@irshat/robot-ui 2.4.52 → 3.4.54
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/index.css +1 -1
- package/dist/index.js +1 -1
- package/package.json +1 -1
package/dist/index.css
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
@layer properties{@supports (((-webkit-hyphens:none)) and (not (margin-trim:inline))) or ((-moz-orient:inline) and (not (color:rgb(from red r g b)))){*,:before,:after,::backdrop{--tw-translate-x:0;--tw-translate-y:0;--tw-translate-z:0;--tw-rotate-x:initial;--tw-rotate-y:initial;--tw-rotate-z:initial;--tw-skew-x:initial;--tw-skew-y:initial;--tw-border-style:solid;--tw-leading:initial;--tw-font-weight:initial;--tw-ordinal:initial;--tw-slashed-zero:initial;--tw-numeric-figure:initial;--tw-numeric-spacing:initial;--tw-numeric-fraction:initial;--tw-shadow:0 0 #0000;--tw-shadow-color:initial;--tw-shadow-alpha:100%;--tw-inset-shadow:0 0 #0000;--tw-inset-shadow-color:initial;--tw-inset-shadow-alpha:100%;--tw-ring-color:initial;--tw-ring-shadow:0 0 #0000;--tw-inset-ring-color:initial;--tw-inset-ring-shadow:0 0 #0000;--tw-ring-inset:initial;--tw-ring-offset-width:0px;--tw-ring-offset-color:#fff;--tw-ring-offset-shadow:0 0 #0000;--tw-blur:initial;--tw-brightness:initial;--tw-contrast:initial;--tw-grayscale:initial;--tw-hue-rotate:initial;--tw-invert:initial;--tw-opacity:initial;--tw-saturate:initial;--tw-sepia:initial;--tw-drop-shadow:initial;--tw-drop-shadow-color:initial;--tw-drop-shadow-alpha:100%;--tw-drop-shadow-size:initial;--tw-backdrop-blur:initial;--tw-backdrop-brightness:initial;--tw-backdrop-contrast:initial;--tw-backdrop-grayscale:initial;--tw-backdrop-hue-rotate:initial;--tw-backdrop-invert:initial;--tw-backdrop-opacity:initial;--tw-backdrop-saturate:initial;--tw-backdrop-sepia:initial;--tw-duration:initial;--tw-ease:initial}}}@layer theme{:root,:host{--font-sans:ui-sans-serif,system-ui,sans-serif,"Apple Color Emoji","Segoe UI Emoji","Segoe UI Symbol","Noto Color Emoji";--font-mono:ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,"Liberation Mono","Courier New",monospace;--color-amber-300:oklch(87.9% .169 91.605);--color-amber-600:oklch(66.6% .179 58.318);--color-lime-500:oklch(76.8% .233 130.85);--color-sky-500:oklch(68.5% .169 237.323);--spacing:.25rem;--text-xs:.75rem;--text-xs--line-height:calc(1/.75);--text-base:1rem;--text-base--line-height: 1.5 ;--font-weight-bold:700;--radius-lg:.5rem;--radius-4xl:2rem;--ease-out:cubic-bezier(0,0,.2,1);--default-transition-duration:.15s;--default-transition-timing-function:cubic-bezier(.4,0,.2,1);--default-font-family:var(--font-sans);--default-mono-font-family:var(--font-mono)}}@layer base{*,:after,:before,::backdrop{box-sizing:border-box;border:0 solid;margin:0;padding:0}::file-selector-button{box-sizing:border-box;border:0 solid;margin:0;padding:0}html,:host{-webkit-text-size-adjust:100%;tab-size:4;line-height:1.5;font-family:var(--default-font-family,ui-sans-serif,system-ui,sans-serif,"Apple Color Emoji","Segoe UI Emoji","Segoe UI Symbol","Noto Color Emoji");font-feature-settings:var(--default-font-feature-settings,normal);font-variation-settings:var(--default-font-variation-settings,normal);-webkit-tap-highlight-color:transparent}hr{height:0;color:inherit;border-top-width:1px}abbr:where([title]){-webkit-text-decoration:underline dotted;text-decoration:underline dotted}h1,h2,h3,h4,h5,h6{font-size:inherit;font-weight:inherit}a{color:inherit;-webkit-text-decoration:inherit;text-decoration:inherit}b,strong{font-weight:bolder}code,kbd,samp,pre{font-family:var(--default-mono-font-family,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,"Liberation Mono","Courier New",monospace);font-feature-settings:var(--default-mono-font-feature-settings,normal);font-variation-settings:var(--default-mono-font-variation-settings,normal);font-size:1em}small{font-size:80%}sub,sup{vertical-align:baseline;font-size:75%;line-height:0;position:relative}sub{bottom:-.25em}sup{top:-.5em}table{text-indent:0;border-color:inherit;border-collapse:collapse}:-moz-focusring{outline:auto}progress{vertical-align:baseline}summary{display:list-item}ol,ul,menu{list-style:none}img,svg,video,canvas,audio,iframe,embed,object{vertical-align:middle;display:block}img,video{max-width:100%;height:auto}button,input,select,optgroup,textarea{font:inherit;font-feature-settings:inherit;font-variation-settings:inherit;letter-spacing:inherit;color:inherit;opacity:1;background-color:#0000;border-radius:0}::file-selector-button{font:inherit;font-feature-settings:inherit;font-variation-settings:inherit;letter-spacing:inherit;color:inherit;opacity:1;background-color:#0000;border-radius:0}:where(select:is([multiple],[size])) optgroup{font-weight:bolder}:where(select:is([multiple],[size])) optgroup option{padding-inline-start:20px}::file-selector-button{margin-inline-end:4px}::placeholder{opacity:1}@supports (not ((-webkit-appearance:-apple-pay-button))) or (contain-intrinsic-size:1px){::placeholder{color:currentColor}@supports (color:color-mix(in lab,red,red)){::placeholder{color:color-mix(in oklab,currentcolor 50%,transparent)}}}textarea{resize:vertical}::-webkit-search-decoration{-webkit-appearance:none}::-webkit-date-and-time-value{min-height:1lh;text-align:inherit}::-webkit-datetime-edit{display:inline-flex}::-webkit-datetime-edit-fields-wrapper{padding:0}::-webkit-datetime-edit{padding-block:0}::-webkit-datetime-edit-year-field{padding-block:0}::-webkit-datetime-edit-month-field{padding-block:0}::-webkit-datetime-edit-day-field{padding-block:0}::-webkit-datetime-edit-hour-field{padding-block:0}::-webkit-datetime-edit-minute-field{padding-block:0}::-webkit-datetime-edit-second-field{padding-block:0}::-webkit-datetime-edit-millisecond-field{padding-block:0}::-webkit-datetime-edit-meridiem-field{padding-block:0}::-webkit-calendar-picker-indicator{line-height:1}:-moz-ui-invalid{box-shadow:none}button,input:where([type=button],[type=reset],[type=submit]){appearance:button}::file-selector-button{appearance:button}::-webkit-inner-spin-button{height:auto}::-webkit-outer-spin-button{height:auto}[hidden]:where(:not([hidden=until-found])){display:none!important}}@layer components;@layer utilities{.collapse{visibility:collapse}.visible{visibility:visible}.absolute{position:absolute}.fixed{position:fixed}.relative{position:relative}.static{position:static}.sticky{position:sticky}.right-0{right:calc(var(--spacing)*0)}.left-0{left:calc(var(--spacing)*0)}.isolate{isolation:isolate}.z-20{z-index:20}.\!container{width:100%!important}@media(min-width:40rem){.\!container{max-width:40rem!important}}@media(min-width:48rem){.\!container{max-width:48rem!important}}@media(min-width:64rem){.\!container{max-width:64rem!important}}@media(min-width:80rem){.\!container{max-width:80rem!important}}@media(min-width:96rem){.\!container{max-width:96rem!important}}.container{width:100%}@media(min-width:40rem){.container{max-width:40rem}}@media(min-width:48rem){.container{max-width:48rem}}@media(min-width:64rem){.container{max-width:64rem}}@media(min-width:80rem){.container{max-width:80rem}}@media(min-width:96rem){.container{max-width:96rem}}.m-3{margin:calc(var(--spacing)*3)}.mx-3{margin-inline:calc(var(--spacing)*3)}.my-0\.5{margin-block:calc(var(--spacing)*.5)}.my-1{margin-block:calc(var(--spacing)*1)}.my-2{margin-block:calc(var(--spacing)*2)}.ms-2{margin-inline-start:calc(var(--spacing)*2)}.ms-3{margin-inline-start:calc(var(--spacing)*3)}.ms-5{margin-inline-start:calc(var(--spacing)*5)}.me-1{margin-inline-end:calc(var(--spacing)*1)}.me-2{margin-inline-end:calc(var(--spacing)*2)}.me-3{margin-inline-end:calc(var(--spacing)*3)}.me-4{margin-inline-end:calc(var(--spacing)*4)}.me-5{margin-inline-end:calc(var(--spacing)*5)}.me-\[0\.75rem\]{margin-inline-end:.75rem}.mt-0\!{margin-top:calc(var(--spacing)*0)!important}.mt-1{margin-top:calc(var(--spacing)*1)}.mt-1\.5{margin-top:calc(var(--spacing)*1.5)}.mt-2{margin-top:calc(var(--spacing)*2)}.mt-2\.5{margin-top:calc(var(--spacing)*2.5)}.mt-3{margin-top:calc(var(--spacing)*3)}.mt-4{margin-top:calc(var(--spacing)*4)}.mt-\[1rem\]{margin-top:1rem}.mb-0\!{margin-bottom:calc(var(--spacing)*0)!important}.mb-2{margin-bottom:calc(var(--spacing)*2)}.\!hidden{display:none!important}.block{display:block}.contents{display:contents}.flex{display:flex}.hidden{display:none}.inline{display:inline}.inline-block{display:inline-block}.inline-flex{display:inline-flex}.table{display:table}.table-caption{display:table-caption}.table-cell{display:table-cell}.h-8{height:calc(var(--spacing)*8)}.h-\[1\.3rem\]{height:1.3rem}.h-\[16px\]{height:16px}.h-\[30px\]{height:30px}.h-\[var\(--input-height\)\]{height:var(--input-height)}.h-full{height:100%}.w-20{width:calc(var(--spacing)*20)}.w-50{width:calc(var(--spacing)*50)}.w-\[1\.3rem\]{width:1.3rem}.w-\[15\%\]{width:15%}.w-\[16px\]{width:16px}.w-\[20\%\]{width:20%}.w-\[30\%\]{width:30%}.w-\[35\%\]{width:35%}.w-\[200px\]{width:200px}.w-full{width:100%}.max-w-\[200px\]{max-width:200px}.flex-1{flex:1}.flex-shrink,.shrink{flex-shrink:1}.flex-grow,.grow{flex-grow:1}.translate-y-3{--tw-translate-y:calc(var(--spacing)*3);translate:var(--tw-translate-x)var(--tw-translate-y)}.translate-y-\[-6px\]{--tw-translate-y:-6px;translate:var(--tw-translate-x)var(--tw-translate-y)}.transform{transform:var(--tw-rotate-x,)var(--tw-rotate-y,)var(--tw-rotate-z,)var(--tw-skew-x,)var(--tw-skew-y,)}.cursor-not-allowed{cursor:not-allowed}.cursor-pointer{cursor:pointer}.resize{resize:both}.flex-col{flex-direction:column}.items-center{align-items:center}.justify-between{justify-content:space-between}.justify-center{justify-content:center}.justify-end{justify-content:flex-end}.gap-1{gap:calc(var(--spacing)*1)}.gap-4{gap:calc(var(--spacing)*4)}.truncate{text-overflow:ellipsis;white-space:nowrap;overflow:hidden}.overflow-hidden{overflow:hidden}.overflow-y-auto{overflow-y:auto}.rounded{border-radius:.25rem}.rounded-4xl{border-radius:var(--radius-4xl)}.rounded-lg{border-radius:var(--radius-lg)}.border{border-style:var(--tw-border-style);border-width:1px}.border-s{border-inline-start-style:var(--tw-border-style);border-inline-start-width:1px}.border-s-2{border-inline-start-style:var(--tw-border-style);border-inline-start-width:2px}.border-t{border-top-style:var(--tw-border-style);border-top-width:1px}.border-\[var\(--color-primary\)\]{border-color:var(--color-primary)}.border-\[var\(--theme-border-color\)\]{border-color:var(--theme-border-color)}.bg-\[var\(--color-primary\)\]{background-color:var(--color-primary)}.bg-\[var\(--theme-bg-color\)\]{background-color:var(--theme-bg-color)}.bg-transparent{background-color:#0000}.bg-\[image\:var\(--btn-dropdown\)\]{background-image:var(--btn-dropdown)}.bg-\[length\:\.75em_auto\]{background-size:.75em}.bg-center{background-position:50%}.bg-no-repeat{background-repeat:no-repeat}.p-3{padding:calc(var(--spacing)*3)}.px-2{padding-inline:calc(var(--spacing)*2)}.px-3{padding-inline:calc(var(--spacing)*3)}.px-4{padding-inline:calc(var(--spacing)*4)}.py-1{padding-block:calc(var(--spacing)*1)}.py-2{padding-block:calc(var(--spacing)*2)}.ps-2{padding-inline-start:calc(var(--spacing)*2)}.ps-4{padding-inline-start:calc(var(--spacing)*4)}.pe-2{padding-inline-end:calc(var(--spacing)*2)}.pe-3{padding-inline-end:calc(var(--spacing)*3)}.text-base{font-size:var(--text-base);line-height:var(--tw-leading,var(--text-base--line-height))}.text-xs{font-size:var(--text-xs);line-height:var(--tw-leading,var(--text-xs--line-height))}.text-\[\.8125rem\]{font-size:.8125rem}.text-\[14px\]{font-size:14px}.text-\[14px\]\!{font-size:14px!important}.text-\[18px\]{font-size:18px}.leading-\[1\.6\]{--tw-leading:1.6;line-height:1.6}.font-\[900\]{--tw-font-weight:900;font-weight:900}.font-bold{--tw-font-weight:var(--font-weight-bold);font-weight:var(--font-weight-bold)}.text-ellipsis{text-overflow:ellipsis}.whitespace-nowrap{white-space:nowrap}.text-\[var\(--theme-destructive-text-color\)\]{color:var(--theme-destructive-text-color)}.text-\[var\(--theme-negative-color\)\]{color:var(--theme-negative-color)}.text-\[var\(--theme-positive-color\)\]{color:var(--theme-positive-color)}.text-\[var\(--theme-subtitle-text-color\)\]{color:var(--theme-subtitle-text-color)}.text-\[var\(--theme-text-color\)\]{color:var(--theme-text-color)}.text-amber-300{color:var(--color-amber-300)}.text-amber-600{color:var(--color-amber-600)}.text-lime-500{color:var(--color-lime-500)}.text-sky-500{color:var(--color-sky-500)}.lowercase{text-transform:lowercase}.uppercase{text-transform:uppercase}.tabular-nums{--tw-numeric-spacing:tabular-nums;font-variant-numeric:var(--tw-ordinal,)var(--tw-slashed-zero,)var(--tw-numeric-figure,)var(--tw-numeric-spacing,)var(--tw-numeric-fraction,)}.opacity-50{opacity:.5}.shadow{--tw-shadow:0 1px 3px 0 var(--tw-shadow-color,#0000001a),0 1px 2px -1px var(--tw-shadow-color,#0000001a);box-shadow:var(--tw-inset-shadow),var(--tw-inset-ring-shadow),var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow)}.shadow-xs{--tw-shadow:0 1px 2px 0 var(--tw-shadow-color,#0000000d);box-shadow:var(--tw-inset-shadow),var(--tw-inset-ring-shadow),var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow)}.shadow-\[color\:var\(--theme-border-color\)\]{--tw-shadow-color:var(--theme-border-color)}@supports (color:color-mix(in lab,red,red)){.shadow-\[color\:var\(--theme-border-color\)\]{--tw-shadow-color:color-mix(in oklab,var(--theme-border-color)var(--tw-shadow-alpha),transparent)}}.blur{--tw-blur:blur(8px);filter:var(--tw-blur,)var(--tw-brightness,)var(--tw-contrast,)var(--tw-grayscale,)var(--tw-hue-rotate,)var(--tw-invert,)var(--tw-saturate,)var(--tw-sepia,)var(--tw-drop-shadow,)}.invert{--tw-invert:invert(100%);filter:var(--tw-blur,)var(--tw-brightness,)var(--tw-contrast,)var(--tw-grayscale,)var(--tw-hue-rotate,)var(--tw-invert,)var(--tw-saturate,)var(--tw-sepia,)var(--tw-drop-shadow,)}.\!filter{filter:var(--tw-blur,)var(--tw-brightness,)var(--tw-contrast,)var(--tw-grayscale,)var(--tw-hue-rotate,)var(--tw-invert,)var(--tw-saturate,)var(--tw-sepia,)var(--tw-drop-shadow,)!important}.filter{filter:var(--tw-blur,)var(--tw-brightness,)var(--tw-contrast,)var(--tw-grayscale,)var(--tw-hue-rotate,)var(--tw-invert,)var(--tw-saturate,)var(--tw-sepia,)var(--tw-drop-shadow,)}.backdrop-filter{-webkit-backdrop-filter:var(--tw-backdrop-blur,)var(--tw-backdrop-brightness,)var(--tw-backdrop-contrast,)var(--tw-backdrop-grayscale,)var(--tw-backdrop-hue-rotate,)var(--tw-backdrop-invert,)var(--tw-backdrop-opacity,)var(--tw-backdrop-saturate,)var(--tw-backdrop-sepia,);backdrop-filter:var(--tw-backdrop-blur,)var(--tw-backdrop-brightness,)var(--tw-backdrop-contrast,)var(--tw-backdrop-grayscale,)var(--tw-backdrop-hue-rotate,)var(--tw-backdrop-invert,)var(--tw-backdrop-opacity,)var(--tw-backdrop-saturate,)var(--tw-backdrop-sepia,)}.transition{transition-property:color,background-color,border-color,outline-color,text-decoration-color,fill,stroke,--tw-gradient-from,--tw-gradient-via,--tw-gradient-to,opacity,box-shadow,transform,translate,scale,rotate,filter,-webkit-backdrop-filter,backdrop-filter,display,content-visibility,overlay,pointer-events;transition-timing-function:var(--tw-ease,var(--default-transition-timing-function));transition-duration:var(--tw-duration,var(--default-transition-duration))}.transition-colors{transition-property:color,background-color,border-color,outline-color,text-decoration-color,fill,stroke,--tw-gradient-from,--tw-gradient-via,--tw-gradient-to;transition-timing-function:var(--tw-ease,var(--default-transition-timing-function));transition-duration:var(--tw-duration,var(--default-transition-duration))}.transition-transform{transition-property:transform,translate,scale,rotate;transition-timing-function:var(--tw-ease,var(--default-transition-timing-function));transition-duration:var(--tw-duration,var(--default-transition-duration))}.duration-250{--tw-duration:.25s;transition-duration:.25s}.ease-out{--tw-ease:var(--ease-out);transition-timing-function:var(--ease-out)}.outline-none{--tw-outline-style:none;outline-style:none}.select-none{-webkit-user-select:none;user-select:none}.\[--color-primary\:var\(--theme-hint-color\)\]{--color-primary:var(--theme-hint-color)}.\[--color-primary\:var\(--theme-negative-color\)\]{--color-primary:var(--theme-negative-color)}.\[--color-primary\:var\(--theme-positive-color\)\]{--color-primary:var(--theme-positive-color)}.focus-within\:border-\[var\(--color-primary\)\]:focus-within{border-color:var(--color-primary)}.focus-within\:border-\[var\(--theme-destructive-text-color\)\]:focus-within{border-color:var(--theme-destructive-text-color)}@media(hover:hover){.hover\:bg-\[var\(--theme-secondary-bg-color\)\]:hover{background-color:var(--theme-secondary-bg-color)}}}@property --tw-translate-x{syntax:"*";inherits:false;initial-value:0}@property --tw-translate-y{syntax:"*";inherits:false;initial-value:0}@property --tw-translate-z{syntax:"*";inherits:false;initial-value:0}@property --tw-rotate-x{syntax:"*";inherits:false}@property --tw-rotate-y{syntax:"*";inherits:false}@property --tw-rotate-z{syntax:"*";inherits:false}@property --tw-skew-x{syntax:"*";inherits:false}@property --tw-skew-y{syntax:"*";inherits:false}@property --tw-border-style{syntax:"*";inherits:false;initial-value:solid}@property --tw-leading{syntax:"*";inherits:false}@property --tw-font-weight{syntax:"*";inherits:false}@property --tw-ordinal{syntax:"*";inherits:false}@property --tw-slashed-zero{syntax:"*";inherits:false}@property --tw-numeric-figure{syntax:"*";inherits:false}@property --tw-numeric-spacing{syntax:"*";inherits:false}@property --tw-numeric-fraction{syntax:"*";inherits:false}@property --tw-shadow{syntax:"*";inherits:false;initial-value:0 0 #0000}@property --tw-shadow-color{syntax:"*";inherits:false}@property --tw-shadow-alpha{syntax:"<percentage>";inherits:false;initial-value:100%}@property --tw-inset-shadow{syntax:"*";inherits:false;initial-value:0 0 #0000}@property --tw-inset-shadow-color{syntax:"*";inherits:false}@property --tw-inset-shadow-alpha{syntax:"<percentage>";inherits:false;initial-value:100%}@property --tw-ring-color{syntax:"*";inherits:false}@property --tw-ring-shadow{syntax:"*";inherits:false;initial-value:0 0 #0000}@property --tw-inset-ring-color{syntax:"*";inherits:false}@property --tw-inset-ring-shadow{syntax:"*";inherits:false;initial-value:0 0 #0000}@property --tw-ring-inset{syntax:"*";inherits:false}@property --tw-ring-offset-width{syntax:"<length>";inherits:false;initial-value:0}@property --tw-ring-offset-color{syntax:"*";inherits:false;initial-value:#fff}@property --tw-ring-offset-shadow{syntax:"*";inherits:false;initial-value:0 0 #0000}@property --tw-blur{syntax:"*";inherits:false}@property --tw-brightness{syntax:"*";inherits:false}@property --tw-contrast{syntax:"*";inherits:false}@property --tw-grayscale{syntax:"*";inherits:false}@property --tw-hue-rotate{syntax:"*";inherits:false}@property --tw-invert{syntax:"*";inherits:false}@property --tw-opacity{syntax:"*";inherits:false}@property --tw-saturate{syntax:"*";inherits:false}@property --tw-sepia{syntax:"*";inherits:false}@property --tw-drop-shadow{syntax:"*";inherits:false}@property --tw-drop-shadow-color{syntax:"*";inherits:false}@property --tw-drop-shadow-alpha{syntax:"<percentage>";inherits:false;initial-value:100%}@property --tw-drop-shadow-size{syntax:"*";inherits:false}@property --tw-backdrop-blur{syntax:"*";inherits:false}@property --tw-backdrop-brightness{syntax:"*";inherits:false}@property --tw-backdrop-contrast{syntax:"*";inherits:false}@property --tw-backdrop-grayscale{syntax:"*";inherits:false}@property --tw-backdrop-hue-rotate{syntax:"*";inherits:false}@property --tw-backdrop-invert{syntax:"*";inherits:false}@property --tw-backdrop-opacity{syntax:"*";inherits:false}@property --tw-backdrop-saturate{syntax:"*";inherits:false}@property --tw-backdrop-sepia{syntax:"*";inherits:false}@property --tw-duration{syntax:"*";inherits:false}@property --tw-ease{syntax:"*";inherits:false}@font-face{font-family:Montserrat;src:url(/Montserrat-Regular.ttf) format("truetype");font-weight:400;font-style:normal}@font-face{font-family:Montserrat;src:url(/Montserrat-Bold.ttf) format("truetype");font-weight:700;font-style:normal}@font-face{font-family:Montserrat;src:url(/Montserrat-Italic.ttf) format("truetype");font-weight:400;font-style:italic}html,body{width:100%;height:100%}body{background:transparent!important;font-family:Montserrat,sans-serif!important;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;width:100%!important;height:100%!important;max-width:100%!important;max-height:100%!important;min-height:auto;min-width:auto;overflow:hidden;padding:0;transition:none;animation:none}:root{--color-scheme: dark;--color-primary: #067deb;--theme-accent-text-color: #6ab2f2;--theme-bg-color: #17212b;--theme-border-color: #2c3f52;--theme-button-color: var(--color-primary);--theme-button-text-color: #ffffff;--theme-destructive-text-color: #ec3942;--theme-header-bg-color: #17212b;--theme-hint-color: #708499;--theme-link-color: #6ab3f3;--theme-secondary-bg-color: #232e3c;--theme-section-bg-color: #17212b;--theme-section-header-text-color: #6ab3f3;--theme-section-separator-color: #111921;--theme-subtitle-text-color: #708499;--theme-text-color: #f5f5f5;--theme-positive-color: #0dad68;--theme-negative-color: #ca3b1f;--alert-success-color: #75b798;--alert-warning-color: #ffda6a;--alert-error-color: #ea868f;--alert-info-color: #6ea8fe;--input-height: 2.5rem;--font-size: 1rem;--btn-padding-x: .75rem;--btn-padding-y: .375rem;--btn-font-size: 1rem;--btn-font-weight: 400;--btn-line-height: 1.5;--btn-color: #212529;--btn-bg: transparent;--btn-border-width: 1px;--btn-border-color: transparent;--btn-border-radius: .375rem;--btn-hover-border-color: transparent;--btn-box-shadow: inset 0 1px 0 rgba(255, 255, 255, .15), 0 1px 1px rgba(0, 0, 0, .075);--btn-disabled-opacity: .65;--btn-focus-box-shadow: 0 0 0 .25rem rgba(var(--btn-focus-shadow-rgb), .5);--btn-close: url("data:image/svg+xml;charset=utf-8,%3Csvg xmlns=%27http://www.w3.org/2000/svg%27 viewBox=%270 0 16 16%27%3E%3Cpath d=%27M.293.293a1 1 0 0 1 1.414 0L8 6.586 14.293.293a1 1 0 1 1 1.414 1.414L9.414 8l6.293 6.293a1 1 0 0 1-1.414 1.414L8 9.414l-6.293 6.293a1 1 0 0 1-1.414-1.414L6.586 8 .293 1.707a1 1 0 0 1 0-1.414z%27/%3E%3C/svg%3E");--btn-plus: url(data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iMTYiIGhlaWdodD0iMTYiIHZpZXdCb3g9IjAgMCAxNiAxNiIgZmlsbD0ibm9uZSIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIj4KPHBhdGggZD0iTTggNEM4LjI3NjE0IDQgOC41IDQuMjIzODYgOC41IDQuNVY3LjVIMTEuNUMxMS43NzYxIDcuNSAxMiA3LjcyMzg2IDEyIDhDMTIgOC4yNzYxNCAxMS43NzYxIDguNSAxMS41IDguNUg4LjVWMTEuNUM4LjUgMTEuNzc2MSA4LjI3NjE0IDEyIDggMTJDNy43MjM4NiAxMiA3LjUgMTEuNzc2MSA3LjUgMTEuNVY4LjVINC41QzQuMjIzODYgOC41IDQgOC4yNzYxNCA0IDhDNCA3LjcyMzg2IDQuMjIzODYgNy41IDQuNSA3LjVINy41VjQuNUM3LjUgNC4yMjM4NiA3LjcyMzg2IDQgOCA0WiIgZmlsbD0iYmxhY2siLz4KPC9zdmc+Cg==);--btn-minus: url(data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iMTYiIGhlaWdodD0iMTYiIHZpZXdCb3g9IjAgMCAxNiAxNiIgZmlsbD0ibm9uZSIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIj4KPHBhdGggZD0iTTQgOEM0IDcuNzIzODYgNC4yMjM4NiA3LjUgNC41IDcuNUgxMS41QzExLjc3NjEgNy41IDEyIDcuNzIzODYgMTIgOEMxMiA4LjI3NjE0IDExLjc3NjEgOC41IDExLjUgOC41SDQuNUM0LjIyMzg2IDguNSA0IDguMjc2MTQgNCA4WiIgZmlsbD0iYmxhY2siLz4KPC9zdmc+Cg==);--btn-dropdown: url("data:image/svg+xml,%3csvg xmlns=%27http://www.w3.org/2000/svg%27 viewBox=%270 0 10 8%27%3e %3cpath d=%27M0.115385 4.4C0.0384615 4.32 0 4.2 0 4.12C0 4.04 0.0384615 3.92 0.115385 3.84L0.653846 3.28C0.807692 3.12 1.03846 3.12 1.19231 3.28L1.23077 3.32L3.34615 5.68C3.42308 5.76 3.53846 5.76 3.61538 5.68L8.76923 0.12H8.80769C8.96154 -0.04 9.19231 -0.04 9.34615 0.12L9.88461 0.68C10.0385 0.84 10.0385 1.08 9.88461 1.24L3.73077 7.88C3.65385 7.96 3.57692 8 3.46154 8C3.34615 8 3.26923 7.96 3.19231 7.88L0.192308 4.52L0.115385 4.4Z%27 fill=%27white%27/%3e %3c/svg%3e") }::-webkit-scrollbar{width:5px;height:8px}::-webkit-scrollbar-thumb{background-color:var(--theme-border-color);opacity:.1;border-radius:4px}::-webkit-scrollbar-track{background:var(--theme-bg-color);border-end-end-radius:.375rem;border-start-end-radius:.375rem}.btn{--btn-color: #fff;--btn-bg: var(--color-primary);--btn-border-color: var(--color-primary);--btn-hover-color: #fff;--btn-hover-bg: color-mix(in srgb, var(--color-primary) 87%, black);--btn-hover-border-color: color-mix(in srgb, var(--color-primary) 84%, black);--btn-focus-shadow-rgb: 49, 132, 253;--btn-active-color: #fff;--btn-active-bg: color-mix(in srgb, var(--color-primary) 75%, black);--btn-active-border-color: color-mix(in srgb, var(--color-primary) 72%, black);--btn-active-shadow: inset 0 3px 5px rgba(0, 0, 0, .125);--btn-disabled-color: #fff;--btn-disabled-bg: color-mix(in srgb, var(--color-primary) 87%, black);--btn-disabled-border-color: color-mix(in srgb, var(--color-primary) 87%, black)}.alert{--alert-color: var(--alert-success-color);--alert-bg: color-mix(in srgb, var(--alert-color) 20%, black);--alert-border-color: color-mix(in srgb, var(--alert-color) 65%, black);--alert-link-color: var(--alert-color);--alert-btn-color: var(--alert-color);--alert-btn-bg-color:var(--alert-bg);--alert-btn-border-color: var(--alert-border-color);--alert-btn-hover-bg: color-mix(in srgb, var(--alert-color) 87%, black);--alert-btn-active-bg: color-mix(in srgb, var(--alert-color) 75%, black);--alert-border-radius: .375rem;background-color:var(--alert-bg);border:1px solid var(--alert-border-color);color:var(--alert-color);border-radius:var(--alert-border-radius)}.tabular-nums{font-variant-numeric:tabular-nums}
|
|
1
|
+
@layer properties{@supports (((-webkit-hyphens:none)) and (not (margin-trim:inline))) or ((-moz-orient:inline) and (not (color:rgb(from red r g b)))){*,:before,:after,::backdrop{--tw-translate-x:0;--tw-translate-y:0;--tw-translate-z:0;--tw-rotate-x:initial;--tw-rotate-y:initial;--tw-rotate-z:initial;--tw-skew-x:initial;--tw-skew-y:initial;--tw-border-style:solid;--tw-leading:initial;--tw-font-weight:initial;--tw-ordinal:initial;--tw-slashed-zero:initial;--tw-numeric-figure:initial;--tw-numeric-spacing:initial;--tw-numeric-fraction:initial;--tw-shadow:0 0 #0000;--tw-shadow-color:initial;--tw-shadow-alpha:100%;--tw-inset-shadow:0 0 #0000;--tw-inset-shadow-color:initial;--tw-inset-shadow-alpha:100%;--tw-ring-color:initial;--tw-ring-shadow:0 0 #0000;--tw-inset-ring-color:initial;--tw-inset-ring-shadow:0 0 #0000;--tw-ring-inset:initial;--tw-ring-offset-width:0px;--tw-ring-offset-color:#fff;--tw-ring-offset-shadow:0 0 #0000;--tw-blur:initial;--tw-brightness:initial;--tw-contrast:initial;--tw-grayscale:initial;--tw-hue-rotate:initial;--tw-invert:initial;--tw-opacity:initial;--tw-saturate:initial;--tw-sepia:initial;--tw-drop-shadow:initial;--tw-drop-shadow-color:initial;--tw-drop-shadow-alpha:100%;--tw-drop-shadow-size:initial;--tw-backdrop-blur:initial;--tw-backdrop-brightness:initial;--tw-backdrop-contrast:initial;--tw-backdrop-grayscale:initial;--tw-backdrop-hue-rotate:initial;--tw-backdrop-invert:initial;--tw-backdrop-opacity:initial;--tw-backdrop-saturate:initial;--tw-backdrop-sepia:initial;--tw-duration:initial;--tw-ease:initial}}}@layer theme{:root,:host{--font-sans:ui-sans-serif,system-ui,sans-serif,"Apple Color Emoji","Segoe UI Emoji","Segoe UI Symbol","Noto Color Emoji";--font-mono:ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,"Liberation Mono","Courier New",monospace;--color-amber-300:oklch(87.9% .169 91.605);--color-amber-600:oklch(66.6% .179 58.318);--color-lime-500:oklch(76.8% .233 130.85);--color-sky-500:oklch(68.5% .169 237.323);--spacing:.25rem;--text-xs:.75rem;--text-xs--line-height:calc(1/.75);--text-base:1rem;--text-base--line-height: 1.5 ;--font-weight-bold:700;--radius-lg:.5rem;--radius-4xl:2rem;--ease-out:cubic-bezier(0,0,.2,1);--default-transition-duration:.15s;--default-transition-timing-function:cubic-bezier(.4,0,.2,1);--default-font-family:var(--font-sans);--default-mono-font-family:var(--font-mono)}}@layer base{*,:after,:before,::backdrop{box-sizing:border-box;border:0 solid;margin:0;padding:0}::file-selector-button{box-sizing:border-box;border:0 solid;margin:0;padding:0}html,:host{-webkit-text-size-adjust:100%;tab-size:4;line-height:1.5;font-family:var(--default-font-family,ui-sans-serif,system-ui,sans-serif,"Apple Color Emoji","Segoe UI Emoji","Segoe UI Symbol","Noto Color Emoji");font-feature-settings:var(--default-font-feature-settings,normal);font-variation-settings:var(--default-font-variation-settings,normal);-webkit-tap-highlight-color:transparent}hr{height:0;color:inherit;border-top-width:1px}abbr:where([title]){-webkit-text-decoration:underline dotted;text-decoration:underline dotted}h1,h2,h3,h4,h5,h6{font-size:inherit;font-weight:inherit}a{color:inherit;-webkit-text-decoration:inherit;text-decoration:inherit}b,strong{font-weight:bolder}code,kbd,samp,pre{font-family:var(--default-mono-font-family,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,"Liberation Mono","Courier New",monospace);font-feature-settings:var(--default-mono-font-feature-settings,normal);font-variation-settings:var(--default-mono-font-variation-settings,normal);font-size:1em}small{font-size:80%}sub,sup{vertical-align:baseline;font-size:75%;line-height:0;position:relative}sub{bottom:-.25em}sup{top:-.5em}table{text-indent:0;border-color:inherit;border-collapse:collapse}:-moz-focusring{outline:auto}progress{vertical-align:baseline}summary{display:list-item}ol,ul,menu{list-style:none}img,svg,video,canvas,audio,iframe,embed,object{vertical-align:middle;display:block}img,video{max-width:100%;height:auto}button,input,select,optgroup,textarea{font:inherit;font-feature-settings:inherit;font-variation-settings:inherit;letter-spacing:inherit;color:inherit;opacity:1;background-color:#0000;border-radius:0}::file-selector-button{font:inherit;font-feature-settings:inherit;font-variation-settings:inherit;letter-spacing:inherit;color:inherit;opacity:1;background-color:#0000;border-radius:0}:where(select:is([multiple],[size])) optgroup{font-weight:bolder}:where(select:is([multiple],[size])) optgroup option{padding-inline-start:20px}::file-selector-button{margin-inline-end:4px}::placeholder{opacity:1}@supports (not ((-webkit-appearance:-apple-pay-button))) or (contain-intrinsic-size:1px){::placeholder{color:currentColor}@supports (color:color-mix(in lab,red,red)){::placeholder{color:color-mix(in oklab,currentcolor 50%,transparent)}}}textarea{resize:vertical}::-webkit-search-decoration{-webkit-appearance:none}::-webkit-date-and-time-value{min-height:1lh;text-align:inherit}::-webkit-datetime-edit{display:inline-flex}::-webkit-datetime-edit-fields-wrapper{padding:0}::-webkit-datetime-edit{padding-block:0}::-webkit-datetime-edit-year-field{padding-block:0}::-webkit-datetime-edit-month-field{padding-block:0}::-webkit-datetime-edit-day-field{padding-block:0}::-webkit-datetime-edit-hour-field{padding-block:0}::-webkit-datetime-edit-minute-field{padding-block:0}::-webkit-datetime-edit-second-field{padding-block:0}::-webkit-datetime-edit-millisecond-field{padding-block:0}::-webkit-datetime-edit-meridiem-field{padding-block:0}::-webkit-calendar-picker-indicator{line-height:1}:-moz-ui-invalid{box-shadow:none}button,input:where([type=button],[type=reset],[type=submit]){appearance:button}::file-selector-button{appearance:button}::-webkit-inner-spin-button{height:auto}::-webkit-outer-spin-button{height:auto}[hidden]:where(:not([hidden=until-found])){display:none!important}}@layer components;@layer utilities{.visible{visibility:visible}.absolute{position:absolute}.fixed{position:fixed}.relative{position:relative}.static{position:static}.right-0{right:calc(var(--spacing)*0)}.left-0{left:calc(var(--spacing)*0)}.z-20{z-index:20}.container{width:100%}@media(min-width:40rem){.container{max-width:40rem}}@media(min-width:48rem){.container{max-width:48rem}}@media(min-width:64rem){.container{max-width:64rem}}@media(min-width:80rem){.container{max-width:80rem}}@media(min-width:96rem){.container{max-width:96rem}}.m-3{margin:calc(var(--spacing)*3)}.mx-3{margin-inline:calc(var(--spacing)*3)}.my-0\.5{margin-block:calc(var(--spacing)*.5)}.my-1{margin-block:calc(var(--spacing)*1)}.my-2{margin-block:calc(var(--spacing)*2)}.ms-2{margin-inline-start:calc(var(--spacing)*2)}.ms-3{margin-inline-start:calc(var(--spacing)*3)}.ms-5{margin-inline-start:calc(var(--spacing)*5)}.me-1{margin-inline-end:calc(var(--spacing)*1)}.me-2{margin-inline-end:calc(var(--spacing)*2)}.me-3{margin-inline-end:calc(var(--spacing)*3)}.me-4{margin-inline-end:calc(var(--spacing)*4)}.me-5{margin-inline-end:calc(var(--spacing)*5)}.me-\[0\.75rem\]{margin-inline-end:.75rem}.mt-0\!{margin-top:calc(var(--spacing)*0)!important}.mt-1{margin-top:calc(var(--spacing)*1)}.mt-1\.5{margin-top:calc(var(--spacing)*1.5)}.mt-2{margin-top:calc(var(--spacing)*2)}.mt-2\.5{margin-top:calc(var(--spacing)*2.5)}.mt-3{margin-top:calc(var(--spacing)*3)}.mt-4{margin-top:calc(var(--spacing)*4)}.mt-\[1rem\]{margin-top:1rem}.mb-0\!{margin-bottom:calc(var(--spacing)*0)!important}.mb-2{margin-bottom:calc(var(--spacing)*2)}.block{display:block}.contents{display:contents}.flex{display:flex}.hidden{display:none}.inline{display:inline}.inline-block{display:inline-block}.inline-flex{display:inline-flex}.table{display:table}.h-8{height:calc(var(--spacing)*8)}.h-\[1\.3rem\]{height:1.3rem}.h-\[16px\]{height:16px}.h-\[30px\]{height:30px}.h-\[var\(--input-height\)\]{height:var(--input-height)}.h-full{height:100%}.w-20{width:calc(var(--spacing)*20)}.w-50{width:calc(var(--spacing)*50)}.w-\[1\.3rem\]{width:1.3rem}.w-\[15\%\]{width:15%}.w-\[16px\]{width:16px}.w-\[20\%\]{width:20%}.w-\[30\%\]{width:30%}.w-\[35\%\]{width:35%}.w-\[200px\]{width:200px}.w-full{width:100%}.max-w-\[200px\]{max-width:200px}.flex-1{flex:1}.shrink{flex-shrink:1}.grow{flex-grow:1}.translate-y-3{--tw-translate-y:calc(var(--spacing)*3);translate:var(--tw-translate-x)var(--tw-translate-y)}.translate-y-\[-6px\]{--tw-translate-y:-6px;translate:var(--tw-translate-x)var(--tw-translate-y)}.transform{transform:var(--tw-rotate-x,)var(--tw-rotate-y,)var(--tw-rotate-z,)var(--tw-skew-x,)var(--tw-skew-y,)}.cursor-not-allowed{cursor:not-allowed}.cursor-pointer{cursor:pointer}.resize{resize:both}.flex-col{flex-direction:column}.items-center{align-items:center}.justify-between{justify-content:space-between}.justify-center{justify-content:center}.justify-end{justify-content:flex-end}.gap-1{gap:calc(var(--spacing)*1)}.gap-4{gap:calc(var(--spacing)*4)}.overflow-hidden{overflow:hidden}.overflow-y-auto{overflow-y:auto}.rounded-4xl{border-radius:var(--radius-4xl)}.rounded-lg{border-radius:var(--radius-lg)}.border{border-style:var(--tw-border-style);border-width:1px}.border-s{border-inline-start-style:var(--tw-border-style);border-inline-start-width:1px}.border-s-2{border-inline-start-style:var(--tw-border-style);border-inline-start-width:2px}.border-t{border-top-style:var(--tw-border-style);border-top-width:1px}.border-\[var\(--color-primary\)\]{border-color:var(--color-primary)}.border-\[var\(--theme-border-color\)\]{border-color:var(--theme-border-color)}.bg-\[var\(--color-primary\)\]{background-color:var(--color-primary)}.bg-\[var\(--theme-bg-color\)\]{background-color:var(--theme-bg-color)}.bg-transparent{background-color:#0000}.bg-\[image\:var\(--btn-dropdown\)\]{background-image:var(--btn-dropdown)}.bg-\[length\:\.75em_auto\]{background-size:.75em}.bg-center{background-position:50%}.bg-no-repeat{background-repeat:no-repeat}.p-3{padding:calc(var(--spacing)*3)}.px-2{padding-inline:calc(var(--spacing)*2)}.px-3{padding-inline:calc(var(--spacing)*3)}.px-4{padding-inline:calc(var(--spacing)*4)}.py-1{padding-block:calc(var(--spacing)*1)}.py-2{padding-block:calc(var(--spacing)*2)}.ps-2{padding-inline-start:calc(var(--spacing)*2)}.ps-4{padding-inline-start:calc(var(--spacing)*4)}.pe-2{padding-inline-end:calc(var(--spacing)*2)}.pe-3{padding-inline-end:calc(var(--spacing)*3)}.text-base{font-size:var(--text-base);line-height:var(--tw-leading,var(--text-base--line-height))}.text-xs{font-size:var(--text-xs);line-height:var(--tw-leading,var(--text-xs--line-height))}.text-\[\.8125rem\]{font-size:.8125rem}.text-\[14px\]{font-size:14px}.text-\[14px\]\!{font-size:14px!important}.text-\[18px\]{font-size:18px}.leading-\[1\.6\]{--tw-leading:1.6;line-height:1.6}.font-\[900\]{--tw-font-weight:900;font-weight:900}.font-bold{--tw-font-weight:var(--font-weight-bold);font-weight:var(--font-weight-bold)}.text-ellipsis{text-overflow:ellipsis}.whitespace-nowrap{white-space:nowrap}.text-\[var\(--theme-destructive-text-color\)\]{color:var(--theme-destructive-text-color)}.text-\[var\(--theme-negative-color\)\]{color:var(--theme-negative-color)}.text-\[var\(--theme-positive-color\)\]{color:var(--theme-positive-color)}.text-\[var\(--theme-subtitle-text-color\)\]{color:var(--theme-subtitle-text-color)}.text-\[var\(--theme-text-color\)\]{color:var(--theme-text-color)}.text-amber-300{color:var(--color-amber-300)}.text-amber-600{color:var(--color-amber-600)}.text-lime-500{color:var(--color-lime-500)}.text-sky-500{color:var(--color-sky-500)}.uppercase{text-transform:uppercase}.tabular-nums{--tw-numeric-spacing:tabular-nums;font-variant-numeric:var(--tw-ordinal,)var(--tw-slashed-zero,)var(--tw-numeric-figure,)var(--tw-numeric-spacing,)var(--tw-numeric-fraction,)}.opacity-50{opacity:.5}.shadow-xs{--tw-shadow:0 1px 2px 0 var(--tw-shadow-color,#0000000d);box-shadow:var(--tw-inset-shadow),var(--tw-inset-ring-shadow),var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow)}.shadow-\[color\:var\(--theme-border-color\)\]{--tw-shadow-color:var(--theme-border-color)}@supports (color:color-mix(in lab,red,red)){.shadow-\[color\:var\(--theme-border-color\)\]{--tw-shadow-color:color-mix(in oklab,var(--theme-border-color)var(--tw-shadow-alpha),transparent)}}.blur{--tw-blur:blur(8px);filter:var(--tw-blur,)var(--tw-brightness,)var(--tw-contrast,)var(--tw-grayscale,)var(--tw-hue-rotate,)var(--tw-invert,)var(--tw-saturate,)var(--tw-sepia,)var(--tw-drop-shadow,)}.filter{filter:var(--tw-blur,)var(--tw-brightness,)var(--tw-contrast,)var(--tw-grayscale,)var(--tw-hue-rotate,)var(--tw-invert,)var(--tw-saturate,)var(--tw-sepia,)var(--tw-drop-shadow,)}.backdrop-filter{-webkit-backdrop-filter:var(--tw-backdrop-blur,)var(--tw-backdrop-brightness,)var(--tw-backdrop-contrast,)var(--tw-backdrop-grayscale,)var(--tw-backdrop-hue-rotate,)var(--tw-backdrop-invert,)var(--tw-backdrop-opacity,)var(--tw-backdrop-saturate,)var(--tw-backdrop-sepia,);backdrop-filter:var(--tw-backdrop-blur,)var(--tw-backdrop-brightness,)var(--tw-backdrop-contrast,)var(--tw-backdrop-grayscale,)var(--tw-backdrop-hue-rotate,)var(--tw-backdrop-invert,)var(--tw-backdrop-opacity,)var(--tw-backdrop-saturate,)var(--tw-backdrop-sepia,)}.transition{transition-property:color,background-color,border-color,outline-color,text-decoration-color,fill,stroke,--tw-gradient-from,--tw-gradient-via,--tw-gradient-to,opacity,box-shadow,transform,translate,scale,rotate,filter,-webkit-backdrop-filter,backdrop-filter,display,content-visibility,overlay,pointer-events;transition-timing-function:var(--tw-ease,var(--default-transition-timing-function));transition-duration:var(--tw-duration,var(--default-transition-duration))}.transition-colors{transition-property:color,background-color,border-color,outline-color,text-decoration-color,fill,stroke,--tw-gradient-from,--tw-gradient-via,--tw-gradient-to;transition-timing-function:var(--tw-ease,var(--default-transition-timing-function));transition-duration:var(--tw-duration,var(--default-transition-duration))}.transition-transform{transition-property:transform,translate,scale,rotate;transition-timing-function:var(--tw-ease,var(--default-transition-timing-function));transition-duration:var(--tw-duration,var(--default-transition-duration))}.duration-250{--tw-duration:.25s;transition-duration:.25s}.ease-out{--tw-ease:var(--ease-out);transition-timing-function:var(--ease-out)}.outline-none{--tw-outline-style:none;outline-style:none}.select-none{-webkit-user-select:none;user-select:none}.\[--color-primary\:var\(--theme-hint-color\)\]{--color-primary:var(--theme-hint-color)}.\[--color-primary\:var\(--theme-negative-color\)\]{--color-primary:var(--theme-negative-color)}.\[--color-primary\:var\(--theme-positive-color\)\]{--color-primary:var(--theme-positive-color)}.focus-within\:border-\[var\(--color-primary\)\]:focus-within{border-color:var(--color-primary)}.focus-within\:border-\[var\(--theme-destructive-text-color\)\]:focus-within{border-color:var(--theme-destructive-text-color)}@media(hover:hover){.hover\:bg-\[var\(--theme-secondary-bg-color\)\]:hover{background-color:var(--theme-secondary-bg-color)}}}@property --tw-translate-x{syntax:"*";inherits:false;initial-value:0}@property --tw-translate-y{syntax:"*";inherits:false;initial-value:0}@property --tw-translate-z{syntax:"*";inherits:false;initial-value:0}@property --tw-rotate-x{syntax:"*";inherits:false}@property --tw-rotate-y{syntax:"*";inherits:false}@property --tw-rotate-z{syntax:"*";inherits:false}@property --tw-skew-x{syntax:"*";inherits:false}@property --tw-skew-y{syntax:"*";inherits:false}@property --tw-border-style{syntax:"*";inherits:false;initial-value:solid}@property --tw-leading{syntax:"*";inherits:false}@property --tw-font-weight{syntax:"*";inherits:false}@property --tw-ordinal{syntax:"*";inherits:false}@property --tw-slashed-zero{syntax:"*";inherits:false}@property --tw-numeric-figure{syntax:"*";inherits:false}@property --tw-numeric-spacing{syntax:"*";inherits:false}@property --tw-numeric-fraction{syntax:"*";inherits:false}@property --tw-shadow{syntax:"*";inherits:false;initial-value:0 0 #0000}@property --tw-shadow-color{syntax:"*";inherits:false}@property --tw-shadow-alpha{syntax:"<percentage>";inherits:false;initial-value:100%}@property --tw-inset-shadow{syntax:"*";inherits:false;initial-value:0 0 #0000}@property --tw-inset-shadow-color{syntax:"*";inherits:false}@property --tw-inset-shadow-alpha{syntax:"<percentage>";inherits:false;initial-value:100%}@property --tw-ring-color{syntax:"*";inherits:false}@property --tw-ring-shadow{syntax:"*";inherits:false;initial-value:0 0 #0000}@property --tw-inset-ring-color{syntax:"*";inherits:false}@property --tw-inset-ring-shadow{syntax:"*";inherits:false;initial-value:0 0 #0000}@property --tw-ring-inset{syntax:"*";inherits:false}@property --tw-ring-offset-width{syntax:"<length>";inherits:false;initial-value:0}@property --tw-ring-offset-color{syntax:"*";inherits:false;initial-value:#fff}@property --tw-ring-offset-shadow{syntax:"*";inherits:false;initial-value:0 0 #0000}@property --tw-blur{syntax:"*";inherits:false}@property --tw-brightness{syntax:"*";inherits:false}@property --tw-contrast{syntax:"*";inherits:false}@property --tw-grayscale{syntax:"*";inherits:false}@property --tw-hue-rotate{syntax:"*";inherits:false}@property --tw-invert{syntax:"*";inherits:false}@property --tw-opacity{syntax:"*";inherits:false}@property --tw-saturate{syntax:"*";inherits:false}@property --tw-sepia{syntax:"*";inherits:false}@property --tw-drop-shadow{syntax:"*";inherits:false}@property --tw-drop-shadow-color{syntax:"*";inherits:false}@property --tw-drop-shadow-alpha{syntax:"<percentage>";inherits:false;initial-value:100%}@property --tw-drop-shadow-size{syntax:"*";inherits:false}@property --tw-backdrop-blur{syntax:"*";inherits:false}@property --tw-backdrop-brightness{syntax:"*";inherits:false}@property --tw-backdrop-contrast{syntax:"*";inherits:false}@property --tw-backdrop-grayscale{syntax:"*";inherits:false}@property --tw-backdrop-hue-rotate{syntax:"*";inherits:false}@property --tw-backdrop-invert{syntax:"*";inherits:false}@property --tw-backdrop-opacity{syntax:"*";inherits:false}@property --tw-backdrop-saturate{syntax:"*";inherits:false}@property --tw-backdrop-sepia{syntax:"*";inherits:false}@property --tw-duration{syntax:"*";inherits:false}@property --tw-ease{syntax:"*";inherits:false}@font-face{font-family:Montserrat;src:url(/Montserrat-Regular.ttf) format("truetype");font-weight:400;font-style:normal}@font-face{font-family:Montserrat;src:url(/Montserrat-Bold.ttf) format("truetype");font-weight:700;font-style:normal}@font-face{font-family:Montserrat;src:url(/Montserrat-Italic.ttf) format("truetype");font-weight:400;font-style:italic}html,body{width:100%;height:100%}body{background:transparent!important;font-family:Montserrat,sans-serif!important;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;width:100%!important;height:100%!important;max-width:100%!important;max-height:100%!important;min-height:auto;min-width:auto;overflow:hidden;padding:0;transition:none;animation:none}:root{--color-scheme: dark;--color-primary: #067deb;--theme-accent-text-color: #6ab2f2;--theme-bg-color: #17212b;--theme-border-color: #2c3f52;--theme-button-color: var(--color-primary);--theme-button-text-color: #ffffff;--theme-destructive-text-color: #ec3942;--theme-header-bg-color: #17212b;--theme-hint-color: #708499;--theme-link-color: #6ab3f3;--theme-secondary-bg-color: #232e3c;--theme-section-bg-color: #17212b;--theme-section-header-text-color: #6ab3f3;--theme-section-separator-color: #111921;--theme-subtitle-text-color: #708499;--theme-text-color: #f5f5f5;--theme-positive-color: #0dad68;--theme-negative-color: #ca3b1f;--alert-success-color: #75b798;--alert-warning-color: #ffda6a;--alert-error-color: #ea868f;--alert-info-color: #6ea8fe;--input-height: 2.5rem;--font-size: 1rem;--btn-padding-x: .75rem;--btn-padding-y: .375rem;--btn-font-size: 1rem;--btn-font-weight: 400;--btn-line-height: 1.5;--btn-color: #212529;--btn-bg: transparent;--btn-border-width: 1px;--btn-border-color: transparent;--btn-border-radius: .375rem;--btn-hover-border-color: transparent;--btn-box-shadow: inset 0 1px 0 rgba(255, 255, 255, .15), 0 1px 1px rgba(0, 0, 0, .075);--btn-disabled-opacity: .65;--btn-focus-box-shadow: 0 0 0 .25rem rgba(var(--btn-focus-shadow-rgb), .5);--btn-close: url("data:image/svg+xml;charset=utf-8,%3Csvg xmlns=%27http://www.w3.org/2000/svg%27 viewBox=%270 0 16 16%27%3E%3Cpath d=%27M.293.293a1 1 0 0 1 1.414 0L8 6.586 14.293.293a1 1 0 1 1 1.414 1.414L9.414 8l6.293 6.293a1 1 0 0 1-1.414 1.414L8 9.414l-6.293 6.293a1 1 0 0 1-1.414-1.414L6.586 8 .293 1.707a1 1 0 0 1 0-1.414z%27/%3E%3C/svg%3E");--btn-plus: url(data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iMTYiIGhlaWdodD0iMTYiIHZpZXdCb3g9IjAgMCAxNiAxNiIgZmlsbD0ibm9uZSIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIj4KPHBhdGggZD0iTTggNEM4LjI3NjE0IDQgOC41IDQuMjIzODYgOC41IDQuNVY3LjVIMTEuNUMxMS43NzYxIDcuNSAxMiA3LjcyMzg2IDEyIDhDMTIgOC4yNzYxNCAxMS43NzYxIDguNSAxMS41IDguNUg4LjVWMTEuNUM4LjUgMTEuNzc2MSA4LjI3NjE0IDEyIDggMTJDNy43MjM4NiAxMiA3LjUgMTEuNzc2MSA3LjUgMTEuNVY4LjVINC41QzQuMjIzODYgOC41IDQgOC4yNzYxNCA0IDhDNCA3LjcyMzg2IDQuMjIzODYgNy41IDQuNSA3LjVINy41VjQuNUM3LjUgNC4yMjM4NiA3LjcyMzg2IDQgOCA0WiIgZmlsbD0iYmxhY2siLz4KPC9zdmc+Cg==);--btn-minus: url(data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iMTYiIGhlaWdodD0iMTYiIHZpZXdCb3g9IjAgMCAxNiAxNiIgZmlsbD0ibm9uZSIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIj4KPHBhdGggZD0iTTQgOEM0IDcuNzIzODYgNC4yMjM4NiA3LjUgNC41IDcuNUgxMS41QzExLjc3NjEgNy41IDEyIDcuNzIzODYgMTIgOEMxMiA4LjI3NjE0IDExLjc3NjEgOC41IDExLjUgOC41SDQuNUM0LjIyMzg2IDguNSA0IDguMjc2MTQgNCA4WiIgZmlsbD0iYmxhY2siLz4KPC9zdmc+Cg==);--btn-dropdown: url("data:image/svg+xml,%3csvg xmlns=%27http://www.w3.org/2000/svg%27 viewBox=%270 0 10 8%27%3e %3cpath d=%27M0.115385 4.4C0.0384615 4.32 0 4.2 0 4.12C0 4.04 0.0384615 3.92 0.115385 3.84L0.653846 3.28C0.807692 3.12 1.03846 3.12 1.19231 3.28L1.23077 3.32L3.34615 5.68C3.42308 5.76 3.53846 5.76 3.61538 5.68L8.76923 0.12H8.80769C8.96154 -0.04 9.19231 -0.04 9.34615 0.12L9.88461 0.68C10.0385 0.84 10.0385 1.08 9.88461 1.24L3.73077 7.88C3.65385 7.96 3.57692 8 3.46154 8C3.34615 8 3.26923 7.96 3.19231 7.88L0.192308 4.52L0.115385 4.4Z%27 fill=%27white%27/%3e %3c/svg%3e") }::-webkit-scrollbar{width:5px;height:8px}::-webkit-scrollbar-thumb{background-color:var(--theme-border-color);opacity:.1;border-radius:4px}::-webkit-scrollbar-track{background:var(--theme-bg-color);border-end-end-radius:.375rem;border-start-end-radius:.375rem}.btn{--btn-color: #fff;--btn-bg: var(--color-primary);--btn-border-color: var(--color-primary);--btn-hover-color: #fff;--btn-hover-bg: color-mix(in srgb, var(--color-primary) 87%, black);--btn-hover-border-color: color-mix(in srgb, var(--color-primary) 84%, black);--btn-focus-shadow-rgb: 49, 132, 253;--btn-active-color: #fff;--btn-active-bg: color-mix(in srgb, var(--color-primary) 75%, black);--btn-active-border-color: color-mix(in srgb, var(--color-primary) 72%, black);--btn-active-shadow: inset 0 3px 5px rgba(0, 0, 0, .125);--btn-disabled-color: #fff;--btn-disabled-bg: color-mix(in srgb, var(--color-primary) 87%, black);--btn-disabled-border-color: color-mix(in srgb, var(--color-primary) 87%, black)}.alert{--alert-color: var(--alert-success-color);--alert-bg: color-mix(in srgb, var(--alert-color) 20%, black);--alert-border-color: color-mix(in srgb, var(--alert-color) 65%, black);--alert-link-color: var(--alert-color);--alert-btn-color: var(--alert-color);--alert-btn-bg-color:var(--alert-bg);--alert-btn-border-color: var(--alert-border-color);--alert-btn-hover-bg: color-mix(in srgb, var(--alert-color) 87%, black);--alert-btn-active-bg: color-mix(in srgb, var(--alert-color) 75%, black);--alert-border-radius: .375rem;background-color:var(--alert-bg);border:1px solid var(--alert-border-color);color:var(--alert-color);border-radius:var(--alert-border-radius)}.tabular-nums{font-variant-numeric:tabular-nums}
|
package/dist/index.js
CHANGED
|
@@ -598,4 +598,4 @@ function e(e){return e&&e.i&&Object.prototype.hasOwnProperty.call(e,"default")?e
|
|
|
598
598
|
background: rgba(0, 0, 0, 0);
|
|
599
599
|
backdrop-filter: blur(0rem);
|
|
600
600
|
}
|
|
601
|
-
`;function qc(){const e=ee(),{data:t}=yu();return d.useEffect(()=>{t&&e(mr(t))},[t]),s.jsx(Lc,{})}const zc={status:Xn.NOT_CONNECT,signals:[],candles:{}},Bc=gn({name:"websocket",initialState:zc,reducers:{wsStatus:(e,t)=>{e.status=t.payload},pushSignal:(e,t)=>{e.signals.unshift(t.payload),e.signals.splice(30)},setSignalsHistory:(e,t)=>{e.signals=[...t.payload]},setCandles:(e,t)=>{e.candles=t.payload}}}),{wsStatus:Hc,pushSignal:Wc,setSignalsHistory:Uc,setCandles:Qc}=Bc.actions;var Vc,Kc={exports:{}};var Gc=function(){if(Vc)return Kc.exports;Vc=1;var e,t="object"==typeof Reflect?Reflect:null,n=t&&"function"==typeof t.apply?t.apply:function(e,t,n){return Function.prototype.apply.call(e,t,n)};e=t&&"function"==typeof t.ownKeys?t.ownKeys:Object.getOwnPropertySymbols?function(e){return Object.getOwnPropertyNames(e).concat(Object.getOwnPropertySymbols(e))}:function(e){return Object.getOwnPropertyNames(e)};var r=Number.isNaN||function(e){return e!=e};function i(){i.init.call(this)}Kc.exports=i,Kc.exports.once=function(e,t){return new Promise(function(n,r){function i(n){e.removeListener(t,a),r(n)}function a(){"function"==typeof e.removeListener&&e.removeListener("error",i),n([].slice.call(arguments))}p(e,t,a,{once:!0}),"error"!==t&&function(e,t,n){"function"==typeof e.on&&p(e,"error",t,n)}(e,i,{once:!0})})},i.EventEmitter=i,i.prototype._events=void 0,i.prototype._eventsCount=0,i.prototype._maxListeners=void 0;var a=10;function o(e){if("function"!=typeof e)throw new TypeError('The "listener" argument must be of type Function. Received type '+typeof e)}function s(e){return void 0===e._maxListeners?i.defaultMaxListeners:e._maxListeners}function l(e,t,n,r){var i,a,l;if(o(n),void 0===(a=e._events)?(a=e._events=Object.create(null),e._eventsCount=0):(void 0!==a.newListener&&(e.emit("newListener",t,n.listener?n.listener:n),a=e._events),l=a[t]),void 0===l)l=a[t]=n,++e._eventsCount;else if("function"==typeof l?l=a[t]=r?[n,l]:[l,n]:r?l.unshift(n):l.push(n),(i=s(e))>0&&l.length>i&&!l.warned){l.warned=!0;var u=new Error("Possible EventEmitter memory leak detected. "+l.length+" "+String(t)+" listeners added. Use emitter.setMaxListeners() to increase limit");u.name="MaxListenersExceededWarning",u.emitter=e,u.type=t,u.count=l.length,console&&console.warn}return e}function u(){if(!this.fired)return this.target.removeListener(this.type,this.wrapFn),this.fired=!0,0===arguments.length?this.listener.call(this.target):this.listener.apply(this.target,arguments)}function c(e,t,n){var r={fired:!1,wrapFn:void 0,target:e,type:t,listener:n},i=u.bind(r);return i.listener=n,r.wrapFn=i,i}function f(e,t,n){var r=e._events;if(void 0===r)return[];var i=r[t];return void 0===i?[]:"function"==typeof i?n?[i.listener||i]:[i]:n?function(e){for(var t=new Array(e.length),n=0;n<t.length;++n)t[n]=e[n].listener||e[n];return t}(i):h(i,i.length)}function d(e){var t=this._events;if(void 0!==t){var n=t[e];if("function"==typeof n)return 1;if(void 0!==n)return n.length}return 0}function h(e,t){for(var n=new Array(t),r=0;r<t;++r)n[r]=e[r];return n}function p(e,t,n,r){if("function"==typeof e.on)r.once?e.once(t,n):e.on(t,n);else{if("function"!=typeof e.addEventListener)throw new TypeError('The "emitter" argument must be of type EventEmitter. Received type '+typeof e);e.addEventListener(t,function i(a){r.once&&e.removeEventListener(t,i),n(a)})}}return Object.defineProperty(i,"defaultMaxListeners",{enumerable:!0,get:function(){return a},set:function(e){if("number"!=typeof e||e<0||r(e))throw new RangeError('The value of "defaultMaxListeners" is out of range. It must be a non-negative number. Received '+e+".");a=e}}),i.init=function(){void 0!==this._events&&this._events!==Object.getPrototypeOf(this)._events||(this._events=Object.create(null),this._eventsCount=0),this._maxListeners=this._maxListeners||void 0},i.prototype.setMaxListeners=function(e){if("number"!=typeof e||e<0||r(e))throw new RangeError('The value of "n" is out of range. It must be a non-negative number. Received '+e+".");return this._maxListeners=e,this},i.prototype.getMaxListeners=function(){return s(this)},i.prototype.emit=function(e){for(var t=[],r=1;r<arguments.length;r++)t.push(arguments[r]);var i="error"===e,a=this._events;if(void 0!==a)i=i&&void 0===a.error;else if(!i)return!1;if(i){var o;if(t.length>0&&(o=t[0]),o instanceof Error)throw o;var s=new Error("Unhandled error."+(o?" ("+o.message+")":""));throw s.context=o,s}var l=a[e];if(void 0===l)return!1;if("function"==typeof l)n(l,this,t);else{var u=l.length,c=h(l,u);for(r=0;r<u;++r)n(c[r],this,t)}return!0},i.prototype.addListener=function(e,t){return l(this,e,t,!1)},i.prototype.on=i.prototype.addListener,i.prototype.prependListener=function(e,t){return l(this,e,t,!0)},i.prototype.once=function(e,t){return o(t),this.on(e,c(this,e,t)),this},i.prototype.prependOnceListener=function(e,t){return o(t),this.prependListener(e,c(this,e,t)),this},i.prototype.removeListener=function(e,t){var n,r,i,a,s;if(o(t),void 0===(r=this._events))return this;if(void 0===(n=r[e]))return this;if(n===t||n.listener===t)0===--this._eventsCount?this._events=Object.create(null):(delete r[e],r.removeListener&&this.emit("removeListener",e,n.listener||t));else if("function"!=typeof n){for(i=-1,a=n.length-1;a>=0;a--)if(n[a]===t||n[a].listener===t){s=n[a].listener,i=a;break}if(i<0)return this;0===i?n.shift():function(e,t){for(;t+1<e.length;t++)e[t]=e[t+1];e.pop()}(n,i),1===n.length&&(r[e]=n[0]),void 0!==r.removeListener&&this.emit("removeListener",e,s||t)}return this},i.prototype.off=i.prototype.removeListener,i.prototype.removeAllListeners=function(e){var t,n,r;if(void 0===(n=this._events))return this;if(void 0===n.removeListener)return 0===arguments.length?(this._events=Object.create(null),this._eventsCount=0):void 0!==n[e]&&(0===--this._eventsCount?this._events=Object.create(null):delete n[e]),this;if(0===arguments.length){var i,a=Object.keys(n);for(r=0;r<a.length;++r)"removeListener"!==(i=a[r])&&this.removeAllListeners(i);return this.removeAllListeners("removeListener"),this._events=Object.create(null),this._eventsCount=0,this}if("function"==typeof(t=n[e]))this.removeListener(e,t);else if(void 0!==t)for(r=t.length-1;r>=0;r--)this.removeListener(e,t[r]);return this},i.prototype.listeners=function(e){return f(this,e,!0)},i.prototype.rawListeners=function(e){return f(this,e,!1)},i.listenerCount=function(e,t){return"function"==typeof e.listenerCount?e.listenerCount(t):d.call(e,t)},i.prototype.listenerCount=d,i.prototype.eventNames=function(){return this._eventsCount>0?e(this._events):[]},Kc.exports}();const Zc=e(Gc);const Xc=new class extends Zc{constructor(){super(),this._permit=!0,window.addEventListener("message",this._handleIframeMessage.bind(this),!1)}set lock(e){this._permit=e}j(e,t){try{const n=rr();n&&window.parent&&window.parent.postMessage({id:n,event:e,data:t},"*")}catch(n){}}_handleIframeMessage(e){try{if(!this._permit)return;const t=e.data;"object"==typeof t&&"id"in t&&t.id===rr()&&"event"in t&&"data"in t&&this.emit(t.event,t.data)}catch(t){}}};const Jc=((e={})=>{const t=new Map,n=new Map,{extra:r,onError:i=Gn}=e;En(i);const a=e=>(e=>(e.unsubscribe=()=>t.delete(e.id),t.set(e.id,e),t=>{e.unsubscribe(),t?.cancelActive&&Wn(e)}))(Hn(t,e)??Bn(e));Fn(a,{withTypes:()=>a});const o=e=>{const n=Hn(t,e);return n&&(n.unsubscribe(),e.cancelActive&&Wn(n)),!!n};Fn(o,{withTypes:()=>o});const s=async(e,o,s,l)=>{const u=new AbortController,c=qn(a,u.signal),f=[];try{e.pending.add(u),(e=>{const t=n.get(e)??0;n.set(e,t+1)})(e),await Promise.resolve(e.effect(o,Fn({},s,{getOriginalState:l,condition:(e,t)=>c(e,t).then(Boolean),take:c,delay:Ln(u.signal),pause:Pn(u.signal),extra:r,signal:u.signal,fork:Dn(u.signal,f),unsubscribe:e.unsubscribe,subscribe:()=>{t.set(e.id,e)},cancelActiveListeners:()=>{e.pending.forEach((e,t,n)=>{e!==u&&($n(e,Sn),n.delete(e))})},cancel:()=>{$n(u,Sn),e.pending.delete(u)},throwIfCancelled:()=>{jn(u.signal)}})))}catch(d){d instanceof Tn||Un(i,d,{raisedBy:"effect"})}finally{await Promise.all(f),$n(u,Cn),(e=>{const t=n.get(e)??1;1===t?n.delete(e):n.set(e,t-1)})(e),e.pending.delete(u)}},l=((e,t)=>()=>{for(const e of t.keys())Wn(e);e.clear()})(t,n);return{middleware:e=>n=>r=>{if(!he(r))return n(r);if(Qn.match(r))return a(r.payload);if(Vn.match(r))return void l();if(Kn.match(r))return o(r.payload);let u=e.getState();const c=()=>{if(u===In)throw new Error(Zn(23));return u};let f;try{if(f=n(r),t.size>0){const n=e.getState(),a=Array.from(t.values());for(const t of a){let a=!1;try{a=t.predicate(r,n,u)}catch(d){a=!1,Un(i,d,{raisedBy:"predicate"})}a&&s(t,r,e,c)}}}finally{u=In}return f},startListening:a,stopListening:o,clearListeners:l}})();const Yc=new class{constructor(){}O(e,t){const n=e.api.assets.find(e=>e.symbol===t.symbol);if(!n)return!1;const r=e.ui.duration||60*t.duration;if(!n.duration.length)return!1;const i=Math.min(...n.duration),a=Math.max(...n.duration);if(r<i||r>a)return!1;if(!n.active)return!1;if(n.payout<e.ui.minPayout)return!1;return!(e.order.orders.filter(e=>"number"!=typeof e.profit).length>=e.ui.maxTrades)}P(e,t){const n=e.order.orders.filter(e=>"profit"in e)[0],r=e.ui,i=this.F;let a=r.amount;if(n){const e=n.profit;e>0&&r.isIncreaseWin?(a="loss"===i?r.amount:Math.floor(n.amount*r.increaseWin),this.F="win"):e<0&&r.isIncreaseLoss?(a="win"===i?r.amount:Math.floor(n.amount*r.increaseLoss),this.F="loss"):this.F=void 0}return a}I(e,t){const n=e.ui,r=e.api;return r.isAccount.balance&&n.isTp&&n.tp<=r.isAccount.balance&&Td.dispatch(vr({type:"warning",text:is(n.localCode||"en","tp_err")})),!0}N(e,t){const n=Td.getState(),r=n.api;if(!n.ui.run||!r.isAccount.account_id)return;if(!this.O(n,e))return;const i=this.P(n,e);t({account_id:r.isAccount.account_id,amount:i,asset:e.symbol,dir:e.dir,duration:n.ui.duration||60*e.duration})}};Jc.startListening({actionCreator:dr,effect:e=>{if(e.payload){const e=Td.getState(),t=e.ui,n=e.api;if(!n.isAccount||!n.isAccount?.deals||void 0===n.isAccount?.balance||!n.isAccount?.symbol)return void Td.dispatch(dr(!1));const r=n.isAccount.balance,i=n.isAccount.deals.min,a=n.isAccount.deals.max,o=n.isAccount.symbol;if(t.amount<i)return Td.dispatch(vr({type:"warning",text:is(t.localCode||"en","check_minAmount")})),void Td.dispatch(dr(!1));if(t.amount>a)return Td.dispatch(vr({type:"warning",text:is(t.localCode||"en","check_maxAmount")})),void Td.dispatch(dr(!1));if(0===r||r<i)return Td.dispatch(vr({type:"warning",text:is(t.localCode||"en","no_balance",[o.concat(String(r))])})),void Td.dispatch(dr(!1));if(t.amount>r)return Td.dispatch(vr({type:"warning",text:is(t.localCode||"en","insufficient_balance",[o.concat(String(t.amount))])})),void Td.dispatch(dr(!1));if(t.isTp&&t.tp<=r)return Td.dispatch(vr({type:"warning",text:is(t.localCode||"en","tp_err")})),void Td.dispatch(dr(!1));if(t.isSl&&t.sl>=r)return Td.dispatch(vr({type:"warning",text:is(t.localCode||"en","sl_err")})),void Td.dispatch(dr(!1));Td.dispatch(vr());if(e.order.orders.filter(e=>"number"!=typeof e.profit).length>0)return;const s=e.ws.signals.find(e=>e.closeTimestamp-Math.floor(Date.now()/1e3)>0);s&&Yc.N(s,e=>{Xc.j("26",e)})}}}),Jc.startListening({actionCreator:hr,effect:e=>{Td.getState()}}),Jc.startListening({actionCreator:gr,effect:e=>{Xc.j("23",e.payload)}}),Jc.startListening({actionCreator:br,effect:e=>{Xc.j("22",e.payload)}}),Jc.startListening({actionCreator:yr,effect:(e,t)=>{e.payload&&t.dispatch(dr(!1))}}),Jc.startListening({actionCreator:mr,effect:(e,t)=>{e.payload&&Xc.j("24",e.payload)}});const ef=Object.create(null);ef.open="0",ef.close="1",ef.ping="2",ef.pong="3",ef.message="4",ef.upgrade="5",ef.noop="6";const tf=Object.create(null);Object.keys(ef).forEach(e=>{tf[ef[e]]=e});const nf={type:"error",data:"parser error"},rf="function"==typeof Blob||"undefined"!=typeof Blob&&"[object BlobConstructor]"===Object.prototype.toString.call(Blob),af="function"==typeof ArrayBuffer,of=e=>"function"==typeof ArrayBuffer.isView?ArrayBuffer.isView(e):e&&e.buffer instanceof ArrayBuffer,sf=({type:e,data:t},n,r)=>rf&&t instanceof Blob?n?r(t):lf(t,r):af&&(t instanceof ArrayBuffer||of(t))?n?r(t):lf(new Blob([t]),r):r(ef[e]+(t||"")),lf=(e,t)=>{const n=new FileReader;return n.onload=function(){const e=n.result.split(",")[1];t("b"+(e||""))},n.readAsDataURL(e)};function uf(e){return e instanceof Uint8Array?e:e instanceof ArrayBuffer?new Uint8Array(e):new Uint8Array(e.buffer,e.byteOffset,e.byteLength)}let cf;const ff="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",df="undefined"==typeof Uint8Array?[]:new Uint8Array(256);for(let Md=0;Md<64;Md++)df[ff.charCodeAt(Md)]=Md;const hf="function"==typeof ArrayBuffer,pf=(e,t)=>{if("string"!=typeof e)return{type:"message",data:mf(e,t)};const n=e.charAt(0);if("b"===n)return{type:"message",data:vf(e.substring(1),t)};return tf[n]?e.length>1?{type:tf[n],data:e.substring(1)}:{type:tf[n]}:nf},vf=(e,t)=>{if(hf){const n=(e=>{let t,n,r,i,a,o=.75*e.length,s=e.length,l=0;"="===e[e.length-1]&&(o--,"="===e[e.length-2]&&o--);const u=new ArrayBuffer(o),c=new Uint8Array(u);for(t=0;t<s;t+=4)n=df[e.charCodeAt(t)],r=df[e.charCodeAt(t+1)],i=df[e.charCodeAt(t+2)],a=df[e.charCodeAt(t+3)],c[l++]=n<<2|r>>4,c[l++]=(15&r)<<4|i>>2,c[l++]=(3&i)<<6|63&a;return u})(e);return mf(n,t)}return{base64:!0,data:e}},mf=(e,t)=>"blob"===t?e instanceof Blob?e:new Blob([e]):e instanceof ArrayBuffer?e:e.buffer,gf=String.fromCharCode(30);function bf(){return new TransformStream({transform(e,t){!function(e,t){rf&&e.data instanceof Blob?e.data.arrayBuffer().then(uf).then(t):af&&(e.data instanceof ArrayBuffer||of(e.data))?t(uf(e.data)):sf(e,!1,e=>{cf||(cf=new TextEncoder),t(cf.encode(e))})}(e,n=>{const r=n.length;let i;if(r<126)i=new Uint8Array(1),new DataView(i.buffer).setUint8(0,r);else if(r<65536){i=new Uint8Array(3);const e=new DataView(i.buffer);e.setUint8(0,126),e.setUint16(1,r)}else{i=new Uint8Array(9);const e=new DataView(i.buffer);e.setUint8(0,127),e.setBigUint64(1,BigInt(r))}e.data&&"string"!=typeof e.data&&(i[0]|=128),t.enqueue(i),t.enqueue(n)})}})}let yf;function wf(e){return e.reduce((e,t)=>e+t.length,0)}function kf(e,t){if(e[0].length===t)return e.shift();const n=new Uint8Array(t);let r=0;for(let i=0;i<t;i++)n[i]=e[0][r++],r===e[0].length&&(e.shift(),r=0);return e.length&&r<e[0].length&&(e[0]=e[0].slice(r)),n}function xf(e){if(e)return function(e){for(var t in xf.prototype)e[t]=xf.prototype[t];return e}(e)}xf.prototype.on=xf.prototype.addEventListener=function(e,t){return this._callbacks=this._callbacks||{},(this._callbacks["$"+e]=this._callbacks["$"+e]||[]).push(t),this},xf.prototype.once=function(e,t){function n(){this.off(e,n),t.apply(this,arguments)}return n.fn=t,this.on(e,n),this},xf.prototype.off=xf.prototype.removeListener=xf.prototype.removeAllListeners=xf.prototype.removeEventListener=function(e,t){if(this._callbacks=this._callbacks||{},0==arguments.length)return this._callbacks={},this;var n,r=this._callbacks["$"+e];if(!r)return this;if(1==arguments.length)return delete this._callbacks["$"+e],this;for(var i=0;i<r.length;i++)if((n=r[i])===t||n.fn===t){r.splice(i,1);break}return 0===r.length&&delete this._callbacks["$"+e],this},xf.prototype.emit=function(e){this._callbacks=this._callbacks||{};for(var t=new Array(arguments.length-1),n=this._callbacks["$"+e],r=1;r<arguments.length;r++)t[r-1]=arguments[r];if(n){r=0;for(var i=(n=n.slice(0)).length;r<i;++r)n[r].apply(this,t)}return this},xf.prototype.emitReserved=xf.prototype.emit,xf.prototype.listeners=function(e){return this._callbacks=this._callbacks||{},this._callbacks["$"+e]||[]},xf.prototype.hasListeners=function(e){return!!this.listeners(e).length};const _f="function"==typeof Promise&&"function"==typeof Promise.resolve?e=>Promise.resolve().then(e):(e,t)=>t(e,0),Sf="undefined"!=typeof self?self:"undefined"!=typeof window?window:Function("return this")();function Cf(e,...t){return t.reduce((t,n)=>(e.hasOwnProperty(n)&&(t[n]=e[n]),t),{})}const Tf=Sf.setTimeout,Ef=Sf.clearTimeout;function Af(e,t){t.useNativeTimers?(e.setTimeoutFn=Tf.bind(Sf),e.clearTimeoutFn=Ef.bind(Sf)):(e.setTimeoutFn=Sf.setTimeout.bind(Sf),e.clearTimeoutFn=Sf.clearTimeout.bind(Sf))}function Rf(e){return"string"==typeof e?function(e){let t=0,n=0;for(let r=0,i=e.length;r<i;r++)t=e.charCodeAt(r),t<128?n+=1:t<2048?n+=2:t<55296||t>=57344?n+=3:(r++,n+=4);return n}(e):Math.ceil(1.33*(e.byteLength||e.size))}function Mf(){return Date.now().toString(36).substring(3)+Math.random().toString(36).substring(2,5)}class $f extends Error{constructor(e,t,n){super(e),this.description=t,this.context=n,this.type="TransportError"}}class jf extends xf{constructor(e){super(),this.writable=!1,Af(this,e),this.opts=e,this.query=e.query,this.socket=e.socket,this.supportsBinary=!e.forceBase64}onError(e,t,n){return super.emitReserved("error",new $f(e,t,n)),this}open(){return this.readyState="opening",this.doOpen(),this}close(){return"opening"!==this.readyState&&"open"!==this.readyState||(this.doClose(),this.onClose()),this}send(e){"open"===this.readyState&&this.write(e)}onOpen(){this.readyState="open",this.writable=!0,super.emitReserved("open")}onData(e){const t=pf(e,this.socket.binaryType);this.onPacket(t)}onPacket(e){super.emitReserved("packet",e)}onClose(e){this.readyState="closed",super.emitReserved("close",e)}pause(e){}createUri(e,t={}){return e+"://"+this._hostname()+this._port()+this.opts.path+this._query(t)}_hostname(){const e=this.opts.hostname;return-1===e.indexOf(":")?e:"["+e+"]"}_port(){return this.opts.port&&(this.opts.secure&&Number(443!==this.opts.port)||!this.opts.secure&&80!==Number(this.opts.port))?":"+this.opts.port:""}_query(e){const t=function(e){let t="";for(let n in e)e.hasOwnProperty(n)&&(t.length&&(t+="&"),t+=encodeURIComponent(n)+"="+encodeURIComponent(e[n]));return t}(e);return t.length?"?"+t:""}}class Of extends jf{constructor(){super(...arguments),this._polling=!1}get name(){return"polling"}doOpen(){this._poll()}pause(e){this.readyState="pausing";const t=()=>{this.readyState="paused",e()};if(this._polling||!this.writable){let e=0;this._polling&&(e++,this.once("pollComplete",function(){--e||t()})),this.writable||(e++,this.once("drain",function(){--e||t()}))}else t()}_poll(){this._polling=!0,this.doPoll(),this.emitReserved("poll")}onData(e){((e,t)=>{const n=e.split(gf),r=[];for(let i=0;i<n.length;i++){const e=pf(n[i],t);if(r.push(e),"error"===e.type)break}return r})(e,this.socket.binaryType).forEach(e=>{if("opening"===this.readyState&&"open"===e.type&&this.onOpen(),"close"===e.type)return this.onClose({description:"transport closed by the server"}),!1;this.onPacket(e)}),"closed"!==this.readyState&&(this._polling=!1,this.emitReserved("pollComplete"),"open"===this.readyState&&this._poll())}doClose(){const e=()=>{this.write([{type:"close"}])};"open"===this.readyState?e():this.once("open",e)}write(e){this.writable=!1,((e,t)=>{const n=e.length,r=new Array(n);let i=0;e.forEach((e,a)=>{sf(e,!1,e=>{r[a]=e,++i===n&&t(r.join(gf))})})})(e,e=>{this.doWrite(e,()=>{this.writable=!0,this.emitReserved("drain")})})}uri(){const e=this.opts.secure?"https":"http",t=this.query||{};return!1!==this.opts.timestampRequests&&(t[this.opts.timestampParam]=Mf()),this.supportsBinary||t.sid||(t.b64=1),this.createUri(e,t)}}let Pf=!1;try{Pf="undefined"!=typeof XMLHttpRequest&&"withCredentials"in new XMLHttpRequest}catch(Rd){}const Lf=Pf;function Ff(){}class If extends Of{constructor(e){if(super(e),"undefined"!=typeof location){const t="https:"===location.protocol;let n=location.port;n||(n=t?"443":"80"),this.xd="undefined"!=typeof location&&e.hostname!==location.hostname||n!==e.port}}doWrite(e,t){const n=this.request({method:"POST",data:e});n.on("success",t),n.on("error",(e,t)=>{this.onError("xhr post error",e,t)})}doPoll(){const e=this.request();e.on("data",this.onData.bind(this)),e.on("error",(e,t)=>{this.onError("xhr poll error",e,t)}),this.pollXhr=e}}let Nf=class e extends xf{constructor(e,t,n){super(),this.createRequest=e,Af(this,n),this._opts=n,this._method=n.method||"GET",this._uri=t,this._data=void 0!==n.data?n.data:null,this._create()}_create(){var t;const n=Cf(this._opts,"agent","pfx","key","passphrase","cert","ca","ciphers","rejectUnauthorized","autoUnref");n.xdomain=!!this._opts.xd;const r=this._xhr=this.createRequest(n);try{r.open(this._method,this._uri,!0);try{if(this._opts.extraHeaders){r.setDisableHeaderCheck&&r.setDisableHeaderCheck(!0);for(let e in this._opts.extraHeaders)this._opts.extraHeaders.hasOwnProperty(e)&&r.setRequestHeader(e,this._opts.extraHeaders[e])}}catch(i){}if("POST"===this._method)try{r.setRequestHeader("Content-type","text/plain;charset=UTF-8")}catch(i){}try{r.setRequestHeader("Accept","*/*")}catch(i){}null===(t=this._opts.cookieJar)||void 0===t||t.addCookies(r),"withCredentials"in r&&(r.withCredentials=this._opts.withCredentials),this._opts.requestTimeout&&(r.timeout=this._opts.requestTimeout),r.onreadystatechange=()=>{var e;3===r.readyState&&(null===(e=this._opts.cookieJar)||void 0===e||e.parseCookies(r.getResponseHeader("set-cookie"))),4===r.readyState&&(200===r.status||1223===r.status?this._onLoad():this.setTimeoutFn(()=>{this._onError("number"==typeof r.status?r.status:0)},0))},r.send(this._data)}catch(i){return void this.setTimeoutFn(()=>{this._onError(i)},0)}"undefined"!=typeof document&&(this._index=e.requestsCount++,e.requests[this._index]=this)}_onError(e){this.emitReserved("error",e,this._xhr),this._cleanup(!0)}_cleanup(t){if(void 0!==this._xhr&&null!==this._xhr){if(this._xhr.onreadystatechange=Ff,t)try{this._xhr.abort()}catch(n){}"undefined"!=typeof document&&delete e.requests[this._index],this._xhr=null}}_onLoad(){const e=this._xhr.responseText;null!==e&&(this.emitReserved("data",e),this.emitReserved("success"),this._cleanup())}abort(){this._cleanup()}};if(Nf.requestsCount=0,Nf.requests={},"undefined"!=typeof document)if("function"==typeof attachEvent)attachEvent("onunload",Df);else if("function"==typeof addEventListener){addEventListener("onpagehide"in Sf?"pagehide":"unload",Df,!1)}function Df(){for(let e in Nf.requests)Nf.requests.hasOwnProperty(e)&&Nf.requests[e].abort()}const qf=function(){const e=zf({xdomain:!1});return e&&null!==e.responseType}();function zf(e){const t=e.xdomain;try{if("undefined"!=typeof XMLHttpRequest&&(!t||Lf))return new XMLHttpRequest}catch(n){}if(!t)try{return new(Sf[["Active"].concat("Object").join("X")])("Microsoft.XMLHTTP")}catch(n){}}const Bf="undefined"!=typeof navigator&&"string"==typeof navigator.product&&"reactnative"===navigator.product.toLowerCase();class Hf extends jf{get name(){return"websocket"}doOpen(){const e=this.uri(),t=this.opts.protocols,n=Bf?{}:Cf(this.opts,"agent","perMessageDeflate","pfx","key","passphrase","cert","ca","ciphers","rejectUnauthorized","localAddress","protocolVersion","origin","maxPayload","family","checkServerIdentity");this.opts.extraHeaders&&(n.headers=this.opts.extraHeaders);try{this.ws=this.createSocket(e,t,n)}catch(Rd){return this.emitReserved("error",Rd)}this.ws.binaryType=this.socket.binaryType,this.addEventListeners()}addEventListeners(){this.ws.onopen=()=>{this.opts.autoUnref&&this.ws._socket.unref(),this.onOpen()},this.ws.onclose=e=>this.onClose({description:"websocket connection closed",context:e}),this.ws.onmessage=e=>this.onData(e.data),this.ws.onerror=e=>this.onError("websocket error",e)}write(e){this.writable=!1;for(let t=0;t<e.length;t++){const n=e[t],r=t===e.length-1;sf(n,this.supportsBinary,e=>{try{this.doWrite(n,e)}catch(t){}r&&_f(()=>{this.writable=!0,this.emitReserved("drain")},this.setTimeoutFn)})}}doClose(){void 0!==this.ws&&(this.ws.onerror=()=>{},this.ws.close(),this.ws=null)}uri(){const e=this.opts.secure?"wss":"ws",t=this.query||{};return this.opts.timestampRequests&&(t[this.opts.timestampParam]=Mf()),this.supportsBinary||(t.b64=1),this.createUri(e,t)}}const Wf=Sf.WebSocket||Sf.MozWebSocket;const Uf={websocket:class extends Hf{createSocket(e,t,n){return Bf?new Wf(e,t,n):t?new Wf(e,t):new Wf(e)}doWrite(e,t){this.ws.send(t)}},webtransport:class extends jf{get name(){return"webtransport"}doOpen(){try{this._transport=new WebTransport(this.createUri("https"),this.opts.transportOptions[this.name])}catch(Rd){return this.emitReserved("error",Rd)}this._transport.closed.then(()=>{this.onClose()}).catch(e=>{this.onError("webtransport error",e)}),this._transport.ready.then(()=>{this._transport.createBidirectionalStream().then(e=>{const t=function(e,t){yf||(yf=new TextDecoder);const n=[];let r=0,i=-1,a=!1;return new TransformStream({transform(o,s){for(n.push(o);;){if(0===r){if(wf(n)<1)break;const e=kf(n,1);a=!(128&~e[0]),i=127&e[0],r=i<126?3:126===i?1:2}else if(1===r){if(wf(n)<2)break;const e=kf(n,2);i=new DataView(e.buffer,e.byteOffset,e.length).getUint16(0),r=3}else if(2===r){if(wf(n)<8)break;const e=kf(n,8),t=new DataView(e.buffer,e.byteOffset,e.length),a=t.getUint32(0);if(a>Math.pow(2,21)-1){s.enqueue(nf);break}i=a*Math.pow(2,32)+t.getUint32(4),r=3}else{if(wf(n)<i)break;const e=kf(n,i);s.enqueue(pf(a?e:yf.decode(e),t)),r=0}if(0===i||i>e){s.enqueue(nf);break}}}})}(Number.MAX_SAFE_INTEGER,this.socket.binaryType),n=e.readable.pipeThrough(t).getReader(),r=bf();r.readable.pipeTo(e.writable),this._writer=r.writable.getWriter();const i=()=>{n.read().then(({done:e,value:t})=>{e||(this.onPacket(t),i())}).catch(e=>{})};i();const a={type:"open"};this.query.sid&&(a.data=`{"sid":"${this.query.sid}"}`),this._writer.write(a).then(()=>this.onOpen())})})}write(e){this.writable=!1;for(let t=0;t<e.length;t++){const n=e[t],r=t===e.length-1;this._writer.write(n).then(()=>{r&&_f(()=>{this.writable=!0,this.emitReserved("drain")},this.setTimeoutFn)})}}doClose(){var e;null===(e=this._transport)||void 0===e||e.close()}},polling:class extends If{constructor(e){super(e);const t=e&&e.forceBase64;this.supportsBinary=qf&&!t}request(e={}){return Object.assign(e,{xd:this.xd},this.opts),new Nf(zf,this.uri(),e)}}},Qf=/^(?:(?![^:@\/?#]+:[^:@\/]*@)(http|https|ws|wss):\/\/)?((?:(([^:@\/?#]*)(?::([^:@\/?#]*))?)?@)?((?:[a-f0-9]{0,4}:){2,7}[a-f0-9]{0,4}|[^:\/?#]*)(?::(\d*))?)(((\/(?:[^?#](?![^?#\/]*\.[^?#\/.]+(?:[?#]|$)))*\/?)?([^?#\/]*))(?:\?([^#]*))?(?:#(.*))?)/,Vf=["source","protocol","authority","userInfo","user","password","host","port","relative","path","directory","file","query","anchor"];function Kf(e){if(e.length>8e3)throw"URI too long";const t=e,n=e.indexOf("["),r=e.indexOf("]");-1!=n&&-1!=r&&(e=e.substring(0,n)+e.substring(n,r).replace(/:/g,";")+e.substring(r,e.length));let i=Qf.exec(e||""),a={},o=14;for(;o--;)a[Vf[o]]=i[o]||"";return-1!=n&&-1!=r&&(a.source=t,a.host=a.host.substring(1,a.host.length-1).replace(/;/g,":"),a.authority=a.authority.replace("[","").replace("]","").replace(/;/g,":"),a.ipv6uri=!0),a.pathNames=function(e,t){const n=/\/{2,9}/g,r=t.replace(n,"/").split("/");"/"!=t.slice(0,1)&&0!==t.length||r.splice(0,1);"/"==t.slice(-1)&&r.splice(r.length-1,1);return r}(0,a.path),a.queryKey=function(e,t){const n={};return t.replace(/(?:^|&)([^&=]*)=?([^&]*)/g,function(e,t,r){t&&(n[t]=r)}),n}(0,a.query),a}const Gf="function"==typeof addEventListener&&"function"==typeof removeEventListener,Zf=[];Gf&&addEventListener("offline",()=>{Zf.forEach(e=>e())},!1);class Xf extends xf{constructor(e,t){if(super(),this.binaryType="arraybuffer",this.writeBuffer=[],this._prevBufferLen=0,this._pingInterval=-1,this._pingTimeout=-1,this._maxPayload=-1,this._pingTimeoutTime=1/0,e&&"object"==typeof e&&(t=e,e=null),e){const n=Kf(e);t.hostname=n.host,t.secure="https"===n.protocol||"wss"===n.protocol,t.port=n.port,n.query&&(t.query=n.query)}else t.host&&(t.hostname=Kf(t.host).host);Af(this,t),this.secure=null!=t.secure?t.secure:"undefined"!=typeof location&&"https:"===location.protocol,t.hostname&&!t.port&&(t.port=this.secure?"443":"80"),this.hostname=t.hostname||("undefined"!=typeof location?location.hostname:"localhost"),this.port=t.port||("undefined"!=typeof location&&location.port?location.port:this.secure?"443":"80"),this.transports=[],this._transportsByName={},t.transports.forEach(e=>{const t=e.prototype.name;this.transports.push(t),this._transportsByName[t]=e}),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},t),this.opts.path=this.opts.path.replace(/\/$/,"")+(this.opts.addTrailingSlash?"/":""),"string"==typeof this.opts.query&&(this.opts.query=function(e){let t={},n=e.split("&");for(let r=0,i=n.length;r<i;r++){let e=n[r].split("=");t[decodeURIComponent(e[0])]=decodeURIComponent(e[1])}return t}(this.opts.query)),Gf&&(this.opts.closeOnBeforeunload&&(this._beforeunloadEventListener=()=>{this.transport&&(this.transport.removeAllListeners(),this.transport.close())},addEventListener("beforeunload",this._beforeunloadEventListener,!1)),"localhost"!==this.hostname&&(this._offlineEventListener=()=>{this._onClose("transport close",{description:"network connection lost"})},Zf.push(this._offlineEventListener))),this.opts.withCredentials&&(this._cookieJar=void 0),this._open()}createTransport(e){const t=Object.assign({},this.opts.query);t.EIO=4,t.transport=e,this.id&&(t.sid=this.id);const n=Object.assign({},this.opts,{query:t,socket:this,hostname:this.hostname,secure:this.secure,port:this.port},this.opts.transportOptions[e]);return new this._transportsByName[e](n)}_open(){if(0===this.transports.length)return void this.setTimeoutFn(()=>{this.emitReserved("error","No transports available")},0);const e=this.opts.rememberUpgrade&&Xf.priorWebsocketSuccess&&-1!==this.transports.indexOf("websocket")?"websocket":this.transports[0];this.readyState="opening";const t=this.createTransport(e);t.open(),this.setTransport(t)}setTransport(e){this.transport&&this.transport.removeAllListeners(),this.transport=e,e.on("drain",this._onDrain.bind(this)).on("packet",this._onPacket.bind(this)).on("error",this._onError.bind(this)).on("close",e=>this._onClose("transport close",e))}onOpen(){this.readyState="open",Xf.priorWebsocketSuccess="websocket"===this.transport.name,this.emitReserved("open"),this.flush()}_onPacket(e){if("opening"===this.readyState||"open"===this.readyState||"closing"===this.readyState)switch(this.emitReserved("packet",e),this.emitReserved("heartbeat"),e.type){case"open":this.onHandshake(JSON.parse(e.data));break;case"ping":this._sendPacket("pong"),this.emitReserved("ping"),this.emitReserved("pong"),this._resetPingTimeout();break;case"error":const t=new Error("server error");t.code=e.data,this._onError(t);break;case"message":this.emitReserved("data",e.data),this.emitReserved("message",e.data)}}onHandshake(e){this.emitReserved("handshake",e),this.id=e.sid,this.transport.query.sid=e.sid,this._pingInterval=e.pingInterval,this._pingTimeout=e.pingTimeout,this._maxPayload=e.maxPayload,this.onOpen(),"closed"!==this.readyState&&this._resetPingTimeout()}_resetPingTimeout(){this.clearTimeoutFn(this._pingTimeoutTimer);const e=this._pingInterval+this._pingTimeout;this._pingTimeoutTime=Date.now()+e,this._pingTimeoutTimer=this.setTimeoutFn(()=>{this._onClose("ping timeout")},e),this.opts.autoUnref&&this._pingTimeoutTimer.unref()}_onDrain(){this.writeBuffer.splice(0,this._prevBufferLen),this._prevBufferLen=0,0===this.writeBuffer.length?this.emitReserved("drain"):this.flush()}flush(){if("closed"!==this.readyState&&this.transport.writable&&!this.upgrading&&this.writeBuffer.length){const e=this._getWritablePackets();this.transport.send(e),this._prevBufferLen=e.length,this.emitReserved("flush")}}_getWritablePackets(){if(!(this._maxPayload&&"polling"===this.transport.name&&this.writeBuffer.length>1))return this.writeBuffer;let e=1;for(let t=0;t<this.writeBuffer.length;t++){const n=this.writeBuffer[t].data;if(n&&(e+=Rf(n)),t>0&&e>this._maxPayload)return this.writeBuffer.slice(0,t);e+=2}return this.writeBuffer}_hasPingExpired(){if(!this._pingTimeoutTime)return!0;const e=Date.now()>this._pingTimeoutTime;return e&&(this._pingTimeoutTime=0,_f(()=>{this._onClose("ping timeout")},this.setTimeoutFn)),e}write(e,t,n){return this._sendPacket("message",e,t,n),this}send(e,t,n){return this._sendPacket("message",e,t,n),this}_sendPacket(e,t,n,r){if("function"==typeof t&&(r=t,t=void 0),"function"==typeof n&&(r=n,n=null),"closing"===this.readyState||"closed"===this.readyState)return;(n=n||{}).compress=!1!==n.compress;const i={type:e,data:t,options:n};this.emitReserved("packetCreate",i),this.writeBuffer.push(i),r&&this.once("flush",r),this.flush()}close(){const e=()=>{this._onClose("forced close"),this.transport.close()},t=()=>{this.off("upgrade",t),this.off("upgradeError",t),e()},n=()=>{this.once("upgrade",t),this.once("upgradeError",t)};return"opening"!==this.readyState&&"open"!==this.readyState||(this.readyState="closing",this.writeBuffer.length?this.once("drain",()=>{this.upgrading?n():e()}):this.upgrading?n():e()),this}_onError(e){if(Xf.priorWebsocketSuccess=!1,this.opts.tryAllTransports&&this.transports.length>1&&"opening"===this.readyState)return this.transports.shift(),this._open();this.emitReserved("error",e),this._onClose("transport error",e)}_onClose(e,t){if("opening"===this.readyState||"open"===this.readyState||"closing"===this.readyState){if(this.clearTimeoutFn(this._pingTimeoutTimer),this.transport.removeAllListeners("close"),this.transport.close(),this.transport.removeAllListeners(),Gf&&(this._beforeunloadEventListener&&removeEventListener("beforeunload",this._beforeunloadEventListener,!1),this._offlineEventListener)){const e=Zf.indexOf(this._offlineEventListener);-1!==e&&Zf.splice(e,1)}this.readyState="closed",this.id=null,this.emitReserved("close",e,t),this.writeBuffer=[],this._prevBufferLen=0}}}Xf.protocol=4;class Jf extends Xf{constructor(){super(...arguments),this._upgrades=[]}onOpen(){if(super.onOpen(),"open"===this.readyState&&this.opts.upgrade)for(let e=0;e<this._upgrades.length;e++)this._probe(this._upgrades[e])}_probe(e){let t=this.createTransport(e),n=!1;Xf.priorWebsocketSuccess=!1;const r=()=>{n||(t.send([{type:"ping",data:"probe"}]),t.once("packet",e=>{if(!n)if("pong"===e.type&&"probe"===e.data){if(this.upgrading=!0,this.emitReserved("upgrading",t),!t)return;Xf.priorWebsocketSuccess="websocket"===t.name,this.transport.pause(()=>{n||"closed"!==this.readyState&&(u(),this.setTransport(t),t.send([{type:"upgrade"}]),this.emitReserved("upgrade",t),t=null,this.upgrading=!1,this.flush())})}else{const e=new Error("probe error");e.transport=t.name,this.emitReserved("upgradeError",e)}}))};function i(){n||(n=!0,u(),t.close(),t=null)}const a=e=>{const n=new Error("probe error: "+e);n.transport=t.name,i(),this.emitReserved("upgradeError",n)};function o(){a("transport closed")}function s(){a("socket closed")}function l(e){t&&e.name!==t.name&&i()}const u=()=>{t.removeListener("open",r),t.removeListener("error",a),t.removeListener("close",o),this.off("close",s),this.off("upgrading",l)};t.once("open",r),t.once("error",a),t.once("close",o),this.once("close",s),this.once("upgrading",l),-1!==this._upgrades.indexOf("webtransport")&&"webtransport"!==e?this.setTimeoutFn(()=>{n||t.open()},200):t.open()}onHandshake(e){this._upgrades=this._filterUpgrades(e.upgrades),super.onHandshake(e)}_filterUpgrades(e){const t=[];for(let n=0;n<e.length;n++)~this.transports.indexOf(e[n])&&t.push(e[n]);return t}}let Yf=class extends Jf{constructor(e,t={}){const n="object"==typeof e?e:t;(!n.transports||n.transports&&"string"==typeof n.transports[0])&&(n.transports=(n.transports||["polling","websocket","webtransport"]).map(e=>Uf[e]).filter(e=>!!e)),super(e,n)}};const ed="function"==typeof ArrayBuffer,td=Object.prototype.toString,nd="function"==typeof Blob||"undefined"!=typeof Blob&&"[object BlobConstructor]"===td.call(Blob),rd="function"==typeof File||"undefined"!=typeof File&&"[object FileConstructor]"===td.call(File);function id(e){return ed&&(e instanceof ArrayBuffer||(e=>"function"==typeof ArrayBuffer.isView?ArrayBuffer.isView(e):e.buffer instanceof ArrayBuffer)(e))||nd&&e instanceof Blob||rd&&e instanceof File}function ad(e,t){if(!e||"object"!=typeof e)return!1;if(Array.isArray(e)){for(let t=0,n=e.length;t<n;t++)if(ad(e[t]))return!0;return!1}if(id(e))return!0;if(e.toJSON&&"function"==typeof e.toJSON&&1===arguments.length)return ad(e.toJSON(),!0);for(const n in e)if(Object.prototype.hasOwnProperty.call(e,n)&&ad(e[n]))return!0;return!1}function od(e){const t=[],n=e.data,r=e;return r.data=sd(n,t),r.attachments=t.length,{packet:r,buffers:t}}function sd(e,t){if(!e)return e;if(id(e)){const n={_placeholder:!0,num:t.length};return t.push(e),n}if(Array.isArray(e)){const n=new Array(e.length);for(let r=0;r<e.length;r++)n[r]=sd(e[r],t);return n}if("object"==typeof e&&!(e instanceof Date)){const n={};for(const r in e)Object.prototype.hasOwnProperty.call(e,r)&&(n[r]=sd(e[r],t));return n}return e}function ld(e,t){return e.data=ud(e.data,t),delete e.attachments,e}function ud(e,t){if(!e)return e;if(e&&!0===e._placeholder){if("number"==typeof e.num&&e.num>=0&&e.num<t.length)return t[e.num];throw new Error("illegal attachments")}if(Array.isArray(e))for(let n=0;n<e.length;n++)e[n]=ud(e[n],t);else if("object"==typeof e)for(const n in e)Object.prototype.hasOwnProperty.call(e,n)&&(e[n]=ud(e[n],t));return e}const cd=["connect","connect_error","disconnect","disconnecting","newListener","removeListener"];var fd,dd;(dd=fd||(fd={}))[dd.CONNECT=0]="CONNECT",dd[dd.DISCONNECT=1]="DISCONNECT",dd[dd.EVENT=2]="EVENT",dd[dd.ACK=3]="ACK",dd[dd.CONNECT_ERROR=4]="CONNECT_ERROR",dd[dd.BINARY_EVENT=5]="BINARY_EVENT",dd[dd.BINARY_ACK=6]="BINARY_ACK";function hd(e){return"[object Object]"===Object.prototype.toString.call(e)}class pd extends xf{constructor(e){super(),this.reviver=e}add(e){let t;if("string"==typeof e){if(this.reconstructor)throw new Error("got plaintext data when reconstructing a packet");t=this.decodeString(e);const n=t.type===fd.BINARY_EVENT;n||t.type===fd.BINARY_ACK?(t.type=n?fd.EVENT:fd.ACK,this.reconstructor=new vd(t),0===t.attachments&&super.emitReserved("decoded",t)):super.emitReserved("decoded",t)}else{if(!id(e)&&!e.base64)throw new Error("Unknown type: "+e);if(!this.reconstructor)throw new Error("got binary data when not reconstructing a packet");t=this.reconstructor.takeBinaryData(e),t&&(this.reconstructor=null,super.emitReserved("decoded",t))}}decodeString(e){let t=0;const n={type:Number(e.charAt(0))};if(void 0===fd[n.type])throw new Error("unknown packet type "+n.type);if(n.type===fd.BINARY_EVENT||n.type===fd.BINARY_ACK){const r=t+1;for(;"-"!==e.charAt(++t)&&t!=e.length;);const i=e.substring(r,t);if(i!=Number(i)||"-"!==e.charAt(t))throw new Error("Illegal attachments");n.attachments=Number(i)}if("/"===e.charAt(t+1)){const r=t+1;for(;++t;){if(","===e.charAt(t))break;if(t===e.length)break}n.nsp=e.substring(r,t)}else n.nsp="/";const r=e.charAt(t+1);if(""!==r&&Number(r)==r){const r=t+1;for(;++t;){const n=e.charAt(t);if(null==n||Number(n)!=n){--t;break}if(t===e.length)break}n.id=Number(e.substring(r,t+1))}if(e.charAt(++t)){const r=this.tryParse(e.substr(t));if(!pd.isPayloadValid(n.type,r))throw new Error("invalid payload");n.data=r}return n}tryParse(e){try{return JSON.parse(e,this.reviver)}catch(t){return!1}}static isPayloadValid(e,t){switch(e){case fd.CONNECT:return hd(t);case fd.DISCONNECT:return void 0===t;case fd.CONNECT_ERROR:return"string"==typeof t||hd(t);case fd.EVENT:case fd.BINARY_EVENT:return Array.isArray(t)&&("number"==typeof t[0]||"string"==typeof t[0]&&-1===cd.indexOf(t[0]));case fd.ACK:case fd.BINARY_ACK:return Array.isArray(t)}}destroy(){this.reconstructor&&(this.reconstructor.finishedReconstruction(),this.reconstructor=null)}}class vd{constructor(e){this.packet=e,this.buffers=[],this.reconPack=e}takeBinaryData(e){if(this.buffers.push(e),this.buffers.length===this.reconPack.attachments){const e=ld(this.reconPack,this.buffers);return this.finishedReconstruction(),e}return null}finishedReconstruction(){this.reconPack=null,this.buffers=[]}}const md=Object.freeze(Object.defineProperty({__proto__:null,Decoder:pd,Encoder:class{constructor(e){this.replacer=e}encode(e){return e.type!==fd.EVENT&&e.type!==fd.ACK||!ad(e)?[this.encodeAsString(e)]:this.encodeAsBinary({type:e.type===fd.EVENT?fd.BINARY_EVENT:fd.BINARY_ACK,nsp:e.nsp,data:e.data,id:e.id})}encodeAsString(e){let t=""+e.type;return e.type!==fd.BINARY_EVENT&&e.type!==fd.BINARY_ACK||(t+=e.attachments+"-"),e.nsp&&"/"!==e.nsp&&(t+=e.nsp+","),null!=e.id&&(t+=e.id),null!=e.data&&(t+=JSON.stringify(e.data,this.replacer)),t}encodeAsBinary(e){const t=od(e),n=this.encodeAsString(t.packet),r=t.buffers;return r.unshift(n),r}},get PacketType(){return fd},protocol:5},Symbol.toStringTag,{value:"Module"}));function gd(e,t,n){return e.on(t,n),function(){e.off(t,n)}}const bd=Object.freeze({connect:1,connect_error:1,disconnect:1,disconnecting:1,newListener:1,removeListener:1});class yd extends xf{constructor(e,t,n){super(),this.connected=!1,this.recovered=!1,this.receiveBuffer=[],this.sendBuffer=[],this._queue=[],this._queueSeq=0,this.ids=0,this.acks={},this.flags={},this.io=e,this.nsp=t,n&&n.auth&&(this.auth=n.auth),this._opts=Object.assign({},n),this.io._autoConnect&&this.open()}get disconnected(){return!this.connected}subEvents(){if(this.subs)return;const e=this.io;this.subs=[gd(e,"open",this.onopen.bind(this)),gd(e,"packet",this.onpacket.bind(this)),gd(e,"error",this.onerror.bind(this)),gd(e,"close",this.onclose.bind(this))]}get active(){return!!this.subs}connect(){return this.connected||(this.subEvents(),this.io._reconnecting||this.io.open(),"open"===this.io._readyState&&this.onopen()),this}open(){return this.connect()}send(...e){return e.unshift("message"),this.emit.apply(this,e),this}emit(e,...t){var n,r,i;if(bd.hasOwnProperty(e))throw new Error('"'+e.toString()+'" is a reserved event name');if(t.unshift(e),this._opts.retries&&!this.flags.fromQueue&&!this.flags.volatile)return this._addToQueue(t),this;const a={type:fd.EVENT,data:t,options:{}};if(a.options.compress=!1!==this.flags.compress,"function"==typeof t[t.length-1]){const e=this.ids++,n=t.pop();this._registerAckCallback(e,n),a.id=e}const o=null===(r=null===(n=this.io.engine)||void 0===n?void 0:n.transport)||void 0===r?void 0:r.writable,s=this.connected&&!(null===(i=this.io.engine)||void 0===i?void 0:i._hasPingExpired());return this.flags.volatile&&!o||(s?(this.notifyOutgoingListeners(a),this.packet(a)):this.sendBuffer.push(a)),this.flags={},this}_registerAckCallback(e,t){var n;const r=null!==(n=this.flags.timeout)&&void 0!==n?n:this._opts.ackTimeout;if(void 0===r)return void(this.acks[e]=t);const i=this.io.setTimeoutFn(()=>{delete this.acks[e];for(let t=0;t<this.sendBuffer.length;t++)this.sendBuffer[t].id===e&&this.sendBuffer.splice(t,1);t.call(this,new Error("operation has timed out"))},r),a=(...e)=>{this.io.clearTimeoutFn(i),t.apply(this,e)};a.withError=!0,this.acks[e]=a}emitWithAck(e,...t){return new Promise((n,r)=>{const i=(e,t)=>e?r(e):n(t);i.withError=!0,t.push(i),this.emit(e,...t)})}_addToQueue(e){let t;"function"==typeof e[e.length-1]&&(t=e.pop());const n={id:this._queueSeq++,tryCount:0,pending:!1,args:e,flags:Object.assign({fromQueue:!0},this.flags)};e.push((e,...r)=>{if(n!==this._queue[0])return;return null!==e?n.tryCount>this._opts.retries&&(this._queue.shift(),t&&t(e)):(this._queue.shift(),t&&t(null,...r)),n.pending=!1,this._drainQueue()}),this._queue.push(n),this._drainQueue()}_drainQueue(e=!1){if(!this.connected||0===this._queue.length)return;const t=this._queue[0];t.pending&&!e||(t.pending=!0,t.tryCount++,this.flags=t.flags,this.emit.apply(this,t.args))}packet(e){e.nsp=this.nsp,this.io._packet(e)}onopen(){"function"==typeof this.auth?this.auth(e=>{this._sendConnectPacket(e)}):this._sendConnectPacket(this.auth)}_sendConnectPacket(e){this.packet({type:fd.CONNECT,data:this._pid?Object.assign({pid:this._pid,offset:this._lastOffset},e):e})}onerror(e){this.connected||this.emitReserved("connect_error",e)}onclose(e,t){this.connected=!1,delete this.id,this.emitReserved("disconnect",e,t),this._clearAcks()}_clearAcks(){Object.keys(this.acks).forEach(e=>{if(!this.sendBuffer.some(t=>String(t.id)===e)){const t=this.acks[e];delete this.acks[e],t.withError&&t.call(this,new Error("socket has been disconnected"))}})}onpacket(e){if(e.nsp===this.nsp)switch(e.type){case fd.CONNECT:e.data&&e.data.sid?this.onconnect(e.data.sid,e.data.pid):this.emitReserved("connect_error",new 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 fd.EVENT:case fd.BINARY_EVENT:this.onevent(e);break;case fd.ACK:case fd.BINARY_ACK:this.onack(e);break;case fd.DISCONNECT:this.ondisconnect();break;case fd.CONNECT_ERROR:this.destroy();const t=new Error(e.data.message);t.data=e.data.data,this.emitReserved("connect_error",t)}}onevent(e){const t=e.data||[];null!=e.id&&t.push(this.ack(e.id)),this.connected?this.emitEvent(t):this.receiveBuffer.push(Object.freeze(t))}emitEvent(e){if(this._anyListeners&&this._anyListeners.length){const t=this._anyListeners.slice();for(const n of t)n.apply(this,e)}super.emit.apply(this,e),this._pid&&e.length&&"string"==typeof e[e.length-1]&&(this._lastOffset=e[e.length-1])}ack(e){const t=this;let n=!1;return function(...r){n||(n=!0,t.packet({type:fd.ACK,id:e,data:r}))}}onack(e){const t=this.acks[e.id];"function"==typeof t&&(delete this.acks[e.id],t.withError&&e.data.unshift(null),t.apply(this,e.data))}onconnect(e,t){this.id=e,this.recovered=t&&this._pid===t,this._pid=t,this.connected=!0,this.emitBuffered(),this.emitReserved("connect"),this._drainQueue(!0)}emitBuffered(){this.receiveBuffer.forEach(e=>this.emitEvent(e)),this.receiveBuffer=[],this.sendBuffer.forEach(e=>{this.notifyOutgoingListeners(e),this.packet(e)}),this.sendBuffer=[]}ondisconnect(){this.destroy(),this.onclose("io server disconnect")}destroy(){this.subs&&(this.subs.forEach(e=>e()),this.subs=void 0),this.io._destroy(this)}disconnect(){return this.connected&&this.packet({type:fd.DISCONNECT}),this.destroy(),this.connected&&this.onclose("io client disconnect"),this}close(){return this.disconnect()}compress(e){return this.flags.compress=e,this}get volatile(){return this.flags.volatile=!0,this}timeout(e){return this.flags.timeout=e,this}onAny(e){return this._anyListeners=this._anyListeners||[],this._anyListeners.push(e),this}prependAny(e){return this._anyListeners=this._anyListeners||[],this._anyListeners.unshift(e),this}offAny(e){if(!this._anyListeners)return this;if(e){const t=this._anyListeners;for(let n=0;n<t.length;n++)if(e===t[n])return t.splice(n,1),this}else this._anyListeners=[];return this}listenersAny(){return this._anyListeners||[]}onAnyOutgoing(e){return this._anyOutgoingListeners=this._anyOutgoingListeners||[],this._anyOutgoingListeners.push(e),this}prependAnyOutgoing(e){return this._anyOutgoingListeners=this._anyOutgoingListeners||[],this._anyOutgoingListeners.unshift(e),this}offAnyOutgoing(e){if(!this._anyOutgoingListeners)return this;if(e){const t=this._anyOutgoingListeners;for(let n=0;n<t.length;n++)if(e===t[n])return t.splice(n,1),this}else this._anyOutgoingListeners=[];return this}listenersAnyOutgoing(){return this._anyOutgoingListeners||[]}notifyOutgoingListeners(e){if(this._anyOutgoingListeners&&this._anyOutgoingListeners.length){const t=this._anyOutgoingListeners.slice();for(const n of t)n.apply(this,e.data)}}}function wd(e){e=e||{},this.ms=e.min||100,this.max=e.max||1e4,this.factor=e.factor||2,this.jitter=e.jitter>0&&e.jitter<=1?e.jitter:0,this.attempts=0}wd.prototype.duration=function(){var e=this.ms*Math.pow(this.factor,this.attempts++);if(this.jitter){var t=Math.random(),n=Math.floor(t*this.jitter*e);e=1&Math.floor(10*t)?e+n:e-n}return 0|Math.min(e,this.max)},wd.prototype.reset=function(){this.attempts=0},wd.prototype.setMin=function(e){this.ms=e},wd.prototype.setMax=function(e){this.max=e},wd.prototype.setJitter=function(e){this.jitter=e};class kd extends xf{constructor(e,t){var n;super(),this.nsps={},this.subs=[],e&&"object"==typeof e&&(t=e,e=void 0),(t=t||{}).path=t.path||"/socket.io",this.opts=t,Af(this,t),this.reconnection(!1!==t.reconnection),this.reconnectionAttempts(t.reconnectionAttempts||1/0),this.reconnectionDelay(t.reconnectionDelay||1e3),this.reconnectionDelayMax(t.reconnectionDelayMax||5e3),this.randomizationFactor(null!==(n=t.randomizationFactor)&&void 0!==n?n:.5),this.backoff=new wd({min:this.reconnectionDelay(),max:this.reconnectionDelayMax(),jitter:this.randomizationFactor()}),this.timeout(null==t.timeout?2e4:t.timeout),this._readyState="closed",this.uri=e;const r=t.parser||md;this.encoder=new r.Encoder,this.decoder=new r.Decoder,this._autoConnect=!1!==t.autoConnect,this._autoConnect&&this.open()}reconnection(e){return arguments.length?(this._reconnection=!!e,e||(this.skipReconnect=!0),this):this._reconnection}reconnectionAttempts(e){return void 0===e?this._reconnectionAttempts:(this._reconnectionAttempts=e,this)}reconnectionDelay(e){var t;return void 0===e?this._reconnectionDelay:(this._reconnectionDelay=e,null===(t=this.backoff)||void 0===t||t.setMin(e),this)}randomizationFactor(e){var t;return void 0===e?this._randomizationFactor:(this._randomizationFactor=e,null===(t=this.backoff)||void 0===t||t.setJitter(e),this)}reconnectionDelayMax(e){var t;return void 0===e?this._reconnectionDelayMax:(this._reconnectionDelayMax=e,null===(t=this.backoff)||void 0===t||t.setMax(e),this)}timeout(e){return arguments.length?(this._timeout=e,this):this._timeout}maybeReconnectOnOpen(){!this._reconnecting&&this._reconnection&&0===this.backoff.attempts&&this.reconnect()}open(e){if(~this._readyState.indexOf("open"))return this;this.engine=new Yf(this.uri,this.opts);const t=this.engine,n=this;this._readyState="opening",this.skipReconnect=!1;const r=gd(t,"open",function(){n.onopen(),e&&e()}),i=t=>{this.cleanup(),this._readyState="closed",this.emitReserved("error",t),e?e(t):this.maybeReconnectOnOpen()},a=gd(t,"error",i);if(!1!==this._timeout){const e=this._timeout,n=this.setTimeoutFn(()=>{r(),i(new Error("timeout")),t.close()},e);this.opts.autoUnref&&n.unref(),this.subs.push(()=>{this.clearTimeoutFn(n)})}return this.subs.push(r),this.subs.push(a),this}connect(e){return this.open(e)}onopen(){this.cleanup(),this._readyState="open",this.emitReserved("open");const e=this.engine;this.subs.push(gd(e,"ping",this.onping.bind(this)),gd(e,"data",this.ondata.bind(this)),gd(e,"error",this.onerror.bind(this)),gd(e,"close",this.onclose.bind(this)),gd(this.decoder,"decoded",this.ondecoded.bind(this)))}onping(){this.emitReserved("ping")}ondata(e){try{this.decoder.add(e)}catch(t){this.onclose("parse error",t)}}ondecoded(e){_f(()=>{this.emitReserved("packet",e)},this.setTimeoutFn)}onerror(e){this.emitReserved("error",e)}socket(e,t){let n=this.nsps[e];return n?this._autoConnect&&!n.active&&n.connect():(n=new yd(this,e,t),this.nsps[e]=n),n}_destroy(e){const t=Object.keys(this.nsps);for(const n of t){if(this.nsps[n].active)return}this._close()}_packet(e){const t=this.encoder.encode(e);for(let n=0;n<t.length;n++)this.engine.write(t[n],e.options)}cleanup(){this.subs.forEach(e=>e()),this.subs.length=0,this.decoder.destroy()}_close(){this.skipReconnect=!0,this._reconnecting=!1,this.onclose("forced close")}disconnect(){return this._close()}onclose(e,t){var n;this.cleanup(),null===(n=this.engine)||void 0===n||n.close(),this.backoff.reset(),this._readyState="closed",this.emitReserved("close",e,t),this._reconnection&&!this.skipReconnect&&this.reconnect()}reconnect(){if(this._reconnecting||this.skipReconnect)return this;const e=this;if(this.backoff.attempts>=this._reconnectionAttempts)this.backoff.reset(),this.emitReserved("reconnect_failed"),this._reconnecting=!1;else{const t=this.backoff.duration();this._reconnecting=!0;const n=this.setTimeoutFn(()=>{e.skipReconnect||(this.emitReserved("reconnect_attempt",e.backoff.attempts),e.skipReconnect||e.open(t=>{t?(e._reconnecting=!1,e.reconnect(),this.emitReserved("reconnect_error",t)):e.onreconnect()}))},t);this.opts.autoUnref&&n.unref(),this.subs.push(()=>{this.clearTimeoutFn(n)})}}onreconnect(){const e=this.backoff.attempts;this._reconnecting=!1,this.backoff.reset(),this.emitReserved("reconnect",e)}}const xd={};function _d(e,t){"object"==typeof e&&(t=e,e=void 0);const n=function(e,t="",n){let r=e;n=n||"undefined"!=typeof location&&location,null==e&&(e=n.protocol+"//"+n.host),"string"==typeof e&&("/"===e.charAt(0)&&(e="/"===e.charAt(1)?n.protocol+e:n.host+e),/^(https?|wss?):\/\//.test(e)||(e=void 0!==n?n.protocol+"//"+e:"https://"+e),r=Kf(e)),r.port||(/^(http|ws)$/.test(r.protocol)?r.port="80":/^(http|ws)s$/.test(r.protocol)&&(r.port="443")),r.path=r.path||"/";const i=-1!==r.host.indexOf(":")?"["+r.host+"]":r.host;return r.id=r.protocol+"://"+i+":"+r.port+t,r.href=r.protocol+"://"+i+(n&&n.port===r.port?"":":"+r.port),r}(e,(t=t||{}).path||"/socket.io"),r=n.source,i=n.id,a=n.path,o=xd[i]&&a in xd[i].nsps;let s;return t.forceNew||t["force new connection"]||!1===t.multiplex||o?s=new kd(r,t):(xd[i]||(xd[i]=new kd(r,t)),s=xd[i]),n.query&&!t.query&&(t.query=n.queryKey),s.socket(n.path,t)}Object.assign(_d,{Manager:kd,Socket:yd,io:_d,connect:_d});class Sd extends Gc.EventEmitter{constructor(){super(...arguments),this.q=null,this.B=null}connect(e,t){try{this.B||(this.B=e,this.q=_d(e,{transports:["websocket"],timeout:1e4,extraHeaders:{"X-Extension-Id":rr()||""},auth:{endpoint:t}}),this.q?.on(Jn,()=>{this.emit(Jn)}),this.q?.on(er,()=>this.emit(er)),this.q?.on(Yn,e=>this.emit(Yn,e)),this.q?.onAny((e,t)=>{this.emit(e,t)}))}catch(n){}}send(e,t){this.q?.emit(e,t)}disconnect(){this.q?.disconnect(),this.q=null,this.B=null}}const Cd=new Sd;Jc.startListening({matcher:lu.endpoints.getData.matchFulfilled,effect:async(e,t)=>{try{const t=e.payload,n=Td.getState().api.endpoint;t.server&&n&&(Cd.disconnect(),Cd.connect(t.server,n))}catch(n){}}}),Jc.startListening({matcher:lu.endpoints.getData.matchPending,effect:async(e,t)=>{}}),Jc.startListening({matcher:lu.endpoints.getData.matchRejected,effect:async(e,t)=>{t.dispatch(_r(0)),t.dispatch(dr(!1))}}),Jc.startListening({actionCreator:fu,effect:e=>{const t=Td.getState(),n=t.ui,r=t.api;r.isAccount?.balance&&(n.run&&n.isTp&&r.isAccount.balance>=n.tp&&(Td.dispatch(vr({type:"success",text:is(n.localCode||"en","tp_success")})),Td.dispatch(dr(!1))),n.run&&n.isSl&&r.isAccount.balance<=n.sl&&(Td.dispatch(vr({type:"success",text:is(n.localCode||"en","sl_success")})),Td.dispatch(dr(!1))))}}),Jc.startListening({actionCreator:hu,effect:e=>{const t=Td.getState();t.api?.endpoint&&Cd.send(t.api.endpoint.concat("/asset"),e.payload)}}),Jc.startListening({actionCreator:cu,effect:e=>{Td.getState().api.asset?Td.dispatch(yr(!1)):(Td.dispatch(dr(!1)),Td.dispatch(yr(!0)))}}),Jc.startListening({actionCreator:pu,effect:async e=>{Td.getState(),Td.dispatch(br(!1)),Xc.j("31",e.payload.url)}}),Jc.startListening({actionCreator:Hc,effect:(e,t)=>{const n=Td.getState();e.payload===Xn.ERROR&&t.dispatch(dr(!1)),e.payload===Xn.CONNECT&&n.api?.endpoint&&n.api.uid&&Cd.send(n.api.endpoint.concat("/asset"),n.api.uid)}}),Jc.startListening({actionCreator:Qc,effect:(e,t)=>{const n=Td.getState();n.ws.status===Xn.CONNECT&&n.api?.endpoint&&n.api.uid&&Cd.send(n.api.endpoint.concat("/candle"),e.payload)}}),Jc.startListening({actionCreator:Wc,effect:e=>{Yc.N(e.payload,e=>{Xc.j("26",e)})}}),Jc.startListening({actionCreator:oc,effect:e=>{}}),Jc.startListening({actionCreator:ac,effect:e=>{const t=Td.getState();t.ui,t.api;const n=t.order.orders.find(t=>t.id===e.payload.id);n&&"number"==typeof n.profit&&Td.dispatch(sc({stat_profit:n.profit>0?n.profit:0,stat_profit_count:n.profit>0?1:0,stat_loss:n.profit<0?n.profit:0,stat_loss_count:n.profit<0?1:0}))}});const Td=function(e){const t=function(e){const{thunk:t=!0,immutableCheck:n=!0,serializableCheck:r=!0,actionCreatorCheck:i=!0}=e??{};let a=new qt;return t&&("boolean"==typeof t?a.push(Ft):a.push(It(t.extraArgument))),a},{reducer:n,middleware:r,devTools:i=!0,preloadedState:a,enhancers:o}=e||{};let s,l;if("function"==typeof n)s=n;else{if(!ue(n))throw new Error(Zn(1));s=fe(n)}l="function"==typeof r?r(t):t();let u=de;i&&(u=Nt({trace:!1,..."object"==typeof i&&i}));const c=function(...e){return t=>(n,r)=>{const i=t(n,r);let a=()=>{throw new Error(ae(15))};const o={getState:i.getState,dispatch:(e,...t)=>a(e,...t)},s=e.map(e=>e(o));return a=de(...s)(i.dispatch),{...i,dispatch:a}}}(...l),f=Qt(c);return ce(s,a,u(..."function"==typeof o?o(f):f()))}({reducer:{ui:fr.reducer,ws:Bc.reducer,api:su.reducer,order:ic.reducer,[lu.reducerPath]:lu.reducer},devTools:!1,middleware:e=>e({serializableCheck:{ignoredPaths:["ui.alerts","dataApi.queries"],ignoredActionPaths:["payload.0.props.button.click","meta.baseQueryMeta"]}}).concat(lu.middleware).concat(Jc.middleware)});var Ed;Ed=Td.dispatch,Xc.on("1",e=>{Ed(cu(e))}),Xc.on("2",e=>{Ed(hu(e))}),Xc.on("4",e=>{Ed(cu({domain:e}))}),Xc.on("3.1",e=>{Ed(fu(e))}),Xc.on("16",e=>{Ed(pr(e))}),Xc.on("30",e=>{Ed(cu({assets:e}))}),Xc.on("27",e=>{Ed(oc(e))}),Xc.on("28",e=>{Ed(ac(e))}),Xc.on("17",e=>{Ed(Qc(e))}),function(e){Cd.on(Jn,()=>e(Hc(Xn.CONNECT))),Cd.on(er,()=>e(Hc(Xn.DISCONNECT))),Cd.on(Yn,t=>e(Hc(Xn.ERROR))),Cd.on("signals",t=>e(Wc(t))),Cd.on("signals/history",t=>e(Uc(t))),Cd.on("asset",t=>e(cu({asset:t})))}(Td.dispatch);const Ad=document.createElement("div");document.body.appendChild(Ad),j.createRoot(Ad).render(s.jsx(d.StrictMode,{children:s.jsx(K,{store:Td,children:s.jsx(bu,{children:s.jsx(os,{children:s.jsx(ts,{children:s.jsx(qc,{})})})})})}));
|
|
601
|
+
`;function qc(){const e=ee(),{data:t}=yu();return d.useEffect(()=>{t&&e(mr(t))},[t]),s.jsx(Lc,{})}const zc={status:Xn.NOT_CONNECT,signals:[],candles:{}},Bc=gn({name:"websocket",initialState:zc,reducers:{wsStatus:(e,t)=>{e.status=t.payload},pushSignal:(e,t)=>{e.signals.unshift(t.payload),e.signals.splice(30)},setSignalsHistory:(e,t)=>{e.signals=[...t.payload]},setCandles:(e,t)=>{e.candles=t.payload}}}),{wsStatus:Hc,pushSignal:Wc,setSignalsHistory:Uc,setCandles:Qc}=Bc.actions;var Vc,Kc={exports:{}};var Gc=function(){if(Vc)return Kc.exports;Vc=1;var e,t="object"==typeof Reflect?Reflect:null,n=t&&"function"==typeof t.apply?t.apply:function(e,t,n){return Function.prototype.apply.call(e,t,n)};e=t&&"function"==typeof t.ownKeys?t.ownKeys:Object.getOwnPropertySymbols?function(e){return Object.getOwnPropertyNames(e).concat(Object.getOwnPropertySymbols(e))}:function(e){return Object.getOwnPropertyNames(e)};var r=Number.isNaN||function(e){return e!=e};function i(){i.init.call(this)}Kc.exports=i,Kc.exports.once=function(e,t){return new Promise(function(n,r){function i(n){e.removeListener(t,a),r(n)}function a(){"function"==typeof e.removeListener&&e.removeListener("error",i),n([].slice.call(arguments))}p(e,t,a,{once:!0}),"error"!==t&&function(e,t,n){"function"==typeof e.on&&p(e,"error",t,n)}(e,i,{once:!0})})},i.EventEmitter=i,i.prototype._events=void 0,i.prototype._eventsCount=0,i.prototype._maxListeners=void 0;var a=10;function o(e){if("function"!=typeof e)throw new TypeError('The "listener" argument must be of type Function. Received type '+typeof e)}function s(e){return void 0===e._maxListeners?i.defaultMaxListeners:e._maxListeners}function l(e,t,n,r){var i,a,l;if(o(n),void 0===(a=e._events)?(a=e._events=Object.create(null),e._eventsCount=0):(void 0!==a.newListener&&(e.emit("newListener",t,n.listener?n.listener:n),a=e._events),l=a[t]),void 0===l)l=a[t]=n,++e._eventsCount;else if("function"==typeof l?l=a[t]=r?[n,l]:[l,n]:r?l.unshift(n):l.push(n),(i=s(e))>0&&l.length>i&&!l.warned){l.warned=!0;var u=new Error("Possible EventEmitter memory leak detected. "+l.length+" "+String(t)+" listeners added. Use emitter.setMaxListeners() to increase limit");u.name="MaxListenersExceededWarning",u.emitter=e,u.type=t,u.count=l.length,console&&console.warn}return e}function u(){if(!this.fired)return this.target.removeListener(this.type,this.wrapFn),this.fired=!0,0===arguments.length?this.listener.call(this.target):this.listener.apply(this.target,arguments)}function c(e,t,n){var r={fired:!1,wrapFn:void 0,target:e,type:t,listener:n},i=u.bind(r);return i.listener=n,r.wrapFn=i,i}function f(e,t,n){var r=e._events;if(void 0===r)return[];var i=r[t];return void 0===i?[]:"function"==typeof i?n?[i.listener||i]:[i]:n?function(e){for(var t=new Array(e.length),n=0;n<t.length;++n)t[n]=e[n].listener||e[n];return t}(i):h(i,i.length)}function d(e){var t=this._events;if(void 0!==t){var n=t[e];if("function"==typeof n)return 1;if(void 0!==n)return n.length}return 0}function h(e,t){for(var n=new Array(t),r=0;r<t;++r)n[r]=e[r];return n}function p(e,t,n,r){if("function"==typeof e.on)r.once?e.once(t,n):e.on(t,n);else{if("function"!=typeof e.addEventListener)throw new TypeError('The "emitter" argument must be of type EventEmitter. Received type '+typeof e);e.addEventListener(t,function i(a){r.once&&e.removeEventListener(t,i),n(a)})}}return Object.defineProperty(i,"defaultMaxListeners",{enumerable:!0,get:function(){return a},set:function(e){if("number"!=typeof e||e<0||r(e))throw new RangeError('The value of "defaultMaxListeners" is out of range. It must be a non-negative number. Received '+e+".");a=e}}),i.init=function(){void 0!==this._events&&this._events!==Object.getPrototypeOf(this)._events||(this._events=Object.create(null),this._eventsCount=0),this._maxListeners=this._maxListeners||void 0},i.prototype.setMaxListeners=function(e){if("number"!=typeof e||e<0||r(e))throw new RangeError('The value of "n" is out of range. It must be a non-negative number. Received '+e+".");return this._maxListeners=e,this},i.prototype.getMaxListeners=function(){return s(this)},i.prototype.emit=function(e){for(var t=[],r=1;r<arguments.length;r++)t.push(arguments[r]);var i="error"===e,a=this._events;if(void 0!==a)i=i&&void 0===a.error;else if(!i)return!1;if(i){var o;if(t.length>0&&(o=t[0]),o instanceof Error)throw o;var s=new Error("Unhandled error."+(o?" ("+o.message+")":""));throw s.context=o,s}var l=a[e];if(void 0===l)return!1;if("function"==typeof l)n(l,this,t);else{var u=l.length,c=h(l,u);for(r=0;r<u;++r)n(c[r],this,t)}return!0},i.prototype.addListener=function(e,t){return l(this,e,t,!1)},i.prototype.on=i.prototype.addListener,i.prototype.prependListener=function(e,t){return l(this,e,t,!0)},i.prototype.once=function(e,t){return o(t),this.on(e,c(this,e,t)),this},i.prototype.prependOnceListener=function(e,t){return o(t),this.prependListener(e,c(this,e,t)),this},i.prototype.removeListener=function(e,t){var n,r,i,a,s;if(o(t),void 0===(r=this._events))return this;if(void 0===(n=r[e]))return this;if(n===t||n.listener===t)0===--this._eventsCount?this._events=Object.create(null):(delete r[e],r.removeListener&&this.emit("removeListener",e,n.listener||t));else if("function"!=typeof n){for(i=-1,a=n.length-1;a>=0;a--)if(n[a]===t||n[a].listener===t){s=n[a].listener,i=a;break}if(i<0)return this;0===i?n.shift():function(e,t){for(;t+1<e.length;t++)e[t]=e[t+1];e.pop()}(n,i),1===n.length&&(r[e]=n[0]),void 0!==r.removeListener&&this.emit("removeListener",e,s||t)}return this},i.prototype.off=i.prototype.removeListener,i.prototype.removeAllListeners=function(e){var t,n,r;if(void 0===(n=this._events))return this;if(void 0===n.removeListener)return 0===arguments.length?(this._events=Object.create(null),this._eventsCount=0):void 0!==n[e]&&(0===--this._eventsCount?this._events=Object.create(null):delete n[e]),this;if(0===arguments.length){var i,a=Object.keys(n);for(r=0;r<a.length;++r)"removeListener"!==(i=a[r])&&this.removeAllListeners(i);return this.removeAllListeners("removeListener"),this._events=Object.create(null),this._eventsCount=0,this}if("function"==typeof(t=n[e]))this.removeListener(e,t);else if(void 0!==t)for(r=t.length-1;r>=0;r--)this.removeListener(e,t[r]);return this},i.prototype.listeners=function(e){return f(this,e,!0)},i.prototype.rawListeners=function(e){return f(this,e,!1)},i.listenerCount=function(e,t){return"function"==typeof e.listenerCount?e.listenerCount(t):d.call(e,t)},i.prototype.listenerCount=d,i.prototype.eventNames=function(){return this._eventsCount>0?e(this._events):[]},Kc.exports}();const Zc=e(Gc);const Xc=new class extends Zc{constructor(){super(),this._permit=!0,window.addEventListener("message",this._handleIframeMessage.bind(this),!1)}set lock(e){this._permit=e}j(e,t){try{const n=rr();n&&window.parent&&window.parent.postMessage({id:n,event:e,data:t},"*")}catch(n){}}_handleIframeMessage(e){try{if(!this._permit)return;const t=e.data;"object"==typeof t&&"id"in t&&t.id===rr()&&"event"in t&&"data"in t&&this.emit(t.event,t.data)}catch(t){}}};const Jc=((e={})=>{const t=new Map,n=new Map,{extra:r,onError:i=Gn}=e;En(i);const a=e=>(e=>(e.unsubscribe=()=>t.delete(e.id),t.set(e.id,e),t=>{e.unsubscribe(),t?.cancelActive&&Wn(e)}))(Hn(t,e)??Bn(e));Fn(a,{withTypes:()=>a});const o=e=>{const n=Hn(t,e);return n&&(n.unsubscribe(),e.cancelActive&&Wn(n)),!!n};Fn(o,{withTypes:()=>o});const s=async(e,o,s,l)=>{const u=new AbortController,c=qn(a,u.signal),f=[];try{e.pending.add(u),(e=>{const t=n.get(e)??0;n.set(e,t+1)})(e),await Promise.resolve(e.effect(o,Fn({},s,{getOriginalState:l,condition:(e,t)=>c(e,t).then(Boolean),take:c,delay:Ln(u.signal),pause:Pn(u.signal),extra:r,signal:u.signal,fork:Dn(u.signal,f),unsubscribe:e.unsubscribe,subscribe:()=>{t.set(e.id,e)},cancelActiveListeners:()=>{e.pending.forEach((e,t,n)=>{e!==u&&($n(e,Sn),n.delete(e))})},cancel:()=>{$n(u,Sn),e.pending.delete(u)},throwIfCancelled:()=>{jn(u.signal)}})))}catch(d){d instanceof Tn||Un(i,d,{raisedBy:"effect"})}finally{await Promise.all(f),$n(u,Cn),(e=>{const t=n.get(e)??1;1===t?n.delete(e):n.set(e,t-1)})(e),e.pending.delete(u)}},l=((e,t)=>()=>{for(const e of t.keys())Wn(e);e.clear()})(t,n);return{middleware:e=>n=>r=>{if(!he(r))return n(r);if(Qn.match(r))return a(r.payload);if(Vn.match(r))return void l();if(Kn.match(r))return o(r.payload);let u=e.getState();const c=()=>{if(u===In)throw new Error(Zn(23));return u};let f;try{if(f=n(r),t.size>0){const n=e.getState(),a=Array.from(t.values());for(const t of a){let a=!1;try{a=t.predicate(r,n,u)}catch(d){a=!1,Un(i,d,{raisedBy:"predicate"})}a&&s(t,r,e,c)}}}finally{u=In}return f},startListening:a,stopListening:o,clearListeners:l}})();const Yc=new class{constructor(){}O(e,t){const n=e.api.assets.find(e=>e.symbol===t.symbol);if(!n)return!1;const r=e.ui.duration||60*t.duration;if(!n.duration.length)return!1;const i=Math.min(...n.duration),a=Math.max(...n.duration);if(r<i||r>a)return!1;if(!n.active)return!1;if(n.payout<e.ui.minPayout)return!1;return!(e.order.orders.filter(e=>"number"!=typeof e.profit).length>=e.ui.maxTrades)}P(e,t){const n=e.order.orders.filter(e=>"profit"in e)[0],r=e.ui,i=this.F;let a=r.amount;if(n){const e=n.profit;e>0&&r.isIncreaseWin?(a="loss"===i?r.amount:Math.floor(n.amount*r.increaseWin),this.F="win"):e<0&&r.isIncreaseLoss?(a="win"===i?r.amount:Math.floor(n.amount*r.increaseLoss),this.F="loss"):this.F=void 0}return a}I(e,t){const n=e.ui,r=e.api;return r.isAccount.balance&&n.isTp&&n.tp<=r.isAccount.balance&&Td.dispatch(vr({type:"warning",text:is(n.localCode||"en","tp_err")})),!0}N(e,t){const n=Td.getState(),r=n.api;if(!n.ui.run||!r.isAccount.account_id)return;if(!this.O(n,e))return;const i=this.P(n,e);t({account_id:r.isAccount.account_id,amount:i,asset:e.symbol,dir:e.dir,duration:n.ui.duration||60*e.duration})}};Jc.startListening({actionCreator:dr,effect:e=>{if(e.payload){const e=Td.getState(),t=e.ui,n=e.api;if(!n.isAccount||!n.isAccount?.deals||void 0===n.isAccount?.balance||!n.isAccount?.symbol)return void Td.dispatch(dr(!1));const r=n.isAccount.balance,i=n.isAccount.deals.min,a=n.isAccount.deals.max,o=n.isAccount.symbol;if(t.amount<i)return Td.dispatch(vr({type:"warning",text:is(t.localCode||"en","check_minAmount")})),void Td.dispatch(dr(!1));if(t.amount>a)return Td.dispatch(vr({type:"warning",text:is(t.localCode||"en","check_maxAmount")})),void Td.dispatch(dr(!1));if(0===r||r<i)return Td.dispatch(vr({type:"warning",text:is(t.localCode||"en","no_balance",[o.concat(String(r))])})),void Td.dispatch(dr(!1));if(t.amount>r)return Td.dispatch(vr({type:"warning",text:is(t.localCode||"en","insufficient_balance",[o.concat(String(t.amount))])})),void Td.dispatch(dr(!1));if(t.isTp&&t.tp<=r)return Td.dispatch(vr({type:"warning",text:is(t.localCode||"en","tp_err")})),void Td.dispatch(dr(!1));if(t.isSl&&t.sl>=r)return Td.dispatch(vr({type:"warning",text:is(t.localCode||"en","sl_err")})),void Td.dispatch(dr(!1));Td.dispatch(vr());if(e.order.orders.filter(e=>"number"!=typeof e.profit).length>0)return;const s=e.ws.signals.find(e=>e.closeTimestamp-Math.floor(Date.now()/1e3)>0);s&&Yc.N(s,e=>{Xc.j("26",e)})}}}),Jc.startListening({actionCreator:hr,effect:e=>{Td.getState()}}),Jc.startListening({actionCreator:gr,effect:e=>{Xc.j("23",e.payload)}}),Jc.startListening({actionCreator:br,effect:e=>{Xc.j("22",e.payload)}}),Jc.startListening({actionCreator:yr,effect:(e,t)=>{e.payload&&t.dispatch(dr(!1))}}),Jc.startListening({actionCreator:mr,effect:(e,t)=>{e.payload&&Xc.j("24",e.payload)}});const ef=Object.create(null);ef.open="0",ef.close="1",ef.ping="2",ef.pong="3",ef.message="4",ef.upgrade="5",ef.noop="6";const tf=Object.create(null);Object.keys(ef).forEach(e=>{tf[ef[e]]=e});const nf={type:"error",data:"parser error"},rf="function"==typeof Blob||"undefined"!=typeof Blob&&"[object BlobConstructor]"===Object.prototype.toString.call(Blob),af="function"==typeof ArrayBuffer,of=e=>"function"==typeof ArrayBuffer.isView?ArrayBuffer.isView(e):e&&e.buffer instanceof ArrayBuffer,sf=({type:e,data:t},n,r)=>rf&&t instanceof Blob?n?r(t):lf(t,r):af&&(t instanceof ArrayBuffer||of(t))?n?r(t):lf(new Blob([t]),r):r(ef[e]+(t||"")),lf=(e,t)=>{const n=new FileReader;return n.onload=function(){const e=n.result.split(",")[1];t("b"+(e||""))},n.readAsDataURL(e)};function uf(e){return e instanceof Uint8Array?e:e instanceof ArrayBuffer?new Uint8Array(e):new Uint8Array(e.buffer,e.byteOffset,e.byteLength)}let cf;const ff="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",df="undefined"==typeof Uint8Array?[]:new Uint8Array(256);for(let Md=0;Md<64;Md++)df[ff.charCodeAt(Md)]=Md;const hf="function"==typeof ArrayBuffer,pf=(e,t)=>{if("string"!=typeof e)return{type:"message",data:mf(e,t)};const n=e.charAt(0);if("b"===n)return{type:"message",data:vf(e.substring(1),t)};return tf[n]?e.length>1?{type:tf[n],data:e.substring(1)}:{type:tf[n]}:nf},vf=(e,t)=>{if(hf){const n=(e=>{let t,n,r,i,a,o=.75*e.length,s=e.length,l=0;"="===e[e.length-1]&&(o--,"="===e[e.length-2]&&o--);const u=new ArrayBuffer(o),c=new Uint8Array(u);for(t=0;t<s;t+=4)n=df[e.charCodeAt(t)],r=df[e.charCodeAt(t+1)],i=df[e.charCodeAt(t+2)],a=df[e.charCodeAt(t+3)],c[l++]=n<<2|r>>4,c[l++]=(15&r)<<4|i>>2,c[l++]=(3&i)<<6|63&a;return u})(e);return mf(n,t)}return{base64:!0,data:e}},mf=(e,t)=>"blob"===t?e instanceof Blob?e:new Blob([e]):e instanceof ArrayBuffer?e:e.buffer,gf=String.fromCharCode(30);function bf(){return new TransformStream({transform(e,t){!function(e,t){rf&&e.data instanceof Blob?e.data.arrayBuffer().then(uf).then(t):af&&(e.data instanceof ArrayBuffer||of(e.data))?t(uf(e.data)):sf(e,!1,e=>{cf||(cf=new TextEncoder),t(cf.encode(e))})}(e,n=>{const r=n.length;let i;if(r<126)i=new Uint8Array(1),new DataView(i.buffer).setUint8(0,r);else if(r<65536){i=new Uint8Array(3);const e=new DataView(i.buffer);e.setUint8(0,126),e.setUint16(1,r)}else{i=new Uint8Array(9);const e=new DataView(i.buffer);e.setUint8(0,127),e.setBigUint64(1,BigInt(r))}e.data&&"string"!=typeof e.data&&(i[0]|=128),t.enqueue(i),t.enqueue(n)})}})}let yf;function wf(e){return e.reduce((e,t)=>e+t.length,0)}function kf(e,t){if(e[0].length===t)return e.shift();const n=new Uint8Array(t);let r=0;for(let i=0;i<t;i++)n[i]=e[0][r++],r===e[0].length&&(e.shift(),r=0);return e.length&&r<e[0].length&&(e[0]=e[0].slice(r)),n}function xf(e){if(e)return function(e){for(var t in xf.prototype)e[t]=xf.prototype[t];return e}(e)}xf.prototype.on=xf.prototype.addEventListener=function(e,t){return this._callbacks=this._callbacks||{},(this._callbacks["$"+e]=this._callbacks["$"+e]||[]).push(t),this},xf.prototype.once=function(e,t){function n(){this.off(e,n),t.apply(this,arguments)}return n.fn=t,this.on(e,n),this},xf.prototype.off=xf.prototype.removeListener=xf.prototype.removeAllListeners=xf.prototype.removeEventListener=function(e,t){if(this._callbacks=this._callbacks||{},0==arguments.length)return this._callbacks={},this;var n,r=this._callbacks["$"+e];if(!r)return this;if(1==arguments.length)return delete this._callbacks["$"+e],this;for(var i=0;i<r.length;i++)if((n=r[i])===t||n.fn===t){r.splice(i,1);break}return 0===r.length&&delete this._callbacks["$"+e],this},xf.prototype.emit=function(e){this._callbacks=this._callbacks||{};for(var t=new Array(arguments.length-1),n=this._callbacks["$"+e],r=1;r<arguments.length;r++)t[r-1]=arguments[r];if(n){r=0;for(var i=(n=n.slice(0)).length;r<i;++r)n[r].apply(this,t)}return this},xf.prototype.emitReserved=xf.prototype.emit,xf.prototype.listeners=function(e){return this._callbacks=this._callbacks||{},this._callbacks["$"+e]||[]},xf.prototype.hasListeners=function(e){return!!this.listeners(e).length};const _f="function"==typeof Promise&&"function"==typeof Promise.resolve?e=>Promise.resolve().then(e):(e,t)=>t(e,0),Sf="undefined"!=typeof self?self:"undefined"!=typeof window?window:Function("return this")();function Cf(e,...t){return t.reduce((t,n)=>(e.hasOwnProperty(n)&&(t[n]=e[n]),t),{})}const Tf=Sf.setTimeout,Ef=Sf.clearTimeout;function Af(e,t){t.useNativeTimers?(e.setTimeoutFn=Tf.bind(Sf),e.clearTimeoutFn=Ef.bind(Sf)):(e.setTimeoutFn=Sf.setTimeout.bind(Sf),e.clearTimeoutFn=Sf.clearTimeout.bind(Sf))}function Rf(e){return"string"==typeof e?function(e){let t=0,n=0;for(let r=0,i=e.length;r<i;r++)t=e.charCodeAt(r),t<128?n+=1:t<2048?n+=2:t<55296||t>=57344?n+=3:(r++,n+=4);return n}(e):Math.ceil(1.33*(e.byteLength||e.size))}function Mf(){return Date.now().toString(36).substring(3)+Math.random().toString(36).substring(2,5)}class $f extends Error{constructor(e,t,n){super(e),this.description=t,this.context=n,this.type="TransportError"}}class jf extends xf{constructor(e){super(),this.writable=!1,Af(this,e),this.opts=e,this.query=e.query,this.socket=e.socket,this.supportsBinary=!e.forceBase64}onError(e,t,n){return super.emitReserved("error",new $f(e,t,n)),this}open(){return this.readyState="opening",this.doOpen(),this}close(){return"opening"!==this.readyState&&"open"!==this.readyState||(this.doClose(),this.onClose()),this}send(e){"open"===this.readyState&&this.write(e)}onOpen(){this.readyState="open",this.writable=!0,super.emitReserved("open")}onData(e){const t=pf(e,this.socket.binaryType);this.onPacket(t)}onPacket(e){super.emitReserved("packet",e)}onClose(e){this.readyState="closed",super.emitReserved("close",e)}pause(e){}createUri(e,t={}){return e+"://"+this._hostname()+this._port()+this.opts.path+this._query(t)}_hostname(){const e=this.opts.hostname;return-1===e.indexOf(":")?e:"["+e+"]"}_port(){return this.opts.port&&(this.opts.secure&&Number(443!==this.opts.port)||!this.opts.secure&&80!==Number(this.opts.port))?":"+this.opts.port:""}_query(e){const t=function(e){let t="";for(let n in e)e.hasOwnProperty(n)&&(t.length&&(t+="&"),t+=encodeURIComponent(n)+"="+encodeURIComponent(e[n]));return t}(e);return t.length?"?"+t:""}}class Of extends jf{constructor(){super(...arguments),this._polling=!1}get name(){return"polling"}doOpen(){this._poll()}pause(e){this.readyState="pausing";const t=()=>{this.readyState="paused",e()};if(this._polling||!this.writable){let e=0;this._polling&&(e++,this.once("pollComplete",function(){--e||t()})),this.writable||(e++,this.once("drain",function(){--e||t()}))}else t()}_poll(){this._polling=!0,this.doPoll(),this.emitReserved("poll")}onData(e){((e,t)=>{const n=e.split(gf),r=[];for(let i=0;i<n.length;i++){const e=pf(n[i],t);if(r.push(e),"error"===e.type)break}return r})(e,this.socket.binaryType).forEach(e=>{if("opening"===this.readyState&&"open"===e.type&&this.onOpen(),"close"===e.type)return this.onClose({description:"transport closed by the server"}),!1;this.onPacket(e)}),"closed"!==this.readyState&&(this._polling=!1,this.emitReserved("pollComplete"),"open"===this.readyState&&this._poll())}doClose(){const e=()=>{this.write([{type:"close"}])};"open"===this.readyState?e():this.once("open",e)}write(e){this.writable=!1,((e,t)=>{const n=e.length,r=new Array(n);let i=0;e.forEach((e,a)=>{sf(e,!1,e=>{r[a]=e,++i===n&&t(r.join(gf))})})})(e,e=>{this.doWrite(e,()=>{this.writable=!0,this.emitReserved("drain")})})}uri(){const e=this.opts.secure?"https":"http",t=this.query||{};return!1!==this.opts.timestampRequests&&(t[this.opts.timestampParam]=Mf()),this.supportsBinary||t.sid||(t.b64=1),this.createUri(e,t)}}let Pf=!1;try{Pf="undefined"!=typeof XMLHttpRequest&&"withCredentials"in new XMLHttpRequest}catch(Rd){}const Lf=Pf;function Ff(){}class If extends Of{constructor(e){if(super(e),"undefined"!=typeof location){const t="https:"===location.protocol;let n=location.port;n||(n=t?"443":"80"),this.xd="undefined"!=typeof location&&e.hostname!==location.hostname||n!==e.port}}doWrite(e,t){const n=this.request({method:"POST",data:e});n.on("success",t),n.on("error",(e,t)=>{this.onError("xhr post error",e,t)})}doPoll(){const e=this.request();e.on("data",this.onData.bind(this)),e.on("error",(e,t)=>{this.onError("xhr poll error",e,t)}),this.pollXhr=e}}let Nf=class e extends xf{constructor(e,t,n){super(),this.createRequest=e,Af(this,n),this._opts=n,this._method=n.method||"GET",this._uri=t,this._data=void 0!==n.data?n.data:null,this._create()}_create(){var t;const n=Cf(this._opts,"agent","pfx","key","passphrase","cert","ca","ciphers","rejectUnauthorized","autoUnref");n.xdomain=!!this._opts.xd;const r=this._xhr=this.createRequest(n);try{r.open(this._method,this._uri,!0);try{if(this._opts.extraHeaders){r.setDisableHeaderCheck&&r.setDisableHeaderCheck(!0);for(let e in this._opts.extraHeaders)this._opts.extraHeaders.hasOwnProperty(e)&&r.setRequestHeader(e,this._opts.extraHeaders[e])}}catch(i){}if("POST"===this._method)try{r.setRequestHeader("Content-type","text/plain;charset=UTF-8")}catch(i){}try{r.setRequestHeader("Accept","*/*")}catch(i){}null===(t=this._opts.cookieJar)||void 0===t||t.addCookies(r),"withCredentials"in r&&(r.withCredentials=this._opts.withCredentials),this._opts.requestTimeout&&(r.timeout=this._opts.requestTimeout),r.onreadystatechange=()=>{var e;3===r.readyState&&(null===(e=this._opts.cookieJar)||void 0===e||e.parseCookies(r.getResponseHeader("set-cookie"))),4===r.readyState&&(200===r.status||1223===r.status?this._onLoad():this.setTimeoutFn(()=>{this._onError("number"==typeof r.status?r.status:0)},0))},r.send(this._data)}catch(i){return void this.setTimeoutFn(()=>{this._onError(i)},0)}"undefined"!=typeof document&&(this._index=e.requestsCount++,e.requests[this._index]=this)}_onError(e){this.emitReserved("error",e,this._xhr),this._cleanup(!0)}_cleanup(t){if(void 0!==this._xhr&&null!==this._xhr){if(this._xhr.onreadystatechange=Ff,t)try{this._xhr.abort()}catch(n){}"undefined"!=typeof document&&delete e.requests[this._index],this._xhr=null}}_onLoad(){const e=this._xhr.responseText;null!==e&&(this.emitReserved("data",e),this.emitReserved("success"),this._cleanup())}abort(){this._cleanup()}};if(Nf.requestsCount=0,Nf.requests={},"undefined"!=typeof document)if("function"==typeof attachEvent)attachEvent("onunload",Df);else if("function"==typeof addEventListener){addEventListener("onpagehide"in Sf?"pagehide":"unload",Df,!1)}function Df(){for(let e in Nf.requests)Nf.requests.hasOwnProperty(e)&&Nf.requests[e].abort()}const qf=function(){const e=zf({xdomain:!1});return e&&null!==e.responseType}();function zf(e){const t=e.xdomain;try{if("undefined"!=typeof XMLHttpRequest&&(!t||Lf))return new XMLHttpRequest}catch(n){}if(!t)try{return new(Sf[["Active"].concat("Object").join("X")])("Microsoft.XMLHTTP")}catch(n){}}const Bf="undefined"!=typeof navigator&&"string"==typeof navigator.product&&"reactnative"===navigator.product.toLowerCase();class Hf extends jf{get name(){return"websocket"}doOpen(){const e=this.uri(),t=this.opts.protocols,n=Bf?{}:Cf(this.opts,"agent","perMessageDeflate","pfx","key","passphrase","cert","ca","ciphers","rejectUnauthorized","localAddress","protocolVersion","origin","maxPayload","family","checkServerIdentity");this.opts.extraHeaders&&(n.headers=this.opts.extraHeaders);try{this.ws=this.createSocket(e,t,n)}catch(Rd){return this.emitReserved("error",Rd)}this.ws.binaryType=this.socket.binaryType,this.addEventListeners()}addEventListeners(){this.ws.onopen=()=>{this.opts.autoUnref&&this.ws._socket.unref(),this.onOpen()},this.ws.onclose=e=>this.onClose({description:"websocket connection closed",context:e}),this.ws.onmessage=e=>this.onData(e.data),this.ws.onerror=e=>this.onError("websocket error",e)}write(e){this.writable=!1;for(let t=0;t<e.length;t++){const n=e[t],r=t===e.length-1;sf(n,this.supportsBinary,e=>{try{this.doWrite(n,e)}catch(t){}r&&_f(()=>{this.writable=!0,this.emitReserved("drain")},this.setTimeoutFn)})}}doClose(){void 0!==this.ws&&(this.ws.onerror=()=>{},this.ws.close(),this.ws=null)}uri(){const e=this.opts.secure?"wss":"ws",t=this.query||{};return this.opts.timestampRequests&&(t[this.opts.timestampParam]=Mf()),this.supportsBinary||(t.b64=1),this.createUri(e,t)}}const Wf=Sf.WebSocket||Sf.MozWebSocket;const Uf={websocket:class extends Hf{createSocket(e,t,n){return Bf?new Wf(e,t,n):t?new Wf(e,t):new Wf(e)}doWrite(e,t){this.ws.send(t)}},webtransport:class extends jf{get name(){return"webtransport"}doOpen(){try{this._transport=new WebTransport(this.createUri("https"),this.opts.transportOptions[this.name])}catch(Rd){return this.emitReserved("error",Rd)}this._transport.closed.then(()=>{this.onClose()}).catch(e=>{this.onError("webtransport error",e)}),this._transport.ready.then(()=>{this._transport.createBidirectionalStream().then(e=>{const t=function(e,t){yf||(yf=new TextDecoder);const n=[];let r=0,i=-1,a=!1;return new TransformStream({transform(o,s){for(n.push(o);;){if(0===r){if(wf(n)<1)break;const e=kf(n,1);a=!(128&~e[0]),i=127&e[0],r=i<126?3:126===i?1:2}else if(1===r){if(wf(n)<2)break;const e=kf(n,2);i=new DataView(e.buffer,e.byteOffset,e.length).getUint16(0),r=3}else if(2===r){if(wf(n)<8)break;const e=kf(n,8),t=new DataView(e.buffer,e.byteOffset,e.length),a=t.getUint32(0);if(a>Math.pow(2,21)-1){s.enqueue(nf);break}i=a*Math.pow(2,32)+t.getUint32(4),r=3}else{if(wf(n)<i)break;const e=kf(n,i);s.enqueue(pf(a?e:yf.decode(e),t)),r=0}if(0===i||i>e){s.enqueue(nf);break}}}})}(Number.MAX_SAFE_INTEGER,this.socket.binaryType),n=e.readable.pipeThrough(t).getReader(),r=bf();r.readable.pipeTo(e.writable),this._writer=r.writable.getWriter();const i=()=>{n.read().then(({done:e,value:t})=>{e||(this.onPacket(t),i())}).catch(e=>{})};i();const a={type:"open"};this.query.sid&&(a.data=`{"sid":"${this.query.sid}"}`),this._writer.write(a).then(()=>this.onOpen())})})}write(e){this.writable=!1;for(let t=0;t<e.length;t++){const n=e[t],r=t===e.length-1;this._writer.write(n).then(()=>{r&&_f(()=>{this.writable=!0,this.emitReserved("drain")},this.setTimeoutFn)})}}doClose(){var e;null===(e=this._transport)||void 0===e||e.close()}},polling:class extends If{constructor(e){super(e);const t=e&&e.forceBase64;this.supportsBinary=qf&&!t}request(e={}){return Object.assign(e,{xd:this.xd},this.opts),new Nf(zf,this.uri(),e)}}},Qf=/^(?:(?![^:@\/?#]+:[^:@\/]*@)(http|https|ws|wss):\/\/)?((?:(([^:@\/?#]*)(?::([^:@\/?#]*))?)?@)?((?:[a-f0-9]{0,4}:){2,7}[a-f0-9]{0,4}|[^:\/?#]*)(?::(\d*))?)(((\/(?:[^?#](?![^?#\/]*\.[^?#\/.]+(?:[?#]|$)))*\/?)?([^?#\/]*))(?:\?([^#]*))?(?:#(.*))?)/,Vf=["source","protocol","authority","userInfo","user","password","host","port","relative","path","directory","file","query","anchor"];function Kf(e){if(e.length>8e3)throw"URI too long";const t=e,n=e.indexOf("["),r=e.indexOf("]");-1!=n&&-1!=r&&(e=e.substring(0,n)+e.substring(n,r).replace(/:/g,";")+e.substring(r,e.length));let i=Qf.exec(e||""),a={},o=14;for(;o--;)a[Vf[o]]=i[o]||"";return-1!=n&&-1!=r&&(a.source=t,a.host=a.host.substring(1,a.host.length-1).replace(/;/g,":"),a.authority=a.authority.replace("[","").replace("]","").replace(/;/g,":"),a.ipv6uri=!0),a.pathNames=function(e,t){const n=/\/{2,9}/g,r=t.replace(n,"/").split("/");"/"!=t.slice(0,1)&&0!==t.length||r.splice(0,1);"/"==t.slice(-1)&&r.splice(r.length-1,1);return r}(0,a.path),a.queryKey=function(e,t){const n={};return t.replace(/(?:^|&)([^&=]*)=?([^&]*)/g,function(e,t,r){t&&(n[t]=r)}),n}(0,a.query),a}const Gf="function"==typeof addEventListener&&"function"==typeof removeEventListener,Zf=[];Gf&&addEventListener("offline",()=>{Zf.forEach(e=>e())},!1);class Xf extends xf{constructor(e,t){if(super(),this.binaryType="arraybuffer",this.writeBuffer=[],this._prevBufferLen=0,this._pingInterval=-1,this._pingTimeout=-1,this._maxPayload=-1,this._pingTimeoutTime=1/0,e&&"object"==typeof e&&(t=e,e=null),e){const n=Kf(e);t.hostname=n.host,t.secure="https"===n.protocol||"wss"===n.protocol,t.port=n.port,n.query&&(t.query=n.query)}else t.host&&(t.hostname=Kf(t.host).host);Af(this,t),this.secure=null!=t.secure?t.secure:"undefined"!=typeof location&&"https:"===location.protocol,t.hostname&&!t.port&&(t.port=this.secure?"443":"80"),this.hostname=t.hostname||("undefined"!=typeof location?location.hostname:"localhost"),this.port=t.port||("undefined"!=typeof location&&location.port?location.port:this.secure?"443":"80"),this.transports=[],this._transportsByName={},t.transports.forEach(e=>{const t=e.prototype.name;this.transports.push(t),this._transportsByName[t]=e}),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},t),this.opts.path=this.opts.path.replace(/\/$/,"")+(this.opts.addTrailingSlash?"/":""),"string"==typeof this.opts.query&&(this.opts.query=function(e){let t={},n=e.split("&");for(let r=0,i=n.length;r<i;r++){let e=n[r].split("=");t[decodeURIComponent(e[0])]=decodeURIComponent(e[1])}return t}(this.opts.query)),Gf&&(this.opts.closeOnBeforeunload&&(this._beforeunloadEventListener=()=>{this.transport&&(this.transport.removeAllListeners(),this.transport.close())},addEventListener("beforeunload",this._beforeunloadEventListener,!1)),"localhost"!==this.hostname&&(this._offlineEventListener=()=>{this._onClose("transport close",{description:"network connection lost"})},Zf.push(this._offlineEventListener))),this.opts.withCredentials&&(this._cookieJar=void 0),this._open()}createTransport(e){const t=Object.assign({},this.opts.query);t.EIO=4,t.transport=e,this.id&&(t.sid=this.id);const n=Object.assign({},this.opts,{query:t,socket:this,hostname:this.hostname,secure:this.secure,port:this.port},this.opts.transportOptions[e]);return new this._transportsByName[e](n)}_open(){if(0===this.transports.length)return void this.setTimeoutFn(()=>{this.emitReserved("error","No transports available")},0);const e=this.opts.rememberUpgrade&&Xf.priorWebsocketSuccess&&-1!==this.transports.indexOf("websocket")?"websocket":this.transports[0];this.readyState="opening";const t=this.createTransport(e);t.open(),this.setTransport(t)}setTransport(e){this.transport&&this.transport.removeAllListeners(),this.transport=e,e.on("drain",this._onDrain.bind(this)).on("packet",this._onPacket.bind(this)).on("error",this._onError.bind(this)).on("close",e=>this._onClose("transport close",e))}onOpen(){this.readyState="open",Xf.priorWebsocketSuccess="websocket"===this.transport.name,this.emitReserved("open"),this.flush()}_onPacket(e){if("opening"===this.readyState||"open"===this.readyState||"closing"===this.readyState)switch(this.emitReserved("packet",e),this.emitReserved("heartbeat"),e.type){case"open":this.onHandshake(JSON.parse(e.data));break;case"ping":this._sendPacket("pong"),this.emitReserved("ping"),this.emitReserved("pong"),this._resetPingTimeout();break;case"error":const t=new Error("server error");t.code=e.data,this._onError(t);break;case"message":this.emitReserved("data",e.data),this.emitReserved("message",e.data)}}onHandshake(e){this.emitReserved("handshake",e),this.id=e.sid,this.transport.query.sid=e.sid,this._pingInterval=e.pingInterval,this._pingTimeout=e.pingTimeout,this._maxPayload=e.maxPayload,this.onOpen(),"closed"!==this.readyState&&this._resetPingTimeout()}_resetPingTimeout(){this.clearTimeoutFn(this._pingTimeoutTimer);const e=this._pingInterval+this._pingTimeout;this._pingTimeoutTime=Date.now()+e,this._pingTimeoutTimer=this.setTimeoutFn(()=>{this._onClose("ping timeout")},e),this.opts.autoUnref&&this._pingTimeoutTimer.unref()}_onDrain(){this.writeBuffer.splice(0,this._prevBufferLen),this._prevBufferLen=0,0===this.writeBuffer.length?this.emitReserved("drain"):this.flush()}flush(){if("closed"!==this.readyState&&this.transport.writable&&!this.upgrading&&this.writeBuffer.length){const e=this._getWritablePackets();this.transport.send(e),this._prevBufferLen=e.length,this.emitReserved("flush")}}_getWritablePackets(){if(!(this._maxPayload&&"polling"===this.transport.name&&this.writeBuffer.length>1))return this.writeBuffer;let e=1;for(let t=0;t<this.writeBuffer.length;t++){const n=this.writeBuffer[t].data;if(n&&(e+=Rf(n)),t>0&&e>this._maxPayload)return this.writeBuffer.slice(0,t);e+=2}return this.writeBuffer}_hasPingExpired(){if(!this._pingTimeoutTime)return!0;const e=Date.now()>this._pingTimeoutTime;return e&&(this._pingTimeoutTime=0,_f(()=>{this._onClose("ping timeout")},this.setTimeoutFn)),e}write(e,t,n){return this._sendPacket("message",e,t,n),this}send(e,t,n){return this._sendPacket("message",e,t,n),this}_sendPacket(e,t,n,r){if("function"==typeof t&&(r=t,t=void 0),"function"==typeof n&&(r=n,n=null),"closing"===this.readyState||"closed"===this.readyState)return;(n=n||{}).compress=!1!==n.compress;const i={type:e,data:t,options:n};this.emitReserved("packetCreate",i),this.writeBuffer.push(i),r&&this.once("flush",r),this.flush()}close(){const e=()=>{this._onClose("forced close"),this.transport.close()},t=()=>{this.off("upgrade",t),this.off("upgradeError",t),e()},n=()=>{this.once("upgrade",t),this.once("upgradeError",t)};return"opening"!==this.readyState&&"open"!==this.readyState||(this.readyState="closing",this.writeBuffer.length?this.once("drain",()=>{this.upgrading?n():e()}):this.upgrading?n():e()),this}_onError(e){if(Xf.priorWebsocketSuccess=!1,this.opts.tryAllTransports&&this.transports.length>1&&"opening"===this.readyState)return this.transports.shift(),this._open();this.emitReserved("error",e),this._onClose("transport error",e)}_onClose(e,t){if("opening"===this.readyState||"open"===this.readyState||"closing"===this.readyState){if(this.clearTimeoutFn(this._pingTimeoutTimer),this.transport.removeAllListeners("close"),this.transport.close(),this.transport.removeAllListeners(),Gf&&(this._beforeunloadEventListener&&removeEventListener("beforeunload",this._beforeunloadEventListener,!1),this._offlineEventListener)){const e=Zf.indexOf(this._offlineEventListener);-1!==e&&Zf.splice(e,1)}this.readyState="closed",this.id=null,this.emitReserved("close",e,t),this.writeBuffer=[],this._prevBufferLen=0}}}Xf.protocol=4;class Jf extends Xf{constructor(){super(...arguments),this._upgrades=[]}onOpen(){if(super.onOpen(),"open"===this.readyState&&this.opts.upgrade)for(let e=0;e<this._upgrades.length;e++)this._probe(this._upgrades[e])}_probe(e){let t=this.createTransport(e),n=!1;Xf.priorWebsocketSuccess=!1;const r=()=>{n||(t.send([{type:"ping",data:"probe"}]),t.once("packet",e=>{if(!n)if("pong"===e.type&&"probe"===e.data){if(this.upgrading=!0,this.emitReserved("upgrading",t),!t)return;Xf.priorWebsocketSuccess="websocket"===t.name,this.transport.pause(()=>{n||"closed"!==this.readyState&&(u(),this.setTransport(t),t.send([{type:"upgrade"}]),this.emitReserved("upgrade",t),t=null,this.upgrading=!1,this.flush())})}else{const e=new Error("probe error");e.transport=t.name,this.emitReserved("upgradeError",e)}}))};function i(){n||(n=!0,u(),t.close(),t=null)}const a=e=>{const n=new Error("probe error: "+e);n.transport=t.name,i(),this.emitReserved("upgradeError",n)};function o(){a("transport closed")}function s(){a("socket closed")}function l(e){t&&e.name!==t.name&&i()}const u=()=>{t.removeListener("open",r),t.removeListener("error",a),t.removeListener("close",o),this.off("close",s),this.off("upgrading",l)};t.once("open",r),t.once("error",a),t.once("close",o),this.once("close",s),this.once("upgrading",l),-1!==this._upgrades.indexOf("webtransport")&&"webtransport"!==e?this.setTimeoutFn(()=>{n||t.open()},200):t.open()}onHandshake(e){this._upgrades=this._filterUpgrades(e.upgrades),super.onHandshake(e)}_filterUpgrades(e){const t=[];for(let n=0;n<e.length;n++)~this.transports.indexOf(e[n])&&t.push(e[n]);return t}}let Yf=class extends Jf{constructor(e,t={}){const n="object"==typeof e?e:t;(!n.transports||n.transports&&"string"==typeof n.transports[0])&&(n.transports=(n.transports||["polling","websocket","webtransport"]).map(e=>Uf[e]).filter(e=>!!e)),super(e,n)}};const ed="function"==typeof ArrayBuffer,td=Object.prototype.toString,nd="function"==typeof Blob||"undefined"!=typeof Blob&&"[object BlobConstructor]"===td.call(Blob),rd="function"==typeof File||"undefined"!=typeof File&&"[object FileConstructor]"===td.call(File);function id(e){return ed&&(e instanceof ArrayBuffer||(e=>"function"==typeof ArrayBuffer.isView?ArrayBuffer.isView(e):e.buffer instanceof ArrayBuffer)(e))||nd&&e instanceof Blob||rd&&e instanceof File}function ad(e,t){if(!e||"object"!=typeof e)return!1;if(Array.isArray(e)){for(let t=0,n=e.length;t<n;t++)if(ad(e[t]))return!0;return!1}if(id(e))return!0;if(e.toJSON&&"function"==typeof e.toJSON&&1===arguments.length)return ad(e.toJSON(),!0);for(const n in e)if(Object.prototype.hasOwnProperty.call(e,n)&&ad(e[n]))return!0;return!1}function od(e){const t=[],n=e.data,r=e;return r.data=sd(n,t),r.attachments=t.length,{packet:r,buffers:t}}function sd(e,t){if(!e)return e;if(id(e)){const n={_placeholder:!0,num:t.length};return t.push(e),n}if(Array.isArray(e)){const n=new Array(e.length);for(let r=0;r<e.length;r++)n[r]=sd(e[r],t);return n}if("object"==typeof e&&!(e instanceof Date)){const n={};for(const r in e)Object.prototype.hasOwnProperty.call(e,r)&&(n[r]=sd(e[r],t));return n}return e}function ld(e,t){return e.data=ud(e.data,t),delete e.attachments,e}function ud(e,t){if(!e)return e;if(e&&!0===e._placeholder){if("number"==typeof e.num&&e.num>=0&&e.num<t.length)return t[e.num];throw new Error("illegal attachments")}if(Array.isArray(e))for(let n=0;n<e.length;n++)e[n]=ud(e[n],t);else if("object"==typeof e)for(const n in e)Object.prototype.hasOwnProperty.call(e,n)&&(e[n]=ud(e[n],t));return e}const cd=["connect","connect_error","disconnect","disconnecting","newListener","removeListener"];var fd,dd;(dd=fd||(fd={}))[dd.CONNECT=0]="CONNECT",dd[dd.DISCONNECT=1]="DISCONNECT",dd[dd.EVENT=2]="EVENT",dd[dd.ACK=3]="ACK",dd[dd.CONNECT_ERROR=4]="CONNECT_ERROR",dd[dd.BINARY_EVENT=5]="BINARY_EVENT",dd[dd.BINARY_ACK=6]="BINARY_ACK";function hd(e){return"[object Object]"===Object.prototype.toString.call(e)}class pd extends xf{constructor(e){super(),this.reviver=e}add(e){let t;if("string"==typeof e){if(this.reconstructor)throw new Error("got plaintext data when reconstructing a packet");t=this.decodeString(e);const n=t.type===fd.BINARY_EVENT;n||t.type===fd.BINARY_ACK?(t.type=n?fd.EVENT:fd.ACK,this.reconstructor=new vd(t),0===t.attachments&&super.emitReserved("decoded",t)):super.emitReserved("decoded",t)}else{if(!id(e)&&!e.base64)throw new Error("Unknown type: "+e);if(!this.reconstructor)throw new Error("got binary data when not reconstructing a packet");t=this.reconstructor.takeBinaryData(e),t&&(this.reconstructor=null,super.emitReserved("decoded",t))}}decodeString(e){let t=0;const n={type:Number(e.charAt(0))};if(void 0===fd[n.type])throw new Error("unknown packet type "+n.type);if(n.type===fd.BINARY_EVENT||n.type===fd.BINARY_ACK){const r=t+1;for(;"-"!==e.charAt(++t)&&t!=e.length;);const i=e.substring(r,t);if(i!=Number(i)||"-"!==e.charAt(t))throw new Error("Illegal attachments");n.attachments=Number(i)}if("/"===e.charAt(t+1)){const r=t+1;for(;++t;){if(","===e.charAt(t))break;if(t===e.length)break}n.nsp=e.substring(r,t)}else n.nsp="/";const r=e.charAt(t+1);if(""!==r&&Number(r)==r){const r=t+1;for(;++t;){const n=e.charAt(t);if(null==n||Number(n)!=n){--t;break}if(t===e.length)break}n.id=Number(e.substring(r,t+1))}if(e.charAt(++t)){const r=this.tryParse(e.substr(t));if(!pd.isPayloadValid(n.type,r))throw new Error("invalid payload");n.data=r}return n}tryParse(e){try{return JSON.parse(e,this.reviver)}catch(t){return!1}}static isPayloadValid(e,t){switch(e){case fd.CONNECT:return hd(t);case fd.DISCONNECT:return void 0===t;case fd.CONNECT_ERROR:return"string"==typeof t||hd(t);case fd.EVENT:case fd.BINARY_EVENT:return Array.isArray(t)&&("number"==typeof t[0]||"string"==typeof t[0]&&-1===cd.indexOf(t[0]));case fd.ACK:case fd.BINARY_ACK:return Array.isArray(t)}}destroy(){this.reconstructor&&(this.reconstructor.finishedReconstruction(),this.reconstructor=null)}}class vd{constructor(e){this.packet=e,this.buffers=[],this.reconPack=e}takeBinaryData(e){if(this.buffers.push(e),this.buffers.length===this.reconPack.attachments){const e=ld(this.reconPack,this.buffers);return this.finishedReconstruction(),e}return null}finishedReconstruction(){this.reconPack=null,this.buffers=[]}}const md=Object.freeze(Object.defineProperty({__proto__:null,Decoder:pd,Encoder:class{constructor(e){this.replacer=e}encode(e){return e.type!==fd.EVENT&&e.type!==fd.ACK||!ad(e)?[this.encodeAsString(e)]:this.encodeAsBinary({type:e.type===fd.EVENT?fd.BINARY_EVENT:fd.BINARY_ACK,nsp:e.nsp,data:e.data,id:e.id})}encodeAsString(e){let t=""+e.type;return e.type!==fd.BINARY_EVENT&&e.type!==fd.BINARY_ACK||(t+=e.attachments+"-"),e.nsp&&"/"!==e.nsp&&(t+=e.nsp+","),null!=e.id&&(t+=e.id),null!=e.data&&(t+=JSON.stringify(e.data,this.replacer)),t}encodeAsBinary(e){const t=od(e),n=this.encodeAsString(t.packet),r=t.buffers;return r.unshift(n),r}},get PacketType(){return fd},protocol:5},Symbol.toStringTag,{value:"Module"}));function gd(e,t,n){return e.on(t,n),function(){e.off(t,n)}}const bd=Object.freeze({connect:1,connect_error:1,disconnect:1,disconnecting:1,newListener:1,removeListener:1});class yd extends xf{constructor(e,t,n){super(),this.connected=!1,this.recovered=!1,this.receiveBuffer=[],this.sendBuffer=[],this._queue=[],this._queueSeq=0,this.ids=0,this.acks={},this.flags={},this.io=e,this.nsp=t,n&&n.auth&&(this.auth=n.auth),this._opts=Object.assign({},n),this.io._autoConnect&&this.open()}get disconnected(){return!this.connected}subEvents(){if(this.subs)return;const e=this.io;this.subs=[gd(e,"open",this.onopen.bind(this)),gd(e,"packet",this.onpacket.bind(this)),gd(e,"error",this.onerror.bind(this)),gd(e,"close",this.onclose.bind(this))]}get active(){return!!this.subs}connect(){return this.connected||(this.subEvents(),this.io._reconnecting||this.io.open(),"open"===this.io._readyState&&this.onopen()),this}open(){return this.connect()}send(...e){return e.unshift("message"),this.emit.apply(this,e),this}emit(e,...t){var n,r,i;if(bd.hasOwnProperty(e))throw new Error('"'+e.toString()+'" is a reserved event name');if(t.unshift(e),this._opts.retries&&!this.flags.fromQueue&&!this.flags.volatile)return this._addToQueue(t),this;const a={type:fd.EVENT,data:t,options:{}};if(a.options.compress=!1!==this.flags.compress,"function"==typeof t[t.length-1]){const e=this.ids++,n=t.pop();this._registerAckCallback(e,n),a.id=e}const o=null===(r=null===(n=this.io.engine)||void 0===n?void 0:n.transport)||void 0===r?void 0:r.writable,s=this.connected&&!(null===(i=this.io.engine)||void 0===i?void 0:i._hasPingExpired());return this.flags.volatile&&!o||(s?(this.notifyOutgoingListeners(a),this.packet(a)):this.sendBuffer.push(a)),this.flags={},this}_registerAckCallback(e,t){var n;const r=null!==(n=this.flags.timeout)&&void 0!==n?n:this._opts.ackTimeout;if(void 0===r)return void(this.acks[e]=t);const i=this.io.setTimeoutFn(()=>{delete this.acks[e];for(let t=0;t<this.sendBuffer.length;t++)this.sendBuffer[t].id===e&&this.sendBuffer.splice(t,1);t.call(this,new Error("operation has timed out"))},r),a=(...e)=>{this.io.clearTimeoutFn(i),t.apply(this,e)};a.withError=!0,this.acks[e]=a}emitWithAck(e,...t){return new Promise((n,r)=>{const i=(e,t)=>e?r(e):n(t);i.withError=!0,t.push(i),this.emit(e,...t)})}_addToQueue(e){let t;"function"==typeof e[e.length-1]&&(t=e.pop());const n={id:this._queueSeq++,tryCount:0,pending:!1,args:e,flags:Object.assign({fromQueue:!0},this.flags)};e.push((e,...r)=>{if(n!==this._queue[0])return;return null!==e?n.tryCount>this._opts.retries&&(this._queue.shift(),t&&t(e)):(this._queue.shift(),t&&t(null,...r)),n.pending=!1,this._drainQueue()}),this._queue.push(n),this._drainQueue()}_drainQueue(e=!1){if(!this.connected||0===this._queue.length)return;const t=this._queue[0];t.pending&&!e||(t.pending=!0,t.tryCount++,this.flags=t.flags,this.emit.apply(this,t.args))}packet(e){e.nsp=this.nsp,this.io._packet(e)}onopen(){"function"==typeof this.auth?this.auth(e=>{this._sendConnectPacket(e)}):this._sendConnectPacket(this.auth)}_sendConnectPacket(e){this.packet({type:fd.CONNECT,data:this._pid?Object.assign({pid:this._pid,offset:this._lastOffset},e):e})}onerror(e){this.connected||this.emitReserved("connect_error",e)}onclose(e,t){this.connected=!1,delete this.id,this.emitReserved("disconnect",e,t),this._clearAcks()}_clearAcks(){Object.keys(this.acks).forEach(e=>{if(!this.sendBuffer.some(t=>String(t.id)===e)){const t=this.acks[e];delete this.acks[e],t.withError&&t.call(this,new Error("socket has been disconnected"))}})}onpacket(e){if(e.nsp===this.nsp)switch(e.type){case fd.CONNECT:e.data&&e.data.sid?this.onconnect(e.data.sid,e.data.pid):this.emitReserved("connect_error",new 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 fd.EVENT:case fd.BINARY_EVENT:this.onevent(e);break;case fd.ACK:case fd.BINARY_ACK:this.onack(e);break;case fd.DISCONNECT:this.ondisconnect();break;case fd.CONNECT_ERROR:this.destroy();const t=new Error(e.data.message);t.data=e.data.data,this.emitReserved("connect_error",t)}}onevent(e){const t=e.data||[];null!=e.id&&t.push(this.ack(e.id)),this.connected?this.emitEvent(t):this.receiveBuffer.push(Object.freeze(t))}emitEvent(e){if(this._anyListeners&&this._anyListeners.length){const t=this._anyListeners.slice();for(const n of t)n.apply(this,e)}super.emit.apply(this,e),this._pid&&e.length&&"string"==typeof e[e.length-1]&&(this._lastOffset=e[e.length-1])}ack(e){const t=this;let n=!1;return function(...r){n||(n=!0,t.packet({type:fd.ACK,id:e,data:r}))}}onack(e){const t=this.acks[e.id];"function"==typeof t&&(delete this.acks[e.id],t.withError&&e.data.unshift(null),t.apply(this,e.data))}onconnect(e,t){this.id=e,this.recovered=t&&this._pid===t,this._pid=t,this.connected=!0,this.emitBuffered(),this.emitReserved("connect"),this._drainQueue(!0)}emitBuffered(){this.receiveBuffer.forEach(e=>this.emitEvent(e)),this.receiveBuffer=[],this.sendBuffer.forEach(e=>{this.notifyOutgoingListeners(e),this.packet(e)}),this.sendBuffer=[]}ondisconnect(){this.destroy(),this.onclose("io server disconnect")}destroy(){this.subs&&(this.subs.forEach(e=>e()),this.subs=void 0),this.io._destroy(this)}disconnect(){return this.connected&&this.packet({type:fd.DISCONNECT}),this.destroy(),this.connected&&this.onclose("io client disconnect"),this}close(){return this.disconnect()}compress(e){return this.flags.compress=e,this}get volatile(){return this.flags.volatile=!0,this}timeout(e){return this.flags.timeout=e,this}onAny(e){return this._anyListeners=this._anyListeners||[],this._anyListeners.push(e),this}prependAny(e){return this._anyListeners=this._anyListeners||[],this._anyListeners.unshift(e),this}offAny(e){if(!this._anyListeners)return this;if(e){const t=this._anyListeners;for(let n=0;n<t.length;n++)if(e===t[n])return t.splice(n,1),this}else this._anyListeners=[];return this}listenersAny(){return this._anyListeners||[]}onAnyOutgoing(e){return this._anyOutgoingListeners=this._anyOutgoingListeners||[],this._anyOutgoingListeners.push(e),this}prependAnyOutgoing(e){return this._anyOutgoingListeners=this._anyOutgoingListeners||[],this._anyOutgoingListeners.unshift(e),this}offAnyOutgoing(e){if(!this._anyOutgoingListeners)return this;if(e){const t=this._anyOutgoingListeners;for(let n=0;n<t.length;n++)if(e===t[n])return t.splice(n,1),this}else this._anyOutgoingListeners=[];return this}listenersAnyOutgoing(){return this._anyOutgoingListeners||[]}notifyOutgoingListeners(e){if(this._anyOutgoingListeners&&this._anyOutgoingListeners.length){const t=this._anyOutgoingListeners.slice();for(const n of t)n.apply(this,e.data)}}}function wd(e){e=e||{},this.ms=e.min||100,this.max=e.max||1e4,this.factor=e.factor||2,this.jitter=e.jitter>0&&e.jitter<=1?e.jitter:0,this.attempts=0}wd.prototype.duration=function(){var e=this.ms*Math.pow(this.factor,this.attempts++);if(this.jitter){var t=Math.random(),n=Math.floor(t*this.jitter*e);e=1&Math.floor(10*t)?e+n:e-n}return 0|Math.min(e,this.max)},wd.prototype.reset=function(){this.attempts=0},wd.prototype.setMin=function(e){this.ms=e},wd.prototype.setMax=function(e){this.max=e},wd.prototype.setJitter=function(e){this.jitter=e};class kd extends xf{constructor(e,t){var n;super(),this.nsps={},this.subs=[],e&&"object"==typeof e&&(t=e,e=void 0),(t=t||{}).path=t.path||"/socket.io",this.opts=t,Af(this,t),this.reconnection(!1!==t.reconnection),this.reconnectionAttempts(t.reconnectionAttempts||1/0),this.reconnectionDelay(t.reconnectionDelay||1e3),this.reconnectionDelayMax(t.reconnectionDelayMax||5e3),this.randomizationFactor(null!==(n=t.randomizationFactor)&&void 0!==n?n:.5),this.backoff=new wd({min:this.reconnectionDelay(),max:this.reconnectionDelayMax(),jitter:this.randomizationFactor()}),this.timeout(null==t.timeout?2e4:t.timeout),this._readyState="closed",this.uri=e;const r=t.parser||md;this.encoder=new r.Encoder,this.decoder=new r.Decoder,this._autoConnect=!1!==t.autoConnect,this._autoConnect&&this.open()}reconnection(e){return arguments.length?(this._reconnection=!!e,e||(this.skipReconnect=!0),this):this._reconnection}reconnectionAttempts(e){return void 0===e?this._reconnectionAttempts:(this._reconnectionAttempts=e,this)}reconnectionDelay(e){var t;return void 0===e?this._reconnectionDelay:(this._reconnectionDelay=e,null===(t=this.backoff)||void 0===t||t.setMin(e),this)}randomizationFactor(e){var t;return void 0===e?this._randomizationFactor:(this._randomizationFactor=e,null===(t=this.backoff)||void 0===t||t.setJitter(e),this)}reconnectionDelayMax(e){var t;return void 0===e?this._reconnectionDelayMax:(this._reconnectionDelayMax=e,null===(t=this.backoff)||void 0===t||t.setMax(e),this)}timeout(e){return arguments.length?(this._timeout=e,this):this._timeout}maybeReconnectOnOpen(){!this._reconnecting&&this._reconnection&&0===this.backoff.attempts&&this.reconnect()}open(e){if(~this._readyState.indexOf("open"))return this;this.engine=new Yf(this.uri,this.opts);const t=this.engine,n=this;this._readyState="opening",this.skipReconnect=!1;const r=gd(t,"open",function(){n.onopen(),e&&e()}),i=t=>{this.cleanup(),this._readyState="closed",this.emitReserved("error",t),e?e(t):this.maybeReconnectOnOpen()},a=gd(t,"error",i);if(!1!==this._timeout){const e=this._timeout,n=this.setTimeoutFn(()=>{r(),i(new Error("timeout")),t.close()},e);this.opts.autoUnref&&n.unref(),this.subs.push(()=>{this.clearTimeoutFn(n)})}return this.subs.push(r),this.subs.push(a),this}connect(e){return this.open(e)}onopen(){this.cleanup(),this._readyState="open",this.emitReserved("open");const e=this.engine;this.subs.push(gd(e,"ping",this.onping.bind(this)),gd(e,"data",this.ondata.bind(this)),gd(e,"error",this.onerror.bind(this)),gd(e,"close",this.onclose.bind(this)),gd(this.decoder,"decoded",this.ondecoded.bind(this)))}onping(){this.emitReserved("ping")}ondata(e){try{this.decoder.add(e)}catch(t){this.onclose("parse error",t)}}ondecoded(e){_f(()=>{this.emitReserved("packet",e)},this.setTimeoutFn)}onerror(e){this.emitReserved("error",e)}socket(e,t){let n=this.nsps[e];return n?this._autoConnect&&!n.active&&n.connect():(n=new yd(this,e,t),this.nsps[e]=n),n}_destroy(e){const t=Object.keys(this.nsps);for(const n of t){if(this.nsps[n].active)return}this._close()}_packet(e){const t=this.encoder.encode(e);for(let n=0;n<t.length;n++)this.engine.write(t[n],e.options)}cleanup(){this.subs.forEach(e=>e()),this.subs.length=0,this.decoder.destroy()}_close(){this.skipReconnect=!0,this._reconnecting=!1,this.onclose("forced close")}disconnect(){return this._close()}onclose(e,t){var n;this.cleanup(),null===(n=this.engine)||void 0===n||n.close(),this.backoff.reset(),this._readyState="closed",this.emitReserved("close",e,t),this._reconnection&&!this.skipReconnect&&this.reconnect()}reconnect(){if(this._reconnecting||this.skipReconnect)return this;const e=this;if(this.backoff.attempts>=this._reconnectionAttempts)this.backoff.reset(),this.emitReserved("reconnect_failed"),this._reconnecting=!1;else{const t=this.backoff.duration();this._reconnecting=!0;const n=this.setTimeoutFn(()=>{e.skipReconnect||(this.emitReserved("reconnect_attempt",e.backoff.attempts),e.skipReconnect||e.open(t=>{t?(e._reconnecting=!1,e.reconnect(),this.emitReserved("reconnect_error",t)):e.onreconnect()}))},t);this.opts.autoUnref&&n.unref(),this.subs.push(()=>{this.clearTimeoutFn(n)})}}onreconnect(){const e=this.backoff.attempts;this._reconnecting=!1,this.backoff.reset(),this.emitReserved("reconnect",e)}}const xd={};function _d(e,t){"object"==typeof e&&(t=e,e=void 0);const n=function(e,t="",n){let r=e;n=n||"undefined"!=typeof location&&location,null==e&&(e=n.protocol+"//"+n.host),"string"==typeof e&&("/"===e.charAt(0)&&(e="/"===e.charAt(1)?n.protocol+e:n.host+e),/^(https?|wss?):\/\//.test(e)||(e=void 0!==n?n.protocol+"//"+e:"https://"+e),r=Kf(e)),r.port||(/^(http|ws)$/.test(r.protocol)?r.port="80":/^(http|ws)s$/.test(r.protocol)&&(r.port="443")),r.path=r.path||"/";const i=-1!==r.host.indexOf(":")?"["+r.host+"]":r.host;return r.id=r.protocol+"://"+i+":"+r.port+t,r.href=r.protocol+"://"+i+(n&&n.port===r.port?"":":"+r.port),r}(e,(t=t||{}).path||"/socket.io"),r=n.source,i=n.id,a=n.path,o=xd[i]&&a in xd[i].nsps;let s;return t.forceNew||t["force new connection"]||!1===t.multiplex||o?s=new kd(r,t):(xd[i]||(xd[i]=new kd(r,t)),s=xd[i]),n.query&&!t.query&&(t.query=n.queryKey),s.socket(n.path,t)}Object.assign(_d,{Manager:kd,Socket:yd,io:_d,connect:_d});class Sd extends Gc.EventEmitter{constructor(){super(...arguments),this.q=null,this.B=null}connect(e,t){try{if(!this.B){if(this.B=e.server,!e.ac)return;this.q=_d(this.B,{transports:["websocket"],timeout:1e4,extraHeaders:{"X-Extension-Id":rr()||""},auth:{endpoint:t,ac:e.ac}}),this.q?.on(Jn,()=>{this.emit(Jn)}),this.q?.on(er,()=>this.emit(er)),this.q?.on(Yn,e=>this.emit(Yn,e)),this.q?.onAny((e,t)=>{this.emit(e,t)})}}catch(n){}}send(e,t){this.q?.emit(e,t)}disconnect(){this.q?.disconnect(),this.q=null,this.B=null}}const Cd=new Sd;Jc.startListening({matcher:lu.endpoints.getData.matchFulfilled,effect:async(e,t)=>{try{const t=e.payload,n=Td.getState().api.endpoint;t.server&&n&&(Cd.disconnect(),Cd.connect(t,n))}catch(n){}}}),Jc.startListening({matcher:lu.endpoints.getData.matchPending,effect:async(e,t)=>{}}),Jc.startListening({matcher:lu.endpoints.getData.matchRejected,effect:async(e,t)=>{t.dispatch(_r(0)),t.dispatch(dr(!1))}}),Jc.startListening({actionCreator:fu,effect:e=>{const t=Td.getState(),n=t.ui,r=t.api;r.isAccount?.balance&&(n.run&&n.isTp&&r.isAccount.balance>=n.tp&&(Td.dispatch(vr({type:"success",text:is(n.localCode||"en","tp_success")})),Td.dispatch(dr(!1))),n.run&&n.isSl&&r.isAccount.balance<=n.sl&&(Td.dispatch(vr({type:"success",text:is(n.localCode||"en","sl_success")})),Td.dispatch(dr(!1))))}}),Jc.startListening({actionCreator:hu,effect:e=>{const t=Td.getState();t.api?.endpoint&&Cd.send(t.api.endpoint.concat("/asset"),e.payload)}}),Jc.startListening({actionCreator:cu,effect:e=>{Td.getState().api.asset?Td.dispatch(yr(!1)):(Td.dispatch(dr(!1)),Td.dispatch(yr(!0)))}}),Jc.startListening({actionCreator:pu,effect:async e=>{Td.getState(),Td.dispatch(br(!1)),Xc.j("31",e.payload.url)}}),Jc.startListening({actionCreator:Hc,effect:(e,t)=>{const n=Td.getState();e.payload===Xn.ERROR&&t.dispatch(dr(!1)),e.payload===Xn.CONNECT&&n.api?.endpoint&&n.api.uid&&Cd.send(n.api.endpoint.concat("/asset"),n.api.uid)}}),Jc.startListening({actionCreator:Qc,effect:(e,t)=>{const n=Td.getState();n.ws.status===Xn.CONNECT&&n.api?.endpoint&&n.api.uid&&Cd.send(n.api.endpoint.concat("/candle"),e.payload)}}),Jc.startListening({actionCreator:Wc,effect:e=>{Yc.N(e.payload,e=>{Xc.j("26",e)})}}),Jc.startListening({actionCreator:oc,effect:e=>{}}),Jc.startListening({actionCreator:ac,effect:e=>{const t=Td.getState();t.ui,t.api;const n=t.order.orders.find(t=>t.id===e.payload.id);n&&"number"==typeof n.profit&&Td.dispatch(sc({stat_profit:n.profit>0?n.profit:0,stat_profit_count:n.profit>0?1:0,stat_loss:n.profit<0?n.profit:0,stat_loss_count:n.profit<0?1:0}))}});const Td=function(e){const t=function(e){const{thunk:t=!0,immutableCheck:n=!0,serializableCheck:r=!0,actionCreatorCheck:i=!0}=e??{};let a=new qt;return t&&("boolean"==typeof t?a.push(Ft):a.push(It(t.extraArgument))),a},{reducer:n,middleware:r,devTools:i=!0,preloadedState:a,enhancers:o}=e||{};let s,l;if("function"==typeof n)s=n;else{if(!ue(n))throw new Error(Zn(1));s=fe(n)}l="function"==typeof r?r(t):t();let u=de;i&&(u=Nt({trace:!1,..."object"==typeof i&&i}));const c=function(...e){return t=>(n,r)=>{const i=t(n,r);let a=()=>{throw new Error(ae(15))};const o={getState:i.getState,dispatch:(e,...t)=>a(e,...t)},s=e.map(e=>e(o));return a=de(...s)(i.dispatch),{...i,dispatch:a}}}(...l),f=Qt(c);return ce(s,a,u(..."function"==typeof o?o(f):f()))}({reducer:{ui:fr.reducer,ws:Bc.reducer,api:su.reducer,order:ic.reducer,[lu.reducerPath]:lu.reducer},devTools:!1,middleware:e=>e({serializableCheck:{ignoredPaths:["ui.alerts","dataApi.queries"],ignoredActionPaths:["payload.0.props.button.click","meta.baseQueryMeta"]}}).concat(lu.middleware).concat(Jc.middleware)});var Ed;Ed=Td.dispatch,Xc.on("1",e=>{Ed(cu(e))}),Xc.on("2",e=>{Ed(hu(e))}),Xc.on("4",e=>{Ed(cu({domain:e}))}),Xc.on("3.1",e=>{Ed(fu(e))}),Xc.on("16",e=>{Ed(pr(e))}),Xc.on("30",e=>{Ed(cu({assets:e}))}),Xc.on("27",e=>{Ed(oc(e))}),Xc.on("28",e=>{Ed(ac(e))}),Xc.on("17",e=>{Ed(Qc(e))}),function(e){Cd.on(Jn,()=>e(Hc(Xn.CONNECT))),Cd.on(er,()=>e(Hc(Xn.DISCONNECT))),Cd.on(Yn,t=>e(Hc(Xn.ERROR))),Cd.on("signals",t=>e(Wc(t))),Cd.on("signals/history",t=>e(Uc(t))),Cd.on("asset",t=>e(cu({asset:t})))}(Td.dispatch);const Ad=document.createElement("div");document.body.appendChild(Ad),j.createRoot(Ad).render(s.jsx(d.StrictMode,{children:s.jsx(K,{store:Td,children:s.jsx(bu,{children:s.jsx(os,{children:s.jsx(ts,{children:s.jsx(qc,{})})})})})}));
|