@elizaos/plugin-knowledge 1.5.14 → 1.6.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.
- package/dist/.vite/manifest.json +2 -2
- package/dist/assets/index-CFqKS0Ch.css +1 -0
- package/dist/assets/index-DcxhjPNa.js +54 -0
- package/dist/index.d.ts +22 -0
- package/dist/index.html +2 -2
- package/dist/index.js +101 -64
- package/dist/index.js.map +1 -1
- package/package.json +2 -2
- package/dist/assets/index-DtOcbZ9V.js +0 -169
- package/dist/assets/index-crC0VS8M.css +0 -1
|
@@ -1,169 +0,0 @@
|
|
|
1
|
-
(function(){const i=document.createElement("link").relList;if(i&&i.supports&&i.supports("modulepreload"))return;for(const o of document.querySelectorAll('link[rel="modulepreload"]'))u(o);new MutationObserver(o=>{for(const c of o)if(c.type==="childList")for(const h of c.addedNodes)h.tagName==="LINK"&&h.rel==="modulepreload"&&u(h)}).observe(document,{childList:!0,subtree:!0});function r(o){const c={};return o.integrity&&(c.integrity=o.integrity),o.referrerPolicy&&(c.referrerPolicy=o.referrerPolicy),o.crossOrigin==="use-credentials"?c.credentials="include":o.crossOrigin==="anonymous"?c.credentials="omit":c.credentials="same-origin",c}function u(o){if(o.ep)return;o.ep=!0;const c=r(o);fetch(o.href,c)}})();function Ry(n){return n&&n.__esModule&&Object.prototype.hasOwnProperty.call(n,"default")?n.default:n}var Qc={exports:{}},Jr={};/**
|
|
2
|
-
* @license React
|
|
3
|
-
* react-jsx-runtime.production.js
|
|
4
|
-
*
|
|
5
|
-
* Copyright (c) Meta Platforms, Inc. and affiliates.
|
|
6
|
-
*
|
|
7
|
-
* This source code is licensed under the MIT license found in the
|
|
8
|
-
* LICENSE file in the root directory of this source tree.
|
|
9
|
-
*/var Kg;function db(){if(Kg)return Jr;Kg=1;var n=Symbol.for("react.transitional.element"),i=Symbol.for("react.fragment");function r(u,o,c){var h=null;if(c!==void 0&&(h=""+c),o.key!==void 0&&(h=""+o.key),"key"in o){c={};for(var g in o)g!=="key"&&(c[g]=o[g])}else c=o;return o=c.ref,{$$typeof:n,type:u,key:h,ref:o!==void 0?o:null,props:c}}return Jr.Fragment=i,Jr.jsx=r,Jr.jsxs=r,Jr}var Fg;function gb(){return Fg||(Fg=1,Qc.exports=db()),Qc.exports}var E=gb(),Ja=class{constructor(){this.listeners=new Set,this.subscribe=this.subscribe.bind(this)}subscribe(n){return this.listeners.add(n),this.onSubscribe(),()=>{this.listeners.delete(n),this.onUnsubscribe()}}hasListeners(){return this.listeners.size>0}onSubscribe(){}onUnsubscribe(){}},Wi=typeof window>"u"||"Deno"in globalThis;function xe(){}function pb(n,i){return typeof n=="function"?n(i):n}function df(n){return typeof n=="number"&&n>=0&&n!==1/0}function Dy(n,i){return Math.max(n+(i||0)-Date.now(),0)}function wi(n,i){return typeof n=="function"?n(i):n}function We(n,i){return typeof n=="function"?n(i):n}function Pg(n,i){const{type:r="all",exact:u,fetchStatus:o,predicate:c,queryKey:h,stale:g}=n;if(h){if(u){if(i.queryHash!==Bf(h,i.options))return!1}else if(!pl(i.queryKey,h))return!1}if(r!=="all"){const y=i.isActive();if(r==="active"&&!y||r==="inactive"&&y)return!1}return!(typeof g=="boolean"&&i.isStale()!==g||o&&o!==i.state.fetchStatus||c&&!c(i))}function Jg(n,i){const{exact:r,status:u,predicate:o,mutationKey:c}=n;if(c){if(!i.options.mutationKey)return!1;if(r){if(Ii(i.options.mutationKey)!==Ii(c))return!1}else if(!pl(i.options.mutationKey,c))return!1}return!(u&&i.state.status!==u||o&&!o(i))}function Bf(n,i){return(i?.queryKeyHashFn||Ii)(n)}function Ii(n){return JSON.stringify(n,(i,r)=>gf(r)?Object.keys(r).sort().reduce((u,o)=>(u[o]=r[o],u),{}):r)}function pl(n,i){return n===i?!0:typeof n!=typeof i?!1:n&&i&&typeof n=="object"&&typeof i=="object"?Object.keys(i).every(r=>pl(n[r],i[r])):!1}function jy(n,i){if(n===i)return n;const r=Wg(n)&&Wg(i);if(r||gf(n)&&gf(i)){const u=r?n:Object.keys(n),o=u.length,c=r?i:Object.keys(i),h=c.length,g=r?[]:{},y=new Set(u);let p=0;for(let v=0;v<h;v++){const m=r?v:c[v];(!r&&y.has(m)||r)&&n[m]===void 0&&i[m]===void 0?(g[m]=void 0,p++):(g[m]=jy(n[m],i[m]),g[m]===n[m]&&n[m]!==void 0&&p++)}return o===h&&p===o?n:g}return i}function is(n,i){if(!i||Object.keys(n).length!==Object.keys(i).length)return!1;for(const r in n)if(n[r]!==i[r])return!1;return!0}function Wg(n){return Array.isArray(n)&&n.length===Object.keys(n).length}function gf(n){if(!Ig(n))return!1;const i=n.constructor;if(i===void 0)return!0;const r=i.prototype;return!(!Ig(r)||!r.hasOwnProperty("isPrototypeOf")||Object.getPrototypeOf(n)!==Object.prototype)}function Ig(n){return Object.prototype.toString.call(n)==="[object Object]"}function yb(n){return new Promise(i=>{setTimeout(i,n)})}function pf(n,i,r){return typeof r.structuralSharing=="function"?r.structuralSharing(n,i):r.structuralSharing!==!1?jy(n,i):i}function mb(n,i,r=0){const u=[...n,i];return r&&u.length>r?u.slice(1):u}function vb(n,i,r=0){const u=[i,...n];return r&&u.length>r?u.slice(0,-1):u}var Gf=Symbol();function ky(n,i){return!n.queryFn&&i?.initialPromise?()=>i.initialPromise:!n.queryFn||n.queryFn===Gf?()=>Promise.reject(new Error(`Missing queryFn: '${n.queryHash}'`)):n.queryFn}function Uy(n,i){return typeof n=="function"?n(...i):!!n}var bb=class extends Ja{#e;#t;#n;constructor(){super(),this.#n=n=>{if(!Wi&&window.addEventListener){const i=()=>n();return window.addEventListener("visibilitychange",i,!1),()=>{window.removeEventListener("visibilitychange",i)}}}}onSubscribe(){this.#t||this.setEventListener(this.#n)}onUnsubscribe(){this.hasListeners()||(this.#t?.(),this.#t=void 0)}setEventListener(n){this.#n=n,this.#t?.(),this.#t=n(i=>{typeof i=="boolean"?this.setFocused(i):this.onFocus()})}setFocused(n){this.#e!==n&&(this.#e=n,this.onFocus())}onFocus(){const n=this.isFocused();this.listeners.forEach(i=>{i(n)})}isFocused(){return typeof this.#e=="boolean"?this.#e:globalThis.document?.visibilityState!=="hidden"}},Qf=new bb,_b=class extends Ja{#e=!0;#t;#n;constructor(){super(),this.#n=n=>{if(!Wi&&window.addEventListener){const i=()=>n(!0),r=()=>n(!1);return window.addEventListener("online",i,!1),window.addEventListener("offline",r,!1),()=>{window.removeEventListener("online",i),window.removeEventListener("offline",r)}}}}onSubscribe(){this.#t||this.setEventListener(this.#n)}onUnsubscribe(){this.hasListeners()||(this.#t?.(),this.#t=void 0)}setEventListener(n){this.#n=n,this.#t?.(),this.#t=n(this.setOnline.bind(this))}setOnline(n){this.#e!==n&&(this.#e=n,this.listeners.forEach(r=>{r(n)}))}isOnline(){return this.#e}},as=new _b;function yf(){let n,i;const r=new Promise((o,c)=>{n=o,i=c});r.status="pending",r.catch(()=>{});function u(o){Object.assign(r,o),delete r.resolve,delete r.reject}return r.resolve=o=>{u({status:"fulfilled",value:o}),n(o)},r.reject=o=>{u({status:"rejected",reason:o}),i(o)},r}function xb(n){return Math.min(1e3*2**n,3e4)}function qy(n){return(n??"online")==="online"?as.isOnline():!0}var Hy=class extends Error{constructor(n){super("CancelledError"),this.revert=n?.revert,this.silent=n?.silent}};function Yc(n){return n instanceof Hy}function Ly(n){let i=!1,r=0,u=!1,o;const c=yf(),h=M=>{u||(_(new Hy(M)),n.abort?.())},g=()=>{i=!0},y=()=>{i=!1},p=()=>Qf.isFocused()&&(n.networkMode==="always"||as.isOnline())&&n.canRun(),v=()=>qy(n.networkMode)&&n.canRun(),m=M=>{u||(u=!0,n.onSuccess?.(M),o?.(),c.resolve(M))},_=M=>{u||(u=!0,n.onError?.(M),o?.(),c.reject(M))},x=()=>new Promise(M=>{o=O=>{(u||p())&&M(O)},n.onPause?.()}).then(()=>{o=void 0,u||n.onContinue?.()}),A=()=>{if(u)return;let M;const O=r===0?n.initialPromise:void 0;try{M=O??n.fn()}catch(S){M=Promise.reject(S)}Promise.resolve(M).then(m).catch(S=>{if(u)return;const j=n.retry??(Wi?0:3),H=n.retryDelay??xb,R=typeof H=="function"?H(r,S):H,C=j===!0||typeof j=="number"&&r<j||typeof j=="function"&&j(r,S);if(i||!C){_(S);return}r++,n.onFail?.(r,S),yb(R).then(()=>p()?void 0:x()).then(()=>{i?_(S):A()})})};return{promise:c,cancel:h,continue:()=>(o?.(),c),cancelRetry:g,continueRetry:y,canStart:v,start:()=>(v()?A():x().then(A),c)}}var wb=n=>setTimeout(n,0);function Sb(){let n=[],i=0,r=g=>{g()},u=g=>{g()},o=wb;const c=g=>{i?n.push(g):o(()=>{r(g)})},h=()=>{const g=n;n=[],g.length&&o(()=>{u(()=>{g.forEach(y=>{r(y)})})})};return{batch:g=>{let y;i++;try{y=g()}finally{i--,i||h()}return y},batchCalls:g=>(...y)=>{c(()=>{g(...y)})},schedule:c,setNotifyFunction:g=>{r=g},setBatchNotifyFunction:g=>{u=g},setScheduler:g=>{o=g}}}var ne=Sb(),By=class{#e;destroy(){this.clearGcTimeout()}scheduleGc(){this.clearGcTimeout(),df(this.gcTime)&&(this.#e=setTimeout(()=>{this.optionalRemove()},this.gcTime))}updateGcTime(n){this.gcTime=Math.max(this.gcTime||0,n??(Wi?1/0:300*1e3))}clearGcTimeout(){this.#e&&(clearTimeout(this.#e),this.#e=void 0)}},Ab=class extends By{#e;#t;#n;#i;#a;#l;#u;constructor(n){super(),this.#u=!1,this.#l=n.defaultOptions,this.setOptions(n.options),this.observers=[],this.#i=n.client,this.#n=this.#i.getQueryCache(),this.queryKey=n.queryKey,this.queryHash=n.queryHash,this.#e=Eb(this.options),this.state=n.state??this.#e,this.scheduleGc()}get meta(){return this.options.meta}get promise(){return this.#a?.promise}setOptions(n){this.options={...this.#l,...n},this.updateGcTime(this.options.gcTime)}optionalRemove(){!this.observers.length&&this.state.fetchStatus==="idle"&&this.#n.remove(this)}setData(n,i){const r=pf(this.state.data,n,this.options);return this.#r({data:r,type:"success",dataUpdatedAt:i?.updatedAt,manual:i?.manual}),r}setState(n,i){this.#r({type:"setState",state:n,setStateOptions:i})}cancel(n){const i=this.#a?.promise;return this.#a?.cancel(n),i?i.then(xe).catch(xe):Promise.resolve()}destroy(){super.destroy(),this.cancel({silent:!0})}reset(){this.destroy(),this.setState(this.#e)}isActive(){return this.observers.some(n=>We(n.options.enabled,this)!==!1)}isDisabled(){return this.getObserversCount()>0?!this.isActive():this.options.queryFn===Gf||this.state.dataUpdateCount+this.state.errorUpdateCount===0}isStatic(){return this.getObserversCount()>0?this.observers.some(n=>wi(n.options.staleTime,this)==="static"):!1}isStale(){return this.getObserversCount()>0?this.observers.some(n=>n.getCurrentResult().isStale):this.state.data===void 0||this.state.isInvalidated}isStaleByTime(n=0){return this.state.data===void 0?!0:n==="static"?!1:this.state.isInvalidated?!0:!Dy(this.state.dataUpdatedAt,n)}onFocus(){this.observers.find(i=>i.shouldFetchOnWindowFocus())?.refetch({cancelRefetch:!1}),this.#a?.continue()}onOnline(){this.observers.find(i=>i.shouldFetchOnReconnect())?.refetch({cancelRefetch:!1}),this.#a?.continue()}addObserver(n){this.observers.includes(n)||(this.observers.push(n),this.clearGcTimeout(),this.#n.notify({type:"observerAdded",query:this,observer:n}))}removeObserver(n){this.observers.includes(n)&&(this.observers=this.observers.filter(i=>i!==n),this.observers.length||(this.#a&&(this.#u?this.#a.cancel({revert:!0}):this.#a.cancelRetry()),this.scheduleGc()),this.#n.notify({type:"observerRemoved",query:this,observer:n}))}getObserversCount(){return this.observers.length}invalidate(){this.state.isInvalidated||this.#r({type:"invalidate"})}fetch(n,i){if(this.state.fetchStatus!=="idle"){if(this.state.data!==void 0&&i?.cancelRefetch)this.cancel({silent:!0});else if(this.#a)return this.#a.continueRetry(),this.#a.promise}if(n&&this.setOptions(n),!this.options.queryFn){const y=this.observers.find(p=>p.options.queryFn);y&&this.setOptions(y.options)}const r=new AbortController,u=y=>{Object.defineProperty(y,"signal",{enumerable:!0,get:()=>(this.#u=!0,r.signal)})},o=()=>{const y=ky(this.options,i),v=(()=>{const m={client:this.#i,queryKey:this.queryKey,meta:this.meta};return u(m),m})();return this.#u=!1,this.options.persister?this.options.persister(y,v,this):y(v)},h=(()=>{const y={fetchOptions:i,options:this.options,queryKey:this.queryKey,client:this.#i,state:this.state,fetchFn:o};return u(y),y})();this.options.behavior?.onFetch(h,this),this.#t=this.state,(this.state.fetchStatus==="idle"||this.state.fetchMeta!==h.fetchOptions?.meta)&&this.#r({type:"fetch",meta:h.fetchOptions?.meta});const g=y=>{Yc(y)&&y.silent||this.#r({type:"error",error:y}),Yc(y)||(this.#n.config.onError?.(y,this),this.#n.config.onSettled?.(this.state.data,y,this)),this.scheduleGc()};return this.#a=Ly({initialPromise:i?.initialPromise,fn:h.fetchFn,abort:r.abort.bind(r),onSuccess:y=>{if(y===void 0){g(new Error(`${this.queryHash} data is undefined`));return}try{this.setData(y)}catch(p){g(p);return}this.#n.config.onSuccess?.(y,this),this.#n.config.onSettled?.(y,this.state.error,this),this.scheduleGc()},onError:g,onFail:(y,p)=>{this.#r({type:"failed",failureCount:y,error:p})},onPause:()=>{this.#r({type:"pause"})},onContinue:()=>{this.#r({type:"continue"})},retry:h.options.retry,retryDelay:h.options.retryDelay,networkMode:h.options.networkMode,canRun:()=>!0}),this.#a.start()}#r(n){const i=r=>{switch(n.type){case"failed":return{...r,fetchFailureCount:n.failureCount,fetchFailureReason:n.error};case"pause":return{...r,fetchStatus:"paused"};case"continue":return{...r,fetchStatus:"fetching"};case"fetch":return{...r,...Gy(r.data,this.options),fetchMeta:n.meta??null};case"success":return this.#t=void 0,{...r,data:n.data,dataUpdateCount:r.dataUpdateCount+1,dataUpdatedAt:n.dataUpdatedAt??Date.now(),error:null,isInvalidated:!1,status:"success",...!n.manual&&{fetchStatus:"idle",fetchFailureCount:0,fetchFailureReason:null}};case"error":const u=n.error;return Yc(u)&&u.revert&&this.#t?{...this.#t,fetchStatus:"idle"}:{...r,error:u,errorUpdateCount:r.errorUpdateCount+1,errorUpdatedAt:Date.now(),fetchFailureCount:r.fetchFailureCount+1,fetchFailureReason:u,fetchStatus:"idle",status:"error"};case"invalidate":return{...r,isInvalidated:!0};case"setState":return{...r,...n.state}}};this.state=i(this.state),ne.batch(()=>{this.observers.forEach(r=>{r.onQueryUpdate()}),this.#n.notify({query:this,type:"updated",action:n})})}};function Gy(n,i){return{fetchFailureCount:0,fetchFailureReason:null,fetchStatus:qy(i.networkMode)?"fetching":"paused",...n===void 0&&{error:null,status:"pending"}}}function Eb(n){const i=typeof n.initialData=="function"?n.initialData():n.initialData,r=i!==void 0,u=r?typeof n.initialDataUpdatedAt=="function"?n.initialDataUpdatedAt():n.initialDataUpdatedAt:0;return{data:i,dataUpdateCount:0,dataUpdatedAt:r?u??Date.now():0,error:null,errorUpdateCount:0,errorUpdatedAt:0,fetchFailureCount:0,fetchFailureReason:null,fetchMeta:null,isInvalidated:!1,status:r?"success":"pending",fetchStatus:"idle"}}var Tb=class extends Ja{constructor(n={}){super(),this.config=n,this.#e=new Map}#e;build(n,i,r){const u=i.queryKey,o=i.queryHash??Bf(u,i);let c=this.get(o);return c||(c=new Ab({client:n,queryKey:u,queryHash:o,options:n.defaultQueryOptions(i),state:r,defaultOptions:n.getQueryDefaults(u)}),this.add(c)),c}add(n){this.#e.has(n.queryHash)||(this.#e.set(n.queryHash,n),this.notify({type:"added",query:n}))}remove(n){const i=this.#e.get(n.queryHash);i&&(n.destroy(),i===n&&this.#e.delete(n.queryHash),this.notify({type:"removed",query:n}))}clear(){ne.batch(()=>{this.getAll().forEach(n=>{this.remove(n)})})}get(n){return this.#e.get(n)}getAll(){return[...this.#e.values()]}find(n){const i={exact:!0,...n};return this.getAll().find(r=>Pg(i,r))}findAll(n={}){const i=this.getAll();return Object.keys(n).length>0?i.filter(r=>Pg(n,r)):i}notify(n){ne.batch(()=>{this.listeners.forEach(i=>{i(n)})})}onFocus(){ne.batch(()=>{this.getAll().forEach(n=>{n.onFocus()})})}onOnline(){ne.batch(()=>{this.getAll().forEach(n=>{n.onOnline()})})}},Ob=class extends By{#e;#t;#n;constructor(n){super(),this.mutationId=n.mutationId,this.#t=n.mutationCache,this.#e=[],this.state=n.state||Qy(),this.setOptions(n.options),this.scheduleGc()}setOptions(n){this.options=n,this.updateGcTime(this.options.gcTime)}get meta(){return this.options.meta}addObserver(n){this.#e.includes(n)||(this.#e.push(n),this.clearGcTimeout(),this.#t.notify({type:"observerAdded",mutation:this,observer:n}))}removeObserver(n){this.#e=this.#e.filter(i=>i!==n),this.scheduleGc(),this.#t.notify({type:"observerRemoved",mutation:this,observer:n})}optionalRemove(){this.#e.length||(this.state.status==="pending"?this.scheduleGc():this.#t.remove(this))}continue(){return this.#n?.continue()??this.execute(this.state.variables)}async execute(n){const i=()=>{this.#i({type:"continue"})};this.#n=Ly({fn:()=>this.options.mutationFn?this.options.mutationFn(n):Promise.reject(new Error("No mutationFn found")),onFail:(o,c)=>{this.#i({type:"failed",failureCount:o,error:c})},onPause:()=>{this.#i({type:"pause"})},onContinue:i,retry:this.options.retry??0,retryDelay:this.options.retryDelay,networkMode:this.options.networkMode,canRun:()=>this.#t.canRun(this)});const r=this.state.status==="pending",u=!this.#n.canStart();try{if(r)i();else{this.#i({type:"pending",variables:n,isPaused:u}),await this.#t.config.onMutate?.(n,this);const c=await this.options.onMutate?.(n);c!==this.state.context&&this.#i({type:"pending",context:c,variables:n,isPaused:u})}const o=await this.#n.start();return await this.#t.config.onSuccess?.(o,n,this.state.context,this),await this.options.onSuccess?.(o,n,this.state.context),await this.#t.config.onSettled?.(o,null,this.state.variables,this.state.context,this),await this.options.onSettled?.(o,null,n,this.state.context),this.#i({type:"success",data:o}),o}catch(o){try{throw await this.#t.config.onError?.(o,n,this.state.context,this),await this.options.onError?.(o,n,this.state.context),await this.#t.config.onSettled?.(void 0,o,this.state.variables,this.state.context,this),await this.options.onSettled?.(void 0,o,n,this.state.context),o}finally{this.#i({type:"error",error:o})}}finally{this.#t.runNext(this)}}#i(n){const i=r=>{switch(n.type){case"failed":return{...r,failureCount:n.failureCount,failureReason:n.error};case"pause":return{...r,isPaused:!0};case"continue":return{...r,isPaused:!1};case"pending":return{...r,context:n.context,data:void 0,failureCount:0,failureReason:null,error:null,isPaused:n.isPaused,status:"pending",variables:n.variables,submittedAt:Date.now()};case"success":return{...r,data:n.data,failureCount:0,failureReason:null,error:null,status:"success",isPaused:!1};case"error":return{...r,data:void 0,error:n.error,failureCount:r.failureCount+1,failureReason:n.error,isPaused:!1,status:"error"}}};this.state=i(this.state),ne.batch(()=>{this.#e.forEach(r=>{r.onMutationUpdate(n)}),this.#t.notify({mutation:this,type:"updated",action:n})})}};function Qy(){return{context:void 0,data:void 0,error:null,failureCount:0,failureReason:null,isPaused:!1,status:"idle",variables:void 0,submittedAt:0}}var Mb=class extends Ja{constructor(n={}){super(),this.config=n,this.#e=new Set,this.#t=new Map,this.#n=0}#e;#t;#n;build(n,i,r){const u=new Ob({mutationCache:this,mutationId:++this.#n,options:n.defaultMutationOptions(i),state:r});return this.add(u),u}add(n){this.#e.add(n);const i=Yu(n);if(typeof i=="string"){const r=this.#t.get(i);r?r.push(n):this.#t.set(i,[n])}this.notify({type:"added",mutation:n})}remove(n){if(this.#e.delete(n)){const i=Yu(n);if(typeof i=="string"){const r=this.#t.get(i);if(r)if(r.length>1){const u=r.indexOf(n);u!==-1&&r.splice(u,1)}else r[0]===n&&this.#t.delete(i)}}this.notify({type:"removed",mutation:n})}canRun(n){const i=Yu(n);if(typeof i=="string"){const u=this.#t.get(i)?.find(o=>o.state.status==="pending");return!u||u===n}else return!0}runNext(n){const i=Yu(n);return typeof i=="string"?this.#t.get(i)?.find(u=>u!==n&&u.state.isPaused)?.continue()??Promise.resolve():Promise.resolve()}clear(){ne.batch(()=>{this.#e.forEach(n=>{this.notify({type:"removed",mutation:n})}),this.#e.clear(),this.#t.clear()})}getAll(){return Array.from(this.#e)}find(n){const i={exact:!0,...n};return this.getAll().find(r=>Jg(i,r))}findAll(n={}){return this.getAll().filter(i=>Jg(n,i))}notify(n){ne.batch(()=>{this.listeners.forEach(i=>{i(n)})})}resumePausedMutations(){const n=this.getAll().filter(i=>i.state.isPaused);return ne.batch(()=>Promise.all(n.map(i=>i.continue().catch(xe))))}};function Yu(n){return n.options.scope?.id}function tp(n){return{onFetch:(i,r)=>{const u=i.options,o=i.fetchOptions?.meta?.fetchMore?.direction,c=i.state.data?.pages||[],h=i.state.data?.pageParams||[];let g={pages:[],pageParams:[]},y=0;const p=async()=>{let v=!1;const m=A=>{Object.defineProperty(A,"signal",{enumerable:!0,get:()=>(i.signal.aborted?v=!0:i.signal.addEventListener("abort",()=>{v=!0}),i.signal)})},_=ky(i.options,i.fetchOptions),x=async(A,M,O)=>{if(v)return Promise.reject();if(M==null&&A.pages.length)return Promise.resolve(A);const j=(()=>{const q={client:i.client,queryKey:i.queryKey,pageParam:M,direction:O?"backward":"forward",meta:i.options.meta};return m(q),q})(),H=await _(j),{maxPages:R}=i.options,C=O?vb:mb;return{pages:C(A.pages,H,R),pageParams:C(A.pageParams,M,R)}};if(o&&c.length){const A=o==="backward",M=A?Cb:ep,O={pages:c,pageParams:h},S=M(u,O);g=await x(O,S,A)}else{const A=n??c.length;do{const M=y===0?h[0]??u.initialPageParam:ep(u,g);if(y>0&&M==null)break;g=await x(g,M),y++}while(y<A)}return g};i.options.persister?i.fetchFn=()=>i.options.persister?.(p,{client:i.client,queryKey:i.queryKey,meta:i.options.meta,signal:i.signal},r):i.fetchFn=p}}}function ep(n,{pages:i,pageParams:r}){const u=i.length-1;return i.length>0?n.getNextPageParam(i[u],i,r[u],r):void 0}function Cb(n,{pages:i,pageParams:r}){return i.length>0?n.getPreviousPageParam?.(i[0],i,r[0],r):void 0}var Nb=class{#e;#t;#n;#i;#a;#l;#u;#r;constructor(n={}){this.#e=n.queryCache||new Tb,this.#t=n.mutationCache||new Mb,this.#n=n.defaultOptions||{},this.#i=new Map,this.#a=new Map,this.#l=0}mount(){this.#l++,this.#l===1&&(this.#u=Qf.subscribe(async n=>{n&&(await this.resumePausedMutations(),this.#e.onFocus())}),this.#r=as.subscribe(async n=>{n&&(await this.resumePausedMutations(),this.#e.onOnline())}))}unmount(){this.#l--,this.#l===0&&(this.#u?.(),this.#u=void 0,this.#r?.(),this.#r=void 0)}isFetching(n){return this.#e.findAll({...n,fetchStatus:"fetching"}).length}isMutating(n){return this.#t.findAll({...n,status:"pending"}).length}getQueryData(n){const i=this.defaultQueryOptions({queryKey:n});return this.#e.get(i.queryHash)?.state.data}ensureQueryData(n){const i=this.defaultQueryOptions(n),r=this.#e.build(this,i),u=r.state.data;return u===void 0?this.fetchQuery(n):(n.revalidateIfStale&&r.isStaleByTime(wi(i.staleTime,r))&&this.prefetchQuery(i),Promise.resolve(u))}getQueriesData(n){return this.#e.findAll(n).map(({queryKey:i,state:r})=>{const u=r.data;return[i,u]})}setQueryData(n,i,r){const u=this.defaultQueryOptions({queryKey:n}),c=this.#e.get(u.queryHash)?.state.data,h=pb(i,c);if(h!==void 0)return this.#e.build(this,u).setData(h,{...r,manual:!0})}setQueriesData(n,i,r){return ne.batch(()=>this.#e.findAll(n).map(({queryKey:u})=>[u,this.setQueryData(u,i,r)]))}getQueryState(n){const i=this.defaultQueryOptions({queryKey:n});return this.#e.get(i.queryHash)?.state}removeQueries(n){const i=this.#e;ne.batch(()=>{i.findAll(n).forEach(r=>{i.remove(r)})})}resetQueries(n,i){const r=this.#e;return ne.batch(()=>(r.findAll(n).forEach(u=>{u.reset()}),this.refetchQueries({type:"active",...n},i)))}cancelQueries(n,i={}){const r={revert:!0,...i},u=ne.batch(()=>this.#e.findAll(n).map(o=>o.cancel(r)));return Promise.all(u).then(xe).catch(xe)}invalidateQueries(n,i={}){return ne.batch(()=>(this.#e.findAll(n).forEach(r=>{r.invalidate()}),n?.refetchType==="none"?Promise.resolve():this.refetchQueries({...n,type:n?.refetchType??n?.type??"active"},i)))}refetchQueries(n,i={}){const r={...i,cancelRefetch:i.cancelRefetch??!0},u=ne.batch(()=>this.#e.findAll(n).filter(o=>!o.isDisabled()&&!o.isStatic()).map(o=>{let c=o.fetch(void 0,r);return r.throwOnError||(c=c.catch(xe)),o.state.fetchStatus==="paused"?Promise.resolve():c}));return Promise.all(u).then(xe)}fetchQuery(n){const i=this.defaultQueryOptions(n);i.retry===void 0&&(i.retry=!1);const r=this.#e.build(this,i);return r.isStaleByTime(wi(i.staleTime,r))?r.fetch(i):Promise.resolve(r.state.data)}prefetchQuery(n){return this.fetchQuery(n).then(xe).catch(xe)}fetchInfiniteQuery(n){return n.behavior=tp(n.pages),this.fetchQuery(n)}prefetchInfiniteQuery(n){return this.fetchInfiniteQuery(n).then(xe).catch(xe)}ensureInfiniteQueryData(n){return n.behavior=tp(n.pages),this.ensureQueryData(n)}resumePausedMutations(){return as.isOnline()?this.#t.resumePausedMutations():Promise.resolve()}getQueryCache(){return this.#e}getMutationCache(){return this.#t}getDefaultOptions(){return this.#n}setDefaultOptions(n){this.#n=n}setQueryDefaults(n,i){this.#i.set(Ii(n),{queryKey:n,defaultOptions:i})}getQueryDefaults(n){const i=[...this.#i.values()],r={};return i.forEach(u=>{pl(n,u.queryKey)&&Object.assign(r,u.defaultOptions)}),r}setMutationDefaults(n,i){this.#a.set(Ii(n),{mutationKey:n,defaultOptions:i})}getMutationDefaults(n){const i=[...this.#a.values()],r={};return i.forEach(u=>{pl(n,u.mutationKey)&&Object.assign(r,u.defaultOptions)}),r}defaultQueryOptions(n){if(n._defaulted)return n;const i={...this.#n.queries,...this.getQueryDefaults(n.queryKey),...n,_defaulted:!0};return i.queryHash||(i.queryHash=Bf(i.queryKey,i)),i.refetchOnReconnect===void 0&&(i.refetchOnReconnect=i.networkMode!=="always"),i.throwOnError===void 0&&(i.throwOnError=!!i.suspense),!i.networkMode&&i.persister&&(i.networkMode="offlineFirst"),i.queryFn===Gf&&(i.enabled=!1),i}defaultMutationOptions(n){return n?._defaulted?n:{...this.#n.mutations,...n?.mutationKey&&this.getMutationDefaults(n.mutationKey),...n,_defaulted:!0}}clear(){this.#e.clear(),this.#t.clear()}},zb=class extends Ja{constructor(n,i){super(),this.options=i,this.#e=n,this.#r=null,this.#u=yf(),this.options.experimental_prefetchInRender||this.#u.reject(new Error("experimental_prefetchInRender feature flag is not enabled")),this.bindMethods(),this.setOptions(i)}#e;#t=void 0;#n=void 0;#i=void 0;#a;#l;#u;#r;#p;#h;#d;#o;#c;#s;#g=new Set;bindMethods(){this.refetch=this.refetch.bind(this)}onSubscribe(){this.listeners.size===1&&(this.#t.addObserver(this),np(this.#t,this.options)?this.#f():this.updateResult(),this.#b())}onUnsubscribe(){this.hasListeners()||this.destroy()}shouldFetchOnReconnect(){return mf(this.#t,this.options,this.options.refetchOnReconnect)}shouldFetchOnWindowFocus(){return mf(this.#t,this.options,this.options.refetchOnWindowFocus)}destroy(){this.listeners=new Set,this.#_(),this.#x(),this.#t.removeObserver(this)}setOptions(n){const i=this.options,r=this.#t;if(this.options=this.#e.defaultQueryOptions(n),this.options.enabled!==void 0&&typeof this.options.enabled!="boolean"&&typeof this.options.enabled!="function"&&typeof We(this.options.enabled,this.#t)!="boolean")throw new Error("Expected enabled to be a boolean or a callback that returns a boolean");this.#w(),this.#t.setOptions(this.options),i._defaulted&&!is(this.options,i)&&this.#e.getQueryCache().notify({type:"observerOptionsUpdated",query:this.#t,observer:this});const u=this.hasListeners();u&&ip(this.#t,r,this.options,i)&&this.#f(),this.updateResult(),u&&(this.#t!==r||We(this.options.enabled,this.#t)!==We(i.enabled,this.#t)||wi(this.options.staleTime,this.#t)!==wi(i.staleTime,this.#t))&&this.#y();const o=this.#m();u&&(this.#t!==r||We(this.options.enabled,this.#t)!==We(i.enabled,this.#t)||o!==this.#s)&&this.#v(o)}getOptimisticResult(n){const i=this.#e.getQueryCache().build(this.#e,n),r=this.createResult(i,n);return Db(this,r)&&(this.#i=r,this.#l=this.options,this.#a=this.#t.state),r}getCurrentResult(){return this.#i}trackResult(n,i){return new Proxy(n,{get:(r,u)=>(this.trackProp(u),i?.(u),Reflect.get(r,u))})}trackProp(n){this.#g.add(n)}getCurrentQuery(){return this.#t}refetch({...n}={}){return this.fetch({...n})}fetchOptimistic(n){const i=this.#e.defaultQueryOptions(n),r=this.#e.getQueryCache().build(this.#e,i);return r.fetch().then(()=>this.createResult(r,i))}fetch(n){return this.#f({...n,cancelRefetch:n.cancelRefetch??!0}).then(()=>(this.updateResult(),this.#i))}#f(n){this.#w();let i=this.#t.fetch(this.options,n);return n?.throwOnError||(i=i.catch(xe)),i}#y(){this.#_();const n=wi(this.options.staleTime,this.#t);if(Wi||this.#i.isStale||!df(n))return;const r=Dy(this.#i.dataUpdatedAt,n)+1;this.#o=setTimeout(()=>{this.#i.isStale||this.updateResult()},r)}#m(){return(typeof this.options.refetchInterval=="function"?this.options.refetchInterval(this.#t):this.options.refetchInterval)??!1}#v(n){this.#x(),this.#s=n,!(Wi||We(this.options.enabled,this.#t)===!1||!df(this.#s)||this.#s===0)&&(this.#c=setInterval(()=>{(this.options.refetchIntervalInBackground||Qf.isFocused())&&this.#f()},this.#s))}#b(){this.#y(),this.#v(this.#m())}#_(){this.#o&&(clearTimeout(this.#o),this.#o=void 0)}#x(){this.#c&&(clearInterval(this.#c),this.#c=void 0)}createResult(n,i){const r=this.#t,u=this.options,o=this.#i,c=this.#a,h=this.#l,y=n!==r?n.state:this.#n,{state:p}=n;let v={...p},m=!1,_;if(i._optimisticResults){const Q=this.hasListeners(),tt=!Q&&np(n,i),F=Q&&ip(n,r,i,u);(tt||F)&&(v={...v,...Gy(p.data,n.options)}),i._optimisticResults==="isRestoring"&&(v.fetchStatus="idle")}let{error:x,errorUpdatedAt:A,status:M}=v;_=v.data;let O=!1;if(i.placeholderData!==void 0&&_===void 0&&M==="pending"){let Q;o?.isPlaceholderData&&i.placeholderData===h?.placeholderData?(Q=o.data,O=!0):Q=typeof i.placeholderData=="function"?i.placeholderData(this.#d?.state.data,this.#d):i.placeholderData,Q!==void 0&&(M="success",_=pf(o?.data,Q,i),m=!0)}if(i.select&&_!==void 0&&!O)if(o&&_===c?.data&&i.select===this.#p)_=this.#h;else try{this.#p=i.select,_=i.select(_),_=pf(o?.data,_,i),this.#h=_,this.#r=null}catch(Q){this.#r=Q}this.#r&&(x=this.#r,_=this.#h,A=Date.now(),M="error");const S=v.fetchStatus==="fetching",j=M==="pending",H=M==="error",R=j&&S,C=_!==void 0,U={status:M,fetchStatus:v.fetchStatus,isPending:j,isSuccess:M==="success",isError:H,isInitialLoading:R,isLoading:R,data:_,dataUpdatedAt:v.dataUpdatedAt,error:x,errorUpdatedAt:A,failureCount:v.fetchFailureCount,failureReason:v.fetchFailureReason,errorUpdateCount:v.errorUpdateCount,isFetched:v.dataUpdateCount>0||v.errorUpdateCount>0,isFetchedAfterMount:v.dataUpdateCount>y.dataUpdateCount||v.errorUpdateCount>y.errorUpdateCount,isFetching:S,isRefetching:S&&!j,isLoadingError:H&&!C,isPaused:v.fetchStatus==="paused",isPlaceholderData:m,isRefetchError:H&&C,isStale:Yf(n,i),refetch:this.refetch,promise:this.#u,isEnabled:We(i.enabled,n)!==!1};if(this.options.experimental_prefetchInRender){const Q=K=>{U.status==="error"?K.reject(U.error):U.data!==void 0&&K.resolve(U.data)},tt=()=>{const K=this.#u=U.promise=yf();Q(K)},F=this.#u;switch(F.status){case"pending":n.queryHash===r.queryHash&&Q(F);break;case"fulfilled":(U.status==="error"||U.data!==F.value)&&tt();break;case"rejected":(U.status!=="error"||U.error!==F.reason)&&tt();break}}return U}updateResult(){const n=this.#i,i=this.createResult(this.#t,this.options);if(this.#a=this.#t.state,this.#l=this.options,this.#a.data!==void 0&&(this.#d=this.#t),is(i,n))return;this.#i=i;const r=()=>{if(!n)return!0;const{notifyOnChangeProps:u}=this.options,o=typeof u=="function"?u():u;if(o==="all"||!o&&!this.#g.size)return!0;const c=new Set(o??this.#g);return this.options.throwOnError&&c.add("error"),Object.keys(this.#i).some(h=>{const g=h;return this.#i[g]!==n[g]&&c.has(g)})};this.#S({listeners:r()})}#w(){const n=this.#e.getQueryCache().build(this.#e,this.options);if(n===this.#t)return;const i=this.#t;this.#t=n,this.#n=n.state,this.hasListeners()&&(i?.removeObserver(this),n.addObserver(this))}onQueryUpdate(){this.updateResult(),this.hasListeners()&&this.#b()}#S(n){ne.batch(()=>{n.listeners&&this.listeners.forEach(i=>{i(this.#i)}),this.#e.getQueryCache().notify({query:this.#t,type:"observerResultsUpdated"})})}};function Rb(n,i){return We(i.enabled,n)!==!1&&n.state.data===void 0&&!(n.state.status==="error"&&i.retryOnMount===!1)}function np(n,i){return Rb(n,i)||n.state.data!==void 0&&mf(n,i,i.refetchOnMount)}function mf(n,i,r){if(We(i.enabled,n)!==!1&&wi(i.staleTime,n)!=="static"){const u=typeof r=="function"?r(n):r;return u==="always"||u!==!1&&Yf(n,i)}return!1}function ip(n,i,r,u){return(n!==i||We(u.enabled,n)===!1)&&(!r.suspense||n.state.status!=="error")&&Yf(n,r)}function Yf(n,i){return We(i.enabled,n)!==!1&&n.isStaleByTime(wi(i.staleTime,n))}function Db(n,i){return!is(n.getCurrentResult(),i)}var jb=class extends Ja{#e;#t=void 0;#n;#i;constructor(i,r){super(),this.#e=i,this.setOptions(r),this.bindMethods(),this.#a()}bindMethods(){this.mutate=this.mutate.bind(this),this.reset=this.reset.bind(this)}setOptions(i){const r=this.options;this.options=this.#e.defaultMutationOptions(i),is(this.options,r)||this.#e.getMutationCache().notify({type:"observerOptionsUpdated",mutation:this.#n,observer:this}),r?.mutationKey&&this.options.mutationKey&&Ii(r.mutationKey)!==Ii(this.options.mutationKey)?this.reset():this.#n?.state.status==="pending"&&this.#n.setOptions(this.options)}onUnsubscribe(){this.hasListeners()||this.#n?.removeObserver(this)}onMutationUpdate(i){this.#a(),this.#l(i)}getCurrentResult(){return this.#t}reset(){this.#n?.removeObserver(this),this.#n=void 0,this.#a(),this.#l()}mutate(i,r){return this.#i=r,this.#n?.removeObserver(this),this.#n=this.#e.getMutationCache().build(this.#e,this.options),this.#n.addObserver(this),this.#n.execute(i)}#a(){const i=this.#n?.state??Qy();this.#t={...i,isPending:i.status==="pending",isSuccess:i.status==="success",isError:i.status==="error",isIdle:i.status==="idle",mutate:this.mutate,reset:this.reset}}#l(i){ne.batch(()=>{if(this.#i&&this.hasListeners()){const r=this.#t.variables,u=this.#t.context;i?.type==="success"?(this.#i.onSuccess?.(i.data,r,u),this.#i.onSettled?.(i.data,null,r,u)):i?.type==="error"&&(this.#i.onError?.(i.error,r,u),this.#i.onSettled?.(void 0,i.error,r,u))}this.listeners.forEach(r=>{r(this.#t)})})}},Xc={exports:{}},xt={};/**
|
|
10
|
-
* @license React
|
|
11
|
-
* react.production.js
|
|
12
|
-
*
|
|
13
|
-
* Copyright (c) Meta Platforms, Inc. and affiliates.
|
|
14
|
-
*
|
|
15
|
-
* This source code is licensed under the MIT license found in the
|
|
16
|
-
* LICENSE file in the root directory of this source tree.
|
|
17
|
-
*/var ap;function kb(){if(ap)return xt;ap=1;var n=Symbol.for("react.transitional.element"),i=Symbol.for("react.portal"),r=Symbol.for("react.fragment"),u=Symbol.for("react.strict_mode"),o=Symbol.for("react.profiler"),c=Symbol.for("react.consumer"),h=Symbol.for("react.context"),g=Symbol.for("react.forward_ref"),y=Symbol.for("react.suspense"),p=Symbol.for("react.memo"),v=Symbol.for("react.lazy"),m=Symbol.iterator;function _(T){return T===null||typeof T!="object"?null:(T=m&&T[m]||T["@@iterator"],typeof T=="function"?T:null)}var x={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},A=Object.assign,M={};function O(T,$,nt){this.props=T,this.context=$,this.refs=M,this.updater=nt||x}O.prototype.isReactComponent={},O.prototype.setState=function(T,$){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,$,"setState")},O.prototype.forceUpdate=function(T){this.updater.enqueueForceUpdate(this,T,"forceUpdate")};function S(){}S.prototype=O.prototype;function j(T,$,nt){this.props=T,this.context=$,this.refs=M,this.updater=nt||x}var H=j.prototype=new S;H.constructor=j,A(H,O.prototype),H.isPureReactComponent=!0;var R=Array.isArray,C={H:null,A:null,T:null,S:null,V:null},q=Object.prototype.hasOwnProperty;function U(T,$,nt,at,st,yt){return nt=yt.ref,{$$typeof:n,type:T,key:$,ref:nt!==void 0?nt:null,props:yt}}function Q(T,$){return U(T.type,$,void 0,void 0,void 0,T.props)}function tt(T){return typeof T=="object"&&T!==null&&T.$$typeof===n}function F(T){var $={"=":"=0",":":"=2"};return"$"+T.replace(/[=:]/g,function(nt){return $[nt]})}var K=/\/+/g;function it(T,$){return typeof T=="object"&&T!==null&&T.key!=null?F(""+T.key):$.toString(36)}function ct(){}function L(T){switch(T.status){case"fulfilled":return T.value;case"rejected":throw T.reason;default:switch(typeof T.status=="string"?T.then(ct,ct):(T.status="pending",T.then(function($){T.status==="pending"&&(T.status="fulfilled",T.value=$)},function($){T.status==="pending"&&(T.status="rejected",T.reason=$)})),T.status){case"fulfilled":return T.value;case"rejected":throw T.reason}}throw T}function J(T,$,nt,at,st){var yt=typeof T;(yt==="undefined"||yt==="boolean")&&(T=null);var ht=!1;if(T===null)ht=!0;else switch(yt){case"bigint":case"string":case"number":ht=!0;break;case"object":switch(T.$$typeof){case n:case i:ht=!0;break;case v:return ht=T._init,J(ht(T._payload),$,nt,at,st)}}if(ht)return st=st(T),ht=at===""?"."+it(T,0):at,R(st)?(nt="",ht!=null&&(nt=ht.replace(K,"$&/")+"/"),J(st,$,nt,"",function(ve){return ve})):st!=null&&(tt(st)&&(st=Q(st,nt+(st.key==null||T&&T.key===st.key?"":(""+st.key).replace(K,"$&/")+"/")+ht)),$.push(st)),1;ht=0;var Ct=at===""?".":at+":";if(R(T))for(var At=0;At<T.length;At++)at=T[At],yt=Ct+it(at,At),ht+=J(at,$,nt,yt,st);else if(At=_(T),typeof At=="function")for(T=At.call(T),At=0;!(at=T.next()).done;)at=at.value,yt=Ct+it(at,At++),ht+=J(at,$,nt,yt,st);else if(yt==="object"){if(typeof T.then=="function")return J(L(T),$,nt,at,st);throw $=String(T),Error("Objects are not valid as a React child (found: "+($==="[object Object]"?"object with keys {"+Object.keys(T).join(", ")+"}":$)+"). If you meant to render a collection of children, use an array instead.")}return ht}function N(T,$,nt){if(T==null)return T;var at=[],st=0;return J(T,at,"","",function(yt){return $.call(nt,yt,st++)}),at}function Z(T){if(T._status===-1){var $=T._result;$=$(),$.then(function(nt){(T._status===0||T._status===-1)&&(T._status=1,T._result=nt)},function(nt){(T._status===0||T._status===-1)&&(T._status=2,T._result=nt)}),T._status===-1&&(T._status=0,T._result=$)}if(T._status===1)return T._result.default;throw T._result}var et=typeof reportError=="function"?reportError:function(T){if(typeof window=="object"&&typeof window.ErrorEvent=="function"){var $=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($))return}else if(typeof process=="object"&&typeof process.emit=="function"){process.emit("uncaughtException",T);return}console.error(T)};function ut(){}return xt.Children={map:N,forEach:function(T,$,nt){N(T,function(){$.apply(this,arguments)},nt)},count:function(T){var $=0;return N(T,function(){$++}),$},toArray:function(T){return N(T,function($){return $})||[]},only:function(T){if(!tt(T))throw Error("React.Children.only expected to receive a single React element child.");return T}},xt.Component=O,xt.Fragment=r,xt.Profiler=o,xt.PureComponent=j,xt.StrictMode=u,xt.Suspense=y,xt.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE=C,xt.__COMPILER_RUNTIME={__proto__:null,c:function(T){return C.H.useMemoCache(T)}},xt.cache=function(T){return function(){return T.apply(null,arguments)}},xt.cloneElement=function(T,$,nt){if(T==null)throw Error("The argument must be a React element, but you passed "+T+".");var at=A({},T.props),st=T.key,yt=void 0;if($!=null)for(ht in $.ref!==void 0&&(yt=void 0),$.key!==void 0&&(st=""+$.key),$)!q.call($,ht)||ht==="key"||ht==="__self"||ht==="__source"||ht==="ref"&&$.ref===void 0||(at[ht]=$[ht]);var ht=arguments.length-2;if(ht===1)at.children=nt;else if(1<ht){for(var Ct=Array(ht),At=0;At<ht;At++)Ct[At]=arguments[At+2];at.children=Ct}return U(T.type,st,void 0,void 0,yt,at)},xt.createContext=function(T){return T={$$typeof:h,_currentValue:T,_currentValue2:T,_threadCount:0,Provider:null,Consumer:null},T.Provider=T,T.Consumer={$$typeof:c,_context:T},T},xt.createElement=function(T,$,nt){var at,st={},yt=null;if($!=null)for(at in $.key!==void 0&&(yt=""+$.key),$)q.call($,at)&&at!=="key"&&at!=="__self"&&at!=="__source"&&(st[at]=$[at]);var ht=arguments.length-2;if(ht===1)st.children=nt;else if(1<ht){for(var Ct=Array(ht),At=0;At<ht;At++)Ct[At]=arguments[At+2];st.children=Ct}if(T&&T.defaultProps)for(at in ht=T.defaultProps,ht)st[at]===void 0&&(st[at]=ht[at]);return U(T,yt,void 0,void 0,null,st)},xt.createRef=function(){return{current:null}},xt.forwardRef=function(T){return{$$typeof:g,render:T}},xt.isValidElement=tt,xt.lazy=function(T){return{$$typeof:v,_payload:{_status:-1,_result:T},_init:Z}},xt.memo=function(T,$){return{$$typeof:p,type:T,compare:$===void 0?null:$}},xt.startTransition=function(T){var $=C.T,nt={};C.T=nt;try{var at=T(),st=C.S;st!==null&&st(nt,at),typeof at=="object"&&at!==null&&typeof at.then=="function"&&at.then(ut,et)}catch(yt){et(yt)}finally{C.T=$}},xt.unstable_useCacheRefresh=function(){return C.H.useCacheRefresh()},xt.use=function(T){return C.H.use(T)},xt.useActionState=function(T,$,nt){return C.H.useActionState(T,$,nt)},xt.useCallback=function(T,$){return C.H.useCallback(T,$)},xt.useContext=function(T){return C.H.useContext(T)},xt.useDebugValue=function(){},xt.useDeferredValue=function(T,$){return C.H.useDeferredValue(T,$)},xt.useEffect=function(T,$,nt){var at=C.H;if(typeof nt=="function")throw Error("useEffect CRUD overload is not enabled in this build of React.");return at.useEffect(T,$)},xt.useId=function(){return C.H.useId()},xt.useImperativeHandle=function(T,$,nt){return C.H.useImperativeHandle(T,$,nt)},xt.useInsertionEffect=function(T,$){return C.H.useInsertionEffect(T,$)},xt.useLayoutEffect=function(T,$){return C.H.useLayoutEffect(T,$)},xt.useMemo=function(T,$){return C.H.useMemo(T,$)},xt.useOptimistic=function(T,$){return C.H.useOptimistic(T,$)},xt.useReducer=function(T,$,nt){return C.H.useReducer(T,$,nt)},xt.useRef=function(T){return C.H.useRef(T)},xt.useState=function(T){return C.H.useState(T)},xt.useSyncExternalStore=function(T,$,nt){return C.H.useSyncExternalStore(T,$,nt)},xt.useTransition=function(){return C.H.useTransition()},xt.version="19.1.1",xt}var rp;function Xf(){return rp||(rp=1,Xc.exports=kb()),Xc.exports}var ot=Xf();const Vf=Ry(ot);var Yy=ot.createContext(void 0),ms=n=>{const i=ot.useContext(Yy);if(!i)throw new Error("No QueryClient set, use QueryClientProvider to set one");return i},Ub=({client:n,children:i})=>(ot.useEffect(()=>(n.mount(),()=>{n.unmount()}),[n]),E.jsx(Yy.Provider,{value:n,children:i})),Xy=ot.createContext(!1),qb=()=>ot.useContext(Xy);Xy.Provider;function Hb(){let n=!1;return{clearReset:()=>{n=!1},reset:()=>{n=!0},isReset:()=>n}}var Lb=ot.createContext(Hb()),Bb=()=>ot.useContext(Lb),Gb=(n,i)=>{(n.suspense||n.throwOnError||n.experimental_prefetchInRender)&&(i.isReset()||(n.retryOnMount=!1))},Qb=n=>{ot.useEffect(()=>{n.clearReset()},[n])},Yb=({result:n,errorResetBoundary:i,throwOnError:r,query:u,suspense:o})=>n.isError&&!i.isReset()&&!n.isFetching&&u&&(o&&n.data===void 0||Uy(r,[n.error,u])),Xb=n=>{if(n.suspense){const i=u=>u==="static"?u:Math.max(u??1e3,1e3),r=n.staleTime;n.staleTime=typeof r=="function"?(...u)=>i(r(...u)):i(r),typeof n.gcTime=="number"&&(n.gcTime=Math.max(n.gcTime,1e3))}},Vb=(n,i)=>n.isLoading&&n.isFetching&&!i,$b=(n,i)=>n?.suspense&&i.isPending,lp=(n,i,r)=>i.fetchOptimistic(n).catch(()=>{r.clearReset()});function Zb(n,i,r){const u=qb(),o=Bb(),c=ms(),h=c.defaultQueryOptions(n);c.getDefaultOptions().queries?._experimental_beforeQuery?.(h),h._optimisticResults=u?"isRestoring":"optimistic",Xb(h),Gb(h,o),Qb(o);const g=!c.getQueryCache().get(h.queryHash),[y]=ot.useState(()=>new i(c,h)),p=y.getOptimisticResult(h),v=!u&&n.subscribed!==!1;if(ot.useSyncExternalStore(ot.useCallback(m=>{const _=v?y.subscribe(ne.batchCalls(m)):xe;return y.updateResult(),_},[y,v]),()=>y.getCurrentResult(),()=>y.getCurrentResult()),ot.useEffect(()=>{y.setOptions(h)},[h,y]),$b(h,p))throw lp(h,y,o);if(Yb({result:p,errorResetBoundary:o,throwOnError:h.throwOnError,query:c.getQueryCache().get(h.queryHash),suspense:h.suspense}))throw p.error;return c.getDefaultOptions().queries?._experimental_afterQuery?.(h,p),h.experimental_prefetchInRender&&!Wi&&Vb(p,u)&&(g?lp(h,y,o):c.getQueryCache().get(h.queryHash)?.promise)?.catch(xe).finally(()=>{y.updateResult()}),h.notifyOnChangeProps?p:y.trackResult(p)}function vf(n,i){return Zb(n,zb)}function Kb(n,i){const r=ms(),[u]=ot.useState(()=>new jb(r,n));ot.useEffect(()=>{u.setOptions(n)},[u,n]);const o=ot.useSyncExternalStore(ot.useCallback(h=>u.subscribe(ne.batchCalls(h)),[u]),()=>u.getCurrentResult(),()=>u.getCurrentResult()),c=ot.useCallback((h,g)=>{u.mutate(h,g).catch(xe)},[u]);if(o.error&&Uy(u.options.throwOnError,[o.error]))throw o.error;return{...o,mutate:c,mutateAsync:o.mutate}}var Vc={exports:{}},Wr={},$c={exports:{}},Zc={};/**
|
|
18
|
-
* @license React
|
|
19
|
-
* scheduler.production.js
|
|
20
|
-
*
|
|
21
|
-
* Copyright (c) Meta Platforms, Inc. and affiliates.
|
|
22
|
-
*
|
|
23
|
-
* This source code is licensed under the MIT license found in the
|
|
24
|
-
* LICENSE file in the root directory of this source tree.
|
|
25
|
-
*/var up;function Fb(){return up||(up=1,function(n){function i(N,Z){var et=N.length;N.push(Z);t:for(;0<et;){var ut=et-1>>>1,T=N[ut];if(0<o(T,Z))N[ut]=Z,N[et]=T,et=ut;else break t}}function r(N){return N.length===0?null:N[0]}function u(N){if(N.length===0)return null;var Z=N[0],et=N.pop();if(et!==Z){N[0]=et;t:for(var ut=0,T=N.length,$=T>>>1;ut<$;){var nt=2*(ut+1)-1,at=N[nt],st=nt+1,yt=N[st];if(0>o(at,et))st<T&&0>o(yt,at)?(N[ut]=yt,N[st]=et,ut=st):(N[ut]=at,N[nt]=et,ut=nt);else if(st<T&&0>o(yt,et))N[ut]=yt,N[st]=et,ut=st;else break t}}return Z}function o(N,Z){var et=N.sortIndex-Z.sortIndex;return et!==0?et:N.id-Z.id}if(n.unstable_now=void 0,typeof performance=="object"&&typeof performance.now=="function"){var c=performance;n.unstable_now=function(){return c.now()}}else{var h=Date,g=h.now();n.unstable_now=function(){return h.now()-g}}var y=[],p=[],v=1,m=null,_=3,x=!1,A=!1,M=!1,O=!1,S=typeof setTimeout=="function"?setTimeout:null,j=typeof clearTimeout=="function"?clearTimeout:null,H=typeof setImmediate<"u"?setImmediate:null;function R(N){for(var Z=r(p);Z!==null;){if(Z.callback===null)u(p);else if(Z.startTime<=N)u(p),Z.sortIndex=Z.expirationTime,i(y,Z);else break;Z=r(p)}}function C(N){if(M=!1,R(N),!A)if(r(y)!==null)A=!0,q||(q=!0,it());else{var Z=r(p);Z!==null&&J(C,Z.startTime-N)}}var q=!1,U=-1,Q=5,tt=-1;function F(){return O?!0:!(n.unstable_now()-tt<Q)}function K(){if(O=!1,q){var N=n.unstable_now();tt=N;var Z=!0;try{t:{A=!1,M&&(M=!1,j(U),U=-1),x=!0;var et=_;try{e:{for(R(N),m=r(y);m!==null&&!(m.expirationTime>N&&F());){var ut=m.callback;if(typeof ut=="function"){m.callback=null,_=m.priorityLevel;var T=ut(m.expirationTime<=N);if(N=n.unstable_now(),typeof T=="function"){m.callback=T,R(N),Z=!0;break e}m===r(y)&&u(y),R(N)}else u(y);m=r(y)}if(m!==null)Z=!0;else{var $=r(p);$!==null&&J(C,$.startTime-N),Z=!1}}break t}finally{m=null,_=et,x=!1}Z=void 0}}finally{Z?it():q=!1}}}var it;if(typeof H=="function")it=function(){H(K)};else if(typeof MessageChannel<"u"){var ct=new MessageChannel,L=ct.port2;ct.port1.onmessage=K,it=function(){L.postMessage(null)}}else it=function(){S(K,0)};function J(N,Z){U=S(function(){N(n.unstable_now())},Z)}n.unstable_IdlePriority=5,n.unstable_ImmediatePriority=1,n.unstable_LowPriority=4,n.unstable_NormalPriority=3,n.unstable_Profiling=null,n.unstable_UserBlockingPriority=2,n.unstable_cancelCallback=function(N){N.callback=null},n.unstable_forceFrameRate=function(N){0>N||125<N?console.error("forceFrameRate takes a positive int between 0 and 125, forcing frame rates higher than 125 fps is not supported"):Q=0<N?Math.floor(1e3/N):5},n.unstable_getCurrentPriorityLevel=function(){return _},n.unstable_next=function(N){switch(_){case 1:case 2:case 3:var Z=3;break;default:Z=_}var et=_;_=Z;try{return N()}finally{_=et}},n.unstable_requestPaint=function(){O=!0},n.unstable_runWithPriority=function(N,Z){switch(N){case 1:case 2:case 3:case 4:case 5:break;default:N=3}var et=_;_=N;try{return Z()}finally{_=et}},n.unstable_scheduleCallback=function(N,Z,et){var ut=n.unstable_now();switch(typeof et=="object"&&et!==null?(et=et.delay,et=typeof et=="number"&&0<et?ut+et:ut):et=ut,N){case 1:var T=-1;break;case 2:T=250;break;case 5:T=1073741823;break;case 4:T=1e4;break;default:T=5e3}return T=et+T,N={id:v++,callback:Z,priorityLevel:N,startTime:et,expirationTime:T,sortIndex:-1},et>ut?(N.sortIndex=et,i(p,N),r(y)===null&&N===r(p)&&(M?(j(U),U=-1):M=!0,J(C,et-ut))):(N.sortIndex=T,i(y,N),A||x||(A=!0,q||(q=!0,it()))),N},n.unstable_shouldYield=F,n.unstable_wrapCallback=function(N){var Z=_;return function(){var et=_;_=Z;try{return N.apply(this,arguments)}finally{_=et}}}}(Zc)),Zc}var sp;function Pb(){return sp||(sp=1,$c.exports=Fb()),$c.exports}var Kc={exports:{}},ye={};/**
|
|
26
|
-
* @license React
|
|
27
|
-
* react-dom.production.js
|
|
28
|
-
*
|
|
29
|
-
* Copyright (c) Meta Platforms, Inc. and affiliates.
|
|
30
|
-
*
|
|
31
|
-
* This source code is licensed under the MIT license found in the
|
|
32
|
-
* LICENSE file in the root directory of this source tree.
|
|
33
|
-
*/var op;function Jb(){if(op)return ye;op=1;var n=Xf();function i(y){var p="https://react.dev/errors/"+y;if(1<arguments.length){p+="?args[]="+encodeURIComponent(arguments[1]);for(var v=2;v<arguments.length;v++)p+="&args[]="+encodeURIComponent(arguments[v])}return"Minified React error #"+y+"; visit "+p+" for the full message or use the non-minified dev environment for full errors and additional helpful warnings."}function r(){}var u={d:{f:r,r:function(){throw Error(i(522))},D:r,C:r,L:r,m:r,X:r,S:r,M:r},p:0,findDOMNode:null},o=Symbol.for("react.portal");function c(y,p,v){var m=3<arguments.length&&arguments[3]!==void 0?arguments[3]:null;return{$$typeof:o,key:m==null?null:""+m,children:y,containerInfo:p,implementation:v}}var h=n.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE;function g(y,p){if(y==="font")return"";if(typeof p=="string")return p==="use-credentials"?p:""}return ye.__DOM_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE=u,ye.createPortal=function(y,p){var v=2<arguments.length&&arguments[2]!==void 0?arguments[2]:null;if(!p||p.nodeType!==1&&p.nodeType!==9&&p.nodeType!==11)throw Error(i(299));return c(y,p,null,v)},ye.flushSync=function(y){var p=h.T,v=u.p;try{if(h.T=null,u.p=2,y)return y()}finally{h.T=p,u.p=v,u.d.f()}},ye.preconnect=function(y,p){typeof y=="string"&&(p?(p=p.crossOrigin,p=typeof p=="string"?p==="use-credentials"?p:"":void 0):p=null,u.d.C(y,p))},ye.prefetchDNS=function(y){typeof y=="string"&&u.d.D(y)},ye.preinit=function(y,p){if(typeof y=="string"&&p&&typeof p.as=="string"){var v=p.as,m=g(v,p.crossOrigin),_=typeof p.integrity=="string"?p.integrity:void 0,x=typeof p.fetchPriority=="string"?p.fetchPriority:void 0;v==="style"?u.d.S(y,typeof p.precedence=="string"?p.precedence:void 0,{crossOrigin:m,integrity:_,fetchPriority:x}):v==="script"&&u.d.X(y,{crossOrigin:m,integrity:_,fetchPriority:x,nonce:typeof p.nonce=="string"?p.nonce:void 0})}},ye.preinitModule=function(y,p){if(typeof y=="string")if(typeof p=="object"&&p!==null){if(p.as==null||p.as==="script"){var v=g(p.as,p.crossOrigin);u.d.M(y,{crossOrigin:v,integrity:typeof p.integrity=="string"?p.integrity:void 0,nonce:typeof p.nonce=="string"?p.nonce:void 0})}}else p==null&&u.d.M(y)},ye.preload=function(y,p){if(typeof y=="string"&&typeof p=="object"&&p!==null&&typeof p.as=="string"){var v=p.as,m=g(v,p.crossOrigin);u.d.L(y,v,{crossOrigin:m,integrity:typeof p.integrity=="string"?p.integrity:void 0,nonce:typeof p.nonce=="string"?p.nonce:void 0,type:typeof p.type=="string"?p.type:void 0,fetchPriority:typeof p.fetchPriority=="string"?p.fetchPriority:void 0,referrerPolicy:typeof p.referrerPolicy=="string"?p.referrerPolicy:void 0,imageSrcSet:typeof p.imageSrcSet=="string"?p.imageSrcSet:void 0,imageSizes:typeof p.imageSizes=="string"?p.imageSizes:void 0,media:typeof p.media=="string"?p.media:void 0})}},ye.preloadModule=function(y,p){if(typeof y=="string")if(p){var v=g(p.as,p.crossOrigin);u.d.m(y,{as:typeof p.as=="string"&&p.as!=="script"?p.as:void 0,crossOrigin:v,integrity:typeof p.integrity=="string"?p.integrity:void 0})}else u.d.m(y)},ye.requestFormReset=function(y){u.d.r(y)},ye.unstable_batchedUpdates=function(y,p){return y(p)},ye.useFormState=function(y,p,v){return h.H.useFormState(y,p,v)},ye.useFormStatus=function(){return h.H.useHostTransitionStatus()},ye.version="19.1.1",ye}var cp;function Wb(){if(cp)return Kc.exports;cp=1;function n(){if(!(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__>"u"||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!="function"))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(n)}catch(i){console.error(i)}}return n(),Kc.exports=Jb(),Kc.exports}/**
|
|
34
|
-
* @license React
|
|
35
|
-
* react-dom-client.production.js
|
|
36
|
-
*
|
|
37
|
-
* Copyright (c) Meta Platforms, Inc. and affiliates.
|
|
38
|
-
*
|
|
39
|
-
* This source code is licensed under the MIT license found in the
|
|
40
|
-
* LICENSE file in the root directory of this source tree.
|
|
41
|
-
*/var fp;function Ib(){if(fp)return Wr;fp=1;var n=Pb(),i=Xf(),r=Wb();function u(e){var a="https://react.dev/errors/"+e;if(1<arguments.length){a+="?args[]="+encodeURIComponent(arguments[1]);for(var l=2;l<arguments.length;l++)a+="&args[]="+encodeURIComponent(arguments[l])}return"Minified React error #"+e+"; visit "+a+" for the full message or use the non-minified dev environment for full errors and additional helpful warnings."}function o(e){return!(!e||e.nodeType!==1&&e.nodeType!==9&&e.nodeType!==11)}function c(e){var a=e,l=e;if(e.alternate)for(;a.return;)a=a.return;else{e=a;do a=e,(a.flags&4098)!==0&&(l=a.return),e=a.return;while(e)}return a.tag===3?l:null}function h(e){if(e.tag===13){var a=e.memoizedState;if(a===null&&(e=e.alternate,e!==null&&(a=e.memoizedState)),a!==null)return a.dehydrated}return null}function g(e){if(c(e)!==e)throw Error(u(188))}function y(e){var a=e.alternate;if(!a){if(a=c(e),a===null)throw Error(u(188));return a!==e?null:e}for(var l=e,s=a;;){var f=l.return;if(f===null)break;var d=f.alternate;if(d===null){if(s=f.return,s!==null){l=s;continue}break}if(f.child===d.child){for(d=f.child;d;){if(d===l)return g(f),e;if(d===s)return g(f),a;d=d.sibling}throw Error(u(188))}if(l.return!==s.return)l=f,s=d;else{for(var b=!1,w=f.child;w;){if(w===l){b=!0,l=f,s=d;break}if(w===s){b=!0,s=f,l=d;break}w=w.sibling}if(!b){for(w=d.child;w;){if(w===l){b=!0,l=d,s=f;break}if(w===s){b=!0,s=d,l=f;break}w=w.sibling}if(!b)throw Error(u(189))}}if(l.alternate!==s)throw Error(u(190))}if(l.tag!==3)throw Error(u(188));return l.stateNode.current===l?e:a}function p(e){var a=e.tag;if(a===5||a===26||a===27||a===6)return e;for(e=e.child;e!==null;){if(a=p(e),a!==null)return a;e=e.sibling}return null}var v=Object.assign,m=Symbol.for("react.element"),_=Symbol.for("react.transitional.element"),x=Symbol.for("react.portal"),A=Symbol.for("react.fragment"),M=Symbol.for("react.strict_mode"),O=Symbol.for("react.profiler"),S=Symbol.for("react.provider"),j=Symbol.for("react.consumer"),H=Symbol.for("react.context"),R=Symbol.for("react.forward_ref"),C=Symbol.for("react.suspense"),q=Symbol.for("react.suspense_list"),U=Symbol.for("react.memo"),Q=Symbol.for("react.lazy"),tt=Symbol.for("react.activity"),F=Symbol.for("react.memo_cache_sentinel"),K=Symbol.iterator;function it(e){return e===null||typeof e!="object"?null:(e=K&&e[K]||e["@@iterator"],typeof e=="function"?e:null)}var ct=Symbol.for("react.client.reference");function L(e){if(e==null)return null;if(typeof e=="function")return e.$$typeof===ct?null:e.displayName||e.name||null;if(typeof e=="string")return e;switch(e){case A:return"Fragment";case O:return"Profiler";case M:return"StrictMode";case C:return"Suspense";case q:return"SuspenseList";case tt:return"Activity"}if(typeof e=="object")switch(e.$$typeof){case x:return"Portal";case H:return(e.displayName||"Context")+".Provider";case j:return(e._context.displayName||"Context")+".Consumer";case R:var a=e.render;return e=e.displayName,e||(e=a.displayName||a.name||"",e=e!==""?"ForwardRef("+e+")":"ForwardRef"),e;case U:return a=e.displayName||null,a!==null?a:L(e.type)||"Memo";case Q:a=e._payload,e=e._init;try{return L(e(a))}catch{}}return null}var J=Array.isArray,N=i.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,Z=r.__DOM_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,et={pending:!1,data:null,method:null,action:null},ut=[],T=-1;function $(e){return{current:e}}function nt(e){0>T||(e.current=ut[T],ut[T]=null,T--)}function at(e,a){T++,ut[T]=e.current,e.current=a}var st=$(null),yt=$(null),ht=$(null),Ct=$(null);function At(e,a){switch(at(ht,a),at(yt,e),at(st,null),a.nodeType){case 9:case 11:e=(e=a.documentElement)&&(e=e.namespaceURI)?wg(e):0;break;default:if(e=a.tagName,a=a.namespaceURI)a=wg(a),e=Sg(a,e);else switch(e){case"svg":e=1;break;case"math":e=2;break;default:e=0}}nt(st),at(st,e)}function ve(){nt(st),nt(yt),nt(ht)}function Wa(e){e.memoizedState!==null&&at(Ct,e);var a=st.current,l=Sg(a,e.type);a!==l&&(at(yt,e),at(st,l))}function ea(e){yt.current===e&&(nt(st),nt(yt)),Ct.current===e&&(nt(Ct),$r._currentValue=et)}var Ia=Object.prototype.hasOwnProperty,na=n.unstable_scheduleCallback,tr=n.unstable_cancelCallback,Es=n.unstable_shouldYield,Ts=n.unstable_requestPaint,Be=n.unstable_now,Cl=n.unstable_getCurrentPriorityLevel,Sn=n.unstable_ImmediatePriority,Si=n.unstable_UserBlockingPriority,Ai=n.unstable_NormalPriority,Os=n.unstable_LowPriority,An=n.unstable_IdlePriority,Ms=n.log,Cs=n.unstable_setDisableYieldValue,En=null,se=null;function cn(e){if(typeof Ms=="function"&&Cs(e),se&&typeof se.setStrictMode=="function")try{se.setStrictMode(En,e)}catch{}}var be=Math.clz32?Math.clz32:Nl,Ns=Math.log,zs=Math.LN2;function Nl(e){return e>>>=0,e===0?32:31-(Ns(e)/zs|0)|0}var ia=256,Ei=4194304;function Tn(e){var a=e&42;if(a!==0)return a;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:case 262144:case 524288:case 1048576:case 2097152:return e&4194048;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 Ti(e,a,l){var s=e.pendingLanes;if(s===0)return 0;var f=0,d=e.suspendedLanes,b=e.pingedLanes;e=e.warmLanes;var w=s&134217727;return w!==0?(s=w&~d,s!==0?f=Tn(s):(b&=w,b!==0?f=Tn(b):l||(l=w&~e,l!==0&&(f=Tn(l))))):(w=s&~d,w!==0?f=Tn(w):b!==0?f=Tn(b):l||(l=s&~e,l!==0&&(f=Tn(l)))),f===0?0:a!==0&&a!==f&&(a&d)===0&&(d=f&-f,l=a&-a,d>=l||d===32&&(l&4194048)!==0)?a:f}function Oi(e,a){return(e.pendingLanes&~(e.suspendedLanes&~e.pingedLanes)&a)===0}function Rs(e,a){switch(e){case 1:case 2:case 4:case 8:case 64:return a+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 a+5e3;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 zl(){var e=ia;return ia<<=1,(ia&4194048)===0&&(ia=256),e}function Rl(){var e=Ei;return Ei<<=1,(Ei&62914560)===0&&(Ei=4194304),e}function er(e){for(var a=[],l=0;31>l;l++)a.push(e);return a}function Mi(e,a){e.pendingLanes|=a,a!==268435456&&(e.suspendedLanes=0,e.pingedLanes=0,e.warmLanes=0)}function Ds(e,a,l,s,f,d){var b=e.pendingLanes;e.pendingLanes=l,e.suspendedLanes=0,e.pingedLanes=0,e.warmLanes=0,e.expiredLanes&=l,e.entangledLanes&=l,e.errorRecoveryDisabledLanes&=l,e.shellSuspendCounter=0;var w=e.entanglements,z=e.expirationTimes,Y=e.hiddenUpdates;for(l=b&~l;0<l;){var P=31-be(l),I=1<<P;w[P]=0,z[P]=-1;var X=Y[P];if(X!==null)for(Y[P]=null,P=0;P<X.length;P++){var V=X[P];V!==null&&(V.lane&=-536870913)}l&=~I}s!==0&&aa(e,s,0),d!==0&&f===0&&e.tag!==0&&(e.suspendedLanes|=d&~(b&~a))}function aa(e,a,l){e.pendingLanes|=a,e.suspendedLanes&=~a;var s=31-be(a);e.entangledLanes|=a,e.entanglements[s]=e.entanglements[s]|1073741824|l&4194090}function rt(e,a){var l=e.entangledLanes|=a;for(e=e.entanglements;l;){var s=31-be(l),f=1<<s;f&a|e[s]&a&&(e[s]|=a),l&=~f}}function pt(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 bt(e){return e&=-e,2<e?8<e?(e&134217727)!==0?32:268435456:8:2}function ie(){var e=Z.p;return e!==0?e:(e=window.event,e===void 0?32:Qg(e.type))}function fn(e,a){var l=Z.p;try{return Z.p=e,a()}finally{Z.p=l}}var ge=Math.random().toString(36).slice(2),It="__reactFiber$"+ge,Kt="__reactProps$"+ge,oe="__reactContainer$"+ge,Ae="__reactEvents$"+ge,nr="__reactListeners$"+ge,av="__reactHandles$"+ge,ch="__reactResources$"+ge,ir="__reactMarker$"+ge;function js(e){delete e[It],delete e[Kt],delete e[Ae],delete e[nr],delete e[av]}function ra(e){var a=e[It];if(a)return a;for(var l=e.parentNode;l;){if(a=l[oe]||l[It]){if(l=a.alternate,a.child!==null||l!==null&&l.child!==null)for(e=Og(e);e!==null;){if(l=e[It])return l;e=Og(e)}return a}e=l,l=e.parentNode}return null}function la(e){if(e=e[It]||e[oe]){var a=e.tag;if(a===5||a===6||a===13||a===26||a===27||a===3)return e}return null}function ar(e){var a=e.tag;if(a===5||a===26||a===27||a===6)return e.stateNode;throw Error(u(33))}function ua(e){var a=e[ch];return a||(a=e[ch]={hoistableStyles:new Map,hoistableScripts:new Map}),a}function ae(e){e[ir]=!0}var fh=new Set,hh={};function Ci(e,a){sa(e,a),sa(e+"Capture",a)}function sa(e,a){for(hh[e]=a,e=0;e<a.length;e++)fh.add(a[e])}var rv=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]*$"),dh={},gh={};function lv(e){return Ia.call(gh,e)?!0:Ia.call(dh,e)?!1:rv.test(e)?gh[e]=!0:(dh[e]=!0,!1)}function Dl(e,a,l){if(lv(a))if(l===null)e.removeAttribute(a);else{switch(typeof l){case"undefined":case"function":case"symbol":e.removeAttribute(a);return;case"boolean":var s=a.toLowerCase().slice(0,5);if(s!=="data-"&&s!=="aria-"){e.removeAttribute(a);return}}e.setAttribute(a,""+l)}}function jl(e,a,l){if(l===null)e.removeAttribute(a);else{switch(typeof l){case"undefined":case"function":case"symbol":case"boolean":e.removeAttribute(a);return}e.setAttribute(a,""+l)}}function On(e,a,l,s){if(s===null)e.removeAttribute(l);else{switch(typeof s){case"undefined":case"function":case"symbol":case"boolean":e.removeAttribute(l);return}e.setAttributeNS(a,l,""+s)}}var ks,ph;function oa(e){if(ks===void 0)try{throw Error()}catch(l){var a=l.stack.trim().match(/\n( *(at )?)/);ks=a&&a[1]||"",ph=-1<l.stack.indexOf(`
|
|
42
|
-
at`)?" (<anonymous>)":-1<l.stack.indexOf("@")?"@unknown:0:0":""}return`
|
|
43
|
-
`+ks+e+ph}var Us=!1;function qs(e,a){if(!e||Us)return"";Us=!0;var l=Error.prepareStackTrace;Error.prepareStackTrace=void 0;try{var s={DetermineComponentFrameRoot:function(){try{if(a){var I=function(){throw Error()};if(Object.defineProperty(I.prototype,"props",{set:function(){throw Error()}}),typeof Reflect=="object"&&Reflect.construct){try{Reflect.construct(I,[])}catch(V){var X=V}Reflect.construct(e,[],I)}else{try{I.call()}catch(V){X=V}e.call(I.prototype)}}else{try{throw Error()}catch(V){X=V}(I=e())&&typeof I.catch=="function"&&I.catch(function(){})}}catch(V){if(V&&X&&typeof V.stack=="string")return[V.stack,X.stack]}return[null,null]}};s.DetermineComponentFrameRoot.displayName="DetermineComponentFrameRoot";var f=Object.getOwnPropertyDescriptor(s.DetermineComponentFrameRoot,"name");f&&f.configurable&&Object.defineProperty(s.DetermineComponentFrameRoot,"name",{value:"DetermineComponentFrameRoot"});var d=s.DetermineComponentFrameRoot(),b=d[0],w=d[1];if(b&&w){var z=b.split(`
|
|
44
|
-
`),Y=w.split(`
|
|
45
|
-
`);for(f=s=0;s<z.length&&!z[s].includes("DetermineComponentFrameRoot");)s++;for(;f<Y.length&&!Y[f].includes("DetermineComponentFrameRoot");)f++;if(s===z.length||f===Y.length)for(s=z.length-1,f=Y.length-1;1<=s&&0<=f&&z[s]!==Y[f];)f--;for(;1<=s&&0<=f;s--,f--)if(z[s]!==Y[f]){if(s!==1||f!==1)do if(s--,f--,0>f||z[s]!==Y[f]){var P=`
|
|
46
|
-
`+z[s].replace(" at new "," at ");return e.displayName&&P.includes("<anonymous>")&&(P=P.replace("<anonymous>",e.displayName)),P}while(1<=s&&0<=f);break}}}finally{Us=!1,Error.prepareStackTrace=l}return(l=e?e.displayName||e.name:"")?oa(l):""}function uv(e){switch(e.tag){case 26:case 27:case 5:return oa(e.type);case 16:return oa("Lazy");case 13:return oa("Suspense");case 19:return oa("SuspenseList");case 0:case 15:return qs(e.type,!1);case 11:return qs(e.type.render,!1);case 1:return qs(e.type,!0);case 31:return oa("Activity");default:return""}}function yh(e){try{var a="";do a+=uv(e),e=e.return;while(e);return a}catch(l){return`
|
|
47
|
-
Error generating stack: `+l.message+`
|
|
48
|
-
`+l.stack}}function Ge(e){switch(typeof e){case"bigint":case"boolean":case"number":case"string":case"undefined":return e;case"object":return e;default:return""}}function mh(e){var a=e.type;return(e=e.nodeName)&&e.toLowerCase()==="input"&&(a==="checkbox"||a==="radio")}function sv(e){var a=mh(e)?"checked":"value",l=Object.getOwnPropertyDescriptor(e.constructor.prototype,a),s=""+e[a];if(!e.hasOwnProperty(a)&&typeof l<"u"&&typeof l.get=="function"&&typeof l.set=="function"){var f=l.get,d=l.set;return Object.defineProperty(e,a,{configurable:!0,get:function(){return f.call(this)},set:function(b){s=""+b,d.call(this,b)}}),Object.defineProperty(e,a,{enumerable:l.enumerable}),{getValue:function(){return s},setValue:function(b){s=""+b},stopTracking:function(){e._valueTracker=null,delete e[a]}}}}function kl(e){e._valueTracker||(e._valueTracker=sv(e))}function vh(e){if(!e)return!1;var a=e._valueTracker;if(!a)return!0;var l=a.getValue(),s="";return e&&(s=mh(e)?e.checked?"true":"false":e.value),e=s,e!==l?(a.setValue(e),!0):!1}function Ul(e){if(e=e||(typeof document<"u"?document:void 0),typeof e>"u")return null;try{return e.activeElement||e.body}catch{return e.body}}var ov=/[\n"\\]/g;function Qe(e){return e.replace(ov,function(a){return"\\"+a.charCodeAt(0).toString(16)+" "})}function Hs(e,a,l,s,f,d,b,w){e.name="",b!=null&&typeof b!="function"&&typeof b!="symbol"&&typeof b!="boolean"?e.type=b:e.removeAttribute("type"),a!=null?b==="number"?(a===0&&e.value===""||e.value!=a)&&(e.value=""+Ge(a)):e.value!==""+Ge(a)&&(e.value=""+Ge(a)):b!=="submit"&&b!=="reset"||e.removeAttribute("value"),a!=null?Ls(e,b,Ge(a)):l!=null?Ls(e,b,Ge(l)):s!=null&&e.removeAttribute("value"),f==null&&d!=null&&(e.defaultChecked=!!d),f!=null&&(e.checked=f&&typeof f!="function"&&typeof f!="symbol"),w!=null&&typeof w!="function"&&typeof w!="symbol"&&typeof w!="boolean"?e.name=""+Ge(w):e.removeAttribute("name")}function bh(e,a,l,s,f,d,b,w){if(d!=null&&typeof d!="function"&&typeof d!="symbol"&&typeof d!="boolean"&&(e.type=d),a!=null||l!=null){if(!(d!=="submit"&&d!=="reset"||a!=null))return;l=l!=null?""+Ge(l):"",a=a!=null?""+Ge(a):l,w||a===e.value||(e.value=a),e.defaultValue=a}s=s??f,s=typeof s!="function"&&typeof s!="symbol"&&!!s,e.checked=w?e.checked:!!s,e.defaultChecked=!!s,b!=null&&typeof b!="function"&&typeof b!="symbol"&&typeof b!="boolean"&&(e.name=b)}function Ls(e,a,l){a==="number"&&Ul(e.ownerDocument)===e||e.defaultValue===""+l||(e.defaultValue=""+l)}function ca(e,a,l,s){if(e=e.options,a){a={};for(var f=0;f<l.length;f++)a["$"+l[f]]=!0;for(l=0;l<e.length;l++)f=a.hasOwnProperty("$"+e[l].value),e[l].selected!==f&&(e[l].selected=f),f&&s&&(e[l].defaultSelected=!0)}else{for(l=""+Ge(l),a=null,f=0;f<e.length;f++){if(e[f].value===l){e[f].selected=!0,s&&(e[f].defaultSelected=!0);return}a!==null||e[f].disabled||(a=e[f])}a!==null&&(a.selected=!0)}}function _h(e,a,l){if(a!=null&&(a=""+Ge(a),a!==e.value&&(e.value=a),l==null)){e.defaultValue!==a&&(e.defaultValue=a);return}e.defaultValue=l!=null?""+Ge(l):""}function xh(e,a,l,s){if(a==null){if(s!=null){if(l!=null)throw Error(u(92));if(J(s)){if(1<s.length)throw Error(u(93));s=s[0]}l=s}l==null&&(l=""),a=l}l=Ge(a),e.defaultValue=l,s=e.textContent,s===l&&s!==""&&s!==null&&(e.value=s)}function fa(e,a){if(a){var l=e.firstChild;if(l&&l===e.lastChild&&l.nodeType===3){l.nodeValue=a;return}}e.textContent=a}var cv=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(" "));function wh(e,a,l){var s=a.indexOf("--")===0;l==null||typeof l=="boolean"||l===""?s?e.setProperty(a,""):a==="float"?e.cssFloat="":e[a]="":s?e.setProperty(a,l):typeof l!="number"||l===0||cv.has(a)?a==="float"?e.cssFloat=l:e[a]=(""+l).trim():e[a]=l+"px"}function Sh(e,a,l){if(a!=null&&typeof a!="object")throw Error(u(62));if(e=e.style,l!=null){for(var s in l)!l.hasOwnProperty(s)||a!=null&&a.hasOwnProperty(s)||(s.indexOf("--")===0?e.setProperty(s,""):s==="float"?e.cssFloat="":e[s]="");for(var f in a)s=a[f],a.hasOwnProperty(f)&&l[f]!==s&&wh(e,f,s)}else for(var d in a)a.hasOwnProperty(d)&&wh(e,d,a[d])}function Bs(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}}var fv=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"]]),hv=/^[\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;function ql(e){return hv.test(""+e)?"javascript:throw new Error('React has blocked a javascript: URL as a security precaution.')":e}var Gs=null;function Qs(e){return e=e.target||e.srcElement||window,e.correspondingUseElement&&(e=e.correspondingUseElement),e.nodeType===3?e.parentNode:e}var ha=null,da=null;function Ah(e){var a=la(e);if(a&&(e=a.stateNode)){var l=e[Kt]||null;t:switch(e=a.stateNode,a.type){case"input":if(Hs(e,l.value,l.defaultValue,l.defaultValue,l.checked,l.defaultChecked,l.type,l.name),a=l.name,l.type==="radio"&&a!=null){for(l=e;l.parentNode;)l=l.parentNode;for(l=l.querySelectorAll('input[name="'+Qe(""+a)+'"][type="radio"]'),a=0;a<l.length;a++){var s=l[a];if(s!==e&&s.form===e.form){var f=s[Kt]||null;if(!f)throw Error(u(90));Hs(s,f.value,f.defaultValue,f.defaultValue,f.checked,f.defaultChecked,f.type,f.name)}}for(a=0;a<l.length;a++)s=l[a],s.form===e.form&&vh(s)}break t;case"textarea":_h(e,l.value,l.defaultValue);break t;case"select":a=l.value,a!=null&&ca(e,!!l.multiple,a,!1)}}}var Ys=!1;function Eh(e,a,l){if(Ys)return e(a,l);Ys=!0;try{var s=e(a);return s}finally{if(Ys=!1,(ha!==null||da!==null)&&(wu(),ha&&(a=ha,e=da,da=ha=null,Ah(a),e)))for(a=0;a<e.length;a++)Ah(e[a])}}function rr(e,a){var l=e.stateNode;if(l===null)return null;var s=l[Kt]||null;if(s===null)return null;l=s[a];t:switch(a){case"onClick":case"onClickCapture":case"onDoubleClick":case"onDoubleClickCapture":case"onMouseDown":case"onMouseDownCapture":case"onMouseMove":case"onMouseMoveCapture":case"onMouseUp":case"onMouseUpCapture":case"onMouseEnter":(s=!s.disabled)||(e=e.type,s=!(e==="button"||e==="input"||e==="select"||e==="textarea")),e=!s;break t;default:e=!1}if(e)return null;if(l&&typeof l!="function")throw Error(u(231,a,typeof l));return l}var Mn=!(typeof window>"u"||typeof window.document>"u"||typeof window.document.createElement>"u"),Xs=!1;if(Mn)try{var lr={};Object.defineProperty(lr,"passive",{get:function(){Xs=!0}}),window.addEventListener("test",lr,lr),window.removeEventListener("test",lr,lr)}catch{Xs=!1}var Jn=null,Vs=null,Hl=null;function Th(){if(Hl)return Hl;var e,a=Vs,l=a.length,s,f="value"in Jn?Jn.value:Jn.textContent,d=f.length;for(e=0;e<l&&a[e]===f[e];e++);var b=l-e;for(s=1;s<=b&&a[l-s]===f[d-s];s++);return Hl=f.slice(e,1<s?1-s:void 0)}function Ll(e){var a=e.keyCode;return"charCode"in e?(e=e.charCode,e===0&&a===13&&(e=13)):e=a,e===10&&(e=13),32<=e||e===13?e:0}function Bl(){return!0}function Oh(){return!1}function Ee(e){function a(l,s,f,d,b){this._reactName=l,this._targetInst=f,this.type=s,this.nativeEvent=d,this.target=b,this.currentTarget=null;for(var w in e)e.hasOwnProperty(w)&&(l=e[w],this[w]=l?l(d):d[w]);return this.isDefaultPrevented=(d.defaultPrevented!=null?d.defaultPrevented:d.returnValue===!1)?Bl:Oh,this.isPropagationStopped=Oh,this}return v(a.prototype,{preventDefault:function(){this.defaultPrevented=!0;var l=this.nativeEvent;l&&(l.preventDefault?l.preventDefault():typeof l.returnValue!="unknown"&&(l.returnValue=!1),this.isDefaultPrevented=Bl)},stopPropagation:function(){var l=this.nativeEvent;l&&(l.stopPropagation?l.stopPropagation():typeof l.cancelBubble!="unknown"&&(l.cancelBubble=!0),this.isPropagationStopped=Bl)},persist:function(){},isPersistent:Bl}),a}var Ni={eventPhase:0,bubbles:0,cancelable:0,timeStamp:function(e){return e.timeStamp||Date.now()},defaultPrevented:0,isTrusted:0},Gl=Ee(Ni),ur=v({},Ni,{view:0,detail:0}),dv=Ee(ur),$s,Zs,sr,Ql=v({},ur,{screenX:0,screenY:0,clientX:0,clientY:0,pageX:0,pageY:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,getModifierState:Fs,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){return"movementX"in e?e.movementX:(e!==sr&&(sr&&e.type==="mousemove"?($s=e.screenX-sr.screenX,Zs=e.screenY-sr.screenY):Zs=$s=0,sr=e),$s)},movementY:function(e){return"movementY"in e?e.movementY:Zs}}),Mh=Ee(Ql),gv=v({},Ql,{dataTransfer:0}),pv=Ee(gv),yv=v({},ur,{relatedTarget:0}),Ks=Ee(yv),mv=v({},Ni,{animationName:0,elapsedTime:0,pseudoElement:0}),vv=Ee(mv),bv=v({},Ni,{clipboardData:function(e){return"clipboardData"in e?e.clipboardData:window.clipboardData}}),_v=Ee(bv),xv=v({},Ni,{data:0}),Ch=Ee(xv),wv={Esc:"Escape",Spacebar:" ",Left:"ArrowLeft",Up:"ArrowUp",Right:"ArrowRight",Down:"ArrowDown",Del:"Delete",Win:"OS",Menu:"ContextMenu",Apps:"ContextMenu",Scroll:"ScrollLock",MozPrintableKey:"Unidentified"},Sv={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"},Av={Alt:"altKey",Control:"ctrlKey",Meta:"metaKey",Shift:"shiftKey"};function Ev(e){var a=this.nativeEvent;return a.getModifierState?a.getModifierState(e):(e=Av[e])?!!a[e]:!1}function Fs(){return Ev}var Tv=v({},ur,{key:function(e){if(e.key){var a=wv[e.key]||e.key;if(a!=="Unidentified")return a}return e.type==="keypress"?(e=Ll(e),e===13?"Enter":String.fromCharCode(e)):e.type==="keydown"||e.type==="keyup"?Sv[e.keyCode]||"Unidentified":""},code:0,location:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,repeat:0,locale:0,getModifierState:Fs,charCode:function(e){return e.type==="keypress"?Ll(e):0},keyCode:function(e){return e.type==="keydown"||e.type==="keyup"?e.keyCode:0},which:function(e){return e.type==="keypress"?Ll(e):e.type==="keydown"||e.type==="keyup"?e.keyCode:0}}),Ov=Ee(Tv),Mv=v({},Ql,{pointerId:0,width:0,height:0,pressure:0,tangentialPressure:0,tiltX:0,tiltY:0,twist:0,pointerType:0,isPrimary:0}),Nh=Ee(Mv),Cv=v({},ur,{touches:0,targetTouches:0,changedTouches:0,altKey:0,metaKey:0,ctrlKey:0,shiftKey:0,getModifierState:Fs}),Nv=Ee(Cv),zv=v({},Ni,{propertyName:0,elapsedTime:0,pseudoElement:0}),Rv=Ee(zv),Dv=v({},Ql,{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}),jv=Ee(Dv),kv=v({},Ni,{newState:0,oldState:0}),Uv=Ee(kv),qv=[9,13,27,32],Ps=Mn&&"CompositionEvent"in window,or=null;Mn&&"documentMode"in document&&(or=document.documentMode);var Hv=Mn&&"TextEvent"in window&&!or,zh=Mn&&(!Ps||or&&8<or&&11>=or),Rh=" ",Dh=!1;function jh(e,a){switch(e){case"keyup":return qv.indexOf(a.keyCode)!==-1;case"keydown":return a.keyCode!==229;case"keypress":case"mousedown":case"focusout":return!0;default:return!1}}function kh(e){return e=e.detail,typeof e=="object"&&"data"in e?e.data:null}var ga=!1;function Lv(e,a){switch(e){case"compositionend":return kh(a);case"keypress":return a.which!==32?null:(Dh=!0,Rh);case"textInput":return e=a.data,e===Rh&&Dh?null:e;default:return null}}function Bv(e,a){if(ga)return e==="compositionend"||!Ps&&jh(e,a)?(e=Th(),Hl=Vs=Jn=null,ga=!1,e):null;switch(e){case"paste":return null;case"keypress":if(!(a.ctrlKey||a.altKey||a.metaKey)||a.ctrlKey&&a.altKey){if(a.char&&1<a.char.length)return a.char;if(a.which)return String.fromCharCode(a.which)}return null;case"compositionend":return zh&&a.locale!=="ko"?null:a.data;default:return null}}var Gv={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};function Uh(e){var a=e&&e.nodeName&&e.nodeName.toLowerCase();return a==="input"?!!Gv[e.type]:a==="textarea"}function qh(e,a,l,s){ha?da?da.push(s):da=[s]:ha=s,a=Mu(a,"onChange"),0<a.length&&(l=new Gl("onChange","change",null,l,s),e.push({event:l,listeners:a}))}var cr=null,fr=null;function Qv(e){mg(e,0)}function Yl(e){var a=ar(e);if(vh(a))return e}function Hh(e,a){if(e==="change")return a}var Lh=!1;if(Mn){var Js;if(Mn){var Ws="oninput"in document;if(!Ws){var Bh=document.createElement("div");Bh.setAttribute("oninput","return;"),Ws=typeof Bh.oninput=="function"}Js=Ws}else Js=!1;Lh=Js&&(!document.documentMode||9<document.documentMode)}function Gh(){cr&&(cr.detachEvent("onpropertychange",Qh),fr=cr=null)}function Qh(e){if(e.propertyName==="value"&&Yl(fr)){var a=[];qh(a,fr,e,Qs(e)),Eh(Qv,a)}}function Yv(e,a,l){e==="focusin"?(Gh(),cr=a,fr=l,cr.attachEvent("onpropertychange",Qh)):e==="focusout"&&Gh()}function Xv(e){if(e==="selectionchange"||e==="keyup"||e==="keydown")return Yl(fr)}function Vv(e,a){if(e==="click")return Yl(a)}function $v(e,a){if(e==="input"||e==="change")return Yl(a)}function Zv(e,a){return e===a&&(e!==0||1/e===1/a)||e!==e&&a!==a}var ze=typeof Object.is=="function"?Object.is:Zv;function hr(e,a){if(ze(e,a))return!0;if(typeof e!="object"||e===null||typeof a!="object"||a===null)return!1;var l=Object.keys(e),s=Object.keys(a);if(l.length!==s.length)return!1;for(s=0;s<l.length;s++){var f=l[s];if(!Ia.call(a,f)||!ze(e[f],a[f]))return!1}return!0}function Yh(e){for(;e&&e.firstChild;)e=e.firstChild;return e}function Xh(e,a){var l=Yh(e);e=0;for(var s;l;){if(l.nodeType===3){if(s=e+l.textContent.length,e<=a&&s>=a)return{node:l,offset:a-e};e=s}t:{for(;l;){if(l.nextSibling){l=l.nextSibling;break t}l=l.parentNode}l=void 0}l=Yh(l)}}function Vh(e,a){return e&&a?e===a?!0:e&&e.nodeType===3?!1:a&&a.nodeType===3?Vh(e,a.parentNode):"contains"in e?e.contains(a):e.compareDocumentPosition?!!(e.compareDocumentPosition(a)&16):!1:!1}function $h(e){e=e!=null&&e.ownerDocument!=null&&e.ownerDocument.defaultView!=null?e.ownerDocument.defaultView:window;for(var a=Ul(e.document);a instanceof e.HTMLIFrameElement;){try{var l=typeof a.contentWindow.location.href=="string"}catch{l=!1}if(l)e=a.contentWindow;else break;a=Ul(e.document)}return a}function Is(e){var a=e&&e.nodeName&&e.nodeName.toLowerCase();return a&&(a==="input"&&(e.type==="text"||e.type==="search"||e.type==="tel"||e.type==="url"||e.type==="password")||a==="textarea"||e.contentEditable==="true")}var Kv=Mn&&"documentMode"in document&&11>=document.documentMode,pa=null,to=null,dr=null,eo=!1;function Zh(e,a,l){var s=l.window===l?l.document:l.nodeType===9?l:l.ownerDocument;eo||pa==null||pa!==Ul(s)||(s=pa,"selectionStart"in s&&Is(s)?s={start:s.selectionStart,end:s.selectionEnd}:(s=(s.ownerDocument&&s.ownerDocument.defaultView||window).getSelection(),s={anchorNode:s.anchorNode,anchorOffset:s.anchorOffset,focusNode:s.focusNode,focusOffset:s.focusOffset}),dr&&hr(dr,s)||(dr=s,s=Mu(to,"onSelect"),0<s.length&&(a=new Gl("onSelect","select",null,a,l),e.push({event:a,listeners:s}),a.target=pa)))}function zi(e,a){var l={};return l[e.toLowerCase()]=a.toLowerCase(),l["Webkit"+e]="webkit"+a,l["Moz"+e]="moz"+a,l}var ya={animationend:zi("Animation","AnimationEnd"),animationiteration:zi("Animation","AnimationIteration"),animationstart:zi("Animation","AnimationStart"),transitionrun:zi("Transition","TransitionRun"),transitionstart:zi("Transition","TransitionStart"),transitioncancel:zi("Transition","TransitionCancel"),transitionend:zi("Transition","TransitionEnd")},no={},Kh={};Mn&&(Kh=document.createElement("div").style,"AnimationEvent"in window||(delete ya.animationend.animation,delete ya.animationiteration.animation,delete ya.animationstart.animation),"TransitionEvent"in window||delete ya.transitionend.transition);function Ri(e){if(no[e])return no[e];if(!ya[e])return e;var a=ya[e],l;for(l in a)if(a.hasOwnProperty(l)&&l in Kh)return no[e]=a[l];return e}var Fh=Ri("animationend"),Ph=Ri("animationiteration"),Jh=Ri("animationstart"),Fv=Ri("transitionrun"),Pv=Ri("transitionstart"),Jv=Ri("transitioncancel"),Wh=Ri("transitionend"),Ih=new Map,io="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(" ");io.push("scrollEnd");function en(e,a){Ih.set(e,a),Ci(a,[e])}var td=new WeakMap;function Ye(e,a){if(typeof e=="object"&&e!==null){var l=td.get(e);return l!==void 0?l:(a={value:e,source:a,stack:yh(a)},td.set(e,a),a)}return{value:e,source:a,stack:yh(a)}}var Xe=[],ma=0,ao=0;function Xl(){for(var e=ma,a=ao=ma=0;a<e;){var l=Xe[a];Xe[a++]=null;var s=Xe[a];Xe[a++]=null;var f=Xe[a];Xe[a++]=null;var d=Xe[a];if(Xe[a++]=null,s!==null&&f!==null){var b=s.pending;b===null?f.next=f:(f.next=b.next,b.next=f),s.pending=f}d!==0&&ed(l,f,d)}}function Vl(e,a,l,s){Xe[ma++]=e,Xe[ma++]=a,Xe[ma++]=l,Xe[ma++]=s,ao|=s,e.lanes|=s,e=e.alternate,e!==null&&(e.lanes|=s)}function ro(e,a,l,s){return Vl(e,a,l,s),$l(e)}function va(e,a){return Vl(e,null,null,a),$l(e)}function ed(e,a,l){e.lanes|=l;var s=e.alternate;s!==null&&(s.lanes|=l);for(var f=!1,d=e.return;d!==null;)d.childLanes|=l,s=d.alternate,s!==null&&(s.childLanes|=l),d.tag===22&&(e=d.stateNode,e===null||e._visibility&1||(f=!0)),e=d,d=d.return;return e.tag===3?(d=e.stateNode,f&&a!==null&&(f=31-be(l),e=d.hiddenUpdates,s=e[f],s===null?e[f]=[a]:s.push(a),a.lane=l|536870912),d):null}function $l(e){if(50<Hr)throw Hr=0,hc=null,Error(u(185));for(var a=e.return;a!==null;)e=a,a=e.return;return e.tag===3?e.stateNode:null}var ba={};function Wv(e,a,l,s){this.tag=e,this.key=l,this.sibling=this.child=this.return=this.stateNode=this.type=this.elementType=null,this.index=0,this.refCleanup=this.ref=null,this.pendingProps=a,this.dependencies=this.memoizedState=this.updateQueue=this.memoizedProps=null,this.mode=s,this.subtreeFlags=this.flags=0,this.deletions=null,this.childLanes=this.lanes=0,this.alternate=null}function Re(e,a,l,s){return new Wv(e,a,l,s)}function lo(e){return e=e.prototype,!(!e||!e.isReactComponent)}function Cn(e,a){var l=e.alternate;return l===null?(l=Re(e.tag,a,e.key,e.mode),l.elementType=e.elementType,l.type=e.type,l.stateNode=e.stateNode,l.alternate=e,e.alternate=l):(l.pendingProps=a,l.type=e.type,l.flags=0,l.subtreeFlags=0,l.deletions=null),l.flags=e.flags&65011712,l.childLanes=e.childLanes,l.lanes=e.lanes,l.child=e.child,l.memoizedProps=e.memoizedProps,l.memoizedState=e.memoizedState,l.updateQueue=e.updateQueue,a=e.dependencies,l.dependencies=a===null?null:{lanes:a.lanes,firstContext:a.firstContext},l.sibling=e.sibling,l.index=e.index,l.ref=e.ref,l.refCleanup=e.refCleanup,l}function nd(e,a){e.flags&=65011714;var l=e.alternate;return l===null?(e.childLanes=0,e.lanes=a,e.child=null,e.subtreeFlags=0,e.memoizedProps=null,e.memoizedState=null,e.updateQueue=null,e.dependencies=null,e.stateNode=null):(e.childLanes=l.childLanes,e.lanes=l.lanes,e.child=l.child,e.subtreeFlags=0,e.deletions=null,e.memoizedProps=l.memoizedProps,e.memoizedState=l.memoizedState,e.updateQueue=l.updateQueue,e.type=l.type,a=l.dependencies,e.dependencies=a===null?null:{lanes:a.lanes,firstContext:a.firstContext}),e}function Zl(e,a,l,s,f,d){var b=0;if(s=e,typeof e=="function")lo(e)&&(b=1);else if(typeof e=="string")b=tb(e,l,st.current)?26:e==="html"||e==="head"||e==="body"?27:5;else t:switch(e){case tt:return e=Re(31,l,a,f),e.elementType=tt,e.lanes=d,e;case A:return Di(l.children,f,d,a);case M:b=8,f|=24;break;case O:return e=Re(12,l,a,f|2),e.elementType=O,e.lanes=d,e;case C:return e=Re(13,l,a,f),e.elementType=C,e.lanes=d,e;case q:return e=Re(19,l,a,f),e.elementType=q,e.lanes=d,e;default:if(typeof e=="object"&&e!==null)switch(e.$$typeof){case S:case H:b=10;break t;case j:b=9;break t;case R:b=11;break t;case U:b=14;break t;case Q:b=16,s=null;break t}b=29,l=Error(u(130,e===null?"null":typeof e,"")),s=null}return a=Re(b,l,a,f),a.elementType=e,a.type=s,a.lanes=d,a}function Di(e,a,l,s){return e=Re(7,e,s,a),e.lanes=l,e}function uo(e,a,l){return e=Re(6,e,null,a),e.lanes=l,e}function so(e,a,l){return a=Re(4,e.children!==null?e.children:[],e.key,a),a.lanes=l,a.stateNode={containerInfo:e.containerInfo,pendingChildren:null,implementation:e.implementation},a}var _a=[],xa=0,Kl=null,Fl=0,Ve=[],$e=0,ji=null,Nn=1,zn="";function ki(e,a){_a[xa++]=Fl,_a[xa++]=Kl,Kl=e,Fl=a}function id(e,a,l){Ve[$e++]=Nn,Ve[$e++]=zn,Ve[$e++]=ji,ji=e;var s=Nn;e=zn;var f=32-be(s)-1;s&=~(1<<f),l+=1;var d=32-be(a)+f;if(30<d){var b=f-f%5;d=(s&(1<<b)-1).toString(32),s>>=b,f-=b,Nn=1<<32-be(a)+f|l<<f|s,zn=d+e}else Nn=1<<d|l<<f|s,zn=e}function oo(e){e.return!==null&&(ki(e,1),id(e,1,0))}function co(e){for(;e===Kl;)Kl=_a[--xa],_a[xa]=null,Fl=_a[--xa],_a[xa]=null;for(;e===ji;)ji=Ve[--$e],Ve[$e]=null,zn=Ve[--$e],Ve[$e]=null,Nn=Ve[--$e],Ve[$e]=null}var _e=null,Vt=null,Nt=!1,Ui=null,hn=!1,fo=Error(u(519));function qi(e){var a=Error(u(418,""));throw yr(Ye(a,e)),fo}function ad(e){var a=e.stateNode,l=e.type,s=e.memoizedProps;switch(a[It]=e,a[Kt]=s,l){case"dialog":Tt("cancel",a),Tt("close",a);break;case"iframe":case"object":case"embed":Tt("load",a);break;case"video":case"audio":for(l=0;l<Br.length;l++)Tt(Br[l],a);break;case"source":Tt("error",a);break;case"img":case"image":case"link":Tt("error",a),Tt("load",a);break;case"details":Tt("toggle",a);break;case"input":Tt("invalid",a),bh(a,s.value,s.defaultValue,s.checked,s.defaultChecked,s.type,s.name,!0),kl(a);break;case"select":Tt("invalid",a);break;case"textarea":Tt("invalid",a),xh(a,s.value,s.defaultValue,s.children),kl(a)}l=s.children,typeof l!="string"&&typeof l!="number"&&typeof l!="bigint"||a.textContent===""+l||s.suppressHydrationWarning===!0||xg(a.textContent,l)?(s.popover!=null&&(Tt("beforetoggle",a),Tt("toggle",a)),s.onScroll!=null&&Tt("scroll",a),s.onScrollEnd!=null&&Tt("scrollend",a),s.onClick!=null&&(a.onclick=Cu),a=!0):a=!1,a||qi(e)}function rd(e){for(_e=e.return;_e;)switch(_e.tag){case 5:case 13:hn=!1;return;case 27:case 3:hn=!0;return;default:_e=_e.return}}function gr(e){if(e!==_e)return!1;if(!Nt)return rd(e),Nt=!0,!1;var a=e.tag,l;if((l=a!==3&&a!==27)&&((l=a===5)&&(l=e.type,l=!(l!=="form"&&l!=="button")||Mc(e.type,e.memoizedProps)),l=!l),l&&Vt&&qi(e),rd(e),a===13){if(e=e.memoizedState,e=e!==null?e.dehydrated:null,!e)throw Error(u(317));t:{for(e=e.nextSibling,a=0;e;){if(e.nodeType===8)if(l=e.data,l==="/$"){if(a===0){Vt=an(e.nextSibling);break t}a--}else l!=="$"&&l!=="$!"&&l!=="$?"||a++;e=e.nextSibling}Vt=null}}else a===27?(a=Vt,di(e.type)?(e=Rc,Rc=null,Vt=e):Vt=a):Vt=_e?an(e.stateNode.nextSibling):null;return!0}function pr(){Vt=_e=null,Nt=!1}function ld(){var e=Ui;return e!==null&&(Me===null?Me=e:Me.push.apply(Me,e),Ui=null),e}function yr(e){Ui===null?Ui=[e]:Ui.push(e)}var ho=$(null),Hi=null,Rn=null;function Wn(e,a,l){at(ho,a._currentValue),a._currentValue=l}function Dn(e){e._currentValue=ho.current,nt(ho)}function go(e,a,l){for(;e!==null;){var s=e.alternate;if((e.childLanes&a)!==a?(e.childLanes|=a,s!==null&&(s.childLanes|=a)):s!==null&&(s.childLanes&a)!==a&&(s.childLanes|=a),e===l)break;e=e.return}}function po(e,a,l,s){var f=e.child;for(f!==null&&(f.return=e);f!==null;){var d=f.dependencies;if(d!==null){var b=f.child;d=d.firstContext;t:for(;d!==null;){var w=d;d=f;for(var z=0;z<a.length;z++)if(w.context===a[z]){d.lanes|=l,w=d.alternate,w!==null&&(w.lanes|=l),go(d.return,l,e),s||(b=null);break t}d=w.next}}else if(f.tag===18){if(b=f.return,b===null)throw Error(u(341));b.lanes|=l,d=b.alternate,d!==null&&(d.lanes|=l),go(b,l,e),b=null}else b=f.child;if(b!==null)b.return=f;else for(b=f;b!==null;){if(b===e){b=null;break}if(f=b.sibling,f!==null){f.return=b.return,b=f;break}b=b.return}f=b}}function mr(e,a,l,s){e=null;for(var f=a,d=!1;f!==null;){if(!d){if((f.flags&524288)!==0)d=!0;else if((f.flags&262144)!==0)break}if(f.tag===10){var b=f.alternate;if(b===null)throw Error(u(387));if(b=b.memoizedProps,b!==null){var w=f.type;ze(f.pendingProps.value,b.value)||(e!==null?e.push(w):e=[w])}}else if(f===Ct.current){if(b=f.alternate,b===null)throw Error(u(387));b.memoizedState.memoizedState!==f.memoizedState.memoizedState&&(e!==null?e.push($r):e=[$r])}f=f.return}e!==null&&po(a,e,l,s),a.flags|=262144}function Pl(e){for(e=e.firstContext;e!==null;){if(!ze(e.context._currentValue,e.memoizedValue))return!0;e=e.next}return!1}function Li(e){Hi=e,Rn=null,e=e.dependencies,e!==null&&(e.firstContext=null)}function pe(e){return ud(Hi,e)}function Jl(e,a){return Hi===null&&Li(e),ud(e,a)}function ud(e,a){var l=a._currentValue;if(a={context:a,memoizedValue:l,next:null},Rn===null){if(e===null)throw Error(u(308));Rn=a,e.dependencies={lanes:0,firstContext:a},e.flags|=524288}else Rn=Rn.next=a;return l}var Iv=typeof AbortController<"u"?AbortController:function(){var e=[],a=this.signal={aborted:!1,addEventListener:function(l,s){e.push(s)}};this.abort=function(){a.aborted=!0,e.forEach(function(l){return l()})}},t1=n.unstable_scheduleCallback,e1=n.unstable_NormalPriority,te={$$typeof:H,Consumer:null,Provider:null,_currentValue:null,_currentValue2:null,_threadCount:0};function yo(){return{controller:new Iv,data:new Map,refCount:0}}function vr(e){e.refCount--,e.refCount===0&&t1(e1,function(){e.controller.abort()})}var br=null,mo=0,wa=0,Sa=null;function n1(e,a){if(br===null){var l=br=[];mo=0,wa=bc(),Sa={status:"pending",value:void 0,then:function(s){l.push(s)}}}return mo++,a.then(sd,sd),a}function sd(){if(--mo===0&&br!==null){Sa!==null&&(Sa.status="fulfilled");var e=br;br=null,wa=0,Sa=null;for(var a=0;a<e.length;a++)(0,e[a])()}}function i1(e,a){var l=[],s={status:"pending",value:null,reason:null,then:function(f){l.push(f)}};return e.then(function(){s.status="fulfilled",s.value=a;for(var f=0;f<l.length;f++)(0,l[f])(a)},function(f){for(s.status="rejected",s.reason=f,f=0;f<l.length;f++)(0,l[f])(void 0)}),s}var od=N.S;N.S=function(e,a){typeof a=="object"&&a!==null&&typeof a.then=="function"&&n1(e,a),od!==null&&od(e,a)};var Bi=$(null);function vo(){var e=Bi.current;return e!==null?e:Lt.pooledCache}function Wl(e,a){a===null?at(Bi,Bi.current):at(Bi,a.pool)}function cd(){var e=vo();return e===null?null:{parent:te._currentValue,pool:e}}var _r=Error(u(460)),fd=Error(u(474)),Il=Error(u(542)),bo={then:function(){}};function hd(e){return e=e.status,e==="fulfilled"||e==="rejected"}function tu(){}function dd(e,a,l){switch(l=e[l],l===void 0?e.push(a):l!==a&&(a.then(tu,tu),a=l),a.status){case"fulfilled":return a.value;case"rejected":throw e=a.reason,pd(e),e;default:if(typeof a.status=="string")a.then(tu,tu);else{if(e=Lt,e!==null&&100<e.shellSuspendCounter)throw Error(u(482));e=a,e.status="pending",e.then(function(s){if(a.status==="pending"){var f=a;f.status="fulfilled",f.value=s}},function(s){if(a.status==="pending"){var f=a;f.status="rejected",f.reason=s}})}switch(a.status){case"fulfilled":return a.value;case"rejected":throw e=a.reason,pd(e),e}throw xr=a,_r}}var xr=null;function gd(){if(xr===null)throw Error(u(459));var e=xr;return xr=null,e}function pd(e){if(e===_r||e===Il)throw Error(u(483))}var In=!1;function _o(e){e.updateQueue={baseState:e.memoizedState,firstBaseUpdate:null,lastBaseUpdate:null,shared:{pending:null,lanes:0,hiddenCallbacks:null},callbacks:null}}function xo(e,a){e=e.updateQueue,a.updateQueue===e&&(a.updateQueue={baseState:e.baseState,firstBaseUpdate:e.firstBaseUpdate,lastBaseUpdate:e.lastBaseUpdate,shared:e.shared,callbacks:null})}function ti(e){return{lane:e,tag:0,payload:null,callback:null,next:null}}function ei(e,a,l){var s=e.updateQueue;if(s===null)return null;if(s=s.shared,(zt&2)!==0){var f=s.pending;return f===null?a.next=a:(a.next=f.next,f.next=a),s.pending=a,a=$l(e),ed(e,null,l),a}return Vl(e,s,a,l),$l(e)}function wr(e,a,l){if(a=a.updateQueue,a!==null&&(a=a.shared,(l&4194048)!==0)){var s=a.lanes;s&=e.pendingLanes,l|=s,a.lanes=l,rt(e,l)}}function wo(e,a){var l=e.updateQueue,s=e.alternate;if(s!==null&&(s=s.updateQueue,l===s)){var f=null,d=null;if(l=l.firstBaseUpdate,l!==null){do{var b={lane:l.lane,tag:l.tag,payload:l.payload,callback:null,next:null};d===null?f=d=b:d=d.next=b,l=l.next}while(l!==null);d===null?f=d=a:d=d.next=a}else f=d=a;l={baseState:s.baseState,firstBaseUpdate:f,lastBaseUpdate:d,shared:s.shared,callbacks:s.callbacks},e.updateQueue=l;return}e=l.lastBaseUpdate,e===null?l.firstBaseUpdate=a:e.next=a,l.lastBaseUpdate=a}var So=!1;function Sr(){if(So){var e=Sa;if(e!==null)throw e}}function Ar(e,a,l,s){So=!1;var f=e.updateQueue;In=!1;var d=f.firstBaseUpdate,b=f.lastBaseUpdate,w=f.shared.pending;if(w!==null){f.shared.pending=null;var z=w,Y=z.next;z.next=null,b===null?d=Y:b.next=Y,b=z;var P=e.alternate;P!==null&&(P=P.updateQueue,w=P.lastBaseUpdate,w!==b&&(w===null?P.firstBaseUpdate=Y:w.next=Y,P.lastBaseUpdate=z))}if(d!==null){var I=f.baseState;b=0,P=Y=z=null,w=d;do{var X=w.lane&-536870913,V=X!==w.lane;if(V?(Ot&X)===X:(s&X)===X){X!==0&&X===wa&&(So=!0),P!==null&&(P=P.next={lane:0,tag:w.tag,payload:w.payload,callback:null,next:null});t:{var _t=e,mt=w;X=a;var Ut=l;switch(mt.tag){case 1:if(_t=mt.payload,typeof _t=="function"){I=_t.call(Ut,I,X);break t}I=_t;break t;case 3:_t.flags=_t.flags&-65537|128;case 0:if(_t=mt.payload,X=typeof _t=="function"?_t.call(Ut,I,X):_t,X==null)break t;I=v({},I,X);break t;case 2:In=!0}}X=w.callback,X!==null&&(e.flags|=64,V&&(e.flags|=8192),V=f.callbacks,V===null?f.callbacks=[X]:V.push(X))}else V={lane:X,tag:w.tag,payload:w.payload,callback:w.callback,next:null},P===null?(Y=P=V,z=I):P=P.next=V,b|=X;if(w=w.next,w===null){if(w=f.shared.pending,w===null)break;V=w,w=V.next,V.next=null,f.lastBaseUpdate=V,f.shared.pending=null}}while(!0);P===null&&(z=I),f.baseState=z,f.firstBaseUpdate=Y,f.lastBaseUpdate=P,d===null&&(f.shared.lanes=0),oi|=b,e.lanes=b,e.memoizedState=I}}function yd(e,a){if(typeof e!="function")throw Error(u(191,e));e.call(a)}function md(e,a){var l=e.callbacks;if(l!==null)for(e.callbacks=null,e=0;e<l.length;e++)yd(l[e],a)}var Aa=$(null),eu=$(0);function vd(e,a){e=Bn,at(eu,e),at(Aa,a),Bn=e|a.baseLanes}function Ao(){at(eu,Bn),at(Aa,Aa.current)}function Eo(){Bn=eu.current,nt(Aa),nt(eu)}var ni=0,wt=null,jt=null,Jt=null,nu=!1,Ea=!1,Gi=!1,iu=0,Er=0,Ta=null,a1=0;function Ft(){throw Error(u(321))}function To(e,a){if(a===null)return!1;for(var l=0;l<a.length&&l<e.length;l++)if(!ze(e[l],a[l]))return!1;return!0}function Oo(e,a,l,s,f,d){return ni=d,wt=a,a.memoizedState=null,a.updateQueue=null,a.lanes=0,N.H=e===null||e.memoizedState===null?e0:n0,Gi=!1,d=l(s,f),Gi=!1,Ea&&(d=_d(a,l,s,f)),bd(e),d}function bd(e){N.H=ou;var a=jt!==null&&jt.next!==null;if(ni=0,Jt=jt=wt=null,nu=!1,Er=0,Ta=null,a)throw Error(u(300));e===null||re||(e=e.dependencies,e!==null&&Pl(e)&&(re=!0))}function _d(e,a,l,s){wt=e;var f=0;do{if(Ea&&(Ta=null),Er=0,Ea=!1,25<=f)throw Error(u(301));if(f+=1,Jt=jt=null,e.updateQueue!=null){var d=e.updateQueue;d.lastEffect=null,d.events=null,d.stores=null,d.memoCache!=null&&(d.memoCache.index=0)}N.H=f1,d=a(l,s)}while(Ea);return d}function r1(){var e=N.H,a=e.useState()[0];return a=typeof a.then=="function"?Tr(a):a,e=e.useState()[0],(jt!==null?jt.memoizedState:null)!==e&&(wt.flags|=1024),a}function Mo(){var e=iu!==0;return iu=0,e}function Co(e,a,l){a.updateQueue=e.updateQueue,a.flags&=-2053,e.lanes&=~l}function No(e){if(nu){for(e=e.memoizedState;e!==null;){var a=e.queue;a!==null&&(a.pending=null),e=e.next}nu=!1}ni=0,Jt=jt=wt=null,Ea=!1,Er=iu=0,Ta=null}function Te(){var e={memoizedState:null,baseState:null,baseQueue:null,queue:null,next:null};return Jt===null?wt.memoizedState=Jt=e:Jt=Jt.next=e,Jt}function Wt(){if(jt===null){var e=wt.alternate;e=e!==null?e.memoizedState:null}else e=jt.next;var a=Jt===null?wt.memoizedState:Jt.next;if(a!==null)Jt=a,jt=e;else{if(e===null)throw wt.alternate===null?Error(u(467)):Error(u(310));jt=e,e={memoizedState:jt.memoizedState,baseState:jt.baseState,baseQueue:jt.baseQueue,queue:jt.queue,next:null},Jt===null?wt.memoizedState=Jt=e:Jt=Jt.next=e}return Jt}function zo(){return{lastEffect:null,events:null,stores:null,memoCache:null}}function Tr(e){var a=Er;return Er+=1,Ta===null&&(Ta=[]),e=dd(Ta,e,a),a=wt,(Jt===null?a.memoizedState:Jt.next)===null&&(a=a.alternate,N.H=a===null||a.memoizedState===null?e0:n0),e}function au(e){if(e!==null&&typeof e=="object"){if(typeof e.then=="function")return Tr(e);if(e.$$typeof===H)return pe(e)}throw Error(u(438,String(e)))}function Ro(e){var a=null,l=wt.updateQueue;if(l!==null&&(a=l.memoCache),a==null){var s=wt.alternate;s!==null&&(s=s.updateQueue,s!==null&&(s=s.memoCache,s!=null&&(a={data:s.data.map(function(f){return f.slice()}),index:0})))}if(a==null&&(a={data:[],index:0}),l===null&&(l=zo(),wt.updateQueue=l),l.memoCache=a,l=a.data[a.index],l===void 0)for(l=a.data[a.index]=Array(e),s=0;s<e;s++)l[s]=F;return a.index++,l}function jn(e,a){return typeof a=="function"?a(e):a}function ru(e){var a=Wt();return Do(a,jt,e)}function Do(e,a,l){var s=e.queue;if(s===null)throw Error(u(311));s.lastRenderedReducer=l;var f=e.baseQueue,d=s.pending;if(d!==null){if(f!==null){var b=f.next;f.next=d.next,d.next=b}a.baseQueue=f=d,s.pending=null}if(d=e.baseState,f===null)e.memoizedState=d;else{a=f.next;var w=b=null,z=null,Y=a,P=!1;do{var I=Y.lane&-536870913;if(I!==Y.lane?(Ot&I)===I:(ni&I)===I){var X=Y.revertLane;if(X===0)z!==null&&(z=z.next={lane:0,revertLane:0,action:Y.action,hasEagerState:Y.hasEagerState,eagerState:Y.eagerState,next:null}),I===wa&&(P=!0);else if((ni&X)===X){Y=Y.next,X===wa&&(P=!0);continue}else I={lane:0,revertLane:Y.revertLane,action:Y.action,hasEagerState:Y.hasEagerState,eagerState:Y.eagerState,next:null},z===null?(w=z=I,b=d):z=z.next=I,wt.lanes|=X,oi|=X;I=Y.action,Gi&&l(d,I),d=Y.hasEagerState?Y.eagerState:l(d,I)}else X={lane:I,revertLane:Y.revertLane,action:Y.action,hasEagerState:Y.hasEagerState,eagerState:Y.eagerState,next:null},z===null?(w=z=X,b=d):z=z.next=X,wt.lanes|=I,oi|=I;Y=Y.next}while(Y!==null&&Y!==a);if(z===null?b=d:z.next=w,!ze(d,e.memoizedState)&&(re=!0,P&&(l=Sa,l!==null)))throw l;e.memoizedState=d,e.baseState=b,e.baseQueue=z,s.lastRenderedState=d}return f===null&&(s.lanes=0),[e.memoizedState,s.dispatch]}function jo(e){var a=Wt(),l=a.queue;if(l===null)throw Error(u(311));l.lastRenderedReducer=e;var s=l.dispatch,f=l.pending,d=a.memoizedState;if(f!==null){l.pending=null;var b=f=f.next;do d=e(d,b.action),b=b.next;while(b!==f);ze(d,a.memoizedState)||(re=!0),a.memoizedState=d,a.baseQueue===null&&(a.baseState=d),l.lastRenderedState=d}return[d,s]}function xd(e,a,l){var s=wt,f=Wt(),d=Nt;if(d){if(l===void 0)throw Error(u(407));l=l()}else l=a();var b=!ze((jt||f).memoizedState,l);b&&(f.memoizedState=l,re=!0),f=f.queue;var w=Ad.bind(null,s,f,e);if(Or(2048,8,w,[e]),f.getSnapshot!==a||b||Jt!==null&&Jt.memoizedState.tag&1){if(s.flags|=2048,Oa(9,lu(),Sd.bind(null,s,f,l,a),null),Lt===null)throw Error(u(349));d||(ni&124)!==0||wd(s,a,l)}return l}function wd(e,a,l){e.flags|=16384,e={getSnapshot:a,value:l},a=wt.updateQueue,a===null?(a=zo(),wt.updateQueue=a,a.stores=[e]):(l=a.stores,l===null?a.stores=[e]:l.push(e))}function Sd(e,a,l,s){a.value=l,a.getSnapshot=s,Ed(a)&&Td(e)}function Ad(e,a,l){return l(function(){Ed(a)&&Td(e)})}function Ed(e){var a=e.getSnapshot;e=e.value;try{var l=a();return!ze(e,l)}catch{return!0}}function Td(e){var a=va(e,2);a!==null&&qe(a,e,2)}function ko(e){var a=Te();if(typeof e=="function"){var l=e;if(e=l(),Gi){cn(!0);try{l()}finally{cn(!1)}}}return a.memoizedState=a.baseState=e,a.queue={pending:null,lanes:0,dispatch:null,lastRenderedReducer:jn,lastRenderedState:e},a}function Od(e,a,l,s){return e.baseState=l,Do(e,jt,typeof s=="function"?s:jn)}function l1(e,a,l,s,f){if(su(e))throw Error(u(485));if(e=a.action,e!==null){var d={payload:f,action:e,next:null,isTransition:!0,status:"pending",value:null,reason:null,listeners:[],then:function(b){d.listeners.push(b)}};N.T!==null?l(!0):d.isTransition=!1,s(d),l=a.pending,l===null?(d.next=a.pending=d,Md(a,d)):(d.next=l.next,a.pending=l.next=d)}}function Md(e,a){var l=a.action,s=a.payload,f=e.state;if(a.isTransition){var d=N.T,b={};N.T=b;try{var w=l(f,s),z=N.S;z!==null&&z(b,w),Cd(e,a,w)}catch(Y){Uo(e,a,Y)}finally{N.T=d}}else try{d=l(f,s),Cd(e,a,d)}catch(Y){Uo(e,a,Y)}}function Cd(e,a,l){l!==null&&typeof l=="object"&&typeof l.then=="function"?l.then(function(s){Nd(e,a,s)},function(s){return Uo(e,a,s)}):Nd(e,a,l)}function Nd(e,a,l){a.status="fulfilled",a.value=l,zd(a),e.state=l,a=e.pending,a!==null&&(l=a.next,l===a?e.pending=null:(l=l.next,a.next=l,Md(e,l)))}function Uo(e,a,l){var s=e.pending;if(e.pending=null,s!==null){s=s.next;do a.status="rejected",a.reason=l,zd(a),a=a.next;while(a!==s)}e.action=null}function zd(e){e=e.listeners;for(var a=0;a<e.length;a++)(0,e[a])()}function Rd(e,a){return a}function Dd(e,a){if(Nt){var l=Lt.formState;if(l!==null){t:{var s=wt;if(Nt){if(Vt){e:{for(var f=Vt,d=hn;f.nodeType!==8;){if(!d){f=null;break e}if(f=an(f.nextSibling),f===null){f=null;break e}}d=f.data,f=d==="F!"||d==="F"?f:null}if(f){Vt=an(f.nextSibling),s=f.data==="F!";break t}}qi(s)}s=!1}s&&(a=l[0])}}return l=Te(),l.memoizedState=l.baseState=a,s={pending:null,lanes:0,dispatch:null,lastRenderedReducer:Rd,lastRenderedState:a},l.queue=s,l=Wd.bind(null,wt,s),s.dispatch=l,s=ko(!1),d=Go.bind(null,wt,!1,s.queue),s=Te(),f={state:a,dispatch:null,action:e,pending:null},s.queue=f,l=l1.bind(null,wt,f,d,l),f.dispatch=l,s.memoizedState=e,[a,l,!1]}function jd(e){var a=Wt();return kd(a,jt,e)}function kd(e,a,l){if(a=Do(e,a,Rd)[0],e=ru(jn)[0],typeof a=="object"&&a!==null&&typeof a.then=="function")try{var s=Tr(a)}catch(b){throw b===_r?Il:b}else s=a;a=Wt();var f=a.queue,d=f.dispatch;return l!==a.memoizedState&&(wt.flags|=2048,Oa(9,lu(),u1.bind(null,f,l),null)),[s,d,e]}function u1(e,a){e.action=a}function Ud(e){var a=Wt(),l=jt;if(l!==null)return kd(a,l,e);Wt(),a=a.memoizedState,l=Wt();var s=l.queue.dispatch;return l.memoizedState=e,[a,s,!1]}function Oa(e,a,l,s){return e={tag:e,create:l,deps:s,inst:a,next:null},a=wt.updateQueue,a===null&&(a=zo(),wt.updateQueue=a),l=a.lastEffect,l===null?a.lastEffect=e.next=e:(s=l.next,l.next=e,e.next=s,a.lastEffect=e),e}function lu(){return{destroy:void 0,resource:void 0}}function qd(){return Wt().memoizedState}function uu(e,a,l,s){var f=Te();s=s===void 0?null:s,wt.flags|=e,f.memoizedState=Oa(1|a,lu(),l,s)}function Or(e,a,l,s){var f=Wt();s=s===void 0?null:s;var d=f.memoizedState.inst;jt!==null&&s!==null&&To(s,jt.memoizedState.deps)?f.memoizedState=Oa(a,d,l,s):(wt.flags|=e,f.memoizedState=Oa(1|a,d,l,s))}function Hd(e,a){uu(8390656,8,e,a)}function Ld(e,a){Or(2048,8,e,a)}function Bd(e,a){return Or(4,2,e,a)}function Gd(e,a){return Or(4,4,e,a)}function Qd(e,a){if(typeof a=="function"){e=e();var l=a(e);return function(){typeof l=="function"?l():a(null)}}if(a!=null)return e=e(),a.current=e,function(){a.current=null}}function Yd(e,a,l){l=l!=null?l.concat([e]):null,Or(4,4,Qd.bind(null,a,e),l)}function qo(){}function Xd(e,a){var l=Wt();a=a===void 0?null:a;var s=l.memoizedState;return a!==null&&To(a,s[1])?s[0]:(l.memoizedState=[e,a],e)}function Vd(e,a){var l=Wt();a=a===void 0?null:a;var s=l.memoizedState;if(a!==null&&To(a,s[1]))return s[0];if(s=e(),Gi){cn(!0);try{e()}finally{cn(!1)}}return l.memoizedState=[s,a],s}function Ho(e,a,l){return l===void 0||(ni&1073741824)!==0?e.memoizedState=a:(e.memoizedState=l,e=K0(),wt.lanes|=e,oi|=e,l)}function $d(e,a,l,s){return ze(l,a)?l:Aa.current!==null?(e=Ho(e,l,s),ze(e,a)||(re=!0),e):(ni&42)===0?(re=!0,e.memoizedState=l):(e=K0(),wt.lanes|=e,oi|=e,a)}function Zd(e,a,l,s,f){var d=Z.p;Z.p=d!==0&&8>d?d:8;var b=N.T,w={};N.T=w,Go(e,!1,a,l);try{var z=f(),Y=N.S;if(Y!==null&&Y(w,z),z!==null&&typeof z=="object"&&typeof z.then=="function"){var P=i1(z,s);Mr(e,a,P,Ue(e))}else Mr(e,a,s,Ue(e))}catch(I){Mr(e,a,{then:function(){},status:"rejected",reason:I},Ue())}finally{Z.p=d,N.T=b}}function s1(){}function Lo(e,a,l,s){if(e.tag!==5)throw Error(u(476));var f=Kd(e).queue;Zd(e,f,a,et,l===null?s1:function(){return Fd(e),l(s)})}function Kd(e){var a=e.memoizedState;if(a!==null)return a;a={memoizedState:et,baseState:et,baseQueue:null,queue:{pending:null,lanes:0,dispatch:null,lastRenderedReducer:jn,lastRenderedState:et},next:null};var l={};return a.next={memoizedState:l,baseState:l,baseQueue:null,queue:{pending:null,lanes:0,dispatch:null,lastRenderedReducer:jn,lastRenderedState:l},next:null},e.memoizedState=a,e=e.alternate,e!==null&&(e.memoizedState=a),a}function Fd(e){var a=Kd(e).next.queue;Mr(e,a,{},Ue())}function Bo(){return pe($r)}function Pd(){return Wt().memoizedState}function Jd(){return Wt().memoizedState}function o1(e){for(var a=e.return;a!==null;){switch(a.tag){case 24:case 3:var l=Ue();e=ti(l);var s=ei(a,e,l);s!==null&&(qe(s,a,l),wr(s,a,l)),a={cache:yo()},e.payload=a;return}a=a.return}}function c1(e,a,l){var s=Ue();l={lane:s,revertLane:0,action:l,hasEagerState:!1,eagerState:null,next:null},su(e)?Id(a,l):(l=ro(e,a,l,s),l!==null&&(qe(l,e,s),t0(l,a,s)))}function Wd(e,a,l){var s=Ue();Mr(e,a,l,s)}function Mr(e,a,l,s){var f={lane:s,revertLane:0,action:l,hasEagerState:!1,eagerState:null,next:null};if(su(e))Id(a,f);else{var d=e.alternate;if(e.lanes===0&&(d===null||d.lanes===0)&&(d=a.lastRenderedReducer,d!==null))try{var b=a.lastRenderedState,w=d(b,l);if(f.hasEagerState=!0,f.eagerState=w,ze(w,b))return Vl(e,a,f,0),Lt===null&&Xl(),!1}catch{}finally{}if(l=ro(e,a,f,s),l!==null)return qe(l,e,s),t0(l,a,s),!0}return!1}function Go(e,a,l,s){if(s={lane:2,revertLane:bc(),action:s,hasEagerState:!1,eagerState:null,next:null},su(e)){if(a)throw Error(u(479))}else a=ro(e,l,s,2),a!==null&&qe(a,e,2)}function su(e){var a=e.alternate;return e===wt||a!==null&&a===wt}function Id(e,a){Ea=nu=!0;var l=e.pending;l===null?a.next=a:(a.next=l.next,l.next=a),e.pending=a}function t0(e,a,l){if((l&4194048)!==0){var s=a.lanes;s&=e.pendingLanes,l|=s,a.lanes=l,rt(e,l)}}var ou={readContext:pe,use:au,useCallback:Ft,useContext:Ft,useEffect:Ft,useImperativeHandle:Ft,useLayoutEffect:Ft,useInsertionEffect:Ft,useMemo:Ft,useReducer:Ft,useRef:Ft,useState:Ft,useDebugValue:Ft,useDeferredValue:Ft,useTransition:Ft,useSyncExternalStore:Ft,useId:Ft,useHostTransitionStatus:Ft,useFormState:Ft,useActionState:Ft,useOptimistic:Ft,useMemoCache:Ft,useCacheRefresh:Ft},e0={readContext:pe,use:au,useCallback:function(e,a){return Te().memoizedState=[e,a===void 0?null:a],e},useContext:pe,useEffect:Hd,useImperativeHandle:function(e,a,l){l=l!=null?l.concat([e]):null,uu(4194308,4,Qd.bind(null,a,e),l)},useLayoutEffect:function(e,a){return uu(4194308,4,e,a)},useInsertionEffect:function(e,a){uu(4,2,e,a)},useMemo:function(e,a){var l=Te();a=a===void 0?null:a;var s=e();if(Gi){cn(!0);try{e()}finally{cn(!1)}}return l.memoizedState=[s,a],s},useReducer:function(e,a,l){var s=Te();if(l!==void 0){var f=l(a);if(Gi){cn(!0);try{l(a)}finally{cn(!1)}}}else f=a;return s.memoizedState=s.baseState=f,e={pending:null,lanes:0,dispatch:null,lastRenderedReducer:e,lastRenderedState:f},s.queue=e,e=e.dispatch=c1.bind(null,wt,e),[s.memoizedState,e]},useRef:function(e){var a=Te();return e={current:e},a.memoizedState=e},useState:function(e){e=ko(e);var a=e.queue,l=Wd.bind(null,wt,a);return a.dispatch=l,[e.memoizedState,l]},useDebugValue:qo,useDeferredValue:function(e,a){var l=Te();return Ho(l,e,a)},useTransition:function(){var e=ko(!1);return e=Zd.bind(null,wt,e.queue,!0,!1),Te().memoizedState=e,[!1,e]},useSyncExternalStore:function(e,a,l){var s=wt,f=Te();if(Nt){if(l===void 0)throw Error(u(407));l=l()}else{if(l=a(),Lt===null)throw Error(u(349));(Ot&124)!==0||wd(s,a,l)}f.memoizedState=l;var d={value:l,getSnapshot:a};return f.queue=d,Hd(Ad.bind(null,s,d,e),[e]),s.flags|=2048,Oa(9,lu(),Sd.bind(null,s,d,l,a),null),l},useId:function(){var e=Te(),a=Lt.identifierPrefix;if(Nt){var l=zn,s=Nn;l=(s&~(1<<32-be(s)-1)).toString(32)+l,a="«"+a+"R"+l,l=iu++,0<l&&(a+="H"+l.toString(32)),a+="»"}else l=a1++,a="«"+a+"r"+l.toString(32)+"»";return e.memoizedState=a},useHostTransitionStatus:Bo,useFormState:Dd,useActionState:Dd,useOptimistic:function(e){var a=Te();a.memoizedState=a.baseState=e;var l={pending:null,lanes:0,dispatch:null,lastRenderedReducer:null,lastRenderedState:null};return a.queue=l,a=Go.bind(null,wt,!0,l),l.dispatch=a,[e,a]},useMemoCache:Ro,useCacheRefresh:function(){return Te().memoizedState=o1.bind(null,wt)}},n0={readContext:pe,use:au,useCallback:Xd,useContext:pe,useEffect:Ld,useImperativeHandle:Yd,useInsertionEffect:Bd,useLayoutEffect:Gd,useMemo:Vd,useReducer:ru,useRef:qd,useState:function(){return ru(jn)},useDebugValue:qo,useDeferredValue:function(e,a){var l=Wt();return $d(l,jt.memoizedState,e,a)},useTransition:function(){var e=ru(jn)[0],a=Wt().memoizedState;return[typeof e=="boolean"?e:Tr(e),a]},useSyncExternalStore:xd,useId:Pd,useHostTransitionStatus:Bo,useFormState:jd,useActionState:jd,useOptimistic:function(e,a){var l=Wt();return Od(l,jt,e,a)},useMemoCache:Ro,useCacheRefresh:Jd},f1={readContext:pe,use:au,useCallback:Xd,useContext:pe,useEffect:Ld,useImperativeHandle:Yd,useInsertionEffect:Bd,useLayoutEffect:Gd,useMemo:Vd,useReducer:jo,useRef:qd,useState:function(){return jo(jn)},useDebugValue:qo,useDeferredValue:function(e,a){var l=Wt();return jt===null?Ho(l,e,a):$d(l,jt.memoizedState,e,a)},useTransition:function(){var e=jo(jn)[0],a=Wt().memoizedState;return[typeof e=="boolean"?e:Tr(e),a]},useSyncExternalStore:xd,useId:Pd,useHostTransitionStatus:Bo,useFormState:Ud,useActionState:Ud,useOptimistic:function(e,a){var l=Wt();return jt!==null?Od(l,jt,e,a):(l.baseState=e,[e,l.queue.dispatch])},useMemoCache:Ro,useCacheRefresh:Jd},Ma=null,Cr=0;function cu(e){var a=Cr;return Cr+=1,Ma===null&&(Ma=[]),dd(Ma,e,a)}function Nr(e,a){a=a.props.ref,e.ref=a!==void 0?a:null}function fu(e,a){throw a.$$typeof===m?Error(u(525)):(e=Object.prototype.toString.call(a),Error(u(31,e==="[object Object]"?"object with keys {"+Object.keys(a).join(", ")+"}":e)))}function i0(e){var a=e._init;return a(e._payload)}function a0(e){function a(B,D){if(e){var G=B.deletions;G===null?(B.deletions=[D],B.flags|=16):G.push(D)}}function l(B,D){if(!e)return null;for(;D!==null;)a(B,D),D=D.sibling;return null}function s(B){for(var D=new Map;B!==null;)B.key!==null?D.set(B.key,B):D.set(B.index,B),B=B.sibling;return D}function f(B,D){return B=Cn(B,D),B.index=0,B.sibling=null,B}function d(B,D,G){return B.index=G,e?(G=B.alternate,G!==null?(G=G.index,G<D?(B.flags|=67108866,D):G):(B.flags|=67108866,D)):(B.flags|=1048576,D)}function b(B){return e&&B.alternate===null&&(B.flags|=67108866),B}function w(B,D,G,W){return D===null||D.tag!==6?(D=uo(G,B.mode,W),D.return=B,D):(D=f(D,G),D.return=B,D)}function z(B,D,G,W){var ft=G.type;return ft===A?P(B,D,G.props.children,W,G.key):D!==null&&(D.elementType===ft||typeof ft=="object"&&ft!==null&&ft.$$typeof===Q&&i0(ft)===D.type)?(D=f(D,G.props),Nr(D,G),D.return=B,D):(D=Zl(G.type,G.key,G.props,null,B.mode,W),Nr(D,G),D.return=B,D)}function Y(B,D,G,W){return D===null||D.tag!==4||D.stateNode.containerInfo!==G.containerInfo||D.stateNode.implementation!==G.implementation?(D=so(G,B.mode,W),D.return=B,D):(D=f(D,G.children||[]),D.return=B,D)}function P(B,D,G,W,ft){return D===null||D.tag!==7?(D=Di(G,B.mode,W,ft),D.return=B,D):(D=f(D,G),D.return=B,D)}function I(B,D,G){if(typeof D=="string"&&D!==""||typeof D=="number"||typeof D=="bigint")return D=uo(""+D,B.mode,G),D.return=B,D;if(typeof D=="object"&&D!==null){switch(D.$$typeof){case _:return G=Zl(D.type,D.key,D.props,null,B.mode,G),Nr(G,D),G.return=B,G;case x:return D=so(D,B.mode,G),D.return=B,D;case Q:var W=D._init;return D=W(D._payload),I(B,D,G)}if(J(D)||it(D))return D=Di(D,B.mode,G,null),D.return=B,D;if(typeof D.then=="function")return I(B,cu(D),G);if(D.$$typeof===H)return I(B,Jl(B,D),G);fu(B,D)}return null}function X(B,D,G,W){var ft=D!==null?D.key:null;if(typeof G=="string"&&G!==""||typeof G=="number"||typeof G=="bigint")return ft!==null?null:w(B,D,""+G,W);if(typeof G=="object"&&G!==null){switch(G.$$typeof){case _:return G.key===ft?z(B,D,G,W):null;case x:return G.key===ft?Y(B,D,G,W):null;case Q:return ft=G._init,G=ft(G._payload),X(B,D,G,W)}if(J(G)||it(G))return ft!==null?null:P(B,D,G,W,null);if(typeof G.then=="function")return X(B,D,cu(G),W);if(G.$$typeof===H)return X(B,D,Jl(B,G),W);fu(B,G)}return null}function V(B,D,G,W,ft){if(typeof W=="string"&&W!==""||typeof W=="number"||typeof W=="bigint")return B=B.get(G)||null,w(D,B,""+W,ft);if(typeof W=="object"&&W!==null){switch(W.$$typeof){case _:return B=B.get(W.key===null?G:W.key)||null,z(D,B,W,ft);case x:return B=B.get(W.key===null?G:W.key)||null,Y(D,B,W,ft);case Q:var St=W._init;return W=St(W._payload),V(B,D,G,W,ft)}if(J(W)||it(W))return B=B.get(G)||null,P(D,B,W,ft,null);if(typeof W.then=="function")return V(B,D,G,cu(W),ft);if(W.$$typeof===H)return V(B,D,G,Jl(D,W),ft);fu(D,W)}return null}function _t(B,D,G,W){for(var ft=null,St=null,dt=D,vt=D=0,ue=null;dt!==null&&vt<G.length;vt++){dt.index>vt?(ue=dt,dt=null):ue=dt.sibling;var Mt=X(B,dt,G[vt],W);if(Mt===null){dt===null&&(dt=ue);break}e&&dt&&Mt.alternate===null&&a(B,dt),D=d(Mt,D,vt),St===null?ft=Mt:St.sibling=Mt,St=Mt,dt=ue}if(vt===G.length)return l(B,dt),Nt&&ki(B,vt),ft;if(dt===null){for(;vt<G.length;vt++)dt=I(B,G[vt],W),dt!==null&&(D=d(dt,D,vt),St===null?ft=dt:St.sibling=dt,St=dt);return Nt&&ki(B,vt),ft}for(dt=s(dt);vt<G.length;vt++)ue=V(dt,B,vt,G[vt],W),ue!==null&&(e&&ue.alternate!==null&&dt.delete(ue.key===null?vt:ue.key),D=d(ue,D,vt),St===null?ft=ue:St.sibling=ue,St=ue);return e&&dt.forEach(function(vi){return a(B,vi)}),Nt&&ki(B,vt),ft}function mt(B,D,G,W){if(G==null)throw Error(u(151));for(var ft=null,St=null,dt=D,vt=D=0,ue=null,Mt=G.next();dt!==null&&!Mt.done;vt++,Mt=G.next()){dt.index>vt?(ue=dt,dt=null):ue=dt.sibling;var vi=X(B,dt,Mt.value,W);if(vi===null){dt===null&&(dt=ue);break}e&&dt&&vi.alternate===null&&a(B,dt),D=d(vi,D,vt),St===null?ft=vi:St.sibling=vi,St=vi,dt=ue}if(Mt.done)return l(B,dt),Nt&&ki(B,vt),ft;if(dt===null){for(;!Mt.done;vt++,Mt=G.next())Mt=I(B,Mt.value,W),Mt!==null&&(D=d(Mt,D,vt),St===null?ft=Mt:St.sibling=Mt,St=Mt);return Nt&&ki(B,vt),ft}for(dt=s(dt);!Mt.done;vt++,Mt=G.next())Mt=V(dt,B,vt,Mt.value,W),Mt!==null&&(e&&Mt.alternate!==null&&dt.delete(Mt.key===null?vt:Mt.key),D=d(Mt,D,vt),St===null?ft=Mt:St.sibling=Mt,St=Mt);return e&&dt.forEach(function(hb){return a(B,hb)}),Nt&&ki(B,vt),ft}function Ut(B,D,G,W){if(typeof G=="object"&&G!==null&&G.type===A&&G.key===null&&(G=G.props.children),typeof G=="object"&&G!==null){switch(G.$$typeof){case _:t:{for(var ft=G.key;D!==null;){if(D.key===ft){if(ft=G.type,ft===A){if(D.tag===7){l(B,D.sibling),W=f(D,G.props.children),W.return=B,B=W;break t}}else if(D.elementType===ft||typeof ft=="object"&&ft!==null&&ft.$$typeof===Q&&i0(ft)===D.type){l(B,D.sibling),W=f(D,G.props),Nr(W,G),W.return=B,B=W;break t}l(B,D);break}else a(B,D);D=D.sibling}G.type===A?(W=Di(G.props.children,B.mode,W,G.key),W.return=B,B=W):(W=Zl(G.type,G.key,G.props,null,B.mode,W),Nr(W,G),W.return=B,B=W)}return b(B);case x:t:{for(ft=G.key;D!==null;){if(D.key===ft)if(D.tag===4&&D.stateNode.containerInfo===G.containerInfo&&D.stateNode.implementation===G.implementation){l(B,D.sibling),W=f(D,G.children||[]),W.return=B,B=W;break t}else{l(B,D);break}else a(B,D);D=D.sibling}W=so(G,B.mode,W),W.return=B,B=W}return b(B);case Q:return ft=G._init,G=ft(G._payload),Ut(B,D,G,W)}if(J(G))return _t(B,D,G,W);if(it(G)){if(ft=it(G),typeof ft!="function")throw Error(u(150));return G=ft.call(G),mt(B,D,G,W)}if(typeof G.then=="function")return Ut(B,D,cu(G),W);if(G.$$typeof===H)return Ut(B,D,Jl(B,G),W);fu(B,G)}return typeof G=="string"&&G!==""||typeof G=="number"||typeof G=="bigint"?(G=""+G,D!==null&&D.tag===6?(l(B,D.sibling),W=f(D,G),W.return=B,B=W):(l(B,D),W=uo(G,B.mode,W),W.return=B,B=W),b(B)):l(B,D)}return function(B,D,G,W){try{Cr=0;var ft=Ut(B,D,G,W);return Ma=null,ft}catch(dt){if(dt===_r||dt===Il)throw dt;var St=Re(29,dt,null,B.mode);return St.lanes=W,St.return=B,St}finally{}}}var Ca=a0(!0),r0=a0(!1),Ze=$(null),dn=null;function ii(e){var a=e.alternate;at(ee,ee.current&1),at(Ze,e),dn===null&&(a===null||Aa.current!==null||a.memoizedState!==null)&&(dn=e)}function l0(e){if(e.tag===22){if(at(ee,ee.current),at(Ze,e),dn===null){var a=e.alternate;a!==null&&a.memoizedState!==null&&(dn=e)}}else ai()}function ai(){at(ee,ee.current),at(Ze,Ze.current)}function kn(e){nt(Ze),dn===e&&(dn=null),nt(ee)}var ee=$(0);function hu(e){for(var a=e;a!==null;){if(a.tag===13){var l=a.memoizedState;if(l!==null&&(l=l.dehydrated,l===null||l.data==="$?"||zc(l)))return a}else if(a.tag===19&&a.memoizedProps.revealOrder!==void 0){if((a.flags&128)!==0)return a}else if(a.child!==null){a.child.return=a,a=a.child;continue}if(a===e)break;for(;a.sibling===null;){if(a.return===null||a.return===e)return null;a=a.return}a.sibling.return=a.return,a=a.sibling}return null}function Qo(e,a,l,s){a=e.memoizedState,l=l(s,a),l=l==null?a:v({},a,l),e.memoizedState=l,e.lanes===0&&(e.updateQueue.baseState=l)}var Yo={enqueueSetState:function(e,a,l){e=e._reactInternals;var s=Ue(),f=ti(s);f.payload=a,l!=null&&(f.callback=l),a=ei(e,f,s),a!==null&&(qe(a,e,s),wr(a,e,s))},enqueueReplaceState:function(e,a,l){e=e._reactInternals;var s=Ue(),f=ti(s);f.tag=1,f.payload=a,l!=null&&(f.callback=l),a=ei(e,f,s),a!==null&&(qe(a,e,s),wr(a,e,s))},enqueueForceUpdate:function(e,a){e=e._reactInternals;var l=Ue(),s=ti(l);s.tag=2,a!=null&&(s.callback=a),a=ei(e,s,l),a!==null&&(qe(a,e,l),wr(a,e,l))}};function u0(e,a,l,s,f,d,b){return e=e.stateNode,typeof e.shouldComponentUpdate=="function"?e.shouldComponentUpdate(s,d,b):a.prototype&&a.prototype.isPureReactComponent?!hr(l,s)||!hr(f,d):!0}function s0(e,a,l,s){e=a.state,typeof a.componentWillReceiveProps=="function"&&a.componentWillReceiveProps(l,s),typeof a.UNSAFE_componentWillReceiveProps=="function"&&a.UNSAFE_componentWillReceiveProps(l,s),a.state!==e&&Yo.enqueueReplaceState(a,a.state,null)}function Qi(e,a){var l=a;if("ref"in a){l={};for(var s in a)s!=="ref"&&(l[s]=a[s])}if(e=e.defaultProps){l===a&&(l=v({},l));for(var f in e)l[f]===void 0&&(l[f]=e[f])}return l}var du=typeof reportError=="function"?reportError:function(e){if(typeof window=="object"&&typeof window.ErrorEvent=="function"){var a=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(a))return}else if(typeof process=="object"&&typeof process.emit=="function"){process.emit("uncaughtException",e);return}console.error(e)};function o0(e){du(e)}function c0(e){console.error(e)}function f0(e){du(e)}function gu(e,a){try{var l=e.onUncaughtError;l(a.value,{componentStack:a.stack})}catch(s){setTimeout(function(){throw s})}}function h0(e,a,l){try{var s=e.onCaughtError;s(l.value,{componentStack:l.stack,errorBoundary:a.tag===1?a.stateNode:null})}catch(f){setTimeout(function(){throw f})}}function Xo(e,a,l){return l=ti(l),l.tag=3,l.payload={element:null},l.callback=function(){gu(e,a)},l}function d0(e){return e=ti(e),e.tag=3,e}function g0(e,a,l,s){var f=l.type.getDerivedStateFromError;if(typeof f=="function"){var d=s.value;e.payload=function(){return f(d)},e.callback=function(){h0(a,l,s)}}var b=l.stateNode;b!==null&&typeof b.componentDidCatch=="function"&&(e.callback=function(){h0(a,l,s),typeof f!="function"&&(ci===null?ci=new Set([this]):ci.add(this));var w=s.stack;this.componentDidCatch(s.value,{componentStack:w!==null?w:""})})}function h1(e,a,l,s,f){if(l.flags|=32768,s!==null&&typeof s=="object"&&typeof s.then=="function"){if(a=l.alternate,a!==null&&mr(a,l,f,!0),l=Ze.current,l!==null){switch(l.tag){case 13:return dn===null?gc():l.alternate===null&&$t===0&&($t=3),l.flags&=-257,l.flags|=65536,l.lanes=f,s===bo?l.flags|=16384:(a=l.updateQueue,a===null?l.updateQueue=new Set([s]):a.add(s),yc(e,s,f)),!1;case 22:return l.flags|=65536,s===bo?l.flags|=16384:(a=l.updateQueue,a===null?(a={transitions:null,markerInstances:null,retryQueue:new Set([s])},l.updateQueue=a):(l=a.retryQueue,l===null?a.retryQueue=new Set([s]):l.add(s)),yc(e,s,f)),!1}throw Error(u(435,l.tag))}return yc(e,s,f),gc(),!1}if(Nt)return a=Ze.current,a!==null?((a.flags&65536)===0&&(a.flags|=256),a.flags|=65536,a.lanes=f,s!==fo&&(e=Error(u(422),{cause:s}),yr(Ye(e,l)))):(s!==fo&&(a=Error(u(423),{cause:s}),yr(Ye(a,l))),e=e.current.alternate,e.flags|=65536,f&=-f,e.lanes|=f,s=Ye(s,l),f=Xo(e.stateNode,s,f),wo(e,f),$t!==4&&($t=2)),!1;var d=Error(u(520),{cause:s});if(d=Ye(d,l),qr===null?qr=[d]:qr.push(d),$t!==4&&($t=2),a===null)return!0;s=Ye(s,l),l=a;do{switch(l.tag){case 3:return l.flags|=65536,e=f&-f,l.lanes|=e,e=Xo(l.stateNode,s,e),wo(l,e),!1;case 1:if(a=l.type,d=l.stateNode,(l.flags&128)===0&&(typeof a.getDerivedStateFromError=="function"||d!==null&&typeof d.componentDidCatch=="function"&&(ci===null||!ci.has(d))))return l.flags|=65536,f&=-f,l.lanes|=f,f=d0(f),g0(f,e,l,s),wo(l,f),!1}l=l.return}while(l!==null);return!1}var p0=Error(u(461)),re=!1;function ce(e,a,l,s){a.child=e===null?r0(a,null,l,s):Ca(a,e.child,l,s)}function y0(e,a,l,s,f){l=l.render;var d=a.ref;if("ref"in s){var b={};for(var w in s)w!=="ref"&&(b[w]=s[w])}else b=s;return Li(a),s=Oo(e,a,l,b,d,f),w=Mo(),e!==null&&!re?(Co(e,a,f),Un(e,a,f)):(Nt&&w&&oo(a),a.flags|=1,ce(e,a,s,f),a.child)}function m0(e,a,l,s,f){if(e===null){var d=l.type;return typeof d=="function"&&!lo(d)&&d.defaultProps===void 0&&l.compare===null?(a.tag=15,a.type=d,v0(e,a,d,s,f)):(e=Zl(l.type,null,s,a,a.mode,f),e.ref=a.ref,e.return=a,a.child=e)}if(d=e.child,!Wo(e,f)){var b=d.memoizedProps;if(l=l.compare,l=l!==null?l:hr,l(b,s)&&e.ref===a.ref)return Un(e,a,f)}return a.flags|=1,e=Cn(d,s),e.ref=a.ref,e.return=a,a.child=e}function v0(e,a,l,s,f){if(e!==null){var d=e.memoizedProps;if(hr(d,s)&&e.ref===a.ref)if(re=!1,a.pendingProps=s=d,Wo(e,f))(e.flags&131072)!==0&&(re=!0);else return a.lanes=e.lanes,Un(e,a,f)}return Vo(e,a,l,s,f)}function b0(e,a,l){var s=a.pendingProps,f=s.children,d=e!==null?e.memoizedState:null;if(s.mode==="hidden"){if((a.flags&128)!==0){if(s=d!==null?d.baseLanes|l:l,e!==null){for(f=a.child=e.child,d=0;f!==null;)d=d|f.lanes|f.childLanes,f=f.sibling;a.childLanes=d&~s}else a.childLanes=0,a.child=null;return _0(e,a,s,l)}if((l&536870912)!==0)a.memoizedState={baseLanes:0,cachePool:null},e!==null&&Wl(a,d!==null?d.cachePool:null),d!==null?vd(a,d):Ao(),l0(a);else return a.lanes=a.childLanes=536870912,_0(e,a,d!==null?d.baseLanes|l:l,l)}else d!==null?(Wl(a,d.cachePool),vd(a,d),ai(),a.memoizedState=null):(e!==null&&Wl(a,null),Ao(),ai());return ce(e,a,f,l),a.child}function _0(e,a,l,s){var f=vo();return f=f===null?null:{parent:te._currentValue,pool:f},a.memoizedState={baseLanes:l,cachePool:f},e!==null&&Wl(a,null),Ao(),l0(a),e!==null&&mr(e,a,s,!0),null}function pu(e,a){var l=a.ref;if(l===null)e!==null&&e.ref!==null&&(a.flags|=4194816);else{if(typeof l!="function"&&typeof l!="object")throw Error(u(284));(e===null||e.ref!==l)&&(a.flags|=4194816)}}function Vo(e,a,l,s,f){return Li(a),l=Oo(e,a,l,s,void 0,f),s=Mo(),e!==null&&!re?(Co(e,a,f),Un(e,a,f)):(Nt&&s&&oo(a),a.flags|=1,ce(e,a,l,f),a.child)}function x0(e,a,l,s,f,d){return Li(a),a.updateQueue=null,l=_d(a,s,l,f),bd(e),s=Mo(),e!==null&&!re?(Co(e,a,d),Un(e,a,d)):(Nt&&s&&oo(a),a.flags|=1,ce(e,a,l,d),a.child)}function w0(e,a,l,s,f){if(Li(a),a.stateNode===null){var d=ba,b=l.contextType;typeof b=="object"&&b!==null&&(d=pe(b)),d=new l(s,d),a.memoizedState=d.state!==null&&d.state!==void 0?d.state:null,d.updater=Yo,a.stateNode=d,d._reactInternals=a,d=a.stateNode,d.props=s,d.state=a.memoizedState,d.refs={},_o(a),b=l.contextType,d.context=typeof b=="object"&&b!==null?pe(b):ba,d.state=a.memoizedState,b=l.getDerivedStateFromProps,typeof b=="function"&&(Qo(a,l,b,s),d.state=a.memoizedState),typeof l.getDerivedStateFromProps=="function"||typeof d.getSnapshotBeforeUpdate=="function"||typeof d.UNSAFE_componentWillMount!="function"&&typeof d.componentWillMount!="function"||(b=d.state,typeof d.componentWillMount=="function"&&d.componentWillMount(),typeof d.UNSAFE_componentWillMount=="function"&&d.UNSAFE_componentWillMount(),b!==d.state&&Yo.enqueueReplaceState(d,d.state,null),Ar(a,s,d,f),Sr(),d.state=a.memoizedState),typeof d.componentDidMount=="function"&&(a.flags|=4194308),s=!0}else if(e===null){d=a.stateNode;var w=a.memoizedProps,z=Qi(l,w);d.props=z;var Y=d.context,P=l.contextType;b=ba,typeof P=="object"&&P!==null&&(b=pe(P));var I=l.getDerivedStateFromProps;P=typeof I=="function"||typeof d.getSnapshotBeforeUpdate=="function",w=a.pendingProps!==w,P||typeof d.UNSAFE_componentWillReceiveProps!="function"&&typeof d.componentWillReceiveProps!="function"||(w||Y!==b)&&s0(a,d,s,b),In=!1;var X=a.memoizedState;d.state=X,Ar(a,s,d,f),Sr(),Y=a.memoizedState,w||X!==Y||In?(typeof I=="function"&&(Qo(a,l,I,s),Y=a.memoizedState),(z=In||u0(a,l,z,s,X,Y,b))?(P||typeof d.UNSAFE_componentWillMount!="function"&&typeof d.componentWillMount!="function"||(typeof d.componentWillMount=="function"&&d.componentWillMount(),typeof d.UNSAFE_componentWillMount=="function"&&d.UNSAFE_componentWillMount()),typeof d.componentDidMount=="function"&&(a.flags|=4194308)):(typeof d.componentDidMount=="function"&&(a.flags|=4194308),a.memoizedProps=s,a.memoizedState=Y),d.props=s,d.state=Y,d.context=b,s=z):(typeof d.componentDidMount=="function"&&(a.flags|=4194308),s=!1)}else{d=a.stateNode,xo(e,a),b=a.memoizedProps,P=Qi(l,b),d.props=P,I=a.pendingProps,X=d.context,Y=l.contextType,z=ba,typeof Y=="object"&&Y!==null&&(z=pe(Y)),w=l.getDerivedStateFromProps,(Y=typeof w=="function"||typeof d.getSnapshotBeforeUpdate=="function")||typeof d.UNSAFE_componentWillReceiveProps!="function"&&typeof d.componentWillReceiveProps!="function"||(b!==I||X!==z)&&s0(a,d,s,z),In=!1,X=a.memoizedState,d.state=X,Ar(a,s,d,f),Sr();var V=a.memoizedState;b!==I||X!==V||In||e!==null&&e.dependencies!==null&&Pl(e.dependencies)?(typeof w=="function"&&(Qo(a,l,w,s),V=a.memoizedState),(P=In||u0(a,l,P,s,X,V,z)||e!==null&&e.dependencies!==null&&Pl(e.dependencies))?(Y||typeof d.UNSAFE_componentWillUpdate!="function"&&typeof d.componentWillUpdate!="function"||(typeof d.componentWillUpdate=="function"&&d.componentWillUpdate(s,V,z),typeof d.UNSAFE_componentWillUpdate=="function"&&d.UNSAFE_componentWillUpdate(s,V,z)),typeof d.componentDidUpdate=="function"&&(a.flags|=4),typeof d.getSnapshotBeforeUpdate=="function"&&(a.flags|=1024)):(typeof d.componentDidUpdate!="function"||b===e.memoizedProps&&X===e.memoizedState||(a.flags|=4),typeof d.getSnapshotBeforeUpdate!="function"||b===e.memoizedProps&&X===e.memoizedState||(a.flags|=1024),a.memoizedProps=s,a.memoizedState=V),d.props=s,d.state=V,d.context=z,s=P):(typeof d.componentDidUpdate!="function"||b===e.memoizedProps&&X===e.memoizedState||(a.flags|=4),typeof d.getSnapshotBeforeUpdate!="function"||b===e.memoizedProps&&X===e.memoizedState||(a.flags|=1024),s=!1)}return d=s,pu(e,a),s=(a.flags&128)!==0,d||s?(d=a.stateNode,l=s&&typeof l.getDerivedStateFromError!="function"?null:d.render(),a.flags|=1,e!==null&&s?(a.child=Ca(a,e.child,null,f),a.child=Ca(a,null,l,f)):ce(e,a,l,f),a.memoizedState=d.state,e=a.child):e=Un(e,a,f),e}function S0(e,a,l,s){return pr(),a.flags|=256,ce(e,a,l,s),a.child}var $o={dehydrated:null,treeContext:null,retryLane:0,hydrationErrors:null};function Zo(e){return{baseLanes:e,cachePool:cd()}}function Ko(e,a,l){return e=e!==null?e.childLanes&~l:0,a&&(e|=Ke),e}function A0(e,a,l){var s=a.pendingProps,f=!1,d=(a.flags&128)!==0,b;if((b=d)||(b=e!==null&&e.memoizedState===null?!1:(ee.current&2)!==0),b&&(f=!0,a.flags&=-129),b=(a.flags&32)!==0,a.flags&=-33,e===null){if(Nt){if(f?ii(a):ai(),Nt){var w=Vt,z;if(z=w){t:{for(z=w,w=hn;z.nodeType!==8;){if(!w){w=null;break t}if(z=an(z.nextSibling),z===null){w=null;break t}}w=z}w!==null?(a.memoizedState={dehydrated:w,treeContext:ji!==null?{id:Nn,overflow:zn}:null,retryLane:536870912,hydrationErrors:null},z=Re(18,null,null,0),z.stateNode=w,z.return=a,a.child=z,_e=a,Vt=null,z=!0):z=!1}z||qi(a)}if(w=a.memoizedState,w!==null&&(w=w.dehydrated,w!==null))return zc(w)?a.lanes=32:a.lanes=536870912,null;kn(a)}return w=s.children,s=s.fallback,f?(ai(),f=a.mode,w=yu({mode:"hidden",children:w},f),s=Di(s,f,l,null),w.return=a,s.return=a,w.sibling=s,a.child=w,f=a.child,f.memoizedState=Zo(l),f.childLanes=Ko(e,b,l),a.memoizedState=$o,s):(ii(a),Fo(a,w))}if(z=e.memoizedState,z!==null&&(w=z.dehydrated,w!==null)){if(d)a.flags&256?(ii(a),a.flags&=-257,a=Po(e,a,l)):a.memoizedState!==null?(ai(),a.child=e.child,a.flags|=128,a=null):(ai(),f=s.fallback,w=a.mode,s=yu({mode:"visible",children:s.children},w),f=Di(f,w,l,null),f.flags|=2,s.return=a,f.return=a,s.sibling=f,a.child=s,Ca(a,e.child,null,l),s=a.child,s.memoizedState=Zo(l),s.childLanes=Ko(e,b,l),a.memoizedState=$o,a=f);else if(ii(a),zc(w)){if(b=w.nextSibling&&w.nextSibling.dataset,b)var Y=b.dgst;b=Y,s=Error(u(419)),s.stack="",s.digest=b,yr({value:s,source:null,stack:null}),a=Po(e,a,l)}else if(re||mr(e,a,l,!1),b=(l&e.childLanes)!==0,re||b){if(b=Lt,b!==null&&(s=l&-l,s=(s&42)!==0?1:pt(s),s=(s&(b.suspendedLanes|l))!==0?0:s,s!==0&&s!==z.retryLane))throw z.retryLane=s,va(e,s),qe(b,e,s),p0;w.data==="$?"||gc(),a=Po(e,a,l)}else w.data==="$?"?(a.flags|=192,a.child=e.child,a=null):(e=z.treeContext,Vt=an(w.nextSibling),_e=a,Nt=!0,Ui=null,hn=!1,e!==null&&(Ve[$e++]=Nn,Ve[$e++]=zn,Ve[$e++]=ji,Nn=e.id,zn=e.overflow,ji=a),a=Fo(a,s.children),a.flags|=4096);return a}return f?(ai(),f=s.fallback,w=a.mode,z=e.child,Y=z.sibling,s=Cn(z,{mode:"hidden",children:s.children}),s.subtreeFlags=z.subtreeFlags&65011712,Y!==null?f=Cn(Y,f):(f=Di(f,w,l,null),f.flags|=2),f.return=a,s.return=a,s.sibling=f,a.child=s,s=f,f=a.child,w=e.child.memoizedState,w===null?w=Zo(l):(z=w.cachePool,z!==null?(Y=te._currentValue,z=z.parent!==Y?{parent:Y,pool:Y}:z):z=cd(),w={baseLanes:w.baseLanes|l,cachePool:z}),f.memoizedState=w,f.childLanes=Ko(e,b,l),a.memoizedState=$o,s):(ii(a),l=e.child,e=l.sibling,l=Cn(l,{mode:"visible",children:s.children}),l.return=a,l.sibling=null,e!==null&&(b=a.deletions,b===null?(a.deletions=[e],a.flags|=16):b.push(e)),a.child=l,a.memoizedState=null,l)}function Fo(e,a){return a=yu({mode:"visible",children:a},e.mode),a.return=e,e.child=a}function yu(e,a){return e=Re(22,e,null,a),e.lanes=0,e.stateNode={_visibility:1,_pendingMarkers:null,_retryCache:null,_transitions:null},e}function Po(e,a,l){return Ca(a,e.child,null,l),e=Fo(a,a.pendingProps.children),e.flags|=2,a.memoizedState=null,e}function E0(e,a,l){e.lanes|=a;var s=e.alternate;s!==null&&(s.lanes|=a),go(e.return,a,l)}function Jo(e,a,l,s,f){var d=e.memoizedState;d===null?e.memoizedState={isBackwards:a,rendering:null,renderingStartTime:0,last:s,tail:l,tailMode:f}:(d.isBackwards=a,d.rendering=null,d.renderingStartTime=0,d.last=s,d.tail=l,d.tailMode=f)}function T0(e,a,l){var s=a.pendingProps,f=s.revealOrder,d=s.tail;if(ce(e,a,s.children,l),s=ee.current,(s&2)!==0)s=s&1|2,a.flags|=128;else{if(e!==null&&(e.flags&128)!==0)t:for(e=a.child;e!==null;){if(e.tag===13)e.memoizedState!==null&&E0(e,l,a);else if(e.tag===19)E0(e,l,a);else if(e.child!==null){e.child.return=e,e=e.child;continue}if(e===a)break t;for(;e.sibling===null;){if(e.return===null||e.return===a)break t;e=e.return}e.sibling.return=e.return,e=e.sibling}s&=1}switch(at(ee,s),f){case"forwards":for(l=a.child,f=null;l!==null;)e=l.alternate,e!==null&&hu(e)===null&&(f=l),l=l.sibling;l=f,l===null?(f=a.child,a.child=null):(f=l.sibling,l.sibling=null),Jo(a,!1,f,l,d);break;case"backwards":for(l=null,f=a.child,a.child=null;f!==null;){if(e=f.alternate,e!==null&&hu(e)===null){a.child=f;break}e=f.sibling,f.sibling=l,l=f,f=e}Jo(a,!0,l,null,d);break;case"together":Jo(a,!1,null,null,void 0);break;default:a.memoizedState=null}return a.child}function Un(e,a,l){if(e!==null&&(a.dependencies=e.dependencies),oi|=a.lanes,(l&a.childLanes)===0)if(e!==null){if(mr(e,a,l,!1),(l&a.childLanes)===0)return null}else return null;if(e!==null&&a.child!==e.child)throw Error(u(153));if(a.child!==null){for(e=a.child,l=Cn(e,e.pendingProps),a.child=l,l.return=a;e.sibling!==null;)e=e.sibling,l=l.sibling=Cn(e,e.pendingProps),l.return=a;l.sibling=null}return a.child}function Wo(e,a){return(e.lanes&a)!==0?!0:(e=e.dependencies,!!(e!==null&&Pl(e)))}function d1(e,a,l){switch(a.tag){case 3:At(a,a.stateNode.containerInfo),Wn(a,te,e.memoizedState.cache),pr();break;case 27:case 5:Wa(a);break;case 4:At(a,a.stateNode.containerInfo);break;case 10:Wn(a,a.type,a.memoizedProps.value);break;case 13:var s=a.memoizedState;if(s!==null)return s.dehydrated!==null?(ii(a),a.flags|=128,null):(l&a.child.childLanes)!==0?A0(e,a,l):(ii(a),e=Un(e,a,l),e!==null?e.sibling:null);ii(a);break;case 19:var f=(e.flags&128)!==0;if(s=(l&a.childLanes)!==0,s||(mr(e,a,l,!1),s=(l&a.childLanes)!==0),f){if(s)return T0(e,a,l);a.flags|=128}if(f=a.memoizedState,f!==null&&(f.rendering=null,f.tail=null,f.lastEffect=null),at(ee,ee.current),s)break;return null;case 22:case 23:return a.lanes=0,b0(e,a,l);case 24:Wn(a,te,e.memoizedState.cache)}return Un(e,a,l)}function O0(e,a,l){if(e!==null)if(e.memoizedProps!==a.pendingProps)re=!0;else{if(!Wo(e,l)&&(a.flags&128)===0)return re=!1,d1(e,a,l);re=(e.flags&131072)!==0}else re=!1,Nt&&(a.flags&1048576)!==0&&id(a,Fl,a.index);switch(a.lanes=0,a.tag){case 16:t:{e=a.pendingProps;var s=a.elementType,f=s._init;if(s=f(s._payload),a.type=s,typeof s=="function")lo(s)?(e=Qi(s,e),a.tag=1,a=w0(null,a,s,e,l)):(a.tag=0,a=Vo(null,a,s,e,l));else{if(s!=null){if(f=s.$$typeof,f===R){a.tag=11,a=y0(null,a,s,e,l);break t}else if(f===U){a.tag=14,a=m0(null,a,s,e,l);break t}}throw a=L(s)||s,Error(u(306,a,""))}}return a;case 0:return Vo(e,a,a.type,a.pendingProps,l);case 1:return s=a.type,f=Qi(s,a.pendingProps),w0(e,a,s,f,l);case 3:t:{if(At(a,a.stateNode.containerInfo),e===null)throw Error(u(387));s=a.pendingProps;var d=a.memoizedState;f=d.element,xo(e,a),Ar(a,s,null,l);var b=a.memoizedState;if(s=b.cache,Wn(a,te,s),s!==d.cache&&po(a,[te],l,!0),Sr(),s=b.element,d.isDehydrated)if(d={element:s,isDehydrated:!1,cache:b.cache},a.updateQueue.baseState=d,a.memoizedState=d,a.flags&256){a=S0(e,a,s,l);break t}else if(s!==f){f=Ye(Error(u(424)),a),yr(f),a=S0(e,a,s,l);break t}else{switch(e=a.stateNode.containerInfo,e.nodeType){case 9:e=e.body;break;default:e=e.nodeName==="HTML"?e.ownerDocument.body:e}for(Vt=an(e.firstChild),_e=a,Nt=!0,Ui=null,hn=!0,l=r0(a,null,s,l),a.child=l;l;)l.flags=l.flags&-3|4096,l=l.sibling}else{if(pr(),s===f){a=Un(e,a,l);break t}ce(e,a,s,l)}a=a.child}return a;case 26:return pu(e,a),e===null?(l=zg(a.type,null,a.pendingProps,null))?a.memoizedState=l:Nt||(l=a.type,e=a.pendingProps,s=Nu(ht.current).createElement(l),s[It]=a,s[Kt]=e,he(s,l,e),ae(s),a.stateNode=s):a.memoizedState=zg(a.type,e.memoizedProps,a.pendingProps,e.memoizedState),null;case 27:return Wa(a),e===null&&Nt&&(s=a.stateNode=Mg(a.type,a.pendingProps,ht.current),_e=a,hn=!0,f=Vt,di(a.type)?(Rc=f,Vt=an(s.firstChild)):Vt=f),ce(e,a,a.pendingProps.children,l),pu(e,a),e===null&&(a.flags|=4194304),a.child;case 5:return e===null&&Nt&&((f=s=Vt)&&(s=G1(s,a.type,a.pendingProps,hn),s!==null?(a.stateNode=s,_e=a,Vt=an(s.firstChild),hn=!1,f=!0):f=!1),f||qi(a)),Wa(a),f=a.type,d=a.pendingProps,b=e!==null?e.memoizedProps:null,s=d.children,Mc(f,d)?s=null:b!==null&&Mc(f,b)&&(a.flags|=32),a.memoizedState!==null&&(f=Oo(e,a,r1,null,null,l),$r._currentValue=f),pu(e,a),ce(e,a,s,l),a.child;case 6:return e===null&&Nt&&((e=l=Vt)&&(l=Q1(l,a.pendingProps,hn),l!==null?(a.stateNode=l,_e=a,Vt=null,e=!0):e=!1),e||qi(a)),null;case 13:return A0(e,a,l);case 4:return At(a,a.stateNode.containerInfo),s=a.pendingProps,e===null?a.child=Ca(a,null,s,l):ce(e,a,s,l),a.child;case 11:return y0(e,a,a.type,a.pendingProps,l);case 7:return ce(e,a,a.pendingProps,l),a.child;case 8:return ce(e,a,a.pendingProps.children,l),a.child;case 12:return ce(e,a,a.pendingProps.children,l),a.child;case 10:return s=a.pendingProps,Wn(a,a.type,s.value),ce(e,a,s.children,l),a.child;case 9:return f=a.type._context,s=a.pendingProps.children,Li(a),f=pe(f),s=s(f),a.flags|=1,ce(e,a,s,l),a.child;case 14:return m0(e,a,a.type,a.pendingProps,l);case 15:return v0(e,a,a.type,a.pendingProps,l);case 19:return T0(e,a,l);case 31:return s=a.pendingProps,l=a.mode,s={mode:s.mode,children:s.children},e===null?(l=yu(s,l),l.ref=a.ref,a.child=l,l.return=a,a=l):(l=Cn(e.child,s),l.ref=a.ref,a.child=l,l.return=a,a=l),a;case 22:return b0(e,a,l);case 24:return Li(a),s=pe(te),e===null?(f=vo(),f===null&&(f=Lt,d=yo(),f.pooledCache=d,d.refCount++,d!==null&&(f.pooledCacheLanes|=l),f=d),a.memoizedState={parent:s,cache:f},_o(a),Wn(a,te,f)):((e.lanes&l)!==0&&(xo(e,a),Ar(a,null,null,l),Sr()),f=e.memoizedState,d=a.memoizedState,f.parent!==s?(f={parent:s,cache:s},a.memoizedState=f,a.lanes===0&&(a.memoizedState=a.updateQueue.baseState=f),Wn(a,te,s)):(s=d.cache,Wn(a,te,s),s!==f.cache&&po(a,[te],l,!0))),ce(e,a,a.pendingProps.children,l),a.child;case 29:throw a.pendingProps}throw Error(u(156,a.tag))}function qn(e){e.flags|=4}function M0(e,a){if(a.type!=="stylesheet"||(a.state.loading&4)!==0)e.flags&=-16777217;else if(e.flags|=16777216,!Ug(a)){if(a=Ze.current,a!==null&&((Ot&4194048)===Ot?dn!==null:(Ot&62914560)!==Ot&&(Ot&536870912)===0||a!==dn))throw xr=bo,fd;e.flags|=8192}}function mu(e,a){a!==null&&(e.flags|=4),e.flags&16384&&(a=e.tag!==22?Rl():536870912,e.lanes|=a,Da|=a)}function zr(e,a){if(!Nt)switch(e.tailMode){case"hidden":a=e.tail;for(var l=null;a!==null;)a.alternate!==null&&(l=a),a=a.sibling;l===null?e.tail=null:l.sibling=null;break;case"collapsed":l=e.tail;for(var s=null;l!==null;)l.alternate!==null&&(s=l),l=l.sibling;s===null?a||e.tail===null?e.tail=null:e.tail.sibling=null:s.sibling=null}}function Xt(e){var a=e.alternate!==null&&e.alternate.child===e.child,l=0,s=0;if(a)for(var f=e.child;f!==null;)l|=f.lanes|f.childLanes,s|=f.subtreeFlags&65011712,s|=f.flags&65011712,f.return=e,f=f.sibling;else for(f=e.child;f!==null;)l|=f.lanes|f.childLanes,s|=f.subtreeFlags,s|=f.flags,f.return=e,f=f.sibling;return e.subtreeFlags|=s,e.childLanes=l,a}function g1(e,a,l){var s=a.pendingProps;switch(co(a),a.tag){case 31:case 16:case 15:case 0:case 11:case 7:case 8:case 12:case 9:case 14:return Xt(a),null;case 1:return Xt(a),null;case 3:return l=a.stateNode,s=null,e!==null&&(s=e.memoizedState.cache),a.memoizedState.cache!==s&&(a.flags|=2048),Dn(te),ve(),l.pendingContext&&(l.context=l.pendingContext,l.pendingContext=null),(e===null||e.child===null)&&(gr(a)?qn(a):e===null||e.memoizedState.isDehydrated&&(a.flags&256)===0||(a.flags|=1024,ld())),Xt(a),null;case 26:return l=a.memoizedState,e===null?(qn(a),l!==null?(Xt(a),M0(a,l)):(Xt(a),a.flags&=-16777217)):l?l!==e.memoizedState?(qn(a),Xt(a),M0(a,l)):(Xt(a),a.flags&=-16777217):(e.memoizedProps!==s&&qn(a),Xt(a),a.flags&=-16777217),null;case 27:ea(a),l=ht.current;var f=a.type;if(e!==null&&a.stateNode!=null)e.memoizedProps!==s&&qn(a);else{if(!s){if(a.stateNode===null)throw Error(u(166));return Xt(a),null}e=st.current,gr(a)?ad(a):(e=Mg(f,s,l),a.stateNode=e,qn(a))}return Xt(a),null;case 5:if(ea(a),l=a.type,e!==null&&a.stateNode!=null)e.memoizedProps!==s&&qn(a);else{if(!s){if(a.stateNode===null)throw Error(u(166));return Xt(a),null}if(e=st.current,gr(a))ad(a);else{switch(f=Nu(ht.current),e){case 1:e=f.createElementNS("http://www.w3.org/2000/svg",l);break;case 2:e=f.createElementNS("http://www.w3.org/1998/Math/MathML",l);break;default:switch(l){case"svg":e=f.createElementNS("http://www.w3.org/2000/svg",l);break;case"math":e=f.createElementNS("http://www.w3.org/1998/Math/MathML",l);break;case"script":e=f.createElement("div"),e.innerHTML="<script><\/script>",e=e.removeChild(e.firstChild);break;case"select":e=typeof s.is=="string"?f.createElement("select",{is:s.is}):f.createElement("select"),s.multiple?e.multiple=!0:s.size&&(e.size=s.size);break;default:e=typeof s.is=="string"?f.createElement(l,{is:s.is}):f.createElement(l)}}e[It]=a,e[Kt]=s;t:for(f=a.child;f!==null;){if(f.tag===5||f.tag===6)e.appendChild(f.stateNode);else if(f.tag!==4&&f.tag!==27&&f.child!==null){f.child.return=f,f=f.child;continue}if(f===a)break t;for(;f.sibling===null;){if(f.return===null||f.return===a)break t;f=f.return}f.sibling.return=f.return,f=f.sibling}a.stateNode=e;t:switch(he(e,l,s),l){case"button":case"input":case"select":case"textarea":e=!!s.autoFocus;break t;case"img":e=!0;break t;default:e=!1}e&&qn(a)}}return Xt(a),a.flags&=-16777217,null;case 6:if(e&&a.stateNode!=null)e.memoizedProps!==s&&qn(a);else{if(typeof s!="string"&&a.stateNode===null)throw Error(u(166));if(e=ht.current,gr(a)){if(e=a.stateNode,l=a.memoizedProps,s=null,f=_e,f!==null)switch(f.tag){case 27:case 5:s=f.memoizedProps}e[It]=a,e=!!(e.nodeValue===l||s!==null&&s.suppressHydrationWarning===!0||xg(e.nodeValue,l)),e||qi(a)}else e=Nu(e).createTextNode(s),e[It]=a,a.stateNode=e}return Xt(a),null;case 13:if(s=a.memoizedState,e===null||e.memoizedState!==null&&e.memoizedState.dehydrated!==null){if(f=gr(a),s!==null&&s.dehydrated!==null){if(e===null){if(!f)throw Error(u(318));if(f=a.memoizedState,f=f!==null?f.dehydrated:null,!f)throw Error(u(317));f[It]=a}else pr(),(a.flags&128)===0&&(a.memoizedState=null),a.flags|=4;Xt(a),f=!1}else f=ld(),e!==null&&e.memoizedState!==null&&(e.memoizedState.hydrationErrors=f),f=!0;if(!f)return a.flags&256?(kn(a),a):(kn(a),null)}if(kn(a),(a.flags&128)!==0)return a.lanes=l,a;if(l=s!==null,e=e!==null&&e.memoizedState!==null,l){s=a.child,f=null,s.alternate!==null&&s.alternate.memoizedState!==null&&s.alternate.memoizedState.cachePool!==null&&(f=s.alternate.memoizedState.cachePool.pool);var d=null;s.memoizedState!==null&&s.memoizedState.cachePool!==null&&(d=s.memoizedState.cachePool.pool),d!==f&&(s.flags|=2048)}return l!==e&&l&&(a.child.flags|=8192),mu(a,a.updateQueue),Xt(a),null;case 4:return ve(),e===null&&Sc(a.stateNode.containerInfo),Xt(a),null;case 10:return Dn(a.type),Xt(a),null;case 19:if(nt(ee),f=a.memoizedState,f===null)return Xt(a),null;if(s=(a.flags&128)!==0,d=f.rendering,d===null)if(s)zr(f,!1);else{if($t!==0||e!==null&&(e.flags&128)!==0)for(e=a.child;e!==null;){if(d=hu(e),d!==null){for(a.flags|=128,zr(f,!1),e=d.updateQueue,a.updateQueue=e,mu(a,e),a.subtreeFlags=0,e=l,l=a.child;l!==null;)nd(l,e),l=l.sibling;return at(ee,ee.current&1|2),a.child}e=e.sibling}f.tail!==null&&Be()>_u&&(a.flags|=128,s=!0,zr(f,!1),a.lanes=4194304)}else{if(!s)if(e=hu(d),e!==null){if(a.flags|=128,s=!0,e=e.updateQueue,a.updateQueue=e,mu(a,e),zr(f,!0),f.tail===null&&f.tailMode==="hidden"&&!d.alternate&&!Nt)return Xt(a),null}else 2*Be()-f.renderingStartTime>_u&&l!==536870912&&(a.flags|=128,s=!0,zr(f,!1),a.lanes=4194304);f.isBackwards?(d.sibling=a.child,a.child=d):(e=f.last,e!==null?e.sibling=d:a.child=d,f.last=d)}return f.tail!==null?(a=f.tail,f.rendering=a,f.tail=a.sibling,f.renderingStartTime=Be(),a.sibling=null,e=ee.current,at(ee,s?e&1|2:e&1),a):(Xt(a),null);case 22:case 23:return kn(a),Eo(),s=a.memoizedState!==null,e!==null?e.memoizedState!==null!==s&&(a.flags|=8192):s&&(a.flags|=8192),s?(l&536870912)!==0&&(a.flags&128)===0&&(Xt(a),a.subtreeFlags&6&&(a.flags|=8192)):Xt(a),l=a.updateQueue,l!==null&&mu(a,l.retryQueue),l=null,e!==null&&e.memoizedState!==null&&e.memoizedState.cachePool!==null&&(l=e.memoizedState.cachePool.pool),s=null,a.memoizedState!==null&&a.memoizedState.cachePool!==null&&(s=a.memoizedState.cachePool.pool),s!==l&&(a.flags|=2048),e!==null&&nt(Bi),null;case 24:return l=null,e!==null&&(l=e.memoizedState.cache),a.memoizedState.cache!==l&&(a.flags|=2048),Dn(te),Xt(a),null;case 25:return null;case 30:return null}throw Error(u(156,a.tag))}function p1(e,a){switch(co(a),a.tag){case 1:return e=a.flags,e&65536?(a.flags=e&-65537|128,a):null;case 3:return Dn(te),ve(),e=a.flags,(e&65536)!==0&&(e&128)===0?(a.flags=e&-65537|128,a):null;case 26:case 27:case 5:return ea(a),null;case 13:if(kn(a),e=a.memoizedState,e!==null&&e.dehydrated!==null){if(a.alternate===null)throw Error(u(340));pr()}return e=a.flags,e&65536?(a.flags=e&-65537|128,a):null;case 19:return nt(ee),null;case 4:return ve(),null;case 10:return Dn(a.type),null;case 22:case 23:return kn(a),Eo(),e!==null&&nt(Bi),e=a.flags,e&65536?(a.flags=e&-65537|128,a):null;case 24:return Dn(te),null;case 25:return null;default:return null}}function C0(e,a){switch(co(a),a.tag){case 3:Dn(te),ve();break;case 26:case 27:case 5:ea(a);break;case 4:ve();break;case 13:kn(a);break;case 19:nt(ee);break;case 10:Dn(a.type);break;case 22:case 23:kn(a),Eo(),e!==null&&nt(Bi);break;case 24:Dn(te)}}function Rr(e,a){try{var l=a.updateQueue,s=l!==null?l.lastEffect:null;if(s!==null){var f=s.next;l=f;do{if((l.tag&e)===e){s=void 0;var d=l.create,b=l.inst;s=d(),b.destroy=s}l=l.next}while(l!==f)}}catch(w){qt(a,a.return,w)}}function ri(e,a,l){try{var s=a.updateQueue,f=s!==null?s.lastEffect:null;if(f!==null){var d=f.next;s=d;do{if((s.tag&e)===e){var b=s.inst,w=b.destroy;if(w!==void 0){b.destroy=void 0,f=a;var z=l,Y=w;try{Y()}catch(P){qt(f,z,P)}}}s=s.next}while(s!==d)}}catch(P){qt(a,a.return,P)}}function N0(e){var a=e.updateQueue;if(a!==null){var l=e.stateNode;try{md(a,l)}catch(s){qt(e,e.return,s)}}}function z0(e,a,l){l.props=Qi(e.type,e.memoizedProps),l.state=e.memoizedState;try{l.componentWillUnmount()}catch(s){qt(e,a,s)}}function Dr(e,a){try{var l=e.ref;if(l!==null){switch(e.tag){case 26:case 27:case 5:var s=e.stateNode;break;case 30:s=e.stateNode;break;default:s=e.stateNode}typeof l=="function"?e.refCleanup=l(s):l.current=s}}catch(f){qt(e,a,f)}}function gn(e,a){var l=e.ref,s=e.refCleanup;if(l!==null)if(typeof s=="function")try{s()}catch(f){qt(e,a,f)}finally{e.refCleanup=null,e=e.alternate,e!=null&&(e.refCleanup=null)}else if(typeof l=="function")try{l(null)}catch(f){qt(e,a,f)}else l.current=null}function R0(e){var a=e.type,l=e.memoizedProps,s=e.stateNode;try{t:switch(a){case"button":case"input":case"select":case"textarea":l.autoFocus&&s.focus();break t;case"img":l.src?s.src=l.src:l.srcSet&&(s.srcset=l.srcSet)}}catch(f){qt(e,e.return,f)}}function Io(e,a,l){try{var s=e.stateNode;U1(s,e.type,l,a),s[Kt]=a}catch(f){qt(e,e.return,f)}}function D0(e){return e.tag===5||e.tag===3||e.tag===26||e.tag===27&&di(e.type)||e.tag===4}function tc(e){t:for(;;){for(;e.sibling===null;){if(e.return===null||D0(e.return))return null;e=e.return}for(e.sibling.return=e.return,e=e.sibling;e.tag!==5&&e.tag!==6&&e.tag!==18;){if(e.tag===27&&di(e.type)||e.flags&2||e.child===null||e.tag===4)continue t;e.child.return=e,e=e.child}if(!(e.flags&2))return e.stateNode}}function ec(e,a,l){var s=e.tag;if(s===5||s===6)e=e.stateNode,a?(l.nodeType===9?l.body:l.nodeName==="HTML"?l.ownerDocument.body:l).insertBefore(e,a):(a=l.nodeType===9?l.body:l.nodeName==="HTML"?l.ownerDocument.body:l,a.appendChild(e),l=l._reactRootContainer,l!=null||a.onclick!==null||(a.onclick=Cu));else if(s!==4&&(s===27&&di(e.type)&&(l=e.stateNode,a=null),e=e.child,e!==null))for(ec(e,a,l),e=e.sibling;e!==null;)ec(e,a,l),e=e.sibling}function vu(e,a,l){var s=e.tag;if(s===5||s===6)e=e.stateNode,a?l.insertBefore(e,a):l.appendChild(e);else if(s!==4&&(s===27&&di(e.type)&&(l=e.stateNode),e=e.child,e!==null))for(vu(e,a,l),e=e.sibling;e!==null;)vu(e,a,l),e=e.sibling}function j0(e){var a=e.stateNode,l=e.memoizedProps;try{for(var s=e.type,f=a.attributes;f.length;)a.removeAttributeNode(f[0]);he(a,s,l),a[It]=e,a[Kt]=l}catch(d){qt(e,e.return,d)}}var Hn=!1,Pt=!1,nc=!1,k0=typeof WeakSet=="function"?WeakSet:Set,le=null;function y1(e,a){if(e=e.containerInfo,Tc=Uu,e=$h(e),Is(e)){if("selectionStart"in e)var l={start:e.selectionStart,end:e.selectionEnd};else t:{l=(l=e.ownerDocument)&&l.defaultView||window;var s=l.getSelection&&l.getSelection();if(s&&s.rangeCount!==0){l=s.anchorNode;var f=s.anchorOffset,d=s.focusNode;s=s.focusOffset;try{l.nodeType,d.nodeType}catch{l=null;break t}var b=0,w=-1,z=-1,Y=0,P=0,I=e,X=null;e:for(;;){for(var V;I!==l||f!==0&&I.nodeType!==3||(w=b+f),I!==d||s!==0&&I.nodeType!==3||(z=b+s),I.nodeType===3&&(b+=I.nodeValue.length),(V=I.firstChild)!==null;)X=I,I=V;for(;;){if(I===e)break e;if(X===l&&++Y===f&&(w=b),X===d&&++P===s&&(z=b),(V=I.nextSibling)!==null)break;I=X,X=I.parentNode}I=V}l=w===-1||z===-1?null:{start:w,end:z}}else l=null}l=l||{start:0,end:0}}else l=null;for(Oc={focusedElem:e,selectionRange:l},Uu=!1,le=a;le!==null;)if(a=le,e=a.child,(a.subtreeFlags&1024)!==0&&e!==null)e.return=a,le=e;else for(;le!==null;){switch(a=le,d=a.alternate,e=a.flags,a.tag){case 0:break;case 11:case 15:break;case 1:if((e&1024)!==0&&d!==null){e=void 0,l=a,f=d.memoizedProps,d=d.memoizedState,s=l.stateNode;try{var _t=Qi(l.type,f,l.elementType===l.type);e=s.getSnapshotBeforeUpdate(_t,d),s.__reactInternalSnapshotBeforeUpdate=e}catch(mt){qt(l,l.return,mt)}}break;case 3:if((e&1024)!==0){if(e=a.stateNode.containerInfo,l=e.nodeType,l===9)Nc(e);else if(l===1)switch(e.nodeName){case"HEAD":case"HTML":case"BODY":Nc(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(u(163))}if(e=a.sibling,e!==null){e.return=a.return,le=e;break}le=a.return}}function U0(e,a,l){var s=l.flags;switch(l.tag){case 0:case 11:case 15:li(e,l),s&4&&Rr(5,l);break;case 1:if(li(e,l),s&4)if(e=l.stateNode,a===null)try{e.componentDidMount()}catch(b){qt(l,l.return,b)}else{var f=Qi(l.type,a.memoizedProps);a=a.memoizedState;try{e.componentDidUpdate(f,a,e.__reactInternalSnapshotBeforeUpdate)}catch(b){qt(l,l.return,b)}}s&64&&N0(l),s&512&&Dr(l,l.return);break;case 3:if(li(e,l),s&64&&(e=l.updateQueue,e!==null)){if(a=null,l.child!==null)switch(l.child.tag){case 27:case 5:a=l.child.stateNode;break;case 1:a=l.child.stateNode}try{md(e,a)}catch(b){qt(l,l.return,b)}}break;case 27:a===null&&s&4&&j0(l);case 26:case 5:li(e,l),a===null&&s&4&&R0(l),s&512&&Dr(l,l.return);break;case 12:li(e,l);break;case 13:li(e,l),s&4&&L0(e,l),s&64&&(e=l.memoizedState,e!==null&&(e=e.dehydrated,e!==null&&(l=E1.bind(null,l),Y1(e,l))));break;case 22:if(s=l.memoizedState!==null||Hn,!s){a=a!==null&&a.memoizedState!==null||Pt,f=Hn;var d=Pt;Hn=s,(Pt=a)&&!d?ui(e,l,(l.subtreeFlags&8772)!==0):li(e,l),Hn=f,Pt=d}break;case 30:break;default:li(e,l)}}function q0(e){var a=e.alternate;a!==null&&(e.alternate=null,q0(a)),e.child=null,e.deletions=null,e.sibling=null,e.tag===5&&(a=e.stateNode,a!==null&&js(a)),e.stateNode=null,e.return=null,e.dependencies=null,e.memoizedProps=null,e.memoizedState=null,e.pendingProps=null,e.stateNode=null,e.updateQueue=null}var Gt=null,Oe=!1;function Ln(e,a,l){for(l=l.child;l!==null;)H0(e,a,l),l=l.sibling}function H0(e,a,l){if(se&&typeof se.onCommitFiberUnmount=="function")try{se.onCommitFiberUnmount(En,l)}catch{}switch(l.tag){case 26:Pt||gn(l,a),Ln(e,a,l),l.memoizedState?l.memoizedState.count--:l.stateNode&&(l=l.stateNode,l.parentNode.removeChild(l));break;case 27:Pt||gn(l,a);var s=Gt,f=Oe;di(l.type)&&(Gt=l.stateNode,Oe=!1),Ln(e,a,l),Qr(l.stateNode),Gt=s,Oe=f;break;case 5:Pt||gn(l,a);case 6:if(s=Gt,f=Oe,Gt=null,Ln(e,a,l),Gt=s,Oe=f,Gt!==null)if(Oe)try{(Gt.nodeType===9?Gt.body:Gt.nodeName==="HTML"?Gt.ownerDocument.body:Gt).removeChild(l.stateNode)}catch(d){qt(l,a,d)}else try{Gt.removeChild(l.stateNode)}catch(d){qt(l,a,d)}break;case 18:Gt!==null&&(Oe?(e=Gt,Tg(e.nodeType===9?e.body:e.nodeName==="HTML"?e.ownerDocument.body:e,l.stateNode),Pr(e)):Tg(Gt,l.stateNode));break;case 4:s=Gt,f=Oe,Gt=l.stateNode.containerInfo,Oe=!0,Ln(e,a,l),Gt=s,Oe=f;break;case 0:case 11:case 14:case 15:Pt||ri(2,l,a),Pt||ri(4,l,a),Ln(e,a,l);break;case 1:Pt||(gn(l,a),s=l.stateNode,typeof s.componentWillUnmount=="function"&&z0(l,a,s)),Ln(e,a,l);break;case 21:Ln(e,a,l);break;case 22:Pt=(s=Pt)||l.memoizedState!==null,Ln(e,a,l),Pt=s;break;default:Ln(e,a,l)}}function L0(e,a){if(a.memoizedState===null&&(e=a.alternate,e!==null&&(e=e.memoizedState,e!==null&&(e=e.dehydrated,e!==null))))try{Pr(e)}catch(l){qt(a,a.return,l)}}function m1(e){switch(e.tag){case 13:case 19:var a=e.stateNode;return a===null&&(a=e.stateNode=new k0),a;case 22:return e=e.stateNode,a=e._retryCache,a===null&&(a=e._retryCache=new k0),a;default:throw Error(u(435,e.tag))}}function ic(e,a){var l=m1(e);a.forEach(function(s){var f=T1.bind(null,e,s);l.has(s)||(l.add(s),s.then(f,f))})}function De(e,a){var l=a.deletions;if(l!==null)for(var s=0;s<l.length;s++){var f=l[s],d=e,b=a,w=b;t:for(;w!==null;){switch(w.tag){case 27:if(di(w.type)){Gt=w.stateNode,Oe=!1;break t}break;case 5:Gt=w.stateNode,Oe=!1;break t;case 3:case 4:Gt=w.stateNode.containerInfo,Oe=!0;break t}w=w.return}if(Gt===null)throw Error(u(160));H0(d,b,f),Gt=null,Oe=!1,d=f.alternate,d!==null&&(d.return=null),f.return=null}if(a.subtreeFlags&13878)for(a=a.child;a!==null;)B0(a,e),a=a.sibling}var nn=null;function B0(e,a){var l=e.alternate,s=e.flags;switch(e.tag){case 0:case 11:case 14:case 15:De(a,e),je(e),s&4&&(ri(3,e,e.return),Rr(3,e),ri(5,e,e.return));break;case 1:De(a,e),je(e),s&512&&(Pt||l===null||gn(l,l.return)),s&64&&Hn&&(e=e.updateQueue,e!==null&&(s=e.callbacks,s!==null&&(l=e.shared.hiddenCallbacks,e.shared.hiddenCallbacks=l===null?s:l.concat(s))));break;case 26:var f=nn;if(De(a,e),je(e),s&512&&(Pt||l===null||gn(l,l.return)),s&4){var d=l!==null?l.memoizedState:null;if(s=e.memoizedState,l===null)if(s===null)if(e.stateNode===null){t:{s=e.type,l=e.memoizedProps,f=f.ownerDocument||f;e:switch(s){case"title":d=f.getElementsByTagName("title")[0],(!d||d[ir]||d[It]||d.namespaceURI==="http://www.w3.org/2000/svg"||d.hasAttribute("itemprop"))&&(d=f.createElement(s),f.head.insertBefore(d,f.querySelector("head > title"))),he(d,s,l),d[It]=e,ae(d),s=d;break t;case"link":var b=jg("link","href",f).get(s+(l.href||""));if(b){for(var w=0;w<b.length;w++)if(d=b[w],d.getAttribute("href")===(l.href==null||l.href===""?null:l.href)&&d.getAttribute("rel")===(l.rel==null?null:l.rel)&&d.getAttribute("title")===(l.title==null?null:l.title)&&d.getAttribute("crossorigin")===(l.crossOrigin==null?null:l.crossOrigin)){b.splice(w,1);break e}}d=f.createElement(s),he(d,s,l),f.head.appendChild(d);break;case"meta":if(b=jg("meta","content",f).get(s+(l.content||""))){for(w=0;w<b.length;w++)if(d=b[w],d.getAttribute("content")===(l.content==null?null:""+l.content)&&d.getAttribute("name")===(l.name==null?null:l.name)&&d.getAttribute("property")===(l.property==null?null:l.property)&&d.getAttribute("http-equiv")===(l.httpEquiv==null?null:l.httpEquiv)&&d.getAttribute("charset")===(l.charSet==null?null:l.charSet)){b.splice(w,1);break e}}d=f.createElement(s),he(d,s,l),f.head.appendChild(d);break;default:throw Error(u(468,s))}d[It]=e,ae(d),s=d}e.stateNode=s}else kg(f,e.type,e.stateNode);else e.stateNode=Dg(f,s,e.memoizedProps);else d!==s?(d===null?l.stateNode!==null&&(l=l.stateNode,l.parentNode.removeChild(l)):d.count--,s===null?kg(f,e.type,e.stateNode):Dg(f,s,e.memoizedProps)):s===null&&e.stateNode!==null&&Io(e,e.memoizedProps,l.memoizedProps)}break;case 27:De(a,e),je(e),s&512&&(Pt||l===null||gn(l,l.return)),l!==null&&s&4&&Io(e,e.memoizedProps,l.memoizedProps);break;case 5:if(De(a,e),je(e),s&512&&(Pt||l===null||gn(l,l.return)),e.flags&32){f=e.stateNode;try{fa(f,"")}catch(V){qt(e,e.return,V)}}s&4&&e.stateNode!=null&&(f=e.memoizedProps,Io(e,f,l!==null?l.memoizedProps:f)),s&1024&&(nc=!0);break;case 6:if(De(a,e),je(e),s&4){if(e.stateNode===null)throw Error(u(162));s=e.memoizedProps,l=e.stateNode;try{l.nodeValue=s}catch(V){qt(e,e.return,V)}}break;case 3:if(Du=null,f=nn,nn=zu(a.containerInfo),De(a,e),nn=f,je(e),s&4&&l!==null&&l.memoizedState.isDehydrated)try{Pr(a.containerInfo)}catch(V){qt(e,e.return,V)}nc&&(nc=!1,G0(e));break;case 4:s=nn,nn=zu(e.stateNode.containerInfo),De(a,e),je(e),nn=s;break;case 12:De(a,e),je(e);break;case 13:De(a,e),je(e),e.child.flags&8192&&e.memoizedState!==null!=(l!==null&&l.memoizedState!==null)&&(oc=Be()),s&4&&(s=e.updateQueue,s!==null&&(e.updateQueue=null,ic(e,s)));break;case 22:f=e.memoizedState!==null;var z=l!==null&&l.memoizedState!==null,Y=Hn,P=Pt;if(Hn=Y||f,Pt=P||z,De(a,e),Pt=P,Hn=Y,je(e),s&8192)t:for(a=e.stateNode,a._visibility=f?a._visibility&-2:a._visibility|1,f&&(l===null||z||Hn||Pt||Yi(e)),l=null,a=e;;){if(a.tag===5||a.tag===26){if(l===null){z=l=a;try{if(d=z.stateNode,f)b=d.style,typeof b.setProperty=="function"?b.setProperty("display","none","important"):b.display="none";else{w=z.stateNode;var I=z.memoizedProps.style,X=I!=null&&I.hasOwnProperty("display")?I.display:null;w.style.display=X==null||typeof X=="boolean"?"":(""+X).trim()}}catch(V){qt(z,z.return,V)}}}else if(a.tag===6){if(l===null){z=a;try{z.stateNode.nodeValue=f?"":z.memoizedProps}catch(V){qt(z,z.return,V)}}}else if((a.tag!==22&&a.tag!==23||a.memoizedState===null||a===e)&&a.child!==null){a.child.return=a,a=a.child;continue}if(a===e)break t;for(;a.sibling===null;){if(a.return===null||a.return===e)break t;l===a&&(l=null),a=a.return}l===a&&(l=null),a.sibling.return=a.return,a=a.sibling}s&4&&(s=e.updateQueue,s!==null&&(l=s.retryQueue,l!==null&&(s.retryQueue=null,ic(e,l))));break;case 19:De(a,e),je(e),s&4&&(s=e.updateQueue,s!==null&&(e.updateQueue=null,ic(e,s)));break;case 30:break;case 21:break;default:De(a,e),je(e)}}function je(e){var a=e.flags;if(a&2){try{for(var l,s=e.return;s!==null;){if(D0(s)){l=s;break}s=s.return}if(l==null)throw Error(u(160));switch(l.tag){case 27:var f=l.stateNode,d=tc(e);vu(e,d,f);break;case 5:var b=l.stateNode;l.flags&32&&(fa(b,""),l.flags&=-33);var w=tc(e);vu(e,w,b);break;case 3:case 4:var z=l.stateNode.containerInfo,Y=tc(e);ec(e,Y,z);break;default:throw Error(u(161))}}catch(P){qt(e,e.return,P)}e.flags&=-3}a&4096&&(e.flags&=-4097)}function G0(e){if(e.subtreeFlags&1024)for(e=e.child;e!==null;){var a=e;G0(a),a.tag===5&&a.flags&1024&&a.stateNode.reset(),e=e.sibling}}function li(e,a){if(a.subtreeFlags&8772)for(a=a.child;a!==null;)U0(e,a.alternate,a),a=a.sibling}function Yi(e){for(e=e.child;e!==null;){var a=e;switch(a.tag){case 0:case 11:case 14:case 15:ri(4,a,a.return),Yi(a);break;case 1:gn(a,a.return);var l=a.stateNode;typeof l.componentWillUnmount=="function"&&z0(a,a.return,l),Yi(a);break;case 27:Qr(a.stateNode);case 26:case 5:gn(a,a.return),Yi(a);break;case 22:a.memoizedState===null&&Yi(a);break;case 30:Yi(a);break;default:Yi(a)}e=e.sibling}}function ui(e,a,l){for(l=l&&(a.subtreeFlags&8772)!==0,a=a.child;a!==null;){var s=a.alternate,f=e,d=a,b=d.flags;switch(d.tag){case 0:case 11:case 15:ui(f,d,l),Rr(4,d);break;case 1:if(ui(f,d,l),s=d,f=s.stateNode,typeof f.componentDidMount=="function")try{f.componentDidMount()}catch(Y){qt(s,s.return,Y)}if(s=d,f=s.updateQueue,f!==null){var w=s.stateNode;try{var z=f.shared.hiddenCallbacks;if(z!==null)for(f.shared.hiddenCallbacks=null,f=0;f<z.length;f++)yd(z[f],w)}catch(Y){qt(s,s.return,Y)}}l&&b&64&&N0(d),Dr(d,d.return);break;case 27:j0(d);case 26:case 5:ui(f,d,l),l&&s===null&&b&4&&R0(d),Dr(d,d.return);break;case 12:ui(f,d,l);break;case 13:ui(f,d,l),l&&b&4&&L0(f,d);break;case 22:d.memoizedState===null&&ui(f,d,l),Dr(d,d.return);break;case 30:break;default:ui(f,d,l)}a=a.sibling}}function ac(e,a){var l=null;e!==null&&e.memoizedState!==null&&e.memoizedState.cachePool!==null&&(l=e.memoizedState.cachePool.pool),e=null,a.memoizedState!==null&&a.memoizedState.cachePool!==null&&(e=a.memoizedState.cachePool.pool),e!==l&&(e!=null&&e.refCount++,l!=null&&vr(l))}function rc(e,a){e=null,a.alternate!==null&&(e=a.alternate.memoizedState.cache),a=a.memoizedState.cache,a!==e&&(a.refCount++,e!=null&&vr(e))}function pn(e,a,l,s){if(a.subtreeFlags&10256)for(a=a.child;a!==null;)Q0(e,a,l,s),a=a.sibling}function Q0(e,a,l,s){var f=a.flags;switch(a.tag){case 0:case 11:case 15:pn(e,a,l,s),f&2048&&Rr(9,a);break;case 1:pn(e,a,l,s);break;case 3:pn(e,a,l,s),f&2048&&(e=null,a.alternate!==null&&(e=a.alternate.memoizedState.cache),a=a.memoizedState.cache,a!==e&&(a.refCount++,e!=null&&vr(e)));break;case 12:if(f&2048){pn(e,a,l,s),e=a.stateNode;try{var d=a.memoizedProps,b=d.id,w=d.onPostCommit;typeof w=="function"&&w(b,a.alternate===null?"mount":"update",e.passiveEffectDuration,-0)}catch(z){qt(a,a.return,z)}}else pn(e,a,l,s);break;case 13:pn(e,a,l,s);break;case 23:break;case 22:d=a.stateNode,b=a.alternate,a.memoizedState!==null?d._visibility&2?pn(e,a,l,s):jr(e,a):d._visibility&2?pn(e,a,l,s):(d._visibility|=2,Na(e,a,l,s,(a.subtreeFlags&10256)!==0)),f&2048&&ac(b,a);break;case 24:pn(e,a,l,s),f&2048&&rc(a.alternate,a);break;default:pn(e,a,l,s)}}function Na(e,a,l,s,f){for(f=f&&(a.subtreeFlags&10256)!==0,a=a.child;a!==null;){var d=e,b=a,w=l,z=s,Y=b.flags;switch(b.tag){case 0:case 11:case 15:Na(d,b,w,z,f),Rr(8,b);break;case 23:break;case 22:var P=b.stateNode;b.memoizedState!==null?P._visibility&2?Na(d,b,w,z,f):jr(d,b):(P._visibility|=2,Na(d,b,w,z,f)),f&&Y&2048&&ac(b.alternate,b);break;case 24:Na(d,b,w,z,f),f&&Y&2048&&rc(b.alternate,b);break;default:Na(d,b,w,z,f)}a=a.sibling}}function jr(e,a){if(a.subtreeFlags&10256)for(a=a.child;a!==null;){var l=e,s=a,f=s.flags;switch(s.tag){case 22:jr(l,s),f&2048&&ac(s.alternate,s);break;case 24:jr(l,s),f&2048&&rc(s.alternate,s);break;default:jr(l,s)}a=a.sibling}}var kr=8192;function za(e){if(e.subtreeFlags&kr)for(e=e.child;e!==null;)Y0(e),e=e.sibling}function Y0(e){switch(e.tag){case 26:za(e),e.flags&kr&&e.memoizedState!==null&&nb(nn,e.memoizedState,e.memoizedProps);break;case 5:za(e);break;case 3:case 4:var a=nn;nn=zu(e.stateNode.containerInfo),za(e),nn=a;break;case 22:e.memoizedState===null&&(a=e.alternate,a!==null&&a.memoizedState!==null?(a=kr,kr=16777216,za(e),kr=a):za(e));break;default:za(e)}}function X0(e){var a=e.alternate;if(a!==null&&(e=a.child,e!==null)){a.child=null;do a=e.sibling,e.sibling=null,e=a;while(e!==null)}}function Ur(e){var a=e.deletions;if((e.flags&16)!==0){if(a!==null)for(var l=0;l<a.length;l++){var s=a[l];le=s,$0(s,e)}X0(e)}if(e.subtreeFlags&10256)for(e=e.child;e!==null;)V0(e),e=e.sibling}function V0(e){switch(e.tag){case 0:case 11:case 15:Ur(e),e.flags&2048&&ri(9,e,e.return);break;case 3:Ur(e);break;case 12:Ur(e);break;case 22:var a=e.stateNode;e.memoizedState!==null&&a._visibility&2&&(e.return===null||e.return.tag!==13)?(a._visibility&=-3,bu(e)):Ur(e);break;default:Ur(e)}}function bu(e){var a=e.deletions;if((e.flags&16)!==0){if(a!==null)for(var l=0;l<a.length;l++){var s=a[l];le=s,$0(s,e)}X0(e)}for(e=e.child;e!==null;){switch(a=e,a.tag){case 0:case 11:case 15:ri(8,a,a.return),bu(a);break;case 22:l=a.stateNode,l._visibility&2&&(l._visibility&=-3,bu(a));break;default:bu(a)}e=e.sibling}}function $0(e,a){for(;le!==null;){var l=le;switch(l.tag){case 0:case 11:case 15:ri(8,l,a);break;case 23:case 22:if(l.memoizedState!==null&&l.memoizedState.cachePool!==null){var s=l.memoizedState.cachePool.pool;s!=null&&s.refCount++}break;case 24:vr(l.memoizedState.cache)}if(s=l.child,s!==null)s.return=l,le=s;else t:for(l=e;le!==null;){s=le;var f=s.sibling,d=s.return;if(q0(s),s===l){le=null;break t}if(f!==null){f.return=d,le=f;break t}le=d}}}var v1={getCacheForType:function(e){var a=pe(te),l=a.data.get(e);return l===void 0&&(l=e(),a.data.set(e,l)),l}},b1=typeof WeakMap=="function"?WeakMap:Map,zt=0,Lt=null,Et=null,Ot=0,Rt=0,ke=null,si=!1,Ra=!1,lc=!1,Bn=0,$t=0,oi=0,Xi=0,uc=0,Ke=0,Da=0,qr=null,Me=null,sc=!1,oc=0,_u=1/0,xu=null,ci=null,fe=0,fi=null,ja=null,ka=0,cc=0,fc=null,Z0=null,Hr=0,hc=null;function Ue(){if((zt&2)!==0&&Ot!==0)return Ot&-Ot;if(N.T!==null){var e=wa;return e!==0?e:bc()}return ie()}function K0(){Ke===0&&(Ke=(Ot&536870912)===0||Nt?zl():536870912);var e=Ze.current;return e!==null&&(e.flags|=32),Ke}function qe(e,a,l){(e===Lt&&(Rt===2||Rt===9)||e.cancelPendingCommit!==null)&&(Ua(e,0),hi(e,Ot,Ke,!1)),Mi(e,l),((zt&2)===0||e!==Lt)&&(e===Lt&&((zt&2)===0&&(Xi|=l),$t===4&&hi(e,Ot,Ke,!1)),yn(e))}function F0(e,a,l){if((zt&6)!==0)throw Error(u(327));var s=!l&&(a&124)===0&&(a&e.expiredLanes)===0||Oi(e,a),f=s?w1(e,a):pc(e,a,!0),d=s;do{if(f===0){Ra&&!s&&hi(e,a,0,!1);break}else{if(l=e.current.alternate,d&&!_1(l)){f=pc(e,a,!1),d=!1;continue}if(f===2){if(d=a,e.errorRecoveryDisabledLanes&d)var b=0;else b=e.pendingLanes&-536870913,b=b!==0?b:b&536870912?536870912:0;if(b!==0){a=b;t:{var w=e;f=qr;var z=w.current.memoizedState.isDehydrated;if(z&&(Ua(w,b).flags|=256),b=pc(w,b,!1),b!==2){if(lc&&!z){w.errorRecoveryDisabledLanes|=d,Xi|=d,f=4;break t}d=Me,Me=f,d!==null&&(Me===null?Me=d:Me.push.apply(Me,d))}f=b}if(d=!1,f!==2)continue}}if(f===1){Ua(e,0),hi(e,a,0,!0);break}t:{switch(s=e,d=f,d){case 0:case 1:throw Error(u(345));case 4:if((a&4194048)!==a)break;case 6:hi(s,a,Ke,!si);break t;case 2:Me=null;break;case 3:case 5:break;default:throw Error(u(329))}if((a&62914560)===a&&(f=oc+300-Be(),10<f)){if(hi(s,a,Ke,!si),Ti(s,0,!0)!==0)break t;s.timeoutHandle=Ag(P0.bind(null,s,l,Me,xu,sc,a,Ke,Xi,Da,si,d,2,-0,0),f);break t}P0(s,l,Me,xu,sc,a,Ke,Xi,Da,si,d,0,-0,0)}}break}while(!0);yn(e)}function P0(e,a,l,s,f,d,b,w,z,Y,P,I,X,V){if(e.timeoutHandle=-1,I=a.subtreeFlags,(I&8192||(I&16785408)===16785408)&&(Vr={stylesheets:null,count:0,unsuspend:eb},Y0(a),I=ib(),I!==null)){e.cancelPendingCommit=I(ig.bind(null,e,a,d,l,s,f,b,w,z,P,1,X,V)),hi(e,d,b,!Y);return}ig(e,a,d,l,s,f,b,w,z)}function _1(e){for(var a=e;;){var l=a.tag;if((l===0||l===11||l===15)&&a.flags&16384&&(l=a.updateQueue,l!==null&&(l=l.stores,l!==null)))for(var s=0;s<l.length;s++){var f=l[s],d=f.getSnapshot;f=f.value;try{if(!ze(d(),f))return!1}catch{return!1}}if(l=a.child,a.subtreeFlags&16384&&l!==null)l.return=a,a=l;else{if(a===e)break;for(;a.sibling===null;){if(a.return===null||a.return===e)return!0;a=a.return}a.sibling.return=a.return,a=a.sibling}}return!0}function hi(e,a,l,s){a&=~uc,a&=~Xi,e.suspendedLanes|=a,e.pingedLanes&=~a,s&&(e.warmLanes|=a),s=e.expirationTimes;for(var f=a;0<f;){var d=31-be(f),b=1<<d;s[d]=-1,f&=~b}l!==0&&aa(e,l,a)}function wu(){return(zt&6)===0?(Lr(0),!1):!0}function dc(){if(Et!==null){if(Rt===0)var e=Et.return;else e=Et,Rn=Hi=null,No(e),Ma=null,Cr=0,e=Et;for(;e!==null;)C0(e.alternate,e),e=e.return;Et=null}}function Ua(e,a){var l=e.timeoutHandle;l!==-1&&(e.timeoutHandle=-1,H1(l)),l=e.cancelPendingCommit,l!==null&&(e.cancelPendingCommit=null,l()),dc(),Lt=e,Et=l=Cn(e.current,null),Ot=a,Rt=0,ke=null,si=!1,Ra=Oi(e,a),lc=!1,Da=Ke=uc=Xi=oi=$t=0,Me=qr=null,sc=!1,(a&8)!==0&&(a|=a&32);var s=e.entangledLanes;if(s!==0)for(e=e.entanglements,s&=a;0<s;){var f=31-be(s),d=1<<f;a|=e[f],s&=~d}return Bn=a,Xl(),l}function J0(e,a){wt=null,N.H=ou,a===_r||a===Il?(a=gd(),Rt=3):a===fd?(a=gd(),Rt=4):Rt=a===p0?8:a!==null&&typeof a=="object"&&typeof a.then=="function"?6:1,ke=a,Et===null&&($t=1,gu(e,Ye(a,e.current)))}function W0(){var e=N.H;return N.H=ou,e===null?ou:e}function I0(){var e=N.A;return N.A=v1,e}function gc(){$t=4,si||(Ot&4194048)!==Ot&&Ze.current!==null||(Ra=!0),(oi&134217727)===0&&(Xi&134217727)===0||Lt===null||hi(Lt,Ot,Ke,!1)}function pc(e,a,l){var s=zt;zt|=2;var f=W0(),d=I0();(Lt!==e||Ot!==a)&&(xu=null,Ua(e,a)),a=!1;var b=$t;t:do try{if(Rt!==0&&Et!==null){var w=Et,z=ke;switch(Rt){case 8:dc(),b=6;break t;case 3:case 2:case 9:case 6:Ze.current===null&&(a=!0);var Y=Rt;if(Rt=0,ke=null,qa(e,w,z,Y),l&&Ra){b=0;break t}break;default:Y=Rt,Rt=0,ke=null,qa(e,w,z,Y)}}x1(),b=$t;break}catch(P){J0(e,P)}while(!0);return a&&e.shellSuspendCounter++,Rn=Hi=null,zt=s,N.H=f,N.A=d,Et===null&&(Lt=null,Ot=0,Xl()),b}function x1(){for(;Et!==null;)tg(Et)}function w1(e,a){var l=zt;zt|=2;var s=W0(),f=I0();Lt!==e||Ot!==a?(xu=null,_u=Be()+500,Ua(e,a)):Ra=Oi(e,a);t:do try{if(Rt!==0&&Et!==null){a=Et;var d=ke;e:switch(Rt){case 1:Rt=0,ke=null,qa(e,a,d,1);break;case 2:case 9:if(hd(d)){Rt=0,ke=null,eg(a);break}a=function(){Rt!==2&&Rt!==9||Lt!==e||(Rt=7),yn(e)},d.then(a,a);break t;case 3:Rt=7;break t;case 4:Rt=5;break t;case 7:hd(d)?(Rt=0,ke=null,eg(a)):(Rt=0,ke=null,qa(e,a,d,7));break;case 5:var b=null;switch(Et.tag){case 26:b=Et.memoizedState;case 5:case 27:var w=Et;if(!b||Ug(b)){Rt=0,ke=null;var z=w.sibling;if(z!==null)Et=z;else{var Y=w.return;Y!==null?(Et=Y,Su(Y)):Et=null}break e}}Rt=0,ke=null,qa(e,a,d,5);break;case 6:Rt=0,ke=null,qa(e,a,d,6);break;case 8:dc(),$t=6;break t;default:throw Error(u(462))}}S1();break}catch(P){J0(e,P)}while(!0);return Rn=Hi=null,N.H=s,N.A=f,zt=l,Et!==null?0:(Lt=null,Ot=0,Xl(),$t)}function S1(){for(;Et!==null&&!Es();)tg(Et)}function tg(e){var a=O0(e.alternate,e,Bn);e.memoizedProps=e.pendingProps,a===null?Su(e):Et=a}function eg(e){var a=e,l=a.alternate;switch(a.tag){case 15:case 0:a=x0(l,a,a.pendingProps,a.type,void 0,Ot);break;case 11:a=x0(l,a,a.pendingProps,a.type.render,a.ref,Ot);break;case 5:No(a);default:C0(l,a),a=Et=nd(a,Bn),a=O0(l,a,Bn)}e.memoizedProps=e.pendingProps,a===null?Su(e):Et=a}function qa(e,a,l,s){Rn=Hi=null,No(a),Ma=null,Cr=0;var f=a.return;try{if(h1(e,f,a,l,Ot)){$t=1,gu(e,Ye(l,e.current)),Et=null;return}}catch(d){if(f!==null)throw Et=f,d;$t=1,gu(e,Ye(l,e.current)),Et=null;return}a.flags&32768?(Nt||s===1?e=!0:Ra||(Ot&536870912)!==0?e=!1:(si=e=!0,(s===2||s===9||s===3||s===6)&&(s=Ze.current,s!==null&&s.tag===13&&(s.flags|=16384))),ng(a,e)):Su(a)}function Su(e){var a=e;do{if((a.flags&32768)!==0){ng(a,si);return}e=a.return;var l=g1(a.alternate,a,Bn);if(l!==null){Et=l;return}if(a=a.sibling,a!==null){Et=a;return}Et=a=e}while(a!==null);$t===0&&($t=5)}function ng(e,a){do{var l=p1(e.alternate,e);if(l!==null){l.flags&=32767,Et=l;return}if(l=e.return,l!==null&&(l.flags|=32768,l.subtreeFlags=0,l.deletions=null),!a&&(e=e.sibling,e!==null)){Et=e;return}Et=e=l}while(e!==null);$t=6,Et=null}function ig(e,a,l,s,f,d,b,w,z){e.cancelPendingCommit=null;do Au();while(fe!==0);if((zt&6)!==0)throw Error(u(327));if(a!==null){if(a===e.current)throw Error(u(177));if(d=a.lanes|a.childLanes,d|=ao,Ds(e,l,d,b,w,z),e===Lt&&(Et=Lt=null,Ot=0),ja=a,fi=e,ka=l,cc=d,fc=f,Z0=s,(a.subtreeFlags&10256)!==0||(a.flags&10256)!==0?(e.callbackNode=null,e.callbackPriority=0,O1(Ai,function(){return sg(),null})):(e.callbackNode=null,e.callbackPriority=0),s=(a.flags&13878)!==0,(a.subtreeFlags&13878)!==0||s){s=N.T,N.T=null,f=Z.p,Z.p=2,b=zt,zt|=4;try{y1(e,a,l)}finally{zt=b,Z.p=f,N.T=s}}fe=1,ag(),rg(),lg()}}function ag(){if(fe===1){fe=0;var e=fi,a=ja,l=(a.flags&13878)!==0;if((a.subtreeFlags&13878)!==0||l){l=N.T,N.T=null;var s=Z.p;Z.p=2;var f=zt;zt|=4;try{B0(a,e);var d=Oc,b=$h(e.containerInfo),w=d.focusedElem,z=d.selectionRange;if(b!==w&&w&&w.ownerDocument&&Vh(w.ownerDocument.documentElement,w)){if(z!==null&&Is(w)){var Y=z.start,P=z.end;if(P===void 0&&(P=Y),"selectionStart"in w)w.selectionStart=Y,w.selectionEnd=Math.min(P,w.value.length);else{var I=w.ownerDocument||document,X=I&&I.defaultView||window;if(X.getSelection){var V=X.getSelection(),_t=w.textContent.length,mt=Math.min(z.start,_t),Ut=z.end===void 0?mt:Math.min(z.end,_t);!V.extend&&mt>Ut&&(b=Ut,Ut=mt,mt=b);var B=Xh(w,mt),D=Xh(w,Ut);if(B&&D&&(V.rangeCount!==1||V.anchorNode!==B.node||V.anchorOffset!==B.offset||V.focusNode!==D.node||V.focusOffset!==D.offset)){var G=I.createRange();G.setStart(B.node,B.offset),V.removeAllRanges(),mt>Ut?(V.addRange(G),V.extend(D.node,D.offset)):(G.setEnd(D.node,D.offset),V.addRange(G))}}}}for(I=[],V=w;V=V.parentNode;)V.nodeType===1&&I.push({element:V,left:V.scrollLeft,top:V.scrollTop});for(typeof w.focus=="function"&&w.focus(),w=0;w<I.length;w++){var W=I[w];W.element.scrollLeft=W.left,W.element.scrollTop=W.top}}Uu=!!Tc,Oc=Tc=null}finally{zt=f,Z.p=s,N.T=l}}e.current=a,fe=2}}function rg(){if(fe===2){fe=0;var e=fi,a=ja,l=(a.flags&8772)!==0;if((a.subtreeFlags&8772)!==0||l){l=N.T,N.T=null;var s=Z.p;Z.p=2;var f=zt;zt|=4;try{U0(e,a.alternate,a)}finally{zt=f,Z.p=s,N.T=l}}fe=3}}function lg(){if(fe===4||fe===3){fe=0,Ts();var e=fi,a=ja,l=ka,s=Z0;(a.subtreeFlags&10256)!==0||(a.flags&10256)!==0?fe=5:(fe=0,ja=fi=null,ug(e,e.pendingLanes));var f=e.pendingLanes;if(f===0&&(ci=null),bt(l),a=a.stateNode,se&&typeof se.onCommitFiberRoot=="function")try{se.onCommitFiberRoot(En,a,void 0,(a.current.flags&128)===128)}catch{}if(s!==null){a=N.T,f=Z.p,Z.p=2,N.T=null;try{for(var d=e.onRecoverableError,b=0;b<s.length;b++){var w=s[b];d(w.value,{componentStack:w.stack})}}finally{N.T=a,Z.p=f}}(ka&3)!==0&&Au(),yn(e),f=e.pendingLanes,(l&4194090)!==0&&(f&42)!==0?e===hc?Hr++:(Hr=0,hc=e):Hr=0,Lr(0)}}function ug(e,a){(e.pooledCacheLanes&=a)===0&&(a=e.pooledCache,a!=null&&(e.pooledCache=null,vr(a)))}function Au(e){return ag(),rg(),lg(),sg()}function sg(){if(fe!==5)return!1;var e=fi,a=cc;cc=0;var l=bt(ka),s=N.T,f=Z.p;try{Z.p=32>l?32:l,N.T=null,l=fc,fc=null;var d=fi,b=ka;if(fe=0,ja=fi=null,ka=0,(zt&6)!==0)throw Error(u(331));var w=zt;if(zt|=4,V0(d.current),Q0(d,d.current,b,l),zt=w,Lr(0,!1),se&&typeof se.onPostCommitFiberRoot=="function")try{se.onPostCommitFiberRoot(En,d)}catch{}return!0}finally{Z.p=f,N.T=s,ug(e,a)}}function og(e,a,l){a=Ye(l,a),a=Xo(e.stateNode,a,2),e=ei(e,a,2),e!==null&&(Mi(e,2),yn(e))}function qt(e,a,l){if(e.tag===3)og(e,e,l);else for(;a!==null;){if(a.tag===3){og(a,e,l);break}else if(a.tag===1){var s=a.stateNode;if(typeof a.type.getDerivedStateFromError=="function"||typeof s.componentDidCatch=="function"&&(ci===null||!ci.has(s))){e=Ye(l,e),l=d0(2),s=ei(a,l,2),s!==null&&(g0(l,s,a,e),Mi(s,2),yn(s));break}}a=a.return}}function yc(e,a,l){var s=e.pingCache;if(s===null){s=e.pingCache=new b1;var f=new Set;s.set(a,f)}else f=s.get(a),f===void 0&&(f=new Set,s.set(a,f));f.has(l)||(lc=!0,f.add(l),e=A1.bind(null,e,a,l),a.then(e,e))}function A1(e,a,l){var s=e.pingCache;s!==null&&s.delete(a),e.pingedLanes|=e.suspendedLanes&l,e.warmLanes&=~l,Lt===e&&(Ot&l)===l&&($t===4||$t===3&&(Ot&62914560)===Ot&&300>Be()-oc?(zt&2)===0&&Ua(e,0):uc|=l,Da===Ot&&(Da=0)),yn(e)}function cg(e,a){a===0&&(a=Rl()),e=va(e,a),e!==null&&(Mi(e,a),yn(e))}function E1(e){var a=e.memoizedState,l=0;a!==null&&(l=a.retryLane),cg(e,l)}function T1(e,a){var l=0;switch(e.tag){case 13:var s=e.stateNode,f=e.memoizedState;f!==null&&(l=f.retryLane);break;case 19:s=e.stateNode;break;case 22:s=e.stateNode._retryCache;break;default:throw Error(u(314))}s!==null&&s.delete(a),cg(e,l)}function O1(e,a){return na(e,a)}var Eu=null,Ha=null,mc=!1,Tu=!1,vc=!1,Vi=0;function yn(e){e!==Ha&&e.next===null&&(Ha===null?Eu=Ha=e:Ha=Ha.next=e),Tu=!0,mc||(mc=!0,C1())}function Lr(e,a){if(!vc&&Tu){vc=!0;do for(var l=!1,s=Eu;s!==null;){if(e!==0){var f=s.pendingLanes;if(f===0)var d=0;else{var b=s.suspendedLanes,w=s.pingedLanes;d=(1<<31-be(42|e)+1)-1,d&=f&~(b&~w),d=d&201326741?d&201326741|1:d?d|2:0}d!==0&&(l=!0,gg(s,d))}else d=Ot,d=Ti(s,s===Lt?d:0,s.cancelPendingCommit!==null||s.timeoutHandle!==-1),(d&3)===0||Oi(s,d)||(l=!0,gg(s,d));s=s.next}while(l);vc=!1}}function M1(){fg()}function fg(){Tu=mc=!1;var e=0;Vi!==0&&(q1()&&(e=Vi),Vi=0);for(var a=Be(),l=null,s=Eu;s!==null;){var f=s.next,d=hg(s,a);d===0?(s.next=null,l===null?Eu=f:l.next=f,f===null&&(Ha=l)):(l=s,(e!==0||(d&3)!==0)&&(Tu=!0)),s=f}Lr(e)}function hg(e,a){for(var l=e.suspendedLanes,s=e.pingedLanes,f=e.expirationTimes,d=e.pendingLanes&-62914561;0<d;){var b=31-be(d),w=1<<b,z=f[b];z===-1?((w&l)===0||(w&s)!==0)&&(f[b]=Rs(w,a)):z<=a&&(e.expiredLanes|=w),d&=~w}if(a=Lt,l=Ot,l=Ti(e,e===a?l:0,e.cancelPendingCommit!==null||e.timeoutHandle!==-1),s=e.callbackNode,l===0||e===a&&(Rt===2||Rt===9)||e.cancelPendingCommit!==null)return s!==null&&s!==null&&tr(s),e.callbackNode=null,e.callbackPriority=0;if((l&3)===0||Oi(e,l)){if(a=l&-l,a===e.callbackPriority)return a;switch(s!==null&&tr(s),bt(l)){case 2:case 8:l=Si;break;case 32:l=Ai;break;case 268435456:l=An;break;default:l=Ai}return s=dg.bind(null,e),l=na(l,s),e.callbackPriority=a,e.callbackNode=l,a}return s!==null&&s!==null&&tr(s),e.callbackPriority=2,e.callbackNode=null,2}function dg(e,a){if(fe!==0&&fe!==5)return e.callbackNode=null,e.callbackPriority=0,null;var l=e.callbackNode;if(Au()&&e.callbackNode!==l)return null;var s=Ot;return s=Ti(e,e===Lt?s:0,e.cancelPendingCommit!==null||e.timeoutHandle!==-1),s===0?null:(F0(e,s,a),hg(e,Be()),e.callbackNode!=null&&e.callbackNode===l?dg.bind(null,e):null)}function gg(e,a){if(Au())return null;F0(e,a,!0)}function C1(){L1(function(){(zt&6)!==0?na(Sn,M1):fg()})}function bc(){return Vi===0&&(Vi=zl()),Vi}function pg(e){return e==null||typeof e=="symbol"||typeof e=="boolean"?null:typeof e=="function"?e:ql(""+e)}function yg(e,a){var l=a.ownerDocument.createElement("input");return l.name=a.name,l.value=a.value,e.id&&l.setAttribute("form",e.id),a.parentNode.insertBefore(l,a),e=new FormData(e),l.parentNode.removeChild(l),e}function N1(e,a,l,s,f){if(a==="submit"&&l&&l.stateNode===f){var d=pg((f[Kt]||null).action),b=s.submitter;b&&(a=(a=b[Kt]||null)?pg(a.formAction):b.getAttribute("formAction"),a!==null&&(d=a,b=null));var w=new Gl("action","action",null,s,f);e.push({event:w,listeners:[{instance:null,listener:function(){if(s.defaultPrevented){if(Vi!==0){var z=b?yg(f,b):new FormData(f);Lo(l,{pending:!0,data:z,method:f.method,action:d},null,z)}}else typeof d=="function"&&(w.preventDefault(),z=b?yg(f,b):new FormData(f),Lo(l,{pending:!0,data:z,method:f.method,action:d},d,z))},currentTarget:f}]})}}for(var _c=0;_c<io.length;_c++){var xc=io[_c],z1=xc.toLowerCase(),R1=xc[0].toUpperCase()+xc.slice(1);en(z1,"on"+R1)}en(Fh,"onAnimationEnd"),en(Ph,"onAnimationIteration"),en(Jh,"onAnimationStart"),en("dblclick","onDoubleClick"),en("focusin","onFocus"),en("focusout","onBlur"),en(Fv,"onTransitionRun"),en(Pv,"onTransitionStart"),en(Jv,"onTransitionCancel"),en(Wh,"onTransitionEnd"),sa("onMouseEnter",["mouseout","mouseover"]),sa("onMouseLeave",["mouseout","mouseover"]),sa("onPointerEnter",["pointerout","pointerover"]),sa("onPointerLeave",["pointerout","pointerover"]),Ci("onChange","change click focusin focusout input keydown keyup selectionchange".split(" ")),Ci("onSelect","focusout contextmenu dragend focusin keydown keyup mousedown mouseup selectionchange".split(" ")),Ci("onBeforeInput",["compositionend","keypress","textInput","paste"]),Ci("onCompositionEnd","compositionend focusout keydown keypress keyup mousedown".split(" ")),Ci("onCompositionStart","compositionstart focusout keydown keypress keyup mousedown".split(" ")),Ci("onCompositionUpdate","compositionupdate focusout keydown keypress keyup mousedown".split(" "));var Br="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(" "),D1=new Set("beforetoggle cancel close invalid load scroll scrollend toggle".split(" ").concat(Br));function mg(e,a){a=(a&4)!==0;for(var l=0;l<e.length;l++){var s=e[l],f=s.event;s=s.listeners;t:{var d=void 0;if(a)for(var b=s.length-1;0<=b;b--){var w=s[b],z=w.instance,Y=w.currentTarget;if(w=w.listener,z!==d&&f.isPropagationStopped())break t;d=w,f.currentTarget=Y;try{d(f)}catch(P){du(P)}f.currentTarget=null,d=z}else for(b=0;b<s.length;b++){if(w=s[b],z=w.instance,Y=w.currentTarget,w=w.listener,z!==d&&f.isPropagationStopped())break t;d=w,f.currentTarget=Y;try{d(f)}catch(P){du(P)}f.currentTarget=null,d=z}}}}function Tt(e,a){var l=a[Ae];l===void 0&&(l=a[Ae]=new Set);var s=e+"__bubble";l.has(s)||(vg(a,e,2,!1),l.add(s))}function wc(e,a,l){var s=0;a&&(s|=4),vg(l,e,s,a)}var Ou="_reactListening"+Math.random().toString(36).slice(2);function Sc(e){if(!e[Ou]){e[Ou]=!0,fh.forEach(function(l){l!=="selectionchange"&&(D1.has(l)||wc(l,!1,e),wc(l,!0,e))});var a=e.nodeType===9?e:e.ownerDocument;a===null||a[Ou]||(a[Ou]=!0,wc("selectionchange",!1,a))}}function vg(e,a,l,s){switch(Qg(a)){case 2:var f=lb;break;case 8:f=ub;break;default:f=qc}l=f.bind(null,a,l,e),f=void 0,!Xs||a!=="touchstart"&&a!=="touchmove"&&a!=="wheel"||(f=!0),s?f!==void 0?e.addEventListener(a,l,{capture:!0,passive:f}):e.addEventListener(a,l,!0):f!==void 0?e.addEventListener(a,l,{passive:f}):e.addEventListener(a,l,!1)}function Ac(e,a,l,s,f){var d=s;if((a&1)===0&&(a&2)===0&&s!==null)t:for(;;){if(s===null)return;var b=s.tag;if(b===3||b===4){var w=s.stateNode.containerInfo;if(w===f)break;if(b===4)for(b=s.return;b!==null;){var z=b.tag;if((z===3||z===4)&&b.stateNode.containerInfo===f)return;b=b.return}for(;w!==null;){if(b=ra(w),b===null)return;if(z=b.tag,z===5||z===6||z===26||z===27){s=d=b;continue t}w=w.parentNode}}s=s.return}Eh(function(){var Y=d,P=Qs(l),I=[];t:{var X=Ih.get(e);if(X!==void 0){var V=Gl,_t=e;switch(e){case"keypress":if(Ll(l)===0)break t;case"keydown":case"keyup":V=Ov;break;case"focusin":_t="focus",V=Ks;break;case"focusout":_t="blur",V=Ks;break;case"beforeblur":case"afterblur":V=Ks;break;case"click":if(l.button===2)break t;case"auxclick":case"dblclick":case"mousedown":case"mousemove":case"mouseup":case"mouseout":case"mouseover":case"contextmenu":V=Mh;break;case"drag":case"dragend":case"dragenter":case"dragexit":case"dragleave":case"dragover":case"dragstart":case"drop":V=pv;break;case"touchcancel":case"touchend":case"touchmove":case"touchstart":V=Nv;break;case Fh:case Ph:case Jh:V=vv;break;case Wh:V=Rv;break;case"scroll":case"scrollend":V=dv;break;case"wheel":V=jv;break;case"copy":case"cut":case"paste":V=_v;break;case"gotpointercapture":case"lostpointercapture":case"pointercancel":case"pointerdown":case"pointermove":case"pointerout":case"pointerover":case"pointerup":V=Nh;break;case"toggle":case"beforetoggle":V=Uv}var mt=(a&4)!==0,Ut=!mt&&(e==="scroll"||e==="scrollend"),B=mt?X!==null?X+"Capture":null:X;mt=[];for(var D=Y,G;D!==null;){var W=D;if(G=W.stateNode,W=W.tag,W!==5&&W!==26&&W!==27||G===null||B===null||(W=rr(D,B),W!=null&&mt.push(Gr(D,W,G))),Ut)break;D=D.return}0<mt.length&&(X=new V(X,_t,null,l,P),I.push({event:X,listeners:mt}))}}if((a&7)===0){t:{if(X=e==="mouseover"||e==="pointerover",V=e==="mouseout"||e==="pointerout",X&&l!==Gs&&(_t=l.relatedTarget||l.fromElement)&&(ra(_t)||_t[oe]))break t;if((V||X)&&(X=P.window===P?P:(X=P.ownerDocument)?X.defaultView||X.parentWindow:window,V?(_t=l.relatedTarget||l.toElement,V=Y,_t=_t?ra(_t):null,_t!==null&&(Ut=c(_t),mt=_t.tag,_t!==Ut||mt!==5&&mt!==27&&mt!==6)&&(_t=null)):(V=null,_t=Y),V!==_t)){if(mt=Mh,W="onMouseLeave",B="onMouseEnter",D="mouse",(e==="pointerout"||e==="pointerover")&&(mt=Nh,W="onPointerLeave",B="onPointerEnter",D="pointer"),Ut=V==null?X:ar(V),G=_t==null?X:ar(_t),X=new mt(W,D+"leave",V,l,P),X.target=Ut,X.relatedTarget=G,W=null,ra(P)===Y&&(mt=new mt(B,D+"enter",_t,l,P),mt.target=G,mt.relatedTarget=Ut,W=mt),Ut=W,V&&_t)e:{for(mt=V,B=_t,D=0,G=mt;G;G=La(G))D++;for(G=0,W=B;W;W=La(W))G++;for(;0<D-G;)mt=La(mt),D--;for(;0<G-D;)B=La(B),G--;for(;D--;){if(mt===B||B!==null&&mt===B.alternate)break e;mt=La(mt),B=La(B)}mt=null}else mt=null;V!==null&&bg(I,X,V,mt,!1),_t!==null&&Ut!==null&&bg(I,Ut,_t,mt,!0)}}t:{if(X=Y?ar(Y):window,V=X.nodeName&&X.nodeName.toLowerCase(),V==="select"||V==="input"&&X.type==="file")var ft=Hh;else if(Uh(X))if(Lh)ft=$v;else{ft=Xv;var St=Yv}else V=X.nodeName,!V||V.toLowerCase()!=="input"||X.type!=="checkbox"&&X.type!=="radio"?Y&&Bs(Y.elementType)&&(ft=Hh):ft=Vv;if(ft&&(ft=ft(e,Y))){qh(I,ft,l,P);break t}St&&St(e,X,Y),e==="focusout"&&Y&&X.type==="number"&&Y.memoizedProps.value!=null&&Ls(X,"number",X.value)}switch(St=Y?ar(Y):window,e){case"focusin":(Uh(St)||St.contentEditable==="true")&&(pa=St,to=Y,dr=null);break;case"focusout":dr=to=pa=null;break;case"mousedown":eo=!0;break;case"contextmenu":case"mouseup":case"dragend":eo=!1,Zh(I,l,P);break;case"selectionchange":if(Kv)break;case"keydown":case"keyup":Zh(I,l,P)}var dt;if(Ps)t:{switch(e){case"compositionstart":var vt="onCompositionStart";break t;case"compositionend":vt="onCompositionEnd";break t;case"compositionupdate":vt="onCompositionUpdate";break t}vt=void 0}else ga?jh(e,l)&&(vt="onCompositionEnd"):e==="keydown"&&l.keyCode===229&&(vt="onCompositionStart");vt&&(zh&&l.locale!=="ko"&&(ga||vt!=="onCompositionStart"?vt==="onCompositionEnd"&&ga&&(dt=Th()):(Jn=P,Vs="value"in Jn?Jn.value:Jn.textContent,ga=!0)),St=Mu(Y,vt),0<St.length&&(vt=new Ch(vt,e,null,l,P),I.push({event:vt,listeners:St}),dt?vt.data=dt:(dt=kh(l),dt!==null&&(vt.data=dt)))),(dt=Hv?Lv(e,l):Bv(e,l))&&(vt=Mu(Y,"onBeforeInput"),0<vt.length&&(St=new Ch("onBeforeInput","beforeinput",null,l,P),I.push({event:St,listeners:vt}),St.data=dt)),N1(I,e,Y,l,P)}mg(I,a)})}function Gr(e,a,l){return{instance:e,listener:a,currentTarget:l}}function Mu(e,a){for(var l=a+"Capture",s=[];e!==null;){var f=e,d=f.stateNode;if(f=f.tag,f!==5&&f!==26&&f!==27||d===null||(f=rr(e,l),f!=null&&s.unshift(Gr(e,f,d)),f=rr(e,a),f!=null&&s.push(Gr(e,f,d))),e.tag===3)return s;e=e.return}return[]}function La(e){if(e===null)return null;do e=e.return;while(e&&e.tag!==5&&e.tag!==27);return e||null}function bg(e,a,l,s,f){for(var d=a._reactName,b=[];l!==null&&l!==s;){var w=l,z=w.alternate,Y=w.stateNode;if(w=w.tag,z!==null&&z===s)break;w!==5&&w!==26&&w!==27||Y===null||(z=Y,f?(Y=rr(l,d),Y!=null&&b.unshift(Gr(l,Y,z))):f||(Y=rr(l,d),Y!=null&&b.push(Gr(l,Y,z)))),l=l.return}b.length!==0&&e.push({event:a,listeners:b})}var j1=/\r\n?/g,k1=/\u0000|\uFFFD/g;function _g(e){return(typeof e=="string"?e:""+e).replace(j1,`
|
|
49
|
-
`).replace(k1,"")}function xg(e,a){return a=_g(a),_g(e)===a}function Cu(){}function kt(e,a,l,s,f,d){switch(l){case"children":typeof s=="string"?a==="body"||a==="textarea"&&s===""||fa(e,s):(typeof s=="number"||typeof s=="bigint")&&a!=="body"&&fa(e,""+s);break;case"className":jl(e,"class",s);break;case"tabIndex":jl(e,"tabindex",s);break;case"dir":case"role":case"viewBox":case"width":case"height":jl(e,l,s);break;case"style":Sh(e,s,d);break;case"data":if(a!=="object"){jl(e,"data",s);break}case"src":case"href":if(s===""&&(a!=="a"||l!=="href")){e.removeAttribute(l);break}if(s==null||typeof s=="function"||typeof s=="symbol"||typeof s=="boolean"){e.removeAttribute(l);break}s=ql(""+s),e.setAttribute(l,s);break;case"action":case"formAction":if(typeof s=="function"){e.setAttribute(l,"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 d=="function"&&(l==="formAction"?(a!=="input"&&kt(e,a,"name",f.name,f,null),kt(e,a,"formEncType",f.formEncType,f,null),kt(e,a,"formMethod",f.formMethod,f,null),kt(e,a,"formTarget",f.formTarget,f,null)):(kt(e,a,"encType",f.encType,f,null),kt(e,a,"method",f.method,f,null),kt(e,a,"target",f.target,f,null)));if(s==null||typeof s=="symbol"||typeof s=="boolean"){e.removeAttribute(l);break}s=ql(""+s),e.setAttribute(l,s);break;case"onClick":s!=null&&(e.onclick=Cu);break;case"onScroll":s!=null&&Tt("scroll",e);break;case"onScrollEnd":s!=null&&Tt("scrollend",e);break;case"dangerouslySetInnerHTML":if(s!=null){if(typeof s!="object"||!("__html"in s))throw Error(u(61));if(l=s.__html,l!=null){if(f.children!=null)throw Error(u(60));e.innerHTML=l}}break;case"multiple":e.multiple=s&&typeof s!="function"&&typeof s!="symbol";break;case"muted":e.muted=s&&typeof s!="function"&&typeof s!="symbol";break;case"suppressContentEditableWarning":case"suppressHydrationWarning":case"defaultValue":case"defaultChecked":case"innerHTML":case"ref":break;case"autoFocus":break;case"xlinkHref":if(s==null||typeof s=="function"||typeof s=="boolean"||typeof s=="symbol"){e.removeAttribute("xlink:href");break}l=ql(""+s),e.setAttributeNS("http://www.w3.org/1999/xlink","xlink:href",l);break;case"contentEditable":case"spellCheck":case"draggable":case"value":case"autoReverse":case"externalResourcesRequired":case"focusable":case"preserveAlpha":s!=null&&typeof s!="function"&&typeof s!="symbol"?e.setAttribute(l,""+s):e.removeAttribute(l);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":s&&typeof s!="function"&&typeof s!="symbol"?e.setAttribute(l,""):e.removeAttribute(l);break;case"capture":case"download":s===!0?e.setAttribute(l,""):s!==!1&&s!=null&&typeof s!="function"&&typeof s!="symbol"?e.setAttribute(l,s):e.removeAttribute(l);break;case"cols":case"rows":case"size":case"span":s!=null&&typeof s!="function"&&typeof s!="symbol"&&!isNaN(s)&&1<=s?e.setAttribute(l,s):e.removeAttribute(l);break;case"rowSpan":case"start":s==null||typeof s=="function"||typeof s=="symbol"||isNaN(s)?e.removeAttribute(l):e.setAttribute(l,s);break;case"popover":Tt("beforetoggle",e),Tt("toggle",e),Dl(e,"popover",s);break;case"xlinkActuate":On(e,"http://www.w3.org/1999/xlink","xlink:actuate",s);break;case"xlinkArcrole":On(e,"http://www.w3.org/1999/xlink","xlink:arcrole",s);break;case"xlinkRole":On(e,"http://www.w3.org/1999/xlink","xlink:role",s);break;case"xlinkShow":On(e,"http://www.w3.org/1999/xlink","xlink:show",s);break;case"xlinkTitle":On(e,"http://www.w3.org/1999/xlink","xlink:title",s);break;case"xlinkType":On(e,"http://www.w3.org/1999/xlink","xlink:type",s);break;case"xmlBase":On(e,"http://www.w3.org/XML/1998/namespace","xml:base",s);break;case"xmlLang":On(e,"http://www.w3.org/XML/1998/namespace","xml:lang",s);break;case"xmlSpace":On(e,"http://www.w3.org/XML/1998/namespace","xml:space",s);break;case"is":Dl(e,"is",s);break;case"innerText":case"textContent":break;default:(!(2<l.length)||l[0]!=="o"&&l[0]!=="O"||l[1]!=="n"&&l[1]!=="N")&&(l=fv.get(l)||l,Dl(e,l,s))}}function Ec(e,a,l,s,f,d){switch(l){case"style":Sh(e,s,d);break;case"dangerouslySetInnerHTML":if(s!=null){if(typeof s!="object"||!("__html"in s))throw Error(u(61));if(l=s.__html,l!=null){if(f.children!=null)throw Error(u(60));e.innerHTML=l}}break;case"children":typeof s=="string"?fa(e,s):(typeof s=="number"||typeof s=="bigint")&&fa(e,""+s);break;case"onScroll":s!=null&&Tt("scroll",e);break;case"onScrollEnd":s!=null&&Tt("scrollend",e);break;case"onClick":s!=null&&(e.onclick=Cu);break;case"suppressContentEditableWarning":case"suppressHydrationWarning":case"innerHTML":case"ref":break;case"innerText":case"textContent":break;default:if(!hh.hasOwnProperty(l))t:{if(l[0]==="o"&&l[1]==="n"&&(f=l.endsWith("Capture"),a=l.slice(2,f?l.length-7:void 0),d=e[Kt]||null,d=d!=null?d[l]:null,typeof d=="function"&&e.removeEventListener(a,d,f),typeof s=="function")){typeof d!="function"&&d!==null&&(l in e?e[l]=null:e.hasAttribute(l)&&e.removeAttribute(l)),e.addEventListener(a,s,f);break t}l in e?e[l]=s:s===!0?e.setAttribute(l,""):Dl(e,l,s)}}}function he(e,a,l){switch(a){case"div":case"span":case"svg":case"path":case"a":case"g":case"p":case"li":break;case"img":Tt("error",e),Tt("load",e);var s=!1,f=!1,d;for(d in l)if(l.hasOwnProperty(d)){var b=l[d];if(b!=null)switch(d){case"src":s=!0;break;case"srcSet":f=!0;break;case"children":case"dangerouslySetInnerHTML":throw Error(u(137,a));default:kt(e,a,d,b,l,null)}}f&&kt(e,a,"srcSet",l.srcSet,l,null),s&&kt(e,a,"src",l.src,l,null);return;case"input":Tt("invalid",e);var w=d=b=f=null,z=null,Y=null;for(s in l)if(l.hasOwnProperty(s)){var P=l[s];if(P!=null)switch(s){case"name":f=P;break;case"type":b=P;break;case"checked":z=P;break;case"defaultChecked":Y=P;break;case"value":d=P;break;case"defaultValue":w=P;break;case"children":case"dangerouslySetInnerHTML":if(P!=null)throw Error(u(137,a));break;default:kt(e,a,s,P,l,null)}}bh(e,d,w,z,Y,b,f,!1),kl(e);return;case"select":Tt("invalid",e),s=b=d=null;for(f in l)if(l.hasOwnProperty(f)&&(w=l[f],w!=null))switch(f){case"value":d=w;break;case"defaultValue":b=w;break;case"multiple":s=w;default:kt(e,a,f,w,l,null)}a=d,l=b,e.multiple=!!s,a!=null?ca(e,!!s,a,!1):l!=null&&ca(e,!!s,l,!0);return;case"textarea":Tt("invalid",e),d=f=s=null;for(b in l)if(l.hasOwnProperty(b)&&(w=l[b],w!=null))switch(b){case"value":s=w;break;case"defaultValue":f=w;break;case"children":d=w;break;case"dangerouslySetInnerHTML":if(w!=null)throw Error(u(91));break;default:kt(e,a,b,w,l,null)}xh(e,s,f,d),kl(e);return;case"option":for(z in l)if(l.hasOwnProperty(z)&&(s=l[z],s!=null))switch(z){case"selected":e.selected=s&&typeof s!="function"&&typeof s!="symbol";break;default:kt(e,a,z,s,l,null)}return;case"dialog":Tt("beforetoggle",e),Tt("toggle",e),Tt("cancel",e),Tt("close",e);break;case"iframe":case"object":Tt("load",e);break;case"video":case"audio":for(s=0;s<Br.length;s++)Tt(Br[s],e);break;case"image":Tt("error",e),Tt("load",e);break;case"details":Tt("toggle",e);break;case"embed":case"source":case"link":Tt("error",e),Tt("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(Y in l)if(l.hasOwnProperty(Y)&&(s=l[Y],s!=null))switch(Y){case"children":case"dangerouslySetInnerHTML":throw Error(u(137,a));default:kt(e,a,Y,s,l,null)}return;default:if(Bs(a)){for(P in l)l.hasOwnProperty(P)&&(s=l[P],s!==void 0&&Ec(e,a,P,s,l,void 0));return}}for(w in l)l.hasOwnProperty(w)&&(s=l[w],s!=null&&kt(e,a,w,s,l,null))}function U1(e,a,l,s){switch(a){case"div":case"span":case"svg":case"path":case"a":case"g":case"p":case"li":break;case"input":var f=null,d=null,b=null,w=null,z=null,Y=null,P=null;for(V in l){var I=l[V];if(l.hasOwnProperty(V)&&I!=null)switch(V){case"checked":break;case"value":break;case"defaultValue":z=I;default:s.hasOwnProperty(V)||kt(e,a,V,null,s,I)}}for(var X in s){var V=s[X];if(I=l[X],s.hasOwnProperty(X)&&(V!=null||I!=null))switch(X){case"type":d=V;break;case"name":f=V;break;case"checked":Y=V;break;case"defaultChecked":P=V;break;case"value":b=V;break;case"defaultValue":w=V;break;case"children":case"dangerouslySetInnerHTML":if(V!=null)throw Error(u(137,a));break;default:V!==I&&kt(e,a,X,V,s,I)}}Hs(e,b,w,z,Y,P,d,f);return;case"select":V=b=w=X=null;for(d in l)if(z=l[d],l.hasOwnProperty(d)&&z!=null)switch(d){case"value":break;case"multiple":V=z;default:s.hasOwnProperty(d)||kt(e,a,d,null,s,z)}for(f in s)if(d=s[f],z=l[f],s.hasOwnProperty(f)&&(d!=null||z!=null))switch(f){case"value":X=d;break;case"defaultValue":w=d;break;case"multiple":b=d;default:d!==z&&kt(e,a,f,d,s,z)}a=w,l=b,s=V,X!=null?ca(e,!!l,X,!1):!!s!=!!l&&(a!=null?ca(e,!!l,a,!0):ca(e,!!l,l?[]:"",!1));return;case"textarea":V=X=null;for(w in l)if(f=l[w],l.hasOwnProperty(w)&&f!=null&&!s.hasOwnProperty(w))switch(w){case"value":break;case"children":break;default:kt(e,a,w,null,s,f)}for(b in s)if(f=s[b],d=l[b],s.hasOwnProperty(b)&&(f!=null||d!=null))switch(b){case"value":X=f;break;case"defaultValue":V=f;break;case"children":break;case"dangerouslySetInnerHTML":if(f!=null)throw Error(u(91));break;default:f!==d&&kt(e,a,b,f,s,d)}_h(e,X,V);return;case"option":for(var _t in l)if(X=l[_t],l.hasOwnProperty(_t)&&X!=null&&!s.hasOwnProperty(_t))switch(_t){case"selected":e.selected=!1;break;default:kt(e,a,_t,null,s,X)}for(z in s)if(X=s[z],V=l[z],s.hasOwnProperty(z)&&X!==V&&(X!=null||V!=null))switch(z){case"selected":e.selected=X&&typeof X!="function"&&typeof X!="symbol";break;default:kt(e,a,z,X,s,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 mt in l)X=l[mt],l.hasOwnProperty(mt)&&X!=null&&!s.hasOwnProperty(mt)&&kt(e,a,mt,null,s,X);for(Y in s)if(X=s[Y],V=l[Y],s.hasOwnProperty(Y)&&X!==V&&(X!=null||V!=null))switch(Y){case"children":case"dangerouslySetInnerHTML":if(X!=null)throw Error(u(137,a));break;default:kt(e,a,Y,X,s,V)}return;default:if(Bs(a)){for(var Ut in l)X=l[Ut],l.hasOwnProperty(Ut)&&X!==void 0&&!s.hasOwnProperty(Ut)&&Ec(e,a,Ut,void 0,s,X);for(P in s)X=s[P],V=l[P],!s.hasOwnProperty(P)||X===V||X===void 0&&V===void 0||Ec(e,a,P,X,s,V);return}}for(var B in l)X=l[B],l.hasOwnProperty(B)&&X!=null&&!s.hasOwnProperty(B)&&kt(e,a,B,null,s,X);for(I in s)X=s[I],V=l[I],!s.hasOwnProperty(I)||X===V||X==null&&V==null||kt(e,a,I,X,s,V)}var Tc=null,Oc=null;function Nu(e){return e.nodeType===9?e:e.ownerDocument}function wg(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 Sg(e,a){if(e===0)switch(a){case"svg":return 1;case"math":return 2;default:return 0}return e===1&&a==="foreignObject"?0:e}function Mc(e,a){return e==="textarea"||e==="noscript"||typeof a.children=="string"||typeof a.children=="number"||typeof a.children=="bigint"||typeof a.dangerouslySetInnerHTML=="object"&&a.dangerouslySetInnerHTML!==null&&a.dangerouslySetInnerHTML.__html!=null}var Cc=null;function q1(){var e=window.event;return e&&e.type==="popstate"?e===Cc?!1:(Cc=e,!0):(Cc=null,!1)}var Ag=typeof setTimeout=="function"?setTimeout:void 0,H1=typeof clearTimeout=="function"?clearTimeout:void 0,Eg=typeof Promise=="function"?Promise:void 0,L1=typeof queueMicrotask=="function"?queueMicrotask:typeof Eg<"u"?function(e){return Eg.resolve(null).then(e).catch(B1)}:Ag;function B1(e){setTimeout(function(){throw e})}function di(e){return e==="head"}function Tg(e,a){var l=a,s=0,f=0;do{var d=l.nextSibling;if(e.removeChild(l),d&&d.nodeType===8)if(l=d.data,l==="/$"){if(0<s&&8>s){l=s;var b=e.ownerDocument;if(l&1&&Qr(b.documentElement),l&2&&Qr(b.body),l&4)for(l=b.head,Qr(l),b=l.firstChild;b;){var w=b.nextSibling,z=b.nodeName;b[ir]||z==="SCRIPT"||z==="STYLE"||z==="LINK"&&b.rel.toLowerCase()==="stylesheet"||l.removeChild(b),b=w}}if(f===0){e.removeChild(d),Pr(a);return}f--}else l==="$"||l==="$?"||l==="$!"?f++:s=l.charCodeAt(0)-48;else s=0;l=d}while(l);Pr(a)}function Nc(e){var a=e.firstChild;for(a&&a.nodeType===10&&(a=a.nextSibling);a;){var l=a;switch(a=a.nextSibling,l.nodeName){case"HTML":case"HEAD":case"BODY":Nc(l),js(l);continue;case"SCRIPT":case"STYLE":continue;case"LINK":if(l.rel.toLowerCase()==="stylesheet")continue}e.removeChild(l)}}function G1(e,a,l,s){for(;e.nodeType===1;){var f=l;if(e.nodeName.toLowerCase()!==a.toLowerCase()){if(!s&&(e.nodeName!=="INPUT"||e.type!=="hidden"))break}else if(s){if(!e[ir])switch(a){case"meta":if(!e.hasAttribute("itemprop"))break;return e;case"link":if(d=e.getAttribute("rel"),d==="stylesheet"&&e.hasAttribute("data-precedence"))break;if(d!==f.rel||e.getAttribute("href")!==(f.href==null||f.href===""?null:f.href)||e.getAttribute("crossorigin")!==(f.crossOrigin==null?null:f.crossOrigin)||e.getAttribute("title")!==(f.title==null?null:f.title))break;return e;case"style":if(e.hasAttribute("data-precedence"))break;return e;case"script":if(d=e.getAttribute("src"),(d!==(f.src==null?null:f.src)||e.getAttribute("type")!==(f.type==null?null:f.type)||e.getAttribute("crossorigin")!==(f.crossOrigin==null?null:f.crossOrigin))&&d&&e.hasAttribute("async")&&!e.hasAttribute("itemprop"))break;return e;default:return e}}else if(a==="input"&&e.type==="hidden"){var d=f.name==null?null:""+f.name;if(f.type==="hidden"&&e.getAttribute("name")===d)return e}else return e;if(e=an(e.nextSibling),e===null)break}return null}function Q1(e,a,l){if(a==="")return null;for(;e.nodeType!==3;)if((e.nodeType!==1||e.nodeName!=="INPUT"||e.type!=="hidden")&&!l||(e=an(e.nextSibling),e===null))return null;return e}function zc(e){return e.data==="$!"||e.data==="$?"&&e.ownerDocument.readyState==="complete"}function Y1(e,a){var l=e.ownerDocument;if(e.data!=="$?"||l.readyState==="complete")a();else{var s=function(){a(),l.removeEventListener("DOMContentLoaded",s)};l.addEventListener("DOMContentLoaded",s),e._reactRetry=s}}function an(e){for(;e!=null;e=e.nextSibling){var a=e.nodeType;if(a===1||a===3)break;if(a===8){if(a=e.data,a==="$"||a==="$!"||a==="$?"||a==="F!"||a==="F")break;if(a==="/$")return null}}return e}var Rc=null;function Og(e){e=e.previousSibling;for(var a=0;e;){if(e.nodeType===8){var l=e.data;if(l==="$"||l==="$!"||l==="$?"){if(a===0)return e;a--}else l==="/$"&&a++}e=e.previousSibling}return null}function Mg(e,a,l){switch(a=Nu(l),e){case"html":if(e=a.documentElement,!e)throw Error(u(452));return e;case"head":if(e=a.head,!e)throw Error(u(453));return e;case"body":if(e=a.body,!e)throw Error(u(454));return e;default:throw Error(u(451))}}function Qr(e){for(var a=e.attributes;a.length;)e.removeAttributeNode(a[0]);js(e)}var Fe=new Map,Cg=new Set;function zu(e){return typeof e.getRootNode=="function"?e.getRootNode():e.nodeType===9?e:e.ownerDocument}var Gn=Z.d;Z.d={f:X1,r:V1,D:$1,C:Z1,L:K1,m:F1,X:J1,S:P1,M:W1};function X1(){var e=Gn.f(),a=wu();return e||a}function V1(e){var a=la(e);a!==null&&a.tag===5&&a.type==="form"?Fd(a):Gn.r(e)}var Ba=typeof document>"u"?null:document;function Ng(e,a,l){var s=Ba;if(s&&typeof a=="string"&&a){var f=Qe(a);f='link[rel="'+e+'"][href="'+f+'"]',typeof l=="string"&&(f+='[crossorigin="'+l+'"]'),Cg.has(f)||(Cg.add(f),e={rel:e,crossOrigin:l,href:a},s.querySelector(f)===null&&(a=s.createElement("link"),he(a,"link",e),ae(a),s.head.appendChild(a)))}}function $1(e){Gn.D(e),Ng("dns-prefetch",e,null)}function Z1(e,a){Gn.C(e,a),Ng("preconnect",e,a)}function K1(e,a,l){Gn.L(e,a,l);var s=Ba;if(s&&e&&a){var f='link[rel="preload"][as="'+Qe(a)+'"]';a==="image"&&l&&l.imageSrcSet?(f+='[imagesrcset="'+Qe(l.imageSrcSet)+'"]',typeof l.imageSizes=="string"&&(f+='[imagesizes="'+Qe(l.imageSizes)+'"]')):f+='[href="'+Qe(e)+'"]';var d=f;switch(a){case"style":d=Ga(e);break;case"script":d=Qa(e)}Fe.has(d)||(e=v({rel:"preload",href:a==="image"&&l&&l.imageSrcSet?void 0:e,as:a},l),Fe.set(d,e),s.querySelector(f)!==null||a==="style"&&s.querySelector(Yr(d))||a==="script"&&s.querySelector(Xr(d))||(a=s.createElement("link"),he(a,"link",e),ae(a),s.head.appendChild(a)))}}function F1(e,a){Gn.m(e,a);var l=Ba;if(l&&e){var s=a&&typeof a.as=="string"?a.as:"script",f='link[rel="modulepreload"][as="'+Qe(s)+'"][href="'+Qe(e)+'"]',d=f;switch(s){case"audioworklet":case"paintworklet":case"serviceworker":case"sharedworker":case"worker":case"script":d=Qa(e)}if(!Fe.has(d)&&(e=v({rel:"modulepreload",href:e},a),Fe.set(d,e),l.querySelector(f)===null)){switch(s){case"audioworklet":case"paintworklet":case"serviceworker":case"sharedworker":case"worker":case"script":if(l.querySelector(Xr(d)))return}s=l.createElement("link"),he(s,"link",e),ae(s),l.head.appendChild(s)}}}function P1(e,a,l){Gn.S(e,a,l);var s=Ba;if(s&&e){var f=ua(s).hoistableStyles,d=Ga(e);a=a||"default";var b=f.get(d);if(!b){var w={loading:0,preload:null};if(b=s.querySelector(Yr(d)))w.loading=5;else{e=v({rel:"stylesheet",href:e,"data-precedence":a},l),(l=Fe.get(d))&&Dc(e,l);var z=b=s.createElement("link");ae(z),he(z,"link",e),z._p=new Promise(function(Y,P){z.onload=Y,z.onerror=P}),z.addEventListener("load",function(){w.loading|=1}),z.addEventListener("error",function(){w.loading|=2}),w.loading|=4,Ru(b,a,s)}b={type:"stylesheet",instance:b,count:1,state:w},f.set(d,b)}}}function J1(e,a){Gn.X(e,a);var l=Ba;if(l&&e){var s=ua(l).hoistableScripts,f=Qa(e),d=s.get(f);d||(d=l.querySelector(Xr(f)),d||(e=v({src:e,async:!0},a),(a=Fe.get(f))&&jc(e,a),d=l.createElement("script"),ae(d),he(d,"link",e),l.head.appendChild(d)),d={type:"script",instance:d,count:1,state:null},s.set(f,d))}}function W1(e,a){Gn.M(e,a);var l=Ba;if(l&&e){var s=ua(l).hoistableScripts,f=Qa(e),d=s.get(f);d||(d=l.querySelector(Xr(f)),d||(e=v({src:e,async:!0,type:"module"},a),(a=Fe.get(f))&&jc(e,a),d=l.createElement("script"),ae(d),he(d,"link",e),l.head.appendChild(d)),d={type:"script",instance:d,count:1,state:null},s.set(f,d))}}function zg(e,a,l,s){var f=(f=ht.current)?zu(f):null;if(!f)throw Error(u(446));switch(e){case"meta":case"title":return null;case"style":return typeof l.precedence=="string"&&typeof l.href=="string"?(a=Ga(l.href),l=ua(f).hoistableStyles,s=l.get(a),s||(s={type:"style",instance:null,count:0,state:null},l.set(a,s)),s):{type:"void",instance:null,count:0,state:null};case"link":if(l.rel==="stylesheet"&&typeof l.href=="string"&&typeof l.precedence=="string"){e=Ga(l.href);var d=ua(f).hoistableStyles,b=d.get(e);if(b||(f=f.ownerDocument||f,b={type:"stylesheet",instance:null,count:0,state:{loading:0,preload:null}},d.set(e,b),(d=f.querySelector(Yr(e)))&&!d._p&&(b.instance=d,b.state.loading=5),Fe.has(e)||(l={rel:"preload",as:"style",href:l.href,crossOrigin:l.crossOrigin,integrity:l.integrity,media:l.media,hrefLang:l.hrefLang,referrerPolicy:l.referrerPolicy},Fe.set(e,l),d||I1(f,e,l,b.state))),a&&s===null)throw Error(u(528,""));return b}if(a&&s!==null)throw Error(u(529,""));return null;case"script":return a=l.async,l=l.src,typeof l=="string"&&a&&typeof a!="function"&&typeof a!="symbol"?(a=Qa(l),l=ua(f).hoistableScripts,s=l.get(a),s||(s={type:"script",instance:null,count:0,state:null},l.set(a,s)),s):{type:"void",instance:null,count:0,state:null};default:throw Error(u(444,e))}}function Ga(e){return'href="'+Qe(e)+'"'}function Yr(e){return'link[rel="stylesheet"]['+e+"]"}function Rg(e){return v({},e,{"data-precedence":e.precedence,precedence:null})}function I1(e,a,l,s){e.querySelector('link[rel="preload"][as="style"]['+a+"]")?s.loading=1:(a=e.createElement("link"),s.preload=a,a.addEventListener("load",function(){return s.loading|=1}),a.addEventListener("error",function(){return s.loading|=2}),he(a,"link",l),ae(a),e.head.appendChild(a))}function Qa(e){return'[src="'+Qe(e)+'"]'}function Xr(e){return"script[async]"+e}function Dg(e,a,l){if(a.count++,a.instance===null)switch(a.type){case"style":var s=e.querySelector('style[data-href~="'+Qe(l.href)+'"]');if(s)return a.instance=s,ae(s),s;var f=v({},l,{"data-href":l.href,"data-precedence":l.precedence,href:null,precedence:null});return s=(e.ownerDocument||e).createElement("style"),ae(s),he(s,"style",f),Ru(s,l.precedence,e),a.instance=s;case"stylesheet":f=Ga(l.href);var d=e.querySelector(Yr(f));if(d)return a.state.loading|=4,a.instance=d,ae(d),d;s=Rg(l),(f=Fe.get(f))&&Dc(s,f),d=(e.ownerDocument||e).createElement("link"),ae(d);var b=d;return b._p=new Promise(function(w,z){b.onload=w,b.onerror=z}),he(d,"link",s),a.state.loading|=4,Ru(d,l.precedence,e),a.instance=d;case"script":return d=Qa(l.src),(f=e.querySelector(Xr(d)))?(a.instance=f,ae(f),f):(s=l,(f=Fe.get(d))&&(s=v({},l),jc(s,f)),e=e.ownerDocument||e,f=e.createElement("script"),ae(f),he(f,"link",s),e.head.appendChild(f),a.instance=f);case"void":return null;default:throw Error(u(443,a.type))}else a.type==="stylesheet"&&(a.state.loading&4)===0&&(s=a.instance,a.state.loading|=4,Ru(s,l.precedence,e));return a.instance}function Ru(e,a,l){for(var s=l.querySelectorAll('link[rel="stylesheet"][data-precedence],style[data-precedence]'),f=s.length?s[s.length-1]:null,d=f,b=0;b<s.length;b++){var w=s[b];if(w.dataset.precedence===a)d=w;else if(d!==f)break}d?d.parentNode.insertBefore(e,d.nextSibling):(a=l.nodeType===9?l.head:l,a.insertBefore(e,a.firstChild))}function Dc(e,a){e.crossOrigin==null&&(e.crossOrigin=a.crossOrigin),e.referrerPolicy==null&&(e.referrerPolicy=a.referrerPolicy),e.title==null&&(e.title=a.title)}function jc(e,a){e.crossOrigin==null&&(e.crossOrigin=a.crossOrigin),e.referrerPolicy==null&&(e.referrerPolicy=a.referrerPolicy),e.integrity==null&&(e.integrity=a.integrity)}var Du=null;function jg(e,a,l){if(Du===null){var s=new Map,f=Du=new Map;f.set(l,s)}else f=Du,s=f.get(l),s||(s=new Map,f.set(l,s));if(s.has(e))return s;for(s.set(e,null),l=l.getElementsByTagName(e),f=0;f<l.length;f++){var d=l[f];if(!(d[ir]||d[It]||e==="link"&&d.getAttribute("rel")==="stylesheet")&&d.namespaceURI!=="http://www.w3.org/2000/svg"){var b=d.getAttribute(a)||"";b=e+b;var w=s.get(b);w?w.push(d):s.set(b,[d])}}return s}function kg(e,a,l){e=e.ownerDocument||e,e.head.insertBefore(l,a==="title"?e.querySelector("head > title"):null)}function tb(e,a,l){if(l===1||a.itemProp!=null)return!1;switch(e){case"meta":case"title":return!0;case"style":if(typeof a.precedence!="string"||typeof a.href!="string"||a.href==="")break;return!0;case"link":if(typeof a.rel!="string"||typeof a.href!="string"||a.href===""||a.onLoad||a.onError)break;switch(a.rel){case"stylesheet":return e=a.disabled,typeof a.precedence=="string"&&e==null;default:return!0}case"script":if(a.async&&typeof a.async!="function"&&typeof a.async!="symbol"&&!a.onLoad&&!a.onError&&a.src&&typeof a.src=="string")return!0}return!1}function Ug(e){return!(e.type==="stylesheet"&&(e.state.loading&3)===0)}var Vr=null;function eb(){}function nb(e,a,l){if(Vr===null)throw Error(u(475));var s=Vr;if(a.type==="stylesheet"&&(typeof l.media!="string"||matchMedia(l.media).matches!==!1)&&(a.state.loading&4)===0){if(a.instance===null){var f=Ga(l.href),d=e.querySelector(Yr(f));if(d){e=d._p,e!==null&&typeof e=="object"&&typeof e.then=="function"&&(s.count++,s=ju.bind(s),e.then(s,s)),a.state.loading|=4,a.instance=d,ae(d);return}d=e.ownerDocument||e,l=Rg(l),(f=Fe.get(f))&&Dc(l,f),d=d.createElement("link"),ae(d);var b=d;b._p=new Promise(function(w,z){b.onload=w,b.onerror=z}),he(d,"link",l),a.instance=d}s.stylesheets===null&&(s.stylesheets=new Map),s.stylesheets.set(a,e),(e=a.state.preload)&&(a.state.loading&3)===0&&(s.count++,a=ju.bind(s),e.addEventListener("load",a),e.addEventListener("error",a))}}function ib(){if(Vr===null)throw Error(u(475));var e=Vr;return e.stylesheets&&e.count===0&&kc(e,e.stylesheets),0<e.count?function(a){var l=setTimeout(function(){if(e.stylesheets&&kc(e,e.stylesheets),e.unsuspend){var s=e.unsuspend;e.unsuspend=null,s()}},6e4);return e.unsuspend=a,function(){e.unsuspend=null,clearTimeout(l)}}:null}function ju(){if(this.count--,this.count===0){if(this.stylesheets)kc(this,this.stylesheets);else if(this.unsuspend){var e=this.unsuspend;this.unsuspend=null,e()}}}var ku=null;function kc(e,a){e.stylesheets=null,e.unsuspend!==null&&(e.count++,ku=new Map,a.forEach(ab,e),ku=null,ju.call(e))}function ab(e,a){if(!(a.state.loading&4)){var l=ku.get(e);if(l)var s=l.get(null);else{l=new Map,ku.set(e,l);for(var f=e.querySelectorAll("link[data-precedence],style[data-precedence]"),d=0;d<f.length;d++){var b=f[d];(b.nodeName==="LINK"||b.getAttribute("media")!=="not all")&&(l.set(b.dataset.precedence,b),s=b)}s&&l.set(null,s)}f=a.instance,b=f.getAttribute("data-precedence"),d=l.get(b)||s,d===s&&l.set(null,f),l.set(b,f),this.count++,s=ju.bind(this),f.addEventListener("load",s),f.addEventListener("error",s),d?d.parentNode.insertBefore(f,d.nextSibling):(e=e.nodeType===9?e.head:e,e.insertBefore(f,e.firstChild)),a.state.loading|=4}}var $r={$$typeof:H,Provider:null,Consumer:null,_currentValue:et,_currentValue2:et,_threadCount:0};function rb(e,a,l,s,f,d,b,w){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=er(-1),this.entangledLanes=this.shellSuspendCounter=this.errorRecoveryDisabledLanes=this.expiredLanes=this.warmLanes=this.pingedLanes=this.suspendedLanes=this.pendingLanes=0,this.entanglements=er(0),this.hiddenUpdates=er(null),this.identifierPrefix=s,this.onUncaughtError=f,this.onCaughtError=d,this.onRecoverableError=b,this.pooledCache=null,this.pooledCacheLanes=0,this.formState=w,this.incompleteTransitions=new Map}function qg(e,a,l,s,f,d,b,w,z,Y,P,I){return e=new rb(e,a,l,b,w,z,Y,I),a=1,d===!0&&(a|=24),d=Re(3,null,null,a),e.current=d,d.stateNode=e,a=yo(),a.refCount++,e.pooledCache=a,a.refCount++,d.memoizedState={element:s,isDehydrated:l,cache:a},_o(d),e}function Hg(e){return e?(e=ba,e):ba}function Lg(e,a,l,s,f,d){f=Hg(f),s.context===null?s.context=f:s.pendingContext=f,s=ti(a),s.payload={element:l},d=d===void 0?null:d,d!==null&&(s.callback=d),l=ei(e,s,a),l!==null&&(qe(l,e,a),wr(l,e,a))}function Bg(e,a){if(e=e.memoizedState,e!==null&&e.dehydrated!==null){var l=e.retryLane;e.retryLane=l!==0&&l<a?l:a}}function Uc(e,a){Bg(e,a),(e=e.alternate)&&Bg(e,a)}function Gg(e){if(e.tag===13){var a=va(e,67108864);a!==null&&qe(a,e,67108864),Uc(e,67108864)}}var Uu=!0;function lb(e,a,l,s){var f=N.T;N.T=null;var d=Z.p;try{Z.p=2,qc(e,a,l,s)}finally{Z.p=d,N.T=f}}function ub(e,a,l,s){var f=N.T;N.T=null;var d=Z.p;try{Z.p=8,qc(e,a,l,s)}finally{Z.p=d,N.T=f}}function qc(e,a,l,s){if(Uu){var f=Hc(s);if(f===null)Ac(e,a,s,qu,l),Yg(e,s);else if(ob(f,e,a,l,s))s.stopPropagation();else if(Yg(e,s),a&4&&-1<sb.indexOf(e)){for(;f!==null;){var d=la(f);if(d!==null)switch(d.tag){case 3:if(d=d.stateNode,d.current.memoizedState.isDehydrated){var b=Tn(d.pendingLanes);if(b!==0){var w=d;for(w.pendingLanes|=2,w.entangledLanes|=2;b;){var z=1<<31-be(b);w.entanglements[1]|=z,b&=~z}yn(d),(zt&6)===0&&(_u=Be()+500,Lr(0))}}break;case 13:w=va(d,2),w!==null&&qe(w,d,2),wu(),Uc(d,2)}if(d=Hc(s),d===null&&Ac(e,a,s,qu,l),d===f)break;f=d}f!==null&&s.stopPropagation()}else Ac(e,a,s,null,l)}}function Hc(e){return e=Qs(e),Lc(e)}var qu=null;function Lc(e){if(qu=null,e=ra(e),e!==null){var a=c(e);if(a===null)e=null;else{var l=a.tag;if(l===13){if(e=h(a),e!==null)return e;e=null}else if(l===3){if(a.stateNode.current.memoizedState.isDehydrated)return a.tag===3?a.stateNode.containerInfo:null;e=null}else a!==e&&(e=null)}}return qu=e,null}function Qg(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(Cl()){case Sn:return 2;case Si:return 8;case Ai:case Os:return 32;case An:return 268435456;default:return 32}default:return 32}}var Bc=!1,gi=null,pi=null,yi=null,Zr=new Map,Kr=new Map,mi=[],sb="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(" ");function Yg(e,a){switch(e){case"focusin":case"focusout":gi=null;break;case"dragenter":case"dragleave":pi=null;break;case"mouseover":case"mouseout":yi=null;break;case"pointerover":case"pointerout":Zr.delete(a.pointerId);break;case"gotpointercapture":case"lostpointercapture":Kr.delete(a.pointerId)}}function Fr(e,a,l,s,f,d){return e===null||e.nativeEvent!==d?(e={blockedOn:a,domEventName:l,eventSystemFlags:s,nativeEvent:d,targetContainers:[f]},a!==null&&(a=la(a),a!==null&&Gg(a)),e):(e.eventSystemFlags|=s,a=e.targetContainers,f!==null&&a.indexOf(f)===-1&&a.push(f),e)}function ob(e,a,l,s,f){switch(a){case"focusin":return gi=Fr(gi,e,a,l,s,f),!0;case"dragenter":return pi=Fr(pi,e,a,l,s,f),!0;case"mouseover":return yi=Fr(yi,e,a,l,s,f),!0;case"pointerover":var d=f.pointerId;return Zr.set(d,Fr(Zr.get(d)||null,e,a,l,s,f)),!0;case"gotpointercapture":return d=f.pointerId,Kr.set(d,Fr(Kr.get(d)||null,e,a,l,s,f)),!0}return!1}function Xg(e){var a=ra(e.target);if(a!==null){var l=c(a);if(l!==null){if(a=l.tag,a===13){if(a=h(l),a!==null){e.blockedOn=a,fn(e.priority,function(){if(l.tag===13){var s=Ue();s=pt(s);var f=va(l,s);f!==null&&qe(f,l,s),Uc(l,s)}});return}}else if(a===3&&l.stateNode.current.memoizedState.isDehydrated){e.blockedOn=l.tag===3?l.stateNode.containerInfo:null;return}}}e.blockedOn=null}function Hu(e){if(e.blockedOn!==null)return!1;for(var a=e.targetContainers;0<a.length;){var l=Hc(e.nativeEvent);if(l===null){l=e.nativeEvent;var s=new l.constructor(l.type,l);Gs=s,l.target.dispatchEvent(s),Gs=null}else return a=la(l),a!==null&&Gg(a),e.blockedOn=l,!1;a.shift()}return!0}function Vg(e,a,l){Hu(e)&&l.delete(a)}function cb(){Bc=!1,gi!==null&&Hu(gi)&&(gi=null),pi!==null&&Hu(pi)&&(pi=null),yi!==null&&Hu(yi)&&(yi=null),Zr.forEach(Vg),Kr.forEach(Vg)}function Lu(e,a){e.blockedOn===a&&(e.blockedOn=null,Bc||(Bc=!0,n.unstable_scheduleCallback(n.unstable_NormalPriority,cb)))}var Bu=null;function $g(e){Bu!==e&&(Bu=e,n.unstable_scheduleCallback(n.unstable_NormalPriority,function(){Bu===e&&(Bu=null);for(var a=0;a<e.length;a+=3){var l=e[a],s=e[a+1],f=e[a+2];if(typeof s!="function"){if(Lc(s||l)===null)continue;break}var d=la(l);d!==null&&(e.splice(a,3),a-=3,Lo(d,{pending:!0,data:f,method:l.method,action:s},s,f))}}))}function Pr(e){function a(z){return Lu(z,e)}gi!==null&&Lu(gi,e),pi!==null&&Lu(pi,e),yi!==null&&Lu(yi,e),Zr.forEach(a),Kr.forEach(a);for(var l=0;l<mi.length;l++){var s=mi[l];s.blockedOn===e&&(s.blockedOn=null)}for(;0<mi.length&&(l=mi[0],l.blockedOn===null);)Xg(l),l.blockedOn===null&&mi.shift();if(l=(e.ownerDocument||e).$$reactFormReplay,l!=null)for(s=0;s<l.length;s+=3){var f=l[s],d=l[s+1],b=f[Kt]||null;if(typeof d=="function")b||$g(l);else if(b){var w=null;if(d&&d.hasAttribute("formAction")){if(f=d,b=d[Kt]||null)w=b.formAction;else if(Lc(f)!==null)continue}else w=b.action;typeof w=="function"?l[s+1]=w:(l.splice(s,3),s-=3),$g(l)}}}function Gc(e){this._internalRoot=e}Gu.prototype.render=Gc.prototype.render=function(e){var a=this._internalRoot;if(a===null)throw Error(u(409));var l=a.current,s=Ue();Lg(l,s,e,a,null,null)},Gu.prototype.unmount=Gc.prototype.unmount=function(){var e=this._internalRoot;if(e!==null){this._internalRoot=null;var a=e.containerInfo;Lg(e.current,2,null,e,null,null),wu(),a[oe]=null}};function Gu(e){this._internalRoot=e}Gu.prototype.unstable_scheduleHydration=function(e){if(e){var a=ie();e={blockedOn:null,target:e,priority:a};for(var l=0;l<mi.length&&a!==0&&a<mi[l].priority;l++);mi.splice(l,0,e),l===0&&Xg(e)}};var Zg=i.version;if(Zg!=="19.1.1")throw Error(u(527,Zg,"19.1.1"));Z.findDOMNode=function(e){var a=e._reactInternals;if(a===void 0)throw typeof e.render=="function"?Error(u(188)):(e=Object.keys(e).join(","),Error(u(268,e)));return e=y(a),e=e!==null?p(e):null,e=e===null?null:e.stateNode,e};var fb={bundleType:0,version:"19.1.1",rendererPackageName:"react-dom",currentDispatcherRef:N,reconcilerVersion:"19.1.1"};if(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__<"u"){var Qu=__REACT_DEVTOOLS_GLOBAL_HOOK__;if(!Qu.isDisabled&&Qu.supportsFiber)try{En=Qu.inject(fb),se=Qu}catch{}}return Wr.createRoot=function(e,a){if(!o(e))throw Error(u(299));var l=!1,s="",f=o0,d=c0,b=f0,w=null;return a!=null&&(a.unstable_strictMode===!0&&(l=!0),a.identifierPrefix!==void 0&&(s=a.identifierPrefix),a.onUncaughtError!==void 0&&(f=a.onUncaughtError),a.onCaughtError!==void 0&&(d=a.onCaughtError),a.onRecoverableError!==void 0&&(b=a.onRecoverableError),a.unstable_transitionCallbacks!==void 0&&(w=a.unstable_transitionCallbacks)),a=qg(e,1,!1,null,null,l,s,f,d,b,w,null),e[oe]=a.current,Sc(e),new Gc(a)},Wr.hydrateRoot=function(e,a,l){if(!o(e))throw Error(u(299));var s=!1,f="",d=o0,b=c0,w=f0,z=null,Y=null;return l!=null&&(l.unstable_strictMode===!0&&(s=!0),l.identifierPrefix!==void 0&&(f=l.identifierPrefix),l.onUncaughtError!==void 0&&(d=l.onUncaughtError),l.onCaughtError!==void 0&&(b=l.onCaughtError),l.onRecoverableError!==void 0&&(w=l.onRecoverableError),l.unstable_transitionCallbacks!==void 0&&(z=l.unstable_transitionCallbacks),l.formState!==void 0&&(Y=l.formState)),a=qg(e,1,!0,a,l??null,s,f,d,b,w,z,Y),a.context=Hg(null),l=a.current,s=Ue(),s=pt(s),f=ti(s),f.callback=null,ei(l,f,s),l=s,a.current.lanes=l,Mi(a,l),yn(a),e[oe]=a.current,Sc(e),new Gu(a)},Wr.version="19.1.1",Wr}var hp;function t_(){if(hp)return Vc.exports;hp=1;function n(){if(!(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__>"u"||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!="function"))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(n)}catch(i){console.error(i)}}return n(),Vc.exports=Ib(),Vc.exports}var e_=t_();/**
|
|
50
|
-
* @license lucide-react v0.525.0 - ISC
|
|
51
|
-
*
|
|
52
|
-
* This source code is licensed under the ISC license.
|
|
53
|
-
* See the LICENSE file in the root directory of this source tree.
|
|
54
|
-
*/const n_=n=>n.replace(/([a-z0-9])([A-Z])/g,"$1-$2").toLowerCase(),i_=n=>n.replace(/^([A-Z])|[\s-_]+(\w)/g,(i,r,u)=>u?u.toUpperCase():r.toLowerCase()),dp=n=>{const i=i_(n);return i.charAt(0).toUpperCase()+i.slice(1)},Vy=(...n)=>n.filter((i,r,u)=>!!i&&i.trim()!==""&&u.indexOf(i)===r).join(" ").trim(),a_=n=>{for(const i in n)if(i.startsWith("aria-")||i==="role"||i==="title")return!0};/**
|
|
55
|
-
* @license lucide-react v0.525.0 - ISC
|
|
56
|
-
*
|
|
57
|
-
* This source code is licensed under the ISC license.
|
|
58
|
-
* See the LICENSE file in the root directory of this source tree.
|
|
59
|
-
*/var r_={xmlns:"http://www.w3.org/2000/svg",width:24,height:24,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:2,strokeLinecap:"round",strokeLinejoin:"round"};/**
|
|
60
|
-
* @license lucide-react v0.525.0 - ISC
|
|
61
|
-
*
|
|
62
|
-
* This source code is licensed under the ISC license.
|
|
63
|
-
* See the LICENSE file in the root directory of this source tree.
|
|
64
|
-
*/const l_=ot.forwardRef(({color:n="currentColor",size:i=24,strokeWidth:r=2,absoluteStrokeWidth:u,className:o="",children:c,iconNode:h,...g},y)=>ot.createElement("svg",{ref:y,...r_,width:i,height:i,stroke:n,strokeWidth:u?Number(r)*24/Number(i):r,className:Vy("lucide",o),...!c&&!a_(g)&&{"aria-hidden":"true"},...g},[...h.map(([p,v])=>ot.createElement(p,v)),...Array.isArray(c)?c:[c]]));/**
|
|
65
|
-
* @license lucide-react v0.525.0 - ISC
|
|
66
|
-
*
|
|
67
|
-
* This source code is licensed under the ISC license.
|
|
68
|
-
* See the LICENSE file in the root directory of this source tree.
|
|
69
|
-
*/const sn=(n,i)=>{const r=ot.forwardRef(({className:u,...o},c)=>ot.createElement(l_,{ref:c,iconNode:i,className:Vy(`lucide-${n_(dp(n))}`,`lucide-${n}`,u),...o}));return r.displayName=dp(n),r};/**
|
|
70
|
-
* @license lucide-react v0.525.0 - ISC
|
|
71
|
-
*
|
|
72
|
-
* This source code is licensed under the ISC license.
|
|
73
|
-
* See the LICENSE file in the root directory of this source tree.
|
|
74
|
-
*/const u_=[["path",{d:"m12 19-7-7 7-7",key:"1l729n"}],["path",{d:"M19 12H5",key:"x3x0zl"}]],s_=sn("arrow-left",u_);/**
|
|
75
|
-
* @license lucide-react v0.525.0 - ISC
|
|
76
|
-
*
|
|
77
|
-
* This source code is licensed under the ISC license.
|
|
78
|
-
* See the LICENSE file in the root directory of this source tree.
|
|
79
|
-
*/const o_=[["path",{d:"M4 19.5v-15A2.5 2.5 0 0 1 6.5 2H19a1 1 0 0 1 1 1v18a1 1 0 0 1-1 1H6.5a1 1 0 0 1 0-5H20",key:"k3hazp"}]],c_=sn("book",o_);/**
|
|
80
|
-
* @license lucide-react v0.525.0 - ISC
|
|
81
|
-
*
|
|
82
|
-
* This source code is licensed under the ISC license.
|
|
83
|
-
* See the LICENSE file in the root directory of this source tree.
|
|
84
|
-
*/const f_=[["path",{d:"M15 2H6a2 2 0 0 0-2 2v16a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V7Z",key:"1rqfz7"}],["path",{d:"M14 2v4a2 2 0 0 0 2 2h4",key:"tnqrlb"}],["path",{d:"M10 9H8",key:"b1mrlr"}],["path",{d:"M16 13H8",key:"t4e002"}],["path",{d:"M16 17H8",key:"z1uh3a"}]],Xu=sn("file-text",f_);/**
|
|
85
|
-
* @license lucide-react v0.525.0 - ISC
|
|
86
|
-
*
|
|
87
|
-
* This source code is licensed under the ISC license.
|
|
88
|
-
* See the LICENSE file in the root directory of this source tree.
|
|
89
|
-
*/const h_=[["path",{d:"M15 2H6a2 2 0 0 0-2 2v16a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V7Z",key:"1rqfz7"}],["path",{d:"M14 2v4a2 2 0 0 0 2 2h4",key:"tnqrlb"}]],Fc=sn("file",h_);/**
|
|
90
|
-
* @license lucide-react v0.525.0 - ISC
|
|
91
|
-
*
|
|
92
|
-
* This source code is licensed under the ISC license.
|
|
93
|
-
* See the LICENSE file in the root directory of this source tree.
|
|
94
|
-
*/const d_=[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"M12 16v-4",key:"1dtifu"}],["path",{d:"M12 8h.01",key:"e9boi3"}]],g_=sn("info",d_);/**
|
|
95
|
-
* @license lucide-react v0.525.0 - ISC
|
|
96
|
-
*
|
|
97
|
-
* This source code is licensed under the ISC license.
|
|
98
|
-
* See the LICENSE file in the root directory of this source tree.
|
|
99
|
-
*/const p_=[["path",{d:"M3 12h.01",key:"nlz23k"}],["path",{d:"M3 18h.01",key:"1tta3j"}],["path",{d:"M3 6h.01",key:"1rqtza"}],["path",{d:"M8 12h13",key:"1za7za"}],["path",{d:"M8 18h13",key:"1lx6n3"}],["path",{d:"M8 6h13",key:"ik3vkj"}]],Pc=sn("list",p_);/**
|
|
100
|
-
* @license lucide-react v0.525.0 - ISC
|
|
101
|
-
*
|
|
102
|
-
* This source code is licensed under the ISC license.
|
|
103
|
-
* See the LICENSE file in the root directory of this source tree.
|
|
104
|
-
*/const y_=[["path",{d:"M12 2v4",key:"3427ic"}],["path",{d:"m16.2 7.8 2.9-2.9",key:"r700ao"}],["path",{d:"M18 12h4",key:"wj9ykh"}],["path",{d:"m16.2 16.2 2.9 2.9",key:"1bxg5t"}],["path",{d:"M12 18v4",key:"jadmvz"}],["path",{d:"m4.9 19.1 2.9-2.9",key:"bwix9q"}],["path",{d:"M2 12h4",key:"j09sii"}],["path",{d:"m4.9 4.9 2.9 2.9",key:"giyufr"}]],Ya=sn("loader",y_);/**
|
|
105
|
-
* @license lucide-react v0.525.0 - ISC
|
|
106
|
-
*
|
|
107
|
-
* This source code is licensed under the ISC license.
|
|
108
|
-
* See the LICENSE file in the root directory of this source tree.
|
|
109
|
-
*/const m_=[["rect",{x:"16",y:"16",width:"6",height:"6",rx:"1",key:"4q2zg0"}],["rect",{x:"2",y:"16",width:"6",height:"6",rx:"1",key:"8cvhb9"}],["rect",{x:"9",y:"2",width:"6",height:"6",rx:"1",key:"1egb70"}],["path",{d:"M5 16v-3a1 1 0 0 1 1-1h12a1 1 0 0 1 1 1v3",key:"1jsf9p"}],["path",{d:"M12 12V8",key:"2874zd"}]],v_=sn("network",m_);/**
|
|
110
|
-
* @license lucide-react v0.525.0 - ISC
|
|
111
|
-
*
|
|
112
|
-
* This source code is licensed under the ISC license.
|
|
113
|
-
* See the LICENSE file in the root directory of this source tree.
|
|
114
|
-
*/const b_=[["path",{d:"m21 21-4.34-4.34",key:"14j7rj"}],["circle",{cx:"11",cy:"11",r:"8",key:"4ej97u"}]],Jc=sn("search",b_);/**
|
|
115
|
-
* @license lucide-react v0.525.0 - ISC
|
|
116
|
-
*
|
|
117
|
-
* This source code is licensed under the ISC license.
|
|
118
|
-
* See the LICENSE file in the root directory of this source tree.
|
|
119
|
-
*/const __=[["path",{d:"M3 6h18",key:"d0wm0j"}],["path",{d:"M19 6v14c0 1-1 2-2 2H7c-1 0-2-1-2-2V6",key:"4alrt4"}],["path",{d:"M8 6V4c0-1 1-2 2-2h4c1 0 2 1 2 2v2",key:"v07s0e"}],["line",{x1:"10",x2:"10",y1:"11",y2:"17",key:"1uufr5"}],["line",{x1:"14",x2:"14",y1:"11",y2:"17",key:"xtxkd"}]],x_=sn("trash-2",__);/**
|
|
120
|
-
* @license lucide-react v0.525.0 - ISC
|
|
121
|
-
*
|
|
122
|
-
* This source code is licensed under the ISC license.
|
|
123
|
-
* See the LICENSE file in the root directory of this source tree.
|
|
124
|
-
*/const w_=[["path",{d:"M12 3v12",key:"1x0j5s"}],["path",{d:"m17 8-5-5-5 5",key:"7q97r8"}],["path",{d:"M21 15v4a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2v-4",key:"ih7n3h"}]],gp=sn("upload",w_);function Wc({children:n,variant:i="default",className:r=""}){const u="inline-flex items-center rounded-full px-2.5 py-0.5 text-xs font-medium",o={default:"bg-primary text-primary-foreground",outline:"border border-input bg-background text-foreground",secondary:"bg-secondary text-secondary-foreground",destructive:"bg-destructive text-destructive-foreground"};return E.jsx("span",{className:`${u} ${o[i]} ${r}`,children:n})}function Zt({children:n,variant:i="default",size:r="default",className:u="",onClick:o,disabled:c=!1,title:h,type:g="button"}){const y="inline-flex items-center justify-center rounded-md font-medium transition-colors focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 disabled:opacity-50 disabled:pointer-events-none",p={default:"bg-primary text-primary-foreground hover:bg-primary/90",outline:"border border-input bg-background hover:bg-accent hover:text-accent-foreground",ghost:"hover:bg-accent hover:text-accent-foreground",destructive:"bg-destructive text-destructive-foreground hover:bg-destructive/90"},v={default:"h-10 px-4 py-2 text-sm",sm:"h-9 rounded-md px-3 text-xs",lg:"h-11 rounded-md px-8 text-sm",icon:"h-10 w-10 text-xs"};return E.jsx("button",{type:g,className:`${y} ${p[i]} ${v[r]} ${u}`,onClick:o,disabled:c,title:h,children:n})}function Ic({type:n="text",placeholder:i,value:r,onChange:u,className:o="",disabled:c=!1,ref:h,multiple:g,accept:y,...p}){return E.jsx("input",{type:n,placeholder:i,value:r,onChange:u,disabled:c,multiple:g,accept:y,ref:h,className:`flex h-10 w-full rounded-md border border-input bg-background px-3 py-2 text-sm ring-offset-background file:border-0 file:bg-transparent file:text-sm file:font-medium placeholder:text-muted-foreground focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 disabled:cursor-not-allowed disabled:opacity-50 ${o}`,...p})}function S_(n,i){var r=n==null?null:typeof Symbol<"u"&&n[Symbol.iterator]||n["@@iterator"];if(r!=null){var u,o,c,h,g=[],y=!0,p=!1;try{if(c=(r=r.call(n)).next,i===0){if(Object(r)!==r)return;y=!1}else for(;!(y=(u=c.call(r)).done)&&(g.push(u.value),g.length!==i);y=!0);}catch(v){p=!0,o=v}finally{try{if(!y&&r.return!=null&&(h=r.return(),Object(h)!==h))return}finally{if(p)throw o}}return g}}function A_(n,i,r){return i=R_(i),i in n?Object.defineProperty(n,i,{value:r,enumerable:!0,configurable:!0,writable:!0}):n[i]=r,n}function pp(n,i){return O_(n)||S_(n,i)||$y(n,i)||N_()}function E_(n){return T_(n)||M_(n)||$y(n)||C_()}function T_(n){if(Array.isArray(n))return bf(n)}function O_(n){if(Array.isArray(n))return n}function M_(n){if(typeof Symbol<"u"&&n[Symbol.iterator]!=null||n["@@iterator"]!=null)return Array.from(n)}function $y(n,i){if(n){if(typeof n=="string")return bf(n,i);var r=Object.prototype.toString.call(n).slice(8,-1);if(r==="Object"&&n.constructor&&(r=n.constructor.name),r==="Map"||r==="Set")return Array.from(n);if(r==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return bf(n,i)}}function bf(n,i){(i==null||i>n.length)&&(i=n.length);for(var r=0,u=new Array(i);r<i;r++)u[r]=n[r];return u}function C_(){throw new TypeError(`Invalid attempt to spread non-iterable instance.
|
|
125
|
-
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function N_(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
|
|
126
|
-
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function z_(n,i){if(typeof n!="object"||n===null)return n;var r=n[Symbol.toPrimitive];if(r!==void 0){var u=r.call(n,i);if(typeof u!="object")return u;throw new TypeError("@@toPrimitive must return a primitive value.")}return(i==="string"?String:Number)(n)}function R_(n){var i=z_(n,"string");return typeof i=="symbol"?i:String(i)}var D_=function(i,r){var u=new Set(r);return Object.assign.apply(Object,[{}].concat(E_(Object.entries(i).filter(function(o){var c=pp(o,1),h=c[0];return!u.has(h)}).map(function(o){var c=pp(o,2),h=c[0],g=c[1];return A_({},h,g)}))))};function _f(n,i){(i==null||i>n.length)&&(i=n.length);for(var r=0,u=Array(i);r<i;r++)u[r]=n[r];return u}function j_(n){if(Array.isArray(n))return n}function k_(n){if(Array.isArray(n))return _f(n)}function U_(n){if(typeof Symbol<"u"&&n[Symbol.iterator]!=null||n["@@iterator"]!=null)return Array.from(n)}function q_(n,i){var r=n==null?null:typeof Symbol<"u"&&n[Symbol.iterator]||n["@@iterator"];if(r!=null){var u,o,c,h,g=[],y=!0,p=!1;try{if(c=(r=r.call(n)).next,i!==0)for(;!(y=(u=c.call(r)).done)&&(g.push(u.value),g.length!==i);y=!0);}catch(v){p=!0,o=v}finally{try{if(!y&&r.return!=null&&(h=r.return(),Object(h)!==h))return}finally{if(p)throw o}}return g}}function H_(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
|
|
127
|
-
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function L_(){throw new TypeError(`Invalid attempt to spread non-iterable instance.
|
|
128
|
-
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function B_(n,i){return j_(n)||q_(n,i)||Zy(n,i)||H_()}function yp(n){return k_(n)||U_(n)||Zy(n)||L_()}function Zy(n,i){if(n){if(typeof n=="string")return _f(n,i);var r={}.toString.call(n).slice(8,-1);return r==="Object"&&n.constructor&&(r=n.constructor.name),r==="Map"||r==="Set"?Array.from(n):r==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?_f(n,i):void 0}}function G_(n){var i=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},r=i.wrapperElementType,u=r===void 0?"div":r,o=i.nodeMapper,c=o===void 0?function(v){return v}:o,h=i.methodNames,g=h===void 0?[]:h,y=i.initPropNames,p=y===void 0?[]:y;return ot.forwardRef(function(v,m){var _=ot.useRef(),x=ot.useMemo(function(){var O=Object.fromEntries(p.filter(function(S){return v.hasOwnProperty(S)}).map(function(S){return[S,v[S]]}));return n(O)},[]);mp(function(){x(c(_.current))},ot.useLayoutEffect),mp(function(){return x._destructor instanceof Function?x._destructor:void 0});var A=ot.useCallback(function(O){for(var S=arguments.length,j=new Array(S>1?S-1:0),H=1;H<S;H++)j[H-1]=arguments[H];return x[O]instanceof Function?x[O].apply(x,j):void 0},[x]),M=ot.useRef({});return Object.keys(D_(v,[].concat(yp(g),yp(p)))).filter(function(O){return M.current[O]!==v[O]}).forEach(function(O){return A(O,v[O])}),M.current=v,ot.useImperativeHandle(m,function(){return Object.fromEntries(g.map(function(O){return[O,function(){for(var S=arguments.length,j=new Array(S),H=0;H<S;H++)j[H]=arguments[H];return A.apply(void 0,[O].concat(j))}]}))},[A]),Vf.createElement(u,{ref:_})})}function mp(n){var i=arguments.length>1&&arguments[1]!==void 0?arguments[1]:ot.useEffect,r=ot.useRef(),u=ot.useRef(!1),o=ot.useRef(!1),c=ot.useState(0),h=B_(c,2);h[0];var g=h[1];u.current&&(o.current=!0),i(function(){return u.current||(r.current=n(),u.current=!0),g(function(y){return y+1}),function(){o.current&&r.current&&r.current()}},[])}var xf="http://www.w3.org/1999/xhtml";const vp={svg:"http://www.w3.org/2000/svg",xhtml:xf,xlink:"http://www.w3.org/1999/xlink",xml:"http://www.w3.org/XML/1998/namespace",xmlns:"http://www.w3.org/2000/xmlns/"};function vs(n){var i=n+="",r=i.indexOf(":");return r>=0&&(i=n.slice(0,r))!=="xmlns"&&(n=n.slice(r+1)),vp.hasOwnProperty(i)?{space:vp[i],local:n}:n}function Q_(n){return function(){var i=this.ownerDocument,r=this.namespaceURI;return r===xf&&i.documentElement.namespaceURI===xf?i.createElement(n):i.createElementNS(r,n)}}function Y_(n){return function(){return this.ownerDocument.createElementNS(n.space,n.local)}}function Ky(n){var i=vs(n);return(i.local?Y_:Q_)(i)}function X_(){}function $f(n){return n==null?X_:function(){return this.querySelector(n)}}function V_(n){typeof n!="function"&&(n=$f(n));for(var i=this._groups,r=i.length,u=new Array(r),o=0;o<r;++o)for(var c=i[o],h=c.length,g=u[o]=new Array(h),y,p,v=0;v<h;++v)(y=c[v])&&(p=n.call(y,y.__data__,v,c))&&("__data__"in y&&(p.__data__=y.__data__),g[v]=p);return new Le(u,this._parents)}function $_(n){return n==null?[]:Array.isArray(n)?n:Array.from(n)}function Z_(){return[]}function Fy(n){return n==null?Z_:function(){return this.querySelectorAll(n)}}function K_(n){return function(){return $_(n.apply(this,arguments))}}function F_(n){typeof n=="function"?n=K_(n):n=Fy(n);for(var i=this._groups,r=i.length,u=[],o=[],c=0;c<r;++c)for(var h=i[c],g=h.length,y,p=0;p<g;++p)(y=h[p])&&(u.push(n.call(y,y.__data__,p,h)),o.push(y));return new Le(u,o)}function Py(n){return function(){return this.matches(n)}}function Jy(n){return function(i){return i.matches(n)}}var P_=Array.prototype.find;function J_(n){return function(){return P_.call(this.children,n)}}function W_(){return this.firstElementChild}function I_(n){return this.select(n==null?W_:J_(typeof n=="function"?n:Jy(n)))}var tx=Array.prototype.filter;function ex(){return Array.from(this.children)}function nx(n){return function(){return tx.call(this.children,n)}}function ix(n){return this.selectAll(n==null?ex:nx(typeof n=="function"?n:Jy(n)))}function ax(n){typeof n!="function"&&(n=Py(n));for(var i=this._groups,r=i.length,u=new Array(r),o=0;o<r;++o)for(var c=i[o],h=c.length,g=u[o]=[],y,p=0;p<h;++p)(y=c[p])&&n.call(y,y.__data__,p,c)&&g.push(y);return new Le(u,this._parents)}function Wy(n){return new Array(n.length)}function rx(){return new Le(this._enter||this._groups.map(Wy),this._parents)}function rs(n,i){this.ownerDocument=n.ownerDocument,this.namespaceURI=n.namespaceURI,this._next=null,this._parent=n,this.__data__=i}rs.prototype={constructor:rs,appendChild:function(n){return this._parent.insertBefore(n,this._next)},insertBefore:function(n,i){return this._parent.insertBefore(n,i)},querySelector:function(n){return this._parent.querySelector(n)},querySelectorAll:function(n){return this._parent.querySelectorAll(n)}};function lx(n){return function(){return n}}function ux(n,i,r,u,o,c){for(var h=0,g,y=i.length,p=c.length;h<p;++h)(g=i[h])?(g.__data__=c[h],u[h]=g):r[h]=new rs(n,c[h]);for(;h<y;++h)(g=i[h])&&(o[h]=g)}function sx(n,i,r,u,o,c,h){var g,y,p=new Map,v=i.length,m=c.length,_=new Array(v),x;for(g=0;g<v;++g)(y=i[g])&&(_[g]=x=h.call(y,y.__data__,g,i)+"",p.has(x)?o[g]=y:p.set(x,y));for(g=0;g<m;++g)x=h.call(n,c[g],g,c)+"",(y=p.get(x))?(u[g]=y,y.__data__=c[g],p.delete(x)):r[g]=new rs(n,c[g]);for(g=0;g<v;++g)(y=i[g])&&p.get(_[g])===y&&(o[g]=y)}function ox(n){return n.__data__}function cx(n,i){if(!arguments.length)return Array.from(this,ox);var r=i?sx:ux,u=this._parents,o=this._groups;typeof n!="function"&&(n=lx(n));for(var c=o.length,h=new Array(c),g=new Array(c),y=new Array(c),p=0;p<c;++p){var v=u[p],m=o[p],_=m.length,x=fx(n.call(v,v&&v.__data__,p,u)),A=x.length,M=g[p]=new Array(A),O=h[p]=new Array(A),S=y[p]=new Array(_);r(v,m,M,O,S,x,i);for(var j=0,H=0,R,C;j<A;++j)if(R=M[j]){for(j>=H&&(H=j+1);!(C=O[H])&&++H<A;);R._next=C||null}}return h=new Le(h,u),h._enter=g,h._exit=y,h}function fx(n){return typeof n=="object"&&"length"in n?n:Array.from(n)}function hx(){return new Le(this._exit||this._groups.map(Wy),this._parents)}function dx(n,i,r){var u=this.enter(),o=this,c=this.exit();return typeof n=="function"?(u=n(u),u&&(u=u.selection())):u=u.append(n+""),i!=null&&(o=i(o),o&&(o=o.selection())),r==null?c.remove():r(c),u&&o?u.merge(o).order():o}function gx(n){for(var i=n.selection?n.selection():n,r=this._groups,u=i._groups,o=r.length,c=u.length,h=Math.min(o,c),g=new Array(o),y=0;y<h;++y)for(var p=r[y],v=u[y],m=p.length,_=g[y]=new Array(m),x,A=0;A<m;++A)(x=p[A]||v[A])&&(_[A]=x);for(;y<o;++y)g[y]=r[y];return new Le(g,this._parents)}function px(){for(var n=this._groups,i=-1,r=n.length;++i<r;)for(var u=n[i],o=u.length-1,c=u[o],h;--o>=0;)(h=u[o])&&(c&&h.compareDocumentPosition(c)^4&&c.parentNode.insertBefore(h,c),c=h);return this}function yx(n){n||(n=mx);function i(m,_){return m&&_?n(m.__data__,_.__data__):!m-!_}for(var r=this._groups,u=r.length,o=new Array(u),c=0;c<u;++c){for(var h=r[c],g=h.length,y=o[c]=new Array(g),p,v=0;v<g;++v)(p=h[v])&&(y[v]=p);y.sort(i)}return new Le(o,this._parents).order()}function mx(n,i){return n<i?-1:n>i?1:n>=i?0:NaN}function vx(){var n=arguments[0];return arguments[0]=this,n.apply(null,arguments),this}function bx(){return Array.from(this)}function _x(){for(var n=this._groups,i=0,r=n.length;i<r;++i)for(var u=n[i],o=0,c=u.length;o<c;++o){var h=u[o];if(h)return h}return null}function xx(){let n=0;for(const i of this)++n;return n}function wx(){return!this.node()}function Sx(n){for(var i=this._groups,r=0,u=i.length;r<u;++r)for(var o=i[r],c=0,h=o.length,g;c<h;++c)(g=o[c])&&n.call(g,g.__data__,c,o);return this}function Ax(n){return function(){this.removeAttribute(n)}}function Ex(n){return function(){this.removeAttributeNS(n.space,n.local)}}function Tx(n,i){return function(){this.setAttribute(n,i)}}function Ox(n,i){return function(){this.setAttributeNS(n.space,n.local,i)}}function Mx(n,i){return function(){var r=i.apply(this,arguments);r==null?this.removeAttribute(n):this.setAttribute(n,r)}}function Cx(n,i){return function(){var r=i.apply(this,arguments);r==null?this.removeAttributeNS(n.space,n.local):this.setAttributeNS(n.space,n.local,r)}}function Nx(n,i){var r=vs(n);if(arguments.length<2){var u=this.node();return r.local?u.getAttributeNS(r.space,r.local):u.getAttribute(r)}return this.each((i==null?r.local?Ex:Ax:typeof i=="function"?r.local?Cx:Mx:r.local?Ox:Tx)(r,i))}function Iy(n){return n.ownerDocument&&n.ownerDocument.defaultView||n.document&&n||n.defaultView}function zx(n){return function(){this.style.removeProperty(n)}}function Rx(n,i,r){return function(){this.style.setProperty(n,i,r)}}function Dx(n,i,r){return function(){var u=i.apply(this,arguments);u==null?this.style.removeProperty(n):this.style.setProperty(n,u,r)}}function jx(n,i,r){return arguments.length>1?this.each((i==null?zx:typeof i=="function"?Dx:Rx)(n,i,r??"")):Ka(this.node(),n)}function Ka(n,i){return n.style.getPropertyValue(i)||Iy(n).getComputedStyle(n,null).getPropertyValue(i)}function kx(n){return function(){delete this[n]}}function Ux(n,i){return function(){this[n]=i}}function qx(n,i){return function(){var r=i.apply(this,arguments);r==null?delete this[n]:this[n]=r}}function Hx(n,i){return arguments.length>1?this.each((i==null?kx:typeof i=="function"?qx:Ux)(n,i)):this.node()[n]}function tm(n){return n.trim().split(/^|\s+/)}function Zf(n){return n.classList||new em(n)}function em(n){this._node=n,this._names=tm(n.getAttribute("class")||"")}em.prototype={add:function(n){var i=this._names.indexOf(n);i<0&&(this._names.push(n),this._node.setAttribute("class",this._names.join(" ")))},remove:function(n){var i=this._names.indexOf(n);i>=0&&(this._names.splice(i,1),this._node.setAttribute("class",this._names.join(" ")))},contains:function(n){return this._names.indexOf(n)>=0}};function nm(n,i){for(var r=Zf(n),u=-1,o=i.length;++u<o;)r.add(i[u])}function im(n,i){for(var r=Zf(n),u=-1,o=i.length;++u<o;)r.remove(i[u])}function Lx(n){return function(){nm(this,n)}}function Bx(n){return function(){im(this,n)}}function Gx(n,i){return function(){(i.apply(this,arguments)?nm:im)(this,n)}}function Qx(n,i){var r=tm(n+"");if(arguments.length<2){for(var u=Zf(this.node()),o=-1,c=r.length;++o<c;)if(!u.contains(r[o]))return!1;return!0}return this.each((typeof i=="function"?Gx:i?Lx:Bx)(r,i))}function Yx(){this.textContent=""}function Xx(n){return function(){this.textContent=n}}function Vx(n){return function(){var i=n.apply(this,arguments);this.textContent=i??""}}function $x(n){return arguments.length?this.each(n==null?Yx:(typeof n=="function"?Vx:Xx)(n)):this.node().textContent}function Zx(){this.innerHTML=""}function Kx(n){return function(){this.innerHTML=n}}function Fx(n){return function(){var i=n.apply(this,arguments);this.innerHTML=i??""}}function Px(n){return arguments.length?this.each(n==null?Zx:(typeof n=="function"?Fx:Kx)(n)):this.node().innerHTML}function Jx(){this.nextSibling&&this.parentNode.appendChild(this)}function Wx(){return this.each(Jx)}function Ix(){this.previousSibling&&this.parentNode.insertBefore(this,this.parentNode.firstChild)}function t2(){return this.each(Ix)}function e2(n){var i=typeof n=="function"?n:Ky(n);return this.select(function(){return this.appendChild(i.apply(this,arguments))})}function n2(){return null}function i2(n,i){var r=typeof n=="function"?n:Ky(n),u=i==null?n2:typeof i=="function"?i:$f(i);return this.select(function(){return this.insertBefore(r.apply(this,arguments),u.apply(this,arguments)||null)})}function a2(){var n=this.parentNode;n&&n.removeChild(this)}function r2(){return this.each(a2)}function l2(){var n=this.cloneNode(!1),i=this.parentNode;return i?i.insertBefore(n,this.nextSibling):n}function u2(){var n=this.cloneNode(!0),i=this.parentNode;return i?i.insertBefore(n,this.nextSibling):n}function s2(n){return this.select(n?u2:l2)}function o2(n){return arguments.length?this.property("__data__",n):this.node().__data__}function c2(n){return function(i){n.call(this,i,this.__data__)}}function f2(n){return n.trim().split(/^|\s+/).map(function(i){var r="",u=i.indexOf(".");return u>=0&&(r=i.slice(u+1),i=i.slice(0,u)),{type:i,name:r}})}function h2(n){return function(){var i=this.__on;if(i){for(var r=0,u=-1,o=i.length,c;r<o;++r)c=i[r],(!n.type||c.type===n.type)&&c.name===n.name?this.removeEventListener(c.type,c.listener,c.options):i[++u]=c;++u?i.length=u:delete this.__on}}}function d2(n,i,r){return function(){var u=this.__on,o,c=c2(i);if(u){for(var h=0,g=u.length;h<g;++h)if((o=u[h]).type===n.type&&o.name===n.name){this.removeEventListener(o.type,o.listener,o.options),this.addEventListener(o.type,o.listener=c,o.options=r),o.value=i;return}}this.addEventListener(n.type,c,r),o={type:n.type,name:n.name,value:i,listener:c,options:r},u?u.push(o):this.__on=[o]}}function g2(n,i,r){var u=f2(n+""),o,c=u.length,h;if(arguments.length<2){var g=this.node().__on;if(g){for(var y=0,p=g.length,v;y<p;++y)for(o=0,v=g[y];o<c;++o)if((h=u[o]).type===v.type&&h.name===v.name)return v.value}return}for(g=i?d2:h2,o=0;o<c;++o)this.each(g(u[o],i,r));return this}function am(n,i,r){var u=Iy(n),o=u.CustomEvent;typeof o=="function"?o=new o(i,r):(o=u.document.createEvent("Event"),r?(o.initEvent(i,r.bubbles,r.cancelable),o.detail=r.detail):o.initEvent(i,!1,!1)),n.dispatchEvent(o)}function p2(n,i){return function(){return am(this,n,i)}}function y2(n,i){return function(){return am(this,n,i.apply(this,arguments))}}function m2(n,i){return this.each((typeof i=="function"?y2:p2)(n,i))}function*v2(){for(var n=this._groups,i=0,r=n.length;i<r;++i)for(var u=n[i],o=0,c=u.length,h;o<c;++o)(h=u[o])&&(yield h)}var rm=[null];function Le(n,i){this._groups=n,this._parents=i}function Al(){return new Le([[document.documentElement]],rm)}function b2(){return this}Le.prototype=Al.prototype={constructor:Le,select:V_,selectAll:F_,selectChild:I_,selectChildren:ix,filter:ax,data:cx,enter:rx,exit:hx,join:dx,merge:gx,selection:b2,order:px,sort:yx,call:vx,nodes:bx,node:_x,size:xx,empty:wx,each:Sx,attr:Nx,style:jx,property:Hx,classed:Qx,text:$x,html:Px,raise:Wx,lower:t2,append:e2,insert:i2,remove:r2,clone:s2,datum:o2,on:g2,dispatch:m2,[Symbol.iterator]:v2};function Ie(n){return typeof n=="string"?new Le([[document.querySelector(n)]],[document.documentElement]):new Le([[n]],rm)}function _2(n){let i;for(;i=n.sourceEvent;)n=i;return n}function vn(n,i){if(n=_2(n),i===void 0&&(i=n.currentTarget),i){var r=i.ownerSVGElement||i;if(r.createSVGPoint){var u=r.createSVGPoint();return u.x=n.clientX,u.y=n.clientY,u=u.matrixTransform(i.getScreenCTM().inverse()),[u.x,u.y]}if(i.getBoundingClientRect){var o=i.getBoundingClientRect();return[n.clientX-o.left-i.clientLeft,n.clientY-o.top-i.clientTop]}}return[n.pageX,n.pageY]}var x2={value:()=>{}};function El(){for(var n=0,i=arguments.length,r={},u;n<i;++n){if(!(u=arguments[n]+"")||u in r||/[\s.]/.test(u))throw new Error("illegal type: "+u);r[u]=[]}return new Wu(r)}function Wu(n){this._=n}function w2(n,i){return n.trim().split(/^|\s+/).map(function(r){var u="",o=r.indexOf(".");if(o>=0&&(u=r.slice(o+1),r=r.slice(0,o)),r&&!i.hasOwnProperty(r))throw new Error("unknown type: "+r);return{type:r,name:u}})}Wu.prototype=El.prototype={constructor:Wu,on:function(n,i){var r=this._,u=w2(n+"",r),o,c=-1,h=u.length;if(arguments.length<2){for(;++c<h;)if((o=(n=u[c]).type)&&(o=S2(r[o],n.name)))return o;return}if(i!=null&&typeof i!="function")throw new Error("invalid callback: "+i);for(;++c<h;)if(o=(n=u[c]).type)r[o]=bp(r[o],n.name,i);else if(i==null)for(o in r)r[o]=bp(r[o],n.name,null);return this},copy:function(){var n={},i=this._;for(var r in i)n[r]=i[r].slice();return new Wu(n)},call:function(n,i){if((o=arguments.length-2)>0)for(var r=new Array(o),u=0,o,c;u<o;++u)r[u]=arguments[u+2];if(!this._.hasOwnProperty(n))throw new Error("unknown type: "+n);for(c=this._[n],u=0,o=c.length;u<o;++u)c[u].value.apply(i,r)},apply:function(n,i,r){if(!this._.hasOwnProperty(n))throw new Error("unknown type: "+n);for(var u=this._[n],o=0,c=u.length;o<c;++o)u[o].value.apply(i,r)}};function S2(n,i){for(var r=0,u=n.length,o;r<u;++r)if((o=n[r]).name===i)return o.value}function bp(n,i,r){for(var u=0,o=n.length;u<o;++u)if(n[u].name===i){n[u]=x2,n=n.slice(0,u).concat(n.slice(u+1));break}return r!=null&&n.push({name:i,value:r}),n}const A2={passive:!1},yl={capture:!0,passive:!1};function tf(n){n.stopImmediatePropagation()}function $a(n){n.preventDefault(),n.stopImmediatePropagation()}function lm(n){var i=n.document.documentElement,r=Ie(n).on("dragstart.drag",$a,yl);"onselectstart"in i?r.on("selectstart.drag",$a,yl):(i.__noselect=i.style.MozUserSelect,i.style.MozUserSelect="none")}function um(n,i){var r=n.document.documentElement,u=Ie(n).on("dragstart.drag",null);i&&(u.on("click.drag",$a,yl),setTimeout(function(){u.on("click.drag",null)},0)),"onselectstart"in r?u.on("selectstart.drag",null):(r.style.MozUserSelect=r.__noselect,delete r.__noselect)}const Vu=n=>()=>n;function wf(n,{sourceEvent:i,subject:r,target:u,identifier:o,active:c,x:h,y:g,dx:y,dy:p,dispatch:v}){Object.defineProperties(this,{type:{value:n,enumerable:!0,configurable:!0},sourceEvent:{value:i,enumerable:!0,configurable:!0},subject:{value:r,enumerable:!0,configurable:!0},target:{value:u,enumerable:!0,configurable:!0},identifier:{value:o,enumerable:!0,configurable:!0},active:{value:c,enumerable:!0,configurable:!0},x:{value:h,enumerable:!0,configurable:!0},y:{value:g,enumerable:!0,configurable:!0},dx:{value:y,enumerable:!0,configurable:!0},dy:{value:p,enumerable:!0,configurable:!0},_:{value:v}})}wf.prototype.on=function(){var n=this._.on.apply(this._,arguments);return n===this._?this:n};function E2(n){return!n.ctrlKey&&!n.button}function T2(){return this.parentNode}function O2(n,i){return i??{x:n.x,y:n.y}}function M2(){return navigator.maxTouchPoints||"ontouchstart"in this}function C2(){var n=E2,i=T2,r=O2,u=M2,o={},c=El("start","drag","end"),h=0,g,y,p,v,m=0;function _(R){R.on("mousedown.drag",x).filter(u).on("touchstart.drag",O).on("touchmove.drag",S,A2).on("touchend.drag touchcancel.drag",j).style("touch-action","none").style("-webkit-tap-highlight-color","rgba(0,0,0,0)")}function x(R,C){if(!(v||!n.call(this,R,C))){var q=H(this,i.call(this,R,C),R,C,"mouse");q&&(Ie(R.view).on("mousemove.drag",A,yl).on("mouseup.drag",M,yl),lm(R.view),tf(R),p=!1,g=R.clientX,y=R.clientY,q("start",R))}}function A(R){if($a(R),!p){var C=R.clientX-g,q=R.clientY-y;p=C*C+q*q>m}o.mouse("drag",R)}function M(R){Ie(R.view).on("mousemove.drag mouseup.drag",null),um(R.view,p),$a(R),o.mouse("end",R)}function O(R,C){if(n.call(this,R,C)){var q=R.changedTouches,U=i.call(this,R,C),Q=q.length,tt,F;for(tt=0;tt<Q;++tt)(F=H(this,U,R,C,q[tt].identifier,q[tt]))&&(tf(R),F("start",R,q[tt]))}}function S(R){var C=R.changedTouches,q=C.length,U,Q;for(U=0;U<q;++U)(Q=o[C[U].identifier])&&($a(R),Q("drag",R,C[U]))}function j(R){var C=R.changedTouches,q=C.length,U,Q;for(v&&clearTimeout(v),v=setTimeout(function(){v=null},500),U=0;U<q;++U)(Q=o[C[U].identifier])&&(tf(R),Q("end",R,C[U]))}function H(R,C,q,U,Q,tt){var F=c.copy(),K=vn(tt||q,C),it,ct,L;if((L=r.call(R,new wf("beforestart",{sourceEvent:q,target:_,identifier:Q,active:h,x:K[0],y:K[1],dx:0,dy:0,dispatch:F}),U))!=null)return it=L.x-K[0]||0,ct=L.y-K[1]||0,function J(N,Z,et){var ut=K,T;switch(N){case"start":o[Q]=J,T=h++;break;case"end":delete o[Q],--h;case"drag":K=vn(et||Z,C),T=h;break}F.call(N,R,new wf(N,{sourceEvent:Z,subject:L,target:_,identifier:Q,active:T,x:K[0]+it,y:K[1]+ct,dx:K[0]-ut[0],dy:K[1]-ut[1],dispatch:F}),U)}}return _.filter=function(R){return arguments.length?(n=typeof R=="function"?R:Vu(!!R),_):n},_.container=function(R){return arguments.length?(i=typeof R=="function"?R:Vu(R),_):i},_.subject=function(R){return arguments.length?(r=typeof R=="function"?R:Vu(R),_):r},_.touchable=function(R){return arguments.length?(u=typeof R=="function"?R:Vu(!!R),_):u},_.on=function(){var R=c.on.apply(c,arguments);return R===c?_:R},_.clickDistance=function(R){return arguments.length?(m=(R=+R)*R,_):Math.sqrt(m)},_}function Kf(n,i,r){n.prototype=i.prototype=r,r.constructor=n}function sm(n,i){var r=Object.create(n.prototype);for(var u in i)r[u]=i[u];return r}function Tl(){}var ml=.7,ls=1/ml,Za="\\s*([+-]?\\d+)\\s*",vl="\\s*([+-]?(?:\\d*\\.)?\\d+(?:[eE][+-]?\\d+)?)\\s*",_n="\\s*([+-]?(?:\\d*\\.)?\\d+(?:[eE][+-]?\\d+)?)%\\s*",N2=/^#([0-9a-f]{3,8})$/,z2=new RegExp(`^rgb\\(${Za},${Za},${Za}\\)$`),R2=new RegExp(`^rgb\\(${_n},${_n},${_n}\\)$`),D2=new RegExp(`^rgba\\(${Za},${Za},${Za},${vl}\\)$`),j2=new RegExp(`^rgba\\(${_n},${_n},${_n},${vl}\\)$`),k2=new RegExp(`^hsl\\(${vl},${_n},${_n}\\)$`),U2=new RegExp(`^hsla\\(${vl},${_n},${_n},${vl}\\)$`),_p={aliceblue:15792383,antiquewhite:16444375,aqua:65535,aquamarine:8388564,azure:15794175,beige:16119260,bisque:16770244,black:0,blanchedalmond:16772045,blue:255,blueviolet:9055202,brown:10824234,burlywood:14596231,cadetblue:6266528,chartreuse:8388352,chocolate:13789470,coral:16744272,cornflowerblue:6591981,cornsilk:16775388,crimson:14423100,cyan:65535,darkblue:139,darkcyan:35723,darkgoldenrod:12092939,darkgray:11119017,darkgreen:25600,darkgrey:11119017,darkkhaki:12433259,darkmagenta:9109643,darkolivegreen:5597999,darkorange:16747520,darkorchid:10040012,darkred:9109504,darksalmon:15308410,darkseagreen:9419919,darkslateblue:4734347,darkslategray:3100495,darkslategrey:3100495,darkturquoise:52945,darkviolet:9699539,deeppink:16716947,deepskyblue:49151,dimgray:6908265,dimgrey:6908265,dodgerblue:2003199,firebrick:11674146,floralwhite:16775920,forestgreen:2263842,fuchsia:16711935,gainsboro:14474460,ghostwhite:16316671,gold:16766720,goldenrod:14329120,gray:8421504,green:32768,greenyellow:11403055,grey:8421504,honeydew:15794160,hotpink:16738740,indianred:13458524,indigo:4915330,ivory:16777200,khaki:15787660,lavender:15132410,lavenderblush:16773365,lawngreen:8190976,lemonchiffon:16775885,lightblue:11393254,lightcoral:15761536,lightcyan:14745599,lightgoldenrodyellow:16448210,lightgray:13882323,lightgreen:9498256,lightgrey:13882323,lightpink:16758465,lightsalmon:16752762,lightseagreen:2142890,lightskyblue:8900346,lightslategray:7833753,lightslategrey:7833753,lightsteelblue:11584734,lightyellow:16777184,lime:65280,limegreen:3329330,linen:16445670,magenta:16711935,maroon:8388608,mediumaquamarine:6737322,mediumblue:205,mediumorchid:12211667,mediumpurple:9662683,mediumseagreen:3978097,mediumslateblue:8087790,mediumspringgreen:64154,mediumturquoise:4772300,mediumvioletred:13047173,midnightblue:1644912,mintcream:16121850,mistyrose:16770273,moccasin:16770229,navajowhite:16768685,navy:128,oldlace:16643558,olive:8421376,olivedrab:7048739,orange:16753920,orangered:16729344,orchid:14315734,palegoldenrod:15657130,palegreen:10025880,paleturquoise:11529966,palevioletred:14381203,papayawhip:16773077,peachpuff:16767673,peru:13468991,pink:16761035,plum:14524637,powderblue:11591910,purple:8388736,rebeccapurple:6697881,red:16711680,rosybrown:12357519,royalblue:4286945,saddlebrown:9127187,salmon:16416882,sandybrown:16032864,seagreen:3050327,seashell:16774638,sienna:10506797,silver:12632256,skyblue:8900331,slateblue:6970061,slategray:7372944,slategrey:7372944,snow:16775930,springgreen:65407,steelblue:4620980,tan:13808780,teal:32896,thistle:14204888,tomato:16737095,turquoise:4251856,violet:15631086,wheat:16113331,white:16777215,whitesmoke:16119285,yellow:16776960,yellowgreen:10145074};Kf(Tl,bl,{copy(n){return Object.assign(new this.constructor,this,n)},displayable(){return this.rgb().displayable()},hex:xp,formatHex:xp,formatHex8:q2,formatHsl:H2,formatRgb:wp,toString:wp});function xp(){return this.rgb().formatHex()}function q2(){return this.rgb().formatHex8()}function H2(){return om(this).formatHsl()}function wp(){return this.rgb().formatRgb()}function bl(n){var i,r;return n=(n+"").trim().toLowerCase(),(i=N2.exec(n))?(r=i[1].length,i=parseInt(i[1],16),r===6?Sp(i):r===3?new Ce(i>>8&15|i>>4&240,i>>4&15|i&240,(i&15)<<4|i&15,1):r===8?$u(i>>24&255,i>>16&255,i>>8&255,(i&255)/255):r===4?$u(i>>12&15|i>>8&240,i>>8&15|i>>4&240,i>>4&15|i&240,((i&15)<<4|i&15)/255):null):(i=z2.exec(n))?new Ce(i[1],i[2],i[3],1):(i=R2.exec(n))?new Ce(i[1]*255/100,i[2]*255/100,i[3]*255/100,1):(i=D2.exec(n))?$u(i[1],i[2],i[3],i[4]):(i=j2.exec(n))?$u(i[1]*255/100,i[2]*255/100,i[3]*255/100,i[4]):(i=k2.exec(n))?Tp(i[1],i[2]/100,i[3]/100,1):(i=U2.exec(n))?Tp(i[1],i[2]/100,i[3]/100,i[4]):_p.hasOwnProperty(n)?Sp(_p[n]):n==="transparent"?new Ce(NaN,NaN,NaN,0):null}function Sp(n){return new Ce(n>>16&255,n>>8&255,n&255,1)}function $u(n,i,r,u){return u<=0&&(n=i=r=NaN),new Ce(n,i,r,u)}function L2(n){return n instanceof Tl||(n=bl(n)),n?(n=n.rgb(),new Ce(n.r,n.g,n.b,n.opacity)):new Ce}function Sf(n,i,r,u){return arguments.length===1?L2(n):new Ce(n,i,r,u??1)}function Ce(n,i,r,u){this.r=+n,this.g=+i,this.b=+r,this.opacity=+u}Kf(Ce,Sf,sm(Tl,{brighter(n){return n=n==null?ls:Math.pow(ls,n),new Ce(this.r*n,this.g*n,this.b*n,this.opacity)},darker(n){return n=n==null?ml:Math.pow(ml,n),new Ce(this.r*n,this.g*n,this.b*n,this.opacity)},rgb(){return this},clamp(){return new Ce(Pi(this.r),Pi(this.g),Pi(this.b),us(this.opacity))},displayable(){return-.5<=this.r&&this.r<255.5&&-.5<=this.g&&this.g<255.5&&-.5<=this.b&&this.b<255.5&&0<=this.opacity&&this.opacity<=1},hex:Ap,formatHex:Ap,formatHex8:B2,formatRgb:Ep,toString:Ep}));function Ap(){return`#${Fi(this.r)}${Fi(this.g)}${Fi(this.b)}`}function B2(){return`#${Fi(this.r)}${Fi(this.g)}${Fi(this.b)}${Fi((isNaN(this.opacity)?1:this.opacity)*255)}`}function Ep(){const n=us(this.opacity);return`${n===1?"rgb(":"rgba("}${Pi(this.r)}, ${Pi(this.g)}, ${Pi(this.b)}${n===1?")":`, ${n})`}`}function us(n){return isNaN(n)?1:Math.max(0,Math.min(1,n))}function Pi(n){return Math.max(0,Math.min(255,Math.round(n)||0))}function Fi(n){return n=Pi(n),(n<16?"0":"")+n.toString(16)}function Tp(n,i,r,u){return u<=0?n=i=r=NaN:r<=0||r>=1?n=i=NaN:i<=0&&(n=NaN),new ln(n,i,r,u)}function om(n){if(n instanceof ln)return new ln(n.h,n.s,n.l,n.opacity);if(n instanceof Tl||(n=bl(n)),!n)return new ln;if(n instanceof ln)return n;n=n.rgb();var i=n.r/255,r=n.g/255,u=n.b/255,o=Math.min(i,r,u),c=Math.max(i,r,u),h=NaN,g=c-o,y=(c+o)/2;return g?(i===c?h=(r-u)/g+(r<u)*6:r===c?h=(u-i)/g+2:h=(i-r)/g+4,g/=y<.5?c+o:2-c-o,h*=60):g=y>0&&y<1?0:h,new ln(h,g,y,n.opacity)}function G2(n,i,r,u){return arguments.length===1?om(n):new ln(n,i,r,u??1)}function ln(n,i,r,u){this.h=+n,this.s=+i,this.l=+r,this.opacity=+u}Kf(ln,G2,sm(Tl,{brighter(n){return n=n==null?ls:Math.pow(ls,n),new ln(this.h,this.s,this.l*n,this.opacity)},darker(n){return n=n==null?ml:Math.pow(ml,n),new ln(this.h,this.s,this.l*n,this.opacity)},rgb(){var n=this.h%360+(this.h<0)*360,i=isNaN(n)||isNaN(this.s)?0:this.s,r=this.l,u=r+(r<.5?r:1-r)*i,o=2*r-u;return new Ce(ef(n>=240?n-240:n+120,o,u),ef(n,o,u),ef(n<120?n+240:n-120,o,u),this.opacity)},clamp(){return new ln(Op(this.h),Zu(this.s),Zu(this.l),us(this.opacity))},displayable(){return(0<=this.s&&this.s<=1||isNaN(this.s))&&0<=this.l&&this.l<=1&&0<=this.opacity&&this.opacity<=1},formatHsl(){const n=us(this.opacity);return`${n===1?"hsl(":"hsla("}${Op(this.h)}, ${Zu(this.s)*100}%, ${Zu(this.l)*100}%${n===1?")":`, ${n})`}`}}));function Op(n){return n=(n||0)%360,n<0?n+360:n}function Zu(n){return Math.max(0,Math.min(1,n||0))}function ef(n,i,r){return(n<60?i+(r-i)*n/60:n<180?r:n<240?i+(r-i)*(240-n)/60:i)*255}const cm=n=>()=>n;function Q2(n,i){return function(r){return n+r*i}}function Y2(n,i,r){return n=Math.pow(n,r),i=Math.pow(i,r)-n,r=1/r,function(u){return Math.pow(n+u*i,r)}}function X2(n){return(n=+n)==1?fm:function(i,r){return r-i?Y2(i,r,n):cm(isNaN(i)?r:i)}}function fm(n,i){var r=i-n;return r?Q2(n,r):cm(isNaN(n)?i:n)}const Mp=function n(i){var r=X2(i);function u(o,c){var h=r((o=Sf(o)).r,(c=Sf(c)).r),g=r(o.g,c.g),y=r(o.b,c.b),p=fm(o.opacity,c.opacity);return function(v){return o.r=h(v),o.g=g(v),o.b=y(v),o.opacity=p(v),o+""}}return u.gamma=n,u}(1);function xi(n,i){return n=+n,i=+i,function(r){return n*(1-r)+i*r}}var Af=/[-+]?(?:\d+\.?\d*|\.?\d+)(?:[eE][-+]?\d+)?/g,nf=new RegExp(Af.source,"g");function V2(n){return function(){return n}}function $2(n){return function(i){return n(i)+""}}function Z2(n,i){var r=Af.lastIndex=nf.lastIndex=0,u,o,c,h=-1,g=[],y=[];for(n=n+"",i=i+"";(u=Af.exec(n))&&(o=nf.exec(i));)(c=o.index)>r&&(c=i.slice(r,c),g[h]?g[h]+=c:g[++h]=c),(u=u[0])===(o=o[0])?g[h]?g[h]+=o:g[++h]=o:(g[++h]=null,y.push({i:h,x:xi(u,o)})),r=nf.lastIndex;return r<i.length&&(c=i.slice(r),g[h]?g[h]+=c:g[++h]=c),g.length<2?y[0]?$2(y[0].x):V2(i):(i=y.length,function(p){for(var v=0,m;v<i;++v)g[(m=y[v]).i]=m.x(p);return g.join("")})}var Cp=180/Math.PI,Ef={translateX:0,translateY:0,rotate:0,skewX:0,scaleX:1,scaleY:1};function hm(n,i,r,u,o,c){var h,g,y;return(h=Math.sqrt(n*n+i*i))&&(n/=h,i/=h),(y=n*r+i*u)&&(r-=n*y,u-=i*y),(g=Math.sqrt(r*r+u*u))&&(r/=g,u/=g,y/=g),n*u<i*r&&(n=-n,i=-i,y=-y,h=-h),{translateX:o,translateY:c,rotate:Math.atan2(i,n)*Cp,skewX:Math.atan(y)*Cp,scaleX:h,scaleY:g}}var Ku;function K2(n){const i=new(typeof DOMMatrix=="function"?DOMMatrix:WebKitCSSMatrix)(n+"");return i.isIdentity?Ef:hm(i.a,i.b,i.c,i.d,i.e,i.f)}function F2(n){return n==null||(Ku||(Ku=document.createElementNS("http://www.w3.org/2000/svg","g")),Ku.setAttribute("transform",n),!(n=Ku.transform.baseVal.consolidate()))?Ef:(n=n.matrix,hm(n.a,n.b,n.c,n.d,n.e,n.f))}function dm(n,i,r,u){function o(p){return p.length?p.pop()+" ":""}function c(p,v,m,_,x,A){if(p!==m||v!==_){var M=x.push("translate(",null,i,null,r);A.push({i:M-4,x:xi(p,m)},{i:M-2,x:xi(v,_)})}else(m||_)&&x.push("translate("+m+i+_+r)}function h(p,v,m,_){p!==v?(p-v>180?v+=360:v-p>180&&(p+=360),_.push({i:m.push(o(m)+"rotate(",null,u)-2,x:xi(p,v)})):v&&m.push(o(m)+"rotate("+v+u)}function g(p,v,m,_){p!==v?_.push({i:m.push(o(m)+"skewX(",null,u)-2,x:xi(p,v)}):v&&m.push(o(m)+"skewX("+v+u)}function y(p,v,m,_,x,A){if(p!==m||v!==_){var M=x.push(o(x)+"scale(",null,",",null,")");A.push({i:M-4,x:xi(p,m)},{i:M-2,x:xi(v,_)})}else(m!==1||_!==1)&&x.push(o(x)+"scale("+m+","+_+")")}return function(p,v){var m=[],_=[];return p=n(p),v=n(v),c(p.translateX,p.translateY,v.translateX,v.translateY,m,_),h(p.rotate,v.rotate,m,_),g(p.skewX,v.skewX,m,_),y(p.scaleX,p.scaleY,v.scaleX,v.scaleY,m,_),p=v=null,function(x){for(var A=-1,M=_.length,O;++A<M;)m[(O=_[A]).i]=O.x(x);return m.join("")}}}var P2=dm(K2,"px, ","px)","deg)"),J2=dm(F2,", ",")",")"),W2=1e-12;function Np(n){return((n=Math.exp(n))+1/n)/2}function I2(n){return((n=Math.exp(n))-1/n)/2}function tw(n){return((n=Math.exp(2*n))-1)/(n+1)}const ew=function n(i,r,u){function o(c,h){var g=c[0],y=c[1],p=c[2],v=h[0],m=h[1],_=h[2],x=v-g,A=m-y,M=x*x+A*A,O,S;if(M<W2)S=Math.log(_/p)/i,O=function(U){return[g+U*x,y+U*A,p*Math.exp(i*U*S)]};else{var j=Math.sqrt(M),H=(_*_-p*p+u*M)/(2*p*r*j),R=(_*_-p*p-u*M)/(2*_*r*j),C=Math.log(Math.sqrt(H*H+1)-H),q=Math.log(Math.sqrt(R*R+1)-R);S=(q-C)/i,O=function(U){var Q=U*S,tt=Np(C),F=p/(r*j)*(tt*tw(i*Q+C)-I2(C));return[g+F*x,y+F*A,p*tt/Np(i*Q+C)]}}return O.duration=S*1e3*i/Math.SQRT2,O}return o.rho=function(c){var h=Math.max(.001,+c),g=h*h,y=g*g;return n(h,g,y)},o}(Math.SQRT2,2,4);var Fa=0,sl=0,Ir=0,gm=1e3,ss,ol,os=0,ta=0,bs=0,_l=typeof performance=="object"&&performance.now?performance:Date,pm=typeof window=="object"&&window.requestAnimationFrame?window.requestAnimationFrame.bind(window):function(n){setTimeout(n,17)};function Ff(){return ta||(pm(nw),ta=_l.now()+bs)}function nw(){ta=0}function cs(){this._call=this._time=this._next=null}cs.prototype=Pf.prototype={constructor:cs,restart:function(n,i,r){if(typeof n!="function")throw new TypeError("callback is not a function");r=(r==null?Ff():+r)+(i==null?0:+i),!this._next&&ol!==this&&(ol?ol._next=this:ss=this,ol=this),this._call=n,this._time=r,Tf()},stop:function(){this._call&&(this._call=null,this._time=1/0,Tf())}};function Pf(n,i,r){var u=new cs;return u.restart(n,i,r),u}function iw(){Ff(),++Fa;for(var n=ss,i;n;)(i=ta-n._time)>=0&&n._call.call(void 0,i),n=n._next;--Fa}function zp(){ta=(os=_l.now())+bs,Fa=sl=0;try{iw()}finally{Fa=0,rw(),ta=0}}function aw(){var n=_l.now(),i=n-os;i>gm&&(bs-=i,os=n)}function rw(){for(var n,i=ss,r,u=1/0;i;)i._call?(u>i._time&&(u=i._time),n=i,i=i._next):(r=i._next,i._next=null,i=n?n._next=r:ss=r);ol=n,Tf(u)}function Tf(n){if(!Fa){sl&&(sl=clearTimeout(sl));var i=n-ta;i>24?(n<1/0&&(sl=setTimeout(zp,n-_l.now()-bs)),Ir&&(Ir=clearInterval(Ir))):(Ir||(os=_l.now(),Ir=setInterval(aw,gm)),Fa=1,pm(zp))}}function Rp(n,i,r){var u=new cs;return i=i==null?0:+i,u.restart(o=>{u.stop(),n(o+i)},i,r),u}var lw=El("start","end","cancel","interrupt"),uw=[],ym=0,Dp=1,Of=2,Iu=3,jp=4,Mf=5,ts=6;function _s(n,i,r,u,o,c){var h=n.__transition;if(!h)n.__transition={};else if(r in h)return;sw(n,r,{name:i,index:u,group:o,on:lw,tween:uw,time:c.time,delay:c.delay,duration:c.duration,ease:c.ease,timer:null,state:ym})}function Jf(n,i){var r=on(n,i);if(r.state>ym)throw new Error("too late; already scheduled");return r}function wn(n,i){var r=on(n,i);if(r.state>Iu)throw new Error("too late; already running");return r}function on(n,i){var r=n.__transition;if(!r||!(r=r[i]))throw new Error("transition not found");return r}function sw(n,i,r){var u=n.__transition,o;u[i]=r,r.timer=Pf(c,0,r.time);function c(p){r.state=Dp,r.timer.restart(h,r.delay,r.time),r.delay<=p&&h(p-r.delay)}function h(p){var v,m,_,x;if(r.state!==Dp)return y();for(v in u)if(x=u[v],x.name===r.name){if(x.state===Iu)return Rp(h);x.state===jp?(x.state=ts,x.timer.stop(),x.on.call("interrupt",n,n.__data__,x.index,x.group),delete u[v]):+v<i&&(x.state=ts,x.timer.stop(),x.on.call("cancel",n,n.__data__,x.index,x.group),delete u[v])}if(Rp(function(){r.state===Iu&&(r.state=jp,r.timer.restart(g,r.delay,r.time),g(p))}),r.state=Of,r.on.call("start",n,n.__data__,r.index,r.group),r.state===Of){for(r.state=Iu,o=new Array(_=r.tween.length),v=0,m=-1;v<_;++v)(x=r.tween[v].value.call(n,n.__data__,r.index,r.group))&&(o[++m]=x);o.length=m+1}}function g(p){for(var v=p<r.duration?r.ease.call(null,p/r.duration):(r.timer.restart(y),r.state=Mf,1),m=-1,_=o.length;++m<_;)o[m].call(n,v);r.state===Mf&&(r.on.call("end",n,n.__data__,r.index,r.group),y())}function y(){r.state=ts,r.timer.stop(),delete u[i];for(var p in u)return;delete n.__transition}}function es(n,i){var r=n.__transition,u,o,c=!0,h;if(r){i=i==null?null:i+"";for(h in r){if((u=r[h]).name!==i){c=!1;continue}o=u.state>Of&&u.state<Mf,u.state=ts,u.timer.stop(),u.on.call(o?"interrupt":"cancel",n,n.__data__,u.index,u.group),delete r[h]}c&&delete n.__transition}}function ow(n){return this.each(function(){es(this,n)})}function cw(n,i){var r,u;return function(){var o=wn(this,n),c=o.tween;if(c!==r){u=r=c;for(var h=0,g=u.length;h<g;++h)if(u[h].name===i){u=u.slice(),u.splice(h,1);break}}o.tween=u}}function fw(n,i,r){var u,o;if(typeof r!="function")throw new Error;return function(){var c=wn(this,n),h=c.tween;if(h!==u){o=(u=h).slice();for(var g={name:i,value:r},y=0,p=o.length;y<p;++y)if(o[y].name===i){o[y]=g;break}y===p&&o.push(g)}c.tween=o}}function hw(n,i){var r=this._id;if(n+="",arguments.length<2){for(var u=on(this.node(),r).tween,o=0,c=u.length,h;o<c;++o)if((h=u[o]).name===n)return h.value;return null}return this.each((i==null?cw:fw)(r,n,i))}function Wf(n,i,r){var u=n._id;return n.each(function(){var o=wn(this,u);(o.value||(o.value={}))[i]=r.apply(this,arguments)}),function(o){return on(o,u).value[i]}}function mm(n,i){var r;return(typeof i=="number"?xi:i instanceof bl?Mp:(r=bl(i))?(i=r,Mp):Z2)(n,i)}function dw(n){return function(){this.removeAttribute(n)}}function gw(n){return function(){this.removeAttributeNS(n.space,n.local)}}function pw(n,i,r){var u,o=r+"",c;return function(){var h=this.getAttribute(n);return h===o?null:h===u?c:c=i(u=h,r)}}function yw(n,i,r){var u,o=r+"",c;return function(){var h=this.getAttributeNS(n.space,n.local);return h===o?null:h===u?c:c=i(u=h,r)}}function mw(n,i,r){var u,o,c;return function(){var h,g=r(this),y;return g==null?void this.removeAttribute(n):(h=this.getAttribute(n),y=g+"",h===y?null:h===u&&y===o?c:(o=y,c=i(u=h,g)))}}function vw(n,i,r){var u,o,c;return function(){var h,g=r(this),y;return g==null?void this.removeAttributeNS(n.space,n.local):(h=this.getAttributeNS(n.space,n.local),y=g+"",h===y?null:h===u&&y===o?c:(o=y,c=i(u=h,g)))}}function bw(n,i){var r=vs(n),u=r==="transform"?J2:mm;return this.attrTween(n,typeof i=="function"?(r.local?vw:mw)(r,u,Wf(this,"attr."+n,i)):i==null?(r.local?gw:dw)(r):(r.local?yw:pw)(r,u,i))}function _w(n,i){return function(r){this.setAttribute(n,i.call(this,r))}}function xw(n,i){return function(r){this.setAttributeNS(n.space,n.local,i.call(this,r))}}function ww(n,i){var r,u;function o(){var c=i.apply(this,arguments);return c!==u&&(r=(u=c)&&xw(n,c)),r}return o._value=i,o}function Sw(n,i){var r,u;function o(){var c=i.apply(this,arguments);return c!==u&&(r=(u=c)&&_w(n,c)),r}return o._value=i,o}function Aw(n,i){var r="attr."+n;if(arguments.length<2)return(r=this.tween(r))&&r._value;if(i==null)return this.tween(r,null);if(typeof i!="function")throw new Error;var u=vs(n);return this.tween(r,(u.local?ww:Sw)(u,i))}function Ew(n,i){return function(){Jf(this,n).delay=+i.apply(this,arguments)}}function Tw(n,i){return i=+i,function(){Jf(this,n).delay=i}}function Ow(n){var i=this._id;return arguments.length?this.each((typeof n=="function"?Ew:Tw)(i,n)):on(this.node(),i).delay}function Mw(n,i){return function(){wn(this,n).duration=+i.apply(this,arguments)}}function Cw(n,i){return i=+i,function(){wn(this,n).duration=i}}function Nw(n){var i=this._id;return arguments.length?this.each((typeof n=="function"?Mw:Cw)(i,n)):on(this.node(),i).duration}function zw(n,i){if(typeof i!="function")throw new Error;return function(){wn(this,n).ease=i}}function Rw(n){var i=this._id;return arguments.length?this.each(zw(i,n)):on(this.node(),i).ease}function Dw(n,i){return function(){var r=i.apply(this,arguments);if(typeof r!="function")throw new Error;wn(this,n).ease=r}}function jw(n){if(typeof n!="function")throw new Error;return this.each(Dw(this._id,n))}function kw(n){typeof n!="function"&&(n=Py(n));for(var i=this._groups,r=i.length,u=new Array(r),o=0;o<r;++o)for(var c=i[o],h=c.length,g=u[o]=[],y,p=0;p<h;++p)(y=c[p])&&n.call(y,y.__data__,p,c)&&g.push(y);return new Pn(u,this._parents,this._name,this._id)}function Uw(n){if(n._id!==this._id)throw new Error;for(var i=this._groups,r=n._groups,u=i.length,o=r.length,c=Math.min(u,o),h=new Array(u),g=0;g<c;++g)for(var y=i[g],p=r[g],v=y.length,m=h[g]=new Array(v),_,x=0;x<v;++x)(_=y[x]||p[x])&&(m[x]=_);for(;g<u;++g)h[g]=i[g];return new Pn(h,this._parents,this._name,this._id)}function qw(n){return(n+"").trim().split(/^|\s+/).every(function(i){var r=i.indexOf(".");return r>=0&&(i=i.slice(0,r)),!i||i==="start"})}function Hw(n,i,r){var u,o,c=qw(i)?Jf:wn;return function(){var h=c(this,n),g=h.on;g!==u&&(o=(u=g).copy()).on(i,r),h.on=o}}function Lw(n,i){var r=this._id;return arguments.length<2?on(this.node(),r).on.on(n):this.each(Hw(r,n,i))}function Bw(n){return function(){var i=this.parentNode;for(var r in this.__transition)if(+r!==n)return;i&&i.removeChild(this)}}function Gw(){return this.on("end.remove",Bw(this._id))}function Qw(n){var i=this._name,r=this._id;typeof n!="function"&&(n=$f(n));for(var u=this._groups,o=u.length,c=new Array(o),h=0;h<o;++h)for(var g=u[h],y=g.length,p=c[h]=new Array(y),v,m,_=0;_<y;++_)(v=g[_])&&(m=n.call(v,v.__data__,_,g))&&("__data__"in v&&(m.__data__=v.__data__),p[_]=m,_s(p[_],i,r,_,p,on(v,r)));return new Pn(c,this._parents,i,r)}function Yw(n){var i=this._name,r=this._id;typeof n!="function"&&(n=Fy(n));for(var u=this._groups,o=u.length,c=[],h=[],g=0;g<o;++g)for(var y=u[g],p=y.length,v,m=0;m<p;++m)if(v=y[m]){for(var _=n.call(v,v.__data__,m,y),x,A=on(v,r),M=0,O=_.length;M<O;++M)(x=_[M])&&_s(x,i,r,M,_,A);c.push(_),h.push(v)}return new Pn(c,h,i,r)}var Xw=Al.prototype.constructor;function Vw(){return new Xw(this._groups,this._parents)}function $w(n,i){var r,u,o;return function(){var c=Ka(this,n),h=(this.style.removeProperty(n),Ka(this,n));return c===h?null:c===r&&h===u?o:o=i(r=c,u=h)}}function vm(n){return function(){this.style.removeProperty(n)}}function Zw(n,i,r){var u,o=r+"",c;return function(){var h=Ka(this,n);return h===o?null:h===u?c:c=i(u=h,r)}}function Kw(n,i,r){var u,o,c;return function(){var h=Ka(this,n),g=r(this),y=g+"";return g==null&&(y=g=(this.style.removeProperty(n),Ka(this,n))),h===y?null:h===u&&y===o?c:(o=y,c=i(u=h,g))}}function Fw(n,i){var r,u,o,c="style."+i,h="end."+c,g;return function(){var y=wn(this,n),p=y.on,v=y.value[c]==null?g||(g=vm(i)):void 0;(p!==r||o!==v)&&(u=(r=p).copy()).on(h,o=v),y.on=u}}function Pw(n,i,r){var u=(n+="")=="transform"?P2:mm;return i==null?this.styleTween(n,$w(n,u)).on("end.style."+n,vm(n)):typeof i=="function"?this.styleTween(n,Kw(n,u,Wf(this,"style."+n,i))).each(Fw(this._id,n)):this.styleTween(n,Zw(n,u,i),r).on("end.style."+n,null)}function Jw(n,i,r){return function(u){this.style.setProperty(n,i.call(this,u),r)}}function Ww(n,i,r){var u,o;function c(){var h=i.apply(this,arguments);return h!==o&&(u=(o=h)&&Jw(n,h,r)),u}return c._value=i,c}function Iw(n,i,r){var u="style."+(n+="");if(arguments.length<2)return(u=this.tween(u))&&u._value;if(i==null)return this.tween(u,null);if(typeof i!="function")throw new Error;return this.tween(u,Ww(n,i,r??""))}function tS(n){return function(){this.textContent=n}}function eS(n){return function(){var i=n(this);this.textContent=i??""}}function nS(n){return this.tween("text",typeof n=="function"?eS(Wf(this,"text",n)):tS(n==null?"":n+""))}function iS(n){return function(i){this.textContent=n.call(this,i)}}function aS(n){var i,r;function u(){var o=n.apply(this,arguments);return o!==r&&(i=(r=o)&&iS(o)),i}return u._value=n,u}function rS(n){var i="text";if(arguments.length<1)return(i=this.tween(i))&&i._value;if(n==null)return this.tween(i,null);if(typeof n!="function")throw new Error;return this.tween(i,aS(n))}function lS(){for(var n=this._name,i=this._id,r=bm(),u=this._groups,o=u.length,c=0;c<o;++c)for(var h=u[c],g=h.length,y,p=0;p<g;++p)if(y=h[p]){var v=on(y,i);_s(y,n,r,p,h,{time:v.time+v.delay+v.duration,delay:0,duration:v.duration,ease:v.ease})}return new Pn(u,this._parents,n,r)}function uS(){var n,i,r=this,u=r._id,o=r.size();return new Promise(function(c,h){var g={value:h},y={value:function(){--o===0&&c()}};r.each(function(){var p=wn(this,u),v=p.on;v!==n&&(i=(n=v).copy(),i._.cancel.push(g),i._.interrupt.push(g),i._.end.push(y)),p.on=i}),o===0&&c()})}var sS=0;function Pn(n,i,r,u){this._groups=n,this._parents=i,this._name=r,this._id=u}function bm(){return++sS}var Qn=Al.prototype;Pn.prototype={constructor:Pn,select:Qw,selectAll:Yw,selectChild:Qn.selectChild,selectChildren:Qn.selectChildren,filter:kw,merge:Uw,selection:Vw,transition:lS,call:Qn.call,nodes:Qn.nodes,node:Qn.node,size:Qn.size,empty:Qn.empty,each:Qn.each,on:Lw,attr:bw,attrTween:Aw,style:Pw,styleTween:Iw,text:nS,textTween:rS,remove:Gw,tween:hw,delay:Ow,duration:Nw,ease:Rw,easeVarying:jw,end:uS,[Symbol.iterator]:Qn[Symbol.iterator]};function oS(n){return((n*=2)<=1?n*n*n:(n-=2)*n*n+2)/2}var cS={time:null,delay:0,duration:250,ease:oS};function fS(n,i){for(var r;!(r=n.__transition)||!(r=r[i]);)if(!(n=n.parentNode))throw new Error(`transition ${i} not found`);return r}function hS(n){var i,r;n instanceof Pn?(i=n._id,n=n._name):(i=bm(),(r=cS).time=Ff(),n=n==null?null:n+"");for(var u=this._groups,o=u.length,c=0;c<o;++c)for(var h=u[c],g=h.length,y,p=0;p<g;++p)(y=h[p])&&_s(y,n,i,p,h,r||fS(y,i));return new Pn(u,this._parents,n,i)}Al.prototype.interrupt=ow;Al.prototype.transition=hS;const Fu=n=>()=>n;function dS(n,{sourceEvent:i,target:r,transform:u,dispatch:o}){Object.defineProperties(this,{type:{value:n,enumerable:!0,configurable:!0},sourceEvent:{value:i,enumerable:!0,configurable:!0},target:{value:r,enumerable:!0,configurable:!0},transform:{value:u,enumerable:!0,configurable:!0},_:{value:o}})}function Zn(n,i,r){this.k=n,this.x=i,this.y=r}Zn.prototype={constructor:Zn,scale:function(n){return n===1?this:new Zn(this.k*n,this.x,this.y)},translate:function(n,i){return n===0&i===0?this:new Zn(this.k,this.x+this.k*n,this.y+this.k*i)},apply:function(n){return[n[0]*this.k+this.x,n[1]*this.k+this.y]},applyX:function(n){return n*this.k+this.x},applyY:function(n){return n*this.k+this.y},invert:function(n){return[(n[0]-this.x)/this.k,(n[1]-this.y)/this.k]},invertX:function(n){return(n-this.x)/this.k},invertY:function(n){return(n-this.y)/this.k},rescaleX:function(n){return n.copy().domain(n.range().map(this.invertX,this).map(n.invert,n))},rescaleY:function(n){return n.copy().domain(n.range().map(this.invertY,this).map(n.invert,n))},toString:function(){return"translate("+this.x+","+this.y+") scale("+this.k+")"}};var If=new Zn(1,0,0);mn.prototype=Zn.prototype;function mn(n){for(;!n.__zoom;)if(!(n=n.parentNode))return If;return n.__zoom}function af(n){n.stopImmediatePropagation()}function tl(n){n.preventDefault(),n.stopImmediatePropagation()}function gS(n){return(!n.ctrlKey||n.type==="wheel")&&!n.button}function pS(){var n=this;return n instanceof SVGElement?(n=n.ownerSVGElement||n,n.hasAttribute("viewBox")?(n=n.viewBox.baseVal,[[n.x,n.y],[n.x+n.width,n.y+n.height]]):[[0,0],[n.width.baseVal.value,n.height.baseVal.value]]):[[0,0],[n.clientWidth,n.clientHeight]]}function kp(){return this.__zoom||If}function yS(n){return-n.deltaY*(n.deltaMode===1?.05:n.deltaMode?1:.002)*(n.ctrlKey?10:1)}function mS(){return navigator.maxTouchPoints||"ontouchstart"in this}function vS(n,i,r){var u=n.invertX(i[0][0])-r[0][0],o=n.invertX(i[1][0])-r[1][0],c=n.invertY(i[0][1])-r[0][1],h=n.invertY(i[1][1])-r[1][1];return n.translate(o>u?(u+o)/2:Math.min(0,u)||Math.max(0,o),h>c?(c+h)/2:Math.min(0,c)||Math.max(0,h))}function bS(){var n=gS,i=pS,r=vS,u=yS,o=mS,c=[0,1/0],h=[[-1/0,-1/0],[1/0,1/0]],g=250,y=ew,p=El("start","zoom","end"),v,m,_,x=500,A=150,M=0,O=10;function S(L){L.property("__zoom",kp).on("wheel.zoom",Q,{passive:!1}).on("mousedown.zoom",tt).on("dblclick.zoom",F).filter(o).on("touchstart.zoom",K).on("touchmove.zoom",it).on("touchend.zoom touchcancel.zoom",ct).style("-webkit-tap-highlight-color","rgba(0,0,0,0)")}S.transform=function(L,J,N,Z){var et=L.selection?L.selection():L;et.property("__zoom",kp),L!==et?C(L,J,N,Z):et.interrupt().each(function(){q(this,arguments).event(Z).start().zoom(null,typeof J=="function"?J.apply(this,arguments):J).end()})},S.scaleBy=function(L,J,N,Z){S.scaleTo(L,function(){var et=this.__zoom.k,ut=typeof J=="function"?J.apply(this,arguments):J;return et*ut},N,Z)},S.scaleTo=function(L,J,N,Z){S.transform(L,function(){var et=i.apply(this,arguments),ut=this.__zoom,T=N==null?R(et):typeof N=="function"?N.apply(this,arguments):N,$=ut.invert(T),nt=typeof J=="function"?J.apply(this,arguments):J;return r(H(j(ut,nt),T,$),et,h)},N,Z)},S.translateBy=function(L,J,N,Z){S.transform(L,function(){return r(this.__zoom.translate(typeof J=="function"?J.apply(this,arguments):J,typeof N=="function"?N.apply(this,arguments):N),i.apply(this,arguments),h)},null,Z)},S.translateTo=function(L,J,N,Z,et){S.transform(L,function(){var ut=i.apply(this,arguments),T=this.__zoom,$=Z==null?R(ut):typeof Z=="function"?Z.apply(this,arguments):Z;return r(If.translate($[0],$[1]).scale(T.k).translate(typeof J=="function"?-J.apply(this,arguments):-J,typeof N=="function"?-N.apply(this,arguments):-N),ut,h)},Z,et)};function j(L,J){return J=Math.max(c[0],Math.min(c[1],J)),J===L.k?L:new Zn(J,L.x,L.y)}function H(L,J,N){var Z=J[0]-N[0]*L.k,et=J[1]-N[1]*L.k;return Z===L.x&&et===L.y?L:new Zn(L.k,Z,et)}function R(L){return[(+L[0][0]+ +L[1][0])/2,(+L[0][1]+ +L[1][1])/2]}function C(L,J,N,Z){L.on("start.zoom",function(){q(this,arguments).event(Z).start()}).on("interrupt.zoom end.zoom",function(){q(this,arguments).event(Z).end()}).tween("zoom",function(){var et=this,ut=arguments,T=q(et,ut).event(Z),$=i.apply(et,ut),nt=N==null?R($):typeof N=="function"?N.apply(et,ut):N,at=Math.max($[1][0]-$[0][0],$[1][1]-$[0][1]),st=et.__zoom,yt=typeof J=="function"?J.apply(et,ut):J,ht=y(st.invert(nt).concat(at/st.k),yt.invert(nt).concat(at/yt.k));return function(Ct){if(Ct===1)Ct=yt;else{var At=ht(Ct),ve=at/At[2];Ct=new Zn(ve,nt[0]-At[0]*ve,nt[1]-At[1]*ve)}T.zoom(null,Ct)}})}function q(L,J,N){return!N&&L.__zooming||new U(L,J)}function U(L,J){this.that=L,this.args=J,this.active=0,this.sourceEvent=null,this.extent=i.apply(L,J),this.taps=0}U.prototype={event:function(L){return L&&(this.sourceEvent=L),this},start:function(){return++this.active===1&&(this.that.__zooming=this,this.emit("start")),this},zoom:function(L,J){return this.mouse&&L!=="mouse"&&(this.mouse[1]=J.invert(this.mouse[0])),this.touch0&&L!=="touch"&&(this.touch0[1]=J.invert(this.touch0[0])),this.touch1&&L!=="touch"&&(this.touch1[1]=J.invert(this.touch1[0])),this.that.__zoom=J,this.emit("zoom"),this},end:function(){return--this.active===0&&(delete this.that.__zooming,this.emit("end")),this},emit:function(L){var J=Ie(this.that).datum();p.call(L,this.that,new dS(L,{sourceEvent:this.sourceEvent,target:S,transform:this.that.__zoom,dispatch:p}),J)}};function Q(L,...J){if(!n.apply(this,arguments))return;var N=q(this,J).event(L),Z=this.__zoom,et=Math.max(c[0],Math.min(c[1],Z.k*Math.pow(2,u.apply(this,arguments)))),ut=vn(L);if(N.wheel)(N.mouse[0][0]!==ut[0]||N.mouse[0][1]!==ut[1])&&(N.mouse[1]=Z.invert(N.mouse[0]=ut)),clearTimeout(N.wheel);else{if(Z.k===et)return;N.mouse=[ut,Z.invert(ut)],es(this),N.start()}tl(L),N.wheel=setTimeout(T,A),N.zoom("mouse",r(H(j(Z,et),N.mouse[0],N.mouse[1]),N.extent,h));function T(){N.wheel=null,N.end()}}function tt(L,...J){if(_||!n.apply(this,arguments))return;var N=L.currentTarget,Z=q(this,J,!0).event(L),et=Ie(L.view).on("mousemove.zoom",nt,!0).on("mouseup.zoom",at,!0),ut=vn(L,N),T=L.clientX,$=L.clientY;lm(L.view),af(L),Z.mouse=[ut,this.__zoom.invert(ut)],es(this),Z.start();function nt(st){if(tl(st),!Z.moved){var yt=st.clientX-T,ht=st.clientY-$;Z.moved=yt*yt+ht*ht>M}Z.event(st).zoom("mouse",r(H(Z.that.__zoom,Z.mouse[0]=vn(st,N),Z.mouse[1]),Z.extent,h))}function at(st){et.on("mousemove.zoom mouseup.zoom",null),um(st.view,Z.moved),tl(st),Z.event(st).end()}}function F(L,...J){if(n.apply(this,arguments)){var N=this.__zoom,Z=vn(L.changedTouches?L.changedTouches[0]:L,this),et=N.invert(Z),ut=N.k*(L.shiftKey?.5:2),T=r(H(j(N,ut),Z,et),i.apply(this,J),h);tl(L),g>0?Ie(this).transition().duration(g).call(C,T,Z,L):Ie(this).call(S.transform,T,Z,L)}}function K(L,...J){if(n.apply(this,arguments)){var N=L.touches,Z=N.length,et=q(this,J,L.changedTouches.length===Z).event(L),ut,T,$,nt;for(af(L),T=0;T<Z;++T)$=N[T],nt=vn($,this),nt=[nt,this.__zoom.invert(nt),$.identifier],et.touch0?!et.touch1&&et.touch0[2]!==nt[2]&&(et.touch1=nt,et.taps=0):(et.touch0=nt,ut=!0,et.taps=1+!!v);v&&(v=clearTimeout(v)),ut&&(et.taps<2&&(m=nt[0],v=setTimeout(function(){v=null},x)),es(this),et.start())}}function it(L,...J){if(this.__zooming){var N=q(this,J).event(L),Z=L.changedTouches,et=Z.length,ut,T,$,nt;for(tl(L),ut=0;ut<et;++ut)T=Z[ut],$=vn(T,this),N.touch0&&N.touch0[2]===T.identifier?N.touch0[0]=$:N.touch1&&N.touch1[2]===T.identifier&&(N.touch1[0]=$);if(T=N.that.__zoom,N.touch1){var at=N.touch0[0],st=N.touch0[1],yt=N.touch1[0],ht=N.touch1[1],Ct=(Ct=yt[0]-at[0])*Ct+(Ct=yt[1]-at[1])*Ct,At=(At=ht[0]-st[0])*At+(At=ht[1]-st[1])*At;T=j(T,Math.sqrt(Ct/At)),$=[(at[0]+yt[0])/2,(at[1]+yt[1])/2],nt=[(st[0]+ht[0])/2,(st[1]+ht[1])/2]}else if(N.touch0)$=N.touch0[0],nt=N.touch0[1];else return;N.zoom("touch",r(H(T,$,nt),N.extent,h))}}function ct(L,...J){if(this.__zooming){var N=q(this,J).event(L),Z=L.changedTouches,et=Z.length,ut,T;for(af(L),_&&clearTimeout(_),_=setTimeout(function(){_=null},x),ut=0;ut<et;++ut)T=Z[ut],N.touch0&&N.touch0[2]===T.identifier?delete N.touch0:N.touch1&&N.touch1[2]===T.identifier&&delete N.touch1;if(N.touch1&&!N.touch0&&(N.touch0=N.touch1,delete N.touch1),N.touch0)N.touch0[1]=this.__zoom.invert(N.touch0[0]);else if(N.end(),N.taps===2&&(T=vn(T,this),Math.hypot(m[0]-T[0],m[1]-T[1])<O)){var $=Ie(this).on("dblclick.zoom");$&&$.apply(this,arguments)}}}return S.wheelDelta=function(L){return arguments.length?(u=typeof L=="function"?L:Fu(+L),S):u},S.filter=function(L){return arguments.length?(n=typeof L=="function"?L:Fu(!!L),S):n},S.touchable=function(L){return arguments.length?(o=typeof L=="function"?L:Fu(!!L),S):o},S.extent=function(L){return arguments.length?(i=typeof L=="function"?L:Fu([[+L[0][0],+L[0][1]],[+L[1][0],+L[1][1]]]),S):i},S.scaleExtent=function(L){return arguments.length?(c[0]=+L[0],c[1]=+L[1],S):[c[0],c[1]]},S.translateExtent=function(L){return arguments.length?(h[0][0]=+L[0][0],h[1][0]=+L[1][0],h[0][1]=+L[0][1],h[1][1]=+L[1][1],S):[[h[0][0],h[0][1]],[h[1][0],h[1][1]]]},S.constrain=function(L){return arguments.length?(r=L,S):r},S.duration=function(L){return arguments.length?(g=+L,S):g},S.interpolate=function(L){return arguments.length?(y=L,S):y},S.on=function(){var L=p.on.apply(p,arguments);return L===p?S:L},S.clickDistance=function(L){return arguments.length?(M=(L=+L)*L,S):Math.sqrt(M)},S.tapDistance=function(L){return arguments.length?(O=+L,S):O},S}class Up extends Map{constructor(i,r=wS){if(super(),Object.defineProperties(this,{_intern:{value:new Map},_key:{value:r}}),i!=null)for(const[u,o]of i)this.set(u,o)}get(i){return super.get(qp(this,i))}has(i){return super.has(qp(this,i))}set(i,r){return super.set(_S(this,i),r)}delete(i){return super.delete(xS(this,i))}}function qp({_intern:n,_key:i},r){const u=i(r);return n.has(u)?n.get(u):r}function _S({_intern:n,_key:i},r){const u=i(r);return n.has(u)?n.get(u):(n.set(u,r),r)}function xS({_intern:n,_key:i},r){const u=i(r);return n.has(u)&&(r=n.get(u),n.delete(u)),r}function wS(n){return n!==null&&typeof n=="object"?n.valueOf():n}function Hp(n,i){let r;if(i===void 0)for(const u of n)u!=null&&(r<u||r===void 0&&u>=u)&&(r=u);else{let u=-1;for(let o of n)(o=i(o,++u,n))!=null&&(r<o||r===void 0&&o>=o)&&(r=o)}return r}function Lp(n,i){let r;if(i===void 0)for(const u of n)u!=null&&(r>u||r===void 0&&u>=u)&&(r=u);else{let u=-1;for(let o of n)(o=i(o,++u,n))!=null&&(r>o||r===void 0&&o>=o)&&(r=o)}return r}function SS(n,i){let r=0;for(let u of n)(u=+u)&&(r+=u);return r}var AS=typeof global=="object"&&global&&global.Object===Object&&global,ES=typeof self=="object"&&self&&self.Object===Object&&self,_m=AS||ES||Function("return this")(),fs=_m.Symbol,xm=Object.prototype,TS=xm.hasOwnProperty,OS=xm.toString,el=fs?fs.toStringTag:void 0;function MS(n){var i=TS.call(n,el),r=n[el];try{n[el]=void 0;var u=!0}catch{}var o=OS.call(n);return u&&(i?n[el]=r:delete n[el]),o}var CS=Object.prototype,NS=CS.toString;function zS(n){return NS.call(n)}var RS="[object Null]",DS="[object Undefined]",Bp=fs?fs.toStringTag:void 0;function jS(n){return n==null?n===void 0?DS:RS:Bp&&Bp in Object(n)?MS(n):zS(n)}function kS(n){return n!=null&&typeof n=="object"}var US="[object Symbol]";function qS(n){return typeof n=="symbol"||kS(n)&&jS(n)==US}var HS=/\s/;function LS(n){for(var i=n.length;i--&&HS.test(n.charAt(i)););return i}var BS=/^\s+/;function GS(n){return n&&n.slice(0,LS(n)+1).replace(BS,"")}function hs(n){var i=typeof n;return n!=null&&(i=="object"||i=="function")}var Gp=NaN,QS=/^[-+]0x[0-9a-f]+$/i,YS=/^0b[01]+$/i,XS=/^0o[0-7]+$/i,VS=parseInt;function Qp(n){if(typeof n=="number")return n;if(qS(n))return Gp;if(hs(n)){var i=typeof n.valueOf=="function"?n.valueOf():n;n=hs(i)?i+"":i}if(typeof n!="string")return n===0?n:+n;n=GS(n);var r=YS.test(n);return r||XS.test(n)?VS(n.slice(2),r?2:8):QS.test(n)?Gp:+n}var rf=function(){return _m.Date.now()},$S="Expected a function",ZS=Math.max,KS=Math.min;function wm(n,i,r){var u,o,c,h,g,y,p=0,v=!1,m=!1,_=!0;if(typeof n!="function")throw new TypeError($S);i=Qp(i)||0,hs(r)&&(v=!!r.leading,m="maxWait"in r,c=m?ZS(Qp(r.maxWait)||0,i):c,_="trailing"in r?!!r.trailing:_);function x(q){var U=u,Q=o;return u=o=void 0,p=q,h=n.apply(Q,U),h}function A(q){return p=q,g=setTimeout(S,i),v?x(q):h}function M(q){var U=q-y,Q=q-p,tt=i-U;return m?KS(tt,c-Q):tt}function O(q){var U=q-y,Q=q-p;return y===void 0||U>=i||U<0||m&&Q>=c}function S(){var q=rf();if(O(q))return j(q);g=setTimeout(S,M(q))}function j(q){return g=void 0,_&&u?x(q):(u=o=void 0,h)}function H(){g!==void 0&&clearTimeout(g),p=0,u=y=o=g=void 0}function R(){return g===void 0?h:j(rf())}function C(){var q=rf(),U=O(q);if(u=arguments,o=this,y=q,U){if(g===void 0)return A(y);if(m)return clearTimeout(g),g=setTimeout(S,i),x(y)}return g===void 0&&(g=setTimeout(S,i)),h}return C.cancel=H,C.flush=R,C}var FS="Expected a function";function PS(n,i,r){var u=!0,o=!0;if(typeof n!="function")throw new TypeError(FS);return hs(r)&&(u="leading"in r?!!r.leading:u,o="trailing"in r?!!r.trailing:o),wm(n,i,{leading:u,maxWait:i,trailing:o})}var Ji=Object.freeze({Linear:Object.freeze({None:function(n){return n},In:function(n){return n},Out:function(n){return n},InOut:function(n){return n}}),Quadratic:Object.freeze({In:function(n){return n*n},Out:function(n){return n*(2-n)},InOut:function(n){return(n*=2)<1?.5*n*n:-.5*(--n*(n-2)-1)}}),Cubic:Object.freeze({In:function(n){return n*n*n},Out:function(n){return--n*n*n+1},InOut:function(n){return(n*=2)<1?.5*n*n*n:.5*((n-=2)*n*n+2)}}),Quartic:Object.freeze({In:function(n){return n*n*n*n},Out:function(n){return 1- --n*n*n*n},InOut:function(n){return(n*=2)<1?.5*n*n*n*n:-.5*((n-=2)*n*n*n-2)}}),Quintic:Object.freeze({In:function(n){return n*n*n*n*n},Out:function(n){return--n*n*n*n*n+1},InOut:function(n){return(n*=2)<1?.5*n*n*n*n*n:.5*((n-=2)*n*n*n*n+2)}}),Sinusoidal:Object.freeze({In:function(n){return 1-Math.sin((1-n)*Math.PI/2)},Out:function(n){return Math.sin(n*Math.PI/2)},InOut:function(n){return .5*(1-Math.sin(Math.PI*(.5-n)))}}),Exponential:Object.freeze({In:function(n){return n===0?0:Math.pow(1024,n-1)},Out:function(n){return n===1?1:1-Math.pow(2,-10*n)},InOut:function(n){return n===0?0:n===1?1:(n*=2)<1?.5*Math.pow(1024,n-1):.5*(-Math.pow(2,-10*(n-1))+2)}}),Circular:Object.freeze({In:function(n){return 1-Math.sqrt(1-n*n)},Out:function(n){return Math.sqrt(1- --n*n)},InOut:function(n){return(n*=2)<1?-.5*(Math.sqrt(1-n*n)-1):.5*(Math.sqrt(1-(n-=2)*n)+1)}}),Elastic:Object.freeze({In:function(n){return n===0?0:n===1?1:-Math.pow(2,10*(n-1))*Math.sin((n-1.1)*5*Math.PI)},Out:function(n){return n===0?0:n===1?1:Math.pow(2,-10*n)*Math.sin((n-.1)*5*Math.PI)+1},InOut:function(n){return n===0?0:n===1?1:(n*=2,n<1?-.5*Math.pow(2,10*(n-1))*Math.sin((n-1.1)*5*Math.PI):.5*Math.pow(2,-10*(n-1))*Math.sin((n-1.1)*5*Math.PI)+1)}}),Back:Object.freeze({In:function(n){var i=1.70158;return n===1?1:n*n*((i+1)*n-i)},Out:function(n){var i=1.70158;return n===0?0:--n*n*((i+1)*n+i)+1},InOut:function(n){var i=2.5949095;return(n*=2)<1?.5*(n*n*((i+1)*n-i)):.5*((n-=2)*n*((i+1)*n+i)+2)}}),Bounce:Object.freeze({In:function(n){return 1-Ji.Bounce.Out(1-n)},Out:function(n){return n<1/2.75?7.5625*n*n:n<2/2.75?7.5625*(n-=1.5/2.75)*n+.75:n<2.5/2.75?7.5625*(n-=2.25/2.75)*n+.9375:7.5625*(n-=2.625/2.75)*n+.984375},InOut:function(n){return n<.5?Ji.Bounce.In(n*2)*.5:Ji.Bounce.Out(n*2-1)*.5+.5}}),generatePow:function(n){return n===void 0&&(n=4),n=n<Number.EPSILON?Number.EPSILON:n,n=n>1e4?1e4:n,{In:function(i){return Math.pow(i,n)},Out:function(i){return 1-Math.pow(1-i,n)},InOut:function(i){return i<.5?Math.pow(i*2,n)/2:(1-Math.pow(2-i*2,n))/2+.5}}}}),cl=function(){return performance.now()},Sm=function(){function n(){for(var i=[],r=0;r<arguments.length;r++)i[r]=arguments[r];this._tweens={},this._tweensAddedDuringUpdate={},this.add.apply(this,i)}return n.prototype.getAll=function(){var i=this;return Object.keys(this._tweens).map(function(r){return i._tweens[r]})},n.prototype.removeAll=function(){this._tweens={}},n.prototype.add=function(){for(var i,r=[],u=0;u<arguments.length;u++)r[u]=arguments[u];for(var o=0,c=r;o<c.length;o++){var h=c[o];(i=h._group)===null||i===void 0||i.remove(h),h._group=this,this._tweens[h.getId()]=h,this._tweensAddedDuringUpdate[h.getId()]=h}},n.prototype.remove=function(){for(var i=[],r=0;r<arguments.length;r++)i[r]=arguments[r];for(var u=0,o=i;u<o.length;u++){var c=o[u];c._group=void 0,delete this._tweens[c.getId()],delete this._tweensAddedDuringUpdate[c.getId()]}},n.prototype.allStopped=function(){return this.getAll().every(function(i){return!i.isPlaying()})},n.prototype.update=function(i,r){i===void 0&&(i=cl()),r===void 0&&(r=!0);var u=Object.keys(this._tweens);if(u.length!==0)for(;u.length>0;){this._tweensAddedDuringUpdate={};for(var o=0;o<u.length;o++){var c=this._tweens[u[o]],h=!r;c&&c.update(i,h)===!1&&!r&&this.remove(c)}u=Object.keys(this._tweensAddedDuringUpdate)}},n}(),Cf={Linear:function(n,i){var r=n.length-1,u=r*i,o=Math.floor(u),c=Cf.Utils.Linear;return i<0?c(n[0],n[1],u):i>1?c(n[r],n[r-1],r-u):c(n[o],n[o+1>r?r:o+1],u-o)},Utils:{Linear:function(n,i,r){return(i-n)*r+n}}},Am=function(){function n(){}return n.nextId=function(){return n._nextId++},n._nextId=0,n}(),Nf=new Sm,Yp=function(){function n(i,r){this._isPaused=!1,this._pauseStart=0,this._valuesStart={},this._valuesEnd={},this._valuesStartRepeat={},this._duration=1e3,this._isDynamic=!1,this._initialRepeat=0,this._repeat=0,this._yoyo=!1,this._isPlaying=!1,this._reversed=!1,this._delayTime=0,this._startTime=0,this._easingFunction=Ji.Linear.None,this._interpolationFunction=Cf.Linear,this._chainedTweens=[],this._onStartCallbackFired=!1,this._onEveryStartCallbackFired=!1,this._id=Am.nextId(),this._isChainStopped=!1,this._propertiesAreSetUp=!1,this._goToEnd=!1,this._object=i,typeof r=="object"?(this._group=r,r.add(this)):r===!0&&(this._group=Nf,Nf.add(this))}return n.prototype.getId=function(){return this._id},n.prototype.isPlaying=function(){return this._isPlaying},n.prototype.isPaused=function(){return this._isPaused},n.prototype.getDuration=function(){return this._duration},n.prototype.to=function(i,r){if(r===void 0&&(r=1e3),this._isPlaying)throw new Error("Can not call Tween.to() while Tween is already started or paused. Stop the Tween first.");return this._valuesEnd=i,this._propertiesAreSetUp=!1,this._duration=r<0?0:r,this},n.prototype.duration=function(i){return i===void 0&&(i=1e3),this._duration=i<0?0:i,this},n.prototype.dynamic=function(i){return i===void 0&&(i=!1),this._isDynamic=i,this},n.prototype.start=function(i,r){if(i===void 0&&(i=cl()),r===void 0&&(r=!1),this._isPlaying)return this;if(this._repeat=this._initialRepeat,this._reversed){this._reversed=!1;for(var u in this._valuesStartRepeat)this._swapEndStartRepeatValues(u),this._valuesStart[u]=this._valuesStartRepeat[u]}if(this._isPlaying=!0,this._isPaused=!1,this._onStartCallbackFired=!1,this._onEveryStartCallbackFired=!1,this._isChainStopped=!1,this._startTime=i,this._startTime+=this._delayTime,!this._propertiesAreSetUp||r){if(this._propertiesAreSetUp=!0,!this._isDynamic){var o={};for(var c in this._valuesEnd)o[c]=this._valuesEnd[c];this._valuesEnd=o}this._setupProperties(this._object,this._valuesStart,this._valuesEnd,this._valuesStartRepeat,r)}return this},n.prototype.startFromCurrentValues=function(i){return this.start(i,!0)},n.prototype._setupProperties=function(i,r,u,o,c){for(var h in u){var g=i[h],y=Array.isArray(g),p=y?"array":typeof g,v=!y&&Array.isArray(u[h]);if(!(p==="undefined"||p==="function")){if(v){var m=u[h];if(m.length===0)continue;for(var _=[g],x=0,A=m.length;x<A;x+=1){var M=this._handleRelativeValue(g,m[x]);if(isNaN(M)){v=!1,console.warn("Found invalid interpolation list. Skipping.");break}_.push(M)}v&&(u[h]=_)}if((p==="object"||y)&&g&&!v){r[h]=y?[]:{};var O=g;for(var S in O)r[h][S]=O[S];o[h]=y?[]:{};var m=u[h];if(!this._isDynamic){var j={};for(var S in m)j[S]=m[S];u[h]=m=j}this._setupProperties(O,r[h],m,o[h],c)}else(typeof r[h]>"u"||c)&&(r[h]=g),y||(r[h]*=1),v?o[h]=u[h].slice().reverse():o[h]=r[h]||0}}},n.prototype.stop=function(){return this._isChainStopped||(this._isChainStopped=!0,this.stopChainedTweens()),this._isPlaying?(this._isPlaying=!1,this._isPaused=!1,this._onStopCallback&&this._onStopCallback(this._object),this):this},n.prototype.end=function(){return this._goToEnd=!0,this.update(this._startTime+this._duration),this},n.prototype.pause=function(i){return i===void 0&&(i=cl()),this._isPaused||!this._isPlaying?this:(this._isPaused=!0,this._pauseStart=i,this)},n.prototype.resume=function(i){return i===void 0&&(i=cl()),!this._isPaused||!this._isPlaying?this:(this._isPaused=!1,this._startTime+=i-this._pauseStart,this._pauseStart=0,this)},n.prototype.stopChainedTweens=function(){for(var i=0,r=this._chainedTweens.length;i<r;i++)this._chainedTweens[i].stop();return this},n.prototype.group=function(i){return i?(i.add(this),this):(console.warn("tween.group() without args has been removed, use group.add(tween) instead."),this)},n.prototype.remove=function(){var i;return(i=this._group)===null||i===void 0||i.remove(this),this},n.prototype.delay=function(i){return i===void 0&&(i=0),this._delayTime=i,this},n.prototype.repeat=function(i){return i===void 0&&(i=0),this._initialRepeat=i,this._repeat=i,this},n.prototype.repeatDelay=function(i){return this._repeatDelayTime=i,this},n.prototype.yoyo=function(i){return i===void 0&&(i=!1),this._yoyo=i,this},n.prototype.easing=function(i){return i===void 0&&(i=Ji.Linear.None),this._easingFunction=i,this},n.prototype.interpolation=function(i){return i===void 0&&(i=Cf.Linear),this._interpolationFunction=i,this},n.prototype.chain=function(){for(var i=[],r=0;r<arguments.length;r++)i[r]=arguments[r];return this._chainedTweens=i,this},n.prototype.onStart=function(i){return this._onStartCallback=i,this},n.prototype.onEveryStart=function(i){return this._onEveryStartCallback=i,this},n.prototype.onUpdate=function(i){return this._onUpdateCallback=i,this},n.prototype.onRepeat=function(i){return this._onRepeatCallback=i,this},n.prototype.onComplete=function(i){return this._onCompleteCallback=i,this},n.prototype.onStop=function(i){return this._onStopCallback=i,this},n.prototype.update=function(i,r){var u=this,o;if(i===void 0&&(i=cl()),r===void 0&&(r=n.autoStartOnUpdate),this._isPaused)return!0;var c;if(!this._goToEnd&&!this._isPlaying)if(r)this.start(i,!0);else return!1;if(this._goToEnd=!1,i<this._startTime)return!0;this._onStartCallbackFired===!1&&(this._onStartCallback&&this._onStartCallback(this._object),this._onStartCallbackFired=!0),this._onEveryStartCallbackFired===!1&&(this._onEveryStartCallback&&this._onEveryStartCallback(this._object),this._onEveryStartCallbackFired=!0);var h=i-this._startTime,g=this._duration+((o=this._repeatDelayTime)!==null&&o!==void 0?o:this._delayTime),y=this._duration+this._repeat*g,p=function(){if(u._duration===0||h>y)return 1;var M=Math.trunc(h/g),O=h-M*g,S=Math.min(O/u._duration,1);return S===0&&h===u._duration?1:S},v=p(),m=this._easingFunction(v);if(this._updateProperties(this._object,this._valuesStart,this._valuesEnd,m),this._onUpdateCallback&&this._onUpdateCallback(this._object,v),this._duration===0||h>=this._duration)if(this._repeat>0){var _=Math.min(Math.trunc((h-this._duration)/g)+1,this._repeat);isFinite(this._repeat)&&(this._repeat-=_);for(c in this._valuesStartRepeat)!this._yoyo&&typeof this._valuesEnd[c]=="string"&&(this._valuesStartRepeat[c]=this._valuesStartRepeat[c]+parseFloat(this._valuesEnd[c])),this._yoyo&&this._swapEndStartRepeatValues(c),this._valuesStart[c]=this._valuesStartRepeat[c];return this._yoyo&&(this._reversed=!this._reversed),this._startTime+=g*_,this._onRepeatCallback&&this._onRepeatCallback(this._object),this._onEveryStartCallbackFired=!1,!0}else{this._onCompleteCallback&&this._onCompleteCallback(this._object);for(var x=0,A=this._chainedTweens.length;x<A;x++)this._chainedTweens[x].start(this._startTime+this._duration,!1);return this._isPlaying=!1,!1}return!0},n.prototype._updateProperties=function(i,r,u,o){for(var c in u)if(r[c]!==void 0){var h=r[c]||0,g=u[c],y=Array.isArray(i[c]),p=Array.isArray(g),v=!y&&p;v?i[c]=this._interpolationFunction(g,o):typeof g=="object"&&g?this._updateProperties(i[c],h,g,o):(g=this._handleRelativeValue(h,g),typeof g=="number"&&(i[c]=h+(g-h)*o))}},n.prototype._handleRelativeValue=function(i,r){return typeof r!="string"?r:r.charAt(0)==="+"||r.charAt(0)==="-"?i+parseFloat(r):parseFloat(r)},n.prototype._swapEndStartRepeatValues=function(i){var r=this._valuesStartRepeat[i],u=this._valuesEnd[i];typeof u=="string"?this._valuesStartRepeat[i]=this._valuesStartRepeat[i]+parseFloat(u):this._valuesStartRepeat[i]=this._valuesEnd[i],this._valuesEnd[i]=r},n.autoStartOnUpdate=!1,n}();Am.nextId;var xn=Nf;xn.getAll.bind(xn);xn.removeAll.bind(xn);xn.add.bind(xn);xn.remove.bind(xn);xn.update.bind(xn);function Xp(n,i){(i==null||i>n.length)&&(i=n.length);for(var r=0,u=Array(i);r<i;r++)u[r]=n[r];return u}function JS(n){if(Array.isArray(n))return n}function WS(n,i){if(!(n instanceof i))throw new TypeError("Cannot call a class as a function")}function IS(n,i,r){return Object.defineProperty(n,"prototype",{writable:!1}),n}function t3(n,i){var r=n==null?null:typeof Symbol<"u"&&n[Symbol.iterator]||n["@@iterator"];if(r!=null){var u,o,c,h,g=[],y=!0,p=!1;try{if(c=(r=r.call(n)).next,i!==0)for(;!(y=(u=c.call(r)).done)&&(g.push(u.value),g.length!==i);y=!0);}catch(v){p=!0,o=v}finally{try{if(!y&&r.return!=null&&(h=r.return(),Object(h)!==h))return}finally{if(p)throw o}}return g}}function e3(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
|
|
129
|
-
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function n3(n,i){return JS(n)||t3(n,i)||i3(n,i)||e3()}function i3(n,i){if(n){if(typeof n=="string")return Xp(n,i);var r={}.toString.call(n).slice(8,-1);return r==="Object"&&n.constructor&&(r=n.constructor.name),r==="Map"||r==="Set"?Array.from(n):r==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?Xp(n,i):void 0}}var a3=IS(function n(i,r){var u=r.default,o=u===void 0?null:u,c=r.triggerUpdate,h=c===void 0?!0:c,g=r.onChange,y=g===void 0?function(p,v){}:g;WS(this,n),this.name=i,this.defaultVal=o,this.triggerUpdate=h,this.onChange=y});function th(n){var i=n.stateInit,r=i===void 0?function(){return{}}:i,u=n.props,o=u===void 0?{}:u,c=n.methods,h=c===void 0?{}:c,g=n.aliases,y=g===void 0?{}:g,p=n.init,v=p===void 0?function(){}:p,m=n.update,_=m===void 0?function(){}:m,x=Object.keys(o).map(function(A){return new a3(A,o[A])});return function A(){for(var M=arguments.length,O=new Array(M),S=0;S<M;S++)O[S]=arguments[S];var j=!!(this instanceof A&&this.constructor),H=j?O.shift():void 0,R=O[0],C=R===void 0?{}:R,q=Object.assign({},r instanceof Function?r(C):r,{initialised:!1}),U={};function Q(K){return tt(K,C),F(),Q}var tt=function(it,ct){v.call(Q,it,q,ct),q.initialised=!0},F=wm(function(){q.initialised&&(_.call(Q,q,U),U={})},1);return x.forEach(function(K){Q[K.name]=it(K);function it(ct){var L=ct.name,J=ct.triggerUpdate,N=J===void 0?!1:J,Z=ct.onChange,et=Z===void 0?function($,nt){}:Z,ut=ct.defaultVal,T=ut===void 0?null:ut;return function($){var nt=q[L];if(!arguments.length)return nt;var at=$===void 0?T:$;return q[L]=at,et.call(Q,at,q,nt),!U.hasOwnProperty(L)&&(U[L]=nt),N&&F(),Q}}}),Object.keys(h).forEach(function(K){Q[K]=function(){for(var it,ct=arguments.length,L=new Array(ct),J=0;J<ct;J++)L[J]=arguments[J];return(it=h[K]).call.apply(it,[Q,q].concat(L))}}),Object.entries(y).forEach(function(K){var it=n3(K,2),ct=it[0],L=it[1];return Q[ct]=Q[L]}),Q.resetProps=function(){return x.forEach(function(K){Q[K.name](K.defaultVal)}),Q},Q.resetProps(),q._rerender=F,j&&H&&Q(H),Q}}var Dt=function(n){return typeof n=="function"?n:typeof n=="string"?function(i){return i[n]}:function(i){return n}};function ds(n){"@babel/helpers - typeof";return ds=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(i){return typeof i}:function(i){return i&&typeof Symbol=="function"&&i.constructor===Symbol&&i!==Symbol.prototype?"symbol":typeof i},ds(n)}var r3=/^\s+/,l3=/\s+$/;function gt(n,i){if(n=n||"",i=i||{},n instanceof gt)return n;if(!(this instanceof gt))return new gt(n,i);var r=u3(n);this._originalInput=n,this._r=r.r,this._g=r.g,this._b=r.b,this._a=r.a,this._roundA=Math.round(100*this._a)/100,this._format=i.format||r.format,this._gradientType=i.gradientType,this._r<1&&(this._r=Math.round(this._r)),this._g<1&&(this._g=Math.round(this._g)),this._b<1&&(this._b=Math.round(this._b)),this._ok=r.ok}gt.prototype={isDark:function(){return this.getBrightness()<128},isLight:function(){return!this.isDark()},isValid:function(){return this._ok},getOriginalInput:function(){return this._originalInput},getFormat:function(){return this._format},getAlpha:function(){return this._a},getBrightness:function(){var i=this.toRgb();return(i.r*299+i.g*587+i.b*114)/1e3},getLuminance:function(){var i=this.toRgb(),r,u,o,c,h,g;return r=i.r/255,u=i.g/255,o=i.b/255,r<=.03928?c=r/12.92:c=Math.pow((r+.055)/1.055,2.4),u<=.03928?h=u/12.92:h=Math.pow((u+.055)/1.055,2.4),o<=.03928?g=o/12.92:g=Math.pow((o+.055)/1.055,2.4),.2126*c+.7152*h+.0722*g},setAlpha:function(i){return this._a=Em(i),this._roundA=Math.round(100*this._a)/100,this},toHsv:function(){var i=$p(this._r,this._g,this._b);return{h:i.h*360,s:i.s,v:i.v,a:this._a}},toHsvString:function(){var i=$p(this._r,this._g,this._b),r=Math.round(i.h*360),u=Math.round(i.s*100),o=Math.round(i.v*100);return this._a==1?"hsv("+r+", "+u+"%, "+o+"%)":"hsva("+r+", "+u+"%, "+o+"%, "+this._roundA+")"},toHsl:function(){var i=Vp(this._r,this._g,this._b);return{h:i.h*360,s:i.s,l:i.l,a:this._a}},toHslString:function(){var i=Vp(this._r,this._g,this._b),r=Math.round(i.h*360),u=Math.round(i.s*100),o=Math.round(i.l*100);return this._a==1?"hsl("+r+", "+u+"%, "+o+"%)":"hsla("+r+", "+u+"%, "+o+"%, "+this._roundA+")"},toHex:function(i){return Zp(this._r,this._g,this._b,i)},toHexString:function(i){return"#"+this.toHex(i)},toHex8:function(i){return f3(this._r,this._g,this._b,this._a,i)},toHex8String:function(i){return"#"+this.toHex8(i)},toRgb:function(){return{r:Math.round(this._r),g:Math.round(this._g),b:Math.round(this._b),a:this._a}},toRgbString:function(){return this._a==1?"rgb("+Math.round(this._r)+", "+Math.round(this._g)+", "+Math.round(this._b)+")":"rgba("+Math.round(this._r)+", "+Math.round(this._g)+", "+Math.round(this._b)+", "+this._roundA+")"},toPercentageRgb:function(){return{r:Math.round(Qt(this._r,255)*100)+"%",g:Math.round(Qt(this._g,255)*100)+"%",b:Math.round(Qt(this._b,255)*100)+"%",a:this._a}},toPercentageRgbString:function(){return this._a==1?"rgb("+Math.round(Qt(this._r,255)*100)+"%, "+Math.round(Qt(this._g,255)*100)+"%, "+Math.round(Qt(this._b,255)*100)+"%)":"rgba("+Math.round(Qt(this._r,255)*100)+"%, "+Math.round(Qt(this._g,255)*100)+"%, "+Math.round(Qt(this._b,255)*100)+"%, "+this._roundA+")"},toName:function(){return this._a===0?"transparent":this._a<1?!1:S3[Zp(this._r,this._g,this._b,!0)]||!1},toFilter:function(i){var r="#"+Kp(this._r,this._g,this._b,this._a),u=r,o=this._gradientType?"GradientType = 1, ":"";if(i){var c=gt(i);u="#"+Kp(c._r,c._g,c._b,c._a)}return"progid:DXImageTransform.Microsoft.gradient("+o+"startColorstr="+r+",endColorstr="+u+")"},toString:function(i){var r=!!i;i=i||this._format;var u=!1,o=this._a<1&&this._a>=0,c=!r&&o&&(i==="hex"||i==="hex6"||i==="hex3"||i==="hex4"||i==="hex8"||i==="name");return c?i==="name"&&this._a===0?this.toName():this.toRgbString():(i==="rgb"&&(u=this.toRgbString()),i==="prgb"&&(u=this.toPercentageRgbString()),(i==="hex"||i==="hex6")&&(u=this.toHexString()),i==="hex3"&&(u=this.toHexString(!0)),i==="hex4"&&(u=this.toHex8String(!0)),i==="hex8"&&(u=this.toHex8String()),i==="name"&&(u=this.toName()),i==="hsl"&&(u=this.toHslString()),i==="hsv"&&(u=this.toHsvString()),u||this.toHexString())},clone:function(){return gt(this.toString())},_applyModification:function(i,r){var u=i.apply(null,[this].concat([].slice.call(r)));return this._r=u._r,this._g=u._g,this._b=u._b,this.setAlpha(u._a),this},lighten:function(){return this._applyModification(p3,arguments)},brighten:function(){return this._applyModification(y3,arguments)},darken:function(){return this._applyModification(m3,arguments)},desaturate:function(){return this._applyModification(h3,arguments)},saturate:function(){return this._applyModification(d3,arguments)},greyscale:function(){return this._applyModification(g3,arguments)},spin:function(){return this._applyModification(v3,arguments)},_applyCombination:function(i,r){return i.apply(null,[this].concat([].slice.call(r)))},analogous:function(){return this._applyCombination(x3,arguments)},complement:function(){return this._applyCombination(b3,arguments)},monochromatic:function(){return this._applyCombination(w3,arguments)},splitcomplement:function(){return this._applyCombination(_3,arguments)},triad:function(){return this._applyCombination(Fp,[3])},tetrad:function(){return this._applyCombination(Fp,[4])}};gt.fromRatio=function(n,i){if(ds(n)=="object"){var r={};for(var u in n)n.hasOwnProperty(u)&&(u==="a"?r[u]=n[u]:r[u]=fl(n[u]));n=r}return gt(n,i)};function u3(n){var i={r:0,g:0,b:0},r=1,u=null,o=null,c=null,h=!1,g=!1;return typeof n=="string"&&(n=O3(n)),ds(n)=="object"&&(Yn(n.r)&&Yn(n.g)&&Yn(n.b)?(i=s3(n.r,n.g,n.b),h=!0,g=String(n.r).substr(-1)==="%"?"prgb":"rgb"):Yn(n.h)&&Yn(n.s)&&Yn(n.v)?(u=fl(n.s),o=fl(n.v),i=c3(n.h,u,o),h=!0,g="hsv"):Yn(n.h)&&Yn(n.s)&&Yn(n.l)&&(u=fl(n.s),c=fl(n.l),i=o3(n.h,u,c),h=!0,g="hsl"),n.hasOwnProperty("a")&&(r=n.a)),r=Em(r),{ok:h,format:n.format||g,r:Math.min(255,Math.max(i.r,0)),g:Math.min(255,Math.max(i.g,0)),b:Math.min(255,Math.max(i.b,0)),a:r}}function s3(n,i,r){return{r:Qt(n,255)*255,g:Qt(i,255)*255,b:Qt(r,255)*255}}function Vp(n,i,r){n=Qt(n,255),i=Qt(i,255),r=Qt(r,255);var u=Math.max(n,i,r),o=Math.min(n,i,r),c,h,g=(u+o)/2;if(u==o)c=h=0;else{var y=u-o;switch(h=g>.5?y/(2-u-o):y/(u+o),u){case n:c=(i-r)/y+(i<r?6:0);break;case i:c=(r-n)/y+2;break;case r:c=(n-i)/y+4;break}c/=6}return{h:c,s:h,l:g}}function o3(n,i,r){var u,o,c;n=Qt(n,360),i=Qt(i,100),r=Qt(r,100);function h(p,v,m){return m<0&&(m+=1),m>1&&(m-=1),m<1/6?p+(v-p)*6*m:m<1/2?v:m<2/3?p+(v-p)*(2/3-m)*6:p}if(i===0)u=o=c=r;else{var g=r<.5?r*(1+i):r+i-r*i,y=2*r-g;u=h(y,g,n+1/3),o=h(y,g,n),c=h(y,g,n-1/3)}return{r:u*255,g:o*255,b:c*255}}function $p(n,i,r){n=Qt(n,255),i=Qt(i,255),r=Qt(r,255);var u=Math.max(n,i,r),o=Math.min(n,i,r),c,h,g=u,y=u-o;if(h=u===0?0:y/u,u==o)c=0;else{switch(u){case n:c=(i-r)/y+(i<r?6:0);break;case i:c=(r-n)/y+2;break;case r:c=(n-i)/y+4;break}c/=6}return{h:c,s:h,v:g}}function c3(n,i,r){n=Qt(n,360)*6,i=Qt(i,100),r=Qt(r,100);var u=Math.floor(n),o=n-u,c=r*(1-i),h=r*(1-o*i),g=r*(1-(1-o)*i),y=u%6,p=[r,h,c,c,g,r][y],v=[g,r,r,h,c,c][y],m=[c,c,g,r,r,h][y];return{r:p*255,g:v*255,b:m*255}}function Zp(n,i,r,u){var o=[un(Math.round(n).toString(16)),un(Math.round(i).toString(16)),un(Math.round(r).toString(16))];return u&&o[0].charAt(0)==o[0].charAt(1)&&o[1].charAt(0)==o[1].charAt(1)&&o[2].charAt(0)==o[2].charAt(1)?o[0].charAt(0)+o[1].charAt(0)+o[2].charAt(0):o.join("")}function f3(n,i,r,u,o){var c=[un(Math.round(n).toString(16)),un(Math.round(i).toString(16)),un(Math.round(r).toString(16)),un(Tm(u))];return o&&c[0].charAt(0)==c[0].charAt(1)&&c[1].charAt(0)==c[1].charAt(1)&&c[2].charAt(0)==c[2].charAt(1)&&c[3].charAt(0)==c[3].charAt(1)?c[0].charAt(0)+c[1].charAt(0)+c[2].charAt(0)+c[3].charAt(0):c.join("")}function Kp(n,i,r,u){var o=[un(Tm(u)),un(Math.round(n).toString(16)),un(Math.round(i).toString(16)),un(Math.round(r).toString(16))];return o.join("")}gt.equals=function(n,i){return!n||!i?!1:gt(n).toRgbString()==gt(i).toRgbString()};gt.random=function(){return gt.fromRatio({r:Math.random(),g:Math.random(),b:Math.random()})};function h3(n,i){i=i===0?0:i||10;var r=gt(n).toHsl();return r.s-=i/100,r.s=xs(r.s),gt(r)}function d3(n,i){i=i===0?0:i||10;var r=gt(n).toHsl();return r.s+=i/100,r.s=xs(r.s),gt(r)}function g3(n){return gt(n).desaturate(100)}function p3(n,i){i=i===0?0:i||10;var r=gt(n).toHsl();return r.l+=i/100,r.l=xs(r.l),gt(r)}function y3(n,i){i=i===0?0:i||10;var r=gt(n).toRgb();return r.r=Math.max(0,Math.min(255,r.r-Math.round(255*-(i/100)))),r.g=Math.max(0,Math.min(255,r.g-Math.round(255*-(i/100)))),r.b=Math.max(0,Math.min(255,r.b-Math.round(255*-(i/100)))),gt(r)}function m3(n,i){i=i===0?0:i||10;var r=gt(n).toHsl();return r.l-=i/100,r.l=xs(r.l),gt(r)}function v3(n,i){var r=gt(n).toHsl(),u=(r.h+i)%360;return r.h=u<0?360+u:u,gt(r)}function b3(n){var i=gt(n).toHsl();return i.h=(i.h+180)%360,gt(i)}function Fp(n,i){if(isNaN(i)||i<=0)throw new Error("Argument to polyad must be a positive number");for(var r=gt(n).toHsl(),u=[gt(n)],o=360/i,c=1;c<i;c++)u.push(gt({h:(r.h+c*o)%360,s:r.s,l:r.l}));return u}function _3(n){var i=gt(n).toHsl(),r=i.h;return[gt(n),gt({h:(r+72)%360,s:i.s,l:i.l}),gt({h:(r+216)%360,s:i.s,l:i.l})]}function x3(n,i,r){i=i||6,r=r||30;var u=gt(n).toHsl(),o=360/r,c=[gt(n)];for(u.h=(u.h-(o*i>>1)+720)%360;--i;)u.h=(u.h+o)%360,c.push(gt(u));return c}function w3(n,i){i=i||6;for(var r=gt(n).toHsv(),u=r.h,o=r.s,c=r.v,h=[],g=1/i;i--;)h.push(gt({h:u,s:o,v:c})),c=(c+g)%1;return h}gt.mix=function(n,i,r){r=r===0?0:r||50;var u=gt(n).toRgb(),o=gt(i).toRgb(),c=r/100,h={r:(o.r-u.r)*c+u.r,g:(o.g-u.g)*c+u.g,b:(o.b-u.b)*c+u.b,a:(o.a-u.a)*c+u.a};return gt(h)};gt.readability=function(n,i){var r=gt(n),u=gt(i);return(Math.max(r.getLuminance(),u.getLuminance())+.05)/(Math.min(r.getLuminance(),u.getLuminance())+.05)};gt.isReadable=function(n,i,r){var u=gt.readability(n,i),o,c;switch(c=!1,o=M3(r),o.level+o.size){case"AAsmall":case"AAAlarge":c=u>=4.5;break;case"AAlarge":c=u>=3;break;case"AAAsmall":c=u>=7;break}return c};gt.mostReadable=function(n,i,r){var u=null,o=0,c,h,g,y;r=r||{},h=r.includeFallbackColors,g=r.level,y=r.size;for(var p=0;p<i.length;p++)c=gt.readability(n,i[p]),c>o&&(o=c,u=gt(i[p]));return gt.isReadable(n,u,{level:g,size:y})||!h?u:(r.includeFallbackColors=!1,gt.mostReadable(n,["#fff","#000"],r))};var zf=gt.names={aliceblue:"f0f8ff",antiquewhite:"faebd7",aqua:"0ff",aquamarine:"7fffd4",azure:"f0ffff",beige:"f5f5dc",bisque:"ffe4c4",black:"000",blanchedalmond:"ffebcd",blue:"00f",blueviolet:"8a2be2",brown:"a52a2a",burlywood:"deb887",burntsienna:"ea7e5d",cadetblue:"5f9ea0",chartreuse:"7fff00",chocolate:"d2691e",coral:"ff7f50",cornflowerblue:"6495ed",cornsilk:"fff8dc",crimson:"dc143c",cyan:"0ff",darkblue:"00008b",darkcyan:"008b8b",darkgoldenrod:"b8860b",darkgray:"a9a9a9",darkgreen:"006400",darkgrey:"a9a9a9",darkkhaki:"bdb76b",darkmagenta:"8b008b",darkolivegreen:"556b2f",darkorange:"ff8c00",darkorchid:"9932cc",darkred:"8b0000",darksalmon:"e9967a",darkseagreen:"8fbc8f",darkslateblue:"483d8b",darkslategray:"2f4f4f",darkslategrey:"2f4f4f",darkturquoise:"00ced1",darkviolet:"9400d3",deeppink:"ff1493",deepskyblue:"00bfff",dimgray:"696969",dimgrey:"696969",dodgerblue:"1e90ff",firebrick:"b22222",floralwhite:"fffaf0",forestgreen:"228b22",fuchsia:"f0f",gainsboro:"dcdcdc",ghostwhite:"f8f8ff",gold:"ffd700",goldenrod:"daa520",gray:"808080",green:"008000",greenyellow:"adff2f",grey:"808080",honeydew:"f0fff0",hotpink:"ff69b4",indianred:"cd5c5c",indigo:"4b0082",ivory:"fffff0",khaki:"f0e68c",lavender:"e6e6fa",lavenderblush:"fff0f5",lawngreen:"7cfc00",lemonchiffon:"fffacd",lightblue:"add8e6",lightcoral:"f08080",lightcyan:"e0ffff",lightgoldenrodyellow:"fafad2",lightgray:"d3d3d3",lightgreen:"90ee90",lightgrey:"d3d3d3",lightpink:"ffb6c1",lightsalmon:"ffa07a",lightseagreen:"20b2aa",lightskyblue:"87cefa",lightslategray:"789",lightslategrey:"789",lightsteelblue:"b0c4de",lightyellow:"ffffe0",lime:"0f0",limegreen:"32cd32",linen:"faf0e6",magenta:"f0f",maroon:"800000",mediumaquamarine:"66cdaa",mediumblue:"0000cd",mediumorchid:"ba55d3",mediumpurple:"9370db",mediumseagreen:"3cb371",mediumslateblue:"7b68ee",mediumspringgreen:"00fa9a",mediumturquoise:"48d1cc",mediumvioletred:"c71585",midnightblue:"191970",mintcream:"f5fffa",mistyrose:"ffe4e1",moccasin:"ffe4b5",navajowhite:"ffdead",navy:"000080",oldlace:"fdf5e6",olive:"808000",olivedrab:"6b8e23",orange:"ffa500",orangered:"ff4500",orchid:"da70d6",palegoldenrod:"eee8aa",palegreen:"98fb98",paleturquoise:"afeeee",palevioletred:"db7093",papayawhip:"ffefd5",peachpuff:"ffdab9",peru:"cd853f",pink:"ffc0cb",plum:"dda0dd",powderblue:"b0e0e6",purple:"800080",rebeccapurple:"663399",red:"f00",rosybrown:"bc8f8f",royalblue:"4169e1",saddlebrown:"8b4513",salmon:"fa8072",sandybrown:"f4a460",seagreen:"2e8b57",seashell:"fff5ee",sienna:"a0522d",silver:"c0c0c0",skyblue:"87ceeb",slateblue:"6a5acd",slategray:"708090",slategrey:"708090",snow:"fffafa",springgreen:"00ff7f",steelblue:"4682b4",tan:"d2b48c",teal:"008080",thistle:"d8bfd8",tomato:"ff6347",turquoise:"40e0d0",violet:"ee82ee",wheat:"f5deb3",white:"fff",whitesmoke:"f5f5f5",yellow:"ff0",yellowgreen:"9acd32"},S3=gt.hexNames=A3(zf);function A3(n){var i={};for(var r in n)n.hasOwnProperty(r)&&(i[n[r]]=r);return i}function Em(n){return n=parseFloat(n),(isNaN(n)||n<0||n>1)&&(n=1),n}function Qt(n,i){E3(n)&&(n="100%");var r=T3(n);return n=Math.min(i,Math.max(0,parseFloat(n))),r&&(n=parseInt(n*i,10)/100),Math.abs(n-i)<1e-6?1:n%i/parseFloat(i)}function xs(n){return Math.min(1,Math.max(0,n))}function He(n){return parseInt(n,16)}function E3(n){return typeof n=="string"&&n.indexOf(".")!=-1&&parseFloat(n)===1}function T3(n){return typeof n=="string"&&n.indexOf("%")!=-1}function un(n){return n.length==1?"0"+n:""+n}function fl(n){return n<=1&&(n=n*100+"%"),n}function Tm(n){return Math.round(parseFloat(n)*255).toString(16)}function Pp(n){return He(n)/255}var rn=function(){var n="[-\\+]?\\d+%?",i="[-\\+]?\\d*\\.\\d+%?",r="(?:"+i+")|(?:"+n+")",u="[\\s|\\(]+("+r+")[,|\\s]+("+r+")[,|\\s]+("+r+")\\s*\\)?",o="[\\s|\\(]+("+r+")[,|\\s]+("+r+")[,|\\s]+("+r+")[,|\\s]+("+r+")\\s*\\)?";return{CSS_UNIT:new RegExp(r),rgb:new RegExp("rgb"+u),rgba:new RegExp("rgba"+o),hsl:new RegExp("hsl"+u),hsla:new RegExp("hsla"+o),hsv:new RegExp("hsv"+u),hsva:new RegExp("hsva"+o),hex3:/^#?([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})$/,hex6:/^#?([0-9a-fA-F]{2})([0-9a-fA-F]{2})([0-9a-fA-F]{2})$/,hex4:/^#?([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})$/,hex8:/^#?([0-9a-fA-F]{2})([0-9a-fA-F]{2})([0-9a-fA-F]{2})([0-9a-fA-F]{2})$/}}();function Yn(n){return!!rn.CSS_UNIT.exec(n)}function O3(n){n=n.replace(r3,"").replace(l3,"").toLowerCase();var i=!1;if(zf[n])n=zf[n],i=!0;else if(n=="transparent")return{r:0,g:0,b:0,a:0,format:"name"};var r;return(r=rn.rgb.exec(n))?{r:r[1],g:r[2],b:r[3]}:(r=rn.rgba.exec(n))?{r:r[1],g:r[2],b:r[3],a:r[4]}:(r=rn.hsl.exec(n))?{h:r[1],s:r[2],l:r[3]}:(r=rn.hsla.exec(n))?{h:r[1],s:r[2],l:r[3],a:r[4]}:(r=rn.hsv.exec(n))?{h:r[1],s:r[2],v:r[3]}:(r=rn.hsva.exec(n))?{h:r[1],s:r[2],v:r[3],a:r[4]}:(r=rn.hex8.exec(n))?{r:He(r[1]),g:He(r[2]),b:He(r[3]),a:Pp(r[4]),format:i?"name":"hex8"}:(r=rn.hex6.exec(n))?{r:He(r[1]),g:He(r[2]),b:He(r[3]),format:i?"name":"hex"}:(r=rn.hex4.exec(n))?{r:He(r[1]+""+r[1]),g:He(r[2]+""+r[2]),b:He(r[3]+""+r[3]),a:Pp(r[4]+""+r[4]),format:i?"name":"hex8"}:(r=rn.hex3.exec(n))?{r:He(r[1]+""+r[1]),g:He(r[2]+""+r[2]),b:He(r[3]+""+r[3]),format:i?"name":"hex"}:!1}function M3(n){var i,r;return n=n||{level:"AA",size:"small"},i=(n.level||"AA").toUpperCase(),r=(n.size||"small").toLowerCase(),i!=="AA"&&i!=="AAA"&&(i="AA"),r!=="small"&&r!=="large"&&(r="small"),{level:i,size:r}}function Rf(n,i){(i==null||i>n.length)&&(i=n.length);for(var r=0,u=Array(i);r<i;r++)u[r]=n[r];return u}function C3(n){if(Array.isArray(n))return Rf(n)}function Om(n,i,r){if(typeof n=="function"?n===i:n.has(i))return arguments.length<3?i:r;throw new TypeError("Private element is not present on this object")}function N3(n,i){if(i.has(n))throw new TypeError("Cannot initialize the same private elements twice on an object")}function z3(n,i){if(!(n instanceof i))throw new TypeError("Cannot call a class as a function")}function Pe(n,i){return n.get(Om(n,i))}function Jp(n,i,r){N3(n,i),i.set(n,r)}function Wp(n,i,r){return n.set(Om(n,i),r),r}function R3(n,i){for(var r=0;r<i.length;r++){var u=i[r];u.enumerable=u.enumerable||!1,u.configurable=!0,"value"in u&&(u.writable=!0),Object.defineProperty(n,H3(u.key),u)}}function D3(n,i,r){return i&&R3(n.prototype,i),Object.defineProperty(n,"prototype",{writable:!1}),n}function j3(n){if(typeof Symbol<"u"&&n[Symbol.iterator]!=null||n["@@iterator"]!=null)return Array.from(n)}function k3(){throw new TypeError(`Invalid attempt to spread non-iterable instance.
|
|
130
|
-
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function U3(n){return C3(n)||j3(n)||L3(n)||k3()}function q3(n,i){if(typeof n!="object"||!n)return n;var r=n[Symbol.toPrimitive];if(r!==void 0){var u=r.call(n,i);if(typeof u!="object")return u;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(n)}function H3(n){var i=q3(n,"string");return typeof i=="symbol"?i:i+""}function L3(n,i){if(n){if(typeof n=="string")return Rf(n,i);var r={}.toString.call(n).slice(8,-1);return r==="Object"&&n.constructor&&(r=n.constructor.name),r==="Map"||r==="Set"?Array.from(n):r==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?Rf(n,i):void 0}}var B3=123,G3=function(i){return"#".concat(Math.min(i,Math.pow(2,24)).toString(16).padStart(6,"0"))},Mm=function(i,r,u){return(i<<16)+(r<<8)+u},Q3=function(i){var r=gt(i).toRgb(),u=r.r,o=r.g,c=r.b;return Mm(u,o,c)},Ip=function(i,r){return i*B3%Math.pow(2,r)},$i=new WeakMap,Xn=new WeakMap,Y3=function(){function n(){var i=arguments.length>0&&arguments[0]!==void 0?arguments[0]:6;z3(this,n),Jp(this,$i,void 0),Jp(this,Xn,void 0),Wp(Xn,this,i),this.reset()}return D3(n,[{key:"reset",value:function(){Wp($i,this,["__reserved for background__"])}},{key:"register",value:function(r){if(Pe($i,this).length>=Math.pow(2,24-Pe(Xn,this)))return null;var u=Pe($i,this).length,o=Ip(u,Pe(Xn,this)),c=G3(u+(o<<24-Pe(Xn,this)));return Pe($i,this).push(r),c}},{key:"lookup",value:function(r){if(!r)return null;var u=typeof r=="string"?Q3(r):Mm.apply(void 0,U3(r));if(!u)return null;var o=u&Math.pow(2,24-Pe(Xn,this))-1,c=u>>24-Pe(Xn,this)&Math.pow(2,Pe(Xn,this))-1;return Ip(o,Pe(Xn,this))!==c||o>=Pe($i,this).length?null:Pe($i,this)[o]}}])}(),Ol,Yt,Cm,Nm,Zi,ty,zm,Rm,Dm,eh,Df,jf,xl={},jm=[],X3=/acit|ex(?:s|g|n|p|$)|rph|grid|ows|mnc|ntw|ine[ch]|zoo|^ord|itera/i,ws=Array.isArray;function bn(n,i){for(var r in i)n[r]=i[r];return n}function nh(n){n&&n.parentNode&&n.parentNode.removeChild(n)}function V3(n,i,r){var u,o,c,h={};for(c in i)c=="key"?u=i[c]:c=="ref"?o=i[c]:h[c]=i[c];if(arguments.length>2&&(h.children=arguments.length>3?Ol.call(arguments,2):r),typeof n=="function"&&n.defaultProps!=null)for(c in n.defaultProps)h[c]===void 0&&(h[c]=n.defaultProps[c]);return hl(n,h,u,o,null)}function hl(n,i,r,u,o){var c={type:n,props:i,key:r,ref:u,__k:null,__:null,__b:0,__e:null,__c:null,constructor:void 0,__v:o??++Cm,__i:-1,__u:0};return o==null&&Yt.vnode!=null&&Yt.vnode(c),c}function Ss(n){return n.children}function ns(n,i){this.props=n,this.context=i}function Pa(n,i){if(i==null)return n.__?Pa(n.__,n.__i+1):null;for(var r;i<n.__k.length;i++)if((r=n.__k[i])!=null&&r.__e!=null)return r.__e;return typeof n.type=="function"?Pa(n):null}function km(n){var i,r;if((n=n.__)!=null&&n.__c!=null){for(n.__e=n.__c.base=null,i=0;i<n.__k.length;i++)if((r=n.__k[i])!=null&&r.__e!=null){n.__e=n.__c.base=r.__e;break}return km(n)}}function ey(n){(!n.__d&&(n.__d=!0)&&Zi.push(n)&&!gs.__r++||ty!=Yt.debounceRendering)&&((ty=Yt.debounceRendering)||zm)(gs)}function gs(){for(var n,i,r,u,o,c,h,g=1;Zi.length;)Zi.length>g&&Zi.sort(Rm),n=Zi.shift(),g=Zi.length,n.__d&&(r=void 0,o=(u=(i=n).__v).__e,c=[],h=[],i.__P&&((r=bn({},u)).__v=u.__v+1,Yt.vnode&&Yt.vnode(r),ih(i.__P,r,u,i.__n,i.__P.namespaceURI,32&u.__u?[o]:null,c,o??Pa(u),!!(32&u.__u),h),r.__v=u.__v,r.__.__k[r.__i]=r,Hm(c,r,h),r.__e!=o&&km(r)));gs.__r=0}function Um(n,i,r,u,o,c,h,g,y,p,v){var m,_,x,A,M,O,S=u&&u.__k||jm,j=i.length;for(y=$3(r,i,S,y,j),m=0;m<j;m++)(x=r.__k[m])!=null&&(_=x.__i==-1?xl:S[x.__i]||xl,x.__i=m,O=ih(n,x,_,o,c,h,g,y,p,v),A=x.__e,x.ref&&_.ref!=x.ref&&(_.ref&&ah(_.ref,null,x),v.push(x.ref,x.__c||A,x)),M==null&&A!=null&&(M=A),4&x.__u||_.__k===x.__k?y=qm(x,y,n):typeof x.type=="function"&&O!==void 0?y=O:A&&(y=A.nextSibling),x.__u&=-7);return r.__e=M,y}function $3(n,i,r,u,o){var c,h,g,y,p,v=r.length,m=v,_=0;for(n.__k=new Array(o),c=0;c<o;c++)(h=i[c])!=null&&typeof h!="boolean"&&typeof h!="function"?(y=c+_,(h=n.__k[c]=typeof h=="string"||typeof h=="number"||typeof h=="bigint"||h.constructor==String?hl(null,h,null,null,null):ws(h)?hl(Ss,{children:h},null,null,null):h.constructor==null&&h.__b>0?hl(h.type,h.props,h.key,h.ref?h.ref:null,h.__v):h).__=n,h.__b=n.__b+1,g=null,(p=h.__i=Z3(h,r,y,m))!=-1&&(m--,(g=r[p])&&(g.__u|=2)),g==null||g.__v==null?(p==-1&&(o>v?_--:o<v&&_++),typeof h.type!="function"&&(h.__u|=4)):p!=y&&(p==y-1?_--:p==y+1?_++:(p>y?_--:_++,h.__u|=4))):n.__k[c]=null;if(m)for(c=0;c<v;c++)(g=r[c])!=null&&(2&g.__u)==0&&(g.__e==u&&(u=Pa(g)),Bm(g,g));return u}function qm(n,i,r){var u,o;if(typeof n.type=="function"){for(u=n.__k,o=0;u&&o<u.length;o++)u[o]&&(u[o].__=n,i=qm(u[o],i,r));return i}n.__e!=i&&(i&&n.type&&!r.contains(i)&&(i=Pa(n)),r.insertBefore(n.__e,i||null),i=n.__e);do i=i&&i.nextSibling;while(i!=null&&i.nodeType==8);return i}function Z3(n,i,r,u){var o,c,h,g=n.key,y=n.type,p=i[r],v=p!=null&&(2&p.__u)==0;if(p===null&&n.key==null||v&&g==p.key&&y==p.type)return r;if(u>(v?1:0)){for(o=r-1,c=r+1;o>=0||c<i.length;)if((p=i[h=o>=0?o--:c++])!=null&&(2&p.__u)==0&&g==p.key&&y==p.type)return h}return-1}function ny(n,i,r){i[0]=="-"?n.setProperty(i,r??""):n[i]=r==null?"":typeof r!="number"||X3.test(i)?r:r+"px"}function Pu(n,i,r,u,o){var c,h;t:if(i=="style")if(typeof r=="string")n.style.cssText=r;else{if(typeof u=="string"&&(n.style.cssText=u=""),u)for(i in u)r&&i in r||ny(n.style,i,"");if(r)for(i in r)u&&r[i]==u[i]||ny(n.style,i,r[i])}else if(i[0]=="o"&&i[1]=="n")c=i!=(i=i.replace(Dm,"$1")),h=i.toLowerCase(),i=h in n||i=="onFocusOut"||i=="onFocusIn"?h.slice(2):i.slice(2),n.l||(n.l={}),n.l[i+c]=r,r?u?r.u=u.u:(r.u=eh,n.addEventListener(i,c?jf:Df,c)):n.removeEventListener(i,c?jf:Df,c);else{if(o=="http://www.w3.org/2000/svg")i=i.replace(/xlink(H|:h)/,"h").replace(/sName$/,"s");else if(i!="width"&&i!="height"&&i!="href"&&i!="list"&&i!="form"&&i!="tabIndex"&&i!="download"&&i!="rowSpan"&&i!="colSpan"&&i!="role"&&i!="popover"&&i in n)try{n[i]=r??"";break t}catch{}typeof r=="function"||(r==null||r===!1&&i[4]!="-"?n.removeAttribute(i):n.setAttribute(i,i=="popover"&&r==1?"":r))}}function iy(n){return function(i){if(this.l){var r=this.l[i.type+n];if(i.t==null)i.t=eh++;else if(i.t<r.u)return;return r(Yt.event?Yt.event(i):i)}}}function ih(n,i,r,u,o,c,h,g,y,p){var v,m,_,x,A,M,O,S,j,H,R,C,q,U,Q,tt,F,K=i.type;if(i.constructor!=null)return null;128&r.__u&&(y=!!(32&r.__u),c=[g=i.__e=r.__e]),(v=Yt.__b)&&v(i);t:if(typeof K=="function")try{if(S=i.props,j="prototype"in K&&K.prototype.render,H=(v=K.contextType)&&u[v.__c],R=v?H?H.props.value:v.__:u,r.__c?O=(m=i.__c=r.__c).__=m.__E:(j?i.__c=m=new K(S,R):(i.__c=m=new ns(S,R),m.constructor=K,m.render=F3),H&&H.sub(m),m.props=S,m.state||(m.state={}),m.context=R,m.__n=u,_=m.__d=!0,m.__h=[],m._sb=[]),j&&m.__s==null&&(m.__s=m.state),j&&K.getDerivedStateFromProps!=null&&(m.__s==m.state&&(m.__s=bn({},m.__s)),bn(m.__s,K.getDerivedStateFromProps(S,m.__s))),x=m.props,A=m.state,m.__v=i,_)j&&K.getDerivedStateFromProps==null&&m.componentWillMount!=null&&m.componentWillMount(),j&&m.componentDidMount!=null&&m.__h.push(m.componentDidMount);else{if(j&&K.getDerivedStateFromProps==null&&S!==x&&m.componentWillReceiveProps!=null&&m.componentWillReceiveProps(S,R),!m.__e&&m.shouldComponentUpdate!=null&&m.shouldComponentUpdate(S,m.__s,R)===!1||i.__v==r.__v){for(i.__v!=r.__v&&(m.props=S,m.state=m.__s,m.__d=!1),i.__e=r.__e,i.__k=r.__k,i.__k.some(function(it){it&&(it.__=i)}),C=0;C<m._sb.length;C++)m.__h.push(m._sb[C]);m._sb=[],m.__h.length&&h.push(m);break t}m.componentWillUpdate!=null&&m.componentWillUpdate(S,m.__s,R),j&&m.componentDidUpdate!=null&&m.__h.push(function(){m.componentDidUpdate(x,A,M)})}if(m.context=R,m.props=S,m.__P=n,m.__e=!1,q=Yt.__r,U=0,j){for(m.state=m.__s,m.__d=!1,q&&q(i),v=m.render(m.props,m.state,m.context),Q=0;Q<m._sb.length;Q++)m.__h.push(m._sb[Q]);m._sb=[]}else do m.__d=!1,q&&q(i),v=m.render(m.props,m.state,m.context),m.state=m.__s;while(m.__d&&++U<25);m.state=m.__s,m.getChildContext!=null&&(u=bn(bn({},u),m.getChildContext())),j&&!_&&m.getSnapshotBeforeUpdate!=null&&(M=m.getSnapshotBeforeUpdate(x,A)),tt=v,v!=null&&v.type===Ss&&v.key==null&&(tt=Lm(v.props.children)),g=Um(n,ws(tt)?tt:[tt],i,r,u,o,c,h,g,y,p),m.base=i.__e,i.__u&=-161,m.__h.length&&h.push(m),O&&(m.__E=m.__=null)}catch(it){if(i.__v=null,y||c!=null)if(it.then){for(i.__u|=y?160:128;g&&g.nodeType==8&&g.nextSibling;)g=g.nextSibling;c[c.indexOf(g)]=null,i.__e=g}else{for(F=c.length;F--;)nh(c[F]);kf(i)}else i.__e=r.__e,i.__k=r.__k,it.then||kf(i);Yt.__e(it,i,r)}else c==null&&i.__v==r.__v?(i.__k=r.__k,i.__e=r.__e):g=i.__e=K3(r.__e,i,r,u,o,c,h,y,p);return(v=Yt.diffed)&&v(i),128&i.__u?void 0:g}function kf(n){n&&n.__c&&(n.__c.__e=!0),n&&n.__k&&n.__k.forEach(kf)}function Hm(n,i,r){for(var u=0;u<r.length;u++)ah(r[u],r[++u],r[++u]);Yt.__c&&Yt.__c(i,n),n.some(function(o){try{n=o.__h,o.__h=[],n.some(function(c){c.call(o)})}catch(c){Yt.__e(c,o.__v)}})}function Lm(n){return typeof n!="object"||n==null||n.__b&&n.__b>0?n:ws(n)?n.map(Lm):bn({},n)}function K3(n,i,r,u,o,c,h,g,y){var p,v,m,_,x,A,M,O=r.props,S=i.props,j=i.type;if(j=="svg"?o="http://www.w3.org/2000/svg":j=="math"?o="http://www.w3.org/1998/Math/MathML":o||(o="http://www.w3.org/1999/xhtml"),c!=null){for(p=0;p<c.length;p++)if((x=c[p])&&"setAttribute"in x==!!j&&(j?x.localName==j:x.nodeType==3)){n=x,c[p]=null;break}}if(n==null){if(j==null)return document.createTextNode(S);n=document.createElementNS(o,j,S.is&&S),g&&(Yt.__m&&Yt.__m(i,c),g=!1),c=null}if(j==null)O===S||g&&n.data==S||(n.data=S);else{if(c=c&&Ol.call(n.childNodes),O=r.props||xl,!g&&c!=null)for(O={},p=0;p<n.attributes.length;p++)O[(x=n.attributes[p]).name]=x.value;for(p in O)if(x=O[p],p!="children"){if(p=="dangerouslySetInnerHTML")m=x;else if(!(p in S)){if(p=="value"&&"defaultValue"in S||p=="checked"&&"defaultChecked"in S)continue;Pu(n,p,null,x,o)}}for(p in S)x=S[p],p=="children"?_=x:p=="dangerouslySetInnerHTML"?v=x:p=="value"?A=x:p=="checked"?M=x:g&&typeof x!="function"||O[p]===x||Pu(n,p,x,O[p],o);if(v)g||m&&(v.__html==m.__html||v.__html==n.innerHTML)||(n.innerHTML=v.__html),i.__k=[];else if(m&&(n.innerHTML=""),Um(i.type=="template"?n.content:n,ws(_)?_:[_],i,r,u,j=="foreignObject"?"http://www.w3.org/1999/xhtml":o,c,h,c?c[0]:r.__k&&Pa(r,0),g,y),c!=null)for(p=c.length;p--;)nh(c[p]);g||(p="value",j=="progress"&&A==null?n.removeAttribute("value"):A!=null&&(A!==n[p]||j=="progress"&&!A||j=="option"&&A!=O[p])&&Pu(n,p,A,O[p],o),p="checked",M!=null&&M!=n[p]&&Pu(n,p,M,O[p],o))}return n}function ah(n,i,r){try{if(typeof n=="function"){var u=typeof n.__u=="function";u&&n.__u(),u&&i==null||(n.__u=n(i))}else n.current=i}catch(o){Yt.__e(o,r)}}function Bm(n,i,r){var u,o;if(Yt.unmount&&Yt.unmount(n),(u=n.ref)&&(u.current&&u.current!=n.__e||ah(u,null,i)),(u=n.__c)!=null){if(u.componentWillUnmount)try{u.componentWillUnmount()}catch(c){Yt.__e(c,i)}u.base=u.__P=null}if(u=n.__k)for(o=0;o<u.length;o++)u[o]&&Bm(u[o],i,r||typeof n.type!="function");r||nh(n.__e),n.__c=n.__=n.__e=void 0}function F3(n,i,r){return this.constructor(n,r)}function P3(n,i,r){var u,o,c,h;i==document&&(i=document.documentElement),Yt.__&&Yt.__(n,i),o=(u=!1)?null:i.__k,c=[],h=[],ih(i,n=i.__k=V3(Ss,null,[n]),o||xl,xl,i.namespaceURI,o?null:i.firstChild?Ol.call(i.childNodes):null,c,o?o.__e:i.firstChild,u,h),Hm(c,n,h)}function Gm(n,i,r){var u,o,c,h,g=bn({},n.props);for(c in n.type&&n.type.defaultProps&&(h=n.type.defaultProps),i)c=="key"?u=i[c]:c=="ref"?o=i[c]:g[c]=i[c]===void 0&&h!=null?h[c]:i[c];return arguments.length>2&&(g.children=arguments.length>3?Ol.call(arguments,2):r),hl(n.type,g,u||n.key,o||n.ref,null)}Ol=jm.slice,Yt={__e:function(n,i,r,u){for(var o,c,h;i=i.__;)if((o=i.__c)&&!o.__)try{if((c=o.constructor)&&c.getDerivedStateFromError!=null&&(o.setState(c.getDerivedStateFromError(n)),h=o.__d),o.componentDidCatch!=null&&(o.componentDidCatch(n,u||{}),h=o.__d),h)return o.__E=o}catch(g){n=g}throw n}},Cm=0,Nm=function(n){return n!=null&&n.constructor==null},ns.prototype.setState=function(n,i){var r;r=this.__s!=null&&this.__s!=this.state?this.__s:this.__s=bn({},this.state),typeof n=="function"&&(n=n(bn({},r),this.props)),n&&bn(r,n),n!=null&&this.__v&&(i&&this._sb.push(i),ey(this))},ns.prototype.forceUpdate=function(n){this.__v&&(this.__e=!0,n&&this.__h.push(n),ey(this))},ns.prototype.render=Ss,Zi=[],zm=typeof Promise=="function"?Promise.prototype.then.bind(Promise.resolve()):setTimeout,Rm=function(n,i){return n.__v.__b-i.__v.__b},gs.__r=0,Dm=/(PointerCapture)$|Capture$/i,eh=0,Df=iy(!1),jf=iy(!0);function ay(n,i){(i==null||i>n.length)&&(i=n.length);for(var r=0,u=Array(i);r<i;r++)u[r]=n[r];return u}function J3(n){if(Array.isArray(n))return n}function W3(n,i,r){return(i=a4(i))in n?Object.defineProperty(n,i,{value:r,enumerable:!0,configurable:!0,writable:!0}):n[i]=r,n}function I3(n,i){var r=n==null?null:typeof Symbol<"u"&&n[Symbol.iterator]||n["@@iterator"];if(r!=null){var u,o,c,h,g=[],y=!0,p=!1;try{if(c=(r=r.call(n)).next,i!==0)for(;!(y=(u=c.call(r)).done)&&(g.push(u.value),g.length!==i);y=!0);}catch(v){p=!0,o=v}finally{try{if(!y&&r.return!=null&&(h=r.return(),Object(h)!==h))return}finally{if(p)throw o}}return g}}function t4(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
|
|
131
|
-
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function ry(n,i){var r=Object.keys(n);if(Object.getOwnPropertySymbols){var u=Object.getOwnPropertySymbols(n);i&&(u=u.filter(function(o){return Object.getOwnPropertyDescriptor(n,o).enumerable})),r.push.apply(r,u)}return r}function e4(n){for(var i=1;i<arguments.length;i++){var r=arguments[i]!=null?arguments[i]:{};i%2?ry(Object(r),!0).forEach(function(u){W3(n,u,r[u])}):Object.getOwnPropertyDescriptors?Object.defineProperties(n,Object.getOwnPropertyDescriptors(r)):ry(Object(r)).forEach(function(u){Object.defineProperty(n,u,Object.getOwnPropertyDescriptor(r,u))})}return n}function n4(n,i){return J3(n)||I3(n,i)||r4(n,i)||t4()}function i4(n,i){if(typeof n!="object"||!n)return n;var r=n[Symbol.toPrimitive];if(r!==void 0){var u=r.call(n,i);if(typeof u!="object")return u;throw new TypeError("@@toPrimitive must return a primitive value.")}return(i==="string"?String:Number)(n)}function a4(n){var i=i4(n,"string");return typeof i=="symbol"?i:i+""}function ps(n){"@babel/helpers - typeof";return ps=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(i){return typeof i}:function(i){return i&&typeof Symbol=="function"&&i.constructor===Symbol&&i!==Symbol.prototype?"symbol":typeof i},ps(n)}function r4(n,i){if(n){if(typeof n=="string")return ay(n,i);var r={}.toString.call(n).slice(8,-1);return r==="Object"&&n.constructor&&(r=n.constructor.name),r==="Map"||r==="Set"?Array.from(n):r==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?ay(n,i):void 0}}var Uf=function(i){if(ps(i)!=="object")return i;var r=Gm(i);if(r.props){var u;r.props=e4({},r.props),r!=null&&(u=r.props)!==null&&u!==void 0&&u.children&&(r.props.children=Array.isArray(r.props.children)?r.props.children.map(Uf):Uf(r.props.children))}return r},l4=function(i){return Nm(Gm(i))},u4=function(i,r){delete r.__k,P3(Uf(i),r)};function s4(n,i){i===void 0&&(i={});var r=i.insertAt;if(!(typeof document>"u")){var u=document.head||document.getElementsByTagName("head")[0],o=document.createElement("style");o.type="text/css",r==="top"&&u.firstChild?u.insertBefore(o,u.firstChild):u.appendChild(o),o.styleSheet?o.styleSheet.cssText=n:o.appendChild(document.createTextNode(n))}}var o4=`.float-tooltip-kap {
|
|
132
|
-
position: absolute;
|
|
133
|
-
width: max-content; /* prevent shrinking near right edge */
|
|
134
|
-
max-width: max(50%, 150px);
|
|
135
|
-
padding: 3px 5px;
|
|
136
|
-
border-radius: 3px;
|
|
137
|
-
font: 12px sans-serif;
|
|
138
|
-
color: #eee;
|
|
139
|
-
background: rgba(0,0,0,0.6);
|
|
140
|
-
pointer-events: none;
|
|
141
|
-
}
|
|
142
|
-
`;s4(o4);var c4=th({props:{content:{default:!1},offsetX:{triggerUpdate:!1},offsetY:{triggerUpdate:!1}},init:function(i,r){var u=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},o=u.style,c=o===void 0?{}:o,h=!!i&&ps(i)==="object"&&!!i.node&&typeof i.node=="function",g=Ie(h?i.node():i);g.style("position")==="static"&&g.style("position","relative"),r.tooltipEl=g.append("div").attr("class","float-tooltip-kap"),Object.entries(c).forEach(function(p){var v=n4(p,2),m=v[0],_=v[1];return r.tooltipEl.style(m,_)}),r.tooltipEl.style("left","-10000px").style("display","none");var y="tooltip-".concat(Math.round(Math.random()*1e12));r.mouseInside=!1,g.on("mousemove.".concat(y),function(p){r.mouseInside=!0;var v=vn(p),m=g.node(),_=m.offsetWidth,x=m.offsetHeight,A=[r.offsetX===null||r.offsetX===void 0?"-".concat(v[0]/_*100,"%"):typeof r.offsetX=="number"?"calc(-50% + ".concat(r.offsetX,"px)"):r.offsetX,r.offsetY===null||r.offsetY===void 0?x>130&&x-v[1]<100?"calc(-100% - 6px)":"21px":typeof r.offsetY=="number"?r.offsetY<0?"calc(-100% - ".concat(Math.abs(r.offsetY),"px)"):"".concat(r.offsetY,"px"):r.offsetY];r.tooltipEl.style("left",v[0]+"px").style("top",v[1]+"px").style("transform","translate(".concat(A.join(","),")")),r.content&&r.tooltipEl.style("display","inline")}),g.on("mouseover.".concat(y),function(){r.mouseInside=!0,r.content&&r.tooltipEl.style("display","inline")}),g.on("mouseout.".concat(y),function(){r.mouseInside=!1,r.tooltipEl.style("display","none")})},update:function(i){i.tooltipEl.style("display",i.content&&i.mouseInside?"inline":"none"),i.content?i.content instanceof HTMLElement?(i.tooltipEl.text(""),i.tooltipEl.append(function(){return i.content})):typeof i.content=="string"?i.tooltipEl.html(i.content):l4(i.content)?(i.tooltipEl.text(""),u4(i.content,i.tooltipEl.node())):(i.tooltipEl.style("display","none"),console.warn("Tooltip content is invalid, skipping.",i.content,i.content.toString())):i.tooltipEl.text("")}});function f4(n,i,r){var u,o=1;n==null&&(n=0),i==null&&(i=0),r==null&&(r=0);function c(){var h,g=u.length,y,p=0,v=0,m=0;for(h=0;h<g;++h)y=u[h],p+=y.x||0,v+=y.y||0,m+=y.z||0;for(p=(p/g-n)*o,v=(v/g-i)*o,m=(m/g-r)*o,h=0;h<g;++h)y=u[h],p&&(y.x-=p),v&&(y.y-=v),m&&(y.z-=m)}return c.initialize=function(h){u=h},c.x=function(h){return arguments.length?(n=+h,c):n},c.y=function(h){return arguments.length?(i=+h,c):i},c.z=function(h){return arguments.length?(r=+h,c):r},c.strength=function(h){return arguments.length?(o=+h,c):o},c}function h4(n){const i=+this._x.call(null,n);return Qm(this.cover(i),i,n)}function Qm(n,i,r){if(isNaN(i))return n;var u,o=n._root,c={data:r},h=n._x0,g=n._x1,y,p,v,m,_;if(!o)return n._root=c,n;for(;o.length;)if((v=i>=(y=(h+g)/2))?h=y:g=y,u=o,!(o=o[m=+v]))return u[m]=c,n;if(p=+n._x.call(null,o.data),i===p)return c.next=o,u?u[m]=c:n._root=c,n;do u=u?u[m]=new Array(2):n._root=new Array(2),(v=i>=(y=(h+g)/2))?h=y:g=y;while((m=+v)==(_=+(p>=y)));return u[_]=o,u[m]=c,n}function d4(n){Array.isArray(n)||(n=Array.from(n));const i=n.length,r=new Float64Array(i);let u=1/0,o=-1/0;for(let c=0,h;c<i;++c)isNaN(h=+this._x.call(null,n[c]))||(r[c]=h,h<u&&(u=h),h>o&&(o=h));if(u>o)return this;this.cover(u).cover(o);for(let c=0;c<i;++c)Qm(this,r[c],n[c]);return this}function g4(n){if(isNaN(n=+n))return this;var i=this._x0,r=this._x1;if(isNaN(i))r=(i=Math.floor(n))+1;else{for(var u=r-i||1,o=this._root,c,h;i>n||n>=r;)switch(h=+(n<i),c=new Array(2),c[h]=o,o=c,u*=2,h){case 0:r=i+u;break;case 1:i=r-u;break}this._root&&this._root.length&&(this._root=o)}return this._x0=i,this._x1=r,this}function p4(){var n=[];return this.visit(function(i){if(!i.length)do n.push(i.data);while(i=i.next)}),n}function y4(n){return arguments.length?this.cover(+n[0][0]).cover(+n[1][0]):isNaN(this._x0)?void 0:[[this._x0],[this._x1]]}function Fn(n,i,r){this.node=n,this.x0=i,this.x1=r}function m4(n,i){var r,u=this._x0,o,c,h=this._x1,g=[],y=this._root,p,v;for(y&&g.push(new Fn(y,u,h)),i==null?i=1/0:(u=n-i,h=n+i);p=g.pop();)if(!(!(y=p.node)||(o=p.x0)>h||(c=p.x1)<u))if(y.length){var m=(o+c)/2;g.push(new Fn(y[1],m,c),new Fn(y[0],o,m)),(v=+(n>=m))&&(p=g[g.length-1],g[g.length-1]=g[g.length-1-v],g[g.length-1-v]=p)}else{var _=Math.abs(n-+this._x.call(null,y.data));_<i&&(i=_,u=n-_,h=n+_,r=y.data)}return r}function v4(n){if(isNaN(y=+this._x.call(null,n)))return this;var i,r=this._root,u,o,c,h=this._x0,g=this._x1,y,p,v,m,_;if(!r)return this;if(r.length)for(;;){if((v=y>=(p=(h+g)/2))?h=p:g=p,i=r,!(r=r[m=+v]))return this;if(!r.length)break;i[m+1&1]&&(u=i,_=m)}for(;r.data!==n;)if(o=r,!(r=r.next))return this;return(c=r.next)&&delete r.next,o?(c?o.next=c:delete o.next,this):i?(c?i[m]=c:delete i[m],(r=i[0]||i[1])&&r===(i[1]||i[0])&&!r.length&&(u?u[_]=r:this._root=r),this):(this._root=c,this)}function b4(n){for(var i=0,r=n.length;i<r;++i)this.remove(n[i]);return this}function _4(){return this._root}function x4(){var n=0;return this.visit(function(i){if(!i.length)do++n;while(i=i.next)}),n}function w4(n){var i=[],r,u=this._root,o,c,h;for(u&&i.push(new Fn(u,this._x0,this._x1));r=i.pop();)if(!n(u=r.node,c=r.x0,h=r.x1)&&u.length){var g=(c+h)/2;(o=u[1])&&i.push(new Fn(o,g,h)),(o=u[0])&&i.push(new Fn(o,c,g))}return this}function S4(n){var i=[],r=[],u;for(this._root&&i.push(new Fn(this._root,this._x0,this._x1));u=i.pop();){var o=u.node;if(o.length){var c,h=u.x0,g=u.x1,y=(h+g)/2;(c=o[0])&&i.push(new Fn(c,h,y)),(c=o[1])&&i.push(new Fn(c,y,g))}r.push(u)}for(;u=r.pop();)n(u.node,u.x0,u.x1);return this}function A4(n){return n[0]}function E4(n){return arguments.length?(this._x=n,this):this._x}function Ym(n,i){var r=new rh(i??A4,NaN,NaN);return n==null?r:r.addAll(n)}function rh(n,i,r){this._x=n,this._x0=i,this._x1=r,this._root=void 0}function ly(n){for(var i={data:n.data},r=i;n=n.next;)r=r.next={data:n.data};return i}var Ne=Ym.prototype=rh.prototype;Ne.copy=function(){var n=new rh(this._x,this._x0,this._x1),i=this._root,r,u;if(!i)return n;if(!i.length)return n._root=ly(i),n;for(r=[{source:i,target:n._root=new Array(2)}];i=r.pop();)for(var o=0;o<2;++o)(u=i.source[o])&&(u.length?r.push({source:u,target:i.target[o]=new Array(2)}):i.target[o]=ly(u));return n};Ne.add=h4;Ne.addAll=d4;Ne.cover=g4;Ne.data=p4;Ne.extent=y4;Ne.find=m4;Ne.remove=v4;Ne.removeAll=b4;Ne.root=_4;Ne.size=x4;Ne.visit=w4;Ne.visitAfter=S4;Ne.x=E4;function T4(n){const i=+this._x.call(null,n),r=+this._y.call(null,n);return Xm(this.cover(i,r),i,r,n)}function Xm(n,i,r,u){if(isNaN(i)||isNaN(r))return n;var o,c=n._root,h={data:u},g=n._x0,y=n._y0,p=n._x1,v=n._y1,m,_,x,A,M,O,S,j;if(!c)return n._root=h,n;for(;c.length;)if((M=i>=(m=(g+p)/2))?g=m:p=m,(O=r>=(_=(y+v)/2))?y=_:v=_,o=c,!(c=c[S=O<<1|M]))return o[S]=h,n;if(x=+n._x.call(null,c.data),A=+n._y.call(null,c.data),i===x&&r===A)return h.next=c,o?o[S]=h:n._root=h,n;do o=o?o[S]=new Array(4):n._root=new Array(4),(M=i>=(m=(g+p)/2))?g=m:p=m,(O=r>=(_=(y+v)/2))?y=_:v=_;while((S=O<<1|M)===(j=(A>=_)<<1|x>=m));return o[j]=c,o[S]=h,n}function O4(n){var i,r,u=n.length,o,c,h=new Array(u),g=new Array(u),y=1/0,p=1/0,v=-1/0,m=-1/0;for(r=0;r<u;++r)isNaN(o=+this._x.call(null,i=n[r]))||isNaN(c=+this._y.call(null,i))||(h[r]=o,g[r]=c,o<y&&(y=o),o>v&&(v=o),c<p&&(p=c),c>m&&(m=c));if(y>v||p>m)return this;for(this.cover(y,p).cover(v,m),r=0;r<u;++r)Xm(this,h[r],g[r],n[r]);return this}function M4(n,i){if(isNaN(n=+n)||isNaN(i=+i))return this;var r=this._x0,u=this._y0,o=this._x1,c=this._y1;if(isNaN(r))o=(r=Math.floor(n))+1,c=(u=Math.floor(i))+1;else{for(var h=o-r||1,g=this._root,y,p;r>n||n>=o||u>i||i>=c;)switch(p=(i<u)<<1|n<r,y=new Array(4),y[p]=g,g=y,h*=2,p){case 0:o=r+h,c=u+h;break;case 1:r=o-h,c=u+h;break;case 2:o=r+h,u=c-h;break;case 3:r=o-h,u=c-h;break}this._root&&this._root.length&&(this._root=g)}return this._x0=r,this._y0=u,this._x1=o,this._y1=c,this}function C4(){var n=[];return this.visit(function(i){if(!i.length)do n.push(i.data);while(i=i.next)}),n}function N4(n){return arguments.length?this.cover(+n[0][0],+n[0][1]).cover(+n[1][0],+n[1][1]):isNaN(this._x0)?void 0:[[this._x0,this._y0],[this._x1,this._y1]]}function we(n,i,r,u,o){this.node=n,this.x0=i,this.y0=r,this.x1=u,this.y1=o}function z4(n,i,r){var u,o=this._x0,c=this._y0,h,g,y,p,v=this._x1,m=this._y1,_=[],x=this._root,A,M;for(x&&_.push(new we(x,o,c,v,m)),r==null?r=1/0:(o=n-r,c=i-r,v=n+r,m=i+r,r*=r);A=_.pop();)if(!(!(x=A.node)||(h=A.x0)>v||(g=A.y0)>m||(y=A.x1)<o||(p=A.y1)<c))if(x.length){var O=(h+y)/2,S=(g+p)/2;_.push(new we(x[3],O,S,y,p),new we(x[2],h,S,O,p),new we(x[1],O,g,y,S),new we(x[0],h,g,O,S)),(M=(i>=S)<<1|n>=O)&&(A=_[_.length-1],_[_.length-1]=_[_.length-1-M],_[_.length-1-M]=A)}else{var j=n-+this._x.call(null,x.data),H=i-+this._y.call(null,x.data),R=j*j+H*H;if(R<r){var C=Math.sqrt(r=R);o=n-C,c=i-C,v=n+C,m=i+C,u=x.data}}return u}function R4(n){if(isNaN(v=+this._x.call(null,n))||isNaN(m=+this._y.call(null,n)))return this;var i,r=this._root,u,o,c,h=this._x0,g=this._y0,y=this._x1,p=this._y1,v,m,_,x,A,M,O,S;if(!r)return this;if(r.length)for(;;){if((A=v>=(_=(h+y)/2))?h=_:y=_,(M=m>=(x=(g+p)/2))?g=x:p=x,i=r,!(r=r[O=M<<1|A]))return this;if(!r.length)break;(i[O+1&3]||i[O+2&3]||i[O+3&3])&&(u=i,S=O)}for(;r.data!==n;)if(o=r,!(r=r.next))return this;return(c=r.next)&&delete r.next,o?(c?o.next=c:delete o.next,this):i?(c?i[O]=c:delete i[O],(r=i[0]||i[1]||i[2]||i[3])&&r===(i[3]||i[2]||i[1]||i[0])&&!r.length&&(u?u[S]=r:this._root=r),this):(this._root=c,this)}function D4(n){for(var i=0,r=n.length;i<r;++i)this.remove(n[i]);return this}function j4(){return this._root}function k4(){var n=0;return this.visit(function(i){if(!i.length)do++n;while(i=i.next)}),n}function U4(n){var i=[],r,u=this._root,o,c,h,g,y;for(u&&i.push(new we(u,this._x0,this._y0,this._x1,this._y1));r=i.pop();)if(!n(u=r.node,c=r.x0,h=r.y0,g=r.x1,y=r.y1)&&u.length){var p=(c+g)/2,v=(h+y)/2;(o=u[3])&&i.push(new we(o,p,v,g,y)),(o=u[2])&&i.push(new we(o,c,v,p,y)),(o=u[1])&&i.push(new we(o,p,h,g,v)),(o=u[0])&&i.push(new we(o,c,h,p,v))}return this}function q4(n){var i=[],r=[],u;for(this._root&&i.push(new we(this._root,this._x0,this._y0,this._x1,this._y1));u=i.pop();){var o=u.node;if(o.length){var c,h=u.x0,g=u.y0,y=u.x1,p=u.y1,v=(h+y)/2,m=(g+p)/2;(c=o[0])&&i.push(new we(c,h,g,v,m)),(c=o[1])&&i.push(new we(c,v,g,y,m)),(c=o[2])&&i.push(new we(c,h,m,v,p)),(c=o[3])&&i.push(new we(c,v,m,y,p))}r.push(u)}for(;u=r.pop();)n(u.node,u.x0,u.y0,u.x1,u.y1);return this}function H4(n){return n[0]}function L4(n){return arguments.length?(this._x=n,this):this._x}function B4(n){return n[1]}function G4(n){return arguments.length?(this._y=n,this):this._y}function Vm(n,i,r){var u=new lh(i??H4,r??B4,NaN,NaN,NaN,NaN);return n==null?u:u.addAll(n)}function lh(n,i,r,u,o,c){this._x=n,this._y=i,this._x0=r,this._y0=u,this._x1=o,this._y1=c,this._root=void 0}function uy(n){for(var i={data:n.data},r=i;n=n.next;)r=r.next={data:n.data};return i}var Se=Vm.prototype=lh.prototype;Se.copy=function(){var n=new lh(this._x,this._y,this._x0,this._y0,this._x1,this._y1),i=this._root,r,u;if(!i)return n;if(!i.length)return n._root=uy(i),n;for(r=[{source:i,target:n._root=new Array(4)}];i=r.pop();)for(var o=0;o<4;++o)(u=i.source[o])&&(u.length?r.push({source:u,target:i.target[o]=new Array(4)}):i.target[o]=uy(u));return n};Se.add=T4;Se.addAll=O4;Se.cover=M4;Se.data=C4;Se.extent=N4;Se.find=z4;Se.remove=R4;Se.removeAll=D4;Se.root=j4;Se.size=k4;Se.visit=U4;Se.visitAfter=q4;Se.x=L4;Se.y=G4;function Q4(n){const i=+this._x.call(null,n),r=+this._y.call(null,n),u=+this._z.call(null,n);return $m(this.cover(i,r,u),i,r,u,n)}function $m(n,i,r,u,o){if(isNaN(i)||isNaN(r)||isNaN(u))return n;var c,h=n._root,g={data:o},y=n._x0,p=n._y0,v=n._z0,m=n._x1,_=n._y1,x=n._z1,A,M,O,S,j,H,R,C,q,U,Q;if(!h)return n._root=g,n;for(;h.length;)if((R=i>=(A=(y+m)/2))?y=A:m=A,(C=r>=(M=(p+_)/2))?p=M:_=M,(q=u>=(O=(v+x)/2))?v=O:x=O,c=h,!(h=h[U=q<<2|C<<1|R]))return c[U]=g,n;if(S=+n._x.call(null,h.data),j=+n._y.call(null,h.data),H=+n._z.call(null,h.data),i===S&&r===j&&u===H)return g.next=h,c?c[U]=g:n._root=g,n;do c=c?c[U]=new Array(8):n._root=new Array(8),(R=i>=(A=(y+m)/2))?y=A:m=A,(C=r>=(M=(p+_)/2))?p=M:_=M,(q=u>=(O=(v+x)/2))?v=O:x=O;while((U=q<<2|C<<1|R)===(Q=(H>=O)<<2|(j>=M)<<1|S>=A));return c[Q]=h,c[U]=g,n}function Y4(n){Array.isArray(n)||(n=Array.from(n));const i=n.length,r=new Float64Array(i),u=new Float64Array(i),o=new Float64Array(i);let c=1/0,h=1/0,g=1/0,y=-1/0,p=-1/0,v=-1/0;for(let m=0,_,x,A,M;m<i;++m)isNaN(x=+this._x.call(null,_=n[m]))||isNaN(A=+this._y.call(null,_))||isNaN(M=+this._z.call(null,_))||(r[m]=x,u[m]=A,o[m]=M,x<c&&(c=x),x>y&&(y=x),A<h&&(h=A),A>p&&(p=A),M<g&&(g=M),M>v&&(v=M));if(c>y||h>p||g>v)return this;this.cover(c,h,g).cover(y,p,v);for(let m=0;m<i;++m)$m(this,r[m],u[m],o[m],n[m]);return this}function X4(n,i,r){if(isNaN(n=+n)||isNaN(i=+i)||isNaN(r=+r))return this;var u=this._x0,o=this._y0,c=this._z0,h=this._x1,g=this._y1,y=this._z1;if(isNaN(u))h=(u=Math.floor(n))+1,g=(o=Math.floor(i))+1,y=(c=Math.floor(r))+1;else{for(var p=h-u||1,v=this._root,m,_;u>n||n>=h||o>i||i>=g||c>r||r>=y;)switch(_=(r<c)<<2|(i<o)<<1|n<u,m=new Array(8),m[_]=v,v=m,p*=2,_){case 0:h=u+p,g=o+p,y=c+p;break;case 1:u=h-p,g=o+p,y=c+p;break;case 2:h=u+p,o=g-p,y=c+p;break;case 3:u=h-p,o=g-p,y=c+p;break;case 4:h=u+p,g=o+p,c=y-p;break;case 5:u=h-p,g=o+p,c=y-p;break;case 6:h=u+p,o=g-p,c=y-p;break;case 7:u=h-p,o=g-p,c=y-p;break}this._root&&this._root.length&&(this._root=v)}return this._x0=u,this._y0=o,this._z0=c,this._x1=h,this._y1=g,this._z1=y,this}function V4(){var n=[];return this.visit(function(i){if(!i.length)do n.push(i.data);while(i=i.next)}),n}function $4(n){return arguments.length?this.cover(+n[0][0],+n[0][1],+n[0][2]).cover(+n[1][0],+n[1][1],+n[1][2]):isNaN(this._x0)?void 0:[[this._x0,this._y0,this._z0],[this._x1,this._y1,this._z1]]}function Ht(n,i,r,u,o,c,h){this.node=n,this.x0=i,this.y0=r,this.z0=u,this.x1=o,this.y1=c,this.z1=h}function Z4(n,i,r,u){var o,c=this._x0,h=this._y0,g=this._z0,y,p,v,m,_,x,A=this._x1,M=this._y1,O=this._z1,S=[],j=this._root,H,R;for(j&&S.push(new Ht(j,c,h,g,A,M,O)),u==null?u=1/0:(c=n-u,h=i-u,g=r-u,A=n+u,M=i+u,O=r+u,u*=u);H=S.pop();)if(!(!(j=H.node)||(y=H.x0)>A||(p=H.y0)>M||(v=H.z0)>O||(m=H.x1)<c||(_=H.y1)<h||(x=H.z1)<g))if(j.length){var C=(y+m)/2,q=(p+_)/2,U=(v+x)/2;S.push(new Ht(j[7],C,q,U,m,_,x),new Ht(j[6],y,q,U,C,_,x),new Ht(j[5],C,p,U,m,q,x),new Ht(j[4],y,p,U,C,q,x),new Ht(j[3],C,q,v,m,_,U),new Ht(j[2],y,q,v,C,_,U),new Ht(j[1],C,p,v,m,q,U),new Ht(j[0],y,p,v,C,q,U)),(R=(r>=U)<<2|(i>=q)<<1|n>=C)&&(H=S[S.length-1],S[S.length-1]=S[S.length-1-R],S[S.length-1-R]=H)}else{var Q=n-+this._x.call(null,j.data),tt=i-+this._y.call(null,j.data),F=r-+this._z.call(null,j.data),K=Q*Q+tt*tt+F*F;if(K<u){var it=Math.sqrt(u=K);c=n-it,h=i-it,g=r-it,A=n+it,M=i+it,O=r+it,o=j.data}}return o}const K4=(n,i,r,u,o,c)=>Math.sqrt((n-u)**2+(i-o)**2+(r-c)**2);function F4(n,i,r,u){const o=[],c=n-u,h=i-u,g=r-u,y=n+u,p=i+u,v=r+u;return this.visit((m,_,x,A,M,O,S)=>{if(!m.length)do{const j=m.data;K4(n,i,r,this._x(j),this._y(j),this._z(j))<=u&&o.push(j)}while(m=m.next);return _>y||x>p||A>v||M<c||O<h||S<g}),o}function P4(n){if(isNaN(_=+this._x.call(null,n))||isNaN(x=+this._y.call(null,n))||isNaN(A=+this._z.call(null,n)))return this;var i,r=this._root,u,o,c,h=this._x0,g=this._y0,y=this._z0,p=this._x1,v=this._y1,m=this._z1,_,x,A,M,O,S,j,H,R,C,q;if(!r)return this;if(r.length)for(;;){if((j=_>=(M=(h+p)/2))?h=M:p=M,(H=x>=(O=(g+v)/2))?g=O:v=O,(R=A>=(S=(y+m)/2))?y=S:m=S,i=r,!(r=r[C=R<<2|H<<1|j]))return this;if(!r.length)break;(i[C+1&7]||i[C+2&7]||i[C+3&7]||i[C+4&7]||i[C+5&7]||i[C+6&7]||i[C+7&7])&&(u=i,q=C)}for(;r.data!==n;)if(o=r,!(r=r.next))return this;return(c=r.next)&&delete r.next,o?(c?o.next=c:delete o.next,this):i?(c?i[C]=c:delete i[C],(r=i[0]||i[1]||i[2]||i[3]||i[4]||i[5]||i[6]||i[7])&&r===(i[7]||i[6]||i[5]||i[4]||i[3]||i[2]||i[1]||i[0])&&!r.length&&(u?u[q]=r:this._root=r),this):(this._root=c,this)}function J4(n){for(var i=0,r=n.length;i<r;++i)this.remove(n[i]);return this}function W4(){return this._root}function I4(){var n=0;return this.visit(function(i){if(!i.length)do++n;while(i=i.next)}),n}function tA(n){var i=[],r,u=this._root,o,c,h,g,y,p,v;for(u&&i.push(new Ht(u,this._x0,this._y0,this._z0,this._x1,this._y1,this._z1));r=i.pop();)if(!n(u=r.node,c=r.x0,h=r.y0,g=r.z0,y=r.x1,p=r.y1,v=r.z1)&&u.length){var m=(c+y)/2,_=(h+p)/2,x=(g+v)/2;(o=u[7])&&i.push(new Ht(o,m,_,x,y,p,v)),(o=u[6])&&i.push(new Ht(o,c,_,x,m,p,v)),(o=u[5])&&i.push(new Ht(o,m,h,x,y,_,v)),(o=u[4])&&i.push(new Ht(o,c,h,x,m,_,v)),(o=u[3])&&i.push(new Ht(o,m,_,g,y,p,x)),(o=u[2])&&i.push(new Ht(o,c,_,g,m,p,x)),(o=u[1])&&i.push(new Ht(o,m,h,g,y,_,x)),(o=u[0])&&i.push(new Ht(o,c,h,g,m,_,x))}return this}function eA(n){var i=[],r=[],u;for(this._root&&i.push(new Ht(this._root,this._x0,this._y0,this._z0,this._x1,this._y1,this._z1));u=i.pop();){var o=u.node;if(o.length){var c,h=u.x0,g=u.y0,y=u.z0,p=u.x1,v=u.y1,m=u.z1,_=(h+p)/2,x=(g+v)/2,A=(y+m)/2;(c=o[0])&&i.push(new Ht(c,h,g,y,_,x,A)),(c=o[1])&&i.push(new Ht(c,_,g,y,p,x,A)),(c=o[2])&&i.push(new Ht(c,h,x,y,_,v,A)),(c=o[3])&&i.push(new Ht(c,_,x,y,p,v,A)),(c=o[4])&&i.push(new Ht(c,h,g,A,_,x,m)),(c=o[5])&&i.push(new Ht(c,_,g,A,p,x,m)),(c=o[6])&&i.push(new Ht(c,h,x,A,_,v,m)),(c=o[7])&&i.push(new Ht(c,_,x,A,p,v,m))}r.push(u)}for(;u=r.pop();)n(u.node,u.x0,u.y0,u.z0,u.x1,u.y1,u.z1);return this}function nA(n){return n[0]}function iA(n){return arguments.length?(this._x=n,this):this._x}function aA(n){return n[1]}function rA(n){return arguments.length?(this._y=n,this):this._y}function lA(n){return n[2]}function uA(n){return arguments.length?(this._z=n,this):this._z}function Zm(n,i,r,u){var o=new uh(i??nA,r??aA,u??lA,NaN,NaN,NaN,NaN,NaN,NaN);return n==null?o:o.addAll(n)}function uh(n,i,r,u,o,c,h,g,y){this._x=n,this._y=i,this._z=r,this._x0=u,this._y0=o,this._z0=c,this._x1=h,this._y1=g,this._z1=y,this._root=void 0}function sy(n){for(var i={data:n.data},r=i;n=n.next;)r=r.next={data:n.data};return i}var de=Zm.prototype=uh.prototype;de.copy=function(){var n=new uh(this._x,this._y,this._z,this._x0,this._y0,this._z0,this._x1,this._y1,this._z1),i=this._root,r,u;if(!i)return n;if(!i.length)return n._root=sy(i),n;for(r=[{source:i,target:n._root=new Array(8)}];i=r.pop();)for(var o=0;o<8;++o)(u=i.source[o])&&(u.length?r.push({source:u,target:i.target[o]=new Array(8)}):i.target[o]=sy(u));return n};de.add=Q4;de.addAll=Y4;de.cover=X4;de.data=V4;de.extent=$4;de.find=Z4;de.findAllWithinRadius=F4;de.remove=P4;de.removeAll=J4;de.root=W4;de.size=I4;de.visit=tA;de.visitAfter=eA;de.x=iA;de.y=rA;de.z=uA;function Kn(n){return function(){return n}}function $n(n){return(n()-.5)*1e-6}function sA(n){return n.index}function oy(n,i){var r=n.get(i);if(!r)throw new Error("node not found: "+i);return r}function oA(n){var i=sA,r=_,u,o=Kn(30),c,h,g,y,p,v,m=1;n==null&&(n=[]);function _(S){return 1/Math.min(y[S.source.index],y[S.target.index])}function x(S){for(var j=0,H=n.length;j<m;++j)for(var R=0,C,q,U,Q=0,tt=0,F=0,K,it;R<H;++R)C=n[R],q=C.source,U=C.target,Q=U.x+U.vx-q.x-q.vx||$n(v),g>1&&(tt=U.y+U.vy-q.y-q.vy||$n(v)),g>2&&(F=U.z+U.vz-q.z-q.vz||$n(v)),K=Math.sqrt(Q*Q+tt*tt+F*F),K=(K-c[R])/K*S*u[R],Q*=K,tt*=K,F*=K,U.vx-=Q*(it=p[R]),g>1&&(U.vy-=tt*it),g>2&&(U.vz-=F*it),q.vx+=Q*(it=1-it),g>1&&(q.vy+=tt*it),g>2&&(q.vz+=F*it)}function A(){if(h){var S,j=h.length,H=n.length,R=new Map(h.map((q,U)=>[i(q,U,h),q])),C;for(S=0,y=new Array(j);S<H;++S)C=n[S],C.index=S,typeof C.source!="object"&&(C.source=oy(R,C.source)),typeof C.target!="object"&&(C.target=oy(R,C.target)),y[C.source.index]=(y[C.source.index]||0)+1,y[C.target.index]=(y[C.target.index]||0)+1;for(S=0,p=new Array(H);S<H;++S)C=n[S],p[S]=y[C.source.index]/(y[C.source.index]+y[C.target.index]);u=new Array(H),M(),c=new Array(H),O()}}function M(){if(h)for(var S=0,j=n.length;S<j;++S)u[S]=+r(n[S],S,n)}function O(){if(h)for(var S=0,j=n.length;S<j;++S)c[S]=+o(n[S],S,n)}return x.initialize=function(S,...j){h=S,v=j.find(H=>typeof H=="function")||Math.random,g=j.find(H=>[1,2,3].includes(H))||2,A()},x.links=function(S){return arguments.length?(n=S,A(),x):n},x.id=function(S){return arguments.length?(i=S,x):i},x.iterations=function(S){return arguments.length?(m=+S,x):m},x.strength=function(S){return arguments.length?(r=typeof S=="function"?S:Kn(+S),M(),x):r},x.distance=function(S){return arguments.length?(o=typeof S=="function"?S:Kn(+S),O(),x):o},x}const cA=1664525,fA=1013904223,cy=4294967296;function hA(){let n=1;return()=>(n=(cA*n+fA)%cy)/cy}var fy=3;function lf(n){return n.x}function hy(n){return n.y}function dA(n){return n.z}var gA=10,pA=Math.PI*(3-Math.sqrt(5)),yA=Math.PI*20/(9+Math.sqrt(221));function mA(n,i){i=i||2;var r=Math.min(fy,Math.max(1,Math.round(i))),u,o=1,c=.001,h=1-Math.pow(c,1/300),g=0,y=.6,p=new Map,v=Pf(x),m=El("tick","end"),_=hA();n==null&&(n=[]);function x(){A(),m.call("tick",u),o<c&&(v.stop(),m.call("end",u))}function A(S){var j,H=n.length,R;S===void 0&&(S=1);for(var C=0;C<S;++C)for(o+=(g-o)*h,p.forEach(function(q){q(o)}),j=0;j<H;++j)R=n[j],R.fx==null?R.x+=R.vx*=y:(R.x=R.fx,R.vx=0),r>1&&(R.fy==null?R.y+=R.vy*=y:(R.y=R.fy,R.vy=0)),r>2&&(R.fz==null?R.z+=R.vz*=y:(R.z=R.fz,R.vz=0));return u}function M(){for(var S=0,j=n.length,H;S<j;++S){if(H=n[S],H.index=S,H.fx!=null&&(H.x=H.fx),H.fy!=null&&(H.y=H.fy),H.fz!=null&&(H.z=H.fz),isNaN(H.x)||r>1&&isNaN(H.y)||r>2&&isNaN(H.z)){var R=gA*(r>2?Math.cbrt(.5+S):r>1?Math.sqrt(.5+S):S),C=S*pA,q=S*yA;r===1?H.x=R:r===2?(H.x=R*Math.cos(C),H.y=R*Math.sin(C)):(H.x=R*Math.sin(C)*Math.cos(q),H.y=R*Math.cos(C),H.z=R*Math.sin(C)*Math.sin(q))}(isNaN(H.vx)||r>1&&isNaN(H.vy)||r>2&&isNaN(H.vz))&&(H.vx=0,r>1&&(H.vy=0),r>2&&(H.vz=0))}}function O(S){return S.initialize&&S.initialize(n,_,r),S}return M(),u={tick:A,restart:function(){return v.restart(x),u},stop:function(){return v.stop(),u},numDimensions:function(S){return arguments.length?(r=Math.min(fy,Math.max(1,Math.round(S))),p.forEach(O),u):r},nodes:function(S){return arguments.length?(n=S,M(),p.forEach(O),u):n},alpha:function(S){return arguments.length?(o=+S,u):o},alphaMin:function(S){return arguments.length?(c=+S,u):c},alphaDecay:function(S){return arguments.length?(h=+S,u):+h},alphaTarget:function(S){return arguments.length?(g=+S,u):g},velocityDecay:function(S){return arguments.length?(y=1-S,u):1-y},randomSource:function(S){return arguments.length?(_=S,p.forEach(O),u):_},force:function(S,j){return arguments.length>1?(j==null?p.delete(S):p.set(S,O(j)),u):p.get(S)},find:function(){var S=Array.prototype.slice.call(arguments),j=S.shift()||0,H=(r>1?S.shift():null)||0,R=(r>2?S.shift():null)||0,C=S.shift()||1/0,q=0,U=n.length,Q,tt,F,K,it,ct;for(C*=C,q=0;q<U;++q)it=n[q],Q=j-it.x,tt=H-(it.y||0),F=R-(it.z||0),K=Q*Q+tt*tt+F*F,K<C&&(ct=it,C=K);return ct},on:function(S,j){return arguments.length>1?(m.on(S,j),u):m.on(S)}}}function vA(){var n,i,r,u,o,c=Kn(-30),h,g=1,y=1/0,p=.81;function v(A){var M,O=n.length,S=(i===1?Ym(n,lf):i===2?Vm(n,lf,hy):i===3?Zm(n,lf,hy,dA):null).visitAfter(_);for(o=A,M=0;M<O;++M)r=n[M],S.visit(x)}function m(){if(n){var A,M=n.length,O;for(h=new Array(M),A=0;A<M;++A)O=n[A],h[O.index]=+c(O,A,n)}}function _(A){var M=0,O,S,j=0,H,R,C,q,U=A.length;if(U){for(H=R=C=q=0;q<U;++q)(O=A[q])&&(S=Math.abs(O.value))&&(M+=O.value,j+=S,H+=S*(O.x||0),R+=S*(O.y||0),C+=S*(O.z||0));M*=Math.sqrt(4/U),A.x=H/j,i>1&&(A.y=R/j),i>2&&(A.z=C/j)}else{O=A,O.x=O.data.x,i>1&&(O.y=O.data.y),i>2&&(O.z=O.data.z);do M+=h[O.data.index];while(O=O.next)}A.value=M}function x(A,M,O,S,j){if(!A.value)return!0;var H=[O,S,j][i-1],R=A.x-r.x,C=i>1?A.y-r.y:0,q=i>2?A.z-r.z:0,U=H-M,Q=R*R+C*C+q*q;if(U*U/p<Q)return Q<y&&(R===0&&(R=$n(u),Q+=R*R),i>1&&C===0&&(C=$n(u),Q+=C*C),i>2&&q===0&&(q=$n(u),Q+=q*q),Q<g&&(Q=Math.sqrt(g*Q)),r.vx+=R*A.value*o/Q,i>1&&(r.vy+=C*A.value*o/Q),i>2&&(r.vz+=q*A.value*o/Q)),!0;if(A.length||Q>=y)return;(A.data!==r||A.next)&&(R===0&&(R=$n(u),Q+=R*R),i>1&&C===0&&(C=$n(u),Q+=C*C),i>2&&q===0&&(q=$n(u),Q+=q*q),Q<g&&(Q=Math.sqrt(g*Q)));do A.data!==r&&(U=h[A.data.index]*o/Q,r.vx+=R*U,i>1&&(r.vy+=C*U),i>2&&(r.vz+=q*U));while(A=A.next)}return v.initialize=function(A,...M){n=A,u=M.find(O=>typeof O=="function")||Math.random,i=M.find(O=>[1,2,3].includes(O))||2,m()},v.strength=function(A){return arguments.length?(c=typeof A=="function"?A:Kn(+A),m(),v):c},v.distanceMin=function(A){return arguments.length?(g=A*A,v):Math.sqrt(g)},v.distanceMax=function(A){return arguments.length?(y=A*A,v):Math.sqrt(y)},v.theta=function(A){return arguments.length?(p=A*A,v):Math.sqrt(p)},v}function bA(n,i,r,u){var o,c,h=Kn(.1),g,y;typeof n!="function"&&(n=Kn(+n)),i==null&&(i=0),r==null&&(r=0),u==null&&(u=0);function p(m){for(var _=0,x=o.length;_<x;++_){var A=o[_],M=A.x-i||1e-6,O=(A.y||0)-r||1e-6,S=(A.z||0)-u||1e-6,j=Math.sqrt(M*M+O*O+S*S),H=(y[_]-j)*g[_]*m/j;A.vx+=M*H,c>1&&(A.vy+=O*H),c>2&&(A.vz+=S*H)}}function v(){if(o){var m,_=o.length;for(g=new Array(_),y=new Array(_),m=0;m<_;++m)y[m]=+n(o[m],m,o),g[m]=isNaN(y[m])?0:+h(o[m],m,o)}}return p.initialize=function(m,..._){o=m,c=_.find(x=>[1,2,3].includes(x))||2,v()},p.strength=function(m){return arguments.length?(h=typeof m=="function"?m:Kn(+m),v(),p):h},p.radius=function(m){return arguments.length?(n=typeof m=="function"?m:Kn(+m),v(),p):n},p.x=function(m){return arguments.length?(i=+m,p):i},p.y=function(m){return arguments.length?(r=+m,p):r},p.z=function(m){return arguments.length?(u=+m,p):u},p}const{abs:nl,cos:Vn,sin:Xa,acos:_A,atan2:il,sqrt:bi,pow:Je}=Math;function al(n){return n<0?-Je(-n,1/3):Je(n,1/3)}const Km=Math.PI,Ju=2*Km,_i=Km/2,xA=1e-6,uf=Number.MAX_SAFE_INTEGER||9007199254740991,sf=Number.MIN_SAFE_INTEGER||-9007199254740991,wA={x:0,y:0,z:0},lt={Tvalues:[-.06405689286260563,.06405689286260563,-.1911188674736163,.1911188674736163,-.3150426796961634,.3150426796961634,-.4337935076260451,.4337935076260451,-.5454214713888396,.5454214713888396,-.6480936519369755,.6480936519369755,-.7401241915785544,.7401241915785544,-.820001985973903,.820001985973903,-.8864155270044011,.8864155270044011,-.9382745520027328,.9382745520027328,-.9747285559713095,.9747285559713095,-.9951872199970213,.9951872199970213],Cvalues:[.12793819534675216,.12793819534675216,.1258374563468283,.1258374563468283,.12167047292780339,.12167047292780339,.1155056680537256,.1155056680537256,.10744427011596563,.10744427011596563,.09761865210411388,.09761865210411388,.08619016153195327,.08619016153195327,.0733464814110803,.0733464814110803,.05929858491543678,.05929858491543678,.04427743881741981,.04427743881741981,.028531388628933663,.028531388628933663,.0123412297999872,.0123412297999872],arcfn:function(n,i){const r=i(n);let u=r.x*r.x+r.y*r.y;return typeof r.z<"u"&&(u+=r.z*r.z),bi(u)},compute:function(n,i,r){if(n===0)return i[0].t=0,i[0];const u=i.length-1;if(n===1)return i[u].t=1,i[u];const o=1-n;let c=i;if(u===0)return i[0].t=n,i[0];if(u===1){const g={x:o*c[0].x+n*c[1].x,y:o*c[0].y+n*c[1].y,t:n};return r&&(g.z=o*c[0].z+n*c[1].z),g}if(u<4){let g=o*o,y=n*n,p,v,m,_=0;u===2?(c=[c[0],c[1],c[2],wA],p=g,v=o*n*2,m=y):u===3&&(p=g*o,v=g*n*3,m=o*y*3,_=n*y);const x={x:p*c[0].x+v*c[1].x+m*c[2].x+_*c[3].x,y:p*c[0].y+v*c[1].y+m*c[2].y+_*c[3].y,t:n};return r&&(x.z=p*c[0].z+v*c[1].z+m*c[2].z+_*c[3].z),x}const h=JSON.parse(JSON.stringify(i));for(;h.length>1;){for(let g=0;g<h.length-1;g++)h[g]={x:h[g].x+(h[g+1].x-h[g].x)*n,y:h[g].y+(h[g+1].y-h[g].y)*n},typeof h[g].z<"u"&&(h[g].z=h[g].z+(h[g+1].z-h[g].z)*n);h.splice(h.length-1,1)}return h[0].t=n,h[0]},computeWithRatios:function(n,i,r,u){const o=1-n,c=r,h=i;let g=c[0],y=c[1],p=c[2],v=c[3],m;if(g*=o,y*=n,h.length===2)return m=g+y,{x:(g*h[0].x+y*h[1].x)/m,y:(g*h[0].y+y*h[1].y)/m,z:u?(g*h[0].z+y*h[1].z)/m:!1,t:n};if(g*=o,y*=2*o,p*=n*n,h.length===3)return m=g+y+p,{x:(g*h[0].x+y*h[1].x+p*h[2].x)/m,y:(g*h[0].y+y*h[1].y+p*h[2].y)/m,z:u?(g*h[0].z+y*h[1].z+p*h[2].z)/m:!1,t:n};if(g*=o,y*=1.5*o,p*=3*o,v*=n*n*n,h.length===4)return m=g+y+p+v,{x:(g*h[0].x+y*h[1].x+p*h[2].x+v*h[3].x)/m,y:(g*h[0].y+y*h[1].y+p*h[2].y+v*h[3].y)/m,z:u?(g*h[0].z+y*h[1].z+p*h[2].z+v*h[3].z)/m:!1,t:n}},derive:function(n,i){const r=[];for(let u=n,o=u.length,c=o-1;o>1;o--,c--){const h=[];for(let g=0,y;g<c;g++)y={x:c*(u[g+1].x-u[g].x),y:c*(u[g+1].y-u[g].y)},i&&(y.z=c*(u[g+1].z-u[g].z)),h.push(y);r.push(h),u=h}return r},between:function(n,i,r){return i<=n&&n<=r||lt.approximately(n,i)||lt.approximately(n,r)},approximately:function(n,i,r){return nl(n-i)<=(r||xA)},length:function(n){const r=lt.Tvalues.length;let u=0;for(let o=0,c;o<r;o++)c=.5*lt.Tvalues[o]+.5,u+=lt.Cvalues[o]*lt.arcfn(c,n);return .5*u},map:function(n,i,r,u,o){const c=r-i,h=o-u,g=n-i,y=g/c;return u+h*y},lerp:function(n,i,r){const u={x:i.x+n*(r.x-i.x),y:i.y+n*(r.y-i.y)};return i.z!==void 0&&r.z!==void 0&&(u.z=i.z+n*(r.z-i.z)),u},pointToString:function(n){let i=n.x+"/"+n.y;return typeof n.z<"u"&&(i+="/"+n.z),i},pointsToString:function(n){return"["+n.map(lt.pointToString).join(", ")+"]"},copy:function(n){return JSON.parse(JSON.stringify(n))},angle:function(n,i,r){const u=i.x-n.x,o=i.y-n.y,c=r.x-n.x,h=r.y-n.y,g=u*h-o*c,y=u*c+o*h;return il(g,y)},round:function(n,i){const r=""+n,u=r.indexOf(".");return parseFloat(r.substring(0,u+1+i))},dist:function(n,i){const r=n.x-i.x,u=n.y-i.y;return bi(r*r+u*u)},closest:function(n,i){let r=Je(2,63),u,o;return n.forEach(function(c,h){o=lt.dist(i,c),o<r&&(r=o,u=h)}),{mdist:r,mpos:u}},abcratio:function(n,i){if(i!==2&&i!==3)return!1;if(typeof n>"u")n=.5;else if(n===0||n===1)return n;const r=Je(n,i)+Je(1-n,i),u=r-1;return nl(u/r)},projectionratio:function(n,i){if(i!==2&&i!==3)return!1;if(typeof n>"u")n=.5;else if(n===0||n===1)return n;const r=Je(1-n,i),u=Je(n,i)+r;return r/u},lli8:function(n,i,r,u,o,c,h,g){const y=(n*u-i*r)*(o-h)-(n-r)*(o*g-c*h),p=(n*u-i*r)*(c-g)-(i-u)*(o*g-c*h),v=(n-r)*(c-g)-(i-u)*(o-h);return v==0?!1:{x:y/v,y:p/v}},lli4:function(n,i,r,u){const o=n.x,c=n.y,h=i.x,g=i.y,y=r.x,p=r.y,v=u.x,m=u.y;return lt.lli8(o,c,h,g,y,p,v,m)},lli:function(n,i){return lt.lli4(n,n.c,i,i.c)},makeline:function(n,i){return new Bt(n.x,n.y,(n.x+i.x)/2,(n.y+i.y)/2,i.x,i.y)},findbbox:function(n){let i=uf,r=uf,u=sf,o=sf;return n.forEach(function(c){const h=c.bbox();i>h.x.min&&(i=h.x.min),r>h.y.min&&(r=h.y.min),u<h.x.max&&(u=h.x.max),o<h.y.max&&(o=h.y.max)}),{x:{min:i,mid:(i+u)/2,max:u,size:u-i},y:{min:r,mid:(r+o)/2,max:o,size:o-r}}},shapeintersections:function(n,i,r,u,o){if(!lt.bboxoverlap(i,u))return[];const c=[],h=[n.startcap,n.forward,n.back,n.endcap],g=[r.startcap,r.forward,r.back,r.endcap];return h.forEach(function(y){y.virtual||g.forEach(function(p){if(p.virtual)return;const v=y.intersects(p,o);v.length>0&&(v.c1=y,v.c2=p,v.s1=n,v.s2=r,c.push(v))})}),c},makeshape:function(n,i,r){const u=i.points.length,o=n.points.length,c=lt.makeline(i.points[u-1],n.points[0]),h=lt.makeline(n.points[o-1],i.points[0]),g={startcap:c,forward:n,back:i,endcap:h,bbox:lt.findbbox([c,n,i,h])};return g.intersections=function(y){return lt.shapeintersections(g,g.bbox,y,y.bbox,r)},g},getminmax:function(n,i,r){if(!r)return{min:0,max:0};let u=uf,o=sf,c,h;r.indexOf(0)===-1&&(r=[0].concat(r)),r.indexOf(1)===-1&&r.push(1);for(let g=0,y=r.length;g<y;g++)c=r[g],h=n.get(c),h[i]<u&&(u=h[i]),h[i]>o&&(o=h[i]);return{min:u,mid:(u+o)/2,max:o,size:o-u}},align:function(n,i){const r=i.p1.x,u=i.p1.y,o=-il(i.p2.y-u,i.p2.x-r),c=function(h){return{x:(h.x-r)*Vn(o)-(h.y-u)*Xa(o),y:(h.x-r)*Xa(o)+(h.y-u)*Vn(o)}};return n.map(c)},roots:function(n,i){i=i||{p1:{x:0,y:0},p2:{x:1,y:0}};const r=n.length-1,u=lt.align(n,i),o=function(U){return 0<=U&&U<=1};if(r===2){const U=u[0].y,Q=u[1].y,tt=u[2].y,F=U-2*Q+tt;if(F!==0){const K=-bi(Q*Q-U*tt),it=-U+Q,ct=-(K+it)/F,L=-(-K+it)/F;return[ct,L].filter(o)}else if(Q!==tt&&F===0)return[(2*Q-tt)/(2*Q-2*tt)].filter(o);return[]}const c=u[0].y,h=u[1].y,g=u[2].y,y=u[3].y;let p=-c+3*h-3*g+y,v=3*c-6*h+3*g,m=-3*c+3*h,_=c;if(lt.approximately(p,0)){if(lt.approximately(v,0))return lt.approximately(m,0)?[]:[-_/m].filter(o);const U=bi(m*m-4*v*_),Q=2*v;return[(U-m)/Q,(-m-U)/Q].filter(o)}v/=p,m/=p,_/=p;const x=(3*m-v*v)/3,A=x/3,M=(2*v*v*v-9*v*m+27*_)/27,O=M/2,S=O*O+A*A*A;let j,H,R,C,q;if(S<0){const U=-x/3,Q=U*U*U,tt=bi(Q),F=-M/(2*tt),K=F<-1?-1:F>1?1:F,it=_A(K),ct=al(tt),L=2*ct;return R=L*Vn(it/3)-v/3,C=L*Vn((it+Ju)/3)-v/3,q=L*Vn((it+2*Ju)/3)-v/3,[R,C,q].filter(o)}else{if(S===0)return j=O<0?al(-O):-al(O),R=2*j-v/3,C=-j-v/3,[R,C].filter(o);{const U=bi(S);return j=al(-O+U),H=al(O+U),[j-H-v/3].filter(o)}}},droots:function(n){if(n.length===3){const i=n[0],r=n[1],u=n[2],o=i-2*r+u;if(o!==0){const c=-bi(r*r-i*u),h=-i+r,g=-(c+h)/o,y=-(-c+h)/o;return[g,y]}else if(r!==u&&o===0)return[(2*r-u)/(2*(r-u))];return[]}if(n.length===2){const i=n[0],r=n[1];return i!==r?[i/(i-r)]:[]}return[]},curvature:function(n,i,r,u,o){let c,h,g,y,p=0,v=0;const m=lt.compute(n,i),_=lt.compute(n,r),x=m.x*m.x+m.y*m.y;if(u?(c=bi(Je(m.y*_.z-_.y*m.z,2)+Je(m.z*_.x-_.z*m.x,2)+Je(m.x*_.y-_.x*m.y,2)),h=Je(x+m.z*m.z,3/2)):(c=m.x*_.y-m.y*_.x,h=Je(x,3/2)),c===0||h===0)return{k:0,r:0};if(p=c/h,v=h/c,!o){const A=lt.curvature(n-.001,i,r,u,!0).k,M=lt.curvature(n+.001,i,r,u,!0).k;y=(M-p+(p-A))/2,g=(nl(M-p)+nl(p-A))/2}return{k:p,r:v,dk:y,adk:g}},inflections:function(n){if(n.length<4)return[];const i=lt.align(n,{p1:n[0],p2:n.slice(-1)[0]}),r=i[2].x*i[1].y,u=i[3].x*i[1].y,o=i[1].x*i[2].y,c=i[3].x*i[2].y,h=18*(-3*r+2*u+3*o-c),g=18*(3*r-u-3*o),y=18*(o-r);if(lt.approximately(h,0)){if(!lt.approximately(g,0)){let _=-y/g;if(0<=_&&_<=1)return[_]}return[]}const p=2*h;if(lt.approximately(p,0))return[];const v=g*g-4*h*y;if(v<0)return[];const m=Math.sqrt(v);return[(m-g)/p,-(g+m)/p].filter(function(_){return 0<=_&&_<=1})},bboxoverlap:function(n,i){const r=["x","y"],u=r.length;for(let o=0,c,h,g,y;o<u;o++)if(c=r[o],h=n[c].mid,g=i[c].mid,y=(n[c].size+i[c].size)/2,nl(h-g)>=y)return!1;return!0},expandbox:function(n,i){i.x.min<n.x.min&&(n.x.min=i.x.min),i.y.min<n.y.min&&(n.y.min=i.y.min),i.z&&i.z.min<n.z.min&&(n.z.min=i.z.min),i.x.max>n.x.max&&(n.x.max=i.x.max),i.y.max>n.y.max&&(n.y.max=i.y.max),i.z&&i.z.max>n.z.max&&(n.z.max=i.z.max),n.x.mid=(n.x.min+n.x.max)/2,n.y.mid=(n.y.min+n.y.max)/2,n.z&&(n.z.mid=(n.z.min+n.z.max)/2),n.x.size=n.x.max-n.x.min,n.y.size=n.y.max-n.y.min,n.z&&(n.z.size=n.z.max-n.z.min)},pairiteration:function(n,i,r){const u=n.bbox(),o=i.bbox(),c=1e5,h=r||.5;if(u.x.size+u.y.size<h&&o.x.size+o.y.size<h)return[(c*(n._t1+n._t2)/2|0)/c+"/"+(c*(i._t1+i._t2)/2|0)/c];let g=n.split(.5),y=i.split(.5),p=[{left:g.left,right:y.left},{left:g.left,right:y.right},{left:g.right,right:y.right},{left:g.right,right:y.left}];p=p.filter(function(m){return lt.bboxoverlap(m.left.bbox(),m.right.bbox())});let v=[];return p.length===0||(p.forEach(function(m){v=v.concat(lt.pairiteration(m.left,m.right,h))}),v=v.filter(function(m,_){return v.indexOf(m)===_})),v},getccenter:function(n,i,r){const u=i.x-n.x,o=i.y-n.y,c=r.x-i.x,h=r.y-i.y,g=u*Vn(_i)-o*Xa(_i),y=u*Xa(_i)+o*Vn(_i),p=c*Vn(_i)-h*Xa(_i),v=c*Xa(_i)+h*Vn(_i),m=(n.x+i.x)/2,_=(n.y+i.y)/2,x=(i.x+r.x)/2,A=(i.y+r.y)/2,M=m+g,O=_+y,S=x+p,j=A+v,H=lt.lli8(m,_,M,O,x,A,S,j),R=lt.dist(H,n);let C=il(n.y-H.y,n.x-H.x),q=il(i.y-H.y,i.x-H.x),U=il(r.y-H.y,r.x-H.x),Q;return C<U?((C>q||q>U)&&(C+=Ju),C>U&&(Q=U,U=C,C=Q)):U<q&&q<C?(Q=U,U=C,C=Q):U+=Ju,H.s=C,H.e=U,H.r=R,H},numberSort:function(n,i){return n-i}};class dl{constructor(i){this.curves=[],this._3d=!1,i&&(this.curves=i,this._3d=this.curves[0]._3d)}valueOf(){return this.toString()}toString(){return"["+this.curves.map(function(i){return lt.pointsToString(i.points)}).join(", ")+"]"}addCurve(i){this.curves.push(i),this._3d=this._3d||i._3d}length(){return this.curves.map(function(i){return i.length()}).reduce(function(i,r){return i+r})}curve(i){return this.curves[i]}bbox(){const i=this.curves;for(var r=i[0].bbox(),u=1;u<i.length;u++)lt.expandbox(r,i[u].bbox());return r}offset(i){const r=[];return this.curves.forEach(function(u){r.push(...u.offset(i))}),new dl(r)}}const{abs:rl,min:dy,max:gy,cos:SA,sin:AA,acos:EA,sqrt:ll}=Math,TA=Math.PI;class Bt{constructor(i){let r=i&&i.forEach?i:Array.from(arguments).slice(),u=!1;if(typeof r[0]=="object"){u=r.length;const x=[];r.forEach(function(A){["x","y","z"].forEach(function(M){typeof A[M]<"u"&&x.push(A[M])})}),r=x}let o=!1;const c=r.length;if(u){if(u>4){if(arguments.length!==1)throw new Error("Only new Bezier(point[]) is accepted for 4th and higher order curves");o=!0}}else if(c!==6&&c!==8&&c!==9&&c!==12&&arguments.length!==1)throw new Error("Only new Bezier(point[]) is accepted for 4th and higher order curves");const h=this._3d=!o&&(c===9||c===12)||i&&i[0]&&typeof i[0].z<"u",g=this.points=[];for(let x=0,A=h?3:2;x<c;x+=A){var y={x:r[x],y:r[x+1]};h&&(y.z=r[x+2]),g.push(y)}const p=this.order=g.length-1,v=this.dims=["x","y"];h&&v.push("z"),this.dimlen=v.length;const m=lt.align(g,{p1:g[0],p2:g[p]}),_=lt.dist(g[0],g[p]);this._linear=m.reduce((x,A)=>x+rl(A.y),0)<_/50,this._lut=[],this._t1=0,this._t2=1,this.update()}static quadraticFromPoints(i,r,u,o){if(typeof o>"u"&&(o=.5),o===0)return new Bt(r,r,u);if(o===1)return new Bt(i,r,r);const c=Bt.getABC(2,i,r,u,o);return new Bt(i,c.A,u)}static cubicFromPoints(i,r,u,o,c){typeof o>"u"&&(o=.5);const h=Bt.getABC(3,i,r,u,o);typeof c>"u"&&(c=lt.dist(r,h.C));const g=c*(1-o)/o,y=lt.dist(i,u),p=(u.x-i.x)/y,v=(u.y-i.y)/y,m=c*p,_=c*v,x=g*p,A=g*v,M={x:r.x-m,y:r.y-_},O={x:r.x+x,y:r.y+A},S=h.A,j={x:S.x+(M.x-S.x)/(1-o),y:S.y+(M.y-S.y)/(1-o)},H={x:S.x+(O.x-S.x)/o,y:S.y+(O.y-S.y)/o},R={x:i.x+(j.x-i.x)/o,y:i.y+(j.y-i.y)/o},C={x:u.x+(H.x-u.x)/(1-o),y:u.y+(H.y-u.y)/(1-o)};return new Bt(i,R,C,u)}static getUtils(){return lt}getUtils(){return Bt.getUtils()}static get PolyBezier(){return dl}valueOf(){return this.toString()}toString(){return lt.pointsToString(this.points)}toSVG(){if(this._3d)return!1;const i=this.points,r=i[0].x,u=i[0].y,o=["M",r,u,this.order===2?"Q":"C"];for(let c=1,h=i.length;c<h;c++)o.push(i[c].x),o.push(i[c].y);return o.join(" ")}setRatios(i){if(i.length!==this.points.length)throw new Error("incorrect number of ratio values");this.ratios=i,this._lut=[]}verify(){const i=this.coordDigest();i!==this._print&&(this._print=i,this.update())}coordDigest(){return this.points.map(function(i,r){return""+r+i.x+i.y+(i.z?i.z:0)}).join("")}update(){this._lut=[],this.dpoints=lt.derive(this.points,this._3d),this.computedirection()}computedirection(){const i=this.points,r=lt.angle(i[0],i[this.order],i[1]);this.clockwise=r>0}length(){return lt.length(this.derivative.bind(this))}static getABC(i=2,r,u,o,c=.5){const h=lt.projectionratio(c,i),g=1-h,y={x:h*r.x+g*o.x,y:h*r.y+g*o.y},p=lt.abcratio(c,i);return{A:{x:u.x+(u.x-y.x)/p,y:u.y+(u.y-y.y)/p},B:u,C:y,S:r,E:o}}getABC(i,r){r=r||this.get(i);let u=this.points[0],o=this.points[this.order];return Bt.getABC(this.order,u,r,o,i)}getLUT(i){if(this.verify(),i=i||100,this._lut.length===i+1)return this._lut;this._lut=[],i++,this._lut=[];for(let r=0,u,o;r<i;r++)o=r/(i-1),u=this.compute(o),u.t=o,this._lut.push(u);return this._lut}on(i,r){r=r||5;const u=this.getLUT(),o=[];for(let c=0,h,g=0;c<u.length;c++)h=u[c],lt.dist(h,i)<r&&(o.push(h),g+=c/u.length);return o.length?t/=o.length:!1}project(i){const r=this.getLUT(),u=r.length-1,o=lt.closest(r,i),c=o.mpos,h=(c-1)/u,g=(c+1)/u,y=.1/u;let p=o.mdist,v=h,m=v,_;p+=1;for(let x;v<g+y;v+=y)_=this.compute(v),x=lt.dist(i,_),x<p&&(p=x,m=v);return m=m<0?0:m>1?1:m,_=this.compute(m),_.t=m,_.d=p,_}get(i){return this.compute(i)}point(i){return this.points[i]}compute(i){return this.ratios?lt.computeWithRatios(i,this.points,this.ratios,this._3d):lt.compute(i,this.points,this._3d,this.ratios)}raise(){const i=this.points,r=[i[0]],u=i.length;for(let o=1,c,h;o<u;o++)c=i[o],h=i[o-1],r[o]={x:(u-o)/u*c.x+o/u*h.x,y:(u-o)/u*c.y+o/u*h.y};return r[u]=i[u-1],new Bt(r)}derivative(i){return lt.compute(i,this.dpoints[0],this._3d)}dderivative(i){return lt.compute(i,this.dpoints[1],this._3d)}align(){let i=this.points;return new Bt(lt.align(i,{p1:i[0],p2:i[i.length-1]}))}curvature(i){return lt.curvature(i,this.dpoints[0],this.dpoints[1],this._3d)}inflections(){return lt.inflections(this.points)}normal(i){return this._3d?this.__normal3(i):this.__normal2(i)}__normal2(i){const r=this.derivative(i),u=ll(r.x*r.x+r.y*r.y);return{t:i,x:-r.y/u,y:r.x/u}}__normal3(i){const r=this.derivative(i),u=this.derivative(i+.01),o=ll(r.x*r.x+r.y*r.y+r.z*r.z),c=ll(u.x*u.x+u.y*u.y+u.z*u.z);r.x/=o,r.y/=o,r.z/=o,u.x/=c,u.y/=c,u.z/=c;const h={x:u.y*r.z-u.z*r.y,y:u.z*r.x-u.x*r.z,z:u.x*r.y-u.y*r.x},g=ll(h.x*h.x+h.y*h.y+h.z*h.z);h.x/=g,h.y/=g,h.z/=g;const y=[h.x*h.x,h.x*h.y-h.z,h.x*h.z+h.y,h.x*h.y+h.z,h.y*h.y,h.y*h.z-h.x,h.x*h.z-h.y,h.y*h.z+h.x,h.z*h.z];return{t:i,x:y[0]*r.x+y[1]*r.y+y[2]*r.z,y:y[3]*r.x+y[4]*r.y+y[5]*r.z,z:y[6]*r.x+y[7]*r.y+y[8]*r.z}}hull(i){let r=this.points,u=[],o=[],c=0;for(o[c++]=r[0],o[c++]=r[1],o[c++]=r[2],this.order===3&&(o[c++]=r[3]);r.length>1;){u=[];for(let h=0,g,y=r.length-1;h<y;h++)g=lt.lerp(i,r[h],r[h+1]),o[c++]=g,u.push(g);r=u}return o}split(i,r){if(i===0&&r)return this.split(r).left;if(r===1)return this.split(i).right;const u=this.hull(i),o={left:this.order===2?new Bt([u[0],u[3],u[5]]):new Bt([u[0],u[4],u[7],u[9]]),right:this.order===2?new Bt([u[5],u[4],u[2]]):new Bt([u[9],u[8],u[6],u[3]]),span:u};return o.left._t1=lt.map(0,0,1,this._t1,this._t2),o.left._t2=lt.map(i,0,1,this._t1,this._t2),o.right._t1=lt.map(i,0,1,this._t1,this._t2),o.right._t2=lt.map(1,0,1,this._t1,this._t2),r?(r=lt.map(r,i,1,0,1),o.right.split(r).left):o}extrema(){const i={};let r=[];return this.dims.forEach((function(u){let o=function(h){return h[u]},c=this.dpoints[0].map(o);i[u]=lt.droots(c),this.order===3&&(c=this.dpoints[1].map(o),i[u]=i[u].concat(lt.droots(c))),i[u]=i[u].filter(function(h){return h>=0&&h<=1}),r=r.concat(i[u].sort(lt.numberSort))}).bind(this)),i.values=r.sort(lt.numberSort).filter(function(u,o){return r.indexOf(u)===o}),i}bbox(){const i=this.extrema(),r={};return this.dims.forEach((function(u){r[u]=lt.getminmax(this,u,i[u])}).bind(this)),r}overlaps(i){const r=this.bbox(),u=i.bbox();return lt.bboxoverlap(r,u)}offset(i,r){if(typeof r<"u"){const u=this.get(i),o=this.normal(i),c={c:u,n:o,x:u.x+o.x*r,y:u.y+o.y*r};return this._3d&&(c.z=u.z+o.z*r),c}if(this._linear){const u=this.normal(0),o=this.points.map(function(c){const h={x:c.x+i*u.x,y:c.y+i*u.y};return c.z&&u.z&&(h.z=c.z+i*u.z),h});return[new Bt(o)]}return this.reduce().map(function(u){return u._linear?u.offset(i)[0]:u.scale(i)})}simple(){if(this.order===3){const o=lt.angle(this.points[0],this.points[3],this.points[1]),c=lt.angle(this.points[0],this.points[3],this.points[2]);if(o>0&&c<0||o<0&&c>0)return!1}const i=this.normal(0),r=this.normal(1);let u=i.x*r.x+i.y*r.y;return this._3d&&(u+=i.z*r.z),rl(EA(u))<TA/3}reduce(){let i,r=0,u=0,o=.01,c,h=[],g=[],y=this.extrema().values;for(y.indexOf(0)===-1&&(y=[0].concat(y)),y.indexOf(1)===-1&&y.push(1),r=y[0],i=1;i<y.length;i++)u=y[i],c=this.split(r,u),c._t1=r,c._t2=u,h.push(c),r=u;return h.forEach(function(p){for(r=0,u=0;u<=1;)for(u=r+o;u<=1+o;u+=o)if(c=p.split(r,u),!c.simple()){if(u-=o,rl(r-u)<o)return[];c=p.split(r,u),c._t1=lt.map(r,0,1,p._t1,p._t2),c._t2=lt.map(u,0,1,p._t1,p._t2),g.push(c),r=u;break}r<1&&(c=p.split(r,1),c._t1=lt.map(r,0,1,p._t1,p._t2),c._t2=p._t2,g.push(c))}),g}translate(i,r,u){u=typeof u=="number"?u:r;const o=this.order;let c=this.points.map((h,g)=>(1-g/o)*r+g/o*u);return new Bt(this.points.map((h,g)=>({x:h.x+i.x*c[g],y:h.y+i.y*c[g]})))}scale(i){const r=this.order;let u=!1;if(typeof i=="function"&&(u=i),u&&r===2)return this.raise().scale(u);const o=this.clockwise,c=this.points;if(this._linear)return this.translate(this.normal(0),u?u(0):i,u?u(1):i);const h=u?u(0):i,g=u?u(1):i,y=[this.offset(0,10),this.offset(1,10)],p=[],v=lt.lli4(y[0],y[0].c,y[1],y[1].c);if(!v)throw new Error("cannot scale this curve. Try reducing it first.");return[0,1].forEach(function(m){const _=p[m*r]=lt.copy(c[m*r]);_.x+=(m?g:h)*y[m].n.x,_.y+=(m?g:h)*y[m].n.y}),u?([0,1].forEach(function(m){if(!(r===2&&m)){var _=c[m+1],x={x:_.x-v.x,y:_.y-v.y},A=u?u((m+1)/r):i;u&&!o&&(A=-A);var M=ll(x.x*x.x+x.y*x.y);x.x/=M,x.y/=M,p[m+1]={x:_.x+A*x.x,y:_.y+A*x.y}}}),new Bt(p)):([0,1].forEach(m=>{if(r===2&&m)return;const _=p[m*r],x=this.derivative(m),A={x:_.x+x.x,y:_.y+x.y};p[m+1]=lt.lli4(_,A,v,c[m+1])}),new Bt(p))}outline(i,r,u,o){if(r=r===void 0?i:r,this._linear){const C=this.normal(0),q=this.points[0],U=this.points[this.points.length-1];let Q,tt,F;u===void 0&&(u=i,o=r),Q={x:q.x+C.x*i,y:q.y+C.y*i},F={x:U.x+C.x*u,y:U.y+C.y*u},tt={x:(Q.x+F.x)/2,y:(Q.y+F.y)/2};const K=[Q,tt,F];Q={x:q.x-C.x*r,y:q.y-C.y*r},F={x:U.x-C.x*o,y:U.y-C.y*o},tt={x:(Q.x+F.x)/2,y:(Q.y+F.y)/2};const it=[F,tt,Q],ct=lt.makeline(it[2],K[0]),L=lt.makeline(K[2],it[0]),J=[ct,new Bt(K),L,new Bt(it)];return new dl(J)}const c=this.reduce(),h=c.length,g=[];let y=[],p,v=0,m=this.length();const _=typeof u<"u"&&typeof o<"u";function x(C,q,U,Q,tt){return function(F){const K=Q/U,it=(Q+tt)/U,ct=q-C;return lt.map(F,0,1,C+K*ct,C+it*ct)}}c.forEach(function(C){const q=C.length();_?(g.push(C.scale(x(i,u,m,v,q))),y.push(C.scale(x(-r,-o,m,v,q)))):(g.push(C.scale(i)),y.push(C.scale(-r))),v+=q}),y=y.map(function(C){return p=C.points,p[3]?C.points=[p[3],p[2],p[1],p[0]]:C.points=[p[2],p[1],p[0]],C}).reverse();const A=g[0].points[0],M=g[h-1].points[g[h-1].points.length-1],O=y[h-1].points[y[h-1].points.length-1],S=y[0].points[0],j=lt.makeline(O,A),H=lt.makeline(M,S),R=[j].concat(g).concat([H]).concat(y);return new dl(R)}outlineshapes(i,r,u){r=r||i;const o=this.outline(i,r).curves,c=[];for(let h=1,g=o.length;h<g/2;h++){const y=lt.makeshape(o[h],o[g-h],u);y.startcap.virtual=h>1,y.endcap.virtual=h<g/2-1,c.push(y)}return c}intersects(i,r){return i?i.p1&&i.p2?this.lineIntersects(i):(i instanceof Bt&&(i=i.reduce()),this.curveintersects(this.reduce(),i,r)):this.selfintersects(r)}lineIntersects(i){const r=dy(i.p1.x,i.p2.x),u=dy(i.p1.y,i.p2.y),o=gy(i.p1.x,i.p2.x),c=gy(i.p1.y,i.p2.y);return lt.roots(this.points,i).filter(h=>{var g=this.get(h);return lt.between(g.x,r,o)&<.between(g.y,u,c)})}selfintersects(i){const r=this.reduce(),u=r.length-2,o=[];for(let c=0,h,g,y;c<u;c++)g=r.slice(c,c+1),y=r.slice(c+2),h=this.curveintersects(g,y,i),o.push(...h);return o}curveintersects(i,r,u){const o=[];i.forEach(function(h){r.forEach(function(g){h.overlaps(g)&&o.push({left:h,right:g})})});let c=[];return o.forEach(function(h){const g=lt.pairiteration(h.left,h.right,u);g.length>0&&(c=c.concat(g))}),c}arcs(i){return i=i||.5,this._iterate(i,[])}_error(i,r,u,o){const c=(o-u)/4,h=this.get(u+c),g=this.get(o-c),y=lt.dist(i,r),p=lt.dist(i,h),v=lt.dist(i,g);return rl(p-y)+rl(v-y)}_iterate(i,r){let u=0,o=1,c;do{c=0,o=1;let h=this.get(u),g,y,p,v,m=!1,_=!1,x,A=o,M=1;do if(_=m,v=p,A=(u+o)/2,g=this.get(A),y=this.get(o),p=lt.getccenter(h,g,y),p.interval={start:u,end:o},m=this._error(p,h,u,o)<=i,x=_&&!m,x||(M=o),m){if(o>=1){if(p.interval.end=M=1,v=p,o>1){let S={x:p.x+p.r*SA(p.e),y:p.y+p.r*AA(p.e)};p.e+=lt.angle({x:p.x,y:p.y},S,this.get(1))}break}o=o+(o-u)/2}else o=A;while(!x&&c++<100);if(c>=100)break;v=v||p,r.push(v),u=M}while(o<1);return r}}function qf(n,i){(i==null||i>n.length)&&(i=n.length);for(var r=0,u=Array(i);r<i;r++)u[r]=n[r];return u}function OA(n){if(Array.isArray(n))return n}function MA(n){if(Array.isArray(n))return qf(n)}function CA(n){if(typeof Symbol<"u"&&n[Symbol.iterator]!=null||n["@@iterator"]!=null)return Array.from(n)}function NA(n,i){var r=n==null?null:typeof Symbol<"u"&&n[Symbol.iterator]||n["@@iterator"];if(r!=null){var u,o,c,h,g=[],y=!0,p=!1;try{if(c=(r=r.call(n)).next,i!==0)for(;!(y=(u=c.call(r)).done)&&(g.push(u.value),g.length!==i);y=!0);}catch(v){p=!0,o=v}finally{try{if(!y&&r.return!=null&&(h=r.return(),Object(h)!==h))return}finally{if(p)throw o}}return g}}function zA(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
|
|
143
|
-
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function RA(){throw new TypeError(`Invalid attempt to spread non-iterable instance.
|
|
144
|
-
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function DA(n,i){if(n==null)return{};var r,u,o=jA(n,i);if(Object.getOwnPropertySymbols){var c=Object.getOwnPropertySymbols(n);for(u=0;u<c.length;u++)r=c[u],i.includes(r)||{}.propertyIsEnumerable.call(n,r)&&(o[r]=n[r])}return o}function jA(n,i){if(n==null)return{};var r={};for(var u in n)if({}.hasOwnProperty.call(n,u)){if(i.includes(u))continue;r[u]=n[u]}return r}function kA(n,i){return OA(n)||NA(n,i)||Fm(n,i)||zA()}function UA(n){return MA(n)||CA(n)||Fm(n)||RA()}function qA(n,i){if(typeof n!="object"||!n)return n;var r=n[Symbol.toPrimitive];if(r!==void 0){var u=r.call(n,i);if(typeof u!="object")return u;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(n)}function HA(n){var i=qA(n,"string");return typeof i=="symbol"?i:i+""}function Fm(n,i){if(n){if(typeof n=="string")return qf(n,i);var r={}.toString.call(n).slice(8,-1);return r==="Object"&&n.constructor&&(r=n.constructor.name),r==="Map"||r==="Set"?Array.from(n):r==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?qf(n,i):void 0}}var LA=function(){var n=arguments.length>0&&arguments[0]!==void 0?arguments[0]:[],i=arguments.length>1&&arguments[1]!==void 0?arguments[1]:[],r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:!0,u=arguments.length>3&&arguments[3]!==void 0?arguments[3]:!1,o=(i instanceof Array?i.length?i:[void 0]:[i]).map(function(g){return{keyAccessor:g,isProp:!(g instanceof Function)}}),c=n.reduce(function(g,y){var p=g,v=y;return o.forEach(function(m,_){var x=m.keyAccessor,A=m.isProp,M;if(A){var O=v,S=O[x],j=DA(O,[x].map(HA));M=S,v=j}else M=x(v,_);_+1<o.length?(p.hasOwnProperty(M)||(p[M]={}),p=p[M]):r?(p.hasOwnProperty(M)||(p[M]=[]),p[M].push(v)):p[M]=v}),g},{});r instanceof Function&&function g(y){var p=arguments.length>1&&arguments[1]!==void 0?arguments[1]:1;p===o.length?Object.keys(y).forEach(function(v){return y[v]=r(y[v])}):Object.values(y).forEach(function(v){return g(v,p+1)})}(c);var h=c;return u&&(h=[],function g(y){var p=arguments.length>1&&arguments[1]!==void 0?arguments[1]:[];p.length===o.length?h.push({keys:p,vals:y}):Object.entries(y).forEach(function(v){var m=kA(v,2),_=m[0],x=m[1];return g(x,[].concat(UA(p),[_]))})}(c),i instanceof Array&&i.length===0&&h.length===1&&(h[0].keys=[])),h};function BA(n,i){switch(arguments.length){case 0:break;case 1:this.range(n);break;default:this.range(i).domain(n);break}return this}const py=Symbol("implicit");function Pm(){var n=new Up,i=[],r=[],u=py;function o(c){let h=n.get(c);if(h===void 0){if(u!==py)return u;n.set(c,h=i.push(c)-1)}return r[h%r.length]}return o.domain=function(c){if(!arguments.length)return i.slice();i=[],n=new Up;for(const h of c)n.has(h)||n.set(h,i.push(h)-1);return o},o.range=function(c){return arguments.length?(r=Array.from(c),o):r.slice()},o.unknown=function(c){return arguments.length?(u=c,o):u},o.copy=function(){return Pm(i,r).unknown(u)},BA.apply(o,arguments),o}function GA(n){for(var i=n.length/6|0,r=new Array(i),u=0;u<i;)r[u]="#"+n.slice(u*6,++u*6);return r}const QA=GA("a6cee31f78b4b2df8a33a02cfb9a99e31a1cfdbf6fff7f00cab2d66a3d9affff99b15928");function YA(n,i){i===void 0&&(i={});var r=i.insertAt;if(!(typeof document>"u")){var u=document.head||document.getElementsByTagName("head")[0],o=document.createElement("style");o.type="text/css",r==="top"&&u.firstChild?u.insertBefore(o,u.firstChild):u.appendChild(o),o.styleSheet?o.styleSheet.cssText=n:o.appendChild(document.createTextNode(n))}}var XA=`.force-graph-container canvas {
|
|
145
|
-
display: block;
|
|
146
|
-
user-select: none;
|
|
147
|
-
outline: none;
|
|
148
|
-
-webkit-tap-highlight-color: transparent;
|
|
149
|
-
}
|
|
150
|
-
|
|
151
|
-
.force-graph-container .clickable {
|
|
152
|
-
cursor: pointer;
|
|
153
|
-
}
|
|
154
|
-
|
|
155
|
-
.force-graph-container .grabbable {
|
|
156
|
-
cursor: move;
|
|
157
|
-
cursor: grab;
|
|
158
|
-
cursor: -moz-grab;
|
|
159
|
-
cursor: -webkit-grab;
|
|
160
|
-
}
|
|
161
|
-
|
|
162
|
-
.force-graph-container .grabbable:active {
|
|
163
|
-
cursor: grabbing;
|
|
164
|
-
cursor: -moz-grabbing;
|
|
165
|
-
cursor: -webkit-grabbing;
|
|
166
|
-
}
|
|
167
|
-
`;YA(XA);function Hf(n,i){(i==null||i>n.length)&&(i=n.length);for(var r=0,u=Array(i);r<i;r++)u[r]=n[r];return u}function VA(n){if(Array.isArray(n))return n}function $A(n){if(Array.isArray(n))return Hf(n)}function yy(n,i,r){if(Jm())return Reflect.construct.apply(null,arguments);var u=[null];u.push.apply(u,i);var o=new(n.bind.apply(n,u));return o}function wl(n,i,r){return(i=WA(i))in n?Object.defineProperty(n,i,{value:r,enumerable:!0,configurable:!0,writable:!0}):n[i]=r,n}function Jm(){try{var n=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(Jm=function(){return!!n})()}function ZA(n){if(typeof Symbol<"u"&&n[Symbol.iterator]!=null||n["@@iterator"]!=null)return Array.from(n)}function KA(n,i){var r=n==null?null:typeof Symbol<"u"&&n[Symbol.iterator]||n["@@iterator"];if(r!=null){var u,o,c,h,g=[],y=!0,p=!1;try{if(c=(r=r.call(n)).next,i!==0)for(;!(y=(u=c.call(r)).done)&&(g.push(u.value),g.length!==i);y=!0);}catch(v){p=!0,o=v}finally{try{if(!y&&r.return!=null&&(h=r.return(),Object(h)!==h))return}finally{if(p)throw o}}return g}}function FA(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
|
|
168
|
-
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function PA(){throw new TypeError(`Invalid attempt to spread non-iterable instance.
|
|
169
|
-
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function my(n,i){var r=Object.keys(n);if(Object.getOwnPropertySymbols){var u=Object.getOwnPropertySymbols(n);i&&(u=u.filter(function(o){return Object.getOwnPropertyDescriptor(n,o).enumerable})),r.push.apply(r,u)}return r}function Va(n){for(var i=1;i<arguments.length;i++){var r=arguments[i]!=null?arguments[i]:{};i%2?my(Object(r),!0).forEach(function(u){wl(n,u,r[u])}):Object.getOwnPropertyDescriptors?Object.defineProperties(n,Object.getOwnPropertyDescriptors(r)):my(Object(r)).forEach(function(u){Object.defineProperty(n,u,Object.getOwnPropertyDescriptor(r,u))})}return n}function gl(n,i){return VA(n)||KA(n,i)||Wm(n,i)||FA()}function tn(n){return $A(n)||ZA(n)||Wm(n)||PA()}function JA(n,i){if(typeof n!="object"||!n)return n;var r=n[Symbol.toPrimitive];if(r!==void 0){var u=r.call(n,i);if(typeof u!="object")return u;throw new TypeError("@@toPrimitive must return a primitive value.")}return(i==="string"?String:Number)(n)}function WA(n){var i=JA(n,"string");return typeof i=="symbol"?i:i+""}function Lf(n){"@babel/helpers - typeof";return Lf=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(i){return typeof i}:function(i){return i&&typeof Symbol=="function"&&i.constructor===Symbol&&i!==Symbol.prototype?"symbol":typeof i},Lf(n)}function Wm(n,i){if(n){if(typeof n=="string")return Hf(n,i);var r={}.toString.call(n).slice(8,-1);return r==="Object"&&n.constructor&&(r=n.constructor.name),r==="Map"||r==="Set"?Array.from(n):r==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?Hf(n,i):void 0}}var IA=Pm(QA);function vy(n,i,r){!i||typeof r!="string"||n.filter(function(u){return!u[r]}).forEach(function(u){u[r]=IA(i(u))})}function tE(n,i){var r=n.nodes,u=n.links,o=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},c=o.nodeFilter,h=c===void 0?function(){return!0}:c,g=o.onLoopError,y=g===void 0?function(x){throw"Invalid DAG structure! Found cycle in node path: ".concat(x.join(" -> "),".")}:g,p={};r.forEach(function(x){return p[i(x)]={data:x,out:[],depth:-1,skip:!h(x)}}),u.forEach(function(x){var A=x.source,M=x.target,O=R(A),S=R(M);if(!p.hasOwnProperty(O))throw"Missing source node with id: ".concat(O);if(!p.hasOwnProperty(S))throw"Missing target node with id: ".concat(S);var j=p[O],H=p[S];j.out.push(H);function R(C){return Lf(C)==="object"?i(C):C}});var v=[];_(Object.values(p));var m=Object.assign.apply(Object,[{}].concat(tn(Object.entries(p).filter(function(x){var A=gl(x,2),M=A[1];return!M.skip}).map(function(x){var A=gl(x,2),M=A[0],O=A[1];return wl({},M,O.depth)}))));return m;function _(x){for(var A=arguments.length>1&&arguments[1]!==void 0?arguments[1]:[],M=arguments.length>2&&arguments[2]!==void 0?arguments[2]:0,O=function(){var R=x[S];if(A.indexOf(R)!==-1){var C=[].concat(tn(A.slice(A.indexOf(R))),[R]).map(function(q){return i(q.data)});return v.some(function(q){return q.length===C.length&&q.every(function(U,Q){return U===C[Q]})})||(v.push(C),y(C)),1}M>R.depth&&(R.depth=M,_(R.out,[].concat(tn(A),[R]),M+(R.skip?0:1)))},S=0,j=x.length;S<j;S++)O()}}var eE=2,me=function(i,r){return r.onNeedsRedraw&&r.onNeedsRedraw()},by=function(i,r){if(!r.isShadow){var u=Dt(r.linkDirectionalParticles);r.graphData.links.forEach(function(o){var c=Math.round(Math.abs(u(o)));c?o.__photons=tn(Array(c)).map(function(){return{}}):delete o.__photons})}},ys=th({props:{graphData:{default:{nodes:[],links:[]},onChange:function(i,r){r.engineRunning=!1,by(i,r)}},dagMode:{onChange:function(i,r){!i&&(r.graphData.nodes||[]).forEach(function(u){return u.fx=u.fy=void 0})}},dagLevelDistance:{},dagNodeFilter:{default:function(i){return!0}},onDagError:{triggerUpdate:!1},nodeRelSize:{default:4,triggerUpdate:!1,onChange:me},nodeId:{default:"id"},nodeVal:{default:"val",triggerUpdate:!1,onChange:me},nodeColor:{default:"color",triggerUpdate:!1,onChange:me},nodeAutoColorBy:{},nodeCanvasObject:{triggerUpdate:!1,onChange:me},nodeCanvasObjectMode:{default:function(){return"replace"},triggerUpdate:!1,onChange:me},nodeVisibility:{default:!0,triggerUpdate:!1,onChange:me},linkSource:{default:"source"},linkTarget:{default:"target"},linkVisibility:{default:!0,triggerUpdate:!1,onChange:me},linkColor:{default:"color",triggerUpdate:!1,onChange:me},linkAutoColorBy:{},linkLineDash:{triggerUpdate:!1,onChange:me},linkWidth:{default:1,triggerUpdate:!1,onChange:me},linkCurvature:{default:0,triggerUpdate:!1,onChange:me},linkCanvasObject:{triggerUpdate:!1,onChange:me},linkCanvasObjectMode:{default:function(){return"replace"},triggerUpdate:!1,onChange:me},linkDirectionalArrowLength:{default:0,triggerUpdate:!1,onChange:me},linkDirectionalArrowColor:{triggerUpdate:!1,onChange:me},linkDirectionalArrowRelPos:{default:.5,triggerUpdate:!1,onChange:me},linkDirectionalParticles:{default:0,triggerUpdate:!1,onChange:by},linkDirectionalParticleSpeed:{default:.01,triggerUpdate:!1},linkDirectionalParticleOffset:{default:0,triggerUpdate:!1},linkDirectionalParticleWidth:{default:4,triggerUpdate:!1},linkDirectionalParticleColor:{triggerUpdate:!1},linkDirectionalParticleCanvasObject:{triggerUpdate:!1},globalScale:{default:1,triggerUpdate:!1},d3AlphaMin:{default:0,triggerUpdate:!1},d3AlphaDecay:{default:.0228,triggerUpdate:!1,onChange:function(i,r){r.forceLayout.alphaDecay(i)}},d3AlphaTarget:{default:0,triggerUpdate:!1,onChange:function(i,r){r.forceLayout.alphaTarget(i)}},d3VelocityDecay:{default:.4,triggerUpdate:!1,onChange:function(i,r){r.forceLayout.velocityDecay(i)}},warmupTicks:{default:0,triggerUpdate:!1},cooldownTicks:{default:1/0,triggerUpdate:!1},cooldownTime:{default:15e3,triggerUpdate:!1},onUpdate:{default:function(){},triggerUpdate:!1},onFinishUpdate:{default:function(){},triggerUpdate:!1},onEngineTick:{default:function(){},triggerUpdate:!1},onEngineStop:{default:function(){},triggerUpdate:!1},onNeedsRedraw:{triggerUpdate:!1},isShadow:{default:!1,triggerUpdate:!1}},methods:{d3Force:function(i,r,u){return u===void 0?i.forceLayout.force(r):(i.forceLayout.force(r,u),this)},d3ReheatSimulation:function(i){return i.forceLayout.alpha(1),this.resetCountdown(),this},resetCountdown:function(i){return i.cntTicks=0,i.startTickTime=new Date,i.engineRunning=!0,this},isEngineRunning:function(i){return!!i.engineRunning},tickFrame:function(i){return!i.isShadow&&r(),o(),!i.isShadow&&c(),!i.isShadow&&h(),u(),this;function r(){i.engineRunning&&(++i.cntTicks>i.cooldownTicks||new Date-i.startTickTime>i.cooldownTime||i.d3AlphaMin>0&&i.forceLayout.alpha()<i.d3AlphaMin?(i.engineRunning=!1,i.onEngineStop()):(i.forceLayout.tick(),i.onEngineTick()))}function u(){var g=Dt(i.nodeVisibility),y=Dt(i.nodeVal),p=Dt(i.nodeColor),v=Dt(i.nodeCanvasObjectMode),m=i.ctx,_=i.isShadow/i.globalScale,x=i.graphData.nodes.filter(g);m.save(),x.forEach(function(A){var M=v(A);if(i.nodeCanvasObject&&(M==="before"||M==="replace")&&(i.nodeCanvasObject(A,m,i.globalScale),M==="replace")){m.restore();return}var O=Math.sqrt(Math.max(0,y(A)||1))*i.nodeRelSize+_;m.beginPath(),m.arc(A.x,A.y,O,0,2*Math.PI,!1),m.fillStyle=p(A)||"rgba(31, 120, 180, 0.92)",m.fill(),i.nodeCanvasObject&&M==="after"&&i.nodeCanvasObject(A,i.ctx,i.globalScale)}),m.restore()}function o(){var g=Dt(i.linkVisibility),y=Dt(i.linkColor),p=Dt(i.linkWidth),v=Dt(i.linkLineDash),m=Dt(i.linkCurvature),_=Dt(i.linkCanvasObjectMode),x=i.ctx,A=i.isShadow*2,M=i.graphData.links.filter(g);M.forEach(q);var O=[],S=[],j=M;if(i.linkCanvasObject){var H=[],R=[];M.forEach(function(U){return({before:O,after:S,replace:H}[_(U)]||R).push(U)}),j=[].concat(tn(O),S,R),O=O.concat(H)}x.save(),O.forEach(function(U){return i.linkCanvasObject(U,x,i.globalScale)}),x.restore();var C=LA(j,[y,p,v]);x.save(),Object.entries(C).forEach(function(U){var Q=gl(U,2),tt=Q[0],F=Q[1],K=!tt||tt==="undefined"?"rgba(0,0,0,0.15)":tt;Object.entries(F).forEach(function(it){var ct=gl(it,2),L=ct[0],J=ct[1],N=(L||1)/i.globalScale+A;Object.entries(J).forEach(function(Z){var et=gl(Z,2);et[0];var ut=et[1],T=v(ut[0]);x.beginPath(),ut.forEach(function($){var nt=$.source,at=$.target;if(!(!nt||!at||!nt.hasOwnProperty("x")||!at.hasOwnProperty("x"))){x.moveTo(nt.x,nt.y);var st=$.__controlPoints;st?x[st.length===2?"quadraticCurveTo":"bezierCurveTo"].apply(x,tn(st).concat([at.x,at.y])):x.lineTo(at.x,at.y)}}),x.strokeStyle=K,x.lineWidth=N,x.setLineDash(T||[]),x.stroke()})})}),x.restore(),x.save(),S.forEach(function(U){return i.linkCanvasObject(U,x,i.globalScale)}),x.restore();function q(U){var Q=m(U);if(!Q){U.__controlPoints=null;return}var tt=U.source,F=U.target;if(!(!tt||!F||!tt.hasOwnProperty("x")||!F.hasOwnProperty("x"))){var K=Math.sqrt(Math.pow(F.x-tt.x,2)+Math.pow(F.y-tt.y,2));if(K>0){var it=Math.atan2(F.y-tt.y,F.x-tt.x),ct=K*Q,L={x:(tt.x+F.x)/2+ct*Math.cos(it-Math.PI/2),y:(tt.y+F.y)/2+ct*Math.sin(it-Math.PI/2)};U.__controlPoints=[L.x,L.y]}else{var J=Q*70;U.__controlPoints=[F.x,F.y-J,F.x+J,F.y]}}}}function c(){var g=1.6,y=.2,p=Dt(i.linkDirectionalArrowLength),v=Dt(i.linkDirectionalArrowRelPos),m=Dt(i.linkVisibility),_=Dt(i.linkDirectionalArrowColor||i.linkColor),x=Dt(i.nodeVal),A=i.ctx;A.save(),i.graphData.links.filter(m).forEach(function(M){var O=p(M);if(!(!O||O<0)){var S=M.source,j=M.target;if(!(!S||!j||!S.hasOwnProperty("x")||!j.hasOwnProperty("x"))){var H=Math.sqrt(Math.max(0,x(S)||1))*i.nodeRelSize,R=Math.sqrt(Math.max(0,x(j)||1))*i.nodeRelSize,C=Math.min(1,Math.max(0,v(M))),q=_(M)||"rgba(0,0,0,0.28)",U=O/g/2,Q=M.__controlPoints&&yy(Bt,[S.x,S.y].concat(tn(M.__controlPoints),[j.x,j.y])),tt=Q?function(N){return Q.get(N)}:function(N){return{x:S.x+(j.x-S.x)*N||0,y:S.y+(j.y-S.y)*N||0}},F=Q?Q.length():Math.sqrt(Math.pow(j.x-S.x,2)+Math.pow(j.y-S.y,2)),K=H+O+(F-H-R-O)*C,it=tt(K/F),ct=tt((K-O)/F),L=tt((K-O*(1-y))/F),J=Math.atan2(it.y-ct.y,it.x-ct.x)-Math.PI/2;A.beginPath(),A.moveTo(it.x,it.y),A.lineTo(ct.x+U*Math.cos(J),ct.y+U*Math.sin(J)),A.lineTo(L.x,L.y),A.lineTo(ct.x-U*Math.cos(J),ct.y-U*Math.sin(J)),A.fillStyle=q,A.fill()}}}),A.restore()}function h(){var g=Dt(i.linkDirectionalParticles),y=Dt(i.linkDirectionalParticleSpeed),p=Dt(i.linkDirectionalParticleOffset),v=Dt(i.linkDirectionalParticleWidth),m=Dt(i.linkVisibility),_=Dt(i.linkDirectionalParticleColor||i.linkColor),x=i.ctx;x.save(),i.graphData.links.filter(m).forEach(function(A){var M=g(A);if(!(!A.hasOwnProperty("__photons")||!A.__photons.length)){var O=A.source,S=A.target;if(!(!O||!S||!O.hasOwnProperty("x")||!S.hasOwnProperty("x"))){var j=y(A),H=Math.abs(p(A)),R=A.__photons||[],C=Math.max(0,v(A)/2)/Math.sqrt(i.globalScale),q=_(A)||"rgba(0,0,0,0.28)";x.fillStyle=q;var U=A.__controlPoints?yy(Bt,[O.x,O.y].concat(tn(A.__controlPoints),[S.x,S.y])):null,Q=0,tt=!1;R.forEach(function(F){var K=!!F.__singleHop;if(F.hasOwnProperty("__progressRatio")||(F.__progressRatio=K?0:(Q+H)/M),!K&&Q++,F.__progressRatio+=j,F.__progressRatio>=1)if(!K)F.__progressRatio=F.__progressRatio%1;else{tt=!0;return}var it=F.__progressRatio,ct=U?U.get(it):{x:O.x+(S.x-O.x)*it||0,y:O.y+(S.y-O.y)*it||0};i.linkDirectionalParticleCanvasObject?i.linkDirectionalParticleCanvasObject(ct.x,ct.y,A,x,i.globalScale):(x.beginPath(),x.arc(ct.x,ct.y,C,0,2*Math.PI,!1),x.fill())}),tt&&(A.__photons=A.__photons.filter(function(F){return!F.__singleHop||F.__progressRatio<=1}))}}}),x.restore()}},emitParticle:function(i,r){return r&&(!r.__photons&&(r.__photons=[]),r.__photons.push({__singleHop:!0})),this}},stateInit:function(){return{forceLayout:mA().force("link",oA()).force("charge",vA()).force("center",f4()).force("dagRadial",null).stop(),engineRunning:!1}},init:function(i,r){r.ctx=i},update:function(i,r){i.engineRunning=!1,i.onUpdate(),i.nodeAutoColorBy!==null&&vy(i.graphData.nodes,Dt(i.nodeAutoColorBy),i.nodeColor),i.linkAutoColorBy!==null&&vy(i.graphData.links,Dt(i.linkAutoColorBy),i.linkColor),i.graphData.links.forEach(function(_){_.source=_[i.linkSource],_.target=_[i.linkTarget]}),i.forceLayout.stop().alpha(1).nodes(i.graphData.nodes);var u=i.forceLayout.force("link");u&&u.id(function(_){return _[i.nodeId]}).links(i.graphData.links);var o=i.dagMode&&tE(i.graphData,function(_){return _[i.nodeId]},{nodeFilter:i.dagNodeFilter,onLoopError:i.onDagError||void 0}),c=Math.max.apply(Math,tn(Object.values(o||[]))),h=i.dagLevelDistance||i.graphData.nodes.length/(c||1)*eE*(["radialin","radialout"].indexOf(i.dagMode)!==-1?.7:1);if(["lr","rl","td","bu"].includes(r.dagMode)){var g=["lr","rl"].includes(r.dagMode)?"fx":"fy";i.graphData.nodes.filter(i.dagNodeFilter).forEach(function(_){return delete _[g]})}if(["lr","rl","td","bu"].includes(i.dagMode)){var y=["rl","bu"].includes(i.dagMode),p=function(x){return(o[x[i.nodeId]]-c/2)*h*(y?-1:1)},v=["lr","rl"].includes(i.dagMode)?"fx":"fy";i.graphData.nodes.filter(i.dagNodeFilter).forEach(function(_){return _[v]=p(_)})}i.forceLayout.force("dagRadial",["radialin","radialout"].indexOf(i.dagMode)!==-1?bA(function(_){var x=o[_[i.nodeId]]||-1;return(i.dagMode==="radialin"?c-x:x)*h}).strength(function(_){return i.dagNodeFilter(_)?1:0}):null);for(var m=0;m<i.warmupTicks&&!(i.d3AlphaMin>0&&i.forceLayout.alpha()<i.d3AlphaMin);m++)i.forceLayout.tick();this.resetCountdown(),i.onFinishUpdate()}});function Im(n,i){var r=n instanceof Array?n:[n],u=new i;return u._destructor&&u._destructor(),{linkProp:function(c){return{default:u[c](),onChange:function(g,y){r.forEach(function(p){return y[p][c](g)})},triggerUpdate:!1}},linkMethod:function(c){return function(h){for(var g=arguments.length,y=new Array(g>1?g-1:0),p=1;p<g;p++)y[p-1]=arguments[p];var v=[];return r.forEach(function(m){var _=h[m],x=_[c].apply(_,y);x!==_&&v.push(x)}),v.length?v[0]:this}}}}var nE=800,iE=4,aE=5,tv=Im("forceGraph",ys),rE=Im(["forceGraph","shadowGraph"],ys),lE=Object.assign.apply(Object,tn(["nodeColor","nodeAutoColorBy","nodeCanvasObject","nodeCanvasObjectMode","linkColor","linkAutoColorBy","linkLineDash","linkWidth","linkCanvasObject","linkCanvasObjectMode","linkDirectionalArrowLength","linkDirectionalArrowColor","linkDirectionalArrowRelPos","linkDirectionalParticles","linkDirectionalParticleSpeed","linkDirectionalParticleOffset","linkDirectionalParticleWidth","linkDirectionalParticleColor","linkDirectionalParticleCanvasObject","dagMode","dagLevelDistance","dagNodeFilter","onDagError","d3AlphaMin","d3AlphaDecay","d3VelocityDecay","warmupTicks","cooldownTicks","cooldownTime","onEngineTick","onEngineStop"].map(function(n){return wl({},n,tv.linkProp(n))})).concat(tn(["nodeRelSize","nodeId","nodeVal","nodeVisibility","linkSource","linkTarget","linkVisibility","linkCurvature"].map(function(n){return wl({},n,rE.linkProp(n))})))),uE=Object.assign.apply(Object,tn(["d3Force","d3ReheatSimulation","emitParticle"].map(function(n){return wl({},n,tv.linkMethod(n))})));function of(n){if(n.canvas){var i=n.canvas.width,r=n.canvas.height;i===300&&r===150&&(i=r=0);var u=window.devicePixelRatio;i/=u,r/=u,[n.canvas,n.shadowCanvas].forEach(function(c){c.style.width="".concat(n.width,"px"),c.style.height="".concat(n.height,"px"),c.width=n.width*u,c.height=n.height*u,!i&&!r&&c.getContext("2d").scale(u,u)});var o=mn(n.canvas).k;n.zoom.translateBy(n.zoom.__baseElem,(n.width-i)/2/o,(n.height-r)/2/o),n.needsRedraw=!0}}function ev(n){var i=window.devicePixelRatio;n.setTransform(i,0,0,i,0,0)}function _y(n,i,r){n.save(),ev(n),n.clearRect(0,0,i,r),n.restore()}var sE=th({props:Va({width:{default:window.innerWidth,onChange:function(i,r){return of(r)},triggerUpdate:!1},height:{default:window.innerHeight,onChange:function(i,r){return of(r)},triggerUpdate:!1},graphData:{default:{nodes:[],links:[]},onChange:function(i,r){[i.nodes,i.links].every(function(o){return(o||[]).every(function(c){return!c.hasOwnProperty("__indexColor")})})&&r.colorTracker.reset(),[{type:"Node",objs:i.nodes},{type:"Link",objs:i.links}].forEach(u),r.forceGraph.graphData(i),r.shadowGraph.graphData(i);function u(o){var c=o.type,h=o.objs;h.filter(function(g){if(!g.hasOwnProperty("__indexColor"))return!0;var y=r.colorTracker.lookup(g.__indexColor);return!y||!y.hasOwnProperty("d")||y.d!==g}).forEach(function(g){g.__indexColor=r.colorTracker.register({type:c,d:g})})}},triggerUpdate:!1},backgroundColor:{onChange:function(i,r){r.canvas&&i&&(r.canvas.style.background=i)},triggerUpdate:!1},nodeLabel:{default:"name",triggerUpdate:!1},nodePointerAreaPaint:{onChange:function(i,r){r.shadowGraph.nodeCanvasObject(i?function(u,o,c){return i(u,u.__indexColor,o,c)}:null),r.flushShadowCanvas&&r.flushShadowCanvas()},triggerUpdate:!1},linkPointerAreaPaint:{onChange:function(i,r){r.shadowGraph.linkCanvasObject(i?function(u,o,c){return i(u,u.__indexColor,o,c)}:null),r.flushShadowCanvas&&r.flushShadowCanvas()},triggerUpdate:!1},linkLabel:{default:"name",triggerUpdate:!1},linkHoverPrecision:{default:4,triggerUpdate:!1},minZoom:{default:.01,onChange:function(i,r){r.zoom.scaleExtent([i,r.zoom.scaleExtent()[1]])},triggerUpdate:!1},maxZoom:{default:1e3,onChange:function(i,r){r.zoom.scaleExtent([r.zoom.scaleExtent()[0],i])},triggerUpdate:!1},enableNodeDrag:{default:!0,triggerUpdate:!1},enableZoomInteraction:{default:!0,triggerUpdate:!1},enablePanInteraction:{default:!0,triggerUpdate:!1},enableZoomPanInteraction:{default:!0,triggerUpdate:!1},enablePointerInteraction:{default:!0,onChange:function(i,r){r.hoverObj=null},triggerUpdate:!1},autoPauseRedraw:{default:!0,triggerUpdate:!1},onNodeDrag:{default:function(){},triggerUpdate:!1},onNodeDragEnd:{default:function(){},triggerUpdate:!1},onNodeClick:{triggerUpdate:!1},onNodeRightClick:{triggerUpdate:!1},onNodeHover:{triggerUpdate:!1},onLinkClick:{triggerUpdate:!1},onLinkRightClick:{triggerUpdate:!1},onLinkHover:{triggerUpdate:!1},onBackgroundClick:{triggerUpdate:!1},onBackgroundRightClick:{triggerUpdate:!1},onZoom:{triggerUpdate:!1},onZoomEnd:{triggerUpdate:!1},onRenderFramePre:{triggerUpdate:!1},onRenderFramePost:{triggerUpdate:!1}},lE),aliases:{stopAnimation:"pauseAnimation"},methods:Va({graph2ScreenCoords:function(i,r,u){var o=mn(i.canvas);return{x:r*o.k+o.x,y:u*o.k+o.y}},screen2GraphCoords:function(i,r,u){var o=mn(i.canvas);return{x:(r-o.x)/o.k,y:(u-o.y)/o.k}},centerAt:function(i,r,u,o){if(!i.canvas)return null;if(r!==void 0||u!==void 0){var c=Object.assign({},r!==void 0?{x:r}:{},u!==void 0?{y:u}:{});return o?i.tweenGroup.add(new Yp(h()).to(c,o).easing(Ji.Quadratic.Out).onUpdate(g).start()):g(c),this}return h();function h(){var y=mn(i.canvas);return{x:(i.width/2-y.x)/y.k,y:(i.height/2-y.y)/y.k}}function g(y){var p=y.x,v=y.y;i.zoom.translateTo(i.zoom.__baseElem,p===void 0?h().x:p,v===void 0?h().y:v),i.needsRedraw=!0}},zoom:function(i,r,u){if(!i.canvas)return null;if(r!==void 0)return u?i.tweenGroup.add(new Yp({k:o()}).to({k:r},u).easing(Ji.Quadratic.Out).onUpdate(function(h){var g=h.k;return c(g)}).start()):c(r),this;return o();function o(){return mn(i.canvas).k}function c(h){i.zoom.scaleTo(i.zoom.__baseElem,h),i.needsRedraw=!0}},zoomToFit:function(i){for(var r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:0,u=arguments.length>2&&arguments[2]!==void 0?arguments[2]:10,o=arguments.length,c=new Array(o>3?o-3:0),h=3;h<o;h++)c[h-3]=arguments[h];var g=this.getGraphBbox.apply(this,c);if(g){var y={x:(g.x[0]+g.x[1])/2,y:(g.y[0]+g.y[1])/2},p=Math.max(1e-12,Math.min(1e12,(i.width-u*2)/(g.x[1]-g.x[0]),(i.height-u*2)/(g.y[1]-g.y[0])));this.centerAt(y.x,y.y,r),this.zoom(p,r)}return this},getGraphBbox:function(i){var r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:function(){return!0},u=Dt(i.nodeVal),o=function(g){return Math.sqrt(Math.max(0,u(g)||1))*i.nodeRelSize},c=i.graphData.nodes.filter(r).map(function(h){return{x:h.x,y:h.y,r:o(h)}});return c.length?{x:[Lp(c,function(h){return h.x-h.r}),Hp(c,function(h){return h.x+h.r})],y:[Lp(c,function(h){return h.y-h.r}),Hp(c,function(h){return h.y+h.r})]}:null},pauseAnimation:function(i){return i.animationFrameRequestId&&(cancelAnimationFrame(i.animationFrameRequestId),i.animationFrameRequestId=null),this},resumeAnimation:function(i){return i.animationFrameRequestId||this._animationCycle(),this},_destructor:function(){this.pauseAnimation(),this.graphData({nodes:[],links:[]})}},uE),stateInit:function(){return{lastSetZoom:1,zoom:bS(),forceGraph:new ys,shadowGraph:new ys().cooldownTicks(0).nodeColor("__indexColor").linkColor("__indexColor").isShadow(!0),colorTracker:new Y3,tweenGroup:new Sm}},init:function(i,r){var u=this;i.innerHTML="";var o=document.createElement("div");o.classList.add("force-graph-container"),o.style.position="relative",i.appendChild(o),r.canvas=document.createElement("canvas"),r.backgroundColor&&(r.canvas.style.background=r.backgroundColor),o.appendChild(r.canvas),r.shadowCanvas=document.createElement("canvas");var c=r.canvas.getContext("2d"),h=r.shadowCanvas.getContext("2d",{willReadFrequently:!0}),g={x:-1e12,y:-1e12},y=function(){var m=null,_=window.devicePixelRatio,x=g.x>0&&g.y>0?h.getImageData(g.x*_,g.y*_,1,1):null;return x&&(m=r.colorTracker.lookup(x.data)),m};Ie(r.canvas).call(C2().subject(function(){if(!r.enableNodeDrag)return null;var v=y();return v&&v.type==="Node"?v.d:null}).on("start",function(v){var m=v.subject;m.__initialDragPos={x:m.x,y:m.y,fx:m.fx,fy:m.fy},v.active||(m.fx=m.x,m.fy=m.y),r.canvas.classList.add("grabbable")}).on("drag",function(v){var m=v.subject,_=m.__initialDragPos,x=v,A=mn(r.canvas).k,M={x:_.x+(x.x-_.x)/A-m.x,y:_.y+(x.y-_.y)/A-m.y};["x","y"].forEach(function(O){return m["f".concat(O)]=m[O]=_[O]+(x[O]-_[O])/A}),!(!m.__dragged&&aE>=Math.sqrt(SS(["x","y"].map(function(O){return Math.pow(v[O]-_[O],2)}))))&&(r.forceGraph.d3AlphaTarget(.3).resetCountdown(),r.isPointerDragging=!0,m.__dragged=!0,r.onNodeDrag(m,M))}).on("end",function(v){var m=v.subject,_=m.__initialDragPos,x={x:m.x-_.x,y:m.y-_.y};_.fx===void 0&&(m.fx=void 0),_.fy===void 0&&(m.fy=void 0),delete m.__initialDragPos,r.forceGraph.d3AlphaTarget()&&r.forceGraph.d3AlphaTarget(0).resetCountdown(),r.canvas.classList.remove("grabbable"),r.isPointerDragging=!1,m.__dragged&&(delete m.__dragged,r.onNodeDragEnd(m,x))})),r.zoom(r.zoom.__baseElem=Ie(r.canvas)),r.zoom.__baseElem.on("dblclick.zoom",null),r.zoom.filter(function(v){return!v.button&&r.enableZoomPanInteraction&&(v.type!=="wheel"||Dt(r.enableZoomInteraction)(v))&&(v.type==="wheel"||Dt(r.enablePanInteraction)(v))}).on("zoom",function(v){var m=v.transform;[c,h].forEach(function(_){ev(_),_.translate(m.x,m.y),_.scale(m.k,m.k)}),r.isPointerDragging=!0,r.onZoom&&r.onZoom(Va(Va({},m),u.centerAt())),r.needsRedraw=!0}).on("end",function(v){r.isPointerDragging=!1,r.onZoomEnd&&r.onZoomEnd(Va(Va({},v.transform),u.centerAt()))}),of(r),r.forceGraph.onNeedsRedraw(function(){return r.needsRedraw=!0}).onFinishUpdate(function(){mn(r.canvas).k===r.lastSetZoom&&r.graphData.nodes.length&&(r.zoom.scaleTo(r.zoom.__baseElem,r.lastSetZoom=iE/Math.cbrt(r.graphData.nodes.length)),r.needsRedraw=!0)}),r.tooltip=new c4(o),["pointermove","pointerdown"].forEach(function(v){return o.addEventListener(v,function(m){v==="pointerdown"&&(r.isPointerPressed=!0,r.pointerDownEvent=m),!r.isPointerDragging&&m.type==="pointermove"&&r.onBackgroundClick&&(m.pressure>0||r.isPointerPressed)&&(m.pointerType==="mouse"||m.movementX===void 0||[m.movementX,m.movementY].some(function(A){return Math.abs(A)>1}))&&(r.isPointerDragging=!0);var _=x(o);g.x=m.pageX-_.left,g.y=m.pageY-_.top;function x(A){var M=A.getBoundingClientRect(),O=window.pageXOffset||document.documentElement.scrollLeft,S=window.pageYOffset||document.documentElement.scrollTop;return{top:M.top+S,left:M.left+O}}},{passive:!0})}),o.addEventListener("pointerup",function(v){if(r.isPointerPressed){if(r.isPointerPressed=!1,r.isPointerDragging){r.isPointerDragging=!1;return}var m=[v,r.pointerDownEvent];requestAnimationFrame(function(){if(v.button===0)if(r.hoverObj){var _=r["on".concat(r.hoverObj.type,"Click")];_&&_.apply(void 0,[r.hoverObj.d].concat(m))}else r.onBackgroundClick&&r.onBackgroundClick.apply(r,m);if(v.button===2)if(r.hoverObj){var x=r["on".concat(r.hoverObj.type,"RightClick")];x&&x.apply(void 0,[r.hoverObj.d].concat(m))}else r.onBackgroundRightClick&&r.onBackgroundRightClick.apply(r,m)})}},{passive:!0}),o.addEventListener("contextmenu",function(v){return!r.onBackgroundRightClick&&!r.onNodeRightClick&&!r.onLinkRightClick?!0:(v.preventDefault(),!1)}),r.forceGraph(c),r.shadowGraph(h);var p=PS(function(){_y(h,r.width,r.height),r.shadowGraph.linkWidth(function(m){return Dt(r.linkWidth)(m)+r.linkHoverPrecision});var v=mn(r.canvas);r.shadowGraph.globalScale(v.k).tickFrame()},nE);r.flushShadowCanvas=p.flush,(this._animationCycle=function v(){var m=!r.autoPauseRedraw||!!r.needsRedraw||r.forceGraph.isEngineRunning()||r.graphData.links.some(function(H){return H.__photons&&H.__photons.length});if(r.needsRedraw=!1,r.enablePointerInteraction){var _=r.isPointerDragging?null:y();if(_!==r.hoverObj){var x=r.hoverObj,A=x?x.type:null,M=_?_.type:null;if(A&&A!==M){var O=r["on".concat(A,"Hover")];O&&O(null,x.d)}if(M){var S=r["on".concat(M,"Hover")];S&&S(_.d,A===M?x.d:null)}r.tooltip.content(_&&Dt(r["".concat(_.type.toLowerCase(),"Label")])(_.d)||null),r.canvas.classList[_&&r["on".concat(M,"Click")]||!_&&r.onBackgroundClick?"add":"remove"]("clickable"),r.hoverObj=_}m&&p()}if(m){_y(c,r.width,r.height);var j=mn(r.canvas).k;r.onRenderFramePre&&r.onRenderFramePre(c,j),r.forceGraph.globalScale(j).tickFrame(),r.onRenderFramePost&&r.onRenderFramePost(c,j)}r.tweenGroup.update(),r.animationFrameRequestId=requestAnimationFrame(v)})()},update:function(i){}}),cf={exports:{}},ff,xy;function oE(){if(xy)return ff;xy=1;var n="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED";return ff=n,ff}var hf,wy;function cE(){if(wy)return hf;wy=1;var n=oE();function i(){}function r(){}return r.resetWarningCache=i,hf=function(){function u(h,g,y,p,v,m){if(m!==n){var _=new Error("Calling PropTypes validators directly is not supported by the `prop-types` package. Use PropTypes.checkPropTypes() to call them. Read more at http://fb.me/use-check-prop-types");throw _.name="Invariant Violation",_}}u.isRequired=u;function o(){return u}var c={array:u,bigint:u,bool:u,func:u,number:u,object:u,string:u,symbol:u,any:u,arrayOf:o,element:u,elementType:u,instanceOf:o,node:u,objectOf:o,oneOf:o,oneOfType:o,shape:o,exact:o,checkPropTypes:r,resetWarningCache:i};return c.PropTypes=c,c},hf}var Sy;function fE(){return Sy||(Sy=1,cf.exports=cE()()),cf.exports}var hE=fE();const k=Ry(hE),As={width:k.number,height:k.number,graphData:k.shape({nodes:k.arrayOf(k.object).isRequired,links:k.arrayOf(k.object).isRequired}),backgroundColor:k.string,nodeRelSize:k.number,nodeId:k.string,nodeLabel:k.oneOfType([k.string,k.func]),nodeVal:k.oneOfType([k.number,k.string,k.func]),nodeVisibility:k.oneOfType([k.bool,k.string,k.func]),nodeColor:k.oneOfType([k.string,k.func]),nodeAutoColorBy:k.oneOfType([k.string,k.func]),onNodeHover:k.func,onNodeClick:k.func,linkSource:k.string,linkTarget:k.string,linkLabel:k.oneOfType([k.string,k.func]),linkVisibility:k.oneOfType([k.bool,k.string,k.func]),linkColor:k.oneOfType([k.string,k.func]),linkAutoColorBy:k.oneOfType([k.string,k.func]),linkWidth:k.oneOfType([k.number,k.string,k.func]),linkCurvature:k.oneOfType([k.number,k.string,k.func]),linkDirectionalArrowLength:k.oneOfType([k.number,k.string,k.func]),linkDirectionalArrowColor:k.oneOfType([k.string,k.func]),linkDirectionalArrowRelPos:k.oneOfType([k.number,k.string,k.func]),linkDirectionalParticles:k.oneOfType([k.number,k.string,k.func]),linkDirectionalParticleSpeed:k.oneOfType([k.number,k.string,k.func]),linkDirectionalParticleOffset:k.oneOfType([k.number,k.string,k.func]),linkDirectionalParticleWidth:k.oneOfType([k.number,k.string,k.func]),linkDirectionalParticleColor:k.oneOfType([k.string,k.func]),onLinkHover:k.func,onLinkClick:k.func,dagMode:k.oneOf(["td","bu","lr","rl","zin","zout","radialin","radialout"]),dagLevelDistance:k.number,dagNodeFilter:k.func,onDagError:k.func,d3AlphaMin:k.number,d3AlphaDecay:k.number,d3VelocityDecay:k.number,warmupTicks:k.number,cooldownTicks:k.number,cooldownTime:k.number,onEngineTick:k.func,onEngineStop:k.func,getGraphBbox:k.func},nv={zoomToFit:k.func,onNodeRightClick:k.func,onNodeDrag:k.func,onNodeDragEnd:k.func,onLinkRightClick:k.func,linkHoverPrecision:k.number,onBackgroundClick:k.func,onBackgroundRightClick:k.func,enablePointerInteraction:k.bool,enableNodeDrag:k.bool},sh={showNavInfo:k.bool,nodeOpacity:k.number,nodeResolution:k.number,nodeThreeObject:k.oneOfType([k.object,k.string,k.func]),nodeThreeObjectExtend:k.oneOfType([k.bool,k.string,k.func]),nodePositionUpdate:k.func,linkOpacity:k.number,linkResolution:k.number,linkCurveRotation:k.oneOfType([k.number,k.string,k.func]),linkMaterial:k.oneOfType([k.object,k.string,k.func]),linkThreeObject:k.oneOfType([k.object,k.string,k.func]),linkThreeObjectExtend:k.oneOfType([k.bool,k.string,k.func]),linkPositionUpdate:k.func,linkDirectionalArrowResolution:k.number,linkDirectionalParticleResolution:k.number,linkDirectionalParticleThreeObject:k.oneOfType([k.object,k.string,k.func]),forceEngine:k.oneOf(["d3","ngraph"]),ngraphPhysics:k.object,numDimensions:k.oneOf([1,2,3])},dE=Object.assign({},As,nv,{linkLineDash:k.oneOfType([k.arrayOf(k.number),k.string,k.func]),nodeCanvasObjectMode:k.oneOfType([k.string,k.func]),nodeCanvasObject:k.func,nodePointerAreaPaint:k.func,linkCanvasObjectMode:k.oneOfType([k.string,k.func]),linkCanvasObject:k.func,linkPointerAreaPaint:k.func,linkDirectionalParticleCanvasObject:k.func,autoPauseRedraw:k.bool,minZoom:k.number,maxZoom:k.number,enableZoomInteraction:k.oneOfType([k.bool,k.func]),enablePanInteraction:k.oneOfType([k.bool,k.func]),onZoom:k.func,onZoomEnd:k.func,onRenderFramePre:k.func,onRenderFramePost:k.func});Object.assign({},As,nv,sh,{enableNavigationControls:k.bool,controlType:k.oneOf(["trackball","orbit","fly"]),rendererConfig:k.object,extraRenderers:k.arrayOf(k.shape({render:k.func.isRequired}))});Object.assign({},As,sh,{nodeDesc:k.oneOfType([k.string,k.func]),linkDesc:k.oneOfType([k.string,k.func])});Object.assign({},As,sh,{markerAttrs:k.object,yOffset:k.number,glScale:k.number});const oh=G_(sE,{methodNames:["emitParticle","d3Force","d3ReheatSimulation","stopAnimation","pauseAnimation","resumeAnimation","centerAt","zoom","zoomToFit","getGraphBbox","screen2GraphCoords","graph2ScreenCoords"]});oh.displayName="ForceGraph2D";oh.propTypes=dE;const Ay=()=>window.ELIZA_CONFIG?.apiBase?window.ELIZA_CONFIG.apiBase:"/api";function gE({onNodeClick:n,selectedMemoryId:i,agentId:r}){const u=ot.useRef(null),o=ot.useRef(null),[c,h]=ot.useState({width:800,height:600}),[g,y]=ot.useState({nodes:[],links:[]}),[p,v]=ot.useState(null),[m,_]=ot.useState(new Set),[x,A]=ot.useState(new Map),[M,O]=ot.useState(!0),[S,j]=ot.useState(null),[H,R]=ot.useState(0);ot.useEffect(()=>{const F=()=>{if(o.current){const{offsetWidth:K,offsetHeight:it}=o.current;h({width:K,height:it})}};return F(),window.addEventListener("resize",F),()=>window.removeEventListener("resize",F)},[]);const C=ot.useCallback(async(F=1)=>{O(!0),j(null);try{const K=new URLSearchParams;K.append("agentId",r),K.append("page",F.toString()),K.append("limit","20");const it=Ay(),ct=await fetch(`${it}/graph/nodes?${K.toString()}`);if(!ct.ok)throw new Error(`Failed to load graph nodes: ${ct.statusText}`);const L=await ct.json();if(L.success&&L.data){const{nodes:J,links:N,pagination:Z}=L.data,et=J.map(ut=>({id:ut.id,type:ut.type,loading:!1,val:ut.type==="document"?8:4}));F===1?(y({nodes:et,links:N}),R(1)):(y(ut=>{const T=new Set(ut.nodes.map(st=>st.id)),$=et.filter(st=>!T.has(st.id)),nt=new Set(ut.links.map(st=>`${st.source}->${st.target}`)),at=N.filter(st=>{const yt=`${st.source}->${st.target}`;return!nt.has(yt)});return{nodes:[...ut.nodes,...$],links:[...ut.links,...at]}}),R(ut=>ut+1)),v(Z)}}catch(K){console.error("Error loading graph nodes:",K),j(K instanceof Error?K.message:"Failed to load graph")}finally{O(!1)}},[r]),q=ot.useCallback(()=>{p&&p.hasMore&&C(p.currentPage+1)},[p,C]),U=ot.useCallback(async F=>{if(x.has(F)){const K=x.get(F);n(K);return}_(K=>new Set(K).add(F));try{const K=new URLSearchParams;K.append("agentId",r);const ct=`${Ay()}/graph/node/${F}?${K.toString()}`,L=await fetch(ct);if(!L.ok){const N=await L.text();throw console.error("API error response:",N),new Error(`Failed to fetch node details: ${L.statusText}`)}const J=await L.json();if(J.success&&J.data){const N={id:J.data.id,content:J.data.content,metadata:J.data.metadata,createdAt:J.data.createdAt,entityId:J.data.entityId,roomId:J.data.roomId,agentId:J.data.agentId,worldId:J.data.worldId};A(Z=>new Map(Z).set(F,N)),n(N)}else throw console.error("Invalid API response format:",J),new Error("Invalid response format from API")}catch(K){console.error("Error fetching node details:",K),alert(`Failed to load node details: ${K instanceof Error?K.message:"Unknown error"}`)}finally{_(K=>{const it=new Set(K);return it.delete(F),it})}},[r,x,n]),Q=ot.useCallback(F=>{U(F.id)},[U]);ot.useEffect(()=>{C(1)},[C]);const tt=ot.useCallback(F=>{const K=i===F.id;return m.has(F.id)?"hsl(210, 70%, 80%)":F.type==="document"?K?"hsl(30, 100%, 60%)":"hsl(30, 100%, 50%)":K?"hsl(200, 70%, 70%)":"hsl(200, 70%, 60%)"},[i,m]);return M&&g.nodes.length===0?E.jsx("div",{className:"w-full h-full flex items-center justify-center",children:E.jsx("div",{className:"text-muted-foreground",children:"Loading graph..."})}):S?E.jsx("div",{className:"w-full h-full flex items-center justify-center",children:E.jsxs("div",{className:"text-destructive",children:["Error: ",S]})}):E.jsxs("div",{ref:o,className:"w-full h-full relative",children:[E.jsxs("div",{className:"absolute top-4 right-4 p-3 bg-card/90 text-card-foreground border border-border rounded-md shadow-sm text-xs backdrop-blur-sm z-10",children:[E.jsx("div",{className:"font-medium mb-2",children:"Legend"}),E.jsxs("div",{className:"space-y-1",children:[E.jsxs("div",{className:"flex items-center gap-2",children:[E.jsx("div",{className:"w-3 h-3 rounded-full bg-orange-500"}),E.jsx("span",{children:"Document"})]}),E.jsxs("div",{className:"flex items-center gap-2",children:[E.jsx("div",{className:"w-3 h-3 rounded-full bg-blue-300"}),E.jsx("span",{children:"Fragment"})]})]})]}),p&&p.hasMore&&E.jsx("div",{className:"absolute bottom-4 left-4 z-10",children:E.jsxs("button",{onClick:q,disabled:M,className:"px-4 py-2 bg-primary text-primary-foreground rounded-md shadow-sm hover:bg-primary/90 disabled:opacity-50",children:["Load More Documents (",p.currentPage,"/",p.totalPages,")"]})}),E.jsx(oh,{ref:u,graphData:g,width:c.width,height:c.height,backgroundColor:"transparent",linkColor:()=>"hsla(var(--muted-foreground), 0.2)",linkWidth:1,linkDirectionalParticles:2,linkDirectionalParticleSpeed:.005,nodeRelSize:1,nodeVal:F=>F.val||4,nodeColor:tt,nodeLabel:F=>m.has(F.id)?"Loading...":`${F.type==="document"?"Document":"Fragment"}: ${F.id.substring(0,8)}`,onNodeClick:Q,enableNodeDrag:!0,enableZoomInteraction:!0,enablePanInteraction:!0,d3AlphaDecay:.02,d3VelocityDecay:.3,warmupTicks:100,cooldownTicks:0,nodeCanvasObject:(F,K,it)=>{const ct=F.val||4,L=i===F.id,J=m.has(F.id);K.beginPath(),K.arc(F.x,F.y,ct,0,2*Math.PI),K.fillStyle=tt(F),K.fill(),K.strokeStyle=L?"hsl(var(--primary))":"hsl(var(--border))",K.lineWidth=L?2:1,K.stroke(),J&&(K.beginPath(),K.arc(F.x,F.y,ct*1.5,0,Math.PI*2*.3),K.strokeStyle="hsl(var(--primary))",K.lineWidth=2,K.stroke())},onEngineStop:()=>{u.current&&u.current.zoomToFit(400)}},`graph-${H}`)]})}const Ml=(...n)=>n.filter(Boolean).join(" "),pE=()=>({toast:({title:n,description:i,variant:r})=>{console.log(`Toast: ${n} - ${i} (${r||"default"})`)}}),Ey=({open:n,onOpenChange:i,children:r})=>n?E.jsx("div",{className:"fixed inset-0 z-50 bg-background/80 backdrop-blur-sm flex items-center justify-center p-4",onClick:()=>i(!1),children:E.jsx("div",{className:"bg-card text-card-foreground rounded-lg shadow-lg max-w-full max-h-full flex flex-col border border-border",onClick:u=>u.stopPropagation(),children:r})}):null,Ty=({className:n,children:i})=>E.jsx("div",{className:Ml("p-6 flex flex-col border-border",n),children:i}),Oy=({className:n,children:i})=>E.jsx("div",{className:Ml("mb-4",n),children:i}),My=({className:n,children:i})=>E.jsx("h2",{className:Ml("text-lg font-semibold",n),children:i}),Cy=({className:n,children:i})=>E.jsx("p",{className:Ml("text-sm text-muted-foreground",n),children:i}),Ny=({className:n,children:i})=>E.jsx("div",{className:Ml("flex justify-end gap-2 mt-4",n),children:i}),ul=10,iv=n=>{const r=n.name.toLowerCase().split(".").pop()||"",u=["ts","tsx","js","jsx","mjs","cjs","py","pyw","pyi","java","c","cpp","cc","cxx","h","hpp","cs","php","rb","go","rs","swift","kt","kts","scala","clj","cljs","ex","exs","r","R","m","mm","sh","bash","zsh","fish","ps1","bat","cmd","sql","lua","pl","pm","dart","hs","elm","ml","fs","fsx","vb","pas","d","nim","zig","jl","tcl","awk","sed","vue","svelte","astro","gitignore","dockerignore","editorconfig","env","cfg","conf","ini","log","txt"],o=["md","markdown"],c=["json"],h=["xml"],g=["html","htm"],y=["css","scss","sass","less"],p=["csv","tsv"],v=["yaml","yml"];return u.includes(r)?"text/plain":o.includes(r)?"text/markdown":c.includes(r)?"application/json":h.includes(r)?"application/xml":g.includes(r)?"text/html":y.includes(r)?"text/css":p.includes(r)?"text/csv":v.includes(r)?"text/yaml":r==="pdf"?"application/pdf":r==="doc"?"application/msword":r==="docx"?"application/vnd.openxmlformats-officedocument.wordprocessingml.document":n.type||"application/octet-stream"},Ki=()=>window.ELIZA_CONFIG?.apiBase?window.ELIZA_CONFIG.apiBase:"/api",Sl={getKnowledgeDocuments:async(n,i)=>{const r=new URLSearchParams;i?.limit&&r.append("limit",i.limit.toString()),i?.before&&r.append("before",i.before.toString()),i?.includeEmbedding&&r.append("includeEmbedding","true");const u=Ki(),o=await fetch(`${u}/documents?${r.toString()}`);if(!o.ok){const c=await o.text();throw new Error(`Failed to fetch knowledge documents: ${o.status} ${c}`)}return await o.json()},getKnowledgeChunks:async(n,i)=>{const r=new URLSearchParams;r.append("agentId",n),i?.limit&&r.append("limit",i.limit.toString()),i?.before&&r.append("before",i.before.toString()),i?.documentId&&r.append("documentId",i.documentId),i?.documentsOnly&&r.append("documentsOnly","true");const u=Ki(),o=await fetch(`${u}/knowledges?${r.toString()}`);if(!o.ok){const c=await o.text();throw new Error(`Failed to fetch knowledge chunks: ${o.status} ${c}`)}return await o.json()},deleteKnowledgeDocument:async(n,i)=>{const r=new URLSearchParams;r.append("agentId",n);const u=Ki(),o=await fetch(`${u}/documents/${i}?${r.toString()}`,{method:"DELETE"});if(!o.ok){const c=await o.text();throw new Error(`Failed to delete knowledge document: ${o.status} ${c}`)}if(o.status!==204)return await o.json()},uploadKnowledge:async(n,i)=>{const r=new FormData;for(const c of i){const h=iv(c),g=new Blob([c],{type:h});r.append("files",g,c.name)}r.append("agentId",n);const u=Ki(),o=await fetch(`${u}/documents`,{method:"POST",body:r});if(!o.ok){const c=await o.text();throw new Error(`Failed to upload knowledge: ${o.status} ${c}`)}return await o.json()},searchKnowledge:async(n,i,r=.5,u=20)=>{const o=new URLSearchParams;o.append("agentId",n),o.append("q",i),o.append("threshold",r.toString()),o.append("limit",u.toString());const c=Ki(),h=await fetch(`${c}/search?${o.toString()}`);if(!h.ok){const g=await h.text();throw new Error(`Failed to search knowledge: ${h.status} ${g}`)}return await h.json()}},yE=(n,i=!0,r=!1)=>vf({queryKey:["agents",n,"knowledge","documents",{includeEmbedding:r}],queryFn:async()=>(await Sl.getKnowledgeDocuments(n,{includeEmbedding:r})).data.memories||[],enabled:i}),mE=(n,i=!0,r)=>{const{data:u=[],isLoading:o,error:c}=vf({queryKey:["agents",n,"knowledge","documents-graph"],queryFn:async()=>(await Sl.getKnowledgeDocuments(n,{includeEmbedding:!1})).data.memories||[],enabled:i&&!r}),{data:h=[],isLoading:g,error:y}=vf({queryKey:["agents",n,"knowledge","document-fragments",r],queryFn:async()=>r?(await Sl.getKnowledgeChunks(n,{documentId:r})).data.chunks||[]:[],enabled:i&&!!r}),p=r?h:u;return{data:p,isLoading:o||g,error:c||y,documents:r?u:p,fragments:r?h.filter(_=>_.metadata?.type==="fragment"):[],mode:r?"document-fragments":"documents-only"}},vE=n=>{const i=ms();return Kb({mutationFn:async({knowledgeId:r})=>{await Sl.deleteKnowledgeDocument(n,r)},onSuccess:()=>{i.invalidateQueries({queryKey:["agents",n,"knowledge","documents"]})}})};function bE({agentId:n}){const[i,r]=ot.useState(null),[u,o]=ot.useState(!1),[c,h]=ot.useState(ul),[g,y]=ot.useState(!1),[p,v]=ot.useState("list"),[m,_]=ot.useState(null),[x,A]=ot.useState(1),[M,O]=ot.useState(!1),[S,j]=ot.useState(""),[H,R]=ot.useState(!1),[C,q]=ot.useState(null),[U,Q]=ot.useState([]),[tt,F]=ot.useState(!1),[K,it]=ot.useState(""),[ct,L]=ot.useState(.5),[J,N]=ot.useState([]),[Z,et]=ot.useState(!1),[ut,T]=ot.useState(null),[$,nt]=ot.useState(""),[at,st]=ot.useState(void 0),yt=ot.useRef(null),ht=ot.useRef(null),{toast:Ct}=pE(),At=ms(),{data:ve=[],isLoading:Wa,error:ea}=yE(n,p==="list"&&!tt,!1),{data:Ia=[],isLoading:na,error:tr,documents:Es=[],fragments:Ts=[]}=mE(n,p==="graph"&&!tt,at),Be=p==="list"?Wa:na,Cl=p==="list"?ea:tr,Sn=p==="list"?ve:Ia,Si=p==="list"?ve.length:Es.length,Ai=p==="graph"?Ts.length:0,{mutate:Os}=vE(n),An=Vf.useMemo(()=>p!=="list"||!$.trim()?Sn:Sn.filter(rt=>{const pt=rt.metadata||{};return(pt.filename||pt.originalFilename||pt.path||"").toLowerCase().includes($.toLowerCase())}),[Sn,$,p]),Ms=An.slice(0,c),Cs=c<An.length,En=ot.useCallback(()=>{if(!ht.current||g||c>=An.length)return;const{scrollTop:rt,scrollHeight:pt,clientHeight:bt}=ht.current;rt+bt>=pt-100&&(y(!0),setTimeout(()=>{h(fn=>Math.min(fn+ul,An.length)),y(!1)},300))},[g,c,An.length]);ot.useEffect(()=>{h(ul)},[]),ot.useEffect(()=>{h(ul)},[$]),ot.useEffect(()=>{const rt=pt=>{pt.key==="Escape"&&i&&(r(null),A(1))};if(i)return document.addEventListener("keydown",rt),()=>document.removeEventListener("keydown",rt)},[i]),ot.useEffect(()=>{const rt=ht.current;if(rt)return rt.addEventListener("scroll",En),()=>rt.removeEventListener("scroll",En)},[En]);const se=ot.useRef(null);ot.useEffect(()=>{m&&se.current&&se.current.scrollIntoView({behavior:"smooth",block:"nearest"})},[m]);const cn=ot.useCallback(rt=>{_(rt)},[]);if(Be&&(!Sn||Sn.length===0)&&!tt)return E.jsx("div",{className:"flex items-center justify-center h-40",children:"Loading knowledge documents..."});if(Cl&&!tt)return E.jsxs("div",{className:"flex items-center justify-center h-40 text-destructive",children:["Error loading knowledge documents: ",Cl.message]});const be=rt=>{const pt=new Date(rt);return`${pt.toLocaleDateString()} ${pt.toLocaleTimeString()}`},Ns=rt=>{switch(rt.split(".").pop()?.toLowerCase()){case"md":return E.jsx(Fc,{className:"h-5 w-5 text-blue-500"});case"js":case"ts":case"jsx":case"tsx":return E.jsx(Fc,{className:"h-5 w-5 text-yellow-500"});case"json":return E.jsx(Fc,{className:"h-5 w-5 text-green-500"});case"pdf":return E.jsx(Xu,{className:"h-5 w-5 text-red-500"});default:return E.jsx(Xu,{className:"h-5 w-5 text-gray-500"})}},zs=rt=>{rt&&window.confirm("Are you sure you want to delete this document?")&&(Os({knowledgeId:rt}),r(null))},Nl=()=>{yt.current&&yt.current.click()},ia=()=>{O(!0),j(""),Q([]),q(null)},Ei=()=>{try{if(!new URL(S).protocol.startsWith("http")){q("URL must start with http:// or https://");return}if(U.includes(S)){q("This URL is already in the list");return}Q([...U,S]),j(""),q(null)}catch{q("Invalid URL")}},Tn=rt=>{Q(U.filter(pt=>pt!==rt))},Ti=async()=>{if(!K.trim()){T("Please enter a search query");return}et(!0),T(null),N([]);try{const rt=await Sl.searchKnowledge(n,K,ct);N(rt.data.results||[]),rt.data.results.length===0&&T("No results found. Try adjusting your search query or lowering the similarity threshold.")}catch(rt){T(rt.message||"Failed to search knowledge"),N([])}finally{et(!1)}},Oi=async()=>{if(S.trim())try{new URL(S).protocol.startsWith("http")&&!U.includes(S)&&Q([...U,S])}catch{}if(U.length===0){q("Please add at least one valid URL");return}R(!0),q(null);try{const rt=Ki(),pt=await fetch(`${rt}/documents`,{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({fileUrls:U,agentId:n})});if(!pt.ok){const ie=await pt.text();throw new Error(ie)}const bt=await pt.json();bt.success?(Ct({title:"URLs imported",description:`Successfully imported ${U.length} document(s)`}),O(!1),At.invalidateQueries({queryKey:["agents",n,"knowledge","documents"]})):q(bt.error?.message||"Error importing documents from URLs")}catch(rt){q(rt.message||"Error importing documents from URLs"),Ct({title:"Error",description:"Failed to import documents from URLs",variant:"destructive"})}finally{R(!1)}},Rs=async rt=>{const pt=rt.target.files;if(!(!pt||pt.length===0)){o(!0);try{const bt=Array.from(pt),ie=new FormData;for(const oe of bt){const Ae=iv(oe),nr=new Blob([oe],{type:Ae});ie.append("files",nr,oe.name)}ie.append("agentId",n);const fn=Ki(),ge=await fetch(`${fn}/documents`,{method:"POST",body:ie});if(!ge.ok)throw new Error(`Upload failed: ${ge.statusText}`);const Kt=(await ge.json()).data||[];if(Array.isArray(Kt)&&Kt.every(oe=>oe.status==="success"))Ct({title:"Knowledge Uploaded",description:`Successfully uploaded ${bt.length} file(s)`}),At.invalidateQueries({queryKey:["agents",n,"knowledge","documents"]});else{const oe=Kt.filter(nr=>nr.status==="success").length,Ae=bt.length-oe;Ct({title:Ae>0?"Upload Partially Failed":"Upload Issues",description:`Uploaded ${oe} file(s). ${Ae} file(s) failed. Check console for details.`,variant:Ae>0?"destructive":"default"}),console.error("Upload results:",Kt)}}catch(bt){Ct({title:"Upload Failed",description:bt instanceof Error?bt.message:"Failed to upload knowledge files",variant:"destructive"}),console.error("Upload error:",bt)}finally{o(!1),yt.current&&(yt.current.value="")}}},zl=()=>E.jsx("div",{className:"flex justify-center p-4",children:g?E.jsxs("div",{className:"flex items-center gap-2",children:[E.jsx(Ya,{className:"h-4 w-4 animate-spin"}),E.jsx("span",{className:"text-sm text-muted-foreground",children:"Loading more..."})]}):E.jsx(Zt,{variant:"ghost",size:"sm",onClick:()=>{y(!0),setTimeout(()=>{h(rt=>Math.min(rt+ul,An.length)),y(!1)},100)},className:"text-xs",children:"Show more"})}),Rl=()=>E.jsxs("div",{className:"text-muted-foreground text-center p-12 flex flex-col items-center gap-3 border-2 border-dashed rounded-lg mt-8",children:[E.jsx(c_,{className:"h-12 w-12 text-muted-foreground opacity-20"}),E.jsx("h3",{className:"text-lg font-medium",children:"No Knowledge Documents"}),E.jsx("p",{className:"max-w-md text-sm",children:"No Knowledge Documents found."}),E.jsxs(Zt,{variant:"outline",onClick:Nl,children:[E.jsx(gp,{className:"h-4 w-4 mr-2"}),"Upload Documents"]})]}),er=()=>aa?E.jsxs(E.Fragment,{children:[E.jsxs(Zt,{variant:"outline",size:"sm",onClick:()=>v("list"),className:"flex-shrink-0",title:"Switch to List view to see documents only",children:[E.jsx(Pc,{className:"h-4 w-4 mr-2"}),E.jsx("span",{children:"List View"})]}),E.jsxs(Zt,{variant:"outline",size:"sm",onClick:()=>{st(void 0),_(null)},className:"flex-shrink-0",children:[E.jsx(s_,{className:"h-4 w-4 mr-2"}),E.jsx("span",{children:"Overview Graph"})]})]}):tt?E.jsxs(Zt,{variant:"outline",size:"sm",onClick:()=>{F(!1),it(""),N([]),T(null),v("list")},className:"flex-shrink-0",title:"Exit search and return to List view",children:[E.jsx(Pc,{className:"h-4 w-4 mr-2"}),E.jsx("span",{className:"hidden md:inline",children:"List View"}),E.jsx("span",{className:"md:hidden",children:"List"})]}):p==="graph"?E.jsxs(Zt,{variant:"outline",size:"sm",onClick:()=>v("list"),className:"flex-shrink-0",title:"Switch to List view to see documents only",children:[E.jsx(Pc,{className:"h-4 w-4 mr-2"}),E.jsx("span",{className:"hidden md:inline",children:"List View"}),E.jsx("span",{className:"md:hidden",children:"List"})]}):E.jsxs(E.Fragment,{children:[E.jsxs(Zt,{variant:"outline",size:"sm",onClick:()=>v("graph"),className:"flex-shrink-0",title:"Switch to Graph view to see documents and fragments",children:[E.jsx(v_,{className:"h-4 w-4 mr-2"}),E.jsx("span",{className:"hidden md:inline",children:"Graph View"}),E.jsx("span",{className:"md:hidden",children:"Graph"})]}),E.jsxs("div",{className:"flex gap-2 ml-auto sm:ml-0",children:[E.jsxs(Zt,{variant:"outline",onClick:()=>F(!0),size:"sm",className:"flex-shrink-0",children:[E.jsx(Jc,{className:"h-4 w-4 sm:mr-2"}),E.jsx("span",{className:"hidden sm:inline",children:"Search"})]}),E.jsxs(Zt,{variant:"outline",onClick:ia,size:"sm",className:"flex-shrink-0",children:[E.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",className:"h-4 w-4 sm:mr-2",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round",children:[E.jsx("path",{d:"M10 13a5 5 0 0 0 7.54.54l3-3a5 5 0 0 0-7.07-7.07l-1.72 1.71"}),E.jsx("path",{d:"M14 11a5 5 0 0 0-7.54-.54l-3 3a5 5 0 0 0 7.07 7.07l1.71-1.71"})]}),E.jsx("span",{className:"hidden sm:inline",children:"URL"})]}),E.jsxs(Zt,{onClick:Nl,disabled:u,size:"sm",className:"flex-shrink-0",children:[u?E.jsx(Ya,{className:"h-4 w-4 animate-spin sm:mr-2"}):E.jsx(gp,{className:"h-4 w-4 sm:mr-2"}),E.jsx("span",{className:"hidden sm:inline",children:"Upload"})]})]})]}),Mi=({memory:rt,index:pt})=>{const bt=rt.metadata||{},ie=()=>bt.title?bt.title:bt.filename?bt.filename:bt.originalFilename?bt.originalFilename:bt.path?bt.path.split("/").pop()||bt.path:rt.id?`Document ${rt.id.substring(0,8)}`:`Document ${pt+1}`,fn=()=>bt.fileExt?bt.fileExt.toLowerCase():(bt.filename||bt.originalFilename||bt.path||"").split(".").pop()?.toLowerCase()||"doc",ge=()=>bt.path?bt.path:bt.filename?bt.filename:bt.originalFilename?bt.originalFilename:bt.source?`Source: ${bt.source}`:"Knowledge Document",It=ie(),Kt=ge(),oe=fn();return E.jsx("button",{type:"button",className:"w-full text-left hover:bg-accent/5 transition-colors group border-b border-border/30 cursor-pointer",onClick:()=>r(rt),children:E.jsxs("div",{className:"flex items-center px-1 py-2 min-h-[2rem]",children:[E.jsxs("div",{className:"flex items-center gap-2 flex-1 min-w-0",children:[E.jsx("div",{className:"flex-shrink-0",children:Ns(It)}),E.jsxs("div",{className:"flex-1 min-w-0",children:[E.jsxs("div",{className:"flex items-center gap-2 mb-1",children:[E.jsx("span",{className:"text-xs font-medium truncate",children:Kt}),E.jsx(Wc,{variant:"outline",className:"px-1 py-0 h-4 text-xs flex-shrink-0",children:oe||"doc"})]}),E.jsx("div",{className:"text-xs text-muted-foreground",children:new Date(rt.createdAt||0).toLocaleString(void 0,{month:"numeric",day:"numeric",year:"2-digit",hour:"numeric",minute:"numeric"})})]})]}),E.jsx("div",{className:"flex items-center gap-2 flex-shrink-0",children:rt.id&&E.jsx(Zt,{variant:"ghost",size:"icon",className:"size-5 opacity-0 group-hover:opacity-100 transition-opacity",onClick:Ae=>{Ae&&(Ae.stopPropagation(),Ae.preventDefault()),zs(rt.id||"")},title:"Delete knowledge",children:E.jsx(x_,{className:"h-3 w-3 text-destructive"})})})]})},rt.id||pt)},Ds=({memory:rt})=>{const pt=rt.metadata,bt=pt?.type==="fragment",ie=pt?.type==="document";return E.jsxs("div",{className:"h-full flex flex-col border-t border-border bg-card text-card-foreground",children:[E.jsxs("div",{className:"flex-shrink-0 p-4 flex justify-between items-start",children:[E.jsxs("div",{className:"space-y-1 flex-1",children:[E.jsxs("h3",{className:"text-sm font-medium flex items-center gap-2",children:[bt?E.jsxs("span",{className:"flex items-center",children:[E.jsx("div",{className:"h-3 w-3 rounded-full bg-accent mr-1.5"}),"Fragment"]}):E.jsxs("span",{className:"flex items-center",children:[E.jsx("div",{className:"h-3 w-3 rounded-full bg-primary mr-1.5"}),"Document"]}),E.jsx("span",{className:"text-muted-foreground ml-2",children:pt?.title||rt.id?.substring(0,8)})]}),E.jsxs("div",{className:"grid grid-cols-2 gap-x-4 gap-y-1 text-xs text-muted-foreground",children:[E.jsxs("div",{className:"col-span-2",children:["ID: ",E.jsx("span",{className:"font-mono",children:rt.id})]}),bt&&pt.documentId&&E.jsxs("div",{className:"col-span-2",children:["Parent Document:"," ",E.jsx("span",{className:"font-mono text-primary/80",children:pt.documentId})]}),bt&&pt.position!==void 0&&E.jsxs("div",{children:["Position: ",pt.position]}),pt.source&&E.jsxs("div",{children:["Source: ",pt.source]}),E.jsxs("div",{children:["Created on: ",be(rt.createdAt||0)]})]})]}),E.jsxs("div",{className:"flex items-center gap-2",children:[ie&&E.jsxs(Zt,{variant:"default",size:"sm",onClick:()=>r(rt),className:"text-xs h-7 px-3",children:[E.jsx(Xu,{className:"h-3 w-3 mr-1"}),"Open Document"]}),E.jsx(Zt,{variant:"ghost",size:"sm",onClick:()=>_(null),className:"text-xs h-7 px-2",children:"Close"})]})]}),E.jsxs("div",{className:"flex-1 overflow-hidden px-4 pb-4 flex flex-col",children:[ie?E.jsxs("div",{className:"flex-1 min-h-0 bg-background rounded border border-border p-6 flex flex-col items-center justify-center text-center",children:[E.jsx(Xu,{className:"h-12 w-12 text-muted-foreground mb-4"}),E.jsx("h4",{className:"text-sm font-medium mb-2",children:pt?.title||pt?.filename||"Document"}),E.jsx("p",{className:"text-xs text-muted-foreground mb-4",children:'Click "Open Document" to view the full content'}),pt?.fileExt&&E.jsx(Wc,{variant:"outline",className:"text-xs",children:pt.fileExt.toUpperCase()})]}):E.jsx("div",{className:"flex-1 min-h-0 bg-background rounded border border-border p-3 overflow-y-auto",style:{scrollbarWidth:"thin",scrollbarColor:"rgba(155, 155, 155, 0.5) transparent"},children:E.jsx("pre",{className:"whitespace-pre-wrap font-mono text-xs break-words max-w-full",children:rt.content?.text||"No content available"})}),rt.embedding&&E.jsxs("div",{className:"mt-2 flex items-center text-xs text-muted-foreground flex-shrink-0",children:[E.jsx("span",{className:"bg-accent/20 text-accent-foreground px-1.5 py-0.5 rounded text-[10px] font-medium mr-1.5",children:"EMBEDDING"}),E.jsxs("span",{children:["Vector with ",rt.embedding.length," dimensions"]})]})]})]})},aa=p==="graph"&&at&&!tt;return E.jsxs("div",{className:"flex flex-col h-full",children:[E.jsxs("div",{className:`flex flex-col sm:flex-row items-start sm:items-center justify-between border-b gap-3 ${aa?"p-6 pb-4":"p-4"}`,children:[E.jsxs("div",{className:"flex flex-col gap-1",children:[E.jsx("h2",{className:"text-lg font-semibold",children:"Knowledge"}),E.jsx("p",{className:"text-xs text-muted-foreground",children:tt?"Searching knowledge fragments":p==="list"?`Viewing ${Si} document${Si!==1?"s":""}`:aa?`Inspecting document with ${Ai} fragment${Ai!==1?"s":""}`:`Viewing ${Si} document${Si!==1?"s":""}`})]}),E.jsx("div",{className:"flex items-center gap-3 w-full sm:w-auto",children:E.jsx(er,{})})]}),tt&&E.jsx("div",{className:"border-b border-border bg-muted/30 p-4",children:E.jsxs("div",{className:"space-y-4",children:[E.jsxs("div",{className:"flex items-center gap-2",children:[E.jsx(g_,{className:"h-4 w-4 text-muted-foreground flex-shrink-0"}),E.jsx("p",{className:"text-xs text-muted-foreground",children:"Search your knowledge base using semantic vector search. Adjust the similarity threshold to control how closely results must match your query."})]}),E.jsxs("div",{className:"space-y-3",children:[E.jsxs("div",{className:"flex gap-2",children:[E.jsx(Ic,{placeholder:"Enter your search query...",value:K,onChange:rt=>it(rt.target.value),onKeyDown:rt=>{rt.key==="Enter"&&K.trim()&&(rt.preventDefault(),Ti())},className:"flex-1"}),E.jsx(Zt,{onClick:Ti,disabled:Z||!K.trim(),size:"sm",className:"px-6",children:Z?E.jsx(Ya,{className:"h-4 w-4 animate-spin"}):E.jsx(Jc,{className:"h-4 w-4"})})]}),E.jsxs("div",{className:"space-y-2",children:[E.jsxs("div",{className:"flex items-center justify-between",children:[E.jsx("label",{className:"text-sm font-medium",children:"Similarity Threshold"}),E.jsxs("span",{className:"text-sm text-muted-foreground",children:[ct.toFixed(2)," (",Math.round(ct*100),"% match)"]})]}),E.jsx("input",{type:"range",min:"0",max:"1",step:"0.05",value:ct,onChange:rt=>L(parseFloat(rt.target.value)),className:"w-full h-2 bg-gray-200 rounded-lg appearance-none cursor-pointer dark:bg-gray-700"}),E.jsxs("div",{className:"flex justify-between text-xs text-muted-foreground",children:[E.jsx("span",{children:"0% (least similar)"}),E.jsx("span",{children:"100% (exact match)"})]})]})]})]})}),M&&E.jsx(Ey,{open:M,onOpenChange:O,children:E.jsxs(Ty,{className:"max-w-md w-full",children:[E.jsxs(Oy,{children:[E.jsx(My,{className:"text-xl font-bold",children:"Import from URL"}),E.jsx(Cy,{children:"Enter one or more URLs of PDF, text, or other files to import into the knowledge base."})]}),E.jsxs("div",{className:"mt-6 space-y-4",children:[E.jsxs("div",{className:"flex gap-2",children:[E.jsx(Ic,{placeholder:"https://example.com/document.pdf",value:S,onChange:rt=>j(rt.target.value),disabled:H,className:"flex-1",onKeyDown:rt=>{rt.key==="Enter"&&S.trim()&&(rt.preventDefault(),Ei())}}),E.jsx(Zt,{variant:"outline",size:"sm",onClick:Ei,disabled:H||!S.trim(),children:"Add"})]}),C&&E.jsx("div",{className:"text-sm text-destructive bg-destructive/10 p-2 rounded-md",children:C}),U.length>0&&E.jsxs("div",{className:"border border-border rounded-md bg-card/50 p-3 mt-2",children:[E.jsxs("h4",{className:"text-sm font-medium mb-2",children:["URLs to import (",U.length,")"]}),E.jsx("div",{className:"space-y-2 max-h-40 overflow-y-auto",children:U.map((rt,pt)=>E.jsxs("div",{className:"flex items-center justify-between text-sm bg-background p-2 rounded border border-border",children:[E.jsx("span",{className:"truncate flex-1",children:rt}),E.jsx(Zt,{variant:"ghost",size:"icon",className:"h-6 w-6 hover:bg-destructive/10 hover:text-destructive",onClick:()=>Tn(rt),disabled:H,children:E.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",className:"h-4 w-4",fill:"none",viewBox:"0 0 24 24",stroke:"currentColor",children:E.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:"M6 18L18 6M6 6l12 12"})})})]},pt))})]})]}),E.jsxs(Ny,{className:"mt-6 pt-4 border-t border-border",children:[E.jsx(Zt,{variant:"outline",onClick:()=>O(!1),disabled:H,children:"Cancel"}),E.jsx(Zt,{onClick:Oi,disabled:H||U.length===0&&!S.trim(),children:H?E.jsxs(E.Fragment,{children:[E.jsx(Ya,{className:"h-4 w-4 animate-spin mr-2"}),"Importing..."]}):"Import"})]})]})}),E.jsx("input",{ref:yt,type:"file",multiple:!0,accept:".txt,.md,.markdown,.pdf,.doc,.docx,.json,.xml,.yaml,.yml,.csv,.tsv,.log,.ini,.cfg,.conf,.env,.gitignore,.dockerignore,.editorconfig,.js,.jsx,.ts,.tsx,.mjs,.cjs,.py,.pyw,.pyi,.java,.c,.cpp,.cc,.cxx,.h,.hpp,.cs,.php,.rb,.go,.rs,.swift,.kt,.kts,.scala,.clj,.cljs,.ex,.exs,.r,.R,.m,.mm,.sh,.bash,.zsh,.fish,.ps1,.bat,.cmd,.sql,.html,.htm,.css,.scss,.sass,.less,.vue,.svelte,.astro,.lua,.pl,.pm,.dart,.hs,.elm,.ml,.fs,.fsx,.vb,.pas,.d,.nim,.zig,.jl,.tcl,.awk,.sed",onChange:Rs,className:"hidden"}),E.jsx("div",{className:"flex-1 overflow-hidden",children:tt?E.jsxs("div",{className:"h-full overflow-y-auto p-4",children:[Z&&E.jsx("div",{className:"flex items-center justify-center h-full",children:E.jsx(Ya,{className:"h-8 w-8 animate-spin text-muted-foreground"})}),ut&&!Z&&E.jsx("div",{className:"flex items-center justify-center h-full text-center",children:E.jsx("div",{className:"p-4 bg-destructive/10 text-destructive rounded-md",children:ut})}),J.length>0&&!Z&&E.jsxs("div",{className:"space-y-3",children:[E.jsxs("h3",{className:"text-sm font-medium",children:["Found ",J.length," result",J.length!==1?"s":""]}),E.jsx("div",{className:"space-y-2",children:J.map((rt,pt)=>E.jsxs("div",{className:"border border-border rounded-md p-3 bg-card hover:bg-accent/10 transition-colors cursor-pointer",onClick:()=>r(rt),children:[E.jsx("div",{className:"flex items-start justify-between mb-2",children:E.jsx("div",{className:"flex items-center gap-2",children:E.jsxs(Wc,{variant:"outline",className:"text-xs",children:[(rt.similarity*100).toFixed(1),"% match"]})})}),E.jsx("p",{className:"text-sm line-clamp-4 mb-2",children:rt.content?.text||"No content"}),E.jsxs("div",{className:"flex items-center justify-between",children:[E.jsx("div",{className:"flex items-center gap-3 text-xs text-muted-foreground",children:rt.metadata?.position!==void 0&&E.jsxs("span",{children:["Fragment #",rt.metadata.position]})}),E.jsxs("div",{className:"flex items-center gap-1 text-xs text-muted-foreground hover:text-foreground transition-colors",children:[E.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",className:"h-3 w-3",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round",children:[E.jsx("path",{d:"M2 3h6a4 4 0 0 1 4 4v14a3 3 0 0 0-3-3H2z"}),E.jsx("path",{d:"M22 3h-6a4 4 0 0 0-4 4v14a3 3 0 0 1 3-3h7z"})]}),E.jsx("span",{children:"Read more"})]})]})]},rt.id||pt))})]}),!Z&&J.length===0&&!ut&&E.jsx("div",{className:"flex items-center justify-center h-full text-center text-muted-foreground",children:E.jsxs("div",{className:"flex flex-col items-center gap-2",children:[E.jsx(Jc,{className:"h-10 w-10 opacity-30"}),E.jsx("p",{children:"Enter a query to search your knowledge base."})]})})]}):Sn.length===0?E.jsx(Rl,{}):p==="graph"?E.jsxs("div",{className:"flex flex-col h-full",children:[E.jsxs("div",{className:`p-4 overflow-hidden ${m?"h-1/3":"flex-1"} transition-all duration-300`,children:[E.jsx(gE,{onNodeClick:cn,selectedMemoryId:m?.id,agentId:n}),p==="graph"&&na&&at&&E.jsx("div",{className:"absolute top-1/2 left-1/2 transform -translate-x-1/2 -translate-y-1/2 bg-card/90 backdrop-blur-sm p-4 rounded-lg shadow-lg border border-border",children:E.jsxs("div",{className:"flex items-center gap-2",children:[E.jsx(Ya,{className:"h-5 w-5 animate-spin"}),E.jsx("span",{children:"Loading document fragments..."})]})})]}),m&&E.jsx("div",{ref:se,className:"h-2/3 overflow-hidden transition-all duration-300",children:E.jsx(Ds,{memory:m})})]}):E.jsxs("div",{className:"h-full flex flex-col",children:[E.jsx("div",{className:"flex-shrink-0 p-4 pb-2 border-b border-border/30",children:E.jsx(Ic,{placeholder:"Filter by filename...",value:$,onChange:rt=>nt(rt.target.value),className:"w-full text-sm"})}),E.jsxs("div",{ref:ht,className:"flex-1 overflow-y-auto p-4 pt-2",children:[E.jsx("div",{className:"grid gap-1.5",children:Ms.map((rt,pt)=>E.jsx(Mi,{memory:rt,index:pt},rt.id||pt))}),Cs&&E.jsx(zl,{})]})]})}),i&&E.jsx(Ey,{open:!!i,onOpenChange:()=>r(null),children:E.jsxs(Ty,{className:"max-w-[95vw] w-full max-h-[95vh] h-full overflow-hidden flex flex-col p-0",children:[E.jsx(Oy,{className:"flex-shrink-0 p-6 pb-2",children:E.jsxs("div",{className:"flex items-center justify-between",children:[E.jsxs("div",{children:[E.jsx(My,{className:"text-xl",children:i.metadata?.title||"Document Content"}),E.jsx(Cy,{children:i.metadata?.filename||"Knowledge document"})]}),(()=>{const rt=i.metadata,pt=rt?.contentType||"",bt=rt?.fileExt?.toLowerCase()||"";return pt==="application/pdf"||bt==="pdf"?E.jsxs("div",{className:"flex items-center gap-2",children:[E.jsx(Zt,{variant:"outline",size:"sm",onClick:()=>A(Math.max(.5,x-.25)),disabled:x<=.5,children:E.jsx("span",{className:"text-lg",children:"−"})}),E.jsxs("span",{className:"text-sm font-medium min-w-[60px] text-center",children:[Math.round(x*100),"%"]}),E.jsx(Zt,{variant:"outline",size:"sm",onClick:()=>A(Math.min(3,x+.25)),disabled:x>=3,children:E.jsx("span",{className:"text-lg",children:"+"})}),E.jsx(Zt,{variant:"outline",size:"sm",onClick:()=>A(1),children:"Reset"})]}):null})()]})}),E.jsx("div",{className:"flex-1 overflow-auto px-6 pb-2",children:(()=>{const rt=i.metadata,pt=rt?.contentType||"",bt=rt?.fileExt?.toLowerCase()||"",ie=pt==="application/pdf"||bt==="pdf";if(ie&&i.content?.text){const fn=i.content.text.trim();if(!fn)return E.jsx("div",{className:"h-full w-full bg-background rounded-lg border border-border p-6 flex items-center justify-center",children:E.jsxs("div",{className:"text-center text-muted-foreground",children:[E.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",className:"h-12 w-12 mx-auto mb-4",fill:"none",viewBox:"0 0 24 24",stroke:"currentColor",children:E.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:"M12 9v2m0 4h.01m-6.938 4h13.856c1.54 0 2.502-1.667 1.732-2.5L13.732 4c-.77-.833-1.732-.833-2.5 0L4.314 18.5c-.77.833.192 2.5 1.732 2.5z"})}),E.jsx("p",{className:"text-lg font-medium",children:"PDF Content Unavailable"}),E.jsx("p",{className:"text-sm",children:"The PDF content could not be loaded."})]})});const ge=`data:application/pdf;base64,${fn}`;return E.jsx("div",{className:"w-full h-full rounded-lg overflow-auto bg-card border border-border",children:E.jsx("div",{className:"min-w-full flex items-center justify-center p-4",style:{minHeight:"100%",transform:`scale(${x})`,transformOrigin:"top center",width:x>1?`${100/x}%`:"100%"},children:E.jsx("iframe",{src:ge,className:"w-full border-0 shadow-md",style:{height:"90vh",maxWidth:"1200px",backgroundColor:"var(--background)"},title:"PDF Document",onError:()=>{console.error("Failed to load PDF in iframe")}})})})}else return ie&&!i.content?.text?E.jsx("div",{className:"h-full w-full bg-background rounded-lg border border-border p-6 flex items-center justify-center",children:E.jsxs("div",{className:"text-center text-muted-foreground",children:[E.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",className:"h-12 w-12 mx-auto mb-4",fill:"none",viewBox:"0 0 24 24",stroke:"currentColor",children:E.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:"M9 12h6m-6 4h6m2 5H7a2 2 0 01-2-2V5a2 2 0 012-2h5.586a1 1 0 01.707.293l5.414 5.414a1 1 0 01.293.707V19a2 2 0 01-2 2z"})}),E.jsx("p",{className:"text-lg font-medium",children:"PDF Not Available"}),E.jsx("p",{className:"text-sm",children:"This PDF document has no content to display."})]})}):E.jsx("div",{className:"h-full w-full bg-background rounded-lg border border-border p-6 overflow-y-auto",children:E.jsx("pre",{className:"whitespace-pre-wrap text-sm font-mono leading-relaxed text-foreground break-words",children:i.content?.text||"No content available"})})})()}),E.jsx(Ny,{className:"flex-shrink-0 p-6 pt-4 border-t border-border",children:E.jsx(Zt,{variant:"outline",onClick:()=>{r(null),A(1)},children:"Close"})})]})})]})}const _E=new Nb;function xE(){const i=window.ELIZA_CONFIG?.agentId;return Vf.useEffect(()=>{document.documentElement.classList.add("dark")},[]),i?E.jsx(wE,{agentId:i}):E.jsxs("div",{className:"p-4 text-center",children:[E.jsx("div",{className:"text-red-600 font-medium",children:"Error: Agent ID not found"}),E.jsx("div",{className:"text-sm text-gray-600 mt-2",children:"The server should inject the agent ID configuration."})]})}function wE({agentId:n}){return E.jsx(Ub,{client:_E,children:E.jsx(bE,{agentId:n})})}const zy=document.getElementById("root");zy&&e_.createRoot(zy).render(E.jsx(xE,{}));
|