@piedata/pieui 1.1.8 → 1.1.10
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/components/Buttons/RedirectButtonCard/index.d.ts +2 -0
- package/dist/components/Buttons/RedirectButtonCard/index.d.ts.map +1 -0
- package/dist/components/Buttons/RedirectButtonCard/types/index.d.ts +13 -0
- package/dist/components/Buttons/RedirectButtonCard/types/index.d.ts.map +1 -0
- package/dist/components/Buttons/RedirectButtonCard/ui/RedirectButtonCard.d.ts +4 -0
- package/dist/components/Buttons/RedirectButtonCard/ui/RedirectButtonCard.d.ts.map +1 -0
- package/dist/components/index.d.ts +1 -0
- package/dist/components/index.d.ts.map +1 -1
- package/dist/components/index.esm.js +23 -23
- package/dist/components/index.js +39 -45
- package/dist/index.esm.js +20 -20
- package/dist/index.js +29 -29
- package/dist/pieui.components.json +37 -0
- package/dist/util/initializeComponents.d.ts.map +1 -1
- package/package.json +1 -1
package/dist/index.esm.js
CHANGED
|
@@ -1,29 +1,29 @@
|
|
|
1
|
-
var
|
|
1
|
+
var yX=Object.create;var{getPrototypeOf:mX,defineProperty:E0,getOwnPropertyNames:q7,getOwnPropertyDescriptor:uX}=Object,D7=Object.prototype.hasOwnProperty;var S=(Z,J,Y)=>{Y=Z!=null?yX(mX(Z)):{};let G=J||!Z||!Z.__esModule?E0(Y,"default",{value:Z,enumerable:!0}):Y;for(let Q of q7(Z))if(!D7.call(G,Q))E0(G,Q,{get:()=>Z[Q],enumerable:!0});return G},I7=new WeakMap,dX=(Z)=>{var J=I7.get(Z),Y;if(J)return J;if(J=E0({},"__esModule",{value:!0}),Z&&typeof Z==="object"||typeof Z==="function")q7(Z).map((G)=>!D7.call(J,G)&&E0(J,G,{get:()=>Z[G],enumerable:!(Y=uX(Z,G))||Y.enumerable}));return I7.set(Z,J),J},A=(Z,J)=>()=>(J||Z((J={exports:{}}).exports,J),J.exports);var N7=(Z,J)=>{for(var Y in J)E0(Z,Y,{get:J[Y],enumerable:!0,configurable:!0,set:(G)=>J[Y]=()=>G})};var A7=(Z,J)=>()=>(Z&&(J=Z(Z=0)),J);var x7=A((KO,S7)=>{var Q3="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED";S7.exports=Q3});var _7=A((LO,j7)=>{var X3=x7();function f7(){}function C7(){}C7.resetWarningCache=f7;j7.exports=function(){function Z(G,Q,X,W,H,z){if(z===X3)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 Y={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:C7,resetWarningCache:f7};return Y.PropTypes=Y,Y}});var f6=A((MO,k7)=>{k7.exports=_7()();var W3,H3});function q3(Z){if(typeof Z==="object"&&Z!==null){var J=Z.$$typeof;switch(J){case z3:switch(Z=Z.type,Z){case F3:case O3:case B3:case L3:case K3:case V3:return Z;default:switch(Z=Z&&Z.$$typeof,Z){case $3:case v7:case I3:case h7:case M3:return Z;default:return J}}case U3:return J}}}var Q1,z3,U3,B3,K3,L3,M3,$3,F3,O3,v7,V3,h7,I3,C6,j6=function(Z){return q3(Z)===h7};var b7=A7(()=>{Q1=typeof Symbol==="function"&&Symbol.for,z3=Q1?Symbol.for("react.element"):60103,U3=Q1?Symbol.for("react.portal"):60106,B3=Q1?Symbol.for("react.fragment"):60107,K3=Q1?Symbol.for("react.strict_mode"):60108,L3=Q1?Symbol.for("react.profiler"):60114,M3=Q1?Symbol.for("react.provider"):60109,$3=Q1?Symbol.for("react.context"):60110,F3=Q1?Symbol.for("react.async_mode"):60111,O3=Q1?Symbol.for("react.concurrent_mode"):60111,v7=Q1?Symbol.for("react.forward_ref"):60112,V3=Q1?Symbol.for("react.suspense"):60113,h7=Q1?Symbol.for("react.memo"):60115,I3=Q1?Symbol.for("react.lazy"):60116;C6=v7});var _6=A(($O,c7)=>{b7();var N3={childContextTypes:!0,contextType:!0,contextTypes:!0,defaultProps:!0,displayName:!0,getDefaultProps:!0,getDerivedStateFromError:!0,getDerivedStateFromProps:!0,mixins:!0,propTypes:!0,type:!0},A3={name:!0,length:!0,prototype:!0,caller:!0,callee:!0,arguments:!0,arity:!0},R3={$$typeof:!0,render:!0,defaultProps:!0,displayName:!0,propTypes:!0},P3={$$typeof:!0,compare:!0,defaultProps:!0,displayName:!0,propTypes:!0,type:!0},u7={};u7[C6]=R3;function g7(Z){if(j6(Z))return P3;return u7[Z.$$typeof]||N3}var{defineProperty:T3,getOwnPropertyNames:w3,getOwnPropertySymbols:y7,getOwnPropertyDescriptor:E3,getPrototypeOf:S3,prototype:m7}=Object;function d7(Z,J,Y){if(typeof J!=="string"){if(m7){var G=S3(J);if(G&&G!==m7)d7(Z,G,Y)}var Q=w3(J);if(y7)Q=Q.concat(y7(J));var X=g7(Z),W=g7(J);for(var H=0;H<Q.length;++H){var z=Q[H];if(!A3[z]&&!(Y&&Y[z])&&!(W&&W[z])&&!(X&&X[z])){var U=E3(J,z);try{T3(Z,z,U)}catch(B){}}}return Z}return Z}c7.exports=d7});var V5=A((h6,l7)=>{Object.defineProperty(h6,"__esModule",{value:!0});h6.default=_3;function _3(Z){return Z.charAt(0).toUpperCase()+Z.slice(1)}l7.exports=h6.default});var n7=A((b6,i7)=>{Object.defineProperty(b6,"__esModule",{value:!0});b6.default=g3;var v3=V5(),h3=b3(v3);function b3(Z){return Z&&Z.__esModule?Z:{default:Z}}function g3(Z,J,Y){if(Z.hasOwnProperty(J)){var G={},Q=Z[J],X=(0,h3.default)(J),W=Object.keys(Y);for(var H=0;H<W.length;H++){var z=W[H];if(z===J)for(var U=0;U<Q.length;U++)G[Q[U]+X]=Y[J];G[z]=Y[z]}return G}return Y}i7.exports=b6.default});var y6=A((g6,o7)=>{Object.defineProperty(g6,"__esModule",{value:!0});g6.default=m3;function m3(Z,J,Y,G,Q){for(var X=0,W=Z.length;X<W;++X){var H=Z[X](J,Y,G,Q);if(H)return H}}o7.exports=g6.default});var u6=A((m6,s7)=>{Object.defineProperty(m6,"__esModule",{value:!0});m6.default=d3;function a7(Z,J){if(Z.indexOf(J)===-1)Z.push(J)}function d3(Z,J){if(Array.isArray(J))for(var Y=0,G=J.length;Y<G;++Y)a7(Z,J[Y]);else a7(Z,J)}s7.exports=m6.default});var c6=A((d6,r7)=>{Object.defineProperty(d6,"__esModule",{value:!0});d6.default=p3;function p3(Z){return Z instanceof Object&&!Array.isArray(Z)}r7.exports=d6.default});var Z4=A((p6,e7)=>{Object.defineProperty(p6,"__esModule",{value:!0});p6.default=e3;var i3=n7(),n3=I5(i3),o3=y6(),t7=I5(o3),a3=u6(),s3=I5(a3),r3=c6(),t3=I5(r3);function I5(Z){return Z&&Z.__esModule?Z:{default:Z}}function e3(Z){var{prefixMap:J,plugins:Y}=Z;function G(Q){for(var X in Q){var W=Q[X];if((0,t3.default)(W))Q[X]=G(W);else if(Array.isArray(W)){var H=[];for(var z=0,U=W.length;z<U;++z){var B=(0,t7.default)(Y,X,W[z],Q,J);(0,s3.default)(H,B||W[z])}if(H.length>0)Q[X]=H}else{var L=(0,t7.default)(Y,X,W,Q,J);if(L)Q[X]=L;Q=(0,n3.default)(J,X,Q)}}return Q}return G}e7.exports=p6.default});var Y4=A((J4,q5)=>{/*!
|
|
2
2
|
* Bowser - a browser detector
|
|
3
3
|
* https://github.com/ded/bowser
|
|
4
4
|
* MIT License | (c) Dustin Diaz 2015
|
|
5
|
-
*/(function(Z,J,Y){if(typeof I5<"u"&&I5.exports)I5.exports=Y();else if(typeof define=="function"&&define.amd)define(J,Y);else Z[J]=Y()})(t7,"bowser",function(){var Z=!0;function J(z){function U(j1){var P1=z.match(j1);return P1&&P1.length>1&&P1[1]||""}function B(j1){var P1=z.match(j1);return P1&&P1.length>1&&P1[2]||""}var L=U(/(ipod|iphone|ipad)/i).toLowerCase(),F=/like android/i.test(z),M=!F&&/android/i.test(z),K=/nexus\s*[0-6]\s*/i.test(z),$=!K&&/nexus\s*[0-9]+/i.test(z),V=/CrOS/.test(z),N=/silk/i.test(z),P=/sailfish/i.test(z),D=/tizen/i.test(z),q=/(web|hpw)(o|0)s/i.test(z),T=/windows phone/i.test(z),f=/SamsungBrowser/i.test(z),m=!T&&/windows/i.test(z),o1=!L&&!N&&/macintosh/i.test(z),f1=!M&&!P&&!D&&!q&&/linux/i.test(z),C1=B(/edg([ea]|ios)\/(\d+(\.\d+)?)/i),k=U(/version\/(\d+(\.\d+)?)/i),A1=/tablet/i.test(z)&&!/tablet pc/i.test(z),p=!A1&&/[^-]mobi/i.test(z),R1=/xbox/i.test(z),O;if(/opera/i.test(z))O={name:"Opera",opera:Z,version:k||U(/(?:opera|opr|opios)[\s\/](\d+(\.\d+)?)/i)};else if(/opr\/|opios/i.test(z))O={name:"Opera",opera:Z,version:U(/(?:opr|opios)[\s\/](\d+(\.\d+)?)/i)||k};else if(/SamsungBrowser/i.test(z))O={name:"Samsung Internet for Android",samsungBrowser:Z,version:k||U(/(?:SamsungBrowser)[\s\/](\d+(\.\d+)?)/i)};else if(/Whale/i.test(z))O={name:"NAVER Whale browser",whale:Z,version:U(/(?:whale)[\s\/](\d+(?:\.\d+)+)/i)};else if(/MZBrowser/i.test(z))O={name:"MZ Browser",mzbrowser:Z,version:U(/(?:MZBrowser)[\s\/](\d+(?:\.\d+)+)/i)};else if(/coast/i.test(z))O={name:"Opera Coast",coast:Z,version:k||U(/(?:coast)[\s\/](\d+(\.\d+)?)/i)};else if(/focus/i.test(z))O={name:"Focus",focus:Z,version:U(/(?:focus)[\s\/](\d+(?:\.\d+)+)/i)};else if(/yabrowser/i.test(z))O={name:"Yandex Browser",yandexbrowser:Z,version:k||U(/(?:yabrowser)[\s\/](\d+(\.\d+)?)/i)};else if(/ucbrowser/i.test(z))O={name:"UC Browser",ucbrowser:Z,version:U(/(?:ucbrowser)[\s\/](\d+(?:\.\d+)+)/i)};else if(/mxios/i.test(z))O={name:"Maxthon",maxthon:Z,version:U(/(?:mxios)[\s\/](\d+(?:\.\d+)+)/i)};else if(/epiphany/i.test(z))O={name:"Epiphany",epiphany:Z,version:U(/(?:epiphany)[\s\/](\d+(?:\.\d+)+)/i)};else if(/puffin/i.test(z))O={name:"Puffin",puffin:Z,version:U(/(?:puffin)[\s\/](\d+(?:\.\d+)?)/i)};else if(/sleipnir/i.test(z))O={name:"Sleipnir",sleipnir:Z,version:U(/(?:sleipnir)[\s\/](\d+(?:\.\d+)+)/i)};else if(/k-meleon/i.test(z))O={name:"K-Meleon",kMeleon:Z,version:U(/(?:k-meleon)[\s\/](\d+(?:\.\d+)+)/i)};else if(T)if(O={name:"Windows Phone",osname:"Windows Phone",windowsphone:Z},C1)O.msedge=Z,O.version=C1;else O.msie=Z,O.version=U(/iemobile\/(\d+(\.\d+)?)/i);else if(/msie|trident/i.test(z))O={name:"Internet Explorer",msie:Z,version:U(/(?:msie |rv:)(\d+(\.\d+)?)/i)};else if(V)O={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(z))O={name:"Microsoft Edge",msedge:Z,version:C1};else if(/vivaldi/i.test(z))O={name:"Vivaldi",vivaldi:Z,version:U(/vivaldi\/(\d+(\.\d+)?)/i)||k};else if(P)O={name:"Sailfish",osname:"Sailfish OS",sailfish:Z,version:U(/sailfish\s?browser\/(\d+(\.\d+)?)/i)};else if(/seamonkey\//i.test(z))O={name:"SeaMonkey",seamonkey:Z,version:U(/seamonkey\/(\d+(\.\d+)?)/i)};else if(/firefox|iceweasel|fxios/i.test(z)){if(O={name:"Firefox",firefox:Z,version:U(/(?:firefox|iceweasel|fxios)[ \/](\d+(\.\d+)?)/i)},/\((mobile|tablet);[^\)]*rv:[\d\.]+\)/i.test(z))O.firefoxos=Z,O.osname="Firefox OS"}else if(N)O={name:"Amazon Silk",silk:Z,version:U(/silk\/(\d+(\.\d+)?)/i)};else if(/phantom/i.test(z))O={name:"PhantomJS",phantom:Z,version:U(/phantomjs\/(\d+(\.\d+)?)/i)};else if(/slimerjs/i.test(z))O={name:"SlimerJS",slimer:Z,version:U(/slimerjs\/(\d+(\.\d+)?)/i)};else if(/blackberry|\bbb\d+/i.test(z)||/rim\stablet/i.test(z))O={name:"BlackBerry",osname:"BlackBerry OS",blackberry:Z,version:k||U(/blackberry[\d]+\/(\d+(\.\d+)?)/i)};else if(q)O={name:"WebOS",osname:"WebOS",webos:Z,version:k||U(/w(?:eb)?osbrowser\/(\d+(\.\d+)?)/i)},/touchpad\//i.test(z)&&(O.touchpad=Z);else if(/bada/i.test(z))O={name:"Bada",osname:"Bada",bada:Z,version:U(/dolfin\/(\d+(\.\d+)?)/i)};else if(D)O={name:"Tizen",osname:"Tizen",tizen:Z,version:U(/(?:tizen\s?)?browser\/(\d+(\.\d+)?)/i)||k};else if(/qupzilla/i.test(z))O={name:"QupZilla",qupzilla:Z,version:U(/(?:qupzilla)[\s\/](\d+(?:\.\d+)+)/i)||k};else if(/chromium/i.test(z))O={name:"Chromium",chromium:Z,version:U(/(?:chromium)[\s\/](\d+(?:\.\d+)?)/i)||k};else if(/chrome|crios|crmo/i.test(z))O={name:"Chrome",chrome:Z,version:U(/(?:chrome|crios|crmo)\/(\d+(\.\d+)?)/i)};else if(M)O={name:"Android",version:k};else if(/safari|applewebkit/i.test(z)){if(O={name:"Safari",safari:Z},k)O.version=k}else if(L){if(O={name:L=="iphone"?"iPhone":L=="ipad"?"iPad":"iPod"},k)O.version=k}else if(/googlebot/i.test(z))O={name:"Googlebot",googlebot:Z,version:U(/googlebot\/(\d+(\.\d+))/i)||k};else O={name:U(/^(.*)\/(.*) /),version:B(/^(.*)\/(.*) /)};if(!O.msedge&&/(apple)?webkit/i.test(z)){if(/(apple)?webkit\/537\.36/i.test(z))O.name=O.name||"Blink",O.blink=Z;else O.name=O.name||"Webkit",O.webkit=Z;if(!O.version&&k)O.version=k}else if(!O.opera&&/gecko\//i.test(z))O.name=O.name||"Gecko",O.gecko=Z,O.version=O.version||U(/gecko\/(\d+(\.\d+)?)/i);if(!O.windowsphone&&(M||O.silk))O.android=Z,O.osname="Android";else if(!O.windowsphone&&L)O[L]=Z,O.ios=Z,O.osname="iOS";else if(o1)O.mac=Z,O.osname="macOS";else if(R1)O.xbox=Z,O.osname="Xbox";else if(m)O.windows=Z,O.osname="Windows";else if(f1)O.linux=Z,O.osname="Linux";function z1(j1){switch(j1){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 y="";if(O.windows)y=z1(U(/Windows ((NT|XP)( \d\d?.\d)?)/i));else if(O.windowsphone)y=U(/windows phone (?:os)?\s?(\d+(\.\d+)*)/i);else if(O.mac)y=U(/Mac OS X (\d+([_\.\s]\d+)*)/i),y=y.replace(/[_\s]/g,".");else if(L)y=U(/os (\d+([_\s]\d+)*) like mac os x/i),y=y.replace(/[_\s]/g,".");else if(M)y=U(/android[ \/-](\d+(\.\d+)*)/i);else if(O.webos)y=U(/(?:web|hpw)os\/(\d+(\.\d+)*)/i);else if(O.blackberry)y=U(/rim\stablet\sos\s(\d+(\.\d+)*)/i);else if(O.bada)y=U(/bada\/(\d+(\.\d+)*)/i);else if(O.tizen)y=U(/tizen[\/\s](\d+(\.\d+)*)/i);if(y)O.osversion=y;var K1=!O.windows&&y.split(".")[0];if(A1||$||L=="ipad"||M&&(K1==3||K1>=4&&!p)||O.silk)O.tablet=Z;else if(p||L=="iphone"||L=="ipod"||M||K||O.blackberry||O.webos||O.bada)O.mobile=Z;if(O.msedge||O.msie&&O.version>=10||O.yandexbrowser&&O.version>=15||O.vivaldi&&O.version>=1||O.chrome&&O.version>=20||O.samsungBrowser&&O.version>=4||O.whale&&X([O.version,"1.0"])===1||O.mzbrowser&&X([O.version,"6.0"])===1||O.focus&&X([O.version,"1.0"])===1||O.firefox&&O.version>=20||O.safari&&O.version>=6||O.opera&&O.version>=10||O.ios&&O.osversion&&O.osversion.split(".")[0]>=6||O.blackberry&&O.version>=10.1||O.chromium&&O.version>=20)O.a=Z;else if(O.msie&&O.version<10||O.chrome&&O.version<20||O.firefox&&O.version<20||O.safari&&O.version<6||O.opera&&O.version<10||O.ios&&O.osversion&&O.osversion.split(".")[0]<6||O.chromium&&O.version<20)O.c=Z;else O.x=Z;return O}var Y=J(typeof navigator<"u"?navigator.userAgent||"":"");Y.test=function(z){for(var U=0;U<z.length;++U){var B=z[U];if(typeof B==="string"){if(B in Y)return!0}}return!1};function G(z){return z.split(".").length}function Q(z,U){var B=[],L;if(Array.prototype.map)return Array.prototype.map.call(z,U);for(L=0;L<z.length;L++)B.push(U(z[L]));return B}function X(z){var U=Math.max(G(z[0]),G(z[1])),B=Q(z,function(L){var F=U-G(L);return L=L+Array(F+1).join(".0"),Q(L.split("."),function(M){return Array(20-M.length).join("0")+M}).reverse()});while(--U>=0)if(B[0][U]>B[1][U])return 1;else if(B[0][U]===B[1][U]){if(U===0)return 0}else return-1}function W(z,U,B){var L=Y;if(typeof U==="string")B=U,U=void 0;if(U===void 0)U=!1;if(B)L=J(B);var F=""+L.version;for(var M in z)if(z.hasOwnProperty(M)){if(L[M]){if(typeof z[M]!=="string")throw Error("Browser version in the minVersion map should be a string: "+M+": "+String(z));return X([F,z[M]])<0}}return U}function H(z,U,B){return!W(z,U,B)}return Y.isUnsupportedBrowser=W,Y.compareVersions=X,Y.check=H,Y._detect=J,Y.detect=J,Y})});var Q4=A((l6,G4)=>{Object.defineProperty(l6,"__esModule",{value:!0});l6.default=YW;var e3=e7(),Z4=ZW(e3);function ZW(Z){return Z&&Z.__esModule?Z:{default:Z}}var J4={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"},Y4={chrome:"chrome",chromium:"chrome",safari:"safari",firfox:"firefox",msedge:"edge",opera:"opera",vivaldi:"opera",msie:"ie"};function JW(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 Y4)if(Z.hasOwnProperty(J))return Y4[J]}function YW(Z){var J=Z4.default._detect(Z);if(J.yandexbrowser)J=Z4.default._detect(Z.replace(/YaBrowser\/[0-9.]*/,""));for(var Y in J4)if(J.hasOwnProperty(Y)){var G=J4[Y];J.jsPrefix=G,J.cssPrefix="-"+G.toLowerCase()+"-";break}if(J.browserName=JW(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}G4.exports=l6.default});var W4=A((i6,X4)=>{Object.defineProperty(i6,"__esModule",{value:!0});i6.default=QW;function QW(Z,J,Y){var G="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 Y+G;return G}X4.exports=i6.default});var U4=A((n6,z4)=>{Object.defineProperty(n6,"__esModule",{value:!0});var WW=function(){function Z(J,Y){for(var G=0;G<Y.length;G++){var Q=Y[G];if(Q.enumerable=Q.enumerable||!1,Q.configurable=!0,"value"in Q)Q.writable=!0;Object.defineProperty(J,Q.key,Q)}}return function(J,Y,G){if(Y)Z(J.prototype,Y);if(G)Z(J,G);return J}}();n6.default=qW;var HW=Q4(),zW=U0(HW),UW=W4(),BW=U0(UW),KW=O5(),LW=U0(KW),MW=u6(),$W=U0(MW),FW=c6(),OW=U0(FW),VW=g6(),H4=U0(VW);function U0(Z){return Z&&Z.__esModule?Z:{default:Z}}function IW(Z,J){if(!(Z instanceof J))throw TypeError("Cannot call a class as a function")}function qW(Z){var{prefixMap:J,plugins:Y}=Z,G=arguments.length>1&&arguments[1]!==void 0?arguments[1]:function(Q){return Q};return function(){function Q(){var X=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};IW(this,Q);var W=typeof navigator<"u"?navigator.userAgent:void 0;if(this._userAgent=X.userAgent||W,this._keepUnprefixed=X.keepUnprefixed||!1,this._userAgent)this._browserInfo=(0,zW.default)(this._userAgent);if(this._browserInfo&&this._browserInfo.cssPrefix)this.prefixedKeyframes=(0,BW.default)(this._browserInfo.browserName,this._browserInfo.browserVersion,this._browserInfo.cssPrefix);else return this._useFallback=!0,!1;var H=this._browserInfo.browserName&&J[this._browserInfo.browserName];if(H){this._requiresPrefix={};for(var z in H)if(H[z]>=this._browserInfo.browserVersion)this._requiresPrefix[z]=!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 WW(Q,[{key:"prefix",value:function(W){if(this._useFallback)return G(W);if(!this._hasPropsRequiringPrefix)return W;return this._prefixStyle(W)}},{key:"_prefixStyle",value:function(W){for(var H in W){var z=W[H];if((0,OW.default)(z))W[H]=this.prefix(z);else if(Array.isArray(z)){var U=[];for(var B=0,L=z.length;B<L;++B){var F=(0,H4.default)(Y,H,z[B],W,this._metaData);(0,$W.default)(U,F||z[B])}if(U.length>0)W[H]=U}else{var M=(0,H4.default)(Y,H,z,W,this._metaData);if(M)W[H]=M;if(this._requiresPrefix.hasOwnProperty(H)){if(W[this._browserInfo.jsPrefix+(0,LW.default)(H)]=z,!this._keepUnprefixed)delete W[H]}}}return W}}],[{key:"prefixAll",value:function(W){return G(W)}}]),Q}()}z4.exports=n6.default});var o6=A((OO,q5)=>{/*!
|
|
5
|
+
*/(function(Z,J,Y){if(typeof q5<"u"&&q5.exports)q5.exports=Y();else if(typeof define=="function"&&define.amd)define(J,Y);else Z[J]=Y()})(J4,"bowser",function(){var Z=!0;function J(z){function U(_1){var T1=z.match(_1);return T1&&T1.length>1&&T1[1]||""}function B(_1){var T1=z.match(_1);return T1&&T1.length>1&&T1[2]||""}var L=U(/(ipod|iphone|ipad)/i).toLowerCase(),F=/like android/i.test(z),M=!F&&/android/i.test(z),K=/nexus\s*[0-6]\s*/i.test(z),$=!K&&/nexus\s*[0-9]+/i.test(z),O=/CrOS/.test(z),N=/silk/i.test(z),P=/sailfish/i.test(z),D=/tizen/i.test(z),q=/(web|hpw)(o|0)s/i.test(z),T=/windows phone/i.test(z),f=/SamsungBrowser/i.test(z),u=!T&&/windows/i.test(z),a1=!L&&!N&&/macintosh/i.test(z),C1=!M&&!P&&!D&&!q&&/linux/i.test(z),j1=B(/edg([ea]|ios)\/(\d+(\.\d+)?)/i),k=U(/version\/(\d+(\.\d+)?)/i),R1=/tablet/i.test(z)&&!/tablet pc/i.test(z),p=!R1&&/[^-]mobi/i.test(z),P1=/xbox/i.test(z),V;if(/opera/i.test(z))V={name:"Opera",opera:Z,version:k||U(/(?:opera|opr|opios)[\s\/](\d+(\.\d+)?)/i)};else if(/opr\/|opios/i.test(z))V={name:"Opera",opera:Z,version:U(/(?:opr|opios)[\s\/](\d+(\.\d+)?)/i)||k};else if(/SamsungBrowser/i.test(z))V={name:"Samsung Internet for Android",samsungBrowser:Z,version:k||U(/(?:SamsungBrowser)[\s\/](\d+(\.\d+)?)/i)};else if(/Whale/i.test(z))V={name:"NAVER Whale browser",whale:Z,version:U(/(?:whale)[\s\/](\d+(?:\.\d+)+)/i)};else if(/MZBrowser/i.test(z))V={name:"MZ Browser",mzbrowser:Z,version:U(/(?:MZBrowser)[\s\/](\d+(?:\.\d+)+)/i)};else if(/coast/i.test(z))V={name:"Opera Coast",coast:Z,version:k||U(/(?:coast)[\s\/](\d+(\.\d+)?)/i)};else if(/focus/i.test(z))V={name:"Focus",focus:Z,version:U(/(?:focus)[\s\/](\d+(?:\.\d+)+)/i)};else if(/yabrowser/i.test(z))V={name:"Yandex Browser",yandexbrowser:Z,version:k||U(/(?:yabrowser)[\s\/](\d+(\.\d+)?)/i)};else if(/ucbrowser/i.test(z))V={name:"UC Browser",ucbrowser:Z,version:U(/(?:ucbrowser)[\s\/](\d+(?:\.\d+)+)/i)};else if(/mxios/i.test(z))V={name:"Maxthon",maxthon:Z,version:U(/(?:mxios)[\s\/](\d+(?:\.\d+)+)/i)};else if(/epiphany/i.test(z))V={name:"Epiphany",epiphany:Z,version:U(/(?:epiphany)[\s\/](\d+(?:\.\d+)+)/i)};else if(/puffin/i.test(z))V={name:"Puffin",puffin:Z,version:U(/(?:puffin)[\s\/](\d+(?:\.\d+)?)/i)};else if(/sleipnir/i.test(z))V={name:"Sleipnir",sleipnir:Z,version:U(/(?:sleipnir)[\s\/](\d+(?:\.\d+)+)/i)};else if(/k-meleon/i.test(z))V={name:"K-Meleon",kMeleon:Z,version:U(/(?:k-meleon)[\s\/](\d+(?:\.\d+)+)/i)};else if(T)if(V={name:"Windows Phone",osname:"Windows Phone",windowsphone:Z},j1)V.msedge=Z,V.version=j1;else V.msie=Z,V.version=U(/iemobile\/(\d+(\.\d+)?)/i);else if(/msie|trident/i.test(z))V={name:"Internet Explorer",msie:Z,version:U(/(?:msie |rv:)(\d+(\.\d+)?)/i)};else if(O)V={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(z))V={name:"Microsoft Edge",msedge:Z,version:j1};else if(/vivaldi/i.test(z))V={name:"Vivaldi",vivaldi:Z,version:U(/vivaldi\/(\d+(\.\d+)?)/i)||k};else if(P)V={name:"Sailfish",osname:"Sailfish OS",sailfish:Z,version:U(/sailfish\s?browser\/(\d+(\.\d+)?)/i)};else if(/seamonkey\//i.test(z))V={name:"SeaMonkey",seamonkey:Z,version:U(/seamonkey\/(\d+(\.\d+)?)/i)};else if(/firefox|iceweasel|fxios/i.test(z)){if(V={name:"Firefox",firefox:Z,version:U(/(?:firefox|iceweasel|fxios)[ \/](\d+(\.\d+)?)/i)},/\((mobile|tablet);[^\)]*rv:[\d\.]+\)/i.test(z))V.firefoxos=Z,V.osname="Firefox OS"}else if(N)V={name:"Amazon Silk",silk:Z,version:U(/silk\/(\d+(\.\d+)?)/i)};else if(/phantom/i.test(z))V={name:"PhantomJS",phantom:Z,version:U(/phantomjs\/(\d+(\.\d+)?)/i)};else if(/slimerjs/i.test(z))V={name:"SlimerJS",slimer:Z,version:U(/slimerjs\/(\d+(\.\d+)?)/i)};else if(/blackberry|\bbb\d+/i.test(z)||/rim\stablet/i.test(z))V={name:"BlackBerry",osname:"BlackBerry OS",blackberry:Z,version:k||U(/blackberry[\d]+\/(\d+(\.\d+)?)/i)};else if(q)V={name:"WebOS",osname:"WebOS",webos:Z,version:k||U(/w(?:eb)?osbrowser\/(\d+(\.\d+)?)/i)},/touchpad\//i.test(z)&&(V.touchpad=Z);else if(/bada/i.test(z))V={name:"Bada",osname:"Bada",bada:Z,version:U(/dolfin\/(\d+(\.\d+)?)/i)};else if(D)V={name:"Tizen",osname:"Tizen",tizen:Z,version:U(/(?:tizen\s?)?browser\/(\d+(\.\d+)?)/i)||k};else if(/qupzilla/i.test(z))V={name:"QupZilla",qupzilla:Z,version:U(/(?:qupzilla)[\s\/](\d+(?:\.\d+)+)/i)||k};else if(/chromium/i.test(z))V={name:"Chromium",chromium:Z,version:U(/(?:chromium)[\s\/](\d+(?:\.\d+)?)/i)||k};else if(/chrome|crios|crmo/i.test(z))V={name:"Chrome",chrome:Z,version:U(/(?:chrome|crios|crmo)\/(\d+(\.\d+)?)/i)};else if(M)V={name:"Android",version:k};else if(/safari|applewebkit/i.test(z)){if(V={name:"Safari",safari:Z},k)V.version=k}else if(L){if(V={name:L=="iphone"?"iPhone":L=="ipad"?"iPad":"iPod"},k)V.version=k}else if(/googlebot/i.test(z))V={name:"Googlebot",googlebot:Z,version:U(/googlebot\/(\d+(\.\d+))/i)||k};else V={name:U(/^(.*)\/(.*) /),version:B(/^(.*)\/(.*) /)};if(!V.msedge&&/(apple)?webkit/i.test(z)){if(/(apple)?webkit\/537\.36/i.test(z))V.name=V.name||"Blink",V.blink=Z;else V.name=V.name||"Webkit",V.webkit=Z;if(!V.version&&k)V.version=k}else if(!V.opera&&/gecko\//i.test(z))V.name=V.name||"Gecko",V.gecko=Z,V.version=V.version||U(/gecko\/(\d+(\.\d+)?)/i);if(!V.windowsphone&&(M||V.silk))V.android=Z,V.osname="Android";else if(!V.windowsphone&&L)V[L]=Z,V.ios=Z,V.osname="iOS";else if(a1)V.mac=Z,V.osname="macOS";else if(P1)V.xbox=Z,V.osname="Xbox";else if(u)V.windows=Z,V.osname="Windows";else if(C1)V.linux=Z,V.osname="Linux";function l(_1){switch(_1){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 g="";if(V.windows)g=l(U(/Windows ((NT|XP)( \d\d?.\d)?)/i));else if(V.windowsphone)g=U(/windows phone (?:os)?\s?(\d+(\.\d+)*)/i);else if(V.mac)g=U(/Mac OS X (\d+([_\.\s]\d+)*)/i),g=g.replace(/[_\s]/g,".");else if(L)g=U(/os (\d+([_\s]\d+)*) like mac os x/i),g=g.replace(/[_\s]/g,".");else if(M)g=U(/android[ \/-](\d+(\.\d+)*)/i);else if(V.webos)g=U(/(?:web|hpw)os\/(\d+(\.\d+)*)/i);else if(V.blackberry)g=U(/rim\stablet\sos\s(\d+(\.\d+)*)/i);else if(V.bada)g=U(/bada\/(\d+(\.\d+)*)/i);else if(V.tizen)g=U(/tizen[\/\s](\d+(\.\d+)*)/i);if(g)V.osversion=g;var M1=!V.windows&&g.split(".")[0];if(R1||$||L=="ipad"||M&&(M1==3||M1>=4&&!p)||V.silk)V.tablet=Z;else if(p||L=="iphone"||L=="ipod"||M||K||V.blackberry||V.webos||V.bada)V.mobile=Z;if(V.msedge||V.msie&&V.version>=10||V.yandexbrowser&&V.version>=15||V.vivaldi&&V.version>=1||V.chrome&&V.version>=20||V.samsungBrowser&&V.version>=4||V.whale&&X([V.version,"1.0"])===1||V.mzbrowser&&X([V.version,"6.0"])===1||V.focus&&X([V.version,"1.0"])===1||V.firefox&&V.version>=20||V.safari&&V.version>=6||V.opera&&V.version>=10||V.ios&&V.osversion&&V.osversion.split(".")[0]>=6||V.blackberry&&V.version>=10.1||V.chromium&&V.version>=20)V.a=Z;else if(V.msie&&V.version<10||V.chrome&&V.version<20||V.firefox&&V.version<20||V.safari&&V.version<6||V.opera&&V.version<10||V.ios&&V.osversion&&V.osversion.split(".")[0]<6||V.chromium&&V.version<20)V.c=Z;else V.x=Z;return V}var Y=J(typeof navigator<"u"?navigator.userAgent||"":"");Y.test=function(z){for(var U=0;U<z.length;++U){var B=z[U];if(typeof B==="string"){if(B in Y)return!0}}return!1};function G(z){return z.split(".").length}function Q(z,U){var B=[],L;if(Array.prototype.map)return Array.prototype.map.call(z,U);for(L=0;L<z.length;L++)B.push(U(z[L]));return B}function X(z){var U=Math.max(G(z[0]),G(z[1])),B=Q(z,function(L){var F=U-G(L);return L=L+Array(F+1).join(".0"),Q(L.split("."),function(M){return Array(20-M.length).join("0")+M}).reverse()});while(--U>=0)if(B[0][U]>B[1][U])return 1;else if(B[0][U]===B[1][U]){if(U===0)return 0}else return-1}function W(z,U,B){var L=Y;if(typeof U==="string")B=U,U=void 0;if(U===void 0)U=!1;if(B)L=J(B);var F=""+L.version;for(var M in z)if(z.hasOwnProperty(M)){if(L[M]){if(typeof z[M]!=="string")throw Error("Browser version in the minVersion map should be a string: "+M+": "+String(z));return X([F,z[M]])<0}}return U}function H(z,U,B){return!W(z,U,B)}return Y.isUnsupportedBrowser=W,Y.compareVersions=X,Y.check=H,Y._detect=J,Y.detect=J,Y})});var H4=A((l6,W4)=>{Object.defineProperty(l6,"__esModule",{value:!0});l6.default=QW;var JW=Y4(),G4=YW(JW);function YW(Z){return Z&&Z.__esModule?Z:{default:Z}}var Q4={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"},X4={chrome:"chrome",chromium:"chrome",safari:"safari",firfox:"firefox",msedge:"edge",opera:"opera",vivaldi:"opera",msie:"ie"};function GW(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 X4)if(Z.hasOwnProperty(J))return X4[J]}function QW(Z){var J=G4.default._detect(Z);if(J.yandexbrowser)J=G4.default._detect(Z.replace(/YaBrowser\/[0-9.]*/,""));for(var Y in Q4)if(J.hasOwnProperty(Y)){var G=Q4[Y];J.jsPrefix=G,J.cssPrefix="-"+G.toLowerCase()+"-";break}if(J.browserName=GW(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}W4.exports=l6.default});var U4=A((i6,z4)=>{Object.defineProperty(i6,"__esModule",{value:!0});i6.default=WW;function WW(Z,J,Y){var G="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 Y+G;return G}z4.exports=i6.default});var L4=A((n6,K4)=>{Object.defineProperty(n6,"__esModule",{value:!0});var zW=function(){function Z(J,Y){for(var G=0;G<Y.length;G++){var Q=Y[G];if(Q.enumerable=Q.enumerable||!1,Q.configurable=!0,"value"in Q)Q.writable=!0;Object.defineProperty(J,Q.key,Q)}}return function(J,Y,G){if(Y)Z(J.prototype,Y);if(G)Z(J,G);return J}}();n6.default=NW;var UW=H4(),BW=B0(UW),KW=U4(),LW=B0(KW),MW=V5(),$W=B0(MW),FW=u6(),OW=B0(FW),VW=c6(),IW=B0(VW),qW=y6(),B4=B0(qW);function B0(Z){return Z&&Z.__esModule?Z:{default:Z}}function DW(Z,J){if(!(Z instanceof J))throw TypeError("Cannot call a class as a function")}function NW(Z){var{prefixMap:J,plugins:Y}=Z,G=arguments.length>1&&arguments[1]!==void 0?arguments[1]:function(Q){return Q};return function(){function Q(){var X=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};DW(this,Q);var W=typeof navigator<"u"?navigator.userAgent:void 0;if(this._userAgent=X.userAgent||W,this._keepUnprefixed=X.keepUnprefixed||!1,this._userAgent)this._browserInfo=(0,BW.default)(this._userAgent);if(this._browserInfo&&this._browserInfo.cssPrefix)this.prefixedKeyframes=(0,LW.default)(this._browserInfo.browserName,this._browserInfo.browserVersion,this._browserInfo.cssPrefix);else return this._useFallback=!0,!1;var H=this._browserInfo.browserName&&J[this._browserInfo.browserName];if(H){this._requiresPrefix={};for(var z in H)if(H[z]>=this._browserInfo.browserVersion)this._requiresPrefix[z]=!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 zW(Q,[{key:"prefix",value:function(W){if(this._useFallback)return G(W);if(!this._hasPropsRequiringPrefix)return W;return this._prefixStyle(W)}},{key:"_prefixStyle",value:function(W){for(var H in W){var z=W[H];if((0,IW.default)(z))W[H]=this.prefix(z);else if(Array.isArray(z)){var U=[];for(var B=0,L=z.length;B<L;++B){var F=(0,B4.default)(Y,H,z[B],W,this._metaData);(0,OW.default)(U,F||z[B])}if(U.length>0)W[H]=U}else{var M=(0,B4.default)(Y,H,z,W,this._metaData);if(M)W[H]=M;if(this._requiresPrefix.hasOwnProperty(H)){if(W[this._browserInfo.jsPrefix+(0,$W.default)(H)]=z,!this._keepUnprefixed)delete W[H]}}}return W}}],[{key:"prefixAll",value:function(W){return G(W)}}]),Q}()}K4.exports=n6.default});var o6=A((NO,D5)=>{/*!
|
|
6
6
|
Copyright (c) 2015 Jed Watson.
|
|
7
7
|
Based on code that is Copyright 2013-2015, Facebook, Inc.
|
|
8
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 q5<"u"&&q5.exports)q5.exports=J;else window.ExecutionEnvironment=J})()});var a1=A((a6,B4)=>{Object.defineProperty(a6,"__esModule",{value:!0});a6.default=AW;var NW=/-webkit-|-moz-|-ms-/;function AW(Z){return typeof Z==="string"&&NW.test(Z)}B4.exports=a6.default});var L4=A((s6,K4)=>{Object.defineProperty(s6,"__esModule",{value:!0});s6.default=SW;var PW=a1(),TW=wW(PW);function wW(Z){return Z&&Z.__esModule?Z:{default:Z}}var EW=["-webkit-","-moz-",""];function SW(Z,J){if(typeof J==="string"&&!(0,TW.default)(J)&&J.indexOf("calc(")>-1)return EW.map(function(Y){return J.replace(/calc\(/g,Y+"calc(")})}K4.exports=s6.default});var $4=A((r6,M4)=>{Object.defineProperty(r6,"__esModule",{value:!0});r6.default=kW;var fW=a1(),CW=jW(fW);function jW(Z){return Z&&Z.__esModule?Z:{default:Z}}var _W=["-webkit-",""];function kW(Z,J){if(typeof J==="string"&&!(0,CW.default)(J)&&J.indexOf("cross-fade(")>-1)return _W.map(function(Y){return J.replace(/cross-fade\(/g,Y+"cross-fade(")})}M4.exports=r6.default});var O4=A((t6,F4)=>{Object.defineProperty(t6,"__esModule",{value:!0});t6.default=yW;var hW=["-webkit-","-moz-",""],bW={"zoom-in":!0,"zoom-out":!0,grab:!0,grabbing:!0};function yW(Z,J){if(Z==="cursor"&&bW.hasOwnProperty(J))return hW.map(function(Y){return Y+J})}F4.exports=t6.default});var I4=A((e6,V4)=>{Object.defineProperty(e6,"__esModule",{value:!0});e6.default=pW;var mW=a1(),uW=dW(mW);function dW(Z){return Z&&Z.__esModule?Z:{default:Z}}var cW=["-webkit-",""];function pW(Z,J){if(typeof J==="string"&&!(0,uW.default)(J)&&J.indexOf("filter(")>-1)return cW.map(function(Y){return J.replace(/filter\(/g,Y+"filter(")})}V4.exports=e6.default});var N4=A((Z8,D4)=>{Object.defineProperty(Z8,"__esModule",{value:!0});Z8.default=iW;var q4={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 iW(Z,J){if(Z==="display"&&q4.hasOwnProperty(J))return q4[J]}D4.exports=Z8.default});var P4=A((J8,R4)=>{Object.defineProperty(J8,"__esModule",{value:!0});J8.default=aW;var oW={"space-around":"distribute","space-between":"justify","flex-start":"start","flex-end":"end"},A4={alignContent:"msFlexLinePack",alignSelf:"msFlexItemAlign",alignItems:"msFlexAlign",justifyContent:"msFlexPack",order:"msFlexOrder",flexGrow:"msFlexPositive",flexShrink:"msFlexNegative",flexBasis:"msFlexPreferredSize"};function aW(Z,J,Y){if(A4.hasOwnProperty(Z))Y[A4[Z]]=oW[J]||J}R4.exports=J8.default});var E4=A((Y8,w4)=>{Object.defineProperty(Y8,"__esModule",{value:!0});Y8.default=tW;var rW={"space-around":"justify","space-between":"justify","flex-start":"start","flex-end":"end","wrap-reverse":"multiple",wrap:"multiple",flex:"box","inline-flex":"inline-box"},T4={alignItems:"WebkitBoxAlign",justifyContent:"WebkitBoxPack",flexWrap:"WebkitBoxLines",flexGrow:"WebkitBoxFlex"};function tW(Z,J,Y){if(Z==="flexDirection"&&typeof J==="string"){if(J.indexOf("column")>-1)Y.WebkitBoxOrient="vertical";else Y.WebkitBoxOrient="horizontal";if(J.indexOf("reverse")>-1)Y.WebkitBoxDirection="reverse";else Y.WebkitBoxDirection="normal"}if(T4.hasOwnProperty(Z))Y[T4[Z]]=rW[J]||J}w4.exports=Y8.default});var f4=A((G8,x4)=>{Object.defineProperty(G8,"__esModule",{value:!0});G8.default=QH;var ZH=a1(),JH=YH(ZH);function YH(Z){return Z&&Z.__esModule?Z:{default:Z}}var GH=["-webkit-","-moz-",""],S4=/linear-gradient|radial-gradient|repeating-linear-gradient|repeating-radial-gradient/gi;function QH(Z,J){if(typeof J==="string"&&!(0,JH.default)(J)&&S4.test(J))return GH.map(function(Y){return J.replace(S4,function(G){return Y+G})})}x4.exports=G8.default});var j4=A((Q8,C4)=>{Object.defineProperty(Q8,"__esModule",{value:!0});Q8.default=BH;var WH=a1(),HH=zH(WH);function zH(Z){return Z&&Z.__esModule?Z:{default:Z}}var UH=["-webkit-",""];function BH(Z,J){if(typeof J==="string"&&!(0,HH.default)(J)&&J.indexOf("image-set(")>-1)return UH.map(function(Y){return J.replace(/image-set\(/g,Y+"image-set(")})}C4.exports=Q8.default});var k4=A((X8,_4)=>{Object.defineProperty(X8,"__esModule",{value:!0});X8.default=LH;function LH(Z,J){if(Z==="position"&&J==="sticky")return["-webkit-sticky","sticky"]}_4.exports=X8.default});var h4=A((W8,v4)=>{Object.defineProperty(W8,"__esModule",{value:!0});W8.default=VH;var $H=["-webkit-","-moz-",""],FH={maxHeight:!0,maxWidth:!0,width:!0,height:!0,columnWidth:!0,minWidth:!0,minHeight:!0},OH={"min-content":!0,"max-content":!0,"fill-available":!0,"fit-content":!0,"contain-floats":!0};function VH(Z,J){if(FH.hasOwnProperty(Z)&&OH.hasOwnProperty(J))return $H.map(function(Y){return Y+J})}v4.exports=W8.default});var y4=A((VO,b4)=>{var qH=/[A-Z]/g,DH=/^ms-/,H8={};function NH(Z){return"-"+Z.toLowerCase()}function AH(Z){if(H8.hasOwnProperty(Z))return H8[Z];var J=Z.replace(qH,NH);return H8[Z]=DH.test(J)?"-"+J:J}b4.exports=AH});var U8=A((z8,g4)=>{Object.defineProperty(z8,"__esModule",{value:!0});z8.default=wH;var RH=y4(),PH=TH(RH);function TH(Z){return Z&&Z.__esModule?Z:{default:Z}}function wH(Z){return(0,PH.default)(Z)}g4.exports=z8.default});var d4=A((K8,u4)=>{Object.defineProperty(K8,"__esModule",{value:!0});K8.default=hH;var SH=U8(),xH=B8(SH),fH=a1(),CH=B8(fH),jH=O5(),m4=B8(jH);function B8(Z){return Z&&Z.__esModule?Z:{default:Z}}var _H={transition:!0,transitionProperty:!0,WebkitTransition:!0,WebkitTransitionProperty:!0,MozTransition:!0,MozTransitionProperty:!0},kH={Webkit:"-webkit-",Moz:"-moz-",ms:"-ms-"};function vH(Z,J){if((0,CH.default)(Z))return Z;var Y=Z.split(/,(?![^()]*(?:\([^()]*\))?\))/g);for(var G=0,Q=Y.length;G<Q;++G){var X=Y[G],W=[X];for(var H in J){var z=(0,xH.default)(H);if(X.indexOf(z)>-1&&z!=="order"){var U=J[H];for(var B=0,L=U.length;B<L;++B)W.unshift(X.replace(z,kH[U[B]]+z))}}Y[G]=W.join(",")}return Y.join(",")}function hH(Z,J,Y,G){if(typeof J==="string"&&_H.hasOwnProperty(Z)){var Q=vH(J,G),X=Q.split(/,(?![^()]*(?:\([^()]*\))?\))/g).filter(function(H){return!/-moz-|-ms-/.test(H)}).join(",");if(Z.indexOf("Webkit")>-1)return X;var W=Q.split(/,(?![^()]*(?:\([^()]*\))?\))/g).filter(function(H){return!/-webkit-|-ms-/.test(H)}).join(",");if(Z.indexOf("Moz")>-1)return W;return Y["Webkit"+(0,m4.default)(Z)]=X,Y["Moz"+(0,m4.default)(Z)]=W,Q}}u4.exports=K8.default});var U1=A((M8,YZ)=>{Object.defineProperty(M8,"__esModule",{value:!0});M8.default=yH;function yH(Z,J,Y){if(Y)return[Z,J];return Z}YZ.exports=M8.default});var QZ=A(($8,GZ)=>{Object.defineProperty($8,"__esModule",{value:!0});$8.default=cH;var mH=U1(),uH=dH(mH);function dH(Z){return Z&&Z.__esModule?Z:{default:Z}}function cH(Z,J,Y,G){var{browserName:Q,browserVersion:X,cssPrefix:W,keepUnprefixed:H}=G;if(typeof J==="string"&&J.indexOf("calc(")>-1&&(Q==="firefox"&&X<15||Q==="chrome"&&X<25||Q==="safari"&&X<6.1||Q==="ios_saf"&&X<7))return(0,uH.default)(J.replace(/calc\(/g,W+"calc("),J,H)}GZ.exports=$8.default});var WZ=A((F8,XZ)=>{Object.defineProperty(F8,"__esModule",{value:!0});F8.default=oH;var lH=U1(),iH=nH(lH);function nH(Z){return Z&&Z.__esModule?Z:{default:Z}}function oH(Z,J,Y,G){var{browserName:Q,browserVersion:X,cssPrefix:W,keepUnprefixed:H}=G;if(typeof J==="string"&&J.indexOf("cross-fade(")>-1&&(Q==="chrome"||Q==="opera"||Q==="and_chr"||(Q==="ios_saf"||Q==="safari")&&X<10))return(0,iH.default)(J.replace(/cross-fade\(/g,W+"cross-fade("),J,H)}XZ.exports=F8.default});var UZ=A((O8,zZ)=>{Object.defineProperty(O8,"__esModule",{value:!0});O8.default=Zz;var sH=U1(),HZ=rH(sH);function rH(Z){return Z&&Z.__esModule?Z:{default:Z}}var tH={grab:!0,grabbing:!0},eH={"zoom-in":!0,"zoom-out":!0};function Zz(Z,J,Y,G){var{browserName:Q,browserVersion:X,cssPrefix:W,keepUnprefixed:H}=G;if(Z==="cursor"&&tH[J]&&(Q==="firefox"||Q==="chrome"||Q==="safari"||Q==="opera"))return(0,HZ.default)(W+J,J,H);if(Z==="cursor"&&eH[J]&&(Q==="firefox"&&X<24||Q==="chrome"&&X<37||Q==="safari"&&X<9||Q==="opera"&&X<24))return(0,HZ.default)(W+J,J,H)}zZ.exports=O8.default});var KZ=A((V8,BZ)=>{Object.defineProperty(V8,"__esModule",{value:!0});V8.default=Xz;var Yz=U1(),Gz=Qz(Yz);function Qz(Z){return Z&&Z.__esModule?Z:{default:Z}}function Xz(Z,J,Y,G){var{browserName:Q,browserVersion:X,cssPrefix:W,keepUnprefixed:H}=G;if(typeof J==="string"&&J.indexOf("filter(")>-1&&(Q==="ios_saf"||Q==="safari"&&X<9.1))return(0,Gz.default)(J.replace(/filter\(/g,W+"filter("),J,H)}BZ.exports=V8.default});var MZ=A((I8,LZ)=>{Object.defineProperty(I8,"__esModule",{value:!0});I8.default=Kz;var Hz=U1(),zz=Uz(Hz);function Uz(Z){return Z&&Z.__esModule?Z:{default:Z}}var Bz={flex:!0,"inline-flex":!0};function Kz(Z,J,Y,G){var{browserName:Q,browserVersion:X,cssPrefix:W,keepUnprefixed:H}=G;if(Z==="display"&&Bz[J]&&(Q==="chrome"&&X<29&&X>20||(Q==="safari"||Q==="ios_saf")&&X<9&&X>6||Q==="opera"&&(X===15||X===16)))return(0,zz.default)(W+J,J,H)}LZ.exports=I8.default});var FZ=A((N8,$Z)=>{Object.defineProperty(N8,"__esModule",{value:!0});N8.default=Oz;var Mz=U1(),$z=Fz(Mz);function Fz(Z){return Z&&Z.__esModule?Z:{default:Z}}var q8={"space-around":"distribute","space-between":"justify","flex-start":"start","flex-end":"end",flex:"flexbox","inline-flex":"inline-flexbox"},D8={alignContent:"msFlexLinePack",alignSelf:"msFlexItemAlign",alignItems:"msFlexAlign",justifyContent:"msFlexPack",order:"msFlexOrder",flexGrow:"msFlexPositive",flexShrink:"msFlexNegative",flexBasis:"msFlexPreferredSize"};function Oz(Z,J,Y,G){var{browserName:Q,browserVersion:X,cssPrefix:W,keepUnprefixed:H,requiresPrefix:z}=G;if((D8.hasOwnProperty(Z)||Z==="display"&&typeof J==="string"&&J.indexOf("flex")>-1)&&(Q==="ie_mob"||Q==="ie")&&X===10){if(delete z[Z],!H&&!Array.isArray(Y[Z]))delete Y[Z];if(Z==="display"&&q8.hasOwnProperty(J))return(0,$z.default)(W+q8[J],J,H);if(D8.hasOwnProperty(Z))Y[D8[Z]]=q8[J]||J}}$Z.exports=N8.default});var VZ=A((P8,OZ)=>{Object.defineProperty(P8,"__esModule",{value:!0});P8.default=Rz;var Iz=U1(),qz=Dz(Iz);function Dz(Z){return Z&&Z.__esModule?Z:{default:Z}}var A8={"space-around":"justify","space-between":"justify","flex-start":"start","flex-end":"end","wrap-reverse":"multiple",wrap:"multiple",flex:"box","inline-flex":"inline-box"},R8={alignItems:"WebkitBoxAlign",justifyContent:"WebkitBoxPack",flexWrap:"WebkitBoxLines",flexGrow:"WebkitBoxFlex"},Nz=["alignContent","alignSelf","order","flexGrow","flexShrink","flexBasis","flexDirection"],Az=Object.keys(R8).concat(Nz);function Rz(Z,J,Y,G){var{browserName:Q,browserVersion:X,cssPrefix:W,keepUnprefixed:H,requiresPrefix:z}=G;if((Az.indexOf(Z)>-1||Z==="display"&&typeof J==="string"&&J.indexOf("flex")>-1)&&(Q==="firefox"&&X<22||Q==="chrome"&&X<21||(Q==="safari"||Q==="ios_saf")&&X<=6.1||Q==="android"&&X<4.4||Q==="and_uc")){if(delete z[Z],!H&&!Array.isArray(Y[Z]))delete Y[Z];if(Z==="flexDirection"&&typeof J==="string"){if(J.indexOf("column")>-1)Y.WebkitBoxOrient="vertical";else Y.WebkitBoxOrient="horizontal";if(J.indexOf("reverse")>-1)Y.WebkitBoxDirection="reverse";else Y.WebkitBoxDirection="normal"}if(Z==="display"&&A8.hasOwnProperty(J))return(0,qz.default)(W+A8[J],J,H);if(R8.hasOwnProperty(Z))Y[R8[Z]]=A8[J]||J}}OZ.exports=P8.default});var DZ=A((T8,qZ)=>{Object.defineProperty(T8,"__esModule",{value:!0});T8.default=Sz;var Tz=U1(),wz=Ez(Tz);function Ez(Z){return Z&&Z.__esModule?Z:{default:Z}}var IZ=/linear-gradient|radial-gradient|repeating-linear-gradient|repeating-radial-gradient/gi;function Sz(Z,J,Y,G){var{browserName:Q,browserVersion:X,cssPrefix:W,keepUnprefixed:H}=G;if(typeof J==="string"&&IZ.test(J)&&(Q==="firefox"&&X<16||Q==="chrome"&&X<26||(Q==="safari"||Q==="ios_saf")&&X<7||(Q==="opera"||Q==="op_mini")&&X<12.1||Q==="android"&&X<4.4||Q==="and_uc"))return(0,wz.default)(J.replace(IZ,function(z){return W+z}),J,H)}qZ.exports=T8.default});var AZ=A((w8,NZ)=>{Object.defineProperty(w8,"__esModule",{value:!0});w8.default=_z;var fz=U1(),Cz=jz(fz);function jz(Z){return Z&&Z.__esModule?Z:{default:Z}}function _z(Z,J,Y,G){var{browserName:Q,cssPrefix:X,keepUnprefixed:W}=G;if(typeof J==="string"&&J.indexOf("image-set(")>-1&&(Q==="chrome"||Q==="opera"||Q==="and_chr"||Q==="and_uc"||Q==="ios_saf"||Q==="safari"))return(0,Cz.default)(J.replace(/image-set\(/g,X+"image-set("),J,W)}NZ.exports=w8.default});var PZ=A((E8,RZ)=>{Object.defineProperty(E8,"__esModule",{value:!0});E8.default=yz;var vz=U1(),hz=bz(vz);function bz(Z){return Z&&Z.__esModule?Z:{default:Z}}function yz(Z,J,Y,G){var{browserName:Q,cssPrefix:X,keepUnprefixed:W}=G;if(Z==="position"&&J==="sticky"&&(Q==="safari"||Q==="ios_saf"))return(0,hz.default)(X+J,J,W)}RZ.exports=E8.default});var wZ=A((S8,TZ)=>{Object.defineProperty(S8,"__esModule",{value:!0});S8.default=lz;var mz=U1(),uz=dz(mz);function dz(Z){return Z&&Z.__esModule?Z:{default:Z}}var cz={maxHeight:!0,maxWidth:!0,width:!0,height:!0,columnWidth:!0,minWidth:!0,minHeight:!0},pz={"min-content":!0,"max-content":!0,"fill-available":!0,"fit-content":!0,"contain-floats":!0};function lz(Z,J,Y,G){var{cssPrefix:Q,keepUnprefixed:X}=G;if(cz.hasOwnProperty(Z)&&pz.hasOwnProperty(J))return(0,uz.default)(Q+J,J,X)}TZ.exports=S8.default});var SZ=A((f8,EZ)=>{Object.defineProperty(f8,"__esModule",{value:!0});f8.default=rz;var nz=U8(),oz=az(nz);function az(Z){return Z&&Z.__esModule?Z:{default:Z}}var sz={transition:!0,transitionProperty:!0,WebkitTransition:!0,WebkitTransitionProperty:!0,MozTransition:!0,MozTransitionProperty:!0},x8=void 0;function rz(Z,J,Y,G){var{cssPrefix:Q,keepUnprefixed:X,requiresPrefix:W}=G;if(typeof J==="string"&&sz.hasOwnProperty(Z)){if(!x8)x8=Object.keys(W).map(function(z){return(0,oz.default)(z)});var H=J.split(/,(?![^()]*(?:\([^()]*\))?\))/g);return x8.forEach(function(z){H.forEach(function(U,B){if(U.indexOf(z)>-1&&z!=="order")H[B]=U.replace(z,Q+z)+(X?","+U:"")})}),H.join(",")}}EZ.exports=f8.default});var GG={};I7(GG,{default:()=>IK,__values:()=>J6,__spreadArrays:()=>cY,__spreadArray:()=>pY,__spread:()=>dY,__setFunctionName:()=>bY,__runInitializers:()=>vY,__rewriteRelativeImportExtension:()=>YG,__rest:()=>CY,__read:()=>L9,__propKey:()=>hY,__param:()=>_Y,__metadata:()=>yY,__makeTemplateObject:()=>oY,__importStar:()=>aY,__importDefault:()=>sY,__generator:()=>mY,__extends:()=>fY,__exportStar:()=>uY,__esDecorate:()=>kY,__disposeResources:()=>JG,__decorate:()=>jY,__createBinding:()=>Y6,__classPrivateFieldSet:()=>tY,__classPrivateFieldIn:()=>eY,__classPrivateFieldGet:()=>rY,__awaiter:()=>gY,__await:()=>q0,__asyncValues:()=>nY,__asyncGenerator:()=>lY,__asyncDelegator:()=>iY,__assign:()=>Z6,__addDisposableResource:()=>ZG});function fY(Z,J){if(typeof J!=="function"&&J!==null)throw TypeError("Class extends value "+String(J)+" is not a constructor or null");B9(Z,J);function Y(){this.constructor=Z}Z.prototype=J===null?Object.create(J):(Y.prototype=J.prototype,new Y)}function CY(Z,J){var Y={};for(var G in Z)if(Object.prototype.hasOwnProperty.call(Z,G)&&J.indexOf(G)<0)Y[G]=Z[G];if(Z!=null&&typeof Object.getOwnPropertySymbols==="function"){for(var Q=0,G=Object.getOwnPropertySymbols(Z);Q<G.length;Q++)if(J.indexOf(G[Q])<0&&Object.prototype.propertyIsEnumerable.call(Z,G[Q]))Y[G[Q]]=Z[G[Q]]}return Y}function jY(Z,J,Y,G){var Q=arguments.length,X=Q<3?J:G===null?G=Object.getOwnPropertyDescriptor(J,Y):G,W;if(typeof Reflect==="object"&&typeof Reflect.decorate==="function")X=Reflect.decorate(Z,J,Y,G);else for(var H=Z.length-1;H>=0;H--)if(W=Z[H])X=(Q<3?W(X):Q>3?W(J,Y,X):W(J,Y))||X;return Q>3&&X&&Object.defineProperty(J,Y,X),X}function _Y(Z,J){return function(Y,G){J(Y,G,Z)}}function kY(Z,J,Y,G,Q,X){function W(N){if(N!==void 0&&typeof N!=="function")throw TypeError("Function expected");return N}var H=G.kind,z=H==="getter"?"get":H==="setter"?"set":"value",U=!J&&Z?G.static?Z:Z.prototype:null,B=J||(U?Object.getOwnPropertyDescriptor(U,G.name):{}),L,F=!1;for(var M=Y.length-1;M>=0;M--){var K={};for(var $ in G)K[$]=$==="access"?{}:G[$];for(var $ in G.access)K.access[$]=G.access[$];K.addInitializer=function(N){if(F)throw TypeError("Cannot add initializers after decoration has completed");X.push(W(N||null))};var V=(0,Y[M])(H==="accessor"?{get:B.get,set:B.set}:B[z],K);if(H==="accessor"){if(V===void 0)continue;if(V===null||typeof V!=="object")throw TypeError("Object expected");if(L=W(V.get))B.get=L;if(L=W(V.set))B.set=L;if(L=W(V.init))Q.unshift(L)}else if(L=W(V))if(H==="field")Q.unshift(L);else B[z]=L}if(U)Object.defineProperty(U,G.name,B);F=!0}function vY(Z,J,Y){var G=arguments.length>2;for(var Q=0;Q<J.length;Q++)Y=G?J[Q].call(Z,Y):J[Q].call(Z);return G?Y:void 0}function hY(Z){return typeof Z==="symbol"?Z:"".concat(Z)}function bY(Z,J,Y){if(typeof J==="symbol")J=J.description?"[".concat(J.description,"]"):"";return Object.defineProperty(Z,"name",{configurable:!0,value:Y?"".concat(Y," ",J):J})}function yY(Z,J){if(typeof Reflect==="object"&&typeof Reflect.metadata==="function")return Reflect.metadata(Z,J)}function gY(Z,J,Y,G){function Q(X){return X instanceof Y?X:new Y(function(W){W(X)})}return new(Y||(Y=Promise))(function(X,W){function H(B){try{U(G.next(B))}catch(L){W(L)}}function z(B){try{U(G.throw(B))}catch(L){W(L)}}function U(B){B.done?X(B.value):Q(B.value).then(H,z)}U((G=G.apply(Z,J||[])).next())})}function mY(Z,J){var Y={label:0,sent:function(){if(X[0]&1)throw X[1];return X[1]},trys:[],ops:[]},G,Q,X,W=Object.create((typeof Iterator==="function"?Iterator:Object).prototype);return W.next=H(0),W.throw=H(1),W.return=H(2),typeof Symbol==="function"&&(W[Symbol.iterator]=function(){return this}),W;function H(U){return function(B){return z([U,B])}}function z(U){if(G)throw TypeError("Generator is already executing.");while(W&&(W=0,U[0]&&(Y=0)),Y)try{if(G=1,Q&&(X=U[0]&2?Q.return:U[0]?Q.throw||((X=Q.return)&&X.call(Q),0):Q.next)&&!(X=X.call(Q,U[1])).done)return X;if(Q=0,X)U=[U[0]&2,X.value];switch(U[0]){case 0:case 1:X=U;break;case 4:return Y.label++,{value:U[1],done:!1};case 5:Y.label++,Q=U[1],U=[0];continue;case 7:U=Y.ops.pop(),Y.trys.pop();continue;default:if((X=Y.trys,!(X=X.length>0&&X[X.length-1]))&&(U[0]===6||U[0]===2)){Y=0;continue}if(U[0]===3&&(!X||U[1]>X[0]&&U[1]<X[3])){Y.label=U[1];break}if(U[0]===6&&Y.label<X[1]){Y.label=X[1],X=U;break}if(X&&Y.label<X[2]){Y.label=X[2],Y.ops.push(U);break}if(X[2])Y.ops.pop();Y.trys.pop();continue}U=J.call(Z,Y)}catch(B){U=[6,B],Q=0}finally{G=X=0}if(U[0]&5)throw U[1];return{value:U[0]?U[1]:void 0,done:!0}}}function uY(Z,J){for(var Y in Z)if(Y!=="default"&&!Object.prototype.hasOwnProperty.call(J,Y))Y6(J,Z,Y)}function J6(Z){var J=typeof Symbol==="function"&&Symbol.iterator,Y=J&&Z[J],G=0;if(Y)return Y.call(Z);if(Z&&typeof Z.length==="number")return{next:function(){if(Z&&G>=Z.length)Z=void 0;return{value:Z&&Z[G++],done:!Z}}};throw TypeError(J?"Object is not iterable.":"Symbol.iterator is not defined.")}function L9(Z,J){var Y=typeof Symbol==="function"&&Z[Symbol.iterator];if(!Y)return Z;var G=Y.call(Z),Q,X=[],W;try{while((J===void 0||J-- >0)&&!(Q=G.next()).done)X.push(Q.value)}catch(H){W={error:H}}finally{try{if(Q&&!Q.done&&(Y=G.return))Y.call(G)}finally{if(W)throw W.error}}return X}function dY(){for(var Z=[],J=0;J<arguments.length;J++)Z=Z.concat(L9(arguments[J]));return Z}function cY(){for(var Z=0,J=0,Y=arguments.length;J<Y;J++)Z+=arguments[J].length;for(var G=Array(Z),Q=0,J=0;J<Y;J++)for(var X=arguments[J],W=0,H=X.length;W<H;W++,Q++)G[Q]=X[W];return G}function pY(Z,J,Y){if(Y||arguments.length===2){for(var G=0,Q=J.length,X;G<Q;G++)if(X||!(G in J)){if(!X)X=Array.prototype.slice.call(J,0,G);X[G]=J[G]}}return Z.concat(X||Array.prototype.slice.call(J))}function q0(Z){return this instanceof q0?(this.v=Z,this):new q0(Z)}function lY(Z,J,Y){if(!Symbol.asyncIterator)throw TypeError("Symbol.asyncIterator is not defined.");var G=Y.apply(Z,J||[]),Q,X=[];return Q=Object.create((typeof AsyncIterator==="function"?AsyncIterator:Object).prototype),H("next"),H("throw"),H("return",W),Q[Symbol.asyncIterator]=function(){return this},Q;function W(M){return function(K){return Promise.resolve(K).then(M,L)}}function H(M,K){if(G[M]){if(Q[M]=function($){return new Promise(function(V,N){X.push([M,$,V,N])>1||z(M,$)})},K)Q[M]=K(Q[M])}}function z(M,K){try{U(G[M](K))}catch($){F(X[0][3],$)}}function U(M){M.value instanceof q0?Promise.resolve(M.value.v).then(B,L):F(X[0][2],M)}function B(M){z("next",M)}function L(M){z("throw",M)}function F(M,K){if(M(K),X.shift(),X.length)z(X[0][0],X[0][1])}}function iY(Z){var J,Y;return J={},G("next"),G("throw",function(Q){throw Q}),G("return"),J[Symbol.iterator]=function(){return this},J;function G(Q,X){J[Q]=Z[Q]?function(W){return(Y=!Y)?{value:q0(Z[Q](W)),done:!1}:X?X(W):W}:X}}function nY(Z){if(!Symbol.asyncIterator)throw TypeError("Symbol.asyncIterator is not defined.");var J=Z[Symbol.asyncIterator],Y;return J?J.call(Z):(Z=typeof J6==="function"?J6(Z):Z[Symbol.iterator](),Y={},G("next"),G("throw"),G("return"),Y[Symbol.asyncIterator]=function(){return this},Y);function G(X){Y[X]=Z[X]&&function(W){return new Promise(function(H,z){W=Z[X](W),Q(H,z,W.done,W.value)})}}function Q(X,W,H,z){Promise.resolve(z).then(function(U){X({value:U,done:H})},W)}}function oY(Z,J){if(Object.defineProperty)Object.defineProperty(Z,"raw",{value:J});else Z.raw=J;return Z}function aY(Z){if(Z&&Z.__esModule)return Z;var J={};if(Z!=null){for(var Y=K9(Z),G=0;G<Y.length;G++)if(Y[G]!=="default")Y6(J,Z,Y[G])}return OK(J,Z),J}function sY(Z){return Z&&Z.__esModule?Z:{default:Z}}function rY(Z,J,Y,G){if(Y==="a"&&!G)throw TypeError("Private accessor was defined without a getter");if(typeof J==="function"?Z!==J||!G:!J.has(Z))throw TypeError("Cannot read private member from an object whose class did not declare it");return Y==="m"?G:Y==="a"?G.call(Z):G?G.value:J.get(Z)}function tY(Z,J,Y,G,Q){if(G==="m")throw TypeError("Private method is not writable");if(G==="a"&&!Q)throw TypeError("Private accessor was defined without a setter");if(typeof J==="function"?Z!==J||!Q:!J.has(Z))throw TypeError("Cannot write private member to an object whose class did not declare it");return G==="a"?Q.call(Z,Y):Q?Q.value=Y:J.set(Z,Y),Y}function eY(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 ZG(Z,J,Y){if(J!==null&&J!==void 0){if(typeof J!=="object"&&typeof J!=="function")throw TypeError("Object expected.");var G,Q;if(Y){if(!Symbol.asyncDispose)throw TypeError("Symbol.asyncDispose is not defined.");G=J[Symbol.asyncDispose]}if(G===void 0){if(!Symbol.dispose)throw TypeError("Symbol.dispose is not defined.");if(G=J[Symbol.dispose],Y)Q=G}if(typeof G!=="function")throw TypeError("Object not disposable.");if(Q)G=function(){try{Q.call(this)}catch(X){return Promise.reject(X)}};Z.stack.push({value:J,dispose:G,async:Y})}else if(Y)Z.stack.push({async:!0});return J}function JG(Z){function J(X){Z.error=Z.hasError?new VK(X,Z.error,"An error was suppressed during disposal."):X,Z.hasError=!0}var Y,G=0;function Q(){while(Y=Z.stack.pop())try{if(!Y.async&&G===1)return G=0,Z.stack.push(Y),Promise.resolve().then(Q);if(Y.dispose){var X=Y.dispose.call(Y.value);if(Y.async)return G|=2,Promise.resolve(X).then(Q,function(W){return J(W),Q()})}else G|=1}catch(W){J(W)}if(G===1)return Z.hasError?Promise.reject(Z.error):Promise.resolve();if(Z.hasError)throw Z.error}return Q()}function YG(Z,J){if(typeof Z==="string"&&/^\.\.?\//.test(Z))return Z.replace(/\.(tsx)$|((?:\.d)?)((?:\.[^./]+?)?)\.([cm]?)ts$/i,function(Y,G,Q,X,W){return G?J?".jsx":".js":Q&&(!X||!W)?Y:Q+X+"."+W.toLowerCase()+"js"});return Z}var B9=function(Z,J){return B9=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(Y,G){Y.__proto__=G}||function(Y,G){for(var Q in G)if(Object.prototype.hasOwnProperty.call(G,Q))Y[Q]=G[Q]},B9(Z,J)},Z6=function(){return Z6=Object.assign||function(J){for(var Y,G=1,Q=arguments.length;G<Q;G++){Y=arguments[G];for(var X in Y)if(Object.prototype.hasOwnProperty.call(Y,X))J[X]=Y[X]}return J},Z6.apply(this,arguments)},Y6,OK,K9=function(Z){return K9=Object.getOwnPropertyNames||function(J){var Y=[];for(var G in J)if(Object.prototype.hasOwnProperty.call(J,G))Y[Y.length]=G;return Y},K9(Z)},VK,IK;var QG=q7(()=>{Y6=Object.create?function(Z,J,Y,G){if(G===void 0)G=Y;var Q=Object.getOwnPropertyDescriptor(J,Y);if(!Q||("get"in Q?!J.__esModule:Q.writable||Q.configurable))Q={enumerable:!0,get:function(){return J[Y]}};Object.defineProperty(Z,G,Q)}:function(Z,J,Y,G){if(G===void 0)G=Y;Z[G]=J[Y]};OK=Object.create?function(Z,J){Object.defineProperty(Z,"default",{enumerable:!0,value:J})}:function(Z,J){Z.default=J};VK=typeof SuppressedError==="function"?SuppressedError:function(Z,J,Y){var G=Error(Y);return G.name="SuppressedError",G.error=Z,G.suppressed=J,G};IK={__extends:fY,__assign:Z6,__rest:CY,__decorate:jY,__param:_Y,__esDecorate:kY,__runInitializers:vY,__propKey:hY,__setFunctionName:bY,__metadata:yY,__awaiter:gY,__generator:mY,__createBinding:Y6,__exportStar:uY,__values:J6,__read:L9,__spread:dY,__spreadArrays:cY,__spreadArray:pY,__await:q0,__asyncGenerator:lY,__asyncDelegator:iY,__asyncValues:nY,__makeTemplateObject:oY,__importStar:aY,__importDefault:sY,__classPrivateFieldGet:rY,__classPrivateFieldSet:tY,__classPrivateFieldIn:eY,__addDisposableResource:ZG,__disposeResources:JG,__rewriteRelativeImportExtension:YG}});var lG=A((HD,pG)=>{/*! Axios v1.13.4 Copyright (c) 2026 Matt Zabriskie and contributors */function NG(Z,J){return function(){return Z.apply(J,arguments)}}var{toString:qK}=Object.prototype,{getPrototypeOf:D9}=Object,{iterator:U6,toStringTag:AG}=Symbol,B6=((Z)=>(J)=>{let Y=qK.call(J);return Z[Y]||(Z[Y]=Y.slice(8,-1).toLowerCase())})(Object.create(null)),F1=(Z)=>{return Z=Z.toLowerCase(),(J)=>B6(J)===Z},K6=(Z)=>(J)=>typeof J===Z,{isArray:N0}=Array,D0=K6("undefined");function r0(Z){return Z!==null&&!D0(Z)&&Z.constructor!==null&&!D0(Z.constructor)&&Z1(Z.constructor.isBuffer)&&Z.constructor.isBuffer(Z)}var RG=F1("ArrayBuffer");function DK(Z){let J;if(typeof ArrayBuffer<"u"&&ArrayBuffer.isView)J=ArrayBuffer.isView(Z);else J=Z&&Z.buffer&&RG(Z.buffer);return J}var NK=K6("string"),Z1=K6("function"),PG=K6("number"),t0=(Z)=>Z!==null&&typeof Z==="object",AK=(Z)=>Z===!0||Z===!1,Q6=(Z)=>{if(B6(Z)!=="object")return!1;let J=D9(Z);return(J===null||J===Object.prototype||Object.getPrototypeOf(J)===null)&&!(AG in Z)&&!(U6 in Z)},RK=(Z)=>{if(!t0(Z)||r0(Z))return!1;try{return Object.keys(Z).length===0&&Object.getPrototypeOf(Z)===Object.prototype}catch(J){return!1}},PK=F1("Date"),TK=F1("File"),wK=F1("Blob"),EK=F1("FileList"),SK=(Z)=>t0(Z)&&Z1(Z.pipe),xK=(Z)=>{let J;return Z&&(typeof FormData==="function"&&Z instanceof FormData||Z1(Z.append)&&((J=B6(Z))==="formdata"||J==="object"&&Z1(Z.toString)&&Z.toString()==="[object FormData]"))},fK=F1("URLSearchParams"),[CK,jK,_K,kK]=["ReadableStream","Request","Response","Headers"].map(F1),vK=(Z)=>Z.trim?Z.trim():Z.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,"");function e0(Z,J,{allOwnKeys:Y=!1}={}){if(Z===null||typeof Z>"u")return;let G,Q;if(typeof Z!=="object")Z=[Z];if(N0(Z))for(G=0,Q=Z.length;G<Q;G++)J.call(null,Z[G],G,Z);else{if(r0(Z))return;let X=Y?Object.getOwnPropertyNames(Z):Object.keys(Z),W=X.length,H;for(G=0;G<W;G++)H=X[G],J.call(null,Z[H],H,Z)}}function TG(Z,J){if(r0(Z))return null;J=J.toLowerCase();let Y=Object.keys(Z),G=Y.length,Q;while(G-- >0)if(Q=Y[G],J===Q.toLowerCase())return Q;return null}var G0=(()=>{if(typeof globalThis<"u")return globalThis;return typeof self<"u"?self:typeof window<"u"?window:global})(),wG=(Z)=>!D0(Z)&&Z!==G0;function O9(){let{caseless:Z,skipUndefined:J}=wG(this)&&this||{},Y={},G=(Q,X)=>{let W=Z&&TG(Y,X)||X;if(Q6(Y[W])&&Q6(Q))Y[W]=O9(Y[W],Q);else if(Q6(Q))Y[W]=O9({},Q);else if(N0(Q))Y[W]=Q.slice();else if(!J||!D0(Q))Y[W]=Q};for(let Q=0,X=arguments.length;Q<X;Q++)arguments[Q]&&e0(arguments[Q],G);return Y}var hK=(Z,J,Y,{allOwnKeys:G}={})=>{return e0(J,(Q,X)=>{if(Y&&Z1(Q))Object.defineProperty(Z,X,{value:NG(Q,Y),writable:!0,enumerable:!0,configurable:!0});else Object.defineProperty(Z,X,{value:Q,writable:!0,enumerable:!0,configurable:!0})},{allOwnKeys:G}),Z},bK=(Z)=>{if(Z.charCodeAt(0)===65279)Z=Z.slice(1);return Z},yK=(Z,J,Y,G)=>{Z.prototype=Object.create(J.prototype,G),Object.defineProperty(Z.prototype,"constructor",{value:Z,writable:!0,enumerable:!1,configurable:!0}),Object.defineProperty(Z,"super",{value:J.prototype}),Y&&Object.assign(Z.prototype,Y)},gK=(Z,J,Y,G)=>{let Q,X,W,H={};if(J=J||{},Z==null)return J;do{Q=Object.getOwnPropertyNames(Z),X=Q.length;while(X-- >0)if(W=Q[X],(!G||G(W,Z,J))&&!H[W])J[W]=Z[W],H[W]=!0;Z=Y!==!1&&D9(Z)}while(Z&&(!Y||Y(Z,J))&&Z!==Object.prototype);return J},mK=(Z,J,Y)=>{if(Z=String(Z),Y===void 0||Y>Z.length)Y=Z.length;Y-=J.length;let G=Z.indexOf(J,Y);return G!==-1&&G===Y},uK=(Z)=>{if(!Z)return null;if(N0(Z))return Z;let J=Z.length;if(!PG(J))return null;let Y=Array(J);while(J-- >0)Y[J]=Z[J];return Y},dK=((Z)=>{return(J)=>{return Z&&J instanceof Z}})(typeof Uint8Array<"u"&&D9(Uint8Array)),cK=(Z,J)=>{let G=(Z&&Z[U6]).call(Z),Q;while((Q=G.next())&&!Q.done){let X=Q.value;J.call(Z,X[0],X[1])}},pK=(Z,J)=>{let Y,G=[];while((Y=Z.exec(J))!==null)G.push(Y);return G},lK=F1("HTMLFormElement"),iK=(Z)=>{return Z.toLowerCase().replace(/[-_\s]([a-z\d])(\w*)/g,function(Y,G,Q){return G.toUpperCase()+Q})},XG=(({hasOwnProperty:Z})=>(J,Y)=>Z.call(J,Y))(Object.prototype),nK=F1("RegExp"),EG=(Z,J)=>{let Y=Object.getOwnPropertyDescriptors(Z),G={};e0(Y,(Q,X)=>{let W;if((W=J(Q,X,Z))!==!1)G[X]=W||Q}),Object.defineProperties(Z,G)},oK=(Z)=>{EG(Z,(J,Y)=>{if(Z1(Z)&&["arguments","caller","callee"].indexOf(Y)!==-1)return!1;let G=Z[Y];if(!Z1(G))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 '"+Y+"'")}})},aK=(Z,J)=>{let Y={},G=(Q)=>{Q.forEach((X)=>{Y[X]=!0})};return N0(Z)?G(Z):G(String(Z).split(J)),Y},sK=()=>{},rK=(Z,J)=>{return Z!=null&&Number.isFinite(Z=+Z)?Z:J};function tK(Z){return!!(Z&&Z1(Z.append)&&Z[AG]==="FormData"&&Z[U6])}var eK=(Z)=>{let J=[,,,,,,,,,,],Y=(G,Q)=>{if(t0(G)){if(J.indexOf(G)>=0)return;if(r0(G))return G;if(!("toJSON"in G)){J[Q]=G;let X=N0(G)?[]:{};return e0(G,(W,H)=>{let z=Y(W,Q+1);!D0(z)&&(X[H]=z)}),J[Q]=void 0,X}}return G};return Y(Z,0)},ZL=F1("AsyncFunction"),JL=(Z)=>Z&&(t0(Z)||Z1(Z))&&Z1(Z.then)&&Z1(Z.catch),SG=((Z,J)=>{if(Z)return setImmediate;return J?((Y,G)=>{return G0.addEventListener("message",({source:Q,data:X})=>{if(Q===G0&&X===Y)G.length&&G.shift()()},!1),(Q)=>{G.push(Q),G0.postMessage(Y,"*")}})(`axios@${Math.random()}`,[]):(Y)=>setTimeout(Y)})(typeof setImmediate==="function",Z1(G0.postMessage)),YL=typeof queueMicrotask<"u"?queueMicrotask.bind(G0):typeof process<"u"&&process.nextTick||SG,GL=(Z)=>Z!=null&&Z1(Z[U6]),I={isArray:N0,isArrayBuffer:RG,isBuffer:r0,isFormData:xK,isArrayBufferView:DK,isString:NK,isNumber:PG,isBoolean:AK,isObject:t0,isPlainObject:Q6,isEmptyObject:RK,isReadableStream:CK,isRequest:jK,isResponse:_K,isHeaders:kK,isUndefined:D0,isDate:PK,isFile:TK,isBlob:wK,isRegExp:nK,isFunction:Z1,isStream:SK,isURLSearchParams:fK,isTypedArray:dK,isFileList:EK,forEach:e0,merge:O9,extend:hK,trim:vK,stripBOM:bK,inherits:yK,toFlatObject:gK,kindOf:B6,kindOfTest:F1,endsWith:mK,toArray:uK,forEachEntry:cK,matchAll:pK,isHTMLForm:lK,hasOwnProperty:XG,hasOwnProp:XG,reduceDescriptors:EG,freezeMethods:oK,toObjectSet:aK,toCamelCase:iK,noop:sK,toFiniteNumber:rK,findKey:TG,global:G0,isContextDefined:wG,isSpecCompliantForm:tK,toJSONObject:eK,isAsyncFn:ZL,isThenable:JL,setImmediate:SG,asap:YL,isIterable:GL};class s extends Error{static from(Z,J,Y,G,Q,X){let W=new s(Z.message,J||Z.code,Y,G,Q);return W.cause=Z,W.name=Z.name,X&&Object.assign(W,X),W}constructor(Z,J,Y,G,Q){super(Z);if(this.name="AxiosError",this.isAxiosError=!0,J&&(this.code=J),Y&&(this.config=Y),G&&(this.request=G),Q)this.response=Q,this.status=Q.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:I.toJSONObject(this.config),code:this.code,status:this.status}}}s.ERR_BAD_OPTION_VALUE="ERR_BAD_OPTION_VALUE";s.ERR_BAD_OPTION="ERR_BAD_OPTION";s.ECONNABORTED="ECONNABORTED";s.ETIMEDOUT="ETIMEDOUT";s.ERR_NETWORK="ERR_NETWORK";s.ERR_FR_TOO_MANY_REDIRECTS="ERR_FR_TOO_MANY_REDIRECTS";s.ERR_DEPRECATED="ERR_DEPRECATED";s.ERR_BAD_RESPONSE="ERR_BAD_RESPONSE";s.ERR_BAD_REQUEST="ERR_BAD_REQUEST";s.ERR_CANCELED="ERR_CANCELED";s.ERR_NOT_SUPPORT="ERR_NOT_SUPPORT";s.ERR_INVALID_URL="ERR_INVALID_URL";var x=s,QL=null;function V9(Z){return I.isPlainObject(Z)||I.isArray(Z)}function xG(Z){return I.endsWith(Z,"[]")?Z.slice(0,-2):Z}function WG(Z,J,Y){if(!Z)return J;return Z.concat(J).map(function(Q,X){return Q=xG(Q),!Y&&X?"["+Q+"]":Q}).join(Y?".":"")}function XL(Z){return I.isArray(Z)&&!Z.some(V9)}var WL=I.toFlatObject(I,{},null,function(J){return/^is[A-Z]/.test(J)});function L6(Z,J,Y){if(!I.isObject(Z))throw TypeError("target must be an object");J=J||new FormData,Y=I.toFlatObject(Y,{metaTokens:!0,dots:!1,indexes:!1},!1,function($,V){return!I.isUndefined(V[$])});let G=Y.metaTokens,Q=Y.visitor||B,X=Y.dots,W=Y.indexes,z=(Y.Blob||typeof Blob<"u"&&Blob)&&I.isSpecCompliantForm(J);if(!I.isFunction(Q))throw TypeError("visitor must be a function");function U(K){if(K===null)return"";if(I.isDate(K))return K.toISOString();if(I.isBoolean(K))return K.toString();if(!z&&I.isBlob(K))throw new x("Blob is not supported. Use a Buffer instead.");if(I.isArrayBuffer(K)||I.isTypedArray(K))return z&&typeof Blob==="function"?new Blob([K]):Buffer.from(K);return K}function B(K,$,V){let N=K;if(K&&!V&&typeof K==="object"){if(I.endsWith($,"{}"))$=G?$:$.slice(0,-2),K=JSON.stringify(K);else if(I.isArray(K)&&XL(K)||(I.isFileList(K)||I.endsWith($,"[]"))&&(N=I.toArray(K)))return $=xG($),N.forEach(function(D,q){!(I.isUndefined(D)||D===null)&&J.append(W===!0?WG([$],q,X):W===null?$:$+"[]",U(D))}),!1}if(V9(K))return!0;return J.append(WG(V,$,X),U(K)),!1}let L=[],F=Object.assign(WL,{defaultVisitor:B,convertValue:U,isVisitable:V9});function M(K,$){if(I.isUndefined(K))return;if(L.indexOf(K)!==-1)throw Error("Circular reference detected in "+$.join("."));L.push(K),I.forEach(K,function(N,P){if((!(I.isUndefined(N)||N===null)&&Q.call(J,N,I.isString(P)?P.trim():P,$,F))===!0)M(N,$?$.concat(P):[P])}),L.pop()}if(!I.isObject(Z))throw TypeError("data must be an object");return M(Z),J}function HG(Z){let J={"!":"%21","'":"%27","(":"%28",")":"%29","~":"%7E","%20":"+","%00":"\x00"};return encodeURIComponent(Z).replace(/[!'()~]|%20|%00/g,function(G){return J[G]})}function N9(Z,J){this._pairs=[],Z&&L6(Z,this,J)}var fG=N9.prototype;fG.append=function(J,Y){this._pairs.push([J,Y])};fG.toString=function(J){let Y=J?function(G){return J.call(this,G,HG)}:HG;return this._pairs.map(function(Q){return Y(Q[0])+"="+Y(Q[1])},"").join("&")};function HL(Z){return encodeURIComponent(Z).replace(/%3A/gi,":").replace(/%24/g,"$").replace(/%2C/gi,",").replace(/%20/g,"+")}function CG(Z,J,Y){if(!J)return Z;let G=Y&&Y.encode||HL,Q=I.isFunction(Y)?{serialize:Y}:Y,X=Q&&Q.serialize,W;if(X)W=X(J,Q);else W=I.isURLSearchParams(J)?J.toString():new N9(J,Q).toString(G);if(W){let H=Z.indexOf("#");if(H!==-1)Z=Z.slice(0,H);Z+=(Z.indexOf("?")===-1?"?":"&")+W}return Z}class jG{constructor(){this.handlers=[]}use(Z,J,Y){return this.handlers.push({fulfilled:Z,rejected:J,synchronous:Y?Y.synchronous:!1,runWhen:Y?Y.runWhen:null}),this.handlers.length-1}eject(Z){if(this.handlers[Z])this.handlers[Z]=null}clear(){if(this.handlers)this.handlers=[]}forEach(Z){I.forEach(this.handlers,function(Y){if(Y!==null)Z(Y)})}}var zG=jG,_G={silentJSONParsing:!0,forcedJSONParsing:!0,clarifyTimeoutError:!1},zL=typeof URLSearchParams<"u"?URLSearchParams:N9,UL=typeof FormData<"u"?FormData:null,BL=typeof Blob<"u"?Blob:null,KL={isBrowser:!0,classes:{URLSearchParams:zL,FormData:UL,Blob:BL},protocols:["http","https","file","blob","url","data"]},A9=typeof window<"u"&&typeof document<"u",I9=typeof navigator==="object"&&navigator||void 0,LL=A9&&(!I9||["ReactNative","NativeScript","NS"].indexOf(I9.product)<0),ML=(()=>{return typeof WorkerGlobalScope<"u"&&self instanceof WorkerGlobalScope&&typeof self.importScripts==="function"})(),$L=A9&&window.location.href||"http://localhost",FL=Object.freeze({__proto__:null,hasBrowserEnv:A9,hasStandardBrowserWebWorkerEnv:ML,hasStandardBrowserEnv:LL,navigator:I9,origin:$L}),n={...FL,...KL};function OL(Z,J){return L6(Z,new n.classes.URLSearchParams,{visitor:function(Y,G,Q,X){if(n.isNode&&I.isBuffer(Y))return this.append(G,Y.toString("base64")),!1;return X.defaultVisitor.apply(this,arguments)},...J})}function VL(Z){return I.matchAll(/\w+|\[(\w*)]/g,Z).map((J)=>{return J[0]==="[]"?"":J[1]||J[0]})}function IL(Z){let J={},Y=Object.keys(Z),G,Q=Y.length,X;for(G=0;G<Q;G++)X=Y[G],J[X]=Z[X];return J}function kG(Z){function J(Y,G,Q,X){let W=Y[X++];if(W==="__proto__")return!0;let H=Number.isFinite(+W),z=X>=Y.length;if(W=!W&&I.isArray(Q)?Q.length:W,z){if(I.hasOwnProp(Q,W))Q[W]=[Q[W],G];else Q[W]=G;return!H}if(!Q[W]||!I.isObject(Q[W]))Q[W]=[];if(J(Y,G,Q[W],X)&&I.isArray(Q[W]))Q[W]=IL(Q[W]);return!H}if(I.isFormData(Z)&&I.isFunction(Z.entries)){let Y={};return I.forEachEntry(Z,(G,Q)=>{J(VL(G),Q,Y,0)}),Y}return null}function qL(Z,J,Y){if(I.isString(Z))try{return(J||JSON.parse)(Z),I.trim(Z)}catch(G){if(G.name!=="SyntaxError")throw G}return(Y||JSON.stringify)(Z)}var R9={transitional:_G,adapter:["xhr","http","fetch"],transformRequest:[function(J,Y){let G=Y.getContentType()||"",Q=G.indexOf("application/json")>-1,X=I.isObject(J);if(X&&I.isHTMLForm(J))J=new FormData(J);if(I.isFormData(J))return Q?JSON.stringify(kG(J)):J;if(I.isArrayBuffer(J)||I.isBuffer(J)||I.isStream(J)||I.isFile(J)||I.isBlob(J)||I.isReadableStream(J))return J;if(I.isArrayBufferView(J))return J.buffer;if(I.isURLSearchParams(J))return Y.setContentType("application/x-www-form-urlencoded;charset=utf-8",!1),J.toString();let H;if(X){if(G.indexOf("application/x-www-form-urlencoded")>-1)return OL(J,this.formSerializer).toString();if((H=I.isFileList(J))||G.indexOf("multipart/form-data")>-1){let z=this.env&&this.env.FormData;return L6(H?{"files[]":J}:J,z&&new z,this.formSerializer)}}if(X||Q)return Y.setContentType("application/json",!1),qL(J);return J}],transformResponse:[function(J){let Y=this.transitional||R9.transitional,G=Y&&Y.forcedJSONParsing,Q=this.responseType==="json";if(I.isResponse(J)||I.isReadableStream(J))return J;if(J&&I.isString(J)&&(G&&!this.responseType||Q)){let W=!(Y&&Y.silentJSONParsing)&&Q;try{return JSON.parse(J,this.parseReviver)}catch(H){if(W){if(H.name==="SyntaxError")throw x.from(H,x.ERR_BAD_RESPONSE,this,null,this.response);throw H}}}return J}],timeout:0,xsrfCookieName:"XSRF-TOKEN",xsrfHeaderName:"X-XSRF-TOKEN",maxContentLength:-1,maxBodyLength:-1,env:{FormData:n.classes.FormData,Blob:n.classes.Blob},validateStatus:function(J){return J>=200&&J<300},headers:{common:{Accept:"application/json, text/plain, */*","Content-Type":void 0}}};I.forEach(["delete","get","head","post","put","patch"],(Z)=>{R9.headers[Z]={}});var P9=R9,DL=I.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"]),NL=(Z)=>{let J={},Y,G,Q;return Z&&Z.split(`
|
|
10
|
-
`).forEach(function(W){if(Q=W.indexOf(":"),Y=W.substring(0,Q).trim().toLowerCase(),G=W.substring(Q+1).trim(),!Y||J[Y]&&
|
|
11
|
-
`)}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 Y=new this(Z);return J.forEach((G)=>Y.set(G)),Y}static accessor(Z){let Y=(this[UG]=this[UG]={accessors:{}}).accessors,G=this.prototype;function Q(X){let W=a0(X);if(!Y[W])TL(G,X),Y[W]=!0}return I.isArray(Z)?Z.forEach(Q):Q(Z),this}}Z5.accessor(["Content-Type","Content-Length","Accept","Accept-Encoding","User-Agent","Authorization"]);I.reduceDescriptors(Z5.prototype,({value:Z},J)=>{let Y=J[0].toUpperCase()+J.slice(1);return{get:()=>Z,set(G){this[Y]=G}}});I.freezeMethods(Z5);var $1=Z5;function $9(Z,J){let Y=this||P9,G=J||Y,Q=$1.from(G.headers),X=G.data;return I.forEach(Z,function(H){X=H.call(Y,X,Q.normalize(),J?J.status:void 0)}),Q.normalize(),X}function vG(Z){return!!(Z&&Z.__CANCEL__)}class hG extends x{constructor(Z,J,Y){super(Z==null?"canceled":Z,x.ERR_CANCELED,J,Y);this.name="CanceledError",this.__CANCEL__=!0}}var J5=hG;function bG(Z,J,Y){let G=Y.config.validateStatus;if(!Y.status||!G||G(Y.status))Z(Y);else J(new x("Request failed with status code "+Y.status,[x.ERR_BAD_REQUEST,x.ERR_BAD_RESPONSE][Math.floor(Y.status/100)-4],Y.config,Y.request,Y))}function wL(Z){let J=/^([-+\w]{1,25})(:?\/\/|:)/.exec(Z);return J&&J[1]||""}function EL(Z,J){Z=Z||10;let Y=Array(Z),G=Array(Z),Q=0,X=0,W;return J=J!==void 0?J:1000,function(z){let U=Date.now(),B=G[X];if(!W)W=U;Y[Q]=z,G[Q]=U;let L=X,F=0;while(L!==Q)F+=Y[L++],L=L%Z;if(Q=(Q+1)%Z,Q===X)X=(X+1)%Z;if(U-W<J)return;let M=B&&U-B;return M?Math.round(F*1000/M):void 0}}function SL(Z,J){let Y=0,G=1000/J,Q,X,W=(U,B=Date.now())=>{if(Y=B,Q=null,X)clearTimeout(X),X=null;Z(...U)};return[(...U)=>{let B=Date.now(),L=B-Y;if(L>=G)W(U,B);else if(Q=U,!X)X=setTimeout(()=>{X=null,W(Q)},G-L)},()=>Q&&W(Q)]}var z6=(Z,J,Y=3)=>{let G=0,Q=EL(50,250);return SL((X)=>{let W=X.loaded,H=X.lengthComputable?X.total:void 0,z=W-G,U=Q(z),B=W<=H;G=W;let L={loaded:W,total:H,progress:H?W/H:void 0,bytes:z,rate:U?U:void 0,estimated:U&&H&&B?(H-W)/U:void 0,event:X,lengthComputable:H!=null,[J?"download":"upload"]:!0};Z(L)},Y)},BG=(Z,J)=>{let Y=Z!=null;return[(G)=>J[0]({lengthComputable:Y,total:Z,loaded:G}),J[1]]},KG=(Z)=>(...J)=>I.asap(()=>Z(...J)),xL=n.hasStandardBrowserEnv?((Z,J)=>(Y)=>{return Y=new URL(Y,n.origin),Z.protocol===Y.protocol&&Z.host===Y.host&&(J||Z.port===Y.port)})(new URL(n.origin),n.navigator&&/(msie|trident)/i.test(n.navigator.userAgent)):()=>!0,fL=n.hasStandardBrowserEnv?{write(Z,J,Y,G,Q,X,W){if(typeof document>"u")return;let H=[`${Z}=${encodeURIComponent(J)}`];if(I.isNumber(Y))H.push(`expires=${new Date(Y).toUTCString()}`);if(I.isString(G))H.push(`path=${G}`);if(I.isString(Q))H.push(`domain=${Q}`);if(X===!0)H.push("secure");if(I.isString(W))H.push(`SameSite=${W}`);document.cookie=H.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 CL(Z){return/^([a-z][a-z\d+\-.]*:)?\/\//i.test(Z)}function jL(Z,J){return J?Z.replace(/\/?\/$/,"")+"/"+J.replace(/^\/+/,""):Z}function yG(Z,J,Y){let G=!CL(J);if(Z&&(G||Y==!1))return jL(Z,J);return J}var LG=(Z)=>Z instanceof $1?{...Z}:Z;function Q0(Z,J){J=J||{};let Y={};function G(U,B,L,F){if(I.isPlainObject(U)&&I.isPlainObject(B))return I.merge.call({caseless:F},U,B);else if(I.isPlainObject(B))return I.merge({},B);else if(I.isArray(B))return B.slice();return B}function Q(U,B,L,F){if(!I.isUndefined(B))return G(U,B,L,F);else if(!I.isUndefined(U))return G(void 0,U,L,F)}function X(U,B){if(!I.isUndefined(B))return G(void 0,B)}function W(U,B){if(!I.isUndefined(B))return G(void 0,B);else if(!I.isUndefined(U))return G(void 0,U)}function H(U,B,L){if(L in J)return G(U,B);else if(L in Z)return G(void 0,U)}let z={url:X,method:X,data:X,baseURL:W,transformRequest:W,transformResponse:W,paramsSerializer:W,timeout:W,timeoutMessage:W,withCredentials:W,withXSRFToken:W,adapter:W,responseType:W,xsrfCookieName:W,xsrfHeaderName:W,onUploadProgress:W,onDownloadProgress:W,decompress:W,maxContentLength:W,maxBodyLength:W,beforeRedirect:W,transport:W,httpAgent:W,httpsAgent:W,cancelToken:W,socketPath:W,responseEncoding:W,validateStatus:H,headers:(U,B,L)=>Q(LG(U),LG(B),L,!0)};return I.forEach(Object.keys({...Z,...J}),function(B){let L=z[B]||Q,F=L(Z[B],J[B],B);I.isUndefined(F)&&L!==H||(Y[B]=F)}),Y}var gG=(Z)=>{let J=Q0({},Z),{data:Y,withXSRFToken:G,xsrfHeaderName:Q,xsrfCookieName:X,headers:W,auth:H}=J;if(J.headers=W=$1.from(W),J.url=CG(yG(J.baseURL,J.url,J.allowAbsoluteUrls),Z.params,Z.paramsSerializer),H)W.set("Authorization","Basic "+btoa((H.username||"")+":"+(H.password?unescape(encodeURIComponent(H.password)):"")));if(I.isFormData(Y)){if(n.hasStandardBrowserEnv||n.hasStandardBrowserWebWorkerEnv)W.setContentType(void 0);else if(I.isFunction(Y.getHeaders)){let z=Y.getHeaders(),U=["content-type","content-length"];Object.entries(z).forEach(([B,L])=>{if(U.includes(B.toLowerCase()))W.set(B,L)})}}if(n.hasStandardBrowserEnv){if(G&&I.isFunction(G)&&(G=G(J)),G||G!==!1&&xL(J.url)){let z=Q&&X&&fL.read(X);if(z)W.set(Q,z)}}return J},_L=typeof XMLHttpRequest<"u",kL=_L&&function(Z){return new Promise(function(Y,G){let Q=gG(Z),X=Q.data,W=$1.from(Q.headers).normalize(),{responseType:H,onUploadProgress:z,onDownloadProgress:U}=Q,B,L,F,M,K;function $(){M&&M(),K&&K(),Q.cancelToken&&Q.cancelToken.unsubscribe(B),Q.signal&&Q.signal.removeEventListener("abort",B)}let V=new XMLHttpRequest;V.open(Q.method.toUpperCase(),Q.url,!0),V.timeout=Q.timeout;function N(){if(!V)return;let D=$1.from("getAllResponseHeaders"in V&&V.getAllResponseHeaders()),T={data:!H||H==="text"||H==="json"?V.responseText:V.response,status:V.status,statusText:V.statusText,headers:D,config:Z,request:V};bG(function(m){Y(m),$()},function(m){G(m),$()},T),V=null}if("onloadend"in V)V.onloadend=N;else V.onreadystatechange=function(){if(!V||V.readyState!==4)return;if(V.status===0&&!(V.responseURL&&V.responseURL.indexOf("file:")===0))return;setTimeout(N)};if(V.onabort=function(){if(!V)return;G(new x("Request aborted",x.ECONNABORTED,Z,V)),V=null},V.onerror=function(q){let T=q&&q.message?q.message:"Network Error",f=new x(T,x.ERR_NETWORK,Z,V);f.event=q||null,G(f),V=null},V.ontimeout=function(){let q=Q.timeout?"timeout of "+Q.timeout+"ms exceeded":"timeout exceeded",T=Q.transitional||_G;if(Q.timeoutErrorMessage)q=Q.timeoutErrorMessage;G(new x(q,T.clarifyTimeoutError?x.ETIMEDOUT:x.ECONNABORTED,Z,V)),V=null},X===void 0&&W.setContentType(null),"setRequestHeader"in V)I.forEach(W.toJSON(),function(q,T){V.setRequestHeader(T,q)});if(!I.isUndefined(Q.withCredentials))V.withCredentials=!!Q.withCredentials;if(H&&H!=="json")V.responseType=Q.responseType;if(U)[F,K]=z6(U,!0),V.addEventListener("progress",F);if(z&&V.upload)[L,M]=z6(z),V.upload.addEventListener("progress",L),V.upload.addEventListener("loadend",M);if(Q.cancelToken||Q.signal){if(B=(D)=>{if(!V)return;G(!D||D.type?new J5(null,Z,V):D),V.abort(),V=null},Q.cancelToken&&Q.cancelToken.subscribe(B),Q.signal)Q.signal.aborted?B():Q.signal.addEventListener("abort",B)}let P=wL(Q.url);if(P&&n.protocols.indexOf(P)===-1){G(new x("Unsupported protocol "+P+":",x.ERR_BAD_REQUEST,Z));return}V.send(X||null)})},vL=(Z,J)=>{let{length:Y}=Z=Z?Z.filter(Boolean):[];if(J||Y){let G=new AbortController,Q,X=function(U){if(!Q){Q=!0,H();let B=U instanceof Error?U:this.reason;G.abort(B instanceof x?B:new J5(B instanceof Error?B.message:B))}},W=J&&setTimeout(()=>{W=null,X(new x(`timeout of ${J}ms exceeded`,x.ETIMEDOUT))},J),H=()=>{if(Z)W&&clearTimeout(W),W=null,Z.forEach((U)=>{U.unsubscribe?U.unsubscribe(X):U.removeEventListener("abort",X)}),Z=null};Z.forEach((U)=>U.addEventListener("abort",X));let{signal:z}=G;return z.unsubscribe=()=>I.asap(H),z}},hL=vL,bL=function*(Z,J){let Y=Z.byteLength;if(!J||Y<J){yield Z;return}let G=0,Q;while(G<Y)Q=G+J,yield Z.slice(G,Q),G=Q},yL=async function*(Z,J){for await(let Y of gL(Z))yield*bL(Y,J)},gL=async function*(Z){if(Z[Symbol.asyncIterator]){yield*Z;return}let J=Z.getReader();try{for(;;){let{done:Y,value:G}=await J.read();if(Y)break;yield G}}finally{await J.cancel()}},MG=(Z,J,Y,G)=>{let Q=yL(Z,J),X=0,W,H=(z)=>{if(!W)W=!0,G&&G(z)};return new ReadableStream({async pull(z){try{let{done:U,value:B}=await Q.next();if(U){H(),z.close();return}let L=B.byteLength;if(Y){let F=X+=L;Y(F)}z.enqueue(new Uint8Array(B))}catch(U){throw H(U),U}},cancel(z){return H(z),Q.return()}},{highWaterMark:2})},$G=65536,{isFunction:G6}=I,mL=(({Request:Z,Response:J})=>({Request:Z,Response:J}))(I.global),{ReadableStream:FG,TextEncoder:OG}=I.global,VG=(Z,...J)=>{try{return!!Z(...J)}catch(Y){return!1}},uL=(Z)=>{Z=I.merge.call({skipUndefined:!0},mL,Z);let{fetch:J,Request:Y,Response:G}=Z,Q=J?G6(J):typeof fetch==="function",X=G6(Y),W=G6(G);if(!Q)return!1;let H=Q&&G6(FG),z=Q&&(typeof OG==="function"?((K)=>($)=>K.encode($))(new OG):async(K)=>new Uint8Array(await new Y(K).arrayBuffer())),U=X&&H&&VG(()=>{let K=!1,$=new Y(n.origin,{body:new FG,method:"POST",get duplex(){return K=!0,"half"}}).headers.has("Content-Type");return K&&!$}),B=W&&H&&VG(()=>I.isReadableStream(new G("").body)),L={stream:B&&((K)=>K.body)};Q&&(()=>{["text","arrayBuffer","blob","formData","stream"].forEach((K)=>{!L[K]&&(L[K]=($,V)=>{let N=$&&$[K];if(N)return N.call($);throw new x(`Response type '${K}' is not supported`,x.ERR_NOT_SUPPORT,V)})})})();let F=async(K)=>{if(K==null)return 0;if(I.isBlob(K))return K.size;if(I.isSpecCompliantForm(K))return(await new Y(n.origin,{method:"POST",body:K}).arrayBuffer()).byteLength;if(I.isArrayBufferView(K)||I.isArrayBuffer(K))return K.byteLength;if(I.isURLSearchParams(K))K=K+"";if(I.isString(K))return(await z(K)).byteLength},M=async(K,$)=>{let V=I.toFiniteNumber(K.getContentLength());return V==null?F($):V};return async(K)=>{let{url:$,method:V,data:N,signal:P,cancelToken:D,timeout:q,onDownloadProgress:T,onUploadProgress:f,responseType:m,headers:o1,withCredentials:f1="same-origin",fetchOptions:C1}=gG(K),k=J||fetch;m=m?(m+"").toLowerCase():"text";let A1=hL([P,D&&D.toAbortSignal()],q),p=null,R1=A1&&A1.unsubscribe&&(()=>{A1.unsubscribe()}),O;try{if(f&&U&&V!=="get"&&V!=="head"&&(O=await M(o1,N))!==0){let _1=new Y($,{method:"POST",body:N,duplex:"half"}),H0;if(I.isFormData(N)&&(H0=_1.headers.get("content-type")))o1.setContentType(H0);if(_1.body){let[S6,$5]=BG(O,z6(KG(f)));N=MG(_1.body,$G,S6,$5)}}if(!I.isString(f1))f1=f1?"include":"omit";let z1=X&&"credentials"in Y.prototype,y={...C1,signal:A1,method:V.toUpperCase(),headers:o1.normalize().toJSON(),body:N,duplex:"half",credentials:z1?f1:void 0};p=X&&new Y($,y);let K1=await(X?k(p,C1):k($,y)),j1=B&&(m==="stream"||m==="response");if(B&&(T||j1&&R1)){let _1={};["status","statusText","headers"].forEach(($7)=>{_1[$7]=K1[$7]});let H0=I.toFiniteNumber(K1.headers.get("content-length")),[S6,$5]=T&&BG(H0,z6(KG(T),!0))||[];K1=new G(MG(K1.body,$G,S6,()=>{$5&&$5(),R1&&R1()}),_1)}m=m||"text";let P1=await L[I.findKey(L,m)||"text"](K1,K);return!j1&&R1&&R1(),await new Promise((_1,H0)=>{bG(_1,H0,{data:P1,headers:$1.from(K1.headers),status:K1.status,statusText:K1.statusText,config:K,request:p})})}catch(z1){if(R1&&R1(),z1&&z1.name==="TypeError"&&/Load failed|fetch/i.test(z1.message))throw Object.assign(new x("Network Error",x.ERR_NETWORK,K,p),{cause:z1.cause||z1});throw x.from(z1,z1&&z1.code,K,p)}}},dL=new Map,mG=(Z)=>{let J=Z&&Z.env||{},{fetch:Y,Request:G,Response:Q}=J,X=[G,Q,Y],W=X.length,H=W,z,U,B=dL;while(H--)z=X[H],U=B.get(z),U===void 0&&B.set(z,U=H?new Map:uL(J)),B=U;return U};mG();var T9={http:QL,xhr:kL,fetch:{get:mG}};I.forEach(T9,(Z,J)=>{if(Z){try{Object.defineProperty(Z,"name",{value:J})}catch(Y){}Object.defineProperty(Z,"adapterName",{value:J})}});var IG=(Z)=>`- ${Z}`,cL=(Z)=>I.isFunction(Z)||Z===null||Z===!1;function pL(Z,J){Z=I.isArray(Z)?Z:[Z];let{length:Y}=Z,G,Q,X={};for(let W=0;W<Y;W++){G=Z[W];let H;if(Q=G,!cL(G)){if(Q=T9[(H=String(G)).toLowerCase()],Q===void 0)throw new x(`Unknown adapter '${H}'`)}if(Q&&(I.isFunction(Q)||(Q=Q.get(J))))break;X[H||"#"+W]=Q}if(!Q){let W=Object.entries(X).map(([z,U])=>`adapter ${z} `+(U===!1?"is not supported by the environment":"is not available in the build")),H=Y?W.length>1?`since :
|
|
12
|
-
`+W.map(
|
|
13
|
-
`):" "+
|
|
14
|
-
`+Q}catch(X){}}throw Y}}_request(Z,J){if(typeof Z==="string")J=J||{},J.url=Z;else J=Z||{};J=Q0(this.defaults,J);let{transitional:Y,paramsSerializer:G,headers:Q}=J;if(Y!==void 0)W6.assertOptions(Y,{silentJSONParsing:q1.transitional(q1.boolean),forcedJSONParsing:q1.transitional(q1.boolean),clarifyTimeoutError:q1.transitional(q1.boolean)},!1);if(G!=null)if(I.isFunction(G))J.paramsSerializer={serialize:G};else W6.assertOptions(G,{encode:q1.function,serialize:q1.function},!0);if(J.allowAbsoluteUrls!==void 0);else if(this.defaults.allowAbsoluteUrls!==void 0)J.allowAbsoluteUrls=this.defaults.allowAbsoluteUrls;else J.allowAbsoluteUrls=!0;W6.assertOptions(J,{baseUrl:q1.spelling("baseURL"),withXsrfToken:q1.spelling("withXSRFToken")},!0),J.method=(J.method||this.defaults.method||"get").toLowerCase();let X=Q&&I.merge(Q.common,Q[J.method]);Q&&I.forEach(["delete","get","head","post","put","patch","common"],(M)=>{delete Q[M]}),J.headers=$1.concat(X,Q);let W=[],H=!0;this.interceptors.request.forEach(function(K){if(typeof K.runWhen==="function"&&K.runWhen(J)===!1)return;H=H&&K.synchronous,W.unshift(K.fulfilled,K.rejected)});let z=[];this.interceptors.response.forEach(function(K){z.push(K.fulfilled,K.rejected)});let U,B=0,L;if(!H){let M=[qG.bind(this),void 0];M.unshift(...W),M.push(...z),L=M.length,U=Promise.resolve(J);while(B<L)U=U.then(M[B++],M[B++]);return U}L=W.length;let F=J;while(B<L){let M=W[B++],K=W[B++];try{F=M(F)}catch($){K.call(this,$);break}}try{U=qG.call(this,F)}catch(M){return Promise.reject(M)}B=0,L=z.length;while(B<L)U=U.then(z[B++],z[B++]);return U}getUri(Z){Z=Q0(this.defaults,Z);let J=yG(Z.baseURL,Z.url,Z.allowAbsoluteUrls);return CG(J,Z.params,Z.paramsSerializer)}}I.forEach(["delete","get","head","options"],function(J){s0.prototype[J]=function(Y,G){return this.request(Q0(G||{},{method:J,url:Y,data:(G||{}).data}))}});I.forEach(["post","put","patch"],function(J){function Y(G){return function(X,W,H){return this.request(Q0(H||{},{method:J,headers:G?{"Content-Type":"multipart/form-data"}:{},url:X,data:W}))}}s0.prototype[J]=Y(),s0.prototype[J+"Form"]=Y(!0)});var H6=s0;class w9{constructor(Z){if(typeof Z!=="function")throw TypeError("executor must be a function.");let J;this.promise=new Promise(function(Q){J=Q});let Y=this;this.promise.then((G)=>{if(!Y._listeners)return;let Q=Y._listeners.length;while(Q-- >0)Y._listeners[Q](G);Y._listeners=null}),this.promise.then=(G)=>{let Q,X=new Promise((W)=>{Y.subscribe(W),Q=W}).then(G);return X.cancel=function(){Y.unsubscribe(Q)},X},Z(function(Q,X,W){if(Y.reason)return;Y.reason=new J5(Q,X,W),J(Y.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=(Y)=>{Z.abort(Y)};return this.subscribe(J),Z.signal.unsubscribe=()=>this.unsubscribe(J),Z.signal}static source(){let Z;return{token:new w9(function(G){Z=G}),cancel:Z}}}var iL=w9;function nL(Z){return function(Y){return Z.apply(null,Y)}}function oL(Z){return I.isObject(Z)&&Z.isAxiosError===!0}var q9={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(q9).forEach(([Z,J])=>{q9[J]=Z});var aL=q9;function cG(Z){let J=new H6(Z),Y=NG(H6.prototype.request,J);return I.extend(Y,H6.prototype,J,{allOwnKeys:!0}),I.extend(Y,J,null,{allOwnKeys:!0}),Y.create=function(Q){return cG(Q0(Z,Q))},Y}var b=cG(P9);b.Axios=H6;b.CanceledError=J5;b.CancelToken=iL;b.isCancel=vG;b.VERSION=dG;b.toFormData=L6;b.AxiosError=x;b.Cancel=b.CanceledError;b.all=function(J){return Promise.all(J)};b.spread=nL;b.isAxiosError=oL;b.mergeConfig=Q0;b.AxiosHeaders=$1;b.formToJSON=(Z)=>kG(I.isHTMLForm(Z)?new FormData(Z):Z);b.getAdapter=uG.getAdapter;b.HttpStatusCode=aL;b.default=b;pG.exports=b});var S9=A((nG)=>{Object.defineProperty(nG,"__esModule",{value:!0});nG.addAxiosDateTransformer=nG.createAxiosDateTransformer=void 0;var sL=(QG(),mX(GG)),rL=sL.__importDefault(lG()),tL=/^\d{4}-\d{2}-\d{2}(T\d{2}:\d{2}:\d{2}(?:\.\d*)?(?:[-+]\d{2}:?\d{2}|Z)?)?$/,eL=(Z)=>{return tL.test(Z)},ZM=(Z,J)=>{return!J||J.length===0||J.includes(Z)},JM=(Z,J,Y)=>{return typeof J==="string"&&eL(J)&&ZM(Z,Y)},iG=(Z,J)=>{if(typeof Z==="object"){for(let Y in Z)if(JM(Y,Z[Y],J))Z[Y]=new Date(Z[Y]);else if(typeof Z[Y]==="object")Z[Y]=iG(Z[Y],J)}return Z},YM=(Z,J)=>{if(Z.data)Z.data=iG(Z.data,J);return Z},GM=(Z={})=>{return nG.addAxiosDateTransformer(rL.default.create(Z),Z)};nG.createAxiosDateTransformer=GM;var QM=(Z,J)=>{let Y=J===null||J===void 0?void 0:J.allowlist;return Z.interceptors.response.use((G)=>YM(G,Y)),Z};nG.addAxiosDateTransformer=QM});var _9=A((YQ)=>{Object.defineProperty(YQ,"__esModule",{value:!0});YQ.Doctype=YQ.CDATA=YQ.Tag=YQ.Style=YQ.Script=YQ.Comment=YQ.Directive=YQ.Text=YQ.Root=YQ.isTag=YQ.ElementType=void 0;var X1;(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"})(X1=YQ.ElementType||(YQ.ElementType={}));function $M(Z){return Z.type===X1.Tag||Z.type===X1.Script||Z.type===X1.Style}YQ.isTag=$M;YQ.Root=X1.Root;YQ.Text=X1.Text;YQ.Directive=X1.Directive;YQ.Comment=X1.Comment;YQ.Script=X1.Script;YQ.Style=X1.Style;YQ.Tag=X1.Tag;YQ.CDATA=X1.CDATA;YQ.Doctype=X1.Doctype});var b9=A((E)=>{var l1=E&&E.__extends||function(){var Z=function(J,Y){return Z=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(G,Q){G.__proto__=Q}||function(G,Q){for(var X in Q)if(Object.prototype.hasOwnProperty.call(Q,X))G[X]=Q[X]},Z(J,Y)};return function(J,Y){if(typeof Y!=="function"&&Y!==null)throw TypeError("Class extends value "+String(Y)+" is not a constructor or null");Z(J,Y);function G(){this.constructor=J}J.prototype=Y===null?Object.create(Y):(G.prototype=Y.prototype,new G)}}(),G5=E&&E.__assign||function(){return G5=Object.assign||function(Z){for(var J,Y=1,G=arguments.length;Y<G;Y++){J=arguments[Y];for(var Q in J)if(Object.prototype.hasOwnProperty.call(J,Q))Z[Q]=J[Q]}return Z},G5.apply(this,arguments)};Object.defineProperty(E,"__esModule",{value:!0});E.cloneNode=E.hasChildren=E.isDocument=E.isDirective=E.isComment=E.isText=E.isCDATA=E.isTag=E.Element=E.Document=E.CDATA=E.NodeWithChildren=E.ProcessingInstruction=E.Comment=E.Text=E.DataNode=E.Node=void 0;var J1=_9(),v9=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 h9(this,J)},Z}();E.Node=v9;var F6=function(Z){l1(J,Z);function J(Y){var G=Z.call(this)||this;return G.data=Y,G}return Object.defineProperty(J.prototype,"nodeValue",{get:function(){return this.data},set:function(Y){this.data=Y},enumerable:!1,configurable:!0}),J}(v9);E.DataNode=F6;var QQ=function(Z){l1(J,Z);function J(){var Y=Z!==null&&Z.apply(this,arguments)||this;return Y.type=J1.ElementType.Text,Y}return Object.defineProperty(J.prototype,"nodeType",{get:function(){return 3},enumerable:!1,configurable:!0}),J}(F6);E.Text=QQ;var XQ=function(Z){l1(J,Z);function J(){var Y=Z!==null&&Z.apply(this,arguments)||this;return Y.type=J1.ElementType.Comment,Y}return Object.defineProperty(J.prototype,"nodeType",{get:function(){return 8},enumerable:!1,configurable:!0}),J}(F6);E.Comment=XQ;var WQ=function(Z){l1(J,Z);function J(Y,G){var Q=Z.call(this,G)||this;return Q.name=Y,Q.type=J1.ElementType.Directive,Q}return Object.defineProperty(J.prototype,"nodeType",{get:function(){return 1},enumerable:!1,configurable:!0}),J}(F6);E.ProcessingInstruction=WQ;var O6=function(Z){l1(J,Z);function J(Y){var G=Z.call(this)||this;return G.children=Y,G}return Object.defineProperty(J.prototype,"firstChild",{get:function(){var Y;return(Y=this.children[0])!==null&&Y!==void 0?Y: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(Y){this.children=Y},enumerable:!1,configurable:!0}),J}(v9);E.NodeWithChildren=O6;var HQ=function(Z){l1(J,Z);function J(){var Y=Z!==null&&Z.apply(this,arguments)||this;return Y.type=J1.ElementType.CDATA,Y}return Object.defineProperty(J.prototype,"nodeType",{get:function(){return 4},enumerable:!1,configurable:!0}),J}(O6);E.CDATA=HQ;var zQ=function(Z){l1(J,Z);function J(){var Y=Z!==null&&Z.apply(this,arguments)||this;return Y.type=J1.ElementType.Root,Y}return Object.defineProperty(J.prototype,"nodeType",{get:function(){return 9},enumerable:!1,configurable:!0}),J}(O6);E.Document=zQ;var UQ=function(Z){l1(J,Z);function J(Y,G,Q,X){if(Q===void 0)Q=[];if(X===void 0)X=Y==="script"?J1.ElementType.Script:Y==="style"?J1.ElementType.Style:J1.ElementType.Tag;var W=Z.call(this,Q)||this;return W.name=Y,W.attribs=G,W.type=X,W}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(Y){this.name=Y},enumerable:!1,configurable:!0}),Object.defineProperty(J.prototype,"attributes",{get:function(){var Y=this;return Object.keys(this.attribs).map(function(G){var Q,X;return{name:G,value:Y.attribs[G],namespace:(Q=Y["x-attribsNamespace"])===null||Q===void 0?void 0:Q[G],prefix:(X=Y["x-attribsPrefix"])===null||X===void 0?void 0:X[G]}})},enumerable:!1,configurable:!0}),J}(O6);E.Element=UQ;function BQ(Z){return(0,J1.isTag)(Z)}E.isTag=BQ;function KQ(Z){return Z.type===J1.ElementType.CDATA}E.isCDATA=KQ;function LQ(Z){return Z.type===J1.ElementType.Text}E.isText=LQ;function MQ(Z){return Z.type===J1.ElementType.Comment}E.isComment=MQ;function $Q(Z){return Z.type===J1.ElementType.Directive}E.isDirective=$Q;function FQ(Z){return Z.type===J1.ElementType.Root}E.isDocument=FQ;function PM(Z){return Object.prototype.hasOwnProperty.call(Z,"children")}E.hasChildren=PM;function h9(Z,J){if(J===void 0)J=!1;var Y;if(LQ(Z))Y=new QQ(Z.data);else if(MQ(Z))Y=new XQ(Z.data);else if(BQ(Z)){var G=J?k9(Z.children):[],Q=new UQ(Z.name,G5({},Z.attribs),G);if(G.forEach(function(z){return z.parent=Q}),Z.namespace!=null)Q.namespace=Z.namespace;if(Z["x-attribsNamespace"])Q["x-attribsNamespace"]=G5({},Z["x-attribsNamespace"]);if(Z["x-attribsPrefix"])Q["x-attribsPrefix"]=G5({},Z["x-attribsPrefix"]);Y=Q}else if(KQ(Z)){var G=J?k9(Z.children):[],X=new HQ(G);G.forEach(function(U){return U.parent=X}),Y=X}else if(FQ(Z)){var G=J?k9(Z.children):[],W=new zQ(G);if(G.forEach(function(U){return U.parent=W}),Z["x-mode"])W["x-mode"]=Z["x-mode"];Y=W}else if($Q(Z)){var H=new WQ(Z.name,Z.data);if(Z["x-name"]!=null)H["x-name"]=Z["x-name"],H["x-publicId"]=Z["x-publicId"],H["x-systemId"]=Z["x-systemId"];Y=H}else throw Error("Not implemented yet: ".concat(Z.type));if(Y.startIndex=Z.startIndex,Y.endIndex=Z.endIndex,Z.sourceCodeLocation!=null)Y.sourceCodeLocation=Z.sourceCodeLocation;return Y}E.cloneNode=h9;function k9(Z){var J=Z.map(function(G){return h9(G,!0)});for(var Y=1;Y<J.length;Y++)J[Y].prev=J[Y-1],J[Y-1].next=J[Y];return J}});var g9=A((D1)=>{var TM=D1&&D1.__createBinding||(Object.create?function(Z,J,Y,G){if(G===void 0)G=Y;var Q=Object.getOwnPropertyDescriptor(J,Y);if(!Q||("get"in Q?!J.__esModule:Q.writable||Q.configurable))Q={enumerable:!0,get:function(){return J[Y]}};Object.defineProperty(Z,G,Q)}:function(Z,J,Y,G){if(G===void 0)G=Y;Z[G]=J[Y]}),wM=D1&&D1.__exportStar||function(Z,J){for(var Y in Z)if(Y!=="default"&&!Object.prototype.hasOwnProperty.call(J,Y))TM(J,Z,Y)};Object.defineProperty(D1,"__esModule",{value:!0});D1.DomHandler=void 0;var y9=_9(),i1=b9();wM(b9(),D1);var OQ={withStartIndices:!1,withEndIndices:!1,xmlMode:!1},VQ=function(){function Z(J,Y,G){if(this.dom=[],this.root=new i1.Document(this.dom),this.done=!1,this.tagStack=[this.root],this.lastNode=null,this.parser=null,typeof Y==="function")G=Y,Y=OQ;if(typeof J==="object")Y=J,J=void 0;this.callback=J!==null&&J!==void 0?J:null,this.options=Y!==null&&Y!==void 0?Y:OQ,this.elementCB=G!==null&&G!==void 0?G:null}return Z.prototype.onparserinit=function(J){this.parser=J},Z.prototype.onreset=function(){this.dom=[],this.root=new i1.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,Y){var G=this.options.xmlMode?y9.ElementType.Tag:void 0,Q=new i1.Element(J,Y,void 0,G);this.addNode(Q),this.tagStack.push(Q)},Z.prototype.ontext=function(J){var Y=this.lastNode;if(Y&&Y.type===y9.ElementType.Text){if(Y.data+=J,this.options.withEndIndices)Y.endIndex=this.parser.endIndex}else{var G=new i1.Text(J);this.addNode(G),this.lastNode=G}},Z.prototype.oncomment=function(J){if(this.lastNode&&this.lastNode.type===y9.ElementType.Comment){this.lastNode.data+=J;return}var Y=new i1.Comment(J);this.addNode(Y),this.lastNode=Y},Z.prototype.oncommentend=function(){this.lastNode=null},Z.prototype.oncdatastart=function(){var J=new i1.Text(""),Y=new i1.CDATA([J]);this.addNode(Y),J.parent=Y,this.lastNode=J},Z.prototype.oncdataend=function(){this.lastNode=null},Z.prototype.onprocessinginstruction=function(J,Y){var G=new i1.ProcessingInstruction(J,Y);this.addNode(G)},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 Y=this.tagStack[this.tagStack.length-1],G=Y.children[Y.children.length-1];if(this.options.withStartIndices)J.startIndex=this.parser.startIndex;if(this.options.withEndIndices)J.endIndex=this.parser.endIndex;if(Y.children.push(J),G)J.prev=G,G.next=J;J.parent=Y,this.lastNode=null},Z}();D1.DomHandler=VQ;D1.default=VQ});var RQ=A((IQ)=>{Object.defineProperty(IQ,"__esModule",{value:!0});IQ.CARRIAGE_RETURN_PLACEHOLDER_REGEX=IQ.CARRIAGE_RETURN_PLACEHOLDER=IQ.CARRIAGE_RETURN_REGEX=IQ.CARRIAGE_RETURN=IQ.CASE_SENSITIVE_TAG_NAMES_MAP=IQ.CASE_SENSITIVE_TAG_NAMES=void 0;IQ.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"];IQ.CASE_SENSITIVE_TAG_NAMES_MAP=IQ.CASE_SENSITIVE_TAG_NAMES.reduce(function(Z,J){return Z[J.toLowerCase()]=J,Z},{});IQ.CARRIAGE_RETURN="\r";IQ.CARRIAGE_RETURN_REGEX=new RegExp(IQ.CARRIAGE_RETURN,"g");IQ.CARRIAGE_RETURN_PLACEHOLDER="__HTML_DOM_PARSER_CARRIAGE_RETURN_PLACEHOLDER_".concat(Date.now().toString(),"__");IQ.CARRIAGE_RETURN_PLACEHOLDER_REGEX=new RegExp(IQ.CARRIAGE_RETURN_PLACEHOLDER,"g")});var m9=A((EQ)=>{Object.defineProperty(EQ,"__esModule",{value:!0});EQ.formatAttributes=PQ;EQ.hasOpenTag=CM;EQ.escapeSpecialCharacters=jM;EQ.revertEscapedCharacters=TQ;EQ.formatDOM=wQ;var V6=g9(),Q5=RQ();function xM(Z){return Q5.CASE_SENSITIVE_TAG_NAMES_MAP[Z]}function PQ(Z){var J={},Y=0,G=Z.length;for(;Y<G;Y++){var Q=Z[Y];J[Q.name]=Q.value}return J}function fM(Z){Z=Z.toLowerCase();var J=xM(Z);if(J)return J;return Z}function CM(Z,J){var Y="<"+J,G=Z.toLowerCase().indexOf(Y);if(G===-1)return!1;var Q=Z[G+Y.length];return Q===">"||Q===" "||Q==="\t"||Q===`
|
|
15
|
-
`||Q==="\r"||Q==="/"}function jM(Z){return Z.replace(Q5.CARRIAGE_RETURN_REGEX,Q5.CARRIAGE_RETURN_PLACEHOLDER)}function TQ(Z){return Z.replace(Q5.CARRIAGE_RETURN_PLACEHOLDER_REGEX,Q5.CARRIAGE_RETURN)}function wQ(Z,J,Y){var G,Q,X,W;if(J===void 0)J=null;var H=[],z,U=0,B=Z.length;for(;U<B;U++){var L=Z[U];switch(L.nodeType){case 1:{var F=fM(L.nodeName);z=new V6.Element(F,PQ(L.attributes)),z.children=wQ(F==="template"?L.content.childNodes:L.childNodes,z);break}case 3:z=new V6.Text(TQ((G=L.nodeValue)!==null&&G!==void 0?G:""));break;case 8:z=new V6.Comment((Q=L.nodeValue)!==null&&Q!==void 0?Q:"");break;default:continue}var M=(X=H[U-1])!==null&&X!==void 0?X:null;if(M)M.next=z;z.parent=J,z.prev=M,z.next=null,H.push(z)}if(Y){if(z=new V6.ProcessingInstruction(Y.substring(0,Y.indexOf(" ")).toLowerCase(),Y),z.next=(W=H[0])!==null&&W!==void 0?W:null,z.parent=J,H.unshift(z),H[1])H[1].prev=H[0]}return H}});var jQ=A((CQ)=>{Object.defineProperty(CQ,"__esModule",{value:!0});CQ.default=gM;var X5=m9(),SQ="html",I6="head",A0="body",yM=/<([a-zA-Z]+[0-9]?)/,D6=function(Z,J){throw Error("This browser does not support `document.implementation.createHTMLDocument`")},u9=function(Z,J){throw Error("This browser does not support `DOMParser.prototype.parseFromString`")},xQ=typeof window==="object"&&window.DOMParser;if(typeof xQ==="function")d9=new xQ,c9="text/html",u9=function(Z,J){if(J)Z="<".concat(J,">").concat(Z,"</").concat(J,">");return d9.parseFromString(Z,c9)},D6=u9;var d9,c9;if(typeof document==="object"&&document.implementation)R0=document.implementation.createHTMLDocument(),D6=function(Z,J){if(J){var Y=R0.documentElement.querySelector(J);if(Y)Y.innerHTML=Z;return R0}return R0.documentElement.innerHTML=Z,R0};var R0,q6=typeof document==="object"&&document.createElement("template"),p9;if(q6&&q6.content)p9=function(Z){return q6.innerHTML=Z,q6.content.childNodes};var fQ=function(){return document.createDocumentFragment().childNodes};function gM(Z){var J,Y,G,Q,X,W;Z=(0,X5.escapeSpecialCharacters)(Z);var H=yM.exec(Z),z=(J=H===null||H===void 0?void 0:H[1])===null||J===void 0?void 0:J.toLowerCase();switch(z){case SQ:{var U=u9(Z);if(!(0,X5.hasOpenTag)(Z,I6)){var B=U.querySelector(I6);(Y=B===null||B===void 0?void 0:B.parentNode)===null||Y===void 0||Y.removeChild(B)}if(!(0,X5.hasOpenTag)(Z,A0)){var B=U.querySelector(A0);(G=B===null||B===void 0?void 0:B.parentNode)===null||G===void 0||G.removeChild(B)}return U.querySelectorAll(SQ)}case I6:case A0:{var L=D6(Z).querySelectorAll(z);if((0,X5.hasOpenTag)(Z,A0)&&(0,X5.hasOpenTag)(Z,I6))return(X=(Q=L[0].parentNode)===null||Q===void 0?void 0:Q.childNodes)!==null&&X!==void 0?X:fQ();return L}default:{if(p9)return p9(Z);var B=D6(Z,A0).querySelector(A0);return(W=B===null||B===void 0?void 0:B.childNodes)!==null&&W!==void 0?W:fQ()}}}});var _Q=A((W5)=>{var uM=W5&&W5.__importDefault||function(Z){return Z&&Z.__esModule?Z:{default:Z}};Object.defineProperty(W5,"__esModule",{value:!0});W5.default=lM;var dM=uM(jQ()),cM=m9(),pM=/<(![a-zA-Z\s]+)>/;function lM(Z){if(typeof Z!=="string")throw TypeError("First argument must be a string");if(!Z)return[];var J=pM.exec(Z),Y=J?J[1]:void 0;return(0,cM.formatDOM)((0,dM.default)(Z),null,Y)}});var kQ=A((oM)=>{var iM=0;oM.SAME=iM;var nM=1;oM.CAMELCASE=nM;oM.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 hQ=A((H2)=>{function tM(Z){return c.hasOwnProperty(Z)?c[Z]:null}function r(Z,J,Y,G,Q,X,W){this.acceptsBooleans=J===2||J===3||J===4,this.attributeName=G,this.attributeNamespace=Q,this.mustUseProperty=Y,this.propertyName=Z,this.type=J,this.sanitizeURL=X,this.removeEmptyString=W}var c={},eM=["children","dangerouslySetInnerHTML","defaultValue","defaultChecked","innerHTML","suppressContentEditableWarning","suppressHydrationWarning","style"];eM.forEach((Z)=>{c[Z]=new r(Z,0,!1,Z,null,!1,!1)});[["acceptCharset","accept-charset"],["className","class"],["htmlFor","for"],["httpEquiv","http-equiv"]].forEach(([Z,J])=>{c[Z]=new r(Z,1,!1,J,null,!1,!1)});["contentEditable","draggable","spellCheck","value"].forEach((Z)=>{c[Z]=new r(Z,2,!1,Z.toLowerCase(),null,!1,!1)});["autoReverse","externalResourcesRequired","focusable","preserveAlpha"].forEach((Z)=>{c[Z]=new r(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)=>{c[Z]=new r(Z,3,!1,Z.toLowerCase(),null,!1,!1)});["checked","multiple","muted","selected"].forEach((Z)=>{c[Z]=new r(Z,3,!0,Z,null,!1,!1)});["capture","download"].forEach((Z)=>{c[Z]=new r(Z,4,!1,Z,null,!1,!1)});["cols","rows","size","span"].forEach((Z)=>{c[Z]=new r(Z,6,!1,Z,null,!1,!1)});["rowSpan","start"].forEach((Z)=>{c[Z]=new r(Z,5,!1,Z.toLowerCase(),null,!1,!1)});var l9=/[\-\:]([a-z])/g,i9=(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(l9,i9);c[J]=new r(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(l9,i9);c[J]=new r(J,1,!1,Z,"http://www.w3.org/1999/xlink",!1,!1)});["xml:base","xml:lang","xml:space"].forEach((Z)=>{let J=Z.replace(l9,i9);c[J]=new r(J,1,!1,Z,"http://www.w3.org/XML/1998/namespace",!1,!1)});["tabIndex","crossOrigin"].forEach((Z)=>{c[Z]=new r(Z,1,!1,Z.toLowerCase(),null,!1,!1)});var Z2="xlinkHref";c[Z2]=new r("xlinkHref",1,!1,"xlink:href","http://www.w3.org/1999/xlink",!0,!1);["src","href","action","formAction"].forEach((Z)=>{c[Z]=new r(Z,1,!1,Z.toLowerCase(),null,!0,!0)});var{CAMELCASE:J2,SAME:Y2,possibleStandardNames:vQ}=kQ(),G2=":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",Q2=G2+"\\-.0-9\\u00B7\\u0300-\\u036F\\u203F-\\u2040",X2=RegExp.prototype.test.bind(new RegExp("^(data|aria)-["+Q2+"]*$")),W2=Object.keys(vQ).reduce((Z,J)=>{let Y=vQ[J];if(Y===Y2)Z[J]=J;else if(Y===J2)Z[J.toLowerCase()]=J;else Z[J]=Y;return Z},{});H2.BOOLEAN=3;H2.BOOLEANISH_STRING=2;H2.NUMERIC=5;H2.OVERLOADED_BOOLEAN=4;H2.POSITIVE_NUMERIC=6;H2.RESERVED=0;H2.STRING=1;H2.getPropertyInfo=tM;H2.isCustomAttribute=X2;H2.possibleStandardNames=W2});var dQ=A((sD,uQ)=>{var bQ=/\/\*[^*]*\*+([^/*][^*]*\*+)*\//g,I2=/\n/g,q2=/^\s*/,D2=/^(\*?[-#/*\\\w]+(\[[0-9a-z_-]+\])?)\s*/,N2=/^:\s*/,A2=/^((?:'(?:\\'|.)*?'|"(?:\\"|.)*?"|\([^)]*?\)|[^};])+)/,R2=/^[;\s]*/,P2=/^\s+|\s+$/g,T2=`
|
|
16
|
-
`,yQ="/",gQ="*",X0="",w2="comment",E2="declaration";function S2(Z,J){if(typeof Z!=="string")throw TypeError("First argument must be a string");if(!Z)return[];J=J||{};var Y=1,G=1;function Q(K){var $=K.match(I2);if($)Y+=$.length;var V=K.lastIndexOf(T2);G=~V?K.length-V:G+K.length}function X(){var K={line:Y,column:G};return function($){return $.position=new W(K),U(),$}}function W(K){this.start=K,this.end={line:Y,column:G},this.source=J.source}W.prototype.content=Z;function H(K){var $=Error(J.source+":"+Y+":"+G+": "+K);if($.reason=K,$.filename=J.source,$.line=Y,$.column=G,$.source=Z,J.silent);else throw $}function z(K){var $=K.exec(Z);if(!$)return;var V=$[0];return Q(V),Z=Z.slice(V.length),$}function U(){z(q2)}function B(K){var $;K=K||[];while($=L())if($!==!1)K.push($);return K}function L(){var K=X();if(yQ!=Z.charAt(0)||gQ!=Z.charAt(1))return;var $=2;while(X0!=Z.charAt($)&&(gQ!=Z.charAt($)||yQ!=Z.charAt($+1)))++$;if($+=2,X0===Z.charAt($-1))return H("End of comment missing");var V=Z.slice(2,$-2);return G+=2,Q(V),Z=Z.slice($),G+=2,K({type:w2,comment:V})}function F(){var K=X(),$=z(D2);if(!$)return;if(L(),!z(N2))return H("property missing ':'");var V=z(A2),N=K({type:E2,property:mQ($[0].replace(bQ,X0)),value:V?mQ(V[0].replace(bQ,X0)):X0});return z(R2),N}function M(){var K=[];B(K);var $;while($=F())if($!==!1)K.push($),B(K);return K}return U(),M()}function mQ(Z){return Z?Z.replace(P2,X0):X0}uQ.exports=S2});var cQ=A((H5)=>{var x2=H5&&H5.__importDefault||function(Z){return Z&&Z.__esModule?Z:{default:Z}};Object.defineProperty(H5,"__esModule",{value:!0});H5.default=C2;var f2=x2(dQ());function C2(Z,J){let Y=null;if(!Z||typeof Z!=="string")return Y;let G=(0,f2.default)(Z),Q=typeof J==="function";return G.forEach((X)=>{if(X.type!=="declaration")return;let{property:W,value:H}=X;if(Q)J(W,H,X);else if(H)Y=Y||{},Y[W]=H}),Y}});var nQ=A((lQ)=>{Object.defineProperty(lQ,"__esModule",{value:!0});lQ.camelCase=void 0;var j2=/^--[a-zA-Z0-9_-]+$/,_2=/-([a-z])/g,k2=/^[^-]+$/,v2=/^-(webkit|moz|ms|o|khtml)-/,h2=/^-(ms)-/,b2=function(Z){return!Z||k2.test(Z)||j2.test(Z)},y2=function(Z,J){return J.toUpperCase()},pQ=function(Z,J){return"".concat(J,"-")},g2=function(Z,J){if(J===void 0)J={};if(b2(Z))return Z;if(Z=Z.toLowerCase(),J.reactCompat)Z=Z.replace(h2,pQ);else Z=Z.replace(v2,pQ);return Z.replace(_2,y2)};lQ.camelCase=g2});var aQ=A((o9,oQ)=>{var m2=o9&&o9.__importDefault||function(Z){return Z&&Z.__esModule?Z:{default:Z}},u2=m2(cQ()),d2=nQ();function n9(Z,J){var Y={};if(!Z||typeof Z!=="string")return Y;return(0,u2.default)(Z,function(G,Q){if(G&&Q)Y[(0,d2.camelCase)(G,J)]=Q}),Y}n9.default=n9;oQ.exports=n9});import*as sQ from"react";var a9=A((t)=>{var c2=t&&t.__importDefault||function(Z){return Z&&Z.__esModule?Z:{default:Z}};Object.defineProperty(t,"__esModule",{value:!0});t.returnFirstArg=t.canTextBeChildOfNode=t.ELEMENTS_WITH_NO_TEXT_CHILDREN=t.PRESERVE_CUSTOM_ATTRIBUTES=void 0;t.isCustomComponent=i2;t.setStyleProp=o2;var p2=c2(aQ()),l2=new Set(["annotation-xml","color-profile","font-face","font-face-src","font-face-uri","font-face-format","font-face-name","missing-glyph"]);function i2(Z,J){if(!Z.includes("-"))return Boolean(J&&typeof J.is==="string");if(l2.has(Z))return!1;return!0}var n2={reactCompat:!0};function o2(Z,J){if(typeof Z!=="string")return;if(!Z.trim()){J.style={};return}try{J.style=(0,p2.default)(Z,n2)}catch(Y){J.style={}}}t.PRESERVE_CUSTOM_ATTRIBUTES=Number(sQ.version.split(".")[0])>=16;t.ELEMENTS_WITH_NO_TEXT_CHILDREN=new Set(["tr","tbody","thead","tfoot","colgroup","table","head","html","frameset"]);var a2=function(Z){return!t.ELEMENTS_WITH_NO_TEXT_CHILDREN.has(Z.name)};t.canTextBeChildOfNode=a2;var s2=function(Z){return Z};t.returnFirstArg=s2});var s9=A((eQ)=>{Object.defineProperty(eQ,"__esModule",{value:!0});eQ.default=Z$;var z5=hQ(),rQ=a9(),r2=["checked","value"],t2=["input","select","textarea"],e2={reset:!0,submit:!0};function Z$(Z,J){if(Z===void 0)Z={};var Y={},G=Boolean(Z.type&&e2[Z.type]);for(var Q in Z){var X=Z[Q];if((0,z5.isCustomAttribute)(Q)){Y[Q]=X;continue}var W=Q.toLowerCase(),H=tQ(W);if(H){var z=(0,z5.getPropertyInfo)(H);if(r2.includes(H)&&t2.includes(J)&&!G)H=tQ("default"+W);switch(Y[H]=X,z===null||z===void 0?void 0:z.type){case z5.BOOLEAN:Y[H]=!0;break;case z5.OVERLOADED_BOOLEAN:if(X==="")Y[H]=!0;break}continue}if(rQ.PRESERVE_CUSTOM_ATTRIBUTES)Y[Q]=X}return(0,rQ.setStyleProp)(Z.style,Y),Y}function tQ(Z){return z5.possibleStandardNames[Z]}});import*as P0 from"react";var JX=A((B5)=>{var Y$=B5&&B5.__importDefault||function(Z){return Z&&Z.__esModule?Z:{default:Z}};Object.defineProperty(B5,"__esModule",{value:!0});B5.default=ZX;var G$=Y$(s9()),U5=a9(),Q$={cloneElement:P0.cloneElement,createElement:P0.createElement,isValidElement:P0.isValidElement};function ZX(Z,J){var Y,G,Q,X,W;if(J===void 0)J={};var H=[],z=typeof J.replace==="function",U=(Y=J.transform)!==null&&Y!==void 0?Y:U5.returnFirstArg,B=(G=J.library)!==null&&G!==void 0?G:Q$,L=B.cloneElement,F=B.createElement,M=B.isValidElement,K=Z.length;for(var $=0;$<K;$++){var V=Z[$];if(z){var N=(Q=J.replace)===null||Q===void 0?void 0:Q.call(J,V,$);if(M(N)){if(K>1)N=L(N,{key:(X=N.key)!==null&&X!==void 0?X:$});H.push(U(N,V,$));continue}}if(V.type==="text"){var P=!V.data.trim().length;if(P&&V.parent&&!(0,U5.canTextBeChildOfNode)(V.parent))continue;if(J.trim&&P)continue;H.push(U(V.data,V,$));continue}var D=V,q={};if(X$(D))(0,U5.setStyleProp)(D.attribs.style,D.attribs),q=D.attribs;else if(D.attribs)q=(0,G$.default)(D.attribs,D.name);var T=void 0;switch(V.type){case"script":case"style":if(V.children[0])q.dangerouslySetInnerHTML={__html:V.children[0].data};break;case"tag":if(V.name==="textarea"&&V.children[0])q.defaultValue=V.children[0].data;else if((W=V.children)===null||W===void 0?void 0:W.length)T=ZX(V.children,J);break;default:continue}if(K>1)q.key=$;H.push(U(F(V.name,q,T),V,$))}return H.length===1?H[0]:H}function X$(Z){return U5.PRESERVE_CUSTOM_ATTRIBUTES&&Z.type==="tag"&&(0,U5.isCustomComponent)(Z.name,Z.attribs)}});var t9=A((g)=>{var r9=g&&g.__importDefault||function(Z){return Z&&Z.__esModule?Z:{default:Z}};Object.defineProperty(g,"__esModule",{value:!0});g.htmlToDOM=g.domToReact=g.attributesToProps=g.Text=g.ProcessingInstruction=g.Element=g.Comment=void 0;g.default=z$;var YX=r9(_Q());g.htmlToDOM=YX.default;var W$=r9(s9());g.attributesToProps=W$.default;var GX=r9(JX());g.domToReact=GX.default;var N6=g9();Object.defineProperty(g,"Comment",{enumerable:!0,get:function(){return N6.Comment}});Object.defineProperty(g,"Element",{enumerable:!0,get:function(){return N6.Element}});Object.defineProperty(g,"ProcessingInstruction",{enumerable:!0,get:function(){return N6.ProcessingInstruction}});Object.defineProperty(g,"Text",{enumerable:!0,get:function(){return N6.Text}});var H$={lowerCaseAttributeNames:!1};function z$(Z,J){var Y;if(typeof Z!=="string")throw TypeError("First argument must be a string");if(!Z)return[];return(0,GX.default)((0,YX.default)(Z,(Y=J===null||J===void 0?void 0:J.htmlparser2)!==null&&Y!==void 0?Y:H$),J)}});import{lazy as uX}from"react";var x6=new Map;function D7(Z,J){return uX(()=>{if(x6.has(J))return x6.get(J);let Y=Z().then((G)=>G);return x6.set(J,Y),Y})}var N7=new Map,dX=(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=D7(J.loader,Z.name),J.loader=void 0,J.isLazy=!0;return J};function L1(Z){let J=dX(Z);return N7.set(J.name,J),J.component}var A7=(Z)=>{return N7.get(Z)};import{Suspense as eX,useContext as Z3}from"react";import{createContext as cX}from"react";import{jsx as iX,Fragment as lX}from"react/jsx-runtime";var pX=cX(iX(lX,{})),k1=pX;import{createContext as nX,useContext as oX}from"react";var E0=nX(null),z0=()=>{let Z=oX(E0);if(!Z)throw Error("usePieConfig must be used within PieConfigProvider");return Z},aX=()=>{let{apiServer:Z}=z0();return Z},v1=aX,sX=()=>{let{centrifugeServer:Z}=z0();return Z},F5=sX,rX=()=>{let{enableRenderingLog:Z}=z0();return Z},h1=rX,tX=()=>{let{pageProcessor:Z}=z0();return Z},R7=tX;import{jsx as P7}from"react/jsx-runtime";function J3({uiConfig:Z,setUiAjaxConfiguration:J}){let Y=Z3(k1),G=h1();if(G)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 Q=A7(Z.card);if(!Q?.component){if(G)console.warn(`[UI] Component not found in registry: ${Z.card}`),console.log("[UI] Returning fallback component");return Y}if(G)console.log("[UI] Found component in registry:",{name:Q.name,isLazy:Q.isLazy,hasMetadata:!!Q.metadata});let X=Q.component,W=P7(X,{data:Z.data,content:Z.content,setUiAjaxConfiguration:J});if(Q.isLazy){if(G)console.log("[UI] Rendering lazy component with Suspense:",Q.name);return P7(eX,{fallback:Q.fallback??Y,children:W},`${Q.name}`)}if(G)console.log("[UI] Rendering component directly:",Q.name);return W}var Y1=J3;import{useEffect as DF,useMemo as NF}from"react";import{QueryClient as AF,QueryClientProvider as RF,useQuery as PF}from"@tanstack/react-query";var C5=S(f6(),1),DJ=S(_6(),1);import qJ,{useState as yU,useContext as BJ,useRef as gU,useEffect as KJ,forwardRef as mU}from"react";var E3={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 S0(Z,J){var Y=!E3[Z]&&typeof J==="number"&&J!==0;return Y?J+"px":J}function x0(Z,J){return Object.keys(Z).reduce(function(Y,G){return Y[G]=J(Z[G],G),Y},{})}function k6(Z){return x0(Z,function(J,Y){return S0(Y,Z[Y])+" !important"})}var S3=/([a-z])?([A-Z])/g,x3=function(J,Y,G){return(Y||"")+"-"+G.toLowerCase()},v6=function(J){return J.replace(S3,x3)},f3=function(J){return Object.keys(J).reduce(function(Y,G){var Q=v6(G);if(/^ms-/.test(Q))Q="-".concat(Q);return Y[Q]=J[G],Y},{})},u7=f3;var cZ=S(r7(),1),pZ=S(U4(),1),lZ=S(o6(),1);var c4=S(L4(),1),p4=S($4(),1),l4=S(O4(),1),i4=S(I4(),1),n4=S(N4(),1),o4=S(P4(),1),a4=S(E4(),1),s4=S(f4(),1),r4=S(j4(),1),t4=S(k4(),1),e4=S(h4(),1),ZZ=S(d4(),1),R=["Webkit"],L8=["Moz"],v=["ms"],l=["Webkit","Moz"],u=["Webkit","ms"],f0=["Webkit","Moz","ms"],JZ={plugins:[c4.default,p4.default,l4.default,i4.default,n4.default,o4.default,a4.default,s4.default,r4.default,t4.default,e4.default,ZZ.default],prefixMap:{transform:u,transformOrigin:u,transformOriginX:u,transformOriginY:u,backfaceVisibility:R,perspective:R,perspectiveOrigin:R,transformStyle:R,transformOriginZ:R,animation:R,animationDelay:R,animationDirection:R,animationFillMode:R,animationDuration:R,animationIterationCount:R,animationName:R,animationPlayState:R,animationTimingFunction:R,appearance:l,userSelect:f0,fontKerning:R,textEmphasisPosition:R,textEmphasis:R,textEmphasisStyle:R,textEmphasisColor:R,boxDecorationBreak:R,clipPath:R,maskImage:R,maskMode:R,maskRepeat:R,maskPosition:R,maskClip:R,maskOrigin:R,maskSize:R,maskComposite:R,mask:R,maskBorderSource:R,maskBorderMode:R,maskBorderSlice:R,maskBorderWidth:R,maskBorderOutset:R,maskBorderRepeat:R,maskBorder:R,maskType:R,textDecorationStyle:l,textDecorationSkip:l,textDecorationLine:l,textDecorationColor:l,filter:R,fontFeatureSettings:l,breakAfter:f0,breakBefore:f0,breakInside:f0,columnCount:l,columnFill:l,columnGap:l,columnRule:l,columnRuleColor:l,columnRuleStyle:l,columnRuleWidth:l,columns:l,columnSpan:l,columnWidth:l,writingMode:u,flex:u,flexBasis:R,flexDirection:u,flexGrow:R,flexFlow:u,flexShrink:R,flexWrap:u,alignContent:R,alignItems:R,alignSelf:R,justifyContent:R,order:R,transitionDelay:R,transitionDuration:R,transitionProperty:R,transitionTimingFunction:R,backdropFilter:R,scrollSnapType:u,scrollSnapPointsX:u,scrollSnapPointsY:u,scrollSnapDestination:u,scrollSnapCoordinate:u,shapeImageThreshold:R,shapeImageMargin:R,shapeImageOutside:R,hyphens:f0,flowInto:u,flowFrom:u,regionFragment:u,boxSizing:L8,textAlignLast:L8,tabSize:L8,wrapFlow:v,wrapThrough:v,wrapMargin:v,touchAction:v,gridTemplateColumns:v,gridTemplateRows:v,gridTemplateAreas:v,gridTemplate:v,gridAutoColumns:v,gridAutoRows:v,gridAutoFlow:v,grid:v,gridRowStart:v,gridColumnStart:v,gridRowEnd:v,gridRow:v,gridColumn:v,gridColumnEnd:v,gridColumnGap:v,gridRowGap:v,gridArea:v,gridGap:v,textSizeAdjust:u,borderImage:R,borderImageOutset:R,borderImageRepeat:R,borderImageSlice:R,borderImageSource:R,borderImageWidth:R}};var xZ=S(QZ(),1),fZ=S(WZ(),1),CZ=S(UZ(),1),jZ=S(KZ(),1),_Z=S(MZ(),1),kZ=S(FZ(),1),vZ=S(VZ(),1),hZ=S(DZ(),1),bZ=S(AZ(),1),yZ=S(PZ(),1),gZ=S(wZ(),1),mZ=S(SZ(),1),uZ={plugins:[xZ.default,fZ.default,CZ.default,jZ.default,_Z.default,kZ.default,vZ.default,hZ.default,bZ.default,yZ.default,gZ.default,mZ.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 N5(Z){if(typeof Symbol==="function"&&typeof Symbol.iterator==="symbol")N5=function(Y){return typeof Y};else N5=function(Y){return Y&&typeof Symbol==="function"&&Y.constructor===Symbol&&Y!==Symbol.prototype?"symbol":typeof Y};return N5(Z)}var iZ=cZ.default(JZ),ez=pZ.default(uZ,iZ);function ZU(Z){return Object.keys(Z).reduce(function(J,Y){var G=Z[Y];if(Array.isArray(G))G=G.join(";"+Y+":");else if(G&&N5(G)==="object"&&typeof G.toString==="function")G=G.toString();return J[Y]=G,J},{})}function JU(Z){return Object.keys(Z).reduce(function(J,Y){var G=Z[Y];if(Array.isArray(G))if(lZ.default.canUseDOM)G=G[G.length-1].toString();else G=G.join(";".concat(v6(Y),":"));return J[Y]=G,J},{})}var dZ,D5;function nZ(Z){var J=Z||global&&global.navigator&&global.navigator.userAgent;if(!D5||J!==dZ){if(J==="all")D5={prefix:iZ,prefixedKeyframes:"keyframes"};else D5=new ez({userAgent:J});dZ=J}return D5}function oZ(Z){return nZ(Z).prefixedKeyframes||"keyframes"}function A5(Z,J){var Y=ZU(Z),G=nZ(J),Q=G.prefix(Y),X=JU(Q);return X}function YU(Z){return Object.keys(Z).map(function(J){return J+": "+Z[J]+";"}).join(`
|
|
17
|
-
`)}function
|
|
18
|
-
`)}},{key:"_emitChange",value:function(){this._listeners.forEach(function(Y){return Y()})}}]),Z}();function K0(Z){for(var J=1;J<arguments.length;J++){var Y=arguments[J]!=null?arguments[J]:{},G=Object.keys(Y);if(typeof Object.getOwnPropertySymbols==="function")G=G.concat(Object.getOwnPropertySymbols(Y).filter(function(Q){return Object.getOwnPropertyDescriptor(Y,Q).enumerable}));G.forEach(function(Q){qU(Z,Q,Y[Q])})}return Z}function qU(Z,J,Y){if(J in Z)Object.defineProperty(Z,J,{value:Y,enumerable:!0,configurable:!0,writable:!0});else Z[J]=Y;return Z}function x5(Z){if(typeof Symbol==="function"&&typeof Symbol.iterator==="symbol")x5=function(Y){return typeof Y};else x5=function(Y){return Y&&typeof Symbol==="function"&&Y.constructor===Symbol&&Y!==Symbol.prototype?"symbol":typeof Y};return x5(Z)}var XJ={plugins:[B1.mergeStyleArray,B1.checkProps,B1.resolveMediaQueries,B1.resolveInteractionStyles,B1.keyframes,B1.visited,B1.removeNestedStyles,B1.prefix,B1.checkProps]},GJ={},DU=!1,r1=null,NU=function(J){return J.type&&!J.type._isRadiumEnhanced},AU=function(J){var{children:Y,component:G,config:Q,existingKeyMap:X,extraStateKeyMap:W}=J;if(!Y)return Y;var H=x5(Y);if(H==="string"||H==="number")return Y;if(H==="function")return function(){var F=Y.apply(this,arguments);if(y1.isValidElement(F)){var M=s1(F);delete W[M];var K=r1(G,F,Q,X,!0,W),$=K.element;return $}return F};if(y1.Children.count(Y)===1&&Y.type){var z=y1.Children.only(Y),U=s1(z);delete W[U];var B=r1(G,z,Q,X,!0,W),L=B.element;return L}return y1.Children.map(Y,function(F){if(y1.isValidElement(F)){var M=s1(F);delete W[M];var K=r1(G,F,Q,X,!0,W),$=K.element;return $}return F})},RU=function(J){var{component:Y,config:G,existingKeyMap:Q,props:X,extraStateKeyMap:W}=J,H=X;return Object.keys(X).forEach(function(z){if(z==="children")return;var U=X[z];if(y1.isValidElement(U)){var B=s1(U);delete W[B],H=K0({},H);var L=r1(Y,U,G,Q,!0,W),F=L.element;H[z]=F}}),H},PU=function(J){var{componentName:Y,existingKeyMap:G,renderedElement:Q}=J,X=s1(Q),W=R5(X),H=!1,z=function(){if(H)return W;if(H=!0,G[W]){var B;if(typeof Q.type==="string")B=Q.type;else if(Q.type.constructor)B=Q.type.constructor.displayName||Q.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. "+(X?'Key "'+X+'" is a duplicate.':"Multiple elements have no key specified.")+' Component: "'+Y+'". '+(B?'Element: "'+B+'".':""))}return G[W]=!0,W};return z},TU=function(J,Y,G,Q){if(!J._radiumIsMounted)return;var X=C0(J),W={_radiumStyleState:K0({},X)};W._radiumStyleState[Y]=K0({},W._radiumStyleState[Y]),W._radiumStyleState[Y][G]=Q,J._lastRadiumState=W._radiumStyleState,J.setState(W)},wU=function(J){var{component:Y,config:G,existingKeyMap:Q,props:X,renderedElement:W}=J;if(!y1.isValidElement(W)||typeof W.type!=="string"||!X.style)return X;var H=X,z=G.plugins||XJ.plugins,U=Y.constructor.displayName||Y.constructor.name,B=PU({renderedElement:W,existingKeyMap:Q,componentName:U}),L=function(P){return Y[P]},F=function(P){return GJ[P]},M=function(P,D){return P5(Y.state,D||B(),P)},K=function(P,D,q){return TU(Y,q||B(),P,D)},$=function(P){var D=Y._radiumStyleKeeper;if(!D){if(DU)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 D.addCSS(P)},V=X.style;if(z.forEach(function(N){var P=N({ExecutionEnvironment:QJ.default,addCSS:$,appendImportantToEachValue:k6,componentName:U,config:G,cssRuleSetToString:b1,getComponentField:L,getGlobalState:F,getState:M,hash:j0,mergeStyles:E5,props:H,setState:K,isNestedStyle:w5,style:V})||{};V=P.style||V,H=P.props&&Object.keys(P.props).length?K0({},H,P.props):H;var D=P.componentFields||{};Object.keys(D).forEach(function(T){Y[T]=D[T]});var q=P.globalState||{};Object.keys(q).forEach(function(T){GJ[T]=q[T]})}),V!==X.style)H=K0({},H,{style:V});return H},EU=function(J,Y,G){if(typeof J.type==="string")Y=K0({},Y,{"data-radium":!0});return y1.cloneElement(J,Y,G)};r1=function(J,Y){var G=arguments.length>2&&arguments[2]!==void 0?arguments[2]:XJ,Q=arguments.length>3&&arguments[3]!==void 0?arguments[3]:{},X=arguments.length>4&&arguments[4]!==void 0?arguments[4]:!1,W=arguments.length>5?arguments[5]:void 0;if(!W){var H=C0(J);W=Object.keys(H).reduce(function(M,K){if(K!=="main")M[K]=!0;return M},{})}if(Array.isArray(Y)&&!Y.props){var z=Y.map(function(M){if(W){var K=s1(M);delete W[K]}return r1(J,M,G,Q,X,W).element});return{extraStateKeyMap:W,element:z}}if(!Y||Y.props&&Y.props["data-radium"]||X&&!NU(Y))return{extraStateKeyMap:W,element:Y};var U=Y.props.children,B=AU({children:U,component:J,config:G,existingKeyMap:Q,extraStateKeyMap:W}),L=RU({component:J,config:G,existingKeyMap:Q,extraStateKeyMap:W,props:Y.props});if(L=wU({component:J,config:G,existingKeyMap:Q,props:L,renderedElement:Y}),B===U&&L===Y.props)return{extraStateKeyMap:W,element:Y};var F=EU(Y,L!==Y.props?L:{},B);return{extraStateKeyMap:W,element:F}};var WJ=r1;var zJ=S(_6(),1);import f5,{useContext as HJ}from"react";function y8(){return y8=Object.assign||function(Z){for(var J=1;J<arguments.length;J++){var Y=arguments[J];for(var G in Y)if(Object.prototype.hasOwnProperty.call(Y,G))Z[G]=Y[G]}return Z},y8.apply(this,arguments)}var _0=f5.createContext(void 0),L0=f5.createContext(void 0);function M0(Z){var J=f5.forwardRef(function(Y,G){var Q=HJ(L0),X=HJ(_0);return f5.createElement(Z,y8({ref:G},Y,{radiumConfigContext:Q,styleKeeperContext:X}))});return J.displayName="withRadiumContexts(".concat(Z.displayName||Z.name||"Component",")"),zJ.default(J,Z)}function t1(Z){if(typeof Symbol==="function"&&typeof Symbol.iterator==="symbol")t1=function(Y){return typeof Y};else t1=function(Y){return Y&&typeof Symbol==="function"&&Y.constructor===Symbol&&Y!==Symbol.prototype?"symbol":typeof Y};return t1(Z)}function $J(Z,J){if(!(Z instanceof J))throw TypeError("Cannot call a class as a function")}function UJ(Z,J){for(var Y=0;Y<J.length;Y++){var G=J[Y];if(G.enumerable=G.enumerable||!1,G.configurable=!0,"value"in G)G.writable=!0;Object.defineProperty(Z,G.key,G)}}function SU(Z,J,Y){if(J)UJ(Z.prototype,J);if(Y)UJ(Z,Y);return Z}function FJ(Z,J){if(J&&(t1(J)==="object"||typeof J==="function"))return J;return OJ(Z)}function OJ(Z){if(Z===void 0)throw ReferenceError("this hasn't been initialised - super() hasn't been called");return Z}function g1(Z,J,Y){if(typeof Reflect<"u"&&Reflect.get)g1=Reflect.get;else g1=function(Q,X,W){var H=xU(Q,X);if(!H)return;var z=Object.getOwnPropertyDescriptor(H,X);if(z.get)return z.get.call(W);return z.value};return g1(Z,J,Y||Z)}function xU(Z,J){while(!Object.prototype.hasOwnProperty.call(Z,J))if(Z=O1(Z),Z===null)break;return Z}function O1(Z){return O1=Object.setPrototypeOf?Object.getPrototypeOf:function(Y){return Y.__proto__||Object.getPrototypeOf(Y)},O1(Z)}function VJ(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)g8(Z,J)}function g8(Z,J){return g8=Object.setPrototypeOf||function(G,Q){return G.__proto__=Q,G},g8(Z,J)}function fU(Z,J){return _U(Z)||jU(Z,J)||CU()}function CU(){throw TypeError("Invalid attempt to destructure non-iterable instance")}function jU(Z,J){var Y=[],G=!0,Q=!1,X=void 0;try{for(var W=Z[Symbol.iterator](),H;!(G=(H=W.next()).done);G=!0)if(Y.push(H.value),J&&Y.length===J)break}catch(z){Q=!0,X=z}finally{try{if(!G&&W.return!=null)W.return()}finally{if(Q)throw X}}return Y}function _U(Z){if(Array.isArray(Z))return Z}function m8(Z){for(var J=1;J<arguments.length;J++){var Y=arguments[J]!=null?arguments[J]:{},G=Object.keys(Y);if(typeof Object.getOwnPropertySymbols==="function")G=G.concat(Object.getOwnPropertySymbols(Y).filter(function(Q){return Object.getOwnPropertyDescriptor(Y,Q).enumerable}));G.forEach(function(Q){kU(Z,Q,Y[Q])})}return Z}function kU(Z,J,Y){if(J in Z)Object.defineProperty(Z,J,{value:Y,enumerable:!0,configurable:!0,writable:!0});else Z[J]=Y;return Z}function IJ(Z,J){if(Z==null)return{};var Y=vU(Z,J),G,Q;if(Object.getOwnPropertySymbols){var X=Object.getOwnPropertySymbols(Z);for(Q=0;Q<X.length;Q++){if(G=X[Q],J.indexOf(G)>=0)continue;if(!Object.prototype.propertyIsEnumerable.call(Z,G))continue;Y[G]=Z[G]}}return Y}function vU(Z,J){if(Z==null)return{};var Y={},G=Object.keys(Z),Q,X;for(X=0;X<G.length;X++){if(Q=G[X],J.indexOf(Q)>=0)continue;Y[Q]=Z[Q]}return Y}function hU(Z){var J=bU(Z,"string");return t1(J)==="symbol"?J:String(J)}function bU(Z,J){if(t1(Z)!=="object"||Z===null)return Z;var Y=Z[Symbol.toPrimitive];if(Y!==void 0){var G=Y.call(Z,J||"default");if(t1(G)!=="object")return G;throw TypeError("@@toPrimitive must return a primitive value.")}return(J==="string"?String:Number)(Z)}var uU=["arguments","callee","caller","length","name","prototype","type"],j5,NJ;function dU(Z,J){Object.getOwnPropertyNames(Z).forEach(function(Y){if(uU.indexOf(Y)<0&&!J.hasOwnProperty(Y)){var G=Object.getOwnPropertyDescriptor(Z,Y);G&&Object.defineProperty(J,Y,G)}})}function cU(Z){var J=Z.prototype||{};return!Z.isReactComponent&&!J.isReactComponent&&!Z.render&&!J.render}function pU(Z){return typeof Z==="function"&&/^\s*class\s+/.test(Z.toString())}function lU(Z,J){NJ.forEach(function(Y){var G=Object.getOwnPropertyDescriptor(Z,Y),Q=(G||{}).value;if(!Q)return;var X=Object.getOwnPropertyDescriptor(j5,Y),W=(X||{}).value,H=J.prototype[Y];if(!H&&Q!==W)G&&Object.defineProperty(J.prototype,Y,G),delete Z[Y]})}function AJ(Z){if(Z._extraRadiumStateKeys&&Z._extraRadiumStateKeys.length>0){var J=Z._extraRadiumStateKeys.reduce(function(Y,G){var Q=Y[G],X=IJ(Y,[G].map(hU));return X},C0(Z));Z._lastRadiumState=J,Z.setState({_radiumStyleState:J})}}function RJ(Z){var{_radiumMouseUpListener:J,_radiumMediaQueryListenersByQuery:Y}=Z;if(Z._radiumIsMounted=!1,J)J.remove();if(Y)Object.keys(Y).forEach(function(G){Y[G].remove()},Z)}function PJ(Z,J,Y){var G=Z||J||Y;if(Y&&G!==Y)G=m8({},Y,G);return G}function TJ(Z,J,Y,G){var Q=WJ(Z,J,Y),X=Q.extraStateKeyMap,W=Q.element;if(Z._extraRadiumStateKeys=Object.keys(X),G)return qJ.createElement(L0.Provider,{value:G},W);return W}function LJ(Z,J){var Y=qJ.forwardRef(function(G,Q){var X=G.radiumConfig,W=IJ(G,["radiumConfig"]),H=BJ(L0),z=BJ(_0),U=yU({_radiumStyleState:{}}),B=fU(U,2),L=B[0],F=B[1],M=gU({state:L,setState:F,_radiumMediaQueryListenersByQuery:void 0,_radiumMouseUpListener:void 0,_radiumIsMounted:!0,_lastRadiumState:void 0,_extraRadiumStateKeys:void 0,_radiumStyleKeeper:z}).current;M.state=L,KJ(function(){return function(){RJ(M)}},[M]);var K=M._extraRadiumStateKeys&&M._extraRadiumStateKeys.length>0;KJ(function(){AJ(M)},[K,M]);var $=Z(W,Q),V=PJ(X,H,J);return TJ(M,$,V,X)});return Y._isRadiumEnhanced=!0,Y.defaultProps=Z.defaultProps,DJ.default(Y,Z)}function iU(Z,J,Y){var G=function(Q){VJ(X,Q);function X(){var W;$J(this,X),W=FJ(this,O1(X).apply(this,arguments)),W.state=W.state||{},W._radiumStyleKeeper=W.props.styleKeeperContext,W._radiumMediaQueryListenersByQuery=W._radiumMediaQueryListenersByQuery,W._radiumMouseUpListener=W._radiumMouseUpListener,W._radiumIsMounted=!0,W._lastRadiumState=void 0,W._extraRadiumStateKeys=void 0,W.state._radiumStyleState={};var H=OJ(W);return lU(H,J),W}return SU(X,[{key:"componentDidUpdate",value:function(H,z,U){if(g1(O1(X.prototype),"componentDidUpdate",this))g1(O1(X.prototype),"componentDidUpdate",this).call(this,H,z,U);AJ(this)}},{key:"componentWillUnmount",value:function(){if(g1(O1(X.prototype),"componentWillUnmount",this))g1(O1(X.prototype),"componentWillUnmount",this).call(this);RJ(this)}},{key:"render",value:function(){var H=g1(O1(X.prototype),"render",this).call(this),z=PJ(this.props.radiumConfig,this.props.radiumConfigContext,Y);return TJ(this,H,z,this.props.radiumConfig)}}]),X}(J);if(G._isRadiumEnhanced=!0,j5=G.prototype,NJ=Object.getOwnPropertyNames(j5).filter(function(Q){return Q!=="constructor"&&typeof j5[Q]==="function"}),dU(Z,G),G.propTypes&&G.propTypes.style)G.propTypes=m8({},G.propTypes,{style:C5.default.oneOfType([C5.default.array,C5.default.object])});return G.displayName=Z.displayName||Z.name||"Component",M0(G)}function nU(Z){return Z=function(J){function Y(){var G=Reflect.construct(J,arguments,this.constructor);return G}return Reflect.setPrototypeOf(Y.prototype,J.prototype),Reflect.setPrototypeOf(Y,J),Y}(Z),Z}var MJ=mU(function(){return null}).$$typeof;function $0(Z){var J=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};if(MJ&&Z.$$typeof===MJ)return LJ(Z.render,J);if(typeof Z!=="function")return oU(J,Z);var Y=Z;if(cU(Y))return LJ(Y,J);var G=Y;if(pU(G))G=nU(G);if(G===Y)G=function(Q){VJ(X,Q);function X(){return $J(this,X),FJ(this,O1(X).apply(this,arguments))}return X}(G);return iU(Y,G,J)}function oU(Z,J){var Y=m8({},Z,J);return function(G){return $0(G,Y)}}var _5=S(f6(),1);import ZB,{PureComponent as JB}from"react";function F0(Z){if(typeof Symbol==="function"&&typeof Symbol.iterator==="symbol")F0=function(Y){return typeof Y};else F0=function(Y){return Y&&typeof Symbol==="function"&&Y.constructor===Symbol&&Y!==Symbol.prototype?"symbol":typeof Y};return F0(Z)}function aU(Z,J){if(!(Z instanceof J))throw TypeError("Cannot call a class as a function")}function wJ(Z,J){for(var Y=0;Y<J.length;Y++){var G=J[Y];if(G.enumerable=G.enumerable||!1,G.configurable=!0,"value"in G)G.writable=!0;Object.defineProperty(Z,G.key,G)}}function sU(Z,J,Y){if(J)wJ(Z.prototype,J);if(Y)wJ(Z,Y);return Z}function rU(Z,J){if(J&&(F0(J)==="object"||typeof J==="function"))return J;return tU(Z)}function tU(Z){if(Z===void 0)throw ReferenceError("this hasn't been initialised - super() hasn't been called");return Z}function u8(Z){return u8=Object.setPrototypeOf?Object.getPrototypeOf:function(Y){return Y.__proto__||Object.getPrototypeOf(Y)},u8(Z)}function eU(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)d8(Z,J)}function d8(Z,J){return d8=Object.setPrototypeOf||function(G,Q){return G.__proto__=Q,G},d8(Z,J)}var c8=function(Z){eU(J,Z);function J(){return aU(this,J),rU(this,u8(J).apply(this,arguments))}return sU(J,[{key:"_buildStyles",value:function(G){var Q=this,X=this.props.radiumConfig&&this.props.radiumConfig.userAgent||this.props.radiumConfigContext&&this.props.radiumConfigContext.userAgent,W=this.props.scopeSelector,H=Object.keys(G).reduce(function(U,B){if(F0(G[B])!=="object")U[B]=G[B];return U},{}),z=Object.keys(H).length?b1(W||"",H,X):"";return z+Object.keys(G).reduce(function(U,B){var L=G[B];if(B==="mediaQueries")U+=Q._buildMediaQueryString(L);else if(F0(G[B])==="object"){var F=W?B.split(",").map(function(M){return W+" "+M.trim()}).join(","):B;U+=b1(F,L,X)}return U},"")}},{key:"_buildMediaQueryString",value:function(G){var Q=this,X="";return Object.keys(G).forEach(function(W){X+="@media "+W+"{"+Q._buildStyles(G[W])+"}"}),X}},{key:"render",value:function(){if(!this.props.rules)return null;var G=this._buildStyles(this.props.rules);return ZB.createElement("style",{dangerouslySetInnerHTML:{__html:G}})}}]),J}(JB);c8.propTypes={radiumConfig:_5.default.object,rules:_5.default.object,scopeSelector:_5.default.string};c8.defaultProps={scopeSelector:""};var EJ=M0(c8);import v5,{useContext as LB,useRef as MB}from"react";import HB,{Component as zB}from"react";function k5(Z){if(typeof Symbol==="function"&&typeof Symbol.iterator==="symbol")k5=function(Y){return typeof Y};else k5=function(Y){return Y&&typeof Symbol==="function"&&Y.constructor===Symbol&&Y!==Symbol.prototype?"symbol":typeof Y};return k5(Z)}function YB(Z,J){if(!(Z instanceof J))throw TypeError("Cannot call a class as a function")}function SJ(Z,J){for(var Y=0;Y<J.length;Y++){var G=J[Y];if(G.enumerable=G.enumerable||!1,G.configurable=!0,"value"in G)G.writable=!0;Object.defineProperty(Z,G.key,G)}}function GB(Z,J,Y){if(J)SJ(Z.prototype,J);if(Y)SJ(Z,Y);return Z}function QB(Z,J){if(J&&(k5(J)==="object"||typeof J==="function"))return J;return XB(Z)}function XB(Z){if(Z===void 0)throw ReferenceError("this hasn't been initialised - super() hasn't been called");return Z}function p8(Z){return p8=Object.setPrototypeOf?Object.getPrototypeOf:function(Y){return Y.__proto__||Object.getPrototypeOf(Y)},p8(Z)}function WB(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)l8(Z,J)}function l8(Z,J){return l8=Object.setPrototypeOf||function(G,Q){return G.__proto__=Q,G},l8(Z,J)}var UB=function(Z){WB(J,Z);function J(){var Y;if(YB(this,J),Y=QB(this,p8(J).apply(this,arguments)),Y.styleKeeper=void 0,Y._subscription=void 0,Y._root=void 0,Y._css=void 0,Y._onChange=function(){var G=Y.styleKeeper.getCSS();if(G!==Y._css){if(Y._root)Y._root.innerHTML=G;else throw Error("No root style object found, even after StyleSheet mount.");Y._css=G}},!Y.props.styleKeeperContext)throw Error("StyleRoot is required to use StyleSheet");return Y.styleKeeper=Y.props.styleKeeperContext,Y._css=Y.styleKeeper.getCSS(),Y}return GB(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 G=this;return HB.createElement("style",{dangerouslySetInnerHTML:{__html:this._css},ref:function(X){G._root=X}})}}]),J}(zB),xJ=M0(UB);function BB(Z,J){if(Z==null)return{};var Y=KB(Z,J),G,Q;if(Object.getOwnPropertySymbols){var X=Object.getOwnPropertySymbols(Z);for(Q=0;Q<X.length;Q++){if(G=X[Q],J.indexOf(G)>=0)continue;if(!Object.prototype.propertyIsEnumerable.call(Z,G))continue;Y[G]=Z[G]}}return Y}function KB(Z,J){if(Z==null)return{};var Y={},G=Object.keys(Z),Q,X;for(X=0;X<G.length;X++){if(Q=G[X],J.indexOf(Q)>=0)continue;Y[Q]=Z[Q]}return Y}function $B(Z,J){var Y=Z&&Z.userAgent||J&&J.userAgent;return new YJ(Y)}var FB=$0(function(Z){var J=Z.children,Y=BB(Z,["children"]);return v5.createElement("div",Y,J,v5.createElement(xJ,null))}),OB=function(J){var Y=J.radiumConfig,G=LB(L0),Q=MB($B(Y,G));return v5.createElement(_0.Provider,{value:Q.current},v5.createElement(FB,J))},fJ=OB;function i8(Z,J){return{__radiumKeyframes:!0,__process:function(G){var Q=oZ(G),X=Object.keys(Z).map(function(z){return b1(z,Z[z],G)}).join(`
|
|
19
|
-
`),W=(J?J+"-":"")+"radium-animation-"+
|
|
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 D5<"u"&&D5.exports)D5.exports=J;else window.ExecutionEnvironment=J})()});var s1=A((a6,M4)=>{Object.defineProperty(a6,"__esModule",{value:!0});a6.default=PW;var RW=/-webkit-|-moz-|-ms-/;function PW(Z){return typeof Z==="string"&&RW.test(Z)}M4.exports=a6.default});var F4=A((s6,$4)=>{Object.defineProperty(s6,"__esModule",{value:!0});s6.default=fW;var wW=s1(),EW=SW(wW);function SW(Z){return Z&&Z.__esModule?Z:{default:Z}}var xW=["-webkit-","-moz-",""];function fW(Z,J){if(typeof J==="string"&&!(0,EW.default)(J)&&J.indexOf("calc(")>-1)return xW.map(function(Y){return J.replace(/calc\(/g,Y+"calc(")})}$4.exports=s6.default});var V4=A((r6,O4)=>{Object.defineProperty(r6,"__esModule",{value:!0});r6.default=hW;var jW=s1(),_W=kW(jW);function kW(Z){return Z&&Z.__esModule?Z:{default:Z}}var vW=["-webkit-",""];function hW(Z,J){if(typeof J==="string"&&!(0,_W.default)(J)&&J.indexOf("cross-fade(")>-1)return vW.map(function(Y){return J.replace(/cross-fade\(/g,Y+"cross-fade(")})}O4.exports=r6.default});var q4=A((t6,I4)=>{Object.defineProperty(t6,"__esModule",{value:!0});t6.default=mW;var gW=["-webkit-","-moz-",""],yW={"zoom-in":!0,"zoom-out":!0,grab:!0,grabbing:!0};function mW(Z,J){if(Z==="cursor"&&yW.hasOwnProperty(J))return gW.map(function(Y){return Y+J})}I4.exports=t6.default});var N4=A((e6,D4)=>{Object.defineProperty(e6,"__esModule",{value:!0});e6.default=iW;var dW=s1(),cW=pW(dW);function pW(Z){return Z&&Z.__esModule?Z:{default:Z}}var lW=["-webkit-",""];function iW(Z,J){if(typeof J==="string"&&!(0,cW.default)(J)&&J.indexOf("filter(")>-1)return lW.map(function(Y){return J.replace(/filter\(/g,Y+"filter(")})}D4.exports=e6.default});var P4=A((Z8,R4)=>{Object.defineProperty(Z8,"__esModule",{value:!0});Z8.default=oW;var A4={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 oW(Z,J){if(Z==="display"&&A4.hasOwnProperty(J))return A4[J]}R4.exports=Z8.default});var E4=A((J8,w4)=>{Object.defineProperty(J8,"__esModule",{value:!0});J8.default=rW;var sW={"space-around":"distribute","space-between":"justify","flex-start":"start","flex-end":"end"},T4={alignContent:"msFlexLinePack",alignSelf:"msFlexItemAlign",alignItems:"msFlexAlign",justifyContent:"msFlexPack",order:"msFlexOrder",flexGrow:"msFlexPositive",flexShrink:"msFlexNegative",flexBasis:"msFlexPreferredSize"};function rW(Z,J,Y){if(T4.hasOwnProperty(Z))Y[T4[Z]]=sW[J]||J}w4.exports=J8.default});var f4=A((Y8,x4)=>{Object.defineProperty(Y8,"__esModule",{value:!0});Y8.default=ZH;var eW={"space-around":"justify","space-between":"justify","flex-start":"start","flex-end":"end","wrap-reverse":"multiple",wrap:"multiple",flex:"box","inline-flex":"inline-box"},S4={alignItems:"WebkitBoxAlign",justifyContent:"WebkitBoxPack",flexWrap:"WebkitBoxLines",flexGrow:"WebkitBoxFlex"};function ZH(Z,J,Y){if(Z==="flexDirection"&&typeof J==="string"){if(J.indexOf("column")>-1)Y.WebkitBoxOrient="vertical";else Y.WebkitBoxOrient="horizontal";if(J.indexOf("reverse")>-1)Y.WebkitBoxDirection="reverse";else Y.WebkitBoxDirection="normal"}if(S4.hasOwnProperty(Z))Y[S4[Z]]=eW[J]||J}x4.exports=Y8.default});var _4=A((G8,j4)=>{Object.defineProperty(G8,"__esModule",{value:!0});G8.default=WH;var YH=s1(),GH=QH(YH);function QH(Z){return Z&&Z.__esModule?Z:{default:Z}}var XH=["-webkit-","-moz-",""],C4=/linear-gradient|radial-gradient|repeating-linear-gradient|repeating-radial-gradient/gi;function WH(Z,J){if(typeof J==="string"&&!(0,GH.default)(J)&&C4.test(J))return XH.map(function(Y){return J.replace(C4,function(G){return Y+G})})}j4.exports=G8.default});var v4=A((Q8,k4)=>{Object.defineProperty(Q8,"__esModule",{value:!0});Q8.default=LH;var zH=s1(),UH=BH(zH);function BH(Z){return Z&&Z.__esModule?Z:{default:Z}}var KH=["-webkit-",""];function LH(Z,J){if(typeof J==="string"&&!(0,UH.default)(J)&&J.indexOf("image-set(")>-1)return KH.map(function(Y){return J.replace(/image-set\(/g,Y+"image-set(")})}k4.exports=Q8.default});var b4=A((X8,h4)=>{Object.defineProperty(X8,"__esModule",{value:!0});X8.default=$H;function $H(Z,J){if(Z==="position"&&J==="sticky")return["-webkit-sticky","sticky"]}h4.exports=X8.default});var y4=A((W8,g4)=>{Object.defineProperty(W8,"__esModule",{value:!0});W8.default=qH;var OH=["-webkit-","-moz-",""],VH={maxHeight:!0,maxWidth:!0,width:!0,height:!0,columnWidth:!0,minWidth:!0,minHeight:!0},IH={"min-content":!0,"max-content":!0,"fill-available":!0,"fit-content":!0,"contain-floats":!0};function qH(Z,J){if(VH.hasOwnProperty(Z)&&IH.hasOwnProperty(J))return OH.map(function(Y){return Y+J})}g4.exports=W8.default});var u4=A((AO,m4)=>{var NH=/[A-Z]/g,AH=/^ms-/,H8={};function RH(Z){return"-"+Z.toLowerCase()}function PH(Z){if(H8.hasOwnProperty(Z))return H8[Z];var J=Z.replace(NH,RH);return H8[Z]=AH.test(J)?"-"+J:J}m4.exports=PH});var U8=A((z8,d4)=>{Object.defineProperty(z8,"__esModule",{value:!0});z8.default=SH;var TH=u4(),wH=EH(TH);function EH(Z){return Z&&Z.__esModule?Z:{default:Z}}function SH(Z){return(0,wH.default)(Z)}d4.exports=z8.default});var l4=A((K8,p4)=>{Object.defineProperty(K8,"__esModule",{value:!0});K8.default=gH;var fH=U8(),CH=B8(fH),jH=s1(),_H=B8(jH),kH=V5(),c4=B8(kH);function B8(Z){return Z&&Z.__esModule?Z:{default:Z}}var vH={transition:!0,transitionProperty:!0,WebkitTransition:!0,WebkitTransitionProperty:!0,MozTransition:!0,MozTransitionProperty:!0},hH={Webkit:"-webkit-",Moz:"-moz-",ms:"-ms-"};function bH(Z,J){if((0,_H.default)(Z))return Z;var Y=Z.split(/,(?![^()]*(?:\([^()]*\))?\))/g);for(var G=0,Q=Y.length;G<Q;++G){var X=Y[G],W=[X];for(var H in J){var z=(0,CH.default)(H);if(X.indexOf(z)>-1&&z!=="order"){var U=J[H];for(var B=0,L=U.length;B<L;++B)W.unshift(X.replace(z,hH[U[B]]+z))}}Y[G]=W.join(",")}return Y.join(",")}function gH(Z,J,Y,G){if(typeof J==="string"&&vH.hasOwnProperty(Z)){var Q=bH(J,G),X=Q.split(/,(?![^()]*(?:\([^()]*\))?\))/g).filter(function(H){return!/-moz-|-ms-/.test(H)}).join(",");if(Z.indexOf("Webkit")>-1)return X;var W=Q.split(/,(?![^()]*(?:\([^()]*\))?\))/g).filter(function(H){return!/-webkit-|-ms-/.test(H)}).join(",");if(Z.indexOf("Moz")>-1)return W;return Y["Webkit"+(0,c4.default)(Z)]=X,Y["Moz"+(0,c4.default)(Z)]=W,Q}}p4.exports=K8.default});var B1=A((M8,XZ)=>{Object.defineProperty(M8,"__esModule",{value:!0});M8.default=mH;function mH(Z,J,Y){if(Y)return[Z,J];return Z}XZ.exports=M8.default});var HZ=A(($8,WZ)=>{Object.defineProperty($8,"__esModule",{value:!0});$8.default=lH;var dH=B1(),cH=pH(dH);function pH(Z){return Z&&Z.__esModule?Z:{default:Z}}function lH(Z,J,Y,G){var{browserName:Q,browserVersion:X,cssPrefix:W,keepUnprefixed:H}=G;if(typeof J==="string"&&J.indexOf("calc(")>-1&&(Q==="firefox"&&X<15||Q==="chrome"&&X<25||Q==="safari"&&X<6.1||Q==="ios_saf"&&X<7))return(0,cH.default)(J.replace(/calc\(/g,W+"calc("),J,H)}WZ.exports=$8.default});var UZ=A((F8,zZ)=>{Object.defineProperty(F8,"__esModule",{value:!0});F8.default=sH;var nH=B1(),oH=aH(nH);function aH(Z){return Z&&Z.__esModule?Z:{default:Z}}function sH(Z,J,Y,G){var{browserName:Q,browserVersion:X,cssPrefix:W,keepUnprefixed:H}=G;if(typeof J==="string"&&J.indexOf("cross-fade(")>-1&&(Q==="chrome"||Q==="opera"||Q==="and_chr"||(Q==="ios_saf"||Q==="safari")&&X<10))return(0,oH.default)(J.replace(/cross-fade\(/g,W+"cross-fade("),J,H)}zZ.exports=F8.default});var LZ=A((O8,KZ)=>{Object.defineProperty(O8,"__esModule",{value:!0});O8.default=Yz;var tH=B1(),BZ=eH(tH);function eH(Z){return Z&&Z.__esModule?Z:{default:Z}}var Zz={grab:!0,grabbing:!0},Jz={"zoom-in":!0,"zoom-out":!0};function Yz(Z,J,Y,G){var{browserName:Q,browserVersion:X,cssPrefix:W,keepUnprefixed:H}=G;if(Z==="cursor"&&Zz[J]&&(Q==="firefox"||Q==="chrome"||Q==="safari"||Q==="opera"))return(0,BZ.default)(W+J,J,H);if(Z==="cursor"&&Jz[J]&&(Q==="firefox"&&X<24||Q==="chrome"&&X<37||Q==="safari"&&X<9||Q==="opera"&&X<24))return(0,BZ.default)(W+J,J,H)}KZ.exports=O8.default});var $Z=A((V8,MZ)=>{Object.defineProperty(V8,"__esModule",{value:!0});V8.default=Hz;var Qz=B1(),Xz=Wz(Qz);function Wz(Z){return Z&&Z.__esModule?Z:{default:Z}}function Hz(Z,J,Y,G){var{browserName:Q,browserVersion:X,cssPrefix:W,keepUnprefixed:H}=G;if(typeof J==="string"&&J.indexOf("filter(")>-1&&(Q==="ios_saf"||Q==="safari"&&X<9.1))return(0,Xz.default)(J.replace(/filter\(/g,W+"filter("),J,H)}MZ.exports=V8.default});var OZ=A((I8,FZ)=>{Object.defineProperty(I8,"__esModule",{value:!0});I8.default=Mz;var Uz=B1(),Bz=Kz(Uz);function Kz(Z){return Z&&Z.__esModule?Z:{default:Z}}var Lz={flex:!0,"inline-flex":!0};function Mz(Z,J,Y,G){var{browserName:Q,browserVersion:X,cssPrefix:W,keepUnprefixed:H}=G;if(Z==="display"&&Lz[J]&&(Q==="chrome"&&X<29&&X>20||(Q==="safari"||Q==="ios_saf")&&X<9&&X>6||Q==="opera"&&(X===15||X===16)))return(0,Bz.default)(W+J,J,H)}FZ.exports=I8.default});var IZ=A((N8,VZ)=>{Object.defineProperty(N8,"__esModule",{value:!0});N8.default=Iz;var Fz=B1(),Oz=Vz(Fz);function Vz(Z){return Z&&Z.__esModule?Z:{default:Z}}var q8={"space-around":"distribute","space-between":"justify","flex-start":"start","flex-end":"end",flex:"flexbox","inline-flex":"inline-flexbox"},D8={alignContent:"msFlexLinePack",alignSelf:"msFlexItemAlign",alignItems:"msFlexAlign",justifyContent:"msFlexPack",order:"msFlexOrder",flexGrow:"msFlexPositive",flexShrink:"msFlexNegative",flexBasis:"msFlexPreferredSize"};function Iz(Z,J,Y,G){var{browserName:Q,browserVersion:X,cssPrefix:W,keepUnprefixed:H,requiresPrefix:z}=G;if((D8.hasOwnProperty(Z)||Z==="display"&&typeof J==="string"&&J.indexOf("flex")>-1)&&(Q==="ie_mob"||Q==="ie")&&X===10){if(delete z[Z],!H&&!Array.isArray(Y[Z]))delete Y[Z];if(Z==="display"&&q8.hasOwnProperty(J))return(0,Oz.default)(W+q8[J],J,H);if(D8.hasOwnProperty(Z))Y[D8[Z]]=q8[J]||J}}VZ.exports=N8.default});var DZ=A((P8,qZ)=>{Object.defineProperty(P8,"__esModule",{value:!0});P8.default=Tz;var Dz=B1(),Nz=Az(Dz);function Az(Z){return Z&&Z.__esModule?Z:{default:Z}}var A8={"space-around":"justify","space-between":"justify","flex-start":"start","flex-end":"end","wrap-reverse":"multiple",wrap:"multiple",flex:"box","inline-flex":"inline-box"},R8={alignItems:"WebkitBoxAlign",justifyContent:"WebkitBoxPack",flexWrap:"WebkitBoxLines",flexGrow:"WebkitBoxFlex"},Rz=["alignContent","alignSelf","order","flexGrow","flexShrink","flexBasis","flexDirection"],Pz=Object.keys(R8).concat(Rz);function Tz(Z,J,Y,G){var{browserName:Q,browserVersion:X,cssPrefix:W,keepUnprefixed:H,requiresPrefix:z}=G;if((Pz.indexOf(Z)>-1||Z==="display"&&typeof J==="string"&&J.indexOf("flex")>-1)&&(Q==="firefox"&&X<22||Q==="chrome"&&X<21||(Q==="safari"||Q==="ios_saf")&&X<=6.1||Q==="android"&&X<4.4||Q==="and_uc")){if(delete z[Z],!H&&!Array.isArray(Y[Z]))delete Y[Z];if(Z==="flexDirection"&&typeof J==="string"){if(J.indexOf("column")>-1)Y.WebkitBoxOrient="vertical";else Y.WebkitBoxOrient="horizontal";if(J.indexOf("reverse")>-1)Y.WebkitBoxDirection="reverse";else Y.WebkitBoxDirection="normal"}if(Z==="display"&&A8.hasOwnProperty(J))return(0,Nz.default)(W+A8[J],J,H);if(R8.hasOwnProperty(Z))Y[R8[Z]]=A8[J]||J}}qZ.exports=P8.default});var RZ=A((T8,AZ)=>{Object.defineProperty(T8,"__esModule",{value:!0});T8.default=fz;var Ez=B1(),Sz=xz(Ez);function xz(Z){return Z&&Z.__esModule?Z:{default:Z}}var NZ=/linear-gradient|radial-gradient|repeating-linear-gradient|repeating-radial-gradient/gi;function fz(Z,J,Y,G){var{browserName:Q,browserVersion:X,cssPrefix:W,keepUnprefixed:H}=G;if(typeof J==="string"&&NZ.test(J)&&(Q==="firefox"&&X<16||Q==="chrome"&&X<26||(Q==="safari"||Q==="ios_saf")&&X<7||(Q==="opera"||Q==="op_mini")&&X<12.1||Q==="android"&&X<4.4||Q==="and_uc"))return(0,Sz.default)(J.replace(NZ,function(z){return W+z}),J,H)}AZ.exports=T8.default});var TZ=A((w8,PZ)=>{Object.defineProperty(w8,"__esModule",{value:!0});w8.default=vz;var jz=B1(),_z=kz(jz);function kz(Z){return Z&&Z.__esModule?Z:{default:Z}}function vz(Z,J,Y,G){var{browserName:Q,cssPrefix:X,keepUnprefixed:W}=G;if(typeof J==="string"&&J.indexOf("image-set(")>-1&&(Q==="chrome"||Q==="opera"||Q==="and_chr"||Q==="and_uc"||Q==="ios_saf"||Q==="safari"))return(0,_z.default)(J.replace(/image-set\(/g,X+"image-set("),J,W)}PZ.exports=w8.default});var EZ=A((E8,wZ)=>{Object.defineProperty(E8,"__esModule",{value:!0});E8.default=mz;var bz=B1(),gz=yz(bz);function yz(Z){return Z&&Z.__esModule?Z:{default:Z}}function mz(Z,J,Y,G){var{browserName:Q,cssPrefix:X,keepUnprefixed:W}=G;if(Z==="position"&&J==="sticky"&&(Q==="safari"||Q==="ios_saf"))return(0,gz.default)(X+J,J,W)}wZ.exports=E8.default});var xZ=A((S8,SZ)=>{Object.defineProperty(S8,"__esModule",{value:!0});S8.default=nz;var dz=B1(),cz=pz(dz);function pz(Z){return Z&&Z.__esModule?Z:{default:Z}}var lz={maxHeight:!0,maxWidth:!0,width:!0,height:!0,columnWidth:!0,minWidth:!0,minHeight:!0},iz={"min-content":!0,"max-content":!0,"fill-available":!0,"fit-content":!0,"contain-floats":!0};function nz(Z,J,Y,G){var{cssPrefix:Q,keepUnprefixed:X}=G;if(lz.hasOwnProperty(Z)&&iz.hasOwnProperty(J))return(0,cz.default)(Q+J,J,X)}SZ.exports=S8.default});var CZ=A((f8,fZ)=>{Object.defineProperty(f8,"__esModule",{value:!0});f8.default=ez;var az=U8(),sz=rz(az);function rz(Z){return Z&&Z.__esModule?Z:{default:Z}}var tz={transition:!0,transitionProperty:!0,WebkitTransition:!0,WebkitTransitionProperty:!0,MozTransition:!0,MozTransitionProperty:!0},x8=void 0;function ez(Z,J,Y,G){var{cssPrefix:Q,keepUnprefixed:X,requiresPrefix:W}=G;if(typeof J==="string"&&tz.hasOwnProperty(Z)){if(!x8)x8=Object.keys(W).map(function(z){return(0,sz.default)(z)});var H=J.split(/,(?![^()]*(?:\([^()]*\))?\))/g);return x8.forEach(function(z){H.forEach(function(U,B){if(U.indexOf(z)>-1&&z!=="order")H[B]=U.replace(z,Q+z)+(X?","+U:"")})}),H.join(",")}}fZ.exports=f8.default});var WG={};N7(WG,{default:()=>DK,__values:()=>Y6,__spreadArrays:()=>iY,__spreadArray:()=>nY,__spread:()=>lY,__setFunctionName:()=>mY,__runInitializers:()=>gY,__rewriteRelativeImportExtension:()=>XG,__rest:()=>kY,__read:()=>L9,__propKey:()=>yY,__param:()=>hY,__metadata:()=>uY,__makeTemplateObject:()=>rY,__importStar:()=>tY,__importDefault:()=>eY,__generator:()=>cY,__extends:()=>_Y,__exportStar:()=>pY,__esDecorate:()=>bY,__disposeResources:()=>QG,__decorate:()=>vY,__createBinding:()=>G6,__classPrivateFieldSet:()=>JG,__classPrivateFieldIn:()=>YG,__classPrivateFieldGet:()=>ZG,__awaiter:()=>dY,__await:()=>D0,__asyncValues:()=>sY,__asyncGenerator:()=>oY,__asyncDelegator:()=>aY,__assign:()=>J6,__addDisposableResource:()=>GG});function _Y(Z,J){if(typeof J!=="function"&&J!==null)throw TypeError("Class extends value "+String(J)+" is not a constructor or null");B9(Z,J);function Y(){this.constructor=Z}Z.prototype=J===null?Object.create(J):(Y.prototype=J.prototype,new Y)}function kY(Z,J){var Y={};for(var G in Z)if(Object.prototype.hasOwnProperty.call(Z,G)&&J.indexOf(G)<0)Y[G]=Z[G];if(Z!=null&&typeof Object.getOwnPropertySymbols==="function"){for(var Q=0,G=Object.getOwnPropertySymbols(Z);Q<G.length;Q++)if(J.indexOf(G[Q])<0&&Object.prototype.propertyIsEnumerable.call(Z,G[Q]))Y[G[Q]]=Z[G[Q]]}return Y}function vY(Z,J,Y,G){var Q=arguments.length,X=Q<3?J:G===null?G=Object.getOwnPropertyDescriptor(J,Y):G,W;if(typeof Reflect==="object"&&typeof Reflect.decorate==="function")X=Reflect.decorate(Z,J,Y,G);else for(var H=Z.length-1;H>=0;H--)if(W=Z[H])X=(Q<3?W(X):Q>3?W(J,Y,X):W(J,Y))||X;return Q>3&&X&&Object.defineProperty(J,Y,X),X}function hY(Z,J){return function(Y,G){J(Y,G,Z)}}function bY(Z,J,Y,G,Q,X){function W(N){if(N!==void 0&&typeof N!=="function")throw TypeError("Function expected");return N}var H=G.kind,z=H==="getter"?"get":H==="setter"?"set":"value",U=!J&&Z?G.static?Z:Z.prototype:null,B=J||(U?Object.getOwnPropertyDescriptor(U,G.name):{}),L,F=!1;for(var M=Y.length-1;M>=0;M--){var K={};for(var $ in G)K[$]=$==="access"?{}:G[$];for(var $ in G.access)K.access[$]=G.access[$];K.addInitializer=function(N){if(F)throw TypeError("Cannot add initializers after decoration has completed");X.push(W(N||null))};var O=(0,Y[M])(H==="accessor"?{get:B.get,set:B.set}:B[z],K);if(H==="accessor"){if(O===void 0)continue;if(O===null||typeof O!=="object")throw TypeError("Object expected");if(L=W(O.get))B.get=L;if(L=W(O.set))B.set=L;if(L=W(O.init))Q.unshift(L)}else if(L=W(O))if(H==="field")Q.unshift(L);else B[z]=L}if(U)Object.defineProperty(U,G.name,B);F=!0}function gY(Z,J,Y){var G=arguments.length>2;for(var Q=0;Q<J.length;Q++)Y=G?J[Q].call(Z,Y):J[Q].call(Z);return G?Y:void 0}function yY(Z){return typeof Z==="symbol"?Z:"".concat(Z)}function mY(Z,J,Y){if(typeof J==="symbol")J=J.description?"[".concat(J.description,"]"):"";return Object.defineProperty(Z,"name",{configurable:!0,value:Y?"".concat(Y," ",J):J})}function uY(Z,J){if(typeof Reflect==="object"&&typeof Reflect.metadata==="function")return Reflect.metadata(Z,J)}function dY(Z,J,Y,G){function Q(X){return X instanceof Y?X:new Y(function(W){W(X)})}return new(Y||(Y=Promise))(function(X,W){function H(B){try{U(G.next(B))}catch(L){W(L)}}function z(B){try{U(G.throw(B))}catch(L){W(L)}}function U(B){B.done?X(B.value):Q(B.value).then(H,z)}U((G=G.apply(Z,J||[])).next())})}function cY(Z,J){var Y={label:0,sent:function(){if(X[0]&1)throw X[1];return X[1]},trys:[],ops:[]},G,Q,X,W=Object.create((typeof Iterator==="function"?Iterator:Object).prototype);return W.next=H(0),W.throw=H(1),W.return=H(2),typeof Symbol==="function"&&(W[Symbol.iterator]=function(){return this}),W;function H(U){return function(B){return z([U,B])}}function z(U){if(G)throw TypeError("Generator is already executing.");while(W&&(W=0,U[0]&&(Y=0)),Y)try{if(G=1,Q&&(X=U[0]&2?Q.return:U[0]?Q.throw||((X=Q.return)&&X.call(Q),0):Q.next)&&!(X=X.call(Q,U[1])).done)return X;if(Q=0,X)U=[U[0]&2,X.value];switch(U[0]){case 0:case 1:X=U;break;case 4:return Y.label++,{value:U[1],done:!1};case 5:Y.label++,Q=U[1],U=[0];continue;case 7:U=Y.ops.pop(),Y.trys.pop();continue;default:if((X=Y.trys,!(X=X.length>0&&X[X.length-1]))&&(U[0]===6||U[0]===2)){Y=0;continue}if(U[0]===3&&(!X||U[1]>X[0]&&U[1]<X[3])){Y.label=U[1];break}if(U[0]===6&&Y.label<X[1]){Y.label=X[1],X=U;break}if(X&&Y.label<X[2]){Y.label=X[2],Y.ops.push(U);break}if(X[2])Y.ops.pop();Y.trys.pop();continue}U=J.call(Z,Y)}catch(B){U=[6,B],Q=0}finally{G=X=0}if(U[0]&5)throw U[1];return{value:U[0]?U[1]:void 0,done:!0}}}function pY(Z,J){for(var Y in Z)if(Y!=="default"&&!Object.prototype.hasOwnProperty.call(J,Y))G6(J,Z,Y)}function Y6(Z){var J=typeof Symbol==="function"&&Symbol.iterator,Y=J&&Z[J],G=0;if(Y)return Y.call(Z);if(Z&&typeof Z.length==="number")return{next:function(){if(Z&&G>=Z.length)Z=void 0;return{value:Z&&Z[G++],done:!Z}}};throw TypeError(J?"Object is not iterable.":"Symbol.iterator is not defined.")}function L9(Z,J){var Y=typeof Symbol==="function"&&Z[Symbol.iterator];if(!Y)return Z;var G=Y.call(Z),Q,X=[],W;try{while((J===void 0||J-- >0)&&!(Q=G.next()).done)X.push(Q.value)}catch(H){W={error:H}}finally{try{if(Q&&!Q.done&&(Y=G.return))Y.call(G)}finally{if(W)throw W.error}}return X}function lY(){for(var Z=[],J=0;J<arguments.length;J++)Z=Z.concat(L9(arguments[J]));return Z}function iY(){for(var Z=0,J=0,Y=arguments.length;J<Y;J++)Z+=arguments[J].length;for(var G=Array(Z),Q=0,J=0;J<Y;J++)for(var X=arguments[J],W=0,H=X.length;W<H;W++,Q++)G[Q]=X[W];return G}function nY(Z,J,Y){if(Y||arguments.length===2){for(var G=0,Q=J.length,X;G<Q;G++)if(X||!(G in J)){if(!X)X=Array.prototype.slice.call(J,0,G);X[G]=J[G]}}return Z.concat(X||Array.prototype.slice.call(J))}function D0(Z){return this instanceof D0?(this.v=Z,this):new D0(Z)}function oY(Z,J,Y){if(!Symbol.asyncIterator)throw TypeError("Symbol.asyncIterator is not defined.");var G=Y.apply(Z,J||[]),Q,X=[];return Q=Object.create((typeof AsyncIterator==="function"?AsyncIterator:Object).prototype),H("next"),H("throw"),H("return",W),Q[Symbol.asyncIterator]=function(){return this},Q;function W(M){return function(K){return Promise.resolve(K).then(M,L)}}function H(M,K){if(G[M]){if(Q[M]=function($){return new Promise(function(O,N){X.push([M,$,O,N])>1||z(M,$)})},K)Q[M]=K(Q[M])}}function z(M,K){try{U(G[M](K))}catch($){F(X[0][3],$)}}function U(M){M.value instanceof D0?Promise.resolve(M.value.v).then(B,L):F(X[0][2],M)}function B(M){z("next",M)}function L(M){z("throw",M)}function F(M,K){if(M(K),X.shift(),X.length)z(X[0][0],X[0][1])}}function aY(Z){var J,Y;return J={},G("next"),G("throw",function(Q){throw Q}),G("return"),J[Symbol.iterator]=function(){return this},J;function G(Q,X){J[Q]=Z[Q]?function(W){return(Y=!Y)?{value:D0(Z[Q](W)),done:!1}:X?X(W):W}:X}}function sY(Z){if(!Symbol.asyncIterator)throw TypeError("Symbol.asyncIterator is not defined.");var J=Z[Symbol.asyncIterator],Y;return J?J.call(Z):(Z=typeof Y6==="function"?Y6(Z):Z[Symbol.iterator](),Y={},G("next"),G("throw"),G("return"),Y[Symbol.asyncIterator]=function(){return this},Y);function G(X){Y[X]=Z[X]&&function(W){return new Promise(function(H,z){W=Z[X](W),Q(H,z,W.done,W.value)})}}function Q(X,W,H,z){Promise.resolve(z).then(function(U){X({value:U,done:H})},W)}}function rY(Z,J){if(Object.defineProperty)Object.defineProperty(Z,"raw",{value:J});else Z.raw=J;return Z}function tY(Z){if(Z&&Z.__esModule)return Z;var J={};if(Z!=null){for(var Y=K9(Z),G=0;G<Y.length;G++)if(Y[G]!=="default")G6(J,Z,Y[G])}return IK(J,Z),J}function eY(Z){return Z&&Z.__esModule?Z:{default:Z}}function ZG(Z,J,Y,G){if(Y==="a"&&!G)throw TypeError("Private accessor was defined without a getter");if(typeof J==="function"?Z!==J||!G:!J.has(Z))throw TypeError("Cannot read private member from an object whose class did not declare it");return Y==="m"?G:Y==="a"?G.call(Z):G?G.value:J.get(Z)}function JG(Z,J,Y,G,Q){if(G==="m")throw TypeError("Private method is not writable");if(G==="a"&&!Q)throw TypeError("Private accessor was defined without a setter");if(typeof J==="function"?Z!==J||!Q:!J.has(Z))throw TypeError("Cannot write private member to an object whose class did not declare it");return G==="a"?Q.call(Z,Y):Q?Q.value=Y:J.set(Z,Y),Y}function YG(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 GG(Z,J,Y){if(J!==null&&J!==void 0){if(typeof J!=="object"&&typeof J!=="function")throw TypeError("Object expected.");var G,Q;if(Y){if(!Symbol.asyncDispose)throw TypeError("Symbol.asyncDispose is not defined.");G=J[Symbol.asyncDispose]}if(G===void 0){if(!Symbol.dispose)throw TypeError("Symbol.dispose is not defined.");if(G=J[Symbol.dispose],Y)Q=G}if(typeof G!=="function")throw TypeError("Object not disposable.");if(Q)G=function(){try{Q.call(this)}catch(X){return Promise.reject(X)}};Z.stack.push({value:J,dispose:G,async:Y})}else if(Y)Z.stack.push({async:!0});return J}function QG(Z){function J(X){Z.error=Z.hasError?new qK(X,Z.error,"An error was suppressed during disposal."):X,Z.hasError=!0}var Y,G=0;function Q(){while(Y=Z.stack.pop())try{if(!Y.async&&G===1)return G=0,Z.stack.push(Y),Promise.resolve().then(Q);if(Y.dispose){var X=Y.dispose.call(Y.value);if(Y.async)return G|=2,Promise.resolve(X).then(Q,function(W){return J(W),Q()})}else G|=1}catch(W){J(W)}if(G===1)return Z.hasError?Promise.reject(Z.error):Promise.resolve();if(Z.hasError)throw Z.error}return Q()}function XG(Z,J){if(typeof Z==="string"&&/^\.\.?\//.test(Z))return Z.replace(/\.(tsx)$|((?:\.d)?)((?:\.[^./]+?)?)\.([cm]?)ts$/i,function(Y,G,Q,X,W){return G?J?".jsx":".js":Q&&(!X||!W)?Y:Q+X+"."+W.toLowerCase()+"js"});return Z}var B9=function(Z,J){return B9=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(Y,G){Y.__proto__=G}||function(Y,G){for(var Q in G)if(Object.prototype.hasOwnProperty.call(G,Q))Y[Q]=G[Q]},B9(Z,J)},J6=function(){return J6=Object.assign||function(J){for(var Y,G=1,Q=arguments.length;G<Q;G++){Y=arguments[G];for(var X in Y)if(Object.prototype.hasOwnProperty.call(Y,X))J[X]=Y[X]}return J},J6.apply(this,arguments)},G6,IK,K9=function(Z){return K9=Object.getOwnPropertyNames||function(J){var Y=[];for(var G in J)if(Object.prototype.hasOwnProperty.call(J,G))Y[Y.length]=G;return Y},K9(Z)},qK,DK;var HG=A7(()=>{G6=Object.create?function(Z,J,Y,G){if(G===void 0)G=Y;var Q=Object.getOwnPropertyDescriptor(J,Y);if(!Q||("get"in Q?!J.__esModule:Q.writable||Q.configurable))Q={enumerable:!0,get:function(){return J[Y]}};Object.defineProperty(Z,G,Q)}:function(Z,J,Y,G){if(G===void 0)G=Y;Z[G]=J[Y]};IK=Object.create?function(Z,J){Object.defineProperty(Z,"default",{enumerable:!0,value:J})}:function(Z,J){Z.default=J};qK=typeof SuppressedError==="function"?SuppressedError:function(Z,J,Y){var G=Error(Y);return G.name="SuppressedError",G.error=Z,G.suppressed=J,G};DK={__extends:_Y,__assign:J6,__rest:kY,__decorate:vY,__param:hY,__esDecorate:bY,__runInitializers:gY,__propKey:yY,__setFunctionName:mY,__metadata:uY,__awaiter:dY,__generator:cY,__createBinding:G6,__exportStar:pY,__values:Y6,__read:L9,__spread:lY,__spreadArrays:iY,__spreadArray:nY,__await:D0,__asyncGenerator:oY,__asyncDelegator:aY,__asyncValues:sY,__makeTemplateObject:rY,__importStar:tY,__importDefault:eY,__classPrivateFieldGet:ZG,__classPrivateFieldSet:JG,__classPrivateFieldIn:YG,__addDisposableResource:GG,__disposeResources:QG,__rewriteRelativeImportExtension:XG}});var nG=A((LD,iG)=>{/*! Axios v1.13.5 Copyright (c) 2026 Matt Zabriskie and contributors */function PG(Z,J){return function(){return Z.apply(J,arguments)}}var{toString:NK}=Object.prototype,{getPrototypeOf:D9}=Object,{iterator:B6,toStringTag:TG}=Symbol,K6=((Z)=>(J)=>{let Y=NK.call(J);return Z[Y]||(Z[Y]=Y.slice(8,-1).toLowerCase())})(Object.create(null)),O1=(Z)=>{return Z=Z.toLowerCase(),(J)=>K6(J)===Z},L6=(Z)=>(J)=>typeof J===Z,{isArray:A0}=Array,N0=L6("undefined");function t0(Z){return Z!==null&&!N0(Z)&&Z.constructor!==null&&!N0(Z.constructor)&&J1(Z.constructor.isBuffer)&&Z.constructor.isBuffer(Z)}var wG=O1("ArrayBuffer");function AK(Z){let J;if(typeof ArrayBuffer<"u"&&ArrayBuffer.isView)J=ArrayBuffer.isView(Z);else J=Z&&Z.buffer&&wG(Z.buffer);return J}var RK=L6("string"),J1=L6("function"),EG=L6("number"),e0=(Z)=>Z!==null&&typeof Z==="object",PK=(Z)=>Z===!0||Z===!1,X6=(Z)=>{if(K6(Z)!=="object")return!1;let J=D9(Z);return(J===null||J===Object.prototype||Object.getPrototypeOf(J)===null)&&!(TG in Z)&&!(B6 in Z)},TK=(Z)=>{if(!e0(Z)||t0(Z))return!1;try{return Object.keys(Z).length===0&&Object.getPrototypeOf(Z)===Object.prototype}catch(J){return!1}},wK=O1("Date"),EK=O1("File"),SK=O1("Blob"),xK=O1("FileList"),fK=(Z)=>e0(Z)&&J1(Z.pipe),CK=(Z)=>{let J;return Z&&(typeof FormData==="function"&&Z instanceof FormData||J1(Z.append)&&((J=K6(Z))==="formdata"||J==="object"&&J1(Z.toString)&&Z.toString()==="[object FormData]"))},jK=O1("URLSearchParams"),[_K,kK,vK,hK]=["ReadableStream","Request","Response","Headers"].map(O1),bK=(Z)=>Z.trim?Z.trim():Z.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,"");function Z5(Z,J,{allOwnKeys:Y=!1}={}){if(Z===null||typeof Z>"u")return;let G,Q;if(typeof Z!=="object")Z=[Z];if(A0(Z))for(G=0,Q=Z.length;G<Q;G++)J.call(null,Z[G],G,Z);else{if(t0(Z))return;let X=Y?Object.getOwnPropertyNames(Z):Object.keys(Z),W=X.length,H;for(G=0;G<W;G++)H=X[G],J.call(null,Z[H],H,Z)}}function SG(Z,J){if(t0(Z))return null;J=J.toLowerCase();let Y=Object.keys(Z),G=Y.length,Q;while(G-- >0)if(Q=Y[G],J===Q.toLowerCase())return Q;return null}var Q0=(()=>{if(typeof globalThis<"u")return globalThis;return typeof self<"u"?self:typeof window<"u"?window:global})(),xG=(Z)=>!N0(Z)&&Z!==Q0;function O9(){let{caseless:Z,skipUndefined:J}=xG(this)&&this||{},Y={},G=(Q,X)=>{if(X==="__proto__"||X==="constructor"||X==="prototype")return;let W=Z&&SG(Y,X)||X;if(X6(Y[W])&&X6(Q))Y[W]=O9(Y[W],Q);else if(X6(Q))Y[W]=O9({},Q);else if(A0(Q))Y[W]=Q.slice();else if(!J||!N0(Q))Y[W]=Q};for(let Q=0,X=arguments.length;Q<X;Q++)arguments[Q]&&Z5(arguments[Q],G);return Y}var gK=(Z,J,Y,{allOwnKeys:G}={})=>{return Z5(J,(Q,X)=>{if(Y&&J1(Q))Object.defineProperty(Z,X,{value:PG(Q,Y),writable:!0,enumerable:!0,configurable:!0});else Object.defineProperty(Z,X,{value:Q,writable:!0,enumerable:!0,configurable:!0})},{allOwnKeys:G}),Z},yK=(Z)=>{if(Z.charCodeAt(0)===65279)Z=Z.slice(1);return Z},mK=(Z,J,Y,G)=>{Z.prototype=Object.create(J.prototype,G),Object.defineProperty(Z.prototype,"constructor",{value:Z,writable:!0,enumerable:!1,configurable:!0}),Object.defineProperty(Z,"super",{value:J.prototype}),Y&&Object.assign(Z.prototype,Y)},uK=(Z,J,Y,G)=>{let Q,X,W,H={};if(J=J||{},Z==null)return J;do{Q=Object.getOwnPropertyNames(Z),X=Q.length;while(X-- >0)if(W=Q[X],(!G||G(W,Z,J))&&!H[W])J[W]=Z[W],H[W]=!0;Z=Y!==!1&&D9(Z)}while(Z&&(!Y||Y(Z,J))&&Z!==Object.prototype);return J},dK=(Z,J,Y)=>{if(Z=String(Z),Y===void 0||Y>Z.length)Y=Z.length;Y-=J.length;let G=Z.indexOf(J,Y);return G!==-1&&G===Y},cK=(Z)=>{if(!Z)return null;if(A0(Z))return Z;let J=Z.length;if(!EG(J))return null;let Y=Array(J);while(J-- >0)Y[J]=Z[J];return Y},pK=((Z)=>{return(J)=>{return Z&&J instanceof Z}})(typeof Uint8Array<"u"&&D9(Uint8Array)),lK=(Z,J)=>{let G=(Z&&Z[B6]).call(Z),Q;while((Q=G.next())&&!Q.done){let X=Q.value;J.call(Z,X[0],X[1])}},iK=(Z,J)=>{let Y,G=[];while((Y=Z.exec(J))!==null)G.push(Y);return G},nK=O1("HTMLFormElement"),oK=(Z)=>{return Z.toLowerCase().replace(/[-_\s]([a-z\d])(\w*)/g,function(Y,G,Q){return G.toUpperCase()+Q})},zG=(({hasOwnProperty:Z})=>(J,Y)=>Z.call(J,Y))(Object.prototype),aK=O1("RegExp"),fG=(Z,J)=>{let Y=Object.getOwnPropertyDescriptors(Z),G={};Z5(Y,(Q,X)=>{let W;if((W=J(Q,X,Z))!==!1)G[X]=W||Q}),Object.defineProperties(Z,G)},sK=(Z)=>{fG(Z,(J,Y)=>{if(J1(Z)&&["arguments","caller","callee"].indexOf(Y)!==-1)return!1;let G=Z[Y];if(!J1(G))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 '"+Y+"'")}})},rK=(Z,J)=>{let Y={},G=(Q)=>{Q.forEach((X)=>{Y[X]=!0})};return A0(Z)?G(Z):G(String(Z).split(J)),Y},tK=()=>{},eK=(Z,J)=>{return Z!=null&&Number.isFinite(Z=+Z)?Z:J};function ZL(Z){return!!(Z&&J1(Z.append)&&Z[TG]==="FormData"&&Z[B6])}var JL=(Z)=>{let J=[,,,,,,,,,,],Y=(G,Q)=>{if(e0(G)){if(J.indexOf(G)>=0)return;if(t0(G))return G;if(!("toJSON"in G)){J[Q]=G;let X=A0(G)?[]:{};return Z5(G,(W,H)=>{let z=Y(W,Q+1);!N0(z)&&(X[H]=z)}),J[Q]=void 0,X}}return G};return Y(Z,0)},YL=O1("AsyncFunction"),GL=(Z)=>Z&&(e0(Z)||J1(Z))&&J1(Z.then)&&J1(Z.catch),CG=((Z,J)=>{if(Z)return setImmediate;return J?((Y,G)=>{return Q0.addEventListener("message",({source:Q,data:X})=>{if(Q===Q0&&X===Y)G.length&&G.shift()()},!1),(Q)=>{G.push(Q),Q0.postMessage(Y,"*")}})(`axios@${Math.random()}`,[]):(Y)=>setTimeout(Y)})(typeof setImmediate==="function",J1(Q0.postMessage)),QL=typeof queueMicrotask<"u"?queueMicrotask.bind(Q0):typeof process<"u"&&process.nextTick||CG,XL=(Z)=>Z!=null&&J1(Z[B6]),I={isArray:A0,isArrayBuffer:wG,isBuffer:t0,isFormData:CK,isArrayBufferView:AK,isString:RK,isNumber:EG,isBoolean:PK,isObject:e0,isPlainObject:X6,isEmptyObject:TK,isReadableStream:_K,isRequest:kK,isResponse:vK,isHeaders:hK,isUndefined:N0,isDate:wK,isFile:EK,isBlob:SK,isRegExp:aK,isFunction:J1,isStream:fK,isURLSearchParams:jK,isTypedArray:pK,isFileList:xK,forEach:Z5,merge:O9,extend:gK,trim:bK,stripBOM:yK,inherits:mK,toFlatObject:uK,kindOf:K6,kindOfTest:O1,endsWith:dK,toArray:cK,forEachEntry:lK,matchAll:iK,isHTMLForm:nK,hasOwnProperty:zG,hasOwnProp:zG,reduceDescriptors:fG,freezeMethods:sK,toObjectSet:rK,toCamelCase:oK,noop:tK,toFiniteNumber:eK,findKey:SG,global:Q0,isContextDefined:xG,isSpecCompliantForm:ZL,toJSONObject:JL,isAsyncFn:YL,isThenable:GL,setImmediate:CG,asap:QL,isIterable:XL};class t extends Error{static from(Z,J,Y,G,Q,X){let W=new t(Z.message,J||Z.code,Y,G,Q);return W.cause=Z,W.name=Z.name,X&&Object.assign(W,X),W}constructor(Z,J,Y,G,Q){super(Z);if(this.name="AxiosError",this.isAxiosError=!0,J&&(this.code=J),Y&&(this.config=Y),G&&(this.request=G),Q)this.response=Q,this.status=Q.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:I.toJSONObject(this.config),code:this.code,status:this.status}}}t.ERR_BAD_OPTION_VALUE="ERR_BAD_OPTION_VALUE";t.ERR_BAD_OPTION="ERR_BAD_OPTION";t.ECONNABORTED="ECONNABORTED";t.ETIMEDOUT="ETIMEDOUT";t.ERR_NETWORK="ERR_NETWORK";t.ERR_FR_TOO_MANY_REDIRECTS="ERR_FR_TOO_MANY_REDIRECTS";t.ERR_DEPRECATED="ERR_DEPRECATED";t.ERR_BAD_RESPONSE="ERR_BAD_RESPONSE";t.ERR_BAD_REQUEST="ERR_BAD_REQUEST";t.ERR_CANCELED="ERR_CANCELED";t.ERR_NOT_SUPPORT="ERR_NOT_SUPPORT";t.ERR_INVALID_URL="ERR_INVALID_URL";var x=t,WL=null;function V9(Z){return I.isPlainObject(Z)||I.isArray(Z)}function jG(Z){return I.endsWith(Z,"[]")?Z.slice(0,-2):Z}function UG(Z,J,Y){if(!Z)return J;return Z.concat(J).map(function(Q,X){return Q=jG(Q),!Y&&X?"["+Q+"]":Q}).join(Y?".":"")}function HL(Z){return I.isArray(Z)&&!Z.some(V9)}var zL=I.toFlatObject(I,{},null,function(J){return/^is[A-Z]/.test(J)});function M6(Z,J,Y){if(!I.isObject(Z))throw TypeError("target must be an object");J=J||new FormData,Y=I.toFlatObject(Y,{metaTokens:!0,dots:!1,indexes:!1},!1,function($,O){return!I.isUndefined(O[$])});let G=Y.metaTokens,Q=Y.visitor||B,X=Y.dots,W=Y.indexes,z=(Y.Blob||typeof Blob<"u"&&Blob)&&I.isSpecCompliantForm(J);if(!I.isFunction(Q))throw TypeError("visitor must be a function");function U(K){if(K===null)return"";if(I.isDate(K))return K.toISOString();if(I.isBoolean(K))return K.toString();if(!z&&I.isBlob(K))throw new x("Blob is not supported. Use a Buffer instead.");if(I.isArrayBuffer(K)||I.isTypedArray(K))return z&&typeof Blob==="function"?new Blob([K]):Buffer.from(K);return K}function B(K,$,O){let N=K;if(K&&!O&&typeof K==="object"){if(I.endsWith($,"{}"))$=G?$:$.slice(0,-2),K=JSON.stringify(K);else if(I.isArray(K)&&HL(K)||(I.isFileList(K)||I.endsWith($,"[]"))&&(N=I.toArray(K)))return $=jG($),N.forEach(function(D,q){!(I.isUndefined(D)||D===null)&&J.append(W===!0?UG([$],q,X):W===null?$:$+"[]",U(D))}),!1}if(V9(K))return!0;return J.append(UG(O,$,X),U(K)),!1}let L=[],F=Object.assign(zL,{defaultVisitor:B,convertValue:U,isVisitable:V9});function M(K,$){if(I.isUndefined(K))return;if(L.indexOf(K)!==-1)throw Error("Circular reference detected in "+$.join("."));L.push(K),I.forEach(K,function(N,P){if((!(I.isUndefined(N)||N===null)&&Q.call(J,N,I.isString(P)?P.trim():P,$,F))===!0)M(N,$?$.concat(P):[P])}),L.pop()}if(!I.isObject(Z))throw TypeError("data must be an object");return M(Z),J}function BG(Z){let J={"!":"%21","'":"%27","(":"%28",")":"%29","~":"%7E","%20":"+","%00":"\x00"};return encodeURIComponent(Z).replace(/[!'()~]|%20|%00/g,function(G){return J[G]})}function N9(Z,J){this._pairs=[],Z&&M6(Z,this,J)}var _G=N9.prototype;_G.append=function(J,Y){this._pairs.push([J,Y])};_G.toString=function(J){let Y=J?function(G){return J.call(this,G,BG)}:BG;return this._pairs.map(function(Q){return Y(Q[0])+"="+Y(Q[1])},"").join("&")};function UL(Z){return encodeURIComponent(Z).replace(/%3A/gi,":").replace(/%24/g,"$").replace(/%2C/gi,",").replace(/%20/g,"+")}function kG(Z,J,Y){if(!J)return Z;let G=Y&&Y.encode||UL,Q=I.isFunction(Y)?{serialize:Y}:Y,X=Q&&Q.serialize,W;if(X)W=X(J,Q);else W=I.isURLSearchParams(J)?J.toString():new N9(J,Q).toString(G);if(W){let H=Z.indexOf("#");if(H!==-1)Z=Z.slice(0,H);Z+=(Z.indexOf("?")===-1?"?":"&")+W}return Z}class vG{constructor(){this.handlers=[]}use(Z,J,Y){return this.handlers.push({fulfilled:Z,rejected:J,synchronous:Y?Y.synchronous:!1,runWhen:Y?Y.runWhen:null}),this.handlers.length-1}eject(Z){if(this.handlers[Z])this.handlers[Z]=null}clear(){if(this.handlers)this.handlers=[]}forEach(Z){I.forEach(this.handlers,function(Y){if(Y!==null)Z(Y)})}}var KG=vG,A9={silentJSONParsing:!0,forcedJSONParsing:!0,clarifyTimeoutError:!1,legacyInterceptorReqResOrdering:!0},BL=typeof URLSearchParams<"u"?URLSearchParams:N9,KL=typeof FormData<"u"?FormData:null,LL=typeof Blob<"u"?Blob:null,ML={isBrowser:!0,classes:{URLSearchParams:BL,FormData:KL,Blob:LL},protocols:["http","https","file","blob","url","data"]},R9=typeof window<"u"&&typeof document<"u",I9=typeof navigator==="object"&&navigator||void 0,$L=R9&&(!I9||["ReactNative","NativeScript","NS"].indexOf(I9.product)<0),FL=(()=>{return typeof WorkerGlobalScope<"u"&&self instanceof WorkerGlobalScope&&typeof self.importScripts==="function"})(),OL=R9&&window.location.href||"http://localhost",VL=Object.freeze({__proto__:null,hasBrowserEnv:R9,hasStandardBrowserWebWorkerEnv:FL,hasStandardBrowserEnv:$L,navigator:I9,origin:OL}),a={...VL,...ML};function IL(Z,J){return M6(Z,new a.classes.URLSearchParams,{visitor:function(Y,G,Q,X){if(a.isNode&&I.isBuffer(Y))return this.append(G,Y.toString("base64")),!1;return X.defaultVisitor.apply(this,arguments)},...J})}function qL(Z){return I.matchAll(/\w+|\[(\w*)]/g,Z).map((J)=>{return J[0]==="[]"?"":J[1]||J[0]})}function DL(Z){let J={},Y=Object.keys(Z),G,Q=Y.length,X;for(G=0;G<Q;G++)X=Y[G],J[X]=Z[X];return J}function hG(Z){function J(Y,G,Q,X){let W=Y[X++];if(W==="__proto__")return!0;let H=Number.isFinite(+W),z=X>=Y.length;if(W=!W&&I.isArray(Q)?Q.length:W,z){if(I.hasOwnProp(Q,W))Q[W]=[Q[W],G];else Q[W]=G;return!H}if(!Q[W]||!I.isObject(Q[W]))Q[W]=[];if(J(Y,G,Q[W],X)&&I.isArray(Q[W]))Q[W]=DL(Q[W]);return!H}if(I.isFormData(Z)&&I.isFunction(Z.entries)){let Y={};return I.forEachEntry(Z,(G,Q)=>{J(qL(G),Q,Y,0)}),Y}return null}function NL(Z,J,Y){if(I.isString(Z))try{return(J||JSON.parse)(Z),I.trim(Z)}catch(G){if(G.name!=="SyntaxError")throw G}return(Y||JSON.stringify)(Z)}var P9={transitional:A9,adapter:["xhr","http","fetch"],transformRequest:[function(J,Y){let G=Y.getContentType()||"",Q=G.indexOf("application/json")>-1,X=I.isObject(J);if(X&&I.isHTMLForm(J))J=new FormData(J);if(I.isFormData(J))return Q?JSON.stringify(hG(J)):J;if(I.isArrayBuffer(J)||I.isBuffer(J)||I.isStream(J)||I.isFile(J)||I.isBlob(J)||I.isReadableStream(J))return J;if(I.isArrayBufferView(J))return J.buffer;if(I.isURLSearchParams(J))return Y.setContentType("application/x-www-form-urlencoded;charset=utf-8",!1),J.toString();let H;if(X){if(G.indexOf("application/x-www-form-urlencoded")>-1)return IL(J,this.formSerializer).toString();if((H=I.isFileList(J))||G.indexOf("multipart/form-data")>-1){let z=this.env&&this.env.FormData;return M6(H?{"files[]":J}:J,z&&new z,this.formSerializer)}}if(X||Q)return Y.setContentType("application/json",!1),NL(J);return J}],transformResponse:[function(J){let Y=this.transitional||P9.transitional,G=Y&&Y.forcedJSONParsing,Q=this.responseType==="json";if(I.isResponse(J)||I.isReadableStream(J))return J;if(J&&I.isString(J)&&(G&&!this.responseType||Q)){let W=!(Y&&Y.silentJSONParsing)&&Q;try{return JSON.parse(J,this.parseReviver)}catch(H){if(W){if(H.name==="SyntaxError")throw x.from(H,x.ERR_BAD_RESPONSE,this,null,this.response);throw H}}}return J}],timeout:0,xsrfCookieName:"XSRF-TOKEN",xsrfHeaderName:"X-XSRF-TOKEN",maxContentLength:-1,maxBodyLength:-1,env:{FormData:a.classes.FormData,Blob:a.classes.Blob},validateStatus:function(J){return J>=200&&J<300},headers:{common:{Accept:"application/json, text/plain, */*","Content-Type":void 0}}};I.forEach(["delete","get","head","post","put","patch"],(Z)=>{P9.headers[Z]={}});var T9=P9,AL=I.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"]),RL=(Z)=>{let J={},Y,G,Q;return Z&&Z.split(`
|
|
10
|
+
`).forEach(function(W){if(Q=W.indexOf(":"),Y=W.substring(0,Q).trim().toLowerCase(),G=W.substring(Q+1).trim(),!Y||J[Y]&&AL[Y])return;if(Y==="set-cookie")if(J[Y])J[Y].push(G);else J[Y]=[G];else J[Y]=J[Y]?J[Y]+", "+G:G}),J},LG=Symbol("internals");function s0(Z){return Z&&String(Z).trim().toLowerCase()}function W6(Z){if(Z===!1||Z==null)return Z;return I.isArray(Z)?Z.map(W6):String(Z)}function PL(Z){let J=Object.create(null),Y=/([^\s,;=]+)\s*(?:=\s*([^,;]+))?/g,G;while(G=Y.exec(Z))J[G[1]]=G[2];return J}var TL=(Z)=>/^[-_a-zA-Z0-9^`|~,!#$%&'*+.]+$/.test(Z.trim());function M9(Z,J,Y,G,Q){if(I.isFunction(G))return G.call(this,J,Y);if(Q)J=Y;if(!I.isString(J))return;if(I.isString(G))return J.indexOf(G)!==-1;if(I.isRegExp(G))return G.test(J)}function wL(Z){return Z.trim().toLowerCase().replace(/([a-z\d])(\w*)/g,(J,Y,G)=>{return Y.toUpperCase()+G})}function EL(Z,J){let Y=I.toCamelCase(" "+J);["get","set","has"].forEach((G)=>{Object.defineProperty(Z,G+Y,{value:function(Q,X,W){return this[G].call(this,J,Q,X,W)},configurable:!0})})}class J5{constructor(Z){Z&&this.set(Z)}set(Z,J,Y){let G=this;function Q(W,H,z){let U=s0(H);if(!U)throw Error("header name must be a non-empty string");let B=I.findKey(G,U);if(!B||G[B]===void 0||z===!0||z===void 0&&G[B]!==!1)G[B||H]=W6(W)}let X=(W,H)=>I.forEach(W,(z,U)=>Q(z,U,H));if(I.isPlainObject(Z)||Z instanceof this.constructor)X(Z,J);else if(I.isString(Z)&&(Z=Z.trim())&&!TL(Z))X(RL(Z),J);else if(I.isObject(Z)&&I.isIterable(Z)){let W={},H,z;for(let U of Z){if(!I.isArray(U))throw TypeError("Object iterator must return a key-value pair");W[z=U[0]]=(H=W[z])?I.isArray(H)?[...H,U[1]]:[H,U[1]]:U[1]}X(W,J)}else Z!=null&&Q(J,Z,Y);return this}get(Z,J){if(Z=s0(Z),Z){let Y=I.findKey(this,Z);if(Y){let G=this[Y];if(!J)return G;if(J===!0)return PL(G);if(I.isFunction(J))return J.call(this,G,Y);if(I.isRegExp(J))return J.exec(G);throw TypeError("parser must be boolean|regexp|function")}}}has(Z,J){if(Z=s0(Z),Z){let Y=I.findKey(this,Z);return!!(Y&&this[Y]!==void 0&&(!J||M9(this,this[Y],Y,J)))}return!1}delete(Z,J){let Y=this,G=!1;function Q(X){if(X=s0(X),X){let W=I.findKey(Y,X);if(W&&(!J||M9(Y,Y[W],W,J)))delete Y[W],G=!0}}if(I.isArray(Z))Z.forEach(Q);else Q(Z);return G}clear(Z){let J=Object.keys(this),Y=J.length,G=!1;while(Y--){let Q=J[Y];if(!Z||M9(this,this[Q],Q,Z,!0))delete this[Q],G=!0}return G}normalize(Z){let J=this,Y={};return I.forEach(this,(G,Q)=>{let X=I.findKey(Y,Q);if(X){J[X]=W6(G),delete J[Q];return}let W=Z?wL(Q):String(Q).trim();if(W!==Q)delete J[Q];J[W]=W6(G),Y[W]=!0}),this}concat(...Z){return this.constructor.concat(this,...Z)}toJSON(Z){let J=Object.create(null);return I.forEach(this,(Y,G)=>{Y!=null&&Y!==!1&&(J[G]=Z&&I.isArray(Y)?Y.join(", "):Y)}),J}[Symbol.iterator](){return Object.entries(this.toJSON())[Symbol.iterator]()}toString(){return Object.entries(this.toJSON()).map(([Z,J])=>Z+": "+J).join(`
|
|
11
|
+
`)}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 Y=new this(Z);return J.forEach((G)=>Y.set(G)),Y}static accessor(Z){let Y=(this[LG]=this[LG]={accessors:{}}).accessors,G=this.prototype;function Q(X){let W=s0(X);if(!Y[W])EL(G,X),Y[W]=!0}return I.isArray(Z)?Z.forEach(Q):Q(Z),this}}J5.accessor(["Content-Type","Content-Length","Accept","Accept-Encoding","User-Agent","Authorization"]);I.reduceDescriptors(J5.prototype,({value:Z},J)=>{let Y=J[0].toUpperCase()+J.slice(1);return{get:()=>Z,set(G){this[Y]=G}}});I.freezeMethods(J5);var F1=J5;function $9(Z,J){let Y=this||T9,G=J||Y,Q=F1.from(G.headers),X=G.data;return I.forEach(Z,function(H){X=H.call(Y,X,Q.normalize(),J?J.status:void 0)}),Q.normalize(),X}function bG(Z){return!!(Z&&Z.__CANCEL__)}class gG extends x{constructor(Z,J,Y){super(Z==null?"canceled":Z,x.ERR_CANCELED,J,Y);this.name="CanceledError",this.__CANCEL__=!0}}var Y5=gG;function yG(Z,J,Y){let G=Y.config.validateStatus;if(!Y.status||!G||G(Y.status))Z(Y);else J(new x("Request failed with status code "+Y.status,[x.ERR_BAD_REQUEST,x.ERR_BAD_RESPONSE][Math.floor(Y.status/100)-4],Y.config,Y.request,Y))}function SL(Z){let J=/^([-+\w]{1,25})(:?\/\/|:)/.exec(Z);return J&&J[1]||""}function xL(Z,J){Z=Z||10;let Y=Array(Z),G=Array(Z),Q=0,X=0,W;return J=J!==void 0?J:1000,function(z){let U=Date.now(),B=G[X];if(!W)W=U;Y[Q]=z,G[Q]=U;let L=X,F=0;while(L!==Q)F+=Y[L++],L=L%Z;if(Q=(Q+1)%Z,Q===X)X=(X+1)%Z;if(U-W<J)return;let M=B&&U-B;return M?Math.round(F*1000/M):void 0}}function fL(Z,J){let Y=0,G=1000/J,Q,X,W=(U,B=Date.now())=>{if(Y=B,Q=null,X)clearTimeout(X),X=null;Z(...U)};return[(...U)=>{let B=Date.now(),L=B-Y;if(L>=G)W(U,B);else if(Q=U,!X)X=setTimeout(()=>{X=null,W(Q)},G-L)},()=>Q&&W(Q)]}var U6=(Z,J,Y=3)=>{let G=0,Q=xL(50,250);return fL((X)=>{let W=X.loaded,H=X.lengthComputable?X.total:void 0,z=W-G,U=Q(z),B=W<=H;G=W;let L={loaded:W,total:H,progress:H?W/H:void 0,bytes:z,rate:U?U:void 0,estimated:U&&H&&B?(H-W)/U:void 0,event:X,lengthComputable:H!=null,[J?"download":"upload"]:!0};Z(L)},Y)},MG=(Z,J)=>{let Y=Z!=null;return[(G)=>J[0]({lengthComputable:Y,total:Z,loaded:G}),J[1]]},$G=(Z)=>(...J)=>I.asap(()=>Z(...J)),CL=a.hasStandardBrowserEnv?((Z,J)=>(Y)=>{return Y=new URL(Y,a.origin),Z.protocol===Y.protocol&&Z.host===Y.host&&(J||Z.port===Y.port)})(new URL(a.origin),a.navigator&&/(msie|trident)/i.test(a.navigator.userAgent)):()=>!0,jL=a.hasStandardBrowserEnv?{write(Z,J,Y,G,Q,X,W){if(typeof document>"u")return;let H=[`${Z}=${encodeURIComponent(J)}`];if(I.isNumber(Y))H.push(`expires=${new Date(Y).toUTCString()}`);if(I.isString(G))H.push(`path=${G}`);if(I.isString(Q))H.push(`domain=${Q}`);if(X===!0)H.push("secure");if(I.isString(W))H.push(`SameSite=${W}`);document.cookie=H.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 _L(Z){if(typeof Z!=="string")return!1;return/^([a-z][a-z\d+\-.]*:)?\/\//i.test(Z)}function kL(Z,J){return J?Z.replace(/\/?\/$/,"")+"/"+J.replace(/^\/+/,""):Z}function mG(Z,J,Y){let G=!_L(J);if(Z&&(G||Y==!1))return kL(Z,J);return J}var FG=(Z)=>Z instanceof F1?{...Z}:Z;function X0(Z,J){J=J||{};let Y={};function G(U,B,L,F){if(I.isPlainObject(U)&&I.isPlainObject(B))return I.merge.call({caseless:F},U,B);else if(I.isPlainObject(B))return I.merge({},B);else if(I.isArray(B))return B.slice();return B}function Q(U,B,L,F){if(!I.isUndefined(B))return G(U,B,L,F);else if(!I.isUndefined(U))return G(void 0,U,L,F)}function X(U,B){if(!I.isUndefined(B))return G(void 0,B)}function W(U,B){if(!I.isUndefined(B))return G(void 0,B);else if(!I.isUndefined(U))return G(void 0,U)}function H(U,B,L){if(L in J)return G(U,B);else if(L in Z)return G(void 0,U)}let z={url:X,method:X,data:X,baseURL:W,transformRequest:W,transformResponse:W,paramsSerializer:W,timeout:W,timeoutMessage:W,withCredentials:W,withXSRFToken:W,adapter:W,responseType:W,xsrfCookieName:W,xsrfHeaderName:W,onUploadProgress:W,onDownloadProgress:W,decompress:W,maxContentLength:W,maxBodyLength:W,beforeRedirect:W,transport:W,httpAgent:W,httpsAgent:W,cancelToken:W,socketPath:W,responseEncoding:W,validateStatus:H,headers:(U,B,L)=>Q(FG(U),FG(B),L,!0)};return I.forEach(Object.keys({...Z,...J}),function(B){if(B==="__proto__"||B==="constructor"||B==="prototype")return;let L=I.hasOwnProp(z,B)?z[B]:Q,F=L(Z[B],J[B],B);I.isUndefined(F)&&L!==H||(Y[B]=F)}),Y}var uG=(Z)=>{let J=X0({},Z),{data:Y,withXSRFToken:G,xsrfHeaderName:Q,xsrfCookieName:X,headers:W,auth:H}=J;if(J.headers=W=F1.from(W),J.url=kG(mG(J.baseURL,J.url,J.allowAbsoluteUrls),Z.params,Z.paramsSerializer),H)W.set("Authorization","Basic "+btoa((H.username||"")+":"+(H.password?unescape(encodeURIComponent(H.password)):"")));if(I.isFormData(Y)){if(a.hasStandardBrowserEnv||a.hasStandardBrowserWebWorkerEnv)W.setContentType(void 0);else if(I.isFunction(Y.getHeaders)){let z=Y.getHeaders(),U=["content-type","content-length"];Object.entries(z).forEach(([B,L])=>{if(U.includes(B.toLowerCase()))W.set(B,L)})}}if(a.hasStandardBrowserEnv){if(G&&I.isFunction(G)&&(G=G(J)),G||G!==!1&&CL(J.url)){let z=Q&&X&&jL.read(X);if(z)W.set(Q,z)}}return J},vL=typeof XMLHttpRequest<"u",hL=vL&&function(Z){return new Promise(function(Y,G){let Q=uG(Z),X=Q.data,W=F1.from(Q.headers).normalize(),{responseType:H,onUploadProgress:z,onDownloadProgress:U}=Q,B,L,F,M,K;function $(){M&&M(),K&&K(),Q.cancelToken&&Q.cancelToken.unsubscribe(B),Q.signal&&Q.signal.removeEventListener("abort",B)}let O=new XMLHttpRequest;O.open(Q.method.toUpperCase(),Q.url,!0),O.timeout=Q.timeout;function N(){if(!O)return;let D=F1.from("getAllResponseHeaders"in O&&O.getAllResponseHeaders()),T={data:!H||H==="text"||H==="json"?O.responseText:O.response,status:O.status,statusText:O.statusText,headers:D,config:Z,request:O};yG(function(u){Y(u),$()},function(u){G(u),$()},T),O=null}if("onloadend"in O)O.onloadend=N;else O.onreadystatechange=function(){if(!O||O.readyState!==4)return;if(O.status===0&&!(O.responseURL&&O.responseURL.indexOf("file:")===0))return;setTimeout(N)};if(O.onabort=function(){if(!O)return;G(new x("Request aborted",x.ECONNABORTED,Z,O)),O=null},O.onerror=function(q){let T=q&&q.message?q.message:"Network Error",f=new x(T,x.ERR_NETWORK,Z,O);f.event=q||null,G(f),O=null},O.ontimeout=function(){let q=Q.timeout?"timeout of "+Q.timeout+"ms exceeded":"timeout exceeded",T=Q.transitional||A9;if(Q.timeoutErrorMessage)q=Q.timeoutErrorMessage;G(new x(q,T.clarifyTimeoutError?x.ETIMEDOUT:x.ECONNABORTED,Z,O)),O=null},X===void 0&&W.setContentType(null),"setRequestHeader"in O)I.forEach(W.toJSON(),function(q,T){O.setRequestHeader(T,q)});if(!I.isUndefined(Q.withCredentials))O.withCredentials=!!Q.withCredentials;if(H&&H!=="json")O.responseType=Q.responseType;if(U)[F,K]=U6(U,!0),O.addEventListener("progress",F);if(z&&O.upload)[L,M]=U6(z),O.upload.addEventListener("progress",L),O.upload.addEventListener("loadend",M);if(Q.cancelToken||Q.signal){if(B=(D)=>{if(!O)return;G(!D||D.type?new Y5(null,Z,O):D),O.abort(),O=null},Q.cancelToken&&Q.cancelToken.subscribe(B),Q.signal)Q.signal.aborted?B():Q.signal.addEventListener("abort",B)}let P=SL(Q.url);if(P&&a.protocols.indexOf(P)===-1){G(new x("Unsupported protocol "+P+":",x.ERR_BAD_REQUEST,Z));return}O.send(X||null)})},bL=(Z,J)=>{let{length:Y}=Z=Z?Z.filter(Boolean):[];if(J||Y){let G=new AbortController,Q,X=function(U){if(!Q){Q=!0,H();let B=U instanceof Error?U:this.reason;G.abort(B instanceof x?B:new Y5(B instanceof Error?B.message:B))}},W=J&&setTimeout(()=>{W=null,X(new x(`timeout of ${J}ms exceeded`,x.ETIMEDOUT))},J),H=()=>{if(Z)W&&clearTimeout(W),W=null,Z.forEach((U)=>{U.unsubscribe?U.unsubscribe(X):U.removeEventListener("abort",X)}),Z=null};Z.forEach((U)=>U.addEventListener("abort",X));let{signal:z}=G;return z.unsubscribe=()=>I.asap(H),z}},gL=bL,yL=function*(Z,J){let Y=Z.byteLength;if(!J||Y<J){yield Z;return}let G=0,Q;while(G<Y)Q=G+J,yield Z.slice(G,Q),G=Q},mL=async function*(Z,J){for await(let Y of uL(Z))yield*yL(Y,J)},uL=async function*(Z){if(Z[Symbol.asyncIterator]){yield*Z;return}let J=Z.getReader();try{for(;;){let{done:Y,value:G}=await J.read();if(Y)break;yield G}}finally{await J.cancel()}},OG=(Z,J,Y,G)=>{let Q=mL(Z,J),X=0,W,H=(z)=>{if(!W)W=!0,G&&G(z)};return new ReadableStream({async pull(z){try{let{done:U,value:B}=await Q.next();if(U){H(),z.close();return}let L=B.byteLength;if(Y){let F=X+=L;Y(F)}z.enqueue(new Uint8Array(B))}catch(U){throw H(U),U}},cancel(z){return H(z),Q.return()}},{highWaterMark:2})},VG=65536,{isFunction:Q6}=I,dL=(({Request:Z,Response:J})=>({Request:Z,Response:J}))(I.global),{ReadableStream:IG,TextEncoder:qG}=I.global,DG=(Z,...J)=>{try{return!!Z(...J)}catch(Y){return!1}},cL=(Z)=>{Z=I.merge.call({skipUndefined:!0},dL,Z);let{fetch:J,Request:Y,Response:G}=Z,Q=J?Q6(J):typeof fetch==="function",X=Q6(Y),W=Q6(G);if(!Q)return!1;let H=Q&&Q6(IG),z=Q&&(typeof qG==="function"?((K)=>($)=>K.encode($))(new qG):async(K)=>new Uint8Array(await new Y(K).arrayBuffer())),U=X&&H&&DG(()=>{let K=!1,$=new Y(a.origin,{body:new IG,method:"POST",get duplex(){return K=!0,"half"}}).headers.has("Content-Type");return K&&!$}),B=W&&H&&DG(()=>I.isReadableStream(new G("").body)),L={stream:B&&((K)=>K.body)};Q&&(()=>{["text","arrayBuffer","blob","formData","stream"].forEach((K)=>{!L[K]&&(L[K]=($,O)=>{let N=$&&$[K];if(N)return N.call($);throw new x(`Response type '${K}' is not supported`,x.ERR_NOT_SUPPORT,O)})})})();let F=async(K)=>{if(K==null)return 0;if(I.isBlob(K))return K.size;if(I.isSpecCompliantForm(K))return(await new Y(a.origin,{method:"POST",body:K}).arrayBuffer()).byteLength;if(I.isArrayBufferView(K)||I.isArrayBuffer(K))return K.byteLength;if(I.isURLSearchParams(K))K=K+"";if(I.isString(K))return(await z(K)).byteLength},M=async(K,$)=>{let O=I.toFiniteNumber(K.getContentLength());return O==null?F($):O};return async(K)=>{let{url:$,method:O,data:N,signal:P,cancelToken:D,timeout:q,onDownloadProgress:T,onUploadProgress:f,responseType:u,headers:a1,withCredentials:C1="same-origin",fetchOptions:j1}=uG(K),k=J||fetch;u=u?(u+"").toLowerCase():"text";let R1=gL([P,D&&D.toAbortSignal()],q),p=null,P1=R1&&R1.unsubscribe&&(()=>{R1.unsubscribe()}),V;try{if(f&&U&&O!=="get"&&O!=="head"&&(V=await M(a1,N))!==0){let k1=new Y($,{method:"POST",body:N,duplex:"half"}),z0;if(I.isFormData(N)&&(z0=k1.headers.get("content-type")))a1.setContentType(z0);if(k1.body){let[S6,F5]=MG(V,U6($G(f)));N=OG(k1.body,VG,S6,F5)}}if(!I.isString(C1))C1=C1?"include":"omit";let l=X&&"credentials"in Y.prototype,g={...j1,signal:R1,method:O.toUpperCase(),headers:a1.normalize().toJSON(),body:N,duplex:"half",credentials:l?C1:void 0};p=X&&new Y($,g);let M1=await(X?k(p,j1):k($,g)),_1=B&&(u==="stream"||u==="response");if(B&&(T||_1&&P1)){let k1={};["status","statusText","headers"].forEach((V7)=>{k1[V7]=M1[V7]});let z0=I.toFiniteNumber(M1.headers.get("content-length")),[S6,F5]=T&&MG(z0,U6($G(T),!0))||[];M1=new G(OG(M1.body,VG,S6,()=>{F5&&F5(),P1&&P1()}),k1)}u=u||"text";let T1=await L[I.findKey(L,u)||"text"](M1,K);return!_1&&P1&&P1(),await new Promise((k1,z0)=>{yG(k1,z0,{data:T1,headers:F1.from(M1.headers),status:M1.status,statusText:M1.statusText,config:K,request:p})})}catch(l){if(P1&&P1(),l&&l.name==="TypeError"&&/Load failed|fetch/i.test(l.message))throw Object.assign(new x("Network Error",x.ERR_NETWORK,K,p,l&&l.response),{cause:l.cause||l});throw x.from(l,l&&l.code,K,p,l&&l.response)}}},pL=new Map,dG=(Z)=>{let J=Z&&Z.env||{},{fetch:Y,Request:G,Response:Q}=J,X=[G,Q,Y],W=X.length,H=W,z,U,B=pL;while(H--)z=X[H],U=B.get(z),U===void 0&&B.set(z,U=H?new Map:cL(J)),B=U;return U};dG();var w9={http:WL,xhr:hL,fetch:{get:dG}};I.forEach(w9,(Z,J)=>{if(Z){try{Object.defineProperty(Z,"name",{value:J})}catch(Y){}Object.defineProperty(Z,"adapterName",{value:J})}});var NG=(Z)=>`- ${Z}`,lL=(Z)=>I.isFunction(Z)||Z===null||Z===!1;function iL(Z,J){Z=I.isArray(Z)?Z:[Z];let{length:Y}=Z,G,Q,X={};for(let W=0;W<Y;W++){G=Z[W];let H;if(Q=G,!lL(G)){if(Q=w9[(H=String(G)).toLowerCase()],Q===void 0)throw new x(`Unknown adapter '${H}'`)}if(Q&&(I.isFunction(Q)||(Q=Q.get(J))))break;X[H||"#"+W]=Q}if(!Q){let W=Object.entries(X).map(([z,U])=>`adapter ${z} `+(U===!1?"is not supported by the environment":"is not available in the build")),H=Y?W.length>1?`since :
|
|
12
|
+
`+W.map(NG).join(`
|
|
13
|
+
`):" "+NG(W[0]):"as no adapter specified";throw new x("There is no suitable adapter to dispatch the request "+H,"ERR_NOT_SUPPORT")}return Q}var cG={getAdapter:iL,adapters:w9};function F9(Z){if(Z.cancelToken)Z.cancelToken.throwIfRequested();if(Z.signal&&Z.signal.aborted)throw new Y5(null,Z)}function AG(Z){if(F9(Z),Z.headers=F1.from(Z.headers),Z.data=$9.call(Z,Z.transformRequest),["post","put","patch"].indexOf(Z.method)!==-1)Z.headers.setContentType("application/x-www-form-urlencoded",!1);return cG.getAdapter(Z.adapter||T9.adapter,Z)(Z).then(function(G){return F9(Z),G.data=$9.call(Z,Z.transformResponse,G),G.headers=F1.from(G.headers),G},function(G){if(!bG(G)){if(F9(Z),G&&G.response)G.response.data=$9.call(Z,Z.transformResponse,G.response),G.response.headers=F1.from(G.response.headers)}return Promise.reject(G)})}var pG="1.13.5",$6={};["object","boolean","number","function","string","symbol"].forEach((Z,J)=>{$6[Z]=function(G){return typeof G===Z||"a"+(J<1?"n ":" ")+Z}});var RG={};$6.transitional=function(J,Y,G){function Q(X,W){return"[Axios v"+pG+"] Transitional option '"+X+"'"+W+(G?". "+G:"")}return(X,W,H)=>{if(J===!1)throw new x(Q(W," has been removed"+(Y?" in "+Y:"")),x.ERR_DEPRECATED);if(Y&&!RG[W])RG[W]=!0,console.warn(Q(W," has been deprecated since v"+Y+" and will be removed in the near future"));return J?J(X,W,H):!0}};$6.spelling=function(J){return(Y,G)=>{return console.warn(`${G} is likely a misspelling of ${J}`),!0}};function nL(Z,J,Y){if(typeof Z!=="object")throw new x("options must be an object",x.ERR_BAD_OPTION_VALUE);let G=Object.keys(Z),Q=G.length;while(Q-- >0){let X=G[Q],W=J[X];if(W){let H=Z[X],z=H===void 0||W(H,X,Z);if(z!==!0)throw new x("option "+X+" must be "+z,x.ERR_BAD_OPTION_VALUE);continue}if(Y!==!0)throw new x("Unknown option "+X,x.ERR_BAD_OPTION)}}var H6={assertOptions:nL,validators:$6},L1=H6.validators;class r0{constructor(Z){this.defaults=Z||{},this.interceptors={request:new KG,response:new KG}}async request(Z,J){try{return await this._request(Z,J)}catch(Y){if(Y instanceof Error){let G={};Error.captureStackTrace?Error.captureStackTrace(G):G=Error();let Q=G.stack?G.stack.replace(/^.+\n/,""):"";try{if(!Y.stack)Y.stack=Q;else if(Q&&!String(Y.stack).endsWith(Q.replace(/^.+\n.+\n/,"")))Y.stack+=`
|
|
14
|
+
`+Q}catch(X){}}throw Y}}_request(Z,J){if(typeof Z==="string")J=J||{},J.url=Z;else J=Z||{};J=X0(this.defaults,J);let{transitional:Y,paramsSerializer:G,headers:Q}=J;if(Y!==void 0)H6.assertOptions(Y,{silentJSONParsing:L1.transitional(L1.boolean),forcedJSONParsing:L1.transitional(L1.boolean),clarifyTimeoutError:L1.transitional(L1.boolean),legacyInterceptorReqResOrdering:L1.transitional(L1.boolean)},!1);if(G!=null)if(I.isFunction(G))J.paramsSerializer={serialize:G};else H6.assertOptions(G,{encode:L1.function,serialize:L1.function},!0);if(J.allowAbsoluteUrls!==void 0);else if(this.defaults.allowAbsoluteUrls!==void 0)J.allowAbsoluteUrls=this.defaults.allowAbsoluteUrls;else J.allowAbsoluteUrls=!0;H6.assertOptions(J,{baseUrl:L1.spelling("baseURL"),withXsrfToken:L1.spelling("withXSRFToken")},!0),J.method=(J.method||this.defaults.method||"get").toLowerCase();let X=Q&&I.merge(Q.common,Q[J.method]);Q&&I.forEach(["delete","get","head","post","put","patch","common"],(M)=>{delete Q[M]}),J.headers=F1.concat(X,Q);let W=[],H=!0;this.interceptors.request.forEach(function(K){if(typeof K.runWhen==="function"&&K.runWhen(J)===!1)return;H=H&&K.synchronous;let $=J.transitional||A9;if($&&$.legacyInterceptorReqResOrdering)W.unshift(K.fulfilled,K.rejected);else W.push(K.fulfilled,K.rejected)});let z=[];this.interceptors.response.forEach(function(K){z.push(K.fulfilled,K.rejected)});let U,B=0,L;if(!H){let M=[AG.bind(this),void 0];M.unshift(...W),M.push(...z),L=M.length,U=Promise.resolve(J);while(B<L)U=U.then(M[B++],M[B++]);return U}L=W.length;let F=J;while(B<L){let M=W[B++],K=W[B++];try{F=M(F)}catch($){K.call(this,$);break}}try{U=AG.call(this,F)}catch(M){return Promise.reject(M)}B=0,L=z.length;while(B<L)U=U.then(z[B++],z[B++]);return U}getUri(Z){Z=X0(this.defaults,Z);let J=mG(Z.baseURL,Z.url,Z.allowAbsoluteUrls);return kG(J,Z.params,Z.paramsSerializer)}}I.forEach(["delete","get","head","options"],function(J){r0.prototype[J]=function(Y,G){return this.request(X0(G||{},{method:J,url:Y,data:(G||{}).data}))}});I.forEach(["post","put","patch"],function(J){function Y(G){return function(X,W,H){return this.request(X0(H||{},{method:J,headers:G?{"Content-Type":"multipart/form-data"}:{},url:X,data:W}))}}r0.prototype[J]=Y(),r0.prototype[J+"Form"]=Y(!0)});var z6=r0;class E9{constructor(Z){if(typeof Z!=="function")throw TypeError("executor must be a function.");let J;this.promise=new Promise(function(Q){J=Q});let Y=this;this.promise.then((G)=>{if(!Y._listeners)return;let Q=Y._listeners.length;while(Q-- >0)Y._listeners[Q](G);Y._listeners=null}),this.promise.then=(G)=>{let Q,X=new Promise((W)=>{Y.subscribe(W),Q=W}).then(G);return X.cancel=function(){Y.unsubscribe(Q)},X},Z(function(Q,X,W){if(Y.reason)return;Y.reason=new Y5(Q,X,W),J(Y.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=(Y)=>{Z.abort(Y)};return this.subscribe(J),Z.signal.unsubscribe=()=>this.unsubscribe(J),Z.signal}static source(){let Z;return{token:new E9(function(G){Z=G}),cancel:Z}}}var oL=E9;function aL(Z){return function(Y){return Z.apply(null,Y)}}function sL(Z){return I.isObject(Z)&&Z.isAxiosError===!0}var q9={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(q9).forEach(([Z,J])=>{q9[J]=Z});var rL=q9;function lG(Z){let J=new z6(Z),Y=PG(z6.prototype.request,J);return I.extend(Y,z6.prototype,J,{allOwnKeys:!0}),I.extend(Y,J,null,{allOwnKeys:!0}),Y.create=function(Q){return lG(X0(Z,Q))},Y}var b=lG(T9);b.Axios=z6;b.CanceledError=Y5;b.CancelToken=oL;b.isCancel=bG;b.VERSION=pG;b.toFormData=M6;b.AxiosError=x;b.Cancel=b.CanceledError;b.all=function(J){return Promise.all(J)};b.spread=aL;b.isAxiosError=sL;b.mergeConfig=X0;b.AxiosHeaders=F1;b.formToJSON=(Z)=>hG(I.isHTMLForm(Z)?new FormData(Z):Z);b.getAdapter=cG.getAdapter;b.HttpStatusCode=rL;b.default=b;iG.exports=b});var x9=A((aG)=>{Object.defineProperty(aG,"__esModule",{value:!0});aG.addAxiosDateTransformer=aG.createAxiosDateTransformer=void 0;var tL=(HG(),dX(WG)),eL=tL.__importDefault(nG()),ZM=/^\d{4}-\d{2}-\d{2}(T\d{2}:\d{2}:\d{2}(?:\.\d*)?(?:[-+]\d{2}:?\d{2}|Z)?)?$/,JM=(Z)=>{return ZM.test(Z)},YM=(Z,J)=>{return!J||J.length===0||J.includes(Z)},GM=(Z,J,Y)=>{return typeof J==="string"&&JM(J)&&YM(Z,Y)},oG=(Z,J)=>{if(typeof Z==="object"){for(let Y in Z)if(GM(Y,Z[Y],J))Z[Y]=new Date(Z[Y]);else if(typeof Z[Y]==="object")Z[Y]=oG(Z[Y],J)}return Z},QM=(Z,J)=>{if(Z.data)Z.data=oG(Z.data,J);return Z},XM=(Z={})=>{return aG.addAxiosDateTransformer(eL.default.create(Z),Z)};aG.createAxiosDateTransformer=XM;var WM=(Z,J)=>{let Y=J===null||J===void 0?void 0:J.allowlist;return Z.interceptors.response.use((G)=>QM(G,Y)),Z};aG.addAxiosDateTransformer=WM});var k9=A((QQ)=>{Object.defineProperty(QQ,"__esModule",{value:!0});QQ.Doctype=QQ.CDATA=QQ.Tag=QQ.Style=QQ.Script=QQ.Comment=QQ.Directive=QQ.Text=QQ.Root=QQ.isTag=QQ.ElementType=void 0;var W1;(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"})(W1=QQ.ElementType||(QQ.ElementType={}));function OM(Z){return Z.type===W1.Tag||Z.type===W1.Script||Z.type===W1.Style}QQ.isTag=OM;QQ.Root=W1.Root;QQ.Text=W1.Text;QQ.Directive=W1.Directive;QQ.Comment=W1.Comment;QQ.Script=W1.Script;QQ.Style=W1.Style;QQ.Tag=W1.Tag;QQ.CDATA=W1.CDATA;QQ.Doctype=W1.Doctype});var g9=A((E)=>{var i1=E&&E.__extends||function(){var Z=function(J,Y){return Z=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(G,Q){G.__proto__=Q}||function(G,Q){for(var X in Q)if(Object.prototype.hasOwnProperty.call(Q,X))G[X]=Q[X]},Z(J,Y)};return function(J,Y){if(typeof Y!=="function"&&Y!==null)throw TypeError("Class extends value "+String(Y)+" is not a constructor or null");Z(J,Y);function G(){this.constructor=J}J.prototype=Y===null?Object.create(Y):(G.prototype=Y.prototype,new G)}}(),Q5=E&&E.__assign||function(){return Q5=Object.assign||function(Z){for(var J,Y=1,G=arguments.length;Y<G;Y++){J=arguments[Y];for(var Q in J)if(Object.prototype.hasOwnProperty.call(J,Q))Z[Q]=J[Q]}return Z},Q5.apply(this,arguments)};Object.defineProperty(E,"__esModule",{value:!0});E.cloneNode=E.hasChildren=E.isDocument=E.isDirective=E.isComment=E.isText=E.isCDATA=E.isTag=E.Element=E.Document=E.CDATA=E.NodeWithChildren=E.ProcessingInstruction=E.Comment=E.Text=E.DataNode=E.Node=void 0;var Y1=k9(),h9=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 b9(this,J)},Z}();E.Node=h9;var F6=function(Z){i1(J,Z);function J(Y){var G=Z.call(this)||this;return G.data=Y,G}return Object.defineProperty(J.prototype,"nodeValue",{get:function(){return this.data},set:function(Y){this.data=Y},enumerable:!1,configurable:!0}),J}(h9);E.DataNode=F6;var WQ=function(Z){i1(J,Z);function J(){var Y=Z!==null&&Z.apply(this,arguments)||this;return Y.type=Y1.ElementType.Text,Y}return Object.defineProperty(J.prototype,"nodeType",{get:function(){return 3},enumerable:!1,configurable:!0}),J}(F6);E.Text=WQ;var HQ=function(Z){i1(J,Z);function J(){var Y=Z!==null&&Z.apply(this,arguments)||this;return Y.type=Y1.ElementType.Comment,Y}return Object.defineProperty(J.prototype,"nodeType",{get:function(){return 8},enumerable:!1,configurable:!0}),J}(F6);E.Comment=HQ;var zQ=function(Z){i1(J,Z);function J(Y,G){var Q=Z.call(this,G)||this;return Q.name=Y,Q.type=Y1.ElementType.Directive,Q}return Object.defineProperty(J.prototype,"nodeType",{get:function(){return 1},enumerable:!1,configurable:!0}),J}(F6);E.ProcessingInstruction=zQ;var O6=function(Z){i1(J,Z);function J(Y){var G=Z.call(this)||this;return G.children=Y,G}return Object.defineProperty(J.prototype,"firstChild",{get:function(){var Y;return(Y=this.children[0])!==null&&Y!==void 0?Y: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(Y){this.children=Y},enumerable:!1,configurable:!0}),J}(h9);E.NodeWithChildren=O6;var UQ=function(Z){i1(J,Z);function J(){var Y=Z!==null&&Z.apply(this,arguments)||this;return Y.type=Y1.ElementType.CDATA,Y}return Object.defineProperty(J.prototype,"nodeType",{get:function(){return 4},enumerable:!1,configurable:!0}),J}(O6);E.CDATA=UQ;var BQ=function(Z){i1(J,Z);function J(){var Y=Z!==null&&Z.apply(this,arguments)||this;return Y.type=Y1.ElementType.Root,Y}return Object.defineProperty(J.prototype,"nodeType",{get:function(){return 9},enumerable:!1,configurable:!0}),J}(O6);E.Document=BQ;var KQ=function(Z){i1(J,Z);function J(Y,G,Q,X){if(Q===void 0)Q=[];if(X===void 0)X=Y==="script"?Y1.ElementType.Script:Y==="style"?Y1.ElementType.Style:Y1.ElementType.Tag;var W=Z.call(this,Q)||this;return W.name=Y,W.attribs=G,W.type=X,W}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(Y){this.name=Y},enumerable:!1,configurable:!0}),Object.defineProperty(J.prototype,"attributes",{get:function(){var Y=this;return Object.keys(this.attribs).map(function(G){var Q,X;return{name:G,value:Y.attribs[G],namespace:(Q=Y["x-attribsNamespace"])===null||Q===void 0?void 0:Q[G],prefix:(X=Y["x-attribsPrefix"])===null||X===void 0?void 0:X[G]}})},enumerable:!1,configurable:!0}),J}(O6);E.Element=KQ;function LQ(Z){return(0,Y1.isTag)(Z)}E.isTag=LQ;function MQ(Z){return Z.type===Y1.ElementType.CDATA}E.isCDATA=MQ;function $Q(Z){return Z.type===Y1.ElementType.Text}E.isText=$Q;function FQ(Z){return Z.type===Y1.ElementType.Comment}E.isComment=FQ;function OQ(Z){return Z.type===Y1.ElementType.Directive}E.isDirective=OQ;function VQ(Z){return Z.type===Y1.ElementType.Root}E.isDocument=VQ;function wM(Z){return Object.prototype.hasOwnProperty.call(Z,"children")}E.hasChildren=wM;function b9(Z,J){if(J===void 0)J=!1;var Y;if($Q(Z))Y=new WQ(Z.data);else if(FQ(Z))Y=new HQ(Z.data);else if(LQ(Z)){var G=J?v9(Z.children):[],Q=new KQ(Z.name,Q5({},Z.attribs),G);if(G.forEach(function(z){return z.parent=Q}),Z.namespace!=null)Q.namespace=Z.namespace;if(Z["x-attribsNamespace"])Q["x-attribsNamespace"]=Q5({},Z["x-attribsNamespace"]);if(Z["x-attribsPrefix"])Q["x-attribsPrefix"]=Q5({},Z["x-attribsPrefix"]);Y=Q}else if(MQ(Z)){var G=J?v9(Z.children):[],X=new UQ(G);G.forEach(function(U){return U.parent=X}),Y=X}else if(VQ(Z)){var G=J?v9(Z.children):[],W=new BQ(G);if(G.forEach(function(U){return U.parent=W}),Z["x-mode"])W["x-mode"]=Z["x-mode"];Y=W}else if(OQ(Z)){var H=new zQ(Z.name,Z.data);if(Z["x-name"]!=null)H["x-name"]=Z["x-name"],H["x-publicId"]=Z["x-publicId"],H["x-systemId"]=Z["x-systemId"];Y=H}else throw Error("Not implemented yet: ".concat(Z.type));if(Y.startIndex=Z.startIndex,Y.endIndex=Z.endIndex,Z.sourceCodeLocation!=null)Y.sourceCodeLocation=Z.sourceCodeLocation;return Y}E.cloneNode=b9;function v9(Z){var J=Z.map(function(G){return b9(G,!0)});for(var Y=1;Y<J.length;Y++)J[Y].prev=J[Y-1],J[Y-1].next=J[Y];return J}});var m9=A((D1)=>{var EM=D1&&D1.__createBinding||(Object.create?function(Z,J,Y,G){if(G===void 0)G=Y;var Q=Object.getOwnPropertyDescriptor(J,Y);if(!Q||("get"in Q?!J.__esModule:Q.writable||Q.configurable))Q={enumerable:!0,get:function(){return J[Y]}};Object.defineProperty(Z,G,Q)}:function(Z,J,Y,G){if(G===void 0)G=Y;Z[G]=J[Y]}),SM=D1&&D1.__exportStar||function(Z,J){for(var Y in Z)if(Y!=="default"&&!Object.prototype.hasOwnProperty.call(J,Y))EM(J,Z,Y)};Object.defineProperty(D1,"__esModule",{value:!0});D1.DomHandler=void 0;var y9=k9(),n1=g9();SM(g9(),D1);var IQ={withStartIndices:!1,withEndIndices:!1,xmlMode:!1},qQ=function(){function Z(J,Y,G){if(this.dom=[],this.root=new n1.Document(this.dom),this.done=!1,this.tagStack=[this.root],this.lastNode=null,this.parser=null,typeof Y==="function")G=Y,Y=IQ;if(typeof J==="object")Y=J,J=void 0;this.callback=J!==null&&J!==void 0?J:null,this.options=Y!==null&&Y!==void 0?Y:IQ,this.elementCB=G!==null&&G!==void 0?G:null}return Z.prototype.onparserinit=function(J){this.parser=J},Z.prototype.onreset=function(){this.dom=[],this.root=new n1.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,Y){var G=this.options.xmlMode?y9.ElementType.Tag:void 0,Q=new n1.Element(J,Y,void 0,G);this.addNode(Q),this.tagStack.push(Q)},Z.prototype.ontext=function(J){var Y=this.lastNode;if(Y&&Y.type===y9.ElementType.Text){if(Y.data+=J,this.options.withEndIndices)Y.endIndex=this.parser.endIndex}else{var G=new n1.Text(J);this.addNode(G),this.lastNode=G}},Z.prototype.oncomment=function(J){if(this.lastNode&&this.lastNode.type===y9.ElementType.Comment){this.lastNode.data+=J;return}var Y=new n1.Comment(J);this.addNode(Y),this.lastNode=Y},Z.prototype.oncommentend=function(){this.lastNode=null},Z.prototype.oncdatastart=function(){var J=new n1.Text(""),Y=new n1.CDATA([J]);this.addNode(Y),J.parent=Y,this.lastNode=J},Z.prototype.oncdataend=function(){this.lastNode=null},Z.prototype.onprocessinginstruction=function(J,Y){var G=new n1.ProcessingInstruction(J,Y);this.addNode(G)},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 Y=this.tagStack[this.tagStack.length-1],G=Y.children[Y.children.length-1];if(this.options.withStartIndices)J.startIndex=this.parser.startIndex;if(this.options.withEndIndices)J.endIndex=this.parser.endIndex;if(Y.children.push(J),G)J.prev=G,G.next=J;J.parent=Y,this.lastNode=null},Z}();D1.DomHandler=qQ;D1.default=qQ});var TQ=A((DQ)=>{Object.defineProperty(DQ,"__esModule",{value:!0});DQ.CARRIAGE_RETURN_PLACEHOLDER_REGEX=DQ.CARRIAGE_RETURN_PLACEHOLDER=DQ.CARRIAGE_RETURN_REGEX=DQ.CARRIAGE_RETURN=DQ.CASE_SENSITIVE_TAG_NAMES_MAP=DQ.CASE_SENSITIVE_TAG_NAMES=void 0;DQ.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"];DQ.CASE_SENSITIVE_TAG_NAMES_MAP=DQ.CASE_SENSITIVE_TAG_NAMES.reduce(function(Z,J){return Z[J.toLowerCase()]=J,Z},{});DQ.CARRIAGE_RETURN="\r";DQ.CARRIAGE_RETURN_REGEX=new RegExp(DQ.CARRIAGE_RETURN,"g");DQ.CARRIAGE_RETURN_PLACEHOLDER="__HTML_DOM_PARSER_CARRIAGE_RETURN_PLACEHOLDER_".concat(Date.now().toString(),"__");DQ.CARRIAGE_RETURN_PLACEHOLDER_REGEX=new RegExp(DQ.CARRIAGE_RETURN_PLACEHOLDER,"g")});var u9=A((xQ)=>{Object.defineProperty(xQ,"__esModule",{value:!0});xQ.formatAttributes=wQ;xQ.hasOpenTag=_M;xQ.escapeSpecialCharacters=kM;xQ.revertEscapedCharacters=EQ;xQ.formatDOM=SQ;var V6=m9(),X5=TQ();function CM(Z){return X5.CASE_SENSITIVE_TAG_NAMES_MAP[Z]}function wQ(Z){var J={},Y=0,G=Z.length;for(;Y<G;Y++){var Q=Z[Y];J[Q.name]=Q.value}return J}function jM(Z){Z=Z.toLowerCase();var J=CM(Z);if(J)return J;return Z}function _M(Z,J){var Y="<"+J,G=Z.toLowerCase().indexOf(Y);if(G===-1)return!1;var Q=Z[G+Y.length];return Q===">"||Q===" "||Q==="\t"||Q===`
|
|
15
|
+
`||Q==="\r"||Q==="/"}function kM(Z){return Z.replace(X5.CARRIAGE_RETURN_REGEX,X5.CARRIAGE_RETURN_PLACEHOLDER)}function EQ(Z){return Z.replace(X5.CARRIAGE_RETURN_PLACEHOLDER_REGEX,X5.CARRIAGE_RETURN)}function SQ(Z,J,Y){var G,Q,X,W;if(J===void 0)J=null;var H=[],z,U=0,B=Z.length;for(;U<B;U++){var L=Z[U];switch(L.nodeType){case 1:{var F=jM(L.nodeName);z=new V6.Element(F,wQ(L.attributes)),z.children=SQ(F==="template"?L.content.childNodes:L.childNodes,z);break}case 3:z=new V6.Text(EQ((G=L.nodeValue)!==null&&G!==void 0?G:""));break;case 8:z=new V6.Comment((Q=L.nodeValue)!==null&&Q!==void 0?Q:"");break;default:continue}var M=(X=H[U-1])!==null&&X!==void 0?X:null;if(M)M.next=z;z.parent=J,z.prev=M,z.next=null,H.push(z)}if(Y){if(z=new V6.ProcessingInstruction(Y.substring(0,Y.indexOf(" ")).toLowerCase(),Y),z.next=(W=H[0])!==null&&W!==void 0?W:null,z.parent=J,H.unshift(z),H[1])H[1].prev=H[0]}return H}});var kQ=A((_Q)=>{Object.defineProperty(_Q,"__esModule",{value:!0});_Q.default=uM;var W5=u9(),fQ="html",I6="head",P0="body",mM=/<([a-zA-Z]+[0-9]?)/,D6=function(Z,J){throw Error("This browser does not support `document.implementation.createHTMLDocument`")},d9=function(Z,J){throw Error("This browser does not support `DOMParser.prototype.parseFromString`")},CQ=typeof window==="object"&&window.DOMParser;if(typeof CQ==="function")c9=new CQ,p9="text/html",d9=function(Z,J){if(J)Z="<".concat(J,">").concat(Z,"</").concat(J,">");return c9.parseFromString(Z,p9)},D6=d9;var c9,p9;if(typeof document==="object"&&document.implementation)T0=document.implementation.createHTMLDocument(),D6=function(Z,J){if(J){var Y=T0.documentElement.querySelector(J);if(Y)Y.innerHTML=Z;return T0}return T0.documentElement.innerHTML=Z,T0};var T0,q6=typeof document==="object"&&document.createElement("template"),l9;if(q6&&q6.content)l9=function(Z){return q6.innerHTML=Z,q6.content.childNodes};var jQ=function(){return document.createDocumentFragment().childNodes};function uM(Z){var J,Y,G,Q,X,W;Z=(0,W5.escapeSpecialCharacters)(Z);var H=mM.exec(Z),z=(J=H===null||H===void 0?void 0:H[1])===null||J===void 0?void 0:J.toLowerCase();switch(z){case fQ:{var U=d9(Z);if(!(0,W5.hasOpenTag)(Z,I6)){var B=U.querySelector(I6);(Y=B===null||B===void 0?void 0:B.parentNode)===null||Y===void 0||Y.removeChild(B)}if(!(0,W5.hasOpenTag)(Z,P0)){var B=U.querySelector(P0);(G=B===null||B===void 0?void 0:B.parentNode)===null||G===void 0||G.removeChild(B)}return U.querySelectorAll(fQ)}case I6:case P0:{var L=D6(Z).querySelectorAll(z);if((0,W5.hasOpenTag)(Z,P0)&&(0,W5.hasOpenTag)(Z,I6))return(X=(Q=L[0].parentNode)===null||Q===void 0?void 0:Q.childNodes)!==null&&X!==void 0?X:jQ();return L}default:{if(l9)return l9(Z);var B=D6(Z,P0).querySelector(P0);return(W=B===null||B===void 0?void 0:B.childNodes)!==null&&W!==void 0?W:jQ()}}}});var vQ=A((H5)=>{var cM=H5&&H5.__importDefault||function(Z){return Z&&Z.__esModule?Z:{default:Z}};Object.defineProperty(H5,"__esModule",{value:!0});H5.default=nM;var pM=cM(kQ()),lM=u9(),iM=/<(![a-zA-Z\s]+)>/;function nM(Z){if(typeof Z!=="string")throw TypeError("First argument must be a string");if(!Z)return[];var J=iM.exec(Z),Y=J?J[1]:void 0;return(0,lM.formatDOM)((0,pM.default)(Z),null,Y)}});var hQ=A((sM)=>{var oM=0;sM.SAME=oM;var aM=1;sM.CAMELCASE=aM;sM.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 gQ=A((U2)=>{function Z2(Z){return c.hasOwnProperty(Z)?c[Z]:null}function e(Z,J,Y,G,Q,X,W){this.acceptsBooleans=J===2||J===3||J===4,this.attributeName=G,this.attributeNamespace=Q,this.mustUseProperty=Y,this.propertyName=Z,this.type=J,this.sanitizeURL=X,this.removeEmptyString=W}var c={},J2=["children","dangerouslySetInnerHTML","defaultValue","defaultChecked","innerHTML","suppressContentEditableWarning","suppressHydrationWarning","style"];J2.forEach((Z)=>{c[Z]=new e(Z,0,!1,Z,null,!1,!1)});[["acceptCharset","accept-charset"],["className","class"],["htmlFor","for"],["httpEquiv","http-equiv"]].forEach(([Z,J])=>{c[Z]=new e(Z,1,!1,J,null,!1,!1)});["contentEditable","draggable","spellCheck","value"].forEach((Z)=>{c[Z]=new e(Z,2,!1,Z.toLowerCase(),null,!1,!1)});["autoReverse","externalResourcesRequired","focusable","preserveAlpha"].forEach((Z)=>{c[Z]=new e(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)=>{c[Z]=new e(Z,3,!1,Z.toLowerCase(),null,!1,!1)});["checked","multiple","muted","selected"].forEach((Z)=>{c[Z]=new e(Z,3,!0,Z,null,!1,!1)});["capture","download"].forEach((Z)=>{c[Z]=new e(Z,4,!1,Z,null,!1,!1)});["cols","rows","size","span"].forEach((Z)=>{c[Z]=new e(Z,6,!1,Z,null,!1,!1)});["rowSpan","start"].forEach((Z)=>{c[Z]=new e(Z,5,!1,Z.toLowerCase(),null,!1,!1)});var i9=/[\-\:]([a-z])/g,n9=(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(i9,n9);c[J]=new e(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(i9,n9);c[J]=new e(J,1,!1,Z,"http://www.w3.org/1999/xlink",!1,!1)});["xml:base","xml:lang","xml:space"].forEach((Z)=>{let J=Z.replace(i9,n9);c[J]=new e(J,1,!1,Z,"http://www.w3.org/XML/1998/namespace",!1,!1)});["tabIndex","crossOrigin"].forEach((Z)=>{c[Z]=new e(Z,1,!1,Z.toLowerCase(),null,!1,!1)});var Y2="xlinkHref";c[Y2]=new e("xlinkHref",1,!1,"xlink:href","http://www.w3.org/1999/xlink",!0,!1);["src","href","action","formAction"].forEach((Z)=>{c[Z]=new e(Z,1,!1,Z.toLowerCase(),null,!0,!0)});var{CAMELCASE:G2,SAME:Q2,possibleStandardNames:bQ}=hQ(),X2=":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",W2=X2+"\\-.0-9\\u00B7\\u0300-\\u036F\\u203F-\\u2040",H2=RegExp.prototype.test.bind(new RegExp("^(data|aria)-["+W2+"]*$")),z2=Object.keys(bQ).reduce((Z,J)=>{let Y=bQ[J];if(Y===Q2)Z[J]=J;else if(Y===G2)Z[J.toLowerCase()]=J;else Z[J]=Y;return Z},{});U2.BOOLEAN=3;U2.BOOLEANISH_STRING=2;U2.NUMERIC=5;U2.OVERLOADED_BOOLEAN=4;U2.POSITIVE_NUMERIC=6;U2.RESERVED=0;U2.STRING=1;U2.getPropertyInfo=Z2;U2.isCustomAttribute=H2;U2.possibleStandardNames=z2});var pQ=A((JN,cQ)=>{var yQ=/\/\*[^*]*\*+([^/*][^*]*\*+)*\//g,D2=/\n/g,N2=/^\s*/,A2=/^(\*?[-#/*\\\w]+(\[[0-9a-z_-]+\])?)\s*/,R2=/^:\s*/,P2=/^((?:'(?:\\'|.)*?'|"(?:\\"|.)*?"|\([^)]*?\)|[^};])+)/,T2=/^[;\s]*/,w2=/^\s+|\s+$/g,E2=`
|
|
16
|
+
`,mQ="/",uQ="*",W0="",S2="comment",x2="declaration";function f2(Z,J){if(typeof Z!=="string")throw TypeError("First argument must be a string");if(!Z)return[];J=J||{};var Y=1,G=1;function Q(K){var $=K.match(D2);if($)Y+=$.length;var O=K.lastIndexOf(E2);G=~O?K.length-O:G+K.length}function X(){var K={line:Y,column:G};return function($){return $.position=new W(K),U(),$}}function W(K){this.start=K,this.end={line:Y,column:G},this.source=J.source}W.prototype.content=Z;function H(K){var $=Error(J.source+":"+Y+":"+G+": "+K);if($.reason=K,$.filename=J.source,$.line=Y,$.column=G,$.source=Z,J.silent);else throw $}function z(K){var $=K.exec(Z);if(!$)return;var O=$[0];return Q(O),Z=Z.slice(O.length),$}function U(){z(N2)}function B(K){var $;K=K||[];while($=L())if($!==!1)K.push($);return K}function L(){var K=X();if(mQ!=Z.charAt(0)||uQ!=Z.charAt(1))return;var $=2;while(W0!=Z.charAt($)&&(uQ!=Z.charAt($)||mQ!=Z.charAt($+1)))++$;if($+=2,W0===Z.charAt($-1))return H("End of comment missing");var O=Z.slice(2,$-2);return G+=2,Q(O),Z=Z.slice($),G+=2,K({type:S2,comment:O})}function F(){var K=X(),$=z(A2);if(!$)return;if(L(),!z(R2))return H("property missing ':'");var O=z(P2),N=K({type:x2,property:dQ($[0].replace(yQ,W0)),value:O?dQ(O[0].replace(yQ,W0)):W0});return z(T2),N}function M(){var K=[];B(K);var $;while($=F())if($!==!1)K.push($),B(K);return K}return U(),M()}function dQ(Z){return Z?Z.replace(w2,W0):W0}cQ.exports=f2});var lQ=A((z5)=>{var C2=z5&&z5.__importDefault||function(Z){return Z&&Z.__esModule?Z:{default:Z}};Object.defineProperty(z5,"__esModule",{value:!0});z5.default=_2;var j2=C2(pQ());function _2(Z,J){let Y=null;if(!Z||typeof Z!=="string")return Y;let G=(0,j2.default)(Z),Q=typeof J==="function";return G.forEach((X)=>{if(X.type!=="declaration")return;let{property:W,value:H}=X;if(Q)J(W,H,X);else if(H)Y=Y||{},Y[W]=H}),Y}});var aQ=A((nQ)=>{Object.defineProperty(nQ,"__esModule",{value:!0});nQ.camelCase=void 0;var k2=/^--[a-zA-Z0-9_-]+$/,v2=/-([a-z])/g,h2=/^[^-]+$/,b2=/^-(webkit|moz|ms|o|khtml)-/,g2=/^-(ms)-/,y2=function(Z){return!Z||h2.test(Z)||k2.test(Z)},m2=function(Z,J){return J.toUpperCase()},iQ=function(Z,J){return"".concat(J,"-")},u2=function(Z,J){if(J===void 0)J={};if(y2(Z))return Z;if(Z=Z.toLowerCase(),J.reactCompat)Z=Z.replace(g2,iQ);else Z=Z.replace(b2,iQ);return Z.replace(v2,m2)};nQ.camelCase=u2});var rQ=A((a9,sQ)=>{var d2=a9&&a9.__importDefault||function(Z){return Z&&Z.__esModule?Z:{default:Z}},c2=d2(lQ()),p2=aQ();function o9(Z,J){var Y={};if(!Z||typeof Z!=="string")return Y;return(0,c2.default)(Z,function(G,Q){if(G&&Q)Y[(0,p2.camelCase)(G,J)]=Q}),Y}o9.default=o9;sQ.exports=o9});import*as tQ from"react";var s9=A((Z1)=>{var l2=Z1&&Z1.__importDefault||function(Z){return Z&&Z.__esModule?Z:{default:Z}};Object.defineProperty(Z1,"__esModule",{value:!0});Z1.returnFirstArg=Z1.canTextBeChildOfNode=Z1.ELEMENTS_WITH_NO_TEXT_CHILDREN=Z1.PRESERVE_CUSTOM_ATTRIBUTES=void 0;Z1.isCustomComponent=o2;Z1.setStyleProp=s2;var i2=l2(rQ()),n2=new Set(["annotation-xml","color-profile","font-face","font-face-src","font-face-uri","font-face-format","font-face-name","missing-glyph"]);function o2(Z,J){if(!Z.includes("-"))return Boolean(J&&typeof J.is==="string");if(n2.has(Z))return!1;return!0}var a2={reactCompat:!0};function s2(Z,J){if(typeof Z!=="string")return;if(!Z.trim()){J.style={};return}try{J.style=(0,i2.default)(Z,a2)}catch(Y){J.style={}}}Z1.PRESERVE_CUSTOM_ATTRIBUTES=Number(tQ.version.split(".")[0])>=16;Z1.ELEMENTS_WITH_NO_TEXT_CHILDREN=new Set(["tr","tbody","thead","tfoot","colgroup","table","head","html","frameset"]);var r2=function(Z){return!Z1.ELEMENTS_WITH_NO_TEXT_CHILDREN.has(Z.name)};Z1.canTextBeChildOfNode=r2;var t2=function(Z){return Z};Z1.returnFirstArg=t2});var r9=A((JX)=>{Object.defineProperty(JX,"__esModule",{value:!0});JX.default=Y$;var U5=gQ(),eQ=s9(),e2=["checked","value"],Z$=["input","select","textarea"],J$={reset:!0,submit:!0};function Y$(Z,J){if(Z===void 0)Z={};var Y={},G=Boolean(Z.type&&J$[Z.type]);for(var Q in Z){var X=Z[Q];if((0,U5.isCustomAttribute)(Q)){Y[Q]=X;continue}var W=Q.toLowerCase(),H=ZX(W);if(H){var z=(0,U5.getPropertyInfo)(H);if(e2.includes(H)&&Z$.includes(J)&&!G)H=ZX("default"+W);switch(Y[H]=X,z===null||z===void 0?void 0:z.type){case U5.BOOLEAN:Y[H]=!0;break;case U5.OVERLOADED_BOOLEAN:if(X==="")Y[H]=!0;break}continue}if(eQ.PRESERVE_CUSTOM_ATTRIBUTES)Y[Q]=X}return(0,eQ.setStyleProp)(Z.style,Y),Y}function ZX(Z){return U5.possibleStandardNames[Z]}});import*as w0 from"react";var GX=A((K5)=>{var Q$=K5&&K5.__importDefault||function(Z){return Z&&Z.__esModule?Z:{default:Z}};Object.defineProperty(K5,"__esModule",{value:!0});K5.default=YX;var X$=Q$(r9()),B5=s9(),W$={cloneElement:w0.cloneElement,createElement:w0.createElement,isValidElement:w0.isValidElement};function YX(Z,J){var Y,G,Q,X,W;if(J===void 0)J={};var H=[],z=typeof J.replace==="function",U=(Y=J.transform)!==null&&Y!==void 0?Y:B5.returnFirstArg,B=(G=J.library)!==null&&G!==void 0?G:W$,L=B.cloneElement,F=B.createElement,M=B.isValidElement,K=Z.length;for(var $=0;$<K;$++){var O=Z[$];if(z){var N=(Q=J.replace)===null||Q===void 0?void 0:Q.call(J,O,$);if(M(N)){if(K>1)N=L(N,{key:(X=N.key)!==null&&X!==void 0?X:$});H.push(U(N,O,$));continue}}if(O.type==="text"){var P=!O.data.trim().length;if(P&&O.parent&&!(0,B5.canTextBeChildOfNode)(O.parent))continue;if(J.trim&&P)continue;H.push(U(O.data,O,$));continue}var D=O,q={};if(H$(D))(0,B5.setStyleProp)(D.attribs.style,D.attribs),q=D.attribs;else if(D.attribs)q=(0,X$.default)(D.attribs,D.name);var T=void 0;switch(O.type){case"script":case"style":if(O.children[0])q.dangerouslySetInnerHTML={__html:O.children[0].data};break;case"tag":if(O.name==="textarea"&&O.children[0])q.defaultValue=O.children[0].data;else if((W=O.children)===null||W===void 0?void 0:W.length)T=YX(O.children,J);break;default:continue}if(K>1)q.key=$;H.push(U(F(O.name,q,T),O,$))}return H.length===1?H[0]:H}function H$(Z){return B5.PRESERVE_CUSTOM_ATTRIBUTES&&Z.type==="tag"&&(0,B5.isCustomComponent)(Z.name,Z.attribs)}});var e9=A((m)=>{var t9=m&&m.__importDefault||function(Z){return Z&&Z.__esModule?Z:{default:Z}};Object.defineProperty(m,"__esModule",{value:!0});m.htmlToDOM=m.domToReact=m.attributesToProps=m.Text=m.ProcessingInstruction=m.Element=m.Comment=void 0;m.default=B$;var QX=t9(vQ());m.htmlToDOM=QX.default;var z$=t9(r9());m.attributesToProps=z$.default;var XX=t9(GX());m.domToReact=XX.default;var N6=m9();Object.defineProperty(m,"Comment",{enumerable:!0,get:function(){return N6.Comment}});Object.defineProperty(m,"Element",{enumerable:!0,get:function(){return N6.Element}});Object.defineProperty(m,"ProcessingInstruction",{enumerable:!0,get:function(){return N6.ProcessingInstruction}});Object.defineProperty(m,"Text",{enumerable:!0,get:function(){return N6.Text}});var U$={lowerCaseAttributeNames:!1};function B$(Z,J){var Y;if(typeof Z!=="string")throw TypeError("First argument must be a string");if(!Z)return[];return(0,XX.default)((0,QX.default)(Z,(Y=J===null||J===void 0?void 0:J.htmlparser2)!==null&&Y!==void 0?Y:U$),J)}});import{lazy as cX}from"react";var x6=new Map;function R7(Z,J){return cX(()=>{if(x6.has(J))return x6.get(J);let Y=Z().then((G)=>G);return x6.set(J,Y),Y})}var P7=new Map,pX=(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=R7(J.loader,Z.name),J.loader=void 0,J.isLazy=!0;return J};function U1(Z){let J=pX(Z);return P7.set(J.name,J),J.component}var T7=(Z)=>{return P7.get(Z)};import{Suspense as J3,useContext as Y3}from"react";import{createContext as lX}from"react";import{jsx as oX,Fragment as nX}from"react/jsx-runtime";var iX=lX(oX(nX,{})),v1=iX;import{createContext as aX,useContext as sX}from"react";var S0=aX(null),U0=()=>{let Z=sX(S0);if(!Z)throw Error("usePieConfig must be used within PieConfigProvider");return Z},rX=()=>{let{apiServer:Z}=U0();return Z},h1=rX,tX=()=>{let{centrifugeServer:Z}=U0();return Z},O5=tX,eX=()=>{let{enableRenderingLog:Z}=U0();return Z},b1=eX,Z3=()=>{let{pageProcessor:Z}=U0();return Z},w7=Z3;import{jsx as E7}from"react/jsx-runtime";function G3({uiConfig:Z,setUiAjaxConfiguration:J}){let Y=Y3(v1),G=b1();if(G)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 Q=T7(Z.card);if(!Q?.component){if(G)console.warn(`[UI] Component not found in registry: ${Z.card}`),console.log("[UI] Returning fallback component");return Y}if(G)console.log("[UI] Found component in registry:",{name:Q.name,isLazy:Q.isLazy,hasMetadata:!!Q.metadata});let X=Q.component,W=E7(X,{data:Z.data,content:Z.content,setUiAjaxConfiguration:J});if(Q.isLazy){if(G)console.log("[UI] Rendering lazy component with Suspense:",Q.name);return E7(J3,{fallback:Q.fallback??Y,children:W},`${Q.name}`)}if(G)console.log("[UI] Rendering component directly:",Q.name);return W}var G1=G3;import{useEffect as TF,useMemo as wF}from"react";import{QueryClient as EF,QueryClientProvider as SF,useQuery as xF}from"@tanstack/react-query";var j5=S(f6(),1),RJ=S(_6(),1);import AJ,{useState as mU,useContext as MJ,useRef as uU,useEffect as $J,forwardRef as dU}from"react";var x3={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 x0(Z,J){var Y=!x3[Z]&&typeof J==="number"&&J!==0;return Y?J+"px":J}function f0(Z,J){return Object.keys(Z).reduce(function(Y,G){return Y[G]=J(Z[G],G),Y},{})}function k6(Z){return f0(Z,function(J,Y){return x0(Y,Z[Y])+" !important"})}var f3=/([a-z])?([A-Z])/g,C3=function(J,Y,G){return(Y||"")+"-"+G.toLowerCase()},v6=function(J){return J.replace(f3,C3)},j3=function(J){return Object.keys(J).reduce(function(Y,G){var Q=v6(G);if(/^ms-/.test(Q))Q="-".concat(Q);return Y[Q]=J[G],Y},{})},p7=j3;var iZ=S(Z4(),1),nZ=S(L4(),1),oZ=S(o6(),1);var i4=S(F4(),1),n4=S(V4(),1),o4=S(q4(),1),a4=S(N4(),1),s4=S(P4(),1),r4=S(E4(),1),t4=S(f4(),1),e4=S(_4(),1),ZZ=S(v4(),1),JZ=S(b4(),1),YZ=S(y4(),1),GZ=S(l4(),1),R=["Webkit"],L8=["Moz"],v=["ms"],i=["Webkit","Moz"],d=["Webkit","ms"],C0=["Webkit","Moz","ms"],QZ={plugins:[i4.default,n4.default,o4.default,a4.default,s4.default,r4.default,t4.default,e4.default,ZZ.default,JZ.default,YZ.default,GZ.default],prefixMap:{transform:d,transformOrigin:d,transformOriginX:d,transformOriginY:d,backfaceVisibility:R,perspective:R,perspectiveOrigin:R,transformStyle:R,transformOriginZ:R,animation:R,animationDelay:R,animationDirection:R,animationFillMode:R,animationDuration:R,animationIterationCount:R,animationName:R,animationPlayState:R,animationTimingFunction:R,appearance:i,userSelect:C0,fontKerning:R,textEmphasisPosition:R,textEmphasis:R,textEmphasisStyle:R,textEmphasisColor:R,boxDecorationBreak:R,clipPath:R,maskImage:R,maskMode:R,maskRepeat:R,maskPosition:R,maskClip:R,maskOrigin:R,maskSize:R,maskComposite:R,mask:R,maskBorderSource:R,maskBorderMode:R,maskBorderSlice:R,maskBorderWidth:R,maskBorderOutset:R,maskBorderRepeat:R,maskBorder:R,maskType:R,textDecorationStyle:i,textDecorationSkip:i,textDecorationLine:i,textDecorationColor:i,filter:R,fontFeatureSettings:i,breakAfter:C0,breakBefore:C0,breakInside:C0,columnCount:i,columnFill:i,columnGap:i,columnRule:i,columnRuleColor:i,columnRuleStyle:i,columnRuleWidth:i,columns:i,columnSpan:i,columnWidth:i,writingMode:d,flex:d,flexBasis:R,flexDirection:d,flexGrow:R,flexFlow:d,flexShrink:R,flexWrap:d,alignContent:R,alignItems:R,alignSelf:R,justifyContent:R,order:R,transitionDelay:R,transitionDuration:R,transitionProperty:R,transitionTimingFunction:R,backdropFilter:R,scrollSnapType:d,scrollSnapPointsX:d,scrollSnapPointsY:d,scrollSnapDestination:d,scrollSnapCoordinate:d,shapeImageThreshold:R,shapeImageMargin:R,shapeImageOutside:R,hyphens:C0,flowInto:d,flowFrom:d,regionFragment:d,boxSizing:L8,textAlignLast:L8,tabSize:L8,wrapFlow:v,wrapThrough:v,wrapMargin:v,touchAction:v,gridTemplateColumns:v,gridTemplateRows:v,gridTemplateAreas:v,gridTemplate:v,gridAutoColumns:v,gridAutoRows:v,gridAutoFlow:v,grid:v,gridRowStart:v,gridColumnStart:v,gridRowEnd:v,gridRow:v,gridColumn:v,gridColumnEnd:v,gridColumnGap:v,gridRowGap:v,gridArea:v,gridGap:v,textSizeAdjust:d,borderImage:R,borderImageOutset:R,borderImageRepeat:R,borderImageSlice:R,borderImageSource:R,borderImageWidth:R}};var jZ=S(HZ(),1),_Z=S(UZ(),1),kZ=S(LZ(),1),vZ=S($Z(),1),hZ=S(OZ(),1),bZ=S(IZ(),1),gZ=S(DZ(),1),yZ=S(RZ(),1),mZ=S(TZ(),1),uZ=S(EZ(),1),dZ=S(xZ(),1),cZ=S(CZ(),1),pZ={plugins:[jZ.default,_Z.default,kZ.default,vZ.default,hZ.default,bZ.default,gZ.default,yZ.default,mZ.default,uZ.default,dZ.default,cZ.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 A5(Z){if(typeof Symbol==="function"&&typeof Symbol.iterator==="symbol")A5=function(Y){return typeof Y};else A5=function(Y){return Y&&typeof Symbol==="function"&&Y.constructor===Symbol&&Y!==Symbol.prototype?"symbol":typeof Y};return A5(Z)}var aZ=iZ.default(QZ),JU=nZ.default(pZ,aZ);function YU(Z){return Object.keys(Z).reduce(function(J,Y){var G=Z[Y];if(Array.isArray(G))G=G.join(";"+Y+":");else if(G&&A5(G)==="object"&&typeof G.toString==="function")G=G.toString();return J[Y]=G,J},{})}function GU(Z){return Object.keys(Z).reduce(function(J,Y){var G=Z[Y];if(Array.isArray(G))if(oZ.default.canUseDOM)G=G[G.length-1].toString();else G=G.join(";".concat(v6(Y),":"));return J[Y]=G,J},{})}var lZ,N5;function sZ(Z){var J=Z||global&&global.navigator&&global.navigator.userAgent;if(!N5||J!==lZ){if(J==="all")N5={prefix:aZ,prefixedKeyframes:"keyframes"};else N5=new JU({userAgent:J});lZ=J}return N5}function rZ(Z){return sZ(Z).prefixedKeyframes||"keyframes"}function R5(Z,J){var Y=YU(Z),G=sZ(J),Q=G.prefix(Y),X=GU(Q);return X}function QU(Z){return Object.keys(Z).map(function(J){return J+": "+Z[J]+";"}).join(`
|
|
17
|
+
`)}function g1(Z,J,Y){if(!J)return"";var G=f0(J,function(H,z){return x0(z,H)}),Q=R5(G,Y),X=p7(Q),W=QU(X);return Z+"{"+W+"}"}var XU=function(J){return J===null||typeof J>"u"?"main":J.toString()},P5=XU;var WU=function(J,Y,G){var Q=P5(Y);return!!J&&!!J._radiumStyleState&&!!J._radiumStyleState[Q]&&J._radiumStyleState[Q][G]},T5=WU;var HU=function(J){return typeof J.ref==="string"?J.ref:J.key},r1=HU;var zU=function(J){return J._lastRadiumState||J.state&&J.state._radiumStyleState||{}},j0=zU;function _0(Z){if(!Z)return"";var J=5381,Y=Z.length-1;while(Y)J=J*33^Z.charCodeAt(Y),Y-=1;return(J>>>0).toString(16)}function w5(Z){if(typeof Symbol==="function"&&typeof Symbol.iterator==="symbol")w5=function(Y){return typeof Y};else w5=function(Y){return Y&&typeof Symbol==="function"&&Y.constructor===Symbol&&Y!==Symbol.prototype?"symbol":typeof Y};return w5(Z)}function E5(Z){return Z&&Z.constructor===Object&&Z.toString===Object.prototype.toString}function S5(Z){var J={};return Z.forEach(function(Y){if(!Y||w5(Y)!=="object")return;if(Array.isArray(Y))Y=S5(Y);Object.keys(Y).forEach(function(G){if(!E5(Y[G])||!E5(J[G])){J[G]=Y[G];return}if(G.indexOf("@media")===0){var Q=G;while(!0)if(Q+=" ",!J[Q]){J[Q]=Y[G];return}}J[G]=S5([J[G],Y[G]])})}),J}var UU=function(){};var tZ=UU;function C8(Z){var{addCSS:J,config:Y,style:G}=Z,Q=function(H){var z=H,U=z.__process(Y.userAgent),B=U.animationName,L=U.css;return J(L),B},X=Object.keys(G).reduce(function(W,H){var z=G[H],U=Array.isArray(z);if(H==="animationName"&&z&&(z.__radiumKeyframes||U))if(U)z=z.map(Q).join(", ");else z=Q(z);return W[H]=z,W},{});return{style:X}}var BU=function(J){var{style:Y,mergeStyles:G}=J,Q=Array.isArray(Y)?G(Y):Y;return{style:Q}},eZ=BU;function j8(Z){var{config:J,style:Y}=Z,G=R5(Y,J.userAgent);return{style:G}}function _8(Z){var{isNestedStyle:J,style:Y}=Z,G=Object.keys(Y).reduce(function(Q,X){var W=Y[X];if(!J(W))Q[X]=W;return Q},{});return{style:G}}var K0=[],x5=!1;function k8(){K0.forEach(function(Z){Z()})}var KU=function(J){if(K0.indexOf(J)===-1)K0.push(J);if(!x5)window.addEventListener("mouseup",k8),x5=!0;return{remove:function(){var G=K0.indexOf(J);if(K0.splice(G,1),K0.length===0&&x5)window.removeEventListener("mouseup",k8),x5=!1}}},ZJ={subscribe:KU,__triggerForTests:k8};var JJ=function(J){return J===":hover"||J===":active"||J===":focus"},LU=function(J){var{ExecutionEnvironment:Y,getComponentField:G,getState:Q,mergeStyles:X,props:W,setState:H,style:z}=J,U={},B={};if(z[":hover"]){var L=W.onMouseEnter;B.onMouseEnter=function(q){L&&L(q),H(":hover",!0)};var F=W.onMouseLeave;B.onMouseLeave=function(q){F&&F(q),H(":hover",!1)}}if(z[":active"]){var M=W.onMouseDown;B.onMouseDown=function(q){M&&M(q),U._lastMouseDown=Date.now(),H(":active","viamousedown")};var K=W.onKeyDown;B.onKeyDown=function(q){if(K&&K(q),q.key===" "||q.key==="Enter")H(":active","viakeydown")};var $=W.onKeyUp;B.onKeyUp=function(q){if($&&$(q),q.key===" "||q.key==="Enter")H(":active",!1)}}if(z[":focus"]){var O=W.onFocus;B.onFocus=function(q){O&&O(q),H(":focus",!0)};var N=W.onBlur;B.onBlur=function(q){N&&N(q),H(":focus",!1)}}if(z[":active"]&&!G("_radiumMouseUpListener")&&Y.canUseEventListeners)U._radiumMouseUpListener=ZJ.subscribe(function(){Object.keys(G("state")._radiumStyleState).forEach(function(q){if(Q(":active",q)==="viamousedown")H(":active",!1,q)})});var P=W.disabled?[z[":disabled"]]:Object.keys(z).filter(function(q){return JJ(q)&&Q(q)}).map(function(q){return z[q]}),D=X([z].concat(P));return D=Object.keys(D).reduce(function(q,T){if(!JJ(T)&&T!==":disabled")q[T]=D[T];return q},{}),{componentFields:U,props:B,style:D}},YJ=LU;function MU(Z){for(var J=1;J<arguments.length;J++){var Y=arguments[J]!=null?arguments[J]:{},G=Object.keys(Y);if(typeof Object.getOwnPropertySymbols==="function")G=G.concat(Object.getOwnPropertySymbols(Y).filter(function(Q){return Object.getOwnPropertyDescriptor(Y,Q).enumerable}));G.forEach(function(Q){$U(Z,Q,Y[Q])})}return Z}function $U(Z,J,Y){if(J in Z)Object.defineProperty(Z,J,{value:Y,enumerable:!0,configurable:!0,writable:!0});else Z[J]=Y;return Z}var v8;function FU(Z){if(v8===void 0)v8=!!Z.canUseDOM&&!!window&&!!window.matchMedia&&function(J){return window.matchMedia(J)}||null;return v8}function GJ(Z,J){return Object.keys(Z).filter(function(Y){return J(Z[Y],Y)}).reduce(function(Y,G){return Y[G]=Z[G],Y},{})}function OU(Z){return Object.keys(Z).reduce(function(J,Y){if(Y.indexOf("@media")!==0)J[Y]=Z[Y];return J},{})}function VU(Z){var{addCSS:J,appendImportantToEachValue:Y,cssRuleSetToString:G,hash:Q,isNestedStyle:X,style:W,userAgent:H}=Z,z="";return Object.keys(W).filter(function(U){return U.indexOf("@media")===0}).map(function(U){var B=Y(GJ(W[U],function(K){return!X(K)}));if(!Object.keys(B).length)return;var L=G("",B,H),F="rmq-"+Q(U+L),M=U+"{ ."+F+L+"}";J(M),z+=(z?" ":"")+F}),z}function IU(Z){var{listener:J,listenersByQuery:Y,matchMedia:G,mediaQueryListsByQuery:Q,query:X}=Z;X=X.replace("@media ","");var W=Q[X];if(!W&&G)Q[X]=W=G(X);if(!Y||!Y[X])W.addListener(J),Y[X]={remove:function(){W.removeListener(J)}};return W}function h8(Z){var{ExecutionEnvironment:J,addCSS:Y,appendImportantToEachValue:G,config:Q,cssRuleSetToString:X,getComponentField:W,getGlobalState:H,hash:z,isNestedStyle:U,mergeStyles:B,props:L,setState:F,style:M}=Z,K=OU(M),$=VU({addCSS:Y,appendImportantToEachValue:G,cssRuleSetToString:X,hash:z,isNestedStyle:U,style:M,userAgent:Q.userAgent}),O=$?{className:$+(L.className?" "+L.className:"")}:null,N=Q.matchMedia||FU(J);if(!N)return{props:O,style:K};var P=MU({},W("_radiumMediaQueryListenersByQuery")),D=H("mediaQueryListsByQuery")||{};return Object.keys(M).filter(function(q){return q.indexOf("@media")===0}).map(function(q){var T=GJ(M[q],U);if(!Object.keys(T).length)return;var f=IU({listener:function(){return F(q,f.matches,"_all")},listenersByQuery:P,matchMedia:N,mediaQueryListsByQuery:D,query:q});if(f.matches)K=B([K,T])}),{componentFields:{_radiumMediaQueryListenersByQuery:P},globalState:{mediaQueryListsByQuery:D},props:O,style:K}}function b8(Z){var{addCSS:J,appendImportantToEachValue:Y,config:G,cssRuleSetToString:Q,hash:X,props:W,style:H}=Z,z=W.className,U=Object.keys(H).reduce(function(B,L){var F=H[L];if(L===":visited"){F=Y(F);var M=Q("",F,G.userAgent),K="rad-"+X(M),$="."+K+":visited"+M;J($),z=(z?z+" ":"")+K}else B[L]=F;return B},{});return{props:z===W.className?null:{className:z},style:U}}var K1={checkProps:tZ,keyframes:C8,mergeStyleArray:eZ,prefix:j8,removeNestedStyles:_8,resolveInteractionStyles:YJ,resolveMediaQueries:h8,visited:b8};var HJ=S(o6(),1);import y1 from"react";function qU(Z,J){if(!(Z instanceof J))throw TypeError("Cannot call a class as a function")}function QJ(Z,J){for(var Y=0;Y<J.length;Y++){var G=J[Y];if(G.enumerable=G.enumerable||!1,G.configurable=!0,"value"in G)G.writable=!0;Object.defineProperty(Z,G.key,G)}}function DU(Z,J,Y){if(J)QJ(Z.prototype,J);if(Y)QJ(Z,Y);return Z}var XJ=function(){function Z(J){qU(this,Z),this._userAgent=void 0,this._listeners=void 0,this._cssSet=void 0,this._userAgent=J,this._listeners=[],this._cssSet={}}return DU(Z,[{key:"subscribe",value:function(Y){var G=this;if(this._listeners.indexOf(Y)===-1)this._listeners.push(Y);return{remove:function(){var X=G._listeners.indexOf(Y);if(X>-1)G._listeners.splice(X,1)}}}},{key:"addCSS",value:function(Y){var G=this;if(!this._cssSet[Y])this._cssSet[Y]=!0,this._emitChange();return{remove:function(){delete G._cssSet[Y],G._emitChange()}}}},{key:"getCSS",value:function(){return Object.keys(this._cssSet).join(`
|
|
18
|
+
`)}},{key:"_emitChange",value:function(){this._listeners.forEach(function(Y){return Y()})}}]),Z}();function L0(Z){for(var J=1;J<arguments.length;J++){var Y=arguments[J]!=null?arguments[J]:{},G=Object.keys(Y);if(typeof Object.getOwnPropertySymbols==="function")G=G.concat(Object.getOwnPropertySymbols(Y).filter(function(Q){return Object.getOwnPropertyDescriptor(Y,Q).enumerable}));G.forEach(function(Q){NU(Z,Q,Y[Q])})}return Z}function NU(Z,J,Y){if(J in Z)Object.defineProperty(Z,J,{value:Y,enumerable:!0,configurable:!0,writable:!0});else Z[J]=Y;return Z}function f5(Z){if(typeof Symbol==="function"&&typeof Symbol.iterator==="symbol")f5=function(Y){return typeof Y};else f5=function(Y){return Y&&typeof Symbol==="function"&&Y.constructor===Symbol&&Y!==Symbol.prototype?"symbol":typeof Y};return f5(Z)}var zJ={plugins:[K1.mergeStyleArray,K1.checkProps,K1.resolveMediaQueries,K1.resolveInteractionStyles,K1.keyframes,K1.visited,K1.removeNestedStyles,K1.prefix,K1.checkProps]},WJ={},AU=!1,t1=null,RU=function(J){return J.type&&!J.type._isRadiumEnhanced},PU=function(J){var{children:Y,component:G,config:Q,existingKeyMap:X,extraStateKeyMap:W}=J;if(!Y)return Y;var H=f5(Y);if(H==="string"||H==="number")return Y;if(H==="function")return function(){var F=Y.apply(this,arguments);if(y1.isValidElement(F)){var M=r1(F);delete W[M];var K=t1(G,F,Q,X,!0,W),$=K.element;return $}return F};if(y1.Children.count(Y)===1&&Y.type){var z=y1.Children.only(Y),U=r1(z);delete W[U];var B=t1(G,z,Q,X,!0,W),L=B.element;return L}return y1.Children.map(Y,function(F){if(y1.isValidElement(F)){var M=r1(F);delete W[M];var K=t1(G,F,Q,X,!0,W),$=K.element;return $}return F})},TU=function(J){var{component:Y,config:G,existingKeyMap:Q,props:X,extraStateKeyMap:W}=J,H=X;return Object.keys(X).forEach(function(z){if(z==="children")return;var U=X[z];if(y1.isValidElement(U)){var B=r1(U);delete W[B],H=L0({},H);var L=t1(Y,U,G,Q,!0,W),F=L.element;H[z]=F}}),H},wU=function(J){var{componentName:Y,existingKeyMap:G,renderedElement:Q}=J,X=r1(Q),W=P5(X),H=!1,z=function(){if(H)return W;if(H=!0,G[W]){var B;if(typeof Q.type==="string")B=Q.type;else if(Q.type.constructor)B=Q.type.constructor.displayName||Q.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. "+(X?'Key "'+X+'" is a duplicate.':"Multiple elements have no key specified.")+' Component: "'+Y+'". '+(B?'Element: "'+B+'".':""))}return G[W]=!0,W};return z},EU=function(J,Y,G,Q){if(!J._radiumIsMounted)return;var X=j0(J),W={_radiumStyleState:L0({},X)};W._radiumStyleState[Y]=L0({},W._radiumStyleState[Y]),W._radiumStyleState[Y][G]=Q,J._lastRadiumState=W._radiumStyleState,J.setState(W)},SU=function(J){var{component:Y,config:G,existingKeyMap:Q,props:X,renderedElement:W}=J;if(!y1.isValidElement(W)||typeof W.type!=="string"||!X.style)return X;var H=X,z=G.plugins||zJ.plugins,U=Y.constructor.displayName||Y.constructor.name,B=wU({renderedElement:W,existingKeyMap:Q,componentName:U}),L=function(P){return Y[P]},F=function(P){return WJ[P]},M=function(P,D){return T5(Y.state,D||B(),P)},K=function(P,D,q){return EU(Y,q||B(),P,D)},$=function(P){var D=Y._radiumStyleKeeper;if(!D){if(AU)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 D.addCSS(P)},O=X.style;if(z.forEach(function(N){var P=N({ExecutionEnvironment:HJ.default,addCSS:$,appendImportantToEachValue:k6,componentName:U,config:G,cssRuleSetToString:g1,getComponentField:L,getGlobalState:F,getState:M,hash:_0,mergeStyles:S5,props:H,setState:K,isNestedStyle:E5,style:O})||{};O=P.style||O,H=P.props&&Object.keys(P.props).length?L0({},H,P.props):H;var D=P.componentFields||{};Object.keys(D).forEach(function(T){Y[T]=D[T]});var q=P.globalState||{};Object.keys(q).forEach(function(T){WJ[T]=q[T]})}),O!==X.style)H=L0({},H,{style:O});return H},xU=function(J,Y,G){if(typeof J.type==="string")Y=L0({},Y,{"data-radium":!0});return y1.cloneElement(J,Y,G)};t1=function(J,Y){var G=arguments.length>2&&arguments[2]!==void 0?arguments[2]:zJ,Q=arguments.length>3&&arguments[3]!==void 0?arguments[3]:{},X=arguments.length>4&&arguments[4]!==void 0?arguments[4]:!1,W=arguments.length>5?arguments[5]:void 0;if(!W){var H=j0(J);W=Object.keys(H).reduce(function(M,K){if(K!=="main")M[K]=!0;return M},{})}if(Array.isArray(Y)&&!Y.props){var z=Y.map(function(M){if(W){var K=r1(M);delete W[K]}return t1(J,M,G,Q,X,W).element});return{extraStateKeyMap:W,element:z}}if(!Y||Y.props&&Y.props["data-radium"]||X&&!RU(Y))return{extraStateKeyMap:W,element:Y};var U=Y.props.children,B=PU({children:U,component:J,config:G,existingKeyMap:Q,extraStateKeyMap:W}),L=TU({component:J,config:G,existingKeyMap:Q,extraStateKeyMap:W,props:Y.props});if(L=SU({component:J,config:G,existingKeyMap:Q,props:L,renderedElement:Y}),B===U&&L===Y.props)return{extraStateKeyMap:W,element:Y};var F=xU(Y,L!==Y.props?L:{},B);return{extraStateKeyMap:W,element:F}};var UJ=t1;var KJ=S(_6(),1);import C5,{useContext as BJ}from"react";function g8(){return g8=Object.assign||function(Z){for(var J=1;J<arguments.length;J++){var Y=arguments[J];for(var G in Y)if(Object.prototype.hasOwnProperty.call(Y,G))Z[G]=Y[G]}return Z},g8.apply(this,arguments)}var k0=C5.createContext(void 0),M0=C5.createContext(void 0);function $0(Z){var J=C5.forwardRef(function(Y,G){var Q=BJ(M0),X=BJ(k0);return C5.createElement(Z,g8({ref:G},Y,{radiumConfigContext:Q,styleKeeperContext:X}))});return J.displayName="withRadiumContexts(".concat(Z.displayName||Z.name||"Component",")"),KJ.default(J,Z)}function e1(Z){if(typeof Symbol==="function"&&typeof Symbol.iterator==="symbol")e1=function(Y){return typeof Y};else e1=function(Y){return Y&&typeof Symbol==="function"&&Y.constructor===Symbol&&Y!==Symbol.prototype?"symbol":typeof Y};return e1(Z)}function VJ(Z,J){if(!(Z instanceof J))throw TypeError("Cannot call a class as a function")}function LJ(Z,J){for(var Y=0;Y<J.length;Y++){var G=J[Y];if(G.enumerable=G.enumerable||!1,G.configurable=!0,"value"in G)G.writable=!0;Object.defineProperty(Z,G.key,G)}}function fU(Z,J,Y){if(J)LJ(Z.prototype,J);if(Y)LJ(Z,Y);return Z}function IJ(Z,J){if(J&&(e1(J)==="object"||typeof J==="function"))return J;return qJ(Z)}function qJ(Z){if(Z===void 0)throw ReferenceError("this hasn't been initialised - super() hasn't been called");return Z}function m1(Z,J,Y){if(typeof Reflect<"u"&&Reflect.get)m1=Reflect.get;else m1=function(Q,X,W){var H=CU(Q,X);if(!H)return;var z=Object.getOwnPropertyDescriptor(H,X);if(z.get)return z.get.call(W);return z.value};return m1(Z,J,Y||Z)}function CU(Z,J){while(!Object.prototype.hasOwnProperty.call(Z,J))if(Z=V1(Z),Z===null)break;return Z}function V1(Z){return V1=Object.setPrototypeOf?Object.getPrototypeOf:function(Y){return Y.__proto__||Object.getPrototypeOf(Y)},V1(Z)}function DJ(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)y8(Z,J)}function y8(Z,J){return y8=Object.setPrototypeOf||function(G,Q){return G.__proto__=Q,G},y8(Z,J)}function jU(Z,J){return vU(Z)||kU(Z,J)||_U()}function _U(){throw TypeError("Invalid attempt to destructure non-iterable instance")}function kU(Z,J){var Y=[],G=!0,Q=!1,X=void 0;try{for(var W=Z[Symbol.iterator](),H;!(G=(H=W.next()).done);G=!0)if(Y.push(H.value),J&&Y.length===J)break}catch(z){Q=!0,X=z}finally{try{if(!G&&W.return!=null)W.return()}finally{if(Q)throw X}}return Y}function vU(Z){if(Array.isArray(Z))return Z}function m8(Z){for(var J=1;J<arguments.length;J++){var Y=arguments[J]!=null?arguments[J]:{},G=Object.keys(Y);if(typeof Object.getOwnPropertySymbols==="function")G=G.concat(Object.getOwnPropertySymbols(Y).filter(function(Q){return Object.getOwnPropertyDescriptor(Y,Q).enumerable}));G.forEach(function(Q){hU(Z,Q,Y[Q])})}return Z}function hU(Z,J,Y){if(J in Z)Object.defineProperty(Z,J,{value:Y,enumerable:!0,configurable:!0,writable:!0});else Z[J]=Y;return Z}function NJ(Z,J){if(Z==null)return{};var Y=bU(Z,J),G,Q;if(Object.getOwnPropertySymbols){var X=Object.getOwnPropertySymbols(Z);for(Q=0;Q<X.length;Q++){if(G=X[Q],J.indexOf(G)>=0)continue;if(!Object.prototype.propertyIsEnumerable.call(Z,G))continue;Y[G]=Z[G]}}return Y}function bU(Z,J){if(Z==null)return{};var Y={},G=Object.keys(Z),Q,X;for(X=0;X<G.length;X++){if(Q=G[X],J.indexOf(Q)>=0)continue;Y[Q]=Z[Q]}return Y}function gU(Z){var J=yU(Z,"string");return e1(J)==="symbol"?J:String(J)}function yU(Z,J){if(e1(Z)!=="object"||Z===null)return Z;var Y=Z[Symbol.toPrimitive];if(Y!==void 0){var G=Y.call(Z,J||"default");if(e1(G)!=="object")return G;throw TypeError("@@toPrimitive must return a primitive value.")}return(J==="string"?String:Number)(Z)}var cU=["arguments","callee","caller","length","name","prototype","type"],_5,PJ;function pU(Z,J){Object.getOwnPropertyNames(Z).forEach(function(Y){if(cU.indexOf(Y)<0&&!J.hasOwnProperty(Y)){var G=Object.getOwnPropertyDescriptor(Z,Y);G&&Object.defineProperty(J,Y,G)}})}function lU(Z){var J=Z.prototype||{};return!Z.isReactComponent&&!J.isReactComponent&&!Z.render&&!J.render}function iU(Z){return typeof Z==="function"&&/^\s*class\s+/.test(Z.toString())}function nU(Z,J){PJ.forEach(function(Y){var G=Object.getOwnPropertyDescriptor(Z,Y),Q=(G||{}).value;if(!Q)return;var X=Object.getOwnPropertyDescriptor(_5,Y),W=(X||{}).value,H=J.prototype[Y];if(!H&&Q!==W)G&&Object.defineProperty(J.prototype,Y,G),delete Z[Y]})}function TJ(Z){if(Z._extraRadiumStateKeys&&Z._extraRadiumStateKeys.length>0){var J=Z._extraRadiumStateKeys.reduce(function(Y,G){var Q=Y[G],X=NJ(Y,[G].map(gU));return X},j0(Z));Z._lastRadiumState=J,Z.setState({_radiumStyleState:J})}}function wJ(Z){var{_radiumMouseUpListener:J,_radiumMediaQueryListenersByQuery:Y}=Z;if(Z._radiumIsMounted=!1,J)J.remove();if(Y)Object.keys(Y).forEach(function(G){Y[G].remove()},Z)}function EJ(Z,J,Y){var G=Z||J||Y;if(Y&&G!==Y)G=m8({},Y,G);return G}function SJ(Z,J,Y,G){var Q=UJ(Z,J,Y),X=Q.extraStateKeyMap,W=Q.element;if(Z._extraRadiumStateKeys=Object.keys(X),G)return AJ.createElement(M0.Provider,{value:G},W);return W}function FJ(Z,J){var Y=AJ.forwardRef(function(G,Q){var X=G.radiumConfig,W=NJ(G,["radiumConfig"]),H=MJ(M0),z=MJ(k0),U=mU({_radiumStyleState:{}}),B=jU(U,2),L=B[0],F=B[1],M=uU({state:L,setState:F,_radiumMediaQueryListenersByQuery:void 0,_radiumMouseUpListener:void 0,_radiumIsMounted:!0,_lastRadiumState:void 0,_extraRadiumStateKeys:void 0,_radiumStyleKeeper:z}).current;M.state=L,$J(function(){return function(){wJ(M)}},[M]);var K=M._extraRadiumStateKeys&&M._extraRadiumStateKeys.length>0;$J(function(){TJ(M)},[K,M]);var $=Z(W,Q),O=EJ(X,H,J);return SJ(M,$,O,X)});return Y._isRadiumEnhanced=!0,Y.defaultProps=Z.defaultProps,RJ.default(Y,Z)}function oU(Z,J,Y){var G=function(Q){DJ(X,Q);function X(){var W;VJ(this,X),W=IJ(this,V1(X).apply(this,arguments)),W.state=W.state||{},W._radiumStyleKeeper=W.props.styleKeeperContext,W._radiumMediaQueryListenersByQuery=W._radiumMediaQueryListenersByQuery,W._radiumMouseUpListener=W._radiumMouseUpListener,W._radiumIsMounted=!0,W._lastRadiumState=void 0,W._extraRadiumStateKeys=void 0,W.state._radiumStyleState={};var H=qJ(W);return nU(H,J),W}return fU(X,[{key:"componentDidUpdate",value:function(H,z,U){if(m1(V1(X.prototype),"componentDidUpdate",this))m1(V1(X.prototype),"componentDidUpdate",this).call(this,H,z,U);TJ(this)}},{key:"componentWillUnmount",value:function(){if(m1(V1(X.prototype),"componentWillUnmount",this))m1(V1(X.prototype),"componentWillUnmount",this).call(this);wJ(this)}},{key:"render",value:function(){var H=m1(V1(X.prototype),"render",this).call(this),z=EJ(this.props.radiumConfig,this.props.radiumConfigContext,Y);return SJ(this,H,z,this.props.radiumConfig)}}]),X}(J);if(G._isRadiumEnhanced=!0,_5=G.prototype,PJ=Object.getOwnPropertyNames(_5).filter(function(Q){return Q!=="constructor"&&typeof _5[Q]==="function"}),pU(Z,G),G.propTypes&&G.propTypes.style)G.propTypes=m8({},G.propTypes,{style:j5.default.oneOfType([j5.default.array,j5.default.object])});return G.displayName=Z.displayName||Z.name||"Component",$0(G)}function aU(Z){return Z=function(J){function Y(){var G=Reflect.construct(J,arguments,this.constructor);return G}return Reflect.setPrototypeOf(Y.prototype,J.prototype),Reflect.setPrototypeOf(Y,J),Y}(Z),Z}var OJ=dU(function(){return null}).$$typeof;function F0(Z){var J=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};if(OJ&&Z.$$typeof===OJ)return FJ(Z.render,J);if(typeof Z!=="function")return sU(J,Z);var Y=Z;if(lU(Y))return FJ(Y,J);var G=Y;if(iU(G))G=aU(G);if(G===Y)G=function(Q){DJ(X,Q);function X(){return VJ(this,X),IJ(this,V1(X).apply(this,arguments))}return X}(G);return oU(Y,G,J)}function sU(Z,J){var Y=m8({},Z,J);return function(G){return F0(G,Y)}}var k5=S(f6(),1);import YB,{PureComponent as GB}from"react";function O0(Z){if(typeof Symbol==="function"&&typeof Symbol.iterator==="symbol")O0=function(Y){return typeof Y};else O0=function(Y){return Y&&typeof Symbol==="function"&&Y.constructor===Symbol&&Y!==Symbol.prototype?"symbol":typeof Y};return O0(Z)}function rU(Z,J){if(!(Z instanceof J))throw TypeError("Cannot call a class as a function")}function xJ(Z,J){for(var Y=0;Y<J.length;Y++){var G=J[Y];if(G.enumerable=G.enumerable||!1,G.configurable=!0,"value"in G)G.writable=!0;Object.defineProperty(Z,G.key,G)}}function tU(Z,J,Y){if(J)xJ(Z.prototype,J);if(Y)xJ(Z,Y);return Z}function eU(Z,J){if(J&&(O0(J)==="object"||typeof J==="function"))return J;return ZB(Z)}function ZB(Z){if(Z===void 0)throw ReferenceError("this hasn't been initialised - super() hasn't been called");return Z}function u8(Z){return u8=Object.setPrototypeOf?Object.getPrototypeOf:function(Y){return Y.__proto__||Object.getPrototypeOf(Y)},u8(Z)}function JB(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)d8(Z,J)}function d8(Z,J){return d8=Object.setPrototypeOf||function(G,Q){return G.__proto__=Q,G},d8(Z,J)}var c8=function(Z){JB(J,Z);function J(){return rU(this,J),eU(this,u8(J).apply(this,arguments))}return tU(J,[{key:"_buildStyles",value:function(G){var Q=this,X=this.props.radiumConfig&&this.props.radiumConfig.userAgent||this.props.radiumConfigContext&&this.props.radiumConfigContext.userAgent,W=this.props.scopeSelector,H=Object.keys(G).reduce(function(U,B){if(O0(G[B])!=="object")U[B]=G[B];return U},{}),z=Object.keys(H).length?g1(W||"",H,X):"";return z+Object.keys(G).reduce(function(U,B){var L=G[B];if(B==="mediaQueries")U+=Q._buildMediaQueryString(L);else if(O0(G[B])==="object"){var F=W?B.split(",").map(function(M){return W+" "+M.trim()}).join(","):B;U+=g1(F,L,X)}return U},"")}},{key:"_buildMediaQueryString",value:function(G){var Q=this,X="";return Object.keys(G).forEach(function(W){X+="@media "+W+"{"+Q._buildStyles(G[W])+"}"}),X}},{key:"render",value:function(){if(!this.props.rules)return null;var G=this._buildStyles(this.props.rules);return YB.createElement("style",{dangerouslySetInnerHTML:{__html:G}})}}]),J}(GB);c8.propTypes={radiumConfig:k5.default.object,rules:k5.default.object,scopeSelector:k5.default.string};c8.defaultProps={scopeSelector:""};var fJ=$0(c8);import h5,{useContext as $B,useRef as FB}from"react";import UB,{Component as BB}from"react";function v5(Z){if(typeof Symbol==="function"&&typeof Symbol.iterator==="symbol")v5=function(Y){return typeof Y};else v5=function(Y){return Y&&typeof Symbol==="function"&&Y.constructor===Symbol&&Y!==Symbol.prototype?"symbol":typeof Y};return v5(Z)}function QB(Z,J){if(!(Z instanceof J))throw TypeError("Cannot call a class as a function")}function CJ(Z,J){for(var Y=0;Y<J.length;Y++){var G=J[Y];if(G.enumerable=G.enumerable||!1,G.configurable=!0,"value"in G)G.writable=!0;Object.defineProperty(Z,G.key,G)}}function XB(Z,J,Y){if(J)CJ(Z.prototype,J);if(Y)CJ(Z,Y);return Z}function WB(Z,J){if(J&&(v5(J)==="object"||typeof J==="function"))return J;return HB(Z)}function HB(Z){if(Z===void 0)throw ReferenceError("this hasn't been initialised - super() hasn't been called");return Z}function p8(Z){return p8=Object.setPrototypeOf?Object.getPrototypeOf:function(Y){return Y.__proto__||Object.getPrototypeOf(Y)},p8(Z)}function zB(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)l8(Z,J)}function l8(Z,J){return l8=Object.setPrototypeOf||function(G,Q){return G.__proto__=Q,G},l8(Z,J)}var KB=function(Z){zB(J,Z);function J(){var Y;if(QB(this,J),Y=WB(this,p8(J).apply(this,arguments)),Y.styleKeeper=void 0,Y._subscription=void 0,Y._root=void 0,Y._css=void 0,Y._onChange=function(){var G=Y.styleKeeper.getCSS();if(G!==Y._css){if(Y._root)Y._root.innerHTML=G;else throw Error("No root style object found, even after StyleSheet mount.");Y._css=G}},!Y.props.styleKeeperContext)throw Error("StyleRoot is required to use StyleSheet");return Y.styleKeeper=Y.props.styleKeeperContext,Y._css=Y.styleKeeper.getCSS(),Y}return XB(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 G=this;return UB.createElement("style",{dangerouslySetInnerHTML:{__html:this._css},ref:function(X){G._root=X}})}}]),J}(BB),jJ=$0(KB);function LB(Z,J){if(Z==null)return{};var Y=MB(Z,J),G,Q;if(Object.getOwnPropertySymbols){var X=Object.getOwnPropertySymbols(Z);for(Q=0;Q<X.length;Q++){if(G=X[Q],J.indexOf(G)>=0)continue;if(!Object.prototype.propertyIsEnumerable.call(Z,G))continue;Y[G]=Z[G]}}return Y}function MB(Z,J){if(Z==null)return{};var Y={},G=Object.keys(Z),Q,X;for(X=0;X<G.length;X++){if(Q=G[X],J.indexOf(Q)>=0)continue;Y[Q]=Z[Q]}return Y}function OB(Z,J){var Y=Z&&Z.userAgent||J&&J.userAgent;return new XJ(Y)}var VB=F0(function(Z){var J=Z.children,Y=LB(Z,["children"]);return h5.createElement("div",Y,J,h5.createElement(jJ,null))}),IB=function(J){var Y=J.radiumConfig,G=$B(M0),Q=FB(OB(Y,G));return h5.createElement(k0.Provider,{value:Q.current},h5.createElement(VB,J))},_J=IB;function i8(Z,J){return{__radiumKeyframes:!0,__process:function(G){var Q=rZ(G),X=Object.keys(Z).map(function(z){return g1(z,Z[z],G)}).join(`
|
|
19
|
+
`),W=(J?J+"-":"")+"radium-animation-"+_0(X),H="@"+Q+" "+W+` {
|
|
20
20
|
`+X+`
|
|
21
21
|
}
|
|
22
|
-
`;return{css:H,animationName:W}}}}function O0(Z){return $0(Z)}O0.Plugins=B1;O0.Style=EJ;O0.StyleRoot=fJ;O0.getState=P5;O0.keyframes=i8;var e=O0;function n8(Z){return{all:Z=Z||new Map,on:function(J,Y){var G=Z.get(J);G?G.push(Y):Z.set(J,[Y])},off:function(J,Y){var G=Z.get(J);G&&(Y?G.splice(G.indexOf(Y)>>>0,1):Z.set(J,[]))},emit:function(J,Y){var G=Z.get(J);G&&G.slice().map(function(Q){Q(Y)}),(G=Z.get("*"))&&G.slice().map(function(Q){Q(J,Y)})}}}import{createContext as VB}from"react";var k0=n8(),IB=VB(k0),m1=IB;var M1=Object.create(null);M1.open="0";M1.close="1";M1.ping="2";M1.pong="3";M1.message="4";M1.upgrade="5";M1.noop="6";var v0=Object.create(null);Object.keys(M1).forEach((Z)=>{v0[M1[Z]]=Z});var h0={type:"error",data:"parser error"};var _J=typeof Blob==="function"||typeof Blob<"u"&&Object.prototype.toString.call(Blob)==="[object BlobConstructor]",kJ=typeof ArrayBuffer==="function",vJ=(Z)=>{return typeof ArrayBuffer.isView==="function"?ArrayBuffer.isView(Z):Z&&Z.buffer instanceof ArrayBuffer},b0=({type:Z,data:J},Y,G)=>{if(_J&&J instanceof Blob)if(Y)return G(J);else return CJ(J,G);else if(kJ&&(J instanceof ArrayBuffer||vJ(J)))if(Y)return G(J);else return CJ(new Blob([J]),G);return G(M1[Z]+(J||""))},CJ=(Z,J)=>{let Y=new FileReader;return Y.onload=function(){let G=Y.result.split(",")[1];J("b"+(G||""))},Y.readAsDataURL(Z)};function jJ(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 o8;function hJ(Z,J){if(_J&&Z.data instanceof Blob)return Z.data.arrayBuffer().then(jJ).then(J);else if(kJ&&(Z.data instanceof ArrayBuffer||vJ(Z.data)))return J(jJ(Z.data));b0(Z,!1,(Y)=>{if(!o8)o8=new TextEncoder;J(o8.encode(Y))})}var y0=typeof Uint8Array>"u"?[]:new Uint8Array(256);for(let Z=0;Z<64;Z++)y0["ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/".charCodeAt(Z)]=Z;var bJ=(Z)=>{let J=Z.length*0.75,Y=Z.length,G,Q=0,X,W,H,z;if(Z[Z.length-1]==="="){if(J--,Z[Z.length-2]==="=")J--}let U=new ArrayBuffer(J),B=new Uint8Array(U);for(G=0;G<Y;G+=4)X=y0[Z.charCodeAt(G)],W=y0[Z.charCodeAt(G+1)],H=y0[Z.charCodeAt(G+2)],z=y0[Z.charCodeAt(G+3)],B[Q++]=X<<2|W>>4,B[Q++]=(W&15)<<4|H>>2,B[Q++]=(H&3)<<6|z&63;return U};var qB=typeof ArrayBuffer==="function",g0=(Z,J)=>{if(typeof Z!=="string")return{type:"message",data:yJ(Z,J)};let Y=Z.charAt(0);if(Y==="b")return{type:"message",data:DB(Z.substring(1),J)};if(!v0[Y])return h0;return Z.length>1?{type:v0[Y],data:Z.substring(1)}:{type:v0[Y]}},DB=(Z,J)=>{if(qB){let Y=bJ(Z);return yJ(Y,J)}else return{base64:!0,data:Z}},yJ=(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 gJ=String.fromCharCode(30),mJ=(Z,J)=>{let Y=Z.length,G=Array(Y),Q=0;Z.forEach((X,W)=>{b0(X,!1,(H)=>{if(G[W]=H,++Q===Y)J(G.join(gJ))})})},uJ=(Z,J)=>{let Y=Z.split(gJ),G=[];for(let Q=0;Q<Y.length;Q++){let X=g0(Y[Q],J);if(G.push(X),X.type==="error")break}return G};function dJ(){return new TransformStream({transform(Z,J){hJ(Z,(Y)=>{let G=Y.length,Q;if(G<126)Q=new Uint8Array(1),new DataView(Q.buffer).setUint8(0,G);else if(G<65536){Q=new Uint8Array(3);let X=new DataView(Q.buffer);X.setUint8(0,126),X.setUint16(1,G)}else{Q=new Uint8Array(9);let X=new DataView(Q.buffer);X.setUint8(0,127),X.setBigUint64(1,BigInt(G))}if(Z.data&&typeof Z.data!=="string")Q[0]|=128;J.enqueue(Q),J.enqueue(Y)})}})}var a8;function h5(Z){return Z.reduce((J,Y)=>J+Y.length,0)}function b5(Z,J){if(Z[0].length===J)return Z.shift();let Y=new Uint8Array(J),G=0;for(let Q=0;Q<J;Q++)if(Y[Q]=Z[0][G++],G===Z[0].length)Z.shift(),G=0;if(Z.length&&G<Z[0].length)Z[0]=Z[0].slice(G);return Y}function cJ(Z,J){if(!a8)a8=new TextDecoder;let Y=[],G=0,Q=-1,X=!1;return new TransformStream({transform(W,H){Y.push(W);while(!0){if(G===0){if(h5(Y)<1)break;let z=b5(Y,1);if(X=(z[0]&128)===128,Q=z[0]&127,Q<126)G=3;else if(Q===126)G=1;else G=2}else if(G===1){if(h5(Y)<2)break;let z=b5(Y,2);Q=new DataView(z.buffer,z.byteOffset,z.length).getUint16(0),G=3}else if(G===2){if(h5(Y)<8)break;let z=b5(Y,8),U=new DataView(z.buffer,z.byteOffset,z.length),B=U.getUint32(0);if(B>Math.pow(2,21)-1){H.enqueue(h0);break}Q=B*Math.pow(2,32)+U.getUint32(4),G=3}else{if(h5(Y)<Q)break;let z=b5(Y,Q);H.enqueue(g0(X?z:a8.decode(z),J)),G=0}if(Q===0||Q>Z){H.enqueue(h0);break}}}})}var s8=4;function j(Z){if(Z)return NB(Z)}function NB(Z){for(var J in j.prototype)Z[J]=j.prototype[J];return Z}j.prototype.on=j.prototype.addEventListener=function(Z,J){return this._callbacks=this._callbacks||{},(this._callbacks["$"+Z]=this._callbacks["$"+Z]||[]).push(J),this};j.prototype.once=function(Z,J){function Y(){this.off(Z,Y),J.apply(this,arguments)}return Y.fn=J,this.on(Z,Y),this};j.prototype.off=j.prototype.removeListener=j.prototype.removeAllListeners=j.prototype.removeEventListener=function(Z,J){if(this._callbacks=this._callbacks||{},arguments.length==0)return this._callbacks={},this;var Y=this._callbacks["$"+Z];if(!Y)return this;if(arguments.length==1)return delete this._callbacks["$"+Z],this;var G;for(var Q=0;Q<Y.length;Q++)if(G=Y[Q],G===J||G.fn===J){Y.splice(Q,1);break}if(Y.length===0)delete this._callbacks["$"+Z];return this};j.prototype.emit=function(Z){this._callbacks=this._callbacks||{};var J=Array(arguments.length-1),Y=this._callbacks["$"+Z];for(var G=1;G<arguments.length;G++)J[G-1]=arguments[G];if(Y){Y=Y.slice(0);for(var G=0,Q=Y.length;G<Q;++G)Y[G].apply(this,J)}return this};j.prototype.emitReserved=j.prototype.emit;j.prototype.listeners=function(Z){return this._callbacks=this._callbacks||{},this._callbacks["$"+Z]||[]};j.prototype.hasListeners=function(Z){return!!this.listeners(Z).length};var T1=(()=>{if(typeof Promise==="function"&&typeof Promise.resolve==="function")return(J)=>Promise.resolve().then(J);else return(J,Y)=>Y(J,0)})(),o=(()=>{if(typeof self<"u")return self;else if(typeof window<"u")return window;else return Function("return this")()})(),pJ="arraybuffer";function lJ(){}function y5(Z,...J){return J.reduce((Y,G)=>{if(Z.hasOwnProperty(G))Y[G]=Z[G];return Y},{})}var AB=o.setTimeout,RB=o.clearTimeout;function w1(Z,J){if(J.useNativeTimers)Z.setTimeoutFn=AB.bind(o),Z.clearTimeoutFn=RB.bind(o);else Z.setTimeoutFn=o.setTimeout.bind(o),Z.clearTimeoutFn=o.clearTimeout.bind(o)}var PB=1.33;function iJ(Z){if(typeof Z==="string")return TB(Z);return Math.ceil((Z.byteLength||Z.size)*PB)}function TB(Z){let J=0,Y=0;for(let G=0,Q=Z.length;G<Q;G++)if(J=Z.charCodeAt(G),J<128)Y+=1;else if(J<2048)Y+=2;else if(J<55296||J>=57344)Y+=3;else G++,Y+=4;return Y}function g5(){return Date.now().toString(36).substring(3)+Math.random().toString(36).substring(2,5)}function nJ(Z){let J="";for(let Y in Z)if(Z.hasOwnProperty(Y)){if(J.length)J+="&";J+=encodeURIComponent(Y)+"="+encodeURIComponent(Z[Y])}return J}function oJ(Z){let J={},Y=Z.split("&");for(let G=0,Q=Y.length;G<Q;G++){let X=Y[G].split("=");J[decodeURIComponent(X[0])]=decodeURIComponent(X[1])}return J}class r8 extends Error{constructor(Z,J,Y){super(Z);this.description=J,this.context=Y,this.type="TransportError"}}class u1 extends j{constructor(Z){super();this.writable=!1,w1(this,Z),this.opts=Z,this.query=Z.query,this.socket=Z.socket,this.supportsBinary=!Z.forceBase64}onError(Z,J,Y){return super.emitReserved("error",new r8(Z,J,Y)),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=g0(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=nJ(Z);return J.length?"?"+J:""}}class m5 extends u1{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 Y=0;if(this._polling)Y++,this.once("pollComplete",function(){--Y||J()});if(!this.writable)Y++,this.once("drain",function(){--Y||J()})}else J()}_poll(){this._polling=!0,this.doPoll(),this.emitReserved("poll")}onData(Z){let J=(Y)=>{if(this.readyState==="opening"&&Y.type==="open")this.onOpen();if(Y.type==="close")return this.onClose({description:"transport closed by the server"}),!1;this.onPacket(Y)};if(uJ(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,mJ(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]=g5();if(!this.supportsBinary&&!J.sid)J.b64=1;return this.createUri(Z,J)}}var aJ=!1;try{aJ=typeof XMLHttpRequest<"u"&&"withCredentials"in new XMLHttpRequest}catch(Z){}var sJ=aJ;function wB(){}class tJ extends m5{constructor(Z){super(Z);if(typeof location<"u"){let J=location.protocol==="https:",Y=location.port;if(!Y)Y=J?"443":"80";this.xd=typeof location<"u"&&Z.hostname!==location.hostname||Y!==Z.port}}doWrite(Z,J){let Y=this.request({method:"POST",data:Z});Y.on("success",J),Y.on("error",(G,Q)=>{this.onError("xhr post error",G,Q)})}doPoll(){let Z=this.request();Z.on("data",this.onData.bind(this)),Z.on("error",(J,Y)=>{this.onError("xhr poll error",J,Y)}),this.pollXhr=Z}}class V1 extends j{constructor(Z,J,Y){super();this.createRequest=Z,w1(this,Y),this._opts=Y,this._method=Y.method||"GET",this._uri=J,this._data=Y.data!==void 0?Y.data:null,this._create()}_create(){var Z;let J=y5(this._opts,"agent","pfx","key","passphrase","cert","ca","ciphers","rejectUnauthorized","autoUnref");J.xdomain=!!this._opts.xd;let Y=this._xhr=this.createRequest(J);try{Y.open(this._method,this._uri,!0);try{if(this._opts.extraHeaders){Y.setDisableHeaderCheck&&Y.setDisableHeaderCheck(!0);for(let G in this._opts.extraHeaders)if(this._opts.extraHeaders.hasOwnProperty(G))Y.setRequestHeader(G,this._opts.extraHeaders[G])}}catch(G){}if(this._method==="POST")try{Y.setRequestHeader("Content-type","text/plain;charset=UTF-8")}catch(G){}try{Y.setRequestHeader("Accept","*/*")}catch(G){}if((Z=this._opts.cookieJar)===null||Z===void 0||Z.addCookies(Y),"withCredentials"in Y)Y.withCredentials=this._opts.withCredentials;if(this._opts.requestTimeout)Y.timeout=this._opts.requestTimeout;Y.onreadystatechange=()=>{var G;if(Y.readyState===3)(G=this._opts.cookieJar)===null||G===void 0||G.parseCookies(Y.getResponseHeader("set-cookie"));if(Y.readyState!==4)return;if(Y.status===200||Y.status===1223)this._onLoad();else this.setTimeoutFn(()=>{this._onError(typeof Y.status==="number"?Y.status:0)},0)},Y.send(this._data)}catch(G){this.setTimeoutFn(()=>{this._onError(G)},0);return}if(typeof document<"u")this._index=V1.requestsCount++,V1.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=wB,Z)try{this._xhr.abort()}catch(J){}if(typeof document<"u")delete V1.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()}}V1.requestsCount=0;V1.requests={};if(typeof document<"u"){if(typeof attachEvent==="function")attachEvent("onunload",rJ);else if(typeof addEventListener==="function"){let Z="onpagehide"in o?"pagehide":"unload";addEventListener(Z,rJ,!1)}}function rJ(){for(let Z in V1.requests)if(V1.requests.hasOwnProperty(Z))V1.requests[Z].abort()}var EB=function(){let Z=eJ({xdomain:!1});return Z&&Z.responseType!==null}();class e1 extends tJ{constructor(Z){super(Z);let J=Z&&Z.forceBase64;this.supportsBinary=EB&&!J}request(Z={}){return Object.assign(Z,{xd:this.xd},this.opts),new V1(eJ,this.uri(),Z)}}function eJ(Z){let J=Z.xdomain;try{if(typeof XMLHttpRequest<"u"&&(!J||sJ))return new XMLHttpRequest}catch(Y){}if(!J)try{return new o[["Active"].concat("Object").join("X")]("Microsoft.XMLHTTP")}catch(Y){}}var ZY=typeof navigator<"u"&&typeof navigator.product==="string"&&navigator.product.toLowerCase()==="reactnative";class JY extends u1{get name(){return"websocket"}doOpen(){let Z=this.uri(),J=this.opts.protocols,Y=ZY?{}:y5(this.opts,"agent","perMessageDeflate","pfx","key","passphrase","cert","ca","ciphers","rejectUnauthorized","localAddress","protocolVersion","origin","maxPayload","family","checkServerIdentity");if(this.opts.extraHeaders)Y.headers=this.opts.extraHeaders;try{this.ws=this.createSocket(Z,J,Y)}catch(G){return this.emitReserved("error",G)}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 Y=Z[J],G=J===Z.length-1;b0(Y,this.supportsBinary,(Q)=>{try{this.doWrite(Y,Q)}catch(X){}if(G)T1(()=>{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]=g5();if(!this.supportsBinary)J.b64=1;return this.createUri(Z,J)}}var t8=o.WebSocket||o.MozWebSocket;class Z0 extends JY{createSocket(Z,J,Y){return!ZY?J?new t8(Z,J):new t8(Z):new t8(Z,J,Y)}doWrite(Z,J){this.ws.send(J)}}class m0 extends u1{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=cJ(Number.MAX_SAFE_INTEGER,this.socket.binaryType),Y=Z.readable.pipeThrough(J).getReader(),G=dJ();G.readable.pipeTo(Z.writable),this._writer=G.writable.getWriter();let Q=()=>{Y.read().then(({done:W,value:H})=>{if(W)return;this.onPacket(H),Q()}).catch((W)=>{})};Q();let X={type:"open"};if(this.query.sid)X.data=`{"sid":"${this.query.sid}"}`;this._writer.write(X).then(()=>this.onOpen())})})}write(Z){this.writable=!1;for(let J=0;J<Z.length;J++){let Y=Z[J],G=J===Z.length-1;this._writer.write(Y).then(()=>{if(G)T1(()=>{this.writable=!0,this.emitReserved("drain")},this.setTimeoutFn)})}}doClose(){var Z;(Z=this._transport)===null||Z===void 0||Z.close()}}var e8={websocket:Z0,webtransport:m0,polling:e1};var SB=/^(?:(?![^:@\/?#]+:[^:@\/]*@)(http|https|ws|wss):\/\/)?((?:(([^:@\/?#]*)(?::([^:@\/?#]*))?)?@)?((?:[a-f0-9]{0,4}:){2,7}[a-f0-9]{0,4}|[^:\/?#]*)(?::(\d*))?)(((\/(?:[^?#](?![^?#\/]*\.[^?#\/.]+(?:[?#]|$)))*\/?)?([^?#\/]*))(?:\?([^#]*))?(?:#(.*))?)/,xB=["source","protocol","authority","userInfo","user","password","host","port","relative","path","directory","file","query","anchor"];function V0(Z){if(Z.length>8000)throw"URI too long";let J=Z,Y=Z.indexOf("["),G=Z.indexOf("]");if(Y!=-1&&G!=-1)Z=Z.substring(0,Y)+Z.substring(Y,G).replace(/:/g,";")+Z.substring(G,Z.length);let Q=SB.exec(Z||""),X={},W=14;while(W--)X[xB[W]]=Q[W]||"";if(Y!=-1&&G!=-1)X.source=J,X.host=X.host.substring(1,X.host.length-1).replace(/;/g,":"),X.authority=X.authority.replace("[","").replace("]","").replace(/;/g,":"),X.ipv6uri=!0;return X.pathNames=fB(X,X.path),X.queryKey=CB(X,X.query),X}function fB(Z,J){let Y=/\/{2,9}/g,G=J.replace(Y,"/").split("/");if(J.slice(0,1)=="/"||J.length===0)G.splice(0,1);if(J.slice(-1)=="/")G.splice(G.length-1,1);return G}function CB(Z,J){let Y={};return J.replace(/(?:^|&)([^&=]*)=?([^&]*)/g,function(G,Q,X){if(Q)Y[Q]=X}),Y}var Z9=typeof addEventListener==="function"&&typeof removeEventListener==="function",u5=[];if(Z9)addEventListener("offline",()=>{u5.forEach((Z)=>Z())},!1);class E1 extends j{constructor(Z,J){super();if(this.binaryType=pJ,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 Y=V0(Z);if(J.hostname=Y.host,J.secure=Y.protocol==="https"||Y.protocol==="wss",J.port=Y.port,Y.query)J.query=Y.query}else if(J.host)J.hostname=V0(J.host).host;if(w1(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((Y)=>{let G=Y.prototype.name;this.transports.push(G),this._transportsByName[G]=Y}),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=oJ(this.opts.query);if(Z9){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"})},u5.push(this._offlineEventListener)}if(this.opts.withCredentials)this._cookieJar=lJ();this._open()}createTransport(Z){let J=Object.assign({},this.opts.query);if(J.EIO=s8,J.transport=Z,this.id)J.sid=this.id;let Y=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](Y)}_open(){if(this.transports.length===0){this.setTimeoutFn(()=>{this.emitReserved("error","No transports available")},0);return}let Z=this.opts.rememberUpgrade&&E1.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",E1.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 Y=0;Y<this.writeBuffer.length;Y++){let G=this.writeBuffer[Y].data;if(G)J+=iJ(G);if(Y>0&&J>this._maxPayload)return this.writeBuffer.slice(0,Y);J+=2}return this.writeBuffer}_hasPingExpired(){if(!this._pingTimeoutTime)return!0;let Z=Date.now()>this._pingTimeoutTime;if(Z)this._pingTimeoutTime=0,T1(()=>{this._onClose("ping timeout")},this.setTimeoutFn);return Z}write(Z,J,Y){return this._sendPacket("message",Z,J,Y),this}send(Z,J,Y){return this._sendPacket("message",Z,J,Y),this}_sendPacket(Z,J,Y,G){if(typeof J==="function")G=J,J=void 0;if(typeof Y==="function")G=Y,Y=null;if(this.readyState==="closing"||this.readyState==="closed")return;Y=Y||{},Y.compress=Y.compress!==!1;let Q={type:Z,data:J,options:Y};if(this.emitReserved("packetCreate",Q),this.writeBuffer.push(Q),G)this.once("flush",G);this.flush()}close(){let Z=()=>{this._onClose("forced close"),this.transport.close()},J=()=>{this.off("upgrade",J),this.off("upgradeError",J),Z()},Y=()=>{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)Y();else Z()});else if(this.upgrading)Y();else Z();return this}_onError(Z){if(E1.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(),Z9){if(this._beforeunloadEventListener)removeEventListener("beforeunload",this._beforeunloadEventListener,!1);if(this._offlineEventListener){let Y=u5.indexOf(this._offlineEventListener);if(Y!==-1)u5.splice(Y,1)}}this.readyState="closed",this.id=null,this.emitReserved("close",Z,J),this.writeBuffer=[],this._prevBufferLen=0}}}E1.protocol=s8;class J9 extends E1{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),Y=!1;E1.priorWebsocketSuccess=!1;let G=()=>{if(Y)return;J.send([{type:"ping",data:"probe"}]),J.once("packet",(B)=>{if(Y)return;if(B.type==="pong"&&B.data==="probe"){if(this.upgrading=!0,this.emitReserved("upgrading",J),!J)return;E1.priorWebsocketSuccess=J.name==="websocket",this.transport.pause(()=>{if(Y)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 Q(){if(Y)return;Y=!0,U(),J.close(),J=null}let X=(B)=>{let L=Error("probe error: "+B);L.transport=J.name,Q(),this.emitReserved("upgradeError",L)};function W(){X("transport closed")}function H(){X("socket closed")}function z(B){if(J&&B.name!==J.name)Q()}let U=()=>{J.removeListener("open",G),J.removeListener("error",X),J.removeListener("close",W),this.off("close",H),this.off("upgrading",z)};if(J.once("open",G),J.once("error",X),J.once("close",W),this.once("close",H),this.once("upgrading",z),this._upgrades.indexOf("webtransport")!==-1&&Z!=="webtransport")this.setTimeoutFn(()=>{if(!Y)J.open()},200);else J.open()}onHandshake(Z){this._upgrades=this._filterUpgrades(Z.upgrades),super.onHandshake(Z)}_filterUpgrades(Z){let J=[];for(let Y=0;Y<Z.length;Y++)if(~this.transports.indexOf(Z[Y]))J.push(Z[Y]);return J}}class u0 extends J9{constructor(Z,J={}){let Y=typeof Z==="object"?Z:J;if(!Y.transports||Y.transports&&typeof Y.transports[0]==="string")Y.transports=(Y.transports||["polling","websocket","webtransport"]).map((G)=>e8[G]).filter((G)=>!!G);super(Z,Y)}}var eI=u0.protocol;function YY(Z,J="",Y){let G=Z;if(Y=Y||typeof location<"u"&&location,Z==null)Z=Y.protocol+"//"+Y.host;if(typeof Z==="string"){if(Z.charAt(0)==="/")if(Z.charAt(1)==="/")Z=Y.protocol+Z;else Z=Y.host+Z;if(!/^(https?|wss?):\/\//.test(Z))if(typeof Y<"u")Z=Y.protocol+"//"+Z;else Z="https://"+Z;G=V0(Z)}if(!G.port){if(/^(http|ws)$/.test(G.protocol))G.port="80";else if(/^(http|ws)s$/.test(G.protocol))G.port="443"}G.path=G.path||"/";let X=G.host.indexOf(":")!==-1?"["+G.host+"]":G.host;return G.id=G.protocol+"://"+X+":"+G.port+J,G.href=G.protocol+"://"+X+(Y&&Y.port===G.port?"":":"+G.port),G}var X9={};I7(X9,{protocol:()=>HY,isPacketValid:()=>uB,PacketType:()=>w,Encoder:()=>zY,Decoder:()=>Q9});var _B=typeof ArrayBuffer==="function",kB=(Z)=>{return typeof ArrayBuffer.isView==="function"?ArrayBuffer.isView(Z):Z.buffer instanceof ArrayBuffer},GY=Object.prototype.toString,vB=typeof Blob==="function"||typeof Blob<"u"&&GY.call(Blob)==="[object BlobConstructor]",hB=typeof File==="function"||typeof File<"u"&&GY.call(File)==="[object FileConstructor]";function c0(Z){return _B&&(Z instanceof ArrayBuffer||kB(Z))||vB&&Z instanceof Blob||hB&&Z instanceof File}function d0(Z,J){if(!Z||typeof Z!=="object")return!1;if(Array.isArray(Z)){for(let Y=0,G=Z.length;Y<G;Y++)if(d0(Z[Y]))return!0;return!1}if(c0(Z))return!0;if(Z.toJSON&&typeof Z.toJSON==="function"&&arguments.length===1)return d0(Z.toJSON(),!0);for(let Y in Z)if(Object.prototype.hasOwnProperty.call(Z,Y)&&d0(Z[Y]))return!0;return!1}function QY(Z){let J=[],Y=Z.data,G=Z;return G.data=Y9(Y,J),G.attachments=J.length,{packet:G,buffers:J}}function Y9(Z,J){if(!Z)return Z;if(c0(Z)){let Y={_placeholder:!0,num:J.length};return J.push(Z),Y}else if(Array.isArray(Z)){let Y=Array(Z.length);for(let G=0;G<Z.length;G++)Y[G]=Y9(Z[G],J);return Y}else if(typeof Z==="object"&&!(Z instanceof Date)){let Y={};for(let G in Z)if(Object.prototype.hasOwnProperty.call(Z,G))Y[G]=Y9(Z[G],J);return Y}return Z}function XY(Z,J){return Z.data=G9(Z.data,J),delete Z.attachments,Z}function G9(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 Y=0;Y<Z.length;Y++)Z[Y]=G9(Z[Y],J);else if(typeof Z==="object"){for(let Y in Z)if(Object.prototype.hasOwnProperty.call(Z,Y))Z[Y]=G9(Z[Y],J)}return Z}var WY=["connect","connect_error","disconnect","disconnecting","newListener","removeListener"],HY=5,w;(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"})(w||(w={}));class zY{constructor(Z){this.replacer=Z}encode(Z){if(Z.type===w.EVENT||Z.type===w.ACK){if(d0(Z))return this.encodeAsBinary({type:Z.type===w.EVENT?w.BINARY_EVENT:w.BINARY_ACK,nsp:Z.nsp,data:Z.data,id:Z.id})}return[this.encodeAsString(Z)]}encodeAsString(Z){let J=""+Z.type;if(Z.type===w.BINARY_EVENT||Z.type===w.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=QY(Z),Y=this.encodeAsString(J.packet),G=J.buffers;return G.unshift(Y),G}}class Q9 extends j{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 Y=J.type===w.BINARY_EVENT;if(Y||J.type===w.BINARY_ACK){if(J.type=Y?w.EVENT:w.ACK,this.reconstructor=new UY(J),J.attachments===0)super.emitReserved("decoded",J)}else super.emitReserved("decoded",J)}else if(c0(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,Y={type:Number(Z.charAt(0))};if(w[Y.type]===void 0)throw Error("unknown packet type "+Y.type);if(Y.type===w.BINARY_EVENT||Y.type===w.BINARY_ACK){let Q=J+1;while(Z.charAt(++J)!=="-"&&J!=Z.length);let X=Z.substring(Q,J);if(X!=Number(X)||Z.charAt(J)!=="-")throw Error("Illegal attachments");Y.attachments=Number(X)}if(Z.charAt(J+1)==="/"){let Q=J+1;while(++J){if(Z.charAt(J)===",")break;if(J===Z.length)break}Y.nsp=Z.substring(Q,J)}else Y.nsp="/";let G=Z.charAt(J+1);if(G!==""&&Number(G)==G){let Q=J+1;while(++J){let X=Z.charAt(J);if(X==null||Number(X)!=X){--J;break}if(J===Z.length)break}Y.id=Number(Z.substring(Q,J+1))}if(Z.charAt(++J)){let Q=this.tryParse(Z.substr(J));if(Q9.isPayloadValid(Y.type,Q))Y.data=Q;else throw Error("invalid payload")}return Y}tryParse(Z){try{return JSON.parse(Z,this.reviver)}catch(J){return!1}}static isPayloadValid(Z,J){switch(Z){case w.CONNECT:return d5(J);case w.DISCONNECT:return J===void 0;case w.CONNECT_ERROR:return typeof J==="string"||d5(J);case w.EVENT:case w.BINARY_EVENT:return Array.isArray(J)&&(typeof J[0]==="number"||typeof J[0]==="string"&&WY.indexOf(J[0])===-1);case w.ACK:case w.BINARY_ACK:return Array.isArray(J)}}destroy(){if(this.reconstructor)this.reconstructor.finishedReconstruction(),this.reconstructor=null}}class UY{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=XY(this.reconPack,this.buffers);return this.finishedReconstruction(),J}return null}finishedReconstruction(){this.reconPack=null,this.buffers=[]}}function bB(Z){return typeof Z==="string"}var yB=Number.isInteger||function(Z){return typeof Z==="number"&&isFinite(Z)&&Math.floor(Z)===Z};function gB(Z){return Z===void 0||yB(Z)}function d5(Z){return Object.prototype.toString.call(Z)==="[object Object]"}function mB(Z,J){switch(Z){case w.CONNECT:return J===void 0||d5(J);case w.DISCONNECT:return J===void 0;case w.EVENT:return Array.isArray(J)&&(typeof J[0]==="number"||typeof J[0]==="string"&&WY.indexOf(J[0])===-1);case w.ACK:return Array.isArray(J);case w.CONNECT_ERROR:return typeof J==="string"||d5(J);default:return!1}}function uB(Z){return bB(Z.nsp)&&gB(Z.id)&&mB(Z.type,Z.data)}function Q1(Z,J,Y){return Z.on(J,Y),function(){Z.off(J,Y)}}var dB=Object.freeze({connect:1,connect_error:1,disconnect:1,disconnecting:1,newListener:1,removeListener:1});class p0 extends j{constructor(Z,J,Y){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,Y&&Y.auth)this.auth=Y.auth;if(this._opts=Object.assign({},Y),this.io._autoConnect)this.open()}get disconnected(){return!this.connected}subEvents(){if(this.subs)return;let Z=this.io;this.subs=[Q1(Z,"open",this.onopen.bind(this)),Q1(Z,"packet",this.onpacket.bind(this)),Q1(Z,"error",this.onerror.bind(this)),Q1(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 Y,G,Q;if(dB.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 X={type:w.EVENT,data:J};if(X.options={},X.options.compress=this.flags.compress!==!1,typeof J[J.length-1]==="function"){let U=this.ids++,B=J.pop();this._registerAckCallback(U,B),X.id=U}let W=(G=(Y=this.io.engine)===null||Y===void 0?void 0:Y.transport)===null||G===void 0?void 0:G.writable,H=this.connected&&!((Q=this.io.engine)===null||Q===void 0?void 0:Q._hasPingExpired());if(this.flags.volatile&&!W);else if(H)this.notifyOutgoingListeners(X),this.packet(X);else this.sendBuffer.push(X);return this.flags={},this}_registerAckCallback(Z,J){var Y;let G=(Y=this.flags.timeout)!==null&&Y!==void 0?Y:this._opts.ackTimeout;if(G===void 0){this.acks[Z]=J;return}let Q=this.io.setTimeoutFn(()=>{delete this.acks[Z];for(let W=0;W<this.sendBuffer.length;W++)if(this.sendBuffer[W].id===Z)this.sendBuffer.splice(W,1);J.call(this,Error("operation has timed out"))},G),X=(...W)=>{this.io.clearTimeoutFn(Q),J.apply(this,W)};X.withError=!0,this.acks[Z]=X}emitWithAck(Z,...J){return new Promise((Y,G)=>{let Q=(X,W)=>{return X?G(X):Y(W)};Q.withError=!0,J.push(Q),this.emit(Z,...J)})}_addToQueue(Z){let J;if(typeof Z[Z.length-1]==="function")J=Z.pop();let Y={id:this._queueSeq++,tryCount:0,pending:!1,args:Z,flags:Object.assign({fromQueue:!0},this.flags)};Z.push((G,...Q)=>{if(Y!==this._queue[0]);if(G!==null){if(Y.tryCount>this._opts.retries){if(this._queue.shift(),J)J(G)}}else if(this._queue.shift(),J)J(null,...Q);return Y.pending=!1,this._drainQueue()}),this._queue.push(Y),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:w.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((Y)=>String(Y.id)===Z)){let Y=this.acks[Z];if(delete this.acks[Z],Y.withError)Y.call(this,Error("socket has been disconnected"))}})}onpacket(Z){if(Z.nsp!==this.nsp)return;switch(Z.type){case w.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 w.EVENT:case w.BINARY_EVENT:this.onevent(Z);break;case w.ACK:case w.BINARY_ACK:this.onack(Z);break;case w.DISCONNECT:this.ondisconnect();break;case w.CONNECT_ERROR:this.destroy();let Y=Error(Z.data.message);Y.data=Z.data.data,this.emitReserved("connect_error",Y);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 Y of J)Y.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,Y=!1;return function(...G){if(Y)return;Y=!0,J.packet({type:w.ACK,id:Z,data:G})}}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:w.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 Y=0;Y<J.length;Y++)if(Z===J[Y])return J.splice(Y,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 Y=0;Y<J.length;Y++)if(Z===J[Y])return J.splice(Y,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 Y of J)Y.apply(this,Z.data)}}}function J0(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}J0.prototype.duration=function(){var Z=this.ms*Math.pow(this.factor,this.attempts++);if(this.jitter){var J=Math.random(),Y=Math.floor(J*this.jitter*Z);Z=(Math.floor(J*10)&1)==0?Z-Y:Z+Y}return Math.min(Z,this.max)|0};J0.prototype.reset=function(){this.attempts=0};J0.prototype.setMin=function(Z){this.ms=Z};J0.prototype.setMax=function(Z){this.max=Z};J0.prototype.setJitter=function(Z){this.jitter=Z};class l0 extends j{constructor(Z,J){var Y;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,w1(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((Y=J.randomizationFactor)!==null&&Y!==void 0?Y:0.5),this.backoff=new J0({min:this.reconnectionDelay(),max:this.reconnectionDelayMax(),jitter:this.randomizationFactor()}),this.timeout(J.timeout==null?20000:J.timeout),this._readyState="closed",this.uri=Z;let G=J.parser||X9;if(this.encoder=new G.Encoder,this.decoder=new G.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 u0(this.uri,this.opts);let J=this.engine,Y=this;this._readyState="opening",this.skipReconnect=!1;let G=Q1(J,"open",function(){Y.onopen(),Z&&Z()}),Q=(W)=>{if(this.cleanup(),this._readyState="closed",this.emitReserved("error",W),Z)Z(W);else this.maybeReconnectOnOpen()},X=Q1(J,"error",Q);if(this._timeout!==!1){let W=this._timeout,H=this.setTimeoutFn(()=>{G(),Q(Error("timeout")),J.close()},W);if(this.opts.autoUnref)H.unref();this.subs.push(()=>{this.clearTimeoutFn(H)})}return this.subs.push(G),this.subs.push(X),this}connect(Z){return this.open(Z)}onopen(){this.cleanup(),this._readyState="open",this.emitReserved("open");let Z=this.engine;this.subs.push(Q1(Z,"ping",this.onping.bind(this)),Q1(Z,"data",this.ondata.bind(this)),Q1(Z,"error",this.onerror.bind(this)),Q1(Z,"close",this.onclose.bind(this)),Q1(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){T1(()=>{this.emitReserved("packet",Z)},this.setTimeoutFn)}onerror(Z){this.emitReserved("error",Z)}socket(Z,J){let Y=this.nsps[Z];if(!Y)Y=new p0(this,Z,J),this.nsps[Z]=Y;else if(this._autoConnect&&!Y.active)Y.connect();return Y}_destroy(Z){let J=Object.keys(this.nsps);for(let Y of J)if(this.nsps[Y].active)return;this._close()}_packet(Z){let J=this.encoder.encode(Z);for(let Y=0;Y<J.length;Y++)this.engine.write(J[Y],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 Y;if(this.cleanup(),(Y=this.engine)===null||Y===void 0||Y.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 Y=this.setTimeoutFn(()=>{if(Z.skipReconnect)return;if(this.emitReserved("reconnect_attempt",Z.backoff.attempts),Z.skipReconnect)return;Z.open((G)=>{if(G)Z._reconnecting=!1,Z.reconnect(),this.emitReserved("reconnect_error",G);else Z.onreconnect()})},J);if(this.opts.autoUnref)Y.unref();this.subs.push(()=>{this.clearTimeoutFn(Y)})}}onreconnect(){let Z=this.backoff.attempts;this._reconnecting=!1,this.backoff.reset(),this.emitReserved("reconnect",Z)}}var i0={};function n0(Z,J){if(typeof Z==="object")J=Z,Z=void 0;J=J||{};let Y=YY(Z,J.path||"/socket.io"),G=Y.source,Q=Y.id,X=Y.path,W=i0[Q]&&X in i0[Q].nsps,H=J.forceNew||J["force new connection"]||J.multiplex===!1||W,z;if(H)z=new l0(G,J);else{if(!i0[Q])i0[Q]=new l0(G,J);z=i0[Q]}if(Y.query&&!J.query)J.query=Y.queryKey;return z.socket(Y.path,J)}Object.assign(n0,{Manager:l0,Socket:p0,io:n0,connect:n0});import{createContext as cB}from"react";var c5=(Z)=>n0(Z,{autoConnect:!1,transports:["websocket"]}),pB=cB(null),d1=pB;import{createContext as HK}from"react";function i(Z,J,Y,G){function Q(X){return X instanceof Y?X:new Y(function(W){W(X)})}return new(Y||(Y=Promise))(function(X,W){function H(B){try{U(G.next(B))}catch(L){W(L)}}function z(B){try{U(G.throw(B))}catch(L){W(L)}}function U(B){B.done?X(B.value):Q(B.value).then(H,z)}U((G=G.apply(Z,J||[])).next())})}function lB(Z){return Z&&Z.__esModule&&Object.prototype.hasOwnProperty.call(Z,"default")?Z.default:Z}var U9={exports:{}},I0=typeof Reflect==="object"?Reflect:null,BY=I0&&typeof I0.apply==="function"?I0.apply:function(J,Y,G){return Function.prototype.apply.call(J,Y,G)},p5;if(I0&&typeof I0.ownKeys==="function")p5=I0.ownKeys;else if(Object.getOwnPropertySymbols)p5=function(J){return Object.getOwnPropertyNames(J).concat(Object.getOwnPropertySymbols(J))};else p5=function(J){return Object.getOwnPropertyNames(J)};function iB(Z){if(console&&console.warn)console.warn(Z)}var LY=Number.isNaN||function(J){return J!==J};function C(){C.init.call(this)}U9.exports=C;U9.exports.once=sB;C.EventEmitter=C;C.prototype._events=void 0;C.prototype._eventsCount=0;C.prototype._maxListeners=void 0;var KY=10;function a5(Z){if(typeof Z!=="function")throw TypeError('The "listener" argument must be of type Function. Received type '+typeof Z)}Object.defineProperty(C,"defaultMaxListeners",{enumerable:!0,get:function(){return KY},set:function(Z){if(typeof Z!=="number"||Z<0||LY(Z))throw RangeError('The value of "defaultMaxListeners" is out of range. It must be a non-negative number. Received '+Z+".");KY=Z}});C.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};C.prototype.setMaxListeners=function(J){if(typeof J!=="number"||J<0||LY(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 MY(Z){if(Z._maxListeners===void 0)return C.defaultMaxListeners;return Z._maxListeners}C.prototype.getMaxListeners=function(){return MY(this)};C.prototype.emit=function(J){var Y=[];for(var G=1;G<arguments.length;G++)Y.push(arguments[G]);var Q=J==="error",X=this._events;if(X!==void 0)Q=Q&&X.error===void 0;else if(!Q)return!1;if(Q){var W;if(Y.length>0)W=Y[0];if(W instanceof Error)throw W;var H=Error("Unhandled error."+(W?" ("+W.message+")":""));throw H.context=W,H}var z=X[J];if(z===void 0)return!1;if(typeof z==="function")BY(z,this,Y);else{var U=z.length,B=IY(z,U);for(var G=0;G<U;++G)BY(B[G],this,Y)}return!0};function $Y(Z,J,Y,G){var Q,X,W;if(a5(Y),X=Z._events,X===void 0)X=Z._events=Object.create(null),Z._eventsCount=0;else{if(X.newListener!==void 0)Z.emit("newListener",J,Y.listener?Y.listener:Y),X=Z._events;W=X[J]}if(W===void 0)W=X[J]=Y,++Z._eventsCount;else{if(typeof W==="function")W=X[J]=G?[Y,W]:[W,Y];else if(G)W.unshift(Y);else W.push(Y);if(Q=MY(Z),Q>0&&W.length>Q&&!W.warned){W.warned=!0;var H=Error("Possible EventEmitter memory leak detected. "+W.length+" "+String(J)+" listeners added. Use emitter.setMaxListeners() to increase limit");H.name="MaxListenersExceededWarning",H.emitter=Z,H.type=J,H.count=W.length,iB(H)}}return Z}C.prototype.addListener=function(J,Y){return $Y(this,J,Y,!1)};C.prototype.on=C.prototype.addListener;C.prototype.prependListener=function(J,Y){return $Y(this,J,Y,!0)};function nB(){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 FY(Z,J,Y){var G={fired:!1,wrapFn:void 0,target:Z,type:J,listener:Y},Q=nB.bind(G);return Q.listener=Y,G.wrapFn=Q,Q}C.prototype.once=function(J,Y){return a5(Y),this.on(J,FY(this,J,Y)),this};C.prototype.prependOnceListener=function(J,Y){return a5(Y),this.prependListener(J,FY(this,J,Y)),this};C.prototype.removeListener=function(J,Y){var G,Q,X,W,H;if(a5(Y),Q=this._events,Q===void 0)return this;if(G=Q[J],G===void 0)return this;if(G===Y||G.listener===Y){if(--this._eventsCount===0)this._events=Object.create(null);else if(delete Q[J],Q.removeListener)this.emit("removeListener",J,G.listener||Y)}else if(typeof G!=="function"){X=-1;for(W=G.length-1;W>=0;W--)if(G[W]===Y||G[W].listener===Y){H=G[W].listener,X=W;break}if(X<0)return this;if(X===0)G.shift();else oB(G,X);if(G.length===1)Q[J]=G[0];if(Q.removeListener!==void 0)this.emit("removeListener",J,H||Y)}return this};C.prototype.off=C.prototype.removeListener;C.prototype.removeAllListeners=function(J){var Y,G,Q;if(G=this._events,G===void 0)return this;if(G.removeListener===void 0){if(arguments.length===0)this._events=Object.create(null),this._eventsCount=0;else if(G[J]!==void 0)if(--this._eventsCount===0)this._events=Object.create(null);else delete G[J];return this}if(arguments.length===0){var X=Object.keys(G),W;for(Q=0;Q<X.length;++Q){if(W=X[Q],W==="removeListener")continue;this.removeAllListeners(W)}return this.removeAllListeners("removeListener"),this._events=Object.create(null),this._eventsCount=0,this}if(Y=G[J],typeof Y==="function")this.removeListener(J,Y);else if(Y!==void 0)for(Q=Y.length-1;Q>=0;Q--)this.removeListener(J,Y[Q]);return this};function OY(Z,J,Y){var G=Z._events;if(G===void 0)return[];var Q=G[J];if(Q===void 0)return[];if(typeof Q==="function")return Y?[Q.listener||Q]:[Q];return Y?aB(Q):IY(Q,Q.length)}C.prototype.listeners=function(J){return OY(this,J,!0)};C.prototype.rawListeners=function(J){return OY(this,J,!1)};C.listenerCount=function(Z,J){if(typeof Z.listenerCount==="function")return Z.listenerCount(J);else return VY.call(Z,J)};C.prototype.listenerCount=VY;function VY(Z){var J=this._events;if(J!==void 0){var Y=J[Z];if(typeof Y==="function")return 1;else if(Y!==void 0)return Y.length}return 0}C.prototype.eventNames=function(){return this._eventsCount>0?p5(this._events):[]};function IY(Z,J){var Y=Array(J);for(var G=0;G<J;++G)Y[G]=Z[G];return Y}function oB(Z,J){for(;J+1<Z.length;J++)Z[J]=Z[J+1];Z.pop()}function aB(Z){var J=Array(Z.length);for(var Y=0;Y<J.length;++Y)J[Y]=Z[Y].listener||Z[Y];return J}function sB(Z,J){return new Promise(function(Y,G){function Q(W){Z.removeListener(J,X),G(W)}function X(){if(typeof Z.removeListener==="function")Z.removeListener("error",Q);Y([].slice.call(arguments))}if(qY(Z,J,X,{once:!0}),J!=="error")rB(Z,Q,{once:!0})})}function rB(Z,J,Y){if(typeof Z.on==="function")qY(Z,"error",J,Y)}function qY(Z,J,Y,G){if(typeof Z.on==="function")if(G.once)Z.once(J,Y);else Z.on(J,Y);else if(typeof Z.addEventListener==="function")Z.addEventListener(J,function Q(X){if(G.once)Z.removeEventListener(J,Q);Y(X)});else throw TypeError('The "emitter" argument must be of type EventEmitter. Received type '+typeof Z)}var tB=U9.exports,DY=lB(tB),_;(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"})(_||(_={}));var c1;(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"})(c1||(c1={}));var o0;(function(Z){Z[Z.disconnectCalled=0]="disconnectCalled",Z[Z.unauthorized=1]="unauthorized",Z[Z.badProtocol=2]="badProtocol",Z[Z.messageSizeLimit=3]="messageSizeLimit"})(o0||(o0={}));var l5;(function(Z){Z[Z.subscribeCalled=0]="subscribeCalled",Z[Z.transportClosed=1]="transportClosed"})(l5||(l5={}));var i5;(function(Z){Z[Z.unsubscribeCalled=0]="unsubscribeCalled",Z[Z.unauthorized=1]="unauthorized",Z[Z.clientClosed=2]="clientClosed"})(i5||(i5={}));var W9;(function(Z){Z[Z.channelCompaction=1]="channelCompaction"})(W9||(W9={}));var h;(function(Z){Z.Disconnected="disconnected",Z.Connecting="connecting",Z.Connected="connected"})(h||(h={}));var a;(function(Z){Z.Unsubscribed="unsubscribed",Z.Subscribing="subscribing",Z.Subscribed="subscribed"})(a||(a={}));function eB(Z,J){return Z.lastIndexOf(J,0)===0}function NY(Z){if(Z===void 0||Z===null)return!1;return typeof Z==="function"}function ZK(Z,J){if(globalThis.console){let Y=globalThis.console[Z];if(NY(Y))Y.apply(globalThis.console,J)}}function JK(Z,J){return Math.floor(Math.random()*(J-Z+1)+Z)}function n5(Z,J,Y){if(Z>31)Z=31;let G=JK(0,Math.min(Y,J*Math.pow(2,Z)));return Math.min(Y,J+G)}function YK(Z){return"error"in Z&&Z.error!==null}function o5(Z){return Math.min(Z*1000,2147483647)}class AY extends DY{constructor(Z,J,Y){super();if(this._resubscribeTimeout=null,this._refreshTimeout=null,this.channel=J,this.state=a.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(Y),this._centrifuge._debugEnabled)this.on("state",(G)=>{this._debug("subscription state",J,G.oldState,"->",G.newState)}),this.on("error",(G)=>{this._debug("subscription error",J,G)});else this.on("error",function(){Function.prototype()})}ready(Z){if(this.state===a.Unsubscribed)return Promise.reject({code:_.subscriptionUnsubscribed,message:this.state});if(this.state===a.Subscribed)return Promise.resolve();return new Promise((J,Y)=>{let G={resolve:J,reject:Y};if(Z)G.timeout=setTimeout(function(){Y({code:_.timeout,message:"timeout"})},Z);this._promises[this._nextPromiseId()]=G})}subscribe(){if(this._isSubscribed())return;this._resubscribeAttempts=0,this._setSubscribing(l5.subscribeCalled,"subscribe called")}unsubscribe(){this._unsubPromise=this._setUnsubscribed(i5.unsubscribeCalled,"unsubscribe called",!0)}publish(Z){return i(this,void 0,void 0,function*(){return yield this._methodCall(),this._centrifuge.publish(this.channel,Z)})}presence(){return i(this,void 0,void 0,function*(){return yield this._methodCall(),this._centrifuge.presence(this.channel)})}presenceStats(){return i(this,void 0,void 0,function*(){return yield this._methodCall(),this._centrifuge.presenceStats(this.channel)})}history(Z){return i(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:_.subscriptionUnsubscribed,message:this.state});return new Promise((Z,J)=>{let Y=this._centrifuge._config.timeout,G=setTimeout(()=>{J({code:_.timeout,message:"timeout"})},Y);this._promises[this._nextPromiseId()]={timeout:G,resolve:Z,reject:J}})}_nextPromiseId(){return++this._promiseId}_needRecover(){return this._recover===!0}_isUnsubscribed(){return this.state===a.Unsubscribed}_isSubscribing(){return this.state===a.Subscribing}_isSubscribed(){return this.state===a.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(a.Subscribed);let J=this._centrifuge._getSubscribeContext(this.channel,Z);this.emit("subscribed",J),this._resolvePromises();let Y=Z.publications;if(Y&&Y.length>0)for(let G in Y){if(!Y.hasOwnProperty(G))continue;this._handlePublication(Y[G])}if(Z.expires===!0)this._refreshTimeout=setTimeout(()=>this._refresh(),o5(Z.ttl))}_setSubscribing(Z,J){return i(this,void 0,void 0,function*(){if(this._isSubscribing())return;if(this._isSubscribed())this._clearSubscribedState();if(this._setState(a.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 I1){this._inflight=!1,this._failUnauthorized();return}this.emit("error",{type:"subscribeData",channel:this.channel,error:{code:_.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 I1){this._inflight=!1,this._failUnauthorized();return}this.emit("error",{type:"subscribeToken",channel:this.channel,error:{code:_.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((Y)=>{this._inflight=!1;let G=Y.reply.subscribe;if(this._handleSubscribeResponse(G),Y.next)Y.next()},(Y)=>{if(this._inflight=!1,this._handleSubscribeError(Y.error),Y.next)Y.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=W9.channelCompaction,this._needRecover()){J.recover=!0;let Y=this._getOffset();if(Y)J.offset=Y;let G=this._getEpoch();if(G)J.epoch=G}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===_.timeout){this._centrifuge._disconnect(c1.subscribeTimeout,"subscribe timeout",!0);return}this._subscribeError(Z)}_handleSubscribeResponse(Z){if(!this._isSubscribing())return;this._setSubscribed(Z)}_setUnsubscribed(Z,J,Y){if(this._isUnsubscribed())return Promise.resolve();let G=Promise.resolve();if(this._isSubscribed()){if(Y)G=this._centrifuge._unsubscribe(this);this._clearSubscribedState()}else if(this._isSubscribing()){if(this._inflight&&Y)G=this._centrifuge._unsubscribe(this);this._clearSubscribingState()}if(this._inflight=!1,this._setState(a.Unsubscribed))this.emit("unsubscribed",{channel:this.channel,code:Z,reason:J});return this._rejectPromises({code:_.subscriptionUnsubscribed,message:this.state}),G}_handlePublication(Z){if(this._delta&&this._delta_negotiated){let{newData:Y,newPrevValue:G}=this._centrifuge._codec.applyDeltaIfNeeded(Z,this._prevValue);Z.data=Y,this._prevValue=G}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===h.Connected)this.emit("error",J);this._scheduleResubscribe()}else this._setUnsubscribed(Z.code,Z.message,!1)}_getResubscribeDelay(){let Z=n5(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:_.badConfiguration,message:"provide a function to get channel subscription token"}}),Promise.reject(new I1(""));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 G={sub_refresh:{channel:Z.channel,token:J}};Z._centrifuge._call(G).then((Q)=>{let X=Q.reply.sub_refresh;if(Z._refreshResponse(X),Q.next)Q.next()},(Q)=>{if(Z._refreshError(Q.error),Q.next)Q.next()})}).catch(function(J){if(J instanceof I1){Z._failUnauthorized();return}Z.emit("error",{type:"refreshToken",channel:Z.channel,error:{code:_.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(),o5(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 n5(0,1e4,20000)}_failUnauthorized(){this._setUnsubscribed(i5.unauthorized,"unauthorized",!0)}}class RY{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=(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 H9{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 Y="";if(Z==="protobuf")Y="centrifuge-protobuf";if(Y!=="")this._transport=new this.options.websocket(this.endpoint,Y);else this._transport=new this.options.websocket(this.endpoint);if(Z==="protobuf")this._transport.binaryType="arraybuffer";this._transport.onopen=()=>{J.onOpen()},this._transport.onerror=(G)=>{J.onError(G)},this._transport.onclose=(G)=>{J.onClose(G)},this._transport.onmessage=(G)=>{J.onMessage(G.data)}}close(){this._transport.close()}send(Z){this._transport.send(Z)}}class PY{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,Y){let G=new EventTarget,Q=Z.options.fetch;return Q(J,Y).then(Z._handleErrors).then((X)=>{G.dispatchEvent(new Event("open"));let W="",H=0,z=new Uint8Array,U=X.body.getReader();return new Z.options.readableStream({start(B){function L(){return U.read().then(({done:F,value:M})=>{if(F){G.dispatchEvent(new Event("close")),B.close();return}try{if(Z._protocol==="json"){W+=Z._utf8decoder.decode(M);while(H<W.length)if(W[H]===`
|
|
23
|
-
`){let K=W.substring(0,H);G.dispatchEvent(new MessageEvent("message",{data:K})),W=W.substring(H+1),H=0}else++H}else{let K=new Uint8Array(z.length+M.length);K.set(z),K.set(M,z.length),z=K;while(!0){let $=Z.options.decoder.decodeReply(z);if($.ok){let
|
|
24
|
-
`){let H=Y.substring(0,G);Z.dispatchEvent(new MessageEvent("message",{data:H})),Y=Y.substring(G+1),G=0}else++G}else{let H=new Uint8Array(Q.length+W.length);H.set(Q),H.set(W,Q.length),Q=H;while(!0){let z=this.options.decoder.decodeReply(Q);if(z.ok){let U=Q.slice(0,z.pos);Z.dispatchEvent(new MessageEvent("message",{data:U})),Q=Q.slice(z.pos);continue}break}}if(X)break}}catch(X){Z.dispatchEvent(new Event("close"))}})}close(){return
|
|
25
|
-
`);else J=Z;try{yield this._writer.write(J)}catch(Y){this.close()}})}}var
|
|
26
|
-
`)throw Error("size integer not terminated by '\\n'");let H=new
|
|
22
|
+
`;return{css:H,animationName:W}}}}function V0(Z){return F0(Z)}V0.Plugins=K1;V0.Style=fJ;V0.StyleRoot=_J;V0.getState=T5;V0.keyframes=i8;var n=V0;function n8(Z){return{all:Z=Z||new Map,on:function(J,Y){var G=Z.get(J);G?G.push(Y):Z.set(J,[Y])},off:function(J,Y){var G=Z.get(J);G&&(Y?G.splice(G.indexOf(Y)>>>0,1):Z.set(J,[]))},emit:function(J,Y){var G=Z.get(J);G&&G.slice().map(function(Q){Q(Y)}),(G=Z.get("*"))&&G.slice().map(function(Q){Q(J,Y)})}}}import{createContext as qB}from"react";var v0=n8(),DB=qB(v0),u1=DB;var $1=Object.create(null);$1.open="0";$1.close="1";$1.ping="2";$1.pong="3";$1.message="4";$1.upgrade="5";$1.noop="6";var h0=Object.create(null);Object.keys($1).forEach((Z)=>{h0[$1[Z]]=Z});var b0={type:"error",data:"parser error"};var hJ=typeof Blob==="function"||typeof Blob<"u"&&Object.prototype.toString.call(Blob)==="[object BlobConstructor]",bJ=typeof ArrayBuffer==="function",gJ=(Z)=>{return typeof ArrayBuffer.isView==="function"?ArrayBuffer.isView(Z):Z&&Z.buffer instanceof ArrayBuffer},g0=({type:Z,data:J},Y,G)=>{if(hJ&&J instanceof Blob)if(Y)return G(J);else return kJ(J,G);else if(bJ&&(J instanceof ArrayBuffer||gJ(J)))if(Y)return G(J);else return kJ(new Blob([J]),G);return G($1[Z]+(J||""))},kJ=(Z,J)=>{let Y=new FileReader;return Y.onload=function(){let G=Y.result.split(",")[1];J("b"+(G||""))},Y.readAsDataURL(Z)};function vJ(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 o8;function yJ(Z,J){if(hJ&&Z.data instanceof Blob)return Z.data.arrayBuffer().then(vJ).then(J);else if(bJ&&(Z.data instanceof ArrayBuffer||gJ(Z.data)))return J(vJ(Z.data));g0(Z,!1,(Y)=>{if(!o8)o8=new TextEncoder;J(o8.encode(Y))})}var y0=typeof Uint8Array>"u"?[]:new Uint8Array(256);for(let Z=0;Z<64;Z++)y0["ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/".charCodeAt(Z)]=Z;var mJ=(Z)=>{let J=Z.length*0.75,Y=Z.length,G,Q=0,X,W,H,z;if(Z[Z.length-1]==="="){if(J--,Z[Z.length-2]==="=")J--}let U=new ArrayBuffer(J),B=new Uint8Array(U);for(G=0;G<Y;G+=4)X=y0[Z.charCodeAt(G)],W=y0[Z.charCodeAt(G+1)],H=y0[Z.charCodeAt(G+2)],z=y0[Z.charCodeAt(G+3)],B[Q++]=X<<2|W>>4,B[Q++]=(W&15)<<4|H>>2,B[Q++]=(H&3)<<6|z&63;return U};var NB=typeof ArrayBuffer==="function",m0=(Z,J)=>{if(typeof Z!=="string")return{type:"message",data:uJ(Z,J)};let Y=Z.charAt(0);if(Y==="b")return{type:"message",data:AB(Z.substring(1),J)};if(!h0[Y])return b0;return Z.length>1?{type:h0[Y],data:Z.substring(1)}:{type:h0[Y]}},AB=(Z,J)=>{if(NB){let Y=mJ(Z);return uJ(Y,J)}else return{base64:!0,data:Z}},uJ=(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 dJ=String.fromCharCode(30),cJ=(Z,J)=>{let Y=Z.length,G=Array(Y),Q=0;Z.forEach((X,W)=>{g0(X,!1,(H)=>{if(G[W]=H,++Q===Y)J(G.join(dJ))})})},pJ=(Z,J)=>{let Y=Z.split(dJ),G=[];for(let Q=0;Q<Y.length;Q++){let X=m0(Y[Q],J);if(G.push(X),X.type==="error")break}return G};function lJ(){return new TransformStream({transform(Z,J){yJ(Z,(Y)=>{let G=Y.length,Q;if(G<126)Q=new Uint8Array(1),new DataView(Q.buffer).setUint8(0,G);else if(G<65536){Q=new Uint8Array(3);let X=new DataView(Q.buffer);X.setUint8(0,126),X.setUint16(1,G)}else{Q=new Uint8Array(9);let X=new DataView(Q.buffer);X.setUint8(0,127),X.setBigUint64(1,BigInt(G))}if(Z.data&&typeof Z.data!=="string")Q[0]|=128;J.enqueue(Q),J.enqueue(Y)})}})}var a8;function b5(Z){return Z.reduce((J,Y)=>J+Y.length,0)}function g5(Z,J){if(Z[0].length===J)return Z.shift();let Y=new Uint8Array(J),G=0;for(let Q=0;Q<J;Q++)if(Y[Q]=Z[0][G++],G===Z[0].length)Z.shift(),G=0;if(Z.length&&G<Z[0].length)Z[0]=Z[0].slice(G);return Y}function iJ(Z,J){if(!a8)a8=new TextDecoder;let Y=[],G=0,Q=-1,X=!1;return new TransformStream({transform(W,H){Y.push(W);while(!0){if(G===0){if(b5(Y)<1)break;let z=g5(Y,1);if(X=(z[0]&128)===128,Q=z[0]&127,Q<126)G=3;else if(Q===126)G=1;else G=2}else if(G===1){if(b5(Y)<2)break;let z=g5(Y,2);Q=new DataView(z.buffer,z.byteOffset,z.length).getUint16(0),G=3}else if(G===2){if(b5(Y)<8)break;let z=g5(Y,8),U=new DataView(z.buffer,z.byteOffset,z.length),B=U.getUint32(0);if(B>Math.pow(2,21)-1){H.enqueue(b0);break}Q=B*Math.pow(2,32)+U.getUint32(4),G=3}else{if(b5(Y)<Q)break;let z=g5(Y,Q);H.enqueue(m0(X?z:a8.decode(z),J)),G=0}if(Q===0||Q>Z){H.enqueue(b0);break}}}})}var s8=4;function j(Z){if(Z)return RB(Z)}function RB(Z){for(var J in j.prototype)Z[J]=j.prototype[J];return Z}j.prototype.on=j.prototype.addEventListener=function(Z,J){return this._callbacks=this._callbacks||{},(this._callbacks["$"+Z]=this._callbacks["$"+Z]||[]).push(J),this};j.prototype.once=function(Z,J){function Y(){this.off(Z,Y),J.apply(this,arguments)}return Y.fn=J,this.on(Z,Y),this};j.prototype.off=j.prototype.removeListener=j.prototype.removeAllListeners=j.prototype.removeEventListener=function(Z,J){if(this._callbacks=this._callbacks||{},arguments.length==0)return this._callbacks={},this;var Y=this._callbacks["$"+Z];if(!Y)return this;if(arguments.length==1)return delete this._callbacks["$"+Z],this;var G;for(var Q=0;Q<Y.length;Q++)if(G=Y[Q],G===J||G.fn===J){Y.splice(Q,1);break}if(Y.length===0)delete this._callbacks["$"+Z];return this};j.prototype.emit=function(Z){this._callbacks=this._callbacks||{};var J=Array(arguments.length-1),Y=this._callbacks["$"+Z];for(var G=1;G<arguments.length;G++)J[G-1]=arguments[G];if(Y){Y=Y.slice(0);for(var G=0,Q=Y.length;G<Q;++G)Y[G].apply(this,J)}return this};j.prototype.emitReserved=j.prototype.emit;j.prototype.listeners=function(Z){return this._callbacks=this._callbacks||{},this._callbacks["$"+Z]||[]};j.prototype.hasListeners=function(Z){return!!this.listeners(Z).length};var w1=(()=>{if(typeof Promise==="function"&&typeof Promise.resolve==="function")return(J)=>Promise.resolve().then(J);else return(J,Y)=>Y(J,0)})(),s=(()=>{if(typeof self<"u")return self;else if(typeof window<"u")return window;else return Function("return this")()})(),nJ="arraybuffer";function oJ(){}function y5(Z,...J){return J.reduce((Y,G)=>{if(Z.hasOwnProperty(G))Y[G]=Z[G];return Y},{})}var PB=s.setTimeout,TB=s.clearTimeout;function E1(Z,J){if(J.useNativeTimers)Z.setTimeoutFn=PB.bind(s),Z.clearTimeoutFn=TB.bind(s);else Z.setTimeoutFn=s.setTimeout.bind(s),Z.clearTimeoutFn=s.clearTimeout.bind(s)}var wB=1.33;function aJ(Z){if(typeof Z==="string")return EB(Z);return Math.ceil((Z.byteLength||Z.size)*wB)}function EB(Z){let J=0,Y=0;for(let G=0,Q=Z.length;G<Q;G++)if(J=Z.charCodeAt(G),J<128)Y+=1;else if(J<2048)Y+=2;else if(J<55296||J>=57344)Y+=3;else G++,Y+=4;return Y}function m5(){return Date.now().toString(36).substring(3)+Math.random().toString(36).substring(2,5)}function sJ(Z){let J="";for(let Y in Z)if(Z.hasOwnProperty(Y)){if(J.length)J+="&";J+=encodeURIComponent(Y)+"="+encodeURIComponent(Z[Y])}return J}function rJ(Z){let J={},Y=Z.split("&");for(let G=0,Q=Y.length;G<Q;G++){let X=Y[G].split("=");J[decodeURIComponent(X[0])]=decodeURIComponent(X[1])}return J}class r8 extends Error{constructor(Z,J,Y){super(Z);this.description=J,this.context=Y,this.type="TransportError"}}class d1 extends j{constructor(Z){super();this.writable=!1,E1(this,Z),this.opts=Z,this.query=Z.query,this.socket=Z.socket,this.supportsBinary=!Z.forceBase64}onError(Z,J,Y){return super.emitReserved("error",new r8(Z,J,Y)),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=m0(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=sJ(Z);return J.length?"?"+J:""}}class u5 extends d1{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 Y=0;if(this._polling)Y++,this.once("pollComplete",function(){--Y||J()});if(!this.writable)Y++,this.once("drain",function(){--Y||J()})}else J()}_poll(){this._polling=!0,this.doPoll(),this.emitReserved("poll")}onData(Z){let J=(Y)=>{if(this.readyState==="opening"&&Y.type==="open")this.onOpen();if(Y.type==="close")return this.onClose({description:"transport closed by the server"}),!1;this.onPacket(Y)};if(pJ(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,cJ(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]=m5();if(!this.supportsBinary&&!J.sid)J.b64=1;return this.createUri(Z,J)}}var tJ=!1;try{tJ=typeof XMLHttpRequest<"u"&&"withCredentials"in new XMLHttpRequest}catch(Z){}var eJ=tJ;function SB(){}class JY extends u5{constructor(Z){super(Z);if(typeof location<"u"){let J=location.protocol==="https:",Y=location.port;if(!Y)Y=J?"443":"80";this.xd=typeof location<"u"&&Z.hostname!==location.hostname||Y!==Z.port}}doWrite(Z,J){let Y=this.request({method:"POST",data:Z});Y.on("success",J),Y.on("error",(G,Q)=>{this.onError("xhr post error",G,Q)})}doPoll(){let Z=this.request();Z.on("data",this.onData.bind(this)),Z.on("error",(J,Y)=>{this.onError("xhr poll error",J,Y)}),this.pollXhr=Z}}class I1 extends j{constructor(Z,J,Y){super();this.createRequest=Z,E1(this,Y),this._opts=Y,this._method=Y.method||"GET",this._uri=J,this._data=Y.data!==void 0?Y.data:null,this._create()}_create(){var Z;let J=y5(this._opts,"agent","pfx","key","passphrase","cert","ca","ciphers","rejectUnauthorized","autoUnref");J.xdomain=!!this._opts.xd;let Y=this._xhr=this.createRequest(J);try{Y.open(this._method,this._uri,!0);try{if(this._opts.extraHeaders){Y.setDisableHeaderCheck&&Y.setDisableHeaderCheck(!0);for(let G in this._opts.extraHeaders)if(this._opts.extraHeaders.hasOwnProperty(G))Y.setRequestHeader(G,this._opts.extraHeaders[G])}}catch(G){}if(this._method==="POST")try{Y.setRequestHeader("Content-type","text/plain;charset=UTF-8")}catch(G){}try{Y.setRequestHeader("Accept","*/*")}catch(G){}if((Z=this._opts.cookieJar)===null||Z===void 0||Z.addCookies(Y),"withCredentials"in Y)Y.withCredentials=this._opts.withCredentials;if(this._opts.requestTimeout)Y.timeout=this._opts.requestTimeout;Y.onreadystatechange=()=>{var G;if(Y.readyState===3)(G=this._opts.cookieJar)===null||G===void 0||G.parseCookies(Y.getResponseHeader("set-cookie"));if(Y.readyState!==4)return;if(Y.status===200||Y.status===1223)this._onLoad();else this.setTimeoutFn(()=>{this._onError(typeof Y.status==="number"?Y.status:0)},0)},Y.send(this._data)}catch(G){this.setTimeoutFn(()=>{this._onError(G)},0);return}if(typeof document<"u")this._index=I1.requestsCount++,I1.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=SB,Z)try{this._xhr.abort()}catch(J){}if(typeof document<"u")delete I1.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()}}I1.requestsCount=0;I1.requests={};if(typeof document<"u"){if(typeof attachEvent==="function")attachEvent("onunload",ZY);else if(typeof addEventListener==="function"){let Z="onpagehide"in s?"pagehide":"unload";addEventListener(Z,ZY,!1)}}function ZY(){for(let Z in I1.requests)if(I1.requests.hasOwnProperty(Z))I1.requests[Z].abort()}var xB=function(){let Z=YY({xdomain:!1});return Z&&Z.responseType!==null}();class Z0 extends JY{constructor(Z){super(Z);let J=Z&&Z.forceBase64;this.supportsBinary=xB&&!J}request(Z={}){return Object.assign(Z,{xd:this.xd},this.opts),new I1(YY,this.uri(),Z)}}function YY(Z){let J=Z.xdomain;try{if(typeof XMLHttpRequest<"u"&&(!J||eJ))return new XMLHttpRequest}catch(Y){}if(!J)try{return new s[["Active"].concat("Object").join("X")]("Microsoft.XMLHTTP")}catch(Y){}}var GY=typeof navigator<"u"&&typeof navigator.product==="string"&&navigator.product.toLowerCase()==="reactnative";class QY extends d1{get name(){return"websocket"}doOpen(){let Z=this.uri(),J=this.opts.protocols,Y=GY?{}:y5(this.opts,"agent","perMessageDeflate","pfx","key","passphrase","cert","ca","ciphers","rejectUnauthorized","localAddress","protocolVersion","origin","maxPayload","family","checkServerIdentity");if(this.opts.extraHeaders)Y.headers=this.opts.extraHeaders;try{this.ws=this.createSocket(Z,J,Y)}catch(G){return this.emitReserved("error",G)}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 Y=Z[J],G=J===Z.length-1;g0(Y,this.supportsBinary,(Q)=>{try{this.doWrite(Y,Q)}catch(X){}if(G)w1(()=>{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]=m5();if(!this.supportsBinary)J.b64=1;return this.createUri(Z,J)}}var t8=s.WebSocket||s.MozWebSocket;class J0 extends QY{createSocket(Z,J,Y){return!GY?J?new t8(Z,J):new t8(Z):new t8(Z,J,Y)}doWrite(Z,J){this.ws.send(J)}}class u0 extends d1{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=iJ(Number.MAX_SAFE_INTEGER,this.socket.binaryType),Y=Z.readable.pipeThrough(J).getReader(),G=lJ();G.readable.pipeTo(Z.writable),this._writer=G.writable.getWriter();let Q=()=>{Y.read().then(({done:W,value:H})=>{if(W)return;this.onPacket(H),Q()}).catch((W)=>{})};Q();let X={type:"open"};if(this.query.sid)X.data=`{"sid":"${this.query.sid}"}`;this._writer.write(X).then(()=>this.onOpen())})})}write(Z){this.writable=!1;for(let J=0;J<Z.length;J++){let Y=Z[J],G=J===Z.length-1;this._writer.write(Y).then(()=>{if(G)w1(()=>{this.writable=!0,this.emitReserved("drain")},this.setTimeoutFn)})}}doClose(){var Z;(Z=this._transport)===null||Z===void 0||Z.close()}}var e8={websocket:J0,webtransport:u0,polling:Z0};var fB=/^(?:(?![^:@\/?#]+:[^:@\/]*@)(http|https|ws|wss):\/\/)?((?:(([^:@\/?#]*)(?::([^:@\/?#]*))?)?@)?((?:[a-f0-9]{0,4}:){2,7}[a-f0-9]{0,4}|[^:\/?#]*)(?::(\d*))?)(((\/(?:[^?#](?![^?#\/]*\.[^?#\/.]+(?:[?#]|$)))*\/?)?([^?#\/]*))(?:\?([^#]*))?(?:#(.*))?)/,CB=["source","protocol","authority","userInfo","user","password","host","port","relative","path","directory","file","query","anchor"];function I0(Z){if(Z.length>8000)throw"URI too long";let J=Z,Y=Z.indexOf("["),G=Z.indexOf("]");if(Y!=-1&&G!=-1)Z=Z.substring(0,Y)+Z.substring(Y,G).replace(/:/g,";")+Z.substring(G,Z.length);let Q=fB.exec(Z||""),X={},W=14;while(W--)X[CB[W]]=Q[W]||"";if(Y!=-1&&G!=-1)X.source=J,X.host=X.host.substring(1,X.host.length-1).replace(/;/g,":"),X.authority=X.authority.replace("[","").replace("]","").replace(/;/g,":"),X.ipv6uri=!0;return X.pathNames=jB(X,X.path),X.queryKey=_B(X,X.query),X}function jB(Z,J){let Y=/\/{2,9}/g,G=J.replace(Y,"/").split("/");if(J.slice(0,1)=="/"||J.length===0)G.splice(0,1);if(J.slice(-1)=="/")G.splice(G.length-1,1);return G}function _B(Z,J){let Y={};return J.replace(/(?:^|&)([^&=]*)=?([^&]*)/g,function(G,Q,X){if(Q)Y[Q]=X}),Y}var Z9=typeof addEventListener==="function"&&typeof removeEventListener==="function",d5=[];if(Z9)addEventListener("offline",()=>{d5.forEach((Z)=>Z())},!1);class S1 extends j{constructor(Z,J){super();if(this.binaryType=nJ,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 Y=I0(Z);if(J.hostname=Y.host,J.secure=Y.protocol==="https"||Y.protocol==="wss",J.port=Y.port,Y.query)J.query=Y.query}else if(J.host)J.hostname=I0(J.host).host;if(E1(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((Y)=>{let G=Y.prototype.name;this.transports.push(G),this._transportsByName[G]=Y}),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=rJ(this.opts.query);if(Z9){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"})},d5.push(this._offlineEventListener)}if(this.opts.withCredentials)this._cookieJar=oJ();this._open()}createTransport(Z){let J=Object.assign({},this.opts.query);if(J.EIO=s8,J.transport=Z,this.id)J.sid=this.id;let Y=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](Y)}_open(){if(this.transports.length===0){this.setTimeoutFn(()=>{this.emitReserved("error","No transports available")},0);return}let Z=this.opts.rememberUpgrade&&S1.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",S1.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 Y=0;Y<this.writeBuffer.length;Y++){let G=this.writeBuffer[Y].data;if(G)J+=aJ(G);if(Y>0&&J>this._maxPayload)return this.writeBuffer.slice(0,Y);J+=2}return this.writeBuffer}_hasPingExpired(){if(!this._pingTimeoutTime)return!0;let Z=Date.now()>this._pingTimeoutTime;if(Z)this._pingTimeoutTime=0,w1(()=>{this._onClose("ping timeout")},this.setTimeoutFn);return Z}write(Z,J,Y){return this._sendPacket("message",Z,J,Y),this}send(Z,J,Y){return this._sendPacket("message",Z,J,Y),this}_sendPacket(Z,J,Y,G){if(typeof J==="function")G=J,J=void 0;if(typeof Y==="function")G=Y,Y=null;if(this.readyState==="closing"||this.readyState==="closed")return;Y=Y||{},Y.compress=Y.compress!==!1;let Q={type:Z,data:J,options:Y};if(this.emitReserved("packetCreate",Q),this.writeBuffer.push(Q),G)this.once("flush",G);this.flush()}close(){let Z=()=>{this._onClose("forced close"),this.transport.close()},J=()=>{this.off("upgrade",J),this.off("upgradeError",J),Z()},Y=()=>{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)Y();else Z()});else if(this.upgrading)Y();else Z();return this}_onError(Z){if(S1.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(),Z9){if(this._beforeunloadEventListener)removeEventListener("beforeunload",this._beforeunloadEventListener,!1);if(this._offlineEventListener){let Y=d5.indexOf(this._offlineEventListener);if(Y!==-1)d5.splice(Y,1)}}this.readyState="closed",this.id=null,this.emitReserved("close",Z,J),this.writeBuffer=[],this._prevBufferLen=0}}}S1.protocol=s8;class J9 extends S1{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),Y=!1;S1.priorWebsocketSuccess=!1;let G=()=>{if(Y)return;J.send([{type:"ping",data:"probe"}]),J.once("packet",(B)=>{if(Y)return;if(B.type==="pong"&&B.data==="probe"){if(this.upgrading=!0,this.emitReserved("upgrading",J),!J)return;S1.priorWebsocketSuccess=J.name==="websocket",this.transport.pause(()=>{if(Y)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 Q(){if(Y)return;Y=!0,U(),J.close(),J=null}let X=(B)=>{let L=Error("probe error: "+B);L.transport=J.name,Q(),this.emitReserved("upgradeError",L)};function W(){X("transport closed")}function H(){X("socket closed")}function z(B){if(J&&B.name!==J.name)Q()}let U=()=>{J.removeListener("open",G),J.removeListener("error",X),J.removeListener("close",W),this.off("close",H),this.off("upgrading",z)};if(J.once("open",G),J.once("error",X),J.once("close",W),this.once("close",H),this.once("upgrading",z),this._upgrades.indexOf("webtransport")!==-1&&Z!=="webtransport")this.setTimeoutFn(()=>{if(!Y)J.open()},200);else J.open()}onHandshake(Z){this._upgrades=this._filterUpgrades(Z.upgrades),super.onHandshake(Z)}_filterUpgrades(Z){let J=[];for(let Y=0;Y<Z.length;Y++)if(~this.transports.indexOf(Z[Y]))J.push(Z[Y]);return J}}class d0 extends J9{constructor(Z,J={}){let Y=typeof Z==="object"?Z:J;if(!Y.transports||Y.transports&&typeof Y.transports[0]==="string")Y.transports=(Y.transports||["polling","websocket","webtransport"]).map((G)=>e8[G]).filter((G)=>!!G);super(Z,Y)}}var Qq=d0.protocol;function XY(Z,J="",Y){let G=Z;if(Y=Y||typeof location<"u"&&location,Z==null)Z=Y.protocol+"//"+Y.host;if(typeof Z==="string"){if(Z.charAt(0)==="/")if(Z.charAt(1)==="/")Z=Y.protocol+Z;else Z=Y.host+Z;if(!/^(https?|wss?):\/\//.test(Z))if(typeof Y<"u")Z=Y.protocol+"//"+Z;else Z="https://"+Z;G=I0(Z)}if(!G.port){if(/^(http|ws)$/.test(G.protocol))G.port="80";else if(/^(http|ws)s$/.test(G.protocol))G.port="443"}G.path=G.path||"/";let X=G.host.indexOf(":")!==-1?"["+G.host+"]":G.host;return G.id=G.protocol+"://"+X+":"+G.port+J,G.href=G.protocol+"://"+X+(Y&&Y.port===G.port?"":":"+G.port),G}var X9={};N7(X9,{protocol:()=>BY,isPacketValid:()=>cB,PacketType:()=>w,Encoder:()=>KY,Decoder:()=>Q9});var vB=typeof ArrayBuffer==="function",hB=(Z)=>{return typeof ArrayBuffer.isView==="function"?ArrayBuffer.isView(Z):Z.buffer instanceof ArrayBuffer},WY=Object.prototype.toString,bB=typeof Blob==="function"||typeof Blob<"u"&&WY.call(Blob)==="[object BlobConstructor]",gB=typeof File==="function"||typeof File<"u"&&WY.call(File)==="[object FileConstructor]";function p0(Z){return vB&&(Z instanceof ArrayBuffer||hB(Z))||bB&&Z instanceof Blob||gB&&Z instanceof File}function c0(Z,J){if(!Z||typeof Z!=="object")return!1;if(Array.isArray(Z)){for(let Y=0,G=Z.length;Y<G;Y++)if(c0(Z[Y]))return!0;return!1}if(p0(Z))return!0;if(Z.toJSON&&typeof Z.toJSON==="function"&&arguments.length===1)return c0(Z.toJSON(),!0);for(let Y in Z)if(Object.prototype.hasOwnProperty.call(Z,Y)&&c0(Z[Y]))return!0;return!1}function HY(Z){let J=[],Y=Z.data,G=Z;return G.data=Y9(Y,J),G.attachments=J.length,{packet:G,buffers:J}}function Y9(Z,J){if(!Z)return Z;if(p0(Z)){let Y={_placeholder:!0,num:J.length};return J.push(Z),Y}else if(Array.isArray(Z)){let Y=Array(Z.length);for(let G=0;G<Z.length;G++)Y[G]=Y9(Z[G],J);return Y}else if(typeof Z==="object"&&!(Z instanceof Date)){let Y={};for(let G in Z)if(Object.prototype.hasOwnProperty.call(Z,G))Y[G]=Y9(Z[G],J);return Y}return Z}function zY(Z,J){return Z.data=G9(Z.data,J),delete Z.attachments,Z}function G9(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 Y=0;Y<Z.length;Y++)Z[Y]=G9(Z[Y],J);else if(typeof Z==="object"){for(let Y in Z)if(Object.prototype.hasOwnProperty.call(Z,Y))Z[Y]=G9(Z[Y],J)}return Z}var UY=["connect","connect_error","disconnect","disconnecting","newListener","removeListener"],BY=5,w;(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"})(w||(w={}));class KY{constructor(Z){this.replacer=Z}encode(Z){if(Z.type===w.EVENT||Z.type===w.ACK){if(c0(Z))return this.encodeAsBinary({type:Z.type===w.EVENT?w.BINARY_EVENT:w.BINARY_ACK,nsp:Z.nsp,data:Z.data,id:Z.id})}return[this.encodeAsString(Z)]}encodeAsString(Z){let J=""+Z.type;if(Z.type===w.BINARY_EVENT||Z.type===w.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=HY(Z),Y=this.encodeAsString(J.packet),G=J.buffers;return G.unshift(Y),G}}class Q9 extends j{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 Y=J.type===w.BINARY_EVENT;if(Y||J.type===w.BINARY_ACK){if(J.type=Y?w.EVENT:w.ACK,this.reconstructor=new LY(J),J.attachments===0)super.emitReserved("decoded",J)}else super.emitReserved("decoded",J)}else if(p0(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,Y={type:Number(Z.charAt(0))};if(w[Y.type]===void 0)throw Error("unknown packet type "+Y.type);if(Y.type===w.BINARY_EVENT||Y.type===w.BINARY_ACK){let Q=J+1;while(Z.charAt(++J)!=="-"&&J!=Z.length);let X=Z.substring(Q,J);if(X!=Number(X)||Z.charAt(J)!=="-")throw Error("Illegal attachments");Y.attachments=Number(X)}if(Z.charAt(J+1)==="/"){let Q=J+1;while(++J){if(Z.charAt(J)===",")break;if(J===Z.length)break}Y.nsp=Z.substring(Q,J)}else Y.nsp="/";let G=Z.charAt(J+1);if(G!==""&&Number(G)==G){let Q=J+1;while(++J){let X=Z.charAt(J);if(X==null||Number(X)!=X){--J;break}if(J===Z.length)break}Y.id=Number(Z.substring(Q,J+1))}if(Z.charAt(++J)){let Q=this.tryParse(Z.substr(J));if(Q9.isPayloadValid(Y.type,Q))Y.data=Q;else throw Error("invalid payload")}return Y}tryParse(Z){try{return JSON.parse(Z,this.reviver)}catch(J){return!1}}static isPayloadValid(Z,J){switch(Z){case w.CONNECT:return c5(J);case w.DISCONNECT:return J===void 0;case w.CONNECT_ERROR:return typeof J==="string"||c5(J);case w.EVENT:case w.BINARY_EVENT:return Array.isArray(J)&&(typeof J[0]==="number"||typeof J[0]==="string"&&UY.indexOf(J[0])===-1);case w.ACK:case w.BINARY_ACK:return Array.isArray(J)}}destroy(){if(this.reconstructor)this.reconstructor.finishedReconstruction(),this.reconstructor=null}}class LY{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=zY(this.reconPack,this.buffers);return this.finishedReconstruction(),J}return null}finishedReconstruction(){this.reconPack=null,this.buffers=[]}}function yB(Z){return typeof Z==="string"}var mB=Number.isInteger||function(Z){return typeof Z==="number"&&isFinite(Z)&&Math.floor(Z)===Z};function uB(Z){return Z===void 0||mB(Z)}function c5(Z){return Object.prototype.toString.call(Z)==="[object Object]"}function dB(Z,J){switch(Z){case w.CONNECT:return J===void 0||c5(J);case w.DISCONNECT:return J===void 0;case w.EVENT:return Array.isArray(J)&&(typeof J[0]==="number"||typeof J[0]==="string"&&UY.indexOf(J[0])===-1);case w.ACK:return Array.isArray(J);case w.CONNECT_ERROR:return typeof J==="string"||c5(J);default:return!1}}function cB(Z){return yB(Z.nsp)&&uB(Z.id)&&dB(Z.type,Z.data)}function X1(Z,J,Y){return Z.on(J,Y),function(){Z.off(J,Y)}}var pB=Object.freeze({connect:1,connect_error:1,disconnect:1,disconnecting:1,newListener:1,removeListener:1});class l0 extends j{constructor(Z,J,Y){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,Y&&Y.auth)this.auth=Y.auth;if(this._opts=Object.assign({},Y),this.io._autoConnect)this.open()}get disconnected(){return!this.connected}subEvents(){if(this.subs)return;let Z=this.io;this.subs=[X1(Z,"open",this.onopen.bind(this)),X1(Z,"packet",this.onpacket.bind(this)),X1(Z,"error",this.onerror.bind(this)),X1(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 Y,G,Q;if(pB.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 X={type:w.EVENT,data:J};if(X.options={},X.options.compress=this.flags.compress!==!1,typeof J[J.length-1]==="function"){let U=this.ids++,B=J.pop();this._registerAckCallback(U,B),X.id=U}let W=(G=(Y=this.io.engine)===null||Y===void 0?void 0:Y.transport)===null||G===void 0?void 0:G.writable,H=this.connected&&!((Q=this.io.engine)===null||Q===void 0?void 0:Q._hasPingExpired());if(this.flags.volatile&&!W);else if(H)this.notifyOutgoingListeners(X),this.packet(X);else this.sendBuffer.push(X);return this.flags={},this}_registerAckCallback(Z,J){var Y;let G=(Y=this.flags.timeout)!==null&&Y!==void 0?Y:this._opts.ackTimeout;if(G===void 0){this.acks[Z]=J;return}let Q=this.io.setTimeoutFn(()=>{delete this.acks[Z];for(let W=0;W<this.sendBuffer.length;W++)if(this.sendBuffer[W].id===Z)this.sendBuffer.splice(W,1);J.call(this,Error("operation has timed out"))},G),X=(...W)=>{this.io.clearTimeoutFn(Q),J.apply(this,W)};X.withError=!0,this.acks[Z]=X}emitWithAck(Z,...J){return new Promise((Y,G)=>{let Q=(X,W)=>{return X?G(X):Y(W)};Q.withError=!0,J.push(Q),this.emit(Z,...J)})}_addToQueue(Z){let J;if(typeof Z[Z.length-1]==="function")J=Z.pop();let Y={id:this._queueSeq++,tryCount:0,pending:!1,args:Z,flags:Object.assign({fromQueue:!0},this.flags)};Z.push((G,...Q)=>{if(Y!==this._queue[0]);if(G!==null){if(Y.tryCount>this._opts.retries){if(this._queue.shift(),J)J(G)}}else if(this._queue.shift(),J)J(null,...Q);return Y.pending=!1,this._drainQueue()}),this._queue.push(Y),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:w.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((Y)=>String(Y.id)===Z)){let Y=this.acks[Z];if(delete this.acks[Z],Y.withError)Y.call(this,Error("socket has been disconnected"))}})}onpacket(Z){if(Z.nsp!==this.nsp)return;switch(Z.type){case w.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 w.EVENT:case w.BINARY_EVENT:this.onevent(Z);break;case w.ACK:case w.BINARY_ACK:this.onack(Z);break;case w.DISCONNECT:this.ondisconnect();break;case w.CONNECT_ERROR:this.destroy();let Y=Error(Z.data.message);Y.data=Z.data.data,this.emitReserved("connect_error",Y);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 Y of J)Y.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,Y=!1;return function(...G){if(Y)return;Y=!0,J.packet({type:w.ACK,id:Z,data:G})}}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:w.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 Y=0;Y<J.length;Y++)if(Z===J[Y])return J.splice(Y,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 Y=0;Y<J.length;Y++)if(Z===J[Y])return J.splice(Y,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 Y of J)Y.apply(this,Z.data)}}}function Y0(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}Y0.prototype.duration=function(){var Z=this.ms*Math.pow(this.factor,this.attempts++);if(this.jitter){var J=Math.random(),Y=Math.floor(J*this.jitter*Z);Z=(Math.floor(J*10)&1)==0?Z-Y:Z+Y}return Math.min(Z,this.max)|0};Y0.prototype.reset=function(){this.attempts=0};Y0.prototype.setMin=function(Z){this.ms=Z};Y0.prototype.setMax=function(Z){this.max=Z};Y0.prototype.setJitter=function(Z){this.jitter=Z};class i0 extends j{constructor(Z,J){var Y;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,E1(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((Y=J.randomizationFactor)!==null&&Y!==void 0?Y:0.5),this.backoff=new Y0({min:this.reconnectionDelay(),max:this.reconnectionDelayMax(),jitter:this.randomizationFactor()}),this.timeout(J.timeout==null?20000:J.timeout),this._readyState="closed",this.uri=Z;let G=J.parser||X9;if(this.encoder=new G.Encoder,this.decoder=new G.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 d0(this.uri,this.opts);let J=this.engine,Y=this;this._readyState="opening",this.skipReconnect=!1;let G=X1(J,"open",function(){Y.onopen(),Z&&Z()}),Q=(W)=>{if(this.cleanup(),this._readyState="closed",this.emitReserved("error",W),Z)Z(W);else this.maybeReconnectOnOpen()},X=X1(J,"error",Q);if(this._timeout!==!1){let W=this._timeout,H=this.setTimeoutFn(()=>{G(),Q(Error("timeout")),J.close()},W);if(this.opts.autoUnref)H.unref();this.subs.push(()=>{this.clearTimeoutFn(H)})}return this.subs.push(G),this.subs.push(X),this}connect(Z){return this.open(Z)}onopen(){this.cleanup(),this._readyState="open",this.emitReserved("open");let Z=this.engine;this.subs.push(X1(Z,"ping",this.onping.bind(this)),X1(Z,"data",this.ondata.bind(this)),X1(Z,"error",this.onerror.bind(this)),X1(Z,"close",this.onclose.bind(this)),X1(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){w1(()=>{this.emitReserved("packet",Z)},this.setTimeoutFn)}onerror(Z){this.emitReserved("error",Z)}socket(Z,J){let Y=this.nsps[Z];if(!Y)Y=new l0(this,Z,J),this.nsps[Z]=Y;else if(this._autoConnect&&!Y.active)Y.connect();return Y}_destroy(Z){let J=Object.keys(this.nsps);for(let Y of J)if(this.nsps[Y].active)return;this._close()}_packet(Z){let J=this.encoder.encode(Z);for(let Y=0;Y<J.length;Y++)this.engine.write(J[Y],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 Y;if(this.cleanup(),(Y=this.engine)===null||Y===void 0||Y.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 Y=this.setTimeoutFn(()=>{if(Z.skipReconnect)return;if(this.emitReserved("reconnect_attempt",Z.backoff.attempts),Z.skipReconnect)return;Z.open((G)=>{if(G)Z._reconnecting=!1,Z.reconnect(),this.emitReserved("reconnect_error",G);else Z.onreconnect()})},J);if(this.opts.autoUnref)Y.unref();this.subs.push(()=>{this.clearTimeoutFn(Y)})}}onreconnect(){let Z=this.backoff.attempts;this._reconnecting=!1,this.backoff.reset(),this.emitReserved("reconnect",Z)}}var n0={};function o0(Z,J){if(typeof Z==="object")J=Z,Z=void 0;J=J||{};let Y=XY(Z,J.path||"/socket.io"),G=Y.source,Q=Y.id,X=Y.path,W=n0[Q]&&X in n0[Q].nsps,H=J.forceNew||J["force new connection"]||J.multiplex===!1||W,z;if(H)z=new i0(G,J);else{if(!n0[Q])n0[Q]=new i0(G,J);z=n0[Q]}if(Y.query&&!J.query)J.query=Y.queryKey;return z.socket(Y.path,J)}Object.assign(o0,{Manager:i0,Socket:l0,io:o0,connect:o0});import{createContext as lB}from"react";var p5=(Z)=>o0(Z,{autoConnect:!1,transports:["websocket"]}),iB=lB(null),c1=iB;import{createContext as UK}from"react";function o(Z,J,Y,G){function Q(X){return X instanceof Y?X:new Y(function(W){W(X)})}return new(Y||(Y=Promise))(function(X,W){function H(B){try{U(G.next(B))}catch(L){W(L)}}function z(B){try{U(G.throw(B))}catch(L){W(L)}}function U(B){B.done?X(B.value):Q(B.value).then(H,z)}U((G=G.apply(Z,J||[])).next())})}function nB(Z){return Z&&Z.__esModule&&Object.prototype.hasOwnProperty.call(Z,"default")?Z.default:Z}var U9={exports:{}},q0=typeof Reflect==="object"?Reflect:null,MY=q0&&typeof q0.apply==="function"?q0.apply:function(J,Y,G){return Function.prototype.apply.call(J,Y,G)},l5;if(q0&&typeof q0.ownKeys==="function")l5=q0.ownKeys;else if(Object.getOwnPropertySymbols)l5=function(J){return Object.getOwnPropertyNames(J).concat(Object.getOwnPropertySymbols(J))};else l5=function(J){return Object.getOwnPropertyNames(J)};function oB(Z){if(console&&console.warn)console.warn(Z)}var FY=Number.isNaN||function(J){return J!==J};function C(){C.init.call(this)}U9.exports=C;U9.exports.once=tB;C.EventEmitter=C;C.prototype._events=void 0;C.prototype._eventsCount=0;C.prototype._maxListeners=void 0;var $Y=10;function s5(Z){if(typeof Z!=="function")throw TypeError('The "listener" argument must be of type Function. Received type '+typeof Z)}Object.defineProperty(C,"defaultMaxListeners",{enumerable:!0,get:function(){return $Y},set:function(Z){if(typeof Z!=="number"||Z<0||FY(Z))throw RangeError('The value of "defaultMaxListeners" is out of range. It must be a non-negative number. Received '+Z+".");$Y=Z}});C.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};C.prototype.setMaxListeners=function(J){if(typeof J!=="number"||J<0||FY(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 OY(Z){if(Z._maxListeners===void 0)return C.defaultMaxListeners;return Z._maxListeners}C.prototype.getMaxListeners=function(){return OY(this)};C.prototype.emit=function(J){var Y=[];for(var G=1;G<arguments.length;G++)Y.push(arguments[G]);var Q=J==="error",X=this._events;if(X!==void 0)Q=Q&&X.error===void 0;else if(!Q)return!1;if(Q){var W;if(Y.length>0)W=Y[0];if(W instanceof Error)throw W;var H=Error("Unhandled error."+(W?" ("+W.message+")":""));throw H.context=W,H}var z=X[J];if(z===void 0)return!1;if(typeof z==="function")MY(z,this,Y);else{var U=z.length,B=NY(z,U);for(var G=0;G<U;++G)MY(B[G],this,Y)}return!0};function VY(Z,J,Y,G){var Q,X,W;if(s5(Y),X=Z._events,X===void 0)X=Z._events=Object.create(null),Z._eventsCount=0;else{if(X.newListener!==void 0)Z.emit("newListener",J,Y.listener?Y.listener:Y),X=Z._events;W=X[J]}if(W===void 0)W=X[J]=Y,++Z._eventsCount;else{if(typeof W==="function")W=X[J]=G?[Y,W]:[W,Y];else if(G)W.unshift(Y);else W.push(Y);if(Q=OY(Z),Q>0&&W.length>Q&&!W.warned){W.warned=!0;var H=Error("Possible EventEmitter memory leak detected. "+W.length+" "+String(J)+" listeners added. Use emitter.setMaxListeners() to increase limit");H.name="MaxListenersExceededWarning",H.emitter=Z,H.type=J,H.count=W.length,oB(H)}}return Z}C.prototype.addListener=function(J,Y){return VY(this,J,Y,!1)};C.prototype.on=C.prototype.addListener;C.prototype.prependListener=function(J,Y){return VY(this,J,Y,!0)};function aB(){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 IY(Z,J,Y){var G={fired:!1,wrapFn:void 0,target:Z,type:J,listener:Y},Q=aB.bind(G);return Q.listener=Y,G.wrapFn=Q,Q}C.prototype.once=function(J,Y){return s5(Y),this.on(J,IY(this,J,Y)),this};C.prototype.prependOnceListener=function(J,Y){return s5(Y),this.prependListener(J,IY(this,J,Y)),this};C.prototype.removeListener=function(J,Y){var G,Q,X,W,H;if(s5(Y),Q=this._events,Q===void 0)return this;if(G=Q[J],G===void 0)return this;if(G===Y||G.listener===Y){if(--this._eventsCount===0)this._events=Object.create(null);else if(delete Q[J],Q.removeListener)this.emit("removeListener",J,G.listener||Y)}else if(typeof G!=="function"){X=-1;for(W=G.length-1;W>=0;W--)if(G[W]===Y||G[W].listener===Y){H=G[W].listener,X=W;break}if(X<0)return this;if(X===0)G.shift();else sB(G,X);if(G.length===1)Q[J]=G[0];if(Q.removeListener!==void 0)this.emit("removeListener",J,H||Y)}return this};C.prototype.off=C.prototype.removeListener;C.prototype.removeAllListeners=function(J){var Y,G,Q;if(G=this._events,G===void 0)return this;if(G.removeListener===void 0){if(arguments.length===0)this._events=Object.create(null),this._eventsCount=0;else if(G[J]!==void 0)if(--this._eventsCount===0)this._events=Object.create(null);else delete G[J];return this}if(arguments.length===0){var X=Object.keys(G),W;for(Q=0;Q<X.length;++Q){if(W=X[Q],W==="removeListener")continue;this.removeAllListeners(W)}return this.removeAllListeners("removeListener"),this._events=Object.create(null),this._eventsCount=0,this}if(Y=G[J],typeof Y==="function")this.removeListener(J,Y);else if(Y!==void 0)for(Q=Y.length-1;Q>=0;Q--)this.removeListener(J,Y[Q]);return this};function qY(Z,J,Y){var G=Z._events;if(G===void 0)return[];var Q=G[J];if(Q===void 0)return[];if(typeof Q==="function")return Y?[Q.listener||Q]:[Q];return Y?rB(Q):NY(Q,Q.length)}C.prototype.listeners=function(J){return qY(this,J,!0)};C.prototype.rawListeners=function(J){return qY(this,J,!1)};C.listenerCount=function(Z,J){if(typeof Z.listenerCount==="function")return Z.listenerCount(J);else return DY.call(Z,J)};C.prototype.listenerCount=DY;function DY(Z){var J=this._events;if(J!==void 0){var Y=J[Z];if(typeof Y==="function")return 1;else if(Y!==void 0)return Y.length}return 0}C.prototype.eventNames=function(){return this._eventsCount>0?l5(this._events):[]};function NY(Z,J){var Y=Array(J);for(var G=0;G<J;++G)Y[G]=Z[G];return Y}function sB(Z,J){for(;J+1<Z.length;J++)Z[J]=Z[J+1];Z.pop()}function rB(Z){var J=Array(Z.length);for(var Y=0;Y<J.length;++Y)J[Y]=Z[Y].listener||Z[Y];return J}function tB(Z,J){return new Promise(function(Y,G){function Q(W){Z.removeListener(J,X),G(W)}function X(){if(typeof Z.removeListener==="function")Z.removeListener("error",Q);Y([].slice.call(arguments))}if(AY(Z,J,X,{once:!0}),J!=="error")eB(Z,Q,{once:!0})})}function eB(Z,J,Y){if(typeof Z.on==="function")AY(Z,"error",J,Y)}function AY(Z,J,Y,G){if(typeof Z.on==="function")if(G.once)Z.once(J,Y);else Z.on(J,Y);else if(typeof Z.addEventListener==="function")Z.addEventListener(J,function Q(X){if(G.once)Z.removeEventListener(J,Q);Y(X)});else throw TypeError('The "emitter" argument must be of type EventEmitter. Received type '+typeof Z)}var ZK=U9.exports,RY=nB(ZK),_;(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"})(_||(_={}));var p1;(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"})(p1||(p1={}));var a0;(function(Z){Z[Z.disconnectCalled=0]="disconnectCalled",Z[Z.unauthorized=1]="unauthorized",Z[Z.badProtocol=2]="badProtocol",Z[Z.messageSizeLimit=3]="messageSizeLimit"})(a0||(a0={}));var i5;(function(Z){Z[Z.subscribeCalled=0]="subscribeCalled",Z[Z.transportClosed=1]="transportClosed"})(i5||(i5={}));var n5;(function(Z){Z[Z.unsubscribeCalled=0]="unsubscribeCalled",Z[Z.unauthorized=1]="unauthorized",Z[Z.clientClosed=2]="clientClosed"})(n5||(n5={}));var W9;(function(Z){Z[Z.channelCompaction=1]="channelCompaction"})(W9||(W9={}));var h;(function(Z){Z.Disconnected="disconnected",Z.Connecting="connecting",Z.Connected="connected"})(h||(h={}));var r;(function(Z){Z.Unsubscribed="unsubscribed",Z.Subscribing="subscribing",Z.Subscribed="subscribed"})(r||(r={}));function JK(Z,J){return Z.lastIndexOf(J,0)===0}function PY(Z){if(Z===void 0||Z===null)return!1;return typeof Z==="function"}function YK(Z,J){if(globalThis.console){let Y=globalThis.console[Z];if(PY(Y))Y.apply(globalThis.console,J)}}function GK(Z,J){return Math.floor(Math.random()*(J-Z+1)+Z)}function o5(Z,J,Y){if(Z>31)Z=31;let G=GK(0,Math.min(Y,J*Math.pow(2,Z)));return Math.min(Y,J+G)}function QK(Z){return"error"in Z&&Z.error!==null}function a5(Z){return Math.min(Z*1000,2147483647)}class TY extends RY{constructor(Z,J,Y){super();if(this._resubscribeTimeout=null,this._refreshTimeout=null,this.channel=J,this.state=r.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(Y),this._centrifuge._debugEnabled)this.on("state",(G)=>{this._debug("subscription state",J,G.oldState,"->",G.newState)}),this.on("error",(G)=>{this._debug("subscription error",J,G)});else this.on("error",function(){Function.prototype()})}ready(Z){if(this.state===r.Unsubscribed)return Promise.reject({code:_.subscriptionUnsubscribed,message:this.state});if(this.state===r.Subscribed)return Promise.resolve();return new Promise((J,Y)=>{let G={resolve:J,reject:Y};if(Z)G.timeout=setTimeout(function(){Y({code:_.timeout,message:"timeout"})},Z);this._promises[this._nextPromiseId()]=G})}subscribe(){if(this._isSubscribed())return;this._resubscribeAttempts=0,this._setSubscribing(i5.subscribeCalled,"subscribe called")}unsubscribe(){this._unsubPromise=this._setUnsubscribed(n5.unsubscribeCalled,"unsubscribe called",!0)}publish(Z){return o(this,void 0,void 0,function*(){return yield this._methodCall(),this._centrifuge.publish(this.channel,Z)})}presence(){return o(this,void 0,void 0,function*(){return yield this._methodCall(),this._centrifuge.presence(this.channel)})}presenceStats(){return o(this,void 0,void 0,function*(){return yield this._methodCall(),this._centrifuge.presenceStats(this.channel)})}history(Z){return o(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:_.subscriptionUnsubscribed,message:this.state});return new Promise((Z,J)=>{let Y=this._centrifuge._config.timeout,G=setTimeout(()=>{J({code:_.timeout,message:"timeout"})},Y);this._promises[this._nextPromiseId()]={timeout:G,resolve:Z,reject:J}})}_nextPromiseId(){return++this._promiseId}_needRecover(){return this._recover===!0}_isUnsubscribed(){return this.state===r.Unsubscribed}_isSubscribing(){return this.state===r.Subscribing}_isSubscribed(){return this.state===r.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(r.Subscribed);let J=this._centrifuge._getSubscribeContext(this.channel,Z);this.emit("subscribed",J),this._resolvePromises();let Y=Z.publications;if(Y&&Y.length>0)for(let G in Y){if(!Y.hasOwnProperty(G))continue;this._handlePublication(Y[G])}if(Z.expires===!0)this._refreshTimeout=setTimeout(()=>this._refresh(),a5(Z.ttl))}_setSubscribing(Z,J){return o(this,void 0,void 0,function*(){if(this._isSubscribing())return;if(this._isSubscribed())this._clearSubscribedState();if(this._setState(r.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 q1){this._inflight=!1,this._failUnauthorized();return}this.emit("error",{type:"subscribeData",channel:this.channel,error:{code:_.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 q1){this._inflight=!1,this._failUnauthorized();return}this.emit("error",{type:"subscribeToken",channel:this.channel,error:{code:_.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((Y)=>{this._inflight=!1;let G=Y.reply.subscribe;if(this._handleSubscribeResponse(G),Y.next)Y.next()},(Y)=>{if(this._inflight=!1,this._handleSubscribeError(Y.error),Y.next)Y.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=W9.channelCompaction,this._needRecover()){J.recover=!0;let Y=this._getOffset();if(Y)J.offset=Y;let G=this._getEpoch();if(G)J.epoch=G}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===_.timeout){this._centrifuge._disconnect(p1.subscribeTimeout,"subscribe timeout",!0);return}this._subscribeError(Z)}_handleSubscribeResponse(Z){if(!this._isSubscribing())return;this._setSubscribed(Z)}_setUnsubscribed(Z,J,Y){if(this._isUnsubscribed())return Promise.resolve();let G=Promise.resolve();if(this._isSubscribed()){if(Y)G=this._centrifuge._unsubscribe(this);this._clearSubscribedState()}else if(this._isSubscribing()){if(this._inflight&&Y)G=this._centrifuge._unsubscribe(this);this._clearSubscribingState()}if(this._inflight=!1,this._setState(r.Unsubscribed))this.emit("unsubscribed",{channel:this.channel,code:Z,reason:J});return this._rejectPromises({code:_.subscriptionUnsubscribed,message:this.state}),G}_handlePublication(Z){if(this._delta&&this._delta_negotiated){let{newData:Y,newPrevValue:G}=this._centrifuge._codec.applyDeltaIfNeeded(Z,this._prevValue);Z.data=Y,this._prevValue=G}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===h.Connected)this.emit("error",J);this._scheduleResubscribe()}else this._setUnsubscribed(Z.code,Z.message,!1)}_getResubscribeDelay(){let Z=o5(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:_.badConfiguration,message:"provide a function to get channel subscription token"}}),Promise.reject(new q1(""));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 G={sub_refresh:{channel:Z.channel,token:J}};Z._centrifuge._call(G).then((Q)=>{let X=Q.reply.sub_refresh;if(Z._refreshResponse(X),Q.next)Q.next()},(Q)=>{if(Z._refreshError(Q.error),Q.next)Q.next()})}).catch(function(J){if(J instanceof q1){Z._failUnauthorized();return}Z.emit("error",{type:"refreshToken",channel:Z.channel,error:{code:_.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(),a5(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 o5(0,1e4,20000)}_failUnauthorized(){this._setUnsubscribed(n5.unauthorized,"unauthorized",!0)}}class wY{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=(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 H9{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 Y="";if(Z==="protobuf")Y="centrifuge-protobuf";if(Y!=="")this._transport=new this.options.websocket(this.endpoint,Y);else this._transport=new this.options.websocket(this.endpoint);if(Z==="protobuf")this._transport.binaryType="arraybuffer";this._transport.onopen=()=>{J.onOpen()},this._transport.onerror=(G)=>{J.onError(G)},this._transport.onclose=(G)=>{J.onClose(G)},this._transport.onmessage=(G)=>{J.onMessage(G.data)}}close(){this._transport.close()}send(Z){this._transport.send(Z)}}class EY{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,Y){let G=new EventTarget,Q=Z.options.fetch;return Q(J,Y).then(Z._handleErrors).then((X)=>{G.dispatchEvent(new Event("open"));let W="",H=0,z=new Uint8Array,U=X.body.getReader();return new Z.options.readableStream({start(B){function L(){return U.read().then(({done:F,value:M})=>{if(F){G.dispatchEvent(new Event("close")),B.close();return}try{if(Z._protocol==="json"){W+=Z._utf8decoder.decode(M);while(H<W.length)if(W[H]===`
|
|
23
|
+
`){let K=W.substring(0,H);G.dispatchEvent(new MessageEvent("message",{data:K})),W=W.substring(H+1),H=0}else++H}else{let K=new Uint8Array(z.length+M.length);K.set(z),K.set(M,z.length),z=K;while(!0){let $=Z.options.decoder.decodeReply(z);if($.ok){let O=z.slice(0,$.pos);G.dispatchEvent(new MessageEvent("message",{data:O})),z=z.slice($.pos);continue}break}}}catch(K){G.dispatchEvent(new Event("error",{detail:K})),G.dispatchEvent(new Event("close")),B.close();return}L()}).catch(function(F){G.dispatchEvent(new Event("error",{detail:F})),G.dispatchEvent(new Event("close")),B.close();return})}return L()}})}).catch((X)=>{G.dispatchEvent(new Event("error",{detail:X})),G.dispatchEvent(new Event("close"))}),G}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,Y){this._protocol=Z,this._abortController=new AbortController;let G,Q;if(Z==="json")G={Accept:"application/json","Content-Type":"application/json"},Q=Y;else G={Accept:"application/octet-stream","Content-Type":"application/octet-stream"},Q=Y;let X={method:"POST",headers:G,body:Q,mode:"cors",credentials:"same-origin",signal:this._abortController.signal},W=this._fetchEventTarget(this,this.endpoint,X);W.addEventListener("open",()=>{J.onOpen()}),W.addEventListener("error",(H)=>{this._abortController.abort(),J.onError(H)}),W.addEventListener("close",()=>{this._abortController.abort(),J.onClose({code:4,reason:"connection closed"})}),W.addEventListener("message",(H)=>{J.onMessage(H.data)})}close(){this._abortController.abort()}send(Z,J,Y){let G,Q,X={session:J,node:Y,data:Z};if(this._protocol==="json")G={"Content-Type":"application/json"},Q=JSON.stringify(X);else G={"Content-Type":"application/octet-stream"},Q=this.options.encoder.encodeEmulationRequest(X);let W=this.options.fetch,H={method:"POST",headers:G,body:Q,mode:"cors",credentials:"same-origin"};W(this.options.emulationEndpoint,H)}}class SY{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,Y){let G;if(globalThis&&globalThis.document&&globalThis.document.baseURI)G=new URL(this.endpoint,globalThis.document.baseURI);else G=new URL(this.endpoint);G.searchParams.append("cf_connect",Y);let Q={},X=new this.options.eventsource(G.toString(),Q);this._transport=X;let W=this;X.onopen=function(){J.onOpen()},X.onerror=function(H){X.close(),J.onError(H),J.onClose({code:4,reason:"connection closed"})},X.onmessage=function(H){J.onMessage(H.data)},W._onClose=function(){J.onClose({code:4,reason:"connection closed"})}}close(){if(this._transport.close(),this._onClose!==null)this._onClose()}send(Z,J,Y){let G={session:J,node:Y,data:Z},Q={"Content-Type":"application/json"},X=JSON.stringify(G),W=this.options.fetch,H={method:"POST",headers:Q,body:X,mode:"cors",credentials:"same-origin"};W(this.options.emulationEndpoint,H)}}class xY{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 o(this,void 0,void 0,function*(){let Y;if(globalThis&&globalThis.document&&globalThis.document.baseURI)Y=new URL(this.endpoint,globalThis.document.baseURI);else Y=new URL(this.endpoint);if(Z==="protobuf")Y.searchParams.append("cf_protocol","protobuf");this._protocol=Z;let G=new EventTarget;this._transport=new this.options.webtransport(Y.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(X){this.close();return}let Q;try{Q=yield this._transport.createBidirectionalStream()}catch(X){this.close();return}this._stream=Q,this._writer=this._stream.writable.getWriter(),G.addEventListener("close",()=>{J.onClose({code:4,reason:"connection closed"})}),G.addEventListener("message",(X)=>{J.onMessage(X.data)}),this._startReading(G),J.onOpen()})}_startReading(Z){return o(this,void 0,void 0,function*(){let J=this._stream.readable.getReader(),Y="",G=0,Q=new Uint8Array;try{while(!0){let{done:X,value:W}=yield J.read();if(W.length>0)if(this._protocol==="json"){Y+=this._utf8decoder.decode(W);while(G<Y.length)if(Y[G]===`
|
|
24
|
+
`){let H=Y.substring(0,G);Z.dispatchEvent(new MessageEvent("message",{data:H})),Y=Y.substring(G+1),G=0}else++G}else{let H=new Uint8Array(Q.length+W.length);H.set(Q),H.set(W,Q.length),Q=H;while(!0){let z=this.options.decoder.decodeReply(Q);if(z.ok){let U=Q.slice(0,z.pos);Z.dispatchEvent(new MessageEvent("message",{data:U})),Q=Q.slice(z.pos);continue}break}}if(X)break}}catch(X){Z.dispatchEvent(new Event("close"))}})}close(){return o(this,void 0,void 0,function*(){try{if(this._writer)yield this._writer.close();this._transport.close()}catch(Z){}})}send(Z){return o(this,void 0,void 0,function*(){let J;if(this._protocol==="json")J=new TextEncoder().encode(Z+`
|
|
25
|
+
`);else J=Z;try{yield this._writer.write(J)}catch(Y){this.close()}})}}var XK=[-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 fY{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=XK[127&this.getByte()])>=0)Z=(Z<<6)+J;return this.pos--,Z>>>0}}class CY{constructor(){this.a=[]}toByteArray(Z){if(Array.isArray(Z))return this.a;return new Uint8Array(this.a)}putArray(Z,J,Y){for(let G=J;G<Y;G++)this.a.push(Z[G])}}function WK(Z){let J=0,Y=0,G=0,Q=0,X=0,W=Z.length;while(W>=16)J=J+Z[X+0]|0,Y=Y+Z[X+1]|0,G=G+Z[X+2]|0,Q=Q+Z[X+3]|0,J=J+Z[X+4]|0,Y=Y+Z[X+5]|0,G=G+Z[X+6]|0,Q=Q+Z[X+7]|0,J=J+Z[X+8]|0,Y=Y+Z[X+9]|0,G=G+Z[X+10]|0,Q=Q+Z[X+11]|0,J=J+Z[X+12]|0,Y=Y+Z[X+13]|0,G=G+Z[X+14]|0,Q=Q+Z[X+15]|0,X+=16,W-=16;while(W>=4)J=J+Z[X+0]|0,Y=Y+Z[X+1]|0,G=G+Z[X+2]|0,Q=Q+Z[X+3]|0,X+=4,W-=4;switch(Q=((Q+(G<<8)|0)+(Y<<16)|0)+(J<<24)|0,W){case 3:Q=Q+(Z[X+2]<<8)|0;case 2:Q=Q+(Z[X+1]<<16)|0;case 1:Q=Q+(Z[X+0]<<24)|0}return Q>>>0}function HK(Z,J){let Y=0,G=new fY(J),Q=Z.length,X=J.length,W=G.getInt();if(G.getChar()!==`
|
|
26
|
+
`)throw Error("size integer not terminated by '\\n'");let H=new CY;while(G.haveBytes()){let z=G.getInt(),U;switch(G.getChar()){case"@":if(U=G.getInt(),G.haveBytes()&&G.getChar()!==",")throw Error("copy command not terminated by ','");if(Y+=z,Y>W)throw Error("copy exceeds output file size");if(U+z>Q)throw Error("copy extends past end of input");H.putArray(Z,U,U+z);break;case":":if(Y+=z,Y>W)throw Error("insert command gives an output larger than predicted");if(z>X)throw Error("insert count exceeds size of delta");H.putArray(G.a,G.pos,G.pos+z),G.pos+=z;break;case";":{let B=H.toByteArray(Z);if(z!==WK(B))throw Error("bad checksum");if(Y!==W)throw Error("generated size does not match predicted size");return B}default:throw Error("unknown delta operator")}}throw Error("unterminated delta")}class z9{name(){return"json"}encodeCommands(Z){return Z.map((J)=>JSON.stringify(J)).join(`
|
|
27
27
|
`)}decodeReplies(Z){return Z.trim().split(`
|
|
28
|
-
`).map((J)=>JSON.parse(J))}applyDeltaIfNeeded(Z,J){let Y,G;if(Z.delta){let Q=XK(J,new TextEncoder().encode(Z.data));Y=JSON.parse(new TextDecoder().decode(Q)),G=Q}else Y=JSON.parse(Z.data),G=new TextEncoder().encode(Z.data);return{newData:Y,newPrevValue:G}}}var WK={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 I1 extends Error{constructor(Z){super(Z);this.name=this.constructor.name}}class Y0 extends DY{constructor(Z,J){super();if(this._reconnectTimeout=null,this._refreshTimeout=null,this._serverPingTimeout=null,this.state=h.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 z9,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({},WK),J),this._configure(),this._debugEnabled)this.on("state",(Y)=>{this._debug("client state",Y.oldState,"->",Y.newState)}),this.on("error",(Y)=>{this._debug("client error",Y)});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 Y=new AY(this,Z,J);return this._subs[Z]=Y,Y}getSubscription(Z){return this._getSub(Z)}removeSubscription(Z){if(!Z)return;if(Z.state!==a.Unsubscribed)Z.unsubscribe();this._removeSubscription(Z)}subscriptions(){return this._subs}ready(Z){return i(this,void 0,void 0,function*(){switch(this.state){case h.Disconnected:throw{code:_.clientDisconnected,message:"client disconnected"};case h.Connected:return;default:return new Promise((J,Y)=>{let G={resolve:J,reject:Y};if(Z)G.timeout=setTimeout(()=>{Y({code:_.timeout,message:"timeout"})},Z);this._promises[this._nextPromiseId()]=G})}})}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(o0.disconnectCalled,"disconnect called",!1)}setToken(Z){this._token=Z}setData(Z){this._data=Z}setHeaders(Z){this._config.headers=Z}send(Z){return i(this,void 0,void 0,function*(){let J={send:{data:Z}};if(yield this._methodCall(),!this._transportSendCommands([J]))throw this._createErrorObject(_.transportWriteError,"transport write error")})}rpc(Z,J){return i(this,void 0,void 0,function*(){let Y={rpc:{method:Z,data:J}};return yield this._methodCall(),{data:(yield this._callPromise(Y,(Q)=>Q.rpc)).data}})}publish(Z,J){return i(this,void 0,void 0,function*(){let Y={publish:{channel:Z,data:J}};return yield this._methodCall(),yield this._callPromise(Y,()=>({})),{}})}history(Z,J){return i(this,void 0,void 0,function*(){let Y={history:this._getHistoryRequest(Z,J)};yield this._methodCall();let G=yield this._callPromise(Y,(X)=>X.history),Q=[];if(G.publications)for(let X=0;X<G.publications.length;X++)Q.push(this._getPublicationContext(Z,G.publications[X]));return{publications:Q,epoch:G.epoch||"",offset:G.offset||0}})}presence(Z){return i(this,void 0,void 0,function*(){let J={presence:{channel:Z}};yield this._methodCall();let G=(yield this._callPromise(J,(Q)=>Q.presence)).presence;for(let Q in G)if(Object.prototype.hasOwnProperty.call(G,Q)){let X=G[Q],W=X.conn_info,H=X.chan_info;if(W)X.connInfo=W;if(H)X.chanInfo=H}return{clients:G}})}presenceStats(Z){return i(this,void 0,void 0,function*(){let J={presence_stats:{channel:Z}};yield this._methodCall();let Y=yield this._callPromise(J,(G)=>{return G.presence_stats});return{numUsers:Y.num_users,numClients:Y.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;ZK("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 z9,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 Y=J.transport;if(["websocket","http_stream","sse","sockjs","webtransport"].indexOf(Y)<0)throw Error("unsupported transport name: "+Y)}}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===h.Disconnected}_isConnecting(){return this.state===h.Connecting}_isConnected(){return this.state===h.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===h.Connected||this.state===h.Connecting)this._disconnect(c1.transportClosed,"transport closed",!0),this._deviceWentOffline=!0}),Z.addEventListener("online",()=>{if(this._debug("online event triggered"),this.state!==h.Connecting)return;if(this._deviceWentOffline&&!this._transportClosed)this._deviceWentOffline=!1,this._transportClosed=!0;this._clearReconnectTimeout(),this._startReconnecting()}),this._networkEventsSet=!0}_getReconnectDelay(){let Z=n5(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 Y=J.errback;if(!Y)continue;Y({error:this._createErrorObject(_.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===a.Subscribed)J._setSubscribing(l5.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 Y=J.id;if(!(Y in this._callbacks))continue;let G=this._callbacks[Y];clearTimeout(this._callbacks[Y].timeout),delete this._callbacks[Y];let Q=G.errback;Q({error:this._createErrorObject(_.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 Y=null;if(this._config.eventsource!==null)Y=this._config.eventsource;else if(typeof globalThis.EventSource<"u")Y=globalThis.EventSource;let G=null;if(this._config.fetch!==null)G=this._config.fetch;else if(typeof globalThis.fetch<"u")G=globalThis.fetch;let Q=null;if(this._config.readableStream!==null)Q=this._config.readableStream;else if(typeof globalThis.ReadableStream<"u")Q=globalThis.ReadableStream;if(!this._emulation){if(eB(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 H9(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 F=0;while(!0){if(F>=this._transports.length)throw Error("no supported transport found");let M=this._transports[this._currentTransportIndex],K=M.transport,$=M.endpoint;if(K==="websocket"){if(this._debug("trying websocket transport"),this._transport=new H9($,{websocket:Z}),!this._transport.supported()){this._debug("websocket transport not available"),this._currentTransportIndex++,F++;continue}}else if(K==="webtransport"){if(this._debug("trying webtransport transport"),this._transport=new wY($,{webtransport:globalThis.WebTransport,decoder:this._codec,encoder:this._codec}),!this._transport.supported()){this._debug("webtransport transport not available"),this._currentTransportIndex++,F++;continue}}else if(K==="http_stream"){if(this._debug("trying http_stream transport"),this._transport=new PY($,{fetch:G,readableStream:Q,emulationEndpoint:this._config.emulationEndpoint,decoder:this._codec,encoder:this._codec}),!this._transport.supported()){this._debug("http_stream transport not available"),this._currentTransportIndex++,F++;continue}}else if(K==="sse"){if(this._debug("trying sse transport"),this._transport=new TY($,{eventsource:Y,fetch:G,emulationEndpoint:this._config.emulationEndpoint}),!this._transport.supported()){this._debug("sse transport not available"),this._currentTransportIndex++,F++;continue}}else if(K==="sockjs"){if(this._debug("trying sockjs"),this._transport=new RY($,{sockjs:J,sockjsOptions:this._config.sockjsOptions}),!this._transport.supported()){this._debug("sockjs transport not available"),this._currentTransportIndex++,F++;continue}}else throw Error("unknown transport "+K);break}}let X=this,W=this._transport,H=this._nextTransportId();X._debug("id of transport",H);let z=!1,U=[];if(this._transport.emulation()){let F=X._sendConnect(!0);U.push(F)}this._setNetworkEvents();let B=this._codec.encodeCommands(U);this._transportClosed=!1;let L;L=setTimeout(function(){W.close()},this._config.timeout),this._transport.initialize(this._codecName(),{onOpen:function(){if(L)clearTimeout(L),L=null;if(X._transportId!=H){X._debug("open callback from non-actual transport"),W.close();return}if(z=!0,X._debug(W.subName(),"transport open"),W.emulation())return;X._transportIsOpen=!0,X._transportWasOpen=!0,X.startBatching(),X._sendConnect(!1),X._sendSubscribeCommands(),X.stopBatching(),X.emit("__centrifuge_debug:connect_frame_sent",{})},onError:function(F){if(X._transportId!=H){X._debug("error callback from non-actual transport");return}X._debug("transport level error",F)},onClose:function(F){if(L)clearTimeout(L),L=null;if(X._transportId!=H){X._debug("close callback from non-actual transport");return}X._debug(W.subName(),"transport closed"),X._transportClosed=!0,X._transportIsOpen=!1;let M="connection closed",K=!0,$=0;if(F&&"code"in F&&F.code)$=F.code;if(F&&F.reason)try{let V=JSON.parse(F.reason);M=V.reason,K=V.reconnect}catch(V){if(M=F.reason,$>=3500&&$<4000||$>=4500&&$<5000)K=!1}if($<3000){if($===1009)$=o0.messageSizeLimit,M="message size limit exceeded",K=!1;else $=c1.transportClosed,M="transport closed";if(X._emulation&&!X._transportWasOpen){if(X._currentTransportIndex++,X._currentTransportIndex>=X._transports.length)X._triedAllTransports=!0,X._currentTransportIndex=0}}else X._transportWasOpen=!0;if(X._isConnecting()&&!z)X.emit("error",{type:"transport",error:{code:_.transportClosed,message:"transport closed"},transport:W.name()});X._reconnecting=!1,X._disconnect($,M,K)},onMessage:function(F){X._dataReceived(F)}},B),X.emit("__centrifuge_debug:transport_initialized",{})}_sendConnect(Z){let J=this._constructConnectCommand(),Y=this;return this._call(J,Z).then((G)=>{let Q=G.reply.connect;if(Y._connectResponse(Q),G.next)G.next()},(G)=>{if(Y._connectError(G.error),G.next)G.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((G)=>{if(!this._isConnecting())return;this._data=G,this._initializeTransport()}).catch((G)=>this._handleGetDataError(G));else this._initializeTransport();return}let Y=this;this._getToken().then(function(G){if(!Y._isConnecting())return;if(G==null||G==null){Y._failUnauthorized();return}if(Y._token=G,Y._debug("connection token refreshed"),Y._config.getData)Y._config.getData().then(function(Q){if(!Y._isConnecting())return;Y._data=Q,Y._initializeTransport()}).catch((Q)=>Y._handleGetDataError(Q));else Y._initializeTransport()}).catch(function(G){if(!Y._isConnecting())return;if(G instanceof I1){Y._failUnauthorized();return}Y.emit("error",{type:"connectToken",error:{code:_.clientConnectToken,message:G!==void 0?G.toString():""}});let Q=Y._getReconnectDelay();Y._debug("error on getting connection token, reconnect after "+Q+" milliseconds",G),Y._reconnecting=!1,Y._reconnectTimeout=setTimeout(()=>{Y._startReconnecting()},Q)})}_handleGetDataError(Z){if(Z instanceof I1){this._failUnauthorized();return}this.emit("error",{type:"connectData",error:{code:_.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!==h.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={},Y=!1;for(let G in this._serverSubs)if(this._serverSubs.hasOwnProperty(G)&&this._serverSubs[G].recoverable){Y=!0;let Q={recover:!0};if(this._serverSubs[G].offset)Q.offset=this._serverSubs[G].offset;if(this._serverSubs[G].epoch)Q.epoch=this._serverSubs[G].epoch;J[G]=Q}if(Y)Z.subs=J;return{connect:Z}}_getHistoryRequest(Z,J){let Y={channel:Z};if(J!==void 0){if(J.since){if(Y.since={offset:J.since.offset},J.since.epoch)Y.since.epoch=J.since.epoch}if(J.limit!==void 0)Y.limit=J.limit;if(J.reverse===!0)Y.reverse=!0}return Y}_methodCall(){if(this._isConnected())return Promise.resolve();return new Promise((Z,J)=>{let Y=setTimeout(function(){J({code:_.timeout,message:"timeout"})},this._config.timeout);this._promises[this._nextPromiseId()]={timeout:Y,resolve:Z,reject:J}})}_callPromise(Z,J){return new Promise((Y,G)=>{this._call(Z,!1).then((Q)=>{var X;let W=J(Q.reply);Y(W),(X=Q.next)===null||X===void 0||X.call(Q)},(Q)=>{var X;G(Q.error),(X=Q.next)===null||X===void 0||X.call(Q)})})}_dataReceived(Z){if(this._serverPing>0)this._waitServerPing();let J=this._codec.decodeReplies(Z);this._dispatchPromise=this._dispatchPromise.then(()=>{let Y;this._dispatchPromise=new Promise((G)=>{Y=G}),this._dispatchSynchronized(J,Y)})}_dispatchSynchronized(Z,J){let Y=Promise.resolve();for(let G in Z)if(Z.hasOwnProperty(G))Y=Y.then(()=>{return this._dispatchReply(Z[G])});Y=Y.then(()=>{J()})}_dispatchReply(Z){let J,Y=new Promise((Q)=>{J=Q});if(Z===void 0||Z===null)return this._debug("dispatch: got undefined or null reply"),J(),Y;let G=Z.id;if(G&&G>0)this._handleReply(Z,J);else if(!Z.push)this._handleServerPing(J);else this._handlePush(Z.push,J);return Y}_call(Z,J){return new Promise((Y,G)=>{if(Z.id=this._nextCommandId(),this._registerCall(Z.id,Y,G),!J)this._addCommand(Z)})}_startConnecting(){if(this._debug("start connecting"),this._setState(h.Connecting))this.emit("connecting",{code:c1.connectCalled,reason:"connect called"});this._client=null,this._startReconnecting()}_disconnect(Z,J,Y){if(this._isDisconnected())return;this._transportIsOpen=!1;let G=this.state;this._reconnecting=!1;let Q={code:Z,reason:J},X=!1;if(Y)X=this._setState(h.Connecting);else X=this._setState(h.Disconnected),this._rejectPromises({code:_.clientDisconnected,message:"disconnected"});if(this._clearOutgoingRequests(),G===h.Connecting)this._clearReconnectTimeout();if(G===h.Connected)this._clearConnectedState();if(X)if(this._isConnecting())this.emit("connecting",Q);else this.emit("disconnected",Q);if(this._transport){this._debug("closing existing transport");let W=this._transport;this._transport=null,W.close(),this._transportClosed=!0,this._nextTransportId()}else this._debug("no transport to close");this._scheduleReconnect()}_failUnauthorized(){this._disconnect(o0.unauthorized,"unauthorized",!1)}_getToken(){if(this._debug("get connection token"),!this._config.getToken)return this.emit("error",{type:"configuration",error:{code:_.badConfiguration,message:"token expired but no getToken function set in the configuration"}}),Promise.reject(new I1(""));return this._config.getToken({})}_refresh(){let Z=this._client,J=this;this._getToken().then(function(Y){if(Z!==J._client)return;if(!Y){J._failUnauthorized();return}if(J._token=Y,J._debug("connection token refreshed"),!J._isConnected())return;let G={refresh:{token:J._token}};J._call(G,!1).then((Q)=>{let X=Q.reply.refresh;if(J._refreshResponse(X),Q.next)Q.next()},(Q)=>{if(J._refreshError(Q.error),Q.next)Q.next()})}).catch(function(Y){if(!J._isConnected())return;if(Y instanceof I1){J._failUnauthorized();return}J.emit("error",{type:"refreshToken",error:{code:_.clientRefreshToken,message:Y!==void 0?Y.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 n5(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(),o5(Z.ttl))}_removeSubscription(Z){if(Z===null)return;delete this._subs[Z.channel]}_unsubscribe(Z){if(!this._transportIsOpen)return Promise.resolve();let Y={unsubscribe:{channel:Z.channel}},G=this;return new Promise((X,W)=>{this._call(Y,!1).then((H)=>{if(X(),H.next)H.next()},(H)=>{if(X(),H.next)H.next();G._disconnect(c1.unsubscribeError,"unsubscribe error",!0)})})}_getSub(Z,J){if(J&&J>0){for(let G in this._subs)if(this._subs.hasOwnProperty(G)){let Q=this._subs[G];if(Q._id===J)return Q}return null}let Y=this._subs[Z];if(!Y)return null;return Y}_isServerSub(Z){return this._serverSubs[Z]!==void 0}_sendSubscribeCommands(){let Z=[];for(let J in this._subs){if(!this._subs.hasOwnProperty(J))continue;let Y=this._subs[J];if(Y._inflight===!0)continue;if(Y.state===a.Subscribing){let G=Y._subscribe();if(G)Z.push(G)}}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(h.Connected),this._refreshTimeout)clearTimeout(this._refreshTimeout);if(Z.expires)this._refreshTimeout=setTimeout(()=>this._refresh(),o5(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 Y=Z[J];this._serverSubs[J]={offset:Y.offset,epoch:Y.epoch,recoverable:Y.recoverable||!1};let G=this._getSubscribeContext(J,Y);this.emit("subscribed",G)}for(let J in Z){if(!Z.hasOwnProperty(J))continue;let Y=Z[J];if(Y.recovered){let G=Y.publications;if(G&&G.length>0){for(let Q in G)if(G.hasOwnProperty(Q))this._handlePublication(J,G[Q])}}}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(c1.noPing,"no ping",!0)},this._serverPing+this._config.maxServerPingDelay)}_getSubscribeContext(Z,J){let Y={channel:Z,positioned:!1,recoverable:!1,wasRecovering:!1,recovered:!1,hasRecoveredPublications:!1};if(J.recovered)Y.recovered=!0;if(J.positioned)Y.positioned=!0;if(J.recoverable)Y.recoverable=!0;if(J.was_recovering)Y.wasRecovering=!0;let G="";if("epoch"in J)G=J.epoch;let Q=0;if("offset"in J)Q=J.offset;if(Y.positioned||Y.recoverable)Y.streamPosition={offset:Q,epoch:G};if(Array.isArray(J.publications)&&J.publications.length>0)Y.hasRecoveredPublications=!0;if(J.data)Y.data=J.data;return Y}_handleReply(Z,J){let Y=Z.id;if(!(Y in this._callbacks)){J();return}let G=this._callbacks[Y];if(clearTimeout(this._callbacks[Y].timeout),delete this._callbacks[Y],!YK(Z)){let Q=G.callback;if(!Q)return;Q({reply:Z,next:J})}else{let Q=G.errback;if(!Q){J();return}let X={code:Z.error.code,message:Z.error.message||"",temporary:Z.error.temporary||!1};Q({error:X,next:J})}}_handleJoin(Z,J,Y){let G=this._getSub(Z,Y);if(!G&&Z){if(this._isServerSub(Z)){let Q={channel:Z,info:this._getJoinLeaveContext(J.info)};this.emit("join",Q)}return}G._handleJoin(J)}_handleLeave(Z,J,Y){let G=this._getSub(Z,Y);if(!G&&Z){if(this._isServerSub(Z)){let Q={channel:Z,info:this._getJoinLeaveContext(J.info)};this.emit("leave",Q)}return}G._handleLeave(J)}_handleUnsubscribe(Z,J){let Y=this._getSub(Z,0);if(!Y&&Z){if(this._isServerSub(Z))delete this._serverSubs[Z],this.emit("unsubscribed",{channel:Z});return}if(J.code<2500)Y._setUnsubscribed(J.code,J.reason,!1);else Y._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,Y=!0;if(J>=3500&&J<4000||J>=4500&&J<5000)Y=!1;this._disconnect(J,Z.reason,Y)}_getPublicationContext(Z,J){let Y={channel:Z,data:J.data};if(J.offset)Y.offset=J.offset;if(J.info)Y.info=this._getJoinLeaveContext(J.info);if(J.tags)Y.tags=J.tags;return Y}_getJoinLeaveContext(Z){let J={client:Z.client,user:Z.user},Y=Z.conn_info;if(Y)J.connInfo=Y;let G=Z.chan_info;if(G)J.chanInfo=G;return J}_handlePublication(Z,J,Y){let G=this._getSub(Z,Y);if(!G&&Z){if(this._isServerSub(Z)){let Q=this._getPublicationContext(Z,J);if(this.emit("publication",Q),J.offset!==void 0)this._serverSubs[Z].offset=J.offset}return}G._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:Y,id:G}=Z;if(Z.pub)this._handlePublication(Y,Z.pub,G);else if(Z.message)this._handleMessage(Z.message);else if(Z.join)this._handleJoin(Y,Z.join,G);else if(Z.leave)this._handleLeave(Y,Z.leave,G);else if(Z.unsubscribe)this._handleUnsubscribe(Y,Z.unsubscribe);else if(Z.subscribe)this._handleSubscribe(Y,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,Y){let G={code:Z,message:J};if(Y)G.temporary=!0;return G}_registerCall(Z,J,Y){this._callbacks[Z]={callback:J,errback:Y,timeout:null},this._callbacks[Z].timeout=setTimeout(()=>{if(delete this._callbacks[Z],NY(Y))Y({error:this._createErrorObject(_.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]}}}Y0.SubscriptionState=a;Y0.State=h;Y0.UnauthorizedError=I1;var s5=(Z,J)=>{async function Y(){let G=await fetch(Z+"api/centrifuge/gen_token");if(!G.ok){if(G.status===403)throw new Y0.UnauthorizedError("Backend is not answering");throw Error(`Unexpected status code ${G.status}`)}return(await G.json()).token}return J?new Y0(J||"",{getToken:Y}):null},zK=HK(null),p1=zK;import{useContext as BK,useEffect as KK}from"react";import{useEffect as UK,useState as xY}from"react";function r5(Z,J){let[Y,G]=xY(null),[Q,X]=xY(!1);return UK(()=>{if(!Q)X(!0),fetch(Z+`api/support/${J}`,{method:"GET"}).then((W)=>W.json()).then((W)=>{G(W)})},[]),Y}var LK=({children:Z})=>{let J=BK(d1),Y=v1(),G=r5(Y,"socketIO"),Q=(X)=>{if(typeof window<"u")window.sid=X.sid,console.log(`SocketIO initialized: ${window.sid}`)};return KK(()=>{if(!J)return;let X=()=>{console.log("SocketIO connected")},W=(H)=>{console.log(`SocketIO disconnected: ${H}`),J.connect()};if(G)J.on("pieinit",Q),J.on("connect",X),J.on("disconnect",W),J.connect();return()=>{if(G)J.off("pieinit",Q),J.off("connect",X),J.off("disconnect",W),J.disconnect()}},[J,G]),Z},t5=LK;import{useContext as MK,useEffect as $K}from"react";var FK=({children:Z})=>{let J=MK(p1),Y=v1(),G=r5(Y,"centrifuge");return $K(()=>{if(!J)return;let Q=()=>{console.log("Centrifuge connected")},X=(W)=>{console.log("Centrifuge disconnected:",W)};if(G)J.on("connected",Q),J.on("disconnected",X),J.connect();return()=>{if(G)J.disconnect()}},[J,G]),Z},e5=FK;var kX=S(S9(),1);import{useContext as x9,useEffect as f9}from"react";var WM=({card:Z,data:J,children:Y,useSocketioSupport:G=!1,useCentrifugeSupport:Q=!1,useMittSupport:X=!1,centrifugeChannel:W=void 0,methods:H=void 0})=>{let z=h1();if(z)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:G,centrifuge:Q,mitt:X,centrifugeChannel:W}),console.log("[PieCard] Methods:",H?Object.keys(H):"none"),console.log("[PieCard] Has children:",!!Y);let U=x9(d1),B=x9(p1),L=x9(m1);if(f9(()=>{if(!U||!G||!H||!J.name){if(z&&G)console.log("[PieCard] Socket.IO setup skipped:",{hasSocket:!!U,useSocketioSupport:G,hasMethods:!!H,hasDataName:!!J?.name});return}return Object.entries(H).forEach(([F,M])=>{let K=`pie${F}_${J.name}`;if(z)console.log(`[PieCard] Socket.IO registering event: ${K}`);U.on(K,M)}),()=>{Object.entries(H).forEach(([F,M])=>{let K=`pie${F}_${J.name}`;if(z)console.log(`[PieCard] Socket.IO unregistering event: ${K}`);U.off(K,M)})}},[U,H,J.name]),f9(()=>{if(!B||!Q||!W||!H||!J.name){if(z&&Q)console.log("[PieCard] Centrifuge setup skipped:",{hasCentrifuge:!!B,useCentrifugeSupport:Q,hasCentrifugeChannel:!!W,hasMethods:!!H,hasDataName:!!J?.name});return}let F=Object.entries(H).map(([M,K])=>{let $=`pie${M}_${J.name}_${W}`;if(z)console.log(`[PieCard] Centrifuge subscribing to channel: ${$}`);let V=B.newSubscription($);return V.on("publication",(N)=>{if(z)console.log(`[PieCard] Centrifuge received data on ${$}:`,N.data);K(N.data)}),V.subscribe(),V});return()=>{F.forEach((M)=>{if(z)console.log("[PieCard] Centrifuge unsubscribing from channel");M.unsubscribe(),B.removeSubscription(M)})}},[B,W,H,J.name]),f9(()=>{if(!L||!X||!H||!J.name){if(z&&X)console.log("[PieCard] Mitt setup skipped:",{hasMitt:!!L,useMittSupport:X,hasMethods:!!H,hasDataName:!!J?.name});return}return Object.entries(H).forEach(([F,M])=>{let K=`pie${F}_${J.name}`;if(z)console.log(`[PieCard] Mitt registering event: ${K}`);L.on(K,M)}),()=>{Object.entries(H).forEach(([F,M])=>{let K=`pie${F}_${J.name}`;if(z)console.log(`[PieCard] Mitt unregistering event: ${K}`);L.off(K,M)})}},[L,H,J.name]),z)console.log("[PieCard] Rendering complete, returning children");return Y},d=WM;function $6(Z){if(!Z)return{};let J={...Z};if("animationName"in J&&typeof J.animationName==="object"){let Y="radiumAnimation_"+Math.random().toString(36).substring(2,8);J.animationName=e.keyframes(J.animationName,Y)}return J}import{jsx as C9}from"react/jsx-runtime";var HM=({data:Z,content:J,setUiAjaxConfiguration:Y})=>{let{name:G,sx:Q}=Z;return C9(d,{card:G,data:Z,children:C9("div",{style:$6(Q),id:G,children:J.map((X,W)=>{return C9(Y1,{uiConfig:X,setUiAjaxConfiguration:Y},`children-${W}`)})})})},oG=e(HM);import{jsx as aG}from"react/jsx-runtime";var zM=({data:Z,content:J,setUiAjaxConfiguration:Y})=>{let{name:G}=Z;return aG(d,{card:G,data:Z,children:J.map((Q,X)=>{return aG(Y1,{uiConfig:Q,setUiAjaxConfiguration:Y},`children-${X}`)})})},sG=zM;import{useContext as rG,useEffect as UM,useRef as BM,useState as tG}from"react";import{jsx as eG}from"react/jsx-runtime";var KM=({data:Z,content:J})=>{let{useLoader:Y,noReturn:G,returnType:Q,useSocketioSupport:X,useCentrifugeSupport:W,useMittSupport:H,centrifugeChannel:z}=Z,U=rG(k1),[B,L]=tG(!1),[F,M]=tG(null),K=BM(J),$=rG(m1),V=(D)=>{if(D===null)L(!0);else if(L(!1),!G)K.current=D;if(!G)M(D)},N=(D)=>{K.current=D.content,M(D.content)},P=(D)=>{if(D===null)L(!0);else if(L(!1),!G)for(let q of D)$.emit(q.name,q.data)};if(UM(()=>{M(J),L(!1)},[J]),!F&&Y)return U;return eG(d,{card:"AjaxGroupCard",data:Z,methods:{changeContent:N},useSocketioSupport:X,useCentrifugeSupport:W,useMittSupport:H,centrifugeChannel:z,children:eG(Y1,{uiConfig:F??K.current,setUiAjaxConfiguration:Q==="events"?P:V})})},ZQ=e(KM);function j9(Z=1000){return new Promise((J)=>{if(typeof window>"u"){J();return}let Y=()=>{if(typeof window.sid<"u")J();else setTimeout(Y,Z)};Y()})}import{useMemo as LM}from"react";var MM=(Z,J={},Y=[],G,Q)=>{let X=Q?.renderingLogEnabled??!1,W=Q?.apiServer??"";if(X)console.log("Registering AJAX: ",G,J,Y);if(!G||!Z){if(X)console.warn("Registration FAILED: pathname or setUiAjaxConfiguration is missing!");return()=>{}}return async(H={})=>{if(typeof window>"u"||typeof document>"u"){if(X)console.warn("getAjaxSubmit called on server, skipping DOM-dependent logic");return}if(Y.includes("sid"))await j9();let z=new FormData;for(let[B,L]of Object.entries({...J,...H}))z.append(B,L);for(let B of Y)if(B==="sid"){if(!window.sid)throw Error("SocketIO isn't initialized properly");z.append("sid",window.sid)}else{let L=document.getElementsByName(B);if(!L.length){if(X)console.warn(`No input found with name ${B}`);continue}let F=L[0];if(F instanceof HTMLInputElement)if(F.type==="file"&&F.files)Array.from(F.files).forEach((M)=>z.append(B,M));else z.append(B,F.value);else if(F instanceof HTMLTextAreaElement)z.append(B,F.value)}let U=W+"api/ajax_content"+G;return Z(null),await fetch(U,{method:"POST",body:z}).then(async(B)=>{let F=(B.headers.get("content-type")||"").includes("application/json");if(!!B.body?.getReader&&!F){let K=B.body.getReader(),$=new TextDecoder,V="";while(!0){let{done:N,value:P}=await K.read();if(N)break;V+=$.decode(P,{stream:!0});let D=V.split(`
|
|
29
|
-
`);V=D.pop()??"";for(let q of D){let T=q.trim();if(!T)continue;try{let f=JSON.parse(T);Z([f])}catch(f){if(X)console.warn("Failed to parse streamed line:",T)}}}if(V.trim())try{let N=JSON.parse(V);Z([N])}catch(N){if(X)console.warn("Failed to parse final streamed line:",V)}return{}}else{let K=await B.json();return Z(K),K}}).catch((B)=>{if(X)console.error("AJAX request failed:",B);return Z(null),B})}},Y5=(Z,J={},Y=[],G)=>{let{apiServer:Q,enableRenderingLog:X}=z0();return LM(()=>MM(Z,J,Y,G,{apiServer:Q,renderingLogEnabled:X}),[Z,J,Y,G,Q,X])};var e9=S(t9(),1),W0=S(t9(),1),T0=e9.default.default||e9.default;import{jsx as Z7,jsxs as B$}from"react/jsx-runtime";var U$=({data:Z,setUiAjaxConfiguration:J})=>{let{name:Y,title:G,iconUrl:Q,iconPosition:X,sx:W,pathname:H,kwargs:z,depsNames:U}=Z,B=Y5(J,z,U,H);return Z7(d,{card:"AjaxButtonCard",data:Z,children:B$("button",{id:Y,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:Y,onClick:()=>B(),style:$6(W),type:"button",children:[Q&&X==="start"&&Z7("img",{src:Q,alt:""}),T0(G),Q&&X==="end"&&Z7("img",{src:Q,alt:""})]})})},QX=e(U$);import{forwardRef as j$,useEffect as DX,useImperativeHandle as _$,useRef as k$,useState as T6}from"react";import{useRef as K$,useState as L$}from"react";import{jsx as M$}from"react/jsx-runtime";function J7(Z){let[J,Y]=L$(!1),G=K$(null);return M$("textarea",{ref:G,...Z,onKeyUp:()=>{Y(!1)},onKeyDown:(H)=>{if(H.key==="Enter"&&H.shiftKey){if(Y(!0),G.current&&typeof window<"u"){let z=window.getComputedStyle(G.current),U=parseFloat(z.lineHeight);G.current.style.height=G.current.scrollHeight+U+"px"}}if(H.key==="Backspace"){if(Y(!0),G.current&&typeof window<"u"){let z=window.getComputedStyle(G.current),U=parseFloat(z.lineHeight);if(G.current.scrollHeight>U)G.current.style.height=G.current.scrollHeight-U+"px"}}Z.onKeyDown&&Z.onKeyDown(H)},onBlur:(H)=>{Y(!1),Z.onBlur&&Z.onBlur(H)},style:{resize:J?"vertical":"none",overflowY:"auto",...Z.style}})}import{useRef as F$,useCallback as O$}from"react";import{jsx as XX}from"react/jsx-runtime";var $$=()=>XX("svg",{xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24",strokeWidth:"1.5",stroke:"currentColor",className:"size-5",children:XX("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"})}),WX=$$;import{jsx as Y7}from"react/jsx-runtime";var V$=({type:Z="button",onClick:J,icons:Y})=>{let G=F$(null),Q=O$(()=>{let W=G.current;if(W)W.style.transform="scale(0.8)",setTimeout(()=>{W.style.transform="scale(1)"},600)},[]);return Y7("button",{ref:G,type:Z,onClick:(W)=>{if(J)J(W);Q()},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:Y.sendIcon?Y7("img",{src:Y.sendIcon,alt:""}):Y7(WX,{})})},HX=V$;import{jsx as zX}from"react/jsx-runtime";var I$=()=>zX("svg",{xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24",strokeWidth:"1.5",stroke:"currentColor",className:"size-5",children:zX("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"})}),UX=I$;import{jsx as A6,jsxs as N$,Fragment as D$}from"react/jsx-runtime";var q$=({name:Z,accept:J,fileInputRef:Y,onSelectFile:G,icons:Q})=>{return N$(D$,{children:[A6("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(Y.current)Y.current.click()},children:Q.attachFileIcon?A6("img",{src:Q.attachFileIcon,alt:""}):A6(UX,{})}),A6("input",{id:Z+"__pie__file",name:Z+"__pie__file",className:"hidden",type:"file",accept:J,ref:Y,onChange:(X)=>{if(X.target.files)G(X.target.files[0])}})]})},BX=q$;import{jsx as KX}from"react/jsx-runtime";var A$=()=>KX("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:KX("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"})}),LX=A$;import{jsx as MX}from"react/jsx-runtime";var R$=()=>MX("svg",{xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24",strokeWidth:"1.5",stroke:"currentColor",className:"size-5",children:MX("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M6 18L18 6M6 6l12 12"})}),R6=R$;import{jsx as K5,jsxs as T$}from"react/jsx-runtime";var P$=({name:Z,selectedFile:J,onDropFile:Y})=>{return T$("div",{className:"flex w-full cursor-default flex-row items-center gap-2",children:[K5(LX,{}),K5("span",{className:"flex-1",children:J.name}),K5("input",{type:"hidden",name:Z,value:""}),K5("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:Y,children:K5(R6,{})})]})},$X=P$;import{jsx as FX,jsxs as E$}from"react/jsx-runtime";var w$=()=>E$("svg",{xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24",strokeWidth:"1.5",stroke:"currentColor",className:"size-5",children:[FX("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"}),FX("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"})]}),OX=w$;import{jsx as L5}from"react/jsx-runtime";var S$=({isListening:Z,toggleListening:J,icons:Y})=>{return L5("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?Y.cancelIcon?L5("img",{src:Y.cancelIcon,alt:""}):L5(R6,{}):Y.voiceRecordingIcon?L5("img",{src:Y.voiceRecordingIcon,alt:""}):L5(OX,{})})},VX=S$;import{jsx as IX,jsxs as f$}from"react/jsx-runtime";var x$=({option:Z,onClickOption:J})=>{return f$("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"&&IX("img",{src:Z.iconUrl,alt:""}),Z.title,Z.iconPosition==="end"&&IX("img",{src:Z.iconUrl,alt:""})]})},P6=x$;import{jsx as qX}from"react/jsx-runtime";var C$=({options:Z,handleOptionClick:J})=>{return qX("div",{className:"flex w-full flex-row flex-wrap justify-start gap-[5px]",children:Z.map((Y,G)=>{return qX(P6,{option:Y,onClickOption:J},G)})})},G7=C$;import{jsx as S1,jsxs as NX}from"react/jsx-runtime";var v$=j$(({name:Z,defaultValue:J,defaultOptions:Y,isArea:G,placeholder:Q,fileAccept:X,optionsPosition:W,icons:H,handleOptionClick:z,handleSendMessage:U,sx:B},L)=>{let F=k$(null),[M,K]=T6(null),[$,V]=T6(J),[N,P]=T6(Y),[D,q]=T6(!1);_$(L,()=>({clear:()=>{if(V(""),K(null),F.current)F.current.value=""},setValue:(f)=>V(f),setOptions:(f)=>P(f)})),DX(()=>{V(J)},[J]),DX(()=>{},[]);let T=()=>{};return NX("div",{className:"flex flex-col items-center gap-[0.1rem]",id:Z+"_chat_input",style:B,children:[N&&W==="top"&&S1(G7,{options:N,handleOptionClick:z}),S1("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:NX("div",{className:"flex w-full grow flex-row items-center rounded-md bg-transparent",children:[M?S1($X,{name:Z,selectedFile:M,onDropFile:()=>{if(K(null),F.current)F.current.value=""}}):!G?S1("input",{name:Z,value:$,onChange:(f)=>V(f.target.value),onKeyDown:(f)=>{if(f.key==="Enter")f.preventDefault(),U()},tabIndex:0,placeholder:Q,className:"m-0 w-full resize-none border-0 bg-transparent outline-none",style:{maxHeight:200,height:"100%",overflowY:"hidden"}}):S1(J7,{name:Z,value:$,onChange:(f)=>V(f.target.value),onKeyDown:(f)=>{if(f.key==="Enter"&&!f.shiftKey)f.preventDefault(),U()},tabIndex:0,rows:2,placeholder:Q,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}}),S1(VX,{isListening:D,toggleListening:T,icons:H}),S1(BX,{name:Z,fileInputRef:F,accept:X,onSelectFile:K,icons:H}),S1(HX,{onClick:U,icons:H})]})}),N&&W==="bottom"&&S1(G7,{options:N,handleOptionClick:z})]})}),AX=v$;import{useState as d$,useEffect as c$}from"react";import{useEffect as h$,useState as b$}from"react";import{jsx as g$}from"react/jsx-runtime";function y$({children:Z}){let[J,Y]=b$(Z);return h$(()=>{Y(Z)},[Z]),g$("div",{className:"max-w-full first:mt-0",children:J})}var RX=y$;import{jsx as PX}from"react/jsx-runtime";var m$=()=>PX("svg",{width:"30",height:"30",viewBox:"0 0 16 16",xmlns:"http://www.w3.org/2000/svg",children:PX("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"})}),TX=m$;import{jsx as w6}from"react/jsx-runtime";function u$({username:Z,avatar:J}){return w6("div",{className:"w-[30px]",children:w6("div",{className:"relative flex size-[30px] items-center justify-center rounded-sm p-1 text-white",children:J?w6("img",{src:J,className:"absolute inset-0 rounded",alt:Z}):w6(TX,{})})})}var Q7=u$;import{jsx as N1,jsxs as wX}from"react/jsx-runtime";var p$=({message:Z,handleOptionClick:J,setUiAjaxConfiguration:Y})=>{let[G,Q]=d$(!1);return c$(()=>{let X=setTimeout(()=>{if(G)Q(!1)},1000);return()=>clearTimeout(X)},[G]),N1("div",{className:"group w-full border-b border-black/10",id:Z.id,children:wX("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")&&N1("div",{className:"relative flex shrink-0 flex-col items-end",children:N1(Q7,{username:Z.username,avatar:Z.avatar})}),wX("div",{className:"relative flex w-[calc(100%-50px)] flex-col gap-1 md:gap-3 lg:w-[calc(100%-115px)]",children:[N1("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"?N1(RX,{children:Z.content},Date.now()+Math.random()):Z.parseMode.toLowerCase()==="html"?T0(Z.content):Z.content:N1(Y1,{uiConfig:Z.content,setUiAjaxConfiguration:Y})}),N1("div",{className:"flex flex-row flex-wrap justify-start gap-1",children:Z.options.map((X,W)=>N1(P6,{onClickOption:J,option:X},W))})]}),Z.align==="right"&&N1("div",{className:"relative flex shrink-0 flex-col items-end",children:N1(Q7,{username:Z.username,avatar:Z.avatar})})]})})},EX=p$;import{forwardRef as l$,useEffect as i$,useImperativeHandle as n$,useRef as o$,useState as a$}from"react";import{jsx as SX}from"react/jsx-runtime";var s$=l$(({name:Z,handleOptionClick:J,defaultMessages:Y,sx:G,setUiAjaxConfiguration:Q},X)=>{let[W,H]=a$(Y),z=o$(null),U=()=>{if(z.current)z.current.scrollTop=z.current.scrollHeight};return i$(()=>{U()},[W]),n$(X,()=>({setMessages:(B)=>H(B),addMessage:(B)=>H((L)=>[...L,B]),scrollToBottom:U})),SX("div",{id:Z+"_messages",className:"flex flex-col items-center overflow-y-scroll",style:G,ref:z,children:W.map((B)=>SX(EX,{message:B,handleOptionClick:J,setUiAjaxConfiguration:Q},B.id))})}),xX=s$;import{useEffect as r$,useRef as fX,useState as t$}from"react";import{jsx as X7,jsxs as ZF}from"react/jsx-runtime";var e$=({data:Z,setUiAjaxConfiguration:J})=>{let{name:Y,defaultValue:G,defaultMessages:Q,defaultOptions:X,isArea:W,fileAccept:H,placeholder:z,icons:U,optionsPosition:B,sxMap:L={container:{},chatInput:{},messages:{}},depsNames:F,pathname:M,kwargs:K,useSocketioSupport:$,useCentrifugeSupport:V,centrifugeChannel:N}=Z,P=fX(null),D=fX(null),[q,T]=t$(!1),f=Y5(J,K,F,M);r$(()=>{if(q)requestAnimationFrame(()=>{f(),T(!1)})},[q]);let m=(p)=>{if(P.current)P.current.setValue(p),T(!0)},o1=()=>{if(P.current)P.current.clear()},f1=(p)=>{if(P.current)P.current.setOptions(p.options)},C1=(p)=>{if(D.current)D.current.addMessage(p.message)},k=(p)=>{if(D.current)D.current.setMessages(p.messages)},A1=()=>{T(!0)};return X7(d,{card:"ChatCard",data:Z,methods:{clearInput:o1,setOptions:f1,addMessage:C1,setMessages:k},useSocketioSupport:$,useCentrifugeSupport:V,centrifugeChannel:N,children:ZF("div",{className:"flex size-full flex-col",style:L.container,children:[X7(xX,{ref:D,name:Y,defaultMessages:Q,sx:L.messages,handleOptionClick:m,setUiAjaxConfiguration:J}),X7(AX,{ref:P,name:Y,isArea:W,defaultOptions:X,placeholder:z,defaultValue:G,fileAccept:H,sx:L.chatInput,handleSendMessage:A1,handleOptionClick:m,optionsPosition:B,icons:U})]})})},CX=e$;import{useEffect as JF,useState as YF}from"react";import{jsx as jX}from"react/jsx-runtime";var GF=({data:Z})=>{let{name:J,value:Y,useSocketioSupport:G,useCentrifugeSupport:Q,useMittSupport:X,centrifugeChannel:W}=Z,[H,z]=YF(Y);return JF(()=>{z(Y)},[Y]),jX(d,{card:"HiddenCard",data:Z,useSocketioSupport:G,useCentrifugeSupport:Q,useMittSupport:X,centrifugeChannel:W,methods:{update:({value:U})=>{z(U)}},children:jX("input",{type:"hidden",id:J,name:J,value:H})})},W7=GF;import{useContext as WF,useEffect as HF}from"react";import{createContext as QF}from"react";var XF=QF(void 0),n1=XF;import{jsx as BF,Fragment as UF}from"react/jsx-runtime";var zF=({data:Z})=>{let{url:J}=Z,Y=WF(n1);return HF(()=>{if(/^[a-zA-Z][a-zA-Z\d+\-.]*:\/\//.test(J))window.location.href=J;else Y?.(J)},[J,Y]),BF(UF,{})},H7=zF;import{useEffect as $F,useState as FF}from"react";import{useCallback as E6,useEffect as KF,useRef as z7,useState as LF}from"react";function MF(){let Z=new AudioContext,J=Z.createOscillator(),Y=J.connect(Z.createMediaStreamDestination());J.start();let G=Y.stream.getAudioTracks()[0];return G.enabled=!1,G}function U7(Z=null,J){let[Y,G]=LF(!1),Q=z7(null),X=z7(null),W=z7(null),H=E6(async(L,F=!0)=>{if(Q.current)z();let M=new RTCPeerConnection;if(M.onconnectionstatechange=()=>{if(M.connectionState==="connected")G(!0);else if(["disconnected","failed","closed"].includes(M.connectionState))G(!1)},M.ontrack=(q)=>{if(Z)Z.srcObject=q.streams[0]},F){let q=await navigator.mediaDevices.getUserMedia({audio:!0});M.addTrack(q.getTracks()[0],q)}else{let q=MF();M.addTrack(q)}let K=M.createDataChannel("oai-events");X.current=K,W.current=new Promise((q)=>{K.addEventListener("open",()=>{q()})});let $=await M.createOffer();await M.setLocalDescription($);let D=await(await fetch(`${"https://api.openai.com/v1/realtime/calls"}?model=${"gpt-realtime"}`,{method:"POST",body:$.sdp,headers:{Authorization:`Bearer ${L}`,"Content-Type":"application/sdp"}})).text();await M.setRemoteDescription({type:"answer",sdp:D}),Q.current=M,await W.current},[Z]),z=E6(()=>{let L=X.current;if(L)L.close();Q.current?.getSenders()?.forEach((F)=>F.track?.stop()),Q.current?.close(),G(!1),Q.current=null,X.current=null,W.current=null},[Z]),U=E6((L)=>{let F=X.current;if(!F){console.error("Data channel is not ready",L);return}let M=new Date().toLocaleTimeString();if(L.event_id=L.event_id||crypto.randomUUID(),F.send(JSON.stringify(L)),!L.timestamp)L.timestamp=M;J?.(L)},[J,Z]),B=E6((L)=>{if(!X.current){console.error("Data channel is not ready");return}let M=()=>{U({type:"conversation.item.create",item:{type:"message",role:"user",content:[{type:"input_text",text:L}]}}),U({type:"response.create"})};if(W.current)W.current.then(M);else M()},[J,Z]);return KF(()=>{let L=X.current;if(!L)return;let F=(M)=>{let K=JSON.parse(M.data);if(!K.timestamp)K.timestamp=new Date().toLocaleTimeString();J?.(K)};return L.addEventListener("message",F),()=>{L.removeEventListener("message",F)}},[J,Z]),{isSessionActive:Y,startSession:H,stopSession:z,sendTextMessage:B}}import{jsx as VF}from"react/jsx-runtime";var OF=({data:Z})=>{let{html:J,useSocketioSupport:Y,useCentrifugeSupport:G,useMittSupport:Q,centrifugeChannel:X}=Z,[W,H]=FF(J),{isSessionActive:z,startSession:U,sendTextMessage:B}=U7(null,(K)=>{if(console.log(K.type,K.type==="response.output_text.delta"&&K.delta),K.type==="response.output_text.delta"&&K.delta)H(($)=>$+K.delta)});return $F(()=>{H(J)},[J]),VF(d,{card:"HTMLEmbedCard",data:Z,methods:{update:(K)=>{H(K.value)},generateUsingAI:async(K)=>{try{if(!z&&K.token)await U(K.token,!1);B(K.prompt)}catch($){console.error("Failed to generate using AI",$)}},initializeAI:async(K)=>{if(!z&&K.token)await U(K.token,!1)}},useCentrifugeSupport:G,useSocketioSupport:Y,useMittSupport:Q,centrifugeChannel:X,children:T0(W)})},B7=e(OF);import{useContext as IF}from"react";import{jsx as K7,Fragment as _X}from"react/jsx-runtime";var qF=({data:Z})=>{let{useCentrifugeSupport:J,useSocketioSupport:Y,useMittSupport:G,centrifugeChannel:Q}=Z,X=IF(n1);return K7(_X,{children:K7(d,{card:"IOEventsCard",data:Z,useCentrifugeSupport:J,useSocketioSupport:Y,useMittSupport:G,centrifugeChannel:Q,methods:{log:(z)=>{console.log("Log event",z)},redirect:(z)=>{if(z.to){let U=z.to;if(/^[a-zA-Z][a-zA-Z\d+\-.]*:\/\//.test(U))window.location.href=U;else X?.(U)}else window.location.reload()}},children:K7(_X,{})})})},L7=qF;var M7=!1;function M5(){if(M7)return;L1({name:"SequenceCard",component:oG,metadata:{author:"PieData",description:"Simple div with styles joining few components"}}),L1({name:"UnionCard",component:sG,metadata:{author:"PieData",description:"Renders one of many components"}}),L1({name:"AjaxGroupCard",component:ZQ,metadata:{author:"PieData",description:"Group card with AJAX support"}}),L1({name:"AjaxButtonCard",component:QX,metadata:{author:"PieData",description:"Button with AJAX support"}}),L1({name:"ChatCard",component:CX,metadata:{author:"PieData"}}),L1({name:"HiddenCard",component:W7,metadata:{author:"PieData"}}),L1({name:"AutoRedirectCard",component:H7,metadata:{author:"PieData"}}),L1({name:"HTMLEmbedCard",component:B7,metadata:{author:"PieData"}}),L1({name:"IOEventsCard",component:L7,metadata:{author:"PieData"}}),M7=!0}function x1(){return M7}import{jsx as W1,Fragment as EF}from"react/jsx-runtime";var TF=({location:Z,fallback:J,onError:Y,initializePie:G})=>{let Q=v1(),X=F5(),W=h1();DF(()=>{if(x1())return;M5(),G()},[]);let H=NF(()=>kX.createAxiosDateTransformer({baseURL:Q||""}),[Q]),{data:z,isLoading:U,error:B}=PF({queryKey:["uiConfig",Z.pathname+Z.search,x1(),Q],queryFn:async()=>{if(!Q||!x1())return;let L="/api/content"+Z.pathname+Z.search;if(W)console.log("[PieRoot] Fetching UI configuration from:",L);let F=await H.get(L,{headers:{"Access-Control-Allow-Origin":"*","Access-Control-Allow-Methods":"GET,PUT,POST,DELETE,PATCH,OPTIONS","Content-type":"application/json"},withCredentials:!0});if(W)console.log("[PieRoot] Received UI configuration:",F.data);return F.data},staleTime:1/0,gcTime:1/0,refetchOnWindowFocus:!1,refetchOnMount:!1,refetchOnReconnect:!1,retry:!0,retryDelay:(L)=>Math.min(1000*2**L,30000)});if(!Q)return J??null;if(W)console.log("[PieRoot] Rendering with location:",Z),console.log("[PieRoot] API_SERVER:",Q),console.log("[PieRoot] Fallback provided:",!!J);if(B){if(W)console.error("[PieRoot] Error fetching UI configuration:",B),console.error("[PieRoot] Error details:",{message:B.message,status:B.response?.status,data:B.response?.data});return Y?.(),J}if(U||!z){if(W)console.log("[PieRoot] Loading state:",{isLoading:U,hasUiConfiguration:!!z});return J}if(W)console.log("[PieRoot] UI configuration loaded successfully:",z),console.log("[PieRoot] Rendering UI with configuration");return W1(m1.Provider,{value:k0,children:W1(d1.Provider,{value:c5(Q),children:W1(p1.Provider,{value:s5(Q,X),children:W1(k1.Provider,{value:J??W1(EF,{}),children:W1(t5,{children:W1(e5,{children:W1(e.StyleRoot,{style:{display:"contents"},children:W1(Y1,{uiConfig:z})})})})})})})})},wF=(Z)=>{let J=new AF;return W1(n1.Provider,{value:Z.onNavigate,children:W1(E0.Provider,{value:Z.config,children:W1(RF,{client:J,children:W1(TF,{...Z})})})})},SF=wF;import{useEffect as CF,useMemo as jF}from"react";import{QueryClient as _F,QueryClientProvider as kF,useQuery as vF}from"@tanstack/react-query";var hX=S(S9(),1);import{useEffect as xF,useState as fF}from"react";var vX=()=>{let[Z,J]=fF(null),Y=R7();return xF(()=>{if(typeof window>"u")return;let G=window.Telegram.WebApp;if(G.ready(),Y==="telegram_expanded"&&(G.platform==="ios"||G.platform==="android"))G.expand();J(G)},[]),Z};import{jsx as H1,Fragment as yF}from"react/jsx-runtime";var hF=({location:Z,fallback:J,onError:Y,initializePie:G})=>{let Q=v1(),X=F5(),W=h1();CF(()=>{if(x1())return;M5(),G()},[]);let H=jF(()=>hX.createAxiosDateTransformer({baseURL:Q}),[]);if(W)console.log("[PieRoot] Rendering with location:",Z),console.log("[PieRoot] API_SERVER:",Q),console.log("[PieRoot] Fallback provided:",!!J);if(!Q)throw Error("Set PIE_API_SERVER and PIE_CENTRIFUGE_SERVER");let z=vX(),{data:U,isLoading:B,error:L}=vF({queryKey:["uiConfig",Z.pathname+Z.search,z?.initData,x1()],queryFn:async()=>{if(!x1())return;let F=Z.search?"&":"?",M=z?.initData?`${F}initData=${encodeURIComponent(z.initData)}`:"",K="/api/content"+Z.pathname+Z.search+M;if(W)console.log("[PieRoot] Fetching UI configuration from:",K);let $=await H.get(K,{headers:{"Access-Control-Allow-Origin":"*","Access-Control-Allow-Methods":"GET,PUT,POST,DELETE,PATCH,OPTIONS","Content-type":"application/json"},withCredentials:!0});if(W)console.log("[PieRoot] Received UI configuration:",$.data);return $.data},staleTime:1/0,gcTime:1/0,refetchOnWindowFocus:!1,refetchOnMount:!1,refetchOnReconnect:!1,retry:!0,retryDelay:(F)=>Math.min(1000*2**F,30000)});if(L&&W)return console.error("[PieRoot] Error fetching UI configuration:",L),console.error("[PieRoot] Error details:",{message:L.message,status:L.response?.status,data:L.response?.data}),Y?.(),J;if(B||!U){if(W)console.log("[PieRoot] Loading state:",{isLoading:B,hasUiConfiguration:!!U});return J}if(W)console.log("[PieRoot] UI configuration loaded successfully:",U),console.log("[PieRoot] Rendering UI with configuration");return H1(m1.Provider,{value:k0,children:H1(d1.Provider,{value:c5(Q),children:H1(p1.Provider,{value:s5(Q,X),children:H1(k1.Provider,{value:J??H1(yF,{}),children:H1(t5,{children:H1(e5,{children:H1(e.StyleRoot,{children:H1(Y1,{uiConfig:U})})})})})})})})},bF=(Z)=>{let J=new _F;return H1(n1.Provider,{value:Z.onNavigate,children:H1(E0.Provider,{value:Z.config,children:H1(kF,{client:J,children:H1(hF,{...Z})})})})},gF=bF;export{Y5 as useAjaxSubmit,L1 as registerPieComponent,x1 as isPieComponentsInitialized,M5 as initializePieComponents,Y1 as UI,gF as PieTelegramRoot,SF as PieRoot,d as PieCard};
|
|
28
|
+
`).map((J)=>JSON.parse(J))}applyDeltaIfNeeded(Z,J){let Y,G;if(Z.delta){let Q=HK(J,new TextEncoder().encode(Z.data));Y=JSON.parse(new TextDecoder().decode(Q)),G=Q}else Y=JSON.parse(Z.data),G=new TextEncoder().encode(Z.data);return{newData:Y,newPrevValue:G}}}var zK={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 q1 extends Error{constructor(Z){super(Z);this.name=this.constructor.name}}class G0 extends RY{constructor(Z,J){super();if(this._reconnectTimeout=null,this._refreshTimeout=null,this._serverPingTimeout=null,this.state=h.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 z9,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({},zK),J),this._configure(),this._debugEnabled)this.on("state",(Y)=>{this._debug("client state",Y.oldState,"->",Y.newState)}),this.on("error",(Y)=>{this._debug("client error",Y)});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 Y=new TY(this,Z,J);return this._subs[Z]=Y,Y}getSubscription(Z){return this._getSub(Z)}removeSubscription(Z){if(!Z)return;if(Z.state!==r.Unsubscribed)Z.unsubscribe();this._removeSubscription(Z)}subscriptions(){return this._subs}ready(Z){return o(this,void 0,void 0,function*(){switch(this.state){case h.Disconnected:throw{code:_.clientDisconnected,message:"client disconnected"};case h.Connected:return;default:return new Promise((J,Y)=>{let G={resolve:J,reject:Y};if(Z)G.timeout=setTimeout(()=>{Y({code:_.timeout,message:"timeout"})},Z);this._promises[this._nextPromiseId()]=G})}})}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(a0.disconnectCalled,"disconnect called",!1)}setToken(Z){this._token=Z}setData(Z){this._data=Z}setHeaders(Z){this._config.headers=Z}send(Z){return o(this,void 0,void 0,function*(){let J={send:{data:Z}};if(yield this._methodCall(),!this._transportSendCommands([J]))throw this._createErrorObject(_.transportWriteError,"transport write error")})}rpc(Z,J){return o(this,void 0,void 0,function*(){let Y={rpc:{method:Z,data:J}};return yield this._methodCall(),{data:(yield this._callPromise(Y,(Q)=>Q.rpc)).data}})}publish(Z,J){return o(this,void 0,void 0,function*(){let Y={publish:{channel:Z,data:J}};return yield this._methodCall(),yield this._callPromise(Y,()=>({})),{}})}history(Z,J){return o(this,void 0,void 0,function*(){let Y={history:this._getHistoryRequest(Z,J)};yield this._methodCall();let G=yield this._callPromise(Y,(X)=>X.history),Q=[];if(G.publications)for(let X=0;X<G.publications.length;X++)Q.push(this._getPublicationContext(Z,G.publications[X]));return{publications:Q,epoch:G.epoch||"",offset:G.offset||0}})}presence(Z){return o(this,void 0,void 0,function*(){let J={presence:{channel:Z}};yield this._methodCall();let G=(yield this._callPromise(J,(Q)=>Q.presence)).presence;for(let Q in G)if(Object.prototype.hasOwnProperty.call(G,Q)){let X=G[Q],W=X.conn_info,H=X.chan_info;if(W)X.connInfo=W;if(H)X.chanInfo=H}return{clients:G}})}presenceStats(Z){return o(this,void 0,void 0,function*(){let J={presence_stats:{channel:Z}};yield this._methodCall();let Y=yield this._callPromise(J,(G)=>{return G.presence_stats});return{numUsers:Y.num_users,numClients:Y.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;YK("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 z9,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 Y=J.transport;if(["websocket","http_stream","sse","sockjs","webtransport"].indexOf(Y)<0)throw Error("unsupported transport name: "+Y)}}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===h.Disconnected}_isConnecting(){return this.state===h.Connecting}_isConnected(){return this.state===h.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===h.Connected||this.state===h.Connecting)this._disconnect(p1.transportClosed,"transport closed",!0),this._deviceWentOffline=!0}),Z.addEventListener("online",()=>{if(this._debug("online event triggered"),this.state!==h.Connecting)return;if(this._deviceWentOffline&&!this._transportClosed)this._deviceWentOffline=!1,this._transportClosed=!0;this._clearReconnectTimeout(),this._startReconnecting()}),this._networkEventsSet=!0}_getReconnectDelay(){let Z=o5(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 Y=J.errback;if(!Y)continue;Y({error:this._createErrorObject(_.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===r.Subscribed)J._setSubscribing(i5.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 Y=J.id;if(!(Y in this._callbacks))continue;let G=this._callbacks[Y];clearTimeout(this._callbacks[Y].timeout),delete this._callbacks[Y];let Q=G.errback;Q({error:this._createErrorObject(_.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 Y=null;if(this._config.eventsource!==null)Y=this._config.eventsource;else if(typeof globalThis.EventSource<"u")Y=globalThis.EventSource;let G=null;if(this._config.fetch!==null)G=this._config.fetch;else if(typeof globalThis.fetch<"u")G=globalThis.fetch;let Q=null;if(this._config.readableStream!==null)Q=this._config.readableStream;else if(typeof globalThis.ReadableStream<"u")Q=globalThis.ReadableStream;if(!this._emulation){if(JK(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 H9(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 F=0;while(!0){if(F>=this._transports.length)throw Error("no supported transport found");let M=this._transports[this._currentTransportIndex],K=M.transport,$=M.endpoint;if(K==="websocket"){if(this._debug("trying websocket transport"),this._transport=new H9($,{websocket:Z}),!this._transport.supported()){this._debug("websocket transport not available"),this._currentTransportIndex++,F++;continue}}else if(K==="webtransport"){if(this._debug("trying webtransport transport"),this._transport=new xY($,{webtransport:globalThis.WebTransport,decoder:this._codec,encoder:this._codec}),!this._transport.supported()){this._debug("webtransport transport not available"),this._currentTransportIndex++,F++;continue}}else if(K==="http_stream"){if(this._debug("trying http_stream transport"),this._transport=new EY($,{fetch:G,readableStream:Q,emulationEndpoint:this._config.emulationEndpoint,decoder:this._codec,encoder:this._codec}),!this._transport.supported()){this._debug("http_stream transport not available"),this._currentTransportIndex++,F++;continue}}else if(K==="sse"){if(this._debug("trying sse transport"),this._transport=new SY($,{eventsource:Y,fetch:G,emulationEndpoint:this._config.emulationEndpoint}),!this._transport.supported()){this._debug("sse transport not available"),this._currentTransportIndex++,F++;continue}}else if(K==="sockjs"){if(this._debug("trying sockjs"),this._transport=new wY($,{sockjs:J,sockjsOptions:this._config.sockjsOptions}),!this._transport.supported()){this._debug("sockjs transport not available"),this._currentTransportIndex++,F++;continue}}else throw Error("unknown transport "+K);break}}let X=this,W=this._transport,H=this._nextTransportId();X._debug("id of transport",H);let z=!1,U=[];if(this._transport.emulation()){let F=X._sendConnect(!0);U.push(F)}this._setNetworkEvents();let B=this._codec.encodeCommands(U);this._transportClosed=!1;let L;L=setTimeout(function(){W.close()},this._config.timeout),this._transport.initialize(this._codecName(),{onOpen:function(){if(L)clearTimeout(L),L=null;if(X._transportId!=H){X._debug("open callback from non-actual transport"),W.close();return}if(z=!0,X._debug(W.subName(),"transport open"),W.emulation())return;X._transportIsOpen=!0,X._transportWasOpen=!0,X.startBatching(),X._sendConnect(!1),X._sendSubscribeCommands(),X.stopBatching(),X.emit("__centrifuge_debug:connect_frame_sent",{})},onError:function(F){if(X._transportId!=H){X._debug("error callback from non-actual transport");return}X._debug("transport level error",F)},onClose:function(F){if(L)clearTimeout(L),L=null;if(X._transportId!=H){X._debug("close callback from non-actual transport");return}X._debug(W.subName(),"transport closed"),X._transportClosed=!0,X._transportIsOpen=!1;let M="connection closed",K=!0,$=0;if(F&&"code"in F&&F.code)$=F.code;if(F&&F.reason)try{let O=JSON.parse(F.reason);M=O.reason,K=O.reconnect}catch(O){if(M=F.reason,$>=3500&&$<4000||$>=4500&&$<5000)K=!1}if($<3000){if($===1009)$=a0.messageSizeLimit,M="message size limit exceeded",K=!1;else $=p1.transportClosed,M="transport closed";if(X._emulation&&!X._transportWasOpen){if(X._currentTransportIndex++,X._currentTransportIndex>=X._transports.length)X._triedAllTransports=!0,X._currentTransportIndex=0}}else X._transportWasOpen=!0;if(X._isConnecting()&&!z)X.emit("error",{type:"transport",error:{code:_.transportClosed,message:"transport closed"},transport:W.name()});X._reconnecting=!1,X._disconnect($,M,K)},onMessage:function(F){X._dataReceived(F)}},B),X.emit("__centrifuge_debug:transport_initialized",{})}_sendConnect(Z){let J=this._constructConnectCommand(),Y=this;return this._call(J,Z).then((G)=>{let Q=G.reply.connect;if(Y._connectResponse(Q),G.next)G.next()},(G)=>{if(Y._connectError(G.error),G.next)G.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((G)=>{if(!this._isConnecting())return;this._data=G,this._initializeTransport()}).catch((G)=>this._handleGetDataError(G));else this._initializeTransport();return}let Y=this;this._getToken().then(function(G){if(!Y._isConnecting())return;if(G==null||G==null){Y._failUnauthorized();return}if(Y._token=G,Y._debug("connection token refreshed"),Y._config.getData)Y._config.getData().then(function(Q){if(!Y._isConnecting())return;Y._data=Q,Y._initializeTransport()}).catch((Q)=>Y._handleGetDataError(Q));else Y._initializeTransport()}).catch(function(G){if(!Y._isConnecting())return;if(G instanceof q1){Y._failUnauthorized();return}Y.emit("error",{type:"connectToken",error:{code:_.clientConnectToken,message:G!==void 0?G.toString():""}});let Q=Y._getReconnectDelay();Y._debug("error on getting connection token, reconnect after "+Q+" milliseconds",G),Y._reconnecting=!1,Y._reconnectTimeout=setTimeout(()=>{Y._startReconnecting()},Q)})}_handleGetDataError(Z){if(Z instanceof q1){this._failUnauthorized();return}this.emit("error",{type:"connectData",error:{code:_.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!==h.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={},Y=!1;for(let G in this._serverSubs)if(this._serverSubs.hasOwnProperty(G)&&this._serverSubs[G].recoverable){Y=!0;let Q={recover:!0};if(this._serverSubs[G].offset)Q.offset=this._serverSubs[G].offset;if(this._serverSubs[G].epoch)Q.epoch=this._serverSubs[G].epoch;J[G]=Q}if(Y)Z.subs=J;return{connect:Z}}_getHistoryRequest(Z,J){let Y={channel:Z};if(J!==void 0){if(J.since){if(Y.since={offset:J.since.offset},J.since.epoch)Y.since.epoch=J.since.epoch}if(J.limit!==void 0)Y.limit=J.limit;if(J.reverse===!0)Y.reverse=!0}return Y}_methodCall(){if(this._isConnected())return Promise.resolve();return new Promise((Z,J)=>{let Y=setTimeout(function(){J({code:_.timeout,message:"timeout"})},this._config.timeout);this._promises[this._nextPromiseId()]={timeout:Y,resolve:Z,reject:J}})}_callPromise(Z,J){return new Promise((Y,G)=>{this._call(Z,!1).then((Q)=>{var X;let W=J(Q.reply);Y(W),(X=Q.next)===null||X===void 0||X.call(Q)},(Q)=>{var X;G(Q.error),(X=Q.next)===null||X===void 0||X.call(Q)})})}_dataReceived(Z){if(this._serverPing>0)this._waitServerPing();let J=this._codec.decodeReplies(Z);this._dispatchPromise=this._dispatchPromise.then(()=>{let Y;this._dispatchPromise=new Promise((G)=>{Y=G}),this._dispatchSynchronized(J,Y)})}_dispatchSynchronized(Z,J){let Y=Promise.resolve();for(let G in Z)if(Z.hasOwnProperty(G))Y=Y.then(()=>{return this._dispatchReply(Z[G])});Y=Y.then(()=>{J()})}_dispatchReply(Z){let J,Y=new Promise((Q)=>{J=Q});if(Z===void 0||Z===null)return this._debug("dispatch: got undefined or null reply"),J(),Y;let G=Z.id;if(G&&G>0)this._handleReply(Z,J);else if(!Z.push)this._handleServerPing(J);else this._handlePush(Z.push,J);return Y}_call(Z,J){return new Promise((Y,G)=>{if(Z.id=this._nextCommandId(),this._registerCall(Z.id,Y,G),!J)this._addCommand(Z)})}_startConnecting(){if(this._debug("start connecting"),this._setState(h.Connecting))this.emit("connecting",{code:p1.connectCalled,reason:"connect called"});this._client=null,this._startReconnecting()}_disconnect(Z,J,Y){if(this._isDisconnected())return;this._transportIsOpen=!1;let G=this.state;this._reconnecting=!1;let Q={code:Z,reason:J},X=!1;if(Y)X=this._setState(h.Connecting);else X=this._setState(h.Disconnected),this._rejectPromises({code:_.clientDisconnected,message:"disconnected"});if(this._clearOutgoingRequests(),G===h.Connecting)this._clearReconnectTimeout();if(G===h.Connected)this._clearConnectedState();if(X)if(this._isConnecting())this.emit("connecting",Q);else this.emit("disconnected",Q);if(this._transport){this._debug("closing existing transport");let W=this._transport;this._transport=null,W.close(),this._transportClosed=!0,this._nextTransportId()}else this._debug("no transport to close");this._scheduleReconnect()}_failUnauthorized(){this._disconnect(a0.unauthorized,"unauthorized",!1)}_getToken(){if(this._debug("get connection token"),!this._config.getToken)return this.emit("error",{type:"configuration",error:{code:_.badConfiguration,message:"token expired but no getToken function set in the configuration"}}),Promise.reject(new q1(""));return this._config.getToken({})}_refresh(){let Z=this._client,J=this;this._getToken().then(function(Y){if(Z!==J._client)return;if(!Y){J._failUnauthorized();return}if(J._token=Y,J._debug("connection token refreshed"),!J._isConnected())return;let G={refresh:{token:J._token}};J._call(G,!1).then((Q)=>{let X=Q.reply.refresh;if(J._refreshResponse(X),Q.next)Q.next()},(Q)=>{if(J._refreshError(Q.error),Q.next)Q.next()})}).catch(function(Y){if(!J._isConnected())return;if(Y instanceof q1){J._failUnauthorized();return}J.emit("error",{type:"refreshToken",error:{code:_.clientRefreshToken,message:Y!==void 0?Y.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 o5(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(),a5(Z.ttl))}_removeSubscription(Z){if(Z===null)return;delete this._subs[Z.channel]}_unsubscribe(Z){if(!this._transportIsOpen)return Promise.resolve();let Y={unsubscribe:{channel:Z.channel}},G=this;return new Promise((X,W)=>{this._call(Y,!1).then((H)=>{if(X(),H.next)H.next()},(H)=>{if(X(),H.next)H.next();G._disconnect(p1.unsubscribeError,"unsubscribe error",!0)})})}_getSub(Z,J){if(J&&J>0){for(let G in this._subs)if(this._subs.hasOwnProperty(G)){let Q=this._subs[G];if(Q._id===J)return Q}return null}let Y=this._subs[Z];if(!Y)return null;return Y}_isServerSub(Z){return this._serverSubs[Z]!==void 0}_sendSubscribeCommands(){let Z=[];for(let J in this._subs){if(!this._subs.hasOwnProperty(J))continue;let Y=this._subs[J];if(Y._inflight===!0)continue;if(Y.state===r.Subscribing){let G=Y._subscribe();if(G)Z.push(G)}}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(h.Connected),this._refreshTimeout)clearTimeout(this._refreshTimeout);if(Z.expires)this._refreshTimeout=setTimeout(()=>this._refresh(),a5(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 Y=Z[J];this._serverSubs[J]={offset:Y.offset,epoch:Y.epoch,recoverable:Y.recoverable||!1};let G=this._getSubscribeContext(J,Y);this.emit("subscribed",G)}for(let J in Z){if(!Z.hasOwnProperty(J))continue;let Y=Z[J];if(Y.recovered){let G=Y.publications;if(G&&G.length>0){for(let Q in G)if(G.hasOwnProperty(Q))this._handlePublication(J,G[Q])}}}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(p1.noPing,"no ping",!0)},this._serverPing+this._config.maxServerPingDelay)}_getSubscribeContext(Z,J){let Y={channel:Z,positioned:!1,recoverable:!1,wasRecovering:!1,recovered:!1,hasRecoveredPublications:!1};if(J.recovered)Y.recovered=!0;if(J.positioned)Y.positioned=!0;if(J.recoverable)Y.recoverable=!0;if(J.was_recovering)Y.wasRecovering=!0;let G="";if("epoch"in J)G=J.epoch;let Q=0;if("offset"in J)Q=J.offset;if(Y.positioned||Y.recoverable)Y.streamPosition={offset:Q,epoch:G};if(Array.isArray(J.publications)&&J.publications.length>0)Y.hasRecoveredPublications=!0;if(J.data)Y.data=J.data;return Y}_handleReply(Z,J){let Y=Z.id;if(!(Y in this._callbacks)){J();return}let G=this._callbacks[Y];if(clearTimeout(this._callbacks[Y].timeout),delete this._callbacks[Y],!QK(Z)){let Q=G.callback;if(!Q)return;Q({reply:Z,next:J})}else{let Q=G.errback;if(!Q){J();return}let X={code:Z.error.code,message:Z.error.message||"",temporary:Z.error.temporary||!1};Q({error:X,next:J})}}_handleJoin(Z,J,Y){let G=this._getSub(Z,Y);if(!G&&Z){if(this._isServerSub(Z)){let Q={channel:Z,info:this._getJoinLeaveContext(J.info)};this.emit("join",Q)}return}G._handleJoin(J)}_handleLeave(Z,J,Y){let G=this._getSub(Z,Y);if(!G&&Z){if(this._isServerSub(Z)){let Q={channel:Z,info:this._getJoinLeaveContext(J.info)};this.emit("leave",Q)}return}G._handleLeave(J)}_handleUnsubscribe(Z,J){let Y=this._getSub(Z,0);if(!Y&&Z){if(this._isServerSub(Z))delete this._serverSubs[Z],this.emit("unsubscribed",{channel:Z});return}if(J.code<2500)Y._setUnsubscribed(J.code,J.reason,!1);else Y._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,Y=!0;if(J>=3500&&J<4000||J>=4500&&J<5000)Y=!1;this._disconnect(J,Z.reason,Y)}_getPublicationContext(Z,J){let Y={channel:Z,data:J.data};if(J.offset)Y.offset=J.offset;if(J.info)Y.info=this._getJoinLeaveContext(J.info);if(J.tags)Y.tags=J.tags;return Y}_getJoinLeaveContext(Z){let J={client:Z.client,user:Z.user},Y=Z.conn_info;if(Y)J.connInfo=Y;let G=Z.chan_info;if(G)J.chanInfo=G;return J}_handlePublication(Z,J,Y){let G=this._getSub(Z,Y);if(!G&&Z){if(this._isServerSub(Z)){let Q=this._getPublicationContext(Z,J);if(this.emit("publication",Q),J.offset!==void 0)this._serverSubs[Z].offset=J.offset}return}G._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:Y,id:G}=Z;if(Z.pub)this._handlePublication(Y,Z.pub,G);else if(Z.message)this._handleMessage(Z.message);else if(Z.join)this._handleJoin(Y,Z.join,G);else if(Z.leave)this._handleLeave(Y,Z.leave,G);else if(Z.unsubscribe)this._handleUnsubscribe(Y,Z.unsubscribe);else if(Z.subscribe)this._handleSubscribe(Y,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,Y){let G={code:Z,message:J};if(Y)G.temporary=!0;return G}_registerCall(Z,J,Y){this._callbacks[Z]={callback:J,errback:Y,timeout:null},this._callbacks[Z].timeout=setTimeout(()=>{if(delete this._callbacks[Z],PY(Y))Y({error:this._createErrorObject(_.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]}}}G0.SubscriptionState=r;G0.State=h;G0.UnauthorizedError=q1;var r5=(Z,J)=>{async function Y(){let G=await fetch(Z+"api/centrifuge/gen_token");if(!G.ok){if(G.status===403)throw new G0.UnauthorizedError("Backend is not answering");throw Error(`Unexpected status code ${G.status}`)}return(await G.json()).token}return J?new G0(J||"",{getToken:Y}):null},BK=UK(null),l1=BK;import{useContext as LK,useEffect as MK}from"react";import{useEffect as KK,useState as jY}from"react";function t5(Z,J){let[Y,G]=jY(null),[Q,X]=jY(!1);return KK(()=>{if(!Q)X(!0),fetch(Z+`api/support/${J}`,{method:"GET"}).then((W)=>W.json()).then((W)=>{G(W)})},[]),Y}var $K=({children:Z})=>{let J=LK(c1),Y=h1(),G=t5(Y,"socketIO"),Q=(X)=>{if(typeof window<"u")window.sid=X.sid,console.log(`SocketIO initialized: ${window.sid}`)};return MK(()=>{if(!J)return;let X=()=>{console.log("SocketIO connected")},W=(H)=>{console.log(`SocketIO disconnected: ${H}`),J.connect()};if(G)J.on("pieinit",Q),J.on("connect",X),J.on("disconnect",W),J.connect();return()=>{if(G)J.off("pieinit",Q),J.off("connect",X),J.off("disconnect",W),J.disconnect()}},[J,G]),Z},e5=$K;import{useContext as FK,useEffect as OK}from"react";var VK=({children:Z})=>{let J=FK(l1),Y=h1(),G=t5(Y,"centrifuge");return OK(()=>{if(!J)return;let Q=()=>{console.log("Centrifuge connected")},X=(W)=>{console.log("Centrifuge disconnected:",W)};if(G)J.on("connected",Q),J.on("disconnected",X),J.connect();return()=>{if(G)J.disconnect()}},[J,G]),Z},Z6=VK;var hX=S(x9(),1);import{useContext as f9,useEffect as C9}from"react";var zM=({card:Z,data:J,children:Y,useSocketioSupport:G=!1,useCentrifugeSupport:Q=!1,useMittSupport:X=!1,centrifugeChannel:W=void 0,methods:H=void 0})=>{let z=b1();if(z)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:G,centrifuge:Q,mitt:X,centrifugeChannel:W}),console.log("[PieCard] Methods:",H?Object.keys(H):"none"),console.log("[PieCard] Has children:",!!Y);let U=f9(c1),B=f9(l1),L=f9(u1);if(C9(()=>{if(!U||!G||!H||!J.name){if(z&&G)console.log("[PieCard] Socket.IO setup skipped:",{hasSocket:!!U,useSocketioSupport:G,hasMethods:!!H,hasDataName:!!J?.name});return}return Object.entries(H).forEach(([F,M])=>{let K=`pie${F}_${J.name}`;if(z)console.log(`[PieCard] Socket.IO registering event: ${K}`);U.on(K,M)}),()=>{Object.entries(H).forEach(([F,M])=>{let K=`pie${F}_${J.name}`;if(z)console.log(`[PieCard] Socket.IO unregistering event: ${K}`);U.off(K,M)})}},[U,H,J.name]),C9(()=>{if(!B||!Q||!W||!H||!J.name){if(z&&Q)console.log("[PieCard] Centrifuge setup skipped:",{hasCentrifuge:!!B,useCentrifugeSupport:Q,hasCentrifugeChannel:!!W,hasMethods:!!H,hasDataName:!!J?.name});return}let F=Object.entries(H).map(([M,K])=>{let $=`pie${M}_${J.name}_${W}`;if(z)console.log(`[PieCard] Centrifuge subscribing to channel: ${$}`);let O=B.newSubscription($);return O.on("publication",(N)=>{if(z)console.log(`[PieCard] Centrifuge received data on ${$}:`,N.data);K(N.data)}),O.subscribe(),O});return()=>{F.forEach((M)=>{if(z)console.log("[PieCard] Centrifuge unsubscribing from channel");M.unsubscribe(),B.removeSubscription(M)})}},[B,W,H,J.name]),C9(()=>{if(!L||!X||!H||!J.name){if(z&&X)console.log("[PieCard] Mitt setup skipped:",{hasMitt:!!L,useMittSupport:X,hasMethods:!!H,hasDataName:!!J?.name});return}return Object.entries(H).forEach(([F,M])=>{let K=`pie${F}_${J.name}`;if(z)console.log(`[PieCard] Mitt registering event: ${K}`);L.on(K,M)}),()=>{Object.entries(H).forEach(([F,M])=>{let K=`pie${F}_${J.name}`;if(z)console.log(`[PieCard] Mitt unregistering event: ${K}`);L.off(K,M)})}},[L,H,J.name]),z)console.log("[PieCard] Rendering complete, returning children");return Y},y=zM;function R0(Z){if(!Z)return{};let J={...Z};if("animationName"in J&&typeof J.animationName==="object"){let Y="radiumAnimation_"+Math.random().toString(36).substring(2,8);J.animationName=n.keyframes(J.animationName,Y)}return J}import{jsx as j9}from"react/jsx-runtime";var UM=({data:Z,content:J,setUiAjaxConfiguration:Y})=>{let{name:G,sx:Q}=Z;return j9(y,{card:G,data:Z,children:j9("div",{style:R0(Q),id:G,children:J.map((X,W)=>{return j9(G1,{uiConfig:X,setUiAjaxConfiguration:Y},`children-${W}`)})})})},sG=n(UM);import{jsx as rG}from"react/jsx-runtime";var BM=({data:Z,content:J,setUiAjaxConfiguration:Y})=>{let{name:G}=Z;return rG(y,{card:G,data:Z,children:J.map((Q,X)=>{return rG(G1,{uiConfig:Q,setUiAjaxConfiguration:Y},`children-${X}`)})})},tG=BM;import{useContext as eG,useEffect as KM,useRef as LM,useState as ZQ}from"react";import{jsx as JQ}from"react/jsx-runtime";var MM=({data:Z,content:J})=>{let{useLoader:Y,noReturn:G,returnType:Q,useSocketioSupport:X,useCentrifugeSupport:W,useMittSupport:H,centrifugeChannel:z}=Z,U=eG(v1),[B,L]=ZQ(!1),[F,M]=ZQ(null),K=LM(J),$=eG(u1),O=(D)=>{if(D===null)L(!0);else if(L(!1),!G)K.current=D;if(!G)M(D)},N=(D)=>{K.current=D.content,M(D.content)},P=(D)=>{if(D===null)L(!0);else if(L(!1),!G)for(let q of D)$.emit(q.name,q.data)};if(KM(()=>{M(J),L(!1)},[J]),!F&&Y)return U;return JQ(y,{card:"AjaxGroupCard",data:Z,methods:{changeContent:N},useSocketioSupport:X,useCentrifugeSupport:W,useMittSupport:H,centrifugeChannel:z,children:JQ(G1,{uiConfig:F??K.current,setUiAjaxConfiguration:Q==="events"?P:O})})},YQ=n(MM);function _9(Z=1000){return new Promise((J)=>{if(typeof window>"u"){J();return}let Y=()=>{if(typeof window.sid<"u")J();else setTimeout(Y,Z)};Y()})}import{useMemo as $M}from"react";var FM=(Z,J={},Y=[],G,Q)=>{let X=Q?.renderingLogEnabled??!1,W=Q?.apiServer??"";if(X)console.log("Registering AJAX: ",G,J,Y);if(!G||!Z){if(X)console.warn("Registration FAILED: pathname or setUiAjaxConfiguration is missing!");return()=>{}}return async(H={})=>{if(typeof window>"u"||typeof document>"u"){if(X)console.warn("getAjaxSubmit called on server, skipping DOM-dependent logic");return}if(Y.includes("sid"))await _9();let z=new FormData;for(let[B,L]of Object.entries({...J,...H}))z.append(B,L);for(let B of Y)if(B==="sid"){if(!window.sid)throw Error("SocketIO isn't initialized properly");z.append("sid",window.sid)}else{let L=document.getElementsByName(B);if(!L.length){if(X)console.warn(`No input found with name ${B}`);continue}let F=L[0];if(F instanceof HTMLInputElement)if(F.type==="file"&&F.files)Array.from(F.files).forEach((M)=>z.append(B,M));else z.append(B,F.value);else if(F instanceof HTMLTextAreaElement)z.append(B,F.value)}let U=W+"api/ajax_content"+G;return Z(null),await fetch(U,{method:"POST",body:z}).then(async(B)=>{let F=(B.headers.get("content-type")||"").includes("application/json");if(!!B.body?.getReader&&!F){let K=B.body.getReader(),$=new TextDecoder,O="";while(!0){let{done:N,value:P}=await K.read();if(N)break;O+=$.decode(P,{stream:!0});let D=O.split(`
|
|
29
|
+
`);O=D.pop()??"";for(let q of D){let T=q.trim();if(!T)continue;try{let f=JSON.parse(T);Z([f])}catch(f){if(X)console.warn("Failed to parse streamed line:",T)}}}if(O.trim())try{let N=JSON.parse(O);Z([N])}catch(N){if(X)console.warn("Failed to parse final streamed line:",O)}return{}}else{let K=await B.json();return Z(K),K}}).catch((B)=>{if(X)console.error("AJAX request failed:",B);return Z(null),B})}},G5=(Z,J={},Y=[],G)=>{let{apiServer:Q,enableRenderingLog:X}=U0();return $M(()=>FM(Z,J,Y,G,{apiServer:Q,renderingLogEnabled:X}),[Z,J,Y,G,Q,X])};var Z7=S(e9(),1),H0=S(e9(),1),o1=Z7.default.default||Z7.default;import{jsx as J7,jsxs as L$}from"react/jsx-runtime";var K$=({data:Z,setUiAjaxConfiguration:J})=>{let{name:Y,title:G,iconUrl:Q,iconPosition:X,sx:W,pathname:H,kwargs:z,depsNames:U}=Z,B=G5(J,z,U,H);return J7(y,{card:"AjaxButtonCard",data:Z,children:L$("button",{id:Y,className:"box-border flex min-h-12 w-full min-w-min cursor-pointer items-center justify-center gap-4 rounded-l border border-black bg-white text-center text-black hover:bg-neutral-300",value:Y,onClick:()=>B(),style:R0(W),type:"button",children:[Q&&X==="start"&&J7("img",{src:Q,alt:""}),o1(G),Q&&X==="end"&&J7("img",{src:Q,alt:""})]})})},WX=n(K$);import{forwardRef as k$,useEffect as AX,useImperativeHandle as v$,useRef as h$,useState as T6}from"react";import{useRef as M$,useState as $$}from"react";import{jsx as F$}from"react/jsx-runtime";function Y7(Z){let[J,Y]=$$(!1),G=M$(null);return F$("textarea",{ref:G,...Z,onKeyUp:()=>{Y(!1)},onKeyDown:(H)=>{if(H.key==="Enter"&&H.shiftKey){if(Y(!0),G.current&&typeof window<"u"){let z=window.getComputedStyle(G.current),U=parseFloat(z.lineHeight);G.current.style.height=G.current.scrollHeight+U+"px"}}if(H.key==="Backspace"){if(Y(!0),G.current&&typeof window<"u"){let z=window.getComputedStyle(G.current),U=parseFloat(z.lineHeight);if(G.current.scrollHeight>U)G.current.style.height=G.current.scrollHeight-U+"px"}}Z.onKeyDown&&Z.onKeyDown(H)},onBlur:(H)=>{Y(!1),Z.onBlur&&Z.onBlur(H)},style:{resize:J?"vertical":"none",overflowY:"auto",...Z.style}})}import{useRef as V$,useCallback as I$}from"react";import{jsx as HX}from"react/jsx-runtime";var O$=()=>HX("svg",{xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24",strokeWidth:"1.5",stroke:"currentColor",className:"size-5",children:HX("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"})}),zX=O$;import{jsx as G7}from"react/jsx-runtime";var q$=({type:Z="button",onClick:J,icons:Y})=>{let G=V$(null),Q=I$(()=>{let W=G.current;if(W)W.style.transform="scale(0.8)",setTimeout(()=>{W.style.transform="scale(1)"},600)},[]);return G7("button",{ref:G,type:Z,onClick:(W)=>{if(J)J(W);Q()},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:Y.sendIcon?G7("img",{src:Y.sendIcon,alt:""}):G7(zX,{})})},UX=q$;import{jsx as BX}from"react/jsx-runtime";var D$=()=>BX("svg",{xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24",strokeWidth:"1.5",stroke:"currentColor",className:"size-5",children:BX("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"})}),KX=D$;import{jsx as A6,jsxs as R$,Fragment as A$}from"react/jsx-runtime";var N$=({name:Z,accept:J,fileInputRef:Y,onSelectFile:G,icons:Q})=>{return R$(A$,{children:[A6("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(Y.current)Y.current.click()},children:Q.attachFileIcon?A6("img",{src:Q.attachFileIcon,alt:""}):A6(KX,{})}),A6("input",{id:Z+"__pie__file",name:Z+"__pie__file",className:"hidden",type:"file",accept:J,ref:Y,onChange:(X)=>{if(X.target.files)G(X.target.files[0])}})]})},LX=N$;import{jsx as MX}from"react/jsx-runtime";var P$=()=>MX("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:MX("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"})}),$X=P$;import{jsx as FX}from"react/jsx-runtime";var T$=()=>FX("svg",{xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24",strokeWidth:"1.5",stroke:"currentColor",className:"size-5",children:FX("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M6 18L18 6M6 6l12 12"})}),R6=T$;import{jsx as L5,jsxs as E$}from"react/jsx-runtime";var w$=({name:Z,selectedFile:J,onDropFile:Y})=>{return E$("div",{className:"flex w-full cursor-default flex-row items-center gap-2",children:[L5($X,{}),L5("span",{className:"flex-1",children:J.name}),L5("input",{type:"hidden",name:Z,value:""}),L5("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:Y,children:L5(R6,{})})]})},OX=w$;import{jsx as VX,jsxs as x$}from"react/jsx-runtime";var S$=()=>x$("svg",{xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24",strokeWidth:"1.5",stroke:"currentColor",className:"size-5",children:[VX("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"}),VX("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"})]}),IX=S$;import{jsx as M5}from"react/jsx-runtime";var f$=({isListening:Z,toggleListening:J,icons:Y})=>{return 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:J,children:Z?Y.cancelIcon?M5("img",{src:Y.cancelIcon,alt:""}):M5(R6,{}):Y.voiceRecordingIcon?M5("img",{src:Y.voiceRecordingIcon,alt:""}):M5(IX,{})})},qX=f$;import{jsx as DX,jsxs as j$}from"react/jsx-runtime";var C$=({option:Z,onClickOption:J})=>{return j$("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"&&DX("img",{src:Z.iconUrl,alt:""}),Z.title,Z.iconPosition==="end"&&DX("img",{src:Z.iconUrl,alt:""})]})},P6=C$;import{jsx as NX}from"react/jsx-runtime";var _$=({options:Z,handleOptionClick:J})=>{return NX("div",{className:"flex w-full flex-row flex-wrap justify-start gap-[5px]",children:Z.map((Y,G)=>{return NX(P6,{option:Y,onClickOption:J},G)})})},Q7=_$;import{jsx as x1,jsxs as RX}from"react/jsx-runtime";var b$=k$(({name:Z,defaultValue:J,defaultOptions:Y,isArea:G,placeholder:Q,fileAccept:X,optionsPosition:W,icons:H,handleOptionClick:z,handleSendMessage:U,sx:B},L)=>{let F=h$(null),[M,K]=T6(null),[$,O]=T6(J),[N,P]=T6(Y),[D,q]=T6(!1);v$(L,()=>({clear:()=>{if(O(""),K(null),F.current)F.current.value=""},setValue:(f)=>O(f),setOptions:(f)=>P(f)})),AX(()=>{O(J)},[J]),AX(()=>{},[]);let T=()=>{};return RX("div",{className:"flex flex-col items-center gap-[0.1rem]",id:Z+"_chat_input",style:B,children:[N&&W==="top"&&x1(Q7,{options:N,handleOptionClick:z}),x1("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:RX("div",{className:"flex w-full grow flex-row items-center rounded-md bg-transparent",children:[M?x1(OX,{name:Z,selectedFile:M,onDropFile:()=>{if(K(null),F.current)F.current.value=""}}):!G?x1("input",{name:Z,value:$,onChange:(f)=>O(f.target.value),onKeyDown:(f)=>{if(f.key==="Enter")f.preventDefault(),U()},tabIndex:0,placeholder:Q,className:"m-0 w-full resize-none border-0 bg-transparent outline-none",style:{maxHeight:200,height:"100%",overflowY:"hidden"}}):x1(Y7,{name:Z,value:$,onChange:(f)=>O(f.target.value),onKeyDown:(f)=>{if(f.key==="Enter"&&!f.shiftKey)f.preventDefault(),U()},tabIndex:0,rows:2,placeholder:Q,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}}),x1(qX,{isListening:D,toggleListening:T,icons:H}),x1(LX,{name:Z,fileInputRef:F,accept:X,onSelectFile:K,icons:H}),x1(UX,{onClick:U,icons:H})]})}),N&&W==="bottom"&&x1(Q7,{options:N,handleOptionClick:z})]})}),PX=b$;import{useState as p$,useEffect as l$}from"react";import{useEffect as g$,useState as y$}from"react";import{jsx as u$}from"react/jsx-runtime";function m$({children:Z}){let[J,Y]=y$(Z);return g$(()=>{Y(Z)},[Z]),u$("div",{className:"max-w-full first:mt-0",children:J})}var TX=m$;import{jsx as wX}from"react/jsx-runtime";var d$=()=>wX("svg",{width:"30",height:"30",viewBox:"0 0 16 16",xmlns:"http://www.w3.org/2000/svg",children:wX("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"})}),EX=d$;import{jsx as w6}from"react/jsx-runtime";function c$({username:Z,avatar:J}){return w6("div",{className:"w-[30px]",children:w6("div",{className:"relative flex size-[30px] items-center justify-center rounded-sm p-1 text-white",children:J?w6("img",{src:J,className:"absolute inset-0 rounded",alt:Z}):w6(EX,{})})})}var X7=c$;import{jsx as N1,jsxs as SX}from"react/jsx-runtime";var i$=({message:Z,handleOptionClick:J,setUiAjaxConfiguration:Y})=>{let[G,Q]=p$(!1);return l$(()=>{let X=setTimeout(()=>{if(G)Q(!1)},1000);return()=>clearTimeout(X)},[G]),N1("div",{className:"group w-full border-b border-black/10",id:Z.id,children:SX("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")&&N1("div",{className:"relative flex shrink-0 flex-col items-end",children:N1(X7,{username:Z.username,avatar:Z.avatar})}),SX("div",{className:"relative flex w-[calc(100%-50px)] flex-col gap-1 md:gap-3 lg:w-[calc(100%-115px)]",children:[N1("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"?N1(TX,{children:Z.content},Date.now()+Math.random()):Z.parseMode.toLowerCase()==="html"?o1(Z.content):Z.content:N1(G1,{uiConfig:Z.content,setUiAjaxConfiguration:Y})}),N1("div",{className:"flex flex-row flex-wrap justify-start gap-1",children:Z.options.map((X,W)=>N1(P6,{onClickOption:J,option:X},W))})]}),Z.align==="right"&&N1("div",{className:"relative flex shrink-0 flex-col items-end",children:N1(X7,{username:Z.username,avatar:Z.avatar})})]})})},xX=i$;import{forwardRef as n$,useEffect as o$,useImperativeHandle as a$,useRef as s$,useState as r$}from"react";import{jsx as fX}from"react/jsx-runtime";var t$=n$(({name:Z,handleOptionClick:J,defaultMessages:Y,sx:G,setUiAjaxConfiguration:Q},X)=>{let[W,H]=r$(Y),z=s$(null),U=()=>{if(z.current)z.current.scrollTop=z.current.scrollHeight};return o$(()=>{U()},[W]),a$(X,()=>({setMessages:(B)=>H(B),addMessage:(B)=>H((L)=>[...L,B]),scrollToBottom:U})),fX("div",{id:Z+"_messages",className:"flex flex-col items-center overflow-y-scroll",style:G,ref:z,children:W.map((B)=>fX(xX,{message:B,handleOptionClick:J,setUiAjaxConfiguration:Q},B.id))})}),CX=t$;import{useEffect as e$,useRef as jX,useState as ZF}from"react";import{jsx as W7,jsxs as YF}from"react/jsx-runtime";var JF=({data:Z,setUiAjaxConfiguration:J})=>{let{name:Y,defaultValue:G,defaultMessages:Q,defaultOptions:X,isArea:W,fileAccept:H,placeholder:z,icons:U,optionsPosition:B,sxMap:L={container:{},chatInput:{},messages:{}},depsNames:F,pathname:M,kwargs:K,useSocketioSupport:$,useCentrifugeSupport:O,centrifugeChannel:N}=Z,P=jX(null),D=jX(null),[q,T]=ZF(!1),f=G5(J,K,F,M);e$(()=>{if(q)requestAnimationFrame(()=>{f(),T(!1)})},[q]);let u=(p)=>{if(P.current)P.current.setValue(p),T(!0)},a1=()=>{if(P.current)P.current.clear()},C1=(p)=>{if(P.current)P.current.setOptions(p.options)},j1=(p)=>{if(D.current)D.current.addMessage(p.message)},k=(p)=>{if(D.current)D.current.setMessages(p.messages)},R1=()=>{T(!0)};return W7(y,{card:"ChatCard",data:Z,methods:{clearInput:a1,setOptions:C1,addMessage:j1,setMessages:k},useSocketioSupport:$,useCentrifugeSupport:O,centrifugeChannel:N,children:YF("div",{className:"flex size-full flex-col",style:L.container,children:[W7(CX,{ref:D,name:Y,defaultMessages:Q,sx:L.messages,handleOptionClick:u,setUiAjaxConfiguration:J}),W7(PX,{ref:P,name:Y,isArea:W,defaultOptions:X,placeholder:z,defaultValue:G,fileAccept:H,sx:L.chatInput,handleSendMessage:R1,handleOptionClick:u,optionsPosition:B,icons:U})]})})},_X=JF;import{useEffect as GF,useState as QF}from"react";import{jsx as kX}from"react/jsx-runtime";var XF=({data:Z})=>{let{name:J,value:Y,useSocketioSupport:G,useCentrifugeSupport:Q,useMittSupport:X,centrifugeChannel:W}=Z,[H,z]=QF(Y);return GF(()=>{z(Y)},[Y]),kX(y,{card:"HiddenCard",data:Z,useSocketioSupport:G,useCentrifugeSupport:Q,useMittSupport:X,centrifugeChannel:W,methods:{update:({value:U})=>{z(U)}},children:kX("input",{type:"hidden",id:J,name:J,value:H})})},H7=XF;import{useContext as zF,useEffect as UF}from"react";import{createContext as WF}from"react";var HF=WF(void 0),A1=HF;import{jsx as LF,Fragment as KF}from"react/jsx-runtime";var BF=({data:Z})=>{let{url:J}=Z,Y=zF(A1);return UF(()=>{if(/^[a-zA-Z][a-zA-Z\d+\-.]*:\/\//.test(J))window.location.href=J;else Y?.(J)},[J,Y]),LF(KF,{})},z7=BF;import{useEffect as OF,useState as VF}from"react";import{useCallback as E6,useEffect as MF,useRef as U7,useState as $F}from"react";function FF(){let Z=new AudioContext,J=Z.createOscillator(),Y=J.connect(Z.createMediaStreamDestination());J.start();let G=Y.stream.getAudioTracks()[0];return G.enabled=!1,G}function B7(Z=null,J){let[Y,G]=$F(!1),Q=U7(null),X=U7(null),W=U7(null),H=E6(async(L,F=!0)=>{if(Q.current)z();let M=new RTCPeerConnection;if(M.onconnectionstatechange=()=>{if(M.connectionState==="connected")G(!0);else if(["disconnected","failed","closed"].includes(M.connectionState))G(!1)},M.ontrack=(q)=>{if(Z)Z.srcObject=q.streams[0]},F){let q=await navigator.mediaDevices.getUserMedia({audio:!0});M.addTrack(q.getTracks()[0],q)}else{let q=FF();M.addTrack(q)}let K=M.createDataChannel("oai-events");X.current=K,W.current=new Promise((q)=>{K.addEventListener("open",()=>{q()})});let $=await M.createOffer();await M.setLocalDescription($);let D=await(await fetch(`${"https://api.openai.com/v1/realtime/calls"}?model=${"gpt-realtime"}`,{method:"POST",body:$.sdp,headers:{Authorization:`Bearer ${L}`,"Content-Type":"application/sdp"}})).text();await M.setRemoteDescription({type:"answer",sdp:D}),Q.current=M,await W.current},[Z]),z=E6(()=>{let L=X.current;if(L)L.close();Q.current?.getSenders()?.forEach((F)=>F.track?.stop()),Q.current?.close(),G(!1),Q.current=null,X.current=null,W.current=null},[Z]),U=E6((L)=>{let F=X.current;if(!F){console.error("Data channel is not ready",L);return}let M=new Date().toLocaleTimeString();if(L.event_id=L.event_id||crypto.randomUUID(),F.send(JSON.stringify(L)),!L.timestamp)L.timestamp=M;J?.(L)},[J,Z]),B=E6((L)=>{if(!X.current){console.error("Data channel is not ready");return}let M=()=>{U({type:"conversation.item.create",item:{type:"message",role:"user",content:[{type:"input_text",text:L}]}}),U({type:"response.create"})};if(W.current)W.current.then(M);else M()},[J,Z]);return MF(()=>{let L=X.current;if(!L)return;let F=(M)=>{let K=JSON.parse(M.data);if(!K.timestamp)K.timestamp=new Date().toLocaleTimeString();J?.(K)};return L.addEventListener("message",F),()=>{L.removeEventListener("message",F)}},[J,Z]),{isSessionActive:Y,startSession:H,stopSession:z,sendTextMessage:B}}import{jsx as qF}from"react/jsx-runtime";var IF=({data:Z})=>{let{html:J,useSocketioSupport:Y,useCentrifugeSupport:G,useMittSupport:Q,centrifugeChannel:X}=Z,[W,H]=VF(J),{isSessionActive:z,startSession:U,sendTextMessage:B}=B7(null,(K)=>{if(console.log(K.type,K.type==="response.output_text.delta"&&K.delta),K.type==="response.output_text.delta"&&K.delta)H(($)=>$+K.delta)});return OF(()=>{H(J)},[J]),qF(y,{card:"HTMLEmbedCard",data:Z,methods:{update:(K)=>{H(K.value)},generateUsingAI:async(K)=>{try{if(!z&&K.token)await U(K.token,!1);B(K.prompt)}catch($){console.error("Failed to generate using AI",$)}},initializeAI:async(K)=>{if(!z&&K.token)await U(K.token,!1)}},useCentrifugeSupport:G,useSocketioSupport:Y,useMittSupport:Q,centrifugeChannel:X,children:o1(W)})},K7=n(IF);import{useContext as DF}from"react";import{jsx as L7,Fragment as vX}from"react/jsx-runtime";var NF=({data:Z})=>{let{useCentrifugeSupport:J,useSocketioSupport:Y,useMittSupport:G,centrifugeChannel:Q}=Z,X=DF(A1);return L7(vX,{children:L7(y,{card:"IOEventsCard",data:Z,useCentrifugeSupport:J,useSocketioSupport:Y,useMittSupport:G,centrifugeChannel:Q,methods:{log:(z)=>{console.log("Log event",z)},redirect:(z)=>{if(z.to){let U=z.to;if(/^[a-zA-Z][a-zA-Z\d+\-.]*:\/\//.test(U))window.location.href=U;else X?.(U)}else window.location.reload()}},children:L7(vX,{})})})},M7=NF;import{useContext as AF}from"react";import{jsx as $7,jsxs as PF}from"react/jsx-runtime";var RF=({data:Z})=>{let{name:J,title:Y,url:G,iconUrl:Q,iconPosition:X,sx:W}=Z,H=AF(A1);return $7(y,{card:"RedirectButtonCard",data:Z,children:PF("button",{id:J,className:"box-border flex min-h-12 w-full min-w-min cursor-pointer items-center justify-center gap-4 rounded-l border border-black bg-white text-center text-black hover:bg-neutral-300",value:J,onClick:(U)=>{if(G)if(U.stopPropagation(),/^[a-zA-Z][a-zA-Z\d+\-.]*:\/\//.test(G))window.location.href=G;else H?.(G)},style:R0(W),type:"button",children:[Q&&X==="start"&&$7("img",{src:Q,alt:""}),o1(Y),Q&&X==="end"&&$7("img",{src:Q,alt:""})]})})},F7=n(RF);var O7=!1;function $5(){if(O7)return;U1({name:"SequenceCard",component:sG,metadata:{author:"PieData",description:"Simple div with styles joining few components"}}),U1({name:"UnionCard",component:tG,metadata:{author:"PieData",description:"Renders one of many components"}}),U1({name:"AjaxGroupCard",component:YQ,metadata:{author:"PieData",description:"Group card with AJAX support"}}),U1({name:"AjaxButtonCard",component:WX,metadata:{author:"PieData",description:"Button with AJAX support"}}),U1({name:"RedirectButtonCard",component:F7,metadata:{author:"PieData",description:"Button with Redirect on click"}}),U1({name:"ChatCard",component:_X,metadata:{author:"PieData"}}),U1({name:"HiddenCard",component:H7,metadata:{author:"PieData"}}),U1({name:"AutoRedirectCard",component:z7,metadata:{author:"PieData"}}),U1({name:"HTMLEmbedCard",component:K7,metadata:{author:"PieData"}}),U1({name:"IOEventsCard",component:M7,metadata:{author:"PieData"}}),O7=!0}function f1(){return O7}import{jsx as H1,Fragment as jF}from"react/jsx-runtime";var fF=({location:Z,fallback:J,onError:Y,initializePie:G})=>{let Q=h1(),X=O5(),W=b1();TF(()=>{if(f1())return;$5(),G()},[]);let H=wF(()=>hX.createAxiosDateTransformer({baseURL:Q||""}),[Q]),{data:z,isLoading:U,error:B}=xF({queryKey:["uiConfig",Z.pathname+Z.search,f1(),Q],queryFn:async()=>{if(!Q||!f1())return;let L="/api/content"+Z.pathname+(Z.search.startsWith("?")?Z.search:`?${Z.search}`);if(W)console.log("[PieRoot] Fetching UI configuration from:",L);let F=await H.get(L,{headers:{"Access-Control-Allow-Origin":"*","Access-Control-Allow-Methods":"GET,PUT,POST,DELETE,PATCH,OPTIONS","Content-type":"application/json"},withCredentials:!0});if(W)console.log("[PieRoot] Received UI configuration:",F.data);return F.data},staleTime:1/0,gcTime:1/0,refetchOnWindowFocus:!1,refetchOnMount:!1,refetchOnReconnect:!1,retry:!0,retryDelay:(L)=>Math.min(1000*2**L,30000)});if(!Q)return J??null;if(W)console.log("[PieRoot] Rendering with location:",Z),console.log("[PieRoot] API_SERVER:",Q),console.log("[PieRoot] Fallback provided:",!!J);if(B){if(W)console.error("[PieRoot] Error fetching UI configuration:",B),console.error("[PieRoot] Error details:",{message:B.message,status:B.response?.status,data:B.response?.data});return Y?.(),J}if(U||!z){if(W)console.log("[PieRoot] Loading state:",{isLoading:U,hasUiConfiguration:!!z});return J}if(W)console.log("[PieRoot] UI configuration loaded successfully:",z),console.log("[PieRoot] Rendering UI with configuration");return H1(u1.Provider,{value:v0,children:H1(c1.Provider,{value:p5(Q),children:H1(l1.Provider,{value:r5(Q,X),children:H1(v1.Provider,{value:J??H1(jF,{}),children:H1(e5,{children:H1(Z6,{children:H1(n.StyleRoot,{style:{display:"contents"},children:H1(G1,{uiConfig:z})})})})})})})})},CF=(Z)=>{let J=new EF;return H1(A1.Provider,{value:Z.onNavigate,children:H1(S0.Provider,{value:Z.config,children:H1(SF,{client:J,children:H1(fF,{...Z})})})})},_F=CF;import{useEffect as hF,useMemo as bF}from"react";import{QueryClient as gF,QueryClientProvider as yF,useQuery as mF}from"@tanstack/react-query";var gX=S(x9(),1);import{useEffect as kF,useState as vF}from"react";var bX=()=>{let[Z,J]=vF(null),Y=w7();return kF(()=>{if(typeof window>"u")return;let G=window.Telegram.WebApp;if(G.ready(),Y==="telegram_expanded"&&(G.platform==="ios"||G.platform==="android"))G.expand();J(G)},[]),Z};import{jsx as z1,Fragment as cF}from"react/jsx-runtime";var uF=({location:Z,fallback:J,onError:Y,initializePie:G})=>{let Q=h1(),X=O5(),W=b1();hF(()=>{if(f1())return;$5(),G()},[]);let H=bF(()=>gX.createAxiosDateTransformer({baseURL:Q}),[]);if(W)console.log("[PieRoot] Rendering with location:",Z),console.log("[PieRoot] API_SERVER:",Q),console.log("[PieRoot] Fallback provided:",!!J);if(!Q)throw Error("Set PIE_API_SERVER and PIE_CENTRIFUGE_SERVER");let z=bX(),{data:U,isLoading:B,error:L}=mF({queryKey:["uiConfig",Z.pathname+Z.search,z?.initData,f1()],queryFn:async()=>{if(!f1())return;let F=Z.search?"&":"",M=z?.initData?`${F}initData=${encodeURIComponent(z.initData)}`:"",K="/api/content"+Z.pathname+(Z.search.startsWith("?")?Z.search:`?${Z.search}`)+M;if(W)console.log("[PieRoot] Fetching UI configuration from:",K);let $=await H.get(K,{headers:{"Access-Control-Allow-Origin":"*","Access-Control-Allow-Methods":"GET,PUT,POST,DELETE,PATCH,OPTIONS","Content-type":"application/json"},withCredentials:!0});if(W)console.log("[PieRoot] Received UI configuration:",$.data);return $.data},staleTime:1/0,gcTime:1/0,refetchOnWindowFocus:!1,refetchOnMount:!1,refetchOnReconnect:!1,retry:!0,retryDelay:(F)=>Math.min(1000*2**F,30000)});if(L&&W)return console.error("[PieRoot] Error fetching UI configuration:",L),console.error("[PieRoot] Error details:",{message:L.message,status:L.response?.status,data:L.response?.data}),Y?.(),J;if(B||!U){if(W)console.log("[PieRoot] Loading state:",{isLoading:B,hasUiConfiguration:!!U});return J}if(W)console.log("[PieRoot] UI configuration loaded successfully:",U),console.log("[PieRoot] Rendering UI with configuration");return z1(u1.Provider,{value:v0,children:z1(c1.Provider,{value:p5(Q),children:z1(l1.Provider,{value:r5(Q,X),children:z1(v1.Provider,{value:J??z1(cF,{}),children:z1(e5,{children:z1(Z6,{children:z1(n.StyleRoot,{children:z1(G1,{uiConfig:U})})})})})})})})},dF=(Z)=>{let J=new gF;return z1(A1.Provider,{value:Z.onNavigate,children:z1(S0.Provider,{value:Z.config,children:z1(yF,{client:J,children:z1(uF,{...Z})})})})},pF=dF;export{G5 as useAjaxSubmit,U1 as registerPieComponent,f1 as isPieComponentsInitialized,$5 as initializePieComponents,G1 as UI,pF as PieTelegramRoot,_F as PieRoot,y as PieCard};
|