comfy-ts 2.6.0 → 2.8.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (101) hide show
  1. package/README.md +22 -13
  2. package/dist/{DefinedWorkflow-BJgt5t0x.js → DefinedWorkflow-BatWaZO1.js} +199 -16
  3. package/dist/DefinedWorkflow-BatWaZO1.js.map +1 -0
  4. package/dist/{DraftsSt-dizp3VcC.js → LogsSt-DFxzQfDc.js} +152 -4
  5. package/dist/LogsSt-DFxzQfDc.js.map +1 -0
  6. package/dist/cli.js +8 -6
  7. package/dist/cli.js.map +1 -1
  8. package/dist/index.cjs +288 -35
  9. package/dist/index.cjs.map +1 -1
  10. package/dist/index.d.cts +128 -7
  11. package/dist/index.d.ts +128 -7
  12. package/dist/index.js +286 -37
  13. package/dist/index.js.map +1 -1
  14. package/dist/run-serve-_nrvJYyt.js +1948 -0
  15. package/dist/run-serve-_nrvJYyt.js.map +1 -0
  16. package/dist/{run-tui-idFhdO4f.js → run-tui-BPw-SZYW.js} +107 -158
  17. package/dist/run-tui-BPw-SZYW.js.map +1 -0
  18. package/dist/serve-web.js +434 -81
  19. package/dist/{state-C90kdjtB.js → state-B-boDz-Z.js} +184 -45
  20. package/dist/state-B-boDz-Z.js.map +1 -0
  21. package/dist/web.d.ts +112 -7
  22. package/dist/web.js +239 -36
  23. package/dist/web.js.map +1 -1
  24. package/examples/README.md +1 -0
  25. package/examples/comfy-cloud/sdk.d.ts +4066 -321
  26. package/examples/rvion/04-krea2-turbo-t2i.cflow.ts +18 -2
  27. package/examples/rvion/07-local-llm-text-gen.cflow.ts +220 -0
  28. package/examples/web/tsconfig.json +7 -1
  29. package/extra/README.md +32 -0
  30. package/extra/comfyui-textgen-stream/README.md +35 -0
  31. package/extra/comfyui-textgen-stream/__init__.py +166 -0
  32. package/extra/scripts/fetch_text_encoder.py +137 -0
  33. package/package.json +6 -3
  34. package/src/cli/comfy-ts-cli.ts +4 -2
  35. package/src/cli/serve/ServeApp.ts +825 -43
  36. package/src/cli/serve/applyVarPayload.ts +10 -3
  37. package/src/cli/serve/describeVar.ts +47 -7
  38. package/src/cli/serve/managerOnlyLoras.ts +27 -0
  39. package/src/cli/serve/run-serve.ts +58 -29
  40. package/src/cli/serve/serveSettings.ts +86 -0
  41. package/src/cli/serve/startupPrint.ts +111 -0
  42. package/src/cli/serve/web/api.ts +120 -1
  43. package/src/cli/serve/web/components/App.tsx +61 -22
  44. package/src/cli/serve/web/components/Gallery.tsx +243 -30
  45. package/src/cli/serve/web/components/Icon.tsx +160 -0
  46. package/src/cli/serve/web/components/PromptEnhancer.tsx +85 -38
  47. package/src/cli/serve/web/components/Sidebar.tsx +43 -19
  48. package/src/cli/serve/web/components/VarsForm.tsx +440 -80
  49. package/src/cli/serve/web/components/controls/BasicControls.tsx +38 -5
  50. package/src/cli/serve/web/components/controls/ImageControl.tsx +3 -2
  51. package/src/cli/serve/web/components/controls/LorasControl.tsx +498 -81
  52. package/src/cli/serve/web/components/controls/PresetPicker.tsx +60 -0
  53. package/src/cli/serve/web/components/controls/SeedControl.tsx +38 -20
  54. package/src/cli/serve/web/components/controls/SizeControl.tsx +3 -2
  55. package/src/cli/serve/web/llm.ts +254 -0
  56. package/src/cli/serve/web/logWeb.ts +6 -0
  57. package/src/cli/serve/web/state/EnhancerSt.ts +261 -157
  58. package/src/cli/serve/web/state/FormSt.ts +70 -18
  59. package/src/cli/serve/web/state/RunSt.ts +22 -1
  60. package/src/cli/serve/web/state/WebSt.ts +542 -13
  61. package/src/cli/serve/web/state/lightbox.ts +44 -0
  62. package/src/cli/serve/web/state/moduleTree.ts +52 -0
  63. package/src/cli/serve/web/state/payload.ts +44 -2
  64. package/src/cli/serve/web/state/urlSelection.ts +53 -0
  65. package/src/cli/serve/web/styles.ts +415 -57
  66. package/src/cli/serve/web/tsconfig.json +4 -0
  67. package/src/cli/tui/components/PickerOverlays.tsx +37 -0
  68. package/src/cli/tui/components/StatusBar.tsx +14 -1
  69. package/src/cli/tui/components/TuiApp.tsx +5 -2
  70. package/src/cli/tui/state/HostSt.ts +3 -2
  71. package/src/cli/tui/state/PickerSt.ts +48 -2
  72. package/src/cli/tui/state/TreeSt.ts +1 -1
  73. package/src/cli/tui/state/TuiSt.ts +2 -1
  74. package/src/coreExports.ts +8 -1
  75. package/src/graph/ComfyNode.ts +58 -1
  76. package/src/host/ComfyHost.ts +13 -2
  77. package/src/host/ComfyManager.ts +31 -13
  78. package/src/host/loraInfoCache.ts +35 -1
  79. package/src/host/loraManagerApi.ts +94 -0
  80. package/src/index.ts +2 -0
  81. package/src/promptEnhancers.ts +102 -0
  82. package/src/runner/ComfyExecution.ts +61 -6
  83. package/src/runner/ComfyWorkflow.ts +18 -4
  84. package/src/runner/ComfyWsApi.ts +3 -0
  85. package/src/runner/describePromptRejection.ts +34 -0
  86. package/src/sdk-generator/ComfySchema.ts +17 -4
  87. package/src/sdk-generator/comfyui-sdk-codegen.ts +56 -2
  88. package/src/state.ts +6 -0
  89. package/src/utils/ansi.ts +13 -0
  90. package/src/utils/matchesRegex.ts +13 -0
  91. package/src/utils/safeName.ts +29 -0
  92. package/src/utils/stringMap.ts +9 -0
  93. package/src/vars/ComfyVars.ts +61 -10
  94. package/src/vars/presets.ts +17 -0
  95. package/dist/DefinedWorkflow-BJgt5t0x.js.map +0 -1
  96. package/dist/DraftsSt-dizp3VcC.js.map +0 -1
  97. package/dist/run-serve-CVu39RNd.js +0 -1002
  98. package/dist/run-serve-CVu39RNd.js.map +0 -1
  99. package/dist/run-tui-idFhdO4f.js.map +0 -1
  100. package/dist/state-C90kdjtB.js.map +0 -1
  101. package/src/cli/serve/web/openrouter.ts +0 -142
package/dist/serve-web.js CHANGED
@@ -1,27 +1,22 @@
1
- var iy=Object.create;var{getPrototypeOf:uy,defineProperty:vo,getOwnPropertyNames:oy}=Object;var ry=Object.prototype.hasOwnProperty;function sy(t){return this[t]}var cy,fy,ce=(t,e,n)=>{var l=t!=null&&typeof t==="object";if(l){var a=e?cy??=new WeakMap:fy??=new WeakMap,i=a.get(t);if(i)return i}n=t!=null?iy(uy(t)):{};let u=e||!t||!t.__esModule?vo(n,"default",{value:t,enumerable:!0}):n;if(t&&typeof t==="object"||typeof t==="function"){for(let o of oy(t))if(!ry.call(u,o))vo(u,o,{get:sy.bind(t,o),enumerable:!0})}if(l)a.set(t,u);return u};var go=(t,e)=>()=>(e||t((e={exports:{}}).exports,e),e.exports);var dy=(t)=>t;function hy(t,e){this[t]=dy.bind(null,e)}var kc=(t,e)=>{for(var n in e)vo(t,n,{get:e[n],enumerable:!0,configurable:!0,set:hy.bind(e,n)})};var yo=(t,e)=>()=>(t&&(e=t(t=0)),e);function _o(t,e){var n=t.length;t.push(e);t:for(;0<n;){var l=n-1>>>1,a=t[l];if(0<_i(a,e))t[l]=e,t[n]=a,n=l;else break t}}function fe(t){return t.length===0?null:t[0]}function xi(t){if(t.length===0)return null;var e=t[0],n=t.pop();if(n!==e){t[0]=n;t:for(var l=0,a=t.length,i=a>>>1;l<i;){var u=2*(l+1)-1,o=t[u],r=u+1,s=t[r];if(0>_i(o,n))r<a&&0>_i(s,o)?(t[l]=s,t[r]=n,l=r):(t[l]=o,t[u]=n,l=u);else if(r<a&&0>_i(s,n))t[l]=s,t[r]=n,l=r;else break t}}return e}function _i(t,e){var n=t.sortIndex-e.sortIndex;return n!==0?n:t.id-e.id}function Oi(t){for(var e=fe(Je);e!==null;){if(e.callback===null)xi(Je);else if(e.startTime<=t)xi(Je),e.sortIndex=e.expirationTime,_o(Se,e);else break;e=fe(Je)}}function Ao(t){if(sa=!1,Oi(t),!ra)if(fe(Se)!==null)ra=!0,ll||(ll=!0,nl());else{var e=fe(Je);e!==null&&Do(Ao,e.startTime-t)}}function Ic(){return xo?!0:de()-Fc<my?!1:!0}function bo(){if(xo=!1,ll){var t=de();Fc=t;var e=!0;try{t:{ra=!1,sa&&(sa=!1,Wc(ca),ca=-1),Oo=!0;var n=Ei;try{e:{Oi(t);for(Kt=fe(Se);Kt!==null&&!(Kt.expirationTime>t&&Ic());){var l=Kt.callback;if(typeof l==="function"){Kt.callback=null,Ei=Kt.priorityLevel;var a=l(Kt.expirationTime<=t);if(t=de(),typeof a==="function"){Kt.callback=a,Oi(t),e=!0;break e}Kt===fe(Se)&&xi(Se),Oi(t)}else xi(Se);Kt=fe(Se)}if(Kt!==null)e=!0;else{var i=fe(Je);i!==null&&Do(Ao,i.startTime-t),e=!1}}break t}finally{Kt=null,Ei=n,Oo=!1}e=void 0}}finally{e?nl():ll=!1}}}function Do(t,e){ca=$c(function(){t(de())},e)}var de=void 0,So,Si,Eo,Se,Je,py=1,Kt=null,Ei=3,Oo=!1,ra=!1,sa=!1,xo=!1,$c,Wc,Jc,ll=!1,ca=-1,my=5,Fc=-1,nl,Ni,No,To=5,zo=1,wo=4,al=3,Ro=2,Mo=function(t){t.callback=null},Co=function(){return Ei},Uo=function(){xo=!0},il=function(t,e,n){var l=de();switch(typeof n==="object"&&n!==null?(n=n.delay,n=typeof n==="number"&&0<n?l+n:l):n=l,t){case 1:var a=-1;break;case 2:a=250;break;case 5:a=1073741823;break;case 4:a=1e4;break;default:a=5000}return a=n+a,t={id:py++,callback:e,priorityLevel:t,startTime:n,expirationTime:a,sortIndex:-1},n>l?(t.sortIndex=n,_o(Je,t),fe(Se)===null&&t===fe(Je)&&(sa?(Wc(ca),ca=-1):sa=!0,Do(Ao,n-l))):(t.sortIndex=a,_o(Se,t),ra||Oo||(ra=!0,ll||(ll=!0,nl()))),t},Vo;var Pc=yo(()=>{if(typeof performance==="object"&&typeof performance.now==="function")So=performance,de=function(){return So.now()};else Si=Date,Eo=Si.now(),de=function(){return Si.now()-Eo};Se=[],Je=[],$c=typeof setTimeout==="function"?setTimeout:null,Wc=typeof clearTimeout==="function"?clearTimeout:null,Jc=typeof setImmediate<"u"?setImmediate:null;if(typeof Jc==="function")nl=function(){Jc(bo)};else if(typeof MessageChannel<"u")Ni=new MessageChannel,No=Ni.port2,Ni.port1.onmessage=bo,nl=function(){No.postMessage(null)};else nl=function(){$c(bo,0)};Vo=Ic});var Ee=go(function(Cy){var jo=Symbol.for("react.transitional.element"),gy=Symbol.for("react.portal"),yy=Symbol.for("react.fragment"),by=Symbol.for("react.strict_mode"),_y=Symbol.for("react.profiler"),Sy=Symbol.for("react.consumer"),Ey=Symbol.for("react.context"),Oy=Symbol.for("react.forward_ref"),Ny=Symbol.for("react.suspense"),xy=Symbol.for("react.memo"),af=Symbol.for("react.lazy"),Ay=Symbol.for("react.activity"),tf=Symbol.iterator;function Dy(t){if(t===null||typeof t!=="object")return null;return t=tf&&t[tf]||t["@@iterator"],typeof t==="function"?t:null}var uf={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},of=Object.assign,rf={};function ol(t,e,n){this.props=t,this.context=e,this.refs=rf,this.updater=n||uf}ol.prototype.isReactComponent={};ol.prototype.setState=function(t,e){if(typeof t!=="object"&&typeof t!=="function"&&t!=null)throw Error("takes an object of state variables to update or a function which returns an object of state variables.");this.updater.enqueueSetState(this,t,e,"setState")};ol.prototype.forceUpdate=function(t){this.updater.enqueueForceUpdate(this,t,"forceUpdate")};function sf(){}sf.prototype=ol.prototype;function Ho(t,e,n){this.props=t,this.context=e,this.refs=rf,this.updater=n||uf}var Lo=Ho.prototype=new sf;Lo.constructor=Ho;of(Lo,ol.prototype);Lo.isPureReactComponent=!0;var ef=Array.isArray;function qo(){}var W={H:null,A:null,T:null,S:null},cf=Object.prototype.hasOwnProperty;function Go(t,e,n){var l=n.ref;return{$$typeof:jo,type:t,key:e,ref:l!==void 0?l:null,props:n}}function Ty(t,e){return Go(t.type,e,t.props)}function Yo(t){return typeof t==="object"&&t!==null&&t.$$typeof===jo}function zy(t){var e={"=":"=0",":":"=2"};return"$"+t.replace(/[=:]/g,function(n){return e[n]})}var nf=/\/+/g;function Bo(t,e){return typeof t==="object"&&t!==null&&t.key!=null?zy(""+t.key):e.toString(36)}function wy(t){switch(t.status){case"fulfilled":return t.value;case"rejected":throw t.reason;default:switch(typeof t.status==="string"?t.then(qo,qo):(t.status="pending",t.then(function(e){t.status==="pending"&&(t.status="fulfilled",t.value=e)},function(e){t.status==="pending"&&(t.status="rejected",t.reason=e)})),t.status){case"fulfilled":return t.value;case"rejected":throw t.reason}}throw t}function ul(t,e,n,l,a){var i=typeof t;if(i==="undefined"||i==="boolean")t=null;var u=!1;if(t===null)u=!0;else switch(i){case"bigint":case"string":case"number":u=!0;break;case"object":switch(t.$$typeof){case jo:case gy:u=!0;break;case af:return u=t._init,ul(u(t._payload),e,n,l,a)}}if(u)return a=a(t),u=l===""?"."+Bo(t,0):l,ef(a)?(n="",u!=null&&(n=u.replace(nf,"$&/")+"/"),ul(a,e,n,"",function(s){return s})):a!=null&&(Yo(a)&&(a=Ty(a,n+(a.key==null||t&&t.key===a.key?"":(""+a.key).replace(nf,"$&/")+"/")+u)),e.push(a)),1;u=0;var o=l===""?".":l+":";if(ef(t))for(var r=0;r<t.length;r++)l=t[r],i=o+Bo(l,r),u+=ul(l,e,n,i,a);else if(r=Dy(t),typeof r==="function")for(t=r.call(t),r=0;!(l=t.next()).done;)l=l.value,i=o+Bo(l,r++),u+=ul(l,e,n,i,a);else if(i==="object"){if(typeof t.then==="function")return ul(wy(t),e,n,l,a);throw e=String(t),Error("Objects are not valid as a React child (found: "+(e==="[object Object]"?"object with keys {"+Object.keys(t).join(", ")+"}":e)+"). If you meant to render a collection of children, use an array instead.")}return u}function Ai(t,e,n){if(t==null)return t;var l=[],a=0;return ul(t,l,"","",function(i){return e.call(n,i,a++)}),l}function Ry(t){if(t._status===-1){var e=t._result;e=e(),e.then(function(n){if(t._status===0||t._status===-1)t._status=1,t._result=n},function(n){if(t._status===0||t._status===-1)t._status=2,t._result=n}),t._status===-1&&(t._status=0,t._result=e)}if(t._status===1)return t._result.default;throw t._result}var lf=typeof reportError==="function"?reportError:function(t){if(typeof window==="object"&&typeof window.ErrorEvent==="function"){var e=new window.ErrorEvent("error",{bubbles:!0,cancelable:!0,message:typeof t==="object"&&t!==null&&typeof t.message==="string"?String(t.message):String(t),error:t});if(!window.dispatchEvent(e))return}else if(typeof process==="object"&&typeof process.emit==="function"){process.emit("uncaughtException",t);return}console.error(t)},My={map:Ai,forEach:function(t,e,n){Ai(t,function(){e.apply(this,arguments)},n)},count:function(t){var e=0;return Ai(t,function(){e++}),e},toArray:function(t){return Ai(t,function(e){return e})||[]},only:function(t){if(!Yo(t))throw Error("React.Children.only expected to receive a single React element child.");return t}};Cy.Activity=Ay;Cy.Children=My;Cy.Component=ol;Cy.Fragment=yy;Cy.Profiler=_y;Cy.PureComponent=Ho;Cy.StrictMode=by;Cy.Suspense=Ny;Cy.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE=W;Cy.__COMPILER_RUNTIME={__proto__:null,c:function(t){return W.H.useMemoCache(t)}};Cy.cache=function(t){return function(){return t.apply(null,arguments)}};Cy.cacheSignal=function(){return null};Cy.cloneElement=function(t,e,n){if(t===null||t===void 0)throw Error("The argument must be a React element, but you passed "+t+".");var l=of({},t.props),a=t.key;if(e!=null)for(i in e.key!==void 0&&(a=""+e.key),e)!cf.call(e,i)||i==="key"||i==="__self"||i==="__source"||i==="ref"&&e.ref===void 0||(l[i]=e[i]);var i=arguments.length-2;if(i===1)l.children=n;else if(1<i){for(var u=Array(i),o=0;o<i;o++)u[o]=arguments[o+2];l.children=u}return Go(t.type,a,l)};Cy.createContext=function(t){return t={$$typeof:Ey,_currentValue:t,_currentValue2:t,_threadCount:0,Provider:null,Consumer:null},t.Provider=t,t.Consumer={$$typeof:Sy,_context:t},t};Cy.createElement=function(t,e,n){var l,a={},i=null;if(e!=null)for(l in e.key!==void 0&&(i=""+e.key),e)cf.call(e,l)&&l!=="key"&&l!=="__self"&&l!=="__source"&&(a[l]=e[l]);var u=arguments.length-2;if(u===1)a.children=n;else if(1<u){for(var o=Array(u),r=0;r<u;r++)o[r]=arguments[r+2];a.children=o}if(t&&t.defaultProps)for(l in u=t.defaultProps,u)a[l]===void 0&&(a[l]=u[l]);return Go(t,i,a)};Cy.createRef=function(){return{current:null}};Cy.forwardRef=function(t){return{$$typeof:Oy,render:t}};Cy.isValidElement=Yo;Cy.lazy=function(t){return{$$typeof:af,_payload:{_status:-1,_result:t},_init:Ry}};Cy.memo=function(t,e){return{$$typeof:xy,type:t,compare:e===void 0?null:e}};Cy.startTransition=function(t){var e=W.T,n={};W.T=n;try{var l=t(),a=W.S;a!==null&&a(n,l),typeof l==="object"&&l!==null&&typeof l.then==="function"&&l.then(qo,lf)}catch(i){lf(i)}finally{e!==null&&n.types!==null&&(e.types=n.types),W.T=e}};Cy.unstable_useCacheRefresh=function(){return W.H.useCacheRefresh()};Cy.use=function(t){return W.H.use(t)};Cy.useActionState=function(t,e,n){return W.H.useActionState(t,e,n)};Cy.useCallback=function(t,e){return W.H.useCallback(t,e)};Cy.useContext=function(t){return W.H.useContext(t)};Cy.useDebugValue=function(){};Cy.useDeferredValue=function(t,e){return W.H.useDeferredValue(t,e)};Cy.useEffect=function(t,e){return W.H.useEffect(t,e)};Cy.useEffectEvent=function(t){return W.H.useEffectEvent(t)};Cy.useId=function(){return W.H.useId()};Cy.useImperativeHandle=function(t,e,n){return W.H.useImperativeHandle(t,e,n)};Cy.useInsertionEffect=function(t,e){return W.H.useInsertionEffect(t,e)};Cy.useLayoutEffect=function(t,e){return W.H.useLayoutEffect(t,e)};Cy.useMemo=function(t,e){return W.H.useMemo(t,e)};Cy.useOptimistic=function(t,e){return W.H.useOptimistic(t,e)};Cy.useReducer=function(t,e,n){return W.H.useReducer(t,e,n)};Cy.useRef=function(t){return W.H.useRef(t)};Cy.useState=function(t){return W.H.useState(t)};Cy.useSyncExternalStore=function(t,e,n){return W.H.useSyncExternalStore(t,e,n)};Cy.useTransition=function(){return W.H.useTransition()};Cy.version="19.2.8"});var Ko={};kc(Ko,{__DOM_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE:()=>hf,createPortal:()=>pf,flushSync:()=>mf,preconnect:()=>vf,prefetchDNS:()=>gf,preinit:()=>yf,preinitModule:()=>bf,preload:()=>_f,preloadModule:()=>Sf,requestFormReset:()=>Ef,unstable_batchedUpdates:()=>Of,useFormState:()=>Nf,useFormStatus:()=>xf,version:()=>Af});function df(t){var e="https://react.dev/errors/"+t;if(1<arguments.length){e+="?args[]="+encodeURIComponent(arguments[1]);for(var n=2;n<arguments.length;n++)e+="&args[]="+encodeURIComponent(arguments[n])}return"Minified React error #"+t+"; visit "+e+" for the full message or use the non-minified dev environment for full errors and additional helpful warnings."}function $e(){}function Ob(t,e,n){var l=3<arguments.length&&arguments[3]!==void 0?arguments[3]:null;return{$$typeof:Eb,key:l==null?null:""+l,children:t,containerInfo:e,implementation:n}}function Di(t,e){if(t==="font")return"";if(typeof e==="string")return e==="use-credentials"?e:""}var ff,St,Eb,fa,hf,pf=function(t,e){var n=2<arguments.length&&arguments[2]!==void 0?arguments[2]:null;if(!e||e.nodeType!==1&&e.nodeType!==9&&e.nodeType!==11)throw Error(df(299));return Ob(t,e,null,n)},mf=function(t){var e=fa.T,n=St.p;try{if(fa.T=null,St.p=2,t)return t()}finally{fa.T=e,St.p=n,St.d.f()}},vf=function(t,e){typeof t==="string"&&(e?(e=e.crossOrigin,e=typeof e==="string"?e==="use-credentials"?e:"":void 0):e=null,St.d.C(t,e))},gf=function(t){typeof t==="string"&&St.d.D(t)},yf=function(t,e){if(typeof t==="string"&&e&&typeof e.as==="string"){var n=e.as,l=Di(n,e.crossOrigin),a=typeof e.integrity==="string"?e.integrity:void 0,i=typeof e.fetchPriority==="string"?e.fetchPriority:void 0;n==="style"?St.d.S(t,typeof e.precedence==="string"?e.precedence:void 0,{crossOrigin:l,integrity:a,fetchPriority:i}):n==="script"&&St.d.X(t,{crossOrigin:l,integrity:a,fetchPriority:i,nonce:typeof e.nonce==="string"?e.nonce:void 0})}},bf=function(t,e){if(typeof t==="string")if(typeof e==="object"&&e!==null){if(e.as==null||e.as==="script"){var n=Di(e.as,e.crossOrigin);St.d.M(t,{crossOrigin:n,integrity:typeof e.integrity==="string"?e.integrity:void 0,nonce:typeof e.nonce==="string"?e.nonce:void 0})}}else e==null&&St.d.M(t)},_f=function(t,e){if(typeof t==="string"&&typeof e==="object"&&e!==null&&typeof e.as==="string"){var n=e.as,l=Di(n,e.crossOrigin);St.d.L(t,n,{crossOrigin:l,integrity:typeof e.integrity==="string"?e.integrity:void 0,nonce:typeof e.nonce==="string"?e.nonce:void 0,type:typeof e.type==="string"?e.type:void 0,fetchPriority:typeof e.fetchPriority==="string"?e.fetchPriority:void 0,referrerPolicy:typeof e.referrerPolicy==="string"?e.referrerPolicy:void 0,imageSrcSet:typeof e.imageSrcSet==="string"?e.imageSrcSet:void 0,imageSizes:typeof e.imageSizes==="string"?e.imageSizes:void 0,media:typeof e.media==="string"?e.media:void 0})}},Sf=function(t,e){if(typeof t==="string")if(e){var n=Di(e.as,e.crossOrigin);St.d.m(t,{as:typeof e.as==="string"&&e.as!=="script"?e.as:void 0,crossOrigin:n,integrity:typeof e.integrity==="string"?e.integrity:void 0})}else St.d.m(t)},Ef=function(t){St.d.r(t)},Of=function(t,e){return t(e)},Nf=function(t,e,n){return fa.H.useFormState(t,e,n)},xf=function(){return fa.H.useHostTransitionStatus()},Af="19.2.8";var Df=yo(()=>{ff=ce(Ee(),1);St={d:{f:$e,r:function(){throw Error(df(522))},D:$e,C:$e,L:$e,m:$e,X:$e,S:$e,M:$e},p:0,findDOMNode:null},Eb=Symbol.for("react.portal");fa=ff.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE;hf=St});var wf=go(function(WS,zf){Df();function Tf(){if(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__>"u"||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!=="function")return;try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(Tf)}catch(t){console.error(t)}}Tf(),zf.exports=Ko});var mc={};kc(mc,{createRoot:()=>Lm,hydrateRoot:()=>Gm,version:()=>Ym});function _(t){var e="https://react.dev/errors/"+t;if(1<arguments.length){e+="?args[]="+encodeURIComponent(arguments[1]);for(var n=2;n<arguments.length;n++)e+="&args[]="+encodeURIComponent(arguments[n])}return"Minified React error #"+t+"; visit "+e+" for the full message or use the non-minified dev environment for full errors and additional helpful warnings."}function eh(t){return!(!t||t.nodeType!==1&&t.nodeType!==9&&t.nodeType!==11)}function ti(t){var e=t,n=t;if(t.alternate)for(;e.return;)e=e.return;else{t=e;do e=t,(e.flags&4098)!==0&&(n=e.return),t=e.return;while(t)}return e.tag===3?n:null}function nh(t){if(t.tag===13){var e=t.memoizedState;if(e===null&&(t=t.alternate,t!==null&&(e=t.memoizedState)),e!==null)return e.dehydrated}return null}function lh(t){if(t.tag===31){var e=t.memoizedState;if(e===null&&(t=t.alternate,t!==null&&(e=t.memoizedState)),e!==null)return e.dehydrated}return null}function Rf(t){if(ti(t)!==t)throw Error(_(188))}function Nb(t){var e=t.alternate;if(!e){if(e=ti(t),e===null)throw Error(_(188));return e!==t?null:t}for(var n=t,l=e;;){var a=n.return;if(a===null)break;var i=a.alternate;if(i===null){if(l=a.return,l!==null){n=l;continue}break}if(a.child===i.child){for(i=a.child;i;){if(i===n)return Rf(a),t;if(i===l)return Rf(a),e;i=i.sibling}throw Error(_(188))}if(n.return!==l.return)n=a,l=i;else{for(var u=!1,o=a.child;o;){if(o===n){u=!0,n=a,l=i;break}if(o===l){u=!0,l=a,n=i;break}o=o.sibling}if(!u){for(o=i.child;o;){if(o===n){u=!0,n=i,l=a;break}if(o===l){u=!0,l=i,n=a;break}o=o.sibling}if(!u)throw Error(_(189))}}if(n.alternate!==l)throw Error(_(190))}if(n.tag!==3)throw Error(_(188));return n.stateNode.current===n?t:e}function ah(t){var e=t.tag;if(e===5||e===26||e===27||e===6)return t;for(t=t.child;t!==null;){if(e=ah(t),e!==null)return e;t=t.sibling}return null}function da(t){if(t===null||typeof t!=="object")return null;return t=Mf&&t[Mf]||t["@@iterator"],typeof t==="function"?t:null}function Ar(t){if(t==null)return null;if(typeof t==="function")return t.$$typeof===Db?null:t.displayName||t.name||null;if(typeof t==="string")return t;switch(t){case hl:return"Fragment";case Er:return"Profiler";case ih:return"StrictMode";case Or:return"Suspense";case Nr:return"SuspenseList";case xr:return"Activity"}if(typeof t==="object")switch(t.$$typeof){case ya:return"Portal";case we:return t.displayName||"Context";case uh:return(t._context.displayName||"Context")+".Consumer";case bs:var e=t.render;return t=t.displayName,t||(t=e.displayName||e.name||"",t=t!==""?"ForwardRef("+t+")":"ForwardRef"),t;case _s:return e=t.displayName||null,e!==null?e:Ar(t.type)||"Memo";case We:e=t._payload,t=t._init;try{return Ar(t(e))}catch(n){}}return null}function ge(t){return{current:t}}function ht(t){0>pl||(t.current=Dr[pl],Dr[pl]=null,pl--)}function k(t,e){pl++,Dr[pl]=t.current,t.current=e}function iu(t,e){switch(k(rn,e),k(La,t),k(ve,null),e.nodeType){case 9:case 11:t=(t=e.documentElement)?(t=t.namespaceURI)?qd(t):0:0;break;default:if(t=e.tagName,e=e.namespaceURI)e=qd(e),t=Am(e,t);else switch(t){case"svg":t=1;break;case"math":t=2;break;default:t=0}}ht(ve),k(ve,t)}function Ml(){ht(ve),ht(La),ht(rn)}function Tr(t){t.memoizedState!==null&&k(au,t);var e=ve.current,n=Am(e,t.type);e!==n&&(k(La,t),k(ve,n))}function uu(t){La.current===t&&(ht(ve),ht(La)),au.current===t&&(ht(au),Fa._currentValue=Vn)}function wn(t){if(Xo===void 0)try{throw Error()}catch(n){var e=n.stack.trim().match(/\n( *(at )?)/);Xo=e&&e[1]||"",Cf=-1<n.stack.indexOf(`
1
+ var ay=Object.create;var{getPrototypeOf:iy,defineProperty:Lr,getOwnPropertyNames:ly}=Object;var oy=Object.prototype.hasOwnProperty;function ry(e){return this[e]}var sy,uy,$e=(e,t,n)=>{var a=e!=null&&typeof e==="object";if(a){var i=t?sy??=new WeakMap:uy??=new WeakMap,l=i.get(e);if(l)return l}n=e!=null?ay(iy(e)):{};let o=t||!e||!e.__esModule?Lr(n,"default",{value:e,enumerable:!0}):n;if(e&&typeof e==="object"||typeof e==="function"){for(let r of ly(e))if(!oy.call(o,r))Lr(o,r,{get:ry.bind(e,r),enumerable:!0})}if(a)i.set(e,o);return o};var Br=(e,t)=>()=>(t||e((t={exports:{}}).exports,t),t.exports);var cy=(e)=>e;function fy(e,t){this[e]=cy.bind(null,t)}var bf=(e,t)=>{for(var n in t)Lr(e,n,{get:t[n],enumerable:!0,configurable:!0,set:fy.bind(t,n)})};var Hr=(e,t)=>()=>(e&&(t=e(e=0)),t);function qr(e,t){var n=e.length;e.push(t);e:for(;0<n;){var a=n-1>>>1,i=e[a];if(0<kl(i,t))e[a]=t,e[n]=i,n=a;else break e}}function yt(e){return e.length===0?null:e[0]}function jl(e){if(e.length===0)return null;var t=e[0],n=e.pop();if(n!==t){e[0]=n;e:for(var a=0,i=e.length,l=i>>>1;a<l;){var o=2*(a+1)-1,r=e[o],s=o+1,c=e[s];if(0>kl(r,n))s<i&&0>kl(c,r)?(e[a]=c,e[s]=n,a=s):(e[a]=r,e[o]=n,a=o);else if(s<i&&0>kl(c,n))e[a]=c,e[s]=n,a=s;else break e}}return t}function kl(e,t){var n=e.sortIndex-t.sortIndex;return n!==0?n:e.id-t.id}function Bl(e){for(var t=yt(nn);t!==null;){if(t.callback===null)jl(nn);else if(t.startTime<=e)jl(nn),t.sortIndex=t.expirationTime,qr(Dt,t);else break;t=yt(nn)}}function Zr(e){if(xi=!1,Bl(e),!Si)if(yt(Dt)!==null)Si=!0,pa||(pa=!0,ha());else{var t=yt(nn);t!==null&&$r(Zr,t.startTime-e)}}function Ef(){return Qr?!0:_t()-xf<hy?!1:!0}function jr(){if(Qr=!1,pa){var e=_t();xf=e;var t=!0;try{e:{Si=!1,xi&&(xi=!1,Sf(Ei),Ei=-1),Kr=!0;var n=Ll;try{t:{Bl(e);for(Je=yt(Dt);Je!==null&&!(Je.expirationTime>e&&Ef());){var a=Je.callback;if(typeof a==="function"){Je.callback=null,Ll=Je.priorityLevel;var i=a(Je.expirationTime<=e);if(e=_t(),typeof i==="function"){Je.callback=i,Bl(e),t=!0;break t}Je===yt(Dt)&&jl(Dt),Bl(e)}else jl(Dt);Je=yt(Dt)}if(Je!==null)t=!0;else{var l=yt(nn);l!==null&&$r(Zr,l.startTime-e),t=!1}}break e}finally{Je=null,Ll=n,Kr=!1}t=void 0}}finally{t?ha():pa=!1}}}function $r(e,t){Ei=_f(function(){e(_t())},t)}var _t=void 0,Gr,Vl,Yr,Dt,nn,dy=1,Je=null,Ll=3,Kr=!1,Si=!1,xi=!1,Qr=!1,_f,Sf,yf,pa=!1,Ei=-1,hy=5,xf=-1,ha,Hl,Xr,Jr=5,Fr=1,Wr=4,ma=3,Ir=2,Pr=function(e){e.callback=null},es=function(){return Ll},ts=function(){Qr=!0},va=function(e,t,n){var a=_t();switch(typeof n==="object"&&n!==null?(n=n.delay,n=typeof n==="number"&&0<n?a+n:a):n=a,e){case 1:var i=-1;break;case 2:i=250;break;case 5:i=1073741823;break;case 4:i=1e4;break;default:i=5000}return i=n+i,e={id:dy++,callback:t,priorityLevel:e,startTime:n,expirationTime:i,sortIndex:-1},n>a?(e.sortIndex=n,qr(nn,e),yt(Dt)===null&&e===yt(nn)&&(xi?(Sf(Ei),Ei=-1):xi=!0,$r(Zr,n-a))):(e.sortIndex=i,qr(Dt,e),Si||Kr||(Si=!0,pa||(pa=!0,ha()))),e},ns;var wf=Hr(()=>{if(typeof performance==="object"&&typeof performance.now==="function")Gr=performance,_t=function(){return Gr.now()};else Vl=Date,Yr=Vl.now(),_t=function(){return Vl.now()-Yr};Dt=[],nn=[],_f=typeof setTimeout==="function"?setTimeout:null,Sf=typeof clearTimeout==="function"?clearTimeout:null,yf=typeof setImmediate<"u"?setImmediate:null;if(typeof yf==="function")ha=function(){yf(jr)};else if(typeof MessageChannel<"u")Hl=new MessageChannel,Xr=Hl.port2,Hl.port1.onmessage=jr,ha=function(){Xr.postMessage(null)};else ha=function(){_f(jr,0)};ns=Ef});var ft=Br(function(Ry){var ls=Symbol.for("react.transitional.element"),my=Symbol.for("react.portal"),vy=Symbol.for("react.fragment"),gy=Symbol.for("react.strict_mode"),by=Symbol.for("react.profiler"),yy=Symbol.for("react.consumer"),_y=Symbol.for("react.context"),Sy=Symbol.for("react.forward_ref"),xy=Symbol.for("react.suspense"),Ey=Symbol.for("react.memo"),Df=Symbol.for("react.lazy"),wy=Symbol.for("react.activity"),Nf=Symbol.iterator;function Ny(e){if(e===null||typeof e!=="object")return null;return e=Nf&&e[Nf]||e["@@iterator"],typeof e==="function"?e:null}var zf={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},Rf=Object.assign,Mf={};function ba(e,t,n){this.props=e,this.context=t,this.refs=Mf,this.updater=n||zf}ba.prototype.isReactComponent={};ba.prototype.setState=function(e,t){if(typeof e!=="object"&&typeof e!=="function"&&e!=null)throw Error("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")};ba.prototype.forceUpdate=function(e){this.updater.enqueueForceUpdate(this,e,"forceUpdate")};function Cf(){}Cf.prototype=ba.prototype;function os(e,t,n){this.props=e,this.context=t,this.refs=Mf,this.updater=n||zf}var rs=os.prototype=new Cf;rs.constructor=os;Rf(rs,ba.prototype);rs.isPureReactComponent=!0;var Of=Array.isArray;function is(){}var ee={H:null,A:null,T:null,S:null},Uf=Object.prototype.hasOwnProperty;function ss(e,t,n){var a=n.ref;return{$$typeof:ls,type:e,key:t,ref:a!==void 0?a:null,props:n}}function Oy(e,t){return ss(e.type,t,e.props)}function us(e){return typeof e==="object"&&e!==null&&e.$$typeof===ls}function Ay(e){var t={"=":"=0",":":"=2"};return"$"+e.replace(/[=:]/g,function(n){return t[n]})}var Af=/\/+/g;function as(e,t){return typeof e==="object"&&e!==null&&e.key!=null?Ay(""+e.key):t.toString(36)}function Ty(e){switch(e.status){case"fulfilled":return e.value;case"rejected":throw e.reason;default:switch(typeof e.status==="string"?e.then(is,is):(e.status="pending",e.then(function(t){e.status==="pending"&&(e.status="fulfilled",e.value=t)},function(t){e.status==="pending"&&(e.status="rejected",e.reason=t)})),e.status){case"fulfilled":return e.value;case"rejected":throw e.reason}}throw e}function ga(e,t,n,a,i){var l=typeof e;if(l==="undefined"||l==="boolean")e=null;var o=!1;if(e===null)o=!0;else switch(l){case"bigint":case"string":case"number":o=!0;break;case"object":switch(e.$$typeof){case ls:case my:o=!0;break;case Df:return o=e._init,ga(o(e._payload),t,n,a,i)}}if(o)return i=i(e),o=a===""?"."+as(e,0):a,Of(i)?(n="",o!=null&&(n=o.replace(Af,"$&/")+"/"),ga(i,t,n,"",function(c){return c})):i!=null&&(us(i)&&(i=Oy(i,n+(i.key==null||e&&e.key===i.key?"":(""+i.key).replace(Af,"$&/")+"/")+o)),t.push(i)),1;o=0;var r=a===""?".":a+":";if(Of(e))for(var s=0;s<e.length;s++)a=e[s],l=r+as(a,s),o+=ga(a,t,n,l,i);else if(s=Ny(e),typeof s==="function")for(e=s.call(e),s=0;!(a=e.next()).done;)a=a.value,l=r+as(a,s++),o+=ga(a,t,n,l,i);else if(l==="object"){if(typeof e.then==="function")return ga(Ty(e),t,n,a,i);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 ql(e,t,n){if(e==null)return e;var a=[],i=0;return ga(e,a,"","",function(l){return t.call(n,l,i++)}),a}function Dy(e){if(e._status===-1){var t=e._result;t=t(),t.then(function(n){if(e._status===0||e._status===-1)e._status=1,e._result=n},function(n){if(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 Tf=typeof reportError==="function"?reportError:function(e){if(typeof window==="object"&&typeof window.ErrorEvent==="function"){var t=new window.ErrorEvent("error",{bubbles:!0,cancelable:!0,message:typeof e==="object"&&e!==null&&typeof e.message==="string"?String(e.message):String(e),error:e});if(!window.dispatchEvent(t))return}else if(typeof process==="object"&&typeof process.emit==="function"){process.emit("uncaughtException",e);return}console.error(e)},zy={map:ql,forEach:function(e,t,n){ql(e,function(){t.apply(this,arguments)},n)},count:function(e){var t=0;return ql(e,function(){t++}),t},toArray:function(e){return ql(e,function(t){return t})||[]},only:function(e){if(!us(e))throw Error("React.Children.only expected to receive a single React element child.");return e}};Ry.Activity=wy;Ry.Children=zy;Ry.Component=ba;Ry.Fragment=vy;Ry.Profiler=by;Ry.PureComponent=os;Ry.StrictMode=gy;Ry.Suspense=xy;Ry.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE=ee;Ry.__COMPILER_RUNTIME={__proto__:null,c:function(e){return ee.H.useMemoCache(e)}};Ry.cache=function(e){return function(){return e.apply(null,arguments)}};Ry.cacheSignal=function(){return null};Ry.cloneElement=function(e,t,n){if(e===null||e===void 0)throw Error("The argument must be a React element, but you passed "+e+".");var a=Rf({},e.props),i=e.key;if(t!=null)for(l in t.key!==void 0&&(i=""+t.key),t)!Uf.call(t,l)||l==="key"||l==="__self"||l==="__source"||l==="ref"&&t.ref===void 0||(a[l]=t[l]);var l=arguments.length-2;if(l===1)a.children=n;else if(1<l){for(var o=Array(l),r=0;r<l;r++)o[r]=arguments[r+2];a.children=o}return ss(e.type,i,a)};Ry.createContext=function(e){return e={$$typeof:_y,_currentValue:e,_currentValue2:e,_threadCount:0,Provider:null,Consumer:null},e.Provider=e,e.Consumer={$$typeof:yy,_context:e},e};Ry.createElement=function(e,t,n){var a,i={},l=null;if(t!=null)for(a in t.key!==void 0&&(l=""+t.key),t)Uf.call(t,a)&&a!=="key"&&a!=="__self"&&a!=="__source"&&(i[a]=t[a]);var o=arguments.length-2;if(o===1)i.children=n;else if(1<o){for(var r=Array(o),s=0;s<o;s++)r[s]=arguments[s+2];i.children=r}if(e&&e.defaultProps)for(a in o=e.defaultProps,o)i[a]===void 0&&(i[a]=o[a]);return ss(e,l,i)};Ry.createRef=function(){return{current:null}};Ry.forwardRef=function(e){return{$$typeof:Sy,render:e}};Ry.isValidElement=us;Ry.lazy=function(e){return{$$typeof:Df,_payload:{_status:-1,_result:e},_init:Dy}};Ry.memo=function(e,t){return{$$typeof:Ey,type:e,compare:t===void 0?null:t}};Ry.startTransition=function(e){var t=ee.T,n={};ee.T=n;try{var a=e(),i=ee.S;i!==null&&i(n,a),typeof a==="object"&&a!==null&&typeof a.then==="function"&&a.then(is,Tf)}catch(l){Tf(l)}finally{t!==null&&n.types!==null&&(t.types=n.types),ee.T=t}};Ry.unstable_useCacheRefresh=function(){return ee.H.useCacheRefresh()};Ry.use=function(e){return ee.H.use(e)};Ry.useActionState=function(e,t,n){return ee.H.useActionState(e,t,n)};Ry.useCallback=function(e,t){return ee.H.useCallback(e,t)};Ry.useContext=function(e){return ee.H.useContext(e)};Ry.useDebugValue=function(){};Ry.useDeferredValue=function(e,t){return ee.H.useDeferredValue(e,t)};Ry.useEffect=function(e,t){return ee.H.useEffect(e,t)};Ry.useEffectEvent=function(e){return ee.H.useEffectEvent(e)};Ry.useId=function(){return ee.H.useId()};Ry.useImperativeHandle=function(e,t,n){return ee.H.useImperativeHandle(e,t,n)};Ry.useInsertionEffect=function(e,t){return ee.H.useInsertionEffect(e,t)};Ry.useLayoutEffect=function(e,t){return ee.H.useLayoutEffect(e,t)};Ry.useMemo=function(e,t){return ee.H.useMemo(e,t)};Ry.useOptimistic=function(e,t){return ee.H.useOptimistic(e,t)};Ry.useReducer=function(e,t,n){return ee.H.useReducer(e,t,n)};Ry.useRef=function(e){return ee.H.useRef(e)};Ry.useState=function(e){return ee.H.useState(e)};Ry.useSyncExternalStore=function(e,t,n){return ee.H.useSyncExternalStore(e,t,n)};Ry.useTransition=function(){return ee.H.useTransition()};Ry.version="19.2.8"});var cs={};bf(cs,{__DOM_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE:()=>Lf,createPortal:()=>Bf,flushSync:()=>Hf,preconnect:()=>jf,prefetchDNS:()=>qf,preinit:()=>Gf,preinitModule:()=>Yf,preload:()=>Kf,preloadModule:()=>Xf,requestFormReset:()=>Qf,unstable_batchedUpdates:()=>Zf,useFormState:()=>$f,useFormStatus:()=>Jf,version:()=>Ff});function Vf(e){var t="https://react.dev/errors/"+e;if(1<arguments.length){t+="?args[]="+encodeURIComponent(arguments[1]);for(var n=2;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."}function an(){}function S0(e,t,n){var a=3<arguments.length&&arguments[3]!==void 0?arguments[3]:null;return{$$typeof:_0,key:a==null?null:""+a,children:e,containerInfo:t,implementation:n}}function Gl(e,t){if(e==="font")return"";if(typeof t==="string")return t==="use-credentials"?t:""}var kf,Oe,_0,wi,Lf,Bf=function(e,t){var n=2<arguments.length&&arguments[2]!==void 0?arguments[2]:null;if(!t||t.nodeType!==1&&t.nodeType!==9&&t.nodeType!==11)throw Error(Vf(299));return S0(e,t,null,n)},Hf=function(e){var t=wi.T,n=Oe.p;try{if(wi.T=null,Oe.p=2,e)return e()}finally{wi.T=t,Oe.p=n,Oe.d.f()}},jf=function(e,t){typeof e==="string"&&(t?(t=t.crossOrigin,t=typeof t==="string"?t==="use-credentials"?t:"":void 0):t=null,Oe.d.C(e,t))},qf=function(e){typeof e==="string"&&Oe.d.D(e)},Gf=function(e,t){if(typeof e==="string"&&t&&typeof t.as==="string"){var n=t.as,a=Gl(n,t.crossOrigin),i=typeof t.integrity==="string"?t.integrity:void 0,l=typeof t.fetchPriority==="string"?t.fetchPriority:void 0;n==="style"?Oe.d.S(e,typeof t.precedence==="string"?t.precedence:void 0,{crossOrigin:a,integrity:i,fetchPriority:l}):n==="script"&&Oe.d.X(e,{crossOrigin:a,integrity:i,fetchPriority:l,nonce:typeof t.nonce==="string"?t.nonce:void 0})}},Yf=function(e,t){if(typeof e==="string")if(typeof t==="object"&&t!==null){if(t.as==null||t.as==="script"){var n=Gl(t.as,t.crossOrigin);Oe.d.M(e,{crossOrigin:n,integrity:typeof t.integrity==="string"?t.integrity:void 0,nonce:typeof t.nonce==="string"?t.nonce:void 0})}}else t==null&&Oe.d.M(e)},Kf=function(e,t){if(typeof e==="string"&&typeof t==="object"&&t!==null&&typeof t.as==="string"){var n=t.as,a=Gl(n,t.crossOrigin);Oe.d.L(e,n,{crossOrigin:a,integrity:typeof t.integrity==="string"?t.integrity:void 0,nonce:typeof t.nonce==="string"?t.nonce:void 0,type:typeof t.type==="string"?t.type:void 0,fetchPriority:typeof t.fetchPriority==="string"?t.fetchPriority:void 0,referrerPolicy:typeof t.referrerPolicy==="string"?t.referrerPolicy:void 0,imageSrcSet:typeof t.imageSrcSet==="string"?t.imageSrcSet:void 0,imageSizes:typeof t.imageSizes==="string"?t.imageSizes:void 0,media:typeof t.media==="string"?t.media:void 0})}},Xf=function(e,t){if(typeof e==="string")if(t){var n=Gl(t.as,t.crossOrigin);Oe.d.m(e,{as:typeof t.as==="string"&&t.as!=="script"?t.as:void 0,crossOrigin:n,integrity:typeof t.integrity==="string"?t.integrity:void 0})}else Oe.d.m(e)},Qf=function(e){Oe.d.r(e)},Zf=function(e,t){return e(t)},$f=function(e,t,n){return wi.H.useFormState(e,t,n)},Jf=function(){return wi.H.useHostTransitionStatus()},Ff="19.2.8";var Wf=Hr(()=>{kf=$e(ft(),1);Oe={d:{f:an,r:function(){throw Error(Vf(522))},D:an,C:an,L:an,m:an,X:an,S:an,M:an},p:0,findDOMNode:null},_0=Symbol.for("react.portal");wi=kf.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE;Lf=Oe});var ed=Br(function(cE,Pf){Wf();function If(){if(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__>"u"||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!=="function")return;try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(If)}catch(e){console.error(e)}}If(),Pf.exports=cs});var Vc={};bf(Vc,{createRoot:()=>cv,hydrateRoot:()=>fv,version:()=>dv});function S(e){var t="https://react.dev/errors/"+e;if(1<arguments.length){t+="?args[]="+encodeURIComponent(arguments[1]);for(var n=2;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."}function Nh(e){return!(!e||e.nodeType!==1&&e.nodeType!==9&&e.nodeType!==11)}function hl(e){var t=e,n=e;if(e.alternate)for(;t.return;)t=t.return;else{e=t;do t=e,(t.flags&4098)!==0&&(n=t.return),e=t.return;while(e)}return t.tag===3?n:null}function Oh(e){if(e.tag===13){var t=e.memoizedState;if(t===null&&(e=e.alternate,e!==null&&(t=e.memoizedState)),t!==null)return t.dehydrated}return null}function Ah(e){if(e.tag===31){var t=e.memoizedState;if(t===null&&(e=e.alternate,e!==null&&(t=e.memoizedState)),t!==null)return t.dehydrated}return null}function td(e){if(hl(e)!==e)throw Error(S(188))}function x0(e){var t=e.alternate;if(!t){if(t=hl(e),t===null)throw Error(S(188));return t!==e?null:e}for(var n=e,a=t;;){var i=n.return;if(i===null)break;var l=i.alternate;if(l===null){if(a=i.return,a!==null){n=a;continue}break}if(i.child===l.child){for(l=i.child;l;){if(l===n)return td(i),e;if(l===a)return td(i),t;l=l.sibling}throw Error(S(188))}if(n.return!==a.return)n=i,a=l;else{for(var o=!1,r=i.child;r;){if(r===n){o=!0,n=i,a=l;break}if(r===a){o=!0,a=i,n=l;break}r=r.sibling}if(!o){for(r=l.child;r;){if(r===n){o=!0,n=l,a=i;break}if(r===a){o=!0,a=l,n=i;break}r=r.sibling}if(!o)throw Error(S(189))}}if(n.alternate!==a)throw Error(S(190))}if(n.tag!==3)throw Error(S(188));return n.stateNode.current===n?e:t}function Th(e){var t=e.tag;if(t===5||t===26||t===27||t===6)return e;for(e=e.child;e!==null;){if(t=Th(e),t!==null)return t;e=e.sibling}return null}function Ni(e){if(e===null||typeof e!=="object")return null;return e=nd&&e[nd]||e["@@iterator"],typeof e==="function"?e:null}function Zs(e){if(e==null)return null;if(typeof e==="function")return e.$$typeof===N0?null:e.displayName||e.name||null;if(typeof e==="string")return e;switch(e){case wa:return"Fragment";case Ys:return"Profiler";case Dh:return"StrictMode";case Ks:return"Suspense";case Xs:return"SuspenseList";case Qs:return"Activity"}if(typeof e==="object")switch(e.$$typeof){case Ri:return"Portal";case Lt:return e.displayName||"Context";case zh:return(e._context.displayName||"Context")+".Consumer";case ju:var t=e.render;return e=e.displayName,e||(e=t.displayName||t.name||"",e=e!==""?"ForwardRef("+e+")":"ForwardRef"),e;case qu:return t=e.displayName||null,t!==null?t:Zs(e.type)||"Memo";case ln:t=e._payload,e=e._init;try{return Zs(e(t))}catch(n){}}return null}function Nt(e){return{current:e}}function be(e){0>Na||(e.current=$s[Na],$s[Na]=null,Na--)}function W(e,t){Na++,$s[Na]=e.current,e.current=t}function So(e,t){switch(W(vn,t),W(Pi,e),W(wt,null),t.nodeType){case 9:case 11:e=(e=t.documentElement)?(e=e.namespaceURI)?rh(e):0:0;break;default:if(e=t.tagName,t=t.namespaceURI)t=rh(t),e=Fm(t,e);else switch(e){case"svg":e=1;break;case"math":e=2;break;default:e=0}}be(wt),W(wt,e)}function Ya(){be(wt),be(Pi),be(vn)}function Js(e){e.memoizedState!==null&&W(_o,e);var t=wt.current,n=Fm(t,e.type);t!==n&&(W(Pi,e),W(wt,n))}function xo(e){Pi.current===e&&(be(wt),be(Pi)),_o.current===e&&(be(_o),cl._currentValue=Qn)}function qn(e){if(fs===void 0)try{throw Error()}catch(n){var t=n.stack.trim().match(/\n( *(at )?)/);fs=t&&t[1]||"",ad=-1<n.stack.indexOf(`
2
2
  at`)?" (<anonymous>)":-1<n.stack.indexOf("@")?"@unknown:0:0":""}return`
3
- `+Xo+t+Cf}function Zo(t,e){if(!t||Qo)return"";Qo=!0;var n=Error.prepareStackTrace;Error.prepareStackTrace=void 0;try{var l={DetermineComponentFrameRoot:function(){try{if(e){var g=function(){throw Error()};if(Object.defineProperty(g.prototype,"props",{set:function(){throw Error()}}),typeof Reflect==="object"&&Reflect.construct){try{Reflect.construct(g,[])}catch(v){var d=v}Reflect.construct(t,[],g)}else{try{g.call()}catch(v){d=v}t.call(g.prototype)}}else{try{throw Error()}catch(v){d=v}(g=t())&&typeof g.catch==="function"&&g.catch(function(){})}}catch(v){if(v&&d&&typeof v.stack==="string")return[v.stack,d.stack]}return[null,null]}};l.DetermineComponentFrameRoot.displayName="DetermineComponentFrameRoot";var a=Object.getOwnPropertyDescriptor(l.DetermineComponentFrameRoot,"name");a&&a.configurable&&Object.defineProperty(l.DetermineComponentFrameRoot,"name",{value:"DetermineComponentFrameRoot"});var i=l.DetermineComponentFrameRoot(),u=i[0],o=i[1];if(u&&o){var r=u.split(`
4
- `),s=o.split(`
5
- `);for(a=l=0;l<r.length&&!r[l].includes("DetermineComponentFrameRoot");)l++;for(;a<s.length&&!s[a].includes("DetermineComponentFrameRoot");)a++;if(l===r.length||a===s.length)for(l=r.length-1,a=s.length-1;1<=l&&0<=a&&r[l]!==s[a];)a--;for(;1<=l&&0<=a;l--,a--)if(r[l]!==s[a]){if(l!==1||a!==1)do if(l--,a--,0>a||r[l]!==s[a]){var h=`
6
- `+r[l].replace(" at new "," at ");return t.displayName&&h.includes("<anonymous>")&&(h=h.replace("<anonymous>",t.displayName)),h}while(1<=l&&0<=a);break}}}finally{Qo=!1,Error.prepareStackTrace=n}return(n=t?t.displayName||t.name:"")?wn(n):""}function Tb(t,e){switch(t.tag){case 26:case 27:case 5:return wn(t.type);case 16:return wn("Lazy");case 13:return t.child!==e&&e!==null?wn("Suspense Fallback"):wn("Suspense");case 19:return wn("SuspenseList");case 0:case 15:return Zo(t.type,!1);case 11:return Zo(t.type.render,!1);case 1:return Zo(t.type,!0);case 31:return wn("Activity");default:return""}}function Uf(t){try{var e="",n=null;do e+=Tb(t,n),n=t,t=t.return;while(t);return e}catch(l){return`
7
- Error generating stack: `+l.message+`
8
- `+l.stack}}function nn(t){if(typeof Cb==="function"&&Ub(t),Vt&&typeof Vt.setStrictMode==="function")try{Vt.setStrictMode(ei,t)}catch(e){}}function qb(t){return t>>>=0,t===0?32:31-(Vb(t)/Bb|0)|0}function Rn(t){var e=t&42;if(e!==0)return e;switch(t&-t){case 1:return 1;case 2:return 2;case 4:return 4;case 8:return 8;case 16:return 16;case 32:return 32;case 64:return 64;case 128:return 128;case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:return t&261888;case 262144:case 524288:case 1048576:case 2097152:return t&3932160;case 4194304:case 8388608:case 16777216:case 33554432:return t&62914560;case 67108864:return 67108864;case 134217728:return 134217728;case 268435456:return 268435456;case 536870912:return 536870912;case 1073741824:return 0;default:return t}}function Uu(t,e,n){var l=t.pendingLanes;if(l===0)return 0;var a=0,i=t.suspendedLanes,u=t.pingedLanes;t=t.warmLanes;var o=l&134217727;return o!==0?(l=o&~i,l!==0?a=Rn(l):(u&=o,u!==0?a=Rn(u):n||(n=o&~t,n!==0&&(a=Rn(n))))):(o=l&~i,o!==0?a=Rn(o):u!==0?a=Rn(u):n||(n=l&~t,n!==0&&(a=Rn(n)))),a===0?0:e!==0&&e!==a&&(e&i)===0&&(i=a&-a,n=e&-e,i>=n||i===32&&(n&4194048)!==0)?e:a}function ni(t,e){return(t.pendingLanes&~(t.suspendedLanes&~t.pingedLanes)&e)===0}function jb(t,e){switch(t){case 1:case 2:case 4:case 8:case 64:return e+250;case 16:case 32:case 128:case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:return e+5000;case 4194304:case 8388608:case 16777216:case 33554432:return-1;case 67108864:case 134217728:case 268435456:case 536870912:case 1073741824:return-1;default:return-1}}function ch(){var t=Ri;return Ri<<=1,(Ri&62914560)===0&&(Ri=4194304),t}function Jo(t){for(var e=[],n=0;31>n;n++)e.push(t);return e}function li(t,e){t.pendingLanes|=e,e!==268435456&&(t.suspendedLanes=0,t.pingedLanes=0,t.warmLanes=0)}function Hb(t,e,n,l,a,i){var u=t.pendingLanes;t.pendingLanes=n,t.suspendedLanes=0,t.pingedLanes=0,t.warmLanes=0,t.expiredLanes&=n,t.entangledLanes&=n,t.errorRecoveryDisabledLanes&=n,t.shellSuspendCounter=0;var{entanglements:o,expirationTimes:r,hiddenUpdates:s}=t;for(n=u&~n;0<n;){var h=31-Bt(n),g=1<<h;o[h]=0,r[h]=-1;var d=s[h];if(d!==null)for(s[h]=null,h=0;h<d.length;h++){var v=d[h];v!==null&&(v.lane&=-536870913)}n&=~g}l!==0&&fh(t,l,0),i!==0&&a===0&&t.tag!==0&&(t.suspendedLanes|=i&~(u&~e))}function fh(t,e,n){t.pendingLanes|=e,t.suspendedLanes&=~e;var l=31-Bt(e);t.entangledLanes|=e,t.entanglements[l]=t.entanglements[l]|1073741824|n&261930}function dh(t,e){var n=t.entangledLanes|=e;for(t=t.entanglements;n;){var l=31-Bt(n),a=1<<l;a&e|t[l]&e&&(t[l]|=e),n&=~a}}function hh(t,e){var n=e&-e;return n=(n&42)!==0?1:Es(n),(n&(t.suspendedLanes|e))!==0?0:n}function Es(t){switch(t){case 2:t=1;break;case 8:t=4;break;case 32:t=16;break;case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:case 4194304:case 8388608:case 16777216:case 33554432:t=128;break;case 268435456:t=134217728;break;default:t=0}return t}function Os(t){return t&=-t,2<t?8<t?(t&134217727)!==0?32:268435456:8:2}function ph(){var t=L.p;if(t!==0)return t;return t=window.event,t===void 0?32:qm(t.type)}function Vf(t,e){var n=L.p;try{return L.p=t,e()}finally{L.p=n}}function Ns(t){delete t[mt],delete t[Tt],delete t[wr],delete t[Lb],delete t[Gb]}function ml(t){var e=t[mt];if(e)return e;for(var n=t.parentNode;n;){if(e=n[Kl]||n[mt]){if(n=e.alternate,e.child!==null||n!==null&&n.child!==null)for(t=Yd(t);t!==null;){if(n=t[mt])return n;t=Yd(t)}return e}t=n,n=t.parentNode}return null}function Xl(t){if(t=t[mt]||t[Kl]){var e=t.tag;if(e===5||e===6||e===13||e===31||e===26||e===27||e===3)return t}return null}function _a(t){var e=t.tag;if(e===5||e===26||e===27||e===6)return t.stateNode;throw Error(_(33))}function xl(t){var e=t[Bf];return e||(e=t[Bf]={hoistableStyles:new Map,hoistableScripts:new Map}),e}function dt(t){t[ai]=!0}function Qn(t,e){Cl(t,e),Cl(t+"Capture",e)}function Cl(t,e){vh[t]=e;for(t=0;t<e.length;t++)mh.add(e[t])}function Kb(t){if(zr.call(jf,t))return!0;if(zr.call(qf,t))return!1;if(Yb.test(t))return jf[t]=!0;return qf[t]=!0,!1}function Yi(t,e,n){if(Kb(e))if(n===null)t.removeAttribute(e);else{switch(typeof n){case"undefined":case"function":case"symbol":t.removeAttribute(e);return;case"boolean":var l=e.toLowerCase().slice(0,5);if(l!=="data-"&&l!=="aria-"){t.removeAttribute(e);return}}t.setAttribute(e,""+n)}}function Mi(t,e,n){if(n===null)t.removeAttribute(e);else{switch(typeof n){case"undefined":case"function":case"symbol":case"boolean":t.removeAttribute(e);return}t.setAttribute(e,""+n)}}function Oe(t,e,n,l){if(l===null)t.removeAttribute(n);else{switch(typeof l){case"undefined":case"function":case"symbol":case"boolean":t.removeAttribute(n);return}t.setAttributeNS(e,n,""+l)}}function Qt(t){switch(typeof t){case"bigint":case"boolean":case"number":case"string":case"undefined":return t;case"object":return t;default:return""}}function gh(t){var e=t.type;return(t=t.nodeName)&&t.toLowerCase()==="input"&&(e==="checkbox"||e==="radio")}function Xb(t,e,n){var l=Object.getOwnPropertyDescriptor(t.constructor.prototype,e);if(!t.hasOwnProperty(e)&&typeof l<"u"&&typeof l.get==="function"&&typeof l.set==="function"){var{get:a,set:i}=l;return Object.defineProperty(t,e,{configurable:!0,get:function(){return a.call(this)},set:function(u){n=""+u,i.call(this,u)}}),Object.defineProperty(t,e,{enumerable:l.enumerable}),{getValue:function(){return n},setValue:function(u){n=""+u},stopTracking:function(){t._valueTracker=null,delete t[e]}}}}function Rr(t){if(!t._valueTracker){var e=gh(t)?"checked":"value";t._valueTracker=Xb(t,e,""+t[e])}}function yh(t){if(!t)return!1;var e=t._valueTracker;if(!e)return!0;var n=e.getValue(),l="";return t&&(l=gh(t)?t.checked?"true":"false":t.value),t=l,t!==n?(e.setValue(t),!0):!1}function ru(t){if(t=t||(typeof document<"u"?document:void 0),typeof t>"u")return null;try{return t.activeElement||t.body}catch(e){return t.body}}function Jt(t){return t.replace(Qb,function(e){return"\\"+e.charCodeAt(0).toString(16)+" "})}function Mr(t,e,n,l,a,i,u,o){if(t.name="",u!=null&&typeof u!=="function"&&typeof u!=="symbol"&&typeof u!=="boolean"?t.type=u:t.removeAttribute("type"),e!=null)if(u==="number"){if(e===0&&t.value===""||t.value!=e)t.value=""+Qt(e)}else t.value!==""+Qt(e)&&(t.value=""+Qt(e));else u!=="submit"&&u!=="reset"||t.removeAttribute("value");e!=null?Cr(t,u,Qt(e)):n!=null?Cr(t,u,Qt(n)):l!=null&&t.removeAttribute("value"),a==null&&i!=null&&(t.defaultChecked=!!i),a!=null&&(t.checked=a&&typeof a!=="function"&&typeof a!=="symbol"),o!=null&&typeof o!=="function"&&typeof o!=="symbol"&&typeof o!=="boolean"?t.name=""+Qt(o):t.removeAttribute("name")}function bh(t,e,n,l,a,i,u,o){if(i!=null&&typeof i!=="function"&&typeof i!=="symbol"&&typeof i!=="boolean"&&(t.type=i),e!=null||n!=null){if(!(i!=="submit"&&i!=="reset"||e!==void 0&&e!==null)){Rr(t);return}n=n!=null?""+Qt(n):"",e=e!=null?""+Qt(e):n,o||e===t.value||(t.value=e),t.defaultValue=e}l=l!=null?l:a,l=typeof l!=="function"&&typeof l!=="symbol"&&!!l,t.checked=o?t.checked:!!l,t.defaultChecked=!!l,u!=null&&typeof u!=="function"&&typeof u!=="symbol"&&typeof u!=="boolean"&&(t.name=u),Rr(t)}function Cr(t,e,n){e==="number"&&ru(t.ownerDocument)===t||t.defaultValue===""+n||(t.defaultValue=""+n)}function Al(t,e,n,l){if(t=t.options,e){e={};for(var a=0;a<n.length;a++)e["$"+n[a]]=!0;for(n=0;n<t.length;n++)a=e.hasOwnProperty("$"+t[n].value),t[n].selected!==a&&(t[n].selected=a),a&&l&&(t[n].defaultSelected=!0)}else{n=""+Qt(n),e=null;for(a=0;a<t.length;a++){if(t[a].value===n){t[a].selected=!0,l&&(t[a].defaultSelected=!0);return}e!==null||t[a].disabled||(e=t[a])}e!==null&&(e.selected=!0)}}function _h(t,e,n){if(e!=null&&(e=""+Qt(e),e!==t.value&&(t.value=e),n==null)){t.defaultValue!==e&&(t.defaultValue=e);return}t.defaultValue=n!=null?""+Qt(n):""}function Sh(t,e,n,l){if(e==null){if(l!=null){if(n!=null)throw Error(_(92));if(ba(l)){if(1<l.length)throw Error(_(93));l=l[0]}n=l}n==null&&(n=""),e=n}n=Qt(e),t.defaultValue=n,l=t.textContent,l===n&&l!==""&&l!==null&&(t.value=l),Rr(t)}function Ul(t,e){if(e){var n=t.firstChild;if(n&&n===t.lastChild&&n.nodeType===3){n.nodeValue=e;return}}t.textContent=e}function Hf(t,e,n){var l=e.indexOf("--")===0;n==null||typeof n==="boolean"||n===""?l?t.setProperty(e,""):e==="float"?t.cssFloat="":t[e]="":l?t.setProperty(e,n):typeof n!=="number"||n===0||Zb.has(e)?e==="float"?t.cssFloat=n:t[e]=(""+n).trim():t[e]=n+"px"}function Eh(t,e,n){if(e!=null&&typeof e!=="object")throw Error(_(62));if(t=t.style,n!=null){for(var l in n)!n.hasOwnProperty(l)||e!=null&&e.hasOwnProperty(l)||(l.indexOf("--")===0?t.setProperty(l,""):l==="float"?t.cssFloat="":t[l]="");for(var a in e)l=e[a],e.hasOwnProperty(a)&&n[a]!==l&&Hf(t,a,l)}else for(var i in e)e.hasOwnProperty(i)&&Hf(t,i,e[i])}function xs(t){if(t.indexOf("-")===-1)return!1;switch(t){case"annotation-xml":case"color-profile":case"font-face":case"font-face-src":case"font-face-uri":case"font-face-format":case"font-face-name":case"missing-glyph":return!1;default:return!0}}function Ki(t){return Jb.test(""+t)?"javascript:throw new Error('React has blocked a javascript: URL as a security precaution.')":t}function Re(){}function As(t){return t=t.target||t.srcElement||window,t.correspondingUseElement&&(t=t.correspondingUseElement),t.nodeType===3?t.parentNode:t}function Lf(t){var e=Xl(t);if(e&&(t=e.stateNode)){var n=t[Tt]||null;t:switch(t=e.stateNode,e.type){case"input":if(Mr(t,n.value,n.defaultValue,n.defaultValue,n.checked,n.defaultChecked,n.type,n.name),e=n.name,n.type==="radio"&&e!=null){for(n=t;n.parentNode;)n=n.parentNode;n=n.querySelectorAll('input[name="'+Jt(""+e)+'"][type="radio"]');for(e=0;e<n.length;e++){var l=n[e];if(l!==t&&l.form===t.form){var a=l[Tt]||null;if(!a)throw Error(_(90));Mr(l,a.value,a.defaultValue,a.defaultValue,a.checked,a.defaultChecked,a.type,a.name)}}for(e=0;e<n.length;e++)l=n[e],l.form===t.form&&yh(l)}break t;case"textarea":_h(t,n.value,n.defaultValue);break t;case"select":e=n.value,e!=null&&Al(t,!!n.multiple,e,!1)}}}function Oh(t,e,n){if($o)return t(e,n);$o=!0;try{var l=t(e);return l}finally{if($o=!1,vl!==null||Dl!==null){if(Zu(),vl&&(e=vl,t=Dl,Dl=vl=null,Lf(e),t))for(e=0;e<t.length;e++)Lf(t[e])}}}function Ga(t,e){var n=t.stateNode;if(n===null)return null;var l=n[Tt]||null;if(l===null)return null;n=l[e];t:switch(e){case"onClick":case"onClickCapture":case"onDoubleClick":case"onDoubleClickCapture":case"onMouseDown":case"onMouseDownCapture":case"onMouseMove":case"onMouseMoveCapture":case"onMouseUp":case"onMouseUpCapture":case"onMouseEnter":(l=!l.disabled)||(t=t.type,l=!(t==="button"||t==="input"||t==="select"||t==="textarea")),t=!l;break t;default:t=!1}if(t)return null;if(n&&typeof n!=="function")throw Error(_(231,e,typeof n));return n}function Nh(){if(Xi)return Xi;var t,e=Ds,n=e.length,l,a="value"in ln?ln.value:ln.textContent,i=a.length;for(t=0;t<n&&e[t]===a[t];t++);var u=n-t;for(l=1;l<=u&&e[n-l]===a[i-l];l++);return Xi=a.slice(t,1<l?1-l:void 0)}function Qi(t){var e=t.keyCode;return"charCode"in t?(t=t.charCode,t===0&&e===13&&(t=13)):t=e,t===10&&(t=13),32<=t||t===13?t:0}function Ci(){return!0}function Gf(){return!1}function zt(t){function e(n,l,a,i,u){this._reactName=n,this._targetInst=a,this.type=l,this.nativeEvent=i,this.target=u,this.currentTarget=null;for(var o in t)t.hasOwnProperty(o)&&(n=t[o],this[o]=n?n(i):i[o]);return this.isDefaultPrevented=(i.defaultPrevented!=null?i.defaultPrevented:i.returnValue===!1)?Ci:Gf,this.isPropagationStopped=Gf,this}return P(e.prototype,{preventDefault:function(){this.defaultPrevented=!0;var n=this.nativeEvent;n&&(n.preventDefault?n.preventDefault():typeof n.returnValue!=="unknown"&&(n.returnValue=!1),this.isDefaultPrevented=Ci)},stopPropagation:function(){var n=this.nativeEvent;n&&(n.stopPropagation?n.stopPropagation():typeof n.cancelBubble!=="unknown"&&(n.cancelBubble=!0),this.isPropagationStopped=Ci)},persist:function(){},isPersistent:Ci}),e}function o0(t){var e=this.nativeEvent;return e.getModifierState?e.getModifierState(t):(t=u0[t])?!!e[t]:!1}function Ts(){return o0}function Ah(t,e){switch(t){case"keyup":return b0.indexOf(e.keyCode)!==-1;case"keydown":return e.keyCode!==229;case"keypress":case"mousedown":case"focusout":return!0;default:return!1}}function Dh(t){return t=t.detail,typeof t==="object"&&"data"in t?t.data:null}function S0(t,e){switch(t){case"compositionend":return Dh(e);case"keypress":if(e.which!==32)return null;return Zf=!0,Qf;case"textInput":return t=e.data,t===Qf&&Zf?null:t;default:return null}}function E0(t,e){if(gl)return t==="compositionend"||!zs&&Ah(t,e)?(t=Nh(),Xi=Ds=ln=null,gl=!1,t):null;switch(t){case"paste":return null;case"keypress":if(!(e.ctrlKey||e.altKey||e.metaKey)||e.ctrlKey&&e.altKey){if(e.char&&1<e.char.length)return e.char;if(e.which)return String.fromCharCode(e.which)}return null;case"compositionend":return xh&&e.locale!=="ko"?null:e.data;default:return null}}function kf(t){var e=t&&t.nodeName&&t.nodeName.toLowerCase();return e==="input"?!!O0[t.type]:e==="textarea"?!0:!1}function Th(t,e,n,l){vl?Dl?Dl.push(l):Dl=[l]:vl=l,e=Au(e,"onChange"),0<e.length&&(n=new Vu("onChange","change",null,n,l),t.push({event:n,listeners:e}))}function N0(t){Om(t,0)}function qu(t){var e=_a(t);if(yh(e))return t}function Jf(t,e){if(t==="change")return e}function $f(){Ta&&(Ta.detachEvent("onpropertychange",wh),Ya=Ta=null)}function wh(t){if(t.propertyName==="value"&&qu(Ya)){var e=[];Th(e,Ya,t,As(t)),Oh(N0,e)}}function x0(t,e,n){t==="focusin"?($f(),Ta=e,Ya=n,Ta.attachEvent("onpropertychange",wh)):t==="focusout"&&$f()}function A0(t){if(t==="selectionchange"||t==="keyup"||t==="keydown")return qu(Ya)}function D0(t,e){if(t==="click")return qu(e)}function T0(t,e){if(t==="input"||t==="change")return qu(e)}function z0(t,e){return t===e&&(t!==0||1/t===1/e)||t!==t&&e!==e}function Ka(t,e){if(jt(t,e))return!0;if(typeof t!=="object"||t===null||typeof e!=="object"||e===null)return!1;var n=Object.keys(t),l=Object.keys(e);if(n.length!==l.length)return!1;for(l=0;l<n.length;l++){var a=n[l];if(!zr.call(e,a)||!jt(t[a],e[a]))return!1}return!0}function Wf(t){for(;t&&t.firstChild;)t=t.firstChild;return t}function Ff(t,e){var n=Wf(t);t=0;for(var l;n;){if(n.nodeType===3){if(l=t+n.textContent.length,t<=e&&l>=e)return{node:n,offset:e-t};t=l}t:{for(;n;){if(n.nextSibling){n=n.nextSibling;break t}n=n.parentNode}n=void 0}n=Wf(n)}}function Rh(t,e){return t&&e?t===e?!0:t&&t.nodeType===3?!1:e&&e.nodeType===3?Rh(t,e.parentNode):("contains"in t)?t.contains(e):t.compareDocumentPosition?!!(t.compareDocumentPosition(e)&16):!1:!1}function Mh(t){t=t!=null&&t.ownerDocument!=null&&t.ownerDocument.defaultView!=null?t.ownerDocument.defaultView:window;for(var e=ru(t.document);e instanceof t.HTMLIFrameElement;){try{var n=typeof e.contentWindow.location.href==="string"}catch(l){n=!1}if(n)t=e.contentWindow;else break;e=ru(t.document)}return e}function ws(t){var e=t&&t.nodeName&&t.nodeName.toLowerCase();return e&&(e==="input"&&(t.type==="text"||t.type==="search"||t.type==="tel"||t.type==="url"||t.type==="password")||e==="textarea"||t.contentEditable==="true")}function If(t,e,n){var l=n.window===n?n.document:n.nodeType===9?n:n.ownerDocument;qr||yl==null||yl!==ru(l)||(l=yl,("selectionStart"in l)&&ws(l)?l={start:l.selectionStart,end:l.selectionEnd}:(l=(l.ownerDocument&&l.ownerDocument.defaultView||window).getSelection(),l={anchorNode:l.anchorNode,anchorOffset:l.anchorOffset,focusNode:l.focusNode,focusOffset:l.focusOffset}),za&&Ka(za,l)||(za=l,l=Au(Br,"onSelect"),0<l.length&&(e=new Vu("onSelect","select",null,e,n),t.push({event:e,listeners:l}),e.target=yl)))}function zn(t,e){var n={};return n[t.toLowerCase()]=e.toLowerCase(),n["Webkit"+t]="webkit"+e,n["Moz"+t]="moz"+e,n}function kn(t){if(Po[t])return Po[t];if(!bl[t])return t;var e=bl[t],n;for(n in e)if(e.hasOwnProperty(n)&&n in Ch)return Po[t]=e[n];return t}function ue(t,e){jh.set(t,e),Qn(e,[t])}function ju(){for(var t=_l,e=Rs=_l=0;e<t;){var n=Xt[e];Xt[e++]=null;var l=Xt[e];Xt[e++]=null;var a=Xt[e];Xt[e++]=null;var i=Xt[e];if(Xt[e++]=null,l!==null&&a!==null){var u=l.pending;u===null?a.next=a:(a.next=u.next,u.next=a),l.pending=a}i!==0&&Hh(n,a,i)}}function Hu(t,e,n,l){Xt[_l++]=t,Xt[_l++]=e,Xt[_l++]=n,Xt[_l++]=l,Rs|=l,t.lanes|=l,t=t.alternate,t!==null&&(t.lanes|=l)}function Ms(t,e,n,l){return Hu(t,e,n,l),cu(t)}function Jn(t,e){return Hu(t,null,null,e),cu(t)}function Hh(t,e,n){t.lanes|=n;var l=t.alternate;l!==null&&(l.lanes|=n);for(var a=!1,i=t.return;i!==null;)i.childLanes|=n,l=i.alternate,l!==null&&(l.childLanes|=n),i.tag===22&&(t=i.stateNode,t===null||t._visibility&1||(a=!0)),t=i,i=i.return;return t.tag===3?(i=t.stateNode,a&&e!==null&&(a=31-Bt(n),t=i.hiddenUpdates,l=t[a],l===null?t[a]=[e]:l.push(e),e.lane=n|536870912),i):null}function cu(t){if(50<ja)throw ja=0,is=null,Error(_(185));for(var e=t.return;e!==null;)t=e,e=t.return;return t.tag===3?t.stateNode:null}function U0(t,e,n,l){this.tag=t,this.key=n,this.sibling=this.child=this.return=this.stateNode=this.type=this.elementType=null,this.index=0,this.refCleanup=this.ref=null,this.pendingProps=e,this.dependencies=this.memoizedState=this.updateQueue=this.memoizedProps=null,this.mode=l,this.subtreeFlags=this.flags=0,this.deletions=null,this.childLanes=this.lanes=0,this.alternate=null}function Mt(t,e,n,l){return new U0(t,e,n,l)}function Cs(t){return t=t.prototype,!(!t||!t.isReactComponent)}function Ce(t,e){var n=t.alternate;return n===null?(n=Mt(t.tag,e,t.key,t.mode),n.elementType=t.elementType,n.type=t.type,n.stateNode=t.stateNode,n.alternate=t,t.alternate=n):(n.pendingProps=e,n.type=t.type,n.flags=0,n.subtreeFlags=0,n.deletions=null),n.flags=t.flags&65011712,n.childLanes=t.childLanes,n.lanes=t.lanes,n.child=t.child,n.memoizedProps=t.memoizedProps,n.memoizedState=t.memoizedState,n.updateQueue=t.updateQueue,e=t.dependencies,n.dependencies=e===null?null:{lanes:e.lanes,firstContext:e.firstContext},n.sibling=t.sibling,n.index=t.index,n.ref=t.ref,n.refCleanup=t.refCleanup,n}function Lh(t,e){t.flags&=65011714;var n=t.alternate;return n===null?(t.childLanes=0,t.lanes=e,t.child=null,t.subtreeFlags=0,t.memoizedProps=null,t.memoizedState=null,t.updateQueue=null,t.dependencies=null,t.stateNode=null):(t.childLanes=n.childLanes,t.lanes=n.lanes,t.child=n.child,t.subtreeFlags=0,t.deletions=null,t.memoizedProps=n.memoizedProps,t.memoizedState=n.memoizedState,t.updateQueue=n.updateQueue,t.type=n.type,e=n.dependencies,t.dependencies=e===null?null:{lanes:e.lanes,firstContext:e.firstContext}),t}function ki(t,e,n,l,a,i){var u=0;if(l=t,typeof t==="function")Cs(t)&&(u=1);else if(typeof t==="string")u=q_(t,n,ve.current)?26:t==="html"||t==="head"||t==="body"?27:5;else t:switch(t){case xr:return t=Mt(31,n,e,a),t.elementType=xr,t.lanes=i,t;case hl:return Bn(n.children,a,i,e);case ih:u=8,a|=24;break;case Er:return t=Mt(12,n,e,a|2),t.elementType=Er,t.lanes=i,t;case Or:return t=Mt(13,n,e,a),t.elementType=Or,t.lanes=i,t;case Nr:return t=Mt(19,n,e,a),t.elementType=Nr,t.lanes=i,t;default:if(typeof t==="object"&&t!==null)switch(t.$$typeof){case we:u=10;break t;case uh:u=9;break t;case bs:u=11;break t;case _s:u=14;break t;case We:u=16,l=null;break t}u=29,n=Error(_(130,t===null?"null":typeof t,"")),l=null}return e=Mt(u,n,e,a),e.elementType=t,e.type=l,e.lanes=i,e}function Bn(t,e,n,l){return t=Mt(7,t,l,e),t.lanes=n,t}function tr(t,e,n){return t=Mt(6,t,null,e),t.lanes=n,t}function Gh(t){var e=Mt(18,null,null,0);return e.stateNode=t,e}function er(t,e,n){return e=Mt(4,t.children!==null?t.children:[],t.key,e),e.lanes=n,e.stateNode={containerInfo:t.containerInfo,pendingChildren:null,implementation:t.implementation},e}function $t(t,e){if(typeof t==="object"&&t!==null){var n=Pf.get(t);if(n!==void 0)return n;return e={value:t,source:e,stack:Uf(e)},Pf.set(t,e),e}return{value:t,source:e,stack:Uf(e)}}function Te(t,e){El[Ol++]=Xa,El[Ol++]=fu,fu=t,Xa=e}function Yh(t,e,n){Zt[kt++]=he,Zt[kt++]=pe,Zt[kt++]=gn,gn=t;var l=he;t=pe;var a=32-Bt(l)-1;l&=~(1<<a),n+=1;var i=32-Bt(e)+a;if(30<i){var u=a-a%5;i=(l&(1<<u)-1).toString(32),l>>=u,a-=u,he=1<<32-Bt(e)+a|n<<a|l,pe=i+t}else he=1<<i|n<<a|l,pe=t}function Us(t){t.return!==null&&(Te(t,1),Yh(t,1,0))}function Vs(t){for(;t===fu;)fu=El[--Ol],El[Ol]=null,Xa=El[--Ol],El[Ol]=null;for(;t===gn;)gn=Zt[--kt],Zt[kt]=null,pe=Zt[--kt],Zt[kt]=null,he=Zt[--kt],Zt[kt]=null}function Kh(t,e){Zt[kt++]=he,Zt[kt++]=pe,Zt[kt++]=gn,he=e.id,pe=e.overflow,gn=t}function yn(t){var e=Error(_(418,1<arguments.length&&arguments[1]!==void 0&&arguments[1]?"text":"HTML",""));throw Qa($t(e,t)),Hr}function td(t){var{stateNode:e,type:n,memoizedProps:l}=t;switch(e[mt]=t,e[Tt]=l,n){case"dialog":U("cancel",e),U("close",e);break;case"iframe":case"object":case"embed":U("load",e);break;case"video":case"audio":for(n=0;n<$a.length;n++)U($a[n],e);break;case"source":U("error",e);break;case"img":case"image":case"link":U("error",e),U("load",e);break;case"details":U("toggle",e);break;case"input":U("invalid",e),bh(e,l.value,l.defaultValue,l.checked,l.defaultChecked,l.type,l.name,!0);break;case"select":U("invalid",e);break;case"textarea":U("invalid",e),Sh(e,l.value,l.defaultValue,l.children)}n=l.children,typeof n!=="string"&&typeof n!=="number"&&typeof n!=="bigint"||e.textContent===""+n||l.suppressHydrationWarning===!0||xm(e.textContent,n)?(l.popover!=null&&(U("beforetoggle",e),U("toggle",e)),l.onScroll!=null&&U("scroll",e),l.onScrollEnd!=null&&U("scrollend",e),l.onClick!=null&&(e.onclick=Re),e=!0):e=!1,e||yn(t,!0)}function ed(t){for(vt=t.return;vt;)switch(vt.tag){case 5:case 31:case 13:Wt=!1;return;case 27:case 3:Wt=!0;return;default:vt=vt.return}}function rl(t){if(t!==vt)return!1;if(!q)return ed(t),q=!0,!1;var e=t.tag,n;if(n=e!==3&&e!==27){if(n=e===5)n=t.type,n=!(n!=="form"&&n!=="button")||ds(t.type,t.memoizedProps);n=!n}if(n&&I&&yn(t),ed(t),e===13){if(t=t.memoizedState,t=t!==null?t.dehydrated:null,!t)throw Error(_(317));I=Gd(t)}else if(e===31){if(t=t.memoizedState,t=t!==null?t.dehydrated:null,!t)throw Error(_(317));I=Gd(t)}else e===27?(e=I,En(t.type)?(t=vs,vs=null,I=t):I=e):I=vt?It(t.stateNode.nextSibling):null;return!0}function Ln(){I=vt=null,q=!1}function nr(){var t=sn;return t!==null&&(At===null?At=t:At.push.apply(At,t),sn=null),t}function Qa(t){sn===null?sn=[t]:sn.push(t)}function Ie(t,e,n){k(Lr,e._currentValue),e._currentValue=n}function Ue(t){t._currentValue=Lr.current,ht(Lr)}function Gr(t,e,n){for(;t!==null;){var l=t.alternate;if((t.childLanes&e)!==e?(t.childLanes|=e,l!==null&&(l.childLanes|=e)):l!==null&&(l.childLanes&e)!==e&&(l.childLanes|=e),t===n)break;t=t.return}}function Yr(t,e,n,l){var a=t.child;a!==null&&(a.return=t);for(;a!==null;){var i=a.dependencies;if(i!==null){var u=a.child;i=i.firstContext;t:for(;i!==null;){var o=i;i=a;for(var r=0;r<e.length;r++)if(o.context===e[r]){i.lanes|=n,o=i.alternate,o!==null&&(o.lanes|=n),Gr(i.return,n,t),l||(u=null);break t}i=o.next}}else if(a.tag===18){if(u=a.return,u===null)throw Error(_(341));u.lanes|=n,i=u.alternate,i!==null&&(i.lanes|=n),Gr(u,n,t),u=null}else u=a.child;if(u!==null)u.return=a;else for(u=a;u!==null;){if(u===t){u=null;break}if(a=u.sibling,a!==null){a.return=u.return,u=a;break}u=u.return}a=u}}function Ql(t,e,n,l){t=null;for(var a=e,i=!1;a!==null;){if(!i){if((a.flags&524288)!==0)i=!0;else if((a.flags&262144)!==0)break}if(a.tag===10){var u=a.alternate;if(u===null)throw Error(_(387));if(u=u.memoizedProps,u!==null){var o=a.type;jt(a.pendingProps.value,u.value)||(t!==null?t.push(o):t=[o])}}else if(a===au.current){if(u=a.alternate,u===null)throw Error(_(387));u.memoizedState.memoizedState!==a.memoizedState.memoizedState&&(t!==null?t.push(Fa):t=[Fa])}a=a.return}t!==null&&Yr(e,t,n,l),e.flags|=262144}function du(t){for(t=t.firstContext;t!==null;){if(!jt(t.context._currentValue,t.memoizedValue))return!0;t=t.next}return!1}function Gn(t){$n=t,Me=null,t=t.dependencies,t!==null&&(t.firstContext=null)}function gt(t){return Xh($n,t)}function Ui(t,e){return $n===null&&Gn(t),Xh(t,e)}function Xh(t,e){var n=e._currentValue;if(e={context:e,memoizedValue:n,next:null},Me===null){if(t===null)throw Error(_(308));Me=e,t.dependencies={lanes:0,firstContext:e},t.flags|=524288}else Me=Me.next=e;return n}function Bs(){return{controller:new V0,data:new Map,refCount:0}}function ui(t){t.refCount--,t.refCount===0&&B0(q0,function(){t.controller.abort()})}function j0(t,e){if(wa===null){var n=wa=[];Kr=0,Vl=oc(),Tl={status:"pending",value:void 0,then:function(l){n.push(l)}}}return Kr++,e.then(nd,nd),e}function nd(){if(--Kr===0&&wa!==null){Tl!==null&&(Tl.status="fulfilled");var t=wa;wa=null,Vl=0,Tl=null;for(var e=0;e<t.length;e++)(0,t[e])()}}function H0(t,e){var n=[],l={status:"pending",value:null,reason:null,then:function(a){n.push(a)}};return t.then(function(){l.status="fulfilled",l.value=e;for(var a=0;a<n.length;a++)(0,n[a])(e)},function(a){l.status="rejected",l.reason=a;for(a=0;a<n.length;a++)(0,n[a])(void 0)}),l}function qs(){var t=qn.current;return t!==null?t:Z.pooledCache}function Ji(t,e){e===null?k(qn,qn.current):k(qn,e.pool)}function Qh(){var t=qs();return t===null?null:{parent:ot._currentValue,pool:t}}function ad(t){return t=t.status,t==="fulfilled"||t==="rejected"}function Zh(t,e,n){switch(n=t[n],n===void 0?t.push(e):n!==e&&(e.then(Re,Re),e=n),e.status){case"fulfilled":return e.value;case"rejected":throw t=e.reason,ud(t),t;default:if(typeof e.status==="string")e.then(Re,Re);else{if(t=Z,t!==null&&100<t.shellSuspendCounter)throw Error(_(482));t=e,t.status="pending",t.then(function(l){if(e.status==="pending"){var a=e;a.status="fulfilled",a.value=l}},function(l){if(e.status==="pending"){var a=e;a.status="rejected",a.reason=l}})}switch(e.status){case"fulfilled":return e.value;case"rejected":throw t=e.reason,ud(t),t}throw jn=e,Zl}}function Cn(t){try{var e=t._init;return e(t._payload)}catch(n){if(n!==null&&typeof n==="object"&&typeof n.then==="function")throw jn=n,Zl;throw n}}function id(){if(jn===null)throw Error(_(459));var t=jn;return jn=null,t}function ud(t){if(t===Zl||t===Lu)throw Error(_(483))}function Vi(t){var e=Za;return Za+=1,zl===null&&(zl=[]),Zh(zl,t,e)}function pa(t,e){e=e.props.ref,t.ref=e!==void 0?e:null}function Bi(t,e){if(e.$$typeof===xb)throw Error(_(525));throw t=Object.prototype.toString.call(e),Error(_(31,t==="[object Object]"?"object with keys {"+Object.keys(e).join(", ")+"}":t))}function kh(t){function e(f,c){if(t){var p=f.deletions;p===null?(f.deletions=[c],f.flags|=16):p.push(c)}}function n(f,c){if(!t)return null;for(;c!==null;)e(f,c),c=c.sibling;return null}function l(f){for(var c=new Map;f!==null;)f.key!==null?c.set(f.key,f):c.set(f.index,f),f=f.sibling;return c}function a(f,c){return f=Ce(f,c),f.index=0,f.sibling=null,f}function i(f,c,p){if(f.index=p,!t)return f.flags|=1048576,c;if(p=f.alternate,p!==null)return p=p.index,p<c?(f.flags|=67108866,c):p;return f.flags|=67108866,c}function u(f){return t&&f.alternate===null&&(f.flags|=67108866),f}function o(f,c,p,b){if(c===null||c.tag!==6)return c=tr(p,f.mode,b),c.return=f,c;return c=a(c,p),c.return=f,c}function r(f,c,p,b){var O=p.type;if(O===hl)return h(f,c,p.props.children,b,p.key);if(c!==null&&(c.elementType===O||typeof O==="object"&&O!==null&&O.$$typeof===We&&Cn(O)===c.type))return c=a(c,p.props),pa(c,p),c.return=f,c;return c=ki(p.type,p.key,p.props,null,f.mode,b),pa(c,p),c.return=f,c}function s(f,c,p,b){if(c===null||c.tag!==4||c.stateNode.containerInfo!==p.containerInfo||c.stateNode.implementation!==p.implementation)return c=er(p,f.mode,b),c.return=f,c;return c=a(c,p.children||[]),c.return=f,c}function h(f,c,p,b,O){if(c===null||c.tag!==7)return c=Bn(p,f.mode,b,O),c.return=f,c;return c=a(c,p),c.return=f,c}function g(f,c,p){if(typeof c==="string"&&c!==""||typeof c==="number"||typeof c==="bigint")return c=tr(""+c,f.mode,p),c.return=f,c;if(typeof c==="object"&&c!==null){switch(c.$$typeof){case Ti:return p=ki(c.type,c.key,c.props,null,f.mode,p),pa(p,c),p.return=f,p;case ya:return c=er(c,f.mode,p),c.return=f,c;case We:return c=Cn(c),g(f,c,p)}if(ba(c)||da(c))return c=Bn(c,f.mode,p,null),c.return=f,c;if(typeof c.then==="function")return g(f,Vi(c),p);if(c.$$typeof===we)return g(f,Ui(f,c),p);Bi(f,c)}return null}function d(f,c,p,b){var O=c!==null?c.key:null;if(typeof p==="string"&&p!==""||typeof p==="number"||typeof p==="bigint")return O!==null?null:o(f,c,""+p,b);if(typeof p==="object"&&p!==null){switch(p.$$typeof){case Ti:return p.key===O?r(f,c,p,b):null;case ya:return p.key===O?s(f,c,p,b):null;case We:return p=Cn(p),d(f,c,p,b)}if(ba(p)||da(p))return O!==null?null:h(f,c,p,b,null);if(typeof p.then==="function")return d(f,c,Vi(p),b);if(p.$$typeof===we)return d(f,c,Ui(f,p),b);Bi(f,p)}return null}function v(f,c,p,b,O){if(typeof b==="string"&&b!==""||typeof b==="number"||typeof b==="bigint")return f=f.get(p)||null,o(c,f,""+b,O);if(typeof b==="object"&&b!==null){switch(b.$$typeof){case Ti:return f=f.get(b.key===null?p:b.key)||null,r(c,f,b,O);case ya:return f=f.get(b.key===null?p:b.key)||null,s(c,f,b,O);case We:return b=Cn(b),v(f,c,p,b,O)}if(ba(b)||da(b))return f=f.get(p)||null,h(c,f,b,O,null);if(typeof b.then==="function")return v(f,c,p,Vi(b),O);if(b.$$typeof===we)return v(f,c,p,Ui(c,b),O);Bi(c,b)}return null}function E(f,c,p,b){for(var O=null,C=null,N=c,w=c=0,y=null;N!==null&&w<p.length;w++){N.index>w?(y=N,N=null):y=N.sibling;var D=d(f,N,p[w],b);if(D===null){N===null&&(N=y);break}t&&N&&D.alternate===null&&e(f,N),c=i(D,c,w),C===null?O=D:C.sibling=D,C=D,N=y}if(w===p.length)return n(f,N),q&&Te(f,w),O;if(N===null){for(;w<p.length;w++)N=g(f,p[w],b),N!==null&&(c=i(N,c,w),C===null?O=N:C.sibling=N,C=N);return q&&Te(f,w),O}for(N=l(N);w<p.length;w++)y=v(N,f,w,p[w],b),y!==null&&(t&&y.alternate!==null&&N.delete(y.key===null?w:y.key),c=i(y,c,w),C===null?O=y:C.sibling=y,C=y);return t&&N.forEach(function(ct){return e(f,ct)}),q&&Te(f,w),O}function A(f,c,p,b){if(p==null)throw Error(_(151));for(var O=null,C=null,N=c,w=c=0,y=null,D=p.next();N!==null&&!D.done;w++,D=p.next()){N.index>w?(y=N,N=null):y=N.sibling;var ct=d(f,N,D.value,b);if(ct===null){N===null&&(N=y);break}t&&N&&ct.alternate===null&&e(f,N),c=i(ct,c,w),C===null?O=ct:C.sibling=ct,C=ct,N=y}if(D.done)return n(f,N),q&&Te(f,w),O;if(N===null){for(;!D.done;w++,D=p.next())D=g(f,D.value,b),D!==null&&(c=i(D,c,w),C===null?O=D:C.sibling=D,C=D);return q&&Te(f,w),O}for(N=l(N);!D.done;w++,D=p.next())D=v(N,f,w,D.value,b),D!==null&&(t&&D.alternate!==null&&N.delete(D.key===null?w:D.key),c=i(D,c,w),C===null?O=D:C.sibling=D,C=D);return t&&N.forEach(function(Tn){return e(f,Tn)}),q&&Te(f,w),O}function z(f,c,p,b){if(typeof p==="object"&&p!==null&&p.type===hl&&p.key===null&&(p=p.props.children),typeof p==="object"&&p!==null){switch(p.$$typeof){case Ti:t:{for(var O=p.key;c!==null;){if(c.key===O){if(O=p.type,O===hl){if(c.tag===7){n(f,c.sibling),b=a(c,p.props.children),b.return=f,f=b;break t}}else if(c.elementType===O||typeof O==="object"&&O!==null&&O.$$typeof===We&&Cn(O)===c.type){n(f,c.sibling),b=a(c,p.props),pa(b,p),b.return=f,f=b;break t}n(f,c);break}else e(f,c);c=c.sibling}p.type===hl?(b=Bn(p.props.children,f.mode,b,p.key),b.return=f,f=b):(b=ki(p.type,p.key,p.props,null,f.mode,b),pa(b,p),b.return=f,f=b)}return u(f);case ya:t:{for(O=p.key;c!==null;){if(c.key===O)if(c.tag===4&&c.stateNode.containerInfo===p.containerInfo&&c.stateNode.implementation===p.implementation){n(f,c.sibling),b=a(c,p.children||[]),b.return=f,f=b;break t}else{n(f,c);break}else e(f,c);c=c.sibling}b=er(p,f.mode,b),b.return=f,f=b}return u(f);case We:return p=Cn(p),z(f,c,p,b)}if(ba(p))return E(f,c,p,b);if(da(p)){if(O=da(p),typeof O!=="function")throw Error(_(150));return p=O.call(p),A(f,c,p,b)}if(typeof p.then==="function")return z(f,c,Vi(p),b);if(p.$$typeof===we)return z(f,c,Ui(f,p),b);Bi(f,p)}return typeof p==="string"&&p!==""||typeof p==="number"||typeof p==="bigint"?(p=""+p,c!==null&&c.tag===6?(n(f,c.sibling),b=a(c,p),b.return=f,f=b):(n(f,c),b=tr(p,f.mode,b),b.return=f,f=b),u(f)):n(f,c)}return function(f,c,p,b){try{Za=0;var O=z(f,c,p,b);return zl=null,O}catch(N){if(N===Zl||N===Lu)throw N;var C=Mt(29,N,null,f.mode);return C.lanes=b,C.return=f,C}finally{}}}function Hs(t){t.updateQueue={baseState:t.memoizedState,firstBaseUpdate:null,lastBaseUpdate:null,shared:{pending:null,lanes:0,hiddenCallbacks:null},callbacks:null}}function Xr(t,e){t=t.updateQueue,e.updateQueue===t&&(e.updateQueue={baseState:t.baseState,firstBaseUpdate:t.firstBaseUpdate,lastBaseUpdate:t.lastBaseUpdate,shared:t.shared,callbacks:null})}function cn(t){return{lane:t,tag:0,payload:null,callback:null,next:null}}function fn(t,e,n){var l=t.updateQueue;if(l===null)return null;if(l=l.shared,(H&2)!==0){var a=l.pending;return a===null?e.next=e:(e.next=a.next,a.next=e),l.pending=e,e=cu(t),Hh(t,null,n),e}return Hu(t,l,e,n),cu(t)}function Ra(t,e,n){if(e=e.updateQueue,e!==null&&(e=e.shared,(n&4194048)!==0)){var l=e.lanes;l&=t.pendingLanes,n|=l,e.lanes=n,dh(t,n)}}function lr(t,e){var{updateQueue:n,alternate:l}=t;if(l!==null&&(l=l.updateQueue,n===l)){var a=null,i=null;if(n=n.firstBaseUpdate,n!==null){do{var u={lane:n.lane,tag:n.tag,payload:n.payload,callback:null,next:null};i===null?a=i=u:i=i.next=u,n=n.next}while(n!==null);i===null?a=i=e:i=i.next=e}else a=i=e;n={baseState:l.baseState,firstBaseUpdate:a,lastBaseUpdate:i,shared:l.shared,callbacks:l.callbacks},t.updateQueue=n;return}t=n.lastBaseUpdate,t===null?n.firstBaseUpdate=e:t.next=e,n.lastBaseUpdate=e}function Ma(){if(Qr){var t=Tl;if(t!==null)throw t}}function Ca(t,e,n,l){Qr=!1;var a=t.updateQueue;Fe=!1;var{firstBaseUpdate:i,lastBaseUpdate:u}=a,o=a.shared.pending;if(o!==null){a.shared.pending=null;var r=o,s=r.next;r.next=null,u===null?i=s:u.next=s,u=r;var h=t.alternate;h!==null&&(h=h.updateQueue,o=h.lastBaseUpdate,o!==u&&(o===null?h.firstBaseUpdate=s:o.next=s,h.lastBaseUpdate=r))}if(i!==null){var g=a.baseState;u=0,h=s=r=null,o=i;do{var d=o.lane&-536870913,v=d!==o.lane;if(v?(B&d)===d:(l&d)===d){d!==0&&d===Vl&&(Qr=!0),h!==null&&(h=h.next={lane:0,tag:o.tag,payload:o.payload,callback:null,next:null});t:{var E=t,A=o;d=e;var z=n;switch(A.tag){case 1:if(E=A.payload,typeof E==="function"){g=E.call(z,g,d);break t}g=E;break t;case 3:E.flags=E.flags&-65537|128;case 0:if(E=A.payload,d=typeof E==="function"?E.call(z,g,d):E,d===null||d===void 0)break t;g=P({},g,d);break t;case 2:Fe=!0}}d=o.callback,d!==null&&(t.flags|=64,v&&(t.flags|=8192),v=a.callbacks,v===null?a.callbacks=[d]:v.push(d))}else v={lane:d,tag:o.tag,payload:o.payload,callback:o.callback,next:null},h===null?(s=h=v,r=g):h=h.next=v,u|=d;if(o=o.next,o===null)if(o=a.shared.pending,o===null)break;else v=o,o=v.next,v.next=null,a.lastBaseUpdate=v,a.shared.pending=null}while(1);h===null&&(r=g),a.baseState=r,a.firstBaseUpdate=s,a.lastBaseUpdate=h,i===null&&(a.shared.lanes=0),_n|=u,t.lanes=u,t.memoizedState=g}}function $h(t,e){if(typeof t!=="function")throw Error(_(191,t));t.call(e)}function Wh(t,e){var n=t.callbacks;if(n!==null)for(t.callbacks=null,t=0;t<n.length;t++)$h(n[t],e)}function od(t,e){t=Le,k(pu,t),k(Bl,e),Le=t|e.baseLanes}function Zr(){k(pu,Le),k(Bl,Bl.current)}function Ls(){Le=pu.current,ht(Bl),ht(pu)}function Pe(t){var e=t.alternate;k(lt,lt.current&1),k(Ht,t),Ft===null&&(e===null||Bl.current!==null?Ft=t:e.memoizedState!==null&&(Ft=t))}function kr(t){k(lt,lt.current),k(Ht,t),Ft===null&&(Ft=t)}function Fh(t){t.tag===22?(k(lt,lt.current),k(Ht,t),Ft===null&&(Ft=t)):tn(t)}function tn(){k(lt,lt.current),k(Ht,Ht.current)}function Rt(t){ht(Ht),Ft===t&&(Ft=null),ht(lt)}function mu(t){for(var e=t;e!==null;){if(e.tag===13){var n=e.memoizedState;if(n!==null&&(n=n.dehydrated,n===null||ps(n)||ms(n)))return e}else if(e.tag===19&&(e.memoizedProps.revealOrder==="forwards"||e.memoizedProps.revealOrder==="backwards"||e.memoizedProps.revealOrder==="unstable_legacy-backwards"||e.memoizedProps.revealOrder==="together")){if((e.flags&128)!==0)return e}else if(e.child!==null){e.child.return=e,e=e.child;continue}if(e===t)break;for(;e.sibling===null;){if(e.return===null||e.return===t)return null;e=e.return}e.sibling.return=e.return,e=e.sibling}return null}function et(){throw Error(_(321))}function Gs(t,e){if(e===null)return!1;for(var n=0;n<e.length&&n<t.length;n++)if(!jt(t[n],e[n]))return!1;return!0}function Ys(t,e,n,l,a,i){return qe=i,R=e,e.memoizedState=null,e.updateQueue=null,e.lanes=0,T.H=t===null||t.memoizedState===null?Tp:Ps,Kn=!1,i=n(l,a),Kn=!1,wl&&(i=Ph(e,n,l,a)),Ih(t),i}function Ih(t){T.H=Ja;var e=Q!==null&&Q.next!==null;if(qe=0,it=Q=R=null,vu=!1,ka=0,Rl=null,e)throw Error(_(300));t===null||rt||(t=t.dependencies,t!==null&&du(t)&&(rt=!0))}function Ph(t,e,n,l){R=t;var a=0;do{if(wl&&(Rl=null),ka=0,wl=!1,25<=a)throw Error(_(301));if(a+=1,it=Q=null,t.updateQueue!=null){var i=t.updateQueue;i.lastEffect=null,i.events=null,i.stores=null,i.memoCache!=null&&(i.memoCache.index=0)}T.H=zp,i=e(n,l)}while(wl);return i}function G0(){var t=T.H,e=t.useState()[0];return e=typeof e.then==="function"?oi(e):e,t=t.useState()[0],(Q!==null?Q.memoizedState:null)!==t&&(R.flags|=1024),e}function Ks(){var t=gu!==0;return gu=0,t}function Xs(t,e,n){e.updateQueue=t.updateQueue,e.flags&=-2053,t.lanes&=~n}function Qs(t){if(vu){for(t=t.memoizedState;t!==null;){var e=t.queue;e!==null&&(e.pending=null),t=t.next}vu=!1}qe=0,it=Q=R=null,wl=!1,ka=gu=0,Rl=null}function Et(){var t={memoizedState:null,baseState:null,baseQueue:null,queue:null,next:null};return it===null?R.memoizedState=it=t:it=it.next=t,it}function at(){if(Q===null){var t=R.alternate;t=t!==null?t.memoizedState:null}else t=Q.next;var e=it===null?R.memoizedState:it.next;if(e!==null)it=e,Q=t;else{if(t===null){if(R.alternate===null)throw Error(_(467));throw Error(_(310))}Q=t,t={memoizedState:Q.memoizedState,baseState:Q.baseState,baseQueue:Q.baseQueue,queue:Q.queue,next:null},it===null?R.memoizedState=it=t:it=it.next=t}return it}function Gu(){return{lastEffect:null,events:null,stores:null,memoCache:null}}function oi(t){var e=ka;return ka+=1,Rl===null&&(Rl=[]),t=Zh(Rl,t,e),e=R,(it===null?e.memoizedState:it.next)===null&&(e=e.alternate,T.H=e===null||e.memoizedState===null?Tp:Ps),t}function Yu(t){if(t!==null&&typeof t==="object"){if(typeof t.then==="function")return oi(t);if(t.$$typeof===we)return gt(t)}throw Error(_(438,String(t)))}function Zs(t){var e=null,n=R.updateQueue;if(n!==null&&(e=n.memoCache),e==null){var l=R.alternate;l!==null&&(l=l.updateQueue,l!==null&&(l=l.memoCache,l!=null&&(e={data:l.data.map(function(a){return a.slice()}),index:0})))}if(e==null&&(e={data:[],index:0}),n===null&&(n=Gu(),R.updateQueue=n),n.memoCache=e,n=e.data[e.index],n===void 0)for(n=e.data[e.index]=Array(t),l=0;l<t;l++)n[l]=Ab;return e.index++,n}function je(t,e){return typeof e==="function"?e(t):e}function $i(t){var e=at();return ks(e,Q,t)}function ks(t,e,n){var l=t.queue;if(l===null)throw Error(_(311));l.lastRenderedReducer=n;var a=t.baseQueue,i=l.pending;if(i!==null){if(a!==null){var u=a.next;a.next=i.next,i.next=u}e.baseQueue=a=i,l.pending=null}if(i=t.baseState,a===null)t.memoizedState=i;else{e=a.next;var o=u=null,r=null,s=e,h=!1;do{var g=s.lane&-536870913;if(g!==s.lane?(B&g)===g:(qe&g)===g){var d=s.revertLane;if(d===0)r!==null&&(r=r.next={lane:0,revertLane:0,gesture:null,action:s.action,hasEagerState:s.hasEagerState,eagerState:s.eagerState,next:null}),g===Vl&&(h=!0);else if((qe&d)===d){s=s.next,d===Vl&&(h=!0);continue}else g={lane:0,revertLane:s.revertLane,gesture:null,action:s.action,hasEagerState:s.hasEagerState,eagerState:s.eagerState,next:null},r===null?(o=r=g,u=i):r=r.next=g,R.lanes|=d,_n|=d;g=s.action,Kn&&n(i,g),i=s.hasEagerState?s.eagerState:n(i,g)}else d={lane:g,revertLane:s.revertLane,gesture:s.gesture,action:s.action,hasEagerState:s.hasEagerState,eagerState:s.eagerState,next:null},r===null?(o=r=d,u=i):r=r.next=d,R.lanes|=g,_n|=g;s=s.next}while(s!==null&&s!==e);if(r===null?u=i:r.next=o,!jt(i,t.memoizedState)&&(rt=!0,h&&(n=Tl,n!==null)))throw n;t.memoizedState=i,t.baseState=u,t.baseQueue=r,l.lastRenderedState=i}return a===null&&(l.lanes=0),[t.memoizedState,l.dispatch]}function ar(t){var e=at(),n=e.queue;if(n===null)throw Error(_(311));n.lastRenderedReducer=t;var{dispatch:l,pending:a}=n,i=e.memoizedState;if(a!==null){n.pending=null;var u=a=a.next;do i=t(i,u.action),u=u.next;while(u!==a);jt(i,e.memoizedState)||(rt=!0),e.memoizedState=i,e.baseQueue===null&&(e.baseState=i),n.lastRenderedState=i}return[i,l]}function tp(t,e,n){var l=R,a=at(),i=q;if(i){if(n===void 0)throw Error(_(407));n=n()}else n=e();var u=!jt((Q||a).memoizedState,n);if(u&&(a.memoizedState=n,rt=!0),a=a.queue,Js(lp.bind(null,l,a,t),[t]),a.getSnapshot!==e||u||it!==null&&it.memoizedState.tag&1){if(l.flags|=2048,ql(9,{destroy:void 0},np.bind(null,l,a,n,e),null),Z===null)throw Error(_(349));i||(qe&127)!==0||ep(l,e,n)}return n}function ep(t,e,n){t.flags|=16384,t={getSnapshot:e,value:n},e=R.updateQueue,e===null?(e=Gu(),R.updateQueue=e,e.stores=[t]):(n=e.stores,n===null?e.stores=[t]:n.push(t))}function np(t,e,n,l){e.value=n,e.getSnapshot=l,ap(e)&&ip(t)}function lp(t,e,n){return n(function(){ap(e)&&ip(t)})}function ap(t){var e=t.getSnapshot;t=t.value;try{var n=e();return!jt(t,n)}catch(l){return!0}}function ip(t){var e=Jn(t,2);e!==null&&Dt(e,t,2)}function Jr(t){var e=Et();if(typeof t==="function"){var n=t;if(t=n(),Kn){nn(!0);try{n()}finally{nn(!1)}}}return e.memoizedState=e.baseState=t,e.queue={pending:null,lanes:0,dispatch:null,lastRenderedReducer:je,lastRenderedState:t},e}function up(t,e,n,l){return t.baseState=n,ks(t,Q,typeof l==="function"?l:je)}function Y0(t,e,n,l,a){if(Xu(t))throw Error(_(485));if(t=e.action,t!==null){var i={payload:a,action:t,next:null,isTransition:!0,status:"pending",value:null,reason:null,listeners:[],then:function(u){i.listeners.push(u)}};T.T!==null?n(!0):i.isTransition=!1,l(i),n=e.pending,n===null?(i.next=e.pending=i,op(e,i)):(i.next=n.next,e.pending=n.next=i)}}function op(t,e){var{action:n,payload:l}=e,a=t.state;if(e.isTransition){var i=T.T,u={};T.T=u;try{var o=n(a,l),r=T.S;r!==null&&r(u,o),rd(t,e,o)}catch(s){$r(t,e,s)}finally{i!==null&&u.types!==null&&(i.types=u.types),T.T=i}}else try{i=n(a,l),rd(t,e,i)}catch(s){$r(t,e,s)}}function rd(t,e,n){n!==null&&typeof n==="object"&&typeof n.then==="function"?n.then(function(l){sd(t,e,l)},function(l){return $r(t,e,l)}):sd(t,e,n)}function sd(t,e,n){e.status="fulfilled",e.value=n,rp(e),t.state=n,e=t.pending,e!==null&&(n=e.next,n===e?t.pending=null:(n=n.next,e.next=n,op(t,n)))}function $r(t,e,n){var l=t.pending;if(t.pending=null,l!==null){l=l.next;do e.status="rejected",e.reason=n,rp(e),e=e.next;while(e!==l)}t.action=null}function rp(t){t=t.listeners;for(var e=0;e<t.length;e++)(0,t[e])()}function sp(t,e){return e}function cd(t,e){if(q){var n=Z.formState;if(n!==null){t:{var l=R;if(q){if(I){e:{var a=I;for(var i=Wt;a.nodeType!==8;){if(!i){a=null;break e}if(a=It(a.nextSibling),a===null){a=null;break e}}i=a.data,a=i==="F!"||i==="F"?a:null}if(a){I=It(a.nextSibling),l=a.data==="F!";break t}}yn(l)}l=!1}l&&(e=n[0])}}return n=Et(),n.memoizedState=n.baseState=e,l={pending:null,lanes:0,dispatch:null,lastRenderedReducer:sp,lastRenderedState:e},n.queue=l,n=xp.bind(null,R,l),l.dispatch=n,l=Jr(!1),i=Is.bind(null,R,!1,l.queue),l=Et(),a={state:e,dispatch:null,action:t,pending:null},l.queue=a,n=Y0.bind(null,R,a,i,n),a.dispatch=n,l.memoizedState=t,[e,n,!1]}function fd(t){var e=at();return cp(e,Q,t)}function cp(t,e,n){if(e=ks(t,e,sp)[0],t=$i(je)[0],typeof e==="object"&&e!==null&&typeof e.then==="function")try{var l=oi(e)}catch(u){if(u===Zl)throw Lu;throw u}else l=e;e=at();var a=e.queue,i=a.dispatch;return n!==e.memoizedState&&(R.flags|=2048,ql(9,{destroy:void 0},K0.bind(null,a,n),null)),[l,i,t]}function K0(t,e){t.action=e}function dd(t){var e=at(),n=Q;if(n!==null)return cp(e,n,t);at(),e=e.memoizedState,n=at();var l=n.queue.dispatch;return n.memoizedState=t,[e,l,!1]}function ql(t,e,n,l){return t={tag:t,create:n,deps:l,inst:e,next:null},e=R.updateQueue,e===null&&(e=Gu(),R.updateQueue=e),n=e.lastEffect,n===null?e.lastEffect=t.next=t:(l=n.next,n.next=t,t.next=l,e.lastEffect=t),t}function fp(){return at().memoizedState}function Wi(t,e,n,l){var a=Et();R.flags|=t,a.memoizedState=ql(1|e,{destroy:void 0},n,l===void 0?null:l)}function Ku(t,e,n,l){var a=at();l=l===void 0?null:l;var i=a.memoizedState.inst;Q!==null&&l!==null&&Gs(l,Q.memoizedState.deps)?a.memoizedState=ql(e,i,n,l):(R.flags|=t,a.memoizedState=ql(1|e,i,n,l))}function hd(t,e){Wi(8390656,8,t,e)}function Js(t,e){Ku(2048,8,t,e)}function X0(t){R.flags|=4;var e=R.updateQueue;if(e===null)e=Gu(),R.updateQueue=e,e.events=[t];else{var n=e.events;n===null?e.events=[t]:n.push(t)}}function dp(t){var e=at().memoizedState;return X0({ref:e,nextImpl:t}),function(){if((H&2)!==0)throw Error(_(440));return e.impl.apply(void 0,arguments)}}function hp(t,e){return Ku(4,2,t,e)}function pp(t,e){return Ku(4,4,t,e)}function mp(t,e){if(typeof e==="function"){t=t();var n=e(t);return function(){typeof n==="function"?n():e(null)}}if(e!==null&&e!==void 0)return t=t(),e.current=t,function(){e.current=null}}function vp(t,e,n){n=n!==null&&n!==void 0?n.concat([t]):null,Ku(4,4,mp.bind(null,e,t),n)}function $s(){}function gp(t,e){var n=at();e=e===void 0?null:e;var l=n.memoizedState;if(e!==null&&Gs(e,l[1]))return l[0];return n.memoizedState=[t,e],t}function yp(t,e){var n=at();e=e===void 0?null:e;var l=n.memoizedState;if(e!==null&&Gs(e,l[1]))return l[0];if(l=t(),Kn){nn(!0);try{t()}finally{nn(!1)}}return n.memoizedState=[l,e],l}function Ws(t,e,n){if(n===void 0||(qe&1073741824)!==0&&(B&261930)===0)return t.memoizedState=e;return t.memoizedState=n,t=um(),R.lanes|=t,_n|=t,n}function bp(t,e,n,l){if(jt(n,e))return n;if(Bl.current!==null)return t=Ws(t,n,l),jt(t,e)||(rt=!0),t;if((qe&42)===0||(qe&1073741824)!==0&&(B&261930)===0)return rt=!0,t.memoizedState=n;return t=um(),R.lanes|=t,_n|=t,e}function _p(t,e,n,l,a){var i=L.p;L.p=i!==0&&8>i?i:8;var u=T.T,o={};T.T=o,Is(t,!1,e,n);try{var r=a(),s=T.S;if(s!==null&&s(o,r),r!==null&&typeof r==="object"&&typeof r.then==="function"){var h=H0(r,l);Ua(t,e,h,qt(t))}else Ua(t,e,l,qt(t))}catch(g){Ua(t,e,{then:function(){},status:"rejected",reason:g},qt())}finally{L.p=i,u!==null&&o.types!==null&&(u.types=o.types),T.T=u}}function Q0(){}function Wr(t,e,n,l){if(t.tag!==5)throw Error(_(476));var a=Sp(t).queue;_p(t,a,e,Vn,n===null?Q0:function(){return Ep(t),n(l)})}function Sp(t){var e=t.memoizedState;if(e!==null)return e;e={memoizedState:Vn,baseState:Vn,baseQueue:null,queue:{pending:null,lanes:0,dispatch:null,lastRenderedReducer:je,lastRenderedState:Vn},next:null};var n={};return e.next={memoizedState:n,baseState:n,baseQueue:null,queue:{pending:null,lanes:0,dispatch:null,lastRenderedReducer:je,lastRenderedState:n},next:null},t.memoizedState=e,t=t.alternate,t!==null&&(t.memoizedState=e),e}function Ep(t){var e=Sp(t);e.next===null&&(e=t.alternate.memoizedState),Ua(t,e.next.queue,{},qt())}function Fs(){return gt(Fa)}function Op(){return at().memoizedState}function Np(){return at().memoizedState}function Z0(t){for(var e=t.return;e!==null;){switch(e.tag){case 24:case 3:var n=qt();t=cn(n);var l=fn(e,t,n);l!==null&&(Dt(l,e,n),Ra(l,e,n)),e={cache:Bs()},t.payload=e;return}e=e.return}}function k0(t,e,n){var l=qt();n={lane:l,revertLane:0,gesture:null,action:n,hasEagerState:!1,eagerState:null,next:null},Xu(t)?Ap(e,n):(n=Ms(t,e,n,l),n!==null&&(Dt(n,t,l),Dp(n,e,l)))}function xp(t,e,n){var l=qt();Ua(t,e,n,l)}function Ua(t,e,n,l){var a={lane:l,revertLane:0,gesture:null,action:n,hasEagerState:!1,eagerState:null,next:null};if(Xu(t))Ap(e,a);else{var i=t.alternate;if(t.lanes===0&&(i===null||i.lanes===0)&&(i=e.lastRenderedReducer,i!==null))try{var u=e.lastRenderedState,o=i(u,n);if(a.hasEagerState=!0,a.eagerState=o,jt(o,u))return Hu(t,e,a,0),Z===null&&ju(),!1}catch(r){}finally{}if(n=Ms(t,e,a,l),n!==null)return Dt(n,t,l),Dp(n,e,l),!0}return!1}function Is(t,e,n,l){if(l={lane:2,revertLane:oc(),gesture:null,action:l,hasEagerState:!1,eagerState:null,next:null},Xu(t)){if(e)throw Error(_(479))}else e=Ms(t,n,l,2),e!==null&&Dt(e,t,2)}function Xu(t){var e=t.alternate;return t===R||e!==null&&e===R}function Ap(t,e){wl=vu=!0;var n=t.pending;n===null?e.next=e:(e.next=n.next,n.next=e),t.pending=e}function Dp(t,e,n){if((n&4194048)!==0){var l=e.lanes;l&=t.pendingLanes,n|=l,e.lanes=n,dh(t,n)}}function ir(t,e,n,l){e=t.memoizedState,n=n(l,e),n=n===null||n===void 0?e:P({},e,n),t.memoizedState=n,t.lanes===0&&(t.updateQueue.baseState=n)}function pd(t,e,n,l,a,i,u){return t=t.stateNode,typeof t.shouldComponentUpdate==="function"?t.shouldComponentUpdate(l,i,u):e.prototype&&e.prototype.isPureReactComponent?!Ka(n,l)||!Ka(a,i):!0}function md(t,e,n,l){t=e.state,typeof e.componentWillReceiveProps==="function"&&e.componentWillReceiveProps(n,l),typeof e.UNSAFE_componentWillReceiveProps==="function"&&e.UNSAFE_componentWillReceiveProps(n,l),e.state!==t&&Fr.enqueueReplaceState(e,e.state,null)}function Xn(t,e){var n=e;if("ref"in e){n={};for(var l in e)l!=="ref"&&(n[l]=e[l])}if(t=t.defaultProps){n===e&&(n=P({},n));for(var a in t)n[a]===void 0&&(n[a]=t[a])}return n}function wp(t){su(t)}function Rp(t){console.error(t)}function Mp(t){su(t)}function yu(t,e){try{var n=t.onUncaughtError;n(e.value,{componentStack:e.stack})}catch(l){setTimeout(function(){throw l})}}function vd(t,e,n){try{var l=t.onCaughtError;l(n.value,{componentStack:n.stack,errorBoundary:e.tag===1?e.stateNode:null})}catch(a){setTimeout(function(){throw a})}}function Ir(t,e,n){return n=cn(n),n.tag=3,n.payload={element:null},n.callback=function(){yu(t,e)},n}function Cp(t){return t=cn(t),t.tag=3,t}function Up(t,e,n,l){var a=n.type.getDerivedStateFromError;if(typeof a==="function"){var i=l.value;t.payload=function(){return a(i)},t.callback=function(){vd(e,n,l)}}var u=n.stateNode;u!==null&&typeof u.componentDidCatch==="function"&&(t.callback=function(){vd(e,n,l),typeof a!=="function"&&(dn===null?dn=new Set([this]):dn.add(this));var o=l.stack;this.componentDidCatch(l.value,{componentStack:o!==null?o:""})})}function J0(t,e,n,l,a){if(n.flags|=32768,l!==null&&typeof l==="object"&&typeof l.then==="function"){if(e=n.alternate,e!==null&&Ql(e,n,a,!0),n=Ht.current,n!==null){switch(n.tag){case 31:case 13:return Ft===null?Ou():n.alternate===null&&nt===0&&(nt=3),n.flags&=-257,n.flags|=65536,n.lanes=a,l===hu?n.flags|=16384:(e=n.updateQueue,e===null?n.updateQueue=new Set([l]):e.add(l),vr(t,l,a)),!1;case 22:return n.flags|=65536,l===hu?n.flags|=16384:(e=n.updateQueue,e===null?(e={transitions:null,markerInstances:null,retryQueue:new Set([l])},n.updateQueue=e):(n=e.retryQueue,n===null?e.retryQueue=new Set([l]):n.add(l)),vr(t,l,a)),!1}throw Error(_(435,n.tag))}return vr(t,l,a),Ou(),!1}if(q)return e=Ht.current,e!==null?((e.flags&65536)===0&&(e.flags|=256),e.flags|=65536,e.lanes=a,l!==Hr&&(t=Error(_(422),{cause:l}),Qa($t(t,n)))):(l!==Hr&&(e=Error(_(423),{cause:l}),Qa($t(e,n))),t=t.current.alternate,t.flags|=65536,a&=-a,t.lanes|=a,l=$t(l,n),a=Ir(t.stateNode,l,a),lr(t,a),nt!==4&&(nt=2)),!1;var i=Error(_(520),{cause:l});if(i=$t(i,n),qa===null?qa=[i]:qa.push(i),nt!==4&&(nt=2),e===null)return!0;l=$t(l,n),n=e;do{switch(n.tag){case 3:return n.flags|=65536,t=a&-a,n.lanes|=t,t=Ir(n.stateNode,l,t),lr(n,t),!1;case 1:if(e=n.type,i=n.stateNode,(n.flags&128)===0&&(typeof e.getDerivedStateFromError==="function"||i!==null&&typeof i.componentDidCatch==="function"&&(dn===null||!dn.has(i))))return n.flags|=65536,a&=-a,n.lanes|=a,a=Cp(a),Up(a,t,n,l),lr(n,a),!1}n=n.return}while(n!==null);return!1}function pt(t,e,n,l){e.child=t===null?Jh(e,null,n,l):Yn(e,t.child,n,l)}function gd(t,e,n,l,a){n=n.render;var i=e.ref;if("ref"in l){var u={};for(var o in l)o!=="ref"&&(u[o]=l[o])}else u=l;if(Gn(e),l=Ys(t,e,n,u,i,a),o=Ks(),t!==null&&!rt)return Xs(t,e,a),He(t,e,a);return q&&o&&Us(e),e.flags|=1,pt(t,e,l,a),e.child}function yd(t,e,n,l,a){if(t===null){var i=n.type;if(typeof i==="function"&&!Cs(i)&&i.defaultProps===void 0&&n.compare===null)return e.tag=15,e.type=i,Vp(t,e,i,l,a);return t=ki(n.type,null,l,e,e.mode,a),t.ref=e.ref,t.return=e,e.child=t}if(i=t.child,!ec(t,a)){var u=i.memoizedProps;if(n=n.compare,n=n!==null?n:Ka,n(u,l)&&t.ref===e.ref)return He(t,e,a)}return e.flags|=1,t=Ce(i,l),t.ref=e.ref,t.return=e,e.child=t}function Vp(t,e,n,l,a){if(t!==null){var i=t.memoizedProps;if(Ka(i,l)&&t.ref===e.ref)if(rt=!1,e.pendingProps=l=i,ec(t,a))(t.flags&131072)!==0&&(rt=!0);else return e.lanes=t.lanes,He(t,e,a)}return Pr(t,e,n,l,a)}function Bp(t,e,n,l){var a=l.children,i=t!==null?t.memoizedState:null;if(t===null&&e.stateNode===null&&(e.stateNode={_visibility:1,_pendingMarkers:null,_retryCache:null,_transitions:null}),l.mode==="hidden"){if((e.flags&128)!==0){if(i=i!==null?i.baseLanes|n:n,t!==null){l=e.child=t.child;for(a=0;l!==null;)a=a|l.lanes|l.childLanes,l=l.sibling;l=a&~i}else l=0,e.child=null;return bd(t,e,i,n,l)}if((n&536870912)!==0)e.memoizedState={baseLanes:0,cachePool:null},t!==null&&Ji(e,i!==null?i.cachePool:null),i!==null?od(e,i):Zr(),Fh(e);else return l=e.lanes=536870912,bd(t,e,i!==null?i.baseLanes|n:n,n,l)}else i!==null?(Ji(e,i.cachePool),od(e,i),tn(e),e.memoizedState=null):(t!==null&&Ji(e,null),Zr(),tn(e));return pt(t,e,a,n),e.child}function Oa(t,e){return t!==null&&t.tag===22||e.stateNode!==null||(e.stateNode={_visibility:1,_pendingMarkers:null,_retryCache:null,_transitions:null}),e.sibling}function bd(t,e,n,l,a){var i=qs();return i=i===null?null:{parent:ot._currentValue,pool:i},e.memoizedState={baseLanes:n,cachePool:i},t!==null&&Ji(e,null),Zr(),Fh(e),t!==null&&Ql(t,e,l,!0),e.childLanes=a,null}function Fi(t,e){return e=bu({mode:e.mode,children:e.children},t.mode),e.ref=t.ref,t.child=e,e.return=t,e}function _d(t,e,n){return Yn(e,t.child,null,n),t=Fi(e,e.pendingProps),t.flags|=2,Rt(e),e.memoizedState=null,t}function $0(t,e,n){var l=e.pendingProps,a=(e.flags&128)!==0;if(e.flags&=-129,t===null){if(q){if(l.mode==="hidden")return t=Fi(e,l),e.lanes=536870912,Oa(null,t);if(kr(e),(t=I)?(t=Tm(t,Wt),t=t!==null&&t.data==="&"?t:null,t!==null&&(e.memoizedState={dehydrated:t,treeContext:gn!==null?{id:he,overflow:pe}:null,retryLane:536870912,hydrationErrors:null},n=Gh(t),n.return=e,e.child=n,vt=e,I=null)):t=null,t===null)throw yn(e);return e.lanes=536870912,null}return Fi(e,l)}var i=t.memoizedState;if(i!==null){var u=i.dehydrated;if(kr(e),a)if(e.flags&256)e.flags&=-257,e=_d(t,e,n);else if(e.memoizedState!==null)e.child=t.child,e.flags|=128,e=null;else throw Error(_(558));else if(rt||Ql(t,e,n,!1),a=(n&t.childLanes)!==0,rt||a){if(l=Z,l!==null&&(u=hh(l,n),u!==0&&u!==i.retryLane))throw i.retryLane=u,Jn(t,u),Dt(l,t,u),tc;Ou(),e=_d(t,e,n)}else t=i.treeContext,I=It(u.nextSibling),vt=e,q=!0,sn=null,Wt=!1,t!==null&&Kh(e,t),e=Fi(e,l),e.flags|=4096;return e}return t=Ce(t.child,{mode:l.mode,children:l.children}),t.ref=e.ref,e.child=t,t.return=e,t}function Ii(t,e){var n=e.ref;if(n===null)t!==null&&t.ref!==null&&(e.flags|=4194816);else{if(typeof n!=="function"&&typeof n!=="object")throw Error(_(284));if(t===null||t.ref!==n)e.flags|=4194816}}function Pr(t,e,n,l,a){if(Gn(e),n=Ys(t,e,n,l,void 0,a),l=Ks(),t!==null&&!rt)return Xs(t,e,a),He(t,e,a);return q&&l&&Us(e),e.flags|=1,pt(t,e,n,a),e.child}function Sd(t,e,n,l,a,i){if(Gn(e),e.updateQueue=null,n=Ph(e,l,n,a),Ih(t),l=Ks(),t!==null&&!rt)return Xs(t,e,i),He(t,e,i);return q&&l&&Us(e),e.flags|=1,pt(t,e,n,i),e.child}function Ed(t,e,n,l,a){if(Gn(e),e.stateNode===null){var i=Sl,u=n.contextType;typeof u==="object"&&u!==null&&(i=gt(u)),i=new n(l,i),e.memoizedState=i.state!==null&&i.state!==void 0?i.state:null,i.updater=Fr,e.stateNode=i,i._reactInternals=e,i=e.stateNode,i.props=l,i.state=e.memoizedState,i.refs={},Hs(e),u=n.contextType,i.context=typeof u==="object"&&u!==null?gt(u):Sl,i.state=e.memoizedState,u=n.getDerivedStateFromProps,typeof u==="function"&&(ir(e,n,u,l),i.state=e.memoizedState),typeof n.getDerivedStateFromProps==="function"||typeof i.getSnapshotBeforeUpdate==="function"||typeof i.UNSAFE_componentWillMount!=="function"&&typeof i.componentWillMount!=="function"||(u=i.state,typeof i.componentWillMount==="function"&&i.componentWillMount(),typeof i.UNSAFE_componentWillMount==="function"&&i.UNSAFE_componentWillMount(),u!==i.state&&Fr.enqueueReplaceState(i,i.state,null),Ca(e,l,i,a),Ma(),i.state=e.memoizedState),typeof i.componentDidMount==="function"&&(e.flags|=4194308),l=!0}else if(t===null){i=e.stateNode;var o=e.memoizedProps,r=Xn(n,o);i.props=r;var s=i.context,h=n.contextType;u=Sl,typeof h==="object"&&h!==null&&(u=gt(h));var g=n.getDerivedStateFromProps;h=typeof g==="function"||typeof i.getSnapshotBeforeUpdate==="function",o=e.pendingProps!==o,h||typeof i.UNSAFE_componentWillReceiveProps!=="function"&&typeof i.componentWillReceiveProps!=="function"||(o||s!==u)&&md(e,i,l,u),Fe=!1;var d=e.memoizedState;i.state=d,Ca(e,l,i,a),Ma(),s=e.memoizedState,o||d!==s||Fe?(typeof g==="function"&&(ir(e,n,g,l),s=e.memoizedState),(r=Fe||pd(e,n,r,l,d,s,u))?(h||typeof i.UNSAFE_componentWillMount!=="function"&&typeof i.componentWillMount!=="function"||(typeof i.componentWillMount==="function"&&i.componentWillMount(),typeof i.UNSAFE_componentWillMount==="function"&&i.UNSAFE_componentWillMount()),typeof i.componentDidMount==="function"&&(e.flags|=4194308)):(typeof i.componentDidMount==="function"&&(e.flags|=4194308),e.memoizedProps=l,e.memoizedState=s),i.props=l,i.state=s,i.context=u,l=r):(typeof i.componentDidMount==="function"&&(e.flags|=4194308),l=!1)}else{i=e.stateNode,Xr(t,e),u=e.memoizedProps,h=Xn(n,u),i.props=h,g=e.pendingProps,d=i.context,s=n.contextType,r=Sl,typeof s==="object"&&s!==null&&(r=gt(s)),o=n.getDerivedStateFromProps,(s=typeof o==="function"||typeof i.getSnapshotBeforeUpdate==="function")||typeof i.UNSAFE_componentWillReceiveProps!=="function"&&typeof i.componentWillReceiveProps!=="function"||(u!==g||d!==r)&&md(e,i,l,r),Fe=!1,d=e.memoizedState,i.state=d,Ca(e,l,i,a),Ma();var v=e.memoizedState;u!==g||d!==v||Fe||t!==null&&t.dependencies!==null&&du(t.dependencies)?(typeof o==="function"&&(ir(e,n,o,l),v=e.memoizedState),(h=Fe||pd(e,n,h,l,d,v,r)||t!==null&&t.dependencies!==null&&du(t.dependencies))?(s||typeof i.UNSAFE_componentWillUpdate!=="function"&&typeof i.componentWillUpdate!=="function"||(typeof i.componentWillUpdate==="function"&&i.componentWillUpdate(l,v,r),typeof i.UNSAFE_componentWillUpdate==="function"&&i.UNSAFE_componentWillUpdate(l,v,r)),typeof i.componentDidUpdate==="function"&&(e.flags|=4),typeof i.getSnapshotBeforeUpdate==="function"&&(e.flags|=1024)):(typeof i.componentDidUpdate!=="function"||u===t.memoizedProps&&d===t.memoizedState||(e.flags|=4),typeof i.getSnapshotBeforeUpdate!=="function"||u===t.memoizedProps&&d===t.memoizedState||(e.flags|=1024),e.memoizedProps=l,e.memoizedState=v),i.props=l,i.state=v,i.context=r,l=h):(typeof i.componentDidUpdate!=="function"||u===t.memoizedProps&&d===t.memoizedState||(e.flags|=4),typeof i.getSnapshotBeforeUpdate!=="function"||u===t.memoizedProps&&d===t.memoizedState||(e.flags|=1024),l=!1)}return i=l,Ii(t,e),l=(e.flags&128)!==0,i||l?(i=e.stateNode,n=l&&typeof n.getDerivedStateFromError!=="function"?null:i.render(),e.flags|=1,t!==null&&l?(e.child=Yn(e,t.child,null,a),e.child=Yn(e,null,n,a)):pt(t,e,n,a),e.memoizedState=i.state,t=e.child):t=He(t,e,a),t}function Od(t,e,n,l){return Ln(),e.flags|=256,pt(t,e,n,l),e.child}function or(t){return{baseLanes:t,cachePool:Qh()}}function rr(t,e,n){return t=t!==null?t.childLanes&~n:0,e&&(t|=Ct),t}function qp(t,e,n){var l=e.pendingProps,a=!1,i=(e.flags&128)!==0,u;if((u=i)||(u=t!==null&&t.memoizedState===null?!1:(lt.current&2)!==0),u&&(a=!0,e.flags&=-129),u=(e.flags&32)!==0,e.flags&=-33,t===null){if(q){if(a?Pe(e):tn(e),(t=I)?(t=Tm(t,Wt),t=t!==null&&t.data!=="&"?t:null,t!==null&&(e.memoizedState={dehydrated:t,treeContext:gn!==null?{id:he,overflow:pe}:null,retryLane:536870912,hydrationErrors:null},n=Gh(t),n.return=e,e.child=n,vt=e,I=null)):t=null,t===null)throw yn(e);return ms(t)?e.lanes=32:e.lanes=536870912,null}var o=l.children;if(l=l.fallback,a)return tn(e),a=e.mode,o=bu({mode:"hidden",children:o},a),l=Bn(l,a,n,null),o.return=e,l.return=e,o.sibling=l,e.child=o,l=e.child,l.memoizedState=or(n),l.childLanes=rr(t,u,n),e.memoizedState=ur,Oa(null,l);return Pe(e),ts(e,o)}var r=t.memoizedState;if(r!==null&&(o=r.dehydrated,o!==null)){if(i)e.flags&256?(Pe(e),e.flags&=-257,e=sr(t,e,n)):e.memoizedState!==null?(tn(e),e.child=t.child,e.flags|=128,e=null):(tn(e),o=l.fallback,a=e.mode,l=bu({mode:"visible",children:l.children},a),o=Bn(o,a,n,null),o.flags|=2,l.return=e,o.return=e,l.sibling=o,e.child=l,Yn(e,t.child,null,n),l=e.child,l.memoizedState=or(n),l.childLanes=rr(t,u,n),e.memoizedState=ur,e=Oa(null,l));else if(Pe(e),ms(o)){if(u=o.nextSibling&&o.nextSibling.dataset,u)var s=u.dgst;u=s,l=Error(_(419)),l.stack="",l.digest=u,Qa({value:l,source:null,stack:null}),e=sr(t,e,n)}else if(rt||Ql(t,e,n,!1),u=(n&t.childLanes)!==0,rt||u){if(u=Z,u!==null&&(l=hh(u,n),l!==0&&l!==r.retryLane))throw r.retryLane=l,Jn(t,l),Dt(u,t,l),tc;ps(o)||Ou(),e=sr(t,e,n)}else ps(o)?(e.flags|=192,e.child=t.child,e=null):(t=r.treeContext,I=It(o.nextSibling),vt=e,q=!0,sn=null,Wt=!1,t!==null&&Kh(e,t),e=ts(e,l.children),e.flags|=4096);return e}if(a)return tn(e),o=l.fallback,a=e.mode,r=t.child,s=r.sibling,l=Ce(r,{mode:"hidden",children:l.children}),l.subtreeFlags=r.subtreeFlags&65011712,s!==null?o=Ce(s,o):(o=Bn(o,a,n,null),o.flags|=2),o.return=e,l.return=e,l.sibling=o,e.child=l,Oa(null,l),l=e.child,o=t.child.memoizedState,o===null?o=or(n):(a=o.cachePool,a!==null?(r=ot._currentValue,a=a.parent!==r?{parent:r,pool:r}:a):a=Qh(),o={baseLanes:o.baseLanes|n,cachePool:a}),l.memoizedState=o,l.childLanes=rr(t,u,n),e.memoizedState=ur,Oa(t.child,l);return Pe(e),n=t.child,t=n.sibling,n=Ce(n,{mode:"visible",children:l.children}),n.return=e,n.sibling=null,t!==null&&(u=e.deletions,u===null?(e.deletions=[t],e.flags|=16):u.push(t)),e.child=n,e.memoizedState=null,n}function ts(t,e){return e=bu({mode:"visible",children:e},t.mode),e.return=t,t.child=e}function bu(t,e){return t=Mt(22,t,null,e),t.lanes=0,t}function sr(t,e,n){return Yn(e,t.child,null,n),t=ts(e,e.pendingProps.children),t.flags|=2,e.memoizedState=null,t}function Nd(t,e,n){t.lanes|=e;var l=t.alternate;l!==null&&(l.lanes|=e),Gr(t.return,e,n)}function cr(t,e,n,l,a,i){var u=t.memoizedState;u===null?t.memoizedState={isBackwards:e,rendering:null,renderingStartTime:0,last:l,tail:n,tailMode:a,treeForkCount:i}:(u.isBackwards=e,u.rendering=null,u.renderingStartTime=0,u.last=l,u.tail=n,u.tailMode=a,u.treeForkCount=i)}function jp(t,e,n){var l=e.pendingProps,a=l.revealOrder,i=l.tail;l=l.children;var u=lt.current,o=(u&2)!==0;if(o?(u=u&1|2,e.flags|=128):u&=1,k(lt,u),pt(t,e,l,n),l=q?Xa:0,!o&&t!==null&&(t.flags&128)!==0)t:for(t=e.child;t!==null;){if(t.tag===13)t.memoizedState!==null&&Nd(t,n,e);else if(t.tag===19)Nd(t,n,e);else if(t.child!==null){t.child.return=t,t=t.child;continue}if(t===e)break t;for(;t.sibling===null;){if(t.return===null||t.return===e)break t;t=t.return}t.sibling.return=t.return,t=t.sibling}switch(a){case"forwards":n=e.child;for(a=null;n!==null;)t=n.alternate,t!==null&&mu(t)===null&&(a=n),n=n.sibling;n=a,n===null?(a=e.child,e.child=null):(a=n.sibling,n.sibling=null),cr(e,!1,a,n,i,l);break;case"backwards":case"unstable_legacy-backwards":n=null,a=e.child;for(e.child=null;a!==null;){if(t=a.alternate,t!==null&&mu(t)===null){e.child=a;break}t=a.sibling,a.sibling=n,n=a,a=t}cr(e,!0,n,null,i,l);break;case"together":cr(e,!1,null,null,void 0,l);break;default:e.memoizedState=null}return e.child}function He(t,e,n){if(t!==null&&(e.dependencies=t.dependencies),_n|=e.lanes,(n&e.childLanes)===0)if(t!==null){if(Ql(t,e,n,!1),(n&e.childLanes)===0)return null}else return null;if(t!==null&&e.child!==t.child)throw Error(_(153));if(e.child!==null){t=e.child,n=Ce(t,t.pendingProps),e.child=n;for(n.return=e;t.sibling!==null;)t=t.sibling,n=n.sibling=Ce(t,t.pendingProps),n.return=e;n.sibling=null}return e.child}function ec(t,e){if((t.lanes&e)!==0)return!0;return t=t.dependencies,t!==null&&du(t)?!0:!1}function W0(t,e,n){switch(e.tag){case 3:iu(e,e.stateNode.containerInfo),Ie(e,ot,t.memoizedState.cache),Ln();break;case 27:case 5:Tr(e);break;case 4:iu(e,e.stateNode.containerInfo);break;case 10:Ie(e,e.type,e.memoizedProps.value);break;case 31:if(e.memoizedState!==null)return e.flags|=128,kr(e),null;break;case 13:var l=e.memoizedState;if(l!==null){if(l.dehydrated!==null)return Pe(e),e.flags|=128,null;if((n&e.child.childLanes)!==0)return qp(t,e,n);return Pe(e),t=He(t,e,n),t!==null?t.sibling:null}Pe(e);break;case 19:var a=(t.flags&128)!==0;if(l=(n&e.childLanes)!==0,l||(Ql(t,e,n,!1),l=(n&e.childLanes)!==0),a){if(l)return jp(t,e,n);e.flags|=128}if(a=e.memoizedState,a!==null&&(a.rendering=null,a.tail=null,a.lastEffect=null),k(lt,lt.current),l)break;else return null;case 22:return e.lanes=0,Bp(t,e,n,e.pendingProps);case 24:Ie(e,ot,t.memoizedState.cache)}return He(t,e,n)}function Hp(t,e,n){if(t!==null)if(t.memoizedProps!==e.pendingProps)rt=!0;else{if(!ec(t,n)&&(e.flags&128)===0)return rt=!1,W0(t,e,n);rt=(t.flags&131072)!==0?!0:!1}else rt=!1,q&&(e.flags&1048576)!==0&&Yh(e,Xa,e.index);switch(e.lanes=0,e.tag){case 16:t:{var l=e.pendingProps;if(t=Cn(e.elementType),e.type=t,typeof t==="function")Cs(t)?(l=Xn(t,l),e.tag=1,e=Ed(null,e,t,l,n)):(e.tag=0,e=Pr(null,e,t,l,n));else{if(t!==void 0&&t!==null){var a=t.$$typeof;if(a===bs){e.tag=11,e=gd(null,e,t,l,n);break t}else if(a===_s){e.tag=14,e=yd(null,e,t,l,n);break t}}throw e=Ar(t)||t,Error(_(306,e,""))}}return e;case 0:return Pr(t,e,e.type,e.pendingProps,n);case 1:return l=e.type,a=Xn(l,e.pendingProps),Ed(t,e,l,a,n);case 3:t:{if(iu(e,e.stateNode.containerInfo),t===null)throw Error(_(387));l=e.pendingProps;var i=e.memoizedState;a=i.element,Xr(t,e),Ca(e,l,null,n);var u=e.memoizedState;if(l=u.cache,Ie(e,ot,l),l!==i.cache&&Yr(e,[ot],n,!0),Ma(),l=u.element,i.isDehydrated)if(i={element:l,isDehydrated:!1,cache:u.cache},e.updateQueue.baseState=i,e.memoizedState=i,e.flags&256){e=Od(t,e,l,n);break t}else if(l!==a){a=$t(Error(_(424)),e),Qa(a),e=Od(t,e,l,n);break t}else{switch(t=e.stateNode.containerInfo,t.nodeType){case 9:t=t.body;break;default:t=t.nodeName==="HTML"?t.ownerDocument.body:t}I=It(t.firstChild),vt=e,q=!0,sn=null,Wt=!0,n=Jh(e,null,l,n);for(e.child=n;n;)n.flags=n.flags&-3|4096,n=n.sibling}else{if(Ln(),l===a){e=He(t,e,n);break t}pt(t,e,l,n)}e=e.child}return e;case 26:return Ii(t,e),t===null?(n=Xd(e.type,null,e.pendingProps,null))?e.memoizedState=n:q||(n=e.type,t=e.pendingProps,l=Du(rn.current).createElement(n),l[mt]=e,l[Tt]=t,yt(l,n,t),dt(l),e.stateNode=l):e.memoizedState=Xd(e.type,t.memoizedProps,e.pendingProps,t.memoizedState),null;case 27:return Tr(e),t===null&&q&&(l=e.stateNode=zm(e.type,e.pendingProps,rn.current),vt=e,Wt=!0,a=I,En(e.type)?(vs=a,I=It(l.firstChild)):I=a),pt(t,e,e.pendingProps.children,n),Ii(t,e),t===null&&(e.flags|=4194304),e.child;case 5:if(t===null&&q){if(a=l=I)l=N_(l,e.type,e.pendingProps,Wt),l!==null?(e.stateNode=l,vt=e,I=It(l.firstChild),Wt=!1,a=!0):a=!1;a||yn(e)}return Tr(e),a=e.type,i=e.pendingProps,u=t!==null?t.memoizedProps:null,l=i.children,ds(a,i)?l=null:u!==null&&ds(a,u)&&(e.flags|=32),e.memoizedState!==null&&(a=Ys(t,e,G0,null,null,n),Fa._currentValue=a),Ii(t,e),pt(t,e,l,n),e.child;case 6:if(t===null&&q){if(t=n=I)n=x_(n,e.pendingProps,Wt),n!==null?(e.stateNode=n,vt=e,I=null,t=!0):t=!1;t||yn(e)}return null;case 13:return qp(t,e,n);case 4:return iu(e,e.stateNode.containerInfo),l=e.pendingProps,t===null?e.child=Yn(e,null,l,n):pt(t,e,l,n),e.child;case 11:return gd(t,e,e.type,e.pendingProps,n);case 7:return pt(t,e,e.pendingProps,n),e.child;case 8:return pt(t,e,e.pendingProps.children,n),e.child;case 12:return pt(t,e,e.pendingProps.children,n),e.child;case 10:return l=e.pendingProps,Ie(e,e.type,l.value),pt(t,e,l.children,n),e.child;case 9:return a=e.type._context,l=e.pendingProps.children,Gn(e),a=gt(a),l=l(a),e.flags|=1,pt(t,e,l,n),e.child;case 14:return yd(t,e,e.type,e.pendingProps,n);case 15:return Vp(t,e,e.type,e.pendingProps,n);case 19:return jp(t,e,n);case 31:return $0(t,e,n);case 22:return Bp(t,e,n,e.pendingProps);case 24:return Gn(e),l=gt(ot),t===null?(a=qs(),a===null&&(a=Z,i=Bs(),a.pooledCache=i,i.refCount++,i!==null&&(a.pooledCacheLanes|=n),a=i),e.memoizedState={parent:l,cache:a},Hs(e),Ie(e,ot,a)):((t.lanes&n)!==0&&(Xr(t,e),Ca(e,null,null,n),Ma()),a=t.memoizedState,i=e.memoizedState,a.parent!==l?(a={parent:l,cache:l},e.memoizedState=a,e.lanes===0&&(e.memoizedState=e.updateQueue.baseState=a),Ie(e,ot,l)):(l=i.cache,Ie(e,ot,l),l!==a.cache&&Yr(e,[ot],n,!0))),pt(t,e,e.pendingProps.children,n),e.child;case 29:throw e.pendingProps}throw Error(_(156,e.tag))}function Ne(t){t.flags|=4}function fr(t,e,n,l,a){if(e=(t.mode&32)!==0)e=!1;if(e){if(t.flags|=16777216,(a&335544128)===a)if(t.stateNode.complete)t.flags|=8192;else if(sm())t.flags|=8192;else throw jn=hu,js}else t.flags&=-16777217}function xd(t,e){if(e.type!=="stylesheet"||(e.state.loading&4)!==0)t.flags&=-16777217;else if(t.flags|=16777216,!Mm(e))if(sm())t.flags|=8192;else throw jn=hu,js}function qi(t,e){e!==null&&(t.flags|=4),t.flags&16384&&(e=t.tag!==22?ch():536870912,t.lanes|=e,jl|=e)}function ma(t,e){if(!q)switch(t.tailMode){case"hidden":e=t.tail;for(var n=null;e!==null;)e.alternate!==null&&(n=e),e=e.sibling;n===null?t.tail=null:n.sibling=null;break;case"collapsed":n=t.tail;for(var l=null;n!==null;)n.alternate!==null&&(l=n),n=n.sibling;l===null?e||t.tail===null?t.tail=null:t.tail.sibling=null:l.sibling=null}}function F(t){var e=t.alternate!==null&&t.alternate.child===t.child,n=0,l=0;if(e)for(var a=t.child;a!==null;)n|=a.lanes|a.childLanes,l|=a.subtreeFlags&65011712,l|=a.flags&65011712,a.return=t,a=a.sibling;else for(a=t.child;a!==null;)n|=a.lanes|a.childLanes,l|=a.subtreeFlags,l|=a.flags,a.return=t,a=a.sibling;return t.subtreeFlags|=l,t.childLanes=n,e}function F0(t,e,n){var l=e.pendingProps;switch(Vs(e),e.tag){case 16:case 15:case 0:case 11:case 7:case 8:case 12:case 9:case 14:return F(e),null;case 1:return F(e),null;case 3:if(n=e.stateNode,l=null,t!==null&&(l=t.memoizedState.cache),e.memoizedState.cache!==l&&(e.flags|=2048),Ue(ot),Ml(),n.pendingContext&&(n.context=n.pendingContext,n.pendingContext=null),t===null||t.child===null)rl(e)?Ne(e):t===null||t.memoizedState.isDehydrated&&(e.flags&256)===0||(e.flags|=1024,nr());return F(e),null;case 26:var{type:a,memoizedState:i}=e;return t===null?(Ne(e),i!==null?(F(e),xd(e,i)):(F(e),fr(e,a,null,l,n))):i?i!==t.memoizedState?(Ne(e),F(e),xd(e,i)):(F(e),e.flags&=-16777217):(t=t.memoizedProps,t!==l&&Ne(e),F(e),fr(e,a,t,l,n)),null;case 27:if(uu(e),n=rn.current,a=e.type,t!==null&&e.stateNode!=null)t.memoizedProps!==l&&Ne(e);else{if(!l){if(e.stateNode===null)throw Error(_(166));return F(e),null}t=ve.current,rl(e)?td(e,t):(t=zm(a,l,n),e.stateNode=t,Ne(e))}return F(e),null;case 5:if(uu(e),a=e.type,t!==null&&e.stateNode!=null)t.memoizedProps!==l&&Ne(e);else{if(!l){if(e.stateNode===null)throw Error(_(166));return F(e),null}if(i=ve.current,rl(e))td(e,i);else{var u=Du(rn.current);switch(i){case 1:i=u.createElementNS("http://www.w3.org/2000/svg",a);break;case 2:i=u.createElementNS("http://www.w3.org/1998/Math/MathML",a);break;default:switch(a){case"svg":i=u.createElementNS("http://www.w3.org/2000/svg",a);break;case"math":i=u.createElementNS("http://www.w3.org/1998/Math/MathML",a);break;case"script":i=u.createElement("div"),i.innerHTML="<script></script>",i=i.removeChild(i.firstChild);break;case"select":i=typeof l.is==="string"?u.createElement("select",{is:l.is}):u.createElement("select"),l.multiple?i.multiple=!0:l.size&&(i.size=l.size);break;default:i=typeof l.is==="string"?u.createElement(a,{is:l.is}):u.createElement(a)}}i[mt]=e,i[Tt]=l;t:for(u=e.child;u!==null;){if(u.tag===5||u.tag===6)i.appendChild(u.stateNode);else if(u.tag!==4&&u.tag!==27&&u.child!==null){u.child.return=u,u=u.child;continue}if(u===e)break t;for(;u.sibling===null;){if(u.return===null||u.return===e)break t;u=u.return}u.sibling.return=u.return,u=u.sibling}e.stateNode=i;t:switch(yt(i,a,l),a){case"button":case"input":case"select":case"textarea":l=!!l.autoFocus;break t;case"img":l=!0;break t;default:l=!1}l&&Ne(e)}}return F(e),fr(e,e.type,t===null?null:t.memoizedProps,e.pendingProps,n),null;case 6:if(t&&e.stateNode!=null)t.memoizedProps!==l&&Ne(e);else{if(typeof l!=="string"&&e.stateNode===null)throw Error(_(166));if(t=rn.current,rl(e)){if(t=e.stateNode,n=e.memoizedProps,l=null,a=vt,a!==null)switch(a.tag){case 27:case 5:l=a.memoizedProps}t[mt]=e,t=t.nodeValue===n||l!==null&&l.suppressHydrationWarning===!0||xm(t.nodeValue,n)?!0:!1,t||yn(e,!0)}else t=Du(t).createTextNode(l),t[mt]=e,e.stateNode=t}return F(e),null;case 31:if(n=e.memoizedState,t===null||t.memoizedState!==null){if(l=rl(e),n!==null){if(t===null){if(!l)throw Error(_(318));if(t=e.memoizedState,t=t!==null?t.dehydrated:null,!t)throw Error(_(557));t[mt]=e}else Ln(),(e.flags&128)===0&&(e.memoizedState=null),e.flags|=4;F(e),t=!1}else n=nr(),t!==null&&t.memoizedState!==null&&(t.memoizedState.hydrationErrors=n),t=!0;if(!t){if(e.flags&256)return Rt(e),e;return Rt(e),null}if((e.flags&128)!==0)throw Error(_(558))}return F(e),null;case 13:if(l=e.memoizedState,t===null||t.memoizedState!==null&&t.memoizedState.dehydrated!==null){if(a=rl(e),l!==null&&l.dehydrated!==null){if(t===null){if(!a)throw Error(_(318));if(a=e.memoizedState,a=a!==null?a.dehydrated:null,!a)throw Error(_(317));a[mt]=e}else Ln(),(e.flags&128)===0&&(e.memoizedState=null),e.flags|=4;F(e),a=!1}else a=nr(),t!==null&&t.memoizedState!==null&&(t.memoizedState.hydrationErrors=a),a=!0;if(!a){if(e.flags&256)return Rt(e),e;return Rt(e),null}}if(Rt(e),(e.flags&128)!==0)return e.lanes=n,e;return n=l!==null,t=t!==null&&t.memoizedState!==null,n&&(l=e.child,a=null,l.alternate!==null&&l.alternate.memoizedState!==null&&l.alternate.memoizedState.cachePool!==null&&(a=l.alternate.memoizedState.cachePool.pool),i=null,l.memoizedState!==null&&l.memoizedState.cachePool!==null&&(i=l.memoizedState.cachePool.pool),i!==a&&(l.flags|=2048)),n!==t&&n&&(e.child.flags|=8192),qi(e,e.updateQueue),F(e),null;case 4:return Ml(),t===null&&rc(e.stateNode.containerInfo),F(e),null;case 10:return Ue(e.type),F(e),null;case 19:if(ht(lt),l=e.memoizedState,l===null)return F(e),null;if(a=(e.flags&128)!==0,i=l.rendering,i===null)if(a)ma(l,!1);else{if(nt!==0||t!==null&&(t.flags&128)!==0)for(t=e.child;t!==null;){if(i=mu(t),i!==null){e.flags|=128,ma(l,!1),t=i.updateQueue,e.updateQueue=t,qi(e,t),e.subtreeFlags=0,t=n;for(n=e.child;n!==null;)Lh(n,t),n=n.sibling;return k(lt,lt.current&1|2),q&&Te(e,l.treeForkCount),e.child}t=t.sibling}l.tail!==null&&Ut()>Su&&(e.flags|=128,a=!0,ma(l,!1),e.lanes=4194304)}else{if(!a)if(t=mu(i),t!==null){if(e.flags|=128,a=!0,t=t.updateQueue,e.updateQueue=t,qi(e,t),ma(l,!0),l.tail===null&&l.tailMode==="hidden"&&!i.alternate&&!q)return F(e),null}else 2*Ut()-l.renderingStartTime>Su&&n!==536870912&&(e.flags|=128,a=!0,ma(l,!1),e.lanes=4194304);l.isBackwards?(i.sibling=e.child,e.child=i):(t=l.last,t!==null?t.sibling=i:e.child=i,l.last=i)}if(l.tail!==null)return t=l.tail,l.rendering=t,l.tail=t.sibling,l.renderingStartTime=Ut(),t.sibling=null,n=lt.current,k(lt,a?n&1|2:n&1),q&&Te(e,l.treeForkCount),t;return F(e),null;case 22:case 23:return Rt(e),Ls(),l=e.memoizedState!==null,t!==null?t.memoizedState!==null!==l&&(e.flags|=8192):l&&(e.flags|=8192),l?(n&536870912)!==0&&(e.flags&128)===0&&(F(e),e.subtreeFlags&6&&(e.flags|=8192)):F(e),n=e.updateQueue,n!==null&&qi(e,n.retryQueue),n=null,t!==null&&t.memoizedState!==null&&t.memoizedState.cachePool!==null&&(n=t.memoizedState.cachePool.pool),l=null,e.memoizedState!==null&&e.memoizedState.cachePool!==null&&(l=e.memoizedState.cachePool.pool),l!==n&&(e.flags|=2048),t!==null&&ht(qn),null;case 24:return n=null,t!==null&&(n=t.memoizedState.cache),e.memoizedState.cache!==n&&(e.flags|=2048),Ue(ot),F(e),null;case 25:return null;case 30:return null}throw Error(_(156,e.tag))}function I0(t,e){switch(Vs(e),e.tag){case 1:return t=e.flags,t&65536?(e.flags=t&-65537|128,e):null;case 3:return Ue(ot),Ml(),t=e.flags,(t&65536)!==0&&(t&128)===0?(e.flags=t&-65537|128,e):null;case 26:case 27:case 5:return uu(e),null;case 31:if(e.memoizedState!==null){if(Rt(e),e.alternate===null)throw Error(_(340));Ln()}return t=e.flags,t&65536?(e.flags=t&-65537|128,e):null;case 13:if(Rt(e),t=e.memoizedState,t!==null&&t.dehydrated!==null){if(e.alternate===null)throw Error(_(340));Ln()}return t=e.flags,t&65536?(e.flags=t&-65537|128,e):null;case 19:return ht(lt),null;case 4:return Ml(),null;case 10:return Ue(e.type),null;case 22:case 23:return Rt(e),Ls(),t!==null&&ht(qn),t=e.flags,t&65536?(e.flags=t&-65537|128,e):null;case 24:return Ue(ot),null;case 25:return null;default:return null}}function Lp(t,e){switch(Vs(e),e.tag){case 3:Ue(ot),Ml();break;case 26:case 27:case 5:uu(e);break;case 4:Ml();break;case 31:e.memoizedState!==null&&Rt(e);break;case 13:Rt(e);break;case 19:ht(lt);break;case 10:Ue(e.type);break;case 22:case 23:Rt(e),Ls(),t!==null&&ht(qn);break;case 24:Ue(ot)}}function ri(t,e){try{var n=e.updateQueue,l=n!==null?n.lastEffect:null;if(l!==null){var a=l.next;n=a;do{if((n.tag&t)===t){l=void 0;var{create:i,inst:u}=n;l=i(),u.destroy=l}n=n.next}while(n!==a)}}catch(o){K(e,e.return,o)}}function bn(t,e,n){try{var l=e.updateQueue,a=l!==null?l.lastEffect:null;if(a!==null){var i=a.next;l=i;do{if((l.tag&t)===t){var u=l.inst,o=u.destroy;if(o!==void 0){u.destroy=void 0,a=e;var r=n,s=o;try{s()}catch(h){K(a,r,h)}}}l=l.next}while(l!==i)}}catch(h){K(e,e.return,h)}}function Gp(t){var e=t.updateQueue;if(e!==null){var n=t.stateNode;try{Wh(e,n)}catch(l){K(t,t.return,l)}}}function Yp(t,e,n){n.props=Xn(t.type,t.memoizedProps),n.state=t.memoizedState;try{n.componentWillUnmount()}catch(l){K(t,e,l)}}function Va(t,e){try{var n=t.ref;if(n!==null){switch(t.tag){case 26:case 27:case 5:var l=t.stateNode;break;case 30:l=t.stateNode;break;default:l=t.stateNode}typeof n==="function"?t.refCleanup=n(l):n.current=l}}catch(a){K(t,e,a)}}function me(t,e){var{ref:n,refCleanup:l}=t;if(n!==null)if(typeof l==="function")try{l()}catch(a){K(t,e,a)}finally{t.refCleanup=null,t=t.alternate,t!=null&&(t.refCleanup=null)}else if(typeof n==="function")try{n(null)}catch(a){K(t,e,a)}else n.current=null}function Kp(t){var{type:e,memoizedProps:n,stateNode:l}=t;try{t:switch(e){case"button":case"input":case"select":case"textarea":n.autoFocus&&l.focus();break t;case"img":n.src?l.src=n.src:n.srcSet&&(l.srcset=n.srcSet)}}catch(a){K(t,t.return,a)}}function dr(t,e,n){try{var l=t.stateNode;y_(l,t.type,n,e),l[Tt]=e}catch(a){K(t,t.return,a)}}function Xp(t){return t.tag===5||t.tag===3||t.tag===26||t.tag===27&&En(t.type)||t.tag===4}function hr(t){t:for(;;){for(;t.sibling===null;){if(t.return===null||Xp(t.return))return null;t=t.return}t.sibling.return=t.return;for(t=t.sibling;t.tag!==5&&t.tag!==6&&t.tag!==18;){if(t.tag===27&&En(t.type))continue t;if(t.flags&2)continue t;if(t.child===null||t.tag===4)continue t;else t.child.return=t,t=t.child}if(!(t.flags&2))return t.stateNode}}function es(t,e,n){var l=t.tag;if(l===5||l===6)t=t.stateNode,e?(n.nodeType===9?n.body:n.nodeName==="HTML"?n.ownerDocument.body:n).insertBefore(t,e):(e=n.nodeType===9?n.body:n.nodeName==="HTML"?n.ownerDocument.body:n,e.appendChild(t),n=n._reactRootContainer,n!==null&&n!==void 0||e.onclick!==null||(e.onclick=Re));else if(l!==4&&(l===27&&En(t.type)&&(n=t.stateNode,e=null),t=t.child,t!==null))for(es(t,e,n),t=t.sibling;t!==null;)es(t,e,n),t=t.sibling}function _u(t,e,n){var l=t.tag;if(l===5||l===6)t=t.stateNode,e?n.insertBefore(t,e):n.appendChild(t);else if(l!==4&&(l===27&&En(t.type)&&(n=t.stateNode),t=t.child,t!==null))for(_u(t,e,n),t=t.sibling;t!==null;)_u(t,e,n),t=t.sibling}function Qp(t){var{stateNode:e,memoizedProps:n}=t;try{for(var l=t.type,a=e.attributes;a.length;)e.removeAttributeNode(a[0]);yt(e,l,n),e[mt]=t,e[Tt]=n}catch(i){K(t,t.return,i)}}function P0(t,e){if(t=t.containerInfo,cs=Ru,t=Mh(t),ws(t)){if("selectionStart"in t)var n={start:t.selectionStart,end:t.selectionEnd};else t:{n=(n=t.ownerDocument)&&n.defaultView||window;var l=n.getSelection&&n.getSelection();if(l&&l.rangeCount!==0){n=l.anchorNode;var{anchorOffset:a,focusNode:i}=l;l=l.focusOffset;try{n.nodeType,i.nodeType}catch(A){n=null;break t}var u=0,o=-1,r=-1,s=0,h=0,g=t,d=null;e:for(;;){for(var v;;){if(g!==n||a!==0&&g.nodeType!==3||(o=u+a),g!==i||l!==0&&g.nodeType!==3||(r=u+l),g.nodeType===3&&(u+=g.nodeValue.length),(v=g.firstChild)===null)break;d=g,g=v}for(;;){if(g===t)break e;if(d===n&&++s===a&&(o=u),d===i&&++h===l&&(r=u),(v=g.nextSibling)!==null)break;g=d,d=g.parentNode}g=v}n=o===-1||r===-1?null:{start:o,end:r}}else n=null}n=n||{start:0,end:0}}else n=null;fs={focusedElem:t,selectionRange:n},Ru=!1;for(ft=e;ft!==null;)if(e=ft,t=e.child,(e.subtreeFlags&1028)!==0&&t!==null)t.return=e,ft=t;else for(;ft!==null;){switch(e=ft,i=e.alternate,t=e.flags,e.tag){case 0:if((t&4)!==0&&(t=e.updateQueue,t=t!==null?t.events:null,t!==null))for(n=0;n<t.length;n++)a=t[n],a.ref.impl=a.nextImpl;break;case 11:case 15:break;case 1:if((t&1024)!==0&&i!==null){t=void 0,n=e,a=i.memoizedProps,i=i.memoizedState,l=n.stateNode;try{var E=Xn(n.type,a);t=l.getSnapshotBeforeUpdate(E,i),l.__reactInternalSnapshotBeforeUpdate=t}catch(A){K(n,n.return,A)}}break;case 3:if((t&1024)!==0){if(t=e.stateNode.containerInfo,n=t.nodeType,n===9)hs(t);else if(n===1)switch(t.nodeName){case"HEAD":case"HTML":case"BODY":hs(t);break;default:t.textContent=""}}break;case 5:case 26:case 27:case 6:case 4:case 17:break;default:if((t&1024)!==0)throw Error(_(163))}if(t=e.sibling,t!==null){t.return=e.return,ft=t;break}ft=e.return}}function Zp(t,e,n){var l=n.flags;switch(n.tag){case 0:case 11:case 15:Ae(t,n),l&4&&ri(5,n);break;case 1:if(Ae(t,n),l&4)if(t=n.stateNode,e===null)try{t.componentDidMount()}catch(u){K(n,n.return,u)}else{var a=Xn(n.type,e.memoizedProps);e=e.memoizedState;try{t.componentDidUpdate(a,e,t.__reactInternalSnapshotBeforeUpdate)}catch(u){K(n,n.return,u)}}l&64&&Gp(n),l&512&&Va(n,n.return);break;case 3:if(Ae(t,n),l&64&&(t=n.updateQueue,t!==null)){if(e=null,n.child!==null)switch(n.child.tag){case 27:case 5:e=n.child.stateNode;break;case 1:e=n.child.stateNode}try{Wh(t,e)}catch(u){K(n,n.return,u)}}break;case 27:e===null&&l&4&&Qp(n);case 26:case 5:Ae(t,n),e===null&&l&4&&Kp(n),l&512&&Va(n,n.return);break;case 12:Ae(t,n);break;case 31:Ae(t,n),l&4&&$p(t,n);break;case 13:Ae(t,n),l&4&&Wp(t,n),l&64&&(t=n.memoizedState,t!==null&&(t=t.dehydrated,t!==null&&(n=r_.bind(null,n),A_(t,n))));break;case 22:if(l=n.memoizedState!==null||ze,!l){e=e!==null&&e.memoizedState!==null||ut,a=ze;var i=ut;ze=l,(ut=e)&&!i?De(t,n,(n.subtreeFlags&8772)!==0):Ae(t,n),ze=a,ut=i}break;case 30:break;default:Ae(t,n)}}function kp(t){var e=t.alternate;e!==null&&(t.alternate=null,kp(e)),t.child=null,t.deletions=null,t.sibling=null,t.tag===5&&(e=t.stateNode,e!==null&&Ns(e)),t.stateNode=null,t.return=null,t.dependencies=null,t.memoizedProps=null,t.memoizedState=null,t.pendingProps=null,t.stateNode=null,t.updateQueue=null}function xe(t,e,n){for(n=n.child;n!==null;)Jp(t,e,n),n=n.sibling}function Jp(t,e,n){if(Vt&&typeof Vt.onCommitFiberUnmount==="function")try{Vt.onCommitFiberUnmount(ei,n)}catch(i){}switch(n.tag){case 26:ut||me(n,e),xe(t,e,n),n.memoizedState?n.memoizedState.count--:n.stateNode&&(n=n.stateNode,n.parentNode.removeChild(n));break;case 27:ut||me(n,e);var l=tt,a=xt;En(n.type)&&(tt=n.stateNode,xt=!1),xe(t,e,n),Ha(n.stateNode),tt=l,xt=a;break;case 5:ut||me(n,e);case 6:if(l=tt,a=xt,tt=null,xe(t,e,n),tt=l,xt=a,tt!==null)if(xt)try{(tt.nodeType===9?tt.body:tt.nodeName==="HTML"?tt.ownerDocument.body:tt).removeChild(n.stateNode)}catch(i){K(n,e,i)}else try{tt.removeChild(n.stateNode)}catch(i){K(n,e,i)}break;case 18:tt!==null&&(xt?(t=tt,Hd(t.nodeType===9?t.body:t.nodeName==="HTML"?t.ownerDocument.body:t,n.stateNode),Yl(t)):Hd(tt,n.stateNode));break;case 4:l=tt,a=xt,tt=n.stateNode.containerInfo,xt=!0,xe(t,e,n),tt=l,xt=a;break;case 0:case 11:case 14:case 15:bn(2,n,e),ut||bn(4,n,e),xe(t,e,n);break;case 1:ut||(me(n,e),l=n.stateNode,typeof l.componentWillUnmount==="function"&&Yp(n,e,l)),xe(t,e,n);break;case 21:xe(t,e,n);break;case 22:ut=(l=ut)||n.memoizedState!==null,xe(t,e,n),ut=l;break;default:xe(t,e,n)}}function $p(t,e){if(e.memoizedState===null&&(t=e.alternate,t!==null&&(t=t.memoizedState,t!==null))){t=t.dehydrated;try{Yl(t)}catch(n){K(e,e.return,n)}}}function Wp(t,e){if(e.memoizedState===null&&(t=e.alternate,t!==null&&(t=t.memoizedState,t!==null&&(t=t.dehydrated,t!==null))))try{Yl(t)}catch(n){K(e,e.return,n)}}function t_(t){switch(t.tag){case 31:case 13:case 19:var e=t.stateNode;return e===null&&(e=t.stateNode=new Ad),e;case 22:return t=t.stateNode,e=t._retryCache,e===null&&(e=t._retryCache=new Ad),e;default:throw Error(_(435,t.tag))}}function ji(t,e){var n=t_(t);e.forEach(function(l){if(!n.has(l)){n.add(l);var a=s_.bind(null,t,l);l.then(a,a)}})}function Ot(t,e){var n=e.deletions;if(n!==null)for(var l=0;l<n.length;l++){var a=n[l],i=t,u=e,o=u;t:for(;o!==null;){switch(o.tag){case 27:if(En(o.type)){tt=o.stateNode,xt=!1;break t}break;case 5:tt=o.stateNode,xt=!1;break t;case 3:case 4:tt=o.stateNode.containerInfo,xt=!0;break t}o=o.return}if(tt===null)throw Error(_(160));Jp(i,u,a),tt=null,xt=!1,i=a.alternate,i!==null&&(i.return=null),a.return=null}if(e.subtreeFlags&13886)for(e=e.child;e!==null;)Fp(e,t),e=e.sibling}function Fp(t,e){var{alternate:n,flags:l}=t;switch(t.tag){case 0:case 11:case 14:case 15:Ot(e,t),Nt(t),l&4&&(bn(3,t,t.return),ri(3,t),bn(5,t,t.return));break;case 1:Ot(e,t),Nt(t),l&512&&(ut||n===null||me(n,n.return)),l&64&&ze&&(t=t.updateQueue,t!==null&&(l=t.callbacks,l!==null&&(n=t.shared.hiddenCallbacks,t.shared.hiddenCallbacks=n===null?l:n.concat(l))));break;case 26:var a=ie;if(Ot(e,t),Nt(t),l&512&&(ut||n===null||me(n,n.return)),l&4){var i=n!==null?n.memoizedState:null;if(l=t.memoizedState,n===null)if(l===null)if(t.stateNode===null){t:{l=t.type,n=t.memoizedProps,a=a.ownerDocument||a;e:switch(l){case"title":if(i=a.getElementsByTagName("title")[0],!i||i[ai]||i[mt]||i.namespaceURI==="http://www.w3.org/2000/svg"||i.hasAttribute("itemprop"))i=a.createElement(l),a.head.insertBefore(i,a.querySelector("head > title"));yt(i,l,n),i[mt]=t,dt(i),l=i;break t;case"link":var u=Zd("link","href",a).get(l+(n.href||""));if(u){for(var o=0;o<u.length;o++)if(i=u[o],i.getAttribute("href")===(n.href==null||n.href===""?null:n.href)&&i.getAttribute("rel")===(n.rel==null?null:n.rel)&&i.getAttribute("title")===(n.title==null?null:n.title)&&i.getAttribute("crossorigin")===(n.crossOrigin==null?null:n.crossOrigin)){u.splice(o,1);break e}}i=a.createElement(l),yt(i,l,n),a.head.appendChild(i);break;case"meta":if(u=Zd("meta","content",a).get(l+(n.content||""))){for(o=0;o<u.length;o++)if(i=u[o],i.getAttribute("content")===(n.content==null?null:""+n.content)&&i.getAttribute("name")===(n.name==null?null:n.name)&&i.getAttribute("property")===(n.property==null?null:n.property)&&i.getAttribute("http-equiv")===(n.httpEquiv==null?null:n.httpEquiv)&&i.getAttribute("charset")===(n.charSet==null?null:n.charSet)){u.splice(o,1);break e}}i=a.createElement(l),yt(i,l,n),a.head.appendChild(i);break;default:throw Error(_(468,l))}i[mt]=t,dt(i),l=i}t.stateNode=l}else kd(a,t.type,t.stateNode);else t.stateNode=Qd(a,l,t.memoizedProps);else i!==l?(i===null?n.stateNode!==null&&(n=n.stateNode,n.parentNode.removeChild(n)):i.count--,l===null?kd(a,t.type,t.stateNode):Qd(a,l,t.memoizedProps)):l===null&&t.stateNode!==null&&dr(t,t.memoizedProps,n.memoizedProps)}break;case 27:Ot(e,t),Nt(t),l&512&&(ut||n===null||me(n,n.return)),n!==null&&l&4&&dr(t,t.memoizedProps,n.memoizedProps);break;case 5:if(Ot(e,t),Nt(t),l&512&&(ut||n===null||me(n,n.return)),t.flags&32){a=t.stateNode;try{Ul(a,"")}catch(E){K(t,t.return,E)}}l&4&&t.stateNode!=null&&(a=t.memoizedProps,dr(t,a,n!==null?n.memoizedProps:a)),l&1024&&(pr=!0);break;case 6:if(Ot(e,t),Nt(t),l&4){if(t.stateNode===null)throw Error(_(162));l=t.memoizedProps,n=t.stateNode;try{n.nodeValue=l}catch(E){K(t,t.return,E)}}break;case 3:if(eu=null,a=ie,ie=Tu(e.containerInfo),Ot(e,t),ie=a,Nt(t),l&4&&n!==null&&n.memoizedState.isDehydrated)try{Yl(e.containerInfo)}catch(E){K(t,t.return,E)}pr&&(pr=!1,Ip(t));break;case 4:l=ie,ie=Tu(t.stateNode.containerInfo),Ot(e,t),Nt(t),ie=l;break;case 12:Ot(e,t),Nt(t);break;case 31:Ot(e,t),Nt(t),l&4&&(l=t.updateQueue,l!==null&&(t.updateQueue=null,ji(t,l)));break;case 13:Ot(e,t),Nt(t),t.child.flags&8192&&t.memoizedState!==null!==(n!==null&&n.memoizedState!==null)&&(Qu=Ut()),l&4&&(l=t.updateQueue,l!==null&&(t.updateQueue=null,ji(t,l)));break;case 22:a=t.memoizedState!==null;var r=n!==null&&n.memoizedState!==null,s=ze,h=ut;if(ze=s||a,ut=h||r,Ot(e,t),ut=h,ze=s,Nt(t),l&8192)t:for(e=t.stateNode,e._visibility=a?e._visibility&-2:e._visibility|1,a&&(n===null||r||ze||ut||Un(t)),n=null,e=t;;){if(e.tag===5||e.tag===26){if(n===null){r=n=e;try{if(i=r.stateNode,a)u=i.style,typeof u.setProperty==="function"?u.setProperty("display","none","important"):u.display="none";else{o=r.stateNode;var g=r.memoizedProps.style,d=g!==void 0&&g!==null&&g.hasOwnProperty("display")?g.display:null;o.style.display=d==null||typeof d==="boolean"?"":(""+d).trim()}}catch(E){K(r,r.return,E)}}}else if(e.tag===6){if(n===null){r=e;try{r.stateNode.nodeValue=a?"":r.memoizedProps}catch(E){K(r,r.return,E)}}}else if(e.tag===18){if(n===null){r=e;try{var v=r.stateNode;a?Ld(v,!0):Ld(r.stateNode,!1)}catch(E){K(r,r.return,E)}}}else if((e.tag!==22&&e.tag!==23||e.memoizedState===null||e===t)&&e.child!==null){e.child.return=e,e=e.child;continue}if(e===t)break t;for(;e.sibling===null;){if(e.return===null||e.return===t)break t;n===e&&(n=null),e=e.return}n===e&&(n=null),e.sibling.return=e.return,e=e.sibling}l&4&&(l=t.updateQueue,l!==null&&(n=l.retryQueue,n!==null&&(l.retryQueue=null,ji(t,n))));break;case 19:Ot(e,t),Nt(t),l&4&&(l=t.updateQueue,l!==null&&(t.updateQueue=null,ji(t,l)));break;case 30:break;case 21:break;default:Ot(e,t),Nt(t)}}function Nt(t){var e=t.flags;if(e&2){try{for(var n,l=t.return;l!==null;){if(Xp(l)){n=l;break}l=l.return}if(n==null)throw Error(_(160));switch(n.tag){case 27:var a=n.stateNode,i=hr(t);_u(t,i,a);break;case 5:var u=n.stateNode;n.flags&32&&(Ul(u,""),n.flags&=-33);var o=hr(t);_u(t,o,u);break;case 3:case 4:var r=n.stateNode.containerInfo,s=hr(t);es(t,s,r);break;default:throw Error(_(161))}}catch(h){K(t,t.return,h)}t.flags&=-3}e&4096&&(t.flags&=-4097)}function Ip(t){if(t.subtreeFlags&1024)for(t=t.child;t!==null;){var e=t;Ip(e),e.tag===5&&e.flags&1024&&e.stateNode.reset(),t=t.sibling}}function Ae(t,e){if(e.subtreeFlags&8772)for(e=e.child;e!==null;)Zp(t,e.alternate,e),e=e.sibling}function Un(t){for(t=t.child;t!==null;){var e=t;switch(e.tag){case 0:case 11:case 14:case 15:bn(4,e,e.return),Un(e);break;case 1:me(e,e.return);var n=e.stateNode;typeof n.componentWillUnmount==="function"&&Yp(e,e.return,n),Un(e);break;case 27:Ha(e.stateNode);case 26:case 5:me(e,e.return),Un(e);break;case 22:e.memoizedState===null&&Un(e);break;case 30:Un(e);break;default:Un(e)}t=t.sibling}}function De(t,e,n){n=n&&(e.subtreeFlags&8772)!==0;for(e=e.child;e!==null;){var l=e.alternate,a=t,i=e,u=i.flags;switch(i.tag){case 0:case 11:case 15:De(a,i,n),ri(4,i);break;case 1:if(De(a,i,n),l=i,a=l.stateNode,typeof a.componentDidMount==="function")try{a.componentDidMount()}catch(s){K(l,l.return,s)}if(l=i,a=l.updateQueue,a!==null){var o=l.stateNode;try{var r=a.shared.hiddenCallbacks;if(r!==null)for(a.shared.hiddenCallbacks=null,a=0;a<r.length;a++)$h(r[a],o)}catch(s){K(l,l.return,s)}}n&&u&64&&Gp(i),Va(i,i.return);break;case 27:Qp(i);case 26:case 5:De(a,i,n),n&&l===null&&u&4&&Kp(i),Va(i,i.return);break;case 12:De(a,i,n);break;case 31:De(a,i,n),n&&u&4&&$p(a,i);break;case 13:De(a,i,n),n&&u&4&&Wp(a,i);break;case 22:i.memoizedState===null&&De(a,i,n),Va(i,i.return);break;case 30:break;default:De(a,i,n)}e=e.sibling}}function nc(t,e){var n=null;t!==null&&t.memoizedState!==null&&t.memoizedState.cachePool!==null&&(n=t.memoizedState.cachePool.pool),t=null,e.memoizedState!==null&&e.memoizedState.cachePool!==null&&(t=e.memoizedState.cachePool.pool),t!==n&&(t!=null&&t.refCount++,n!=null&&ui(n))}function lc(t,e){t=null,e.alternate!==null&&(t=e.alternate.memoizedState.cache),e=e.memoizedState.cache,e!==t&&(e.refCount++,t!=null&&ui(t))}function ae(t,e,n,l){if(e.subtreeFlags&10256)for(e=e.child;e!==null;)Pp(t,e,n,l),e=e.sibling}function Pp(t,e,n,l){var a=e.flags;switch(e.tag){case 0:case 11:case 15:ae(t,e,n,l),a&2048&&ri(9,e);break;case 1:ae(t,e,n,l);break;case 3:ae(t,e,n,l),a&2048&&(t=null,e.alternate!==null&&(t=e.alternate.memoizedState.cache),e=e.memoizedState.cache,e!==t&&(e.refCount++,t!=null&&ui(t)));break;case 12:if(a&2048){ae(t,e,n,l),t=e.stateNode;try{var i=e.memoizedProps,u=i.id,o=i.onPostCommit;typeof o==="function"&&o(u,e.alternate===null?"mount":"update",t.passiveEffectDuration,-0)}catch(r){K(e,e.return,r)}}else ae(t,e,n,l);break;case 31:ae(t,e,n,l);break;case 13:ae(t,e,n,l);break;case 23:break;case 22:i=e.stateNode,u=e.alternate,e.memoizedState!==null?i._visibility&2?ae(t,e,n,l):Ba(t,e):i._visibility&2?ae(t,e,n,l):(i._visibility|=2,cl(t,e,n,l,(e.subtreeFlags&10256)!==0||!1)),a&2048&&nc(u,e);break;case 24:ae(t,e,n,l),a&2048&&lc(e.alternate,e);break;default:ae(t,e,n,l)}}function cl(t,e,n,l,a){a=a&&((e.subtreeFlags&10256)!==0||!1);for(e=e.child;e!==null;){var i=t,u=e,o=n,r=l,s=u.flags;switch(u.tag){case 0:case 11:case 15:cl(i,u,o,r,a),ri(8,u);break;case 23:break;case 22:var h=u.stateNode;u.memoizedState!==null?h._visibility&2?cl(i,u,o,r,a):Ba(i,u):(h._visibility|=2,cl(i,u,o,r,a)),a&&s&2048&&nc(u.alternate,u);break;case 24:cl(i,u,o,r,a),a&&s&2048&&lc(u.alternate,u);break;default:cl(i,u,o,r,a)}e=e.sibling}}function Ba(t,e){if(e.subtreeFlags&10256)for(e=e.child;e!==null;){var n=t,l=e,a=l.flags;switch(l.tag){case 22:Ba(n,l),a&2048&&nc(l.alternate,l);break;case 24:Ba(n,l),a&2048&&lc(l.alternate,l);break;default:Ba(n,l)}e=e.sibling}}function sl(t,e,n){if(t.subtreeFlags&Na)for(t=t.child;t!==null;)tm(t,e,n),t=t.sibling}function tm(t,e,n){switch(t.tag){case 26:sl(t,e,n),t.flags&Na&&t.memoizedState!==null&&j_(n,ie,t.memoizedState,t.memoizedProps);break;case 5:sl(t,e,n);break;case 3:case 4:var l=ie;ie=Tu(t.stateNode.containerInfo),sl(t,e,n),ie=l;break;case 22:t.memoizedState===null&&(l=t.alternate,l!==null&&l.memoizedState!==null?(l=Na,Na=16777216,sl(t,e,n),Na=l):sl(t,e,n));break;default:sl(t,e,n)}}function em(t){var e=t.alternate;if(e!==null&&(t=e.child,t!==null)){e.child=null;do e=t.sibling,t.sibling=null,t=e;while(t!==null)}}function va(t){var e=t.deletions;if((t.flags&16)!==0){if(e!==null)for(var n=0;n<e.length;n++){var l=e[n];ft=l,lm(l,t)}em(t)}if(t.subtreeFlags&10256)for(t=t.child;t!==null;)nm(t),t=t.sibling}function nm(t){switch(t.tag){case 0:case 11:case 15:va(t),t.flags&2048&&bn(9,t,t.return);break;case 3:va(t);break;case 12:va(t);break;case 22:var e=t.stateNode;t.memoizedState!==null&&e._visibility&2&&(t.return===null||t.return.tag!==13)?(e._visibility&=-3,Pi(t)):va(t);break;default:va(t)}}function Pi(t){var e=t.deletions;if((t.flags&16)!==0){if(e!==null)for(var n=0;n<e.length;n++){var l=e[n];ft=l,lm(l,t)}em(t)}for(t=t.child;t!==null;){switch(e=t,e.tag){case 0:case 11:case 15:bn(8,e,e.return),Pi(e);break;case 22:n=e.stateNode,n._visibility&2&&(n._visibility&=-3,Pi(e));break;default:Pi(e)}t=t.sibling}}function lm(t,e){for(;ft!==null;){var n=ft;switch(n.tag){case 0:case 11:case 15:bn(8,n,e);break;case 23:case 22:if(n.memoizedState!==null&&n.memoizedState.cachePool!==null){var l=n.memoizedState.cachePool.pool;l!=null&&l.refCount++}break;case 24:ui(n.memoizedState.cache)}if(l=n.child,l!==null)l.return=n,ft=l;else t:for(n=t;ft!==null;){l=ft;var{sibling:a,return:i}=l;if(kp(l),l===n){ft=null;break t}if(a!==null){a.return=i,ft=a;break t}ft=i}}}function qt(){return(H&2)!==0&&B!==0?B&-B:T.T!==null?oc():ph()}function um(){if(Ct===0)if((B&536870912)===0||q){var t=wi;wi<<=1,(wi&3932160)===0&&(wi=262144),Ct=t}else Ct=536870912;return t=Ht.current,t!==null&&(t.flags|=32),Ct}function Dt(t,e,n){if(t===Z&&(Y===2||Y===9)||t.cancelPendingCommit!==null)Ll(t,0),un(t,B,Ct,!1);if(li(t,n),(H&2)===0||t!==Z)t===Z&&((H&2)===0&&(Hn|=n),nt===4&&un(t,B,Ct,!1)),ye(t)}function om(t,e,n){if((H&6)!==0)throw Error(_(327));var l=!n&&(e&127)===0&&(e&t.expiredLanes)===0||ni(t,e),a=l?i_(t,e):mr(t,e,!0),i=l;do{if(a===0){kl&&!l&&un(t,e,0,!1);break}else{if(n=t.current.alternate,i&&!l_(n)){a=mr(t,e,!1),i=!1;continue}if(a===2){if(i=e,t.errorRecoveryDisabledLanes&i)var u=0;else u=t.pendingLanes&-536870913,u=u!==0?u:u&536870912?536870912:0;if(u!==0){e=u;t:{var o=t;a=qa;var r=o.current.memoizedState.isDehydrated;if(r&&(Ll(o,u).flags|=256),u=mr(o,u,!1),u!==2){if(ac&&!r){o.errorRecoveryDisabledLanes|=i,Hn|=i,a=4;break t}i=At,At=a,i!==null&&(At===null?At=i:At.push.apply(At,i))}a=u}if(i=!1,a!==2)continue}}if(a===1){Ll(t,0),un(t,e,0,!0);break}t:{switch(l=t,i=a,i){case 0:case 1:throw Error(_(345));case 4:if((e&4194048)!==e)break;case 6:un(l,e,Ct,!an);break t;case 2:At=null;break;case 3:case 5:break;default:throw Error(_(329))}if((e&62914560)===e&&(a=Qu+300-Ut(),10<a)){if(un(l,e,Ct,!an),Uu(l,0,!0)!==0)break t;Ve=e,l.timeoutHandle=Dm(Dd.bind(null,l,n,At,Eu,ns,e,Ct,Hn,jl,an,i,"Throttled",-0,0),a);break t}Dd(l,n,At,Eu,ns,e,Ct,Hn,jl,an,i,null,-0,0)}}break}while(1);ye(t)}function Dd(t,e,n,l,a,i,u,o,r,s,h,g,d,v){if(t.timeoutHandle=-1,g=e.subtreeFlags,g&8192||(g&16785408)===16785408){g={stylesheets:null,count:0,imgCount:0,imgBytes:0,suspenseyImages:[],waitingForImages:!0,waitingForViewTransition:!1,unsuspend:Re},tm(e,i,g);var E=(i&62914560)===i?Qu-Ut():(i&4194048)===i?am-Ut():0;if(E=H_(g,E),E!==null){Ve=i,t.cancelPendingCommit=E(zd.bind(null,t,e,i,n,l,a,u,o,r,h,g,null,d,v)),un(t,i,u,!s);return}}zd(t,e,i,n,l,a,u,o,r)}function l_(t){for(var e=t;;){var n=e.tag;if((n===0||n===11||n===15)&&e.flags&16384&&(n=e.updateQueue,n!==null&&(n=n.stores,n!==null)))for(var l=0;l<n.length;l++){var a=n[l],i=a.getSnapshot;a=a.value;try{if(!jt(i(),a))return!1}catch(u){return!1}}if(n=e.child,e.subtreeFlags&16384&&n!==null)n.return=e,e=n;else{if(e===t)break;for(;e.sibling===null;){if(e.return===null||e.return===t)return!0;e=e.return}e.sibling.return=e.return,e=e.sibling}}return!0}function un(t,e,n,l){e&=~ic,e&=~Hn,t.suspendedLanes|=e,t.pingedLanes&=~e,l&&(t.warmLanes|=e),l=t.expirationTimes;for(var a=e;0<a;){var i=31-Bt(a),u=1<<i;l[i]=-1,a&=~u}n!==0&&fh(t,n,e)}function Zu(){return(H&6)===0?(si(0,!1),!1):!0}function uc(){if(V!==null){if(Y===0)var t=V.return;else t=V,Me=$n=null,Qs(t),zl=null,Za=0,t=V;for(;t!==null;)Lp(t.alternate,t),t=t.return;V=null}}function Ll(t,e){var n=t.timeoutHandle;n!==-1&&(t.timeoutHandle=-1,S_(n)),n=t.cancelPendingCommit,n!==null&&(t.cancelPendingCommit=null,n()),Ve=0,uc(),Z=t,V=n=Ce(t.current,null),B=e,Y=0,wt=null,an=!1,kl=ni(t,e),ac=!1,jl=Ct=ic=Hn=_n=nt=0,At=qa=null,ns=!1,(e&8)!==0&&(e|=e&32);var l=t.entangledLanes;if(l!==0)for(t=t.entanglements,l&=e;0<l;){var a=31-Bt(l),i=1<<a;e|=t[a],l&=~i}return Le=e,ju(),n}function rm(t,e){R=null,T.H=Ja,e===Zl||e===Lu?(e=id(),Y=3):e===js?(e=id(),Y=4):Y=e===tc?8:e!==null&&typeof e==="object"&&typeof e.then==="function"?6:1,wt=e,V===null&&(nt=1,yu(t,$t(e,t.current)))}function sm(){var t=Ht.current;return t===null?!0:(B&4194048)===B?Ft===null?!0:!1:(B&62914560)===B||(B&536870912)!==0?t===Ft:!1}function cm(){var t=T.H;return T.H=Ja,t===null?Ja:t}function fm(){var t=T.A;return T.A=e_,t}function Ou(){nt=4,an||(B&4194048)!==B&&Ht.current!==null||(kl=!0),(_n&134217727)===0&&(Hn&134217727)===0||Z===null||un(Z,B,Ct,!1)}function mr(t,e,n){var l=H;H|=2;var a=cm(),i=fm();if(Z!==t||B!==e)Eu=null,Ll(t,e);e=!1;var u=nt;t:do try{if(Y!==0&&V!==null){var o=V,r=wt;switch(Y){case 8:uc(),u=6;break t;case 3:case 2:case 9:case 6:Ht.current===null&&(e=!0);var s=Y;if(Y=0,wt=null,Nl(t,o,r,s),n&&kl){u=0;break t}break;default:s=Y,Y=0,wt=null,Nl(t,o,r,s)}}a_(),u=nt;break}catch(h){rm(t,h)}while(1);return e&&t.shellSuspendCounter++,Me=$n=null,H=l,T.H=a,T.A=i,V===null&&(Z=null,B=0,ju()),u}function a_(){for(;V!==null;)dm(V)}function i_(t,e){var n=H;H|=2;var l=cm(),a=fm();Z!==t||B!==e?(Eu=null,Su=Ut()+500,Ll(t,e)):kl=ni(t,e);t:do try{if(Y!==0&&V!==null){e=V;var i=wt;e:switch(Y){case 1:Y=0,wt=null,Nl(t,e,i,1);break;case 2:case 9:if(ad(i)){Y=0,wt=null,Td(e);break}e=function(){Y!==2&&Y!==9||Z!==t||(Y=7),ye(t)},i.then(e,e);break t;case 3:Y=7;break t;case 4:Y=5;break t;case 7:ad(i)?(Y=0,wt=null,Td(e)):(Y=0,wt=null,Nl(t,e,i,7));break;case 5:var u=null;switch(V.tag){case 26:u=V.memoizedState;case 5:case 27:var o=V;if(u?Mm(u):o.stateNode.complete){Y=0,wt=null;var r=o.sibling;if(r!==null)V=r;else{var s=o.return;s!==null?(V=s,ku(s)):V=null}break e}}Y=0,wt=null,Nl(t,e,i,5);break;case 6:Y=0,wt=null,Nl(t,e,i,6);break;case 8:uc(),nt=6;break t;default:throw Error(_(462))}}u_();break}catch(h){rm(t,h)}while(1);if(Me=$n=null,T.H=l,T.A=a,H=n,V!==null)return 0;return Z=null,B=0,ju(),nt}function u_(){for(;V!==null&&!zb();)dm(V)}function dm(t){var e=Hp(t.alternate,t,Le);t.memoizedProps=t.pendingProps,e===null?ku(t):V=e}function Td(t){var e=t,n=e.alternate;switch(e.tag){case 15:case 0:e=Sd(n,e,e.pendingProps,e.type,void 0,B);break;case 11:e=Sd(n,e,e.pendingProps,e.type.render,e.ref,B);break;case 5:Qs(e);default:Lp(n,e),e=V=Lh(e,Le),e=Hp(n,e,Le)}t.memoizedProps=t.pendingProps,e===null?ku(t):V=e}function Nl(t,e,n,l){Me=$n=null,Qs(e),zl=null,Za=0;var a=e.return;try{if(J0(t,a,e,n,B)){nt=1,yu(t,$t(n,t.current)),V=null;return}}catch(i){if(a!==null)throw V=a,i;nt=1,yu(t,$t(n,t.current)),V=null;return}if(e.flags&32768){if(q||l===1)t=!0;else if(kl||(B&536870912)!==0)t=!1;else if(an=t=!0,l===2||l===9||l===3||l===6)l=Ht.current,l!==null&&l.tag===13&&(l.flags|=16384);hm(e,t)}else ku(e)}function ku(t){var e=t;do{if((e.flags&32768)!==0){hm(e,an);return}t=e.return;var n=F0(e.alternate,e,Le);if(n!==null){V=n;return}if(e=e.sibling,e!==null){V=e;return}V=e=t}while(e!==null);nt===0&&(nt=5)}function hm(t,e){do{var n=I0(t.alternate,t);if(n!==null){n.flags&=32767,V=n;return}if(n=t.return,n!==null&&(n.flags|=32768,n.subtreeFlags=0,n.deletions=null),!e&&(t=t.sibling,t!==null)){V=t;return}V=t=n}while(t!==null);nt=6,V=null}function zd(t,e,n,l,a,i,u,o,r){t.cancelPendingCommit=null;do Ju();while(st!==0);if((H&6)!==0)throw Error(_(327));if(e!==null){if(e===t.current)throw Error(_(177));if(i=e.lanes|e.childLanes,i|=Rs,Hb(t,n,i,u,o,r),t===Z&&(V=Z=null,B=0),Hl=e,hn=t,Ve=n,ls=i,as=a,im=l,(e.subtreeFlags&10256)!==0||(e.flags&10256)!==0?(t.callbackNode=null,t.callbackPriority=0,c_(ou,function(){return ym(),null})):(t.callbackNode=null,t.callbackPriority=0),l=(e.flags&13878)!==0,(e.subtreeFlags&13878)!==0||l){l=T.T,T.T=null,a=L.p,L.p=2,u=H,H|=4;try{P0(t,e,n)}finally{H=u,L.p=a,T.T=l}}st=1,pm(),mm(),vm()}}function pm(){if(st===1){st=0;var t=hn,e=Hl,n=(e.flags&13878)!==0;if((e.subtreeFlags&13878)!==0||n){n=T.T,T.T=null;var l=L.p;L.p=2;var a=H;H|=4;try{Fp(e,t);var i=fs,u=Mh(t.containerInfo),o=i.focusedElem,r=i.selectionRange;if(u!==o&&o&&o.ownerDocument&&Rh(o.ownerDocument.documentElement,o)){if(r!==null&&ws(o)){var{start:s,end:h}=r;if(h===void 0&&(h=s),"selectionStart"in o)o.selectionStart=s,o.selectionEnd=Math.min(h,o.value.length);else{var g=o.ownerDocument||document,d=g&&g.defaultView||window;if(d.getSelection){var v=d.getSelection(),E=o.textContent.length,A=Math.min(r.start,E),z=r.end===void 0?A:Math.min(r.end,E);!v.extend&&A>z&&(u=z,z=A,A=u);var f=Ff(o,A),c=Ff(o,z);if(f&&c&&(v.rangeCount!==1||v.anchorNode!==f.node||v.anchorOffset!==f.offset||v.focusNode!==c.node||v.focusOffset!==c.offset)){var p=g.createRange();p.setStart(f.node,f.offset),v.removeAllRanges(),A>z?(v.addRange(p),v.extend(c.node,c.offset)):(p.setEnd(c.node,c.offset),v.addRange(p))}}}}g=[];for(v=o;v=v.parentNode;)v.nodeType===1&&g.push({element:v,left:v.scrollLeft,top:v.scrollTop});typeof o.focus==="function"&&o.focus();for(o=0;o<g.length;o++){var b=g[o];b.element.scrollLeft=b.left,b.element.scrollTop=b.top}}Ru=!!cs,fs=cs=null}finally{H=a,L.p=l,T.T=n}}t.current=e,st=2}}function mm(){if(st===2){st=0;var t=hn,e=Hl,n=(e.flags&8772)!==0;if((e.subtreeFlags&8772)!==0||n){n=T.T,T.T=null;var l=L.p;L.p=2;var a=H;H|=4;try{Zp(t,e.alternate,e)}finally{H=a,L.p=l,T.T=n}}st=3}}function vm(){if(st===4||st===3){st=0,wb();var t=hn,e=Hl,n=Ve,l=im;(e.subtreeFlags&10256)!==0||(e.flags&10256)!==0?st=5:(st=0,Hl=hn=null,gm(t,t.pendingLanes));var a=t.pendingLanes;if(a===0&&(dn=null),Os(n),e=e.stateNode,Vt&&typeof Vt.onCommitFiberRoot==="function")try{Vt.onCommitFiberRoot(ei,e,void 0,(e.current.flags&128)===128)}catch(r){}if(l!==null){e=T.T,a=L.p,L.p=2,T.T=null;try{for(var i=t.onRecoverableError,u=0;u<l.length;u++){var o=l[u];i(o.value,{componentStack:o.stack})}}finally{T.T=e,L.p=a}}(Ve&3)!==0&&Ju(),ye(t),a=t.pendingLanes,(n&261930)!==0&&(a&42)!==0?t===is?ja++:(ja=0,is=t):ja=0,si(0,!1)}}function gm(t,e){(t.pooledCacheLanes&=e)===0&&(e=t.pooledCache,e!=null&&(t.pooledCache=null,ui(e)))}function Ju(){return pm(),mm(),vm(),ym()}function ym(){if(st!==5)return!1;var t=hn,e=ls;ls=0;var n=Os(Ve),l=T.T,a=L.p;try{L.p=32>n?32:n,T.T=null,n=as,as=null;var i=hn,u=Ve;if(st=0,Hl=hn=null,Ve=0,(H&6)!==0)throw Error(_(331));var o=H;if(H|=4,nm(i.current),Pp(i,i.current,u,n),H=o,si(0,!1),Vt&&typeof Vt.onPostCommitFiberRoot==="function")try{Vt.onPostCommitFiberRoot(ei,i)}catch(r){}return!0}finally{L.p=a,T.T=l,gm(t,e)}}function wd(t,e,n){e=$t(n,e),e=Ir(t.stateNode,e,2),t=fn(t,e,2),t!==null&&(li(t,2),ye(t))}function K(t,e,n){if(t.tag===3)wd(t,t,n);else for(;e!==null;){if(e.tag===3){wd(e,t,n);break}else if(e.tag===1){var l=e.stateNode;if(typeof e.type.getDerivedStateFromError==="function"||typeof l.componentDidCatch==="function"&&(dn===null||!dn.has(l))){t=$t(n,t),n=Cp(2),l=fn(e,n,2),l!==null&&(Up(n,l,e,t),li(l,2),ye(l));break}}e=e.return}}function vr(t,e,n){var l=t.pingCache;if(l===null){l=t.pingCache=new n_;var a=new Set;l.set(e,a)}else a=l.get(e),a===void 0&&(a=new Set,l.set(e,a));a.has(n)||(ac=!0,a.add(n),t=o_.bind(null,t,e,n),e.then(t,t))}function o_(t,e,n){var l=t.pingCache;l!==null&&l.delete(e),t.pingedLanes|=t.suspendedLanes&n,t.warmLanes&=~n,Z===t&&(B&n)===n&&(nt===4||nt===3&&(B&62914560)===B&&300>Ut()-Qu?(H&2)===0&&Ll(t,0):ic|=n,jl===B&&(jl=0)),ye(t)}function bm(t,e){e===0&&(e=ch()),t=Jn(t,e),t!==null&&(li(t,e),ye(t))}function r_(t){var e=t.memoizedState,n=0;e!==null&&(n=e.retryLane),bm(t,n)}function s_(t,e){var n=0;switch(t.tag){case 31:case 13:var{stateNode:l,memoizedState:a}=t;a!==null&&(n=a.retryLane);break;case 19:l=t.stateNode;break;case 22:l=t.stateNode._retryCache;break;default:throw Error(_(314))}l!==null&&l.delete(e),bm(t,n)}function c_(t,e){return Ss(t,e)}function ye(t){t!==fl&&t.next===null&&(fl===null?Nu=fl=t:fl=fl.next=t),xu=!0,us||(us=!0,d_())}function si(t,e){if(!gr&&xu){gr=!0;do{var n=!1;for(var l=Nu;l!==null;){if(!e)if(t!==0){var a=l.pendingLanes;if(a===0)var i=0;else{var{suspendedLanes:u,pingedLanes:o}=l;i=(1<<31-Bt(42|t)+1)-1,i&=a&~(u&~o),i=i&201326741?i&201326741|1:i?i|2:0}i!==0&&(n=!0,Rd(l,i))}else i=B,i=Uu(l,l===Z?i:0,l.cancelPendingCommit!==null||l.timeoutHandle!==-1),(i&3)===0||ni(l,i)||(n=!0,Rd(l,i));l=l.next}}while(n);gr=!1}}function f_(){_m()}function _m(){xu=us=!1;var t=0;on!==0&&__()&&(t=on);for(var e=Ut(),n=null,l=Nu;l!==null;){var a=l.next,i=Sm(l,e);if(i===0)l.next=null,n===null?Nu=a:n.next=a,a===null&&(fl=n);else if(n=l,t!==0||(i&3)!==0)xu=!0;l=a}st!==0&&st!==5||si(t,!1),on!==0&&(on=0)}function Sm(t,e){for(var{suspendedLanes:n,pingedLanes:l,expirationTimes:a}=t,i=t.pendingLanes&-62914561;0<i;){var u=31-Bt(i),o=1<<u,r=a[u];if(r===-1){if((o&n)===0||(o&l)!==0)a[u]=jb(o,e)}else r<=e&&(t.expiredLanes|=o);i&=~o}if(e=Z,n=B,n=Uu(t,t===e?n:0,t.cancelPendingCommit!==null||t.timeoutHandle!==-1),l=t.callbackNode,n===0||t===e&&(Y===2||Y===9)||t.cancelPendingCommit!==null)return l!==null&&l!==null&&ko(l),t.callbackNode=null,t.callbackPriority=0;if((n&3)===0||ni(t,n)){if(e=n&-n,e===t.callbackPriority)return e;switch(l!==null&&ko(l),Os(n)){case 2:case 8:n=rh;break;case 32:n=ou;break;case 268435456:n=sh;break;default:n=ou}return l=Em.bind(null,t),n=Ss(n,l),t.callbackPriority=e,t.callbackNode=n,e}return l!==null&&l!==null&&ko(l),t.callbackPriority=2,t.callbackNode=null,2}function Em(t,e){if(st!==0&&st!==5)return t.callbackNode=null,t.callbackPriority=0,null;var n=t.callbackNode;if(Ju()&&t.callbackNode!==n)return null;var l=B;if(l=Uu(t,t===Z?l:0,t.cancelPendingCommit!==null||t.timeoutHandle!==-1),l===0)return null;return om(t,l,e),Sm(t,Ut()),t.callbackNode!=null&&t.callbackNode===n?Em.bind(null,t):null}function Rd(t,e){if(Ju())return null;om(t,e,!0)}function d_(){E_(function(){(H&6)!==0?Ss(oh,f_):_m()})}function oc(){if(on===0){var t=Vl;t===0&&(t=zi,zi<<=1,(zi&261888)===0&&(zi=256)),on=t}return on}function Md(t){return t==null||typeof t==="symbol"||typeof t==="boolean"?null:typeof t==="function"?t:Ki(""+t)}function Cd(t,e){var n=e.ownerDocument.createElement("input");return n.name=e.name,n.value=e.value,t.id&&n.setAttribute("form",t.id),e.parentNode.insertBefore(n,e),t=new FormData(t),n.parentNode.removeChild(n),t}function h_(t,e,n,l,a){if(e==="submit"&&n&&n.stateNode===a){var i=Md((a[Tt]||null).action),u=l.submitter;u&&(e=(e=u[Tt]||null)?Md(e.formAction):u.getAttribute("formAction"),e!==null&&(i=e,u=null));var o=new Vu("action","action",null,l,a);t.push({event:o,listeners:[{instance:null,listener:function(){if(l.defaultPrevented){if(on!==0){var r=u?Cd(a,u):new FormData(a);Wr(n,{pending:!0,data:r,method:a.method,action:i},null,r)}}else typeof i==="function"&&(o.preventDefault(),r=u?Cd(a,u):new FormData(a),Wr(n,{pending:!0,data:r,method:a.method,action:i},i,r))},currentTarget:a}]})}}function Om(t,e){e=(e&4)!==0;for(var n=0;n<t.length;n++){var l=t[n],a=l.event;l=l.listeners;t:{var i=void 0;if(e)for(var u=l.length-1;0<=u;u--){var o=l[u],r=o.instance,s=o.currentTarget;if(o=o.listener,r!==i&&a.isPropagationStopped())break t;i=o,a.currentTarget=s;try{i(a)}catch(h){su(h)}a.currentTarget=null,i=r}else for(u=0;u<l.length;u++){if(o=l[u],r=o.instance,s=o.currentTarget,o=o.listener,r!==i&&a.isPropagationStopped())break t;i=o,a.currentTarget=s;try{i(a)}catch(h){su(h)}a.currentTarget=null,i=r}}}}function U(t,e){var n=e[wr];n===void 0&&(n=e[wr]=new Set);var l=t+"__bubble";n.has(l)||(Nm(e,t,2,!1),n.add(l))}function yr(t,e,n){var l=0;e&&(l|=4),Nm(n,t,l,e)}function rc(t){if(!t[Hi]){t[Hi]=!0,mh.forEach(function(n){n!=="selectionchange"&&(p_.has(n)||yr(n,!1,t),yr(n,!0,t))});var e=t.nodeType===9?t:t.ownerDocument;e===null||e[Hi]||(e[Hi]=!0,yr("selectionchange",!1,e))}}function Nm(t,e,n,l){switch(qm(e)){case 2:var a=Y_;break;case 8:a=K_;break;default:a=dc}n=a.bind(null,e,n,t),a=void 0,!Vr||e!=="touchstart"&&e!=="touchmove"&&e!=="wheel"||(a=!0),l?a!==void 0?t.addEventListener(e,n,{capture:!0,passive:a}):t.addEventListener(e,n,!0):a!==void 0?t.addEventListener(e,n,{passive:a}):t.addEventListener(e,n,!1)}function br(t,e,n,l,a){var i=l;if((e&1)===0&&(e&2)===0&&l!==null)t:for(;;){if(l===null)return;var u=l.tag;if(u===3||u===4){var o=l.stateNode.containerInfo;if(o===a)break;if(u===4)for(u=l.return;u!==null;){var r=u.tag;if((r===3||r===4)&&u.stateNode.containerInfo===a)return;u=u.return}for(;o!==null;){if(u=ml(o),u===null)return;if(r=u.tag,r===5||r===6||r===26||r===27){l=i=u;continue t}o=o.parentNode}}l=l.return}Oh(function(){var s=i,h=As(n),g=[];t:{var d=jh.get(t);if(d!==void 0){var v=Vu,E=t;switch(t){case"keypress":if(Qi(n)===0)break t;case"keydown":case"keyup":v=s0;break;case"focusin":E="focus",v=Io;break;case"focusout":E="blur",v=Io;break;case"beforeblur":case"afterblur":v=Io;break;case"click":if(n.button===2)break t;case"auxclick":case"dblclick":case"mousedown":case"mousemove":case"mouseup":case"mouseout":case"mouseover":case"contextmenu":v=Yf;break;case"drag":case"dragend":case"dragenter":case"dragexit":case"dragleave":case"dragover":case"dragstart":case"drop":v=Fb;break;case"touchcancel":case"touchend":case"touchmove":case"touchstart":v=d0;break;case Uh:case Vh:case Bh:v=t0;break;case qh:v=p0;break;case"scroll":case"scrollend":v=$b;break;case"wheel":v=v0;break;case"copy":case"cut":case"paste":v=n0;break;case"gotpointercapture":case"lostpointercapture":case"pointercancel":case"pointerdown":case"pointermove":case"pointerout":case"pointerover":case"pointerup":v=Xf;break;case"toggle":case"beforetoggle":v=y0}var A=(e&4)!==0,z=!A&&(t==="scroll"||t==="scrollend"),f=A?d!==null?d+"Capture":null:d;A=[];for(var c=s,p;c!==null;){var b=c;if(p=b.stateNode,b=b.tag,b!==5&&b!==26&&b!==27||p===null||f===null||(b=Ga(c,f),b!=null&&A.push(Wa(c,b,p))),z)break;c=c.return}0<A.length&&(d=new v(d,E,null,n,h),g.push({event:d,listeners:A}))}}if((e&7)===0){t:{if(d=t==="mouseover"||t==="pointerover",v=t==="mouseout"||t==="pointerout",d&&n!==Ur&&(E=n.relatedTarget||n.fromElement)&&(ml(E)||E[Kl]))break t;if(v||d){if(d=h.window===h?h:(d=h.ownerDocument)?d.defaultView||d.parentWindow:window,v){if(E=n.relatedTarget||n.toElement,v=s,E=E?ml(E):null,E!==null&&(z=ti(E),A=E.tag,E!==z||A!==5&&A!==27&&A!==6))E=null}else v=null,E=s;if(v!==E){if(A=Yf,b="onMouseLeave",f="onMouseEnter",c="mouse",t==="pointerout"||t==="pointerover")A=Xf,b="onPointerLeave",f="onPointerEnter",c="pointer";if(z=v==null?d:_a(v),p=E==null?d:_a(E),d=new A(b,c+"leave",v,n,h),d.target=z,d.relatedTarget=p,b=null,ml(h)===s&&(A=new A(f,c+"enter",E,n,h),A.target=p,A.relatedTarget=z,b=A),z=b,v&&E)e:{A=m_,f=v,c=E,p=0;for(b=f;b;b=A(b))p++;b=0;for(var O=c;O;O=A(O))b++;for(;0<p-b;)f=A(f),p--;for(;0<b-p;)c=A(c),b--;for(;p--;){if(f===c||c!==null&&f===c.alternate){A=f;break e}f=A(f),c=A(c)}A=null}else A=null;v!==null&&Ud(g,d,v,A,!1),E!==null&&z!==null&&Ud(g,z,E,A,!0)}}}t:{if(d=s?_a(s):window,v=d.nodeName&&d.nodeName.toLowerCase(),v==="select"||v==="input"&&d.type==="file")var C=Jf;else if(kf(d))if(zh)C=T0;else{C=A0;var N=x0}else v=d.nodeName,!v||v.toLowerCase()!=="input"||d.type!=="checkbox"&&d.type!=="radio"?s&&xs(s.elementType)&&(C=Jf):C=D0;if(C&&(C=C(t,s))){Th(g,C,n,h);break t}N&&N(t,d,s),t==="focusout"&&s&&d.type==="number"&&s.memoizedProps.value!=null&&Cr(d,"number",d.value)}switch(N=s?_a(s):window,t){case"focusin":if(kf(N)||N.contentEditable==="true")yl=N,Br=s,za=null;break;case"focusout":za=Br=yl=null;break;case"mousedown":qr=!0;break;case"contextmenu":case"mouseup":case"dragend":qr=!1,If(g,n,h);break;case"selectionchange":if(w0)break;case"keydown":case"keyup":If(g,n,h)}var w;if(zs)t:{switch(t){case"compositionstart":var y="onCompositionStart";break t;case"compositionend":y="onCompositionEnd";break t;case"compositionupdate":y="onCompositionUpdate";break t}y=void 0}else gl?Ah(t,n)&&(y="onCompositionEnd"):t==="keydown"&&n.keyCode===229&&(y="onCompositionStart");if(y&&(xh&&n.locale!=="ko"&&(gl||y!=="onCompositionStart"?y==="onCompositionEnd"&&gl&&(w=Nh()):(ln=h,Ds=("value"in ln)?ln.value:ln.textContent,gl=!0)),N=Au(s,y),0<N.length&&(y=new Kf(y,t,null,n,h),g.push({event:y,listeners:N}),w?y.data=w:(w=Dh(n),w!==null&&(y.data=w)))),w=_0?S0(t,n):E0(t,n))y=Au(s,"onBeforeInput"),0<y.length&&(N=new Kf("onBeforeInput","beforeinput",null,n,h),g.push({event:N,listeners:y}),N.data=w);h_(g,t,s,n,h)}Om(g,e)})}function Wa(t,e,n){return{instance:t,listener:e,currentTarget:n}}function Au(t,e){for(var n=e+"Capture",l=[];t!==null;){var a=t,i=a.stateNode;if(a=a.tag,a!==5&&a!==26&&a!==27||i===null||(a=Ga(t,n),a!=null&&l.unshift(Wa(t,a,i)),a=Ga(t,e),a!=null&&l.push(Wa(t,a,i))),t.tag===3)return l;t=t.return}return[]}function m_(t){if(t===null)return null;do t=t.return;while(t&&t.tag!==5&&t.tag!==27);return t?t:null}function Ud(t,e,n,l,a){for(var i=e._reactName,u=[];n!==null&&n!==l;){var o=n,r=o.alternate,s=o.stateNode;if(o=o.tag,r!==null&&r===l)break;o!==5&&o!==26&&o!==27||s===null||(r=s,a?(s=Ga(n,i),s!=null&&u.unshift(Wa(n,s,r))):a||(s=Ga(n,i),s!=null&&u.push(Wa(n,s,r)))),n=n.return}u.length!==0&&t.push({event:e,listeners:u})}function Vd(t){return(typeof t==="string"?t:""+t).replace(v_,`
9
- `).replace(g_,"")}function xm(t,e){return e=Vd(e),Vd(t)===e?!0:!1}function X(t,e,n,l,a,i){switch(n){case"children":typeof l==="string"?e==="body"||e==="textarea"&&l===""||Ul(t,l):(typeof l==="number"||typeof l==="bigint")&&e!=="body"&&Ul(t,""+l);break;case"className":Mi(t,"class",l);break;case"tabIndex":Mi(t,"tabindex",l);break;case"dir":case"role":case"viewBox":case"width":case"height":Mi(t,n,l);break;case"style":Eh(t,l,i);break;case"data":if(e!=="object"){Mi(t,"data",l);break}case"src":case"href":if(l===""&&(e!=="a"||n!=="href")){t.removeAttribute(n);break}if(l==null||typeof l==="function"||typeof l==="symbol"||typeof l==="boolean"){t.removeAttribute(n);break}l=Ki(""+l),t.setAttribute(n,l);break;case"action":case"formAction":if(typeof l==="function"){t.setAttribute(n,"javascript:throw new Error('A React form was unexpectedly submitted. If you called form.submit() manually, consider using form.requestSubmit() instead. If you\\'re trying to use event.stopPropagation() in a submit event handler, consider also calling event.preventDefault().')");break}else typeof i==="function"&&(n==="formAction"?(e!=="input"&&X(t,e,"name",a.name,a,null),X(t,e,"formEncType",a.formEncType,a,null),X(t,e,"formMethod",a.formMethod,a,null),X(t,e,"formTarget",a.formTarget,a,null)):(X(t,e,"encType",a.encType,a,null),X(t,e,"method",a.method,a,null),X(t,e,"target",a.target,a,null)));if(l==null||typeof l==="symbol"||typeof l==="boolean"){t.removeAttribute(n);break}l=Ki(""+l),t.setAttribute(n,l);break;case"onClick":l!=null&&(t.onclick=Re);break;case"onScroll":l!=null&&U("scroll",t);break;case"onScrollEnd":l!=null&&U("scrollend",t);break;case"dangerouslySetInnerHTML":if(l!=null){if(typeof l!=="object"||!("__html"in l))throw Error(_(61));if(n=l.__html,n!=null){if(a.children!=null)throw Error(_(60));t.innerHTML=n}}break;case"multiple":t.multiple=l&&typeof l!=="function"&&typeof l!=="symbol";break;case"muted":t.muted=l&&typeof l!=="function"&&typeof l!=="symbol";break;case"suppressContentEditableWarning":case"suppressHydrationWarning":case"defaultValue":case"defaultChecked":case"innerHTML":case"ref":break;case"autoFocus":break;case"xlinkHref":if(l==null||typeof l==="function"||typeof l==="boolean"||typeof l==="symbol"){t.removeAttribute("xlink:href");break}n=Ki(""+l),t.setAttributeNS("http://www.w3.org/1999/xlink","xlink:href",n);break;case"contentEditable":case"spellCheck":case"draggable":case"value":case"autoReverse":case"externalResourcesRequired":case"focusable":case"preserveAlpha":l!=null&&typeof l!=="function"&&typeof l!=="symbol"?t.setAttribute(n,""+l):t.removeAttribute(n);break;case"inert":case"allowFullScreen":case"async":case"autoPlay":case"controls":case"default":case"defer":case"disabled":case"disablePictureInPicture":case"disableRemotePlayback":case"formNoValidate":case"hidden":case"loop":case"noModule":case"noValidate":case"open":case"playsInline":case"readOnly":case"required":case"reversed":case"scoped":case"seamless":case"itemScope":l&&typeof l!=="function"&&typeof l!=="symbol"?t.setAttribute(n,""):t.removeAttribute(n);break;case"capture":case"download":l===!0?t.setAttribute(n,""):l!==!1&&l!=null&&typeof l!=="function"&&typeof l!=="symbol"?t.setAttribute(n,l):t.removeAttribute(n);break;case"cols":case"rows":case"size":case"span":l!=null&&typeof l!=="function"&&typeof l!=="symbol"&&!isNaN(l)&&1<=l?t.setAttribute(n,l):t.removeAttribute(n);break;case"rowSpan":case"start":l==null||typeof l==="function"||typeof l==="symbol"||isNaN(l)?t.removeAttribute(n):t.setAttribute(n,l);break;case"popover":U("beforetoggle",t),U("toggle",t),Yi(t,"popover",l);break;case"xlinkActuate":Oe(t,"http://www.w3.org/1999/xlink","xlink:actuate",l);break;case"xlinkArcrole":Oe(t,"http://www.w3.org/1999/xlink","xlink:arcrole",l);break;case"xlinkRole":Oe(t,"http://www.w3.org/1999/xlink","xlink:role",l);break;case"xlinkShow":Oe(t,"http://www.w3.org/1999/xlink","xlink:show",l);break;case"xlinkTitle":Oe(t,"http://www.w3.org/1999/xlink","xlink:title",l);break;case"xlinkType":Oe(t,"http://www.w3.org/1999/xlink","xlink:type",l);break;case"xmlBase":Oe(t,"http://www.w3.org/XML/1998/namespace","xml:base",l);break;case"xmlLang":Oe(t,"http://www.w3.org/XML/1998/namespace","xml:lang",l);break;case"xmlSpace":Oe(t,"http://www.w3.org/XML/1998/namespace","xml:space",l);break;case"is":Yi(t,"is",l);break;case"innerText":case"textContent":break;default:if(!(2<n.length)||n[0]!=="o"&&n[0]!=="O"||n[1]!=="n"&&n[1]!=="N")n=kb.get(n)||n,Yi(t,n,l)}}function ss(t,e,n,l,a,i){switch(n){case"style":Eh(t,l,i);break;case"dangerouslySetInnerHTML":if(l!=null){if(typeof l!=="object"||!("__html"in l))throw Error(_(61));if(n=l.__html,n!=null){if(a.children!=null)throw Error(_(60));t.innerHTML=n}}break;case"children":typeof l==="string"?Ul(t,l):(typeof l==="number"||typeof l==="bigint")&&Ul(t,""+l);break;case"onScroll":l!=null&&U("scroll",t);break;case"onScrollEnd":l!=null&&U("scrollend",t);break;case"onClick":l!=null&&(t.onclick=Re);break;case"suppressContentEditableWarning":case"suppressHydrationWarning":case"innerHTML":case"ref":break;case"innerText":case"textContent":break;default:if(!vh.hasOwnProperty(n))t:{if(n[0]==="o"&&n[1]==="n"&&(a=n.endsWith("Capture"),e=n.slice(2,a?n.length-7:void 0),i=t[Tt]||null,i=i!=null?i[n]:null,typeof i==="function"&&t.removeEventListener(e,i,a),typeof l==="function")){typeof i!=="function"&&i!==null&&(n in t?t[n]=null:t.hasAttribute(n)&&t.removeAttribute(n)),t.addEventListener(e,l,a);break t}n in t?t[n]=l:l===!0?t.setAttribute(n,""):Yi(t,n,l)}}}function yt(t,e,n){switch(e){case"div":case"span":case"svg":case"path":case"a":case"g":case"p":case"li":break;case"img":U("error",t),U("load",t);var l=!1,a=!1,i;for(i in n)if(n.hasOwnProperty(i)){var u=n[i];if(u!=null)switch(i){case"src":l=!0;break;case"srcSet":a=!0;break;case"children":case"dangerouslySetInnerHTML":throw Error(_(137,e));default:X(t,e,i,u,n,null)}}a&&X(t,e,"srcSet",n.srcSet,n,null),l&&X(t,e,"src",n.src,n,null);return;case"input":U("invalid",t);var o=i=u=a=null,r=null,s=null;for(l in n)if(n.hasOwnProperty(l)){var h=n[l];if(h!=null)switch(l){case"name":a=h;break;case"type":u=h;break;case"checked":r=h;break;case"defaultChecked":s=h;break;case"value":i=h;break;case"defaultValue":o=h;break;case"children":case"dangerouslySetInnerHTML":if(h!=null)throw Error(_(137,e));break;default:X(t,e,l,h,n,null)}}bh(t,i,o,r,s,u,a,!1);return;case"select":U("invalid",t),l=u=i=null;for(a in n)if(n.hasOwnProperty(a)&&(o=n[a],o!=null))switch(a){case"value":i=o;break;case"defaultValue":u=o;break;case"multiple":l=o;default:X(t,e,a,o,n,null)}e=i,n=u,t.multiple=!!l,e!=null?Al(t,!!l,e,!1):n!=null&&Al(t,!!l,n,!0);return;case"textarea":U("invalid",t),i=a=l=null;for(u in n)if(n.hasOwnProperty(u)&&(o=n[u],o!=null))switch(u){case"value":l=o;break;case"defaultValue":a=o;break;case"children":i=o;break;case"dangerouslySetInnerHTML":if(o!=null)throw Error(_(91));break;default:X(t,e,u,o,n,null)}Sh(t,l,a,i);return;case"option":for(r in n)if(n.hasOwnProperty(r)&&(l=n[r],l!=null))switch(r){case"selected":t.selected=l&&typeof l!=="function"&&typeof l!=="symbol";break;default:X(t,e,r,l,n,null)}return;case"dialog":U("beforetoggle",t),U("toggle",t),U("cancel",t),U("close",t);break;case"iframe":case"object":U("load",t);break;case"video":case"audio":for(l=0;l<$a.length;l++)U($a[l],t);break;case"image":U("error",t),U("load",t);break;case"details":U("toggle",t);break;case"embed":case"source":case"link":U("error",t),U("load",t);case"area":case"base":case"br":case"col":case"hr":case"keygen":case"meta":case"param":case"track":case"wbr":case"menuitem":for(s in n)if(n.hasOwnProperty(s)&&(l=n[s],l!=null))switch(s){case"children":case"dangerouslySetInnerHTML":throw Error(_(137,e));default:X(t,e,s,l,n,null)}return;default:if(xs(e)){for(h in n)n.hasOwnProperty(h)&&(l=n[h],l!==void 0&&ss(t,e,h,l,n,void 0));return}}for(o in n)n.hasOwnProperty(o)&&(l=n[o],l!=null&&X(t,e,o,l,n,null))}function y_(t,e,n,l){switch(e){case"div":case"span":case"svg":case"path":case"a":case"g":case"p":case"li":break;case"input":var a=null,i=null,u=null,o=null,r=null,s=null,h=null;for(v in n){var g=n[v];if(n.hasOwnProperty(v)&&g!=null)switch(v){case"checked":break;case"value":break;case"defaultValue":r=g;default:l.hasOwnProperty(v)||X(t,e,v,null,l,g)}}for(var d in l){var v=l[d];if(g=n[d],l.hasOwnProperty(d)&&(v!=null||g!=null))switch(d){case"type":i=v;break;case"name":a=v;break;case"checked":s=v;break;case"defaultChecked":h=v;break;case"value":u=v;break;case"defaultValue":o=v;break;case"children":case"dangerouslySetInnerHTML":if(v!=null)throw Error(_(137,e));break;default:v!==g&&X(t,e,d,v,l,g)}}Mr(t,u,o,r,s,h,i,a);return;case"select":v=u=o=d=null;for(i in n)if(r=n[i],n.hasOwnProperty(i)&&r!=null)switch(i){case"value":break;case"multiple":v=r;default:l.hasOwnProperty(i)||X(t,e,i,null,l,r)}for(a in l)if(i=l[a],r=n[a],l.hasOwnProperty(a)&&(i!=null||r!=null))switch(a){case"value":d=i;break;case"defaultValue":o=i;break;case"multiple":u=i;default:i!==r&&X(t,e,a,i,l,r)}e=o,n=u,l=v,d!=null?Al(t,!!n,d,!1):!!l!==!!n&&(e!=null?Al(t,!!n,e,!0):Al(t,!!n,n?[]:"",!1));return;case"textarea":v=d=null;for(o in n)if(a=n[o],n.hasOwnProperty(o)&&a!=null&&!l.hasOwnProperty(o))switch(o){case"value":break;case"children":break;default:X(t,e,o,null,l,a)}for(u in l)if(a=l[u],i=n[u],l.hasOwnProperty(u)&&(a!=null||i!=null))switch(u){case"value":d=a;break;case"defaultValue":v=a;break;case"children":break;case"dangerouslySetInnerHTML":if(a!=null)throw Error(_(91));break;default:a!==i&&X(t,e,u,a,l,i)}_h(t,d,v);return;case"option":for(var E in n)if(d=n[E],n.hasOwnProperty(E)&&d!=null&&!l.hasOwnProperty(E))switch(E){case"selected":t.selected=!1;break;default:X(t,e,E,null,l,d)}for(r in l)if(d=l[r],v=n[r],l.hasOwnProperty(r)&&d!==v&&(d!=null||v!=null))switch(r){case"selected":t.selected=d&&typeof d!=="function"&&typeof d!=="symbol";break;default:X(t,e,r,d,l,v)}return;case"img":case"link":case"area":case"base":case"br":case"col":case"embed":case"hr":case"keygen":case"meta":case"param":case"source":case"track":case"wbr":case"menuitem":for(var A in n)d=n[A],n.hasOwnProperty(A)&&d!=null&&!l.hasOwnProperty(A)&&X(t,e,A,null,l,d);for(s in l)if(d=l[s],v=n[s],l.hasOwnProperty(s)&&d!==v&&(d!=null||v!=null))switch(s){case"children":case"dangerouslySetInnerHTML":if(d!=null)throw Error(_(137,e));break;default:X(t,e,s,d,l,v)}return;default:if(xs(e)){for(var z in n)d=n[z],n.hasOwnProperty(z)&&d!==void 0&&!l.hasOwnProperty(z)&&ss(t,e,z,void 0,l,d);for(h in l)d=l[h],v=n[h],!l.hasOwnProperty(h)||d===v||d===void 0&&v===void 0||ss(t,e,h,d,l,v);return}}for(var f in n)d=n[f],n.hasOwnProperty(f)&&d!=null&&!l.hasOwnProperty(f)&&X(t,e,f,null,l,d);for(g in l)d=l[g],v=n[g],!l.hasOwnProperty(g)||d===v||d==null&&v==null||X(t,e,g,d,l,v)}function Bd(t){switch(t){case"css":case"script":case"font":case"img":case"image":case"input":case"link":return!0;default:return!1}}function b_(){if(typeof performance.getEntriesByType==="function"){for(var t=0,e=0,n=performance.getEntriesByType("resource"),l=0;l<n.length;l++){var a=n[l],i=a.transferSize,u=a.initiatorType,o=a.duration;if(i&&o&&Bd(u)){u=0,o=a.responseEnd;for(l+=1;l<n.length;l++){var r=n[l],s=r.startTime;if(s>o)break;var{transferSize:h,initiatorType:g}=r;h&&Bd(g)&&(r=r.responseEnd,u+=h*(r<o?1:(o-s)/(r-s)))}if(--l,e+=8*(i+u)/(a.duration/1000),t++,10<t)break}}if(0<t)return e/t/1e6}return navigator.connection&&(t=navigator.connection.downlink,typeof t==="number")?t:5}function Du(t){return t.nodeType===9?t:t.ownerDocument}function qd(t){switch(t){case"http://www.w3.org/2000/svg":return 1;case"http://www.w3.org/1998/Math/MathML":return 2;default:return 0}}function Am(t,e){if(t===0)switch(e){case"svg":return 1;case"math":return 2;default:return 0}return t===1&&e==="foreignObject"?0:t}function ds(t,e){return t==="textarea"||t==="noscript"||typeof e.children==="string"||typeof e.children==="number"||typeof e.children==="bigint"||typeof e.dangerouslySetInnerHTML==="object"&&e.dangerouslySetInnerHTML!==null&&e.dangerouslySetInnerHTML.__html!=null}function __(){var t=window.event;if(t&&t.type==="popstate"){if(t===_r)return!1;return _r=t,!0}return _r=null,!1}function O_(t){setTimeout(function(){throw t})}function En(t){return t==="head"}function Hd(t,e){var n=e,l=0;do{var a=n.nextSibling;if(t.removeChild(n),a&&a.nodeType===8)if(n=a.data,n==="/$"||n==="/&"){if(l===0){t.removeChild(a),Yl(e);return}l--}else if(n==="$"||n==="$?"||n==="$~"||n==="$!"||n==="&")l++;else if(n==="html")Ha(t.ownerDocument.documentElement);else if(n==="head"){n=t.ownerDocument.head,Ha(n);for(var i=n.firstChild;i;){var{nextSibling:u,nodeName:o}=i;i[ai]||o==="SCRIPT"||o==="STYLE"||o==="LINK"&&i.rel.toLowerCase()==="stylesheet"||n.removeChild(i),i=u}}else n==="body"&&Ha(t.ownerDocument.body);n=a}while(n);Yl(e)}function Ld(t,e){var n=t;t=0;do{var l=n.nextSibling;if(n.nodeType===1?e?(n._stashedDisplay=n.style.display,n.style.display="none"):(n.style.display=n._stashedDisplay||"",n.getAttribute("style")===""&&n.removeAttribute("style")):n.nodeType===3&&(e?(n._stashedText=n.nodeValue,n.nodeValue=""):n.nodeValue=n._stashedText||""),l&&l.nodeType===8)if(n=l.data,n==="/$")if(t===0)break;else t--;else n!=="$"&&n!=="$?"&&n!=="$~"&&n!=="$!"||t++;n=l}while(n)}function hs(t){var e=t.firstChild;e&&e.nodeType===10&&(e=e.nextSibling);for(;e;){var n=e;switch(e=e.nextSibling,n.nodeName){case"HTML":case"HEAD":case"BODY":hs(n),Ns(n);continue;case"SCRIPT":case"STYLE":continue;case"LINK":if(n.rel.toLowerCase()==="stylesheet")continue}t.removeChild(n)}}function N_(t,e,n,l){for(;t.nodeType===1;){var a=n;if(t.nodeName.toLowerCase()!==e.toLowerCase()){if(!l&&(t.nodeName!=="INPUT"||t.type!=="hidden"))break}else if(!l)if(e==="input"&&t.type==="hidden"){var i=a.name==null?null:""+a.name;if(a.type==="hidden"&&t.getAttribute("name")===i)return t}else return t;else if(!t[ai])switch(e){case"meta":if(!t.hasAttribute("itemprop"))break;return t;case"link":if(i=t.getAttribute("rel"),i==="stylesheet"&&t.hasAttribute("data-precedence"))break;else if(i!==a.rel||t.getAttribute("href")!==(a.href==null||a.href===""?null:a.href)||t.getAttribute("crossorigin")!==(a.crossOrigin==null?null:a.crossOrigin)||t.getAttribute("title")!==(a.title==null?null:a.title))break;return t;case"style":if(t.hasAttribute("data-precedence"))break;return t;case"script":if(i=t.getAttribute("src"),(i!==(a.src==null?null:a.src)||t.getAttribute("type")!==(a.type==null?null:a.type)||t.getAttribute("crossorigin")!==(a.crossOrigin==null?null:a.crossOrigin))&&i&&t.hasAttribute("async")&&!t.hasAttribute("itemprop"))break;return t;default:return t}if(t=It(t.nextSibling),t===null)break}return null}function x_(t,e,n){if(e==="")return null;for(;t.nodeType!==3;){if((t.nodeType!==1||t.nodeName!=="INPUT"||t.type!=="hidden")&&!n)return null;if(t=It(t.nextSibling),t===null)return null}return t}function Tm(t,e){for(;t.nodeType!==8;){if((t.nodeType!==1||t.nodeName!=="INPUT"||t.type!=="hidden")&&!e)return null;if(t=It(t.nextSibling),t===null)return null}return t}function ps(t){return t.data==="$?"||t.data==="$~"}function ms(t){return t.data==="$!"||t.data==="$?"&&t.ownerDocument.readyState!=="loading"}function A_(t,e){var n=t.ownerDocument;if(t.data==="$~")t._reactRetry=e;else if(t.data!=="$?"||n.readyState!=="loading")e();else{var l=function(){e(),n.removeEventListener("DOMContentLoaded",l)};n.addEventListener("DOMContentLoaded",l),t._reactRetry=l}}function It(t){for(;t!=null;t=t.nextSibling){var e=t.nodeType;if(e===1||e===3)break;if(e===8){if(e=t.data,e==="$"||e==="$!"||e==="$?"||e==="$~"||e==="&"||e==="F!"||e==="F")break;if(e==="/$"||e==="/&")return null}}return t}function Gd(t){t=t.nextSibling;for(var e=0;t;){if(t.nodeType===8){var n=t.data;if(n==="/$"||n==="/&"){if(e===0)return It(t.nextSibling);e--}else n!=="$"&&n!=="$!"&&n!=="$?"&&n!=="$~"&&n!=="&"||e++}t=t.nextSibling}return null}function Yd(t){t=t.previousSibling;for(var e=0;t;){if(t.nodeType===8){var n=t.data;if(n==="$"||n==="$!"||n==="$?"||n==="$~"||n==="&"){if(e===0)return t;e--}else n!=="/$"&&n!=="/&"||e++}t=t.previousSibling}return null}function zm(t,e,n){switch(e=Du(n),t){case"html":if(t=e.documentElement,!t)throw Error(_(452));return t;case"head":if(t=e.head,!t)throw Error(_(453));return t;case"body":if(t=e.body,!t)throw Error(_(454));return t;default:throw Error(_(451))}}function Ha(t){for(var e=t.attributes;e.length;)t.removeAttributeNode(e[0]);Ns(t)}function Tu(t){return typeof t.getRootNode==="function"?t.getRootNode():t.nodeType===9?t:t.ownerDocument}function D_(){var t=Ge.f(),e=Zu();return t||e}function T_(t){var e=Xl(t);e!==null&&e.tag===5&&e.type==="form"?Ep(e):Ge.r(t)}function wm(t,e,n){var l=Jl;if(l&&typeof e==="string"&&e){var a=Jt(e);a='link[rel="'+t+'"][href="'+a+'"]',typeof n==="string"&&(a+='[crossorigin="'+n+'"]'),Kd.has(a)||(Kd.add(a),t={rel:t,crossOrigin:n,href:e},l.querySelector(a)===null&&(e=l.createElement("link"),yt(e,"link",t),dt(e),l.head.appendChild(e)))}}function z_(t){Ge.D(t),wm("dns-prefetch",t,null)}function w_(t,e){Ge.C(t,e),wm("preconnect",t,e)}function R_(t,e,n){Ge.L(t,e,n);var l=Jl;if(l&&t&&e){var a='link[rel="preload"][as="'+Jt(e)+'"]';e==="image"?n&&n.imageSrcSet?(a+='[imagesrcset="'+Jt(n.imageSrcSet)+'"]',typeof n.imageSizes==="string"&&(a+='[imagesizes="'+Jt(n.imageSizes)+'"]')):a+='[href="'+Jt(t)+'"]':a+='[href="'+Jt(t)+'"]';var i=a;switch(e){case"style":i=Gl(t);break;case"script":i=$l(t)}Pt.has(i)||(t=P({rel:"preload",href:e==="image"&&n&&n.imageSrcSet?void 0:t,as:e},n),Pt.set(i,t),l.querySelector(a)!==null||e==="style"&&l.querySelector(ci(i))||e==="script"&&l.querySelector(fi(i))||(e=l.createElement("link"),yt(e,"link",t),dt(e),l.head.appendChild(e)))}}function M_(t,e){Ge.m(t,e);var n=Jl;if(n&&t){var l=e&&typeof e.as==="string"?e.as:"script",a='link[rel="modulepreload"][as="'+Jt(l)+'"][href="'+Jt(t)+'"]',i=a;switch(l){case"audioworklet":case"paintworklet":case"serviceworker":case"sharedworker":case"worker":case"script":i=$l(t)}if(!Pt.has(i)&&(t=P({rel:"modulepreload",href:t},e),Pt.set(i,t),n.querySelector(a)===null)){switch(l){case"audioworklet":case"paintworklet":case"serviceworker":case"sharedworker":case"worker":case"script":if(n.querySelector(fi(i)))return}l=n.createElement("link"),yt(l,"link",t),dt(l),n.head.appendChild(l)}}}function C_(t,e,n){Ge.S(t,e,n);var l=Jl;if(l&&t){var a=xl(l).hoistableStyles,i=Gl(t);e=e||"default";var u=a.get(i);if(!u){var o={loading:0,preload:null};if(u=l.querySelector(ci(i)))o.loading=5;else{t=P({rel:"stylesheet",href:t,"data-precedence":e},n),(n=Pt.get(i))&&sc(t,n);var r=u=l.createElement("link");dt(r),yt(r,"link",t),r._p=new Promise(function(s,h){r.onload=s,r.onerror=h}),r.addEventListener("load",function(){o.loading|=1}),r.addEventListener("error",function(){o.loading|=2}),o.loading|=4,tu(u,e,l)}u={type:"stylesheet",instance:u,count:1,state:o},a.set(i,u)}}}function U_(t,e){Ge.X(t,e);var n=Jl;if(n&&t){var l=xl(n).hoistableScripts,a=$l(t),i=l.get(a);i||(i=n.querySelector(fi(a)),i||(t=P({src:t,async:!0},e),(e=Pt.get(a))&&cc(t,e),i=n.createElement("script"),dt(i),yt(i,"link",t),n.head.appendChild(i)),i={type:"script",instance:i,count:1,state:null},l.set(a,i))}}function V_(t,e){Ge.M(t,e);var n=Jl;if(n&&t){var l=xl(n).hoistableScripts,a=$l(t),i=l.get(a);i||(i=n.querySelector(fi(a)),i||(t=P({src:t,async:!0,type:"module"},e),(e=Pt.get(a))&&cc(t,e),i=n.createElement("script"),dt(i),yt(i,"link",t),n.head.appendChild(i)),i={type:"script",instance:i,count:1,state:null},l.set(a,i))}}function Xd(t,e,n,l){var a=(a=rn.current)?Tu(a):null;if(!a)throw Error(_(446));switch(t){case"meta":case"title":return null;case"style":return typeof n.precedence==="string"&&typeof n.href==="string"?(e=Gl(n.href),n=xl(a).hoistableStyles,l=n.get(e),l||(l={type:"style",instance:null,count:0,state:null},n.set(e,l)),l):{type:"void",instance:null,count:0,state:null};case"link":if(n.rel==="stylesheet"&&typeof n.href==="string"&&typeof n.precedence==="string"){t=Gl(n.href);var i=xl(a).hoistableStyles,u=i.get(t);if(u||(a=a.ownerDocument||a,u={type:"stylesheet",instance:null,count:0,state:{loading:0,preload:null}},i.set(t,u),(i=a.querySelector(ci(t)))&&!i._p&&(u.instance=i,u.state.loading=5),Pt.has(t)||(n={rel:"preload",as:"style",href:n.href,crossOrigin:n.crossOrigin,integrity:n.integrity,media:n.media,hrefLang:n.hrefLang,referrerPolicy:n.referrerPolicy},Pt.set(t,n),i||B_(a,t,n,u.state))),e&&l===null)throw Error(_(528,""));return u}if(e&&l!==null)throw Error(_(529,""));return null;case"script":return e=n.async,n=n.src,typeof n==="string"&&e&&typeof e!=="function"&&typeof e!=="symbol"?(e=$l(n),n=xl(a).hoistableScripts,l=n.get(e),l||(l={type:"script",instance:null,count:0,state:null},n.set(e,l)),l):{type:"void",instance:null,count:0,state:null};default:throw Error(_(444,t))}}function Gl(t){return'href="'+Jt(t)+'"'}function ci(t){return'link[rel="stylesheet"]['+t+"]"}function Rm(t){return P({},t,{"data-precedence":t.precedence,precedence:null})}function B_(t,e,n,l){t.querySelector('link[rel="preload"][as="style"]['+e+"]")?l.loading=1:(e=t.createElement("link"),l.preload=e,e.addEventListener("load",function(){return l.loading|=1}),e.addEventListener("error",function(){return l.loading|=2}),yt(e,"link",n),dt(e),t.head.appendChild(e))}function $l(t){return'[src="'+Jt(t)+'"]'}function fi(t){return"script[async]"+t}function Qd(t,e,n){if(e.count++,e.instance===null)switch(e.type){case"style":var l=t.querySelector('style[data-href~="'+Jt(n.href)+'"]');if(l)return e.instance=l,dt(l),l;var a=P({},n,{"data-href":n.href,"data-precedence":n.precedence,href:null,precedence:null});return l=(t.ownerDocument||t).createElement("style"),dt(l),yt(l,"style",a),tu(l,n.precedence,t),e.instance=l;case"stylesheet":a=Gl(n.href);var i=t.querySelector(ci(a));if(i)return e.state.loading|=4,e.instance=i,dt(i),i;l=Rm(n),(a=Pt.get(a))&&sc(l,a),i=(t.ownerDocument||t).createElement("link"),dt(i);var u=i;return u._p=new Promise(function(o,r){u.onload=o,u.onerror=r}),yt(i,"link",l),e.state.loading|=4,tu(i,n.precedence,t),e.instance=i;case"script":if(i=$l(n.src),a=t.querySelector(fi(i)))return e.instance=a,dt(a),a;if(l=n,a=Pt.get(i))l=P({},n),cc(l,a);return t=t.ownerDocument||t,a=t.createElement("script"),dt(a),yt(a,"link",l),t.head.appendChild(a),e.instance=a;case"void":return null;default:throw Error(_(443,e.type))}else e.type==="stylesheet"&&(e.state.loading&4)===0&&(l=e.instance,e.state.loading|=4,tu(l,n.precedence,t));return e.instance}function tu(t,e,n){for(var l=n.querySelectorAll('link[rel="stylesheet"][data-precedence],style[data-precedence]'),a=l.length?l[l.length-1]:null,i=a,u=0;u<l.length;u++){var o=l[u];if(o.dataset.precedence===e)i=o;else if(i!==a)break}i?i.parentNode.insertBefore(t,i.nextSibling):(e=n.nodeType===9?n.head:n,e.insertBefore(t,e.firstChild))}function sc(t,e){t.crossOrigin==null&&(t.crossOrigin=e.crossOrigin),t.referrerPolicy==null&&(t.referrerPolicy=e.referrerPolicy),t.title==null&&(t.title=e.title)}function cc(t,e){t.crossOrigin==null&&(t.crossOrigin=e.crossOrigin),t.referrerPolicy==null&&(t.referrerPolicy=e.referrerPolicy),t.integrity==null&&(t.integrity=e.integrity)}function Zd(t,e,n){if(eu===null){var l=new Map,a=eu=new Map;a.set(n,l)}else a=eu,l=a.get(n),l||(l=new Map,a.set(n,l));if(l.has(t))return l;l.set(t,null),n=n.getElementsByTagName(t);for(a=0;a<n.length;a++){var i=n[a];if(!(i[ai]||i[mt]||t==="link"&&i.getAttribute("rel")==="stylesheet")&&i.namespaceURI!=="http://www.w3.org/2000/svg"){var u=i.getAttribute(e)||"";u=t+u;var o=l.get(u);o?o.push(i):l.set(u,[i])}}return l}function kd(t,e,n){t=t.ownerDocument||t,t.head.insertBefore(n,e==="title"?t.querySelector("head > title"):null)}function q_(t,e,n){if(n===1||e.itemProp!=null)return!1;switch(t){case"meta":case"title":return!0;case"style":if(typeof e.precedence!=="string"||typeof e.href!=="string"||e.href==="")break;return!0;case"link":if(typeof e.rel!=="string"||typeof e.href!=="string"||e.href===""||e.onLoad||e.onError)break;switch(e.rel){case"stylesheet":return t=e.disabled,typeof e.precedence==="string"&&t==null;default:return!0}case"script":if(e.async&&typeof e.async!=="function"&&typeof e.async!=="symbol"&&!e.onLoad&&!e.onError&&e.src&&typeof e.src==="string")return!0}return!1}function Mm(t){return t.type==="stylesheet"&&(t.state.loading&3)===0?!1:!0}function j_(t,e,n,l){if(n.type==="stylesheet"&&(typeof l.media!=="string"||matchMedia(l.media).matches!==!1)&&(n.state.loading&4)===0){if(n.instance===null){var a=Gl(l.href),i=e.querySelector(ci(a));if(i){e=i._p,e!==null&&typeof e==="object"&&typeof e.then==="function"&&(t.count++,t=zu.bind(t),e.then(t,t)),n.state.loading|=4,n.instance=i,dt(i);return}i=e.ownerDocument||e,l=Rm(l),(a=Pt.get(a))&&sc(l,a),i=i.createElement("link"),dt(i);var u=i;u._p=new Promise(function(o,r){u.onload=o,u.onerror=r}),yt(i,"link",l),n.instance=i}t.stylesheets===null&&(t.stylesheets=new Map),t.stylesheets.set(n,e),(e=n.state.preload)&&(n.state.loading&3)===0&&(t.count++,n=zu.bind(t),e.addEventListener("load",n),e.addEventListener("error",n))}}function H_(t,e){return t.stylesheets&&t.count===0&&nu(t,t.stylesheets),0<t.count||0<t.imgCount?function(n){var l=setTimeout(function(){if(t.stylesheets&&nu(t,t.stylesheets),t.unsuspend){var i=t.unsuspend;t.unsuspend=null,i()}},60000+e);0<t.imgBytes&&Sr===0&&(Sr=62500*b_());var a=setTimeout(function(){if(t.waitingForImages=!1,t.count===0&&(t.stylesheets&&nu(t,t.stylesheets),t.unsuspend)){var i=t.unsuspend;t.unsuspend=null,i()}},(t.imgBytes>Sr?50:800)+e);return t.unsuspend=n,function(){t.unsuspend=null,clearTimeout(l),clearTimeout(a)}}:null}function zu(){if(this.count--,this.count===0&&(this.imgCount===0||!this.waitingForImages)){if(this.stylesheets)nu(this,this.stylesheets);else if(this.unsuspend){var t=this.unsuspend;this.unsuspend=null,t()}}}function nu(t,e){t.stylesheets=null,t.unsuspend!==null&&(t.count++,wu=new Map,e.forEach(L_,t),wu=null,zu.call(t))}function L_(t,e){if(!(e.state.loading&4)){var n=wu.get(t);if(n)var l=n.get(null);else{n=new Map,wu.set(t,n);for(var a=t.querySelectorAll("link[data-precedence],style[data-precedence]"),i=0;i<a.length;i++){var u=a[i];if(u.nodeName==="LINK"||u.getAttribute("media")!=="not all")n.set(u.dataset.precedence,u),l=u}l&&n.set(null,l)}a=e.instance,u=a.getAttribute("data-precedence"),i=n.get(u)||l,i===l&&n.set(null,a),n.set(u,a),this.count++,l=zu.bind(this),a.addEventListener("load",l),a.addEventListener("error",l),i?i.parentNode.insertBefore(a,i.nextSibling):(t=t.nodeType===9?t.head:t,t.insertBefore(a,t.firstChild)),e.state.loading|=4}}function G_(t,e,n,l,a,i,u,o,r){this.tag=1,this.containerInfo=t,this.pingCache=this.current=this.pendingChildren=null,this.timeoutHandle=-1,this.callbackNode=this.next=this.pendingContext=this.context=this.cancelPendingCommit=null,this.callbackPriority=0,this.expirationTimes=Jo(-1),this.entangledLanes=this.shellSuspendCounter=this.errorRecoveryDisabledLanes=this.expiredLanes=this.warmLanes=this.pingedLanes=this.suspendedLanes=this.pendingLanes=0,this.entanglements=Jo(0),this.hiddenUpdates=Jo(null),this.identifierPrefix=l,this.onUncaughtError=a,this.onCaughtError=i,this.onRecoverableError=u,this.pooledCache=null,this.pooledCacheLanes=0,this.formState=r,this.incompleteTransitions=new Map}function Cm(t,e,n,l,a,i,u,o,r,s,h,g){return t=new G_(t,e,n,u,r,s,h,g,o),e=1,i===!0&&(e|=24),i=Mt(3,null,null,e),t.current=i,i.stateNode=t,e=Bs(),e.refCount++,t.pooledCache=e,e.refCount++,i.memoizedState={element:l,isDehydrated:n,cache:e},Hs(i),t}function Um(t){if(!t)return Sl;return t=Sl,t}function Vm(t,e,n,l,a,i){a=Um(a),l.context===null?l.context=a:l.pendingContext=a,l=cn(e),l.payload={element:n},i=i===void 0?null:i,i!==null&&(l.callback=i),n=fn(t,l,e),n!==null&&(Dt(n,t,e),Ra(n,t,e))}function Jd(t,e){if(t=t.memoizedState,t!==null&&t.dehydrated!==null){var n=t.retryLane;t.retryLane=n!==0&&n<e?n:e}}function fc(t,e){Jd(t,e),(t=t.alternate)&&Jd(t,e)}function Bm(t){if(t.tag===13||t.tag===31){var e=Jn(t,67108864);e!==null&&Dt(e,t,67108864),fc(t,67108864)}}function $d(t){if(t.tag===13||t.tag===31){var e=qt();e=Es(e);var n=Jn(t,e);n!==null&&Dt(n,t,e),fc(t,e)}}function Y_(t,e,n,l){var a=T.T;T.T=null;var i=L.p;try{L.p=2,dc(t,e,n,l)}finally{L.p=i,T.T=a}}function K_(t,e,n,l){var a=T.T;T.T=null;var i=L.p;try{L.p=8,dc(t,e,n,l)}finally{L.p=i,T.T=a}}function dc(t,e,n,l){if(Ru){var a=gs(l);if(a===null)br(t,e,l,Mu,n),Wd(t,l);else if(Q_(a,t,e,n,l))l.stopPropagation();else if(Wd(t,l),e&4&&-1<X_.indexOf(t)){for(;a!==null;){var i=Xl(a);if(i!==null)switch(i.tag){case 3:if(i=i.stateNode,i.current.memoizedState.isDehydrated){var u=Rn(i.pendingLanes);if(u!==0){var o=i;o.pendingLanes|=2;for(o.entangledLanes|=2;u;){var r=1<<31-Bt(u);o.entanglements[1]|=r,u&=~r}ye(i),(H&6)===0&&(Su=Ut()+500,si(0,!1))}}break;case 31:case 13:o=Jn(i,2),o!==null&&Dt(o,i,2),Zu(),fc(i,2)}if(i=gs(l),i===null&&br(t,e,l,Mu,n),i===a)break;a=i}a!==null&&l.stopPropagation()}else br(t,e,l,null,n)}}function gs(t){return t=As(t),hc(t)}function hc(t){if(Mu=null,t=ml(t),t!==null){var e=ti(t);if(e===null)t=null;else{var n=e.tag;if(n===13){if(t=nh(e),t!==null)return t;t=null}else if(n===31){if(t=lh(e),t!==null)return t;t=null}else if(n===3){if(e.stateNode.current.memoizedState.isDehydrated)return e.tag===3?e.stateNode.containerInfo:null;t=null}else e!==t&&(t=null)}}return Mu=t,null}function qm(t){switch(t){case"beforetoggle":case"cancel":case"click":case"close":case"contextmenu":case"copy":case"cut":case"auxclick":case"dblclick":case"dragend":case"dragstart":case"drop":case"focusin":case"focusout":case"input":case"invalid":case"keydown":case"keypress":case"keyup":case"mousedown":case"mouseup":case"paste":case"pause":case"play":case"pointercancel":case"pointerdown":case"pointerup":case"ratechange":case"reset":case"resize":case"seeked":case"submit":case"toggle":case"touchcancel":case"touchend":case"touchstart":case"volumechange":case"change":case"selectionchange":case"textInput":case"compositionstart":case"compositionend":case"compositionupdate":case"beforeblur":case"afterblur":case"beforeinput":case"blur":case"fullscreenchange":case"focus":case"hashchange":case"popstate":case"select":case"selectstart":return 2;case"drag":case"dragenter":case"dragexit":case"dragleave":case"dragover":case"mousemove":case"mouseout":case"mouseover":case"pointermove":case"pointerout":case"pointerover":case"scroll":case"touchmove":case"wheel":case"mouseenter":case"mouseleave":case"pointerenter":case"pointerleave":return 8;case"message":switch(Rb()){case oh:return 2;case rh:return 8;case ou:case Mb:return 32;case sh:return 268435456;default:return 32}default:return 32}}function Wd(t,e){switch(t){case"focusin":case"focusout":pn=null;break;case"dragenter":case"dragleave":mn=null;break;case"mouseover":case"mouseout":vn=null;break;case"pointerover":case"pointerout":Ia.delete(e.pointerId);break;case"gotpointercapture":case"lostpointercapture":Pa.delete(e.pointerId)}}function ga(t,e,n,l,a,i){if(t===null||t.nativeEvent!==i)return t={blockedOn:e,domEventName:n,eventSystemFlags:l,nativeEvent:i,targetContainers:[a]},e!==null&&(e=Xl(e),e!==null&&Bm(e)),t;return t.eventSystemFlags|=l,e=t.targetContainers,a!==null&&e.indexOf(a)===-1&&e.push(a),t}function Q_(t,e,n,l,a){switch(e){case"focusin":return pn=ga(pn,t,e,n,l,a),!0;case"dragenter":return mn=ga(mn,t,e,n,l,a),!0;case"mouseover":return vn=ga(vn,t,e,n,l,a),!0;case"pointerover":var i=a.pointerId;return Ia.set(i,ga(Ia.get(i)||null,t,e,n,l,a)),!0;case"gotpointercapture":return i=a.pointerId,Pa.set(i,ga(Pa.get(i)||null,t,e,n,l,a)),!0}return!1}function jm(t){var e=ml(t.target);if(e!==null){var n=ti(e);if(n!==null){if(e=n.tag,e===13){if(e=nh(n),e!==null){t.blockedOn=e,Vf(t.priority,function(){$d(n)});return}}else if(e===31){if(e=lh(n),e!==null){t.blockedOn=e,Vf(t.priority,function(){$d(n)});return}}else if(e===3&&n.stateNode.current.memoizedState.isDehydrated){t.blockedOn=n.tag===3?n.stateNode.containerInfo:null;return}}}t.blockedOn=null}function lu(t){if(t.blockedOn!==null)return!1;for(var e=t.targetContainers;0<e.length;){var n=gs(t.nativeEvent);if(n===null){n=t.nativeEvent;var l=new n.constructor(n.type,n);Ur=l,n.target.dispatchEvent(l),Ur=null}else return e=Xl(n),e!==null&&Bm(e),t.blockedOn=n,!1;e.shift()}return!0}function Fd(t,e,n){lu(t)&&n.delete(e)}function Z_(){ys=!1,pn!==null&&lu(pn)&&(pn=null),mn!==null&&lu(mn)&&(mn=null),vn!==null&&lu(vn)&&(vn=null),Ia.forEach(Fd),Pa.forEach(Fd)}function Li(t,e){t.blockedOn===e&&(t.blockedOn=null,ys||(ys=!0,il(al,Z_)))}function Id(t){Gi!==t&&(Gi=t,il(al,function(){Gi===t&&(Gi=null);for(var e=0;e<t.length;e+=3){var n=t[e],l=t[e+1],a=t[e+2];if(typeof l!=="function")if(hc(l||n)===null)continue;else break;var i=Xl(n);i!==null&&(t.splice(e,3),e-=3,Wr(i,{pending:!0,data:a,method:n.method,action:l},l,a))}}))}function Yl(t){function e(r){return Li(r,t)}pn!==null&&Li(pn,t),mn!==null&&Li(mn,t),vn!==null&&Li(vn,t),Ia.forEach(e),Pa.forEach(e);for(var n=0;n<en.length;n++){var l=en[n];l.blockedOn===t&&(l.blockedOn=null)}for(;0<en.length&&(n=en[0],n.blockedOn===null);)jm(n),n.blockedOn===null&&en.shift();if(n=(t.ownerDocument||t).$$reactFormReplay,n!=null)for(l=0;l<n.length;l+=3){var a=n[l],i=n[l+1],u=a[Tt]||null;if(typeof i==="function")u||Id(n);else if(u){var o=null;if(i&&i.hasAttribute("formAction")){if(a=i,u=i[Tt]||null)o=u.formAction;else if(hc(a)!==null)continue}else o=u.action;typeof o==="function"?n[l+1]=o:(n.splice(l,3),l-=3),Id(n)}}}function Hm(){function t(i){i.canIntercept&&i.info==="react-transition"&&i.intercept({handler:function(){return new Promise(function(u){return a=u})},focusReset:"manual",scroll:"manual"})}function e(){a!==null&&(a(),a=null),l||setTimeout(n,20)}function n(){if(!l&&!navigation.transition){var i=navigation.currentEntry;i&&i.url!=null&&navigation.navigate(i.url,{state:i.getState(),info:"react-transition",history:"replace"})}}if(typeof navigation==="object"){var l=!1,a=null;return navigation.addEventListener("navigate",t),navigation.addEventListener("navigatesuccess",e),navigation.addEventListener("navigateerror",e),setTimeout(n,100),function(){l=!0,navigation.removeEventListener("navigate",t),navigation.removeEventListener("navigatesuccess",e),navigation.removeEventListener("navigateerror",e),a!==null&&(a(),a=null)}}}function pc(t){this._internalRoot=t}function $u(t){this._internalRoot=t}var Cu,th,P,xb,Ti,ya,hl,ih,Er,uh,we,bs,Or,Nr,_s,We,xr,Ab,Mf,Db,ba,T,L,Vn,Dr,pl=-1,ve,La,rn,au,Xo,Cf,Qo=!1,zr,Ss,ko,zb,wb,Ut,Rb,oh,rh,ou,Mb,sh,Cb,Ub,ei=null,Vt=null,Bt,Vb,Bb,zi=256,wi=262144,Ri=4194304,Sn,mt,Tt,Kl,wr,Lb,Gb,Bf,ai,mh,vh,Yb,qf,jf,Qb,Zb,kb,Jb,Ur=null,vl=null,Dl=null,$o=!1,Be,Vr=!1,Mn,ln=null,Ds=null,Xi=null,Zn,Vu,ii,$b,Wo,Fo,ha,Bu,Yf,Wb,Fb,Ib,Io,Pb,t0,e0,n0,l0,Kf,a0,i0,u0,r0,s0,c0,Xf,f0,d0,h0,p0,m0,v0,g0,y0,b0,zs,Da=null,_0,xh,Qf,Zf=!1,gl=!1,O0,Ta=null,Ya=null,zh=!1,Sa,Ea,Zi,jt,w0,yl=null,Br=null,za=null,qr=!1,bl,Po,Ch,Uh,Vh,Bh,R0,M0,C0,qh,jh,jr,su,Xt,_l=0,Rs=0,Sl,Pf,El,Ol=0,fu=null,Xa=0,Zt,kt=0,gn=null,he=1,pe="",vt=null,I=null,q=!1,sn=null,Wt=!1,Hr,Lr,$n=null,Me=null,V0,B0,q0,ot,wa=null,Kr=0,Vl=0,Tl=null,ld,qn,Zl,js,Lu,hu,jn=null,zl=null,Za=0,Yn,Jh,Fe=!1,Qr=!1,Bl,pu,Ht,Ft=null,lt,qe=0,R=null,Q=null,it=null,vu=!1,wl=!1,Kn=!1,gu=0,ka=0,Rl=null,L0=0,Ja,Tp,Ps,zp,Fr,tc,rt=!1,ur,ze=!1,ut=!1,pr=!1,Ad,ft=null,tt=null,xt=!1,ie=null,Na=8192,e_,n_,H=0,Z=null,V=null,B=0,Y=0,wt=null,an=!1,kl=!1,ac=!1,Le=0,nt=0,_n=0,Hn=0,ic=0,Ct=0,jl=0,qa=null,At=null,ns=!1,Qu=0,am=0,Su=1/0,Eu=null,dn=null,st=0,hn=null,Hl=null,Ve=0,ls=0,as=null,im=null,ja=0,is=null,Nu=null,fl=null,us=!1,xu=!1,gr=!1,on=0,Aa,os,rs,xa,$a,p_,Hi,v_,g_,cs=null,fs=null,_r=null,Dm,S_,jd,E_,vs=null,Pt,Kd,Ge,Jl,eu=null,Sr=0,wu=null,Fa,Ru=!0,Mu=null,ys=!1,pn=null,mn=null,vn=null,Ia,Pa,en,X_,Gi=null,Pd,k_,dl,Lm=function(t,e){if(!eh(t))throw Error(_(299));var n=!1,l="",a=wp,i=Rp,u=Mp;return e!==null&&e!==void 0&&(e.unstable_strictMode===!0&&(n=!0),e.identifierPrefix!==void 0&&(l=e.identifierPrefix),e.onUncaughtError!==void 0&&(a=e.onUncaughtError),e.onCaughtError!==void 0&&(i=e.onCaughtError),e.onRecoverableError!==void 0&&(u=e.onRecoverableError)),e=Cm(t,1,!1,null,null,n,l,null,a,i,u,Hm),t[Kl]=e.current,rc(t),new pc(e)},Gm=function(t,e,n){if(!eh(t))throw Error(_(299));var l=!1,a="",i=wp,u=Rp,o=Mp,r=null;return n!==null&&n!==void 0&&(n.unstable_strictMode===!0&&(l=!0),n.identifierPrefix!==void 0&&(a=n.identifierPrefix),n.onUncaughtError!==void 0&&(i=n.onUncaughtError),n.onCaughtError!==void 0&&(u=n.onCaughtError),n.onRecoverableError!==void 0&&(o=n.onRecoverableError),n.formState!==void 0&&(r=n.formState)),e=Cm(t,1,!0,e,n!=null?n:null,l,a,r,i,u,o,Hm),e.context=Um(null),n=e.current,l=qt(),l=Es(l),a=cn(l),a.callback=null,fn(n,a,l),n=l,e.current.lanes=n,li(e,n),ye(e),t[Kl]=e.current,rc(t),new $u(e)},Ym="19.2.8";var Km=yo(()=>{Pc();Cu=ce(Ee(),1),th=ce(wf(),1);P=Object.assign,xb=Symbol.for("react.element"),Ti=Symbol.for("react.transitional.element"),ya=Symbol.for("react.portal"),hl=Symbol.for("react.fragment"),ih=Symbol.for("react.strict_mode"),Er=Symbol.for("react.profiler"),uh=Symbol.for("react.consumer"),we=Symbol.for("react.context"),bs=Symbol.for("react.forward_ref"),Or=Symbol.for("react.suspense"),Nr=Symbol.for("react.suspense_list"),_s=Symbol.for("react.memo"),We=Symbol.for("react.lazy"),xr=Symbol.for("react.activity"),Ab=Symbol.for("react.memo_cache_sentinel"),Mf=Symbol.iterator;Db=Symbol.for("react.client.reference");ba=Array.isArray,T=Cu.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,L=th.__DOM_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,Vn={pending:!1,data:null,method:null,action:null},Dr=[];ve=ge(null),La=ge(null),rn=ge(null),au=ge(null);zr=Object.prototype.hasOwnProperty,Ss=il,ko=Mo,zb=Vo,wb=Uo,Ut=de,Rb=Co,oh=zo,rh=Ro,ou=al,Mb=wo,sh=To,Cb=void 0,Ub=void 0;Bt=Math.clz32?Math.clz32:qb,Vb=Math.log,Bb=Math.LN2;Sn=Math.random().toString(36).slice(2),mt="__reactFiber$"+Sn,Tt="__reactProps$"+Sn,Kl="__reactContainer$"+Sn,wr="__reactEvents$"+Sn,Lb="__reactListeners$"+Sn,Gb="__reactHandles$"+Sn,Bf="__reactResources$"+Sn,ai="__reactMarker$"+Sn;mh=new Set,vh={};Yb=RegExp("^[: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]*$"),qf={},jf={};Qb=/[\n"\\]/g;Zb=new Set("animationIterationCount aspectRatio borderImageOutset borderImageSlice borderImageWidth boxFlex boxFlexGroup boxOrdinalGroup columnCount columns flex flexGrow flexPositive flexShrink flexNegative flexOrder gridArea gridRow gridRowEnd gridRowSpan gridRowStart gridColumn gridColumnEnd gridColumnSpan gridColumnStart fontWeight lineClamp lineHeight opacity order orphans scale tabSize widows zIndex zoom fillOpacity floodOpacity stopOpacity strokeDasharray strokeDashoffset strokeMiterlimit strokeOpacity strokeWidth MozAnimationIterationCount MozBoxFlex MozBoxFlexGroup MozLineClamp msAnimationIterationCount msFlex msZoom msFlexGrow msFlexNegative msFlexOrder msFlexPositive msFlexShrink msGridColumn msGridColumnSpan msGridRow msGridRowSpan WebkitAnimationIterationCount WebkitBoxFlex WebKitBoxFlexGroup WebkitBoxOrdinalGroup WebkitColumnCount WebkitColumns WebkitFlex WebkitFlexGrow WebkitFlexPositive WebkitFlexShrink WebkitLineClamp".split(" "));kb=new Map([["acceptCharset","accept-charset"],["htmlFor","for"],["httpEquiv","http-equiv"],["crossOrigin","crossorigin"],["accentHeight","accent-height"],["alignmentBaseline","alignment-baseline"],["arabicForm","arabic-form"],["baselineShift","baseline-shift"],["capHeight","cap-height"],["clipPath","clip-path"],["clipRule","clip-rule"],["colorInterpolation","color-interpolation"],["colorInterpolationFilters","color-interpolation-filters"],["colorProfile","color-profile"],["colorRendering","color-rendering"],["dominantBaseline","dominant-baseline"],["enableBackground","enable-background"],["fillOpacity","fill-opacity"],["fillRule","fill-rule"],["floodColor","flood-color"],["floodOpacity","flood-opacity"],["fontFamily","font-family"],["fontSize","font-size"],["fontSizeAdjust","font-size-adjust"],["fontStretch","font-stretch"],["fontStyle","font-style"],["fontVariant","font-variant"],["fontWeight","font-weight"],["glyphName","glyph-name"],["glyphOrientationHorizontal","glyph-orientation-horizontal"],["glyphOrientationVertical","glyph-orientation-vertical"],["horizAdvX","horiz-adv-x"],["horizOriginX","horiz-origin-x"],["imageRendering","image-rendering"],["letterSpacing","letter-spacing"],["lightingColor","lighting-color"],["markerEnd","marker-end"],["markerMid","marker-mid"],["markerStart","marker-start"],["overlinePosition","overline-position"],["overlineThickness","overline-thickness"],["paintOrder","paint-order"],["panose-1","panose-1"],["pointerEvents","pointer-events"],["renderingIntent","rendering-intent"],["shapeRendering","shape-rendering"],["stopColor","stop-color"],["stopOpacity","stop-opacity"],["strikethroughPosition","strikethrough-position"],["strikethroughThickness","strikethrough-thickness"],["strokeDasharray","stroke-dasharray"],["strokeDashoffset","stroke-dashoffset"],["strokeLinecap","stroke-linecap"],["strokeLinejoin","stroke-linejoin"],["strokeMiterlimit","stroke-miterlimit"],["strokeOpacity","stroke-opacity"],["strokeWidth","stroke-width"],["textAnchor","text-anchor"],["textDecoration","text-decoration"],["textRendering","text-rendering"],["transformOrigin","transform-origin"],["underlinePosition","underline-position"],["underlineThickness","underline-thickness"],["unicodeBidi","unicode-bidi"],["unicodeRange","unicode-range"],["unitsPerEm","units-per-em"],["vAlphabetic","v-alphabetic"],["vHanging","v-hanging"],["vIdeographic","v-ideographic"],["vMathematical","v-mathematical"],["vectorEffect","vector-effect"],["vertAdvY","vert-adv-y"],["vertOriginX","vert-origin-x"],["vertOriginY","vert-origin-y"],["wordSpacing","word-spacing"],["writingMode","writing-mode"],["xmlnsXlink","xmlns:xlink"],["xHeight","x-height"]]),Jb=/^[\u0000-\u001F ]*j[\r\n\t]*a[\r\n\t]*v[\r\n\t]*a[\r\n\t]*s[\r\n\t]*c[\r\n\t]*r[\r\n\t]*i[\r\n\t]*p[\r\n\t]*t[\r\n\t]*:/i;Be=!(typeof window>"u"||typeof window.document>"u"||typeof window.document.createElement>"u");if(Be)try{Mn={},Object.defineProperty(Mn,"passive",{get:function(){Vr=!0}}),window.addEventListener("test",Mn,Mn),window.removeEventListener("test",Mn,Mn)}catch(t){Vr=!1}Zn={eventPhase:0,bubbles:0,cancelable:0,timeStamp:function(t){return t.timeStamp||Date.now()},defaultPrevented:0,isTrusted:0},Vu=zt(Zn),ii=P({},Zn,{view:0,detail:0}),$b=zt(ii),Bu=P({},ii,{screenX:0,screenY:0,clientX:0,clientY:0,pageX:0,pageY:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,getModifierState:Ts,button:0,buttons:0,relatedTarget:function(t){return t.relatedTarget===void 0?t.fromElement===t.srcElement?t.toElement:t.fromElement:t.relatedTarget},movementX:function(t){if("movementX"in t)return t.movementX;return t!==ha&&(ha&&t.type==="mousemove"?(Wo=t.screenX-ha.screenX,Fo=t.screenY-ha.screenY):Fo=Wo=0,ha=t),Wo},movementY:function(t){return"movementY"in t?t.movementY:Fo}}),Yf=zt(Bu),Wb=P({},Bu,{dataTransfer:0}),Fb=zt(Wb),Ib=P({},ii,{relatedTarget:0}),Io=zt(Ib),Pb=P({},Zn,{animationName:0,elapsedTime:0,pseudoElement:0}),t0=zt(Pb),e0=P({},Zn,{clipboardData:function(t){return"clipboardData"in t?t.clipboardData:window.clipboardData}}),n0=zt(e0),l0=P({},Zn,{data:0}),Kf=zt(l0),a0={Esc:"Escape",Spacebar:" ",Left:"ArrowLeft",Up:"ArrowUp",Right:"ArrowRight",Down:"ArrowDown",Del:"Delete",Win:"OS",Menu:"ContextMenu",Apps:"ContextMenu",Scroll:"ScrollLock",MozPrintableKey:"Unidentified"},i0={8:"Backspace",9:"Tab",12:"Clear",13:"Enter",16:"Shift",17:"Control",18:"Alt",19:"Pause",20:"CapsLock",27:"Escape",32:" ",33:"PageUp",34:"PageDown",35:"End",36:"Home",37:"ArrowLeft",38:"ArrowUp",39:"ArrowRight",40:"ArrowDown",45:"Insert",46:"Delete",112:"F1",113:"F2",114:"F3",115:"F4",116:"F5",117:"F6",118:"F7",119:"F8",120:"F9",121:"F10",122:"F11",123:"F12",144:"NumLock",145:"ScrollLock",224:"Meta"},u0={Alt:"altKey",Control:"ctrlKey",Meta:"metaKey",Shift:"shiftKey"};r0=P({},ii,{key:function(t){if(t.key){var e=a0[t.key]||t.key;if(e!=="Unidentified")return e}return t.type==="keypress"?(t=Qi(t),t===13?"Enter":String.fromCharCode(t)):t.type==="keydown"||t.type==="keyup"?i0[t.keyCode]||"Unidentified":""},code:0,location:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,repeat:0,locale:0,getModifierState:Ts,charCode:function(t){return t.type==="keypress"?Qi(t):0},keyCode:function(t){return t.type==="keydown"||t.type==="keyup"?t.keyCode:0},which:function(t){return t.type==="keypress"?Qi(t):t.type==="keydown"||t.type==="keyup"?t.keyCode:0}}),s0=zt(r0),c0=P({},Bu,{pointerId:0,width:0,height:0,pressure:0,tangentialPressure:0,tiltX:0,tiltY:0,twist:0,pointerType:0,isPrimary:0}),Xf=zt(c0),f0=P({},ii,{touches:0,targetTouches:0,changedTouches:0,altKey:0,metaKey:0,ctrlKey:0,shiftKey:0,getModifierState:Ts}),d0=zt(f0),h0=P({},Zn,{propertyName:0,elapsedTime:0,pseudoElement:0}),p0=zt(h0),m0=P({},Bu,{deltaX:function(t){return"deltaX"in t?t.deltaX:("wheelDeltaX"in t)?-t.wheelDeltaX:0},deltaY:function(t){return"deltaY"in t?t.deltaY:("wheelDeltaY"in t)?-t.wheelDeltaY:("wheelDelta"in t)?-t.wheelDelta:0},deltaZ:0,deltaMode:0}),v0=zt(m0),g0=P({},Zn,{newState:0,oldState:0}),y0=zt(g0),b0=[9,13,27,32],zs=Be&&"CompositionEvent"in window;Be&&"documentMode"in document&&(Da=document.documentMode);_0=Be&&"TextEvent"in window&&!Da,xh=Be&&(!zs||Da&&8<Da&&11>=Da),Qf=String.fromCharCode(32);O0={color:!0,date:!0,datetime:!0,"datetime-local":!0,email:!0,month:!0,number:!0,password:!0,range:!0,search:!0,tel:!0,text:!0,time:!0,url:!0,week:!0};if(Be){if(Be){if(Ea="oninput"in document,!Ea)Zi=document.createElement("div"),Zi.setAttribute("oninput","return;"),Ea=typeof Zi.oninput==="function";Sa=Ea}else Sa=!1;zh=Sa&&(!document.documentMode||9<document.documentMode)}jt=typeof Object.is==="function"?Object.is:z0;w0=Be&&"documentMode"in document&&11>=document.documentMode;bl={animationend:zn("Animation","AnimationEnd"),animationiteration:zn("Animation","AnimationIteration"),animationstart:zn("Animation","AnimationStart"),transitionrun:zn("Transition","TransitionRun"),transitionstart:zn("Transition","TransitionStart"),transitioncancel:zn("Transition","TransitionCancel"),transitionend:zn("Transition","TransitionEnd")},Po={},Ch={};Be&&(Ch=document.createElement("div").style,("AnimationEvent"in window)||(delete bl.animationend.animation,delete bl.animationiteration.animation,delete bl.animationstart.animation),("TransitionEvent"in window)||delete bl.transitionend.transition);Uh=kn("animationend"),Vh=kn("animationiteration"),Bh=kn("animationstart"),R0=kn("transitionrun"),M0=kn("transitionstart"),C0=kn("transitioncancel"),qh=kn("transitionend"),jh=new Map,jr="abort auxClick beforeToggle cancel canPlay canPlayThrough click close contextMenu copy cut drag dragEnd dragEnter dragExit dragLeave dragOver dragStart drop durationChange emptied encrypted ended error gotPointerCapture input invalid keyDown keyPress keyUp load loadedData loadedMetadata loadStart lostPointerCapture mouseDown mouseMove mouseOut mouseOver mouseUp paste pause play playing pointerCancel pointerDown pointerMove pointerOut pointerOver pointerUp progress rateChange reset resize seeked seeking stalled submit suspend timeUpdate touchCancel touchEnd touchStart volumeChange scroll toggle touchMove waiting wheel".split(" ");jr.push("scrollEnd");su=typeof reportError==="function"?reportError:function(t){if(typeof window==="object"&&typeof window.ErrorEvent==="function"){var e=new window.ErrorEvent("error",{bubbles:!0,cancelable:!0,message:typeof t==="object"&&t!==null&&typeof t.message==="string"?String(t.message):String(t),error:t});if(!window.dispatchEvent(e))return}else if(typeof process==="object"&&typeof process.emit==="function"){process.emit("uncaughtException",t);return}console.error(t)},Xt=[];Sl={};Pf=new WeakMap;El=[],Zt=[];Hr=Error(_(519));Lr=ge(null);V0=typeof AbortController<"u"?AbortController:function(){var t=[],e=this.signal={aborted:!1,addEventListener:function(n,l){t.push(l)}};this.abort=function(){e.aborted=!0,t.forEach(function(n){return n()})}},B0=il,q0=al,ot={$$typeof:we,Consumer:null,Provider:null,_currentValue:null,_currentValue2:null,_threadCount:0};ld=T.S;T.S=function(t,e){am=Ut(),typeof e==="object"&&e!==null&&typeof e.then==="function"&&j0(t,e),ld!==null&&ld(t,e)};qn=ge(null);Zl=Error(_(460)),js=Error(_(474)),Lu=Error(_(542)),hu={then:function(){}};Yn=kh(!0),Jh=kh(!1);Bl=ge(null),pu=ge(0);Ht=ge(null);lt=ge(0);Ja={readContext:gt,use:Yu,useCallback:et,useContext:et,useEffect:et,useImperativeHandle:et,useLayoutEffect:et,useInsertionEffect:et,useMemo:et,useReducer:et,useRef:et,useState:et,useDebugValue:et,useDeferredValue:et,useTransition:et,useSyncExternalStore:et,useId:et,useHostTransitionStatus:et,useFormState:et,useActionState:et,useOptimistic:et,useMemoCache:et,useCacheRefresh:et};Ja.useEffectEvent=et;Tp={readContext:gt,use:Yu,useCallback:function(t,e){return Et().memoizedState=[t,e===void 0?null:e],t},useContext:gt,useEffect:hd,useImperativeHandle:function(t,e,n){n=n!==null&&n!==void 0?n.concat([t]):null,Wi(4194308,4,mp.bind(null,e,t),n)},useLayoutEffect:function(t,e){return Wi(4194308,4,t,e)},useInsertionEffect:function(t,e){Wi(4,2,t,e)},useMemo:function(t,e){var n=Et();e=e===void 0?null:e;var l=t();if(Kn){nn(!0);try{t()}finally{nn(!1)}}return n.memoizedState=[l,e],l},useReducer:function(t,e,n){var l=Et();if(n!==void 0){var a=n(e);if(Kn){nn(!0);try{n(e)}finally{nn(!1)}}}else a=e;return l.memoizedState=l.baseState=a,t={pending:null,lanes:0,dispatch:null,lastRenderedReducer:t,lastRenderedState:a},l.queue=t,t=t.dispatch=k0.bind(null,R,t),[l.memoizedState,t]},useRef:function(t){var e=Et();return t={current:t},e.memoizedState=t},useState:function(t){t=Jr(t);var e=t.queue,n=xp.bind(null,R,e);return e.dispatch=n,[t.memoizedState,n]},useDebugValue:$s,useDeferredValue:function(t,e){var n=Et();return Ws(n,t,e)},useTransition:function(){var t=Jr(!1);return t=_p.bind(null,R,t.queue,!0,!1),Et().memoizedState=t,[!1,t]},useSyncExternalStore:function(t,e,n){var l=R,a=Et();if(q){if(n===void 0)throw Error(_(407));n=n()}else{if(n=e(),Z===null)throw Error(_(349));(B&127)!==0||ep(l,e,n)}a.memoizedState=n;var i={value:n,getSnapshot:e};return a.queue=i,hd(lp.bind(null,l,i,t),[t]),l.flags|=2048,ql(9,{destroy:void 0},np.bind(null,l,i,n,e),null),n},useId:function(){var t=Et(),e=Z.identifierPrefix;if(q){var n=pe,l=he;n=(l&~(1<<32-Bt(l)-1)).toString(32)+n,e="_"+e+"R_"+n,n=gu++,0<n&&(e+="H"+n.toString(32)),e+="_"}else n=L0++,e="_"+e+"r_"+n.toString(32)+"_";return t.memoizedState=e},useHostTransitionStatus:Fs,useFormState:cd,useActionState:cd,useOptimistic:function(t){var e=Et();e.memoizedState=e.baseState=t;var n={pending:null,lanes:0,dispatch:null,lastRenderedReducer:null,lastRenderedState:null};return e.queue=n,e=Is.bind(null,R,!0,n),n.dispatch=e,[t,e]},useMemoCache:Zs,useCacheRefresh:function(){return Et().memoizedState=Z0.bind(null,R)},useEffectEvent:function(t){var e=Et(),n={impl:t};return e.memoizedState=n,function(){if((H&2)!==0)throw Error(_(440));return n.impl.apply(void 0,arguments)}}},Ps={readContext:gt,use:Yu,useCallback:gp,useContext:gt,useEffect:Js,useImperativeHandle:vp,useInsertionEffect:hp,useLayoutEffect:pp,useMemo:yp,useReducer:$i,useRef:fp,useState:function(){return $i(je)},useDebugValue:$s,useDeferredValue:function(t,e){var n=at();return bp(n,Q.memoizedState,t,e)},useTransition:function(){var t=$i(je)[0],e=at().memoizedState;return[typeof t==="boolean"?t:oi(t),e]},useSyncExternalStore:tp,useId:Op,useHostTransitionStatus:Fs,useFormState:fd,useActionState:fd,useOptimistic:function(t,e){var n=at();return up(n,Q,t,e)},useMemoCache:Zs,useCacheRefresh:Np};Ps.useEffectEvent=dp;zp={readContext:gt,use:Yu,useCallback:gp,useContext:gt,useEffect:Js,useImperativeHandle:vp,useInsertionEffect:hp,useLayoutEffect:pp,useMemo:yp,useReducer:ar,useRef:fp,useState:function(){return ar(je)},useDebugValue:$s,useDeferredValue:function(t,e){var n=at();return Q===null?Ws(n,t,e):bp(n,Q.memoizedState,t,e)},useTransition:function(){var t=ar(je)[0],e=at().memoizedState;return[typeof t==="boolean"?t:oi(t),e]},useSyncExternalStore:tp,useId:Op,useHostTransitionStatus:Fs,useFormState:dd,useActionState:dd,useOptimistic:function(t,e){var n=at();if(Q!==null)return up(n,Q,t,e);return n.baseState=t,[t,n.queue.dispatch]},useMemoCache:Zs,useCacheRefresh:Np};zp.useEffectEvent=dp;Fr={enqueueSetState:function(t,e,n){t=t._reactInternals;var l=qt(),a=cn(l);a.payload=e,n!==void 0&&n!==null&&(a.callback=n),e=fn(t,a,l),e!==null&&(Dt(e,t,l),Ra(e,t,l))},enqueueReplaceState:function(t,e,n){t=t._reactInternals;var l=qt(),a=cn(l);a.tag=1,a.payload=e,n!==void 0&&n!==null&&(a.callback=n),e=fn(t,a,l),e!==null&&(Dt(e,t,l),Ra(e,t,l))},enqueueForceUpdate:function(t,e){t=t._reactInternals;var n=qt(),l=cn(n);l.tag=2,e!==void 0&&e!==null&&(l.callback=e),e=fn(t,l,n),e!==null&&(Dt(e,t,n),Ra(e,t,n))}};tc=Error(_(461));ur={dehydrated:null,treeContext:null,retryLane:0,hydrationErrors:null};Ad=typeof WeakSet==="function"?WeakSet:Set;e_={getCacheForType:function(t){var e=gt(ot),n=e.data.get(t);return n===void 0&&(n=t(),e.data.set(t,n)),n},cacheSignal:function(){return gt(ot).controller.signal}},n_=typeof WeakMap==="function"?WeakMap:Map;for(xa=0;xa<jr.length;xa++)Aa=jr[xa],os=Aa.toLowerCase(),rs=Aa[0].toUpperCase()+Aa.slice(1),ue(os,"on"+rs);ue(Uh,"onAnimationEnd");ue(Vh,"onAnimationIteration");ue(Bh,"onAnimationStart");ue("dblclick","onDoubleClick");ue("focusin","onFocus");ue("focusout","onBlur");ue(R0,"onTransitionRun");ue(M0,"onTransitionStart");ue(C0,"onTransitionCancel");ue(qh,"onTransitionEnd");Cl("onMouseEnter",["mouseout","mouseover"]);Cl("onMouseLeave",["mouseout","mouseover"]);Cl("onPointerEnter",["pointerout","pointerover"]);Cl("onPointerLeave",["pointerout","pointerover"]);Qn("onChange","change click focusin focusout input keydown keyup selectionchange".split(" "));Qn("onSelect","focusout contextmenu dragend focusin keydown keyup mousedown mouseup selectionchange".split(" "));Qn("onBeforeInput",["compositionend","keypress","textInput","paste"]);Qn("onCompositionEnd","compositionend focusout keydown keypress keyup mousedown".split(" "));Qn("onCompositionStart","compositionstart focusout keydown keypress keyup mousedown".split(" "));Qn("onCompositionUpdate","compositionupdate focusout keydown keypress keyup mousedown".split(" "));$a="abort canplay canplaythrough durationchange emptied encrypted ended error loadeddata loadedmetadata loadstart pause play playing progress ratechange resize seeked seeking stalled suspend timeupdate volumechange waiting".split(" "),p_=new Set("beforetoggle cancel close invalid load scroll scrollend toggle".split(" ").concat($a));Hi="_reactListening"+Math.random().toString(36).slice(2);v_=/\r\n?/g,g_=/\u0000|\uFFFD/g;Dm=typeof setTimeout==="function"?setTimeout:void 0,S_=typeof clearTimeout==="function"?clearTimeout:void 0,jd=typeof Promise==="function"?Promise:void 0,E_=typeof queueMicrotask==="function"?queueMicrotask:typeof jd<"u"?function(t){return jd.resolve(null).then(t).catch(O_)}:Dm;Pt=new Map,Kd=new Set;Ge=L.d;L.d={f:D_,r:T_,D:z_,C:w_,L:R_,m:M_,X:U_,S:C_,M:V_};Jl=typeof document>"u"?null:document;Fa={$$typeof:we,Provider:null,Consumer:null,_currentValue:Vn,_currentValue2:Vn,_threadCount:0};Ia=new Map,Pa=new Map,en=[],X_="mousedown mouseup touchcancel touchend touchstart auxclick dblclick pointercancel pointerdown pointerup dragend dragstart drop compositionend compositionstart keydown keypress keyup input textInput copy cut paste click change contextmenu reset".split(" ");$u.prototype.render=pc.prototype.render=function(t){var e=this._internalRoot;if(e===null)throw Error(_(409));var n=e.current,l=qt();Vm(n,l,t,e,null,null)};$u.prototype.unmount=pc.prototype.unmount=function(){var t=this._internalRoot;if(t!==null){this._internalRoot=null;var e=t.containerInfo;Vm(t.current,2,null,t,null,null),Zu(),e[Kl]=null}};$u.prototype.unstable_scheduleHydration=function(t){if(t){var e=ph();t={blockedOn:null,target:t,priority:e};for(var n=0;n<en.length&&e!==0&&e<en[n].priority;n++);en.splice(n,0,t),n===0&&jm(t)}};Pd=Cu.version;if(Pd!=="19.2.8")throw Error(_(527,Pd,"19.2.8"));L.findDOMNode=function(t){var e=t._reactInternals;if(e===void 0){if(typeof t.render==="function")throw Error(_(188));throw t=Object.keys(t).join(","),Error(_(268,t))}return t=Nb(e),t=t!==null?ah(t):null,t=t===null?null:t.stateNode,t};k_={bundleType:0,version:"19.2.8",rendererPackageName:"react-dom",currentDispatcherRef:T,reconcilerVersion:"19.2.8"};if(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__<"u"){if(dl=__REACT_DEVTOOLS_GLOBAL_HOOK__,!dl.isDisabled&&dl.supportsFiber)try{ei=dl.inject(k_),Vt=dl}catch(t){}}});var Zm=go(function(FS,Qm){Km();function Xm(){if(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__>"u"||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!=="function")return;try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(Xm)}catch(t){console.error(t)}}Xm(),Qm.exports=mc});var ey=ce(Zm(),1);function J(t,...e){throw Error(`[MobX] minified error nr: ${t}${e.length?" "+e.map(String).join(","):""}. See mobx.js.org/errors`)}var{assign:_e,getOwnPropertyDescriptor:Nc,defineProperty:Xe,prototype:ao}=Object,yc=[];Object.freeze(yc);var uv={};Object.freeze(uv);var W_=Object.toString();var Fl=()=>{};function Pl(t){return typeof t==="function"}function bc(t){switch(typeof t){case"string":case"symbol":case"number":return!0}return!1}function io(t){return t!==null&&typeof t==="object"}function Ze(t){if(!io(t))return!1;let e=Object.getPrototypeOf(t);if(e==null)return!0;let n=Wn(e,"constructor")&&e.constructor;return typeof n==="function"&&n.toString()===W_}function ov(t){let e=t==null?void 0:t.constructor;if(!e)return!1;if(e.name==="GeneratorFunction"||e.displayName==="GeneratorFunction")return!0;return!1}function rv(t,e,n){Xe(t,e,{enumerable:!1,writable:!0,configurable:!0,value:n})}function F_(t,e,n){Xe(t,e,{enumerable:!1,writable:!1,configurable:!0,value:n})}function Pn(t,e){let n="isMobX"+t;return e.prototype[n]=!0,function(l){return io(l)&&l[n]===!0}}function mi(t){return t!=null&&Object.prototype.toString.call(t)==="[object Map]"}function I_(t){let e=Object.getPrototypeOf(t),n=Object.getPrototypeOf(e);return Object.getPrototypeOf(n)===null}function On(t){return t!=null&&Object.prototype.toString.call(t)==="[object Set]"}function P_(t){let e=Object.keys(t),n=Object.getOwnPropertySymbols(t);if(!n.length)return e;return[...e,...n.filter((l)=>ao.propertyIsEnumerable.call(t,l))]}var Pu=Reflect.ownKeys;function sv(t){return t===null?null:typeof t==="object"?""+t:t}function Wn(t,e){return ao.hasOwnProperty.call(t,e)}var t1=Object.getOwnPropertyDescriptors;function Lt(t,e){return!!(t&e)}function Gt(t,e,n){if(n)t|=e;else t&=~e;return t}var M=Symbol("mobx administration");class ea{constructor(t="Atom"){this.name_=void 0,this.flags_=0,this.observers_=new Set,this.lastAccessedBy_=0,this.lowestObserverState_=-1,this.onBOL=void 0,this.onBUOL=void 0,this.name_=t}get isBeingObserved(){return Lt(this.flags_,1)}set isBeingObserved(t){this.flags_=Gt(this.flags_,1,t)}get isPendingUnobservation(){return Lt(this.flags_,2)}set isPendingUnobservation(t){this.flags_=Gt(this.flags_,2,t)}get diffValue(){return Lt(this.flags_,4)?1:0}set diffValue(t){this.flags_=Gt(this.flags_,4,t===1?!0:!1)}onBO(){if(this.onBOL)this.onBOL.forEach((t)=>t())}onBUO(){if(this.onBUOL)this.onBUOL.forEach((t)=>t())}reportObserved(){return Mv(this)}reportChanged(){ne(),Cv(this),le()}toString(){return this.name_}}var xc=Pn("Atom",ea);function cv(t,e=Fl,n=Fl){let l=new ea(t);if(e!==Fl)l.onBOL=new Set([e]);if(n!==Fl)l.onBUOL=new Set([n]);return l}var Ac=Object.is;function Fn(t,e,n){if(kv(t))return t;if(Array.isArray(t))return bt.array(t,{name:n});if(Ze(t))return bt.object(t,void 0,{name:n});if(mi(t))return bt.map(t,{name:n});if(On(t))return bt.set(t,{name:n});if(typeof t==="function"&&!ta(t)&&!hi(t))if(ov(t))return co(t);else return wc(n,t);return t}function e1(t,e,n){if(t===void 0||t===null)return t;if(pi(t)||$v(t)||aa(t)||Ke(t))return t;if(Array.isArray(t))return bt.array(t,{name:n,deep:!1});if(Ze(t))return bt.object(t,void 0,{name:n,deep:!1});if(mi(t))return bt.map(t,{name:n,deep:!1});if(On(t))return bt.set(t,{name:n,deep:!1})}function uo(t){return t}function oo(t,e){return{annotationType_:t,options_:e,make_:n1,extend_:l1}}function n1(t,e,n,l){var a;if((a=this.options_)!=null&&a.bound)return this.extend_(t,e,n,!1)===null?0:1;if(l===t.target_)return this.extend_(t,e,n,!1)===null?0:2;if(ta(n.value))return 1;let i=dv(t,this,e,n,!1);return Xe(l,e,i),2}function l1(t,e,n,l){let a=dv(t,this,e,n);return t.defineProperty_(e,a,l)}function fv(t,e,n){let{kind:l,name:a,addInitializer:i}=n,u=t,o=(s)=>{var h,g,d,v;return In((h=(g=u.options_)==null?void 0:g.name)!=null?h:a.toString(),s,(d=(v=u.options_)==null?void 0:v.autoAction)!=null?d:!1)};if(l=="field")return function(s){var h;let g=s;if(!ta(g))g=o(g);if((h=u.options_)!=null&&h.bound)g=g.bind(this),g.isMobxAction=!0;return g};if(l=="method"){var r;if(!ta(e))e=o(e);if((r=u.options_)!=null&&r.bound)i(function(){let s=this,h=s[a].bind(s);h.isMobxAction=!0,s[a]=h});return e}J(43,u.annotationType_,String(a),l)}function a1(t,{annotationType_:e},n,{value:l}){}function dv(t,e,n,l,a=x.safeDescriptors){var i,u,o,r,s,h,g;a1(t,e,n,l);let{value:d}=l;if((i=e.options_)!=null&&i.bound){var v;d=d.bind((v=t.proxy_)!=null?v:t.target_)}return{value:In((u=(o=e.options_)==null?void 0:o.name)!=null?u:n.toString(),d,(r=(s=e.options_)==null?void 0:s.autoAction)!=null?r:!1,(h=e.options_)!=null&&h.bound?(g=t.proxy_)!=null?g:t.target_:void 0),configurable:a?t.isPlainObject_:!0,enumerable:!1,writable:a?!1:!0}}function hv(t,e){return{annotationType_:t,options_:e,make_:i1,extend_:u1}}function i1(t,e,n,l){var a;if(l===t.target_)return this.extend_(t,e,n,!1)===null?0:2;if((a=this.options_)!=null&&a.bound&&(!Wn(t.target_,e)||!hi(t.target_[e]))){if(this.extend_(t,e,n,!1)===null)return 0}if(hi(n.value))return 1;let i=mv(t,this,e,n,!1,!1);return Xe(l,e,i),2}function u1(t,e,n,l){var a;let i=mv(t,this,e,n,(a=this.options_)==null?void 0:a.bound);return t.defineProperty_(e,i,l)}function pv(t,e,n){var l;let{name:a,addInitializer:i}=n;if(!hi(e))e=co(e);if((l=t.options_)!=null&&l.bound)i(function(){let u=this,o=u[a].bind(u);o.isMobXFlow=!0,u[a]=o});return e}function o1(t,{annotationType_:e},n,{value:l}){}function mv(t,e,n,l,a,i=x.safeDescriptors){o1(t,e,n,l);let{value:u}=l;if(!hi(u))u=co(u);if(a){var o;u=u.bind((o=t.proxy_)!=null?o:t.target_),u.isMobXFlow=!0}return{value:u,configurable:i?t.isPlainObject_:!0,enumerable:!1,writable:i?!1:!0}}function vv(t,e){return{annotationType_:t,options_:e,make_:r1,extend_:s1}}function r1(t,e,n){return this.extend_(t,e,n,!1)===null?0:1}function s1(t,e,n,l){return c1(t,this,e,n),t.defineComputedProperty_(e,_e({},this.options_,{get:n.get,set:n.set}),l)}function gv(t,e,n){let l=t,{name:a,addInitializer:i}=n,u;function o(r,s){let h=_e({},l.options_,{get:e,context:r});return h.name||(h.name=`ObservableObject.${a.toString()}`),new Qe(h)}return i(function(){var r;let s=yi(this)[M],h=this,g=s.values_.get(a);if(g instanceof Qe&&g.derivation!==e)s.values_.delete(a);((r=s.lazyComputedKeys_)!=null?r:s.lazyComputedKeys_=new Map).set(a,()=>o(h,s))}),function(){let r=this[M],s=r.values_.get(a);if(s instanceof Qe&&s.derivation!==e){var h;let d=(h=u)==null?void 0:h.get(this);if(!d){var g;d=o(this,r),((g=u)!=null?g:u=new WeakMap).set(this,d)}return d.get()}return r.getObservablePropValue_(a)}}function c1(t,{annotationType_:e},n,{get:l}){}function Dc(t,e){return{annotationType_:t,options_:e,make_:f1,extend_:d1}}function f1(t,e,n){return this.extend_(t,e,n,!1)===null?0:1}function d1(t,e,n,l){var a,i;return h1(t,this,e,n),t.defineObservableProperty_(e,n.value,(a=(i=this.options_)==null?void 0:i.enhancer_)!=null?a:Fn,l)}function yv(t,e,n){let l=t,{kind:a,name:i}=n;if(a!=="accessor")return;function u(o,r){var s;let h=yi(o)[M];return((s=h.lazyObservableKeys_)!=null?s:h.lazyObservableKeys_=new Map).set(i,()=>{var g,d;return new xn(r,(g=(d=l.options_)==null?void 0:d.enhancer_)!=null?g:Fn,`ObservableObject.${i.toString()}`,!1)}),h}return{get(){var o;return((o=this[M])!=null?o:u(this,e.get.call(this))).getObservablePropValue_(i)},set(o){var r;return((r=this[M])!=null?r:u(this,o)).setObservablePropValue_(i,o)},init(o){return u(this,o),o}}}function h1(t,{annotationType_:e},n,l){}var p1="true",m1=bv();function bv(t){return{annotationType_:p1,options_:t,make_:v1,extend_:g1}}function v1(t,e,n,l){var a,i;if(n.get)return Tc.make_(t,e,n,l);if(n.set){let h=ta(n.set)?n.set:In(e.toString(),n.set);if(l===t.target_)return t.defineProperty_(e,{configurable:x.safeDescriptors?t.isPlainObject_:!0,set:h})===null?0:2;return Xe(l,e,{configurable:!0,set:h}),2}if(l!==t.target_&&typeof n.value==="function"){var u;if(ov(n.value)){var o;return((o=this.options_)!=null&&o.autoBind?tS:co).make_(t,e,n,l)}return((u=this.options_)!=null&&u.autoBind?k1:wc).make_(t,e,n,l)}let r=((a=this.options_)==null?void 0:a.deep)===!1?na:bt;if(typeof n.value==="function"&&(i=this.options_)!=null&&i.autoBind){var s;n.value=n.value.bind((s=t.proxy_)!=null?s:t.target_)}return r.make_(t,e,n,l)}function g1(t,e,n,l){var a,i;if(n.get)return Tc.extend_(t,e,n,l);if(n.set)return t.defineProperty_(e,{configurable:x.safeDescriptors?t.isPlainObject_:!0,set:In(e.toString(),n.set)},l);if(typeof n.value==="function"&&(a=this.options_)!=null&&a.autoBind){var u;n.value=n.value.bind((u=t.proxy_)!=null?u:t.target_)}return(((i=this.options_)==null?void 0:i.deep)===!1?na:bt).extend_(t,e,n,l)}function ro(t,e){return _e(function(l,a){if(a&&typeof a.kind==="string")return e(t,l,a);return},t)}var y1="observable",b1="observable.ref",_1="observable.shallow";var _v={deep:!0,name:void 0,defaultDecorator:void 0};Object.freeze(_v);function Wu(t){return t||_v}var Sv=Dc(y1),S1=Dc(b1,{enhancer_:uo}),E1=Dc(_1,{enhancer_:e1});function Ev(t){return ro(t,yv)}function Fu(t){return t.deep===!0?Fn:t.deep===!1?uo:N1(t.defaultDecorator)}function O1(t){var e;return t?(e=t.defaultDecorator)!=null?e:bv(t):void 0}function N1(t){var e,n;return!t?Fn:(e=(n=t.options_)==null?void 0:n.enhancer_)!=null?e:Fn}function x1(t,e,n){if(e&&typeof e.kind==="string")return yv(Sv,t,e);if(kv(t))return t;if(Ze(t))return bt.object(t,e,n);if(Array.isArray(t))return bt.array(t,e);if(mi(t))return bt.map(t,e);if(On(t))return bt.set(t,e);if(typeof t==="object"&&t!==null)return t;return bt.box(t,e)}var A1={box(t,e){let n=Wu(e);return new xn(t,Fu(n),n.name,!0,n.equals)},array(t,e){let n=Wu(e);return oS(t,Fu(n),n.name)},map(t,e){let n=Wu(e);return new Mc(t,Fu(n),n.name)},set(t,e){let n=Wu(e);return new Cc(t,Fu(n),n.name)},object(t,e,n){return ia(()=>Kv(lS({},n),t,e))}},na=Ev(S1),vi=Ev(E1);var bt=_e(x1,Sv,A1),Ov="computed";function D1(t){return ro(t,gv)}var Nv=vv(Ov);var Tc=function(e,n){if(n&&typeof n.kind==="string")return gv(Nv,e,n);if(Ze(e))return D1(vv(Ov,e));let l=Ze(n)?n:{};return l.get=e,l.name||(l.name=e.name||""),new Qe(l)};_e(Tc,Nv);var km,Jm,to=0,T1=1,z1=(km=(Jm=Nc(()=>{},"name"))==null?void 0:Jm.configurable)!=null?km:!1,$m={value:"action",configurable:!0,writable:!1,enumerable:!1};function In(t,e,n=!1,l){function a(){return xv(t,n,e,l||this,arguments)}if(a.isMobxAction=!0,a.toString=()=>e.toString(),z1)$m.value=t,Xe(a,"name",$m);return a}function xv(t,e,n,l,a){let i=w1(t,e,l,a);try{return n.apply(l,a)}catch(u){throw i.error_=u,u}finally{R1(i)}}function w1(t,e,n,l){let i=0,u=x.trackingDerivation,o=!e||!u;ne();let r=x.allowStateChanges;if(o)la();let s=x.allowStateReads,h={runAsAction_:o,prevDerivation_:u,prevAllowStateChanges_:r,prevAllowStateReads_:s,notifySpy_:!1,startTime_:i,actionId_:T1++,parentActionId_:to};return to=h.actionId_,h}function R1(t){if(to!==t.actionId_)J(30);if(to=t.parentActionId_,t.error_!==void 0)x.suppressReactionErrors=!0;if(le(),t.runAsAction_)An(t.prevDerivation_);x.suppressReactionErrors=!1}function M1(t,e){let n=C1(t);try{return e()}finally{U1(n)}}function C1(t){let e=x.allowStateChanges;return x.allowStateChanges=t,e}function U1(t){x.allowStateChanges=t}class xn extends ea{constructor(t,e,n="ObservableValue",l=!0,a=Ac){super(n);if(this.enhancer_=void 0,this.name_=void 0,this.equals_=void 0,this.hasUnreportedChange_=!1,this.interceptors_=void 0,this.changeListeners_=void 0,this.value_=void 0,this.dehancer=void 0,this.enhancer_=e,this.name_=n,this.equals_=a,this.value_=e(t,void 0,n),!1)var i}dehanceValue(t){if(this.dehancer!==void 0)return this.dehancer(t);return t}set(t){let e=this.value_;if(t=this.prepareNewValue_(t),t!==x.UNCHANGED)this.setNewValue_(t)}prepareNewValue_(t){if(be(this),te(this)){let e=ee(this,{object:this,type:Dn,newValue:t});if(!e)return x.UNCHANGED;t=e.newValue}return t=this.enhancer_(t,this.value_,this.name_),this.equals_(this.value_,t)?x.UNCHANGED:t}setNewValue_(t){let e=this.value_;if(this.value_=t,this.reportChanged(),oe(this))re(this,{type:Dn,object:this,newValue:t,oldValue:e})}get(){return this.reportObserved(),this.dehanceValue(this.value_)}raw(){return this.value_}toJSON(){return this.get()}toString(){return`${this.name_}[${this.value_}]`}valueOf(){return sv(this.get())}[Symbol.toPrimitive](){return this.valueOf()}}class Qe{constructor(t){if(this.dependenciesState_=-1,this.observing_=[],this.newObserving_=null,this.observers_=new Set,this.runId_=0,this.lastAccessedBy_=0,this.lowestObserverState_=0,this.unboundDepsCount_=0,this.value_=new di(null),this.name_=void 0,this.triggeredBy_=void 0,this.flags_=0,this.derivation=void 0,this.setter_=void 0,this.scope_=void 0,this.equals_=void 0,this.requiresReaction_=void 0,this.keepAlive_=void 0,this.onBOL=void 0,this.onBUOL=void 0,!t.get)J(31);if(this.derivation=t.get,this.name_=t.name||"ComputedValue",t.set)this.setter_=In("ComputedValue-setter",t.set);this.equals_=t.equals||Ac,this.scope_=t.context,this.requiresReaction_=t.requiresReaction,this.keepAlive_=!!t.keepAlive}onBecomeStale_(){G1(this)}onBO(){if(this.onBOL)this.onBOL.forEach((t)=>t())}onBUO(){if(this.onBUOL)this.onBUOL.forEach((t)=>t())}get isComputing(){return Lt(this.flags_,1)}set isComputing(t){this.flags_=Gt(this.flags_,1,t)}get isRunningSetter(){return Lt(this.flags_,2)}set isRunningSetter(t){this.flags_=Gt(this.flags_,2,t)}get isBeingObserved(){return Lt(this.flags_,4)}set isBeingObserved(t){this.flags_=Gt(this.flags_,4,t)}get isPendingUnobservation(){return Lt(this.flags_,8)}set isPendingUnobservation(t){this.flags_=Gt(this.flags_,8,t)}get diffValue(){return Lt(this.flags_,16)?1:0}set diffValue(t){this.flags_=Gt(this.flags_,16,t===1?!0:!1)}get(){if(this.isComputing)J(32,this.name_,this.derivation);if(x.inBatch===0&&this.observers_.size===0&&!this.keepAlive_){if(_c(this))this.warnAboutUntrackedRead_(),ne(),this.value_=this.computeValue_(!1),le()}else if(Mv(this),_c(this)){let e=x.trackingContext;if(this.keepAlive_&&!e)x.trackingContext=this;if(this.trackAndCompute())L1(this);x.trackingContext=e}let t=this.value_;if(Iu(t))throw t.cause;return t}set(t){if(this.setter_){if(this.isRunningSetter)J(33,this.name_);this.isRunningSetter=!0;try{this.setter_.call(this.scope_,t)}finally{this.isRunningSetter=!1}}else J(34,this.name_)}trackAndCompute(){let t=this.value_,e=this.dependenciesState_===-1,n=this.computeValue_(!0),l=e||Iu(t)||Iu(n)||!this.equals_(t,n);if(l)this.value_=n;return l}computeValue_(t){this.isComputing=!0;let e=!1,n;if(t)n=Av(this,this.derivation,this.scope_);else if(x.disableErrorBoundaries===!0)n=this.derivation.call(this.scope_);else try{n=this.derivation.call(this.scope_)}catch(l){n=new di(l)}return this.isComputing=!1,n}suspend_(){if(!this.keepAlive_)Sc(this),this.value_=void 0}warnAboutUntrackedRead_(){return}toString(){return`${this.name_}[${this.derivation.toString()}]`}valueOf(){return sv(this.get())}[Symbol.toPrimitive](){return this.valueOf()}}var so=Pn("ComputedValue",Qe);class di{constructor(t){this.cause=void 0,this.cause=t}}function Iu(t){return t instanceof di}function _c(t){switch(t.dependenciesState_){case 0:return!1;case-1:case 2:return!0;case 1:{let n=la(),l=t.observing_,a=l.length;for(let i=0;i<a;i++){let u=l[i];if(so(u)){if(x.disableErrorBoundaries)u.get();else try{u.get()}catch(o){return An(n),!0}if(t.dependenciesState_===2)return An(n),!0}}return Tv(t),An(n),!1}}}function be(t){return}function V1(t){}function Av(t,e,n){Tv(t),t.newObserving_=Array(t.runId_===0?100:t.observing_.length),t.unboundDepsCount_=0,t.runId_=++x.runId;let a=x.trackingDerivation;x.trackingDerivation=t,x.inBatch++;let i;if(x.disableErrorBoundaries===!0)i=e.call(n);else try{i=e.call(n)}catch(u){i=new di(u)}return x.inBatch--,x.trackingDerivation=a,q1(t),B1(t),i}function B1(t){return}function q1(t){let e=t.observing_,n=t.observing_=t.newObserving_,l=0,a=0,i=t.unboundDepsCount_;for(let u=0;u<i;u++){let o=n[u];if(o.diffValue===0){if(o.diffValue=1,a!==u)n[a]=o;a++}if(o.dependenciesState_>l)l=o.dependenciesState_}n.length=a,t.newObserving_=null,i=e.length;while(i--){let u=e[i];if(u.diffValue===0)wv(u,t);u.diffValue=0}while(a--){let u=n[a];if(u.diffValue===1)u.diffValue=0,H1(u,t)}if(l!==0)t.dependenciesState_=l,t.onBecomeStale_()}function Sc(t){let e=t.observing_;t.observing_=[];let n=e.length;while(n--)wv(e[n],t);t.dependenciesState_=-1}function Dv(t){let e=la();try{return t()}finally{An(e)}}function la(){let t=x.trackingDerivation;return x.trackingDerivation=null,t}function An(t){x.trackingDerivation=t}function Tv(t){if(t.dependenciesState_===0)return;t.dependenciesState_=0;let e=t.observing_,n=e.length;while(n--)e[n].lowestObserverState_=0}var zv=7;class Ec{constructor(){this.version=zv,this.UNCHANGED={},this.trackingDerivation=null,this.trackingContext=null,this.runId=0,this.mobxGuid=0,this.inBatch=0,this.pendingUnobservations=[],this.pendingReactions=[],this.isRunningReactions=!1,this.allowStateChanges=!1,this.allowStateReads=!0,this.enforceActions=!0,this.spyListeners=[],this.globalReactionErrorHandlers=[],this.computedRequiresReaction=!1,this.reactionRequiresObservable=!1,this.observableRequiresReaction=!1,this.disableErrorBoundaries=!1,this.suppressReactionErrors=!1,this.safeDescriptors=!0}}var vc=!0,j1=!1,x=function(){let t=globalThis;if(t.__mobxInstanceCount>0&&!t.__mobxGlobals)vc=!1;if(t.__mobxGlobals&&t.__mobxGlobals.version!==zv)vc=!1;if(!vc)return setTimeout(()=>{if(!j1)J(35)},1),new Ec;else if(t.__mobxGlobals){if(t.__mobxInstanceCount+=1,!t.__mobxGlobals.UNCHANGED)t.__mobxGlobals.UNCHANGED={};return t.__mobxGlobals}else return t.__mobxInstanceCount=1,t.__mobxGlobals=new Ec}();function zc(){return x}function H1(t,e){if(t.observers_.add(e),t.lowestObserverState_>e.dependenciesState_)t.lowestObserverState_=e.dependenciesState_}function wv(t,e){if(t.observers_.delete(e),t.observers_.size===0)Rv(t)}function Rv(t){if(t.isPendingUnobservation===!1)t.isPendingUnobservation=!0,x.pendingUnobservations.push(t)}function ne(){x.inBatch++}function le(){if(--x.inBatch===0){Uv();let t=x.pendingUnobservations;for(let e=0;e<t.length;e++){let n=t[e];if(n.isPendingUnobservation=!1,n.observers_.size===0){if(n.isBeingObserved)n.isBeingObserved=!1,n.onBUO();if(n instanceof Qe)n.suspend_()}}x.pendingUnobservations=[]}}function Mv(t){V1(t);let e=x.trackingDerivation;if(e!==null){if(e.runId_!==t.lastAccessedBy_){if(t.lastAccessedBy_=e.runId_,e.newObserving_[e.unboundDepsCount_++]=t,!t.isBeingObserved&&x.trackingContext)t.isBeingObserved=!0,t.onBO()}return t.isBeingObserved}else if(t.observers_.size===0&&x.inBatch>0)Rv(t);return!1}function Cv(t){if(t.lowestObserverState_===2)return;t.lowestObserverState_=2,t.observers_.forEach((e)=>{if(e.dependenciesState_===0)e.onBecomeStale_();e.dependenciesState_=2})}function L1(t){if(t.lowestObserverState_===2)return;t.lowestObserverState_=2,t.observers_.forEach((e)=>{if(e.dependenciesState_===1)e.dependenciesState_=2;else if(e.dependenciesState_===0)t.lowestObserverState_=0})}function G1(t){if(t.lowestObserverState_!==0)return;t.lowestObserverState_=1,t.observers_.forEach((e)=>{if(e.dependenciesState_===0)e.dependenciesState_=1,e.onBecomeStale_()})}class gi{constructor(t="Reaction",e,n,l){this.name_=void 0,this.onInvalidate_=void 0,this.errorHandler_=void 0,this.requiresObservable_=void 0,this.observing_=[],this.newObserving_=[],this.dependenciesState_=-1,this.runId_=0,this.unboundDepsCount_=0,this.flags_=0,this.name_=t,this.onInvalidate_=e,this.errorHandler_=n,this.requiresObservable_=l}get isDisposed(){return Lt(this.flags_,1)}set isDisposed(t){this.flags_=Gt(this.flags_,1,t)}get isScheduled(){return Lt(this.flags_,2)}set isScheduled(t){this.flags_=Gt(this.flags_,2,t)}get isTrackPending(){return Lt(this.flags_,4)}set isTrackPending(t){this.flags_=Gt(this.flags_,4,t)}get isRunning(){return Lt(this.flags_,8)}set isRunning(t){this.flags_=Gt(this.flags_,8,t)}get diffValue(){return Lt(this.flags_,16)?1:0}set diffValue(t){this.flags_=Gt(this.flags_,16,t===1?!0:!1)}onBecomeStale_(){this.schedule_()}schedule_(){if(!this.isScheduled)this.isScheduled=!0,x.pendingReactions.push(this),Uv()}runReaction_(){if(!this.isDisposed){ne(),this.isScheduled=!1;let t=x.trackingContext;if(x.trackingContext=this,_c(this)){this.isTrackPending=!0;try{this.onInvalidate_()}catch(e){this.reportExceptionInDerivation_(e)}}x.trackingContext=t,le()}}track(t){if(this.isDisposed)return;ne();let e=!1,n;this.isRunning=!0;let l=x.trackingContext;x.trackingContext=this;let a=Av(this,t,void 0);if(x.trackingContext=l,this.isRunning=!1,this.isTrackPending=!1,this.isDisposed)Sc(this);if(Iu(a))this.reportExceptionInDerivation_(a.cause);le()}reportExceptionInDerivation_(t){if(this.errorHandler_){this.errorHandler_(t,this);return}if(x.disableErrorBoundaries)throw t;let e=`[mobx] uncaught error in '${this}'`;if(!x.suppressReactionErrors)console.error(e,t);x.globalReactionErrorHandlers.forEach((n)=>n(t,this))}dispose(){if(!this.isDisposed){if(this.isDisposed=!0,!this.isRunning)ne(),Sc(this),le()}}getDisposer_(t){let e=()=>{this.dispose(),t==null||t.removeEventListener==null||t.removeEventListener("abort",e)};if(t==null||t.addEventListener==null||t.addEventListener("abort",e),e[M]=this,"dispose"in Symbol&&typeof Symbol.dispose==="symbol")e[Symbol.dispose]=e;return e}toString(){return`Reaction[${this.name_}]`}}var Y1=100,K1=(t)=>t();function Uv(){if(x.inBatch>0||x.isRunningReactions)return;K1(X1)}function X1(){x.isRunningReactions=!0;let t=x.pendingReactions,e=0;while(t.length>0){if(++e===Y1)console.error(`[mobx] cycle in reaction: ${t[0]}`),t.splice(0);let n=t.splice(0);for(let l=0,a=n.length;l<a;l++)n[l].runReaction_()}x.isRunningReactions=!1}var eo=Pn("Reaction",gi);var Vv="action";var Bv="autoAction",Q1="autoAction.bound",qv="<unnamed action>",jv=oo(Vv);var Hv=oo(Bv,{autoAction:!0}),Z1=oo(Q1,{autoAction:!0,bound:!0});function Lv(t){return ro(t,fv)}function Gv(t){return function(l,a){if(a&&typeof a.kind==="string")return fv(t?Hv:jv,l,a);if(Pl(l))return In(l.name||qv,l,t);if(Pl(a))return In(l,a,t);if(bc(l))return Lv(oo(t?Bv:Vv,{name:l,autoAction:t}))}}var Il=Gv(!1);_e(Il,jv);var wc=Gv(!0);_e(wc,Hv);var k1=Lv(Z1);function G(t){return xv(t.name||qv,!1,t,this,void 0)}function ta(t){return Pl(t)&&t.isMobxAction===!0}var J1=(t)=>t();function $1(t){return t.scheduler?t.scheduler:t.delay?(e)=>setTimeout(e,t.delay):J1}function Yv(t,e,n=uv){var l,a;let i=(l=n.name)!=null?l:"Reaction",u=Il(i,n.onError?W1(n.onError,e):e),o=!n.scheduler&&!n.delay,r=$1(n),s=!0,h=!1,g,d=n.equals||Ac,v=new gi(i,()=>{if(s||o)E();else if(!h)h=!0,r(E)},n.onError,n.requiresObservable);function E(){if(h=!1,v.isDisposed)return;let A=!1,z=g;if(v.track(()=>{let f=M1(!1,()=>t(v));A=s||!d(g,f),g=f}),s&&n.fireImmediately)u(g,z,v);else if(!s&&A)u(g,z,v);s=!1}if(!(n!=null&&(a=n.signal)!=null&&a.aborted))v.schedule_();return v.getDisposer_(n==null?void 0:n.signal)}function W1(t,e){return function(){try{return e.apply(this,arguments)}catch(n){t.call(this,n)}}}function Kv(t,e,n,l){let a=t1(e);return ia(()=>{let i=yi(t,l)[M];Pu(a).forEach((u)=>{i.extend_(u,a[u],!n?!0:(u in n)?n[u]:!0)})}),t}function Xv(t,e){return Qv(lo(t,e))}function Qv(t){let e={name:t.name_};if(t.observing_&&t.observing_.length>0)e.dependencies=F1(t.observing_).map(Qv);return e}function F1(t){return Array.from(new Set(t))}class Zv extends Error{constructor(){super("FLOW_CANCELLED");Object.setPrototypeOf(this,new.target.prototype),this.name="FlowCancellationError"}toString(){return`Error: ${this.message}`}}function I1(t){return ro(t,pv)}var Wm=hv("flow"),P1=hv("flow.bound",{bound:!0}),co=_e(function(e,n){if(n&&typeof n.kind==="string")return pv(Wm,e,n);let l=e,a=l.name||"flow",i=function(){let o=this,r=arguments,s=0,h=Il(a,l).apply(o,r),g,d=void 0,v=new Promise(function(A,z){let f=0;g=z;function c(O){d=void 0;let C;try{C=Il(a,h.next).call(h,O)}catch(N){return z(N)}b(C)}function p(O){d=void 0;let C;try{C=Il(a,h.throw).call(h,O)}catch(N){return z(N)}b(C)}function b(O){if(Pl(O==null?void 0:O.then)){O.then(b,z);return}if(O.done)return A(O.value);return d=Promise.resolve(O.value),d.then(c,p)}c(void 0)}),E=a;return v.cancel=Il(E,function(){try{if(d)Fm(d);let A=h.return(void 0),z=Promise.resolve(A.value);z.then(Fl,Fl),Fm(z),g(new Zv)}catch(A){g(A)}}),v};return i.isMobXFlow=!0,i},Wm),tS=I1(P1);function Fm(t){if(Pl(t.cancel))t.cancel()}function hi(t){return(t==null?void 0:t.isMobXFlow)===!0}function eS(t,e){if(!t)return!1;if(e!==void 0){if(pi(t)){var n,l;let a=t[M];return a.values_.has(e)||!!((n=a.lazyComputedKeys_)!=null&&n.has(e))||!!((l=a.lazyObservableKeys_)!=null&&l.has(e))}return!1}return pi(t)||!!t[M]||xc(t)||eo(t)||so(t)}function kv(t){return eS(t)}function Ye(t,e=void 0){ne();try{return t.apply(e)}finally{le()}}function Wl(t){return t[M]}var nS={has(t,e){return Wl(t).has_(e)},get(t,e){return Wl(t).get_(e)},set(t,e,n){var l;if(!bc(e))return!1;return(l=Wl(t).set_(e,n,!0))!=null?l:!0},deleteProperty(t,e){var n;if(!bc(e))return!1;return(n=Wl(t).delete_(e,!0))!=null?n:!0},defineProperty(t,e,n){var l;return(l=Wl(t).defineProperty_(e,n))!=null?l:!0},ownKeys(t){return Wl(t).ownKeys_()},preventExtensions(t){J(13)}};function lS(t,e){var n,l;return t=yi(t,e),(l=(n=t[M]).proxy_)!=null?l:n.proxy_=new Proxy(t,nS)}function te(t){return t.interceptors_!==void 0&&t.interceptors_.length>0}function ee(t,e){let n=la();try{let l=[...t.interceptors_||[]];for(let a=0,i=l.length;a<i;a++){if(e=l[a](e),e&&!e.type)J(14);if(!e)break}return e}finally{An(n)}}function oe(t){return t.changeListeners_!==void 0&&t.changeListeners_.length>0}function re(t,e){let n=la(),l=t.changeListeners_;if(!l)return;l=l.slice();for(let a=0,i=l.length;a<i;a++)l[a](e);An(n)}var gc=Symbol("mobx-keys");function ke(t,e,n){if(Ze(t))return Kv(t,t,e,n);return ia(()=>{let l=yi(t,n)[M];if(!t[gc]){let a=Object.getPrototypeOf(t),i=new Set([...Pu(t),...Pu(a)]);i.delete("constructor"),i.delete(M),rv(a,gc,i)}t[gc].forEach((a)=>aS(l,a,!e?!0:(a in e)?e[a]:!0))}),t}function aS(t,e,n){if(n===!0)n=t.defaultAnnotation_;if(n===!1)return;if(Fv(t,n,e),!(e in t.target_))J(1,n.annotationType_,`${t.name_}.${e.toString()}`);let l=t.target_;while(l&&l!==ao){let a=Nc(l,e);if(a){let i=n.make_(t,e,a,l);if(i===0)return;if(i===1)break}l=Object.getPrototypeOf(l)}Wv(t,n,e)}var Im="splice",Dn="update",iS=1e4,uS={get(t,e){let n=t[M];if(e===M)return n;if(e==="length")return n.getArrayLength_();if(typeof e==="string"&&!isNaN(e))return n.get_(parseInt(e));if(Wn(Oc,e))return Oc[e];return t[e]},set(t,e,n){let l=t[M];if(e==="length")l.setArrayLength_(n);if(typeof e==="symbol"||isNaN(e))t[e]=n;else l.set_(parseInt(e),n);return!0},preventExtensions(){J(15)}};class Rc{constructor(t="ObservableArray",e,n){this.owned_=void 0,this.atom_=void 0,this.values_=[],this.interceptors_=void 0,this.changeListeners_=void 0,this.enhancer_=void 0,this.dehancer=void 0,this.proxy_=void 0,this.lastKnownLength_=0,this.owned_=n,this.atom_=new ea(t),this.enhancer_=(l,a)=>e(l,a,"ObservableArray[..]")}dehanceValue_(t){if(this.dehancer!==void 0)return this.dehancer(t);return t}dehanceValues_(t){if(this.dehancer!==void 0&&t.length>0)return t.map(this.dehancer);return t}getArrayLength_(){return this.atom_.reportObserved(),this.values_.length}setArrayLength_(t){if(typeof t!=="number"||isNaN(t)||t<0)J(40,t);let e=this.values_.length;if(t===e)return;else if(t>e){let n=Array.from({length:t-e});this.spliceWithArray_(e,0,n)}else this.spliceWithArray_(t,e-t)}updateArrayLength_(t,e){if(t!==this.lastKnownLength_)J(16);this.lastKnownLength_+=e}spliceWithArray_(t,e,n){be(this.atom_);let l=this.values_.length;if(t===void 0)t=0;else if(t>l)t=l;else if(t<0)t=Math.max(0,l+t);if(arguments.length===1)e=l-t;else if(e===void 0||e===null)e=0;else e=Math.max(0,Math.min(e,l-t));if(n===void 0)n=yc;if(te(this)){let i=ee(this,{object:this.proxy_,type:Im,index:t,removedCount:e,added:n});if(!i)return yc;e=i.removedCount,n=i.added}n=n.length===0?n:n.map((i)=>this.enhancer_(i,void 0));let a=this.spliceItemsIntoValues_(t,e,n);if(e!==0||n.length!==0)this.notifyArraySplice_(t,n,a);return this.dehanceValues_(a)}spliceItemsIntoValues_(t,e,n){if(n.length<iS)return this.values_.splice(t,e,...n);else{let l=this.values_.slice(t,t+e),a=this.values_.slice(t+e);this.values_.length+=n.length-e;for(let i=0;i<n.length;i++)this.values_[t+i]=n[i];for(let i=0;i<a.length;i++)this.values_[t+n.length+i]=a[i];return l}}notifyArrayChildUpdate_(t,e,n){let a=oe(this),i=a?{observableKind:"array",object:this.proxy_,type:Dn,debugObjectName:this.atom_.name_,index:t,newValue:e,oldValue:n}:null;if(this.atom_.reportChanged(),a)re(this,i)}notifyArraySplice_(t,e,n){let a=oe(this),i=a?{observableKind:"array",object:this.proxy_,debugObjectName:this.atom_.name_,type:Im,index:t,removed:n,added:e,removedCount:n.length,addedCount:e.length}:null;if(this.atom_.reportChanged(),a)re(this,i)}get_(t){return this.atom_.reportObserved(),this.dehanceValue_(this.values_[t])}set_(t,e){let n=this.values_;if(t<n.length){be(this.atom_);let l=n[t];if(te(this)){let i=ee(this,{type:Dn,object:this.proxy_,index:t,newValue:e});if(!i)return;e=i.newValue}if(e=this.enhancer_(e,l),e!==l)n[t]=e,this.notifyArrayChildUpdate_(t,e,l)}else{let l=Array.from({length:t+1-n.length});l[l.length-1]=e,this.spliceWithArray_(n.length,0,l)}}}function oS(t,e,n="ObservableArray",l=!1){return ia(()=>{let a=new Rc(n,e,l);F_(a.values_,M,a);let i=new Proxy(a.values_,uS);if(a.proxy_=i,t&&t.length)a.spliceWithArray_(0,0,t);return i})}var Oc={clear(){return this.splice(0)},replace(t){let e=this[M];return e.spliceWithArray_(0,e.values_.length,t)},toJSON(){return this.slice()},splice(t,e,...n){let l=this[M];switch(arguments.length){case 0:return[];case 1:return l.spliceWithArray_(t);case 2:return l.spliceWithArray_(t,e)}return l.spliceWithArray_(t,e,n)},spliceWithArray(t,e,n){return this[M].spliceWithArray_(t,e,n)},push(...t){let e=this[M];return e.spliceWithArray_(e.values_.length,0,t),e.values_.length},pop(){return this.splice(Math.max(this[M].values_.length-1,0),1)[0]},shift(){return this.splice(0,1)[0]},unshift(...t){let e=this[M];return e.spliceWithArray_(0,0,t),e.values_.length},reverse(){if(x.trackingDerivation)J(37,"reverse");return this.replace(this.slice().reverse()),this},sort(){if(x.trackingDerivation)J(37,"sort");let t=this.slice();return t.sort.apply(t,arguments),this.replace(t),this},remove(t){let e=this[M],n=e.dehanceValues_(e.values_).indexOf(t);if(n>-1)return this.splice(n,1),!0;return!1}};$("at",Yt);$("concat",Yt);$("flat",Yt);$("includes",Yt);$("indexOf",Yt);$("join",Yt);$("lastIndexOf",Yt);$("slice",Yt);$("toString",Yt);$("toLocaleString",Yt);$("toSorted",Yt);$("toSpliced",Yt);$("with",Yt);$("every",se);$("filter",se);$("find",se);$("findIndex",se);$("findLast",se);$("findLastIndex",se);$("flatMap",se);$("forEach",se);$("map",se);$("some",se);$("toReversed",se);$("reduce",Jv);$("reduceRight",Jv);function $(t,e){if(typeof Array.prototype[t]==="function")Oc[t]=e(t)}function Yt(t){return function(){let e=this[M];e.atom_.reportObserved();let n=e.dehanceValues_(e.values_);return n[t].apply(n,arguments)}}function se(t){return function(e,n){let l=this[M];return l.atom_.reportObserved(),l.dehanceValues_(l.values_)[t]((i,u)=>e.call(n,i,u,this))}}function Jv(t){return function(){let e=this[M];e.atom_.reportObserved();let n=e.dehanceValues_(e.values_),l=arguments[0];return arguments[0]=(a,i,u)=>l(a,i,u,this),n[t].apply(n,arguments)}}var rS=Pn("ObservableArrayAdministration",Rc);function $v(t){return io(t)&&rS(t[M])}var sS={},Nn="add",no="delete";class Mc{constructor(t,e=Fn,n="ObservableMap"){this.enhancer_=void 0,this.name_=void 0,this[M]=sS,this.data_=void 0,this.hasMap_=void 0,this.keysAtom_=void 0,this.interceptors_=void 0,this.changeListeners_=void 0,this.dehancer=void 0,this.enhancer_=e,this.name_=n,ia(()=>{if(this.keysAtom_=cv("ObservableMap.keys()"),this.data_=new Map,this.hasMap_=new Map,t)this.merge(t)})}has_(t){return this.data_.has(t)}has(t){if(!x.trackingDerivation)return this.has_(t);let e=this.hasMap_.get(t);if(!e){let n=e=new xn(this.has_(t),uo,"ObservableMap.key?",!1);this.hasMap_.set(t,n),n.onBUOL=new Set([()=>this.hasMap_.delete(t)])}return e.get()}set(t,e){let n=this.has_(t);if(te(this)){let l=ee(this,{type:n?Dn:Nn,object:this,newValue:e,name:t});if(!l)return this;e=l.newValue}if(n)this.updateValue_(t,e);else this.addValue_(t,e);return this}delete(t){if(be(this.keysAtom_),te(this)){if(!ee(this,{type:no,object:this,name:t}))return!1}if(this.has_(t)){let n=oe(this),l=n?{observableKind:"map",debugObjectName:this.name_,type:no,object:this,oldValue:this.data_.get(t).value_,name:t}:null;if(Ye(()=>{var a;this.keysAtom_.reportChanged(),(a=this.hasMap_.get(t))==null||a.setNewValue_(!1),this.data_.get(t).setNewValue_(void 0),this.data_.delete(t)}),n)re(this,l);return!0}return!1}updateValue_(t,e){let n=this.data_.get(t);if(e=n.prepareNewValue_(e),e!==x.UNCHANGED){let a=oe(this),i=a?{observableKind:"map",debugObjectName:this.name_,type:Dn,object:this,oldValue:n.value_,name:t,newValue:e}:null;if(n.setNewValue_(e),a)re(this,i)}}addValue_(t,e){be(this.keysAtom_),Ye(()=>{var i;let u=new xn(e,this.enhancer_,"ObservableMap.key",!1);this.data_.set(t,u),e=u.value_,(i=this.hasMap_.get(t))==null||i.setNewValue_(!0),this.keysAtom_.reportChanged()});let n=!1,l=oe(this),a=l||n?{observableKind:"map",debugObjectName:this.name_,type:Nn,object:this,name:t,newValue:e}:null;if(l)re(this,a)}get(t){if(this.has(t))return this.dehanceValue_(this.data_.get(t).get());return this.dehanceValue_(void 0)}getOrInsert(t,e){if(!this.has(t))this.set(t,e);return this.get(t)}getOrInsertComputed(t,e){if(!this.has(t))this.set(t,e(t));return this.get(t)}dehanceValue_(t){if(this.dehancer!==void 0)return this.dehancer(t);return t}keys(){return this.keysAtom_.reportObserved(),this.data_.keys()}values(){let t=this,e=this.keys();return Pm({next(){let{done:n,value:l}=e.next();return{done:n,value:n?void 0:t.get(l)}}})}entries(){let t=this,e=this.keys();return Pm({next(){let{done:n,value:l}=e.next();return{done:n,value:n?void 0:[l,t.get(l)]}}})}[Symbol.iterator](){return this.entries()}forEach(t,e){for(let[n,l]of this)t.call(e,l,n,this)}merge(t){if(aa(t))t=new Map(t);return Ye(()=>{if(Ze(t))P_(t).forEach((e)=>this.set(e,t[e]));else if(Array.isArray(t))t.forEach(([e,n])=>this.set(e,n));else if(mi(t)){if(!I_(t))J(19,t);t.forEach((e,n)=>this.set(n,e))}else if(t!==null&&t!==void 0)J(20,t)}),this}clear(){Ye(()=>{Dv(()=>{for(let t of this.keys())this.delete(t)})})}replace(t){return Ye(()=>{let e=cS(t),n=new Map,l=!1;for(let a of this.data_.keys())if(!e.has(a))if(this.delete(a))l=!0;else{let u=this.data_.get(a);n.set(a,u)}for(let[a,i]of e.entries()){let u=this.data_.has(a);if(this.set(a,i),this.data_.has(a)){let o=this.data_.get(a);if(n.set(a,o),!u)l=!0}}if(!l)if(this.data_.size!==n.size)this.keysAtom_.reportChanged();else{let a=this.data_.keys(),i=n.keys(),u=a.next(),o=i.next();while(!u.done){if(u.value!==o.value){this.keysAtom_.reportChanged();break}u=a.next(),o=i.next()}}this.data_=n}),this}get size(){return this.keysAtom_.reportObserved(),this.data_.size}toString(){return"[object ObservableMap]"}toJSON(){return Array.from(this)}get[Symbol.toStringTag](){return"Map"}}var aa=Pn("ObservableMap",Mc);function Pm(t){return t[Symbol.toStringTag]="MapIterator",Pv(t)}function cS(t){if(mi(t)||aa(t))return t;else if(Array.isArray(t))return new Map(t);else if(Ze(t)){let e=new Map;for(let n in t)e.set(n,t[n]);return e}else return J(21,t)}var fS={};class Cc{constructor(t,e=Fn,n="ObservableSet"){this.name_=void 0,this[M]=fS,this.data_=new Set,this.atom_=void 0,this.changeListeners_=void 0,this.interceptors_=void 0,this.dehancer=void 0,this.enhancer_=void 0,this.name_=n,this.enhancer_=(l,a)=>e(l,a,n),ia(()=>{if(this.atom_=cv(this.name_),t)this.replace(t)})}dehanceValue_(t){if(this.dehancer!==void 0)return this.dehancer(t);return t}clear(){Ye(()=>{Dv(()=>{for(let t of this.data_.values())this.delete(t)})})}forEach(t,e){for(let n of this)t.call(e,n,n,this)}get size(){return this.atom_.reportObserved(),this.data_.size}add(t){if(be(this.atom_),te(this)){let e=ee(this,{type:Nn,object:this,newValue:t});if(!e)return this;t=e.newValue}if(!this.has(t)){Ye(()=>{this.data_.add(this.enhancer_(t,void 0)),this.atom_.reportChanged()});let e=!1,n=oe(this),l=n||e?{observableKind:"set",debugObjectName:this.name_,type:Nn,object:this,newValue:t}:null;if(n)re(this,l)}return this}delete(t){if(te(this)){if(!ee(this,{type:no,object:this,oldValue:t}))return!1}if(this.has(t)){let n=oe(this),l=n?{observableKind:"set",debugObjectName:this.name_,type:no,object:this,oldValue:t}:null;if(Ye(()=>{this.atom_.reportChanged(),this.data_.delete(t)}),n)re(this,l);return!0}return!1}has(t){return this.atom_.reportObserved(),this.data_.has(this.dehanceValue_(t))}entries(){let t=this.values();return tv({next(){let{value:e,done:n}=t.next();return!n?{value:[e,e],done:n}:{value:void 0,done:n}}})}keys(){return this.values()}values(){this.atom_.reportObserved();let t=this,e=this.data_.values();return tv({next(){let{value:n,done:l}=e.next();return!l?{value:t.dehanceValue_(n),done:l}:{value:void 0,done:l}}})}intersection(t){if(On(t)&&!Ke(t))return t.intersection(this);else return new Set(this).intersection(t)}union(t){if(On(t)&&!Ke(t))return t.union(this);else return new Set(this).union(t)}difference(t){return new Set(this).difference(t)}symmetricDifference(t){if(On(t)&&!Ke(t))return t.symmetricDifference(this);else return new Set(this).symmetricDifference(t)}isSubsetOf(t){return new Set(this).isSubsetOf(t)}isSupersetOf(t){return new Set(this).isSupersetOf(t)}isDisjointFrom(t){if(On(t)&&!Ke(t))return t.isDisjointFrom(this);else return new Set(this).isDisjointFrom(t)}replace(t){if(Ke(t))t=new Set(t);return Ye(()=>{if(Array.isArray(t))this.clear(),t.forEach((e)=>this.add(e));else if(On(t))this.clear(),t.forEach((e)=>this.add(e));else if(t!==null&&t!==void 0)J(41,t)}),this}toJSON(){return Array.from(this)}toString(){return"[object ObservableSet]"}[Symbol.iterator](){return this.values()}get[Symbol.toStringTag](){return"Set"}}var Ke=Pn("ObservableSet",Cc);function tv(t){return t[Symbol.toStringTag]="SetIterator",Pv(t)}var ev=Object.create(null),nv="remove";class Uc{constructor(t,e=new Map,n,l=m1){this.target_=void 0,this.values_=void 0,this.name_=void 0,this.defaultAnnotation_=void 0,this.keysAtom_=void 0,this.changeListeners_=void 0,this.interceptors_=void 0,this.proxy_=void 0,this.isPlainObject_=void 0,this.appliedAnnotations_=void 0,this.pendingKeys_=void 0,this.lazyComputedKeys_=void 0,this.lazyObservableKeys_=void 0,this.target_=t,this.values_=e,this.name_=n,this.defaultAnnotation_=l,this.keysAtom_=new ea("ObservableObject.keys"),this.isPlainObject_=Ze(this.target_)}getObservablePropValue_(t){var e,n;return((e=(n=this.values_.get(t))!=null?n:this.materializeLazyComputed_(t))!=null?e:this.materializeLazyObservable_(t)).get()}materializeLazyComputed_(t){var e;let n=(e=this.lazyComputedKeys_)==null?void 0:e.get(t);if(!n)return;if(this.lazyComputedKeys_.delete(t),this.lazyComputedKeys_.size===0)this.lazyComputedKeys_=void 0;let l=n();return this.values_.set(t,l),l}materializeLazyObservable_(t){var e;let n=(e=this.lazyObservableKeys_)==null?void 0:e.get(t);if(!n)return;if(this.lazyObservableKeys_.delete(t),this.lazyObservableKeys_.size===0)this.lazyObservableKeys_=void 0;let l=n();return this.values_.set(t,l),l}setObservablePropValue_(t,e){var n,l;let a=(n=(l=this.values_.get(t))!=null?l:this.materializeLazyComputed_(t))!=null?n:this.materializeLazyObservable_(t);if(a instanceof Qe)return a.set(e),!0;if(te(this)){let i=ee(this,{type:Dn,object:this.proxy_||this.target_,name:t,newValue:e});if(!i)return null;e=i.newValue}if(e=a.prepareNewValue_(e),e!==x.UNCHANGED){let i=oe(this),u=!1,o=i?{type:Dn,observableKind:"object",debugObjectName:this.name_,object:this.proxy_||this.target_,oldValue:a.value_,name:t,newValue:e}:null;if(a.setNewValue_(e),i)re(this,o)}return!0}get_(t){if(x.trackingDerivation&&!Wn(this.target_,t))this.has_(t);return this.target_[t]}set_(t,e,n=!1){if(Wn(this.target_,t))if(this.values_.has(t))return this.setObservablePropValue_(t,e);else if(n)return Reflect.set(this.target_,t,e);else return this.target_[t]=e,!0;else return this.extend_(t,{value:e,enumerable:!0,writable:!0,configurable:!0},this.defaultAnnotation_,n)}has_(t){if(!x.trackingDerivation)return t in this.target_;this.pendingKeys_||(this.pendingKeys_=new Map);let e=this.pendingKeys_.get(t);if(!e)e=new xn(t in this.target_,uo,"ObservableObject.key?",!1),this.pendingKeys_.set(t,e);return e.get()}extend_(t,e,n,l=!1){if(n===!0)n=this.defaultAnnotation_;if(n===!1)return this.defineProperty_(t,e,l);Fv(this,n,t);let a=n.extend_(this,t,e,l);if(a)Wv(this,n,t);return a}defineProperty_(t,e,n=!1){be(this.keysAtom_);try{ne();let l=this.delete_(t);if(!l)return l;if(te(this)){let a=ee(this,{object:this.proxy_||this.target_,name:t,type:Nn,newValue:e.value});if(!a)return null;let{newValue:i}=a;if(e.value!==i)e=_e({},e,{value:i})}if(n){if(!Reflect.defineProperty(this.target_,t,e))return!1}else Xe(this.target_,t,e);this.notifyPropertyAddition_(t,e.value)}finally{le()}return!0}defineObservableProperty_(t,e,n,l=!1){be(this.keysAtom_);try{ne();let a=this.delete_(t);if(!a)return a;if(te(this)){let r=ee(this,{object:this.proxy_||this.target_,name:t,type:Nn,newValue:e});if(!r)return null;e=r.newValue}let i=lv(t),u={configurable:x.safeDescriptors?this.isPlainObject_:!0,enumerable:!0,get:i.get,set:i.set};if(l){if(!Reflect.defineProperty(this.target_,t,u))return!1}else Xe(this.target_,t,u);let o=new xn(e,n,"ObservableObject.key",!1);this.values_.set(t,o),this.notifyPropertyAddition_(t,o.value_)}finally{le()}return!0}defineComputedProperty_(t,e,n=!1){be(this.keysAtom_);try{ne();let l=this.delete_(t);if(!l)return l;if(te(this)){if(!ee(this,{object:this.proxy_||this.target_,name:t,type:Nn,newValue:void 0}))return null}e.name||(e.name="ObservableObject.key"),e.context=this.proxy_||this.target_;let a=lv(t),i={configurable:x.safeDescriptors?this.isPlainObject_:!0,enumerable:!1,get:a.get,set:a.set};if(n){if(!Reflect.defineProperty(this.target_,t,i))return!1}else Xe(this.target_,t,i);this.values_.set(t,new Qe(e)),this.notifyPropertyAddition_(t,void 0)}finally{le()}return!0}delete_(t,e=!1){if(be(this.keysAtom_),!Wn(this.target_,t))return!0;if(te(this)){if(!ee(this,{object:this.proxy_||this.target_,name:t,type:nv}))return null}try{var n;ne();let a=oe(this),i=!1,u=this.values_.get(t),o=void 0;if(!u&&(a||i)){var l;o=(l=Nc(this.target_,t))==null?void 0:l.value}if(e){if(!Reflect.deleteProperty(this.target_,t))return!1}else delete this.target_[t];if(u){if(this.values_.delete(t),u instanceof xn)o=u.value_;Cv(u)}if(this.keysAtom_.reportChanged(),(n=this.pendingKeys_)==null||(n=n.get(t))==null||n.set(t in this.target_),a||i){let r={type:nv,observableKind:"object",object:this.proxy_||this.target_,debugObjectName:this.name_,oldValue:o,name:t};if(a)re(this,r)}}finally{le()}return!0}notifyPropertyAddition_(t,e){var n;let l=oe(this),a=!1;if(l){let i=l?{type:Nn,observableKind:"object",debugObjectName:this.name_,object:this.proxy_||this.target_,name:t,newValue:e}:null;if(l)re(this,i)}(n=this.pendingKeys_)==null||(n=n.get(t))==null||n.set(!0),this.keysAtom_.reportChanged()}ownKeys_(){return this.keysAtom_.reportObserved(),Pu(this.target_)}keys_(){return this.keysAtom_.reportObserved(),Object.keys(this.target_)}}function yi(t,e){var n;if(Wn(t,M))return t;let l=(n=e==null?void 0:e.name)!=null?n:"ObservableObject",a=new Uc(t,new Map,String(l),O1(e));return rv(t,M,a),t}var dS=Pn("ObservableObjectAdministration",Uc);function lv(t){return ev[t]||(ev[t]={get(){return this[M].getObservablePropValue_(t)},set(e){return this[M].setObservablePropValue_(t,e)}})}function pi(t){if(io(t))return dS(t[M]);return!1}function Wv(t,e,n){}function Fv(t,e,n){}function lo(t,e){if(typeof t==="object"&&t!==null){if($v(t)){if(e!==void 0)J(23);return t[M].atom_}if(Ke(t))return t.atom_;if(aa(t)){if(e===void 0)return t.keysAtom_;let a=t.data_.get(e)||t.hasMap_.get(e);if(!a)J(25,e,av(t));return a}if(pi(t)){var n,l;if(!e)return J(26);let a=t[M],i=(n=(l=a.values_.get(e))!=null?l:a.materializeLazyComputed_(e))!=null?n:a.materializeLazyObservable_(e);if(!i)J(27,e,av(t));return i}if(xc(t)||so(t)||eo(t))return t}else if(Pl(t)){if(eo(t[M]))return t[M]}J(28)}function Iv(t,e){if(!t)J(29);if(e!==void 0)return Iv(lo(t,e));if(xc(t)||so(t)||eo(t))return t;if(aa(t)||Ke(t))return t;if(t[M])return t[M];J(24,t)}function av(t,e){let n;if(e!==void 0)n=lo(t,e);else if(ta(t))return t.name;else if(pi(t)||aa(t)||Ke(t))n=Iv(t);else n=lo(t);return n.name_}function ia(t){let e=la(),n=!0;ne();try{return t()}finally{le(),An(e)}}var IS=ao.toString;var iv,hS=((iv=globalThis.Iterator)==null?void 0:iv.prototype)||{};function Pv(t){return t[Symbol.iterator]=pS,_e(Object.create(hS),t)}function pS(){return this}var _t=ce(Ee(),1),tg;if(!_t.useState||!_t.useSyncExternalStore)throw Error("mobx-react-lite requires React 18 or later");if(!((zc==null||(tg=zc())==null?void 0:tg.version)>=7))throw Error("mobx-react-lite requires mobx at least version 7 to be available");var mS=1e4,vS=1e4;class og{constructor(t){this.finalize=void 0,this.registrations=new Map,this.sweepTimeout=void 0,this.sweep=(e=mS)=>{clearTimeout(this.sweepTimeout),this.sweepTimeout=void 0;let n=Date.now();if(this.registrations.forEach((l,a)=>{if(n-l.registeredAt>=e)this.finalize(l.value),this.registrations.delete(a)}),this.registrations.size>0)this.scheduleSweep()},this.finalizeAllImmediately=()=>{this.sweep(0)},this.finalize=t}register(t,e,n){this.registrations.set(n,{value:e,registeredAt:Date.now()}),this.scheduleSweep()}unregister(t){this.registrations.delete(t)}scheduleSweep(){if(this.sweepTimeout===void 0)this.sweepTimeout=setTimeout(this.sweep,vS)}}var gS=typeof FinalizationRegistry<"u"?FinalizationRegistry:og,Vc=new gS((t)=>{var e;(e=t.reaction)==null||e.dispose(),t.reaction=null}),yS=!1;function rg(){return yS}function eg(t){t.reaction=new gi(`observer${t.name}`,()=>{t.stateVersion=Symbol(),t.onStoreChange==null||t.onStoreChange()})}function sg(t,e="observed"){if(rg())return t();let n=_t.default.useRef(null);if(!n.current){let u={reaction:null,onStoreChange:null,stateVersion:Symbol(),name:e,subscribe(o){if(Vc.unregister(u),u.onStoreChange=o,!u.reaction)eg(u),u.stateVersion=Symbol();return()=>{var r;u.onStoreChange=null,(r=u.reaction)==null||r.dispose(),u.reaction=null}},getSnapshot(){return u.stateVersion}};n.current=u}let l=n.current;if(!l.reaction)eg(l),Vc.register(n,l,l);_t.default.useDebugValue(l.reaction,Xv),_t.default.useSyncExternalStore(l.subscribe,l.getSnapshot,l.getSnapshot);let a,i;if(l.reaction.track(()=>{try{a=t()}catch(u){i=u}}),i)throw i;return a}var ng,lg,cg=typeof Symbol==="function"&&Symbol.for,bS=(ng=(lg=Object.getOwnPropertyDescriptor(()=>{},"name"))==null?void 0:lg.configurable)!=null?ng:!1,ag=cg?Symbol.for("react.forward_ref"):typeof _t.forwardRef==="function"&&_t.forwardRef((t)=>null).$$typeof,ig=cg?Symbol.for("react.memo"):typeof _t.memo==="function"&&_t.memo((t)=>null).$$typeof;function j(t){if(ig&&t.$$typeof===ig)throw Error("[mobx-react-lite] You are trying to use `observer` on a function component wrapped in either another `observer` or `React.memo`. The observer already applies 'React.memo' for you.");if(rg())return t;let e=!1,n=t,l=t.displayName||t.name;if(ag&&t.$$typeof===ag){if(e=!0,n=t.render,typeof n!=="function")throw Error("[mobx-react-lite] `render` property of ForwardRef was not a function")}let a=(i,u)=>sg(()=>n(i,u),l);if(a.displayName=t.displayName,bS)Object.defineProperty(a,"name",{value:t.name,writable:!0,configurable:!0});if(e)a=_t.forwardRef(a);return a=_t.memo(a),SS(t,a),a}var _S={$$typeof:!0,render:!0,compare:!0,type:!0,displayName:!0};function SS(t,e){Object.keys(t).forEach((n)=>{if(!_S[n])Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(t,n))})}function ES({children:t,render:e}){if(t&&e)console.error("MobX Observer: Do not use children and render in the same time in `Observer`");let n=t||e;if(typeof n!=="function")return null;return sg(n)}ES.displayName="Observer";function fo(t,e){return _t.useState(()=>bt(t(),e,{autoBind:!0}))[0]}var ug,eE=(ug=Vc.finalizeAllImmediately)!=null?ug:()=>{};var Sg=ce(Ee(),1);async function tl(t,e){let n=await fetch(t,e),l=await n.json().catch(()=>null);if(!n.ok||l==null)throw Error(l?.error??`http ${n.status} on ${t}`);return l}function fg(){return tl("/drafts")}function dg(t){return tl(`/drafts/${encodeURIComponent(t.module)}/${encodeURIComponent(t.draft)}`)}function hg(t){return tl(`/generate/${encodeURIComponent(t.module)}/${encodeURIComponent(t.draft)}`,{method:"POST",headers:{"content-type":"application/json"},body:JSON.stringify(t.payload)})}function bi(t,e={}){return tl(`/drafts/${encodeURIComponent(t.module)}/${encodeURIComponent(t.draft)}`,{method:"PUT",headers:{"content-type":"application/json"},body:JSON.stringify(t.values),keepalive:e.keepalive===!0})}function pg(t){return tl(`/run/${encodeURIComponent(t.module)}`)}function mg(t){return`/run/${encodeURIComponent(t.module)}/preview?t=${t.tick}`}function vg(t){return tl(`/lora-info/${encodeURIComponent(t.host)}/${encodeURIComponent(t.name)}`)}function gg(t){return`/lora-preview/${encodeURIComponent(t.host)}/${encodeURIComponent(t.name)}`}async function yg(t){let e=new Uint8Array(await t.file.arrayBuffer()),n="";for(let l=0;l<e.length;l+=32768)n+=String.fromCharCode(...e.subarray(l,l+32768));return tl("/upload",{method:"POST",headers:{"content-type":"application/json"},body:JSON.stringify({name:t.file.name,dataBase64:btoa(n)})})}async function bg(t){let e=await fetch(t);if(!e.ok)throw Error(`fetch failed (http ${e.status})`);let n=await e.blob(),l=n.type==="image/png"?n:await OS(n);await navigator.clipboard.write([new ClipboardItem({"image/png":l})])}async function OS(t){let e=await createImageBitmap(t),n=document.createElement("canvas");n.width=e.width,n.height=e.height;let l=n.getContext("2d");if(l==null)throw Error("canvas 2d context unavailable");return l.drawImage(e,0,0),await new Promise((a,i)=>{n.toBlob((u)=>{if(u==null)i(Error("png encode failed"));else a(u)},"image/png")})}var NS=Symbol.for("react.transitional.element"),xS=Symbol.for("react.fragment");function _g(t,e,n){var l=null;if(n!==void 0&&(l=""+n),e.key!==void 0&&(l=""+e.key),"key"in e){n={};for(var a in e)a!=="key"&&(n[a]=e[a])}else n=e;return e=n.ref,{$$typeof:NS,type:t,key:l,ref:e!==void 0?e:null,props:n}}var ua=xS,m=_g,S=_g;var AS=typeof navigator<"u"&&navigator.clipboard!=null;function DS(){return fo(()=>({copyNote:null,lightbox:null,setCopyNote(t,e){this.copyNote={url:t,text:e}},openLightbox(t){this.lightbox=t},closeLightbox(){this.lightbox=null}}))}var TS=j(function(e){let n=e.local.lightbox;if(Sg.useEffect(()=>{if(n==null)return;let a=(i)=>{if(i.key==="Escape")e.local.closeLightbox()};return window.addEventListener("keydown",a),()=>window.removeEventListener("keydown",a)},[n,e.local]),n==null)return null;let l=()=>{bg(n.url).then(()=>e.local.setCopyNote(n.url,"copied ✓")).catch((a)=>e.local.setCopyNote(n.url,`copy failed: ${a instanceof Error?a.message:String(a)}`))};return m("div",{className:"modal-overlay",onClick:()=>e.local.closeLightbox(),children:S("div",{className:"lightbox",onClick:(a)=>a.stopPropagation(),children:[m("img",{src:n.url,alt:n.title}),S("div",{className:"lightbox-bar",children:[m("span",{className:"hint",title:n.title,children:n.title}),AS?m("button",{type:"button",onClick:l,children:"copy"}):null,m("a",{href:n.url,target:"_blank",rel:"noreferrer",children:"open ↗"}),n.promptId!=null?m("button",{type:"button",title:"remove this result",onClick:()=>{if(n.promptId!=null)e.st.run.remove(n.promptId);e.local.closeLightbox()},children:"delete"}):null,e.local.copyNote?.url===n.url?m("span",{className:"hint",children:e.local.copyNote.text}):null,m("button",{type:"button",title:"close (esc)",onClick:()=>e.local.closeLightbox(),children:"✕"})]})]})})}),zS=j(function(e){let n=e.st.run.runningModule;if(!e.st.run.isRunning||n==null)return null;let l=e.st.run.progressPercent,a=mg({module:n,tick:e.st.run.previewTick});return S("div",{className:"run-card running",children:[S("div",{className:"meta",children:[S("span",{children:["generating ",n,"…"]}),m("span",{children:l!=null?`${Math.round(l)}%`:""})]}),m("div",{className:"progress-track",children:m("div",{className:"progress-fill",style:{width:`${l??0}%`}})}),e.st.run.hasPreview?m("div",{className:"imgs",children:m("button",{type:"button",className:"img-button",onClick:()=>e.local.openLightbox({url:a,title:"latent preview",promptId:null}),children:m("img",{src:a,alt:"latent preview"})})}):null]})}),Eg=j(function(e){let n=DS();if(e.st.run.results.length===0&&!e.st.run.isRunning)return null;return S("div",{className:"gallery",children:[m(zS,{st:e.st,local:n}),e.st.run.results.length>0?S("div",{className:"gallery-head",children:[S("span",{children:[e.st.run.results.length," result",e.st.run.results.length===1?"":"s"]}),m("button",{type:"button",className:"link",onClick:()=>e.st.run.clear(),children:"clear all"})]}):null,e.st.run.results.map((l)=>S("div",{className:"run-card",children:[S("div",{className:"meta",children:[S("span",{children:[l.at," · ",l.module,"/",l.draft," · ",(l.durationMs/1000).toFixed(1),"s",Object.entries(l.seeds).map(([a,i])=>` · ${a}: ${i}`)]}),m("button",{type:"button",className:"link",title:"remove this result",onClick:()=>e.st.run.remove(l.promptId),children:"✕"})]}),S("div",{className:"imgs",children:[l.images.map((a)=>a.url!=null?m("button",{type:"button",className:"img-button",title:a.filename,onClick:()=>{if(a.url!=null)n.openLightbox({url:a.url,title:a.filename,promptId:l.promptId})},children:m("img",{src:a.url,alt:a.filename})},a.filename):S("div",{className:"noimg",children:[a.filename," (not saved locally — no preview)"]},a.filename)),l.images.length===0?m("div",{className:"noimg",children:"no image outputs"}):null]})]},l.promptId)),m(TS,{st:e.st,local:n})]})});var Og=j(function(e){return S("div",{className:"sidebar",children:[e.st.modules.map((n)=>S("div",{children:[S("div",{className:"side-module",children:[m("span",{className:"name",children:n.module}),m("span",{className:"host",children:n.host})]}),n.drafts.map((l)=>{let a=e.st.form?.moduleKey===n.module&&e.st.form?.draft===l;return m("button",{type:"button",className:a?"side-draft sel":"side-draft",onClick:()=>void e.st.select({module:n.module,draft:l}),children:l},l)})]},n.module)),Object.keys(e.st.loadErrors).length>0?S("div",{className:"side-errors",children:[m("div",{children:"failed to load:"}),Object.entries(e.st.loadErrors).map(([n,l])=>S("div",{children:[m("div",{className:"file",children:n}),m("div",{className:"msg",children:l})]},n))]}):null]})});var Yg=ce(Ee(),1);var Ng=ce(Ee(),1);var wS=["off","low","medium","high"],RS=j(function(e){let n=e.e.visibleModels;return S("div",{children:[m("div",{className:"section-title",children:"openrouter · the key stays in this browser"}),S("div",{className:"enh-row",children:[m("input",{type:"password",placeholder:"sk-or-v1-… (localStorage only)",value:e.e.apiKey,onChange:(l)=>e.e.setApiKey(l.target.value),style:{flex:1,minWidth:200}}),m("button",{type:"button",onClick:()=>void e.e.loadModels(),disabled:e.e.modelsState==="loading",children:e.e.modelsState==="loading"?"loading…":"load models"})]}),S("div",{className:"enh-row",children:[n.length>0?S("select",{value:e.e.model,onChange:(l)=>e.e.setModel(l.target.value),style:{flex:1},children:[n.some((l)=>l.id===e.e.model)?null:S("option",{value:e.e.model,children:[e.e.model," (not in the list)"]}),n.map((l)=>m("option",{value:l.id,children:l.id},l.id))]}):m("input",{type:"text",placeholder:"model id, e.g. anthropic/claude-sonnet-5",value:e.e.model,onChange:(l)=>e.e.setModel(l.target.value),style:{flex:1}}),S("label",{className:"row-inline",title:"only models that support reasoning",children:[m("input",{type:"checkbox",checked:e.e.thinkingOnly,onChange:()=>e.e.toggleThinkingOnly()}),m("span",{className:"hint",children:"thinking only"})]}),S("label",{className:"row-inline",title:"reasoning effort sent to the model",children:[m("span",{className:"hint",children:"effort"}),m("select",{value:e.e.effort,onChange:(l)=>e.e.setEffort(l.target.value),children:wS.map((l)=>m("option",{value:l,children:l},l))})]})]}),e.e.modelsError!==""?S("div",{className:"error",children:["\uD83D\uDD34 ",e.e.modelsError]}):null]})}),MS=j(function(e){let n=e.e.preset;if(n==null)return null;let l=()=>{let i=window.prompt("rename this master prompt",n.name);if(i!=null)e.e.renamePreset(i)},a=()=>{let i=window.prompt("name the new master prompt","refine-<model>-prompt");if(i!=null)e.e.addPreset(i)};return S("div",{children:[m("div",{className:"section-title",children:"master prompt · one per image model"}),S("div",{className:"enh-row",children:[m("select",{value:n.id,onChange:(i)=>e.e.selectPreset(i.target.value),style:{flex:1},children:e.e.presets.map((i)=>m("option",{value:i.id,children:i.name},i.id))}),m("button",{type:"button",onClick:a,children:"new"}),m("button",{type:"button",onClick:()=>e.e.duplicatePreset(),children:"duplicate"}),m("button",{type:"button",onClick:l,children:"rename"}),m("button",{type:"button",onClick:()=>e.e.deletePreset(),title:"delete this master prompt",children:"✕"}),m("button",{type:"button",className:"link",onClick:()=>e.e.restoreDefaults(),title:"re-add the shipped ones",children:"restore defaults"})]}),m("textarea",{rows:8,value:n.text,onChange:(i)=>e.e.setPresetText(i.target.value)})]})}),CS=j(function(e){let n=e.e;Ng.useEffect(()=>{let a=(i)=>{if(i.key==="Escape")n.close();if(i.key==="Enter"&&(i.metaKey||i.ctrlKey))i.preventDefault(),n.run()};return window.addEventListener("keydown",a),()=>window.removeEventListener("keydown",a)},[n]);let l=n.phase==="running";return m("div",{className:"modal-overlay",onClick:()=>n.close(),children:S("div",{className:"modal",onClick:(a)=>a.stopPropagation(),children:[S("div",{className:"modal-head",children:[m("b",{style:{flex:1},children:"✨ enhance prompt"}),m("button",{type:"button",onClick:()=>n.close(),children:"✕"})]}),S("div",{className:"modal-body",children:[m(RS,{e:n}),m(MS,{e:n}),m("div",{className:"section-title",children:"prompt"}),S("div",{className:"enh-cols",children:[S("div",{children:[m("div",{className:"hint",children:"yours (edit before refining, the var is untouched)"}),m("textarea",{rows:8,value:n.original,onChange:(a)=>n.setOriginal(a.target.value)})]}),S("div",{children:[m("div",{className:"hint",children:l?"rewriting…":"rewritten (editable before apply)"}),m("textarea",{rows:8,value:n.result,placeholder:"hit enhance",onChange:(a)=>n.setResult(a.target.value)})]})]}),n.thinking!==""?S("div",{children:[m("div",{className:"section-title",children:"thinking"}),m("div",{className:"enh-think",children:n.thinking})]}):null,n.error!==""?S("div",{className:"error",children:["\uD83D\uDD34 ",n.error]}):null]}),S("div",{className:"modal-foot",children:[l?m("button",{type:"button",onClick:()=>n.cancel(),children:"stop"}):m("button",{type:"button",className:"primary",onClick:()=>n.run(),title:"⌘⏎ / ctrl+⏎",children:"enhance"}),m("button",{type:"button",onClick:()=>n.apply(),disabled:n.result.trim()==="",children:"apply to prompt"}),m("span",{className:"hint",style:{flex:1},children:l?`${n.result.length} chars streamed`:"nothing is written until you apply"}),m("button",{type:"button",className:"link",onClick:()=>n.close(),children:"cancel"})]})]})})}),xg=j(function(e){let n=e.st.enhancer;return S(ua,{children:[m("button",{type:"button",className:"link",title:"rewrite this prompt with an llm",onClick:()=>n.openFor({v:e.v,module:e.module}),children:"✨ enhance"}),n.target===e.v?m(CS,{e:n}):null]})});var Ag=j(function(e){let n=typeof e.v.value==="string"?e.v.value:"",l=Math.min(12,Math.max(4,n.split(`
10
- `).length+1));return S("div",{children:[m("textarea",{rows:l,value:n,onChange:(a)=>e.v.set(a.target.value)}),S("div",{className:"row-inline",children:[m("span",{className:"hint",children:'// line = comment · "- " line = negative prompt'}),m(xg,{v:e.v,st:e.st,module:e.module})]})]})}),Dg=j(function(e){return m("input",{type:"text",value:typeof e.v.value==="string"?e.v.value:"",onChange:(n)=>e.v.set(n.target.value)})}),Tg=j(function(e){let n=e.v.desc.kind==="int",l=typeof e.v.value==="number"?e.v.value:0,a=e.v.desc.min,i=e.v.desc.max,u=(o)=>{let r=n?parseInt(o,10):parseFloat(o);if(Number.isFinite(r))e.v.set(r)};return S("div",{className:"row-inline",children:[m("input",{type:"number",value:l,step:n?1:"any",min:a,max:i,onChange:(o)=>u(o.target.value)}),a!=null&&i!=null?m("input",{type:"range",style:{flex:1,minWidth:120},value:l,min:a,max:i,step:n?1:(i-a)/200,onChange:(o)=>u(o.target.value)}):null,a!=null||i!=null?m("span",{className:"hint",children:`${a??"-∞"} … ${i??"∞"}`}):null]})}),zg=j(function(e){return S("label",{className:"row-inline",style:{cursor:"pointer"},children:[m("input",{type:"checkbox",checked:e.v.value===!0,onChange:(n)=>e.v.set(n.target.checked)}),m("span",{className:"hint",children:e.v.value===!0?"on":"off"})]})}),wg=j(function(e){let n=e.v.desc.choices??[],l=typeof e.v.value==="string"?e.v.value:"";return S("select",{value:l,onChange:(a)=>e.v.set(a.target.value),children:[n.includes(l)?null:m("option",{value:l,disabled:!0,children:l===""?"(unset)":`${l} (not on this host)`}),n.map((a)=>m("option",{value:a,children:a},a))]})});var Rg=ce(Ee(),1);var Mg=j(function(e){let n=Rg.useRef(null),l=typeof e.v.value==="string"?e.v.value:"",a=/^https?:\/\//.test(l)?l:e.v.uploadedUrl,i=e.v.desc.extensions??[],u=async(o)=>{if(o==null)return;try{let r=await yg({file:o});e.v.set(r.path),e.v.setUploadedUrl(r.url)}catch(r){alert(`upload failed: ${r instanceof Error?r.message:String(r)}`)}};return S("div",{children:[S("div",{className:"row-inline",children:[m("input",{type:"text",style:{flex:1},placeholder:"local path or http(s) url",value:l,onChange:(o)=>{e.v.set(o.target.value),e.v.setUploadedUrl(null)}}),m("button",{type:"button",onClick:()=>n.current?.click(),children:"upload…"}),l!==""?m("button",{type:"button",title:"clear the image",onClick:()=>{e.v.set(""),e.v.setUploadedUrl(null)},children:"✕"}):null,m("input",{ref:n,type:"file",accept:i.map((o)=>`.${o}`).join(","),style:{display:"none"},onChange:(o)=>{u(o.target.files?.[0]),o.target.value=""}})]}),a!=null&&a!==""?m("div",{className:"img-preview",children:m("img",{src:a,alt:l})}):null]})});var Lc=ce(Ee(),1);function Cg(t){let e={};for(let n of t)if(n.kind!=="seed")e[n.name]=n.value;return e}function Bc(t){if(typeof t==="number"&&Number.isFinite(t))return{mode:"=",value:t};if(t!=null&&typeof t==="object"){let e=t;return{mode:typeof e.mode==="string"?e.mode:"=",value:typeof e.value==="number"&&Number.isFinite(e.value)?e.value:0}}return{mode:"=",value:0}}function qc(t){if(t!=null&&typeof t==="object"){let e=t;if(typeof e.width==="number"&&typeof e.height==="number")return{width:e.width,height:e.height}}return{width:1024,height:1024}}function US(t,e){if(t==null||typeof t!=="object"||Array.isArray(t))return{};let n=new Set(e),l={};for(let[a,i]of Object.entries(t))if(n.has(a)&&jc(i))l[a]=i;return l}function Ug(t,e){if(t.kind==="seed")return Bc(e??t.default);if(t.kind==="size")return qc(e??t.default);if(t.kind==="loras")return US(e??t.default,t.options??[]);return e??t.default}function Vg(){return Math.floor(Math.random()*4294967296)}function jc(t){return t!=null&&t!==!1}function ho(t){if(typeof t==="number"&&Number.isFinite(t))return{model:t,clip:t};if(Array.isArray(t)&&typeof t[0]==="number"&&typeof t[1]==="number")return{model:t[0],clip:t[1]};return{model:1,clip:1}}function Bg(t,e,n,l){let a={...t};if(!n)delete a[e];else{let i=l??ho(t[e]);a[e]=[i.model,i.clip]}return a}function qg(t,e,n){return{...t,[e]:[n.model,n.clip]}}var Hc=60;function VS(t){if(t!=null&&typeof t==="object"&&!Array.isArray(t))return t;return{}}var jg=j(function(e){let n=fo(()=>({open:!1,filter:"",info:new Map,previewFailed:new Set,prevStrength:new Map,paused:new Set,setOpen(y){this.open=y},setFilter(y){this.filter=y},noteInfo(y,D){this.info.set(y,D)},notePreviewFailed(y){this.previewFailed.add(y)},notePrevStrength(y,D){this.prevStrength.set(y,D)},setPaused(y,D){if(D)this.paused.add(y);else this.paused.delete(y)}})),l=VS(e.v.value),a=e.v.desc.options??[],i=e.v.desc.optionLabels??{},u=(y)=>i[y]??y,o=(y)=>jc(l[y]),r=(y)=>o(y)||n.paused.has(y),s=a.filter(r),h=e.st.showLoraImages,g=e.st.showLoraTitles,d=(y,D)=>{n.setPaused(y,!1);let ct={...l};if(D==null)delete ct[y];else ct[y]=D;e.v.set(ct)},v=(y,D)=>{if(!D)n.notePrevStrength(y,ho(l[y]));n.setPaused(y,!D),e.v.set(Bg(l,y,D,D?n.prevStrength.get(y):void 0))},E=(y,D)=>{if(!o(y)){n.notePrevStrength(y,D);return}e.v.set(qg(l,y,D))},A=(y)=>{let D=o(y)?ho(l[y]):n.prevStrength.get(y)??{model:1,clip:1};return S(ua,{children:[m("span",{className:"st-label",children:"m"}),m("input",{type:"number",step:0.05,value:D.model,onChange:(ct)=>{let Tn=parseFloat(ct.target.value);if(Number.isFinite(Tn))E(y,{model:Tn,clip:D.clip})}}),m("span",{className:"st-label",children:"c"}),m("input",{type:"number",step:0.05,value:D.clip,onChange:(ct)=>{let Tn=parseFloat(ct.target.value);if(Number.isFinite(Tn))E(y,{model:D.model,clip:Tn})}})]})},z=n.open,f=e.host,c=s.join(`
11
- `);Lc.useEffect(()=>{if(!z)return;for(let y of c.split(`
12
- `)){if(y===""||n.info.has(y))continue;n.noteInfo(y,"loading"),vg({host:f,name:y}).then((D)=>n.noteInfo(y,D)).catch(()=>n.noteInfo(y,"error"))}},[z,c,f,n]),Lc.useEffect(()=>{if(!z)return;let y=(D)=>{if(D.key==="Escape")n.setOpen(!1)};return window.addEventListener("keydown",y),()=>window.removeEventListener("keydown",y)},[z,n]);let p=n.filter.toLowerCase(),b=(y)=>y.toLowerCase().includes(p)||u(y).toLowerCase().includes(p),O=a.filter(b),C=O.filter((y)=>!r(y)).slice(0,Hc),N=(y)=>{if(!h)return null;return n.previewFailed.has(y)?m("div",{className:"lora-thumb none",children:"no preview"}):m("img",{className:"lora-thumb",loading:"lazy",src:gg({host:e.host,name:y}),alt:u(y),onError:()=>n.notePreviewFailed(y)},y)},w=S(ua,{children:[m("button",{type:"button",className:h?"mode sel":"mode",title:h?"hide lora images":"show lora images",onClick:()=>e.st.toggleLoraImages(),children:"\uD83D\uDDBC"}),m("button",{type:"button",className:g?"mode sel":"mode",title:g?"hide lora titles":"show lora titles",onClick:()=>e.st.toggleLoraTitles(),children:"\uD83C\uDFF7"})]});return S("div",{children:[S("div",{className:"row-inline",children:[!h&&!g?S("span",{className:"hint",children:[s.length," lora",s.length===1?"":"s"," in the palette"]}):s.map((y)=>S("span",{className:`${h?"lora-chip card":"lora-chip"}${o(y)?"":" off"}`,children:[S("button",{type:"button",className:"lora-toggle",title:o(y)?`${y}
13
- click to pause`:`${y}
14
- paused — click to resume`,onClick:()=>v(y,!o(y)),children:[N(y),g?m("span",{className:"chip-title",children:u(y)}):null,m("span",{className:"chip-state",children:o(y)?"● on":"⏸ paused"})]}),S("span",{className:"chip-controls",children:[A(y),m("button",{type:"button",title:"remove from the palette (the popup adds it back)",onClick:()=>d(y,null),children:"✕"})]})]},y)),m("button",{type:"button",onClick:()=>n.setOpen(!0),children:s.length===0?`add loras… (${a.length})`:"+ add…"}),w]}),n.open?m("div",{className:"modal-overlay",onClick:()=>n.setOpen(!1),children:S("div",{className:"modal",onClick:(y)=>y.stopPropagation(),children:[S("div",{className:"modal-head",children:[m("input",{type:"text",autoFocus:!0,placeholder:`filter ${a.length} loras`,value:n.filter,onChange:(y)=>n.setFilter(y.target.value)}),w,m("button",{type:"button",title:"close (esc)",onClick:()=>n.setOpen(!1),children:"✕"})]}),S("div",{className:"modal-body",children:[s.length>0?S("div",{className:"lora-active-section",children:[S("div",{className:"section-title",children:["your palette (",s.length,")"]}),s.filter(b).map((y)=>{let D=n.info.get(y);return S("div",{className:o(y)?"lora-active-row":"lora-active-row off",children:[N(y),S("div",{className:"lora-active-text",children:[m("div",{className:"lora-label",title:y,children:g?u(y):"···"}),typeof D==="object"&&D.triggerWords.length>0?m("div",{className:"hint",children:D.triggerWords.join(", ")}):m("div",{className:"hint",children:y})]}),m("input",{type:"checkbox",checked:o(y),title:o(y)?"pause (stays in the palette)":"resume",onChange:(ct)=>v(y,ct.target.checked)}),A(y),m("button",{type:"button",title:"remove from the list",onClick:()=>d(y,null),children:"✕"})]},y)})]}):null,m("div",{className:"section-title",children:"all loras — tap to add to the palette"}),m("div",{className:"lora-grid",children:C.map((y)=>S("button",{type:"button",className:"lora-card",title:y,onClick:()=>d(y,[1,1]),children:[N(y),m("div",{className:"lora-label",children:g?u(y):y.slice(0,2)+"···"})]},y))}),O.length-s.filter(b).length>Hc?S("div",{className:"loras-more",children:["… ",O.length-s.filter(b).length-Hc," more — refine the filter"]}):null,O.length===0?S("div",{className:"loras-more",children:["no lora matches '",n.filter,"'"]}):null]})]})}):null]})});var Hg=[{mode:"=",label:"fixed",hint:"this exact seed, every run"},{mode:"+",label:"+1",hint:"increments after each run"},{mode:"-",label:"-1",hint:"decrements after each run"},{mode:"?",label:"random",hint:"a fresh random seed each run"}],Lg=j(function(e){let n=Bc(e.v.value),l=(a)=>{if(Number.isFinite(a))e.v.set({mode:n.mode,value:Math.max(0,Math.floor(a))})};return S("div",{children:[S("div",{className:"row-inline",children:[Hg.map((a)=>m("button",{type:"button",className:n.mode===a.mode?"mode sel":"mode",title:a.hint,onClick:()=>e.v.set({mode:a.mode,value:n.value}),children:a.label},a.mode)),m("input",{type:"number",min:0,value:n.value,onChange:(a)=>l(parseInt(a.target.value,10))}),m("button",{type:"button",title:"roll a random seed now",onClick:()=>l(Vg()),children:"\uD83C\uDFB2"})]}),m("div",{className:"hint",children:Hg.find((a)=>a.mode===n.mode)?.hint??n.mode})]})});var Gg=j(function(e){let n=qc(e.v.value),l=e.v.desc.presets??[],a=l.find((u)=>u.width===n.width&&u.height===n.height),i=(u)=>{let o=u.width??n.width,r=u.height??n.height;if(Number.isFinite(o)&&Number.isFinite(r)&&o>0&&r>0)e.v.set({width:Math.floor(o),height:Math.floor(r)})};return S("div",{className:"row-inline",children:[S("select",{value:a?.label??"__custom__",onChange:(u)=>{let o=l.find((r)=>r.label===u.target.value);if(o!=null)e.v.set({width:o.width,height:o.height})},children:[a==null?m("option",{value:"__custom__",children:"custom"}):null,l.map((u)=>S("option",{value:u.label,children:[u.label," (",u.width,"×",u.height,")"]},u.label))]}),m("input",{type:"number",min:1,value:n.width,onChange:(u)=>i({width:Number(u.target.value)})}),"×",m("input",{type:"number",min:1,value:n.height,onChange:(u)=>i({height:Number(u.target.value)})}),m("button",{type:"button",title:"swap width and height",onClick:()=>e.v.set({width:n.height,height:n.width}),children:"⇄"})]})});var BS=j(function(e){switch(e.v.desc.kind){case"prompt":return m(Ag,{v:e.v,st:e.st,module:e.module});case"text":return m(Dg,{v:e.v});case"int":case"float":return m(Tg,{v:e.v});case"seed":return m(Lg,{v:e.v});case"toggle":return m(zg,{v:e.v});case"choice":return m(wg,{v:e.v});case"loras":return m(jg,{v:e.v,host:e.host,st:e.st});case"size":return m(Gg,{v:e.v});case"image":return m(Mg,{v:e.v});default:return S("div",{className:"hint",children:["unsupported var kind '",e.v.desc.kind,"' — use the json api"]})}}),qS=j(function(e){return S("div",{className:"var-row",children:[S("div",{className:"var-label",children:[e.v.desc.label??e.v.name,e.v.dirty?m("button",{type:"button",className:"dirty-dot",title:"changed this session — click to restore the loaded value (autosaves)",onClick:()=>e.v.revert(),children:"●"}):null,m("span",{className:"kind",children:e.v.desc.kind})]}),m("div",{className:"var-control",children:m(BS,{v:e.v,host:e.host,st:e.st,module:e.module})})]})}),jS=j(function(e){let n=e.st.run.queue;if(n.length===0)return null;return S("div",{className:"queue",children:[S("div",{className:"queue-head",children:[S("span",{children:["queue · ",n.length," prompt",n.length===1?"":"s"]}),e.st.run.pendingCount>0?S("button",{type:"button",className:"link",onClick:()=>e.st.run.clearQueue(),children:["clear ",e.st.run.pendingCount," pending"]}):null]}),n.map((l,a)=>S("div",{className:"queue-row",children:[m("span",{className:"queue-ix",children:a+1}),S("span",{className:"queue-name",children:[l.module,"/",l.draft]}),l.sent?m("span",{className:"hint",children:"on the host — past cancelling"}):m("button",{type:"button",title:"drop this queued prompt",onClick:()=>e.st.run.removeQueued(l.id),children:"✕"})]},l.id))]})}),Kg=j(function(e){let n=e.st.form;if(Yg.useEffect(()=>{let a=(i)=>{if(e.st.enhancer.isOpen)return;if(i.key==="Enter"&&(i.metaKey||i.ctrlKey))i.preventDefault(),e.st.generate()};return window.addEventListener("keydown",a),()=>window.removeEventListener("keydown",a)},[e.st]),n==null)return null;let l=()=>{let a=window.prompt("duplicate draft as…",`${n.draft} copy`);if(a!=null)e.st.duplicateDraft(a)};return S("div",{children:[S("div",{className:"form-head",children:[S("h2",{children:[m("b",{children:n.moduleKey})," / ",n.draft]}),S("span",{className:"hint",children:[n.saveState==="saving"?"saving…":null,n.saveState==="saved"?"autosaved":null,n.saveState==="error"?`\uD83D\uDD34 save failed: ${n.saveError}`:null]}),m("button",{type:"button",className:"link",title:"save these values as a new draft",onClick:l,children:"duplicate…"})]}),n.vars.map((a)=>m(qS,{v:a,host:n.host,st:e.st,module:n.moduleKey},`${n.draft}/${a.name}`)),S("div",{className:"runbar",children:[m("button",{type:"button",className:e.st.run.isRunning?"primary pulse":"primary",title:"⌘⏎ / ctrl+⏎ — click again to queue another",onClick:()=>e.st.generate(),children:e.st.run.isRunning?e.st.run.progressPercent!=null?`generating… ${Math.round(e.st.run.progressPercent)}%`:"generating…":"generate"}),m("span",{className:"status",children:n.dirtyCount===0?"draft values":`${n.dirtyCount} var${n.dirtyCount>1?"s":""} changed this session`}),n.dirtyCount>0?m("button",{type:"button",className:"link",onClick:()=>n.revertAll(),children:"revert all"}):null,e.st.run.error!=null?S("span",{className:"error",children:["\uD83D\uDD34 ",e.st.run.error]}):null]}),m(jS,{st:e.st})]})});var Xg=j(function(e){if(e.st.phase==="loading")return m("div",{className:"center",children:"loading…"});if(e.st.phase==="error")return m("div",{className:"center",children:S("div",{className:"error",children:["\uD83D\uDD34 ",e.st.bootError]})});return S("div",{className:"app",children:[S("div",{className:"topbar",children:[m("button",{type:"button",className:"burger",title:"toggle the workflow menu",onClick:()=>e.st.toggleSidebar(),children:"☰"}),m("h1",{children:"comfy-ts serve"}),S("span",{className:"dim",children:[e.st.modules.length," workflow",e.st.modules.length===1?"":"s"," · drafts are the base, edits override per run"]})]}),S("div",{className:"cols",children:[e.st.sidebarOpen?m("div",{className:"backdrop",onClick:()=>e.st.toggleSidebar()}):null,e.st.sidebarOpen?m(Og,{st:e.st}):null,S("div",{className:"main",children:[e.st.formError!=null?S("div",{className:"center error",children:["\uD83D\uDD34 ",e.st.formError]}):null,e.st.formLoading&&e.st.form==null?m("div",{className:"center",children:"loading draft…"}):null,e.st.modules.length===0?m("div",{className:"center",children:"no workflow modules loaded"}):null,S("div",{className:"work",children:[m("div",{className:"form-col",children:m(Kg,{st:e.st})}),m("div",{className:"results-col",children:m(Eg,{st:e.st})})]})]})]})]})});function oa(t){return typeof t==="object"&&t!==null&&!Array.isArray(t)?t:{}}function el(t){return typeof t==="string"?t:""}function HS(t){let e=oa(t).data;if(!Array.isArray(e))return[];let n=[];for(let l of e){let a=oa(l),i=el(a.id);if(i==="")continue;let u=Array.isArray(a.supported_parameters)?a.supported_parameters:[];n.push({id:i,name:el(a.name)===""?i:el(a.name),reasoning:u.includes("reasoning")})}return n.sort((l,a)=>l.id.localeCompare(a.id)),n}async function Qg(t,e){let n=await t.text().catch(()=>"");return Error(`openrouter ${e} failed: http ${t.status} ${n.slice(0,300)}`)}async function Zg(t){if(t.key.trim()==="")throw Error("no openrouter api key — paste one in the enhancer settings");let e=await fetch("https://openrouter.ai/api/v1/models",{headers:{Authorization:`Bearer ${t.key.trim()}`}});if(!e.ok)throw await Qg(e,"model list");return HS(await e.json())}function LS(t){return{model:t.model,stream:!0,messages:[{role:"system",content:t.system},{role:"user",content:t.user}],...t.effort==="off"?{}:{reasoning:{effort:t.effort}}}}function GS(t){let e=t.split(`
15
- `),n=e.pop()??"",l=[];for(let a of e){let i=a.trim();if(i===""||i.startsWith(":"))continue;if(i.startsWith("data:"))l.push(i.slice(5).trim())}return{events:l,rest:n}}function YS(t){if(t===""||t==="[DONE]")return null;let e;try{e=JSON.parse(t)}catch{return null}let n=oa(e),l=oa(n.error);if(el(l.message)!=="")throw Error(`openrouter stream error: ${el(l.message)}`);let a=n.choices;if(!Array.isArray(a))return null;let i=oa(oa(a[0]).delta),u=el(i.content),o=el(i.reasoning);if(u===""&&o==="")return null;return{content:u,reasoning:o}}async function kg(t){if(t.key.trim()==="")throw Error("no openrouter api key — paste one in the enhancer settings");if(t.model.trim()==="")throw Error("no model selected");let e=await fetch("https://openrouter.ai/api/v1/chat/completions",{method:"POST",headers:{Authorization:`Bearer ${t.key.trim()}`,"content-type":"application/json"},body:JSON.stringify(LS(t)),signal:t.signal});if(!e.ok)throw await Qg(e,"refine");let n=e.body?.getReader();if(n==null)throw Error("openrouter refine failed: the response carried no stream");let l=new TextDecoder,a={content:"",reasoning:""},i="";for(;;){let u=await n.read();if(u.done)break;i+=l.decode(u.value,{stream:!0});let o=GS(i);i=o.rest;for(let r of o.events){let s=YS(r);if(s==null)continue;a.content+=s.content,a.reasoning+=s.reasoning,t.onDelta(s)}}if(a.content.trim()==="")throw Error("openrouter refine returned no text — try another model");return a}var Wg="comfy-ts-serve-enhancer",KS="anthropic/claude-sonnet-5",XS=`You rewrite image prompts for krea2 turbo, a distilled 8 step text to image model whose text encoder reads flowing natural language, not tag soup, and which is steered by adjectives rather than by negatives.
16
-
17
- Rewrite the user's prompt into ONE dense paragraph someone could picture with their eyes closed:
18
- - keep every noun and every named subject the user wrote, they are the point
19
- - add what is missing to make it fun to look at: lighting, palette, material, texture, camera angle, composition, mood
20
- - prefer concrete visual nouns over praise, never write "masterpiece", "8k", "highly detailed", "award winning"
21
- - stay under about 80 words, no lists, no headings, no quotes around the result
22
- - keep any "// " comment line and any "- " negative line from the input verbatim, each on its own line
23
-
24
- Answer with the rewritten prompt and nothing else: no preamble, no explanation.`;function mo(){return[{id:"refine-krea2-prompt",name:"refine-krea2-prompt",text:XS}]}function po(t,e){return typeof t==="string"&&t!==""?t:e}function Fg(t){return t==="off"||t==="low"||t==="medium"||t==="high"}function Jg(t){let e=typeof t==="object"&&t!==null?t:{},n=[];if(Array.isArray(e.presets))for(let u of e.presets){let o=typeof u==="object"&&u!==null?u:{},r=po(o.id,"");if(r==="")continue;n.push({id:r,name:po(o.name,r),text:typeof o.text==="string"?o.text:""})}let l=n.length>0?n:mo(),a={};if(typeof e.presetByModule==="object"&&e.presetByModule!==null){for(let[u,o]of Object.entries(e.presetByModule))if(typeof o==="string")a[u]=o}let i=po(e.presetId,"");return{apiKey:typeof e.apiKey==="string"?e.apiKey:"",model:po(e.model,KS),effort:Fg(e.effort)?e.effort:"medium",thinkingOnly:e.thinkingOnly!==!1,presets:l,presetId:l.some((u)=>u.id===i)?i:l[0]?.id??"",presetByModule:a}}function $g(t,e){if(!e.includes(t))return t;for(let n=2;n<1000;n++){let l=`${t} ${n}`;if(!e.includes(l))return l}return`${t} ${e.length+1}`}function QS(){return`mp-${Math.random().toString(36).slice(2,10)}`}function ZS(){try{return Jg(JSON.parse(localStorage.getItem(Wg)??"{}"))}catch{return Jg({})}}class Gc{apiKey;model;effort;thinkingOnly;presets;presetId;presetByModule;models=[];modelsState="idle";modelsError="";target=null;targetModule="";original="";result="";thinking="";phase="idle";error="";abort=null;constructor(){let t=ZS();this.apiKey=t.apiKey,this.model=t.model,this.effort=t.effort,this.thinkingOnly=t.thinkingOnly,this.presets=t.presets,this.presetId=t.presetId,this.presetByModule=t.presetByModule,ke(this,{abort:!1})}get preset(){return this.presets.find((t)=>t.id===this.presetId)??this.presets[0]??null}get isOpen(){return this.target!=null}get visibleModels(){return this.thinkingOnly?this.models.filter((t)=>t.reasoning):this.models}openFor(t){this.target=t.v,this.targetModule=t.module,this.original=typeof t.v.value==="string"?t.v.value:"",this.result="",this.thinking="",this.error="",this.phase="idle";let e=this.presetByModule[t.module];if(e!=null&&this.presets.some((n)=>n.id===e))this.presetId=e}close(){this.cancel(),this.target=null,this.targetModule=""}settingsJSON(){return{apiKey:this.apiKey,model:this.model,effort:this.effort,thinkingOnly:this.thinkingOnly,presets:this.presets,presetId:this.presetId,presetByModule:this.presetByModule}}persist(){try{localStorage.setItem(Wg,JSON.stringify(this.settingsJSON()))}catch{}}setApiKey(t){this.apiKey=t.trim(),this.persist()}setModel(t){this.model=t,this.persist()}setEffort(t){if(!Fg(t))return;this.effort=t,this.persist()}setResult(t){this.result=t}setOriginal(t){this.original=t}toggleThinkingOnly(){this.thinkingOnly=!this.thinkingOnly,this.persist()}selectPreset(t){if(!this.presets.some((e)=>e.id===t))return;if(this.presetId=t,this.targetModule!=="")this.presetByModule[this.targetModule]=t;this.persist()}replacePreset(t){this.presets=this.presets.map((e)=>e.id===t.id?t:e),this.persist()}setPresetText(t){let e=this.preset;if(e!=null)this.replacePreset({...e,text:t})}renamePreset(t){let e=this.preset,n=t.trim();if(e==null||n==="")return;this.replacePreset({...e,name:$g(n,this.presets.filter((l)=>l.id!==e.id).map((l)=>l.name))})}addPreset(t,e=""){let n=t.trim();if(n==="")return;let l={id:QS(),name:$g(n,this.presets.map((a)=>a.name)),text:e};this.presets=[...this.presets,l],this.selectPreset(l.id)}duplicatePreset(){let t=this.preset;if(t!=null)this.addPreset(`${t.name} copy`,t.text)}deletePreset(){let t=this.preset;if(t==null)return;let e=this.presets.filter((n)=>n.id!==t.id);this.presets=e.length>0?e:mo(),this.presetId=this.presets[0]?.id??"";for(let[n,l]of Object.entries(this.presetByModule))if(l===t.id)delete this.presetByModule[n];this.persist()}restoreDefaults(){let t=this.presets.filter((e)=>!mo().some((n)=>n.id===e.id));this.presets=[...mo(),...t],this.presetId=this.presets[0]?.id??"",this.persist()}async loadModels(){G(()=>{this.modelsState="loading",this.modelsError=""});try{let t=await Zg({key:this.apiKey});G(()=>{this.models=t,this.modelsState="idle"})}catch(t){G(()=>{this.modelsState="error",this.modelsError=t instanceof Error?t.message:String(t)})}}cancel(){if(this.abort?.abort(),this.abort=null,this.phase==="running")this.phase=this.result===""?"idle":"done"}run(){this.runNow()}async runNow(){let t=this.preset;if(t==null||this.phase==="running")return;let e=new AbortController;this.abort=e,G(()=>{this.phase="running",this.error="",this.result="",this.thinking=""});try{await kg({key:this.apiKey,model:this.model,system:t.text,user:this.original,effort:this.effort,signal:e.signal,onDelta:(n)=>G(()=>{this.result+=n.content,this.thinking+=n.reasoning})}),G(()=>{this.phase="done"})}catch(n){let l=e.signal.aborted;G(()=>{if(this.phase=l?this.result===""?"idle":"done":"error",!l)this.error=n instanceof Error?n.message:String(n)})}finally{if(this.abort===e)this.abort=null}}apply(){let t=this.result.trim();if(this.target==null||t==="")return;this.target.set(t),this.close()}}class Ig{name;desc;initial;value;dirty=!1;uploadedUrl=null;constructor(t,e,n){this.name=t;this.desc=e;this.initial=n;this.value=n,ke(this,{value:na,name:!1,desc:!1,initial:!1})}set(t){this.value=t,this.dirty=!0}setUploadedUrl(t){this.uploadedUrl=t}revert(){this.value=this.initial,this.dirty=!1,this.uploadedUrl=null}snapshot(){return{name:this.name,value:this.value}}}class Yc{moduleKey;draft;vars;host;saveState="saved";saveError=null;disposers=[];saveChain=Promise.resolve(!0);lastSaved;constructor(t,e,n,l){this.moduleKey=t;this.draft=e;this.host=n.host,this.vars=Object.entries(n.vars).map(([a,i])=>new Ig(a,i,Ug(i,l[a]))),this.lastSaved=JSON.stringify(Object.fromEntries(this.vars.map((a)=>[a.name,l[a.name]]))),ke(this,{vars:!1,moduleKey:!1,draft:!1,host:!1,disposers:!1,saveChain:!1,lastSaved:!1}),this.disposers.push(Yv(()=>JSON.stringify(this.valuesJSON()),()=>void this.save(),{delay:500}))}dispose(){for(let t of this.disposers)t();if(this.disposers=[],JSON.stringify(this.valuesJSON())!==this.lastSaved)this.save()}flushKeepalive(){let t=JSON.stringify(this.valuesJSON());if(t===this.lastSaved)return;bi({module:this.moduleKey,draft:this.draft,values:JSON.parse(t)},{keepalive:!0}).then(()=>G(()=>{this.lastSaved=t,this.saveState="saved"}),(e)=>G(()=>{this.saveState="error",this.saveError=e instanceof Error?e.message:String(e)}))}valuesJSON(){return Object.fromEntries(this.vars.map((t)=>[t.name,t.value]))}queuePayload(){return Cg(this.vars.map((t)=>({name:t.name,kind:t.desc.kind,value:t.value})))}get dirtyCount(){return this.vars.filter((t)=>t.dirty).length}save(){let t=JSON.stringify(this.valuesJSON());if(t===this.lastSaved)return G(()=>{this.saveState="saved",this.saveError=null}),Promise.resolve(!0);return G(()=>{this.saveState="saving"}),this.saveChain=this.saveChain.then(async()=>{try{return await bi({module:this.moduleKey,draft:this.draft,values:JSON.parse(t)}),G(()=>{this.lastSaved=t,this.saveState="saved",this.saveError=null}),!0}catch(e){return G(()=>{this.saveState="error",this.saveError=e instanceof Error?e.message:String(e)}),!1}}),this.saveChain}revertAll(){for(let t of this.vars)t.revert()}}function kS(t){return new Promise((e)=>setTimeout(e,t))}class Kc{queue=[];error=null;results=[];progressPercent=null;hasPreview=!1;previewTick=0;draining=!1;nextId=0;pollGen=0;constructor(){ke(this,{queue:vi,results:vi})}get isRunning(){return this.queue.some((t)=>t.sent)}get runningModule(){return this.queue.find((t)=>t.sent)?.module??null}get pendingCount(){return this.queue.filter((t)=>!t.sent).length}enqueue(t){if(this.queue=[...this.queue,{id:`q${this.nextId++}`,...t,sent:!1}],this.error=null,!this.draining)this.drain()}removeQueued(t){this.queue=this.queue.filter((e)=>e.id!==t||e.sent)}clearQueue(){this.queue=this.queue.filter((t)=>t.sent)}remove(t){this.results=this.results.filter((e)=>e.promptId!==t)}clear(){this.results=[]}async drain(){if(this.draining)return;this.draining=!0;try{while(!0){let t=this.queue.find((n)=>!n.sent);if(t==null)return;G(()=>{this.queue=this.queue.map((n)=>n.id===t.id?{...n,sent:!0}:n),this.progressPercent=null,this.hasPreview=!1});let e=++this.pollGen;this.poll(t.module,e);try{let n=await hg(t);G(()=>{this.results=[{...n,at:new Date().toLocaleTimeString()},...this.results].slice(0,20)})}catch(n){G(()=>{this.error=n instanceof Error?n.message:String(n),this.queue=this.queue.filter((l)=>l.sent&&l.id!==t.id)})}finally{this.pollGen++,G(()=>{this.queue=this.queue.filter((n)=>n.id!==t.id),this.progressPercent=null,this.hasPreview=!1})}}}finally{this.draining=!1}}async poll(t,e){while(e===this.pollGen){if(await kS(700),e!==this.pollGen)return;try{let n=await pg({module:t});G(()=>{if(e!==this.pollGen)return;this.progressPercent=n.percent,this.hasPreview=n.hasPreview,this.previewTick=n.previewSeq??0})}catch{}}}}var Pg="comfy-ts-serve-ui";function Xc(){try{return JSON.parse(localStorage.getItem(Pg)??"{}")??{}}catch{return{}}}function Qc(){return window.matchMedia("(max-width: 800px)").matches}class Zc{phase="loading";bootError="";modules=[];loadErrors={};form=null;formLoading=!1;formError=null;sidebarOpen;showLoraImages;showLoraTitles;run;enhancer;constructor(){this.run=new Kc,this.enhancer=new Gc;let t=Xc();this.sidebarOpen=t.sidebar??!Qc(),this.showLoraImages=t.loraImages??!0,this.showLoraTitles=t.loraTitles??!0,ke(this,{run:!1,enhancer:!1,form:na,modules:vi}),window.addEventListener("beforeunload",()=>this.form?.flushKeepalive()),document.addEventListener("visibilitychange",()=>{if(document.visibilityState==="hidden")this.form?.flushKeepalive()}),this.boot()}toggleSidebar(){this.sidebarOpen=!this.sidebarOpen,this.persist()}toggleLoraImages(){this.showLoraImages=!this.showLoraImages,this.persist()}toggleLoraTitles(){this.showLoraTitles=!this.showLoraTitles,this.persist()}persist(){try{let t=Xc();localStorage.setItem(Pg,JSON.stringify({...t,...this.form!=null?{module:this.form.moduleKey,draft:this.form.draft}:{},sidebar:this.sidebarOpen,loraImages:this.showLoraImages,loraTitles:this.showLoraTitles}))}catch{}}moduleByKey(t){return this.modules.find((e)=>e.module===t)??null}async boot(){try{let t=await fg();G(()=>{this.modules=t.workflows,this.loadErrors=t.loadErrors??{},this.phase="ready"});let e=Xc(),n=(e.module!=null?this.moduleByKey(e.module):null)??this.modules[0];if(n==null)return;let l=e.draft!=null&&n.drafts.includes(e.draft)?e.draft:"default";await this.select({module:n.module,draft:l})}catch(t){G(()=>{this.phase="error",this.bootError=t instanceof Error?t.message:String(t)})}}selectToken=0;async select(t){let e=this.moduleByKey(t.module);if(e==null)return;if(this.form?.moduleKey===t.module&&this.form.draft===t.draft){G(()=>{if(Qc())this.sidebarOpen=!1});return}let n=++this.selectToken;G(()=>{if(this.enhancer.close(),this.formLoading=!0,this.formError=null,Qc())this.sidebarOpen=!1});let l=this.form;if(l!=null)l.dispose(),await l.save();try{let a=await dg(t);G(()=>{if(n!==this.selectToken)return;this.form=new Yc(t.module,t.draft,e,a.values??{}),this.persist()})}catch(a){G(()=>{if(n!==this.selectToken)return;this.formError=a instanceof Error?a.message:String(a)})}finally{G(()=>{if(n===this.selectToken)this.formLoading=!1})}}generate(){this.generateNow()}async generateNow(){let t=this.form;if(t==null)return;let e=t.queuePayload();if(!await t.save())return;this.run.enqueue({module:t.moduleKey,draft:t.draft,payload:e})}async duplicateDraft(t){let e=this.form,n=t.trim();if(e==null||n==="")return;if(this.moduleByKey(e.moduleKey)?.drafts.includes(n)===!0&&!window.confirm(`draft '${n}' already exists — overwrite it?`))return;try{let a=await bi({module:e.moduleKey,draft:n,values:e.valuesJSON()});G(()=>{this.modules=this.modules.map((i)=>i.module===e.moduleKey?{...i,drafts:a.drafts}:i)}),await this.select({module:e.moduleKey,draft:n})}catch(a){G(()=>{this.formError=a instanceof Error?a.message:String(a)})}}}var ty=`
3
+ `+fs+e+ad}function hs(e,t){if(!e||ds)return"";ds=!0;var n=Error.prepareStackTrace;Error.prepareStackTrace=void 0;try{var a={DetermineComponentFrameRoot:function(){try{if(t){var b=function(){throw Error()};if(Object.defineProperty(b.prototype,"props",{set:function(){throw Error()}}),typeof Reflect==="object"&&Reflect.construct){try{Reflect.construct(b,[])}catch(g){var h=g}Reflect.construct(e,[],b)}else{try{b.call()}catch(g){h=g}e.call(b.prototype)}}else{try{throw Error()}catch(g){h=g}(b=e())&&typeof b.catch==="function"&&b.catch(function(){})}}catch(g){if(g&&h&&typeof g.stack==="string")return[g.stack,h.stack]}return[null,null]}};a.DetermineComponentFrameRoot.displayName="DetermineComponentFrameRoot";var i=Object.getOwnPropertyDescriptor(a.DetermineComponentFrameRoot,"name");i&&i.configurable&&Object.defineProperty(a.DetermineComponentFrameRoot,"name",{value:"DetermineComponentFrameRoot"});var l=a.DetermineComponentFrameRoot(),o=l[0],r=l[1];if(o&&r){var s=o.split(`
4
+ `),c=r.split(`
5
+ `);for(i=a=0;a<s.length&&!s[a].includes("DetermineComponentFrameRoot");)a++;for(;i<c.length&&!c[i].includes("DetermineComponentFrameRoot");)i++;if(a===s.length||i===c.length)for(a=s.length-1,i=c.length-1;1<=a&&0<=i&&s[a]!==c[i];)i--;for(;1<=a&&0<=i;a--,i--)if(s[a]!==c[i]){if(a!==1||i!==1)do if(a--,i--,0>i||s[a]!==c[i]){var m=`
6
+ `+s[a].replace(" at new "," at ");return e.displayName&&m.includes("<anonymous>")&&(m=m.replace("<anonymous>",e.displayName)),m}while(1<=a&&0<=i);break}}}finally{ds=!1,Error.prepareStackTrace=n}return(n=e?e.displayName||e.name:"")?qn(n):""}function O0(e,t){switch(e.tag){case 26:case 27:case 5:return qn(e.type);case 16:return qn("Lazy");case 13:return e.child!==t&&t!==null?qn("Suspense Fallback"):qn("Suspense");case 19:return qn("SuspenseList");case 0:case 15:return hs(e.type,!1);case 11:return hs(e.type.render,!1);case 1:return hs(e.type,!0);case 31:return qn("Activity");default:return""}}function id(e){try{var t="",n=null;do t+=O0(e,n),n=e,e=e.return;while(e);return t}catch(a){return`
7
+ Error generating stack: `+a.message+`
8
+ `+a.stack}}function fn(e){if(typeof R0==="function"&&M0(e),je&&typeof je.setStrictMode==="function")try{je.setStrictMode(pl,e)}catch(t){}}function k0(e){return e>>>=0,e===0?32:31-(C0(e)/U0|0)|0}function Gn(e){var t=e&42;if(t!==0)return t;switch(e&-e){case 1:return 1;case 2:return 2;case 4:return 4;case 8:return 8;case 16:return 16;case 32:return 32;case 64:return 64;case 128:return 128;case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:return e&261888;case 262144:case 524288:case 1048576:case 2097152:return e&3932160;case 4194304:case 8388608:case 16777216:case 33554432:return e&62914560;case 67108864:return 67108864;case 134217728:return 134217728;case 268435456:return 268435456;case 536870912:return 536870912;case 1073741824:return 0;default:return e}}function Fo(e,t,n){var a=e.pendingLanes;if(a===0)return 0;var i=0,l=e.suspendedLanes,o=e.pingedLanes;e=e.warmLanes;var r=a&134217727;return r!==0?(a=r&~l,a!==0?i=Gn(a):(o&=r,o!==0?i=Gn(o):n||(n=r&~e,n!==0&&(i=Gn(n))))):(r=a&~l,r!==0?i=Gn(r):o!==0?i=Gn(o):n||(n=a&~e,n!==0&&(i=Gn(n)))),i===0?0:t!==0&&t!==i&&(t&l)===0&&(l=i&-i,n=t&-t,l>=n||l===32&&(n&4194048)!==0)?t:i}function ml(e,t){return(e.pendingLanes&~(e.suspendedLanes&~e.pingedLanes)&t)===0}function V0(e,t){switch(e){case 1:case 2:case 4:case 8:case 64:return t+250;case 16:case 32:case 128:case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:return t+5000;case 4194304:case 8388608:case 16777216:case 33554432:return-1;case 67108864:case 134217728:case 268435456:case 536870912:case 1073741824:return-1;default:return-1}}function Uh(){var e=Ql;return Ql<<=1,(Ql&62914560)===0&&(Ql=4194304),e}function ms(e){for(var t=[],n=0;31>n;n++)t.push(e);return t}function vl(e,t){e.pendingLanes|=t,t!==268435456&&(e.suspendedLanes=0,e.pingedLanes=0,e.warmLanes=0)}function L0(e,t,n,a,i,l){var o=e.pendingLanes;e.pendingLanes=n,e.suspendedLanes=0,e.pingedLanes=0,e.warmLanes=0,e.expiredLanes&=n,e.entangledLanes&=n,e.errorRecoveryDisabledLanes&=n,e.shellSuspendCounter=0;var{entanglements:r,expirationTimes:s,hiddenUpdates:c}=e;for(n=o&~n;0<n;){var m=31-qe(n),b=1<<m;r[m]=0,s[m]=-1;var h=c[m];if(h!==null)for(c[m]=null,m=0;m<h.length;m++){var g=h[m];g!==null&&(g.lane&=-536870913)}n&=~b}a!==0&&kh(e,a,0),l!==0&&i===0&&e.tag!==0&&(e.suspendedLanes|=l&~(o&~t))}function kh(e,t,n){e.pendingLanes|=t,e.suspendedLanes&=~t;var a=31-qe(t);e.entangledLanes|=t,e.entanglements[a]=e.entanglements[a]|1073741824|n&261930}function Vh(e,t){var n=e.entangledLanes|=t;for(e=e.entanglements;n;){var a=31-qe(n),i=1<<a;i&t|e[a]&t&&(e[a]|=t),n&=~i}}function Lh(e,t){var n=t&-t;return n=(n&42)!==0?1:Yu(n),(n&(e.suspendedLanes|t))!==0?0:n}function Yu(e){switch(e){case 2:e=1;break;case 8:e=4;break;case 32:e=16;break;case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:case 4194304:case 8388608:case 16777216:case 33554432:e=128;break;case 268435456:e=134217728;break;default:e=0}return e}function Ku(e){return e&=-e,2<e?8<e?(e&134217727)!==0?32:268435456:8:2}function Bh(){var e=X.p;if(e!==0)return e;return e=window.event,e===void 0?32:rv(e.type)}function ld(e,t){var n=X.p;try{return X.p=e,t()}finally{X.p=n}}function Xu(e){delete e[_e],delete e[Ce],delete e[Ws],delete e[B0],delete e[H0]}function Oa(e){var t=e[_e];if(t)return t;for(var n=e.parentNode;n;){if(t=n[ei]||n[_e]){if(n=t.alternate,t.child!==null||n!==null&&n.child!==null)for(e=dh(e);e!==null;){if(n=e[_e])return n;e=dh(e)}return t}e=n,n=e.parentNode}return null}function ti(e){if(e=e[_e]||e[ei]){var t=e.tag;if(t===5||t===6||t===13||t===31||t===26||t===27||t===3)return e}return null}function Ci(e){var t=e.tag;if(t===5||t===26||t===27||t===6)return e.stateNode;throw Error(S(33))}function Va(e){var t=e[od];return t||(t=e[od]={hoistableStyles:new Map,hoistableScripts:new Map}),t}function ge(e){e[gl]=!0}function na(e,t){Ka(e,t),Ka(e+"Capture",t)}function Ka(e,t){jh[e]=t;for(e=0;e<t.length;e++)Hh.add(t[e])}function q0(e){if(Fs.call(sd,e))return!0;if(Fs.call(rd,e))return!1;if(j0.test(e))return sd[e]=!0;return rd[e]=!0,!1}function ao(e,t,n){if(q0(t))if(n===null)e.removeAttribute(t);else{switch(typeof n){case"undefined":case"function":case"symbol":e.removeAttribute(t);return;case"boolean":var a=t.toLowerCase().slice(0,5);if(a!=="data-"&&a!=="aria-"){e.removeAttribute(t);return}}e.setAttribute(t,""+n)}}function Zl(e,t,n){if(n===null)e.removeAttribute(t);else{switch(typeof n){case"undefined":case"function":case"symbol":case"boolean":e.removeAttribute(t);return}e.setAttribute(t,""+n)}}function zt(e,t,n,a){if(a===null)e.removeAttribute(n);else{switch(typeof a){case"undefined":case"function":case"symbol":case"boolean":e.removeAttribute(n);return}e.setAttributeNS(t,n,""+a)}}function We(e){switch(typeof e){case"bigint":case"boolean":case"number":case"string":case"undefined":return e;case"object":return e;default:return""}}function qh(e){var t=e.type;return(e=e.nodeName)&&e.toLowerCase()==="input"&&(t==="checkbox"||t==="radio")}function G0(e,t,n){var a=Object.getOwnPropertyDescriptor(e.constructor.prototype,t);if(!e.hasOwnProperty(t)&&typeof a<"u"&&typeof a.get==="function"&&typeof a.set==="function"){var{get:i,set:l}=a;return Object.defineProperty(e,t,{configurable:!0,get:function(){return i.call(this)},set:function(o){n=""+o,l.call(this,o)}}),Object.defineProperty(e,t,{enumerable:a.enumerable}),{getValue:function(){return n},setValue:function(o){n=""+o},stopTracking:function(){e._valueTracker=null,delete e[t]}}}}function Is(e){if(!e._valueTracker){var t=qh(e)?"checked":"value";e._valueTracker=G0(e,t,""+e[t])}}function Gh(e){if(!e)return!1;var t=e._valueTracker;if(!t)return!0;var n=t.getValue(),a="";return e&&(a=qh(e)?e.checked?"true":"false":e.value),e=a,e!==n?(t.setValue(e),!0):!1}function wo(e){if(e=e||(typeof document<"u"?document:void 0),typeof e>"u")return null;try{return e.activeElement||e.body}catch(t){return e.body}}function et(e){return e.replace(Y0,function(t){return"\\"+t.charCodeAt(0).toString(16)+" "})}function Ps(e,t,n,a,i,l,o,r){if(e.name="",o!=null&&typeof o!=="function"&&typeof o!=="symbol"&&typeof o!=="boolean"?e.type=o:e.removeAttribute("type"),t!=null)if(o==="number"){if(t===0&&e.value===""||e.value!=t)e.value=""+We(t)}else e.value!==""+We(t)&&(e.value=""+We(t));else o!=="submit"&&o!=="reset"||e.removeAttribute("value");t!=null?eu(e,o,We(t)):n!=null?eu(e,o,We(n)):a!=null&&e.removeAttribute("value"),i==null&&l!=null&&(e.defaultChecked=!!l),i!=null&&(e.checked=i&&typeof i!=="function"&&typeof i!=="symbol"),r!=null&&typeof r!=="function"&&typeof r!=="symbol"&&typeof r!=="boolean"?e.name=""+We(r):e.removeAttribute("name")}function Yh(e,t,n,a,i,l,o,r){if(l!=null&&typeof l!=="function"&&typeof l!=="symbol"&&typeof l!=="boolean"&&(e.type=l),t!=null||n!=null){if(!(l!=="submit"&&l!=="reset"||t!==void 0&&t!==null)){Is(e);return}n=n!=null?""+We(n):"",t=t!=null?""+We(t):n,r||t===e.value||(e.value=t),e.defaultValue=t}a=a!=null?a:i,a=typeof a!=="function"&&typeof a!=="symbol"&&!!a,e.checked=r?e.checked:!!a,e.defaultChecked=!!a,o!=null&&typeof o!=="function"&&typeof o!=="symbol"&&typeof o!=="boolean"&&(e.name=o),Is(e)}function eu(e,t,n){t==="number"&&wo(e.ownerDocument)===e||e.defaultValue===""+n||(e.defaultValue=""+n)}function La(e,t,n,a){if(e=e.options,t){t={};for(var i=0;i<n.length;i++)t["$"+n[i]]=!0;for(n=0;n<e.length;n++)i=t.hasOwnProperty("$"+e[n].value),e[n].selected!==i&&(e[n].selected=i),i&&a&&(e[n].defaultSelected=!0)}else{n=""+We(n),t=null;for(i=0;i<e.length;i++){if(e[i].value===n){e[i].selected=!0,a&&(e[i].defaultSelected=!0);return}t!==null||e[i].disabled||(t=e[i])}t!==null&&(t.selected=!0)}}function Kh(e,t,n){if(t!=null&&(t=""+We(t),t!==e.value&&(e.value=t),n==null)){e.defaultValue!==t&&(e.defaultValue=t);return}e.defaultValue=n!=null?""+We(n):""}function Xh(e,t,n,a){if(t==null){if(a!=null){if(n!=null)throw Error(S(92));if(Mi(a)){if(1<a.length)throw Error(S(93));a=a[0]}n=a}n==null&&(n=""),t=n}n=We(t),e.defaultValue=n,a=e.textContent,a===n&&a!==""&&a!==null&&(e.value=a),Is(e)}function Xa(e,t){if(t){var n=e.firstChild;if(n&&n===e.lastChild&&n.nodeType===3){n.nodeValue=t;return}}e.textContent=t}function ud(e,t,n){var a=t.indexOf("--")===0;n==null||typeof n==="boolean"||n===""?a?e.setProperty(t,""):t==="float"?e.cssFloat="":e[t]="":a?e.setProperty(t,n):typeof n!=="number"||n===0||K0.has(t)?t==="float"?e.cssFloat=n:e[t]=(""+n).trim():e[t]=n+"px"}function Qh(e,t,n){if(t!=null&&typeof t!=="object")throw Error(S(62));if(e=e.style,n!=null){for(var a in n)!n.hasOwnProperty(a)||t!=null&&t.hasOwnProperty(a)||(a.indexOf("--")===0?e.setProperty(a,""):a==="float"?e.cssFloat="":e[a]="");for(var i in t)a=t[i],t.hasOwnProperty(i)&&n[i]!==a&&ud(e,i,a)}else for(var l in t)t.hasOwnProperty(l)&&ud(e,l,t[l])}function Qu(e){if(e.indexOf("-")===-1)return!1;switch(e){case"annotation-xml":case"color-profile":case"font-face":case"font-face-src":case"font-face-uri":case"font-face-format":case"font-face-name":case"missing-glyph":return!1;default:return!0}}function io(e){return Q0.test(""+e)?"javascript:throw new Error('React has blocked a javascript: URL as a security precaution.')":e}function Bt(){}function Zu(e){return e=e.target||e.srcElement||window,e.correspondingUseElement&&(e=e.correspondingUseElement),e.nodeType===3?e.parentNode:e}function cd(e){var t=ti(e);if(t&&(e=t.stateNode)){var n=e[Ce]||null;e:switch(e=t.stateNode,t.type){case"input":if(Ps(e,n.value,n.defaultValue,n.defaultValue,n.checked,n.defaultChecked,n.type,n.name),t=n.name,n.type==="radio"&&t!=null){for(n=e;n.parentNode;)n=n.parentNode;n=n.querySelectorAll('input[name="'+et(""+t)+'"][type="radio"]');for(t=0;t<n.length;t++){var a=n[t];if(a!==e&&a.form===e.form){var i=a[Ce]||null;if(!i)throw Error(S(90));Ps(a,i.value,i.defaultValue,i.defaultValue,i.checked,i.defaultChecked,i.type,i.name)}}for(t=0;t<n.length;t++)a=n[t],a.form===e.form&&Gh(a)}break e;case"textarea":Kh(e,n.value,n.defaultValue);break e;case"select":t=n.value,t!=null&&La(e,!!n.multiple,t,!1)}}}function Zh(e,t,n){if(vs)return e(t,n);vs=!0;try{var a=e(t);return a}finally{if(vs=!1,Aa!==null||Ba!==null){if(sr(),Aa&&(t=Aa,e=Ba,Ba=Aa=null,cd(t),e))for(t=0;t<e.length;t++)cd(e[t])}}}function el(e,t){var n=e.stateNode;if(n===null)return null;var a=n[Ce]||null;if(a===null)return null;n=a[t];e:switch(t){case"onClick":case"onClickCapture":case"onDoubleClick":case"onDoubleClickCapture":case"onMouseDown":case"onMouseDownCapture":case"onMouseMove":case"onMouseMoveCapture":case"onMouseUp":case"onMouseUpCapture":case"onMouseEnter":(a=!a.disabled)||(e=e.type,a=!(e==="button"||e==="input"||e==="select"||e==="textarea")),e=!a;break e;default:e=!1}if(e)return null;if(n&&typeof n!=="function")throw Error(S(231,t,typeof n));return n}function $h(){if(lo)return lo;var e,t=$u,n=t.length,a,i="value"in dn?dn.value:dn.textContent,l=i.length;for(e=0;e<n&&t[e]===i[e];e++);var o=n-e;for(a=1;a<=o&&t[n-a]===i[l-a];a++);return lo=i.slice(e,1<a?1-a:void 0)}function oo(e){var t=e.keyCode;return"charCode"in e?(e=e.charCode,e===0&&t===13&&(e=13)):e=t,e===10&&(e=13),32<=e||e===13?e:0}function $l(){return!0}function fd(){return!1}function Ue(e){function t(n,a,i,l,o){this._reactName=n,this._targetInst=i,this.type=a,this.nativeEvent=l,this.target=o,this.currentTarget=null;for(var r in e)e.hasOwnProperty(r)&&(n=e[r],this[r]=n?n(l):l[r]);return this.isDefaultPrevented=(l.defaultPrevented!=null?l.defaultPrevented:l.returnValue===!1)?$l:fd,this.isPropagationStopped=fd,this}return ae(t.prototype,{preventDefault:function(){this.defaultPrevented=!0;var n=this.nativeEvent;n&&(n.preventDefault?n.preventDefault():typeof n.returnValue!=="unknown"&&(n.returnValue=!1),this.isDefaultPrevented=$l)},stopPropagation:function(){var n=this.nativeEvent;n&&(n.stopPropagation?n.stopPropagation():typeof n.cancelBubble!=="unknown"&&(n.cancelBubble=!0),this.isPropagationStopped=$l)},persist:function(){},isPersistent:$l}),t}function l1(e){var t=this.nativeEvent;return t.getModifierState?t.getModifierState(e):(e=i1[e])?!!t[e]:!1}function Ju(){return l1}function Fh(e,t){switch(e){case"keyup":return g1.indexOf(t.keyCode)!==-1;case"keydown":return t.keyCode!==229;case"keypress":case"mousedown":case"focusout":return!0;default:return!1}}function Wh(e){return e=e.detail,typeof e==="object"&&"data"in e?e.data:null}function y1(e,t){switch(e){case"compositionend":return Wh(t);case"keypress":if(t.which!==32)return null;return vd=!0,md;case"textInput":return e=t.data,e===md&&vd?null:e;default:return null}}function _1(e,t){if(Ta)return e==="compositionend"||!Fu&&Fh(e,t)?(e=$h(),lo=$u=dn=null,Ta=!1,e):null;switch(e){case"paste":return null;case"keypress":if(!(t.ctrlKey||t.altKey||t.metaKey)||t.ctrlKey&&t.altKey){if(t.char&&1<t.char.length)return t.char;if(t.which)return String.fromCharCode(t.which)}return null;case"compositionend":return Jh&&t.locale!=="ko"?null:t.data;default:return null}}function gd(e){var t=e&&e.nodeName&&e.nodeName.toLowerCase();return t==="input"?!!S1[e.type]:t==="textarea"?!0:!1}function Ih(e,t,n,a){Aa?Ba?Ba.push(a):Ba=[a]:Aa=a,t=Go(t,"onChange"),0<t.length&&(n=new Wo("onChange","change",null,n,a),e.push({event:n,listeners:t}))}function x1(e){Zm(e,0)}function Po(e){var t=Ci(e);if(Gh(t))return e}function bd(e,t){if(e==="change")return t}function yd(){qi&&(qi.detachEvent("onpropertychange",ep),tl=qi=null)}function ep(e){if(e.propertyName==="value"&&Po(tl)){var t=[];Ih(t,tl,e,Zu(e)),Zh(x1,t)}}function E1(e,t,n){e==="focusin"?(yd(),qi=t,tl=n,qi.attachEvent("onpropertychange",ep)):e==="focusout"&&yd()}function w1(e){if(e==="selectionchange"||e==="keyup"||e==="keydown")return Po(tl)}function N1(e,t){if(e==="click")return Po(t)}function O1(e,t){if(e==="input"||e==="change")return Po(t)}function A1(e,t){return e===t&&(e!==0||1/e===1/t)||e!==e&&t!==t}function nl(e,t){if(Ye(e,t))return!0;if(typeof e!=="object"||e===null||typeof t!=="object"||t===null)return!1;var n=Object.keys(e),a=Object.keys(t);if(n.length!==a.length)return!1;for(a=0;a<n.length;a++){var i=n[a];if(!Fs.call(t,i)||!Ye(e[i],t[i]))return!1}return!0}function _d(e){for(;e&&e.firstChild;)e=e.firstChild;return e}function Sd(e,t){var n=_d(e);e=0;for(var a;n;){if(n.nodeType===3){if(a=e+n.textContent.length,e<=t&&a>=t)return{node:n,offset:t-e};e=a}e:{for(;n;){if(n.nextSibling){n=n.nextSibling;break e}n=n.parentNode}n=void 0}n=_d(n)}}function tp(e,t){return e&&t?e===t?!0:e&&e.nodeType===3?!1:t&&t.nodeType===3?tp(e,t.parentNode):("contains"in e)?e.contains(t):e.compareDocumentPosition?!!(e.compareDocumentPosition(t)&16):!1:!1}function np(e){e=e!=null&&e.ownerDocument!=null&&e.ownerDocument.defaultView!=null?e.ownerDocument.defaultView:window;for(var t=wo(e.document);t instanceof e.HTMLIFrameElement;){try{var n=typeof t.contentWindow.location.href==="string"}catch(a){n=!1}if(n)e=t.contentWindow;else break;t=wo(e.document)}return t}function Wu(e){var t=e&&e.nodeName&&e.nodeName.toLowerCase();return t&&(t==="input"&&(e.type==="text"||e.type==="search"||e.type==="tel"||e.type==="url"||e.type==="password")||t==="textarea"||e.contentEditable==="true")}function xd(e,t,n){var a=n.window===n?n.document:n.nodeType===9?n:n.ownerDocument;iu||Da==null||Da!==wo(a)||(a=Da,("selectionStart"in a)&&Wu(a)?a={start:a.selectionStart,end:a.selectionEnd}:(a=(a.ownerDocument&&a.ownerDocument.defaultView||window).getSelection(),a={anchorNode:a.anchorNode,anchorOffset:a.anchorOffset,focusNode:a.focusNode,focusOffset:a.focusOffset}),Gi&&nl(Gi,a)||(Gi=a,a=Go(au,"onSelect"),0<a.length&&(t=new Wo("onSelect","select",null,t,n),e.push({event:t,listeners:a}),t.target=Da)))}function jn(e,t){var n={};return n[e.toLowerCase()]=t.toLowerCase(),n["Webkit"+e]="webkit"+t,n["Moz"+e]="moz"+t,n}function ia(e){if(_s[e])return _s[e];if(!za[e])return e;var t=za[e],n;for(n in t)if(t.hasOwnProperty(n)&&n in ap)return _s[e]=t[n];return e}function pt(e,t){sp.set(e,t),na(t,[e])}function er(){for(var e=Ra,t=Iu=Ra=0;t<e;){var n=Fe[t];Fe[t++]=null;var a=Fe[t];Fe[t++]=null;var i=Fe[t];Fe[t++]=null;var l=Fe[t];if(Fe[t++]=null,a!==null&&i!==null){var o=a.pending;o===null?i.next=i:(i.next=o.next,o.next=i),a.pending=i}l!==0&&up(n,i,l)}}function tr(e,t,n,a){Fe[Ra++]=e,Fe[Ra++]=t,Fe[Ra++]=n,Fe[Ra++]=a,Iu|=a,e.lanes|=a,e=e.alternate,e!==null&&(e.lanes|=a)}function Pu(e,t,n,a){return tr(e,t,n,a),Oo(e)}function la(e,t){return tr(e,null,null,t),Oo(e)}function up(e,t,n){e.lanes|=n;var a=e.alternate;a!==null&&(a.lanes|=n);for(var i=!1,l=e.return;l!==null;)l.childLanes|=n,a=l.alternate,a!==null&&(a.childLanes|=n),l.tag===22&&(e=l.stateNode,e===null||e._visibility&1||(i=!0)),e=l,l=l.return;return e.tag===3?(l=e.stateNode,i&&t!==null&&(i=31-qe(n),e=l.hiddenUpdates,a=e[i],a===null?e[i]=[t]:a.push(t),t.lane=n|536870912),l):null}function Oo(e){if(50<Wi)throw Wi=0,Ou=null,Error(S(185));for(var t=e.return;t!==null;)e=t,t=e.return;return e.tag===3?e.stateNode:null}function M1(e,t,n,a){this.tag=e,this.key=n,this.sibling=this.child=this.return=this.stateNode=this.type=this.elementType=null,this.index=0,this.refCleanup=this.ref=null,this.pendingProps=t,this.dependencies=this.memoizedState=this.updateQueue=this.memoizedProps=null,this.mode=a,this.subtreeFlags=this.flags=0,this.deletions=null,this.childLanes=this.lanes=0,this.alternate=null}function Le(e,t,n,a){return new M1(e,t,n,a)}function ec(e){return e=e.prototype,!(!e||!e.isReactComponent)}function jt(e,t){var n=e.alternate;return n===null?(n=Le(e.tag,t,e.key,e.mode),n.elementType=e.elementType,n.type=e.type,n.stateNode=e.stateNode,n.alternate=e,e.alternate=n):(n.pendingProps=t,n.type=e.type,n.flags=0,n.subtreeFlags=0,n.deletions=null),n.flags=e.flags&65011712,n.childLanes=e.childLanes,n.lanes=e.lanes,n.child=e.child,n.memoizedProps=e.memoizedProps,n.memoizedState=e.memoizedState,n.updateQueue=e.updateQueue,t=e.dependencies,n.dependencies=t===null?null:{lanes:t.lanes,firstContext:t.firstContext},n.sibling=e.sibling,n.index=e.index,n.ref=e.ref,n.refCleanup=e.refCleanup,n}function cp(e,t){e.flags&=65011714;var n=e.alternate;return n===null?(e.childLanes=0,e.lanes=t,e.child=null,e.subtreeFlags=0,e.memoizedProps=null,e.memoizedState=null,e.updateQueue=null,e.dependencies=null,e.stateNode=null):(e.childLanes=n.childLanes,e.lanes=n.lanes,e.child=n.child,e.subtreeFlags=0,e.deletions=null,e.memoizedProps=n.memoizedProps,e.memoizedState=n.memoizedState,e.updateQueue=n.updateQueue,e.type=n.type,t=n.dependencies,e.dependencies=t===null?null:{lanes:t.lanes,firstContext:t.firstContext}),e}function so(e,t,n,a,i,l){var o=0;if(a=e,typeof e==="function")ec(e)&&(o=1);else if(typeof e==="string")o=k_(e,n,wt.current)?26:e==="html"||e==="head"||e==="body"?27:5;else e:switch(e){case Qs:return e=Le(31,n,t,i),e.elementType=Qs,e.lanes=l,e;case wa:return Zn(n.children,i,l,t);case Dh:o=8,i|=24;break;case Ys:return e=Le(12,n,t,i|2),e.elementType=Ys,e.lanes=l,e;case Ks:return e=Le(13,n,t,i),e.elementType=Ks,e.lanes=l,e;case Xs:return e=Le(19,n,t,i),e.elementType=Xs,e.lanes=l,e;default:if(typeof e==="object"&&e!==null)switch(e.$$typeof){case Lt:o=10;break e;case zh:o=9;break e;case ju:o=11;break e;case qu:o=14;break e;case ln:o=16,a=null;break e}o=29,n=Error(S(130,e===null?"null":typeof e,"")),a=null}return t=Le(o,n,t,i),t.elementType=e,t.type=a,t.lanes=l,t}function Zn(e,t,n,a){return e=Le(7,e,a,t),e.lanes=n,e}function Ss(e,t,n){return e=Le(6,e,null,t),e.lanes=n,e}function fp(e){var t=Le(18,null,null,0);return t.stateNode=e,t}function xs(e,t,n){return t=Le(4,e.children!==null?e.children:[],e.key,t),t.lanes=n,t.stateNode={containerInfo:e.containerInfo,pendingChildren:null,implementation:e.implementation},t}function tt(e,t){if(typeof e==="object"&&e!==null){var n=Ed.get(e);if(n!==void 0)return n;return t={value:e,source:t,stack:id(t)},Ed.set(e,t),t}return{value:e,source:t,stack:id(t)}}function kt(e,t){Ca[Ua++]=al,Ca[Ua++]=Ao,Ao=e,al=t}function dp(e,t,n){Ie[Pe++]=St,Ie[Pe++]=xt,Ie[Pe++]=Nn,Nn=e;var a=St;e=xt;var i=32-qe(a)-1;a&=~(1<<i),n+=1;var l=32-qe(t)+i;if(30<l){var o=i-i%5;l=(a&(1<<o)-1).toString(32),a>>=o,i-=o,St=1<<32-qe(t)+i|n<<i|a,xt=l+e}else St=1<<l|n<<i|a,xt=e}function tc(e){e.return!==null&&(kt(e,1),dp(e,1,0))}function nc(e){for(;e===Ao;)Ao=Ca[--Ua],Ca[Ua]=null,al=Ca[--Ua],Ca[Ua]=null;for(;e===Nn;)Nn=Ie[--Pe],Ie[Pe]=null,xt=Ie[--Pe],Ie[Pe]=null,St=Ie[--Pe],Ie[Pe]=null}function hp(e,t){Ie[Pe++]=St,Ie[Pe++]=xt,Ie[Pe++]=Nn,St=t.id,xt=t.overflow,Nn=e}function On(e){var t=Error(S(418,1<arguments.length&&arguments[1]!==void 0&&arguments[1]?"text":"HTML",""));throw il(tt(t,e)),ou}function wd(e){var{stateNode:t,type:n,memoizedProps:a}=e;switch(t[_e]=e,t[Ce]=a,n){case"dialog":H("cancel",t),H("close",t);break;case"iframe":case"object":case"embed":H("load",t);break;case"video":case"audio":for(n=0;n<sl.length;n++)H(sl[n],t);break;case"source":H("error",t);break;case"img":case"image":case"link":H("error",t),H("load",t);break;case"details":H("toggle",t);break;case"input":H("invalid",t),Yh(t,a.value,a.defaultValue,a.checked,a.defaultChecked,a.type,a.name,!0);break;case"select":H("invalid",t);break;case"textarea":H("invalid",t),Xh(t,a.value,a.defaultValue,a.children)}n=a.children,typeof n!=="string"&&typeof n!=="number"&&typeof n!=="bigint"||t.textContent===""+n||a.suppressHydrationWarning===!0||Jm(t.textContent,n)?(a.popover!=null&&(H("beforetoggle",t),H("toggle",t)),a.onScroll!=null&&H("scroll",t),a.onScrollEnd!=null&&H("scrollend",t),a.onClick!=null&&(t.onclick=Bt),t=!0):t=!1,t||On(e,!0)}function Nd(e){for(Se=e.return;Se;)switch(Se.tag){case 5:case 31:case 13:nt=!1;return;case 27:case 3:nt=!0;return;default:Se=Se.return}}function ya(e){if(e!==Se)return!1;if(!G)return Nd(e),G=!0,!1;var t=e.tag,n;if(n=t!==3&&t!==27){if(n=t===5)n=e.type,n=!(n!=="form"&&n!=="button")||Cu(e.type,e.memoizedProps);n=!n}if(n&&ne&&On(e),Nd(e),t===13){if(e=e.memoizedState,e=e!==null?e.dehydrated:null,!e)throw Error(S(317));ne=fh(e)}else if(t===31){if(e=e.memoizedState,e=e!==null?e.dehydrated:null,!e)throw Error(S(317));ne=fh(e)}else t===27?(t=ne,zn(e.type)?(e=Lu,Lu=null,ne=e):ne=t):ne=Se?it(e.stateNode.nextSibling):null;return!0}function Wn(){ne=Se=null,G=!1}function Es(){var e=gn;return e!==null&&(Re===null?Re=e:Re.push.apply(Re,e),gn=null),e}function il(e){gn===null?gn=[e]:gn.push(e)}function rn(e,t,n){W(ru,t._currentValue),t._currentValue=n}function qt(e){e._currentValue=ru.current,be(ru)}function su(e,t,n){for(;e!==null;){var a=e.alternate;if((e.childLanes&t)!==t?(e.childLanes|=t,a!==null&&(a.childLanes|=t)):a!==null&&(a.childLanes&t)!==t&&(a.childLanes|=t),e===n)break;e=e.return}}function uu(e,t,n,a){var i=e.child;i!==null&&(i.return=e);for(;i!==null;){var l=i.dependencies;if(l!==null){var o=i.child;l=l.firstContext;e:for(;l!==null;){var r=l;l=i;for(var s=0;s<t.length;s++)if(r.context===t[s]){l.lanes|=n,r=l.alternate,r!==null&&(r.lanes|=n),su(l.return,n,e),a||(o=null);break e}l=r.next}}else if(i.tag===18){if(o=i.return,o===null)throw Error(S(341));o.lanes|=n,l=o.alternate,l!==null&&(l.lanes|=n),su(o,n,e),o=null}else o=i.child;if(o!==null)o.return=i;else for(o=i;o!==null;){if(o===e){o=null;break}if(i=o.sibling,i!==null){i.return=o.return,o=i;break}o=o.return}i=o}}function ni(e,t,n,a){e=null;for(var i=t,l=!1;i!==null;){if(!l){if((i.flags&524288)!==0)l=!0;else if((i.flags&262144)!==0)break}if(i.tag===10){var o=i.alternate;if(o===null)throw Error(S(387));if(o=o.memoizedProps,o!==null){var r=i.type;Ye(i.pendingProps.value,o.value)||(e!==null?e.push(r):e=[r])}}else if(i===_o.current){if(o=i.alternate,o===null)throw Error(S(387));o.memoizedState.memoizedState!==i.memoizedState.memoizedState&&(e!==null?e.push(cl):e=[cl])}i=i.return}e!==null&&uu(t,e,n,a),t.flags|=262144}function To(e){for(e=e.firstContext;e!==null;){if(!Ye(e.context._currentValue,e.memoizedValue))return!0;e=e.next}return!1}function In(e){oa=e,Ht=null,e=e.dependencies,e!==null&&(e.firstContext=null)}function xe(e){return pp(oa,e)}function Jl(e,t){return oa===null&&In(e),pp(e,t)}function pp(e,t){var n=t._currentValue;if(t={context:t,memoizedValue:n,next:null},Ht===null){if(e===null)throw Error(S(308));Ht=t,e.dependencies={lanes:0,firstContext:t},e.flags|=524288}else Ht=Ht.next=t;return n}function ac(){return{controller:new C1,data:new Map,refCount:0}}function yl(e){e.refCount--,e.refCount===0&&U1(k1,function(){e.controller.abort()})}function V1(e,t){if(Yi===null){var n=Yi=[];cu=0,Qa=Tc(),Ha={status:"pending",value:void 0,then:function(a){n.push(a)}}}return cu++,t.then(Od,Od),t}function Od(){if(--cu===0&&Yi!==null){Ha!==null&&(Ha.status="fulfilled");var e=Yi;Yi=null,Qa=0,Ha=null;for(var t=0;t<e.length;t++)(0,e[t])()}}function L1(e,t){var n=[],a={status:"pending",value:null,reason:null,then:function(i){n.push(i)}};return e.then(function(){a.status="fulfilled",a.value=t;for(var i=0;i<n.length;i++)(0,n[i])(t)},function(i){a.status="rejected",a.reason=i;for(i=0;i<n.length;i++)(0,n[i])(void 0)}),a}function ic(){var e=$n.current;return e!==null?e:F.pooledCache}function uo(e,t){t===null?W($n,$n.current):W($n,t.pool)}function mp(){var e=ic();return e===null?null:{parent:fe._currentValue,pool:e}}function Td(e){return e=e.status,e==="fulfilled"||e==="rejected"}function vp(e,t,n){switch(n=e[n],n===void 0?e.push(t):n!==t&&(t.then(Bt,Bt),t=n),t.status){case"fulfilled":return t.value;case"rejected":throw e=t.reason,zd(e),e;default:if(typeof t.status==="string")t.then(Bt,Bt);else{if(e=F,e!==null&&100<e.shellSuspendCounter)throw Error(S(482));e=t,e.status="pending",e.then(function(a){if(t.status==="pending"){var i=t;i.status="fulfilled",i.value=a}},function(a){if(t.status==="pending"){var i=t;i.status="rejected",i.reason=a}})}switch(t.status){case"fulfilled":return t.value;case"rejected":throw e=t.reason,zd(e),e}throw Jn=t,ai}}function Kn(e){try{var t=e._init;return t(e._payload)}catch(n){if(n!==null&&typeof n==="object"&&typeof n.then==="function")throw Jn=n,ai;throw n}}function Dd(){if(Jn===null)throw Error(S(459));var e=Jn;return Jn=null,e}function zd(e){if(e===ai||e===nr)throw Error(S(483))}function Fl(e){var t=ll;return ll+=1,ja===null&&(ja=[]),vp(ja,e,t)}function Ai(e,t){t=t.props.ref,e.ref=t!==void 0?t:null}function Wl(e,t){if(t.$$typeof===E0)throw Error(S(525));throw e=Object.prototype.toString.call(t),Error(S(31,e==="[object Object]"?"object with keys {"+Object.keys(t).join(", ")+"}":e))}function gp(e){function t(d,f){if(e){var v=d.deletions;v===null?(d.deletions=[f],d.flags|=16):v.push(f)}}function n(d,f){if(!e)return null;for(;f!==null;)t(d,f),f=f.sibling;return null}function a(d){for(var f=new Map;d!==null;)d.key!==null?f.set(d.key,d):f.set(d.index,d),d=d.sibling;return f}function i(d,f){return d=jt(d,f),d.index=0,d.sibling=null,d}function l(d,f,v){if(d.index=v,!e)return d.flags|=1048576,f;if(v=d.alternate,v!==null)return v=v.index,v<f?(d.flags|=67108866,f):v;return d.flags|=67108866,f}function o(d){return e&&d.alternate===null&&(d.flags|=67108866),d}function r(d,f,v,y){if(f===null||f.tag!==6)return f=Ss(v,d.mode,y),f.return=d,f;return f=i(f,v),f.return=d,f}function s(d,f,v,y){var w=v.type;if(w===wa)return m(d,f,v.props.children,y,v.key);if(f!==null&&(f.elementType===w||typeof w==="object"&&w!==null&&w.$$typeof===ln&&Kn(w)===f.type))return f=i(f,v.props),Ai(f,v),f.return=d,f;return f=so(v.type,v.key,v.props,null,d.mode,y),Ai(f,v),f.return=d,f}function c(d,f,v,y){if(f===null||f.tag!==4||f.stateNode.containerInfo!==v.containerInfo||f.stateNode.implementation!==v.implementation)return f=xs(v,d.mode,y),f.return=d,f;return f=i(f,v.children||[]),f.return=d,f}function m(d,f,v,y,w){if(f===null||f.tag!==7)return f=Zn(v,d.mode,y,w),f.return=d,f;return f=i(f,v),f.return=d,f}function b(d,f,v){if(typeof f==="string"&&f!==""||typeof f==="number"||typeof f==="bigint")return f=Ss(""+f,d.mode,v),f.return=d,f;if(typeof f==="object"&&f!==null){switch(f.$$typeof){case Yl:return v=so(f.type,f.key,f.props,null,d.mode,v),Ai(v,f),v.return=d,v;case Ri:return f=xs(f,d.mode,v),f.return=d,f;case ln:return f=Kn(f),b(d,f,v)}if(Mi(f)||Ni(f))return f=Zn(f,d.mode,v,null),f.return=d,f;if(typeof f.then==="function")return b(d,Fl(f),v);if(f.$$typeof===Lt)return b(d,Jl(d,f),v);Wl(d,f)}return null}function h(d,f,v,y){var w=f!==null?f.key:null;if(typeof v==="string"&&v!==""||typeof v==="number"||typeof v==="bigint")return w!==null?null:r(d,f,""+v,y);if(typeof v==="object"&&v!==null){switch(v.$$typeof){case Yl:return v.key===w?s(d,f,v,y):null;case Ri:return v.key===w?c(d,f,v,y):null;case ln:return v=Kn(v),h(d,f,v,y)}if(Mi(v)||Ni(v))return w!==null?null:m(d,f,v,y,null);if(typeof v.then==="function")return h(d,f,Fl(v),y);if(v.$$typeof===Lt)return h(d,f,Jl(d,v),y);Wl(d,v)}return null}function g(d,f,v,y,w){if(typeof y==="string"&&y!==""||typeof y==="number"||typeof y==="bigint")return d=d.get(v)||null,r(f,d,""+y,w);if(typeof y==="object"&&y!==null){switch(y.$$typeof){case Yl:return d=d.get(y.key===null?v:y.key)||null,s(f,d,y,w);case Ri:return d=d.get(y.key===null?v:y.key)||null,c(f,d,y,w);case ln:return y=Kn(y),g(d,f,v,y,w)}if(Mi(y)||Ni(y))return d=d.get(v)||null,m(f,d,y,w,null);if(typeof y.then==="function")return g(d,f,v,Fl(y),w);if(y.$$typeof===Lt)return g(d,f,v,Jl(f,y),w);Wl(f,y)}return null}function x(d,f,v,y){for(var w=null,U=null,O=f,R=f=0,k=null;O!==null&&R<v.length;R++){O.index>R?(k=O,O=null):k=O.sibling;var B=h(d,O,v[R],y);if(B===null){O===null&&(O=k);break}e&&O&&B.alternate===null&&t(d,O),f=l(B,f,R),U===null?w=B:U.sibling=B,U=B,O=k}if(R===v.length)return n(d,O),G&&kt(d,R),w;if(O===null){for(;R<v.length;R++)O=b(d,v[R],y),O!==null&&(f=l(O,f,R),U===null?w=O:U.sibling=O,U=O);return G&&kt(d,R),w}for(O=a(O);R<v.length;R++)k=g(O,d,R,v[R],y),k!==null&&(e&&k.alternate!==null&&O.delete(k.key===null?R:k.key),f=l(k,f,R),U===null?w=k:U.sibling=k,U=k);return e&&O.forEach(function(ct){return t(d,ct)}),G&&kt(d,R),w}function A(d,f,v,y){if(v==null)throw Error(S(151));for(var w=null,U=null,O=f,R=f=0,k=null,B=v.next();O!==null&&!B.done;R++,B=v.next()){O.index>R?(k=O,O=null):k=O.sibling;var ct=h(d,O,B.value,y);if(ct===null){O===null&&(O=k);break}e&&O&&ct.alternate===null&&t(d,O),f=l(ct,f,R),U===null?w=ct:U.sibling=ct,U=ct,O=k}if(B.done)return n(d,O),G&&kt(d,R),w;if(O===null){for(;!B.done;R++,B=v.next())B=b(d,B.value,y),B!==null&&(f=l(B,f,R),U===null?w=B:U.sibling=B,U=B);return G&&kt(d,R),w}for(O=a(O);!B.done;R++,B=v.next())B=g(O,d,R,B.value,y),B!==null&&(e&&B.alternate!==null&&O.delete(B.key===null?R:B.key),f=l(B,f,R),U===null?w=B:U.sibling=B,U=B);return e&&O.forEach(function(Cr){return t(d,Cr)}),G&&kt(d,R),w}function M(d,f,v,y){if(typeof v==="object"&&v!==null&&v.type===wa&&v.key===null&&(v=v.props.children),typeof v==="object"&&v!==null){switch(v.$$typeof){case Yl:e:{for(var w=v.key;f!==null;){if(f.key===w){if(w=v.type,w===wa){if(f.tag===7){n(d,f.sibling),y=i(f,v.props.children),y.return=d,d=y;break e}}else if(f.elementType===w||typeof w==="object"&&w!==null&&w.$$typeof===ln&&Kn(w)===f.type){n(d,f.sibling),y=i(f,v.props),Ai(y,v),y.return=d,d=y;break e}n(d,f);break}else t(d,f);f=f.sibling}v.type===wa?(y=Zn(v.props.children,d.mode,y,v.key),y.return=d,d=y):(y=so(v.type,v.key,v.props,null,d.mode,y),Ai(y,v),y.return=d,d=y)}return o(d);case Ri:e:{for(w=v.key;f!==null;){if(f.key===w)if(f.tag===4&&f.stateNode.containerInfo===v.containerInfo&&f.stateNode.implementation===v.implementation){n(d,f.sibling),y=i(f,v.children||[]),y.return=d,d=y;break e}else{n(d,f);break}else t(d,f);f=f.sibling}y=xs(v,d.mode,y),y.return=d,d=y}return o(d);case ln:return v=Kn(v),M(d,f,v,y)}if(Mi(v))return x(d,f,v,y);if(Ni(v)){if(w=Ni(v),typeof w!=="function")throw Error(S(150));return v=w.call(v),A(d,f,v,y)}if(typeof v.then==="function")return M(d,f,Fl(v),y);if(v.$$typeof===Lt)return M(d,f,Jl(d,v),y);Wl(d,v)}return typeof v==="string"&&v!==""||typeof v==="number"||typeof v==="bigint"?(v=""+v,f!==null&&f.tag===6?(n(d,f.sibling),y=i(f,v),y.return=d,d=y):(n(d,f),y=Ss(v,d.mode,y),y.return=d,d=y),o(d)):n(d,f)}return function(d,f,v,y){try{ll=0;var w=M(d,f,v,y);return ja=null,w}catch(O){if(O===ai||O===nr)throw O;var U=Le(29,O,null,d.mode);return U.lanes=y,U.return=d,U}finally{}}}function oc(e){e.updateQueue={baseState:e.memoizedState,firstBaseUpdate:null,lastBaseUpdate:null,shared:{pending:null,lanes:0,hiddenCallbacks:null},callbacks:null}}function fu(e,t){e=e.updateQueue,t.updateQueue===e&&(t.updateQueue={baseState:e.baseState,firstBaseUpdate:e.firstBaseUpdate,lastBaseUpdate:e.lastBaseUpdate,shared:e.shared,callbacks:null})}function bn(e){return{lane:e,tag:0,payload:null,callback:null,next:null}}function yn(e,t,n){var a=e.updateQueue;if(a===null)return null;if(a=a.shared,(K&2)!==0){var i=a.pending;return i===null?t.next=t:(t.next=i.next,i.next=t),a.pending=t,t=Oo(e),up(e,null,n),t}return tr(e,a,t,n),Oo(e)}function Ki(e,t,n){if(t=t.updateQueue,t!==null&&(t=t.shared,(n&4194048)!==0)){var a=t.lanes;a&=e.pendingLanes,n|=a,t.lanes=n,Vh(e,n)}}function ws(e,t){var{updateQueue:n,alternate:a}=e;if(a!==null&&(a=a.updateQueue,n===a)){var i=null,l=null;if(n=n.firstBaseUpdate,n!==null){do{var o={lane:n.lane,tag:n.tag,payload:n.payload,callback:null,next:null};l===null?i=l=o:l=l.next=o,n=n.next}while(n!==null);l===null?i=l=t:l=l.next=t}else i=l=t;n={baseState:a.baseState,firstBaseUpdate:i,lastBaseUpdate:l,shared:a.shared,callbacks:a.callbacks},e.updateQueue=n;return}e=n.lastBaseUpdate,e===null?n.firstBaseUpdate=t:e.next=t,n.lastBaseUpdate=t}function Xi(){if(du){var e=Ha;if(e!==null)throw e}}function Qi(e,t,n,a){du=!1;var i=e.updateQueue;on=!1;var{firstBaseUpdate:l,lastBaseUpdate:o}=i,r=i.shared.pending;if(r!==null){i.shared.pending=null;var s=r,c=s.next;s.next=null,o===null?l=c:o.next=c,o=s;var m=e.alternate;m!==null&&(m=m.updateQueue,r=m.lastBaseUpdate,r!==o&&(r===null?m.firstBaseUpdate=c:r.next=c,m.lastBaseUpdate=s))}if(l!==null){var b=i.baseState;o=0,m=c=s=null,r=l;do{var h=r.lane&-536870913,g=h!==r.lane;if(g?(q&h)===h:(a&h)===h){h!==0&&h===Qa&&(du=!0),m!==null&&(m=m.next={lane:0,tag:r.tag,payload:r.payload,callback:null,next:null});e:{var x=e,A=r;h=t;var M=n;switch(A.tag){case 1:if(x=A.payload,typeof x==="function"){b=x.call(M,b,h);break e}b=x;break e;case 3:x.flags=x.flags&-65537|128;case 0:if(x=A.payload,h=typeof x==="function"?x.call(M,b,h):x,h===null||h===void 0)break e;b=ae({},b,h);break e;case 2:on=!0}}h=r.callback,h!==null&&(e.flags|=64,g&&(e.flags|=8192),g=i.callbacks,g===null?i.callbacks=[h]:g.push(h))}else g={lane:h,tag:r.tag,payload:r.payload,callback:r.callback,next:null},m===null?(c=m=g,s=b):m=m.next=g,o|=h;if(r=r.next,r===null)if(r=i.shared.pending,r===null)break;else g=r,r=g.next,g.next=null,i.lastBaseUpdate=g,i.shared.pending=null}while(1);m===null&&(s=b),i.baseState=s,i.firstBaseUpdate=c,i.lastBaseUpdate=m,l===null&&(i.shared.lanes=0),Tn|=o,e.lanes=o,e.memoizedState=b}}function yp(e,t){if(typeof e!=="function")throw Error(S(191,e));e.call(t)}function _p(e,t){var n=e.callbacks;if(n!==null)for(e.callbacks=null,e=0;e<n.length;e++)yp(n[e],t)}function Rd(e,t){e=Zt,W(zo,e),W(Za,t),Zt=e|t.baseLanes}function hu(){W(zo,Zt),W(Za,Za.current)}function rc(){Zt=zo.current,be(Za),be(zo)}function sn(e){var t=e.alternate;W(re,re.current&1),W(Ke,e),at===null&&(t===null||Za.current!==null?at=e:t.memoizedState!==null&&(at=e))}function pu(e){W(re,re.current),W(Ke,e),at===null&&(at=e)}function Sp(e){e.tag===22?(W(re,re.current),W(Ke,e),at===null&&(at=e)):un(e)}function un(){W(re,re.current),W(Ke,Ke.current)}function Ve(e){be(Ke),at===e&&(at=null),be(re)}function Ro(e){for(var t=e;t!==null;){if(t.tag===13){var n=t.memoizedState;if(n!==null&&(n=n.dehydrated,n===null||ku(n)||Vu(n)))return t}else if(t.tag===19&&(t.memoizedProps.revealOrder==="forwards"||t.memoizedProps.revealOrder==="backwards"||t.memoizedProps.revealOrder==="unstable_legacy-backwards"||t.memoizedProps.revealOrder==="together")){if((t.flags&128)!==0)return t}else if(t.child!==null){t.child.return=t,t=t.child;continue}if(t===e)break;for(;t.sibling===null;){if(t.return===null||t.return===e)return null;t=t.return}t.sibling.return=t.return,t=t.sibling}return null}function le(){throw Error(S(321))}function sc(e,t){if(t===null)return!1;for(var n=0;n<t.length&&n<e.length;n++)if(!Ye(e[n],t[n]))return!1;return!0}function uc(e,t,n,a,i,l){return Kt=l,C=t,t.memoizedState=null,t.updateQueue=null,t.lanes=0,z.H=e===null||e.memoizedState===null?Ip:_c,ea=!1,l=n(a,i),ea=!1,qa&&(l=Ep(t,n,a,i)),xp(e),l}function xp(e){z.H=rl;var t=J!==null&&J.next!==null;if(Kt=0,ue=J=C=null,Mo=!1,ol=0,Ga=null,t)throw Error(S(300));e===null||de||(e=e.dependencies,e!==null&&To(e)&&(de=!0))}function Ep(e,t,n,a){C=e;var i=0;do{if(qa&&(Ga=null),ol=0,qa=!1,25<=i)throw Error(S(301));if(i+=1,ue=J=null,e.updateQueue!=null){var l=e.updateQueue;l.lastEffect=null,l.events=null,l.stores=null,l.memoCache!=null&&(l.memoCache.index=0)}z.H=Pp,l=t(n,a)}while(qa);return l}function H1(){var e=z.H,t=e.useState()[0];return t=typeof t.then==="function"?_l(t):t,e=e.useState()[0],(J!==null?J.memoizedState:null)!==e&&(C.flags|=1024),t}function cc(){var e=Co!==0;return Co=0,e}function fc(e,t,n){t.updateQueue=e.updateQueue,t.flags&=-2053,e.lanes&=~n}function dc(e){if(Mo){for(e=e.memoizedState;e!==null;){var t=e.queue;t!==null&&(t.pending=null),e=e.next}Mo=!1}Kt=0,ue=J=C=null,qa=!1,ol=Co=0,Ga=null}function Ae(){var e={memoizedState:null,baseState:null,baseQueue:null,queue:null,next:null};return ue===null?C.memoizedState=ue=e:ue=ue.next=e,ue}function se(){if(J===null){var e=C.alternate;e=e!==null?e.memoizedState:null}else e=J.next;var t=ue===null?C.memoizedState:ue.next;if(t!==null)ue=t,J=e;else{if(e===null){if(C.alternate===null)throw Error(S(467));throw Error(S(310))}J=e,e={memoizedState:J.memoizedState,baseState:J.baseState,baseQueue:J.baseQueue,queue:J.queue,next:null},ue===null?C.memoizedState=ue=e:ue=ue.next=e}return ue}function ar(){return{lastEffect:null,events:null,stores:null,memoCache:null}}function _l(e){var t=ol;return ol+=1,Ga===null&&(Ga=[]),e=vp(Ga,e,t),t=C,(ue===null?t.memoizedState:ue.next)===null&&(t=t.alternate,z.H=t===null||t.memoizedState===null?Ip:_c),e}function ir(e){if(e!==null&&typeof e==="object"){if(typeof e.then==="function")return _l(e);if(e.$$typeof===Lt)return xe(e)}throw Error(S(438,String(e)))}function hc(e){var t=null,n=C.updateQueue;if(n!==null&&(t=n.memoCache),t==null){var a=C.alternate;a!==null&&(a=a.updateQueue,a!==null&&(a=a.memoCache,a!=null&&(t={data:a.data.map(function(i){return i.slice()}),index:0})))}if(t==null&&(t={data:[],index:0}),n===null&&(n=ar(),C.updateQueue=n),n.memoCache=t,n=t.data[t.index],n===void 0)for(n=t.data[t.index]=Array(e),a=0;a<e;a++)n[a]=w0;return t.index++,n}function Xt(e,t){return typeof t==="function"?t(e):t}function co(e){var t=se();return pc(t,J,e)}function pc(e,t,n){var a=e.queue;if(a===null)throw Error(S(311));a.lastRenderedReducer=n;var i=e.baseQueue,l=a.pending;if(l!==null){if(i!==null){var o=i.next;i.next=l.next,l.next=o}t.baseQueue=i=l,a.pending=null}if(l=e.baseState,i===null)e.memoizedState=l;else{t=i.next;var r=o=null,s=null,c=t,m=!1;do{var b=c.lane&-536870913;if(b!==c.lane?(q&b)===b:(Kt&b)===b){var h=c.revertLane;if(h===0)s!==null&&(s=s.next={lane:0,revertLane:0,gesture:null,action:c.action,hasEagerState:c.hasEagerState,eagerState:c.eagerState,next:null}),b===Qa&&(m=!0);else if((Kt&h)===h){c=c.next,h===Qa&&(m=!0);continue}else b={lane:0,revertLane:c.revertLane,gesture:null,action:c.action,hasEagerState:c.hasEagerState,eagerState:c.eagerState,next:null},s===null?(r=s=b,o=l):s=s.next=b,C.lanes|=h,Tn|=h;b=c.action,ea&&n(l,b),l=c.hasEagerState?c.eagerState:n(l,b)}else h={lane:b,revertLane:c.revertLane,gesture:c.gesture,action:c.action,hasEagerState:c.hasEagerState,eagerState:c.eagerState,next:null},s===null?(r=s=h,o=l):s=s.next=h,C.lanes|=b,Tn|=b;c=c.next}while(c!==null&&c!==t);if(s===null?o=l:s.next=r,!Ye(l,e.memoizedState)&&(de=!0,m&&(n=Ha,n!==null)))throw n;e.memoizedState=l,e.baseState=o,e.baseQueue=s,a.lastRenderedState=l}return i===null&&(a.lanes=0),[e.memoizedState,a.dispatch]}function Ns(e){var t=se(),n=t.queue;if(n===null)throw Error(S(311));n.lastRenderedReducer=e;var{dispatch:a,pending:i}=n,l=t.memoizedState;if(i!==null){n.pending=null;var o=i=i.next;do l=e(l,o.action),o=o.next;while(o!==i);Ye(l,t.memoizedState)||(de=!0),t.memoizedState=l,t.baseQueue===null&&(t.baseState=l),n.lastRenderedState=l}return[l,a]}function wp(e,t,n){var a=C,i=se(),l=G;if(l){if(n===void 0)throw Error(S(407));n=n()}else n=t();var o=!Ye((J||i).memoizedState,n);if(o&&(i.memoizedState=n,de=!0),i=i.queue,mc(Ap.bind(null,a,i,e),[e]),i.getSnapshot!==t||o||ue!==null&&ue.memoizedState.tag&1){if(a.flags|=2048,$a(9,{destroy:void 0},Op.bind(null,a,i,n,t),null),F===null)throw Error(S(349));l||(Kt&127)!==0||Np(a,t,n)}return n}function Np(e,t,n){e.flags|=16384,e={getSnapshot:t,value:n},t=C.updateQueue,t===null?(t=ar(),C.updateQueue=t,t.stores=[e]):(n=t.stores,n===null?t.stores=[e]:n.push(e))}function Op(e,t,n,a){t.value=n,t.getSnapshot=a,Tp(t)&&Dp(e)}function Ap(e,t,n){return n(function(){Tp(t)&&Dp(e)})}function Tp(e){var t=e.getSnapshot;e=e.value;try{var n=t();return!Ye(e,n)}catch(a){return!0}}function Dp(e){var t=la(e,2);t!==null&&Me(t,e,2)}function mu(e){var t=Ae();if(typeof e==="function"){var n=e;if(e=n(),ea){fn(!0);try{n()}finally{fn(!1)}}}return t.memoizedState=t.baseState=e,t.queue={pending:null,lanes:0,dispatch:null,lastRenderedReducer:Xt,lastRenderedState:e},t}function zp(e,t,n,a){return e.baseState=n,pc(e,J,typeof a==="function"?a:Xt)}function j1(e,t,n,a,i){if(or(e))throw Error(S(485));if(e=t.action,e!==null){var l={payload:i,action:e,next:null,isTransition:!0,status:"pending",value:null,reason:null,listeners:[],then:function(o){l.listeners.push(o)}};z.T!==null?n(!0):l.isTransition=!1,a(l),n=t.pending,n===null?(l.next=t.pending=l,Rp(t,l)):(l.next=n.next,t.pending=n.next=l)}}function Rp(e,t){var{action:n,payload:a}=t,i=e.state;if(t.isTransition){var l=z.T,o={};z.T=o;try{var r=n(i,a),s=z.S;s!==null&&s(o,r),Md(e,t,r)}catch(c){vu(e,t,c)}finally{l!==null&&o.types!==null&&(l.types=o.types),z.T=l}}else try{l=n(i,a),Md(e,t,l)}catch(c){vu(e,t,c)}}function Md(e,t,n){n!==null&&typeof n==="object"&&typeof n.then==="function"?n.then(function(a){Cd(e,t,a)},function(a){return vu(e,t,a)}):Cd(e,t,n)}function Cd(e,t,n){t.status="fulfilled",t.value=n,Mp(t),e.state=n,t=e.pending,t!==null&&(n=t.next,n===t?e.pending=null:(n=n.next,t.next=n,Rp(e,n)))}function vu(e,t,n){var a=e.pending;if(e.pending=null,a!==null){a=a.next;do t.status="rejected",t.reason=n,Mp(t),t=t.next;while(t!==a)}e.action=null}function Mp(e){e=e.listeners;for(var t=0;t<e.length;t++)(0,e[t])()}function Cp(e,t){return t}function Ud(e,t){if(G){var n=F.formState;if(n!==null){e:{var a=C;if(G){if(ne){t:{var i=ne;for(var l=nt;i.nodeType!==8;){if(!l){i=null;break t}if(i=it(i.nextSibling),i===null){i=null;break t}}l=i.data,i=l==="F!"||l==="F"?i:null}if(i){ne=it(i.nextSibling),a=i.data==="F!";break e}}On(a)}a=!1}a&&(t=n[0])}}return n=Ae(),n.memoizedState=n.baseState=t,a={pending:null,lanes:0,dispatch:null,lastRenderedReducer:Cp,lastRenderedState:t},n.queue=a,n=Jp.bind(null,C,a),a.dispatch=n,a=mu(!1),l=yc.bind(null,C,!1,a.queue),a=Ae(),i={state:t,dispatch:null,action:e,pending:null},a.queue=i,n=j1.bind(null,C,i,l,n),i.dispatch=n,a.memoizedState=e,[t,n,!1]}function kd(e){var t=se();return Up(t,J,e)}function Up(e,t,n){if(t=pc(e,t,Cp)[0],e=co(Xt)[0],typeof t==="object"&&t!==null&&typeof t.then==="function")try{var a=_l(t)}catch(o){if(o===ai)throw nr;throw o}else a=t;t=se();var i=t.queue,l=i.dispatch;return n!==t.memoizedState&&(C.flags|=2048,$a(9,{destroy:void 0},q1.bind(null,i,n),null)),[a,l,e]}function q1(e,t){e.action=t}function Vd(e){var t=se(),n=J;if(n!==null)return Up(t,n,e);se(),t=t.memoizedState,n=se();var a=n.queue.dispatch;return n.memoizedState=e,[t,a,!1]}function $a(e,t,n,a){return e={tag:e,create:n,deps:a,inst:t,next:null},t=C.updateQueue,t===null&&(t=ar(),C.updateQueue=t),n=t.lastEffect,n===null?t.lastEffect=e.next=e:(a=n.next,n.next=e,e.next=a,t.lastEffect=e),e}function kp(){return se().memoizedState}function fo(e,t,n,a){var i=Ae();C.flags|=e,i.memoizedState=$a(1|t,{destroy:void 0},n,a===void 0?null:a)}function lr(e,t,n,a){var i=se();a=a===void 0?null:a;var l=i.memoizedState.inst;J!==null&&a!==null&&sc(a,J.memoizedState.deps)?i.memoizedState=$a(t,l,n,a):(C.flags|=e,i.memoizedState=$a(1|t,l,n,a))}function Ld(e,t){fo(8390656,8,e,t)}function mc(e,t){lr(2048,8,e,t)}function G1(e){C.flags|=4;var t=C.updateQueue;if(t===null)t=ar(),C.updateQueue=t,t.events=[e];else{var n=t.events;n===null?t.events=[e]:n.push(e)}}function Vp(e){var t=se().memoizedState;return G1({ref:t,nextImpl:e}),function(){if((K&2)!==0)throw Error(S(440));return t.impl.apply(void 0,arguments)}}function Lp(e,t){return lr(4,2,e,t)}function Bp(e,t){return lr(4,4,e,t)}function Hp(e,t){if(typeof t==="function"){e=e();var n=t(e);return function(){typeof n==="function"?n():t(null)}}if(t!==null&&t!==void 0)return e=e(),t.current=e,function(){t.current=null}}function jp(e,t,n){n=n!==null&&n!==void 0?n.concat([e]):null,lr(4,4,Hp.bind(null,t,e),n)}function vc(){}function qp(e,t){var n=se();t=t===void 0?null:t;var a=n.memoizedState;if(t!==null&&sc(t,a[1]))return a[0];return n.memoizedState=[e,t],e}function Gp(e,t){var n=se();t=t===void 0?null:t;var a=n.memoizedState;if(t!==null&&sc(t,a[1]))return a[0];if(a=e(),ea){fn(!0);try{e()}finally{fn(!1)}}return n.memoizedState=[a,t],a}function gc(e,t,n){if(n===void 0||(Kt&1073741824)!==0&&(q&261930)===0)return e.memoizedState=t;return e.memoizedState=n,e=zm(),C.lanes|=e,Tn|=e,n}function Yp(e,t,n,a){if(Ye(n,t))return n;if(Za.current!==null)return e=gc(e,n,a),Ye(e,t)||(de=!0),e;if((Kt&42)===0||(Kt&1073741824)!==0&&(q&261930)===0)return de=!0,e.memoizedState=n;return e=zm(),C.lanes|=e,Tn|=e,t}function Kp(e,t,n,a,i){var l=X.p;X.p=l!==0&&8>l?l:8;var o=z.T,r={};z.T=r,yc(e,!1,t,n);try{var s=i(),c=z.S;if(c!==null&&c(r,s),s!==null&&typeof s==="object"&&typeof s.then==="function"){var m=L1(s,a);Zi(e,t,m,Ge(e))}else Zi(e,t,a,Ge(e))}catch(b){Zi(e,t,{then:function(){},status:"rejected",reason:b},Ge())}finally{X.p=l,o!==null&&r.types!==null&&(o.types=r.types),z.T=o}}function Y1(){}function gu(e,t,n,a){if(e.tag!==5)throw Error(S(476));var i=Xp(e).queue;Kp(e,i,t,Qn,n===null?Y1:function(){return Qp(e),n(a)})}function Xp(e){var t=e.memoizedState;if(t!==null)return t;t={memoizedState:Qn,baseState:Qn,baseQueue:null,queue:{pending:null,lanes:0,dispatch:null,lastRenderedReducer:Xt,lastRenderedState:Qn},next:null};var n={};return t.next={memoizedState:n,baseState:n,baseQueue:null,queue:{pending:null,lanes:0,dispatch:null,lastRenderedReducer:Xt,lastRenderedState:n},next:null},e.memoizedState=t,e=e.alternate,e!==null&&(e.memoizedState=t),t}function Qp(e){var t=Xp(e);t.next===null&&(t=e.alternate.memoizedState),Zi(e,t.next.queue,{},Ge())}function bc(){return xe(cl)}function Zp(){return se().memoizedState}function $p(){return se().memoizedState}function K1(e){for(var t=e.return;t!==null;){switch(t.tag){case 24:case 3:var n=Ge();e=bn(n);var a=yn(t,e,n);a!==null&&(Me(a,t,n),Ki(a,t,n)),t={cache:ac()},e.payload=t;return}t=t.return}}function X1(e,t,n){var a=Ge();n={lane:a,revertLane:0,gesture:null,action:n,hasEagerState:!1,eagerState:null,next:null},or(e)?Fp(t,n):(n=Pu(e,t,n,a),n!==null&&(Me(n,e,a),Wp(n,t,a)))}function Jp(e,t,n){var a=Ge();Zi(e,t,n,a)}function Zi(e,t,n,a){var i={lane:a,revertLane:0,gesture:null,action:n,hasEagerState:!1,eagerState:null,next:null};if(or(e))Fp(t,i);else{var l=e.alternate;if(e.lanes===0&&(l===null||l.lanes===0)&&(l=t.lastRenderedReducer,l!==null))try{var o=t.lastRenderedState,r=l(o,n);if(i.hasEagerState=!0,i.eagerState=r,Ye(r,o))return tr(e,t,i,0),F===null&&er(),!1}catch(s){}finally{}if(n=Pu(e,t,i,a),n!==null)return Me(n,e,a),Wp(n,t,a),!0}return!1}function yc(e,t,n,a){if(a={lane:2,revertLane:Tc(),gesture:null,action:a,hasEagerState:!1,eagerState:null,next:null},or(e)){if(t)throw Error(S(479))}else t=Pu(e,n,a,2),t!==null&&Me(t,e,2)}function or(e){var t=e.alternate;return e===C||t!==null&&t===C}function Fp(e,t){qa=Mo=!0;var n=e.pending;n===null?t.next=t:(t.next=n.next,n.next=t),e.pending=t}function Wp(e,t,n){if((n&4194048)!==0){var a=t.lanes;a&=e.pendingLanes,n|=a,t.lanes=n,Vh(e,n)}}function Os(e,t,n,a){t=e.memoizedState,n=n(a,t),n=n===null||n===void 0?t:ae({},t,n),e.memoizedState=n,e.lanes===0&&(e.updateQueue.baseState=n)}function Bd(e,t,n,a,i,l,o){return e=e.stateNode,typeof e.shouldComponentUpdate==="function"?e.shouldComponentUpdate(a,l,o):t.prototype&&t.prototype.isPureReactComponent?!nl(n,a)||!nl(i,l):!0}function Hd(e,t,n,a){e=t.state,typeof t.componentWillReceiveProps==="function"&&t.componentWillReceiveProps(n,a),typeof t.UNSAFE_componentWillReceiveProps==="function"&&t.UNSAFE_componentWillReceiveProps(n,a),t.state!==e&&bu.enqueueReplaceState(t,t.state,null)}function ta(e,t){var n=t;if("ref"in t){n={};for(var a in t)a!=="ref"&&(n[a]=t[a])}if(e=e.defaultProps){n===t&&(n=ae({},n));for(var i in e)n[i]===void 0&&(n[i]=e[i])}return n}function em(e){No(e)}function tm(e){console.error(e)}function nm(e){No(e)}function Uo(e,t){try{var n=e.onUncaughtError;n(t.value,{componentStack:t.stack})}catch(a){setTimeout(function(){throw a})}}function jd(e,t,n){try{var a=e.onCaughtError;a(n.value,{componentStack:n.stack,errorBoundary:t.tag===1?t.stateNode:null})}catch(i){setTimeout(function(){throw i})}}function yu(e,t,n){return n=bn(n),n.tag=3,n.payload={element:null},n.callback=function(){Uo(e,t)},n}function am(e){return e=bn(e),e.tag=3,e}function im(e,t,n,a){var i=n.type.getDerivedStateFromError;if(typeof i==="function"){var l=a.value;e.payload=function(){return i(l)},e.callback=function(){jd(t,n,a)}}var o=n.stateNode;o!==null&&typeof o.componentDidCatch==="function"&&(e.callback=function(){jd(t,n,a),typeof i!=="function"&&(_n===null?_n=new Set([this]):_n.add(this));var r=a.stack;this.componentDidCatch(a.value,{componentStack:r!==null?r:""})})}function Q1(e,t,n,a,i){if(n.flags|=32768,a!==null&&typeof a==="object"&&typeof a.then==="function"){if(t=n.alternate,t!==null&&ni(t,n,i,!0),n=Ke.current,n!==null){switch(n.tag){case 31:case 13:return at===null?Ho():n.alternate===null&&oe===0&&(oe=3),n.flags&=-257,n.flags|=65536,n.lanes=i,a===Do?n.flags|=16384:(t=n.updateQueue,t===null?n.updateQueue=new Set([a]):t.add(a),Ls(e,a,i)),!1;case 22:return n.flags|=65536,a===Do?n.flags|=16384:(t=n.updateQueue,t===null?(t={transitions:null,markerInstances:null,retryQueue:new Set([a])},n.updateQueue=t):(n=t.retryQueue,n===null?t.retryQueue=new Set([a]):n.add(a)),Ls(e,a,i)),!1}throw Error(S(435,n.tag))}return Ls(e,a,i),Ho(),!1}if(G)return t=Ke.current,t!==null?((t.flags&65536)===0&&(t.flags|=256),t.flags|=65536,t.lanes=i,a!==ou&&(e=Error(S(422),{cause:a}),il(tt(e,n)))):(a!==ou&&(t=Error(S(423),{cause:a}),il(tt(t,n))),e=e.current.alternate,e.flags|=65536,i&=-i,e.lanes|=i,a=tt(a,n),i=yu(e.stateNode,a,i),ws(e,i),oe!==4&&(oe=2)),!1;var l=Error(S(520),{cause:a});if(l=tt(l,n),Fi===null?Fi=[l]:Fi.push(l),oe!==4&&(oe=2),t===null)return!0;a=tt(a,n),n=t;do{switch(n.tag){case 3:return n.flags|=65536,e=i&-i,n.lanes|=e,e=yu(n.stateNode,a,e),ws(n,e),!1;case 1:if(t=n.type,l=n.stateNode,(n.flags&128)===0&&(typeof t.getDerivedStateFromError==="function"||l!==null&&typeof l.componentDidCatch==="function"&&(_n===null||!_n.has(l))))return n.flags|=65536,i&=-i,n.lanes|=i,i=am(i),im(i,e,n,a),ws(n,i),!1}n=n.return}while(n!==null);return!1}function ye(e,t,n,a){t.child=e===null?bp(t,null,n,a):Pn(t,e.child,n,a)}function qd(e,t,n,a,i){n=n.render;var l=t.ref;if("ref"in a){var o={};for(var r in a)r!=="ref"&&(o[r]=a[r])}else o=a;if(In(t),a=uc(e,t,n,o,l,i),r=cc(),e!==null&&!de)return fc(e,t,i),Qt(e,t,i);return G&&r&&tc(t),t.flags|=1,ye(e,t,a,i),t.child}function Gd(e,t,n,a,i){if(e===null){var l=n.type;if(typeof l==="function"&&!ec(l)&&l.defaultProps===void 0&&n.compare===null)return t.tag=15,t.type=l,lm(e,t,l,a,i);return e=so(n.type,null,a,t,t.mode,i),e.ref=t.ref,e.return=t,t.child=e}if(l=e.child,!xc(e,i)){var o=l.memoizedProps;if(n=n.compare,n=n!==null?n:nl,n(o,a)&&e.ref===t.ref)return Qt(e,t,i)}return t.flags|=1,e=jt(l,a),e.ref=t.ref,e.return=t,t.child=e}function lm(e,t,n,a,i){if(e!==null){var l=e.memoizedProps;if(nl(l,a)&&e.ref===t.ref)if(de=!1,t.pendingProps=a=l,xc(e,i))(e.flags&131072)!==0&&(de=!0);else return t.lanes=e.lanes,Qt(e,t,i)}return _u(e,t,n,a,i)}function om(e,t,n,a){var i=a.children,l=e!==null?e.memoizedState:null;if(e===null&&t.stateNode===null&&(t.stateNode={_visibility:1,_pendingMarkers:null,_retryCache:null,_transitions:null}),a.mode==="hidden"){if((t.flags&128)!==0){if(l=l!==null?l.baseLanes|n:n,e!==null){a=t.child=e.child;for(i=0;a!==null;)i=i|a.lanes|a.childLanes,a=a.sibling;a=i&~l}else a=0,t.child=null;return Yd(e,t,l,n,a)}if((n&536870912)!==0)t.memoizedState={baseLanes:0,cachePool:null},e!==null&&uo(t,l!==null?l.cachePool:null),l!==null?Rd(t,l):hu(),Sp(t);else return a=t.lanes=536870912,Yd(e,t,l!==null?l.baseLanes|n:n,n,a)}else l!==null?(uo(t,l.cachePool),Rd(t,l),un(t),t.memoizedState=null):(e!==null&&uo(t,null),hu(),un(t));return ye(e,t,i,n),t.child}function Vi(e,t){return e!==null&&e.tag===22||t.stateNode!==null||(t.stateNode={_visibility:1,_pendingMarkers:null,_retryCache:null,_transitions:null}),t.sibling}function Yd(e,t,n,a,i){var l=ic();return l=l===null?null:{parent:fe._currentValue,pool:l},t.memoizedState={baseLanes:n,cachePool:l},e!==null&&uo(t,null),hu(),Sp(t),e!==null&&ni(e,t,a,!0),t.childLanes=i,null}function ho(e,t){return t=ko({mode:t.mode,children:t.children},e.mode),t.ref=e.ref,e.child=t,t.return=e,t}function Kd(e,t,n){return Pn(t,e.child,null,n),e=ho(t,t.pendingProps),e.flags|=2,Ve(t),t.memoizedState=null,e}function Z1(e,t,n){var a=t.pendingProps,i=(t.flags&128)!==0;if(t.flags&=-129,e===null){if(G){if(a.mode==="hidden")return e=ho(t,a),t.lanes=536870912,Vi(null,e);if(pu(t),(e=ne)?(e=Im(e,nt),e=e!==null&&e.data==="&"?e:null,e!==null&&(t.memoizedState={dehydrated:e,treeContext:Nn!==null?{id:St,overflow:xt}:null,retryLane:536870912,hydrationErrors:null},n=fp(e),n.return=t,t.child=n,Se=t,ne=null)):e=null,e===null)throw On(t);return t.lanes=536870912,null}return ho(t,a)}var l=e.memoizedState;if(l!==null){var o=l.dehydrated;if(pu(t),i)if(t.flags&256)t.flags&=-257,t=Kd(e,t,n);else if(t.memoizedState!==null)t.child=e.child,t.flags|=128,t=null;else throw Error(S(558));else if(de||ni(e,t,n,!1),i=(n&e.childLanes)!==0,de||i){if(a=F,a!==null&&(o=Lh(a,n),o!==0&&o!==l.retryLane))throw l.retryLane=o,la(e,o),Me(a,e,o),Sc;Ho(),t=Kd(e,t,n)}else e=l.treeContext,ne=it(o.nextSibling),Se=t,G=!0,gn=null,nt=!1,e!==null&&hp(t,e),t=ho(t,a),t.flags|=4096;return t}return e=jt(e.child,{mode:a.mode,children:a.children}),e.ref=t.ref,t.child=e,e.return=t,e}function po(e,t){var n=t.ref;if(n===null)e!==null&&e.ref!==null&&(t.flags|=4194816);else{if(typeof n!=="function"&&typeof n!=="object")throw Error(S(284));if(e===null||e.ref!==n)t.flags|=4194816}}function _u(e,t,n,a,i){if(In(t),n=uc(e,t,n,a,void 0,i),a=cc(),e!==null&&!de)return fc(e,t,i),Qt(e,t,i);return G&&a&&tc(t),t.flags|=1,ye(e,t,n,i),t.child}function Xd(e,t,n,a,i,l){if(In(t),t.updateQueue=null,n=Ep(t,a,n,i),xp(e),a=cc(),e!==null&&!de)return fc(e,t,l),Qt(e,t,l);return G&&a&&tc(t),t.flags|=1,ye(e,t,n,l),t.child}function Qd(e,t,n,a,i){if(In(t),t.stateNode===null){var l=Ma,o=n.contextType;typeof o==="object"&&o!==null&&(l=xe(o)),l=new n(a,l),t.memoizedState=l.state!==null&&l.state!==void 0?l.state:null,l.updater=bu,t.stateNode=l,l._reactInternals=t,l=t.stateNode,l.props=a,l.state=t.memoizedState,l.refs={},oc(t),o=n.contextType,l.context=typeof o==="object"&&o!==null?xe(o):Ma,l.state=t.memoizedState,o=n.getDerivedStateFromProps,typeof o==="function"&&(Os(t,n,o,a),l.state=t.memoizedState),typeof n.getDerivedStateFromProps==="function"||typeof l.getSnapshotBeforeUpdate==="function"||typeof l.UNSAFE_componentWillMount!=="function"&&typeof l.componentWillMount!=="function"||(o=l.state,typeof l.componentWillMount==="function"&&l.componentWillMount(),typeof l.UNSAFE_componentWillMount==="function"&&l.UNSAFE_componentWillMount(),o!==l.state&&bu.enqueueReplaceState(l,l.state,null),Qi(t,a,l,i),Xi(),l.state=t.memoizedState),typeof l.componentDidMount==="function"&&(t.flags|=4194308),a=!0}else if(e===null){l=t.stateNode;var r=t.memoizedProps,s=ta(n,r);l.props=s;var c=l.context,m=n.contextType;o=Ma,typeof m==="object"&&m!==null&&(o=xe(m));var b=n.getDerivedStateFromProps;m=typeof b==="function"||typeof l.getSnapshotBeforeUpdate==="function",r=t.pendingProps!==r,m||typeof l.UNSAFE_componentWillReceiveProps!=="function"&&typeof l.componentWillReceiveProps!=="function"||(r||c!==o)&&Hd(t,l,a,o),on=!1;var h=t.memoizedState;l.state=h,Qi(t,a,l,i),Xi(),c=t.memoizedState,r||h!==c||on?(typeof b==="function"&&(Os(t,n,b,a),c=t.memoizedState),(s=on||Bd(t,n,s,a,h,c,o))?(m||typeof l.UNSAFE_componentWillMount!=="function"&&typeof l.componentWillMount!=="function"||(typeof l.componentWillMount==="function"&&l.componentWillMount(),typeof l.UNSAFE_componentWillMount==="function"&&l.UNSAFE_componentWillMount()),typeof l.componentDidMount==="function"&&(t.flags|=4194308)):(typeof l.componentDidMount==="function"&&(t.flags|=4194308),t.memoizedProps=a,t.memoizedState=c),l.props=a,l.state=c,l.context=o,a=s):(typeof l.componentDidMount==="function"&&(t.flags|=4194308),a=!1)}else{l=t.stateNode,fu(e,t),o=t.memoizedProps,m=ta(n,o),l.props=m,b=t.pendingProps,h=l.context,c=n.contextType,s=Ma,typeof c==="object"&&c!==null&&(s=xe(c)),r=n.getDerivedStateFromProps,(c=typeof r==="function"||typeof l.getSnapshotBeforeUpdate==="function")||typeof l.UNSAFE_componentWillReceiveProps!=="function"&&typeof l.componentWillReceiveProps!=="function"||(o!==b||h!==s)&&Hd(t,l,a,s),on=!1,h=t.memoizedState,l.state=h,Qi(t,a,l,i),Xi();var g=t.memoizedState;o!==b||h!==g||on||e!==null&&e.dependencies!==null&&To(e.dependencies)?(typeof r==="function"&&(Os(t,n,r,a),g=t.memoizedState),(m=on||Bd(t,n,m,a,h,g,s)||e!==null&&e.dependencies!==null&&To(e.dependencies))?(c||typeof l.UNSAFE_componentWillUpdate!=="function"&&typeof l.componentWillUpdate!=="function"||(typeof l.componentWillUpdate==="function"&&l.componentWillUpdate(a,g,s),typeof l.UNSAFE_componentWillUpdate==="function"&&l.UNSAFE_componentWillUpdate(a,g,s)),typeof l.componentDidUpdate==="function"&&(t.flags|=4),typeof l.getSnapshotBeforeUpdate==="function"&&(t.flags|=1024)):(typeof l.componentDidUpdate!=="function"||o===e.memoizedProps&&h===e.memoizedState||(t.flags|=4),typeof l.getSnapshotBeforeUpdate!=="function"||o===e.memoizedProps&&h===e.memoizedState||(t.flags|=1024),t.memoizedProps=a,t.memoizedState=g),l.props=a,l.state=g,l.context=s,a=m):(typeof l.componentDidUpdate!=="function"||o===e.memoizedProps&&h===e.memoizedState||(t.flags|=4),typeof l.getSnapshotBeforeUpdate!=="function"||o===e.memoizedProps&&h===e.memoizedState||(t.flags|=1024),a=!1)}return l=a,po(e,t),a=(t.flags&128)!==0,l||a?(l=t.stateNode,n=a&&typeof n.getDerivedStateFromError!=="function"?null:l.render(),t.flags|=1,e!==null&&a?(t.child=Pn(t,e.child,null,i),t.child=Pn(t,null,n,i)):ye(e,t,n,i),t.memoizedState=l.state,e=t.child):e=Qt(e,t,i),e}function Zd(e,t,n,a){return Wn(),t.flags|=256,ye(e,t,n,a),t.child}function Ts(e){return{baseLanes:e,cachePool:mp()}}function Ds(e,t,n){return e=e!==null?e.childLanes&~n:0,t&&(e|=Be),e}function rm(e,t,n){var a=t.pendingProps,i=!1,l=(t.flags&128)!==0,o;if((o=l)||(o=e!==null&&e.memoizedState===null?!1:(re.current&2)!==0),o&&(i=!0,t.flags&=-129),o=(t.flags&32)!==0,t.flags&=-33,e===null){if(G){if(i?sn(t):un(t),(e=ne)?(e=Im(e,nt),e=e!==null&&e.data!=="&"?e:null,e!==null&&(t.memoizedState={dehydrated:e,treeContext:Nn!==null?{id:St,overflow:xt}:null,retryLane:536870912,hydrationErrors:null},n=fp(e),n.return=t,t.child=n,Se=t,ne=null)):e=null,e===null)throw On(t);return Vu(e)?t.lanes=32:t.lanes=536870912,null}var r=a.children;if(a=a.fallback,i)return un(t),i=t.mode,r=ko({mode:"hidden",children:r},i),a=Zn(a,i,n,null),r.return=t,a.return=t,r.sibling=a,t.child=r,a=t.child,a.memoizedState=Ts(n),a.childLanes=Ds(e,o,n),t.memoizedState=As,Vi(null,a);return sn(t),Su(t,r)}var s=e.memoizedState;if(s!==null&&(r=s.dehydrated,r!==null)){if(l)t.flags&256?(sn(t),t.flags&=-257,t=zs(e,t,n)):t.memoizedState!==null?(un(t),t.child=e.child,t.flags|=128,t=null):(un(t),r=a.fallback,i=t.mode,a=ko({mode:"visible",children:a.children},i),r=Zn(r,i,n,null),r.flags|=2,a.return=t,r.return=t,a.sibling=r,t.child=a,Pn(t,e.child,null,n),a=t.child,a.memoizedState=Ts(n),a.childLanes=Ds(e,o,n),t.memoizedState=As,t=Vi(null,a));else if(sn(t),Vu(r)){if(o=r.nextSibling&&r.nextSibling.dataset,o)var c=o.dgst;o=c,a=Error(S(419)),a.stack="",a.digest=o,il({value:a,source:null,stack:null}),t=zs(e,t,n)}else if(de||ni(e,t,n,!1),o=(n&e.childLanes)!==0,de||o){if(o=F,o!==null&&(a=Lh(o,n),a!==0&&a!==s.retryLane))throw s.retryLane=a,la(e,a),Me(o,e,a),Sc;ku(r)||Ho(),t=zs(e,t,n)}else ku(r)?(t.flags|=192,t.child=e.child,t=null):(e=s.treeContext,ne=it(r.nextSibling),Se=t,G=!0,gn=null,nt=!1,e!==null&&hp(t,e),t=Su(t,a.children),t.flags|=4096);return t}if(i)return un(t),r=a.fallback,i=t.mode,s=e.child,c=s.sibling,a=jt(s,{mode:"hidden",children:a.children}),a.subtreeFlags=s.subtreeFlags&65011712,c!==null?r=jt(c,r):(r=Zn(r,i,n,null),r.flags|=2),r.return=t,a.return=t,a.sibling=r,t.child=a,Vi(null,a),a=t.child,r=e.child.memoizedState,r===null?r=Ts(n):(i=r.cachePool,i!==null?(s=fe._currentValue,i=i.parent!==s?{parent:s,pool:s}:i):i=mp(),r={baseLanes:r.baseLanes|n,cachePool:i}),a.memoizedState=r,a.childLanes=Ds(e,o,n),t.memoizedState=As,Vi(e.child,a);return sn(t),n=e.child,e=n.sibling,n=jt(n,{mode:"visible",children:a.children}),n.return=t,n.sibling=null,e!==null&&(o=t.deletions,o===null?(t.deletions=[e],t.flags|=16):o.push(e)),t.child=n,t.memoizedState=null,n}function Su(e,t){return t=ko({mode:"visible",children:t},e.mode),t.return=e,e.child=t}function ko(e,t){return e=Le(22,e,null,t),e.lanes=0,e}function zs(e,t,n){return Pn(t,e.child,null,n),e=Su(t,t.pendingProps.children),e.flags|=2,t.memoizedState=null,e}function $d(e,t,n){e.lanes|=t;var a=e.alternate;a!==null&&(a.lanes|=t),su(e.return,t,n)}function Rs(e,t,n,a,i,l){var o=e.memoizedState;o===null?e.memoizedState={isBackwards:t,rendering:null,renderingStartTime:0,last:a,tail:n,tailMode:i,treeForkCount:l}:(o.isBackwards=t,o.rendering=null,o.renderingStartTime=0,o.last=a,o.tail=n,o.tailMode=i,o.treeForkCount=l)}function sm(e,t,n){var a=t.pendingProps,i=a.revealOrder,l=a.tail;a=a.children;var o=re.current,r=(o&2)!==0;if(r?(o=o&1|2,t.flags|=128):o&=1,W(re,o),ye(e,t,a,n),a=G?al:0,!r&&e!==null&&(e.flags&128)!==0)e:for(e=t.child;e!==null;){if(e.tag===13)e.memoizedState!==null&&$d(e,n,t);else if(e.tag===19)$d(e,n,t);else if(e.child!==null){e.child.return=e,e=e.child;continue}if(e===t)break e;for(;e.sibling===null;){if(e.return===null||e.return===t)break e;e=e.return}e.sibling.return=e.return,e=e.sibling}switch(i){case"forwards":n=t.child;for(i=null;n!==null;)e=n.alternate,e!==null&&Ro(e)===null&&(i=n),n=n.sibling;n=i,n===null?(i=t.child,t.child=null):(i=n.sibling,n.sibling=null),Rs(t,!1,i,n,l,a);break;case"backwards":case"unstable_legacy-backwards":n=null,i=t.child;for(t.child=null;i!==null;){if(e=i.alternate,e!==null&&Ro(e)===null){t.child=i;break}e=i.sibling,i.sibling=n,n=i,i=e}Rs(t,!0,n,null,l,a);break;case"together":Rs(t,!1,null,null,void 0,a);break;default:t.memoizedState=null}return t.child}function Qt(e,t,n){if(e!==null&&(t.dependencies=e.dependencies),Tn|=t.lanes,(n&t.childLanes)===0)if(e!==null){if(ni(e,t,n,!1),(n&t.childLanes)===0)return null}else return null;if(e!==null&&t.child!==e.child)throw Error(S(153));if(t.child!==null){e=t.child,n=jt(e,e.pendingProps),t.child=n;for(n.return=t;e.sibling!==null;)e=e.sibling,n=n.sibling=jt(e,e.pendingProps),n.return=t;n.sibling=null}return t.child}function xc(e,t){if((e.lanes&t)!==0)return!0;return e=e.dependencies,e!==null&&To(e)?!0:!1}function $1(e,t,n){switch(t.tag){case 3:So(t,t.stateNode.containerInfo),rn(t,fe,e.memoizedState.cache),Wn();break;case 27:case 5:Js(t);break;case 4:So(t,t.stateNode.containerInfo);break;case 10:rn(t,t.type,t.memoizedProps.value);break;case 31:if(t.memoizedState!==null)return t.flags|=128,pu(t),null;break;case 13:var a=t.memoizedState;if(a!==null){if(a.dehydrated!==null)return sn(t),t.flags|=128,null;if((n&t.child.childLanes)!==0)return rm(e,t,n);return sn(t),e=Qt(e,t,n),e!==null?e.sibling:null}sn(t);break;case 19:var i=(e.flags&128)!==0;if(a=(n&t.childLanes)!==0,a||(ni(e,t,n,!1),a=(n&t.childLanes)!==0),i){if(a)return sm(e,t,n);t.flags|=128}if(i=t.memoizedState,i!==null&&(i.rendering=null,i.tail=null,i.lastEffect=null),W(re,re.current),a)break;else return null;case 22:return t.lanes=0,om(e,t,n,t.pendingProps);case 24:rn(t,fe,e.memoizedState.cache)}return Qt(e,t,n)}function um(e,t,n){if(e!==null)if(e.memoizedProps!==t.pendingProps)de=!0;else{if(!xc(e,n)&&(t.flags&128)===0)return de=!1,$1(e,t,n);de=(e.flags&131072)!==0?!0:!1}else de=!1,G&&(t.flags&1048576)!==0&&dp(t,al,t.index);switch(t.lanes=0,t.tag){case 16:e:{var a=t.pendingProps;if(e=Kn(t.elementType),t.type=e,typeof e==="function")ec(e)?(a=ta(e,a),t.tag=1,t=Qd(null,t,e,a,n)):(t.tag=0,t=_u(null,t,e,a,n));else{if(e!==void 0&&e!==null){var i=e.$$typeof;if(i===ju){t.tag=11,t=qd(null,t,e,a,n);break e}else if(i===qu){t.tag=14,t=Gd(null,t,e,a,n);break e}}throw t=Zs(e)||e,Error(S(306,t,""))}}return t;case 0:return _u(e,t,t.type,t.pendingProps,n);case 1:return a=t.type,i=ta(a,t.pendingProps),Qd(e,t,a,i,n);case 3:e:{if(So(t,t.stateNode.containerInfo),e===null)throw Error(S(387));a=t.pendingProps;var l=t.memoizedState;i=l.element,fu(e,t),Qi(t,a,null,n);var o=t.memoizedState;if(a=o.cache,rn(t,fe,a),a!==l.cache&&uu(t,[fe],n,!0),Xi(),a=o.element,l.isDehydrated)if(l={element:a,isDehydrated:!1,cache:o.cache},t.updateQueue.baseState=l,t.memoizedState=l,t.flags&256){t=Zd(e,t,a,n);break e}else if(a!==i){i=tt(Error(S(424)),t),il(i),t=Zd(e,t,a,n);break e}else{switch(e=t.stateNode.containerInfo,e.nodeType){case 9:e=e.body;break;default:e=e.nodeName==="HTML"?e.ownerDocument.body:e}ne=it(e.firstChild),Se=t,G=!0,gn=null,nt=!0,n=bp(t,null,a,n);for(t.child=n;n;)n.flags=n.flags&-3|4096,n=n.sibling}else{if(Wn(),a===i){t=Qt(e,t,n);break e}ye(e,t,a,n)}t=t.child}return t;case 26:return po(e,t),e===null?(n=ph(t.type,null,t.pendingProps,null))?t.memoizedState=n:G||(n=t.type,e=t.pendingProps,a=Yo(vn.current).createElement(n),a[_e]=t,a[Ce]=e,Ee(a,n,e),ge(a),t.stateNode=a):t.memoizedState=ph(t.type,e.memoizedProps,t.pendingProps,e.memoizedState),null;case 27:return Js(t),e===null&&G&&(a=t.stateNode=Pm(t.type,t.pendingProps,vn.current),Se=t,nt=!0,i=ne,zn(t.type)?(Lu=i,ne=it(a.firstChild)):ne=i),ye(e,t,t.pendingProps.children,n),po(e,t),e===null&&(t.flags|=4194304),t.child;case 5:if(e===null&&G){if(i=a=ne)a=x_(a,t.type,t.pendingProps,nt),a!==null?(t.stateNode=a,Se=t,ne=it(a.firstChild),nt=!1,i=!0):i=!1;i||On(t)}return Js(t),i=t.type,l=t.pendingProps,o=e!==null?e.memoizedProps:null,a=l.children,Cu(i,l)?a=null:o!==null&&Cu(i,o)&&(t.flags|=32),t.memoizedState!==null&&(i=uc(e,t,H1,null,null,n),cl._currentValue=i),po(e,t),ye(e,t,a,n),t.child;case 6:if(e===null&&G){if(e=n=ne)n=E_(n,t.pendingProps,nt),n!==null?(t.stateNode=n,Se=t,ne=null,e=!0):e=!1;e||On(t)}return null;case 13:return rm(e,t,n);case 4:return So(t,t.stateNode.containerInfo),a=t.pendingProps,e===null?t.child=Pn(t,null,a,n):ye(e,t,a,n),t.child;case 11:return qd(e,t,t.type,t.pendingProps,n);case 7:return ye(e,t,t.pendingProps,n),t.child;case 8:return ye(e,t,t.pendingProps.children,n),t.child;case 12:return ye(e,t,t.pendingProps.children,n),t.child;case 10:return a=t.pendingProps,rn(t,t.type,a.value),ye(e,t,a.children,n),t.child;case 9:return i=t.type._context,a=t.pendingProps.children,In(t),i=xe(i),a=a(i),t.flags|=1,ye(e,t,a,n),t.child;case 14:return Gd(e,t,t.type,t.pendingProps,n);case 15:return lm(e,t,t.type,t.pendingProps,n);case 19:return sm(e,t,n);case 31:return Z1(e,t,n);case 22:return om(e,t,n,t.pendingProps);case 24:return In(t),a=xe(fe),e===null?(i=ic(),i===null&&(i=F,l=ac(),i.pooledCache=l,l.refCount++,l!==null&&(i.pooledCacheLanes|=n),i=l),t.memoizedState={parent:a,cache:i},oc(t),rn(t,fe,i)):((e.lanes&n)!==0&&(fu(e,t),Qi(t,null,null,n),Xi()),i=e.memoizedState,l=t.memoizedState,i.parent!==a?(i={parent:a,cache:a},t.memoizedState=i,t.lanes===0&&(t.memoizedState=t.updateQueue.baseState=i),rn(t,fe,a)):(a=l.cache,rn(t,fe,a),a!==i.cache&&uu(t,[fe],n,!0))),ye(e,t,t.pendingProps.children,n),t.child;case 29:throw t.pendingProps}throw Error(S(156,t.tag))}function Rt(e){e.flags|=4}function Ms(e,t,n,a,i){if(t=(e.mode&32)!==0)t=!1;if(t){if(e.flags|=16777216,(i&335544128)===i)if(e.stateNode.complete)e.flags|=8192;else if(Cm())e.flags|=8192;else throw Jn=Do,lc}else e.flags&=-16777217}function Jd(e,t){if(t.type!=="stylesheet"||(t.state.loading&4)!==0)e.flags&=-16777217;else if(e.flags|=16777216,!nv(t))if(Cm())e.flags|=8192;else throw Jn=Do,lc}function Il(e,t){t!==null&&(e.flags|=4),e.flags&16384&&(t=e.tag!==22?Uh():536870912,e.lanes|=t,Ja|=t)}function Ti(e,t){if(!G)switch(e.tailMode){case"hidden":t=e.tail;for(var n=null;t!==null;)t.alternate!==null&&(n=t),t=t.sibling;n===null?e.tail=null:n.sibling=null;break;case"collapsed":n=e.tail;for(var a=null;n!==null;)n.alternate!==null&&(a=n),n=n.sibling;a===null?t||e.tail===null?e.tail=null:e.tail.sibling=null:a.sibling=null}}function te(e){var t=e.alternate!==null&&e.alternate.child===e.child,n=0,a=0;if(t)for(var i=e.child;i!==null;)n|=i.lanes|i.childLanes,a|=i.subtreeFlags&65011712,a|=i.flags&65011712,i.return=e,i=i.sibling;else for(i=e.child;i!==null;)n|=i.lanes|i.childLanes,a|=i.subtreeFlags,a|=i.flags,i.return=e,i=i.sibling;return e.subtreeFlags|=a,e.childLanes=n,t}function J1(e,t,n){var a=t.pendingProps;switch(nc(t),t.tag){case 16:case 15:case 0:case 11:case 7:case 8:case 12:case 9:case 14:return te(t),null;case 1:return te(t),null;case 3:if(n=t.stateNode,a=null,e!==null&&(a=e.memoizedState.cache),t.memoizedState.cache!==a&&(t.flags|=2048),qt(fe),Ya(),n.pendingContext&&(n.context=n.pendingContext,n.pendingContext=null),e===null||e.child===null)ya(t)?Rt(t):e===null||e.memoizedState.isDehydrated&&(t.flags&256)===0||(t.flags|=1024,Es());return te(t),null;case 26:var{type:i,memoizedState:l}=t;return e===null?(Rt(t),l!==null?(te(t),Jd(t,l)):(te(t),Ms(t,i,null,a,n))):l?l!==e.memoizedState?(Rt(t),te(t),Jd(t,l)):(te(t),t.flags&=-16777217):(e=e.memoizedProps,e!==a&&Rt(t),te(t),Ms(t,i,e,a,n)),null;case 27:if(xo(t),n=vn.current,i=t.type,e!==null&&t.stateNode!=null)e.memoizedProps!==a&&Rt(t);else{if(!a){if(t.stateNode===null)throw Error(S(166));return te(t),null}e=wt.current,ya(t)?wd(t,e):(e=Pm(i,a,n),t.stateNode=e,Rt(t))}return te(t),null;case 5:if(xo(t),i=t.type,e!==null&&t.stateNode!=null)e.memoizedProps!==a&&Rt(t);else{if(!a){if(t.stateNode===null)throw Error(S(166));return te(t),null}if(l=wt.current,ya(t))wd(t,l);else{var o=Yo(vn.current);switch(l){case 1:l=o.createElementNS("http://www.w3.org/2000/svg",i);break;case 2:l=o.createElementNS("http://www.w3.org/1998/Math/MathML",i);break;default:switch(i){case"svg":l=o.createElementNS("http://www.w3.org/2000/svg",i);break;case"math":l=o.createElementNS("http://www.w3.org/1998/Math/MathML",i);break;case"script":l=o.createElement("div"),l.innerHTML="<script></script>",l=l.removeChild(l.firstChild);break;case"select":l=typeof a.is==="string"?o.createElement("select",{is:a.is}):o.createElement("select"),a.multiple?l.multiple=!0:a.size&&(l.size=a.size);break;default:l=typeof a.is==="string"?o.createElement(i,{is:a.is}):o.createElement(i)}}l[_e]=t,l[Ce]=a;e:for(o=t.child;o!==null;){if(o.tag===5||o.tag===6)l.appendChild(o.stateNode);else if(o.tag!==4&&o.tag!==27&&o.child!==null){o.child.return=o,o=o.child;continue}if(o===t)break e;for(;o.sibling===null;){if(o.return===null||o.return===t)break e;o=o.return}o.sibling.return=o.return,o=o.sibling}t.stateNode=l;e:switch(Ee(l,i,a),i){case"button":case"input":case"select":case"textarea":a=!!a.autoFocus;break e;case"img":a=!0;break e;default:a=!1}a&&Rt(t)}}return te(t),Ms(t,t.type,e===null?null:e.memoizedProps,t.pendingProps,n),null;case 6:if(e&&t.stateNode!=null)e.memoizedProps!==a&&Rt(t);else{if(typeof a!=="string"&&t.stateNode===null)throw Error(S(166));if(e=vn.current,ya(t)){if(e=t.stateNode,n=t.memoizedProps,a=null,i=Se,i!==null)switch(i.tag){case 27:case 5:a=i.memoizedProps}e[_e]=t,e=e.nodeValue===n||a!==null&&a.suppressHydrationWarning===!0||Jm(e.nodeValue,n)?!0:!1,e||On(t,!0)}else e=Yo(e).createTextNode(a),e[_e]=t,t.stateNode=e}return te(t),null;case 31:if(n=t.memoizedState,e===null||e.memoizedState!==null){if(a=ya(t),n!==null){if(e===null){if(!a)throw Error(S(318));if(e=t.memoizedState,e=e!==null?e.dehydrated:null,!e)throw Error(S(557));e[_e]=t}else Wn(),(t.flags&128)===0&&(t.memoizedState=null),t.flags|=4;te(t),e=!1}else n=Es(),e!==null&&e.memoizedState!==null&&(e.memoizedState.hydrationErrors=n),e=!0;if(!e){if(t.flags&256)return Ve(t),t;return Ve(t),null}if((t.flags&128)!==0)throw Error(S(558))}return te(t),null;case 13:if(a=t.memoizedState,e===null||e.memoizedState!==null&&e.memoizedState.dehydrated!==null){if(i=ya(t),a!==null&&a.dehydrated!==null){if(e===null){if(!i)throw Error(S(318));if(i=t.memoizedState,i=i!==null?i.dehydrated:null,!i)throw Error(S(317));i[_e]=t}else Wn(),(t.flags&128)===0&&(t.memoizedState=null),t.flags|=4;te(t),i=!1}else i=Es(),e!==null&&e.memoizedState!==null&&(e.memoizedState.hydrationErrors=i),i=!0;if(!i){if(t.flags&256)return Ve(t),t;return Ve(t),null}}if(Ve(t),(t.flags&128)!==0)return t.lanes=n,t;return n=a!==null,e=e!==null&&e.memoizedState!==null,n&&(a=t.child,i=null,a.alternate!==null&&a.alternate.memoizedState!==null&&a.alternate.memoizedState.cachePool!==null&&(i=a.alternate.memoizedState.cachePool.pool),l=null,a.memoizedState!==null&&a.memoizedState.cachePool!==null&&(l=a.memoizedState.cachePool.pool),l!==i&&(a.flags|=2048)),n!==e&&n&&(t.child.flags|=8192),Il(t,t.updateQueue),te(t),null;case 4:return Ya(),e===null&&Dc(t.stateNode.containerInfo),te(t),null;case 10:return qt(t.type),te(t),null;case 19:if(be(re),a=t.memoizedState,a===null)return te(t),null;if(i=(t.flags&128)!==0,l=a.rendering,l===null)if(i)Ti(a,!1);else{if(oe!==0||e!==null&&(e.flags&128)!==0)for(e=t.child;e!==null;){if(l=Ro(e),l!==null){t.flags|=128,Ti(a,!1),e=l.updateQueue,t.updateQueue=e,Il(t,e),t.subtreeFlags=0,e=n;for(n=t.child;n!==null;)cp(n,e),n=n.sibling;return W(re,re.current&1|2),G&&kt(t,a.treeForkCount),t.child}e=e.sibling}a.tail!==null&&He()>Lo&&(t.flags|=128,i=!0,Ti(a,!1),t.lanes=4194304)}else{if(!i)if(e=Ro(l),e!==null){if(t.flags|=128,i=!0,e=e.updateQueue,t.updateQueue=e,Il(t,e),Ti(a,!0),a.tail===null&&a.tailMode==="hidden"&&!l.alternate&&!G)return te(t),null}else 2*He()-a.renderingStartTime>Lo&&n!==536870912&&(t.flags|=128,i=!0,Ti(a,!1),t.lanes=4194304);a.isBackwards?(l.sibling=t.child,t.child=l):(e=a.last,e!==null?e.sibling=l:t.child=l,a.last=l)}if(a.tail!==null)return e=a.tail,a.rendering=e,a.tail=e.sibling,a.renderingStartTime=He(),e.sibling=null,n=re.current,W(re,i?n&1|2:n&1),G&&kt(t,a.treeForkCount),e;return te(t),null;case 22:case 23:return Ve(t),rc(),a=t.memoizedState!==null,e!==null?e.memoizedState!==null!==a&&(t.flags|=8192):a&&(t.flags|=8192),a?(n&536870912)!==0&&(t.flags&128)===0&&(te(t),t.subtreeFlags&6&&(t.flags|=8192)):te(t),n=t.updateQueue,n!==null&&Il(t,n.retryQueue),n=null,e!==null&&e.memoizedState!==null&&e.memoizedState.cachePool!==null&&(n=e.memoizedState.cachePool.pool),a=null,t.memoizedState!==null&&t.memoizedState.cachePool!==null&&(a=t.memoizedState.cachePool.pool),a!==n&&(t.flags|=2048),e!==null&&be($n),null;case 24:return n=null,e!==null&&(n=e.memoizedState.cache),t.memoizedState.cache!==n&&(t.flags|=2048),qt(fe),te(t),null;case 25:return null;case 30:return null}throw Error(S(156,t.tag))}function F1(e,t){switch(nc(t),t.tag){case 1:return e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 3:return qt(fe),Ya(),e=t.flags,(e&65536)!==0&&(e&128)===0?(t.flags=e&-65537|128,t):null;case 26:case 27:case 5:return xo(t),null;case 31:if(t.memoizedState!==null){if(Ve(t),t.alternate===null)throw Error(S(340));Wn()}return e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 13:if(Ve(t),e=t.memoizedState,e!==null&&e.dehydrated!==null){if(t.alternate===null)throw Error(S(340));Wn()}return e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 19:return be(re),null;case 4:return Ya(),null;case 10:return qt(t.type),null;case 22:case 23:return Ve(t),rc(),e!==null&&be($n),e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 24:return qt(fe),null;case 25:return null;default:return null}}function cm(e,t){switch(nc(t),t.tag){case 3:qt(fe),Ya();break;case 26:case 27:case 5:xo(t);break;case 4:Ya();break;case 31:t.memoizedState!==null&&Ve(t);break;case 13:Ve(t);break;case 19:be(re);break;case 10:qt(t.type);break;case 22:case 23:Ve(t),rc(),e!==null&&be($n);break;case 24:qt(fe)}}function Sl(e,t){try{var n=t.updateQueue,a=n!==null?n.lastEffect:null;if(a!==null){var i=a.next;n=i;do{if((n.tag&e)===e){a=void 0;var{create:l,inst:o}=n;a=l(),o.destroy=a}n=n.next}while(n!==i)}}catch(r){Z(t,t.return,r)}}function An(e,t,n){try{var a=t.updateQueue,i=a!==null?a.lastEffect:null;if(i!==null){var l=i.next;a=l;do{if((a.tag&e)===e){var o=a.inst,r=o.destroy;if(r!==void 0){o.destroy=void 0,i=t;var s=n,c=r;try{c()}catch(m){Z(i,s,m)}}}a=a.next}while(a!==l)}}catch(m){Z(t,t.return,m)}}function fm(e){var t=e.updateQueue;if(t!==null){var n=e.stateNode;try{_p(t,n)}catch(a){Z(e,e.return,a)}}}function dm(e,t,n){n.props=ta(e.type,e.memoizedProps),n.state=e.memoizedState;try{n.componentWillUnmount()}catch(a){Z(e,t,a)}}function $i(e,t){try{var n=e.ref;if(n!==null){switch(e.tag){case 26:case 27:case 5:var a=e.stateNode;break;case 30:a=e.stateNode;break;default:a=e.stateNode}typeof n==="function"?e.refCleanup=n(a):n.current=a}}catch(i){Z(e,t,i)}}function Et(e,t){var{ref:n,refCleanup:a}=e;if(n!==null)if(typeof a==="function")try{a()}catch(i){Z(e,t,i)}finally{e.refCleanup=null,e=e.alternate,e!=null&&(e.refCleanup=null)}else if(typeof n==="function")try{n(null)}catch(i){Z(e,t,i)}else n.current=null}function hm(e){var{type:t,memoizedProps:n,stateNode:a}=e;try{e:switch(t){case"button":case"input":case"select":case"textarea":n.autoFocus&&a.focus();break e;case"img":n.src?a.src=n.src:n.srcSet&&(a.srcset=n.srcSet)}}catch(i){Z(e,e.return,i)}}function Cs(e,t,n){try{var a=e.stateNode;v_(a,e.type,n,t),a[Ce]=t}catch(i){Z(e,e.return,i)}}function pm(e){return e.tag===5||e.tag===3||e.tag===26||e.tag===27&&zn(e.type)||e.tag===4}function Us(e){e:for(;;){for(;e.sibling===null;){if(e.return===null||pm(e.return))return null;e=e.return}e.sibling.return=e.return;for(e=e.sibling;e.tag!==5&&e.tag!==6&&e.tag!==18;){if(e.tag===27&&zn(e.type))continue e;if(e.flags&2)continue e;if(e.child===null||e.tag===4)continue e;else e.child.return=e,e=e.child}if(!(e.flags&2))return e.stateNode}}function xu(e,t,n){var a=e.tag;if(a===5||a===6)e=e.stateNode,t?(n.nodeType===9?n.body:n.nodeName==="HTML"?n.ownerDocument.body:n).insertBefore(e,t):(t=n.nodeType===9?n.body:n.nodeName==="HTML"?n.ownerDocument.body:n,t.appendChild(e),n=n._reactRootContainer,n!==null&&n!==void 0||t.onclick!==null||(t.onclick=Bt));else if(a!==4&&(a===27&&zn(e.type)&&(n=e.stateNode,t=null),e=e.child,e!==null))for(xu(e,t,n),e=e.sibling;e!==null;)xu(e,t,n),e=e.sibling}function Vo(e,t,n){var a=e.tag;if(a===5||a===6)e=e.stateNode,t?n.insertBefore(e,t):n.appendChild(e);else if(a!==4&&(a===27&&zn(e.type)&&(n=e.stateNode),e=e.child,e!==null))for(Vo(e,t,n),e=e.sibling;e!==null;)Vo(e,t,n),e=e.sibling}function mm(e){var{stateNode:t,memoizedProps:n}=e;try{for(var a=e.type,i=t.attributes;i.length;)t.removeAttributeNode(i[0]);Ee(t,a,n),t[_e]=e,t[Ce]=n}catch(l){Z(e,e.return,l)}}function W1(e,t){if(e=e.containerInfo,Ru=Zo,e=np(e),Wu(e)){if("selectionStart"in e)var n={start:e.selectionStart,end:e.selectionEnd};else e:{n=(n=e.ownerDocument)&&n.defaultView||window;var a=n.getSelection&&n.getSelection();if(a&&a.rangeCount!==0){n=a.anchorNode;var{anchorOffset:i,focusNode:l}=a;a=a.focusOffset;try{n.nodeType,l.nodeType}catch(A){n=null;break e}var o=0,r=-1,s=-1,c=0,m=0,b=e,h=null;t:for(;;){for(var g;;){if(b!==n||i!==0&&b.nodeType!==3||(r=o+i),b!==l||a!==0&&b.nodeType!==3||(s=o+a),b.nodeType===3&&(o+=b.nodeValue.length),(g=b.firstChild)===null)break;h=b,b=g}for(;;){if(b===e)break t;if(h===n&&++c===i&&(r=o),h===l&&++m===a&&(s=o),(g=b.nextSibling)!==null)break;b=h,h=b.parentNode}b=g}n=r===-1||s===-1?null:{start:r,end:s}}else n=null}n=n||{start:0,end:0}}else n=null;Mu={focusedElem:e,selectionRange:n},Zo=!1;for(ve=t;ve!==null;)if(t=ve,e=t.child,(t.subtreeFlags&1028)!==0&&e!==null)e.return=t,ve=e;else for(;ve!==null;){switch(t=ve,l=t.alternate,e=t.flags,t.tag){case 0:if((e&4)!==0&&(e=t.updateQueue,e=e!==null?e.events:null,e!==null))for(n=0;n<e.length;n++)i=e[n],i.ref.impl=i.nextImpl;break;case 11:case 15:break;case 1:if((e&1024)!==0&&l!==null){e=void 0,n=t,i=l.memoizedProps,l=l.memoizedState,a=n.stateNode;try{var x=ta(n.type,i);e=a.getSnapshotBeforeUpdate(x,l),a.__reactInternalSnapshotBeforeUpdate=e}catch(A){Z(n,n.return,A)}}break;case 3:if((e&1024)!==0){if(e=t.stateNode.containerInfo,n=e.nodeType,n===9)Uu(e);else if(n===1)switch(e.nodeName){case"HEAD":case"HTML":case"BODY":Uu(e);break;default:e.textContent=""}}break;case 5:case 26:case 27:case 6:case 4:case 17:break;default:if((e&1024)!==0)throw Error(S(163))}if(e=t.sibling,e!==null){e.return=t.return,ve=e;break}ve=t.return}}function vm(e,t,n){var a=n.flags;switch(n.tag){case 0:case 11:case 15:Ct(e,n),a&4&&Sl(5,n);break;case 1:if(Ct(e,n),a&4)if(e=n.stateNode,t===null)try{e.componentDidMount()}catch(o){Z(n,n.return,o)}else{var i=ta(n.type,t.memoizedProps);t=t.memoizedState;try{e.componentDidUpdate(i,t,e.__reactInternalSnapshotBeforeUpdate)}catch(o){Z(n,n.return,o)}}a&64&&fm(n),a&512&&$i(n,n.return);break;case 3:if(Ct(e,n),a&64&&(e=n.updateQueue,e!==null)){if(t=null,n.child!==null)switch(n.child.tag){case 27:case 5:t=n.child.stateNode;break;case 1:t=n.child.stateNode}try{_p(e,t)}catch(o){Z(n,n.return,o)}}break;case 27:t===null&&a&4&&mm(n);case 26:case 5:Ct(e,n),t===null&&a&4&&hm(n),a&512&&$i(n,n.return);break;case 12:Ct(e,n);break;case 31:Ct(e,n),a&4&&ym(e,n);break;case 13:Ct(e,n),a&4&&_m(e,n),a&64&&(e=n.memoizedState,e!==null&&(e=e.dehydrated,e!==null&&(n=o_.bind(null,n),w_(e,n))));break;case 22:if(a=n.memoizedState!==null||Vt,!a){t=t!==null&&t.memoizedState!==null||ce,i=Vt;var l=ce;Vt=a,(ce=t)&&!l?Ut(e,n,(n.subtreeFlags&8772)!==0):Ct(e,n),Vt=i,ce=l}break;case 30:break;default:Ct(e,n)}}function gm(e){var t=e.alternate;t!==null&&(e.alternate=null,gm(t)),e.child=null,e.deletions=null,e.sibling=null,e.tag===5&&(t=e.stateNode,t!==null&&Xu(t)),e.stateNode=null,e.return=null,e.dependencies=null,e.memoizedProps=null,e.memoizedState=null,e.pendingProps=null,e.stateNode=null,e.updateQueue=null}function Mt(e,t,n){for(n=n.child;n!==null;)bm(e,t,n),n=n.sibling}function bm(e,t,n){if(je&&typeof je.onCommitFiberUnmount==="function")try{je.onCommitFiberUnmount(pl,n)}catch(l){}switch(n.tag){case 26:ce||Et(n,t),Mt(e,t,n),n.memoizedState?n.memoizedState.count--:n.stateNode&&(n=n.stateNode,n.parentNode.removeChild(n));break;case 27:ce||Et(n,t);var a=ie,i=ze;zn(n.type)&&(ie=n.stateNode,ze=!1),Mt(e,t,n),Ii(n.stateNode),ie=a,ze=i;break;case 5:ce||Et(n,t);case 6:if(a=ie,i=ze,ie=null,Mt(e,t,n),ie=a,ze=i,ie!==null)if(ze)try{(ie.nodeType===9?ie.body:ie.nodeName==="HTML"?ie.ownerDocument.body:ie).removeChild(n.stateNode)}catch(l){Z(n,t,l)}else try{ie.removeChild(n.stateNode)}catch(l){Z(n,t,l)}break;case 18:ie!==null&&(ze?(e=ie,uh(e.nodeType===9?e.body:e.nodeName==="HTML"?e.ownerDocument.body:e,n.stateNode),Pa(e)):uh(ie,n.stateNode));break;case 4:a=ie,i=ze,ie=n.stateNode.containerInfo,ze=!0,Mt(e,t,n),ie=a,ze=i;break;case 0:case 11:case 14:case 15:An(2,n,t),ce||An(4,n,t),Mt(e,t,n);break;case 1:ce||(Et(n,t),a=n.stateNode,typeof a.componentWillUnmount==="function"&&dm(n,t,a)),Mt(e,t,n);break;case 21:Mt(e,t,n);break;case 22:ce=(a=ce)||n.memoizedState!==null,Mt(e,t,n),ce=a;break;default:Mt(e,t,n)}}function ym(e,t){if(t.memoizedState===null&&(e=t.alternate,e!==null&&(e=e.memoizedState,e!==null))){e=e.dehydrated;try{Pa(e)}catch(n){Z(t,t.return,n)}}}function _m(e,t){if(t.memoizedState===null&&(e=t.alternate,e!==null&&(e=e.memoizedState,e!==null&&(e=e.dehydrated,e!==null))))try{Pa(e)}catch(n){Z(t,t.return,n)}}function I1(e){switch(e.tag){case 31:case 13:case 19:var t=e.stateNode;return t===null&&(t=e.stateNode=new Fd),t;case 22:return e=e.stateNode,t=e._retryCache,t===null&&(t=e._retryCache=new Fd),t;default:throw Error(S(435,e.tag))}}function Pl(e,t){var n=I1(e);t.forEach(function(a){if(!n.has(a)){n.add(a);var i=r_.bind(null,e,a);a.then(i,i)}})}function Te(e,t){var n=t.deletions;if(n!==null)for(var a=0;a<n.length;a++){var i=n[a],l=e,o=t,r=o;e:for(;r!==null;){switch(r.tag){case 27:if(zn(r.type)){ie=r.stateNode,ze=!1;break e}break;case 5:ie=r.stateNode,ze=!1;break e;case 3:case 4:ie=r.stateNode.containerInfo,ze=!0;break e}r=r.return}if(ie===null)throw Error(S(160));bm(l,o,i),ie=null,ze=!1,l=i.alternate,l!==null&&(l.return=null),i.return=null}if(t.subtreeFlags&13886)for(t=t.child;t!==null;)Sm(t,e),t=t.sibling}function Sm(e,t){var{alternate:n,flags:a}=e;switch(e.tag){case 0:case 11:case 14:case 15:Te(t,e),De(e),a&4&&(An(3,e,e.return),Sl(3,e),An(5,e,e.return));break;case 1:Te(t,e),De(e),a&512&&(ce||n===null||Et(n,n.return)),a&64&&Vt&&(e=e.updateQueue,e!==null&&(a=e.callbacks,a!==null&&(n=e.shared.hiddenCallbacks,e.shared.hiddenCallbacks=n===null?a:n.concat(a))));break;case 26:var i=ht;if(Te(t,e),De(e),a&512&&(ce||n===null||Et(n,n.return)),a&4){var l=n!==null?n.memoizedState:null;if(a=e.memoizedState,n===null)if(a===null)if(e.stateNode===null){e:{a=e.type,n=e.memoizedProps,i=i.ownerDocument||i;t:switch(a){case"title":if(l=i.getElementsByTagName("title")[0],!l||l[gl]||l[_e]||l.namespaceURI==="http://www.w3.org/2000/svg"||l.hasAttribute("itemprop"))l=i.createElement(a),i.head.insertBefore(l,i.querySelector("head > title"));Ee(l,a,n),l[_e]=e,ge(l),a=l;break e;case"link":var o=vh("link","href",i).get(a+(n.href||""));if(o){for(var r=0;r<o.length;r++)if(l=o[r],l.getAttribute("href")===(n.href==null||n.href===""?null:n.href)&&l.getAttribute("rel")===(n.rel==null?null:n.rel)&&l.getAttribute("title")===(n.title==null?null:n.title)&&l.getAttribute("crossorigin")===(n.crossOrigin==null?null:n.crossOrigin)){o.splice(r,1);break t}}l=i.createElement(a),Ee(l,a,n),i.head.appendChild(l);break;case"meta":if(o=vh("meta","content",i).get(a+(n.content||""))){for(r=0;r<o.length;r++)if(l=o[r],l.getAttribute("content")===(n.content==null?null:""+n.content)&&l.getAttribute("name")===(n.name==null?null:n.name)&&l.getAttribute("property")===(n.property==null?null:n.property)&&l.getAttribute("http-equiv")===(n.httpEquiv==null?null:n.httpEquiv)&&l.getAttribute("charset")===(n.charSet==null?null:n.charSet)){o.splice(r,1);break t}}l=i.createElement(a),Ee(l,a,n),i.head.appendChild(l);break;default:throw Error(S(468,a))}l[_e]=e,ge(l),a=l}e.stateNode=a}else gh(i,e.type,e.stateNode);else e.stateNode=mh(i,a,e.memoizedProps);else l!==a?(l===null?n.stateNode!==null&&(n=n.stateNode,n.parentNode.removeChild(n)):l.count--,a===null?gh(i,e.type,e.stateNode):mh(i,a,e.memoizedProps)):a===null&&e.stateNode!==null&&Cs(e,e.memoizedProps,n.memoizedProps)}break;case 27:Te(t,e),De(e),a&512&&(ce||n===null||Et(n,n.return)),n!==null&&a&4&&Cs(e,e.memoizedProps,n.memoizedProps);break;case 5:if(Te(t,e),De(e),a&512&&(ce||n===null||Et(n,n.return)),e.flags&32){i=e.stateNode;try{Xa(i,"")}catch(x){Z(e,e.return,x)}}a&4&&e.stateNode!=null&&(i=e.memoizedProps,Cs(e,i,n!==null?n.memoizedProps:i)),a&1024&&(ks=!0);break;case 6:if(Te(t,e),De(e),a&4){if(e.stateNode===null)throw Error(S(162));a=e.memoizedProps,n=e.stateNode;try{n.nodeValue=a}catch(x){Z(e,e.return,x)}}break;case 3:if(go=null,i=ht,ht=Ko(t.containerInfo),Te(t,e),ht=i,De(e),a&4&&n!==null&&n.memoizedState.isDehydrated)try{Pa(t.containerInfo)}catch(x){Z(e,e.return,x)}ks&&(ks=!1,xm(e));break;case 4:a=ht,ht=Ko(e.stateNode.containerInfo),Te(t,e),De(e),ht=a;break;case 12:Te(t,e),De(e);break;case 31:Te(t,e),De(e),a&4&&(a=e.updateQueue,a!==null&&(e.updateQueue=null,Pl(e,a)));break;case 13:Te(t,e),De(e),e.child.flags&8192&&e.memoizedState!==null!==(n!==null&&n.memoizedState!==null)&&(rr=He()),a&4&&(a=e.updateQueue,a!==null&&(e.updateQueue=null,Pl(e,a)));break;case 22:i=e.memoizedState!==null;var s=n!==null&&n.memoizedState!==null,c=Vt,m=ce;if(Vt=c||i,ce=m||s,Te(t,e),ce=m,Vt=c,De(e),a&8192)e:for(t=e.stateNode,t._visibility=i?t._visibility&-2:t._visibility|1,i&&(n===null||s||Vt||ce||Xn(e)),n=null,t=e;;){if(t.tag===5||t.tag===26){if(n===null){s=n=t;try{if(l=s.stateNode,i)o=l.style,typeof o.setProperty==="function"?o.setProperty("display","none","important"):o.display="none";else{r=s.stateNode;var b=s.memoizedProps.style,h=b!==void 0&&b!==null&&b.hasOwnProperty("display")?b.display:null;r.style.display=h==null||typeof h==="boolean"?"":(""+h).trim()}}catch(x){Z(s,s.return,x)}}}else if(t.tag===6){if(n===null){s=t;try{s.stateNode.nodeValue=i?"":s.memoizedProps}catch(x){Z(s,s.return,x)}}}else if(t.tag===18){if(n===null){s=t;try{var g=s.stateNode;i?ch(g,!0):ch(s.stateNode,!1)}catch(x){Z(s,s.return,x)}}}else if((t.tag!==22&&t.tag!==23||t.memoizedState===null||t===e)&&t.child!==null){t.child.return=t,t=t.child;continue}if(t===e)break e;for(;t.sibling===null;){if(t.return===null||t.return===e)break e;n===t&&(n=null),t=t.return}n===t&&(n=null),t.sibling.return=t.return,t=t.sibling}a&4&&(a=e.updateQueue,a!==null&&(n=a.retryQueue,n!==null&&(a.retryQueue=null,Pl(e,n))));break;case 19:Te(t,e),De(e),a&4&&(a=e.updateQueue,a!==null&&(e.updateQueue=null,Pl(e,a)));break;case 30:break;case 21:break;default:Te(t,e),De(e)}}function De(e){var t=e.flags;if(t&2){try{for(var n,a=e.return;a!==null;){if(pm(a)){n=a;break}a=a.return}if(n==null)throw Error(S(160));switch(n.tag){case 27:var i=n.stateNode,l=Us(e);Vo(e,l,i);break;case 5:var o=n.stateNode;n.flags&32&&(Xa(o,""),n.flags&=-33);var r=Us(e);Vo(e,r,o);break;case 3:case 4:var s=n.stateNode.containerInfo,c=Us(e);xu(e,c,s);break;default:throw Error(S(161))}}catch(m){Z(e,e.return,m)}e.flags&=-3}t&4096&&(e.flags&=-4097)}function xm(e){if(e.subtreeFlags&1024)for(e=e.child;e!==null;){var t=e;xm(t),t.tag===5&&t.flags&1024&&t.stateNode.reset(),e=e.sibling}}function Ct(e,t){if(t.subtreeFlags&8772)for(t=t.child;t!==null;)vm(e,t.alternate,t),t=t.sibling}function Xn(e){for(e=e.child;e!==null;){var t=e;switch(t.tag){case 0:case 11:case 14:case 15:An(4,t,t.return),Xn(t);break;case 1:Et(t,t.return);var n=t.stateNode;typeof n.componentWillUnmount==="function"&&dm(t,t.return,n),Xn(t);break;case 27:Ii(t.stateNode);case 26:case 5:Et(t,t.return),Xn(t);break;case 22:t.memoizedState===null&&Xn(t);break;case 30:Xn(t);break;default:Xn(t)}e=e.sibling}}function Ut(e,t,n){n=n&&(t.subtreeFlags&8772)!==0;for(t=t.child;t!==null;){var a=t.alternate,i=e,l=t,o=l.flags;switch(l.tag){case 0:case 11:case 15:Ut(i,l,n),Sl(4,l);break;case 1:if(Ut(i,l,n),a=l,i=a.stateNode,typeof i.componentDidMount==="function")try{i.componentDidMount()}catch(c){Z(a,a.return,c)}if(a=l,i=a.updateQueue,i!==null){var r=a.stateNode;try{var s=i.shared.hiddenCallbacks;if(s!==null)for(i.shared.hiddenCallbacks=null,i=0;i<s.length;i++)yp(s[i],r)}catch(c){Z(a,a.return,c)}}n&&o&64&&fm(l),$i(l,l.return);break;case 27:mm(l);case 26:case 5:Ut(i,l,n),n&&a===null&&o&4&&hm(l),$i(l,l.return);break;case 12:Ut(i,l,n);break;case 31:Ut(i,l,n),n&&o&4&&ym(i,l);break;case 13:Ut(i,l,n),n&&o&4&&_m(i,l);break;case 22:l.memoizedState===null&&Ut(i,l,n),$i(l,l.return);break;case 30:break;default:Ut(i,l,n)}t=t.sibling}}function Ec(e,t){var n=null;e!==null&&e.memoizedState!==null&&e.memoizedState.cachePool!==null&&(n=e.memoizedState.cachePool.pool),e=null,t.memoizedState!==null&&t.memoizedState.cachePool!==null&&(e=t.memoizedState.cachePool.pool),e!==n&&(e!=null&&e.refCount++,n!=null&&yl(n))}function wc(e,t){e=null,t.alternate!==null&&(e=t.alternate.memoizedState.cache),t=t.memoizedState.cache,t!==e&&(t.refCount++,e!=null&&yl(e))}function dt(e,t,n,a){if(t.subtreeFlags&10256)for(t=t.child;t!==null;)Em(e,t,n,a),t=t.sibling}function Em(e,t,n,a){var i=t.flags;switch(t.tag){case 0:case 11:case 15:dt(e,t,n,a),i&2048&&Sl(9,t);break;case 1:dt(e,t,n,a);break;case 3:dt(e,t,n,a),i&2048&&(e=null,t.alternate!==null&&(e=t.alternate.memoizedState.cache),t=t.memoizedState.cache,t!==e&&(t.refCount++,e!=null&&yl(e)));break;case 12:if(i&2048){dt(e,t,n,a),e=t.stateNode;try{var l=t.memoizedProps,o=l.id,r=l.onPostCommit;typeof r==="function"&&r(o,t.alternate===null?"mount":"update",e.passiveEffectDuration,-0)}catch(s){Z(t,t.return,s)}}else dt(e,t,n,a);break;case 31:dt(e,t,n,a);break;case 13:dt(e,t,n,a);break;case 23:break;case 22:l=t.stateNode,o=t.alternate,t.memoizedState!==null?l._visibility&2?dt(e,t,n,a):Ji(e,t):l._visibility&2?dt(e,t,n,a):(l._visibility|=2,Sa(e,t,n,a,(t.subtreeFlags&10256)!==0||!1)),i&2048&&Ec(o,t);break;case 24:dt(e,t,n,a),i&2048&&wc(t.alternate,t);break;default:dt(e,t,n,a)}}function Sa(e,t,n,a,i){i=i&&((t.subtreeFlags&10256)!==0||!1);for(t=t.child;t!==null;){var l=e,o=t,r=n,s=a,c=o.flags;switch(o.tag){case 0:case 11:case 15:Sa(l,o,r,s,i),Sl(8,o);break;case 23:break;case 22:var m=o.stateNode;o.memoizedState!==null?m._visibility&2?Sa(l,o,r,s,i):Ji(l,o):(m._visibility|=2,Sa(l,o,r,s,i)),i&&c&2048&&Ec(o.alternate,o);break;case 24:Sa(l,o,r,s,i),i&&c&2048&&wc(o.alternate,o);break;default:Sa(l,o,r,s,i)}t=t.sibling}}function Ji(e,t){if(t.subtreeFlags&10256)for(t=t.child;t!==null;){var n=e,a=t,i=a.flags;switch(a.tag){case 22:Ji(n,a),i&2048&&Ec(a.alternate,a);break;case 24:Ji(n,a),i&2048&&wc(a.alternate,a);break;default:Ji(n,a)}t=t.sibling}}function _a(e,t,n){if(e.subtreeFlags&Li)for(e=e.child;e!==null;)wm(e,t,n),e=e.sibling}function wm(e,t,n){switch(e.tag){case 26:_a(e,t,n),e.flags&Li&&e.memoizedState!==null&&V_(n,ht,e.memoizedState,e.memoizedProps);break;case 5:_a(e,t,n);break;case 3:case 4:var a=ht;ht=Ko(e.stateNode.containerInfo),_a(e,t,n),ht=a;break;case 22:e.memoizedState===null&&(a=e.alternate,a!==null&&a.memoizedState!==null?(a=Li,Li=16777216,_a(e,t,n),Li=a):_a(e,t,n));break;default:_a(e,t,n)}}function Nm(e){var t=e.alternate;if(t!==null&&(e=t.child,e!==null)){t.child=null;do t=e.sibling,e.sibling=null,e=t;while(e!==null)}}function Di(e){var t=e.deletions;if((e.flags&16)!==0){if(t!==null)for(var n=0;n<t.length;n++){var a=t[n];ve=a,Am(a,e)}Nm(e)}if(e.subtreeFlags&10256)for(e=e.child;e!==null;)Om(e),e=e.sibling}function Om(e){switch(e.tag){case 0:case 11:case 15:Di(e),e.flags&2048&&An(9,e,e.return);break;case 3:Di(e);break;case 12:Di(e);break;case 22:var t=e.stateNode;e.memoizedState!==null&&t._visibility&2&&(e.return===null||e.return.tag!==13)?(t._visibility&=-3,mo(e)):Di(e);break;default:Di(e)}}function mo(e){var t=e.deletions;if((e.flags&16)!==0){if(t!==null)for(var n=0;n<t.length;n++){var a=t[n];ve=a,Am(a,e)}Nm(e)}for(e=e.child;e!==null;){switch(t=e,t.tag){case 0:case 11:case 15:An(8,t,t.return),mo(t);break;case 22:n=t.stateNode,n._visibility&2&&(n._visibility&=-3,mo(t));break;default:mo(t)}e=e.sibling}}function Am(e,t){for(;ve!==null;){var n=ve;switch(n.tag){case 0:case 11:case 15:An(8,n,t);break;case 23:case 22:if(n.memoizedState!==null&&n.memoizedState.cachePool!==null){var a=n.memoizedState.cachePool.pool;a!=null&&a.refCount++}break;case 24:yl(n.memoizedState.cache)}if(a=n.child,a!==null)a.return=n,ve=a;else e:for(n=e;ve!==null;){a=ve;var{sibling:i,return:l}=a;if(gm(a),a===n){ve=null;break e}if(i!==null){i.return=l,ve=i;break e}ve=l}}}function Ge(){return(K&2)!==0&&q!==0?q&-q:z.T!==null?Tc():Bh()}function zm(){if(Be===0)if((q&536870912)===0||G){var e=Xl;Xl<<=1,(Xl&3932160)===0&&(Xl=262144),Be=e}else Be=536870912;return e=Ke.current,e!==null&&(e.flags|=32),Be}function Me(e,t,n){if(e===F&&(Q===2||Q===9)||e.cancelPendingCommit!==null)Wa(e,0),pn(e,q,Be,!1);if(vl(e,n),(K&2)===0||e!==F)e===F&&((K&2)===0&&(Fn|=n),oe===4&&pn(e,q,Be,!1)),Ot(e)}function Rm(e,t,n){if((K&6)!==0)throw Error(S(327));var a=!n&&(t&127)===0&&(t&e.expiredLanes)===0||ml(e,t),i=a?a_(e,t):Vs(e,t,!0),l=a;do{if(i===0){ii&&!a&&pn(e,t,0,!1);break}else{if(n=e.current.alternate,l&&!t_(n)){i=Vs(e,t,!1),l=!1;continue}if(i===2){if(l=t,e.errorRecoveryDisabledLanes&l)var o=0;else o=e.pendingLanes&-536870913,o=o!==0?o:o&536870912?536870912:0;if(o!==0){t=o;e:{var r=e;i=Fi;var s=r.current.memoizedState.isDehydrated;if(s&&(Wa(r,o).flags|=256),o=Vs(r,o,!1),o!==2){if(Nc&&!s){r.errorRecoveryDisabledLanes|=l,Fn|=l,i=4;break e}l=Re,Re=i,l!==null&&(Re===null?Re=l:Re.push.apply(Re,l))}i=o}if(l=!1,i!==2)continue}}if(i===1){Wa(e,0),pn(e,t,0,!0);break}e:{switch(a=e,l=i,l){case 0:case 1:throw Error(S(345));case 4:if((t&4194048)!==t)break;case 6:pn(a,t,Be,!hn);break e;case 2:Re=null;break;case 3:case 5:break;default:throw Error(S(329))}if((t&62914560)===t&&(i=rr+300-He(),10<i)){if(pn(a,t,Be,!hn),Fo(a,0,!0)!==0)break e;Gt=t,a.timeoutHandle=Wm(Wd.bind(null,a,n,Re,Bo,Eu,t,Be,Fn,Ja,hn,l,"Throttled",-0,0),i);break e}Wd(a,n,Re,Bo,Eu,t,Be,Fn,Ja,hn,l,null,-0,0)}}break}while(1);Ot(e)}function Wd(e,t,n,a,i,l,o,r,s,c,m,b,h,g){if(e.timeoutHandle=-1,b=t.subtreeFlags,b&8192||(b&16785408)===16785408){b={stylesheets:null,count:0,imgCount:0,imgBytes:0,suspenseyImages:[],waitingForImages:!0,waitingForViewTransition:!1,unsuspend:Bt},wm(t,l,b);var x=(l&62914560)===l?rr-He():(l&4194048)===l?Tm-He():0;if(x=L_(b,x),x!==null){Gt=l,e.cancelPendingCommit=x(Pd.bind(null,e,t,l,n,a,i,o,r,s,m,b,null,h,g)),pn(e,l,o,!c);return}}Pd(e,t,l,n,a,i,o,r,s)}function t_(e){for(var t=e;;){var n=t.tag;if((n===0||n===11||n===15)&&t.flags&16384&&(n=t.updateQueue,n!==null&&(n=n.stores,n!==null)))for(var a=0;a<n.length;a++){var i=n[a],l=i.getSnapshot;i=i.value;try{if(!Ye(l(),i))return!1}catch(o){return!1}}if(n=t.child,t.subtreeFlags&16384&&n!==null)n.return=t,t=n;else{if(t===e)break;for(;t.sibling===null;){if(t.return===null||t.return===e)return!0;t=t.return}t.sibling.return=t.return,t=t.sibling}}return!0}function pn(e,t,n,a){t&=~Oc,t&=~Fn,e.suspendedLanes|=t,e.pingedLanes&=~t,a&&(e.warmLanes|=t),a=e.expirationTimes;for(var i=t;0<i;){var l=31-qe(i),o=1<<l;a[l]=-1,i&=~o}n!==0&&kh(e,n,t)}function sr(){return(K&6)===0?(xl(0,!1),!1):!0}function Ac(){if(j!==null){if(Q===0)var e=j.return;else e=j,Ht=oa=null,dc(e),ja=null,ll=0,e=j;for(;e!==null;)cm(e.alternate,e),e=e.return;j=null}}function Wa(e,t){var n=e.timeoutHandle;n!==-1&&(e.timeoutHandle=-1,y_(n)),n=e.cancelPendingCommit,n!==null&&(e.cancelPendingCommit=null,n()),Gt=0,Ac(),F=e,j=n=jt(e.current,null),q=t,Q=0,ke=null,hn=!1,ii=ml(e,t),Nc=!1,Ja=Be=Oc=Fn=Tn=oe=0,Re=Fi=null,Eu=!1,(t&8)!==0&&(t|=t&32);var a=e.entangledLanes;if(a!==0)for(e=e.entanglements,a&=t;0<a;){var i=31-qe(a),l=1<<i;t|=e[i],a&=~l}return Zt=t,er(),n}function Mm(e,t){C=null,z.H=rl,t===ai||t===nr?(t=Dd(),Q=3):t===lc?(t=Dd(),Q=4):Q=t===Sc?8:t!==null&&typeof t==="object"&&typeof t.then==="function"?6:1,ke=t,j===null&&(oe=1,Uo(e,tt(t,e.current)))}function Cm(){var e=Ke.current;return e===null?!0:(q&4194048)===q?at===null?!0:!1:(q&62914560)===q||(q&536870912)!==0?e===at:!1}function Um(){var e=z.H;return z.H=rl,e===null?rl:e}function km(){var e=z.A;return z.A=P1,e}function Ho(){oe=4,hn||(q&4194048)!==q&&Ke.current!==null||(ii=!0),(Tn&134217727)===0&&(Fn&134217727)===0||F===null||pn(F,q,Be,!1)}function Vs(e,t,n){var a=K;K|=2;var i=Um(),l=km();if(F!==e||q!==t)Bo=null,Wa(e,t);t=!1;var o=oe;e:do try{if(Q!==0&&j!==null){var r=j,s=ke;switch(Q){case 8:Ac(),o=6;break e;case 3:case 2:case 9:case 6:Ke.current===null&&(t=!0);var c=Q;if(Q=0,ke=null,ka(e,r,s,c),n&&ii){o=0;break e}break;default:c=Q,Q=0,ke=null,ka(e,r,s,c)}}n_(),o=oe;break}catch(m){Mm(e,m)}while(1);return t&&e.shellSuspendCounter++,Ht=oa=null,K=a,z.H=i,z.A=l,j===null&&(F=null,q=0,er()),o}function n_(){for(;j!==null;)Vm(j)}function a_(e,t){var n=K;K|=2;var a=Um(),i=km();F!==e||q!==t?(Bo=null,Lo=He()+500,Wa(e,t)):ii=ml(e,t);e:do try{if(Q!==0&&j!==null){t=j;var l=ke;t:switch(Q){case 1:Q=0,ke=null,ka(e,t,l,1);break;case 2:case 9:if(Td(l)){Q=0,ke=null,Id(t);break}t=function(){Q!==2&&Q!==9||F!==e||(Q=7),Ot(e)},l.then(t,t);break e;case 3:Q=7;break e;case 4:Q=5;break e;case 7:Td(l)?(Q=0,ke=null,Id(t)):(Q=0,ke=null,ka(e,t,l,7));break;case 5:var o=null;switch(j.tag){case 26:o=j.memoizedState;case 5:case 27:var r=j;if(o?nv(o):r.stateNode.complete){Q=0,ke=null;var s=r.sibling;if(s!==null)j=s;else{var c=r.return;c!==null?(j=c,ur(c)):j=null}break t}}Q=0,ke=null,ka(e,t,l,5);break;case 6:Q=0,ke=null,ka(e,t,l,6);break;case 8:Ac(),oe=6;break e;default:throw Error(S(462))}}i_();break}catch(m){Mm(e,m)}while(1);if(Ht=oa=null,z.H=a,z.A=i,K=n,j!==null)return 0;return F=null,q=0,er(),oe}function i_(){for(;j!==null&&!A0();)Vm(j)}function Vm(e){var t=um(e.alternate,e,Zt);e.memoizedProps=e.pendingProps,t===null?ur(e):j=t}function Id(e){var t=e,n=t.alternate;switch(t.tag){case 15:case 0:t=Xd(n,t,t.pendingProps,t.type,void 0,q);break;case 11:t=Xd(n,t,t.pendingProps,t.type.render,t.ref,q);break;case 5:dc(t);default:cm(n,t),t=j=cp(t,Zt),t=um(n,t,Zt)}e.memoizedProps=e.pendingProps,t===null?ur(e):j=t}function ka(e,t,n,a){Ht=oa=null,dc(t),ja=null,ll=0;var i=t.return;try{if(Q1(e,i,t,n,q)){oe=1,Uo(e,tt(n,e.current)),j=null;return}}catch(l){if(i!==null)throw j=i,l;oe=1,Uo(e,tt(n,e.current)),j=null;return}if(t.flags&32768){if(G||a===1)e=!0;else if(ii||(q&536870912)!==0)e=!1;else if(hn=e=!0,a===2||a===9||a===3||a===6)a=Ke.current,a!==null&&a.tag===13&&(a.flags|=16384);Lm(t,e)}else ur(t)}function ur(e){var t=e;do{if((t.flags&32768)!==0){Lm(t,hn);return}e=t.return;var n=J1(t.alternate,t,Zt);if(n!==null){j=n;return}if(t=t.sibling,t!==null){j=t;return}j=t=e}while(t!==null);oe===0&&(oe=5)}function Lm(e,t){do{var n=F1(e.alternate,e);if(n!==null){n.flags&=32767,j=n;return}if(n=e.return,n!==null&&(n.flags|=32768,n.subtreeFlags=0,n.deletions=null),!t&&(e=e.sibling,e!==null)){j=e;return}j=e=n}while(e!==null);oe=6,j=null}function Pd(e,t,n,a,i,l,o,r,s){e.cancelPendingCommit=null;do cr();while(pe!==0);if((K&6)!==0)throw Error(S(327));if(t!==null){if(t===e.current)throw Error(S(177));if(l=t.lanes|t.childLanes,l|=Iu,L0(e,n,l,o,r,s),e===F&&(j=F=null,q=0),Fa=t,Sn=e,Gt=n,wu=l,Nu=i,Dm=a,(t.subtreeFlags&10256)!==0||(t.flags&10256)!==0?(e.callbackNode=null,e.callbackPriority=0,s_(Eo,function(){return Gm(),null})):(e.callbackNode=null,e.callbackPriority=0),a=(t.flags&13878)!==0,(t.subtreeFlags&13878)!==0||a){a=z.T,z.T=null,i=X.p,X.p=2,o=K,K|=4;try{W1(e,t,n)}finally{K=o,X.p=i,z.T=a}}pe=1,Bm(),Hm(),jm()}}function Bm(){if(pe===1){pe=0;var e=Sn,t=Fa,n=(t.flags&13878)!==0;if((t.subtreeFlags&13878)!==0||n){n=z.T,z.T=null;var a=X.p;X.p=2;var i=K;K|=4;try{Sm(t,e);var l=Mu,o=np(e.containerInfo),r=l.focusedElem,s=l.selectionRange;if(o!==r&&r&&r.ownerDocument&&tp(r.ownerDocument.documentElement,r)){if(s!==null&&Wu(r)){var{start:c,end:m}=s;if(m===void 0&&(m=c),"selectionStart"in r)r.selectionStart=c,r.selectionEnd=Math.min(m,r.value.length);else{var b=r.ownerDocument||document,h=b&&b.defaultView||window;if(h.getSelection){var g=h.getSelection(),x=r.textContent.length,A=Math.min(s.start,x),M=s.end===void 0?A:Math.min(s.end,x);!g.extend&&A>M&&(o=M,M=A,A=o);var d=Sd(r,A),f=Sd(r,M);if(d&&f&&(g.rangeCount!==1||g.anchorNode!==d.node||g.anchorOffset!==d.offset||g.focusNode!==f.node||g.focusOffset!==f.offset)){var v=b.createRange();v.setStart(d.node,d.offset),g.removeAllRanges(),A>M?(g.addRange(v),g.extend(f.node,f.offset)):(v.setEnd(f.node,f.offset),g.addRange(v))}}}}b=[];for(g=r;g=g.parentNode;)g.nodeType===1&&b.push({element:g,left:g.scrollLeft,top:g.scrollTop});typeof r.focus==="function"&&r.focus();for(r=0;r<b.length;r++){var y=b[r];y.element.scrollLeft=y.left,y.element.scrollTop=y.top}}Zo=!!Ru,Mu=Ru=null}finally{K=i,X.p=a,z.T=n}}e.current=t,pe=2}}function Hm(){if(pe===2){pe=0;var e=Sn,t=Fa,n=(t.flags&8772)!==0;if((t.subtreeFlags&8772)!==0||n){n=z.T,z.T=null;var a=X.p;X.p=2;var i=K;K|=4;try{vm(e,t.alternate,t)}finally{K=i,X.p=a,z.T=n}}pe=3}}function jm(){if(pe===4||pe===3){pe=0,T0();var e=Sn,t=Fa,n=Gt,a=Dm;(t.subtreeFlags&10256)!==0||(t.flags&10256)!==0?pe=5:(pe=0,Fa=Sn=null,qm(e,e.pendingLanes));var i=e.pendingLanes;if(i===0&&(_n=null),Ku(n),t=t.stateNode,je&&typeof je.onCommitFiberRoot==="function")try{je.onCommitFiberRoot(pl,t,void 0,(t.current.flags&128)===128)}catch(s){}if(a!==null){t=z.T,i=X.p,X.p=2,z.T=null;try{for(var l=e.onRecoverableError,o=0;o<a.length;o++){var r=a[o];l(r.value,{componentStack:r.stack})}}finally{z.T=t,X.p=i}}(Gt&3)!==0&&cr(),Ot(e),i=e.pendingLanes,(n&261930)!==0&&(i&42)!==0?e===Ou?Wi++:(Wi=0,Ou=e):Wi=0,xl(0,!1)}}function qm(e,t){(e.pooledCacheLanes&=t)===0&&(t=e.pooledCache,t!=null&&(e.pooledCache=null,yl(t)))}function cr(){return Bm(),Hm(),jm(),Gm()}function Gm(){if(pe!==5)return!1;var e=Sn,t=wu;wu=0;var n=Ku(Gt),a=z.T,i=X.p;try{X.p=32>n?32:n,z.T=null,n=Nu,Nu=null;var l=Sn,o=Gt;if(pe=0,Fa=Sn=null,Gt=0,(K&6)!==0)throw Error(S(331));var r=K;if(K|=4,Om(l.current),Em(l,l.current,o,n),K=r,xl(0,!1),je&&typeof je.onPostCommitFiberRoot==="function")try{je.onPostCommitFiberRoot(pl,l)}catch(s){}return!0}finally{X.p=i,z.T=a,qm(e,t)}}function eh(e,t,n){t=tt(n,t),t=yu(e.stateNode,t,2),e=yn(e,t,2),e!==null&&(vl(e,2),Ot(e))}function Z(e,t,n){if(e.tag===3)eh(e,e,n);else for(;t!==null;){if(t.tag===3){eh(t,e,n);break}else if(t.tag===1){var a=t.stateNode;if(typeof t.type.getDerivedStateFromError==="function"||typeof a.componentDidCatch==="function"&&(_n===null||!_n.has(a))){e=tt(n,e),n=am(2),a=yn(t,n,2),a!==null&&(im(n,a,t,e),vl(a,2),Ot(a));break}}t=t.return}}function Ls(e,t,n){var a=e.pingCache;if(a===null){a=e.pingCache=new e_;var i=new Set;a.set(t,i)}else i=a.get(t),i===void 0&&(i=new Set,a.set(t,i));i.has(n)||(Nc=!0,i.add(n),e=l_.bind(null,e,t,n),t.then(e,e))}function l_(e,t,n){var a=e.pingCache;a!==null&&a.delete(t),e.pingedLanes|=e.suspendedLanes&n,e.warmLanes&=~n,F===e&&(q&n)===n&&(oe===4||oe===3&&(q&62914560)===q&&300>He()-rr?(K&2)===0&&Wa(e,0):Oc|=n,Ja===q&&(Ja=0)),Ot(e)}function Ym(e,t){t===0&&(t=Uh()),e=la(e,t),e!==null&&(vl(e,t),Ot(e))}function o_(e){var t=e.memoizedState,n=0;t!==null&&(n=t.retryLane),Ym(e,n)}function r_(e,t){var n=0;switch(e.tag){case 31:case 13:var{stateNode:a,memoizedState:i}=e;i!==null&&(n=i.retryLane);break;case 19:a=e.stateNode;break;case 22:a=e.stateNode._retryCache;break;default:throw Error(S(314))}a!==null&&a.delete(t),Ym(e,n)}function s_(e,t){return Gu(e,t)}function Ot(e){e!==xa&&e.next===null&&(xa===null?jo=xa=e:xa=xa.next=e),qo=!0,Au||(Au=!0,c_())}function xl(e,t){if(!Bs&&qo){Bs=!0;do{var n=!1;for(var a=jo;a!==null;){if(!t)if(e!==0){var i=a.pendingLanes;if(i===0)var l=0;else{var{suspendedLanes:o,pingedLanes:r}=a;l=(1<<31-qe(42|e)+1)-1,l&=i&~(o&~r),l=l&201326741?l&201326741|1:l?l|2:0}l!==0&&(n=!0,th(a,l))}else l=q,l=Fo(a,a===F?l:0,a.cancelPendingCommit!==null||a.timeoutHandle!==-1),(l&3)===0||ml(a,l)||(n=!0,th(a,l));a=a.next}}while(n);Bs=!1}}function u_(){Km()}function Km(){qo=Au=!1;var e=0;mn!==0&&b_()&&(e=mn);for(var t=He(),n=null,a=jo;a!==null;){var i=a.next,l=Xm(a,t);if(l===0)a.next=null,n===null?jo=i:n.next=i,i===null&&(xa=n);else if(n=a,e!==0||(l&3)!==0)qo=!0;a=i}pe!==0&&pe!==5||xl(e,!1),mn!==0&&(mn=0)}function Xm(e,t){for(var{suspendedLanes:n,pingedLanes:a,expirationTimes:i}=e,l=e.pendingLanes&-62914561;0<l;){var o=31-qe(l),r=1<<o,s=i[o];if(s===-1){if((r&n)===0||(r&a)!==0)i[o]=V0(r,t)}else s<=t&&(e.expiredLanes|=r);l&=~r}if(t=F,n=q,n=Fo(e,e===t?n:0,e.cancelPendingCommit!==null||e.timeoutHandle!==-1),a=e.callbackNode,n===0||e===t&&(Q===2||Q===9)||e.cancelPendingCommit!==null)return a!==null&&a!==null&&ps(a),e.callbackNode=null,e.callbackPriority=0;if((n&3)===0||ml(e,n)){if(t=n&-n,t===e.callbackPriority)return t;switch(a!==null&&ps(a),Ku(n)){case 2:case 8:n=Mh;break;case 32:n=Eo;break;case 268435456:n=Ch;break;default:n=Eo}return a=Qm.bind(null,e),n=Gu(n,a),e.callbackPriority=t,e.callbackNode=n,t}return a!==null&&a!==null&&ps(a),e.callbackPriority=2,e.callbackNode=null,2}function Qm(e,t){if(pe!==0&&pe!==5)return e.callbackNode=null,e.callbackPriority=0,null;var n=e.callbackNode;if(cr()&&e.callbackNode!==n)return null;var a=q;if(a=Fo(e,e===F?a:0,e.cancelPendingCommit!==null||e.timeoutHandle!==-1),a===0)return null;return Rm(e,a,t),Xm(e,He()),e.callbackNode!=null&&e.callbackNode===n?Qm.bind(null,e):null}function th(e,t){if(cr())return null;Rm(e,t,!0)}function c_(){__(function(){(K&6)!==0?Gu(Rh,u_):Km()})}function Tc(){if(mn===0){var e=Qa;e===0&&(e=Kl,Kl<<=1,(Kl&261888)===0&&(Kl=256)),mn=e}return mn}function nh(e){return e==null||typeof e==="symbol"||typeof e==="boolean"?null:typeof e==="function"?e:io(""+e)}function ah(e,t){var n=t.ownerDocument.createElement("input");return n.name=t.name,n.value=t.value,e.id&&n.setAttribute("form",e.id),t.parentNode.insertBefore(n,t),e=new FormData(e),n.parentNode.removeChild(n),e}function f_(e,t,n,a,i){if(t==="submit"&&n&&n.stateNode===i){var l=nh((i[Ce]||null).action),o=a.submitter;o&&(t=(t=o[Ce]||null)?nh(t.formAction):o.getAttribute("formAction"),t!==null&&(l=t,o=null));var r=new Wo("action","action",null,a,i);e.push({event:r,listeners:[{instance:null,listener:function(){if(a.defaultPrevented){if(mn!==0){var s=o?ah(i,o):new FormData(i);gu(n,{pending:!0,data:s,method:i.method,action:l},null,s)}}else typeof l==="function"&&(r.preventDefault(),s=o?ah(i,o):new FormData(i),gu(n,{pending:!0,data:s,method:i.method,action:l},l,s))},currentTarget:i}]})}}function Zm(e,t){t=(t&4)!==0;for(var n=0;n<e.length;n++){var a=e[n],i=a.event;a=a.listeners;e:{var l=void 0;if(t)for(var o=a.length-1;0<=o;o--){var r=a[o],s=r.instance,c=r.currentTarget;if(r=r.listener,s!==l&&i.isPropagationStopped())break e;l=r,i.currentTarget=c;try{l(i)}catch(m){No(m)}i.currentTarget=null,l=s}else for(o=0;o<a.length;o++){if(r=a[o],s=r.instance,c=r.currentTarget,r=r.listener,s!==l&&i.isPropagationStopped())break e;l=r,i.currentTarget=c;try{l(i)}catch(m){No(m)}i.currentTarget=null,l=s}}}}function H(e,t){var n=t[Ws];n===void 0&&(n=t[Ws]=new Set);var a=e+"__bubble";n.has(a)||($m(t,e,2,!1),n.add(a))}function Hs(e,t,n){var a=0;t&&(a|=4),$m(n,e,a,t)}function Dc(e){if(!e[eo]){e[eo]=!0,Hh.forEach(function(n){n!=="selectionchange"&&(d_.has(n)||Hs(n,!1,e),Hs(n,!0,e))});var t=e.nodeType===9?e:e.ownerDocument;t===null||t[eo]||(t[eo]=!0,Hs("selectionchange",!1,t))}}function $m(e,t,n,a){switch(rv(t)){case 2:var i=j_;break;case 8:i=q_;break;default:i=Cc}n=i.bind(null,t,n,e),i=void 0,!nu||t!=="touchstart"&&t!=="touchmove"&&t!=="wheel"||(i=!0),a?i!==void 0?e.addEventListener(t,n,{capture:!0,passive:i}):e.addEventListener(t,n,!0):i!==void 0?e.addEventListener(t,n,{passive:i}):e.addEventListener(t,n,!1)}function js(e,t,n,a,i){var l=a;if((t&1)===0&&(t&2)===0&&a!==null)e:for(;;){if(a===null)return;var o=a.tag;if(o===3||o===4){var r=a.stateNode.containerInfo;if(r===i)break;if(o===4)for(o=a.return;o!==null;){var s=o.tag;if((s===3||s===4)&&o.stateNode.containerInfo===i)return;o=o.return}for(;r!==null;){if(o=Oa(r),o===null)return;if(s=o.tag,s===5||s===6||s===26||s===27){a=l=o;continue e}r=r.parentNode}}a=a.return}Zh(function(){var c=l,m=Zu(n),b=[];e:{var h=sp.get(e);if(h!==void 0){var g=Wo,x=e;switch(e){case"keypress":if(oo(n)===0)break e;case"keydown":case"keyup":g=r1;break;case"focusin":x="focus",g=ys;break;case"focusout":x="blur",g=ys;break;case"beforeblur":case"afterblur":g=ys;break;case"click":if(n.button===2)break e;case"auxclick":case"dblclick":case"mousedown":case"mousemove":case"mouseup":case"mouseout":case"mouseover":case"contextmenu":g=dd;break;case"drag":case"dragend":case"dragenter":case"dragexit":case"dragleave":case"dragover":case"dragstart":case"drop":g=J0;break;case"touchcancel":case"touchend":case"touchmove":case"touchstart":g=c1;break;case ip:case lp:case op:g=I0;break;case rp:g=d1;break;case"scroll":case"scrollend":g=Z0;break;case"wheel":g=p1;break;case"copy":case"cut":case"paste":g=e1;break;case"gotpointercapture":case"lostpointercapture":case"pointercancel":case"pointerdown":case"pointermove":case"pointerout":case"pointerover":case"pointerup":g=pd;break;case"toggle":case"beforetoggle":g=v1}var A=(t&4)!==0,M=!A&&(e==="scroll"||e==="scrollend"),d=A?h!==null?h+"Capture":null:h;A=[];for(var f=c,v;f!==null;){var y=f;if(v=y.stateNode,y=y.tag,y!==5&&y!==26&&y!==27||v===null||d===null||(y=el(f,d),y!=null&&A.push(ul(f,y,v))),M)break;f=f.return}0<A.length&&(h=new g(h,x,null,n,m),b.push({event:h,listeners:A}))}}if((t&7)===0){e:{if(h=e==="mouseover"||e==="pointerover",g=e==="mouseout"||e==="pointerout",h&&n!==tu&&(x=n.relatedTarget||n.fromElement)&&(Oa(x)||x[ei]))break e;if(g||h){if(h=m.window===m?m:(h=m.ownerDocument)?h.defaultView||h.parentWindow:window,g){if(x=n.relatedTarget||n.toElement,g=c,x=x?Oa(x):null,x!==null&&(M=hl(x),A=x.tag,x!==M||A!==5&&A!==27&&A!==6))x=null}else g=null,x=c;if(g!==x){if(A=dd,y="onMouseLeave",d="onMouseEnter",f="mouse",e==="pointerout"||e==="pointerover")A=pd,y="onPointerLeave",d="onPointerEnter",f="pointer";if(M=g==null?h:Ci(g),v=x==null?h:Ci(x),h=new A(y,f+"leave",g,n,m),h.target=M,h.relatedTarget=v,y=null,Oa(m)===c&&(A=new A(d,f+"enter",x,n,m),A.target=v,A.relatedTarget=M,y=A),M=y,g&&x)t:{A=h_,d=g,f=x,v=0;for(y=d;y;y=A(y))v++;y=0;for(var w=f;w;w=A(w))y++;for(;0<v-y;)d=A(d),v--;for(;0<y-v;)f=A(f),y--;for(;v--;){if(d===f||f!==null&&d===f.alternate){A=d;break t}d=A(d),f=A(f)}A=null}else A=null;g!==null&&ih(b,h,g,A,!1),x!==null&&M!==null&&ih(b,M,x,A,!0)}}}e:{if(h=c?Ci(c):window,g=h.nodeName&&h.nodeName.toLowerCase(),g==="select"||g==="input"&&h.type==="file")var U=bd;else if(gd(h))if(Ph)U=O1;else{U=w1;var O=E1}else g=h.nodeName,!g||g.toLowerCase()!=="input"||h.type!=="checkbox"&&h.type!=="radio"?c&&Qu(c.elementType)&&(U=bd):U=N1;if(U&&(U=U(e,c))){Ih(b,U,n,m);break e}O&&O(e,h,c),e==="focusout"&&c&&h.type==="number"&&c.memoizedProps.value!=null&&eu(h,"number",h.value)}switch(O=c?Ci(c):window,e){case"focusin":if(gd(O)||O.contentEditable==="true")Da=O,au=c,Gi=null;break;case"focusout":Gi=au=Da=null;break;case"mousedown":iu=!0;break;case"contextmenu":case"mouseup":case"dragend":iu=!1,xd(b,n,m);break;case"selectionchange":if(T1)break;case"keydown":case"keyup":xd(b,n,m)}var R;if(Fu)e:{switch(e){case"compositionstart":var k="onCompositionStart";break e;case"compositionend":k="onCompositionEnd";break e;case"compositionupdate":k="onCompositionUpdate";break e}k=void 0}else Ta?Fh(e,n)&&(k="onCompositionEnd"):e==="keydown"&&n.keyCode===229&&(k="onCompositionStart");if(k&&(Jh&&n.locale!=="ko"&&(Ta||k!=="onCompositionStart"?k==="onCompositionEnd"&&Ta&&(R=$h()):(dn=m,$u=("value"in dn)?dn.value:dn.textContent,Ta=!0)),O=Go(c,k),0<O.length&&(k=new hd(k,e,null,n,m),b.push({event:k,listeners:O}),R?k.data=R:(R=Wh(n),R!==null&&(k.data=R)))),R=b1?y1(e,n):_1(e,n))k=Go(c,"onBeforeInput"),0<k.length&&(O=new hd("onBeforeInput","beforeinput",null,n,m),b.push({event:O,listeners:k}),O.data=R);f_(b,e,c,n,m)}Zm(b,t)})}function ul(e,t,n){return{instance:e,listener:t,currentTarget:n}}function Go(e,t){for(var n=t+"Capture",a=[];e!==null;){var i=e,l=i.stateNode;if(i=i.tag,i!==5&&i!==26&&i!==27||l===null||(i=el(e,n),i!=null&&a.unshift(ul(e,i,l)),i=el(e,t),i!=null&&a.push(ul(e,i,l))),e.tag===3)return a;e=e.return}return[]}function h_(e){if(e===null)return null;do e=e.return;while(e&&e.tag!==5&&e.tag!==27);return e?e:null}function ih(e,t,n,a,i){for(var l=t._reactName,o=[];n!==null&&n!==a;){var r=n,s=r.alternate,c=r.stateNode;if(r=r.tag,s!==null&&s===a)break;r!==5&&r!==26&&r!==27||c===null||(s=c,i?(c=el(n,l),c!=null&&o.unshift(ul(n,c,s))):i||(c=el(n,l),c!=null&&o.push(ul(n,c,s)))),n=n.return}o.length!==0&&e.push({event:t,listeners:o})}function lh(e){return(typeof e==="string"?e:""+e).replace(p_,`
9
+ `).replace(m_,"")}function Jm(e,t){return t=lh(t),lh(e)===t?!0:!1}function $(e,t,n,a,i,l){switch(n){case"children":typeof a==="string"?t==="body"||t==="textarea"&&a===""||Xa(e,a):(typeof a==="number"||typeof a==="bigint")&&t!=="body"&&Xa(e,""+a);break;case"className":Zl(e,"class",a);break;case"tabIndex":Zl(e,"tabindex",a);break;case"dir":case"role":case"viewBox":case"width":case"height":Zl(e,n,a);break;case"style":Qh(e,a,l);break;case"data":if(t!=="object"){Zl(e,"data",a);break}case"src":case"href":if(a===""&&(t!=="a"||n!=="href")){e.removeAttribute(n);break}if(a==null||typeof a==="function"||typeof a==="symbol"||typeof a==="boolean"){e.removeAttribute(n);break}a=io(""+a),e.setAttribute(n,a);break;case"action":case"formAction":if(typeof a==="function"){e.setAttribute(n,"javascript:throw new Error('A React form was unexpectedly submitted. If you called form.submit() manually, consider using form.requestSubmit() instead. If you\\'re trying to use event.stopPropagation() in a submit event handler, consider also calling event.preventDefault().')");break}else typeof l==="function"&&(n==="formAction"?(t!=="input"&&$(e,t,"name",i.name,i,null),$(e,t,"formEncType",i.formEncType,i,null),$(e,t,"formMethod",i.formMethod,i,null),$(e,t,"formTarget",i.formTarget,i,null)):($(e,t,"encType",i.encType,i,null),$(e,t,"method",i.method,i,null),$(e,t,"target",i.target,i,null)));if(a==null||typeof a==="symbol"||typeof a==="boolean"){e.removeAttribute(n);break}a=io(""+a),e.setAttribute(n,a);break;case"onClick":a!=null&&(e.onclick=Bt);break;case"onScroll":a!=null&&H("scroll",e);break;case"onScrollEnd":a!=null&&H("scrollend",e);break;case"dangerouslySetInnerHTML":if(a!=null){if(typeof a!=="object"||!("__html"in a))throw Error(S(61));if(n=a.__html,n!=null){if(i.children!=null)throw Error(S(60));e.innerHTML=n}}break;case"multiple":e.multiple=a&&typeof a!=="function"&&typeof a!=="symbol";break;case"muted":e.muted=a&&typeof a!=="function"&&typeof a!=="symbol";break;case"suppressContentEditableWarning":case"suppressHydrationWarning":case"defaultValue":case"defaultChecked":case"innerHTML":case"ref":break;case"autoFocus":break;case"xlinkHref":if(a==null||typeof a==="function"||typeof a==="boolean"||typeof a==="symbol"){e.removeAttribute("xlink:href");break}n=io(""+a),e.setAttributeNS("http://www.w3.org/1999/xlink","xlink:href",n);break;case"contentEditable":case"spellCheck":case"draggable":case"value":case"autoReverse":case"externalResourcesRequired":case"focusable":case"preserveAlpha":a!=null&&typeof a!=="function"&&typeof a!=="symbol"?e.setAttribute(n,""+a):e.removeAttribute(n);break;case"inert":case"allowFullScreen":case"async":case"autoPlay":case"controls":case"default":case"defer":case"disabled":case"disablePictureInPicture":case"disableRemotePlayback":case"formNoValidate":case"hidden":case"loop":case"noModule":case"noValidate":case"open":case"playsInline":case"readOnly":case"required":case"reversed":case"scoped":case"seamless":case"itemScope":a&&typeof a!=="function"&&typeof a!=="symbol"?e.setAttribute(n,""):e.removeAttribute(n);break;case"capture":case"download":a===!0?e.setAttribute(n,""):a!==!1&&a!=null&&typeof a!=="function"&&typeof a!=="symbol"?e.setAttribute(n,a):e.removeAttribute(n);break;case"cols":case"rows":case"size":case"span":a!=null&&typeof a!=="function"&&typeof a!=="symbol"&&!isNaN(a)&&1<=a?e.setAttribute(n,a):e.removeAttribute(n);break;case"rowSpan":case"start":a==null||typeof a==="function"||typeof a==="symbol"||isNaN(a)?e.removeAttribute(n):e.setAttribute(n,a);break;case"popover":H("beforetoggle",e),H("toggle",e),ao(e,"popover",a);break;case"xlinkActuate":zt(e,"http://www.w3.org/1999/xlink","xlink:actuate",a);break;case"xlinkArcrole":zt(e,"http://www.w3.org/1999/xlink","xlink:arcrole",a);break;case"xlinkRole":zt(e,"http://www.w3.org/1999/xlink","xlink:role",a);break;case"xlinkShow":zt(e,"http://www.w3.org/1999/xlink","xlink:show",a);break;case"xlinkTitle":zt(e,"http://www.w3.org/1999/xlink","xlink:title",a);break;case"xlinkType":zt(e,"http://www.w3.org/1999/xlink","xlink:type",a);break;case"xmlBase":zt(e,"http://www.w3.org/XML/1998/namespace","xml:base",a);break;case"xmlLang":zt(e,"http://www.w3.org/XML/1998/namespace","xml:lang",a);break;case"xmlSpace":zt(e,"http://www.w3.org/XML/1998/namespace","xml:space",a);break;case"is":ao(e,"is",a);break;case"innerText":case"textContent":break;default:if(!(2<n.length)||n[0]!=="o"&&n[0]!=="O"||n[1]!=="n"&&n[1]!=="N")n=X0.get(n)||n,ao(e,n,a)}}function zu(e,t,n,a,i,l){switch(n){case"style":Qh(e,a,l);break;case"dangerouslySetInnerHTML":if(a!=null){if(typeof a!=="object"||!("__html"in a))throw Error(S(61));if(n=a.__html,n!=null){if(i.children!=null)throw Error(S(60));e.innerHTML=n}}break;case"children":typeof a==="string"?Xa(e,a):(typeof a==="number"||typeof a==="bigint")&&Xa(e,""+a);break;case"onScroll":a!=null&&H("scroll",e);break;case"onScrollEnd":a!=null&&H("scrollend",e);break;case"onClick":a!=null&&(e.onclick=Bt);break;case"suppressContentEditableWarning":case"suppressHydrationWarning":case"innerHTML":case"ref":break;case"innerText":case"textContent":break;default:if(!jh.hasOwnProperty(n))e:{if(n[0]==="o"&&n[1]==="n"&&(i=n.endsWith("Capture"),t=n.slice(2,i?n.length-7:void 0),l=e[Ce]||null,l=l!=null?l[n]:null,typeof l==="function"&&e.removeEventListener(t,l,i),typeof a==="function")){typeof l!=="function"&&l!==null&&(n in e?e[n]=null:e.hasAttribute(n)&&e.removeAttribute(n)),e.addEventListener(t,a,i);break e}n in e?e[n]=a:a===!0?e.setAttribute(n,""):ao(e,n,a)}}}function Ee(e,t,n){switch(t){case"div":case"span":case"svg":case"path":case"a":case"g":case"p":case"li":break;case"img":H("error",e),H("load",e);var a=!1,i=!1,l;for(l in n)if(n.hasOwnProperty(l)){var o=n[l];if(o!=null)switch(l){case"src":a=!0;break;case"srcSet":i=!0;break;case"children":case"dangerouslySetInnerHTML":throw Error(S(137,t));default:$(e,t,l,o,n,null)}}i&&$(e,t,"srcSet",n.srcSet,n,null),a&&$(e,t,"src",n.src,n,null);return;case"input":H("invalid",e);var r=l=o=i=null,s=null,c=null;for(a in n)if(n.hasOwnProperty(a)){var m=n[a];if(m!=null)switch(a){case"name":i=m;break;case"type":o=m;break;case"checked":s=m;break;case"defaultChecked":c=m;break;case"value":l=m;break;case"defaultValue":r=m;break;case"children":case"dangerouslySetInnerHTML":if(m!=null)throw Error(S(137,t));break;default:$(e,t,a,m,n,null)}}Yh(e,l,r,s,c,o,i,!1);return;case"select":H("invalid",e),a=o=l=null;for(i in n)if(n.hasOwnProperty(i)&&(r=n[i],r!=null))switch(i){case"value":l=r;break;case"defaultValue":o=r;break;case"multiple":a=r;default:$(e,t,i,r,n,null)}t=l,n=o,e.multiple=!!a,t!=null?La(e,!!a,t,!1):n!=null&&La(e,!!a,n,!0);return;case"textarea":H("invalid",e),l=i=a=null;for(o in n)if(n.hasOwnProperty(o)&&(r=n[o],r!=null))switch(o){case"value":a=r;break;case"defaultValue":i=r;break;case"children":l=r;break;case"dangerouslySetInnerHTML":if(r!=null)throw Error(S(91));break;default:$(e,t,o,r,n,null)}Xh(e,a,i,l);return;case"option":for(s in n)if(n.hasOwnProperty(s)&&(a=n[s],a!=null))switch(s){case"selected":e.selected=a&&typeof a!=="function"&&typeof a!=="symbol";break;default:$(e,t,s,a,n,null)}return;case"dialog":H("beforetoggle",e),H("toggle",e),H("cancel",e),H("close",e);break;case"iframe":case"object":H("load",e);break;case"video":case"audio":for(a=0;a<sl.length;a++)H(sl[a],e);break;case"image":H("error",e),H("load",e);break;case"details":H("toggle",e);break;case"embed":case"source":case"link":H("error",e),H("load",e);case"area":case"base":case"br":case"col":case"hr":case"keygen":case"meta":case"param":case"track":case"wbr":case"menuitem":for(c in n)if(n.hasOwnProperty(c)&&(a=n[c],a!=null))switch(c){case"children":case"dangerouslySetInnerHTML":throw Error(S(137,t));default:$(e,t,c,a,n,null)}return;default:if(Qu(t)){for(m in n)n.hasOwnProperty(m)&&(a=n[m],a!==void 0&&zu(e,t,m,a,n,void 0));return}}for(r in n)n.hasOwnProperty(r)&&(a=n[r],a!=null&&$(e,t,r,a,n,null))}function v_(e,t,n,a){switch(t){case"div":case"span":case"svg":case"path":case"a":case"g":case"p":case"li":break;case"input":var i=null,l=null,o=null,r=null,s=null,c=null,m=null;for(g in n){var b=n[g];if(n.hasOwnProperty(g)&&b!=null)switch(g){case"checked":break;case"value":break;case"defaultValue":s=b;default:a.hasOwnProperty(g)||$(e,t,g,null,a,b)}}for(var h in a){var g=a[h];if(b=n[h],a.hasOwnProperty(h)&&(g!=null||b!=null))switch(h){case"type":l=g;break;case"name":i=g;break;case"checked":c=g;break;case"defaultChecked":m=g;break;case"value":o=g;break;case"defaultValue":r=g;break;case"children":case"dangerouslySetInnerHTML":if(g!=null)throw Error(S(137,t));break;default:g!==b&&$(e,t,h,g,a,b)}}Ps(e,o,r,s,c,m,l,i);return;case"select":g=o=r=h=null;for(l in n)if(s=n[l],n.hasOwnProperty(l)&&s!=null)switch(l){case"value":break;case"multiple":g=s;default:a.hasOwnProperty(l)||$(e,t,l,null,a,s)}for(i in a)if(l=a[i],s=n[i],a.hasOwnProperty(i)&&(l!=null||s!=null))switch(i){case"value":h=l;break;case"defaultValue":r=l;break;case"multiple":o=l;default:l!==s&&$(e,t,i,l,a,s)}t=r,n=o,a=g,h!=null?La(e,!!n,h,!1):!!a!==!!n&&(t!=null?La(e,!!n,t,!0):La(e,!!n,n?[]:"",!1));return;case"textarea":g=h=null;for(r in n)if(i=n[r],n.hasOwnProperty(r)&&i!=null&&!a.hasOwnProperty(r))switch(r){case"value":break;case"children":break;default:$(e,t,r,null,a,i)}for(o in a)if(i=a[o],l=n[o],a.hasOwnProperty(o)&&(i!=null||l!=null))switch(o){case"value":h=i;break;case"defaultValue":g=i;break;case"children":break;case"dangerouslySetInnerHTML":if(i!=null)throw Error(S(91));break;default:i!==l&&$(e,t,o,i,a,l)}Kh(e,h,g);return;case"option":for(var x in n)if(h=n[x],n.hasOwnProperty(x)&&h!=null&&!a.hasOwnProperty(x))switch(x){case"selected":e.selected=!1;break;default:$(e,t,x,null,a,h)}for(s in a)if(h=a[s],g=n[s],a.hasOwnProperty(s)&&h!==g&&(h!=null||g!=null))switch(s){case"selected":e.selected=h&&typeof h!=="function"&&typeof h!=="symbol";break;default:$(e,t,s,h,a,g)}return;case"img":case"link":case"area":case"base":case"br":case"col":case"embed":case"hr":case"keygen":case"meta":case"param":case"source":case"track":case"wbr":case"menuitem":for(var A in n)h=n[A],n.hasOwnProperty(A)&&h!=null&&!a.hasOwnProperty(A)&&$(e,t,A,null,a,h);for(c in a)if(h=a[c],g=n[c],a.hasOwnProperty(c)&&h!==g&&(h!=null||g!=null))switch(c){case"children":case"dangerouslySetInnerHTML":if(h!=null)throw Error(S(137,t));break;default:$(e,t,c,h,a,g)}return;default:if(Qu(t)){for(var M in n)h=n[M],n.hasOwnProperty(M)&&h!==void 0&&!a.hasOwnProperty(M)&&zu(e,t,M,void 0,a,h);for(m in a)h=a[m],g=n[m],!a.hasOwnProperty(m)||h===g||h===void 0&&g===void 0||zu(e,t,m,h,a,g);return}}for(var d in n)h=n[d],n.hasOwnProperty(d)&&h!=null&&!a.hasOwnProperty(d)&&$(e,t,d,null,a,h);for(b in a)h=a[b],g=n[b],!a.hasOwnProperty(b)||h===g||h==null&&g==null||$(e,t,b,h,a,g)}function oh(e){switch(e){case"css":case"script":case"font":case"img":case"image":case"input":case"link":return!0;default:return!1}}function g_(){if(typeof performance.getEntriesByType==="function"){for(var e=0,t=0,n=performance.getEntriesByType("resource"),a=0;a<n.length;a++){var i=n[a],l=i.transferSize,o=i.initiatorType,r=i.duration;if(l&&r&&oh(o)){o=0,r=i.responseEnd;for(a+=1;a<n.length;a++){var s=n[a],c=s.startTime;if(c>r)break;var{transferSize:m,initiatorType:b}=s;m&&oh(b)&&(s=s.responseEnd,o+=m*(s<r?1:(r-c)/(s-c)))}if(--a,t+=8*(l+o)/(i.duration/1000),e++,10<e)break}}if(0<e)return t/e/1e6}return navigator.connection&&(e=navigator.connection.downlink,typeof e==="number")?e:5}function Yo(e){return e.nodeType===9?e:e.ownerDocument}function rh(e){switch(e){case"http://www.w3.org/2000/svg":return 1;case"http://www.w3.org/1998/Math/MathML":return 2;default:return 0}}function Fm(e,t){if(e===0)switch(t){case"svg":return 1;case"math":return 2;default:return 0}return e===1&&t==="foreignObject"?0:e}function Cu(e,t){return e==="textarea"||e==="noscript"||typeof t.children==="string"||typeof t.children==="number"||typeof t.children==="bigint"||typeof t.dangerouslySetInnerHTML==="object"&&t.dangerouslySetInnerHTML!==null&&t.dangerouslySetInnerHTML.__html!=null}function b_(){var e=window.event;if(e&&e.type==="popstate"){if(e===qs)return!1;return qs=e,!0}return qs=null,!1}function S_(e){setTimeout(function(){throw e})}function zn(e){return e==="head"}function uh(e,t){var n=t,a=0;do{var i=n.nextSibling;if(e.removeChild(n),i&&i.nodeType===8)if(n=i.data,n==="/$"||n==="/&"){if(a===0){e.removeChild(i),Pa(t);return}a--}else if(n==="$"||n==="$?"||n==="$~"||n==="$!"||n==="&")a++;else if(n==="html")Ii(e.ownerDocument.documentElement);else if(n==="head"){n=e.ownerDocument.head,Ii(n);for(var l=n.firstChild;l;){var{nextSibling:o,nodeName:r}=l;l[gl]||r==="SCRIPT"||r==="STYLE"||r==="LINK"&&l.rel.toLowerCase()==="stylesheet"||n.removeChild(l),l=o}}else n==="body"&&Ii(e.ownerDocument.body);n=i}while(n);Pa(t)}function ch(e,t){var n=e;e=0;do{var a=n.nextSibling;if(n.nodeType===1?t?(n._stashedDisplay=n.style.display,n.style.display="none"):(n.style.display=n._stashedDisplay||"",n.getAttribute("style")===""&&n.removeAttribute("style")):n.nodeType===3&&(t?(n._stashedText=n.nodeValue,n.nodeValue=""):n.nodeValue=n._stashedText||""),a&&a.nodeType===8)if(n=a.data,n==="/$")if(e===0)break;else e--;else n!=="$"&&n!=="$?"&&n!=="$~"&&n!=="$!"||e++;n=a}while(n)}function Uu(e){var t=e.firstChild;t&&t.nodeType===10&&(t=t.nextSibling);for(;t;){var n=t;switch(t=t.nextSibling,n.nodeName){case"HTML":case"HEAD":case"BODY":Uu(n),Xu(n);continue;case"SCRIPT":case"STYLE":continue;case"LINK":if(n.rel.toLowerCase()==="stylesheet")continue}e.removeChild(n)}}function x_(e,t,n,a){for(;e.nodeType===1;){var i=n;if(e.nodeName.toLowerCase()!==t.toLowerCase()){if(!a&&(e.nodeName!=="INPUT"||e.type!=="hidden"))break}else if(!a)if(t==="input"&&e.type==="hidden"){var l=i.name==null?null:""+i.name;if(i.type==="hidden"&&e.getAttribute("name")===l)return e}else return e;else if(!e[gl])switch(t){case"meta":if(!e.hasAttribute("itemprop"))break;return e;case"link":if(l=e.getAttribute("rel"),l==="stylesheet"&&e.hasAttribute("data-precedence"))break;else if(l!==i.rel||e.getAttribute("href")!==(i.href==null||i.href===""?null:i.href)||e.getAttribute("crossorigin")!==(i.crossOrigin==null?null:i.crossOrigin)||e.getAttribute("title")!==(i.title==null?null:i.title))break;return e;case"style":if(e.hasAttribute("data-precedence"))break;return e;case"script":if(l=e.getAttribute("src"),(l!==(i.src==null?null:i.src)||e.getAttribute("type")!==(i.type==null?null:i.type)||e.getAttribute("crossorigin")!==(i.crossOrigin==null?null:i.crossOrigin))&&l&&e.hasAttribute("async")&&!e.hasAttribute("itemprop"))break;return e;default:return e}if(e=it(e.nextSibling),e===null)break}return null}function E_(e,t,n){if(t==="")return null;for(;e.nodeType!==3;){if((e.nodeType!==1||e.nodeName!=="INPUT"||e.type!=="hidden")&&!n)return null;if(e=it(e.nextSibling),e===null)return null}return e}function Im(e,t){for(;e.nodeType!==8;){if((e.nodeType!==1||e.nodeName!=="INPUT"||e.type!=="hidden")&&!t)return null;if(e=it(e.nextSibling),e===null)return null}return e}function ku(e){return e.data==="$?"||e.data==="$~"}function Vu(e){return e.data==="$!"||e.data==="$?"&&e.ownerDocument.readyState!=="loading"}function w_(e,t){var n=e.ownerDocument;if(e.data==="$~")e._reactRetry=t;else if(e.data!=="$?"||n.readyState!=="loading")t();else{var a=function(){t(),n.removeEventListener("DOMContentLoaded",a)};n.addEventListener("DOMContentLoaded",a),e._reactRetry=a}}function it(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==="$?"||t==="$~"||t==="&"||t==="F!"||t==="F")break;if(t==="/$"||t==="/&")return null}}return e}function fh(e){e=e.nextSibling;for(var t=0;e;){if(e.nodeType===8){var n=e.data;if(n==="/$"||n==="/&"){if(t===0)return it(e.nextSibling);t--}else n!=="$"&&n!=="$!"&&n!=="$?"&&n!=="$~"&&n!=="&"||t++}e=e.nextSibling}return null}function dh(e){e=e.previousSibling;for(var t=0;e;){if(e.nodeType===8){var n=e.data;if(n==="$"||n==="$!"||n==="$?"||n==="$~"||n==="&"){if(t===0)return e;t--}else n!=="/$"&&n!=="/&"||t++}e=e.previousSibling}return null}function Pm(e,t,n){switch(t=Yo(n),e){case"html":if(e=t.documentElement,!e)throw Error(S(452));return e;case"head":if(e=t.head,!e)throw Error(S(453));return e;case"body":if(e=t.body,!e)throw Error(S(454));return e;default:throw Error(S(451))}}function Ii(e){for(var t=e.attributes;t.length;)e.removeAttributeNode(t[0]);Xu(e)}function Ko(e){return typeof e.getRootNode==="function"?e.getRootNode():e.nodeType===9?e:e.ownerDocument}function N_(){var e=$t.f(),t=sr();return e||t}function O_(e){var t=ti(e);t!==null&&t.tag===5&&t.type==="form"?Qp(t):$t.r(e)}function ev(e,t,n){var a=li;if(a&&typeof t==="string"&&t){var i=et(t);i='link[rel="'+e+'"][href="'+i+'"]',typeof n==="string"&&(i+='[crossorigin="'+n+'"]'),hh.has(i)||(hh.add(i),e={rel:e,crossOrigin:n,href:t},a.querySelector(i)===null&&(t=a.createElement("link"),Ee(t,"link",e),ge(t),a.head.appendChild(t)))}}function A_(e){$t.D(e),ev("dns-prefetch",e,null)}function T_(e,t){$t.C(e,t),ev("preconnect",e,t)}function D_(e,t,n){$t.L(e,t,n);var a=li;if(a&&e&&t){var i='link[rel="preload"][as="'+et(t)+'"]';t==="image"?n&&n.imageSrcSet?(i+='[imagesrcset="'+et(n.imageSrcSet)+'"]',typeof n.imageSizes==="string"&&(i+='[imagesizes="'+et(n.imageSizes)+'"]')):i+='[href="'+et(e)+'"]':i+='[href="'+et(e)+'"]';var l=i;switch(t){case"style":l=Ia(e);break;case"script":l=oi(e)}lt.has(l)||(e=ae({rel:"preload",href:t==="image"&&n&&n.imageSrcSet?void 0:e,as:t},n),lt.set(l,e),a.querySelector(i)!==null||t==="style"&&a.querySelector(El(l))||t==="script"&&a.querySelector(wl(l))||(t=a.createElement("link"),Ee(t,"link",e),ge(t),a.head.appendChild(t)))}}function z_(e,t){$t.m(e,t);var n=li;if(n&&e){var a=t&&typeof t.as==="string"?t.as:"script",i='link[rel="modulepreload"][as="'+et(a)+'"][href="'+et(e)+'"]',l=i;switch(a){case"audioworklet":case"paintworklet":case"serviceworker":case"sharedworker":case"worker":case"script":l=oi(e)}if(!lt.has(l)&&(e=ae({rel:"modulepreload",href:e},t),lt.set(l,e),n.querySelector(i)===null)){switch(a){case"audioworklet":case"paintworklet":case"serviceworker":case"sharedworker":case"worker":case"script":if(n.querySelector(wl(l)))return}a=n.createElement("link"),Ee(a,"link",e),ge(a),n.head.appendChild(a)}}}function R_(e,t,n){$t.S(e,t,n);var a=li;if(a&&e){var i=Va(a).hoistableStyles,l=Ia(e);t=t||"default";var o=i.get(l);if(!o){var r={loading:0,preload:null};if(o=a.querySelector(El(l)))r.loading=5;else{e=ae({rel:"stylesheet",href:e,"data-precedence":t},n),(n=lt.get(l))&&zc(e,n);var s=o=a.createElement("link");ge(s),Ee(s,"link",e),s._p=new Promise(function(c,m){s.onload=c,s.onerror=m}),s.addEventListener("load",function(){r.loading|=1}),s.addEventListener("error",function(){r.loading|=2}),r.loading|=4,vo(o,t,a)}o={type:"stylesheet",instance:o,count:1,state:r},i.set(l,o)}}}function M_(e,t){$t.X(e,t);var n=li;if(n&&e){var a=Va(n).hoistableScripts,i=oi(e),l=a.get(i);l||(l=n.querySelector(wl(i)),l||(e=ae({src:e,async:!0},t),(t=lt.get(i))&&Rc(e,t),l=n.createElement("script"),ge(l),Ee(l,"link",e),n.head.appendChild(l)),l={type:"script",instance:l,count:1,state:null},a.set(i,l))}}function C_(e,t){$t.M(e,t);var n=li;if(n&&e){var a=Va(n).hoistableScripts,i=oi(e),l=a.get(i);l||(l=n.querySelector(wl(i)),l||(e=ae({src:e,async:!0,type:"module"},t),(t=lt.get(i))&&Rc(e,t),l=n.createElement("script"),ge(l),Ee(l,"link",e),n.head.appendChild(l)),l={type:"script",instance:l,count:1,state:null},a.set(i,l))}}function ph(e,t,n,a){var i=(i=vn.current)?Ko(i):null;if(!i)throw Error(S(446));switch(e){case"meta":case"title":return null;case"style":return typeof n.precedence==="string"&&typeof n.href==="string"?(t=Ia(n.href),n=Va(i).hoistableStyles,a=n.get(t),a||(a={type:"style",instance:null,count:0,state:null},n.set(t,a)),a):{type:"void",instance:null,count:0,state:null};case"link":if(n.rel==="stylesheet"&&typeof n.href==="string"&&typeof n.precedence==="string"){e=Ia(n.href);var l=Va(i).hoistableStyles,o=l.get(e);if(o||(i=i.ownerDocument||i,o={type:"stylesheet",instance:null,count:0,state:{loading:0,preload:null}},l.set(e,o),(l=i.querySelector(El(e)))&&!l._p&&(o.instance=l,o.state.loading=5),lt.has(e)||(n={rel:"preload",as:"style",href:n.href,crossOrigin:n.crossOrigin,integrity:n.integrity,media:n.media,hrefLang:n.hrefLang,referrerPolicy:n.referrerPolicy},lt.set(e,n),l||U_(i,e,n,o.state))),t&&a===null)throw Error(S(528,""));return o}if(t&&a!==null)throw Error(S(529,""));return null;case"script":return t=n.async,n=n.src,typeof n==="string"&&t&&typeof t!=="function"&&typeof t!=="symbol"?(t=oi(n),n=Va(i).hoistableScripts,a=n.get(t),a||(a={type:"script",instance:null,count:0,state:null},n.set(t,a)),a):{type:"void",instance:null,count:0,state:null};default:throw Error(S(444,e))}}function Ia(e){return'href="'+et(e)+'"'}function El(e){return'link[rel="stylesheet"]['+e+"]"}function tv(e){return ae({},e,{"data-precedence":e.precedence,precedence:null})}function U_(e,t,n,a){e.querySelector('link[rel="preload"][as="style"]['+t+"]")?a.loading=1:(t=e.createElement("link"),a.preload=t,t.addEventListener("load",function(){return a.loading|=1}),t.addEventListener("error",function(){return a.loading|=2}),Ee(t,"link",n),ge(t),e.head.appendChild(t))}function oi(e){return'[src="'+et(e)+'"]'}function wl(e){return"script[async]"+e}function mh(e,t,n){if(t.count++,t.instance===null)switch(t.type){case"style":var a=e.querySelector('style[data-href~="'+et(n.href)+'"]');if(a)return t.instance=a,ge(a),a;var i=ae({},n,{"data-href":n.href,"data-precedence":n.precedence,href:null,precedence:null});return a=(e.ownerDocument||e).createElement("style"),ge(a),Ee(a,"style",i),vo(a,n.precedence,e),t.instance=a;case"stylesheet":i=Ia(n.href);var l=e.querySelector(El(i));if(l)return t.state.loading|=4,t.instance=l,ge(l),l;a=tv(n),(i=lt.get(i))&&zc(a,i),l=(e.ownerDocument||e).createElement("link"),ge(l);var o=l;return o._p=new Promise(function(r,s){o.onload=r,o.onerror=s}),Ee(l,"link",a),t.state.loading|=4,vo(l,n.precedence,e),t.instance=l;case"script":if(l=oi(n.src),i=e.querySelector(wl(l)))return t.instance=i,ge(i),i;if(a=n,i=lt.get(l))a=ae({},n),Rc(a,i);return e=e.ownerDocument||e,i=e.createElement("script"),ge(i),Ee(i,"link",a),e.head.appendChild(i),t.instance=i;case"void":return null;default:throw Error(S(443,t.type))}else t.type==="stylesheet"&&(t.state.loading&4)===0&&(a=t.instance,t.state.loading|=4,vo(a,n.precedence,e));return t.instance}function vo(e,t,n){for(var a=n.querySelectorAll('link[rel="stylesheet"][data-precedence],style[data-precedence]'),i=a.length?a[a.length-1]:null,l=i,o=0;o<a.length;o++){var r=a[o];if(r.dataset.precedence===t)l=r;else if(l!==i)break}l?l.parentNode.insertBefore(e,l.nextSibling):(t=n.nodeType===9?n.head:n,t.insertBefore(e,t.firstChild))}function zc(e,t){e.crossOrigin==null&&(e.crossOrigin=t.crossOrigin),e.referrerPolicy==null&&(e.referrerPolicy=t.referrerPolicy),e.title==null&&(e.title=t.title)}function Rc(e,t){e.crossOrigin==null&&(e.crossOrigin=t.crossOrigin),e.referrerPolicy==null&&(e.referrerPolicy=t.referrerPolicy),e.integrity==null&&(e.integrity=t.integrity)}function vh(e,t,n){if(go===null){var a=new Map,i=go=new Map;i.set(n,a)}else i=go,a=i.get(n),a||(a=new Map,i.set(n,a));if(a.has(e))return a;a.set(e,null),n=n.getElementsByTagName(e);for(i=0;i<n.length;i++){var l=n[i];if(!(l[gl]||l[_e]||e==="link"&&l.getAttribute("rel")==="stylesheet")&&l.namespaceURI!=="http://www.w3.org/2000/svg"){var o=l.getAttribute(t)||"";o=e+o;var r=a.get(o);r?r.push(l):a.set(o,[l])}}return a}function gh(e,t,n){e=e.ownerDocument||e,e.head.insertBefore(n,t==="title"?e.querySelector("head > title"):null)}function k_(e,t,n){if(n===1||t.itemProp!=null)return!1;switch(e){case"meta":case"title":return!0;case"style":if(typeof t.precedence!=="string"||typeof t.href!=="string"||t.href==="")break;return!0;case"link":if(typeof t.rel!=="string"||typeof t.href!=="string"||t.href===""||t.onLoad||t.onError)break;switch(t.rel){case"stylesheet":return e=t.disabled,typeof t.precedence==="string"&&e==null;default:return!0}case"script":if(t.async&&typeof t.async!=="function"&&typeof t.async!=="symbol"&&!t.onLoad&&!t.onError&&t.src&&typeof t.src==="string")return!0}return!1}function nv(e){return e.type==="stylesheet"&&(e.state.loading&3)===0?!1:!0}function V_(e,t,n,a){if(n.type==="stylesheet"&&(typeof a.media!=="string"||matchMedia(a.media).matches!==!1)&&(n.state.loading&4)===0){if(n.instance===null){var i=Ia(a.href),l=t.querySelector(El(i));if(l){t=l._p,t!==null&&typeof t==="object"&&typeof t.then==="function"&&(e.count++,e=Xo.bind(e),t.then(e,e)),n.state.loading|=4,n.instance=l,ge(l);return}l=t.ownerDocument||t,a=tv(a),(i=lt.get(i))&&zc(a,i),l=l.createElement("link"),ge(l);var o=l;o._p=new Promise(function(r,s){o.onload=r,o.onerror=s}),Ee(l,"link",a),n.instance=l}e.stylesheets===null&&(e.stylesheets=new Map),e.stylesheets.set(n,t),(t=n.state.preload)&&(n.state.loading&3)===0&&(e.count++,n=Xo.bind(e),t.addEventListener("load",n),t.addEventListener("error",n))}}function L_(e,t){return e.stylesheets&&e.count===0&&bo(e,e.stylesheets),0<e.count||0<e.imgCount?function(n){var a=setTimeout(function(){if(e.stylesheets&&bo(e,e.stylesheets),e.unsuspend){var l=e.unsuspend;e.unsuspend=null,l()}},60000+t);0<e.imgBytes&&Gs===0&&(Gs=62500*g_());var i=setTimeout(function(){if(e.waitingForImages=!1,e.count===0&&(e.stylesheets&&bo(e,e.stylesheets),e.unsuspend)){var l=e.unsuspend;e.unsuspend=null,l()}},(e.imgBytes>Gs?50:800)+t);return e.unsuspend=n,function(){e.unsuspend=null,clearTimeout(a),clearTimeout(i)}}:null}function Xo(){if(this.count--,this.count===0&&(this.imgCount===0||!this.waitingForImages)){if(this.stylesheets)bo(this,this.stylesheets);else if(this.unsuspend){var e=this.unsuspend;this.unsuspend=null,e()}}}function bo(e,t){e.stylesheets=null,e.unsuspend!==null&&(e.count++,Qo=new Map,t.forEach(B_,e),Qo=null,Xo.call(e))}function B_(e,t){if(!(t.state.loading&4)){var n=Qo.get(e);if(n)var a=n.get(null);else{n=new Map,Qo.set(e,n);for(var i=e.querySelectorAll("link[data-precedence],style[data-precedence]"),l=0;l<i.length;l++){var o=i[l];if(o.nodeName==="LINK"||o.getAttribute("media")!=="not all")n.set(o.dataset.precedence,o),a=o}a&&n.set(null,a)}i=t.instance,o=i.getAttribute("data-precedence"),l=n.get(o)||a,l===a&&n.set(null,i),n.set(o,i),this.count++,a=Xo.bind(this),i.addEventListener("load",a),i.addEventListener("error",a),l?l.parentNode.insertBefore(i,l.nextSibling):(e=e.nodeType===9?e.head:e,e.insertBefore(i,e.firstChild)),t.state.loading|=4}}function H_(e,t,n,a,i,l,o,r,s){this.tag=1,this.containerInfo=e,this.pingCache=this.current=this.pendingChildren=null,this.timeoutHandle=-1,this.callbackNode=this.next=this.pendingContext=this.context=this.cancelPendingCommit=null,this.callbackPriority=0,this.expirationTimes=ms(-1),this.entangledLanes=this.shellSuspendCounter=this.errorRecoveryDisabledLanes=this.expiredLanes=this.warmLanes=this.pingedLanes=this.suspendedLanes=this.pendingLanes=0,this.entanglements=ms(0),this.hiddenUpdates=ms(null),this.identifierPrefix=a,this.onUncaughtError=i,this.onCaughtError=l,this.onRecoverableError=o,this.pooledCache=null,this.pooledCacheLanes=0,this.formState=s,this.incompleteTransitions=new Map}function av(e,t,n,a,i,l,o,r,s,c,m,b){return e=new H_(e,t,n,o,s,c,m,b,r),t=1,l===!0&&(t|=24),l=Le(3,null,null,t),e.current=l,l.stateNode=e,t=ac(),t.refCount++,e.pooledCache=t,t.refCount++,l.memoizedState={element:a,isDehydrated:n,cache:t},oc(l),e}function iv(e){if(!e)return Ma;return e=Ma,e}function lv(e,t,n,a,i,l){i=iv(i),a.context===null?a.context=i:a.pendingContext=i,a=bn(t),a.payload={element:n},l=l===void 0?null:l,l!==null&&(a.callback=l),n=yn(e,a,t),n!==null&&(Me(n,e,t),Ki(n,e,t))}function bh(e,t){if(e=e.memoizedState,e!==null&&e.dehydrated!==null){var n=e.retryLane;e.retryLane=n!==0&&n<t?n:t}}function Mc(e,t){bh(e,t),(e=e.alternate)&&bh(e,t)}function ov(e){if(e.tag===13||e.tag===31){var t=la(e,67108864);t!==null&&Me(t,e,67108864),Mc(e,67108864)}}function yh(e){if(e.tag===13||e.tag===31){var t=Ge();t=Yu(t);var n=la(e,t);n!==null&&Me(n,e,t),Mc(e,t)}}function j_(e,t,n,a){var i=z.T;z.T=null;var l=X.p;try{X.p=2,Cc(e,t,n,a)}finally{X.p=l,z.T=i}}function q_(e,t,n,a){var i=z.T;z.T=null;var l=X.p;try{X.p=8,Cc(e,t,n,a)}finally{X.p=l,z.T=i}}function Cc(e,t,n,a){if(Zo){var i=Bu(a);if(i===null)js(e,t,a,$o,n),_h(e,a);else if(Y_(i,e,t,n,a))a.stopPropagation();else if(_h(e,a),t&4&&-1<G_.indexOf(e)){for(;i!==null;){var l=ti(i);if(l!==null)switch(l.tag){case 3:if(l=l.stateNode,l.current.memoizedState.isDehydrated){var o=Gn(l.pendingLanes);if(o!==0){var r=l;r.pendingLanes|=2;for(r.entangledLanes|=2;o;){var s=1<<31-qe(o);r.entanglements[1]|=s,o&=~s}Ot(l),(K&6)===0&&(Lo=He()+500,xl(0,!1))}}break;case 31:case 13:r=la(l,2),r!==null&&Me(r,l,2),sr(),Mc(l,2)}if(l=Bu(a),l===null&&js(e,t,a,$o,n),l===i)break;i=l}i!==null&&a.stopPropagation()}else js(e,t,a,null,n)}}function Bu(e){return e=Zu(e),Uc(e)}function Uc(e){if($o=null,e=Oa(e),e!==null){var t=hl(e);if(t===null)e=null;else{var n=t.tag;if(n===13){if(e=Oh(t),e!==null)return e;e=null}else if(n===31){if(e=Ah(t),e!==null)return e;e=null}else if(n===3){if(t.stateNode.current.memoizedState.isDehydrated)return t.tag===3?t.stateNode.containerInfo:null;e=null}else t!==e&&(e=null)}}return $o=e,null}function rv(e){switch(e){case"beforetoggle":case"cancel":case"click":case"close":case"contextmenu":case"copy":case"cut":case"auxclick":case"dblclick":case"dragend":case"dragstart":case"drop":case"focusin":case"focusout":case"input":case"invalid":case"keydown":case"keypress":case"keyup":case"mousedown":case"mouseup":case"paste":case"pause":case"play":case"pointercancel":case"pointerdown":case"pointerup":case"ratechange":case"reset":case"resize":case"seeked":case"submit":case"toggle":case"touchcancel":case"touchend":case"touchstart":case"volumechange":case"change":case"selectionchange":case"textInput":case"compositionstart":case"compositionend":case"compositionupdate":case"beforeblur":case"afterblur":case"beforeinput":case"blur":case"fullscreenchange":case"focus":case"hashchange":case"popstate":case"select":case"selectstart":return 2;case"drag":case"dragenter":case"dragexit":case"dragleave":case"dragover":case"mousemove":case"mouseout":case"mouseover":case"pointermove":case"pointerout":case"pointerover":case"scroll":case"touchmove":case"wheel":case"mouseenter":case"mouseleave":case"pointerenter":case"pointerleave":return 8;case"message":switch(D0()){case Rh:return 2;case Mh:return 8;case Eo:case z0:return 32;case Ch:return 268435456;default:return 32}default:return 32}}function _h(e,t){switch(e){case"focusin":case"focusout":xn=null;break;case"dragenter":case"dragleave":En=null;break;case"mouseover":case"mouseout":wn=null;break;case"pointerover":case"pointerout":fl.delete(t.pointerId);break;case"gotpointercapture":case"lostpointercapture":dl.delete(t.pointerId)}}function zi(e,t,n,a,i,l){if(e===null||e.nativeEvent!==l)return e={blockedOn:t,domEventName:n,eventSystemFlags:a,nativeEvent:l,targetContainers:[i]},t!==null&&(t=ti(t),t!==null&&ov(t)),e;return e.eventSystemFlags|=a,t=e.targetContainers,i!==null&&t.indexOf(i)===-1&&t.push(i),e}function Y_(e,t,n,a,i){switch(t){case"focusin":return xn=zi(xn,e,t,n,a,i),!0;case"dragenter":return En=zi(En,e,t,n,a,i),!0;case"mouseover":return wn=zi(wn,e,t,n,a,i),!0;case"pointerover":var l=i.pointerId;return fl.set(l,zi(fl.get(l)||null,e,t,n,a,i)),!0;case"gotpointercapture":return l=i.pointerId,dl.set(l,zi(dl.get(l)||null,e,t,n,a,i)),!0}return!1}function sv(e){var t=Oa(e.target);if(t!==null){var n=hl(t);if(n!==null){if(t=n.tag,t===13){if(t=Oh(n),t!==null){e.blockedOn=t,ld(e.priority,function(){yh(n)});return}}else if(t===31){if(t=Ah(n),t!==null){e.blockedOn=t,ld(e.priority,function(){yh(n)});return}}else if(t===3&&n.stateNode.current.memoizedState.isDehydrated){e.blockedOn=n.tag===3?n.stateNode.containerInfo:null;return}}}e.blockedOn=null}function yo(e){if(e.blockedOn!==null)return!1;for(var t=e.targetContainers;0<t.length;){var n=Bu(e.nativeEvent);if(n===null){n=e.nativeEvent;var a=new n.constructor(n.type,n);tu=a,n.target.dispatchEvent(a),tu=null}else return t=ti(n),t!==null&&ov(t),e.blockedOn=n,!1;t.shift()}return!0}function Sh(e,t,n){yo(e)&&n.delete(t)}function K_(){Hu=!1,xn!==null&&yo(xn)&&(xn=null),En!==null&&yo(En)&&(En=null),wn!==null&&yo(wn)&&(wn=null),fl.forEach(Sh),dl.forEach(Sh)}function to(e,t){e.blockedOn===t&&(e.blockedOn=null,Hu||(Hu=!0,va(ma,K_)))}function xh(e){no!==e&&(no=e,va(ma,function(){no===e&&(no=null);for(var t=0;t<e.length;t+=3){var n=e[t],a=e[t+1],i=e[t+2];if(typeof a!=="function")if(Uc(a||n)===null)continue;else break;var l=ti(n);l!==null&&(e.splice(t,3),t-=3,gu(l,{pending:!0,data:i,method:n.method,action:a},a,i))}}))}function Pa(e){function t(s){return to(s,e)}xn!==null&&to(xn,e),En!==null&&to(En,e),wn!==null&&to(wn,e),fl.forEach(t),dl.forEach(t);for(var n=0;n<cn.length;n++){var a=cn[n];a.blockedOn===e&&(a.blockedOn=null)}for(;0<cn.length&&(n=cn[0],n.blockedOn===null);)sv(n),n.blockedOn===null&&cn.shift();if(n=(e.ownerDocument||e).$$reactFormReplay,n!=null)for(a=0;a<n.length;a+=3){var i=n[a],l=n[a+1],o=i[Ce]||null;if(typeof l==="function")o||xh(n);else if(o){var r=null;if(l&&l.hasAttribute("formAction")){if(i=l,o=l[Ce]||null)r=o.formAction;else if(Uc(i)!==null)continue}else r=o.action;typeof r==="function"?n[a+1]=r:(n.splice(a,3),a-=3),xh(n)}}}function uv(){function e(l){l.canIntercept&&l.info==="react-transition"&&l.intercept({handler:function(){return new Promise(function(o){return i=o})},focusReset:"manual",scroll:"manual"})}function t(){i!==null&&(i(),i=null),a||setTimeout(n,20)}function n(){if(!a&&!navigation.transition){var l=navigation.currentEntry;l&&l.url!=null&&navigation.navigate(l.url,{state:l.getState(),info:"react-transition",history:"replace"})}}if(typeof navigation==="object"){var a=!1,i=null;return navigation.addEventListener("navigate",e),navigation.addEventListener("navigatesuccess",t),navigation.addEventListener("navigateerror",t),setTimeout(n,100),function(){a=!0,navigation.removeEventListener("navigate",e),navigation.removeEventListener("navigatesuccess",t),navigation.removeEventListener("navigateerror",t),i!==null&&(i(),i=null)}}}function kc(e){this._internalRoot=e}function fr(e){this._internalRoot=e}var Jo,wh,ae,E0,Yl,Ri,wa,Dh,Ys,zh,Lt,ju,Ks,Xs,qu,ln,Qs,w0,nd,N0,Mi,z,X,Qn,$s,Na=-1,wt,Pi,vn,_o,fs,ad,ds=!1,Fs,Gu,ps,A0,T0,He,D0,Rh,Mh,Eo,z0,Ch,R0,M0,pl=null,je=null,qe,C0,U0,Kl=256,Xl=262144,Ql=4194304,Dn,_e,Ce,ei,Ws,B0,H0,od,gl,Hh,jh,j0,rd,sd,Y0,K0,X0,Q0,tu=null,Aa=null,Ba=null,vs=!1,Yt,nu=!1,Yn,dn=null,$u=null,lo=null,aa,Wo,bl,Z0,gs,bs,Oi,Io,dd,$0,J0,F0,ys,W0,I0,P0,e1,t1,hd,n1,a1,i1,o1,r1,s1,pd,u1,c1,f1,d1,h1,p1,m1,v1,g1,Fu,ji=null,b1,Jh,md,vd=!1,Ta=!1,S1,qi=null,tl=null,Ph=!1,Ui,ki,ro,Ye,T1,Da=null,au=null,Gi=null,iu=!1,za,_s,ap,ip,lp,op,D1,z1,R1,rp,sp,lu,No,Fe,Ra=0,Iu=0,Ma,Ed,Ca,Ua=0,Ao=null,al=0,Ie,Pe=0,Nn=null,St=1,xt="",Se=null,ne=null,G=!1,gn=null,nt=!1,ou,ru,oa=null,Ht=null,C1,U1,k1,fe,Yi=null,cu=0,Qa=0,Ha=null,Ad,$n,ai,lc,nr,Do,Jn=null,ja=null,ll=0,Pn,bp,on=!1,du=!1,Za,zo,Ke,at=null,re,Kt=0,C=null,J=null,ue=null,Mo=!1,qa=!1,ea=!1,Co=0,ol=0,Ga=null,B1=0,rl,Ip,_c,Pp,bu,Sc,de=!1,As,Vt=!1,ce=!1,ks=!1,Fd,ve=null,ie=null,ze=!1,ht=null,Li=8192,P1,e_,K=0,F=null,j=null,q=0,Q=0,ke=null,hn=!1,ii=!1,Nc=!1,Zt=0,oe=0,Tn=0,Fn=0,Oc=0,Be=0,Ja=0,Fi=null,Re=null,Eu=!1,rr=0,Tm=0,Lo=1/0,Bo=null,_n=null,pe=0,Sn=null,Fa=null,Gt=0,wu=0,Nu=null,Dm=null,Wi=0,Ou=null,jo=null,xa=null,Au=!1,qo=!1,Bs=!1,mn=0,Hi,Tu,Du,Bi,sl,d_,eo,p_,m_,Ru=null,Mu=null,qs=null,Wm,y_,sh,__,Lu=null,lt,hh,$t,li,go=null,Gs=0,Qo=null,cl,Zo=!0,$o=null,Hu=!1,xn=null,En=null,wn=null,fl,dl,cn,G_,no=null,Eh,X_,Ea,cv=function(e,t){if(!Nh(e))throw Error(S(299));var n=!1,a="",i=em,l=tm,o=nm;return t!==null&&t!==void 0&&(t.unstable_strictMode===!0&&(n=!0),t.identifierPrefix!==void 0&&(a=t.identifierPrefix),t.onUncaughtError!==void 0&&(i=t.onUncaughtError),t.onCaughtError!==void 0&&(l=t.onCaughtError),t.onRecoverableError!==void 0&&(o=t.onRecoverableError)),t=av(e,1,!1,null,null,n,a,null,i,l,o,uv),e[ei]=t.current,Dc(e),new kc(t)},fv=function(e,t,n){if(!Nh(e))throw Error(S(299));var a=!1,i="",l=em,o=tm,r=nm,s=null;return n!==null&&n!==void 0&&(n.unstable_strictMode===!0&&(a=!0),n.identifierPrefix!==void 0&&(i=n.identifierPrefix),n.onUncaughtError!==void 0&&(l=n.onUncaughtError),n.onCaughtError!==void 0&&(o=n.onCaughtError),n.onRecoverableError!==void 0&&(r=n.onRecoverableError),n.formState!==void 0&&(s=n.formState)),t=av(e,1,!0,t,n!=null?n:null,a,i,s,l,o,r,uv),t.context=iv(null),n=t.current,a=Ge(),a=Yu(a),i=bn(a),i.callback=null,yn(n,i,a),n=a,t.current.lanes=n,vl(t,n),Ot(t),e[ei]=t.current,Dc(e),new fr(t)},dv="19.2.8";var hv=Hr(()=>{wf();Jo=$e(ft(),1),wh=$e(ed(),1);ae=Object.assign,E0=Symbol.for("react.element"),Yl=Symbol.for("react.transitional.element"),Ri=Symbol.for("react.portal"),wa=Symbol.for("react.fragment"),Dh=Symbol.for("react.strict_mode"),Ys=Symbol.for("react.profiler"),zh=Symbol.for("react.consumer"),Lt=Symbol.for("react.context"),ju=Symbol.for("react.forward_ref"),Ks=Symbol.for("react.suspense"),Xs=Symbol.for("react.suspense_list"),qu=Symbol.for("react.memo"),ln=Symbol.for("react.lazy"),Qs=Symbol.for("react.activity"),w0=Symbol.for("react.memo_cache_sentinel"),nd=Symbol.iterator;N0=Symbol.for("react.client.reference");Mi=Array.isArray,z=Jo.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,X=wh.__DOM_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,Qn={pending:!1,data:null,method:null,action:null},$s=[];wt=Nt(null),Pi=Nt(null),vn=Nt(null),_o=Nt(null);Fs=Object.prototype.hasOwnProperty,Gu=va,ps=Pr,A0=ns,T0=ts,He=_t,D0=es,Rh=Fr,Mh=Ir,Eo=ma,z0=Wr,Ch=Jr,R0=void 0,M0=void 0;qe=Math.clz32?Math.clz32:k0,C0=Math.log,U0=Math.LN2;Dn=Math.random().toString(36).slice(2),_e="__reactFiber$"+Dn,Ce="__reactProps$"+Dn,ei="__reactContainer$"+Dn,Ws="__reactEvents$"+Dn,B0="__reactListeners$"+Dn,H0="__reactHandles$"+Dn,od="__reactResources$"+Dn,gl="__reactMarker$"+Dn;Hh=new Set,jh={};j0=RegExp("^[: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]*$"),rd={},sd={};Y0=/[\n"\\]/g;K0=new Set("animationIterationCount aspectRatio borderImageOutset borderImageSlice borderImageWidth boxFlex boxFlexGroup boxOrdinalGroup columnCount columns flex flexGrow flexPositive flexShrink flexNegative flexOrder gridArea gridRow gridRowEnd gridRowSpan gridRowStart gridColumn gridColumnEnd gridColumnSpan gridColumnStart fontWeight lineClamp lineHeight opacity order orphans scale tabSize widows zIndex zoom fillOpacity floodOpacity stopOpacity strokeDasharray strokeDashoffset strokeMiterlimit strokeOpacity strokeWidth MozAnimationIterationCount MozBoxFlex MozBoxFlexGroup MozLineClamp msAnimationIterationCount msFlex msZoom msFlexGrow msFlexNegative msFlexOrder msFlexPositive msFlexShrink msGridColumn msGridColumnSpan msGridRow msGridRowSpan WebkitAnimationIterationCount WebkitBoxFlex WebKitBoxFlexGroup WebkitBoxOrdinalGroup WebkitColumnCount WebkitColumns WebkitFlex WebkitFlexGrow WebkitFlexPositive WebkitFlexShrink WebkitLineClamp".split(" "));X0=new Map([["acceptCharset","accept-charset"],["htmlFor","for"],["httpEquiv","http-equiv"],["crossOrigin","crossorigin"],["accentHeight","accent-height"],["alignmentBaseline","alignment-baseline"],["arabicForm","arabic-form"],["baselineShift","baseline-shift"],["capHeight","cap-height"],["clipPath","clip-path"],["clipRule","clip-rule"],["colorInterpolation","color-interpolation"],["colorInterpolationFilters","color-interpolation-filters"],["colorProfile","color-profile"],["colorRendering","color-rendering"],["dominantBaseline","dominant-baseline"],["enableBackground","enable-background"],["fillOpacity","fill-opacity"],["fillRule","fill-rule"],["floodColor","flood-color"],["floodOpacity","flood-opacity"],["fontFamily","font-family"],["fontSize","font-size"],["fontSizeAdjust","font-size-adjust"],["fontStretch","font-stretch"],["fontStyle","font-style"],["fontVariant","font-variant"],["fontWeight","font-weight"],["glyphName","glyph-name"],["glyphOrientationHorizontal","glyph-orientation-horizontal"],["glyphOrientationVertical","glyph-orientation-vertical"],["horizAdvX","horiz-adv-x"],["horizOriginX","horiz-origin-x"],["imageRendering","image-rendering"],["letterSpacing","letter-spacing"],["lightingColor","lighting-color"],["markerEnd","marker-end"],["markerMid","marker-mid"],["markerStart","marker-start"],["overlinePosition","overline-position"],["overlineThickness","overline-thickness"],["paintOrder","paint-order"],["panose-1","panose-1"],["pointerEvents","pointer-events"],["renderingIntent","rendering-intent"],["shapeRendering","shape-rendering"],["stopColor","stop-color"],["stopOpacity","stop-opacity"],["strikethroughPosition","strikethrough-position"],["strikethroughThickness","strikethrough-thickness"],["strokeDasharray","stroke-dasharray"],["strokeDashoffset","stroke-dashoffset"],["strokeLinecap","stroke-linecap"],["strokeLinejoin","stroke-linejoin"],["strokeMiterlimit","stroke-miterlimit"],["strokeOpacity","stroke-opacity"],["strokeWidth","stroke-width"],["textAnchor","text-anchor"],["textDecoration","text-decoration"],["textRendering","text-rendering"],["transformOrigin","transform-origin"],["underlinePosition","underline-position"],["underlineThickness","underline-thickness"],["unicodeBidi","unicode-bidi"],["unicodeRange","unicode-range"],["unitsPerEm","units-per-em"],["vAlphabetic","v-alphabetic"],["vHanging","v-hanging"],["vIdeographic","v-ideographic"],["vMathematical","v-mathematical"],["vectorEffect","vector-effect"],["vertAdvY","vert-adv-y"],["vertOriginX","vert-origin-x"],["vertOriginY","vert-origin-y"],["wordSpacing","word-spacing"],["writingMode","writing-mode"],["xmlnsXlink","xmlns:xlink"],["xHeight","x-height"]]),Q0=/^[\u0000-\u001F ]*j[\r\n\t]*a[\r\n\t]*v[\r\n\t]*a[\r\n\t]*s[\r\n\t]*c[\r\n\t]*r[\r\n\t]*i[\r\n\t]*p[\r\n\t]*t[\r\n\t]*:/i;Yt=!(typeof window>"u"||typeof window.document>"u"||typeof window.document.createElement>"u");if(Yt)try{Yn={},Object.defineProperty(Yn,"passive",{get:function(){nu=!0}}),window.addEventListener("test",Yn,Yn),window.removeEventListener("test",Yn,Yn)}catch(e){nu=!1}aa={eventPhase:0,bubbles:0,cancelable:0,timeStamp:function(e){return e.timeStamp||Date.now()},defaultPrevented:0,isTrusted:0},Wo=Ue(aa),bl=ae({},aa,{view:0,detail:0}),Z0=Ue(bl),Io=ae({},bl,{screenX:0,screenY:0,clientX:0,clientY:0,pageX:0,pageY:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,getModifierState:Ju,button:0,buttons:0,relatedTarget:function(e){return e.relatedTarget===void 0?e.fromElement===e.srcElement?e.toElement:e.fromElement:e.relatedTarget},movementX:function(e){if("movementX"in e)return e.movementX;return e!==Oi&&(Oi&&e.type==="mousemove"?(gs=e.screenX-Oi.screenX,bs=e.screenY-Oi.screenY):bs=gs=0,Oi=e),gs},movementY:function(e){return"movementY"in e?e.movementY:bs}}),dd=Ue(Io),$0=ae({},Io,{dataTransfer:0}),J0=Ue($0),F0=ae({},bl,{relatedTarget:0}),ys=Ue(F0),W0=ae({},aa,{animationName:0,elapsedTime:0,pseudoElement:0}),I0=Ue(W0),P0=ae({},aa,{clipboardData:function(e){return"clipboardData"in e?e.clipboardData:window.clipboardData}}),e1=Ue(P0),t1=ae({},aa,{data:0}),hd=Ue(t1),n1={Esc:"Escape",Spacebar:" ",Left:"ArrowLeft",Up:"ArrowUp",Right:"ArrowRight",Down:"ArrowDown",Del:"Delete",Win:"OS",Menu:"ContextMenu",Apps:"ContextMenu",Scroll:"ScrollLock",MozPrintableKey:"Unidentified"},a1={8:"Backspace",9:"Tab",12:"Clear",13:"Enter",16:"Shift",17:"Control",18:"Alt",19:"Pause",20:"CapsLock",27:"Escape",32:" ",33:"PageUp",34:"PageDown",35:"End",36:"Home",37:"ArrowLeft",38:"ArrowUp",39:"ArrowRight",40:"ArrowDown",45:"Insert",46:"Delete",112:"F1",113:"F2",114:"F3",115:"F4",116:"F5",117:"F6",118:"F7",119:"F8",120:"F9",121:"F10",122:"F11",123:"F12",144:"NumLock",145:"ScrollLock",224:"Meta"},i1={Alt:"altKey",Control:"ctrlKey",Meta:"metaKey",Shift:"shiftKey"};o1=ae({},bl,{key:function(e){if(e.key){var t=n1[e.key]||e.key;if(t!=="Unidentified")return t}return e.type==="keypress"?(e=oo(e),e===13?"Enter":String.fromCharCode(e)):e.type==="keydown"||e.type==="keyup"?a1[e.keyCode]||"Unidentified":""},code:0,location:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,repeat:0,locale:0,getModifierState:Ju,charCode:function(e){return e.type==="keypress"?oo(e):0},keyCode:function(e){return e.type==="keydown"||e.type==="keyup"?e.keyCode:0},which:function(e){return e.type==="keypress"?oo(e):e.type==="keydown"||e.type==="keyup"?e.keyCode:0}}),r1=Ue(o1),s1=ae({},Io,{pointerId:0,width:0,height:0,pressure:0,tangentialPressure:0,tiltX:0,tiltY:0,twist:0,pointerType:0,isPrimary:0}),pd=Ue(s1),u1=ae({},bl,{touches:0,targetTouches:0,changedTouches:0,altKey:0,metaKey:0,ctrlKey:0,shiftKey:0,getModifierState:Ju}),c1=Ue(u1),f1=ae({},aa,{propertyName:0,elapsedTime:0,pseudoElement:0}),d1=Ue(f1),h1=ae({},Io,{deltaX:function(e){return"deltaX"in e?e.deltaX:("wheelDeltaX"in e)?-e.wheelDeltaX:0},deltaY:function(e){return"deltaY"in e?e.deltaY:("wheelDeltaY"in e)?-e.wheelDeltaY:("wheelDelta"in e)?-e.wheelDelta:0},deltaZ:0,deltaMode:0}),p1=Ue(h1),m1=ae({},aa,{newState:0,oldState:0}),v1=Ue(m1),g1=[9,13,27,32],Fu=Yt&&"CompositionEvent"in window;Yt&&"documentMode"in document&&(ji=document.documentMode);b1=Yt&&"TextEvent"in window&&!ji,Jh=Yt&&(!Fu||ji&&8<ji&&11>=ji),md=String.fromCharCode(32);S1={color:!0,date:!0,datetime:!0,"datetime-local":!0,email:!0,month:!0,number:!0,password:!0,range:!0,search:!0,tel:!0,text:!0,time:!0,url:!0,week:!0};if(Yt){if(Yt){if(ki="oninput"in document,!ki)ro=document.createElement("div"),ro.setAttribute("oninput","return;"),ki=typeof ro.oninput==="function";Ui=ki}else Ui=!1;Ph=Ui&&(!document.documentMode||9<document.documentMode)}Ye=typeof Object.is==="function"?Object.is:A1;T1=Yt&&"documentMode"in document&&11>=document.documentMode;za={animationend:jn("Animation","AnimationEnd"),animationiteration:jn("Animation","AnimationIteration"),animationstart:jn("Animation","AnimationStart"),transitionrun:jn("Transition","TransitionRun"),transitionstart:jn("Transition","TransitionStart"),transitioncancel:jn("Transition","TransitionCancel"),transitionend:jn("Transition","TransitionEnd")},_s={},ap={};Yt&&(ap=document.createElement("div").style,("AnimationEvent"in window)||(delete za.animationend.animation,delete za.animationiteration.animation,delete za.animationstart.animation),("TransitionEvent"in window)||delete za.transitionend.transition);ip=ia("animationend"),lp=ia("animationiteration"),op=ia("animationstart"),D1=ia("transitionrun"),z1=ia("transitionstart"),R1=ia("transitioncancel"),rp=ia("transitionend"),sp=new Map,lu="abort auxClick beforeToggle cancel canPlay canPlayThrough click close contextMenu copy cut drag dragEnd dragEnter dragExit dragLeave dragOver dragStart drop durationChange emptied encrypted ended error gotPointerCapture input invalid keyDown keyPress keyUp load loadedData loadedMetadata loadStart lostPointerCapture mouseDown mouseMove mouseOut mouseOver mouseUp paste pause play playing pointerCancel pointerDown pointerMove pointerOut pointerOver pointerUp progress rateChange reset resize seeked seeking stalled submit suspend timeUpdate touchCancel touchEnd touchStart volumeChange scroll toggle touchMove waiting wheel".split(" ");lu.push("scrollEnd");No=typeof reportError==="function"?reportError:function(e){if(typeof window==="object"&&typeof window.ErrorEvent==="function"){var t=new window.ErrorEvent("error",{bubbles:!0,cancelable:!0,message:typeof e==="object"&&e!==null&&typeof e.message==="string"?String(e.message):String(e),error:e});if(!window.dispatchEvent(t))return}else if(typeof process==="object"&&typeof process.emit==="function"){process.emit("uncaughtException",e);return}console.error(e)},Fe=[];Ma={};Ed=new WeakMap;Ca=[],Ie=[];ou=Error(S(519));ru=Nt(null);C1=typeof AbortController<"u"?AbortController:function(){var e=[],t=this.signal={aborted:!1,addEventListener:function(n,a){e.push(a)}};this.abort=function(){t.aborted=!0,e.forEach(function(n){return n()})}},U1=va,k1=ma,fe={$$typeof:Lt,Consumer:null,Provider:null,_currentValue:null,_currentValue2:null,_threadCount:0};Ad=z.S;z.S=function(e,t){Tm=He(),typeof t==="object"&&t!==null&&typeof t.then==="function"&&V1(e,t),Ad!==null&&Ad(e,t)};$n=Nt(null);ai=Error(S(460)),lc=Error(S(474)),nr=Error(S(542)),Do={then:function(){}};Pn=gp(!0),bp=gp(!1);Za=Nt(null),zo=Nt(0);Ke=Nt(null);re=Nt(0);rl={readContext:xe,use:ir,useCallback:le,useContext:le,useEffect:le,useImperativeHandle:le,useLayoutEffect:le,useInsertionEffect:le,useMemo:le,useReducer:le,useRef:le,useState:le,useDebugValue:le,useDeferredValue:le,useTransition:le,useSyncExternalStore:le,useId:le,useHostTransitionStatus:le,useFormState:le,useActionState:le,useOptimistic:le,useMemoCache:le,useCacheRefresh:le};rl.useEffectEvent=le;Ip={readContext:xe,use:ir,useCallback:function(e,t){return Ae().memoizedState=[e,t===void 0?null:t],e},useContext:xe,useEffect:Ld,useImperativeHandle:function(e,t,n){n=n!==null&&n!==void 0?n.concat([e]):null,fo(4194308,4,Hp.bind(null,t,e),n)},useLayoutEffect:function(e,t){return fo(4194308,4,e,t)},useInsertionEffect:function(e,t){fo(4,2,e,t)},useMemo:function(e,t){var n=Ae();t=t===void 0?null:t;var a=e();if(ea){fn(!0);try{e()}finally{fn(!1)}}return n.memoizedState=[a,t],a},useReducer:function(e,t,n){var a=Ae();if(n!==void 0){var i=n(t);if(ea){fn(!0);try{n(t)}finally{fn(!1)}}}else i=t;return a.memoizedState=a.baseState=i,e={pending:null,lanes:0,dispatch:null,lastRenderedReducer:e,lastRenderedState:i},a.queue=e,e=e.dispatch=X1.bind(null,C,e),[a.memoizedState,e]},useRef:function(e){var t=Ae();return e={current:e},t.memoizedState=e},useState:function(e){e=mu(e);var t=e.queue,n=Jp.bind(null,C,t);return t.dispatch=n,[e.memoizedState,n]},useDebugValue:vc,useDeferredValue:function(e,t){var n=Ae();return gc(n,e,t)},useTransition:function(){var e=mu(!1);return e=Kp.bind(null,C,e.queue,!0,!1),Ae().memoizedState=e,[!1,e]},useSyncExternalStore:function(e,t,n){var a=C,i=Ae();if(G){if(n===void 0)throw Error(S(407));n=n()}else{if(n=t(),F===null)throw Error(S(349));(q&127)!==0||Np(a,t,n)}i.memoizedState=n;var l={value:n,getSnapshot:t};return i.queue=l,Ld(Ap.bind(null,a,l,e),[e]),a.flags|=2048,$a(9,{destroy:void 0},Op.bind(null,a,l,n,t),null),n},useId:function(){var e=Ae(),t=F.identifierPrefix;if(G){var n=xt,a=St;n=(a&~(1<<32-qe(a)-1)).toString(32)+n,t="_"+t+"R_"+n,n=Co++,0<n&&(t+="H"+n.toString(32)),t+="_"}else n=B1++,t="_"+t+"r_"+n.toString(32)+"_";return e.memoizedState=t},useHostTransitionStatus:bc,useFormState:Ud,useActionState:Ud,useOptimistic:function(e){var t=Ae();t.memoizedState=t.baseState=e;var n={pending:null,lanes:0,dispatch:null,lastRenderedReducer:null,lastRenderedState:null};return t.queue=n,t=yc.bind(null,C,!0,n),n.dispatch=t,[e,t]},useMemoCache:hc,useCacheRefresh:function(){return Ae().memoizedState=K1.bind(null,C)},useEffectEvent:function(e){var t=Ae(),n={impl:e};return t.memoizedState=n,function(){if((K&2)!==0)throw Error(S(440));return n.impl.apply(void 0,arguments)}}},_c={readContext:xe,use:ir,useCallback:qp,useContext:xe,useEffect:mc,useImperativeHandle:jp,useInsertionEffect:Lp,useLayoutEffect:Bp,useMemo:Gp,useReducer:co,useRef:kp,useState:function(){return co(Xt)},useDebugValue:vc,useDeferredValue:function(e,t){var n=se();return Yp(n,J.memoizedState,e,t)},useTransition:function(){var e=co(Xt)[0],t=se().memoizedState;return[typeof e==="boolean"?e:_l(e),t]},useSyncExternalStore:wp,useId:Zp,useHostTransitionStatus:bc,useFormState:kd,useActionState:kd,useOptimistic:function(e,t){var n=se();return zp(n,J,e,t)},useMemoCache:hc,useCacheRefresh:$p};_c.useEffectEvent=Vp;Pp={readContext:xe,use:ir,useCallback:qp,useContext:xe,useEffect:mc,useImperativeHandle:jp,useInsertionEffect:Lp,useLayoutEffect:Bp,useMemo:Gp,useReducer:Ns,useRef:kp,useState:function(){return Ns(Xt)},useDebugValue:vc,useDeferredValue:function(e,t){var n=se();return J===null?gc(n,e,t):Yp(n,J.memoizedState,e,t)},useTransition:function(){var e=Ns(Xt)[0],t=se().memoizedState;return[typeof e==="boolean"?e:_l(e),t]},useSyncExternalStore:wp,useId:Zp,useHostTransitionStatus:bc,useFormState:Vd,useActionState:Vd,useOptimistic:function(e,t){var n=se();if(J!==null)return zp(n,J,e,t);return n.baseState=e,[e,n.queue.dispatch]},useMemoCache:hc,useCacheRefresh:$p};Pp.useEffectEvent=Vp;bu={enqueueSetState:function(e,t,n){e=e._reactInternals;var a=Ge(),i=bn(a);i.payload=t,n!==void 0&&n!==null&&(i.callback=n),t=yn(e,i,a),t!==null&&(Me(t,e,a),Ki(t,e,a))},enqueueReplaceState:function(e,t,n){e=e._reactInternals;var a=Ge(),i=bn(a);i.tag=1,i.payload=t,n!==void 0&&n!==null&&(i.callback=n),t=yn(e,i,a),t!==null&&(Me(t,e,a),Ki(t,e,a))},enqueueForceUpdate:function(e,t){e=e._reactInternals;var n=Ge(),a=bn(n);a.tag=2,t!==void 0&&t!==null&&(a.callback=t),t=yn(e,a,n),t!==null&&(Me(t,e,n),Ki(t,e,n))}};Sc=Error(S(461));As={dehydrated:null,treeContext:null,retryLane:0,hydrationErrors:null};Fd=typeof WeakSet==="function"?WeakSet:Set;P1={getCacheForType:function(e){var t=xe(fe),n=t.data.get(e);return n===void 0&&(n=e(),t.data.set(e,n)),n},cacheSignal:function(){return xe(fe).controller.signal}},e_=typeof WeakMap==="function"?WeakMap:Map;for(Bi=0;Bi<lu.length;Bi++)Hi=lu[Bi],Tu=Hi.toLowerCase(),Du=Hi[0].toUpperCase()+Hi.slice(1),pt(Tu,"on"+Du);pt(ip,"onAnimationEnd");pt(lp,"onAnimationIteration");pt(op,"onAnimationStart");pt("dblclick","onDoubleClick");pt("focusin","onFocus");pt("focusout","onBlur");pt(D1,"onTransitionRun");pt(z1,"onTransitionStart");pt(R1,"onTransitionCancel");pt(rp,"onTransitionEnd");Ka("onMouseEnter",["mouseout","mouseover"]);Ka("onMouseLeave",["mouseout","mouseover"]);Ka("onPointerEnter",["pointerout","pointerover"]);Ka("onPointerLeave",["pointerout","pointerover"]);na("onChange","change click focusin focusout input keydown keyup selectionchange".split(" "));na("onSelect","focusout contextmenu dragend focusin keydown keyup mousedown mouseup selectionchange".split(" "));na("onBeforeInput",["compositionend","keypress","textInput","paste"]);na("onCompositionEnd","compositionend focusout keydown keypress keyup mousedown".split(" "));na("onCompositionStart","compositionstart focusout keydown keypress keyup mousedown".split(" "));na("onCompositionUpdate","compositionupdate focusout keydown keypress keyup mousedown".split(" "));sl="abort canplay canplaythrough durationchange emptied encrypted ended error loadeddata loadedmetadata loadstart pause play playing progress ratechange resize seeked seeking stalled suspend timeupdate volumechange waiting".split(" "),d_=new Set("beforetoggle cancel close invalid load scroll scrollend toggle".split(" ").concat(sl));eo="_reactListening"+Math.random().toString(36).slice(2);p_=/\r\n?/g,m_=/\u0000|\uFFFD/g;Wm=typeof setTimeout==="function"?setTimeout:void 0,y_=typeof clearTimeout==="function"?clearTimeout:void 0,sh=typeof Promise==="function"?Promise:void 0,__=typeof queueMicrotask==="function"?queueMicrotask:typeof sh<"u"?function(e){return sh.resolve(null).then(e).catch(S_)}:Wm;lt=new Map,hh=new Set;$t=X.d;X.d={f:N_,r:O_,D:A_,C:T_,L:D_,m:z_,X:M_,S:R_,M:C_};li=typeof document>"u"?null:document;cl={$$typeof:Lt,Provider:null,Consumer:null,_currentValue:Qn,_currentValue2:Qn,_threadCount:0};fl=new Map,dl=new Map,cn=[],G_="mousedown mouseup touchcancel touchend touchstart auxclick dblclick pointercancel pointerdown pointerup dragend dragstart drop compositionend compositionstart keydown keypress keyup input textInput copy cut paste click change contextmenu reset".split(" ");fr.prototype.render=kc.prototype.render=function(e){var t=this._internalRoot;if(t===null)throw Error(S(409));var n=t.current,a=Ge();lv(n,a,e,t,null,null)};fr.prototype.unmount=kc.prototype.unmount=function(){var e=this._internalRoot;if(e!==null){this._internalRoot=null;var t=e.containerInfo;lv(e.current,2,null,e,null,null),sr(),t[ei]=null}};fr.prototype.unstable_scheduleHydration=function(e){if(e){var t=Bh();e={blockedOn:null,target:e,priority:t};for(var n=0;n<cn.length&&t!==0&&t<cn[n].priority;n++);cn.splice(n,0,e),n===0&&sv(e)}};Eh=Jo.version;if(Eh!=="19.2.8")throw Error(S(527,Eh,"19.2.8"));X.findDOMNode=function(e){var t=e._reactInternals;if(t===void 0){if(typeof e.render==="function")throw Error(S(188));throw e=Object.keys(e).join(","),Error(S(268,e))}return e=x0(t),e=e!==null?Th(e):null,e=e===null?null:e.stateNode,e};X_={bundleType:0,version:"19.2.8",rendererPackageName:"react-dom",currentDispatcherRef:z,reconcilerVersion:"19.2.8"};if(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__<"u"){if(Ea=__REACT_DEVTOOLS_GLOBAL_HOOK__,!Ea.isDisabled&&Ea.supportsFiber)try{pl=Ea.inject(X_),je=Ea}catch(e){}}});var vv=Br(function(fE,mv){hv();function pv(){if(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__>"u"||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!=="function")return;try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(pv)}catch(e){console.error(e)}}pv(),mv.exports=Vc});var Fb=$e(vv(),1);function I(e,...t){throw Error(`[MobX] minified error nr: ${e}${t.length?" "+t.map(String).join(","):""}. See mobx.js.org/errors`)}var{assign:Tt,getOwnPropertyDescriptor:Xc,defineProperty:Wt,prototype:_r}=Object,Hc=[];Object.freeze(Hc);var zv={};Object.freeze(zv);var $_=Object.toString();var si=()=>{};function ci(e){return typeof e==="function"}function jc(e){switch(typeof e){case"string":case"symbol":case"number":return!0}return!1}function Sr(e){return e!==null&&typeof e==="object"}function Pt(e){if(!Sr(e))return!1;let t=Object.getPrototypeOf(e);if(t==null)return!0;let n=ra(t,"constructor")&&t.constructor;return typeof n==="function"&&n.toString()===$_}function Rv(e){let t=e==null?void 0:e.constructor;if(!t)return!1;if(t.name==="GeneratorFunction"||t.displayName==="GeneratorFunction")return!0;return!1}function Mv(e,t,n){Wt(e,t,{enumerable:!1,writable:!0,configurable:!0,value:n})}function J_(e,t,n){Wt(e,t,{enumerable:!1,writable:!1,configurable:!0,value:n})}function ca(e,t){let n="isMobX"+e;return t.prototype[n]=!0,function(a){return Sr(a)&&a[n]===!0}}function Tl(e){return e!=null&&Object.prototype.toString.call(e)==="[object Map]"}function F_(e){let t=Object.getPrototypeOf(e),n=Object.getPrototypeOf(t);return Object.getPrototypeOf(n)===null}function Rn(e){return e!=null&&Object.prototype.toString.call(e)==="[object Set]"}function W_(e){let t=Object.keys(e),n=Object.getOwnPropertySymbols(e);if(!n.length)return t;return[...t,...n.filter((a)=>_r.propertyIsEnumerable.call(e,a))]}var mr=Reflect.ownKeys;function Cv(e){return e===null?null:typeof e==="object"?""+e:e}function ra(e,t){return _r.hasOwnProperty.call(e,t)}var I_=Object.getOwnPropertyDescriptors;function Xe(e,t){return!!(e&t)}function Qe(e,t,n){if(n)e|=t;else e&=~t;return e}var V=Symbol("mobx administration");class di{constructor(e="Atom"){this.name_=void 0,this.flags_=0,this.observers_=new Set,this.lastAccessedBy_=0,this.lowestObserverState_=-1,this.onBOL=void 0,this.onBUOL=void 0,this.name_=e}get isBeingObserved(){return Xe(this.flags_,1)}set isBeingObserved(e){this.flags_=Qe(this.flags_,1,e)}get isPendingUnobservation(){return Xe(this.flags_,2)}set isPendingUnobservation(e){this.flags_=Qe(this.flags_,2,e)}get diffValue(){return Xe(this.flags_,4)?1:0}set diffValue(e){this.flags_=Qe(this.flags_,4,e===1?!0:!1)}onBO(){if(this.onBOL)this.onBOL.forEach((e)=>e())}onBUO(){if(this.onBUOL)this.onBUOL.forEach((e)=>e())}reportObserved(){return ng(this)}reportChanged(){st(),ag(this),ut()}toString(){return this.name_}}var Qc=ca("Atom",di);function Uv(e,t=si,n=si){let a=new di(e);if(t!==si)a.onBOL=new Set([t]);if(n!==si)a.onBUOL=new Set([n]);return a}var Zc=Object.is;function sa(e,t,n){if(vg(e))return e;if(Array.isArray(e))return we.array(e,{name:n});if(Pt(e))return we.object(e,void 0,{name:n});if(Tl(e))return we.map(e,{name:n});if(Rn(e))return we.set(e,{name:n});if(typeof e==="function"&&!fi(e)&&!Ol(e))if(Rv(e))return Ar(e);else return Wc(n,e);return e}function P_(e,t,n){if(e===void 0||e===null)return e;if(Al(e)||bg(e)||mi(e)||Ft(e))return e;if(Array.isArray(e))return we.array(e,{name:n,deep:!1});if(Pt(e))return we.object(e,void 0,{name:n,deep:!1});if(Tl(e))return we.map(e,{name:n,deep:!1});if(Rn(e))return we.set(e,{name:n,deep:!1})}function xr(e){return e}function Er(e,t){return{annotationType_:e,options_:t,make_:eS,extend_:tS}}function eS(e,t,n,a){var i;if((i=this.options_)!=null&&i.bound)return this.extend_(e,t,n,!1)===null?0:1;if(a===e.target_)return this.extend_(e,t,n,!1)===null?0:2;if(fi(n.value))return 1;let l=Vv(e,this,t,n,!1);return Wt(a,t,l),2}function tS(e,t,n,a){let i=Vv(e,this,t,n);return e.defineProperty_(t,i,a)}function kv(e,t,n){let{kind:a,name:i,addInitializer:l}=n,o=e,r=(c)=>{var m,b,h,g;return ua((m=(b=o.options_)==null?void 0:b.name)!=null?m:i.toString(),c,(h=(g=o.options_)==null?void 0:g.autoAction)!=null?h:!1)};if(a=="field")return function(c){var m;let b=c;if(!fi(b))b=r(b);if((m=o.options_)!=null&&m.bound)b=b.bind(this),b.isMobxAction=!0;return b};if(a=="method"){var s;if(!fi(t))t=r(t);if((s=o.options_)!=null&&s.bound)l(function(){let c=this,m=c[i].bind(c);m.isMobxAction=!0,c[i]=m});return t}I(43,o.annotationType_,String(i),a)}function nS(e,{annotationType_:t},n,{value:a}){}function Vv(e,t,n,a,i=N.safeDescriptors){var l,o,r,s,c,m,b;nS(e,t,n,a);let{value:h}=a;if((l=t.options_)!=null&&l.bound){var g;h=h.bind((g=e.proxy_)!=null?g:e.target_)}return{value:ua((o=(r=t.options_)==null?void 0:r.name)!=null?o:n.toString(),h,(s=(c=t.options_)==null?void 0:c.autoAction)!=null?s:!1,(m=t.options_)!=null&&m.bound?(b=e.proxy_)!=null?b:e.target_:void 0),configurable:i?e.isPlainObject_:!0,enumerable:!1,writable:i?!1:!0}}function Lv(e,t){return{annotationType_:e,options_:t,make_:aS,extend_:iS}}function aS(e,t,n,a){var i;if(a===e.target_)return this.extend_(e,t,n,!1)===null?0:2;if((i=this.options_)!=null&&i.bound&&(!ra(e.target_,t)||!Ol(e.target_[t]))){if(this.extend_(e,t,n,!1)===null)return 0}if(Ol(n.value))return 1;let l=Hv(e,this,t,n,!1,!1);return Wt(a,t,l),2}function iS(e,t,n,a){var i;let l=Hv(e,this,t,n,(i=this.options_)==null?void 0:i.bound);return e.defineProperty_(t,l,a)}function Bv(e,t,n){var a;let{name:i,addInitializer:l}=n;if(!Ol(t))t=Ar(t);if((a=e.options_)!=null&&a.bound)l(function(){let o=this,r=o[i].bind(o);r.isMobXFlow=!0,o[i]=r});return t}function lS(e,{annotationType_:t},n,{value:a}){}function Hv(e,t,n,a,i,l=N.safeDescriptors){lS(e,t,n,a);let{value:o}=a;if(!Ol(o))o=Ar(o);if(i){var r;o=o.bind((r=e.proxy_)!=null?r:e.target_),o.isMobXFlow=!0}return{value:o,configurable:l?e.isPlainObject_:!0,enumerable:!1,writable:l?!1:!0}}function jv(e,t){return{annotationType_:e,options_:t,make_:oS,extend_:rS}}function oS(e,t,n){return this.extend_(e,t,n,!1)===null?0:1}function rS(e,t,n,a){return sS(e,this,t,n),e.defineComputedProperty_(t,Tt({},this.options_,{get:n.get,set:n.set}),a)}function qv(e,t,n){let a=e,{name:i,addInitializer:l}=n,o;function r(s,c){let m=Tt({},a.options_,{get:t,context:s});return m.name||(m.name=`ObservableObject.${i.toString()}`),new It(m)}return l(function(){var s;let c=Rl(this)[V],m=this,b=c.values_.get(i);if(b instanceof It&&b.derivation!==t)c.values_.delete(i);((s=c.lazyComputedKeys_)!=null?s:c.lazyComputedKeys_=new Map).set(i,()=>r(m,c))}),function(){let s=this[V],c=s.values_.get(i);if(c instanceof It&&c.derivation!==t){var m;let h=(m=o)==null?void 0:m.get(this);if(!h){var b;h=r(this,s),((b=o)!=null?b:o=new WeakMap).set(this,h)}return h.get()}return s.getObservablePropValue_(i)}}function sS(e,{annotationType_:t},n,{get:a}){}function $c(e,t){return{annotationType_:e,options_:t,make_:uS,extend_:cS}}function uS(e,t,n){return this.extend_(e,t,n,!1)===null?0:1}function cS(e,t,n,a){var i,l;return fS(e,this,t,n),e.defineObservableProperty_(t,n.value,(i=(l=this.options_)==null?void 0:l.enhancer_)!=null?i:sa,a)}function Gv(e,t,n){let a=e,{kind:i,name:l}=n;if(i!=="accessor")return;function o(r,s){var c;let m=Rl(r)[V];return((c=m.lazyObservableKeys_)!=null?c:m.lazyObservableKeys_=new Map).set(l,()=>{var b,h;return new Cn(s,(b=(h=a.options_)==null?void 0:h.enhancer_)!=null?b:sa,`ObservableObject.${l.toString()}`,!1)}),m}return{get(){var r;return((r=this[V])!=null?r:o(this,t.get.call(this))).getObservablePropValue_(l)},set(r){var s;return((s=this[V])!=null?s:o(this,r)).setObservablePropValue_(l,r)},init(r){return o(this,r),r}}}function fS(e,{annotationType_:t},n,a){}var dS="true",hS=Yv();function Yv(e){return{annotationType_:dS,options_:e,make_:pS,extend_:mS}}function pS(e,t,n,a){var i,l;if(n.get)return Jc.make_(e,t,n,a);if(n.set){let m=fi(n.set)?n.set:ua(t.toString(),n.set);if(a===e.target_)return e.defineProperty_(t,{configurable:N.safeDescriptors?e.isPlainObject_:!0,set:m})===null?0:2;return Wt(a,t,{configurable:!0,set:m}),2}if(a!==e.target_&&typeof n.value==="function"){var o;if(Rv(n.value)){var r;return((r=this.options_)!=null&&r.autoBind?IS:Ar).make_(e,t,n,a)}return((o=this.options_)!=null&&o.autoBind?XS:Wc).make_(e,t,n,a)}let s=((i=this.options_)==null?void 0:i.deep)===!1?hi:we;if(typeof n.value==="function"&&(l=this.options_)!=null&&l.autoBind){var c;n.value=n.value.bind((c=e.proxy_)!=null?c:e.target_)}return s.make_(e,t,n,a)}function mS(e,t,n,a){var i,l;if(n.get)return Jc.extend_(e,t,n,a);if(n.set)return e.defineProperty_(t,{configurable:N.safeDescriptors?e.isPlainObject_:!0,set:ua(t.toString(),n.set)},a);if(typeof n.value==="function"&&(i=this.options_)!=null&&i.autoBind){var o;n.value=n.value.bind((o=e.proxy_)!=null?o:e.target_)}return(((l=this.options_)==null?void 0:l.deep)===!1?hi:we).extend_(e,t,n,a)}function wr(e,t){return Tt(function(a,i){if(i&&typeof i.kind==="string")return t(e,a,i);return},e)}var vS="observable",gS="observable.ref",bS="observable.shallow";var Kv={deep:!0,name:void 0,defaultDecorator:void 0};Object.freeze(Kv);function dr(e){return e||Kv}var Xv=$c(vS),yS=$c(gS,{enhancer_:xr}),_S=$c(bS,{enhancer_:P_});function Qv(e){return wr(e,Gv)}function hr(e){return e.deep===!0?sa:e.deep===!1?xr:xS(e.defaultDecorator)}function SS(e){var t;return e?(t=e.defaultDecorator)!=null?t:Yv(e):void 0}function xS(e){var t,n;return!e?sa:(t=(n=e.options_)==null?void 0:n.enhancer_)!=null?t:sa}function ES(e,t,n){if(t&&typeof t.kind==="string")return Gv(Xv,e,t);if(vg(e))return e;if(Pt(e))return we.object(e,t,n);if(Array.isArray(e))return we.array(e,t);if(Tl(e))return we.map(e,t);if(Rn(e))return we.set(e,t);if(typeof e==="object"&&e!==null)return e;return we.box(e,t)}var wS={box(e,t){let n=dr(t);return new Cn(e,hr(n),n.name,!0,n.equals)},array(e,t){let n=dr(t);return lx(e,hr(n),n.name)},map(e,t){let n=dr(t);return new Pc(e,hr(n),n.name)},set(e,t){let n=dr(t);return new ef(e,hr(n),n.name)},object(e,t,n){return vi(()=>dg(tx({},n),e,t))}},hi=Qv(yS),Dl=Qv(_S);var we=Tt(ES,Xv,wS),Zv="computed";function NS(e){return wr(e,qv)}var $v=jv(Zv);var Jc=function(t,n){if(n&&typeof n.kind==="string")return qv($v,t,n);if(Pt(t))return NS(jv(Zv,t));let a=Pt(n)?n:{};return a.get=t,a.name||(a.name=t.name||""),new It(a)};Tt(Jc,$v);var gv,bv,vr=0,OS=1,AS=(gv=(bv=Xc(()=>{},"name"))==null?void 0:bv.configurable)!=null?gv:!1,yv={value:"action",configurable:!0,writable:!1,enumerable:!1};function ua(e,t,n=!1,a){function i(){return Jv(e,n,t,a||this,arguments)}if(i.isMobxAction=!0,i.toString=()=>t.toString(),AS)yv.value=e,Wt(i,"name",yv);return i}function Jv(e,t,n,a,i){let l=TS(e,t,a,i);try{return n.apply(a,i)}catch(o){throw l.error_=o,o}finally{DS(l)}}function TS(e,t,n,a){let l=0,o=N.trackingDerivation,r=!t||!o;st();let s=N.allowStateChanges;if(r)pi();let c=N.allowStateReads,m={runAsAction_:r,prevDerivation_:o,prevAllowStateChanges_:s,prevAllowStateReads_:c,notifySpy_:!1,startTime_:l,actionId_:OS++,parentActionId_:vr};return vr=m.actionId_,m}function DS(e){if(vr!==e.actionId_)I(30);if(vr=e.parentActionId_,e.error_!==void 0)N.suppressReactionErrors=!0;if(ut(),e.runAsAction_)Un(e.prevDerivation_);N.suppressReactionErrors=!1}function zS(e,t){let n=RS(e);try{return t()}finally{MS(n)}}function RS(e){let t=N.allowStateChanges;return N.allowStateChanges=e,t}function MS(e){N.allowStateChanges=e}class Cn extends di{constructor(e,t,n="ObservableValue",a=!0,i=Zc){super(n);if(this.enhancer_=void 0,this.name_=void 0,this.equals_=void 0,this.hasUnreportedChange_=!1,this.interceptors_=void 0,this.changeListeners_=void 0,this.value_=void 0,this.dehancer=void 0,this.enhancer_=t,this.name_=n,this.equals_=i,this.value_=t(e,void 0,n),!1)var l}dehanceValue(e){if(this.dehancer!==void 0)return this.dehancer(e);return e}set(e){let t=this.value_;if(e=this.prepareNewValue_(e),e!==N.UNCHANGED)this.setNewValue_(e)}prepareNewValue_(e){if(At(this),ot(this)){let t=rt(this,{object:this,type:kn,newValue:e});if(!t)return N.UNCHANGED;e=t.newValue}return e=this.enhancer_(e,this.value_,this.name_),this.equals_(this.value_,e)?N.UNCHANGED:e}setNewValue_(e){let t=this.value_;if(this.value_=e,this.reportChanged(),mt(this))vt(this,{type:kn,object:this,newValue:e,oldValue:t})}get(){return this.reportObserved(),this.dehanceValue(this.value_)}raw(){return this.value_}toJSON(){return this.get()}toString(){return`${this.name_}[${this.value_}]`}valueOf(){return Cv(this.get())}[Symbol.toPrimitive](){return this.valueOf()}}class It{constructor(e){if(this.dependenciesState_=-1,this.observing_=[],this.newObserving_=null,this.observers_=new Set,this.runId_=0,this.lastAccessedBy_=0,this.lowestObserverState_=0,this.unboundDepsCount_=0,this.value_=new Nl(null),this.name_=void 0,this.triggeredBy_=void 0,this.flags_=0,this.derivation=void 0,this.setter_=void 0,this.scope_=void 0,this.equals_=void 0,this.requiresReaction_=void 0,this.keepAlive_=void 0,this.onBOL=void 0,this.onBUOL=void 0,!e.get)I(31);if(this.derivation=e.get,this.name_=e.name||"ComputedValue",e.set)this.setter_=ua("ComputedValue-setter",e.set);this.equals_=e.equals||Zc,this.scope_=e.context,this.requiresReaction_=e.requiresReaction,this.keepAlive_=!!e.keepAlive}onBecomeStale_(){HS(this)}onBO(){if(this.onBOL)this.onBOL.forEach((e)=>e())}onBUO(){if(this.onBUOL)this.onBUOL.forEach((e)=>e())}get isComputing(){return Xe(this.flags_,1)}set isComputing(e){this.flags_=Qe(this.flags_,1,e)}get isRunningSetter(){return Xe(this.flags_,2)}set isRunningSetter(e){this.flags_=Qe(this.flags_,2,e)}get isBeingObserved(){return Xe(this.flags_,4)}set isBeingObserved(e){this.flags_=Qe(this.flags_,4,e)}get isPendingUnobservation(){return Xe(this.flags_,8)}set isPendingUnobservation(e){this.flags_=Qe(this.flags_,8,e)}get diffValue(){return Xe(this.flags_,16)?1:0}set diffValue(e){this.flags_=Qe(this.flags_,16,e===1?!0:!1)}get(){if(this.isComputing)I(32,this.name_,this.derivation);if(N.inBatch===0&&this.observers_.size===0&&!this.keepAlive_){if(qc(this))this.warnAboutUntrackedRead_(),st(),this.value_=this.computeValue_(!1),ut()}else if(ng(this),qc(this)){let t=N.trackingContext;if(this.keepAlive_&&!t)N.trackingContext=this;if(this.trackAndCompute())BS(this);N.trackingContext=t}let e=this.value_;if(pr(e))throw e.cause;return e}set(e){if(this.setter_){if(this.isRunningSetter)I(33,this.name_);this.isRunningSetter=!0;try{this.setter_.call(this.scope_,e)}finally{this.isRunningSetter=!1}}else I(34,this.name_)}trackAndCompute(){let e=this.value_,t=this.dependenciesState_===-1,n=this.computeValue_(!0),a=t||pr(e)||pr(n)||!this.equals_(e,n);if(a)this.value_=n;return a}computeValue_(e){this.isComputing=!0;let t=!1,n;if(e)n=Fv(this,this.derivation,this.scope_);else if(N.disableErrorBoundaries===!0)n=this.derivation.call(this.scope_);else try{n=this.derivation.call(this.scope_)}catch(a){n=new Nl(a)}return this.isComputing=!1,n}suspend_(){if(!this.keepAlive_)Gc(this),this.value_=void 0}warnAboutUntrackedRead_(){return}toString(){return`${this.name_}[${this.derivation.toString()}]`}valueOf(){return Cv(this.get())}[Symbol.toPrimitive](){return this.valueOf()}}var Nr=ca("ComputedValue",It);class Nl{constructor(e){this.cause=void 0,this.cause=e}}function pr(e){return e instanceof Nl}function qc(e){switch(e.dependenciesState_){case 0:return!1;case-1:case 2:return!0;case 1:{let n=pi(),a=e.observing_,i=a.length;for(let l=0;l<i;l++){let o=a[l];if(Nr(o)){if(N.disableErrorBoundaries)o.get();else try{o.get()}catch(r){return Un(n),!0}if(e.dependenciesState_===2)return Un(n),!0}}return Iv(e),Un(n),!1}}}function At(e){return}function CS(e){}function Fv(e,t,n){Iv(e),e.newObserving_=Array(e.runId_===0?100:e.observing_.length),e.unboundDepsCount_=0,e.runId_=++N.runId;let i=N.trackingDerivation;N.trackingDerivation=e,N.inBatch++;let l;if(N.disableErrorBoundaries===!0)l=t.call(n);else try{l=t.call(n)}catch(o){l=new Nl(o)}return N.inBatch--,N.trackingDerivation=i,kS(e),US(e),l}function US(e){return}function kS(e){let t=e.observing_,n=e.observing_=e.newObserving_,a=0,i=0,l=e.unboundDepsCount_;for(let o=0;o<l;o++){let r=n[o];if(r.diffValue===0){if(r.diffValue=1,i!==o)n[i]=r;i++}if(r.dependenciesState_>a)a=r.dependenciesState_}n.length=i,e.newObserving_=null,l=t.length;while(l--){let o=t[l];if(o.diffValue===0)eg(o,e);o.diffValue=0}while(i--){let o=n[i];if(o.diffValue===1)o.diffValue=0,LS(o,e)}if(a!==0)e.dependenciesState_=a,e.onBecomeStale_()}function Gc(e){let t=e.observing_;e.observing_=[];let n=t.length;while(n--)eg(t[n],e);e.dependenciesState_=-1}function Wv(e){let t=pi();try{return e()}finally{Un(t)}}function pi(){let e=N.trackingDerivation;return N.trackingDerivation=null,e}function Un(e){N.trackingDerivation=e}function Iv(e){if(e.dependenciesState_===0)return;e.dependenciesState_=0;let t=e.observing_,n=t.length;while(n--)t[n].lowestObserverState_=0}var Pv=7;class Yc{constructor(){this.version=Pv,this.UNCHANGED={},this.trackingDerivation=null,this.trackingContext=null,this.runId=0,this.mobxGuid=0,this.inBatch=0,this.pendingUnobservations=[],this.pendingReactions=[],this.isRunningReactions=!1,this.allowStateChanges=!1,this.allowStateReads=!0,this.enforceActions=!0,this.spyListeners=[],this.globalReactionErrorHandlers=[],this.computedRequiresReaction=!1,this.reactionRequiresObservable=!1,this.observableRequiresReaction=!1,this.disableErrorBoundaries=!1,this.suppressReactionErrors=!1,this.safeDescriptors=!0}}var Lc=!0,VS=!1,N=function(){let e=globalThis;if(e.__mobxInstanceCount>0&&!e.__mobxGlobals)Lc=!1;if(e.__mobxGlobals&&e.__mobxGlobals.version!==Pv)Lc=!1;if(!Lc)return setTimeout(()=>{if(!VS)I(35)},1),new Yc;else if(e.__mobxGlobals){if(e.__mobxInstanceCount+=1,!e.__mobxGlobals.UNCHANGED)e.__mobxGlobals.UNCHANGED={};return e.__mobxGlobals}else return e.__mobxInstanceCount=1,e.__mobxGlobals=new Yc}();function Fc(){return N}function LS(e,t){if(e.observers_.add(t),e.lowestObserverState_>t.dependenciesState_)e.lowestObserverState_=t.dependenciesState_}function eg(e,t){if(e.observers_.delete(t),e.observers_.size===0)tg(e)}function tg(e){if(e.isPendingUnobservation===!1)e.isPendingUnobservation=!0,N.pendingUnobservations.push(e)}function st(){N.inBatch++}function ut(){if(--N.inBatch===0){ig();let e=N.pendingUnobservations;for(let t=0;t<e.length;t++){let n=e[t];if(n.isPendingUnobservation=!1,n.observers_.size===0){if(n.isBeingObserved)n.isBeingObserved=!1,n.onBUO();if(n instanceof It)n.suspend_()}}N.pendingUnobservations=[]}}function ng(e){CS(e);let t=N.trackingDerivation;if(t!==null){if(t.runId_!==e.lastAccessedBy_){if(e.lastAccessedBy_=t.runId_,t.newObserving_[t.unboundDepsCount_++]=e,!e.isBeingObserved&&N.trackingContext)e.isBeingObserved=!0,e.onBO()}return e.isBeingObserved}else if(e.observers_.size===0&&N.inBatch>0)tg(e);return!1}function ag(e){if(e.lowestObserverState_===2)return;e.lowestObserverState_=2,e.observers_.forEach((t)=>{if(t.dependenciesState_===0)t.onBecomeStale_();t.dependenciesState_=2})}function BS(e){if(e.lowestObserverState_===2)return;e.lowestObserverState_=2,e.observers_.forEach((t)=>{if(t.dependenciesState_===1)t.dependenciesState_=2;else if(t.dependenciesState_===0)e.lowestObserverState_=0})}function HS(e){if(e.lowestObserverState_!==0)return;e.lowestObserverState_=1,e.observers_.forEach((t)=>{if(t.dependenciesState_===0)t.dependenciesState_=1,t.onBecomeStale_()})}class zl{constructor(e="Reaction",t,n,a){this.name_=void 0,this.onInvalidate_=void 0,this.errorHandler_=void 0,this.requiresObservable_=void 0,this.observing_=[],this.newObserving_=[],this.dependenciesState_=-1,this.runId_=0,this.unboundDepsCount_=0,this.flags_=0,this.name_=e,this.onInvalidate_=t,this.errorHandler_=n,this.requiresObservable_=a}get isDisposed(){return Xe(this.flags_,1)}set isDisposed(e){this.flags_=Qe(this.flags_,1,e)}get isScheduled(){return Xe(this.flags_,2)}set isScheduled(e){this.flags_=Qe(this.flags_,2,e)}get isTrackPending(){return Xe(this.flags_,4)}set isTrackPending(e){this.flags_=Qe(this.flags_,4,e)}get isRunning(){return Xe(this.flags_,8)}set isRunning(e){this.flags_=Qe(this.flags_,8,e)}get diffValue(){return Xe(this.flags_,16)?1:0}set diffValue(e){this.flags_=Qe(this.flags_,16,e===1?!0:!1)}onBecomeStale_(){this.schedule_()}schedule_(){if(!this.isScheduled)this.isScheduled=!0,N.pendingReactions.push(this),ig()}runReaction_(){if(!this.isDisposed){st(),this.isScheduled=!1;let e=N.trackingContext;if(N.trackingContext=this,qc(this)){this.isTrackPending=!0;try{this.onInvalidate_()}catch(t){this.reportExceptionInDerivation_(t)}}N.trackingContext=e,ut()}}track(e){if(this.isDisposed)return;st();let t=!1,n;this.isRunning=!0;let a=N.trackingContext;N.trackingContext=this;let i=Fv(this,e,void 0);if(N.trackingContext=a,this.isRunning=!1,this.isTrackPending=!1,this.isDisposed)Gc(this);if(pr(i))this.reportExceptionInDerivation_(i.cause);ut()}reportExceptionInDerivation_(e){if(this.errorHandler_){this.errorHandler_(e,this);return}if(N.disableErrorBoundaries)throw e;let t=`[mobx] uncaught error in '${this}'`;if(!N.suppressReactionErrors)console.error(t,e);N.globalReactionErrorHandlers.forEach((n)=>n(e,this))}dispose(){if(!this.isDisposed){if(this.isDisposed=!0,!this.isRunning)st(),Gc(this),ut()}}getDisposer_(e){let t=()=>{this.dispose(),e==null||e.removeEventListener==null||e.removeEventListener("abort",t)};if(e==null||e.addEventListener==null||e.addEventListener("abort",t),t[V]=this,"dispose"in Symbol&&typeof Symbol.dispose==="symbol")t[Symbol.dispose]=t;return t}toString(){return`Reaction[${this.name_}]`}}var jS=100,qS=(e)=>e();function ig(){if(N.inBatch>0||N.isRunningReactions)return;qS(GS)}function GS(){N.isRunningReactions=!0;let e=N.pendingReactions,t=0;while(e.length>0){if(++t===jS)console.error(`[mobx] cycle in reaction: ${e[0]}`),e.splice(0);let n=e.splice(0);for(let a=0,i=n.length;a<i;a++)n[a].runReaction_()}N.isRunningReactions=!1}var gr=ca("Reaction",zl);var lg="action";var og="autoAction",YS="autoAction.bound",rg="<unnamed action>",sg=Er(lg);var ug=Er(og,{autoAction:!0}),KS=Er(YS,{autoAction:!0,bound:!0});function cg(e){return wr(e,kv)}function fg(e){return function(a,i){if(i&&typeof i.kind==="string")return kv(e?ug:sg,a,i);if(ci(a))return ua(a.name||rg,a,e);if(ci(i))return ua(a,i,e);if(jc(a))return cg(Er(e?og:lg,{name:a,autoAction:e}))}}var ui=fg(!1);Tt(ui,sg);var Wc=fg(!0);Tt(Wc,ug);var XS=cg(KS);function E(e){return Jv(e.name||rg,!1,e,this,void 0)}function fi(e){return ci(e)&&e.isMobxAction===!0}var QS=(e)=>e();function ZS(e){return e.scheduler?e.scheduler:e.delay?(t)=>setTimeout(t,e.delay):QS}function Or(e,t,n=zv){var a,i;let l=(a=n.name)!=null?a:"Reaction",o=ui(l,n.onError?$S(n.onError,t):t),r=!n.scheduler&&!n.delay,s=ZS(n),c=!0,m=!1,b,h=n.equals||Zc,g=new zl(l,()=>{if(c||r)x();else if(!m)m=!0,s(x)},n.onError,n.requiresObservable);function x(){if(m=!1,g.isDisposed)return;let A=!1,M=b;if(g.track(()=>{let d=zS(!1,()=>e(g));A=c||!h(b,d),b=d}),c&&n.fireImmediately)o(b,M,g);else if(!c&&A)o(b,M,g);c=!1}if(!(n!=null&&(i=n.signal)!=null&&i.aborted))g.schedule_();return g.getDisposer_(n==null?void 0:n.signal)}function $S(e,t){return function(){try{return t.apply(this,arguments)}catch(n){e.call(this,n)}}}function dg(e,t,n,a){let i=I_(t);return vi(()=>{let l=Rl(e,a)[V];mr(i).forEach((o)=>{l.extend_(o,i[o],!n?!0:(o in n)?n[o]:!0)})}),e}function hg(e,t){return pg(yr(e,t))}function pg(e){let t={name:e.name_};if(e.observing_&&e.observing_.length>0)t.dependencies=JS(e.observing_).map(pg);return t}function JS(e){return Array.from(new Set(e))}class mg extends Error{constructor(){super("FLOW_CANCELLED");Object.setPrototypeOf(this,new.target.prototype),this.name="FlowCancellationError"}toString(){return`Error: ${this.message}`}}function FS(e){return wr(e,Bv)}var _v=Lv("flow"),WS=Lv("flow.bound",{bound:!0}),Ar=Tt(function(t,n){if(n&&typeof n.kind==="string")return Bv(_v,t,n);let a=t,i=a.name||"flow",l=function(){let r=this,s=arguments,c=0,m=ui(i,a).apply(r,s),b,h=void 0,g=new Promise(function(A,M){let d=0;b=M;function f(w){h=void 0;let U;try{U=ui(i,m.next).call(m,w)}catch(O){return M(O)}y(U)}function v(w){h=void 0;let U;try{U=ui(i,m.throw).call(m,w)}catch(O){return M(O)}y(U)}function y(w){if(ci(w==null?void 0:w.then)){w.then(y,M);return}if(w.done)return A(w.value);return h=Promise.resolve(w.value),h.then(f,v)}f(void 0)}),x=i;return g.cancel=ui(x,function(){try{if(h)Sv(h);let A=m.return(void 0),M=Promise.resolve(A.value);M.then(si,si),Sv(M),b(new mg)}catch(A){b(A)}}),g};return l.isMobXFlow=!0,l},_v),IS=FS(WS);function Sv(e){if(ci(e.cancel))e.cancel()}function Ol(e){return(e==null?void 0:e.isMobXFlow)===!0}function PS(e,t){if(!e)return!1;if(t!==void 0){if(Al(e)){var n,a;let i=e[V];return i.values_.has(t)||!!((n=i.lazyComputedKeys_)!=null&&n.has(t))||!!((a=i.lazyObservableKeys_)!=null&&a.has(t))}return!1}return Al(e)||!!e[V]||Qc(e)||gr(e)||Nr(e)}function vg(e){return PS(e)}function Jt(e,t=void 0){st();try{return e.apply(t)}finally{ut()}}function ri(e){return e[V]}var ex={has(e,t){return ri(e).has_(t)},get(e,t){return ri(e).get_(t)},set(e,t,n){var a;if(!jc(t))return!1;return(a=ri(e).set_(t,n,!0))!=null?a:!0},deleteProperty(e,t){var n;if(!jc(t))return!1;return(n=ri(e).delete_(t,!0))!=null?n:!0},defineProperty(e,t,n){var a;return(a=ri(e).defineProperty_(t,n))!=null?a:!0},ownKeys(e){return ri(e).ownKeys_()},preventExtensions(e){I(13)}};function tx(e,t){var n,a;return e=Rl(e,t),(a=(n=e[V]).proxy_)!=null?a:n.proxy_=new Proxy(e,ex)}function ot(e){return e.interceptors_!==void 0&&e.interceptors_.length>0}function rt(e,t){let n=pi();try{let a=[...e.interceptors_||[]];for(let i=0,l=a.length;i<l;i++){if(t=a[i](t),t&&!t.type)I(14);if(!t)break}return t}finally{Un(n)}}function mt(e){return e.changeListeners_!==void 0&&e.changeListeners_.length>0}function vt(e,t){let n=pi(),a=e.changeListeners_;if(!a)return;a=a.slice();for(let i=0,l=a.length;i<l;i++)a[i](t);Un(n)}var Bc=Symbol("mobx-keys");function en(e,t,n){if(Pt(e))return dg(e,e,t,n);return vi(()=>{let a=Rl(e,n)[V];if(!e[Bc]){let i=Object.getPrototypeOf(e),l=new Set([...mr(e),...mr(i)]);l.delete("constructor"),l.delete(V),Mv(i,Bc,l)}e[Bc].forEach((i)=>nx(a,i,!t?!0:(i in t)?t[i]:!0))}),e}function nx(e,t,n){if(n===!0)n=e.defaultAnnotation_;if(n===!1)return;if(_g(e,n,t),!(t in e.target_))I(1,n.annotationType_,`${e.name_}.${t.toString()}`);let a=e.target_;while(a&&a!==_r){let i=Xc(a,t);if(i){let l=n.make_(e,t,i,a);if(l===0)return;if(l===1)break}a=Object.getPrototypeOf(a)}yg(e,n,t)}var xv="splice",kn="update",ax=1e4,ix={get(e,t){let n=e[V];if(t===V)return n;if(t==="length")return n.getArrayLength_();if(typeof t==="string"&&!isNaN(t))return n.get_(parseInt(t));if(ra(Kc,t))return Kc[t];return e[t]},set(e,t,n){let a=e[V];if(t==="length")a.setArrayLength_(n);if(typeof t==="symbol"||isNaN(t))e[t]=n;else a.set_(parseInt(t),n);return!0},preventExtensions(){I(15)}};class Ic{constructor(e="ObservableArray",t,n){this.owned_=void 0,this.atom_=void 0,this.values_=[],this.interceptors_=void 0,this.changeListeners_=void 0,this.enhancer_=void 0,this.dehancer=void 0,this.proxy_=void 0,this.lastKnownLength_=0,this.owned_=n,this.atom_=new di(e),this.enhancer_=(a,i)=>t(a,i,"ObservableArray[..]")}dehanceValue_(e){if(this.dehancer!==void 0)return this.dehancer(e);return e}dehanceValues_(e){if(this.dehancer!==void 0&&e.length>0)return e.map(this.dehancer);return e}getArrayLength_(){return this.atom_.reportObserved(),this.values_.length}setArrayLength_(e){if(typeof e!=="number"||isNaN(e)||e<0)I(40,e);let t=this.values_.length;if(e===t)return;else if(e>t){let n=Array.from({length:e-t});this.spliceWithArray_(t,0,n)}else this.spliceWithArray_(e,t-e)}updateArrayLength_(e,t){if(e!==this.lastKnownLength_)I(16);this.lastKnownLength_+=t}spliceWithArray_(e,t,n){At(this.atom_);let a=this.values_.length;if(e===void 0)e=0;else if(e>a)e=a;else if(e<0)e=Math.max(0,a+e);if(arguments.length===1)t=a-e;else if(t===void 0||t===null)t=0;else t=Math.max(0,Math.min(t,a-e));if(n===void 0)n=Hc;if(ot(this)){let l=rt(this,{object:this.proxy_,type:xv,index:e,removedCount:t,added:n});if(!l)return Hc;t=l.removedCount,n=l.added}n=n.length===0?n:n.map((l)=>this.enhancer_(l,void 0));let i=this.spliceItemsIntoValues_(e,t,n);if(t!==0||n.length!==0)this.notifyArraySplice_(e,n,i);return this.dehanceValues_(i)}spliceItemsIntoValues_(e,t,n){if(n.length<ax)return this.values_.splice(e,t,...n);else{let a=this.values_.slice(e,e+t),i=this.values_.slice(e+t);this.values_.length+=n.length-t;for(let l=0;l<n.length;l++)this.values_[e+l]=n[l];for(let l=0;l<i.length;l++)this.values_[e+n.length+l]=i[l];return a}}notifyArrayChildUpdate_(e,t,n){let i=mt(this),l=i?{observableKind:"array",object:this.proxy_,type:kn,debugObjectName:this.atom_.name_,index:e,newValue:t,oldValue:n}:null;if(this.atom_.reportChanged(),i)vt(this,l)}notifyArraySplice_(e,t,n){let i=mt(this),l=i?{observableKind:"array",object:this.proxy_,debugObjectName:this.atom_.name_,type:xv,index:e,removed:n,added:t,removedCount:n.length,addedCount:t.length}:null;if(this.atom_.reportChanged(),i)vt(this,l)}get_(e){return this.atom_.reportObserved(),this.dehanceValue_(this.values_[e])}set_(e,t){let n=this.values_;if(e<n.length){At(this.atom_);let a=n[e];if(ot(this)){let l=rt(this,{type:kn,object:this.proxy_,index:e,newValue:t});if(!l)return;t=l.newValue}if(t=this.enhancer_(t,a),t!==a)n[e]=t,this.notifyArrayChildUpdate_(e,t,a)}else{let a=Array.from({length:e+1-n.length});a[a.length-1]=t,this.spliceWithArray_(n.length,0,a)}}}function lx(e,t,n="ObservableArray",a=!1){return vi(()=>{let i=new Ic(n,t,a);J_(i.values_,V,i);let l=new Proxy(i.values_,ix);if(i.proxy_=l,e&&e.length)i.spliceWithArray_(0,0,e);return l})}var Kc={clear(){return this.splice(0)},replace(e){let t=this[V];return t.spliceWithArray_(0,t.values_.length,e)},toJSON(){return this.slice()},splice(e,t,...n){let a=this[V];switch(arguments.length){case 0:return[];case 1:return a.spliceWithArray_(e);case 2:return a.spliceWithArray_(e,t)}return a.spliceWithArray_(e,t,n)},spliceWithArray(e,t,n){return this[V].spliceWithArray_(e,t,n)},push(...e){let t=this[V];return t.spliceWithArray_(t.values_.length,0,e),t.values_.length},pop(){return this.splice(Math.max(this[V].values_.length-1,0),1)[0]},shift(){return this.splice(0,1)[0]},unshift(...e){let t=this[V];return t.spliceWithArray_(0,0,e),t.values_.length},reverse(){if(N.trackingDerivation)I(37,"reverse");return this.replace(this.slice().reverse()),this},sort(){if(N.trackingDerivation)I(37,"sort");let e=this.slice();return e.sort.apply(e,arguments),this.replace(e),this},remove(e){let t=this[V],n=t.dehanceValues_(t.values_).indexOf(e);if(n>-1)return this.splice(n,1),!0;return!1}};P("at",Ze);P("concat",Ze);P("flat",Ze);P("includes",Ze);P("indexOf",Ze);P("join",Ze);P("lastIndexOf",Ze);P("slice",Ze);P("toString",Ze);P("toLocaleString",Ze);P("toSorted",Ze);P("toSpliced",Ze);P("with",Ze);P("every",gt);P("filter",gt);P("find",gt);P("findIndex",gt);P("findLast",gt);P("findLastIndex",gt);P("flatMap",gt);P("forEach",gt);P("map",gt);P("some",gt);P("toReversed",gt);P("reduce",gg);P("reduceRight",gg);function P(e,t){if(typeof Array.prototype[e]==="function")Kc[e]=t(e)}function Ze(e){return function(){let t=this[V];t.atom_.reportObserved();let n=t.dehanceValues_(t.values_);return n[e].apply(n,arguments)}}function gt(e){return function(t,n){let a=this[V];return a.atom_.reportObserved(),a.dehanceValues_(a.values_)[e]((l,o)=>t.call(n,l,o,this))}}function gg(e){return function(){let t=this[V];t.atom_.reportObserved();let n=t.dehanceValues_(t.values_),a=arguments[0];return arguments[0]=(i,l,o)=>a(i,l,o,this),n[e].apply(n,arguments)}}var ox=ca("ObservableArrayAdministration",Ic);function bg(e){return Sr(e)&&ox(e[V])}var rx={},Mn="add",br="delete";class Pc{constructor(e,t=sa,n="ObservableMap"){this.enhancer_=void 0,this.name_=void 0,this[V]=rx,this.data_=void 0,this.hasMap_=void 0,this.keysAtom_=void 0,this.interceptors_=void 0,this.changeListeners_=void 0,this.dehancer=void 0,this.enhancer_=t,this.name_=n,vi(()=>{if(this.keysAtom_=Uv("ObservableMap.keys()"),this.data_=new Map,this.hasMap_=new Map,e)this.merge(e)})}has_(e){return this.data_.has(e)}has(e){if(!N.trackingDerivation)return this.has_(e);let t=this.hasMap_.get(e);if(!t){let n=t=new Cn(this.has_(e),xr,"ObservableMap.key?",!1);this.hasMap_.set(e,n),n.onBUOL=new Set([()=>this.hasMap_.delete(e)])}return t.get()}set(e,t){let n=this.has_(e);if(ot(this)){let a=rt(this,{type:n?kn:Mn,object:this,newValue:t,name:e});if(!a)return this;t=a.newValue}if(n)this.updateValue_(e,t);else this.addValue_(e,t);return this}delete(e){if(At(this.keysAtom_),ot(this)){if(!rt(this,{type:br,object:this,name:e}))return!1}if(this.has_(e)){let n=mt(this),a=n?{observableKind:"map",debugObjectName:this.name_,type:br,object:this,oldValue:this.data_.get(e).value_,name:e}:null;if(Jt(()=>{var i;this.keysAtom_.reportChanged(),(i=this.hasMap_.get(e))==null||i.setNewValue_(!1),this.data_.get(e).setNewValue_(void 0),this.data_.delete(e)}),n)vt(this,a);return!0}return!1}updateValue_(e,t){let n=this.data_.get(e);if(t=n.prepareNewValue_(t),t!==N.UNCHANGED){let i=mt(this),l=i?{observableKind:"map",debugObjectName:this.name_,type:kn,object:this,oldValue:n.value_,name:e,newValue:t}:null;if(n.setNewValue_(t),i)vt(this,l)}}addValue_(e,t){At(this.keysAtom_),Jt(()=>{var l;let o=new Cn(t,this.enhancer_,"ObservableMap.key",!1);this.data_.set(e,o),t=o.value_,(l=this.hasMap_.get(e))==null||l.setNewValue_(!0),this.keysAtom_.reportChanged()});let n=!1,a=mt(this),i=a||n?{observableKind:"map",debugObjectName:this.name_,type:Mn,object:this,name:e,newValue:t}:null;if(a)vt(this,i)}get(e){if(this.has(e))return this.dehanceValue_(this.data_.get(e).get());return this.dehanceValue_(void 0)}getOrInsert(e,t){if(!this.has(e))this.set(e,t);return this.get(e)}getOrInsertComputed(e,t){if(!this.has(e))this.set(e,t(e));return this.get(e)}dehanceValue_(e){if(this.dehancer!==void 0)return this.dehancer(e);return e}keys(){return this.keysAtom_.reportObserved(),this.data_.keys()}values(){let e=this,t=this.keys();return Ev({next(){let{done:n,value:a}=t.next();return{done:n,value:n?void 0:e.get(a)}}})}entries(){let e=this,t=this.keys();return Ev({next(){let{done:n,value:a}=t.next();return{done:n,value:n?void 0:[a,e.get(a)]}}})}[Symbol.iterator](){return this.entries()}forEach(e,t){for(let[n,a]of this)e.call(t,a,n,this)}merge(e){if(mi(e))e=new Map(e);return Jt(()=>{if(Pt(e))W_(e).forEach((t)=>this.set(t,e[t]));else if(Array.isArray(e))e.forEach(([t,n])=>this.set(t,n));else if(Tl(e)){if(!F_(e))I(19,e);e.forEach((t,n)=>this.set(n,t))}else if(e!==null&&e!==void 0)I(20,e)}),this}clear(){Jt(()=>{Wv(()=>{for(let e of this.keys())this.delete(e)})})}replace(e){return Jt(()=>{let t=sx(e),n=new Map,a=!1;for(let i of this.data_.keys())if(!t.has(i))if(this.delete(i))a=!0;else{let o=this.data_.get(i);n.set(i,o)}for(let[i,l]of t.entries()){let o=this.data_.has(i);if(this.set(i,l),this.data_.has(i)){let r=this.data_.get(i);if(n.set(i,r),!o)a=!0}}if(!a)if(this.data_.size!==n.size)this.keysAtom_.reportChanged();else{let i=this.data_.keys(),l=n.keys(),o=i.next(),r=l.next();while(!o.done){if(o.value!==r.value){this.keysAtom_.reportChanged();break}o=i.next(),r=l.next()}}this.data_=n}),this}get size(){return this.keysAtom_.reportObserved(),this.data_.size}toString(){return"[object ObservableMap]"}toJSON(){return Array.from(this)}get[Symbol.toStringTag](){return"Map"}}var mi=ca("ObservableMap",Pc);function Ev(e){return e[Symbol.toStringTag]="MapIterator",xg(e)}function sx(e){if(Tl(e)||mi(e))return e;else if(Array.isArray(e))return new Map(e);else if(Pt(e)){let t=new Map;for(let n in e)t.set(n,e[n]);return t}else return I(21,e)}var ux={};class ef{constructor(e,t=sa,n="ObservableSet"){this.name_=void 0,this[V]=ux,this.data_=new Set,this.atom_=void 0,this.changeListeners_=void 0,this.interceptors_=void 0,this.dehancer=void 0,this.enhancer_=void 0,this.name_=n,this.enhancer_=(a,i)=>t(a,i,n),vi(()=>{if(this.atom_=Uv(this.name_),e)this.replace(e)})}dehanceValue_(e){if(this.dehancer!==void 0)return this.dehancer(e);return e}clear(){Jt(()=>{Wv(()=>{for(let e of this.data_.values())this.delete(e)})})}forEach(e,t){for(let n of this)e.call(t,n,n,this)}get size(){return this.atom_.reportObserved(),this.data_.size}add(e){if(At(this.atom_),ot(this)){let t=rt(this,{type:Mn,object:this,newValue:e});if(!t)return this;e=t.newValue}if(!this.has(e)){Jt(()=>{this.data_.add(this.enhancer_(e,void 0)),this.atom_.reportChanged()});let t=!1,n=mt(this),a=n||t?{observableKind:"set",debugObjectName:this.name_,type:Mn,object:this,newValue:e}:null;if(n)vt(this,a)}return this}delete(e){if(ot(this)){if(!rt(this,{type:br,object:this,oldValue:e}))return!1}if(this.has(e)){let n=mt(this),a=n?{observableKind:"set",debugObjectName:this.name_,type:br,object:this,oldValue:e}:null;if(Jt(()=>{this.atom_.reportChanged(),this.data_.delete(e)}),n)vt(this,a);return!0}return!1}has(e){return this.atom_.reportObserved(),this.data_.has(this.dehanceValue_(e))}entries(){let e=this.values();return wv({next(){let{value:t,done:n}=e.next();return!n?{value:[t,t],done:n}:{value:void 0,done:n}}})}keys(){return this.values()}values(){this.atom_.reportObserved();let e=this,t=this.data_.values();return wv({next(){let{value:n,done:a}=t.next();return!a?{value:e.dehanceValue_(n),done:a}:{value:void 0,done:a}}})}intersection(e){if(Rn(e)&&!Ft(e))return e.intersection(this);else return new Set(this).intersection(e)}union(e){if(Rn(e)&&!Ft(e))return e.union(this);else return new Set(this).union(e)}difference(e){return new Set(this).difference(e)}symmetricDifference(e){if(Rn(e)&&!Ft(e))return e.symmetricDifference(this);else return new Set(this).symmetricDifference(e)}isSubsetOf(e){return new Set(this).isSubsetOf(e)}isSupersetOf(e){return new Set(this).isSupersetOf(e)}isDisjointFrom(e){if(Rn(e)&&!Ft(e))return e.isDisjointFrom(this);else return new Set(this).isDisjointFrom(e)}replace(e){if(Ft(e))e=new Set(e);return Jt(()=>{if(Array.isArray(e))this.clear(),e.forEach((t)=>this.add(t));else if(Rn(e))this.clear(),e.forEach((t)=>this.add(t));else if(e!==null&&e!==void 0)I(41,e)}),this}toJSON(){return Array.from(this)}toString(){return"[object ObservableSet]"}[Symbol.iterator](){return this.values()}get[Symbol.toStringTag](){return"Set"}}var Ft=ca("ObservableSet",ef);function wv(e){return e[Symbol.toStringTag]="SetIterator",xg(e)}var Nv=Object.create(null),Ov="remove";class tf{constructor(e,t=new Map,n,a=hS){this.target_=void 0,this.values_=void 0,this.name_=void 0,this.defaultAnnotation_=void 0,this.keysAtom_=void 0,this.changeListeners_=void 0,this.interceptors_=void 0,this.proxy_=void 0,this.isPlainObject_=void 0,this.appliedAnnotations_=void 0,this.pendingKeys_=void 0,this.lazyComputedKeys_=void 0,this.lazyObservableKeys_=void 0,this.target_=e,this.values_=t,this.name_=n,this.defaultAnnotation_=a,this.keysAtom_=new di("ObservableObject.keys"),this.isPlainObject_=Pt(this.target_)}getObservablePropValue_(e){var t,n;return((t=(n=this.values_.get(e))!=null?n:this.materializeLazyComputed_(e))!=null?t:this.materializeLazyObservable_(e)).get()}materializeLazyComputed_(e){var t;let n=(t=this.lazyComputedKeys_)==null?void 0:t.get(e);if(!n)return;if(this.lazyComputedKeys_.delete(e),this.lazyComputedKeys_.size===0)this.lazyComputedKeys_=void 0;let a=n();return this.values_.set(e,a),a}materializeLazyObservable_(e){var t;let n=(t=this.lazyObservableKeys_)==null?void 0:t.get(e);if(!n)return;if(this.lazyObservableKeys_.delete(e),this.lazyObservableKeys_.size===0)this.lazyObservableKeys_=void 0;let a=n();return this.values_.set(e,a),a}setObservablePropValue_(e,t){var n,a;let i=(n=(a=this.values_.get(e))!=null?a:this.materializeLazyComputed_(e))!=null?n:this.materializeLazyObservable_(e);if(i instanceof It)return i.set(t),!0;if(ot(this)){let l=rt(this,{type:kn,object:this.proxy_||this.target_,name:e,newValue:t});if(!l)return null;t=l.newValue}if(t=i.prepareNewValue_(t),t!==N.UNCHANGED){let l=mt(this),o=!1,r=l?{type:kn,observableKind:"object",debugObjectName:this.name_,object:this.proxy_||this.target_,oldValue:i.value_,name:e,newValue:t}:null;if(i.setNewValue_(t),l)vt(this,r)}return!0}get_(e){if(N.trackingDerivation&&!ra(this.target_,e))this.has_(e);return this.target_[e]}set_(e,t,n=!1){if(ra(this.target_,e))if(this.values_.has(e))return this.setObservablePropValue_(e,t);else if(n)return Reflect.set(this.target_,e,t);else return this.target_[e]=t,!0;else return this.extend_(e,{value:t,enumerable:!0,writable:!0,configurable:!0},this.defaultAnnotation_,n)}has_(e){if(!N.trackingDerivation)return e in this.target_;this.pendingKeys_||(this.pendingKeys_=new Map);let t=this.pendingKeys_.get(e);if(!t)t=new Cn(e in this.target_,xr,"ObservableObject.key?",!1),this.pendingKeys_.set(e,t);return t.get()}extend_(e,t,n,a=!1){if(n===!0)n=this.defaultAnnotation_;if(n===!1)return this.defineProperty_(e,t,a);_g(this,n,e);let i=n.extend_(this,e,t,a);if(i)yg(this,n,e);return i}defineProperty_(e,t,n=!1){At(this.keysAtom_);try{st();let a=this.delete_(e);if(!a)return a;if(ot(this)){let i=rt(this,{object:this.proxy_||this.target_,name:e,type:Mn,newValue:t.value});if(!i)return null;let{newValue:l}=i;if(t.value!==l)t=Tt({},t,{value:l})}if(n){if(!Reflect.defineProperty(this.target_,e,t))return!1}else Wt(this.target_,e,t);this.notifyPropertyAddition_(e,t.value)}finally{ut()}return!0}defineObservableProperty_(e,t,n,a=!1){At(this.keysAtom_);try{st();let i=this.delete_(e);if(!i)return i;if(ot(this)){let s=rt(this,{object:this.proxy_||this.target_,name:e,type:Mn,newValue:t});if(!s)return null;t=s.newValue}let l=Av(e),o={configurable:N.safeDescriptors?this.isPlainObject_:!0,enumerable:!0,get:l.get,set:l.set};if(a){if(!Reflect.defineProperty(this.target_,e,o))return!1}else Wt(this.target_,e,o);let r=new Cn(t,n,"ObservableObject.key",!1);this.values_.set(e,r),this.notifyPropertyAddition_(e,r.value_)}finally{ut()}return!0}defineComputedProperty_(e,t,n=!1){At(this.keysAtom_);try{st();let a=this.delete_(e);if(!a)return a;if(ot(this)){if(!rt(this,{object:this.proxy_||this.target_,name:e,type:Mn,newValue:void 0}))return null}t.name||(t.name="ObservableObject.key"),t.context=this.proxy_||this.target_;let i=Av(e),l={configurable:N.safeDescriptors?this.isPlainObject_:!0,enumerable:!1,get:i.get,set:i.set};if(n){if(!Reflect.defineProperty(this.target_,e,l))return!1}else Wt(this.target_,e,l);this.values_.set(e,new It(t)),this.notifyPropertyAddition_(e,void 0)}finally{ut()}return!0}delete_(e,t=!1){if(At(this.keysAtom_),!ra(this.target_,e))return!0;if(ot(this)){if(!rt(this,{object:this.proxy_||this.target_,name:e,type:Ov}))return null}try{var n;st();let i=mt(this),l=!1,o=this.values_.get(e),r=void 0;if(!o&&(i||l)){var a;r=(a=Xc(this.target_,e))==null?void 0:a.value}if(t){if(!Reflect.deleteProperty(this.target_,e))return!1}else delete this.target_[e];if(o){if(this.values_.delete(e),o instanceof Cn)r=o.value_;ag(o)}if(this.keysAtom_.reportChanged(),(n=this.pendingKeys_)==null||(n=n.get(e))==null||n.set(e in this.target_),i||l){let s={type:Ov,observableKind:"object",object:this.proxy_||this.target_,debugObjectName:this.name_,oldValue:r,name:e};if(i)vt(this,s)}}finally{ut()}return!0}notifyPropertyAddition_(e,t){var n;let a=mt(this),i=!1;if(a){let l=a?{type:Mn,observableKind:"object",debugObjectName:this.name_,object:this.proxy_||this.target_,name:e,newValue:t}:null;if(a)vt(this,l)}(n=this.pendingKeys_)==null||(n=n.get(e))==null||n.set(!0),this.keysAtom_.reportChanged()}ownKeys_(){return this.keysAtom_.reportObserved(),mr(this.target_)}keys_(){return this.keysAtom_.reportObserved(),Object.keys(this.target_)}}function Rl(e,t){var n;if(ra(e,V))return e;let a=(n=t==null?void 0:t.name)!=null?n:"ObservableObject",i=new tf(e,new Map,String(a),SS(t));return Mv(e,V,i),e}var cx=ca("ObservableObjectAdministration",tf);function Av(e){return Nv[e]||(Nv[e]={get(){return this[V].getObservablePropValue_(e)},set(t){return this[V].setObservablePropValue_(e,t)}})}function Al(e){if(Sr(e))return cx(e[V]);return!1}function yg(e,t,n){}function _g(e,t,n){}function yr(e,t){if(typeof e==="object"&&e!==null){if(bg(e)){if(t!==void 0)I(23);return e[V].atom_}if(Ft(e))return e.atom_;if(mi(e)){if(t===void 0)return e.keysAtom_;let i=e.data_.get(t)||e.hasMap_.get(t);if(!i)I(25,t,Tv(e));return i}if(Al(e)){var n,a;if(!t)return I(26);let i=e[V],l=(n=(a=i.values_.get(t))!=null?a:i.materializeLazyComputed_(t))!=null?n:i.materializeLazyObservable_(t);if(!l)I(27,t,Tv(e));return l}if(Qc(e)||Nr(e)||gr(e))return e}else if(ci(e)){if(gr(e[V]))return e[V]}I(28)}function Sg(e,t){if(!e)I(29);if(t!==void 0)return Sg(yr(e,t));if(Qc(e)||Nr(e)||gr(e))return e;if(mi(e)||Ft(e))return e;if(e[V])return e[V];I(24,e)}function Tv(e,t){let n;if(t!==void 0)n=yr(e,t);else if(fi(e))return e.name;else if(Al(e)||mi(e)||Ft(e))n=Sg(e);else n=yr(e);return n.name_}function vi(e){let t=pi(),n=!0;st();try{return e()}finally{ut(),Un(t)}}var dE=_r.toString;var Dv,fx=((Dv=globalThis.Iterator)==null?void 0:Dv.prototype)||{};function xg(e){return e[Symbol.iterator]=dx,Tt(Object.create(fx),e)}function dx(){return this}var Ne=$e(ft(),1),Eg;if(!Ne.useState||!Ne.useSyncExternalStore)throw Error("mobx-react-lite requires React 18 or later");if(!((Fc==null||(Eg=Fc())==null?void 0:Eg.version)>=7))throw Error("mobx-react-lite requires mobx at least version 7 to be available");var hx=1e4,px=1e4;class zg{constructor(e){this.finalize=void 0,this.registrations=new Map,this.sweepTimeout=void 0,this.sweep=(t=hx)=>{clearTimeout(this.sweepTimeout),this.sweepTimeout=void 0;let n=Date.now();if(this.registrations.forEach((a,i)=>{if(n-a.registeredAt>=t)this.finalize(a.value),this.registrations.delete(i)}),this.registrations.size>0)this.scheduleSweep()},this.finalizeAllImmediately=()=>{this.sweep(0)},this.finalize=e}register(e,t,n){this.registrations.set(n,{value:t,registeredAt:Date.now()}),this.scheduleSweep()}unregister(e){this.registrations.delete(e)}scheduleSweep(){if(this.sweepTimeout===void 0)this.sweepTimeout=setTimeout(this.sweep,px)}}var mx=typeof FinalizationRegistry<"u"?FinalizationRegistry:zg,nf=new mx((e)=>{var t;(t=e.reaction)==null||t.dispose(),e.reaction=null}),vx=!1;function Rg(){return vx}function wg(e){e.reaction=new zl(`observer${e.name}`,()=>{e.stateVersion=Symbol(),e.onStoreChange==null||e.onStoreChange()})}function Mg(e,t="observed"){if(Rg())return e();let n=Ne.default.useRef(null);if(!n.current){let o={reaction:null,onStoreChange:null,stateVersion:Symbol(),name:t,subscribe(r){if(nf.unregister(o),o.onStoreChange=r,!o.reaction)wg(o),o.stateVersion=Symbol();return()=>{var s;o.onStoreChange=null,(s=o.reaction)==null||s.dispose(),o.reaction=null}},getSnapshot(){return o.stateVersion}};n.current=o}let a=n.current;if(!a.reaction)wg(a),nf.register(n,a,a);Ne.default.useDebugValue(a.reaction,hg),Ne.default.useSyncExternalStore(a.subscribe,a.getSnapshot,a.getSnapshot);let i,l;if(a.reaction.track(()=>{try{i=e()}catch(o){l=o}}),l)throw l;return i}var Ng,Og,Cg=typeof Symbol==="function"&&Symbol.for,gx=(Ng=(Og=Object.getOwnPropertyDescriptor(()=>{},"name"))==null?void 0:Og.configurable)!=null?Ng:!1,Ag=Cg?Symbol.for("react.forward_ref"):typeof Ne.forwardRef==="function"&&Ne.forwardRef((e)=>null).$$typeof,Tg=Cg?Symbol.for("react.memo"):typeof Ne.memo==="function"&&Ne.memo((e)=>null).$$typeof;function L(e){if(Tg&&e.$$typeof===Tg)throw Error("[mobx-react-lite] You are trying to use `observer` on a function component wrapped in either another `observer` or `React.memo`. The observer already applies 'React.memo' for you.");if(Rg())return e;let t=!1,n=e,a=e.displayName||e.name;if(Ag&&e.$$typeof===Ag){if(t=!0,n=e.render,typeof n!=="function")throw Error("[mobx-react-lite] `render` property of ForwardRef was not a function")}let i=(l,o)=>Mg(()=>n(l,o),a);if(i.displayName=e.displayName,gx)Object.defineProperty(i,"name",{value:e.name,writable:!0,configurable:!0});if(t)i=Ne.forwardRef(i);return i=Ne.memo(i),yx(e,i),i}var bx={$$typeof:!0,render:!0,compare:!0,type:!0,displayName:!0};function yx(e,t){Object.keys(e).forEach((n)=>{if(!bx[n])Object.defineProperty(t,n,Object.getOwnPropertyDescriptor(e,n))})}function _x({children:e,render:t}){if(e&&t)console.error("MobX Observer: Do not use children and render in the same time in `Observer`");let n=e||t;if(typeof n!=="function")return null;return Mg(n)}_x.displayName="Observer";function Vn(e,t){return Ne.useState(()=>we(e(),t,{autoBind:!0}))[0]}var Dg,mE=(Dg=nf.finalizeAllImmediately)!=null?Dg:()=>{};var Zb=$e(ft(),1);var Sx=Symbol.for("react.transitional.element"),xx=Symbol.for("react.fragment");function Ug(e,t,n){var a=null;if(n!==void 0&&(a=""+n),t.key!==void 0&&(a=""+t.key),"key"in t){n={};for(var i in t)i!=="key"&&(n[i]=t[i])}else n=t;return t=n.ref,{$$typeof:Sx,type:e,key:a,ref:t!==void 0?t:null,props:n}}var he=xx,u=Ug,p=Ug;var Ex={close:u("path",{d:"M6 6l12 12M18 6L6 18"}),trash:u("path",{d:"M4 7h16M10 7V5h4v2M6 7l1 12h10l1-12M10 11v5M14 11v5"}),copy:u("path",{d:"M9 9h10v10H9zM5 15V5h10"}),external:u("path",{d:"M14 5h5v5M19 5l-8 8M18 14v5H5V6h5"}),dice:p(he,{children:[u("rect",{x:"4",y:"4",width:"16",height:"16",rx:"3"}),u("circle",{cx:"9",cy:"9",r:"1.3",fill:"currentColor",stroke:"none"}),u("circle",{cx:"15",cy:"15",r:"1.3",fill:"currentColor",stroke:"none"}),u("circle",{cx:"12",cy:"12",r:"1.3",fill:"currentColor",stroke:"none"})]}),image:p(he,{children:[u("rect",{x:"3",y:"5",width:"18",height:"14",rx:"2"}),u("circle",{cx:"8.5",cy:"10",r:"1.5"}),u("path",{d:"M4 17l5-5 4 4 3-2 4 4"})]}),tag:p(he,{children:[u("path",{d:"M4 11V4h7l9 9-7 7-9-9z"}),u("circle",{cx:"8",cy:"8",r:"1.3",fill:"currentColor",stroke:"none"})]}),sparkle:u("path",{d:"M12 3l1.9 5.1L19 10l-5.1 1.9L12 17l-1.9-5.1L5 10l5.1-1.9zM18 15l.8 2.2L21 18l-2.2.8L18 21l-.8-2.2L15 18l2.2-.8z"}),play:u("path",{d:"M7 4l13 8-13 8z",fill:"currentColor",stroke:"none"}),pause:u("path",{d:"M8 5v14M16 5v14"}),save:u("path",{d:"M5 4h11l3 3v13H5zM8 4v6h7V4M8 20v-6h8v6"}),ghost:u("path",{d:"M5 20V10a7 7 0 0114 0v10l-2.3-2-2.4 2-2.3-2-2.4 2zM9.5 10h.01M14.5 10h.01"}),"panel-off":p(he,{children:[u("rect",{x:"3",y:"4",width:"18",height:"16",rx:"2"}),u("path",{d:"M4 5l16 14"})]}),"panel-bottom":p(he,{children:[u("rect",{x:"3",y:"4",width:"18",height:"16",rx:"2"}),u("path",{d:"M3 14h18"}),u("rect",{x:"4.5",y:"15.5",width:"15",height:"3",fill:"currentColor",stroke:"none",opacity:"0.85"})]}),"panel-side":p(he,{children:[u("rect",{x:"3",y:"4",width:"18",height:"16",rx:"2"}),u("path",{d:"M14 4v16"}),u("rect",{x:"15.5",y:"5.5",width:"4",height:"13",fill:"currentColor",stroke:"none",opacity:"0.85"})]}),"panel-left":p(he,{children:[u("rect",{x:"3",y:"4",width:"18",height:"16",rx:"2"}),u("path",{d:"M10 4v16"}),u("rect",{x:"4.5",y:"5.5",width:"4",height:"13",fill:"currentColor",stroke:"none",opacity:"0.85"})]}),"panel-corner":p(he,{children:[u("rect",{x:"3",y:"4",width:"18",height:"16",rx:"2"}),u("rect",{x:"12.5",y:"12.5",width:"7",height:"6",fill:"currentColor",stroke:"none",opacity:"0.85"})]}),swap:u("path",{d:"M4 8h13l-3-3M20 16H7l3 3"}),plus:u("path",{d:"M12 5v14M5 12h14"}),"copy-plus":u("path",{d:"M9 9h10v10H9zM5 15V5h10M14 12v4M12 14h4"}),pen:u("path",{d:"M4 20h4L20 8l-4-4L4 16zM14 6l4 4"}),broom:u("path",{d:"M19 4l-7 7M9.5 8.5l6 6-5 5-6-6zM4.5 13.5L2 21l7.5-2.5"}),expand:u("path",{d:"M4 9V4h5M20 15v5h-5M15 4h5v5M9 20H4v-5"}),shrink:u("path",{d:"M9 4v5H4M15 20v-5h5M20 9h-5V4M4 15h5v5"}),power:u("path",{d:"M12 3v9M7.5 6.5a7 7 0 109 0"}),warn:u("path",{d:"M12 4l9 16H3zM12 10v4M12 17h.01"}),link:u("path",{d:"M10 14a4 4 0 015.7 0l2.6-2.6a4 4 0 10-5.7-5.7L11 7.3M14 10a4 4 0 01-5.7 0l-2.6 2.6a4 4 0 105.7 5.7L13 16.7"}),unlink:u("path",{d:"M9 15l-1.6 1.6a4 4 0 01-5.7-5.7L3.3 9.3M15 9l1.6-1.6a4 4 0 015.7 5.7L20.7 14.7M4 4l16 16"}),grip:p(he,{children:[u("circle",{cx:"9",cy:"6",r:"1.4",fill:"currentColor",stroke:"none"}),u("circle",{cx:"15",cy:"6",r:"1.4",fill:"currentColor",stroke:"none"}),u("circle",{cx:"9",cy:"12",r:"1.4",fill:"currentColor",stroke:"none"}),u("circle",{cx:"15",cy:"12",r:"1.4",fill:"currentColor",stroke:"none"}),u("circle",{cx:"9",cy:"18",r:"1.4",fill:"currentColor",stroke:"none"}),u("circle",{cx:"15",cy:"18",r:"1.4",fill:"currentColor",stroke:"none"})]}),refresh:u("path",{d:"M20 11a8 8 0 10-2 6M20 6v5h-5"}),terminal:u("path",{d:"M4 5h16v14H4zM7 9l3 3-3 3M13 15h4"}),folder:u("path",{d:"M3 7h6l2 2h10v10H3z"}),dot:u("circle",{cx:"12",cy:"12",r:"5",fill:"currentColor",stroke:"none"})};function D(e){return p("svg",{className:"icon",viewBox:"0 0 24 24",width:`${e.size??1.15}em`,height:`${e.size??1.15}em`,fill:"none",stroke:"currentColor",strokeWidth:1.8,strokeLinecap:"round",strokeLinejoin:"round","aria-hidden":e.title==null,role:e.title==null?void 0:"img",children:[e.title==null?null:u("title",{children:e.title}),Ex[e.name]]})}var fa=$e(ft(),1);async function me(e,t){let n=await fetch(e,t),a=await n.json().catch(()=>null);if(!n.ok||a==null)throw Error(a?.error??`http ${n.status} on ${e}`);return a}function af(){return me("/drafts")}function kg(e){return me(`/drafts/${encodeURIComponent(e.module)}/${encodeURIComponent(e.draft)}`)}function Vg(e){return me(`/generate/${encodeURIComponent(e.module)}/${encodeURIComponent(e.draft)}`,{method:"POST",headers:{"content-type":"application/json"},body:JSON.stringify(e.payload)})}function Ml(e,t={}){return me(`/drafts/${encodeURIComponent(e.module)}/${encodeURIComponent(e.draft)}`,{method:"PUT",headers:{"content-type":"application/json"},body:JSON.stringify(e.values),keepalive:t.keepalive===!0})}function lf(e){return me(`/drafts/${encodeURIComponent(e.module)}/${encodeURIComponent(e.draft)}`,{method:"DELETE"})}function Lg(e){return me(`/run/${encodeURIComponent(e.module)}`)}function Tr(e){return`/run/${encodeURIComponent(e.module)}/preview?t=${e.tick}`}function of(e){return me(`/lora-info/${encodeURIComponent(e.host)}/${encodeURIComponent(e.name)}`)}function Bg(e){return me(`/lora-about/${encodeURIComponent(e.host)}/${encodeURIComponent(e.name)}`)}function rf(e){return`/lora-preview/${encodeURIComponent(e.host)}/${encodeURIComponent(e.name)}`}function Hg(){return me("/settings")}function jg(e){return me("/settings",{method:"PUT",headers:{"content-type":"application/json"},body:JSON.stringify(e)})}function qg(){return me("/hosts")}function Gg(e){return me(`/hosts/${encodeURIComponent(e.host)}/ping`)}function Yg(e){return me(`/hosts/${encodeURIComponent(e.host)}/${e.action}`,{method:"POST"})}function Kg(e){return me(`/hosts/${encodeURIComponent(e.host)}/logs`)}function Xg(e){return me(`/hosts/${encodeURIComponent(e.module)}`,{method:"PUT",headers:{"content-type":"application/json"},body:JSON.stringify({host:e.host})})}function Qg(){return me("/prompt-enhancers")}function Zg(e){return me(`/prompt-enhancers/${encodeURIComponent(e.name)}`,{method:"PUT",headers:{"content-type":"application/json"},body:JSON.stringify({text:e.text})})}function $g(e){return me(`/prompt-enhancers/${encodeURIComponent(e.name)}`,{method:"DELETE"})}async function Jg(e){let t=new Uint8Array(await e.file.arrayBuffer()),n="";for(let a=0;a<t.length;a+=32768)n+=String.fromCharCode(...t.subarray(a,a+32768));return me("/upload",{method:"POST",headers:{"content-type":"application/json"},body:JSON.stringify({name:e.file.name,dataBase64:btoa(n)})})}function Fg(e){if(e.target.kind==="image")return{url:e.target.url,title:e.target.title,promptId:e.target.promptId};let t=e.target.module,n=e.results.filter((l)=>l.module===t),a=n.length>e.target.after?n[0]:void 0,i=a?.images.find((l)=>l.url!=null);if(!e.isRunning&&i?.url!=null)return{url:i.url,title:i.filename,promptId:a?.promptId??null};return{url:Tr({module:t,tick:e.previewTick}),title:"latent preview",promptId:null}}async function Wg(e){let t=await fetch(e);if(!t.ok)throw Error(`fetch failed (http ${t.status})`);let n=await t.blob(),a=n.type==="image/png"?n:await wx(n);await navigator.clipboard.write([new ClipboardItem({"image/png":a})])}async function wx(e){let t=await createImageBitmap(e),n=document.createElement("canvas");n.width=t.width,n.height=t.height;let a=n.getContext("2d");if(a==null)throw Error("canvas 2d context unavailable");return a.drawImage(t,0,0),await new Promise((i,l)=>{n.toBlob((o)=>{if(o==null)l(Error("png encode failed"));else i(o)},"image/png")})}var Ig=typeof navigator<"u"&&navigator.clipboard!=null;function Nx(){return Vn(()=>({copyNote:null,lightbox:null,zoom:1,panX:0,panY:0,setCopyNote(e,t){this.copyNote={url:e,text:t}},openLightbox(e){this.lightbox=e,this.resetZoom()},closeLightbox(){this.lightbox=null,this.resetZoom()},zoomBy(e,t){let n=Math.min(8,Math.max(1,this.zoom*e));if(n===this.zoom)return;let a=n/this.zoom;if(this.panX=t.x-(t.x-this.panX)*a,this.panY=t.y-(t.y-this.panY)*a,this.zoom=n,n===1)this.panX=0,this.panY=0},panBy(e,t){if(this.zoom===1)return;this.panX+=e,this.panY+=t},resetZoom(){this.zoom=1,this.panX=0,this.panY=0}}))}var Ox=L(function(t){let n=t.local.lightbox,a=n==null?null:Fg({target:n,isRunning:t.st.run.isRunning,previewTick:t.st.run.previewTick,results:t.st.run.results});fa.useEffect(()=>{if(n==null)return;let o=(r)=>{if(r.key==="Escape")t.local.closeLightbox()};return window.addEventListener("keydown",o),()=>window.removeEventListener("keydown",o)},[n,t.local]);let i=fa.useRef(null);if(fa.useEffect(()=>{let o=i.current;if(o==null)return;let r=(s)=>{s.preventDefault();let c=o.getBoundingClientRect();t.local.zoomBy(s.deltaY<0?1.2:0.8333333333333334,{x:s.clientX-c.left-c.width/2,y:s.clientY-c.top-c.height/2})};return o.addEventListener("wheel",r,{passive:!1}),()=>o.removeEventListener("wheel",r)},[n,t.local]),a==null)return null;let l=()=>{Wg(a.url).then(()=>t.local.setCopyNote(a.url,"copied ✓")).catch((o)=>t.local.setCopyNote(a.url,`copy failed: ${o instanceof Error?o.message:String(o)}`))};return u("div",{className:"modal-overlay",onClick:()=>t.local.closeLightbox(),children:p("div",{className:"lightbox",onClick:(o)=>o.stopPropagation(),children:[u("div",{ref:i,className:t.local.zoom>1?"zoom-view grabbing":"zoom-view",onDoubleClick:()=>t.local.resetZoom(),onPointerDown:(o)=>{if(t.local.zoom===1)return;o.currentTarget.setPointerCapture(o.pointerId)},onPointerMove:(o)=>{if(o.buttons!==1)return;t.local.panBy(o.movementX,o.movementY)},children:u("img",{src:a.url,alt:a.title,draggable:!1,style:{transform:`translate(${t.local.panX}px, ${t.local.panY}px) scale(${t.local.zoom})`}})}),p("div",{className:"lightbox-bar",children:[u("span",{className:"hint","data-tip":a.title,children:a.title}),t.local.zoom>1?p("button",{type:"button","data-tip":"back to fit (or double click the image)",onClick:()=>t.local.resetZoom(),children:[t.local.zoom.toFixed(1),"× · fit"]}):u("span",{className:"hint",children:"scroll to zoom"}),Ig?u("button",{type:"button",onClick:l,children:"copy"}):null,u("a",{href:a.url,target:"_blank",rel:"noreferrer",children:"open ↗"}),a.promptId!=null?u("button",{type:"button","data-tip":"remove this result",onClick:()=>{if(a.promptId!=null)t.st.run.remove(a.promptId);t.local.closeLightbox()},children:"delete"}):null,t.local.copyNote?.url===a.url?u("span",{className:"hint",children:t.local.copyNote.text}):null,u("button",{type:"button","data-tip":"close (esc)",onClick:()=>t.local.closeLightbox(),children:u(D,{name:"close"})})]})]})})});function Pg(e){let t=e.indexOf("</think>");if(t===-1)return e.trimStart().startsWith("<think>")?{thinking:e.replace(/^\s*<think>/,"").trim(),answer:""}:{thinking:null,answer:e.trim()};let n=e.slice(0,t).replace(/^\s*<think>/,"").trim();return{thinking:n===""?null:n,answer:e.slice(t+8).trim()}}var Ax=L(function(t){let n=Vn(()=>({showThinking:!1,copied:!1,toggle(){this.showThinking=!this.showThinking},markCopied(){this.copied=!0}})),{thinking:a,answer:i}=Pg(t.entry.text);return p("div",{className:"run-text",children:[p("div",{className:"run-text-head",children:[u("span",{className:"hint",children:t.entry.nodeKey??"text"}),a!=null?u("button",{type:"button",className:"link","data-tip":"the model's reasoning, before its answer",onClick:()=>n.toggle(),children:n.showThinking?"hide thinking":"thinking"}):null,Ig?p("button",{type:"button",className:"link","data-tip":"copy this text",onClick:()=>{navigator.clipboard.writeText(i===""?t.entry.text:i),n.markCopied()},children:[u(D,{name:"copy"})," ",n.copied?"copied":""]}):null]}),a!=null&&n.showThinking?u("pre",{className:"run-thinking",children:a}):null,i===""?u("div",{className:"noimg",children:"the model reasoned past its token budget and never answered — raise max tokens"}):u("pre",{className:"run-text-body",children:i})]})}),Tx=L(function(t){let{thinking:n,answer:a}=Pg(t.text),i=fa.useRef(null);fa.useEffect(()=>{let o=i.current;if(o!=null)o.scrollTop=o.scrollHeight});let l=a!==""?a:n??"";return p("div",{className:"run-live",children:[a===""&&n!=null?u("span",{className:"hint",children:"thinking…"}):null,u("pre",{ref:i,className:a===""?"run-live-body dim":"run-live-body",children:l})]})}),Dx=L(function(t){let n=t.st.run.runningModule;if(!t.st.run.isRunning||n==null)return null;let a=t.st.run.progressPercent,i=Tr({module:n,tick:t.st.run.previewTick}),l=t.st.run.progressNode,o=t.st.run.progressCount,r=t.st.run.progressText;return p("div",{className:"run-card running",children:[p("div",{className:"meta",children:[p("span",{children:["generating ",n,"…"]}),u("span",{children:a!=null?`${Math.round(a)}%`:""})]}),l!=null?p("div",{className:"run-node",children:[l,o!=null?` ${o.value}/${o.max}`:""]}):null,r!=null&&r!==""?u(Tx,{text:r}):null,u("div",{className:"progress-track",children:u("div",{className:"progress-fill",style:{width:`${a??0}%`}})}),t.st.run.hasPreview&&t.st.showLatent?u("div",{className:"imgs",children:u("button",{type:"button",className:"img-button",onClick:()=>t.local.openLightbox({kind:"latent",module:n,after:t.st.run.results.filter((s)=>s.module===n).length}),children:u("img",{src:i,alt:"latent preview"})})}):null]})}),eb=L(function(t){let n=Nx();if(t.st.run.results.length===0&&!t.st.run.isRunning)return null;let a=t.compact===!0?t.st.run.results.slice(0,1):t.st.run.results;return p("div",{className:"gallery",children:[u(Dx,{st:t.st,local:n}),a.map((i)=>p("div",{className:"run-card",children:[p("div",{className:"meta",children:[p("span",{children:[i.at," · ",i.module,"/",i.draft," · ",(i.durationMs/1000).toFixed(1),"s",Object.entries(i.seeds).map(([l,o])=>` · ${l}: ${o}`)]}),u("button",{type:"button",className:"link","data-tip":"remove this result",onClick:()=>t.st.run.remove(i.promptId),children:u(D,{name:"trash"})})]}),p("div",{className:"imgs",children:[i.images.map((l)=>l.url!=null?u("button",{type:"button",className:"img-button","data-tip":l.filename,onClick:()=>{if(l.url!=null)n.openLightbox({kind:"image",url:l.url,title:l.filename,promptId:i.promptId})},children:u("img",{src:l.url,alt:l.filename})},l.filename):p("div",{className:"noimg",children:[l.filename," (not saved locally — no preview)"]},l.filename)),i.images.length===0&&(i.texts??[]).length===0?u("div",{className:"noimg",children:"no outputs"}):null]}),(i.texts??[]).map((l,o)=>u(Ax,{entry:l},`${i.promptId}-${o}`))]},i.promptId)),u(Ox,{st:t.st,local:n})]})});function zx(e){return e.split(/[/\\]/).filter((t)=>t!=="")}function Rx(e){return zx(e).slice(0,-1)}function Mx(e){let t=e[0];if(t==null)return[];let n=[];for(let a=0;a<t.length;a++){let i=t[a];if(i==null||!e.every((l)=>l[a]===i))break;n.push(i)}return n}function tb(e){if(e.length===0)return[];let t=e.map((l)=>Rx(l.file)),n=Mx(t),a=Math.max(0,n.length-1),i=new Map;for(let[l,o]of e.entries()){let r=(t[l]??[]).slice(a).join("/"),s=i.get(r);if(s==null)i.set(r,[o]);else s.push(o)}return[...i.entries()].map(([l,o])=>({folder:l,modules:[...o].sort((r,s)=>r.module.localeCompare(s.module))})).sort((l,o)=>l.folder.localeCompare(o.folder))}var nb=L(function(t){let n=tb(t.st.modules);return p("div",{className:"sidebar",children:[p("div",{className:"side-head",children:[u("span",{children:"workflows"}),u("button",{type:"button","data-tip":"close — reopen it by clicking the workflow name",onClick:()=>t.st.toggleSidebar(),children:u(D,{name:"close"})})]}),n.map((a)=>p("div",{className:"side-group",children:[a.folder===""?null:p("div",{className:"side-folder",children:[a.folder,"/"]}),u("div",{className:"side-branch",children:a.modules.map((i)=>p("div",{children:[p("div",{className:"side-module",children:[u("span",{className:"name",children:i.module}),u("span",{className:"host",children:i.host})]}),i.drafts.map((l)=>{let o=t.st.form?.moduleKey===i.module&&t.st.form?.draft===l;return u("button",{type:"button",className:o?"side-draft sel":"side-draft",onClick:()=>void t.st.select({module:i.module,draft:l}),children:l},l)})]},i.module))})]},a.folder)),Object.keys(t.st.loadErrors).length>0?p("div",{className:"side-errors",children:[u("div",{children:"failed to load:"}),Object.entries(t.st.loadErrors).map(([a,i])=>p("div",{children:[u("div",{className:"file",children:a}),u("div",{className:"msg",children:i})]},a))]}):null]})});var Xb=$e(ft(),1);var ib=$e(ft(),1);function ab(e,t){let n=t.trim();return e.find((a)=>a.text.trim()===n)?.label??null}function Cx(e){let t=e.split(`
10
+ `).find((n)=>n.trim()!=="")??"";return t.length<=90?t:`${t.slice(0,89)}…`}var Dr=L(function(t){let n=t.v.desc.textPresets??[],[a,i]=ib.useState(!1);if(n.length===0)return null;let l=typeof t.v.value==="string"?t.v.value:"",o=ab(n,l);return p("div",{className:"preset-box",onKeyDown:(r)=>r.key==="Escape"?i(!1):void 0,children:[p("button",{type:"button",className:"preset-btn","aria-expanded":a,"data-tip":"named starting texts — picking one replaces the field",onClick:()=>i(!a),children:[u(D,{name:"tag"})," presets ▾"]}),a?p(he,{children:[u("div",{className:"preset-backdrop",onClick:()=>i(!1)}),u("div",{className:"preset-menu",children:n.map((r)=>p("button",{type:"button",className:r.label===o?"preset-item on":"preset-item",onClick:()=>{t.v.set(r.text),i(!1)},children:[p("span",{className:"preset-name",children:[r.label===o?"• ":"  ",r.label]}),u("span",{className:"preset-peek",children:Cx(r.text)})]},r.label))})]}):null]})});var gb=$e(ft(),1);function Cl(e){let t={};if(typeof e==="object"&&e!==null&&!Array.isArray(e)){for(let[n,a]of Object.entries(e))if(typeof a==="string")t[n]=a}return t}function bi(e){return e==="openrouter"?"https://openrouter.ai/api/v1":"http://localhost:3000"}function zr(e){return e.trim().replace(/\/+$/,"")}function Ux(e){let t=zr(e.baseUrl)===""?bi(e.provider):zr(e.baseUrl);return e.provider==="openrouter"?`${t}/models`:`${t}/api/models`}function kx(e){let t=zr(e.baseUrl)===""?bi(e.provider):zr(e.baseUrl);return e.provider==="openrouter"?`${t}/chat/completions`:`${t}/api/chat/completions`}function gi(e){return typeof e==="object"&&e!==null&&!Array.isArray(e)?e:{}}function tn(e){return typeof e==="string"?e:""}function Vx(e){let t=gi(e).data;if(!Array.isArray(t))return[];let n=[];for(let a of t){let i=gi(a),l=tn(i.id);if(l==="")continue;let o=i.supported_parameters,r=Array.isArray(o)?o.includes("reasoning"):null;n.push({id:l,name:tn(i.name)===""?l:tn(i.name),reasoning:r})}return n.sort((a,i)=>a.id.localeCompare(i.id)),n}async function lb(e,t){let n=await e.text().catch(()=>"");return Error(`llm ${t} failed: http ${e.status} ${n.slice(0,300)}`)}function ob(e,t){if(e instanceof Error&&e.name==="AbortError")return e;let n=e instanceof Error?e.message:String(e);return Error(`could not reach ${t} (${n}) — is it running, and does it allow this origin? open webui needs CORS_ALLOW_ORIGIN`)}async function rb(e){let t=Ux(e),n;try{n=await fetch(t,{headers:sb(e)})}catch(a){throw ob(a,t)}if(!n.ok)throw await lb(n,"model list");return Vx(await n.json())}function sb(e){return e.key.trim()===""?{}:{Authorization:`Bearer ${e.key.trim()}`}}function Lx(e){let t=e.provider==="openrouter"&&e.effort!=="off"?{reasoning:{effort:e.effort}}:{};return{model:e.model,stream:!0,messages:[{role:"system",content:e.system},{role:"user",content:e.user}],...t}}function Bx(e){let t=e.split(`
11
+ `),n=t.pop()??"",a=[];for(let i of t){let l=i.trim();if(l===""||l.startsWith(":"))continue;if(l.startsWith("data:"))a.push(l.slice(5).trim())}return{events:a,rest:n}}function Hx(e){if(e===""||e==="[DONE]")return null;let t;try{t=JSON.parse(e)}catch{return null}let n=gi(t),a=gi(n.error);if(tn(a.message)!=="")throw Error(`llm stream error: ${tn(a.message)}`);let i=n.choices;if(!Array.isArray(i))return null;let l=gi(gi(i[0]).delta),o=tn(l.content),r=tn(l.reasoning)===""?tn(l.reasoning_content):tn(l.reasoning);if(o===""&&r==="")return null;return{content:o,reasoning:r}}class ub{inside=!1;pending="";feed(e){let t=this.pending+e;this.pending="";let n="",a="";for(;;){let l=this.inside?"</think>":"<think>",o=t.indexOf(l);if(o===-1)break;let r=t.slice(0,o);if(this.inside)a+=r;else n+=r;t=t.slice(o+l.length),this.inside=!this.inside}let i=jx(t);if(i!==-1)this.pending=t.slice(i),t=t.slice(0,i);if(this.inside)a+=t;else n+=t;return{content:n,reasoning:a}}flush(){let e=this.pending;return this.pending="",this.inside?{content:"",reasoning:e}:{content:e,reasoning:""}}}function jx(e){let t=e.lastIndexOf("<");if(t===-1)return-1;let n=e.slice(t);return"<think>".startsWith(n)||"</think>".startsWith(n)?t:-1}async function cb(e){if(e.endpoint.provider==="openrouter"&&e.endpoint.key.trim()==="")throw Error("no openrouter api key — paste one in the enhancer settings");if(e.model.trim()==="")throw Error("no model selected");let t=kx(e.endpoint),n;try{n=await fetch(t,{method:"POST",headers:{...sb(e.endpoint),"content-type":"application/json"},body:JSON.stringify(Lx({...e,provider:e.endpoint.provider})),signal:e.signal})}catch(c){throw ob(c,t)}if(!n.ok)throw await lb(n,"refine");let a=n.body?.getReader();if(a==null)throw Error("llm refine failed: the response carried no stream");let i=new TextDecoder,l=new ub,o={content:"",reasoning:""},r=(c)=>{if(c.content===""&&c.reasoning==="")return;o.content+=c.content,o.reasoning+=c.reasoning,e.onDelta(c)},s="";for(;;){let c=await a.read();if(c.done)break;s+=i.decode(c.value,{stream:!0});let m=Bx(s);s=m.rest;for(let b of m.events){let h=Hx(b);if(h==null)continue;let g=l.feed(h.content);r({content:g.content,reasoning:g.reasoning+h.reasoning})}}if(r(l.flush()),o.content.trim()==="")throw Error("the model returned no prompt text — try another model");return o}var hb="comfy-ts-serve-enhancer",qx={openrouter:"anthropic/claude-sonnet-5",openwebui:""},pb=["openrouter","openwebui"];function mb(e){return e==="openrouter"||e==="openwebui"}function vb(e){return e==="off"||e==="low"||e==="medium"||e==="high"}function fb(e){let t=typeof e==="object"&&e!==null?e:{},n=Cl(t.modelByProvider),a=Cl(t.baseUrlByProvider);return{provider:mb(t.provider)?t.provider:"openrouter",keyByProvider:Cl(t.keyByProvider),baseUrlByProvider:{openrouter:bi("openrouter"),openwebui:bi("openwebui"),...a},modelByProvider:{...qx,...n},effort:vb(t.effort)?t.effort:"medium",thinkingOnly:t.thinkingOnly!==!1,presetName:typeof t.presetName==="string"?t.presetName:"",presetByModule:Cl(t.presetByModule)}}function db(e,t){if(!t.includes(e))return e;for(let n=2;n<1000;n++){let a=`${e} ${n}`;if(!t.includes(a))return a}return`${e} ${t.length+1}`}function Gx(){try{return fb(JSON.parse(localStorage.getItem(hb)??"{}"))}catch{return fb({})}}class sf{provider;keyByProvider;baseUrlByProvider;modelByProvider;effort;thinkingOnly;presetName;presetByModule;presets=[];presetsState="idle";presetsError="";saveState="saved";saveError="";models=[];modelsState="idle";modelsError="";target=null;targetModule="";original="";result="";thinking="";phase="idle";error="";abort=null;disposer;lastSaved="";constructor(){let e=Gx();this.provider=e.provider,this.keyByProvider=e.keyByProvider,this.baseUrlByProvider=e.baseUrlByProvider,this.modelByProvider=e.modelByProvider,this.effort=e.effort,this.thinkingOnly=e.thinkingOnly,this.presetName=e.presetName,this.presetByModule=e.presetByModule,en(this,{abort:!1,disposer:!1,lastSaved:!1}),this.disposer=Or(()=>{let t=this.preset;return t==null?null:JSON.stringify(t)},(t)=>{if(t==null||t===this.lastSaved)return;this.savePresetNow(JSON.parse(t))},{delay:600})}dispose(){this.disposer()}get apiKey(){return this.keyByProvider[this.provider]??""}get baseUrl(){return this.baseUrlByProvider[this.provider]??bi(this.provider)}get model(){return this.modelByProvider[this.provider]??""}get endpoint(){return{provider:this.provider,baseUrl:this.baseUrl,key:this.apiKey}}get visibleModels(){return this.thinkingOnly?this.models.filter((e)=>e.reasoning!==!1):this.models}get preset(){return this.presets.find((e)=>e.name===this.presetName)??this.presets[0]??null}get isOpen(){return this.target!=null}settingsJSON(){return{provider:this.provider,keyByProvider:this.keyByProvider,baseUrlByProvider:this.baseUrlByProvider,modelByProvider:this.modelByProvider,effort:this.effort,thinkingOnly:this.thinkingOnly,presetName:this.presetName,presetByModule:this.presetByModule}}persist(){try{localStorage.setItem(hb,JSON.stringify(this.settingsJSON()))}catch{}}setProvider(e){if(!mb(e))return;this.provider=e,this.models=[],this.modelsState="idle",this.modelsError="",this.persist()}setApiKey(e){this.keyByProvider[this.provider]=e.trim(),this.persist()}setBaseUrl(e){this.baseUrlByProvider[this.provider]=e.trim(),this.persist()}setModel(e){this.modelByProvider[this.provider]=e,this.persist()}setEffort(e){if(!vb(e))return;this.effort=e,this.persist()}toggleThinkingOnly(){this.thinkingOnly=!this.thinkingOnly,this.persist()}async loadPresets(){E(()=>{this.presetsState="loading",this.presetsError=""});try{let e=await Qg();E(()=>{if(this.presets=e.enhancers,this.presetsState="idle",!this.presets.some((t)=>t.name===this.presetName))this.presetName=this.presets[0]?.name??"";this.lastSaved=JSON.stringify(this.preset)})}catch(e){E(()=>{this.presetsState="error",this.presetsError=e instanceof Error?e.message:String(e)})}}async savePresetNow(e){E(()=>{this.saveState="saving",this.lastSaved=JSON.stringify(e)});try{let t=await Zg(e);E(()=>{this.presets=t.enhancers,this.saveState="saved",this.saveError=""})}catch(t){E(()=>{this.saveState="error",this.saveError=t instanceof Error?t.message:String(t)})}}selectPreset(e){if(!this.presets.some((t)=>t.name===e))return;if(this.presetName=e,this.lastSaved=JSON.stringify(this.preset),this.targetModule!=="")this.presetByModule[this.targetModule]=e;this.persist()}setPresetText(e){let t=this.preset;if(t==null)return;this.presets=this.presets.map((n)=>n.name===t.name?{...n,text:e}:n)}addPreset(e,t=""){if(e.trim()==="")return;let n=db(e.trim(),this.presets.map((a)=>a.name));this.presets=[...this.presets,{name:n,text:t}],this.presetName=n,this.persist(),this.savePresetNow({name:n,text:t})}duplicatePreset(){let e=this.preset;if(e!=null)this.addPreset(`${e.name} copy`,e.text)}async renamePreset(e){let t=this.preset,n=db(e.trim(),this.presets.filter((a)=>a.name!==t?.name).map((a)=>a.name));if(t==null||n===""||n===t.name)return;await this.savePresetNow({name:n,text:t.text}),E(()=>{this.presetName=n,this.persist()}),await this.removePresetFile(t.name)}async deletePreset(){let e=this.preset;if(e==null)return;await this.removePresetFile(e.name),E(()=>{for(let[t,n]of Object.entries(this.presetByModule))if(n===e.name)delete this.presetByModule[t];if(!this.presets.some((t)=>t.name===this.presetName))this.presetName=this.presets[0]?.name??"";this.persist()})}async removePresetFile(e){try{let t=await $g({name:e});E(()=>{this.presets=t.enhancers})}catch(t){E(()=>{this.saveState="error",this.saveError=t instanceof Error?t.message:String(t)})}}openFor(e){this.target=e.v,this.targetModule=e.module,this.original=typeof e.v.value==="string"?e.v.value:"",this.result="",this.thinking="",this.error="",this.phase="idle";let t=this.presetByModule[e.module];if(t!=null)this.presetName=t;if(this.presets.length===0)this.loadPresets()}close(){this.cancel(),this.target=null,this.targetModule=""}setResult(e){this.result=e}setOriginal(e){this.original=e}async loadModels(){E(()=>{this.modelsState="loading",this.modelsError=""});try{let e=await rb(this.endpoint);E(()=>{this.models=e,this.modelsState="idle"})}catch(e){E(()=>{this.modelsState="error",this.modelsError=e instanceof Error?e.message:String(e)})}}cancel(){if(this.abort?.abort(),this.abort=null,this.phase==="running")this.phase=this.result===""?"idle":"done"}run(){this.runNow()}async runNow(){let e=this.preset;if(e==null||this.phase==="running")return;let t=new AbortController;this.abort=t,E(()=>{this.phase="running",this.error="",this.result="",this.thinking=""});try{await cb({endpoint:this.endpoint,model:this.model,system:e.text,user:this.original,effort:this.effort,signal:t.signal,onDelta:(n)=>E(()=>{this.result+=n.content,this.thinking+=n.reasoning})}),E(()=>{this.phase="done"})}catch(n){let a=t.signal.aborted;E(()=>{if(this.phase=a?this.result===""?"idle":"done":"error",!a)this.error=n instanceof Error?n.message:String(n)})}finally{if(this.abort===t)this.abort=null}}apply(){let e=this.result.trim();if(this.target==null||e==="")return;this.target.set(e),this.close()}}var Yx=["off","low","medium","high"],Kx={openrouter:"openrouter (cloud)",openwebui:"open webui (local)"},Xx=L(function(t){let n=t.e.visibleModels,a=t.e.provider==="openwebui";return p("div",{children:[u("div",{className:"section-title",children:"provider · keys stay in this browser"}),p("div",{className:"enh-row",children:[u("select",{value:t.e.provider,onChange:(i)=>t.e.setProvider(i.target.value),children:pb.map((i)=>u("option",{value:i,children:Kx[i]},i))}),a?u("input",{type:"text",placeholder:"http://localhost:3000",value:t.e.baseUrl,onChange:(i)=>t.e.setBaseUrl(i.target.value),style:{flex:1,minWidth:180}}):null,u("input",{type:"password",placeholder:a?"open webui api key (blank if none)":"sk-or-v1-… (localStorage only)",value:t.e.apiKey,onChange:(i)=>t.e.setApiKey(i.target.value),style:{flex:1,minWidth:160}}),u("button",{type:"button",onClick:()=>void t.e.loadModels(),disabled:t.e.modelsState==="loading",children:t.e.modelsState==="loading"?"loading…":"load models"})]}),p("div",{className:"enh-row",children:[n.length>0?p("select",{value:t.e.model,onChange:(i)=>t.e.setModel(i.target.value),style:{flex:1},children:[n.some((i)=>i.id===t.e.model)?null:p("option",{value:t.e.model,children:[t.e.model," (not in the list)"]}),n.map((i)=>u("option",{value:i.id,children:i.id},i.id))]}):u("input",{type:"text",placeholder:a?"model id, e.g. qwen3:8b":"model id, e.g. anthropic/claude-sonnet-5",value:t.e.model,onChange:(i)=>t.e.setModel(i.target.value),style:{flex:1}}),p("label",{className:"row-inline","data-tip":"hide models that report no reasoning support",children:[u("input",{type:"checkbox",checked:t.e.thinkingOnly,onChange:()=>t.e.toggleThinkingOnly()}),u("span",{className:"hint",children:"thinking only"})]}),a?null:p("label",{className:"row-inline","data-tip":"reasoning effort sent to the model",children:[u("span",{className:"hint",children:"effort"}),u("select",{value:t.e.effort,onChange:(i)=>t.e.setEffort(i.target.value),children:Yx.map((i)=>u("option",{value:i,children:i},i))})]})]}),a?u("div",{className:"hint",children:"a local model's <think> block is routed to the thinking pane, never into your prompt"}):null,t.e.modelsError!==""?p("div",{className:"error",children:["\uD83D\uDD34 ",t.e.modelsError]}):null]})}),Qx=L(function(t){let n=t.e.preset;if(n==null)return p("div",{children:[u("div",{className:"section-title",children:"master prompt"}),u("div",{className:"hint",children:t.e.presetsState==="loading"?"loading .comfy-ts/prompt-enhancers/…":"no master prompt yet"}),t.e.presetsError!==""?p("div",{className:"error",children:["\uD83D\uDD34 ",t.e.presetsError]}):null,u("button",{type:"button",onClick:()=>t.e.addPreset("refine-prompt"),children:"create one"})]});let a=()=>{let o=window.prompt("rename this master prompt (renames the file)",n.name);if(o!=null)t.e.renamePreset(o)},i=()=>{let o=window.prompt("name the new master prompt","refine-<model>-prompt");if(o!=null)t.e.addPreset(o)},l=()=>{if(window.confirm(`delete master prompt '${n.name}'? the .md file is removed.`))t.e.deletePreset()};return p("div",{children:[p("div",{className:"section-title",children:["master prompt · one per image model · .comfy-ts/prompt-enhancers/",n.name,".md"]}),p("div",{className:"enh-row",children:[u("select",{value:n.name,onChange:(o)=>t.e.selectPreset(o.target.value),style:{flex:1},children:t.e.presets.map((o)=>u("option",{value:o.name,children:o.name},o.name))}),u("button",{type:"button",onClick:i,children:"new"}),u("button",{type:"button",onClick:()=>t.e.duplicatePreset(),children:"duplicate"}),u("button",{type:"button",onClick:a,children:"rename"}),u("button",{type:"button",onClick:l,"data-tip":"delete this master prompt file",children:u(D,{name:"close"})}),p("span",{className:"hint",children:[t.e.saveState==="saving"?"saving…":null,t.e.saveState==="saved"?"autosaved to disk":null,t.e.saveState==="error"?`\uD83D\uDD34 save failed: ${t.e.saveError}`:null]})]}),u("textarea",{rows:8,value:n.text,onChange:(o)=>t.e.setPresetText(o.target.value)})]})}),Zx=L(function(t){let n=t.e;gb.useEffect(()=>{let i=(l)=>{if(l.key==="Escape")n.close();if(l.key==="Enter"&&(l.metaKey||l.ctrlKey))l.preventDefault(),n.run()};return window.addEventListener("keydown",i),()=>window.removeEventListener("keydown",i)},[n]);let a=n.phase==="running";return u("div",{className:"modal-overlay",onClick:()=>n.close(),children:p("div",{className:"modal",onClick:(i)=>i.stopPropagation(),children:[p("div",{className:"modal-head",children:[p("b",{style:{flex:1},children:[u(D,{name:"sparkle"})," enhance prompt"]}),u("button",{type:"button",onClick:()=>n.close(),children:u(D,{name:"close"})})]}),p("div",{className:"modal-body",children:[u(Xx,{e:n}),u(Qx,{e:n}),u("div",{className:"section-title",children:"prompt"}),p("div",{className:"enh-cols",children:[p("div",{children:[u("div",{className:"hint",children:"yours (edit before refining, the var is untouched)"}),u("textarea",{rows:8,value:n.original,onChange:(i)=>n.setOriginal(i.target.value)})]}),p("div",{children:[u("div",{className:"hint",children:a?"rewriting…":"rewritten (editable before apply)"}),u("textarea",{rows:8,value:n.result,placeholder:"hit enhance",onChange:(i)=>n.setResult(i.target.value)})]})]}),n.thinking!==""?p("div",{children:[u("div",{className:"section-title",children:"thinking"}),u("div",{className:"enh-think",children:n.thinking})]}):null,n.error!==""?p("div",{className:"error",children:["\uD83D\uDD34 ",n.error]}):null]}),p("div",{className:"modal-foot",children:[a?u("button",{type:"button",onClick:()=>n.cancel(),children:"stop"}):u("button",{type:"button",className:"primary",onClick:()=>n.run(),"data-tip":"⌘⏎ / ctrl+⏎",children:"enhance"}),u("button",{type:"button",onClick:()=>n.apply(),disabled:n.result.trim()==="",children:"apply to prompt"}),u("span",{className:"hint",style:{flex:1},children:a?`${n.result.length} chars streamed`:"nothing is written until you apply"}),u("button",{type:"button",className:"link",onClick:()=>n.close(),children:"cancel"})]})]})})}),bb=L(function(t){let n=t.st.enhancer;return p(he,{children:[p("button",{type:"button",className:"link","data-tip":"rewrite this prompt with an llm",onClick:()=>n.openFor({v:t.v,module:t.module}),children:[u(D,{name:"sparkle"})," enhance"]}),n.target===t.v?u(Zx,{e:n}):null]})});var yb=L(function(t){let n=typeof t.v.value==="string"?t.v.value:"",a=Math.min(12,Math.max(4,n.split(`
12
+ `).length+1)),i=t.st.form?.loraKeywordsFor(t.v)??[];return p("div",{children:[i.length>0?u("div",{className:"kw-prefix","data-tip":"added in front of your prompt at run time, one per active lora",children:i.map((l)=>u("span",{className:"kw-chip",children:l},l))}):null,u("textarea",{rows:a,value:n,onChange:(l)=>t.v.set(l.target.value)}),p("div",{className:"row-inline",children:[u("span",{className:"hint",children:'// line = comment · "- " line = negative prompt'}),u(Dr,{v:t.v}),u(bb,{v:t.v,st:t.st,module:t.module})]})]})}),_b=L(function(t){let n=typeof t.v.value==="string"?t.v.value:"",a=t.v.desc.textPresets??[];if(t.v.desc.multiline===!0){let i=Math.min(12,Math.max(3,n.split(`
13
+ `).length+1));return p("div",{children:[u("textarea",{rows:i,value:n,onChange:(l)=>t.v.set(l.target.value)}),a.length>0?u("div",{className:"row-inline",children:u(Dr,{v:t.v})}):null]})}if(a.length===0)return u("input",{type:"text",value:n,onChange:(i)=>t.v.set(i.target.value)});return p("div",{className:"row-inline",children:[u("input",{type:"text",style:{flex:1},value:n,onChange:(i)=>t.v.set(i.target.value)}),u(Dr,{v:t.v})]})}),Sb=L(function(t){let n=t.v.desc.kind==="int",a=typeof t.v.value==="number"?t.v.value:0,i=t.v.desc.min,l=t.v.desc.max,o=(r)=>{let s=n?parseInt(r,10):parseFloat(r);if(Number.isFinite(s))t.v.set(s)};return p("div",{className:"row-inline",children:[u("input",{type:"number",value:a,step:n?1:"any",min:i,max:l,onChange:(r)=>o(r.target.value)}),i!=null&&l!=null?u("input",{type:"range",style:{flex:1,minWidth:120},value:a,min:i,max:l,step:n?1:(l-i)/200,onChange:(r)=>o(r.target.value)}):null,i!=null||l!=null?u("span",{className:"hint",children:`${i??"-∞"} … ${l??"∞"}`}):null]})}),xb=L(function(t){return p("label",{className:"row-inline",style:{cursor:"pointer"},children:[u("input",{type:"checkbox",checked:t.v.value===!0,onChange:(n)=>t.v.set(n.target.checked)}),u("span",{className:"hint",children:t.v.value===!0?"on":"off"})]})}),Eb=L(function(t){let n=t.v.desc.choices??[],a=typeof t.v.value==="string"?t.v.value:"";return p("select",{value:a,onChange:(i)=>t.v.set(i.target.value),children:[n.includes(a)?null:u("option",{value:a,disabled:!0,children:a===""?"(unset)":`${a} (not on this host)`}),n.map((i)=>u("option",{value:i,children:i},i))]})});var wb=$e(ft(),1);var Nb=L(function(t){let n=wb.useRef(null),a=typeof t.v.value==="string"?t.v.value:"",i=/^https?:\/\//.test(a)?a:t.v.uploadedUrl,l=t.v.desc.extensions??[],o=async(r)=>{if(r==null)return;try{let s=await Jg({file:r});t.v.set(s.path),t.v.setUploadedUrl(s.url)}catch(s){alert(`upload failed: ${s instanceof Error?s.message:String(s)}`)}};return p("div",{children:[p("div",{className:"row-inline",children:[u("input",{type:"text",style:{flex:1},placeholder:"local path or http(s) url",value:a,onChange:(r)=>{t.v.set(r.target.value),t.v.setUploadedUrl(null)}}),u("button",{type:"button",onClick:()=>n.current?.click(),children:"upload…"}),a!==""?u("button",{type:"button","data-tip":"clear the image",onClick:()=>{t.v.set(""),t.v.setUploadedUrl(null)},children:u(D,{name:"close"})}):null,u("input",{ref:n,type:"file",accept:l.map((r)=>`.${r}`).join(","),style:{display:"none"},onChange:(r)=>{o(r.target.files?.[0]),r.target.value=""}})]}),i!=null&&i!==""?u("div",{className:"img-preview",children:u("img",{src:i,alt:a})}):null]})});function Ln(e,t){console.error(`\uD83D\uDD34 [comfy-ts serve] ${e}: ${t instanceof Error?t.message:String(t)}`)}var Bn=$e(ft(),1);function Ob(e){let t={};for(let n of e)if(n.kind!=="seed")t[n.name]=n.value;return t}function Ul(e){if(typeof e==="number"&&Number.isFinite(e))return{mode:"=",value:e};if(e!=null&&typeof e==="object"){let t=e;return{mode:typeof t.mode==="string"?t.mode:"=",value:typeof t.value==="number"&&Number.isFinite(t.value)?t.value:0}}return{mode:"=",value:0}}function uf(e){if(e!=null&&typeof e==="object"){let t=e;if(typeof t.width==="number"&&typeof t.height==="number")return{width:t.width,height:t.height}}return{width:1024,height:1024}}function $x(e,t){if(e==null||typeof e!=="object"||Array.isArray(e))return{};let n=new Set(t),a={};for(let[i,l]of Object.entries(e))if(n.has(i)&&Rr(l))a[i]=l;return a}function Ab(e,t){if(e.kind==="seed")return Ul(t??e.default);if(e.kind==="size")return uf(t??e.default);if(e.kind==="loras")return $x(t??e.default,e.options??[]);return t??e.default}function Tb(){return Math.floor(Math.random()*4294967296)}function Rr(e){return e!=null&&e!==!1}function Mr(e){if(typeof e==="number"&&Number.isFinite(e))return{model:e,clip:e};if(Array.isArray(e)&&typeof e[0]==="number"&&typeof e[1]==="number")return{model:e[0],clip:e[1]};return{model:1,clip:1}}function Db(e,t,n,a){let i={...e};if(!n)i[t]=!1;else{let l=a??Mr(e[t]);i[t]=[l.model,l.clip]}return i}function zb(e){let t=new Set(e.options),n=Object.keys(e.record).filter((i)=>t.has(i)&&(Rr(e.record[i])||e.paused.has(i))),a=[...e.paused].filter((i)=>t.has(i)&&!n.includes(i));return[...n,...a].reverse()}function Rb(e){let t=[...e.displayed],[n]=t.splice(e.from,1);if(n==null)return e.record;t.splice(e.to,0,n);let a={};for(let i of[...t].reverse())if(i in e.record)a[i]=e.record[i];for(let[i,l]of Object.entries(e.record))if(!(i in a))a[i]=l;return a}function Mb(e,t,n){return{...e,[t]:[n.model,n.clip]}}var cf="application/x-comfy-lora";function Jx(e){if(e!=null&&typeof e==="object"&&!Array.isArray(e))return e;return{}}var Cb=L(function(t){let n=Vn(()=>({open:!1,filter:"",info:new Map,previewFailed:new Set,prevStrength:new Map,paused:new Set,setOpen(_){this.open=_},setFilter(_){this.filter=_},noteInfo(_,T){this.info.set(_,T)},notePreviewFailed(_){this.previewFailed.add(_)},notePrevStrength(_,T){this.prevStrength.set(_,T)},setPaused(_,T){if(T)this.paused.add(_);else this.paused.delete(_)},details:null,setDetails(_){this.details=_},split:new Map,isSplit(_,T){return this.split.get(_)??T},setSplit(_,T){this.split.set(_,T)}})),a=Jx(t.v.value),i=t.v.desc.options??[],l=t.v.desc.optionLabels??{},o=(_)=>l[_]??_,r=(_)=>Rr(a[_]),s=(_)=>r(_)||n.paused.has(_),c=zb({record:a,options:i,paused:n.paused}),m=new Set(t.v.desc.managerOnlyOptions??[]),b="on disk and known to the lora manager, but ComfyUI has not scanned it: it refuses the prompt. only restarting ComfyUI makes it re-read the folder",h=(_)=>m.has(_)?u("span",{className:"lora-warn","data-tip":"on disk and known to the lora manager, but ComfyUI has not scanned it: it refuses the prompt. only restarting ComfyUI makes it re-read the folder",children:u(D,{name:"warn",size:0.9})}):null,g=c.filter((_)=>m.has(_)),x=t.st.showLoraImages,A=t.st.showLoraTitles,M=(_,T)=>{n.setPaused(_,!1);let Y={...a};if(T==null)delete Y[_];else Y[_]=T;t.v.set(Y)},d=(_,T)=>{if(!T)n.notePrevStrength(_,Mr(a[_]));n.setPaused(_,!T),t.v.set(Db(a,_,T,T?n.prevStrength.get(_):void 0))},f=(_,T)=>{if(!r(_)){n.notePrevStrength(_,T);return}t.v.set(Mb(a,_,T))},v=(_)=>{let T=r(_)?Mr(a[_]):n.prevStrength.get(_)??{model:1,clip:1},Y=n.isSplit(_,T.model!==T.clip),bt=(yi,_i)=>{if(!Number.isFinite(_i))return;let da=Math.round(_i*100)/100;if(yi==="both")return f(_,{model:da,clip:da});f(_,yi==="model"?{model:da,clip:T.clip}:{model:T.model,clip:da})},Hn=(yi,_i,da,ny)=>p("div",{className:"st-line",children:[u("button",{type:"button",className:"st-label","data-tip":ny,onClick:()=>n.setSplit(_,!Y),children:da}),u("input",{type:"range",min:-1,max:2,step:0.05,value:_i,onChange:(Vr)=>bt(yi,parseFloat(Vr.target.value))}),u("input",{type:"number",step:0.05,value:_i,onChange:(Vr)=>bt(yi,parseFloat(Vr.target.value))})]});if(!Y)return Hn("both",T.model,"m+c","model and clip together — click to set them apart");return p(he,{children:[Hn("model",T.model,"m","model strength — click to tie them back together"),Hn("clip",T.clip,"c","clip strength — click to tie them back together")]})},y=n.open,w=t.host,U=c.join(`
14
+ `);Bn.useEffect(()=>{if(!y)return;for(let _ of U.split(`
15
+ `)){if(_===""||n.info.has(_))continue;n.noteInfo(_,"loading"),of({host:w,name:_}).then((T)=>n.noteInfo(_,T)).catch(()=>n.noteInfo(_,"error"))}},[y,U,w,n]),Bn.useEffect(()=>{if(!y)return;let _=(T)=>{if(T.key==="Escape")n.setOpen(!1)};return window.addEventListener("keydown",_),()=>window.removeEventListener("keydown",_)},[y,n]);let O=n.filter.toLowerCase(),R=(_)=>_.toLowerCase().includes(O)||o(_).toLowerCase().includes(O),k=i.filter(R),B=t.st.loraCap,ct=k.filter((_)=>!s(_)).slice(0,B),Cr=(_)=>{let T=_.split(/[\\/]+/);return T.length<=1?"":T.slice(0,-1).join("/")},ey=(()=>{let _=new Map;for(let T of ct){let Y=Cr(T),bt=_.get(Y);if(bt==null)_.set(Y,[T]);else bt.push(T)}return[..._.entries()].map(([T,Y])=>({folder:T,names:Y})).sort((T,Y)=>T.folder.localeCompare(Y.folder))})(),Ur=Bn.useRef(null);Bn.useEffect(()=>{if(!y)return;let _=Ur.current;if(_==null)return;_.focus(),_.select()},[y]);let ty=()=>{let _=ct[0];if(_==null)return;M(_,[1,1]),Ur.current?.select()},kr=(_)=>{if(!x)return null;return n.previewFailed.has(_)?u("div",{className:"lora-thumb none",children:"no preview"}):u("img",{className:t.st.loraFill?"lora-thumb fill":"lora-thumb",loading:"lazy",src:rf({host:t.host,name:_}),alt:o(_),onError:()=>n.notePreviewFailed(_)},_)},gf=p(he,{children:[u("button",{type:"button",className:x?"mode sel":"mode","data-tip":x?"hide lora images":"show lora images",onClick:()=>t.st.toggleLoraImages(),children:u(D,{name:"image"})}),u("button",{type:"button",className:A?"mode sel":"mode","data-tip":A?"hide lora titles":"show lora titles",onClick:()=>t.st.toggleLoraTitles(),children:u(D,{name:"tag"})}),x?u("button",{type:"button",className:t.st.loraFill?"mode sel":"mode","data-tip":t.st.loraFill?"fit the whole preview inside the card":"fill the card with the preview",onClick:()=>t.st.toggleLoraFill(),children:u(D,{name:t.st.loraFill?"shrink":"expand"})}):null]});return p("div",{children:[p("div",{className:"lora-actions",children:[p("button",{type:"button",className:"field-height",onClick:()=>n.setOpen(!0),children:[u(D,{name:"plus"})," ",c.length===0?`add loras (${i.length})`:"add"]}),u("span",{className:"btn-group field-height",children:gf}),p("button",{type:"button",className:"field-height",disabled:t.st.loraSyncing,"data-tip":"re-download the lora metadata from the lora manager on this host (names, trigger words, previews)",onClick:()=>void t.st.refreshLoras(),children:[u(D,{name:"refresh"})," ",t.st.loraSyncing?"syncing…":"sync"]}),g.length>0?p("button",{type:"button",className:"field-height warn-action",disabled:t.st.hostWatch==="down","data-tip":`${g.length} lora(s) here are on disk but ComfyUI has not scanned them, so it refuses the prompt. Only a RESTART makes it re-read its models folder: refetching the schema just re-reads the same list. then hit refresh here and the var widens in place`,onClick:()=>void t.st.hostAction("restart"),children:[u(D,{name:"power"})," restart ComfyUI"]}):null,t.hostUrl==null?null:p("a",{className:"button-link field-height",href:`${t.hostUrl}/loras`,target:"_blank",rel:"noreferrer","data-tip":"open the lora manager of this host in a new tab",children:[u(D,{name:"external"})," manager"]}),c.length>0?p("span",{className:"hint",children:[c.length," in the palette · ",c.filter(r).length," on"]}):null,t.v.desc.optionsFilter==null?null:p("span",{className:"hint","data-tip":"this workflow declared v.loras(<regex>) — only matching loras are offered",children:["filter ",t.v.desc.optionsFilter]})]}),u("div",{className:"row-inline",children:!x&&!A?p("span",{className:"hint",children:[c.length," lora",c.length===1?"":"s"," in the palette"]}):c.map((_,T)=>p("span",{className:`${x?"lora-chip card":"lora-chip"}${r(_)?"":" off"}`,draggable:!0,onMouseDown:(Y)=>{let bt=Y.target;Y.currentTarget.draggable=bt.closest("input, label, button, select, a")==null},onMouseUp:(Y)=>{Y.currentTarget.draggable=!0},onDragStart:(Y)=>{Y.dataTransfer.effectAllowed="move",Y.dataTransfer.setData(cf,String(T))},onDragOver:(Y)=>{if(Y.dataTransfer.types.includes(cf))Y.preventDefault()},onDrop:(Y)=>{let bt=Y.dataTransfer.getData(cf);if(bt==="")return;Y.preventDefault();let Hn=Number(bt);if(Number.isInteger(Hn)&&Hn!==T)t.v.set(Rb({record:a,displayed:c,from:Hn,to:T}))},children:[p("span",{className:"chip-media",children:[u("button",{type:"button",className:"lora-toggle","data-tip":`${_}
16
+ click for its details`,onClick:()=>n.setDetails(_),children:kr(_)}),u("button",{type:"button",className:"chip-remove","data-tip":"remove from the palette (the popup adds it back)",onClick:()=>M(_,null),children:u(D,{name:"close",size:1.05})})]}),p("span",{className:"chip-head",children:[p("label",{className:"switch","data-tip":r(_)?"pause this lora":"resume this lora",children:[u("input",{type:"checkbox",checked:r(_),onChange:(Y)=>d(_,Y.target.checked)}),u("span",{className:"track"})]}),A?u("button",{type:"button",className:"chip-title as-text","data-tip":`${_}
17
+ click for its details`,onClick:()=>n.setDetails(_),children:o(_)}):null,h(_)]}),u("span",{className:"chip-controls",children:v(_)})]},_))}),n.details==null?null:u(Fx,{name:n.details,host:t.host,hostUrl:t.hostUrl,label:o(n.details),showImage:x,keyword:(t.v.desc.optionKeywords??{})[n.details]??null,managerOnly:m.has(n.details),onClose:()=>n.setDetails(null)}),n.open?u("div",{className:"modal-overlay",onClick:()=>n.setOpen(!1),children:p("div",{className:"modal",onClick:(_)=>_.stopPropagation(),children:[p("div",{className:"modal-head",children:[u("input",{ref:Ur,type:"text",placeholder:`search ${i.length} loras${t.v.desc.optionsFilter==null?"":` matching ${t.v.desc.optionsFilter}`} — enter adds the first`,value:n.filter,onChange:(_)=>n.setFilter(_.target.value),onKeyDown:(_)=>{if(_.key!=="Enter")return;_.preventDefault(),ty()}}),gf,u("button",{type:"button","data-tip":"close (esc)",onClick:()=>n.setOpen(!1),children:u(D,{name:"close"})})]}),p("div",{className:"modal-body",children:[c.length>0?p("div",{children:[p("div",{className:"section-title",children:["your palette (",c.length,")"]}),c.filter(R).map((_)=>{let T=n.info.get(_);return p("div",{className:r(_)?"lora-active-row":"lora-active-row off",children:[kr(_),p("div",{className:"lora-active-text",children:[u("div",{className:"lora-label","data-tip":_,children:A?o(_):"···"}),typeof T==="object"&&T.triggerWords.length>0?u("div",{className:"hint",children:T.triggerWords.join(", ")}):u("div",{className:"hint",children:_})]}),u("input",{type:"checkbox",checked:r(_),"data-tip":r(_)?"pause (stays in the palette)":"resume",onChange:(Y)=>d(_,Y.target.checked)}),v(_),u("button",{type:"button",className:"chip-remove","data-tip":"remove from the list",onClick:()=>M(_,null),children:u(D,{name:"close",size:0.9})})]},_)})]}):null,u("div",{className:"section-title",children:"all loras — tap to add to the palette"}),ey.map((_)=>p("div",{children:[p("div",{className:"section-title",children:[_.folder===""?"loose (no folder)":`${_.folder}/`," · ",_.names.length]}),u("div",{className:"lora-grid",children:_.names.map((T)=>p("button",{type:"button",className:"lora-card","data-tip":T,onClick:()=>M(T,[1,1]),children:[kr(T),p("div",{className:"lora-label",children:[A?o(T):T.slice(0,2)+"···",h(T)]})]},T))})]},_.folder)),k.length-c.filter(R).length>B?p("div",{className:"loras-more",children:["… ",k.length-c.filter(R).length-B," more — refine the filter, or draw",u("input",{type:"number",min:1,max:2000,value:B,"data-tip":"how many cards this popup draws — each one is an image request, so the right number depends on your collection and your box. Kept in this browser",onChange:(_)=>{let T=parseInt(_.target.value,10);if(Number.isFinite(T))t.st.setLoraCap(T)}}),"at once"]}):null,k.length===0?p("div",{className:"loras-more",children:["no lora matches '",n.filter,"'"]}):null]})]})}):null]})}),Fx=L(function(t){let n=Vn(()=>({info:"loading",about:null,aboutError:null,set(r){this.info=r},setAbout(r){this.about=r,this.aboutError=null},setAboutError(r){this.about=null,this.aboutError=r}})),{name:a,host:i}=t;Bn.useEffect(()=>{let r=!0;return n.set("loading"),n.setAbout(null),of({host:i,name:a}).then((s)=>{if(r)n.set(s)}).catch((s)=>{if(r)n.set("error");Ln(`lora info for ${a}`,s)}),Bg({host:i,name:a}).then((s)=>{if(r)n.setAbout(s)}).catch((s)=>{if(r)n.setAboutError(s instanceof Error?s.message:String(s));Ln(`lora details for ${a}`,s)}),()=>{r=!1}},[i,a,n]),Bn.useEffect(()=>{let r=(s)=>{if(s.key==="Escape")t.onClose()};return window.addEventListener("keydown",r),()=>window.removeEventListener("keydown",r)},[t]);let l=n.info,o=(r,s)=>s==null||s===""?null:p("div",{className:"detail-row",children:[u("span",{className:"detail-key",children:r}),u("span",{className:"detail-val",children:s})]});return u("div",{className:"modal-overlay",onClick:()=>t.onClose(),children:p("div",{className:"modal",onClick:(r)=>r.stopPropagation(),children:[p("div",{className:"modal-head",children:[u("b",{style:{flex:1},children:t.label}),u("button",{type:"button","data-tip":"close (esc)",onClick:()=>t.onClose(),children:u(D,{name:"close"})})]}),p("div",{className:"modal-body",children:[l==="loading"?u("div",{className:"hint",children:"reading the mirror…"}):null,l==="error"?u("div",{className:"error",children:"\uD83D\uDD34 could not read this lora's metadata"}):null,typeof l==="object"?p("div",{className:"lora-details",children:[t.showImage?u("img",{className:"detail-thumb",src:rf({host:i,name:a}),alt:t.label}):null,p("div",{className:"detail-list",children:[l.known===!1?u("div",{className:"hint",children:"not in the lora manager mirror — run sync, or this file is unknown to it"}):null,t.managerOnly?u("div",{className:"hint",children:"⚠ only the lora manager lists it, not comfy"}):null,o("file",a),o("base model",l.baseModel),o("folder",l.folder),o("trigger words",l.triggerWords.join(", ")),o("prompt keyword",t.keyword),o("tags",(l.tags??[]).join(", ")),o("notes",l.notes),o("size",l.fileSize==null?null:`${(l.fileSize/1e9).toFixed(2)} GB`),o("path",l.filePath),n.about?.description==null?null:u("div",{className:"detail-desc",children:n.about.description}),o("civitai",l.civitaiUrl==null?null:p("a",{href:l.civitaiUrl,target:"_blank",rel:"noreferrer",children:[l.civitaiVersion??"model page"," ↗"]})),n.about!=null&&n.about.examples.length>0?p("div",{children:[p("div",{className:"section-title",children:["examples (",n.about.examples.length,")"]}),u("div",{className:"detail-examples",children:n.about.examples.slice(0,8).map((r)=>u("img",{src:r,alt:"",loading:"lazy"},r))})]}):null,n.about?.examplesReason==null?null:p("div",{className:"hint",children:["no example images: ",n.about.examplesReason]}),n.aboutError==null?null:p("div",{className:"error",children:["\uD83D\uDD34 the lora manager did not answer: ",n.aboutError]}),t.hostUrl==null?null:p("a",{className:"button-link",href:`${t.hostUrl}/loras`,target:"_blank",rel:"noreferrer",children:[u(D,{name:"external"})," open in the lora manager"]})]})]}):null]})]})})});var ff=[{mode:"=",hint:"fixed: this exact seed, every run"},{mode:"+",hint:"increments after each run"},{mode:"?",hint:"a fresh random seed each run"}];function Wx(e){if(ff.some((t)=>t.mode===e))return ff;return[...ff,{mode:e,hint:e==="-"?"decrements after each run":`mode '${e}'`}]}var Ub=L(function(t){let n=Ul(t.v.value),a=(i)=>{if(Number.isFinite(i))t.v.set({mode:n.mode,value:Math.max(0,Math.floor(i))})};return u("div",{children:p("div",{className:"row-inline",children:[u("span",{className:"btn-group field-height",children:Wx(n.mode).map((i)=>u("button",{type:"button",className:n.mode===i.mode?"sel":"","data-tip":i.hint,onClick:()=>t.v.set({mode:i.mode,value:n.value}),children:i.mode},i.mode))}),u("input",{type:"number",min:0,value:n.value,onChange:(i)=>a(parseInt(i.target.value,10))}),u("button",{type:"button",className:"field-height","data-tip":"roll a random seed now",onClick:()=>a(Tb()),children:u(D,{name:"dice"})})]})})});var kb=L(function(t){let n=uf(t.v.value),a=t.v.desc.presets??[],i=a.find((o)=>o.width===n.width&&o.height===n.height),l=(o)=>{let r=o.width??n.width,s=o.height??n.height;if(Number.isFinite(r)&&Number.isFinite(s)&&r>0&&s>0)t.v.set({width:Math.floor(r),height:Math.floor(s)})};return p("div",{className:"row-inline",children:[p("select",{value:i?.label??"__custom__",onChange:(o)=>{let r=a.find((s)=>s.label===o.target.value);if(r!=null)t.v.set({width:r.width,height:r.height})},children:[i==null?u("option",{value:"__custom__",children:"custom"}):null,a.map((o)=>p("option",{value:o.label,children:[o.label," (",o.width,"×",o.height,")"]},o.label))]}),u("input",{type:"number",min:1,value:n.width,onChange:(o)=>l({width:Number(o.target.value)})}),"×",u("input",{type:"number",min:1,value:n.height,onChange:(o)=>l({height:Number(o.target.value)})}),u("button",{type:"button","data-tip":"swap width and height",onClick:()=>t.v.set({width:n.height,height:n.width}),children:u(D,{name:"swap"})})]})});class Vb{name;desc;initial;value;dirty=!1;uploadedUrl=null;constructor(e,t,n){this.name=e;this.desc=t;this.initial=n;this.value=n,en(this,{value:hi,name:!1,desc:!1})}set(e){this.value=e,this.dirty=!0}setFromRun(e){this.value=e,this.initial=e,this.dirty=!1}setUploadedUrl(e){this.uploadedUrl=e}revert(){this.value=this.initial,this.dirty=!1,this.uploadedUrl=null}snapshot(){return{name:this.name,value:this.value}}}class df{moduleKey;draft;vars;host;saveState="saved";saveError=null;disposers=[];saveChain=Promise.resolve(!0);lastSaved;lastQueued;queueSeq=0;constructor(e,t,n,a){this.moduleKey=e;this.draft=t;this.host=n.host,this.vars=Object.entries(n.vars).map(([i,l])=>new Vb(i,l,Ab(l,a[i]))),this.lastSaved=JSON.stringify(Object.fromEntries(this.vars.map((i)=>[i.name,a[i.name]]))),this.lastQueued=this.lastSaved,en(this,{vars:!1,moduleKey:!1,draft:!1,host:!1,disposers:!1,saveChain:!1,lastSaved:!1,lastQueued:!1,queueSeq:!1}),this.disposers.push(Or(()=>JSON.stringify(this.valuesJSON()),()=>void this.save(),{delay:500}))}dispose(e={}){for(let t of this.disposers)t();if(this.disposers=[],e.flush===!1)return;if(JSON.stringify(this.valuesJSON())!==this.lastQueued)this.save()}flushKeepalive(){let e=JSON.stringify(this.valuesJSON());if(e===this.lastQueued)return;this.lastQueued=e,Ml({module:this.moduleKey,draft:this.draft,values:JSON.parse(e)},{keepalive:!0}).then(()=>E(()=>{this.lastSaved=e,this.lastQueued=e,this.saveState="saved"}),(t)=>E(()=>{if(this.lastQueued===e)this.lastQueued=this.lastSaved;this.saveState="error",this.saveError=t instanceof Error?t.message:String(t)}))}valuesJSON(){return Object.fromEntries(this.vars.map((e)=>[e.name,e.value]))}queuePayload(){return Ob(this.vars.map((e)=>({name:e.name,kind:e.desc.kind,value:e.value})))}loraKeywordsFor(e){let t=e.desc.keywordsFrom;if(t==null)return[];let n=this.vars.find((o)=>o.name===t);if(n==null)return[];let a=n.desc.optionKeywords??{},i=n.value!=null&&typeof n.value==="object"?n.value:{},l=[];for(let o of n.desc.options??[]){let r=i[o];if(r==null||r===!1)continue;let s=a[o];if(s!=null&&s!==""&&!l.includes(s))l.push(s)}return l}get dirtyCount(){return this.vars.filter((e)=>e.dirty).length}save(){let e=JSON.stringify(this.valuesJSON());if(e===this.lastQueued)return this.lastSaved===e?Promise.resolve(!0):this.saveChain;this.lastQueued=e;let t=++this.queueSeq;return E(()=>{this.saveState="saving"}),this.saveChain=this.saveChain.then(async()=>{try{return await Ml({module:this.moduleKey,draft:this.draft,values:JSON.parse(e)}),E(()=>{this.lastSaved=e,this.saveState="saved",this.saveError=null}),!0}catch(n){return E(()=>{if(this.queueSeq===t)this.lastQueued=this.lastSaved;this.saveChain=Promise.resolve(!0),this.saveState="error",this.saveError=n instanceof Error?n.message:String(n)}),!1}}),this.saveChain}revertAll(){for(let e of this.vars)e.revert()}}function Lb(e){try{let t=new URLSearchParams(e.startsWith("?")?e.slice(1):e),n=t.get("workflow"),a=t.get("draft");return{module:n===""?null:n,draft:a===""?null:a}}catch{return{module:null,draft:null}}}function Bb(e){let t=new URLSearchParams(e.search.startsWith("?")?e.search.slice(1):e.search);t.set("workflow",e.module),t.set("draft",e.draft);let n=t.toString();return n===""?"":`?${n}`}function Hb(e){let t=(l)=>l==null?null:e.modules.find((o)=>o.module===l)??null,n=t(e.url.module)??t(e.stored.module)??e.modules[0];if(n==null)return null;let a=e.url.module!=null&&e.url.module===n.module?e.url.draft:e.stored.draft,i=a!=null&&n.drafts.includes(a)?a:"default";return{module:n.module,draft:i}}function Ix(e){return new Promise((t)=>setTimeout(t,e))}class hf{queue=[];error=null;results=[];progressPercent=null;progressNode=null;progressCount=null;progressText=null;hasPreview=!1;previewTick=0;draining=!1;nextId=0;pollGen=0;onSeeds=null;constructor(){en(this,{queue:Dl,results:Dl})}get isRunning(){return this.queue.some((e)=>e.sent)}get runningModule(){return this.queue.find((e)=>e.sent)?.module??null}get pendingCount(){return this.queue.filter((e)=>!e.sent).length}enqueue(e){if(this.queue=[...this.queue,{id:`q${this.nextId++}`,...e,sent:!1}],this.error=null,!this.draining)this.drain()}removeQueued(e){this.queue=this.queue.filter((t)=>t.id!==e||t.sent)}clearQueue(){this.queue=this.queue.filter((e)=>e.sent)}remove(e){this.results=this.results.filter((t)=>t.promptId!==e)}clear(){this.results=[]}async drain(){if(this.draining)return;this.draining=!0;try{while(!0){let e=this.queue.find((n)=>!n.sent);if(e==null)return;E(()=>{this.queue=this.queue.map((n)=>n.id===e.id?{...n,sent:!0}:n),this.progressPercent=null,this.progressNode=null,this.progressCount=null,this.progressText=null,this.hasPreview=!1});let t=++this.pollGen;this.poll(e.module,t);try{let n=await Vg(e);E(()=>{this.results=[{...n,at:new Date().toLocaleTimeString()},...this.results].slice(0,20)}),this.onSeeds?.({module:e.module,draft:e.draft,seeds:n.seeds})}catch(n){E(()=>{this.error=n instanceof Error?n.message:String(n),this.queue=this.queue.filter((a)=>a.sent&&a.id!==e.id)})}finally{this.pollGen++,E(()=>{this.queue=this.queue.filter((n)=>n.id!==e.id),this.progressPercent=null,this.progressNode=null,this.progressCount=null,this.progressText=null,this.hasPreview=!1})}}}finally{this.draining=!1}}async poll(e,t){while(t===this.pollGen){if(await Ix(700),t!==this.pollGen)return;try{let n=await Lg({module:e});E(()=>{if(t!==this.pollGen)return;this.progressPercent=n.percent,this.progressNode=n.node??null,this.progressCount=n.nodeProgress??null,this.progressText=n.progressText??null,this.hasPreview=n.hasPreview,this.previewTick=n.previewSeq??0})}catch{}}}}var Gb="comfy-ts-serve-ui",Px="side",Yb=[{id:"off",icon:"panel-off",title:"no preview: the form only"},{id:"bottom",icon:"panel-bottom",title:"results below the form"},{id:"left",icon:"panel-left",title:"results left of the form"},{id:"side",icon:"panel-side",title:"results right of the form"},{id:"pinned",icon:"panel-corner",title:"newest image in the bottom right corner, form scrolls under it"}];function eE(e){return e==="off"||e==="bottom"||e==="left"||e==="side"||e==="pinned"}var Kb=200,tE=60;function jb(e){let t=typeof e==="number"&&Number.isFinite(e)?Math.floor(e):Kb;return Math.min(2000,Math.max(1,t))}function nE(e){if(e==null||typeof e!=="object"||Array.isArray(e))return{};let t={};for(let[n,a]of Object.entries(e))if(Array.isArray(a))t[n]=a.filter((i)=>typeof i==="string");return t}function pf(){try{let e=JSON.parse(localStorage.getItem(Gb)??"{}")??{};return{...e,varOrder:nE(e.varOrder)}}catch{return{}}}function qb(){return window.matchMedia("(max-width: 800px)").matches}class mf{phase="loading";bootError="";modules=[];loadErrors={};form=null;formLoading=!1;formError=null;sidebarOpen;showLoraImages;showLoraTitles;loraFill;loraCap;run;enhancer;settings={saveToDisk:!0,hostOverride:{},savePrefix:{},effectivePrefix:{}};savingError=null;prefixEdits={};prefixTimers=new Map;get saveToDisk(){return this.settings.saveToDisk}layout;varOrder={};orderedVars(e,t){let n=this.varOrder[e];if(n==null)return[...t];let a=new Set(t),i=n.filter((l)=>a.has(l));return[...i,...t.filter((l)=>!i.includes(l))]}moveVar(e){let t=this.orderedVars(e.module,e.names),[n]=t.splice(e.from,1);if(n==null)return;t.splice(e.to,0,n),this.varOrder={...this.varOrder,[e.module]:t},this.persist()}hosts={hosts:[],defaults:{},overrides:{}};hostError=null;constructor(){this.run=new hf,this.run.onSeeds=(t)=>this.applyRunSeeds(t),this.enhancer=new sf;let e=pf();this.layout=eE(e.layout)?e.layout:Px,this.sidebarOpen=e.sidebar??!1,this.showLoraImages=e.loraImages??!0,this.showLoraTitles=e.loraTitles??!0,this.loraFill=e.loraFill??!0,this.loraCap=jb(e.loraCapMigrated!==!0&&e.loraCap===tE?Kb:e.loraCap),this.showLatent=e.latent??!0,this.varOrder=e.varOrder??{},this.showLogs=e.logs??!1,en(this,{run:!1,enhancer:!1,form:hi,modules:Dl}),window.addEventListener("beforeunload",()=>this.form?.flushKeepalive()),document.addEventListener("visibilitychange",()=>{if(document.visibilityState==="hidden")this.form?.save()}),this.boot()}toggleSidebar(){this.sidebarOpen=!this.sidebarOpen,this.persist()}toggleLoraImages(){this.showLoraImages=!this.showLoraImages,this.persist()}toggleLoraTitles(){this.showLoraTitles=!this.showLoraTitles,this.persist()}toggleLoraFill(){this.loraFill=!this.loraFill,this.persist()}setLoraCap(e){this.loraCap=jb(e),this.persist()}applyRunSeeds(e){let t=this.form;if(t==null||t.moduleKey!==e.module||t.draft!==e.draft)return;E(()=>{for(let n of t.vars){if(n.desc.kind!=="seed")continue;let a=e.seeds[n.name];if(typeof a!=="number"||!Number.isFinite(a))continue;let i=Ul(n.value);if(i.value===a)continue;n.setFromRun({mode:i.mode,value:a})}})}syncUrl(){let e=this.form;if(e==null)return;try{let t=Bb({search:window.location.search,module:e.moduleKey,draft:e.draft});window.history.replaceState(null,"",`${window.location.pathname}${t}${window.location.hash}`)}catch(t){Ln("could not put the selection in the url",t)}}persist(){try{let e=pf();localStorage.setItem(Gb,JSON.stringify({...e,...this.form!=null?{module:this.form.moduleKey,draft:this.form.draft}:{},sidebar:this.sidebarOpen,loraImages:this.showLoraImages,loraTitles:this.showLoraTitles,loraFill:this.loraFill,loraCap:this.loraCap,loraCapMigrated:!0,layout:this.layout,latent:this.showLatent,logs:this.showLogs,varOrder:this.varOrder}))}catch(e){Ln("ui state could not be stored (it will not survive a reload)",e)}}moduleByKey(e){return this.modules.find((t)=>t.module===e)??null}async boot(){try{let e=await af();E(()=>{this.modules=e.workflows,this.loadErrors=e.loadErrors??{},this.phase="ready"}),this.loadSettings(),this.loadHosts();let t=pf(),n=Hb({url:Lb(window.location.search),stored:{module:t.module??null,draft:t.draft??null},modules:this.modules});if(n==null)return;await this.select(n)}catch(e){E(()=>{this.phase="error",this.bootError=e instanceof Error?e.message:String(e)})}}selectToken=0;async select(e){let t=this.moduleByKey(e.module);if(t==null)return;if(this.form?.moduleKey===e.module&&this.form.draft===e.draft){E(()=>{if(qb())this.sidebarOpen=!1});return}let n=++this.selectToken;E(()=>{if(this.enhancer.close(),this.formLoading=!0,this.formError=null,qb())this.sidebarOpen=!1});let a=this.form;if(a!=null){if(a.dispose(),E(()=>{this.form=null}),!await a.save())E(()=>{this.formError=`the previous draft could not be saved: ${a.saveError??"unknown error"}`})}try{let i=await kg(e);E(()=>{if(n!==this.selectToken)return;this.form=new df(e.module,e.draft,t,i.values??{}),this.persist(),this.syncUrl()})}catch(i){E(()=>{if(n!==this.selectToken)return;this.form=null,this.formError=i instanceof Error?i.message:String(i)})}finally{E(()=>{if(n===this.selectToken)this.formLoading=!1})}}get generateInResults(){return this.layout==="side"||this.layout==="left"||this.layout==="pinned"}setLayout(e){this.layout=e,this.persist()}hostFor(e){return this.hosts.overrides[e]??this.hosts.defaults[e]??""}hostUrlFor(e){let t=this.hostFor(e);return this.hosts.hosts.find((n)=>n.id===t)?.httpUrl??null}isHostOverridden(e){return this.hosts.overrides[e]!=null}async loadHosts(){try{let e=await qg();E(()=>{this.hosts=e})}catch(e){Ln("could not read the host list",e)}}showLogs=!1;logLines=[];logsError=null;hostNote=null;showLatent=!0;logsTimer=null;toggleLatent(){this.showLatent=!this.showLatent,this.persist()}toggleLogs(){if(this.showLogs=!this.showLogs,this.persist(),this.logsTimer!=null)clearInterval(this.logsTimer);if(this.logsTimer=null,!this.showLogs)return;this.pullLogs(),this.logsTimer=setInterval(()=>void this.pullLogs(),3000)}async pullLogs(){let e=this.form==null?null:this.hostFor(this.form.moduleKey);if(e==null||e==="")return;try{let t=await Kg({host:e});E(()=>{this.logLines=t.lines,this.logsError=null})}catch(t){E(()=>{this.logsError=t instanceof Error?t.message:String(t)})}}loraSyncing=!1;async refreshLoras(){if(this.loraSyncing)return;E(()=>{this.loraSyncing=!0}),await this.hostAction("refresh-loras");try{let e=await af(),t=this.form;if(E(()=>{this.modules=e.workflows}),t!=null)t.dispose(),await t.save(),E(()=>{this.form=null}),await this.select({module:t.moduleKey,draft:t.draft})}catch(e){E(()=>{this.hostError=e instanceof Error?e.message:String(e)})}finally{E(()=>{this.loraSyncing=!1})}}hostWatch="idle";async watchHostComeBack(){let e=this.form==null?null:this.hostFor(this.form.moduleKey);if(e==null||e==="")return;E(()=>{this.hostWatch="down"});let t=Date.now()+120000;for(;;){if(await new Promise((a)=>setTimeout(a,2500)),Date.now()>t){E(()=>{this.hostWatch="idle",this.hostError=`${e} has not answered for 2 minutes — check the console`});return}if(!await Gg({host:e}).then((a)=>a.up).catch(()=>!1))continue;E(()=>{this.hostWatch="back",this.hostNote=`${e} is back up`}),setTimeout(()=>E(()=>this.hostWatch="idle"),4000);return}}async hostAction(e){let t=this.form==null?null:this.hostFor(this.form.moduleKey);if(t==null||t==="")return;E(()=>{this.hostError=null,this.hostNote=null});try{let n=await Yg({host:t,action:e});if(E(()=>{this.hostNote=n.note}),e==="restart")this.watchHostComeBack()}catch(n){E(()=>{this.hostError=n instanceof Error?n.message:String(n)})}}async setModuleHost(e){E(()=>{this.hostError=null});try{let t=await Xg(e);E(()=>{this.hosts={...this.hosts,overrides:t.overrides}})}catch(t){E(()=>{this.hostError=t instanceof Error?t.message:String(t)})}}async loadSettings(){try{let e=await Hg();E(()=>{this.settings=e})}catch(e){Ln("could not read the serve settings",e)}}savePrefixDraft(e){return this.prefixEdits[e]??this.settings.savePrefix[e]??""}setSavePrefix(e,t){this.prefixEdits[e]=t,this.savingError=null;let n=this.prefixTimers.get(e);if(n!=null)clearTimeout(n);this.prefixTimers.set(e,setTimeout(()=>{this.pushSettings({savePrefix:{[e]:t}})},500))}async pushSettings(e){try{let t=await jg(e);return E(()=>{this.settings=t,this.savingError=null}),!0}catch(t){return E(()=>{this.savingError=t instanceof Error?t.message:String(t)}),!1}}async toggleSaveToDisk(){let e=!this.saveToDisk,t=this.settings;if(E(()=>{this.settings={...this.settings,saveToDisk:e},this.savingError=null}),!await this.pushSettings({saveToDisk:e}))E(()=>{this.settings=t})}generate(){this.generateNow()}async generateNow(){let e=this.form;if(e==null)return;let t=e.queuePayload();if(!await e.save())return;this.run.enqueue({module:e.moduleKey,draft:e.draft,payload:t})}async renameDraft(e){let t=this.form,n=e.trim();if(t==null||n===""||n===t.draft)return;let a=t.draft;if(await this.duplicateDraft(n),this.form?.draft!==n)return;await lf({module:t.moduleKey,draft:a}).then((i)=>E(()=>{this.modules=this.modules.map((l)=>l.module===t.moduleKey?{...l,drafts:i.drafts}:l)}),(i)=>E(()=>{this.formError=`renamed to '${n}', but the old draft '${a}' could not be removed: ${i instanceof Error?i.message:String(i)}`}))}async deleteDraft(e){let t=this.form;if(t!=null&&t.moduleKey===e.module&&t.draft===e.draft)t.dispose({flush:!1}),E(()=>{this.form=null});try{let n=await lf(e);E(()=>{this.modules=this.modules.map((i)=>i.module===e.module?{...i,drafts:n.drafts}:i)});let a=n.drafts.includes("default")?"default":n.drafts[0]??"default";await this.select({module:e.module,draft:a})}catch(n){E(()=>{this.formError=n instanceof Error?n.message:String(n)})}}async duplicateDraft(e){let t=this.form,n=e.trim();if(t==null||n==="")return;if(this.moduleByKey(t.moduleKey)?.drafts.includes(n)===!0&&!window.confirm(`draft '${n}' already exists — overwrite it?`))return;try{let i=await Ml({module:t.moduleKey,draft:n,values:t.valuesJSON()});E(()=>{this.modules=this.modules.map((l)=>l.module===t.moduleKey?{...l,drafts:i.drafts}:l)}),await this.select({module:t.moduleKey,draft:n})}catch(i){E(()=>{this.formError=i instanceof Error?i.message:String(i)})}}}var aE=L(function(t){switch(t.v.desc.kind){case"prompt":return u(yb,{v:t.v,st:t.st,module:t.module});case"text":return u(_b,{v:t.v});case"int":case"float":return u(Sb,{v:t.v});case"seed":return u(Ub,{v:t.v});case"toggle":return u(xb,{v:t.v});case"choice":return u(Eb,{v:t.v});case"loras":return u(Cb,{v:t.v,host:t.st.hostFor(t.module),st:t.st,hostUrl:t.st.hostUrlFor(t.module)});case"size":return u(kb,{v:t.v});case"image":return u(Nb,{v:t.v});default:return p("div",{className:"hint",children:["unsupported var kind '",t.v.desc.kind,"' — use the json api"]})}}),iE=L(function(t){return p("div",{className:t.v.desc.kind==="loras"||t.v.desc.kind==="prompt"?"var-row wide":"var-row",onDragOver:(n)=>{if(n.dataTransfer.types.includes("application/x-comfy-var"))n.preventDefault()},onDrop:(n)=>{let a=n.dataTransfer.getData("application/x-comfy-var");if(a==="")return;n.preventDefault();let i=Number(a);if(Number.isInteger(i)&&i!==t.index)t.st.moveVar({module:t.module,names:t.names,from:i,to:t.index})},children:[p("div",{className:"var-label",draggable:!0,onDragStart:(n)=>{n.dataTransfer.effectAllowed="move",n.dataTransfer.setData("application/x-comfy-var",String(t.index))},children:[u("span",{"data-tip":`${t.v.desc.kind}
18
+ drag the label to reorder`,children:t.v.desc.label??t.v.name}),t.v.dirty?u("button",{type:"button",className:"dirty-dot","data-tip":"changed this session — click to restore the loaded value (autosaves)",onClick:()=>t.v.revert(),children:"●"}):null]}),u("div",{className:"var-control",children:u(aE,{v:t.v,host:t.host,st:t.st,module:t.module})})]})}),lE=L(function(t){let n=Vn(()=>({mode:null,name:"",start(l,o){this.mode=l,this.name=l==="duplicate"?`${o} copy`:o},set(l){this.name=l},stop(){this.mode=null}})),a=t.st.moduleByKey(t.form.moduleKey)?.drafts??[t.form.draft],i=()=>{let l=n.name.trim(),o=n.mode;if(n.stop(),l===""||o==null)return;if(o==="duplicate")t.st.duplicateDraft(l);else t.st.renameDraft(l)};return p("div",{className:"head-box",children:[p("span",{className:"head-label",children:["draft",p("span",{className:t.form.saveState==="error"?"save-state error":"save-state",children:[t.form.saveState==="saving"?"· saving":null,t.form.saveState==="saved"?"· saved":null,t.form.saveState==="error"?"· NOT SAVED":null]})]}),n.mode!=null?u("input",{type:"text",autoFocus:!0,className:"head-input",value:n.name,placeholder:n.mode==="rename"?"new name, then enter":"new draft name, then enter",onFocus:(l)=>l.currentTarget.select(),onChange:(l)=>n.set(l.target.value),onKeyDown:(l)=>{if(l.key==="Enter")i();if(l.key==="Escape")n.stop()},onBlur:()=>n.stop()}):u("select",{className:"head-select draft",value:t.form.draft,"data-tip":"switch draft",onChange:(l)=>void t.st.select({module:t.form.moduleKey,draft:l.target.value}),children:a.map((l)=>u("option",{value:l,children:l},l))}),p("span",{className:"head-line",children:[p("span",{className:"btn-group head-group",children:[u("button",{type:"button","data-tip":"rename this draft (the file is renamed)",onClick:()=>n.mode!=null?i():n.start("rename",t.form.draft),children:u(D,{name:"pen"})}),u("button",{type:"button","data-tip":"save these values as a new draft",onClick:()=>n.mode!=null?i():n.start("duplicate",t.form.draft),children:u(D,{name:"copy-plus"})}),u("button",{type:"button",className:"danger","data-tip":"delete this draft's file (default resets to the workflow's own values)",onClick:()=>{if(window.confirm(`delete draft '${t.form.draft}' of ${t.form.moduleKey}? the file is removed.`))t.st.deleteDraft({module:t.form.moduleKey,draft:t.form.draft})},children:u(D,{name:"trash"})})]}),t.form.dirtyCount>0?u("button",{type:"button",className:"dirty head-right","data-tip":`${t.form.dirtyCount} var${t.form.dirtyCount>1?"s":""} changed this session — revert to the values this draft loaded with`,onClick:()=>t.form.revertAll(),children:u(D,{name:"broom"})}):null]})]})}),vf=L(function(t){let n=t.st.run;return p("span",{className:"run-line",children:[p("button",{type:"button",className:n.isRunning?"primary pulse":"primary","data-tip":"⌘⏎ / ctrl+⏎ — click again to queue another",onClick:()=>t.st.generate(),children:[u(D,{name:"play",size:0.85})," ",n.isRunning?n.progressPercent!=null?`generating… ${Math.round(n.progressPercent)}%`:"generating…":"generate",n.isRunning?null:u("span",{className:"kbd-hint",children:"⌘⏎"})]}),n.queue.length>0?p("span",{className:"run-chip","data-tip":"prompts waiting behind this one",children:["queue: ",n.queue.length,n.pendingCount>0?u("button",{type:"button",className:"link","data-tip":`drop the ${n.pendingCount} not yet sent to the host`,onClick:()=>n.clearQueue(),children:"clear"}):null]}):null,n.results.length>0?p("span",{className:"run-chip","data-tip":"runs kept in this page",children:[n.results.length," result",n.results.length===1?"":"s",u("button",{type:"button",className:"link","data-tip":"forget every run shown here",onClick:()=>n.clear(),children:"clear"})]}):null]})}),oE=L(function(t){let n=t.st.saveToDisk;return p("div",{className:"var-row",children:[u("div",{className:"var-label",children:u("span",{"data-tip":"save — where this workflow's images go",children:"output"})}),p("div",{className:"var-control",children:[p("div",{className:"row-inline",children:[p("label",{className:"row-inline",style:{cursor:"pointer"},children:[u("input",{type:"checkbox",checked:n,onChange:()=>void t.st.toggleSaveToDisk()}),p("span",{className:"hint",children:[u(D,{name:n?"save":"ghost",size:1})," ",n?"write to disk":"memory only"]})]}),n?p(he,{children:[u("span",{className:"hint",children:".comfy-ts/outputs/"}),u("input",{type:"text",style:{flex:1,minWidth:120},placeholder:t.module,value:t.st.savePrefixDraft(t.module),"data-tip":"subfolder the images land in — folder names only, a/b allowed",onChange:(a)=>t.st.setSavePrefix(t.module,a.target.value)}),u("span",{className:"hint",children:"/…png"})]}):u("span",{className:"hint",children:"kept in memory and shown here, lost when the server restarts"})]}),t.st.savingError!=null?p("div",{className:"error",children:["\uD83D\uDD34 ",t.st.savingError]}):null]})]})}),Qb=L(function(t){let n=t.st.form;if(Xb.useEffect(()=>{let l=(o)=>{if(t.st.enhancer.isOpen)return;if(o.key==="Enter"&&(o.metaKey||o.ctrlKey))o.preventDefault(),t.st.generate()};return window.addEventListener("keydown",l),()=>window.removeEventListener("keydown",l)},[t.st]),n==null)return null;let a=t.st.orderedVars(n.moduleKey,n.vars.map((l)=>l.name)),i=a.map((l)=>n.vars.find((o)=>o.name===l)).filter((l)=>l!=null);return p("div",{children:[u("div",{className:"head-shell",children:p("div",{className:"head-boxes",children:[p("div",{className:"head-box",children:[u("span",{className:"head-label",children:"workflow"}),u("div",{className:"head-line",children:u("button",{type:"button",className:"head-value app as-link","data-tip":t.st.sidebarOpen?"close the workflow menu":"browse every workflow",onClick:()=>t.st.toggleSidebar(),children:n.moduleKey})}),p("div",{className:"head-line",children:[u("span",{className:"btn-group",children:u("button",{type:"button","data-tip":t.st.sidebarOpen?"close the workflow menu":"browse every workflow",onClick:()=>t.st.toggleSidebar(),children:u(D,{name:"folder"})})}),p("span",{className:"hint",children:[n.vars.length," vars"]})]})]}),u(lE,{st:t.st,form:n}),p("div",{className:"head-box",children:[u("span",{className:"head-label",children:"host"}),u("div",{className:"head-line",children:t.st.hosts.hosts.length>1?u("select",{className:"head-select",value:t.st.hostFor(n.moduleKey),"data-tip":"run this workflow on another host",onChange:(l)=>void t.st.setModuleHost({module:n.moduleKey,host:l.target.value}),children:t.st.hosts.hosts.map((l)=>u("option",{value:l.id,children:l.id===(t.st.hosts.defaults[n.moduleKey]??"")?`${l.id} (its own)`:l.id},l.id))}):u("span",{className:"head-value host",children:t.st.hostFor(n.moduleKey)||n.host})}),p("div",{className:"head-line",children:[p("span",{className:"btn-group",children:[u("button",{type:"button","data-tip":"interrupt the prompt running now",onClick:()=>void t.st.hostAction("interrupt"),children:u(D,{name:"pause"})}),u("button",{type:"button","data-tip":"drop everything still pending in the host queue",onClick:()=>void t.st.hostAction("clear-queue"),children:u(D,{name:"trash"})}),u("button",{type:"button","data-tip":"refetch object_info from the host and rewrite sdk.d.ts (the var lists widen in place)",onClick:()=>void t.st.hostAction("refresh-schema"),children:u(D,{name:"refresh"})}),u("button",{type:"button",className:"danger","data-tip":"restart ComfyUI on that host (manager reboot) — it reconnects when back",onClick:()=>{if(window.confirm(`restart ComfyUI on '${t.st.hostFor(n.moduleKey)}'?`))t.st.hostAction("restart")},children:u(D,{name:"power"})})]}),t.st.isHostOverridden(n.moduleKey)?p("button",{type:"button",className:"link","data-tip":`runs on an override — back to ${t.st.hosts.defaults[n.moduleKey]??"its own host"}`,onClick:()=>void t.st.setModuleHost({module:n.moduleKey,host:null}),children:[u(D,{name:"swap"})," reset"]}):null]})]}),p("div",{className:"head-box",children:[u("span",{className:"head-label",children:"preview"}),u("div",{className:"head-line",children:u("span",{className:"btn-group",children:Yb.map((l)=>u("button",{type:"button",className:t.st.layout===l.id?"sel":"","data-tip":l.title,onClick:()=>t.st.setLayout(l.id),children:u(D,{name:l.icon})},l.id))})}),u("div",{className:"head-line",children:p("span",{className:"btn-group",children:[u("button",{type:"button",className:t.st.showLatent?"sel":"","data-tip":t.st.showLatent?"hide the latent preview during a run":"show the latent preview",onClick:()=>t.st.toggleLatent(),children:u(D,{name:"image"})}),u("button",{type:"button",className:t.st.showLogs?"sel":"","data-tip":t.st.showLogs?"hide the ComfyUI console":"show the ComfyUI console",onClick:()=>t.st.toggleLogs(),children:u(D,{name:"terminal"})})]})})]})]})}),t.st.hostError!=null?p("div",{className:"error",children:["\uD83D\uDD34 ",t.st.hostError]}):null,t.st.hostWatch==="down"?u("div",{className:"host-note pulse",children:"restarting… waiting for the host to answer again"}):null,t.st.hostNote!=null&&t.st.hostWatch!=="down"?u("div",{className:"host-note",children:t.st.hostNote}):null,n.saveState==="error"?p("div",{className:"error",children:["\uD83D\uDD34 draft save failed: ",n.saveError]}):null,p("div",{className:"vars",children:[i.map((l,o)=>u(iE,{v:l,host:n.host,st:t.st,module:n.moduleKey,index:o,names:a},`${n.moduleKey}/${n.draft}/${l.name}`)),u(oE,{st:t.st,module:n.moduleKey})]}),t.st.generateInResults&&t.st.run.error==null?null:p("div",{className:"runbar",children:[t.st.generateInResults?null:u(vf,{st:t.st}),t.st.run.error!=null?p("span",{className:"error",children:["\uD83D\uDD34 ",t.st.run.error]}):null]})]})});function rE(){Zb.useEffect(()=>{let e=(t)=>{if(t.key!=="a"&&t.key!=="A")return;if(!t.metaKey&&!t.ctrlKey)return;if(t.altKey)return;let n=document.activeElement;if(!(n instanceof HTMLInputElement?n.type==="text"||n.type==="search"||n.type==="password"||n.type==="url":n instanceof HTMLTextAreaElement))return;t.preventDefault(),n.select()};return window.addEventListener("keydown",e),()=>window.removeEventListener("keydown",e)},[])}var $b=L(function(t){if(rE(),t.st.phase==="loading")return u("div",{className:"center",children:"loading…"});if(t.st.phase==="error")return u("div",{className:"center",children:p("div",{className:"error",children:["\uD83D\uDD34 ",t.st.bootError]})});return u("div",{className:"app",children:p("div",{className:"cols",children:[t.st.sidebarOpen?u("div",{className:"backdrop",onClick:()=>t.st.toggleSidebar()}):null,t.st.sidebarOpen?u(nb,{st:t.st}):null,p("div",{className:"main",children:[t.st.formError!=null?p("div",{className:"center error",children:["\uD83D\uDD34 ",t.st.formError]}):null,t.st.formLoading&&t.st.form==null?u("div",{className:"center",children:"loading draft…"}):null,t.st.modules.length===0?u("div",{className:"center",children:"no workflow modules loaded"}):null,p("div",{className:`work layout-${t.st.layout}`,children:[p("div",{className:"form-col",children:[u(Qb,{st:t.st}),t.st.showLogs?p("div",{className:"logs",children:[p("div",{className:"logs-head",children:[p("span",{children:["console · ",t.st.hostFor(t.st.form?.moduleKey??"")||"host"]}),u("button",{type:"button",className:"link",onClick:()=>t.st.toggleLogs(),children:"hide"})]}),t.st.logsError!=null?p("div",{className:"error",children:["\uD83D\uDD34 ",t.st.logsError]}):null,u("pre",{children:t.st.logLines.join(`
19
+ `)})]}):null]}),t.st.layout==="off"?null:p("div",{className:"results-col",children:[t.st.generateInResults?p("div",{className:"results-run",children:[u(vf,{st:t.st}),t.st.run.error!=null?p("span",{className:"error",children:["\uD83D\uDD34 ",t.st.run.error]}):null]}):null,u(eb,{st:t.st,compact:t.st.layout==="pinned"})]})]})]})]})})});var Jb=`
25
20
  :root {
26
21
  --bg: #101217;
27
22
  --panel: #171a21;
@@ -44,20 +39,21 @@ body {
44
39
  }
45
40
  #root { height: 100%; }
46
41
  .app { display: flex; flex-direction: column; height: 100%; }
47
- .topbar {
48
- display: flex; align-items: baseline; gap: 12px;
49
- padding: 10px 16px; border-bottom: 1px solid var(--border); background: var(--panel);
50
- }
51
- .topbar h1 { font-size: 15px; margin: 0; font-weight: 600; }
52
- .topbar .dim { color: var(--dim); font-size: 12px; }
53
- .burger { font-size: 16px; padding: 3px 10px; align-self: center; }
54
42
  .cols { display: flex; flex: 1; min-height: 0; position: relative; }
55
43
  .backdrop { display: none; }
56
44
 
57
45
  .sidebar {
58
46
  width: 240px; flex-shrink: 0; overflow-y: auto;
59
- border-right: 1px solid var(--border); background: var(--panel); padding: 8px 0;
47
+ border-right: 1px solid var(--border); background: var(--panel); padding: 6px 0;
48
+ }
49
+ /* the way OUT, from inside: the drawer opens from the workflow head box, which nothing
50
+ advertises, so a visible close is what teaches where it lives */
51
+ .side-head {
52
+ display: flex; align-items: center; justify-content: space-between; gap: 8px;
53
+ padding: 2px 8px 8px 12px; margin-bottom: 4px; border-bottom: 1px solid var(--border);
54
+ color: var(--dim); font-size: 11px; letter-spacing: 0.06em; text-transform: uppercase;
60
55
  }
56
+ .side-head button { padding: 2px 6px; }
61
57
  .side-module { padding: 6px 12px 2px; }
62
58
  .side-module .name { font-weight: 600; }
63
59
  .side-module .host { color: var(--dim); font-size: 11px; margin-left: 6px; }
@@ -71,25 +67,88 @@ body {
71
67
  .side-errors .file { color: var(--dim); word-break: break-all; }
72
68
  .side-errors .msg { color: var(--red); }
73
69
 
74
- .main { flex: 1; overflow-y: auto; padding: 16px 20px 60px; }
70
+ /* the ONE scrolling element. --main-pad-y is its own top+bottom padding, published so the
71
+ sticky results column can subtract exactly that: a column sized to the full VIEWPORT inside
72
+ a padded scrollport is always taller than the room it has, which is a scrollbar on a page
73
+ that fits. The bottom padding is small on purpose — everything that floats here (the run
74
+ bar, the pinned preview) is position:sticky, so it occupies flow space and needs no
75
+ clearance; the old 48px was left from a fixed bar and was pure phantom scroll height */
76
+ .main { --main-pad-y: 26px; flex: 1; min-height: 0; overflow-y: auto; padding: 12px 14px 14px; }
75
77
  .main h2 { font-size: 14px; margin: 0; color: var(--dim); font-weight: 500; }
76
78
  .main h2 b { color: var(--text); }
77
- .form-head { display: flex; gap: 12px; align-items: baseline; margin-bottom: 12px; flex-wrap: wrap; }
78
79
 
80
+ /* the TUI header on the web: one labelled box per thing you are editing, actions below */
81
+ /* the boxes measure the FORM COLUMN, not the window: a results panel on the side halves the
82
+ space they have while the viewport is unchanged, so a media query would answer the wrong
83
+ question. Three variants, and EVEN ones: flex-wrap could leave 3 boxes on one line and 1
84
+ alone on the next, which reads as a bug rather than as a layout */
85
+ .head-shell { container-type: inline-size; }
86
+ .head-boxes { display: grid; grid-template-columns: 1fr; gap: 10px; margin: 4px 0 0; align-items: stretch; }
87
+ @container (min-width: 380px) {
88
+ .head-boxes { grid-template-columns: repeat(2, minmax(0, 1fr)); }
89
+ }
90
+ @container (min-width: 780px) {
91
+ .head-boxes { grid-template-columns: repeat(4, minmax(0, 1fr)); }
92
+ }
93
+ /* no container-query support: fall back to the old wrapping row rather than a stack of four */
94
+ @supports not (container-type: inline-size) {
95
+ .head-boxes { display: flex; flex-wrap: wrap; }
96
+ .head-boxes > .head-box { flex: 1 1 auto; min-width: 150px; }
97
+ }
98
+ .head-box {
99
+ position: relative; border: 1px solid var(--border); border-radius: 8px;
100
+ padding: 5px 9px; background: var(--panel); min-width: 0;
101
+ }
102
+ .head-label {
103
+ position: absolute; top: -7px; left: 9px; padding: 0 5px; background: var(--bg);
104
+ color: var(--dim); font-size: 10px; letter-spacing: 0.06em; text-transform: uppercase;
105
+ }
106
+ .head-value { font-weight: 600; overflow-wrap: anywhere; }
107
+ .head-value.app { color: var(--amber); }
108
+ .head-value.draft { color: var(--accent); }
109
+ .head-value.host { color: var(--green); }
110
+ .head-select { padding: 2px 6px; font-size: 13px; font-weight: 600; color: var(--green); max-width: 220px; }
111
+ .head-select.draft { color: var(--accent); }
112
+ /* a head value that acts: reads like the text beside it, behaves like a button */
113
+ .head-value.as-link {
114
+ border: 0; background: none; padding: 0; font: inherit; font-weight: 600; cursor: pointer;
115
+ color: var(--amber); display: inline-flex; align-items: center; gap: 5px;
116
+ }
117
+ .head-value.as-link:hover { color: var(--accent); text-decoration: underline; }
118
+ button.danger { color: var(--dim); }
119
+ button.danger:hover { color: var(--red); border-color: var(--red); }
120
+
121
+ /* the sidebar is a tree: folder → workflows → drafts, the branch line makes the nesting readable */
122
+ .side-group { margin-bottom: 7px; }
123
+ .side-folder { padding: 4px 12px 2px; color: var(--dim); font-size: 11px; overflow-wrap: anywhere; }
124
+ .side-branch { margin-left: 10px; border-left: 1px solid var(--border); }
125
+
126
+ /* the label column is fit-content CAPPED, not a fixed slab: with short labels the controls
127
+ start right after them. Rows are subgrids of .vars so the column still lines up across
128
+ rows — a per-row grid would give every row its own width. The 150px track is the
129
+ pre-subgrid fallback, kept first so an old engine still gets aligned columns */
130
+ /* the form needs air under the head boxes: the first var sat flush against them */
131
+ .vars { display: grid; grid-template-columns: fit-content(150px) 1fr; margin-top: 14px; }
79
132
  .var-row {
80
- display: grid; grid-template-columns: 170px 1fr; gap: 10px; align-items: start;
81
- padding: 8px 0; border-bottom: 1px solid var(--border);
133
+ display: grid; grid-template-columns: 150px 1fr; grid-column: 1 / -1;
134
+ grid-template-columns: subgrid; gap: 8px; align-items: start;
135
+ padding: 3px 0; border-bottom: 1px solid var(--border);
82
136
  }
83
- .var-label { padding-top: 5px; overflow-wrap: break-word; }
84
- .var-label .kind { color: var(--dim); font-size: 11px; display: block; }
137
+ /* the label IS the drag handle for its row: no separate grip to reveal or aim at */
138
+ .var-label { padding-top: 3px; overflow-wrap: break-word; cursor: grab; }
139
+ .var-label:active { cursor: grabbing; }
140
+ .lora-chip[draggable='true'] { cursor: grab; }
141
+ /* the card drags from anywhere, so its own controls must keep their cursor */
142
+ .lora-chip input, .lora-chip label, .lora-chip button { cursor: pointer; }
143
+ .lora-chip input[type='number'] { cursor: text; }
85
144
  .var-label .dirty-dot { color: var(--amber); margin-left: 4px; background: none; border: 0; padding: 0; cursor: pointer; font: inherit; }
86
145
  .var-label .dirty-dot:hover { color: var(--red); }
87
146
  .var-control { min-width: 0; }
88
- .hint { color: var(--dim); font-size: 11px; margin-top: 3px; }
147
+ .hint { color: var(--dim); font-size: 11px; margin-top: 2px; }
89
148
 
90
149
  input[type='text'], input[type='number'], textarea, select {
91
150
  background: var(--panel-2); color: var(--text); border: 1px solid var(--border);
92
- border-radius: 6px; padding: 6px 8px; font: inherit; max-width: 100%;
151
+ border-radius: 6px; padding: 3px 7px; font: inherit; max-width: 100%;
93
152
  }
94
153
  input[type='text'] { width: 100%; }
95
154
  input[type='number'] { width: 110px; }
@@ -99,41 +158,107 @@ input[type='range'] { width: 100%; accent-color: var(--accent); }
99
158
  input[type='checkbox'] { accent-color: var(--accent); width: 16px; height: 16px; }
100
159
  .row-inline { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
101
160
 
161
+ /* presets menu (text + prompt vars). The backdrop sits UNDER the menu and over everything
162
+ else, so any outside click closes it without a document listener */
163
+ .preset-box { position: relative; }
164
+ .preset-btn { white-space: nowrap; }
165
+ .preset-backdrop { position: fixed; inset: 0; z-index: 40; }
166
+ .preset-menu {
167
+ position: absolute; top: calc(100% + 4px); left: 0; z-index: 41;
168
+ display: flex; flex-direction: column; min-width: 260px; max-width: min(520px, 90vw);
169
+ max-height: 320px; overflow-y: auto;
170
+ background: var(--panel-2); border: 1px solid var(--border); border-radius: 8px; padding: 4px;
171
+ box-shadow: 0 10px 28px rgba(0, 0, 0, 0.55);
172
+ }
173
+ .preset-item {
174
+ display: flex; flex-direction: column; gap: 1px; align-items: flex-start;
175
+ background: none; border: 0; border-radius: 6px; padding: 4px 7px; text-align: left; width: 100%;
176
+ }
177
+ .preset-item:hover { background: var(--accent-dim); border-color: transparent; }
178
+ .preset-item.on .preset-name { color: var(--accent); }
179
+ .preset-name { white-space: pre; }
180
+ .preset-peek {
181
+ color: var(--dim); font-size: 11px; max-width: 100%;
182
+ overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
183
+ }
184
+
102
185
  button {
103
186
  background: var(--panel-2); color: var(--text); border: 1px solid var(--border);
104
- border-radius: 6px; padding: 5px 10px; font: inherit; cursor: pointer;
187
+ border-radius: 6px; padding: 3px 8px; font: inherit; cursor: pointer;
105
188
  }
106
189
  button:hover { border-color: var(--accent); }
107
190
  button:disabled { opacity: 0.5; cursor: default; }
108
- button.primary { background: var(--accent); border-color: var(--accent); color: #0d1117; font-weight: 600; padding: 8px 22px; }
191
+ /* the run button is the loudest thing on the page, it does not need to be the biggest */
192
+ button.primary {
193
+ background: var(--accent); border-color: var(--accent); color: #0d1117; font-weight: 600;
194
+ padding: 5px 14px; display: inline-flex; align-items: center; gap: 6px;
195
+ }
196
+ .kbd-hint {
197
+ font-size: 10px; opacity: 0.65; border: 1px solid currentColor; border-radius: 4px;
198
+ padding: 0 4px; line-height: 1.4;
199
+ }
109
200
  button.link { border: 0; background: none; color: var(--accent); padding: 0; }
110
- button.mode { padding: 4px 8px; font-size: 12px; }
201
+ button.link.danger { color: var(--dim); }
202
+ button.link.danger:hover { color: var(--red); }
203
+ button.mode { padding: 2px 7px; font-size: 12px; }
111
204
  button.mode.sel { background: var(--accent-dim); border-color: var(--accent); color: #fff; }
112
205
 
206
+ /* the run line: button, queue count, result count — one row, each part appearing only when
207
+ it has something to say */
208
+ .run-line { display: inline-flex; gap: 10px; align-items: center; flex-wrap: wrap; }
209
+ .run-chip {
210
+ display: inline-flex; gap: 6px; align-items: center; color: var(--dim); font-size: 12px;
211
+ border: 1px solid var(--border); border-radius: 999px; padding: 2px 10px;
212
+ }
213
+ .run-chip .link { font-size: 12px; }
113
214
  .runbar {
114
215
  position: sticky; bottom: 0; display: flex; gap: 14px; align-items: center;
115
216
  background: var(--panel); border: 1px solid var(--border); border-radius: 8px;
116
- padding: 10px 14px; margin-top: 14px;
217
+ padding: 8px 12px; margin-top: 10px;
117
218
  }
118
- .runbar .status { color: var(--dim); font-size: 12px; }
219
+ /* the changed-vars broom: FAR RIGHT of the draft box line and outside the button group, so
220
+ appearing and disappearing with the dirty count never shifts the buttons beside it */
221
+ .head-box .head-right { margin-left: auto; padding: 2px 5px; }
222
+ .head-box button.dirty { color: var(--amber); }
223
+ .head-box button.dirty:hover { color: var(--red); border-color: var(--red); }
119
224
  .runbar .error { color: var(--red); font-size: 12px; white-space: pre-wrap; }
120
225
  .pulse { animation: pulse 1.2s ease-in-out infinite; }
121
226
  @keyframes pulse { 50% { opacity: 0.45; } }
122
227
 
123
- .gallery { margin-top: 18px; display: flex; flex-direction: column; gap: 14px; }
124
- .gallery-head { display: flex; gap: 12px; align-items: baseline; color: var(--dim); font-size: 12px; }
125
- .run-card { background: var(--panel); border: 1px solid var(--border); border-radius: 8px; padding: 10px 12px; }
228
+ .gallery { margin-top: 12px; display: flex; flex-direction: column; gap: 10px; }
229
+ .run-card { background: var(--panel); border: 1px solid var(--border); border-radius: 8px; padding: 8px 10px; }
126
230
  .run-card .meta { color: var(--dim); font-size: 12px; margin-bottom: 8px; display: flex; justify-content: space-between; gap: 8px; }
127
231
  .run-card .imgs { display: flex; flex-wrap: wrap; gap: 10px; }
128
232
  .run-card img { max-width: min(320px, 100%); max-height: 320px; border-radius: 6px; display: block; }
129
233
  .run-card .noimg { color: var(--dim); font-style: italic; }
130
234
  .run-card.running { border-color: var(--accent-dim); }
235
+ /* what the host is on, in the node's own unit — the live signal of a text run, which has
236
+ neither a latent frame nor an image to show */
237
+ .run-node { color: var(--accent); font-size: 12px; margin-bottom: 6px; font-variant-numeric: tabular-nums; }
238
+
239
+ /* a STRING output: the answer is prose, so it wraps and selects like prose. Monospace because
240
+ an expanded prompt is copied into another field verbatim */
241
+ .run-text { margin-top: 8px; border-top: 1px solid var(--border); padding-top: 6px; }
242
+ .run-text-head { display: flex; align-items: center; gap: 10px; margin-bottom: 4px; }
243
+ .run-text-body, .run-thinking {
244
+ margin: 0; white-space: pre-wrap; overflow-wrap: anywhere;
245
+ font-family: ui-monospace, SFMono-Regular, Menlo, monospace; font-size: 13px; line-height: 1.5;
246
+ background: var(--panel-2); border: 1px solid var(--border); border-radius: 6px; padding: 7px 9px;
247
+ max-height: 40vh; overflow-y: auto;
248
+ }
249
+ .run-thinking { color: var(--dim); font-size: 12px; margin-bottom: 6px; }
250
+
251
+ /* the stream: pinned to its newest line, capped so a long answer never pushes the page around */
252
+ .run-live { margin-top: 6px; }
253
+ .run-live-body {
254
+ margin: 0; white-space: pre-wrap; overflow-wrap: anywhere;
255
+ font-family: ui-monospace, SFMono-Regular, Menlo, monospace; font-size: 12px; line-height: 1.5;
256
+ background: var(--panel-2); border: 1px solid var(--border); border-radius: 6px; padding: 6px 8px;
257
+ max-height: 30vh; overflow-y: auto;
258
+ }
259
+ .run-live-body.dim { color: var(--dim); }
131
260
  .progress-track { height: 6px; background: var(--panel-2); border-radius: 3px; overflow: hidden; margin-bottom: 8px; }
132
261
  .progress-fill { height: 100%; background: var(--accent); border-radius: 3px; transition: width 0.4s ease; }
133
- .img-cell { display: flex; flex-direction: column; gap: 4px; min-width: 0; }
134
- .img-actions { display: flex; gap: 10px; align-items: baseline; font-size: 12px; }
135
- .img-actions a { color: var(--accent); text-decoration: none; }
136
- .img-actions button { padding: 2px 8px; font-size: 12px; }
137
262
 
138
263
  .lora-chip {
139
264
  display: inline-flex; gap: 6px; align-items: center; max-width: 100%;
@@ -143,10 +268,14 @@ button.mode.sel { background: var(--accent-dim); border-color: var(--accent); co
143
268
  .lora-chip button:hover { color: var(--red); }
144
269
  /* image mode: the row chip becomes the same preview card as the popup */
145
270
  .lora-chip.card {
271
+ position: relative;
146
272
  flex-direction: column; align-items: stretch; border-radius: 8px; padding: 6px;
147
- background: var(--panel-2); border: 1px solid var(--border); width: 132px;
273
+ background: var(--panel-2); border: 1px solid var(--border); width: 168px;
274
+ /* anything that still outgrows the card is clipped IN PLACE, never painted over its
275
+ neighbour. CLIP on x only: hidden on both axes would trap the tooltips too */
276
+ overflow-x: clip; overflow-y: visible;
148
277
  }
149
- .lora-chip.card .lora-thumb { height: 110px; }
278
+ .lora-chip.card .lora-thumb { height: 130px; }
150
279
  .lora-chip.card .chip-title { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
151
280
  .chip-title { min-width: 0; }
152
281
  /* the whole card is the pause/resume target — the palette gesture */
@@ -156,26 +285,66 @@ button.mode.sel { background: var(--accent-dim); border-color: var(--accent); co
156
285
  }
157
286
  .lora-chip:not(.card) .lora-toggle { flex-direction: row; align-items: center; gap: 6px; }
158
287
  .lora-toggle:hover .chip-title { color: var(--accent); }
159
- .chip-state { font-size: 10px; color: var(--green); letter-spacing: 0.04em; }
160
- .lora-chip.off .chip-state { color: var(--amber); }
161
- .chip-controls { display: flex; gap: 4px; align-items: center; }
162
- .chip-controls input[type='number'] { width: 52px; padding: 1px 4px; font-size: 11px; }
163
- .chip-controls button { border: 0; background: none; color: inherit; padding: 0 2px; font-size: 11px; }
164
- .chip-controls button:hover { color: var(--red); }
288
+ .chip-controls { display: flex; flex-direction: column; gap: 3px; }
289
+ /* a line: label button, slider, number. The label toggles m+c ↔ m / c */
290
+ .st-line { display: flex; gap: 5px; align-items: center; }
291
+ .st-line .st-label {
292
+ border: 0; background: none; padding: 0; cursor: pointer; font-size: 10px; letter-spacing: 0.03em;
293
+ color: var(--dim); width: 24px; text-align: left; flex-shrink: 0;
294
+ }
295
+ .st-line .st-label:hover { color: var(--accent); }
296
+ /* wide enough for a signed two-decimal value plus the spinner: -0.55 was clipping */
297
+ .st-line input[type='number'] { width: 58px; flex-shrink: 0; padding: 1px 5px; font-size: 11px; }
298
+
299
+ /* the sliders, drawn rather than left to the browser's default chrome */
300
+ .st-line input[type='range'] {
301
+ flex: 1; min-width: 40px; height: 14px; margin: 0; padding: 0;
302
+ appearance: none; background: none; cursor: pointer;
303
+ }
304
+ .st-line input[type='range']::-webkit-slider-runnable-track {
305
+ height: 3px; border-radius: 2px; background: var(--border);
306
+ }
307
+ .st-line input[type='range']::-webkit-slider-thumb {
308
+ appearance: none; width: 11px; height: 11px; border-radius: 50%; margin-top: -4px;
309
+ background: var(--accent); border: 0;
310
+ }
311
+ .st-line input[type='range']::-moz-range-track { height: 3px; border-radius: 2px; background: var(--border); }
312
+ .st-line input[type='range']::-moz-range-thumb {
313
+ width: 11px; height: 11px; border: 0; border-radius: 50%; background: var(--accent);
314
+ }
315
+ .lora-chip.off .st-line input[type='range']::-webkit-slider-thumb { background: var(--dim); }
316
+ .lora-chip.off .st-line input[type='range']::-moz-range-thumb { background: var(--dim); }
317
+
318
+ /* the head line: switch, then the name */
319
+ .chip-head { display: flex; gap: 6px; align-items: center; min-width: 0; }
320
+ .chip-title.as-text {
321
+ border: 0; background: none; padding: 0; color: inherit; font: inherit; cursor: pointer;
322
+ overflow: hidden; text-overflow: ellipsis; white-space: nowrap; text-align: left; min-width: 0;
323
+ }
324
+ .chip-title.as-text:hover { color: var(--accent); }
325
+
326
+ /* the picture's own box: the ✕ is positioned against THIS, so it never depends on which
327
+ ancestor happens to be positioned, and the image keeps the whole height */
328
+ .chip-media { position: relative; display: block; isolation: isolate; }
329
+ .chip-media .lora-toggle { display: block; width: 100%; }
330
+ /* ✕ is ALWAYS a corner overlay, on the card and in the popup row: it costs zero layout
331
+ width, and it is never hover-gated — a phone has no hover, so a hidden ✕ is no ✕.
332
+ The selector carries TWO classes on purpose: the .lora-chip button rule above is 0-1-1 and would
333
+ otherwise win, stripping the padding and the backdrop off this one.
334
+ width:auto because a stretch parent would otherwise pull it across the whole card */
335
+ .chip-media .chip-remove, .lora-active-row .chip-remove {
336
+ position: absolute; top: 4px; right: 4px; z-index: 1; width: auto; height: auto;
337
+ display: inline-flex; align-items: center; justify-content: center;
338
+ border: 0; border-radius: 6px; padding: 4px; line-height: 0; color: #fff; cursor: pointer;
339
+ background: rgba(16, 18, 23, 0.72); opacity: 0.85; transition: opacity 0.12s, color 0.12s;
340
+ }
341
+ .chip-media .chip-remove:hover, .lora-active-row .chip-remove:hover { opacity: 1; color: var(--red); }
342
+
165
343
  /* PAUSED: still in the palette, visibly not contributing to the graph */
166
344
  .lora-chip.off, .lora-active-row.off { opacity: 0.55; }
167
345
  .lora-chip.off { border-style: dashed; }
168
346
  .lora-chip.off .lora-thumb, .lora-active-row.off .lora-thumb { filter: grayscale(1); }
169
347
 
170
- .queue { margin-top: 10px; border: 1px solid var(--border); border-radius: 8px; background: var(--panel); }
171
- .queue-head {
172
- display: flex; gap: 12px; align-items: baseline; justify-content: space-between;
173
- padding: 6px 10px; border-bottom: 1px solid var(--border); color: var(--dim); font-size: 12px;
174
- }
175
- .queue-row { display: flex; gap: 10px; align-items: center; padding: 4px 10px; font-size: 12px; }
176
- .queue-ix { color: var(--dim); width: 16px; }
177
- .queue-name { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
178
- .queue-row button { padding: 1px 8px; font-size: 11px; }
179
348
 
180
349
  .modal-overlay {
181
350
  position: fixed; inset: 0; z-index: 50; background: rgba(0, 0, 0, 0.55);
@@ -190,7 +359,7 @@ button.mode.sel { background: var(--accent-dim); border-color: var(--accent); co
190
359
  .modal-body { overflow-y: auto; padding: 10px; }
191
360
  .section-title { color: var(--dim); font-size: 11px; text-transform: uppercase; letter-spacing: 0.06em; margin: 8px 0 6px; }
192
361
 
193
- .lora-active-row { display: flex; gap: 10px; align-items: center; padding: 4px 0; border-bottom: 1px solid var(--border); }
362
+ .lora-active-row { position: relative; display: flex; gap: 10px; align-items: center; padding: 4px 22px 4px 0; border-bottom: 1px solid var(--border); }
194
363
  .lora-active-text { flex: 1; min-width: 0; }
195
364
  .lora-active-row input[type='number'] { width: 64px; padding: 2px 6px; font-size: 12px; }
196
365
  .lora-label { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 13px; }
@@ -201,7 +370,11 @@ button.mode.sel { background: var(--accent-dim); border-color: var(--accent); co
201
370
  background: var(--panel-2); border: 1px solid var(--border); border-radius: 8px; cursor: pointer; min-width: 0;
202
371
  }
203
372
  .lora-card:hover { border-color: var(--accent); }
204
- .lora-thumb { width: 100%; height: 110px; object-fit: cover; border-radius: 6px; display: block; }
373
+ /* CONTAIN, never cover: a cropped preview hides exactly what the lora looks like */
374
+ /* contain by default (nothing of the art is hidden); FILL crops to the card, which reads far
375
+ better for style loras — the toggle lives in the loras row and persists */
376
+ .lora-thumb { width: 100%; height: 110px; object-fit: contain; border-radius: 6px; display: block; background: var(--bg); }
377
+ .lora-thumb.fill { object-fit: cover; }
205
378
  .lora-active-row .lora-thumb { width: 48px; height: 48px; flex-shrink: 0; }
206
379
  div.lora-thumb.none {
207
380
  display: flex; align-items: center; justify-content: center;
@@ -214,11 +387,18 @@ div.lora-thumb.none {
214
387
  display: flex; flex-direction: column; gap: 8px; max-width: min(1100px, 100%); max-height: 100%;
215
388
  }
216
389
  .lightbox img { max-width: 100%; max-height: calc(90vh - 60px); object-fit: contain; border-radius: 8px; }
390
+ /* wheel zoom: the viewport CLIPS, the image inside is transformed. transform-origin stays
391
+ centred so the pan offsets computed from the cursor are the only thing moving it */
392
+ .zoom-view { overflow: hidden; border-radius: 8px; display: flex; justify-content: center; touch-action: none; }
393
+ .zoom-view img { transform-origin: center center; will-change: transform; }
394
+ .zoom-view.grabbing { cursor: grab; }
395
+ .zoom-view.grabbing:active { cursor: grabbing; }
217
396
  .lightbox-bar {
218
397
  display: flex; gap: 12px; align-items: center; justify-content: center; flex-wrap: wrap;
219
398
  background: var(--panel); border: 1px solid var(--border); border-radius: 8px; padding: 8px 12px;
220
399
  }
221
400
  .lightbox-bar a { color: var(--accent); text-decoration: none; }
401
+ .loras-more input[type='number'] { width: 72px; margin: 0 5px; }
222
402
  .loras-more { color: var(--dim); font-size: 12px; padding: 4px 10px; }
223
403
 
224
404
  /* prompt enhancer modal */
@@ -241,13 +421,182 @@ div.lora-thumb.none {
241
421
  .center { display: flex; height: 100%; align-items: center; justify-content: center; color: var(--dim); }
242
422
  .center .error { color: var(--red); max-width: 640px; white-space: pre-wrap; }
243
423
 
244
- /* results right of the form on wide screens ("bottom or right": right ≥1100px, bottom below) */
245
- @media (min-width: 1100px) {
246
- .work { display: flex; gap: 18px; align-items: flex-start; }
247
- .form-col { flex: 1; min-width: 0; }
248
- .results-col { width: 380px; flex-shrink: 0; }
249
- .results-col .gallery { margin-top: 0; }
424
+ /* the placements. Each one is a BUTTON and nothing else: there is no width rule that quietly
425
+ moves the panel somewhere no button is showing */
426
+ .work.layout-side { display: flex; gap: 18px; align-items: flex-start; }
427
+ .work.layout-side .form-col { flex: 1; min-width: 0; }
428
+ .work.layout-side .results-col { width: min(380px, 45vw); flex-shrink: 0; }
429
+ .work.layout-side .results-col .gallery { margin-top: 0; }
430
+ /* results LEFT of the form: same column, the other side. flex order rather than
431
+ row-reverse, so the dom order (form first) stays the reading and tab order */
432
+ .work.layout-left { display: flex; gap: 18px; align-items: flex-start; }
433
+ .work.layout-left .form-col { flex: 1; min-width: 0; order: 2; }
434
+ .work.layout-left .results-col { width: min(380px, 45vw); flex-shrink: 0; order: 1; }
435
+ .work.layout-left .results-col .gallery { margin-top: 0; }
436
+ .work.layout-left .results-col {
437
+ position: sticky; top: 0; align-self: flex-start;
438
+ max-height: calc(100dvh - var(--main-pad-y, 26px)); min-height: 0; overflow-y: auto; overscroll-behavior: contain;
439
+ }
440
+
441
+ /* a 380px column beside a form does not fit a phone: BOTH side placements stack there. This
442
+ is the chosen mode adapting, not a different mode — the button stays lit and still says
443
+ where the panel goes the moment there is room for it */
444
+ @media (max-width: 760px) {
445
+ .work.layout-side, .work.layout-left { display: block; }
446
+ .work.layout-side .results-col, .work.layout-left .results-col {
447
+ position: static; width: auto; max-height: none; overflow-y: visible; margin-top: 12px;
448
+ }
449
+ }
450
+
451
+ /* A COLUMN OF RESULTS IS NEVER TALLER THAN THE PAGE. Left to itself it grows with the run
452
+ history and drags the document down, so reading a var meant scrolling past a stack of
453
+ images. It sticks to the top of .main (the scroll container) and scrolls INSIDE itself,
454
+ so the form column stays where it is however many runs pile up */
455
+ .work.layout-side .results-col {
456
+ position: sticky; top: 0; align-self: flex-start;
457
+ max-height: calc(100dvh - var(--main-pad-y, 26px)); min-height: 0; overflow-y: auto; overscroll-behavior: contain;
458
+ }
459
+ /* PINNED: the newest result floats over the bottom, the form scrolls under it — the phone
460
+ answer to "I always have to scroll between them". Sticky, so it never covers the runbar.
461
+ It HUGS its content: fit-content width + auto height, so an empty run or a tall portrait
462
+ never leaves a band of dead space around the image */
463
+ .work.layout-pinned .results-col {
464
+ /* bottom RIGHT corner: it hugs the image, so anchoring it to a corner keeps the form's
465
+ left edge readable instead of splitting the page down the middle */
466
+ position: sticky; bottom: 0; z-index: 15; margin-top: 10px;
467
+ width: fit-content; max-width: 100%; margin-left: auto; margin-right: 0;
468
+ max-height: 46vh; overflow-y: auto;
469
+ background: var(--panel); border: 1px solid var(--border); border-radius: 10px;
470
+ box-shadow: 0 -8px 24px rgba(0, 0, 0, 0.45); padding: 6px;
471
+ }
472
+ .work.layout-pinned .results-col .gallery { margin-top: 0; gap: 6px; }
473
+ /* the pinned card is the IMAGE plus its controls, nothing else: no meta line, no padding walls */
474
+ .work.layout-pinned .run-card { padding: 0; border: 0; background: none; }
475
+ .work.layout-pinned .run-card .meta { margin-bottom: 2px; font-size: 11px; }
476
+ .work.layout-pinned .run-card img { max-height: 34vh; width: auto; }
477
+ .results-run { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; margin-bottom: 8px; }
478
+ .work.layout-pinned .results-run { margin-bottom: 6px; justify-content: flex-end; }
479
+ /* segmented control: ONE group, no gaps, only the outer corners rounded */
480
+ .btn-group { display: inline-flex; }
481
+ .btn-group button {
482
+ padding: 2px 6px; font-size: 13px; line-height: 1.3; border-radius: 0; margin: 0;
483
+ border-right-width: 0; background: var(--panel-2);
484
+ }
485
+ .btn-group button:first-child { border-top-left-radius: 6px; border-bottom-left-radius: 6px; }
486
+ .btn-group button:last-child { border-right-width: 1px; border-top-right-radius: 6px; border-bottom-right-radius: 6px; }
487
+ .btn-group button.sel { background: var(--accent-dim); border-color: var(--accent); color: #fff; }
488
+ /* the selected segment owns the divider on both sides, else its highlight looks clipped */
489
+ .btn-group button.sel + button { border-left-color: var(--accent); }
490
+ .btn-group button:hover { background: var(--panel); }
491
+ /* a group living inside a header box sits beside the value, not under it */
492
+ .head-group { margin-left: 8px; vertical-align: middle; }
493
+ .head-group button { padding: 2px 5px; }
494
+ /* rows that mix buttons and inputs: one height for both, so nothing steps over the line.
495
+ 32px is what an input with 6px padding and a 1px border measures at this font size */
496
+ /* everything on a var row is the SAME height as the input beside it, or the row steps.
497
+ 28px is what the slimmed input measures (14px text, 3px padding, 1px border) */
498
+ .field-height, .field-height button { height: 28px; }
499
+ .field-height button { display: inline-flex; align-items: center; justify-content: center; }
500
+ /* a one-character mode button still needs a target: = + ? are narrow glyphs */
501
+ .btn-group.field-height button { min-width: 28px; }
502
+ .head-input { padding: 2px 6px; font-size: 13px; font-weight: 600; color: var(--accent); max-width: 180px; }
503
+ .head-label .save-state { color: var(--dim); font-weight: 400; margin-left: 4px; }
504
+ .head-label .save-state.error { color: var(--red); }
505
+ /* every head box is two lines: what you are on, then what you can do to it */
506
+ .head-box { display: flex; flex-direction: column; gap: 5px; }
507
+ .head-line { display: flex; gap: 8px; align-items: center; min-height: 24px; }
508
+ .head-line .head-group { margin-left: 0; }
509
+
510
+ /* the lora controls sit above the palette, left aligned */
511
+ .lora-actions { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; margin-bottom: 8px; }
512
+ .lora-actions button { font-size: 12px; }
513
+ /* a lora the manager knows and comfy does not: flagged, never hidden */
514
+ .host-note {
515
+ margin: 8px 0; padding: 6px 10px; font-size: 12px; color: var(--text);
516
+ background: var(--panel); border: 1px solid var(--accent-dim); border-radius: 6px;
517
+ }
518
+ /* the keywords the active loras prepend to the prompt: shown, not guessed */
519
+ .kw-prefix { display: flex; gap: 6px; flex-wrap: wrap; margin-bottom: 6px; }
520
+ .kw-chip {
521
+ font-size: 11px; padding: 2px 8px; border-radius: 10px;
522
+ background: var(--accent-dim); color: #fff;
523
+ }
524
+ /* a real switch, not a word: the state is readable at a glance and hittable on a phone */
525
+ .switch { position: relative; display: inline-flex; width: 28px; height: 16px; flex-shrink: 0; cursor: pointer; }
526
+ .switch input { position: absolute; opacity: 0; width: 100%; height: 100%; margin: 0; cursor: pointer; }
527
+ .switch .track {
528
+ position: absolute; inset: 0; border-radius: 999px; background: var(--panel-2);
529
+ border: 1px solid var(--border); transition: background 0.15s, border-color 0.15s;
530
+ }
531
+ .switch .track::after {
532
+ content: ''; position: absolute; top: 1px; left: 1px; width: 12px; height: 12px; border-radius: 50%;
533
+ background: var(--dim); transition: transform 0.15s, background 0.15s;
534
+ }
535
+ .switch input:checked + .track { background: var(--accent-dim); border-color: var(--accent); }
536
+ .switch input:checked + .track::after { transform: translateX(12px); background: var(--accent); }
537
+ .switch input:focus-visible + .track { outline: 2px solid var(--accent); outline-offset: 2px; }
538
+
539
+ /* the lora details sheet */
540
+ .lora-details { display: flex; gap: 14px; flex-wrap: wrap; }
541
+ .detail-thumb { width: 220px; max-width: 100%; border-radius: 8px; }
542
+ .detail-list { flex: 1; min-width: 220px; display: flex; flex-direction: column; gap: 6px; }
543
+ .detail-row { display: grid; grid-template-columns: 110px 1fr; gap: 10px; font-size: 12px; }
544
+ .detail-key { color: var(--dim); }
545
+ .detail-val { overflow-wrap: anywhere; }
546
+ .detail-val a { color: var(--accent); text-decoration: none; }
547
+ /* civitai's own words about the model. PLAIN TEXT: the extension answers html, and third
548
+ party html is never injected into this page — the seam strips it to text */
549
+ .detail-desc {
550
+ white-space: pre-wrap; font-size: 12px; line-height: 1.5; color: var(--text);
551
+ background: var(--bg); border: 1px solid var(--border); border-radius: 6px;
552
+ padding: 8px 10px; max-height: 220px; overflow-y: auto;
250
553
  }
554
+ .detail-examples { display: flex; gap: 8px; flex-wrap: wrap; }
555
+ .detail-examples img { width: 96px; height: 96px; object-fit: cover; border-radius: 6px; }
556
+
557
+ button.warn-action { color: var(--amber); border-color: var(--amber); }
558
+ button.warn-action:hover { background: var(--panel); }
559
+ .lora-warn { color: var(--amber); display: inline-flex; margin-left: 4px; vertical-align: -0.1em; }
560
+ /* an anchor that must read as a button (it opens the host's own page, so it IS a link) */
561
+ .button-link {
562
+ display: inline-flex; align-items: center; gap: 5px; text-decoration: none; font-size: 12px;
563
+ background: var(--panel-2); color: var(--text); border: 1px solid var(--border);
564
+ border-radius: 6px; padding: 0 10px;
565
+ }
566
+ .button-link:hover { border-color: var(--accent); color: var(--accent); }
567
+
568
+ /* the ComfyUI console, only while asked for */
569
+ .logs { margin-top: 14px; border: 1px solid var(--border); border-radius: 8px; background: var(--panel); }
570
+ .logs-head {
571
+ display: flex; justify-content: space-between; gap: 12px; align-items: baseline;
572
+ padding: 6px 10px; border-bottom: 1px solid var(--border); color: var(--dim); font-size: 12px;
573
+ }
574
+ .logs pre {
575
+ margin: 0; padding: 8px 10px; max-height: 240px; overflow: auto; white-space: pre-wrap;
576
+ font-size: 11px; line-height: 1.35; color: var(--dim);
577
+ font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
578
+ }
579
+
580
+ /* INSTANT tooltips: the native title attribute waits about a second and cannot be styled, so
581
+ every affordance carries data-tip instead. No js, no library, and no delay, which is the point */
582
+ [data-tip] { position: relative; }
583
+ [data-tip]:hover::after, [data-tip]:focus-visible::after {
584
+ content: attr(data-tip);
585
+ /* anchored to the button's bottom LEFT, never centred: a centred tip on the leftmost
586
+ button hangs off the screen, and one below never covers the row you are reading */
587
+ position: absolute; top: calc(100% + 5px); left: 0;
588
+ z-index: 60; pointer-events: none; white-space: normal; max-width: 220px; width: max-content;
589
+ opacity: 0.8;
590
+ background: var(--panel-2); color: var(--text); border: 1px solid var(--border);
591
+ border-radius: 6px; padding: 4px 8px; font-size: 11px; font-weight: 400; line-height: 1.3;
592
+ box-shadow: 0 6px 18px rgba(0, 0, 0, 0.5);
593
+ }
594
+ /* the pointer never crosses a tooltip, so hover cannot flicker between the two */
595
+ @media (hover: none) { [data-tip]:hover::after { display: none; } }
596
+
597
+ /* icons inherit the text they sit in, so a button never jumps when one is swapped in */
598
+ .icon { display: inline-block; vertical-align: -0.16em; flex-shrink: 0; }
599
+ button .icon + * { margin-left: 4px; }
251
600
 
252
601
  /* the sidebar becomes a fixed drawer over a backdrop */
253
602
  @media (max-width: 800px) {
@@ -261,10 +610,14 @@ div.lora-thumb.none {
261
610
 
262
611
  /* phone: label over control, 16px inputs (below that iOS zooms the page on focus) */
263
612
  @media (max-width: 640px) {
264
- .main { padding: 12px 12px 60px; }
265
- .var-row { grid-template-columns: 1fr; gap: 4px; }
266
- .var-label { padding-top: 0; }
267
- .var-label .kind { display: inline; margin-left: 6px; }
613
+ .main { --main-pad-y: 22px; padding: 10px 10px 12px; }
614
+ /* labels stay BESIDE their control on a phone too: stacking them doubled the height of
615
+ every row and read as a wall. The column just gets narrower. A row that needs the whole
616
+ width (loras) opts out with .wide */
617
+ .vars { grid-template-columns: fit-content(96px) 1fr; }
618
+ .var-row { gap: 6px; }
619
+ .var-row.wide { grid-template-columns: 1fr; gap: 3px; }
620
+ .var-label { padding-top: 3px; font-size: 12px; }
268
621
  input[type='text'], input[type='number'], textarea, select { font-size: 16px; }
269
622
  input[type='number'] { width: 96px; }
270
623
  /* repeated at row specificity: the base 12px rule outranks the bare selector above,
@@ -277,4 +630,4 @@ div.lora-thumb.none {
277
630
  /* side by side prompts do not fit a phone: stack yours over the rewrite */
278
631
  .enh-cols { grid-template-columns: 1fr; }
279
632
  }
280
- `;var ny=document.createElement("style");ny.textContent=ty;document.head.appendChild(ny);var ly=new Zc;globalThis.webst=ly;var ay=document.getElementById("root");if(ay==null)throw Error("[serve web] #root element missing from the shell html");ey.createRoot(ay).render(m(Xg,{st:ly}));
633
+ `;var Wb=document.createElement("style");Wb.textContent=Jb;document.head.appendChild(Wb);var Ib=new mf;globalThis.webst=Ib;var Pb=document.getElementById("root");if(Pb==null)throw Error("[serve web] #root element missing from the shell html");Fb.createRoot(Pb).render(u($b,{st:Ib}));