nexgui4 1.0.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.
@@ -0,0 +1,152 @@
1
+ !function(e,t,g,n){"use strict";function _interopNamespaceDefault(e){const t=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(e)for(const g in e)if("default"!==g){const n=Object.getOwnPropertyDescriptor(e,g);Object.defineProperty(t,g,n.get?n:{enumerable:!0,get:()=>e[g]})}return t.default=e,Object.freeze(t)}const C=_interopNamespaceDefault(t),o=_interopNamespaceDefault(n);var I=Symbol.for("immer-nothing"),a=Symbol.for("immer-draftable"),i=Symbol.for("immer-state");function die(e,...t){throw new Error(`[Immer] minified error nr: ${e}. Full error at: https://bit.ly/3cXEKWf`)}var s=Object.getPrototypeOf;function isDraft(e){return!!e&&!!e[i]}function isDraftable(e){return!!e&&(isPlainObject$2(e)||Array.isArray(e)||!!e[a]||!!e.constructor?.[a]||isMap(e)||isSet(e))}var l=Object.prototype.constructor.toString(),c=new WeakMap;function isPlainObject$2(e){if(!e||"object"!=typeof e)return!1;const t=Object.getPrototypeOf(e);if(null===t||t===Object.prototype)return!0;const g=Object.hasOwnProperty.call(t,"constructor")&&t.constructor;if(g===Object)return!0;if("function"!=typeof g)return!1;let n=c.get(g);return void 0===n&&(n=Function.toString.call(g),c.set(g,n)),n===l}function each(e,t,g=!0){0===getArchtype(e)?(g?Reflect.ownKeys(e):Object.keys(e)).forEach(g=>{t(g,e[g],e)}):e.forEach((g,n)=>t(n,g,e))}function getArchtype(e){const t=e[i];return t?t.type_:Array.isArray(e)?1:isMap(e)?2:isSet(e)?3:0}function has(e,t){return 2===getArchtype(e)?e.has(t):Object.prototype.hasOwnProperty.call(e,t)}function set(e,t,g){const n=getArchtype(e);2===n?e.set(t,g):3===n?e.add(g):e[t]=g}function is(e,t){return e===t?0!==e||1/e==1/t:e!=e&&t!=t}function isMap(e){return e instanceof Map}function isSet(e){return e instanceof Set}function latest(e){return e.copy_||e.base_}function shallowCopy(e,t){if(isMap(e))return new Map(e);if(isSet(e))return new Set(e);if(Array.isArray(e))return Array.prototype.slice.call(e);const g=isPlainObject$2(e);if(!0===t||"class_only"===t&&!g){const t=Object.getOwnPropertyDescriptors(e);delete t[i];let g=Reflect.ownKeys(t);for(let n=0;n<g.length;n++){const C=g[n],o=t[C];!1===o.writable&&(o.writable=!0,o.configurable=!0),(o.get||o.set)&&(t[C]={configurable:!0,writable:!0,enumerable:o.enumerable,value:e[C]})}return Object.create(s(e),t)}{const t=s(e);if(null!==t&&g)return{...e};const n=Object.create(t);return Object.assign(n,e)}}function freeze(e,t=!1){return isFrozen(e)||isDraft(e)||!isDraftable(e)||(getArchtype(e)>1&&Object.defineProperties(e,{set:u,add:u,clear:u,delete:u}),Object.freeze(e),t&&Object.values(e).forEach(e=>freeze(e,!0))),e}function dontMutateFrozenCollections(){die(2)}var u={value:dontMutateFrozenCollections};function isFrozen(e){return null===e||"object"!=typeof e||Object.isFrozen(e)}var d,p={};function getPlugin(e){const t=p[e];return t||die(0,e),t}function getCurrentScope(){return d}function createScope(e,t){return{drafts_:[],parent_:e,immer_:t,canAutoFreeze_:!0,unfinalizedDrafts_:0}}function usePatchesInScope(e,t){t&&(getPlugin("Patches"),e.patches_=[],e.inversePatches_=[],e.patchListener_=t)}function revokeScope(e){leaveScope(e),e.drafts_.forEach(revokeDraft),e.drafts_=null}function leaveScope(e){e===d&&(d=e.parent_)}function enterScope(e){return d=createScope(d,e)}function revokeDraft(e){const t=e[i];0===t.type_||1===t.type_?t.revoke_():t.revoked_=!0}function processResult(e,t){t.unfinalizedDrafts_=t.drafts_.length;const g=t.drafts_[0];return void 0!==e&&e!==g?(g[i].modified_&&(revokeScope(t),die(4)),isDraftable(e)&&(e=finalize(t,e),t.parent_||maybeFreeze(t,e)),t.patches_&&getPlugin("Patches").generateReplacementPatches_(g[i].base_,e,t.patches_,t.inversePatches_)):e=finalize(t,g,[]),revokeScope(t),t.patches_&&t.patchListener_(t.patches_,t.inversePatches_),e!==I?e:void 0}function finalize(e,t,g){if(isFrozen(t))return t;const n=e.immer_.shouldUseStrictIteration(),C=t[i];if(!C)return each(t,(n,o)=>finalizeProperty(e,C,t,n,o,g),n),t;if(C.scope_!==e)return t;if(!C.modified_)return maybeFreeze(e,C.base_,!0),C.base_;if(!C.finalized_){C.finalized_=!0,C.scope_.unfinalizedDrafts_--;const t=C.copy_;let o=t,I=!1;3===C.type_&&(o=new Set(t),t.clear(),I=!0),each(o,(n,o)=>finalizeProperty(e,C,t,n,o,g,I),n),maybeFreeze(e,t,!1),g&&e.patches_&&getPlugin("Patches").generatePatches_(C,g,e.patches_,e.inversePatches_)}return C.copy_}function finalizeProperty(e,t,g,n,C,o,I){if(null==C)return;if("object"!=typeof C&&!I)return;const a=isFrozen(C);if(!a||I){if(isDraft(C)){const I=finalize(e,C,o&&t&&3!==t.type_&&!has(t.assigned_,n)?o.concat(n):void 0);if(set(g,n,I),!isDraft(I))return;e.canAutoFreeze_=!1}else I&&g.add(C);if(isDraftable(C)&&!a){if(!e.immer_.autoFreeze_&&e.unfinalizedDrafts_<1)return;if(t&&t.base_&&t.base_[n]===C&&a)return;finalize(e,C),t&&t.scope_.parent_||"symbol"==typeof n||!(isMap(g)?g.has(n):Object.prototype.propertyIsEnumerable.call(g,n))||maybeFreeze(e,C)}}}function maybeFreeze(e,t,g=!1){!e.parent_&&e.immer_.autoFreeze_&&e.canAutoFreeze_&&freeze(t,g)}function createProxyProxy(e,t){const g=Array.isArray(e),n={type_:g?1:0,scope_:t?t.scope_:getCurrentScope(),modified_:!1,finalized_:!1,assigned_:{},parent_:t,base_:e,draft_:null,copy_:null,revoke_:null,isManual_:!1};let C=n,o=m;g&&(C=[n],o=h);const{revoke:I,proxy:a}=Proxy.revocable(C,o);return n.draft_=a,n.revoke_=I,a}var m={get(e,t){if(t===i)return e;const g=latest(e);if(!has(g,t))return readPropFromProto(e,g,t);const n=g[t];return e.finalized_||!isDraftable(n)?n:n===peek$1(e.base_,t)?(prepareCopy(e),e.copy_[t]=createProxy(n,e)):n},has:(e,t)=>t in latest(e),ownKeys:e=>Reflect.ownKeys(latest(e)),set(e,t,g){const n=getDescriptorFromProto(latest(e),t);if(n?.set)return n.set.call(e.draft_,g),!0;if(!e.modified_){const n=peek$1(latest(e),t),C=n?.[i];if(C&&C.base_===g)return e.copy_[t]=g,e.assigned_[t]=!1,!0;if(is(g,n)&&(void 0!==g||has(e.base_,t)))return!0;prepareCopy(e),markChanged(e)}return e.copy_[t]===g&&(void 0!==g||t in e.copy_)||Number.isNaN(g)&&Number.isNaN(e.copy_[t])||(e.copy_[t]=g,e.assigned_[t]=!0),!0},deleteProperty:(e,t)=>(void 0!==peek$1(e.base_,t)||t in e.base_?(e.assigned_[t]=!1,prepareCopy(e),markChanged(e)):delete e.assigned_[t],e.copy_&&delete e.copy_[t],!0),getOwnPropertyDescriptor(e,t){const g=latest(e),n=Reflect.getOwnPropertyDescriptor(g,t);return n?{writable:!0,configurable:1!==e.type_||"length"!==t,enumerable:n.enumerable,value:g[t]}:n},defineProperty(){die(11)},getPrototypeOf:e=>s(e.base_),setPrototypeOf(){die(12)}},h={};function peek$1(e,t){const g=e[i];return(g?latest(g):e)[t]}function readPropFromProto(e,t,g){const n=getDescriptorFromProto(t,g);return n?"value"in n?n.value:n.get?.call(e.draft_):void 0}function getDescriptorFromProto(e,t){if(!(t in e))return;let g=s(e);for(;g;){const e=Object.getOwnPropertyDescriptor(g,t);if(e)return e;g=s(g)}}function markChanged(e){e.modified_||(e.modified_=!0,e.parent_&&markChanged(e.parent_))}function prepareCopy(e){e.copy_||(e.copy_=shallowCopy(e.base_,e.scope_.immer_.useStrictShallowCopy_))}function createProxy(e,t){const g=isMap(e)?getPlugin("MapSet").proxyMap_(e,t):isSet(e)?getPlugin("MapSet").proxySet_(e,t):createProxyProxy(e,t);return(t?t.scope_:getCurrentScope()).drafts_.push(g),g}function current(e){return isDraft(e)||die(10,e),currentImpl(e)}function currentImpl(e){if(!isDraftable(e)||isFrozen(e))return e;const t=e[i];let g,n=!0;if(t){if(!t.modified_)return t.base_;t.finalized_=!0,g=shallowCopy(e,t.scope_.immer_.useStrictShallowCopy_),n=t.scope_.immer_.shouldUseStrictIteration()}else g=shallowCopy(e,!0);return each(g,(e,t)=>{set(g,e,currentImpl(t))},n),t&&(t.finalized_=!1),g}each(m,(e,t)=>{h[e]=function(){return arguments[0]=arguments[0][0],t.apply(this,arguments)}}),h.deleteProperty=function(e,t){return h.set.call(this,e,t,void 0)},h.set=function(e,t,g){return m.set.call(this,e[0],t,g,e[0])};var y=new class{constructor(e){this.autoFreeze_=!0,this.useStrictShallowCopy_=!1,this.useStrictIteration_=!0,this.produce=(e,t,g)=>{if("function"==typeof e&&"function"!=typeof t){const g=t;t=e;const n=this;return function(e=g,...C){return n.produce(e,e=>t.call(this,e,...C))}}let n;if("function"!=typeof t&&die(6),void 0!==g&&"function"!=typeof g&&die(7),isDraftable(e)){const C=enterScope(this),o=createProxy(e,void 0);let I=!0;try{n=t(o),I=!1}finally{I?revokeScope(C):leaveScope(C)}return usePatchesInScope(C,g),processResult(n,C)}if(!e||"object"!=typeof e){if(n=t(e),void 0===n&&(n=e),n===I&&(n=void 0),this.autoFreeze_&&freeze(n,!0),g){const t=[],C=[];getPlugin("Patches").generateReplacementPatches_(e,n,t,C),g(t,C)}return n}die(1,e)},this.produceWithPatches=(e,t)=>{if("function"==typeof e)return(t,...g)=>this.produceWithPatches(t,t=>e(t,...g));let g,n;return[this.produce(e,t,(e,t)=>{g=e,n=t}),g,n]},"boolean"==typeof e?.autoFreeze&&this.setAutoFreeze(e.autoFreeze),"boolean"==typeof e?.useStrictShallowCopy&&this.setUseStrictShallowCopy(e.useStrictShallowCopy),"boolean"==typeof e?.useStrictIteration&&this.setUseStrictIteration(e.useStrictIteration)}createDraft(e){isDraftable(e)||die(8),isDraft(e)&&(e=current(e));const t=enterScope(this),g=createProxy(e,void 0);return g[i].isManual_=!0,leaveScope(t),g}finishDraft(e,t){const g=e&&e[i];g&&g.isManual_||die(9);const{scope_:n}=g;return usePatchesInScope(n,t),processResult(void 0,n)}setAutoFreeze(e){this.autoFreeze_=e}setUseStrictShallowCopy(e){this.useStrictShallowCopy_=e}setUseStrictIteration(e){this.useStrictIteration_=e}shouldUseStrictIteration(){return this.useStrictIteration_}applyPatches(e,t){let g;for(g=t.length-1;g>=0;g--){const n=t[g];if(0===n.path.length&&"replace"===n.op){e=n.value;break}}g>-1&&(t=t.slice(g+1));const n=getPlugin("Patches").applyPatches_;return isDraft(e)?n(e,t):this.produce(e,e=>n(e,t))}},b=y.produce,v=y.setAutoFreeze.bind(y);const x=200,applyCap=(e,t)=>!Number.isFinite(t)||t<=0?e:e.length>t?e.slice(e.length-t):e,createFeedModel=({cap:e=x}={})=>{let t=[];return{add:g=>{t=applyCap(t.concat(g),e)},addEntries:g=>{Array.isArray(g)&&0!==g.length&&(t=applyCap(t.concat(g),e))},replaceEntries:g=>{t=applyCap(Array.isArray(g)?[...g]:[],e)},snapshot:()=>[...t],clear:()=>{t=[]},destroy:()=>{t=[]}}},S=3e3,w=1e3,E=500,R=5e3,M=500,T=300,createStreamModel=({onAppend:e=()=>{},onClear:t=()=>{}}={})=>{let g=0,n=0,C=[],o=[],I=null,a=null;const i=new Set,notify=()=>{n++,a=null,i.forEach(e=>e())},retainLiveTail=e=>e.length<S?e:e.slice(-w),callCallback=(e,...t)=>{try{const g=e(...t);g&&"function"==typeof g.catch&&g.catch(()=>{})}catch{}};return{subscribe:e=>(i.add(e),()=>i.delete(e)),getSnapshot:()=>(a||(a={version:n,buffer:C,filteredBuffer:o,promptLine:I,totalLines:C.length}),a),addLines:t=>{const n=[],a=[];let i=null;for(const e of t){if("main"!==(e.buffer??"main"))continue;const t={id:g++,html:e.html,timestamp:e.timestamp,isPrompt:e.isPrompt,isMonospace:e.isMonospace,shouldLog:e.shouldLog,buffer:e.buffer??"main"};n.push(t),t.isPrompt?i=t:a.push(t)}0!==n.length&&(C=retainLiveTail([...C,...n]),o=retainLiveTail([...o,...a]),i&&(I=i),callCallback(e,n),notify())},clear:()=>{C=[],o=[],I=null,g=0,callCallback(t),notify()},getStats:()=>({totalLines:C.length,filteredLines:o.length,liveBufferCount:C.length,liveFilteredCount:o.length,version:n,subscribers:i.size,sessionTotalLines:g,nextId:g,liveBufferCapThreshold:S,liveBufferRetainCount:w})}},P=5e3,appendWithCap=(e,t,g)=>{if(0===t.length)return e;const n=e.concat(t);return!Number.isFinite(g)||g<=0?n:n.length>g?n.slice(n.length-g):n},createTranscriptModel=({cap:e=P}={})=>{let t=0,g=0,n=[],C=null;const o=new Set,notify=()=>{g++,C=null,o.forEach(e=>e())};return{subscribe:e=>(o.add(e),()=>o.delete(e)),getSnapshot:()=>(C||(C={version:g,items:n,totalLines:n.length}),C),addLines:g=>{const C=[];for(const e of g)C.push({id:t++,html:e.html,timestamp:e.timestamp,isPrompt:Boolean(e.isPrompt),isMonospace:Boolean(e.isMonospace),shouldLog:e.shouldLog,hasMXP:(e.html||"").includes("mxp_send"),buffer:e.buffer});0!==C.length&&(n=appendWithCap(n,C,e),notify())},clear:()=>{n=[],t=0,notify()},getStats:()=>({totalLines:n.length,version:g,subscribers:o.size})}},N=Object.freeze({SYSTEM_PHASE:"nexgui4.system.phase",SYSTEM_READY:"nexgui4.system.ready",SYSTEM_DESTROYED:"nexgui4.system.destroyed"}),O=Object.freeze({TIMER_STARTED:"nexgui4.domain.timer.started",TIMER_UPDATED:"nexgui4.domain.timer.updated",TIMER_EXPIRED:"nexgui4.domain.timer.expired",TIMER_CLEARED:"nexgui4.domain.timer.cleared",STATS_UPDATED:"nexgui4.domain.stats.updated",TARGET_CHANGED:"nexgui4.domain.target.changed",STREAM_LINE:"nexgui4.domain.stream.line",PARTY_UPDATED:"nexgui4.domain.party.updated",PARTY_MEMBER_LEFT:"nexgui4.domain.party.member.left",ROOM_UPDATED:"nexgui4.domain.room.updated",DEFENCE_GAINED:"nexgui4.domain.defence.gained",DEFENCE_LOST:"nexgui4.domain.defence.lost",CHARACTER_UPDATED:"nexgui4.domain.character.updated",CLASS_CHANGED:"nexgui4.domain.character.class.changed"}),D=Object.freeze({STREAM_LINE:"nexgui4.ingress.stream.line",TIMER_STARTED:"nexgui4.ingress.timer.started",STATS_UPDATED:"nexgui4.ingress.stats.updated",TARGET_CHANGED:"nexgui4.ingress.target.changed",ROOM_UPDATED:"nexgui4.ingress.room.updated",DEFENCE_GAINED:"nexgui4.ingress.defence.gained",DEFENCE_LOST:"nexgui4.ingress.defence.lost",CLASS_CHANGED:"nexgui4.ingress.character.class.changed"}),j=Object.freeze({THEME_CHANGED:"nexgui4.ui.theme.changed",HOST_SETTINGS_CHANGED:"nexgui4.ui.host.settings.changed"}),L=Object.freeze({...N,...O,...j}),hasOwn$1=(e,t)=>Boolean(e)&&Object.prototype.hasOwnProperty.call(e,t),normalizeNumber$3=e=>{const t=Number(e);return Number.isFinite(t)?t:0},normalizeDuration=e=>Math.max(0,Math.abs(normalizeNumber$3(e))),normalizeDirection$1=(e,t="countdown")=>e&&"object"==typeof e?"countup"===e.direction||"countup"===e.mode||!1===e.countDown?"countup":"countdown":t,normalizePosition$1=(e,t="top")=>"string"==typeof e?"bottom"===e?"bottom":"top":e&&"object"==typeof e?"bottom"===e.position?"bottom":"top":t,normalizeStayVisible=(e,t=!0)=>e&&"object"==typeof e&&hasOwn$1(e,"stayVisible")?!0===e.stayVisible:t,normalizeGroupIds=(e,t=[])=>{if(!e||"object"!=typeof e)return[...t];const g=hasOwn$1(e,"groupIds")?e.groupIds:hasOwn$1(e,"groupId")?e.groupId:hasOwn$1(e,"group")?e.group:null;if(null==g)return[...t];const n=Array.isArray(g)?g:[g],C=new Set,o=[];for(const I of n){if("string"!=typeof I)continue;const e=I.trim();e&&!C.has(e)&&(C.add(e),o.push(e))}return o},isVisibleTimer=e=>!0===e.stayVisible||!0===e.enabled&&!0===e.running,areGroupIdsEqual=(e,t)=>e.length===t.length&&e.every((e,g)=>e===t[g]),areTimerSnapshotsEqual=(e,t)=>e.id===t.id&&e.durationMs===t.durationMs&&e.startedAt===t.startedAt&&e.label===t.label&&e.direction===t.direction&&e.position===t.position&&e.stayVisible===t.stayVisible&&e.enabled===t.enabled&&e.running===t.running&&e.elapsedMs===t.elapsedMs&&e.remainingMs===t.remainingMs&&areGroupIdsEqual(e.groupIds,t.groupIds),getIdleElapsedMs=e=>!0===e.stayVisible?e.durationMs:0,noopSetTimer=()=>null,noopClearTimer$1=()=>{},createTimerModel=({eventBus:e,now:t=()=>0,setTimer:g=noopSetTimer,clearTimer:n=noopClearTimer$1}={})=>{const C=new Map;let o=[];const getElapsedMs2=e=>e.running&&null!=e.startedAt?Math.min(e.durationMs,Math.max(0,normalizeNumber$3(t())-normalizeNumber$3(e.startedAt))):e.elapsedMs,cloneTimer=e=>{const t=getElapsedMs2(e);return{id:e.id,durationMs:e.durationMs,startedAt:e.startedAt,label:e.label,direction:e.direction,position:e.position,stayVisible:e.stayVisible,groupIds:[...e.groupIds],enabled:e.enabled,running:e.running,elapsedMs:t,remainingMs:Math.max(0,e.durationMs-t)}},clearScheduledExpiry=e=>{null!=e.timeoutId&&(n(e.timeoutId),e.timeoutId=null)},emitTimerUpdated=t=>{e.emit(O.TIMER_UPDATED,cloneTimer(t))},expire=t=>{const g=C.get(t);g&&(clearScheduledExpiry(g),g.elapsedMs=g.durationMs,g.startedAt=null,g.enabled=!1,g.running=!1,e.emit(O.TIMER_EXPIRED,{...cloneTimer(g),reason:"expired"}))},scheduleExpiry=e=>{clearScheduledExpiry(e),e.timeoutId=g(()=>expire(e.id),e.durationMs)},createDormantTimer=(e,t,g,n,C)=>{const o=t??C?.durationMs??0,I=normalizeStayVisible(n,C?.stayVisible??!0);return{id:e,durationMs:o,startedAt:null,label:"string"==typeof g?g:C?.label??"",direction:normalizeDirection$1(n,C?.direction??"countdown"),position:normalizePosition$1(n,C?.position??"top"),stayVisible:I,groupIds:normalizeGroupIds(n,C?.groupIds??[]),enabled:!1,running:!1,elapsedMs:I?o:0,timeoutId:null}},createTimer=(e,t,g,n)=>{const o=C.get(e);o&&clearScheduledExpiry(o);const I=createDormantTimer(e,normalizeDuration(t),g,n,o);return C.set(e,I),emitTimerUpdated(I),cloneTimer(I)},start2=g=>{const n=C.get(g);if(!n)return null;clearScheduledExpiry(n),n.elapsedMs=0,n.startedAt=t(),n.enabled=!0,n.running=!0,scheduleExpiry(n);const o=cloneTimer(n);return e.emit(O.TIMER_STARTED,o),o},list=(e={})=>{const t="string"==typeof e?e:e.groupId??null,g="object"==typeof e&&!0===e?.visibleOnly;return[...C.values()].map(e=>cloneTimer(e)).filter(e=>!(t&&!e.groupIds.includes(t)||g&&!isVisibleTimer(e)))},snapshot=()=>list({visibleOnly:!0});return{add:(e,t,g="",n)=>{const C=createTimer(e,t,g,n);return n&&"object"==typeof n&&!0===n.autoStart?start2(e):C},clearAll:()=>{if(0===C.size)return 0;const t=C.size;return C.forEach(e=>clearScheduledExpiry(e)),C.clear(),e.emit(O.TIMER_CLEARED),t},destroy:()=>{C.forEach(e=>clearScheduledExpiry(e)),C.clear()},get:e=>{const t=C.get(e);return t?cloneTimer(t):null},list,read:()=>{const e=[...C.values()].map(e=>cloneTimer(e)).filter(e=>isVisibleTimer(e));return o.length===e.length&&o.every((t,g)=>areTimerSnapshotsEqual(t,e[g]))||(o=e),o},remove:t=>{const g=C.get(t);if(!g)return null;clearScheduledExpiry(g);const n=cloneTimer(g);return C.delete(t),e.emit(O.TIMER_EXPIRED,{...n,reason:"removed"}),n},reset:e=>{const t=C.get(e);return t?(clearScheduledExpiry(t),t.elapsedMs=getIdleElapsedMs(t),t.startedAt=null,t.enabled=!1,t.running=!1,emitTimerUpdated(t),cloneTimer(t)):null},snapshot,start:start2,stop:e=>{const t=C.get(e);return t?(clearScheduledExpiry(t),t.elapsedMs=getElapsedMs2(t),t.startedAt=null,t.enabled=!1,t.running=!1,emitTimerUpdated(t),cloneTimer(t)):null}}},isPlainObject$1=e=>"[object Object]"===Object.prototype.toString.call(e),toNumber=(e,t=0)=>{const g="number"==typeof e?e:"string"==typeof e&&e.trim().length>0?Number(e):Number.NaN;return Number.isFinite(g)?g:t},toPercent=e=>{if("number"==typeof e&&Number.isFinite(e))return e;if("string"!=typeof e)return null;const t=Number.parseInt(e.replace("%","").trim(),10);return Number.isNaN(t)?null:t},toTrimmedString=e=>"string"==typeof e&&e.trim().length>0?e.trim():null,toBooleanFlag=e=>!0===e||1===e||"1"===e,stripAnsi=e=>"string"==typeof e?e.replace(/\u001b\[[0-9;]*m/g,"").trim():"",extractNamedValue=e=>Array.isArray(e)?toTrimmedString(e[0]):isPlainObject$1(e)?toTrimmedString(e.name):toTrimmedString(e),deepFreeze=e=>{if(!e||"object"!=typeof e||Object.isFrozen(e))return e;Object.freeze(e);for(const t of Object.values(e))deepFreeze(t);return e},parseFontSize=(e,t=14)=>{if("number"==typeof e&&Number.isFinite(e)&&e>0)return e;if("string"==typeof e){const t=Number.parseFloat(e);if(Number.isFinite(t)&&t>0)return t}return t},G={hp:{current:0,max:0},mp:{current:0,max:0},ep:{current:0,max:0},wp:{current:0,max:0},nl:{current:0,max:0},gold:0,bank:0,xp:0,xpToNext:0},createStatsModel=({eventBus:e}={})=>{let t=structuredClone(G);const read2=()=>t;return{update:g=>{for(const e of Object.keys(g)){const n=g[e];null===n||"object"!=typeof n||Array.isArray(n)?t[e]=n:t[e]={...t[e],...n}}e.emit(O.STATS_UPDATED,read2())},read:read2,snapshot:()=>deepFreeze(structuredClone(t)),destroy:()=>{t=structuredClone(G)}}},B=Object.freeze({goldCollection:!0,targetCalls:!0,affCalls:!0,callTargets:!1,callAffs:!1,gagChat:!1}),F=Object.freeze([{key:"goldCollection",label:"Collect Gold",tooltip:"Legacy party automation flag for gold collection behaviour."},{key:"targetCalls",label:"Accept Targets",tooltip:"Accept leader target calls from party chat."},{key:"affCalls",label:"Accept Affs",tooltip:"Accept legacy affliction call messages from party chat."},{key:"callTargets",label:"Call Targets",tooltip:"Legacy toggle preserved for compatibility with party workflows."},{key:"callAffs",label:"Call Affs",tooltip:"Legacy toggle preserved for compatibility with party workflows."},{key:"gagChat",label:"Gag Chat",tooltip:"Hide party chat lines from the display stream."}]),W=Object.freeze(F.map(({key:e})=>e)),isNonEmptyString=e=>"string"==typeof e&&e.trim().length>0,trimToEmpty=e=>isNonEmptyString(e)?e.trim():"",V=trimToEmpty,normalizeLookupKey=e=>trimToEmpty(e).toLowerCase(),toDisplayName=e=>trimToEmpty(e).replace(/[_-]+/g," ").replace(/\s+/g," ").replace(/\b([a-z])/g,e=>e.toUpperCase()),capitalizeFirst=e=>{const t=trimToEmpty(e);return t?t.charAt(0).toUpperCase()+t.slice(1):""},cloneSettings=e=>({...B,...e}),cloneState=e=>({members:[...e.members],leader:e.leader,selfName:e.selfName,settings:cloneSettings(e.settings)}),normalizeMembers=e=>{const t=[],g=new Set;return(Array.isArray(e)?e:[]).forEach(e=>{const n=V("string"==typeof e?e:e?.name);n&&!g.has(n)&&(g.add(n),t.push(n))}),t},reconcileLeader=(e,t)=>t.includes(e.leader)?e.leader:e.selfName&&t.includes(e.selfName)?e.selfName:t[0]??"",ensureSelfMember=(e,t)=>!e.selfName||t.includes(e.selfName)?t:[e.selfName,...t],createPartyModel=({eventBus:e}={})=>{let t={members:[],leader:"",selfName:"",settings:cloneSettings(B)};const emitUpdated=()=>{e.emit(O.PARTY_UPDATED,snapshot())},snapshot=()=>cloneState(t);return{update:e=>{const g=ensureSelfMember(t,normalizeMembers(e)),n=reconcileLeader(t,g);t.leader===n&&t.members.length===g.length&&t.members.every((e,t)=>e===g[t])||(t={...t,members:g,leader:n},emitUpdated())},addMember:e=>{const g=V(e);g&&!t.members.includes(g)&&(t={...t,members:[...t.members,g],leader:t.leader||g},emitUpdated())},removeMember:g=>{const n=V(g);if(!n||n===t.selfName||!t.members.includes(n))return;const C=t.members.filter(e=>e!==n);t={...t,members:C,leader:reconcileLeader(t,C)},e.emit(O.PARTY_MEMBER_LEFT,{name:n}),emitUpdated()},setLeader:e=>{const g=V(e);g&&t.members.includes(g)&&t.leader!==g&&(t={...t,leader:g},emitUpdated())},setSelf:e=>{const g=V(e);if(!g)return;const n=ensureSelfMember({...t,selfName:g},t.members.filter(e=>e!==g)),C=n.includes(t.leader)?t.leader:g;t.selfName===g&&t.leader===C&&t.members.length===n.length&&t.members.every((e,t)=>e===n[t])||(t={...t,selfName:g,members:n,leader:C},emitUpdated())},setSetting:(e,g)=>{if(!W.includes(e))throw new Error(`[nexGui4] Unknown party setting "${String(e)}".`);const n=!0===g;t.settings[e]!==n&&(t={...t,settings:{...t.settings,[e]:n}},emitUpdated())},read:()=>t,snapshot,destroy:()=>{t={members:[],leader:"",selfName:"",settings:cloneSettings(B)}}}},K={players:[],npcs:[],items:[],roomName:"",roomId:""},cloneRoomCollection=e=>Array.isArray(e)?structuredClone(e):[],createRoomModel=({eventBus:e}={})=>{let t=structuredClone(K);const read2=()=>t;return{update:g=>{t={players:g.players?[...g.players]:[],npcs:cloneRoomCollection(g.npcs),items:cloneRoomCollection(g.items),roomName:g.roomName??"",roomId:g.roomId??""},e.emit(O.ROOM_UPDATED,read2())},read:read2,snapshot:()=>({players:[...t.players],npcs:cloneRoomCollection(t.npcs),items:cloneRoomCollection(t.items),roomName:t.roomName,roomId:t.roomId}),destroy:()=>{t=structuredClone(K)}}},createEmptyTargetDetails=()=>({id:null,name:null,hpPercent:null,hpText:null,hpDelta:null,gender:null,currentAffs:[],limbs:{}}),U={name:"",class:"",level:0,target:null,targetDetails:createEmptyTargetDetails(),gender:null,balance:!1,equilibrium:!1,classBalanceType:null,classBalanceReady:null,currentAffs:[],limbs:{}},createCharacterModel=({eventBus:e}={})=>{let t={...U};const read2=()=>t;return{update:g=>{t={...t,...g},e.emit(O.CHARACTER_UPDATED,read2())},read:read2,setClass:g=>{t={...t,class:g},e.emit(O.CLASS_CHANGED,{class:g})},setTarget:g=>{t={...t,target:g},e.emit(O.TARGET_CHANGED,{target:g})},snapshot:()=>deepFreeze(structuredClone(t)),destroy:()=>{t={...U}}}},createDefenceModel=({eventBus:e}={})=>{let t=[];return{gain:g=>{t.includes(g)||(t=[...t,g].sort()),e.emit(O.DEFENCE_GAINED,{name:g})},lose:g=>{t.includes(g)&&(t=t.filter(e=>e!==g)),e.emit(O.DEFENCE_LOST,{name:g})},reset:()=>{t=[]},read:()=>t,snapshot:()=>[...t],destroy:()=>{t=[]}}},normalizeClassBalanceType=e=>"string"==typeof e&&e.trim().length>0?e.trim():null,normalizeClassStatList=e=>Array.isArray(e)?e.reduce((e,t)=>{if("string"!=typeof t)return e;const g=t.trim();return g?(e.push(g),e):e},[]):[],resolveClassBalanceReady=({classStats:e,classBalanceType:t})=>{const g=normalizeClassBalanceType(t);if(!g)return null;const n=normalizeClassStatList(e).map(e=>e.toLowerCase()),C=`${g.toLowerCase()}: yes`,o=`${g.toLowerCase()}: no`;return!!n.includes(C)||!n.includes(o)&&null},createClassBalanceController=()=>{let e=null,t=[];const snapshot=()=>({classBalanceType:e,classBalanceReady:resolveClassBalanceReady({classStats:t,classBalanceType:e})});return{getType:()=>e,setType:t=>(e=normalizeClassBalanceType(t),snapshot()),updateFromVitals:e=>(t=normalizeClassStatList(e?.charstats),snapshot()),destroy:()=>{e=null,t=[]}}},normalizeGender$1=e=>{if("string"!=typeof e)return null;const t=e.trim().toLowerCase();return"female"===t?"female":"male"===t?"male":null},normalizeAfflictionName=e=>{if(Array.isArray(e))return normalizeAfflictionName(e[0]);if(isPlainObject$1(e))return normalizeAfflictionName(e.name??e.affliction??e.id);if("string"!=typeof e)return null;const t=e.trim().toLowerCase();return t.length>0?t:null},normalizeAfflictionList=e=>{if(Array.isArray(e)){const t=e.map(e=>normalizeAfflictionName(e)).filter(Boolean);return t.length>0?Array.from(new Set(t)):null}return isPlainObject$1(e)?normalizeAfflictionList(Object.keys(e)):null},normalizeLimbMap=e=>isPlainObject$1(e)?Object.fromEntries(Object.entries(e).map(([e,t])=>null!==t&&"object"==typeof t?[e,structuredClone(t)]:[e,{percent:toNumber(t)}])):null,buildCharacterDetailPatch=e=>{if(!isPlainObject$1(e))return null;const t={},g=normalizeGender$1(e.gender),n=normalizeAfflictionList(e.currentAffs??e.afflictions),C=normalizeLimbMap(e.limbs);return g&&(t.gender=g),n&&(t.currentAffs=n),C&&(t.limbs=C),Object.keys(t).length>0?t:null},applyCharacterAfflictionEvent=(e,t,g)=>{if("Char.Afflictions.Add"!==t&&"Char.Afflictions.Remove"!==t)return!1;const n=normalizeAfflictionName(g);if(!n)return!1;const C=e.snapshot(),o=Array.isArray(C.currentAffs)?C.currentAffs:[];return"Char.Afflictions.Add"===t?!o.includes(n)&&(e.update({currentAffs:[...o,n]}),!0):(e.update({currentAffs:o.filter(e=>e!==n)}),!0)},extractTargetLabel=e=>{if("string"==typeof e){const t=toTrimmedString(e);return!t||/^\d+$/.test(t)?null:t}return isPlainObject$1(e)?toTrimmedString(e.short_desc)??toTrimmedString(e.name)??toTrimmedString(e.fullname)??toTrimmedString(e.text):null},toTargetIdString=e=>"string"==typeof e?toTrimmedString(e):"number"==typeof e&&Number.isFinite(e)?String(e):null,extractTargetId=e=>"string"==typeof e?toTargetIdString(e):isPlainObject$1(e)?toTargetIdString(e.id)??toTargetIdString(e.target):null,getTargetHpText=e=>{if(!isPlainObject$1(e))return null;const t=e.hpperc??e.hpPercent??e.hp;return"number"==typeof t&&Number.isFinite(t)?String(t):toTrimmedString(t)},buildTargetDetailsPatch=(e,t=createEmptyTargetDetails())=>{if(!isPlainObject$1(e))return null;const g=e.currentAffs??e.afflictions,n=Array.isArray(g)||isPlainObject$1(g),C=isPlainObject$1(e.limbs),o=getTargetHpText(e),I=toPercent(o),a="number"==typeof e.hpChange&&Number.isFinite(e.hpChange)?e.hpChange:"string"==typeof e.hpChange&&e.hpChange.trim().length>0?toNumber(e.hpChange,t.hpDelta??0):null!=I&&null!=t.hpPercent?t.hpPercent-I:null,i=normalizeAfflictionList(g),s=normalizeLimbMap(e.limbs),l=normalizeGender$1(e.gender),c={};return extractTargetId(e)&&(c.id=extractTargetId(e)),extractTargetLabel(e)&&(c.name=extractTargetLabel(e)),null!==o&&(c.hpText=o),null!==I&&(c.hpPercent=I),null!==a&&(c.hpDelta=a),l&&(c.gender=l),(i||n)&&(c.currentAffs=i??[]),(s||C)&&(c.limbs=s??{}),Object.keys(c).length>0?c:null},hasTargetDetails=e=>!!isPlainObject$1(e)&&(Object.keys(e.limbs??{}).length>0||Array.isArray(e.currentAffs)&&e.currentAffs.length>0||null!==e.name||null!==e.id||null!==e.hpPercent||null!==e.hpText),mergeTargetDetails=(...e)=>{const t=createEmptyTargetDetails();for(const g of e)isPlainObject$1(g)&&(null!=g.id&&(t.id=g.id),null!=g.name&&(t.name=g.name),null!=g.hpPercent&&(t.hpPercent=g.hpPercent),null!=g.hpText&&(t.hpText=g.hpText),null!=g.hpDelta&&(t.hpDelta=g.hpDelta),null!=g.gender&&(t.gender=g.gender),Array.isArray(g.currentAffs)&&(t.currentAffs=[...g.currentAffs]),isPlainObject$1(g.limbs)&&(t.limbs=structuredClone(g.limbs)));return t},createTargetSyncModel=({characterModel:e,getHostTarget:t=()=>null}={})=>{const clear=()=>{e.update({targetDetails:createEmptyTargetDetails()}),e.setTarget(null)},sync=({targetValue:g,hostTargetValue:n=t(),reset:C=!1}={})=>{const o=e.snapshot().targetDetails??createEmptyTargetDetails(),I=extractTargetId(g),a=C||I&&o.id&&o.id!==I?createEmptyTargetDetails():o,i=buildTargetDetailsPatch(n,a),s=mergeTargetDetails(a,i),l=buildTargetDetailsPatch(g,s),c=mergeTargetDetails(s,l),u=c.name??extractTargetLabel(n)??extractTargetLabel(g);e.update({targetDetails:hasTargetDetails(c)?c:createEmptyTargetDetails()}),e.setTarget(u??null)};return Object.freeze({clear,sync})},H=Object.freeze(["m","mx"]),Y=new Set(H),isRoomNpcAttrib=e=>"string"==typeof e&&Y.has(e),isRoomNpcItem=e=>"object"==typeof e&&null!==e&&isRoomNpcAttrib(e.attrib),getRoomEntryId=e=>isPlainObject$1(e)&&null!=e.id?String(e.id):null,isRoomLocation=e=>"room"===toTrimmedString(e?.location)?.toLowerCase(),splitRoomEntries=e=>(Array.isArray(e)?structuredClone(e):[]).reduce((e,t)=>(isRoomNpcItem(t)?e.npcs.push(t):e.items.push(t),e),{items:[],npcs:[]}),extractRoomItemList=e=>Array.isArray(e?.items)?e.items:Array.isArray(e?.Items)?e.Items:Array.isArray(e?.room)?e.room:[],extractRoomItemEntry=e=>isPlainObject$1(e?.item)?e.item:isPlainObject$1(e?.Item)?e.Item:isPlainObject$1(e)?e:null,removeRoomItemEntry=(e,t)=>e.filter(e=>getRoomEntryId(e)!==t),upsertRoomItemEntry=(e,t)=>{const g=getRoomEntryId(t);if(!g)return[...e,structuredClone(t)];const n=structuredClone(e),C=n.findIndex(e=>getRoomEntryId(e)===g);return-1===C?(n.push(structuredClone(t)),n):(n[C]=structuredClone(t),n)},createRoomOccupantsModel=({roomModel:e,playerDirectory:t}={})=>{const rememberRoomPlayers=e=>{t?.rememberRoomPlayers?.(e)},apply=(t,g)=>{const n=e.snapshot();switch(t){case"Room.Info":{const t=Array.isArray(g?.Players)?g.Players:Array.isArray(g?.players)?g.players:[],C=t.map(e=>extractNamedValue(e)??toTrimmedString(e?.fullname)).filter(Boolean);return rememberRoomPlayers(t),e.update({...n,players:C,roomName:toTrimmedString(g?.name)??"",roomId:g?.num??g?.id??""}),!0}case"Room.AddPlayer":{const t=toTrimmedString(g?.name)??extractNamedValue(g)??toTrimmedString(g?.fullname);return!(!t||n.players.includes(t)||(rememberRoomPlayers([g]),e.update({...n,players:[...n.players,t]}),0))}case"Room.RemovePlayer":{const t=extractNamedValue(g);return!!t&&(e.update({...n,players:n.players.filter(e=>e!==t)}),!0)}case"Char.Items.List":return!!isRoomLocation(g)&&(e.update({...n,...splitRoomEntries(extractRoomItemList(g))}),!0);case"Char.Items.Add":case"Char.Items.Update":{if(!isRoomLocation(g))return!1;const t=extractRoomItemEntry(g);if(!t)return!1;const C=getRoomEntryId(t),o=null==C?n.npcs:removeRoomItemEntry(n.npcs,C),I=null==C?n.items:removeRoomItemEntry(n.items,C);return e.update({...n,npcs:isRoomNpcItem(t)?upsertRoomItemEntry(o,t):o,items:isRoomNpcItem(t)?I:upsertRoomItemEntry(I,t)}),!0}case"Char.Items.Remove":{if(!isRoomLocation(g))return!1;const t=getRoomEntryId(extractRoomItemEntry(g));return!!t&&(e.update({...n,npcs:removeRoomItemEntry(n.npcs,t),items:removeRoomItemEntry(n.items,t)}),!0)}default:return!1}};return Object.freeze({apply})},Z=Object.freeze({"&":"&amp;","<":"&lt;",">":"&gt;",'"':"&quot;","'":"&#39;"}),escapeHtml=e=>String(e??"").replace(/[&<>"']/g,e=>Z[e]),Q=Object.freeze({amp:"&",lt:"<",gt:">",quot:'"',apos:"'",nbsp:" "}),stripHtml=e=>{if(!e||"string"!=typeof e)return e??"";let t=e.replace(/<[^>]+>/g,"");return t=t.replace(/&([^;]+);/g,(e,t)=>{if(Q[t])return Q[t];if(t.startsWith("#")){const e=t.startsWith("#x")?parseInt(t.substring(2),16):parseInt(t.substring(1),10);if(!isNaN(e))return String.fromCharCode(e)}return e}),t},X=Object.freeze({"a monolith sigil":{color:"red",text:"A MONOLITH SIGIL"},"a cube sigil":{color:"yellow",text:"A CUBE SIGIL"},"some gold sovereigns":{color:"gold",text:"GOLD COINS"}}),q=Object.freeze({angle:Object.freeze({open:"<",close:">"}),square:Object.freeze({open:"[",close:"]"}),curly:Object.freeze({open:"{",close:"}"}),round:Object.freeze({open:"(",close:")"})}),styleAttribute$2=e=>{const t=Object.entries(e).filter(([,e])=>e);return 0===t.length?"":` style="${t.map(([e,t])=>`${e}: ${t}`).join("; ")}"`},createTextSegment=(e,t,g={})=>({text:e,color:t,italic:Boolean(g.italic),bold:Boolean(g.bold)}),renderSegmentHtml=e=>`<span${styleAttribute$2({color:e.color,"font-style":e.italic?"italic":null,"font-weight":e.bold?"700":null})}>${escapeHtml(e.text)}</span>`,createStaticRule=(e,t,g,n)=>Object.freeze({family:"room-text",id:e,gate:t,pattern:g,createMarker:()=>n}),createDirectionalRule=(e,t,g,n,C,o,I,a)=>Object.freeze({family:"room-text",id:e,gate:t,pattern:g,createMarker:e=>({frame:n,frameColor:C,segments:[createTextSegment(o,I),createTextSegment(capitalizeFirst(e?.groups?.direction),a)]})}),createSigilRule=(e,t,g,n,C)=>createStaticRule(e,t,g,{frame:"curly",frameColor:"yellow",segments:[createTextSegment("Sigil: ","silver"),createTextSegment(n,C)]}),createRuneRule=(e,t,g,n)=>createStaticRule(e,t,g,{frame:"round",frameColor:"red",segments:[createTextSegment("Rune: ","silver"),createTextSegment(n,"aquamarine")]}),createConquestRule=(e,t,g,n,C)=>createStaticRule(e,t,g,{frame:null,frameColor:null,leftIcons:[{id:"shield-halved",colors:["silver",C],size:12}],rightIcons:[{id:"shield-halved",colors:[C,"silver"],size:12}],segments:[createTextSegment(" Conquest: ","slategray"),createTextSegment(n,C)]}),J=Object.freeze([createStaticRule("totem","runic totem",/A runic totem is planted solidly in the ground\./,{frame:"angle",frameColor:"dodgerblue",segments:[createTextSegment("TOTEM","Tomato")]}),createStaticRule("frozenGround","slick with",/The ground is slick with ice\./,{frame:"angle",frameColor:"dodgerblue",segments:[createTextSegment("Frozen Ground","PowderBlue")]}),createStaticRule("graveHands","rotting flesh",/Hands of rotting flesh and white bone push up from the ground/,{frame:"angle",frameColor:"crimson",segments:[createTextSegment("Gravehands","Beige")]}),createDirectionalRule("icewall","icewall",/An icewall is here, blocking passage to the (?<direction>\w+)\./,"square","red","Icewall: ","dodgerblue","aquamarine"),createDirectionalRule("stonewall","wall of stone",/A large wall of stone stands here, blocking passage to the (?<direction>\w+)\./,"square","red","Stonewall: ","silver","aquamarine"),createSigilRule("cubeSigil","cube",/Resting on the ground is a cube-shaped silver sigil\./,"Cube","aquamarine"),createSigilRule("eyeSigil","obsidian",/An obsidian eye sigil is here\./,"Eye","lightgreen"),createSigilRule("monolithSigil","monolith",/A sigil in the shape of a small, rectangular monolith is on the ground\./,"Monolith","red"),createSigilRule("keySigil","key-shaped",/Lying flat on the ground is a key-shaped sigil\./,"Key","lightPink"),createRuneRule("kena","nightmares",/A rune that looks like something out of your nightmares has been sketched into the ground here\./,"Kena"),createRuneRule("uruz","lightning bolt",/A rune like a lightning bolt has been sketched into the ground here\./,"Uruz"),createRuneRule("fehu","closed eye",/A rune like a closed eye has been sketched into the ground here\./,"Fehu"),createRuneRule("pithikhan","square box",/A rune resembling a square box has been sketched into the ground here\./,"Pithikhan"),createRuneRule("inguz","stick man",/A rune that looks like a stick man has been sketched into the ground here\./,"Inguz"),createRuneRule("wunjo","open eye",/A rune like an open eye has been sketched into the ground here\./,"Wunjo"),createRuneRule("sowulu","a nail",/A rune that looks like a nail has been sketched into the ground here\./,"Sowulu"),createRuneRule("isaz","flurry of lighning",/A rune like a flurry of lightning bolts has been sketched into the ground here\./,"Isaz"),createRuneRule("dagaz","rising sun",/A rune like a rising sun has been sketched into the ground here\./,"Dagaz"),createRuneRule("raido","resembling a horse",/A rune resembling a horse has been sketched into the ground here\./,"Raido"),createRuneRule("nauthiz","resembling a leech",/A rune resembling a leech has been sketched into the ground here\./,"Nauthiz"),createRuneRule("mannaz","resembling a bell",/A rune resembling a bell has been sketched into the ground here\./,"Mannaz"),createRuneRule("othala","resembling a mountain",/A rune resembling a mountain range has been sketched into the ground here\./,"Othala"),createRuneRule("sleizak","resembling a viper",/A rune resembling a viper has been sketched into the ground here\./,"Sleizak"),createRuneRule("tiwaz","upward-pointing arrow",/A rune like an upward-pointing arrow has been sketched into the ground here\./,"Tiwaz"),createRuneRule("nairat","like a butterfly",/A rune shaped like a butterfly has been sketched into the ground here\./,"Nairat"),createRuneRule("eihwaz","like a yew",/A rune shaped like a yew has been sketched into the ground here\./,"Eihwaz"),createConquestRule("conquestAshtan","warp-touched",/Crackling ozone heralds warp-touched mirage, their coming the advent of change\./,"Ashtan ","#990099"),createConquestRule("conquestCyrene","draconic tracks",/Bound in ice, draconic tracks scribe a glittering path across the earth\./,"Cyrene ","#009999"),createConquestRule("conquestNeraeos","Cerulean waters",/Cerulean waters preside, fathom and depths stirred to roiling currents by the pervasive will of Neraeos Pelagia, Lord of the Sea\./,"Cyrene ","#009999"),createConquestRule("conquestEleusis","fecundity",/Nature's fecundity floods the surrounds with the clamour of life in a chittering refrain\./,"Eleusis ","#00e600"),createConquestRule("conquestHashan","leaden shadow",/Lines of leaden shadow coil underfoot, turning earth to metal by alchemical writ\./,"Hashan ","#999900"),createConquestRule("conquestMhaldor","red-hued",/A noxious, red-hued fog overwhelms the area with a thick, palpable vapour\./,"Mhaldor ","#e60000"),createConquestRule("conquestTargossas","mien",/Radiant light joins with calescent heat, suffusing the area with a harsh, blinding mien\./,"Targossas ","#ffffff"),createConquestRule("conquestUnderworld","ashen earth",/Soul's blood pools on ashen earth turned dust, an inviolable call to death's advance\./,"Underworld ","tomato")]),$=new Map,_=new Set,notifyOverrideSubscribers=()=>{for(const e of _)e()},subscribeToRoomItemOverrides=e=>(_.add(e),()=>_.delete(e)),setUserRoomItemOverride=(e,t)=>{const g=normalizeLookupKey(e);g&&($.set(g,t),notifyOverrideSubscribers())},removeUserRoomItemOverride=e=>{const t=normalizeLookupKey(e);t&&($.delete(t),notifyOverrideSubscribers())},getUserRoomItemOverride=e=>{const t=normalizeLookupKey(e);return t?$.get(t)??null:null},listUserRoomItemOverrides=()=>Array.from($.entries()),getRoomItemOverride=e=>{if("string"==typeof e){const t=normalizeLookupKey(e);return $.get(t)??X[t]??null}if(!e||"object"!=typeof e)return null;const t=normalizeLookupKey(e.id),g=normalizeLookupKey(e.name);return $.get(t)??$.get(g)??X[t]??X[g]??null},renderRoomMarkerHtml=(e,t={})=>{const g=e.frame?q[e.frame]:null,n=t.iconRenderer,C=Array.isArray(e.leftIcons)?e.leftIcons.map(e=>n?.(e)??"").join(""):"",o=Array.isArray(e.rightIcons)?e.rightIcons.map(e=>n?.(e)??"").join(""):"";return[C,g?renderSegmentHtml(createTextSegment(g.open,e.frameColor,{bold:!0})):"",e.segments.map(renderSegmentHtml).join(""),g?renderSegmentHtml(createTextSegment(g.close,e.frameColor,{bold:!0})):"",o].join("")},matchRoomTextReplacements=e=>isNonEmptyString(e)?J.flatMap(t=>{if(!e.includes(t.gate))return[];const g=e.match(t.pattern);return g?[{rule:t,match:g,marker:t.createMarker(g)}]:[]}):[],replaceRoomText=(e,t={})=>{if(!isNonEmptyString(e))return e;let g=e;for(const{rule:n,match:C,marker:o}of matchRoomTextReplacements(e))g=g.replace(n.pattern,renderRoomMarkerHtml(o,t));return g},createWormholeExitDescriptor=({warp:e,currentArea:t}={})=>{if(!e||"object"!=typeof e)return null;const g=t&&t===e.area?e.name:e.areaName;return isNonEmptyString(g)?{family:"room-exit",command:"worm warp",label:`Wormhole: (${g})`}:null},renderWormholeExitHtml=e=>e?`<span>, and <a class="mxp_send" href="#" rel="${escapeHtml(e.command)}">${escapeHtml(e.label)}</a>.</span>`:"",extractPartyChatPayload=e=>{if(!isPlainObject$1(e)||"party"!==toTrimmedString(e.channel)?.toLowerCase())return null;const t=toTrimmedString(e.talker),g=stripAnsi(e.text);if(!t||!g)return null;const n=g.match(/^\(Party\): (\w+) says, "(.+)"$/);return{talker:t,message:n?.[2]??g}},capitalizeLookupName=e=>`${e.charAt(0).toUpperCase()}${e.slice(1)}`,createPartyAutomationModel=({characterModel:e,partyModel:t,playerDirectory:g,sendCommand:n}={})=>{const send=e=>{"function"==typeof n&&n(e)},processChannelText=n=>{const C=extractPartyChatPayload(n);if(!C)return!1;const o=t.snapshot();if(!o.settings.targetCalls||C.talker!==o.leader)return!1;const I=C.message.match(/^Target: (.+)\.$/)??C.message.match(/^(?:Target|TARGET) (.+)\.$/);if(I){const t=toTrimmedString(I[1]);if(!t)return!1;const n=e.snapshot(),C=g.getPlayerProfile(n.name)?.city??"",o=g.getPlayerProfile(capitalizeLookupName(t))??g.getPlayerProfile(t);return!(o?.city&&C&&o.city===C||(send(`settarget ${t}`),send(`enemy ${t}`),0))}const a=C.message.match(/^Enemy (.+)\.$/);if(a){const e=toTrimmedString(a[1]);if(e)return send(`enemy ${e}`),!0}return!1},processEvent=(e,t)=>"Comm.Channel.Text"===e&&processChannelText(t);return Object.freeze({processChannelText,processEvent})},ee=(ge={commands:["send","sendGmcp"],variables:["getVariable","setVariable"],target:["getTarget","setTarget"],output:["notice","gagCurrentBlock"],host:["getHostSettings","setHostSetting","getHostLayoutSnapshot","updateHostLayoutAttributes","focusInput","getConfiguredDefences"],events:["on","off"],lifecycle:["destroy"]},Object.freeze(Object.fromEntries(Object.entries(ge).map(([e,t])=>[e,Object.freeze([...t])])))),te=Object.freeze(Object.values(ee).flat()),assertAdapterContract=e=>{const t=te;for(const g of t)if("function"!=typeof e?.[g])throw new Error(`[nexGui4] Adapter missing required method: "${g}"`);return e},createStoreImpl=e=>{let t;const g=new Set,setState=(e,n)=>{const C="function"==typeof e?e(t):e;if(!Object.is(C,t)){const e=t;t=(null!=n?n:"object"!=typeof C||null===C)?C:Object.assign({},t,C),g.forEach(g=>g(t,e))}},getState=()=>t,n={setState,getState,getInitialState:()=>C,subscribe:e=>(g.add(e),()=>g.delete(e))},C=t=e(setState,getState,n);return n},createStore=e=>e?createStoreImpl(e):createStoreImpl,identity$1=e=>e;var ge;function useStore(e,g=identity$1){const n=t.useSyncExternalStore(e.subscribe,t.useCallback(()=>g(e.getState()),[e,g]),t.useCallback(()=>g(e.getInitialState()),[e,g]));return t.useDebugValue(n),n}const createImpl=e=>{const t=createStore(e),useBoundStore=e=>useStore(t,e);return Object.assign(useBoundStore,t),useBoundStore},create=e=>e?createImpl(e):createImpl,normalizeConfiguredDefenceList=e=>{if(!Array.isArray(e))return[];const t=new Set;return e.reduce((e,g)=>{if("string"!=typeof g)return e;const n=g.trim();return!n||t.has(n)||(t.add(n),e.push(n)),e},[])},createDefenceStore=({defenceModel:e,eventBus:t,configuredDefences:g=[]})=>{const readDefences=()=>e.read?.()??e.snapshot(),n=create(()=>({defences:readDefences(),configuredDefences:normalizeConfiguredDefenceList(g),gainDefence:t=>e.gain(t),loseDefence:t=>e.lose(t),resetDefences:()=>{e.reset(),n.setState({defences:readDefences()})},setConfiguredDefences:e=>{n.setState({configuredDefences:normalizeConfiguredDefenceList(e)})}})),refreshDefences=()=>{n.setState({defences:readDefences()})};return t.on(O.DEFENCE_GAINED,refreshDefences),t.on(O.DEFENCE_LOST,refreshDefences),n},ensureInsight=()=>("undefined"==typeof insight&&(globalThis.insight={target:null}),globalThis.insight),removeTrackedHandler=(e,t,g)=>{const n=e.get(t);if(n){if("string"==typeof g)n.delete(g);else for(const[e,t]of n.entries())if(t===g){n.delete(e);break}0===n.size&&e.delete(t)}},normalizeListenerIdSegment=e=>String(e).replace(/[^A-Za-z0-9]+/g,"-").replace(/^-+|-+$/g,"").replace(/-{2,}/g,"-"),createDefaultListenerId=(e,t)=>{const g=`nexGui4-${normalizeListenerIdSegment(e)||"event"}`;if(!t||0===t.size)return g;let n=t.size+1,C=`${g}-${n}`;for(;t.has(C);)n+=1,C=`${g}-${n}`;return C},re="#00B1D2",ne=`<span style="color:${re};">[-</span><span style="color:#FDDB27;">nexGui</span><span style="color:${re};">-] </span>`,renderNoticeHtml=(e,t)=>{if(t?.html)return ne+String(e);const g=t&&"object"==typeof t?t.style:t,n=escapeHtml(e);return"string"==typeof g&&g.trim()?ne+`<span style="color: ${escapeHtml(g.trim())};">${n}</span>`:ne+n},getHostSettings=()=>nexusclient.settings?.()??{},getHostLayout=()=>nexusclient.ui?.()?.layout?.()??null,updateHostLayoutAttributes=e=>{const t=getHostLayout();t?.flexModel?.doAction&&"function"==typeof t.model&&t.flexModel.doAction({type:"FlexLayout_UpdateModelAttributes",data:{json:{...t.model()?.global??{},...e}}})},extractLegacyRuntimeConfiguredDefences=()=>normalizeConfiguredDefenceList(globalThis.nexGui?.defences),extractNexSysConfiguredDefences=()=>{const e=globalThis.nexSys?.defPrios,t=globalThis.nexSys?.defs;if("[object Object]"!==Object.prototype.toString.call(e)||"[object Object]"!==Object.prototype.toString.call(t))return[];const g=Object.entries(e.keepup??{}).filter(([,e])=>Boolean(e)).map(([e])=>e).filter(e=>Boolean(t?.[e]?.prio)),n=Object.entries(e.static??{}).filter(([,e])=>Boolean(e)).map(([e])=>e).filter(e=>Boolean(t?.[e]?.prio));return normalizeConfiguredDefenceList([...g,...n])},resolveConfiguredDefences=()=>{const e=extractLegacyRuntimeConfiguredDefences();return e.length>0?e:extractNexSysConfiguredDefences()},createNexusAdapter=({playerRelationships:e}={})=>{const t=new Map;return assertAdapterContract({send:t=>(e?.trackRelationshipCommand?.(t),nexusclient.send_commands(t)),sendGmcp:(e,t)=>nexusclient.datahandler().send_GMCP(e,t),getVariable:e=>nexusclient.variables().vars?.[e],setVariable:(e,t)=>{const g=nexusclient.variables();g.vars??={},g.vars[e]=t},getTarget:()=>{const e=ensureInsight();return"function"==typeof e?.getTarget?e.getTarget()??null:e?.target??null},setTarget:e=>{const t=ensureInsight();!t||"object"!=typeof t||"function"==typeof t.getTarget||void 0!==t.target&&"string"!=typeof t.target&&null!=e||(t.target=e??null),nexusclient.setTarget(e)},notice:(e,t)=>{if("function"==typeof nexusclient.add_html_line)return void nexusclient.add_html_line(renderNoticeHtml(e,t));const g=t&&"object"==typeof t?t.style:t;"function"==typeof nexusclient.writeLine&&nexusclient.writeLine(e,g)},getHostSettings,setHostSetting:(e,t)=>{getHostSettings()[e]=t},getHostLayoutSnapshot:()=>getHostLayout()?.model?.()?.global??{},updateHostLayoutAttributes,focusInput:()=>{nexusclient.focusInput?.()},getConfiguredDefences:resolveConfiguredDefences,gagCurrentBlock:()=>nexusclient.current_block?.forEach(e=>e.gag=!0),on:(e,g,n)=>{t.has(e)||t.set(e,new Map);const C=t.get(e),o=null!=n?.id?n:{...n,id:createDefaultListenerId(e,C)},I=eventStream.registerEvent(e,g,o);return t.get(e).set(I,g),()=>{eventStream.removeListener(e,I),removeTrackedHandler(t,e,I)}},off:(e,g)=>{eventStream.removeListener(e,g),removeTrackedHandler(t,e,g)},destroy:()=>{for(const[e,g]of t.entries())for(const t of g.keys())eventStream.removeListener(e,t);t.clear()}})},Ae=Object.freeze({"(hidden)":"orange","(none)":"orange",ashtan:"#990099",cyrene:"#009999",eleusis:"#00e600",hashan:"#999900",mhaldor:"#e60000",targossas:"#ffffff",garden:"yellow",underworld:"tomato"}),normalizePlayerCityKey=e=>{if(!isNonEmptyString(e))return"";const t=e.trim().toLowerCase();return"(hidden)"===t||"(none)"===t?t:t.replace(/\(.+?\)/g,"").replace(/,.*$/g,"").trim()},getPlayerCityColor=(e,t="orange")=>{const g=normalizePlayerCityKey(e);return g?Ae[g]??t:t},resolveRoomPlayerName=(e,t)=>isNonEmptyString(e)?e.trim():isPlainObject$1(e)?isNonEmptyString(e.name)?e.name.trim():isNonEmptyString(e.fullname)?t?.resolvePlayerNameFromFullname?.(e.fullname)??"":"":"",buildFallbackPlayerProfile=(e,t)=>{if(!isPlainObject$1(e))return null;const g={loaded:!0,name:t};return isNonEmptyString(e.city)&&(g.city=normalizePlayerCityKey(e.city)),isNonEmptyString(e.class)&&(g.class=e.class.trim()),isNonEmptyString(e.fullname)&&(g.fullname=e.fullname.trim()),"number"==typeof e.level&&Number.isFinite(e.level)?g.level=e.level:isNonEmptyString(e.level)&&(g.level=e.level.trim()),Object.keys(g).length>2?g:null},mergePlayerPresentationProfile=(e,t)=>e?t?{...t,...e,loaded:!0===e.loaded||!0===t.loaded}:e:t,resolvePlayerPresentationColor=({name:e,profile:t,playerDirectory:g}={})=>!0===t?.loaded&&isNonEmptyString(t.city)?getPlayerCityColor(t.city):g?.getPlayerColor?.(V(e))??"grey",cloneProfileValue=e=>Array.isArray(e)||isPlainObject$1(e)?structuredClone(e):e,sanitizeProfilePatch=(e={})=>{if(!isPlainObject$1(e))return{};const t={};for(const[g,n]of Object.entries(e))"name"!==g&&"regex"!==g&&"user"!==g&&("loaded"!==g?"city"!==g?"fullname"!==g?"source"!==g?"loadedAt"!==g&&"remoteSyncedAt"!==g?null!=n&&("string"!=typeof n?("number"==typeof n||"boolean"==typeof n||Array.isArray(n)||isPlainObject$1(n))&&(t[g]=cloneProfileValue(n)):n.trim().length>0&&(t[g]=n.trim())):"number"==typeof n&&Number.isFinite(n)?t[g]=n:null===n&&(t[g]=null):"local"!==n&&"public"!==n&&"remote"!==n||(t.source=n):isNonEmptyString(n)&&(t.fullname=n.trim()):isNonEmptyString(n)&&(t.city=normalizePlayerCityKey(n)):t.loaded=!0===n);return t},resolveFetch$1=e=>"function"==typeof e?e:null,createPlayerDirectoryModel=({fetchImpl:e,now:t=()=>0}={})=>{const g=new Map,n=new Map,C=new Map,o=new Set;let I=0;const notifyListeners=()=>{I+=1,o.forEach(e=>{try{e()}catch{}})},upsertProfile=(e,t={})=>{const C=V(e);if(!C)return;const o={...g.get(C)??{name:C,city:"",fullname:"",loaded:!1,source:"local",loadedAt:null,remoteSyncedAt:null},...sanitizeProfilePatch(t),name:C};g.set(C,o),isNonEmptyString(o.fullname)&&n.set(o.fullname.trim(),C),notifyListeners()},resolveStoredName=e=>{const t=V(e);if(!t)return"";if(g.has(t))return t;const n=normalizeLookupKey(t);for(const C of g.keys())if(C.toLowerCase()===n)return C;return t},getStoredProfileByNormalizedName=e=>e&&g.has(e)?g.get(e)??null:null,getPlayerProfile2=e=>{const t=getStoredProfileByNormalizedName(V(e));return t?{...t}:null},fetchCharacterProfile=async g=>{const n=V(g),o=resolveStoredName(g),I=normalizeLookupKey(g);if(!n)return null;if(C.has(I))return C.get(I);const a=resolveFetch$1(e);if("function"!=typeof a)return o?getPlayerProfile2(o):null;const i=(async()=>{try{const e=await a(`https://api.achaea.com/characters/${n.toLowerCase()}.json`,{cache:"no-store"});if(!e.ok)return o?getPlayerProfile2(o):null;const g=await e.json(),C=resolveStoredName(g?.name??n);return upsertProfile(C,{...g,loaded:!0,source:"public",loadedAt:t()}),getPlayerProfile2(C)}catch{return o?getPlayerProfile2(o):null}finally{C.delete(I)}})();return C.set(I,i),i},refreshPlayerProfile=async e=>{const t=await fetchCharacterProfile(e);if(t)return t;const g=resolveStoredName(e);return g?getPlayerProfile2(g):null},subscribePlayerDirectory=e=>(o.add(e),()=>{o.delete(e)}),rememberPlayerStatus=({name:e,city:t,fullname:g,...n}={})=>{const C=V(e);C&&upsertProfile(C,{...n,name:C,city:t,fullname:g,loaded:!0})},rememberChannelPlayers=e=>{Array.isArray(e)&&e.forEach(e=>{const t=V(e?.name);t&&(upsertProfile(t,{fullname:e?.fullname}),g.get(t)?.loaded||fetchCharacterProfile(t))})},rememberRoomPlayers=e=>{Array.isArray(e)&&e.forEach(e=>{const t=V(e?.name??e);t&&(upsertProfile(t,{fullname:e?.fullname}),g.get(t)?.loaded||fetchCharacterProfile(t))})},resolvePlayerNameFromFullname=e=>{if(!isNonEmptyString(e))return"";const t=e.trim(),g=n.get(t);if(g)return g;const C=t.split(/\s+/).at(-1);return V(C)},getPlayerColorByNormalizedName=e=>{const t=getStoredProfileByNormalizedName(e);return t?.loaded&&t.city?getPlayerCityColor(t.city):"grey"},getPlayerColor=e=>getPlayerColorByNormalizedName(V(e)),resetPlayerDirectory=()=>{g.clear(),n.clear(),C.clear(),notifyListeners()},hydrateFromCacheEntries=e=>{Array.isArray(e)&&e.forEach(e=>{const t=V(e?.name);t&&upsertProfile(t,{...e,loaded:!0})})},hydrateFromRemoteEntries=e=>{if(!Array.isArray(e))return;const g=t();e.forEach(e=>{const t=V(e?.name);t&&upsertProfile(t,{...e,loaded:!0,source:"remote",remoteSyncedAt:g})})},getAllPlayerProfiles=()=>Array.from(g.values()).map(e=>({...e})),getKnownPlayerNames=()=>Array.from(g.keys()),destroy=()=>{g.clear(),n.clear(),C.clear(),o.clear()};return Object.freeze({getAllPlayerProfiles,getKnownPlayerNames,getPlayerColor,getPlayerColorByNormalizedName,getPlayerProfile:getPlayerProfile2,getVersion:()=>I,hydrateFromCacheEntries,hydrateFromRemoteEntries,refreshPlayerProfile,rememberChannelPlayers,rememberPlayerStatus,rememberRoomPlayers,resetPlayerDirectory,resolvePlayerNameFromFullname,subscribePlayerDirectory,destroy})},Ce=createPlayerDirectoryModel(),getDefaultPlayerDirectoryModel=()=>Ce,getPlayerProfile=e=>Ce.getPlayerProfile(e),updateSetMembership=(e,t,g)=>{if(!t)return!1;const n=e.has(t);return g&&!n?(e.add(t),!0):!(g||!n||(e.delete(t),0))},normalizeNames=e=>Array.isArray(e)?new Set(e.map(e=>V(e)).filter(Boolean)):new Set,replaceSetContents=(e,t)=>{const g=normalizeNames(t);let n=!1;return[...e].forEach(t=>{g.has(t)||(e.delete(t),n=!0)}),g.forEach(t=>{e.has(t)||(e.add(t),n=!0)}),n},createPlayerRelationshipsModel=()=>{const e=new Set,t=new Set,g=new Set,n=new Set;let C=0;const notifyListeners=()=>{C+=1,n.forEach(e=>{try{e()}catch{}})},subscribePlayerRelationships=e=>(n.add(e),()=>{n.delete(e)}),rememberEnemyPlayer=g=>{const n=V(g),C=updateSetMembership(e,n,!0),o=updateSetMembership(t,n,!1);(C||o)&&notifyListeners()},rememberAllyPlayer=g=>{const n=V(g),C=updateSetMembership(t,n,!0),o=updateSetMembership(e,n,!1);(C||o)&&notifyListeners()},forgetEnemyPlayer=t=>{const g=V(t);updateSetMembership(e,g,!1)&&notifyListeners()},forgetAllyPlayer=e=>{const g=V(e);updateSetMembership(t,g,!1)&&notifyListeners()},rememberCityEnemyPlayer=e=>{const t=V(e);updateSetMembership(g,t,!0)&&notifyListeners()},isEnemyPlayerByNormalizedName=t=>e.has(t),isAllyPlayerByNormalizedName=e=>t.has(e),isCityEnemyPlayerByNormalizedName=e=>g.has(e),isEnemyPlayer=e=>isEnemyPlayerByNormalizedName(V(e)),isAllyPlayer=e=>isAllyPlayerByNormalizedName(V(e)),isCityEnemyPlayer=e=>isCityEnemyPlayerByNormalizedName(V(e)),replaceEnemyPlayers=g=>{const n=normalizeNames(g);let C=replaceSetContents(e,[...n]);n.forEach(e=>{C=updateSetMembership(t,e,!1)||C}),C&&notifyListeners()},replaceAllyPlayers=g=>{const n=normalizeNames(g);let C=replaceSetContents(t,[...n]);n.forEach(t=>{C=updateSetMembership(e,t,!1)||C}),C&&notifyListeners()},replaceCityEnemyPlayers=e=>{replaceSetContents(g,e)&&notifyListeners()},trackRelationshipCommand=e=>{if(!isNonEmptyString(e))return;const t=e.trim(),g=t.match(/^enemy\s+(.+)$/i);if(g)return void rememberEnemyPlayer(g[1]);const n=t.match(/^ally\s+(.+)$/i);if(n)return void rememberAllyPlayer(n[1]);const C=t.match(/^city enemy\s+(.+)$/i);C&&rememberCityEnemyPlayer(C[1])},resetPlayerRelationships=()=>{e.clear(),t.clear(),g.clear(),notifyListeners()},destroy=()=>{e.clear(),t.clear(),g.clear(),n.clear()};return Object.freeze({forgetAllyPlayer,forgetEnemyPlayer,getVersion:()=>C,isAllyPlayer,isAllyPlayerByNormalizedName,isCityEnemyPlayer,isCityEnemyPlayerByNormalizedName,isEnemyPlayer,isEnemyPlayerByNormalizedName,rememberAllyPlayer,rememberCityEnemyPlayer,rememberEnemyPlayer,replaceAllyPlayers,replaceCityEnemyPlayers,replaceEnemyPlayers,resetPlayerRelationships,subscribePlayerRelationships,trackRelationshipCommand,destroy})},oe=createPlayerRelationshipsModel(),getDefaultPlayerRelationshipsModel=()=>oe,Ie=25,cloneDiagnosticValue=e=>Array.isArray(e)?e.map(e=>cloneDiagnosticValue(e)):isPlainObject$1(e)?Object.fromEntries(Object.entries(e).map(([e,t])=>[e,cloneDiagnosticValue(t)])):e,toPublicEntry=({_signature:e,...t})=>cloneDiagnosticValue(t),buildSignature=({channel:e,action:t,status:g,name:n=null,detail:C=null})=>JSON.stringify([e,t,g,n,C]),createPlayerDirectoryDiagnosticsModel=({historyLimit:e=Ie,now:t=()=>0}={})=>{let g=[],n={};const recordPlayerDirectoryDiagnostic2=({channel:C,action:o,status:I,name:a=null,detail:i=null})=>{const s=buildSignature({channel:C,action:o,status:I,name:a,detail:i}),l=t(),c=g.at(-1);if(c?._signature===s)return c.at=l,c.count+=1,void(n[C]=toPublicEntry(c));g.push({at:l,channel:C,action:o,status:I,...a?{name:a}:{},...null==i?{}:{detail:cloneDiagnosticValue(i)},count:1,_signature:s}),g.length>e&&g.splice(0,g.length-e),n[C]=toPublicEntry(g.at(-1))},getPlayerDirectoryDiagnosticsSnapshot=()=>({latest:cloneDiagnosticValue(n),history:g.map(e=>toPublicEntry(e))}),resetPlayerDirectoryDiagnostics=()=>{g=[],n={}};return Object.freeze({getPlayerDirectoryDiagnosticsSnapshot,recordPlayerDirectoryDiagnostic:recordPlayerDirectoryDiagnostic2,resetPlayerDirectoryDiagnostics,destroy:resetPlayerDirectoryDiagnostics})},ae=createPlayerDirectoryDiagnosticsModel(),getDefaultPlayerDirectoryDiagnosticsModel=()=>ae,recordPlayerDirectoryDiagnostic=e=>ae.recordPlayerDirectoryDiagnostic(e),ie=Object.freeze({DISABLED:"disabled",OK:"ok",UNAVAILABLE:"unavailable",REJECTED:"rejected"}),httpStatusToRemoteStatus=e=>401===e||403===e?ie.REJECTED:e>=500||0===e?ie.UNAVAILABLE:e>=200&&e<300?ie.OK:ie.UNAVAILABLE,createNullRemotePlayerService=()=>({checkAvailability:async()=>ie.DISABLED,hydrateDirectory:async()=>({ok:!1,remoteStatus:ie.DISABLED}),upsertProfile:async()=>({ok:!1,remoteStatus:ie.DISABLED}),deleteProfile:async()=>({ok:!1,remoteStatus:ie.DISABLED})}),createLambdaRemotePlayerService=({apiUrl:e,apiKey:t="",fetchFn:g=null}={})=>{if("string"!=typeof e||!e.trim())return createNullRemotePlayerService();const n=e.trim(),C="function"==typeof g?g:null,call=async({method:e,params:g={},body:o})=>{const I=new URLSearchParams;for(const[t,n]of Object.entries(g))"filter"===t&&null!==n&&"object"==typeof n?I.set(t,JSON.stringify(n)):void 0!==n&&I.set(t,String(n));const a=I.toString()?`${n}?${I}`:n,i={"Content-Type":"application/json"};t&&(i["x-api-key"]=t);const s={method:e,headers:i};void 0!==o&&(s.body=JSON.stringify(o));const l=await C(a,s);return{status:l.status,ok:l.ok,response:l}};return{checkAvailability:async()=>{if("function"!=typeof C)return ie.UNAVAILABLE;try{const{status:e}=await call({method:"GET",params:{check:"auth"}});return httpStatusToRemoteStatus(e)}catch{return ie.UNAVAILABLE}},hydrateDirectory:async()=>{if("function"!=typeof C)return{ok:!1,remoteStatus:ie.UNAVAILABLE};try{const{status:e,ok:t,response:g}=await call({method:"GET",params:{name:"ALL",collection:"characters"}}),n=httpStatusToRemoteStatus(e);if(!t)return{ok:!1,remoteStatus:n};const C=await g.json();return{ok:!0,entries:Array.isArray(C)?C:[],remoteStatus:ie.OK}}catch{return{ok:!1,remoteStatus:ie.UNAVAILABLE}}},upsertProfile:async e=>{if("function"!=typeof C)return{ok:!1,remoteStatus:ie.UNAVAILABLE};try{const{status:t,ok:g}=await call({method:"POST",params:{collection:"characters"},body:{data:e}});return{ok:g,remoteStatus:httpStatusToRemoteStatus(t)}}catch{return{ok:!1,remoteStatus:ie.UNAVAILABLE}}},deleteProfile:async e=>{if("function"!=typeof C)return{ok:!1,remoteStatus:ie.UNAVAILABLE};try{const{status:t,ok:g}=await call({method:"DELETE",params:{name:e,collection:"characters"}});return{ok:g,remoteStatus:httpStatusToRemoteStatus(t)}}catch{return{ok:!1,remoteStatus:ie.UNAVAILABLE}}}}},joinFontFamily=(...e)=>e.join(", "),se=joinFontFamily('"Roboto Mono"',"Consolas","monospace"),le=14,ce=Object.freeze([Object.freeze({label:"Roboto Mono",value:se}),Object.freeze({label:"Consolas",value:joinFontFamily("Consolas","Monaco","monospace")}),Object.freeze({label:"JetBrains Mono",value:joinFontFamily('"JetBrains Mono"',"Consolas","monospace")}),Object.freeze({label:"Fira Code",value:joinFontFamily('"Fira Code"',"Consolas","monospace")}),Object.freeze({label:"Source Code Pro",value:joinFontFamily('"Source Code Pro"',"Consolas","monospace")}),Object.freeze({label:"Courier New",value:joinFontFamily('"Courier New"',"monospace")})]),normalizeDisplayFontFamily=e=>"string"!=typeof e?se:e.trim()||se,normalizeDisplayFontSize=(e,t=le)=>{if("number"==typeof e&&Number.isFinite(e)&&e>0)return Math.round(e);if("string"==typeof e){const t=Number.parseFloat(e);if(Number.isFinite(t)&&t>0)return Math.round(t)}return t},readHostDisplayFontFamily=(e={})=>{const t="function"==typeof e?.get_font_family?e.get_font_family():e?.font_family;return normalizeDisplayFontFamily(t)},readHostDisplayFontSize=(e={})=>normalizeDisplayFontSize(e?.font_size),ue=1,clonePersistenceValue=e=>Array.isArray(e)?e.map(e=>clonePersistenceValue(e)):isPlainObject$1(e)?Object.fromEntries(Object.entries(e).map(([e,t])=>[e,clonePersistenceValue(t)])):e,normalizeLeafValue=(e,t)=>"boolean"==typeof e?"boolean"==typeof t?t:e:"number"==typeof e?"number"==typeof t&&Number.isFinite(t)?t:e:"string"==typeof e?"string"==typeof t?t:e:clonePersistenceValue(e),applySchemaPatch=(e,t,g)=>{if(isPlainObject$1(g))for(const n of Object.keys(e)){if("version"===n||!Object.hasOwn(g,n))continue;const C=e[n],o=g[n];Array.isArray(C)?t[n]=Array.isArray(o)?clonePersistenceValue(o):clonePersistenceValue(C):isPlainObject$1(C)?applySchemaPatch(C,t[n],o):t[n]=normalizeLeafValue(C,o)}},createSchemaSnapshot=(e,...t)=>{const g=clonePersistenceValue(e);for(const n of t)applySchemaPatch(e,g,n);return Object.hasOwn(e,"version")&&(g.version=e.version),g},de="nexGui4Settings",pe=Object.freeze({SETTINGS:"settings",GAME_STATS:"gameStats",UI:"ui",PLAYER_DIRECTORY:"playerDirectory"}),me=deepFreeze({version:ue,theme:{backgroundImage:"",fontSize:12,displayFontFamily:se,displayFontSize:le,backgroundOpacity:.5,hue:0},ui:{loginTracker:!1,msgReplace:!1,showCombatStream:!1,showSystemStream:!1,logoutDownload:!1,virtualizedLogs:!1,allyEnemyFormatting:!0,targetFormatting:!0,damageNumbers:!0,nativeDisplay:!1},party:{goldCollection:!0,targetCalls:!0,affCalls:!0,callTargets:!1,callAffs:!1,gagChat:!1}}),fe=deepFreeze({version:ue,kills:0,month:{deaths:0,goldCap:0,month:0,startingGold:0,startingKills:0,startingXp:0,currentXp:0,xpValue:0,year:0}}),he=deepFreeze({version:ue,scrollbackModal:{width:600,height:400,x:0,y:0}}),normalizePersistenceFragment=(e,t)=>Array.isArray(e)?Array.isArray(t)?clonePersistenceValue(t):clonePersistenceValue(e):isPlainObject$1(e)?createSchemaSnapshot(e,t):normalizeLeafValue(e,t),migrateSettingsPersistence=e=>createSchemaSnapshot(me,e),migrateGameStatsPersistence=e=>createSchemaSnapshot(fe,e),migrateUiPersistence=e=>createSchemaSnapshot(he,e),ye="function"==typeof queueMicrotask?queueMicrotask:e=>Promise.resolve().then(e),resolvePlayerDirectory$1=e=>e??getDefaultPlayerDirectoryModel(),resolveDiagnostics=e=>e??getDefaultPlayerDirectoryDiagnosticsModel(),resolveCacheReader=(e,t)=>"function"==typeof e?e:"function"==typeof e?.readCache?e.readCache.bind(e):"function"==typeof e?.getVariable?t=>(e.getVariable(de)||{})[pe.PLAYER_DIRECTORY]:"function"==typeof t?t:null,resolveCacheWriter=(e,t)=>"function"==typeof e?e:"function"==typeof e?.writeCache?e.writeCache.bind(e):"function"==typeof e?.setVariable?(t,g)=>{const n=e.getVariable(de)||{};n[pe.PLAYER_DIRECTORY]=g,e.setVariable(de,n)}:"function"==typeof t?t:null,parseStoredSnapshot=e=>Array.isArray(e)?e:null,createSnapshotSaver=(e,t)=>g=>{if("function"!=typeof g)return;const n=e.getAllPlayerProfiles().filter(e=>e.loaded&&(e.city||e.fullname));g(t,n)},createPlayerDirectoryLifecycle=({playerDirectory:e,diagnostics:t,readCache:g,writeCache:n,storageKey:C=pe.PLAYER_DIRECTORY}={})=>{const o=resolvePlayerDirectory$1(e),I=resolveDiagnostics(t),a=createSnapshotSaver(o,C);let i=!1,s=null,l=!1,c=!1;const recordDiagnostic=e=>I.recordPlayerDirectoryDiagnostic(e),isDirectorySeeded2=()=>i,resetSeededFlag=()=>{i=!1},warmDirectoryFromCache=e=>{const t=resolveCacheReader(e,g);try{const e=t?.(C),g=parseStoredSnapshot(e);null!==g&&g.length>0&&o.hydrateFromCacheEntries(g)}catch{}finally{i=!0}},saveDirectorySnapshot=e=>{a(resolveCacheWriter(e,n))},subscribePersistence=e=>{const t=resolveCacheWriter(e,n);if(s?.(),s=null,l=!1,c=!0,"function"!=typeof t||"function"!=typeof o.subscribePlayerDirectory)return()=>{};const scheduleSave=()=>{c&&!l&&(l=!0,ye(()=>{l=!1,c&&saveDirectorySnapshot(t)}))};return s=o.subscribePlayerDirectory(scheduleSave),()=>{c=!1,s?.(),s=null}},refreshDirectoryFromRemote=async(e,t)=>{try{const g=await e.hydrateDirectory(),n=Array.isArray(g?.entries)?g.entries.length:0;recordDiagnostic({channel:"remote",action:"hydrateDirectory",status:g?.remoteStatus??ie.UNAVAILABLE,detail:{ok:!0===g?.ok,entryCount:n}}),g.ok&&Array.isArray(g.entries)&&g.entries.length>0&&(o.hydrateFromRemoteEntries(g.entries),saveDirectorySnapshot(t))}catch{recordDiagnostic({channel:"remote",action:"hydrateDirectory",status:ie.UNAVAILABLE,detail:{ok:!1,exception:!0}})}},reset=()=>{i=!1,l=!1,c=!1,s?.(),s=null,I.resetPlayerDirectoryDiagnostics?.()};return Object.freeze({destroy:reset,isDirectorySeeded:isDirectorySeeded2,refreshDirectoryFromRemote,reset,resetSeededFlag,saveDirectorySnapshot,subscribePersistence,warmDirectoryFromCache})},be=createPlayerDirectoryLifecycle(),isDirectorySeeded=()=>be.isDirectorySeeded(),ACHAEA_CHARACTER_URL=e=>`https://api.achaea.com/characters/${e.toLowerCase()}.json`,ve=Object.freeze({OK:"ok",AUTHORITATIVE_FAILURE:"authoritative_failure",TRANSIENT_FAILURE:"transient_failure"}),fetchPublicProfileForSync=async(e,{fetchFn:t=null}={})=>{if("function"!=typeof t)return{outcome:ve.TRANSIENT_FAILURE,data:null};try{const g=await t(ACHAEA_CHARACTER_URL(e),{method:"GET",cache:"no-store"});if(!g.ok)return{outcome:g.status>=500?ve.TRANSIENT_FAILURE:ve.AUTHORITATIVE_FAILURE,data:null};const n=await g.json();return{outcome:ve.OK,data:n}}catch{return{outcome:ve.TRANSIENT_FAILURE,data:null}}},normalizeCrowdsourceCity=(e,t,{getPlayerProfile:g=getPlayerProfile}={})=>{if("Romeo"===t||"Juliet"===t)return"garden";const n="string"==typeof e?.city?e.city:"";if(""===n)return"garden";if("(hidden)"===n.toLowerCase()){const e=g(t),n=e?.city??"";return n&&"(hidden)"!==n?n:"(none)"}return n},createCrowdsourceSyncHandler=({remoteService:e,getSelfName:t=()=>null,getPlayerProfile:g=getPlayerProfile,isSeeded:n=isDirectorySeeded,recordDiagnostic:C=recordPlayerDirectoryDiagnostic,fetchFn:o=null,fetchProfileForSync:I=e=>fetchPublicProfileForSync(e,{fetchFn:o}),maxConcurrent:a=3})=>{let i=[];const s=new Set,l=[],processOneName=async n=>{const o=t();if(o&&n===o)return;const{outcome:a,data:i}=await I(n);if(a===ve.OK&&i){const t=normalizeCrowdsourceCity(i,n,{getPlayerProfile:g}),I={...i,city:t};o&&(I.user=o);const a=await e.upsertProfile(I);return void(a?.ok||C({channel:"crowdsource",action:"upsertProfile",status:a?.remoteStatus??"unavailable",name:n}))}if(a===ve.AUTHORITATIVE_FAILURE){C({channel:"crowdsource",action:"publicProfileFetch",status:ve.AUTHORITATIVE_FAILURE,name:n});const t=await e.deleteProfile(n);return void C({channel:"crowdsource",action:"deleteProfile",status:t?.remoteStatus??"unavailable",name:n,detail:{ok:!0===t?.ok}})}C({channel:"crowdsource",action:"publicProfileFetch",status:ve.TRANSIENT_FAILURE,name:n})},drainQueue=()=>{for(;s.size<a&&l.length>0;){const e=l.shift();e&&!s.has(e)&&(s.add(e),processOneName(e).finally(()=>{s.delete(e),drainQueue()}))}},enqueue=e=>{for(const t of e)s.has(t)||l.includes(t)||l.push(t);drainQueue()};return e=>{if(!n())return;if(!Array.isArray(e))return;const t=e.map(e=>"string"==typeof e?.name?e.name.trim():"").filter(Boolean),g=t.filter(e=>!i.includes(e));i=[...t],g.length>0&&enqueue(g)}},isPresent=e=>null!=e&&String(e).length>0,classAttribute=e=>isPresent(e)?` class="${escapeHtml(e)}"`:"",styleAttribute$1=(e={})=>{const t=Object.entries(e??{}).filter(([,e])=>isPresent(e)).map(([e,t])=>`${escapeHtml(e)}:${escapeHtml(t)}`).join(";");return t?` style="${t};"`:""},titleAttribute=e=>isPresent(e)?` title="${escapeHtml(e)}"`:"",span=(e,{className:t=null,style:g=null}={})=>`<span${classAttribute(t)}${styleAttribute$1(g)}>${e}</span>`,textNode=e=>({kind:"text",text:e}),classTextNode=(e,t)=>({kind:"class-text",className:e,text:t}),styledTextNode=(e,{className:t=null,fg:g=null,bg:n=null}={})=>({kind:"styled-text",className:t,text:e,fg:g,bg:n}),relationshipNameNode=e=>({kind:"relationship-name",descriptor:e}),iconBandingNode=({icon:e,colors:t,size:g,children:n})=>({kind:"icon-banding",icon:e,colors:t,size:g,children:n}),xe=Object.freeze({className:"ng-target-format",borderColor:"rgb(255, 0, 0)",boxShadow:"inset 0 0 0 1px rgb(255, 0, 0)",padding:"0 2px"}),Se=Object.freeze({ally:Object.freeze({className:"ng-brkt ng-brkt-ally",color:"#ffffff",open:"(",close:")"}),enemy:Object.freeze({className:"ng-brkt ng-brkt-enemy",color:"#ff0000",open:"(",close:")"})}),createRelationshipNameDescriptor=(e,t={})=>{if(!isNonEmptyString(e))return null;const g={family:"inline-name",text:e.trim(),color:t.color??"grey",italic:Boolean(t.isCityEnemy),target:Boolean(t.isTarget),bracket:null,targetStyle:xe};return t.isAlly?g.bracket=Se.ally:t.isEnemy&&(g.bracket=Se.enemy),g},createPlayerRelationshipDescriptor=(e,t={})=>{if(!isNonEmptyString(e))return null;const g=e.trim(),n=isNonEmptyString(t.targetName)?t.targetName.trim():"",C=Boolean(t.isAlly),o=Boolean(t.isEnemy),I=Boolean(t.isCityEnemy),a=t.isTarget??(!1!==t.targetFormatting&&n.length>0&&n===g);return createRelationshipNameDescriptor(g,{color:t.color??"grey",isAlly:C,isEnemy:o,isCityEnemy:I,isTarget:a})},renderBracket=(e,t)=>`<span class="${e.className}"${styleAttribute$1({color:e.color,"font-weight":"bold"})}>${escapeHtml(t)}</span>`,renderRelationshipNameHtml=e=>{if(!e)return"";const t=`<span${styleAttribute$1({color:e.color,"font-style":e.italic?"italic":null})}>${escapeHtml(e.text)}</span>`,g=e.bracket?[renderBracket(e.bracket,e.bracket.open),t,renderBracket(e.bracket,e.bracket.close)].join(""):t;return e.target?`<span class="${e.targetStyle.className}"${styleAttribute$1({"box-shadow":e.targetStyle.boxShadow??`inset 0 0 0 1px ${e.targetStyle.borderColor}`,padding:e.targetStyle.padding})}>${g}</span>`:g},we=Object.freeze({original:" ".repeat(8),adjusted:" ".repeat(6)}),Ee=new WeakMap,isAsciiUppercase=e=>{if("string"!=typeof e||0===e.length)return!1;const t=e.charCodeAt(0);return t>=65&&t<=90},isNameCharacter=e=>{if("string"!=typeof e||0===e.length)return!1;if("'"===e||"-"===e)return!0;const t=e.charCodeAt(0);return t>=65&&t<=90||t>=97&&t<=122},extractUniqueWords=e=>{const t="string"==typeof e?e.match(/[A-Z][A-Za-z'-]*/g):null;return t?[...new Set(t)]:[]},resolveDescriptorFactory=({createDescriptor:e,relationshipFormatter:t}={})=>"function"==typeof e?e:"function"==typeof t?t:"function"==typeof t?.createDescriptor?t.createDescriptor:null,resolveCompiledHighlighter=e=>{const t=e?.compiledHighlighter;return t&&Array.isArray(t.namesByLength)&&t.entries instanceof Map&&0!==t.entries.size?t:null},getCompiledInitialCharacters=e=>{const t=Ee.get(e);if(t)return t;const g=new Set;return e.entries.forEach((e,t)=>{"string"==typeof t&&t.length>0&&g.add(t.charAt(0))}),Ee.set(e,g),g},hasPotentialCompiledMatch=(e,t)=>{if("string"!=typeof e||0===e.length)return!1;const g=getCompiledInitialCharacters(t);for(let n=0;n<e.length;n+=1)if(g.has(e.charAt(n)))return!0;return!1},applyCompiledHighlighting=(e,t,g)=>{const n=e.text();if(!hasPotentialCompiledMatch(n,t))return!1;const C=e.formatted();if("string"!=typeof C||0===C.length)return!1;let o=0,I=0,a=null,i=!1;for(;o<C.length;){const e=C.charAt(o);if("<"===e){const e=C.indexOf(">",o+1);if(-1===e)break;o=e+1;continue}if(!isAsciiUppercase(e)){o+=1;continue}let n=o+1;for(;n<C.length&&isNameCharacter(C.charAt(n));)n+=1;const s=C.slice(o,n),l=t.entries.get(s);l?(null===a?a=[C.slice(0,o)]:a.push(C.slice(I,o)),a.push(l.html),I=n,o=n,g&&l.adjustsMonospacePadding&&(i=!0)):o=n}if(null===a)return!1;let s=a.join("")+C.slice(I);return i&&(s=s.replace(we.original,we.adjusted)),e.formatted=()=>s,!0},buildReplacementMapFromDescriptors=(e,t)=>{const g=new Map;return e.forEach(e=>{const n=t(e);n&&"grey"!==n.color&&g.set(e,{html:renderRelationshipNameHtml(n),bracketed:Boolean(n.bracket),adjustsMonospacePadding:Boolean(n.bracket)})}),g},applyInlineNameHighlighting=(e,{createDescriptor:t,relationshipFormatter:g,monospace:n=!1}={})=>{if(!e||e.nexSkillReplacement||"function"!=typeof e.text||"function"!=typeof e.formatted)return!1;const C=resolveCompiledHighlighter(g);if(C)return applyCompiledHighlighting(e,C,n);const o=resolveDescriptorFactory({createDescriptor:t,relationshipFormatter:g});if(!o)return!1;const I=extractUniqueWords(e.text()),a=buildReplacementMapFromDescriptors(I,o);if(0===a.size)return!1;const i=e.formatted();if("string"!=typeof i||0===i.length)return!1;let s=i,l=!1;for(const c of[...a.keys()].sort((e,t)=>t.length-e.length)){const e=a.get(c);e&&s.includes(c)&&(s=s.split(c).join(e.html),n&&e.adjustsMonospacePadding&&(s=s.replace(we.original,we.adjusted)),l=!0)}return!!l&&(e.formatted=()=>s,!0)},sortNamesByLengthDesc=(e,t)=>t.length-e.length,normalizeKnownNames=e=>{if(!Array.isArray(e))return[];const t=new Set,g=[];return e.forEach(e=>{const n=V(e);n&&!t.has(n)&&(t.add(n),g.push(n))}),g},createCompiledInlineHighlighter=({knownNames:e=[],createDescriptor:t}={})=>{const g=new Map,n=normalizeKnownNames(e);return"function"!=typeof t||0===n.length?Object.freeze({namesByLength:Object.freeze([]),entries:g}):(n.forEach(e=>{const n=t(e);n&&"grey"!==n.color&&g.set(e,Object.freeze({html:renderRelationshipNameHtml(n),bracketed:Boolean(n.bracket),adjustsMonospacePadding:Boolean(n.bracket)}))}),Object.freeze({namesByLength:Object.freeze(n.filter(e=>g.has(e)).sort(sortNamesByLengthDesc)),entries:g}))},callPredicate=(e,t)=>{if("function"!=typeof e)return!1;try{return Boolean(e(t))}catch{return!1}},callColorResolver=(e,t)=>{if("function"!=typeof e)return"grey";try{return e(t)??"grey"}catch{return"grey"}},readKnownNames=e=>{if(Array.isArray(e))return e;if("function"!=typeof e)return[];try{const t=e();return Array.isArray(t)?t:[]}catch{return[]}},createRelationshipNameFormatter=(e={})=>{const t=V(e.targetName),g=!1!==e.allyEnemyFormatting,n=!1!==e.targetFormatting,C=e.getPlayerColorByNormalizedName??e.getPlayerColor,o=e.isAllyPlayerByNormalizedName??e.isAllyPlayer,I=e.isEnemyPlayerByNormalizedName??e.isEnemyPlayer,a=e.isCityEnemyPlayerByNormalizedName??e.isCityEnemyPlayer,i=Array.isArray(e.knownPlayerNames)||"function"==typeof e.getKnownPlayerNames,s=readKnownNames(e.knownPlayerNames??e.getKnownPlayerNames),l=new Set(s.map(V).filter(Boolean)),createDescriptor=(e,s={})=>{const c=V(e),u=V(s.text)||c;if(!c||!u)return null;const d=s.isAlly??(g&&callPredicate(o,c)),p=s.isEnemy??callPredicate(I,c),m=s.isCityEnemy??callPredicate(a,c),h=s.isTarget??(n&&(!i||l.has(c))&&t.length>0&&t===c);return createPlayerRelationshipDescriptor(u,{color:s.color??callColorResolver(C,c),isAlly:d,isEnemy:p,isCityEnemy:m,isTarget:h})},c=createCompiledInlineHighlighter({knownNames:s,createDescriptor});return Object.freeze({compiledHighlighter:c,createDescriptor,renderHtml:(e,t={})=>renderRelationshipNameHtml(createDescriptor(e,t))})},getUiSettings$3=e=>e?.persistenceStore?.getAll?.()?.ui??{},getCharacterState$2=e=>e?.stores?.character?.getState?.()??{},Re=Object.freeze(["allyEnemyFormatting","targetFormatting","targetName","playerDirectory","playerDirectoryVersion","playerRelationships","playerRelationshipsVersion"]);let ke=new WeakMap,Me=null;const readModelVersion=e=>{if("function"!=typeof e?.getVersion)return null;try{return e.getVersion()}catch{return null}},createFormatterSignature=(e,t={})=>{const g=getUiSettings$3(e),n=getCharacterState$2(e),C=t.playerDirectory??e?.playerDirectory??null,o=t.playerRelationships??e?.playerRelationships??null;return{allyEnemyFormatting:!1!==g.allyEnemyFormatting,targetFormatting:!1!==g.targetFormatting,targetName:V(t.targetName??n.target??null),playerDirectory:C,playerDirectoryVersion:readModelVersion(C),playerRelationships:o,playerRelationshipsVersion:readModelVersion(o)}},signaturesEqual$1=(e,t)=>null!==e&&null!==t&&Re.every(g=>Object.is(e[g],t[g])),readCachedFormatter=e=>e&&"object"==typeof e?ke.get(e)??null:Me,writeCachedFormatter=(e,t)=>e&&"object"==typeof e?(ke.set(e,t),t):(Me=t,t),createFormatterFromSignature=e=>{const{playerDirectory:t,playerRelationships:g}=e;return createRelationshipNameFormatter({allyEnemyFormatting:e.allyEnemyFormatting,targetFormatting:e.targetFormatting,targetName:e.targetName,getKnownPlayerNames:t?.getKnownPlayerNames?.bind(t),getPlayerColor:t?.getPlayerColor?.bind(t),getPlayerColorByNormalizedName:t?.getPlayerColorByNormalizedName?.bind(t),isAllyPlayer:g?.isAllyPlayer?.bind(g),isAllyPlayerByNormalizedName:g?.isAllyPlayerByNormalizedName?.bind(g),isEnemyPlayer:g?.isEnemyPlayer?.bind(g),isEnemyPlayerByNormalizedName:g?.isEnemyPlayerByNormalizedName?.bind(g),isCityEnemyPlayer:g?.isCityEnemyPlayer?.bind(g),isCityEnemyPlayerByNormalizedName:g?.isCityEnemyPlayerByNormalizedName?.bind(g)})},clearRelationshipNameFormatterCache=e=>{e&&"object"==typeof e?ke.delete(e):(void 0===e&&(ke=new WeakMap),Me=null)},createRelationshipNameFormatterFromContext=(e,t={})=>{const g=createFormatterSignature(e,t),n=readCachedFormatter(e);if(signaturesEqual$1(n?.signature??null,g))return n.formatter;const C=createFormatterFromSignature(g);return writeCachedFormatter(e,{signature:g,formatter:C}),C},applyContextInlineNameHighlighting=(e,{contextValue:t=null,monospace:g=!1}={})=>applyInlineNameHighlighting(e,{relationshipFormatter:createRelationshipNameFormatterFromContext(t),monospace:g}),highlightInlineNamesInText=(e,{contextValue:t=null}={})=>{const g={text:()=>e,formatted:()=>e};return applyContextInlineNameHighlighting(g,{contextValue:t})?{content:g.formatted(),isHtml:!0}:{content:e,isHtml:void 0}},Te=deepFreeze([["a CRITICAL","2x"],["CRUSHING","4x"],["OBLITERATING","8x"],["ANNIHILATINGLY","16x"],["WORLD","32x"],["PLANE","64x"],["coalescence of power","MAYA"]]),Pe=deepFreeze({"physical cutting":"#708090","physical blunt":"#708090",magical:"#FFFFFF",poison:"#9ACD32",psychic:"#663399",fire:"#8B0000",cold:"#87CEFA",electricity:"#FFD700",asphyxiation:"#D2B48C",raw:"#FFB6C1",unblockable:"#FFB6C1"}),Ne=deepFreeze({attack:"orange",battlerage:"yellow",affliction:"red"}),Oe=deepFreeze({attainment:"yellow",gear:"plum"}),De=deepFreeze({eat:{id:"eat",fg:"gold",text:"Eat: ",banding:["{","}"]},smoke:{id:"smoke",fg:"orchid",text:"Smoke: ",banding:["{","}"]},apply:{id:"apply",fg:"aquamarine",text:"Apply: ",banding:["{","}"]},sip:{id:"sip",fg:"HotPink",text:"Sip: ",banding:["{","}"]},focus:{id:"focus",fg:"BlueViolet",text:"Focus",banding:["{","}"]},tattoo:{id:"tattoo",fg:"cornflowerBlue",text:"Tattoo: ",banding:["||","||"]},shield:{id:"shield",fg:"cyan",text:" Shield ",banding:{icon:"shield-cross",colors:["cyan","goldenrod"],size:16}},rebounding:{id:"rebounding",fg:"white",text:" Rebounding ",banding:{icon:"shield-cross",colors:["white","goldenrod"],size:16}},prismatic:{id:"prismatic",fg:"yellow",text:" Prismatic ",banding:{icon:"shield-cross",colors:["goldenrod","white"],size:16}},tree:{id:"tree",fg:"lawngreen",text:" Tree ",banding:{icon:"tree",colors:["green","brown"],size:16}},npcslain:{id:"npcslain",fg:"red",text:" SLAIN ",banding:{icon:"tombstone",colors:["grey","white"],size:18}}}),je=deepFreeze({id:"default",fg:"grey",text:"Action",bg:"",banding:["[","]"]}),toDamageSlug$1=e=>e.toLowerCase().replace(/\s+/g,"-"),getSkillColor=e=>Oe[e]??"orange",getSkillClass=e=>e&&Oe[e]?`ng-skill-${e}`:"ng-skill-default",getUserActionDefinition=e=>De[e]??{...je,id:e},getUserActionClass=e=>e&&De[e]?`ng-action-${e}`:"ng-action-default",getDamageClass=e=>e&&void 0!==Pe[e]?`ng-dmg-${toDamageSlug$1(e)}`:"ng-dmg-unknown",hpPercentToColor=e=>{if(null==e||!Number.isFinite(e))return"grey";const t=Math.max(0,Math.min(100,e)),g=1.2*t,n=(t<75?50:Math.abs(t-100)/2+25)/100,k=e=>(e+g/30)%12,C=1*Math.min(n,1-n),f=e=>n-C*Math.max(-1,Math.min(k(e)-3,Math.min(9-k(e),1))),toHex=e=>Math.round(255*e).toString(16).padStart(2,"0");return`#${toHex(f(0))}${toHex(f(8))}${toHex(f(4))}`},ze="You",createSegment=(e,t=null,g=!1)=>({text:e,fg:t,bg:null,bold:g}),resolvePatternLength$1=e=>{const t=trimToEmpty(e?.matchType),g=e?.patterns?.[t];return Array.isArray(g)?g.length:0},createNameDescriptor=(e,{relationshipFormatter:t,selfName:g,selfText:n,targetName:C})=>{const o=trimToEmpty(e);return o?"self"===o||g&&o===g?createRelationshipNameDescriptor(n,{color:"lightpink",isTarget:C===o}):"function"==typeof t?.createDescriptor?t.createDescriptor(o,{text:toDisplayName(o)}):createRelationshipNameDescriptor(toDisplayName(o),{color:"grey",isAlly:!1,isEnemy:!1,isCityEnemy:!1,isTarget:C===o}):null},createPreviewSegments=({actor:e,actionLabel:t,actionColor:g,target:n,info:C})=>{const o=[];if(e){const t=e.bracket?`${e.bracket.open}${e.text}${e.bracket.close}`:e.text;o.push(createSegment(t,e.color)),o.push(createSegment(" "))}if(isNonEmptyString(t)&&o.push(createSegment(t.trim(),g,!0)),n){o.push(createSegment(" "));const e=n.bracket?`${n.bracket.open}${n.text}${n.bracket.close}`:n.text;o.push(createSegment(e,n.color))}return isNonEmptyString(C)&&(o.push(createSegment(" ")),o.push(createSegment(`[${toDisplayName(C)}]`,"cadetblue"))),o},createReplacementDescriptor=(e,t,g={})=>{if("nexSkillMatch"!==e&&"nexSkillNpcMatch"!==e)return null;if(!t||"object"!=typeof t||Array.isArray(t))return null;const n=trimToEmpty(g.selfName),C=trimToEmpty(g.selfText)||ze,o=trimToEmpty(g.targetName),I=g.relationshipFormatter,a="nexSkillNpcMatch"===e?"npc":"user",i="user"===a?getUserActionDefinition(t.id):null,s=createNameDescriptor(t.user,{relationshipFormatter:I,selfName:n,selfText:C,targetName:o}),l=createNameDescriptor(t.target,{relationshipFormatter:I,selfName:n,selfText:C,targetName:o}),c=trimToEmpty(t.fullName)||toDisplayName(t.skill||t.id),u="npc"===a?Array.isArray(t.tags)&&t.tags.length>0?t.tags.map(toDisplayName).join(", "):c:trimToEmpty(i?.text)||c,d="npc"===a?"red":i?.fg??getSkillColor(t.skill),p=createPreviewSegments({actor:s,actionLabel:u,actionColor:d,target:l,info:t.info}),m=p.map(e=>e.text).join(""),h=Math.max(resolvePatternLength$1(t)-1,0);return{family:"skill",eventName:e,buffer:"combat",variant:a,id:trimToEmpty(t.id),matchType:trimToEmpty(t.matchType),skill:{id:trimToEmpty(t.skill),name:c,color:getSkillColor(t.skill)},actor:s,target:l,tags:Array.isArray(t.tags)?t.tags.map(trimToEmpty).filter(Boolean):[],info:isNonEmptyString(t.info)?t.info.trim():null,userAction:i,hostMutation:{replaceCurrentLine:!0,companionLineCount:h,tooltipSource:"npc"===a&&Array.isArray(t.tags)&&t.tags.includes("damage")&&"self"===t.target?"health-lost":null},preview:{tag:"npc"===a?"«npc»":"[act]",tagColor:d,text:m,segments:p},metadata:{actionTypeColors:Ne,critLabels:Te,damageColors:Pe}}},Le=Object.freeze({fg:null,bg:null,bold:!1}),createPlainSegment=e=>({text:e,...Le}),extractName=e=>extractNamedValue(e),createStructuredLine=(e,t,g,n,C,o={})=>({type:"combat"===C?"combat":"system",buffer:C,segments:[createPlainSegment(n)],metadata:{event:e,tag:t,tagColor:g,details:o}}),pickDefined=(e,t=null)=>void 0===e?t:e,resolveSkillReplacementDetails=(e,t)=>{if(!isPlainObject$1(t))return null;const g=isPlainObject$1(t.sourcePayload)?t.sourcePayload:t,n=isPlainObject$1(t.replacement)?t.replacement:createReplacementDescriptor(e,g);return n?{replacement:n,context:t.context??t.replacementContext,crit:pickDefined(t.crit),damage:pickDefined(t.damage),healthLost:Array.isArray(t.healthLost)?t.healthLost:[],tooltip:pickDefined(t.tooltip),originalLine:pickDefined(t.originalLine),matchType:"string"==typeof t.matchType?t.matchType:n.matchType,actorId:"string"==typeof t.actorId?t.actorId:"string"==typeof g.user?g.user.trim():null,targetHpText:pickDefined(t.targetHpText),targetHpPercent:pickDefined(t.targetHpPercent),hpDeltaText:pickDefined(t.hpDeltaText),sourcePayload:g}:null},createSkillReplacementLine=(e,t)=>{const g=resolveSkillReplacementDetails(e,t);if(!g)return null;const{replacement:n}=g,C=n.preview??{};return{type:"replacement",buffer:"system"===n.buffer?"system":"combat",segments:Array.isArray(C.segments)?C.segments:[],metadata:{event:e,tag:"string"==typeof C.tag?C.tag:"",tagColor:"string"==typeof C.tagColor?C.tagColor:null,details:g}}},parsePercent$1=e=>{if(null==e)return null;const t=Number.parseInt(String(e).replace("%",""),10);return Number.isNaN(t)?null:t},extractTargetEventId=e=>{if(!isPlainObject$1(e))return null;const t=e.id??e.target;return"number"==typeof t&&Number.isFinite(t)?String(t):toTrimmedString(t)},extractTargetEventLabel=e=>toTrimmedString(e?.short_desc)??toTrimmedString(e?.name)??toTrimmedString(e?.text)??(extractTargetEventId(e)?`Target ${extractTargetEventId(e)}`:null),getTargetHpValue=e=>e?.hpperc??e?.hpPercent??e?.hp??null,hasNexsysTargetIdentityChange=e=>{const t=isPlainObject$1(e?.changedFields)?e.changedFields:null;return!t||["id","target","text","name","short_desc"].some(e=>Object.prototype.hasOwnProperty.call(t,e))},createTargetLine=(e,t,g)=>createStructuredLine(e,"[Target]","red",g,"combat",{id:extractTargetEventId(t),hpPercent:parsePercent$1(getTargetHpValue(t)),shortDescription:toTrimmedString(t?.short_desc)??toTrimmedString(t?.text)}),parseStreamEventLine=(e,t)=>{switch(e){case"Char.Defences.Add":{const g=extractName(t);return g?createStructuredLine(e,"+def","lawngreen",toDisplayName(g),"system",{name:g,direction:"gained",description:t&&"object"==typeof t&&!Array.isArray(t)?t.desc??null:null}):null}case"Char.Defences.Remove":{const g=extractName(t);return g?createStructuredLine(e,"-def","crimson",toDisplayName(g),"system",{name:g,direction:"lost"}):null}case"Char.Afflictions.Add":{const g=extractName(t);return g?createStructuredLine(e,"+aff","crimson",toDisplayName(g),"system",{name:g,direction:"gained",description:t&&"object"==typeof t&&!Array.isArray(t)?t.desc??null:null}):null}case"Char.Afflictions.Remove":{const g=extractName(t);return g?createStructuredLine(e,"-aff","lawngreen",toDisplayName(g),"system",{name:g,direction:"lost"}):null}case"nexsys4.system.target.changed":{if(!isPlainObject$1(t)||!hasNexsysTargetIdentityChange(t))return null;const g=extractTargetEventLabel(t);return g?createTargetLine(e,t,g):null}case"nexsys4.serverside.aff.priority.set":case"nexsys4.serverside.def.priority.set":{if(!isPlainObject$1(t))return null;const g="string"==typeof t.id&&t.id.trim().length>0?t.id.trim():null,n="number"==typeof t.priority&&Number.isFinite(t.priority)?t.priority:null;return g&&null!=n?createStructuredLine(e,`[Prio] ${n}`,"deepskyblue",toDisplayName(g),"system",{id:g,priority:n,accepted:!0===t.accepted,kind:e.includes(".aff.")?"affliction":"defence"}):null}case"nexSkillMatch":case"nexSkillNpcMatch":return createSkillReplacementLine(e,t);default:return null}},styleAttribute=e=>{const t=Object.entries(e).filter(([,e])=>e);return 0===t.length?"":` style="${t.map(([e,t])=>`${e}: ${t}`).join("; ")}"`},renderChunk=e=>`<span${styleAttribute({color:e.fg,"background-color":e.bg,"font-weight":e.bold?"700":null})}>${escapeHtml(e.text)}</span>`,renderSegmentsHtml=e=>e.map(renderChunk).join(""),resolveTimestamp=e=>e.timestamp??e.metadata?.timestamp??Date.now(),createDisplayLine=({html:e,timestamp:t,isPrompt:g=!1,isMonospace:n=!1,shouldLog:C=!0,buffer:o="main"})=>({id:null,html:e,timestamp:t,isPrompt:g,isMonospace:n,shouldLog:C,buffer:o}),renderStructuredRowHtml=(e,t)=>{const g=e.metadata?.tag??"",n=e.metadata?.tagColor??null;return[`<span class="nexgui4-stream-row nexgui4-stream-row--${t}" style="display: grid; grid-template-columns: auto minmax(0, 1fr); column-gap: 0.5rem; align-items: baseline;">`,`<span class="nexgui4-stream-row__tag mono"${styleAttribute({color:n})}>${escapeHtml(g)}</span>`,`<span class="nexgui4-stream-row__payload">${renderSegmentsHtml(e.segments)}</span>`,"</span>"].join("")},renderColorLine=e=>{const t=resolveTimestamp(e);return createDisplayLine({html:`<span class="nexgui4-color-line">${renderSegmentsHtml(e.segments)}</span>`,timestamp:t,isPrompt:e.isPrompt??!1,isMonospace:e.isMonospace??!1,shouldLog:e.shouldLog??!0,buffer:"main"})},Ge=Object.freeze({options:Object.freeze({msgReplace:!0,damageNumbers:!0}),target:Object.freeze({hpText:null,hpPercent:null,hpDeltaText:null}),styles:Object.freeze({getAfflictionStyle:()=>({fg:"grey",bg:null}),resolveCureInfoStyle:(e,t="cadetblue")=>({fg:t,bg:null})}),icons:Object.freeze({dualTone:null})}),capitalize$1=e=>"string"==typeof e&&e.length>0?e.charAt(0).toUpperCase()+e.slice(1):"",getRuntimeStyle=e=>({fg:"string"==typeof e?.fg?e.fg:null,bg:"string"==typeof e?.bg?e.bg:null}),resolveRenderContext=(e={})=>{const t=e.context??e.replacementContext??{};return{options:{...Ge.options,...t.options??{}},target:{...Ge.target,...t.target??{}},styles:{...Ge.styles,...t.styles??{}},icons:{...Ge.icons,...t.icons??{}}}},withSeparators=(e,t)=>e.flatMap((e,g)=>0===g?[e]:[t,e]),createTitle=e=>{const t="string"==typeof e.originalLine?e.originalLine:null,g=[t?`Source: ${t}`:null,"string"==typeof e.tooltip?e.tooltip:null].filter(Boolean);return g.length>0?g.join("\n---\n"):null},createActorNodes=e=>e?[relationshipNameNode(e)]:[],createUserActionNodes=(e,t,g)=>{const{id:n,text:C,banding:o}=e,I=[classTextNode(getUserActionClass(n),C)];if(t){const{fg:n,bg:C}=getRuntimeStyle(g.styles.resolveCureInfoStyle?.(t,e.fg));I.push(styledTextNode(capitalize$1(t),{className:"ng-info-text",fg:n??e.fg,bg:C}))}if(Array.isArray(o)){const[e,t]=o;return[classTextNode("ng-brkt",e),...I,classTextNode("ng-brkt",t)]}return[iconBandingNode({icon:o.icon,colors:o.colors,size:o.size,children:I})]},createTargetHpValueNodes=(e,t)=>{const g="number"==typeof e.targetHpPercent?e.targetHpPercent:"number"==typeof t.target.hpPercent?t.target.hpPercent:null,n="string"==typeof e.targetHpText?e.targetHpText:"string"==typeof t.target.hpText?t.target.hpText:null;return null!=g?[styledTextNode(`${g}%`,{fg:hpPercentToColor(g)})]:n?[classTextNode("ng-muted",n)]:[]},createDamageValueNodes=(e,t)=>{const g=e.damage;return g&&"string"==typeof g.damage?[classTextNode(getDamageClass(g.type),g.damage)]:createTargetHpValueNodes(e,t)},createUserSkillAttackNodes=(e,t,g)=>{const{skill:n,info:C,tags:o,target:I}=e,a=[classTextNode("ng-brkt","["),classTextNode(getSkillClass(n.id),n.name),classTextNode("ng-brkt","]")];C&&a.push(textNode(" "),classTextNode("ng-info-text",capitalize$1(C)));const i=Array.isArray(o)&&o.includes("pve")&&o.includes("damage")&&"string"==typeof I?.text&&I.text.includes(" "),s="firstPerson"===t.matchType||!t.actorId;if(i){const e="string"==typeof t.crit?t.crit:"Hit",n=s&&g.options.damageNumbers?createDamageValueNodes(t,g):createTargetHpValueNodes(t,g);a.push(classTextNode("ng-crit-separator",`: ${e} `)),n.length>0&&a.push(classTextNode("ng-dmg-bracket","("),...n,classTextNode("ng-dmg-bracket",")"))}return a},createUserActionColumnNodes=(e,t,g)=>{const{userAction:n,info:C}=e;return n&&De[n.id]?createUserActionNodes(n,C??null,g):createUserSkillAttackNodes(e,t,g)},createNpcActionColumnNodes=(e,t,g)=>{const{tags:n,target:C,skill:o}=e;if(!n||0===n.length)return[classTextNode("ng-muted",o.name)];const I=n.map(e=>{if("damage"===e&&"You"===C?.text){const e="string"==typeof t.hpDeltaText&&t.hpDeltaText?t.hpDeltaText:"string"==typeof g.target.hpDeltaText&&g.target.hpDeltaText?g.target.hpDeltaText:"-0%";return classTextNode("ng-hp-loss",e)}const{fg:n,bg:o}=getRuntimeStyle(g.styles.getAfflictionStyle?.(e));return styledTextNode(capitalize$1(e),{fg:n??"grey",bg:o})});return[classTextNode("ng-npc-bracket","«"),...withSeparators(I,classTextNode("ng-muted",", ")),classTextNode("ng-npc-bracket","»")]},createTargetColumnNodes=(e,t,g)=>{if(!e)return[];const n=relationshipNameNode(e);if(!e.text.includes(" ")||"grey"!==e.color)return[n];const C="number"==typeof t.targetHpPercent?t.targetHpPercent:"number"==typeof g.target.hpPercent?g.target.hpPercent:null,o="string"==typeof t.targetHpText?t.targetHpText:"string"==typeof g.target.hpText?g.target.hpText:null;return null!=C?[classTextNode("ng-dmg-bracket","("),styledTextNode(`${C}%`,{fg:hpPercentToColor(C)}),classTextNode("ng-dmg-bracket",") "),n]:o?[classTextNode("ng-dmg-bracket","("),classTextNode("ng-muted",o),classTextNode("ng-dmg-bracket",") "),n]:[n]},createReplacementViewModel=(e,t={})=>{if(!e||"object"!=typeof e)return null;const g=resolveRenderContext(t),n="npc"===e.variant?createNpcActionColumnNodes(e,t,g):createUserActionColumnNodes(e,t,g);return{family:"skill",eventName:e.eventName,variant:e.variant,layout:"replacement-row",title:createTitle(t),previewText:"string"==typeof e.preview?.text?e.preview.text:"",columns:{actor:createActorNodes(e.actor),action:n,target:createTargetColumnNodes(e.target,t,g)},assets:{dualToneIcons:g.icons.dualTone},metadata:{skillId:e.skill?.id??"",actionId:e.userAction?.id??null,matchType:"string"==typeof t.matchType?t.matchType:e.matchType,actorId:"string"==typeof t.actorId?t.actorId:null,tags:Array.isArray(e.tags)?[...e.tags]:[]}}},Be=new Map,normalizeColors=e=>Array.isArray(e)?1===e.length?[e[0],e[0]]:[e[0]??"currentColor",e[1]??e[0]??"currentColor"]:[e??"currentColor",e??"currentColor"],buildIconHtml=(e,t,g=16,n=null)=>{const C=normalizeColors(t),o=n?.[e];if(!Array.isArray(o))return"";const[I,a,,,i]=o;if(!Array.isArray(i)||i.length<2)return"";const s=`${e}-${C.join(",")}-${g}-${I}-${a}-${i.join("|")}`,l=Be.get(s);if(l)return l;const[c,u]=C,d=['<svg xmlns="http://www.w3.org/2000/svg" class="svg-inline--fa icon" aria-hidden="true" focusable="false"',` style="height:${escapeHtml(String(g))}px; --ng-fill-1:${escapeHtml(c)}; --ng-fill-2:${escapeHtml(u)};"`,` viewBox="0 0 ${escapeHtml(String(I))} ${escapeHtml(String(a))}">`,'<g class="fa-group">',`<path class="ng-icon-fill-1" d="${escapeHtml(i[0])}"></path>`,`<path class="ng-icon-fill-2" d="${escapeHtml(i[1])}"></path>`,"</g>","</svg>"].join("");return Be.set(s,d),d},buildIconBandingHtml=(e,t,g,n,C=null)=>{const o=buildIconHtml(e,t,g,C);return o?`${o}${n}${o}`:`«${n}»`},renderStyledTextNode=e=>span(escapeHtml(e.text),{className:e.className,style:{color:e.fg,"background-color":e.bg}}),renderReplacementHtmlNode=(e,t={})=>{if(!e||"object"!=typeof e)return"";switch(e.kind){case"text":return escapeHtml(e.text);case"class-text":return span(escapeHtml(e.text),{className:e.className});case"styled-text":return renderStyledTextNode(e);case"relationship-name":return renderRelationshipNameHtml(e.descriptor);case"icon-banding":return buildIconBandingHtml(e.icon,e.colors,e.size,renderReplacementHtmlNodes(e.children,t),t.dualToneIcons??null);case"group":return renderReplacementHtmlNodes(e.children,t);default:return""}},renderReplacementHtmlNodes=(e,t={})=>Array.isArray(e)?e.map(e=>renderReplacementHtmlNode(e,t)).join(""):"",renderColumn=(e,t)=>`<span class="nexgui4-replacement-row__${t}">${renderReplacementHtmlNodes(e?.columns?.[t],e?.assets)}</span>`,renderReplacementHtml=e=>[`<span class="nexgui4-replacement-row"${titleAttribute(e?.title)}>`,'<span class="nexgui4-replacement-row__buffer"></span>',renderColumn(e,"actor"),renderColumn(e,"action"),renderColumn(e,"target"),"</span>"].join(""),colorText=(e,t)=>e?span(escapeHtml(t),{style:{color:e}}):escapeHtml(t),renderFallbackPreviewHtml=e=>`<span class="nexgui4-replacement-row">${Array.isArray(e.segments)?e.segments.map(e=>e.fg?colorText(e.fg,e.text):escapeHtml(e.text)).join(""):""}</span>`,generateReplacementHtml=(e,t={})=>{const g=createReplacementViewModel(e,t);return renderReplacementHtml(g)},renderReplacementLine=e=>{const t=resolveTimestamp(e),g=e.metadata?.details??{},n=g.replacement??null,C=n?generateReplacementHtml(n,g):renderFallbackPreviewHtml(e);return createDisplayLine({html:C,timestamp:t,isPrompt:!1,isMonospace:!1,shouldLog:e.shouldLog??!0,buffer:"system"===e.buffer?"system":"combat"})},Fe=/^Health lost: (\d+) \((.+?)\)\.$/,We=/^Damage dealt: (\d+) \((.+?)\)\.$/,Ve=Object.freeze({crit:null,damage:null,healthLost:Object.freeze([]),tooltip:null,originalLine:null,consumedLineIndexes:Object.freeze([])}),getLineText=e=>e?"function"==typeof e.parsed_line?.text?e.parsed_line.text():"string"==typeof e.line?e.line:"":"",resolvePatternLength=e=>{const t="string"==typeof e.matchType?e.matchType.trim():"",g=e.patterns?.[t];return Array.isArray(g)?g.length:0},isPveDamageAction=e=>Array.isArray(e.tags)&&e.tags.includes("pve")&&e.tags.includes("damage")&&"string"==typeof e.target&&e.target.includes(" "),isNpcDamageToSelf=e=>Array.isArray(e.tags)&&e.tags.includes("damage")&&"self"===e.target,isFirstPersonOrActorless=e=>"firstPerson"===("string"==typeof e.matchType?e.matchType.trim():"")||("string"==typeof e.user?0===e.user.trim().length:!e.user),shouldCollectDamageDealt=(e,t)=>Boolean(t?.damageNumbers)&&isFirstPersonOrActorless(e),collectCrit=(e,t)=>{const g=getLineText(e?.[t]);for(const[n,C]of Te)if(g.includes(n))return{crit:C,consumedLineIndex:t};return{crit:"Hit",consumedLineIndex:null}},collectDamageDealt=(e,t)=>{const g=getLineText(e?.[t]).match(We);return g?{damage:g[1],type:g[2],consumedLineIndex:t}:null},collectHealthLost=(e,t)=>{if(!Array.isArray(e))return{healthLost:[],consumedLineIndexes:[]};const g=[],n=[];for(let C=t;C<e.length-1;C++){const t=getLineText(e[C]).match(Fe);t&&(g.push({damage:t[1],type:t[2]}),n.push(C))}return{healthLost:g,consumedLineIndexes:n}},collectReplacementSideData=(e,t,g,n={})=>{if(!e||"object"!=typeof e||Array.isArray(e)||!Array.isArray(t)||!g||"number"!=typeof g.index)return{...Ve,healthLost:[],consumedLineIndexes:[]};const C=e,o=new Set,I=getLineText(g)||null,a=resolvePatternLength(C),i=Math.max(a-1,0),s={crit:null,damage:null,healthLost:[],tooltip:null,originalLine:I};for(let l=1;l<=i;l++)o.add(g.index+l);if(isPveDamageAction(C)){const e=g.index+1,I=collectCrit(t,e);if(s.crit=I.crit,null!=I.consumedLineIndex&&o.add(I.consumedLineIndex),shouldCollectDamageDealt(C,n)){const g=null!=I.consumedLineIndex?e+1:e,n=collectDamageDealt(t,g);n&&(s.damage={damage:n.damage,type:n.type},o.add(n.consumedLineIndex))}}if(isNpcDamageToSelf(C)){const e=collectHealthLost(t,g.index+1);s.healthLost=e.healthLost,s.tooltip=e.healthLost.length>0?e.healthLost.map(({damage:e,type:t})=>`${e} (${t})`).join("\n"):null,e.consumedLineIndexes.forEach(e=>{o.add(e)})}return{...s,consumedLineIndexes:[...o].filter(e=>e!==g.index).sort((e,t)=>e-t)}},Ke="You",Ue="cadetblue",He=Object.freeze(["contextValue","persistenceStore","persistenceVersion","msgReplace","damageNumbers","selfName","targetName","hpText","hpPercent","hpDeltaText","playerDirectory","playerDirectoryVersion","playerRelationships","playerRelationshipsVersion","allyEnemyFormatting","targetFormatting","afflictionStyles","cureStyles","herbNames","herbMinerals","dualToneIcons"]);let Ye=null,Ze=null;const toNullableString=e=>isNonEmptyString(e)?e.trim():null,parsePercent=e=>{if("number"==typeof e&&Number.isFinite(e))return e;if("string"!=typeof e)return null;const t=e.match(/-?\d+(?:\.\d+)?/),g=t?Number(t[0]):NaN;return Number.isFinite(g)?g:null},getGlobals$1=()=>globalThis,getContextValue$2=()=>getGlobals$1().nexGui?.__contextValue??null,getCharacterState$1=e=>e?.stores?.character?.getState?.()??{},getUiSettings$2=e=>e?.persistenceStore?.getAll?.()?.ui??{},getPersistenceVersion=e=>"function"==typeof e?.persistenceStore?.getVersion?e.persistenceStore.getVersion():null,getModelVersion$2=e=>"function"==typeof e?.getVersion?e.getVersion():null,resolveUiSettings=(e,t)=>null!==t&&Ye?.contextValue===e&&Ye.persistenceStore===e?.persistenceStore&&Ye.persistenceVersion===t?Ye.uiSettings:getUiSettings$2(e),normalizeStyle=(e,t)=>({fg:toNullableString(e?.fg)??t,bg:toNullableString(e?.bg)}),createStyleResolvers=()=>({getAfflictionStyle:e=>{const t=getGlobals$1().nexSys?.prompt?.affAbbrev?.[e]??null;return normalizeStyle(t,"grey")},resolveCureInfoStyle:(e,t=Ue)=>{if(!isNonEmptyString(e))return{fg:t,bg:null};const g=getGlobals$1().nexSys,n=g?.tables?.herb_name_to_herb?.[e]??e,C=g?.prompt?.cureColors?.[n]??g?.prompt?.cureColors?.[g?.tables?.herb_to_mineral?.[n]]??null;return C?normalizeStyle(C,t):{fg:t,bg:null}}}),signaturesEqual=(e,t)=>null!==e&&null!==t&&He.every(g=>Object.is(e[g],t[g])),readContextInputs=()=>{const e=getGlobals$1(),t=getContextValue$2(),g=getPersistenceVersion(t),n=resolveUiSettings(t,g),C=getPersistenceVersion(t),o=t?.stores?.settings?.getState?.()?.options??n,I=getCharacterState$1(t),a=I.targetDetails??{},i=e.GMCP?.Target??{},s=e.nexSys??null,l=s?.prompt??null,c=s?.tables??null,u=toNullableString(a.hpText)??toNullableString(a.hpperc)??toNullableString(i.HP)??toNullableString(i.hpperc)??toNullableString(i.lastHP),d=parsePercent(a.hpPercent??a.hpperc??i.HP??i.hpperc??i.lastHP),p=toNullableString(I.target)??toNullableString(i.Text)??toNullableString(i.text)??"",m=toNullableString(l?.vars?.diffhp?.text)??("number"==typeof i.hpChange?`${i.hpChange}%`:toNullableString(i.hpChange)),h=Boolean(o.msgReplace),y=Boolean(o.damageNumbers),b=toNullableString(I.name)??toNullableString(e.GMCP?.Char?.Status?.name)??"",v=e.window?.___FONT_AWESOME___?.styles?.fad??null;return{contextValue:t,persistenceStore:t?.persistenceStore??null,persistenceVersion:C,uiSettings:n,msgReplace:h,damageNumbers:y,selfName:b,targetName:p,hpText:u,hpPercent:d,hpDeltaText:m,playerDirectory:t?.playerDirectory??null,playerDirectoryVersion:getModelVersion$2(t?.playerDirectory),playerRelationships:t?.playerRelationships??null,playerRelationshipsVersion:getModelVersion$2(t?.playerRelationships),allyEnemyFormatting:n.allyEnemyFormatting,targetFormatting:n.targetFormatting,afflictionStyles:l?.affAbbrev??null,cureStyles:l?.cureColors??null,herbNames:c?.herb_name_to_herb??null,herbMinerals:c?.herb_to_mineral??null,dualToneIcons:v}},createContextFromInputs=e=>({options:{msgReplace:e.msgReplace,damageNumbers:e.damageNumbers},self:{name:e.selfName,label:Ke},target:{name:e.targetName,hpText:e.hpText,hpPercent:e.hpPercent,hpDeltaText:e.hpDeltaText},styles:createStyleResolvers(),icons:{dualTone:e.dualToneIcons},playerDirectory:e.playerDirectory,playerRelationships:e.playerRelationships,relationshipFormatter:createRelationshipNameFormatterFromContext(e.contextValue,{targetName:e.targetName})}),clearMessageReplacementContextCache=()=>{Ye=null,Ze=null},createMessageReplacementContext=()=>{const e=readContextInputs();return signaturesEqual(Ye,e)&&Ze||(Ye=e,Ze=createContextFromInputs(e)),Ze},getGlobals=()=>globalThis,getHostBlock=()=>getGlobals().nexusclient?.current_block??null,getHostCurrentLine=()=>getGlobals().nexusclient?.current_line??null,createRenderContext=e=>({options:e.options,target:e.target,styles:e.styles,icons:e.icons}),createSkillReplacementPipelinePayload=(e,t,{context:g,sideData:n})=>{const C=createReplacementDescriptor(e,t,{relationshipFormatter:g.relationshipFormatter,selfName:g.self.name,selfText:g.self.label,targetName:g.target.name});return C?{kind:"nexgui4.skillReplacement",sourcePayload:t,replacement:C,context:createRenderContext(g),crit:n.crit,damage:n.damage,healthLost:n.healthLost,tooltip:n.tooltip,originalLine:n.originalLine,matchType:"string"==typeof t.matchType?t.matchType.trim():null,actorId:"string"==typeof t.user?t.user.trim():null,targetHpText:g.target.hpText,targetHpPercent:g.target.hpPercent,hpDeltaText:g.target.hpDeltaText}:null},renderPipelinePayloadForHost=(e,t)=>{const g=parseStreamEventLine(e,t);return g?renderReplacementLine(g).html:null},createSkillReplacementGagHandler=(e,t,{emitReplacement:g}={})=>n=>{if(!e())return;if(!n||"object"!=typeof n||Array.isArray(n))return;const C=n,o=getHostBlock(),I=getHostCurrentLine();if(!o||!I||"number"!=typeof I.index)return;const{index:a}=I,i=createMessageReplacementContext(),s=collectReplacementSideData(C,o,I,i.options),l=createSkillReplacementPipelinePayload(t,C,{context:i,sideData:s});if(!l)return;if(g?.(l),!I.parsed_line)return;const c=renderPipelinePayloadForHost(t,l);c&&(s.consumedLineIndexes.forEach(e=>{const t=o[e];t&&e!==a&&(t.gag=!0)}),I.parsed_line.nexSkillReplacement=!0,I.parsed_line.formatted=()=>c)},getOptions=()=>createMessageReplacementContext().options,isReplacementEnabled=()=>Boolean(getOptions().msgReplace),Qe="nexGui4",normalizeNexGuiClassReflexName=e=>{const t=toTrimmedString(e)?.replace(/\s+/g,"").toLowerCase();return t?`nexGui.${t}`:null},readCurrentHostClassName=(e=globalThis.GMCP)=>toTrimmedString(e?.Char?.Status?.class),runNexGuiClassReflex=(e,{nexusClient:t=globalThis.nexusclient,packageName:g=Qe}={})=>{const n=normalizeNexGuiClassReflexName(e);n&&t?.reflexes?.()?.run_function?.(n,{},g)},runNexGuiClassReflexForCurrentHostClass=(e={})=>runNexGuiClassReflex(readCurrentHostClassName(e.gmcp),e),Xe=new Set(["blindness","deafness","insomnia"]),qe="https://api.achaea.com/characters.json",passthroughParser=e=>e,resolvePlayerDirectory=e=>e??getDefaultPlayerDirectoryModel(),getContextValue$1=()=>globalThis.nexGui?.__contextValue??null,resolvePlayerRelationships$1=e=>e??getContextValue$1()?.playerRelationships??getDefaultPlayerRelationshipsModel(),resolveFetch=e=>"function"==typeof e?e:"function"==typeof globalThis.fetch?globalThis.fetch.bind(globalThis):null,getUiSettings$1=()=>getContextValue$1()?.persistenceStore?.getAll?.()?.ui??{},getCharacterState=()=>getContextValue$1()?.stores?.character?.getState?.()??{},isLoginTrackerEnabled=()=>Boolean(getUiSettings$1()?.loginTracker),shouldEmitAffliction=e=>{const t=extractNamedValue(e);return!Xe.has(t)},extractChannelPlayerNames=e=>Array.isArray(e)?e.map(e=>e?.name).filter(isNonEmptyString).map(e=>e.trim()):[],fetchActiveCharacterNames=async(e=recordPlayerDirectoryDiagnostic,t=null)=>{if("function"!=typeof t)return e({channel:"presence",action:"charactersListFetch",status:"unavailable",detail:{fetchAvailable:!1}}),[];try{const g=await t(qe,{cache:"no-store"});if(!g.ok)return e({channel:"presence",action:"charactersListFetch",status:"unavailable",detail:{httpStatus:g.status}}),[];const n=await g.json();return Array.isArray(n?.characters)?n.characters.map(e=>e?.name).filter(isNonEmptyString).map(e=>e.trim()):[]}catch{return e({channel:"presence",action:"charactersListFetch",status:"unavailable",detail:{exception:!0}}),[]}},createLoginTrackerNoticeHtml=(e,t,g,n)=>`<span>${createRelationshipNameFormatterFromContext(getContextValue$1(),{playerDirectory:g,playerRelationships:n}).renderHtml(e)} logged ${t}</span>`,emitBridgeEvent=({eventBus:e,topic:t,sourceEvent:g,payload:n,parser:C=passthroughParser,meta:o})=>{e.emit(t,{event:g,data:C(n),meta:o})},normalizeNexsysTargetChangedPayload=e=>isPlainObject$1(e)&&isPlainObject$1(e.current)?{...e.current,changedFields:isPlainObject$1(e.changedFields)?e.changedFields:{}}:e,parseCurrentHostClassChangedPayload=()=>({class:readCurrentHostClassName()}),createEmitHandler=(e,t)=>g=>{t.filter&&!t.filter(g)||(emitBridgeEvent({eventBus:e,topic:t.topic,sourceEvent:t.eventName,payload:g,parser:t.parser,meta:t.meta}),t.afterEmit?.(g))},createSkillReplacementEmitHandler=(e,t)=>createSkillReplacementGagHandler(isReplacementEnabled,t,{emitReplacement:g=>{emitBridgeEvent({eventBus:e,topic:D.STREAM_LINE,sourceEvent:t,payload:g,parser:passthroughParser,meta:{buffer:"combat",sourceModel:"replacement"}})}}),createLoginTrackerHandler=(e,t,g,n,C)=>{let o=[];return async I=>{if(!isLoginTrackerEnabled())return;const a=extractChannelPlayerNames(I),i=await fetchActiveCharacterNames(n,C),s=[...new Set([...a,...i])];if(0===o.length)return void(o=s);const l=[getCharacterState()?.name,globalThis.GMCP?.Char?.Status?.name].find(isNonEmptyString)?.trim(),c=o.filter(e=>!s.includes(e));s.filter(e=>!o.includes(e)).forEach(n=>{n!==l&&e.notice(createLoginTrackerNoticeHtml(n,"in",t,g),{html:!0})}),c.forEach(n=>{n!==l&&e.notice(createLoginTrackerNoticeHtml(n,"out",t,g),{html:!0})}),o=s}},Je=[{eventName:"IRE.Target.Set",topic:D.TARGET_CHANGED,parser:passthroughParser},{eventName:"IRE.Target.Info",topic:D.TARGET_CHANGED,parser:passthroughParser},{eventName:"nexsys4.system.target.changed",topic:D.TARGET_CHANGED,parser:normalizeNexsysTargetChangedPayload},{eventName:"Room.RemovePlayer",topic:D.ROOM_UPDATED,parser:passthroughParser},{eventName:"Room.AddPlayer",topic:D.ROOM_UPDATED,parser:passthroughParser},{eventName:"Room.Info",topic:D.ROOM_UPDATED,parser:passthroughParser},{eventName:"Char.Items.List",topic:D.ROOM_UPDATED,parser:passthroughParser},{eventName:"Char.Items.Add",topic:D.ROOM_UPDATED,parser:passthroughParser},{eventName:"Char.Items.Remove",topic:D.ROOM_UPDATED,parser:passthroughParser},{eventName:"Char.Items.Update",topic:D.ROOM_UPDATED,parser:passthroughParser},{eventName:"Char.Defences.Add",topic:D.DEFENCE_GAINED,parser:passthroughParser},{eventName:"Char.Defences.Remove",topic:D.DEFENCE_LOST,parser:passthroughParser},{eventName:"Char.Afflictions.Add",topic:D.STREAM_LINE,parser:passthroughParser,filter:shouldEmitAffliction,meta:{buffer:"system"}},{eventName:"Char.Afflictions.Remove",topic:D.STREAM_LINE,parser:passthroughParser,filter:shouldEmitAffliction,meta:{buffer:"system"}},{eventName:"Char.Vitals",topic:D.STATS_UPDATED,parser:passthroughParser},{eventName:"nexsys4.system.class.changed",topic:D.CLASS_CHANGED,parser:parseCurrentHostClassChangedPayload,afterEmit:()=>runNexGuiClassReflexForCurrentHostClass()},{eventName:"Comm.Channel.Text",topic:D.STREAM_LINE,parser:passthroughParser},{eventName:"Char.Status",topic:D.STATS_UPDATED,parser:passthroughParser},{eventName:"IRE.Misc.Achievement",topic:D.STATS_UPDATED,parser:passthroughParser,meta:{sourceModel:"stats"}},{eventName:"IRE.Time.List",topic:D.STATS_UPDATED,parser:passthroughParser,meta:{sourceModel:"stats"}},{eventName:"nexSkillMatch",topic:D.TIMER_STARTED,parser:passthroughParser,meta:{sourceModel:"timers"}},{eventName:"nexsys4.serverside.aff.priority.set",topic:D.STREAM_LINE,parser:passthroughParser,meta:{buffer:"system"}},{eventName:"nexsys4.serverside.def.priority.set",topic:D.STREAM_LINE,parser:passthroughParser,meta:{buffer:"system"}}],createStartUpGagHandler=e=>function(){e.gagCurrentBlock()},registerGmcpBindings=({adapter:e,eventBus:t,playerDirectory:g,playerDirectoryLifecycle:n,playerRelationships:C,playerDirectoryDiagnostics:o,remoteService:I,fetchFn:a})=>{const i=resolvePlayerDirectory(g),s=resolvePlayerRelationships$1(C),l=o?.recordPlayerDirectoryDiagnostic??recordPlayerDirectoryDiagnostic,c=I??createNullRemotePlayerService(),u=resolveFetch(a),d=[],p=createStartUpGagHandler(e),m=createLoginTrackerHandler(e,i,s,l,u),h=createCrowdsourceSyncHandler({remoteService:c,getPlayerProfile:i.getPlayerProfile,isSeeded:n?.isDirectorySeeded,recordDiagnostic:l,fetchFn:u,getSelfName:()=>[getCharacterState()?.name,globalThis.GMCP?.Char?.Status?.name].find(isNonEmptyString)?.trim()??null});d.push(e.on("nexSkillMatch",createSkillReplacementEmitHandler(t,"nexSkillMatch"))),d.push(e.on("nexSkillNpcMatch",createSkillReplacementEmitHandler(t,"nexSkillNpcMatch")));for(const y of Je){const g=createEmitHandler(t,y);d.push(e.on(y.eventName,g))}return d.push(e.on("Comm.Channel.Players",e=>{i.rememberChannelPlayers(e),h(e)})),d.push(e.on("Comm.Channel.Players",m)),d.push(e.on("IRE.Time.Update",()=>{e.sendGmcp("IRE.Time.Request")})),d.push(e.on("PromptEvent",p,{id:"nexGuiStartUpGag"})),d.push(e.on("nexGuiLoaded",()=>{e.off("PromptEvent","nexGuiStartUpGag"),e.notice("nexGui loaded using startup spam gag.")},{once:!0})),()=>{for(const e of d)e()}},emitStartupReadySignal=e=>{e.send("echo raiseEvent nexGuiLoaded")},createEventBus=({label:e="nexgui4.eventBus",debugEnabled:t=!1,traceLimit:g=500}={})=>{const n=new Map,C=[],pushTrace=(n,o)=>{const I={at:Date.now(),type:n,detail:o};return C.push(I),C.length>g&&C.splice(0,C.length-g),t&&console.log(`[${e}]`,n,o),I},on=(e,t)=>(n.has(e)||n.set(e,new Set),n.get(e).add(t),()=>off(e,t)),off=(e,t)=>n.get(e)?.delete(t);return{on,off,emit:(e,t)=>{pushTrace(e,t),n.get(e)?.forEach(e=>e(t))},clear:()=>{n.clear(),C.length=0},getTrace:()=>[...C],setDebugEnabled:e=>{t=e}}},parseStoredValue$1=e=>{if("string"!=typeof e)return e;try{return JSON.parse(e)}catch{return e}},isEquivalentValue=(e,t)=>JSON.stringify(e)===JSON.stringify(t),createPersistenceStore=({adapter:e,sliceKey:t=pe.SETTINGS,schema:g=me,migrate:n=migrateSettingsPersistence}={})=>{const C=assertAdapterContract(e);let o=0;const markChanged2=()=>{o+=1},assertSchemaKey=e=>{if("string"!=typeof e||"version"===e||!Object.hasOwn(g,e))throw new Error(`[nexGui4] Unknown persistence key "${String(e)}" for slice "${t}"`)},readState=()=>{const e=C.getVariable(de)||{},g=e[t],o=parseStoredValue$1(g),I=n(o);if(void 0===g||"string"==typeof g||!isEquivalentValue(o,I)){const g={...e,[t]:I};C.setVariable(de,g),markChanged2()}return I};return{get:e=>(assertSchemaKey(e),clonePersistenceValue(readState()[e])),set:(e,n)=>{assertSchemaKey(e);const o={...readState(),version:g.version,[e]:normalizePersistenceFragment(g[e],n)},I={...C.getVariable(de)||{},[t]:o};return C.setVariable(de,I),markChanged2(),clonePersistenceValue(o[e])},getAll:()=>clonePersistenceValue(readState()),getVersion:()=>o,reset:()=>{const e=clonePersistenceValue(g),n={...C.getVariable(de)||{},[t]:e};return C.setVariable(de,n),markChanged2(),clonePersistenceValue(e)}}},bindFunction=(e,t)=>"function"==typeof e?.[t]?e[t].bind(e):null,noopTimer=()=>null,noopClearTimer=()=>{},getPublicDualToneIcons=e=>e.window?.___FONT_AWESOME___?.styles?.fad??null,createBrowserRuntimePorts=(e=globalThis)=>Object.freeze({fetch:bindFunction(e,"fetch"),now:()=>Date.now(),setTimeout:bindFunction(e,"setTimeout")??noopTimer,clearTimeout:bindFunction(e,"clearTimeout")??noopClearTimer,setInterval:bindFunction(e,"setInterval")??noopTimer,clearInterval:bindFunction(e,"clearInterval")??noopClearTimer,getPublicDualToneIcons:()=>getPublicDualToneIcons(e)}),freezePhaseList=e=>Object.freeze([...e]),$e=Object.freeze({INIT:"INIT",PREPARING:"PREPARING",BOOTING:"BOOTING",MOUNTING_UI:"MOUNTING_UI",HYDRATING_LAYOUT:"HYDRATING_LAYOUT",RUNNING:"RUNNING",FAILED:"FAILED",DESTROYED:"DESTROYED"}),_e=Object.freeze({[$e.INIT]:freezePhaseList([$e.PREPARING,$e.DESTROYED]),[$e.PREPARING]:freezePhaseList([$e.BOOTING,$e.FAILED,$e.DESTROYED]),[$e.BOOTING]:freezePhaseList([$e.MOUNTING_UI,$e.FAILED,$e.DESTROYED]),[$e.MOUNTING_UI]:freezePhaseList([$e.HYDRATING_LAYOUT,$e.FAILED,$e.DESTROYED]),[$e.HYDRATING_LAYOUT]:freezePhaseList([$e.RUNNING,$e.FAILED,$e.DESTROYED]),[$e.RUNNING]:freezePhaseList([$e.FAILED,$e.DESTROYED]),[$e.FAILED]:freezePhaseList([$e.PREPARING,$e.DESTROYED]),[$e.DESTROYED]:freezePhaseList([])}),isPhaseTransitionAllowed=(e,t)=>_e[e]?.includes(t)??!1,et=Object.freeze([$e.PREPARING,$e.BOOTING,$e.MOUNTING_UI,$e.HYDRATING_LAYOUT,$e.RUNNING]),tt=3,gt=250,toErrorMessage=e=>e instanceof Error&&e.message?e.message:"string"==typeof e&&e.length>0?e:"Unknown startup failure",getRetryDelayMs=(e,t)=>t*2**Math.max(0,e-1),createStartupOrchestrator=({adapter:e,eventBus:t,phaseHandlers:g={},maxAttempts:n=tt,retryDelayMs:C=gt,setTimeoutFn:o=setTimeout,clearTimeoutFn:I=clearTimeout})=>{let a=$e.INIT,i=0,s=null,l=null,c=null,u=!1;const getState=()=>({phase:a,attempts:i,lastError:s}),transitionTo=(e,g={})=>{if(!isPhaseTransitionAllowed(a,e))throw new Error(`[nexGui4] Invalid startup phase transition: ${a} -> ${e}`);const n=a;return a=e,t.emit(L.SYSTEM_PHASE,{phase:e,previousPhase:n,attempt:g.attempt??i,...void 0!==g.error?{error:g.error}:{},...void 0!==g.retryDelayMs?{retryDelayMs:g.retryDelayMs}:{},...void 0!==g.permanent?{permanent:g.permanent}:{}}),e===$e.RUNNING&&t.emit(L.SYSTEM_READY,{phase:e,previousPhase:n,attempt:g.attempt??i}),getState()},clearPendingRetry=()=>{c&&(I(c.timerId),c.resolve(),c=null)},waitForRetry=e=>new Promise(t=>{const g=o(()=>{c=null,t()},e);c={timerId:g,resolve:t}}),runPhase=async n=>{const C=g[n];"function"==typeof C&&await C({phase:n,attempt:i,adapter:e,eventBus:t})},runAttempt=async()=>{i+=1;try{for(const e of et){if(u)return getState();transitionTo(e,{attempt:i}),await runPhase(e)}return s=null,getState()}catch(t){s=t;const g=i<n,o=g?getRetryDelayMs(i,C):0;if(transitionTo($e.FAILED,{attempt:i,error:t,...g?{retryDelayMs:o}:{permanent:!0}}),!g)throw e.notice(`[nexGui4] Startup failed after ${i} attempts: ${toErrorMessage(t)}`),t;return await waitForRetry(o),u?getState():runAttempt()}};return{start:()=>l||(u?Promise.reject(new Error("[nexGui4] Cannot start startupOrchestrator after destroy().")):a===$e.RUNNING?Promise.resolve(getState()):(l=runAttempt().finally(()=>{l=null}),l)),destroy:()=>(a===$e.DESTROYED||(u=!0,clearPendingRetry(),transitionTo($e.DESTROYED,{attempt:i})),getState()),getState}},rt="nexgui4_scrollback",nt=1,At="session_lines",toSortedLines=e=>Array.from(e.values()).sort((e,t)=>e.id-t.id),resolveIndexedDb=e=>void 0!==e?e:globalThis.indexedDB,resolveKeyRange=e=>void 0!==e?e:globalThis.IDBKeyRange,createIndexedDbManager=({dbName:e=rt,dbVersion:t=nt,storeName:g=At,indexedDb:n,keyRange:C,logger:o=null}={})=>{const I=resolveIndexedDb(n),a=resolveKeyRange(C);let i=null,s=null,l=new Map,c=!I||!a,u=!1;const debug=(...e)=>o?.debug?.(...e),warn=(...e)=>o?.warn?.(...e),switchToFallback=e=>{i&&(i.close?.(),i=null),c=!0,warn("[nexGui4] IndexedDB unavailable; using in-memory scrollback storage.",e)},assertActive=()=>{if(u)throw new Error("[nexGui4] IndexedDB manager has been destroyed.")},initialize=()=>(assertActive(),c||i?Promise.resolve():s||(s=new Promise(n=>{let C=!1;const settleWithFallback=e=>{C||(C=!0,s=null,switchToFallback(e),n())},settleWithDb=e=>{C?e?.close?.():(C=!0,i=e,debug("[nexGui4] IndexedDB scrollback storage initialized."),n())};let o;try{o=I.open(e,t)}catch(a){return void settleWithFallback(a)}o.onupgradeneeded=e=>{const t=e.target.result;t.objectStoreNames.contains(g)||t.createObjectStore(g,{keyPath:"id"})},o.onsuccess=e=>{settleWithDb(e.target.result)},o.onerror=e=>{settleWithFallback(e.target.error)},o.onblocked=e=>{settleWithFallback(e)}}),s)),ensureDb=async()=>(assertActive(),c?null:i||(await initialize(),i)),writeBatch=async e=>{if(assertActive(),0===e.length)return;if(c){for(const t of e)l.set(t.id,t);return}const t=await ensureDb();if(!c&&t)return new Promise((n,C)=>{const o=t.transaction([g],"readwrite"),I=o.objectStore(g);o.oncomplete=()=>{n()},o.onerror=e=>{C(e.target.error)},o.onabort=e=>{C(e.target.error)};for(const t of e)I.put(t)});await writeBatch(e)},readRange=async(e,t)=>{if(assertActive(),c)return toSortedLines(l).filter(g=>g.id>=e&&g.id<=t);const n=await ensureDb();return c||!n?readRange(e,t):new Promise((C,o)=>{const I=n.transaction([g],"readonly").objectStore(g),i=a.bound(e,t),s=I.getAll(i);s.onsuccess=()=>{C(s.result)},s.onerror=e=>{o(e.target.error)}})},readIds=async e=>{if(assertActive(),0===e.length)return[];if(c)return e.map(e=>l.get(e)).filter(Boolean);const t=await ensureDb();return c||!t?readIds(e):new Promise((n,C)=>{const o=t.transaction([g],"readonly"),I=o.objectStore(g),a=[];let i=!1;o.oncomplete=()=>{if(i)return;const t=new Map(a.map(e=>[e.id,e]));n(e.map(e=>t.get(e)).filter(Boolean))},o.onerror=e=>{i=!0,C(e.target.error)},o.onabort=e=>{i=!0,C(e.target.error)};for(const t of e){const e=I.get(t);e.onsuccess=()=>{void 0!==e.result&&a.push(e.result)}}})},readAll=async()=>{if(assertActive(),c)return toSortedLines(l);const e=await ensureDb();return c||!e?readAll():new Promise((t,n)=>{const C=e.transaction([g],"readonly").objectStore(g).getAll();C.onsuccess=()=>{t(C.result)},C.onerror=e=>{n(e.target.error)}})},clear=async()=>{if(assertActive(),c)return void l.clear();const e=await ensureDb();if(!c&&e)return new Promise((t,n)=>{const C=e.transaction([g],"readwrite").objectStore(g).clear();C.onsuccess=()=>{t()},C.onerror=e=>{n(e.target.error)}});await clear()},close=()=>{i?.close?.(),i=null,s=null},destroy=()=>{u||(close(),l=new Map,u=!0)};return{initialize,writeBatch,readRange,readIds,readAll,clear,close,destroy,isFallback:()=>c}},Ct=Object.freeze([]),normalizeEntries=e=>(Array.isArray(e)?e:[]).filter(e=>e&&"number"==typeof e.id).map(e=>({...e})),estimateSearchBytes=(e,t)=>2*t+32*e,createScrollbackSessionStore=({storage:e=createIndexedDbManager(),writeBatchSize:t=E,writeDebounceMs:g=R,setTimeoutFn:n=setTimeout,clearTimeoutFn:C=clearTimeout,logger:o=null}={})=>{let I=[],a=null,i=Promise.resolve(),s=[],l=0,c=!1,u=null;const reportAsyncError=e=>{o?.error?.("[nexGui4] Scrollback session operation failed.",e)},assertActive=()=>{if(c)throw new Error("[nexGui4] Scrollback session store has been destroyed.")},cancelFlushTimer=()=>{a&&(C(a),a=null)},enqueueOperation=e=>{const t=i.then(e);return i=t.catch(()=>{}),t},takePendingWrites=()=>{if(cancelFlushTimer(),0===I.length)return Ct;const e=I;return I=[],e},enqueuePendingWrite=()=>{const t=takePendingWrites();return 0===t.length?i:enqueueOperation(()=>e.writeBatch(t))},scheduleFlush=()=>{a||0===I.length||(a=n(()=>{a=null,enqueuePendingWrite().catch(reportAsyncError)},g))},resetSearchRecords=()=>{s=[],l=0},appendSearchRecords=e=>{for(const t of e){const e=stripHtml(t.html).toLowerCase();s.push({id:t.id,isPrompt:Boolean(t.isPrompt),text:e}),l+=e.length}},flush=()=>(assertActive(),enqueuePendingWrite()),readRange=async(t,g)=>(assertActive(),await flush(),enqueueOperation(()=>e.readRange(t,g))),readIds=async t=>(assertActive(),await flush(),Array.isArray(t)&&0!==t.length?enqueueOperation(()=>e.readIds(t)):[]),readAll=async()=>(assertActive(),await flush(),enqueueOperation(()=>e.readAll())),search=async(t,{includePrompts:g=!0}={})=>{assertActive();const n=String(t??"").trim().toLowerCase();if(await flush(),!n)return[];const C=s.filter(e=>g||!e.isPrompt).filter(e=>e.text.includes(n)).map(e=>e.id);return 0===C.length?[]:enqueueOperation(()=>e.readIds(C))};return{initialize:()=>(assertActive(),enqueueOperation(()=>e.initialize?.()??Promise.resolve())),append:e=>{if(c)return;const g=normalizeEntries(e);0!==g.length&&(appendSearchRecords(g),I.push(...g),I.length>=t?enqueuePendingWrite().catch(reportAsyncError):scheduleFlush())},flush,clear:()=>(assertActive(),cancelFlushTimer(),I=[],resetSearchRecords(),enqueueOperation(()=>e.clear())),readRange,readIds,readAll,search,getStats:()=>({pendingCount:I.length,pendingFlushScheduled:Boolean(a),storageFallback:Boolean(e.isFallback?.()),searchLineCount:s.length,searchTextChars:l,estimatedSearchBytes:estimateSearchBytes(s.length,l),writeBatchSize:t,writeDebounceMs:g,destroyed:c}),destroy:()=>{if(u)return u;const t=enqueuePendingWrite();return c=!0,u=t.catch(reportAsyncError).finally(()=>{cancelFlushTimer(),I=[],resetSearchRecords(),"function"==typeof e.destroy?e.destroy():e.close?.()}),u}}},NOOP$6=()=>{},normalizeTargetValue=e=>"string"==typeof e&&e.trim().length>0?e.trim():null,createCharacterApi=({characterModel:e=null,getTarget:t=()=>null,setTarget:g=NOOP$6,syncTarget:n=null,clearTarget:C=null}={})=>{const getCharacterSnapshot=()=>e?.snapshot?.()??{},o=Object.freeze({get:()=>getCharacterSnapshot().target??null,set:e=>{const o=normalizeTargetValue(e);return g(o),null===o?C?.():n?.({targetValue:o,hostTargetValue:t(),reset:!0}),getCharacterSnapshot().target??null},is:e=>normalizeLookupKey(getCharacterSnapshot().target)===normalizeLookupKey(e)}),I=Object.freeze({get:()=>getCharacterSnapshot().class??"",is:e=>normalizeLookupKey(getCharacterSnapshot().class)===normalizeLookupKey(e)});return Object.freeze({target:o,class:I})},EMPTY_ICON_HTML=()=>"",createColorsApi=({playerColor:e=()=>"grey",iconHtml:t=EMPTY_ICON_HTML}={})=>{const g="function"==typeof t?t:EMPTY_ICON_HTML;return Object.freeze({playerColor:t=>e(t),iconHtml:(e,t,n)=>g(e,t,n)})},NOOP$5=()=>{},toFrozenList$1=e=>Object.freeze(Array.isArray(e)?[...e]:[]),createCustomizeApi=({setConfiguredDefences:e=NOOP$5,setClassBalanceType:t=NOOP$5,mountNativeDisplay:g=NOOP$5,unmountNativeDisplay:n=NOOP$5}={})=>{const C=Object.freeze({set:t=>toFrozenList$1(e(t))}),o=Object.freeze({set:e=>t(e)}),I=Object.freeze({mount:()=>{g()},unmount:()=>{n()}});return Object.freeze({defences:C,classBalance:o,nativeDisplay:I})},NOOP$4=()=>!1,toFrozenList=e=>Object.freeze(Array.isArray(e)?[...e]:[]),createLayoutApi=({presetIds:e=[],applyPreset:t=NOOP$4,saveLayout:g=NOOP$4,restoreLayout:n=NOOP$4,hasSavedLayout:C=()=>!1}={})=>{const o=toFrozenList(e);return Object.freeze({list:()=>o,apply:e=>Boolean(t(e)),save:()=>Boolean(g()),restore:()=>Boolean(n()),hasSaved:()=>Boolean(C())})},NOOP$3=()=>({members:[],leader:"",selfName:""}),createPartyApi=({getSnapshot:e=NOOP$3}={})=>{const isMember=t=>{const g=normalizeLookupKey(t);return!!g&&e().members.some(e=>normalizeLookupKey(e)===g)};return Object.freeze({isMember})},ot=Object.freeze([]),normalizeLookupName=e=>"string"==typeof e&&e.trim().length>0?e.trim().toLowerCase():"",toReadOnlySnapshot=e=>e&&"object"==typeof e?deepFreeze(structuredClone(e)):e,createPlayersApi=({getPlayer:e=()=>null,listPlayers:t=()=>ot,getPlayerColor:g=()=>"grey",refreshPlayer:n=async()=>null}={})=>{const resolveProfile=g=>{const n=e(g);if(n)return n;const C=normalizeLookupName(g);return C?t().find(e=>normalizeLookupName(e?.name)===C)??null:null},get=e=>{const t=resolveProfile(e);return t?toReadOnlySnapshot(t):null},color2=e=>g(e),fetch=async e=>{try{const t=await n(e);if(t)return toReadOnlySnapshot(t)}catch{}const t=resolveProfile(e);return t?toReadOnlySnapshot(t):null};return Object.freeze({get,color:color2,fetch})},NOOP$2=()=>{},NOOP_LIST=()=>[],NOOP_GET=()=>null,It=["text","color","background"],normalizeOverride=e=>{if(!e||"object"!=typeof e)return null;const t={};for(const g of It)"string"==typeof e[g]&&e[g]&&(t[g]=e[g]);return Object.keys(t).length>0?Object.freeze(t):null},createRoomApi=({setItemOverride:e=NOOP$2,removeItemOverride:t=NOOP$2,listItemOverrides:g=NOOP_LIST,getItemOverride:n=NOOP_GET}={})=>{const C=Object.freeze({set:(t,g)=>{const n=normalizeOverride(g);return n?(e(t,n),n):null},remove:e=>{t(e)},get:e=>n(e),list:()=>Object.freeze(g().map(([e,t])=>Object.freeze({name:e,override:t})))});return Object.freeze({items:C})},isTranscriptModel=e=>Boolean(e&&"function"==typeof e.addLines&&"function"==typeof e.getSnapshot),assertHtml=e=>{if("string"!=typeof e||0===e.length)throw new TypeError('api.stream.add requires a non-empty "html" string.')},resolveTargetModel=(e,t,g)=>{if("system"===e)return t;if("combat"===e)return g;throw new RangeError('api.stream.add requires "stream" to be either "system" or "combat".')},toReadOnlyEntry=e=>e?Object.freeze({...e}):null,createStreamApi=({systemStream:e=null,combatStream:t=null,now:g=Date.now}={})=>{const add=({html:n,stream:C}={})=>{assertHtml(n);const o=resolveTargetModel(C,e,t);if(!isTranscriptModel(o))return null;const I=g();return o.addLines([{html:n,timestamp:I,isPrompt:!1,isMonospace:!1,shouldLog:!0,buffer:C}]),toReadOnlyEntry(o.getSnapshot().items.at(-1))};return Object.freeze({add})},createNoopTimerModel=()=>({add:()=>null,clearAll:()=>0,get:()=>null,list:()=>[],remove:()=>null,reset:()=>null,start:()=>null,stop:()=>null}),hasListFilters=e=>"string"==typeof e||null!==e&&"object"==typeof e,resolveGroupId=e=>"string"==typeof e?e:e&&"object"==typeof e&&"string"==typeof e.groupId?e.groupId:null,createTimersApi=({timerModel:e}={})=>{const t=e??createNoopTimerModel(),get=e=>t.get(e),list=e=>{if(!hasListFilters(e))throw new TypeError("api.timers.list requires filters; read nexGui.state.timers.list for the unfiltered snapshot.");return t.list(e)},start2=e=>t.start(e),stop=e=>t.stop(e),reset=e=>t.reset(e),remove=e=>t.remove(e),add=(e,g,n="",C)=>t.add(e,g,n,C),clear=e=>{const g=resolveGroupId(e);if(!g)return t.clearAll();const n=t.list({groupId:g});for(const C of n)t.remove(C.id);return n.length};return Object.freeze({add,clear,get,list,remove,reset,start:start2,stop})},toFrozenSnapshot=e=>e&&"object"==typeof e?deepFreeze(structuredClone(e)):e,at=Object.freeze({name:"",class:"",level:0,target:null,targetDetails:Object.freeze({id:null,name:null,hpPercent:null,hpText:null,hpDelta:null,gender:null,currentAffs:Object.freeze([]),limbs:Object.freeze({})}),gender:null,balance:!1,equilibrium:!1,classBalanceType:null,classBalanceReady:null,currentAffs:Object.freeze([]),limbs:Object.freeze({})}),createCharacterState=({characterModel:e=null}={})=>()=>toFrozenSnapshot(e?.snapshot?.()??at),createCustomizeState=({getConfiguredDefences:e=()=>[],classBalanceController:t=null}={})=>()=>{const g=e();return toFrozenSnapshot({defences:Array.isArray(g)?g:[],classBalance:t?.getType?.()??null})},it=Object.freeze({members:Object.freeze([]),leader:"",selfName:"",settings:Object.freeze({})}),createPartyState=({partyModel:e=null}={})=>()=>toFrozenSnapshot(e?.snapshot?.()??it),st=Object.freeze({directory:Object.freeze([]),cityPalette:Object.freeze({})}),createPlayersState=({playerDirectory:e=null,cityPalette:t=st.cityPalette}={})=>()=>toFrozenSnapshot({directory:e?.getAllPlayerProfiles?.()??[],cityPalette:t&&"object"==typeof t?t:{}}),lt=Object.freeze({ref:Object.freeze({id:"",name:""}),items:Object.freeze([]),occupants:Object.freeze({players:Object.freeze([]),npcs:Object.freeze([])})}),createRoomState=({roomModel:e=null}={})=>()=>{const t=e?.snapshot?.();return t?toFrozenSnapshot({ref:{id:t.roomId??"",name:t.roomName??""},items:Array.isArray(t.items)?t.items:[],occupants:{players:Array.isArray(t.players)?t.players:[],npcs:Array.isArray(t.npcs)?t.npcs:[]}}):lt},ct=Object.freeze({instance:Object.freeze({kills:0,goldGained:0,xpPercent:0,xpValue:0,deaths:0,startedAt:0}),session:Object.freeze({kills:0,goldGained:0,xpPercent:0,xpValue:0,deaths:0,startedAt:0}),month:Object.freeze({kills:0,goldGained:0,xpPercent:0,xpValue:0,deaths:0,startedAt:0,goldCap:0,year:0,month:0})}),createStatsState=({playStatsModel:e=null}={})=>()=>toFrozenSnapshot(e?.snapshot?.()??ct),createSystemState=({version:e="",isMounted:t=()=>!1,startupOrchestrator:g=null}={})=>()=>toFrozenSnapshot({version:e,mounted:Boolean(t()),phase:g?.getState?.().phase??"INIT"}),createTimersState=({timerModel:e=null}={})=>()=>toFrozenSnapshot({list:e?.list?.()??[]}),composePublicApi=({version:e,startupOrchestrator:t,isMounted:g,character:n,timerModel:C,players:o,colors:I,customize:a,layout:i,party:s,room:l,stats:c,stream:u}={})=>{const d=createPlayersApi(o),p=createColorsApi({playerColor:I?.playerColor??d.color,iconHtml:I?.iconHtml}),m={system:createSystemState({version:e,isMounted:g,startupOrchestrator:t}),character:createCharacterState({characterModel:n?.characterModel}),party:createPartyState({partyModel:s?.partyModel}),room:createRoomState({roomModel:l?.roomModel}),stats:createStatsState({playStatsModel:c?.playStatsModel}),players:createPlayersState({playerDirectory:o?.playerDirectory,cityPalette:I?.cityPalette}),timers:createTimersState({timerModel:C}),customize:createCustomizeState({getConfiguredDefences:a?.getConfiguredDefences,classBalanceController:a?.classBalanceController})},stateSnapshot=()=>Object.freeze({system:m.system(),character:m.character(),party:m.party(),room:m.room(),stats:m.stats(),players:m.players(),timers:m.timers(),customize:m.customize()}),h=Object.freeze({character:createCharacterApi(n),players:d,colors:p,timers:createTimersApi({timerModel:C}),customize:createCustomizeApi(a),layout:createLayoutApi(i),party:createPartyApi({getSnapshot:s?.getSnapshot}),room:createRoomApi(l),stream:createStreamApi(u)}),y={};return Object.defineProperty(y,"state",{enumerable:!0,get:stateSnapshot}),Object.defineProperty(y,"api",{value:h,enumerable:!0}),Object.freeze(y)},ut="feather-pointed",tab=(e,t={})=>({type:"tab",id:e,name:e,component:e,helpText:e,icon:ut,...t}),hostTab=e=>({type:"tab",...e}),rightBorder=(e={})=>({type:"border",location:"right",...e}),dt={layout:{type:"row",id:"main",children:[{type:"row",id:"#f21df3e7-48ef-48f4-b77d-96a4cfc93903",weight:11.055408908360821,children:[{type:"tabset",id:"container_1",weight:6.080414549807837,children:[tab("nexDefences")]},{type:"tabset",id:"#fc94a4e0-6b58-42b5-826f-6e0c3bec80a7",weight:5.235912529001193,children:[tab("nexTimers")]},{type:"tabset",id:"#3251f844-bd3f-4ebb-aca9-9a4dfe9d0add",weight:5.49476101474438,children:[tab("nexTarget")]},{type:"tabset",id:"#5a449b58-0188-4ab9-9c98-023ed517a477",weight:5.316690055933218,children:[tab("nexStats",{borderWidth:725})]}]},{type:"row",id:"#70e4ecdf-81dc-40c6-b536-b62595eff99b",weight:54.4266284719302,children:[{type:"tabset",id:"#f85f4040-6d4a-49c7-94bd-7244f1a3b32d",weight:11.507047541573453,children:[hostTab({id:"all_comm",name:"All Comm",helpText:"Global Communication Window",component:"all_comm",icon:"message-lines"})]},{type:"tabset",id:"#fdd3f126-a4e3-4f24-9e2b-03b2f25825ec",weight:46.37955039657086,enableDrop:!1,enableTabStrip:!1,active:!0,children:[hostTab({id:"#90968890-c02d-44ac-947a-5651201350c8",component:"center"})]}]},{type:"row",id:"#105ad70c-29c2-4f15-b764-c2c124fd5e36",weight:41.18462928637565,children:[{type:"row",id:"#6c8d384b-ce25-444f-9ece-92e8d7c1c7f4",weight:26.295598569968487,children:[{type:"tabset",id:"#14f8b2aa-bc7c-4e2b-b6cb-b05931394b2a",weight:48.76712328767123,children:[tab("nexFeed")]},{type:"tabset",id:"#887e45a7-0b29-446f-862b-d6dde018fc96",weight:51.23287671232877,children:[tab("nexMetrics")]}]},{type:"row",id:"#64cee95d-aaef-477c-965e-76cdabd2a677",weight:35.830262173583016,children:[{type:"row",id:"#c365b5e0-6c0c-4de0-81f2-872ed286499d",weight:39.93115318416523,children:[{type:"tabset",id:"#01137e43-37f6-4f66-aa8a-b129d202fc29",weight:49.54337899543379,children:[tab("nexItems")]},{type:"tabset",id:"#e4c4c437-aba2-45ff-b168-f72896c253fa",weight:50.45662100456621,children:[tab("nexNpcs")]}]},{type:"tabset",id:"#59491b6a-bab3-415d-8367-25c562f46ae9",weight:60.06884681583477,selected:1,children:[hostTab({id:"map",name:"Map",helpText:"Map",component:"map",icon:"route"}),hostTab({id:"nexMap",name:"nexMap",helpText:"nexMap",component:"nexMap",icon:ut})]}]},{type:"tabset",id:"#63176cb9-c8b3-452a-afff-1e828d13e678",weight:6.009664560737805,children:[tab("nexPlayers")]},{type:"row",id:"#9e30489f-3eaf-4afe-90f6-23087c97698d",weight:19.364474695710708,children:[{type:"tabset",id:"#688e21f9-7929-4c29-92ce-9a9500c8fb63",weight:34.47319574635062,children:[tab("nexCombat")]},{type:"tabset",id:"#a79f5a9f-83b7-4f6a-b3c9-1c3e5843cc7e",weight:34.83104898939232,children:[tab("nexSystem")]}]}]}]},borders:[rightBorder({size:700,children:[tab("nexOptions",{borderWidth:300}),tab("nexParty",{borderWidth:300})]}),{type:"border",location:"left",children:[]},{type:"border",location:"top",children:[]},{type:"border",location:"bottom",children:[]}]},pt={layout:{type:"row",id:"main",children:[{type:"row",id:"#70e4ecdf-81dc-40c6-b536-b62595eff99b",weight:57.26509774852639,children:[{type:"tabset",id:"#f85f4040-6d4a-49c7-94bd-7244f1a3b32d",weight:17.557736227615205,selected:1,children:[hostTab({id:"map",name:"Map",helpText:"Map",component:"map",icon:"route"}),hostTab({id:"nexMap",name:"nexMap",helpText:"nexMap",component:"nexMap",icon:ut})]},{type:"row",id:"#bcb4f90b-4716-4f9b-9b22-ffd8741be626",weight:7.090289581370549,children:[{type:"tabset",id:"#b54bf1ab-4145-4041-9e67-8e6b789724b1",weight:11.363636363636363,children:[tab("nexPlayers")]},{type:"tabset",id:"#3df7c443-17f5-406e-9a45-54879deb731e",weight:26.79425837320574,children:[tab("nexNpcs")]},{type:"tabset",id:"#5c7c36a2-9496-4e6f-a1df-c581f898f7ac",weight:36.8421052631579,active:!0,children:[tab("nexItems")]}]},{type:"tabset",id:"#1eaac23b-4eae-486d-8915-90a25f41f9e0",weight:2.6494514015995967,children:[hostTab({id:"all_comm",name:"All Comm",helpText:"Global Communication Window",component:"all_comm",icon:"message-lines"})]},{type:"tabset",id:"#fdd3f126-a4e3-4f24-9e2b-03b2f25825ec",weight:30.58912072755898,enableDrop:!1,enableTabStrip:!1,children:[hostTab({id:"#90968890-c02d-44ac-947a-5651201350c8",component:"center"})]}]}]},borders:[rightBorder({size:700,children:[tab("nexOptions",{borderWidth:300}),tab("nexParty",{borderWidth:300}),tab("nexMetrics"),tab("nexStats",{borderWidth:725}),tab("nexCombat"),tab("nexSystem"),tab("nexTarget"),tab("nexDefences"),tab("nexTimers"),tab("nexFeed")]})]},mt=Object.freeze({kDesktop:dt,mobile:pt}),ft=Object.freeze(Object.keys(mt)),getLayoutPreset=e=>mt[e]??null,createCharacterStore=({characterModel:e,eventBus:t})=>{const g=create(()=>({...e.read(),updateCharacter:t=>e.update(t),setClass:t=>e.setClass(t),setTarget:t=>e.setTarget(t)})),refreshCharacter=()=>{g.setState(e.read())};return t.on(O.CHARACTER_UPDATED,refreshCharacter),t.on(O.CLASS_CHANGED,refreshCharacter),t.on(O.TARGET_CHANGED,refreshCharacter),g},projectEntries=(e,t)=>e.length===t.length&&e.every((e,g)=>Object.is(e,t[g]))?e:t,createFeedStore=({feedModel:e})=>create((t,g)=>{const refresh=()=>{t({entries:projectEntries(g().entries,e.snapshot())})};return{entries:e.snapshot(),addEntry:t=>{e.add(t),refresh()},addEntries:t=>{if("function"==typeof e.addEntries)e.addEntries(t);else for(const g of t)e.add(g);refresh()},replaceEntries:t=>{if("function"==typeof e.replaceEntries)e.replaceEntries(t);else{e.clear();for(const g of t)e.add(g)}refresh()},clear:()=>{e.clear(),refresh()}}}),createPartyStore=({partyModel:e,eventBus:t})=>{const readParty=()=>e.read?.()??e.snapshot(),g=create(()=>({...readParty(),updateParty:t=>e.update(t),addMember:t=>e.addMember(t),removeMember:t=>e.removeMember(t),setLeader:t=>e.setLeader(t),setSelf:t=>e.setSelf(t),setSetting:(t,g)=>e.setSetting(t,g)})),refreshParty=()=>{g.setState(readParty())};return t.on(O.PARTY_UPDATED,refreshParty),t.on(O.PARTY_MEMBER_LEFT,refreshParty),g},ht=/^You have gained (\d+) experience\.$/,yt=/^You have made (\d+) out of 450000 gold this month\.$/,toFiniteNumber=(e,t=null)=>{const g="number"==typeof e?e:"string"==typeof e&&e.trim().length>0?Number(e):Number.NaN;return Number.isFinite(g)?g:t},toInteger=(e,t=null)=>{const g=toFiniteNumber(e,Number.NaN);return Number.isFinite(g)?Math.trunc(g):t},toStatusXp=e=>{if(!e||"object"!=typeof e)return null;const t="string"==typeof e.level?Number.parseInt(e.level,10):toInteger(e.level,null),g=toFiniteNumber("string"==typeof e.xp?e.xp.replace("%",""):e.xp,null);return null==t||null==g?null:t+g/100},makeScope=e=>({kills:0,goldGained:0,xpPercent:0,xpValue:0,deaths:0,startedAt:e}),makeMonthScope=e=>({...makeScope(e),goldCap:0,year:0,month:0}),cloneSnapshot=e=>structuredClone(e),normalizePersistedStats=e=>migrateGameStatsPersistence(e??fe),createPlayStatsModel=({persistedGameStats:e,now:t=()=>Date.now()}={})=>{const g=t(),n=normalizePersistedStats(e),C=n.month??fe.month,o=toInteger(C.xpValue??C.xp,0);let I=toInteger(n.kills,0),a=null,i=toFiniteNumber(C.currentXp,null);const s=new Set,l=new Set,c=g,u={instance:{initialized:!1,startingGold:null,startingKills:I,startingXp:null,startedAt:g},session:{initialized:!1,startingGold:null,startingKills:I,startingXp:null,startedAt:g},month:{initialized:toInteger(C.year,0)>0&&toInteger(C.month,0)>0,startingGold:toInteger(C.startingGold,null),startingKills:toInteger(C.startingKills,I),startingXp:toFiniteNumber(C.startingXp,null),startedAt:c}};let d={instance:makeScope(g),session:makeScope(g),month:{...makeMonthScope(c),goldCap:toInteger(C.goldCap,0),year:toInteger(C.year,0),month:toInteger(C.month,0),xpValue:o,deaths:toInteger(C.deaths,0)}};const read2=()=>d,updateScope=(e,t)=>{if(!t||"object"!=typeof t)return;const g=d[e],n={...g,...t};Object.keys(t).some(e=>!Object.prototype.hasOwnProperty.call(g,e)||!Object.is(g[e],n[e]))&&(d={...d,[e]:n})},toPersistenceSnapshot=()=>({kills:I,month:{deaths:d.month.deaths,goldCap:d.month.goldCap,month:d.month.month,startingGold:u.month.startingGold??0,startingKills:u.month.startingKills??I,startingXp:u.month.startingXp??0,currentXp:i??0,xpValue:d.month.xpValue,year:d.month.year}}),emitRead=()=>{const e=read2();s.forEach(t=>t(e))},emitPersistenceSnapshot=()=>{const e=toPersistenceSnapshot();l.forEach(t=>t(e))},emitChange=({persist:e=!1}={})=>{emitRead(),e&&emitPersistenceSnapshot()},ensureScopeBaseline=e=>{const t=u[e];t.initialized||null==a||null==i||(t.initialized=!0,t.startingGold=a,t.startingKills=I,t.startingXp=i)},refreshScope=e=>{const t=u[e];t.initialized&&null!=t.startingGold&&null!=t.startingXp&&null!=a&&null!=i&&updateScope(e,{kills:I-t.startingKills,goldGained:a-t.startingGold,xpPercent:Number((100*(i-t.startingXp)).toFixed(2))})},refreshAllScopes=()=>{ensureScopeBaseline("instance"),ensureScopeBaseline("session"),ensureScopeBaseline("month"),refreshScope("instance"),refreshScope("session"),refreshScope("month"),emitChange({persist:!0})},incrementXpValue=e=>{!Number.isFinite(e)||e<=0||(updateScope("instance",{xpValue:d.instance.xpValue+e}),updateScope("session",{xpValue:d.session.xpValue+e}),updateScope("month",{xpValue:d.month.xpValue+e}),emitChange({persist:!0}))},setMonthGoldCap=e=>{!Number.isFinite(e)||e<0||(updateScope("month",{goldCap:e}),emitChange({persist:!0}))};return{destroy:()=>{s.clear(),l.clear()},handleAchievement:e=>{if("TotalCreaturesKilled"!==e?.name)return{requestGoldCap:!1};const t=toInteger(e?.value,I);return null!=t&&(I=t,refreshAllScopes()),{requestGoldCap:!0}},handleStatus:e=>{a=toInteger(e?.gold,a),i=toStatusXp(e)??i,refreshAllScopes()},handleTimeList:e=>{const g=toInteger(e?.mon,null),n=toInteger(e?.year,null);if(null!=g){if(g!==d.month.month||null!=n&&n!==d.month.year){const e=t();return u.month={initialized:null!=a&&null!=i,startingGold:a,startingKills:I,startingXp:i,startedAt:e},d={...d,month:{...makeMonthScope(e),year:n??0,month:g}},void emitChange({persist:!0})}updateScope("month",{year:n??d.month.year,month:g}),emitChange({persist:!0})}},processStreamEntries:e=>{Array.isArray(e)&&0!==e.length&&e.forEach(e=>{if(e?.isPrompt)return;const t=stripHtml(e?.html).trim(),g=t.match(ht);if(g)return void incrementXpValue(toInteger(g[1],0));const n=t.match(yt);n&&setMonthGoldCap(toInteger(n[1],0))})},read:read2,resetInstance:()=>{const e=t();u.instance={initialized:null!=a&&null!=i,startingGold:a,startingKills:I,startingXp:i,startedAt:e},d={...d,instance:makeScope(e)},emitChange()},snapshot:()=>cloneSnapshot(d),subscribe:e=>(s.add(e),()=>s.delete(e)),subscribePersistence:e=>(l.add(e),()=>l.delete(e)),toPersistenceSnapshot,updateInstance:e=>{updateScope("instance",e),emitChange()},updateMonth:e=>{updateScope("month",e),emitChange()},updateSession:e=>{updateScope("session",e),emitChange()}}},createPlayStatsStore=({playStatsModel:e}={})=>{const t=e??createPlayStatsModel(),g=create(()=>({...t.read(),updateInstance:e=>t.updateInstance(e),updateSession:e=>t.updateSession(e),updateMonth:e=>t.updateMonth(e),resetInstance:()=>t.resetInstance()})),refreshStats=()=>{g.setState(t.read())},n=t.subscribe(refreshStats);return Object.defineProperty(g,"destroy",{value:()=>{n()},enumerable:!1}),g},createRoomStore=({roomModel:e,eventBus:t})=>{const readRoom=()=>e.read?.()??e.snapshot(),g=create(()=>({...readRoom(),updateRoom:t=>e.update(t)})),refreshRoom=()=>{g.setState(readRoom())};return t.on(O.ROOM_UPDATED,refreshRoom),g},normalizeTarget=e=>{if(null==e)return null;if("string"==typeof e){const t=e.trim();return t.length>0?t:null}return"object"!=typeof e||Array.isArray(e)?e:"target"in e?normalizeTarget(e.target):null},createStatsStore=({statsModel:e,eventBus:t})=>{const g=create(()=>({...e.read(),target:null,updateStats:t=>e.update(t)})),refreshStats=()=>{g.setState(e.read())};return t.on(O.STATS_UPDATED,refreshStats),t.on(O.TARGET_CHANGED,e=>{g.setState({target:normalizeTarget(e)})}),g},immer=e=>(t,g,n)=>(n.setState=(e,g,...n)=>{const C="function"==typeof e?b(e):e;return t(C,g,...n)},e(n.setState,g,n)),bt=Object.freeze({purpleGalaxy:"https://cdn.pixabay.com/photo/2018/12/18/22/30/background-3883188_960_720.jpg",blueGalaxy:"https://cdn.pixabay.com/photo/2022/06/08/05/47/stars-7249785_960_720.jpg",orangeGalaxy:"https://cdn.pixabay.com/photo/2015/08/28/11/27/space-911785_960_720.jpg",greenGalaxy:"https://cdn.pixabay.com/photo/2017/08/15/08/23/stars-2643089_960_720.jpg",stars:"https://s3-us-west-2.amazonaws.com/s.cdpn.io/1231630/stars.png",darkForest:"https://i.pinimg.com/originals/44/6e/3b/446e3b79395a287ca32f7977dd83b290.jpg"}),vt=Object.freeze(Object.keys(bt)),xt=new Map(Object.entries(bt).map(([e,t])=>[t,e])),canonicalizeBackgroundImageValue=e=>{if("string"!=typeof e)return"";const t=e.trim();return t?Object.hasOwn(bt,t)?t:xt.get(t)??t:""},resolveBackgroundImageSource=e=>{const t=canonicalizeBackgroundImageValue(e);return bt[t]??t},St=deepFreeze({background:{primary:"#0d0d0d",panel:"#141414",header:"#1a1a1a",modal:"#1e1e1e"},text:{primary:"#FFF5D6",secondary:"#C0B090",muted:"#706050",accent:"#FFD700"},game:{hp:"#e05555",mp:"#5588e0",ep:"#55c055",wp:"#e0a035",nl:"#a055e0",timerActive:"#55aaff",timerCritical:"#ff5533"},spacing:{unit:4},radius:{panel:4,tag:2},theme:{backgroundImage:"",fontSize:12,displayFontFamily:se,displayFontSize:le,backgroundOpacity:.5,hue:0},replacement:{bracketAllyColor:"#ffffff",bracketEnemyColor:"#ff0000",targetBorderColor:"rgb(255, 0, 0)",selfNameColor:"lightpink",infoColor:"cadetblue",unknownNameColor:"grey",npcTagBracketColor:"red",damageNumberBracketColor:"#808080"}}),cloneTokens$1=e=>structuredClone(e),mergeTokenPatch=(e,t)=>{const g=cloneTokens$1(e);if(!isPlainObject$1(t))return g;const applyPatch=(e,t)=>{for(const[g,n]of Object.entries(t))void 0!==n&&(Array.isArray(n)?e[g]=structuredClone(n):isPlainObject$1(n)&&isPlainObject$1(e[g])?applyPatch(e[g],n):e[g]=structuredClone(n))};return applyPatch(g,t),g},normalizeThemeTokens=e=>{if(!isPlainObject$1(e))return e;const t={...e};return Object.hasOwn(e,"backgroundImage")&&(t.backgroundImage=canonicalizeBackgroundImageValue(e.backgroundImage)),Object.hasOwn(e,"displayFontFamily")&&(t.displayFontFamily=normalizeDisplayFontFamily(e.displayFontFamily)),Object.hasOwn(e,"displayFontSize")&&(t.displayFontSize=normalizeDisplayFontSize(e.displayFontSize)),{...t}},normalizeTokens=e=>({...e,theme:normalizeThemeTokens(e.theme)}),createThemeStore=({eventBus:e,persistenceStore:t}={})=>{const g=t&&"function"==typeof t.get?normalizeThemeTokens(t.get("theme")):void 0,n=normalizeTokens(mergeTokenPatch(St,{theme:g})),C=create(immer(()=>({tokens:n,updateTokens:g=>{const n=normalizeTokens(mergeTokenPatch(C.getState().tokens,g));t&&"function"==typeof t.set&&t.set("theme",n.theme),C.setState({tokens:n}),e.emit(L.THEME_CHANGED,{tokens:cloneTokens$1(n)})},resetTokens:()=>{const g=cloneTokens$1(St);t&&"function"==typeof t.set&&t.set("theme",g.theme),C.setState({tokens:g}),e.emit(L.THEME_CHANGED,{tokens:cloneTokens$1(g)})}})));return C},createTimerStore=({timerModel:e,eventBus:t})=>{const readTimers=()=>e.read?.()??e.snapshot(),g=create(()=>({timers:readTimers(),addTimer:(t,g,n="",C)=>e.add(t,g,n,C),removeTimer:t=>e.remove(t),clearAll:()=>e.clearAll()})),refreshTimers=()=>{g.setState({timers:readTimers()})};return t.on(O.TIMER_STARTED,refreshTimers),t.on(O.TIMER_UPDATED,refreshTimers),t.on(O.TIMER_EXPIRED,refreshTimers),t.on(O.TIMER_CLEARED,refreshTimers),g},createUiStore=({persistenceStore:e}={})=>create(immer(t=>({activeTab:{},modalOpen:null,settings:e?.get?.("ui")??{},netflixMode:!1,setActiveTab:(e,g)=>t(t=>{t.activeTab[e]=g}),openModal:e=>t({modalOpen:e}),closeModal:()=>t({modalOpen:null}),setSetting:(g,n)=>t(t=>{t.settings[g]=n,e?.set?.("ui",t.settings)}),setNetflixMode:e=>t(t=>{t.netflixMode=Boolean(e)})}))),createMessageRegistry=()=>{const e=new Map;return{register:(t,g)=>(e.set(t,g),g),lookup:t=>e.get(t)??null,listTypes:()=>[...e.keys()].sort((e,t)=>e.localeCompare(t))}},wt=["#000000","#800000","#008000","#808000","#000080","#800080","#008080","#c0c0c0","#808080","#ff0000","#00ff00","#ffff00","#0000ff","#ff00ff","#00ffff","#ffffff"],Et=[0,95,135,175,215,255],hex2=e=>e.toString(16).padStart(2,"0"),Rt={};for(let wl=0;wl<16;wl++)Rt[wl]=wt[wl];for(let wl=16;wl<=231;wl++){const e=wl-16,t=Math.floor(e/36),g=Math.floor(e%36/6),n=e%6,C=Et[t],o=Et[g],I=Et[n];Rt[wl]=`#${hex2(C)}${hex2(o)}${hex2(I)}`}for(let wl=232;wl<=255;wl++){const e=8+10*(wl-232);Rt[wl]=`#${hex2(e)}${hex2(e)}${hex2(e)}`}const kt=/\x1b\[([0-9;]*)m|([^\x1b]+)/g,stdColor=(e,t)=>Rt[t?e+8:e],parseAnsi=e=>{const t=[];let g,n=null,C=null,o=!1;for(kt.lastIndex=0;null!==(g=kt.exec(e));){if(void 0!==g[2]){t.push({text:g[2],fg:n,bg:C,bold:o});continue}const e=g[1],I=0===e.length?[0]:e.split(";").map(Number);let a=0;for(;a<I.length;){const e=I[a];0===e?(n=null,C=null,o=!1):1===e?o=!0:e>=30&&e<=37?n=stdColor(e-30,o):e>=40&&e<=47?C=stdColor(e-40,!1):e>=90&&e<=97?n=Rt[e-90+8]:e>=100&&e<=107?C=Rt[e-100+8]:38===e&&5===I[a+1]&&void 0!==I[a+2]?(n=Rt[I[a+2]]??null,a+=2):48===e&&5===I[a+1]&&void 0!==I[a+2]&&(C=Rt[I[a+2]]??null,a+=2),a++}}return t},Mt=/\x1b\[[0-9;]*m/g,Tt=/^\d+h,\s*\d+m,\s*\d+e,\s*\d+w/,parsePromptLine=e=>{const t=e.replace(Mt,"").trim();return{isPrompt:Tt.test(t),text:t}},renderCombatLine=e=>{const t=resolveTimestamp(e);return createDisplayLine({html:renderStructuredRowHtml(e,"combat"),timestamp:t,isPrompt:!1,isMonospace:!1,shouldLog:e.shouldLog??!0,buffer:"combat"})},renderSystemLine=e=>{const t=resolveTimestamp(e);return createDisplayLine({html:renderStructuredRowHtml(e,"system"),timestamp:t,isPrompt:!1,isMonospace:!1,shouldLog:e.shouldLog??!0,buffer:"system"})},Pt=Object.freeze({main:renderColorLine,system:renderSystemLine,combat:renderCombatLine,replacement:renderReplacementLine}),isMessageInput=e=>Boolean(e&&"object"==typeof e&&!Array.isArray(e)&&"string"==typeof e.event&&Object.prototype.hasOwnProperty.call(e,"payload")),parseRawLine=(e,t,g)=>{const n=t(e),C=g(e);return{type:"main",buffer:"main",segments:n,metadata:{text:C.text,source:"raw"},isPrompt:C.isPrompt,isMonospace:C.isPrompt,shouldLog:!0}},withTimestamp=(e,t)=>null!=e.timestamp||null!=e.metadata?.timestamp?e:{...e,timestamp:t()},validateDependencies=(e,t,g)=>{if(!e||"function"!=typeof e.addLines)throw new TypeError("createMessagePipeline requires a streamModel with addLines(lines).");if(null!=g&&"function"!=typeof g.addLines)throw new TypeError("createMessagePipeline side transcript models must expose addLines(lines).");if(!t||"function"!=typeof t.register||"function"!=typeof t.lookup)throw new TypeError("createMessagePipeline requires a registry with register(type, renderer) and lookup(type).")},createMessagePipeline=({streamModel:e,registry:t=createMessageRegistry(),parseAnsi:g=parseAnsi,parsePromptLine:n=parsePromptLine,parseStreamEventLine:C=parseStreamEventLine,renderColorLine:o=Pt.main,renderCombatLine:I=Pt.combat,renderReplacementLine:a=Pt.replacement,renderSystemLine:i=Pt.system,systemStreamModel:s=null,combatStreamModel:l=null,now:c=Date.now})=>{validateDependencies(e,t,s),validateDependencies(e,t,l),t.register("main",o),t.register("system",i),t.register("combat",I),t.register("replacement",a);const resolveTargetModel2=t=>"system"===t?s??e:"combat"===t?l??e:e,renderAndStore=e=>{if(!e)return null;const g=t.lookup(e.type);if(!g)return null;const n=g(withTimestamp(e,c));return resolveTargetModel2(n?.buffer??e.buffer).addLines([n]),n};function process(e,t){return"string"==typeof e&&1===arguments.length?renderAndStore(parseRawLine(e,g,n)):"string"==typeof e&&arguments.length>1?renderAndStore(C(e,t)):isMessageInput(e)?renderAndStore(C(e.event,e.payload)):null}return{process,registry:t}},parseLevel=e=>{if("number"==typeof e&&Number.isFinite(e))return e;if("string"!=typeof e)return 0;const t=e.match(/\d+/);return t?Number.parseInt(t[0],10):0},buildVitalsStatsPatch=e=>isPlainObject$1(e)?{hp:{current:toNumber(e.hp),max:toNumber(e.maxhp)},mp:{current:toNumber(e.mp),max:toNumber(e.maxmp)},ep:{current:toNumber(e.ep),max:toNumber(e.maxep)},wp:{current:toNumber(e.wp),max:toNumber(e.maxwp)},nl:{current:toNumber(e.nl),max:toNumber(e.maxnl,100)}}:null,buildVitalsCharacterPatch=e=>isPlainObject$1(e)?{balance:toBooleanFlag(e.bal),equilibrium:toBooleanFlag(e.eq),...buildCharacterDetailPatch(e)??{}}:null,buildStatusSync=e=>{if(!isPlainObject$1(e))return null;const t=toPercent(e.xp),g=toTrimmedString(e.class);return{statsPatch:{gold:toNumber(e.gold),bank:toNumber(e.bank),...null==t?{}:{xp:t,xpToNext:Math.max(0,100-t)}},characterPatch:{...toTrimmedString(e.name)?{name:e.name.trim()}:{},level:parseLevel(e.level),...buildCharacterDetailPatch(e)??{}},className:g,target:extractTargetLabel(e.target),city:toTrimmedString(e.city)}},isBridgeEnvelope=e=>isPlainObject$1(e)&&"string"==typeof e.event&&Object.prototype.hasOwnProperty.call(e,"data"),isTargetClearEvent=(e,t)=>"IRE.Target.Set"===e?!extractTargetId(t):"nexsys4.system.target.changed"===e&&isPlainObject$1(t)&&!extractTargetId(t)&&!extractTargetLabel(t),createGmcpIngressController=({adapter:e,eventBus:t,timerModel:g,streamModel:n,systemStreamModel:C,combatStreamModel:o,statsModel:I,partyModel:a,roomModel:i,characterModel:s,defenceModel:l,classBalanceController:c,playerDirectory:u,targetSyncModel:d=createTargetSyncModel({characterModel:s,getHostTarget:()=>"function"==typeof e?.getTarget?e.getTarget():null}),roomOccupantsModel:p=createRoomOccupantsModel({roomModel:i,playerDirectory:u}),partyAutomationModel:m=createPartyAutomationModel({characterModel:s,partyModel:a,playerDirectory:u,sendCommand:t=>e.send(t)})}={})=>{const h=createMessagePipeline({streamModel:n,systemStreamModel:C,combatStreamModel:o}),y=[],subscribe=(e,g)=>{y.push(t.on(e,g))},processDisplayBridge=e=>{isBridgeEnvelope(e)&&h.process(e.event,e.data)};return subscribe(D.STREAM_LINE,e=>{isBridgeEnvelope(e)&&(applyCharacterAfflictionEvent(s,e.event,e.data),m.processEvent(e.event,e.data),processDisplayBridge(e))}),subscribe(D.TIMER_STARTED,e=>{if(!isBridgeEnvelope(e)||"nexSkillMatch"!==e.event)return;if("self"!==e.data?.user)return;const t=toTrimmedString(e.data?.id);if(!t)return;const n=g.get(t);n&&g.start(n.id)}),subscribe(D.DEFENCE_GAINED,e=>{if(!isBridgeEnvelope(e))return;const t=extractNamedValue(e.data);t&&l.gain(t),processDisplayBridge(e)}),subscribe(D.DEFENCE_LOST,e=>{if(!isBridgeEnvelope(e))return;const t=extractNamedValue(e.data);t&&l.lose(t),processDisplayBridge(e)}),subscribe(D.TARGET_CHANGED,e=>{if(isBridgeEnvelope(e)){if(isTargetClearEvent(e.event,e.data))return d.clear(),void processDisplayBridge(e);d.sync({targetValue:e.data,reset:"IRE.Target.Set"===e.event}),processDisplayBridge(e)}}),subscribe(D.STATS_UPDATED,e=>{if(isBridgeEnvelope(e)){if("Char.Vitals"===e.event){const t=buildVitalsStatsPatch(e.data),g=buildVitalsCharacterPatch(e.data),n=c.updateFromVitals(e.data);t&&I.update(t),(g||n)&&s.update({...g??{},...n??{}})}if("Char.Status"===e.event){const t=buildStatusSync(e.data);if(!t)return;I.update(t.statsPatch),s.update(t.characterPatch),a.setSelf(t.characterPatch.name??e.data?.name),u.rememberPlayerStatus({...e.data,name:t.characterPatch.name??e.data?.name,city:t.city,fullname:e.data?.fullname}),t.className&&s.setClass(t.className),s.setTarget(t.target)}}}),subscribe(D.ROOM_UPDATED,e=>{isBridgeEnvelope(e)&&p.apply(e.event,e.data)}),subscribe(D.CLASS_CHANGED,e=>{if(!isBridgeEnvelope(e))return;const t=toTrimmedString(e.data?.class)??toTrimmedString(e.data);t&&s.setClass(t)}),Object.freeze({destroy:()=>{y.forEach(e=>e?.())}})},Nt=Object.freeze({}),areDisplayHostSettingsEqual=(e,t)=>e.showPrompts===t.showPrompts&&e.showTimestamps===t.showTimestamps,freezeDisplayHostSettings=e=>Object.freeze(e),readDisplayHostSettings=e=>{const t=e?.()??Nt;return freezeDisplayHostSettings({showPrompts:Boolean(t.show_prompts),showTimestamps:Boolean(t.show_timestamps)})},resolvePayloadSnapshot$2=(e,t)=>{if(!t||"object"!=typeof t||"string"!=typeof t.key)return null;if(!("value"in t))return null;switch(t.key){case"show_prompts":{const g=Boolean(t.value);return g===e.showPrompts?e:freezeDisplayHostSettings({...e,showPrompts:g})}case"single_prompt":{const g=!Boolean(t.value);return g===e.showPrompts?e:freezeDisplayHostSettings({...e,showPrompts:g})}case"show_timestamps":{const g=Boolean(t.value);return g===e.showTimestamps?e:freezeDisplayHostSettings({...e,showTimestamps:g})}default:return null}},createHostDisplaySettingsModel=({eventBus:e,readHostSettings:t})=>{if(!e||"function"!=typeof e.on)throw new Error("createHostDisplaySettingsModel requires an eventBus with on(topic, listener).");if("function"!=typeof t)throw new Error("createHostDisplaySettingsModel requires readHostSettings().");let g=readDisplayHostSettings(t);const n=new Set,notifyListeners=()=>{for(const e of n)e()},commitSnapshot=e=>(!e||areDisplayHostSettingsEqual(g,e)||(g=e,notifyListeners()),g),syncFromHost=()=>commitSnapshot(readDisplayHostSettings(t)),handleHostSettingsChanged=e=>{const t=resolvePayloadSnapshot$2(g,e);t&&commitSnapshot(t)},C=e.on(L.HOST_SETTINGS_CHANGED,handleHostSettingsChanged),o=e.on(L.SYSTEM_PHASE,syncFromHost),subscribe=e=>(n.add(e),()=>{n.delete(e)}),getSnapshot=()=>g,destroy=()=>{C?.(),o?.(),n.clear()};return Object.freeze({destroy,getSnapshot,subscribe})},Ot=Object.freeze({}),areHostSettingsEqual=(e,t)=>e.echo_input===t.echo_input&&e.echo_gmcp===t.echo_gmcp&&e.single_prompt===t.single_prompt&&e.show_timestamps===t.show_timestamps,freezeHostSettings=e=>Object.freeze(e),readHostSettingsFromHost=e=>{const t=e?.()??Ot;return freezeHostSettings({echo_input:Boolean(t.echo_input),echo_gmcp:Boolean(t.echo_gmcp),single_prompt:!Boolean(t.show_prompts),show_timestamps:Boolean(t.show_timestamps)})},resolvePayloadSnapshot$1=(e,t)=>{if(!t||"object"!=typeof t||"string"!=typeof t.key)return null;if(!("value"in t))return null;switch(t.key){case"echo_input":{const g=Boolean(t.value);return g===e.echo_input?e:freezeHostSettings({...e,echo_input:g})}case"echo_gmcp":{const g=Boolean(t.value);return g===e.echo_gmcp?e:freezeHostSettings({...e,echo_gmcp:g})}case"single_prompt":{const g=Boolean(t.value);return g===e.single_prompt?e:freezeHostSettings({...e,single_prompt:g})}case"show_prompts":{const g=!Boolean(t.value);return g===e.single_prompt?e:freezeHostSettings({...e,single_prompt:g})}case"show_timestamps":{const g=Boolean(t.value);return g===e.show_timestamps?e:freezeHostSettings({...e,show_timestamps:g})}default:return null}},createHostSettingsModel=({eventBus:e,readHostSettings:t})=>{if(!e||"function"!=typeof e.on)throw new Error("createHostSettingsModel requires an eventBus with on(topic, listener).");if("function"!=typeof t)throw new Error("createHostSettingsModel requires readHostSettings().");let g=readHostSettingsFromHost(t);const n=new Set,notifyListeners=()=>{for(const e of n)e()},commitSnapshot=e=>(!e||areHostSettingsEqual(g,e)||(g=e,notifyListeners()),g),syncFromHost=()=>commitSnapshot(readHostSettingsFromHost(t)),handleHostSettingsChanged=e=>{const t=resolvePayloadSnapshot$1(g,e);t&&commitSnapshot(t)},C=e.on(L.HOST_SETTINGS_CHANGED,handleHostSettingsChanged),o=e.on(L.SYSTEM_PHASE,syncFromHost),subscribe=e=>(n.add(e),()=>{n.delete(e)}),getSnapshot=()=>g,destroy=()=>{C?.(),o?.(),n.clear()};return Object.freeze({destroy,getSnapshot,subscribe})},Dt=Object.freeze({}),areHostLayoutsEqual=(e,t)=>e.display_tabstrip===t.display_tabstrip,freezeHostLayout=e=>Object.freeze(e),readHostLayoutFromHost=e=>{const t=e?.()??Dt;return freezeHostLayout({display_tabstrip:"boolean"!=typeof t.tabSetEnableTabStrip||t.tabSetEnableTabStrip})},resolvePayloadSnapshot=(e,t)=>{if(!t||"object"!=typeof t||"string"!=typeof t.key)return null;if(!("value"in t))return null;if("display_tabstrip"===t.key){const g=Boolean(t.value);return g===e.display_tabstrip?e:freezeHostLayout({...e,display_tabstrip:g})}return null},createHostLayoutModel=({eventBus:e,readHostLayout:t})=>{if(!e||"function"!=typeof e.on)throw new Error("createHostLayoutModel requires an eventBus with on(topic, listener).");if("function"!=typeof t)throw new Error("createHostLayoutModel requires readHostLayout().");let g=readHostLayoutFromHost(t);const n=new Set,notifyListeners=()=>{for(const e of n)e()},commitSnapshot=e=>(!e||areHostLayoutsEqual(g,e)||(g=e,notifyListeners()),g),syncFromHost=()=>commitSnapshot(readHostLayoutFromHost(t)),handleHostSettingsChanged=e=>{const t=resolvePayloadSnapshot(g,e);t?commitSnapshot(t):syncFromHost()},C=e.on(L.HOST_SETTINGS_CHANGED,handleHostSettingsChanged),o=e.on(L.SYSTEM_PHASE,syncFromHost),subscribe=e=>(n.add(e),()=>{n.delete(e)}),getSnapshot=()=>g,destroy=()=>{C?.(),o?.(),n.clear()};return Object.freeze({destroy,getSnapshot,subscribe})},hasPersistenceAdapter=e=>e&&"function"==typeof e.getVariable&&"function"==typeof e.setVariable,createPlayStatsPersistence=({adapter:e}={})=>{if(!hasPersistenceAdapter(e))return null;const t=createPersistenceStore({adapter:e,sliceKey:pe.GAME_STATS,schema:fe,migrate:migrateGameStatsPersistence});return{read:()=>t.getAll(),write:e=>{t.set("kills",e?.kills??0),t.set("month",e?.month??{})}}},safeUnsubscribe=e=>{"function"==typeof e&&e()},resolveStreamEntries=(e,t)=>{const g=e.getSnapshot(),n=Array.isArray(g?.buffer)?g.buffer:[];if(0===n.length)return{entries:[],lastProcessedStreamId:-1};const C=n.filter(e=>e.id>t);return{entries:C,lastProcessedStreamId:C.length>0?C[C.length-1].id:t}},createPlayStatsController=({adapter:e,now:t,persistence:g=createPlayStatsPersistence({adapter:e}),streamModel:n}={})=>{const C=createPlayStatsModel({persistedGameStats:g?.read?.(),now:t}),o=[];let I=-1,a=!1;if(g&&"function"==typeof g.write&&o.push(C.subscribePersistence(e=>{g.write(e)})),e&&"function"==typeof e.on&&(o.push(e.on("Char.Status",C.handleStatus)),o.push(e.on("IRE.Misc.Achievement",t=>{const g=C.handleAchievement(t);g?.requestGoldCap&&"function"==typeof e.send&&e.send("goldcap")})),o.push(e.on("IRE.Time.List",C.handleTimeList))),n&&"function"==typeof n.subscribe&&"function"==typeof n.getSnapshot){const processStreamSnapshot=()=>{const e=resolveStreamEntries(n,I);I=e.lastProcessedStreamId,C.processStreamEntries(e.entries)};o.push(n.subscribe(processStreamSnapshot))}return{destroy:()=>{a||(a=!0,o.splice(0).forEach(safeUnsubscribe))},model:C}},jt=t.createContext(null),useNexGui=()=>{const e=t.useContext(jt);if(null===e)throw new Error("useNexGui must be used inside NexGuiContext.Provider");return e},NexGuiMountRoot=()=>null,createReactMountLifecycle=({contextValue:e,RootComponent:n=NexGuiMountRoot}={})=>{const C=new Map;let o=!1;const unmountContainer=e=>{const t=C.get(e);t&&(C.delete(e),t.unmount())},mount=I=>{if(o)throw new Error("[nexGui4] Cannot mount a destroyed nexGui instance.");if(!I||"object"!=typeof I||1!==I.nodeType)throw new TypeError("[nexGui4] mount(container) requires a DOM element container.");unmountContainer(I);const a=g.createRoot(I);return C.set(I,a),a.render(t.createElement(jt.Provider,{value:e},t.createElement(n))),{unmount:()=>{unmountContainer(I)}}},destroy=()=>{if(!o){o=!0;for(const e of[...C.keys()])unmountContainer(e)}};return Object.freeze({mount,destroy,isMounted:()=>C.size>0})},NOOP$1=()=>{},normalizeCommand=e=>"function"==typeof e?e:NOOP$1,createPlatformTabsController=()=>{let e=NOOP$1,t=NOOP$1,g=NOOP$1,n=NOOP$1,C=NOOP$1,hasSavedLayout2=()=>!1;const resetNativeDisplayCommands=()=>{e=NOOP$1,t=NOOP$1},resetLayoutCommands=()=>{g=NOOP$1,n=NOOP$1,C=NOOP$1,hasSavedLayout2=()=>!1};return Object.freeze({mountNativeDisplay:(...t)=>e(...t),unmountNativeDisplay:(...e)=>t(...e),configureNativeDisplayCommands:(g={})=>{const n=normalizeCommand(g.mountNativeDisplay),C=normalizeCommand(g.unmountNativeDisplay);return e=n,t=C,()=>{e===n&&t===C&&resetNativeDisplayCommands()}},resetNativeDisplayCommands,applyLayoutPreset:(...e)=>g(...e),saveLayout:(...e)=>n(...e),restoreLayout:(...e)=>C(...e),hasSavedLayout:(...e)=>hasSavedLayout2(...e),configureLayoutCommands:(e={})=>{const t=normalizeCommand(e.applyLayoutPreset),o=normalizeCommand(e.saveLayout),I=normalizeCommand(e.restoreLayout),a="function"==typeof e.hasSavedLayout?e.hasSavedLayout:()=>!1;return g=t,n=o,C=I,hasSavedLayout2=a,()=>{g===t&&n===o&&C===I&&hasSavedLayout2===a&&resetLayoutCommands()}},resetLayoutCommands})};v(!1);const zt="4.0.0",resolveRuntimePorts=(e={})=>{const t=createBrowserRuntimePorts(),g=e&&"object"==typeof e?e:{};return Object.freeze({...t,...g})},resolveConfiguredDefenceList=e=>normalizeConfiguredDefenceList(e.getConfiguredDefences?.()),seedInitialDisplayTheme=({adapter:e,persistenceStore:t})=>{const g=e.getVariable(de);if(void 0!==g?.settings)return;const n=e.getHostSettings?.()??{},C=t.get("theme");t.set("theme",{...C,displayFontFamily:readHostDisplayFontFamily(n),displayFontSize:readHostDisplayFontSize(n)})},withRelationshipCommandTracking=(e,t)=>{const g=assertAdapterContract(e);if(!t||"function"!=typeof t.trackRelationshipCommand)return g;const n=Object.create(g),C=g.send.bind(g);return Object.defineProperty(n,"send",{value:e=>(t.trackRelationshipCommand(e),C(e)),enumerable:!0}),assertAdapterContract(n)},resolveAdapter=({adapter:e,playerRelationships:t}={})=>withRelationshipCommandTracking(e??createNexusAdapter(),t),createNexGui=({adapter:e,debugEnabled:t=!1,traceLimit:g=500,autoStart:n=!0,playerDirectory:C,playerRelationships:o,startupPhaseHandlers:I,remoteService:a,runtimePorts:i}={})=>{const s=resolveRuntimePorts(i),l=o??createPlayerRelationshipsModel(),c=resolveAdapter({adapter:e,playerRelationships:l}),u=createEventBus({label:"nexgui4",debugEnabled:t,traceLimit:g}),d=C??createPlayerDirectoryModel({fetchImpl:s.fetch,now:s.now}),p=createPlayerDirectoryDiagnosticsModel({now:s.now}),m=createPlayerDirectoryLifecycle({playerDirectory:d,diagnostics:p,readCache:()=>(c.getVariable(de)||{})[pe.PLAYER_DIRECTORY],writeCache:(e,t)=>{const g=c.getVariable(de)||{};g[pe.PLAYER_DIRECTORY]=t,c.setVariable(de,g)}}),h=createPlatformTabsController(),y=createHostDisplaySettingsModel({eventBus:u,readHostSettings:()=>c.getHostSettings?.()??{}}),b=createHostSettingsModel({eventBus:u,readHostSettings:()=>c.getHostSettings?.()??{}}),v=createHostLayoutModel({eventBus:u,readHostLayout:()=>c.getHostLayoutSnapshot?.()??{}}),x=createTimerModel({eventBus:u,now:s.now,setTimer:s.setTimeout,clearTimer:s.clearTimeout}),S=createIndexedDbManager(),w=createScrollbackSessionStore({storage:S,setTimeoutFn:s.setTimeout,clearTimeoutFn:s.clearTimeout,logger:console}),E=createStreamModel({onAppend:e=>w.append(e),onClear:()=>{w.clear().catch(e=>{console.error("[nexGui4] Failed to clear scrollback session.",e)})}}),R=createTranscriptModel({cap:5e3}),M=createTranscriptModel({cap:5e3}),T=createStatsModel({eventBus:u}),P=createPartyModel({eventBus:u}),N=createRoomModel({eventBus:u}),O=createCharacterModel({eventBus:u}),D=createDefenceModel({eventBus:u}),j=createFeedModel({cap:5e3}),G=createClassBalanceController(),B=createTargetSyncModel({characterModel:O,getHostTarget:()=>"function"==typeof c.getTarget?c.getTarget():null}),F=createRoomOccupantsModel({roomModel:N,playerDirectory:d}),W=createPlayStatsController({adapter:c,streamModel:E,now:s.now}),V=createPartyAutomationModel({characterModel:O,partyModel:P,playerDirectory:d,sendCommand:e=>c.send(e)}),K=resolveConfiguredDefenceList(c),U="function"==typeof c.getTarget?c.getTarget():null;isPlainObject$1(U)&&B.sync({targetValue:U,hostTargetValue:U,reset:!0});const H=createPersistenceStore({adapter:c,sliceKey:pe.SETTINGS});seedInitialDisplayTheme({adapter:c,persistenceStore:H});const Y=createPersistenceStore({adapter:c,sliceKey:pe.UI,schema:he,migrate:migrateUiPersistence});for(const[L,Ae]of Object.entries(H.get("party")))P.setSetting(L,Ae);u.on(L.PARTY_UPDATED,({settings:e})=>{H.set("party",e)});const Z=createGmcpIngressController({adapter:c,eventBus:u,timerModel:x,streamModel:E,systemStreamModel:R,combatStreamModel:M,statsModel:T,partyModel:P,roomModel:N,characterModel:O,defenceModel:D,classBalanceController:G,playerDirectory:d,targetSyncModel:B,roomOccupantsModel:F,partyAutomationModel:V}),Q=createDefenceStore({defenceModel:D,eventBus:u,configuredDefences:K}),X=Object.freeze({timers:createTimerStore({timerModel:x,eventBus:u}),stream:E,stats:createStatsStore({statsModel:T,eventBus:u}),party:createPartyStore({partyModel:P,eventBus:u}),room:createRoomStore({roomModel:N,eventBus:u}),character:createCharacterStore({characterModel:O,eventBus:u}),defence:Q,theme:createThemeStore({eventBus:u,persistenceStore:H}),ui:createUiStore({persistenceStore:H}),feed:createFeedStore({feedModel:j}),playStats:createPlayStatsStore({playStatsModel:W.model}),systemStream:R,combatStream:M}),q=registerGmcpBindings({adapter:c,eventBus:u,playerDirectory:d,playerDirectoryLifecycle:m,playerRelationships:l,playerDirectoryDiagnostics:p,remoteService:a,fetchFn:s.fetch}),J={adapter:c,eventBus:u,hostDisplaySettingsModel:y,hostSettingsModel:b,hostLayoutModel:v,playerDirectory:d,playerDirectoryLifecycle:m,playerDirectoryDiagnostics:p,playerRelationships:l,stores:X,streamModel:E,scrollbackSession:w,persistenceStore:H,scrollbackLayoutStore:Y,platformTabs:h,formatInlineNames:e=>highlightInlineNamesInText(e,{contextValue:J})},$=createReactMountLifecycle({contextValue:J});let _=!1,ee=null;const initializeScrollbackSession=async()=>{try{if(await w.initialize(),_)return;await w.clear()}catch(e){if(_)return;console.warn("[nexGui4] Scrollback session startup degraded; continuing.",e)}},te={...I,[$e.PREPARING]:async e=>{await initializeScrollbackSession(),await(I?.[$e.PREPARING]?.(e))}},ge=createStartupOrchestrator({adapter:c,eventBus:u,phaseHandlers:te,setTimeoutFn:s.setTimeout,clearTimeoutFn:s.clearTimeout}),startRuntime=()=>(ee??=ge.start(),ee.catch(()=>{}),ee),mount=e=>{if(_)throw new Error("[nexGui4] Cannot mount a destroyed nexGui instance.");return $.mount(e)},destroy=()=>{_||(_=!0,$.destroy(),ge.destroy(),y.destroy(),b.destroy(),v.destroy(),q?.(),Z.destroy(),W.destroy(),X.playStats.destroy?.(),u.emit(L.SYSTEM_DESTROYED,{version:zt}),x.destroy(),j.destroy(),P.destroy(),N.destroy(),T.destroy(),O.destroy(),D.destroy(),W.model.destroy(),G.destroy(),w.destroy(),m.destroy?.(),d.destroy?.(),l.destroy?.(),clearRelationshipNameFormatterCache(J),clearMessageReplacementContextCache(),h.resetNativeDisplayCommands(),h.resetLayoutCommands(),c.destroy(),u.clear())},re=composePublicApi({version:zt,startupOrchestrator:ge,isMounted:()=>$.isMounted(),character:{characterModel:O,getTarget:()=>"function"==typeof c.getTarget?c.getTarget():null,setTarget:e=>{c.setTarget(e)},syncTarget:e=>B.sync(e),clearTarget:()=>B.clear()},timerModel:x,players:{playerDirectory:d,getPlayer:d.getPlayerProfile,listPlayers:d.getAllPlayerProfiles,getPlayerColor:d.getPlayerColor,refreshPlayer:d.refreshPlayerProfile},colors:{cityPalette:Ae,iconHtml:(e,t,g)=>buildIconHtml(e,t,g,s.getPublicDualToneIcons?.()??null)},customize:{getConfiguredDefences:()=>X.defence.getState().configuredDefences,setConfiguredDefences:e=>(X.defence.getState().setConfiguredDefences(normalizeConfiguredDefenceList(e)),X.defence.getState().configuredDefences),classBalanceController:G,setClassBalanceType:e=>{const t=G.setType(e);return O.update(t),G.getType()},mountNativeDisplay:()=>h.mountNativeDisplay(),unmountNativeDisplay:()=>h.unmountNativeDisplay()},layout:{presetIds:ft,applyPreset:e=>h.applyLayoutPreset(e),saveLayout:()=>h.saveLayout(),restoreLayout:()=>h.restoreLayout(),hasSavedLayout:()=>h.hasSavedLayout()},party:{partyModel:P,getSnapshot:()=>P.snapshot()},room:{roomModel:N,setItemOverride:setUserRoomItemOverride,removeItemOverride:removeUserRoomItemOverride,listItemOverrides:listUserRoomItemOverrides,getItemOverride:getUserRoomItemOverride},stats:{playStatsModel:W.model},stream:{systemStream:X.systemStream,combatStream:X.combatStream}}),ne={version:zt,mount,stores:X,debug:{getEventTrace:()=>u.getTrace(),setDebugEnabled:e=>u.setDebugEnabled(e),stream:{getStats:()=>({...E.getStats(),scrollbackSession:w.getStats()}),getScrollbackStats:()=>w.getStats(),getDbStats:async()=>{try{const e=await w.readAll(),t=w.getStats();return{fallback:t.storageFallback,count:e.length,firstId:e[0]?.id,lastId:e[e.length-1]?.id,scrollbackSession:t}}catch(e){return{error:e.message}}}},playerDirectory:{getSnapshot:()=>p.getPlayerDirectoryDiagnosticsSnapshot()}},destroy};return Object.defineProperty(ne,"state",{enumerable:!0,get:()=>re.state}),Object.defineProperty(ne,"api",{value:re.api,enumerable:!0}),Object.defineProperty(ne,"__contextValue",{value:J,enumerable:!1}),Object.defineProperty(ne,"__start",{value:startRuntime,enumerable:!1}),n&&startRuntime(),ne};function formatMuiErrorMessage(e,...t){const g=new URL(`https://mui.com/production-error/?code=${e}`);return t.forEach(e=>g.searchParams.append("args[]",e)),`Minified MUI error #${e}; visit ${g} for the full message.`}function _extends(){return _extends=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var g=arguments[t];for(var n in g)({}).hasOwnProperty.call(g,n)&&(e[n]=g[n])}return e},_extends.apply(null,arguments)}function sheetForTag(e){if(e.sheet)return e.sheet;for(var t=0;t<document.styleSheets.length;t++)if(document.styleSheets[t].ownerNode===e)return document.styleSheets[t]}function createStyleElement(e){var t=document.createElement("style");return t.setAttribute("data-emotion",e.key),void 0!==e.nonce&&t.setAttribute("nonce",e.nonce),t.appendChild(document.createTextNode("")),t.setAttribute("data-s",""),t}var Lt=function(){function StyleSheet2(e){var t=this;this._insertTag=function(e){var g;g=0===t.tags.length?t.insertionPoint?t.insertionPoint.nextSibling:t.prepend?t.container.firstChild:t.before:t.tags[t.tags.length-1].nextSibling,t.container.insertBefore(e,g),t.tags.push(e)},this.isSpeedy=void 0===e.speedy||e.speedy,this.tags=[],this.ctr=0,this.nonce=e.nonce,this.key=e.key,this.container=e.container,this.prepend=e.prepend,this.insertionPoint=e.insertionPoint,this.before=null}var e=StyleSheet2.prototype;return e.hydrate=function(e){e.forEach(this._insertTag)},e.insert=function(e){this.ctr%(this.isSpeedy?65e3:1)==0&&this._insertTag(createStyleElement(this));var t=this.tags[this.tags.length-1];if(this.isSpeedy){var g=sheetForTag(t);try{g.insertRule(e,g.cssRules.length)}catch(n){}}else t.appendChild(document.createTextNode(e));this.ctr++},e.flush=function(){this.tags.forEach(function(e){var t;return null==(t=e.parentNode)?void 0:t.removeChild(e)}),this.tags=[],this.ctr=0},StyleSheet2}(),Gt="-ms-",Bt="-moz-",Ft="-webkit-",Wt="comm",Vt="rule",Kt="decl",Ut="@import",Ht="@keyframes",Yt="@layer",Zt=Math.abs,Qt=String.fromCharCode,Xt=Object.assign;function hash$2(e,t){return 45^charat(e,0)?(((t<<2^charat(e,0))<<2^charat(e,1))<<2^charat(e,2))<<2^charat(e,3):0}function trim(e){return e.trim()}function match(e,t){return(e=t.exec(e))?e[0]:e}function replace(e,t,g){return e.replace(t,g)}function indexof(e,t){return e.indexOf(t)}function charat(e,t){return 0|e.charCodeAt(t)}function substr(e,t,g){return e.slice(t,g)}function strlen(e){return e.length}function sizeof(e){return e.length}function append(e,t){return t.push(e),e}function combine(e,t){return e.map(t).join("")}var qt=1,Jt=1,$t=0,_t=0,eg=0,tg="";function node(e,t,g,n,C,o,I){return{value:e,root:t,parent:g,type:n,props:C,children:o,line:qt,column:Jt,length:I,return:""}}function copy(e,t){return Xt(node("",null,null,"",null,null,0),e,{length:-e.length},t)}function char(){return eg}function prev(){return eg=_t>0?charat(tg,--_t):0,Jt--,10===eg&&(Jt=1,qt--),eg}function next(){return eg=_t<$t?charat(tg,_t++):0,Jt++,10===eg&&(Jt=1,qt++),eg}function peek(){return charat(tg,_t)}function caret(){return _t}function slice(e,t){return substr(tg,e,t)}function token(e){switch(e){case 0:case 9:case 10:case 13:case 32:return 5;case 33:case 43:case 44:case 47:case 62:case 64:case 126:case 59:case 123:case 125:return 4;case 58:return 3;case 34:case 39:case 40:case 91:return 2;case 41:case 93:return 1}return 0}function alloc(e){return qt=Jt=1,$t=strlen(tg=e),_t=0,[]}function dealloc(e){return tg="",e}function delimit(e){return trim(slice(_t-1,delimiter(91===e?e+2:40===e?e+1:e)))}function whitespace(e){for(;(eg=peek())&&eg<33;)next();return token(e)>2||token(eg)>3?"":" "}function escaping(e,t){for(;--t&&next()&&!(eg<48||eg>102||eg>57&&eg<65||eg>70&&eg<97););return slice(e,caret()+(t<6&&32==peek()&&32==next()))}function delimiter(e){for(;next();)switch(eg){case e:return _t;case 34:case 39:34!==e&&39!==e&&delimiter(eg);break;case 40:41===e&&delimiter(e);break;case 92:next()}return _t}function commenter(e,t){for(;next()&&e+eg!==57&&(e+eg!==84||47!==peek()););return"/*"+slice(t,_t-1)+"*"+Qt(47===e?e:next())}function identifier(e){for(;!token(peek());)next();return slice(e,_t)}function compile(e){return dealloc(parse("",null,null,null,[""],e=alloc(e),0,[0],e))}function parse(e,t,g,n,C,o,I,a,i){for(var s=0,l=0,c=I,u=0,d=0,p=0,m=1,h=1,y=1,b=0,v="",x=C,S=o,w=n,E=v;h;)switch(p=b,b=next()){case 40:if(108!=p&&58==charat(E,c-1)){-1!=indexof(E+=replace(delimit(b),"&","&\f"),"&\f")&&(y=-1);break}case 34:case 39:case 91:E+=delimit(b);break;case 9:case 10:case 13:case 32:E+=whitespace(p);break;case 92:E+=escaping(caret()-1,7);continue;case 47:switch(peek()){case 42:case 47:append(comment(commenter(next(),caret()),t,g),i);break;default:E+="/"}break;case 123*m:a[s++]=strlen(E)*y;case 125*m:case 59:case 0:switch(b){case 0:case 125:h=0;case 59+l:-1==y&&(E=replace(E,/\f/g,"")),d>0&&strlen(E)-c&&append(d>32?declaration(E+";",n,g,c-1):declaration(replace(E," ","")+";",n,g,c-2),i);break;case 59:E+=";";default:if(append(w=ruleset(E,t,g,s,l,C,a,v,x=[],S=[],c),o),123===b)if(0===l)parse(E,t,w,w,x,o,c,a,S);else switch(99===u&&110===charat(E,3)?100:u){case 100:case 108:case 109:case 115:parse(e,w,w,n&&append(ruleset(e,w,w,0,0,C,a,v,C,x=[],c),S),C,S,c,a,n?x:S);break;default:parse(E,w,w,w,[""],S,0,a,S)}}s=l=d=0,m=y=1,v=E="",c=I;break;case 58:c=1+strlen(E),d=p;default:if(m<1)if(123==b)--m;else if(125==b&&0==m++&&125==prev())continue;switch(E+=Qt(b),b*m){case 38:y=l>0?1:(E+="\f",-1);break;case 44:a[s++]=(strlen(E)-1)*y,y=1;break;case 64:45===peek()&&(E+=delimit(next())),u=peek(),l=c=strlen(v=E+=identifier(caret())),b++;break;case 45:45===p&&2==strlen(E)&&(m=0)}}return o}function ruleset(e,t,g,n,C,o,I,a,i,s,l){for(var c=C-1,u=0===C?o:[""],d=sizeof(u),p=0,m=0,h=0;p<n;++p)for(var y=0,b=substr(e,c+1,c=Zt(m=I[p])),v=e;y<d;++y)(v=trim(m>0?u[y]+" "+b:replace(b,/&\f/g,u[y])))&&(i[h++]=v);return node(e,t,g,0===C?Vt:a,i,s,l)}function comment(e,t,g){return node(e,t,g,Wt,Qt(char()),substr(e,2,-2),0)}function declaration(e,t,g,n){return node(e,t,g,Kt,substr(e,0,n),substr(e,n+1,-1),n)}function serialize(e,t){for(var g="",n=sizeof(e),C=0;C<n;C++)g+=t(e[C],C,e,t)||"";return g}function stringify(e,t,g,n){switch(e.type){case Yt:if(e.children.length)break;case Ut:case Kt:return e.return=e.return||e.value;case Wt:return"";case Ht:return e.return=e.value+"{"+serialize(e.children,n)+"}";case Vt:e.value=e.props.join(",")}return strlen(g=serialize(e.children,n))?e.return=e.value+"{"+g+"}":""}function middleware(e){var t=sizeof(e);return function(g,n,C,o){for(var I="",a=0;a<t;a++)I+=e[a](g,n,C,o)||"";return I}}function rulesheet(e){return function(t){t.root||(t=t.return)&&e(t)}}function memoize$1(e){var t=Object.create(null);return function(g){return void 0===t[g]&&(t[g]=e(g)),t[g]}}var identifierWithPointTracking=function(e,t,g){for(var n=0,C=0;n=C,C=peek(),38===n&&12===C&&(t[g]=1),!token(C);)next();return slice(e,_t)},toRules=function(e,t){var g=-1,n=44;do{switch(token(n)){case 0:38===n&&12===peek()&&(t[g]=1),e[g]+=identifierWithPointTracking(_t-1,t,g);break;case 2:e[g]+=delimit(n);break;case 4:if(44===n){e[++g]=58===peek()?"&\f":"",t[g]=e[g].length;break}default:e[g]+=Qt(n)}}while(n=next());return e},getRules=function(e,t){return dealloc(toRules(alloc(e),t))},gg=new WeakMap,compat=function(e){if("rule"===e.type&&e.parent&&!(e.length<1)){for(var t=e.value,g=e.parent,n=e.column===g.column&&e.line===g.line;"rule"!==g.type;)if(!(g=g.parent))return;if((1!==e.props.length||58===t.charCodeAt(0)||gg.get(g))&&!n){gg.set(e,!0);for(var C=[],o=getRules(t,C),I=g.props,a=0,i=0;a<o.length;a++)for(var s=0;s<I.length;s++,i++)e.props[i]=C[a]?o[a].replace(/&\f/g,I[s]):I[s]+" "+o[a]}}},removeLabel=function(e){if("decl"===e.type){var t=e.value;108===t.charCodeAt(0)&&98===t.charCodeAt(2)&&(e.return="",e.value="")}};function prefix(e,t){switch(hash$2(e,t)){case 5103:return Ft+"print-"+e+e;case 5737:case 4201:case 3177:case 3433:case 1641:case 4457:case 2921:case 5572:case 6356:case 5844:case 3191:case 6645:case 3005:case 6391:case 5879:case 5623:case 6135:case 4599:case 4855:case 4215:case 6389:case 5109:case 5365:case 5621:case 3829:return Ft+e+e;case 5349:case 4246:case 4810:case 6968:case 2756:return Ft+e+Bt+e+Gt+e+e;case 6828:case 4268:return Ft+e+Gt+e+e;case 6165:return Ft+e+Gt+"flex-"+e+e;case 5187:return Ft+e+replace(e,/(\w+).+(:[^]+)/,Ft+"box-$1$2"+Gt+"flex-$1$2")+e;case 5443:return Ft+e+Gt+"flex-item-"+replace(e,/flex-|-self/,"")+e;case 4675:return Ft+e+Gt+"flex-line-pack"+replace(e,/align-content|flex-|-self/,"")+e;case 5548:return Ft+e+Gt+replace(e,"shrink","negative")+e;case 5292:return Ft+e+Gt+replace(e,"basis","preferred-size")+e;case 6060:return Ft+"box-"+replace(e,"-grow","")+Ft+e+Gt+replace(e,"grow","positive")+e;case 4554:return Ft+replace(e,/([^-])(transform)/g,"$1"+Ft+"$2")+e;case 6187:return replace(replace(replace(e,/(zoom-|grab)/,Ft+"$1"),/(image-set)/,Ft+"$1"),e,"")+e;case 5495:case 3959:return replace(e,/(image-set\([^]*)/,Ft+"$1$`$1");case 4968:return replace(replace(e,/(.+:)(flex-)?(.*)/,Ft+"box-pack:$3"+Gt+"flex-pack:$3"),/s.+-b[^;]+/,"justify")+Ft+e+e;case 4095:case 3583:case 4068:case 2532:return replace(e,/(.+)-inline(.+)/,Ft+"$1$2")+e;case 8116:case 7059:case 5753:case 5535:case 5445:case 5701:case 4933:case 4677:case 5533:case 5789:case 5021:case 4765:if(strlen(e)-1-t>6)switch(charat(e,t+1)){case 109:if(45!==charat(e,t+4))break;case 102:return replace(e,/(.+:)(.+)-([^]+)/,"$1"+Ft+"$2-$3$1"+Bt+(108==charat(e,t+3)?"$3":"$2-$3"))+e;case 115:return~indexof(e,"stretch")?prefix(replace(e,"stretch","fill-available"),t)+e:e}break;case 4949:if(115!==charat(e,t+1))break;case 6444:switch(charat(e,strlen(e)-3-(~indexof(e,"!important")&&10))){case 107:return replace(e,":",":"+Ft)+e;case 101:return replace(e,/(.+:)([^;!]+)(;|!.+)?/,"$1"+Ft+(45===charat(e,14)?"inline-":"")+"box$3$1"+Ft+"$2$3$1"+Gt+"$2box$3")+e}break;case 5936:switch(charat(e,t+11)){case 114:return Ft+e+Gt+replace(e,/[svh]\w+-[tblr]{2}/,"tb")+e;case 108:return Ft+e+Gt+replace(e,/[svh]\w+-[tblr]{2}/,"tb-rl")+e;case 45:return Ft+e+Gt+replace(e,/[svh]\w+-[tblr]{2}/,"lr")+e}return Ft+e+Gt+e+e}return e}var rg=[function(e,t,g,n){if(e.length>-1&&!e.return)switch(e.type){case Kt:e.return=prefix(e.value,e.length);break;case Ht:return serialize([copy(e,{value:replace(e.value,"@","@"+Ft)})],n);case Vt:if(e.length)return combine(e.props,function(t){switch(match(t,/(::plac\w+|:read-\w+)/)){case":read-only":case":read-write":return serialize([copy(e,{props:[replace(t,/:(read-\w+)/,":"+Bt+"$1")]})],n);case"::placeholder":return serialize([copy(e,{props:[replace(t,/:(plac\w+)/,":"+Ft+"input-$1")]}),copy(e,{props:[replace(t,/:(plac\w+)/,":"+Bt+"$1")]}),copy(e,{props:[replace(t,/:(plac\w+)/,Gt+"input-$1")]})],n)}return""})}}],createCache=function(e){var t=e.key;if("css"===t){var g=document.querySelectorAll("style[data-emotion]:not([data-s])");Array.prototype.forEach.call(g,function(e){-1!==e.getAttribute("data-emotion").indexOf(" ")&&(document.head.appendChild(e),e.setAttribute("data-s",""))})}var n,C,o=e.stylisPlugins||rg,I={},a=[];n=e.container||document.head,Array.prototype.forEach.call(document.querySelectorAll('style[data-emotion^="'+t+' "]'),function(e){for(var t=e.getAttribute("data-emotion").split(" "),g=1;g<t.length;g++)I[t[g]]=!0;a.push(e)});var i,s=[compat,removeLabel],l=[stringify,rulesheet(function(e){i.insert(e)})],c=middleware(s.concat(o,l)),stylis=function(e){return serialize(compile(e),c)};C=function(e,t,g,n){i=g,stylis(e?e+"{"+t.styles+"}":t.styles),n&&(u.inserted[t.name]=!0)};var u={key:t,sheet:new Lt({key:t,container:n,nonce:e.nonce,speedy:e.speedy,prepend:e.prepend,insertionPoint:e.insertionPoint}),nonce:e.nonce,inserted:I,registered:{},insert:C};return u.sheet.hydrate(a),u};function getDefaultExportFromCjs(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var ng,Ag,Cg,og,Ig={exports:{}},ag={};function requireReactIs_production_min(){if(ng)return ag;ng=1;var e="function"==typeof Symbol&&Symbol.for,t=e?Symbol.for("react.element"):60103,g=e?Symbol.for("react.portal"):60106,n=e?Symbol.for("react.fragment"):60107,C=e?Symbol.for("react.strict_mode"):60108,o=e?Symbol.for("react.profiler"):60114,I=e?Symbol.for("react.provider"):60109,a=e?Symbol.for("react.context"):60110,i=e?Symbol.for("react.async_mode"):60111,s=e?Symbol.for("react.concurrent_mode"):60111,l=e?Symbol.for("react.forward_ref"):60112,c=e?Symbol.for("react.suspense"):60113,u=e?Symbol.for("react.suspense_list"):60120,d=e?Symbol.for("react.memo"):60115,p=e?Symbol.for("react.lazy"):60116,m=e?Symbol.for("react.block"):60121,h=e?Symbol.for("react.fundamental"):60117,y=e?Symbol.for("react.responder"):60118,b=e?Symbol.for("react.scope"):60119;function z(e){if("object"==typeof e&&null!==e){var u=e.$$typeof;switch(u){case t:switch(e=e.type){case i:case s:case n:case o:case C:case c:return e;default:switch(e=e&&e.$$typeof){case a:case l:case p:case d:case I:return e;default:return u}}case g:return u}}}function A(e){return z(e)===s}return ag.AsyncMode=i,ag.ConcurrentMode=s,ag.ContextConsumer=a,ag.ContextProvider=I,ag.Element=t,ag.ForwardRef=l,ag.Fragment=n,ag.Lazy=p,ag.Memo=d,ag.Portal=g,ag.Profiler=o,ag.StrictMode=C,ag.Suspense=c,ag.isAsyncMode=function(e){return A(e)||z(e)===i},ag.isConcurrentMode=A,ag.isContextConsumer=function(e){return z(e)===a},ag.isContextProvider=function(e){return z(e)===I},ag.isElement=function(e){return"object"==typeof e&&null!==e&&e.$$typeof===t},ag.isForwardRef=function(e){return z(e)===l},ag.isFragment=function(e){return z(e)===n},ag.isLazy=function(e){return z(e)===p},ag.isMemo=function(e){return z(e)===d},ag.isPortal=function(e){return z(e)===g},ag.isProfiler=function(e){return z(e)===o},ag.isStrictMode=function(e){return z(e)===C},ag.isSuspense=function(e){return z(e)===c},ag.isValidElementType=function(e){return"string"==typeof e||"function"==typeof e||e===n||e===s||e===o||e===C||e===c||e===u||"object"==typeof e&&null!==e&&(e.$$typeof===p||e.$$typeof===d||e.$$typeof===I||e.$$typeof===a||e.$$typeof===l||e.$$typeof===h||e.$$typeof===y||e.$$typeof===b||e.$$typeof===m)},ag.typeOf=z,ag}function requireReactIs$1(){return Ag||(Ag=1,Ig.exports=requireReactIs_production_min()),Ig.exports}function requireHoistNonReactStatics_cjs(){if(og)return Cg;og=1;var e=requireReactIs$1(),t={childContextTypes:!0,contextType:!0,contextTypes:!0,defaultProps:!0,displayName:!0,getDefaultProps:!0,getDerivedStateFromError:!0,getDerivedStateFromProps:!0,mixins:!0,propTypes:!0,type:!0},g={name:!0,length:!0,prototype:!0,caller:!0,callee:!0,arguments:!0,arity:!0},n={$$typeof:!0,render:!0,defaultProps:!0,displayName:!0,propTypes:!0},C={$$typeof:!0,compare:!0,defaultProps:!0,displayName:!0,propTypes:!0,type:!0},o={};function getStatics(g){return e.isMemo(g)?C:o[g.$$typeof]||t}o[e.ForwardRef]=n,o[e.Memo]=C;var I=Object.defineProperty,a=Object.getOwnPropertyNames,i=Object.getOwnPropertySymbols,s=Object.getOwnPropertyDescriptor,l=Object.getPrototypeOf,c=Object.prototype;function hoistNonReactStatics(e,t,n){if("string"!=typeof t){if(c){var C=l(t);C&&C!==c&&hoistNonReactStatics(e,C,n)}var o=a(t);i&&(o=o.concat(i(t)));for(var u=getStatics(e),d=getStatics(t),p=0;p<o.length;++p){var m=o[p];if(!(g[m]||n&&n[m]||d&&d[m]||u&&u[m])){var h=s(t,m);try{I(e,m,h)}catch(y){}}}}return e}return Cg=hoistNonReactStatics}requireHoistNonReactStatics_cjs();var ig=!0;function getRegisteredStyles(e,t,g){var n="";return g.split(" ").forEach(function(g){void 0!==e[g]?t.push(e[g]+";"):g&&(n+=g+" ")}),n}var registerStyles=function(e,t,g){var n=e.key+"-"+t.name;!1!==g&&!1!==ig||void 0!==e.registered[n]||(e.registered[n]=t.styles)},insertStyles=function(e,t,g){registerStyles(e,t,g);var n=e.key+"-"+t.name;if(void 0===e.inserted[t.name]){var C=t;do{e.insert(t===C?"."+n:"",C,e.sheet,!0),C=C.next}while(void 0!==C)}};function murmur2(e){for(var t,g=0,n=0,C=e.length;C>=4;++n,C-=4)t=1540483477*(65535&(t=255&e.charCodeAt(n)|(255&e.charCodeAt(++n))<<8|(255&e.charCodeAt(++n))<<16|(255&e.charCodeAt(++n))<<24))+(59797*(t>>>16)<<16),g=1540483477*(65535&(t^=t>>>24))+(59797*(t>>>16)<<16)^1540483477*(65535&g)+(59797*(g>>>16)<<16);switch(C){case 3:g^=(255&e.charCodeAt(n+2))<<16;case 2:g^=(255&e.charCodeAt(n+1))<<8;case 1:g=1540483477*(65535&(g^=255&e.charCodeAt(n)))+(59797*(g>>>16)<<16)}return(((g=1540483477*(65535&(g^=g>>>13))+(59797*(g>>>16)<<16))^g>>>15)>>>0).toString(36)}var sg={animationIterationCount:1,aspectRatio:1,borderImageOutset:1,borderImageSlice:1,borderImageWidth:1,boxFlex:1,boxFlexGroup:1,boxOrdinalGroup:1,columnCount:1,columns:1,flex:1,flexGrow:1,flexPositive:1,flexShrink:1,flexNegative:1,flexOrder:1,gridRow:1,gridRowEnd:1,gridRowSpan:1,gridRowStart:1,gridColumn:1,gridColumnEnd:1,gridColumnSpan:1,gridColumnStart:1,msGridRow:1,msGridRowSpan:1,msGridColumn:1,msGridColumnSpan:1,fontWeight:1,lineHeight:1,opacity:1,order:1,orphans:1,scale:1,tabSize:1,widows:1,zIndex:1,zoom:1,WebkitLineClamp:1,fillOpacity:1,floodOpacity:1,stopOpacity:1,strokeDasharray:1,strokeDashoffset:1,strokeMiterlimit:1,strokeOpacity:1,strokeWidth:1},lg=/[A-Z]|^ms/g,cg=/_EMO_([^_]+?)_([^]*?)_EMO_/g,isCustomProperty=function(e){return 45===e.charCodeAt(1)},isProcessableValue=function(e){return null!=e&&"boolean"!=typeof e},ug=memoize$1(function(e){return isCustomProperty(e)?e:e.replace(lg,"-$&").toLowerCase()}),processStyleValue=function(e,t){switch(e){case"animation":case"animationName":if("string"==typeof t)return t.replace(cg,function(e,t,g){return dg={name:t,styles:g,next:dg},t})}return 1===sg[e]||isCustomProperty(e)||"number"!=typeof t||0===t?t:t+"px"};function handleInterpolation(e,t,g){if(null==g)return"";var n=g;if(void 0!==n.__emotion_styles)return n;switch(typeof g){case"boolean":return"";case"object":var C=g;if(1===C.anim)return dg={name:C.name,styles:C.styles,next:dg},C.name;var o=g;if(void 0!==o.styles){var I=o.next;if(void 0!==I)for(;void 0!==I;)dg={name:I.name,styles:I.styles,next:dg},I=I.next;return o.styles+";"}return createStringFromObject(e,t,g);case"function":if(void 0!==e){var a=dg,i=g(e);return dg=a,handleInterpolation(e,t,i)}}var s=g;if(null==t)return s;var l=t[s];return void 0!==l?l:s}function createStringFromObject(e,t,g){var n="";if(Array.isArray(g))for(var C=0;C<g.length;C++)n+=handleInterpolation(e,t,g[C])+";";else for(var o in g){var I=g[o];if("object"!=typeof I){var a=I;null!=t&&void 0!==t[a]?n+=o+"{"+t[a]+"}":isProcessableValue(a)&&(n+=ug(o)+":"+processStyleValue(o,a)+";")}else if(!Array.isArray(I)||"string"!=typeof I[0]||null!=t&&void 0!==t[I[0]]){var i=handleInterpolation(e,t,I);switch(o){case"animation":case"animationName":n+=ug(o)+":"+i+";";break;default:n+=o+"{"+i+"}"}}else for(var s=0;s<I.length;s++)isProcessableValue(I[s])&&(n+=ug(o)+":"+processStyleValue(o,I[s])+";")}return n}var dg,pg=/label:\s*([^\s;{]+)\s*(;|$)/g;function serializeStyles(e,t,g){if(1===e.length&&"object"==typeof e[0]&&null!==e[0]&&void 0!==e[0].styles)return e[0];var n=!0,C="";dg=void 0;var o=e[0];null==o||void 0===o.raw?(n=!1,C+=handleInterpolation(g,t,o)):C+=o[0];for(var I=1;I<e.length;I++)C+=handleInterpolation(g,t,e[I]),n&&(C+=o[I]);pg.lastIndex=0;for(var a,i="";null!==(a=pg.exec(C));)i+="-"+a[1];return{name:murmur2(C)+i,styles:C,next:dg}}var mg,fg,syncFallback=function(e){return e()},hg=!!C.useInsertionEffect&&C.useInsertionEffect,yg=hg||syncFallback,bg=hg||C.useLayoutEffect,vg=C.createContext("undefined"!=typeof HTMLElement?createCache({key:"css"}):null),xg=vg.Provider,withEmotionCache=function(e){return t.forwardRef(function(g,n){var C=t.useContext(vg);return e(g,C,n)})},Sg=C.createContext({}),wg={}.hasOwnProperty,Eg="__EMOTION_TYPE_PLEASE_DO_NOT_USE__",createEmotionProps=function(e,t){var g={};for(var n in t)wg.call(t,n)&&(g[n]=t[n]);return g[Eg]=e,g},Insertion$1=function(e){var t=e.cache,g=e.serialized,n=e.isStringTag;return registerStyles(t,g,n),yg(function(){return insertStyles(t,g,n)}),null},Rg=withEmotionCache(function(e,t,g){var n=e.css;"string"==typeof n&&void 0!==t.registered[n]&&(n=t.registered[n]);var o=e[Eg],I=[n],a="";"string"==typeof e.className?a=getRegisteredStyles(t.registered,I,e.className):null!=e.className&&(a=e.className+" ");var i=serializeStyles(I,void 0,C.useContext(Sg));a+=t.key+"-"+i.name;var s={};for(var l in e)wg.call(e,l)&&"css"!==l&&l!==Eg&&(s[l]=e[l]);return s.className=a,g&&(s.ref=g),C.createElement(C.Fragment,null,C.createElement(Insertion$1,{cache:t,serialized:i,isStringTag:"string"==typeof o}),C.createElement(o,s))}),jsx=function(e,t){var g=arguments;if(null==t||!wg.call(t,"css"))return C.createElement.apply(void 0,g);var n=g.length,o=new Array(n);o[0]=Rg,o[1]=createEmotionProps(e,t);for(var I=2;I<n;I++)o[I]=g[I];return C.createElement.apply(null,o)};mg=jsx||(jsx={}),fg||(fg=mg.JSX||(mg.JSX={}));var kg=withEmotionCache(function(e,t){var g=serializeStyles([e.styles],void 0,C.useContext(Sg)),n=C.useRef();return bg(function(){var e=t.key+"-global",C=new t.sheet.constructor({key:e,nonce:t.sheet.nonce,container:t.sheet.container,speedy:t.sheet.isSpeedy}),o=!1,I=document.querySelector('style[data-emotion="'+e+" "+g.name+'"]');return t.sheet.tags.length&&(C.before=t.sheet.tags[0]),null!==I&&(o=!0,I.setAttribute("data-emotion",e),C.hydrate([I])),n.current=[C,o],function(){C.flush()}},[t]),bg(function(){var e=n.current,C=e[0];if(e[1])e[1]=!1;else{if(void 0!==g.next&&insertStyles(t,g.next,!0),C.tags.length){var o=C.tags[C.tags.length-1].nextElementSibling;C.before=o,C.flush()}t.insert("",g,C,!1)}},[t,g.name]),null});function css(){for(var e=arguments.length,t=new Array(e),g=0;g<e;g++)t[g]=arguments[g];return serializeStyles(t)}function keyframes(){var e=css.apply(void 0,arguments),t="animation-"+e.name;return{name:t,styles:"@keyframes "+t+"{"+e.styles+"}",anim:1,toString:function(){return"_EMO_"+this.name+"_"+this.styles+"_EMO_"}}}var Mg=/^((children|dangerouslySetInnerHTML|key|ref|autoFocus|defaultValue|defaultChecked|innerHTML|suppressContentEditableWarning|suppressHydrationWarning|valueLink|abbr|accept|acceptCharset|accessKey|action|allow|allowUserMedia|allowPaymentRequest|allowFullScreen|allowTransparency|alt|async|autoComplete|autoPlay|capture|cellPadding|cellSpacing|challenge|charSet|checked|cite|classID|className|cols|colSpan|content|contentEditable|contextMenu|controls|controlsList|coords|crossOrigin|data|dateTime|decoding|default|defer|dir|disabled|disablePictureInPicture|disableRemotePlayback|download|draggable|encType|enterKeyHint|fetchpriority|fetchPriority|form|formAction|formEncType|formMethod|formNoValidate|formTarget|frameBorder|headers|height|hidden|high|href|hrefLang|htmlFor|httpEquiv|id|inputMode|integrity|is|keyParams|keyType|kind|label|lang|list|loading|loop|low|marginHeight|marginWidth|max|maxLength|media|mediaGroup|method|min|minLength|multiple|muted|name|nonce|noValidate|open|optimum|pattern|placeholder|playsInline|popover|popoverTarget|popoverTargetAction|poster|preload|profile|radioGroup|readOnly|referrerPolicy|rel|required|reversed|role|rows|rowSpan|sandbox|scope|scoped|scrolling|seamless|selected|shape|size|sizes|slot|span|spellCheck|src|srcDoc|srcLang|srcSet|start|step|style|summary|tabIndex|target|title|translate|type|useMap|value|width|wmode|wrap|about|datatype|inlist|prefix|property|resource|typeof|vocab|autoCapitalize|autoCorrect|autoSave|color|incremental|fallback|inert|itemProp|itemScope|itemType|itemID|itemRef|on|option|results|security|unselectable|accentHeight|accumulate|additive|alignmentBaseline|allowReorder|alphabetic|amplitude|arabicForm|ascent|attributeName|attributeType|autoReverse|azimuth|baseFrequency|baselineShift|baseProfile|bbox|begin|bias|by|calcMode|capHeight|clip|clipPathUnits|clipPath|clipRule|colorInterpolation|colorInterpolationFilters|colorProfile|colorRendering|contentScriptType|contentStyleType|cursor|cx|cy|d|decelerate|descent|diffuseConstant|direction|display|divisor|dominantBaseline|dur|dx|dy|edgeMode|elevation|enableBackground|end|exponent|externalResourcesRequired|fill|fillOpacity|fillRule|filter|filterRes|filterUnits|floodColor|floodOpacity|focusable|fontFamily|fontSize|fontSizeAdjust|fontStretch|fontStyle|fontVariant|fontWeight|format|from|fr|fx|fy|g1|g2|glyphName|glyphOrientationHorizontal|glyphOrientationVertical|glyphRef|gradientTransform|gradientUnits|hanging|horizAdvX|horizOriginX|ideographic|imageRendering|in|in2|intercept|k|k1|k2|k3|k4|kernelMatrix|kernelUnitLength|kerning|keyPoints|keySplines|keyTimes|lengthAdjust|letterSpacing|lightingColor|limitingConeAngle|local|markerEnd|markerMid|markerStart|markerHeight|markerUnits|markerWidth|mask|maskContentUnits|maskUnits|mathematical|mode|numOctaves|offset|opacity|operator|order|orient|orientation|origin|overflow|overlinePosition|overlineThickness|panose1|paintOrder|pathLength|patternContentUnits|patternTransform|patternUnits|pointerEvents|points|pointsAtX|pointsAtY|pointsAtZ|preserveAlpha|preserveAspectRatio|primitiveUnits|r|radius|refX|refY|renderingIntent|repeatCount|repeatDur|requiredExtensions|requiredFeatures|restart|result|rotate|rx|ry|scale|seed|shapeRendering|slope|spacing|specularConstant|specularExponent|speed|spreadMethod|startOffset|stdDeviation|stemh|stemv|stitchTiles|stopColor|stopOpacity|strikethroughPosition|strikethroughThickness|string|stroke|strokeDasharray|strokeDashoffset|strokeLinecap|strokeLinejoin|strokeMiterlimit|strokeOpacity|strokeWidth|surfaceScale|systemLanguage|tableValues|targetX|targetY|textAnchor|textDecoration|textRendering|textLength|to|transform|u1|u2|underlinePosition|underlineThickness|unicode|unicodeBidi|unicodeRange|unitsPerEm|vAlphabetic|vHanging|vIdeographic|vMathematical|values|vectorEffect|version|vertAdvY|vertOriginX|vertOriginY|viewBox|viewTarget|visibility|widths|wordSpacing|writingMode|x|xHeight|x1|x2|xChannelSelector|xlinkActuate|xlinkArcrole|xlinkHref|xlinkRole|xlinkShow|xlinkTitle|xlinkType|xmlBase|xmlns|xmlnsXlink|xmlLang|xmlSpace|y|y1|y2|yChannelSelector|z|zoomAndPan|for|class|autofocus)|(([Dd][Aa][Tt][Aa]|[Aa][Rr][Ii][Aa]|x)-.*))$/,Tg=memoize$1(function(e){return Mg.test(e)||111===e.charCodeAt(0)&&110===e.charCodeAt(1)&&e.charCodeAt(2)<91}),testOmitPropsOnComponent=function(e){return"theme"!==e},getDefaultShouldForwardProp=function(e){return"string"==typeof e&&e.charCodeAt(0)>96?Tg:testOmitPropsOnComponent},composeShouldForwardProps=function(e,t,g){var n;if(t){var C=t.shouldForwardProp;n=e.__emotion_forwardProp&&C?function(t){return e.__emotion_forwardProp(t)&&C(t)}:C}return"function"!=typeof n&&g&&(n=e.__emotion_forwardProp),n},Insertion=function(e){var t=e.cache,g=e.serialized,n=e.isStringTag;return registerStyles(t,g,n),yg(function(){return insertStyles(t,g,n)}),null},Pg=function createStyled2(e,t){var g,n,o=e.__emotion_real===e,I=o&&e.__emotion_base||e;void 0!==t&&(g=t.label,n=t.target);var a=composeShouldForwardProps(e,t,o),i=a||getDefaultShouldForwardProp(I),s=!i("as");return function(){var l=arguments,c=o&&void 0!==e.__emotion_styles?e.__emotion_styles.slice(0):[];if(void 0!==g&&c.push("label:"+g+";"),null==l[0]||void 0===l[0].raw)c.push.apply(c,l);else{var u=l[0];c.push(u[0]);for(var d=l.length,p=1;p<d;p++)c.push(l[p],u[p])}var m=withEmotionCache(function(e,t,g){var o=s&&e.as||I,l="",u=[],d=e;if(null==e.theme){for(var p in d={},e)d[p]=e[p];d.theme=C.useContext(Sg)}"string"==typeof e.className?l=getRegisteredStyles(t.registered,u,e.className):null!=e.className&&(l=e.className+" ");var m=serializeStyles(c.concat(u),t.registered,d);l+=t.key+"-"+m.name,void 0!==n&&(l+=" "+n);var h=s&&void 0===a?getDefaultShouldForwardProp(o):i,y={};for(var b in e)s&&"as"===b||h(b)&&(y[b]=e[b]);return y.className=l,g&&(y.ref=g),C.createElement(C.Fragment,null,C.createElement(Insertion,{cache:t,serialized:m,isStringTag:"string"==typeof o}),C.createElement(o,y))});return m.displayName=void 0!==g?g:"Styled("+("string"==typeof I?I:I.displayName||I.name||"Component")+")",m.defaultProps=e.defaultProps,m.__emotion_real=m,m.__emotion_base=I,m.__emotion_styles=c,m.__emotion_forwardProp=a,Object.defineProperty(m,"toString",{value:function(){return"."+n}}),m.withComponent=function(e,g){return createStyled2(e,_extends({},t,g,{shouldForwardProp:composeShouldForwardProps(m,g,!0)})).apply(void 0,c)},m}},Ng=["a","abbr","address","area","article","aside","audio","b","base","bdi","bdo","big","blockquote","body","br","button","canvas","caption","cite","code","col","colgroup","data","datalist","dd","del","details","dfn","dialog","div","dl","dt","em","embed","fieldset","figcaption","figure","footer","form","h1","h2","h3","h4","h5","h6","head","header","hgroup","hr","html","i","iframe","img","input","ins","kbd","keygen","label","legend","li","link","main","map","mark","marquee","menu","menuitem","meta","meter","nav","noscript","object","ol","optgroup","option","output","p","param","picture","pre","progress","q","rp","rt","ruby","s","samp","script","section","select","small","source","span","strong","style","sub","summary","sup","table","tbody","td","textarea","tfoot","th","thead","time","title","tr","track","u","ul","var","video","wbr","circle","clipPath","defs","ellipse","foreignObject","g","image","line","linearGradient","mask","path","pattern","polygon","polyline","radialGradient","rect","stop","svg","text","tspan"],Og=Pg.bind(null);Ng.forEach(function(e){Og[e]=Og(e)});var Dg,jg,zg,Lg,Gg,Bg={exports:{}};function requireReactPropTypesSecret(){return jg?Dg:(jg=1,Dg="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED")}function requireFactoryWithThrowingShims(){if(Lg)return zg;Lg=1;var e=requireReactPropTypesSecret();function emptyFunction(){}function emptyFunctionWithReset(){}return emptyFunctionWithReset.resetWarningCache=emptyFunction,zg=function(){function shim(t,g,n,C,o,I){if(I!==e){var a=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 a.name="Invariant Violation",a}}function getShim(){return shim}shim.isRequired=shim;var t={array:shim,bigint:shim,bool:shim,func:shim,number:shim,object:shim,string:shim,symbol:shim,any:shim,arrayOf:getShim,element:shim,elementType:shim,instanceOf:getShim,node:shim,objectOf:getShim,oneOf:getShim,oneOfType:getShim,shape:getShim,exact:getShim,checkPropTypes:emptyFunctionWithReset,resetWarningCache:emptyFunction};return t.PropTypes=t,t}}function requirePropTypes(){return Gg||(Gg=1,Bg.exports=requireFactoryWithThrowingShims()()),Bg.exports}const Fg=getDefaultExportFromCjs(requirePropTypes());var Wg,Vg,Kg={exports:{}},Ug={};function requireReactJsxRuntime_production(){if(Wg)return Ug;Wg=1;var e=Symbol.for("react.transitional.element"),t=Symbol.for("react.fragment");function jsxProd(t,g,n){var C=null;if(void 0!==n&&(C=""+n),void 0!==g.key&&(C=""+g.key),"key"in g)for(var o in n={},g)"key"!==o&&(n[o]=g[o]);else n=g;return g=n.ref,{$$typeof:e,type:t,key:C,ref:void 0!==g?g:null,props:n}}return Ug.Fragment=t,Ug.jsx=jsxProd,Ug.jsxs=jsxProd,Ug}function requireJsxRuntime(){return Vg||(Vg=1,Kg.exports=requireReactJsxRuntime_production()),Kg.exports}var Hg=requireJsxRuntime();const Yg=new Map,createEmotionCache=(e,t)=>{const g=createCache(e);return g.sheet=new t({key:g.key,nonce:g.sheet.nonce,container:g.sheet.container,speedy:g.sheet.isSpeedy,prepend:g.sheet.prepend,insertionPoint:g.sheet.insertionPoint}),g};let Zg;if("object"==typeof document&&(Zg=document.querySelector('[name="emotion-insertion-point"]'),!Zg)){Zg=document.createElement("meta"),Zg.setAttribute("name","emotion-insertion-point"),Zg.setAttribute("content","");const e=document.querySelector("head");e&&e.prepend(Zg)}function getCache(e,t){if(e||t){class g extends Lt{insert(e,t){return this.key&&this.key.endsWith("global")&&(this.before=Zg),super.insert(e,t)}}const n=createEmotionCache({key:"css",insertionPoint:e?Zg:void 0},g);if(t){const e=n.insert;n.insert=(...t)=>(t[1].styles.match(/^@layer\s+[^{]*$/)||(t[1].styles=`@layer mui {${t[1].styles}}`),e(...t))}return n}}function StyledEngineProvider(e){const{injectFirst:t,enableCssLayer:g,children:n}=e,o=C.useMemo(()=>{const e=`${t}-${g}`;if("object"==typeof document&&Yg.has(e))return Yg.get(e);const n=getCache(t,g);return Yg.set(e,n),n},[t,g]);return o?Hg.jsx(xg,{value:o,children:n}):n}function isEmpty$2(e){return null==e||0===Object.keys(e).length}function GlobalStyles$2(e){const{styles:t,defaultTheme:g={}}=e,n="function"==typeof t?e=>t(isEmpty$2(e)?g:e):t;return Hg.jsx(kg,{styles:n})}function styled$2(e,t){return Og(e,t)}function internal_mutateStyles(e,t){Array.isArray(e.__emotion_styles)&&(e.__emotion_styles=t(e.__emotion_styles))}const Qg=[];function internal_serializeStyles(e){return Qg[0]=e,serializeStyles(Qg)}var Xg,qg,Jg={exports:{}},$g={};function requireReactIs_production(){if(Xg)return $g;Xg=1;var e=Symbol.for("react.transitional.element"),t=Symbol.for("react.portal"),g=Symbol.for("react.fragment"),n=Symbol.for("react.strict_mode"),C=Symbol.for("react.profiler"),o=Symbol.for("react.consumer"),I=Symbol.for("react.context"),a=Symbol.for("react.forward_ref"),i=Symbol.for("react.suspense"),s=Symbol.for("react.suspense_list"),l=Symbol.for("react.memo"),c=Symbol.for("react.lazy"),u=Symbol.for("react.view_transition"),d=Symbol.for("react.client.reference");function typeOf(d){if("object"==typeof d&&null!==d){var p=d.$$typeof;switch(p){case e:switch(d=d.type){case g:case C:case n:case i:case s:case u:return d;default:switch(d=d&&d.$$typeof){case I:case a:case c:case l:case o:return d;default:return p}}case t:return p}}}return $g.ContextConsumer=o,$g.ContextProvider=I,$g.Element=e,$g.ForwardRef=a,$g.Fragment=g,$g.Lazy=c,$g.Memo=l,$g.Portal=t,$g.Profiler=C,$g.StrictMode=n,$g.Suspense=i,$g.SuspenseList=s,$g.isContextConsumer=function(e){return typeOf(e)===o},$g.isContextProvider=function(e){return typeOf(e)===I},$g.isElement=function(t){return"object"==typeof t&&null!==t&&t.$$typeof===e},$g.isForwardRef=function(e){return typeOf(e)===a},$g.isFragment=function(e){return typeOf(e)===g},$g.isLazy=function(e){return typeOf(e)===c},$g.isMemo=function(e){return typeOf(e)===l},$g.isPortal=function(e){return typeOf(e)===t},$g.isProfiler=function(e){return typeOf(e)===C},$g.isStrictMode=function(e){return typeOf(e)===n},$g.isSuspense=function(e){return typeOf(e)===i},$g.isSuspenseList=function(e){return typeOf(e)===s},$g.isValidElementType=function(e){return"string"==typeof e||"function"==typeof e||e===g||e===C||e===n||e===i||e===s||"object"==typeof e&&null!==e&&(e.$$typeof===c||e.$$typeof===l||e.$$typeof===I||e.$$typeof===o||e.$$typeof===a||e.$$typeof===d||void 0!==e.getModuleId)},$g.typeOf=typeOf,$g}function requireReactIs(){return qg||(qg=1,Jg.exports=requireReactIs_production()),Jg.exports}var _g=requireReactIs();function isPlainObject(e){if("object"!=typeof e||null===e)return!1;const t=Object.getPrototypeOf(e);return!(null!==t&&t!==Object.prototype&&null!==Object.getPrototypeOf(t)||Symbol.toStringTag in e||Symbol.iterator in e)}function deepClone(e){if(C.isValidElement(e)||_g.isValidElementType(e)||!isPlainObject(e))return e;const t={};return Object.keys(e).forEach(g=>{t[g]=deepClone(e[g])}),t}function deepmerge(e,t,g={clone:!0}){const n=g.clone?{...e}:e;return isPlainObject(e)&&isPlainObject(t)&&Object.keys(t).forEach(o=>{C.isValidElement(t[o])||_g.isValidElementType(t[o])?n[o]=t[o]:isPlainObject(t[o])&&Object.prototype.hasOwnProperty.call(e,o)&&isPlainObject(e[o])?n[o]=deepmerge(e[o],t[o],g):g.clone?n[o]=isPlainObject(t[o])?deepClone(t[o]):t[o]:n[o]=t[o]}),n}const sortBreakpointsValues=e=>{const t=Object.keys(e).map(t=>({key:t,val:e[t]}))||[];return t.sort((e,t)=>e.val-t.val),t.reduce((e,t)=>({...e,[t.key]:t.val}),{})};function createBreakpoints(e){const{values:t={xs:0,sm:600,md:900,lg:1200,xl:1536},unit:g="px",step:n=5,...C}=e,o=sortBreakpointsValues(t),I=Object.keys(o);function up(e){return`@media (min-width:${"number"==typeof t[e]?t[e]:e}${g})`}function down(e){return`@media (max-width:${("number"==typeof t[e]?t[e]:e)-n/100}${g})`}function between(e,C){const o=I.indexOf(C);return`@media (min-width:${"number"==typeof t[e]?t[e]:e}${g}) and (max-width:${(-1!==o&&"number"==typeof t[I[o]]?t[I[o]]:C)-n/100}${g})`}function only(e){return I.indexOf(e)+1<I.length?between(e,I[I.indexOf(e)+1]):up(e)}function not(e){const t=I.indexOf(e);return 0===t?up(I[1]):t===I.length-1?down(I[t]):between(e,I[I.indexOf(e)+1]).replace("@media","@media not all and")}return{keys:I,values:o,up,down,between,only,not,unit:g,...C}}function sortContainerQueries(e,t){if(!e.containerQueries)return t;const g=Object.keys(t).filter(e=>e.startsWith("@container")).sort((e,t)=>{const g=/min-width:\s*([0-9.]+)/;return+(e.match(g)?.[1]||0)-+(t.match(g)?.[1]||0)});return g.length?g.reduce((e,g)=>{const n=t[g];return delete e[g],e[g]=n,e},{...t}):t}function isCqShorthand(e,t){return"@"===t||t.startsWith("@")&&(e.some(e=>t.startsWith(`@${e}`))||!!t.match(/^@\d/))}function getContainerQuery(e,t){const g=t.match(/^@([^/]+)?\/?(.+)?$/);if(!g)return null;const[,n,C]=g,o=Number.isNaN(+n)?n||0:+n;return e.containerQueries(C).up(o)}function cssContainerQueries(e){const toContainerQuery=(e,t)=>e.replace("@media",t?`@container ${t}`:"@container");function attachCq(t,g){t.up=(...t)=>toContainerQuery(e.breakpoints.up(...t),g),t.down=(...t)=>toContainerQuery(e.breakpoints.down(...t),g),t.between=(...t)=>toContainerQuery(e.breakpoints.between(...t),g),t.only=(...t)=>toContainerQuery(e.breakpoints.only(...t),g),t.not=(...t)=>{const n=toContainerQuery(e.breakpoints.not(...t),g);return n.includes("not all and")?n.replace("not all and ","").replace("min-width:","width<").replace("max-width:","width>").replace("and","or"):n}}const t={},containerQueries=e=>(attachCq(t,e),t);return attachCq(containerQueries),{...e,containerQueries}}const er={borderRadius:4};function merge(e,t){return t?deepmerge(e,t,{clone:!1}):e}const tr={xs:0,sm:600,md:900,lg:1200,xl:1536},gr={keys:["xs","sm","md","lg","xl"],up:e=>`@media (min-width:${tr[e]}px)`},rr={containerQueries:e=>({up:t=>{let g="number"==typeof t?t:tr[t]||t;return"number"==typeof g&&(g=`${g}px`),e?`@container ${e} (min-width:${g})`:`@container (min-width:${g})`}})};function handleBreakpoints(e,t,g){const n=e.theme||{};if(Array.isArray(t)){const e=n.breakpoints||gr;return t.reduce((n,C,o)=>(n[e.up(e.keys[o])]=g(t[o]),n),{})}if("object"==typeof t){const e=n.breakpoints||gr;return Object.keys(t).reduce((C,o)=>{if(isCqShorthand(e.keys,o)){const e=getContainerQuery(n.containerQueries?n:rr,o);e&&(C[e]=g(t[o],o))}else if(Object.keys(e.values||tr).includes(o))C[e.up(o)]=g(t[o],o);else{const e=o;C[e]=t[e]}return C},{})}return g(t)}function createEmptyBreakpointObject(e={}){const t=e.keys?.reduce((t,g)=>(t[e.up(g)]={},t),{});return t||{}}function removeUnusedBreakpoints(e,t){return e.reduce((e,t)=>{const g=e[t];return(!g||0===Object.keys(g).length)&&delete e[t],e},t)}function mergeBreakpointsInOrder(e,...t){const g=createEmptyBreakpointObject(e),n=[g,...t].reduce((e,t)=>deepmerge(e,t),{});return removeUnusedBreakpoints(Object.keys(g),n)}function computeBreakpointsBase(e,t){if("object"!=typeof e)return{};const g={},n=Object.keys(t);return Array.isArray(e)?n.forEach((t,n)=>{n<e.length&&(g[t]=!0)}):n.forEach(t=>{null!=e[t]&&(g[t]=!0)}),g}function resolveBreakpointValues({values:e,breakpoints:t,base:g}){const n=g||computeBreakpointsBase(e,t),C=Object.keys(n);if(0===C.length)return e;let o;return C.reduce((t,g,n)=>(Array.isArray(e)?(t[g]=null!=e[n]?e[n]:e[o],o=n):"object"==typeof e?(t[g]=null!=e[g]?e[g]:e[o],o=g):t[g]=e,t),{})}function capitalize(e){if("string"!=typeof e)throw new Error(formatMuiErrorMessage(7));return e.charAt(0).toUpperCase()+e.slice(1)}function getPath(e,t,g=!0){if(!t||"string"!=typeof t)return null;if(e&&e.vars&&g){const g=`vars.${t}`.split(".").reduce((e,t)=>e&&e[t]?e[t]:null,e);if(null!=g)return g}return t.split(".").reduce((e,t)=>e&&null!=e[t]?e[t]:null,e)}function getStyleValue$1(e,t,g,n=g){let C;return C="function"==typeof e?e(g):Array.isArray(e)?e[g]||n:getPath(e,g)||n,t&&(C=t(C,n,e)),C}function style$2(e){const{prop:t,cssProperty:g=e.prop,themeKey:n,transform:C}=e,fn=e=>{if(null==e[t])return null;const o=e[t],I=getPath(e.theme,n)||{};return handleBreakpoints(e,o,e=>{let n=getStyleValue$1(I,C,e);return e===n&&"string"==typeof e&&(n=getStyleValue$1(I,C,`${t}${"default"===e?"":capitalize(e)}`,e)),!1===g?n:{[g]:n}})};return fn.propTypes={},fn.filterProps=[t],fn}function memoize(e){const t={};return g=>(void 0===t[g]&&(t[g]=e(g)),t[g])}const nr={m:"margin",p:"padding"},Ar={t:"Top",r:"Right",b:"Bottom",l:"Left",x:["Left","Right"],y:["Top","Bottom"]},Cr={marginX:"mx",marginY:"my",paddingX:"px",paddingY:"py"},or=memoize(e=>{if(e.length>2){if(!Cr[e])return[e];e=Cr[e]}const[t,g]=e.split(""),n=nr[t],C=Ar[g]||"";return Array.isArray(C)?C.map(e=>n+e):[n+C]}),Ir=["m","mt","mr","mb","ml","mx","my","margin","marginTop","marginRight","marginBottom","marginLeft","marginX","marginY","marginInline","marginInlineStart","marginInlineEnd","marginBlock","marginBlockStart","marginBlockEnd"],ar=["p","pt","pr","pb","pl","px","py","padding","paddingTop","paddingRight","paddingBottom","paddingLeft","paddingX","paddingY","paddingInline","paddingInlineStart","paddingInlineEnd","paddingBlock","paddingBlockStart","paddingBlockEnd"];function createUnaryUnit(e,t,g,n){const C=getPath(e,t,!0)??g;return"number"==typeof C||"string"==typeof C?e=>"string"==typeof e?e:"string"==typeof C?C.startsWith("var(")&&0===e?0:C.startsWith("var(")&&1===e?C:`calc(${e} * ${C})`:C*e:Array.isArray(C)?e=>{if("string"==typeof e)return e;const t=Math.abs(e),g=C[t];return e>=0?g:"number"==typeof g?-g:"string"==typeof g&&g.startsWith("var(")?`calc(-1 * ${g})`:`-${g}`}:"function"==typeof C?C:()=>{}}function createUnarySpacing(e){return createUnaryUnit(e,"spacing",8)}function getValue(e,t){return"string"==typeof t||null==t?t:e(t)}function getStyleFromPropValue(e,t){return g=>e.reduce((e,n)=>(e[n]=getValue(t,g),e),{})}function resolveCssProperty(e,t,g,n){if(!t.includes(g))return null;const C=getStyleFromPropValue(or(g),n);return handleBreakpoints(e,e[g],C)}function style$1(e,t){const g=createUnarySpacing(e.theme);return Object.keys(e).map(n=>resolveCssProperty(e,t,n,g)).reduce(merge,{})}function margin(e){return style$1(e,Ir)}function padding(e){return style$1(e,ar)}function createSpacing(e=8,t=createUnarySpacing({spacing:e})){if(e.mui)return e;const spacing=(...e)=>(0===e.length?[1]:e).map(e=>{const g=t(e);return"number"==typeof g?`${g}px`:g}).join(" ");return spacing.mui=!0,spacing}function compose(...e){const t=e.reduce((e,t)=>(t.filterProps.forEach(g=>{e[g]=t}),e),{}),fn=e=>Object.keys(e).reduce((g,n)=>t[n]?merge(g,t[n](e)):g,{});return fn.propTypes={},fn.filterProps=e.reduce((e,t)=>e.concat(t.filterProps),[]),fn}function borderTransform(e){return"number"!=typeof e?e:`${e}px solid`}function createBorderStyle(e,t){return style$2({prop:e,themeKey:"borders",transform:t})}margin.propTypes={},margin.filterProps=Ir,padding.propTypes={},padding.filterProps=ar;const ir=createBorderStyle("border",borderTransform),sr=createBorderStyle("borderTop",borderTransform),lr=createBorderStyle("borderRight",borderTransform),cr=createBorderStyle("borderBottom",borderTransform),ur=createBorderStyle("borderLeft",borderTransform),dr=createBorderStyle("borderColor"),pr=createBorderStyle("borderTopColor"),mr=createBorderStyle("borderRightColor"),fr=createBorderStyle("borderBottomColor"),hr=createBorderStyle("borderLeftColor"),yr=createBorderStyle("outline",borderTransform),br=createBorderStyle("outlineColor"),borderRadius=e=>{if(void 0!==e.borderRadius&&null!==e.borderRadius){const t=createUnaryUnit(e.theme,"shape.borderRadius",4),styleFromPropValue=e=>({borderRadius:getValue(t,e)});return handleBreakpoints(e,e.borderRadius,styleFromPropValue)}return null};borderRadius.propTypes={},borderRadius.filterProps=["borderRadius"],compose(ir,sr,lr,cr,ur,dr,pr,mr,fr,hr,borderRadius,yr,br);const gap=e=>{if(void 0!==e.gap&&null!==e.gap){const t=createUnaryUnit(e.theme,"spacing",8),styleFromPropValue=e=>({gap:getValue(t,e)});return handleBreakpoints(e,e.gap,styleFromPropValue)}return null};gap.propTypes={},gap.filterProps=["gap"];const columnGap=e=>{if(void 0!==e.columnGap&&null!==e.columnGap){const t=createUnaryUnit(e.theme,"spacing",8),styleFromPropValue=e=>({columnGap:getValue(t,e)});return handleBreakpoints(e,e.columnGap,styleFromPropValue)}return null};columnGap.propTypes={},columnGap.filterProps=["columnGap"];const rowGap=e=>{if(void 0!==e.rowGap&&null!==e.rowGap){const t=createUnaryUnit(e.theme,"spacing",8),styleFromPropValue=e=>({rowGap:getValue(t,e)});return handleBreakpoints(e,e.rowGap,styleFromPropValue)}return null};function paletteTransform(e,t){return"grey"===t?t:e}function sizingTransform(e){return e<=1&&0!==e?100*e+"%":e}rowGap.propTypes={},rowGap.filterProps=["rowGap"],compose(gap,columnGap,rowGap,style$2({prop:"gridColumn"}),style$2({prop:"gridRow"}),style$2({prop:"gridAutoFlow"}),style$2({prop:"gridAutoColumns"}),style$2({prop:"gridAutoRows"}),style$2({prop:"gridTemplateColumns"}),style$2({prop:"gridTemplateRows"}),style$2({prop:"gridTemplateAreas"}),style$2({prop:"gridArea"})),compose(style$2({prop:"color",themeKey:"palette",transform:paletteTransform}),style$2({prop:"bgcolor",cssProperty:"backgroundColor",themeKey:"palette",transform:paletteTransform}),style$2({prop:"backgroundColor",themeKey:"palette",transform:paletteTransform}));const vr=style$2({prop:"width",transform:sizingTransform}),maxWidth=e=>{if(void 0!==e.maxWidth&&null!==e.maxWidth){const styleFromPropValue=t=>{const g=e.theme?.breakpoints?.values?.[t]||tr[t];return g?"px"!==e.theme?.breakpoints?.unit?{maxWidth:`${g}${e.theme.breakpoints.unit}`}:{maxWidth:g}:{maxWidth:sizingTransform(t)}};return handleBreakpoints(e,e.maxWidth,styleFromPropValue)}return null};maxWidth.filterProps=["maxWidth"];const xr=style$2({prop:"minWidth",transform:sizingTransform}),Sr=style$2({prop:"height",transform:sizingTransform}),wr=style$2({prop:"maxHeight",transform:sizingTransform}),Er=style$2({prop:"minHeight",transform:sizingTransform});style$2({prop:"size",cssProperty:"width",transform:sizingTransform}),style$2({prop:"size",cssProperty:"height",transform:sizingTransform}),compose(vr,maxWidth,xr,Sr,wr,Er,style$2({prop:"boxSizing"}));const Rr={border:{themeKey:"borders",transform:borderTransform},borderTop:{themeKey:"borders",transform:borderTransform},borderRight:{themeKey:"borders",transform:borderTransform},borderBottom:{themeKey:"borders",transform:borderTransform},borderLeft:{themeKey:"borders",transform:borderTransform},borderColor:{themeKey:"palette"},borderTopColor:{themeKey:"palette"},borderRightColor:{themeKey:"palette"},borderBottomColor:{themeKey:"palette"},borderLeftColor:{themeKey:"palette"},outline:{themeKey:"borders",transform:borderTransform},outlineColor:{themeKey:"palette"},borderRadius:{themeKey:"shape.borderRadius",style:borderRadius},color:{themeKey:"palette",transform:paletteTransform},bgcolor:{themeKey:"palette",cssProperty:"backgroundColor",transform:paletteTransform},backgroundColor:{themeKey:"palette",transform:paletteTransform},p:{style:padding},pt:{style:padding},pr:{style:padding},pb:{style:padding},pl:{style:padding},px:{style:padding},py:{style:padding},padding:{style:padding},paddingTop:{style:padding},paddingRight:{style:padding},paddingBottom:{style:padding},paddingLeft:{style:padding},paddingX:{style:padding},paddingY:{style:padding},paddingInline:{style:padding},paddingInlineStart:{style:padding},paddingInlineEnd:{style:padding},paddingBlock:{style:padding},paddingBlockStart:{style:padding},paddingBlockEnd:{style:padding},m:{style:margin},mt:{style:margin},mr:{style:margin},mb:{style:margin},ml:{style:margin},mx:{style:margin},my:{style:margin},margin:{style:margin},marginTop:{style:margin},marginRight:{style:margin},marginBottom:{style:margin},marginLeft:{style:margin},marginX:{style:margin},marginY:{style:margin},marginInline:{style:margin},marginInlineStart:{style:margin},marginInlineEnd:{style:margin},marginBlock:{style:margin},marginBlockStart:{style:margin},marginBlockEnd:{style:margin},displayPrint:{cssProperty:!1,transform:e=>({"@media print":{display:e}})},display:{},overflow:{},textOverflow:{},visibility:{},whiteSpace:{},flexBasis:{},flexDirection:{},flexWrap:{},justifyContent:{},alignItems:{},alignContent:{},order:{},flex:{},flexGrow:{},flexShrink:{},alignSelf:{},justifyItems:{},justifySelf:{},gap:{style:gap},rowGap:{style:rowGap},columnGap:{style:columnGap},gridColumn:{},gridRow:{},gridAutoFlow:{},gridAutoColumns:{},gridAutoRows:{},gridTemplateColumns:{},gridTemplateRows:{},gridTemplateAreas:{},gridArea:{},position:{},zIndex:{themeKey:"zIndex"},top:{},right:{},bottom:{},left:{},boxShadow:{themeKey:"shadows"},width:{transform:sizingTransform},maxWidth:{style:maxWidth},minWidth:{transform:sizingTransform},height:{transform:sizingTransform},maxHeight:{transform:sizingTransform},minHeight:{transform:sizingTransform},boxSizing:{},font:{themeKey:"font"},fontFamily:{themeKey:"typography"},fontSize:{themeKey:"typography"},fontStyle:{themeKey:"typography"},fontWeight:{themeKey:"typography"},letterSpacing:{},textTransform:{},lineHeight:{},textAlign:{},typography:{cssProperty:!1,themeKey:"typography"}};function objectsHaveSameKeys(...e){const t=e.reduce((e,t)=>e.concat(Object.keys(t)),[]),g=new Set(t);return e.every(e=>g.size===Object.keys(e).length)}function callIfFn(e,t){return"function"==typeof e?e(t):e}function unstable_createStyleFunctionSx(){function getThemeValue(e,t,g,n){const C={[e]:t,theme:g},o=n[e];if(!o)return{[e]:t};const{cssProperty:I=e,themeKey:a,transform:i,style:s}=o;if(null==t)return null;if("typography"===a&&"inherit"===t)return{[e]:t};const l=getPath(g,a)||{};return s?s(C):handleBreakpoints(C,t,t=>{let g=getStyleValue$1(l,i,t);return t===g&&"string"==typeof t&&(g=getStyleValue$1(l,i,`${e}${"default"===t?"":capitalize(t)}`,t)),!1===I?g:{[I]:g}})}function styleFunctionSx2(e){const{sx:t,theme:g={},nested:n}=e||{};if(!t)return null;const C=g.unstable_sxConfig??Rr;function traverse(e){let t=e;if("function"==typeof e)t=e(g);else if("object"!=typeof e)return e;if(!t)return null;const o=createEmptyBreakpointObject(g.breakpoints),I=Object.keys(o);let a=o;return Object.keys(t).forEach(e=>{const n=callIfFn(t[e],g);if(null!=n)if("object"==typeof n)if(C[e])a=merge(a,getThemeValue(e,n,g,C));else{const t=handleBreakpoints({theme:g},n,t=>({[e]:t}));objectsHaveSameKeys(t,n)?a[e]=styleFunctionSx2({sx:n,theme:g,nested:!0}):a=merge(a,t)}else a=merge(a,getThemeValue(e,n,g,C))}),!n&&g.modularCssLayers?{"@layer sx":sortContainerQueries(g,removeUnusedBreakpoints(I,a))}:sortContainerQueries(g,removeUnusedBreakpoints(I,a))}return Array.isArray(t)?t.map(traverse):traverse(t)}return styleFunctionSx2}const kr=unstable_createStyleFunctionSx();function applyStyles$2(e,t){const g=this;if(g.vars){if(!g.colorSchemes?.[e]||"function"!=typeof g.getColorSchemeSelector)return{};let n=g.getColorSchemeSelector(e);return"&"===n?t:((n.includes("data-")||n.includes("."))&&(n=`*:where(${n.replace(/\s*&$/,"")}) &`),{[n]:t})}return g.palette.mode===e?t:{}}function createTheme$1(e={},...t){const{breakpoints:g={},palette:n={},spacing:C,shape:o={},...I}=e;let a=deepmerge({breakpoints:createBreakpoints(g),direction:"ltr",components:{},palette:{mode:"light",...n},spacing:createSpacing(C),shape:{...er,...o}},I);return a=cssContainerQueries(a),a.applyStyles=applyStyles$2,a=t.reduce((e,t)=>deepmerge(e,t),a),a.unstable_sxConfig={...Rr,...I?.unstable_sxConfig},a.unstable_sx=function(e){return kr({sx:e,theme:this})},a}function isObjectEmpty$2(e){return 0===Object.keys(e).length}function useTheme$4(e=null){const t=C.useContext(Sg);return!t||isObjectEmpty$2(t)?e:t}kr.filterProps=["sx"];const Mr=createTheme$1();function useTheme$3(e=Mr){return useTheme$4(e)}function wrapGlobalLayer(e){const t=internal_serializeStyles(e);return e!==t&&t.styles?(t.styles.match(/^@layer\s+[^{]*$/)||(t.styles=`@layer global{${t.styles}}`),t):e}function GlobalStyles$1({styles:e,themeId:t,defaultTheme:g={}}){const n=useTheme$3(g),C=t&&n[t]||n;let o="function"==typeof e?e(C):e;return C.modularCssLayers&&(o=Array.isArray(o)?o.map(e=>wrapGlobalLayer("function"==typeof e?e(C):e)):wrapGlobalLayer(o)),Hg.jsx(GlobalStyles$2,{styles:o})}const splitProps=e=>{const t={systemProps:{},otherProps:{}},g=e?.theme?.unstable_sxConfig??Rr;return Object.keys(e).forEach(n=>{g[n]?t.systemProps[n]=e[n]:t.otherProps[n]=e[n]}),t};function extendSxProp$1(e){const{sx:t,...g}=e,{systemProps:n,otherProps:C}=splitProps(g);let o;return o=Array.isArray(t)?[n,...t]:"function"==typeof t?(...e)=>{const g=t(...e);return isPlainObject(g)?{...n,...g}:n}:{...n,...t},{...C,sx:o}}const defaultGenerator=e=>e,Tr=(()=>{let e=defaultGenerator;return{configure(t){e=t},generate:t=>e(t),reset(){e=defaultGenerator}}})();function r(e){var t,g,n="";if("string"==typeof e||"number"==typeof e)n+=e;else if("object"==typeof e)if(Array.isArray(e)){var C=e.length;for(t=0;t<C;t++)e[t]&&(g=r(e[t]))&&(n&&(n+=" "),n+=g)}else for(g in e)e[g]&&(n&&(n+=" "),n+=g);return n}function clsx(){for(var e,t,g=0,n="",C=arguments.length;g<C;g++)(e=arguments[g])&&(t=r(e))&&(n&&(n+=" "),n+=t);return n}function createBox(e={}){const{themeId:t,defaultTheme:g,defaultClassName:n="MuiBox-root",generateClassName:o}=e,I=styled$2("div",{shouldForwardProp:e=>"theme"!==e&&"sx"!==e&&"as"!==e})(kr);return C.forwardRef(function(e,C){const a=useTheme$3(g),{className:i,component:s="div",...l}=extendSxProp$1(e);return Hg.jsx(I,{as:s,ref:C,className:clsx(i,o?o(n):n),theme:t&&a[t]||a,...l})})}const Pr={active:"active",checked:"checked",completed:"completed",disabled:"disabled",error:"error",expanded:"expanded",focused:"focused",focusVisible:"focusVisible",open:"open",readOnly:"readOnly",required:"required",selected:"selected"};function generateUtilityClass(e,t,g="Mui"){const n=Pr[t];return n?`${g}-${n}`:`${Tr.generate(e)}-${t}`}function generateUtilityClasses(e,t,g="Mui"){const n={};return t.forEach(t=>{n[t]=generateUtilityClass(e,t,g)}),n}function preprocessStyles(e){const{variants:t,...g}=e,n={variants:t,style:internal_serializeStyles(g),isProcessed:!0};return n.style===g||t&&t.forEach(e=>{"function"!=typeof e.style&&(e.style=internal_serializeStyles(e.style))}),n}const Nr=createTheme$1();function shouldForwardProp(e){return"ownerState"!==e&&"theme"!==e&&"sx"!==e&&"as"!==e}function shallowLayer(e,t){return t&&e&&"object"==typeof e&&e.styles&&!e.styles.startsWith("@layer")&&(e.styles=`@layer ${t}{${String(e.styles)}}`),e}function defaultOverridesResolver(e){return e?(t,g)=>g[e]:null}function attachTheme(e,t,g){e.theme=isObjectEmpty$1(e.theme)?g:e.theme[t]||e.theme}function processStyle(e,t,g){const n="function"==typeof t?t(e):t;if(Array.isArray(n))return n.flatMap(t=>processStyle(e,t,g));if(Array.isArray(n?.variants)){let t;if(n.isProcessed)t=g?shallowLayer(n.style,g):n.style;else{const{variants:e,...C}=n;t=g?shallowLayer(internal_serializeStyles(C),g):C}return processStyleVariants(e,n.variants,[t],g)}return n?.isProcessed?g?shallowLayer(internal_serializeStyles(n.style),g):n.style:g?shallowLayer(internal_serializeStyles(n),g):n}function processStyleVariants(e,t,g=[],n=void 0){let C;e:for(let o=0;o<t.length;o+=1){const I=t[o];if("function"==typeof I.props){if(C??={...e,...e.ownerState,ownerState:e.ownerState},!I.props(C))continue}else for(const t in I.props)if(e[t]!==I.props[t]&&e.ownerState?.[t]!==I.props[t])continue e;"function"==typeof I.style?(C??={...e,...e.ownerState,ownerState:e.ownerState},g.push(n?shallowLayer(internal_serializeStyles(I.style(C)),n):I.style(C))):g.push(n?shallowLayer(internal_serializeStyles(I.style),n):I.style)}return g}function createStyled(e={}){const{themeId:t,defaultTheme:g=Nr,rootShouldForwardProp:n=shouldForwardProp,slotShouldForwardProp:C=shouldForwardProp}=e;function styleAttachTheme(e){attachTheme(e,t,g)}return(e,t={})=>{internal_mutateStyles(e,e=>e.filter(e=>e!==kr));const{name:g,slot:o,skipVariantsResolver:I,skipSx:a,overridesResolver:i=defaultOverridesResolver(lowercaseFirstLetter(o)),...s}=t,l=g&&g.startsWith("Mui")||o?"components":"custom",c=void 0!==I?I:o&&"Root"!==o&&"root"!==o||!1,u=a||!1;let d=shouldForwardProp;"Root"===o||"root"===o?d=n:o?d=C:isStringTag(e)&&(d=void 0);const p=styled$2(e,{shouldForwardProp:d,label:generateStyledLabel(),...s}),transformStyle=e=>{if(e.__emotion_real===e)return e;if("function"==typeof e)return function(t){return processStyle(t,e,t.theme.modularCssLayers?l:void 0)};if(isPlainObject(e)){const t=preprocessStyles(e);return function(e){return t.variants?processStyle(e,t,e.theme.modularCssLayers?l:void 0):e.theme.modularCssLayers?shallowLayer(t.style,l):t.style}}return e},muiStyledResolver=(...t)=>{const n=[],C=t.map(transformStyle),o=[];if(n.push(styleAttachTheme),g&&i&&o.push(function(e){const t=e.theme,n=t.components?.[g]?.styleOverrides;if(!n)return null;const C={};for(const g in n)C[g]=processStyle(e,n[g],e.theme.modularCssLayers?"theme":void 0);return i(e,C)}),g&&!c&&o.push(function(e){const t=e.theme,n=t?.components?.[g]?.variants;return n?processStyleVariants(e,n,[],e.theme.modularCssLayers?"theme":void 0):null}),u||o.push(kr),Array.isArray(C[0])){const e=C.shift(),t=new Array(n.length).fill(""),g=new Array(o.length).fill("");let I;I=[...t,...e,...g],I.raw=[...t,...e.raw,...g],n.unshift(I)}const I=[...n,...C,...o],a=p(...I);return e.muiName&&(a.muiName=e.muiName),a};return p.withConfig&&(muiStyledResolver.withConfig=p.withConfig),muiStyledResolver}}function generateStyledLabel(e,t){let g;return g}function isObjectEmpty$1(e){for(const t in e)return!1;return!0}function isStringTag(e){return"string"==typeof e&&e.charCodeAt(0)>96}function lowercaseFirstLetter(e){return e?e.charAt(0).toLowerCase()+e.slice(1):e}const Or=createStyled();function resolveProps(e,t,g=!1){const n={...t};for(const C in e)if(Object.prototype.hasOwnProperty.call(e,C)){const o=C;if("components"===o||"slots"===o)n[o]={...e[o],...n[o]};else if("componentsProps"===o||"slotProps"===o){const C=e[o],I=t[o];if(I)if(C){n[o]={...I};for(const e in C)if(Object.prototype.hasOwnProperty.call(C,e)){const t=e;n[o][t]=resolveProps(C[t],I[t],g)}}else n[o]=I;else n[o]=C||{}}else"className"===o&&g&&t.className?n.className=clsx(e?.className,t?.className):"style"===o&&g&&t.style?n.style={...e?.style,...t?.style}:void 0===n[o]&&(n[o]=e[o])}return n}function getThemeProps$1(e){const{theme:t,name:g,props:n}=e;return t&&t.components&&t.components[g]&&t.components[g].defaultProps?resolveProps(t.components[g].defaultProps,n):n}function useThemeProps({props:e,name:t,defaultTheme:g,themeId:n}){let C=useTheme$3(g);return n&&(C=C[n]||C),getThemeProps$1({theme:C,name:t,props:e})}const Dr="undefined"!=typeof window?C.useLayoutEffect:C.useEffect;function clamp$2(e,t=Number.MIN_SAFE_INTEGER,g=Number.MAX_SAFE_INTEGER){return Math.max(t,Math.min(e,g))}function clampWrapper(e,t=0,g=1){return clamp$2(e,t,g)}function hexToRgb(e){e=e.slice(1);const t=new RegExp(`.{1,${e.length>=6?2:1}}`,"g");let g=e.match(t);return g&&1===g[0].length&&(g=g.map(e=>e+e)),g?`rgb${4===g.length?"a":""}(${g.map((e,t)=>t<3?parseInt(e,16):Math.round(parseInt(e,16)/255*1e3)/1e3).join(", ")})`:""}function decomposeColor(e){if(e.type)return e;if("#"===e.charAt(0))return decomposeColor(hexToRgb(e));const t=e.indexOf("("),g=e.substring(0,t);if(!["rgb","rgba","hsl","hsla","color"].includes(g))throw new Error(formatMuiErrorMessage(9,e));let n,C=e.substring(t+1,e.length-1);if("color"===g){if(C=C.split(" "),n=C.shift(),4===C.length&&"/"===C[3].charAt(0)&&(C[3]=C[3].slice(1)),!["srgb","display-p3","a98-rgb","prophoto-rgb","rec-2020"].includes(n))throw new Error(formatMuiErrorMessage(10,n))}else C=C.split(",");return C=C.map(e=>parseFloat(e)),{type:g,values:C,colorSpace:n}}const colorChannel=e=>{const t=decomposeColor(e);return t.values.slice(0,3).map((e,g)=>t.type.includes("hsl")&&0!==g?`${e}%`:e).join(" ")},private_safeColorChannel=(e,t)=>{try{return colorChannel(e)}catch(g){return e}};function recomposeColor(e){const{type:t,colorSpace:g}=e;let{values:n}=e;return t.includes("rgb")?n=n.map((e,t)=>t<3?parseInt(e,10):e):t.includes("hsl")&&(n[1]=`${n[1]}%`,n[2]=`${n[2]}%`),n=t.includes("color")?`${g} ${n.join(" ")}`:`${n.join(", ")}`,`${t}(${n})`}function hslToRgb(e){e=decomposeColor(e);const{values:t}=e,g=t[0],n=t[1]/100,C=t[2]/100,o=n*Math.min(C,1-C),f=(e,t=(e+g/30)%12)=>C-o*Math.max(Math.min(t-3,9-t,1),-1);let I="rgb";const a=[Math.round(255*f(0)),Math.round(255*f(8)),Math.round(255*f(4))];return"hsla"===e.type&&(I+="a",a.push(t[3])),recomposeColor({type:I,values:a})}function getLuminance(e){let t="hsl"===(e=decomposeColor(e)).type||"hsla"===e.type?decomposeColor(hslToRgb(e)).values:e.values;return t=t.map(t=>("color"!==e.type&&(t/=255),t<=.03928?t/12.92:((t+.055)/1.055)**2.4)),Number((.2126*t[0]+.7152*t[1]+.0722*t[2]).toFixed(3))}function getContrastRatio(e,t){const g=getLuminance(e),n=getLuminance(t);return(Math.max(g,n)+.05)/(Math.min(g,n)+.05)}function alpha(e,t){return e=decomposeColor(e),t=clampWrapper(t),"rgb"!==e.type&&"hsl"!==e.type||(e.type+="a"),"color"===e.type?e.values[3]=`/${t}`:e.values[3]=t,recomposeColor(e)}function private_safeAlpha(e,t,g){try{return alpha(e,t)}catch(n){return e}}function darken(e,t){if(e=decomposeColor(e),t=clampWrapper(t),e.type.includes("hsl"))e.values[2]*=1-t;else if(e.type.includes("rgb")||e.type.includes("color"))for(let g=0;g<3;g+=1)e.values[g]*=1-t;return recomposeColor(e)}function private_safeDarken(e,t,g){try{return darken(e,t)}catch(n){return e}}function lighten(e,t){if(e=decomposeColor(e),t=clampWrapper(t),e.type.includes("hsl"))e.values[2]+=(100-e.values[2])*t;else if(e.type.includes("rgb"))for(let g=0;g<3;g+=1)e.values[g]+=(255-e.values[g])*t;else if(e.type.includes("color"))for(let g=0;g<3;g+=1)e.values[g]+=(1-e.values[g])*t;return recomposeColor(e)}function private_safeLighten(e,t,g){try{return lighten(e,t)}catch(n){return e}}function emphasize(e,t=.15){return getLuminance(e)>.5?darken(e,t):lighten(e,t)}function private_safeEmphasize(e,t,g){try{return emphasize(e,t)}catch(n){return e}}const jr=C.createContext(null);function useTheme$2(){return C.useContext(jr)}const zr="function"==typeof Symbol&&Symbol.for?Symbol.for("mui.nested"):"__THEME_NESTED__";function mergeOuterLocalTheme(e,t){return"function"==typeof t?t(e):{...e,...t}}function ThemeProvider$2(e){const{children:t,theme:g}=e,n=useTheme$2(),o=C.useMemo(()=>{const e=null===n?{...g}:mergeOuterLocalTheme(n,g);return null!=e&&(e[zr]=null!==n),e},[g,n]);return Hg.jsx(jr.Provider,{value:o,children:t})}const Lr=C.createContext();function RtlProvider({value:e,...t}){return Hg.jsx(Lr.Provider,{value:e??!0,...t})}const useRtl=()=>C.useContext(Lr)??!1,Gr=C.createContext(void 0);function DefaultPropsProvider({value:e,children:t}){return Hg.jsx(Gr.Provider,{value:e,children:t})}function getThemeProps(e){const{theme:t,name:g,props:n}=e;if(!t||!t.components||!t.components[g])return n;const C=t.components[g];return C.defaultProps?resolveProps(C.defaultProps,n,t.components.mergeClassNameAndStyle):C.styleOverrides||C.variants?n:resolveProps(C,n,t.components.mergeClassNameAndStyle)}function useDefaultProps$1({props:e,name:t}){return getThemeProps({props:e,name:t,theme:{components:C.useContext(Gr)}})}let Br=0;function useGlobalId(e){const[t,g]=C.useState(e),n=e||t;return C.useEffect(()=>{null==t&&(Br+=1,g(`mui-${Br}`))},[t]),n}const Fr={...C}.useId;function useId(e){if(void 0!==Fr){const t=Fr();return e??t}return useGlobalId(e)}function useLayerOrder(e){const t=useTheme$4(),g=useId()||"",{modularCssLayers:n}=e;let C="mui.global, mui.components, mui.theme, mui.custom, mui.sx";return C=n&&null===t?"string"==typeof n?n.replace(/mui(?!\.)/g,C):`@layer ${C};`:"",Dr(()=>{const e=document.querySelector("head");if(!e)return;const t=e.firstChild;if(C){if(t&&t.hasAttribute?.("data-mui-layer-order")&&t.getAttribute("data-mui-layer-order")===g)return;const n=document.createElement("style");n.setAttribute("data-mui-layer-order",g),n.textContent=C,e.prepend(n)}else e.querySelector(`style[data-mui-layer-order="${g}"]`)?.remove()},[C,g]),C?Hg.jsx(GlobalStyles$1,{styles:C}):null}const Wr={};function useThemeScoping(e,t,g,n=!1){return C.useMemo(()=>{const C=e&&t[e]||t;if("function"==typeof g){const o=g(C),I=e?{...t,[e]:o}:o;return n?()=>I:I}return e?{...t,[e]:g}:{...t,...g}},[e,t,g,n])}function ThemeProvider$1(e){const{children:t,theme:g,themeId:n}=e,C=useTheme$4(Wr),o=useTheme$2()||Wr,I=useThemeScoping(n,C,g),a=useThemeScoping(n,o,g,!0),i="rtl"===(n?I[n]:I).direction,s=useLayerOrder(I);return Hg.jsx(ThemeProvider$2,{theme:a,children:Hg.jsx(Sg.Provider,{value:I,children:Hg.jsx(RtlProvider,{value:i,children:Hg.jsxs(DefaultPropsProvider,{value:n?I[n].components:I.components,children:[s,t]})})})})}const Vr={theme:void 0};function unstable_memoTheme(e){let t,g;return function(n){let C=t;return void 0!==C&&n.theme===g||(Vr.theme=n.theme,C=preprocessStyles(e(Vr)),t=C,g=n.theme),C}}const Kr="mode",Ur="color-scheme",Hr="data-color-scheme";function InitColorSchemeScript(e){const{defaultMode:t="system",defaultLightColorScheme:g="light",defaultDarkColorScheme:n="dark",modeStorageKey:C=Kr,colorSchemeStorageKey:o=Ur,attribute:I=Hr,colorSchemeNode:a="document.documentElement",nonce:i}=e||{};let s="",l=I;if("class"===I&&(l=".%s"),"data"===I&&(l="[data-%s]"),l.startsWith(".")){const e=l.substring(1);s+=`${a}.classList.remove('${e}'.replace('%s', light), '${e}'.replace('%s', dark));\n ${a}.classList.add('${e}'.replace('%s', colorScheme));`}const c=l.match(/\[([^[\]]+)\]/);if(c){const[e,t]=c[1].split("=");t||(s+=`${a}.removeAttribute('${e}'.replace('%s', light));\n ${a}.removeAttribute('${e}'.replace('%s', dark));`),s+=`\n ${a}.setAttribute('${e}'.replace('%s', colorScheme), ${t?`${t}.replace('%s', colorScheme)`:'""'});`}else".%s"!==l&&(s+=`${a}.setAttribute('${l}', colorScheme);`);return Hg.jsx("script",{suppressHydrationWarning:!0,nonce:"undefined"==typeof window?i:"",dangerouslySetInnerHTML:{__html:`(function() {\ntry {\n let colorScheme = '';\n const mode = localStorage.getItem('${C}') || '${t}';\n const dark = localStorage.getItem('${o}-dark') || '${n}';\n const light = localStorage.getItem('${o}-light') || '${g}';\n if (mode === 'system') {\n // handle system mode\n const mql = window.matchMedia('(prefers-color-scheme: dark)');\n if (mql.matches) {\n colorScheme = dark\n } else {\n colorScheme = light\n }\n }\n if (mode === 'light') {\n colorScheme = light;\n }\n if (mode === 'dark') {\n colorScheme = dark;\n }\n if (colorScheme) {\n ${s}\n }\n} catch(e){}})();`}},"mui-color-scheme-init")}function noop$7(){}const localStorageManager=({key:e,storageWindow:t})=>(t||"undefined"==typeof window||(t=window),{get(g){if("undefined"==typeof window)return;if(!t)return g;let n;try{n=t.localStorage.getItem(e)}catch{}return n||g},set:g=>{if(t)try{t.localStorage.setItem(e,g)}catch{}},subscribe:g=>{if(!t)return noop$7;const listener=t=>{const n=t.newValue;t.key===e&&g(n)};return t.addEventListener("storage",listener),()=>{t.removeEventListener("storage",listener)}}});function noop$6(){}function getSystemMode(e){if("undefined"!=typeof window&&"function"==typeof window.matchMedia&&"system"===e)return window.matchMedia("(prefers-color-scheme: dark)").matches?"dark":"light"}function processState(e,t){return"light"===e.mode||"system"===e.mode&&"light"===e.systemMode?t("light"):"dark"===e.mode||"system"===e.mode&&"dark"===e.systemMode?t("dark"):void 0}function getColorScheme(e){return processState(e,t=>"light"===t?e.lightColorScheme:"dark"===t?e.darkColorScheme:void 0)}function useCurrentColorScheme(e){const{defaultMode:t="light",defaultLightColorScheme:g,defaultDarkColorScheme:n,supportedColorSchemes:o=[],modeStorageKey:I=Kr,colorSchemeStorageKey:a=Ur,storageWindow:i=("undefined"==typeof window?void 0:window),storageManager:s=localStorageManager,noSsr:l=!1}=e,c=o.join(","),u=o.length>1,d=C.useMemo(()=>s?.({key:I,storageWindow:i}),[s,I,i]),p=C.useMemo(()=>s?.({key:`${a}-light`,storageWindow:i}),[s,a,i]),m=C.useMemo(()=>s?.({key:`${a}-dark`,storageWindow:i}),[s,a,i]),[h,y]=C.useState(()=>{const e=d?.get(t)||t,C=p?.get(g)||g,o=m?.get(n)||n;return{mode:e,systemMode:getSystemMode(e),lightColorScheme:C,darkColorScheme:o}}),[b,v]=C.useState(l||!u);C.useEffect(()=>{v(!0)},[]);const x=getColorScheme(h),S=C.useCallback(e=>{y(g=>{if(e===g.mode)return g;const n=e??t;return d?.set(n),{...g,mode:n,systemMode:getSystemMode(n)}})},[d,t]),w=C.useCallback(e=>{e?"string"==typeof e?e&&!c.includes(e)?console.error(`\`${e}\` does not exist in \`theme.colorSchemes\`.`):y(t=>{const g={...t};return processState(t,t=>{"light"===t&&(p?.set(e),g.lightColorScheme=e),"dark"===t&&(m?.set(e),g.darkColorScheme=e)}),g}):y(t=>{const C={...t},o=null===e.light?g:e.light,I=null===e.dark?n:e.dark;return o&&(c.includes(o)?(C.lightColorScheme=o,p?.set(o)):console.error(`\`${o}\` does not exist in \`theme.colorSchemes\`.`)),I&&(c.includes(I)?(C.darkColorScheme=I,m?.set(I)):console.error(`\`${I}\` does not exist in \`theme.colorSchemes\`.`)),C}):y(e=>(p?.set(g),m?.set(n),{...e,lightColorScheme:g,darkColorScheme:n}))},[c,p,m,g,n]),E=C.useCallback(e=>{"system"===h.mode&&y(t=>{const g=e?.matches?"dark":"light";return t.systemMode===g?t:{...t,systemMode:g}})},[h.mode]),R=C.useRef(E);return R.current=E,C.useEffect(()=>{if("function"!=typeof window.matchMedia||!u)return;const handler=(...e)=>R.current(...e),e=window.matchMedia("(prefers-color-scheme: dark)");return e.addListener(handler),handler(e),()=>{e.removeListener(handler)}},[u]),C.useEffect(()=>{if(u){const e=d?.subscribe(e=>{e&&!["light","dark","system"].includes(e)||S(e||t)})||noop$6,g=p?.subscribe(e=>{e&&!c.match(e)||w({light:e})})||noop$6,n=m?.subscribe(e=>{e&&!c.match(e)||w({dark:e})})||noop$6;return()=>{e(),g(),n()}}},[w,S,c,t,i,u,d,p,m]),{...h,mode:b?h.mode:void 0,systemMode:b?h.systemMode:void 0,colorScheme:b?x:void 0,setMode:S,setColorScheme:w}}const Yr="*{-webkit-transition:none!important;-moz-transition:none!important;-o-transition:none!important;-ms-transition:none!important;transition:none!important}";function createCssVarsProvider(e){const{themeId:t,theme:g={},modeStorageKey:n=Kr,colorSchemeStorageKey:o=Ur,disableTransitionOnChange:I=!1,defaultColorScheme:a,resolveTheme:i}=e,s={allColorSchemes:[],colorScheme:void 0,darkColorScheme:void 0,lightColorScheme:void 0,mode:void 0,setColorScheme:()=>{},setMode:()=>{},systemMode:void 0},l=C.createContext(void 0),useColorScheme=()=>C.useContext(l)||s,c={},u={};function CssVarsProvider2(e){const{children:s,theme:d,modeStorageKey:p=n,colorSchemeStorageKey:m=o,disableTransitionOnChange:h=I,storageManager:y,storageWindow:b=("undefined"==typeof window?void 0:window),documentNode:v=("undefined"==typeof document?void 0:document),colorSchemeNode:x=("undefined"==typeof document?void 0:document.documentElement),disableNestedContext:S=!1,disableStyleSheetGeneration:w=!1,defaultMode:E="system",forceThemeRerender:R=!1,noSsr:M}=e,T=C.useRef(!1),P=useTheme$2(),N=C.useContext(l),O=!!N&&!S,D=C.useMemo(()=>d||("function"==typeof g?g():g),[d]),j=D[t],L=j||D,{colorSchemes:G=c,components:B=u,cssVarPrefix:F}=L,W=Object.keys(G).filter(e=>!!G[e]).join(","),V=C.useMemo(()=>W.split(","),[W]),K="string"==typeof a?a:a.light,U="string"==typeof a?a:a.dark,H=G[K]&&G[U]?E:G[L.defaultColorScheme]?.palette?.mode||L.palette?.mode,{mode:Y,setMode:Z,systemMode:Q,lightColorScheme:X,darkColorScheme:q,colorScheme:J,setColorScheme:$}=useCurrentColorScheme({supportedColorSchemes:V,defaultLightColorScheme:K,defaultDarkColorScheme:U,modeStorageKey:p,colorSchemeStorageKey:m,defaultMode:H,storageManager:y,storageWindow:b,noSsr:M});let _=Y,ee=J;O&&(_=N.mode,ee=N.colorScheme);let te=ee||L.defaultColorScheme;L.vars&&!R&&(te=L.defaultColorScheme);const ge=C.useMemo(()=>{const e=L.generateThemeVars?.()||L.vars,t={...L,components:B,colorSchemes:G,cssVarPrefix:F,vars:e};if("function"==typeof t.generateSpacing&&(t.spacing=t.generateSpacing()),te){const e=G[te];e&&"object"==typeof e&&Object.keys(e).forEach(g=>{e[g]&&"object"==typeof e[g]?t[g]={...t[g],...e[g]}:t[g]=e[g]})}return i?i(t):t},[L,te,B,G,F]),re=L.colorSchemeSelector;Dr(()=>{if(ee&&x&&re&&"media"!==re){const e=re;let t=re;if("class"===e&&(t=".%s"),"data"===e&&(t="[data-%s]"),e?.startsWith("data-")&&!e.includes("%s")&&(t=`[${e}="%s"]`),t.startsWith("."))x.classList.remove(...V.map(e=>t.substring(1).replace("%s",e))),x.classList.add(t.substring(1).replace("%s",ee));else{const e=t.replace("%s",ee).match(/\[([^\]]+)\]/);if(e){const[t,g]=e[1].split("=");g||V.forEach(e=>{x.removeAttribute(t.replace(ee,e))}),x.setAttribute(t,g?g.replace(/"|'/g,""):"")}else x.setAttribute(t,ee)}}},[ee,re,x,V]),C.useEffect(()=>{let e;if(h&&T.current&&v){const t=v.createElement("style");t.appendChild(v.createTextNode(Yr)),v.head.appendChild(t),window.getComputedStyle(v.body),e=setTimeout(()=>{v.head.removeChild(t)},1)}return()=>{clearTimeout(e)}},[ee,h,v]),C.useEffect(()=>(T.current=!0,()=>{T.current=!1}),[]);const ne=C.useMemo(()=>({allColorSchemes:V,colorScheme:ee,darkColorScheme:q,lightColorScheme:X,mode:_,setColorScheme:$,setMode:Z,systemMode:Q}),[V,ee,q,X,_,$,Z,Q,ge.colorSchemeSelector]);let Ae=!0;(w||!1===L.cssVariables||O&&P?.cssVarPrefix===F)&&(Ae=!1);const Ce=Hg.jsxs(C.Fragment,{children:[Hg.jsx(ThemeProvider$1,{themeId:j?t:void 0,theme:ge,children:s}),Ae&&Hg.jsx(GlobalStyles$2,{styles:ge.generateStyleSheets?.()||[]})]});return O?Ce:Hg.jsx(l.Provider,{value:ne,children:Ce})}const d="string"==typeof a?a:a.light,p="string"==typeof a?a:a.dark;return{CssVarsProvider:CssVarsProvider2,useColorScheme,getInitColorSchemeScript:e=>InitColorSchemeScript({colorSchemeStorageKey:o,defaultLightColorScheme:d,defaultDarkColorScheme:p,modeStorageKey:n,...e})}}function createGetCssVar$1(e=""){function appendVar(...t){if(!t.length)return"";const g=t[0];return"string"!=typeof g||g.match(/(#|\(|\)|(-?(\d*\.)?\d+)(px|em|%|ex|ch|rem|vw|vh|vmin|vmax|cm|mm|in|pt|pc))|^(-?(\d*\.)?\d+)$|(\d+ \d+ \d+)/)?`, ${g}`:`, var(--${e?`${e}-`:""}${g}${appendVar(...t.slice(1))})`}return(t,...g)=>`var(--${e?`${e}-`:""}${t}${appendVar(...g)})`}const assignNestedKeys=(e,t,g,n=[])=>{let C=e;t.forEach((e,o)=>{o===t.length-1?Array.isArray(C)?C[Number(e)]=g:C&&"object"==typeof C&&(C[e]=g):C&&"object"==typeof C&&(C[e]||(C[e]=n.includes(e)?[]:{}),C=C[e])})},walkObjectDeep=(e,t,g)=>{function recurse(e,n=[],C=[]){Object.entries(e).forEach(([e,o])=>{(!g||g&&!g([...n,e]))&&null!=o&&("object"==typeof o&&Object.keys(o).length>0?recurse(o,[...n,e],Array.isArray(o)?[...C,e]:C):t([...n,e],o,C))})}recurse(e)},getCssValue=(e,t)=>"number"==typeof t?["lineHeight","fontWeight","opacity","zIndex"].some(t=>e.includes(t))||e[e.length-1].toLowerCase().includes("opacity")?t:`${t}px`:t;function cssVarsParser(e,t){const{prefix:g,shouldSkipGeneratingVar:n}=t||{},C={},o={},I={};return walkObjectDeep(e,(e,t,a)=>{if(!("string"!=typeof t&&"number"!=typeof t||n&&n(e,t))){const n=`--${g?`${g}-`:""}${e.join("-")}`,i=getCssValue(e,t);Object.assign(C,{[n]:i}),assignNestedKeys(o,e,`var(${n})`,a),assignNestedKeys(I,e,`var(${n}, ${i})`,a)}},e=>"vars"===e[0]),{css:C,vars:o,varsWithDefaults:I}}function prepareCssVars(e,t={}){const{getSelector:g=defaultGetSelector2,disableCssColorScheme:n,colorSchemeSelector:C,enableContrastVars:o}=t,{colorSchemes:I={},components:a,defaultColorScheme:i="light",...s}=e,{vars:l,css:c,varsWithDefaults:u}=cssVarsParser(s,t);let d=u;const p={},{[i]:m,...h}=I;if(Object.entries(h||{}).forEach(([e,g])=>{const{vars:n,css:C,varsWithDefaults:o}=cssVarsParser(g,t);d=deepmerge(d,o),p[e]={css:C,vars:n}}),m){const{css:e,vars:g,varsWithDefaults:n}=cssVarsParser(m,t);d=deepmerge(d,n),p[i]={css:e,vars:g}}function defaultGetSelector2(t,g){let n=C;if("class"===C&&(n=".%s"),"data"===C&&(n="[data-%s]"),C?.startsWith("data-")&&!C.includes("%s")&&(n=`[${C}="%s"]`),t){if("media"===n){if(e.defaultColorScheme===t)return":root";const n=I[t]?.palette?.mode||t;return{[`@media (prefers-color-scheme: ${n})`]:{":root":g}}}if(n)return e.defaultColorScheme===t?`:root, ${n.replace("%s",String(t))}`:n.replace("%s",String(t))}return":root"}return{vars:d,generateThemeVars:()=>{let e={...l};return Object.entries(p).forEach(([,{vars:t}])=>{e=deepmerge(e,t)}),e},generateStyleSheets:()=>{const t=[],C=e.defaultColorScheme||"light";function insertStyleSheet(e,g){Object.keys(g).length&&t.push("string"==typeof e?{[e]:{...g}}:e)}insertStyleSheet(g(void 0,{...c}),c);const{[C]:a,...i}=p;if(a){const{css:e}=a,t=I[C]?.palette?.mode,o=!n&&t?{colorScheme:t,...e}:{...e};insertStyleSheet(g(C,{...o}),o)}return Object.entries(i).forEach(([e,{css:t}])=>{const C=I[e]?.palette?.mode,o=!n&&C?{colorScheme:C,...t}:{...t};insertStyleSheet(g(e,{...o}),o)}),o&&t.push({":root":{"--__l-threshold":"0.7","--__l":"clamp(0, (l / var(--__l-threshold) - 1) * -infinity, 1)","--__a":"clamp(0.87, (l / var(--__l-threshold) - 1) * -infinity, 1)"}}),t}}}function createGetColorSchemeSelector(e){return function(t){return"media"===e?`@media (prefers-color-scheme: ${t})`:e?e.startsWith("data-")&&!e.includes("%s")?`[${e}="${t}"] &`:"class"===e?`.${t} &`:"data"===e?`[data-${t}] &`:`${e.replace("%s",t)} &`:"&"}}function composeClasses(e,t,g=void 0){const n={};for(const C in e){const o=e[C];let I="",a=!0;for(let e=0;e<o.length;e+=1){const n=o[e];n&&(I+=(!0===a?"":" ")+t(n),a=!1,g&&g[n]&&(I+=" "+g[n]))}n[C]=I}return n}function isMuiElement(e,t){return C.isValidElement(e)&&-1!==t.indexOf(e.type.muiName??e.type?._payload?.value?.muiName)}const Zr=createTheme$1(),Qr=Or("div",{name:"MuiStack",slot:"Root"});function useThemePropsDefault(e){return useThemeProps({props:e,name:"MuiStack",defaultTheme:Zr})}function joinChildren(e,t){const g=C.Children.toArray(e).filter(Boolean);return g.reduce((e,n,o)=>(e.push(n),o<g.length-1&&e.push(C.cloneElement(t,{key:`separator-${o}`})),e),[])}const getSideFromDirection=e=>({row:"Left","row-reverse":"Right",column:"Top","column-reverse":"Bottom"}[e]),style=({ownerState:e,theme:t})=>{let g={display:"flex",flexDirection:"column",...handleBreakpoints({theme:t},resolveBreakpointValues({values:e.direction,breakpoints:t.breakpoints.values}),e=>({flexDirection:e}))};if(e.spacing){const n=createUnarySpacing(t),C=Object.keys(t.breakpoints.values).reduce((t,g)=>(("object"==typeof e.spacing&&null!=e.spacing[g]||"object"==typeof e.direction&&null!=e.direction[g])&&(t[g]=!0),t),{}),o=resolveBreakpointValues({values:e.direction,base:C}),I=resolveBreakpointValues({values:e.spacing,base:C});"object"==typeof o&&Object.keys(o).forEach((e,t,g)=>{if(!o[e]){const n=t>0?o[g[t-1]]:"column";o[e]=n}}),g=deepmerge(g,handleBreakpoints({theme:t},I,(t,g)=>e.useFlexGap?{gap:getValue(n,t)}:{"& > :not(style):not(style)":{margin:0},"& > :not(style) ~ :not(style)":{[`margin${getSideFromDirection(g?o[g]:e.direction)}`]:getValue(n,t)}}))}return g=mergeBreakpointsInOrder(t.breakpoints,g),g};function createStack(e={}){const{createStyledComponent:t=Qr,useThemeProps:g=useThemePropsDefault,componentName:n="MuiStack"}=e,useUtilityClasses2=()=>composeClasses({root:["root"]},e=>generateUtilityClass(n,e),{}),o=t(style);return C.forwardRef(function(e,t){const n=extendSxProp$1(g(e)),{component:C="div",direction:I="column",spacing:a=0,divider:i,children:s,className:l,useFlexGap:c=!1,...u}=n,d={direction:I,spacing:a,useFlexGap:c},p=useUtilityClasses2();return Hg.jsx(o,{as:C,ownerState:d,ref:t,className:clsx(p.root,l),...u,children:i?joinChildren(s,i):s})})}const Xr="$$material",qr={black:"#000",white:"#fff"},Jr={50:"#fafafa",100:"#f5f5f5",200:"#eeeeee",300:"#e0e0e0",400:"#bdbdbd",500:"#9e9e9e",600:"#757575",700:"#616161",800:"#424242",900:"#212121",A100:"#f5f5f5",A200:"#eeeeee",A400:"#bdbdbd",A700:"#616161"},$r={50:"#f3e5f5",200:"#ce93d8",300:"#ba68c8",400:"#ab47bc",500:"#9c27b0",700:"#7b1fa2"},_r={300:"#e57373",400:"#ef5350",500:"#f44336",700:"#d32f2f",800:"#c62828"},en={300:"#ffb74d",400:"#ffa726",500:"#ff9800",700:"#f57c00",900:"#e65100"},tn={50:"#e3f2fd",200:"#90caf9",400:"#42a5f5",700:"#1976d2",800:"#1565c0"},gn={300:"#4fc3f7",400:"#29b6f6",500:"#03a9f4",700:"#0288d1",900:"#01579b"},rn={300:"#81c784",400:"#66bb6a",500:"#4caf50",700:"#388e3c",800:"#2e7d32",900:"#1b5e20"};function getLight(){return{text:{primary:"rgba(0, 0, 0, 0.87)",secondary:"rgba(0, 0, 0, 0.6)",disabled:"rgba(0, 0, 0, 0.38)"},divider:"rgba(0, 0, 0, 0.12)",background:{paper:qr.white,default:qr.white},action:{active:"rgba(0, 0, 0, 0.54)",hover:"rgba(0, 0, 0, 0.04)",hoverOpacity:.04,selected:"rgba(0, 0, 0, 0.08)",selectedOpacity:.08,disabled:"rgba(0, 0, 0, 0.26)",disabledBackground:"rgba(0, 0, 0, 0.12)",disabledOpacity:.38,focus:"rgba(0, 0, 0, 0.12)",focusOpacity:.12,activatedOpacity:.12}}}const nn=getLight();function getDark(){return{text:{primary:qr.white,secondary:"rgba(255, 255, 255, 0.7)",disabled:"rgba(255, 255, 255, 0.5)",icon:"rgba(255, 255, 255, 0.5)"},divider:"rgba(255, 255, 255, 0.12)",background:{paper:"#121212",default:"#121212"},action:{active:qr.white,hover:"rgba(255, 255, 255, 0.08)",hoverOpacity:.08,selected:"rgba(255, 255, 255, 0.16)",selectedOpacity:.16,disabled:"rgba(255, 255, 255, 0.3)",disabledBackground:"rgba(255, 255, 255, 0.12)",disabledOpacity:.38,focus:"rgba(255, 255, 255, 0.12)",focusOpacity:.12,activatedOpacity:.24}}}const An=getDark();function addLightOrDark(e,t,g,n){const C=n.light||n,o=n.dark||1.5*n;e[t]||(e.hasOwnProperty(g)?e[t]=e[g]:"light"===t?e.light=lighten(e.main,C):"dark"===t&&(e.dark=darken(e.main,o)))}function mixLightOrDark(e,t,g,n,C){const o=C.light||C,I=C.dark||1.5*C;t[g]||(t.hasOwnProperty(n)?t[g]=t[n]:"light"===g?t.light=`color-mix(in ${e}, ${t.main}, #fff ${(100*o).toFixed(0)}%)`:"dark"===g&&(t.dark=`color-mix(in ${e}, ${t.main}, #000 ${(100*I).toFixed(0)}%)`))}function getDefaultPrimary(e="light"){return"dark"===e?{main:tn[200],light:tn[50],dark:tn[400]}:{main:tn[700],light:tn[400],dark:tn[800]}}function getDefaultSecondary(e="light"){return"dark"===e?{main:$r[200],light:$r[50],dark:$r[400]}:{main:$r[500],light:$r[300],dark:$r[700]}}function getDefaultError(e="light"){return"dark"===e?{main:_r[500],light:_r[300],dark:_r[700]}:{main:_r[700],light:_r[400],dark:_r[800]}}function getDefaultInfo(e="light"){return"dark"===e?{main:gn[400],light:gn[300],dark:gn[700]}:{main:gn[700],light:gn[500],dark:gn[900]}}function getDefaultSuccess(e="light"){return"dark"===e?{main:rn[400],light:rn[300],dark:rn[700]}:{main:rn[800],light:rn[500],dark:rn[900]}}function getDefaultWarning(e="light"){return"dark"===e?{main:en[400],light:en[300],dark:en[700]}:{main:"#ed6c02",light:en[500],dark:en[900]}}function contrastColor(e){return`oklch(from ${e} var(--__l) 0 h / var(--__a))`}function createPalette(e){const{mode:t="light",contrastThreshold:g=3,tonalOffset:n=.2,colorSpace:C,...o}=e,I=e.primary||getDefaultPrimary(t),a=e.secondary||getDefaultSecondary(t),i=e.error||getDefaultError(t),s=e.info||getDefaultInfo(t),l=e.success||getDefaultSuccess(t),c=e.warning||getDefaultWarning(t);function getContrastText(e){return C?contrastColor(e):getContrastRatio(e,An.text.primary)>=g?An.text.primary:nn.text.primary}const augmentColor=({color:e,name:t,mainShade:g=500,lightShade:o=300,darkShade:I=700})=>{if(!(e={...e}).main&&e[g]&&(e.main=e[g]),!e.hasOwnProperty("main"))throw new Error(formatMuiErrorMessage(11,t?` (${t})`:"",g));if("string"!=typeof e.main)throw new Error(formatMuiErrorMessage(12,t?` (${t})`:"",JSON.stringify(e.main)));return C?(mixLightOrDark(C,e,"light",o,n),mixLightOrDark(C,e,"dark",I,n)):(addLightOrDark(e,"light",o,n),addLightOrDark(e,"dark",I,n)),e.contrastText||(e.contrastText=getContrastText(e.main)),e};let u;return"light"===t?u=getLight():"dark"===t&&(u=getDark()),deepmerge({common:{...qr},mode:t,primary:augmentColor({color:I,name:"primary"}),secondary:augmentColor({color:a,name:"secondary",mainShade:"A400",lightShade:"A200",darkShade:"A700"}),error:augmentColor({color:i,name:"error"}),warning:augmentColor({color:c,name:"warning"}),info:augmentColor({color:s,name:"info"}),success:augmentColor({color:l,name:"success"}),grey:Jr,contrastThreshold:g,getContrastText,augmentColor,tonalOffset:n,...u},o)}function prepareTypographyVars(e){const t={};return Object.entries(e).forEach(e=>{const[g,n]=e;"object"==typeof n&&(t[g]=`${n.fontStyle?`${n.fontStyle} `:""}${n.fontVariant?`${n.fontVariant} `:""}${n.fontWeight?`${n.fontWeight} `:""}${n.fontStretch?`${n.fontStretch} `:""}${n.fontSize||""}${n.lineHeight?`/${n.lineHeight} `:""}${n.fontFamily||""}`)}),t}function createMixins(e,t){return{toolbar:{minHeight:56,[e.up("xs")]:{"@media (orientation: landscape)":{minHeight:48}},[e.up("sm")]:{minHeight:64}},...t}}function round$2(e){return Math.round(1e5*e)/1e5}const Cn={textTransform:"uppercase"},In='"Roboto", "Helvetica", "Arial", sans-serif';function createTypography(e,t){const{fontFamily:g=In,fontSize:n=14,fontWeightLight:C=300,fontWeightRegular:o=400,fontWeightMedium:I=500,fontWeightBold:a=700,htmlFontSize:i=16,allVariants:s,pxToRem:l,...c}="function"==typeof t?t(e):t,u=n/14,d=l||(e=>e/i*u+"rem"),buildVariant=(e,t,n,C,o)=>({fontFamily:g,fontWeight:e,fontSize:d(t),lineHeight:n,...g===In?{letterSpacing:`${round$2(C/t)}em`}:{},...o,...s}),p={h1:buildVariant(C,96,1.167,-1.5),h2:buildVariant(C,60,1.2,-.5),h3:buildVariant(o,48,1.167,0),h4:buildVariant(o,34,1.235,.25),h5:buildVariant(o,24,1.334,0),h6:buildVariant(I,20,1.6,.15),subtitle1:buildVariant(o,16,1.75,.15),subtitle2:buildVariant(I,14,1.57,.1),body1:buildVariant(o,16,1.5,.15),body2:buildVariant(o,14,1.43,.15),button:buildVariant(I,14,1.75,.4,Cn),caption:buildVariant(o,12,1.66,.4),overline:buildVariant(o,12,2.66,1,Cn),inherit:{fontFamily:"inherit",fontWeight:"inherit",fontSize:"inherit",lineHeight:"inherit",letterSpacing:"inherit"}};return deepmerge({htmlFontSize:i,pxToRem:d,fontFamily:g,fontSize:n,fontWeightLight:C,fontWeightRegular:o,fontWeightMedium:I,fontWeightBold:a,...p},c,{clone:!1})}const an=.2,sn=.14,ln=.12;function createShadow(...e){return[`${e[0]}px ${e[1]}px ${e[2]}px ${e[3]}px rgba(0,0,0,${an})`,`${e[4]}px ${e[5]}px ${e[6]}px ${e[7]}px rgba(0,0,0,${sn})`,`${e[8]}px ${e[9]}px ${e[10]}px ${e[11]}px rgba(0,0,0,${ln})`].join(",")}const cn=["none",createShadow(0,2,1,-1,0,1,1,0,0,1,3,0),createShadow(0,3,1,-2,0,2,2,0,0,1,5,0),createShadow(0,3,3,-2,0,3,4,0,0,1,8,0),createShadow(0,2,4,-1,0,4,5,0,0,1,10,0),createShadow(0,3,5,-1,0,5,8,0,0,1,14,0),createShadow(0,3,5,-1,0,6,10,0,0,1,18,0),createShadow(0,4,5,-2,0,7,10,1,0,2,16,1),createShadow(0,5,5,-3,0,8,10,1,0,3,14,2),createShadow(0,5,6,-3,0,9,12,1,0,3,16,2),createShadow(0,6,6,-3,0,10,14,1,0,4,18,3),createShadow(0,6,7,-4,0,11,15,1,0,4,20,3),createShadow(0,7,8,-4,0,12,17,2,0,5,22,4),createShadow(0,7,8,-4,0,13,19,2,0,5,24,4),createShadow(0,7,9,-4,0,14,21,2,0,5,26,4),createShadow(0,8,9,-5,0,15,22,2,0,6,28,5),createShadow(0,8,10,-5,0,16,24,2,0,6,30,5),createShadow(0,8,11,-5,0,17,26,2,0,6,32,5),createShadow(0,9,11,-5,0,18,28,2,0,7,34,6),createShadow(0,9,12,-6,0,19,29,2,0,7,36,6),createShadow(0,10,13,-6,0,20,31,3,0,8,38,7),createShadow(0,10,13,-6,0,21,33,3,0,8,40,7),createShadow(0,10,14,-6,0,22,35,3,0,8,42,7),createShadow(0,11,14,-7,0,23,36,3,0,9,44,8),createShadow(0,11,15,-7,0,24,38,3,0,9,46,8)],un={easeInOut:"cubic-bezier(0.4, 0, 0.2, 1)",easeOut:"cubic-bezier(0.0, 0, 0.2, 1)",easeIn:"cubic-bezier(0.4, 0, 1, 1)",sharp:"cubic-bezier(0.4, 0, 0.6, 1)"},dn={shortest:150,shorter:200,short:250,standard:300,complex:375,enteringScreen:225,leavingScreen:195};function formatMs(e){return`${Math.round(e)}ms`}function getAutoHeightDuration(e){if(!e)return 0;const t=e/36;return Math.min(Math.round(10*(4+15*t**.25+t/5)),3e3)}function createTransitions(e){const t={...un,...e.easing},g={...dn,...e.duration};return{getAutoHeightDuration,create:(e=["all"],n={})=>{const{duration:C=g.standard,easing:o=t.easeInOut,delay:I=0,...a}=n;return(Array.isArray(e)?e:[e]).map(e=>`${e} ${"string"==typeof C?C:formatMs(C)} ${o} ${"string"==typeof I?I:formatMs(I)}`).join(",")},...e,easing:t,duration:g}}const pn={mobileStepper:1e3,fab:1050,speedDial:1050,appBar:1100,drawer:1200,modal:1300,snackbar:1400,tooltip:1500};function isSerializable(e){return isPlainObject(e)||void 0===e||"string"==typeof e||"boolean"==typeof e||"number"==typeof e||Array.isArray(e)}function stringifyTheme(e={}){const t={...e};function serializeTheme(e){const t=Object.entries(e);for(let g=0;g<t.length;g++){const[n,C]=t[g];!isSerializable(C)||n.startsWith("unstable_")?delete e[n]:isPlainObject(C)&&(e[n]={...C},serializeTheme(e[n]))}}return serializeTheme(t),`import { unstable_createBreakpoints as createBreakpoints, createTransitions } from '@mui/material/styles';\n\nconst theme = ${JSON.stringify(t,null,2)};\n\ntheme.breakpoints = createBreakpoints(theme.breakpoints || {});\ntheme.transitions = createTransitions(theme.transitions || {});\n\nexport default theme;`}function coefficientToPercentage(e){return"number"==typeof e?`${(100*e).toFixed(0)}%`:`calc((${e}) * 100%)`}const parseAddition=e=>{if(!Number.isNaN(+e))return+e;const t=e.match(/\d*\.?\d+/g);if(!t)return 0;let g=0;for(let n=0;n<t.length;n+=1)g+=+t[n];return g};function attachColorManipulators(e){Object.assign(e,{alpha(t,g){const n=this||e;return n.colorSpace?`oklch(from ${t} l c h / ${"string"==typeof g?`calc(${g})`:g})`:n.vars?`rgba(${t.replace(/var\(--([^,\s)]+)(?:,[^)]+)?\)+/g,"var(--$1Channel)")} / ${"string"==typeof g?`calc(${g})`:g})`:alpha(t,parseAddition(g))},lighten(t,g){const n=this||e;return n.colorSpace?`color-mix(in ${n.colorSpace}, ${t}, #fff ${coefficientToPercentage(g)})`:lighten(t,g)},darken(t,g){const n=this||e;return n.colorSpace?`color-mix(in ${n.colorSpace}, ${t}, #000 ${coefficientToPercentage(g)})`:darken(t,g)}})}function createThemeNoVars(e={},...t){const{breakpoints:g,mixins:n={},spacing:C,palette:o={},transitions:I={},typography:a={},shape:i,colorSpace:s,...l}=e;if(e.vars&&void 0===e.generateThemeVars)throw new Error(formatMuiErrorMessage(20));const c=createPalette({...o,colorSpace:s}),u=createTheme$1(e);let d=deepmerge(u,{mixins:createMixins(u.breakpoints,n),palette:c,shadows:cn.slice(),typography:createTypography(c,a),transitions:createTransitions(I),zIndex:{...pn}});return d=deepmerge(d,l),d=t.reduce((e,t)=>deepmerge(e,t),d),d.unstable_sxConfig={...Rr,...l?.unstable_sxConfig},d.unstable_sx=function(e){return kr({sx:e,theme:this})},d.toRuntimeSource=stringifyTheme,attachColorManipulators(d),d}function getOverlayAlpha(e){let t;return t=e<1?5.11916*e**2:4.5*Math.log(e+1)+2,Math.round(10*t)/1e3}const mn=[...Array(25)].map((e,t)=>{if(0===t)return"none";const g=getOverlayAlpha(t);return`linear-gradient(rgba(255 255 255 / ${g}), rgba(255 255 255 / ${g}))`});function getOpacity(e){return{inputPlaceholder:"dark"===e?.5:.42,inputUnderline:"dark"===e?.7:.42,switchTrackDisabled:"dark"===e?.2:.12,switchTrack:"dark"===e?.3:.38}}function getOverlays(e){return"dark"===e?mn:[]}function createColorScheme(e){const{palette:t={mode:"light"},opacity:g,overlays:n,colorSpace:C,...o}=e,I=createPalette({...t,colorSpace:C});return{palette:I,opacity:{...getOpacity(I.mode),...g},overlays:n||getOverlays(I.mode),...o}}function shouldSkipGeneratingVar(e){return!!e[0].match(/(cssVarPrefix|colorSchemeSelector|modularCssLayers|rootSelector|typography|mixins|breakpoints|direction|transitions)/)||!!e[0].match(/sxConfig$/)||"palette"===e[0]&&!!e[1]?.match(/(mode|contrastThreshold|tonalOffset)/)}const excludeVariablesFromRoot=e=>[...[...Array(25)].map((t,g)=>`--${e?`${e}-`:""}overlays-${g}`),`--${e?`${e}-`:""}palette-AppBar-darkBg`,`--${e?`${e}-`:""}palette-AppBar-darkColor`],defaultGetSelector=e=>(t,g)=>{const n=e.rootSelector||":root",C=e.colorSchemeSelector;let o=C;if("class"===C&&(o=".%s"),"data"===C&&(o="[data-%s]"),C?.startsWith("data-")&&!C.includes("%s")&&(o=`[${C}="%s"]`),e.defaultColorScheme===t){if("dark"===t){const C={};return excludeVariablesFromRoot(e.cssVarPrefix).forEach(e=>{C[e]=g[e],delete g[e]}),"media"===o?{[n]:g,"@media (prefers-color-scheme: dark)":{[n]:C}}:o?{[o.replace("%s",t)]:C,[`${n}, ${o.replace("%s",t)}`]:g}:{[n]:{...g,...C}}}if(o&&"media"!==o)return`${n}, ${o.replace("%s",String(t))}`}else if(t){if("media"===o)return{[`@media (prefers-color-scheme: ${String(t)})`]:{[n]:g}};if(o)return o.replace("%s",String(t))}return n};function assignNode(e,t){t.forEach(t=>{e[t]||(e[t]={})})}function setColor(e,t,g){!e[t]&&g&&(e[t]=g)}function toRgb(e){return"string"==typeof e&&e.startsWith("hsl")?hslToRgb(e):e}function setColorChannel(e,t){`${t}Channel`in e||(e[`${t}Channel`]=private_safeColorChannel(toRgb(e[t])))}function getSpacingVal(e){return"number"==typeof e?`${e}px`:"string"==typeof e||"function"==typeof e||Array.isArray(e)?e:"8px"}const silent=e=>{try{return e()}catch(t){}},createGetCssVar=(e="mui")=>createGetCssVar$1(e);function attachColorScheme$1(e,t,g,n,C){if(!g)return;g=!0===g?{}:g;const o="dark"===C?"dark":"light";if(!n)return void(t[C]=createColorScheme({...g,palette:{mode:o,...g?.palette},colorSpace:e}));const{palette:I,...a}=createThemeNoVars({...n,palette:{mode:o,...g?.palette},colorSpace:e});return t[C]={...g,palette:I,opacity:{...getOpacity(o),...g?.opacity},overlays:g?.overlays||getOverlays(o)},a}function createThemeWithVars(e={},...t){const{colorSchemes:g={light:!0},defaultColorScheme:n,disableCssColorScheme:C=!1,cssVarPrefix:o="mui",nativeColor:I=!1,shouldSkipGeneratingVar:a=shouldSkipGeneratingVar,colorSchemeSelector:i=(g.light&&g.dark?"media":void 0),rootSelector:s=":root",...l}=e,c=Object.keys(g)[0],u=n||(g.light&&"light"!==c?"light":c),d=createGetCssVar(o),{[u]:p,light:m,dark:h,...y}=g,b={...y};let v,x=p;if(("dark"===u&&!("dark"in g)||"light"===u&&!("light"in g))&&(x=!0),!x)throw new Error(formatMuiErrorMessage(21,u));I&&(v="oklch");const S=attachColorScheme$1(v,b,x,l,u);m&&!b.light&&attachColorScheme$1(v,b,m,void 0,"light"),h&&!b.dark&&attachColorScheme$1(v,b,h,void 0,"dark");let w={defaultColorScheme:u,...S,cssVarPrefix:o,colorSchemeSelector:i,rootSelector:s,getCssVar:d,colorSchemes:b,font:{...prepareTypographyVars(S.typography),...S.font},spacing:getSpacingVal(l.spacing)};Object.keys(w.colorSchemes).forEach(e=>{const t=w.colorSchemes[e].palette,setCssVarColor=e=>{const g=e.split("-"),n=g[1],C=g[2];return d(e,t[n][C])};function colorMix(e,t,g){if(v){let n;return e===private_safeAlpha&&(n=`transparent ${(100*(1-g)).toFixed(0)}%`),e===private_safeDarken&&(n=`#000 ${(100*g).toFixed(0)}%`),e===private_safeLighten&&(n=`#fff ${(100*g).toFixed(0)}%`),`color-mix(in ${v}, ${t}, ${n})`}return e(t,g)}if("light"===t.mode&&(setColor(t.common,"background","#fff"),setColor(t.common,"onBackground","#000")),"dark"===t.mode&&(setColor(t.common,"background","#000"),setColor(t.common,"onBackground","#fff")),assignNode(t,["Alert","AppBar","Avatar","Button","Chip","FilledInput","LinearProgress","Skeleton","Slider","SnackbarContent","SpeedDialAction","StepConnector","StepContent","Switch","TableCell","Tooltip"]),"light"===t.mode){setColor(t.Alert,"errorColor",colorMix(private_safeDarken,I?d("palette-error-light"):t.error.light,.6)),setColor(t.Alert,"infoColor",colorMix(private_safeDarken,I?d("palette-info-light"):t.info.light,.6)),setColor(t.Alert,"successColor",colorMix(private_safeDarken,I?d("palette-success-light"):t.success.light,.6)),setColor(t.Alert,"warningColor",colorMix(private_safeDarken,I?d("palette-warning-light"):t.warning.light,.6)),setColor(t.Alert,"errorFilledBg",setCssVarColor("palette-error-main")),setColor(t.Alert,"infoFilledBg",setCssVarColor("palette-info-main")),setColor(t.Alert,"successFilledBg",setCssVarColor("palette-success-main")),setColor(t.Alert,"warningFilledBg",setCssVarColor("palette-warning-main")),setColor(t.Alert,"errorFilledColor",silent(()=>t.getContrastText(t.error.main))),setColor(t.Alert,"infoFilledColor",silent(()=>t.getContrastText(t.info.main))),setColor(t.Alert,"successFilledColor",silent(()=>t.getContrastText(t.success.main))),setColor(t.Alert,"warningFilledColor",silent(()=>t.getContrastText(t.warning.main))),setColor(t.Alert,"errorStandardBg",colorMix(private_safeLighten,I?d("palette-error-light"):t.error.light,.9)),setColor(t.Alert,"infoStandardBg",colorMix(private_safeLighten,I?d("palette-info-light"):t.info.light,.9)),setColor(t.Alert,"successStandardBg",colorMix(private_safeLighten,I?d("palette-success-light"):t.success.light,.9)),setColor(t.Alert,"warningStandardBg",colorMix(private_safeLighten,I?d("palette-warning-light"):t.warning.light,.9)),setColor(t.Alert,"errorIconColor",setCssVarColor("palette-error-main")),setColor(t.Alert,"infoIconColor",setCssVarColor("palette-info-main")),setColor(t.Alert,"successIconColor",setCssVarColor("palette-success-main")),setColor(t.Alert,"warningIconColor",setCssVarColor("palette-warning-main")),setColor(t.AppBar,"defaultBg",setCssVarColor("palette-grey-100")),setColor(t.Avatar,"defaultBg",setCssVarColor("palette-grey-400")),setColor(t.Button,"inheritContainedBg",setCssVarColor("palette-grey-300")),setColor(t.Button,"inheritContainedHoverBg",setCssVarColor("palette-grey-A100")),setColor(t.Chip,"defaultBorder",setCssVarColor("palette-grey-400")),setColor(t.Chip,"defaultAvatarColor",setCssVarColor("palette-grey-700")),setColor(t.Chip,"defaultIconColor",setCssVarColor("palette-grey-700")),setColor(t.FilledInput,"bg","rgba(0, 0, 0, 0.06)"),setColor(t.FilledInput,"hoverBg","rgba(0, 0, 0, 0.09)"),setColor(t.FilledInput,"disabledBg","rgba(0, 0, 0, 0.12)"),setColor(t.LinearProgress,"primaryBg",colorMix(private_safeLighten,I?d("palette-primary-main"):t.primary.main,.62)),setColor(t.LinearProgress,"secondaryBg",colorMix(private_safeLighten,I?d("palette-secondary-main"):t.secondary.main,.62)),setColor(t.LinearProgress,"errorBg",colorMix(private_safeLighten,I?d("palette-error-main"):t.error.main,.62)),setColor(t.LinearProgress,"infoBg",colorMix(private_safeLighten,I?d("palette-info-main"):t.info.main,.62)),setColor(t.LinearProgress,"successBg",colorMix(private_safeLighten,I?d("palette-success-main"):t.success.main,.62)),setColor(t.LinearProgress,"warningBg",colorMix(private_safeLighten,I?d("palette-warning-light"):t.warning.main,.62)),setColor(t.Skeleton,"bg",v?colorMix(private_safeAlpha,I?d("palette-text-primary"):t.text.primary,.11):`rgba(${setCssVarColor("palette-text-primaryChannel")} / 0.11)`),setColor(t.Slider,"primaryTrack",colorMix(private_safeLighten,I?d("palette-primary-main"):t.primary.main,.62)),setColor(t.Slider,"secondaryTrack",colorMix(private_safeLighten,I?d("palette-secondary-main"):t.secondary.main,.62)),setColor(t.Slider,"errorTrack",colorMix(private_safeLighten,I?d("palette-error-main"):t.error.main,.62)),setColor(t.Slider,"infoTrack",colorMix(private_safeLighten,I?d("palette-info-main"):t.info.main,.62)),setColor(t.Slider,"successTrack",colorMix(private_safeLighten,I?d("palette-success-main"):t.success.main,.62)),setColor(t.Slider,"warningTrack",colorMix(private_safeLighten,I?d("palette-warning-main"):t.warning.main,.62));const e=v?colorMix(private_safeDarken,I?d("palette-background-default"):t.background.default,.6825):private_safeEmphasize(t.background.default,.8);setColor(t.SnackbarContent,"bg",e),setColor(t.SnackbarContent,"color",silent(()=>v?An.text.primary:t.getContrastText(e))),setColor(t.SpeedDialAction,"fabHoverBg",private_safeEmphasize(t.background.paper,.15)),setColor(t.StepConnector,"border",setCssVarColor("palette-grey-400")),setColor(t.StepContent,"border",setCssVarColor("palette-grey-400")),setColor(t.Switch,"defaultColor",setCssVarColor("palette-common-white")),setColor(t.Switch,"defaultDisabledColor",setCssVarColor("palette-grey-100")),setColor(t.Switch,"primaryDisabledColor",colorMix(private_safeLighten,I?d("palette-primary-main"):t.primary.main,.62)),setColor(t.Switch,"secondaryDisabledColor",colorMix(private_safeLighten,I?d("palette-secondary-main"):t.secondary.main,.62)),setColor(t.Switch,"errorDisabledColor",colorMix(private_safeLighten,I?d("palette-error-main"):t.error.main,.62)),setColor(t.Switch,"infoDisabledColor",colorMix(private_safeLighten,I?d("palette-info-main"):t.info.main,.62)),setColor(t.Switch,"successDisabledColor",colorMix(private_safeLighten,I?d("palette-success-main"):t.success.main,.62)),setColor(t.Switch,"warningDisabledColor",colorMix(private_safeLighten,I?d("palette-warning-main"):t.warning.main,.62)),setColor(t.TableCell,"border",colorMix(private_safeLighten,private_safeAlpha(I?d("palette-divider"):t.divider,1),.88)),setColor(t.Tooltip,"bg",colorMix(private_safeAlpha,I?d("palette-grey-700"):t.grey[700],.92))}if("dark"===t.mode){setColor(t.Alert,"errorColor",colorMix(private_safeLighten,I?d("palette-error-light"):t.error.light,.6)),setColor(t.Alert,"infoColor",colorMix(private_safeLighten,I?d("palette-info-light"):t.info.light,.6)),setColor(t.Alert,"successColor",colorMix(private_safeLighten,I?d("palette-success-light"):t.success.light,.6)),setColor(t.Alert,"warningColor",colorMix(private_safeLighten,I?d("palette-warning-light"):t.warning.light,.6)),setColor(t.Alert,"errorFilledBg",setCssVarColor("palette-error-dark")),setColor(t.Alert,"infoFilledBg",setCssVarColor("palette-info-dark")),setColor(t.Alert,"successFilledBg",setCssVarColor("palette-success-dark")),setColor(t.Alert,"warningFilledBg",setCssVarColor("palette-warning-dark")),setColor(t.Alert,"errorFilledColor",silent(()=>t.getContrastText(t.error.dark))),setColor(t.Alert,"infoFilledColor",silent(()=>t.getContrastText(t.info.dark))),setColor(t.Alert,"successFilledColor",silent(()=>t.getContrastText(t.success.dark))),setColor(t.Alert,"warningFilledColor",silent(()=>t.getContrastText(t.warning.dark))),setColor(t.Alert,"errorStandardBg",colorMix(private_safeDarken,I?d("palette-error-light"):t.error.light,.9)),setColor(t.Alert,"infoStandardBg",colorMix(private_safeDarken,I?d("palette-info-light"):t.info.light,.9)),setColor(t.Alert,"successStandardBg",colorMix(private_safeDarken,I?d("palette-success-light"):t.success.light,.9)),setColor(t.Alert,"warningStandardBg",colorMix(private_safeDarken,I?d("palette-warning-light"):t.warning.light,.9)),setColor(t.Alert,"errorIconColor",setCssVarColor("palette-error-main")),setColor(t.Alert,"infoIconColor",setCssVarColor("palette-info-main")),setColor(t.Alert,"successIconColor",setCssVarColor("palette-success-main")),setColor(t.Alert,"warningIconColor",setCssVarColor("palette-warning-main")),setColor(t.AppBar,"defaultBg",setCssVarColor("palette-grey-900")),setColor(t.AppBar,"darkBg",setCssVarColor("palette-background-paper")),setColor(t.AppBar,"darkColor",setCssVarColor("palette-text-primary")),setColor(t.Avatar,"defaultBg",setCssVarColor("palette-grey-600")),setColor(t.Button,"inheritContainedBg",setCssVarColor("palette-grey-800")),setColor(t.Button,"inheritContainedHoverBg",setCssVarColor("palette-grey-700")),setColor(t.Chip,"defaultBorder",setCssVarColor("palette-grey-700")),setColor(t.Chip,"defaultAvatarColor",setCssVarColor("palette-grey-300")),setColor(t.Chip,"defaultIconColor",setCssVarColor("palette-grey-300")),setColor(t.FilledInput,"bg","rgba(255, 255, 255, 0.09)"),setColor(t.FilledInput,"hoverBg","rgba(255, 255, 255, 0.13)"),setColor(t.FilledInput,"disabledBg","rgba(255, 255, 255, 0.12)"),setColor(t.LinearProgress,"primaryBg",colorMix(private_safeDarken,I?d("palette-primary-main"):t.primary.main,.5)),setColor(t.LinearProgress,"secondaryBg",colorMix(private_safeDarken,I?d("palette-secondary-main"):t.secondary.main,.5)),setColor(t.LinearProgress,"errorBg",colorMix(private_safeDarken,I?d("palette-error-main"):t.error.main,.5)),setColor(t.LinearProgress,"infoBg",colorMix(private_safeDarken,I?d("palette-info-main"):t.info.main,.5)),setColor(t.LinearProgress,"successBg",colorMix(private_safeDarken,I?d("palette-success-main"):t.success.main,.5)),setColor(t.LinearProgress,"warningBg",colorMix(private_safeDarken,I?d("palette-warning-main"):t.warning.main,.5)),setColor(t.Skeleton,"bg",v?colorMix(private_safeAlpha,I?d("palette-text-primary"):t.text.primary,.13):`rgba(${setCssVarColor("palette-text-primaryChannel")} / 0.13)`),setColor(t.Slider,"primaryTrack",colorMix(private_safeDarken,I?d("palette-primary-main"):t.primary.main,.5)),setColor(t.Slider,"secondaryTrack",colorMix(private_safeDarken,I?d("palette-secondary-main"):t.secondary.main,.5)),setColor(t.Slider,"errorTrack",colorMix(private_safeDarken,I?d("palette-error-main"):t.error.main,.5)),setColor(t.Slider,"infoTrack",colorMix(private_safeDarken,I?d("palette-info-main"):t.info.main,.5)),setColor(t.Slider,"successTrack",colorMix(private_safeDarken,I?d("palette-success-main"):t.success.main,.5)),setColor(t.Slider,"warningTrack",colorMix(private_safeDarken,I?d("palette-warning-light"):t.warning.main,.5));const e=v?colorMix(private_safeLighten,I?d("palette-background-default"):t.background.default,.985):private_safeEmphasize(t.background.default,.98);setColor(t.SnackbarContent,"bg",e),setColor(t.SnackbarContent,"color",silent(()=>v?nn.text.primary:t.getContrastText(e))),setColor(t.SpeedDialAction,"fabHoverBg",private_safeEmphasize(t.background.paper,.15)),setColor(t.StepConnector,"border",setCssVarColor("palette-grey-600")),setColor(t.StepContent,"border",setCssVarColor("palette-grey-600")),setColor(t.Switch,"defaultColor",setCssVarColor("palette-grey-300")),setColor(t.Switch,"defaultDisabledColor",setCssVarColor("palette-grey-600")),setColor(t.Switch,"primaryDisabledColor",colorMix(private_safeDarken,I?d("palette-primary-main"):t.primary.main,.55)),setColor(t.Switch,"secondaryDisabledColor",colorMix(private_safeDarken,I?d("palette-secondary-main"):t.secondary.main,.55)),setColor(t.Switch,"errorDisabledColor",colorMix(private_safeDarken,I?d("palette-error-main"):t.error.main,.55)),setColor(t.Switch,"infoDisabledColor",colorMix(private_safeDarken,I?d("palette-info-main"):t.info.main,.55)),setColor(t.Switch,"successDisabledColor",colorMix(private_safeDarken,I?d("palette-success-main"):t.success.main,.55)),setColor(t.Switch,"warningDisabledColor",colorMix(private_safeDarken,I?d("palette-warning-light"):t.warning.main,.55)),setColor(t.TableCell,"border",colorMix(private_safeDarken,private_safeAlpha(I?d("palette-divider"):t.divider,1),.68)),setColor(t.Tooltip,"bg",colorMix(private_safeAlpha,I?d("palette-grey-700"):t.grey[700],.92))}I||(setColorChannel(t.background,"default"),setColorChannel(t.background,"paper"),setColorChannel(t.common,"background"),setColorChannel(t.common,"onBackground"),setColorChannel(t,"divider")),Object.keys(t).forEach(e=>{const g=t[e];"tonalOffset"!==e&&!I&&g&&"object"==typeof g&&(g.main&&setColor(t[e],"mainChannel",private_safeColorChannel(toRgb(g.main))),g.light&&setColor(t[e],"lightChannel",private_safeColorChannel(toRgb(g.light))),g.dark&&setColor(t[e],"darkChannel",private_safeColorChannel(toRgb(g.dark))),g.contrastText&&setColor(t[e],"contrastTextChannel",private_safeColorChannel(toRgb(g.contrastText))),"text"===e&&(setColorChannel(t[e],"primary"),setColorChannel(t[e],"secondary")),"action"===e&&(g.active&&setColorChannel(t[e],"active"),g.selected&&setColorChannel(t[e],"selected")))})}),w=t.reduce((e,t)=>deepmerge(e,t),w);const E={prefix:o,disableCssColorScheme:C,shouldSkipGeneratingVar:a,getSelector:defaultGetSelector(w),enableContrastVars:I},{vars:R,generateThemeVars:M,generateStyleSheets:T}=prepareCssVars(w,E);return w.vars=R,Object.entries(w.colorSchemes[w.defaultColorScheme]).forEach(([e,t])=>{w[e]=t}),w.generateThemeVars=M,w.generateStyleSheets=T,w.generateSpacing=function(){return createSpacing(l.spacing,createUnarySpacing(this))},w.getColorSchemeSelector=createGetColorSchemeSelector(i),w.spacing=w.generateSpacing(),w.shouldSkipGeneratingVar=a,w.unstable_sxConfig={...Rr,...l?.unstable_sxConfig},w.unstable_sx=function(e){return kr({sx:e,theme:this})},w.toRuntimeSource=stringifyTheme,w}function attachColorScheme(e,t,g){e.colorSchemes&&g&&(e.colorSchemes[t]={...!0!==g&&g,palette:createPalette({...!0===g?{}:g.palette,mode:t})})}function createTheme(e={},...t){const{palette:g,cssVariables:n=!1,colorSchemes:C=(g?void 0:{light:!0}),defaultColorScheme:o=g?.mode,...I}=e,a=o||"light",i=C?.[a],s={...C,...g?{[a]:{..."boolean"!=typeof i&&i,palette:g}}:void 0};if(!1===n){if(!("colorSchemes"in e))return createThemeNoVars(e,...t);let n=g;"palette"in e||s[a]&&(!0!==s[a]?n=s[a].palette:"dark"===a&&(n={mode:"dark"}));const C=createThemeNoVars({...e,palette:n},...t);return C.defaultColorScheme=a,C.colorSchemes=s,"light"===C.palette.mode&&(C.colorSchemes.light={...!0!==s.light&&s.light,palette:C.palette},attachColorScheme(C,"dark",s.dark)),"dark"===C.palette.mode&&(C.colorSchemes.dark={...!0!==s.dark&&s.dark,palette:C.palette},attachColorScheme(C,"light",s.light)),C}return g||"light"in s||"light"!==a||(s.light=!0),createThemeWithVars({...I,colorSchemes:s,defaultColorScheme:a,..."boolean"!=typeof n&&n},...t)}const hn=createTheme();function useTheme$1(){const e=useTheme$3(hn);return e[Xr]||e}function slotShouldForwardProp(e){return"ownerState"!==e&&"theme"!==e&&"sx"!==e&&"as"!==e}const rootShouldForwardProp=e=>slotShouldForwardProp(e)&&"classes"!==e,yn=createStyled({themeId:Xr,defaultTheme:hn,rootShouldForwardProp});function ThemeProviderNoVars({theme:e,...t}){const g=Xr in e?e[Xr]:void 0;return Hg.jsx(ThemeProvider$1,{...t,themeId:g?Xr:void 0,theme:g||e})}const bn={colorSchemeStorageKey:"mui-color-scheme",defaultLightColorScheme:"light",defaultDarkColorScheme:"dark",modeStorageKey:"mui-mode"},{CssVarsProvider:vn}=createCssVarsProvider({themeId:Xr,theme:()=>createTheme({cssVariables:!0}),colorSchemeStorageKey:bn.colorSchemeStorageKey,modeStorageKey:bn.modeStorageKey,defaultColorScheme:{light:bn.defaultLightColorScheme,dark:bn.defaultDarkColorScheme},resolveTheme:e=>{const t={...e,typography:createTypography(e.palette,e.typography)};return t.unstable_sx=function(e){return kr({sx:e,theme:this})},t}}),xn=vn;function ThemeProvider({theme:e,...t}){const g=C.useMemo(()=>{if("function"==typeof e)return e;const t=Xr in e?e[Xr]:e;return"colorSchemes"in t?null:"vars"in t?e:{...e,vars:null}},[e]);return g?Hg.jsx(ThemeProviderNoVars,{theme:g,...t}):Hg.jsx(xn,{theme:e,...t})}const Sn=generateUtilityClasses("MuiBox",["root"]),wn=createTheme(),En=createBox({themeId:Xr,defaultTheme:wn,defaultClassName:Sn.root,generateClassName:Tr.generate}),cloneTokens=e=>structuredClone(e),buildHueFilter=e=>`hue-rotate(${e}deg)`,createMuiTheme=(e=St)=>{const t=e??St;return createTheme({spacing:t.spacing.unit,shape:{borderRadius:t.radius.panel},typography:{fontSize:t.theme.fontSize},palette:{mode:"dark",primary:{main:t.text.accent},background:{default:t.background.primary,paper:t.background.panel},text:{primary:t.text.primary,secondary:t.text.secondary,disabled:t.text.muted},hp:{main:t.game.hp},mp:{main:t.game.mp},ep:{main:t.game.ep},wp:{main:t.game.wp},nl:{main:t.game.nl},timerActive:{main:t.game.timerActive},timerCritical:{main:t.game.timerCritical}},components:{MuiTooltip:{defaultProps:{arrow:!0,placement:"top"}},MuiPaper:{defaultProps:{elevation:0}},MuiButton:{defaultProps:{size:"small"}},MuiSwitch:{defaultProps:{size:"small"}},MuiSlider:{defaultProps:{size:"small"}}},nexGui:{backgroundImage:resolveBackgroundImageSource(t.theme.backgroundImage),backgroundOpacity:t.theme.backgroundOpacity,backgroundFilter:buildHueFilter(t.theme.hue),radius:cloneTokens(t.radius),tokens:cloneTokens(t)}})};function GlobalStyles(e){return Hg.jsx(GlobalStyles$1,{...e,defaultTheme:hn,themeId:Xr})}function globalCss(e){return function(t){return Hg.jsx(GlobalStyles,{styles:"function"==typeof e?g=>e({theme:g,...t}):e})}}function internal_createExtendSxProp(){return extendSxProp$1}const Rn=unstable_memoTheme;function useDefaultProps(e){return useDefaultProps$1(e)}function getPaperUtilityClass(e){return generateUtilityClass("MuiPaper",e)}generateUtilityClasses("MuiPaper",["root","rounded","outlined","elevation","elevation0","elevation1","elevation2","elevation3","elevation4","elevation5","elevation6","elevation7","elevation8","elevation9","elevation10","elevation11","elevation12","elevation13","elevation14","elevation15","elevation16","elevation17","elevation18","elevation19","elevation20","elevation21","elevation22","elevation23","elevation24"]);const useUtilityClasses$C=e=>{const{square:t,elevation:g,variant:n,classes:C}=e;return composeClasses({root:["root",n,!t&&"rounded","elevation"===n&&`elevation${g}`]},getPaperUtilityClass,C)},kn=yn("div",{name:"MuiPaper",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:g}=e;return[t.root,t[g.variant],!g.square&&t.rounded,"elevation"===g.variant&&t[`elevation${g.elevation}`]]}})(Rn(({theme:e})=>({backgroundColor:(e.vars||e).palette.background.paper,color:(e.vars||e).palette.text.primary,transition:e.transitions.create("box-shadow"),variants:[{props:({ownerState:e})=>!e.square,style:{borderRadius:e.shape.borderRadius}},{props:{variant:"outlined"},style:{border:`1px solid ${(e.vars||e).palette.divider}`}},{props:{variant:"elevation"},style:{boxShadow:"var(--Paper-shadow)",backgroundImage:"var(--Paper-overlay)"}}]}))),Mn=C.forwardRef(function(e,t){const g=useDefaultProps({props:e,name:"MuiPaper"}),n=useTheme$1(),{className:C,component:o="div",elevation:I=1,square:a=!1,variant:i="elevation",...s}=g,l={...g,component:o,elevation:I,square:a,variant:i},c=useUtilityClasses$C(l);return Hg.jsx(kn,{as:o,ownerState:l,className:clsx(c.root,C),ref:t,...s,style:{..."elevation"===i&&{"--Paper-shadow":(n.vars||n).shadows[I],...n.vars&&{"--Paper-overlay":n.vars.overlays?.[I]},...!n.vars&&"dark"===n.palette.mode&&{"--Paper-overlay":`linear-gradient(${alpha("#fff",getOverlayAlpha(I))}, ${alpha("#fff",getOverlayAlpha(I))})`}},...s.style}})}),Tn=createStack({createStyledComponent:yn("div",{name:"MuiStack",slot:"Root"}),useThemeProps:e=>useDefaultProps({props:e,name:"MuiStack"})}),DefenceTagComponent=({name:e})=>React.createElement(Mn,{className:"defence-tag",elevation:3,sx:{fontFamily:"inherit",fontSize:"inherit",px:.75,py:"2px",textAlign:"center",width:"100%"}},e);DefenceTagComponent.displayName="DefenceTag",DefenceTagComponent.propTypes={name:Fg.string.isRequired};const Pn=t.memo(DefenceTagComponent);function hasCorrectMainProperty(e){return"string"==typeof e.main}function checkSimplePaletteColorValues(e,t=[]){if(!hasCorrectMainProperty(e))return!1;for(const g of t)if(!e.hasOwnProperty(g)||"string"!=typeof e[g])return!1;return!0}function createSimplePaletteValueFilter(e=[]){return([,t])=>t&&checkSimplePaletteColorValues(t,e)}function getTypographyUtilityClass(e){return generateUtilityClass("MuiTypography",e)}Pn.displayName="DefenceTag",Pn.propTypes=DefenceTagComponent.propTypes,generateUtilityClasses("MuiTypography",["root","h1","h2","h3","h4","h5","h6","subtitle1","subtitle2","body1","body2","inherit","button","caption","overline","alignLeft","alignRight","alignCenter","alignJustify","noWrap","gutterBottom","paragraph"]);const Nn={primary:!0,secondary:!0,error:!0,info:!0,success:!0,warning:!0,textPrimary:!0,textSecondary:!0,textDisabled:!0},On=internal_createExtendSxProp(),useUtilityClasses$B=e=>{const{align:t,gutterBottom:g,noWrap:n,paragraph:C,variant:o,classes:I}=e;return composeClasses({root:["root",o,"inherit"!==e.align&&`align${capitalize(t)}`,g&&"gutterBottom",n&&"noWrap",C&&"paragraph"]},getTypographyUtilityClass,I)},Dn=yn("span",{name:"MuiTypography",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:g}=e;return[t.root,g.variant&&t[g.variant],"inherit"!==g.align&&t[`align${capitalize(g.align)}`],g.noWrap&&t.noWrap,g.gutterBottom&&t.gutterBottom,g.paragraph&&t.paragraph]}})(Rn(({theme:e})=>({margin:0,variants:[{props:{variant:"inherit"},style:{font:"inherit",lineHeight:"inherit",letterSpacing:"inherit"}},...Object.entries(e.typography).filter(([e,t])=>"inherit"!==e&&t&&"object"==typeof t).map(([e,t])=>({props:{variant:e},style:t})),...Object.entries(e.palette).filter(createSimplePaletteValueFilter()).map(([t])=>({props:{color:t},style:{color:(e.vars||e).palette[t].main}})),...Object.entries(e.palette?.text||{}).filter(([,e])=>"string"==typeof e).map(([t])=>({props:{color:`text${capitalize(t)}`},style:{color:(e.vars||e).palette.text[t]}})),{props:({ownerState:e})=>"inherit"!==e.align,style:{textAlign:"var(--Typography-textAlign)"}},{props:({ownerState:e})=>e.noWrap,style:{overflow:"hidden",textOverflow:"ellipsis",whiteSpace:"nowrap"}},{props:({ownerState:e})=>e.gutterBottom,style:{marginBottom:"0.35em"}},{props:({ownerState:e})=>e.paragraph,style:{marginBottom:16}}]}))),jn={h1:"h1",h2:"h2",h3:"h3",h4:"h4",h5:"h5",h6:"h6",subtitle1:"h6",subtitle2:"h6",body1:"p",body2:"p",inherit:"p"},zn=C.forwardRef(function(e,t){const{color:g,...n}=useDefaultProps({props:e,name:"MuiTypography"}),C=!Nn[g],o=On({...n,...C&&{color:g}}),{align:I="inherit",className:a,component:i,gutterBottom:s=!1,noWrap:l=!1,paragraph:c=!1,variant:u="body1",variantMapping:d=jn,...p}=o,m={...o,align:I,color:g,className:a,component:i,gutterBottom:s,noWrap:l,paragraph:c,variant:u,variantMapping:d},h=i||(c?"p":d[u]||jn[u])||"span",y=useUtilityClasses$B(m);return Hg.jsx(Dn,{as:h,ref:t,className:clsx(y.root,a),...p,ownerState:m,style:{..."inherit"!==I&&{"--Typography-textAlign":I},...p.style}})}),getErrorMessage=e=>e instanceof Error&&e.message?e.message:"string"==typeof e&&e.length>0?e:"Unknown panel error.";class Ln extends t.Component{static displayName="PanelErrorBoundary";static propTypes={children:Fg.node,panelName:Fg.node.isRequired};static getDerivedStateFromError(e){return{error:e}}constructor(e){super(e),this.state={error:null}}componentDidCatch(){}render(){const{children:e,panelName:t}=this.props,{error:g}=this.state;return g?React.createElement(En,{className:"nexgui4-panel-error-boundary",role:"alert",sx:{backgroundColor:"background.paper",border:1,borderColor:"divider",borderRadius:1,color:"text.primary",display:"flex",flex:1,flexDirection:"column",gap:1,minHeight:0,minWidth:0,p:1.5,width:"100%"}},React.createElement(zn,{component:"h2",sx:{fontSize:"0.95rem",fontWeight:700}},t),React.createElement(zn,{color:"text.secondary",variant:"body2"},"This panel failed to render."),React.createElement(zn,{sx:{fontFamily:"monospace",overflowWrap:"anywhere"},variant:"body2"},getErrorMessage(g))):e}}const isIterable=e=>Symbol.iterator in e,hasIterableEntries=e=>"entries"in e,compareEntries=(e,t)=>{const g=e instanceof Map?e:new Map(e.entries()),n=t instanceof Map?t:new Map(t.entries());if(g.size!==n.size)return!1;for(const[C,o]of g)if(!n.has(C)||!Object.is(o,n.get(C)))return!1;return!0},compareIterables=(e,t)=>{const g=e[Symbol.iterator](),n=t[Symbol.iterator]();let C=g.next(),o=n.next();for(;!C.done&&!o.done;){if(!Object.is(C.value,o.value))return!1;C=g.next(),o=n.next()}return!!C.done&&!!o.done};function shallow(e,t){return!!Object.is(e,t)||"object"==typeof e&&null!==e&&"object"==typeof t&&null!==t&&Object.getPrototypeOf(e)===Object.getPrototypeOf(t)&&(isIterable(e)&&isIterable(t)?hasIterableEntries(e)&&hasIterableEntries(t)?compareEntries(e,t):compareIterables(e,t):compareEntries({entries:()=>Object.entries(e)},{entries:()=>Object.entries(t)}))}function useShallow(e){const g=t.useRef(void 0);return t=>{const n=e(t);return shallow(g.current,n)?g.current:g.current=n}}const selectDefenceSlice=e=>({configuredDefences:e.configuredDefences,defences:e.defences,gainDefence:e.gainDefence,loseDefence:e.loseDefence,resetDefences:e.resetDefences,setConfiguredDefences:e.setConfiguredDefences}),useDefence=()=>{const{stores:e}=useNexGui();return e.defence(useShallow(selectDefenceSlice))},getFlipTransform$a=e=>{switch(e){case 1:return"scaleX(-1) scaleY(-1)";case 2:return"scaleY(-1)";case 3:return"scaleX(-1)";default:return"none"}},DefencesPanelInner=()=>{const e=useTheme$1(),[g]=t.useState(()=>Math.floor(4*Math.random())),{configuredDefences:n,defences:C}=useDefence(),o=e?.nexGui?.backgroundImage??"",I=e?.nexGui?.backgroundOpacity??.5,a=e?.nexGui?.backgroundFilter??"none",i=new Set(C),s=n.filter(e=>!i.has(e)),l=s.length>0;return React.createElement(En,{className:"defences-panel",sx:{color:"text.primary",fontFamily:e.typography.fontFamily,fontSize:e.typography.fontSize,height:"100%",overflow:"hidden",position:"relative",width:"100%"}},o?React.createElement(En,{"aria-hidden":"true",className:"defences-panel__background",sx:{backgroundImage:`url(${o})`,backgroundPosition:"center",backgroundSize:"cover",filter:a,inset:0,opacity:I,position:"absolute",transform:getFlipTransform$a(g),zIndex:0}}):null,l?React.createElement(En,{className:"defences-panel__content",sx:{height:"100%",overflowY:"auto",p:1,position:"relative",width:"100%",zIndex:1}},React.createElement(Mn,{className:"defences-panel__surface",elevation:0,sx:{backgroundColor:alpha(e.palette.background.paper,.78),minHeight:"100%",p:1}},React.createElement(Tn,{spacing:.5,sx:{position:"relative",width:"100%"}},s.map(e=>React.createElement(Pn,{key:e,name:e}))))):null)};DefencesPanelInner.displayName="DefencesPanelInner";const DefencesPanel=()=>React.createElement(Ln,{panelName:"Defences"},React.createElement(DefencesPanelInner,null));function memo(e,t,g){let n,C=g.initialDeps??[],o=!0;function memoizedFunction(){var I,a,i;let s;g.key&&(null==(I=g.debug)?void 0:I.call(g))&&(s=Date.now());const l=e();if(l.length===C.length&&!l.some((e,t)=>C[t]!==e))return n;let c;if(C=l,g.key&&(null==(a=g.debug)?void 0:a.call(g))&&(c=Date.now()),n=t(...l),g.key&&(null==(i=g.debug)?void 0:i.call(g))){const e=Math.round(100*(Date.now()-s))/100,t=Math.round(100*(Date.now()-c))/100,n=t/16,pad=(e,t)=>{for(e=String(e);e.length<t;)e=" "+e;return e};console.info(`%c⏱ ${pad(t,5)} /${pad(e,5)} ms`,`\n font-size: .6rem;\n font-weight: bold;\n color: hsl(${Math.max(0,Math.min(120-120*n,120))}deg 100% 31%);`,null==g?void 0:g.key)}return!(null==g?void 0:g.onChange)||o&&g.skipInitialOnChange||g.onChange(n),o=!1,n}return memoizedFunction.updateDeps=e=>{C=e},memoizedFunction}function notUndefined(e,t){if(void 0===e)throw new Error("Unexpected undefined");return e}DefencesPanel.displayName="DefencesPanel";const approxEqual=(e,t)=>Math.abs(e-t)<1.01,debounce$2=(e,t,g)=>{let n;return function(...C){e.clearTimeout(n),n=e.setTimeout(()=>t.apply(this,C),g)}},getRect=e=>{const{offsetWidth:t,offsetHeight:g}=e;return{width:t,height:g}},defaultKeyExtractor=e=>e,defaultRangeExtractor=e=>{const t=Math.max(e.startIndex-e.overscan,0),g=Math.min(e.endIndex+e.overscan,e.count-1),n=[];for(let C=t;C<=g;C++)n.push(C);return n},observeElementRect=(e,t)=>{const g=e.scrollElement;if(!g)return;const n=e.targetWindow;if(!n)return;const handler=e=>{const{width:g,height:n}=e;t({width:Math.round(g),height:Math.round(n)})};if(handler(getRect(g)),!n.ResizeObserver)return()=>{};const C=new n.ResizeObserver(t=>{const run=()=>{const e=t[0];if(null==e?void 0:e.borderBoxSize){const t=e.borderBoxSize[0];if(t)return void handler({width:t.inlineSize,height:t.blockSize})}handler(getRect(g))};e.options.useAnimationFrameWithResizeObserver?requestAnimationFrame(run):run()});return C.observe(g,{box:"border-box"}),()=>{C.unobserve(g)}},Gn={passive:!0},Bn="undefined"==typeof window||"onscrollend"in window,observeElementOffset=(e,t)=>{const g=e.scrollElement;if(!g)return;const n=e.targetWindow;if(!n)return;let C=0;const o=e.options.useScrollendEvent&&Bn?()=>{}:debounce$2(n,()=>{t(C,!1)},e.options.isScrollingResetDelay),createHandler=n=>()=>{const{horizontal:I,isRtl:a}=e.options;C=I?g.scrollLeft*(a?-1:1):g.scrollTop,o(),t(C,n)},I=createHandler(!0),a=createHandler(!1);g.addEventListener("scroll",I,Gn);const i=e.options.useScrollendEvent&&Bn;return i&&g.addEventListener("scrollend",a,Gn),()=>{g.removeEventListener("scroll",I),i&&g.removeEventListener("scrollend",a)}},measureElement=(e,t,g)=>{if(null==t?void 0:t.borderBoxSize){const e=t.borderBoxSize[0];if(e)return Math.round(e[g.options.horizontal?"inlineSize":"blockSize"])}return e[g.options.horizontal?"offsetWidth":"offsetHeight"]},elementScroll=(e,{adjustments:t=0,behavior:g},n)=>{var C,o;const I=e+t;null==(o=null==(C=n.scrollElement)?void 0:C.scrollTo)||o.call(C,{[n.options.horizontal?"left":"top"]:I,behavior:g})};class Fn{constructor(e){this.unsubs=[],this.scrollElement=null,this.targetWindow=null,this.isScrolling=!1,this.scrollState=null,this.measurementsCache=[],this.itemSizeCache=new Map,this.laneAssignments=new Map,this.pendingMeasuredCacheIndexes=[],this.prevLanes=void 0,this.lanesChangedFlag=!1,this.lanesSettling=!1,this.scrollRect=null,this.scrollOffset=null,this.scrollDirection=null,this.scrollAdjustments=0,this.elementsCache=new Map,this.now=()=>{var e,t,g;return(null==(g=null==(t=null==(e=this.targetWindow)?void 0:e.performance)?void 0:t.now)?void 0:g.call(t))??Date.now()},this.observer=(()=>{let e=null;const get=()=>e||(this.targetWindow&&this.targetWindow.ResizeObserver?e=new this.targetWindow.ResizeObserver(e=>{e.forEach(e=>{const run=()=>{const t=e.target,g=this.indexFromElement(t);t.isConnected?this.shouldMeasureDuringScroll(g)&&this.resizeItem(g,this.options.measureElement(t,e,this)):this.observer.unobserve(t)};this.options.useAnimationFrameWithResizeObserver?requestAnimationFrame(run):run()})}):null);return{disconnect:()=>{var t;null==(t=get())||t.disconnect(),e=null},observe:e=>{var t;return null==(t=get())?void 0:t.observe(e,{box:"border-box"})},unobserve:e=>{var t;return null==(t=get())?void 0:t.unobserve(e)}}})(),this.range=null,this.setOptions=e=>{Object.entries(e).forEach(([t,g])=>{void 0===g&&delete e[t]}),this.options={debug:!1,initialOffset:0,overscan:1,paddingStart:0,paddingEnd:0,scrollPaddingStart:0,scrollPaddingEnd:0,horizontal:!1,getItemKey:defaultKeyExtractor,rangeExtractor:defaultRangeExtractor,onChange:()=>{},measureElement,initialRect:{width:0,height:0},scrollMargin:0,gap:0,indexAttribute:"data-index",initialMeasurementsCache:[],lanes:1,isScrollingResetDelay:150,enabled:!0,isRtl:!1,useScrollendEvent:!1,useAnimationFrameWithResizeObserver:!1,laneAssignmentMode:"estimate",...e}},this.notify=e=>{var t,g;null==(g=(t=this.options).onChange)||g.call(t,this,e)},this.maybeNotify=memo(()=>(this.calculateRange(),[this.isScrolling,this.range?this.range.startIndex:null,this.range?this.range.endIndex:null]),e=>{this.notify(e)},{key:!1,debug:()=>this.options.debug,initialDeps:[this.isScrolling,this.range?this.range.startIndex:null,this.range?this.range.endIndex:null]}),this.cleanup=()=>{this.unsubs.filter(Boolean).forEach(e=>e()),this.unsubs=[],this.observer.disconnect(),null!=this.rafId&&this.targetWindow&&(this.targetWindow.cancelAnimationFrame(this.rafId),this.rafId=null),this.scrollState=null,this.scrollElement=null,this.targetWindow=null},this._didMount=()=>()=>{this.cleanup()},this._willUpdate=()=>{var e;const t=this.options.enabled?this.options.getScrollElement():null;if(this.scrollElement!==t){if(this.cleanup(),!t)return void this.maybeNotify();this.scrollElement=t,this.scrollElement&&"ownerDocument"in this.scrollElement?this.targetWindow=this.scrollElement.ownerDocument.defaultView:this.targetWindow=(null==(e=this.scrollElement)?void 0:e.window)??null,this.elementsCache.forEach(e=>{this.observer.observe(e)}),this.unsubs.push(this.options.observeElementRect(this,e=>{this.scrollRect=e,this.maybeNotify()})),this.unsubs.push(this.options.observeElementOffset(this,(e,t)=>{this.scrollAdjustments=0,this.scrollDirection=t?this.getScrollOffset()<e?"forward":"backward":null,this.scrollOffset=e,this.isScrolling=t,this.scrollState&&this.scheduleScrollReconcile(),this.maybeNotify()})),this._scrollToOffset(this.getScrollOffset(),{adjustments:void 0,behavior:void 0})}},this.rafId=null,this.getSize=()=>this.options.enabled?(this.scrollRect=this.scrollRect??this.options.initialRect,this.scrollRect[this.options.horizontal?"width":"height"]):(this.scrollRect=null,0),this.getScrollOffset=()=>this.options.enabled?(this.scrollOffset=this.scrollOffset??("function"==typeof this.options.initialOffset?this.options.initialOffset():this.options.initialOffset),this.scrollOffset):(this.scrollOffset=null,0),this.getFurthestMeasurement=(e,t)=>{const g=new Map,n=new Map;for(let C=t-1;C>=0;C--){const t=e[C];if(g.has(t.lane))continue;const o=n.get(t.lane);if(null==o||t.end>o.end?n.set(t.lane,t):t.end<o.end&&g.set(t.lane,!0),g.size===this.options.lanes)break}return n.size===this.options.lanes?Array.from(n.values()).sort((e,t)=>e.end===t.end?e.index-t.index:e.end-t.end)[0]:void 0},this.getMeasurementOptions=memo(()=>[this.options.count,this.options.paddingStart,this.options.scrollMargin,this.options.getItemKey,this.options.enabled,this.options.lanes,this.options.laneAssignmentMode],(e,t,g,n,C,o,I)=>(void 0!==this.prevLanes&&this.prevLanes!==o&&(this.lanesChangedFlag=!0),this.prevLanes=o,this.pendingMeasuredCacheIndexes=[],{count:e,paddingStart:t,scrollMargin:g,getItemKey:n,enabled:C,lanes:o,laneAssignmentMode:I}),{key:!1}),this.getMeasurements=memo(()=>[this.getMeasurementOptions(),this.itemSizeCache],({count:e,paddingStart:t,scrollMargin:g,getItemKey:n,enabled:C,lanes:o,laneAssignmentMode:I},a)=>{if(!C)return this.measurementsCache=[],this.itemSizeCache.clear(),this.laneAssignments.clear(),[];if(this.laneAssignments.size>e)for(const c of this.laneAssignments.keys())c>=e&&this.laneAssignments.delete(c);this.lanesChangedFlag&&(this.lanesChangedFlag=!1,this.lanesSettling=!0,this.measurementsCache=[],this.itemSizeCache.clear(),this.laneAssignments.clear(),this.pendingMeasuredCacheIndexes=[]),0!==this.measurementsCache.length||this.lanesSettling||(this.measurementsCache=this.options.initialMeasurementsCache,this.measurementsCache.forEach(e=>{this.itemSizeCache.set(e.key,e.size)}));const i=this.lanesSettling?0:this.pendingMeasuredCacheIndexes.length>0?Math.min(...this.pendingMeasuredCacheIndexes):0;this.pendingMeasuredCacheIndexes=[],this.lanesSettling&&this.measurementsCache.length===e&&(this.lanesSettling=!1);const s=this.measurementsCache.slice(0,i),l=new Array(o).fill(void 0);for(let c=0;c<i;c++){const e=s[c];e&&(l[e.lane]=c)}for(let c=i;c<e;c++){const e=n(c),C=this.laneAssignments.get(c);let o,i;const u="estimate"===I||a.has(e);if(void 0!==C&&this.options.lanes>1){o=C;const e=l[o],n=void 0!==e?s[e]:void 0;i=n?n.end+this.options.gap:t+g}else{const e=1===this.options.lanes?s[c-1]:this.getFurthestMeasurement(s,c);i=e?e.end+this.options.gap:t+g,o=e?e.lane:c%this.options.lanes,this.options.lanes>1&&u&&this.laneAssignments.set(c,o)}const d=a.get(e),p="number"==typeof d?d:this.options.estimateSize(c),m=i+p;s[c]={index:c,start:i,size:p,end:m,key:e,lane:o},l[o]=c}return this.measurementsCache=s,s},{key:!1,debug:()=>this.options.debug}),this.calculateRange=memo(()=>[this.getMeasurements(),this.getSize(),this.getScrollOffset(),this.options.lanes],(e,t,g,n)=>this.range=e.length>0&&t>0?calculateRange({measurements:e,outerSize:t,scrollOffset:g,lanes:n}):null,{key:!1,debug:()=>this.options.debug}),this.getVirtualIndexes=memo(()=>{let e=null,t=null;const g=this.calculateRange();return g&&(e=g.startIndex,t=g.endIndex),this.maybeNotify.updateDeps([this.isScrolling,e,t]),[this.options.rangeExtractor,this.options.overscan,this.options.count,e,t]},(e,t,g,n,C)=>null===n||null===C?[]:e({startIndex:n,endIndex:C,overscan:t,count:g}),{key:!1,debug:()=>this.options.debug}),this.indexFromElement=e=>{const t=this.options.indexAttribute,g=e.getAttribute(t);return g?parseInt(g,10):(console.warn(`Missing attribute name '${t}={index}' on measured element.`),-1)},this.shouldMeasureDuringScroll=e=>{var t;if(!this.scrollState||"smooth"!==this.scrollState.behavior)return!0;const g=this.scrollState.index??(null==(t=this.getVirtualItemForOffset(this.scrollState.lastTargetOffset))?void 0:t.index);if(void 0!==g&&this.range){const t=Math.max(this.options.overscan,Math.ceil((this.range.endIndex-this.range.startIndex)/2)),n=Math.max(0,g-t),C=Math.min(this.options.count-1,g+t);return e>=n&&e<=C}return!0},this.measureElement=e=>{if(!e)return void this.elementsCache.forEach((e,t)=>{e.isConnected||(this.observer.unobserve(e),this.elementsCache.delete(t))});const t=this.indexFromElement(e),g=this.options.getItemKey(t),n=this.elementsCache.get(g);n!==e&&(n&&this.observer.unobserve(n),this.observer.observe(e),this.elementsCache.set(g,e)),this.isScrolling&&!this.scrollState||!this.shouldMeasureDuringScroll(t)||this.resizeItem(t,this.options.measureElement(e,void 0,this))},this.resizeItem=(e,t)=>{var g;const n=this.measurementsCache[e];if(!n)return;const C=t-(this.itemSizeCache.get(n.key)??n.size);0!==C&&("smooth"!==(null==(g=this.scrollState)?void 0:g.behavior)&&(void 0!==this.shouldAdjustScrollPositionOnItemSizeChange?this.shouldAdjustScrollPositionOnItemSizeChange(n,C,this):n.start<this.getScrollOffset()+this.scrollAdjustments)&&this._scrollToOffset(this.getScrollOffset(),{adjustments:this.scrollAdjustments+=C,behavior:void 0}),this.pendingMeasuredCacheIndexes.push(n.index),this.itemSizeCache=new Map(this.itemSizeCache.set(n.key,t)),this.notify(!1))},this.getVirtualItems=memo(()=>[this.getVirtualIndexes(),this.getMeasurements()],(e,t)=>{const g=[];for(let n=0,C=e.length;n<C;n++){const C=t[e[n]];g.push(C)}return g},{key:!1,debug:()=>this.options.debug}),this.getVirtualItemForOffset=e=>{const t=this.getMeasurements();if(0!==t.length)return notUndefined(t[findNearestBinarySearch(0,t.length-1,e=>notUndefined(t[e]).start,e)])},this.getMaxScrollOffset=()=>{if(!this.scrollElement)return 0;if("scrollHeight"in this.scrollElement)return this.options.horizontal?this.scrollElement.scrollWidth-this.scrollElement.clientWidth:this.scrollElement.scrollHeight-this.scrollElement.clientHeight;{const e=this.scrollElement.document.documentElement;return this.options.horizontal?e.scrollWidth-this.scrollElement.innerWidth:e.scrollHeight-this.scrollElement.innerHeight}},this.getOffsetForAlignment=(e,t,g=0)=>{if(!this.scrollElement)return 0;const n=this.getSize(),C=this.getScrollOffset();"auto"===t&&(t=e>=C+n?"end":"start"),"center"===t?e+=(g-n)/2:"end"===t&&(e-=n);const o=this.getMaxScrollOffset();return Math.max(Math.min(o,e),0)},this.getOffsetForIndex=(e,t="auto")=>{e=Math.max(0,Math.min(e,this.options.count-1));const g=this.getSize(),n=this.getScrollOffset(),C=this.measurementsCache[e];if(!C)return;if("auto"===t)if(C.end>=n+g-this.options.scrollPaddingEnd)t="end";else{if(!(C.start<=n+this.options.scrollPaddingStart))return[n,t];t="start"}if("end"===t&&e===this.options.count-1)return[this.getMaxScrollOffset(),t];const o="end"===t?C.end+this.options.scrollPaddingEnd:C.start-this.options.scrollPaddingStart;return[this.getOffsetForAlignment(o,t,C.size),t]},this.scrollToOffset=(e,{align:t="start",behavior:g="auto"}={})=>{const n=this.getOffsetForAlignment(e,t),C=this.now();this.scrollState={index:null,align:t,behavior:g,startedAt:C,lastTargetOffset:n,stableFrames:0},this._scrollToOffset(n,{adjustments:void 0,behavior:g}),this.scheduleScrollReconcile()},this.scrollToIndex=(e,{align:t="auto",behavior:g="auto"}={})=>{e=Math.max(0,Math.min(e,this.options.count-1));const n=this.getOffsetForIndex(e,t);if(!n)return;const[C,o]=n,I=this.now();this.scrollState={index:e,align:o,behavior:g,startedAt:I,lastTargetOffset:C,stableFrames:0},this._scrollToOffset(C,{adjustments:void 0,behavior:g}),this.scheduleScrollReconcile()},this.scrollBy=(e,{behavior:t="auto"}={})=>{const g=this.getScrollOffset()+e,n=this.now();this.scrollState={index:null,align:"start",behavior:t,startedAt:n,lastTargetOffset:g,stableFrames:0},this._scrollToOffset(g,{adjustments:void 0,behavior:t}),this.scheduleScrollReconcile()},this.getTotalSize=()=>{var e;const t=this.getMeasurements();let g;if(0===t.length)g=this.options.paddingStart;else if(1===this.options.lanes)g=(null==(e=t[t.length-1])?void 0:e.end)??0;else{const e=Array(this.options.lanes).fill(null);let n=t.length-1;for(;n>=0&&e.some(e=>null===e);){const g=t[n];null===e[g.lane]&&(e[g.lane]=g.end),n--}g=Math.max(...e.filter(e=>null!==e))}return Math.max(g-this.options.scrollMargin+this.options.paddingEnd,0)},this._scrollToOffset=(e,{adjustments:t,behavior:g})=>{this.options.scrollToFn(e,{behavior:g,adjustments:t},this)},this.measure=()=>{this.itemSizeCache=new Map,this.laneAssignments=new Map,this.notify(!1)},this.setOptions(e)}scheduleScrollReconcile(){this.targetWindow?null==this.rafId&&(this.rafId=this.targetWindow.requestAnimationFrame(()=>{this.rafId=null,this.reconcileScroll()})):this.scrollState=null}reconcileScroll(){if(!this.scrollState)return;if(!this.scrollElement)return;const e=5e3;if(this.now()-this.scrollState.startedAt>e)return void(this.scrollState=null);const t=null!=this.scrollState.index?this.getOffsetForIndex(this.scrollState.index,this.scrollState.align):void 0,g=t?t[0]:this.scrollState.lastTargetOffset,n=1,C=g!==this.scrollState.lastTargetOffset;if(!C&&approxEqual(g,this.getScrollOffset())){if(this.scrollState.stableFrames++,this.scrollState.stableFrames>=n)return void(this.scrollState=null)}else this.scrollState.stableFrames=0,C&&(this.scrollState.lastTargetOffset=g,this.scrollState.behavior="auto",this._scrollToOffset(g,{adjustments:void 0,behavior:"auto"}));this.scheduleScrollReconcile()}}const findNearestBinarySearch=(e,t,g,n)=>{for(;e<=t;){const C=(e+t)/2|0,o=g(C);if(o<n)e=C+1;else{if(!(o>n))return C;t=C-1}}return e>0?e-1:0};function calculateRange({measurements:e,outerSize:t,scrollOffset:g,lanes:n}){const C=e.length-1,getOffset=t=>e[t].start;if(e.length<=n)return{startIndex:0,endIndex:C};let o=findNearestBinarySearch(0,C,getOffset,g),I=o;if(1===n)for(;I<C&&e[I].end<g+t;)I++;else if(n>1){const a=Array(n).fill(0);for(;I<C&&a.some(e=>e<g+t);){const t=e[I];a[t.lane]=t.end,I++}const i=Array(n).fill(g+t);for(;o>=0&&i.some(e=>e>=g);){const t=e[o];i[t.lane]=t.start,o--}o=Math.max(0,o-o%n),I=Math.min(C,I+(n-1-I%n))}return{startIndex:o,endIndex:I}}const Wn="undefined"!=typeof document?C.useLayoutEffect:C.useEffect;function useVirtualizerBase({useFlushSync:e=!0,...t}){const g=C.useReducer(()=>({}),{})[1],o={...t,onChange:(C,o)=>{var I;e&&o?n.flushSync(g):g(),null==(I=t.onChange)||I.call(t,C,o)}},[I]=C.useState(()=>new Fn(o));return I.setOptions(o),Wn(()=>I._didMount(),[]),Wn(()=>I._willUpdate()),I}function useVirtualizer(e){return useVirtualizerBase({observeElementRect,observeElementOffset,scrollToFn:elementScroll,...e})}const Vn=1,Kn=24,Un=8,noop$5=()=>{},denyScrollPositionAdjustment=()=>!1,defaultEstimateSize=()=>48,defaultGetItemKey=(e,t)=>e?.id??t,joinClassNames=(...e)=>e.filter(Boolean).join(" "),getVirtualItemEnd=e=>Number.isFinite(e?.end)?e.end:Number.isFinite(e?.size)?e.start+e.size:e?.start??0,getElementWidth=(e,t=null)=>{const g=t?.contentRect?.width??e.getBoundingClientRect?.().width??e.clientWidth;return Number.isFinite(g)?g:0},getVerticalScrollbarGutterWidth=e=>{if(!e)return 0;const t=Number(e.offsetWidth),g=Number(e.clientWidth);return Number.isFinite(t)&&Number.isFinite(g)?Math.max(0,t-g):0},isNearBottom=e=>e.scrollHeight-e.scrollTop-e.clientHeight<=Kn,isPinnedToDisplayTail=e=>e.scrollHeight-e.scrollTop-e.clientHeight<=Vn,TranscriptViewportComponent=({items:e,renderItem:g,getItemKey:n=defaultGetItemKey,itemKeyVersion:C=null,displayPinKey:o=null,estimateSize:I=defaultEstimateSize,overscan:a=5,fontFamily:i="inherit",fontSize:s,border:l=!1,mode:c="panel",onRequestHistory:u=noop$5,onScrollLockChange:d=noop$5,activeMatchIndex:p=-1,footer:m=null,fallbackToAllItems:h=!1,onSendCommand:y=noop$5,showScrollLockBadge:b=!1,viewportSx:v,viewportTestId:x="virtual-scroll-viewport"},S)=>{const w=t.useRef(null),E=t.useRef(null),R=t.useRef({animationFrame:0,width:null}),M=t.useRef(e),T=t.useRef(n),P=t.useRef({getItemKey:null,itemKeyRevision:null,lookup:null}),[N,O]=t.useState(!1),[D,j]=t.useState(0),[L,G]=t.useState(0),B="display"===c,F=parseFontSize(s);M.current=e,T.current=n;const W=C??e;P.current.getItemKey===n&&P.current.itemKeyRevision===W||(P.current={getItemKey:n,itemKeyRevision:W,lookup:e=>T.current(M.current[e],e)});const V=P.current.lookup,K=t.useCallback(()=>w.current,[]),U=useVirtualizer({count:e.length,initialRect:{height:400,width:0},getScrollElement:K,estimateSize:I,getItemKey:V,overscan:a,shouldAdjustScrollPositionOnItemSizeChange:B?void 0:denyScrollPositionAdjustment}),H=U.getTotalSize(),Y=U.getVirtualItems(),Z=Y[0]??null,Q=Y.at(-1)??null,X=Z?Math.max(0,Z.start):0,q=Q?Math.max(0,H-getVirtualItemEnd(Q)):0,J=h&&0===Y.length&&e.length>0,$=joinClassNames("nexgui4-transcript-spacer",!J&&(B?"nexgui4-transcript-spacer--display":"nexgui4-transcript-spacer--panel")),_=J?void 0:B?0===Y.length?{height:`${H}px`}:{paddingBottom:`${q}px`,paddingTop:`${X}px`}:{height:`${H}px`},ee=null==s?void 0:"number"==typeof s?`${s}px`:s,te=joinClassNames("nexgui4-transcript-scroll-viewport",B?"nexgui4-transcript-scroll-viewport--display":"nexgui4-transcript-scroll-viewport--panel"),ge={fontFamily:i,fontSize:ee},re={right:`${Un+D}px`},ne=t.useCallback(e=>{const t=getVerticalScrollbarGutterWidth(e);j(e=>e===t?e:t)},[]),Ae=t.useCallback(()=>{const e=w.current;e&&(e.scrollTop=e.scrollHeight)},[]);t.useImperativeHandle(S,()=>({scrollToBottom:Ae,scrollToIndex:(e,t)=>U.scrollToIndex(e,t)}),[U,Ae]),t.useLayoutEffect(()=>{if(!B)return void(E.current=null);const t=w.current;if(!t)return;const g={itemCount:e.length,scrollHeight:t.scrollHeight,totalSize:H},n=E.current;null!=n&&n.itemCount===g.itemCount&&n.scrollHeight===g.scrollHeight&&n.totalSize===g.totalSize&&isPinnedToDisplayTail(t)||(t.scrollTop=t.scrollHeight,E.current=g)},[o,L,B,e.length,H]),t.useLayoutEffect(()=>{B||N||0===e.length||U.scrollToIndex(e.length-1,{align:"end"})},[B,N,e.length,U]),t.useLayoutEffect(()=>{const e=U.measure,t=window.ResizeObserver,g=R.current;if(!B)return g.width=null,void(g.animationFrame&&(window.cancelAnimationFrame(g.animationFrame),g.animationFrame=0));const n=w.current;if(!n||"function"!=typeof e||"function"!=typeof t)return;g.width=getElementWidth(n);const scheduleMeasure=t=>{g.width!==t&&(g.width=t,g.animationFrame&&window.cancelAnimationFrame(g.animationFrame),g.animationFrame=window.requestAnimationFrame(()=>{g.animationFrame=0,e(),G(e=>e+1)}))},C=new t(e=>{scheduleMeasure(getElementWidth(n,e[0]))});return C.observe(n),()=>{C.disconnect(),g.animationFrame&&(window.cancelAnimationFrame(g.animationFrame),g.animationFrame=0)}},[B,U]),t.useLayoutEffect(()=>{if(B)return void j(0);const e=w.current;if(!e)return;ne(e);const t=window.ResizeObserver;if("function"!=typeof t)return;const g=new t(()=>{ne(e)});return g.observe(e),()=>{g.disconnect()}},[B,ne]),t.useLayoutEffect(()=>{B||ne(w.current)},[B,e.length,H,ne]),t.useEffect(()=>{0===e.length&&O(!1)},[e.length]),t.useEffect(()=>{d(N)},[N,d]);const Ce=t.useCallback(e=>{if(B)return;ne(e.currentTarget);const t=!isNearBottom(e.currentTarget);O(e=>e===t?e:t)},[B,ne]);t.useEffect(()=>{const e=w.current;if(!e)return;const handleWheel=e=>{!B||e.deltaY>=0||(e.preventDefault(),u())};return e.addEventListener("wheel",handleWheel,{passive:!1}),()=>e.removeEventListener("wheel",handleWheel)},[B,u]);const oe=t.useCallback(e=>{if(!(e.target instanceof Element))return;const t=e.target.closest("a");if(!t||!e.currentTarget.contains(t))return;if(t.classList.contains("url_link"))return;const g=t.getAttribute("rel");g&&(e.preventDefault(),y(g))},[y]);return React.createElement(En,{component:"section",sx:{border:l?1:0,borderColor:"divider",borderRadius:l?1:0,display:"flex",flex:1,flexDirection:"column",minHeight:0,position:"relative"}},b&&N?React.createElement(En,{component:"div","data-testid":"scroll-lock-badge",role:"status",style:re,sx:{backgroundColor:"background.paper",border:1,borderColor:"divider",borderRadius:1,boxShadow:1,color:"text.secondary",fontSize:"0.75rem",px:1,py:.5,position:"absolute",top:8,zIndex:2}},"Scroll lock"):null,React.createElement(En,{className:te,component:"div",onClick:oe,"data-testid":x,onScroll:Ce,ref:w,style:ge,sx:v},React.createElement("div",{className:$,"data-testid":"virtual-scroll-spacer",style:_},J?e.map((e,t)=>React.createElement("div",{className:"nexgui4-transcript-row","data-index":t,key:n(e,t)},g(e,{fontSize:F,index:t,isActiveMatch:t===p}))):Y.map(t=>{const n=e[t.index];return null==n?null:React.createElement("div",{className:joinClassNames("nexgui4-transcript-row",B?"nexgui4-transcript-row--display":"nexgui4-transcript-row--panel"),"data-index":t.index,key:t.key,ref:U.measureElement,style:B?void 0:{transform:`translateY(${t.start}px)`}},g(n,{fontSize:F,index:t.index,isActiveMatch:t.index===p}))})),m))};TranscriptViewportComponent.displayName="TranscriptViewport",TranscriptViewportComponent.propTypes={activeMatchIndex:Fg.number,border:Fg.bool,displayPinKey:Fg.oneOfType([Fg.number,Fg.string]),estimateSize:Fg.func,fallbackToAllItems:Fg.bool,fontFamily:Fg.string,fontSize:Fg.oneOfType([Fg.number,Fg.string]),footer:Fg.node,getItemKey:Fg.func,itemKeyVersion:Fg.oneOfType([Fg.number,Fg.string]),items:Fg.array.isRequired,mode:Fg.oneOf(["panel","display"]),onRequestHistory:Fg.func,onSendCommand:Fg.func,onScrollLockChange:Fg.func,overscan:Fg.number,renderItem:Fg.func.isRequired,showScrollLockBadge:Fg.bool,viewportSx:Fg.oneOfType([Fg.array,Fg.func,Fg.object]),viewportTestId:Fg.string};const Hn=t.forwardRef(TranscriptViewportComponent);Hn.displayName="TranscriptViewport",Hn.propTypes=TranscriptViewportComponent.propTypes;const padTwo=e=>String(e).padStart(2,"0"),padThree=e=>String(e).padStart(3,"0"),formatNumericTimestamp=(e,t=!0)=>{const g=new Date(e),n=[padTwo(g.getHours()),padTwo(g.getMinutes()),padTwo(g.getSeconds())].join(":");return t?`${n}.${padThree(g.getMilliseconds())}`:n},resolveLabel=(e,t)=>"string"==typeof e&&e.length>0?e:Number.isFinite(e)?formatNumericTimestamp(e,t):null,resolveDateTime=e=>Number.isFinite(e)?new Date(e).toISOString():void 0,TimestampComponent=({timestamp:e,fontFamily:t=se,fontSize:g,highlight:n=!1,className:C="ng-timestamp timestamp mono no_out",includeMilliseconds:o=!0})=>{const I=resolveLabel(e,o);return null===I?null:React.createElement("time",{className:C,dateTime:resolveDateTime(e),style:n?{backgroundColor:"yellow",fontFamily:t,fontSize:g}:{fontFamily:t,fontSize:g}},I)};TimestampComponent.displayName="Timestamp",TimestampComponent.propTypes={className:Fg.string,fontFamily:Fg.string,fontSize:Fg.oneOfType([Fg.number,Fg.string]),highlight:Fg.bool,includeMilliseconds:Fg.bool,timestamp:Fg.oneOfType([Fg.number,Fg.string]).isRequired};const Yn=t.memo(TimestampComponent);Yn.displayName="Timestamp",Yn.propTypes=TimestampComponent.propTypes;const Zn=Fg.shape({content:Fg.node,id:Fg.oneOfType([Fg.number,Fg.string]),isHtml:Fg.bool,timestamp:Fg.number}),renderContent=(e,g)=>null==e||!1===e?null:t.isValidElement(e)?e:g?React.createElement(zn,{component:"span",sx:{color:"text.primary",display:"inline",lineHeight:1.5},variant:"body2",dangerouslySetInnerHTML:{__html:e}}):React.createElement(zn,{component:"span",sx:{color:"text.primary",display:"inline",lineHeight:1.5},variant:"body2"},e),FeedEntryComponent=({entry:e,fontSize:t})=>React.createElement(En,{className:"feed-entry","data-feed-entry-id":e.id??void 0,sx:{alignItems:"flex-start",columnGap:1,display:"flex",minWidth:0,py:.5,width:"100%"}},Number.isFinite(e.timestamp)?React.createElement(Yn,{timestamp:e.timestamp,fontSize:t,includeMilliseconds:!1}):null,React.createElement(En,{className:"feed-entry__content",sx:{flex:1,minWidth:0,overflowWrap:"anywhere"}},renderContent(e.content,e.isHtml)));FeedEntryComponent.displayName="FeedEntry",FeedEntryComponent.propTypes={entry:Zn.isRequired,fontSize:Fg.oneOfType([Fg.number,Fg.string])};const Qn=t.memo(FeedEntryComponent);Qn.displayName="FeedEntry",Qn.propTypes=FeedEntryComponent.propTypes;const getFlipTransform$9=e=>{switch(e){case 1:return"scaleX(-1) scaleY(-1)";case 2:return"scaleY(-1)";case 3:return"scaleX(-1)";default:return"none"}},PanelBackgroundComponent=({backgroundClassName:e,children:g=null,component:n="div",contentClassName:C,contentSx:o,sx:I,...a})=>{const i=useTheme$1(),[s]=t.useState(()=>Math.floor(4*Math.random())),l=i?.nexGui?.backgroundImage??"",c=i?.nexGui?.backgroundOpacity??.5,u=i?.nexGui?.backgroundFilter??"none";return React.createElement(En,{component:n,sx:[{display:"flex",flex:1,height:"100%",minHeight:0,minWidth:0,overflow:"hidden",position:"relative",width:"100%"},I],...a},l?React.createElement(En,{"aria-hidden":"true",className:e,sx:{backgroundImage:`url(${l})`,backgroundPosition:"center",backgroundSize:"cover",filter:u,inset:0,opacity:c,position:"absolute",transform:getFlipTransform$9(s),zIndex:0}}):null,React.createElement(En,{className:C,sx:[{display:"flex",flex:1,minHeight:0,minWidth:0,position:"relative",zIndex:1},o]},g))};PanelBackgroundComponent.displayName="PanelBackground",PanelBackgroundComponent.propTypes={backgroundClassName:Fg.string,children:Fg.node,component:Fg.elementType,contentClassName:Fg.string,contentSx:Fg.oneOfType([Fg.array,Fg.func,Fg.object]),sx:Fg.oneOfType([Fg.array,Fg.func,Fg.object])};const Xn=t.memo(PanelBackgroundComponent);Xn.displayName="PanelBackground",Xn.propTypes=PanelBackgroundComponent.propTypes;const noopSubscribe$1=()=>()=>{},getModelVersion$1=e=>"function"==typeof e?.getVersion?e.getVersion():0,selectEntries=e=>e.entries,colorEntry=(e,t)=>{if("string"!=typeof e?.content||0===e.content.length||"function"!=typeof t)return e;const{content:g,isHtml:n}=t(e.content);return g!==e.content||n?{...e,content:g,isHtml:n}:e},useFeed=()=>{const{stores:e,playerDirectory:g,playerRelationships:n,formatInlineNames:C}=useNexGui(),o=e.feed(selectEntries),I=t.useMemo(()=>({subscribe:e=>{const t=g?.subscribePlayerDirectory?.(e)??noopSubscribe$1(),C=n?.subscribePlayerRelationships?.(e)??noopSubscribe$1();return()=>{t?.(),C?.()}},getSnapshot:()=>`${getModelVersion$1(g)}:${getModelVersion$1(n)}`}),[g,n]),a=t.useSyncExternalStore(I.subscribe,I.getSnapshot,I.getSnapshot),i=t.useRef(null);return null===i.current&&(i.current=new WeakMap),{entries:t.useMemo(()=>{const e=i.current;return o.map(t=>{if(null===t||"object"!=typeof t)return t;const g=e.get(t);if(g&&g.version===a)return g.value;const n=colorEntry(t,C);return g&&g.value.content===n.content&&g.value.isHtml===n.isHtml?(e.set(t,{version:a,value:g.value}),g.value):(e.set(t,{version:a,value:n}),n)})},[o,a,C])}},GameFeedInner=()=>{const e=useTheme$1(),{entries:g}=useFeed(),n=g.at(-1)?.id??g.length,C=t.useCallback((e,{fontSize:t}={})=>React.createElement(Qn,{entry:e,fontSize:t}),[]);return 0===g.length?React.createElement(Xn,{backgroundClassName:"game-feed__background",className:"game-feed game-feed--empty",contentClassName:"game-feed__content",contentSx:{alignItems:"center",color:"text.secondary",justifyContent:"center",p:2}},React.createElement(zn,{variant:"body2"},"No feed entries")):React.createElement(Xn,{backgroundClassName:"game-feed__background",className:"game-feed",contentClassName:"game-feed__content",contentSx:{minHeight:0}},React.createElement(Hn,{itemKeyVersion:n,items:g,fontFamily:e.typography.fontFamily,fontSize:e.typography.fontSize,renderItem:C,showScrollLockBadge:!1,viewportSx:{p:1}}))};GameFeedInner.displayName="GameFeedInner";const GameFeed=()=>React.createElement(Ln,{panelName:"GameFeed"},React.createElement(GameFeedInner,null));GameFeed.displayName="GameFeed";const noop$4=()=>{},qn="nexgui4-structured-stream-panel__timestamp ng-timestamp timestamp mono no_out",Jn=Fg.shape({hasMXP:Fg.bool.isRequired,html:Fg.string.isRequired,id:Fg.number.isRequired,timestamp:Fg.oneOfType([Fg.number,Fg.string]).isRequired}),buildLineClassName$1=e=>["nexgui4-structured-stream-panel__line",e.isMonospace?"mono":null].filter(Boolean).join(" "),StructuredStreamRowComponent=({line:e,onSendCommand:t=noop$4})=>{const handleMXP=e=>{if(!(e.target instanceof Element))return;const g=e.target.closest("a");if(!g||!e.currentTarget.contains(g))return;if(g.classList.contains("url_link"))return;const n=g.getAttribute("rel");n&&(e.preventDefault(),t(n))};return React.createElement(En,{component:"div",className:buildLineClassName$1(e),"data-stream-entry-id":e.id,onClick:e.hasMXP?handleMXP:null,sx:{alignItems:"baseline",columnGap:"0.5rem",display:"grid",gridTemplateColumns:"12ch minmax(0, 1fr)",minWidth:0,width:"100%",zIndex:1,"& .nexgui4-structured-stream-panel__payload":{minWidth:0,overflowWrap:"anywhere"},"& .nexgui4-stream-row":{alignItems:"baseline",display:"grid",gridTemplateColumns:"auto minmax(0, 1fr)",columnGap:"0.5rem",width:"100%"},"& .nexgui4-replacement-row":{width:"100%"}}},React.createElement(Yn,{className:qn,fontFamily:"inherit",timestamp:e.timestamp}),React.createElement(En,{component:"span",className:"nexgui4-structured-stream-panel__payload",dangerouslySetInnerHTML:{__html:e.html}}))};StructuredStreamRowComponent.displayName="StructuredStreamRow",StructuredStreamRowComponent.propTypes={line:Jn.isRequired,onSendCommand:Fg.func};const $n=t.memo(StructuredStreamRowComponent);$n.displayName="StructuredStreamRow",$n.propTypes=StructuredStreamRowComponent.propTypes;const StructuredStreamPanelComponent=({items:e,itemKeyVersion:g=null,onSendCommand:n=noop$4})=>{const C=useTheme$1(),o=t.useCallback(e=>React.createElement($n,{line:e,onSendCommand:n}),[n]);return React.createElement(Xn,{backgroundClassName:"nexgui4-structured-stream-panel__background",component:"section",contentClassName:"nexgui4-structured-stream-panel__content",contentSx:{color:"text.primary",fontFamily:"inherit",fontSize:"inherit"},"data-testid":"structured-stream-panel"},React.createElement(Hn,{fontFamily:C.typography.fontFamily,fontSize:C.typography.fontSize,itemKeyVersion:g,items:e,renderItem:o,showScrollLockBadge:!1,viewportSx:{p:"5px"}}))};StructuredStreamPanelComponent.displayName="StructuredStreamPanel",StructuredStreamPanelComponent.propTypes={itemKeyVersion:Fg.oneOfType([Fg.number,Fg.string]),items:Fg.arrayOf(Jn).isRequired,onSendCommand:Fg.func};const _n=t.memo(StructuredStreamPanelComponent);_n.displayName="StructuredStreamPanel",_n.propTypes=StructuredStreamPanelComponent.propTypes;const eA=new WeakMap,assertTranscriptModel=e=>{if(!e||"function"!=typeof e.subscribe||"function"!=typeof e.getSnapshot)throw new Error("useTranscript requires a transcript model with subscribe(listener) and getSnapshot().")},getTranscriptModelBindings=e=>{assertTranscriptModel(e);let t=eA.get(e);if(!t){const subscribe=t=>e.subscribe(t),getSnapshot=()=>e.getSnapshot();t=Object.freeze({subscribe,getSnapshot}),eA.set(e,t)}return t},useTranscript=e=>{const{subscribe:g,getSnapshot:n}=getTranscriptModelBindings(e),C=t.useSyncExternalStore(g,n,n);return{version:C.version,items:C.items,totalLines:C.totalLines}},CombatStreamInner=()=>{const{adapter:e,stores:g}=useNexGui(),{items:n,version:C}=useTranscript(g.combatStream),o=t.useCallback(t=>e.send(t),[e]);return React.createElement(_n,{itemKeyVersion:C,items:n,onSendCommand:o})};CombatStreamInner.displayName="CombatStreamInner";const CombatStream=()=>React.createElement(Ln,{panelName:"Combat Stream"},React.createElement(CombatStreamInner,null));function useForkRef(...e){const t=C.useRef(void 0),g=C.useCallback(t=>{const g=e.map(e=>{if(null==e)return null;if("function"==typeof e){const g=e,n=g(t);return"function"==typeof n?n:()=>{g(null)}}return e.current=t,()=>{e.current=null}});return()=>{g.forEach(e=>e?.())}},e);return C.useMemo(()=>e.every(e=>null==e)?null:e=>{t.current&&(t.current(),t.current=void 0),null!=e&&(t.current=g(e))},e)}function isHostComponent(e){return"string"==typeof e}function appendOwnerState(e,t,g){return void 0===e||isHostComponent(e)?t:{...t,ownerState:{...t.ownerState,...g}}}function extractEventHandlers(e,t=[]){if(void 0===e)return{};const g={};return Object.keys(e).filter(g=>g.match(/^on[A-Z]/)&&"function"==typeof e[g]&&!t.includes(g)).forEach(t=>{g[t]=e[t]}),g}function omitEventHandlers(e){if(void 0===e)return{};const t={};return Object.keys(e).filter(t=>!(t.match(/^on[A-Z]/)&&"function"==typeof e[t])).forEach(g=>{t[g]=e[g]}),t}function mergeSlotProps$1(e){const{getSlotProps:t,additionalProps:g,externalSlotProps:n,externalForwardedProps:C,className:o}=e;if(!t){const e=clsx(g?.className,o,C?.className,n?.className),t={...g?.style,...C?.style,...n?.style},I={...g,...C,...n};return e.length>0&&(I.className=e),Object.keys(t).length>0&&(I.style=t),{props:I,internalRef:void 0}}const I=extractEventHandlers({...C,...n}),a=omitEventHandlers(n),i=omitEventHandlers(C),s=t(I),l=clsx(s?.className,g?.className,o,C?.className,n?.className),c={...s?.style,...g?.style,...C?.style,...n?.style},u={...s,...g,...i,...a};return l.length>0&&(u.className=l),Object.keys(c).length>0&&(u.style=c),{props:u,internalRef:s.ref}}function resolveComponentProps(e,t,g){return"function"==typeof e?e(t,g):e}function useSlotProps(e){const{elementType:t,externalSlotProps:g,ownerState:n,skipResolvingSlotProps:C=!1,...o}=e,I=C?{}:resolveComponentProps(g,n),{props:a,internalRef:i}=mergeSlotProps$1({...o,externalSlotProps:I});return appendOwnerState(t,{...a,ref:useForkRef(i,I?.ref,e.additionalProps?.ref)},n)}function ownerDocument(e){return e&&e.ownerDocument||document}CombatStream.displayName="CombatStream";const tA=C.createContext({});function getListUtilityClass(e){return generateUtilityClass("MuiList",e)}generateUtilityClasses("MuiList",["root","padding","dense","subheader"]);const useUtilityClasses$A=e=>{const{classes:t,disablePadding:g,dense:n,subheader:C}=e;return composeClasses({root:["root",!g&&"padding",n&&"dense",C&&"subheader"]},getListUtilityClass,t)},gA=yn("ul",{name:"MuiList",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:g}=e;return[t.root,!g.disablePadding&&t.padding,g.dense&&t.dense,g.subheader&&t.subheader]}})({listStyle:"none",margin:0,padding:0,position:"relative",variants:[{props:({ownerState:e})=>!e.disablePadding,style:{paddingTop:8,paddingBottom:8}},{props:({ownerState:e})=>e.subheader,style:{paddingTop:0}}]}),rA=C.forwardRef(function(e,t){const g=useDefaultProps({props:e,name:"MuiList"}),{children:n,className:o,component:I="ul",dense:a=!1,disablePadding:i=!1,subheader:s,...l}=g,c=C.useMemo(()=>({dense:a}),[a]),u={...g,component:I,dense:a,disablePadding:i},d=useUtilityClasses$A(u);return Hg.jsx(tA.Provider,{value:c,children:Hg.jsxs(gA,{as:I,className:clsx(d.root,o),ref:t,ownerState:u,...l,children:[s,n]})})});function activeElement(e){let t=e.activeElement;for(;null!=t?.shadowRoot?.activeElement;)t=t.shadowRoot.activeElement;return t}function getScrollbarSize(e=window){const t=e.document.documentElement.clientWidth;return e.innerWidth-t}function createChainedFunction(...e){return e.reduce((e,t)=>null==t?e:function(...g){e.apply(this,g),t.apply(this,g)},()=>{})}function getSvgIconUtilityClass(e){return generateUtilityClass("MuiSvgIcon",e)}generateUtilityClasses("MuiSvgIcon",["root","colorPrimary","colorSecondary","colorAction","colorError","colorDisabled","fontSizeInherit","fontSizeSmall","fontSizeMedium","fontSizeLarge"]);const useUtilityClasses$z=e=>{const{color:t,fontSize:g,classes:n}=e;return composeClasses({root:["root","inherit"!==t&&`color${capitalize(t)}`,`fontSize${capitalize(g)}`]},getSvgIconUtilityClass,n)},nA=yn("svg",{name:"MuiSvgIcon",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:g}=e;return[t.root,"inherit"!==g.color&&t[`color${capitalize(g.color)}`],t[`fontSize${capitalize(g.fontSize)}`]]}})(Rn(({theme:e})=>({userSelect:"none",width:"1em",height:"1em",display:"inline-block",flexShrink:0,transition:e.transitions?.create?.("fill",{duration:(e.vars??e).transitions?.duration?.shorter}),variants:[{props:e=>!e.hasSvgAsChild,style:{fill:"currentColor"}},{props:{fontSize:"inherit"},style:{fontSize:"inherit"}},{props:{fontSize:"small"},style:{fontSize:e.typography?.pxToRem?.(20)||"1.25rem"}},{props:{fontSize:"medium"},style:{fontSize:e.typography?.pxToRem?.(24)||"1.5rem"}},{props:{fontSize:"large"},style:{fontSize:e.typography?.pxToRem?.(35)||"2.1875rem"}},...Object.entries((e.vars??e).palette).filter(([,e])=>e&&e.main).map(([t])=>({props:{color:t},style:{color:(e.vars??e).palette?.[t]?.main}})),{props:{color:"action"},style:{color:(e.vars??e).palette?.action?.active}},{props:{color:"disabled"},style:{color:(e.vars??e).palette?.action?.disabled}},{props:{color:"inherit"},style:{color:void 0}}]}))),AA=C.forwardRef(function(e,t){const g=useDefaultProps({props:e,name:"MuiSvgIcon"}),{children:n,className:o,color:I="inherit",component:a="svg",fontSize:i="medium",htmlColor:s,inheritViewBox:l=!1,titleAccess:c,viewBox:u="0 0 24 24",...d}=g,p=C.isValidElement(n)&&"svg"===n.type,m={...g,color:I,component:a,fontSize:i,instanceFontSize:e.fontSize,inheritViewBox:l,viewBox:u,hasSvgAsChild:p},h={};l||(h.viewBox=u);const y=useUtilityClasses$z(m);return Hg.jsxs(nA,{as:a,className:clsx(y.root,o),focusable:"false",color:s,"aria-hidden":!c||void 0,role:c?"img":void 0,ref:t,...h,...d,...p&&n.props,ownerState:m,children:[p?n.props.children:n,c?Hg.jsx("title",{children:c}):null]})});function createSvgIcon(e,t){function Component(t,g){return Hg.jsx(AA,{"data-testid":void 0,ref:g,...t,children:e})}return Component.muiName=AA.muiName,C.memo(C.forwardRef(Component))}function debounce$1(e,t=166){let g;function debounced(...n){const later=()=>{e.apply(this,n)};clearTimeout(g),g=setTimeout(later,t)}return debounced.clear=()=>{clearTimeout(g)},debounced}function ownerWindow(e){return ownerDocument(e).defaultView||window}function setRef(e,t){"function"==typeof e?e(t):e&&(e.current=t)}function useControlled(e){const{controlled:t,default:g,name:n,state:o="value"}=e,{current:I}=C.useRef(void 0!==t),[a,i]=C.useState(g);return[I?t:a,C.useCallback(e=>{I||i(e)},[])]}function useEventCallback(e){const t=C.useRef(e);return Dr(()=>{t.current=e}),C.useRef((...e)=>(0,t.current)(...e)).current}function isEventHandler(e,t){const g=e.charCodeAt(2);return"o"===e[0]&&"n"===e[1]&&g>=65&&g<=90&&"function"==typeof t}function mergeSlotProps(e,t){if(!e)return t;function extractHandlers(e,t){const g={};return Object.keys(t).forEach(n=>{isEventHandler(n,t[n])&&"function"==typeof e[n]&&(g[n]=(...g)=>{e[n](...g),t[n](...g)})}),g}if("function"==typeof e||"function"==typeof t)return g=>{const n="function"==typeof t?t(g):t,C="function"==typeof e?e({...g,...n}):e,o=clsx(g?.className,n?.className,C?.className),I=extractHandlers(C,n);return{...n,...C,...I,...!!o&&{className:o},...n?.style&&C?.style&&{style:{...n.style,...C.style}},...n?.sx&&C?.sx&&{sx:[...Array.isArray(n.sx)?n.sx:[n.sx],...Array.isArray(C.sx)?C.sx:[C.sx]]}}};const g=t,n=extractHandlers(e,g),C=clsx(g?.className,e?.className);return{...t,...e,...n,...!!C&&{className:C},...g?.style&&e?.style&&{style:{...g.style,...e.style}},...g?.sx&&e?.sx&&{sx:[...Array.isArray(g.sx)?g.sx:[g.sx],...Array.isArray(e.sx)?e.sx:[e.sx]]}}}function nextItem$1(e,t,g){return e===t?e.firstChild:t&&t.nextElementSibling?t.nextElementSibling:g?null:e.firstChild}function previousItem$1(e,t,g){return e===t?g?e.firstChild:e.lastChild:t&&t.previousElementSibling?t.previousElementSibling:g?null:e.lastChild}function textCriteriaMatches(e,t){if(void 0===t)return!0;let g=e.innerText;return void 0===g&&(g=e.textContent),g=g.trim().toLowerCase(),0!==g.length&&(t.repeating?g[0]===t.keys[0]:g.startsWith(t.keys.join("")))}function moveFocus$1(e,t,g,n,C,o){let I=!1,a=C(e,t,!!t&&g);for(;a;){if(a===e.firstChild){if(I)return!1;I=!0}const t=!n&&(a.disabled||"true"===a.getAttribute("aria-disabled"));if(a.hasAttribute("tabindex")&&textCriteriaMatches(a,o)&&!t)return a.focus(),!0;a=C(e,a,g)}return!1}AA.muiName="SvgIcon";const CA=C.forwardRef(function(e,t){const{actions:g,autoFocus:n=!1,autoFocusItem:o=!1,children:I,className:a,disabledItemsFocusable:i=!1,disableListWrap:s=!1,onKeyDown:l,variant:c="selectedMenu",...u}=e,d=C.useRef(null),p=C.useRef({keys:[],repeating:!0,previousKeyMatched:!0,lastTime:null});Dr(()=>{n&&d.current.focus()},[n]),C.useImperativeHandle(g,()=>({adjustStyleForScrollbar:(e,{direction:t})=>{const g=!d.current.style.width;if(e.clientHeight<d.current.clientHeight&&g){const g=`${getScrollbarSize(ownerWindow(e))}px`;d.current.style["rtl"===t?"paddingLeft":"paddingRight"]=g,d.current.style.width=`calc(100% + ${g})`}return d.current}}),[]);const handleKeyDown=e=>{const t=d.current,g=e.key;if(e.ctrlKey||e.metaKey||e.altKey)return void(l&&l(e));const n=activeElement(ownerDocument(t));if("ArrowDown"===g)e.preventDefault(),moveFocus$1(t,n,s,i,nextItem$1);else if("ArrowUp"===g)e.preventDefault(),moveFocus$1(t,n,s,i,previousItem$1);else if("Home"===g)e.preventDefault(),moveFocus$1(t,null,s,i,nextItem$1);else if("End"===g)e.preventDefault(),moveFocus$1(t,null,s,i,previousItem$1);else if(1===g.length){const C=p.current,o=g.toLowerCase(),I=performance.now();C.keys.length>0&&(I-C.lastTime>500?(C.keys=[],C.repeating=!0,C.previousKeyMatched=!0):C.repeating&&o!==C.keys[0]&&(C.repeating=!1)),C.lastTime=I,C.keys.push(o);const a=n&&!C.repeating&&textCriteriaMatches(n,C);C.previousKeyMatched&&(a||moveFocus$1(t,n,!1,i,nextItem$1,C))?e.preventDefault():C.previousKeyMatched=!1}l&&l(e)},m=useForkRef(d,t);let h=-1;C.Children.forEach(I,(e,t)=>{C.isValidElement(e)?(e.props.disabled||("selectedMenu"===c&&e.props.selected||-1===h)&&(h=t),h===t&&(e.props.disabled||e.props.muiSkipListHighlight||e.type.muiSkipListHighlight)&&(h+=1,h>=I.length&&(h=-1))):h===t&&(h+=1,h>=I.length&&(h=-1))});const y=C.Children.map(I,(e,t)=>{if(t===h){const t={};return o&&(t.autoFocus=!0),void 0===e.props.tabIndex&&"selectedMenu"===c&&(t.tabIndex=0),C.cloneElement(e,t)}return e});return Hg.jsx(rA,{role:"menu",ref:m,className:a,onKeyDown:handleKeyDown,tabIndex:n?0:-1,...u,children:y})}),oA={};function useLazyRef(e,t){const g=C.useRef(oA);return g.current===oA&&(g.current=e(t)),g}const IA=[];function useOnMount(e){C.useEffect(e,IA)}class aA{static create(){return new aA}currentId=null;start(e,t){this.clear(),this.currentId=setTimeout(()=>{this.currentId=null,t()},e)}clear=()=>{null!==this.currentId&&(clearTimeout(this.currentId),this.currentId=null)};disposeEffect=()=>this.clear}function useTimeout(){const e=useLazyRef(aA.create).current;return useOnMount(e.disposeEffect),e}function getReactElementRef(e){return parseInt(C.version,10)>=19?e?.props?.ref||null:e?.ref||null}function _objectWithoutPropertiesLoose(e,t){if(null==e)return{};var g={};for(var n in e)if({}.hasOwnProperty.call(e,n)){if(-1!==t.indexOf(n))continue;g[n]=e[n]}return g}function _setPrototypeOf(e,t){return(_setPrototypeOf=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,t){return e.__proto__=t,e})(e,t)}function _inheritsLoose(e,t){e.prototype=Object.create(t.prototype),e.prototype.constructor=e,_setPrototypeOf(e,t)}const iA={disabled:!1},sA=t.createContext(null);var forceReflow=function(e){return e.scrollTop},lA="unmounted",cA="exited",uA="entering",dA="entered",pA="exiting",mA=function(e){function Transition2(t,g){var n;n=e.call(this,t,g)||this;var C,o=g&&!g.isMounting?t.enter:t.appear;return n.appearStatus=null,t.in?o?(C=cA,n.appearStatus=uA):C=dA:C=t.unmountOnExit||t.mountOnEnter?lA:cA,n.state={status:C},n.nextCallback=null,n}_inheritsLoose(Transition2,e),Transition2.getDerivedStateFromProps=function(e,t){return e.in&&t.status===lA?{status:cA}:null};var g=Transition2.prototype;return g.componentDidMount=function(){this.updateStatus(!0,this.appearStatus)},g.componentDidUpdate=function(e){var t=null;if(e!==this.props){var g=this.state.status;this.props.in?g!==uA&&g!==dA&&(t=uA):g!==uA&&g!==dA||(t=pA)}this.updateStatus(!1,t)},g.componentWillUnmount=function(){this.cancelNextCallback()},g.getTimeouts=function(){var e,t,g,n=this.props.timeout;return e=t=g=n,null!=n&&"number"!=typeof n&&(e=n.exit,t=n.enter,g=void 0!==n.appear?n.appear:t),{exit:e,enter:t,appear:g}},g.updateStatus=function(e,t){if(void 0===e&&(e=!1),null!==t)if(this.cancelNextCallback(),t===uA){if(this.props.unmountOnExit||this.props.mountOnEnter){var g=this.props.nodeRef?this.props.nodeRef.current:n.findDOMNode(this);g&&forceReflow(g)}this.performEnter(e)}else this.performExit();else this.props.unmountOnExit&&this.state.status===cA&&this.setState({status:lA})},g.performEnter=function(e){var t=this,g=this.props.enter,C=this.context?this.context.isMounting:e,o=this.props.nodeRef?[C]:[n.findDOMNode(this),C],I=o[0],a=o[1],i=this.getTimeouts(),s=C?i.appear:i.enter;!e&&!g||iA.disabled?this.safeSetState({status:dA},function(){t.props.onEntered(I)}):(this.props.onEnter(I,a),this.safeSetState({status:uA},function(){t.props.onEntering(I,a),t.onTransitionEnd(s,function(){t.safeSetState({status:dA},function(){t.props.onEntered(I,a)})})}))},g.performExit=function(){var e=this,t=this.props.exit,g=this.getTimeouts(),C=this.props.nodeRef?void 0:n.findDOMNode(this);t&&!iA.disabled?(this.props.onExit(C),this.safeSetState({status:pA},function(){e.props.onExiting(C),e.onTransitionEnd(g.exit,function(){e.safeSetState({status:cA},function(){e.props.onExited(C)})})})):this.safeSetState({status:cA},function(){e.props.onExited(C)})},g.cancelNextCallback=function(){null!==this.nextCallback&&(this.nextCallback.cancel(),this.nextCallback=null)},g.safeSetState=function(e,t){t=this.setNextCallback(t),this.setState(e,t)},g.setNextCallback=function(e){var t=this,g=!0;return this.nextCallback=function(n){g&&(g=!1,t.nextCallback=null,e(n))},this.nextCallback.cancel=function(){g=!1},this.nextCallback},g.onTransitionEnd=function(e,t){this.setNextCallback(t);var g=this.props.nodeRef?this.props.nodeRef.current:n.findDOMNode(this),C=null==e&&!this.props.addEndListener;if(g&&!C){if(this.props.addEndListener){var o=this.props.nodeRef?[this.nextCallback]:[g,this.nextCallback],I=o[0],a=o[1];this.props.addEndListener(I,a)}null!=e&&setTimeout(this.nextCallback,e)}else setTimeout(this.nextCallback,0)},g.render=function(){var e=this.state.status;if(e===lA)return null;var g=this.props,n=g.children;g.in,g.mountOnEnter,g.unmountOnExit,g.appear,g.enter,g.exit,g.timeout,g.addEndListener,g.onEnter,g.onEntering,g.onEntered,g.onExit,g.onExiting,g.onExited,g.nodeRef;var C=_objectWithoutPropertiesLoose(g,["children","in","mountOnEnter","unmountOnExit","appear","enter","exit","timeout","addEndListener","onEnter","onEntering","onEntered","onExit","onExiting","onExited","nodeRef"]);return t.createElement(sA.Provider,{value:null},"function"==typeof n?n(e,C):t.cloneElement(t.Children.only(n),C))},Transition2}(t.Component);function noop$3(){}function _assertThisInitialized(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function getChildMapping(e,g){var mapper=function(e){return g&&t.isValidElement(e)?g(e):e},n=Object.create(null);return e&&t.Children.map(e,function(e){return e}).forEach(function(e){n[e.key]=mapper(e)}),n}function mergeChildMappings(e,t){function getValueForKey(g){return g in t?t[g]:e[g]}e=e||{},t=t||{};var g,n=Object.create(null),C=[];for(var o in e)o in t?C.length&&(n[o]=C,C=[]):C.push(o);var I={};for(var a in t){if(n[a])for(g=0;g<n[a].length;g++){var i=n[a][g];I[n[a][g]]=getValueForKey(i)}I[a]=getValueForKey(a)}for(g=0;g<C.length;g++)I[C[g]]=getValueForKey(C[g]);return I}function getProp(e,t,g){return null!=g[t]?g[t]:e.props[t]}function getInitialChildMapping(e,g){return getChildMapping(e.children,function(n){return t.cloneElement(n,{onExited:g.bind(null,n),in:!0,appear:getProp(n,"appear",e),enter:getProp(n,"enter",e),exit:getProp(n,"exit",e)})})}function getNextChildMapping(e,g,n){var C=getChildMapping(e.children),o=mergeChildMappings(g,C);return Object.keys(o).forEach(function(I){var a=o[I];if(t.isValidElement(a)){var i=I in g,s=I in C,l=g[I],c=t.isValidElement(l)&&!l.props.in;!s||i&&!c?s||!i||c?s&&i&&t.isValidElement(l)&&(o[I]=t.cloneElement(a,{onExited:n.bind(null,a),in:l.props.in,exit:getProp(a,"exit",e),enter:getProp(a,"enter",e)})):o[I]=t.cloneElement(a,{in:!1}):o[I]=t.cloneElement(a,{onExited:n.bind(null,a),in:!0,exit:getProp(a,"exit",e),enter:getProp(a,"enter",e)})}}),o}mA.contextType=sA,mA.propTypes={},mA.defaultProps={in:!1,mountOnEnter:!1,unmountOnExit:!1,appear:!1,enter:!0,exit:!0,onEnter:noop$3,onEntering:noop$3,onEntered:noop$3,onExit:noop$3,onExiting:noop$3,onExited:noop$3},mA.UNMOUNTED=lA,mA.EXITED=cA,mA.ENTERING=uA,mA.ENTERED=dA,mA.EXITING=pA;var fA=Object.values||function(e){return Object.keys(e).map(function(t){return e[t]})},hA={component:"div",childFactory:function(e){return e}},yA=function(e){function TransitionGroup2(t,g){var n,C=(n=e.call(this,t,g)||this).handleExited.bind(_assertThisInitialized(n));return n.state={contextValue:{isMounting:!0},handleExited:C,firstRender:!0},n}_inheritsLoose(TransitionGroup2,e);var g=TransitionGroup2.prototype;return g.componentDidMount=function(){this.mounted=!0,this.setState({contextValue:{isMounting:!1}})},g.componentWillUnmount=function(){this.mounted=!1},TransitionGroup2.getDerivedStateFromProps=function(e,t){var g=t.children,n=t.handleExited;return{children:t.firstRender?getInitialChildMapping(e,n):getNextChildMapping(e,g,n),firstRender:!1}},g.handleExited=function(e,t){var g=getChildMapping(this.props.children);e.key in g||(e.props.onExited&&e.props.onExited(t),this.mounted&&this.setState(function(t){var g=_extends({},t.children);return delete g[e.key],{children:g}}))},g.render=function(){var e=this.props,g=e.component,n=e.childFactory,C=_objectWithoutPropertiesLoose(e,["component","childFactory"]),o=this.state.contextValue,I=fA(this.state.children).map(n);return delete C.appear,delete C.enter,delete C.exit,null===g?t.createElement(sA.Provider,{value:o},I):t.createElement(sA.Provider,{value:o},t.createElement(g,C,I))},TransitionGroup2}(t.Component);yA.propTypes={},yA.defaultProps=hA;const reflow=e=>e.scrollTop;function normalizedTransitionCallback(e,t){return g=>{if(t){const n=e.current;void 0===g?t(n):t(n,g)}}}function getTransitionChildStyle(e,t,g,n,C,o){const I="exited"!==e||t?g[e]||g.exited:n;return C||o?{...I,...C,...o}:I}function getTransitionProps(e,t){const{timeout:g,easing:n,style:C={}}=e;return{duration:C.transitionDuration??("number"==typeof g?g:g[t.mode]||0),easing:C.transitionTimingFunction??("object"==typeof n?n[t.mode]:n),delay:C.transitionDelay}}function getScale(e){return`scale(${e}, ${e**2})`}const bA={entering:{opacity:1,transform:getScale(1)},entered:{opacity:1,transform:"none"},exiting:{opacity:0,transform:getScale(.75)},exited:{opacity:0,transform:getScale(.75)}},vA={opacity:0,transform:getScale(.75),visibility:"hidden"},xA=C.forwardRef(function(e,t){const{addEndListener:g,appear:n=!0,children:o,easing:I,in:a,onEnter:i,onEntered:s,onEntering:l,onExit:c,onExited:u,onExiting:d,style:p,timeout:m="auto",...h}=e,y=useTimeout(),b=C.useRef(),v=useTheme$1(),x=C.useRef(null),S=useForkRef(x,getReactElementRef(o),t),w=normalizedTransitionCallback(x,l),E=normalizedTransitionCallback(x,(e,t)=>{reflow(e);const{duration:g,delay:n,easing:C}=getTransitionProps({style:p,timeout:m,easing:I},{mode:"enter"});let o;"auto"===m?(o=v.transitions.getAutoHeightDuration(e.clientHeight),b.current=o):o=g,e.style.transition=[v.transitions.create("opacity",{duration:o,delay:n}),v.transitions.create("transform",{duration:.666*o,delay:n,easing:C})].join(","),i&&i(e,t)}),R=normalizedTransitionCallback(x,s),M=normalizedTransitionCallback(x,d),T=normalizedTransitionCallback(x,e=>{const{duration:t,delay:g,easing:n}=getTransitionProps({style:p,timeout:m,easing:I},{mode:"exit"});let C;"auto"===m?(C=v.transitions.getAutoHeightDuration(e.clientHeight),b.current=C):C=t,e.style.transition=[v.transitions.create("opacity",{duration:C,delay:g}),v.transitions.create("transform",{duration:.666*C,delay:g||.333*C,easing:n})].join(","),e.style.opacity=0,e.style.transform=getScale(.75),c&&c(e)}),P=normalizedTransitionCallback(x,e=>{e.style.transition="",u&&u(e)}),handleAddEndListener=e=>{"auto"===m&&y.start(b.current||0,e),g&&g(x.current,e)};return Hg.jsx(mA,{appear:n,in:a,nodeRef:x,onEnter:E,onEntered:R,onEntering:w,onExit:T,onExited:P,onExiting:M,addEndListener:handleAddEndListener,timeout:"auto"===m?null:m,...h,children:(e,{ownerState:t,...g})=>{const n=getTransitionChildStyle(e,a,bA,vA,p,o.props.style);return C.cloneElement(o,{style:n,ref:S,...g})}})});function isOverflowing(e){const t=ownerDocument(e);return t.body===e?ownerWindow(e).innerWidth>t.documentElement.clientWidth:e.scrollHeight>e.clientHeight}function ariaHidden(e,t){t?e.setAttribute("aria-hidden","true"):e.removeAttribute("aria-hidden")}function getPaddingRight(e){return parseFloat(ownerWindow(e).getComputedStyle(e).paddingRight)||0}function isAriaHiddenForbiddenOnElement(e){const t=["TEMPLATE","SCRIPT","STYLE","LINK","MAP","META","NOSCRIPT","PICTURE","COL","COLGROUP","PARAM","SLOT","SOURCE","TRACK"].includes(e.tagName),g="INPUT"===e.tagName&&"hidden"===e.getAttribute("type");return t||g}function ariaHiddenSiblings(e,t,g,n,C){const o=[t,g,...n];[].forEach.call(e.children,e=>{const t=!o.includes(e),g=!isAriaHiddenForbiddenOnElement(e);t&&g&&ariaHidden(e,C)})}function findIndexOf(e,t){let g=-1;return e.some((e,n)=>!!t(e)&&(g=n,!0)),g}function handleContainer(e,t){const g=[],n=e.container;if(!t.disableScrollLock){if(isOverflowing(n)){const e=getScrollbarSize(ownerWindow(n));g.push({value:n.style.paddingRight,property:"padding-right",el:n}),n.style.paddingRight=`${getPaddingRight(n)+e}px`;const t=ownerDocument(n).querySelectorAll(".mui-fixed");[].forEach.call(t,t=>{g.push({value:t.style.paddingRight,property:"padding-right",el:t}),t.style.paddingRight=`${getPaddingRight(t)+e}px`})}let e;if(n.parentNode instanceof DocumentFragment)e=ownerDocument(n).body;else{const t=n.parentElement,g=ownerWindow(n);e="HTML"===t?.nodeName&&"scroll"===g.getComputedStyle(t).overflowY?t:n}g.push({value:e.style.overflow,property:"overflow",el:e},{value:e.style.overflowX,property:"overflow-x",el:e},{value:e.style.overflowY,property:"overflow-y",el:e}),e.style.overflow="hidden"}return()=>{g.forEach(({value:e,el:t,property:g})=>{e?t.style.setProperty(g,e):t.style.removeProperty(g)})}}function getHiddenSiblings(e){const t=[];return[].forEach.call(e.children,e=>{"true"===e.getAttribute("aria-hidden")&&t.push(e)}),t}xA&&(xA.muiSupportAuto=!0);class SA{constructor(){this.modals=[],this.containers=[]}add(e,t){let g=this.modals.indexOf(e);if(-1!==g)return g;g=this.modals.length,this.modals.push(e),e.modalRef&&ariaHidden(e.modalRef,!1);const n=getHiddenSiblings(t);ariaHiddenSiblings(t,e.mount,e.modalRef,n,!0);const C=findIndexOf(this.containers,e=>e.container===t);return-1!==C?(this.containers[C].modals.push(e),g):(this.containers.push({modals:[e],container:t,restore:null,hiddenSiblings:n}),g)}mount(e,t){const g=findIndexOf(this.containers,t=>t.modals.includes(e)),n=this.containers[g];n.restore||(n.restore=handleContainer(n,t))}remove(e,t=!0){const g=this.modals.indexOf(e);if(-1===g)return g;const n=findIndexOf(this.containers,t=>t.modals.includes(e)),C=this.containers[n];if(C.modals.splice(C.modals.indexOf(e),1),this.modals.splice(g,1),0===C.modals.length)C.restore&&C.restore(),e.modalRef&&ariaHidden(e.modalRef,t),ariaHiddenSiblings(C.container,e.mount,e.modalRef,C.hiddenSiblings,!1),this.containers.splice(n,1);else{const e=C.modals[C.modals.length-1];e.modalRef&&ariaHidden(e.modalRef,!1)}return g}isTopModal(e){return this.modals.length>0&&this.modals[this.modals.length-1]===e}}const wA=["input","select","textarea","a[href]","button","[tabindex]","audio[controls]","video[controls]",'[contenteditable]:not([contenteditable="false"])'].join(",");function getTabIndex(e){const t=parseInt(e.getAttribute("tabindex")||"",10);return Number.isNaN(t)?"true"===e.contentEditable||("AUDIO"===e.nodeName||"VIDEO"===e.nodeName||"DETAILS"===e.nodeName)&&null===e.getAttribute("tabindex")?0:e.tabIndex:t}function isNonTabbableRadio(e){if("INPUT"!==e.tagName||"radio"!==e.type)return!1;if(!e.name)return!1;const getRadio=t=>e.ownerDocument.querySelector(`input[type="radio"]${t}`);let t=getRadio(`[name="${e.name}"]:checked`);return t||(t=getRadio(`[name="${e.name}"]`)),t!==e}function isNodeMatchingSelectorFocusable(e){return!(e.disabled||"INPUT"===e.tagName&&"hidden"===e.type||isNonTabbableRadio(e))}function defaultGetTabbable(e){const t=[],g=[];return Array.from(e.querySelectorAll(wA)).forEach((e,n)=>{const C=getTabIndex(e);-1!==C&&isNodeMatchingSelectorFocusable(e)&&(0===C?t.push(e):g.push({documentOrder:n,tabIndex:C,node:e}))}),g.sort((e,t)=>e.tabIndex===t.tabIndex?e.documentOrder-t.documentOrder:e.tabIndex-t.tabIndex).map(e=>e.node).concat(t)}function defaultIsEnabled(){return!0}function FocusTrap(e){const{children:t,disableAutoFocus:g=!1,disableEnforceFocus:n=!1,disableRestoreFocus:o=!1,getTabbable:I=defaultGetTabbable,isEnabled:a=defaultIsEnabled,open:i}=e,s=C.useRef(!1),l=C.useRef(null),c=C.useRef(null),u=C.useRef(null),d=C.useRef(null),p=C.useRef(!1),m=C.useRef(null),h=useForkRef(getReactElementRef(t),m),y=C.useRef(null);C.useEffect(()=>{i&&m.current&&(p.current=!g)},[g,i]),C.useEffect(()=>{if(!i||!m.current)return;const e=activeElement(ownerDocument(m.current));return m.current.contains(e)||(m.current.hasAttribute("tabIndex")||m.current.setAttribute("tabIndex","-1"),p.current&&m.current.focus()),()=>{o||(u.current&&u.current.focus&&(s.current=!0,u.current.focus()),u.current=null)}},[i]),C.useEffect(()=>{if(!i||!m.current)return;const e=ownerDocument(m.current),loopFocus=t=>{y.current=t,!n&&a()&&"Tab"===t.key&&activeElement(e)===m.current&&t.shiftKey&&(s.current=!0,c.current&&c.current.focus())},contain=()=>{const t=m.current;if(null===t)return;const g=activeElement(e);if(!e.hasFocus()||!a()||s.current)return void(s.current=!1);if(t.contains(g))return;if(n&&g!==l.current&&g!==c.current)return;if(g!==d.current)d.current=null;else if(null!==d.current)return;if(!p.current)return;let C=[];if(g!==l.current&&g!==c.current||(C=I(m.current)),C.length>0){const e=Boolean(y.current?.shiftKey&&"Tab"===y.current?.key),t=C[0],g=C[C.length-1];"string"!=typeof t&&"string"!=typeof g&&(e?g.focus():t.focus())}else t.focus()};e.addEventListener("focusin",contain),e.addEventListener("keydown",loopFocus,!0);const t=setInterval(()=>{const t=activeElement(e);t&&"BODY"===t.tagName&&contain()},50);return()=>{clearInterval(t),e.removeEventListener("focusin",contain),e.removeEventListener("keydown",loopFocus,!0)}},[g,n,o,a,i,I]);const onFocus=e=>{null===u.current&&(u.current=e.relatedTarget),p.current=!0,d.current=e.target;const g=t.props.onFocus;g&&g(e)},handleFocusSentinel=e=>{null===u.current&&(u.current=e.relatedTarget),p.current=!0};return Hg.jsxs(C.Fragment,{children:[Hg.jsx("div",{tabIndex:i?0:-1,onFocus:handleFocusSentinel,ref:l,"data-testid":"sentinelStart"}),C.cloneElement(t,{ref:h,onFocus}),Hg.jsx("div",{tabIndex:i?0:-1,onFocus:handleFocusSentinel,ref:c,"data-testid":"sentinelEnd"})]})}function getContainer$1(e){return"function"==typeof e?e():e}const EA=C.forwardRef(function(e,t){const{children:g,container:n,disablePortal:I=!1}=e,[a,i]=C.useState(null),s=useForkRef(C.isValidElement(g)?getReactElementRef(g):null,t);if(Dr(()=>{I||i(getContainer$1(n)||document.body)},[n,I]),Dr(()=>{if(a&&!I)return setRef(t,a),()=>{setRef(t,null)}},[t,a,I]),I){if(C.isValidElement(g)){const e={ref:s};return C.cloneElement(g,e)}return g}return a?o.createPortal(g,a):a});function useSlot(e,t){const{className:g,elementType:n,ownerState:C,externalForwardedProps:o,internalForwardedProps:I,shouldForwardComponentProp:a=!1,...i}=t,{component:s,slots:l={[e]:void 0},slotProps:c={[e]:void 0},...u}=o,d=l[e]||n,p=resolveComponentProps(c[e],C),{props:{component:m,...h},internalRef:y}=mergeSlotProps$1({className:g,...i,externalForwardedProps:"root"===e?u:void 0,externalSlotProps:p}),b=useForkRef(y,p?.ref,t.ref),v="root"===e?m||s:m;return[d,appendOwnerState(d,{..."root"===e&&!s&&!l[e]&&I,..."root"!==e&&!l[e]&&I,...h,...v&&!a&&{as:v},...v&&a&&{component:v},ref:b},C)]}const RA={entering:{opacity:1},entered:{opacity:1},exiting:{opacity:0},exited:{opacity:0}},kA={opacity:0,visibility:"hidden"},MA=C.forwardRef(function(e,t){const g=useTheme$1(),n={enter:g.transitions.duration.enteringScreen,exit:g.transitions.duration.leavingScreen},{addEndListener:o,appear:I=!0,children:a,easing:i,in:s,onEnter:l,onEntered:c,onEntering:u,onExit:d,onExited:p,onExiting:m,style:h,timeout:y=n,...b}=e,v=C.useRef(null),x=useForkRef(v,getReactElementRef(a),t),S=normalizedTransitionCallback(v,u),w=normalizedTransitionCallback(v,(e,t)=>{reflow(e);const n=getTransitionProps({style:h,timeout:y,easing:i},{mode:"enter"});e.style.transition=g.transitions.create("opacity",n),l&&l(e,t)}),E=normalizedTransitionCallback(v,c),R=normalizedTransitionCallback(v,m),M=normalizedTransitionCallback(v,e=>{const t=getTransitionProps({style:h,timeout:y,easing:i},{mode:"exit"});e.style.transition=g.transitions.create("opacity",t),d&&d(e)}),T=normalizedTransitionCallback(v,e=>{e.style.transition="",p&&p(e)}),handleAddEndListener=e=>{o&&o(v.current,e)};return Hg.jsx(mA,{appear:I,in:s,nodeRef:v,onEnter:w,onEntered:E,onEntering:S,onExit:M,onExited:T,onExiting:R,addEndListener:handleAddEndListener,timeout:y,...b,children:(e,{ownerState:t,...g})=>{const n=getTransitionChildStyle(e,s,RA,kA,h,a.props.style);return C.cloneElement(a,{style:n,ref:x,...g})}})});function getBackdropUtilityClass(e){return generateUtilityClass("MuiBackdrop",e)}generateUtilityClasses("MuiBackdrop",["root","invisible"]);const useUtilityClasses$y=e=>{const{classes:t,invisible:g}=e;return composeClasses({root:["root",g&&"invisible"]},getBackdropUtilityClass,t)},TA=yn("div",{name:"MuiBackdrop",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:g}=e;return[t.root,g.invisible&&t.invisible]}})({position:"fixed",display:"flex",alignItems:"center",justifyContent:"center",right:0,bottom:0,top:0,left:0,backgroundColor:"rgba(0, 0, 0, 0.5)",WebkitTapHighlightColor:"transparent",variants:[{props:{invisible:!0},style:{backgroundColor:"transparent"}}]}),PA=C.forwardRef(function(e,t){const g=useDefaultProps({props:e,name:"MuiBackdrop"}),{children:n,className:C,component:o="div",invisible:I=!1,open:a,components:i={},componentsProps:s={},slotProps:l={},slots:c={},TransitionComponent:u,transitionDuration:d,...p}=g,m={...g,component:o,invisible:I},h=useUtilityClasses$y(m),y={component:o,slots:{transition:u,root:i.Root,...c},slotProps:{...s,...l}},[b,v]=useSlot("root",{elementType:TA,externalForwardedProps:y,className:clsx(h.root,C),ownerState:m}),[x,S]=useSlot("transition",{elementType:MA,externalForwardedProps:y,ownerState:m});return Hg.jsx(x,{in:a,timeout:d,...p,...S,children:Hg.jsx(b,{"aria-hidden":!0,...v,ref:t,children:n})})});function getContainer(e){return"function"==typeof e?e():e}function getHasTransition(e){return!!e&&e.props.hasOwnProperty("in")}const noop$2=()=>{},NA=new SA;function useModal(e){const{container:t,disableEscapeKeyDown:g=!1,disableScrollLock:n=!1,closeAfterTransition:o=!1,onTransitionEnter:I,onTransitionExited:a,children:i,onClose:s,open:l,rootRef:c}=e,u=C.useRef({}),d=C.useRef(null),p=C.useRef(null),m=useForkRef(p,c),[h,y]=C.useState(!l),b=getHasTransition(i);let v=!0;"false"!==e["aria-hidden"]&&!1!==e["aria-hidden"]||(v=!1);const getDoc=()=>ownerDocument(d.current),getModal=()=>(u.current.modalRef=p.current,u.current.mount=d.current,u.current),handleMounted=()=>{NA.mount(getModal(),{disableScrollLock:n}),p.current&&(p.current.scrollTop=0)},x=useEventCallback(()=>{const e=getContainer(t)||getDoc().body;NA.add(getModal(),e),p.current&&handleMounted()}),isTopModal=()=>NA.isTopModal(getModal()),S=useEventCallback(e=>{d.current=e,e&&(l&&isTopModal()?handleMounted():p.current&&ariaHidden(p.current,v))}),w=C.useCallback(()=>{NA.remove(getModal(),v)},[v]);C.useEffect(()=>()=>{w()},[w]),C.useEffect(()=>{l?x():b&&o||w()},[l,w,b,o,x]);const createHandleKeyDown=e=>t=>{e.onKeyDown?.(t),"Escape"===t.key&&229!==t.which&&isTopModal()&&(g||(t.stopPropagation(),s&&s(t,"escapeKeyDown")))},createHandleBackdropClick=e=>t=>{e.onClick?.(t),t.target===t.currentTarget&&s&&s(t,"backdropClick")};return{getRootProps:(t={})=>{const g=extractEventHandlers(e);delete g.onTransitionEnter,delete g.onTransitionExited;const n={...g,...t};return{role:"presentation",...n,onKeyDown:createHandleKeyDown(n),ref:m}},getBackdropProps:(e={})=>{const t=e;return{"aria-hidden":!0,...t,onClick:createHandleBackdropClick(t),open:l}},getTransitionProps:()=>{const handleExited=()=>{y(!0),a&&a(),o&&w()};return{onEnter:createChainedFunction(()=>{y(!1),I&&I()},i?.props.onEnter??noop$2),onExited:createChainedFunction(handleExited,i?.props.onExited??noop$2)}},rootRef:m,portalRef:S,isTopModal,exited:h,hasTransition:b}}function getModalUtilityClass(e){return generateUtilityClass("MuiModal",e)}generateUtilityClasses("MuiModal",["root","hidden","backdrop"]);const useUtilityClasses$x=e=>{const{open:t,exited:g,classes:n}=e;return composeClasses({root:["root",!t&&g&&"hidden"],backdrop:["backdrop"]},getModalUtilityClass,n)},OA=yn("div",{name:"MuiModal",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:g}=e;return[t.root,!g.open&&g.exited&&t.hidden]}})(Rn(({theme:e})=>({position:"fixed",zIndex:(e.vars||e).zIndex.modal,right:0,bottom:0,top:0,left:0,variants:[{props:({ownerState:e})=>!e.open&&e.exited,style:{visibility:"hidden"}}]}))),DA=yn(PA,{name:"MuiModal",slot:"Backdrop"})({zIndex:-1}),jA=C.forwardRef(function(e,t){const g=useDefaultProps({name:"MuiModal",props:e}),{BackdropComponent:n=DA,BackdropProps:o,classes:I,className:a,closeAfterTransition:i=!1,children:s,container:l,component:c,components:u={},componentsProps:d={},disableAutoFocus:p=!1,disableEnforceFocus:m=!1,disableEscapeKeyDown:h=!1,disablePortal:y=!1,disableRestoreFocus:b=!1,disableScrollLock:v=!1,hideBackdrop:x=!1,keepMounted:S=!1,onClose:w,onTransitionEnter:E,onTransitionExited:R,open:M,slotProps:T={},slots:P={},theme:N,...O}=g,D={...g,closeAfterTransition:i,disableAutoFocus:p,disableEnforceFocus:m,disableEscapeKeyDown:h,disablePortal:y,disableRestoreFocus:b,disableScrollLock:v,hideBackdrop:x,keepMounted:S},{getRootProps:j,getBackdropProps:L,getTransitionProps:G,portalRef:B,isTopModal:F,exited:W,hasTransition:V}=useModal({...D,rootRef:t}),K={...D,exited:W},U=useUtilityClasses$x(K),H={};if(void 0===s.props.tabIndex&&(H.tabIndex="-1"),V){const{onEnter:e,onExited:t}=G();H.onEnter=e,H.onExited=t}const Y={slots:{root:u.Root,backdrop:u.Backdrop,...P},slotProps:{...d,...T}},[Z,Q]=useSlot("root",{ref:t,elementType:OA,externalForwardedProps:{...Y,...O,component:c},getSlotProps:j,ownerState:K,className:clsx(a,U?.root,!K.open&&K.exited&&U?.hidden)}),[X,q]=useSlot("backdrop",{ref:o?.ref,elementType:n,externalForwardedProps:Y,shouldForwardComponentProp:!0,additionalProps:o,getSlotProps:e=>L({...e,onClick:t=>{e?.onClick&&e.onClick(t)}}),className:clsx(o?.className,U?.backdrop),ownerState:K});return S||M||V&&!W?Hg.jsx(EA,{ref:B,container:l,disablePortal:y,children:Hg.jsxs(Z,{...Q,children:[!x&&n?Hg.jsx(X,{...q}):null,Hg.jsx(FocusTrap,{disableEnforceFocus:m,disableAutoFocus:p,disableRestoreFocus:b,isEnabled:F,open:M,children:C.cloneElement(s,H)})]})}):null});function getPopoverUtilityClass(e){return generateUtilityClass("MuiPopover",e)}function getOffsetTop(e,t){let g=0;return"number"==typeof t?g=t:"center"===t?g=e.height/2:"bottom"===t&&(g=e.height),g}function getOffsetLeft(e,t){let g=0;return"number"==typeof t?g=t:"center"===t?g=e.width/2:"right"===t&&(g=e.width),g}function getTransformOriginValue(e){return[e.horizontal,e.vertical].map(e=>"number"==typeof e?`${e}px`:e).join(" ")}function resolveAnchorEl$1(e){return"function"==typeof e?e():e}generateUtilityClasses("MuiPopover",["root","paper"]);const useUtilityClasses$w=e=>{const{classes:t}=e;return composeClasses({root:["root"],paper:["paper"]},getPopoverUtilityClass,t)},zA=yn(jA,{name:"MuiPopover",slot:"Root"})({}),LA=yn(Mn,{name:"MuiPopover",slot:"Paper"})({position:"absolute",overflowY:"auto",overflowX:"hidden",minWidth:16,minHeight:16,maxWidth:"calc(100% - 32px)",maxHeight:"calc(100% - 32px)",outline:0}),GA=C.forwardRef(function(e,t){const g=useDefaultProps({props:e,name:"MuiPopover"}),{action:n,anchorEl:o,anchorOrigin:I={vertical:"top",horizontal:"left"},anchorPosition:a,anchorReference:i="anchorEl",children:s,className:l,container:c,elevation:u=8,marginThreshold:d=16,open:p,PaperProps:m={},slots:h={},slotProps:y={},transformOrigin:b={vertical:"top",horizontal:"left"},TransitionComponent:v,transitionDuration:x="auto",TransitionProps:S={},disableScrollLock:w=!1,...E}=g,R=C.useRef(),M={...g,anchorOrigin:I,anchorReference:i,elevation:u,marginThreshold:d,transformOrigin:b,TransitionComponent:v,transitionDuration:x,TransitionProps:S},T=useUtilityClasses$w(M),P=C.useCallback(()=>{if("anchorPosition"===i)return a;const e=resolveAnchorEl$1(o),t=(e&&1===e.nodeType?e:ownerDocument(R.current).body).getBoundingClientRect();return{top:t.top+getOffsetTop(t,I.vertical),left:t.left+getOffsetLeft(t,I.horizontal)}},[o,I.horizontal,I.vertical,a,i]),N=C.useCallback(e=>({vertical:getOffsetTop(e,b.vertical),horizontal:getOffsetLeft(e,b.horizontal)}),[b.horizontal,b.vertical]),O=C.useCallback(e=>{const t={width:e.offsetWidth,height:e.offsetHeight},g=N(t);if("none"===i)return{top:null,left:null,transformOrigin:getTransformOriginValue(g)};const n=P();let C=n.top-g.vertical,I=n.left-g.horizontal;const a=C+t.height,s=I+t.width,l=ownerWindow(resolveAnchorEl$1(o)),c=l.innerHeight-d,u=l.innerWidth-d;if(null!==d&&C<d){const e=C-d;C-=e,g.vertical+=e}else if(null!==d&&a>c){const e=a-c;C-=e,g.vertical+=e}if(null!==d&&I<d){const e=I-d;I-=e,g.horizontal+=e}else if(s>u){const e=s-u;I-=e,g.horizontal+=e}return{top:`${Math.round(C)}px`,left:`${Math.round(I)}px`,transformOrigin:getTransformOriginValue(g)}},[o,i,P,N,d]),[D,j]=C.useState(p),L=C.useCallback(()=>{const e=R.current;if(!e)return;const t=O(e);null!==t.top&&e.style.setProperty("top",t.top),null!==t.left&&(e.style.left=t.left),e.style.transformOrigin=t.transformOrigin,j(!0)},[O]);C.useEffect(()=>(w&&window.addEventListener("scroll",L),()=>window.removeEventListener("scroll",L)),[o,w,L]);const handleEntering=()=>{L()},handleExited=()=>{j(!1)};C.useEffect(()=>{p&&L()}),C.useImperativeHandle(n,()=>p?{updatePosition:()=>{L()}}:null,[p,L]),C.useEffect(()=>{if(!p)return;const e=debounce$1(()=>{L()}),t=ownerWindow(resolveAnchorEl$1(o));return t.addEventListener("resize",e),()=>{e.clear(),t.removeEventListener("resize",e)}},[o,p,L]);let G=x;const B={slots:{transition:v,...h},slotProps:{transition:S,paper:m,...y}},[F,W]=useSlot("transition",{elementType:xA,externalForwardedProps:B,ownerState:M,getSlotProps:e=>({...e,onEntering:(t,g)=>{e.onEntering?.(t,g),handleEntering()},onExited:t=>{e.onExited?.(t),handleExited()}}),additionalProps:{appear:!0,in:p}});"auto"!==x||F.muiSupportAuto||(G=void 0);const V=c||(o?ownerDocument(resolveAnchorEl$1(o)).body:void 0),[K,{slots:U,slotProps:H,...Y}]=useSlot("root",{ref:t,elementType:zA,externalForwardedProps:{...B,...E},shouldForwardComponentProp:!0,additionalProps:{slots:{backdrop:h.backdrop},slotProps:{backdrop:mergeSlotProps("function"==typeof y.backdrop?y.backdrop(M):y.backdrop,{invisible:!0})},container:V,open:p},ownerState:M,className:clsx(T.root,l)}),[Z,Q]=useSlot("paper",{ref:R,className:T.paper,elementType:LA,externalForwardedProps:B,shouldForwardComponentProp:!0,additionalProps:{elevation:u,style:D?void 0:{opacity:0}},ownerState:M});return Hg.jsx(K,{...Y,...!isHostComponent(K)&&{slots:U,slotProps:H,disableScrollLock:w},children:Hg.jsx(F,{...W,timeout:G,children:Hg.jsx(Z,{...Q,children:s})})})});function getMenuUtilityClass(e){return generateUtilityClass("MuiMenu",e)}generateUtilityClasses("MuiMenu",["root","paper","list"]);const BA={vertical:"top",horizontal:"right"},FA={vertical:"top",horizontal:"left"},useUtilityClasses$v=e=>{const{classes:t}=e;return composeClasses({root:["root"],paper:["paper"],list:["list"]},getMenuUtilityClass,t)},WA=yn(GA,{shouldForwardProp:e=>rootShouldForwardProp(e)||"classes"===e,name:"MuiMenu",slot:"Root"})({}),VA=yn(LA,{name:"MuiMenu",slot:"Paper"})({maxHeight:"calc(100% - 96px)",WebkitOverflowScrolling:"touch"}),KA=yn(CA,{name:"MuiMenu",slot:"List"})({outline:0}),UA=C.forwardRef(function(e,t){const g=useDefaultProps({props:e,name:"MuiMenu"}),{autoFocus:n=!0,children:o,className:I,disableAutoFocusItem:a=!1,MenuListProps:i={},onClose:s,open:l,PaperProps:c={},PopoverClasses:u,transitionDuration:d="auto",TransitionProps:{onEntering:p,...m}={},variant:h="selectedMenu",slots:y={},slotProps:b={},...v}=g,x=useRtl(),S={...g,autoFocus:n,disableAutoFocusItem:a,MenuListProps:i,onEntering:p,PaperProps:c,transitionDuration:d,TransitionProps:m,variant:h},w=useUtilityClasses$v(S),E=n&&!a&&l,R=C.useRef(null),handleEntering=(e,t)=>{R.current&&R.current.adjustStyleForScrollbar(e,{direction:x?"rtl":"ltr"}),p&&p(e,t)},handleListKeyDown=e=>{"Tab"===e.key&&(e.preventDefault(),s&&s(e,"tabKeyDown"))};let M=-1;C.Children.map(o,(e,t)=>{C.isValidElement(e)&&(e.props.disabled||("selectedMenu"===h&&e.props.selected||-1===M)&&(M=t))});const T={slots:y,slotProps:{list:i,transition:m,paper:c,...b}},P=useSlotProps({elementType:y.root,externalSlotProps:b.root,ownerState:S,className:[w.root,I]}),[N,O]=useSlot("paper",{className:w.paper,elementType:VA,externalForwardedProps:T,shouldForwardComponentProp:!0,ownerState:S}),[D,j]=useSlot("list",{className:clsx(w.list,i.className),elementType:KA,shouldForwardComponentProp:!0,externalForwardedProps:T,getSlotProps:e=>({...e,onKeyDown:t=>{handleListKeyDown(t),e.onKeyDown?.(t)}}),ownerState:S}),L="function"==typeof T.slotProps.transition?T.slotProps.transition(S):T.slotProps.transition;return Hg.jsx(WA,{onClose:s,anchorOrigin:{vertical:"bottom",horizontal:x?"right":"left"},transformOrigin:x?BA:FA,slots:{root:y.root,paper:N,backdrop:y.backdrop,...y.transition&&{transition:y.transition}},slotProps:{root:P,paper:O,backdrop:"function"==typeof b.backdrop?b.backdrop(S):b.backdrop,transition:{...L,onEntering:(...e)=>{handleEntering(...e),L?.onEntering?.(...e)}}},open:l,ref:t,transitionDuration:d,ownerState:S,...v,classes:u,children:Hg.jsx(D,{actions:R,autoFocus:n&&(-1===M||a),autoFocusItem:E,variant:h,...j,children:o})})});function isFocusVisible(e){try{return e.matches(":focus-visible")}catch(t){}return!1}class HA{static create(){return new HA}static use(){const e=useLazyRef(HA.create).current,[t,g]=C.useState(!1);return e.shouldMount=t,e.setShouldMount=g,C.useEffect(e.mountEffect,[t]),e}constructor(){this.ref={current:null},this.mounted=null,this.didMount=!1,this.shouldMount=!1,this.setShouldMount=null}mount(){return this.mounted||(this.mounted=createControlledPromise(),this.shouldMount=!0,this.setShouldMount(this.shouldMount)),this.mounted}mountEffect=()=>{this.shouldMount&&!this.didMount&&null!==this.ref.current&&(this.didMount=!0,this.mounted.resolve())};start(...e){this.mount().then(()=>this.ref.current?.start(...e))}stop(...e){this.mount().then(()=>this.ref.current?.stop(...e))}pulsate(...e){this.mount().then(()=>this.ref.current?.pulsate(...e))}}function useLazyRipple(){return HA.use()}function createControlledPromise(){let e,t;const g=new Promise((g,n)=>{e=g,t=n});return g.resolve=e,g.reject=t,g}function Ripple(e){const{className:t,classes:g,pulsate:n=!1,rippleX:o,rippleY:I,rippleSize:a,in:i,onExited:s,timeout:l}=e,[c,u]=C.useState(!1),d=clsx(t,g.ripple,g.rippleVisible,n&&g.ripplePulsate),p={width:a,height:a,top:-a/2+I,left:-a/2+o},m=clsx(g.child,c&&g.childLeaving,n&&g.childPulsate);return i||c||u(!0),C.useEffect(()=>{if(!i&&null!=s){const e=setTimeout(s,l);return()=>{clearTimeout(e)}}},[s,i,l]),Hg.jsx("span",{className:d,style:p,children:Hg.jsx("span",{className:m})})}const YA=generateUtilityClasses("MuiTouchRipple",["root","ripple","rippleVisible","ripplePulsate","child","childLeaving","childPulsate"]),ZA=550,QA=80,XA=keyframes`
2
+ 0% {
3
+ transform: scale(0);
4
+ opacity: 0.1;
5
+ }
6
+
7
+ 100% {
8
+ transform: scale(1);
9
+ opacity: 0.3;
10
+ }
11
+ `,qA=keyframes`
12
+ 0% {
13
+ opacity: 1;
14
+ }
15
+
16
+ 100% {
17
+ opacity: 0;
18
+ }
19
+ `,JA=keyframes`
20
+ 0% {
21
+ transform: scale(1);
22
+ }
23
+
24
+ 50% {
25
+ transform: scale(0.92);
26
+ }
27
+
28
+ 100% {
29
+ transform: scale(1);
30
+ }
31
+ `,$A=yn("span",{name:"MuiTouchRipple",slot:"Root"})({overflow:"hidden",pointerEvents:"none",position:"absolute",zIndex:0,top:0,right:0,bottom:0,left:0,borderRadius:"inherit"}),_A=yn(Ripple,{name:"MuiTouchRipple",slot:"Ripple"})`
32
+ opacity: 0;
33
+ position: absolute;
34
+
35
+ &.${YA.rippleVisible} {
36
+ opacity: 0.3;
37
+ transform: scale(1);
38
+ animation-name: ${XA};
39
+ animation-duration: ${ZA}ms;
40
+ animation-timing-function: ${({theme:e})=>e.transitions.easing.easeInOut};
41
+ }
42
+
43
+ &.${YA.ripplePulsate} {
44
+ animation-duration: ${({theme:e})=>e.transitions.duration.shorter}ms;
45
+ }
46
+
47
+ & .${YA.child} {
48
+ opacity: 1;
49
+ display: block;
50
+ width: 100%;
51
+ height: 100%;
52
+ border-radius: 50%;
53
+ background-color: currentColor;
54
+ }
55
+
56
+ & .${YA.childLeaving} {
57
+ opacity: 0;
58
+ animation-name: ${qA};
59
+ animation-duration: ${ZA}ms;
60
+ animation-timing-function: ${({theme:e})=>e.transitions.easing.easeInOut};
61
+ }
62
+
63
+ & .${YA.childPulsate} {
64
+ position: absolute;
65
+ /* @noflip */
66
+ left: 0px;
67
+ top: 0;
68
+ animation-name: ${JA};
69
+ animation-duration: 2500ms;
70
+ animation-timing-function: ${({theme:e})=>e.transitions.easing.easeInOut};
71
+ animation-iteration-count: infinite;
72
+ animation-delay: 200ms;
73
+ }
74
+ `,eC=C.forwardRef(function(e,t){const g=useDefaultProps({props:e,name:"MuiTouchRipple"}),{center:n=!1,classes:o={},className:I,...a}=g,[i,s]=C.useState([]),l=C.useRef(0),c=C.useRef(null);C.useEffect(()=>{c.current&&(c.current(),c.current=null)},[i]);const u=C.useRef(!1),d=useTimeout(),p=C.useRef(null),m=C.useRef(null),h=C.useCallback(e=>{const{pulsate:t,rippleX:g,rippleY:n,rippleSize:C,cb:I}=e;s(e=>[...e,Hg.jsx(_A,{classes:{ripple:clsx(o.ripple,YA.ripple),rippleVisible:clsx(o.rippleVisible,YA.rippleVisible),ripplePulsate:clsx(o.ripplePulsate,YA.ripplePulsate),child:clsx(o.child,YA.child),childLeaving:clsx(o.childLeaving,YA.childLeaving),childPulsate:clsx(o.childPulsate,YA.childPulsate)},timeout:ZA,pulsate:t,rippleX:g,rippleY:n,rippleSize:C},l.current)]),l.current+=1,c.current=I},[o]),y=C.useCallback((e={},t={},g=()=>{})=>{const{pulsate:C=!1,center:o=n||t.pulsate,fakeElement:I=!1}=t;if("mousedown"===e?.type&&u.current)return void(u.current=!1);"touchstart"===e?.type&&(u.current=!0);const a=I?null:m.current,i=a?a.getBoundingClientRect():{width:0,height:0,left:0,top:0};let s,l,c;if(o||void 0===e||0===e.clientX&&0===e.clientY||!e.clientX&&!e.touches)s=Math.round(i.width/2),l=Math.round(i.height/2);else{const{clientX:t,clientY:g}=e.touches&&e.touches.length>0?e.touches[0]:e;s=Math.round(t-i.left),l=Math.round(g-i.top)}if(o)c=Math.sqrt((2*i.width**2+i.height**2)/3),c%2==0&&(c+=1);else{const e=2*Math.max(Math.abs((a?a.clientWidth:0)-s),s)+2,t=2*Math.max(Math.abs((a?a.clientHeight:0)-l),l)+2;c=Math.sqrt(e**2+t**2)}e?.touches?null===p.current&&(p.current=()=>{h({pulsate:C,rippleX:s,rippleY:l,rippleSize:c,cb:g})},d.start(QA,()=>{p.current&&(p.current(),p.current=null)})):h({pulsate:C,rippleX:s,rippleY:l,rippleSize:c,cb:g})},[n,h,d]),b=C.useCallback(()=>{y({},{pulsate:!0})},[y]),v=C.useCallback((e,t)=>{if(d.clear(),"touchend"===e?.type&&p.current)return p.current(),p.current=null,void d.start(0,()=>{v(e,t)});p.current=null,s(e=>e.length>0?e.slice(1):e),c.current=t},[d]);return C.useImperativeHandle(t,()=>({pulsate:b,start:y,stop:v}),[b,y,v]),Hg.jsx($A,{className:clsx(YA.root,o.root,I),ref:m,...a,children:Hg.jsx(yA,{component:null,exit:!0,children:i})})});function getButtonBaseUtilityClass(e){return generateUtilityClass("MuiButtonBase",e)}const tC=generateUtilityClasses("MuiButtonBase",["root","disabled","focusVisible"]),useUtilityClasses$u=e=>{const{disabled:t,focusVisible:g,focusVisibleClassName:n,classes:C}=e,o=composeClasses({root:["root",t&&"disabled",g&&"focusVisible"]},getButtonBaseUtilityClass,C);return g&&n&&(o.root+=` ${n}`),o},gC=yn("button",{name:"MuiButtonBase",slot:"Root"})({display:"inline-flex",alignItems:"center",justifyContent:"center",position:"relative",boxSizing:"border-box",WebkitTapHighlightColor:"transparent",backgroundColor:"transparent",outline:0,border:0,margin:0,borderRadius:0,padding:0,cursor:"pointer",userSelect:"none",verticalAlign:"middle",MozAppearance:"none",WebkitAppearance:"none",textDecoration:"none",color:"inherit","&::-moz-focus-inner":{borderStyle:"none"},[`&.${tC.disabled}`]:{pointerEvents:"none",cursor:"default"},"@media print":{colorAdjust:"exact"}}),rC=C.forwardRef(function(e,t){const g=useDefaultProps({props:e,name:"MuiButtonBase"}),{action:n,centerRipple:o=!1,children:I,className:a,component:i="button",disabled:s=!1,disableRipple:l=!1,disableTouchRipple:c=!1,focusRipple:u=!1,focusVisibleClassName:d,LinkComponent:p="a",onBlur:m,onClick:h,onContextMenu:y,onDragLeave:b,onFocus:v,onFocusVisible:x,onKeyDown:S,onKeyUp:w,onMouseDown:E,onMouseLeave:R,onMouseUp:M,onTouchEnd:T,onTouchMove:P,onTouchStart:N,tabIndex:O=0,TouchRippleProps:D,touchRippleRef:j,type:L,...G}=g,B=C.useRef(null),F=useLazyRipple(),W=useForkRef(F.ref,j),[V,K]=C.useState(!1);s&&V&&K(!1),C.useImperativeHandle(n,()=>({focusVisible:()=>{K(!0),B.current.focus()}}),[]);const U=F.shouldMount&&!l&&!s;C.useEffect(()=>{V&&u&&!l&&F.pulsate()},[l,u,V,F]);const H=useRippleHandler(F,"start",E,c),Y=useRippleHandler(F,"stop",y,c),Z=useRippleHandler(F,"stop",b,c),Q=useRippleHandler(F,"stop",M,c),X=useRippleHandler(F,"stop",e=>{V&&e.preventDefault(),R&&R(e)},c),q=useRippleHandler(F,"start",N,c),J=useRippleHandler(F,"stop",T,c),$=useRippleHandler(F,"stop",P,c),_=useRippleHandler(F,"stop",e=>{isFocusVisible(e.target)||K(!1),m&&m(e)},!1),ee=useEventCallback(e=>{B.current||(B.current=e.currentTarget),isFocusVisible(e.target)&&(K(!0),x&&x(e)),v&&v(e)}),isNonNativeButton=()=>{const e=B.current;return e?"BUTTON"!==e.tagName&&!("A"===e.tagName&&e.href):i&&"button"!==i},te=useEventCallback(e=>{u&&!e.repeat&&V&&" "===e.key&&F.stop(e,()=>{F.start(e)}),e.target===e.currentTarget&&isNonNativeButton()&&" "===e.key&&e.preventDefault(),S&&S(e),e.target===e.currentTarget&&isNonNativeButton()&&"Enter"===e.key&&!s&&(e.preventDefault(),h&&h(e))}),ge=useEventCallback(e=>{u&&" "===e.key&&V&&!e.defaultPrevented&&F.stop(e,()=>{F.pulsate(e)}),w&&w(e),h&&e.target===e.currentTarget&&isNonNativeButton()&&" "===e.key&&!e.defaultPrevented&&!s&&h(e)});let re=i;"button"===re&&(G.href||G.to)&&(re=p);const ne={};if("button"===re){const e=!!G.formAction;ne.type=void 0!==L||e?L:"button",ne.disabled=s}else G.href||G.to||(ne.role="button"),s&&(ne["aria-disabled"]=s);const Ae=useForkRef(t,B),Ce={...g,centerRipple:o,component:i,disabled:s,disableRipple:l,disableTouchRipple:c,focusRipple:u,tabIndex:O,focusVisible:V},oe=useUtilityClasses$u(Ce);return Hg.jsxs(gC,{as:re,className:clsx(oe.root,a),ownerState:Ce,onBlur:_,onClick:h,onContextMenu:Y,onFocus:ee,onKeyDown:te,onKeyUp:ge,onMouseDown:H,onMouseLeave:X,onMouseUp:Q,onDragLeave:Z,onTouchEnd:J,onTouchMove:$,onTouchStart:q,ref:Ae,tabIndex:s?-1:O,type:L,...ne,...G,children:[I,U?Hg.jsx(eC,{ref:W,center:o,...D}):null]})});function useRippleHandler(e,t,g,n=!1){return useEventCallback(C=>(g&&g(C),n||e[t](C),!0))}function getDividerUtilityClass(e){return generateUtilityClass("MuiDivider",e)}const nC=generateUtilityClasses("MuiDivider",["root","absolute","fullWidth","inset","middle","flexItem","light","vertical","withChildren","withChildrenVertical","textAlignRight","textAlignLeft","wrapper","wrapperVertical"]),useUtilityClasses$t=e=>{const{absolute:t,children:g,classes:n,flexItem:C,light:o,orientation:I,textAlign:a,variant:i}=e;return composeClasses({root:["root",t&&"absolute",i,o&&"light","vertical"===I&&"vertical",C&&"flexItem",g&&"withChildren",g&&"vertical"===I&&"withChildrenVertical","right"===a&&"vertical"!==I&&"textAlignRight","left"===a&&"vertical"!==I&&"textAlignLeft"],wrapper:["wrapper","vertical"===I&&"wrapperVertical"]},getDividerUtilityClass,n)},AC=yn("div",{name:"MuiDivider",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:g}=e;return[t.root,g.absolute&&t.absolute,t[g.variant],g.light&&t.light,"vertical"===g.orientation&&t.vertical,g.flexItem&&t.flexItem,g.children&&t.withChildren,g.children&&"vertical"===g.orientation&&t.withChildrenVertical,"right"===g.textAlign&&"vertical"!==g.orientation&&t.textAlignRight,"left"===g.textAlign&&"vertical"!==g.orientation&&t.textAlignLeft]}})(Rn(({theme:e})=>({margin:0,flexShrink:0,borderWidth:0,borderStyle:"solid",borderColor:(e.vars||e).palette.divider,borderBottomWidth:"thin",variants:[{props:{absolute:!0},style:{position:"absolute",bottom:0,left:0,width:"100%"}},{props:{light:!0},style:{borderColor:e.alpha((e.vars||e).palette.divider,.08)}},{props:{variant:"inset"},style:{marginLeft:72}},{props:{variant:"middle",orientation:"horizontal"},style:{marginLeft:e.spacing(2),marginRight:e.spacing(2)}},{props:{variant:"middle",orientation:"vertical"},style:{marginTop:e.spacing(1),marginBottom:e.spacing(1)}},{props:{orientation:"vertical"},style:{height:"100%",borderBottomWidth:0,borderRightWidth:"thin"}},{props:{flexItem:!0},style:{alignSelf:"stretch",height:"auto"}},{props:({ownerState:e})=>!!e.children,style:{display:"flex",textAlign:"center",border:0,borderTopStyle:"solid",borderLeftStyle:"solid","&::before, &::after":{content:'""',alignSelf:"center"}}},{props:({ownerState:e})=>e.children&&"vertical"!==e.orientation,style:{"&::before, &::after":{width:"100%",borderTop:`thin solid ${(e.vars||e).palette.divider}`,borderTopStyle:"inherit"}}},{props:({ownerState:e})=>"vertical"===e.orientation&&e.children,style:{flexDirection:"column","&::before, &::after":{height:"100%",borderLeft:`thin solid ${(e.vars||e).palette.divider}`,borderLeftStyle:"inherit"}}},{props:({ownerState:e})=>"right"===e.textAlign&&"vertical"!==e.orientation,style:{"&::before":{width:"90%"},"&::after":{width:"10%"}}},{props:({ownerState:e})=>"left"===e.textAlign&&"vertical"!==e.orientation,style:{"&::before":{width:"10%"},"&::after":{width:"90%"}}}]}))),CC=yn("span",{name:"MuiDivider",slot:"Wrapper",overridesResolver:(e,t)=>{const{ownerState:g}=e;return[t.wrapper,"vertical"===g.orientation&&t.wrapperVertical]}})(Rn(({theme:e})=>({display:"inline-block",paddingLeft:`calc(${e.spacing(1)} * 1.2)`,paddingRight:`calc(${e.spacing(1)} * 1.2)`,whiteSpace:"nowrap",variants:[{props:{orientation:"vertical"},style:{paddingTop:`calc(${e.spacing(1)} * 1.2)`,paddingBottom:`calc(${e.spacing(1)} * 1.2)`}}]}))),oC=C.forwardRef(function(e,t){const g=useDefaultProps({props:e,name:"MuiDivider"}),{absolute:n=!1,children:C,className:o,orientation:I="horizontal",component:a=(C||"vertical"===I?"div":"hr"),flexItem:i=!1,light:s=!1,role:l=("hr"!==a?"separator":void 0),textAlign:c="center",variant:u="fullWidth",...d}=g,p={...g,absolute:n,component:a,flexItem:i,light:s,orientation:I,role:l,textAlign:c,variant:u},m=useUtilityClasses$t(p);return Hg.jsx(AC,{as:a,className:clsx(m.root,o),role:l,ref:t,ownerState:p,"aria-orientation":"separator"!==l||"hr"===a&&"vertical"!==I?void 0:I,...d,children:C?Hg.jsx(CC,{className:m.wrapper,ownerState:p,children:C}):null})});oC&&(oC.muiSkipListHighlight=!0);const IC=generateUtilityClasses("MuiListItemIcon",["root","alignItemsFlexStart"]),aC=generateUtilityClasses("MuiListItemText",["root","multiline","dense","inset","primary","secondary"]);function getMenuItemUtilityClass(e){return generateUtilityClass("MuiMenuItem",e)}const iC=generateUtilityClasses("MuiMenuItem",["root","focusVisible","dense","disabled","divider","gutters","selected"]);function getNativeSelectUtilityClasses(e){return generateUtilityClass("MuiNativeSelect",e)}const sC=generateUtilityClasses("MuiNativeSelect",["root","select","multiple","filled","outlined","standard","disabled","icon","iconOpen","iconFilled","iconOutlined","iconStandard","nativeInput","error"]),useUtilityClasses$s=e=>{const{classes:t,variant:g,disabled:n,multiple:C,open:o,error:I}=e;return composeClasses({select:["select",g,n&&"disabled",C&&"multiple",I&&"error"],icon:["icon",`icon${capitalize(g)}`,o&&"iconOpen",n&&"disabled"]},getNativeSelectUtilityClasses,t)},lC=yn("select",{name:"MuiNativeSelect"})(({theme:e})=>({MozAppearance:"none",WebkitAppearance:"none",userSelect:"none",borderRadius:0,cursor:"pointer","&:focus":{borderRadius:0},[`&.${sC.disabled}`]:{cursor:"default"},"&[multiple]":{height:"auto"},"&:not([multiple]) option, &:not([multiple]) optgroup":{backgroundColor:(e.vars||e).palette.background.paper},variants:[{props:({ownerState:e})=>"filled"!==e.variant&&"outlined"!==e.variant,style:{"&&&":{paddingRight:24,minWidth:16}}},{props:{variant:"filled"},style:{"&&&":{paddingRight:32}}},{props:{variant:"outlined"},style:{borderRadius:(e.vars||e).shape.borderRadius,"&:focus":{borderRadius:(e.vars||e).shape.borderRadius},"&&&":{paddingRight:32}}}]})),cC=yn(lC,{name:"MuiNativeSelect",slot:"Select",shouldForwardProp:rootShouldForwardProp,overridesResolver:(e,t)=>{const{ownerState:g}=e;return[t.select,t[g.variant],g.error&&t.error,{[`&.${sC.multiple}`]:t.multiple}]}})({}),uC=yn("svg",{name:"MuiNativeSelect"})(({theme:e})=>({position:"absolute",right:0,top:"calc(50% - .5em)",pointerEvents:"none",color:(e.vars||e).palette.action.active,[`&.${sC.disabled}`]:{color:(e.vars||e).palette.action.disabled},variants:[{props:({ownerState:e})=>e.open,style:{transform:"rotate(180deg)"}},{props:{variant:"filled"},style:{right:7}},{props:{variant:"outlined"},style:{right:7}}]})),dC=yn(uC,{name:"MuiNativeSelect",slot:"Icon",overridesResolver:(e,t)=>{const{ownerState:g}=e;return[t.icon,g.variant&&t[`icon${capitalize(g.variant)}`],g.open&&t.iconOpen]}})({}),pC=C.forwardRef(function(e,t){const{className:g,disabled:n,error:o,IconComponent:I,inputRef:a,variant:i="standard",...s}=e,l={...e,disabled:n,variant:i,error:o},c=useUtilityClasses$s(l);return Hg.jsxs(C.Fragment,{children:[Hg.jsx(cC,{ownerState:l,className:clsx(c.select,g),disabled:n,ref:a||t,...s}),e.multiple?null:Hg.jsx(dC,{as:I,ownerState:l,className:c.icon})]})});function hasValue(e){return null!=e&&!(Array.isArray(e)&&0===e.length)}function isFilled(e,t=!1){return e&&(hasValue(e.value)&&""!==e.value||t&&hasValue(e.defaultValue)&&""!==e.defaultValue)}function isAdornedStart(e){return e.startAdornment}function getSelectUtilityClasses(e){return generateUtilityClass("MuiSelect",e)}const mC=generateUtilityClasses("MuiSelect",["root","select","multiple","filled","outlined","standard","disabled","focused","icon","iconOpen","iconFilled","iconOutlined","iconStandard","nativeInput","error"]);function getOpenInteractionType(e){return e?"mousedown"===e.type||"pointerdown"===e.type||"touchstart"===e.type?"pointer":"keydown"===e.type||"click"===e.type&&0===e.detail?"keyboard":null:null}function isEmpty$1(e){return null==e||"string"==typeof e&&!e.trim()}function areEqualValues(e,t){return"object"==typeof t&&null!==t?e===t:String(e)===String(t)}const fC=C.createContext(null);function useSelectFocusSource(){return C.useContext(fC)}const hC=fC.Provider;var yC;const bC=yn(lC,{name:"MuiSelect",slot:"Select",overridesResolver:(e,t)=>{const{ownerState:g}=e;return[{[`&.${mC.select}`]:t.select},{[`&.${mC.select}`]:t[g.variant]},{[`&.${mC.error}`]:t.error},{[`&.${mC.multiple}`]:t.multiple}]}})({[`&.${mC.select}`]:{height:"auto",minHeight:"1.4375em",textOverflow:"ellipsis",whiteSpace:"nowrap",overflow:"hidden"}}),vC=yn(uC,{name:"MuiSelect",slot:"Icon",overridesResolver:(e,t)=>{const{ownerState:g}=e;return[t.icon,g.variant&&t[`icon${capitalize(g.variant)}`],g.open&&t.iconOpen]}})({}),xC=yn("input",{shouldForwardProp:e=>slotShouldForwardProp(e)&&"classes"!==e,name:"MuiSelect",slot:"NativeInput"})({bottom:0,left:0,position:"absolute",opacity:0,pointerEvents:"none",width:"100%",boxSizing:"border-box"}),useUtilityClasses$r=e=>{const{classes:t,variant:g,disabled:n,multiple:C,open:o,error:I}=e;return composeClasses({select:["select",g,n&&"disabled",C&&"multiple",I&&"error"],icon:["icon",`icon${capitalize(g)}`,o&&"iconOpen",n&&"disabled"],nativeInput:["nativeInput"]},getSelectUtilityClasses,t)},SC=C.forwardRef(function(e,t){const{"aria-describedby":g,"aria-label":n,autoFocus:o,autoWidth:I,children:a,className:i,defaultOpen:s,defaultValue:l,disabled:c,displayEmpty:u,error:d=!1,IconComponent:p,inputRef:m,labelId:h,MenuProps:y={},multiple:b,name:v,onBlur:x,onChange:S,onClose:w,onFocus:E,onKeyDown:R,onMouseDown:M,onOpen:T,open:P,readOnly:N,renderValue:O,required:D,SelectDisplayProps:j={},tabIndex:L,type:G,value:B,variant:F="standard",...W}=e,[V,K]=useControlled({controlled:B,default:l,name:"Select"}),[U,H]=useControlled({controlled:P,default:s,name:"Select"}),Y=C.useRef(null),Z=C.useRef(null),[Q,X]=C.useState(null),{current:q}=C.useRef(null!=P),[J,$]=C.useState(),[_,ee]=C.useState(null),te=useForkRef(t,m),ge=C.useCallback(e=>{Z.current=e,e&&X(e)},[]),re=Q?.parentNode;C.useImperativeHandle(te,()=>({focus:()=>{Z.current.focus()},node:Y.current,value:V}),[V]);const ne=null!==Q&&U;C.useEffect(()=>{if(!ne||!re||I)return;if("undefined"==typeof ResizeObserver)return;const e=new ResizeObserver(()=>{$(re.clientWidth)});return e.observe(re),()=>{e.disconnect()}},[ne,re,I]),C.useEffect(()=>{s&&U&&Q&&!q&&($(I?null:re.clientWidth),Z.current.focus())},[Q,I]),C.useEffect(()=>{o&&Z.current.focus()},[o]),C.useEffect(()=>{if(!h)return;const e=ownerDocument(Z.current).getElementById(h);if(e){const handler=()=>{getSelection().isCollapsed&&Z.current.focus()};return e.addEventListener("click",handler),()=>{e.removeEventListener("click",handler)}}},[h]);const update=(e,t)=>{e?(ee(getOpenInteractionType(t)),T&&T(t)):(ee(null),w&&w(t)),q||($(I?null:re.clientWidth),H(e))},handleMouseDown=e=>{M?.(e),0===e.button&&(e.preventDefault(),Z.current.focus(),update(!0,e))},handleClose=e=>{update(!1,e)},Ae=C.Children.toArray(a),handleChange=e=>{const t=Ae.find(t=>t.props.value===e.target.value);void 0!==t&&(K(t.props.value),S&&S(e,t))},handleItemClick=e=>t=>{let g;if(t.currentTarget.hasAttribute("tabindex")){if(b){g=Array.isArray(V)?V.slice():[];const t=V.indexOf(e.props.value);-1===t?g.push(e.props.value):g.splice(t,1)}else g=e.props.value;if(e.props.onClick&&e.props.onClick(t),V!==g&&(K(g),S)){const n=t.nativeEvent||t,C=new n.constructor(n.type,n);Object.defineProperty(C,"target",{writable:!0,value:{value:g,name:v}}),S(C,e)}b||update(!1,t)}},handleKeyDown=e=>{N||([" ","ArrowUp","ArrowDown","Enter"].includes(e.key)&&(e.preventDefault(),update(!0,e)),R?.(e))},handleBlur=e=>{!ne&&x&&(Object.defineProperty(e,"target",{writable:!0,value:{value:V,name:v}}),x(e))};let Ce,oe;delete W["aria-invalid"];const Ie=[];let ae=!1;(isFilled({value:V})||u)&&(O?Ce=O(V):ae=!0);const ie=Ae.map(e=>{if(!C.isValidElement(e))return null;let t;if(b){if(!Array.isArray(V))throw new Error(formatMuiErrorMessage(2));t=V.some(t=>areEqualValues(t,e.props.value)),t&&ae&&Ie.push(e.props.children)}else t=areEqualValues(V,e.props.value),t&&ae&&(oe=e.props.children);return C.cloneElement(e,{"aria-selected":t?"true":"false",onClick:handleItemClick(e),onKeyUp:t=>{" "===t.key&&t.preventDefault(),e.props.onKeyUp&&e.props.onKeyUp(t)},role:"option",selected:t,value:void 0,"data-value":e.props.value})});ae&&(Ce=b?0===Ie.length?null:Ie.reduce((e,t,g)=>(e.push(t),g<Ie.length-1&&e.push(", "),e),[]):oe);let se,le=J;!I&&q&&Q&&(le=re.clientWidth),se=void 0!==L?L:c?null:0;const ce=j.id||(v?`mui-component-select-${v}`:void 0),ue={...e,variant:F,value:V,open:ne,error:d},de=useUtilityClasses$r(ue),pe={...y.PaperProps,..."function"==typeof y.slotProps?.paper?y.slotProps.paper(ue):y.slotProps?.paper},me={...y.MenuListProps,..."function"==typeof y.slotProps?.list?y.slotProps.list(ue):y.slotProps?.list},fe=useId();return Hg.jsxs(C.Fragment,{children:[Hg.jsx(bC,{as:"div",ref:ge,tabIndex:se,role:"combobox","aria-controls":ne?fe:void 0,"aria-disabled":c?"true":void 0,"aria-expanded":ne?"true":"false","aria-haspopup":"listbox","aria-label":n,"aria-labelledby":[h,ce].filter(Boolean).join(" ")||void 0,"aria-describedby":g,"aria-required":D?"true":void 0,"aria-invalid":d?"true":void 0,onKeyDown:handleKeyDown,onMouseDown:c||N?null:handleMouseDown,onBlur:handleBlur,onFocus:E,...j,ownerState:ue,className:clsx(j.className,de.select,i),id:ce,children:isEmpty$1(Ce)?yC||(yC=Hg.jsx("span",{className:"notranslate","aria-hidden":!0,children:"​"})):Ce}),Hg.jsx(xC,{"aria-invalid":d,value:Array.isArray(V)?V.join(","):V,name:v,ref:Y,"aria-hidden":!0,onChange:handleChange,tabIndex:-1,disabled:c,className:de.nativeInput,autoFocus:o,required:D,...W,ownerState:ue}),Hg.jsx(vC,{as:p,className:de.icon,ownerState:ue}),Hg.jsx(hC,{value:_,children:Hg.jsx(UA,{id:`menu-${v||""}`,anchorEl:re,open:ne,onClose:handleClose,anchorOrigin:{vertical:"bottom",horizontal:"center"},transformOrigin:{vertical:"top",horizontal:"center"},...y,slotProps:{...y.slotProps,list:{"aria-labelledby":h,role:"listbox","aria-multiselectable":b?"true":void 0,disableListWrap:!0,id:fe,...me},paper:{...pe,style:{minWidth:le,...null!=pe?pe.style:null}}},children:ie})})]})});function formControlState({props:e,states:t,muiFormControl:g}){return t.reduce((t,n)=>(t[n]=e[n],g&&void 0===e[n]&&(t[n]=g[n]),t),{})}const wC=C.createContext(void 0);function useFormControl(){return C.useContext(wC)}const EC=createSvgIcon(Hg.jsx("path",{d:"M7 10l5 5 5-5z"}));function getStyleValue(e){return parseInt(e,10)||0}const RC={shadow:{visibility:"hidden",position:"absolute",overflow:"hidden",height:0,top:0,left:0,transform:"translateZ(0)"}};function isObjectEmpty(e){for(const t in e)return!1;return!0}function isEmpty(e){return isObjectEmpty(e)||0===e.outerHeightStyle&&!e.overflowing}const kC=C.forwardRef(function(e,t){const{onChange:g,maxRows:n,minRows:o=1,style:I,value:a,...i}=e,{current:s}=C.useRef(null!=a),l=C.useRef(null),c=useForkRef(t,l),u=C.useRef(null),d=C.useRef(null),p=C.useCallback(()=>{const t=l.current,g=d.current;if(!t||!g)return;const C=ownerWindow(t).getComputedStyle(t);if("0px"===C.width)return{outerHeightStyle:0,overflowing:!1};g.style.width=C.width,g.value=t.value||e.placeholder||"x","\n"===g.value.slice(-1)&&(g.value+=" ");const I=C.boxSizing,a=getStyleValue(C.paddingBottom)+getStyleValue(C.paddingTop),i=getStyleValue(C.borderBottomWidth)+getStyleValue(C.borderTopWidth),s=g.scrollHeight;g.value="x";const c=g.scrollHeight;let u=s;return o&&(u=Math.max(Number(o)*c,u)),n&&(u=Math.min(Number(n)*c,u)),u=Math.max(u,c),{outerHeightStyle:u+("border-box"===I?a+i:0),overflowing:Math.abs(u-s)<=1}},[n,o,e.placeholder]),m=useEventCallback(()=>{const e=l.current,t=p();if(!e||!t||isEmpty(t))return!1;const g=t.outerHeightStyle;return null!=u.current&&u.current!==g}),h=C.useCallback(()=>{const e=l.current,t=p();if(!e||!t||isEmpty(t))return;const g=t.outerHeightStyle;u.current!==g&&(u.current=g,e.style.height=`${g}px`),e.style.overflow=t.overflowing?"hidden":""},[p]),y=C.useRef(-1);Dr(()=>{const e=debounce$1(h),t=l?.current;if(!t)return;const g=ownerWindow(t);let n;return g.addEventListener("resize",e),"undefined"!=typeof ResizeObserver&&(n=new ResizeObserver(()=>{m()&&(n.unobserve(t),cancelAnimationFrame(y.current),h(),y.current=requestAnimationFrame(()=>{n.observe(t)}))}),n.observe(t)),()=>{e.clear(),cancelAnimationFrame(y.current),g.removeEventListener("resize",e),n&&n.disconnect()}},[p,h,m]),Dr(()=>{h()});const handleChange=e=>{s||h();const t=e.target,n=t.value.length,C=t.value.endsWith("\n"),o=t.selectionStart===n;C&&o&&t.setSelectionRange(n,n),g&&g(e)};return Hg.jsxs(C.Fragment,{children:[Hg.jsx("textarea",{value:a,onChange:handleChange,ref:c,rows:o,style:I,...i}),Hg.jsx("textarea",{"aria-hidden":!0,className:e.className,readOnly:!0,ref:d,tabIndex:-1,style:{...RC.shadow,...I,paddingTop:0,paddingBottom:0}})]})});function getInputBaseUtilityClass(e){return generateUtilityClass("MuiInputBase",e)}const MC=generateUtilityClasses("MuiInputBase",["root","formControl","focused","disabled","adornedStart","adornedEnd","error","sizeSmall","multiline","colorSecondary","fullWidth","hiddenLabel","readOnly","input","inputSizeSmall","inputMultiline","inputTypeSearch","inputAdornedStart","inputAdornedEnd","inputHiddenLabel"]);var TC;const rootOverridesResolver=(e,t)=>{const{ownerState:g}=e;return[t.root,g.formControl&&t.formControl,g.startAdornment&&t.adornedStart,g.endAdornment&&t.adornedEnd,g.error&&t.error,"small"===g.size&&t.sizeSmall,g.multiline&&t.multiline,g.color&&t[`color${capitalize(g.color)}`],g.fullWidth&&t.fullWidth,g.hiddenLabel&&t.hiddenLabel]},inputOverridesResolver=(e,t)=>{const{ownerState:g}=e;return[t.input,"small"===g.size&&t.inputSizeSmall,g.multiline&&t.inputMultiline,"search"===g.type&&t.inputTypeSearch,g.startAdornment&&t.inputAdornedStart,g.endAdornment&&t.inputAdornedEnd,g.hiddenLabel&&t.inputHiddenLabel]},useUtilityClasses$q=e=>{const{classes:t,color:g,disabled:n,error:C,endAdornment:o,focused:I,formControl:a,fullWidth:i,hiddenLabel:s,multiline:l,readOnly:c,size:u,startAdornment:d,type:p}=e;return composeClasses({root:["root",`color${capitalize(g)}`,n&&"disabled",C&&"error",i&&"fullWidth",I&&"focused",a&&"formControl",u&&"medium"!==u&&`size${capitalize(u)}`,l&&"multiline",d&&"adornedStart",o&&"adornedEnd",s&&"hiddenLabel",c&&"readOnly"],input:["input",n&&"disabled","search"===p&&"inputTypeSearch",l&&"inputMultiline","small"===u&&"inputSizeSmall",s&&"inputHiddenLabel",d&&"inputAdornedStart",o&&"inputAdornedEnd",c&&"readOnly"]},getInputBaseUtilityClass,t)},PC=yn("div",{name:"MuiInputBase",slot:"Root",overridesResolver:rootOverridesResolver})(Rn(({theme:e})=>({...e.typography.body1,color:(e.vars||e).palette.text.primary,lineHeight:"1.4375em",boxSizing:"border-box",position:"relative",cursor:"text",display:"inline-flex",alignItems:"center",[`&.${MC.disabled}`]:{color:(e.vars||e).palette.text.disabled,cursor:"default"},variants:[{props:({ownerState:e})=>e.multiline,style:{padding:"4px 0 5px"}},{props:({ownerState:e,size:t})=>e.multiline&&"small"===t,style:{paddingTop:1}},{props:({ownerState:e})=>e.fullWidth,style:{width:"100%"}}]}))),NC=yn("input",{name:"MuiInputBase",slot:"Input",overridesResolver:inputOverridesResolver})(Rn(({theme:e})=>{const t="light"===e.palette.mode,g={color:"currentColor",...e.vars?{opacity:e.vars.opacity.inputPlaceholder}:{opacity:t?.42:.5},transition:e.transitions.create("opacity",{duration:e.transitions.duration.shorter})},n={opacity:"0 !important"},C=e.vars?{opacity:e.vars.opacity.inputPlaceholder}:{opacity:t?.42:.5};return{font:"inherit",letterSpacing:"inherit",color:"currentColor",padding:"4px 0 5px",border:0,boxSizing:"content-box",background:"none",height:"1.4375em",margin:0,WebkitTapHighlightColor:"transparent",display:"block",minWidth:0,width:"100%","&::-webkit-input-placeholder":g,"&::-moz-placeholder":g,"&::-ms-input-placeholder":g,"&:focus":{outline:0},"&:invalid":{boxShadow:"none"},"&::-webkit-search-decoration":{WebkitAppearance:"none"},[`label[data-shrink=false] + .${MC.formControl} &`]:{"&::-webkit-input-placeholder":n,"&::-moz-placeholder":n,"&::-ms-input-placeholder":n,"&:focus::-webkit-input-placeholder":C,"&:focus::-moz-placeholder":C,"&:focus::-ms-input-placeholder":C},[`&.${MC.disabled}`]:{opacity:1,WebkitTextFillColor:(e.vars||e).palette.text.disabled},variants:[{props:({ownerState:e})=>!e.disableInjectingGlobalStyles,style:{animationName:"mui-auto-fill-cancel",animationDuration:"10ms","&:-webkit-autofill":{animationDuration:"5000s",animationName:"mui-auto-fill"}}},{props:{size:"small"},style:{paddingTop:1}},{props:({ownerState:e})=>e.multiline,style:{height:"auto",resize:"none",padding:0,paddingTop:0}},{props:{type:"search"},style:{MozAppearance:"textfield"}}]}})),OC=globalCss({"@keyframes mui-auto-fill":{from:{display:"block"}},"@keyframes mui-auto-fill-cancel":{from:{display:"block"}}}),DC=C.forwardRef(function(e,t){const g=useDefaultProps({props:e,name:"MuiInputBase"}),{"aria-describedby":n,autoComplete:o,autoFocus:I,className:a,color:i,components:s={},componentsProps:l={},defaultValue:c,disabled:u,disableInjectingGlobalStyles:d,endAdornment:p,error:m,fullWidth:h=!1,id:y,inputComponent:b="input",inputProps:v={},inputRef:x,margin:S,maxRows:w,minRows:E,multiline:R=!1,name:M,onBlur:T,onChange:P,onClick:N,onFocus:O,onKeyDown:D,onKeyUp:j,placeholder:L,readOnly:G,renderSuffix:B,rows:F,size:W,slotProps:V={},slots:K={},startAdornment:U,type:H="text",value:Y,...Z}=g,Q=null!=v.value?v.value:Y,{current:X}=C.useRef(null!=Q),q=C.useRef(),J=C.useCallback(e=>{},[]),$=useForkRef(q,x,v.ref,J),[_,ee]=C.useState(!1),te=useFormControl(),ge=formControlState({props:g,muiFormControl:te,states:["color","disabled","error","hiddenLabel","size","required","filled"]});ge.focused=te?te.focused:_,C.useEffect(()=>{!te&&u&&_&&(ee(!1),T&&T())},[te,u,_,T]);const re=te&&te.onFilled,ne=te&&te.onEmpty,Ae=C.useCallback(e=>{isFilled(e)?re&&re():ne&&ne()},[re,ne]);Dr(()=>{X&&Ae({value:Q})},[Q,Ae,X]);const handleFocus=e=>{O&&O(e),v.onFocus&&v.onFocus(e),te&&te.onFocus?te.onFocus(e):ee(!0)},handleBlur=e=>{T&&T(e),v.onBlur&&v.onBlur(e),te&&te.onBlur?te.onBlur(e):ee(!1)},handleChange=(e,...t)=>{if(!X){const t=e.target||q.current;if(null==t)throw new Error(formatMuiErrorMessage(1));Ae({value:t.value})}v.onChange&&v.onChange(e,...t),P&&P(e,...t)};C.useEffect(()=>{Ae(q.current)},[]);const handleClick=e=>{q.current&&e.currentTarget===e.target&&q.current.focus(),N&&N(e)};let Ce=b,oe=v;R&&"input"===Ce&&(oe=F?{type:void 0,minRows:F,maxRows:F,...oe}:{type:void 0,maxRows:w,minRows:E,...oe},Ce=kC);const handleAutoFill=e=>{Ae("mui-auto-fill-cancel"===e.animationName?q.current:{value:"x"})};C.useEffect(()=>{te&&te.setAdornedStart(Boolean(U))},[te,U]);const Ie={...g,color:ge.color||"primary",disabled:ge.disabled,endAdornment:p,error:ge.error,focused:ge.focused,formControl:te,fullWidth:h,hiddenLabel:ge.hiddenLabel,multiline:R,size:ge.size,startAdornment:U,type:H},ae=useUtilityClasses$q(Ie),ie=K.root||s.Root||PC,se=V.root||l.root||{},le=K.input||s.Input||NC;return oe={...oe,...V.input??l.input},Hg.jsxs(C.Fragment,{children:[!d&&"function"==typeof OC&&(TC||(TC=Hg.jsx(OC,{}))),Hg.jsxs(ie,{...se,ref:t,onClick:handleClick,...Z,...!isHostComponent(ie)&&{ownerState:{...Ie,...se.ownerState}},className:clsx(ae.root,se.className,a,G&&"MuiInputBase-readOnly"),children:[U,Hg.jsx(wC.Provider,{value:null,children:Hg.jsx(le,{"aria-invalid":ge.error,"aria-describedby":n,autoComplete:o,autoFocus:I,defaultValue:c,disabled:ge.disabled,id:y,onAnimationStart:handleAutoFill,name:M,placeholder:L,readOnly:G,required:ge.required,rows:F,value:Q,onKeyDown:D,onKeyUp:j,type:H,...oe,...!isHostComponent(le)&&{as:Ce,ownerState:{...Ie,...oe.ownerState}},ref:$,className:clsx(ae.input,oe.className,G&&"MuiInputBase-readOnly"),onBlur:handleBlur,onChange:handleChange,onFocus:handleFocus})}),p,B?B({...ge,startAdornment:U}):null]})]})});function getInputUtilityClass(e){return generateUtilityClass("MuiInput",e)}const jC={...MC,...generateUtilityClasses("MuiInput",["root","underline","input"])},useUtilityClasses$p=e=>{const{classes:t,disableUnderline:g}=e,n=composeClasses({root:["root",!g&&"underline"],input:["input"]},getInputUtilityClass,t);return{...t,...n}},zC=yn(PC,{shouldForwardProp:e=>rootShouldForwardProp(e)||"classes"===e,name:"MuiInput",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:g}=e;return[...rootOverridesResolver(e,t),!g.disableUnderline&&t.underline]}})(Rn(({theme:e})=>{let t="light"===e.palette.mode?"rgba(0, 0, 0, 0.42)":"rgba(255, 255, 255, 0.7)";return e.vars&&(t=e.alpha(e.vars.palette.common.onBackground,e.vars.opacity.inputUnderline)),{position:"relative",variants:[{props:({ownerState:e})=>e.formControl,style:{"label + &":{marginTop:16}}},{props:({ownerState:e})=>!e.disableUnderline,style:{"&::after":{left:0,bottom:0,content:'""',position:"absolute",right:0,transform:"scaleX(0)",transition:e.transitions.create("transform",{duration:e.transitions.duration.shorter,easing:e.transitions.easing.easeOut}),pointerEvents:"none"},[`&.${jC.focused}:after`]:{transform:"scaleX(1) translateX(0)"},[`&.${jC.error}`]:{"&::before, &::after":{borderBottomColor:(e.vars||e).palette.error.main}},"&::before":{borderBottom:`1px solid ${t}`,left:0,bottom:0,content:'""',position:"absolute",right:0,transition:e.transitions.create("border-bottom-color",{duration:e.transitions.duration.shorter}),pointerEvents:"none"},[`&:hover:not(.${jC.disabled}, .${jC.error}):before`]:{borderBottom:`2px solid ${(e.vars||e).palette.text.primary}`,"@media (hover: none)":{borderBottom:`1px solid ${t}`}},[`&.${jC.disabled}:before`]:{borderBottomStyle:"dotted"}}},...Object.entries(e.palette).filter(createSimplePaletteValueFilter()).map(([t])=>({props:{color:t,disableUnderline:!1},style:{"&::after":{borderBottom:`2px solid ${(e.vars||e).palette[t].main}`}}}))]}})),LC=yn(NC,{name:"MuiInput",slot:"Input",overridesResolver:inputOverridesResolver})({}),GC=C.forwardRef(function(e,t){const g=useDefaultProps({props:e,name:"MuiInput"}),{disableUnderline:n=!1,components:C={},componentsProps:o,fullWidth:I=!1,inputComponent:a="input",multiline:i=!1,slotProps:s,slots:l={},type:c="text",...u}=g,d=useUtilityClasses$p(g),p={root:{ownerState:{disableUnderline:n}}},m=s??o?deepmerge(s??o,p):p,h=l.root??C.Root??zC,y=l.input??C.Input??LC;return Hg.jsx(DC,{slots:{root:h,input:y},slotProps:m,fullWidth:I,inputComponent:a,multiline:i,ref:t,type:c,...u,classes:d})});function getFilledInputUtilityClass(e){return generateUtilityClass("MuiFilledInput",e)}GC.muiName="Input";const BC={...MC,...generateUtilityClasses("MuiFilledInput",["root","underline","input","adornedStart","adornedEnd","sizeSmall","multiline","hiddenLabel"])},useUtilityClasses$o=e=>{const{classes:t,disableUnderline:g,startAdornment:n,endAdornment:C,size:o,hiddenLabel:I,multiline:a}=e,i=composeClasses({root:["root",!g&&"underline",n&&"adornedStart",C&&"adornedEnd","small"===o&&`size${capitalize(o)}`,I&&"hiddenLabel",a&&"multiline"],input:["input"]},getFilledInputUtilityClass,t);return{...t,...i}},FC=yn(PC,{shouldForwardProp:e=>rootShouldForwardProp(e)||"classes"===e,name:"MuiFilledInput",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:g}=e;return[...rootOverridesResolver(e,t),!g.disableUnderline&&t.underline]}})(Rn(({theme:e})=>{const t="light"===e.palette.mode,g=t?"rgba(0, 0, 0, 0.42)":"rgba(255, 255, 255, 0.7)",n=t?"rgba(0, 0, 0, 0.06)":"rgba(255, 255, 255, 0.09)",C=t?"rgba(0, 0, 0, 0.09)":"rgba(255, 255, 255, 0.13)",o=t?"rgba(0, 0, 0, 0.12)":"rgba(255, 255, 255, 0.12)";return{position:"relative",backgroundColor:e.vars?e.vars.palette.FilledInput.bg:n,borderTopLeftRadius:(e.vars||e).shape.borderRadius,borderTopRightRadius:(e.vars||e).shape.borderRadius,transition:e.transitions.create("background-color",{duration:e.transitions.duration.shorter,easing:e.transitions.easing.easeOut}),"&:hover":{backgroundColor:e.vars?e.vars.palette.FilledInput.hoverBg:C,"@media (hover: none)":{backgroundColor:e.vars?e.vars.palette.FilledInput.bg:n}},[`&.${BC.focused}`]:{backgroundColor:e.vars?e.vars.palette.FilledInput.bg:n},[`&.${BC.disabled}`]:{backgroundColor:e.vars?e.vars.palette.FilledInput.disabledBg:o},variants:[{props:({ownerState:e})=>!e.disableUnderline,style:{"&::after":{left:0,bottom:0,content:'""',position:"absolute",right:0,transform:"scaleX(0)",transition:e.transitions.create("transform",{duration:e.transitions.duration.shorter,easing:e.transitions.easing.easeOut}),pointerEvents:"none"},[`&.${BC.focused}:after`]:{transform:"scaleX(1) translateX(0)"},[`&.${BC.error}`]:{"&::before, &::after":{borderBottomColor:(e.vars||e).palette.error.main}},"&::before":{borderBottom:`1px solid ${e.vars?e.alpha(e.vars.palette.common.onBackground,e.vars.opacity.inputUnderline):g}`,left:0,bottom:0,content:'""',position:"absolute",right:0,transition:e.transitions.create("border-bottom-color",{duration:e.transitions.duration.shorter}),pointerEvents:"none"},[`&:hover:not(.${BC.disabled}, .${BC.error}):before`]:{borderBottom:`1px solid ${(e.vars||e).palette.text.primary}`},[`&.${BC.disabled}:before`]:{borderBottomStyle:"dotted"}}},...Object.entries(e.palette).filter(createSimplePaletteValueFilter()).map(([t])=>({props:{disableUnderline:!1,color:t},style:{"&::after":{borderBottom:`2px solid ${(e.vars||e).palette[t]?.main}`}}})),{props:({ownerState:e})=>e.startAdornment,style:{paddingLeft:12}},{props:({ownerState:e})=>e.endAdornment,style:{paddingRight:12}},{props:({ownerState:e})=>e.multiline,style:{padding:"25px 12px 8px"}},{props:({ownerState:e,size:t})=>e.multiline&&"small"===t,style:{paddingTop:21,paddingBottom:4}},{props:({ownerState:e})=>e.multiline&&e.hiddenLabel,style:{paddingTop:16,paddingBottom:17}},{props:({ownerState:e})=>e.multiline&&e.hiddenLabel&&"small"===e.size,style:{paddingTop:8,paddingBottom:9}}]}})),WC=yn(NC,{name:"MuiFilledInput",slot:"Input",overridesResolver:inputOverridesResolver})(Rn(({theme:e})=>({paddingTop:25,paddingRight:12,paddingBottom:8,paddingLeft:12,...!e.vars&&{"&:-webkit-autofill":{WebkitBoxShadow:"light"===e.palette.mode?null:"0 0 0 100px #266798 inset",WebkitTextFillColor:"light"===e.palette.mode?null:"#fff",caretColor:"light"===e.palette.mode?null:"#fff",borderTopLeftRadius:"inherit",borderTopRightRadius:"inherit"}},...e.vars&&{"&:-webkit-autofill":{borderTopLeftRadius:"inherit",borderTopRightRadius:"inherit"},[e.getColorSchemeSelector("dark")]:{"&:-webkit-autofill":{WebkitBoxShadow:"0 0 0 100px #266798 inset",WebkitTextFillColor:"#fff",caretColor:"#fff"}}},variants:[{props:{size:"small"},style:{paddingTop:21,paddingBottom:4}},{props:({ownerState:e})=>e.hiddenLabel,style:{paddingTop:16,paddingBottom:17}},{props:({ownerState:e})=>e.startAdornment,style:{paddingLeft:0}},{props:({ownerState:e})=>e.endAdornment,style:{paddingRight:0}},{props:({ownerState:e})=>e.hiddenLabel&&"small"===e.size,style:{paddingTop:8,paddingBottom:9}},{props:({ownerState:e})=>e.multiline,style:{paddingTop:0,paddingBottom:0,paddingLeft:0,paddingRight:0}}]}))),VC=C.forwardRef(function(e,t){const g=useDefaultProps({props:e,name:"MuiFilledInput"}),{disableUnderline:n=!1,components:C={},componentsProps:o,fullWidth:I=!1,hiddenLabel:a,inputComponent:i="input",multiline:s=!1,slotProps:l,slots:c={},type:u="text",...d}=g,p={...g,disableUnderline:n,fullWidth:I,inputComponent:i,multiline:s,type:u},m=useUtilityClasses$o(g),h={root:{ownerState:p},input:{ownerState:p}},y=l??o?deepmerge(h,l??o):h,b=c.root??C.Root??FC,v=c.input??C.Input??WC;return Hg.jsx(DC,{slots:{root:b,input:v},slotProps:y,fullWidth:I,inputComponent:i,multiline:s,ref:t,type:u,...d,classes:m})});var KC;VC.muiName="Input";const UC=yn("fieldset",{name:"MuiNotchedOutlined",shouldForwardProp:rootShouldForwardProp})({textAlign:"left",position:"absolute",bottom:0,right:0,top:-5,left:0,margin:0,padding:"0 8px",pointerEvents:"none",borderRadius:"inherit",borderStyle:"solid",borderWidth:1,overflow:"hidden",minWidth:"0%"}),HC=yn("legend",{name:"MuiNotchedOutlined",shouldForwardProp:rootShouldForwardProp})(Rn(({theme:e})=>({float:"unset",width:"auto",overflow:"hidden",variants:[{props:({ownerState:e})=>!e.withLabel,style:{padding:0,lineHeight:"11px",transition:e.transitions.create("width",{duration:150,easing:e.transitions.easing.easeOut})}},{props:({ownerState:e})=>e.withLabel,style:{display:"block",padding:0,height:11,fontSize:"0.75em",visibility:"hidden",maxWidth:.01,transition:e.transitions.create("max-width",{duration:50,easing:e.transitions.easing.easeOut}),whiteSpace:"nowrap","& > span":{paddingLeft:5,paddingRight:5,display:"inline-block",opacity:0,visibility:"visible"}}},{props:({ownerState:e})=>e.withLabel&&e.notched,style:{maxWidth:"100%",transition:e.transitions.create("max-width",{duration:100,easing:e.transitions.easing.easeOut,delay:50})}}]})));function NotchedOutline(e){const{children:t,classes:g,className:n,label:C,notched:o,...I}=e,a=null!=C&&""!==C,i={...e,notched:o,withLabel:a};return Hg.jsx(UC,{"aria-hidden":!0,className:n,ownerState:i,...I,children:Hg.jsx(HC,{ownerState:i,children:a?Hg.jsx("span",{children:C}):KC||(KC=Hg.jsx("span",{className:"notranslate","aria-hidden":!0,children:"​"}))})})}function getOutlinedInputUtilityClass(e){return generateUtilityClass("MuiOutlinedInput",e)}const YC={...MC,...generateUtilityClasses("MuiOutlinedInput",["root","notchedOutline","input"])},useUtilityClasses$n=e=>{const{classes:t}=e,g=composeClasses({root:["root"],notchedOutline:["notchedOutline"],input:["input"]},getOutlinedInputUtilityClass,t);return{...t,...g}},ZC=yn(PC,{shouldForwardProp:e=>rootShouldForwardProp(e)||"classes"===e,name:"MuiOutlinedInput",slot:"Root",overridesResolver:rootOverridesResolver})(Rn(({theme:e})=>{const t="light"===e.palette.mode?"rgba(0, 0, 0, 0.23)":"rgba(255, 255, 255, 0.23)";return{position:"relative",borderRadius:(e.vars||e).shape.borderRadius,[`&:hover .${YC.notchedOutline}`]:{borderColor:(e.vars||e).palette.text.primary},"@media (hover: none)":{[`&:hover .${YC.notchedOutline}`]:{borderColor:e.vars?e.alpha(e.vars.palette.common.onBackground,.23):t}},[`&.${YC.focused} .${YC.notchedOutline}`]:{borderWidth:2},variants:[...Object.entries(e.palette).filter(createSimplePaletteValueFilter()).map(([t])=>({props:{color:t},style:{[`&.${YC.focused} .${YC.notchedOutline}`]:{borderColor:(e.vars||e).palette[t].main}}})),{props:{},style:{[`&.${YC.error} .${YC.notchedOutline}`]:{borderColor:(e.vars||e).palette.error.main},[`&.${YC.disabled} .${YC.notchedOutline}`]:{borderColor:(e.vars||e).palette.action.disabled}}},{props:({ownerState:e})=>e.startAdornment,style:{paddingLeft:14}},{props:({ownerState:e})=>e.endAdornment,style:{paddingRight:14}},{props:({ownerState:e})=>e.multiline,style:{padding:"16.5px 14px"}},{props:({ownerState:e,size:t})=>e.multiline&&"small"===t,style:{padding:"8.5px 14px"}}]}})),QC=yn(NotchedOutline,{name:"MuiOutlinedInput",slot:"NotchedOutline"})(Rn(({theme:e})=>{const t="light"===e.palette.mode?"rgba(0, 0, 0, 0.23)":"rgba(255, 255, 255, 0.23)";return{borderColor:e.vars?e.alpha(e.vars.palette.common.onBackground,.23):t}})),XC=yn(NC,{name:"MuiOutlinedInput",slot:"Input",overridesResolver:inputOverridesResolver})(Rn(({theme:e})=>({padding:"16.5px 14px",...!e.vars&&{"&:-webkit-autofill":{WebkitBoxShadow:"light"===e.palette.mode?null:"0 0 0 100px #266798 inset",WebkitTextFillColor:"light"===e.palette.mode?null:"#fff",caretColor:"light"===e.palette.mode?null:"#fff",borderRadius:"inherit"}},...e.vars&&{"&:-webkit-autofill":{borderRadius:"inherit"},[e.getColorSchemeSelector("dark")]:{"&:-webkit-autofill":{WebkitBoxShadow:"0 0 0 100px #266798 inset",WebkitTextFillColor:"#fff",caretColor:"#fff"}}},variants:[{props:{size:"small"},style:{padding:"8.5px 14px"}},{props:({ownerState:e})=>e.multiline,style:{padding:0}},{props:({ownerState:e})=>e.startAdornment,style:{paddingLeft:0}},{props:({ownerState:e})=>e.endAdornment,style:{paddingRight:0}}]}))),qC=C.forwardRef(function(e,t){const g=useDefaultProps({props:e,name:"MuiOutlinedInput"}),{components:n={},fullWidth:o=!1,inputComponent:I="input",label:a,multiline:i=!1,notched:s,slots:l={},slotProps:c={},type:u="text",...d}=g,p=useUtilityClasses$n(g),m=useFormControl(),h=formControlState({props:g,muiFormControl:m,states:["color","disabled","error","focused","hiddenLabel","size","required"]}),y={...g,color:h.color||"primary",disabled:h.disabled,error:h.error,focused:h.focused,formControl:m,fullWidth:o,hiddenLabel:h.hiddenLabel,multiline:i,size:h.size,type:u},b=l.root??n.Root??ZC,v=l.input??n.Input??XC,[x,S]=useSlot("notchedOutline",{elementType:QC,className:p.notchedOutline,shouldForwardComponentProp:!0,ownerState:y,externalForwardedProps:{slots:l,slotProps:c},additionalProps:{label:null!=a&&""!==a&&h.required?Hg.jsxs(C.Fragment,{children:[a," ","*"]}):a}});return Hg.jsx(DC,{slots:{root:b,input:v},slotProps:c,renderSuffix:e=>Hg.jsx(x,{...S,notched:void 0!==s?s:Boolean(e.startAdornment||e.filled||e.focused)}),fullWidth:o,inputComponent:I,multiline:i,ref:t,type:u,...d,classes:{...p,notchedOutline:null}})});qC.muiName="Input";const useUtilityClasses$m=e=>{const{classes:t}=e,g=composeClasses({root:["root"]},getSelectUtilityClasses,t);return{...t,...g}},JC={name:"MuiSelect",slot:"Root",shouldForwardProp:e=>rootShouldForwardProp(e)&&"variant"!==e},$C=yn(GC,JC)(""),_C=yn(qC,JC)(""),eo=yn(VC,JC)(""),to=C.forwardRef(function(e,t){const g=useDefaultProps({name:"MuiSelect",props:e}),{autoWidth:n=!1,children:o,classes:I={},className:a,defaultOpen:i=!1,displayEmpty:s=!1,IconComponent:l=EC,id:c,input:u,inputProps:d,label:p,labelId:m,MenuProps:h,multiple:y=!1,native:b=!1,onClose:v,onOpen:x,open:S,renderValue:w,SelectDisplayProps:E,variant:R="outlined",...M}=g,T=b?pC:SC,P=formControlState({props:g,muiFormControl:useFormControl(),states:["variant","error"]}),N=P.variant||R,O={...g,variant:N,classes:I},D=useUtilityClasses$m(O),{root:j,...L}=D,G=u||{standard:Hg.jsx($C,{ownerState:O}),outlined:Hg.jsx(_C,{label:p,ownerState:O}),filled:Hg.jsx(eo,{ownerState:O})}[N],B=useForkRef(t,getReactElementRef(G));return Hg.jsx(C.Fragment,{children:C.cloneElement(G,{inputComponent:T,inputProps:{children:o,error:P.error,IconComponent:l,variant:N,type:void 0,multiple:y,...b?{id:c}:{autoWidth:n,defaultOpen:i,displayEmpty:s,labelId:m,MenuProps:h,onClose:v,onOpen:x,open:S,renderValue:w,SelectDisplayProps:{id:c,...E}},...d,classes:d?deepmerge(L,d.classes):L,...u?u.props.inputProps:{}},...(y&&b||s)&&"outlined"===N?{notched:!0}:{},ref:B,className:clsx(G.props.className,a,D.root),...!u&&{variant:N},...M})})});function focusWithVisible(e,t){if(null!=t)try{e.focus({focusVisible:"keyboard"===t})}catch(g){e.focus()}else e.focus()}to.muiName="Select";const useUtilityClasses$l=e=>{const{disabled:t,dense:g,divider:n,disableGutters:C,selected:o,classes:I}=e,a=composeClasses({root:["root",g&&"dense",t&&"disabled",!C&&"gutters",n&&"divider",o&&"selected"]},getMenuItemUtilityClass,I);return{...I,...a}},go=yn(rC,{shouldForwardProp:e=>rootShouldForwardProp(e)||"classes"===e,name:"MuiMenuItem",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:g}=e;return[t.root,g.dense&&t.dense,g.divider&&t.divider,!g.disableGutters&&t.gutters]}})(Rn(({theme:e})=>({...e.typography.body1,display:"flex",justifyContent:"flex-start",alignItems:"center",position:"relative",textDecoration:"none",minHeight:48,paddingTop:6,paddingBottom:6,boxSizing:"border-box",whiteSpace:"nowrap","&:hover":{textDecoration:"none",backgroundColor:(e.vars||e).palette.action.hover,"@media (hover: none)":{backgroundColor:"transparent"}},[`&.${iC.selected}`]:{backgroundColor:e.alpha((e.vars||e).palette.primary.main,(e.vars||e).palette.action.selectedOpacity),[`&.${iC.focusVisible}`]:{backgroundColor:e.alpha((e.vars||e).palette.primary.main,`${(e.vars||e).palette.action.selectedOpacity} + ${(e.vars||e).palette.action.focusOpacity}`)}},[`&.${iC.selected}:hover`]:{backgroundColor:e.alpha((e.vars||e).palette.primary.main,`${(e.vars||e).palette.action.selectedOpacity} + ${(e.vars||e).palette.action.hoverOpacity}`),"@media (hover: none)":{backgroundColor:e.alpha((e.vars||e).palette.primary.main,(e.vars||e).palette.action.selectedOpacity)}},[`&.${iC.focusVisible}`]:{backgroundColor:(e.vars||e).palette.action.focus},[`&.${iC.disabled}`]:{opacity:(e.vars||e).palette.action.disabledOpacity},[`& + .${nC.root}`]:{marginTop:e.spacing(1),marginBottom:e.spacing(1)},[`& + .${nC.inset}`]:{marginLeft:52},[`& .${aC.root}`]:{marginTop:0,marginBottom:0},[`& .${aC.inset}`]:{paddingLeft:36},[`& .${IC.root}`]:{minWidth:36},variants:[{props:({ownerState:e})=>!e.disableGutters,style:{paddingLeft:16,paddingRight:16}},{props:({ownerState:e})=>e.divider,style:{borderBottom:`1px solid ${(e.vars||e).palette.divider}`,backgroundClip:"padding-box"}},{props:({ownerState:e})=>!e.dense,style:{[e.breakpoints.up("sm")]:{minHeight:"auto"}}},{props:({ownerState:e})=>e.dense,style:{minHeight:32,paddingTop:4,paddingBottom:4,...e.typography.body2,[`& .${IC.root} svg`]:{fontSize:"1.25rem"}}}]}))),ro=C.forwardRef(function(e,t){const g=useDefaultProps({props:e,name:"MuiMenuItem"}),{autoFocus:n=!1,component:o="li",dense:I=!1,divider:a=!1,disableGutters:i=!1,focusVisibleClassName:s,role:l="menuitem",tabIndex:c,className:u,...d}=g,p=useSelectFocusSource(),m=C.useContext(tA),h=C.useMemo(()=>({dense:I||m.dense||!1,disableGutters:i}),[m.dense,I,i]),y=C.useRef(null);Dr(()=>{n&&y.current&&focusWithVisible(y.current,p)},[n]);const b={...g,dense:h.dense,divider:a,disableGutters:i},v=useUtilityClasses$l(g),x=useForkRef(y,t);let S;return g.disabled||(S=void 0!==c?c:-1),Hg.jsx(tA.Provider,{value:h,children:Hg.jsx(go,{ref:x,role:l,tabIndex:S,component:o,focusVisibleClassName:clsx(v.focusVisible,s),className:clsx(v.root,u),...d,ownerState:b,classes:v})})}),getRoomItemLookupEntry=e=>e&&"object"==typeof e?getRoomItemOverride(e):null,getRoomItemBackground=e=>{const t=getRoomItemLookupEntry(e);return t?.background??void 0},getRoomItemColor=e=>{const t=getRoomItemLookupEntry(e);return t?t.color:"t"===e?.attrib?"orange":void 0},getRoomItemLabel=e=>{if("string"==typeof e)return e;const t=getRoomItemLookupEntry(e);return t?t.text:e?.name},getRoomItemCommands=e=>{const t=["Probe"];return"string"==typeof e?.attrib&&e.attrib.includes("t")&&t.unshift("Get"),t},sortRoomItemsLikeNexGui3=e=>[...e].sort((e,t)=>{const g=getRoomItemLookupEntry(e);return getRoomItemLookupEntry(t)&&!g?-1:"t"!==t?.attrib||"t"===e?.attrib||g?1:-1}),selectRoomSlice=e=>({players:e.players,npcs:e.npcs,items:e.items,roomName:e.roomName,roomId:e.roomId,updateRoom:e.updateRoom}),useRoom=()=>{const{stores:e}=useNexGui();return e.room(useShallow(selectRoomSlice))},toDisplayItem=(e,t)=>"string"==typeof e?{commands:[],id:null,key:`room-item-string-${t}-${e}`,label:getRoomItemLabel(e),name:e,raw:e,rowBackground:void 0,rowColor:void 0}:e&&"object"==typeof e?{commands:null==e.id?[]:getRoomItemCommands(e),id:e.id??null,key:`room-item-${e.id??`${t}-${e.name??"unknown"}`}`,label:getRoomItemLabel(e)??e.name??"",name:e.name??"",raw:e,rowBackground:getRoomItemBackground(e),rowColor:getRoomItemColor(e)}:null,useRoomItemsViewModel=()=>{const{adapter:e}=useNexGui(),{items:g}=useRoom(),[n,C]=t.useState(0);t.useEffect(()=>subscribeToRoomItemOverrides(()=>C(e=>e+1)),[]);const o=t.useMemo(()=>sortRoomItemsLikeNexGui3((g??[]).filter(e=>!isRoomNpcItem(e))).map((e,t)=>toDisplayItem(e,t)).filter(Boolean),[g,n]),I=t.useCallback((t,g)=>{null!=g?.id&&e?.send?.(`${t} ${g.id}`)},[e]);return t.useMemo(()=>({items:o,sendItemCommand:I}),[o,I])},getFlipTransform$8=e=>{switch(e){case 1:return"scaleX(-1) scaleY(-1)";case 2:return"scaleY(-1)";case 3:return"scaleX(-1)";default:return"none"}},ItemsPanelInner=()=>{const e=useTheme$1(),{items:g,sendItemCommand:n}=useRoomItemsViewModel(),[C]=t.useState(()=>Math.floor(4*Math.random())),[o,I]=t.useState(null),[a,i]=t.useState(null),s=e?.nexGui?.backgroundImage??"",l=e?.nexGui?.backgroundOpacity??.5,c=e?.nexGui?.backgroundFilter??"none",u=Boolean(o),d=a?.commands??[],handleCloseMenu=()=>{I(null),i(null)},handleOpenMenu=(e,t)=>{t&&null!=t.id&&0!==t.commands.length&&(i(t),I(e.currentTarget))},handleCommandClick=e=>{null!=a?.id?(n(e,a),handleCloseMenu()):handleCloseMenu()};return React.createElement(En,{className:"items-panel",sx:{color:"text.primary",fontFamily:e.typography.fontFamily,fontSize:e.typography.fontSize,height:"100%",overflow:"hidden",position:"relative",width:"100%"}},s?React.createElement(En,{"aria-hidden":"true",className:"items-panel__background",sx:{backgroundImage:`url(${s})`,backgroundPosition:"center",backgroundSize:"cover",filter:c,height:"100%",inset:0,left:0,opacity:l,position:"absolute",top:0,transform:getFlipTransform$8(C),width:"100%",zIndex:0}}):null,React.createElement(En,{className:"items-panel__content","data-testid":"items-panel-content",sx:{display:"flex",flexDirection:"column-reverse",height:"100%",overflow:"auto",position:"relative",width:"100%",zIndex:1}},g.length>0?React.createElement(En,{className:"items-panel__rows",sx:{display:"table",m:"10px",maxWidth:"100%",p:"1px",position:"relative",textAlign:"left"}},g.map(e=>{const t=null!=e.id&&e.commands.length>0;return React.createElement(En,{key:e.key,className:["items-panel__row",t?"items-panel__row--interactive":""].filter(Boolean).join(" "),onClick:t?t=>handleOpenMenu(t,e):void 0,onContextMenu:t?t=>{t.preventDefault(),handleOpenMenu(t,e)}:void 0,sx:{backgroundColor:e.rowBackground??"transparent",cursor:t?"pointer":"inherit",display:"table-row"}},React.createElement(En,{component:"div",sx:{color:"cyan",display:"table-cell",padding:"0px 5px 0px 2px",whiteSpace:"nowrap"}},React.createElement(zn,{component:"span",sx:{color:"inherit",fontVariantNumeric:"tabular-nums"},variant:"body2"},e.id??"")),React.createElement(En,{component:"div",sx:{display:"table-cell",padding:0,width:"100%"}},React.createElement(zn,{component:"span",sx:{color:e.rowColor??"text.primary"},variant:"body2"},e.label)))})):null),React.createElement(UA,{anchorEl:o,onClose:handleCloseMenu,open:u,slotProps:{paper:{sx:{backgroundColor:"#000000",border:"1px solid #ffffff"}}}},d.map(e=>React.createElement(ro,{key:e,onClick:()=>handleCommandClick(e)},e))))};ItemsPanelInner.displayName="ItemsPanelInner";const ItemsPanel=()=>React.createElement(Ln,{panelName:"Items"},React.createElement(ItemsPanelInner,null));function getCircularProgressUtilityClass(e){return generateUtilityClass("MuiCircularProgress",e)}ItemsPanel.displayName="ItemsPanel",generateUtilityClasses("MuiCircularProgress",["root","determinate","indeterminate","colorPrimary","colorSecondary","svg","track","circle","circleDeterminate","circleIndeterminate","circleDisableShrink"]);const no=44,Ao=keyframes`
75
+ 0% {
76
+ transform: rotate(0deg);
77
+ }
78
+
79
+ 100% {
80
+ transform: rotate(360deg);
81
+ }
82
+ `,Co=keyframes`
83
+ 0% {
84
+ stroke-dasharray: 1px, 200px;
85
+ stroke-dashoffset: 0;
86
+ }
87
+
88
+ 50% {
89
+ stroke-dasharray: 100px, 200px;
90
+ stroke-dashoffset: -15px;
91
+ }
92
+
93
+ 100% {
94
+ stroke-dasharray: 1px, 200px;
95
+ stroke-dashoffset: -126px;
96
+ }
97
+ `,oo="string"!=typeof Ao?css`
98
+ animation: ${Ao} 1.4s linear infinite;
99
+ `:null,Io="string"!=typeof Co?css`
100
+ animation: ${Co} 1.4s ease-in-out infinite;
101
+ `:null,useUtilityClasses$k=e=>{const{classes:t,variant:g,color:n,disableShrink:C}=e;return composeClasses({root:["root",g,`color${capitalize(n)}`],svg:["svg"],track:["track"],circle:["circle",`circle${capitalize(g)}`,C&&"circleDisableShrink"]},getCircularProgressUtilityClass,t)},ao=yn("span",{name:"MuiCircularProgress",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:g}=e;return[t.root,t[g.variant],t[`color${capitalize(g.color)}`]]}})(Rn(({theme:e})=>({display:"inline-block",variants:[{props:{variant:"determinate"},style:{transition:e.transitions.create("transform")}},{props:{variant:"indeterminate"},style:oo||{animation:`${Ao} 1.4s linear infinite`}},...Object.entries(e.palette).filter(createSimplePaletteValueFilter()).map(([t])=>({props:{color:t},style:{color:(e.vars||e).palette[t].main}}))]}))),io=yn("svg",{name:"MuiCircularProgress",slot:"Svg"})({display:"block"}),so=yn("circle",{name:"MuiCircularProgress",slot:"Circle",overridesResolver:(e,t)=>{const{ownerState:g}=e;return[t.circle,t[`circle${capitalize(g.variant)}`],g.disableShrink&&t.circleDisableShrink]}})(Rn(({theme:e})=>({stroke:"currentColor",variants:[{props:{variant:"determinate"},style:{transition:e.transitions.create("stroke-dashoffset")}},{props:{variant:"indeterminate"},style:{strokeDasharray:"80px, 200px",strokeDashoffset:0}},{props:({ownerState:e})=>"indeterminate"===e.variant&&!e.disableShrink,style:Io||{animation:`${Co} 1.4s ease-in-out infinite`}}]}))),lo=yn("circle",{name:"MuiCircularProgress",slot:"Track"})(Rn(({theme:e})=>({stroke:"currentColor",opacity:(e.vars||e).palette.action.activatedOpacity}))),co=C.forwardRef(function(e,t){const g=useDefaultProps({props:e,name:"MuiCircularProgress"}),{className:n,color:C="primary",disableShrink:o=!1,enableTrackSlot:I=!1,size:a=40,style:i,thickness:s=3.6,value:l=0,variant:c="indeterminate",...u}=g,d={...g,color:C,disableShrink:o,size:a,thickness:s,value:l,variant:c,enableTrackSlot:I},p=useUtilityClasses$k(d),m={},h={},y={};if("determinate"===c){const e=2*Math.PI*((no-s)/2);m.strokeDasharray=e.toFixed(3),y["aria-valuenow"]=Math.round(l),m.strokeDashoffset=`${((100-l)/100*e).toFixed(3)}px`,h.transform="rotate(-90deg)"}return Hg.jsx(ao,{className:clsx(p.root,n),style:{width:a,height:a,...h,...i},ownerState:d,ref:t,role:"progressbar",...y,...u,children:Hg.jsxs(io,{className:p.svg,ownerState:d,viewBox:`${no/2} ${no/2} ${no} ${no}`,children:[I?Hg.jsx(lo,{className:p.track,ownerState:d,cx:no,cy:no,r:(no-s)/2,fill:"none",strokeWidth:s,"aria-hidden":"true"}):null,Hg.jsx(so,{className:p.circle,style:m,ownerState:d,cx:no,cy:no,r:(no-s)/2,fill:"none",strokeWidth:s})]})})});function getButtonUtilityClass(e){return generateUtilityClass("MuiButton",e)}const uo=generateUtilityClasses("MuiButton",["root","text","textInherit","textPrimary","textSecondary","textSuccess","textError","textInfo","textWarning","outlined","outlinedInherit","outlinedPrimary","outlinedSecondary","outlinedSuccess","outlinedError","outlinedInfo","outlinedWarning","contained","containedInherit","containedPrimary","containedSecondary","containedSuccess","containedError","containedInfo","containedWarning","disableElevation","focusVisible","disabled","colorInherit","colorPrimary","colorSecondary","colorSuccess","colorError","colorInfo","colorWarning","textSizeSmall","textSizeMedium","textSizeLarge","outlinedSizeSmall","outlinedSizeMedium","outlinedSizeLarge","containedSizeSmall","containedSizeMedium","containedSizeLarge","sizeMedium","sizeSmall","sizeLarge","fullWidth","startIcon","endIcon","icon","iconSizeSmall","iconSizeMedium","iconSizeLarge","loading","loadingWrapper","loadingIconPlaceholder","loadingIndicator","loadingPositionCenter","loadingPositionStart","loadingPositionEnd"]),po=C.createContext({}),mo=C.createContext(void 0),useUtilityClasses$j=e=>{const{color:t,disableElevation:g,fullWidth:n,size:C,variant:o,loading:I,loadingPosition:a,classes:i}=e,s=composeClasses({root:["root",I&&"loading",o,`${o}${capitalize(t)}`,`size${capitalize(C)}`,`${o}Size${capitalize(C)}`,`color${capitalize(t)}`,g&&"disableElevation",n&&"fullWidth",I&&`loadingPosition${capitalize(a)}`],startIcon:["icon","startIcon",`iconSize${capitalize(C)}`],endIcon:["icon","endIcon",`iconSize${capitalize(C)}`],loadingIndicator:["loadingIndicator"],loadingWrapper:["loadingWrapper"]},getButtonUtilityClass,i);return{...i,...s}},fo=[{props:{size:"small"},style:{"& > *:nth-of-type(1)":{fontSize:18}}},{props:{size:"medium"},style:{"& > *:nth-of-type(1)":{fontSize:20}}},{props:{size:"large"},style:{"& > *:nth-of-type(1)":{fontSize:22}}}],ho=yn(rC,{shouldForwardProp:e=>rootShouldForwardProp(e)||"classes"===e,name:"MuiButton",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:g}=e;return[t.root,t[g.variant],t[`${g.variant}${capitalize(g.color)}`],t[`size${capitalize(g.size)}`],t[`${g.variant}Size${capitalize(g.size)}`],"inherit"===g.color&&t.colorInherit,g.disableElevation&&t.disableElevation,g.fullWidth&&t.fullWidth,g.loading&&t.loading]}})(Rn(({theme:e})=>{const t="light"===e.palette.mode?e.palette.grey[300]:e.palette.grey[800],g="light"===e.palette.mode?e.palette.grey.A100:e.palette.grey[700];return{...e.typography.button,minWidth:64,padding:"6px 16px",border:0,borderRadius:(e.vars||e).shape.borderRadius,transition:e.transitions.create(["background-color","box-shadow","border-color","color"],{duration:e.transitions.duration.short}),"&:hover":{textDecoration:"none"},[`&.${uo.disabled}`]:{color:(e.vars||e).palette.action.disabled},variants:[{props:{variant:"contained"},style:{color:"var(--variant-containedColor)",backgroundColor:"var(--variant-containedBg)",boxShadow:(e.vars||e).shadows[2],"&:hover":{boxShadow:(e.vars||e).shadows[4],"@media (hover: none)":{boxShadow:(e.vars||e).shadows[2]}},"&:active":{boxShadow:(e.vars||e).shadows[8]},[`&.${uo.focusVisible}`]:{boxShadow:(e.vars||e).shadows[6]},[`&.${uo.disabled}`]:{color:(e.vars||e).palette.action.disabled,boxShadow:(e.vars||e).shadows[0],backgroundColor:(e.vars||e).palette.action.disabledBackground}}},{props:{variant:"outlined"},style:{padding:"5px 15px",border:"1px solid currentColor",borderColor:"var(--variant-outlinedBorder, currentColor)",backgroundColor:"var(--variant-outlinedBg)",color:"var(--variant-outlinedColor)",[`&.${uo.disabled}`]:{border:`1px solid ${(e.vars||e).palette.action.disabledBackground}`}}},{props:{variant:"text"},style:{padding:"6px 8px",color:"var(--variant-textColor)",backgroundColor:"var(--variant-textBg)"}},...Object.entries(e.palette).filter(createSimplePaletteValueFilter()).map(([t])=>({props:{color:t},style:{"--variant-textColor":(e.vars||e).palette[t].main,"--variant-outlinedColor":(e.vars||e).palette[t].main,"--variant-outlinedBorder":e.alpha((e.vars||e).palette[t].main,.5),"--variant-containedColor":(e.vars||e).palette[t].contrastText,"--variant-containedBg":(e.vars||e).palette[t].main,"@media (hover: hover)":{"&:hover":{"--variant-containedBg":(e.vars||e).palette[t].dark,"--variant-textBg":e.alpha((e.vars||e).palette[t].main,(e.vars||e).palette.action.hoverOpacity),"--variant-outlinedBorder":(e.vars||e).palette[t].main,"--variant-outlinedBg":e.alpha((e.vars||e).palette[t].main,(e.vars||e).palette.action.hoverOpacity)}}}})),{props:{color:"inherit"},style:{color:"inherit",borderColor:"currentColor","--variant-containedBg":e.vars?e.vars.palette.Button.inheritContainedBg:t,"@media (hover: hover)":{"&:hover":{"--variant-containedBg":e.vars?e.vars.palette.Button.inheritContainedHoverBg:g,"--variant-textBg":e.alpha((e.vars||e).palette.text.primary,(e.vars||e).palette.action.hoverOpacity),"--variant-outlinedBg":e.alpha((e.vars||e).palette.text.primary,(e.vars||e).palette.action.hoverOpacity)}}}},{props:{size:"small",variant:"text"},style:{padding:"4px 5px",fontSize:e.typography.pxToRem(13)}},{props:{size:"large",variant:"text"},style:{padding:"8px 11px",fontSize:e.typography.pxToRem(15)}},{props:{size:"small",variant:"outlined"},style:{padding:"3px 9px",fontSize:e.typography.pxToRem(13)}},{props:{size:"large",variant:"outlined"},style:{padding:"7px 21px",fontSize:e.typography.pxToRem(15)}},{props:{size:"small",variant:"contained"},style:{padding:"4px 10px",fontSize:e.typography.pxToRem(13)}},{props:{size:"large",variant:"contained"},style:{padding:"8px 22px",fontSize:e.typography.pxToRem(15)}},{props:{disableElevation:!0},style:{boxShadow:"none","&:hover":{boxShadow:"none"},[`&.${uo.focusVisible}`]:{boxShadow:"none"},"&:active":{boxShadow:"none"},[`&.${uo.disabled}`]:{boxShadow:"none"}}},{props:{fullWidth:!0},style:{width:"100%"}},{props:{loadingPosition:"center"},style:{transition:e.transitions.create(["background-color","box-shadow","border-color"],{duration:e.transitions.duration.short}),[`&.${uo.loading}`]:{color:"transparent"}}}]}})),yo=yn("span",{name:"MuiButton",slot:"StartIcon",overridesResolver:(e,t)=>{const{ownerState:g}=e;return[t.startIcon,g.loading&&t.startIconLoadingStart,t[`iconSize${capitalize(g.size)}`]]}})(({theme:e})=>({display:"inherit",marginRight:8,marginLeft:-4,variants:[{props:{size:"small"},style:{marginLeft:-2}},{props:{loadingPosition:"start",loading:!0},style:{transition:e.transitions.create(["opacity"],{duration:e.transitions.duration.short}),opacity:0}},{props:{loadingPosition:"start",loading:!0,fullWidth:!0},style:{marginRight:-8}},...fo]})),bo=yn("span",{name:"MuiButton",slot:"EndIcon",overridesResolver:(e,t)=>{const{ownerState:g}=e;return[t.endIcon,g.loading&&t.endIconLoadingEnd,t[`iconSize${capitalize(g.size)}`]]}})(({theme:e})=>({display:"inherit",marginRight:-4,marginLeft:8,variants:[{props:{size:"small"},style:{marginRight:-2}},{props:{loadingPosition:"end",loading:!0},style:{transition:e.transitions.create(["opacity"],{duration:e.transitions.duration.short}),opacity:0}},{props:{loadingPosition:"end",loading:!0,fullWidth:!0},style:{marginLeft:-8}},...fo]})),vo=yn("span",{name:"MuiButton",slot:"LoadingIndicator"})(({theme:e})=>({display:"none",position:"absolute",visibility:"visible",variants:[{props:{loading:!0},style:{display:"flex"}},{props:{loadingPosition:"start"},style:{left:14}},{props:{loadingPosition:"start",size:"small"},style:{left:10}},{props:{variant:"text",loadingPosition:"start"},style:{left:6}},{props:{loadingPosition:"center"},style:{left:"50%",transform:"translate(-50%)",color:(e.vars||e).palette.action.disabled}},{props:{loadingPosition:"end"},style:{right:14}},{props:{loadingPosition:"end",size:"small"},style:{right:10}},{props:{variant:"text",loadingPosition:"end"},style:{right:6}},{props:{loadingPosition:"start",fullWidth:!0},style:{position:"relative",left:-10}},{props:{loadingPosition:"end",fullWidth:!0},style:{position:"relative",right:-10}}]})),xo=yn("span",{name:"MuiButton",slot:"LoadingIconPlaceholder"})({display:"inline-block",width:"1em",height:"1em"}),So=C.forwardRef(function(e,t){const g=C.useContext(po),n=C.useContext(mo),o=useDefaultProps({props:resolveProps(g,e),name:"MuiButton"}),{children:I,color:a="primary",component:i="button",className:s,disabled:l=!1,disableElevation:c=!1,disableFocusRipple:u=!1,endIcon:d,focusVisibleClassName:p,fullWidth:m=!1,id:h,loading:y=null,loadingIndicator:b,loadingPosition:v="center",size:x="medium",startIcon:S,type:w,variant:E="text",...R}=o,M=useId(h),T=b??Hg.jsx(co,{"aria-labelledby":M,color:"inherit",size:16}),P={...o,color:a,component:i,disabled:l,disableElevation:c,disableFocusRipple:u,fullWidth:m,loading:y,loadingIndicator:T,loadingPosition:v,size:x,type:w,variant:E},N=useUtilityClasses$j(P),O=(S||y&&"start"===v)&&Hg.jsx(yo,{className:N.startIcon,ownerState:P,children:S||Hg.jsx(xo,{className:N.loadingIconPlaceholder,ownerState:P})}),D=(d||y&&"end"===v)&&Hg.jsx(bo,{className:N.endIcon,ownerState:P,children:d||Hg.jsx(xo,{className:N.loadingIconPlaceholder,ownerState:P})}),j=n||"",L="boolean"==typeof y?Hg.jsx("span",{className:N.loadingWrapper,style:{display:"contents"},children:y&&Hg.jsx(vo,{className:N.loadingIndicator,ownerState:P,children:T})}):null;return Hg.jsxs(ho,{ownerState:P,className:clsx(g.className,N.root,s,j),component:i,disabled:l||y,focusRipple:!u,focusVisibleClassName:clsx(N.focusVisible,p),ref:t,type:w,id:y?M:h,...R,classes:N,children:[O,"end"!==v&&L,I,"end"===v&&L,D]})});function getDialogUtilityClass(e){return generateUtilityClass("MuiDialog",e)}const wo=generateUtilityClasses("MuiDialog",["root","backdrop","scrollPaper","scrollBody","container","paper","paperScrollPaper","paperScrollBody","paperWidthFalse","paperWidthXs","paperWidthSm","paperWidthMd","paperWidthLg","paperWidthXl","paperFullWidth","paperFullScreen"]),Eo=C.createContext({}),Ro=yn(PA,{name:"MuiDialog",slot:"Backdrop"})({zIndex:-1}),useUtilityClasses$i=e=>{const{classes:t,scroll:g,maxWidth:n,fullWidth:C,fullScreen:o}=e;return composeClasses({root:["root"],backdrop:["backdrop"],container:["container",`scroll${capitalize(g)}`],paper:["paper",`paperScroll${capitalize(g)}`,`paperWidth${capitalize(String(n))}`,C&&"paperFullWidth",o&&"paperFullScreen"]},getDialogUtilityClass,t)},ko=yn(jA,{name:"MuiDialog",slot:"Root"})({"@media print":{position:"absolute !important"}}),Mo=yn("div",{name:"MuiDialog",slot:"Container",overridesResolver:(e,t)=>{const{ownerState:g}=e;return[t.container,t[`scroll${capitalize(g.scroll)}`]]}})({height:"100%","@media print":{height:"auto"},outline:0,variants:[{props:{scroll:"paper"},style:{display:"flex",justifyContent:"center",alignItems:"center"}},{props:{scroll:"body"},style:{overflowY:"auto",overflowX:"hidden",textAlign:"center","&::after":{content:'""',display:"inline-block",verticalAlign:"middle",height:"100%",width:"0"}}}]}),To=yn(Mn,{name:"MuiDialog",slot:"Paper",overridesResolver:(e,t)=>{const{ownerState:g}=e;return[t.paper,t[`scrollPaper${capitalize(g.scroll)}`],t[`paperWidth${capitalize(String(g.maxWidth))}`],g.fullWidth&&t.paperFullWidth,g.fullScreen&&t.paperFullScreen]}})(Rn(({theme:e})=>({margin:32,position:"relative",overflowY:"auto","@media print":{overflowY:"visible",boxShadow:"none"},variants:[{props:{scroll:"paper"},style:{display:"flex",flexDirection:"column",maxHeight:"calc(100% - 64px)"}},{props:{scroll:"body"},style:{display:"inline-block",verticalAlign:"middle",textAlign:"initial"}},{props:({ownerState:e})=>!e.maxWidth,style:{maxWidth:"calc(100% - 64px)"}},{props:{maxWidth:"xs"},style:{maxWidth:"px"===e.breakpoints.unit?Math.max(e.breakpoints.values.xs,444):`max(${e.breakpoints.values.xs}${e.breakpoints.unit}, 444px)`,[`&.${wo.paperScrollBody}`]:{[e.breakpoints.down(Math.max(e.breakpoints.values.xs,444)+64)]:{maxWidth:"calc(100% - 64px)"}}}},...Object.keys(e.breakpoints.values).filter(e=>"xs"!==e).map(t=>({props:{maxWidth:t},style:{maxWidth:`${e.breakpoints.values[t]}${e.breakpoints.unit}`,[`&.${wo.paperScrollBody}`]:{[e.breakpoints.down(e.breakpoints.values[t]+64)]:{maxWidth:"calc(100% - 64px)"}}}})),{props:({ownerState:e})=>e.fullWidth,style:{width:"calc(100% - 64px)"}},{props:({ownerState:e})=>e.fullScreen,style:{margin:0,width:"100%",maxWidth:"100%",height:"100%",maxHeight:"none",borderRadius:0,[`&.${wo.paperScrollBody}`]:{margin:0,maxWidth:"100%"}}}]}))),Po=C.forwardRef(function(e,t){const g=useDefaultProps({props:e,name:"MuiDialog"}),n=useTheme$1(),o={enter:n.transitions.duration.enteringScreen,exit:n.transitions.duration.leavingScreen},{"aria-describedby":I,"aria-labelledby":a,"aria-modal":i=!0,BackdropComponent:s,BackdropProps:l,children:c,className:u,disableEscapeKeyDown:d=!1,fullScreen:p=!1,fullWidth:m=!1,maxWidth:h="sm",onClick:y,onClose:b,open:v,PaperComponent:x=Mn,PaperProps:S={},role:w="dialog",scroll:E="paper",slots:R={},slotProps:M={},TransitionComponent:T=MA,transitionDuration:P=o,TransitionProps:N,...O}=g,D={...g,disableEscapeKeyDown:d,fullScreen:p,fullWidth:m,maxWidth:h,scroll:E},j=useUtilityClasses$i(D),L=C.useRef(),handleMouseDown=e=>{L.current=e.target===e.currentTarget},handleBackdropClick=e=>{y&&y(e),L.current&&(L.current=null,b&&b(e,"backdropClick"))},G=useId(a),B=C.useMemo(()=>({titleId:G}),[G]),F={slots:{transition:T,...R},slotProps:{transition:N,paper:S,backdrop:l,...M}},[W,V]=useSlot("root",{elementType:ko,shouldForwardComponentProp:!0,externalForwardedProps:F,ownerState:D,className:clsx(j.root,u),ref:t}),[K,U]=useSlot("backdrop",{elementType:Ro,shouldForwardComponentProp:!0,externalForwardedProps:F,ownerState:D,className:j.backdrop}),[H,Y]=useSlot("paper",{elementType:To,shouldForwardComponentProp:!0,externalForwardedProps:F,ownerState:D,className:clsx(j.paper,S.className)}),[Z,Q]=useSlot("container",{elementType:Mo,externalForwardedProps:F,ownerState:D,className:j.container}),[X,q]=useSlot("transition",{elementType:MA,externalForwardedProps:F,ownerState:D,additionalProps:{appear:!0,in:v,timeout:P,role:"presentation"}});return Hg.jsx(W,{closeAfterTransition:!0,slots:{backdrop:K},slotProps:{backdrop:{transitionDuration:P,as:s,...U}},disableEscapeKeyDown:d,onClose:b,open:v,onClick:handleBackdropClick,...V,...O,children:Hg.jsx(X,{...q,children:Hg.jsx(Z,{onMouseDown:handleMouseDown,...Q,children:Hg.jsx(H,{as:x,elevation:24,role:w,"aria-describedby":I,"aria-labelledby":G,"aria-modal":i,...Y,children:Hg.jsx(Eo.Provider,{value:B,children:c})})})})})});function getDialogActionsUtilityClass(e){return generateUtilityClass("MuiDialogActions",e)}generateUtilityClasses("MuiDialogActions",["root","spacing"]);const useUtilityClasses$h=e=>{const{classes:t,disableSpacing:g}=e;return composeClasses({root:["root",!g&&"spacing"]},getDialogActionsUtilityClass,t)},No=yn("div",{name:"MuiDialogActions",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:g}=e;return[t.root,!g.disableSpacing&&t.spacing]}})({display:"flex",alignItems:"center",padding:8,justifyContent:"flex-end",flex:"0 0 auto",variants:[{props:({ownerState:e})=>!e.disableSpacing,style:{"& > :not(style) ~ :not(style)":{marginLeft:8}}}]}),Oo=C.forwardRef(function(e,t){const g=useDefaultProps({props:e,name:"MuiDialogActions"}),{className:n,disableSpacing:C=!1,...o}=g,I={...g,disableSpacing:C},a=useUtilityClasses$h(I);return Hg.jsx(No,{className:clsx(a.root,n),ownerState:I,ref:t,...o})});function getDialogContentUtilityClass(e){return generateUtilityClass("MuiDialogContent",e)}function getDialogTitleUtilityClass(e){return generateUtilityClass("MuiDialogTitle",e)}generateUtilityClasses("MuiDialogContent",["root","dividers"]);const Do=generateUtilityClasses("MuiDialogTitle",["root"]),useUtilityClasses$g=e=>{const{classes:t,dividers:g}=e;return composeClasses({root:["root",g&&"dividers"]},getDialogContentUtilityClass,t)},jo=yn("div",{name:"MuiDialogContent",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:g}=e;return[t.root,g.dividers&&t.dividers]}})(Rn(({theme:e})=>({flex:"1 1 auto",WebkitOverflowScrolling:"touch",overflowY:"auto",padding:"20px 24px",variants:[{props:({ownerState:e})=>e.dividers,style:{padding:"16px 24px",borderTop:`1px solid ${(e.vars||e).palette.divider}`,borderBottom:`1px solid ${(e.vars||e).palette.divider}`}},{props:({ownerState:e})=>!e.dividers,style:{[`.${Do.root} + &`]:{paddingTop:0}}}]}))),zo=C.forwardRef(function(e,t){const g=useDefaultProps({props:e,name:"MuiDialogContent"}),{className:n,dividers:C=!1,...o}=g,I={...g,dividers:C},a=useUtilityClasses$g(I);return Hg.jsx(jo,{className:clsx(a.root,n),ownerState:I,ref:t,...o})}),useUtilityClasses$f=e=>{const{classes:t}=e;return composeClasses({root:["root"]},getDialogTitleUtilityClass,t)},Lo=yn(zn,{name:"MuiDialogTitle",slot:"Root"})({padding:"16px 24px",flex:"0 0 auto"}),Go=C.forwardRef(function(e,t){const g=useDefaultProps({props:e,name:"MuiDialogTitle"}),{className:n,id:o,...I}=g,a=g,i=useUtilityClasses$f(a),{titleId:s=o}=C.useContext(Eo);return Hg.jsx(Lo,{component:"h2",className:clsx(i.root,n),ownerState:a,ref:t,variant:"h6",id:o??s,...I})});function getFormControlUtilityClasses(e){return generateUtilityClass("MuiFormControl",e)}generateUtilityClasses("MuiFormControl",["root","marginNone","marginNormal","marginDense","fullWidth","disabled"]);const useUtilityClasses$e=e=>{const{classes:t,margin:g,fullWidth:n}=e;return composeClasses({root:["root","none"!==g&&`margin${capitalize(g)}`,n&&"fullWidth"]},getFormControlUtilityClasses,t)},Bo=yn("div",{name:"MuiFormControl",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:g}=e;return[t.root,t[`margin${capitalize(g.margin)}`],g.fullWidth&&t.fullWidth]}})({display:"inline-flex",flexDirection:"column",position:"relative",minWidth:0,padding:0,margin:0,border:0,verticalAlign:"top",variants:[{props:{margin:"normal"},style:{marginTop:16,marginBottom:8}},{props:{margin:"dense"},style:{marginTop:8,marginBottom:4}},{props:{fullWidth:!0},style:{width:"100%"}}]}),Fo=C.forwardRef(function(e,t){const g=useDefaultProps({props:e,name:"MuiFormControl"}),{children:n,className:o,color:I="primary",component:a="div",disabled:i=!1,error:s=!1,focused:l,fullWidth:c=!1,hiddenLabel:u=!1,margin:d="none",required:p=!1,size:m="medium",variant:h="outlined",...y}=g,b={...g,color:I,component:a,disabled:i,error:s,fullWidth:c,hiddenLabel:u,margin:d,required:p,size:m,variant:h},v=useUtilityClasses$e(b),[x,S]=C.useState(()=>{let e=!1;return n&&C.Children.forEach(n,t=>{if(!isMuiElement(t,["Input","Select"]))return;const g=isMuiElement(t,["Select"])?t.props.input:t;g&&isAdornedStart(g.props)&&(e=!0)}),e}),[w,E]=C.useState(()=>{let e=!1;return n&&C.Children.forEach(n,t=>{isMuiElement(t,["Input","Select"])&&(isFilled(t.props,!0)||isFilled(t.props.inputProps,!0))&&(e=!0)}),e}),[R,M]=C.useState(!1);i&&R&&M(!1);const T=void 0===l||i?R:l;let P;C.useRef(!1);const N=C.useCallback(()=>{E(!0)},[]),O=C.useCallback(()=>{E(!1)},[]),D=C.useMemo(()=>({adornedStart:x,setAdornedStart:S,color:I,disabled:i,error:s,filled:w,focused:T,fullWidth:c,hiddenLabel:u,size:m,onBlur:()=>{M(!1)},onFocus:()=>{M(!0)},onEmpty:O,onFilled:N,registerEffect:P,required:p,variant:h}),[x,I,i,s,w,T,c,u,P,O,N,p,m,h]);return Hg.jsx(wC.Provider,{value:D,children:Hg.jsx(Bo,{as:a,ownerState:b,className:clsx(v.root,o),ref:t,...y,children:n})})});function getFormControlLabelUtilityClasses(e){return generateUtilityClass("MuiFormControlLabel",e)}const Wo=generateUtilityClasses("MuiFormControlLabel",["root","labelPlacementStart","labelPlacementTop","labelPlacementBottom","disabled","label","error","required","asterisk"]),useUtilityClasses$d=e=>{const{classes:t,disabled:g,labelPlacement:n,error:C,required:o}=e;return composeClasses({root:["root",g&&"disabled",`labelPlacement${capitalize(n)}`,C&&"error",o&&"required"],label:["label",g&&"disabled"],asterisk:["asterisk",C&&"error"]},getFormControlLabelUtilityClasses,t)},Vo=yn("label",{name:"MuiFormControlLabel",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:g}=e;return[{[`& .${Wo.label}`]:t.label},t.root,t[`labelPlacement${capitalize(g.labelPlacement)}`]]}})(Rn(({theme:e})=>({display:"inline-flex",alignItems:"center",cursor:"pointer",verticalAlign:"middle",WebkitTapHighlightColor:"transparent",marginLeft:-11,marginRight:16,[`&.${Wo.disabled}`]:{cursor:"default"},[`& .${Wo.label}`]:{[`&.${Wo.disabled}`]:{color:(e.vars||e).palette.text.disabled}},variants:[{props:{labelPlacement:"start"},style:{flexDirection:"row-reverse",marginRight:-11}},{props:{labelPlacement:"top"},style:{flexDirection:"column-reverse"}},{props:{labelPlacement:"bottom"},style:{flexDirection:"column"}},{props:({labelPlacement:e})=>"start"===e||"top"===e||"bottom"===e,style:{marginLeft:16}}]}))),Ko=yn("span",{name:"MuiFormControlLabel",slot:"Asterisk"})(Rn(({theme:e})=>({[`&.${Wo.error}`]:{color:(e.vars||e).palette.error.main}}))),Uo=C.forwardRef(function(e,t){const g=useDefaultProps({props:e,name:"MuiFormControlLabel"}),{checked:n,className:o,componentsProps:I={},control:a,disabled:i,disableTypography:s,inputRef:l,label:c,labelPlacement:u="end",name:d,onChange:p,required:m,slots:h={},slotProps:y={},value:b,...v}=g,x=useFormControl(),S=i??a.props.disabled??x?.disabled,w=m??a.props.required,E={disabled:S,required:w};["checked","name","onChange","value","inputRef"].forEach(e=>{void 0===a.props[e]&&void 0!==g[e]&&(E[e]=g[e])});const R=formControlState({props:g,muiFormControl:x,states:["error"]}),M={...g,disabled:S,labelPlacement:u,required:w,error:R.error},T=useUtilityClasses$d(M),P={slots:h,slotProps:{...I,...y}},[N,O]=useSlot("typography",{elementType:zn,externalForwardedProps:P,ownerState:M});let D=c;return null==D||D.type===zn||s||(D=Hg.jsx(N,{component:"span",...O,className:clsx(T.label,O?.className),children:D})),Hg.jsxs(Vo,{className:clsx(T.root,o),ownerState:M,ref:t,...v,children:[C.cloneElement(a,E),w?Hg.jsxs("div",{children:[D,Hg.jsxs(Ko,{ownerState:M,"aria-hidden":!0,className:T.asterisk,children:[" ","*"]})]}):D]})});function getSwitchBaseUtilityClass(e){return generateUtilityClass("PrivateSwitchBase",e)}generateUtilityClasses("PrivateSwitchBase",["root","checked","disabled","input","edgeStart","edgeEnd"]);const useUtilityClasses$c=e=>{const{classes:t,checked:g,disabled:n,edge:C}=e;return composeClasses({root:["root",g&&"checked",n&&"disabled",C&&`edge${capitalize(C)}`],input:["input"]},getSwitchBaseUtilityClass,t)},Ho=yn(rC,{name:"MuiSwitchBase"})({padding:9,borderRadius:"50%",variants:[{props:{edge:"start",size:"small"},style:{marginLeft:-3}},{props:({edge:e,ownerState:t})=>"start"===e&&"small"!==t.size,style:{marginLeft:-12}},{props:{edge:"end",size:"small"},style:{marginRight:-3}},{props:({edge:e,ownerState:t})=>"end"===e&&"small"!==t.size,style:{marginRight:-12}}]}),Yo=yn("input",{name:"MuiSwitchBase",shouldForwardProp:rootShouldForwardProp})({cursor:"inherit",position:"absolute",opacity:0,width:"100%",height:"100%",top:0,left:0,margin:0,padding:0,zIndex:1}),Zo=C.forwardRef(function(e,t){const{autoFocus:g,checked:n,checkedIcon:C,defaultChecked:o,disabled:I,disableFocusRipple:a=!1,edge:i=!1,icon:s,id:l,inputProps:c,inputRef:u,name:d,onBlur:p,onChange:m,onFocus:h,readOnly:y,required:b=!1,tabIndex:v,type:x,value:S,slots:w={},slotProps:E={},...R}=e,[M,T]=useControlled({controlled:n,default:Boolean(o),name:"SwitchBase",state:"checked"}),P=useFormControl(),handleFocus=e=>{h&&h(e),P&&P.onFocus&&P.onFocus(e)},handleBlur=e=>{p&&p(e),P&&P.onBlur&&P.onBlur(e)},handleInputChange=e=>{if(e.nativeEvent.defaultPrevented||y)return;const t=e.target.checked;T(t),m&&m(e,t)};let N=I;P&&void 0===N&&(N=P.disabled);const O="checkbox"===x||"radio"===x,D={...e,checked:M,disabled:N,disableFocusRipple:a,edge:i},j=useUtilityClasses$c(D),L={slots:w,slotProps:{input:c,...E}},[G,B]=useSlot("root",{ref:t,elementType:Ho,className:j.root,shouldForwardComponentProp:!0,externalForwardedProps:{...L,component:"span",...R},getSlotProps:e=>({...e,onFocus:t=>{e.onFocus?.(t),handleFocus(t)},onBlur:t=>{e.onBlur?.(t),handleBlur(t)}}),ownerState:D,additionalProps:{centerRipple:!0,focusRipple:!a,role:void 0,tabIndex:null}}),[F,W]=useSlot("input",{ref:u,elementType:Yo,className:j.input,externalForwardedProps:L,getSlotProps:e=>({...e,onChange:t=>{e.onChange?.(t),handleInputChange(t)}}),ownerState:D,additionalProps:{autoFocus:g,checked:n,defaultChecked:o,disabled:N,id:O?l:void 0,name:d,readOnly:y,required:b,tabIndex:v,type:x,..."checkbox"===x&&void 0===S?{}:{value:S}}});return Hg.jsxs(G,{...B,children:[Hg.jsx(F,{...W}),M?C:s]})});function getSwitchUtilityClass(e){return generateUtilityClass("MuiSwitch",e)}const Qo=generateUtilityClasses("MuiSwitch",["root","edgeStart","edgeEnd","switchBase","colorPrimary","colorSecondary","sizeSmall","sizeMedium","checked","disabled","input","thumb","track"]),useUtilityClasses$b=e=>{const{classes:t,edge:g,size:n,color:C,checked:o,disabled:I}=e,a=composeClasses({root:["root",g&&`edge${capitalize(g)}`,`size${capitalize(n)}`],switchBase:["switchBase",`color${capitalize(C)}`,o&&"checked",I&&"disabled"],thumb:["thumb"],track:["track"],input:["input"]},getSwitchUtilityClass,t);return{...t,...a}},Xo=yn("span",{name:"MuiSwitch",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:g}=e;return[t.root,g.edge&&t[`edge${capitalize(g.edge)}`],t[`size${capitalize(g.size)}`]]}})({display:"inline-flex",width:58,height:38,overflow:"hidden",padding:12,boxSizing:"border-box",position:"relative",flexShrink:0,zIndex:0,verticalAlign:"middle","@media print":{colorAdjust:"exact"},variants:[{props:{edge:"start"},style:{marginLeft:-8}},{props:{edge:"end"},style:{marginRight:-8}},{props:{size:"small"},style:{width:40,height:24,padding:7,[`& .${Qo.thumb}`]:{width:16,height:16},[`& .${Qo.switchBase}`]:{padding:4,[`&.${Qo.checked}`]:{transform:"translateX(16px)"}}}}]}),qo=yn(Zo,{name:"MuiSwitch",slot:"SwitchBase",overridesResolver:(e,t)=>{const{ownerState:g}=e;return[t.switchBase,{[`& .${Qo.input}`]:t.input},"default"!==g.color&&t[`color${capitalize(g.color)}`]]}})(Rn(({theme:e})=>({position:"absolute",top:0,left:0,zIndex:1,color:e.vars?e.vars.palette.Switch.defaultColor:`${"light"===e.palette.mode?e.palette.common.white:e.palette.grey[300]}`,transition:e.transitions.create(["left","transform"],{duration:e.transitions.duration.shortest}),[`&.${Qo.checked}`]:{transform:"translateX(20px)"},[`&.${Qo.disabled}`]:{color:e.vars?e.vars.palette.Switch.defaultDisabledColor:`${"light"===e.palette.mode?e.palette.grey[100]:e.palette.grey[600]}`},[`&.${Qo.checked} + .${Qo.track}`]:{opacity:.5},[`&.${Qo.disabled} + .${Qo.track}`]:{opacity:e.vars?e.vars.opacity.switchTrackDisabled:""+("light"===e.palette.mode?.12:.2)},[`& .${Qo.input}`]:{left:"-100%",width:"300%"}})),Rn(({theme:e})=>({"&:hover":{backgroundColor:e.alpha((e.vars||e).palette.action.active,(e.vars||e).palette.action.hoverOpacity),"@media (hover: none)":{backgroundColor:"transparent"}},variants:[...Object.entries(e.palette).filter(createSimplePaletteValueFilter(["light"])).map(([t])=>({props:{color:t},style:{[`&.${Qo.checked}`]:{color:(e.vars||e).palette[t].main,"&:hover":{backgroundColor:e.alpha((e.vars||e).palette[t].main,(e.vars||e).palette.action.hoverOpacity),"@media (hover: none)":{backgroundColor:"transparent"}},[`&.${Qo.disabled}`]:{color:e.vars?e.vars.palette.Switch[`${t}DisabledColor`]:`${"light"===e.palette.mode?e.lighten(e.palette[t].main,.62):e.darken(e.palette[t].main,.55)}`}},[`&.${Qo.checked} + .${Qo.track}`]:{backgroundColor:(e.vars||e).palette[t].main}}}))]}))),Jo=yn("span",{name:"MuiSwitch",slot:"Track"})(Rn(({theme:e})=>({height:"100%",width:"100%",borderRadius:7,boxSizing:"border-box",border:"1px solid transparent",zIndex:-1,transition:e.transitions.create(["opacity","background-color"],{duration:e.transitions.duration.shortest}),backgroundColor:e.vars?e.vars.palette.common.onBackground:`${"light"===e.palette.mode?e.palette.common.black:e.palette.common.white}`,opacity:e.vars?e.vars.opacity.switchTrack:""+("light"===e.palette.mode?.38:.3)}))),$o=yn("span",{name:"MuiSwitch",slot:"Thumb"})(Rn(({theme:e})=>({boxShadow:(e.vars||e).shadows[1],backgroundColor:"currentColor",boxSizing:"border-box",border:"1px solid transparent",width:20,height:20,borderRadius:"50%"}))),_o=C.forwardRef(function(e,t){const g=useDefaultProps({props:e,name:"MuiSwitch"}),{className:n,color:C="primary",edge:o=!1,size:I="medium",sx:a,slots:i={},slotProps:s={},...l}=g,c={...g,color:C,edge:o,size:I},u=useUtilityClasses$b(c),d={slots:i,slotProps:s},[p,m]=useSlot("root",{className:clsx(u.root,n),elementType:Xo,externalForwardedProps:d,ownerState:c,additionalProps:{sx:a}}),[h,y]=useSlot("thumb",{className:u.thumb,elementType:$o,externalForwardedProps:d,ownerState:c}),b=Hg.jsx(h,{...y}),[v,x]=useSlot("track",{className:u.track,elementType:Jo,externalForwardedProps:d,ownerState:c});return Hg.jsxs(p,{...m,children:[Hg.jsx(qo,{type:"checkbox",icon:b,checkedIcon:b,ref:t,ownerState:c,...l,classes:{...u,root:u.switchBase},slots:{...i.switchBase&&{root:i.switchBase},...i.input&&{input:i.input}},slotProps:{...s.switchBase&&{root:"function"==typeof s.switchBase?s.switchBase(c):s.switchBase},input:{role:"switch"},...s.input&&{input:"function"==typeof s.input?s.input(c):s.input}}}),Hg.jsx(v,{...x})]})});function getFormLabelUtilityClasses(e){return generateUtilityClass("MuiFormLabel",e)}const eI=generateUtilityClasses("MuiFormLabel",["root","colorSecondary","focused","disabled","error","filled","required","asterisk"]),useUtilityClasses$a=e=>{const{classes:t,color:g,focused:n,disabled:C,error:o,filled:I,required:a}=e;return composeClasses({root:["root",`color${capitalize(g)}`,C&&"disabled",o&&"error",I&&"filled",n&&"focused",a&&"required"],asterisk:["asterisk",o&&"error"]},getFormLabelUtilityClasses,t)},tI=yn("label",{name:"MuiFormLabel",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:g}=e;return[t.root,"secondary"===g.color&&t.colorSecondary,g.filled&&t.filled]}})(Rn(({theme:e})=>({color:(e.vars||e).palette.text.secondary,...e.typography.body1,lineHeight:"1.4375em",padding:0,position:"relative",variants:[...Object.entries(e.palette).filter(createSimplePaletteValueFilter()).map(([t])=>({props:{color:t},style:{[`&.${eI.focused}`]:{color:(e.vars||e).palette[t].main}}})),{props:{},style:{[`&.${eI.disabled}`]:{color:(e.vars||e).palette.text.disabled},[`&.${eI.error}`]:{color:(e.vars||e).palette.error.main}}}]}))),gI=yn("span",{name:"MuiFormLabel",slot:"Asterisk"})(Rn(({theme:e})=>({[`&.${eI.error}`]:{color:(e.vars||e).palette.error.main}}))),rI=C.forwardRef(function(e,t){const g=useDefaultProps({props:e,name:"MuiFormLabel"}),{children:n,className:C,color:o,component:I="label",disabled:a,error:i,filled:s,focused:l,required:c,...u}=g,d=formControlState({props:g,muiFormControl:useFormControl(),states:["color","required","focused","disabled","error","filled"]}),p={...g,color:d.color||"primary",component:I,disabled:d.disabled,error:d.error,filled:d.filled,focused:d.focused,required:d.required},m=useUtilityClasses$a(p);return Hg.jsxs(tI,{as:I,ownerState:p,className:clsx(m.root,C),ref:t,...u,children:[n,d.required&&Hg.jsxs(gI,{ownerState:p,"aria-hidden":!0,className:m.asterisk,children:[" ","*"]})]})});function getInputLabelUtilityClasses(e){return generateUtilityClass("MuiInputLabel",e)}generateUtilityClasses("MuiInputLabel",["root","focused","disabled","error","required","asterisk","formControl","sizeSmall","shrink","animated","standard","filled","outlined"]);const useUtilityClasses$9=e=>{const{classes:t,formControl:g,size:n,shrink:C,disableAnimation:o,variant:I,required:a}=e,i=composeClasses({root:["root",g&&"formControl",!o&&"animated",C&&"shrink",n&&"medium"!==n&&`size${capitalize(n)}`,I],asterisk:[a&&"asterisk"]},getInputLabelUtilityClasses,t);return{...t,...i}},nI=yn(rI,{shouldForwardProp:e=>rootShouldForwardProp(e)||"classes"===e,name:"MuiInputLabel",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:g}=e;return[{[`& .${eI.asterisk}`]:t.asterisk},t.root,g.formControl&&t.formControl,"small"===g.size&&t.sizeSmall,g.shrink&&t.shrink,!g.disableAnimation&&t.animated,g.focused&&t.focused,t[g.variant]]}})(Rn(({theme:e})=>({display:"block",transformOrigin:"top left",whiteSpace:"nowrap",overflow:"hidden",textOverflow:"ellipsis",maxWidth:"100%",variants:[{props:({ownerState:e})=>e.formControl,style:{position:"absolute",left:0,top:0,transform:"translate(0, 20px) scale(1)"}},{props:{size:"small"},style:{transform:"translate(0, 17px) scale(1)"}},{props:({ownerState:e})=>e.shrink,style:{transform:"translate(0, -1.5px) scale(0.75)",transformOrigin:"top left",maxWidth:"133%"}},{props:({ownerState:e})=>!e.disableAnimation,style:{transition:e.transitions.create(["color","transform","max-width"],{duration:e.transitions.duration.shorter,easing:e.transitions.easing.easeOut})}},{props:{variant:"filled"},style:{zIndex:1,pointerEvents:"none",transform:"translate(12px, 16px) scale(1)",maxWidth:"calc(100% - 24px)"}},{props:{variant:"filled",size:"small"},style:{transform:"translate(12px, 13px) scale(1)"}},{props:({variant:e,ownerState:t})=>"filled"===e&&t.shrink,style:{userSelect:"none",pointerEvents:"auto",transform:"translate(12px, 7px) scale(0.75)",maxWidth:"calc(133% - 24px)"}},{props:({variant:e,ownerState:t,size:g})=>"filled"===e&&t.shrink&&"small"===g,style:{transform:"translate(12px, 4px) scale(0.75)"}},{props:{variant:"outlined"},style:{zIndex:1,pointerEvents:"none",transform:"translate(14px, 16px) scale(1)",maxWidth:"calc(100% - 24px)"}},{props:{variant:"outlined",size:"small"},style:{transform:"translate(14px, 9px) scale(1)"}},{props:({variant:e,ownerState:t})=>"outlined"===e&&t.shrink,style:{userSelect:"none",pointerEvents:"auto",maxWidth:"calc(133% - 32px)",transform:"translate(14px, -9px) scale(0.75)"}}]}))),AI=C.forwardRef(function(e,t){const g=useDefaultProps({name:"MuiInputLabel",props:e}),{disableAnimation:n=!1,margin:C,shrink:o,variant:I,className:a,...i}=g,s=useFormControl();let l=o;void 0===l&&s&&(l=s.filled||s.focused||s.adornedStart);const c=formControlState({props:g,muiFormControl:s,states:["size","variant","required","focused"]}),u={...g,disableAnimation:n,formControl:s,shrink:l,size:c.size,variant:c.variant,required:c.required,focused:c.focused},d=useUtilityClasses$9(u);return Hg.jsx(nI,{"data-shrink":l,ref:t,className:clsx(d.root,a),...i,ownerState:u,classes:d})});function getFormHelperTextUtilityClasses(e){return generateUtilityClass("MuiFormHelperText",e)}const CI=generateUtilityClasses("MuiFormHelperText",["root","error","disabled","sizeSmall","sizeMedium","contained","focused","filled","required"]);var oI;const useUtilityClasses$8=e=>{const{classes:t,contained:g,size:n,disabled:C,error:o,filled:I,focused:a,required:i}=e;return composeClasses({root:["root",C&&"disabled",o&&"error",n&&`size${capitalize(n)}`,g&&"contained",a&&"focused",I&&"filled",i&&"required"]},getFormHelperTextUtilityClasses,t)},II=yn("p",{name:"MuiFormHelperText",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:g}=e;return[t.root,g.size&&t[`size${capitalize(g.size)}`],g.contained&&t.contained,g.filled&&t.filled]}})(Rn(({theme:e})=>({color:(e.vars||e).palette.text.secondary,...e.typography.caption,textAlign:"left",marginTop:3,marginRight:0,marginBottom:0,marginLeft:0,[`&.${CI.disabled}`]:{color:(e.vars||e).palette.text.disabled},[`&.${CI.error}`]:{color:(e.vars||e).palette.error.main},variants:[{props:{size:"small"},style:{marginTop:4}},{props:({ownerState:e})=>e.contained,style:{marginLeft:14,marginRight:14}}]}))),aI=C.forwardRef(function(e,t){const g=useDefaultProps({props:e,name:"MuiFormHelperText"}),{children:n,className:C,component:o="p",disabled:I,error:a,filled:i,focused:s,margin:l,required:c,variant:u,...d}=g,p=formControlState({props:g,muiFormControl:useFormControl(),states:["variant","size","disabled","error","filled","focused","required"]}),m={...g,component:o,contained:"filled"===p.variant||"outlined"===p.variant,variant:p.variant,size:p.size,disabled:p.disabled,error:p.error,filled:p.filled,focused:p.focused,required:p.required};delete m.ownerState;const h=useUtilityClasses$8(m);return Hg.jsx(II,{as:o,className:clsx(h.root,C),ref:t,...d,ownerState:m,children:" "===n?oI||(oI=Hg.jsx("span",{className:"notranslate","aria-hidden":!0,children:"​"})):n})});function getTextFieldUtilityClass(e){return generateUtilityClass("MuiTextField",e)}generateUtilityClasses("MuiTextField",["root"]);const iI={standard:GC,filled:VC,outlined:qC},useUtilityClasses$7=e=>{const{classes:t}=e;return composeClasses({root:["root"]},getTextFieldUtilityClass,t)},sI=yn(Fo,{name:"MuiTextField",slot:"Root"})({}),lI=C.forwardRef(function(e,t){const g=useDefaultProps({props:e,name:"MuiTextField"}),{autoComplete:n,autoFocus:C=!1,children:o,className:I,color:a="primary",defaultValue:i,disabled:s=!1,error:l=!1,FormHelperTextProps:c,fullWidth:u=!1,helperText:d,id:p,InputLabelProps:m,inputProps:h,InputProps:y,inputRef:b,label:v,maxRows:x,minRows:S,multiline:w=!1,name:E,onBlur:R,onChange:M,onFocus:T,placeholder:P,required:N=!1,rows:O,select:D=!1,SelectProps:j,slots:L={},slotProps:G={},type:B,value:F,variant:W="outlined",...V}=g,K={...g,autoFocus:C,color:a,disabled:s,error:l,fullWidth:u,multiline:w,required:N,select:D,variant:W},U=useUtilityClasses$7(K),H=useId(p),Y=d&&H?`${H}-helper-text`:void 0,Z=v&&H?`${H}-label`:void 0,Q=iI[W],X={slots:L,slotProps:{input:y,inputLabel:m,htmlInput:h,formHelperText:c,select:j,...G}},q={},J=X.slotProps.inputLabel;"outlined"===W&&(J&&void 0!==J.shrink&&(q.notched=J.shrink),q.label=v),D&&(j&&j.native||(q.id=void 0),q["aria-describedby"]=void 0);const[$,_]=useSlot("root",{elementType:sI,shouldForwardComponentProp:!0,externalForwardedProps:{...X,...V},ownerState:K,className:clsx(U.root,I),ref:t,additionalProps:{disabled:s,error:l,fullWidth:u,required:N,color:a,variant:W}}),[ee,te]=useSlot("input",{elementType:Q,externalForwardedProps:X,additionalProps:q,ownerState:K}),[ge,re]=useSlot("inputLabel",{elementType:AI,externalForwardedProps:X,ownerState:K}),[ne,Ae]=useSlot("htmlInput",{elementType:"input",externalForwardedProps:X,ownerState:K}),[Ce,oe]=useSlot("formHelperText",{elementType:aI,externalForwardedProps:X,ownerState:K}),[Ie,ae]=useSlot("select",{elementType:to,externalForwardedProps:X,ownerState:K}),ie=Hg.jsx(ee,{"aria-describedby":Y,autoComplete:n,autoFocus:C,defaultValue:i,fullWidth:u,multiline:w,name:E,rows:O,maxRows:x,minRows:S,type:B,value:F,id:H,inputRef:b,onBlur:R,onChange:M,onFocus:T,placeholder:P,inputProps:Ae,slots:{input:L.htmlInput?ne:void 0},...te});return Hg.jsxs($,{..._,children:[null!=v&&""!==v&&Hg.jsx(ge,{htmlFor:H,id:Z,...re,children:v}),D?Hg.jsx(Ie,{"aria-describedby":Y,id:H,labelId:Z,value:F,input:ie,...ae,children:o}):ie,d&&Hg.jsx(Ce,{id:Y,...oe,children:d})]})}),cI=600,uI=400,clampScrollbackGeometryValue=(e,t,g)=>Math.min(Math.max(e,t),g),parseStoredValue=e=>{if("string"!=typeof e)return e;try{return JSON.parse(e)}catch{return e}},hasUsablePersistenceAdapter=e=>"function"==typeof e?.getVariable&&"function"==typeof e?.setVariable,hasSavedGeometry=e=>{if(!hasUsablePersistenceAdapter(e))return!1;const t=e.getVariable(de)||{},g=parseStoredValue(t[pe.UI]);return isPlainObject$1(g?.scrollbackModal)},getScrollbackViewportBounds=()=>"undefined"==typeof window?{width:800,height:600}:{width:Math.max(320,window.innerWidth),height:Math.max(240,window.innerHeight)},getMinimumScrollbackGeometry=()=>{const e=getScrollbackViewportBounds();return{width:Math.min(cI,e.width),height:Math.min(uI,e.height)}},getDefaultScrollbackGeometry=()=>{const e=getScrollbackViewportBounds(),t=getMinimumScrollbackGeometry(),g=clampScrollbackGeometryValue(Math.round(.7*e.width),t.width,e.width),n=clampScrollbackGeometryValue(Math.round(.7*e.height),t.height,e.height);return{x:Math.round((e.width-g)/2),y:Math.round((e.height-n)/2),width:g,height:n}},normalizeScrollbackGeometry=e=>{const t=getDefaultScrollbackGeometry(),g=getScrollbackViewportBounds(),n=getMinimumScrollbackGeometry(),C=clampScrollbackGeometryValue(Number(e?.width)||t.width,n.width,g.width),o=clampScrollbackGeometryValue(Number(e?.height)||t.height,n.height,g.height);return{x:clampScrollbackGeometryValue(Number(e?.x)||0,0,Math.max(0,g.width-C)),y:clampScrollbackGeometryValue(Number(e?.y)||0,0,Math.max(0,g.height-o)),width:C,height:o}},useScrollbackLayout=()=>{const e=t.useContext(jt),g=e?.adapter,n=e?.scrollbackLayoutStore,C=e?.persistenceStore?.getAll?.()?.ui??{},o=t.useMemo(()=>n&&hasSavedGeometry(g)?normalizeScrollbackGeometry(n.get("scrollbackModal")):getDefaultScrollbackGeometry(),[g,n]),I=t.useCallback(e=>{n?.set("scrollbackModal",normalizeScrollbackGeometry(e))},[n]);return{focusHostInput:t.useCallback(()=>{g?.focusInput?.()},[g]),initialGeometry:o,persistGeometry:I,useVirtualizedLogs:Boolean(C.virtualizedLogs)}},dI=.8,useScrollbackHydration=({items:e,open:g,scrollbackSession:n,getViewportElement:C,dispatchViewportScroll:o,setScrollLock:I,onViewportOpened:a})=>{const[i,s]=t.useState([]),[l,c]=t.useState(!1),[u,d]=t.useState(!0),p=t.useRef([]);p.current=i;const m=t.useRef({hasMore:!0,isLoading:!1});m.current={hasMore:u,isLoading:l},t.useEffect(()=>{if(!g)return s([]),void d(!0);s(t=>{if(0===e.length)return[];if(0===t.length)return[...e];const g=t[t.length-1]?.id??-1,n=e.filter(e=>e.id>g);return n.length>0?[...t,...n]:t})},[e,g]);const h=t.useCallback(async()=>{if(!m.current.hasMore||m.current.isLoading)return;const e=p.current[0]?.id;if(void 0===e||e<=0)return m.current={...m.current,hasMore:!1},void d(!1);if(!n?.readRange)return m.current={...m.current,hasMore:!1},void d(!1);m.current={...m.current,isLoading:!0},c(!0);try{const t=Math.max(0,e-M),g=e-1,o=await n.readRange(t,g);if(0===o.length)return m.current={...m.current,hasMore:!1},void d(!1);s(e=>{const t=new Set(e.map(e=>e.id));return[...o.filter(e=>!t.has(e.id)),...e]});const I=C();if(I){const e=I.scrollHeight,t=I.scrollTop;window.requestAnimationFrame(()=>{const g=I.scrollHeight-e;I.scrollTop=t+g})}}catch(t){console.error("[nexGui4] Failed to load older lines",t)}finally{m.current={...m.current,isLoading:!1},c(!1)}},[C,n]);return t.useEffect(()=>{if(!g)return;let e=!0,t=null,n=null;const i=window.requestAnimationFrame(()=>{window.requestAnimationFrame(()=>{if(!e)return;const g=C();if(!g)return;t=g;const i=Math.max(0,g.scrollHeight-g.clientHeight),s=g.clientHeight*dI,l=Math.max(0,i-s);g.scrollTop=l,o(g),I(l<i),a?.(),n=()=>{const{hasMore:e,isLoading:t}=m.current;g.scrollTop<T&&e&&!t&&h()},g.addEventListener("scroll",n,{passive:!0})})});return()=>{e=!1,window.cancelAnimationFrame(i),t&&n&&t.removeEventListener("scroll",n)}},[o,C,h,a,g,I]),{hydratedItems:i,hasMore:u,isLoadingMore:l}},useScrollbackSearch=({scrollbackSession:e,open:g,showPrompts:n,onCursorChange:C})=>{const[o,I]=t.useState(""),[a,i]=t.useState(""),[s,l]=t.useState([]),[c,u]=t.useState(!1),[d,p]=t.useState(-1),m=t.useCallback(()=>{I(""),i(""),p(-1)},[]);t.useEffect(()=>{g||(m(),l([]),u(!1))},[g,m]),t.useEffect(()=>{if(!a)return l([]),void u(!1);let t=!0;return u(!0),(async()=>{try{if(e?.search){const g=await e.search(a,{includePrompts:!0});return void(t&&l(g))}t&&l([])}catch(g){console.error("[nexGui4] Failed searching scrollback session",g)}finally{t&&u(!1)}})(),()=>{t=!1}},[a,e]);const h=t.useMemo(()=>a?n?s:s.filter(e=>!e.isPrompt):[],[a,s,n]),y=h.length;t.useEffect(()=>{g&&a&&0!==y?(p(0),C?.(0)):p(-1)},[a,C,g,y]);const b=t.useCallback(e=>{I(e.target.value)},[]),v=t.useCallback(e=>{if("Enter"!==e.key)return;const t=e.target.value??"";if(t!==a)return void i(t);if(0===y)return;const g=d+1>=y?0:d+1;p(g),C?.(g)},[a,C,d,y]),x=a.length>0,S=x&&o.length>0&&0===y;return{searchBarText:o,setSearchBarText:I,committedSearchTerm:a,searchResults:h,isSearching:c,isSearchActive:x,searchMatchCount:y,searchCursor:d,hasNoMatch:S,searchStatusText:c?"Searching...":S?"No match":y>0&&d>=0?`${d+1}/${y}`:"",resetSearch:m,handleSearchInput:b,handleSearchKeyDown:v}},pI=1500,useScrollbackSelection=({visibleItems:e})=>{const[g,n]=t.useState(null),[C,o]=t.useState(null),[I,a]=t.useState(!1),i=t.useRef({a:null,b:null});i.current={a:g,b:C};const s=t.useCallback(e=>{const{a:t,b:g}=i.current;t===e||g===e?(n(null),o(null)):null===t?n(e):null===g?o(e):(n(e),o(null))},[]),l=t.useMemo(()=>{if(null==g||null==C)return null;const t=Math.min(g,C),n=Math.max(g,C);return e.filter(e=>e.id>=t&&e.id<=n)},[g,C,e]),c=t.useCallback(async()=>{if(!l?.length)return;const e=l.map(e=>stripHtml(e.html)).join("\n");try{await navigator.clipboard.writeText(e),a(!0),window.setTimeout(()=>a(!1),pI)}catch{}},[l]),u=t.useCallback(e=>{const t=e===g||e===C;if(null==g||null==C)return{isEndpoint:t,inRange:!1};const n=Math.min(g,C),o=Math.max(g,C);return{isEndpoint:t,inRange:e>=n&&e<=o}},[g,C]);return{selectionA:g,selectionB:C,selectedRangeItems:l,copyConfirmed:I,handleLineSelect:s,handleCopyRange:c,isLineSelected:u}},mI="nexgui4-log.html",fI="text/html;charset=utf-8",toDate=e=>{if(e instanceof Date)return Number.isNaN(e.getTime())?null:e;if("number"==typeof e&&Number.isFinite(e)){const t=new Date(e);return Number.isNaN(t.getTime())?null:t}return null},formatTimestamp$1=e=>{const t="string"==typeof e&&e.trim().length>0?e:null;if(t)return t;const g=toDate(e)??new Date,pad=(e,t=2)=>String(e).padStart(t,"0");return[pad(g.getHours()),pad(g.getMinutes()),pad(g.getSeconds())].join(":")+`.${pad(g.getMilliseconds(),3)}`},formatLogDate=(e=new Date)=>`${e.getFullYear()}-${e.getMonth()+1}-${e.getDate()}`,resolveCssFontSize$1=e=>null==e?`${le}px`:"number"==typeof e?`${e}px`:String(e),collectPaletteCss=()=>{if("undefined"==typeof document)return"";try{return Array.from(document.getElementById("ng-palette")?.sheet?.cssRules??[]).map(e=>e.cssText).join("\n")}catch{return""}},collectNexGuiStyles=()=>"undefined"==typeof document?"":document.getElementById("nexGuicss")?.outerHTML??"",normalizeLogLine=(e,t)=>({html:String(e?.html??""),id:Number.isFinite(Number(e?.id))&&null!==e?.id?Number(e.id):t,isMonospace:Boolean(e?.isMonospace),isPrompt:Boolean(e?.isPrompt),shouldLog:Boolean(e?.shouldLog),timestamp:formatTimestamp$1(e?.timestamp)}),normalizeLogLines=e=>e.map((e,t)=>normalizeLogLine(e,t)),serializeJsonForInlineScript=e=>JSON.stringify(e).replace(/</g,"\\u003c").replace(/>/g,"\\u003e").replace(/&/g,"\\u0026").replace(/\u2028/g,"\\u2028").replace(/\u2029/g,"\\u2029"),buildLogTitle=e=>e&&String(e).trim().length>0?String(e):`nexGui4 Scrollback - ${formatLogDate()}`,buildBaseStyle=({fontFamily:e,fontSize:t})=>`\n html,\n body {\n background: black;\n color: #ccc;\n margin: 0;\n min-height: 100%;\n }\n\n body {\n box-sizing: border-box;\n font-family: ${e};\n font-size: ${t};\n padding: 12px;\n }\n\n .nexgui4-log-line {\n box-sizing: border-box;\n font-family: ${e};\n font-size: ${t};\n line-height: 1.2;\n overflow-wrap: anywhere;\n white-space: pre-wrap;\n }\n\n .nexgui4-log-line.mono,\n .nexgui4-log-line .mono {\n font-family: ${e};\n }\n\n .nexgui4-log-timestamp {\n color: #555;\n font-family: ${e};\n margin-right: 1ch;\n }\n\n .nexgui4-log-payload {\n min-width: 0;\n }\n`,buildHead=({title:e,fontFamily:t,fontSize:g})=>{const n=collectPaletteCss(),C=collectNexGuiStyles();return`<head>\n <meta charset="utf-8" />\n <title>${escapeHtml(e)}</title>\n <style>\n${buildBaseStyle({fontFamily:t,fontSize:g})}\n </style>\n <style id="ng-palette">${n}</style>\n ${C}\n </head>`},buildLogLineClassName=e=>["nexgui4-log-line",e.isPrompt?"prompt textline":"textline",e.isMonospace?"mono":null].filter(Boolean).join(" "),renderStaticLogRow=e=>`<div class="${buildLogLineClassName(e)}"><span class="nexgui4-log-timestamp timestamp mono no_out">${escapeHtml(e.timestamp)}&nbsp;</span><span class="nexgui4-log-payload">${e.html}</span></div>`,buildStandardHtmlLog=(e,{fontFamily:t=se,fontSize:g,title:n}={})=>{const C=resolveCssFontSize$1(g),o=buildLogTitle(n),I=normalizeLogLines(e).map(renderStaticLogRow).join("\n");return`<!doctype html>\n<html>\n ${buildHead({title:o,fontFamily:t,fontSize:C})}\n <body>\n${I}\n </body>\n</html>`},buildVirtualizedLogScript=(e,t)=>`\n (() => {\n const allLines = ${serializeJsonForInlineScript(e)};\n const viewport = document.getElementById("nexgui4-log-viewport");\n const spacer = document.getElementById("nexgui4-log-spacer");\n const rows = document.getElementById("nexgui4-log-rows");\n const searchInput = document.getElementById("nexgui4-log-search");\n const status = document.getElementById("nexgui4-log-search-status");\n const timestampToggle = document.getElementById("nexgui4-log-timestamps");\n const promptToggle = document.getElementById("nexgui4-log-prompts");\n\n let showTimestamps = true;\n let showPrompts = true;\n let displayLines = allLines;\n let heights = [];\n let offsets = [];\n let searchTerm = "";\n let searchMatches = [];\n let searchIndex = -1;\n let renderFrame = 0;\n const overscan = 8;\n const lineTextCache = new WeakMap();\n const textProbe = document.createElement("div");\n\n const estimate = Math.max(18, ${Math.max(18,t)});\n const escapeText = (value) =>\n String(value ?? "")\n .replaceAll("&", "&amp;")\n .replaceAll("<", "&lt;")\n .replaceAll(">", "&gt;")\n .replaceAll('"', "&quot;")\n .replaceAll("'", "&#39;");\n\n const readLineText = (line) => {\n if (lineTextCache.has(line)) {\n return lineTextCache.get(line);\n }\n\n textProbe.innerHTML = line.html ?? "";\n const text = (textProbe.textContent || "").toLowerCase();\n lineTextCache.set(line, text);\n return text;\n };\n\n const rebuildMetrics = () => {\n offsets = new Array(displayLines.length + 1);\n offsets[0] = 0;\n for (let index = 0; index < displayLines.length; index += 1) {\n offsets[index + 1] = offsets[index] + (heights[index] || estimate);\n }\n spacer.style.height = (offsets[offsets.length - 1] || 0) + "px";\n };\n\n const findIndexAt = (offset) => {\n let low = 0;\n let high = displayLines.length;\n while (low < high) {\n const mid = Math.floor((low + high) / 2);\n if (offsets[mid + 1] < offset) {\n low = mid + 1;\n } else {\n high = mid;\n }\n }\n return low;\n };\n\n const updateStatus = () => {\n if (!searchTerm) {\n status.textContent = "";\n return;\n }\n\n status.textContent = searchMatches.length\n ? "(" + (searchIndex + 1) + " of " + searchMatches.length + ") Line: " + searchMatches[searchIndex]\n : "No entry found";\n };\n\n const classNameForLine = (line) =>\n "nexgui4-log-line " +\n (line.isPrompt ? "prompt textline" : "textline") +\n (line.isMonospace ? " mono" : "");\n\n const render = () => {\n renderFrame = 0;\n const top = viewport.scrollTop;\n const bottom = top + viewport.clientHeight;\n const start = Math.max(0, findIndexAt(top) - overscan);\n const end = Math.min(displayLines.length, findIndexAt(bottom) + overscan + 1);\n const activeDisplayIndex = searchMatches[searchIndex] ?? -1;\n let html = "";\n\n for (let index = start; index < end; index += 1) {\n const line = displayLines[index];\n const timestamp = showTimestamps\n ? '<span class="nexgui4-log-timestamp timestamp mono no_out">' +\n escapeText(line.timestamp) +\n "&nbsp;</span>"\n : "";\n const activeClass = activeDisplayIndex === index ? " nexgui4-log-line--active" : "";\n\n html +=\n '<div class="' +\n classNameForLine(line) +\n activeClass +\n '" data-index="' +\n index +\n '" style="transform:translateY(' +\n offsets[index] +\n 'px)">' +\n timestamp +\n '<span class="nexgui4-log-payload">' +\n line.html +\n "</span></div>";\n }\n\n rows.innerHTML = html;\n window.requestAnimationFrame(measureRenderedRows);\n };\n\n const requestRender = () => {\n if (renderFrame) {\n return;\n }\n\n renderFrame = window.requestAnimationFrame(render);\n };\n\n const measureRenderedRows = () => {\n let changed = false;\n\n rows.querySelectorAll("[data-index]").forEach((row) => {\n const index = Number(row.getAttribute("data-index"));\n const measured = Math.ceil(row.getBoundingClientRect().height);\n\n if (Number.isFinite(index) && measured > 0 && Math.abs((heights[index] || estimate) - measured) > 1) {\n heights[index] = measured;\n changed = true;\n }\n });\n\n if (changed) {\n rebuildMetrics();\n requestRender();\n }\n };\n\n const rebuildDisplayLines = () => {\n displayLines = showPrompts ? allLines : allLines.filter((line) => !line.isPrompt);\n heights = new Array(displayLines.length);\n searchMatches = [];\n searchIndex = -1;\n\n if (searchTerm) {\n searchMatches = displayLines.reduce((matches, line, index) => {\n if (readLineText(line).includes(searchTerm)) {\n matches.push(index);\n }\n return matches;\n }, []);\n searchIndex = searchMatches.length > 0 ? 0 : -1;\n }\n\n rebuildMetrics();\n updateStatus();\n requestRender();\n };\n\n const scrollToActiveSearchMatch = () => {\n if (searchIndex < 0) {\n return;\n }\n\n viewport.scrollTop = Math.max(\n 0,\n offsets[searchMatches[searchIndex]] - viewport.clientHeight / 2,\n );\n requestRender();\n };\n\n const runSearch = () => {\n const nextTerm = searchInput.value.trim().toLowerCase();\n\n if (nextTerm !== searchTerm) {\n searchTerm = nextTerm;\n rebuildDisplayLines();\n } else if (searchMatches.length > 0) {\n searchIndex = (searchIndex + 1) % searchMatches.length;\n updateStatus();\n requestRender();\n }\n\n scrollToActiveSearchMatch();\n };\n\n viewport.addEventListener("scroll", requestRender, { passive: true });\n window.addEventListener("resize", () => {\n heights = new Array(displayLines.length);\n rebuildMetrics();\n requestRender();\n });\n searchInput.addEventListener("keydown", (event) => {\n if (event.key === "Enter") {\n runSearch();\n }\n });\n timestampToggle.addEventListener("change", () => {\n showTimestamps = timestampToggle.checked;\n heights = new Array(displayLines.length);\n rebuildMetrics();\n requestRender();\n });\n promptToggle.addEventListener("change", () => {\n showPrompts = promptToggle.checked;\n rebuildDisplayLines();\n });\n\n rebuildDisplayLines();\n viewport.scrollTop = Math.max(0, spacer.offsetHeight - viewport.clientHeight);\n requestRender();\n })();\n`,buildVirtualizedHtmlLog=(e,{fontFamily:t=se,fontSize:g,title:n}={})=>{const C=resolveCssFontSize$1(g),o=Number.parseFloat(C)||le,I=buildLogTitle(n),a=normalizeLogLines(e);return`<!doctype html>\n<html>\n ${buildHead({title:I,fontFamily:t,fontSize:C})}\n <body class="nexgui4-log-body--virtual">\n <div class="nexgui4-log-toolbar">\n <input id="nexgui4-log-search" aria-label="Search log" placeholder="Search" />\n <span id="nexgui4-log-search-status" aria-live="polite"></span>\n <label><input id="nexgui4-log-timestamps" type="checkbox" checked /> Timestamps</label>\n <label><input id="nexgui4-log-prompts" type="checkbox" checked /> Prompts</label>\n </div>\n <div id="nexgui4-log-viewport" class="nexgui4-log-viewport">\n <div id="nexgui4-log-spacer" class="nexgui4-log-spacer">\n <div id="nexgui4-log-rows" class="nexgui4-log-rows"></div>\n </div>\n </div>\n <style>\n .nexgui4-log-body--virtual {\n height: 100vh;\n overflow: hidden;\n padding: 0;\n }\n\n .nexgui4-log-toolbar {\n align-items: center;\n background: #050505;\n border-bottom: 1px solid #333;\n box-sizing: border-box;\n display: flex;\n gap: 12px;\n height: 42px;\n padding: 6px 10px;\n }\n\n .nexgui4-log-toolbar input[type="text"],\n #nexgui4-log-search {\n background: #111;\n border: 1px solid #444;\n color: #eee;\n font: inherit;\n padding: 4px 6px;\n width: 24ch;\n }\n\n #nexgui4-log-search-status {\n color: #aaa;\n min-width: 18ch;\n }\n\n .nexgui4-log-toolbar label {\n align-items: center;\n display: inline-flex;\n gap: 4px;\n white-space: nowrap;\n }\n\n .nexgui4-log-viewport {\n height: calc(100vh - 42px);\n overflow-y: auto;\n position: relative;\n }\n\n .nexgui4-log-spacer {\n position: relative;\n width: 100%;\n }\n\n .nexgui4-log-rows {\n left: 0;\n position: absolute;\n top: 0;\n width: 100%;\n }\n\n .nexgui4-log-rows .nexgui4-log-line {\n left: 0;\n padding: 0 12px;\n position: absolute;\n top: 0;\n width: 100%;\n }\n\n .nexgui4-log-line--active {\n background: #e5e7eb;\n color: #111827;\n }\n </style>\n <script>\n${buildVirtualizedLogScript(a,1.5*o+26)}\n <\/script>\n </body>\n</html>`},buildHtmlLog=(e,t,g={})=>t?buildVirtualizedHtmlLog(e,g):buildStandardHtmlLog(e,g),downloadBuffer=(e,t,{fontFamily:g=se,fontSize:n,title:C}={})=>{if("undefined"==typeof document||"undefined"==typeof Blob||"undefined"==typeof URL||"function"!=typeof URL.createObjectURL||0===e.length)return;const o=buildHtmlLog(e,t,{fontFamily:g,fontSize:n,title:C}),I=URL.createObjectURL(new Blob([o],{type:fI})),a=document.createElement("a");a.href=I,a.download=mI,a.style.display="none",document.body.append(a),a.click(),a.remove(),URL.revokeObjectURL(I)},useScrollbackDownload=({scrollbackSession:e,visibleItems:g,isSearchActive:n,useVirtualizedLogs:C,fontFamily:o,fontSize:I})=>({handleDownload:t.useCallback(async()=>{let t=g;if(!n&&e?.readAll)try{const g=await e.readAll();g&&g.length>0&&(t=g)}catch(a){console.error("[nexGui4] Failed to read all lines for download",a)}downloadBuffer(t,C,{fontFamily:o,fontSize:I})},[o,I,n,e,C,g])}),hI=12,yI=18,bI={height:"--nexgui4-scrollback-height",width:"--nexgui4-scrollback-width",x:"--nexgui4-scrollback-left",y:"--nexgui4-scrollback-top"},vI=[{direction:"n",sx:{cursor:"n-resize",height:hI,left:yI,right:yI,top:-hI/2}},{direction:"s",sx:{bottom:-hI/2,cursor:"s-resize",height:hI,left:yI,right:yI}},{direction:"e",sx:{bottom:yI,cursor:"e-resize",right:-hI/2,top:yI,width:hI}},{direction:"w",sx:{bottom:yI,cursor:"w-resize",left:-hI/2,top:yI,width:hI}},{direction:"ne",sx:{cursor:"ne-resize",height:yI,right:-hI/2,top:-hI/2,width:yI}},{direction:"nw",sx:{cursor:"nw-resize",height:yI,left:-hI/2,top:-hI/2,width:yI}},{direction:"se",sx:{bottom:-hI/2,cursor:"se-resize",height:yI,right:-hI/2,width:yI}},{direction:"sw",sx:{bottom:-hI/2,cursor:"sw-resize",height:yI,left:-hI/2,width:yI}}],areScrollbackGeometriesEqual=(e,t)=>e?.x===t?.x&&e?.y===t?.y&&e?.width===t?.width&&e?.height===t?.height,getScrollbackPaperGeometryStyle=e=>({[bI.height]:`${e.height}px`,[bI.width]:`${e.width}px`,[bI.x]:`${e.x}px`,[bI.y]:`${e.y}px`}),applyScrollbackPaperGeometry=(e,t)=>{e&&t&&Object.entries(getScrollbackPaperGeometryStyle(t)).forEach(([t,g])=>{e.style.setProperty(t,g)})},useScrollbackGeometry=({initialGeometry:e,persistGeometry:g,contentRef:n})=>{const C=t.useRef(null),o=t.useRef(e),I=t.useRef(e),[a,i]=t.useState(()=>getScrollbackPaperGeometryStyle(e)),s=t.useCallback(()=>C.current??n.current?.closest('[data-testid="scrollback-dialog-paper"]')??n.current?.closest(".MuiDialog-paper")??null,[n]),l=t.useCallback(e=>{const t="function"==typeof e?e(I.current):e,g=normalizeScrollbackGeometry(t);return I.current=g,applyScrollbackPaperGeometry(s(),g),g},[s]),c=t.useCallback(e=>{const t=l(e);return areScrollbackGeometriesEqual(o.current,t)||(o.current=t,i(getScrollbackPaperGeometryStyle(t))),t},[l]),u=t.useCallback((e,t)=>{const n=document.body.style.userSelect;document.body.style.userSelect="none";const handlePointerMove=e=>{t(e)},handlePointerUp=()=>{document.body.style.userSelect=n,document.removeEventListener("pointermove",handlePointerMove),document.removeEventListener("pointerup",handlePointerUp);const e=c(I.current);g(e)};document.addEventListener("pointermove",handlePointerMove),document.addEventListener("pointerup",handlePointerUp),e.currentTarget.setPointerCapture?.(e.pointerId)},[c,g]),d=t.useCallback(e=>{if(0!==e.button)return;e.preventDefault();const t=I.current,g=e.clientX-t.x,n=e.clientY-t.y;u(e,e=>{l({...t,x:e.clientX-g,y:e.clientY-n})})},[l,u]),p=t.useCallback(e=>t=>{if(0!==t.button)return;t.preventDefault(),t.stopPropagation();const g=I.current,n=t.clientX,C=t.clientY,o=g.x+g.width,a=g.y+g.height,i=getMinimumScrollbackGeometry();u(t,t=>{let I=g;if(e.includes("e")&&(I={...I,width:clampScrollbackGeometryValue(g.width+(t.clientX-n),i.width,getScrollbackViewportBounds().width-g.x)}),e.includes("s")&&(I={...I,height:clampScrollbackGeometryValue(g.height+(t.clientY-C),i.height,getScrollbackViewportBounds().height-g.y)}),e.includes("w")){const e=clampScrollbackGeometryValue(g.x+(t.clientX-n),0,o-i.width);I={...I,x:e,width:o-e}}if(e.includes("n")){const e=clampScrollbackGeometryValue(g.y+(t.clientY-C),0,a-i.height);I={...I,y:e,height:a-e}}l(I)})},[l,u]),m=t.useCallback(()=>{c(e=>e)},[c]);return{paperRef:C,paperGeometryStyle:a,handleDragPointerDown:d,handleResizePointerDown:p,reaffirmCommittedGeometry:m}},xI={id:Fg.number.isRequired,html:Fg.string.isRequired,timestamp:Fg.string.isRequired,isPrompt:Fg.bool.isRequired,isMonospace:Fg.bool.isRequired,shouldLog:Fg.bool.isRequired},SI=Fg.exact(xI),buildLineClassName=e=>["nexgui4-virtual-scroll-line",e.isPrompt?"prompt textline":"textline",e.isMonospace?"mono":null,e.shouldLog?"nexguilog":null].filter(Boolean).join(" "),VirtualScrollLineComponent=({fontFamily:e,line:t,isActiveMatch:g=!1,timestampClassName:n,showTimestamp:C=!0})=>React.createElement("div",{className:buildLineClassName(t)},C?React.createElement(Yn,{fontFamily:e,timestamp:t.timestamp,highlight:g,className:n}):null,React.createElement("span",{className:"nexgui4-virtual-scroll-line__payload",dangerouslySetInnerHTML:{__html:t.html}}));VirtualScrollLineComponent.displayName="VirtualScrollLine",VirtualScrollLineComponent.propTypes={fontFamily:Fg.string,isActiveMatch:Fg.bool,line:SI.isRequired,showTimestamp:Fg.bool,timestampClassName:Fg.string};const areVirtualScrollLinePropsEqual=(e,t)=>e.line.id===t.line.id&&e.fontFamily===t.fontFamily&&e.showTimestamp===t.showTimestamp&&e.isActiveMatch===t.isActiveMatch&&e.timestampClassName===t.timestampClassName,wI=t.memo(VirtualScrollLineComponent,areVirtualScrollLinePropsEqual);wI.displayName="VirtualScrollLine",wI.propTypes=VirtualScrollLineComponent.propTypes;const EI=Fg.oneOfType([SI,Fg.oneOf([null])]),PromptLineComponent=({fontFamily:e,promptLine:t=null,show:g=!1,showTimestamp:n=!0,timestampClassName:C})=>g&&t?React.createElement("div",{className:"nexgui4-prompt-line"},React.createElement(wI,{fontFamily:e,line:t,showTimestamp:n,timestampClassName:C})):null;PromptLineComponent.displayName="PromptLine",PromptLineComponent.propTypes={fontFamily:Fg.string,promptLine:EI,show:Fg.bool.isRequired,showTimestamp:Fg.bool,timestampClassName:Fg.string};const RI=t.memo(PromptLineComponent);RI.displayName="PromptLine",RI.propTypes=PromptLineComponent.propTypes;const kI="mixed",MI="single-line",noop$1=()=>{},TI=Fg.oneOfType([SI,Fg.oneOf([null])]),estimateLineSize=(e,t)=>t===MI?Math.ceil(1.25*e):1.5*e+26,VirtualScrollBufferComponent=({items:e,promptLine:g=null,showPromptInline:n=!0,showTimestamp:C=!0,onSendCommand:o=noop$1,fontFamily:I=se,fontSize:a=le,itemKeyVersion:i=null,border:s=!0,onRequestScrollback:l=noop$1,onScrollLockChange:c=noop$1,activeMatchIndex:u=-1,timestampClassName:d,estimateSizeMode:p=kI,overscan:m=5,renderItem:h},y)=>{const b=parseFontSize(a,le),v=t.useCallback(()=>estimateLineSize(b,p),[p,b]),x=t.useCallback((e,t)=>e?.id??t,[]),S=s?null:`${e.length}:${e.at(-1)?.id??""}:${n?"":g?.id??""}`,w=t.useCallback((e,{isActiveMatch:t})=>React.createElement(wI,{fontFamily:I,line:e,isActiveMatch:t,showTimestamp:C,timestampClassName:d}),[I,C,d]);return React.createElement(Hn,{ref:y,activeMatchIndex:u,border:s,displayPinKey:S,estimateSize:v,fontFamily:I,fontSize:a,footer:React.createElement(RI,{fontFamily:I,promptLine:g,show:Boolean(g)&&!n,showTimestamp:C,timestampClassName:d}),getItemKey:x,itemKeyVersion:i,items:e,mode:s?"panel":"display",onRequestHistory:l,onSendCommand:o,onScrollLockChange:c,overscan:m,renderItem:h??w,showScrollLockBadge:s})};VirtualScrollBufferComponent.displayName="VirtualScrollBuffer",VirtualScrollBufferComponent.propTypes={activeMatchIndex:Fg.number,border:Fg.bool,estimateSizeMode:Fg.oneOf([kI,MI]),fontFamily:Fg.string,fontSize:Fg.oneOfType([Fg.number,Fg.string]),itemKeyVersion:Fg.oneOfType([Fg.number,Fg.string]),items:Fg.arrayOf(SI).isRequired,onRequestScrollback:Fg.func,onScrollLockChange:Fg.func,onSendCommand:Fg.func,overscan:Fg.number,promptLine:TI,renderItem:Fg.func,showPromptInline:Fg.bool,showTimestamp:Fg.bool,timestampClassName:Fg.string};const PI=t.forwardRef(VirtualScrollBufferComponent);PI.displayName="VirtualScrollBuffer",PI.propTypes=VirtualScrollBufferComponent.propTypes;const NI=Fg.oneOfType([SI,Fg.oneOf([null])]),noop=()=>{},OI=.8,DI=1,jI=2,zI=48,LI="nexgui4-scrollback-timestamp ng-timestamp timestamp mono no_out",resolveCssFontSize=e=>null==e?`${le}px`:"number"==typeof e?`${e}px`:String(e),getScrollbackWheelDeltaPixels=(e,t)=>{const g=Number(e?.deltaY);if(!Number.isFinite(g)||0===g)return 0;if(e?.deltaMode===DI)return g*zI;if(e?.deltaMode===jI){const e=Number(t?.clientHeight);return g*Math.max(0,Number.isFinite(e)?e:0)*OI}return g},resolveDialogSurfaceBackground=e=>e.nexGui?.tokens?.background?.modal??e.palette.background.paper,resolveModalBackground=e=>e.palette.common.black,resolveHeaderBackground=e=>e.nexGui?.tokens?.background?.header??e.palette.background.default,GI=t.memo(({isEndpoint:e,inRange:t,onClick:g})=>React.createElement(En,{"aria-label":"Select line for copy range",component:"button",onClick:g,sx:g=>({alignSelf:"flex-start",bgcolor:e?g.palette.primary.main:"transparent",borderRadius:"50%",borderStyle:"solid",borderWidth:2,borderColor:e?g.palette.primary.main:g.palette.divider,boxSizing:"border-box",cursor:"pointer",display:"block",flexShrink:0,height:12,lineHeight:1,mr:"6px",mt:"2px",opacity:e?1:t?.6:.25,outline:"none",p:0,transition:"opacity 0.12s, background-color 0.12s, border-color 0.12s",width:12,"&:hover":{borderColor:g.palette.primary.main,opacity:1},"&:focus-visible":{outline:`2px solid ${g.palette.primary.main}`,outlineOffset:2}})}));GI.displayName="SelectionBubble",GI.propTypes={inRange:Fg.bool.isRequired,isEndpoint:Fg.bool.isRequired,onClick:Fg.func.isRequired};const ScrollbackModalDialog=({open:e,onClose:g,items:n,filteredItems:C=n,itemKeyVersion:o=null,scrollbackSession:I=null,promptLine:a=null,onSendCommand:i=noop,fontFamily:s=se,fontSize:l=le,showTimestamp:c=!0})=>{const[u,d]=t.useState(!0),[p,m]=t.useState(c),[h,y]=t.useState(!1),{focusHostInput:b,initialGeometry:v,persistGeometry:x,useVirtualizedLogs:S}=useScrollbackLayout(),w=t.useRef(null),E=t.useRef(null),R=t.useCallback(()=>E.current?.querySelector('[data-testid="virtual-scroll-viewport"]')??null,[]),M=t.useCallback(e=>{e.dispatchEvent(new Event("scroll",{bubbles:!0}))},[]),T=t.useCallback(e=>{const t=R();if(!t)return!1;const g=Math.max(0,t.scrollHeight-t.clientHeight),n=clampScrollbackGeometryValue(t.scrollTop+e,0,g);return t.scrollTop=n,!0},[R]),P=t.useCallback(()=>{const e=R();e?(e.scrollTop=e.scrollHeight,M(e)):w.current?.scrollToBottom?.(),y(!1)},[M,R]),N=t.useCallback(e=>{e<0||(w.current?.scrollToIndex?.(e,{align:"center"}),y(!0))},[]),{hydratedItems:O,isLoadingMore:D}=useScrollbackHydration({items:n,open:e,scrollbackSession:I,getViewportElement:R,dispatchViewportScroll:M,setScrollLock:y}),{paperRef:j,paperGeometryStyle:L,handleDragPointerDown:G,handleResizePointerDown:B,reaffirmCommittedGeometry:F}=useScrollbackGeometry({initialGeometry:v,persistGeometry:x,contentRef:E}),{searchBarText:W,searchResults:V,isSearchActive:K,searchCursor:U,searchStatusText:H,hasNoMatch:Y,resetSearch:Z,handleSearchInput:Q,handleSearchKeyDown:X}=useScrollbackSearch({scrollbackSession:I,open:e,showPrompts:u,onCursorChange:N}),q=t.useMemo(()=>K?V:u?O:O.filter(e=>!e.isPrompt),[O,K,V,u]),J=K?U:-1,$=resolveCssFontSize(l),{selectedRangeItems:_,copyConfirmed:ee,handleLineSelect:te,handleCopyRange:ge,isLineSelected:re}=useScrollbackSelection({visibleItems:q}),{handleDownload:ne}=useScrollbackDownload({scrollbackSession:I,visibleItems:q,isSearchActive:K,useVirtualizedLogs:S,fontFamily:s,fontSize:l}),Ae=t.useCallback((e,{isActiveMatch:t})=>{const{isEndpoint:g,inRange:n}=re(e.id);return React.createElement(En,{sx:e=>({alignItems:"flex-start",bgcolor:n?g?e.palette.action.selected:e.palette.action.hover:void 0,display:"flex"})},React.createElement(GI,{isEndpoint:g,inRange:n,onClick:()=>te(e.id)}),React.createElement(En,{sx:{flex:1,minWidth:0}},React.createElement(wI,{fontFamily:s,isActiveMatch:t,line:e,showTimestamp:p,timestampClassName:LI})))},[s,te,re,p]);t.useEffect(()=>{h||Z()},[Z,h]),t.useEffect(()=>{e?F():y(!1)},[e,F]),t.useEffect(()=>{if(!e)return;const t=R();if(!t)return;const handleWheel=e=>{if(e.ctrlKey)return;const g=getScrollbackWheelDeltaPixels(e,t);0!==g&&(e.preventDefault(),e.stopPropagation(),T(g))};return t.addEventListener("wheel",handleWheel,{passive:!1}),()=>{t.removeEventListener("wheel",handleWheel)}},[R,e,T]),t.useEffect(()=>{if(!e)return;const handleWindowKeyDown=e=>"PageUp"===e.key?(e.preventDefault(),e.stopPropagation(),void T(-(R()?.clientHeight??0)*OI)):"PageDown"===e.key?(e.preventDefault(),e.stopPropagation(),void T((R()?.clientHeight??0)*OI)):void("Escape"===e.key&&(e.preventDefault(),e.stopPropagation(),g(),window.setTimeout(()=>{b()},0)));return window.addEventListener("keydown",handleWindowKeyDown,!0),()=>{window.removeEventListener("keydown",handleWindowKeyDown,!0)}},[b,R,g,e,T]);const Ce=t.useCallback((e,t)=>{d(t)},[]),oe=t.useCallback((e,t)=>{m(t)},[]),Ie=t.useCallback(()=>{P()},[P]),ae=t.useCallback((e,t)=>{"backdropClick"!==t&&(g(),window.setTimeout(()=>{b()},0))},[b,g]),ie=I?.getStats?.(),ce=K?q.length:ie?.searchLineCount??q.length;return React.createElement(Po,{open:e,onClose:ae,disableEnforceFocus:!0,disableAutoFocus:!0,maxWidth:!1,sx:e=>({pointerEvents:"auto",zIndex:e.zIndex.modal+10,"& .MuiDialog-container":{alignItems:"flex-start",justifyContent:"flex-start",pointerEvents:"none"},"& .MuiDialogTitle-root":{cursor:"grab",fontFamily:s,fontSize:$,userSelect:"none"},"& .MuiDialogTitle-root:active":{cursor:"grabbing"},"& .MuiButton-root, & .MuiInputBase-root, & .MuiInputLabel-root":{fontFamily:s,fontSize:$}}),slotProps:{backdrop:{invisible:!0},paper:{"data-testid":"scrollback-dialog-paper",ref:j,style:L,sx:e=>({backgroundImage:"none",backgroundColor:resolveDialogSurfaceBackground(e),border:1,borderColor:"divider",boxShadow:24,color:"text.primary",isolation:"isolate",position:"fixed",pointerEvents:"auto",left:`var(${bI.x})`,top:`var(${bI.y})`,width:`var(${bI.width})`,height:`var(${bI.height})`,m:0,maxWidth:"none",maxHeight:"none",display:"flex",flexDirection:"column",fontFamily:s,fontSize:$,overflow:"hidden",zIndex:e.zIndex.modal+11})}}},React.createElement(Go,{onPointerDown:G,sx:e=>({backgroundColor:resolveHeaderBackground(e),borderBottom:1,borderColor:"divider",backgroundImage:"none",p:1,touchAction:"none"})},"Scrollback Buffer"),React.createElement(zo,{ref:E,sx:e=>({backgroundColor:resolveModalBackground(e),backgroundImage:"none",color:"text.primary",display:"flex",flex:1,minHeight:0,overflow:"hidden",p:0,position:"relative"})},D?React.createElement(En,{sx:{position:"absolute",top:8,left:"50%",transform:"translateX(-50%)",zIndex:10,backgroundColor:"rgba(0, 0, 0, 0.7)",borderRadius:"4px",padding:"4px 8px",display:"flex",alignItems:"center",gap:"8px",color:"primary.main",fontSize:"0.75rem",border:"1px solid",borderColor:"divider"}},React.createElement(co,{size:12,thickness:5}),"Loading history..."):null,React.createElement(PI,{activeMatchIndex:J,border:!0,fontFamily:s,fontSize:l,itemKeyVersion:o,items:q,onSendCommand:i,onScrollLockChange:y,promptLine:a,ref:w,renderItem:Ae,showPromptInline:!0,showTimestamp:p,timestampClassName:LI})),React.createElement(Oo,null,React.createElement(lI,{size:"small",label:"Search",value:W,onInput:Q,onKeyDown:X,error:Y,slotProps:{htmlInput:{"aria-label":"Search scrollback"}},sx:{width:"20ch"}}),H?React.createElement(En,{"aria-live":"polite",component:"div",role:"status",sx:e=>({color:Y?e.palette.error.main:e.palette.text.secondary,fontSize:e.typography.pxToRem(12),lineHeight:1.2,whiteSpace:"nowrap"})},H):null,React.createElement(En,{sx:{flex:1}}),React.createElement(Uo,{control:React.createElement(_o,{checked:u,onChange:Ce,size:"small"}),label:"Show Prompts",sx:{mr:1,userSelect:"none"}}),React.createElement(Uo,{control:React.createElement(_o,{checked:p,onChange:oe,size:"small"}),label:"Show Timestamps",sx:{mr:1,userSelect:"none"}}),null!=_?React.createElement(So,{color:ee?"success":"primary",onClick:ge,size:"small",variant:"outlined"},ee?"Copied!":`Copy (${_.length})`):null,h?React.createElement(So,{onClick:Ie,size:"small",variant:"outlined"},"Bottom"):null,React.createElement(So,{onClick:ne,size:"small",variant:"outlined"},"Download (#",ce,")"),React.createElement(So,{onClick:ae,size:"small"},"Close")),vI.map(e=>React.createElement(En,{component:"span","data-testid":`scrollback-resize-handle-${e.direction}`,key:e.direction,onPointerDown:B(e.direction),sx:{position:"absolute",touchAction:"none",zIndex:2,...e.sx}})))};ScrollbackModalDialog.displayName="ScrollbackModalDialog";const BI={fontFamily:Fg.string,fontSize:Fg.oneOfType([Fg.number,Fg.string]),filteredItems:Fg.arrayOf(SI),itemKeyVersion:Fg.oneOfType([Fg.number,Fg.string]),scrollbackSession:Fg.object,items:Fg.arrayOf(SI).isRequired,onClose:Fg.func.isRequired,onSendCommand:Fg.func,open:Fg.bool.isRequired,promptLine:NI,showTimestamp:Fg.bool};ScrollbackModalDialog.propTypes=BI;const ScrollbackModalComponent=e=>e.open?React.createElement(ScrollbackModalDialog,{...e}):null;ScrollbackModalComponent.displayName="ScrollbackModal",ScrollbackModalComponent.propTypes=BI;const FI=t.memo(ScrollbackModalComponent);FI.displayName="ScrollbackModal",FI.propTypes=ScrollbackModalComponent.propTypes;const identity=e=>e,useHostDisplaySetting=(e=identity,g=Object.is)=>{const{hostDisplaySettingsModel:n}=useNexGui();if(!n||"function"!=typeof n.subscribe||"function"!=typeof n.getSnapshot)throw new Error("useHostDisplaySetting requires NexGuiContext hostDisplaySettingsModel with subscribe(listener) and getSnapshot().");const C=t.useMemo(()=>{let t=e(n.getSnapshot());const getSnapshot=()=>{const C=e(n.getSnapshot());return g(t,C)||(t=C),t},subscribe=C=>n.subscribe(()=>{const o=e(n.getSnapshot());g(t,o)||(t=o,C())});return Object.freeze({getSnapshot,subscribe})},[n,g,e]);return t.useSyncExternalStore(C.subscribe,C.getSnapshot,C.getSnapshot)},useHostDisplaySettings=()=>useHostDisplaySetting(),WI=Object.freeze({}),VI=Object.freeze({}),createHostBridge=e=>Object.freeze({getSettings:()=>e?.getHostSettings?.()??WI,setSetting:(t,g)=>{e?.setHostSetting?.(t,g)},getLayoutSnapshot:()=>e?.getHostLayoutSnapshot?.()??VI,updateLayoutAttributes:t=>{e?.updateHostLayoutAttributes?.(t)},focusInput:()=>{e?.focusInput?.()}}),useHostBridge=()=>{const{adapter:e}=useNexGui();return t.useMemo(()=>createHostBridge(e),[e])},useHostFocus=()=>{const e=useHostBridge();return t.useCallback(()=>{e.focusInput()},[e])},KI=new WeakMap,assertStreamModel=e=>{if(!e||"function"!=typeof e.subscribe||"function"!=typeof e.getSnapshot)throw new Error("useStream requires NexGuiContext streamModel with subscribe(listener) and getSnapshot().")},getStreamModelBindings=e=>{assertStreamModel(e);let t=KI.get(e);if(!t){const subscribe=t=>e.subscribe(t),getSnapshot=()=>e.getSnapshot();t=Object.freeze({subscribe,getSnapshot}),KI.set(e,t)}return t},useStreamSnapshot=()=>{const{streamModel:e}=useNexGui(),{subscribe:g,getSnapshot:n}=getStreamModelBindings(e);return t.useSyncExternalStore(g,n,n)},selectUiSlice=e=>({activeTab:e.activeTab,modalOpen:e.modalOpen,setActiveTab:e.setActiveTab,openModal:e.openModal,closeModal:e.closeModal}),useUi=()=>{const{stores:e}=useNexGui();return e.ui(useShallow(selectUiSlice))},UI="scrollback",HI=100,YI=HI,ZI=HI,getPromptShownTailStartIndex=(e,t,g)=>{const n=Math.max(0,e.length-g);let C=0;for(let o=e.length-1;o>=n;o--)if(!e[o]?.isPrompt&&(C++,C===t))return o;return n},selectMainDisplayLiveTailItems=({allItems:e,filteredItems:t,showPrompts:g,nonPromptLimit:n=YI,totalItemLimit:C=ZI})=>{const o=g?e:t;if(o.length<=n)return o;if(!g)return o.slice(-n);const I=getPromptShownTailStartIndex(o,n,C);return 0===I?o:o.slice(I)},useMainDisplayViewModel=()=>{const{adapter:e,scrollbackSession:g}=useNexGui(),n=useHostFocus(),{showPrompts:C,showTimestamps:o}=useHostDisplaySettings(),{buffer:I,filteredBuffer:a,promptLine:i,version:s}=useStreamSnapshot(),{modalOpen:l,openModal:c,closeModal:u}=useUi(),d=t.useMemo(()=>selectMainDisplayLiveTailItems({allItems:I,filteredItems:a,showPrompts:C}),[I,a,C]),p=C?null:i,m=d.at(-1),h=`${C?"all":"filtered"}:${d.length}:${m?.id??"none"}`,y=t.useCallback(()=>{l!==UI&&c(UI)},[l,c]),b=t.useCallback(()=>{u()},[u]),v=t.useCallback(t=>{e?.send?.(t)},[e]);return{allItems:I,closeScrollback:b,displayItems:d,displayItemKeyVersion:h,displayPromptLine:p,filteredItems:a,focusHostInput:n,openScrollback:y,promptLine:i,scrollbackOpen:l===UI,sendCommand:v,showTimestamps:o,scrollbackItemKeyVersion:s,scrollbackSession:g}},selectThemeSlice=e=>({tokens:e.tokens,updateTokens:e.updateTokens,resetTokens:e.resetTokens}),useTheme=()=>{const{stores:e}=useNexGui(),g=e.theme(useShallow(selectThemeSlice)),n=t.useMemo(()=>createMuiTheme(g.tokens),[g.tokens]);return t.useMemo(()=>({...g,theme:n}),[g,n])},QI="nexgui4-main-display-timestamp ng-timestamp timestamp mono no_out",XI=10,MainDisplayInner=()=>{const e=t.useRef(null),{tokens:g}=useTheme(),{allItems:n,closeScrollback:C,displayItems:o,displayItemKeyVersion:I,displayPromptLine:a,filteredItems:i,focusHostInput:s,openScrollback:l,promptLine:c,scrollbackItemKeyVersion:u,scrollbackOpen:d,scrollbackSession:p,sendCommand:m,showTimestamps:h}=useMainDisplayViewModel(),y=g.theme.displayFontFamily,b=g.theme.displayFontSize,v=t.useCallback(()=>{l()},[l]),x=t.useCallback(()=>{C(),e.current?.scrollToBottom(),s()},[C,s]);return React.createElement(En,{className:"main-display main-display__content",sx:{display:"flex",flex:1,minHeight:0,minWidth:0,overflow:"hidden",position:"relative",width:"100%"}},React.createElement(En,{"data-testid":"main-display-buffer",sx:{display:"flex",flex:1,minHeight:0,position:"relative"}},React.createElement(PI,{ref:e,border:!1,estimateSizeMode:"single-line",fontFamily:y,fontSize:b,itemKeyVersion:I,items:o,onRequestScrollback:v,onSendCommand:m,overscan:XI,promptLine:a,showPromptInline:!1,showTimestamp:h,timestampClassName:QI})),React.createElement(FI,{fontFamily:y,fontSize:b,filteredItems:i,items:n,itemKeyVersion:u,scrollbackSession:p,onClose:x,onSendCommand:m,open:d,promptLine:c,showTimestamp:h}))};MainDisplayInner.displayName="MainDisplayInner";const MainDisplay=()=>React.createElement(Ln,{panelName:"Main Display"},React.createElement(MainDisplayInner,null));function getLinearProgressUtilityClass(e){return generateUtilityClass("MuiLinearProgress",e)}MainDisplay.displayName="MainDisplay",generateUtilityClasses("MuiLinearProgress",["root","colorPrimary","colorSecondary","determinate","indeterminate","buffer","query","dashed","dashedColorPrimary","dashedColorSecondary","bar","bar1","bar2","barColorPrimary","barColorSecondary","bar1Indeterminate","bar1Determinate","bar1Buffer","bar2Indeterminate","bar2Buffer"]);const qI=4,JI=keyframes`
102
+ 0% {
103
+ left: -35%;
104
+ right: 100%;
105
+ }
106
+
107
+ 60% {
108
+ left: 100%;
109
+ right: -90%;
110
+ }
111
+
112
+ 100% {
113
+ left: 100%;
114
+ right: -90%;
115
+ }
116
+ `,$I="string"!=typeof JI?css`
117
+ animation: ${JI} 2.1s cubic-bezier(0.65, 0.815, 0.735, 0.395) infinite;
118
+ `:null,_I=keyframes`
119
+ 0% {
120
+ left: -200%;
121
+ right: 100%;
122
+ }
123
+
124
+ 60% {
125
+ left: 107%;
126
+ right: -8%;
127
+ }
128
+
129
+ 100% {
130
+ left: 107%;
131
+ right: -8%;
132
+ }
133
+ `,ea="string"!=typeof _I?css`
134
+ animation: ${_I} 2.1s cubic-bezier(0.165, 0.84, 0.44, 1) 1.15s infinite;
135
+ `:null,ta=keyframes`
136
+ 0% {
137
+ opacity: 1;
138
+ background-position: 0 -23px;
139
+ }
140
+
141
+ 60% {
142
+ opacity: 0;
143
+ background-position: 0 -23px;
144
+ }
145
+
146
+ 100% {
147
+ opacity: 1;
148
+ background-position: -200px -23px;
149
+ }
150
+ `,ga="string"!=typeof ta?css`
151
+ animation: ${ta} 3s infinite linear;
152
+ `:null,useUtilityClasses$6=e=>{const{classes:t,variant:g,color:n}=e;return composeClasses({root:["root",`color${capitalize(n)}`,g],dashed:["dashed",`dashedColor${capitalize(n)}`],bar1:["bar","bar1",`barColor${capitalize(n)}`,("indeterminate"===g||"query"===g)&&"bar1Indeterminate","determinate"===g&&"bar1Determinate","buffer"===g&&"bar1Buffer"],bar2:["bar","bar2","buffer"!==g&&`barColor${capitalize(n)}`,"buffer"===g&&`color${capitalize(n)}`,("indeterminate"===g||"query"===g)&&"bar2Indeterminate","buffer"===g&&"bar2Buffer"]},getLinearProgressUtilityClass,t)},getColorShade=(e,t)=>e.vars?e.vars.palette.LinearProgress[`${t}Bg`]:"light"===e.palette.mode?e.lighten(e.palette[t].main,.62):e.darken(e.palette[t].main,.5),ra=yn("span",{name:"MuiLinearProgress",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:g}=e;return[t.root,t[`color${capitalize(g.color)}`],t[g.variant]]}})(Rn(({theme:e})=>({position:"relative",overflow:"hidden",display:"block",height:4,zIndex:0,"@media print":{colorAdjust:"exact"},variants:[...Object.entries(e.palette).filter(createSimplePaletteValueFilter()).map(([t])=>({props:{color:t},style:{backgroundColor:getColorShade(e,t)}})),{props:({ownerState:e})=>"inherit"===e.color&&"buffer"!==e.variant,style:{"&::before":{content:'""',position:"absolute",left:0,top:0,right:0,bottom:0,backgroundColor:"currentColor",opacity:.3}}},{props:{variant:"buffer"},style:{backgroundColor:"transparent"}},{props:{variant:"query"},style:{transform:"rotate(180deg)"}}]}))),na=yn("span",{name:"MuiLinearProgress",slot:"Dashed",overridesResolver:(e,t)=>{const{ownerState:g}=e;return[t.dashed,t[`dashedColor${capitalize(g.color)}`]]}})(Rn(({theme:e})=>({position:"absolute",marginTop:0,height:"100%",width:"100%",backgroundSize:"10px 10px",backgroundPosition:"0 -23px",variants:[{props:{color:"inherit"},style:{opacity:.3,backgroundImage:"radial-gradient(currentColor 0%, currentColor 16%, transparent 42%)"}},...Object.entries(e.palette).filter(createSimplePaletteValueFilter()).map(([t])=>{const g=getColorShade(e,t);return{props:{color:t},style:{backgroundImage:`radial-gradient(${g} 0%, ${g} 16%, transparent 42%)`}}})]})),ga||{animation:`${ta} 3s infinite linear`}),Aa=yn("span",{name:"MuiLinearProgress",slot:"Bar1",overridesResolver:(e,t)=>{const{ownerState:g}=e;return[t.bar,t.bar1,t[`barColor${capitalize(g.color)}`],("indeterminate"===g.variant||"query"===g.variant)&&t.bar1Indeterminate,"determinate"===g.variant&&t.bar1Determinate,"buffer"===g.variant&&t.bar1Buffer]}})(Rn(({theme:e})=>({width:"100%",position:"absolute",left:0,bottom:0,top:0,transition:"transform 0.2s linear",transformOrigin:"left",variants:[{props:{color:"inherit"},style:{backgroundColor:"currentColor"}},...Object.entries(e.palette).filter(createSimplePaletteValueFilter()).map(([t])=>({props:{color:t},style:{backgroundColor:(e.vars||e).palette[t].main}})),{props:{variant:"determinate"},style:{transition:`transform .${qI}s linear`}},{props:{variant:"buffer"},style:{zIndex:1,transition:`transform .${qI}s linear`}},{props:({ownerState:e})=>"indeterminate"===e.variant||"query"===e.variant,style:{width:"auto"}},{props:({ownerState:e})=>"indeterminate"===e.variant||"query"===e.variant,style:$I||{animation:`${JI} 2.1s cubic-bezier(0.65, 0.815, 0.735, 0.395) infinite`}}]}))),Ca=yn("span",{name:"MuiLinearProgress",slot:"Bar2",overridesResolver:(e,t)=>{const{ownerState:g}=e;return[t.bar,t.bar2,t[`barColor${capitalize(g.color)}`],("indeterminate"===g.variant||"query"===g.variant)&&t.bar2Indeterminate,"buffer"===g.variant&&t.bar2Buffer]}})(Rn(({theme:e})=>({width:"100%",position:"absolute",left:0,bottom:0,top:0,transition:"transform 0.2s linear",transformOrigin:"left",variants:[...Object.entries(e.palette).filter(createSimplePaletteValueFilter()).map(([t])=>({props:{color:t},style:{"--LinearProgressBar2-barColor":(e.vars||e).palette[t].main}})),{props:({ownerState:e})=>"buffer"!==e.variant&&"inherit"!==e.color,style:{backgroundColor:"var(--LinearProgressBar2-barColor, currentColor)"}},{props:({ownerState:e})=>"buffer"!==e.variant&&"inherit"===e.color,style:{backgroundColor:"currentColor"}},{props:{color:"inherit"},style:{opacity:.3}},...Object.entries(e.palette).filter(createSimplePaletteValueFilter()).map(([t])=>({props:{color:t,variant:"buffer"},style:{backgroundColor:getColorShade(e,t),transition:`transform .${qI}s linear`}})),{props:({ownerState:e})=>"indeterminate"===e.variant||"query"===e.variant,style:{width:"auto"}},{props:({ownerState:e})=>"indeterminate"===e.variant||"query"===e.variant,style:ea||{animation:`${_I} 2.1s cubic-bezier(0.165, 0.84, 0.44, 1) 1.15s infinite`}}]}))),oa=C.forwardRef(function(e,t){const g=useDefaultProps({props:e,name:"MuiLinearProgress"}),{className:n,color:C="primary",value:o,valueBuffer:I,variant:a="indeterminate",...i}=g,s={...g,color:C,variant:a},l=useUtilityClasses$6(s),c=useRtl(),u={},d={bar1:{},bar2:{}};if(("determinate"===a||"buffer"===a)&&void 0!==o){u["aria-valuenow"]=Math.round(o),u["aria-valuemin"]=0,u["aria-valuemax"]=100;let e=o-100;c&&(e=-e),d.bar1.transform=`translateX(${e}%)`}if("buffer"===a&&void 0!==I){let e=(I||0)-100;c&&(e=-e),d.bar2.transform=`translateX(${e}%)`}return Hg.jsxs(ra,{className:clsx(l.root,n),ownerState:s,role:"progressbar",...u,ref:t,...i,children:["buffer"===a?Hg.jsx(na,{className:l.dashed,ownerState:s}):null,Hg.jsx(Aa,{className:l.bar1,ownerState:s,style:d.bar1}),"determinate"===a?null:Hg.jsx(Ca,{className:l.bar2,ownerState:s,style:d.bar2})]})});function getTabUtilityClass(e){return generateUtilityClass("MuiTab",e)}const Ia=generateUtilityClasses("MuiTab",["root","labelIcon","textColorInherit","textColorPrimary","textColorSecondary","selected","disabled","fullWidth","wrapped","iconWrapper","icon"]),useUtilityClasses$5=e=>{const{classes:t,textColor:g,fullWidth:n,wrapped:C,icon:o,label:I,selected:a,disabled:i}=e;return composeClasses({root:["root",o&&I&&"labelIcon",`textColor${capitalize(g)}`,n&&"fullWidth",C&&"wrapped",a&&"selected",i&&"disabled"],icon:["iconWrapper","icon"]},getTabUtilityClass,t)},aa=yn(rC,{name:"MuiTab",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:g}=e;return[t.root,g.label&&g.icon&&t.labelIcon,t[`textColor${capitalize(g.textColor)}`],g.fullWidth&&t.fullWidth,g.wrapped&&t.wrapped,{[`& .${Ia.iconWrapper}`]:t.iconWrapper},{[`& .${Ia.icon}`]:t.icon}]}})(Rn(({theme:e})=>({...e.typography.button,maxWidth:360,minWidth:90,position:"relative",minHeight:48,flexShrink:0,padding:"12px 16px",overflow:"hidden",whiteSpace:"normal",textAlign:"center",lineHeight:1.25,variants:[{props:({ownerState:e})=>e.label&&("top"===e.iconPosition||"bottom"===e.iconPosition),style:{flexDirection:"column"}},{props:({ownerState:e})=>e.label&&"top"!==e.iconPosition&&"bottom"!==e.iconPosition,style:{flexDirection:"row"}},{props:({ownerState:e})=>e.icon&&e.label,style:{minHeight:72,paddingTop:9,paddingBottom:9}},{props:({ownerState:e,iconPosition:t})=>e.icon&&e.label&&"top"===t,style:{[`& > .${Ia.icon}`]:{marginBottom:6}}},{props:({ownerState:e,iconPosition:t})=>e.icon&&e.label&&"bottom"===t,style:{[`& > .${Ia.icon}`]:{marginTop:6}}},{props:({ownerState:e,iconPosition:t})=>e.icon&&e.label&&"start"===t,style:{[`& > .${Ia.icon}`]:{marginRight:e.spacing(1)}}},{props:({ownerState:e,iconPosition:t})=>e.icon&&e.label&&"end"===t,style:{[`& > .${Ia.icon}`]:{marginLeft:e.spacing(1)}}},{props:{textColor:"inherit"},style:{color:"inherit",opacity:.6,[`&.${Ia.selected}`]:{opacity:1},[`&.${Ia.disabled}`]:{opacity:(e.vars||e).palette.action.disabledOpacity}}},{props:{textColor:"primary"},style:{color:(e.vars||e).palette.text.secondary,[`&.${Ia.selected}`]:{color:(e.vars||e).palette.primary.main},[`&.${Ia.disabled}`]:{color:(e.vars||e).palette.text.disabled}}},{props:{textColor:"secondary"},style:{color:(e.vars||e).palette.text.secondary,[`&.${Ia.selected}`]:{color:(e.vars||e).palette.secondary.main},[`&.${Ia.disabled}`]:{color:(e.vars||e).palette.text.disabled}}},{props:({ownerState:e})=>e.fullWidth,style:{flexShrink:1,flexGrow:1,flexBasis:0,maxWidth:"none"}},{props:({ownerState:e})=>e.wrapped,style:{fontSize:e.typography.pxToRem(12)}}]}))),ia=C.forwardRef(function(e,t){const g=useDefaultProps({props:e,name:"MuiTab"}),{className:n,disabled:o=!1,disableFocusRipple:I=!1,fullWidth:a,icon:i,iconPosition:s="top",indicator:l,label:c,onChange:u,onClick:d,onFocus:p,selected:m,selectionFollowsFocus:h,textColor:y="inherit",value:b,wrapped:v=!1,...x}=g,S={...g,disabled:o,disableFocusRipple:I,selected:m,icon:!!i,iconPosition:s,label:!!c,fullWidth:a,textColor:y,wrapped:v},w=useUtilityClasses$5(S),E=i&&c&&C.isValidElement(i)?C.cloneElement(i,{className:clsx(w.icon,i.props.className)}):i,handleClick=e=>{!m&&u&&u(e,b),d&&d(e)},handleFocus=e=>{h&&!m&&u&&u(e,b),p&&p(e)};return Hg.jsxs(aa,{focusRipple:!I,className:clsx(w.root,n),ref:t,role:"tab","aria-selected":m,disabled:o,onClick:handleClick,onFocus:handleFocus,ownerState:S,tabIndex:m?0:-1,...x,children:["top"===s||"start"===s?Hg.jsxs(C.Fragment,{children:[E,c]}):Hg.jsxs(C.Fragment,{children:[c,E]}),l]})});function easeInOutSin(e){return(1+Math.sin(Math.PI*e-Math.PI/2))/2}function animate(e,t,g,n={},C=()=>{}){const{ease:o=easeInOutSin,duration:I=300}=n;let a=null;const i=t[e];let s=!1;const cancel=()=>{s=!0},step=n=>{if(s)return void C(new Error("Animation cancelled"));null===a&&(a=n);const l=Math.min(1,(n-a)/I);t[e]=o(l)*(g-i)+i,l>=1?requestAnimationFrame(()=>{C(null)}):requestAnimationFrame(step)};return i===g?(C(new Error("Element already at target position")),cancel):(requestAnimationFrame(step),cancel)}const sa={width:99,height:99,position:"absolute",top:-9999,overflow:"scroll"};function ScrollbarSize(e){const{onChange:t,...g}=e,n=C.useRef(),o=C.useRef(null),setMeasurements=()=>{n.current=o.current.offsetHeight-o.current.clientHeight};return Dr(()=>{const e=debounce$1(()=>{const e=n.current;setMeasurements(),e!==n.current&&t(n.current)}),g=ownerWindow(o.current);return g.addEventListener("resize",e),()=>{e.clear(),g.removeEventListener("resize",e)}},[t]),C.useEffect(()=>{setMeasurements(),t(n.current)},[t]),Hg.jsx("div",{style:sa,...g,ref:o})}const la=createSvgIcon(Hg.jsx("path",{d:"M15.41 16.09l-4.58-4.59 4.58-4.59L14 5.5l-6 6 6 6z"})),ca=createSvgIcon(Hg.jsx("path",{d:"M8.59 16.34l4.58-4.59-4.58-4.59L10 5.75l6 6-6 6z"}));function getTabScrollButtonUtilityClass(e){return generateUtilityClass("MuiTabScrollButton",e)}const ua=generateUtilityClasses("MuiTabScrollButton",["root","vertical","horizontal","disabled"]),useUtilityClasses$4=e=>{const{classes:t,orientation:g,disabled:n}=e;return composeClasses({root:["root",g,n&&"disabled"]},getTabScrollButtonUtilityClass,t)},da=yn(rC,{name:"MuiTabScrollButton",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:g}=e;return[t.root,g.orientation&&t[g.orientation]]}})({width:40,flexShrink:0,opacity:.8,[`&.${ua.disabled}`]:{opacity:0},variants:[{props:{orientation:"vertical"},style:{width:"100%",height:40,"& svg":{transform:"var(--TabScrollButton-svgRotate)"}}}]}),pa=C.forwardRef(function(e,t){const g=useDefaultProps({props:e,name:"MuiTabScrollButton"}),{className:n,slots:C={},slotProps:o={},direction:I,orientation:a,disabled:i,...s}=g,l=useRtl(),c={isRtl:l,...g},u=useUtilityClasses$4(c),d=C.StartScrollButtonIcon??la,p=C.EndScrollButtonIcon??ca,m=useSlotProps({elementType:d,externalSlotProps:o.startScrollButtonIcon,additionalProps:{fontSize:"small"},ownerState:c}),h=useSlotProps({elementType:p,externalSlotProps:o.endScrollButtonIcon,additionalProps:{fontSize:"small"},ownerState:c});return Hg.jsx(da,{component:"div",className:clsx(u.root,n),ref:t,role:null,ownerState:c,tabIndex:null,...s,style:{...s.style,..."vertical"===a&&{"--TabScrollButton-svgRotate":`rotate(${l?-90:90}deg)`}},children:"left"===I?Hg.jsx(d,{...m}):Hg.jsx(p,{...h})})});function getTabsUtilityClass(e){return generateUtilityClass("MuiTabs",e)}const ma=generateUtilityClasses("MuiTabs",["root","vertical","list","flexContainer","flexContainerVertical","centered","scroller","fixed","scrollableX","scrollableY","hideScrollbar","scrollButtons","scrollButtonsHideMobile","indicator"]),nextItem=(e,t)=>e===t?e.firstChild:t&&t.nextElementSibling?t.nextElementSibling:e.firstChild,previousItem=(e,t)=>e===t?e.lastChild:t&&t.previousElementSibling?t.previousElementSibling:e.lastChild,moveFocus=(e,t,g)=>{let n=!1,C=g(e,t);for(;C;){if(C===e.firstChild){if(n)return;n=!0}const t=C.disabled||"true"===C.getAttribute("aria-disabled");if(C.hasAttribute("tabindex")&&!t)return void C.focus();C=g(e,C)}},useUtilityClasses$3=e=>{const{vertical:t,fixed:g,hideScrollbar:n,scrollableX:C,scrollableY:o,centered:I,scrollButtonsHideMobile:a,classes:i}=e;return composeClasses({root:["root",t&&"vertical"],scroller:["scroller",g&&"fixed",n&&"hideScrollbar",C&&"scrollableX",o&&"scrollableY"],list:["list","flexContainer",t&&"flexContainerVertical",t&&"vertical",I&&"centered"],indicator:["indicator"],scrollButtons:["scrollButtons",a&&"scrollButtonsHideMobile"],scrollableX:[C&&"scrollableX"],hideScrollbar:[n&&"hideScrollbar"]},getTabsUtilityClass,i)},fa=yn("div",{name:"MuiTabs",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:g}=e;return[{[`& .${ma.scrollButtons}`]:t.scrollButtons},{[`& .${ma.scrollButtons}`]:g.scrollButtonsHideMobile&&t.scrollButtonsHideMobile},t.root,g.vertical&&t.vertical]}})(Rn(({theme:e})=>({overflow:"hidden",minHeight:48,WebkitOverflowScrolling:"touch",display:"flex",variants:[{props:({ownerState:e})=>e.vertical,style:{flexDirection:"column"}},{props:({ownerState:e})=>e.scrollButtonsHideMobile,style:{[`& .${ma.scrollButtons}`]:{[e.breakpoints.down("sm")]:{display:"none"}}}}]}))),ha=yn("div",{name:"MuiTabs",slot:"Scroller",overridesResolver:(e,t)=>{const{ownerState:g}=e;return[t.scroller,g.fixed&&t.fixed,g.hideScrollbar&&t.hideScrollbar,g.scrollableX&&t.scrollableX,g.scrollableY&&t.scrollableY]}})({position:"relative",display:"inline-block",flex:"1 1 auto",whiteSpace:"nowrap",variants:[{props:({ownerState:e})=>e.fixed,style:{overflowX:"hidden",width:"100%"}},{props:({ownerState:e})=>e.hideScrollbar,style:{scrollbarWidth:"none","&::-webkit-scrollbar":{display:"none"}}},{props:({ownerState:e})=>e.scrollableX,style:{overflowX:"auto",overflowY:"hidden"}},{props:({ownerState:e})=>e.scrollableY,style:{overflowY:"auto",overflowX:"hidden"}}]}),ya=yn("div",{name:"MuiTabs",slot:"List",overridesResolver:(e,t)=>{const{ownerState:g}=e;return[t.list,t.flexContainer,g.vertical&&t.flexContainerVertical,g.centered&&t.centered]}})({display:"flex",variants:[{props:({ownerState:e})=>e.vertical,style:{flexDirection:"column"}},{props:({ownerState:e})=>e.centered,style:{justifyContent:"center"}}]}),ba=yn("span",{name:"MuiTabs",slot:"Indicator"})(Rn(({theme:e})=>({position:"absolute",height:2,bottom:0,width:"100%",transition:e.transitions.create(),variants:[{props:{indicatorColor:"primary"},style:{backgroundColor:(e.vars||e).palette.primary.main}},{props:{indicatorColor:"secondary"},style:{backgroundColor:(e.vars||e).palette.secondary.main}},{props:({ownerState:e})=>e.vertical,style:{height:"100%",width:2,right:0}}]}))),va=yn(ScrollbarSize)({overflowX:"auto",overflowY:"hidden",scrollbarWidth:"none","&::-webkit-scrollbar":{display:"none"}}),xa={},Sa=C.forwardRef(function(e,t){const g=useDefaultProps({props:e,name:"MuiTabs"}),n=useTheme$1(),o=useRtl(),{"aria-label":I,"aria-labelledby":a,action:i,centered:s=!1,children:l,className:c,component:u="div",allowScrollButtonsMobile:d=!1,indicatorColor:p="primary",onChange:m,orientation:h="horizontal",ScrollButtonComponent:y,scrollButtons:b="auto",selectionFollowsFocus:v,slots:x={},slotProps:S={},TabIndicatorProps:w={},TabScrollButtonProps:E={},textColor:R="primary",value:M,variant:T="standard",visibleScrollbar:P=!1,...N}=g,O="scrollable"===T,D="vertical"===h,j=D?"scrollTop":"scrollLeft",L=D?"top":"left",G=D?"bottom":"right",B=D?"clientHeight":"clientWidth",F=D?"height":"width",W={...g,component:u,allowScrollButtonsMobile:d,indicatorColor:p,orientation:h,vertical:D,scrollButtons:b,textColor:R,variant:T,visibleScrollbar:P,fixed:!O,hideScrollbar:O&&!P,scrollableX:O&&!D,scrollableY:O&&D,centered:s&&!O,scrollButtonsHideMobile:!d},V=useUtilityClasses$3(W),K=useSlotProps({elementType:x.StartScrollButtonIcon,externalSlotProps:S.startScrollButtonIcon,ownerState:W}),U=useSlotProps({elementType:x.EndScrollButtonIcon,externalSlotProps:S.endScrollButtonIcon,ownerState:W}),[H,Y]=C.useState(!1),[Z,Q]=C.useState(xa),[X,q]=C.useState(!1),[J,$]=C.useState(!1),[_,ee]=C.useState(!1),[te,ge]=C.useState({overflow:"hidden",scrollbarWidth:0}),re=new Map,ne=C.useRef(null),Ae=C.useRef(null),Ce={slots:x,slotProps:{indicator:w,scrollButtons:E,...S}},getTabsMeta=()=>{const e=ne.current;let t,g;if(e){const g=e.getBoundingClientRect();t={clientWidth:e.clientWidth,scrollLeft:e.scrollLeft,scrollTop:e.scrollTop,scrollWidth:e.scrollWidth,top:g.top,bottom:g.bottom,left:g.left,right:g.right}}if(e&&!1!==M){const e=Ae.current.children;if(e.length>0){const t=e[re.get(M)];g=t?t.getBoundingClientRect():null}}return{tabsMeta:t,tabMeta:g}},oe=useEventCallback(()=>{const{tabsMeta:e,tabMeta:t}=getTabsMeta();let g,n=0;D?(g="top",t&&e&&(n=t.top-e.top+e.scrollTop)):(g=o?"right":"left",t&&e&&(n=(o?-1:1)*(t[g]-e[g]+e.scrollLeft)));const C={[g]:n,[F]:t?t[F]:0};if("number"!=typeof Z[g]||"number"!=typeof Z[F])Q(C);else{const e=Math.abs(Z[g]-C[g]),t=Math.abs(Z[F]-C[F]);(e>=1||t>=1)&&Q(C)}}),scroll=(e,{animation:t=!0}={})=>{t?animate(j,ne.current,e,{duration:n.transitions.duration.standard}):ne.current[j]=e},moveTabsScroll=e=>{let t=ne.current[j];t+=D?e:e*(o?-1:1),scroll(t)},getScrollSize=()=>{const e=ne.current[B];let t=0;const g=Array.from(Ae.current.children);for(let n=0;n<g.length;n+=1){const C=g[n];if(t+C[B]>e){0===n&&(t=e);break}t+=C[B]}return t},handleStartScrollClick=()=>{moveTabsScroll(-1*getScrollSize())},handleEndScrollClick=()=>{moveTabsScroll(getScrollSize())},[Ie,{onChange:ae,...ie}]=useSlot("scrollbar",{className:clsx(V.scrollableX,V.hideScrollbar),elementType:va,shouldForwardComponentProp:!0,externalForwardedProps:Ce,ownerState:W}),se=C.useCallback(e=>{ae?.(e),ge({overflow:null,scrollbarWidth:e})},[ae]),[le,ce]=useSlot("scrollButtons",{className:clsx(V.scrollButtons,E.className),elementType:pa,externalForwardedProps:Ce,ownerState:W,additionalProps:{orientation:h,slots:{StartScrollButtonIcon:x.startScrollButtonIcon||x.StartScrollButtonIcon,EndScrollButtonIcon:x.endScrollButtonIcon||x.EndScrollButtonIcon},slotProps:{startScrollButtonIcon:K,endScrollButtonIcon:U}}}),getConditionalElements=()=>{const e={};e.scrollbarSizeListener=O?Hg.jsx(Ie,{...ie,onChange:se}):null;const t=O&&("auto"===b&&(X||J)||!0===b);return e.scrollButtonStart=t?Hg.jsx(le,{direction:o?"right":"left",onClick:handleStartScrollClick,disabled:!X,...ce}):null,e.scrollButtonEnd=t?Hg.jsx(le,{direction:o?"left":"right",onClick:handleEndScrollClick,disabled:!J,...ce}):null,e},ue=useEventCallback(e=>{const{tabsMeta:t,tabMeta:g}=getTabsMeta();if(g&&t)if(g[L]<t[L]){const n=t[j]+(g[L]-t[L]);scroll(n,{animation:e})}else if(g[G]>t[G]){const n=t[j]+(g[G]-t[G]);scroll(n,{animation:e})}}),de=useEventCallback(()=>{O&&!1!==b&&ee(!_)});C.useEffect(()=>{const e=debounce$1(()=>{ne.current&&oe()});let t;const handleMutation=g=>{g.forEach(e=>{e.removedNodes.forEach(e=>{t?.unobserve(e)}),e.addedNodes.forEach(e=>{t?.observe(e)})}),e(),de()},g=ownerWindow(ne.current);let n;return g.addEventListener("resize",e),"undefined"!=typeof ResizeObserver&&(t=new ResizeObserver(e),Array.from(Ae.current.children).forEach(e=>{t.observe(e)})),"undefined"!=typeof MutationObserver&&(n=new MutationObserver(handleMutation),n.observe(Ae.current,{childList:!0})),()=>{e.clear(),g.removeEventListener("resize",e),n?.disconnect(),t?.disconnect()}},[oe,de]),C.useEffect(()=>{const e=Array.from(Ae.current.children),t=e.length;if("undefined"!=typeof IntersectionObserver&&t>0&&O&&!1!==b){const g=e[0],n=e[t-1],C={root:ne.current,threshold:.99},o=new IntersectionObserver(e=>{q(!e[0].isIntersecting)},C);o.observe(g);const I=new IntersectionObserver(e=>{$(!e[0].isIntersecting)},C);return I.observe(n),()=>{o.disconnect(),I.disconnect()}}},[O,b,_,l?.length]),C.useEffect(()=>{Y(!0)},[]),C.useEffect(()=>{oe()}),C.useEffect(()=>{ue(xa!==Z)},[ue,Z]),C.useImperativeHandle(i,()=>({updateIndicator:oe,updateScrollButtons:de}),[oe,de]);const[pe,me]=useSlot("indicator",{className:clsx(V.indicator,w.className),elementType:ba,externalForwardedProps:Ce,ownerState:W,additionalProps:{style:Z}}),fe=Hg.jsx(pe,{...me});let he=0;const ye=C.Children.map(l,e=>{if(!C.isValidElement(e))return null;const t=void 0===e.props.value?he:e.props.value;re.set(t,he);const g=t===M;return he+=1,C.cloneElement(e,{fullWidth:"fullWidth"===T,indicator:g&&!H&&fe,selected:g,selectionFollowsFocus:v,onChange:m,textColor:R,value:t,...1!==he||!1!==M||e.props.tabIndex?{}:{tabIndex:0}})}),handleKeyDown=e=>{if(e.altKey||e.shiftKey||e.ctrlKey||e.metaKey)return;const t=Ae.current,g=activeElement(ownerDocument(t)),n=g?.getAttribute("role");if("tab"!==n)return;let C="horizontal"===h?"ArrowLeft":"ArrowUp",I="horizontal"===h?"ArrowRight":"ArrowDown";switch("horizontal"===h&&o&&(C="ArrowRight",I="ArrowLeft"),e.key){case C:e.preventDefault(),moveFocus(t,g,previousItem);break;case I:e.preventDefault(),moveFocus(t,g,nextItem);break;case"Home":e.preventDefault(),moveFocus(t,null,nextItem);break;case"End":e.preventDefault(),moveFocus(t,null,previousItem)}},be=getConditionalElements(),[ve,xe]=useSlot("root",{ref:t,className:clsx(V.root,c),elementType:fa,externalForwardedProps:{...Ce,...N,component:u},ownerState:W}),[Se,we]=useSlot("scroller",{ref:ne,className:V.scroller,elementType:ha,externalForwardedProps:Ce,ownerState:W,additionalProps:{style:{overflow:te.overflow,[D?"margin"+(o?"Left":"Right"):"marginBottom"]:P?void 0:-te.scrollbarWidth}}}),[Ee,Re]=useSlot("list",{ref:Ae,className:clsx(V.list,V.flexContainer),elementType:ya,externalForwardedProps:Ce,ownerState:W,getSlotProps:e=>({...e,onKeyDown:t=>{handleKeyDown(t),e.onKeyDown?.(t)}})});return Hg.jsxs(ve,{...xe,children:[be.scrollButtonStart,be.scrollbarSizeListener,Hg.jsxs(Se,{...we,children:[Hg.jsx(Ee,{"aria-label":I,"aria-labelledby":a,"aria-orientation":"vertical"===h?"vertical":null,role:"tablist",...Re,children:ye}),H&&fe]}),be.scrollButtonEnd]})}),selectPlayStatsSlice=e=>({instance:e.instance,session:e.session,month:e.month,updateInstance:e.updateInstance,updateSession:e.updateSession,updateMonth:e.updateMonth,resetInstance:e.resetInstance}),usePlayStats=()=>{const{stores:e}=useNexGui();return e.playStats(useShallow(selectPlayStatsSlice))},wa="metrics",Ea=Object.freeze(["instance","session","month"]),Ra=Object.freeze({instance:"Instance",session:"Session",month:"Month"}),ka=1e3,Ma=35e4,Ta=45e4,getFlipTransform$7=e=>{switch(e){case 1:return"scaleX(-1) scaleY(-1)";case 2:return"scaleY(-1)";case 3:return"scaleX(-1)";default:return"none"}},formatNumber$1=e=>e.toLocaleString("en-US"),formatPercent=e=>`${e.toFixed(2)}%`,formatElapsed=(e,t=Date.now())=>{const g=Math.max(0,t-e),n=Math.floor(g/1e3),C=Math.floor(n/3600),o=Math.floor(n%3600/60);return[C>0?`${C}h`:null,C>0||o>0?`${o}m`:null,n%60+"s"].filter(Boolean).join(" ")},formatPerHour=(e,t,g=Date.now())=>{const n=Math.max(0,g-t)/36e5,C=parseInt(e/n,10);return C>0?formatNumber$1(C):"0"},resolveActiveTabId$2=e=>"string"==typeof e&&Ea.includes(e)?e:"number"==typeof e?Ea[e]??"month":"month",Pa={kills:Fg.number.isRequired,goldGained:Fg.number.isRequired,xpPercent:Fg.number.isRequired,xpValue:Fg.number.isRequired,deaths:Fg.number.isRequired,startedAt:Fg.number.isRequired},Na=Fg.shape(Pa),Oa=Fg.shape({...Pa,goldCap:Fg.number.isRequired,year:Fg.number,month:Fg.number}),StatTable=({rows:e})=>React.createElement(En,{component:"table",sx:{borderCollapse:"collapse","& td":{pb:.5,pr:2,verticalAlign:"top"},"& td:last-of-type":{fontVariantNumeric:"tabular-nums"}}},React.createElement("tbody",null,e.map((e,t)=>React.createElement("tr",{key:`${e.label}-${t}`},React.createElement("td",null,e.label),React.createElement("td",null,e.value)))));StatTable.displayName="MetricsPanelStatTable",StatTable.propTypes={rows:Fg.arrayOf(Fg.shape({label:Fg.string.isRequired,value:Fg.node.isRequired})).isRequired};const LinearProgressWithLabel=({label:e,value:t})=>React.createElement(En,{sx:{mt:2}},React.createElement(En,{sx:{fontSize:"9px",mb:.25}},e),React.createElement(En,{sx:{alignItems:"center",display:"flex"}},React.createElement(En,{sx:{mr:1,width:"100%"}},React.createElement(oa,{"aria-label":e,sx:{borderRadius:5,height:5},value:t,variant:"determinate"})),React.createElement(En,{sx:{minWidth:35}},React.createElement(zn,{color:"text.secondary",variant:"body2"},`${t}%`))));LinearProgressWithLabel.displayName="MetricsPanelLinearProgressWithLabel",LinearProgressWithLabel.propTypes={label:Fg.string.isRequired,value:Fg.number.isRequired};const MonthGoldCap=({goldCap:e})=>React.createElement(En,{sx:{mt:1}},React.createElement(LinearProgressWithLabel,{label:"Soft Gold Cap",value:e<=Ma?parseInt(e/Ma*100,10):100}),React.createElement(LinearProgressWithLabel,{label:"Hard Gold Cap",value:e<=Ta?parseInt(e/Ta*100,10):100}));MonthGoldCap.displayName="MetricsPanelMonthGoldCap",MonthGoldCap.propTypes={goldCap:Fg.number.isRequired};const ScopeContent=({now:e,onReset:g,scope:n,scopeKey:C})=>{const o=t.useMemo(()=>{const t=[{label:"Total Kills:",value:formatNumber$1(n.kills)},{label:"Total Gold:",value:formatNumber$1(n.goldGained)},{label:"Total XP:",value:formatPercent(n.xpPercent)},{label:"Total XP:",value:formatNumber$1(n.xpValue)},{label:"Total Deaths:",value:formatNumber$1(n.deaths)}];return"month"!==C?[...t,{label:"Time:",value:formatElapsed(n.startedAt,e)},{label:"XP/Hr:",value:formatPerHour(n.xpValue,n.startedAt,e)},{label:"Gold/Hr:",value:formatPerHour(n.goldGained,n.startedAt,e)}]:[...t,{label:"Gold Cap:",value:formatNumber$1(n.goldCap)}]},[e,n,C]);return React.createElement(En,null,React.createElement(StatTable,{rows:o}),"instance"===C?React.createElement(So,{onClick:g,sx:{mt:1},variant:"outlined"},"Reset"):null,"month"===C?React.createElement(MonthGoldCap,{goldCap:n.goldCap}):null)};ScopeContent.displayName="MetricsPanelScopeContent",ScopeContent.propTypes={now:Fg.number.isRequired,onReset:Fg.func.isRequired,scope:Fg.oneOfType([Na,Oa]).isRequired,scopeKey:Fg.oneOf(["instance","session","month"]).isRequired};const MetricsPanelInner=()=>{const e=useTheme$1(),{activeTab:g,setActiveTab:n}=useUi(),{instance:C,session:o,month:I,resetInstance:a}=usePlayStats(),[i]=t.useState(()=>Math.floor(4*Math.random())),[s,l]=t.useState(()=>Date.now()),c=e?.nexGui?.backgroundImage??"",u=e?.nexGui?.backgroundOpacity??.5,d=e?.nexGui?.backgroundFilter??"none",p=resolveActiveTabId$2(g[wa]),m={instance:C,session:o,month:I};t.useEffect(()=>{if("month"===p)return void l(Date.now());l(Date.now());const e=window.setInterval(()=>{l(Date.now())},ka);return()=>{window.clearInterval(e)}},[p]);const handleTabChange=(e,t)=>{const g=Ea.indexOf(t);g>=0&&n(wa,g)};return React.createElement(En,{className:"metrics-panel",sx:{color:"text.primary",height:"100%",overflow:"hidden",position:"relative",width:"100%"}},c?React.createElement(En,{"aria-hidden":"true",className:"metrics-panel__background",sx:{backgroundImage:`url(${c})`,backgroundPosition:"center",backgroundSize:"cover",filter:d,inset:0,opacity:u,position:"absolute",transform:getFlipTransform$7(i),zIndex:0}}):null,React.createElement(En,{className:"metrics-panel__content",sx:{display:"flex",flexDirection:"column",fontFamily:e.typography.fontFamily,fontSize:e.nexusFontSize??e.typography.fontSize,height:"100%",position:"relative",width:"100%",zIndex:1}},React.createElement(En,{sx:{borderBottom:1,borderColor:"divider"}},React.createElement(Sa,{"aria-label":"stats tabs",onChange:handleTabChange,value:p},Ea.map(e=>React.createElement(ia,{key:e,label:Ra[e],value:e})))),React.createElement(En,{sx:{flex:1,overflowY:"auto",p:2}},React.createElement(zn,{component:"div",sx:{color:"text.primary",fontFamily:"inherit",fontSize:"inherit",position:"relative"}},React.createElement(ScopeContent,{now:s,onReset:a,scope:m[p],scopeKey:p})))))};MetricsPanelInner.displayName="MetricsPanelInner";const MetricsPanel=()=>React.createElement(Ln,{panelName:"Metrics"},React.createElement(MetricsPanelInner,null));MetricsPanel.displayName="MetricsPanel";const Da={id:Fg.oneOfType([Fg.number,Fg.string]).isRequired,name:Fg.string.isRequired},ja=Fg.shape(Da),RoomNpcRowComponent=({indent:e=0,interactive:t=!1,isTarget:g=!1,npc:n,onContextMenu:C,onSelect:o})=>{const I=e>0?e:0,a=e>0?e:2;return React.createElement(En,{className:["room-npc-row",t?"room-npc-row--interactive":"",g?"room-npc-row--target":""].filter(Boolean).join(" "),onClick:t?()=>o?.(n):void 0,onContextMenu:t?e=>{C?.(e,n)}:void 0,sx:{cursor:t?"pointer":"inherit",display:"table-row",outline:g?"1px solid red":""}},React.createElement(En,{component:"div",sx:{color:"cyan",display:"table-cell",padding:`0px 5px 0px ${a}px`,whiteSpace:"nowrap"}},React.createElement(zn,{component:"span",sx:{color:"inherit",fontVariantNumeric:"tabular-nums"},variant:"body2"},n.id)),React.createElement(En,{component:"div",sx:{display:"table-cell",padding:`0px 5px 0px ${I}px`,width:"100%"}},React.createElement(zn,{component:"span",sx:{color:"text.primary"},variant:"body2"},n.name)))};RoomNpcRowComponent.displayName="RoomNpcRow",RoomNpcRowComponent.propTypes={npc:ja.isRequired,indent:Fg.number,interactive:Fg.bool,isTarget:Fg.bool,onContextMenu:Fg.func,onSelect:Fg.func};const za=t.memo(RoomNpcRowComponent);za.displayName="RoomNpcRow",za.propTypes=RoomNpcRowComponent.propTypes;const selectCharacterSlice=e=>({name:e.name,class:e.class,level:e.level,target:e.target,targetDetails:e.targetDetails,gender:e.gender,balance:e.balance,equilibrium:e.equilibrium,currentAffs:e.currentAffs,limbs:e.limbs,updateCharacter:e.updateCharacter,setClass:e.setClass,setTarget:e.setTarget}),useCharacter=()=>{const{stores:e}=useNexGui();return e.character(useShallow(selectCharacterSlice))},La=[/a dervish/,/a sharp-toothed gremlin/,/a chaos orb/,/a bloodleech/,/a minion of chaos/,/a worm/,/a green slime/,/a soulmaster/,/a humbug/,/a chimera/,/a bubonis/,/a chaos storm/,/a chaos hound/,/a withered crone/,/a pathfinder/,/a doppleganger/,/an ethereal firelord/,/a simpering sycophant/,/a water weird/,/an eldritch abomination/,/Khaseem/],Ga=[/a shipmate/,/a spectral shipmate/],Ba=[/a swarthy swashbuckler/],Fa=new Set(["guard","person-military-pointing"]),Wa=new Set(["face-angry-horns","fiend","monster"]),Va=new Set(["humanoid","person"]),getFlipTransform$6=e=>{switch(e){case 1:return"scaleX(-1) scaleY(-1)";case 2:return"scaleY(-1)";case 3:return"scaleX(-1)";default:return"none"}},partition=(e,t)=>e.reduce((e,g,n,C)=>(t(g,n,C)?e[0].push(g):e[1].push(g),e),[[],[]]),toNpcEntry=e=>e&&"object"==typeof e&&"string"==typeof e.name?{...e,id:e.id??e.name}:"string"==typeof e?{attrib:"m",id:e,name:e}:null,matchesPatternList=(e,t)=>"string"==typeof e&&t.some(t=>t.test(e)),isVisibleNpc=e=>"m"===e?.attrib||"mx"===e?.attrib,isGuardNpc=e=>Fa.has(e?.icon??"")&&"mx"===e?.attrib,isEntityNpc=e=>Wa.has(e?.icon??"")&&matchesPatternList(e?.name,La),isShipmateNpc=e=>matchesPatternList(e?.name,Ga),isSwashbucklerNpc=e=>Va.has(e?.icon??"")&&matchesPatternList(e?.name,Ba),NpcGroupHeader=({count:e,expanded:t,onToggle:g,title:n})=>e<1?null:React.createElement(En,{className:"npcs-panel__group-header",onClick:g,sx:{cursor:"pointer",display:"table-row"}},React.createElement(En,{component:"div",sx:{color:"cyan",display:"table-cell",fontFamily:"monospace",padding:"0px 5px 0px 0px",pl:"1rem",whiteSpace:"nowrap"}},React.createElement(zn,{component:"span",sx:{color:"inherit",fontFamily:"inherit"},variant:"body2"},t?"-":"+ ")),React.createElement(En,{component:"div",sx:{display:"table-cell"}},React.createElement(zn,{component:"span",sx:{color:"text.primary"},variant:"body2"},"(",e,") ",n)));NpcGroupHeader.displayName="NpcGroupHeader",NpcGroupHeader.propTypes={count:Fg.number.isRequired,expanded:Fg.bool.isRequired,onToggle:Fg.func.isRequired,title:Fg.string.isRequired};const NpcsPanelInner=()=>{const e=useTheme$1(),{adapter:g}=useNexGui(),{npcs:n}=useRoom(),{target:C,targetDetails:o}=useCharacter(),[I]=t.useState(()=>Math.floor(4*Math.random())),[a,i]=t.useState(!1),[s,l]=t.useState(!1),[c,u]=t.useState(!1),[d,p]=t.useState(!1),m=e?.nexGui?.backgroundImage??"",h=e?.nexGui?.backgroundOpacity??.5,y=e?.nexGui?.backgroundFilter??"none",b=null!=o?.id?String(o.id):null,v=t.useMemo(()=>(n??[]).map(e=>toNpcEntry(e)).filter(Boolean),[n]),x=t.useMemo(()=>{let e=[],t=[],g=[],n=[],C=v;return[e,C]=partition(C,isGuardNpc),[t,C]=partition(C,isEntityNpc),[g,C]=partition(C,isShipmateNpc),[n,C]=partition(C,isSwashbucklerNpc),{guards:e,entities:t,shipmates:g,swashbucklers:n,npcs:C.filter(isVisibleNpc)}},[v]),handleNpcSelect=e=>{null!=e?.id&&g.send(`settarget ${e.id}`)},handleNpcContextMenu=e=>{e.preventDefault(),g.notice?.("RIGHT CLICK RIGHT CLICK RIGHT CLICK")};return React.createElement(En,{className:"npcs-panel",sx:{height:"100%",overflow:"hidden",position:"relative",width:"100%"}},m?React.createElement(En,{"aria-hidden":"true",className:"npcs-panel__background",sx:{backgroundImage:`url(${m})`,backgroundPosition:"center",backgroundSize:"cover",filter:y,inset:0,opacity:h,position:"absolute",transform:getFlipTransform$6(I),zIndex:0}}):null,React.createElement(En,{className:"npcs-panel__content",sx:{background:`linear-gradient(180deg, ${alpha("#050505",.18)} 0%, ${alpha("#050505",.36)} 100%)`,color:"text.primary",height:"100%",overflow:"auto",position:"relative",width:"100%",zIndex:1}},React.createElement(En,{className:"npcs-panel__rows",sx:{cursor:"pointer",display:"table",fontSize:e.typography.fontSize,m:"10px",maxWidth:"100%",p:"1px",position:"relative",textAlign:"left"}},React.createElement(NpcGroupHeader,{count:x.guards.length,expanded:s,onToggle:()=>l(e=>!e),title:"City Guards"}),s?x.guards.map(e=>React.createElement(za,{key:`guard-${e.id}`,indent:12,npc:e})):null,React.createElement(NpcGroupHeader,{count:x.entities.length,expanded:a,onToggle:()=>i(e=>!e),title:"Entities"}),a?x.entities.map(e=>React.createElement(za,{key:`entity-${e.id}`,indent:12,npc:e})):null,React.createElement(NpcGroupHeader,{count:x.shipmates.length,expanded:c,onToggle:()=>u(e=>!e),title:"Shipmates"}),c?x.shipmates.map(e=>React.createElement(za,{key:`shipmate-${e.id}`,indent:12,npc:e})):null,React.createElement(NpcGroupHeader,{count:x.swashbucklers.length,expanded:d,onToggle:()=>p(e=>!e),title:"Swashbucklers"}),d?x.swashbucklers.map(e=>React.createElement(za,{key:`swashbuckler-${e.id}`,indent:12,npc:e})):null,x.npcs.map(e=>React.createElement(za,{key:`npc-${e.id}`,interactive:!0,isTarget:b?String(e.id)===b:e.name===C,npc:e,onContextMenu:handleNpcContextMenu,onSelect:handleNpcSelect})))))};NpcsPanelInner.displayName="NpcsPanelInner";const NpcsPanel=()=>React.createElement(Ln,{panelName:"NPCs"},React.createElement(NpcsPanelInner,null));NpcsPanel.displayName="NpcsPanel";const Ka=Object.freeze([]),Ua=Fg.shape({content:Fg.node,id:Fg.string.isRequired,label:Fg.node.isRequired}),resolveActiveTabId$1=(e,t)=>e.some(e=>e.id===t)?t:e[0]?.id??!1,getFlipTransform$5=e=>{switch(e){case 1:return"scaleX(-1) scaleY(-1)";case 2:return"scaleY(-1)";case 3:return"scaleX(-1)";default:return"none"}},TabContainerComponent=({tabs:e=Ka,activeTab:g=null,backgroundImage:n="",backgroundOpacity:C=.5,backgroundFilter:o="none",onTabChange:I})=>{const[a]=t.useState(()=>Math.floor(4*Math.random())),i=resolveActiveTabId$1(e,g),s=e.find(e=>e.id===i)??null;return 0===e.length?null:React.createElement(En,{className:"nexgui4-tab-container",sx:{display:"flex",flex:1,flexDirection:"column",height:"100%",minHeight:0,minWidth:0,overflow:"hidden",position:"relative",width:"100%"}},n?React.createElement(En,{"aria-hidden":"true",className:"nexgui4-tab-container__background",sx:{backgroundImage:`url(${n})`,backgroundPosition:"center",backgroundSize:"cover",filter:o,inset:0,opacity:C,position:"absolute",transform:getFlipTransform$5(a),zIndex:0}}):null,React.createElement(En,{className:"nexgui4-tab-container__surface",sx:{display:"flex",flex:1,flexDirection:"column",minHeight:0,minWidth:0,position:"relative",zIndex:1}},React.createElement(Sa,{allowScrollButtonsMobile:!0,"aria-label":"Panel tabs",className:"nexgui4-tab-container__tabs",onChange:(e,t)=>I(t),scrollButtons:"auto",sx:{borderBottom:1,borderColor:"divider",minHeight:40,"& .MuiTab-root":{minHeight:40,textTransform:"none"}},value:i,variant:"scrollable"},e.map(e=>React.createElement(ia,{"aria-controls":`nexgui4-tab-panel-${e.id}`,id:`nexgui4-tab-${e.id}`,key:e.id,label:e.label,value:e.id}))),React.createElement(En,{"aria-labelledby":s?`nexgui4-tab-${s.id}`:void 0,className:"nexgui4-tab-container__tabpanel",id:s?`nexgui4-tab-panel-${s.id}`:void 0,role:"tabpanel",sx:{display:"flex",flex:1,minHeight:0,minWidth:0,overflow:"auto",p:2,position:"relative",zIndex:1}},s?.content??null)))};TabContainerComponent.displayName="TabContainer",TabContainerComponent.propTypes={activeTab:Fg.oneOfType([Fg.string,Fg.oneOf([null])]),backgroundFilter:Fg.string,backgroundImage:Fg.string,backgroundOpacity:Fg.number,onTabChange:Fg.func.isRequired,tabs:Fg.arrayOf(Ua)};const Ha=t.memo(TabContainerComponent);Ha.displayName="TabContainer",Ha.propTypes=TabContainerComponent.propTypes;var Ya="top",Za="bottom",Qa="right",Xa="left",qa="auto",Ja=[Ya,Za,Qa,Xa],$a="start",_a="end",ei="clippingParents",ti="viewport",gi="popper",ri="reference",ni=Ja.reduce(function(e,t){return e.concat([t+"-"+$a,t+"-"+_a])},[]),Ai=[].concat(Ja,[qa]).reduce(function(e,t){return e.concat([t,t+"-"+$a,t+"-"+_a])},[]),Ci=["beforeRead","read","afterRead","beforeMain","main","afterMain","beforeWrite","write","afterWrite"];function getNodeName(e){return e?(e.nodeName||"").toLowerCase():null}function getWindow(e){if(null==e)return window;if("[object Window]"!==e.toString()){var t=e.ownerDocument;return t&&t.defaultView||window}return e}function isElement(e){return e instanceof getWindow(e).Element||e instanceof Element}function isHTMLElement$1(e){return e instanceof getWindow(e).HTMLElement||e instanceof HTMLElement}function isShadowRoot(e){return"undefined"!=typeof ShadowRoot&&(e instanceof getWindow(e).ShadowRoot||e instanceof ShadowRoot)}function applyStyles(e){var t=e.state;Object.keys(t.elements).forEach(function(e){var g=t.styles[e]||{},n=t.attributes[e]||{},C=t.elements[e];isHTMLElement$1(C)&&getNodeName(C)&&(Object.assign(C.style,g),Object.keys(n).forEach(function(e){var t=n[e];!1===t?C.removeAttribute(e):C.setAttribute(e,!0===t?"":t)}))})}function effect$2(e){var t=e.state,g={popper:{position:t.options.strategy,left:"0",top:"0",margin:"0"},arrow:{position:"absolute"},reference:{}};return Object.assign(t.elements.popper.style,g.popper),t.styles=g,t.elements.arrow&&Object.assign(t.elements.arrow.style,g.arrow),function(){Object.keys(t.elements).forEach(function(e){var n=t.elements[e],C=t.attributes[e]||{},o=Object.keys(t.styles.hasOwnProperty(e)?t.styles[e]:g[e]).reduce(function(e,t){return e[t]="",e},{});isHTMLElement$1(n)&&getNodeName(n)&&(Object.assign(n.style,o),Object.keys(C).forEach(function(e){n.removeAttribute(e)}))})}}const oi={name:"applyStyles",enabled:!0,phase:"write",fn:applyStyles,effect:effect$2,requires:["computeStyles"]};function getBasePlacement(e){return e.split("-")[0]}var Ii=Math.max,ai=Math.min,ii=Math.round;function getUAString(){var e=navigator.userAgentData;return null!=e&&e.brands&&Array.isArray(e.brands)?e.brands.map(function(e){return e.brand+"/"+e.version}).join(" "):navigator.userAgent}function isLayoutViewport(){return!/^((?!chrome|android).)*safari/i.test(getUAString())}function getBoundingClientRect(e,t,g){void 0===t&&(t=!1),void 0===g&&(g=!1);var n=e.getBoundingClientRect(),C=1,o=1;t&&isHTMLElement$1(e)&&(C=e.offsetWidth>0&&ii(n.width)/e.offsetWidth||1,o=e.offsetHeight>0&&ii(n.height)/e.offsetHeight||1);var I=(isElement(e)?getWindow(e):window).visualViewport,a=!isLayoutViewport()&&g,i=(n.left+(a&&I?I.offsetLeft:0))/C,s=(n.top+(a&&I?I.offsetTop:0))/o,l=n.width/C,c=n.height/o;return{width:l,height:c,top:s,right:i+l,bottom:s+c,left:i,x:i,y:s}}function getLayoutRect(e){var t=getBoundingClientRect(e),g=e.offsetWidth,n=e.offsetHeight;return Math.abs(t.width-g)<=1&&(g=t.width),Math.abs(t.height-n)<=1&&(n=t.height),{x:e.offsetLeft,y:e.offsetTop,width:g,height:n}}function contains(e,t){var g=t.getRootNode&&t.getRootNode();if(e.contains(t))return!0;if(g&&isShadowRoot(g)){var n=t;do{if(n&&e.isSameNode(n))return!0;n=n.parentNode||n.host}while(n)}return!1}function getComputedStyle(e){return getWindow(e).getComputedStyle(e)}function isTableElement(e){return["table","td","th"].indexOf(getNodeName(e))>=0}function getDocumentElement(e){return((isElement(e)?e.ownerDocument:e.document)||window.document).documentElement}function getParentNode(e){return"html"===getNodeName(e)?e:e.assignedSlot||e.parentNode||(isShadowRoot(e)?e.host:null)||getDocumentElement(e)}function getTrueOffsetParent(e){return isHTMLElement$1(e)&&"fixed"!==getComputedStyle(e).position?e.offsetParent:null}function getContainingBlock(e){var t=/firefox/i.test(getUAString());if(/Trident/i.test(getUAString())&&isHTMLElement$1(e)&&"fixed"===getComputedStyle(e).position)return null;var g=getParentNode(e);for(isShadowRoot(g)&&(g=g.host);isHTMLElement$1(g)&&["html","body"].indexOf(getNodeName(g))<0;){var n=getComputedStyle(g);if("none"!==n.transform||"none"!==n.perspective||"paint"===n.contain||-1!==["transform","perspective"].indexOf(n.willChange)||t&&"filter"===n.willChange||t&&n.filter&&"none"!==n.filter)return g;g=g.parentNode}return null}function getOffsetParent(e){for(var t=getWindow(e),g=getTrueOffsetParent(e);g&&isTableElement(g)&&"static"===getComputedStyle(g).position;)g=getTrueOffsetParent(g);return g&&("html"===getNodeName(g)||"body"===getNodeName(g)&&"static"===getComputedStyle(g).position)?t:g||getContainingBlock(e)||t}function getMainAxisFromPlacement(e){return["top","bottom"].indexOf(e)>=0?"x":"y"}function within(e,t,g){return Ii(e,ai(t,g))}function withinMaxClamp(e,t,g){var n=within(e,t,g);return n>g?g:n}function getFreshSideObject(){return{top:0,right:0,bottom:0,left:0}}function mergePaddingObject(e){return Object.assign({},getFreshSideObject(),e)}function expandToHashMap(e,t){return t.reduce(function(t,g){return t[g]=e,t},{})}var toPaddingObject=function(e,t){return mergePaddingObject("number"!=typeof(e="function"==typeof e?e(Object.assign({},t.rects,{placement:t.placement})):e)?e:expandToHashMap(e,Ja))};function arrow(e){var t,g=e.state,n=e.name,C=e.options,o=g.elements.arrow,I=g.modifiersData.popperOffsets,a=getBasePlacement(g.placement),i=getMainAxisFromPlacement(a),s=[Xa,Qa].indexOf(a)>=0?"height":"width";if(o&&I){var l=toPaddingObject(C.padding,g),c=getLayoutRect(o),u="y"===i?Ya:Xa,d="y"===i?Za:Qa,p=g.rects.reference[s]+g.rects.reference[i]-I[i]-g.rects.popper[s],m=I[i]-g.rects.reference[i],h=getOffsetParent(o),y=h?"y"===i?h.clientHeight||0:h.clientWidth||0:0,b=p/2-m/2,v=l[u],x=y-c[s]-l[d],S=y/2-c[s]/2+b,w=within(v,S,x),E=i;g.modifiersData[n]=((t={})[E]=w,t.centerOffset=w-S,t)}}function effect$1(e){var t=e.state,g=e.options.element,n=void 0===g?"[data-popper-arrow]":g;null!=n&&("string"!=typeof n||(n=t.elements.popper.querySelector(n)))&&contains(t.elements.popper,n)&&(t.elements.arrow=n)}function getVariation(e){return e.split("-")[1]}var si={top:"auto",right:"auto",bottom:"auto",left:"auto"};function roundOffsetsByDPR(e,t){var g=e.x,n=e.y,C=t.devicePixelRatio||1;return{x:ii(g*C)/C||0,y:ii(n*C)/C||0}}function mapToStyles(e){var t,g=e.popper,n=e.popperRect,C=e.placement,o=e.variation,I=e.offsets,a=e.position,i=e.gpuAcceleration,s=e.adaptive,l=e.roundOffsets,c=e.isFixed,u=I.x,d=void 0===u?0:u,p=I.y,m=void 0===p?0:p,h="function"==typeof l?l({x:d,y:m}):{x:d,y:m};d=h.x,m=h.y;var y=I.hasOwnProperty("x"),b=I.hasOwnProperty("y"),v=Xa,x=Ya,S=window;if(s){var w=getOffsetParent(g),E="clientHeight",R="clientWidth";w===getWindow(g)&&"static"!==getComputedStyle(w=getDocumentElement(g)).position&&"absolute"===a&&(E="scrollHeight",R="scrollWidth"),(C===Ya||(C===Xa||C===Qa)&&o===_a)&&(x=Za,m-=(c&&w===S&&S.visualViewport?S.visualViewport.height:w[E])-n.height,m*=i?1:-1),C!==Xa&&(C!==Ya&&C!==Za||o!==_a)||(v=Qa,d-=(c&&w===S&&S.visualViewport?S.visualViewport.width:w[R])-n.width,d*=i?1:-1)}var M,T=Object.assign({position:a},s&&si),P=!0===l?roundOffsetsByDPR({x:d,y:m},getWindow(g)):{x:d,y:m};return d=P.x,m=P.y,i?Object.assign({},T,((M={})[x]=b?"0":"",M[v]=y?"0":"",M.transform=(S.devicePixelRatio||1)<=1?"translate("+d+"px, "+m+"px)":"translate3d("+d+"px, "+m+"px, 0)",M)):Object.assign({},T,((t={})[x]=b?m+"px":"",t[v]=y?d+"px":"",t.transform="",t))}function computeStyles(e){var t=e.state,g=e.options,n=g.gpuAcceleration,C=void 0===n||n,o=g.adaptive,I=void 0===o||o,a=g.roundOffsets,i=void 0===a||a,s={placement:getBasePlacement(t.placement),variation:getVariation(t.placement),popper:t.elements.popper,popperRect:t.rects.popper,gpuAcceleration:C,isFixed:"fixed"===t.options.strategy};null!=t.modifiersData.popperOffsets&&(t.styles.popper=Object.assign({},t.styles.popper,mapToStyles(Object.assign({},s,{offsets:t.modifiersData.popperOffsets,position:t.options.strategy,adaptive:I,roundOffsets:i})))),null!=t.modifiersData.arrow&&(t.styles.arrow=Object.assign({},t.styles.arrow,mapToStyles(Object.assign({},s,{offsets:t.modifiersData.arrow,position:"absolute",adaptive:!1,roundOffsets:i})))),t.attributes.popper=Object.assign({},t.attributes.popper,{"data-popper-placement":t.placement})}var li={passive:!0};function effect(e){var t=e.state,g=e.instance,n=e.options,C=n.scroll,o=void 0===C||C,I=n.resize,a=void 0===I||I,i=getWindow(t.elements.popper),s=[].concat(t.scrollParents.reference,t.scrollParents.popper);return o&&s.forEach(function(e){e.addEventListener("scroll",g.update,li)}),a&&i.addEventListener("resize",g.update,li),function(){o&&s.forEach(function(e){e.removeEventListener("scroll",g.update,li)}),a&&i.removeEventListener("resize",g.update,li)}}var ci={left:"right",right:"left",bottom:"top",top:"bottom"};function getOppositePlacement(e){return e.replace(/left|right|bottom|top/g,function(e){return ci[e]})}var ui={start:"end",end:"start"};function getOppositeVariationPlacement(e){return e.replace(/start|end/g,function(e){return ui[e]})}function getWindowScroll(e){var t=getWindow(e);return{scrollLeft:t.pageXOffset,scrollTop:t.pageYOffset}}function getWindowScrollBarX(e){return getBoundingClientRect(getDocumentElement(e)).left+getWindowScroll(e).scrollLeft}function getViewportRect(e,t){var g=getWindow(e),n=getDocumentElement(e),C=g.visualViewport,o=n.clientWidth,I=n.clientHeight,a=0,i=0;if(C){o=C.width,I=C.height;var s=isLayoutViewport();(s||!s&&"fixed"===t)&&(a=C.offsetLeft,i=C.offsetTop)}return{width:o,height:I,x:a+getWindowScrollBarX(e),y:i}}function getDocumentRect(e){var t,g=getDocumentElement(e),n=getWindowScroll(e),C=null==(t=e.ownerDocument)?void 0:t.body,o=Ii(g.scrollWidth,g.clientWidth,C?C.scrollWidth:0,C?C.clientWidth:0),I=Ii(g.scrollHeight,g.clientHeight,C?C.scrollHeight:0,C?C.clientHeight:0),a=-n.scrollLeft+getWindowScrollBarX(e),i=-n.scrollTop;return"rtl"===getComputedStyle(C||g).direction&&(a+=Ii(g.clientWidth,C?C.clientWidth:0)-o),{width:o,height:I,x:a,y:i}}function isScrollParent(e){var t=getComputedStyle(e),g=t.overflow,n=t.overflowX,C=t.overflowY;return/auto|scroll|overlay|hidden/.test(g+C+n)}function getScrollParent(e){return["html","body","#document"].indexOf(getNodeName(e))>=0?e.ownerDocument.body:isHTMLElement$1(e)&&isScrollParent(e)?e:getScrollParent(getParentNode(e))}function listScrollParents(e,t){var g;void 0===t&&(t=[]);var n=getScrollParent(e),C=n===(null==(g=e.ownerDocument)?void 0:g.body),o=getWindow(n),I=C?[o].concat(o.visualViewport||[],isScrollParent(n)?n:[]):n,a=t.concat(I);return C?a:a.concat(listScrollParents(getParentNode(I)))}function rectToClientRect(e){return Object.assign({},e,{left:e.x,top:e.y,right:e.x+e.width,bottom:e.y+e.height})}function getInnerBoundingClientRect(e,t){var g=getBoundingClientRect(e,!1,"fixed"===t);return g.top=g.top+e.clientTop,g.left=g.left+e.clientLeft,g.bottom=g.top+e.clientHeight,g.right=g.left+e.clientWidth,g.width=e.clientWidth,g.height=e.clientHeight,g.x=g.left,g.y=g.top,g}function getClientRectFromMixedType(e,t,g){return t===ti?rectToClientRect(getViewportRect(e,g)):isElement(t)?getInnerBoundingClientRect(t,g):rectToClientRect(getDocumentRect(getDocumentElement(e)))}function getClippingParents(e){var t=listScrollParents(getParentNode(e)),g=["absolute","fixed"].indexOf(getComputedStyle(e).position)>=0&&isHTMLElement$1(e)?getOffsetParent(e):e;return isElement(g)?t.filter(function(e){return isElement(e)&&contains(e,g)&&"body"!==getNodeName(e)}):[]}function getClippingRect(e,t,g,n){var C="clippingParents"===t?getClippingParents(e):[].concat(t),o=[].concat(C,[g]),I=o[0],a=o.reduce(function(t,g){var C=getClientRectFromMixedType(e,g,n);return t.top=Ii(C.top,t.top),t.right=ai(C.right,t.right),t.bottom=ai(C.bottom,t.bottom),t.left=Ii(C.left,t.left),t},getClientRectFromMixedType(e,I,n));return a.width=a.right-a.left,a.height=a.bottom-a.top,a.x=a.left,a.y=a.top,a}function computeOffsets(e){var t,g=e.reference,n=e.element,C=e.placement,o=C?getBasePlacement(C):null,I=C?getVariation(C):null,a=g.x+g.width/2-n.width/2,i=g.y+g.height/2-n.height/2;switch(o){case Ya:t={x:a,y:g.y-n.height};break;case Za:t={x:a,y:g.y+g.height};break;case Qa:t={x:g.x+g.width,y:i};break;case Xa:t={x:g.x-n.width,y:i};break;default:t={x:g.x,y:g.y}}var s=o?getMainAxisFromPlacement(o):null;if(null!=s){var l="y"===s?"height":"width";switch(I){case $a:t[s]=t[s]-(g[l]/2-n[l]/2);break;case _a:t[s]=t[s]+(g[l]/2-n[l]/2)}}return t}function detectOverflow(e,t){void 0===t&&(t={});var g=t,n=g.placement,C=void 0===n?e.placement:n,o=g.strategy,I=void 0===o?e.strategy:o,a=g.boundary,i=void 0===a?ei:a,s=g.rootBoundary,l=void 0===s?ti:s,c=g.elementContext,u=void 0===c?gi:c,d=g.altBoundary,p=void 0!==d&&d,m=g.padding,h=void 0===m?0:m,y=mergePaddingObject("number"!=typeof h?h:expandToHashMap(h,Ja)),b=u===gi?ri:gi,v=e.rects.popper,x=e.elements[p?b:u],S=getClippingRect(isElement(x)?x:x.contextElement||getDocumentElement(e.elements.popper),i,l,I),w=getBoundingClientRect(e.elements.reference),E=computeOffsets({reference:w,element:v,placement:C}),R=rectToClientRect(Object.assign({},v,E)),M=u===gi?R:w,T={top:S.top-M.top+y.top,bottom:M.bottom-S.bottom+y.bottom,left:S.left-M.left+y.left,right:M.right-S.right+y.right},P=e.modifiersData.offset;if(u===gi&&P){var N=P[C];Object.keys(T).forEach(function(e){var t=[Qa,Za].indexOf(e)>=0?1:-1,g=[Ya,Za].indexOf(e)>=0?"y":"x";T[e]+=N[g]*t})}return T}function computeAutoPlacement(e,t){void 0===t&&(t={});var g=t,n=g.placement,C=g.boundary,o=g.rootBoundary,I=g.padding,a=g.flipVariations,i=g.allowedAutoPlacements,s=void 0===i?Ai:i,l=getVariation(n),c=l?a?ni:ni.filter(function(e){return getVariation(e)===l}):Ja,u=c.filter(function(e){return s.indexOf(e)>=0});0===u.length&&(u=c);var d=u.reduce(function(t,g){return t[g]=detectOverflow(e,{placement:g,boundary:C,rootBoundary:o,padding:I})[getBasePlacement(g)],t},{});return Object.keys(d).sort(function(e,t){return d[e]-d[t]})}function getExpandedFallbackPlacements(e){if(getBasePlacement(e)===qa)return[];var t=getOppositePlacement(e);return[getOppositeVariationPlacement(e),t,getOppositeVariationPlacement(t)]}function flip(e){var t=e.state,g=e.options,n=e.name;if(!t.modifiersData[n]._skip){for(var C=g.mainAxis,o=void 0===C||C,I=g.altAxis,a=void 0===I||I,i=g.fallbackPlacements,s=g.padding,l=g.boundary,c=g.rootBoundary,u=g.altBoundary,d=g.flipVariations,p=void 0===d||d,m=g.allowedAutoPlacements,h=t.options.placement,y=getBasePlacement(h),b=i||(y!==h&&p?getExpandedFallbackPlacements(h):[getOppositePlacement(h)]),v=[h].concat(b).reduce(function(e,g){return e.concat(getBasePlacement(g)===qa?computeAutoPlacement(t,{placement:g,boundary:l,rootBoundary:c,padding:s,flipVariations:p,allowedAutoPlacements:m}):g)},[]),x=t.rects.reference,S=t.rects.popper,w=new Map,E=!0,R=v[0],M=0;M<v.length;M++){var T=v[M],P=getBasePlacement(T),N=getVariation(T)===$a,O=[Ya,Za].indexOf(P)>=0,D=O?"width":"height",j=detectOverflow(t,{placement:T,boundary:l,rootBoundary:c,altBoundary:u,padding:s}),L=O?N?Qa:Xa:N?Za:Ya;x[D]>S[D]&&(L=getOppositePlacement(L));var G=getOppositePlacement(L),B=[];if(o&&B.push(j[P]<=0),a&&B.push(j[L]<=0,j[G]<=0),B.every(function(e){return e})){R=T,E=!1;break}w.set(T,B)}if(E)for(var _loop=function(e){var t=v.find(function(t){var g=w.get(t);if(g)return g.slice(0,e).every(function(e){return e})});if(t)return R=t,"break"},F=p?3:1;F>0&&"break"!==_loop(F);F--);t.placement!==R&&(t.modifiersData[n]._skip=!0,t.placement=R,t.reset=!0)}}function getSideOffsets(e,t,g){return void 0===g&&(g={x:0,y:0}),{top:e.top-t.height-g.y,right:e.right-t.width+g.x,bottom:e.bottom-t.height+g.y,left:e.left-t.width-g.x}}function isAnySideFullyClipped(e){return[Ya,Qa,Za,Xa].some(function(t){return e[t]>=0})}function hide(e){var t=e.state,g=e.name,n=t.rects.reference,C=t.rects.popper,o=t.modifiersData.preventOverflow,I=detectOverflow(t,{elementContext:"reference"}),a=detectOverflow(t,{altBoundary:!0}),i=getSideOffsets(I,n),s=getSideOffsets(a,C,o),l=isAnySideFullyClipped(i),c=isAnySideFullyClipped(s);t.modifiersData[g]={referenceClippingOffsets:i,popperEscapeOffsets:s,isReferenceHidden:l,hasPopperEscaped:c},t.attributes.popper=Object.assign({},t.attributes.popper,{"data-popper-reference-hidden":l,"data-popper-escaped":c})}function distanceAndSkiddingToXY(e,t,g){var n=getBasePlacement(e),C=[Xa,Ya].indexOf(n)>=0?-1:1,o="function"==typeof g?g(Object.assign({},t,{placement:e})):g,I=o[0],a=o[1];return I=I||0,a=(a||0)*C,[Xa,Qa].indexOf(n)>=0?{x:a,y:I}:{x:I,y:a}}function offset(e){var t=e.state,g=e.options,n=e.name,C=g.offset,o=void 0===C?[0,0]:C,I=Ai.reduce(function(e,g){return e[g]=distanceAndSkiddingToXY(g,t.rects,o),e},{}),a=I[t.placement],i=a.x,s=a.y;null!=t.modifiersData.popperOffsets&&(t.modifiersData.popperOffsets.x+=i,t.modifiersData.popperOffsets.y+=s),t.modifiersData[n]=I}function popperOffsets(e){var t=e.state,g=e.name;t.modifiersData[g]=computeOffsets({reference:t.rects.reference,element:t.rects.popper,placement:t.placement})}function getAltAxis(e){return"x"===e?"y":"x"}function preventOverflow(e){var t=e.state,g=e.options,n=e.name,C=g.mainAxis,o=void 0===C||C,I=g.altAxis,a=void 0!==I&&I,i=g.boundary,s=g.rootBoundary,l=g.altBoundary,c=g.padding,u=g.tether,d=void 0===u||u,p=g.tetherOffset,m=void 0===p?0:p,h=detectOverflow(t,{boundary:i,rootBoundary:s,padding:c,altBoundary:l}),y=getBasePlacement(t.placement),b=getVariation(t.placement),v=!b,x=getMainAxisFromPlacement(y),S=getAltAxis(x),w=t.modifiersData.popperOffsets,E=t.rects.reference,R=t.rects.popper,M="function"==typeof m?m(Object.assign({},t.rects,{placement:t.placement})):m,T="number"==typeof M?{mainAxis:M,altAxis:M}:Object.assign({mainAxis:0,altAxis:0},M),P=t.modifiersData.offset?t.modifiersData.offset[t.placement]:null,N={x:0,y:0};if(w){if(o){var O,D="y"===x?Ya:Xa,j="y"===x?Za:Qa,L="y"===x?"height":"width",G=w[x],B=G+h[D],F=G-h[j],W=d?-R[L]/2:0,V=b===$a?E[L]:R[L],K=b===$a?-R[L]:-E[L],U=t.elements.arrow,H=d&&U?getLayoutRect(U):{width:0,height:0},Y=t.modifiersData["arrow#persistent"]?t.modifiersData["arrow#persistent"].padding:getFreshSideObject(),Z=Y[D],Q=Y[j],X=within(0,E[L],H[L]),q=v?E[L]/2-W-X-Z-T.mainAxis:V-X-Z-T.mainAxis,J=v?-E[L]/2+W+X+Q+T.mainAxis:K+X+Q+T.mainAxis,$=t.elements.arrow&&getOffsetParent(t.elements.arrow),_=$?"y"===x?$.clientTop||0:$.clientLeft||0:0,ee=null!=(O=null==P?void 0:P[x])?O:0,te=G+J-ee,ge=within(d?ai(B,G+q-ee-_):B,G,d?Ii(F,te):F);w[x]=ge,N[x]=ge-G}if(a){var re,ne="x"===x?Ya:Xa,Ae="x"===x?Za:Qa,Ce=w[S],oe="y"===S?"height":"width",Ie=Ce+h[ne],ae=Ce-h[Ae],ie=-1!==[Ya,Xa].indexOf(y),se=null!=(re=null==P?void 0:P[S])?re:0,le=ie?Ie:Ce-E[oe]-R[oe]-se+T.altAxis,ce=ie?Ce+E[oe]+R[oe]-se-T.altAxis:ae,ue=d&&ie?withinMaxClamp(le,Ce,ce):within(d?le:Ie,Ce,d?ce:ae);w[S]=ue,N[S]=ue-Ce}t.modifiersData[n]=N}}function getHTMLElementScroll(e){return{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}}function getNodeScroll(e){return e!==getWindow(e)&&isHTMLElement$1(e)?getHTMLElementScroll(e):getWindowScroll(e)}function isElementScaled(e){var t=e.getBoundingClientRect(),g=ii(t.width)/e.offsetWidth||1,n=ii(t.height)/e.offsetHeight||1;return 1!==g||1!==n}function getCompositeRect(e,t,g){void 0===g&&(g=!1);var n=isHTMLElement$1(t),C=isHTMLElement$1(t)&&isElementScaled(t),o=getDocumentElement(t),I=getBoundingClientRect(e,C,g),a={scrollLeft:0,scrollTop:0},i={x:0,y:0};return(n||!n&&!g)&&(("body"!==getNodeName(t)||isScrollParent(o))&&(a=getNodeScroll(t)),isHTMLElement$1(t)?((i=getBoundingClientRect(t,!0)).x+=t.clientLeft,i.y+=t.clientTop):o&&(i.x=getWindowScrollBarX(o))),{x:I.left+a.scrollLeft-i.x,y:I.top+a.scrollTop-i.y,width:I.width,height:I.height}}function order(e){var t=new Map,g=new Set,n=[];function sort(e){g.add(e.name),[].concat(e.requires||[],e.requiresIfExists||[]).forEach(function(e){if(!g.has(e)){var n=t.get(e);n&&sort(n)}}),n.push(e)}return e.forEach(function(e){t.set(e.name,e)}),e.forEach(function(e){g.has(e.name)||sort(e)}),n}function orderModifiers(e){var t=order(e);return Ci.reduce(function(e,g){return e.concat(t.filter(function(e){return e.phase===g}))},[])}function debounce(e){var t;return function(){return t||(t=new Promise(function(g){Promise.resolve().then(function(){t=void 0,g(e())})})),t}}function mergeByName(e){var t=e.reduce(function(e,t){var g=e[t.name];return e[t.name]=g?Object.assign({},g,t,{options:Object.assign({},g.options,t.options),data:Object.assign({},g.data,t.data)}):t,e},{});return Object.keys(t).map(function(e){return t[e]})}var di={placement:"bottom",modifiers:[],strategy:"absolute"};function areValidElements(){for(var e=arguments.length,t=new Array(e),g=0;g<e;g++)t[g]=arguments[g];return!t.some(function(e){return!(e&&"function"==typeof e.getBoundingClientRect)})}function popperGenerator(e){void 0===e&&(e={});var t=e,g=t.defaultModifiers,n=void 0===g?[]:g,C=t.defaultOptions,o=void 0===C?di:C;return function(e,t,g){void 0===g&&(g=o);var C={placement:"bottom",orderedModifiers:[],options:Object.assign({},di,o),modifiersData:{},elements:{reference:e,popper:t},attributes:{},styles:{}},I=[],a=!1,i={state:C,setOptions:function(g){var I="function"==typeof g?g(C.options):g;cleanupModifierEffects(),C.options=Object.assign({},o,C.options,I),C.scrollParents={reference:isElement(e)?listScrollParents(e):e.contextElement?listScrollParents(e.contextElement):[],popper:listScrollParents(t)};var a=orderModifiers(mergeByName([].concat(n,C.options.modifiers)));return C.orderedModifiers=a.filter(function(e){return e.enabled}),runModifierEffects(),i.update()},forceUpdate:function(){if(!a){var e=C.elements,t=e.reference,g=e.popper;if(areValidElements(t,g)){C.rects={reference:getCompositeRect(t,getOffsetParent(g),"fixed"===C.options.strategy),popper:getLayoutRect(g)},C.reset=!1,C.placement=C.options.placement,C.orderedModifiers.forEach(function(e){return C.modifiersData[e.name]=Object.assign({},e.data)});for(var n=0;n<C.orderedModifiers.length;n++)if(!0!==C.reset){var o=C.orderedModifiers[n],I=o.fn,s=o.options,l=void 0===s?{}:s,c=o.name;"function"==typeof I&&(C=I({state:C,options:l,name:c,instance:i})||C)}else C.reset=!1,n=-1}}},update:debounce(function(){return new Promise(function(e){i.forceUpdate(),e(C)})}),destroy:function(){cleanupModifierEffects(),a=!0}};if(!areValidElements(e,t))return i;function runModifierEffects(){C.orderedModifiers.forEach(function(e){var t=e.name,g=e.options,n=void 0===g?{}:g,o=e.effect;if("function"==typeof o){var a=o({state:C,name:t,instance:i,options:n}),noopFn=function(){};I.push(a||noopFn)}})}function cleanupModifierEffects(){I.forEach(function(e){return e()}),I=[]}return i.setOptions(g).then(function(e){!a&&g.onFirstUpdate&&g.onFirstUpdate(e)}),i}}var pi=popperGenerator({defaultModifiers:[{name:"eventListeners",enabled:!0,phase:"write",fn:function(){},effect,data:{}},{name:"popperOffsets",enabled:!0,phase:"read",fn:popperOffsets,data:{}},{name:"computeStyles",enabled:!0,phase:"beforeWrite",fn:computeStyles,data:{}},oi,{name:"offset",enabled:!0,phase:"main",requires:["popperOffsets"],fn:offset},{name:"flip",enabled:!0,phase:"main",fn:flip,requiresIfExists:["offset"],data:{_skip:!1}},{name:"preventOverflow",enabled:!0,phase:"main",fn:preventOverflow,requiresIfExists:["offset"]},{name:"arrow",enabled:!0,phase:"main",fn:arrow,effect:effect$1,requires:["popperOffsets"],requiresIfExists:["preventOverflow"]},{name:"hide",enabled:!0,phase:"main",requiresIfExists:["preventOverflow"],fn:hide}]});function getPopperUtilityClass(e){return generateUtilityClass("MuiPopper",e)}function flipPlacement(e,t){if("ltr"===t)return e;switch(e){case"bottom-end":return"bottom-start";case"bottom-start":return"bottom-end";case"top-end":return"top-start";case"top-start":return"top-end";default:return e}}function resolveAnchorEl(e){return"function"==typeof e?e():e}function isHTMLElement(e){return void 0!==e.nodeType}generateUtilityClasses("MuiPopper",["root"]);const useUtilityClasses$2=e=>{const{classes:t}=e;return composeClasses({root:["root"]},getPopperUtilityClass,t)},mi={},fi=C.forwardRef(function(e,t){const{anchorEl:g,children:n,direction:o,disablePortal:I,modifiers:a,open:i,placement:s,popperOptions:l,popperRef:c,slotProps:u={},slots:d={},TransitionProps:p,ownerState:m,...h}=e,y=C.useRef(null),b=useForkRef(y,t),v=C.useRef(null),x=useForkRef(v,c),S=C.useRef(x);Dr(()=>{S.current=x},[x]),C.useImperativeHandle(c,()=>v.current,[]);const w=flipPlacement(s,o),[E,R]=C.useState(w),[M,T]=C.useState(resolveAnchorEl(g));C.useEffect(()=>{v.current&&v.current.forceUpdate()}),C.useEffect(()=>{g&&T(resolveAnchorEl(g))},[g]),Dr(()=>{if(!M||!i)return;const handlePopperUpdate=e=>{R(e.placement)};let e=[{name:"preventOverflow",options:{altBoundary:I}},{name:"flip",options:{altBoundary:I}},{name:"onUpdate",enabled:!0,phase:"afterWrite",fn:({state:e})=>{handlePopperUpdate(e)}}];null!=a&&(e=e.concat(a)),l&&null!=l.modifiers&&(e=e.concat(l.modifiers));const t=pi(M,y.current,{placement:w,...l,modifiers:e});return S.current(t),()=>{t.destroy(),S.current(null)}},[M,I,a,i,l,w]);const P={placement:E};null!==p&&(P.TransitionProps=p);const N=useUtilityClasses$2(e),O=d.root??"div",D=useSlotProps({elementType:O,externalSlotProps:u.root,externalForwardedProps:h,additionalProps:{role:"tooltip",ref:b},ownerState:e,className:N.root});return Hg.jsx(O,{...D,children:"function"==typeof n?n(P):n})}),hi=yn(C.forwardRef(function(e,t){const{anchorEl:g,children:n,container:o,direction:I="ltr",disablePortal:a=!1,keepMounted:i=!1,modifiers:s,open:l,placement:c="bottom",popperOptions:u=mi,popperRef:d,style:p,transition:m=!1,slotProps:h={},slots:y={},...b}=e,[v,x]=C.useState(!0),handleEnter=()=>{x(!1)},handleExited=()=>{x(!0)};if(!i&&!l&&(!m||v))return null;let S;if(o)S=o;else if(g){const e=resolveAnchorEl(g);S=e&&isHTMLElement(e)?ownerDocument(e).body:ownerDocument(null).body}const w=l||!i||m&&!v?void 0:"none",E=m?{in:l,onEnter:handleEnter,onExited:handleExited}:void 0;return Hg.jsx(EA,{disablePortal:a,container:S,children:Hg.jsx(fi,{anchorEl:g,direction:I,disablePortal:a,modifiers:s,ref:t,open:m?!v:l,placement:c,popperOptions:u,popperRef:d,slotProps:h,slots:y,...b,style:{position:"fixed",top:0,left:0,display:w,...p},TransitionProps:E,children:n})})}),{name:"MuiPopper",slot:"Root"})({}),yi=C.forwardRef(function(e,t){const g=useRtl(),n=useDefaultProps({props:e,name:"MuiPopper"}),{anchorEl:C,component:o,components:I,componentsProps:a,container:i,disablePortal:s,keepMounted:l,modifiers:c,open:u,placement:d,popperOptions:p,popperRef:m,transition:h,slots:y,slotProps:b,...v}=n,x=y?.root??I?.Root,S={anchorEl:C,container:i,disablePortal:s,keepMounted:l,modifiers:c,open:u,placement:d,popperOptions:p,popperRef:m,transition:h,...v};return Hg.jsx(hi,{as:o,direction:g?"rtl":"ltr",slots:{root:x},slotProps:b??a,...S,ref:t})});function getTooltipUtilityClass(e){return generateUtilityClass("MuiTooltip",e)}const bi=generateUtilityClasses("MuiTooltip",["popper","popperInteractive","popperArrow","popperClose","tooltip","tooltipArrow","touch","tooltipPlacementLeft","tooltipPlacementRight","tooltipPlacementTop","tooltipPlacementBottom","arrow"]);function round(e){return Math.round(1e5*e)/1e5}const useUtilityClasses$1=e=>{const{classes:t,disableInteractive:g,arrow:n,touch:C,placement:o}=e;return composeClasses({popper:["popper",!g&&"popperInteractive",n&&"popperArrow"],tooltip:["tooltip",n&&"tooltipArrow",C&&"touch",`tooltipPlacement${capitalize(o.split("-")[0])}`],arrow:["arrow"]},getTooltipUtilityClass,t)},vi=yn(yi,{name:"MuiTooltip",slot:"Popper",overridesResolver:(e,t)=>{const{ownerState:g}=e;return[t.popper,!g.disableInteractive&&t.popperInteractive,g.arrow&&t.popperArrow,!g.open&&t.popperClose]}})(Rn(({theme:e})=>({zIndex:(e.vars||e).zIndex.tooltip,pointerEvents:"none",variants:[{props:({ownerState:e})=>!e.disableInteractive,style:{pointerEvents:"auto"}},{props:({open:e})=>!e,style:{pointerEvents:"none"}},{props:({ownerState:e})=>e.arrow,style:{[`&[data-popper-placement*="bottom"] .${bi.arrow}`]:{top:0,marginTop:"-0.71em","&::before":{transformOrigin:"0 100%"}},[`&[data-popper-placement*="top"] .${bi.arrow}`]:{bottom:0,marginBottom:"-0.71em","&::before":{transformOrigin:"100% 0"}},[`&[data-popper-placement*="right"] .${bi.arrow}`]:{height:"1em",width:"0.71em","&::before":{transformOrigin:"100% 100%"}},[`&[data-popper-placement*="left"] .${bi.arrow}`]:{height:"1em",width:"0.71em","&::before":{transformOrigin:"0 0"}}}},{props:({ownerState:e})=>e.arrow&&!e.isRtl,style:{[`&[data-popper-placement*="right"] .${bi.arrow}`]:{left:0,marginLeft:"-0.71em"}}},{props:({ownerState:e})=>e.arrow&&!!e.isRtl,style:{[`&[data-popper-placement*="right"] .${bi.arrow}`]:{right:0,marginRight:"-0.71em"}}},{props:({ownerState:e})=>e.arrow&&!e.isRtl,style:{[`&[data-popper-placement*="left"] .${bi.arrow}`]:{right:0,marginRight:"-0.71em"}}},{props:({ownerState:e})=>e.arrow&&!!e.isRtl,style:{[`&[data-popper-placement*="left"] .${bi.arrow}`]:{left:0,marginLeft:"-0.71em"}}}]}))),xi=yn("div",{name:"MuiTooltip",slot:"Tooltip",overridesResolver:(e,t)=>{const{ownerState:g}=e;return[t.tooltip,g.touch&&t.touch,g.arrow&&t.tooltipArrow,t[`tooltipPlacement${capitalize(g.placement.split("-")[0])}`]]}})(Rn(({theme:e})=>({backgroundColor:e.vars?e.vars.palette.Tooltip.bg:e.alpha(e.palette.grey[700],.92),borderRadius:(e.vars||e).shape.borderRadius,color:(e.vars||e).palette.common.white,fontFamily:e.typography.fontFamily,padding:"4px 8px",fontSize:e.typography.pxToRem(11),maxWidth:300,margin:2,wordWrap:"break-word",fontWeight:e.typography.fontWeightMedium,[`.${bi.popper}[data-popper-placement*="left"] &`]:{transformOrigin:"right center"},[`.${bi.popper}[data-popper-placement*="right"] &`]:{transformOrigin:"left center"},[`.${bi.popper}[data-popper-placement*="top"] &`]:{transformOrigin:"center bottom",marginBottom:"14px"},[`.${bi.popper}[data-popper-placement*="bottom"] &`]:{transformOrigin:"center top",marginTop:"14px"},variants:[{props:({ownerState:e})=>e.arrow,style:{position:"relative",margin:0}},{props:({ownerState:e})=>e.touch,style:{padding:"8px 16px",fontSize:e.typography.pxToRem(14),lineHeight:`${round(16/14)}em`,fontWeight:e.typography.fontWeightRegular}},{props:({ownerState:e})=>!e.isRtl,style:{[`.${bi.popper}[data-popper-placement*="left"] &`]:{marginRight:"14px"},[`.${bi.popper}[data-popper-placement*="right"] &`]:{marginLeft:"14px"}}},{props:({ownerState:e})=>!e.isRtl&&e.touch,style:{[`.${bi.popper}[data-popper-placement*="left"] &`]:{marginRight:"24px"},[`.${bi.popper}[data-popper-placement*="right"] &`]:{marginLeft:"24px"}}},{props:({ownerState:e})=>!!e.isRtl,style:{[`.${bi.popper}[data-popper-placement*="left"] &`]:{marginLeft:"14px"},[`.${bi.popper}[data-popper-placement*="right"] &`]:{marginRight:"14px"}}},{props:({ownerState:e})=>!!e.isRtl&&e.touch,style:{[`.${bi.popper}[data-popper-placement*="left"] &`]:{marginLeft:"24px"},[`.${bi.popper}[data-popper-placement*="right"] &`]:{marginRight:"24px"}}},{props:({ownerState:e})=>e.touch,style:{[`.${bi.popper}[data-popper-placement*="top"] &`]:{marginBottom:"24px"}}},{props:({ownerState:e})=>e.touch,style:{[`.${bi.popper}[data-popper-placement*="bottom"] &`]:{marginTop:"24px"}}}]}))),Si=yn("span",{name:"MuiTooltip",slot:"Arrow"})(Rn(({theme:e})=>({overflow:"hidden",position:"absolute",width:"1em",height:"0.71em",boxSizing:"border-box",color:e.vars?e.vars.palette.Tooltip.bg:e.alpha(e.palette.grey[700],.9),"&::before":{content:'""',margin:"auto",display:"block",width:"100%",height:"100%",backgroundColor:"currentColor",transform:"rotate(45deg)"}})));let wi=!1;const Ei=new aA;let Ri={x:0,y:0};function composeEventHandler(e,t){return(g,...n)=>{t&&t(g,...n),e(g,...n)}}const ki=C.forwardRef(function(e,t){const g=useDefaultProps({props:e,name:"MuiTooltip"}),{arrow:n=!1,children:o,classes:I,components:a={},componentsProps:i={},describeChild:s=!1,disableFocusListener:l=!1,disableHoverListener:c=!1,disableInteractive:u=!1,disableTouchListener:d=!1,enterDelay:p=100,enterNextDelay:m=0,enterTouchDelay:h=700,followCursor:y=!1,id:b,leaveDelay:v=0,leaveTouchDelay:x=1500,onClose:S,onOpen:w,open:E,placement:R="bottom",PopperComponent:M,PopperProps:T={},slotProps:P={},slots:N={},title:O,TransitionComponent:D,TransitionProps:j,...L}=g,G=C.isValidElement(o)?o:Hg.jsx("span",{children:o}),B=useTheme$1(),F=useRtl(),[W,V]=C.useState(),[K,U]=C.useState(null),H=C.useRef(!1),Y=u||y,Z=useTimeout(),Q=useTimeout(),X=useTimeout(),q=useTimeout(),[J,$]=useControlled({controlled:E,default:!1,name:"Tooltip",state:"open"});let _=J;const ee=useId(b),te=C.useRef(),ge=useEventCallback(()=>{void 0!==te.current&&(document.body.style.WebkitUserSelect=te.current,te.current=void 0),q.clear()});C.useEffect(()=>ge,[ge]);const handleOpen=e=>{Ei.clear(),wi=!0,$(!0),w&&!_&&w(e)},re=useEventCallback(e=>{Ei.start(800+v,()=>{wi=!1}),$(!1),S&&_&&S(e),Z.start(B.transitions.duration.shortest,()=>{H.current=!1})}),handleMouseOver=e=>{H.current&&"touchstart"!==e.type||(W&&W.removeAttribute("title"),Q.clear(),X.clear(),p||wi&&m?Q.start(wi?m:p,()=>{handleOpen(e)}):handleOpen(e))},handleMouseLeave=e=>{Q.clear(),X.start(v,()=>{re(e)})},[,ne]=C.useState(!1),handleBlur=e=>{const t=e?.target??W;if(!t||!isFocusVisible(t)){ne(!1);const g=e??new Event("blur");!e&&t&&(Object.defineProperty(g,"target",{value:t}),Object.defineProperty(g,"currentTarget",{value:t})),handleMouseLeave(g)}},handleFocus=e=>{W||V(e.currentTarget),isFocusVisible(e.target)&&(ne(!0),handleMouseOver(e))},detectTouchStart=e=>{H.current=!0;const t=G.props;t.onTouchStart&&t.onTouchStart(e)},handleTouchStart=e=>{detectTouchStart(e),X.clear(),Z.clear(),ge(),te.current=document.body.style.WebkitUserSelect,document.body.style.WebkitUserSelect="none",q.start(h,()=>{document.body.style.WebkitUserSelect=te.current,handleMouseOver(e)})},handleTouchEnd=e=>{G.props.onTouchEnd&&G.props.onTouchEnd(e),ge(),X.start(x,()=>{re(e)})};C.useEffect(()=>{if(_)return document.addEventListener("keydown",handleKeyDown),()=>{document.removeEventListener("keydown",handleKeyDown)};function handleKeyDown(e){"Escape"===e.key&&re(e)}},[re,_]);const Ae=useForkRef(getReactElementRef(G),V,t);O||0===O||(_=!1);const Ce=C.useRef(),handleMouseMove=e=>{const t=G.props;t.onMouseMove&&t.onMouseMove(e),Ri={x:e.clientX,y:e.clientY},Ce.current&&Ce.current.update()},oe={},Ie="string"==typeof O;s?(oe.title=_||!Ie||c?null:O,oe["aria-describedby"]=_?ee:null):(oe["aria-label"]=Ie?O:null,oe["aria-labelledby"]=_&&!Ie?ee:null);const ae={...oe,...L,...G.props,className:clsx(L.className,G.props.className),onTouchStart:detectTouchStart,ref:Ae,...y?{onMouseMove:handleMouseMove}:{}},ie={};d||(ae.onTouchStart=handleTouchStart,ae.onTouchEnd=handleTouchEnd),c||(ae.onMouseOver=composeEventHandler(handleMouseOver,ae.onMouseOver),ae.onMouseLeave=composeEventHandler(handleMouseLeave,ae.onMouseLeave),Y||(ie.onMouseOver=handleMouseOver,ie.onMouseLeave=handleMouseLeave)),l||(ae.onFocus=composeEventHandler(handleFocus,ae.onFocus),ae.onBlur=composeEventHandler(handleBlur,ae.onBlur),Y||(ie.onFocus=handleFocus,ie.onBlur=handleBlur));const se={...g,isRtl:F,arrow:n,disableInteractive:Y,placement:R,PopperComponentProp:M,touch:H.current},le="function"==typeof P.popper?P.popper(se):P.popper,ce=C.useMemo(()=>{let e=[{name:"arrow",enabled:Boolean(K),options:{element:K,padding:4}}];return T.popperOptions?.modifiers&&(e=e.concat(T.popperOptions.modifiers)),le?.popperOptions?.modifiers&&(e=e.concat(le.popperOptions.modifiers)),{...T.popperOptions,...le?.popperOptions,modifiers:e}},[K,T.popperOptions,le?.popperOptions]),ue=useUtilityClasses$1(se),de="function"==typeof P.transition?P.transition(se):P.transition,pe={slots:{popper:a.Popper,transition:a.Transition??D,tooltip:a.Tooltip,arrow:a.Arrow,...N},slotProps:{arrow:P.arrow??i.arrow,popper:{...T,...le??i.popper},tooltip:P.tooltip??i.tooltip,transition:{...j,...de??i.transition}}},[me,fe]=useSlot("popper",{elementType:vi,externalForwardedProps:pe,ownerState:se,className:clsx(ue.popper,T?.className)}),[he,ye]=useSlot("transition",{elementType:xA,externalForwardedProps:pe,ownerState:se}),[be,ve]=useSlot("tooltip",{elementType:xi,className:ue.tooltip,externalForwardedProps:pe,ownerState:se}),[xe,Se]=useSlot("arrow",{elementType:Si,className:ue.arrow,externalForwardedProps:pe,ownerState:se,ref:U});return Hg.jsxs(C.Fragment,{children:[C.cloneElement(G,ae),Hg.jsx(me,{as:M??yi,placement:R,anchorEl:y?{getBoundingClientRect:()=>({top:Ri.y,left:Ri.x,right:Ri.x,bottom:Ri.y,width:0,height:0})}:W,popperRef:Ce,open:!!W&&_,id:ee,transition:!0,...ie,...fe,popperOptions:ce,children:({TransitionProps:e})=>Hg.jsx(he,{timeout:B.transitions.duration.shorter,...e,...ye,children:Hg.jsxs(be,{...ve,children:[O,n?Hg.jsx(xe,{...Se}):null]})})})]})}),Mi="title",Ti="popover",Pi={cursor:"help",display:"inline-flex",maxWidth:"100%"},renderLabel=(e,t,g)=>{const n=React.createElement(zn,{component:"span",variant:"body2"},e);return t?g===Mi?React.createElement(En,{component:"span",sx:Pi,title:t},n):React.createElement(ki,{describeChild:!0,placement:"top-start",title:t},React.createElement(En,{component:"span",sx:Pi},n)):n},ConfigToggleComponent=({label:e,value:t,onChange:g,tooltip:n="",tooltipMode:C=Ti})=>React.createElement(Uo,{control:React.createElement(_o,{checked:t,onChange:()=>g(!t)}),label:renderLabel(e,n,C),sx:{alignItems:"center",gap:1,justifyContent:"space-between",m:0,width:"100%","& .MuiFormControlLabel-label":{flex:1}}});ConfigToggleComponent.displayName="ConfigToggle",ConfigToggleComponent.propTypes={label:Fg.string.isRequired,onChange:Fg.func.isRequired,tooltip:Fg.string,tooltipMode:Fg.oneOf([Ti,Mi]),value:Fg.bool.isRequired};const Ni=t.memo(ConfigToggleComponent);Ni.displayName="ConfigToggle",Ni.propTypes=ConfigToggleComponent.propTypes;const NOOP=()=>{},resolveCommand=e=>"function"==typeof e?e:NOOP,createNativeDisplayCommands=e=>Object.freeze({mount:resolveCommand(e?.mountNativeDisplay),unmount:resolveCommand(e?.unmountNativeDisplay)}),useNativeDisplayCommands=()=>{const{platformTabs:e}=useNexGui();return t.useMemo(()=>createNativeDisplayCommands(e),[e])},Oi="sfx/arcade sound",Di="nexGui4.netflixMode",ji="nexGui4.netflixMode",zi="https://images.ctfassets.net/y2ske730sjqp/821Wg4N9hJD8vs5FBcCGg/9eaf66123397cc61be14e40174123c40/Vector__3_.svg?w=460",Li="netflixModeEmoteColor",Gi="netflixModeScenarios",Bi="#afffff",Fi=/^#(?:[0-9a-fA-F]{3}|[0-9a-fA-F]{6})$/,resolveNetflixEmoteColor=e=>"string"==typeof e&&Fi.test(e.trim())?e.trim():Bi,resolveNetflixScenarioEnabled=(e,t)=>{const g=e?.[t];return"boolean"!=typeof g||g},renderNetflixNoticeHtml=e=>`<span style="height:15px;overflow:hidden"><img src="${zi}" style="height:16px"/> Mode ${e}.</span>`,resolveSelfName=e=>{const t=e?.getState?.()?.name;if(isNonEmptyString(t))return t.trim().toLowerCase();const g=globalThis.GMCP?.Char?.Status?.name;return isNonEmptyString(g)?g.trim().toLowerCase():null},Wi=Object.freeze([{id:"nameMentioned",label:"Name Mentioned",predicate:(e,{selfName:t})=>!(!t||"string"!=typeof e?.text)&&e.text.toLowerCase().includes(t)},{id:"saysChannel",label:"Says",predicate:e=>"says"===e?.channel},{id:"tellsChannel",label:"Tells",predicate:e=>"tells"===e?.channel}]),Vi=Object.freeze([{id:"emote",label:"Emote",regex:/^/,resolveFg:({emoteColor:e})=>e}]),Ki=Object.freeze([{id:"affGot",label:"Aff Got",eventName:"nexsys4.aff.got"},{id:"defLost",label:"Def Lost",eventName:"nexsys4.def.lost"},{id:"damage",label:"Damage",eventName:"nexsys4.system.health.changed"},{id:"roomChanged",label:"Room Changed",eventName:"nexsys4.system.room.changed"}]),Ui=Object.freeze([...Wi.map(({id:e,label:t})=>({id:e,label:t,source:"commChannel"})),...Ki.map(({id:e,label:t})=>({id:e,label:t,source:"event"})),...Vi.map(({id:e,label:t})=>({id:e,label:t,source:"trigger"}))]),playNetflixSound=()=>{nexusclient.ui?.()?.sounds?.()?.play_sound?.(Oi)},evaluateCommChannelPayload=(e,t,g)=>{for(const n of Wi)if(resolveNetflixScenarioEnabled(g,n.id)&&n.predicate(e??{},t))return!0;return!1},attachCommChannelListener=(e,t)=>{const handler=g=>{const n=resolveSelfName(e),C=t();evaluateCommChannelPayload(g,{selfName:n},C)&&playNetflixSound()};return eventStream.registerEvent("Comm.Channel.Text",handler,{id:Di}),()=>{eventStream.removeListener("Comm.Channel.Text",Di)}},attachTriggerScenarios=(e,t)=>{for(const g of Vi){if(!resolveNetflixScenarioEnabled(t,g.id))continue;const n=g.resolveFg?.({emoteColor:e})??g.fg;nexAction.triggers.add({id:`${ji}.${g.id}`,regex:g.regex,tags:[ji],fg:n,action:playNetflixSound})}return()=>{nexAction.triggers.remove([ji])}},areTriggerScenarioOverridesEqual=(e,t)=>{for(const g of Vi)if(resolveNetflixScenarioEnabled(e,g.id)!==resolveNetflixScenarioEnabled(t,g.id))return!1;return!0},attachEventScenarios=e=>{const t=[];for(const g of Ki){const n=`${Di}.eventScenario.${g.id}`,handler=t=>{const n=e();resolveNetflixScenarioEnabled(n,g.id)&&(g.predicate&&!g.predicate(t)||playNetflixSound())};eventStream.registerEvent(g.eventName,handler,{id:n}),t.push(()=>eventStream.removeListener(g.eventName,n))}return()=>{for(const e of t)e()}},readEmoteColorFromUiState=e=>resolveNetflixEmoteColor(e?.settings?.[Li]),readScenarioOverridesFromUiState=e=>e?.settings?.[Gi]??null,createNetflixModeController=({adapter:e,uiStore:t,characterStore:g})=>{if(!t||"function"!=typeof t.getState||"function"!=typeof t.subscribe)return()=>{};let n=null,C=null,o=null,I=!1,a=null,i=null;const getScenarioOverrides=()=>readScenarioOverridesFromUiState(t.getState()),enable=(t,s)=>{I||(n=attachCommChannelListener(g,getScenarioOverrides),C=attachTriggerScenarios(t,s),o=attachEventScenarios(getScenarioOverrides),a=t,i=s,I=!0,e?.notice?.(renderNetflixNoticeHtml("Enabled"),{html:!0}))},disable=()=>{I&&(n?.(),C?.(),o?.(),n=null,C=null,o=null,a=null,i=null,I=!1,e?.notice?.(renderNetflixNoticeHtml("Disabled"),{html:!0}))},reattachTriggers=(e,t)=>{C?.(),C=attachTriggerScenarios(e,t),a=e,i=t},sync=e=>{const t=readEmoteColorFromUiState(e),g=readScenarioOverridesFromUiState(e);if(e?.netflixMode){if(!I)return void enable(t,g);const e=t!==a,n=!areTriggerScenarioOverridesEqual(g,i);(e||n)&&reattachTriggers(t,g)}else disable()};sync(t.getState());const s=t.subscribe((e,t)=>{const g=Boolean(e?.netflixMode),n=Boolean(t?.netflixMode),C=readEmoteColorFromUiState(e),o=readEmoteColorFromUiState(t),I=readScenarioOverridesFromUiState(e),a=readScenarioOverridesFromUiState(t);g===n&&C===o&&I===a||sync(e)});return()=>{s(),I&&(n?.(),C?.(),o?.(),n=null,C=null,o=null,a=null,i=null,I=!1)}},useNetflixModeSettings=()=>{const{stores:e}=useNexGui(),g=e.ui(e=>e.netflixMode),n=e.ui(e=>e.setNetflixMode),C=e.ui(e=>e.settings?.[Li]),o=e.ui(e=>e.settings?.[Gi]),I=e.ui(e=>e.setSetting),a=t.useCallback(e=>{I(Li,resolveNetflixEmoteColor(e))},[I]),i=t.useCallback((t,g)=>{const n=e.ui.getState().settings?.[Gi]??{};I(Gi,{...n,[t]:Boolean(g)})},[I,e]),s=t.useMemo(()=>Ui.map(({id:e,label:t})=>({id:e,label:t,enabled:resolveNetflixScenarioEnabled(o,e),setEnabled:t=>i(e,t)})),[o,i]);return{enabled:Boolean(g),setEnabled:n,emoteColor:resolveNetflixEmoteColor(C),defaultEmoteColor:Bi,setEmoteColor:a,logoUrl:zi,scenarios:s}},usePersistence=()=>{const{persistenceStore:e}=useNexGui();return e},Hi=[{key:"loginTracker",label:"Login Tracker",tooltip:"Show formatted login/logout notices by diffing the who list against Achaea's public character roster. Uses ally/enemy and target name formatting, and excludes your own character."},{key:"logoutDownload",label:"Auto-Download Log on Logout",tooltip:"Automatically download the scrollback buffer as an HTML log when you disconnect."},{key:"virtualizedLogs",label:"Virtualized HTML Logs",tooltip:"Download logs as an interactive virtualized HTML viewer for long sessions."}],NetflixModeSection=()=>{const{enabled:e,setEnabled:t,emoteColor:g,setEmoteColor:n,logoUrl:C,scenarios:o}=useNetflixModeSettings();return React.createElement(En,{sx:{display:"flex",flexDirection:"column",gap:1}},React.createElement(zn,{gutterBottom:!0,sx:{alignItems:"center",display:"flex",gap:.75},variant:"subtitle2"},React.createElement(En,{alt:"Netflix",component:"img",src:C,sx:{display:"block",height:14,width:"auto"}}),"Mode"),React.createElement(Ni,{label:"Enabled",onChange:t,tooltip:"Play an attention chime on enabled catches below. Resets to off each session.",tooltipMode:"title",value:e}),React.createElement(En,{sx:{display:"flex",flexDirection:"column",gap:.25,pl:1}},React.createElement(zn,{color:"text.secondary",sx:{mb:.25},variant:"caption"},"Catches"),o.map(e=>React.createElement(Ni,{key:e.id,label:e.label,onChange:e.setEnabled,tooltipMode:"title",value:e.enabled}))),React.createElement(En,{sx:{alignItems:"center",display:"flex",gap:1.5},title:"Color used by the emote attention trigger. Set this to your configured emote line color so the trigger matches emotes in your room."},React.createElement(zn,{sx:{minWidth:96},variant:"body2"},"Emote Color"),React.createElement(En,{component:"input","aria-label":"Netflix Mode emote color",onChange:e=>n(e.target.value),sx:{background:"transparent",border:"1px solid rgba(255,255,255,0.2)",borderRadius:1,cursor:"pointer",height:28,padding:0,width:40},type:"color",value:g}),React.createElement(zn,{sx:{fontFamily:"monospace"},variant:"caption"},g)))};NetflixModeSection.displayName="NetflixModeSection";const OptionsAdvancedInner=()=>{const e=usePersistence(),g=useNativeDisplayCommands(),[n,C]=t.useState(()=>e.get("ui")??{}),[o,I]=t.useState(!1),handleToggle=(t,g)=>{const o={...n,[t]:g};e.set("ui",o),C(o)},handleNativeDisplay=e=>{handleToggle("nativeDisplay",e),e?g.mount():g.unmount()};return React.createElement(En,{className:"options-advanced",sx:{display:"flex",flexDirection:"column",gap:1.5,p:1.5}},React.createElement(zn,{gutterBottom:!0,variant:"subtitle2"},"Advanced Options"),React.createElement(oC,{sx:{mb:1}}),React.createElement(En,{sx:{columnGap:3,display:"grid",gridTemplateColumns:{xs:"minmax(0, 1fr)",md:"repeat(2, minmax(0, 1fr))"},rowGap:1.5}},React.createElement(En,{sx:{display:"flex",flexDirection:"column",gap:.5,minWidth:0}},Hi.map(({key:e,label:t,tooltip:g})=>React.createElement(Ni,{key:e,label:t,onChange:t=>handleToggle(e,t),tooltip:g,tooltipMode:"title",value:Boolean(n[e])})),React.createElement(oC,{sx:{my:1}}),React.createElement(zn,{gutterBottom:!0,variant:"subtitle2"},"Experimental"),React.createElement(Ni,{label:"Native Display Override",onChange:handleNativeDisplay,tooltip:"Mount the nexGui display in the Nexus output area instead of a panel tab. Applies immediately; the tab panel is hidden on the next reload.",tooltipMode:"title",value:Boolean(n.nativeDisplay)}),React.createElement(oC,{sx:{my:1}}),React.createElement(zn,{gutterBottom:!0,variant:"subtitle2"},"Debug"),React.createElement(Ni,{label:"Event Bus Debug Mode",onChange:I,tooltip:"Log all internal events to the browser console. Session-only.",tooltipMode:"title",value:o})),React.createElement(En,{sx:{display:"flex",flexDirection:"column",gap:.5,minWidth:0}},React.createElement(NetflixModeSection,null))))};OptionsAdvancedInner.displayName="OptionsAdvancedInner";const OptionsAdvanced=()=>React.createElement(Ln,{panelName:"Options Advanced"},React.createElement(OptionsAdvancedInner,null));OptionsAdvanced.displayName="OptionsAdvanced";const Yi={border:0,clip:"rect(0 0 0 0)",height:"1px",margin:"-1px",overflow:"hidden",padding:0,position:"absolute",whiteSpace:"nowrap",width:"1px"};function areArraysEqual(e,t,g=(e,t)=>e===t){return e.length===t.length&&e.every((e,n)=>g(e,t[n]))}const Zi=2;function getNewValue(e,t,g,n,C){return 1===g?Math.min(e+t,C):Math.max(e-t,n)}function asc(e,t){return e-t}function findClosest(e,t){const{index:g}=e.reduce((e,g,n)=>{const C=Math.abs(t-g);return null===e||C<e.distance||C===e.distance?{distance:C,index:n}:e},null)??{};return g}function trackFinger(e,t){if(void 0!==t.current&&e.changedTouches){const g=e;for(let e=0;e<g.changedTouches.length;e+=1){const n=g.changedTouches[e];if(n.identifier===t.current)return{x:n.clientX,y:n.clientY}}return!1}return{x:e.clientX,y:e.clientY}}function valueToPercent(e,t,g){return 100*(e-t)/(g-t)}function percentToValue(e,t,g){return(g-t)*e+t}function getDecimalPrecision(e){if(Math.abs(e)<1){const t=e.toExponential().split("e-"),g=t[0].split(".")[1];return(g?g.length:0)+parseInt(t[1],10)}const t=e.toString().split(".")[1];return t?t.length:0}function roundValueToStep(e,t,g){const n=Math.round((e-g)/t)*t+g;return Number(n.toFixed(getDecimalPrecision(t)))}function setValueIndex({values:e,newValue:t,index:g}){const n=e.slice();return n[g]=t,n.sort(asc)}function focusThumb({sliderRef:e,activeIndex:t,setActive:g}){const n=ownerDocument(e.current);e.current?.contains(n.activeElement)&&Number(n?.activeElement?.getAttribute("data-index"))===t||e.current?.querySelector(`[type="range"][data-index="${t}"]`).focus(),g&&g(t)}function areValuesEqual(e,t){return"number"==typeof e&&"number"==typeof t?e===t:"object"==typeof e&&"object"==typeof t&&areArraysEqual(e,t)}const Qi={horizontal:{offset:e=>({left:`${e}%`}),leap:e=>({width:`${e}%`})},"horizontal-reverse":{offset:e=>({right:`${e}%`}),leap:e=>({width:`${e}%`})},vertical:{offset:e=>({bottom:`${e}%`}),leap:e=>({height:`${e}%`})}},Identity$1=e=>e;let Xi;function doesSupportTouchActionNone(){return void 0===Xi&&(Xi="undefined"==typeof CSS||"function"!=typeof CSS.supports||CSS.supports("touch-action","none")),Xi}function useSlider(e){const{"aria-labelledby":t,defaultValue:g,disabled:n=!1,disableSwap:o=!1,isRtl:I=!1,marks:a=!1,max:i=100,min:s=0,name:l,onChange:c,onChangeCommitted:u,orientation:d="horizontal",rootRef:p,scale:m=Identity$1,step:h=1,shiftStep:y=10,tabIndex:b,value:v}=e,x=C.useRef(void 0),[S,w]=C.useState(-1),[E,R]=C.useState(-1),[M,T]=C.useState(!1),P=C.useRef(0),N=C.useRef(null),[O,D]=useControlled({controlled:v,default:g??s,name:"Slider"}),j=c&&((e,t,g)=>{const n=e.nativeEvent||e,C=new n.constructor(n.type,n);Object.defineProperty(C,"target",{writable:!0,value:{value:t,name:l}}),N.current=t,c(C,t,g)}),L=Array.isArray(O);let G=L?O.slice().sort(asc):[O];G=G.map(e=>null==e?s:clamp$2(e,s,i));const B=!0===a&&null!==h?[...Array(Math.floor((i-s)/h)+1)].map((e,t)=>({value:s+h*t})):a||[],F=B.map(e=>e.value),[W,V]=C.useState(-1),K=C.useRef(null),U=useForkRef(p,K),createHandleHiddenInputFocus=e=>t=>{const g=Number(t.currentTarget.getAttribute("data-index"));isFocusVisible(t.target)&&V(g),R(g),e?.onFocus?.(t)},createHandleHiddenInputBlur=e=>t=>{isFocusVisible(t.target)||V(-1),R(-1),e?.onBlur?.(t)},changeValue=(e,t)=>{const g=Number(e.currentTarget.getAttribute("data-index")),n=G[g],C=F.indexOf(n);let I=t;if(B&&null==h){const e=F[F.length-1];I=I>=e?e:I<=F[0]?F[0]:I<n?F[C-1]:F[C+1]}if(I=clamp$2(I,s,i),L){o&&(I=clamp$2(I,G[g-1]||-1/0,G[g+1]||1/0));const e=I;I=setValueIndex({values:G,newValue:I,index:g});let t=g;o||(t=I.indexOf(e)),focusThumb({sliderRef:K,activeIndex:t})}D(I),V(g),j&&!areValuesEqual(I,O)&&j(e,I,g),u&&u(e,N.current??I)},createHandleHiddenInputKeyDown=e=>t=>{if(["ArrowUp","ArrowDown","ArrowLeft","ArrowRight","PageUp","PageDown","Home","End"].includes(t.key)){t.preventDefault();const e=Number(t.currentTarget.getAttribute("data-index")),g=G[e];let n=null;if(null!=h){const e=t.shiftKey?y:h;switch(t.key){case"ArrowUp":n=getNewValue(g,e,1,s,i);break;case"ArrowRight":n=getNewValue(g,e,I?-1:1,s,i);break;case"ArrowDown":n=getNewValue(g,e,-1,s,i);break;case"ArrowLeft":n=getNewValue(g,e,I?1:-1,s,i);break;case"PageUp":n=getNewValue(g,y,1,s,i);break;case"PageDown":n=getNewValue(g,y,-1,s,i);break;case"Home":n=s;break;case"End":n=i}}else if(B){const e=F[F.length-1],C=F.indexOf(g),o=[I?"ArrowLeft":"ArrowRight","ArrowUp","PageUp","End"];[I?"ArrowRight":"ArrowLeft","ArrowDown","PageDown","Home"].includes(t.key)?n=0===C?F[0]:F[C-1]:o.includes(t.key)&&(n=C===F.length-1?e:F[C+1])}null!=n&&changeValue(t,n)}e?.onKeyDown?.(t)};Dr(()=>{n&&K.current.contains(document.activeElement)&&document.activeElement?.blur()},[n]),n&&-1!==S&&w(-1),n&&-1!==W&&V(-1);const createHandleHiddenInputChange=e=>t=>{e.onChange?.(t),changeValue(t,t.target.valueAsNumber)},H=C.useRef(void 0);let Y=d;I&&"horizontal"===d&&(Y+="-reverse");const getFingerNewValue=({finger:e,move:t=!1})=>{const{current:g}=K,{width:n,height:C,bottom:I,left:a}=g.getBoundingClientRect();let l,c;if(l=Y.startsWith("vertical")?(I-e.y)/C:(e.x-a)/n,Y.includes("-reverse")&&(l=1-l),c=percentToValue(l,s,i),h)c=roundValueToStep(c,h,s);else{const e=findClosest(F,c);c=F[e]}c=clamp$2(c,s,i);let u=0;if(L){u=t?H.current:findClosest(G,c),o&&(c=clamp$2(c,G[u-1]||-1/0,G[u+1]||1/0));const e=c;c=setValueIndex({values:G,newValue:c,index:u}),o&&t||(u=c.indexOf(e),H.current=u)}return{newValue:c,activeIndex:u}},Z=useEventCallback(e=>{const t=trackFinger(e,x);if(!t)return;if(P.current+=1,"mousemove"===e.type&&0===e.buttons)return void Q(e);const{newValue:g,activeIndex:n}=getFingerNewValue({finger:t,move:!0});focusThumb({sliderRef:K,activeIndex:n,setActive:w}),D(g),!M&&P.current>Zi&&T(!0),j&&!areValuesEqual(g,O)&&j(e,g,n)}),Q=useEventCallback(e=>{const t=trackFinger(e,x);if(T(!1),!t)return;const{newValue:g}=getFingerNewValue({finger:t,move:!0});w(-1),"touchend"===e.type&&R(-1),u&&u(e,N.current??g),x.current=void 0,q()}),X=useEventCallback(e=>{if(n)return;doesSupportTouchActionNone()||e.preventDefault();const t=e.changedTouches[0];null!=t&&(x.current=t.identifier);const g=trackFinger(e,x);if(!1!==g){const{newValue:t,activeIndex:n}=getFingerNewValue({finger:g});focusThumb({sliderRef:K,activeIndex:n,setActive:w}),D(t),j&&!areValuesEqual(t,O)&&j(e,t,n)}P.current=0;const C=ownerDocument(K.current);C.addEventListener("touchmove",Z,{passive:!0}),C.addEventListener("touchend",Q,{passive:!0})}),q=C.useCallback(()=>{const e=ownerDocument(K.current);e.removeEventListener("mousemove",Z),e.removeEventListener("mouseup",Q),e.removeEventListener("touchmove",Z),e.removeEventListener("touchend",Q)},[Q,Z]);C.useEffect(()=>{const{current:e}=K;return e.addEventListener("touchstart",X,{passive:doesSupportTouchActionNone()}),()=>{e.removeEventListener("touchstart",X),q()}},[q,X]),C.useEffect(()=>{n&&q()},[n,q]);const createHandleMouseDown=e=>t=>{if(e.onMouseDown?.(t),n)return;if(t.defaultPrevented)return;if(0!==t.button)return;t.preventDefault();const g=trackFinger(t,x);if(!1!==g){const{newValue:e,activeIndex:n}=getFingerNewValue({finger:g});focusThumb({sliderRef:K,activeIndex:n,setActive:w}),D(e),j&&!areValuesEqual(e,O)&&j(t,e,n)}P.current=0;const C=ownerDocument(K.current);C.addEventListener("mousemove",Z,{passive:!0}),C.addEventListener("mouseup",Q)},J=valueToPercent(L?G[0]:s,s,i),$=valueToPercent(G[G.length-1],s,i)-J,createHandleMouseOver=e=>t=>{e.onMouseOver?.(t);const g=Number(t.currentTarget.getAttribute("data-index"));R(g)},createHandleMouseLeave=e=>t=>{e.onMouseLeave?.(t),R(-1)};let _;return"vertical"===d&&(_=I?"vertical-rl":"vertical-lr"),{active:S,axis:Y,axisProps:Qi,dragging:M,focusedThumbIndex:W,getHiddenInputProps:(g={})=>{const C=extractEventHandlers(g),o={onChange:createHandleHiddenInputChange(C||{}),onFocus:createHandleHiddenInputFocus(C||{}),onBlur:createHandleHiddenInputBlur(C||{}),onKeyDown:createHandleHiddenInputKeyDown(C||{})},a={...C,...o};return{tabIndex:b,"aria-labelledby":t,"aria-orientation":d,"aria-valuemax":m(i),"aria-valuemin":m(s),name:l,type:"range",min:e.min,max:e.max,step:null===e.step&&e.marks?"any":e.step??void 0,disabled:n,...g,...a,style:{...Yi,direction:I?"rtl":"ltr",width:"100%",height:"100%",writingMode:_}}},getRootProps:(e={})=>{const t=extractEventHandlers(e),g={onMouseDown:createHandleMouseDown(t||{})},n={...t,...g};return{...e,ref:U,...n}},getThumbProps:(e={})=>{const t=extractEventHandlers(e),g={onMouseOver:createHandleMouseOver(t||{}),onMouseLeave:createHandleMouseLeave(t||{})};return{...e,...t,...g}},marks:B,open:E,range:L,rootRef:U,trackLeap:$,trackOffset:J,values:G,getThumbStyle:e=>({pointerEvents:-1!==S&&S!==e?"none":void 0})}}const shouldSpreadAdditionalProps=e=>!e||!isHostComponent(e);function getSliderUtilityClass(e){return generateUtilityClass("MuiSlider",e)}const qi=generateUtilityClasses("MuiSlider",["root","active","colorPrimary","colorSecondary","colorError","colorInfo","colorSuccess","colorWarning","disabled","dragging","focusVisible","mark","markActive","marked","markLabel","markLabelActive","rail","sizeSmall","thumb","thumbColorPrimary","thumbColorSecondary","thumbColorError","thumbColorSuccess","thumbColorInfo","thumbColorWarning","track","trackInverted","trackFalse","thumbSizeSmall","valueLabel","valueLabelOpen","valueLabelCircle","valueLabelLabel","vertical"]),useValueLabelClasses=e=>{const{open:t}=e;return{offset:clsx(t&&qi.valueLabelOpen),circle:qi.valueLabelCircle,label:qi.valueLabelLabel}};function SliderValueLabel$1(e){const{children:t,className:g,value:n}=e,o=useValueLabelClasses(e);return t?C.cloneElement(t,{className:t.props.className},Hg.jsxs(C.Fragment,{children:[t.props.children,Hg.jsx("span",{className:clsx(o.offset,g),"aria-hidden":!0,children:Hg.jsx("span",{className:o.circle,children:Hg.jsx("span",{className:o.label,children:n})})})]})):null}function Identity(e){return e}const Ji=yn("span",{name:"MuiSlider",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:g}=e;return[t.root,t[`color${capitalize(g.color)}`],"medium"!==g.size&&t[`size${capitalize(g.size)}`],g.marked&&t.marked,"vertical"===g.orientation&&t.vertical,"inverted"===g.track&&t.trackInverted,!1===g.track&&t.trackFalse]}})(Rn(({theme:e})=>({borderRadius:12,boxSizing:"content-box",display:"inline-block",position:"relative",cursor:"pointer",touchAction:"none",WebkitTapHighlightColor:"transparent","@media print":{colorAdjust:"exact"},[`&.${qi.disabled}`]:{pointerEvents:"none",cursor:"default",color:(e.vars||e).palette.grey[400]},[`&.${qi.dragging}`]:{[`& .${qi.thumb}, & .${qi.track}`]:{transition:"none"}},variants:[...Object.entries(e.palette).filter(createSimplePaletteValueFilter()).map(([t])=>({props:{color:t},style:{color:(e.vars||e).palette[t].main}})),{props:{orientation:"horizontal"},style:{height:4,width:"100%",padding:"13px 0","@media (pointer: coarse)":{padding:"20px 0"}}},{props:{orientation:"horizontal",size:"small"},style:{height:2}},{props:{orientation:"horizontal",marked:!0},style:{marginBottom:20}},{props:{orientation:"vertical"},style:{height:"100%",width:4,padding:"0 13px","@media (pointer: coarse)":{padding:"0 20px"}}},{props:{orientation:"vertical",size:"small"},style:{width:2}},{props:{orientation:"vertical",marked:!0},style:{marginRight:44}}]}))),$i=yn("span",{name:"MuiSlider",slot:"Rail"})({display:"block",position:"absolute",borderRadius:"inherit",backgroundColor:"currentColor",opacity:.38,variants:[{props:{orientation:"horizontal"},style:{width:"100%",height:"inherit",top:"50%",transform:"translateY(-50%)"}},{props:{orientation:"vertical"},style:{height:"100%",width:"inherit",left:"50%",transform:"translateX(-50%)"}},{props:{track:"inverted"},style:{opacity:1}}]}),_i=yn("span",{name:"MuiSlider",slot:"Track"})(Rn(({theme:e})=>({display:"block",position:"absolute",borderRadius:"inherit",border:"1px solid currentColor",backgroundColor:"currentColor",transition:e.transitions.create(["left","width","bottom","height"],{duration:e.transitions.duration.shortest}),variants:[{props:{size:"small"},style:{border:"none"}},{props:{orientation:"horizontal"},style:{height:"inherit",top:"50%",transform:"translateY(-50%)"}},{props:{orientation:"vertical"},style:{width:"inherit",left:"50%",transform:"translateX(-50%)"}},{props:{track:!1},style:{display:"none"}},...Object.entries(e.palette).filter(createSimplePaletteValueFilter()).map(([t])=>({props:{color:t,track:"inverted"},style:{...e.vars?{backgroundColor:e.vars.palette.Slider[`${t}Track`],borderColor:e.vars.palette.Slider[`${t}Track`]}:{backgroundColor:e.lighten(e.palette[t].main,.62),borderColor:e.lighten(e.palette[t].main,.62),...e.applyStyles("dark",{backgroundColor:e.darken(e.palette[t].main,.5)}),...e.applyStyles("dark",{borderColor:e.darken(e.palette[t].main,.5)})}}}))]}))),es=yn("span",{name:"MuiSlider",slot:"Thumb",overridesResolver:(e,t)=>{const{ownerState:g}=e;return[t.thumb,t[`thumbColor${capitalize(g.color)}`],"medium"!==g.size&&t[`thumbSize${capitalize(g.size)}`]]}})(Rn(({theme:e})=>({position:"absolute",width:20,height:20,boxSizing:"border-box",borderRadius:"50%",outline:0,backgroundColor:"currentColor",display:"flex",alignItems:"center",justifyContent:"center",transition:e.transitions.create(["box-shadow","left","bottom"],{duration:e.transitions.duration.shortest}),"&::before":{position:"absolute",content:'""',borderRadius:"inherit",width:"100%",height:"100%",boxShadow:(e.vars||e).shadows[2]},"&::after":{position:"absolute",content:'""',borderRadius:"50%",width:42,height:42,top:"50%",left:"50%",transform:"translate(-50%, -50%)"},[`&.${qi.disabled}`]:{"&:hover":{boxShadow:"none"}},variants:[{props:{size:"small"},style:{width:12,height:12,"&::before":{boxShadow:"none"}}},{props:{orientation:"horizontal"},style:{top:"50%",transform:"translate(-50%, -50%)"}},{props:{orientation:"vertical"},style:{left:"50%",transform:"translate(-50%, 50%)"}},...Object.entries(e.palette).filter(createSimplePaletteValueFilter()).map(([t])=>({props:{color:t},style:{[`&:hover, &.${qi.focusVisible}`]:{boxShadow:`0px 0px 0px 8px ${e.alpha((e.vars||e).palette[t].main,.16)}`,"@media (hover: none)":{boxShadow:"none"}},[`&.${qi.active}`]:{boxShadow:`0px 0px 0px 14px ${e.alpha((e.vars||e).palette[t].main,.16)}`}}}))]}))),ts=yn(SliderValueLabel$1,{name:"MuiSlider",slot:"ValueLabel"})(Rn(({theme:e})=>({zIndex:1,whiteSpace:"nowrap",...e.typography.body2,fontWeight:500,transition:e.transitions.create(["transform"],{duration:e.transitions.duration.shortest}),position:"absolute",backgroundColor:(e.vars||e).palette.grey[600],borderRadius:2,color:(e.vars||e).palette.common.white,display:"flex",alignItems:"center",justifyContent:"center",padding:"0.25rem 0.75rem",variants:[{props:{orientation:"horizontal"},style:{transform:"translateY(-100%) scale(0)",top:"-10px",transformOrigin:"bottom center","&::before":{position:"absolute",content:'""',width:8,height:8,transform:"translate(-50%, 50%) rotate(45deg)",backgroundColor:"inherit",bottom:0,left:"50%"},[`&.${qi.valueLabelOpen}`]:{transform:"translateY(-100%) scale(1)"}}},{props:{orientation:"vertical"},style:{transform:"translateY(-50%) scale(0)",right:"30px",top:"50%",transformOrigin:"right center","&::before":{position:"absolute",content:'""',width:8,height:8,transform:"translate(-50%, -50%) rotate(45deg)",backgroundColor:"inherit",right:-8,top:"50%"},[`&.${qi.valueLabelOpen}`]:{transform:"translateY(-50%) scale(1)"}}},{props:{size:"small"},style:{fontSize:e.typography.pxToRem(12),padding:"0.25rem 0.5rem"}},{props:{orientation:"vertical",size:"small"},style:{right:"20px"}}]}))),gs=yn("span",{name:"MuiSlider",slot:"Mark",shouldForwardProp:e=>slotShouldForwardProp(e)&&"markActive"!==e,overridesResolver:(e,t)=>{const{markActive:g}=e;return[t.mark,g&&t.markActive]}})(Rn(({theme:e})=>({position:"absolute",width:2,height:2,borderRadius:1,backgroundColor:"currentColor",variants:[{props:{orientation:"horizontal"},style:{top:"50%",transform:"translate(-1px, -50%)"}},{props:{orientation:"vertical"},style:{left:"50%",transform:"translate(-50%, 1px)"}},{props:{markActive:!0},style:{backgroundColor:(e.vars||e).palette.background.paper,opacity:.8}}]}))),rs=yn("span",{name:"MuiSlider",slot:"MarkLabel",shouldForwardProp:e=>slotShouldForwardProp(e)&&"markLabelActive"!==e})(Rn(({theme:e})=>({...e.typography.body2,color:(e.vars||e).palette.text.secondary,position:"absolute",whiteSpace:"nowrap",variants:[{props:{orientation:"horizontal"},style:{top:30,transform:"translateX(-50%)","@media (pointer: coarse)":{top:40}}},{props:{orientation:"vertical"},style:{left:36,transform:"translateY(50%)","@media (pointer: coarse)":{left:44}}},{props:{markLabelActive:!0},style:{color:(e.vars||e).palette.text.primary}}]}))),useUtilityClasses=e=>{const{disabled:t,dragging:g,marked:n,orientation:C,track:o,classes:I,color:a,size:i}=e;return composeClasses({root:["root",t&&"disabled",g&&"dragging",n&&"marked","vertical"===C&&"vertical","inverted"===o&&"trackInverted",!1===o&&"trackFalse",a&&`color${capitalize(a)}`,i&&`size${capitalize(i)}`],rail:["rail"],track:["track"],mark:["mark"],markActive:["markActive"],markLabel:["markLabel"],markLabelActive:["markLabelActive"],valueLabel:["valueLabel"],thumb:["thumb",t&&"disabled",i&&`thumbSize${capitalize(i)}`,a&&`thumbColor${capitalize(a)}`],active:["active"],disabled:["disabled"],focusVisible:["focusVisible"]},getSliderUtilityClass,I)},Forward=({children:e})=>e,ns=C.forwardRef(function(e,t){const g=useDefaultProps({props:e,name:"MuiSlider"}),n=useRtl(),{"aria-label":o,"aria-valuetext":I,"aria-labelledby":a,component:i="span",components:s={},componentsProps:l={},color:c="primary",classes:u,className:d,disableSwap:p=!1,disabled:m=!1,getAriaLabel:h,getAriaValueText:y,marks:b=!1,max:v=100,min:x=0,name:S,onChange:w,onChangeCommitted:E,orientation:R="horizontal",shiftStep:M=10,size:T="medium",step:P=1,scale:N=Identity,slotProps:O,slots:D,tabIndex:j,track:L="normal",value:G,valueLabelDisplay:B="off",valueLabelFormat:F=Identity,...W}=g,V={...g,isRtl:n,max:v,min:x,classes:u,disabled:m,disableSwap:p,orientation:R,marks:b,color:c,size:T,step:P,shiftStep:M,scale:N,track:L,valueLabelDisplay:B,valueLabelFormat:F},{axisProps:K,getRootProps:U,getHiddenInputProps:H,getThumbProps:Y,open:Z,active:Q,axis:X,focusedThumbIndex:q,range:J,dragging:$,marks:_,values:ee,trackOffset:te,trackLeap:ge,getThumbStyle:re}=useSlider({...V,rootRef:t});V.marked=_.length>0&&_.some(e=>e.label),V.dragging=$,V.focusedThumbIndex=q;const ne=useUtilityClasses(V),Ae=D?.root??s.Root??Ji,Ce=D?.rail??s.Rail??$i,oe=D?.track??s.Track??_i,Ie=D?.thumb??s.Thumb??es,ae=D?.valueLabel??s.ValueLabel??ts,ie=D?.mark??s.Mark??gs,se=D?.markLabel??s.MarkLabel??rs,le=D?.input??s.Input??"input",ce=O?.root??l.root,ue=O?.rail??l.rail,de=O?.track??l.track,pe=O?.thumb??l.thumb,me=O?.valueLabel??l.valueLabel,fe=O?.mark??l.mark,he=O?.markLabel??l.markLabel,ye=O?.input??l.input,be=useSlotProps({elementType:Ae,getSlotProps:U,externalSlotProps:ce,externalForwardedProps:W,additionalProps:{...shouldSpreadAdditionalProps(Ae)&&{as:i}},ownerState:{...V,...ce?.ownerState},className:[ne.root,d]}),ve=useSlotProps({elementType:Ce,externalSlotProps:ue,ownerState:V,className:ne.rail}),xe=useSlotProps({elementType:oe,externalSlotProps:de,additionalProps:{style:{...K[X].offset(te),...K[X].leap(ge)}},ownerState:{...V,...de?.ownerState},className:ne.track}),Se=useSlotProps({elementType:Ie,getSlotProps:Y,externalSlotProps:pe,ownerState:{...V,...pe?.ownerState},className:ne.thumb}),we=useSlotProps({elementType:ae,externalSlotProps:me,ownerState:{...V,...me?.ownerState},className:ne.valueLabel}),Ee=useSlotProps({elementType:ie,externalSlotProps:fe,ownerState:V,className:ne.mark}),Re=useSlotProps({elementType:se,externalSlotProps:he,ownerState:V,className:ne.markLabel}),ke=useSlotProps({elementType:le,getSlotProps:H,externalSlotProps:ye,ownerState:V});return Hg.jsxs(Ae,{...be,children:[Hg.jsx(Ce,{...ve}),Hg.jsx(oe,{...xe}),_.filter(e=>e.value>=x&&e.value<=v).map((e,t)=>{const g=valueToPercent(e.value,x,v),n=K[X].offset(g);let o;return o=!1===L?ee.includes(e.value):"normal"===L&&(J?e.value>=ee[0]&&e.value<=ee[ee.length-1]:e.value<=ee[0])||"inverted"===L&&(J?e.value<=ee[0]||e.value>=ee[ee.length-1]:e.value>=ee[0]),Hg.jsxs(C.Fragment,{children:[Hg.jsx(ie,{"data-index":t,...Ee,...!isHostComponent(ie)&&{markActive:o},style:{...n,...Ee.style},className:clsx(Ee.className,o&&ne.markActive)}),null!=e.label?Hg.jsx(se,{"aria-hidden":!0,"data-index":t,...Re,...!isHostComponent(se)&&{markLabelActive:o},style:{...n,...Re.style},className:clsx(ne.markLabel,Re.className,o&&ne.markLabelActive),children:e.label}):null]},t)}),ee.map((e,t)=>{const g=valueToPercent(e,x,v),n=K[X].offset(g),C="off"===B?Forward:ae;return Hg.jsx(C,{...!isHostComponent(C)&&{valueLabelFormat:F,valueLabelDisplay:B,value:"function"==typeof F?F(N(e),t):F,index:t,open:Z===t||Q===t||"on"===B,disabled:m},...we,children:Hg.jsx(Ie,{"data-index":t,...Se,className:clsx(ne.thumb,Se.className,Q===t&&ne.active,q===t&&ne.focusVisible),style:{...n,...re(t),...Se.style},children:Hg.jsx(le,{"data-index":t,"aria-label":h?h(t):o,"aria-valuenow":N(e),"aria-labelledby":a,"aria-valuetext":y?y(N(e),t):I,value:ee[t],...ke})})},t)})]})}),resolveSliderValue$1=e=>Array.isArray(e)?e[0]??0:e,OptionsDisplayInner=()=>{const{tokens:e,updateTokens:g}=useTheme(),n=usePersistence(),[C,o]=t.useState(()=>n.get("ui")??{}),I=t.useMemo(()=>{const t=e.theme.displayFontFamily;return ce.some(({value:e})=>e===t)?ce:[{label:t,value:t},...ce]},[e.theme.displayFontFamily]),handleUiToggle=(e,t)=>{const g={...C,[e]:t};n.set("ui",g),o(g)},handleDisplayFontFamily=e=>{g({theme:{displayFontFamily:e.target.value}})},handleDisplayFontSize=(e,t)=>{g({theme:{displayFontSize:resolveSliderValue$1(t)}})};return React.createElement(En,{className:"options-display",sx:{display:"flex",flexDirection:"column",gap:1.5,p:1.5}},React.createElement(zn,{gutterBottom:!0,variant:"subtitle2"},"Main Display / Scrollback Style"),React.createElement(oC,null),React.createElement(Fo,{fullWidth:!0,size:"small"},React.createElement(AI,{id:"display-font-family-select-label"},"Font Family"),React.createElement(to,{label:"Font Family",labelId:"display-font-family-select-label",onChange:handleDisplayFontFamily,value:e.theme.displayFontFamily},I.map(e=>React.createElement(ro,{key:e.value,value:e.value},e.label)))),React.createElement(En,{sx:{display:"flex",flexDirection:"column",gap:1}},React.createElement(zn,{variant:"caption",color:"text.secondary"},"Display Font Size: ",e.theme.displayFontSize,"px"),React.createElement(ns,{"aria-label":"Display font size",max:20,min:8,onChange:handleDisplayFontSize,step:1,value:e.theme.displayFontSize})),React.createElement(oC,{sx:{mt:.5}}),React.createElement(zn,{gutterBottom:!0,variant:"subtitle2"},"Formatting"),React.createElement(Ni,{label:"Ally / Enemy Formatting",onChange:e=>handleUiToggle("allyEnemyFormatting",e),tooltip:"Apply ally and enemy markers to recognised player names in panels and game output.",tooltipMode:"title",value:Boolean(C.allyEnemyFormatting)}),React.createElement(Ni,{label:"Target Formatting",onChange:e=>handleUiToggle("targetFormatting",e),tooltip:"Highlight your current target in game output.",tooltipMode:"title",value:Boolean(C.targetFormatting)}))};OptionsDisplayInner.displayName="OptionsDisplayInner";const OptionsDisplay=()=>React.createElement(Ln,{panelName:"Options Display"},React.createElement(OptionsDisplayInner,null));OptionsDisplay.displayName="OptionsDisplay";const As=Object.freeze([{key:"showCombatStream",label:"Combat Stream",tooltip:"Route combat messages to a separate stream panel."},{key:"showSystemStream",label:"System Stream",tooltip:"Route system messages to a separate stream panel."},{key:"damageNumbers",label:"Damage Numbers",tooltip:"Show damage number overlays on combat output."},{key:"msgReplace",label:"Message Replace",tooltip:"Apply structured replacement rows for skill actions (nexSkillMatch / nexSkillNpcMatch). Inline name highlighting is controlled separately by the Ally/Enemy Formatting toggle."}]),useGameOptionToggles=()=>{const{stores:e}=useNexGui(),g=e.ui(e=>e.settings),n=e.ui(e=>e.setSetting);return t.useMemo(()=>As.map(e=>({key:e.key,label:e.label,tooltip:e.tooltip,value:Boolean(g[e.key]),onChange:t=>n(e.key,t)})),[n,g])},Cs=Object.freeze([{key:"echo_input",label:"Echo Input",tooltip:"Mirror your typed commands into the game output stream.",setValue:(e,t)=>{e.setSetting("echo_input",t)}},{key:"echo_gmcp",label:"Display GMCP",tooltip:"Show inbound GMCP payloads in the output stream.",setValue:(e,t)=>{e.setSetting("echo_gmcp",t)}},{key:"single_prompt",label:"Single Prompt",tooltip:"Collapse the duplicate Nexus prompt line into a single prompt.",setValue:(e,t)=>{e.setSetting("show_prompts",!t)}},{key:"show_timestamps",label:"Display Timestamps",tooltip:"Show Nexus timestamps in the main output stream.",setValue:(e,t)=>{e.setSetting("show_timestamps",t)}},{key:"display_tabstrip",label:"Display Tabstrip",tooltip:"Show the FlexLayout tab strip for docked Nexus tabs.",setValue:(e,t)=>{e.updateLayoutAttributes({tabSetEnableTabStrip:t})}}]),useHostSettingsToggles=()=>{const{eventBus:e,hostSettingsModel:g,hostLayoutModel:n}=useNexGui(),C=useHostBridge(),o=t.useSyncExternalStore(g.subscribe,g.getSnapshot),I=t.useSyncExternalStore(n.subscribe,n.getSnapshot),a=t.useCallback(({key:t,setValue:g},n)=>{g(C,n),e.emit(L.HOST_SETTINGS_CHANGED,{key:t,value:n})},[e,C]);return t.useMemo(()=>Cs.map(e=>({key:e.key,label:e.label,tooltip:e.tooltip,value:"display_tabstrip"===e.key?Boolean(I.display_tabstrip):Boolean(o[e.key]),onChange:t=>a(e,t)})),[o,I,a])},OptionsGameInner=()=>{const e=useHostSettingsToggles(),t=useGameOptionToggles();return React.createElement(En,{className:"options-game",sx:{display:"flex",flexDirection:"column",gap:.5,p:1.5}},React.createElement(zn,{gutterBottom:!0,variant:"subtitle2"},"Game Options"),React.createElement(oC,{sx:{mb:1}}),React.createElement(En,{sx:{columnGap:3,display:"grid",gridTemplateColumns:{xs:"minmax(0, 1fr)",md:"repeat(2, minmax(0, 1fr))"},rowGap:1.5}},React.createElement(En,{sx:{display:"flex",flexDirection:"column",gap:.5,minWidth:0}},React.createElement(zn,{gutterBottom:!0,variant:"subtitle2"},"Nexus Config"),e.map(({key:e,label:t,tooltip:g,value:n,onChange:C})=>React.createElement(Ni,{key:e,label:t,onChange:C,tooltip:g,tooltipMode:"title",value:n}))),React.createElement(En,{sx:{display:"flex",flexDirection:"column",gap:.5,minWidth:0}},React.createElement(zn,{gutterBottom:!0,variant:"subtitle2"},"nexGui Config"),t.map(({key:e,label:t,tooltip:g,value:n,onChange:C})=>React.createElement(Ni,{key:e,label:t,onChange:C,tooltip:g,tooltipMode:"title",value:n})))))};OptionsGameInner.displayName="OptionsGameInner";const OptionsGame=()=>React.createElement(Ln,{panelName:"Options Game"},React.createElement(OptionsGameInner,null));OptionsGame.displayName="OptionsGame";const os="__none__",Is="__custom__",resolveSliderValue=e=>Array.isArray(e)?e[0]??0:e,OptionsStyleInner=()=>{const{tokens:e,updateTokens:t}=useTheme(),g=canonicalizeBackgroundImageValue(e.theme.backgroundImage),n=vt.includes(g)?g:g?Is:os,handleFontSize=(e,g)=>{t({theme:{fontSize:resolveSliderValue(g)}})},handleOpacity=(e,g)=>{t({theme:{backgroundOpacity:resolveSliderValue(g)}})},handleHue=(e,g)=>{t({theme:{hue:resolveSliderValue(g)}})},handleCustomBgImage=e=>{t({theme:{backgroundImage:e.target.value}})},handleBackgroundImageSelect=e=>{const{value:g}=e.target;g!==os?g!==Is?t({theme:{backgroundImage:g}}):n!==Is&&t({theme:{backgroundImage:""}}):t({theme:{backgroundImage:""}})};return React.createElement(En,{className:"options-style",sx:{display:"flex",flexDirection:"column",gap:1.5,p:1.5}},React.createElement(zn,{gutterBottom:!0,variant:"subtitle2"},"Panel Display Style"),React.createElement(oC,null),React.createElement(En,{sx:{display:"flex",flexDirection:"column",gap:1}},React.createElement(zn,{variant:"caption",color:"text.secondary"},"Panel Font Size: ",e.theme.fontSize,"px"),React.createElement(ns,{"aria-label":"Panel font size",max:20,min:8,onChange:handleFontSize,step:1,value:e.theme.fontSize})),React.createElement(En,{sx:{display:"flex",flexDirection:"column",gap:1}},React.createElement(zn,{variant:"caption",color:"text.secondary"},"Background Opacity: ",Math.round(100*e.theme.backgroundOpacity),"%"),React.createElement(ns,{"aria-label":"Background opacity",max:1,min:0,onChange:handleOpacity,step:.01,value:e.theme.backgroundOpacity})),React.createElement(En,{sx:{display:"flex",flexDirection:"column",gap:1}},React.createElement(zn,{variant:"caption",color:"text.secondary"},"Hue Shift: ",e.theme.hue,"°"),React.createElement(ns,{"aria-label":"Hue shift",max:360,min:0,onChange:handleHue,step:1,value:e.theme.hue})),React.createElement(Fo,{fullWidth:!0,size:"small"},React.createElement(AI,{id:"background-image-select-label"},"Background Image"),React.createElement(to,{label:"Background Image",labelId:"background-image-select-label",onChange:handleBackgroundImageSelect,value:n},React.createElement(ro,{value:os},"None"),vt.map(e=>React.createElement(ro,{key:e,value:e},e)),React.createElement(ro,{value:Is},"Custom URL"))),React.createElement(lI,{InputLabelProps:{shrink:!0},fullWidth:!0,label:"Background Image URL",onChange:handleCustomBgImage,placeholder:"https://...",size:"small",value:e.theme.backgroundImage,variant:"outlined"}))};OptionsStyleInner.displayName="OptionsStyleInner";const OptionsStyle=()=>React.createElement(Ln,{panelName:"Options Panels"},React.createElement(OptionsStyleInner,null));OptionsStyle.displayName="OptionsStyle";const as="options",ss=Object.freeze([{content:React.createElement(OptionsGame,null),id:"game",label:"Game"},{content:React.createElement(OptionsStyle,null),id:"style",label:"Panels"},{content:React.createElement(OptionsDisplay,null),id:"display",label:"Display"},{content:React.createElement(OptionsAdvanced,null),id:"advanced",label:"Advanced"}]),resolveActiveTabId=e=>"string"==typeof e?e:"number"==typeof e?ss[e]?.id??ss[0].id:ss[0].id,OptionsPanelInner=()=>{const e=useTheme(),{activeTab:t,setActiveTab:g}=useUi(),n=e.theme?.nexGui?.backgroundImage??"",C=e.theme?.nexGui?.backgroundOpacity??.5,o=e.theme?.nexGui?.backgroundFilter??"none",handleTabChange=e=>{const t=ss.findIndex(t=>t.id===e);t>=0&&g(as,t)};return React.createElement(Ha,{activeTab:resolveActiveTabId(t[as]),backgroundFilter:o,backgroundImage:n,backgroundOpacity:C,onTabChange:handleTabChange,tabs:ss})};OptionsPanelInner.displayName="OptionsPanelInner";const OptionsPanel=()=>React.createElement(Ln,{panelName:"Options"},React.createElement(OptionsPanelInner,null));OptionsPanel.displayName="OptionsPanel";const PartyMemberRowComponent=({name:e,color:t="text.primary",disabled:g=!1,onClick:n=null})=>{const C="function"==typeof n&&!g;return React.createElement(En,{className:"party-member-row",onClick:C?()=>n(e):void 0,role:C?"button":void 0,sx:{alignItems:"center",cursor:C?"pointer":"default",display:"flex",minHeight:24,px:.5},tabIndex:C?0:void 0},React.createElement(zn,{component:"span",sx:{color:t,fontWeight:500,lineHeight:1.35},variant:"body2"},e))};PartyMemberRowComponent.displayName="PartyMemberRow",PartyMemberRowComponent.propTypes={color:Fg.string,disabled:Fg.bool,name:Fg.string.isRequired,onClick:Fg.func};const ls=t.memo(PartyMemberRowComponent);ls.displayName="PartyMemberRow",ls.propTypes=PartyMemberRowComponent.propTypes;const selectPartySlice=e=>({members:e.members,leader:e.leader,selfName:e.selfName,settings:e.settings,updateParty:e.updateParty,addMember:e.addMember,removeMember:e.removeMember,setLeader:e.setLeader,setSelf:e.setSelf,setSetting:e.setSetting}),useParty=()=>{const{stores:e}=useNexGui();return e.party(useShallow(selectPartySlice))},noopSubscribe=()=>()=>{},fallbackFalse=()=>!1,fallbackNull=()=>null,fallbackName=()=>"",fallbackColor=()=>"grey",getModelVersion=e=>"function"==typeof e?.getVersion?e.getVersion():0,createDirectoryBinding=(e,t)=>{const subscribe=g=>{const n=e?.subscribePlayerDirectory?.(g)??noopSubscribe(),C=t?.subscribePlayerRelationships?.(g)??noopSubscribe();return()=>{n?.(),C?.()}},getSnapshot=()=>`${getModelVersion(e)}:${getModelVersion(t)}`;return Object.freeze({getSnapshot,subscribe})},usePlayerDirectory=()=>{const{playerDirectory:e,playerRelationships:g}=useNexGui(),n=t.useMemo(()=>createDirectoryBinding(e,g),[e,g]),C=t.useSyncExternalStore(n.subscribe,n.getSnapshot,n.getSnapshot);return t.useMemo(()=>Object.freeze({version:C,getPlayerColor:e?.getPlayerColor?.bind(e)??fallbackColor,getPlayerProfile:e?.getPlayerProfile?.bind(e)??fallbackNull,isAllyPlayer:g?.isAllyPlayer?.bind(g)??fallbackFalse,isCityEnemyPlayer:g?.isCityEnemyPlayer?.bind(g)??fallbackFalse,isEnemyPlayer:g?.isEnemyPlayer?.bind(g)??fallbackFalse,resolvePlayerNameFromFullname:e?.resolvePlayerNameFromFullname?.bind(e)??fallbackName}),[e,g,C])},usePartyViewModel=()=>{const e=usePlayerDirectory(),{members:g,leader:n,selfName:C,settings:o,setLeader:I,addMember:a,removeMember:i,setSetting:s}=useParty();return t.useMemo(()=>{e.version;const t=g.map(t=>({color:e.getPlayerColor(t),disabled:t===C,name:t})),l=g.map(t=>({color:e.getPlayerColor(t),name:t})),c=F.map(({key:e,label:t,tooltip:g})=>({key:e,label:t,tooltip:g,value:Boolean(o?.[e]),onChange:t=>s(e,t)}));return{addMember:a,leader:n&&g.includes(n)?n:"",leaderColor:n?e.getPlayerColor(n):null,leaderOptions:l,memberRows:t,members:g,removeMember:i,selfName:C,setLeader:I,toggles:c}},[a,n,g,e,i,C,I,s,o])},getFlipTransform$4=e=>{switch(e){case 1:return"scaleX(-1) scaleY(-1)";case 2:return"scaleY(-1)";case 3:return"scaleX(-1)";default:return"none"}},PartyPanelInner=()=>{const e=useTheme$1(),[g]=t.useState(()=>Math.floor(4*Math.random())),[n,C]=t.useState(""),{addMember:o,leader:I,leaderColor:a,leaderOptions:i,memberRows:s,members:l,removeMember:c,setLeader:u,toggles:d}=usePartyViewModel(),p=e?.nexGui?.backgroundImage??"",m=e?.nexGui?.backgroundOpacity??.5,h=e?.nexGui?.backgroundFilter??"none",y=t.useCallback(e=>{"Enter"===e.key&&n.trim()&&(o(n.trim()),C(""))},[o,n]);return React.createElement(En,{className:"party-panel",sx:{height:"100%",overflow:"hidden",position:"relative",width:"100%"}},p?React.createElement(En,{"aria-hidden":"true",className:"party-panel__background",sx:{backgroundImage:`url(${p})`,backgroundPosition:"center",backgroundSize:"cover",filter:h,inset:0,opacity:m,position:"absolute",transform:getFlipTransform$4(g),zIndex:0}}):null,React.createElement(En,{className:"party-panel__content",sx:{background:`linear-gradient(180deg, ${alpha("#050505",.28)} 0%, ${alpha("#050505",.56)} 100%)`,display:"grid",gridTemplateColumns:"1fr 1fr",gap:2,height:"100%",overflowY:"auto",p:1.25,position:"relative",width:"100%",zIndex:1}},React.createElement(En,{sx:{display:"flex",flexDirection:"column",gap:.5,minWidth:0}},React.createElement(lI,{label:"Add member",onChange:e=>C(e.target.value),onKeyDown:y,size:"small",sx:{mb:.5,width:"15ch"},value:n}),React.createElement(zn,{component:"span",sx:{color:"text.secondary",fontSize:11,fontWeight:700,letterSpacing:.4,pb:.25,textTransform:"uppercase"}},"Party Members"),l.length>0?s.map(e=>React.createElement(ls,{color:e.color,disabled:e.disabled,key:e.name,name:e.name,onClick:c})):React.createElement(zn,{color:"text.secondary",variant:"body2"},"No party members")),React.createElement(En,{sx:{display:"flex",flexDirection:"column",gap:1}},React.createElement(Fo,{fullWidth:!0,size:"small"},React.createElement(AI,{id:"nexgui4-party-leader-label"},"Party Leader"),React.createElement(to,{disabled:0===l.length,label:"Party Leader",labelId:"nexgui4-party-leader-label",onChange:e=>u(e.target.value),sx:{color:a??"text.primary",minWidth:"18ch"},value:I},i.map(e=>React.createElement(ro,{key:e.name,sx:{color:e.color},value:e.name},e.name)))),React.createElement(oC,{sx:{my:.5}}),React.createElement(zn,{component:"span",sx:{color:"text.secondary",fontSize:11,fontWeight:700,letterSpacing:.4,textTransform:"uppercase"}},"Party Behaviour"),d.map(({key:e,label:t,tooltip:g,value:n,onChange:C})=>React.createElement(Ni,{key:e,label:t,onChange:C,tooltip:g,value:n})))))};PartyPanelInner.displayName="PartyPanelInner";const PartyPanel=()=>React.createElement(Ln,{panelName:"Party"},React.createElement(PartyPanelInner,null));PartyPanel.displayName="PartyPanel";const cs={color:Fg.string.isRequired,isAlly:Fg.bool,isEnemy:Fg.bool,isTarget:Fg.bool,name:Fg.string.isRequired},us=Fg.exact(cs),RoomPlayerRowComponent=({onHover:e,onLeave:t,onSelect:g,player:n})=>{const C=n.isEnemy?"#ff0000":"#ffffff",o=n.isAlly||n.isEnemy;return React.createElement(En,{className:"room-player-row",onClick:()=>g(n.name),onMouseEnter:e,onMouseLeave:t,sx:{alignItems:"center",cursor:"pointer",display:"inline-flex",gap:.125,margin:"2px 4px",minHeight:e=>`${Number(e.typography.fontSize)+8}px`,outline:n.isTarget?"1px solid red":"",px:.25,py:.125,position:"relative",zIndex:1}},o?React.createElement(zn,{component:"span",sx:{color:C,fontWeight:700},variant:"body2"},"("):null,React.createElement(zn,{component:"span",sx:{color:n.color,fontWeight:700},variant:"body2"},n.name),o?React.createElement(zn,{component:"span",sx:{color:C,fontWeight:700},variant:"body2"},")"):null)};RoomPlayerRowComponent.displayName="RoomPlayerRow",RoomPlayerRowComponent.propTypes={onHover:Fg.func.isRequired,onLeave:Fg.func.isRequired,onSelect:Fg.func.isRequired,player:us.isRequired};const ds=t.memo(RoomPlayerRowComponent);ds.displayName="RoomPlayerRow",ds.propTypes=RoomPlayerRowComponent.propTypes;const ps=new Set(["regex","user","time","loaded"]),formatCellValue=e=>Array.isArray(e)?e.join(", "):null!==e&&"object"==typeof e?JSON.stringify(e):String(e),ms=Fg.objectOf(Fg.oneOfType([Fg.string,Fg.number,Fg.bool,Fg.array,Fg.object])),PlayerPopoverComponent=({anchorEl:e=null,onClose:g,player:n})=>{const C=t.useMemo(()=>Object.entries(n??{}).flatMap(([e,t])=>ps.has(e)||null==t?[]:React.createElement("tr",{key:e},React.createElement("td",{style:{color:"cyan",padding:"0 5px 0 2px"}},e),React.createElement("td",{style:{padding:0}},formatCellValue(t)))),[n]);return n?React.createElement(GA,{anchorEl:e,anchorOrigin:{horizontal:"left",vertical:"top"},disableRestoreFocus:!0,onClose:g,open:Boolean(e),sx:{pointerEvents:"none"},slotProps:{paper:{sx:{backgroundColor:"#000000",border:"1px solid #ffffff"}}},transformOrigin:{horizontal:"right",vertical:"bottom"}},React.createElement("table",{style:{background:"black",borderSpacing:"0px",fontSize:"13px",margin:"10px",maxWidth:"100%",padding:"1px",textAlign:"left"}},React.createElement("thead",null,React.createElement("tr",null,React.createElement("th",{style:{width:"auto"}}),React.createElement("th",{style:{width:"auto"}}))),React.createElement("tbody",null,C))):null};PlayerPopoverComponent.displayName="PlayerPopover",PlayerPopoverComponent.propTypes={anchorEl:Fg.instanceOf(Element),onClose:Fg.func.isRequired,player:ms},PlayerPopoverComponent.defaultProps={player:null};const fs=t.memo(PlayerPopoverComponent);fs.displayName="PlayerPopover",fs.propTypes=PlayerPopoverComponent.propTypes;const resolvePlayerProfile=(e,t,g)=>{const n=g.getPlayerProfile(t),C=buildFallbackPlayerProfile(e,t);return mergePlayerPresentationProfile(n,C)},useRoomPlayersViewModel=()=>{const{adapter:e}=useNexGui(),{players:g}=useRoom(),{name:n,target:C}=useCharacter(),{members:o}=useParty(),I=usePlayerDirectory(),a=t.useMemo(()=>{I.version;const e=new Set((o??[]).filter(e=>"string"==typeof e&&e.length>0&&e!==n)),t=I.getPlayerProfile(n)?.city??"";return[...g??[]].map(g=>{const n=resolveRoomPlayerName(g,I);if(!n)return null;const o=resolvePlayerProfile(g,n,I),a=!0===o?.loaded,i=I.isEnemyPlayer(n),s=I.isAllyPlayer(n)||e.has(n);let l=5;return a&&(l=i?0:s?1:o.city===t?2:"garden"===o.city?3:4),{color:resolvePlayerPresentationColor({name:n,profile:o,playerDirectory:I}),isAlly:s,isEnemy:i,isTarget:n===C,loaded:a,name:n,profile:o,priority:l}}).filter(Boolean).sort((e,t)=>e.priority!==t.priority?e.priority-t.priority:e.name.localeCompare(t.name))},[o,I,g,n,C]),i=t.useCallback(t=>{e?.send?.(`settarget ${t}`)},[e]);return t.useMemo(()=>({players:a,selectPlayer:i}),[a,i])},getFlipTransform$3=e=>{switch(e){case 1:return"scaleX(-1) scaleY(-1)";case 2:return"scaleY(-1)";case 3:return"scaleX(-1)";default:return"none"}},PlayersPanelInner=()=>{const e=useTheme$1(),{players:g,selectPlayer:n}=useRoomPlayersViewModel(),[C]=t.useState(()=>Math.floor(4*Math.random())),[o,I]=t.useState(null),[a,i]=t.useState(""),s=e?.nexGui?.backgroundImage??"",l=e?.nexGui?.backgroundOpacity??.5,c=e?.nexGui?.backgroundFilter??"none",u=a?g.find(e=>e.name===a)?.profile??null:null;t.useEffect(()=>{o&&(a&&g.some(e=>e.name===a)||(I(null),i("")))},[o,a,g]);const handleClosePopover=()=>{I(null),i("")};return 0===g.length?React.createElement(En,{className:"players-panel players-panel--empty",sx:{alignItems:"center",color:"text.secondary",display:"flex",flex:1,justifyContent:"center",p:2}},React.createElement(zn,{variant:"body2"},"No players in room")):React.createElement(En,{className:"players-panel",sx:{height:"100%",overflow:"hidden",position:"relative",width:"100%"}},s?React.createElement(En,{"aria-hidden":"true",className:"players-panel__background",sx:{backgroundImage:`url(${s})`,backgroundPosition:"center",backgroundSize:"cover",filter:c,inset:0,opacity:l,position:"absolute",transform:getFlipTransform$3(C),zIndex:0}}):null,React.createElement(En,{className:"players-panel__content",sx:{alignContent:"flex-start",background:`linear-gradient(180deg, ${alpha("#050505",.28)} 0%, ${alpha("#050505",.56)} 100%)`,color:"text.primary",display:"flex",flexDirection:"row",flexWrap:"wrap",height:"100%",overflowY:"auto",position:"relative",width:"100%",zIndex:1}},g.map((e,t)=>React.createElement(ds,{key:`${e.name}-${t}`,onHover:t=>{e.loaded?(I(t.currentTarget),i(e.name)):handleClosePopover()},onLeave:handleClosePopover,onSelect:n,player:e}))),React.createElement(fs,{anchorEl:o,onClose:handleClosePopover,player:u?.loaded?u:null}))};PlayersPanelInner.displayName="PlayersPanelInner";const PlayersPanel=()=>React.createElement(Ln,{panelName:"Players"},React.createElement(PlayersPanelInner,null));PlayersPanel.displayName="PlayersPanel";const hs="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAI0AAADUCAYAAACh36CaAAAACXBIWXMAAA7EAAAOxAGVKw4bAAA4HGlUWHRYTUw6Y29tLmFkb2JlLnhtcAAAAAAAPD94cGFja2V0IGJlZ2luPSLvu78iIGlkPSJXNU0wTXBDZWhpSHpyZVN6TlRjemtjOWQiPz4KPHg6eG1wbWV0YSB4bWxuczp4PSJhZG9iZTpuczptZXRhLyIgeDp4bXB0az0iQWRvYmUgWE1QIENvcmUgNS41LWMwMjEgNzkuMTU0OTExLCAyMDEzLzEwLzI5LTExOjQ3OjE2ICAgICAgICAiPgogICA8cmRmOlJERiB4bWxuczpyZGY9Imh0dHA6Ly93d3cudzMub3JnLzE5OTkvMDIvMjItcmRmLXN5bnRheC1ucyMiPgogICAgICA8cmRmOkRlc2NyaXB0aW9uIHJkZjphYm91dD0iIgogICAgICAgICAgICB4bWxuczp4bXA9Imh0dHA6Ly9ucy5hZG9iZS5jb20veGFwLzEuMC8iCiAgICAgICAgICAgIHhtbG5zOmRjPSJodHRwOi8vcHVybC5vcmcvZGMvZWxlbWVudHMvMS4xLyIKICAgICAgICAgICAgeG1sbnM6cGhvdG9zaG9wPSJodHRwOi8vbnMuYWRvYmUuY29tL3Bob3Rvc2hvcC8xLjAvIgogICAgICAgICAgICB4bWxuczp4bXBNTT0iaHR0cDovL25zLmFkb2JlLmNvbS94YXAvMS4wL21tLyIKICAgICAgICAgICAgeG1sbnM6c3RFdnQ9Imh0dHA6Ly9ucy5hZG9iZS5jb20veGFwLzEuMC9zVHlwZS9SZXNvdXJjZUV2ZW50IyIKICAgICAgICAgICAgeG1sbnM6d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RGVzY3JpcHRpb24+CiAgIDwvcmRmOlJERj4KPC94OnhtcG1ldGE+CiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgCjw/eHBhY2tldCBlbmQ9InciPz6NaNPuAAAAIGNIUk0AAHolAACAgwAA+f8AAIDpAAB1MAAA6mAAADqYAAAXb5JfxUYAAAVqSURBVHja7Nt/TNRlHMDxz07vjjt+DqVAHJJmYaxWkQj+GP7MCbg0c5WuNdOtVV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htcE1NOkhpc3Rvcnk+CiAgICAgICAgIDx0aWZmOk9yaWVudGF0aW9uPjE8L3RpZmY6T3JpZW50YXRpb24+CiAgICAgICAgIDx0aWZmOlhSZXNvbHV0aW9uPjk2MDAwMC8xMDAwMDwvdGlmZjpYUmVzb2x1dGlvbj4KICAgICAgICAgPHRpZmY6WVJlc29sdXRpb24+OTYwMDAwLzEwMDAwPC90aWZmOllSZXNvbHV0aW9uPgogICAgICAgICA8dGlmZjpSZXNvbHV0aW9uVW5pdD4yPC90aWZmOlJlc29sdXRpb25Vbml0PgogICAgICAgICA8ZXhpZjpDb2xvclNwYWNlPjY1NTM1PC9leGlmOkNvbG9yU3BhY2U+CiAgICAgICAgIDxleGlmOlBpeGVsWERpbWVuc2lvbj4xNDE8L2V4aWY6UGl4ZWxYRGltZW5zaW9uPgogICAgICAgICA8ZXhpZjpQaXhlbFlEaW1lbnNpb24+MjEyPC9leGlmOlBpeGVsWURpbWVuc2lvbj4KICAgICAgPC9yZGY6RGVzY3JpcHRpb24+CiAgIDwvcmRmOlJERj4KPC94OnhtcG1ldGE+CiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgCjw/eHBhY2tldCBlbmQ9InciPz5sInMIAAAAIGNIUk0AAHolAACAgwAA+f8AAIDpAAB1MAAA6mAAADqYAAAXb5JfxUYAAAllSURBVHja7N35c1X1Gcfxh8YFiMGAICBV6ajjqBSqMC6MIpZYtS5AFRRxGxF0jIBVJNYWEVyYEbHWiis6KqBCck8SQkggYYeQ5C5kRQgBk3uzkgUCJCpqPv0hEnJvbpzpdNofmvcz8/4Hzrxyzsn3fs85JsmI/p04CAQaAg2BhkBDoCECDYGGQEOgIdAQgYZAQ6Ah0BBoiEBDoCHQEGgINAQaDgKBhkBDoCHQEGiIQEOgIdAQaAg0RKAh0BBoCDQEGiLQEGj+Rw3q2WtY74jTpv0qIuKeqKjIaREREePNrLf9hwOa/+Nc7y9c8Opzj+nvL81sTV+5RP9YOFsDzoleaWb9QEPhq8v+VLVZUl1OW98WKuBN1K1jr5GZPQQa6lTA42RXeBMV8DgKeByV5cTrRGCb1JyvuCfvl5l9CBoKRVN0EswpOAlq/DpN+q5ITzw0QWY2AzTUEc22UDQBj6Py3AQdL83Ut2WbddklQwNmdhZoyCRZldsV5/ckKhycspx46Vieli+dLzOLBQ2dPNMMDnic5nBoAh5HTfvWq8qXpPMG9k8FDZkk8+92zO91Fvu7QFPhTZRqszT+luvLzex00JDVeO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zc3T1j215vOP3/mniltvvxkdDa2QpPSFp60/MhmNCPcPoqcnfOXvDrlGFOUStm7det+Pn3nUoHc70Xa2FRCEzEP1IxIpCb4iN5Lx4TF/fng0inIJgbbWGU6rGcGzrVf8SpB4PIGyUh+KPAWCLMuXn3iNKMolxIYi1TabBYeOfKEwxqDTnb+b2MjZRVEQRk42CgBjkFXFGI/Hr/bdIVmjKBptbW0V86dPuDktpbHn0yM6k9GAdFqGTqeDfuTb8RgwEoZBb9BDTUuefH6BNEXRsNvtw5KMuMNpQ3nphGgsnoSgE+XheDImKyq6+yJSe2dvymYxw2QwAIzBYjHHbTZbTLtXriiKhtfrDSuW0vWv/PvW9B1LF8pOuw1ed4EcHY6nFEVBSZFXL+p1amNbBwKdIZjtVljM1jF/WGI0inIJf/P00z87fKrtzNw5lW6mqqn3dh4cSiaT1orJpbBajaoegmA1GVHgdkJKSegKR8Z8Cng0inIZQ0NxFukbgN5g0JtNeuv8eTPMwWAIJ+vbBixWk2Iym1B/ugWrH/sRnlj71D9q14/FuP5DaVfS0NBQ9b21j7+Tjg/OuXv5IrQHe5CUJEQGoqieVoZAsAct3cP7X3rppSfnzp17TLt+LCjKFSiKoovH49a6urrZX3zxxcydO3feVVpaGjSZTGmj0Sht3Ljx+9o1+UBROESvKRyiKByiKByiKByiKByiKByiKByiKByiKByiKByiKByiKByiKByiKByiKByiKByiKByiKByiKByiKByiKByiKByiKByiKByiKByiKByiKByiKByiKByiKByiKByiKByiKByiKByiKByiKByiKByiKByiKByiKByiKByiKByiKByiKByiKByiKByiKByiKByiKByiKByiKByiKByiKByiKByiKByiKByiKByiKByiKByiKByiKByiKByiKByiKByiKByiKByiKByiKByiKByiKByiKByiKByiKByiKByiKByiKByiKByiKByiKByiKByiKByiKByiKByiKByiKByiKByiKByiKByiKByiKByiKByiKByiKByiKByiKByiKByiKByiKBz6X15rejmpXenZAAAAAElFTkSuQmCC",xs="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAI0AAADUCAYA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TlmMDEwNGZhPC9zdEV2dDppbnN0YW5jZUlEPgogICAgICAgICAgICAgICAgICA8c3RFdnQ6d2hlbj4yMDE1LTA0LTA2VDExOjM0OjUwLTA3OjAwPC9zdEV2dDp3aGVuPgogICAgICAgICAgICAgICAgICA8c3RFdnQ6c29mdHdhcmVBZ2VudD5BZG9iZSBQaG90b3Nob3AgQ0MgKFdpbmRvd3MpPC9zdEV2dDpzb2Z0d2FyZUFnZW50PgogICAgICAgICAgICAgICA8L3JkZjpsaT4KICAgICAgICAgICAgPC9yZGY6U2VxPgogICAgICAgICA8L3htcE1NOkhpc3Rvcnk+CiAgICAgICAgIDx0aWZmOk9yaWVudGF0aW9uPjE8L3RpZmY6T3JpZW50YXRpb24+CiAgICAgICAgIDx0aWZmOlhSZXNvbHV0aW9uPjk2MDAwMC8xMDAwMDwvdGlmZjpYUmVzb2x1dGlvbj4KICAgICAgICAgPHRpZmY6WVJlc29sdXRpb24+OTYwMDAwLzEwMDAwPC90aWZmOllSZXNvbHV0aW9uPgogICAgICAgICA8dGlmZjpSZXNvbHV0aW9uVW5pdD4yPC90aWZmOlJlc29sdXRpb25Vbml0PgogICAgICAgICA8ZXhpZjpDb2xvclNwYWNlPjY1NTM1PC9leGlmOkNvbG9yU3BhY2U+CiAgICAgICAgIDxleGlmOlBpeGVsWERpbWVuc2lvbj4xNDE8L2V4aWY6UGl4ZWxYRGltZW5zaW9uPgogICAgICAgICA8ZXhpZjpQaXhlbFlEaW1lbnNpb24+MjEyPC9leGlmOlBpeGVsWURpbWVuc2lvbj4KICAgICAgPC9yZGY6RGVzY3JpcHRpb24+CiAgIDwvcmRmOlJERj4KPC94OnhtcG1ldGE+CiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgCjw/eHBhY2tldCBlbmQ9InciPz7RAlCYAAAAIGNIUk0AAHolAACAgwAA+f8AAIDpAAB1MAAA6mAAADqYAAAXb5JfxUYAAA4VSURBVHja7N1peM133sfxTyyxr6XauEvV6KK01blv2g4duigdraXbRamqKkNraN3VqtYWWjVKpZZBbJkoSU72REQWiUS2k1WQiMi+nGxIIijJZx5Ezi0kabjnyTif33W9H3ia6+V//svv//2DJJS6k/RHUEKjhEYJjRIaJTRKCY0SGiU0SmiU0CglNEpolNAooVFCo5TQKKFRQqOERgmNEhr9EZTQKKFRQqOERgmNUkKjhEYJjRIaJTRKCY0SGiU0SmiU0CglNEpolNAooVFCo4RGKaFRQqOERgmNEhqlhEYJjR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+CiAgICAgICAgIDx0aWZmOlhSZXNvbHV0aW9uPjk2MDAwMC8xMDAwMDwvdGlmZjpYUmVzb2x1dGlvbj4KICAgICAgICAgPHRpZmY6WVJlc29sdXRpb24+OTYwMDAwLzEwMDAwPC90aWZmOllSZXNvbHV0aW9uPgogICAgICAgICA8dGlmZjpSZXNvbHV0aW9uVW5pdD4yPC90aWZmOlJlc29sdXRpb25Vbml0PgogICAgICAgICA8ZXhpZjpDb2xvclNwYWNlPjY1NTM1PC9leGlmOkNvbG9yU3BhY2U+CiAgICAgICAgIDxleGlmOlBpeGVsWERpbWVuc2lvbj4xNDE8L2V4aWY6UGl4ZWxYRGltZW5zaW9uPgogICAgICAgICA8ZXhpZjpQaXhlbFlEaW1lbnNpb24+MjEyPC9leGlmOlBpeGVsWURpbWVuc2lvbj4KICAgICAgPC9yZGY6RGVzY3JpcHRpb24+CiAgIDwvcmRmOlJERj4KPC94OnhtcG1ldGE+CiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgCjw/eHBhY2tldCBlbmQ9InciPz40H0NbAAAAIGNIUk0AAHolAACAgwAA+f8AAIDpAAB1MAAA6mAAADqYAAAXb5JfxUYAAAmNSURBVHja7N1pdFT1GcfxJ4IEEDyALO5LQDTUY92rtZSKLbVWLQW7HKyAIIjaWj1QBFuWFlmqFFyAlMjiOYBsmZlISFiSCAlLlplJDAbExEAyWSAbAZJAEOXXF5Bhhkms2r5ivv9zvi/nzTyfM3Pn3vu/Y5KM6NvEm0CgIdAQaAg0BBoi0BBoCDQEGgINEWgINAQaAg2Bhgg0BBoCDYGGQEOg4U0g0BBoCDQEGgINEWgINAQaAg2Bhgg0BBoCDYGGQEMEGroo0PwfVlSH9pEjO13W4emIiIih7dpdOjoysl1vBg2a1taAAQ/c+ZlzyUy5lszSzEljtWj2eH2wcNo4Bg2aC9clZrZ65sQxUuVuqT5XqsqUqrPOlTmSQYMmcN3UuVPH8nTXQqkpX9X5iSrOilOpx6lSj1M+t1NlXsdzDBo0gSs1ed3bUlO+fG6HfG6HH4y/HOcMBg2a5vXbaeNHSV/sbRnL+U+alxg0aMzM7Mqe3VKq8xPV+HlK62g8ThW7ndEMGjRmZr3HDR8s1ed+DRiXKjyOdTWedQwaNGZm9tiSua9KtdmtoinxuFTlibv7uGctgwaNmZkNj182W6rY2SKYc58075d6nFbmcTJo0JiZ2bitq+frTPmOVtGUup39fG6X+dwuBg0aMzObvDN+kb4o2d4aGle512nNMWjQ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gICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgCjw/eHBhY2tldCBlbmQ9InciPz5sHDDvAAAAIGNIUk0AAHolAACAgwAA+f8AAIDpAAB1MAAA6mAAADqYAAAXb5JfxUYAAA5iSURBVHja7N15VNT1/sfxtyxuuKfmcjNLM9NrWt2k7JjeSq2sW2l60ptWLmkuSWWW/XDJtesuKtclLME1YUDQkU1UUGCYGRaRTUBg2AeQRVDceP3+YFFkWKt7Tnxfn3Oe/3nmeDiP853v5/v9fD4jAISxxsQ/AiMaRjSMaBjRMKJhjGgY0TCiYUTDiIYxomFEw4iGEQ0jGsaI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AgICAgICAgICA8L3JkZjpsaT4KICAgICAgICAgICAgPC9yZGY6U2VxPgogICAgICAgICA8L3htcE1NOkhpc3Rvcnk+CiAgICAgICAgIDx0aWZmOk9yaWVudGF0aW9uPjE8L3RpZmY6T3JpZW50YXRpb24+CiAgICAgICAgIDx0aWZmOlhSZXNvbHV0aW9uPjk2MDAwMC8xMDAwMDwvdGlmZjpYUmVzb2x1dGlvbj4KICAgICAgICAgPHRpZmY6WVJlc29sdXRpb24+OTYwMDAwLzEwMDAwPC90aWZmOllSZXNvbHV0aW9uPgogICAgICAgICA8dGlmZjpSZXNvbHV0aW9uVW5pdD4yPC90aWZmOlJlc29sdXRpb25Vbml0PgogICAgICAgICA8ZXhpZjpDb2xvclNwYWNlPjY1NTM1PC9leGlmOkNvbG9yU3BhY2U+CiAgICAgICAgIDxleGlmOlBpeGVsWERpbWVuc2lvbj4xNDE8L2V4aWY6UGl4ZWxYRGltZW5zaW9uPgogICAgICAgICA8ZXhpZjpQaXhlbFlEaW1lbnNpb24+MjEyPC9leGlmOlBpeGVsWURpbWVuc2lvbj4KICAgICAgPC9yZGY6RGVzY3JpcHRpb24+CiAgIDwvcmRmOlJERj4KPC94OnhtcG1ldGE+CiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIAogICAgICAgICAgICAgICAgICAgICAgICAgICAgCjw/eHBhY2tldCBlbmQ9InciPz7d8hayAAAAIGNIUk0AAHolAACAgwAA+f8AAIDpAAB1MAAA6mAAADqYAAAXb5JfxUYAAAuGSURBVHja7N15cBRlHsbxHxIXCy9UEAEVXBFUxFW28EJdVlfx2AVXYLkVQdYtoKAUD3QV5VQOXYKAHEaIiBxJ92QyyYQkJARIIMn0TO6LcCTTmUlCJjMJCQn3s39wWArhSgYzw5OqbyV/JKmpqU91v9Pv+3YLAGHsUuKbwIiGEQ0jGkY0jGgYIxpGNIxoGNEwomGMaBjRMKJhRMOIhjGiYUTDiIYRDSMaRjR8ExjRMKJhRMOIhhENY0TDiIYRDSOaK/3iL/Nr1KB+grKkDk6rMqTEqk7VrYaZutUwo8RqmGbXlBH7043d63fHyKM9u13W/ycaP0QzdtjfX0NZUqDDqmbpmurSNfWgrqm1uqZW2TU1tzzduLp+T+z4Xg93v49oiEZERCa/PXg/yneixGqArqlnVZYRjtrdm9GrZ7cFREM0IiIy8vUXbShNahBNZY4ZZelG3HfPnR8QDdGIiMjwf75gQ9mOBtF48qJgt4SiY/u204iGaEREZOrEkR64LecEo2sqyjPCUb8vHj0fuHcD0RCNBAS0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QVYUBllRGGRFYZAVhUFWFAZZURhkRWGQFYVBVhQGWVEYZEVhkBWFQVYUBllRGGRFYZAVhUFWFAZZURhkRWGQFYVBVhQGWVEYZEVhkBWFQVYUBllRGGRFYZAVhUFWFAZZURhkRWGQFYVBVhQGWVEYZEVhkBWFQVYUBllRGGRFYZAVhUFWFAZZURhkRWGQFYVBVhQGWVEYZEVhkBWFQVYUBllRGGRFYZAVhUFWFAZZURhkRWGQFYVBVhQGWVEYZEVhkBWFQVYUBllRGPR/A9LPIYPjR/AAAAAASUVORK5CYII=",Ps=Object.freeze([{key:"head",label:"H:"},{key:"torso",label:"T:"},{key:"leftarm",label:"LA:"},{key:"rightarm",label:"RA:"},{key:"leftleg",label:"LL:"},{key:"rightleg",label:"RL:"}]),normalizeValue=e=>{const t=Number(e);return Number.isFinite(t)?`${Math.round(t)}`:"0"},Ns=Fg.shape({head:Fg.oneOfType([Fg.number,Fg.string]).isRequired,torso:Fg.oneOfType([Fg.number,Fg.string]).isRequired,leftarm:Fg.oneOfType([Fg.number,Fg.string]).isRequired,rightarm:Fg.oneOfType([Fg.number,Fg.string]).isRequired,leftleg:Fg.oneOfType([Fg.number,Fg.string]).isRequired,rightleg:Fg.oneOfType([Fg.number,Fg.string]).isRequired}),LimbColumnComponent=({values:e})=>React.createElement(En,{"aria-hidden":"true",className:"nexus-man__limb-column",sx:{color:"text.primary",display:"flex",flexDirection:"column",fontSize:13,lineHeight:1.5,minWidth:"8ch",width:"8ch"}},Ps.map(({key:t,label:g})=>React.createElement(En,{className:`nexus-man__limb-row nexus-man__limb-row--${t}`,key:t,sx:{display:"flex",justifyContent:"space-between",width:"8ch"}},React.createElement(zn,{component:"span",sx:{color:"text.primary",fontFamily:"inherit",fontSize:"inherit",width:"3ch"}},g),React.createElement(zn,{component:"span",sx:{color:"text.primary",fontFamily:"inherit",fontSize:"inherit",textAlign:"left",width:"5ch"}},normalizeValue(e[t])))));LimbColumnComponent.displayName="LimbColumn",LimbColumnComponent.propTypes={values:Ns.isRequired};const Os=t.memo(LimbColumnComponent);Os.displayName="LimbColumn",Os.propTypes=LimbColumnComponent.propTypes;const Ds=Object.freeze({male:Object.freeze({head:ys,torso:Ts,leftarm:vs,rightarm:Es,leftleg:Ss,rightleg:ks}),female:Object.freeze({head:hs,torso:Ms,leftarm:bs,rightarm:ws,leftleg:xs,rightleg:Rs})}),js=Object.freeze([{key:"leftleg",label:"left leg"},{key:"rightleg",label:"right leg"},{key:"torso",label:"torso"},{key:"head",label:"head"},{key:"leftarm",label:"left arm"},{key:"rightarm",label:"right arm"}]),zs=Fg.shape({percent:Fg.oneOfType([Fg.number,Fg.string]),value:Fg.oneOfType([Fg.number,Fg.string]),damagePercent:Fg.oneOfType([Fg.number,Fg.string])}),normalizeGender=e=>"string"==typeof e&&"female"===e.trim().toLowerCase()?"female":"male",normalizeAfflictions=e=>Array.isArray(e)?e.map(e=>"string"==typeof e?e.trim().toLowerCase():`${e??""}`.trim().toLowerCase()).filter(e=>e.length>0):[],toNumericValue=e=>{const t=Number(e);return Number.isFinite(t)?t:0},getLimbEntry=(e,t)=>{const g=[t];"leftarm"===t?g.push("leftArm"):"rightarm"===t?g.push("rightArm"):"leftleg"===t?g.push("leftLeg"):"rightleg"===t&&g.push("rightLeg");for(const n of g)if(e?.[n])return e[n];return{}},buildLimbValues=e=>({head:toNumericValue(getLimbEntry(e,"head").percent??getLimbEntry(e,"head").value),torso:toNumericValue(getLimbEntry(e,"torso").percent??getLimbEntry(e,"torso").value),leftarm:toNumericValue(getLimbEntry(e,"leftarm").percent??getLimbEntry(e,"leftarm").value),rightarm:toNumericValue(getLimbEntry(e,"rightarm").percent??getLimbEntry(e,"rightarm").value),leftleg:toNumericValue(getLimbEntry(e,"leftleg").percent??getLimbEntry(e,"leftleg").value),rightleg:toNumericValue(getLimbEntry(e,"rightleg").percent??getLimbEntry(e,"rightleg").value)}),getLimbState=(e,t)=>{if("torso"===t){if(e.includes("mildtrauma"))return"mild-trauma";if(e.includes("serioustrauma"))return"serious-trauma"}return e.includes(`broken${t}`)?"broken":e.includes(`damaged${t}`)?"damaged":e.includes(`mangled${t}`)?"mangled":"healthy"},getFilterReference=(e,t)=>"broken"===e?`url(#${t.yellow})`:"damaged"===e||"mild-trauma"===e?`url(#${t.orange})`:"mangled"===e||"serious-trauma"===e?`url(#${t.red})`:"",NexusManComponent=({currentAffs:e=[],gender:g="male",limbs:n={}})=>{const C=t.useId().replace(/[:]/g,""),o={yellow:`${C}-yellowShift`,orange:`${C}-orangeShift`,red:`${C}-redShift`},I=normalizeGender(g),a=Ds[I],i=normalizeAfflictions(e),s=buildLimbValues(n);return React.createElement(En,{"aria-label":"NexusMan body status display",className:"nexus-man","data-gender":I,role:"img",sx:{alignItems:"center",display:"flex",flexDirection:"row",gap:1,justifyContent:"center",width:"100%"}},React.createElement("svg",{"aria-hidden":"true",height:"0",width:"0"},React.createElement("defs",null,React.createElement("filter",{id:o.yellow},React.createElement("feColorMatrix",{type:"matrix",values:"1 0 0 0 0\r\n 0 1 0 0 0\r\n 0 0 0 0 0\r\n 0 0 0 1 0"})),React.createElement("filter",{id:o.orange},React.createElement("feColorMatrix",{type:"matrix",values:"1 1 0 0 0\r\n 0 0.45 0 0 0\r\n 0 0 0 0 0\r\n 0 0 0 1 0"})),React.createElement("filter",{id:o.red},React.createElement("feColorMatrix",{type:"matrix",values:"1 0 0 0 0\r\n 0 0 0 0 0\r\n 0 0 0 0 0\r\n 0 0 0 1 0"})))),React.createElement(En,{className:"nexus-man__figure",sx:{flex:"1 1 auto",height:"100%",maxWidth:"202px",minHeight:"120px",overflow:"hidden",position:"relative",width:"100%"}},js.map(({key:e,label:t})=>{const g=getLimbState(i,e),n=getFilterReference(g,o);return React.createElement(En,{alt:"","aria-hidden":"true",className:`nexus-man__layer nexus-man__layer--${e}`,component:"img","data-damage-state":g,"data-limb":e,key:e,src:a[e],sx:{filter:n,height:"100%",left:0,objectFit:"contain",position:"absolute",top:0,width:"100%"},title:t})})),React.createElement(Os,{values:s}))};NexusManComponent.displayName="NexusMan",NexusManComponent.propTypes={currentAffs:Fg.arrayOf(Fg.string),gender:Fg.oneOf(["male","female"]),limbs:Fg.objectOf(zs)};const Ls=t.memo(NexusManComponent);Ls.displayName="NexusMan",Ls.propTypes=NexusManComponent.propTypes;const Gs=Object.freeze(["hp","mp","ep","wp","nl"]),clamp$1=(e,t,g)=>Math.min(g,Math.max(t,e)),normalizeNumber$2=e=>{const t=Number(e);return Number.isFinite(t)?t:0},formatNumber=e=>normalizeNumber$2(e).toLocaleString(),getBaseColor=(e,t)=>e?.palette?.[t]?.main??e?.nexGui?.tokens?.game?.[t]??St.game[t],getPercentage=(e,t)=>{const g=normalizeNumber$2(e),n=normalizeNumber$2(t);return n<=0?0:clamp$1(g/n*100,0,100)},getHpColor=e=>e<=25?"#d9534f":e<=50?"#d9832e":e<=75?"#b7b33d":"#2fa35a",getGaugeColor=(e,t,g)=>"hp"===t?getHpColor(g):getBaseColor(e,t),StatBarComponent=({type:e,current:t,max:g,label:n=e.toUpperCase()})=>{const C=useTheme$1(),o=normalizeNumber$2(t),I=normalizeNumber$2(g),a=getPercentage(o,I),i=getGaugeColor(C,e,a),s=`${Math.round(a)}%`;return React.createElement(En,{className:`stat-bar stat-bar--${e}`,sx:{minWidth:0,width:"100%"}},React.createElement(En,{"aria-label":n,"aria-valuemax":100,"aria-valuemin":0,"aria-valuenow":Math.round(a),className:`stat-bar__progress stat-bar__progress--${e}`,role:"progressbar",sx:{backgroundColor:alpha(i,.14),border:`1px solid ${alpha(i,.48)}`,borderRadius:1,minHeight:22,overflow:"hidden",position:"relative",width:"100%"}},React.createElement(En,{"aria-hidden":"true",sx:{backgroundColor:i,bottom:0,left:0,opacity:.68,position:"absolute",top:0,transition:"width 180ms ease",width:`${a}%`}}),React.createElement(En,{sx:{alignItems:"center",color:"text.primary",display:"flex",gap:1,justifyContent:"space-between",minHeight:22,px:.75,position:"relative",zIndex:1}},React.createElement(zn,{component:"span",sx:{color:"text.primary",fontSize:11,fontWeight:700,letterSpacing:.5,textTransform:"uppercase"}},n),React.createElement(zn,{component:"span",sx:{color:"text.primary",fontSize:11,fontVariantNumeric:"tabular-nums",textShadow:"0 0 3px rgba(0, 0, 0, 0.85)"}},formatNumber(o)," / ",formatNumber(I)," (",s,")"))))};StatBarComponent.displayName="StatBar",StatBarComponent.propTypes={current:Fg.number.isRequired,label:Fg.string,max:Fg.number.isRequired,type:Fg.oneOf(Gs).isRequired};const Bs=t.memo(StatBarComponent);Bs.displayName="StatBar",Bs.propTypes=StatBarComponent.propTypes;const selectStatsSlice=e=>({hp:e.hp,mp:e.mp,ep:e.ep,wp:e.wp,nl:e.nl,gold:e.gold,bank:e.bank,xp:e.xp,xpToNext:e.xpToNext,target:e.target,updateStats:e.updateStats}),useStats=()=>{const{stores:e}=useNexGui();return e.stats(useShallow(selectStatsSlice))},Fs=Object.freeze([{type:"hp",label:"HP"},{type:"mp",label:"MP"},{type:"ep",label:"EP"},{type:"wp",label:"WP"},{type:"nl",label:"NL"}]),getFlipTransform$2=e=>{switch(e){case 1:return"scaleX(-1) scaleY(-1)";case 2:return"scaleY(-1)";case 3:return"scaleX(-1)";default:return"none"}},Indicator=({className:e,label:t,ready:g})=>React.createElement(En,{className:e,sx:{alignItems:"center",backgroundColor:g?"rgba(18, 42, 26, 0.82)":"rgba(24, 24, 24, 0.82)",border:"1px solid",borderColor:g?"rgba(102, 221, 144, 0.7)":"rgba(192, 176, 144, 0.22)",borderRadius:999,color:g?"#66dd90":"text.disabled",display:"inline-flex",gap:.5,px:1,py:.25}},React.createElement(En,{"aria-hidden":"true",sx:{backgroundColor:g?"#66dd90":"rgba(192, 176, 144, 0.35)",borderRadius:"50%",boxShadow:g?"0 0 8px rgba(102, 221, 144, 0.5)":"none",flexShrink:0,height:6,width:6}}),React.createElement(zn,{component:"span",sx:{color:"inherit",fontSize:11,fontWeight:700,letterSpacing:.5,textTransform:"uppercase"}},t)),StatsPanelInner=()=>{const e=useTheme$1(),[g]=t.useState(()=>Math.floor(4*Math.random())),{hp:n,mp:C,ep:o,wp:I,nl:a}=useStats(),{balance:i,currentAffs:s,equilibrium:l,gender:c,limbs:u}=useCharacter(),d=e?.nexGui?.backgroundImage??"",p=e?.nexGui?.backgroundOpacity??.5,m=e?.nexGui?.backgroundFilter??"none";return React.createElement(En,{className:"stats-panel",sx:{height:"100%",overflow:"hidden",position:"relative",width:"100%"}},d?React.createElement(En,{"aria-hidden":"true",className:"stats-panel__background",sx:{backgroundImage:`url(${d})`,backgroundPosition:"center",backgroundSize:"cover",filter:m,inset:0,opacity:p,position:"absolute",transform:getFlipTransform$2(g),zIndex:0}}):null,React.createElement(En,{className:"stats-panel__content",sx:{background:`linear-gradient(180deg, ${alpha("#050505",.3)} 0%, ${alpha("#050505",.55)} 100%)`,display:"flex",flexDirection:"column",gap:1,height:"100%",p:1,position:"relative",width:"100%",zIndex:1}},React.createElement(En,{className:"stats-panel__body",sx:{alignItems:"center",display:"flex",justifyContent:"center",minHeight:120}},React.createElement(Ls,{currentAffs:s,gender:c??"male",limbs:u})),React.createElement(En,{className:"stats-panel__indicators",sx:{display:"flex",gap:1,justifyContent:"center"}},React.createElement(Indicator,{className:"stats-panel__balance stats-panel__balance--"+(i?"ready":"waiting"),label:"Balance",ready:i}),React.createElement(Indicator,{className:"stats-panel__equilibrium stats-panel__equilibrium--"+(l?"ready":"waiting"),label:"Equilibrium",ready:l})),React.createElement(En,{className:"stats-panel__bars",sx:{display:"flex",flex:"1 1 auto",flexDirection:"column",gap:.75,justifyContent:"flex-end"}},Fs.map(({type:e,label:t})=>{const g={hp:n,mp:C,ep:o,wp:I,nl:a}[e]??{current:0,max:0};return React.createElement(Bs,{current:g.current??0,key:e,label:t,max:g.max??0,type:e})}))))};Indicator.displayName="StatsPanelIndicator",Indicator.propTypes={className:Fg.string.isRequired,label:Fg.string.isRequired,ready:Fg.bool.isRequired},StatsPanelInner.displayName="StatsPanelInner";const StatsPanel=()=>React.createElement(Ln,{panelName:"Stats"},React.createElement(StatsPanelInner,null));StatsPanel.displayName="StatsPanel";const SystemStreamInner=()=>{const{adapter:e,stores:g}=useNexGui(),{items:n,version:C}=useTranscript(g.systemStream),o=t.useCallback(t=>e.send(t),[e]);return React.createElement(_n,{itemKeyVersion:C,items:n,onSendCommand:o})};SystemStreamInner.displayName="SystemStreamInner";const SystemStream=()=>React.createElement(Ln,{panelName:"System Stream"},React.createElement(SystemStreamInner,null));SystemStream.displayName="SystemStream";const getFlipTransform$1=e=>{switch(e){case 1:return"scaleX(-1) scaleY(-1)";case 2:return"scaleY(-1)";case 3:return"scaleX(-1)";default:return"none"}},hasRenderableTarget=(e,t,g)=>Boolean(e||t||Object.keys(g?.limbs??{}).length>0||g?.currentAffs?.length>0),TargetPanelInner=()=>{const e=useTheme$1(),[g]=t.useState(()=>Math.floor(4*Math.random())),{target:n,targetDetails:C}=useCharacter(),o=e?.nexGui?.backgroundImage??"",I=e?.nexGui?.backgroundOpacity??.5,a=e?.nexGui?.backgroundFilter??"none",i=C?.name??n??null,s=C?.hpText??(null!=C?.hpPercent?`${C.hpPercent}%`:null),l=hasRenderableTarget(i,s,C);return React.createElement(En,{className:"target-panel",sx:{height:"100%",overflow:"hidden",position:"relative",width:"100%"}},o?React.createElement(En,{"aria-hidden":"true",className:"target-panel__background",sx:{backgroundImage:`url(${o})`,backgroundPosition:"center",backgroundSize:"cover",filter:a,inset:0,opacity:I,position:"absolute",transform:getFlipTransform$1(g),zIndex:0}}):null,React.createElement(En,{className:"target-panel__content",sx:{background:`linear-gradient(180deg, ${alpha("#050505",.18)} 0%, ${alpha("#050505",.36)} 100%)`,display:"flex",flexDirection:"column",height:"100%",minHeight:0,position:"relative",width:"100%",zIndex:1}},i||s?React.createElement(En,{className:"target-panel__status",sx:{px:1,pt:.5}},React.createElement(zn,{sx:{color:"text.secondary",fontSize:11,fontWeight:700,letterSpacing:.3,textShadow:"0 1px 1px rgba(0, 0, 0, 0.7)"},variant:"caption"},[i,s?`HP ${s}`:null].filter(Boolean).join(" | "))):null,React.createElement(En,{className:"target-panel__body",sx:{alignItems:"center",display:"flex",flex:1,justifyContent:"center",minHeight:0,p:1}},l?React.createElement(Ls,{currentAffs:C?.currentAffs??[],gender:C?.gender??"male",limbs:C?.limbs??{}}):null)))};TargetPanelInner.displayName="TargetPanelInner";const TargetPanel=()=>React.createElement(Ln,{panelName:"Target"},React.createElement(TargetPanelInner,null));TargetPanel.displayName="TargetPanel";const clamp=(e,t,g)=>Math.min(g,Math.max(t,e)),normalizeNumber$1=e=>{const t=Number(e);return Number.isFinite(t)?t:0},normalizeDirection=(e,t)=>"countup"===e||!1===t?"countup":"countdown",getElapsedMs=(e,t)=>Math.max(0,normalizeNumber$1(t)-normalizeNumber$1(e)),getElapsedPercentage=(e,t)=>{const g=Math.max(0,Math.abs(normalizeNumber$1(t)));return g<=0?100:clamp(e/g*100,0,100)},formatTimerValue=e=>{const t=Math.max(0,normalizeNumber$1(e))/1e3;return t<10?`${t.toFixed(1)}s`:t<=60?`${t.toFixed(0)}s`:`${Math.floor(t/60)}m ${(t%60).toFixed(0)}s`},hslToHex=(e,t=100,g=50)=>{const n=g/100,k=t=>(t+e/30)%12,C=t/100*Math.min(n,1-n),f=e=>n-C*Math.max(-1,Math.min(k(e)-3,Math.min(9-k(e),1)));return"#"+[f(0),f(8),f(4)].map(e=>Math.round(255*e).toString(16).padStart(2,"0")).join("")},getGradientColor=e=>{const t=1.2*clamp(normalizeNumber$1(e),0,100),g=e<75?50:Math.abs(e-100)/2+25;return hslToHex(t,100,g)},getProgressValue=(e,t,g)=>{const n=getElapsedPercentage(e,t);return"countup"===g?n:clamp(100-n,0,100)},TimerBarComponent=({id:e,label:t,durationMs:g,startedAt:n,elapsedMs:C=0,now:o,tickIntervalMs:I,running:a=!0,direction:i="countdown",countDown:s})=>{const l=useTheme$1(),c=Math.max(0,Math.abs(normalizeNumber$1(g))),u=normalizeDirection(i,s),d=!1!==a&&null!=n?getElapsedMs(n,o):normalizeNumber$1(C),p=clamp(d,0,c),m=getProgressValue(p,c,u),h=formatTimerValue(c-p),y=t?.trim()||e,b=getGradientColor(m),v=Math.max(22,normalizeNumber$1(l?.typography?.fontSize)+10),x=`${y} (${h})`,S=Math.max(0,normalizeNumber$1(I)),w=0===m||100===m?"none":`transform ${S}ms linear, background-color ${S}ms linear`;return React.createElement(En,{className:`timer-bar timer-bar--${u}`,"data-timer-id":e,sx:{border:"1.5px solid #aaa",borderRadius:"6px",fontSize:l.typography.fontSize,margin:"3px 0",overflow:"hidden",position:"relative",width:"100%"}},React.createElement(oa,{"aria-label":y,"aria-valuetext":x,className:`timer-bar__progress timer-bar__progress--${u}`,sx:{backgroundColor:"transparent",height:v,"& .MuiLinearProgress-bar":{backgroundColor:b,borderRadius:"4px",transition:w}},value:m,variant:"determinate"}),React.createElement(En,{sx:{alignItems:"center",color:"#FFF5D6",display:"flex",inset:0,px:1.25,pointerEvents:"none",position:"absolute"}},React.createElement(zn,{component:"span",sx:{color:"inherit",fontSize:"inherit",minWidth:0,overflow:"hidden",textOverflow:"ellipsis",textShadow:"-1px -1px 1px #000, 1px -1px 1px #000, -1px 1px 1px #000, 1px 1px 1px #000",whiteSpace:"nowrap"},variant:"body2"},x)))};TimerBarComponent.displayName="TimerBar",TimerBarComponent.propTypes={countDown:Fg.bool,direction:Fg.oneOf(["countup","countdown"]),durationMs:Fg.number.isRequired,elapsedMs:Fg.number,id:Fg.string.isRequired,label:Fg.string.isRequired,now:Fg.number.isRequired,running:Fg.bool,startedAt:Fg.number,tickIntervalMs:Fg.number.isRequired};const Ws=t.memo(TimerBarComponent);Ws.displayName="TimerBar",Ws.propTypes=TimerBarComponent.propTypes;const Vs=1e4,Ks=100,Us=500,Hs=[],normalizeNumber=e=>{const t=Number(e);return Number.isFinite(t)?t:0},isRunningTimer=e=>!1!==e?.running&&null!=e?.startedAt,getRemainingMs=(e,t)=>{const g=Math.max(0,Math.abs(normalizeNumber(e.durationMs))),n=Math.max(0,normalizeNumber(t)-normalizeNumber(e.startedAt));return Math.max(0,g-n)},getClockState=(e,t)=>{let g=1/0,n=!1;for(const C of e??[])isRunningTimer(C)&&(n=!0,g=Math.min(g,getRemainingMs(C,t)));return{isTicking:n,tickIntervalMs:n&&g<Vs?Ks:Us}},useTimerClock=(e=Hs)=>{const[g,n]=t.useState(()=>Date.now()),{isTicking:C,tickIntervalMs:o}=t.useMemo(()=>getClockState(e,g),[g,e]);return t.useEffect(()=>{if(!C)return;const tick=()=>n(Date.now());tick();const e=setInterval(tick,o);return()=>clearInterval(e)},[C,o]),t.useMemo(()=>({now:g,tickIntervalMs:o,isTicking:C}),[C,g,o])},selectTimerView=({id:e,durationMs:t,startedAt:g,label:n,direction:C,position:o,stayVisible:I,enabled:a,running:i,elapsedMs:s,remainingMs:l})=>({id:e,durationMs:t,startedAt:g,label:n,direction:C,position:o,stayVisible:I,enabled:a,running:i,elapsedMs:s,remainingMs:l}),selectTimersSlice=e=>({timerEntries:e.timers,addTimer:e.addTimer,removeTimer:e.removeTimer,clearAll:e.clearAll}),useTimers=()=>{const{stores:e}=useNexGui(),{timerEntries:g,addTimer:n,removeTimer:C,clearAll:o}=e.timers(useShallow(selectTimersSlice)),I=t.useMemo(()=>g.map(selectTimerView),[g]);return t.useMemo(()=>({timers:I,addTimer:n,removeTimer:C,clearAll:o}),[n,o,C,I])},getFlipTransform=e=>{switch(e){case 1:return"scaleX(-1) scaleY(-1)";case 2:return"scaleY(-1)";case 3:return"scaleX(-1)";default:return"none"}},normalizePosition=e=>"bottom"===e?"bottom":"top",partitionTimers=e=>e.reduce((e,t)=>(e[normalizePosition(t.position)].push(t),e),{top:[],bottom:[]}),TimersPanelInner=()=>{const e=useTheme$1(),{timers:g}=useTimers(),[n]=t.useState(()=>Math.floor(4*Math.random())),C=e?.nexGui?.backgroundImage??"",o=e?.nexGui?.backgroundOpacity??.5,I=e?.nexGui?.backgroundFilter??"none",{now:a,tickIntervalMs:i}=useTimerClock(g),{top:s,bottom:l}=t.useMemo(()=>partitionTimers(g),[g]);return React.createElement(En,{className:"timers-panel",sx:{color:"text.primary",fontFamily:e.typography.fontFamily,fontSize:e.typography.fontSize,height:"100%",overflow:"hidden",position:"relative",width:"100%"}},C?React.createElement(En,{"aria-hidden":"true",className:"timers-panel__background",sx:{backgroundImage:`url(${C})`,backgroundPosition:"center",backgroundSize:"cover",filter:I,inset:0,opacity:o,position:"absolute",transform:getFlipTransform(n),zIndex:0}}):null,React.createElement(En,{className:"timers-panel__content","data-testid":"timers-panel",sx:{display:"flex",flexDirection:"column",height:"100%",justifyContent:"space-between",overflowY:"auto",p:1,position:"relative",width:"100%",zIndex:1}},React.createElement(En,{className:"timers-panel__stack timers-panel__stack--top","data-testid":"timers-panel-top",sx:{display:"flex",flexDirection:"column"}},s.map(e=>React.createElement(Ws,{key:e.id,countDown:e.countDown,direction:e.direction,durationMs:e.durationMs,elapsedMs:e.elapsedMs,id:e.id,label:e.label,now:a,running:e.running,startedAt:e.startedAt,tickIntervalMs:i}))),React.createElement(En,{className:"timers-panel__stack timers-panel__stack--bottom","data-testid":"timers-panel-bottom",sx:{display:"flex",flexDirection:"column"}},l.map(e=>React.createElement(Ws,{key:e.id,countDown:e.countDown,direction:e.direction,durationMs:e.durationMs,elapsedMs:e.elapsedMs,id:e.id,label:e.label,now:a,running:e.running,startedAt:e.startedAt,tickIntervalMs:i})))))};TimersPanelInner.displayName="TimersPanelInner";const TimersPanel=()=>React.createElement(Ln,{panelName:"Timers"},React.createElement(TimersPanelInner,null));TimersPanel.displayName="TimersPanel";const Ys=Object.freeze(["nexTimers","nexParty","nexPlayers","nexNpcs","nexItems","nexStats","nexSystem","nexCombat","nexDefences","nexFeed","nexTarget","nexOptions","nexMetrics"]),getTabComponents=()=>({nexTimers:TimersPanel,nexParty:PartyPanel,nexPlayers:PlayersPanel,nexNpcs:NpcsPanel,nexItems:ItemsPanel,nexStats:StatsPanel,nexSystem:SystemStream,nexCombat:CombatStream,nexDefences:DefencesPanel,nexFeed:GameFeed,nexTarget:TargetPanel,nexOptions:OptionsPanel,nexMetrics:MetricsPanel}),getLayout$1=()=>nexusclient.ui().layout(),getStoredLayout=e=>nexusclient._ui?._layout??e,createTabNode=e=>({type:"tab",id:e,name:e,component:e,icon:"feather-pointed",helpText:e}),resolveContextValue=e=>{const t=e??globalThis.nexGui?.__contextValue;if(!t)throw new Error("[nexGui4] initializeTabs requires a NexGuiContext value from the active runtime.");return t},selectThemeTokens=e=>e.tokens,NexusTabRoot=({Component:e,contextValue:t})=>{const g=t.stores.theme(selectThemeTokens),n=C.useMemo(()=>createMuiTheme(g),[g]);return C.createElement(jt.Provider,{value:t},C.createElement(StyledEngineProvider,{injectFirst:!0},C.createElement(ThemeProvider,{theme:n},C.createElement(En,{className:"nexgui4-panel-root",sx:{display:"flex",flex:1,height:"100%",minHeight:0,minWidth:0,width:"100%"}},C.createElement(e)))))},registerTabFactory=(e,t,g,n)=>{e.nexoverrides[t]=e=>C.createElement(NexusTabRoot,{Component:g,contextValue:n})},generateTabs=({skipIds:e=[]}={})=>{const t=getLayout$1().flexModel,g=t.getNodeById("map");if(!g)return console.warn("[nexGui4] generateTabs(): map node not found in layout model."),[...Ys];const n=g.getParent?.()?.getId?.()||"root";return Ys.forEach(g=>{e.includes(g)||t.getNodeById(g)||t.doAction({type:"FlexLayout_AddNode",data:{json:createTabNode(g),toNode:n,location:"center"}})}),[...Ys]},mountNativeDisplay=({contextValue:e}={})=>{const t=resolveContextValue(e),g=getLayout$1();void 0===g.nexoverrides&&(g.nexoverrides={}),g.nexoverrides.output_main=e=>C.createElement(NexusTabRoot,{Component:MainDisplay,contextValue:t});try{nexusclient.buffer().limit=100}catch{}},unmountNativeDisplay=()=>{const e=getLayout$1();delete e?.nexoverrides?.output_main;try{nexusclient.buffer().limit=0}catch{}},initializeTabs=({contextValue:e}={})=>{const t=resolveContextValue(e),g=getLayout$1(),n=getStoredLayout(g),C=g.flexModel;return void 0===g.get_tab_object_original&&(g.get_tab_object_original=g.get_tab_object),void 0===n.get_tab_object_original&&(n.get_tab_object_original=g.get_tab_object_original),void 0===g.nexoverrides&&(g.nexoverrides={}),Object.entries(getTabComponents()).forEach(([e,n])=>{registerTabFactory(g,e,n,t)}),g.get_tab_object=function(e,t){return this.nexoverrides[e]?this.nexoverrides[e](t):nexusclient._ui._layout.get_tab_object_original(e,t)},C.doAction({data:{tabNode:"map"},type:"FlexLayout_SelectTab"}),g.nexoverrides},Zs="nexGuiLayout",getLayout=()=>nexusclient.ui().layout(),setModelPreservingGlobal=({layout:e,borders:t})=>{const g=getLayout(),n=g.flexModel.toJson();g.set_model({global:n.global,borders:t,layout:e})},applyLayoutPreset=e=>{const t=getLayoutPreset(e);return!!t&&(setModelPreservingGlobal(t),!0)},saveCurrentLayout=()=>{const e=getLayout().model();return nexusclient.variables().vars[Zs]={layout:JSON.stringify(e.layout),borders:JSON.stringify(e.borders)},!0},readSavedLayout=()=>{const e=nexusclient.variables?.()?.vars?.[Zs];if(!e?.layout||!e?.borders)return null;try{return{layout:JSON.parse(e.layout),borders:JSON.parse(e.borders)}}catch{return null}},hasSavedLayout=()=>null!==readSavedLayout(),restoreSavedLayout=()=>{const e=readSavedLayout();return!!e&&(setModelPreservingGlobal(e),!0)},getRawText=e=>e?"function"==typeof e.parsed_line?.text?e.parsed_line.text():"string"==typeof e.line?e.line:"":"",getFormattedHtml=e=>e?"function"==typeof e.parsed_line?.formatted?e.parsed_line.formatted():getRawText(e):"",patchFormatted=(e,t)=>{e?.parsed_line&&"object"==typeof e.parsed_line&&(e.parsed_line.formatted=()=>t)},createIconRenderer=()=>{const e=createMessageReplacementContext();return t=>buildIconHtml(t.id,t.colors,t.size,e.icons.dualTone)},lineContains=(e,t)=>!!getRawText(e).includes(t)||!("string"!=typeof e?.line||!e.line.includes(t)),findBlockIndex=(e,t)=>e.findIndex(e=>lineContains(e,t)),applyRoomReplacements=e=>{if(!Array.isArray(e)||0===e.length)return;const t=findBlockIndex(e,"<RName");if(t<0)return;const g=e[t],n=e[t+1];if(!n)return;const C=getFormattedHtml(n),o=createIconRenderer(),I=replaceRoomText(C,{iconRenderer:o});if(I!==C&&patchFormatted(n,I),(getRawText(g)||getFormattedHtml(g)).includes("Flying above"))return;const a=globalThis.nexMap;if(!a?.status?.loaded)return;const i=findBlockIndex(e,"<RExits");if(i<0)return;const s=globalThis.GMCP?.Room?.Info?.num;if(!s)return;const l="function"==typeof a.warpTarget?a.warpTarget(s):null;if(!l)return;const c=createWormholeExitDescriptor({warp:l,currentArea:a.status?.currentArea});if(!c)return;const u=e[i];let d=getFormattedHtml(u);d=d.replace(" and",""),d=d.replace(".",renderWormholeExitHtml(c)),patchFormatted(u,d)},registerEvents=e=>{const t=[];return((e,g,n={})=>{const C=`nexGui4-${e.replace(/\W+/g,"-")}`;eventStream.registerEvent(e,g,{...n,id:C,tags:["nexGui4"]}),t.push({eventName:e,id:C})})("Room.Info",e=>{nexAction.triggers.enable("nexGui4.roomReplacements")}),()=>{t.forEach(({eventName:e,id:t})=>{eventStream.removeListener?.(e,t)})}},safeCall$2=(e,t,...g)=>"function"==typeof e?e.call(t,...g):void 0,getHostLineText=e=>e&&"object"==typeof e?e.parsed_line?safeCall$2(e.parsed_line.text,e.parsed_line)??"":"string"==typeof e.line?e.line:e.html_line&&"string"==typeof e.html_text?stripHtml(e.html_text):"":"",isLikelyPartyName=e=>/^[A-Za-z][A-Za-z'-]*$/.test(e),normalizePartyMembersLine=e=>e.replace(/\.$/,"").split(", ").map(e=>e.trim()).filter(Boolean),extractRealmPartyMembers=(e,t)=>e.map(e=>t?.resolvePlayerNameFromFullname?.(e)).filter(isLikelyPartyName),resolvePlayerRelationships=e=>e?.playerRelationships??getDefaultPlayerRelationshipsModel(),registerTriggers=e=>{const t=resolvePlayerRelationships(e);return nexAction.triggers.add({id:"nexGui4.party.chatGag",regex:/^\(Party\): \w+ says, ".+"$/,tags:["nexGui4"],action:()=>{const t=e?.stores?.party?.getState?.()??null;t?.settings?.gagChat&&(nexusclient.current_line.gag=!0)}}),nexAction.triggers.add({id:"nexGui4.party.memberJoined",regex:/^\(Party\): (\w+) has joined your party\.$/,tags:["nexGui4"],action:t=>{const g=e?.stores?.party?.getState?.()??null;g?.addMember?.(t[1])}}),nexAction.triggers.add({id:"nexGui4.party.memberLeft",regex:/^\(Party\): (\w+) has left your party\.$/,tags:["nexGui4"],action:t=>{const g=e?.stores?.party?.getState?.()??null;g?.removeMember?.(t[1])}}),nexAction.triggers.add({id:"nexGui4.party.listHeader",regex:"Your party has the following members:",tags:["nexGui4"],action:()=>{const t=e?.stores?.party?.getState?.()??null,g=nexusclient.current_block??[],n=g.indexOf(nexusclient.current_line);if(n<0)return;const C=g[n+2],o=getHostLineText(C);t?.updateParty?.(normalizePartyMembersLine(o))}}),nexAction.triggers.add({id:"nexGui4.party.realmsHeader",regex:"The following members of your party are in the realms:",tags:["nexGui4"],action:()=>{const t=e?.stores?.party?.getState?.()??null,g=nexusclient.current_block??[],n=g.indexOf(nexusclient.current_line);if(n<0)return;const C=g.slice(n+1).map(getHostLineText);t?.updateParty?.(extractRealmPartyMembers(C,e?.playerDirectory))}}),nexAction.triggers.add({id:"nexGui4.party.noParty",regex:"You are not the member of any party",tags:["nexGui4"],action:()=>{const t=e?.stores?.party?.getState?.()??null;t?.updateParty?.([])}}),nexAction.triggers.add({id:"nexGui4.party.leftParty",regex:"You have left your party",tags:["nexGui4"],action:()=>{const t=e?.stores?.party?.getState?.()??null;t?.updateParty?.([])}}),nexAction.triggers.add({id:"nexGui4.party.joinedParty",regex:/^You have joined \w+'s party\.$/,tags:["nexGui4"],action:()=>{e?.adapter?.send?.("party members")}}),nexAction.triggers.add({id:"nexGui4.rel.cityEnemiesHeader",regex:/^Enemies of .+ of \w+:$/,tags:["nexGui4"],action:()=>{const e=nexusclient.current_block??[],g=e.indexOf(nexusclient.current_line);if(g<0)return;const n=e[g+1],C=getHostLineText(n).replaceAll(" ","").split(",").map(e=>e.trim()).filter(isLikelyPartyName);t.replaceCityEnemyPlayers(C)}}),nexAction.triggers.add({id:"nexGui4.rel.enemiesHeader",regex:"You have the following enemies:",tags:["nexGui4"],action:()=>{const e=nexusclient.current_block??[],g=e.indexOf(nexusclient.current_line);if(g<0)return;const n=e.slice(g).map(getHostLineText),C=[];for(let t=1;t<n.length-1;t+=1){const e=n[t];e&&!e.includes(" ")&&C.push(e)}t.replaceEnemyPlayers(C.filter(isLikelyPartyName))}}),nexAction.triggers.add({id:"nexGui4.rel.noEnemies",regex:"You have no enemies.",tags:["nexGui4"],action:()=>{t.replaceEnemyPlayers([])}}),nexAction.triggers.add({id:"nexGui4.rel.noEnemiesForgive",regex:"In a moment of forgiveness, you declare that you have no enemies.",tags:["nexGui4"],action:()=>{t.replaceEnemyPlayers([])}}),nexAction.triggers.add({id:"nexGui4.rel.enemyRemoved",regex:/^You declare that (\w+) will no longer be one of your enemies\.$/,tags:["nexGui4"],action:e=>{t.forgetEnemyPlayer(e[1])}}),nexAction.triggers.add({id:"nexGui4.rel.enemyAdded",regex:/^(\w+) is now one of your enemies\.$/,tags:["nexGui4"],action:e=>{t.rememberEnemyPlayer(e[1])}}),nexAction.triggers.add({id:"nexGui4.rel.alliesHeader",regex:"You have the following allies:",tags:["nexGui4"],action:()=>{const e=nexusclient.current_block??[],g=e.indexOf(nexusclient.current_line);if(g<0)return;const n=e.slice(g).map(getHostLineText),C=[];for(let t=1;t<n.length-1;t+=1){const e=n[t];if(!e)continue;if(e.includes("You have"))break;let g;g=e.includes("lust")?e.split(" ")[7]?.trim():e.split(" ")[0]?.trim(),isLikelyPartyName(g)&&C.push(g)}t.replaceAllyPlayers(C)}}),nexAction.triggers.add({id:"nexGui4.rel.allyRemoved",regex:/^You declare that (\w+) will no longer be one of your allies\.$/,tags:["nexGui4"],action:e=>{t.forgetAllyPlayer(e[1])}}),nexAction.triggers.add({id:"nexGui4.rel.allyAdded",regex:/^(\w+) is now one of your allies\.$/,tags:["nexGui4"],action:e=>{t.rememberAllyPlayer(e[1])}}),nexAction.triggers.add({id:"nexGui4.roomReplacements",regex:/^/,tags:["nexGui4"],action:()=>{applyRoomReplacements(nexusclient.current_block??[]),nexAction.triggers.disable("nexGui4.roomReplacements")},enabled:!1}),()=>{nexAction.triggers.remove(["nexGui4"])}},Qs="scrollback",Xs="__nexGuiInlineHighlightingContext",qs="__nexGuiInitialHostBufferSynced";let Js=null,$s=null;const getRuntime=()=>globalThis.nexGui??null,getContextValue=e=>e??getRuntime()?.__contextValue??null,getUiStoreState=e=>e?.stores?.ui?.getState?.()??null,getStreamModel=e=>e?.streamModel??e?.stores?.stream??null,getScrollbackSession=e=>e?.scrollbackSession??null,getUiSettings=e=>e?.persistenceStore?.getAll?.()?.ui??{},formatTimestamp=(e=!1,t=Date.now())=>{const g=new Date(t),n=String(g.getHours()).padStart(2,"0"),C=String(g.getMinutes()).padStart(2,"0"),o=String(g.getSeconds()).padStart(2,"0");return e?`${n}:${C}:${o}.${String(g.getMilliseconds()).padStart(3,"0")}`:`${n}:${C}:${o}`},safeCall$1=(e,t,...g)=>"function"==typeof e?e.call(t,...g):void 0,readRuntimeInlineHighlightingContext=e=>e?.[Xs]??e?.__contextValue??null,writeRuntimeInlineHighlightingContext=(e,t)=>{if(!e||"object"!=typeof e)return;const g=readRuntimeInlineHighlightingContext(e);Object.is(g,t)||(g&&g!==t&&clearRelationshipNameFormatterCache(g),Object.prototype.hasOwnProperty.call(e,Xs)?e[Xs]=t:Object.defineProperty(e,Xs,{value:t,writable:!0,enumerable:!1,configurable:!0}))},ensureRuntimeColors=e=>{const t=getRuntime();if(!t)return{inLineHighlighting:t=>applyContextInlineNameHighlighting(t,{contextValue:e})};if(writeRuntimeInlineHighlightingContext(t,e),t.colors&&"function"==typeof t.colors.inLineHighlighting)return t.colors;const g=Object.freeze({inLineHighlighting:e=>applyContextInlineNameHighlighting(e,{contextValue:readRuntimeInlineHighlightingContext(t)})});return Object.defineProperty(t,"colors",{value:g,enumerable:!1,configurable:!0}),g},toArray=e=>Array.isArray(e)?e:[],createExtraBreakLine=()=>({html:"<span> </span>",timestamp:Date.now(),isPrompt:!1,isMonospace:!1,shouldLog:!1,buffer:"main"}),getCurrentPromptHtml=e=>{const t=getStreamModel(e)?.getSnapshot?.()?.promptLine;return"string"==typeof t?.html?t.html:null},convertHostLine=(e,t="main",g=null)=>{if(!e||"object"!=typeof e)return null;if(e.html_line&&"string"==typeof e.html_text&&e.html_text.length>0)return e.gag?null:{html:e.html_text,timestamp:e.timestamp_ms,isPrompt:!1,isMonospace:!1,shouldLog:Boolean(e.log),buffer:t};if(!e.parsed_line)return null;const n=safeCall$1(e.parsed_line.text,e.parsed_line)??"";return!n.length||e.gag?null:(g?.inLineHighlighting(e.parsed_line),{html:safeCall$1(e.parsed_line.formatted,e.parsed_line)??n,timestamp:e.timestamp_ms,isPrompt:Boolean(e.is_prompt),isMonospace:Boolean(e.monospace),shouldLog:Boolean(e.log),buffer:t})},convertHostLines=(e,t,g=null,n=null)=>{const C=toArray(e);if(0===C.length)return[];const o=C.map(e=>convertHostLine(e,"main",g)).filter(Boolean);if(0===o.length)return[];if(!o.some(e=>!e.isPrompt)){const e=o[o.length-1];return e&&e.html!==n?o:[]}return t?[createExtraBreakLine(),...o]:o},appendConvertedLines=(e,t)=>{Array.isArray(t)&&0!==t.length&&getStreamModel(e)?.addLines?.(t)},hasInitialHostBufferSync=e=>Boolean(e?.[qs]),markInitialHostBufferSynced=e=>{e&&"object"==typeof e&&(Object.prototype.hasOwnProperty.call(e,qs)?e[qs]=!0:Object.defineProperty(e,qs,{value:!0,writable:!0,enumerable:!1,configurable:!0}))},syncInitialHostBuffer=(e,t,g=null)=>{if(hasInitialHostBufferSync(e))return;markInitialHostBufferSynced(e);const n=toArray(t?.lines);0!==n.length&&appendConvertedLines(e,convertHostLines(n,Boolean(nexusclient.settings?.().extra_break),g,getCurrentPromptHtml(e)))},getNextStreamSessionId=e=>{const t=getStreamModel(e),g=t?.getStats?.(),n=Number(g?.nextId??g?.sessionTotalLines);if(Number.isFinite(n))return Math.max(0,Math.floor(n));const C=t?.getSnapshot?.()?.buffer??[],o=C.at(-1)?.id;return Number.isFinite(o)?Math.max(0,Math.floor(o+1)):0},downloadScrollbackSessionSlice=async(e,t)=>{if("undefined"==typeof document||"undefined"==typeof Blob||"undefined"==typeof URL||"function"!=typeof URL.createObjectURL)return;const g=getScrollbackSession(e);if(!g?.readRange)return;const n=getUiSettings(e),C=Boolean(n.virtualizedLogs);let o=[];try{o=await g.readRange(Math.max(0,Math.floor(Number(t)||0)),Number.MAX_SAFE_INTEGER)}catch(I){return void console.error("[nexGui4] Failed reading scrollback log export",I)}0!==o.length&&downloadBuffer(o,C)},undoFooterLayout=()=>{if("undefined"==typeof document)return;const e=document.getElementById("status_vars");e&&["status-target","status-bank","status-gold","status-level","status-ping"].forEach(t=>{const g=document.getElementById(t);g&&e.prepend(g)})},isScrollbackRendererEnabled=()=>{const e=globalThis.nexusclient?.variables?.()?.vars?.nexGuiSettings?.options?.nexGuiRenderer;return!1!==e},isScrollbackOpen=e=>getUiStoreState(e)?.modalOpen===Qs,openScrollback=e=>getUiStoreState(e)?.openModal?.(Qs),closeScrollback=e=>getUiStoreState(e)?.closeModal?.(),saveOriginalMethod=(e,t,g,{nullish:n=!1}={})=>{const C=`${g}_original`,o=Object.prototype.hasOwnProperty.call(t,C);return n?t[C]??=t[g]:void 0===t[C]&&(t[C]=t[g]),e.push(()=>{void 0!==t[C]&&(t[g]=t[C]),o||delete t[C]}),t[C]},removePatches=()=>{Js?.(),Js=null,$s=null},applyPatches=({contextValue:e}={})=>{const t=$s;if(removePatches(),"undefined"==typeof nexusclient)throw new Error("[nexGui4] applyPatches requires the live nexusclient host.");const g=getContextValue(e);if(!g)throw new Error("[nexGui4] applyPatches requires a live NexGui context value.");t&&t!==g&&clearRelationshipNameFormatterCache(t),$s=g;const n=ensureRuntimeColors(g),C=[],o={logStartSessionId:null},I=nexusclient.ui().layout(),a=nexusclient._ui?._layout??I,i=nexusclient.datahandler(),s=nexusclient.platform(),l=nexusclient.serverapi(),c=nexusclient.log(),u=nexusclient.buffer();syncInitialHostBuffer(g,u,n);const d=Object.prototype.hasOwnProperty.call(i,"handle_GMCP_original"),p=Object.prototype.hasOwnProperty.call(I,"get_tab_object_original"),m=Object.prototype.hasOwnProperty.call(a,"get_tab_object_original"),h=Object.prototype.hasOwnProperty.call(I,"nexoverrides"),y=new Map(Ys.filter(e=>Object.prototype.hasOwnProperty.call(I.nexoverrides??{},e)).map(e=>[e,I.nexoverrides[e]]));initializeTabs({contextValue:g}),C.push(()=>{const e=getRuntime();e&&"object"==typeof e&&delete e[Xs],void 0!==I.get_tab_object_original&&(I.get_tab_object=I.get_tab_object_original),Ys.forEach(e=>{I.nexoverrides&&(y.has(e)?I.nexoverrides[e]=y.get(e):delete I.nexoverrides[e])}),!h&&I.nexoverrides&&0===Object.keys(I.nexoverrides).length&&delete I.nexoverrides,p||delete I.get_tab_object_original,m||delete a.get_tab_object_original});const b=saveOriginalMethod(C,nexusclient,"process_lines");nexusclient.process_lines=function(e){const t=safeCall$1(b,this,e);if(this.gagged)return t;const C=Boolean(nexusclient.settings?.().extra_break);return appendConvertedLines(g,convertHostLines(e,C,n,getCurrentPromptHtml(g))),t};const v=saveOriginalMethod(C,nexusclient,"_add_line");nexusclient._add_line=function(e,t){const n=!this.current_block,C=safeCall$1(v,this,e,t);if(!n)return C;appendConvertedLines(g,[convertHostLine(e,t??"main")].filter(Boolean))},"undefined"==typeof nexSys&&(saveOriginalMethod(C,u,"add_block"),u.add_block=function(e){let t=0,g=0;for(let C=0;C<e.length;++C){const n=e[C];if(n.log&&g++,!n.gag&&(n.parsed_line||n.html_line))if(!n.is_prompt||t){if(n.parsed_line&&!safeCall$1(n.parsed_line.text,n.parsed_line)&&(0===t||C===e.length-1))continue;safeCall$1(this._fill_tab_completion,this,n),t++,this.lineid++,n.id=this.lineid,this.lines.push(n),this.unread=!0}else n.gag=!0}const n=safeCall$1(this.prune_lines,this);(t||g||n)&&safeCall$1(this.on_lines_changed,this)});const x=saveOriginalMethod(C,c,"enable");c.enable=function(){const e=safeCall$1(x,this),t=getNextStreamSessionId(g);return o.logStartSessionId=Math.max(0,t-100),e};const S=saveOriginalMethod(C,c,"disable");c.disable=function(){const e=safeCall$1(S,this),t=getUiSettings(g);if(null!=o.logStartSessionId||t.logoutDownload){const e=o.logStartSessionId??0;o.logStartSessionId=null,downloadScrollbackSessionSlice(g,e)}return e};const w=saveOriginalMethod(C,l,"on_disconnect");l.on_disconnect=function(){this.__anonymous=!1,this.__game=null,this.__name=null,undoFooterLayout();const e=getUiSettings(g);if(null!=o.logStartSessionId||e.logoutDownload){const e=o.logStartSessionId??0;o.logStartSessionId=null,downloadScrollbackSessionSlice(g,e)}return safeCall$1(w,this)},saveOriginalMethod(C,s,"on_key_down",{nullish:!0}),s.on_key_down=function(e,t,n,C){return n&&C&&76===e||33===e&&isScrollbackRendererEnabled()&&!isScrollbackOpen(g)?(openScrollback(g),!0):(27===e&&closeScrollback(g),safeCall$1(this.on_key_down_original,this,e,t,n,C))},void 0===i.handle_GMCP_original&&(i.handle_GMCP_original=i.handle_GMCP),C.push(()=>{void 0!==i.handle_GMCP_original&&(i.handle_GMCP=i.handle_GMCP_original,d||delete i.handle_GMCP_original)}),i.handle_GMCP=function(e,t){if("Comm.Channel.Text"===e){const e="string"==typeof t?(()=>{try{return JSON.parse(t)}catch{return null}})():t;if("says"===e?.channel&&"string"==typeof e.talker&&e.talker.indexOf(" ")>-1&&-1===e.talker.indexOf("Discord"))return;if(e?.talker===globalThis.GMCP?.Char?.Status?.name&&"string"==typeof e.text&&e.text.includes("Duanathar."))return}return safeCall$1(this.handle_GMCP_original,this,e,t)};const E=saveOriginalMethod(C,I,"write_channel");I.write_channel=function(e,t){if(!t||"function"!=typeof this.channel_id_from_cmd||"function"!=typeof this.channel_record)return safeCall$1(E,this,e,t);ensureRuntimeColors(g).inLineHighlighting(t);const n=Date.now(),C=[{parsed_line:t,timestamp_ms:formatTimestamp(!0,n),timestamp:formatTimestamp(!1,n)}],o=this.channel_id_from_cmd(e),I=this.channel_record(o);if(I)try{I.buffer.add_block(C)}catch{}try{this._nexus.comm_buffer().add_block(C)}catch{}};const R=registerTriggers(g),M=registerEvents();return C.push(R),C.push(M),Js=()=>{for(;C.length>0;){const e=C.pop();e?.()}$s=null,Js=null},removePatches},installGlobalNexGui=e=>(globalThis.nexGui?.destroy?.(),globalThis.nexGui=e,e),_s="nexgui4-styles",el=new Map,getStyleElement=()=>{if("undefined"==typeof document||"function"!=typeof document.getElementById||!document.head)return null;const e=document.getElementById(_s);if(e)return e;const t=document.createElement("style");return t.id=_s,document.head.appendChild(t),t},registerNexguiStyles=(e,t)=>{if(!e||"string"!=typeof t)return;const g=getStyleElement();g&&(el.set(e,t.trim()),g.textContent=Array.from(el.values()).filter(Boolean).join("\n\n"))},tl="replacement-base",gl=St.replacement,toDamageSlug=e=>e.toLowerCase().replace(/\s+/g,"-"),buildCatalogRules=()=>[".ng-skill-default { color: orange; }",Object.entries(Oe).map(([e,t])=>`.ng-skill-${e} { color: ${t}; }`).join("\n"),".ng-action-default { color: grey; }",Object.entries(De).map(([e,t])=>`.ng-action-${e} { color: ${t.fg}; }`).join("\n"),".ng-dmg-unknown { color: grey; }",Object.entries(Pe).map(([e,t])=>`.ng-dmg-${toDamageSlug(e)} { color: ${t}; }`).join("\n"),".ng-muted { color: grey; }",".ng-npc-bracket { color: red; font-weight: bold; }",".ng-crit-separator { color: white; }",".ng-dmg-bracket { color: #808080; }",".ng-hp-loss { color: tomato; }",".ng-info-text { color: cadetblue; font-style: italic; }"].filter(Boolean).join("\n"),rl=`\n/* nexGui4 replacement visual primitives — injected by replacementStyles.js */\n.ng-brkt { font-weight: bold; }\n.ng-brkt-ally { color: ${gl.bracketAllyColor}; }\n.ng-brkt-enemy { color: ${gl.bracketEnemyColor}; }\n.ng-italic { font-style: italic; }\n.ng-target-format {\n box-decoration-break: clone;\n -webkit-box-decoration-break: clone;\n box-shadow: inset 0 0 0 1px ${gl.targetBorderColor};\n padding: 0 2px;\n position: relative;\n z-index: 1;\n}\n.ng-icon-fill-1 { fill: var(--ng-fill-1); }\n.ng-icon-fill-2 { fill: var(--ng-fill-2); }\n\n/* Legacy message replacement row classes retained for compatibility. */\n.ng-seg { display: table-cell; color: #aaa; }\n.ng-msgline { display: inline-table; width: calc(100% - 15ch); }\n.ng-w-0 { width: 0; }\n.ng-w-5 { width: 5%; }\n.ng-w-30 { width: 30%; }\n.ng-w-35 { width: 35%; }\n\n/* Flex layout for structured skill replacement rows */\n.nexgui4-replacement-row {\n display: inline-flex;\n width: calc(100% - 15ch); /* account for timestamp */\n min-width: 0;\n overflow: hidden;\n vertical-align: top;\n}\n.nexgui4-replacement-row__buffer {\n flex: 0 0 5%;\n}\n.nexgui4-replacement-row__actor {\n flex: 0 0 30%;\n overflow: hidden;\n white-space: nowrap;\n text-overflow: ellipsis;\n}\n.nexgui4-replacement-row__action {\n flex: 0 0 35%;\n}\n.nexgui4-replacement-row__target {\n flex: 1;\n min-width: 0;\n}\n\n${buildCatalogRules()}\n`.trim(),injectReplacementBaseStyles=()=>{registerNexguiStyles(tl,rl)},nl="transcript-viewport",Al="\n/* nexGui4 transcript viewport primitives. */\n.nexgui4-transcript-scroll-viewport {\n flex: 1;\n min-height: 0;\n overflow-anchor: none;\n overflow-y: auto;\n position: relative;\n margin: 5px;\n}\n\n.nexgui4-transcript-scroll-viewport--display {\n -ms-overflow-style: none;\n scrollbar-width: none;\n}\n\n.nexgui4-transcript-scroll-viewport--display::-webkit-scrollbar {\n display: none;\n}\n\n.nexgui4-transcript-spacer {\n width: 100%;\n}\n\n.nexgui4-transcript-spacer--display {\n box-sizing: border-box;\n}\n\n.nexgui4-transcript-spacer--panel {\n position: relative;\n}\n\n.nexgui4-transcript-row {\n width: 100%;\n}\n\n.nexgui4-transcript-row--panel {\n left: 0;\n position: absolute;\n top: 0;\n}\n\n.nexgui4-virtual-scroll-line {\n align-items: baseline;\n contain: layout style paint;\n display: flex;\n font-family: inherit;\n min-width: 0;\n}\n\n.nexgui4-virtual-scroll-line.nexguilog {\n display: flex !important;\n}\n\n.nexgui4-main-display-timestamp.timestamp,\n.nexgui4-scrollback-timestamp.timestamp,\n.nexgui4-structured-stream-panel__timestamp.timestamp {\n display: inline !important;\n}\n\n.nexgui4-virtual-scroll-line__payload {\n flex: 1;\n min-width: 0;\n overflow-wrap: anywhere;\n white-space: pre-wrap;\n}\n\n.nexgui4-prompt-line {\n position: static;\n width: 100%;\n}\n".trim(),injectTranscriptStyles=()=>{registerNexguiStyles(nl,Al)},Cl={"shield-halved":[512,512,["shield-alt"],"f3ed",["M256 0c.2 0 .5 0 .7 0c4.6 0 9.2 1 13.4 2.9L458.4 82.8c22 9.3 38.4 31 38.3 57.2c-.5 99.2-41.3 280.7-213.6 363.2c-8.3 4-17.4 6-26.4 6V0H256z","M256.7 0c-.2 0-.5 0-.7 0c-4.6 0-9.2 1-13.4 2.9L54.3 82.8c-22 9.3-38.4 31-38.3 57.2c.5 99.2 41.3 280.7 213.6 363.2c8.3 4 17.4 6 26.4 6V0h.7z"]],"shield-cross":[512,512,[9960],"f712",["M224 10.8L54.3 82.8c-22 9.3-38.4 31-38.3 57.2c0 6.4 .2 13 .6 20H192c17.7 0 32-14.3 32-32V10.8zM24.7 224C43.7 319.9 97.4 437.2 224 500.4V256c0-17.7-14.3-32-32-32H24.7zM288 500.4C414.6 437.2 468.3 319.9 487.3 224H320c-17.7 0-32 14.3-32 32V500.4zM495.4 160c.4-7 .6-13.7 .6-20c.1-26.2-16.3-47.9-38.3-57.2L288 10.8V128c0 17.7 14.3 32 32 32H495.4z","M288 10.8L269.4 2.9C265.2 1 260.7 0 256 0s-9.2 1-13.4 2.9L224 10.8V128c0 17.7-14.3 32-32 32H16.6c1.1 19.4 3.6 41.1 8.1 64H192c17.7 0 32 14.3 32 32V500.4c1.9 .9 3.7 1.8 5.6 2.7c16.7 8 36.1 8 52.8 0c1.9-.9 3.8-1.8 5.6-2.7V256c0-17.7 14.3-32 32-32H487.3c4.5-22.9 7.1-44.6 8.1-64H320c-17.7 0-32-14.3-32-32V10.8z"]],tree:[448,512,[127794],"f1bb",["M210.6 5.9L62 169.4c-3.9 4.2-6 9.8-6 15.5C56 197.7 66.3 208 79.1 208H104L30.6 281.4c-4.2 4.2-6.6 10-6.6 16C24 309.9 34.1 320 46.6 320H80L5.4 409.5C1.9 413.7 0 419 0 424.5c0 13 10.5 23.5 23.5 23.5H192V224c0-17.7 14.3-32 32-32s32 14.3 32 32V448H424.5c13 0 23.5-10.5 23.5-23.5c0-5.5-1.9-10.8-5.4-15L368 320h33.4c12.5 0 22.6-10.1 22.6-22.6c0-6-2.4-11.8-6.6-16L344 208h24.9c12.7 0 23.1-10.3 23.1-23.1c0-5.7-2.1-11.3-6-15.5L237.4 5.9C234 2.1 229.1 0 224 0s-10 2.1-13.4 5.9z","M224 192c17.7 0 32 14.3 32 32V480c0 17.7-14.3 32-32 32s-32-14.3-32-32V224c0-17.7 14.3-32 32-32z"]],droplet:[384,512,[128167,"tint"],"f043",["M192 512C86 512 0 426 0 320C0 228.8 130.2 57.7 166.6 11.7C172.6 4.2 181.5 0 191.1 0h1.8c9.6 0 18.5 4.2 24.5 11.7C253.8 57.7 384 228.8 384 320c0 106-86 192-192 192zM96 336c0-8.8-7.2-16-16-16s-16 7.2-16 16c0 61.9 50.1 112 112 112c8.8 0 16-7.2 16-16s-7.2-16-16-16c-44.2 0-80-35.8-80-80z","M80 320c8.8 0 16 7.2 16 16c0 44.2 35.8 80 80 80c8.8 0 16 7.2 16 16s-7.2 16-16 16c-61.9 0-112-50.1-112-112c0-8.8 7.2-16 16-16z"]],tombstone:[448,512,[],"f720",["M224 0C118 0 32 86 32 192V448H416V192C416 86 330 0 224 0zm24 152v40h48c13.3 0 24 10.7 24 24s-10.7 24-24 24H248V360c0 13.3-10.7 24-24 24s-24-10.7-24-24V240H152c-13.3 0-24-10.7-24-24s10.7-24 24-24h48V152c0-13.3 10.7-24 24-24s24 10.7 24 24z","M248 152c0-13.3-10.7-24-24-24s-24 10.7-24 24v40H152c-13.3 0-24 10.7-24 24s10.7 24 24 24h48V360c0 13.3 10.7 24 24 24s24-10.7 24-24V240h48c13.3 0 24-10.7 24-24s-10.7-24-24-24H248V152zM32 448c-17.7 0-32 14.3-32 32s14.3 32 32 32H416c17.7 0 32-14.3 32-32s-14.3-32-32-32H32z"]],feather:[512,512,[129718],"f52d",["M97.9 448h84c49.7 0 97.9-14.4 139-41c11.1-7.2 5.5-23-7.8-23c-5.1 0-9.2-4.1-9.2-9.2c0-4.1 2.7-7.6 6.5-8.8l81-24.3c2.5-.8 4.8-2.1 6.7-4l22.4-22.4c10.1-10.1 2.9-27.3-11.3-27.3l-32.2 0c-5.1 0-9.2-4.1-9.2-9.2c0-4.1 2.7-7.6 6.5-8.8l112-33.6c4-1.2 7.4-3.9 9.3-7.7C506.4 207.6 512 184.1 512 160c0-41-16.3-80.3-45.3-109.3l-5.5-5.5C432.3 16.3 393 0 352 0s-80.3 16.3-109.3 45.3L139 149C91 197 64 262.1 64 330v84L311 167c9.4-9.4 24.6-9.4 33.9 0s9.4 24.6 0 33.9L97.9 448z","M24 512c-6.2 0-12.3-2.3-17-7c-9.4-9.4-9.4-24.6 0-33.9L311 167c9.4-9.4 24.6-9.4 33.9 0s9.4 24.6 0 33.9L41 505c-4.7 4.7-10.8 7-17 7z"]],"fish-fins":[576,512,[],"e4f2",["M182 150.4C221.3 120.9 273.7 96 336 96s114.7 24.9 154 54.4c39.2 29.4 67.2 64.7 81.6 89.5c5.8 9.9 5.8 22.2 0 32.1c-14.4 24.8-42.5 60.1-81.6 89.5C450.7 391.1 398.3 416 336 416s-114.7-24.9-154-54.4c-15.3-11.5-29-23.9-40.7-36.3L48.1 379.6c-12.5 7.3-28.4 5.3-38.7-4.9S-3 348.7 4.2 336.1L50 256 4.2 175.9c-7.2-12.6-5-28.4 5.3-38.6s26.1-12.2 38.7-4.9l93.1 54.3c11.8-12.3 25.4-24.8 40.7-36.3zM448 256a32 32 0 1 0 -64 0 32 32 0 1 0 64 0z","M238.9 36.9C227.7 44 222 57.3 224.6 70.3l9.7 48.6C264.1 105.1 298.2 96 336 96c5.7 0 11.3 .2 16.8 .6L275.2 38.4c-10.6-8-25-8.5-36.3-1.5zm-4.6 356.2l-9.7 48.6c-2.6 13 3.1 26.3 14.3 33.3s25.6 6.5 36.3-1.5l77.6-58.2c-5.5 .4-11.1 .6-16.8 .6c-37.8 0-71.9-9.1-101.7-22.9z"]]},ol="host-surface",Il="character_module_class",al="100%",il="15%",sl="\nhtml { -webkit-font-smoothing: subpixel-antialiased; }\n.flexlayout__splitter { background-color: grey; }\n.flexlayout__tab { background-color: #000 !important; }\n.output { padding: 5px; }\n.nexguilog { display: none; }\n\n.ng-timestamp { margin-right: 1ch; }\n\n.ng-virtual-list {\n background: black;\n width: 100%;\n overflow-y: auto;\n contain: strict;\n padding-bottom: 0;\n}\n\n.ng-virtual-list--border { border-bottom: 1px solid #ccc; }\n\n.ng-virtual-anchor {\n overflow-anchor: none;\n width: 100%;\n color: white;\n white-space: pre-wrap;\n word-wrap: break-word;\n}\n\n.ng-ListItem { contain: layout inline-size; }\n\n.nexgui4-tab-container {\n isolation: isolate;\n overflow: hidden;\n position: relative;\n}\n\n.nexgui4-tab-container__background {\n inset: 0;\n pointer-events: none;\n position: absolute;\n z-index: 0;\n}\n\n.nexgui4-tab-container__surface,\n.nexgui4-tab-container__tabs,\n.nexgui4-tab-container__tabpanel {\n position: relative;\n z-index: 1;\n}\n".trim(),injectHostStyles=()=>{registerNexguiStyles(ol,sl)},setClassBalanceIconReadyState=e=>{if("undefined"==typeof document)return;const t=document.getElementById(Il);t&&(t.style.opacity=!0===e?al:!1===e?il:"")},bindClassBalanceIcon=({characterStore:e}={})=>{if(!e||"function"!=typeof e.getState||"function"!=typeof e.subscribe)return()=>{};const sync=(t=e.getState())=>{setClassBalanceIconReadyState(t?.classBalanceReady??null)};return sync(),e.subscribe(e=>{sync(e)})},injectFontAwesomeIcons=()=>{"undefined"!=typeof window&&window.___FONT_AWESOME___?.styles?.fad&&Object.assign(window.___FONT_AWESOME___.styles.fad,Cl)},ll=300;let cl=null;const forceFooterHostElementsVisible=e=>{e?.setHostSetting?.("show_gauges",!0),e?.setHostSetting?.("show_balances",!0)},applyFooterLayout=()=>{if("undefined"==typeof document)return;const e=document.getElementsByClassName("bottom_view")[0];e&&(e.style.padding="0px",e.children[2]&&(e.children[2].style.margin="0px"));const t=document.getElementById("status_vars");if(t){for(let g=0;g<t.children.length;g++)Object.assign(t.children[g].style,{fontSize:"14.4px",marginTop:"auto",marginBottom:"auto",verticalAlign:"middle"});Object.assign(t.style,{justifyContent:"flex-start",alignItems:"center",marginTop:0,marginBottom:0});const e=document.getElementById("component_balances");e&&(t.prepend(e),e.style.minWidth="50px",e.style.marginTop="5px",e.style.gap="2px")}const g=document.getElementById("extra_icons");g&&(Object.assign(g.style,{display:"flex",justifyContent:"end",gap:"10px"}),["status-bank","status-gold","status-level","status-ping"].forEach(e=>{const t=document.getElementById(e);t&&g.prepend(t)}));const n=document.getElementById("status-ping");n&&(n.style.minWidth="57px");const C=document.getElementById("left_icons");if(C){Object.assign(C.style,{minWidth:"300px",maxWidth:"500px"}),C.children[0]&&(C.children[0].style.visibility="hidden",C.children[0].style.width="0px");const e=document.getElementById("status-target");e&&(C.prepend(e),e.style.fontSize="12px",e.style.fontWeight="bold")}const o=document.getElementById("footer");if(o&&g){const e=document.getElementById("gauges");if(e){o.insertBefore(e,g),Object.assign(e.style,{display:"flex",transform:"scaleY(0.85)",minWidth:0,flexGrow:100,alignItems:"center"});for(const t of e.children)t.children[1]&&(t.children[1].style.fontSize="12px"),t.style.flexGrow=1}}document.getElementById(Il)?.remove();const I=document.createElement("div");I.id=Il,I.className="balance class-balance",I.style.flexGrow="1";const a=window.___FONT_AWESOME___?.styles?.fa?.hourglass?.[4]??"";I.innerHTML=`<svg aria-hidden="true" focusable="false" data-prefix="fad" data-icon="hourglass" class="svg-inline--fa fa-star fa-w-18" role="img" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 576 512" color="#33FFD4" style="font-size: 20px;"><g class="fa-group"><path class="fa-secondary" fill="currentColor" d="${a}"></path><path class="fa-primary" fill="currentColor" d=""></path></g></svg>`,document.getElementById("component_balances")?.appendChild(I),document.getElementById("balance_balance")?.setAttribute("style","flex-grow: 1"),document.getElementById("balance_equilibrium")?.setAttribute("style","flex-grow: 1")},configureFlexLayout=()=>{if("undefined"==typeof nexusclient)return;const e=nexusclient.ui().layout(),t=e.model()?.global??{},g="boolean"!=typeof t.tabSetEnableTabStrip||t.tabSetEnableTabStrip;e.flexModel.doAction({type:"FlexLayout_UpdateModelAttributes",data:{json:{splitterSize:2,tabSetEnableTabStrip:g,tabEnableClose:!1,tabSetEnableMaximize:!1,borderEnableAutoHide:!0,borderEnableDrop:!0}}}),["right","left","top","bottom"].forEach(t=>{e.model().borders.find(e=>e.location===t)||e.model().borders.push({type:"border",location:t,children:[]})});const borderLeaveEvent=()=>{cl&&(document.getElementsByClassName("MuiPopover-root MuiMenu-root MuiModal-root").length||e.flexModel.doAction({type:"FlexLayout_SelectTab",data:{tabNode:cl}}))},n=document.getElementsByClassName("flexlayout__tab_border_right");for(let o=0;o<n.length;o++)n[o].addEventListener("mouseleave",borderLeaveEvent);const borderMouseOverEvent=t=>{const g=t.target.title;g&&(e.flexModel.getNodeById(g)?.isVisible()||(cl=g,e.flexModel.doAction({type:"FlexLayout_SelectTab",data:{tabNode:cl}})))},C=document.getElementsByClassName("flexlayout__border_button_right");for(let o=0;o<C.length;o++){const t=C[o];t.addEventListener("mouseenter",borderMouseOverEvent);const g=e.model().borders[0]?.children.find(e=>e.id===t.title);g&&g.borderWidth<ll&&(g.borderWidth=ll)}},ul="nexGui4",dl="https://unpkg.com/nexgui4/dist/nexGui4.nxs",pl="khaseem",ml=1e4,fl=[{key:"classCustomizations",names:["nexGui.classCustomizations","classCustomizations"]},{key:"userSettings",names:["nexGui.userSettings","userSettings"]}],hl=new Set(fl.flatMap(({names:e})=>e.map(e=>e.toLowerCase()))),toLowerName=e=>String(e??"").trim().toLowerCase(),clonePackageItem=e=>{if(!e||"object"!=typeof e)return null;if("function"==typeof structuredClone)try{return structuredClone(e)}catch{}try{return JSON.parse(JSON.stringify(e))}catch{return e}},safeCall=e=>{try{return e()}catch{return null}},getReflexes=e=>safeCall(()=>e?.reflexes?.())??null,getPackageRegistry=e=>{const t=safeCall(()=>e?.packages?.());if("function"==typeof t?.get)return t;const g=safeCall(()=>getReflexes(e)?.packages?.());return"function"==typeof g?.get?g:null},getNexGuiPackage=(e,t=ul)=>safeCall(()=>getPackageRegistry(e)?.get(t))??null,findPackageItemByNames=(e,t)=>{if(!Array.isArray(e))return null;const g=new Set(t.map(toLowerName));return e.find(e=>g.has(toLowerName(e?.name)))??null},captureCustomizationGroups=e=>fl.map(({key:t,names:g})=>{const n=findPackageItemByNames(e?.items,g);return n?{key:t,names:g,data:clonePackageItem(n)}:null}).filter(Boolean),applyCustomizationGroup=(e,t,g)=>{const n=findPackageItemByNames(e?.items,t.names);return!(!n||!t.data||("function"==typeof n.apply?(n.apply(t.data,g),0):"object"!=typeof n||"object"!=typeof t.data||(Object.assign(n,clonePackageItem(t.data)),0)))},enableRuntimePackageGroups=e=>{Array.isArray(e?.items)&&e.items.filter(e=>"group"===e?.type&&!hl.has(toLowerName(e.name))).forEach(e=>{e.enabled=!0})},reportUpdateError=({adapter:e,consoleObj:t,message:g,nexusClient:n})=>{t.error(g),"function"!=typeof e?.notice?"function"!=typeof n?.display?n?.display_notice?.(g,"red"):n.display(g):e.notice(g,"red")},createAbortSignal=({AbortControllerCtor:e,setTimeoutFn:t,timeoutMs:g})=>{if(!e||g<=0)return{signal:void 0,timeout:null};const n=new e,C=t(()=>n.abort(),g);return{signal:n.signal,timeout:C}},updateNxs=async({adapter:e=null,clearTimeoutFn:t=clearTimeout,consoleObj:g=console,fetchFn:n=globalThis.fetch,nexusClient:C=globalThis.nexusclient,packageName:o=ul,setTimeoutFn:I=setTimeout,skipCharacterName:a=pl,timeoutMs:i=ml,url:s=dl}={})=>{if(toLowerName(C?.charname)===toLowerName(a))return null;const l=getPackageRegistry(C);if(!l)return null;let c=null;try{if("function"!=typeof n)throw new Error("fetch is not available.");const e=l.get(o);if(!e||"function"!=typeof e.apply)throw new Error(`${o} package is not installed in Nexus.`);const t=captureCustomizationGroups(e),{signal:g,timeout:a}=createAbortSignal({AbortControllerCtor:globalThis.AbortController,setTimeoutFn:I,timeoutMs:i});c=a;const u=await n(s,{cache:"no-store",...g?{signal:g}:{}});if(!u?.ok)throw new Error(`${o} update failed: ${u?.status??"unknown"} ${u?.statusText??""}`.trim());const d=await u.json(),p=getReflexes(C),m=getNexGuiPackage(C,o);m.apply(d,p);const h=getNexGuiPackage(C,o)??m;return t.forEach(e=>{applyCustomizationGroup(h,e,p)}),enableRuntimePackageGroups(h),d}catch(u){const t="AbortError"===u?.name?`${o} update timed out. Check your connection.`:`${o} update error: ${u?.message??String(u)}`;return reportUpdateError({adapter:e,consoleObj:g,message:t,nexusClient:C}),null}finally{null!==c&&t(c)}},yl="https://api.achaea.com/gamefeed.json",bl=5e3,normalizeFetchedEntries=e=>Array.isArray(e)?e.filter(Boolean):[],parseTimestamp=e=>{if("string"!=typeof e||0===e.trim().length)return;const t=e.trim(),g=t.match(/^(\d{4})-(\d{2})-(\d{2})[ T](\d{2}):(\d{2}):(\d{2})$/);if(g){const[,e,t,n,C,o,I]=g;return Date.UTC(Number(e),Number(t)-1,Number(n),Number(C),Number(o),Number(I),0)}const n=t.includes("T")?t:t.replace(" ","T"),C=/(?:Z|[+-]\d{2}:?\d{2})$/i.test(n),o=Date.parse(C?n:`${n}Z`);return Number.isFinite(o)?o:void 0},toStoreEntry=e=>({content:e.description??e.caption??null,id:e.id??void 0,timestamp:parseTimestamp(e.date)}),mapEntries=e=>e.map(e=>toStoreEntry(e)),applySnapshot=(e,t)=>{const g=e?.getState?.();if(!g)return;const n=mapEntries(t);if("function"!=typeof g.replaceEntries){g.clear();for(const e of n)g.addEntry(e)}else g.replaceEntries(n)},appendEntries=(e,t)=>{const g=e?.getState?.();if(!g)return;const n=mapEntries(t);if("function"!=typeof g.addEntries)for(const C of n)g.addEntry(C);else g.addEntries(n)},createGameFeedPoller=({feedStore:e,fetchFn:t=null,setIntervalFn:g=null,clearIntervalFn:n=null,intervalMs:C=bl,url:o=yl})=>{let I=null,a=null,i=!1,s=null;const syncFromRemote=async()=>{if("function"!=typeof t)return[];try{const g=await t(o,{cache:"no-store"});if(!g?.ok)return[];const n=await g.json(),C=normalizeFetchedEntries(n);if(!i||0===C.length)return C;const I=C.at(-1)?.id??null;if(null==I)return applySnapshot(e,C),C;if(null==s)return applySnapshot(e,C),s=I,C;if(I===s)return[];const a=C.findIndex(e=>e?.id===s);return a<0?applySnapshot(e,C):appendEntries(e,C.slice(a+1)),s=I,C}catch{return[]}},pollOnce=()=>a||(a=syncFromRemote().finally(()=>{a=null}),a);return{start:()=>{i||(i=!0,pollOnce(),"function"==typeof g&&(I=g(()=>{pollOnce()},C)))},stop:()=>{i=!1,null!==I&&"function"==typeof n&&(n(I),I=null)},pollOnce}},vl="https://2a9fwzdazf.execute-api.us-east-2.amazonaws.com/nexGui/cdb",xl="zr1te94RPZ4yaMJCc6j134eAxDsCpkmm48py1GaD",resolveRemoteService=({remoteService:e,remotePlayerService:t,fetchFn:g}={})=>{if(e)return e;const n=t??{apiUrl:vl,apiKey:xl};return createLambdaRemotePlayerService({...n,fetchFn:n.fetchFn??g})},bootstrapNexus=(e={})=>{const{adapter:t,autoStart:g,startupPhaseHandlers:n,remoteService:C,remotePlayerService:o,feedPollingEnabled:I=!0,runtimePorts:a,...i}=e,s=a??createBrowserRuntimePorts(),l=createNexusAdapter(),c=resolveRemoteService({remoteService:C,remotePlayerService:o,fetchFn:s.fetch});let u,d=!1,p=!1,m=!1,h=!1,y=!1,b=!1,v=!1,x=!1,S=null,removeLivePatches=()=>{},removeClassBalanceBinding=()=>{},removeNetflixModeController=()=>{},removeNativeDisplayCommands=()=>{},removeLayoutCommands=()=>{};const ensureFeedPoller=()=>I?(S??=createGameFeedPoller({feedStore:u.stores.feed,fetchFn:s.fetch,setIntervalFn:s.setInterval,clearIntervalFn:s.clearInterval}),S):null;return u=createNexGui({adapter:l,autoStart:!1,remoteService:c,startupPhaseHandlers:{[$e.BOOTING]:async()=>{const e=updateNxs({adapter:l,fetchFn:s.fetch,setTimeoutFn:s.setTimeout,clearTimeoutFn:s.clearTimeout});injectHostStyles(),injectTranscriptStyles(),injectReplacementBaseStyles(),injectFontAwesomeIcons();const t=u.__contextValue,g=t?.persistenceStore?.get("ui")?.nativeDisplay??!1;if(d||(generateTabs(),d=!0),p||(forceFooterHostElementsVisible(l),configureFlexLayout(),applyFooterLayout(),p=!0),h||(removeClassBalanceBinding=bindClassBalanceIcon({characterStore:u.stores.character}),h=!0),y||(removeNetflixModeController=createNetflixModeController({adapter:l,uiStore:u.stores.ui,characterStore:u.stores.character}),y=!0),m||(removeLivePatches=applyPatches({contextValue:t}),m=!0,g&&t.platformTabs.mountNativeDisplay()),!v){const e=l.destroy.bind(l);l.destroy=()=>{S?.stop(),removeNativeDisplayCommands(),removeLayoutCommands(),removeClassBalanceBinding(),h=!1,removeNetflixModeController(),y=!1,m&&(removeLivePatches(),m=!1),e()},v=!0}x||(l.send("stat"),l.send("pwho"),l.send("enemies"),l.send("allies"),l.send("city enemies"),l.send("date"),l.send("ql"),x=!0),t.playerDirectoryLifecycle.warmDirectoryFromCache(),b||(t.playerDirectoryLifecycle.subscribePersistence(),b=!0),t.playerDirectoryLifecycle.refreshDirectoryFromRemote(c),ensureFeedPoller()?.start(),await e}},runtimePorts:s,...i}),removeNativeDisplayCommands=u.__contextValue.platformTabs.configureNativeDisplayCommands({mountNativeDisplay:()=>mountNativeDisplay({contextValue:u.__contextValue}),unmountNativeDisplay:()=>{unmountNativeDisplay()}}),removeLayoutCommands=u.__contextValue.platformTabs.configureLayoutCommands({applyLayoutPreset,saveLayout:saveCurrentLayout,restoreLayout:restoreSavedLayout,hasSavedLayout}),installGlobalNexGui(u),u.__start().catch(()=>{}).then(()=>{emitStartupReadySignal(l),runNexGuiClassReflexForCurrentHostClass()}),u},createMockAdapter=({playerRelationships:e}={})=>{const t=[],g=new Map,n=new Map,C={echo_input:!1,echo_gmcp:!1,show_prompts:!0,show_timestamps:!1},o={tabSetEnableTabStrip:!1};let I=0,a=0;const getListenerBucket=e=>(n.has(e)||n.set(e,new Map),n.get(e)),resolveListenerId=(e,t={})=>t.id??"listener-"+ ++a,removeListener=(e,t)=>{const g=n.get(e);if(!g)return!1;if("string"==typeof t)return g.delete(t);for(const[n,C]of g.entries())if(C.handler===t)return g.delete(n),!0;return!1},i=assertAdapterContract({send:g=>{e?.trackRelationshipCommand?.(g),t.push(g)},sendGmcp:(e,g)=>t.push({gmcp:e,data:g}),getVariable:e=>g.get(e),setVariable:(e,t)=>g.set(e,t),getTarget:()=>g.get("_target")??null,setTarget:e=>g.set("_target",e),notice:()=>{},getHostSettings:()=>C,setHostSetting:(e,t)=>{C[e]=t},getHostLayoutSnapshot:()=>o,updateHostLayoutAttributes:e=>{Object.assign(o,e)},focusInput:()=>{},getConfiguredDefences:()=>[],gagCurrentBlock:()=>{I+=1},on:(e,t,g)=>{const n=resolveListenerId(t,g);return getListenerBucket(e).set(n,{handler:t,once:Boolean(g?.once)}),()=>removeListener(e,n)},off:(e,t)=>removeListener(e,t),destroy:()=>{n.clear()}});return i._test={getSentCommands:()=>[...t],clearCommands:()=>{t.length=0},getGaggedBlockCount:()=>I,triggerEvent:(e,t)=>{const g=n.get(e);if(g)for(const[n,C]of[...g.entries()])C.handler(t),C.once&&g.delete(n)},setVariable:(e,t)=>g.set(e,t)},i},bootstrapPlayground=(e={})=>{const{feedPollingEnabled:t=!0,startupPhaseHandlers:g={},runtimePorts:n,...C}=e,o=n??createBrowserRuntimePorts(),I=createMockAdapter();let a,i=null;const ensureFeedPoller=()=>t?(i??=createGameFeedPoller({feedStore:a.stores.feed,fetchFn:o.fetch,setIntervalFn:o.setInterval,clearIntervalFn:o.clearInterval}),i):null;a=createNexGui({adapter:I,runtimePorts:o,startupPhaseHandlers:{...g,[$e.BOOTING]:async e=>{await(g[$e.BOOTING]?.(e)),injectTranscriptStyles(),ensureFeedPoller()?.start()}},...C});const s=a.destroy.bind(a);return a.destroy=()=>{i?.stop(),s()},a},Sl=Object.freeze({NexGuiContext:jt,applyInlineNameHighlighting,createMuiTheme,createReplacementDescriptor,generateReplacementHtml,injectReplacementBaseStyles,isRoomNpcItem,nexGuiIcons:Cl,panels:Object.freeze({CombatStream,DefencesPanel,GameFeed,ItemsPanel,MainDisplay,MetricsPanel,NpcsPanel,OptionsPanel,PartyPanel,PlayersPanel,StatsPanel,SystemStream,TargetPanel,TimersPanel})});e.TOPICS=L,e.bootstrapNexus=bootstrapNexus,e.bootstrapPlayground=bootstrapPlayground,e.composePublicApi=composePublicApi,e.createMockAdapter=createMockAdapter,e.createNexGui=createNexGui,e.createNexusAdapter=createNexusAdapter,e.defaultTokens=St,e.playground=Sl,e.updateNxs=updateNxs,Object.defineProperty(e,Symbol.toStringTag,{value:"Module"})}(this.nexGui=this.nexGui||{},React,ReactDOM,ReactDOM);