rqbit/crates/librqbit/webui/dist/assets/index.js

57 lines
212 KiB
JavaScript
Raw Normal View History

2024-04-07 13:42:58 +04:00
(function(){const t=document.createElement("link").relList;if(t&&t.supports&&t.supports("modulepreload"))return;for(const l of document.querySelectorAll('link[rel="modulepreload"]'))r(l);new MutationObserver(l=>{for(const i of l)if(i.type==="childList")for(const o of i.addedNodes)o.tagName==="LINK"&&o.rel==="modulepreload"&&r(o)}).observe(document,{childList:!0,subtree:!0});function n(l){const i={};return l.integrity&&(i.integrity=l.integrity),l.referrerPolicy&&(i.referrerPolicy=l.referrerPolicy),l.crossOrigin==="use-credentials"?i.credentials="include":l.crossOrigin==="anonymous"?i.credentials="omit":i.credentials="same-origin",i}function r(l){if(l.ep)return;l.ep=!0;const i=n(l);fetch(l.href,i)}})();var Ut=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};function il(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var _c={exports:{}},_i={},Tc={exports:{}},B={};/**
* @license React
* react.production.min.js
*
* Copyright (c) Facebook, Inc. and its affiliates.
*
* This source code is licensed under the MIT license found in the
* LICENSE file in the root directory of this source tree.
2024-04-07 13:42:58 +04:00
*/var ol=Symbol.for("react.element"),M1=Symbol.for("react.portal"),z1=Symbol.for("react.fragment"),F1=Symbol.for("react.strict_mode"),I1=Symbol.for("react.profiler"),D1=Symbol.for("react.provider"),R1=Symbol.for("react.context"),A1=Symbol.for("react.forward_ref"),$1=Symbol.for("react.suspense"),U1=Symbol.for("react.memo"),B1=Symbol.for("react.lazy"),ea=Symbol.iterator;function H1(e){return e===null||typeof e!="object"?null:(e=ea&&e[ea]||e["@@iterator"],typeof e=="function"?e:null)}var jc={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},Nc=Object.assign,Pc={};function sr(e,t,n){this.props=e,this.context=t,this.refs=Pc,this.updater=n||jc}sr.prototype.isReactComponent={};sr.prototype.setState=function(e,t){if(typeof e!="object"&&typeof e!="function"&&e!=null)throw Error("setState(...): takes an object of state variables to update or a function which returns an object of state variables.");this.updater.enqueueSetState(this,e,t,"setState")};sr.prototype.forceUpdate=function(e){this.updater.enqueueForceUpdate(this,e,"forceUpdate")};function Lc(){}Lc.prototype=sr.prototype;function Iu(e,t,n){this.props=e,this.context=t,this.refs=Pc,this.updater=n||jc}var Du=Iu.prototype=new Lc;Du.constructor=Iu;Nc(Du,sr.prototype);Du.isPureReactComponent=!0;var ta=Array.isArray,Oc=Object.prototype.hasOwnProperty,Ru={current:null},Mc={key:!0,ref:!0,__self:!0,__source:!0};function zc(e,t,n){var r,l={},i=null,o=null;if(t!=null)for(r in t.ref!==void 0&&(o=t.ref),t.key!==void 0&&(i=""+t.key),t)Oc.call(t,r)&&!Mc.hasOwnProperty(r)&&(l[r]=t[r]);var s=arguments.length-2;if(s===1)l.children=n;else if(1<s){for(var a=Array(s),f=0;f<s;f++)a[f]=arguments[f+2];l.children=a}if(e&&e.defaultProps)for(r in s=e.defaultProps,s)l[r]===void 0&&(l[r]=s[r]);return{$$typeof:ol,type:e,key:i,ref:o,props:l,_owner:Ru.current}}function V1(e,t){return{$$typeof:ol,type:e.type,key:t,ref:e.ref,props:e.props,_owner:e._owner}}function Au(e){return typeof e=="object"&&e!==null&&e.$$typeof===ol}function W1(e){var t={"=":"=0",":":"=2"};return"$"+e.replace(/[=:]/g,function(n){return t[n]})}var na=/\/+/g;function oo(e,t){return typeof e=="object"&&e!==null&&e.key!=null?W1(""+e.key):t.toString(36)}function Bl(e,t,n,r,l){var i=typeof e;(i==="undefined"||i==="boolean")&&(e=null);var o=!1;if(e===null)o=!0;else switch(i){case"string":case"number":o=!0;break;case"object":switch(e.$$typeof){case ol:case M1:o=!0}}if(o)return o=e,l=l(o),e=r===""?"."+oo(o,0):r,ta(l)?(n="",e!=null&&(n=e.replace(na,"$&/")+"/"),Bl(l,t,n,"",function(f){return f})):l!=null&&(Au(l)&&(l=V1(l,n+(!l.key||o&&o.key===l.key?"":(""+l.key).replace(na,"$&/")+"/")+e)),t.push(l)),1;if(o=0,r=r===""?".":r+":",ta(e))for(var s=0;s<e.length;s++){i=e[s];var a=r+oo(i,s);o+=Bl(i,t,n,a,l)}else if(a=H1(e),typeof a=="function")for(e=a.call(e),s=0;!(i=e.next()).done;)i=i.value,a=r+oo(i,s++),o+=Bl(i,t,n,a,l);else if(i==="object")throw t=String(e),Error("Objects are not valid as a React child (found: "+(t==="[object Object]"?"object with keys {"+Object.keys(e).join(", ")+"}":t)+"). If you meant to render a collection of children, use an array instead.");return o}function El(e,t,n){if(e==null)return e;var r=[],l=0;return Bl(e,r,"","",function(i){return t.call(n,i,l++)}),r}function Q1(e){if(e._status===-1){var t=e._result;t=t(),t.then(function(n){(e._status===0||e._status===-1)&&(e._status=1,e._result=n)},function(n){(e._status===0||e._status===-1)&&(e._status=2,e._result=n)}),e._status===-1&&(e._status=0,e._result=t)}if(e._status===1)return e._result.default;throw e._result}var Ce={current:null},Hl={transition:null},K1={ReactCurrentDispatcher:Ce,ReactCurrentBatchConfig:Hl,ReactCurrentOwner:Ru};B.Children={map:El,forEach:function(e,t,n){El(e,function(){t.apply(this,arguments)},n)},count:function(e){var t=0;return El(e,function(){t++}),t},toArray:function(e){return El(e,function(t){return t})||[]},only:function(e){if(!Au(e))throw Error("React.Children.only expected to receive a single React element child.");return e}};B.Component=sr;B.Fragment=z1;B.Profiler=I1;B.Pure
* @license React
* react-jsx-runtime.production.min.js
*
* Copyright (c) Facebook, Inc. and its affiliates.
*
* This source code is licensed under the MIT license found in the
* LICENSE file in the root directory of this source tree.
2024-04-07 13:42:58 +04:00
*/var Z1=C,G1=Symbol.for("react.element"),Y1=Symbol.for("react.fragment"),X1=Object.prototype.hasOwnProperty,J1=Z1.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner,q1={key:!0,ref:!0,__self:!0,__source:!0};function Fc(e,t,n){var r,l={},i=null,o=null;n!==void 0&&(i=""+n),t.key!==void 0&&(i=""+t.key),t.ref!==void 0&&(o=t.ref);for(r in t)X1.call(t,r)&&!q1.hasOwnProperty(r)&&(l[r]=t[r]);if(e&&e.defaultProps)for(r in t=e.defaultProps,t)l[r]===void 0&&(l[r]=t[r]);return{$$typeof:G1,type:e,key:i,ref:o,props:l,_owner:J1.current}}_i.Fragment=Y1;_i.jsx=Fc;_i.jsxs=Fc;_c.exports=_i;var d=_c.exports,$o={},Ic={exports:{}},De={},Dc={exports:{}},Rc={};/**
* @license React
* scheduler.production.min.js
*
* Copyright (c) Facebook, Inc. and its affiliates.
*
* This source code is licensed under the MIT license found in the
* LICENSE file in the root directory of this source tree.
2024-04-07 13:42:58 +04:00
*/(function(e){function t(P,R){var $=P.length;P.push(R);e:for(;0<$;){var K=$-1>>>1,ee=P[K];if(0<l(ee,R))P[K]=R,P[$]=ee,$=K;else break e}}function n(P){return P.length===0?null:P[0]}function r(P){if(P.length===0)return null;var R=P[0],$=P.pop();if($!==R){P[0]=$;e:for(var K=0,ee=P.length,Ge=ee>>>1;K<Ge;){var $e=2*(K+1)-1,pt=P[$e],Ye=$e+1,Ot=P[Ye];if(0>l(pt,$))Ye<ee&&0>l(Ot,pt)?(P[K]=Ot,P[Ye]=$,K=Ye):(P[K]=pt,P[$e]=$,K=$e);else if(Ye<ee&&0>l(Ot,$))P[K]=Ot,P[Ye]=$,K=Ye;else break e}}return R}function l(P,R){var $=P.sortIndex-R.sortIndex;return $!==0?$:P.id-R.id}if(typeof performance=="object"&&typeof performance.now=="function"){var i=performance;e.unstable_now=function(){return i.now()}}else{var o=Date,s=o.now();e.unstable_now=function(){return o.now()-s}}var a=[],f=[],y=1,x=null,v=3,w=!1,S=!1,k=!1,z=typeof setTimeout=="function"?setTimeout:null,h=typeof clearTimeout=="function"?clearTimeout:null,p=typeof setImmediate<"u"?setImmediate:null;typeof navigator<"u"&&navigator.scheduling!==void 0&&navigator.scheduling.isInputPending!==void 0&&navigator.scheduling.isInputPending.bind(navigator.scheduling);function m(P){for(var R=n(f);R!==null;){if(R.callback===null)r(f);else if(R.startTime<=P)r(f),R.sortIndex=R.expirationTime,t(a,R);else break;R=n(f)}}function _(P){if(k=!1,m(P),!S)if(n(a)!==null)S=!0,Ae(T);else{var R=n(f);R!==null&&rt(_,R.startTime-P)}}function T(P,R){S=!1,k&&(k=!1,h(F),F=-1),w=!0;var $=v;try{for(m(R),x=n(a);x!==null&&(!(x.expirationTime>R)||P&&!we());){var K=x.callback;if(typeof K=="function"){x.callback=null,v=x.priorityLevel;var ee=K(x.expirationTime<=R);R=e.unstable_now(),typeof ee=="function"?x.callback=ee:x===n(a)&&r(a),m(R)}else r(a);x=n(a)}if(x!==null)var Ge=!0;else{var $e=n(f);$e!==null&&rt(_,$e.startTime-R),Ge=!1}return Ge}finally{x=null,v=$,w=!1}}var j=!1,O=null,F=-1,W=5,A=-1;function we(){return!(e.unstable_now()-A<W)}function ft(){if(O!==null){var P=e.unstable_now();A=P;var R=!0;try{R=O(!0,P)}finally{R?dt():(j=!1,O=null)}}else j=!1}var dt;if(typeof p=="function")dt=function(){p(ft)};else if(typeof MessageChannel<"u"){var Tn=new MessageChannel,fr=Tn.port2;Tn.port1.onmessage=ft,dt=function(){fr.postMessage(null)}}else dt=function(){z(ft,0)};function Ae(P){O=P,j||(j=!0,dt())}function rt(P,R){F=z(function(){P(e.unstable_now())},R)}e.unstable_IdlePriority=5,e.unstable_ImmediatePriority=1,e.unstable_LowPriority=4,e.unstable_NormalPriority=3,e.unstable_Profiling=null,e.unstable_UserBlockingPriority=2,e.unstable_cancelCallback=function(P){P.callback=null},e.unstable_continueExecution=function(){S||w||(S=!0,Ae(T))},e.unstable_forceFrameRate=function(P){0>P||125<P?console.error("forceFrameRate takes a positive int between 0 and 125, forcing frame rates higher than 125 fps is not supported"):W=0<P?Math.floor(1e3/P):5},e.unstable_getCurrentPriorityLevel=function(){return v},e.unstable_getFirstCallbackNode=function(){return n(a)},e.unstable_next=function(P){switch(v){case 1:case 2:case 3:var R=3;break;default:R=v}var $=v;v=R;try{return P()}finally{v=$}},e.unstable_pauseExecution=function(){},e.unstable_requestPaint=function(){},e.unstable_runWithPriority=function(P,R){switch(P){case 1:case 2:case 3:case 4:case 5:break;default:P=3}var $=v;v=P;try{return R()}finally{v=$}},e.unstable_scheduleCallback=function(P,R,$){var K=e.unstable_now();switch(typeof $=="object"&&$!==null?($=$.delay,$=typeof $=="number"&&0<$?K+$:K):$=K,P){case 1:var ee=-1;break;case 2:ee=250;break;case 5:ee=1073741823;break;case 4:ee=1e4;break;default:ee=5e3}return ee=$+ee,P={id:y++,callback:R,priorityLevel:P,startTime:$,expirationTime:ee,sortIndex:-1},$>K?(P.sortIndex=$,t(f,P),n(a)===null&&P===n(f)&&(k?(h(F),F=-1):k=!0,rt(_,$-K))):(P.sortIndex=ee,t(a,P),S||w||(S=!0,Ae(T))),P},e.unstable_shouldYield=we,e.unstable_wrapCallback=function(P){var R=v;return function(){var $=v;v=R;try{return P.apply(this,arguments)}finally{v=$}}}})(Rc);Dc.exports=Rc;var b1=Dc.exports;/**
* @license React
* react-dom.production.min.js
*
* Copyright (c) Facebook, Inc. and its affiliates.
*
* This source code is licensed under the MIT license found in the
* LICENSE file in the root directory of this source tree.
2024-04-07 13:42:58 +04:00
*/var Ac=C,Ie=b1;function N(e){for(var t="https://reactjs.org/docs/error-decoder.html?invariant="+e,n=1;n<arguments.length;n++)t+="&args[]="+encodeURIComponent(arguments[n]);return"Minified React error #"+e+"; visit "+t+" for the full message or use the non-minified dev environment for full errors and additional helpful warnings."}var $c=new Set,Br={};function Cn(e,t){er(e,t),er(e+"Capture",t)}function er(e,t){for(Br[e]=t,e=0;e<t.length;e++)$c.add(t[e])}var _t=!(typeof window>"u"||typeof window.document>"u"||typeof window.document.createElement>"u"),Uo=Object.prototype.hasOwnProperty,ep=/^[:A-Z_a-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD][:A-Z_a-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD\-.0-9\u00B7\u0300-\u036F\u203F-\u2040]*$/,ra={},la={};function tp(e){return Uo.call(la,e)?!0:Uo.call(ra,e)?!1:ep.test(e)?la[e]=!0:(ra[e]=!0,!1)}function np(e,t,n,r){if(n!==null&&n.type===0)return!1;switch(typeof t){case"function":case"symbol":return!0;case"boolean":return r?!1:n!==null?!n.acceptsBooleans:(e=e.toLowerCase().slice(0,5),e!=="data-"&&e!=="aria-");default:return!1}}function rp(e,t,n,r){if(t===null||typeof t>"u"||np(e,t,n,r))return!0;if(r)return!1;if(n!==null)switch(n.type){case 3:return!t;case 4:return t===!1;case 5:return isNaN(t);case 6:return isNaN(t)||1>t}return!1}function _e(e,t,n,r,l,i,o){this.acceptsBooleans=t===2||t===3||t===4,this.attributeName=r,this.attributeNamespace=l,this.mustUseProperty=n,this.propertyName=e,this.type=t,this.sanitizeURL=i,this.removeEmptyString=o}var me={};"children dangerouslySetInnerHTML defaultValue defaultChecked innerHTML suppressContentEditableWarning suppressHydrationWarning style".split(" ").forEach(function(e){me[e]=new _e(e,0,!1,e,null,!1,!1)});[["acceptCharset","accept-charset"],["className","class"],["htmlFor","for"],["httpEquiv","http-equiv"]].forEach(function(e){var t=e[0];me[t]=new _e(t,1,!1,e[1],null,!1,!1)});["contentEditable","draggable","spellCheck","value"].forEach(function(e){me[e]=new _e(e,2,!1,e.toLowerCase(),null,!1,!1)});["autoReverse","externalResourcesRequired","focusable","preserveAlpha"].forEach(function(e){me[e]=new _e(e,2,!1,e,null,!1,!1)});"allowFullScreen async autoFocus autoPlay controls default defer disabled disablePictureInPicture disableRemotePlayback formNoValidate hidden loop noModule noValidate open playsInline readOnly required reversed scoped seamless itemScope".split(" ").forEach(function(e){me[e]=new _e(e,3,!1,e.toLowerCase(),null,!1,!1)});["checked","multiple","muted","selected"].forEach(function(e){me[e]=new _e(e,3,!0,e,null,!1,!1)});["capture","download"].forEach(function(e){me[e]=new _e(e,4,!1,e,null,!1,!1)});["cols","rows","size","span"].forEach(function(e){me[e]=new _e(e,6,!1,e,null,!1,!1)});["rowSpan","start"].forEach(function(e){me[e]=new _e(e,5,!1,e.toLowerCase(),null,!1,!1)});var $u=/[\-:]([a-z])/g;function Uu(e){return e[1].toUpperCase()}"accent-height alignment-baseline arabic-form baseline-shift cap-height clip-path clip-rule color-interpolation color-interpolation-filters color-profile color-rendering dominant-baseline enable-background fill-opacity fill-rule flood-color flood-opacity font-family font-size font-size-adjust font-stretch font-style font-variant font-weight glyph-name glyph-orientation-horizontal glyph-orientation-vertical horiz-adv-x horiz-origin-x image-rendering letter-spacing lighting-color marker-end marker-mid marker-start overline-position overline-thickness paint-order panose-1 pointer-events rendering-intent shape-rendering stop-color stop-opacity strikethrough-position strikethrough-thickness stroke-dasharray stroke-dashoffset stroke-linecap stroke-linejoin stroke-miterlimit stroke-opacity stroke-width text-anchor text-decoration text-rendering underline-position underline-thickness unicode-bidi unicode-range units-per-em v-alphabetic v-hanging v-ideographic v-mathematical vector-effect vert-adv-y vert-origin-
`+uo+e}var so=!1;function ao(e,t){if(!e||so)return"";so=!0;var n=Error.prepareStackTrace;Error.prepareStackTrace=void 0;try{if(t)if(t=function(){throw Error()},Object.defineProperty(t.prototype,"props",{set:function(){throw Error()}}),typeof Reflect=="object"&&Reflect.construct){try{Reflect.construct(t,[])}catch(f){var r=f}Reflect.construct(e,[],t)}else{try{t.call()}catch(f){r=f}e.call(t.prototype)}else{try{throw Error()}catch(f){r=f}e()}}catch(f){if(f&&r&&typeof f.stack=="string"){for(var l=f.stack.split(`
`),i=r.stack.split(`
`),o=l.length-1,s=i.length-1;1<=o&&0<=s&&l[o]!==i[s];)s--;for(;1<=o&&0<=s;o--,s--)if(l[o]!==i[s]){if(o!==1||s!==1)do if(o--,s--,0>s||l[o]!==i[s]){var a=`
2024-04-07 13:42:58 +04:00
`+l[o].replace(" at new "," at ");return e.displayName&&a.includes("<anonymous>")&&(a=a.replace("<anonymous>",e.displayName)),a}while(1<=o&&0<=s);break}}}finally{so=!1,Error.prepareStackTrace=n}return(e=e?e.displayName||e.name:"")?Nr(e):""}function lp(e){switch(e.tag){case 5:return Nr(e.type);case 16:return Nr("Lazy");case 13:return Nr("Suspense");case 19:return Nr("SuspenseList");case 0:case 2:case 15:return e=ao(e.type,!1),e;case 11:return e=ao(e.type.render,!1),e;case 1:return e=ao(e.type,!0),e;default:return""}}function Wo(e){if(e==null)return null;if(typeof e=="function")return e.displayName||e.name||null;if(typeof e=="string")return e;switch(e){case Dn:return"Fragment";case In:return"Portal";case Bo:return"Profiler";case Hu:return"StrictMode";case Ho:return"Suspense";case Vo:return"SuspenseList"}if(typeof e=="object")switch(e.$$typeof){case Bc:return(e.displayName||"Context")+".Consumer";case Uc:return(e._context.displayName||"Context")+".Provider";case Vu:var t=e.render;return e=e.displayName,e||(e=t.displayName||t.name||"",e=e!==""?"ForwardRef("+e+")":"ForwardRef"),e;case Wu:return t=e.displayName||null,t!==null?t:Wo(e.type)||"Memo";case Dt:t=e._payload,e=e._init;try{return Wo(e(t))}catch{}}return null}function ip(e){var t=e.type;switch(e.tag){case 24:return"Cache";case 9:return(t.displayName||"Context")+".Consumer";case 10:return(t._context.displayName||"Context")+".Provider";case 18:return"DehydratedFragment";case 11:return e=t.render,e=e.displayName||e.name||"",t.displayName||(e!==""?"ForwardRef("+e+")":"ForwardRef");case 7:return"Fragment";case 5:return t;case 4:return"Portal";case 3:return"Root";case 6:return"Text";case 16:return Wo(t);case 8:return t===Hu?"StrictMode":"Mode";case 22:return"Offscreen";case 12:return"Profiler";case 21:return"Scope";case 13:return"Suspense";case 19:return"SuspenseList";case 25:return"TracingMarker";case 1:case 0:case 17:case 2:case 14:case 15:if(typeof t=="function")return t.displayName||t.name||null;if(typeof t=="string")return t}return null}function qt(e){switch(typeof e){case"boolean":case"number":case"string":case"undefined":return e;case"object":return e;default:return""}}function Vc(e){var t=e.type;return(e=e.nodeName)&&e.toLowerCase()==="input"&&(t==="checkbox"||t==="radio")}function op(e){var t=Vc(e)?"checked":"value",n=Object.getOwnPropertyDescriptor(e.constructor.prototype,t),r=""+e[t];if(!e.hasOwnProperty(t)&&typeof n<"u"&&typeof n.get=="function"&&typeof n.set=="function"){var l=n.get,i=n.set;return Object.defineProperty(e,t,{configurable:!0,get:function(){return l.call(this)},set:function(o){r=""+o,i.call(this,o)}}),Object.defineProperty(e,t,{enumerable:n.enumerable}),{getValue:function(){return r},setValue:function(o){r=""+o},stopTracking:function(){e._valueTracker=null,delete e[t]}}}}function _l(e){e._valueTracker||(e._valueTracker=op(e))}function Wc(e){if(!e)return!1;var t=e._valueTracker;if(!t)return!0;var n=t.getValue(),r="";return e&&(r=Vc(e)?e.checked?"true":"false":e.value),e=r,e!==n?(t.setValue(e),!0):!1}function bl(e){if(e=e||(typeof document<"u"?document:void 0),typeof e>"u")return null;try{return e.activeElement||e.body}catch{return e.body}}function Qo(e,t){var n=t.checked;return re({},t,{defaultChecked:void 0,defaultValue:void 0,value:void 0,checked:n??e._wrapperState.initialChecked})}function oa(e,t){var n=t.defaultValue==null?"":t.defaultValue,r=t.checked!=null?t.checked:t.defaultChecked;n=qt(t.value!=null?t.value:n),e._wrapperState={initialChecked:r,initialValue:n,controlled:t.type==="checkbox"||t.type==="radio"?t.checked!=null:t.value!=null}}function Qc(e,t){t=t.checked,t!=null&&Bu(e,"checked",t,!1)}function Ko(e,t){Qc(e,t);var n=qt(t.value),r=t.type;if(n!=null)r==="number"?(n===0&&e.value===""||e.value!=n)&&(e.value=""+n):e.value!==""+n&&(e.value=""+n);else if(r==="submit"||r==="reset"){e.removeAttribute("value");return}t.hasOwnProperty("value")?Zo(e,t.type,n):t.hasOwnProperty("defaultValue")&&Zo(e,t.type,qt(t.defaultValue)),t.checked==null&&t.defaultChecked!=null&&(e.defaultChecked=!!t.defaultChecked)}function ua(e,t,n){if(t.hasOwnProperty("val
`).replace(gh,"")}function zl(e,t,n){if(t=La(t),La(e)!==t&&n)throw Error(N(425))}function ui(){}var uu=null,su=null;function au(e,t){return e==="textarea"||e==="noscript"||typeof t.children=="string"||typeof t.children=="number"||typeof t.dangerouslySetInnerHTML=="object"&&t.dangerouslySetInnerHTML!==null&&t.dangerouslySetInnerHTML.__html!=null}var cu=typeof setTimeout=="function"?setTimeout:void 0,vh=typeof clearTimeout=="function"?clearTimeout:void 0,Oa=typeof Promise=="function"?Promise:void 0,yh=typeof queueMicrotask=="function"?queueMicrotask:typeof Oa<"u"?function(e){return Oa.resolve(null).then(e).catch(xh)}:cu;function xh(e){setTimeout(function(){throw e})}function Eo(e,t){var n=t,r=0;do{var l=n.nextSibling;if(e.removeChild(n),l&&l.nodeType===8)if(n=l.data,n==="/$"){if(r===0){e.removeChild(l),Kr(t);return}r--}else n!=="$"&&n!=="$?"&&n!=="$!"||r++;n=l}while(n);Kr(t)}function Kt(e){for(;e!=null;e=e.nextSibling){var t=e.nodeType;if(t===1||t===3)break;if(t===8){if(t=e.data,t==="$"||t==="$!"||t==="$?")break;if(t==="/$")return null}}return e}function Ma(e){e=e.previousSibling;for(var t=0;e;){if(e.nodeType===8){var n=e.data;if(n==="$"||n==="$!"||n==="$?"){if(t===0)return e;t--}else n==="/$"&&t++}e=e.previousSibling}return null}var cr=Math.random().toString(36).slice(2),st="__reactFiber$"+cr,Jr="__reactProps$"+cr,Tt="__reactContainer$"+cr,fu="__reactEvents$"+cr,wh="__reactListeners$"+cr,Sh="__reactHandles$"+cr;function fn(e){var t=e[st];if(t)return t;for(var n=e.parentNode;n;){if(t=n[Tt]||n[st]){if(n=t.alternate,t.child!==null||n!==null&&n.child!==null)for(e=Ma(e);e!==null;){if(n=e[st])return n;e=Ma(e)}return t}e=n,n=e.parentNode}return null}function al(e){return e=e[st]||e[Tt],!e||e.tag!==5&&e.tag!==6&&e.tag!==13&&e.tag!==3?null:e}function Un(e){if(e.tag===5||e.tag===6)return e.stateNode;throw Error(N(33))}function Li(e){return e[Jr]||null}var du=[],Bn=-1;function nn(e){return{current:e}}function J(e){0>Bn||(e.current=du[Bn],du[Bn]=null,Bn--)}function Y(e,t){Bn++,du[Bn]=e.current,e.current=t}var bt={},xe=nn(bt),Pe=nn(!1),yn=bt;function tr(e,t){var n=e.type.contextTypes;if(!n)return bt;var r=e.stateNode;if(r&&r.__reactInternalMemoizedUnmaskedChildContext===t)return r.__reactInternalMemoizedMaskedChildContext;var l={},i;for(i in n)l[i]=t[i];return r&&(e=e.stateNode,e.__reactInternalMemoizedUnmaskedChildContext=t,e.__reactInternalMemoizedMaskedChildContext=l),l}function Le(e){return e=e.childContextTypes,e!=null}function si(){J(Pe),J(xe)}function za(e,t,n){if(xe.current!==bt)throw Error(N(168));Y(xe,t),Y(Pe,n)}function Ff(e,t,n){var r=e.stateNode;if(t=t.childContextTypes,typeof r.getChildContext!="function")return n;r=r.getChildContext();for(var l in r)if(!(l in t))throw Error(N(108,ip(e)||"Unknown",l));return re({},n,r)}function ai(e){return e=(e=e.stateNode)&&e.__reactInternalMemoizedMergedChildContext||bt,yn=xe.current,Y(xe,e),Y(Pe,Pe.current),!0}function Fa(e,t,n){var r=e.stateNode;if(!r)throw Error(N(169));n?(e=Ff(e,t,yn),r.__reactInternalMemoizedMergedChildContext=e,J(Pe),J(xe),Y(xe,e)):J(Pe),Y(Pe,n)}var wt=null,Oi=!1,Co=!1;function If(e){wt===null?wt=[e]:wt.push(e)}function kh(e){Oi=!0,If(e)}function rn(){if(!Co&&wt!==null){Co=!0;var e=0,t=Q;try{var n=wt;for(Q=1;e<n.length;e++){var r=n[e];do r=r(!0);while(r!==null)}wt=null,Oi=!1}catch(l){throw wt!==null&&(wt=wt.slice(e+1)),of(Ku,rn),l}finally{Q=t,Co=!1}}return null}var Hn=[],Vn=0,ci=null,fi=0,He=[],Ve=0,xn=null,St=1,kt="";function sn(e,t){Hn[Vn++]=fi,Hn[Vn++]=ci,ci=e,fi=t}function Df(e,t,n){He[Ve++]=St,He[Ve++]=kt,He[Ve++]=xn,xn=e;var r=St;e=kt;var l=32-et(r)-1;r&=~(1<<l),n+=1;var i=32-et(t)+l;if(30<i){var o=l-l%5;i=(r&(1<<o)-1).toString(32),r>>=o,l-=o,St=1<<32-et(t)+l|n<<l|r,kt=i+e}else St=1<<i|n<<l|r,kt=e}function ts(e){e.return!==null&&(sn(e,1),Df(e,1,0))}function ns(e){for(;e===ci;)ci=Hn[--Vn],Hn[Vn]=null,fi=Hn[--Vn],Hn[Vn]=null;for(;e===xn;)xn=He[--Ve],He[Ve]=null,kt=He[--Ve],He[Ve]=null,St=He[--Ve],He[Ve]=null}var Fe=null,ze=null,b=!1,be=null;function Rf(e,t){var n=We(5,null,null,0);n.elementType="DELETED",n.stateNode=t,n.return=e,t=e.deletions,t===null?(e.de
Error generating stack: `+i.message+`
2024-04-07 13:42:58 +04:00
`+i.stack}return{value:e,source:t,stack:l,digest:null}}function Po(e,t,n){return{value:e,source:null,stack:n??null,digest:t??null}}function yu(e,t){try{console.error(t.value)}catch(n){setTimeout(function(){throw n})}}var Oh=typeof WeakMap=="function"?WeakMap:Map;function fd(e,t,n){n=Ct(-1,n),n.tag=3,n.payload={element:null};var r=t.value;return n.callback=function(){xi||(xi=!0,Nu=r),yu(e,t)},n}function dd(e,t,n){n=Ct(-1,n),n.tag=3;var r=e.type.getDerivedStateFromError;if(typeof r=="function"){var l=t.value;n.payload=function(){return r(l)},n.callback=function(){yu(e,t)}}var i=e.stateNode;return i!==null&&typeof i.componentDidCatch=="function"&&(n.callback=function(){yu(e,t),typeof r!="function"&&(Gt===null?Gt=new Set([this]):Gt.add(this));var o=t.stack;this.componentDidCatch(t.value,{componentStack:o!==null?o:""})}),n}function Wa(e,t,n){var r=e.pingCache;if(r===null){r=e.pingCache=new Oh;var l=new Set;r.set(t,l)}else l=r.get(t),l===void 0&&(l=new Set,r.set(t,l));l.has(n)||(l.add(n),e=Qh.bind(null,e,t,n),t.then(e,e))}function Qa(e){do{var t;if((t=e.tag===13)&&(t=e.memoizedState,t=t!==null?t.dehydrated!==null:!0),t)return e;e=e.return}while(e!==null);return null}function Ka(e,t,n,r,l){return e.mode&1?(e.flags|=65536,e.lanes=l,e):(e===t?e.flags|=65536:(e.flags|=128,n.flags|=131072,n.flags&=-52805,n.tag===1&&(n.alternate===null?n.tag=17:(t=Ct(-1,1),t.tag=2,Zt(n,t,1))),n.lanes|=1),e)}var Mh=Pt.ReactCurrentOwner,Ne=!1;function ke(e,t,n,r){t.child=e===null?Wf(t,null,n,r):rr(t,e.child,n,r)}function Za(e,t,n,r,l){n=n.render;var i=t.ref;return Jn(t,l),r=ps(e,t,n,r,i,l),n=hs(),e!==null&&!Ne?(t.updateQueue=e.updateQueue,t.flags&=-2053,e.lanes&=~l,Nt(e,t,l)):(b&&n&&ts(t),t.flags|=1,ke(e,t,r,l),t.child)}function Ga(e,t,n,r,l){if(e===null){var i=n.type;return typeof i=="function"&&!Cs(i)&&i.defaultProps===void 0&&n.compare===null&&n.defaultProps===void 0?(t.tag=15,t.type=i,pd(e,t,i,r,l)):(e=ql(n.type,null,r,t,t.mode,l),e.ref=t.ref,e.return=t,t.child=e)}if(i=e.child,!(e.lanes&l)){var o=i.memoizedProps;if(n=n.compare,n=n!==null?n:Gr,n(o,r)&&e.ref===t.ref)return Nt(e,t,l)}return t.flags|=1,e=Xt(i,r),e.ref=t.ref,e.return=t,t.child=e}function pd(e,t,n,r,l){if(e!==null){var i=e.memoizedProps;if(Gr(i,r)&&e.ref===t.ref)if(Ne=!1,t.pendingProps=r=i,(e.lanes&l)!==0)e.flags&131072&&(Ne=!0);else return t.lanes=e.lanes,Nt(e,t,l)}return xu(e,t,n,r,l)}function hd(e,t,n){var r=t.pendingProps,l=r.children,i=e!==null?e.memoizedState:null;if(r.mode==="hidden")if(!(t.mode&1))t.memoizedState={baseLanes:0,cachePool:null,transitions:null},Y(Kn,Me),Me|=n;else{if(!(n&1073741824))return e=i!==null?i.baseLanes|n:n,t.lanes=t.childLanes=1073741824,t.memoizedState={baseLanes:e,cachePool:null,transitions:null},t.updateQueue=null,Y(Kn,Me),Me|=e,null;t.memoizedState={baseLanes:0,cachePool:null,transitions:null},r=i!==null?i.baseLanes:n,Y(Kn,Me),Me|=r}else i!==null?(r=i.baseLanes|n,t.memoizedState=null):r=n,Y(Kn,Me),Me|=r;return ke(e,t,l,n),t.child}function md(e,t){var n=t.ref;(e===null&&n!==null||e!==null&&e.ref!==n)&&(t.flags|=512,t.flags|=2097152)}function xu(e,t,n,r,l){var i=Le(n)?yn:xe.current;return i=tr(t,i),Jn(t,l),n=ps(e,t,n,r,i,l),r=hs(),e!==null&&!Ne?(t.updateQueue=e.updateQueue,t.flags&=-2053,e.lanes&=~l,Nt(e,t,l)):(b&&r&&ts(t),t.flags|=1,ke(e,t,n,l),t.child)}function Ya(e,t,n,r,l){if(Le(n)){var i=!0;ai(t)}else i=!1;if(Jn(t,l),t.stateNode===null)Yl(e,t),Hf(t,n,r),vu(t,n,r,l),r=!0;else if(e===null){var o=t.stateNode,s=t.memoizedProps;o.props=s;var a=o.context,f=n.contextType;typeof f=="object"&&f!==null?f=Ke(f):(f=Le(n)?yn:xe.current,f=tr(t,f));var y=n.getDerivedStateFromProps,x=typeof y=="function"||typeof o.getSnapshotBeforeUpdate=="function";x||typeof o.UNSAFE_componentWillReceiveProps!="function"&&typeof o.componentWillReceiveProps!="function"||(s!==r||a!==f)&&Ua(t,o,r,f),Rt=!1;var v=t.memoizedState;o.state=v,hi(t,r,o,l),a=t.memoizedState,s!==r||v!==a||Pe.current||Rt?(typeof y=="function"&&(gu(t,n,y,r),a=t.memoizedState),(s=Rt||$a(t,n,s,r,v,a,f))?(x||typeof o.UNSAFE_componentWillMount!="function"&&typeof o.componentWillMount!="function"||(typeof o.compon
2023-12-17 19:27:22 +00:00
* @license React
* use-sync-external-store-shim.production.min.js
*
* Copyright (c) Facebook, Inc. and its affiliates.
*
* This source code is licensed under the MIT license found in the
* LICENSE file in the root directory of this source tree.
2024-04-07 13:42:58 +04:00
*/var ur=C;function eg(e,t){return e===t&&(e!==0||1/e===1/t)||e!==e&&t!==t}var tg=typeof Object.is=="function"?Object.is:eg,ng=ur.useState,rg=ur.useEffect,lg=ur.useLayoutEffect,ig=ur.useDebugValue;function og(e,t){var n=t(),r=ng({inst:{value:n,getSnapshot:t}}),l=r[0].inst,i=r[1];return lg(function(){l.value=n,l.getSnapshot=t,Ro(l)&&i({inst:l})},[e,n,t]),rg(function(){return Ro(l)&&i({inst:l}),e(function(){Ro(l)&&i({inst:l})})},[e]),ig(n),n}function Ro(e){var t=e.getSnapshot;e=e.value;try{var n=t();return!tg(e,n)}catch{return!0}}function ug(e,t){return t()}var sg=typeof window>"u"||typeof window.document>"u"||typeof window.document.createElement>"u"?ug:og;Xd.useSyncExternalStore=ur.useSyncExternalStore!==void 0?ur.useSyncExternalStore:sg;Yd.exports=Xd;var ag=Yd.exports;/**
2023-12-17 19:27:22 +00:00
* @license React
* use-sync-external-store-shim/with-selector.production.min.js
*
* Copyright (c) Facebook, Inc. and its affiliates.
*
* This source code is licensed under the MIT license found in the
* LICENSE file in the root directory of this source tree.
*/var Qi=C,cg=ag;function fg(e,t){return e===t&&(e!==0||1/e===1/t)||e!==e&&t!==t}var dg=typeof Object.is=="function"?Object.is:fg,pg=cg.useSyncExternalStore,hg=Qi.useRef,mg=Qi.useEffect,gg=Qi.useMemo,vg=Qi.useDebugValue;Gd.useSyncExternalStoreWithSelector=function(e,t,n,r,l){var i=hg(null);if(i.current===null){var o={hasValue:!1,value:null};i.current=o}else o=i.current;i=gg(function(){function a(w){if(!f){if(f=!0,y=w,w=r(w),l!==void 0&&o.hasValue){var S=o.value;if(l(S,w))return x=S}return x=w}if(S=x,dg(y,w))return S;var k=r(w);return l!==void 0&&l(S,k)?S:(y=w,x=k)}var f=!1,y,x,v=n===void 0?null:n;return[function(){return a(t())},v===null?void 0:function(){return a(v())}]},[t,n,r,l]);var s=pg(e,i[0],i[1]);return mg(function(){o.hasValue=!0,o.value=s},[s]),vg(s),s};Zd.exports=Gd;var yg=Zd.exports;const xg=il(yg),{useDebugValue:wg}=Et,{useSyncExternalStoreWithSelector:Sg}=xg;const kg=e=>e;function Eg(e,t=kg,n){const r=Sg(e.subscribe,e.getState,e.getServerState||e.getInitialState,t,n);return wg(r),r}const yc=e=>{const t=typeof e=="function"?bm(e):e,n=(r,l)=>Eg(t,r,l);return Object.assign(n,t),n},Jd=e=>e?yc(e):yc,Cg=(e,t)=>e.id==t.id&&e.info_hash==t.info_hash,_g=(e,t)=>e===null&&t===null?!0:e===null||t===null?!1:e.length===t.length&&e.every((n,r)=>Cg(n,t[r])),vn=Jd(e=>({torrents:null,torrentsLoading:!1,torrentsInitiallyLoading:!1,setTorrentsLoading:t=>e(n=>n.torrents==null?{torrentsInitiallyLoading:t,torrentsLoading:t}:{torrentsInitiallyLoading:!1,torrentsLoading:t}),setTorrents:t=>e(n=>_g(n.torrents,t)?{}:{torrents:t}),refreshTorrents:()=>{},setRefreshTorrents:t=>e({refreshTorrents:t})})),Tg=({id:e,show:t,onHide:n})=>{if(!t)return null;const[r,l]=C.useState(!1),[i,o]=C.useState(null),[s,a]=C.useState(!1),f=C.useContext(Lt),y=vn(w=>w.refreshTorrents),x=()=>{l(!1),o(null),a(!1),n()},v=()=>{a(!0),(r?f.delete:f.forget)(e).then(()=>{y(),x()}).catch(S=>{o({text:`Error deleting torrent id=${e}`,details:S}),a(!1)})};return d.jsxs(Hi,{isOpen:t,onClose:n,title:"Delete torrent",children:[d.jsxs(Vi,{children:[d.jsx("p",{className:"text-gray-700 dark:text-slate-300",children:"Are you sure you want to delete the torrent?"}),d.jsxs("div",{className:"mt-4 flex items-center",children:[d.jsx("input",{type:"checkbox",id:"deleteFiles",className:"form-checkbox h-4 w-4 text-blue-500",onChange:()=>l(!r),checked:r,placeholder:"Also delete files"}),d.jsx("label",{htmlFor:"deleteFiles",className:"ml-2 text-gray-700 dark:text-slate-300",children:"Also delete files"})]}),i&&d.jsx(En,{error:i})]}),d.jsxs(Wi,{children:[s&&d.jsx(Ei,{}),d.jsx(en,{variant:"cancel",onClick:x,children:"Cancel"}),d.jsx(en,{variant:"danger",onClick:v,disabled:s,children:"Delete Torrent"})]})]})};function jg(e){return ae({tag:"svg",attr:{viewBox:"0 0 512 512"},child:[{tag:"path",attr:{d:"M487.4 315.7l-42.6-24.6c4.3-23.2 4.3-47 0-70.2l42.6-24.6c4.9-2.8 7.1-8.6 5.5-14-11.1-35.6-30-67.8-54.7-94.6-3.8-4.1-10-5.1-14.8-2.3L380.8 110c-17.9-15.4-38.5-27.3-60.8-35.1V25.8c0-5.6-3.9-10.5-9.4-11.7-36.7-8.2-74.3-7.8-109.2 0-5.5 1.2-9.4 6.1-9.4 11.7V75c-22.2 7.9-42.8 19.8-60.8 35.1L88.7 85.5c-4.9-2.8-11-1.9-14.8 2.3-24.7 26.7-43.6 58.9-54.7 94.6-1.7 5.4.6 11.2 5.5 14L67.3 221c-4.3 23.2-4.3 47 0 70.2l-42.6 24.6c-4.9 2.8-7.1 8.6-5.5 14 11.1 35.6 30 67.8 54.7 94.6 3.8 4.1 10 5.1 14.8 2.3l42.6-24.6c17.9 15.4 38.5 27.3 60.8 35.1v49.2c0 5.6 3.9 10.5 9.4 11.7 36.7 8.2 74.3 7.8 109.2 0 5.5-1.2 9.4-6.1 9.4-11.7v-49.2c22.2-7.9 42.8-19.8 60.8-35.1l42.6 24.6c4.9 2.8 11 1.9 14.8-2.3 24.7-26.7 43.6-58.9 54.7-94.6 1.5-5.5-.7-11.3-5.6-14.1zM256 336c-44.1 0-80-35.9-80-80s35.9-80 80-80 80 35.9 80 80-35.9 80-80 80z"}}]})(e)}function Ng(e){return ae({tag:"svg",attr:{viewBox:"0 0 448 512"},child:[{tag:"path",attr:{d:"M144 479H48c-26.5 0-48-21.5-48-48V79c0-26.5 21.5-48 48-48h96c26.5 0 48 21.5 48 48v352c0 26.5-21.5 48-48 48zm304-48V79c0-26.5-21.5-48-48-48h-96c-26.5 0-48 21.5-48 48v352c0 26.5 21.5 48 48 48h96c26.5 0 48-21.5 48-48z"}}]})(e)}function Pg(e){return ae({tag:"svg",attr:{viewBox:"0 0 448 512"},child:[{tag:"path",attr:{d:"M424.4 214.7L72.4 6.6C43.8-10.3 0 6.1 0 47.9V464c0 37.5 40.7 60.1 72.4 41.3l352-208c