@nubisco/openbridge 0.39.0 → 0.39.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/__tests__/auth-gate.test.d.ts +2 -0
- package/dist/__tests__/auth-gate.test.d.ts.map +1 -0
- package/dist/__tests__/auth-gate.test.js +141 -0
- package/dist/__tests__/auth-gate.test.js.map +1 -0
- package/dist/auth.d.ts +27 -3
- package/dist/auth.d.ts.map +1 -1
- package/dist/auth.js +71 -11
- package/dist/auth.js.map +1 -1
- package/dist/server.d.ts.map +1 -1
- package/dist/server.js +8 -11
- package/dist/server.js.map +1 -1
- package/package.json +10 -10
- package/ui-dist/assets/index-D9v2kI8s.js +109 -0
- package/ui-dist/index.html +1 -1
- package/ui-dist/assets/index-BkNkuHBq.js +0 -108
|
@@ -1,108 +0,0 @@
|
|
|
1
|
-
(function(){const t=document.createElement("link").relList;if(t&&t.supports&&t.supports("modulepreload"))return;for(const s of document.querySelectorAll('link[rel="modulepreload"]'))r(s);new MutationObserver(s=>{for(const n of s)if(n.type==="childList")for(const a of n.addedNodes)a.tagName==="LINK"&&a.rel==="modulepreload"&&r(a)}).observe(document,{childList:!0,subtree:!0});function i(s){const n={};return s.integrity&&(n.integrity=s.integrity),s.referrerPolicy&&(n.referrerPolicy=s.referrerPolicy),s.crossOrigin==="use-credentials"?n.credentials="include":s.crossOrigin==="anonymous"?n.credentials="omit":n.credentials="same-origin",n}function r(s){if(s.ep)return;s.ep=!0;const n=i(s);fetch(s.href,n)}})();/**
|
|
2
|
-
* @vue/shared v3.5.32
|
|
3
|
-
* (c) 2018-present Yuxi (Evan) You and Vue contributors
|
|
4
|
-
* @license MIT
|
|
5
|
-
**/function $h(e){const t=Object.create(null);for(const i of e.split(","))t[i]=1;return i=>i in t}const et={},Mn=[],vr=()=>{},jp=()=>!1,Q0=e=>e.charCodeAt(0)===111&&e.charCodeAt(1)===110&&(e.charCodeAt(2)>122||e.charCodeAt(2)<97),ec=e=>e.startsWith("onUpdate:"),Vt=Object.assign,xh=(e,t)=>{const i=e.indexOf(t);i>-1&&e.splice(i,1)},Kv=Object.prototype.hasOwnProperty,nt=(e,t)=>Kv.call(e,t),Ve=Array.isArray,Ln=e=>ml(e)==="[object Map]",qn=e=>ml(e)==="[object Set]",jd=e=>ml(e)==="[object Date]",Ue=e=>typeof e=="function",At=e=>typeof e=="string",Oi=e=>typeof e=="symbol",tt=e=>e!==null&&typeof e=="object",Kp=e=>(tt(e)||Ue(e))&&Ue(e.then)&&Ue(e.catch),qp=Object.prototype.toString,ml=e=>qp.call(e),qv=e=>ml(e).slice(8,-1),Gp=e=>ml(e)==="[object Object]",tc=e=>At(e)&&e!=="NaN"&&e[0]!=="-"&&""+parseInt(e,10)===e,No=$h(",key,ref,ref_for,ref_key,onVnodeBeforeMount,onVnodeMounted,onVnodeBeforeUpdate,onVnodeUpdated,onVnodeBeforeUnmount,onVnodeUnmounted"),ic=e=>{const t=Object.create(null);return i=>t[i]||(t[i]=e(i))},Gv=/-\w/g,pi=ic(e=>e.replace(Gv,t=>t.slice(1).toUpperCase())),Yv=/\B([A-Z])/g,Yr=ic(e=>e.replace(Yv,"-$1").toLowerCase()),rc=ic(e=>e.charAt(0).toUpperCase()+e.slice(1)),Fc=ic(e=>e?`on${rc(e)}`:""),di=(e,t)=>!Object.is(e,t),i0=(e,...t)=>{for(let i=0;i<e.length;i++)e[i](...t)},Yp=(e,t,i,r=!1)=>{Object.defineProperty(e,t,{configurable:!0,enumerable:!1,writable:r,value:i})},sc=e=>{const t=parseFloat(e);return isNaN(t)?e:t},Xv=e=>{const t=At(e)?Number(e):NaN;return isNaN(t)?e:t};let Kd;const nc=()=>Kd||(Kd=typeof globalThis<"u"?globalThis:typeof self<"u"?self:typeof window<"u"?window:typeof global<"u"?global:{});function Ci(e){if(Ve(e)){const t={};for(let i=0;i<e.length;i++){const r=e[i],s=At(r)?t5(r):Ci(r);if(s)for(const n in s)t[n]=s[n]}return t}else if(At(e)||tt(e))return e}const Jv=/;(?![^(]*\))/g,Qv=/:([^]+)/,e5=/\/\*[^]*?\*\//g;function t5(e){const t={};return e.replace(e5,"").split(Jv).forEach(i=>{if(i){const r=i.split(Qv);r.length>1&&(t[r[0].trim()]=r[1].trim())}}),t}function xe(e){let t="";if(At(e))t=e;else if(Ve(e))for(let i=0;i<e.length;i++){const r=xe(e[i]);r&&(t+=r+" ")}else if(tt(e))for(const i in e)e[i]&&(t+=i+" ");return t.trim()}const i5="itemscope,allowfullscreen,formnovalidate,ismap,nomodule,novalidate,readonly",r5=$h(i5);function Xp(e){return!!e||e===""}function s5(e,t){if(e.length!==t.length)return!1;let i=!0;for(let r=0;i&&r<e.length;r++)i=vs(e[r],t[r]);return i}function vs(e,t){if(e===t)return!0;let i=jd(e),r=jd(t);if(i||r)return i&&r?e.getTime()===t.getTime():!1;if(i=Oi(e),r=Oi(t),i||r)return e===t;if(i=Ve(e),r=Ve(t),i||r)return i&&r?s5(e,t):!1;if(i=tt(e),r=tt(t),i||r){if(!i||!r)return!1;const s=Object.keys(e).length,n=Object.keys(t).length;if(s!==n)return!1;for(const a in e){const o=e.hasOwnProperty(a),l=t.hasOwnProperty(a);if(o&&!l||!o&&l||!vs(e[a],t[a]))return!1}}return String(e)===String(t)}function Th(e,t){return e.findIndex(i=>vs(i,t))}const Jp=e=>!!(e&&e.__v_isRef===!0),Z=e=>At(e)?e:e==null?"":Ve(e)||tt(e)&&(e.toString===qp||!Ue(e.toString))?Jp(e)?Z(e.value):JSON.stringify(e,Qp,2):String(e),Qp=(e,t)=>Jp(t)?Qp(e,t.value):Ln(t)?{[`Map(${t.size})`]:[...t.entries()].reduce((i,[r,s],n)=>(i[zc(r,n)+" =>"]=s,i),{})}:qn(t)?{[`Set(${t.size})`]:[...t.values()].map(i=>zc(i))}:Oi(t)?zc(t):tt(t)&&!Ve(t)&&!Gp(t)?String(t):t,zc=(e,t="")=>{var i;return Oi(e)?`Symbol(${(i=e.description)!=null?i:t})`:e};/**
|
|
6
|
-
* @vue/reactivity v3.5.32
|
|
7
|
-
* (c) 2018-present Yuxi (Evan) You and Vue contributors
|
|
8
|
-
* @license MIT
|
|
9
|
-
**/let hi;class e_{constructor(t=!1){this.detached=t,this._active=!0,this._on=0,this.effects=[],this.cleanups=[],this._isPaused=!1,this.__v_skip=!0,this.parent=hi,!t&&hi&&(this.index=(hi.scopes||(hi.scopes=[])).push(this)-1)}get active(){return this._active}pause(){if(this._active){this._isPaused=!0;let t,i;if(this.scopes)for(t=0,i=this.scopes.length;t<i;t++)this.scopes[t].pause();for(t=0,i=this.effects.length;t<i;t++)this.effects[t].pause()}}resume(){if(this._active&&this._isPaused){this._isPaused=!1;let t,i;if(this.scopes)for(t=0,i=this.scopes.length;t<i;t++)this.scopes[t].resume();for(t=0,i=this.effects.length;t<i;t++)this.effects[t].resume()}}run(t){if(this._active){const i=hi;try{return hi=this,t()}finally{hi=i}}}on(){++this._on===1&&(this.prevScope=hi,hi=this)}off(){this._on>0&&--this._on===0&&(hi=this.prevScope,this.prevScope=void 0)}stop(t){if(this._active){this._active=!1;let i,r;for(i=0,r=this.effects.length;i<r;i++)this.effects[i].stop();for(this.effects.length=0,i=0,r=this.cleanups.length;i<r;i++)this.cleanups[i]();if(this.cleanups.length=0,this.scopes){for(i=0,r=this.scopes.length;i<r;i++)this.scopes[i].stop(!0);this.scopes.length=0}if(!this.detached&&this.parent&&!t){const s=this.parent.scopes.pop();s&&s!==this&&(this.parent.scopes[this.index]=s,s.index=this.index)}this.parent=void 0}}}function Nh(e){return new e_(e)}function t_(){return hi}function I1(e,t=!1){hi&&hi.cleanups.push(e)}let gt;const Uc=new WeakSet;class i_{constructor(t){this.fn=t,this.deps=void 0,this.depsTail=void 0,this.flags=5,this.next=void 0,this.cleanup=void 0,this.scheduler=void 0,hi&&hi.active&&hi.effects.push(this)}pause(){this.flags|=64}resume(){this.flags&64&&(this.flags&=-65,Uc.has(this)&&(Uc.delete(this),this.trigger()))}notify(){this.flags&2&&!(this.flags&32)||this.flags&8||s_(this)}run(){if(!(this.flags&1))return this.fn();this.flags|=2,qd(this),n_(this);const t=gt,i=er;gt=this,er=!0;try{return this.fn()}finally{a_(this),gt=t,er=i,this.flags&=-3}}stop(){if(this.flags&1){for(let t=this.deps;t;t=t.nextDep)Oh(t);this.deps=this.depsTail=void 0,qd(this),this.onStop&&this.onStop(),this.flags&=-2}}trigger(){this.flags&64?Uc.add(this):this.scheduler?this.scheduler():this.runIfDirty()}runIfDirty(){R1(this)&&this.run()}get dirty(){return R1(this)}}let r_=0,Ho,Po;function s_(e,t=!1){if(e.flags|=8,t){e.next=Po,Po=e;return}e.next=Ho,Ho=e}function Hh(){r_++}function Ph(){if(--r_>0)return;if(Po){let t=Po;for(Po=void 0;t;){const i=t.next;t.next=void 0,t.flags&=-9,t=i}}let e;for(;Ho;){let t=Ho;for(Ho=void 0;t;){const i=t.next;if(t.next=void 0,t.flags&=-9,t.flags&1)try{t.trigger()}catch(r){e||(e=r)}t=i}}if(e)throw e}function n_(e){for(let t=e.deps;t;t=t.nextDep)t.version=-1,t.prevActiveLink=t.dep.activeLink,t.dep.activeLink=t}function a_(e){let t,i=e.depsTail,r=i;for(;r;){const s=r.prevDep;r.version===-1?(r===i&&(i=s),Oh(r),n5(r)):t=r,r.dep.activeLink=r.prevActiveLink,r.prevActiveLink=void 0,r=s}e.deps=t,e.depsTail=i}function R1(e){for(let t=e.deps;t;t=t.nextDep)if(t.dep.version!==t.version||t.dep.computed&&(o_(t.dep.computed)||t.dep.version!==t.version))return!0;return!!e._dirty}function o_(e){if(e.flags&4&&!(e.flags&16)||(e.flags&=-17,e.globalVersion===Uo)||(e.globalVersion=Uo,!e.isSSR&&e.flags&128&&(!e.deps&&!e._dirty||!R1(e))))return;e.flags|=2;const t=e.dep,i=gt,r=er;gt=e,er=!0;try{n_(e);const s=e.fn(e._value);(t.version===0||di(s,e._value))&&(e.flags|=128,e._value=s,t.version++)}catch(s){throw t.version++,s}finally{gt=i,er=r,a_(e),e.flags&=-3}}function Oh(e,t=!1){const{dep:i,prevSub:r,nextSub:s}=e;if(r&&(r.nextSub=s,e.prevSub=void 0),s&&(s.prevSub=r,e.nextSub=void 0),i.subs===e&&(i.subs=r,!r&&i.computed)){i.computed.flags&=-5;for(let n=i.computed.deps;n;n=n.nextDep)Oh(n,!0)}!t&&!--i.sc&&i.map&&i.map.delete(i.key)}function n5(e){const{prevDep:t,nextDep:i}=e;t&&(t.nextDep=i,e.prevDep=void 0),i&&(i.prevDep=t,e.nextDep=void 0)}let er=!0;const l_=[];function Kr(){l_.push(er),er=!1}function qr(){const e=l_.pop();er=e===void 0?!0:e}function qd(e){const{cleanup:t}=e;if(e.cleanup=void 0,t){const i=gt;gt=void 0;try{t()}finally{gt=i}}}let Uo=0;class a5{constructor(t,i){this.sub=t,this.dep=i,this.version=i.version,this.nextDep=this.prevDep=this.nextSub=this.prevSub=this.prevActiveLink=void 0}}class ac{constructor(t){this.computed=t,this.version=0,this.activeLink=void 0,this.subs=void 0,this.map=void 0,this.key=void 0,this.sc=0,this.__v_skip=!0}track(t){if(!gt||!er||gt===this.computed)return;let i=this.activeLink;if(i===void 0||i.sub!==gt)i=this.activeLink=new a5(gt,this),gt.deps?(i.prevDep=gt.depsTail,gt.depsTail.nextDep=i,gt.depsTail=i):gt.deps=gt.depsTail=i,c_(i);else if(i.version===-1&&(i.version=this.version,i.nextDep)){const r=i.nextDep;r.prevDep=i.prevDep,i.prevDep&&(i.prevDep.nextDep=r),i.prevDep=gt.depsTail,i.nextDep=void 0,gt.depsTail.nextDep=i,gt.depsTail=i,gt.deps===i&&(gt.deps=r)}return i}trigger(t){this.version++,Uo++,this.notify(t)}notify(t){Hh();try{for(let i=this.subs;i;i=i.prevSub)i.sub.notify()&&i.sub.dep.notify()}finally{Ph()}}}function c_(e){if(e.dep.sc++,e.sub.flags&4){const t=e.dep.computed;if(t&&!e.dep.subs){t.flags|=20;for(let r=t.deps;r;r=r.nextDep)c_(r)}const i=e.dep.subs;i!==e&&(e.prevSub=i,i&&(i.nextSub=e)),e.dep.subs=e}}const g0=new WeakMap,Ys=Symbol(""),D1=Symbol(""),Wo=Symbol("");function fi(e,t,i){if(er&>){let r=g0.get(e);r||g0.set(e,r=new Map);let s=r.get(i);s||(r.set(i,s=new ac),s.map=r,s.key=i),s.track()}}function Rr(e,t,i,r,s,n){const a=g0.get(e);if(!a){Uo++;return}const o=l=>{l&&l.trigger()};if(Hh(),t==="clear")a.forEach(o);else{const l=Ve(e),c=l&&tc(i);if(l&&i==="length"){const u=Number(r);a.forEach((h,d)=>{(d==="length"||d===Wo||!Oi(d)&&d>=u)&&o(h)})}else switch((i!==void 0||a.has(void 0))&&o(a.get(i)),c&&o(a.get(Wo)),t){case"add":l?c&&o(a.get("length")):(o(a.get(Ys)),Ln(e)&&o(a.get(D1)));break;case"delete":l||(o(a.get(Ys)),Ln(e)&&o(a.get(D1)));break;case"set":Ln(e)&&o(a.get(Ys));break}}Ph()}function o5(e,t){const i=g0.get(e);return i&&i.get(t)}function hn(e){const t=Xe(e);return t===e?t:(fi(t,"iterate",Wo),Hi(e)?t:t.map(tr))}function oc(e){return fi(e=Xe(e),"iterate",Wo),e}function pr(e,t){return Gr(e)?Tn(jr(e)?tr(t):t):tr(t)}const l5={__proto__:null,[Symbol.iterator](){return Wc(this,Symbol.iterator,e=>pr(this,e))},concat(...e){return hn(this).concat(...e.map(t=>Ve(t)?hn(t):t))},entries(){return Wc(this,"entries",e=>(e[1]=pr(this,e[1]),e))},every(e,t){return $r(this,"every",e,t,void 0,arguments)},filter(e,t){return $r(this,"filter",e,t,i=>i.map(r=>pr(this,r)),arguments)},find(e,t){return $r(this,"find",e,t,i=>pr(this,i),arguments)},findIndex(e,t){return $r(this,"findIndex",e,t,void 0,arguments)},findLast(e,t){return $r(this,"findLast",e,t,i=>pr(this,i),arguments)},findLastIndex(e,t){return $r(this,"findLastIndex",e,t,void 0,arguments)},forEach(e,t){return $r(this,"forEach",e,t,void 0,arguments)},includes(...e){return jc(this,"includes",e)},indexOf(...e){return jc(this,"indexOf",e)},join(e){return hn(this).join(e)},lastIndexOf(...e){return jc(this,"lastIndexOf",e)},map(e,t){return $r(this,"map",e,t,void 0,arguments)},pop(){return lo(this,"pop")},push(...e){return lo(this,"push",e)},reduce(e,...t){return Gd(this,"reduce",e,t)},reduceRight(e,...t){return Gd(this,"reduceRight",e,t)},shift(){return lo(this,"shift")},some(e,t){return $r(this,"some",e,t,void 0,arguments)},splice(...e){return lo(this,"splice",e)},toReversed(){return hn(this).toReversed()},toSorted(e){return hn(this).toSorted(e)},toSpliced(...e){return hn(this).toSpliced(...e)},unshift(...e){return lo(this,"unshift",e)},values(){return Wc(this,"values",e=>pr(this,e))}};function Wc(e,t,i){const r=oc(e),s=r[t]();return r!==e&&!Hi(e)&&(s._next=s.next,s.next=()=>{const n=s._next();return n.done||(n.value=i(n.value)),n}),s}const c5=Array.prototype;function $r(e,t,i,r,s,n){const a=oc(e),o=a!==e&&!Hi(e),l=a[t];if(l!==c5[t]){const h=l.apply(e,n);return o?tr(h):h}let c=i;a!==e&&(o?c=function(h,d){return i.call(this,pr(e,h),d,e)}:i.length>2&&(c=function(h,d){return i.call(this,h,d,e)}));const u=l.call(a,c,r);return o&&s?s(u):u}function Gd(e,t,i,r){const s=oc(e),n=s!==e&&!Hi(e);let a=i,o=!1;s!==e&&(n?(o=r.length===0,a=function(c,u,h){return o&&(o=!1,c=pr(e,c)),i.call(this,c,pr(e,u),h,e)}):i.length>3&&(a=function(c,u,h){return i.call(this,c,u,h,e)}));const l=s[t](a,...r);return o?pr(e,l):l}function jc(e,t,i){const r=Xe(e);fi(r,"iterate",Wo);const s=r[t](...i);return(s===-1||s===!1)&&lc(i[0])?(i[0]=Xe(i[0]),r[t](...i)):s}function lo(e,t,i=[]){Kr(),Hh();const r=Xe(e)[t].apply(e,i);return Ph(),qr(),r}const u5=$h("__proto__,__v_isRef,__isVue"),u_=new Set(Object.getOwnPropertyNames(Symbol).filter(e=>e!=="arguments"&&e!=="caller").map(e=>Symbol[e]).filter(Oi));function h5(e){Oi(e)||(e=String(e));const t=Xe(this);return fi(t,"has",e),t.hasOwnProperty(e)}class h_{constructor(t=!1,i=!1){this._isReadonly=t,this._isShallow=i}get(t,i,r){if(i==="__v_skip")return t.__v_skip;const s=this._isReadonly,n=this._isShallow;if(i==="__v_isReactive")return!s;if(i==="__v_isReadonly")return s;if(i==="__v_isShallow")return n;if(i==="__v_raw")return r===(s?n?w5:__:n?p_:f_).get(t)||Object.getPrototypeOf(t)===Object.getPrototypeOf(r)?t:void 0;const a=Ve(t);if(!s){let l;if(a&&(l=l5[i]))return l;if(i==="hasOwnProperty")return h5}const o=Reflect.get(t,i,wt(t)?t:r);if((Oi(i)?u_.has(i):u5(i))||(s||fi(t,"get",i),n))return o;if(wt(o)){const l=a&&tc(i)?o:o.value;return s&&tt(l)?xn(l):l}return tt(o)?s?xn(o):tn(o):o}}class d_ extends h_{constructor(t=!1){super(!1,t)}set(t,i,r,s){let n=t[i];const a=Ve(t)&&tc(i);if(!this._isShallow){const c=Gr(n);if(!Hi(r)&&!Gr(r)&&(n=Xe(n),r=Xe(r)),!a&&wt(n)&&!wt(r))return c||(n.value=r),!0}const o=a?Number(i)<t.length:nt(t,i),l=Reflect.set(t,i,r,wt(t)?t:s);return t===Xe(s)&&(o?di(r,n)&&Rr(t,"set",i,r):Rr(t,"add",i,r)),l}deleteProperty(t,i){const r=nt(t,i);t[i];const s=Reflect.deleteProperty(t,i);return s&&r&&Rr(t,"delete",i,void 0),s}has(t,i){const r=Reflect.has(t,i);return(!Oi(i)||!u_.has(i))&&fi(t,"has",i),r}ownKeys(t){return fi(t,"iterate",Ve(t)?"length":Ys),Reflect.ownKeys(t)}}class d5 extends h_{constructor(t=!1){super(!0,t)}set(t,i){return!0}deleteProperty(t,i){return!0}}const f5=new d_,p5=new d5,_5=new d_(!0);const V1=e=>e,Nl=e=>Reflect.getPrototypeOf(e);function m5(e,t,i){return function(...r){const s=this.__v_raw,n=Xe(s),a=Ln(n),o=e==="entries"||e===Symbol.iterator&&a,l=e==="keys"&&a,c=s[e](...r),u=i?V1:t?Tn:tr;return!t&&fi(n,"iterate",l?D1:Ys),Vt(Object.create(c),{next(){const{value:h,done:d}=c.next();return d?{value:h,done:d}:{value:o?[u(h[0]),u(h[1])]:u(h),done:d}}})}}function Hl(e){return function(...t){return e==="delete"?!1:e==="clear"?void 0:this}}function g5(e,t){const i={get(s){const n=this.__v_raw,a=Xe(n),o=Xe(s);e||(di(s,o)&&fi(a,"get",s),fi(a,"get",o));const{has:l}=Nl(a),c=t?V1:e?Tn:tr;if(l.call(a,s))return c(n.get(s));if(l.call(a,o))return c(n.get(o));n!==a&&n.get(s)},get size(){const s=this.__v_raw;return!e&&fi(Xe(s),"iterate",Ys),s.size},has(s){const n=this.__v_raw,a=Xe(n),o=Xe(s);return e||(di(s,o)&&fi(a,"has",s),fi(a,"has",o)),s===o?n.has(s):n.has(s)||n.has(o)},forEach(s,n){const a=this,o=a.__v_raw,l=Xe(o),c=t?V1:e?Tn:tr;return!e&&fi(l,"iterate",Ys),o.forEach((u,h)=>s.call(n,c(u),c(h),a))}};return Vt(i,e?{add:Hl("add"),set:Hl("set"),delete:Hl("delete"),clear:Hl("clear")}:{add(s){const n=Xe(this),a=Nl(n),o=Xe(s),l=!t&&!Hi(s)&&!Gr(s)?o:s;return a.has.call(n,l)||di(s,l)&&a.has.call(n,s)||di(o,l)&&a.has.call(n,o)||(n.add(l),Rr(n,"add",l,l)),this},set(s,n){!t&&!Hi(n)&&!Gr(n)&&(n=Xe(n));const a=Xe(this),{has:o,get:l}=Nl(a);let c=o.call(a,s);c||(s=Xe(s),c=o.call(a,s));const u=l.call(a,s);return a.set(s,n),c?di(n,u)&&Rr(a,"set",s,n):Rr(a,"add",s,n),this},delete(s){const n=Xe(this),{has:a,get:o}=Nl(n);let l=a.call(n,s);l||(s=Xe(s),l=a.call(n,s)),o&&o.call(n,s);const c=n.delete(s);return l&&Rr(n,"delete",s,void 0),c},clear(){const s=Xe(this),n=s.size!==0,a=s.clear();return n&&Rr(s,"clear",void 0,void 0),a}}),["keys","values","entries",Symbol.iterator].forEach(s=>{i[s]=m5(s,e,t)}),i}function Ih(e,t){const i=g5(e,t);return(r,s,n)=>s==="__v_isReactive"?!e:s==="__v_isReadonly"?e:s==="__v_raw"?r:Reflect.get(nt(i,s)&&s in r?i:r,s,n)}const v5={get:Ih(!1,!1)},b5={get:Ih(!1,!0)},y5={get:Ih(!0,!1)};const f_=new WeakMap,p_=new WeakMap,__=new WeakMap,w5=new WeakMap;function S5(e){switch(e){case"Object":case"Array":return 1;case"Map":case"Set":case"WeakMap":case"WeakSet":return 2;default:return 0}}function C5(e){return e.__v_skip||!Object.isExtensible(e)?0:S5(qv(e))}function tn(e){return Gr(e)?e:Rh(e,!1,f5,v5,f_)}function m_(e){return Rh(e,!1,_5,b5,p_)}function xn(e){return Rh(e,!0,p5,y5,__)}function Rh(e,t,i,r,s){if(!tt(e)||e.__v_raw&&!(t&&e.__v_isReactive))return e;const n=C5(e);if(n===0)return e;const a=s.get(e);if(a)return a;const o=new Proxy(e,n===2?r:i);return s.set(e,o),o}function jr(e){return Gr(e)?jr(e.__v_raw):!!(e&&e.__v_isReactive)}function Gr(e){return!!(e&&e.__v_isReadonly)}function Hi(e){return!!(e&&e.__v_isShallow)}function lc(e){return e?!!e.__v_raw:!1}function Xe(e){const t=e&&e.__v_raw;return t?Xe(t):e}function Dh(e){return!nt(e,"__v_skip")&&Object.isExtensible(e)&&Yp(e,"__v_skip",!0),e}const tr=e=>tt(e)?tn(e):e,Tn=e=>tt(e)?xn(e):e;function wt(e){return e?e.__v_isRef===!0:!1}function X(e){return g_(e,!1)}function Ar(e){return g_(e,!0)}function g_(e,t){return wt(e)?e:new k5(e,t)}class k5{constructor(t,i){this.dep=new ac,this.__v_isRef=!0,this.__v_isShallow=!1,this._rawValue=i?t:Xe(t),this._value=i?t:tr(t),this.__v_isShallow=i}get value(){return this.dep.track(),this._value}set value(t){const i=this._rawValue,r=this.__v_isShallow||Hi(t)||Gr(t);t=r?t:Xe(t),di(t,i)&&(this._rawValue=t,this._value=r?t:tr(t),this.dep.trigger())}}function ue(e){return wt(e)?e.value:e}function A5(e){return Ue(e)?e():ue(e)}const M5={get:(e,t,i)=>t==="__v_raw"?e:ue(Reflect.get(e,t,i)),set:(e,t,i,r)=>{const s=e[t];return wt(s)&&!wt(i)?(s.value=i,!0):Reflect.set(e,t,i,r)}};function v_(e){return jr(e)?e:new Proxy(e,M5)}class L5{constructor(t){this.__v_isRef=!0,this._value=void 0;const i=this.dep=new ac,{get:r,set:s}=t(i.track.bind(i),i.trigger.bind(i));this._get=r,this._set=s}get value(){return this._value=this._get()}set value(t){this._set(t)}}function E5(e){return new L5(e)}function $5(e){const t=Ve(e)?new Array(e.length):{};for(const i in e)t[i]=b_(e,i);return t}class x5{constructor(t,i,r){this._object=t,this._defaultValue=r,this.__v_isRef=!0,this._value=void 0,this._key=Oi(i)?i:String(i),this._raw=Xe(t);let s=!0,n=t;if(!Ve(t)||Oi(this._key)||!tc(this._key))do s=!lc(n)||Hi(n);while(s&&(n=n.__v_raw));this._shallow=s}get value(){let t=this._object[this._key];return this._shallow&&(t=ue(t)),this._value=t===void 0?this._defaultValue:t}set value(t){if(this._shallow&&wt(this._raw[this._key])){const i=this._object[this._key];if(wt(i)){i.value=t;return}}this._object[this._key]=t}get dep(){return o5(this._raw,this._key)}}class T5{constructor(t){this._getter=t,this.__v_isRef=!0,this.__v_isReadonly=!0,this._value=void 0}get value(){return this._value=this._getter()}}function N5(e,t,i){return wt(e)?e:Ue(e)?new T5(e):tt(e)&&arguments.length>1?b_(e,t,i):X(e)}function b_(e,t,i){return new x5(e,t,i)}class H5{constructor(t,i,r){this.fn=t,this.setter=i,this._value=void 0,this.dep=new ac(this),this.__v_isRef=!0,this.deps=void 0,this.depsTail=void 0,this.flags=16,this.globalVersion=Uo-1,this.next=void 0,this.effect=this,this.__v_isReadonly=!i,this.isSSR=r}notify(){if(this.flags|=16,!(this.flags&8)&>!==this)return s_(this,!0),!0}get value(){const t=this.dep.track();return o_(this),t&&(t.version=this.dep.version),this._value}set value(t){this.setter&&this.setter(t)}}function P5(e,t,i=!1){let r,s;return Ue(e)?r=e:(r=e.get,s=e.set),new H5(r,s,i)}const Pl={},v0=new WeakMap;let Bs;function O5(e,t=!1,i=Bs){if(i){let r=v0.get(i);r||v0.set(i,r=[]),r.push(e)}}function I5(e,t,i=et){const{immediate:r,deep:s,once:n,scheduler:a,augmentJob:o,call:l}=i,c=v=>s?v:Hi(v)||s===!1||s===0?Dr(v,1):Dr(v);let u,h,d,f,m=!1,_=!1;if(wt(e)?(h=()=>e.value,m=Hi(e)):jr(e)?(h=()=>c(e),m=!0):Ve(e)?(_=!0,m=e.some(v=>jr(v)||Hi(v)),h=()=>e.map(v=>{if(wt(v))return v.value;if(jr(v))return c(v);if(Ue(v))return l?l(v,2):v()})):Ue(e)?t?h=l?()=>l(e,2):e:h=()=>{if(d){Kr();try{d()}finally{qr()}}const v=Bs;Bs=u;try{return l?l(e,3,[f]):e(f)}finally{Bs=v}}:h=vr,t&&s){const v=h,k=s===!0?1/0:s;h=()=>Dr(v(),k)}const y=t_(),p=()=>{u.stop(),y&&y.active&&xh(y.effects,u)};if(n&&t){const v=t;t=(...k)=>{v(...k),p()}}let C=_?new Array(e.length).fill(Pl):Pl;const w=v=>{if(!(!(u.flags&1)||!u.dirty&&!v))if(t){const k=u.run();if(s||m||(_?k.some(($,M)=>di($,C[M])):di(k,C))){d&&d();const $=Bs;Bs=u;try{const M=[k,C===Pl?void 0:_&&C[0]===Pl?[]:C,f];C=k,l?l(t,3,M):t(...M)}finally{Bs=$}}}else u.run()};return o&&o(w),u=new i_(h),u.scheduler=a?()=>a(w,!1):w,f=v=>O5(v,!1,u),d=u.onStop=()=>{const v=v0.get(u);if(v){if(l)l(v,4);else for(const k of v)k();v0.delete(u)}},t?r?w(!0):C=u.run():a?a(w.bind(null,!0),!0):u.run(),p.pause=u.pause.bind(u),p.resume=u.resume.bind(u),p.stop=p,p}function Dr(e,t=1/0,i){if(t<=0||!tt(e)||e.__v_skip||(i=i||new Map,(i.get(e)||0)>=t))return e;if(i.set(e,t),t--,wt(e))Dr(e.value,t,i);else if(Ve(e))for(let r=0;r<e.length;r++)Dr(e[r],t,i);else if(qn(e)||Ln(e))e.forEach(r=>{Dr(r,t,i)});else if(Gp(e)){for(const r in e)Dr(e[r],t,i);for(const r of Object.getOwnPropertySymbols(e))Object.prototype.propertyIsEnumerable.call(e,r)&&Dr(e[r],t,i)}return e}/**
|
|
10
|
-
* @vue/runtime-core v3.5.32
|
|
11
|
-
* (c) 2018-present Yuxi (Evan) You and Vue contributors
|
|
12
|
-
* @license MIT
|
|
13
|
-
**/function gl(e,t,i,r){try{return r?e(...r):e()}catch(s){vl(s,t,i)}}function ir(e,t,i,r){if(Ue(e)){const s=gl(e,t,i,r);return s&&Kp(s)&&s.catch(n=>{vl(n,t,i)}),s}if(Ve(e)){const s=[];for(let n=0;n<e.length;n++)s.push(ir(e[n],t,i,r));return s}}function vl(e,t,i,r=!0){const s=t?t.vnode:null,{errorHandler:n,throwUnhandledErrorInProduction:a}=t&&t.appContext.config||et;if(t){let o=t.parent;const l=t.proxy,c=`https://vuejs.org/error-reference/#runtime-${i}`;for(;o;){const u=o.ec;if(u){for(let h=0;h<u.length;h++)if(u[h](e,l,c)===!1)return}o=o.parent}if(n){Kr(),gl(n,null,10,[e,l,c]),qr();return}}R5(e,i,s,r,a)}function R5(e,t,i,r=!0,s=!1){if(s)throw e;console.error(e)}const wi=[];let dr=-1;const En=[];let ls=null,vn=0;const y_=Promise.resolve();let b0=null;function _i(e){const t=b0||y_;return e?t.then(this?e.bind(this):e):t}function D5(e){let t=dr+1,i=wi.length;for(;t<i;){const r=t+i>>>1,s=wi[r],n=jo(s);n<e||n===e&&s.flags&2?t=r+1:i=r}return t}function Vh(e){if(!(e.flags&1)){const t=jo(e),i=wi[wi.length-1];!i||!(e.flags&2)&&t>=jo(i)?wi.push(e):wi.splice(D5(t),0,e),e.flags|=1,w_()}}function w_(){b0||(b0=y_.then(C_))}function V5(e){Ve(e)?En.push(...e):ls&&e.id===-1?ls.splice(vn+1,0,e):e.flags&1||(En.push(e),e.flags|=1),w_()}function Yd(e,t,i=dr+1){for(;i<wi.length;i++){const r=wi[i];if(r&&r.flags&2){if(e&&r.id!==e.uid)continue;wi.splice(i,1),i--,r.flags&4&&(r.flags&=-2),r(),r.flags&4||(r.flags&=-2)}}}function S_(e){if(En.length){const t=[...new Set(En)].sort((i,r)=>jo(i)-jo(r));if(En.length=0,ls){ls.push(...t);return}for(ls=t,vn=0;vn<ls.length;vn++){const i=ls[vn];i.flags&4&&(i.flags&=-2),i.flags&8||i(),i.flags&=-2}ls=null,vn=0}}const jo=e=>e.id==null?e.flags&2?-1:1/0:e.id;function C_(e){try{for(dr=0;dr<wi.length;dr++){const t=wi[dr];t&&!(t.flags&8)&&(t.flags&4&&(t.flags&=-2),gl(t,t.i,t.i?15:14),t.flags&4||(t.flags&=-2))}}finally{for(;dr<wi.length;dr++){const t=wi[dr];t&&(t.flags&=-2)}dr=-1,wi.length=0,S_(),b0=null,(wi.length||En.length)&&C_()}}let ni=null,k_=null;function y0(e){const t=ni;return ni=e,k_=e&&e.type.__scopeId||null,t}function ee(e,t=ni,i){if(!t||e._n)return e;const r=(...s)=>{r._d&&k0(-1);const n=y0(t);let a;try{a=e(...s)}finally{y0(n),r._d&&k0(1)}return a};return r._n=!0,r._c=!0,r._d=!0,r}function Xs(e,t){if(ni===null)return e;const i=dc(ni),r=e.dirs||(e.dirs=[]);for(let s=0;s<t.length;s++){let[n,a,o,l=et]=t[s];n&&(Ue(n)&&(n={mounted:n,updated:n}),n.deep&&Dr(a),r.push({dir:n,instance:i,value:a,oldValue:void 0,arg:o,modifiers:l}))}return e}function Ns(e,t,i,r){const s=e.dirs,n=t&&t.dirs;for(let a=0;a<s.length;a++){const o=s[a];n&&(o.oldValue=n[a].value);let l=o.dir[r];l&&(Kr(),ir(l,i,8,[e.el,o,e,t]),qr())}}function ps(e,t){if(ri){let i=ri.provides;const r=ri.parent&&ri.parent.provides;r===i&&(i=ri.provides=Object.create(r)),i[e]=t}}function ai(e,t,i=!1){const r=ki();if(r||Js){let s=Js?Js._context.provides:r?r.parent==null||r.ce?r.vnode.appContext&&r.vnode.appContext.provides:r.parent.provides:void 0;if(s&&e in s)return s[e];if(arguments.length>1)return i&&Ue(t)?t.call(r&&r.proxy):t}}function B5(){return!!(ki()||Js)}const Z5=Symbol.for("v-scx"),F5=()=>ai(Z5);function z5(e,t){return Bh(e,null,{flush:"sync"})}function Fe(e,t,i){return Bh(e,t,i)}function Bh(e,t,i=et){const{immediate:r,deep:s,flush:n,once:a}=i,o=Vt({},i),l=t&&r||!t&&n!=="post";let c;if(Nn){if(n==="sync"){const f=F5();c=f.__watcherHandles||(f.__watcherHandles=[])}else if(!l){const f=()=>{};return f.stop=vr,f.resume=vr,f.pause=vr,f}}const u=ri;o.call=(f,m,_)=>ir(f,u,m,_);let h=!1;n==="post"?o.scheduler=f=>{vi(f,u&&u.suspense)}:n!=="sync"&&(h=!0,o.scheduler=(f,m)=>{m?f():Vh(f)}),o.augmentJob=f=>{t&&(f.flags|=4),h&&(f.flags|=2,u&&(f.id=u.uid,f.i=u))};const d=I5(e,t,o);return Nn&&(c?c.push(d):l&&d()),d}function U5(e,t,i){const r=this.proxy,s=At(e)?e.includes(".")?A_(r,e):()=>r[e]:e.bind(r,r);let n;Ue(t)?n=t:(n=t.handler,i=t);const a=yl(this),o=Bh(s,n.bind(r),i);return a(),o}function A_(e,t){const i=t.split(".");return()=>{let r=e;for(let s=0;s<i.length&&r;s++)r=r[i[s]];return r}}const Hs=new WeakMap,M_=Symbol("_vte"),L_=e=>e.__isTeleport,Us=e=>e&&(e.disabled||e.disabled===""),W5=e=>e&&(e.defer||e.defer===""),Xd=e=>typeof SVGElement<"u"&&e instanceof SVGElement,Jd=e=>typeof MathMLElement=="function"&&e instanceof MathMLElement,B1=(e,t)=>{const i=e&&e.to;return At(i)?t?t(i):null:i},j5={name:"Teleport",__isTeleport:!0,process(e,t,i,r,s,n,a,o,l,c){const{mc:u,pc:h,pbc:d,o:{insert:f,querySelector:m,createText:_,createComment:y}}=c,p=Us(t.props);let{dynamicChildren:C}=t;const w=($,M,D)=>{$.shapeFlag&16&&u($.children,M,D,s,n,a,o,l)},v=($=t)=>{const M=Us($.props),D=$.target=B1($.props,m),H=Z1(D,$,_,f);D&&(a!=="svg"&&Xd(D)?a="svg":a!=="mathml"&&Jd(D)&&(a="mathml"),s&&s.isCE&&(s.ce._teleportTargets||(s.ce._teleportTargets=new Set)).add(D),M||(w($,D,H),ko($,!1)))},k=$=>{const M=()=>{Hs.get($)===M&&(Hs.delete($),Us($.props)&&(w($,i,$.anchor),ko($,!0)),v($))};Hs.set($,M),vi(M,n)};if(e==null){const $=t.el=_(""),M=t.anchor=_("");if(f($,i,r),f(M,i,r),W5(t.props)||n&&n.pendingBranch){k(t);return}p&&(w(t,i,M),ko(t,!0)),v()}else{t.el=e.el;const $=t.anchor=e.anchor,M=Hs.get(e);if(M){M.flags|=8,Hs.delete(e),k(t);return}t.targetStart=e.targetStart;const D=t.target=e.target,H=t.targetAnchor=e.targetAnchor,R=Us(e.props),V=R?i:D,N=R?$:H;if(a==="svg"||Xd(D)?a="svg":(a==="mathml"||Jd(D))&&(a="mathml"),C?(d(e.dynamicChildren,C,V,s,n,a,o),Uh(e,t,!0)):l||h(e,t,V,N,s,n,a,o,!1),p)R?t.props&&e.props&&t.props.to!==e.props.to&&(t.props.to=e.props.to):Ol(t,i,$,c,1);else if((t.props&&t.props.to)!==(e.props&&e.props.to)){const P=t.target=B1(t.props,m);P&&Ol(t,P,null,c,0)}else R&&Ol(t,D,H,c,1);ko(t,p)}},remove(e,t,i,{um:r,o:{remove:s}},n){const{shapeFlag:a,children:o,anchor:l,targetStart:c,targetAnchor:u,target:h,props:d}=e;let f=n||!Us(d);const m=Hs.get(e);if(m&&(m.flags|=8,Hs.delete(e),f=!1),h&&(s(c),s(u)),n&&s(l),a&16)for(let _=0;_<o.length;_++){const y=o[_];r(y,t,i,f,!!y.dynamicChildren)}},move:Ol,hydrate:K5};function Ol(e,t,i,{o:{insert:r},m:s},n=2){n===0&&r(e.targetAnchor,t,i);const{el:a,anchor:o,shapeFlag:l,children:c,props:u}=e,h=n===2;if(h&&r(a,t,i),(!h||Us(u))&&l&16)for(let d=0;d<c.length;d++)s(c[d],t,i,2);h&&r(o,t,i)}function K5(e,t,i,r,s,n,{o:{nextSibling:a,parentNode:o,querySelector:l,insert:c,createText:u}},h){function d(y,p){let C=p;for(;C;){if(C&&C.nodeType===8){if(C.data==="teleport start anchor")t.targetStart=C;else if(C.data==="teleport anchor"){t.targetAnchor=C,y._lpa=t.targetAnchor&&a(t.targetAnchor);break}}C=a(C)}}function f(y,p){p.anchor=h(a(y),p,o(y),i,r,s,n)}const m=t.target=B1(t.props,l),_=Us(t.props);if(m){const y=m._lpa||m.firstChild;t.shapeFlag&16&&(_?(f(e,t),d(m,y),t.targetAnchor||Z1(m,t,u,c,o(e)===m?e:null)):(t.anchor=a(e),d(m,y),t.targetAnchor||Z1(m,t,u,c),h(y&&a(y),t,m,i,r,s,n))),ko(t,_)}else _&&t.shapeFlag&16&&(f(e,t),t.targetStart=e,t.targetAnchor=a(e));return t.anchor&&a(t.anchor)}const br=j5;function ko(e,t){const i=e.ctx;if(i&&i.ut){let r,s;for(t?(r=e.el,s=e.anchor):(r=e.targetStart,s=e.targetAnchor);r&&r!==s;)r.nodeType===1&&r.setAttribute("data-v-owner",i.uid),r=r.nextSibling;i.ut()}}function Z1(e,t,i,r,s=null){const n=t.targetStart=i(""),a=t.targetAnchor=i("");return n[M_]=a,e&&(r(n,e,s),r(a,e,s)),a}const fr=Symbol("_leaveCb"),co=Symbol("_enterCb");function q5(){const e={isMounted:!1,isLeaving:!1,isUnmounting:!1,leavingVNodes:new Map};return ut(()=>{e.isMounted=!0}),Gi(()=>{e.isUnmounting=!0}),e}const Vi=[Function,Array],E_={mode:String,appear:Boolean,persisted:Boolean,onBeforeEnter:Vi,onEnter:Vi,onAfterEnter:Vi,onEnterCancelled:Vi,onBeforeLeave:Vi,onLeave:Vi,onAfterLeave:Vi,onLeaveCancelled:Vi,onBeforeAppear:Vi,onAppear:Vi,onAfterAppear:Vi,onAppearCancelled:Vi},$_=e=>{const t=e.subTree;return t.component?$_(t.component):t},G5={name:"BaseTransition",props:E_,setup(e,{slots:t}){const i=ki(),r=q5();return()=>{const s=t.default&&N_(t.default(),!0);if(!s||!s.length)return;const n=x_(s),a=Xe(e),{mode:o}=a;if(r.isLeaving)return Kc(n);const l=Qd(n);if(!l)return Kc(n);let c=F1(l,a,r,i,h=>c=h);l.type!==Xt&&Ko(l,c);let u=i.subTree&&Qd(i.subTree);if(u&&u.type!==Xt&&!Ws(u,l)&&$_(i).type!==Xt){let h=F1(u,a,r,i);if(Ko(u,h),o==="out-in"&&l.type!==Xt)return r.isLeaving=!0,h.afterLeave=()=>{r.isLeaving=!1,i.job.flags&8||i.update(),delete h.afterLeave,u=void 0},Kc(n);o==="in-out"&&l.type!==Xt?h.delayLeave=(d,f,m)=>{const _=T_(r,u);_[String(u.key)]=u,d[fr]=()=>{f(),d[fr]=void 0,delete c.delayedLeave,u=void 0},c.delayedLeave=()=>{m(),delete c.delayedLeave,u=void 0}}:u=void 0}else u&&(u=void 0);return n}}};function x_(e){let t=e[0];if(e.length>1){for(const i of e)if(i.type!==Xt){t=i;break}}return t}const Y5=G5;function T_(e,t){const{leavingVNodes:i}=e;let r=i.get(t.type);return r||(r=Object.create(null),i.set(t.type,r)),r}function F1(e,t,i,r,s){const{appear:n,mode:a,persisted:o=!1,onBeforeEnter:l,onEnter:c,onAfterEnter:u,onEnterCancelled:h,onBeforeLeave:d,onLeave:f,onAfterLeave:m,onLeaveCancelled:_,onBeforeAppear:y,onAppear:p,onAfterAppear:C,onAppearCancelled:w}=t,v=String(e.key),k=T_(i,e),$=(H,R)=>{H&&ir(H,r,9,R)},M=(H,R)=>{const V=R[1];$(H,R),Ve(H)?H.every(N=>N.length<=1)&&V():H.length<=1&&V()},D={mode:a,persisted:o,beforeEnter(H){let R=l;if(!i.isMounted)if(n)R=y||l;else return;H[fr]&&H[fr](!0);const V=k[v];V&&Ws(e,V)&&V.el[fr]&&V.el[fr](),$(R,[H])},enter(H){if(k[v]===e)return;let R=c,V=u,N=h;if(!i.isMounted)if(n)R=p||c,V=C||u,N=w||h;else return;let P=!1;H[co]=j=>{P||(P=!0,j?$(N,[H]):$(V,[H]),D.delayedLeave&&D.delayedLeave(),H[co]=void 0)};const U=H[co].bind(null,!1);R?M(R,[H,U]):U()},leave(H,R){const V=String(e.key);if(H[co]&&H[co](!0),i.isUnmounting)return R();$(d,[H]);let N=!1;H[fr]=U=>{N||(N=!0,R(),U?$(_,[H]):$(m,[H]),H[fr]=void 0,k[V]===e&&delete k[V])};const P=H[fr].bind(null,!1);k[V]=e,f?M(f,[H,P]):P()},clone(H){const R=F1(H,t,i,r,s);return s&&s(R),R}};return D}function Kc(e){if(bl(e))return e=bs(e),e.children=null,e}function Qd(e){if(!bl(e))return L_(e.type)&&e.children?x_(e.children):e;if(e.component)return e.component.subTree;const{shapeFlag:t,children:i}=e;if(i){if(t&16)return i[0];if(t&32&&Ue(i.default))return i.default()}}function Ko(e,t){e.shapeFlag&6&&e.component?(e.transition=t,Ko(e.component.subTree,t)):e.shapeFlag&128?(e.ssContent.transition=t.clone(e.ssContent),e.ssFallback.transition=t.clone(e.ssFallback)):e.transition=t}function N_(e,t=!1,i){let r=[],s=0;for(let n=0;n<e.length;n++){let a=e[n];const o=i==null?a.key:String(i)+String(a.key!=null?a.key:n);a.type===we?(a.patchFlag&128&&s++,r=r.concat(N_(a.children,t,o))):(t||a.type!==Xt)&&r.push(o!=null?bs(a,{key:o}):a)}if(s>1)for(let n=0;n<r.length;n++)r[n].patchFlag=-2;return r}function Re(e,t){return Ue(e)?Vt({name:e.name},t,{setup:e}):e}function qi(){const e=ki();return e?(e.appContext.config.idPrefix||"v")+"-"+e.ids[0]+e.ids[1]++:""}function Zh(e){e.ids=[e.ids[0]+e.ids[2]+++"-",0,0]}function e2(e,t){let i;return!!((i=Object.getOwnPropertyDescriptor(e,t))&&!i.configurable)}const w0=new WeakMap;function Oo(e,t,i,r,s=!1){if(Ve(e)){e.forEach((_,y)=>Oo(_,t&&(Ve(t)?t[y]:t),i,r,s));return}if($n(r)&&!s){r.shapeFlag&512&&r.type.__asyncResolved&&r.component.subTree.component&&Oo(e,t,i,r.component.subTree);return}const n=r.shapeFlag&4?dc(r.component):r.el,a=s?null:n,{i:o,r:l}=e,c=t&&t.r,u=o.refs===et?o.refs={}:o.refs,h=o.setupState,d=Xe(h),f=h===et?jp:_=>e2(u,_)?!1:nt(d,_),m=(_,y)=>!(y&&e2(u,y));if(c!=null&&c!==l){if(t2(t),At(c))u[c]=null,f(c)&&(h[c]=null);else if(wt(c)){const _=t;m(c,_.k)&&(c.value=null),_.k&&(u[_.k]=null)}}if(Ue(l))gl(l,o,12,[a,u]);else{const _=At(l),y=wt(l);if(_||y){const p=()=>{if(e.f){const C=_?f(l)?h[l]:u[l]:m()||!e.k?l.value:u[e.k];if(s)Ve(C)&&xh(C,n);else if(Ve(C))C.includes(n)||C.push(n);else if(_)u[l]=[n],f(l)&&(h[l]=u[l]);else{const w=[n];m(l,e.k)&&(l.value=w),e.k&&(u[e.k]=w)}}else _?(u[l]=a,f(l)&&(h[l]=a)):y&&(m(l,e.k)&&(l.value=a),e.k&&(u[e.k]=a))};if(a){const C=()=>{p(),w0.delete(e)};C.id=-1,w0.set(e,C),vi(C,i)}else t2(e),p()}}}function t2(e){const t=w0.get(e);t&&(t.flags|=8,w0.delete(e))}const i2=e=>e.nodeType===8;nc().requestIdleCallback;nc().cancelIdleCallback;function X5(e,t){if(i2(e)&&e.data==="["){let i=1,r=e.nextSibling;for(;r;){if(r.nodeType===1){if(t(r)===!1)break}else if(i2(r))if(r.data==="]"){if(--i===0)break}else r.data==="["&&i++;r=r.nextSibling}}else t(e)}const $n=e=>!!e.type.__asyncLoader;function J5(e){Ue(e)&&(e={loader:e});const{loader:t,loadingComponent:i,errorComponent:r,delay:s=200,hydrate:n,timeout:a,suspensible:o=!0,onError:l}=e;let c=null,u,h=0;const d=()=>(h++,c=null,f()),f=()=>{let m;return c||(m=c=t().catch(_=>{if(_=_ instanceof Error?_:new Error(String(_)),l)return new Promise((y,p)=>{l(_,()=>y(d()),()=>p(_),h+1)});throw _}).then(_=>m!==c&&c?c:(_&&(_.__esModule||_[Symbol.toStringTag]==="Module")&&(_=_.default),u=_,_)))};return Re({name:"AsyncComponentWrapper",__asyncLoader:f,__asyncHydrate(m,_,y){let p=!1;(_.bu||(_.bu=[])).push(()=>p=!0);const C=()=>{p||y()},w=n?()=>{const v=n(C,k=>X5(m,k));v&&(_.bum||(_.bum=[])).push(v)}:C;u?w():f().then(()=>!_.isUnmounted&&w())},get __asyncResolved(){return u},setup(){const m=ri;if(Zh(m),u)return()=>Il(u,m);const _=w=>{c=null,vl(w,m,13,!r)};if(o&&m.suspense||Nn)return f().then(w=>()=>Il(w,m)).catch(w=>(_(w),()=>r?Y(r,{error:w}):null));const y=X(!1),p=X(),C=X(!!s);return s&&setTimeout(()=>{C.value=!1},s),a!=null&&setTimeout(()=>{if(!y.value&&!p.value){const w=new Error(`Async component timed out after ${a}ms.`);_(w),p.value=w}},a),f().then(()=>{y.value=!0,m.parent&&bl(m.parent.vnode)&&m.parent.update()}).catch(w=>{_(w),p.value=w}),()=>{if(y.value&&u)return Il(u,m);if(p.value&&r)return Y(r,{error:p.value});if(i&&!C.value)return Il(i,m)}}})}function Il(e,t){const{ref:i,props:r,children:s,ce:n}=t.vnode,a=Y(e,r,s);return a.ref=i,a.ce=n,delete t.vnode.ce,a}const bl=e=>e.type.__isKeepAlive;function Q5(e,t){H_(e,"a",t)}function e3(e,t){H_(e,"da",t)}function H_(e,t,i=ri){const r=e.__wdc||(e.__wdc=()=>{let s=i;for(;s;){if(s.isDeactivated)return;s=s.parent}return e()});if(cc(t,r,i),i){let s=i.parent;for(;s&&s.parent;)bl(s.parent.vnode)&&t3(r,t,i,s),s=s.parent}}function t3(e,t,i,r){const s=cc(t,e,r,!0);Ii(()=>{xh(r[t],s)},i)}function cc(e,t,i=ri,r=!1){if(i){const s=i[e]||(i[e]=[]),n=t.__weh||(t.__weh=(...a)=>{Kr();const o=yl(i),l=ir(t,i,e,a);return o(),qr(),l});return r?s.unshift(n):s.push(n),n}}const Xr=e=>(t,i=ri)=>{(!Nn||e==="sp")&&cc(e,(...r)=>t(...r),i)},i3=Xr("bm"),ut=Xr("m"),r3=Xr("bu"),s3=Xr("u"),Gi=Xr("bum"),Ii=Xr("um"),n3=Xr("sp"),a3=Xr("rtg"),o3=Xr("rtc");function l3(e,t=ri){cc("ec",e,t)}const P_="components";function qo(e,t){return I_(P_,e,!0,t)||e}const O_=Symbol.for("v-ndc");function uc(e){return At(e)?I_(P_,e,!1)||e:e||O_}function I_(e,t,i=!0,r=!1){const s=ni||ri;if(s){const n=s.type;{const o=U3(n,!1);if(o&&(o===t||o===pi(t)||o===rc(pi(t))))return n}const a=r2(s[e]||n[e],t)||r2(s.appContext[e],t);return!a&&r?n:a}}function r2(e,t){return e&&(e[t]||e[pi(t)]||e[rc(pi(t))])}function Be(e,t,i,r){let s;const n=i&&i[r],a=Ve(e);if(a||At(e)){const o=a&&jr(e);let l=!1,c=!1;o&&(l=!Hi(e),c=Gr(e),e=oc(e)),s=new Array(e.length);for(let u=0,h=e.length;u<h;u++)s[u]=t(l?c?Tn(tr(e[u])):tr(e[u]):e[u],u,void 0,n&&n[u])}else if(typeof e=="number"){s=new Array(e);for(let o=0;o<e;o++)s[o]=t(o+1,o,void 0,n&&n[o])}else if(tt(e))if(e[Symbol.iterator])s=Array.from(e,(o,l)=>t(o,l,void 0,n&&n[l]));else{const o=Object.keys(e);s=new Array(o.length);for(let l=0,c=o.length;l<c;l++){const u=o[l];s[l]=t(e[u],u,l,n&&n[l])}}else s=[];return i&&(i[r]=s),s}function R_(e,t){for(let i=0;i<t.length;i++){const r=t[i];if(Ve(r))for(let s=0;s<r.length;s++)e[r[s].name]=r[s].fn;else r&&(e[r.name]=r.key?(...s)=>{const n=r.fn(...s);return n&&(n.key=r.key),n}:r.fn)}return e}function Pe(e,t,i={},r,s){if(ni.ce||ni.parent&&$n(ni.parent)&&ni.parent.ce){const c=Object.keys(i).length>0;return t!=="default"&&(i.name=t),g(),de(we,null,[Y("slot",i,r&&r())],c?-2:64)}let n=e[t];n&&n._c&&(n._d=!1),g();const a=n&&D_(n(i)),o=i.key||a&&a.key,l=de(we,{key:(o&&!Oi(o)?o:`_${t}`)+(!a&&r?"_fb":"")},a||(r?r():[]),a&&e._===1?64:-2);return!s&&l.scopeId&&(l.slotScopeIds=[l.scopeId+"-s"]),n&&n._c&&(n._d=!0),l}function D_(e){return e.some(t=>Yo(t)?!(t.type===Xt||t.type===we&&!D_(t.children)):!0)?e:null}const z1=e=>e?am(e)?dc(e):z1(e.parent):null,Io=Vt(Object.create(null),{$:e=>e,$el:e=>e.vnode.el,$data:e=>e.data,$props:e=>e.props,$attrs:e=>e.attrs,$slots:e=>e.slots,$refs:e=>e.refs,$parent:e=>z1(e.parent),$root:e=>z1(e.root),$host:e=>e.ce,$emit:e=>e.emit,$options:e=>Z_(e),$forceUpdate:e=>e.f||(e.f=()=>{Vh(e.update)}),$nextTick:e=>e.n||(e.n=_i.bind(e.proxy)),$watch:e=>U5.bind(e)}),qc=(e,t)=>e!==et&&!e.__isScriptSetup&&nt(e,t),c3={get({_:e},t){if(t==="__v_skip")return!0;const{ctx:i,setupState:r,data:s,props:n,accessCache:a,type:o,appContext:l}=e;if(t[0]!=="$"){const d=a[t];if(d!==void 0)switch(d){case 1:return r[t];case 2:return s[t];case 4:return i[t];case 3:return n[t]}else{if(qc(r,t))return a[t]=1,r[t];if(s!==et&&nt(s,t))return a[t]=2,s[t];if(nt(n,t))return a[t]=3,n[t];if(i!==et&&nt(i,t))return a[t]=4,i[t];U1&&(a[t]=0)}}const c=Io[t];let u,h;if(c)return t==="$attrs"&&fi(e.attrs,"get",""),c(e);if((u=o.__cssModules)&&(u=u[t]))return u;if(i!==et&&nt(i,t))return a[t]=4,i[t];if(h=l.config.globalProperties,nt(h,t))return h[t]},set({_:e},t,i){const{data:r,setupState:s,ctx:n}=e;return qc(s,t)?(s[t]=i,!0):r!==et&&nt(r,t)?(r[t]=i,!0):nt(e.props,t)||t[0]==="$"&&t.slice(1)in e?!1:(n[t]=i,!0)},has({_:{data:e,setupState:t,accessCache:i,ctx:r,appContext:s,props:n,type:a}},o){let l;return!!(i[o]||e!==et&&o[0]!=="$"&&nt(e,o)||qc(t,o)||nt(n,o)||nt(r,o)||nt(Io,o)||nt(s.config.globalProperties,o)||(l=a.__cssModules)&&l[o])},defineProperty(e,t,i){return i.get!=null?e._.accessCache[t]=0:nt(i,"value")&&this.set(e,t,i.value,null),Reflect.defineProperty(e,t,i)}};function ks(){return u3().slots}function u3(e){const t=ki();return t.setupContext||(t.setupContext=lm(t))}function S0(e){return Ve(e)?e.reduce((t,i)=>(t[i]=null,t),{}):e}function V_(e,t){return!e||!t?e||t:Ve(e)&&Ve(t)?e.concat(t):Vt({},S0(e),S0(t))}let U1=!0;function h3(e){const t=Z_(e),i=e.proxy,r=e.ctx;U1=!1,t.beforeCreate&&s2(t.beforeCreate,e,"bc");const{data:s,computed:n,methods:a,watch:o,provide:l,inject:c,created:u,beforeMount:h,mounted:d,beforeUpdate:f,updated:m,activated:_,deactivated:y,beforeDestroy:p,beforeUnmount:C,destroyed:w,unmounted:v,render:k,renderTracked:$,renderTriggered:M,errorCaptured:D,serverPrefetch:H,expose:R,inheritAttrs:V,components:N,directives:P,filters:U}=t;if(c&&d3(c,r,null),a)for(const te in a){const ne=a[te];Ue(ne)&&(r[te]=ne.bind(i))}if(s){const te=s.call(i,i);tt(te)&&(e.data=tn(te))}if(U1=!0,n)for(const te in n){const ne=n[te],J=Ue(ne)?ne.bind(i,i):Ue(ne.get)?ne.get.bind(i,i):vr,fe=!Ue(ne)&&Ue(ne.set)?ne.set.bind(i):vr,re=Q({get:J,set:fe});Object.defineProperty(r,te,{enumerable:!0,configurable:!0,get:()=>re.value,set:_e=>re.value=_e})}if(o)for(const te in o)B_(o[te],r,i,te);if(l){const te=Ue(l)?l.call(i):l;Reflect.ownKeys(te).forEach(ne=>{ps(ne,te[ne])})}u&&s2(u,e,"c");function oe(te,ne){Ve(ne)?ne.forEach(J=>te(J.bind(i))):ne&&te(ne.bind(i))}if(oe(i3,h),oe(ut,d),oe(r3,f),oe(s3,m),oe(Q5,_),oe(e3,y),oe(l3,D),oe(o3,$),oe(a3,M),oe(Gi,C),oe(Ii,v),oe(n3,H),Ve(R))if(R.length){const te=e.exposed||(e.exposed={});R.forEach(ne=>{Object.defineProperty(te,ne,{get:()=>i[ne],set:J=>i[ne]=J,enumerable:!0})})}else e.exposed||(e.exposed={});k&&e.render===vr&&(e.render=k),V!=null&&(e.inheritAttrs=V),N&&(e.components=N),P&&(e.directives=P),H&&Zh(e)}function d3(e,t,i=vr){Ve(e)&&(e=W1(e));for(const r in e){const s=e[r];let n;tt(s)?"default"in s?n=ai(s.from||r,s.default,!0):n=ai(s.from||r):n=ai(s),wt(n)?Object.defineProperty(t,r,{enumerable:!0,configurable:!0,get:()=>n.value,set:a=>n.value=a}):t[r]=n}}function s2(e,t,i){ir(Ve(e)?e.map(r=>r.bind(t.proxy)):e.bind(t.proxy),t,i)}function B_(e,t,i,r){let s=r.includes(".")?A_(i,r):()=>i[r];if(At(e)){const n=t[e];Ue(n)&&Fe(s,n)}else if(Ue(e))Fe(s,e.bind(i));else if(tt(e))if(Ve(e))e.forEach(n=>B_(n,t,i,r));else{const n=Ue(e.handler)?e.handler.bind(i):t[e.handler];Ue(n)&&Fe(s,n,e)}}function Z_(e){const t=e.type,{mixins:i,extends:r}=t,{mixins:s,optionsCache:n,config:{optionMergeStrategies:a}}=e.appContext,o=n.get(t);let l;return o?l=o:!s.length&&!i&&!r?l=t:(l={},s.length&&s.forEach(c=>C0(l,c,a,!0)),C0(l,t,a)),tt(t)&&n.set(t,l),l}function C0(e,t,i,r=!1){const{mixins:s,extends:n}=t;n&&C0(e,n,i,!0),s&&s.forEach(a=>C0(e,a,i,!0));for(const a in t)if(!(r&&a==="expose")){const o=f3[a]||i&&i[a];e[a]=o?o(e[a],t[a]):t[a]}return e}const f3={data:n2,props:a2,emits:a2,methods:Ao,computed:Ao,beforeCreate:mi,created:mi,beforeMount:mi,mounted:mi,beforeUpdate:mi,updated:mi,beforeDestroy:mi,beforeUnmount:mi,destroyed:mi,unmounted:mi,activated:mi,deactivated:mi,errorCaptured:mi,serverPrefetch:mi,components:Ao,directives:Ao,watch:_3,provide:n2,inject:p3};function n2(e,t){return t?e?function(){return Vt(Ue(e)?e.call(this,this):e,Ue(t)?t.call(this,this):t)}:t:e}function p3(e,t){return Ao(W1(e),W1(t))}function W1(e){if(Ve(e)){const t={};for(let i=0;i<e.length;i++)t[e[i]]=e[i];return t}return e}function mi(e,t){return e?[...new Set([].concat(e,t))]:t}function Ao(e,t){return e?Vt(Object.create(null),e,t):t}function a2(e,t){return e?Ve(e)&&Ve(t)?[...new Set([...e,...t])]:Vt(Object.create(null),S0(e),S0(t??{})):t}function _3(e,t){if(!e)return t;if(!t)return e;const i=Vt(Object.create(null),e);for(const r in t)i[r]=mi(e[r],t[r]);return i}function F_(){return{app:null,config:{isNativeTag:jp,performance:!1,globalProperties:{},optionMergeStrategies:{},errorHandler:void 0,warnHandler:void 0,compilerOptions:{}},mixins:[],components:{},directives:{},provides:Object.create(null),optionsCache:new WeakMap,propsCache:new WeakMap,emitsCache:new WeakMap}}let m3=0;function g3(e,t){return function(r,s=null){Ue(r)||(r=Vt({},r)),s!=null&&!tt(s)&&(s=null);const n=F_(),a=new WeakSet,o=[];let l=!1;const c=n.app={_uid:m3++,_component:r,_props:s,_container:null,_context:n,_instance:null,version:j3,get config(){return n.config},set config(u){},use(u,...h){return a.has(u)||(u&&Ue(u.install)?(a.add(u),u.install(c,...h)):Ue(u)&&(a.add(u),u(c,...h))),c},mixin(u){return n.mixins.includes(u)||n.mixins.push(u),c},component(u,h){return h?(n.components[u]=h,c):n.components[u]},directive(u,h){return h?(n.directives[u]=h,c):n.directives[u]},mount(u,h,d){if(!l){const f=c._ceVNode||Y(r,s);return f.appContext=n,d===!0?d="svg":d===!1&&(d=void 0),e(f,u,d),l=!0,c._container=u,u.__vue_app__=c,dc(f.component)}},onUnmount(u){o.push(u)},unmount(){l&&(ir(o,c._instance,16),e(null,c._container),delete c._container.__vue_app__)},provide(u,h){return n.provides[u]=h,c},runWithContext(u){const h=Js;Js=c;try{return u()}finally{Js=h}}};return c}}let Js=null;function z_(e,t,i=et){const r=ki(),s=pi(t),n=Yr(t),a=U_(e,s),o=E5((l,c)=>{let u,h=et,d;return z5(()=>{const f=e[s];di(u,f)&&(u=f,c())}),{get(){return l(),i.get?i.get(u):u},set(f){const m=i.set?i.set(f):f;if(!di(m,u)&&!(h!==et&&di(f,h)))return;const _=r.vnode.props;_&&(t in _||s in _||n in _)&&(`onUpdate:${t}`in _||`onUpdate:${s}`in _||`onUpdate:${n}`in _)||(u=f,c()),r.emit(`update:${t}`,m),di(f,m)&&di(f,h)&&!di(m,d)&&c(),h=f,d=m}}});return o[Symbol.iterator]=()=>{let l=0;return{next(){return l<2?{value:l++?a||et:o,done:!1}:{done:!0}}}},o}const U_=(e,t)=>t==="modelValue"||t==="model-value"?e.modelModifiers:e[`${t}Modifiers`]||e[`${pi(t)}Modifiers`]||e[`${Yr(t)}Modifiers`];function v3(e,t,...i){if(e.isUnmounted)return;const r=e.vnode.props||et;let s=i;const n=t.startsWith("update:"),a=n&&U_(r,t.slice(7));a&&(a.trim&&(s=i.map(u=>At(u)?u.trim():u)),a.number&&(s=i.map(sc)));let o,l=r[o=Fc(t)]||r[o=Fc(pi(t))];!l&&n&&(l=r[o=Fc(Yr(t))]),l&&ir(l,e,6,s);const c=r[o+"Once"];if(c){if(!e.emitted)e.emitted={};else if(e.emitted[o])return;e.emitted[o]=!0,ir(c,e,6,s)}}const b3=new WeakMap;function W_(e,t,i=!1){const r=i?b3:t.emitsCache,s=r.get(e);if(s!==void 0)return s;const n=e.emits;let a={},o=!1;if(!Ue(e)){const l=c=>{const u=W_(c,t,!0);u&&(o=!0,Vt(a,u))};!i&&t.mixins.length&&t.mixins.forEach(l),e.extends&&l(e.extends),e.mixins&&e.mixins.forEach(l)}return!n&&!o?(tt(e)&&r.set(e,null),null):(Ve(n)?n.forEach(l=>a[l]=null):Vt(a,n),tt(e)&&r.set(e,a),a)}function hc(e,t){return!e||!Q0(t)?!1:(t=t.slice(2).replace(/Once$/,""),nt(e,t[0].toLowerCase()+t.slice(1))||nt(e,Yr(t))||nt(e,t))}function o2(e){const{type:t,vnode:i,proxy:r,withProxy:s,propsOptions:[n],slots:a,attrs:o,emit:l,render:c,renderCache:u,props:h,data:d,setupState:f,ctx:m,inheritAttrs:_}=e,y=y0(e);let p,C;try{if(i.shapeFlag&4){const v=s||r,k=v;p=_r(c.call(k,v,u,h,f,d,m)),C=o}else{const v=t;p=_r(v.length>1?v(h,{attrs:o,slots:a,emit:l}):v(h,null)),C=t.props?o:y3(o)}}catch(v){Ro.length=0,vl(v,e,1),p=Y(Xt)}let w=p;if(C&&_!==!1){const v=Object.keys(C),{shapeFlag:k}=w;v.length&&k&7&&(n&&v.some(ec)&&(C=w3(C,n)),w=bs(w,C,!1,!0))}return i.dirs&&(w=bs(w,null,!1,!0),w.dirs=w.dirs?w.dirs.concat(i.dirs):i.dirs),i.transition&&Ko(w,i.transition),p=w,y0(y),p}const y3=e=>{let t;for(const i in e)(i==="class"||i==="style"||Q0(i))&&((t||(t={}))[i]=e[i]);return t},w3=(e,t)=>{const i={};for(const r in e)(!ec(r)||!(r.slice(9)in t))&&(i[r]=e[r]);return i};function S3(e,t,i){const{props:r,children:s,component:n}=e,{props:a,children:o,patchFlag:l}=t,c=n.emitsOptions;if(t.dirs||t.transition)return!0;if(i&&l>=0){if(l&1024)return!0;if(l&16)return r?l2(r,a,c):!!a;if(l&8){const u=t.dynamicProps;for(let h=0;h<u.length;h++){const d=u[h];if(j_(a,r,d)&&!hc(c,d))return!0}}}else return(s||o)&&(!o||!o.$stable)?!0:r===a?!1:r?a?l2(r,a,c):!0:!!a;return!1}function l2(e,t,i){const r=Object.keys(t);if(r.length!==Object.keys(e).length)return!0;for(let s=0;s<r.length;s++){const n=r[s];if(j_(t,e,n)&&!hc(i,n))return!0}return!1}function j_(e,t,i){const r=e[i],s=t[i];return i==="style"&&tt(r)&&tt(s)?!vs(r,s):r!==s}function C3({vnode:e,parent:t,suspense:i},r){for(;t;){const s=t.subTree;if(s.suspense&&s.suspense.activeBranch===e&&(s.suspense.vnode.el=s.el=r,e=s),s===e)(e=t.vnode).el=r,t=t.parent;else break}i&&i.activeBranch===e&&(i.vnode.el=r)}const K_={},q_=()=>Object.create(K_),G_=e=>Object.getPrototypeOf(e)===K_;function k3(e,t,i,r=!1){const s={},n=q_();e.propsDefaults=Object.create(null),Y_(e,t,s,n);for(const a in e.propsOptions[0])a in s||(s[a]=void 0);i?e.props=r?s:m_(s):e.type.props?e.props=s:e.props=n,e.attrs=n}function A3(e,t,i,r){const{props:s,attrs:n,vnode:{patchFlag:a}}=e,o=Xe(s),[l]=e.propsOptions;let c=!1;if((r||a>0)&&!(a&16)){if(a&8){const u=e.vnode.dynamicProps;for(let h=0;h<u.length;h++){let d=u[h];if(hc(e.emitsOptions,d))continue;const f=t[d];if(l)if(nt(n,d))f!==n[d]&&(n[d]=f,c=!0);else{const m=pi(d);s[m]=j1(l,o,m,f,e,!1)}else f!==n[d]&&(n[d]=f,c=!0)}}}else{Y_(e,t,s,n)&&(c=!0);let u;for(const h in o)(!t||!nt(t,h)&&((u=Yr(h))===h||!nt(t,u)))&&(l?i&&(i[h]!==void 0||i[u]!==void 0)&&(s[h]=j1(l,o,h,void 0,e,!0)):delete s[h]);if(n!==o)for(const h in n)(!t||!nt(t,h))&&(delete n[h],c=!0)}c&&Rr(e.attrs,"set","")}function Y_(e,t,i,r){const[s,n]=e.propsOptions;let a=!1,o;if(t)for(let l in t){if(No(l))continue;const c=t[l];let u;s&&nt(s,u=pi(l))?!n||!n.includes(u)?i[u]=c:(o||(o={}))[u]=c:hc(e.emitsOptions,l)||(!(l in r)||c!==r[l])&&(r[l]=c,a=!0)}if(n){const l=Xe(i),c=o||et;for(let u=0;u<n.length;u++){const h=n[u];i[h]=j1(s,l,h,c[h],e,!nt(c,h))}}return a}function j1(e,t,i,r,s,n){const a=e[i];if(a!=null){const o=nt(a,"default");if(o&&r===void 0){const l=a.default;if(a.type!==Function&&!a.skipFactory&&Ue(l)){const{propsDefaults:c}=s;if(i in c)r=c[i];else{const u=yl(s);r=c[i]=l.call(null,t),u()}}else r=l;s.ce&&s.ce._setProp(i,r)}a[0]&&(n&&!o?r=!1:a[1]&&(r===""||r===Yr(i))&&(r=!0))}return r}const M3=new WeakMap;function X_(e,t,i=!1){const r=i?M3:t.propsCache,s=r.get(e);if(s)return s;const n=e.props,a={},o=[];let l=!1;if(!Ue(e)){const u=h=>{l=!0;const[d,f]=X_(h,t,!0);Vt(a,d),f&&o.push(...f)};!i&&t.mixins.length&&t.mixins.forEach(u),e.extends&&u(e.extends),e.mixins&&e.mixins.forEach(u)}if(!n&&!l)return tt(e)&&r.set(e,Mn),Mn;if(Ve(n))for(let u=0;u<n.length;u++){const h=pi(n[u]);c2(h)&&(a[h]=et)}else if(n)for(const u in n){const h=pi(u);if(c2(h)){const d=n[u],f=a[h]=Ve(d)||Ue(d)?{type:d}:Vt({},d),m=f.type;let _=!1,y=!0;if(Ve(m))for(let p=0;p<m.length;++p){const C=m[p],w=Ue(C)&&C.name;if(w==="Boolean"){_=!0;break}else w==="String"&&(y=!1)}else _=Ue(m)&&m.name==="Boolean";f[0]=_,f[1]=y,(_||nt(f,"default"))&&o.push(h)}}const c=[a,o];return tt(e)&&r.set(e,c),c}function c2(e){return e[0]!=="$"&&!No(e)}const Fh=e=>e==="_"||e==="_ctx"||e==="$stable",zh=e=>Ve(e)?e.map(_r):[_r(e)],L3=(e,t,i)=>{if(t._n)return t;const r=ee((...s)=>zh(t(...s)),i);return r._c=!1,r},J_=(e,t,i)=>{const r=e._ctx;for(const s in e){if(Fh(s))continue;const n=e[s];if(Ue(n))t[s]=L3(s,n,r);else if(n!=null){const a=zh(n);t[s]=()=>a}}},Q_=(e,t)=>{const i=zh(t);e.slots.default=()=>i},em=(e,t,i)=>{for(const r in t)(i||!Fh(r))&&(e[r]=t[r])},E3=(e,t,i)=>{const r=e.slots=q_();if(e.vnode.shapeFlag&32){const s=t._;s?(em(r,t,i),i&&Yp(r,"_",s,!0)):J_(t,r)}else t&&Q_(e,t)},$3=(e,t,i)=>{const{vnode:r,slots:s}=e;let n=!0,a=et;if(r.shapeFlag&32){const o=t._;o?i&&o===1?n=!1:em(s,t,i):(n=!t.$stable,J_(t,s)),a=t}else t&&(Q_(e,t),a={default:1});if(n)for(const o in s)!Fh(o)&&a[o]==null&&delete s[o]},vi=P3;function x3(e){return T3(e)}function T3(e,t){const i=nc();i.__VUE__=!0;const{insert:r,remove:s,patchProp:n,createElement:a,createText:o,createComment:l,setText:c,setElementText:u,parentNode:h,nextSibling:d,setScopeId:f=vr,insertStaticContent:m}=e,_=(x,T,K,se=null,he=null,pe=null,S=void 0,A=null,B=!!T.dynamicChildren)=>{if(x===T)return;x&&!Ws(x,T)&&(se=O(x),_e(x,he,pe,!0),x=null),T.patchFlag===-2&&(B=!1,T.dynamicChildren=null);const{type:L,ref:I,shapeFlag:z}=T;switch(L){case As:y(x,T,K,se);break;case Xt:p(x,T,K,se);break;case Yc:x==null&&C(T,K,se,S);break;case we:N(x,T,K,se,he,pe,S,A,B);break;default:z&1?k(x,T,K,se,he,pe,S,A,B):z&6?P(x,T,K,se,he,pe,S,A,B):(z&64||z&128)&&L.process(x,T,K,se,he,pe,S,A,B,ge)}I!=null&&he?Oo(I,x&&x.ref,pe,T||x,!T):I==null&&x&&x.ref!=null&&Oo(x.ref,null,pe,x,!0)},y=(x,T,K,se)=>{if(x==null)r(T.el=o(T.children),K,se);else{const he=T.el=x.el;T.children!==x.children&&c(he,T.children)}},p=(x,T,K,se)=>{x==null?r(T.el=l(T.children||""),K,se):T.el=x.el},C=(x,T,K,se)=>{[x.el,x.anchor]=m(x.children,T,K,se,x.el,x.anchor)},w=({el:x,anchor:T},K,se)=>{let he;for(;x&&x!==T;)he=d(x),r(x,K,se),x=he;r(T,K,se)},v=({el:x,anchor:T})=>{let K;for(;x&&x!==T;)K=d(x),s(x),x=K;s(T)},k=(x,T,K,se,he,pe,S,A,B)=>{if(T.type==="svg"?S="svg":T.type==="math"&&(S="mathml"),x==null)$(T,K,se,he,pe,S,A,B);else{const L=x.el&&x.el._isVueCE?x.el:null;try{L&&L._beginPatch(),H(x,T,he,pe,S,A,B)}finally{L&&L._endPatch()}}},$=(x,T,K,se,he,pe,S,A)=>{let B,L;const{props:I,shapeFlag:z,transition:W,dirs:ae}=x;if(B=x.el=a(x.type,pe,I&&I.is,I),z&8?u(B,x.children):z&16&&D(x.children,B,null,se,he,Gc(x,pe),S,A),ae&&Ns(x,null,se,"created"),M(B,x,x.scopeId,S,se),I){for(const ke in I)ke!=="value"&&!No(ke)&&n(B,ke,null,I[ke],pe,se);"value"in I&&n(B,"value",null,I.value,pe),(L=I.onVnodeBeforeMount)&&sr(L,se,x)}ae&&Ns(x,null,se,"beforeMount");const ye=N3(he,W);ye&&W.beforeEnter(B),r(B,T,K),((L=I&&I.onVnodeMounted)||ye||ae)&&vi(()=>{try{L&&sr(L,se,x),ye&&W.enter(B),ae&&Ns(x,null,se,"mounted")}finally{}},he)},M=(x,T,K,se,he)=>{if(K&&f(x,K),se)for(let pe=0;pe<se.length;pe++)f(x,se[pe]);if(he){let pe=he.subTree;if(T===pe||rm(pe.type)&&(pe.ssContent===T||pe.ssFallback===T)){const S=he.vnode;M(x,S,S.scopeId,S.slotScopeIds,he.parent)}}},D=(x,T,K,se,he,pe,S,A,B=0)=>{for(let L=B;L<x.length;L++){const I=x[L]=A?Ir(x[L]):_r(x[L]);_(null,I,T,K,se,he,pe,S,A)}},H=(x,T,K,se,he,pe,S)=>{const A=T.el=x.el;let{patchFlag:B,dynamicChildren:L,dirs:I}=T;B|=x.patchFlag&16;const z=x.props||et,W=T.props||et;let ae;if(K&&Ps(K,!1),(ae=W.onVnodeBeforeUpdate)&&sr(ae,K,T,x),I&&Ns(T,x,K,"beforeUpdate"),K&&Ps(K,!0),(z.innerHTML&&W.innerHTML==null||z.textContent&&W.textContent==null)&&u(A,""),L?R(x.dynamicChildren,L,A,K,se,Gc(T,he),pe):S||ne(x,T,A,null,K,se,Gc(T,he),pe,!1),B>0){if(B&16)V(A,z,W,K,he);else if(B&2&&z.class!==W.class&&n(A,"class",null,W.class,he),B&4&&n(A,"style",z.style,W.style,he),B&8){const ye=T.dynamicProps;for(let ke=0;ke<ye.length;ke++){const Oe=ye[ke],je=z[Oe],Ee=W[Oe];(Ee!==je||Oe==="value")&&n(A,Oe,je,Ee,he,K)}}B&1&&x.children!==T.children&&u(A,T.children)}else!S&&L==null&&V(A,z,W,K,he);((ae=W.onVnodeUpdated)||I)&&vi(()=>{ae&&sr(ae,K,T,x),I&&Ns(T,x,K,"updated")},se)},R=(x,T,K,se,he,pe,S)=>{for(let A=0;A<T.length;A++){const B=x[A],L=T[A],I=B.el&&(B.type===we||!Ws(B,L)||B.shapeFlag&198)?h(B.el):K;_(B,L,I,null,se,he,pe,S,!0)}},V=(x,T,K,se,he)=>{if(T!==K){if(T!==et)for(const pe in T)!No(pe)&&!(pe in K)&&n(x,pe,T[pe],null,he,se);for(const pe in K){if(No(pe))continue;const S=K[pe],A=T[pe];S!==A&&pe!=="value"&&n(x,pe,A,S,he,se)}"value"in K&&n(x,"value",T.value,K.value,he)}},N=(x,T,K,se,he,pe,S,A,B)=>{const L=T.el=x?x.el:o(""),I=T.anchor=x?x.anchor:o("");let{patchFlag:z,dynamicChildren:W,slotScopeIds:ae}=T;ae&&(A=A?A.concat(ae):ae),x==null?(r(L,K,se),r(I,K,se),D(T.children||[],K,I,he,pe,S,A,B)):z>0&&z&64&&W&&x.dynamicChildren&&x.dynamicChildren.length===W.length?(R(x.dynamicChildren,W,K,he,pe,S,A),(T.key!=null||he&&T===he.subTree)&&Uh(x,T,!0)):ne(x,T,K,I,he,pe,S,A,B)},P=(x,T,K,se,he,pe,S,A,B)=>{T.slotScopeIds=A,x==null?T.shapeFlag&512?he.ctx.activate(T,K,se,S,B):U(T,K,se,he,pe,S,B):j(x,T,B)},U=(x,T,K,se,he,pe,S)=>{const A=x.component=B3(x,se,he);if(bl(x)&&(A.ctx.renderer=ge),Z3(A,!1,S),A.asyncDep){if(he&&he.registerDep(A,oe,S),!x.el){const B=A.subTree=Y(Xt);p(null,B,T,K),x.placeholder=B.el}}else oe(A,x,T,K,he,pe,S)},j=(x,T,K)=>{const se=T.component=x.component;if(S3(x,T,K))if(se.asyncDep&&!se.asyncResolved){te(se,T,K);return}else se.next=T,se.update();else T.el=x.el,se.vnode=T},oe=(x,T,K,se,he,pe,S)=>{const A=()=>{if(x.isMounted){let{next:z,bu:W,u:ae,parent:ye,vnode:ke}=x;{const Ot=tm(x);if(Ot){z&&(z.el=ke.el,te(x,z,S)),Ot.asyncDep.then(()=>{vi(()=>{x.isUnmounted||L()},he)});return}}let Oe=z,je;Ps(x,!1),z?(z.el=ke.el,te(x,z,S)):z=ke,W&&i0(W),(je=z.props&&z.props.onVnodeBeforeUpdate)&&sr(je,ye,z,ke),Ps(x,!0);const Ee=o2(x),lt=x.subTree;x.subTree=Ee,_(lt,Ee,h(lt.el),O(lt),x,he,pe),z.el=Ee.el,Oe===null&&C3(x,Ee.el),ae&&vi(ae,he),(je=z.props&&z.props.onVnodeUpdated)&&vi(()=>sr(je,ye,z,ke),he)}else{let z;const{el:W,props:ae}=T,{bm:ye,m:ke,parent:Oe,root:je,type:Ee}=x,lt=$n(T);Ps(x,!1),ye&&i0(ye),!lt&&(z=ae&&ae.onVnodeBeforeMount)&&sr(z,Oe,T),Ps(x,!0);{je.ce&&je.ce._hasShadowRoot()&&je.ce._injectChildStyle(Ee,x.parent?x.parent.type:void 0);const Ot=x.subTree=o2(x);_(null,Ot,K,se,x,he,pe),T.el=Ot.el}if(ke&&vi(ke,he),!lt&&(z=ae&&ae.onVnodeMounted)){const Ot=T;vi(()=>sr(z,Oe,Ot),he)}(T.shapeFlag&256||Oe&&$n(Oe.vnode)&&Oe.vnode.shapeFlag&256)&&x.a&&vi(x.a,he),x.isMounted=!0,T=K=se=null}};x.scope.on();const B=x.effect=new i_(A);x.scope.off();const L=x.update=B.run.bind(B),I=x.job=B.runIfDirty.bind(B);I.i=x,I.id=x.uid,B.scheduler=()=>Vh(I),Ps(x,!0),L()},te=(x,T,K)=>{T.component=x;const se=x.vnode.props;x.vnode=T,x.next=null,A3(x,T.props,se,K),$3(x,T.children,K),Kr(),Yd(x),qr()},ne=(x,T,K,se,he,pe,S,A,B=!1)=>{const L=x&&x.children,I=x?x.shapeFlag:0,z=T.children,{patchFlag:W,shapeFlag:ae}=T;if(W>0){if(W&128){fe(L,z,K,se,he,pe,S,A,B);return}else if(W&256){J(L,z,K,se,he,pe,S,A,B);return}}ae&8?(I&16&&me(L,he,pe),z!==L&&u(K,z)):I&16?ae&16?fe(L,z,K,se,he,pe,S,A,B):me(L,he,pe,!0):(I&8&&u(K,""),ae&16&&D(z,K,se,he,pe,S,A,B))},J=(x,T,K,se,he,pe,S,A,B)=>{x=x||Mn,T=T||Mn;const L=x.length,I=T.length,z=Math.min(L,I);let W;for(W=0;W<z;W++){const ae=T[W]=B?Ir(T[W]):_r(T[W]);_(x[W],ae,K,null,he,pe,S,A,B)}L>I?me(x,he,pe,!0,!1,z):D(T,K,se,he,pe,S,A,B,z)},fe=(x,T,K,se,he,pe,S,A,B)=>{let L=0;const I=T.length;let z=x.length-1,W=I-1;for(;L<=z&&L<=W;){const ae=x[L],ye=T[L]=B?Ir(T[L]):_r(T[L]);if(Ws(ae,ye))_(ae,ye,K,null,he,pe,S,A,B);else break;L++}for(;L<=z&&L<=W;){const ae=x[z],ye=T[W]=B?Ir(T[W]):_r(T[W]);if(Ws(ae,ye))_(ae,ye,K,null,he,pe,S,A,B);else break;z--,W--}if(L>z){if(L<=W){const ae=W+1,ye=ae<I?T[ae].el:se;for(;L<=W;)_(null,T[L]=B?Ir(T[L]):_r(T[L]),K,ye,he,pe,S,A,B),L++}}else if(L>W)for(;L<=z;)_e(x[L],he,pe,!0),L++;else{const ae=L,ye=L,ke=new Map;for(L=ye;L<=W;L++){const Mt=T[L]=B?Ir(T[L]):_r(T[L]);Mt.key!=null&&ke.set(Mt.key,L)}let Oe,je=0;const Ee=W-ye+1;let lt=!1,Ot=0;const $i=new Array(Ee);for(L=0;L<Ee;L++)$i[L]=0;for(L=ae;L<=z;L++){const Mt=x[L];if(je>=Ee){_e(Mt,he,pe,!0);continue}let li;if(Mt.key!=null)li=ke.get(Mt.key);else for(Oe=ye;Oe<=W;Oe++)if($i[Oe-ye]===0&&Ws(Mt,T[Oe])){li=Oe;break}li===void 0?_e(Mt,he,pe,!0):($i[li-ye]=L+1,li>=Ot?Ot=li:lt=!0,_(Mt,T[li],K,null,he,pe,S,A,B),je++)}const Er=lt?H3($i):Mn;for(Oe=Er.length-1,L=Ee-1;L>=0;L--){const Mt=ye+L,li=T[Mt],es=T[Mt+1],Yi=Mt+1<I?es.el||im(es):se;$i[L]===0?_(null,li,K,Yi,he,pe,S,A,B):lt&&(Oe<0||L!==Er[Oe]?re(li,K,Yi,2):Oe--)}}},re=(x,T,K,se,he=null)=>{const{el:pe,type:S,transition:A,children:B,shapeFlag:L}=x;if(L&6){re(x.component.subTree,T,K,se);return}if(L&128){x.suspense.move(T,K,se);return}if(L&64){S.move(x,T,K,ge);return}if(S===we){r(pe,T,K);for(let z=0;z<B.length;z++)re(B[z],T,K,se);r(x.anchor,T,K);return}if(S===Yc){w(x,T,K);return}if(se!==2&&L&1&&A)if(se===0)A.beforeEnter(pe),r(pe,T,K),vi(()=>A.enter(pe),he);else{const{leave:z,delayLeave:W,afterLeave:ae}=A,ye=()=>{x.ctx.isUnmounted?s(pe):r(pe,T,K)},ke=()=>{pe._isLeaving&&pe[fr](!0),z(pe,()=>{ye(),ae&&ae()})};W?W(pe,ye,ke):ke()}else r(pe,T,K)},_e=(x,T,K,se=!1,he=!1)=>{const{type:pe,props:S,ref:A,children:B,dynamicChildren:L,shapeFlag:I,patchFlag:z,dirs:W,cacheIndex:ae,memo:ye}=x;if(z===-2&&(he=!1),A!=null&&(Kr(),Oo(A,null,K,x,!0),qr()),ae!=null&&(T.renderCache[ae]=void 0),I&256){T.ctx.deactivate(x);return}const ke=I&1&&W,Oe=!$n(x);let je;if(Oe&&(je=S&&S.onVnodeBeforeUnmount)&&sr(je,T,x),I&6)be(x.component,K,se);else{if(I&128){x.suspense.unmount(K,se);return}ke&&Ns(x,null,T,"beforeUnmount"),I&64?x.type.remove(x,T,K,ge,se):L&&!L.hasOnce&&(pe!==we||z>0&&z&64)?me(L,T,K,!1,!0):(pe===we&&z&384||!he&&I&16)&&me(B,T,K),se&&Ne(x)}const Ee=ye!=null&&ae==null;(Oe&&(je=S&&S.onVnodeUnmounted)||ke||Ee)&&vi(()=>{je&&sr(je,T,x),ke&&Ns(x,null,T,"unmounted"),Ee&&(x.el=null)},K)},Ne=x=>{const{type:T,el:K,anchor:se,transition:he}=x;if(T===we){$e(K,se);return}if(T===Yc){v(x);return}const pe=()=>{s(K),he&&!he.persisted&&he.afterLeave&&he.afterLeave()};if(x.shapeFlag&1&&he&&!he.persisted){const{leave:S,delayLeave:A}=he,B=()=>S(K,pe);A?A(x.el,pe,B):B()}else pe()},$e=(x,T)=>{let K;for(;x!==T;)K=d(x),s(x),x=K;s(T)},be=(x,T,K)=>{const{bum:se,scope:he,job:pe,subTree:S,um:A,m:B,a:L}=x;u2(B),u2(L),se&&i0(se),he.stop(),pe&&(pe.flags|=8,_e(S,x,T,K)),A&&vi(A,T),vi(()=>{x.isUnmounted=!0},T)},me=(x,T,K,se=!1,he=!1,pe=0)=>{for(let S=pe;S<x.length;S++)_e(x[S],T,K,se,he)},O=x=>{if(x.shapeFlag&6)return O(x.component.subTree);if(x.shapeFlag&128)return x.suspense.next();const T=d(x.anchor||x.el),K=T&&T[M_];return K?d(K):T};let ie=!1;const le=(x,T,K)=>{let se;x==null?T._vnode&&(_e(T._vnode,null,null,!0),se=T._vnode.component):_(T._vnode||null,x,T,null,null,null,K),T._vnode=x,ie||(ie=!0,Yd(se),S_(),ie=!1)},ge={p:_,um:_e,m:re,r:Ne,mt:U,mc:D,pc:ne,pbc:R,n:O,o:e};return{render:le,hydrate:void 0,createApp:g3(le)}}function Gc({type:e,props:t},i){return i==="svg"&&e==="foreignObject"||i==="mathml"&&e==="annotation-xml"&&t&&t.encoding&&t.encoding.includes("html")?void 0:i}function Ps({effect:e,job:t},i){i?(e.flags|=32,t.flags|=4):(e.flags&=-33,t.flags&=-5)}function N3(e,t){return(!e||e&&!e.pendingBranch)&&t&&!t.persisted}function Uh(e,t,i=!1){const r=e.children,s=t.children;if(Ve(r)&&Ve(s))for(let n=0;n<r.length;n++){const a=r[n];let o=s[n];o.shapeFlag&1&&!o.dynamicChildren&&((o.patchFlag<=0||o.patchFlag===32)&&(o=s[n]=Ir(s[n]),o.el=a.el),!i&&o.patchFlag!==-2&&Uh(a,o)),o.type===As&&(o.patchFlag===-1&&(o=s[n]=Ir(o)),o.el=a.el),o.type===Xt&&!o.el&&(o.el=a.el)}}function H3(e){const t=e.slice(),i=[0];let r,s,n,a,o;const l=e.length;for(r=0;r<l;r++){const c=e[r];if(c!==0){if(s=i[i.length-1],e[s]<c){t[r]=s,i.push(r);continue}for(n=0,a=i.length-1;n<a;)o=n+a>>1,e[i[o]]<c?n=o+1:a=o;c<e[i[n]]&&(n>0&&(t[r]=i[n-1]),i[n]=r)}}for(n=i.length,a=i[n-1];n-- >0;)i[n]=a,a=t[a];return i}function tm(e){const t=e.subTree.component;if(t)return t.asyncDep&&!t.asyncResolved?t:tm(t)}function u2(e){if(e)for(let t=0;t<e.length;t++)e[t].flags|=8}function im(e){if(e.placeholder)return e.placeholder;const t=e.component;return t?im(t.subTree):null}const rm=e=>e.__isSuspense;function P3(e,t){t&&t.pendingBranch?Ve(e)?t.effects.push(...e):t.effects.push(e):V5(e)}const we=Symbol.for("v-fgt"),As=Symbol.for("v-txt"),Xt=Symbol.for("v-cmt"),Yc=Symbol.for("v-stc"),Ro=[];let Ni=null;function g(e=!1){Ro.push(Ni=e?null:[])}function O3(){Ro.pop(),Ni=Ro[Ro.length-1]||null}let Go=1;function k0(e,t=!1){Go+=e,e<0&&Ni&&t&&(Ni.hasOnce=!0)}function sm(e){return e.dynamicChildren=Go>0?Ni||Mn:null,O3(),Go>0&&Ni&&Ni.push(e),e}function E(e,t,i,r,s,n){return sm(b(e,t,i,r,s,n,!0))}function de(e,t,i,r,s){return sm(Y(e,t,i,r,s,!0))}function Yo(e){return e?e.__v_isVNode===!0:!1}function Ws(e,t){return e.type===t.type&&e.key===t.key}const nm=({key:e})=>e??null,r0=({ref:e,ref_key:t,ref_for:i})=>(typeof e=="number"&&(e=""+e),e!=null?At(e)||wt(e)||Ue(e)?{i:ni,r:e,k:t,f:!!i}:e:null);function b(e,t=null,i=null,r=0,s=null,n=e===we?0:1,a=!1,o=!1){const l={__v_isVNode:!0,__v_skip:!0,type:e,props:t,key:t&&nm(t),ref:t&&r0(t),scopeId:k_,slotScopeIds:null,children:i,component:null,suspense:null,ssContent:null,ssFallback:null,dirs:null,transition:null,el:null,anchor:null,target:null,targetStart:null,targetAnchor:null,staticCount:0,shapeFlag:n,patchFlag:r,dynamicProps:s,dynamicChildren:null,appContext:null,ctx:ni};return o?(Wh(l,i),n&128&&e.normalize(l)):i&&(l.shapeFlag|=At(i)?8:16),Go>0&&!a&&Ni&&(l.patchFlag>0||n&6)&&l.patchFlag!==32&&Ni.push(l),l}const Y=I3;function I3(e,t=null,i=null,r=0,s=null,n=!1){if((!e||e===O_)&&(e=Xt),Yo(e)){const o=bs(e,t,!0);return i&&Wh(o,i),Go>0&&!n&&Ni&&(o.shapeFlag&6?Ni[Ni.indexOf(e)]=o:Ni.push(o)),o.patchFlag=-2,o}if(W3(e)&&(e=e.__vccOpts),t){t=R3(t);let{class:o,style:l}=t;o&&!At(o)&&(t.class=xe(o)),tt(l)&&(lc(l)&&!Ve(l)&&(l=Vt({},l)),t.style=Ci(l))}const a=At(e)?1:rm(e)?128:L_(e)?64:tt(e)?4:Ue(e)?2:0;return b(e,t,i,r,s,a,n,!0)}function R3(e){return e?lc(e)||G_(e)?Vt({},e):e:null}function bs(e,t,i=!1,r=!1){const{props:s,ref:n,patchFlag:a,children:o,transition:l}=e,c=t?Jt(s||{},t):s,u={__v_isVNode:!0,__v_skip:!0,type:e.type,props:c,key:c&&nm(c),ref:t&&t.ref?i&&n?Ve(n)?n.concat(r0(t)):[n,r0(t)]:r0(t):n,scopeId:e.scopeId,slotScopeIds:e.slotScopeIds,children:o,target:e.target,targetStart:e.targetStart,targetAnchor:e.targetAnchor,staticCount:e.staticCount,shapeFlag:e.shapeFlag,patchFlag:t&&e.type!==we?a===-1?16:a|16:a,dynamicProps:e.dynamicProps,dynamicChildren:e.dynamicChildren,appContext:e.appContext,dirs:e.dirs,transition:l,component:e.component,suspense:e.suspense,ssContent:e.ssContent&&bs(e.ssContent),ssFallback:e.ssFallback&&bs(e.ssFallback),placeholder:e.placeholder,el:e.el,anchor:e.anchor,ctx:e.ctx,ce:e.ce};return l&&r&&Ko(u,l.clone(u)),u}function ce(e=" ",t=0){return Y(As,null,e,t)}function F(e="",t=!1){return t?(g(),de(Xt,null,e)):Y(Xt,null,e)}function _r(e){return e==null||typeof e=="boolean"?Y(Xt):Ve(e)?Y(we,null,e.slice()):Yo(e)?Ir(e):Y(As,null,String(e))}function Ir(e){return e.el===null&&e.patchFlag!==-1||e.memo?e:bs(e)}function Wh(e,t){let i=0;const{shapeFlag:r}=e;if(t==null)t=null;else if(Ve(t))i=16;else if(typeof t=="object")if(r&65){const s=t.default;s&&(s._c&&(s._d=!1),Wh(e,s()),s._c&&(s._d=!0));return}else{i=32;const s=t._;!s&&!G_(t)?t._ctx=ni:s===3&&ni&&(ni.slots._===1?t._=1:(t._=2,e.patchFlag|=1024))}else Ue(t)?(t={default:t,_ctx:ni},i=32):(t=String(t),r&64?(i=16,t=[ce(t)]):i=8);e.children=t,e.shapeFlag|=i}function Jt(...e){const t={};for(let i=0;i<e.length;i++){const r=e[i];for(const s in r)if(s==="class")t.class!==r.class&&(t.class=xe([t.class,r.class]));else if(s==="style")t.style=Ci([t.style,r.style]);else if(Q0(s)){const n=t[s],a=r[s];a&&n!==a&&!(Ve(n)&&n.includes(a))?t[s]=n?[].concat(n,a):a:a==null&&n==null&&!ec(s)&&(t[s]=a)}else s!==""&&(t[s]=r[s])}return t}function sr(e,t,i,r=null){ir(e,t,7,[i,r])}const D3=F_();let V3=0;function B3(e,t,i){const r=e.type,s=(t?t.appContext:e.appContext)||D3,n={uid:V3++,vnode:e,type:r,parent:t,appContext:s,root:null,next:null,subTree:null,effect:null,update:null,job:null,scope:new e_(!0),render:null,proxy:null,exposed:null,exposeProxy:null,withProxy:null,provides:t?t.provides:Object.create(s.provides),ids:t?t.ids:["",0,0],accessCache:null,renderCache:[],components:null,directives:null,propsOptions:X_(r,s),emitsOptions:W_(r,s),emit:null,emitted:null,propsDefaults:et,inheritAttrs:r.inheritAttrs,ctx:et,data:et,props:et,attrs:et,slots:et,refs:et,setupState:et,setupContext:null,suspense:i,suspenseId:i?i.pendingId:0,asyncDep:null,asyncResolved:!1,isMounted:!1,isUnmounted:!1,isDeactivated:!1,bc:null,c:null,bm:null,m:null,bu:null,u:null,um:null,bum:null,da:null,a:null,rtg:null,rtc:null,ec:null,sp:null};return n.ctx={_:n},n.root=t?t.root:n,n.emit=v3.bind(null,n),e.ce&&e.ce(n),n}let ri=null;const ki=()=>ri||ni;let A0,K1;{const e=nc(),t=(i,r)=>{let s;return(s=e[i])||(s=e[i]=[]),s.push(r),n=>{s.length>1?s.forEach(a=>a(n)):s[0](n)}};A0=t("__VUE_INSTANCE_SETTERS__",i=>ri=i),K1=t("__VUE_SSR_SETTERS__",i=>Nn=i)}const yl=e=>{const t=ri;return A0(e),e.scope.on(),()=>{e.scope.off(),A0(t)}},h2=()=>{ri&&ri.scope.off(),A0(null)};function am(e){return e.vnode.shapeFlag&4}let Nn=!1;function Z3(e,t=!1,i=!1){t&&K1(t);const{props:r,children:s}=e.vnode,n=am(e);k3(e,r,n,t),E3(e,s,i||t);const a=n?F3(e,t):void 0;return t&&K1(!1),a}function F3(e,t){const i=e.type;e.accessCache=Object.create(null),e.proxy=new Proxy(e.ctx,c3);const{setup:r}=i;if(r){Kr();const s=e.setupContext=r.length>1?lm(e):null,n=yl(e),a=gl(r,e,0,[e.props,s]),o=Kp(a);if(qr(),n(),(o||e.sp)&&!$n(e)&&Zh(e),o){if(a.then(h2,h2),t)return a.then(l=>{d2(e,l)}).catch(l=>{vl(l,e,0)});e.asyncDep=a}else d2(e,a)}else om(e)}function d2(e,t,i){Ue(t)?e.type.__ssrInlineRender?e.ssrRender=t:e.render=t:tt(t)&&(e.setupState=v_(t)),om(e)}function om(e,t,i){const r=e.type;e.render||(e.render=r.render||vr);{const s=yl(e);Kr();try{h3(e)}finally{qr(),s()}}}const z3={get(e,t){return fi(e,"get",""),e[t]}};function lm(e){const t=i=>{e.exposed=i||{}};return{attrs:new Proxy(e.attrs,z3),slots:e.slots,emit:e.emit,expose:t}}function dc(e){return e.exposed?e.exposeProxy||(e.exposeProxy=new Proxy(v_(Dh(e.exposed)),{get(t,i){if(i in t)return t[i];if(i in Io)return Io[i](e)},has(t,i){return i in t||i in Io}})):e.proxy}function U3(e,t=!0){return Ue(e)?e.displayName||e.name:e.name||t&&e.__name}function W3(e){return Ue(e)&&"__vccOpts"in e}const Q=(e,t)=>P5(e,t,Nn);function Me(e,t,i){try{k0(-1);const r=arguments.length;return r===2?tt(t)&&!Ve(t)?Yo(t)?Y(e,null,[t]):Y(e,t):Y(e,null,t):(r>3?i=Array.prototype.slice.call(arguments,2):r===3&&Yo(i)&&(i=[i]),Y(e,t,i))}finally{k0(1)}}const j3="3.5.32";/**
|
|
14
|
-
* @vue/runtime-dom v3.5.32
|
|
15
|
-
* (c) 2018-present Yuxi (Evan) You and Vue contributors
|
|
16
|
-
* @license MIT
|
|
17
|
-
**/let q1;const f2=typeof window<"u"&&window.trustedTypes;if(f2)try{q1=f2.createPolicy("vue",{createHTML:e=>e})}catch{}const cm=q1?e=>q1.createHTML(e):e=>e,K3="http://www.w3.org/2000/svg",q3="http://www.w3.org/1998/Math/MathML",Or=typeof document<"u"?document:null,p2=Or&&Or.createElement("template"),G3={insert:(e,t,i)=>{t.insertBefore(e,i||null)},remove:e=>{const t=e.parentNode;t&&t.removeChild(e)},createElement:(e,t,i,r)=>{const s=t==="svg"?Or.createElementNS(K3,e):t==="mathml"?Or.createElementNS(q3,e):i?Or.createElement(e,{is:i}):Or.createElement(e);return e==="select"&&r&&r.multiple!=null&&s.setAttribute("multiple",r.multiple),s},createText:e=>Or.createTextNode(e),createComment:e=>Or.createComment(e),setText:(e,t)=>{e.nodeValue=t},setElementText:(e,t)=>{e.textContent=t},parentNode:e=>e.parentNode,nextSibling:e=>e.nextSibling,querySelector:e=>Or.querySelector(e),setScopeId(e,t){e.setAttribute(t,"")},insertStaticContent(e,t,i,r,s,n){const a=i?i.previousSibling:t.lastChild;if(s&&(s===n||s.nextSibling))for(;t.insertBefore(s.cloneNode(!0),i),!(s===n||!(s=s.nextSibling)););else{p2.innerHTML=cm(r==="svg"?`<svg>${e}</svg>`:r==="mathml"?`<math>${e}</math>`:e);const o=p2.content;if(r==="svg"||r==="mathml"){const l=o.firstChild;for(;l.firstChild;)o.appendChild(l.firstChild);o.removeChild(l)}t.insertBefore(o,i)}return[a?a.nextSibling:t.firstChild,i?i.previousSibling:t.lastChild]}},ts="transition",uo="animation",Xo=Symbol("_vtc"),um={name:String,type:String,css:{type:Boolean,default:!0},duration:[String,Number,Object],enterFromClass:String,enterActiveClass:String,enterToClass:String,appearFromClass:String,appearActiveClass:String,appearToClass:String,leaveFromClass:String,leaveActiveClass:String,leaveToClass:String},Y3=Vt({},E_,um),X3=e=>(e.displayName="Transition",e.props=Y3,e),jh=X3((e,{slots:t})=>Me(Y5,J3(e),t)),Os=(e,t=[])=>{Ve(e)?e.forEach(i=>i(...t)):e&&e(...t)},_2=e=>e?Ve(e)?e.some(t=>t.length>1):e.length>1:!1;function J3(e){const t={};for(const N in e)N in um||(t[N]=e[N]);if(e.css===!1)return t;const{name:i="v",type:r,duration:s,enterFromClass:n=`${i}-enter-from`,enterActiveClass:a=`${i}-enter-active`,enterToClass:o=`${i}-enter-to`,appearFromClass:l=n,appearActiveClass:c=a,appearToClass:u=o,leaveFromClass:h=`${i}-leave-from`,leaveActiveClass:d=`${i}-leave-active`,leaveToClass:f=`${i}-leave-to`}=e,m=Q3(s),_=m&&m[0],y=m&&m[1],{onBeforeEnter:p,onEnter:C,onEnterCancelled:w,onLeave:v,onLeaveCancelled:k,onBeforeAppear:$=p,onAppear:M=C,onAppearCancelled:D=w}=t,H=(N,P,U,j)=>{N._enterCancelled=j,Is(N,P?u:o),Is(N,P?c:a),U&&U()},R=(N,P)=>{N._isLeaving=!1,Is(N,h),Is(N,f),Is(N,d),P&&P()},V=N=>(P,U)=>{const j=N?M:C,oe=()=>H(P,N,U);Os(j,[P,oe]),m2(()=>{Is(P,N?l:n),xr(P,N?u:o),_2(j)||g2(P,r,_,oe)})};return Vt(t,{onBeforeEnter(N){Os(p,[N]),xr(N,n),xr(N,a)},onBeforeAppear(N){Os($,[N]),xr(N,l),xr(N,c)},onEnter:V(!1),onAppear:V(!0),onLeave(N,P){N._isLeaving=!0;const U=()=>R(N,P);xr(N,h),N._enterCancelled?(xr(N,d),y2(N)):(y2(N),xr(N,d)),m2(()=>{N._isLeaving&&(Is(N,h),xr(N,f),_2(v)||g2(N,r,y,U))}),Os(v,[N,U])},onEnterCancelled(N){H(N,!1,void 0,!0),Os(w,[N])},onAppearCancelled(N){H(N,!0,void 0,!0),Os(D,[N])},onLeaveCancelled(N){R(N),Os(k,[N])}})}function Q3(e){if(e==null)return null;if(tt(e))return[Xc(e.enter),Xc(e.leave)];{const t=Xc(e);return[t,t]}}function Xc(e){return Xv(e)}function xr(e,t){t.split(/\s+/).forEach(i=>i&&e.classList.add(i)),(e[Xo]||(e[Xo]=new Set)).add(t)}function Is(e,t){t.split(/\s+/).forEach(r=>r&&e.classList.remove(r));const i=e[Xo];i&&(i.delete(t),i.size||(e[Xo]=void 0))}function m2(e){requestAnimationFrame(()=>{requestAnimationFrame(e)})}let eb=0;function g2(e,t,i,r){const s=e._endId=++eb,n=()=>{s===e._endId&&r()};if(i!=null)return setTimeout(n,i);const{type:a,timeout:o,propCount:l}=tb(e,t);if(!a)return r();const c=a+"end";let u=0;const h=()=>{e.removeEventListener(c,d),n()},d=f=>{f.target===e&&++u>=l&&h()};setTimeout(()=>{u<l&&h()},o+1),e.addEventListener(c,d)}function tb(e,t){const i=window.getComputedStyle(e),r=m=>(i[m]||"").split(", "),s=r(`${ts}Delay`),n=r(`${ts}Duration`),a=v2(s,n),o=r(`${uo}Delay`),l=r(`${uo}Duration`),c=v2(o,l);let u=null,h=0,d=0;t===ts?a>0&&(u=ts,h=a,d=n.length):t===uo?c>0&&(u=uo,h=c,d=l.length):(h=Math.max(a,c),u=h>0?a>c?ts:uo:null,d=u?u===ts?n.length:l.length:0);const f=u===ts&&/\b(?:transform|all)(?:,|$)/.test(r(`${ts}Property`).toString());return{type:u,timeout:h,propCount:d,hasTransform:f}}function v2(e,t){for(;e.length<t.length;)e=e.concat(e);return Math.max(...t.map((i,r)=>b2(i)+b2(e[r])))}function b2(e){return e==="auto"?0:Number(e.slice(0,-1).replace(",","."))*1e3}function y2(e){return(e?e.ownerDocument:document).body.offsetHeight}function ib(e,t,i){const r=e[Xo];r&&(t=(t?[t,...r]:[...r]).join(" ")),t==null?e.removeAttribute("class"):i?e.setAttribute("class",t):e.className=t}const M0=Symbol("_vod"),hm=Symbol("_vsh"),dm={name:"show",beforeMount(e,{value:t},{transition:i}){e[M0]=e.style.display==="none"?"":e.style.display,i&&t?i.beforeEnter(e):ho(e,t)},mounted(e,{value:t},{transition:i}){i&&t&&i.enter(e)},updated(e,{value:t,oldValue:i},{transition:r}){!t!=!i&&(r?t?(r.beforeEnter(e),ho(e,!0),r.enter(e)):r.leave(e,()=>{ho(e,!1)}):ho(e,t))},beforeUnmount(e,{value:t}){ho(e,t)}};function ho(e,t){e.style.display=t?e[M0]:"none",e[hm]=!t}const rb=Symbol(""),sb=/(?:^|;)\s*display\s*:/;function nb(e,t,i){const r=e.style,s=At(i);let n=!1;if(i&&!s){if(t)if(At(t))for(const a of t.split(";")){const o=a.slice(0,a.indexOf(":")).trim();i[o]==null&&s0(r,o,"")}else for(const a in t)i[a]==null&&s0(r,a,"");for(const a in i)a==="display"&&(n=!0),s0(r,a,i[a])}else if(s){if(t!==i){const a=r[rb];a&&(i+=";"+a),r.cssText=i,n=sb.test(i)}}else t&&e.removeAttribute("style");M0 in e&&(e[M0]=n?r.display:"",e[hm]&&(r.display="none"))}const w2=/\s*!important$/;function s0(e,t,i){if(Ve(i))i.forEach(r=>s0(e,t,r));else if(i==null&&(i=""),t.startsWith("--"))e.setProperty(t,i);else{const r=ab(e,t);w2.test(i)?e.setProperty(Yr(r),i.replace(w2,""),"important"):e[r]=i}}const S2=["Webkit","Moz","ms"],Jc={};function ab(e,t){const i=Jc[t];if(i)return i;let r=pi(t);if(r!=="filter"&&r in e)return Jc[t]=r;r=rc(r);for(let s=0;s<S2.length;s++){const n=S2[s]+r;if(n in e)return Jc[t]=n}return t}const C2="http://www.w3.org/1999/xlink";function k2(e,t,i,r,s,n=r5(t)){r&&t.startsWith("xlink:")?i==null?e.removeAttributeNS(C2,t.slice(6,t.length)):e.setAttributeNS(C2,t,i):i==null||n&&!Xp(i)?e.removeAttribute(t):e.setAttribute(t,n?"":Oi(i)?String(i):i)}function A2(e,t,i,r,s){if(t==="innerHTML"||t==="textContent"){i!=null&&(e[t]=t==="innerHTML"?cm(i):i);return}const n=e.tagName;if(t==="value"&&n!=="PROGRESS"&&!n.includes("-")){const o=n==="OPTION"?e.getAttribute("value")||"":e.value,l=i==null?e.type==="checkbox"?"on":"":String(i);(o!==l||!("_value"in e))&&(e.value=l),i==null&&e.removeAttribute(t),e._value=i;return}let a=!1;if(i===""||i==null){const o=typeof e[t];o==="boolean"?i=Xp(i):i==null&&o==="string"?(i="",a=!0):o==="number"&&(i=0,a=!0)}try{e[t]=i}catch{}a&&e.removeAttribute(s||t)}function Vr(e,t,i,r){e.addEventListener(t,i,r)}function ob(e,t,i,r){e.removeEventListener(t,i,r)}const M2=Symbol("_vei");function lb(e,t,i,r,s=null){const n=e[M2]||(e[M2]={}),a=n[t];if(r&&a)a.value=r;else{const[o,l]=cb(t);if(r){const c=n[t]=db(r,s);Vr(e,o,c,l)}else a&&(ob(e,o,a,l),n[t]=void 0)}}const L2=/(?:Once|Passive|Capture)$/;function cb(e){let t;if(L2.test(e)){t={};let r;for(;r=e.match(L2);)e=e.slice(0,e.length-r[0].length),t[r[0].toLowerCase()]=!0}return[e[2]===":"?e.slice(3):Yr(e.slice(2)),t]}let Qc=0;const ub=Promise.resolve(),hb=()=>Qc||(ub.then(()=>Qc=0),Qc=Date.now());function db(e,t){const i=r=>{if(!r._vts)r._vts=Date.now();else if(r._vts<=i.attached)return;ir(fb(r,i.value),t,5,[r])};return i.value=e,i.attached=hb(),i}function fb(e,t){if(Ve(t)){const i=e.stopImmediatePropagation;return e.stopImmediatePropagation=()=>{i.call(e),e._stopped=!0},t.map(r=>s=>!s._stopped&&r&&r(s))}else return t}const E2=e=>e.charCodeAt(0)===111&&e.charCodeAt(1)===110&&e.charCodeAt(2)>96&&e.charCodeAt(2)<123,pb=(e,t,i,r,s,n)=>{const a=s==="svg";t==="class"?ib(e,r,a):t==="style"?nb(e,i,r):Q0(t)?ec(t)||lb(e,t,i,r,n):(t[0]==="."?(t=t.slice(1),!0):t[0]==="^"?(t=t.slice(1),!1):_b(e,t,r,a))?(A2(e,t,r),!e.tagName.includes("-")&&(t==="value"||t==="checked"||t==="selected")&&k2(e,t,r,a,n,t!=="value")):e._isVueCE&&(mb(e,t)||e._def.__asyncLoader&&(/[A-Z]/.test(t)||!At(r)))?A2(e,pi(t),r,n,t):(t==="true-value"?e._trueValue=r:t==="false-value"&&(e._falseValue=r),k2(e,t,r,a))};function _b(e,t,i,r){if(r)return!!(t==="innerHTML"||t==="textContent"||t in e&&E2(t)&&Ue(i));if(t==="spellcheck"||t==="draggable"||t==="translate"||t==="autocorrect"||t==="sandbox"&&e.tagName==="IFRAME"||t==="form"||t==="list"&&e.tagName==="INPUT"||t==="type"&&e.tagName==="TEXTAREA")return!1;if(t==="width"||t==="height"){const s=e.tagName;if(s==="IMG"||s==="VIDEO"||s==="CANVAS"||s==="SOURCE")return!1}return E2(t)&&At(i)?!1:t in e}function mb(e,t){const i=e._def.props;if(!i)return!1;const r=pi(t);return Array.isArray(i)?i.some(s=>pi(s)===r):Object.keys(i).some(s=>pi(s)===r)}const ys=e=>{const t=e.props["onUpdate:modelValue"]||!1;return Ve(t)?i=>i0(t,i):t};function gb(e){e.target.composing=!0}function $2(e){const t=e.target;t.composing&&(t.composing=!1,t.dispatchEvent(new Event("input")))}const ji=Symbol("_assign");function x2(e,t,i){return t&&(e=e.trim()),i&&(e=sc(e)),e}const L0={created(e,{modifiers:{lazy:t,trim:i,number:r}},s){e[ji]=ys(s);const n=r||s.props&&s.props.type==="number";Vr(e,t?"change":"input",a=>{a.target.composing||e[ji](x2(e.value,i,n))}),(i||n)&&Vr(e,"change",()=>{e.value=x2(e.value,i,n)}),t||(Vr(e,"compositionstart",gb),Vr(e,"compositionend",$2),Vr(e,"change",$2))},mounted(e,{value:t}){e.value=t??""},beforeUpdate(e,{value:t,oldValue:i,modifiers:{lazy:r,trim:s,number:n}},a){if(e[ji]=ys(a),e.composing)return;const o=(n||e.type==="number")&&!/^0\d/.test(e.value)?sc(e.value):e.value,l=t??"";if(o===l)return;const c=e.getRootNode();(c instanceof Document||c instanceof ShadowRoot)&&c.activeElement===e&&e.type!=="range"&&(r&&t===i||s&&e.value.trim()===l)||(e.value=l)}},fm={deep:!0,created(e,t,i){e[ji]=ys(i),Vr(e,"change",()=>{const r=e._modelValue,s=Hn(e),n=e.checked,a=e[ji];if(Ve(r)){const o=Th(r,s),l=o!==-1;if(n&&!l)a(r.concat(s));else if(!n&&l){const c=[...r];c.splice(o,1),a(c)}}else if(qn(r)){const o=new Set(r);n?o.add(s):o.delete(s),a(o)}else a(pm(e,n))})},mounted:T2,beforeUpdate(e,t,i){e[ji]=ys(i),T2(e,t,i)}};function T2(e,{value:t,oldValue:i},r){e._modelValue=t;let s;if(Ve(t))s=Th(t,r.props.value)>-1;else if(qn(t))s=t.has(r.props.value);else{if(t===i)return;s=vs(t,pm(e,!0))}e.checked!==s&&(e.checked=s)}const vb={created(e,{value:t},i){e.checked=vs(t,i.props.value),e[ji]=ys(i),Vr(e,"change",()=>{e[ji](Hn(e))})},beforeUpdate(e,{value:t,oldValue:i},r){e[ji]=ys(r),t!==i&&(e.checked=vs(t,r.props.value))}},bb={deep:!0,created(e,{value:t,modifiers:{number:i}},r){const s=qn(t);Vr(e,"change",()=>{const n=Array.prototype.filter.call(e.options,a=>a.selected).map(a=>i?sc(Hn(a)):Hn(a));e[ji](e.multiple?s?new Set(n):n:n[0]),e._assigning=!0,_i(()=>{e._assigning=!1})}),e[ji]=ys(r)},mounted(e,{value:t}){N2(e,t)},beforeUpdate(e,t,i){e[ji]=ys(i)},updated(e,{value:t}){e._assigning||N2(e,t)}};function N2(e,t){const i=e.multiple,r=Ve(t);if(!(i&&!r&&!qn(t))){for(let s=0,n=e.options.length;s<n;s++){const a=e.options[s],o=Hn(a);if(i)if(r){const l=typeof o;l==="string"||l==="number"?a.selected=t.some(c=>String(c)===String(o)):a.selected=Th(t,o)>-1}else a.selected=t.has(o);else if(vs(Hn(a),t)){e.selectedIndex!==s&&(e.selectedIndex=s);return}}!i&&e.selectedIndex!==-1&&(e.selectedIndex=-1)}}function Hn(e){return"_value"in e?e._value:e.value}function pm(e,t){const i=t?"_trueValue":"_falseValue";return i in e?e[i]:t}const H2={created(e,t,i){Rl(e,t,i,null,"created")},mounted(e,t,i){Rl(e,t,i,null,"mounted")},beforeUpdate(e,t,i,r){Rl(e,t,i,r,"beforeUpdate")},updated(e,t,i,r){Rl(e,t,i,r,"updated")}};function yb(e,t){switch(e){case"SELECT":return bb;case"TEXTAREA":return L0;default:switch(t){case"checkbox":return fm;case"radio":return vb;default:return L0}}}function Rl(e,t,i,r,s){const a=yb(e.tagName,i.props&&i.props.type)[s];a&&a(e,t,i,r)}const wb=["ctrl","shift","alt","meta"],Sb={stop:e=>e.stopPropagation(),prevent:e=>e.preventDefault(),self:e=>e.target!==e.currentTarget,ctrl:e=>!e.ctrlKey,shift:e=>!e.shiftKey,alt:e=>!e.altKey,meta:e=>!e.metaKey,left:e=>"button"in e&&e.button!==0,middle:e=>"button"in e&&e.button!==1,right:e=>"button"in e&&e.button!==2,exact:(e,t)=>wb.some(i=>e[`${i}Key`]&&!t.includes(i))},at=(e,t)=>{if(!e)return e;const i=e._withMods||(e._withMods={}),r=t.join(".");return i[r]||(i[r]=(s,...n)=>{for(let a=0;a<t.length;a++){const o=Sb[t[a]];if(o&&o(s,t))return}return e(s,...n)})},Cb={esc:"escape",space:" ",up:"arrow-up",left:"arrow-left",right:"arrow-right",down:"arrow-down",delete:"backspace"},Br=(e,t)=>{const i=e._withKeys||(e._withKeys={}),r=t.join(".");return i[r]||(i[r]=s=>{if(!("key"in s))return;const n=Yr(s.key);if(t.some(a=>a===n||Cb[a]===n))return e(s)})},kb=Vt({patchProp:pb},G3);let P2;function Ab(){return P2||(P2=x3(kb))}const _m=(...e)=>{const t=Ab().createApp(...e),{mount:i}=t;return t.mount=r=>{const s=Lb(r);if(!s)return;const n=t._component;!Ue(n)&&!n.render&&!n.template&&(n.template=s.innerHTML),s.nodeType===1&&(s.textContent="");const a=i(s,!1,Mb(s));return s instanceof Element&&(s.removeAttribute("v-cloak"),s.setAttribute("data-v-app","")),a},t};function Mb(e){if(e instanceof SVGElement)return"svg";if(typeof MathMLElement=="function"&&e instanceof MathMLElement)return"mathml"}function Lb(e){return At(e)?document.querySelector(e):e}/*!
|
|
18
|
-
* pinia v2.3.1
|
|
19
|
-
* (c) 2025 Eduardo San Martin Morote
|
|
20
|
-
* @license MIT
|
|
21
|
-
*/let mm;const fc=e=>mm=e,gm=Symbol();function G1(e){return e&&typeof e=="object"&&Object.prototype.toString.call(e)==="[object Object]"&&typeof e.toJSON!="function"}var Do;(function(e){e.direct="direct",e.patchObject="patch object",e.patchFunction="patch function"})(Do||(Do={}));function Eb(){const e=Nh(!0),t=e.run(()=>X({}));let i=[],r=[];const s=Dh({install(n){fc(s),s._a=n,n.provide(gm,s),n.config.globalProperties.$pinia=s,r.forEach(a=>i.push(a)),r=[]},use(n){return this._a?i.push(n):r.push(n),this},_p:i,_a:null,_e:e,_s:new Map,state:t});return s}const vm=()=>{};function O2(e,t,i,r=vm){e.push(t);const s=()=>{const n=e.indexOf(t);n>-1&&(e.splice(n,1),r())};return!i&&t_()&&I1(s),s}function dn(e,...t){e.slice().forEach(i=>{i(...t)})}const $b=e=>e(),I2=Symbol(),e1=Symbol();function Y1(e,t){e instanceof Map&&t instanceof Map?t.forEach((i,r)=>e.set(r,i)):e instanceof Set&&t instanceof Set&&t.forEach(e.add,e);for(const i in t){if(!t.hasOwnProperty(i))continue;const r=t[i],s=e[i];G1(s)&&G1(r)&&e.hasOwnProperty(i)&&!wt(r)&&!jr(r)?e[i]=Y1(s,r):e[i]=r}return e}const xb=Symbol();function Tb(e){return!G1(e)||!e.hasOwnProperty(xb)}const{assign:as}=Object;function Nb(e){return!!(wt(e)&&e.effect)}function Hb(e,t,i,r){const{state:s,actions:n,getters:a}=t,o=i.state.value[e];let l;function c(){o||(i.state.value[e]=s?s():{});const u=$5(i.state.value[e]);return as(u,n,Object.keys(a||{}).reduce((h,d)=>(h[d]=Dh(Q(()=>{fc(i);const f=i._s.get(e);return a[d].call(f,f)})),h),{}))}return l=bm(e,c,t,i,r,!0),l}function bm(e,t,i={},r,s,n){let a;const o=as({actions:{}},i),l={deep:!0};let c,u,h=[],d=[],f;const m=r.state.value[e];!n&&!m&&(r.state.value[e]={});let _;function y(D){let H;c=u=!1,typeof D=="function"?(D(r.state.value[e]),H={type:Do.patchFunction,storeId:e,events:f}):(Y1(r.state.value[e],D),H={type:Do.patchObject,payload:D,storeId:e,events:f});const R=_=Symbol();_i().then(()=>{_===R&&(c=!0)}),u=!0,dn(h,H,r.state.value[e])}const p=n?function(){const{state:H}=i,R=H?H():{};this.$patch(V=>{as(V,R)})}:vm;function C(){a.stop(),h=[],d=[],r._s.delete(e)}const w=(D,H="")=>{if(I2 in D)return D[e1]=H,D;const R=function(){fc(r);const V=Array.from(arguments),N=[],P=[];function U(te){N.push(te)}function j(te){P.push(te)}dn(d,{args:V,name:R[e1],store:k,after:U,onError:j});let oe;try{oe=D.apply(this&&this.$id===e?this:k,V)}catch(te){throw dn(P,te),te}return oe instanceof Promise?oe.then(te=>(dn(N,te),te)).catch(te=>(dn(P,te),Promise.reject(te))):(dn(N,oe),oe)};return R[I2]=!0,R[e1]=H,R},v={_p:r,$id:e,$onAction:O2.bind(null,d),$patch:y,$reset:p,$subscribe(D,H={}){const R=O2(h,D,H.detached,()=>V()),V=a.run(()=>Fe(()=>r.state.value[e],N=>{(H.flush==="sync"?u:c)&&D({storeId:e,type:Do.direct,events:f},N)},as({},l,H)));return R},$dispose:C},k=tn(v);r._s.set(e,k);const M=(r._a&&r._a.runWithContext||$b)(()=>r._e.run(()=>(a=Nh()).run(()=>t({action:w}))));for(const D in M){const H=M[D];if(wt(H)&&!Nb(H)||jr(H))n||(m&&Tb(H)&&(wt(H)?H.value=m[D]:Y1(H,m[D])),r.state.value[e][D]=H);else if(typeof H=="function"){const R=w(H,D);M[D]=R,o.actions[D]=H}}return as(k,M),as(Xe(k),M),Object.defineProperty(k,"$state",{get:()=>r.state.value[e],set:D=>{y(H=>{as(H,D)})}}),r._p.forEach(D=>{as(k,a.run(()=>D({store:k,app:r._a,pinia:r,options:o})))}),m&&n&&i.hydrate&&i.hydrate(k.$state,m),c=!0,u=!0,k}/*! #__NO_SIDE_EFFECTS__ */function pc(e,t,i){let r,s;const n=typeof t=="function";typeof e=="string"?(r=e,s=n?i:t):(s=e,r=e.id);function a(o,l){const c=B5();return o=o||(c?ai(gm,null):null),o&&fc(o),o=mm,o._s.has(r)||(n?bm(r,t,s,o):Hb(r,s,o)),o._s.get(r)}return a.$id=r,a}/*!
|
|
22
|
-
* shared v11.3.0
|
|
23
|
-
* (c) 2026 kazuya kawaguchi
|
|
24
|
-
* Released under the MIT License.
|
|
25
|
-
*/function Pb(e,t){typeof console<"u"&&(console.warn("[intlify] "+e),t&&console.warn(t.stack))}const E0=typeof window<"u",Ms=(e,t=!1)=>t?Symbol.for(e):Symbol(e),Ob=(e,t,i)=>Ib({l:e,k:t,s:i}),Ib=e=>JSON.stringify(e).replace(/\u2028/g,"\\u2028").replace(/\u2029/g,"\\u2029").replace(/\u0027/g,"\\u0027"),Dt=e=>typeof e=="number"&&isFinite(e),ym=e=>Kh(e)==="[object Date]",Pn=e=>Kh(e)==="[object RegExp]",_c=e=>Ye(e)&&Object.keys(e).length===0,Ut=Object.assign,Rb=Object.create,pt=(e=null)=>Rb(e);let R2;const js=()=>R2||(R2=typeof globalThis<"u"?globalThis:typeof self<"u"?self:typeof window<"u"?window:typeof global<"u"?global:pt());function D2(e){return e.replace(/&/g,"&").replace(/</g,"<").replace(/>/g,">").replace(/"/g,""").replace(/'/g,"'").replace(/\//g,"/").replace(/=/g,"=")}function V2(e){return e.replace(/&(?![a-zA-Z0-9#]{2,6};)/g,"&").replace(/"/g,""").replace(/'/g,"'").replace(/</g,"<").replace(/>/g,">")}function Db(e){return e=e.replace(/(\w+)\s*=\s*"([^"]*)"/g,(r,s,n)=>`${s}="${V2(n)}"`),e=e.replace(/(\w+)\s*=\s*'([^']*)'/g,(r,s,n)=>`${s}='${V2(n)}'`),/\s*on\w+\s*=\s*["']?[^"'>]+["']?/gi.test(e)&&(e=e.replace(/(\s+)(on)(\w+\s*=)/gi,"$1on$3")),[/(\s+(?:href|src|action|formaction)\s*=\s*["']?)\s*javascript:/gi,/(style\s*=\s*["'][^"']*url\s*\(\s*)javascript:/gi].forEach(r=>{e=e.replace(r,"$1javascript:")}),e}const Vb=Object.prototype.hasOwnProperty;function Ui(e,t){return Vb.call(e,t)}const xt=Array.isArray,yt=e=>typeof e=="function",He=e=>typeof e=="string",Je=e=>typeof e=="boolean",ot=e=>e!==null&&typeof e=="object",Bb=e=>ot(e)&&yt(e.then)&&yt(e.catch),wm=Object.prototype.toString,Kh=e=>wm.call(e),Ye=e=>Kh(e)==="[object Object]",Zb=e=>e==null?"":xt(e)||Ye(e)&&e.toString===wm?JSON.stringify(e,null,2):String(e);function qh(e,t=""){return e.reduce((i,r,s)=>s===0?i+r:i+t+r,"")}const Dl=e=>!ot(e)||xt(e);function n0(e,t){if(Dl(e)||Dl(t))throw new Error("Invalid value");const i=[{src:e,des:t}];for(;i.length;){const{src:r,des:s}=i.pop();Object.keys(r).forEach(n=>{n!=="__proto__"&&(ot(r[n])&&!ot(s[n])&&(s[n]=Array.isArray(r[n])?[]:pt()),Dl(s[n])||Dl(r[n])?s[n]=r[n]:i.push({src:r[n],des:s[n]}))})}}/*!
|
|
26
|
-
* message-compiler v11.3.0
|
|
27
|
-
* (c) 2026 kazuya kawaguchi
|
|
28
|
-
* Released under the MIT License.
|
|
29
|
-
*/function Fb(e,t,i){return{line:e,column:t,offset:i}}function X1(e,t,i){return{start:e,end:t}}const rt={EXPECTED_TOKEN:1,INVALID_TOKEN_IN_PLACEHOLDER:2,UNTERMINATED_SINGLE_QUOTE_IN_PLACEHOLDER:3,UNKNOWN_ESCAPE_SEQUENCE:4,INVALID_UNICODE_ESCAPE_SEQUENCE:5,UNBALANCED_CLOSING_BRACE:6,UNTERMINATED_CLOSING_BRACE:7,EMPTY_PLACEHOLDER:8,NOT_ALLOW_NEST_PLACEHOLDER:9,INVALID_LINKED_FORMAT:10,MUST_HAVE_MESSAGES_IN_PLURAL:11,UNEXPECTED_EMPTY_LINKED_MODIFIER:12,UNEXPECTED_EMPTY_LINKED_KEY:13,UNEXPECTED_LEXICAL_ANALYSIS:14},zb=17;function mc(e,t,i={}){const{domain:r,messages:s,args:n}=i,a=e,o=new SyntaxError(String(a));return o.code=e,t&&(o.location=t),o.domain=r,o}function Ub(e){throw e}const nr=" ",Wb="\r",ui=`
|
|
30
|
-
`,jb="\u2028",Kb="\u2029";function qb(e){const t=e;let i=0,r=1,s=1,n=0;const a=M=>t[M]===Wb&&t[M+1]===ui,o=M=>t[M]===ui,l=M=>t[M]===Kb,c=M=>t[M]===jb,u=M=>a(M)||o(M)||l(M)||c(M),h=()=>i,d=()=>r,f=()=>s,m=()=>n,_=M=>a(M)||l(M)||c(M)?ui:t[M],y=()=>_(i),p=()=>_(i+n);function C(){return n=0,u(i)&&(r++,s=0),a(i)&&i++,i++,s++,t[i]}function w(){return a(i+n)&&n++,n++,t[i+n]}function v(){i=0,r=1,s=1,n=0}function k(M=0){n=M}function $(){const M=i+n;for(;M!==i;)C();n=0}return{index:h,line:d,column:f,peekOffset:m,charAt:_,currentChar:y,currentPeek:p,next:C,peek:w,reset:v,resetPeek:k,skipToPeek:$}}const Tr=void 0,Gb=".",B2="'",Yb="tokenizer";function Xb(e,t={}){const i=t.location!==!1,r=qb(e),s=()=>r.index(),n=()=>Fb(r.line(),r.column(),r.index()),a=n(),o=s(),l={currentType:13,offset:o,startLoc:a,endLoc:a,lastType:13,lastOffset:o,lastStartLoc:a,lastEndLoc:a,braceNest:0,inLinked:!1,text:""},c=()=>l,{onError:u}=t;function h(S,A,B,...L){const I=c();if(A.column+=B,A.offset+=B,u){const z=i?X1(I.startLoc,A):null,W=mc(S,z,{domain:Yb,args:L});u(W)}}function d(S,A,B){S.endLoc=n(),S.currentType=A;const L={type:A};return i&&(L.loc=X1(S.startLoc,S.endLoc)),B!=null&&(L.value=B),L}const f=S=>d(S,13);function m(S,A){return S.currentChar()===A?(S.next(),A):(h(rt.EXPECTED_TOKEN,n(),0,A),"")}function _(S){let A="";for(;S.currentPeek()===nr||S.currentPeek()===ui;)A+=S.currentPeek(),S.peek();return A}function y(S){const A=_(S);return S.skipToPeek(),A}function p(S){if(S===Tr)return!1;const A=S.charCodeAt(0);return A>=97&&A<=122||A>=65&&A<=90||A===95}function C(S){if(S===Tr)return!1;const A=S.charCodeAt(0);return A>=48&&A<=57}function w(S,A){const{currentType:B}=A;if(B!==2)return!1;_(S);const L=p(S.currentPeek());return S.resetPeek(),L}function v(S,A){const{currentType:B}=A;if(B!==2)return!1;_(S);const L=S.currentPeek()==="-"?S.peek():S.currentPeek(),I=C(L);return S.resetPeek(),I}function k(S,A){const{currentType:B}=A;if(B!==2)return!1;_(S);const L=S.currentPeek()===B2;return S.resetPeek(),L}function $(S,A){const{currentType:B}=A;if(B!==7)return!1;_(S);const L=S.currentPeek()===".";return S.resetPeek(),L}function M(S,A){const{currentType:B}=A;if(B!==8)return!1;_(S);const L=p(S.currentPeek());return S.resetPeek(),L}function D(S,A){const{currentType:B}=A;if(!(B===7||B===11))return!1;_(S);const L=S.currentPeek()===":";return S.resetPeek(),L}function H(S,A){const{currentType:B}=A;if(B!==9)return!1;const L=()=>{const z=S.currentPeek();return z==="{"?p(S.peek()):z==="@"||z==="|"||z===":"||z==="."||z===nr||!z?!1:z===ui?(S.peek(),L()):V(S,!1)},I=L();return S.resetPeek(),I}function R(S){_(S);const A=S.currentPeek()==="|";return S.resetPeek(),A}function V(S,A=!0){const B=(I=!1,z="")=>{const W=S.currentPeek();return W==="{"||W==="@"||!W?I:W==="|"?!(z===nr||z===ui):W===nr?(S.peek(),B(!0,nr)):W===ui?(S.peek(),B(!0,ui)):!0},L=B();return A&&S.resetPeek(),L}function N(S,A){const B=S.currentChar();return B===Tr?Tr:A(B)?(S.next(),B):null}function P(S){const A=S.charCodeAt(0);return A>=97&&A<=122||A>=65&&A<=90||A>=48&&A<=57||A===95||A===36}function U(S){return N(S,P)}function j(S){const A=S.charCodeAt(0);return A>=97&&A<=122||A>=65&&A<=90||A>=48&&A<=57||A===95||A===36||A===45}function oe(S){return N(S,j)}function te(S){const A=S.charCodeAt(0);return A>=48&&A<=57}function ne(S){return N(S,te)}function J(S){const A=S.charCodeAt(0);return A>=48&&A<=57||A>=65&&A<=70||A>=97&&A<=102}function fe(S){return N(S,J)}function re(S){let A="",B="";for(;A=ne(S);)B+=A;return B}function _e(S){let A="";for(;;){const B=S.currentChar();if(B==="\\"){const L=S.peek();L==="{"||L==="}"||L==="@"||L==="|"||L==="\\"?(A+=B+L,S.next(),S.next()):(S.resetPeek(),A+=B,S.next())}else{if(B==="{"||B==="}"||B==="@"||B==="|"||!B)break;if(B===nr||B===ui)if(V(S))A+=B,S.next();else{if(R(S))break;A+=B,S.next()}else A+=B,S.next()}}return A}function Ne(S){y(S);let A="",B="";for(;A=oe(S);)B+=A;const L=S.currentChar();if(L&&L!=="}"&&L!==Tr&&L!==nr&&L!==ui&&L!==" "){const I=ge(S);return h(rt.INVALID_TOKEN_IN_PLACEHOLDER,n(),0,B+I),B+I}return S.currentChar()===Tr&&h(rt.UNTERMINATED_CLOSING_BRACE,n(),0),B}function $e(S){y(S);let A="";return S.currentChar()==="-"?(S.next(),A+=`-${re(S)}`):A+=re(S),S.currentChar()===Tr&&h(rt.UNTERMINATED_CLOSING_BRACE,n(),0),A}function be(S){return S!==B2&&S!==ui}function me(S){y(S),m(S,"'");let A="",B="";for(;A=N(S,be);)A==="\\"?B+=O(S):B+=A;const L=S.currentChar();return L===ui||L===Tr?(h(rt.UNTERMINATED_SINGLE_QUOTE_IN_PLACEHOLDER,n(),0),L===ui&&(S.next(),m(S,"'")),B):(m(S,"'"),B)}function O(S){const A=S.currentChar();switch(A){case"\\":case"'":return S.next(),`\\${A}`;case"u":return ie(S,A,4);case"U":return ie(S,A,6);default:return h(rt.UNKNOWN_ESCAPE_SEQUENCE,n(),0,A),""}}function ie(S,A,B){m(S,A);let L="";for(let I=0;I<B;I++){const z=fe(S);if(!z){h(rt.INVALID_UNICODE_ESCAPE_SEQUENCE,n(),0,`\\${A}${L}${S.currentChar()}`);break}L+=z}return`\\${A}${L}`}function le(S){return S!=="{"&&S!=="}"&&S!==nr&&S!==ui}function ge(S){y(S);let A="",B="";for(;A=N(S,le);)B+=A;return B}function Se(S){let A="",B="";for(;A=U(S);)B+=A;return B}function x(S){const A=B=>{const L=S.currentChar();return L==="{"||L==="@"||L==="|"||L==="("||L===")"||!L||L===nr?B:(B+=L,S.next(),A(B))};return A("")}function T(S){y(S);const A=m(S,"|");return y(S),A}function K(S,A){let B=null;switch(S.currentChar()){case"{":return A.braceNest>=1&&h(rt.NOT_ALLOW_NEST_PLACEHOLDER,n(),0),S.next(),B=d(A,2,"{"),y(S),A.braceNest++,B;case"}":return A.braceNest>0&&A.currentType===2&&h(rt.EMPTY_PLACEHOLDER,n(),0),S.next(),B=d(A,3,"}"),A.braceNest--,A.braceNest>0&&y(S),A.inLinked&&A.braceNest===0&&(A.inLinked=!1),B;case"@":return A.braceNest>0&&h(rt.UNTERMINATED_CLOSING_BRACE,n(),0),B=se(S,A)||f(A),A.braceNest=0,B;default:{let I=!0,z=!0,W=!0;if(R(S))return A.braceNest>0&&h(rt.UNTERMINATED_CLOSING_BRACE,n(),0),B=d(A,1,T(S)),A.braceNest=0,A.inLinked=!1,B;if(A.braceNest>0&&(A.currentType===4||A.currentType===5||A.currentType===6))return h(rt.UNTERMINATED_CLOSING_BRACE,n(),0),A.braceNest=0,he(S,A);if(I=w(S,A))return B=d(A,4,Ne(S)),y(S),B;if(z=v(S,A))return B=d(A,5,$e(S)),y(S),B;if(W=k(S,A))return B=d(A,6,me(S)),y(S),B;if(!I&&!z&&!W)return B=d(A,12,ge(S)),h(rt.INVALID_TOKEN_IN_PLACEHOLDER,n(),0,B.value),y(S),B;break}}return B}function se(S,A){const{currentType:B}=A;let L=null;const I=S.currentChar();switch((B===7||B===8||B===11||B===9)&&(I===ui||I===nr)&&h(rt.INVALID_LINKED_FORMAT,n(),0),I){case"@":return S.next(),L=d(A,7,"@"),A.inLinked=!0,L;case".":return y(S),S.next(),d(A,8,".");case":":return y(S),S.next(),d(A,9,":");default:return R(S)?(L=d(A,1,T(S)),A.braceNest=0,A.inLinked=!1,L):$(S,A)||D(S,A)?(y(S),se(S,A)):M(S,A)?(y(S),d(A,11,Se(S))):H(S,A)?(y(S),I==="{"?K(S,A)||L:d(A,10,x(S))):(B===7&&h(rt.INVALID_LINKED_FORMAT,n(),0),A.braceNest=0,A.inLinked=!1,he(S,A))}}function he(S,A){let B={type:13};if(A.braceNest>0)return K(S,A)||f(A);if(A.inLinked)return se(S,A)||f(A);switch(S.currentChar()){case"{":return K(S,A)||f(A);case"}":return h(rt.UNBALANCED_CLOSING_BRACE,n(),0),S.next(),d(A,3,"}");case"@":return se(S,A)||f(A);default:{if(R(S))return B=d(A,1,T(S)),A.braceNest=0,A.inLinked=!1,B;if(V(S))return d(A,0,_e(S));break}}return B}function pe(){const{currentType:S,offset:A,startLoc:B,endLoc:L}=l;return l.lastType=S,l.lastOffset=A,l.lastStartLoc=B,l.lastEndLoc=L,l.offset=s(),l.startLoc=n(),r.currentChar()===Tr?d(l,13):he(r,l)}return{nextToken:pe,currentOffset:s,currentPosition:n,context:c}}const Jb="parser",Qb=/(?:\\\\|\\'|\\u([0-9a-fA-F]{4})|\\U([0-9a-fA-F]{6}))/g,ey=/\\([\\@{}|])/g;function ty(e,t){return t}function iy(e,t,i){switch(e){case"\\\\":return"\\";case"\\'":return"'";default:{const r=parseInt(t||i,16);return r<=55295||r>=57344?String.fromCodePoint(r):"�"}}}function ry(e={}){const t=e.location!==!1,{onError:i}=e;function r(p,C,w,v,...k){const $=p.currentPosition();if($.offset+=v,$.column+=v,i){const M=t?X1(w,$):null,D=mc(C,M,{domain:Jb,args:k});i(D)}}function s(p,C,w){const v={type:p};return t&&(v.start=C,v.end=C,v.loc={start:w,end:w}),v}function n(p,C,w,v){t&&(p.end=C,p.loc&&(p.loc.end=w))}function a(p,C){const w=p.context(),v=s(3,w.offset,w.startLoc);return v.value=C.replace(ey,ty),n(v,p.currentOffset(),p.currentPosition()),v}function o(p,C){const w=p.context(),{lastOffset:v,lastStartLoc:k}=w,$=s(5,v,k);return $.index=parseInt(C,10),p.nextToken(),n($,p.currentOffset(),p.currentPosition()),$}function l(p,C){const w=p.context(),{lastOffset:v,lastStartLoc:k}=w,$=s(4,v,k);return $.key=C,p.nextToken(),n($,p.currentOffset(),p.currentPosition()),$}function c(p,C){const w=p.context(),{lastOffset:v,lastStartLoc:k}=w,$=s(9,v,k);return $.value=C.replace(Qb,iy),p.nextToken(),n($,p.currentOffset(),p.currentPosition()),$}function u(p){const C=p.nextToken(),w=p.context(),{lastOffset:v,lastStartLoc:k}=w,$=s(8,v,k);return C.type!==11?(r(p,rt.UNEXPECTED_EMPTY_LINKED_MODIFIER,w.lastStartLoc,0),$.value="",n($,v,k),{nextConsumeToken:C,node:$}):(C.value==null&&r(p,rt.UNEXPECTED_LEXICAL_ANALYSIS,w.lastStartLoc,0,ar(C)),$.value=C.value||"",n($,p.currentOffset(),p.currentPosition()),{node:$})}function h(p,C){const w=p.context(),v=s(7,w.offset,w.startLoc);return v.value=C,n(v,p.currentOffset(),p.currentPosition()),v}function d(p){const C=p.context(),w=s(6,C.offset,C.startLoc);let v=p.nextToken();if(v.type===8){const k=u(p);w.modifier=k.node,v=k.nextConsumeToken||p.nextToken()}switch(v.type!==9&&r(p,rt.UNEXPECTED_LEXICAL_ANALYSIS,C.lastStartLoc,0,ar(v)),v=p.nextToken(),v.type===2&&(v=p.nextToken()),v.type){case 10:v.value==null&&r(p,rt.UNEXPECTED_LEXICAL_ANALYSIS,C.lastStartLoc,0,ar(v)),w.key=h(p,v.value||"");break;case 4:v.value==null&&r(p,rt.UNEXPECTED_LEXICAL_ANALYSIS,C.lastStartLoc,0,ar(v)),w.key=l(p,v.value||"");break;case 5:v.value==null&&r(p,rt.UNEXPECTED_LEXICAL_ANALYSIS,C.lastStartLoc,0,ar(v)),w.key=o(p,v.value||"");break;case 6:v.value==null&&r(p,rt.UNEXPECTED_LEXICAL_ANALYSIS,C.lastStartLoc,0,ar(v)),w.key=c(p,v.value||"");break;default:{r(p,rt.UNEXPECTED_EMPTY_LINKED_KEY,C.lastStartLoc,0);const k=p.context(),$=s(7,k.offset,k.startLoc);return $.value="",n($,k.offset,k.startLoc),w.key=$,n(w,k.offset,k.startLoc),{nextConsumeToken:v,node:w}}}return n(w,p.currentOffset(),p.currentPosition()),{node:w}}function f(p){const C=p.context(),w=C.currentType===1?p.currentOffset():C.offset,v=C.currentType===1?C.endLoc:C.startLoc,k=s(2,w,v);k.items=[];let $=null;do{const H=$||p.nextToken();switch($=null,H.type){case 0:H.value==null&&r(p,rt.UNEXPECTED_LEXICAL_ANALYSIS,C.lastStartLoc,0,ar(H)),k.items.push(a(p,H.value||""));break;case 5:H.value==null&&r(p,rt.UNEXPECTED_LEXICAL_ANALYSIS,C.lastStartLoc,0,ar(H)),k.items.push(o(p,H.value||""));break;case 4:H.value==null&&r(p,rt.UNEXPECTED_LEXICAL_ANALYSIS,C.lastStartLoc,0,ar(H)),k.items.push(l(p,H.value||""));break;case 6:H.value==null&&r(p,rt.UNEXPECTED_LEXICAL_ANALYSIS,C.lastStartLoc,0,ar(H)),k.items.push(c(p,H.value||""));break;case 7:{const R=d(p);k.items.push(R.node),$=R.nextConsumeToken||null;break}}}while(C.currentType!==13&&C.currentType!==1);const M=C.currentType===1?C.lastOffset:p.currentOffset(),D=C.currentType===1?C.lastEndLoc:p.currentPosition();return n(k,M,D),k}function m(p,C,w,v){const k=p.context();let $=v.items.length===0;const M=s(1,C,w);M.cases=[],M.cases.push(v);do{const D=f(p);$||($=D.items.length===0),M.cases.push(D)}while(k.currentType!==13);return $&&r(p,rt.MUST_HAVE_MESSAGES_IN_PLURAL,w,0),n(M,p.currentOffset(),p.currentPosition()),M}function _(p){const C=p.context(),{offset:w,startLoc:v}=C,k=f(p);return C.currentType===13?k:m(p,w,v,k)}function y(p){const C=Xb(p,Ut({},e)),w=C.context(),v=s(0,w.offset,w.startLoc);return t&&v.loc&&(v.loc.source=p),v.body=_(C),e.onCacheKey&&(v.cacheKey=e.onCacheKey(p)),w.currentType!==13&&r(C,rt.UNEXPECTED_LEXICAL_ANALYSIS,w.lastStartLoc,0,p[w.offset]||""),n(v,C.currentOffset(),C.currentPosition()),v}return{parse:y}}function ar(e){if(e.type===13)return"EOF";const t=(e.value||"").replace(/\r?\n/gu,"\\n");return t.length>10?t.slice(0,9)+"…":t}function sy(e,t={}){const i={ast:e,helpers:new Set};return{context:()=>i,helper:n=>(i.helpers.add(n),n)}}function Z2(e,t){for(let i=0;i<e.length;i++)Gh(e[i],t)}function Gh(e,t){switch(e.type){case 1:Z2(e.cases,t),t.helper("plural");break;case 2:Z2(e.items,t);break;case 6:{Gh(e.key,t),t.helper("linked"),t.helper("type");break}case 5:t.helper("interpolate"),t.helper("list");break;case 4:t.helper("interpolate"),t.helper("named");break}}function ny(e,t={}){const i=sy(e);i.helper("normalize"),e.body&&Gh(e.body,i);const r=i.context();e.helpers=Array.from(r.helpers)}function ay(e){const t=e.body;return t.type===2?F2(t):t.cases.forEach(i=>F2(i)),e}function F2(e){if(e.items.length===1){const t=e.items[0];(t.type===3||t.type===9)&&(e.static=t.value,delete t.value)}else{const t=[];for(let i=0;i<e.items.length;i++){const r=e.items[i];if(!(r.type===3||r.type===9)||r.value==null)break;t.push(r.value)}if(t.length===e.items.length){e.static=qh(t);for(let i=0;i<e.items.length;i++){const r=e.items[i];(r.type===3||r.type===9)&&delete r.value}}}}function bn(e){switch(e.t=e.type,e.type){case 0:{const t=e;bn(t.body),t.b=t.body,delete t.body;break}case 1:{const t=e,i=t.cases;for(let r=0;r<i.length;r++)bn(i[r]);t.c=i,delete t.cases;break}case 2:{const t=e,i=t.items;for(let r=0;r<i.length;r++)bn(i[r]);t.i=i,delete t.items,t.static&&(t.s=t.static,delete t.static);break}case 3:case 9:case 8:case 7:{const t=e;t.value&&(t.v=t.value,delete t.value);break}case 6:{const t=e;bn(t.key),t.k=t.key,delete t.key,t.modifier&&(bn(t.modifier),t.m=t.modifier,delete t.modifier);break}case 5:{const t=e;t.i=t.index,delete t.index;break}case 4:{const t=e;t.k=t.key,delete t.key;break}}delete e.type}function oy(e,t){const{filename:i,breakLineCode:r,needIndent:s}=t,n=t.location!==!1,a={filename:i,code:"",column:1,line:1,offset:0,map:void 0,breakLineCode:r,needIndent:s,indentLevel:0};n&&e.loc&&(a.source=e.loc.source);const o=()=>a;function l(_,y){a.code+=_}function c(_,y=!0){const p=y?r:"";l(s?p+" ".repeat(_):p)}function u(_=!0){const y=++a.indentLevel;_&&c(y)}function h(_=!0){const y=--a.indentLevel;_&&c(y)}function d(){c(a.indentLevel)}return{context:o,push:l,indent:u,deindent:h,newline:d,helper:_=>`_${_}`,needIndent:()=>a.needIndent}}function ly(e,t){const{helper:i}=e;e.push(`${i("linked")}(`),On(e,t.key),t.modifier?(e.push(", "),On(e,t.modifier),e.push(", _type")):e.push(", undefined, _type"),e.push(")")}function cy(e,t){const{helper:i,needIndent:r}=e;e.push(`${i("normalize")}([`),e.indent(r());const s=t.items.length;for(let n=0;n<s&&(On(e,t.items[n]),n!==s-1);n++)e.push(", ");e.deindent(r()),e.push("])")}function uy(e,t){const{helper:i,needIndent:r}=e;if(t.cases.length>1){e.push(`${i("plural")}([`),e.indent(r());const s=t.cases.length;for(let n=0;n<s&&(On(e,t.cases[n]),n!==s-1);n++)e.push(", ");e.deindent(r()),e.push("])")}}function hy(e,t){t.body?On(e,t.body):e.push("null")}function On(e,t){const{helper:i}=e;switch(t.type){case 0:hy(e,t);break;case 1:uy(e,t);break;case 2:cy(e,t);break;case 6:ly(e,t);break;case 8:e.push(JSON.stringify(t.value),t);break;case 7:e.push(JSON.stringify(t.value),t);break;case 5:e.push(`${i("interpolate")}(${i("list")}(${t.index}))`,t);break;case 4:e.push(`${i("interpolate")}(${i("named")}(${JSON.stringify(t.key)}))`,t);break;case 9:e.push(JSON.stringify(t.value),t);break;case 3:e.push(JSON.stringify(t.value),t);break}}const dy=(e,t={})=>{const i=He(t.mode)?t.mode:"normal",r=He(t.filename)?t.filename:"message.intl";t.sourceMap;const s=t.breakLineCode!=null?t.breakLineCode:i==="arrow"?";":`
|
|
31
|
-
`,n=t.needIndent?t.needIndent:i!=="arrow",a=e.helpers||[],o=oy(e,{filename:r,breakLineCode:s,needIndent:n});o.push(i==="normal"?"function __msg__ (ctx) {":"(ctx) => {"),o.indent(n),a.length>0&&(o.push(`const { ${qh(a.map(u=>`${u}: _${u}`),", ")} } = ctx`),o.newline()),o.push("return "),On(o,e),o.deindent(n),o.push("}"),delete e.helpers;const{code:l,map:c}=o.context();return{ast:e,code:l,map:c?c.toJSON():void 0}};function fy(e,t={}){const i=Ut({},t),r=!!i.jit,s=!!i.minify,n=i.optimize==null?!0:i.optimize,o=ry(i).parse(e);return r?(n&&ay(o),s&&bn(o),{ast:o,code:""}):(ny(o,i),dy(o,i))}/*!
|
|
32
|
-
* core-base v11.3.0
|
|
33
|
-
* (c) 2026 kazuya kawaguchi
|
|
34
|
-
* Released under the MIT License.
|
|
35
|
-
*/function py(){typeof __INTLIFY_PROD_DEVTOOLS__!="boolean"&&(js().__INTLIFY_PROD_DEVTOOLS__=!1),typeof __INTLIFY_DROP_MESSAGE_COMPILER__!="boolean"&&(js().__INTLIFY_DROP_MESSAGE_COMPILER__=!1)}function yr(e){return ot(e)&&Yh(e)===0&&(Ui(e,"b")||Ui(e,"body"))}const Sm=["b","body"];function _y(e){return Ls(e,Sm)}const Cm=["c","cases"];function my(e){return Ls(e,Cm,[])}const km=["s","static"];function gy(e){return Ls(e,km)}const Am=["i","items"];function vy(e){return Ls(e,Am,[])}const Mm=["t","type"];function Yh(e){return Ls(e,Mm)}const Lm=["v","value"];function Vl(e,t){const i=Ls(e,Lm);if(i!=null)return i;throw Jo(t)}const Em=["m","modifier"];function by(e){return Ls(e,Em)}const $m=["k","key"];function yy(e){const t=Ls(e,$m);if(t)return t;throw Jo(6)}function Ls(e,t,i){for(let r=0;r<t.length;r++){const s=t[r];if(Ui(e,s)&&e[s]!=null)return e[s]}return i}const xm=[...Sm,...Cm,...km,...Am,...$m,...Em,...Lm,...Mm];function Jo(e){return new Error(`unhandled node type: ${e}`)}function t1(e){return i=>wy(i,e)}function wy(e,t){const i=_y(t);if(i==null)throw Jo(0);if(Yh(i)===1){const n=my(i);return e.plural(n.reduce((a,o)=>[...a,z2(e,o)],[]))}else return z2(e,i)}function z2(e,t){const i=gy(t);if(i!=null)return e.type==="text"?i:e.normalize([i]);{const r=vy(t).reduce((s,n)=>[...s,J1(e,n)],[]);return e.normalize(r)}}function J1(e,t){const i=Yh(t);switch(i){case 3:return Vl(t,i);case 9:return Vl(t,i);case 4:{const r=t;if(Ui(r,"k")&&r.k)return e.interpolate(e.named(r.k));if(Ui(r,"key")&&r.key)return e.interpolate(e.named(r.key));throw Jo(i)}case 5:{const r=t;if(Ui(r,"i")&&Dt(r.i))return e.interpolate(e.list(r.i));if(Ui(r,"index")&&Dt(r.index))return e.interpolate(e.list(r.index));throw Jo(i)}case 6:{const r=t,s=by(r),n=yy(r);return e.linked(J1(e,n),s?J1(e,s):void 0,e.type)}case 7:return Vl(t,i);case 8:return Vl(t,i);default:throw new Error(`unhandled node on format message part: ${i}`)}}const Sy=e=>e;let Bl=pt();function Cy(e,t={}){let i=!1;const r=t.onError||Ub;return t.onError=s=>{i=!0,r(s)},{...fy(e,t),detectError:i}}function ky(e,t){if(!__INTLIFY_DROP_MESSAGE_COMPILER__&&He(e)){Je(t.warnHtmlMessage)&&t.warnHtmlMessage;const r=(t.onCacheKey||Sy)(e),s=Bl[r];if(s)return s;const{ast:n,detectError:a}=Cy(e,{...t,location:!1,jit:!0}),o=t1(n);return a?o:Bl[r]=o}else{const i=e.cacheKey;if(i){const r=Bl[i];return r||(Bl[i]=t1(e))}else return t1(e)}}let Qo=null;function Ay(e){Qo=e}function My(e,t,i){Qo&&Qo.emit("i18n:init",{timestamp:Date.now(),i18n:e,version:t,meta:i})}const Ly=Ey("function:translate");function Ey(e){return t=>Qo&&Qo.emit(e,t)}const Zr={INVALID_ARGUMENT:zb,INVALID_DATE_ARGUMENT:18,INVALID_ISO_DATE_ARGUMENT:19,NOT_SUPPORT_LOCALE_PROMISE_VALUE:21,NOT_SUPPORT_LOCALE_ASYNC_FUNCTION:22,NOT_SUPPORT_LOCALE_TYPE:23},$y=24;function Fr(e){return mc(e,null,void 0)}function Xh(e,t){return t.locale!=null?U2(t.locale):U2(e.locale)}let i1;function U2(e){if(He(e))return e;if(yt(e)){if(e.resolvedOnce&&i1!=null)return i1;if(e.constructor.name==="Function"){const t=e();if(Bb(t))throw Fr(Zr.NOT_SUPPORT_LOCALE_PROMISE_VALUE);return i1=t}else throw Fr(Zr.NOT_SUPPORT_LOCALE_ASYNC_FUNCTION)}else throw Fr(Zr.NOT_SUPPORT_LOCALE_TYPE)}function xy(e,t,i){return[...new Set([i,...xt(t)?t:ot(t)?Object.keys(t):He(t)?[t]:[i]])]}function Q1(e,t,i){const r=He(i)?i:el,s=e;s.__localeChainCache||(s.__localeChainCache=new Map);let n=s.__localeChainCache.get(r);if(!n){n=[];let a=[i];for(;xt(a);)a=W2(n,a,t);const o=xt(t)||!Ye(t)?t:t.default?t.default:null;a=He(o)?[o]:o,xt(a)&&W2(n,a,!1),s.__localeChainCache.set(r,n)}return n}function W2(e,t,i){let r=!0;for(let s=0;s<t.length&&Je(r);s++){const n=t[s];He(n)&&(r=Ty(e,t[s],i))}return r}function Ty(e,t,i){let r;const s=t.split("-");do{const n=s.join("-");r=Ny(e,n,i),s.splice(-1,1)}while(s.length&&r===!0);return r}function Ny(e,t,i){let r=!1;if(!e.includes(t)&&(r=!0,t)){r=t[t.length-1]!=="!";const s=t.replace(/!/g,"");e.push(s),(xt(i)||Ye(i))&&i[s]&&(r=i[s])}return r}const Es=[];Es[0]={w:[0],i:[3,0],"[":[4],o:[7]};Es[1]={w:[1],".":[2],"[":[4],o:[7]};Es[2]={w:[2],i:[3,0],0:[3,0]};Es[3]={i:[3,0],0:[3,0],w:[1,1],".":[2,1],"[":[4,1],o:[7,1]};Es[4]={"'":[5,0],'"':[6,0],"[":[4,2],"]":[1,3],o:8,l:[4,0]};Es[5]={"'":[4,0],o:8,l:[5,0]};Es[6]={'"':[4,0],o:8,l:[6,0]};const Hy=/^\s?(?:true|false|-?[\d.]+|'[^']*'|"[^"]*")\s?$/;function Py(e){return Hy.test(e)}function Oy(e){const t=e.charCodeAt(0),i=e.charCodeAt(e.length-1);return t===i&&(t===34||t===39)?e.slice(1,-1):e}function Iy(e){if(e==null)return"o";switch(e.charCodeAt(0)){case 91:case 93:case 46:case 34:case 39:return e;case 95:case 36:case 45:return"i";case 9:case 10:case 13:case 160:case 65279:case 8232:case 8233:return"w"}return"i"}function Ry(e){const t=e.trim();return e.charAt(0)==="0"&&isNaN(parseInt(e))?!1:Py(t)?Oy(t):"*"+t}function Dy(e){const t=[];let i=-1,r=0,s=0,n,a,o,l,c,u,h;const d=[];d[0]=()=>{a===void 0?a=o:a+=o},d[1]=()=>{a!==void 0&&(t.push(a),a=void 0)},d[2]=()=>{d[0](),s++},d[3]=()=>{if(s>0)s--,r=4,d[0]();else{if(s=0,a===void 0||(a=Ry(a),a===!1))return!1;d[1]()}};function f(){const m=e[i+1];if(r===5&&m==="'"||r===6&&m==='"')return i++,o="\\"+m,d[0](),!0}for(;r!==null;)if(i++,n=e[i],!(n==="\\"&&f())){if(l=Iy(n),h=Es[r],c=h[l]||h.l||8,c===8||(r=c[0],c[1]!==void 0&&(u=d[c[1]],u&&(o=n,u()===!1))))return;if(r===7)return t}}const j2=new Map;function Vy(e,t){return ot(e)?e[t]:null}function By(e,t){if(!ot(e))return null;let i=j2.get(t);if(i||(i=Dy(t),i&&j2.set(t,i)),!i)return null;const r=i.length;let s=e,n=0;for(;n<r;){const a=i[n];if(xm.includes(a)&&yr(s)||!ot(s)||!Ui(s,a))return null;const o=s[a];if(o===void 0||yt(s))return null;s=o,n++}return s}const Zy="11.3.0",gc=-1,el="en-US",$0="",K2=e=>`${e.charAt(0).toLocaleUpperCase()}${e.substr(1)}`;function Fy(){return{upper:(e,t)=>t==="text"&&He(e)?e.toUpperCase():t==="vnode"&&ot(e)&&"__v_isVNode"in e?e.children.toUpperCase():e,lower:(e,t)=>t==="text"&&He(e)?e.toLowerCase():t==="vnode"&&ot(e)&&"__v_isVNode"in e?e.children.toLowerCase():e,capitalize:(e,t)=>t==="text"&&He(e)?K2(e):t==="vnode"&&ot(e)&&"__v_isVNode"in e?K2(e.children):e}}let Tm;function zy(e){Tm=e}let Nm;function Uy(e){Nm=e}let Hm;function Wy(e){Hm=e}let Pm=null;const jy=e=>{Pm=e},Ky=()=>Pm;let Om=null;const q2=e=>{Om=e},qy=()=>Om;let G2=0;function Gy(e={}){const t=yt(e.onWarn)?e.onWarn:Pb,i=He(e.version)?e.version:Zy,r=He(e.locale)||yt(e.locale)?e.locale:el,s=yt(r)?el:r,n=xt(e.fallbackLocale)||Ye(e.fallbackLocale)||He(e.fallbackLocale)||e.fallbackLocale===!1?e.fallbackLocale:s,a=Ye(e.messages)?e.messages:r1(s),o=Ye(e.datetimeFormats)?e.datetimeFormats:r1(s),l=Ye(e.numberFormats)?e.numberFormats:r1(s),c=Ut(pt(),e.modifiers,Fy()),u=e.pluralRules||pt(),h=yt(e.missing)?e.missing:null,d=Je(e.missingWarn)||Pn(e.missingWarn)?e.missingWarn:!0,f=Je(e.fallbackWarn)||Pn(e.fallbackWarn)?e.fallbackWarn:!0,m=!!e.fallbackFormat,_=!!e.unresolving,y=yt(e.postTranslation)?e.postTranslation:null,p=Ye(e.processor)?e.processor:null,C=Je(e.warnHtmlMessage)?e.warnHtmlMessage:!0,w=!!e.escapeParameter,v=yt(e.messageCompiler)?e.messageCompiler:Tm,k=yt(e.messageResolver)?e.messageResolver:Nm||Vy,$=yt(e.localeFallbacker)?e.localeFallbacker:Hm||xy,M=ot(e.fallbackContext)?e.fallbackContext:void 0,D=e,H=ot(D.__datetimeFormatters)?D.__datetimeFormatters:new Map,R=ot(D.__numberFormatters)?D.__numberFormatters:new Map,V=ot(D.__meta)?D.__meta:{};G2++;const N={version:i,cid:G2,locale:r,fallbackLocale:n,messages:a,modifiers:c,pluralRules:u,missing:h,missingWarn:d,fallbackWarn:f,fallbackFormat:m,unresolving:_,postTranslation:y,processor:p,warnHtmlMessage:C,escapeParameter:w,messageCompiler:v,messageResolver:k,localeFallbacker:$,fallbackContext:M,onWarn:t,__meta:V};return N.datetimeFormats=o,N.numberFormats=l,N.__datetimeFormatters=H,N.__numberFormatters=R,__INTLIFY_PROD_DEVTOOLS__&&My(N,i,V),N}const r1=e=>({[e]:pt()});function Jh(e,t,i,r,s){const{missing:n,onWarn:a}=e;if(n!==null){const o=n(e,i,t,s);return He(o)?o:t}else return t}function fo(e,t,i){const r=e;r.__localeChainCache=new Map,e.localeFallbacker(e,i,t)}function Yy(e,t){return e===t?!1:e.split("-")[0]===t.split("-")[0]}function Xy(e,t){const i=t.indexOf(e);if(i===-1)return!1;for(let r=i+1;r<t.length;r++)if(Yy(e,t[r]))return!0;return!1}function Y2(e,...t){const{datetimeFormats:i,unresolving:r,fallbackLocale:s,onWarn:n,localeFallbacker:a}=e,{__datetimeFormatters:o}=e;if(!He(t[0])&&!ym(t[0])&&!Dt(t[0]))return $0;const[l,c,u,h]=eu(...t),d=Je(u.missingWarn)?u.missingWarn:e.missingWarn;Je(u.fallbackWarn)?u.fallbackWarn:e.fallbackWarn;const f=!!u.part,m=Xh(e,u),_=a(e,s,m);if(!He(l)||l==="")return new Intl.DateTimeFormat(m.replace(/!/g,""),h).format(c);let y={},p,C=null;const w="datetime format";for(let $=0;$<_.length&&(p=_[$],y=i[p]||{},C=y[l],!Ye(C));$++)Jh(e,l,p,d,w);if(!Ye(C)||!He(p))return r?gc:l;let v=`${p}__${l}`;_c(h)||(v=`${v}__${JSON.stringify(h)}`);let k=o.get(v);return k||(k=new Intl.DateTimeFormat(p,Ut({},C,h)),o.set(v,k)),f?k.formatToParts(c):k.format(c)}const Im=["localeMatcher","weekday","era","year","month","day","hour","minute","second","timeZoneName","formatMatcher","hour12","timeZone","dateStyle","timeStyle","calendar","dayPeriod","numberingSystem","hourCycle","fractionalSecondDigits"];function eu(...e){const[t,i,r,s]=e,n=pt();let a=pt(),o;if(He(t)){const l=t.match(/(\d{4}-\d{2}-\d{2})(T|\s)?(.*)/);if(!l)throw Fr(Zr.INVALID_ISO_DATE_ARGUMENT);const c=l[3]?l[3].trim().startsWith("T")?`${l[1].trim()}${l[3].trim()}`:`${l[1].trim()}T${l[3].trim()}`:l[1].trim();o=new Date(c);try{o.toISOString()}catch{throw Fr(Zr.INVALID_ISO_DATE_ARGUMENT)}}else if(ym(t)){if(isNaN(t.getTime()))throw Fr(Zr.INVALID_DATE_ARGUMENT);o=t}else if(Dt(t))o=t;else throw Fr(Zr.INVALID_ARGUMENT);return He(i)?n.key=i:Ye(i)&&Object.keys(i).forEach(l=>{Im.includes(l)?a[l]=i[l]:n[l]=i[l]}),He(r)?n.locale=r:Ye(r)&&(a=r),Ye(s)&&(a=s),[n.key||"",o,n,a]}function X2(e,t,i){const r=e;for(const s in i){const n=`${t}__${s}`;r.__datetimeFormatters.has(n)&&r.__datetimeFormatters.delete(n)}}function J2(e,...t){const{numberFormats:i,unresolving:r,fallbackLocale:s,onWarn:n,localeFallbacker:a}=e,{__numberFormatters:o}=e;if(!Dt(t[0]))return $0;const[l,c,u,h]=tu(...t),d=Je(u.missingWarn)?u.missingWarn:e.missingWarn;Je(u.fallbackWarn)?u.fallbackWarn:e.fallbackWarn;const f=!!u.part,m=Xh(e,u),_=a(e,s,m);if(!He(l)||l==="")return new Intl.NumberFormat(m.replace(/!/g,""),h).format(c);let y={},p,C=null;const w="number format";for(let $=0;$<_.length&&(p=_[$],y=i[p]||{},C=y[l],!Ye(C));$++)Jh(e,l,p,d,w);if(!Ye(C)||!He(p))return r?gc:l;let v=`${p}__${l}`;_c(h)||(v=`${v}__${JSON.stringify(h)}`);let k=o.get(v);return k||(k=new Intl.NumberFormat(p,Ut({},C,h)),o.set(v,k)),f?k.formatToParts(c):k.format(c)}const Rm=["localeMatcher","style","currency","currencyDisplay","currencySign","useGrouping","minimumIntegerDigits","minimumFractionDigits","maximumFractionDigits","minimumSignificantDigits","maximumSignificantDigits","compactDisplay","notation","signDisplay","unit","unitDisplay","roundingMode","roundingPriority","roundingIncrement","trailingZeroDisplay"];function tu(...e){const[t,i,r,s]=e,n=pt();let a=pt();if(!Dt(t))throw Fr(Zr.INVALID_ARGUMENT);const o=t;return He(i)?n.key=i:Ye(i)&&Object.keys(i).forEach(l=>{Rm.includes(l)?a[l]=i[l]:n[l]=i[l]}),He(r)?n.locale=r:Ye(r)&&(a=r),Ye(s)&&(a=s),[n.key||"",o,n,a]}function Q2(e,t,i){const r=e;for(const s in i){const n=`${t}__${s}`;r.__numberFormatters.has(n)&&r.__numberFormatters.delete(n)}}const Jy=e=>e,Qy=e=>"",e7="text",t7=e=>e.length===0?"":qh(e),i7=Zb;function s1(e,t){return e=Math.abs(e),t===2?e===1?0:1:Math.min(e,2)}function r7(e){var i,r;const t=Dt(e.pluralIndex)?e.pluralIndex:-1;return Dt((i=e.named)==null?void 0:i.count)?e.named.count:Dt((r=e.named)==null?void 0:r.n)?e.named.n:t}function s7(e={}){var p,C,w,v;const t=e.locale,i=r7(e),r=He(t)&&yt((p=e.pluralRules)==null?void 0:p[t])?e.pluralRules[t]:s1,s=r===s1?void 0:s1,n=k=>k[r(i,k.length,s)],a=e.list||[],o=k=>a[k],l=e.named||pt();Dt(e.pluralIndex)&&(l.count||(l.count=e.pluralIndex),l.n||(l.n=e.pluralIndex));const c=k=>l[k];function u(k,$){const M=yt(e.messages)?e.messages(k,!!$):ot(e.messages)?e.messages[k]:!1;return M||(e.parent?e.parent.message(k):Qy)}const h=k=>e.modifiers?e.modifiers[k]:Jy,d=yt((C=e.processor)==null?void 0:C.normalize)?e.processor.normalize:t7,f=yt((w=e.processor)==null?void 0:w.interpolate)?e.processor.interpolate:i7,m=He((v=e.processor)==null?void 0:v.type)?e.processor.type:e7,y={list:o,named:c,plural:n,linked:(k,...$)=>{const[M,D]=$;let H="text",R="";$.length===1?ot(M)?(R=M.modifier||R,H=M.type||H):He(M)&&(R=M||R):$.length===2&&(He(M)&&(R=M||R),He(D)&&(H=D||H));const V=u(k,!0)(y),N=V===""||V===void 0?k:V,P=H==="vnode"&&xt(N)&&R?N[0]:N;return R?h(R)(P,H):P},message:u,type:m,interpolate:f,normalize:d,values:Ut(pt(),a,l)};return y}const ef=()=>"",zi=e=>yt(e);function tf(e,...t){const{fallbackFormat:i,postTranslation:r,unresolving:s,messageCompiler:n,fallbackLocale:a,messages:o}=e,[l,c]=iu(...t),u=Je(c.missingWarn)?c.missingWarn:e.missingWarn,h=Je(c.fallbackWarn)?c.fallbackWarn:e.fallbackWarn,d=Je(c.escapeParameter)?c.escapeParameter:e.escapeParameter,f=!!c.resolvedMessage,m=He(c.default)||Je(c.default)?Je(c.default)?n?l:()=>l:c.default:i?n?l:()=>l:null,_=i||m!=null&&(He(m)||yt(m)),y=Xh(e,c);d&&n7(c);let[p,C,w]=f?[l,y,o[y]||pt()]:Dm(e,l,y,a,h,u),v=p,k=l;if(!f&&!(He(v)||yr(v)||zi(v))&&_&&(v=m,k=v),!f&&(!(He(v)||yr(v)||zi(v))||!He(C)))return s?gc:l;let $=!1;const M=()=>{$=!0},D=zi(v)?v:Vm(e,l,C,v,k,M);if($)return v;const H=l7(e,C,w,c),R=s7(H),V=a7(e,D,R);let N=r?r(V,l):V;if(d&&He(N)&&(N=Db(N)),__INTLIFY_PROD_DEVTOOLS__){const P={timestamp:Date.now(),key:He(l)?l:zi(v)?v.key:"",locale:C||(zi(v)?v.locale:""),format:He(v)?v:zi(v)?v.source:"",message:N};P.meta=Ut({},e.__meta,Ky()||{}),Ly(P)}return N}function n7(e){xt(e.list)?e.list=e.list.map(t=>He(t)?D2(t):t):ot(e.named)&&Object.keys(e.named).forEach(t=>{He(e.named[t])&&(e.named[t]=D2(e.named[t]))})}function Dm(e,t,i,r,s,n){const{messages:a,onWarn:o,messageResolver:l,localeFallbacker:c}=e,u=c(e,r,i);let h=pt(),d,f=null;const m="translate";for(let _=0;_<u.length&&(d=u[_],h=a[d]||pt(),(f=l(h,t))===null&&(f=h[t]),!(He(f)||yr(f)||zi(f)));_++)if(!Xy(d,u)){const y=Jh(e,t,d,n,m);y!==t&&(f=y)}return[f,d,h]}function Vm(e,t,i,r,s,n){const{messageCompiler:a,warnHtmlMessage:o}=e;if(zi(r)){const c=r;return c.locale=c.locale||i,c.key=c.key||t,c}if(a==null){const c=()=>r;return c.locale=i,c.key=t,c}const l=a(r,o7(e,i,s,r,o,n));return l.locale=i,l.key=t,l.source=r,l}function a7(e,t,i){return t(i)}function iu(...e){const[t,i,r]=e,s=pt();if(!He(t)&&!Dt(t)&&!zi(t)&&!yr(t))throw Fr(Zr.INVALID_ARGUMENT);const n=Dt(t)?String(t):(zi(t),t);return Dt(i)?s.plural=i:He(i)?s.default=i:Ye(i)&&!_c(i)?s.named=i:xt(i)&&(s.list=i),Dt(r)?s.plural=r:He(r)?s.default=r:Ye(r)&&Ut(s,r),[n,s]}function o7(e,t,i,r,s,n){return{locale:t,key:i,warnHtmlMessage:s,onError:a=>{throw n&&n(a),a},onCacheKey:a=>Ob(t,i,a)}}function l7(e,t,i,r){const{modifiers:s,pluralRules:n,messageResolver:a,fallbackLocale:o,fallbackWarn:l,missingWarn:c,fallbackContext:u}=e,d={locale:t,modifiers:s,pluralRules:n,messages:(f,m)=>{let _=a(i,f);if(_==null&&(u||m)){const[,,y]=Dm(u||e,f,t,o,l,c);_=a(y,f)}if(He(_)||yr(_)){let y=!1;const C=Vm(e,f,t,_,f,()=>{y=!0});return y?ef:C}else return zi(_)?_:ef}};return e.processor&&(d.processor=e.processor),r.list&&(d.list=r.list),r.named&&(d.named=r.named),Dt(r.plural)&&(d.pluralIndex=r.plural),d}py();/*!
|
|
36
|
-
* vue-i18n v11.3.0
|
|
37
|
-
* (c) 2026 kazuya kawaguchi
|
|
38
|
-
* Released under the MIT License.
|
|
39
|
-
*/const c7="11.3.0";function u7(){typeof __VUE_I18N_FULL_INSTALL__!="boolean"&&(js().__VUE_I18N_FULL_INSTALL__=!0),typeof __VUE_I18N_LEGACY_API__!="boolean"&&(js().__VUE_I18N_LEGACY_API__=!0),typeof __INTLIFY_DROP_MESSAGE_COMPILER__!="boolean"&&(js().__INTLIFY_DROP_MESSAGE_COMPILER__=!1),typeof __INTLIFY_PROD_DEVTOOLS__!="boolean"&&(js().__INTLIFY_PROD_DEVTOOLS__=!1)}const Ei={UNEXPECTED_RETURN_TYPE:$y,INVALID_ARGUMENT:25,MUST_BE_CALL_SETUP_TOP:26,NOT_INSTALLED:27,REQUIRED_VALUE:28,INVALID_VALUE:29,NOT_INSTALLED_WITH_PROVIDE:31,UNEXPECTED_ERROR:32};function Ri(e,...t){return mc(e,null,void 0)}const ru=Ms("__translateVNode"),su=Ms("__datetimeParts"),nu=Ms("__numberParts"),Bm=Ms("__setPluralRules"),Zm=Ms("__injectWithOption"),au=Ms("__dispose");function tl(e){if(!ot(e)||yr(e))return e;for(const t in e)if(Ui(e,t))if(!t.includes("."))ot(e[t])&&tl(e[t]);else{const i=t.split("."),r=i.length-1;let s=e,n=!1;for(let a=0;a<r;a++){if(i[a]==="__proto__")throw new Error(`unsafe key: ${i[a]}`);if(i[a]in s||(s[i[a]]=pt()),!ot(s[i[a]])){n=!0;break}s=s[i[a]]}if(n||(yr(s)?xm.includes(i[r])||delete e[t]:(s[i[r]]=e[t],delete e[t])),!yr(s)){const a=s[i[r]];ot(a)&&tl(a)}}return e}function Qh(e,t){const{messages:i,__i18n:r,messageResolver:s,flatJson:n}=t,a=Ye(i)?i:xt(r)?pt():{[e]:pt()};if(xt(r)&&r.forEach(o=>{if("locale"in o&&"resource"in o){const{locale:l,resource:c}=o;l?(a[l]=a[l]||pt(),n0(c,a[l])):n0(c,a)}else He(o)&&n0(JSON.parse(o),a)}),s==null&&n)for(const o in a)Ui(a,o)&&tl(a[o]);return a}function Fm(e){return e.type}function zm(e,t,i){let r=ot(t.messages)?t.messages:pt();"__i18nGlobal"in i&&(r=Qh(e.locale.value,{messages:r,__i18n:i.__i18nGlobal}));const s=Object.keys(r);s.length&&s.forEach(n=>{e.mergeLocaleMessage(n,r[n])});{if(ot(t.datetimeFormats)){const n=Object.keys(t.datetimeFormats);n.length&&n.forEach(a=>{e.mergeDateTimeFormat(a,t.datetimeFormats[a])})}if(ot(t.numberFormats)){const n=Object.keys(t.numberFormats);n.length&&n.forEach(a=>{e.mergeNumberFormat(a,t.numberFormats[a])})}}}function rf(e){return Y(As,null,e,0)}function il(){return ki()}const sf="__INTLIFY_META__",nf=()=>[],h7=()=>!1;let af=0;function of(e){return(t,i,r,s)=>e(i,r,il()||void 0,s)}const d7=()=>{const e=il();let t=null;return e&&(t=Fm(e)[sf])?{[sf]:t}:null};function ed(e={}){const{__root:t,__injectWithOption:i}=e,r=t===void 0,s=e.flatJson,n=E0?X:Ar;let a=Je(e.inheritLocale)?e.inheritLocale:!0;const o=n(t&&a?t.locale.value:He(e.locale)?e.locale:el),l=n(t&&a?t.fallbackLocale.value:He(e.fallbackLocale)||xt(e.fallbackLocale)||Ye(e.fallbackLocale)||e.fallbackLocale===!1?e.fallbackLocale:o.value),c=n(Qh(o.value,e)),u=n(Ye(e.datetimeFormats)?e.datetimeFormats:{[o.value]:{}}),h=n(Ye(e.numberFormats)?e.numberFormats:{[o.value]:{}});let d=t?t.missingWarn:Je(e.missingWarn)||Pn(e.missingWarn)?e.missingWarn:!0,f=t?t.fallbackWarn:Je(e.fallbackWarn)||Pn(e.fallbackWarn)?e.fallbackWarn:!0,m=t?t.fallbackRoot:Je(e.fallbackRoot)?e.fallbackRoot:!0,_=!!e.fallbackFormat,y=yt(e.missing)?e.missing:null,p=yt(e.missing)?of(e.missing):null,C=yt(e.postTranslation)?e.postTranslation:null,w=t?t.warnHtmlMessage:Je(e.warnHtmlMessage)?e.warnHtmlMessage:!0,v=!!e.escapeParameter;const k=t?t.modifiers:Ye(e.modifiers)?e.modifiers:{};let $=e.pluralRules||t&&t.pluralRules,M;M=(()=>{r&&q2(null);const W={version:c7,locale:o.value,fallbackLocale:l.value,messages:c.value,modifiers:k,pluralRules:$,missing:p===null?void 0:p,missingWarn:d,fallbackWarn:f,fallbackFormat:_,unresolving:!0,postTranslation:C===null?void 0:C,warnHtmlMessage:w,escapeParameter:v,messageResolver:e.messageResolver,messageCompiler:e.messageCompiler,__meta:{framework:"vue"}};W.datetimeFormats=u.value,W.numberFormats=h.value,W.__datetimeFormatters=Ye(M)?M.__datetimeFormatters:void 0,W.__numberFormatters=Ye(M)?M.__numberFormatters:void 0;const ae=Gy(W);return r&&q2(ae),ae})(),fo(M,o.value,l.value);function H(){return[o.value,l.value,c.value,u.value,h.value]}const R=Q({get:()=>o.value,set:W=>{M.locale=W,o.value=W}}),V=Q({get:()=>l.value,set:W=>{M.fallbackLocale=W,l.value=W,fo(M,o.value,W)}}),N=Q(()=>c.value),P=Q(()=>u.value),U=Q(()=>h.value);function j(){return yt(C)?C:null}function oe(W){C=W,M.postTranslation=W}function te(){return y}function ne(W){W!==null&&(p=of(W)),y=W,M.missing=p}const J=(W,ae,ye,ke,Oe,je)=>{H();let Ee;try{__INTLIFY_PROD_DEVTOOLS__,r||(M.fallbackContext=t?qy():void 0),Ee=W(M)}finally{__INTLIFY_PROD_DEVTOOLS__,r||(M.fallbackContext=void 0)}if(ye!=="translate exists"&&Dt(Ee)&&Ee===gc||ye==="translate exists"&&!Ee){const[lt,Ot]=ae();return t&&m?ke(t):Oe(lt)}else{if(je(Ee))return Ee;throw Ri(Ei.UNEXPECTED_RETURN_TYPE)}};function fe(...W){return J(ae=>Reflect.apply(tf,null,[ae,...W]),()=>iu(...W),"translate",ae=>Reflect.apply(ae.t,ae,[...W]),ae=>ae,ae=>He(ae))}function re(...W){const[ae,ye,ke]=W;if(ke&&!ot(ke))throw Ri(Ei.INVALID_ARGUMENT);return fe(ae,ye,Ut({resolvedMessage:!0},ke||{}))}function _e(...W){return J(ae=>Reflect.apply(Y2,null,[ae,...W]),()=>eu(...W),"datetime format",ae=>Reflect.apply(ae.d,ae,[...W]),()=>$0,ae=>He(ae)||xt(ae))}function Ne(...W){return J(ae=>Reflect.apply(J2,null,[ae,...W]),()=>tu(...W),"number format",ae=>Reflect.apply(ae.n,ae,[...W]),()=>$0,ae=>He(ae)||xt(ae))}function $e(W){return W.map(ae=>He(ae)||Dt(ae)||Je(ae)?rf(String(ae)):ae)}const me={normalize:$e,interpolate:W=>W,type:"vnode"};function O(...W){return J(ae=>{let ye;const ke=ae;try{ke.processor=me,ye=Reflect.apply(tf,null,[ke,...W])}finally{ke.processor=null}return ye},()=>iu(...W),"translate",ae=>ae[ru](...W),ae=>[rf(ae)],ae=>xt(ae))}function ie(...W){return J(ae=>Reflect.apply(J2,null,[ae,...W]),()=>tu(...W),"number format",ae=>ae[nu](...W),nf,ae=>He(ae)||xt(ae))}function le(...W){return J(ae=>Reflect.apply(Y2,null,[ae,...W]),()=>eu(...W),"datetime format",ae=>ae[su](...W),nf,ae=>He(ae)||xt(ae))}function ge(W){$=W,M.pluralRules=$}function Se(W,ae){return J(()=>{if(!W)return!1;const ye=He(ae)?ae:o.value,ke=He(ae)?[ye]:Q1(M,l.value,ye);for(let Oe=0;Oe<ke.length;Oe++){const je=K(ke[Oe]);let Ee=M.messageResolver(je,W);if(Ee===null&&(Ee=je[W]),yr(Ee)||zi(Ee)||He(Ee))return!0}return!1},()=>[W],"translate exists",ye=>Reflect.apply(ye.te,ye,[W,ae]),h7,ye=>Je(ye))}function x(W){let ae=null;const ye=Q1(M,l.value,o.value);for(let ke=0;ke<ye.length;ke++){const Oe=c.value[ye[ke]]||{},je=M.messageResolver(Oe,W);if(je!=null){ae=je;break}}return ae}function T(W){const ae=x(W);return ae??(t?t.tm(W)||{}:{})}function K(W){return c.value[W]||{}}function se(W,ae){if(s){const ye={[W]:ae};for(const ke in ye)Ui(ye,ke)&&tl(ye[ke]);ae=ye[W]}c.value[W]=ae,M.messages=c.value}function he(W,ae){c.value[W]=c.value[W]||{};const ye={[W]:ae};if(s)for(const ke in ye)Ui(ye,ke)&&tl(ye[ke]);ae=ye[W],n0(ae,c.value[W]),M.messages=c.value}function pe(W){return u.value[W]||{}}function S(W,ae){u.value[W]=ae,M.datetimeFormats=u.value,X2(M,W,ae)}function A(W,ae){u.value[W]=Ut(u.value[W]||{},ae),M.datetimeFormats=u.value,X2(M,W,ae)}function B(W){return h.value[W]||{}}function L(W,ae){h.value[W]=ae,M.numberFormats=h.value,Q2(M,W,ae)}function I(W,ae){h.value[W]=Ut(h.value[W]||{},ae),M.numberFormats=h.value,Q2(M,W,ae)}af++,t&&E0&&(Fe(t.locale,W=>{a&&(o.value=W,M.locale=W,fo(M,o.value,l.value))}),Fe(t.fallbackLocale,W=>{a&&(l.value=W,M.fallbackLocale=W,fo(M,o.value,l.value))}));const z={id:af,locale:R,fallbackLocale:V,get inheritLocale(){return a},set inheritLocale(W){a=W,W&&t&&(o.value=t.locale.value,l.value=t.fallbackLocale.value,fo(M,o.value,l.value))},get availableLocales(){return Object.keys(c.value).sort()},messages:N,get modifiers(){return k},get pluralRules(){return $||{}},get isGlobal(){return r},get missingWarn(){return d},set missingWarn(W){d=W,M.missingWarn=d},get fallbackWarn(){return f},set fallbackWarn(W){f=W,M.fallbackWarn=f},get fallbackRoot(){return m},set fallbackRoot(W){m=W},get fallbackFormat(){return _},set fallbackFormat(W){_=W,M.fallbackFormat=_},get warnHtmlMessage(){return w},set warnHtmlMessage(W){w=W,M.warnHtmlMessage=W},get escapeParameter(){return v},set escapeParameter(W){v=W,M.escapeParameter=W},t:fe,getLocaleMessage:K,setLocaleMessage:se,mergeLocaleMessage:he,getPostTranslationHandler:j,setPostTranslationHandler:oe,getMissingHandler:te,setMissingHandler:ne,[Bm]:ge};return z.datetimeFormats=P,z.numberFormats=U,z.rt=re,z.te=Se,z.tm=T,z.d=_e,z.n=Ne,z.getDateTimeFormat=pe,z.setDateTimeFormat=S,z.mergeDateTimeFormat=A,z.getNumberFormat=B,z.setNumberFormat=L,z.mergeNumberFormat=I,z[Zm]=i,z[ru]=O,z[su]=le,z[nu]=ie,z}function f7(e){const t=He(e.locale)?e.locale:el,i=He(e.fallbackLocale)||xt(e.fallbackLocale)||Ye(e.fallbackLocale)||e.fallbackLocale===!1?e.fallbackLocale:t,r=yt(e.missing)?e.missing:void 0,s=Je(e.silentTranslationWarn)||Pn(e.silentTranslationWarn)?!e.silentTranslationWarn:!0,n=Je(e.silentFallbackWarn)||Pn(e.silentFallbackWarn)?!e.silentFallbackWarn:!0,a=Je(e.fallbackRoot)?e.fallbackRoot:!0,o=!!e.formatFallbackMessages,l=Ye(e.modifiers)?e.modifiers:{},c=e.pluralizationRules,u=yt(e.postTranslation)?e.postTranslation:void 0,h=He(e.warnHtmlInMessage)?e.warnHtmlInMessage!=="off":!0,d=!!e.escapeParameterHtml,f=Je(e.sync)?e.sync:!0;let m=e.messages;if(Ye(e.sharedMessages)){const k=e.sharedMessages;m=Object.keys(k).reduce((M,D)=>{const H=M[D]||(M[D]={});return Ut(H,k[D]),M},m||{})}const{__i18n:_,__root:y,__injectWithOption:p}=e,C=e.datetimeFormats,w=e.numberFormats,v=e.flatJson;return{locale:t,fallbackLocale:i,messages:m,flatJson:v,datetimeFormats:C,numberFormats:w,missing:r,missingWarn:s,fallbackWarn:n,fallbackRoot:a,fallbackFormat:o,modifiers:l,pluralRules:c,postTranslation:u,warnHtmlMessage:h,escapeParameter:d,messageResolver:e.messageResolver,inheritLocale:f,__i18n:_,__root:y,__injectWithOption:p}}function ou(e={}){const t=ed(f7(e)),{__extender:i}=e,r={id:t.id,get locale(){return t.locale.value},set locale(s){t.locale.value=s},get fallbackLocale(){return t.fallbackLocale.value},set fallbackLocale(s){t.fallbackLocale.value=s},get messages(){return t.messages.value},get datetimeFormats(){return t.datetimeFormats.value},get numberFormats(){return t.numberFormats.value},get availableLocales(){return t.availableLocales},get missing(){return t.getMissingHandler()},set missing(s){t.setMissingHandler(s)},get silentTranslationWarn(){return Je(t.missingWarn)?!t.missingWarn:t.missingWarn},set silentTranslationWarn(s){t.missingWarn=Je(s)?!s:s},get silentFallbackWarn(){return Je(t.fallbackWarn)?!t.fallbackWarn:t.fallbackWarn},set silentFallbackWarn(s){t.fallbackWarn=Je(s)?!s:s},get modifiers(){return t.modifiers},get formatFallbackMessages(){return t.fallbackFormat},set formatFallbackMessages(s){t.fallbackFormat=s},get postTranslation(){return t.getPostTranslationHandler()},set postTranslation(s){t.setPostTranslationHandler(s)},get sync(){return t.inheritLocale},set sync(s){t.inheritLocale=s},get warnHtmlInMessage(){return t.warnHtmlMessage?"warn":"off"},set warnHtmlInMessage(s){t.warnHtmlMessage=s!=="off"},get escapeParameterHtml(){return t.escapeParameter},set escapeParameterHtml(s){t.escapeParameter=s},get pluralizationRules(){return t.pluralRules||{}},__composer:t,t(...s){return Reflect.apply(t.t,t,[...s])},rt(...s){return Reflect.apply(t.rt,t,[...s])},te(s,n){return t.te(s,n)},tm(s){return t.tm(s)},getLocaleMessage(s){return t.getLocaleMessage(s)},setLocaleMessage(s,n){t.setLocaleMessage(s,n)},mergeLocaleMessage(s,n){t.mergeLocaleMessage(s,n)},d(...s){return Reflect.apply(t.d,t,[...s])},getDateTimeFormat(s){return t.getDateTimeFormat(s)},setDateTimeFormat(s,n){t.setDateTimeFormat(s,n)},mergeDateTimeFormat(s,n){t.mergeDateTimeFormat(s,n)},n(...s){return Reflect.apply(t.n,t,[...s])},getNumberFormat(s){return t.getNumberFormat(s)},setNumberFormat(s,n){t.setNumberFormat(s,n)},mergeNumberFormat(s,n){t.mergeNumberFormat(s,n)}};return r.__extender=i,r}function p7(e,t,i){return{beforeCreate(){const r=il();if(!r)throw Ri(Ei.UNEXPECTED_ERROR);const s=this.$options;if(s.i18n){const n=s.i18n;if(s.__i18n&&(n.__i18n=s.__i18n),n.__root=t,this===this.$root)this.$i18n=lf(e,n);else{n.__injectWithOption=!0,n.__extender=i.__vueI18nExtend,this.$i18n=ou(n);const a=this.$i18n;a.__extender&&(a.__disposer=a.__extender(this.$i18n))}}else if(s.__i18n)if(this===this.$root)this.$i18n=lf(e,s);else{this.$i18n=ou({__i18n:s.__i18n,__injectWithOption:!0,__extender:i.__vueI18nExtend,__root:t});const n=this.$i18n;n.__extender&&(n.__disposer=n.__extender(this.$i18n))}else this.$i18n=e;s.__i18nGlobal&&zm(t,s,s),this.$t=(...n)=>this.$i18n.t(...n),this.$rt=(...n)=>this.$i18n.rt(...n),this.$te=(n,a)=>this.$i18n.te(n,a),this.$d=(...n)=>this.$i18n.d(...n),this.$n=(...n)=>this.$i18n.n(...n),this.$tm=n=>this.$i18n.tm(n),i.__setInstance(r,this.$i18n)},mounted(){},unmounted(){const r=il();if(!r)throw Ri(Ei.UNEXPECTED_ERROR);const s=this.$i18n;delete this.$t,delete this.$rt,delete this.$te,delete this.$d,delete this.$n,delete this.$tm,s.__disposer&&(s.__disposer(),delete s.__disposer,delete s.__extender),i.__deleteInstance(r),delete this.$i18n}}}function lf(e,t){e.locale=t.locale||e.locale,e.fallbackLocale=t.fallbackLocale||e.fallbackLocale,e.missing=t.missing||e.missing,e.silentTranslationWarn=t.silentTranslationWarn||e.silentFallbackWarn,e.silentFallbackWarn=t.silentFallbackWarn||e.silentFallbackWarn,e.formatFallbackMessages=t.formatFallbackMessages||e.formatFallbackMessages,e.postTranslation=t.postTranslation||e.postTranslation,e.warnHtmlInMessage=t.warnHtmlInMessage||e.warnHtmlInMessage,e.escapeParameterHtml=t.escapeParameterHtml||e.escapeParameterHtml,e.sync=t.sync||e.sync,e.__composer[Bm](t.pluralizationRules||e.pluralizationRules);const i=Qh(e.locale,{messages:t.messages,__i18n:t.__i18n});return Object.keys(i).forEach(r=>e.mergeLocaleMessage(r,i[r])),t.datetimeFormats&&Object.keys(t.datetimeFormats).forEach(r=>e.mergeDateTimeFormat(r,t.datetimeFormats[r])),t.numberFormats&&Object.keys(t.numberFormats).forEach(r=>e.mergeNumberFormat(r,t.numberFormats[r])),e}const td={tag:{type:[String,Object]},locale:{type:String},scope:{type:String,validator:e=>e==="parent"||e==="global",default:"parent"},i18n:{type:Object}};function _7({slots:e},t){return t.length===1&&t[0]==="default"?(e.default?e.default():[]).reduce((r,s)=>[...r,...s.type===we?s.children:[s]],[]):t.reduce((i,r)=>{const s=e[r];return s&&(i[r]=s()),i},pt())}function Um(){return we}const m7=Re({name:"i18n-t",props:Ut({keypath:{type:String,required:!0},plural:{type:[Number,String],validator:e=>Dt(e)||!isNaN(e)}},td),setup(e,t){const{slots:i,attrs:r}=t,s=e.i18n||id({useScope:e.scope,__useComponent:!0});return()=>{const n=Object.keys(i).filter(h=>h[0]!=="_"),a=pt();e.locale&&(a.locale=e.locale),e.plural!==void 0&&(a.plural=He(e.plural)?+e.plural:e.plural);const o=_7(t,n),l=s[ru](e.keypath,o,a),c=Ut(pt(),r),u=He(e.tag)||ot(e.tag)?e.tag:Um();return Me(u,c,l)}}}),cf=m7;function g7(e){return xt(e)&&!He(e[0])}function Wm(e,t,i,r){const{slots:s,attrs:n}=t;return()=>{const a={part:!0};let o=pt();e.locale&&(a.locale=e.locale),He(e.format)?a.key=e.format:ot(e.format)&&(He(e.format.key)&&(a.key=e.format.key),o=Object.keys(e.format).reduce((d,f)=>i.includes(f)?Ut(pt(),d,{[f]:e.format[f]}):d,pt()));const l=r(e.value,a,o);let c=[a.key];xt(l)?c=l.map((d,f)=>{const m=s[d.type],_=m?m({[d.type]:d.value,index:f,parts:l}):[d.value];return g7(_)&&(_[0].key=`${d.type}-${f}`),_}):He(l)&&(c=[l]);const u=Ut(pt(),n),h=He(e.tag)||ot(e.tag)?e.tag:Um();return Me(h,u,c)}}const v7=Re({name:"i18n-n",props:Ut({value:{type:Number,required:!0},format:{type:[String,Object]}},td),setup(e,t){const i=e.i18n||id({useScope:e.scope,__useComponent:!0});return Wm(e,t,Rm,(...r)=>i[nu](...r))}}),uf=v7;function b7(e,t){const i=e;if(e.mode==="composition")return i.__getInstance(t)||e.global;{const r=i.__getInstance(t);return r!=null?r.__composer:e.global.__composer}}function y7(e){const t=a=>{const{instance:o,value:l}=a;if(!o||!o.$)throw Ri(Ei.UNEXPECTED_ERROR);const c=b7(e,o.$),u=hf(l);return[Reflect.apply(c.t,c,[...df(u)]),c]};return{created:(a,o)=>{const[l,c]=t(o);E0&&(a.__i18nWatcher=Fe(c.locale,()=>{o.instance&&o.instance.$forceUpdate()})),a.__composer=c,a.textContent=l},unmounted:a=>{E0&&a.__i18nWatcher&&(a.__i18nWatcher(),a.__i18nWatcher=void 0,delete a.__i18nWatcher),a.__composer&&(a.__composer=void 0,delete a.__composer)},beforeUpdate:(a,{value:o})=>{if(a.__composer){const l=a.__composer,c=hf(o);a.textContent=Reflect.apply(l.t,l,[...df(c)])}},getSSRProps:a=>{const[o]=t(a);return{textContent:o}}}}function hf(e){if(He(e))return{path:e};if(Ye(e)){if(!("path"in e))throw Ri(Ei.REQUIRED_VALUE,"path");return e}else throw Ri(Ei.INVALID_VALUE)}function df(e){const{path:t,locale:i,args:r,choice:s,plural:n}=e,a={},o=r||{};return He(i)&&(a.locale=i),Dt(s)&&(a.plural=s),Dt(n)&&(a.plural=n),[t,o,a]}function w7(e,t,...i){const r=Ye(i[0])?i[0]:{};(Je(r.globalInstall)?r.globalInstall:!0)&&([cf.name,"I18nT"].forEach(n=>e.component(n,cf)),[uf.name,"I18nN"].forEach(n=>e.component(n,uf)),[pf.name,"I18nD"].forEach(n=>e.component(n,pf))),e.directive("t",y7(t))}const S7=Ms("global-vue-i18n");function C7(e={}){const t=__VUE_I18N_LEGACY_API__&&Je(e.legacy)?e.legacy:__VUE_I18N_LEGACY_API__,i=Je(e.globalInjection)?e.globalInjection:!0,r=new Map,[s,n]=k7(e,t),a=Ms("");function o(h){return r.get(h)||null}function l(h,d){r.set(h,d)}function c(h){r.delete(h)}const u={get mode(){return __VUE_I18N_LEGACY_API__&&t?"legacy":"composition"},async install(h,...d){if(h.__VUE_I18N_SYMBOL__=a,h.provide(h.__VUE_I18N_SYMBOL__,u),Ye(d[0])){const _=d[0];u.__composerExtend=_.__composerExtend,u.__vueI18nExtend=_.__vueI18nExtend}let f=null;!t&&i&&(f=N7(h,u.global)),__VUE_I18N_FULL_INSTALL__&&w7(h,u,...d),__VUE_I18N_LEGACY_API__&&t&&h.mixin(p7(n,n.__composer,u));const m=h.unmount;h.unmount=()=>{f&&f(),u.dispose(),m()}},get global(){return n},dispose(){s.stop()},__instances:r,__getInstance:o,__setInstance:l,__deleteInstance:c};return u}function id(e={}){const t=il();if(t==null)throw Ri(Ei.MUST_BE_CALL_SETUP_TOP);if(!t.isCE&&t.appContext.app!=null&&!t.appContext.app.__VUE_I18N_SYMBOL__)throw Ri(Ei.NOT_INSTALLED);const i=A7(t),r=L7(i),s=Fm(t),n=M7(e,s);if(n==="global")return zm(r,e,s),r;if(n==="parent"){let l=E7(i,t,e.__useComponent);return l==null&&(l=r),l}const a=i;let o=a.__getInstance(t);if(o==null){const l=Ut({},e);"__i18n"in s&&(l.__i18n=s.__i18n),r&&(l.__root=r),o=ed(l),a.__composerExtend&&(o[au]=a.__composerExtend(o)),x7(a,t,o),a.__setInstance(t,o)}return o}function k7(e,t){const i=Nh(),r=__VUE_I18N_LEGACY_API__&&t?i.run(()=>ou(e)):i.run(()=>ed(e));if(r==null)throw Ri(Ei.UNEXPECTED_ERROR);return[i,r]}function A7(e){const t=ai(e.isCE?S7:e.appContext.app.__VUE_I18N_SYMBOL__);if(!t)throw Ri(e.isCE?Ei.NOT_INSTALLED_WITH_PROVIDE:Ei.UNEXPECTED_ERROR);return t}function M7(e,t){return _c(e)?"__i18n"in t?"local":"global":e.useScope?e.useScope:"local"}function L7(e){return e.mode==="composition"?e.global:e.global.__composer}function E7(e,t,i=!1){let r=null;const s=t.root;let n=$7(t,i);for(;n!=null;){const a=e;if(e.mode==="composition")r=a.__getInstance(n);else if(__VUE_I18N_LEGACY_API__){const o=a.__getInstance(n);o!=null&&(r=o.__composer,i&&r&&!r[Zm]&&(r=null))}if(r!=null||s===n)break;n=n.parent}return r}function $7(e,t=!1){return e==null?null:t&&e.vnode.ctx||e.parent}function x7(e,t,i){ut(()=>{},t),Ii(()=>{const r=i;e.__deleteInstance(t);const s=r[au];s&&(s(),delete r[au])},t)}const T7=["locale","fallbackLocale","availableLocales"],ff=["t","rt","d","n","tm","te"];function N7(e,t){const i=Object.create(null);return T7.forEach(s=>{const n=Object.getOwnPropertyDescriptor(t,s);if(!n)throw Ri(Ei.UNEXPECTED_ERROR);const a=wt(n.value)?{get(){return n.value.value},set(o){n.value.value=o}}:{get(){return n.get&&n.get()}};Object.defineProperty(i,s,a)}),e.config.globalProperties.$i18n=i,ff.forEach(s=>{const n=Object.getOwnPropertyDescriptor(t,s);if(!n||!n.value)throw Ri(Ei.UNEXPECTED_ERROR);Object.defineProperty(e.config.globalProperties,`$${s}`,n)}),()=>{delete e.config.globalProperties.$i18n,ff.forEach(s=>{delete e.config.globalProperties[`$${s}`]})}}const H7=Re({name:"i18n-d",props:Ut({value:{type:[Number,Date],required:!0},format:{type:[String,Object]}},td),setup(e,t){const i=e.i18n||id({useScope:e.scope,__useComponent:!0});return Wm(e,t,Im,(...r)=>i[su](...r))}}),pf=H7;u7();zy(ky);Uy(By);Wy(Q1);if(__INTLIFY_PROD_DEVTOOLS__){const e=js();e.__INTLIFY__=!0,Ay(e.__INTLIFY_DEVTOOLS_GLOBAL_HOOK__)}var jm="(prefers-reduced-motion: reduce)";function P7(){let e=X(!1);if(typeof window<"u"&&typeof window.matchMedia=="function"){let t=window.matchMedia(jm);e.value=t.matches;let i=r=>{e.value=r.matches};typeof t.addEventListener=="function"?(t.addEventListener("change",i),I1(()=>t.removeEventListener("change",i))):typeof t.addListener=="function"&&(t.addListener(i),I1(()=>t.removeListener(i)))}return xn(e)}function rd(){return typeof window>"u"||typeof window.matchMedia!="function"?!1:window.matchMedia(jm).matches}var lu="data-nb-tour-step",O7=Symbol("nb-command-palette");function I7(){let e=tn(new Map),t=X(!1),i=X(void 0),r=X(void 0);function s(u){e.set(u.id,u)}function n(u){for(let h of u)e.set(h.id,h)}function a(u){e.delete(u)}function o(u){r.value=u,t.value=!0}function l(){t.value=!1,r.value=void 0}function c(u){i.value=u}return tn({commands:e,isOpen:t,activeContext:i,searchFilter:r,register:s,registerMany:n,unregister:a,open:o,close:l,setContext:c})}var ht=(e,t)=>{let i=e.__vccOpts||e;for(let[r,s]of t)i[r]=s;return i},_f=Object.defineProperty,vc=(e,t)=>{let i={};for(var r in e)_f(i,r,{get:e[r],enumerable:!0});return _f(i,Symbol.toStringTag,{value:"Module"}),i},R7=vc({default:()=>D7});function D7(e){e.directive("nb-context-menu",{mounted(t,i){let r=s=>{s.preventDefault(),typeof i.value=="function"&&i.value({x:s.clientX,y:s.clientY})};t.__nbContextMenuHandler__=r,t.addEventListener("contextmenu",r)},updated(t,i){t.__nbContextMenuHandler__&&t.removeEventListener("contextmenu",t.__nbContextMenuHandler__);let r=s=>{s.preventDefault(),typeof i.value=="function"&&i.value({x:s.clientX,y:s.clientY})};t.__nbContextMenuHandler__=r,t.addEventListener("contextmenu",r)},unmounted(t){t.__nbContextMenuHandler__&&(t.removeEventListener("contextmenu",t.__nbContextMenuHandler__),delete t.__nbContextMenuHandler__)}})}var V7=vc({devWarn:()=>ws,renderTooltipContent:()=>a0}),mf=new Set(["span","div","p","b","strong","em","i","u","s","small","code","kbd","br","ul","ol","li"]),B7=new Set(["br"]),gf=new Set(["class","style","dir","lang"]),Z7=e=>e.replace(/&/g,"&").replace(/</g,"<").replace(/>/g,">").replace(/"/g,""").replace(/'/g,"'"),F7=new Set("color.background-color.font-family.font-size.font-style.font-variant.font-weight.letter-spacing.line-height.text-align.text-decoration.text-transform.white-space.word-break.overflow-wrap.opacity.display.flex-direction.align-items.justify-content.gap.margin.margin-top.margin-right.margin-bottom.margin-left.padding.padding-top.padding-right.padding-bottom.padding-left.max-width.min-width.border-radius".split(".")),z7=/url\(|image-set\(|expression\(|javascript:|@import|\\/i,U7=/^[A-Za-z_-][A-Za-z0-9_-]*$/,W7=e=>e.split(";").map(t=>{let i=t.indexOf(":");if(i<0)return"";let r=t.slice(0,i).trim().toLowerCase(),s=t.slice(i+1).trim();return!r||!s?"":F7.has(r)?z7.test(s)?(ws(`style-value:${r}`,`The value of "${r}" was dropped: tooltip content may not load a resource or call a CSS function that does.`),""):`${r}: ${s}`:(ws(`style:${r}`,`"${r}" is not an allowed tooltip content style property and was dropped.`),"")}).filter(Boolean).join("; "),j7=e=>e.split(/\s+/).filter(t=>t?U7.test(t)?!0:(ws(`class:${t}`,`"${t}" is not a valid class token for tooltip content and was dropped.`),!1):!1).join(" "),K7=(e,t)=>e==="style"?W7(t):e==="class"?j7(t):t,q7=new Set(["b","strong","em","i","u","s","small","code","kbd","br","p"]),G7={"<":"<",">":">",'"':""","'":"'"},vf=e=>e.replace(/&(?!(?:[a-zA-Z][a-zA-Z0-9]{1,10}|#\d{1,7}|#[xX][0-9a-fA-F]{1,6});)/g,"&").replace(/[<>"']/g,t=>G7[t]),Km=e=>e.split(/(<[^<>]*>)/g).map(t=>{var i;if(t.startsWith("<")&&t.endsWith(">")){let r=/^<\s*(\/?)\s*([a-zA-Z][a-zA-Z0-9]*)\s*\/?\s*>$/.exec(t),s=(i=r==null?void 0:r[2])==null?void 0:i.toLowerCase();return s&&q7.has(s)?`<${r[1]}${s}>`:(s&&ws(`string-tag:${s}`,`<${s}> is not allowed in a tooltip string and was shown as text. Use the structured content form for anything richer.`),vf(t))}return vf(t).replace(/\n/g,"<br>")}).join(""),bf=new Set,ws=(e,t)=>{typeof process<"u"||bf.has(e)||(bf.add(e),console.warn(`[nb-tooltip] ${t}`))},cu=e=>{if(Array.isArray(e))return e.map(u=>cu(u)).join("");if(!e||typeof e!="object"||!e.component)return"";let{component:t,props:i={},children:r,content:s}=e,n=r===void 0?s:r,a=Array.isArray(n)?cu(n):n===void 0?"":Km(String(n)),o=String(t).toLowerCase();if(!mf.has(o))return ws(`tag:${o}`,`<${o}> is not allowed in tooltip content and was dropped. Allowed tags: ${[...mf].join(", ")}.`),a;let l=Object.entries(i).filter(([u])=>gf.has(u)?!0:(ws(`prop:${u}`,`"${u}" is not an allowed tooltip content prop and was dropped. Allowed props: ${[...gf].join(", ")}.`),!1)).map(([u,h])=>[u,K7(u,String(h))]).filter(([,u])=>u!=="").map(([u,h])=>`${u}="${Z7(h)}"`).join(" "),c=`<${o}${l?` ${l}`:""}>`;return B7.has(o)?c:`${c}${a}</${o}>`},a0=e=>e?typeof e=="string"?Km(e):Array.isArray(e)?cu(e):"":"",Y7=vc({default:()=>Sw,dismissAllTooltips:()=>Ew}),sd=e=>e.status??e.flavor??"default",nd=e=>e.chipClass??e.classExtra,wr=new Set,X7=0,J7=()=>`nb-tooltip-${++X7}`,Q7=900,qm=4e3,ew=500,Gm=0,uu=(e,t)=>{if(!e)return!1;let i=Date.now()-e;return i>=0&&i<t},yf=!1,tw=()=>{if(yf||typeof document>"u")return;yf=!0;let e=t=>{if(wr.size===0)return;let i=t==null?void 0:t.target;i instanceof Element&&i.closest(".nb-tooltip")||Lw("dismiss")};document.addEventListener("pointerdown",()=>{Gm=Date.now()},!0),document.addEventListener("dragstart",()=>e(),!0),document.addEventListener("keydown",t=>{t.key==="Escape"&&e()},!0),document.addEventListener("pointerdown",e,!0),window.addEventListener("blur",e),document.addEventListener("mouseleave",e)},wf=200,Sf=1e3,iw=2,rw=e=>{let t=e.tooltipElement;if(!t)return!1;if(t.__hovered__)return!0;try{return t.isConnected&&t.matches(":hover")}catch{return!1}},sw=e=>{if(!e.isConnected)return!1;if(rw(e)||e.__trigger__==="focus"&&e.contains(document.activeElement)||e.__trigger__==="touch"&&uu(e.__lastTouchAt__,qm))return!0;try{return e.matches(":hover")}catch{return!0}},hu=e=>{clearTimeout(e.__watchdogTimer__),e.__watchdogTimer__=void 0,e.__watchdogMisses__=0},nw=e=>{hu(e);let t=()=>{var i;if(!((i=e.__chips__)!=null&&i.size)){hu(e);return}if(sw(e))e.__watchdogMisses__=0;else{if(e.__watchdogMisses__=(e.__watchdogMisses__??0)+1,!e.isConnected){Sn(e,!0,"program");return}if(e.__watchdogMisses__>=iw){ld(e,"dismiss");return}}e.__watchdogTimer__=setTimeout(t,Sf)};e.__watchdogTimer__=setTimeout(t,Sf)},Sr=new Set,_s=null,Ym=e=>`${Math.round(e.top)}:${Math.round(e.left)}:${Math.round(e.width)}:${Math.round(e.height)}`,aw=e=>{if(typeof getComputedStyle!="function")return!1;let t;try{t=getComputedStyle(e)}catch{return!1}let i=`${t.overflow} ${t.overflowX} ${t.overflowY}`;return/hidden|scroll|auto|clip|overlay/.test(i)},ow=e=>{let t=[],i=e.parentElement;for(;i&&i!==document.body&&i!==document.documentElement;)aw(i)&&t.push(i),i=i.parentElement;return t},du=e=>!(e.width===0&&e.height===0&&e.top===0&&e.left===0),lw=(e,t)=>{if(!e.isConnected)return!1;if(!du(t))return!0;if(t.width===0||t.height===0||!(t.bottom>0&&t.right>0&&t.top<window.innerHeight&&t.left<window.innerWidth))return!1;for(let i of e.__clippers__??[]){if(!i.isConnected)continue;let r=i.getBoundingClientRect();if(du(r)&&(t.bottom<=r.top||t.top>=r.bottom||t.right<=r.left||t.left>=r.right))return!1}return!0},Xm=e=>{var r;let t=e.tooltipElement;if(!t||!((r=e.__chips__)!=null&&r.size)){Sr.delete(e);return}let i=e.getBoundingClientRect();if(!lw(e,i)){e.__offscreenReported__||(e.__offscreenReported__=!0,ld(e,"dismiss"));return}e.__offscreenReported__=!1,e.__lastRect__=Ym(i),e.__side__!=="cursor"&&wl(e,t,e.__requestedSide__??e.__side__)},x0=()=>{Qm();for(let e of Array.from(Sr))Xm(e)},cw=100,uw=320,Cf=0,Jm=0,Qm=()=>{Jm=Date.now()+uw},fu=()=>{if(Sr.size===0){_s=null;return}let e=Date.now();if(e>=Jm&&e-Cf<cw){_s=requestAnimationFrame(fu);return}Cf=e;for(let t of Array.from(Sr)){if(!t.tooltipElement){Sr.delete(t);continue}Ym(t.getBoundingClientRect())!==t.__lastRect__&&(Qm(),Xm(t))}_s=requestAnimationFrame(fu)},T0=!1,hw=e=>{Sr.add(e),e.__lastRect__=void 0,e.__clippers__=ow(e),!(typeof window>"u")&&(T0||(T0=!0,document.addEventListener("scroll",x0,{capture:!0,passive:!0}),window.addEventListener("resize",x0,{passive:!0})),_s===null&&typeof requestAnimationFrame=="function"&&(_s=requestAnimationFrame(fu)))},ad=e=>{Sr.delete(e),e.__lastRect__=void 0,e.__clippers__=void 0,!(Sr.size>0||typeof window>"u")&&(T0&&(T0=!1,document.removeEventListener("scroll",x0,{capture:!0}),window.removeEventListener("resize",x0)),_s!==null&&typeof cancelAnimationFrame=="function"&&(cancelAnimationFrame(_s),_s=null))},dw=(e,t,i)=>{var r;if((r=e.__chips__)==null||r.delete(t),clearTimeout(t.__removeTimer__),t.__removeTimer__=void 0,i||rd()){t.remove();return}t.style.animation=`tooltipDisappear ${wf}ms ease-in-out forwards`,t.__removeTimer__=setTimeout(()=>{t.__removeTimer__=void 0,t.remove()},wf)},e4=(e,t)=>{if(ad(e),e.__trigger__=void 0,e.__side__=void 0,e.__chips__)for(let i of Array.from(e.__chips__))dw(e,i,t);e.tooltipElement=void 0,e.__lastContent__=void 0,hu(e)},t4="a[href], button, input, select, textarea, summary, [tabindex]",pu="data-nb-tooltip-anchor",kf=(e,t)=>{let i=t.target;if(!(i instanceof Element)||i===e)return!0;let r=i.closest(`[${pu}]`);return r===null||r===e},Vo=e=>{if(!e)return"";if(typeof e=="string")return e.replace(/<[^>]*>/g," ").replace(/ /g," ").replace(/&/g,"&").replace(/</g,"<").replace(/>/g,">").replace(/"/g,'"').replace(/'/g,"'").replace(/\s+/g," ").trim();if(Array.isArray(e))return e.map(t=>Vo(t)).filter(Boolean).join(" ");if(typeof e=="object"){let t=e;return Vo(t.children??t.content)}return""},i4=e=>[Vo(e.header),Vo(e.body),Vo(e.tip)].filter(Boolean).join(". "),fw=e=>{if(e.hasAttribute("aria-labelledby")||e.hasAttribute("aria-label")&&!e.__ownsAriaLabel__||e.hasAttribute("title")||(e.textContent??"").trim().length>0)return!0;let t=e.querySelector("img[alt]");return!!t&&(t.getAttribute("alt")??"").trim().length>0},r4=(e,t)=>{let i=t.aria??"auto";return i==="auto"?fw(e)?"description":"label":i},pw=(e,t)=>{if(!t||r4(e,t)!=="label"){e.__ownsAriaLabel__&&(e.__ownsAriaLabel__=(e.removeAttribute("aria-label"),!1)),e.__ownsRole__&&(e.__ownsRole__=(e.removeAttribute("role"),!1));return}let i=i4(t);i&&(e.setAttribute("aria-label",i),e.__ownsAriaLabel__=!0,!e.__ownsRole__&&!e.hasAttribute("role")&&!e.matches(t4)&&(e.setAttribute("role","img"),e.__ownsRole__=!0))},n1=(e,t)=>{let i=!!(t!=null&&t.focusable);if(i&&!e.__ownsTabIndex__){if(e.matches(t4)||e.hasAttribute("tabindex"))return;e.setAttribute("tabindex","0"),e.__ownsTabIndex__=!0;return}!i&&e.__ownsTabIndex__&&(e.removeAttribute("tabindex"),e.__ownsTabIndex__=!1)},_w=(e,t)=>{e.__prevDescribedBy__=e.getAttribute("aria-describedby");let i=[e.__prevDescribedBy__,t].filter(Boolean).join(" ");e.setAttribute("aria-describedby",i)},mw=e=>{e.__prevDescribedBy__!==void 0&&(e.__prevDescribedBy__?e.setAttribute("aria-describedby",e.__prevDescribedBy__):e.removeAttribute("aria-describedby"),e.__prevDescribedBy__=void 0)},gw="nb-tooltip-description",s4=e=>!!e&&!!(e.body||e.header||e.tip),vw=(e,t)=>{if(typeof document>"u")return;let i=t&&s4(t)&&r4(e,t)==="description"?i4(t):"";if(!i){n4(e);return}let r=e.__descNode__;r||(r=document.createElement("span"),r.className=gw,r.id=J7(),r.setAttribute("role","tooltip"),document.body.appendChild(r),e.__descNode__=r,_w(e,r.id)),e.__descText__!==i&&(r.textContent=i,e.__descText__=i)},n4=e=>{e.__descNode__&&(mw(e),e.__descNode__.remove(),e.__descNode__=void 0,e.__descText__=void 0)},bw=(e,t)=>{if(s4(t)){e.__prevTitle__===void 0&&e.hasAttribute("title")&&(e.__prevTitle__=e.getAttribute("title")??"",e.removeAttribute("title"));return}a4(e)},a4=e=>{e.__prevTitle__!==void 0&&(e.hasAttribute("title")||e.setAttribute("title",e.__prevTitle__),e.__prevTitle__=void 0)},a1=(e,t)=>{bw(e,t),pw(e,t),vw(e,t)},yw=e=>{var t,i;return e.disabled===!0?!0:!!((t=e.closest)!=null&&t.call(e,"fieldset[disabled]"))&&!((i=e.closest)!=null&&i.call(e,"fieldset[disabled] > legend:first-of-type"))},ww=(e,t,i)=>t>=e.left&&t<=e.right&&i>=e.top&&i<=e.bottom,o4=e=>{let t=e.__proxyHost__;t&&(e.__proxyMove__&&t.removeEventListener("mousemove",e.__proxyMove__),e.__proxyLeave__&&t.removeEventListener("mouseleave",e.__proxyLeave__),e.__proxyHost__=void 0,e.__proxyMove__=void 0,e.__proxyLeave__=void 0,e.__proxyInside__=!1)},Af=e=>{let t=e.__tooltipBinding__&&yw(e)?e.parentElement:null;e.__proxyHost__!==t&&(o4(e),t&&(e.__proxyMove__=i=>{var n,a,o;let r=i;if(r.buttons)return;let s=e.getBoundingClientRect();if(du(s)?ww(s,r.clientX,r.clientY):i.target===e||e.contains(i.target)){e.__mouseX__=r.clientX,e.__mouseY__=r.clientY,e.__proxyInside__?(n=e.__tooltipBinding__)!=null&&n.followCursor&&wl(e,e.tooltipElement,e.__requestedSide__):(e.__proxyInside__=!0,(a=e.__showTooltip__)==null||a.call(e,"pointer"));return}e.__proxyInside__&&(e.__proxyInside__=!1,(o=e.__hideTooltip__)==null||o.call(e,void 0,"pointer"))},e.__proxyLeave__=()=>{var i;e.__proxyInside__&&(e.__proxyInside__=!1,(i=e.__hideTooltip__)==null||i.call(e,void 0,"pointer"))},t.addEventListener("mousemove",e.__proxyMove__),t.addEventListener("mouseleave",e.__proxyLeave__),e.__proxyHost__=t))},Mf=e=>{e.onOpenChange||ws("controlled-no-handler","a tooltip was given `open` but no `onOpenChange`, so nothing the user does (hover, blur, Escape) can change it. Either handle `onOpenChange` or drop `open` and let the directive own visibility.")},Lf=(e,t)=>{var r,s;if(!t)return;let i=t.open===void 0?e.__openState__===void 0&&t.defaultOpen?!0:void 0:t.open;i!==void 0&&i!==(e.__openState__===!0||!!e.__showTimer__)&&(i?(r=e.__showTooltip__)==null||r.call(e,"program"):(s=e.__hideTooltip__)==null||s.call(e,0,"program"))},Sw=e=>{tw();let t=e.config.globalProperties.$router;t&&t.beforeEach(()=>{wr.forEach(i=>{var r;return(r=i==null?void 0:i.__hideTooltip__)==null?void 0:r.call(i,0,"program")}),wr.clear()}),e.directive("nb-tooltip",{mounted(i,r){i.__showTooltip__=(s="pointer")=>{var a;let n=i.__tooltipBinding__;if(n){if(n.open!==void 0&&s!=="program"){Mf(n),(a=n.onOpenChange)==null||a.call(n,!0,s);return}clearTimeout(i.__hideTimer__),i.__hideTimer__=void 0,Cw(i,n,s)}},i.__hideTooltip__=(s=(a=>(a=i.__tooltipBinding__)==null?void 0:a.hideDelay)()??150,n="dismiss")=>{var l;let o=i.__tooltipBinding__;if((o==null?void 0:o.open)!==void 0&&n!=="program"){Mf(o),(l=o.onOpenChange)==null||l.call(o,!1,n);return}if(clearTimeout(i.__hideTimer__),s<=0){i.__hideTimer__=void 0,Sn(i,!0,n);return}i.__hideTimer__=setTimeout(()=>{i.__hideTimer__=void 0,Sn(i,s<=0,n)},s)},i.__mouseMove__=s=>{var n,a;i.__mouseX__=s.clientX,i.__mouseY__=s.clientY,(n=i.__tooltipBinding__)!=null&&n.followCursor&&wl(i,i.tooltipElement,(a=i.__tooltipBinding__)==null?void 0:a.position)},i.__tooltipBinding__=r.value,i.__showHandler__=s=>{var a;if(uu(i.__lastTouchAt__,Q7))return;let n=s;n.buttons||(typeof n.clientX=="number"&&(n.clientX||n.clientY)&&(i.__mouseX__=n.clientX,i.__mouseY__=n.clientY),(a=i.__showTooltip__)==null||a.call(i,"pointer"))},i.__hideHandler__=()=>{var s;return(s=i.__hideTooltip__)==null?void 0:s.call(i,void 0,"pointer")},i.__focusHandler__=s=>{var n;uu(Gm,ew)||kf(i,s)&&((n=i.__showTooltip__)==null||n.call(i,"focus"))},i.__blurHandler__=()=>{var s;return(s=i.__hideTooltip__)==null?void 0:s.call(i,void 0,"focus")},i.__touchHandler__=s=>{var n,a,o;((n=i.__tooltipBinding__)==null?void 0:n.touch)!==!1&&kf(i,s)&&(i.__lastTouchAt__=Date.now(),(a=i.__showTooltip__)==null||a.call(i,"touch"),(o=i.__hideTooltip__)==null||o.call(i,qm,"touch"))},n1(i,r.value),a1(i,r.value),i.setAttribute(pu,""),i.addEventListener("mouseenter",i.__showHandler__),i.addEventListener("mouseleave",i.__hideHandler__),i.addEventListener("mousemove",i.__mouseMove__),i.addEventListener("focusin",i.__focusHandler__),i.addEventListener("focusout",i.__blurHandler__),i.addEventListener("touchstart",i.__touchHandler__,{passive:!0}),Af(i),Lf(i,r.value)},updated(i,r){let s=i.__tooltipBinding__;if(i.__tooltipBinding__=r.value,!r.value){a1(i,void 0),n1(i,void 0),Sn(i,!0);return}if(s!==r.value&&(a1(i,r.value),n1(i,r.value)),Af(i),Lf(i,r.value),!i.tooltipElement||s===r.value)return;let n=c4(r.value);n!==i.__lastContent__&&(i.__lastContent__=n,kw(i,r.value))},unmounted(i){clearTimeout(i.__showTimer__),i.__showTimer__=void 0,clearTimeout(i.__hideTimer__),i.__hideTimer__=void 0,Sn(i,!0),wr.delete(i),i.__showHandler__&&i.removeEventListener("mouseenter",i.__showHandler__),i.__hideHandler__&&i.removeEventListener("mouseleave",i.__hideHandler__),i.__focusHandler__&&i.removeEventListener("focusin",i.__focusHandler__),i.__blurHandler__&&i.removeEventListener("focusout",i.__blurHandler__),i.__touchHandler__&&i.removeEventListener("touchstart",i.__touchHandler__),n4(i),a4(i),i.__ownsAriaLabel__&&(i.__ownsAriaLabel__=(i.removeAttribute("aria-label"),!1)),i.__ownsTabIndex__&&(i.__ownsTabIndex__=(i.removeAttribute("tabindex"),!1)),i.__ownsRole__&&(i.__ownsRole__=(i.removeAttribute("role"),!1)),i.removeAttribute(pu),o4(i),i.__mouseMove__&&i.removeEventListener("mousemove",i.__mouseMove__),ad(i)}})},od=({header:e="",body:t="",tip:i=""})=>`<div class="nb-tooltip-content"><div class="nb-tooltip-header">${a0(e)}</div><div class="nb-tooltip-body">${a0(t)}</div><div class="nb-tooltip-tip">${a0(i)}</div></div>`,l4=(e,t,i)=>["nb-tooltip",`nb-tooltip-${e}`,t?`nb-tooltip-flavor-${t}`:"",i||""].filter(Boolean).join(" "),c4=e=>`${e.position??""}|${sd(e)}|${nd(e)??""}|${od(e)}`,Cw=(e,t,i="pointer")=>{let{header:r,body:s,tip:n,delay:a=400,animationTime:o=300,position:l,overflowOnly:c}=t,u=sd(t),h=nd(t);if(clearTimeout(e.__showTimer__),e.__showTimer__=void 0,e4(e,!0),c){let m=e.getBoundingClientRect();if(!(Math.round(m.width)<Math.round(e.scrollWidth)))return}if(!(s||r||n))return;let d=i==="pointer"?a:0,f=rd();e.__showTimer__=setTimeout(()=>{var p;if(e.__showTimer__=void 0,!e.isConnected)return;let m=i==="pointer"?l??"cursor":l&&l!=="cursor"?l:"top";for(let C of Array.from(Sr))C!==e&&ld(C,"superseded");let _=document.createElement("span");_.className=l4(m,u,h),_.innerHTML=od({header:r,body:s,tip:n}),_.addEventListener("mouseenter",()=>{_.__hovered__=!0,clearTimeout(e.__hideTimer__),e.__hideTimer__=void 0,e.__watchdogMisses__=0}),_.addEventListener("mouseleave",()=>{var C;_.__hovered__=!1,(C=e.__hideTooltip__)==null||C.call(e)}),f?_.style.opacity="1":(_.style.transition=`opacity ${o}ms ease-in-out`,_.style.animation=`tooltipAppear ${o}ms ease-in-out forwards`),_.setAttribute("aria-hidden","true"),e.__trigger__=i,e.tooltipElement=_,(e.__chips__??(e.__chips__=new Set)).add(_),e.__lastContent__=c4(t),wr.add(e),document.body.appendChild(_),e.__requestedSide__=m,e.__side__=m,wl(e,_,m),hw(e),nw(e);let y=e.__openState__===!0;e.__openState__=!0,y||((p=t.onOpenChange)==null||p.call(t,!0,i))},d)},ld=(e,t,i=!0)=>{if(e.__hideTooltip__){e.__hideTooltip__(i?0:void 0,t);return}Sn(e,i,t)},Sn=(e,t=!1,i="dismiss")=>{var s,n;clearTimeout(e.__showTimer__),e.__showTimer__=void 0;let r=e.__openState__===!0;e4(e,t),wr.delete(e),e.__requestedSide__=void 0,r&&(e.__openState__=!1,(n=(s=e.__tooltipBinding__)==null?void 0:s.onOpenChange)==null||n.call(s,!1,i))},kw=(e,t)=>{let{header:i,body:r,tip:s,position:n}=t,a=sd(t),o=nd(t),l=e.__requestedSide__??e.__side__??n,c=e.tooltipElement;c&&(c.innerHTML=od({header:i,body:r,tip:s}),c.className=l4(e.__side__??l??"cursor",a,o),wl(e,c,l))};function Aw(e,t,i,r,s,n,a){switch(e){case"top":return{top:t.top-(r+s*2),left:t.left+t.width/2-(i/2+s/2)};case"bottom":return{top:t.bottom+s,left:t.left+t.width/2-(i/2+s/2)};case"left":return{top:t.top+t.height/2-r/2,left:t.left-(i+s*2)};case"right":return{top:t.top+t.height/2-r/2,left:t.right+s};default:return{top:a+Ef,left:n+Ef}}}var Ef=14;function $f(e,t,i,r,s){return t>=s&&e>=s&&t+i<=window.innerWidth-s&&e+r<=window.innerHeight-s}var Mw={top:["bottom","right","left"],bottom:["top","right","left"],left:["right","top","bottom"],right:["left","top","bottom"],cursor:[]},wl=(e,t,i)=>{if(!t)return;let r=e.getBoundingClientRect(),s=t.getBoundingClientRect(),n=s.width||0,a=s.height||0,o=e.__mouseX__??0,l=e.__mouseY__??0,c=i??"cursor",u=_=>Aw(_,r,n,a,4,o,l),h=u(c),d=c;if(n>0&&a>0&&!$f(h.top,h.left,n,a,16))for(let _ of Mw[c]){let y=u(_);if($f(y.top,y.left,n,a,16)){h=y,d=_;break}}let{top:f,left:m}=h;if(n>0&&a>0){let _=window.innerWidth-n-16,y=window.innerHeight-a-16;m>_&&(m=_),m<16&&(m=16),f>y&&(f=y),f<16&&(f=16)}if(d!=="cursor"){for(let _ of["top","bottom","left","right"])t.classList.remove(`nb-tooltip-${_}`);t.classList.add(`nb-tooltip-${d}`)}if(e.__side__=d,n>0&&a>0&&d!=="cursor"){let _=r.left+r.width/2,y=r.top+r.height/2;if(d==="top"||d==="bottom"){let p=Math.max(8,Math.min(n-8,_-m))/n*100;t.style.setProperty("--nb-tooltip-arrow-offset",`${p}%`)}else{let p=Math.max(8,Math.min(a-8,y-f))/a*100;t.style.setProperty("--nb-tooltip-arrow-offset",`${p}%`)}}t.style.top=`${f}px`,t.style.left=`${m}px`};function Lw(e){var i;for(let r of Array.from(wr))(i=r.__hideTooltip__)==null||i.call(r,0,e);let t=new Set;for(let r of Array.from(wr))for(let s of r.__chips__??[])t.add(s);document.querySelectorAll("span.nb-tooltip").forEach(r=>{t.has(r)||r.remove()})}function Ew(){var e;for(let t of Array.from(wr))(e=t.__hideTooltip__)==null||e.call(t,0,"program");wr.clear();for(let t of Array.from(Sr))ad(t);document.querySelectorAll("span.nb-tooltip").forEach(t=>t.remove())}var $w=vc({default:()=>xw});function xf(e,t){let i=t.value;if(i==null||i===""){e.removeAttribute(lu);return}e.setAttribute(lu,String(i))}var xw=e=>{e.directive("nb-tour-step",{mounted:xf,updated:xf,unmounted(t){t.removeAttribute(lu)}})},Tw=Object.assign({"./ContextMenu.directive.ts":R7,"./ToolTip.content.ts":V7,"./ToolTip.directive.ts":Y7,"./TourStep.directive.ts":$w}),Nw={install(e){Object.values(Tw).forEach(t=>{typeof t.default=="function"&&t.default(e)})}},Hw={install(e){let t=I7();e.provide(O7,t)}},Pw={install(e,t={}){if(t.components)for(let[i,r]of Object.entries(t.components))e.component(i,r);e.use(Nw),e.use(Hw)}},u4=new Map;function Ow(e){if(typeof e=="object"&&e&&!("render"in e)&&!("setup"in e)&&!("template"in e)){let t=e;if("thin"in t||"light"in t||"regular"in t||"bold"in t||"fill"in t||"duotone"in t)return t}return{regular:e}}function Iw(e){for(let[t,i]of Object.entries(e))u4.set(t,Ow(i))}function Rw(e,t="regular"){let i=u4.get(e);if(i){if(i[t])return i[t];if(i.regular)return i.regular;for(let r of["bold","fill","duotone","light","thin"])if(i[r])return i[r]}}var Dw=e=>Symbol.for(`@nubisco/ui:${e}-catalog`);function Vw(e){return globalThis[Dw(e)]}var Tf=new Map;function Bw(e,t,i="regular"){let r=Vw(e);if(!r){let l="Icon",c=`${e}s`;throw Error(`[@nubisco/ui] <Nb${l}> was given the runtime-resolved name "${t}", but the ${e} catalogue is not loaded. The name may also have been forwarded from another component's \`${e}\` prop. Three ways out, cheapest first: pass a literal name so the bundler plugin links just that ${e}; register the set the value can actually take with register${l}s() and pay for only those; or, if the value is genuinely open-ended (a picker, a CMS field), import '@nubisco/ui/${c}/all' in the file that needs the whole set.`)}let s=r[t];if(!s)return;let n=`${e}:${t}:${i}`,a=Tf.get(n);if(a)return a;let o=J5(async()=>{let l=await s();return l[i]??l.regular??l.default});return Tf.set(n,o),o}function Zw(e,t="regular"){let i=e;return i&&typeof i=="object"&&("regular"in i||t in i)?i[t]??i.regular??i.default:e}function Fw(e){var i;if(!e)return;let t=e;if(typeof t.glyphName=="string")return t.glyphName;if(typeof((i=t.regular)==null?void 0:i.glyphName)=="string")return t.regular.glyphName}var h4=function(e){return e.ExtraExtraSmall="xxs",e.ExtraSmall="xs",e.Small="sm",e.Medium="md",e.Large="lg",e.ExtraLarge="xl",e.ExtraExtraLarge="xxl",e}({}),d4=function(e){return e.Small="sm",e.Medium="md",e.Large="lg",e}({});function Nf(e){return e.replace(new RegExp("(?<=[A-Z0-9])([A-Z])(?=[a-z])","g")," $1").replace(/_/g," ").replace(/([a-z])([A-Z])/g,"$1-$2").replace(/\s+/g,"-").toLowerCase()}function cd(e){var i,r;if(e.id)return e.id;let t=Nf(((r=(i=ki())==null?void 0:i.type)==null?void 0:r.__name)??"component");return typeof e.name=="string"&&e.name?`${t}-${Nf(e.name)}`:`${t}-${qi()}`}var f4=function(e){return e.Hover="hover",e.Always="always",e}(f4||{}),p4=function(e){return e.Thin="thin",e.Light="light",e.Regular="regular",e.Bold="bold",e.Fill="fill",e.Duotone="duotone",e}(p4||{}),_u=function(e){return e[e.XXL=92]="XXL",e[e.XL=60]="XL",e[e.LG=20]="LG",e[e.MD=16]="MD",e[e.SM=14]="SM",e[e.XS=12]="XS",e[e.XXS=8]="XXS",e}(_u||{}),zw=["title"],Ge=ht(Re({__name:"Icon",props:{name:{default:void 0},icon:{default:void 0},size:{default:h4.Medium},animation:{default:null},animationMode:{default:f4.Always},color:{default:void 0},weight:{default:p4.Regular},title:{default:void 0},clickable:{type:Boolean,default:!1},hoverable:{type:Boolean,default:!1}},emits:["click"],setup(e,{emit:t}){let i=e,r=t,s=Q(()=>i.icon??i.name),n=Q(()=>typeof s.value=="string"?s.value:Fw(s.value)),a=Q(()=>typeof s.value=="string"?void 0:s.value),o=cd({name:n.value}),l=Q(()=>{let d=typeof i.size=="number"?i.size:_u[String(i.size).toUpperCase()]||_u.MD;return{id:o,...i.size&&{width:`${d}px`,height:`${d}px`},...i.clickable&&{role:"button"}}}),c=Q(()=>{let d=a.value;if(d)return Zw(d,i.weight);let f=typeof s.value=="string"?s.value:void 0;return f?Rw(f,i.weight)||Bw("icon",f,i.weight):void 0}),u=Q(()=>({"nb-icon":!0,...n.value&&{[n.value]:!0},[`nb-icon-${i.size}`]:["xxs","xs","sm","md","lg","xl","xxl"].includes(String(i.size)),[`nb-icon-animation-${i.animationMode}-${i.animation}`]:i.animation,hoverable:i.hoverable||i.animation&&i.animationMode==="hover","box-clickable":i.clickable})),h=Q(()=>({...i.color&&{color:i.color},...typeof i.size=="number"&&{maxWidth:`${i.size}px`,maxHeight:`${i.size}px`,height:`${i.size}px`,width:`${i.size}px`},...typeof i.size=="string"&&!["xxs","xs","sm","md","lg","xl","xxl"].includes(i.size)&&{maxWidth:i.size,maxHeight:i.size,height:i.size,width:i.size}}));return(d,f)=>(g(),E("i",Jt({class:u.value,style:h.value},l.value,{title:e.title,onClick:f[0]||(f[0]=m=>e.clickable?r("click",m):void 0)}),[c.value?(g(),de(uc(c.value),{key:0,"aria-hidden":"true"})):F("",!0)],16,zw))}}),[["__scopeId","data-v-034072e6"]]);const Uw=(e,t,i)=>{const r=s=>Me("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:t,fill:"currentColor",...s,innerHTML:i});return r.displayName="NbGlyph",r.glyphName=e,r},Hf=Uw("caret-down","0 0 256 256",'<path d="M213.66,101.66l-80,80a8,8,0,0,1-11.32,0l-80-80A8,8,0,0,1,53.66,90.34L128,164.69l74.34-74.35a8,8,0,0,1,11.32,11.32Z"/>'),Gn=(e,t,i)=>{const r=s=>Me("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:t,fill:"currentColor",...s,innerHTML:i});return r.displayName="NbGlyph",r.glyphName=e,r},Ww=Gn("magnifying-glass","0 0 256 256",'<path d="M226.83,221.17l-52.7-52.7a84.1,84.1,0,1,0-5.66,5.66l52.7,52.7a4,4,0,0,0,5.66-5.66ZM36,112a76,76,0,1,1,76,76A76.08,76.08,0,0,1,36,112Z"/>'),jw=Gn("magnifying-glass","0 0 256 256",'<path d="M228.24,219.76l-51.38-51.38a86.15,86.15,0,1,0-8.48,8.48l51.38,51.38a6,6,0,0,0,8.48-8.48ZM38,112a74,74,0,1,1,74,74A74.09,74.09,0,0,1,38,112Z"/>'),Pf=Gn("magnifying-glass","0 0 256 256",'<path d="M229.66,218.34l-50.07-50.06a88.11,88.11,0,1,0-11.31,11.31l50.06,50.07a8,8,0,0,0,11.32-11.32ZM40,112a72,72,0,1,1,72,72A72.08,72.08,0,0,1,40,112Z"/>'),Kw=Gn("magnifying-glass","0 0 256 256",'<path d="M232.49,215.51,185,168a92.12,92.12,0,1,0-17,17l47.53,47.54a12,12,0,0,0,17-17ZM44,112a68,68,0,1,1,68,68A68.07,68.07,0,0,1,44,112Z"/>'),qw=Gn("magnifying-glass","0 0 256 256",'<path d="M168,112a56,56,0,1,1-56-56A56,56,0,0,1,168,112Zm61.66,117.66a8,8,0,0,1-11.32,0l-50.06-50.07a88,88,0,1,1,11.32-11.31l50.06,50.06A8,8,0,0,1,229.66,229.66ZM112,184a72,72,0,1,0-72-72A72.08,72.08,0,0,0,112,184Z"/>'),Gw=Gn("magnifying-glass","0 0 256 256",'<path d="M192,112a80,80,0,1,1-80-80A80,80,0,0,1,192,112Z" opacity="0.2"/><path d="M229.66,218.34,179.6,168.28a88.21,88.21,0,1,0-11.32,11.31l50.06,50.07a8,8,0,0,0,11.32-11.32ZM40,112a72,72,0,1,1,72,72A72.08,72.08,0,0,1,40,112Z"/>'),Yw="magnifying-glass",Of=Object.freeze(Object.defineProperty({__proto__:null,bold:Kw,default:Pf,duotone:Gw,fill:qw,glyphName:Yw,light:jw,regular:Pf,thin:Ww},Symbol.toStringTag,{value:"Module"})),Yn=(e,t,i)=>{const r=s=>Me("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:t,fill:"currentColor",...s,innerHTML:i});return r.displayName="NbGlyph",r.glyphName=e,r},Xw=Yn("warning-circle","0 0 256 256",'<path d="M128,28A100,100,0,1,0,228,128,100.11,100.11,0,0,0,128,28Zm0,192a92,92,0,1,1,92-92A92.1,92.1,0,0,1,128,220Zm-4-84V80a4,4,0,0,1,8,0v56a4,4,0,0,1-8,0Zm12,36a8,8,0,1,1-8-8A8,8,0,0,1,136,172Z"/>'),Jw=Yn("warning-circle","0 0 256 256",'<path d="M128,26A102,102,0,1,0,230,128,102.12,102.12,0,0,0,128,26Zm0,192a90,90,0,1,1,90-90A90.1,90.1,0,0,1,128,218Zm-6-82V80a6,6,0,0,1,12,0v56a6,6,0,0,1-12,0Zm16,36a10,10,0,1,1-10-10A10,10,0,0,1,138,172Z"/>'),If=Yn("warning-circle","0 0 256 256",'<path d="M128,24A104,104,0,1,0,232,128,104.11,104.11,0,0,0,128,24Zm0,192a88,88,0,1,1,88-88A88.1,88.1,0,0,1,128,216Zm-8-80V80a8,8,0,0,1,16,0v56a8,8,0,0,1-16,0Zm20,36a12,12,0,1,1-12-12A12,12,0,0,1,140,172Z"/>'),Qw=Yn("warning-circle","0 0 256 256",'<path d="M128,20A108,108,0,1,0,236,128,108.12,108.12,0,0,0,128,20Zm0,192a84,84,0,1,1,84-84A84.09,84.09,0,0,1,128,212Zm-12-80V80a12,12,0,0,1,24,0v52a12,12,0,0,1-24,0Zm28,40a16,16,0,1,1-16-16A16,16,0,0,1,144,172Z"/>'),eS=Yn("warning-circle","0 0 256 256",'<path d="M128,24A104,104,0,1,0,232,128,104.11,104.11,0,0,0,128,24Zm-8,56a8,8,0,0,1,16,0v56a8,8,0,0,1-16,0Zm8,104a12,12,0,1,1,12-12A12,12,0,0,1,128,184Z"/>'),tS=Yn("warning-circle","0 0 256 256",'<path d="M224,128a96,96,0,1,1-96-96A96,96,0,0,1,224,128Z" opacity="0.2"/><path d="M128,24A104,104,0,1,0,232,128,104.11,104.11,0,0,0,128,24Zm0,192a88,88,0,1,1,88-88A88.1,88.1,0,0,1,128,216Zm-8-80V80a8,8,0,0,1,16,0v56a8,8,0,0,1-16,0Zm20,36a12,12,0,1,1-12-12A12,12,0,0,1,140,172Z"/>'),iS="warning-circle",_4=Object.freeze(Object.defineProperty({__proto__:null,bold:Qw,default:If,duotone:tS,fill:eS,glyphName:iS,light:Jw,regular:If,thin:Xw},Symbol.toStringTag,{value:"Module"}));var m4="data-nb-layer",mu=Symbol("nb-layer");function N0(e){if(!Number.isFinite(e))return 0;let t=Math.round(e);return t<0?0:t>3?3:t}function gu(e){return`nb-layer-${e}`}function rS(e){let t=null,i=s=>{let n=/^nb-layer-([0-3])$/.exec(s.trim());if(!n)return;let a=Number(n[1]);(t===null||a>t)&&(t=a)},r=s=>{if(typeof s=="string"){for(let n of s.split(/\s+/))i(n);return}if(Array.isArray(s)){for(let n of s)r(n);return}if(s&&typeof s=="object")for(let[n,a]of Object.entries(s))a&&i(n)};return r(e),t}function sS(e){let t=(e==null?void 0:e.parentElement)??null;for(;t;){let i=t.getAttribute(m4);if(i!==null){let s=Number(i);if(Number.isFinite(s))return{level:N0(s+1),source:"surface"}}let r=t.classList;if(r){for(let s=3;s>=0;s--)if(r.contains(gu(s)))return{level:s,source:"class"}}t=t.parentElement}return null}function nS(e){if(!e)return null;if(e instanceof Element)return e;let t=e.$el;return t instanceof Element?t:null}function In(e={}){let t=ki(),i=ai(mu,null),r=e.el??X(null),s=X(null),n=e.probe??!e.overlay,a=Q(()=>{var c;let l=A5(e.level);return l===void 0?rS((c=t==null?void 0:t.attrs)==null?void 0:c.class):N0(l)}),o=Q(()=>{let l=a.value;if(l!==null)return l;if(e.overlay)return 3;let c=s.value;return c&&c.source==="class"?c.level:i?i.value:c?c.level:1});return n&&ut(()=>{s.value=sS(nS(r.value)??((t==null?void 0:t.vnode.el)instanceof Element?t.vnode.el:null))}),e.provideContext!==!1&&ps(mu,Q(()=>N0(o.value+1))),{level:o,layerClass:Q(()=>gu(o.value)),layerProps:Q(()=>({class:gu(o.value),[m4]:String(o.value)})),surfaceRef:r}}const Xn=(e,t,i)=>{const r=s=>Me("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:t,fill:"currentColor",...s,innerHTML:i});return r.displayName="NbGlyph",r.glyphName=e,r},aS=Xn("caret-right","0 0 256 256",'<path d="M178.83,130.83l-80,80a4,4,0,0,1-5.66-5.66L170.34,128,93.17,50.83a4,4,0,0,1,5.66-5.66l80,80A4,4,0,0,1,178.83,130.83Z"/>'),oS=Xn("caret-right","0 0 256 256",'<path d="M180.24,132.24l-80,80a6,6,0,0,1-8.48-8.48L167.51,128,91.76,52.24a6,6,0,0,1,8.48-8.48l80,80A6,6,0,0,1,180.24,132.24Z"/>'),vu=Xn("caret-right","0 0 256 256",'<path d="M181.66,133.66l-80,80a8,8,0,0,1-11.32-11.32L164.69,128,90.34,53.66a8,8,0,0,1,11.32-11.32l80,80A8,8,0,0,1,181.66,133.66Z"/>'),lS=Xn("caret-right","0 0 256 256",'<path d="M184.49,136.49l-80,80a12,12,0,0,1-17-17L159,128,87.51,56.49a12,12,0,1,1,17-17l80,80A12,12,0,0,1,184.49,136.49Z"/>'),cS=Xn("caret-right","0 0 256 256",'<path d="M181.66,133.66l-80,80A8,8,0,0,1,88,208V48a8,8,0,0,1,13.66-5.66l80,80A8,8,0,0,1,181.66,133.66Z"/>'),uS=Xn("caret-right","0 0 256 256",'<path d="M176,128,96,208V48Z" opacity="0.2"/><path d="M181.66,122.34l-80-80A8,8,0,0,0,88,48V208a8,8,0,0,0,13.66,5.66l80-80A8,8,0,0,0,181.66,122.34ZM104,188.69V67.31L164.69,128Z"/>'),hS="caret-right",dS=Object.freeze(Object.defineProperty({__proto__:null,bold:lS,default:vu,duotone:uS,fill:cS,glyphName:hS,light:oS,regular:vu,thin:aS},Symbol.toStringTag,{value:"Module"}));var fS={class:"nb-breadcrumbs","aria-label":"breadcrumb"},pS={key:0,class:"nb-breadcrumbs__brand"},_S={key:0,class:"nb-breadcrumbs__title"},mS={key:1,class:"nb-breadcrumbs__subtitle"},gS={key:2,class:"nb-breadcrumbs__crumbs"},g4=ht(Re({__name:"Breadcrumbs",props:{title:{},subtitle:{}},setup(e){let t=ks();function i(s){return s.some(n=>n.type===Xt?!1:n.type===As?String(n.children??"").trim()!=="":n.type===we?i(n.children??[]):!0)}let r=Q(()=>{var s;return i(((s=t.default)==null?void 0:s.call(t))??[])});return(s,n)=>(g(),E("nav",fS,[e.title||e.subtitle?(g(),E("span",pS,[e.title?(g(),E("span",_S,Z(e.title),1)):F("",!0),e.subtitle?(g(),E("span",mS,Z(e.subtitle),1)):F("",!0)])):F("",!0),(e.title||e.subtitle)&&r.value?(g(),de(Ge,{key:1,name:ue(vu),size:"sm",class:"nb-breadcrumbs__sep"},null,8,["name"])):F("",!0),r.value?(g(),E("span",gS,[Pe(s.$slots,"default",{},void 0,!0)])):F("",!0)]))}}),[["__scopeId","data-v-064c6984"]]);function vS(e){var i,r,s,n;let t=(i=e.name)==null?void 0:i.trim();if(t){let a=t.split(/\s+/);return((((r=a[0])==null?void 0:r[0])??"")+(a.length>1?((s=a[a.length-1])==null?void 0:s[0])??"":"")).toUpperCase()}return(((n=e.email)==null?void 0:n.trim().split("@")[0])??"").slice(0,2).toUpperCase()}var v4=function(e){return e.Grey="grey",e.Blue="blue",e.Orange="orange",e.Green="green",e.Red="red",e.Purple="purple",e.Primary="primary",e}(v4||{}),b4=function(e){return e.Small="sm",e.Medium="md",e}(b4||{}),bS={key:0,class:"nb-badge__dot"},an=ht(Re({__name:"Badge",props:{variant:{default:v4.Grey},size:{default:b4.Medium},dot:{type:Boolean,default:!1}},setup(e){return(t,i)=>(g(),E("span",{class:xe(["nb-badge",`nb-badge--${e.variant}`,`nb-badge--${e.size}`])},[e.dot?(g(),E("span",bS)):F("",!0),Pe(t.$slots,"default",{},void 0,!0)],2))}}),[["__scopeId","data-v-02a9584e"]]);const Jn=(e,t,i)=>{const r=s=>Me("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:t,fill:"currentColor",...s,innerHTML:i});return r.displayName="NbGlyph",r.glyphName=e,r},yS=Jn("x","0 0 256 256",'<path d="M202.83,197.17a4,4,0,0,1-5.66,5.66L128,133.66,58.83,202.83a4,4,0,0,1-5.66-5.66L122.34,128,53.17,58.83a4,4,0,0,1,5.66-5.66L128,122.34l69.17-69.17a4,4,0,1,1,5.66,5.66L133.66,128Z"/>'),wS=Jn("x","0 0 256 256",'<path d="M204.24,195.76a6,6,0,1,1-8.48,8.48L128,136.49,60.24,204.24a6,6,0,0,1-8.48-8.48L119.51,128,51.76,60.24a6,6,0,0,1,8.48-8.48L128,119.51l67.76-67.75a6,6,0,0,1,8.48,8.48L136.49,128Z"/>'),rl=Jn("x","0 0 256 256",'<path d="M205.66,194.34a8,8,0,0,1-11.32,11.32L128,139.31,61.66,205.66a8,8,0,0,1-11.32-11.32L116.69,128,50.34,61.66A8,8,0,0,1,61.66,50.34L128,116.69l66.34-66.35a8,8,0,0,1,11.32,11.32L139.31,128Z"/>'),SS=Jn("x","0 0 256 256",'<path d="M208.49,191.51a12,12,0,0,1-17,17L128,145,64.49,208.49a12,12,0,0,1-17-17L111,128,47.51,64.49a12,12,0,0,1,17-17L128,111l63.51-63.52a12,12,0,0,1,17,17L145,128Z"/>'),CS=Jn("x","0 0 256 256",'<path d="M208,32H48A16,16,0,0,0,32,48V208a16,16,0,0,0,16,16H208a16,16,0,0,0,16-16V48A16,16,0,0,0,208,32ZM181.66,170.34a8,8,0,0,1-11.32,11.32L128,139.31,85.66,181.66a8,8,0,0,1-11.32-11.32L116.69,128,74.34,85.66A8,8,0,0,1,85.66,74.34L128,116.69l42.34-42.35a8,8,0,0,1,11.32,11.32L139.31,128Z"/>'),kS=Jn("x","0 0 256 256",'<path d="M216,56V200a16,16,0,0,1-16,16H56a16,16,0,0,1-16-16V56A16,16,0,0,1,56,40H200A16,16,0,0,1,216,56Z" opacity="0.2"/><path d="M205.66,194.34a8,8,0,0,1-11.32,11.32L128,139.31,61.66,205.66a8,8,0,0,1-11.32-11.32L116.69,128,50.34,61.66A8,8,0,0,1,61.66,50.34L128,116.69l66.34-66.35a8,8,0,0,1,11.32,11.32L139.31,128Z"/>'),AS="x",bu=Object.freeze(Object.defineProperty({__proto__:null,bold:SS,default:rl,duotone:kS,fill:CS,glyphName:AS,light:wS,regular:rl,thin:yS},Symbol.toStringTag,{value:"Module"})),Qn=(e,t,i)=>{const r=s=>Me("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:t,fill:"currentColor",...s,innerHTML:i});return r.displayName="NbGlyph",r.glyphName=e,r},MS=Qn("info","0 0 256 256",'<path d="M140,176a4,4,0,0,1-4,4,12,12,0,0,1-12-12V128a4,4,0,0,0-4-4,4,4,0,0,1,0-8,12,12,0,0,1,12,12v40a4,4,0,0,0,4,4A4,4,0,0,1,140,176ZM124,92a8,8,0,1,0-8-8A8,8,0,0,0,124,92Zm104,36A100,100,0,1,1,128,28,100.11,100.11,0,0,1,228,128Zm-8,0a92,92,0,1,0-92,92A92.1,92.1,0,0,0,220,128Z"/>'),LS=Qn("info","0 0 256 256",'<path d="M142,176a6,6,0,0,1-6,6,14,14,0,0,1-14-14V128a2,2,0,0,0-2-2,6,6,0,0,1,0-12,14,14,0,0,1,14,14v40a2,2,0,0,0,2,2A6,6,0,0,1,142,176ZM124,94a10,10,0,1,0-10-10A10,10,0,0,0,124,94Zm106,34A102,102,0,1,1,128,26,102.12,102.12,0,0,1,230,128Zm-12,0a90,90,0,1,0-90,90A90.1,90.1,0,0,0,218,128Z"/>'),H0=Qn("info","0 0 256 256",'<path d="M128,24A104,104,0,1,0,232,128,104.11,104.11,0,0,0,128,24Zm0,192a88,88,0,1,1,88-88A88.1,88.1,0,0,1,128,216Zm16-40a8,8,0,0,1-8,8,16,16,0,0,1-16-16V128a8,8,0,0,1,0-16,16,16,0,0,1,16,16v40A8,8,0,0,1,144,176ZM112,84a12,12,0,1,1,12,12A12,12,0,0,1,112,84Z"/>'),ES=Qn("info","0 0 256 256",'<path d="M108,84a16,16,0,1,1,16,16A16,16,0,0,1,108,84Zm128,44A108,108,0,1,1,128,20,108.12,108.12,0,0,1,236,128Zm-24,0a84,84,0,1,0-84,84A84.09,84.09,0,0,0,212,128Zm-72,36.68V132a20,20,0,0,0-20-20,12,12,0,0,0-4,23.32V168a20,20,0,0,0,20,20,12,12,0,0,0,4-23.32Z"/>'),$S=Qn("info","0 0 256 256",'<path d="M128,24A104,104,0,1,0,232,128,104.11,104.11,0,0,0,128,24Zm-4,48a12,12,0,1,1-12,12A12,12,0,0,1,124,72Zm12,112a16,16,0,0,1-16-16V128a8,8,0,0,1,0-16,16,16,0,0,1,16,16v40a8,8,0,0,1,0,16Z"/>'),xS=Qn("info","0 0 256 256",'<path d="M224,128a96,96,0,1,1-96-96A96,96,0,0,1,224,128Z" opacity="0.2"/><path d="M144,176a8,8,0,0,1-8,8,16,16,0,0,1-16-16V128a8,8,0,0,1,0-16,16,16,0,0,1,16,16v40A8,8,0,0,1,144,176Zm88-48A104,104,0,1,1,128,24,104.11,104.11,0,0,1,232,128Zm-16,0a88,88,0,1,0-88,88A88.1,88.1,0,0,0,216,128ZM124,96a12,12,0,1,0-12-12A12,12,0,0,0,124,96Z"/>'),TS="info",y4=Object.freeze(Object.defineProperty({__proto__:null,bold:ES,default:H0,duotone:xS,fill:$S,glyphName:TS,light:LS,regular:H0,thin:MS},Symbol.toStringTag,{value:"Module"})),ea=(e,t,i)=>{const r=s=>Me("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:t,fill:"currentColor",...s,innerHTML:i});return r.displayName="NbGlyph",r.glyphName=e,r},NS=ea("check-circle","0 0 256 256",'<path d="M170.83,101.17a4,4,0,0,1,0,5.66l-56,56a4,4,0,0,1-5.66,0l-24-24a4,4,0,0,1,5.66-5.66L112,154.34l53.17-53.17A4,4,0,0,1,170.83,101.17ZM228,128A100,100,0,1,1,128,28,100.11,100.11,0,0,1,228,128Zm-8,0a92,92,0,1,0-92,92A92.1,92.1,0,0,0,220,128Z"/>'),HS=ea("check-circle","0 0 256 256",'<path d="M172.24,99.76a6,6,0,0,1,0,8.48l-56,56a6,6,0,0,1-8.48,0l-24-24a6,6,0,0,1,8.48-8.48L112,151.51l51.76-51.75A6,6,0,0,1,172.24,99.76ZM230,128A102,102,0,1,1,128,26,102.12,102.12,0,0,1,230,128Zm-12,0a90,90,0,1,0-90,90A90.1,90.1,0,0,0,218,128Z"/>'),Rf=ea("check-circle","0 0 256 256",'<path d="M173.66,98.34a8,8,0,0,1,0,11.32l-56,56a8,8,0,0,1-11.32,0l-24-24a8,8,0,0,1,11.32-11.32L112,148.69l50.34-50.35A8,8,0,0,1,173.66,98.34ZM232,128A104,104,0,1,1,128,24,104.11,104.11,0,0,1,232,128Zm-16,0a88,88,0,1,0-88,88A88.1,88.1,0,0,0,216,128Z"/>'),PS=ea("check-circle","0 0 256 256",'<path d="M176.49,95.51a12,12,0,0,1,0,17l-56,56a12,12,0,0,1-17,0l-24-24a12,12,0,1,1,17-17L112,143l47.51-47.52A12,12,0,0,1,176.49,95.51ZM236,128A108,108,0,1,1,128,20,108.12,108.12,0,0,1,236,128Zm-24,0a84,84,0,1,0-84,84A84.09,84.09,0,0,0,212,128Z"/>'),OS=ea("check-circle","0 0 256 256",'<path d="M128,24A104,104,0,1,0,232,128,104.11,104.11,0,0,0,128,24Zm45.66,85.66-56,56a8,8,0,0,1-11.32,0l-24-24a8,8,0,0,1,11.32-11.32L112,148.69l50.34-50.35a8,8,0,0,1,11.32,11.32Z"/>'),IS=ea("check-circle","0 0 256 256",'<path d="M224,128a96,96,0,1,1-96-96A96,96,0,0,1,224,128Z" opacity="0.2"/><path d="M173.66,98.34a8,8,0,0,1,0,11.32l-56,56a8,8,0,0,1-11.32,0l-24-24a8,8,0,0,1,11.32-11.32L112,148.69l50.34-50.35A8,8,0,0,1,173.66,98.34ZM232,128A104,104,0,1,1,128,24,104.11,104.11,0,0,1,232,128Zm-16,0a88,88,0,1,0-88,88A88.1,88.1,0,0,0,216,128Z"/>'),RS="check-circle",ud=Object.freeze(Object.defineProperty({__proto__:null,bold:PS,default:Rf,duotone:IS,fill:OS,glyphName:RS,light:HS,regular:Rf,thin:NS},Symbol.toStringTag,{value:"Module"})),ta=(e,t,i)=>{const r=s=>Me("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:t,fill:"currentColor",...s,innerHTML:i});return r.displayName="NbGlyph",r.glyphName=e,r},DS=ta("warning","0 0 256 256",'<path d="M233.34,190.09,145.88,38.22h0a20.75,20.75,0,0,0-35.76,0L22.66,190.09a19.52,19.52,0,0,0,0,19.71A20.36,20.36,0,0,0,40.54,220H215.46a20.36,20.36,0,0,0,17.86-10.2A19.52,19.52,0,0,0,233.34,190.09ZM226.4,205.8a12.47,12.47,0,0,1-10.94,6.2H40.54a12.47,12.47,0,0,1-10.94-6.2,11.45,11.45,0,0,1,0-11.72L117.05,42.21a12.76,12.76,0,0,1,21.9,0L226.4,194.08A11.45,11.45,0,0,1,226.4,205.8ZM124,144V104a4,4,0,0,1,8,0v40a4,4,0,0,1-8,0Zm12,36a8,8,0,1,1-8-8A8,8,0,0,1,136,180Z"/>'),VS=ta("warning","0 0 256 256",'<path d="M235.07,189.09,147.61,37.22h0a22.75,22.75,0,0,0-39.22,0L20.93,189.09a21.53,21.53,0,0,0,0,21.72A22.35,22.35,0,0,0,40.55,222h174.9a22.35,22.35,0,0,0,19.6-11.19A21.53,21.53,0,0,0,235.07,189.09ZM224.66,204.8a10.46,10.46,0,0,1-9.21,5.2H40.55a10.46,10.46,0,0,1-9.21-5.2,9.51,9.51,0,0,1,0-9.72L118.79,43.21a10.75,10.75,0,0,1,18.42,0l87.46,151.87A9.51,9.51,0,0,1,224.66,204.8ZM122,144V104a6,6,0,0,1,12,0v40a6,6,0,0,1-12,0Zm16,36a10,10,0,1,1-10-10A10,10,0,0,1,138,180Z"/>'),mr=ta("warning","0 0 256 256",'<path d="M236.8,188.09,149.35,36.22h0a24.76,24.76,0,0,0-42.7,0L19.2,188.09a23.51,23.51,0,0,0,0,23.72A24.35,24.35,0,0,0,40.55,224h174.9a24.35,24.35,0,0,0,21.33-12.19A23.51,23.51,0,0,0,236.8,188.09ZM222.93,203.8a8.5,8.5,0,0,1-7.48,4.2H40.55a8.5,8.5,0,0,1-7.48-4.2,7.59,7.59,0,0,1,0-7.72L120.52,44.21a8.75,8.75,0,0,1,15,0l87.45,151.87A7.59,7.59,0,0,1,222.93,203.8ZM120,144V104a8,8,0,0,1,16,0v40a8,8,0,0,1-16,0Zm20,36a12,12,0,1,1-12-12A12,12,0,0,1,140,180Z"/>'),BS=ta("warning","0 0 256 256",'<path d="M240.26,186.1,152.81,34.23h0a28.74,28.74,0,0,0-49.62,0L15.74,186.1a27.45,27.45,0,0,0,0,27.71A28.31,28.31,0,0,0,40.55,228h174.9a28.31,28.31,0,0,0,24.79-14.19A27.45,27.45,0,0,0,240.26,186.1Zm-20.8,15.7a4.46,4.46,0,0,1-4,2.2H40.55a4.46,4.46,0,0,1-4-2.2,3.56,3.56,0,0,1,0-3.73L124,46.2a4.77,4.77,0,0,1,8,0l87.44,151.87A3.56,3.56,0,0,1,219.46,201.8ZM116,136V104a12,12,0,0,1,24,0v32a12,12,0,0,1-24,0Zm28,40a16,16,0,1,1-16-16A16,16,0,0,1,144,176Z"/>'),ZS=ta("warning","0 0 256 256",'<path d="M236.8,188.09,149.35,36.22h0a24.76,24.76,0,0,0-42.7,0L19.2,188.09a23.51,23.51,0,0,0,0,23.72A24.35,24.35,0,0,0,40.55,224h174.9a24.35,24.35,0,0,0,21.33-12.19A23.51,23.51,0,0,0,236.8,188.09ZM120,104a8,8,0,0,1,16,0v40a8,8,0,0,1-16,0Zm8,88a12,12,0,1,1,12-12A12,12,0,0,1,128,192Z"/>'),FS=ta("warning","0 0 256 256",'<path d="M215.46,216H40.54C27.92,216,20,202.79,26.13,192.09L113.59,40.22c6.3-11,22.52-11,28.82,0l87.46,151.87C236,202.79,228.08,216,215.46,216Z" opacity="0.2"/><path d="M236.8,188.09,149.35,36.22h0a24.76,24.76,0,0,0-42.7,0L19.2,188.09a23.51,23.51,0,0,0,0,23.72A24.35,24.35,0,0,0,40.55,224h174.9a24.35,24.35,0,0,0,21.33-12.19A23.51,23.51,0,0,0,236.8,188.09ZM222.93,203.8a8.5,8.5,0,0,1-7.48,4.2H40.55a8.5,8.5,0,0,1-7.48-4.2,7.59,7.59,0,0,1,0-7.72L120.52,44.21a8.75,8.75,0,0,1,15,0l87.45,151.87A7.59,7.59,0,0,1,222.93,203.8ZM120,144V104a8,8,0,0,1,16,0v40a8,8,0,0,1-16,0Zm20,36a12,12,0,1,1-12-12A12,12,0,0,1,140,180Z"/>'),zS="warning",w4=Object.freeze(Object.defineProperty({__proto__:null,bold:BS,default:mr,duotone:FS,fill:ZS,glyphName:zS,light:VS,regular:mr,thin:DS},Symbol.toStringTag,{value:"Module"})),ia=(e,t,i)=>{const r=s=>Me("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:t,fill:"currentColor",...s,innerHTML:i});return r.displayName="NbGlyph",r.glyphName=e,r},US=ia("x-circle","0 0 256 256",'<path d="M162.83,98.83,133.66,128l29.17,29.17a4,4,0,0,1-5.66,5.66L128,133.66,98.83,162.83a4,4,0,0,1-5.66-5.66L122.34,128,93.17,98.83a4,4,0,0,1,5.66-5.66L128,122.34l29.17-29.17a4,4,0,1,1,5.66,5.66ZM228,128A100,100,0,1,1,128,28,100.11,100.11,0,0,1,228,128Zm-8,0a92,92,0,1,0-92,92A92.1,92.1,0,0,0,220,128Z"/>'),WS=ia("x-circle","0 0 256 256",'<path d="M164.24,100.24,136.48,128l27.76,27.76a6,6,0,1,1-8.48,8.48L128,136.48l-27.76,27.76a6,6,0,0,1-8.48-8.48L119.52,128,91.76,100.24a6,6,0,0,1,8.48-8.48L128,119.52l27.76-27.76a6,6,0,0,1,8.48,8.48ZM230,128A102,102,0,1,1,128,26,102.12,102.12,0,0,1,230,128Zm-12,0a90,90,0,1,0-90,90A90.1,90.1,0,0,0,218,128Z"/>'),Df=ia("x-circle","0 0 256 256",'<path d="M165.66,101.66,139.31,128l26.35,26.34a8,8,0,0,1-11.32,11.32L128,139.31l-26.34,26.35a8,8,0,0,1-11.32-11.32L116.69,128,90.34,101.66a8,8,0,0,1,11.32-11.32L128,116.69l26.34-26.35a8,8,0,0,1,11.32,11.32ZM232,128A104,104,0,1,1,128,24,104.11,104.11,0,0,1,232,128Zm-16,0a88,88,0,1,0-88,88A88.1,88.1,0,0,0,216,128Z"/>'),jS=ia("x-circle","0 0 256 256",'<path d="M168.49,104.49,145,128l23.52,23.51a12,12,0,0,1-17,17L128,145l-23.51,23.52a12,12,0,0,1-17-17L111,128,87.51,104.49a12,12,0,0,1,17-17L128,111l23.51-23.52a12,12,0,0,1,17,17ZM236,128A108,108,0,1,1,128,20,108.12,108.12,0,0,1,236,128Zm-24,0a84,84,0,1,0-84,84A84.09,84.09,0,0,0,212,128Z"/>'),KS=ia("x-circle","0 0 256 256",'<path d="M128,24A104,104,0,1,0,232,128,104.11,104.11,0,0,0,128,24Zm37.66,130.34a8,8,0,0,1-11.32,11.32L128,139.31l-26.34,26.35a8,8,0,0,1-11.32-11.32L116.69,128,90.34,101.66a8,8,0,0,1,11.32-11.32L128,116.69l26.34-26.35a8,8,0,0,1,11.32,11.32L139.31,128Z"/>'),qS=ia("x-circle","0 0 256 256",'<path d="M224,128a96,96,0,1,1-96-96A96,96,0,0,1,224,128Z" opacity="0.2"/><path d="M165.66,101.66,139.31,128l26.35,26.34a8,8,0,0,1-11.32,11.32L128,139.31l-26.34,26.35a8,8,0,0,1-11.32-11.32L116.69,128,90.34,101.66a8,8,0,0,1,11.32-11.32L128,116.69l26.34-26.35a8,8,0,0,1,11.32,11.32ZM232,128A104,104,0,1,1,128,24,104.11,104.11,0,0,1,232,128Zm-16,0a88,88,0,1,0-88,88A88.1,88.1,0,0,0,216,128Z"/>'),GS="x-circle",YS=Object.freeze(Object.defineProperty({__proto__:null,bold:jS,default:Df,duotone:qS,fill:KS,glyphName:GS,light:WS,regular:Df,thin:US},Symbol.toStringTag,{value:"Module"})),ra=(e,t,i)=>{const r=s=>Me("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:t,fill:"currentColor",...s,innerHTML:i});return r.displayName="NbGlyph",r.glyphName=e,r},XS=ra("note","0 0 256 256",'<path d="M92,96a4,4,0,0,1,4-4h64a4,4,0,0,1,0,8H96A4,4,0,0,1,92,96Zm4,36h64a4,4,0,0,0,0-8H96a4,4,0,0,0,0,8Zm32,24H96a4,4,0,0,0,0,8h32a4,4,0,0,0,0-8ZM220,48V156.69a11.9,11.9,0,0,1-3.52,8.48l-51.31,51.32a11.93,11.93,0,0,1-8.48,3.51H48a12,12,0,0,1-12-12V48A12,12,0,0,1,48,36H208A12,12,0,0,1,220,48ZM48,212H156V160a4,4,0,0,1,4-4h52V48a4,4,0,0,0-4-4H48a4,4,0,0,0-4,4V208A4,4,0,0,0,48,212Zm158.35-48H164v42.35Z"/>'),JS=ra("note","0 0 256 256",'<path d="M90,96a6,6,0,0,1,6-6h64a6,6,0,0,1,0,12H96A6,6,0,0,1,90,96Zm6,38h64a6,6,0,0,0,0-12H96a6,6,0,0,0,0,12Zm32,20H96a6,6,0,0,0,0,12h32a6,6,0,0,0,0-12ZM222,48V156.69a13.94,13.94,0,0,1-4.1,9.9L166.59,217.9a13.94,13.94,0,0,1-9.9,4.1H48a14,14,0,0,1-14-14V48A14,14,0,0,1,48,34H208A14,14,0,0,1,222,48ZM48,210H154V160a6,6,0,0,1,6-6h50V48a2,2,0,0,0-2-2H48a2,2,0,0,0-2,2V208A2,2,0,0,0,48,210Zm153.52-44H166v35.52Z"/>'),Vf=ra("note","0 0 256 256",'<path d="M88,96a8,8,0,0,1,8-8h64a8,8,0,0,1,0,16H96A8,8,0,0,1,88,96Zm8,40h64a8,8,0,0,0,0-16H96a8,8,0,0,0,0,16Zm32,16H96a8,8,0,0,0,0,16h32a8,8,0,0,0,0-16ZM224,48V156.69A15.86,15.86,0,0,1,219.31,168L168,219.31A15.86,15.86,0,0,1,156.69,224H48a16,16,0,0,1-16-16V48A16,16,0,0,1,48,32H208A16,16,0,0,1,224,48ZM48,208H152V160a8,8,0,0,1,8-8h48V48H48Zm120-40v28.7L196.69,168Z"/>'),QS=ra("note","0 0 256 256",'<path d="M84,108A12,12,0,0,1,96,96h64a12,12,0,0,1,0,24H96A12,12,0,0,1,84,108Zm32,28H96a12,12,0,0,0,0,24h20a12,12,0,0,0,0-24ZM228,48V156.69a19.86,19.86,0,0,1-5.86,14.14l-51.31,51.31A19.86,19.86,0,0,1,156.69,228H48a20,20,0,0,1-20-20V48A20,20,0,0,1,48,28H208A20,20,0,0,1,228,48ZM52,204h92V156a12,12,0,0,1,12-12h48V52H52Zm139-36H168v23Z"/>'),e9=ra("note","0 0 256 256",'<path d="M208,32H48A16,16,0,0,0,32,48V208a16,16,0,0,0,16,16H156.69A15.92,15.92,0,0,0,168,219.31L219.31,168A15.92,15.92,0,0,0,224,156.69V48A16,16,0,0,0,208,32ZM96,88h64a8,8,0,0,1,0,16H96a8,8,0,0,1,0-16Zm32,80H96a8,8,0,0,1,0-16h32a8,8,0,0,1,0,16ZM96,136a8,8,0,0,1,0-16h64a8,8,0,0,1,0,16Zm64,68.69V160h44.7Z"/>'),t9=ra("note","0 0 256 256",'<path d="M216,160l-56,56V160Z" opacity="0.2"/><path d="M88,96a8,8,0,0,1,8-8h64a8,8,0,0,1,0,16H96A8,8,0,0,1,88,96Zm8,40h64a8,8,0,0,0,0-16H96a8,8,0,0,0,0,16Zm32,16H96a8,8,0,0,0,0,16h32a8,8,0,0,0,0-16ZM224,48V156.69A15.86,15.86,0,0,1,219.31,168L168,219.31A15.86,15.86,0,0,1,156.69,224H48a16,16,0,0,1-16-16V48A16,16,0,0,1,48,32H208A16,16,0,0,1,224,48ZM48,208H152V160a8,8,0,0,1,8-8h48V48H48Zm120-40v28.7L196.69,168Z"/>'),i9="note",r9=Object.freeze(Object.defineProperty({__proto__:null,bold:QS,default:Vf,duotone:t9,fill:e9,glyphName:i9,light:JS,regular:Vf,thin:XS},Symbol.toStringTag,{value:"Module"}));var yu=function(e){return e.Info="info",e.Success="success",e.Warning="warning",e.Error="error",e.Neutral="neutral",e}(yu||{}),wu=function(e){return e.Inline="inline",e.Callout="callout",e}(wu||{}),s9=["role","aria-live"],n9={class:"nb-banner__body"},a9={key:0,class:"nb-banner__title"},o9={key:1,class:"nb-banner__text"},l9={key:1,class:"nb-banner__actions"},c9=["aria-label"],bc=ht(Re({__name:"Banner",props:{status:{default:yu.Info},variant:{default:wu.Inline},title:{},dismissible:{type:Boolean,default:!1},icon:{},hideIcon:{type:Boolean,default:!1},flush:{type:Boolean,default:!1},closeLabel:{default:"Dismiss"}},emits:["dismiss"],setup(e,{emit:t}){let i=e,r=t,s=ks(),n=Q(()=>!!s.default),a=Q(()=>!!s.action),o=Q(()=>i.dismissible&&i.variant!==wu.Callout),l=Q(()=>i.status===yu.Error),c=X(!1);function u(){c.value=!0,r("dismiss")}let h={info:y4,success:ud,warning:w4,error:YS,neutral:r9};return(d,f)=>c.value?F("",!0):(g(),E("div",{key:0,class:xe(["nb-banner",`nb-banner--${i.status}`,`nb-banner--${i.variant}`,{"nb-banner--flush":i.flush}]),role:l.value?"alert":"status","aria-live":l.value?"assertive":"polite"},[i.hideIcon?F("",!0):(g(),de(Ge,{key:0,name:i.icon??h[i.status],size:18,weight:"fill",class:"nb-banner__icon","aria-hidden":"true"},null,8,["name"])),b("p",n9,[i.title?(g(),E("strong",a9,Z(i.title),1)):F("",!0),n.value?(g(),E("span",o9,[Pe(d.$slots,"default",{},void 0,!0)])):F("",!0)]),a.value?(g(),E("div",l9,[Pe(d.$slots,"action",{},void 0,!0)])):F("",!0),o.value?(g(),E("button",{key:2,type:"button",class:"nb-banner__close","aria-label":i.closeLabel,onClick:u},[Y(Ge,{name:ue(rl),size:14},null,8,["name"])],8,c9)):F("",!0)],10,s9))}}),[["__scopeId","data-v-bf09999e"]]),u9={key:0,class:"nb-chart__header"},h9={key:0,class:"nb-chart__title"},d9={key:1,class:"nb-chart__subtitle"},hd=ht(Re({__name:"ChartFrame",props:{title:{default:void 0},subtitle:{default:void 0},height:{default:280},showLegend:{type:Boolean,default:!0}},setup(e,{expose:t}){let i=e,r=X(null),s=Q(()=>{let n=i.height;return typeof n=="number"||/^\d+(\.\d+)?$/.test(n)?`${n}px`:n});return t({viewport:r}),(n,a)=>(g(),E("figure",{class:"nb-chart",style:Ci({height:s.value})},[e.title||e.subtitle?(g(),E("figcaption",u9,[e.title?(g(),E("h4",h9,Z(e.title),1)):F("",!0),e.subtitle?(g(),E("p",d9,Z(e.subtitle),1)):F("",!0)])):F("",!0),b("div",{ref_key:"viewport",ref:r,class:"nb-chart__viewport"},[Pe(n.$slots,"default",{},void 0,!0)],512),e.showLegend?Pe(n.$slots,"legend",{key:1},void 0,!0):F("",!0)],4))}}),[["__scopeId","data-v-0b28100e"]]),f9={key:0,class:"nb-chart__tooltip-title"},p9={class:"nb-chart__tooltip-rows"},_9={class:"nb-chart__tooltip-label"},m9={class:"nb-chart__tooltip-value"},dd=ht(Re({__name:"ChartTooltip",props:{visible:{type:Boolean},x:{},y:{},title:{},rows:{}},setup(e){return(t,i)=>(g(),de(jh,{name:"nb-chart-tooltip"},{default:ee(()=>[e.visible?(g(),E("div",{key:0,class:"nb-chart__tooltip",style:Ci({transform:`translate(${e.x}px, ${e.y}px)`}),role:"tooltip"},[e.title?(g(),E("div",f9,Z(e.title),1)):F("",!0),b("ul",p9,[(g(!0),E(we,null,Be(e.rows,(r,s)=>(g(),E("li",{key:`${r.label}-${s}`,class:"nb-chart__tooltip-row"},[b("span",{class:"nb-chart__tooltip-swatch",style:Ci({background:r.color})},null,4),b("span",_9,Z(r.label),1),b("span",m9,Z(r.value),1)]))),128))])],4)):F("",!0)]),_:1}))}}),[["__scopeId","data-v-03e0b7bb"]]),P0=["var(--nb-c-chart-1)","var(--nb-c-chart-2)","var(--nb-c-chart-3)","var(--nb-c-chart-4)","var(--nb-c-chart-5)","var(--nb-c-chart-6)","var(--nb-c-chart-7)","var(--nb-c-chart-8)"],fd=(e,t=P0)=>{let i=t.length>0?t:P0;return i[((Number.isFinite(e)?Math.trunc(e):0)%i.length+i.length)%i.length]},g9={class:"nb-chart__legend"},v9={class:"nb-chart__legend-label"},S4=ht(Re({__name:"ChartLegend",props:{items:{}},setup(e){return(t,i)=>(g(),E("ul",g9,[(g(!0),E(we,null,Be(e.items,r=>(g(),E("li",{key:r.label,class:"nb-chart__legend-item"},[b("span",{class:"nb-chart__legend-swatch",style:Ci({background:r.color})},null,4),b("span",v9,Z(r.label),1)]))),128))]))}}),[["__scopeId","data-v-401d7d8b"]]),O0=(e,t)=>{let[i,r]=e,[s,n]=t,a=r-i||1,o=l=>s+(l-i)/a*(n-s);return o.domain=e,o.range=t,o.ticks=(l=5)=>y9(i,r,l),o},b9=(e,t,i=.2)=>{let[r,s]=t,n=(s-r)/Math.max(e.length,1),a=n*(1-i),o=(n-a)/2,l=new Map(e.map((u,h)=>[u,h])),c=u=>{let h=l.get(u);return h===void 0?r:r+h*n+o};return c.bandwidth=a,c.domain=e,c.range=t,c},y9=(e,t,i=5)=>{if(e===t)return[e];let r=t-e,s=r/Math.max(i,1),n=10**Math.floor(Math.log10(s)),a=[1,2,5,10].map(u=>u*n),o=a.find(u=>r/u<=i*1.5)??a[a.length-1],l=Math.ceil(e/o)*o,c=[];for(let u=l;u<=t+o/2;u+=o)c.push(Number(u.toFixed(10)));return c},pd=(e,t,i=.05)=>{if(e===t){let s=Math.abs(e)||1;return[e-s,t+s]}let r=(t-e)*i;return[e-r,t+r]},_d=(e,t={width:480,height:280})=>{let i=X({...t}),r=null;return ut(()=>{!e.value||typeof ResizeObserver>"u"||(r=new ResizeObserver(s=>{let n=s[0];if(!n)return;let{width:a,height:o}=n.contentRect;i.value={width:Math.max(0,Math.round(a)),height:Math.max(0,Math.round(o))}}),r.observe(e.value))}),Gi(()=>{r==null||r.disconnect(),r=null}),i},w9=["width","height","role","aria-label"],S9={key:0},C9=["x1","x2","y1","y2"],k9={class:"nb-chart__axis"},A9=["x","y","text-anchor","dominant-baseline"],M9={class:"nb-chart__axis"},L9=["x","y","text-anchor","dominant-baseline"],E9=["x1","x2","y1","y2"],$9=["fill","tabindex","role","aria-label","onKeydown"],x9={class:"nb-chart__hover-layer"},T9=["onMouseenter","onMousemove","onClick"],N9=ht(Re({__name:"BarChart",props:{series:{default:()=>[]},orientation:{default:"vertical"},stacked:{type:Boolean,default:!1},title:{default:void 0},subtitle:{default:void 0},height:{default:280},showLegend:{type:Boolean,default:!0},showTooltip:{type:Boolean,default:!0},showGrid:{type:Boolean,default:!0},colors:{default:()=>P0}},emits:["select"],setup(e,{emit:t}){let i=e,r=t,s=X(null),n=_d(s,{width:480,height:240}),a=Q(()=>i.orientation==="horizontal"),o=Q(()=>i.series.map((J,fe)=>({name:J.name,data:J.data,color:J.color??fd(fe,i.colors)}))),l=Q(()=>{var J;return(((J=i.series[0])==null?void 0:J.data)??[]).map(fe=>fe.x)}),c=(J,fe)=>{var re,_e;return((_e=(re=o.value[fe])==null?void 0:re.data[J])==null?void 0:_e.y)??0},u=(J,fe)=>{let re=c(J,fe);if(!i.stacked)return[0,re];let _e=0;for(let Ne=0;Ne<fe;Ne+=1){let $e=c(J,Ne);$e>=0==re>=0&&(_e+=$e)}return[_e,_e+re]},h=Q(()=>{let J=[];return l.value.forEach((fe,re)=>{o.value.forEach((_e,Ne)=>{J.push(u(re,Ne)[1])})}),J.length?pd(Math.min(0,...J),Math.max(0,...J),.05):[0,1]}),d=Q(()=>{if(!a.value)return{top:12,right:16,bottom:28,left:44};let J=l.value.reduce((re,_e)=>Math.max(re,String(_e).length),0),fe=Math.max(44,Math.round(n.value.width*.4));return{top:12,right:16,bottom:28,left:Math.min(Math.max(44,Math.ceil(J*6.2)+12),fe)}}),f=Q(()=>({x0:d.value.left,x1:Math.max(d.value.left,n.value.width-d.value.right),y0:d.value.top,y1:Math.max(d.value.top,n.value.height-d.value.bottom)})),m=Q(()=>b9(l.value.map(J=>String(J)),a.value?[f.value.y0,f.value.y1]:[f.value.x0,f.value.x1],.2)),_=Q(()=>O0(h.value,a.value?[f.value.x0,f.value.x1]:[f.value.y1,f.value.y0])),y=Q(()=>_.value.ticks(5)),p=J=>m.value(String(l.value[J])),C=J=>p(J)+m.value.bandwidth/2,w=Q(()=>{let J=o.value.length||1;return i.stacked?m.value.bandwidth:m.value.bandwidth/J}),v=(J,fe)=>{let[re,_e]=u(J,fe),Ne=_.value(re),$e=_.value(_e),be=Math.max(0,w.value-2),me=p(J)+(i.stacked?0:fe*w.value),O=Math.max(0,Math.abs($e-Ne));return a.value?{x:Math.min(Ne,$e),y:me,width:O,height:be}:{x:me,y:Math.min(Ne,$e),width:be,height:O}},k=J=>{let fe=p(J),re=m.value.bandwidth;return a.value?{x:f.value.x0,y:fe,width:Math.max(0,f.value.x1-f.value.x0),height:re}:{x:fe,y:f.value.y0,width:re,height:Math.max(0,f.value.y1-f.value.y0)}},$=J=>Math.abs(J)>=1e3?`${(J/1e3).toFixed(1)}k`:String(J),M=ki(),D=()=>{var J;return!!((J=M==null?void 0:M.vnode.props)!=null&&J.onSelect)},H=(J,fe)=>{let re=o.value[fe],_e=$(c(J,fe));return o.value.length>1?`${l.value[J]}, ${re==null?void 0:re.name}: ${_e}`:`${l.value[J]}: ${_e}`},R=(J,fe)=>{let re=o.value[fe],_e=re==null?void 0:re.data[J];return{kind:"series",x:(_e==null?void 0:_e.x)??l.value[J],y:(_e==null?void 0:_e.y)??0,seriesName:(re==null?void 0:re.name)??"",seriesIndex:fe,index:J,point:_e??{x:l.value[J],y:0}}},V=J=>{let fe=J.currentTarget.ownerSVGElement;if(!fe)return null;let re=fe.getBoundingClientRect();return{x:J.clientX-re.left,y:J.clientY-re.top}},N=(J,fe)=>{let re=o.value.length;if(re<=1)return 0;let _e=V(J);if(!_e)return 0;if(i.stacked){let be=a.value?_e.x:_e.y;for(let me=0;me<re;me+=1){let[O,ie]=u(fe,me),le=_.value(O),ge=_.value(ie);if(be>=Math.min(le,ge)&&be<=Math.max(le,ge))return me}return re-1}let Ne=(a.value?_e.y:_e.x)-p(fe),$e=Math.floor(Ne/(w.value||1));return Math.min(Math.max($e,0),re-1)},P=(J,fe)=>{D()&&r("select",R(fe,N(J,fe)))},U=(J,fe,re)=>{D()&&(J.key!=="Enter"&&J.key!==" "||(J.preventDefault(),r("select",R(fe,re))))},j=X(null),oe=X({x:0,y:0}),te=(J,fe)=>{let re=V(J);re&&(oe.value={x:re.x+12,y:re.y+12},j.value=fe)},ne=Q(()=>j.value===null?[]:o.value.map(J=>{var fe;return{label:J.name,value:$(((fe=J.data[j.value])==null?void 0:fe.y)??0),color:J.color}}));return(J,fe)=>(g(),de(hd,{title:e.title,subtitle:e.subtitle,height:e.height,"show-legend":e.showLegend&&o.value.length>0},{legend:ee(()=>[Y(S4,{items:o.value.map(re=>({label:re.name,color:re.color}))},null,8,["items"])]),default:ee(()=>[b("div",{ref_key:"root",ref:s,class:"nb-bar-chart"},[(g(),E("svg",{width:ue(n).width,height:ue(n).height,class:xe(["nb-chart__svg",{"nb-chart__svg--selectable":D()}]),role:D()?"group":"img","aria-label":e.title||"Bar chart",onMouseleave:fe[0]||(fe[0]=re=>j.value=null)},[e.showGrid&&ue(n).width>0?(g(),E("g",S9,[(g(!0),E(we,null,Be(y.value,re=>(g(),E("line",{key:`grid-${re}`,class:"nb-chart__gridline",x1:a.value?_.value(re):f.value.x0,x2:a.value?_.value(re):f.value.x1,y1:a.value?f.value.y0:_.value(re),y2:a.value?f.value.y1:_.value(re)},null,8,C9))),128))])):F("",!0),b("g",k9,[(g(!0),E(we,null,Be(y.value,re=>(g(),E("text",{key:`vt-${re}`,x:a.value?_.value(re):f.value.x0-6,y:a.value?f.value.y1+14:_.value(re),"text-anchor":a.value?"middle":"end","dominant-baseline":a.value?"auto":"middle"},Z($(re)),9,A9))),128))]),b("g",M9,[(g(!0),E(we,null,Be(l.value,(re,_e)=>(g(),E("text",{key:`ct-${_e}`,x:a.value?f.value.x0-6:C(_e),y:a.value?C(_e):f.value.y1+14,"text-anchor":a.value?"end":"middle","dominant-baseline":a.value?"middle":"auto"},Z(re),9,L9))),128))]),b("line",{class:"nb-chart__axis-line",x1:a.value?_.value(0):f.value.x0,x2:a.value?_.value(0):f.value.x1,y1:a.value?f.value.y0:_.value(0),y2:a.value?f.value.y1:_.value(0)},null,8,E9),(g(!0),E(we,null,Be(l.value,(re,_e)=>(g(),E("g",{key:`g-${_e}`},[(g(!0),E(we,null,Be(o.value,(Ne,$e)=>(g(),E("rect",Jt({key:`${_e}-${$e}`,class:["nb-chart__bar",{"is-dim":j.value!==null&&j.value!==_e}]},{ref_for:!0},v(_e,$e),{fill:Ne.color,tabindex:D()?0:void 0,role:D()?"button":void 0,"aria-label":D()?H(_e,$e):void 0,onKeydown:be=>U(be,_e,$e)}),null,16,$9))),128))]))),128)),b("g",x9,[(g(!0),E(we,null,Be(l.value,(re,_e)=>(g(),E("rect",Jt({key:`hover-${_e}`},{ref_for:!0},k(_e),{fill:"transparent",onMouseenter:Ne=>j.value=_e,onMousemove:Ne=>te(Ne,_e),onClick:Ne=>P(Ne,_e)}),null,16,T9))),128))])],42,w9)),Y(dd,{visible:e.showTooltip&&j.value!==null,x:oe.value.x,y:oe.value.y,title:j.value===null?"":String(l.value[j.value]),rows:ne.value},null,8,["visible","x","y","title","rows"])],512)]),_:1},8,["title","subtitle","height","show-legend"]))}}),[["__scopeId","data-v-6e97c73e"]]);function C4(){let e=ki();return Q(()=>{let t=e==null?void 0:e.appContext.components;return(t==null?void 0:t.RouterLink)??(t==null?void 0:t["router-link"])??null})}var k4=function(e){return e.Button="button",e.Submit="submit",e.Reset="reset",e}(k4||{}),H9={key:0,class:"nb-button__decorations"},P9={key:0,class:"nb-button__spinner","aria-hidden":"true"},Bf=new Set;function O9(e){if(typeof e=="string")return e;if(e&&(typeof e=="object"||typeof e=="function")){let t=e;if(typeof t.glyphName=="string")return t.glyphName}return""}var oi=ht(Re({__name:"Button",props:{variant:{default:void 0},outlined:{type:Boolean,default:!1},size:{default:h4.Medium},disabled:{type:Boolean,default:!1},loading:{type:Boolean,default:!1},icon:{default:void 0},type:{default:k4.Button},href:{default:void 0},target:{default:void 0},rel:{default:void 0},to:{default:void 0}},emits:["click"],setup(e){let t=e,i=ks(),r=Q(()=>!i.default&&!!(t.icon||t.loading)),s=C4(),n=Q(()=>t.to!=null&&!!s.value),a=Q(()=>{if(typeof t.to=="string")return t.to;if(t.href)return t.href}),o=Q(()=>n.value?s.value:a.value?"a":"button"),l=Q(()=>o.value==="a"?{href:a.value,target:t.target,rel:t.rel}:{}),c={xxs:10,xs:12,sm:12,md:14,lg:16,xl:16,xxl:20},u={xxs:12,xs:14,sm:16,md:18,lg:20,xl:20,xxl:26},h=Q(()=>(r.value?u:c)[t.size??"md"]??(r.value?18:14)),d=ki();return ut(()=>{typeof process<"u"||r.value&&_i(()=>{var _;let f=(_=d==null?void 0:d.proxy)==null?void 0:_.$el;if(!f||typeof f.getAttribute!="function"||["aria-label","aria-labelledby","title"].some(y=>(f.getAttribute(y)??"").trim().length>0)||(f.textContent??"").trim().length>0)return;let m=O9(t.icon);Bf.has(m)||(Bf.add(m),console.warn(`[NbButton] An icon-only button${m?` (icon "${m}")`:""} has no accessible name, so a screen reader announces it as "button". Add aria-label, or name it with v-nb-tooltip.`,f))})}),(f,m)=>(g(),de(uc(o.value),Jt({class:["nb-button",e.variant?`nb-button--${e.variant}`:null,`nb-button--${e.size}`,{"nb-button--outlined":e.outlined},{"nb-button--loading":e.loading},{"nb-button--icon-only":r.value}],to:n.value?e.to:void 0},l.value,{disabled:o.value==="button"?e.disabled||e.loading:void 0,"aria-disabled":o.value!=="button"&&(e.disabled||e.loading)?!0:void 0,type:o.value==="button"?e.type:void 0,onClick:m[0]||(m[0]=_=>e.disabled||e.loading?void 0:f.$emit("click",_))}),{default:ee(()=>[Pe(f.$slots,"default",{},void 0,!0),e.loading||e.icon?(g(),E("div",H9,[e.loading?(g(),E("span",P9)):e.icon?(g(),de(Ge,{key:1,name:e.icon,size:h.value,class:"nb-button__icon"},null,8,["name","size"])):F("",!0)])):F("",!0)]),_:3},16,["class","to","disabled","aria-disabled","type"]))}}),[["__scopeId","data-v-a0e2a085"]]),A4=function(e){return e.Small="sm",e.Medium="md",e}(A4||{}),I9=["for"],R9={key:0,class:"nb-label__asterisk","aria-hidden":"true"},sa=ht(Re({__name:"Label",props:{htmlFor:{default:void 0},required:{type:Boolean,default:!1},disabled:{type:Boolean,default:!1},size:{default:A4.Medium}},setup(e){return(t,i)=>(g(),E("label",{for:e.htmlFor,class:xe(["nb-label",`nb-label--${e.size}`,{"nb-label--required":e.required,"nb-label--disabled":e.disabled}])},[Pe(t.$slots,"default",{},void 0,!0),e.required?(g(),E("span",R9,"*")):F("",!0),Pe(t.$slots,"suffix",{},void 0,!0)],10,I9))}}),[["__scopeId","data-v-836b13c6"]]),I0=function(e){return e.Error="error",e.Warning="warning",e.Success="success",e.Helper="helper",e}(I0||{}),D9=["aria-live"],V9={key:0,class:"nb-message__text"},B9={key:1,class:"nb-message__tooltip","aria-hidden":"true"},Qe=ht(Re({__name:"Message",props:{variant:{default:I0.Helper},iconOnly:{type:Boolean,default:!1}},setup(e){let t=e,i={error:_4,warning:w4,success:ud,helper:y4};return(r,s)=>(g(),E("div",{class:xe(["nb-message",`nb-message--${t.variant}`,{"nb-message--icon-only":t.iconOnly}]),role:"status","aria-live":t.variant==="error"?"assertive":"polite"},[Y(Ge,{name:i[t.variant],size:14,class:"nb-message__icon"},null,8,["name"]),t.iconOnly?F("",!0):(g(),E("span",V9,[Pe(r.$slots,"default",{},void 0,!0)])),t.iconOnly?(g(),E("span",B9,[Pe(r.$slots,"default",{},void 0,!0)])):F("",!0)],10,D9))}}),[["__scopeId","data-v-3b1f8105"]]),Qi=Re({__name:"Grid",props:{id:{type:String,default:null},is:{type:String,default:"div"},dir:{type:[String,Object,Function],default:"row",validator:e=>typeof e=="function"?!0:typeof e=="string"?["row","col","row-reverse","col-reverse"].includes(e):Object.values(e).every(t=>["row","col","row-reverse","col-reverse"].includes(t))},align:{type:[String,Object,Function],default:null,validator:e=>e==null||typeof e=="function"?!0:typeof e=="string"?["start","end","center","baseline","stretch"].includes(e):Object.values(e).every(t=>["start","end","center","baseline","stretch"].includes(t))},justify:{type:[String,Object,Function],default:null,validator:e=>e==null||typeof e=="function"?!0:typeof e=="string"?["around","between","center","end","evenly","start"].includes(e):Object.values(e).every(t=>["around","between","center","end","evenly","start"].includes(t))},gap:{type:[String,Object,Function],default:null,validator:e=>{if(e==null||typeof e=="function")return!0;let t=["xxs","xs","sm","md","lg","xl","xxl"];return typeof e=="string"?t.includes(e):Object.values(e).every(i=>t.includes(i))}},grid:{type:[Number,String,Object,Function],default:null,validator:e=>{if(e==null||typeof e=="function")return!0;let t=i=>{let r=typeof i=="string"?parseInt(i,10):i;return r>=1&&r<=16&&!isNaN(r)};return typeof e=="number"||typeof e=="string"?t(e):Object.values(e).every(t)}},shift:{type:[Number,String,Object,Function],default:null,validator:e=>{if(e==null||typeof e=="function")return!0;let t=i=>{let r=typeof i=="string"?parseInt(i,10):i;return r>=0&&r<=15&&!isNaN(r)};return typeof e=="number"||typeof e=="string"?t(e):Object.values(e).every(t)}},wrap:{type:[String,Object,Function],default:null,validator:e=>e==null||typeof e=="function"?!0:typeof e=="string"?["nowrap","wrap","reverse"].includes(e):Object.values(e).every(t=>["nowrap","wrap","reverse"].includes(t))},first:{type:[Boolean,Array],default:null,validator:e=>{if(e==null||typeof e=="boolean")return!0;let t=["sm","md","lg","xl","xxl"];return e.every(i=>t.includes(i))}},last:{type:[Boolean,Array],default:null,validator:e=>{if(e==null||typeof e=="boolean")return!0;let t=["sm","md","lg","xl","xxl"];return e.every(i=>t.includes(i))}},visible:{type:[Boolean,Object,Function],default:null},reverse:{type:[Boolean,Array],default:!1,validator:e=>{if(e==null||typeof e=="boolean")return!0;let t=["sm","md","lg","xl","xxl"];return e.every(i=>t.includes(i))}},grow:{type:Boolean,default:null},flex:{type:Boolean,default:null},shrink:{type:Boolean,default:null},distributed:{type:Boolean,default:!1},mode:{type:String,default:"wide",validator:e=>["wide","narrow","condensed"].includes(e)},tabIndex:{type:String,default:null}},setup(e,{expose:t}){let i=["a","button","input","textarea","select","details","iframe","object","embed","area","audio","video"],r=X();t({getRef:()=>r.value});let s=e,n=w=>w.replace(/([a-z])([A-Z])/g,"$1-$2").toLowerCase();function a(w,v){let{collection:k,breakpoint:$}=v,M=$?`${$}-`:"";$&&w==="row"||(k[`${M}${w}`]=!0)}function o(w,v){let{collection:k,breakpoint:$,classMap:M}=v,D=$?`${$}-`:"",H=(M==null?void 0:M[w])??w;k[`${D}align-${H}`]=!0}function l(w,v){let{collection:k,breakpoint:$,classMap:M}=v,D=$?`${$}-`:"",H=(M==null?void 0:M[w])??w;k[`${D}justify-${H}`]=!0}function c(w,v){let{collection:k,breakpoint:$}=v,M=$?`${$}-`:"";k[`${M}gap-${w}`]=!0}function u(w,v){let{collection:k,breakpoint:$}=v,M=$?`${$}-`:"";k[`${M}grid-${w}`]=!0}function h(w,v){let{collection:k,breakpoint:$}=v,M=$?`${$}-`:"";k[`${M}shift-${w}`]=!0}function d(w,v){let{collection:k,breakpoint:$}=v,M=$?`${$}-`:"";k[`${M}${w}`]=!0}function f(w,v){if(!w)return;let{collection:k,breakpoint:$}=v,M=$?`${$}-`:"";k[`${M}reverse`]=!0}function m(w,v,k){if(!w)return;let{collection:$,breakpoint:M}=v,D=M?`${M}-`:"";$[`${D}${k}`]=!0}function _(w,v){let{collection:k,breakpoint:$}=v,M=$?`${$}-`:"";k[`${M}${w?"visible":"hidden"}`]=!0}function y(w,v,k){let $={};if(w==null)return $;if(typeof w=="function"){let M=w();return M!=null&&v(M,{collection:$,classMap:k}),$}return typeof w=="string"||typeof w=="number"||typeof w=="boolean"?(v(w,{collection:$,classMap:k}),$):Array.isArray(w)?(w.forEach(M=>{v(!0,{collection:$,breakpoint:n(M),classMap:k})}),$):(typeof w=="object"&&Object.entries(w).forEach(([M,D])=>{D!=null&&v(D,{collection:$,breakpoint:n(M),classMap:k})}),$)}let p=w=>{let v={top:"start",bottom:"end",center:"center",stretch:"stretch",baseline:"base"},k={left:"start",right:"end",center:"center",between:"between",around:"around",evenly:"evenly"};return{"nb-grid":!0,...y(w.dir,a),...y(w.align,o,v),...y(w.justify,l,k),...y(w.gap,c),...y(w.grid,u),...y(w.shift,h),...y(w.wrap,d),...y(w.reverse,f),...y(w.first,($,M)=>m($,M,"first")),...y(w.last,($,M)=>m($,M,"last")),...y(w.visible,_),...w.flex?{flex:!0}:{},...w.distributed?{distributed:!0}:{},...w.mode?{[w.mode]:!0}:{},...w.grow?{grow:!0}:{},...w.shrink!==null&&w.shrink!==void 0?{[`shrink-${w.shrink?"1":"0"}`]:!0}:{}}},C=Q(()=>p(s));return(w,v)=>(g(),de(uc(w.is),{id:w.id,ref_key:"root",ref:r,class:xe(C.value),tabindex:w.tabIndex??!i.includes(w.is)?"-1":"0"},{default:ee(()=>[Pe(w.$slots,"default")]),_:3},8,["id","class","tabindex"]))}});const na=(e,t,i)=>{const r=s=>Me("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:t,fill:"currentColor",...s,innerHTML:i});return r.displayName="NbGlyph",r.glyphName=e,r},Z9=na("caret-left","0 0 256 256",'<path d="M162.83,205.17a4,4,0,0,1-5.66,5.66l-80-80a4,4,0,0,1,0-5.66l80-80a4,4,0,1,1,5.66,5.66L85.66,128Z"/>'),F9=na("caret-left","0 0 256 256",'<path d="M164.24,203.76a6,6,0,1,1-8.48,8.48l-80-80a6,6,0,0,1,0-8.48l80-80a6,6,0,0,1,8.48,8.48L88.49,128Z"/>'),Zf=na("caret-left","0 0 256 256",'<path d="M165.66,202.34a8,8,0,0,1-11.32,11.32l-80-80a8,8,0,0,1,0-11.32l80-80a8,8,0,0,1,11.32,11.32L91.31,128Z"/>'),z9=na("caret-left","0 0 256 256",'<path d="M168.49,199.51a12,12,0,0,1-17,17l-80-80a12,12,0,0,1,0-17l80-80a12,12,0,0,1,17,17L97,128Z"/>'),U9=na("caret-left","0 0 256 256",'<path d="M168,48V208a8,8,0,0,1-13.66,5.66l-80-80a8,8,0,0,1,0-11.32l80-80A8,8,0,0,1,168,48Z"/>'),W9=na("caret-left","0 0 256 256",'<path d="M160,48V208L80,128Z" opacity="0.2"/><path d="M163.06,40.61a8,8,0,0,0-8.72,1.73l-80,80a8,8,0,0,0,0,11.32l80,80A8,8,0,0,0,168,208V48A8,8,0,0,0,163.06,40.61ZM152,188.69,91.31,128,152,67.31Z"/>'),j9="caret-left",K9=Object.freeze(Object.defineProperty({__proto__:null,bold:z9,default:Zf,duotone:W9,fill:U9,glyphName:j9,light:F9,regular:Zf,thin:Z9},Symbol.toStringTag,{value:"Module"}));var q9=["width","height","role","aria-hidden","aria-labelledby","focusable"],G9=["id"],Y9=["id"],X9=["id"],J9=["id"],Q9=["id"],eC=["id"],tC=["id"],iC=["id"],rC=["id"],sC=["id"],nC={transform:"translate(-44.999 -33.192)scale(.92486)"},aC=["fill"],oC=["fill"],lC=["fill"],cC=["fill"],uC=["fill"],hC=["fill"],dC=["fill"],fC=["fill"],pC=["fill"],_C=["fill"],mC=["fill"],gC=["fill"],vC=Re({__name:"NubiscoPlatformMark",props:{size:{default:20},title:{default:void 0}},setup(e){let t=e,i=`nb-nubisco-platform-mark-${qi()}`,r=`${i}-title`,s=Q(()=>typeof t.size=="number"?`${t.size}px`:t.size);return(n,a)=>(g(),E("svg",{width:s.value,height:s.value,viewBox:"0 0 320 320",fill:"none",xmlns:"http://www.w3.org/2000/svg",role:t.title?"img":void 0,"aria-hidden":t.title?void 0:"true","aria-labelledby":t.title?r:void 0,focusable:t.title?void 0:"false"},[t.title?(g(),E("title",{key:0,id:r},Z(t.title),1)):F("",!0),b("defs",null,[b("linearGradient",{id:`${i}-a`,x1:"119.61",x2:"119.61",y1:"36.855",y2:"381.922",gradientTransform:"matrix(-.88714 -.4615 .40987 -.99917 140.112 473.946)",gradientUnits:"userSpaceOnUse",spreadMethod:"pad"},[...a[0]||(a[0]=[b("stop",{offset:"0","stop-color":"#c4b5fd"},null,-1),b("stop",{offset:".51","stop-color":"#8b5cf6"},null,-1),b("stop",{offset:"1","stop-color":"#4c1d95"},null,-1)])],8,G9),b("linearGradient",{id:`${i}-b`,x1:"143.989",x2:"143.989",y1:"36.855",y2:"179.9",gradientTransform:"rotate(27.476 159.702 130.504)scale(1 .92545)",gradientUnits:"userSpaceOnUse"},[...a[1]||(a[1]=[b("stop",{offset:"0","stop-opacity":".17"},null,-1),b("stop",{offset:"1","stop-opacity":".03"},null,-1)])],8,Y9),b("linearGradient",{id:`${i}-c`,x1:"91.703",x2:"91.703",y1:"328.267",y2:"381.922",gradientTransform:"matrix(-.60193 -.79855 1.25666 -1.08976 -307.908 812.885)",gradientUnits:"userSpaceOnUse"},[...a[2]||(a[2]=[b("stop",{offset:"0","stop-opacity":".38"},null,-1),b("stop",{offset:"1","stop-opacity":".2"},null,-1)])],8,X9),b("linearGradient",{id:`${i}-d`,x1:"348.688",x2:"348.688",y1:"35.889",y2:"116.548",gradientTransform:"rotate(239.754 337.588 85.06)scale(1 1.35453)",gradientUnits:"userSpaceOnUse"},[...a[3]||(a[3]=[b("stop",{offset:"0","stop-color":"#c7d2fe","stop-opacity":".56"},null,-1),b("stop",{offset:".745","stop-color":"#eef2ff"},null,-1),b("stop",{offset:"1","stop-color":"#eef2ff"},null,-1)])],8,J9),b("linearGradient",{id:`${i}-e`,x1:"338.142",x2:"338.142",y1:"47.006",y2:"121.215",gradientTransform:"rotate(41.017 403.561 105.221)scale(1 1.549)",gradientUnits:"userSpaceOnUse"},[...a[4]||(a[4]=[b("stop",{offset:"0","stop-color":"#fff","stop-opacity":".35"},null,-1),b("stop",{offset:".611","stop-color":"#fff","stop-opacity":".2"},null,-1),b("stop",{offset:".656","stop-color":"#fff","stop-opacity":".09"},null,-1),b("stop",{offset:"1","stop-color":"#fff","stop-opacity":".05"},null,-1)])],8,Q9),b("linearGradient",{id:`${i}-f`,x1:"286.279",x2:"286.279",y1:"128.145",y2:"381.893",gradientTransform:"matrix(.98012 -.1984 .20133 .99503 -34.837 58.725)",gradientUnits:"userSpaceOnUse"},[...a[5]||(a[5]=[b("stop",{offset:"0","stop-color":"#5e2178","stop-opacity":"0"},null,-1),b("stop",{offset:".23","stop-color":"#5e2174","stop-opacity":"0"},null,-1),b("stop",{offset:"1","stop-color":"#5e2077","stop-opacity":".77"},null,-1)])],8,eC),b("linearGradient",{id:`${i}-g`,x1:"220.396",x2:"220.396",y1:"36.815",y2:"381.893",gradientTransform:"matrix(.9096 -.4155 .45815 .99927 -61.508 91.882)",gradientUnits:"userSpaceOnUse"},[...a[6]||(a[6]=[b("stop",{offset:"0","stop-color":"#7dd3fc"},null,-1),b("stop",{offset:".5","stop-color":"#38bdf8"},null,-1),b("stop",{offset:"1","stop-color":"#4338ca"},null,-1)])],8,tC),b("linearGradient",{id:`${i}-h`,x1:"197.5",x2:"197.5",y1:"36.815",y2:"132.342",gradientTransform:"rotate(-65.21 176.696 92.616)scale(1 1.1573)",gradientUnits:"userSpaceOnUse"},[...a[7]||(a[7]=[b("stop",{offset:"0","stop-color":"#fff","stop-opacity":".45"},null,-1),b("stop",{offset:"1","stop-color":"#60a5fa","stop-opacity":".85"},null,-1)])],8,iC),b("linearGradient",{id:`${i}-i`,x1:"197.5",x2:"197.5",y1:"59.48",y2:"132.342",gradientTransform:"rotate(-63.231 113.999 150.221)scale(1 2.11347)",gradientUnits:"userSpaceOnUse"},[...a[8]||(a[8]=[b("stop",{offset:"0","stop-color":"#fff","stop-opacity":".6"},null,-1),b("stop",{offset:".461","stop-color":"#fff","stop-opacity":".71"},null,-1),b("stop",{offset:"1","stop-color":"#fff","stop-opacity":".82"},null,-1)])],8,rC),b("linearGradient",{id:`${i}-j`,x1:"258.091",x2:"258.091",y1:"319.547",y2:"338.393",gradientTransform:"rotate(-80.06 -339.105 833.104)scale(1 4.05965)",gradientUnits:"userSpaceOnUse"},[...a[9]||(a[9]=[b("stop",{offset:"0","stop-color":"#60a5fa","stop-opacity":".96"},null,-1),b("stop",{offset:".493","stop-color":"#60a5fa","stop-opacity":".74"},null,-1),b("stop",{offset:"1","stop-color":"#60a5fa","stop-opacity":".34"},null,-1)])],8,sC)]),b("g",nC,[b("g",null,[b("path",{fill:`url(#${i}-a)`,d:"M48.655 381.922c71.172-124.782 3.049-340.71 141.911-345.067C173.148 402.723 82.723 380.123 48.655 381.922"},null,8,aC),b("path",{fill:`url(#${i}-b)`,d:"M177.776 179.9c-57.288-128.188-80.363-36.931-80.363-36.931 10.255-59.703 30.912-104.161 93.153-106.114-2.686 56.413-7.107 103.59-12.79 143.045"},null,8,oC),b("path",{fill:`url(#${i}-c)`,d:"M48.655 381.922c9.423-16.521 16.405-34.64 21.748-53.655 17.691 18.395 64.349 3.674 64.349 3.674-31.373 55.419-67.307 48.989-86.097 49.981"},null,8,lC),a[10]||(a[10]=b("path",{fill:"#e0e7ff",d:"M134.752 331.941c-13.63 5.995-53.201 12.838-64.349-3.674 17.691 18.395 64.349 3.674 64.349 3.674"},null,-1))]),b("g",null,[b("path",{fill:`url(#${i}-a)`,d:"M313.875 381.893c-25.777 0-45.248-6.416-60.124-17.427C216.182 182.535 312.866 21.948 394.655 36.85c-59.316 122.24-44.489 345.043-80.78 345.043"},null,8,cC),b("path",{fill:`url(#${i}-d)`,d:"M367.694 116.548s-15.167-41.655-64.974-28.547c27.276-36.929 60.692-56.843 91.935-51.151-11.449 23.594-20.136 50.935-26.961 79.698"},null,8,uC),a[11]||(a[11]=b("path",{fill:"#fff","fill-opacity":".46",d:"M367.694 116.548s-15.167-41.655-64.974-28.547c49.49-16.872 64.974 28.547 64.974 28.547"},null,-1)),b("path",{fill:`url(#${i}-e)`,d:"M384.493 47.025c-48.94 7.777-92.702 74.19-92.702 74.19s35.018-75.588 92.702-74.19"},null,8,hC),b("path",{fill:`url(#${i}-f)`,d:"M313.875 381.893c-25.777 0-45.248-6.416-60.124-17.427-18.652-90.322-4.213-175.383 25.064-236.321 12.184 33.435 19.638 221.543 48.343 239.852-3.562 8.902-7.85 13.896-13.283 13.896"},null,8,dC)]),b("path",{fill:`url(#${i}-g)`,d:"M313.875 381.893c-174.222 0-60.342-293.107-186.959-316.694 14.13-17.017 33.938-27.461 63.337-28.384 121.142 11.21 61.419 240.042 123.622 345.078"},null,8,fC),b("path",{fill:`url(#${i}-h)`,d:"M268.085 132.342s-61.681-68.748-141.169-67.143c14.13-17.017 33.938-27.461 63.337-28.384 48.292 4.469 67.842 43.521 77.832 95.527"},null,8,pC),b("path",{fill:`url(#${i}-i)`,d:"M268.085 132.342s-61.681-68.748-141.169-67.143c56.3-1.878 104.887 28.123 141.169 67.143"},null,8,_C),b("path",{fill:`url(#${i}-c)`,d:"M313.875 381.893c-51.52 0-77.847-25.632-92.648-62.346 37.447 29.88 73.274 13.505 73.727 15.194 4.654 17.344 10.73 33.322 18.921 47.152"},null,8,mC),b("path",{fill:`url(#${i}-j)`,d:"M294.954 334.741c-23.352 6.999-50.621 5.603-73.727-15.194 37.447 29.88 73.274 13.505 73.727 15.194"},null,8,gC),a[12]||(a[12]=b("path",{fill:"#fff","fill-opacity":".11",d:"M164.386 48.742c79.985-4.198 103.959 141.977 103.959 141.977C249.39 92.792 222.974 38.013 164.386 48.742"},null,-1))])],8,q9))}});function bC(e,t){typeof console<"u"&&(console.warn("[intlify] "+e),t&&console.warn(t.stack))}var Ff=typeof window<"u",on=(e,t=!1)=>t?Symbol.for(e):Symbol(e),yC=(e,t,i)=>wC({l:e,k:t,s:i}),wC=e=>JSON.stringify(e).replace(/\u2028/g,"\\u2028").replace(/\u2029/g,"\\u2029").replace(/\u0027/g,"\\u0027"),Qt=e=>typeof e=="number"&&isFinite(e),M4=e=>md(e)==="[object Date]",R0=e=>md(e)==="[object RegExp]",yc=e=>ft(e)&&Object.keys(e).length===0,Si=Object.assign,SC=Object.create,Pt=(e=null)=>SC(e),CC,Ks=()=>CC||(CC=typeof globalThis<"u"?globalThis:typeof self<"u"?self:typeof window<"u"?window:typeof global<"u"?global:Pt());function zf(e){return e.replace(/&/g,"&").replace(/</g,"<").replace(/>/g,">").replace(/"/g,""").replace(/'/g,"'").replace(/\//g,"/").replace(/=/g,"=")}function Uf(e){return e.replace(/&(?![a-zA-Z0-9#]{2,6};)/g,"&").replace(/"/g,""").replace(/'/g,"'").replace(/</g,"<").replace(/>/g,">")}function kC(e){return e=e.replace(/(\w+)\s*=\s*"([^"]*)"/g,(t,i,r)=>`${i}="${Uf(r)}"`),e=e.replace(/(\w+)\s*=\s*'([^']*)'/g,(t,i,r)=>`${i}='${Uf(r)}'`),/\s*on\w+\s*=\s*["']?[^"'>]+["']?/gi.test(e)&&(e=e.replace(/(\s+)(on)(\w+\s*=)/gi,"$1on$3")),[/(\s+(?:href|src|action|formaction)\s*=\s*["']?)\s*javascript:/gi,/(style\s*=\s*["'][^"']*url\s*\(\s*)javascript:/gi].forEach(t=>{e=e.replace(t,"$1javascript:")}),e}var AC=Object.prototype.hasOwnProperty;function Wi(e,t){return AC.call(e,t)}var zt=Array.isArray,$t=e=>typeof e=="function",De=e=>typeof e=="string",Ht=e=>typeof e=="boolean",_t=e=>typeof e=="object"&&!!e,MC=e=>_t(e)&&$t(e.then)&&$t(e.catch),L4=Object.prototype.toString,md=e=>L4.call(e),ft=e=>md(e)==="[object Object]",LC=e=>e==null?"":zt(e)||ft(e)&&e.toString===L4?JSON.stringify(e,null,2):String(e);function gd(e,t=""){return e.reduce((i,r,s)=>s===0?i+r:i+t+r,"")}var Zl=e=>!_t(e)||zt(e);function o0(e,t){if(Zl(e)||Zl(t))throw Error("Invalid value");let i=[{src:e,des:t}];for(;i.length;){let{src:r,des:s}=i.pop();Object.keys(r).forEach(n=>{n!=="__proto__"&&(_t(r[n])&&!_t(s[n])&&(s[n]=Array.isArray(r[n])?[]:Pt()),Zl(s[n])||Zl(r[n])?s[n]=r[n]:i.push({src:r[n],des:s[n]}))})}}function EC(e,t,i){return{line:e,column:t,offset:i}}function Su(e,t,i){return{start:e,end:t}}var st={EXPECTED_TOKEN:1,INVALID_TOKEN_IN_PLACEHOLDER:2,UNTERMINATED_SINGLE_QUOTE_IN_PLACEHOLDER:3,UNKNOWN_ESCAPE_SEQUENCE:4,INVALID_UNICODE_ESCAPE_SEQUENCE:5,UNBALANCED_CLOSING_BRACE:6,UNTERMINATED_CLOSING_BRACE:7,EMPTY_PLACEHOLDER:8,NOT_ALLOW_NEST_PLACEHOLDER:9,INVALID_LINKED_FORMAT:10,MUST_HAVE_MESSAGES_IN_PLURAL:11,UNEXPECTED_EMPTY_LINKED_MODIFIER:12,UNEXPECTED_EMPTY_LINKED_KEY:13,UNEXPECTED_LEXICAL_ANALYSIS:14};function wc(e,t,i={}){let{domain:r,messages:s,args:n}=i,a=e,o=SyntaxError(String(a));return o.code=e,t&&(o.location=t),o.domain=r,o}function $C(e){throw e}var or=" ",xC="\r",bi=`
|
|
40
|
-
`,TC="\u2028",NC="\u2029";function HC(e){let t=e,i=0,r=1,s=1,n=0,a=M=>t[M]===xC&&t[M+1]===bi,o=M=>t[M]===bi,l=M=>t[M]===NC,c=M=>t[M]===TC,u=M=>a(M)||o(M)||l(M)||c(M),h=()=>i,d=()=>r,f=()=>s,m=()=>n,_=M=>a(M)||l(M)||c(M)?bi:t[M],y=()=>_(i),p=()=>_(i+n);function C(){return n=0,u(i)&&(r++,s=0),a(i)&&i++,i++,s++,t[i]}function w(){return a(i+n)&&n++,n++,t[i+n]}function v(){i=0,r=1,s=1,n=0}function k(M=0){n=M}function $(){let M=i+n;for(;M!==i;)C();n=0}return{index:h,line:d,column:f,peekOffset:m,charAt:_,currentChar:y,currentPeek:p,next:C,peek:w,reset:v,resetPeek:k,skipToPeek:$}}var Nr=void 0,Wf="'",PC="tokenizer";function OC(e,t={}){let i=t.location!==!1,r=HC(e),s=()=>r.index(),n=()=>EC(r.line(),r.column(),r.index()),a=n(),o=s(),l={currentType:13,offset:o,startLoc:a,endLoc:a,lastType:13,lastOffset:o,lastStartLoc:a,lastEndLoc:a,braceNest:0,inLinked:!1,text:""},c=()=>l,{onError:u}=t;function h(S,A,B,...L){let I=c();A.column+=B,A.offset+=B,u&&u(wc(S,i?Su(I.startLoc,A):null,{domain:PC,args:L}))}function d(S,A,B){S.endLoc=n(),S.currentType=A;let L={type:A};return i&&(L.loc=Su(S.startLoc,S.endLoc)),B!=null&&(L.value=B),L}let f=S=>d(S,13);function m(S,A){return S.currentChar()===A?(S.next(),A):(h(st.EXPECTED_TOKEN,n(),0,A),"")}function _(S){let A="";for(;S.currentPeek()===or||S.currentPeek()===bi;)A+=S.currentPeek(),S.peek();return A}function y(S){let A=_(S);return S.skipToPeek(),A}function p(S){if(S===Nr)return!1;let A=S.charCodeAt(0);return A>=97&&A<=122||A>=65&&A<=90||A===95}function C(S){if(S===Nr)return!1;let A=S.charCodeAt(0);return A>=48&&A<=57}function w(S,A){let{currentType:B}=A;if(B!==2)return!1;_(S);let L=p(S.currentPeek());return S.resetPeek(),L}function v(S,A){let{currentType:B}=A;if(B!==2)return!1;_(S);let L=C(S.currentPeek()==="-"?S.peek():S.currentPeek());return S.resetPeek(),L}function k(S,A){let{currentType:B}=A;if(B!==2)return!1;_(S);let L=S.currentPeek()===Wf;return S.resetPeek(),L}function $(S,A){let{currentType:B}=A;if(B!==7)return!1;_(S);let L=S.currentPeek()===".";return S.resetPeek(),L}function M(S,A){let{currentType:B}=A;if(B!==8)return!1;_(S);let L=p(S.currentPeek());return S.resetPeek(),L}function D(S,A){let{currentType:B}=A;if(!(B===7||B===11))return!1;_(S);let L=S.currentPeek()===":";return S.resetPeek(),L}function H(S,A){let{currentType:B}=A;if(B!==9)return!1;let L=()=>{let z=S.currentPeek();return z==="{"?p(S.peek()):z==="@"||z==="|"||z===":"||z==="."||z===or||!z?!1:z===bi?(S.peek(),L()):V(S,!1)},I=L();return S.resetPeek(),I}function R(S){_(S);let A=S.currentPeek()==="|";return S.resetPeek(),A}function V(S,A=!0){let B=(I=!1,z="")=>{let W=S.currentPeek();return W==="{"||W==="@"||!W?I:W==="|"?!(z===or||z===bi):W===or?(S.peek(),B(!0,or)):W===bi?(S.peek(),B(!0,bi)):!0},L=B();return A&&S.resetPeek(),L}function N(S,A){let B=S.currentChar();return B===Nr?Nr:A(B)?(S.next(),B):null}function P(S){let A=S.charCodeAt(0);return A>=97&&A<=122||A>=65&&A<=90||A>=48&&A<=57||A===95||A===36}function U(S){return N(S,P)}function j(S){let A=S.charCodeAt(0);return A>=97&&A<=122||A>=65&&A<=90||A>=48&&A<=57||A===95||A===36||A===45}function oe(S){return N(S,j)}function te(S){let A=S.charCodeAt(0);return A>=48&&A<=57}function ne(S){return N(S,te)}function J(S){let A=S.charCodeAt(0);return A>=48&&A<=57||A>=65&&A<=70||A>=97&&A<=102}function fe(S){return N(S,J)}function re(S){let A="",B="";for(;A=ne(S);)B+=A;return B}function _e(S){let A="";for(;;){let B=S.currentChar();if(B==="\\"){let L=S.peek();L==="{"||L==="}"||L==="@"||L==="|"||L==="\\"?(A+=B+L,S.next(),S.next()):(S.resetPeek(),A+=B,S.next())}else{if(B==="{"||B==="}"||B==="@"||B==="|"||!B)break;if(B===or||B===bi)if(V(S))A+=B,S.next();else{if(R(S))break;A+=B,S.next()}else A+=B,S.next()}}return A}function Ne(S){y(S);let A="",B="";for(;A=oe(S);)B+=A;let L=S.currentChar();if(L&&L!=="}"&&L!==Nr&&L!==or&&L!==bi&&L!==" "){let I=ge(S);return h(st.INVALID_TOKEN_IN_PLACEHOLDER,n(),0,B+I),B+I}return S.currentChar()===Nr&&h(st.UNTERMINATED_CLOSING_BRACE,n(),0),B}function $e(S){y(S);let A="";return S.currentChar()==="-"?(S.next(),A+=`-${re(S)}`):A+=re(S),S.currentChar()===Nr&&h(st.UNTERMINATED_CLOSING_BRACE,n(),0),A}function be(S){return S!==Wf&&S!==bi}function me(S){y(S),m(S,"'");let A="",B="";for(;A=N(S,be);)A==="\\"?B+=O(S):B+=A;let L=S.currentChar();return L===bi||L===Nr?(h(st.UNTERMINATED_SINGLE_QUOTE_IN_PLACEHOLDER,n(),0),L===bi&&(S.next(),m(S,"'")),B):(m(S,"'"),B)}function O(S){let A=S.currentChar();switch(A){case"\\":case"'":return S.next(),`\\${A}`;case"u":return ie(S,A,4);case"U":return ie(S,A,6);default:return h(st.UNKNOWN_ESCAPE_SEQUENCE,n(),0,A),""}}function ie(S,A,B){m(S,A);let L="";for(let I=0;I<B;I++){let z=fe(S);if(!z){h(st.INVALID_UNICODE_ESCAPE_SEQUENCE,n(),0,`\\${A}${L}${S.currentChar()}`);break}L+=z}return`\\${A}${L}`}function le(S){return S!=="{"&&S!=="}"&&S!==or&&S!==bi}function ge(S){y(S);let A="",B="";for(;A=N(S,le);)B+=A;return B}function Se(S){let A="",B="";for(;A=U(S);)B+=A;return B}function x(S){let A=B=>{let L=S.currentChar();return L==="{"||L==="@"||L==="|"||L==="("||L===")"||!L||L===or?B:(B+=L,S.next(),A(B))};return A("")}function T(S){y(S);let A=m(S,"|");return y(S),A}function K(S,A){let B=null;switch(S.currentChar()){case"{":return A.braceNest>=1&&h(st.NOT_ALLOW_NEST_PLACEHOLDER,n(),0),S.next(),B=d(A,2,"{"),y(S),A.braceNest++,B;case"}":return A.braceNest>0&&A.currentType===2&&h(st.EMPTY_PLACEHOLDER,n(),0),S.next(),B=d(A,3,"}"),A.braceNest--,A.braceNest>0&&y(S),A.inLinked&&A.braceNest===0&&(A.inLinked=!1),B;case"@":return A.braceNest>0&&h(st.UNTERMINATED_CLOSING_BRACE,n(),0),B=se(S,A)||f(A),A.braceNest=0,B;default:{let L=!0,I=!0,z=!0;if(R(S))return A.braceNest>0&&h(st.UNTERMINATED_CLOSING_BRACE,n(),0),B=d(A,1,T(S)),A.braceNest=0,A.inLinked=!1,B;if(A.braceNest>0&&(A.currentType===4||A.currentType===5||A.currentType===6))return h(st.UNTERMINATED_CLOSING_BRACE,n(),0),A.braceNest=0,he(S,A);if(L=w(S,A))return B=d(A,4,Ne(S)),y(S),B;if(I=v(S,A))return B=d(A,5,$e(S)),y(S),B;if(z=k(S,A))return B=d(A,6,me(S)),y(S),B;if(!L&&!I&&!z)return B=d(A,12,ge(S)),h(st.INVALID_TOKEN_IN_PLACEHOLDER,n(),0,B.value),y(S),B;break}}return B}function se(S,A){let{currentType:B}=A,L=null,I=S.currentChar();switch((B===7||B===8||B===11||B===9)&&(I===bi||I===or)&&h(st.INVALID_LINKED_FORMAT,n(),0),I){case"@":return S.next(),L=d(A,7,"@"),A.inLinked=!0,L;case".":return y(S),S.next(),d(A,8,".");case":":return y(S),S.next(),d(A,9,":");default:return R(S)?(L=d(A,1,T(S)),A.braceNest=0,A.inLinked=!1,L):$(S,A)||D(S,A)?(y(S),se(S,A)):M(S,A)?(y(S),d(A,11,Se(S))):H(S,A)?(y(S),I==="{"?K(S,A)||L:d(A,10,x(S))):(B===7&&h(st.INVALID_LINKED_FORMAT,n(),0),A.braceNest=0,A.inLinked=!1,he(S,A))}}function he(S,A){let B={type:13};if(A.braceNest>0)return K(S,A)||f(A);if(A.inLinked)return se(S,A)||f(A);switch(S.currentChar()){case"{":return K(S,A)||f(A);case"}":return h(st.UNBALANCED_CLOSING_BRACE,n(),0),S.next(),d(A,3,"}");case"@":return se(S,A)||f(A);default:if(R(S))return B=d(A,1,T(S)),A.braceNest=0,A.inLinked=!1,B;if(V(S))return d(A,0,_e(S));break}return B}function pe(){let{currentType:S,offset:A,startLoc:B,endLoc:L}=l;return l.lastType=S,l.lastOffset=A,l.lastStartLoc=B,l.lastEndLoc=L,l.offset=s(),l.startLoc=n(),r.currentChar()===Nr?d(l,13):he(r,l)}return{nextToken:pe,currentOffset:s,currentPosition:n,context:c}}var IC="parser",RC=/(?:\\\\|\\'|\\u([0-9a-fA-F]{4})|\\U([0-9a-fA-F]{6}))/g,DC=/\\([\\@{}|])/g;function VC(e,t){return t}function BC(e,t,i){switch(e){case"\\\\":return"\\";case"\\'":return"'";default:{let r=parseInt(t||i,16);return r<=55295||r>=57344?String.fromCodePoint(r):"�"}}}function ZC(e={}){let t=e.location!==!1,{onError:i}=e;function r(p,C,w,v,...k){let $=p.currentPosition();$.offset+=v,$.column+=v,i&&i(wc(C,t?Su(w,$):null,{domain:IC,args:k}))}function s(p,C,w){let v={type:p};return t&&(v.start=C,v.end=C,v.loc={start:w,end:w}),v}function n(p,C,w,v){t&&(p.end=C,p.loc&&(p.loc.end=w))}function a(p,C){let w=p.context(),v=s(3,w.offset,w.startLoc);return v.value=C.replace(DC,VC),n(v,p.currentOffset(),p.currentPosition()),v}function o(p,C){let{lastOffset:w,lastStartLoc:v}=p.context(),k=s(5,w,v);return k.index=parseInt(C,10),p.nextToken(),n(k,p.currentOffset(),p.currentPosition()),k}function l(p,C){let{lastOffset:w,lastStartLoc:v}=p.context(),k=s(4,w,v);return k.key=C,p.nextToken(),n(k,p.currentOffset(),p.currentPosition()),k}function c(p,C){let{lastOffset:w,lastStartLoc:v}=p.context(),k=s(9,w,v);return k.value=C.replace(RC,BC),p.nextToken(),n(k,p.currentOffset(),p.currentPosition()),k}function u(p){let C=p.nextToken(),w=p.context(),{lastOffset:v,lastStartLoc:k}=w,$=s(8,v,k);return C.type===11?(C.value??r(p,st.UNEXPECTED_LEXICAL_ANALYSIS,w.lastStartLoc,0,lr(C)),$.value=C.value||"",n($,p.currentOffset(),p.currentPosition()),{node:$}):(r(p,st.UNEXPECTED_EMPTY_LINKED_MODIFIER,w.lastStartLoc,0),$.value="",n($,v,k),{nextConsumeToken:C,node:$})}function h(p,C){let w=p.context(),v=s(7,w.offset,w.startLoc);return v.value=C,n(v,p.currentOffset(),p.currentPosition()),v}function d(p){let C=p.context(),w=s(6,C.offset,C.startLoc),v=p.nextToken();if(v.type===8){let k=u(p);w.modifier=k.node,v=k.nextConsumeToken||p.nextToken()}switch(v.type!==9&&r(p,st.UNEXPECTED_LEXICAL_ANALYSIS,C.lastStartLoc,0,lr(v)),v=p.nextToken(),v.type===2&&(v=p.nextToken()),v.type){case 10:v.value??r(p,st.UNEXPECTED_LEXICAL_ANALYSIS,C.lastStartLoc,0,lr(v)),w.key=h(p,v.value||"");break;case 4:v.value??r(p,st.UNEXPECTED_LEXICAL_ANALYSIS,C.lastStartLoc,0,lr(v)),w.key=l(p,v.value||"");break;case 5:v.value??r(p,st.UNEXPECTED_LEXICAL_ANALYSIS,C.lastStartLoc,0,lr(v)),w.key=o(p,v.value||"");break;case 6:v.value??r(p,st.UNEXPECTED_LEXICAL_ANALYSIS,C.lastStartLoc,0,lr(v)),w.key=c(p,v.value||"");break;default:{r(p,st.UNEXPECTED_EMPTY_LINKED_KEY,C.lastStartLoc,0);let k=p.context(),$=s(7,k.offset,k.startLoc);return $.value="",n($,k.offset,k.startLoc),w.key=$,n(w,k.offset,k.startLoc),{nextConsumeToken:v,node:w}}}return n(w,p.currentOffset(),p.currentPosition()),{node:w}}function f(p){let C=p.context(),w=s(2,C.currentType===1?p.currentOffset():C.offset,C.currentType===1?C.endLoc:C.startLoc);w.items=[];let v=null;do{let k=v||p.nextToken();switch(v=null,k.type){case 0:k.value??r(p,st.UNEXPECTED_LEXICAL_ANALYSIS,C.lastStartLoc,0,lr(k)),w.items.push(a(p,k.value||""));break;case 5:k.value??r(p,st.UNEXPECTED_LEXICAL_ANALYSIS,C.lastStartLoc,0,lr(k)),w.items.push(o(p,k.value||""));break;case 4:k.value??r(p,st.UNEXPECTED_LEXICAL_ANALYSIS,C.lastStartLoc,0,lr(k)),w.items.push(l(p,k.value||""));break;case 6:k.value??r(p,st.UNEXPECTED_LEXICAL_ANALYSIS,C.lastStartLoc,0,lr(k)),w.items.push(c(p,k.value||""));break;case 7:{let $=d(p);w.items.push($.node),v=$.nextConsumeToken||null;break}}}while(C.currentType!==13&&C.currentType!==1);return n(w,C.currentType===1?C.lastOffset:p.currentOffset(),C.currentType===1?C.lastEndLoc:p.currentPosition()),w}function m(p,C,w,v){let k=p.context(),$=v.items.length===0,M=s(1,C,w);M.cases=[],M.cases.push(v);do{let D=f(p);$||($=D.items.length===0),M.cases.push(D)}while(k.currentType!==13);return $&&r(p,st.MUST_HAVE_MESSAGES_IN_PLURAL,w,0),n(M,p.currentOffset(),p.currentPosition()),M}function _(p){let C=p.context(),{offset:w,startLoc:v}=C,k=f(p);return C.currentType===13?k:m(p,w,v,k)}function y(p){let C=OC(p,Si({},e)),w=C.context(),v=s(0,w.offset,w.startLoc);return t&&v.loc&&(v.loc.source=p),v.body=_(C),e.onCacheKey&&(v.cacheKey=e.onCacheKey(p)),w.currentType!==13&&r(C,st.UNEXPECTED_LEXICAL_ANALYSIS,w.lastStartLoc,0,p[w.offset]||""),n(v,C.currentOffset(),C.currentPosition()),v}return{parse:y}}function lr(e){if(e.type===13)return"EOF";let t=(e.value||"").replace(/\r?\n/gu,"\\n");return t.length>10?t.slice(0,9)+"…":t}function FC(e,t={}){let i={ast:e,helpers:new Set};return{context:()=>i,helper:r=>(i.helpers.add(r),r)}}function jf(e,t){for(let i=0;i<e.length;i++)vd(e[i],t)}function vd(e,t){switch(e.type){case 1:jf(e.cases,t),t.helper("plural");break;case 2:jf(e.items,t);break;case 6:vd(e.key,t),t.helper("linked"),t.helper("type");break;case 5:t.helper("interpolate"),t.helper("list");break;case 4:t.helper("interpolate"),t.helper("named");break}}function zC(e,t={}){let i=FC(e);i.helper("normalize"),e.body&&vd(e.body,i);let r=i.context();e.helpers=Array.from(r.helpers)}function UC(e){let t=e.body;return t.type===2?Kf(t):t.cases.forEach(i=>Kf(i)),e}function Kf(e){if(e.items.length===1){let t=e.items[0];(t.type===3||t.type===9)&&(e.static=t.value,delete t.value)}else{let t=[];for(let i=0;i<e.items.length;i++){let r=e.items[i];if(!(r.type===3||r.type===9)||r.value==null)break;t.push(r.value)}if(t.length===e.items.length){e.static=gd(t);for(let i=0;i<e.items.length;i++){let r=e.items[i];(r.type===3||r.type===9)&&delete r.value}}}}function yn(e){switch(e.t=e.type,e.type){case 0:{let t=e;yn(t.body),t.b=t.body,delete t.body;break}case 1:{let t=e,i=t.cases;for(let r=0;r<i.length;r++)yn(i[r]);t.c=i,delete t.cases;break}case 2:{let t=e,i=t.items;for(let r=0;r<i.length;r++)yn(i[r]);t.i=i,delete t.items,t.static&&(t.s=t.static,delete t.static);break}case 3:case 9:case 8:case 7:{let t=e;t.value&&(t.v=t.value,delete t.value);break}case 6:{let t=e;yn(t.key),t.k=t.key,delete t.key,t.modifier&&(yn(t.modifier),t.m=t.modifier,delete t.modifier);break}case 5:{let t=e;t.i=t.index,delete t.index;break}case 4:{let t=e;t.k=t.key,delete t.key;break}}delete e.type}function WC(e,t){let{filename:i,breakLineCode:r,needIndent:s}=t,n=t.location!==!1,a={filename:i,code:"",column:1,line:1,offset:0,map:void 0,breakLineCode:r,needIndent:s,indentLevel:0};n&&e.loc&&(a.source=e.loc.source);let o=()=>a;function l(f,m){a.code+=f}function c(f,m=!0){let _=m?r:"";l(s?_+" ".repeat(f):_)}function u(f=!0){let m=++a.indentLevel;f&&c(m)}function h(f=!0){let m=--a.indentLevel;f&&c(m)}function d(){c(a.indentLevel)}return{context:o,push:l,indent:u,deindent:h,newline:d,helper:f=>`_${f}`,needIndent:()=>a.needIndent}}function jC(e,t){let{helper:i}=e;e.push(`${i("linked")}(`),Rn(e,t.key),t.modifier?(e.push(", "),Rn(e,t.modifier),e.push(", _type")):e.push(", undefined, _type"),e.push(")")}function KC(e,t){let{helper:i,needIndent:r}=e;e.push(`${i("normalize")}([`),e.indent(r());let s=t.items.length;for(let n=0;n<s&&(Rn(e,t.items[n]),n!==s-1);n++)e.push(", ");e.deindent(r()),e.push("])")}function qC(e,t){let{helper:i,needIndent:r}=e;if(t.cases.length>1){e.push(`${i("plural")}([`),e.indent(r());let s=t.cases.length;for(let n=0;n<s&&(Rn(e,t.cases[n]),n!==s-1);n++)e.push(", ");e.deindent(r()),e.push("])")}}function GC(e,t){t.body?Rn(e,t.body):e.push("null")}function Rn(e,t){let{helper:i}=e;switch(t.type){case 0:GC(e,t);break;case 1:qC(e,t);break;case 2:KC(e,t);break;case 6:jC(e,t);break;case 8:e.push(JSON.stringify(t.value),t);break;case 7:e.push(JSON.stringify(t.value),t);break;case 5:e.push(`${i("interpolate")}(${i("list")}(${t.index}))`,t);break;case 4:e.push(`${i("interpolate")}(${i("named")}(${JSON.stringify(t.key)}))`,t);break;case 9:e.push(JSON.stringify(t.value),t);break;case 3:e.push(JSON.stringify(t.value),t);break}}var YC=(e,t={})=>{let i=De(t.mode)?t.mode:"normal",r=De(t.filename)?t.filename:"message.intl";t.sourceMap;let s=t.breakLineCode==null?i==="arrow"?";":`
|
|
41
|
-
`:t.breakLineCode,n=t.needIndent?t.needIndent:i!=="arrow",a=e.helpers||[],o=WC(e,{filename:r,breakLineCode:s,needIndent:n});o.push(i==="normal"?"function __msg__ (ctx) {":"(ctx) => {"),o.indent(n),a.length>0&&(o.push(`const { ${gd(a.map(u=>`${u}: _${u}`),", ")} } = ctx`),o.newline()),o.push("return "),Rn(o,e),o.deindent(n),o.push("}"),delete e.helpers;let{code:l,map:c}=o.context();return{ast:e,code:l,map:c?c.toJSON():void 0}};function XC(e,t={}){let i=Si({},t),r=!!i.jit,s=!!i.minify,n=i.optimize==null?!0:i.optimize,a=ZC(i).parse(e);return r?(n&&UC(a),s&&yn(a),{ast:a,code:""}):(zC(a,i),YC(a,i))}function JC(){typeof __INTLIFY_PROD_DEVTOOLS__!="boolean"&&(Ks().__INTLIFY_PROD_DEVTOOLS__=!1),typeof __INTLIFY_DROP_MESSAGE_COMPILER__!="boolean"&&(Ks().__INTLIFY_DROP_MESSAGE_COMPILER__=!1)}function Cr(e){return _t(e)&&bd(e)===0&&(Wi(e,"b")||Wi(e,"body"))}var E4=["b","body"];function QC(e){return $s(e,E4)}var $4=["c","cases"];function ek(e){return $s(e,$4,[])}var x4=["s","static"];function tk(e){return $s(e,x4)}var T4=["i","items"];function ik(e){return $s(e,T4,[])}var N4=["t","type"];function bd(e){return $s(e,N4)}var H4=["v","value"];function Fl(e,t){let i=$s(e,H4);if(i!=null)return i;throw sl(t)}var P4=["m","modifier"];function rk(e){return $s(e,P4)}var O4=["k","key"];function sk(e){let t=$s(e,O4);if(t)return t;throw sl(6)}function $s(e,t,i){for(let r=0;r<t.length;r++){let s=t[r];if(Wi(e,s)&&e[s]!=null)return e[s]}return i}var I4=[...E4,...$4,...x4,...T4,...O4,...P4,...H4,...N4];function sl(e){return Error(`unhandled node type: ${e}`)}function o1(e){return t=>nk(t,e)}function nk(e,t){let i=QC(t);if(i==null)throw sl(0);if(bd(i)===1){let r=ek(i);return e.plural(r.reduce((s,n)=>[...s,qf(e,n)],[]))}else return qf(e,i)}function qf(e,t){let i=tk(t);if(i!=null)return e.type==="text"?i:e.normalize([i]);{let r=ik(t).reduce((s,n)=>[...s,Cu(e,n)],[]);return e.normalize(r)}}function Cu(e,t){let i=bd(t);switch(i){case 3:return Fl(t,i);case 9:return Fl(t,i);case 4:{let r=t;if(Wi(r,"k")&&r.k)return e.interpolate(e.named(r.k));if(Wi(r,"key")&&r.key)return e.interpolate(e.named(r.key));throw sl(i)}case 5:{let r=t;if(Wi(r,"i")&&Qt(r.i))return e.interpolate(e.list(r.i));if(Wi(r,"index")&&Qt(r.index))return e.interpolate(e.list(r.index));throw sl(i)}case 6:{let r=t,s=rk(r),n=sk(r);return e.linked(Cu(e,n),s?Cu(e,s):void 0,e.type)}case 7:return Fl(t,i);case 8:return Fl(t,i);default:throw Error(`unhandled node on format message part: ${i}`)}}var ak=e=>e,zl=Pt();function ok(e,t={}){let i=!1,r=t.onError||$C;return t.onError=s=>{i=!0,r(s)},{...XC(e,t),detectError:i}}function lk(e,t){if(!__INTLIFY_DROP_MESSAGE_COMPILER__&&De(e)){Ht(t.warnHtmlMessage)&&t.warnHtmlMessage;let i=(t.onCacheKey||ak)(e),r=zl[i];if(r)return r;let{ast:s,detectError:n}=ok(e,{...t,location:!1,jit:!0}),a=o1(s);return n?a:zl[i]=a}else{let i=e.cacheKey;return i?zl[i]||(zl[i]=o1(e)):o1(e)}}var nl=null;function ck(e){nl=e}function uk(e,t,i){nl&&nl.emit("i18n:init",{timestamp:Date.now(),i18n:e,version:t,meta:i})}var hk=dk("function:translate");function dk(e){return t=>nl&&nl.emit(e,t)}var zr={INVALID_ARGUMENT:17,INVALID_DATE_ARGUMENT:18,INVALID_ISO_DATE_ARGUMENT:19,NOT_SUPPORT_LOCALE_PROMISE_VALUE:21,NOT_SUPPORT_LOCALE_ASYNC_FUNCTION:22,NOT_SUPPORT_LOCALE_TYPE:23};function Ur(e){return wc(e,null,void 0)}function yd(e,t){return t.locale==null?Gf(e.locale):Gf(t.locale)}var l1;function Gf(e){if(De(e))return e;if($t(e)){if(e.resolvedOnce&&l1!=null)return l1;if(e.constructor.name==="Function"){let t=e();if(MC(t))throw Ur(zr.NOT_SUPPORT_LOCALE_PROMISE_VALUE);return l1=t}else throw Ur(zr.NOT_SUPPORT_LOCALE_ASYNC_FUNCTION)}else throw Ur(zr.NOT_SUPPORT_LOCALE_TYPE)}function fk(e,t,i){return[...new Set([i,...zt(t)?t:_t(t)?Object.keys(t):De(t)?[t]:[i]])]}function ku(e,t,i){let r=De(i)?i:D0,s=e;s.__localeChainCache||(s.__localeChainCache=new Map);let n=s.__localeChainCache.get(r);if(!n){n=[];let a=[i];for(;zt(a);)a=Yf(n,a,t);let o=zt(t)||!ft(t)?t:t.default?t.default:null;a=De(o)?[o]:o,zt(a)&&Yf(n,a,!1),s.__localeChainCache.set(r,n)}return n}function Yf(e,t,i){let r=!0;for(let s=0;s<t.length&&Ht(r);s++){let n=t[s];De(n)&&(r=pk(e,t[s],i))}return r}function pk(e,t,i){let r,s=t.split("-");do r=_k(e,s.join("-"),i),s.splice(-1,1);while(s.length&&r===!0);return r}function _k(e,t,i){let r=!1;if(!e.includes(t)&&(r=!0,t)){r=t[t.length-1]!=="!";let s=t.replace(/!/g,"");e.push(s),(zt(i)||ft(i))&&i[s]&&(r=i[s])}return r}var os=[];os[0]={w:[0],i:[3,0],"[":[4],o:[7]},os[1]={w:[1],".":[2],"[":[4],o:[7]},os[2]={w:[2],i:[3,0],0:[3,0]},os[3]={i:[3,0],0:[3,0],w:[1,1],".":[2,1],"[":[4,1],o:[7,1]},os[4]={"'":[5,0],'"':[6,0],"[":[4,2],"]":[1,3],o:8,l:[4,0]},os[5]={"'":[4,0],o:8,l:[5,0]},os[6]={'"':[4,0],o:8,l:[6,0]};var mk=/^\s?(?:true|false|-?[\d.]+|'[^']*'|"[^"]*")\s?$/;function gk(e){return mk.test(e)}function vk(e){let t=e.charCodeAt(0);return t===e.charCodeAt(e.length-1)&&(t===34||t===39)?e.slice(1,-1):e}function bk(e){if(e==null)return"o";switch(e.charCodeAt(0)){case 91:case 93:case 46:case 34:case 39:return e;case 95:case 36:case 45:return"i";case 9:case 10:case 13:case 160:case 65279:case 8232:case 8233:return"w"}return"i"}function yk(e){let t=e.trim();return e.charAt(0)==="0"&&isNaN(parseInt(e))?!1:gk(t)?vk(t):"*"+t}function wk(e){let t=[],i=-1,r=0,s=0,n,a,o,l,c,u,h,d=[];d[0]=()=>{a===void 0?a=o:a+=o},d[1]=()=>{a!==void 0&&(t.push(a),a=void 0)},d[2]=()=>{d[0](),s++},d[3]=()=>{if(s>0)s--,r=4,d[0]();else{if(s=0,a===void 0||(a=yk(a),a===!1))return!1;d[1]()}};function f(){let m=e[i+1];if(r===5&&m==="'"||r===6&&m==='"')return i++,o="\\"+m,d[0](),!0}for(;r!==null;)if(i++,n=e[i],!(n==="\\"&&f())){if(l=bk(n),h=os[r],c=h[l]||h.l||8,c===8||(r=c[0],c[1]!==void 0&&(u=d[c[1]],u&&(o=n,u()===!1))))return;if(r===7)return t}}var Xf=new Map;function Sk(e,t){return _t(e)?e[t]:null}function Ck(e,t){if(!_t(e))return null;let i=Xf.get(t);if(i||(i=wk(t),i&&Xf.set(t,i)),!i)return null;let r=i.length,s=e,n=0;for(;n<r;){let a=i[n];if(I4.includes(a)&&Cr(s)||!_t(s)||!Wi(s,a))return null;let o=s[a];if(o===void 0||$t(s))return null;s=o,n++}return s}var kk="11.3.0",D0="en-US",Jf=e=>`${e.charAt(0).toLocaleUpperCase()}${e.substr(1)}`;function Ak(){return{upper:(e,t)=>t==="text"&&De(e)?e.toUpperCase():t==="vnode"&&_t(e)&&"__v_isVNode"in e?e.children.toUpperCase():e,lower:(e,t)=>t==="text"&&De(e)?e.toLowerCase():t==="vnode"&&_t(e)&&"__v_isVNode"in e?e.children.toLowerCase():e,capitalize:(e,t)=>t==="text"&&De(e)?Jf(e):t==="vnode"&&_t(e)&&"__v_isVNode"in e?Jf(e.children):e}}var R4;function Mk(e){R4=e}var D4;function Lk(e){D4=e}var V4;function Ek(e){V4=e}var B4=null,Qf=e=>{B4=e},$k=()=>B4,e6=0;function xk(e={}){let t=$t(e.onWarn)?e.onWarn:bC,i=De(e.version)?e.version:kk,r=De(e.locale)||$t(e.locale)?e.locale:D0,s=$t(r)?D0:r,n=zt(e.fallbackLocale)||ft(e.fallbackLocale)||De(e.fallbackLocale)||e.fallbackLocale===!1?e.fallbackLocale:s,a=ft(e.messages)?e.messages:c1(s),o=ft(e.datetimeFormats)?e.datetimeFormats:c1(s),l=ft(e.numberFormats)?e.numberFormats:c1(s),c=Si(Pt(),e.modifiers,Ak()),u=e.pluralRules||Pt(),h=$t(e.missing)?e.missing:null,d=Ht(e.missingWarn)||R0(e.missingWarn)?e.missingWarn:!0,f=Ht(e.fallbackWarn)||R0(e.fallbackWarn)?e.fallbackWarn:!0,m=!!e.fallbackFormat,_=!!e.unresolving,y=$t(e.postTranslation)?e.postTranslation:null,p=ft(e.processor)?e.processor:null,C=Ht(e.warnHtmlMessage)?e.warnHtmlMessage:!0,w=!!e.escapeParameter,v=$t(e.messageCompiler)?e.messageCompiler:R4,k=$t(e.messageResolver)?e.messageResolver:D4||Sk,$=$t(e.localeFallbacker)?e.localeFallbacker:V4||fk,M=_t(e.fallbackContext)?e.fallbackContext:void 0,D=e,H=_t(D.__datetimeFormatters)?D.__datetimeFormatters:new Map,R=_t(D.__numberFormatters)?D.__numberFormatters:new Map,V=_t(D.__meta)?D.__meta:{};e6++;let N={version:i,cid:e6,locale:r,fallbackLocale:n,messages:a,modifiers:c,pluralRules:u,missing:h,missingWarn:d,fallbackWarn:f,fallbackFormat:m,unresolving:_,postTranslation:y,processor:p,warnHtmlMessage:C,escapeParameter:w,messageCompiler:v,messageResolver:k,localeFallbacker:$,fallbackContext:M,onWarn:t,__meta:V};return N.datetimeFormats=o,N.numberFormats=l,N.__datetimeFormatters=H,N.__numberFormatters=R,__INTLIFY_PROD_DEVTOOLS__&&uk(N,i,V),N}var c1=e=>({[e]:Pt()});function wd(e,t,i,r,s){let{missing:n,onWarn:a}=e;if(n!==null){let o=n(e,i,t,s);return De(o)?o:t}else return t}function po(e,t,i){let r=e;r.__localeChainCache=new Map,e.localeFallbacker(e,i,t)}function Tk(e,t){return e===t?!1:e.split("-")[0]===t.split("-")[0]}function Nk(e,t){let i=t.indexOf(e);if(i===-1)return!1;for(let r=i+1;r<t.length;r++)if(Tk(e,t[r]))return!0;return!1}function t6(e,...t){let{datetimeFormats:i,unresolving:r,fallbackLocale:s,onWarn:n,localeFallbacker:a}=e,{__datetimeFormatters:o}=e;if(!De(t[0])&&!M4(t[0])&&!Qt(t[0]))return"";let[l,c,u,h]=Au(...t),d=Ht(u.missingWarn)?u.missingWarn:e.missingWarn;Ht(u.fallbackWarn)?u.fallbackWarn:e.fallbackWarn;let f=!!u.part,m=yd(e,u),_=a(e,s,m);if(!De(l)||l==="")return new Intl.DateTimeFormat(m.replace(/!/g,""),h).format(c);let y={},p,C=null,w="datetime format";for(let $=0;$<_.length&&(p=_[$],y=i[p]||{},C=y[l],!ft(C));$++)wd(e,l,p,d,w);if(!ft(C)||!De(p))return r?-1:l;let v=`${p}__${l}`;yc(h)||(v=`${v}__${JSON.stringify(h)}`);let k=o.get(v);return k||(k=new Intl.DateTimeFormat(p,Si({},C,h)),o.set(v,k)),f?k.formatToParts(c):k.format(c)}var Hk=["localeMatcher","weekday","era","year","month","day","hour","minute","second","timeZoneName","formatMatcher","hour12","timeZone","dateStyle","timeStyle","calendar","dayPeriod","numberingSystem","hourCycle","fractionalSecondDigits"];function Au(...e){let[t,i,r,s]=e,n=Pt(),a=Pt(),o;if(De(t)){let l=t.match(/(\d{4}-\d{2}-\d{2})(T|\s)?(.*)/);if(!l)throw Ur(zr.INVALID_ISO_DATE_ARGUMENT);let c=l[3]?l[3].trim().startsWith("T")?`${l[1].trim()}${l[3].trim()}`:`${l[1].trim()}T${l[3].trim()}`:l[1].trim();o=new Date(c);try{o.toISOString()}catch{throw Ur(zr.INVALID_ISO_DATE_ARGUMENT)}}else if(M4(t)){if(isNaN(t.getTime()))throw Ur(zr.INVALID_DATE_ARGUMENT);o=t}else if(Qt(t))o=t;else throw Ur(zr.INVALID_ARGUMENT);return De(i)?n.key=i:ft(i)&&Object.keys(i).forEach(l=>{Hk.includes(l)?a[l]=i[l]:n[l]=i[l]}),De(r)?n.locale=r:ft(r)&&(a=r),ft(s)&&(a=s),[n.key||"",o,n,a]}function i6(e,t,i){let r=e;for(let s in i){let n=`${t}__${s}`;r.__datetimeFormatters.has(n)&&r.__datetimeFormatters.delete(n)}}function r6(e,...t){let{numberFormats:i,unresolving:r,fallbackLocale:s,onWarn:n,localeFallbacker:a}=e,{__numberFormatters:o}=e;if(!Qt(t[0]))return"";let[l,c,u,h]=Mu(...t),d=Ht(u.missingWarn)?u.missingWarn:e.missingWarn;Ht(u.fallbackWarn)?u.fallbackWarn:e.fallbackWarn;let f=!!u.part,m=yd(e,u),_=a(e,s,m);if(!De(l)||l==="")return new Intl.NumberFormat(m.replace(/!/g,""),h).format(c);let y={},p,C=null,w="number format";for(let $=0;$<_.length&&(p=_[$],y=i[p]||{},C=y[l],!ft(C));$++)wd(e,l,p,d,w);if(!ft(C)||!De(p))return r?-1:l;let v=`${p}__${l}`;yc(h)||(v=`${v}__${JSON.stringify(h)}`);let k=o.get(v);return k||(k=new Intl.NumberFormat(p,Si({},C,h)),o.set(v,k)),f?k.formatToParts(c):k.format(c)}var Pk=["localeMatcher","style","currency","currencyDisplay","currencySign","useGrouping","minimumIntegerDigits","minimumFractionDigits","maximumFractionDigits","minimumSignificantDigits","maximumSignificantDigits","compactDisplay","notation","signDisplay","unit","unitDisplay","roundingMode","roundingPriority","roundingIncrement","trailingZeroDisplay"];function Mu(...e){let[t,i,r,s]=e,n=Pt(),a=Pt();if(!Qt(t))throw Ur(zr.INVALID_ARGUMENT);let o=t;return De(i)?n.key=i:ft(i)&&Object.keys(i).forEach(l=>{Pk.includes(l)?a[l]=i[l]:n[l]=i[l]}),De(r)?n.locale=r:ft(r)&&(a=r),ft(s)&&(a=s),[n.key||"",o,n,a]}function s6(e,t,i){let r=e;for(let s in i){let n=`${t}__${s}`;r.__numberFormatters.has(n)&&r.__numberFormatters.delete(n)}}var Ok=e=>e,Ik=e=>"",Rk="text",Dk=e=>e.length===0?"":gd(e),Vk=LC;function u1(e,t){return e=Math.abs(e),t===2?e===1?0:1:Math.min(e,2)}function Bk(e){var i,r;let t=Qt(e.pluralIndex)?e.pluralIndex:-1;return Qt((i=e.named)==null?void 0:i.count)?e.named.count:Qt((r=e.named)==null?void 0:r.n)?e.named.n:t}function Zk(e={}){var _,y,p,C;let t=e.locale,i=Bk(e),r=De(t)&&$t((_=e.pluralRules)==null?void 0:_[t])?e.pluralRules[t]:u1,s=r===u1?void 0:u1,n=w=>w[r(i,w.length,s)],a=e.list||[],o=w=>a[w],l=e.named||Pt();Qt(e.pluralIndex)&&(l.count||(l.count=e.pluralIndex),l.n||(l.n=e.pluralIndex));let c=w=>l[w];function u(w,v){return($t(e.messages)?e.messages(w,!!v):_t(e.messages)?e.messages[w]:!1)||(e.parent?e.parent.message(w):Ik)}let h=w=>e.modifiers?e.modifiers[w]:Ok,d=$t((y=e.processor)==null?void 0:y.normalize)?e.processor.normalize:Dk,f=$t((p=e.processor)==null?void 0:p.interpolate)?e.processor.interpolate:Vk,m={list:o,named:c,plural:n,linked:(w,...v)=>{let[k,$]=v,M="text",D="";v.length===1?_t(k)?(D=k.modifier||D,M=k.type||M):De(k)&&(D=k||D):v.length===2&&(De(k)&&(D=k||D),De($)&&(M=$||M));let H=u(w,!0)(m),R=H===""||H===void 0?w:H,V=M==="vnode"&&zt(R)&&D?R[0]:R;return D?h(D)(V,M):V},message:u,type:De((C=e.processor)==null?void 0:C.type)?e.processor.type:Rk,interpolate:f,normalize:d,values:Si(Pt(),a,l)};return m}var n6=()=>"",Ji=e=>$t(e);function a6(e,...t){let{fallbackFormat:i,postTranslation:r,unresolving:s,messageCompiler:n,fallbackLocale:a,messages:o}=e,[l,c]=Lu(...t),u=Ht(c.missingWarn)?c.missingWarn:e.missingWarn,h=Ht(c.fallbackWarn)?c.fallbackWarn:e.fallbackWarn,d=Ht(c.escapeParameter)?c.escapeParameter:e.escapeParameter,f=!!c.resolvedMessage,m=De(c.default)||Ht(c.default)?Ht(c.default)?n?l:()=>l:c.default:i?n?l:()=>l:null,_=i||m!=null&&(De(m)||$t(m)),y=yd(e,c);d&&Fk(c);let[p,C,w]=f?[l,y,o[y]||Pt()]:Z4(e,l,y,a,h,u),v=p,k=l;if(!f&&!(De(v)||Cr(v)||Ji(v))&&_&&(v=m,k=v),!f&&(!(De(v)||Cr(v)||Ji(v))||!De(C)))return s?-1:l;let $=!1,M=Ji(v)?v:F4(e,l,C,v,k,()=>{$=!0});if($)return v;let D=zk(e,M,Zk(Wk(e,C,w,c))),H=r?r(D,l):D;if(d&&De(H)&&(H=kC(H)),__INTLIFY_PROD_DEVTOOLS__){let R={timestamp:Date.now(),key:De(l)?l:Ji(v)?v.key:"",locale:C||(Ji(v)?v.locale:""),format:De(v)?v:Ji(v)?v.source:"",message:H};R.meta=Si({},e.__meta,{}),hk(R)}return H}function Fk(e){zt(e.list)?e.list=e.list.map(t=>De(t)?zf(t):t):_t(e.named)&&Object.keys(e.named).forEach(t=>{De(e.named[t])&&(e.named[t]=zf(e.named[t]))})}function Z4(e,t,i,r,s,n){let{messages:a,onWarn:o,messageResolver:l,localeFallbacker:c}=e,u=c(e,r,i),h=Pt(),d,f=null,m="translate";for(let _=0;_<u.length&&(d=u[_],h=a[d]||Pt(),(f=l(h,t))===null&&(f=h[t]),!(De(f)||Cr(f)||Ji(f)));_++)if(!Nk(d,u)){let y=wd(e,t,d,n,m);y!==t&&(f=y)}return[f,d,h]}function F4(e,t,i,r,s,n){let{messageCompiler:a,warnHtmlMessage:o}=e;if(Ji(r)){let c=r;return c.locale=c.locale||i,c.key=c.key||t,c}if(a==null){let c=()=>r;return c.locale=i,c.key=t,c}let l=a(r,Uk(e,i,s,r,o,n));return l.locale=i,l.key=t,l.source=r,l}function zk(e,t,i){return t(i)}function Lu(...e){let[t,i,r]=e,s=Pt();if(!De(t)&&!Qt(t)&&!Ji(t)&&!Cr(t))throw Ur(zr.INVALID_ARGUMENT);let n=Qt(t)?String(t):t;return Qt(i)?s.plural=i:De(i)?s.default=i:ft(i)&&!yc(i)?s.named=i:zt(i)&&(s.list=i),Qt(r)?s.plural=r:De(r)?s.default=r:ft(r)&&Si(s,r),[n,s]}function Uk(e,t,i,r,s,n){return{locale:t,key:i,warnHtmlMessage:s,onError:a=>{throw n&&n(a),a},onCacheKey:a=>yC(t,i,a)}}function Wk(e,t,i,r){let{modifiers:s,pluralRules:n,messageResolver:a,fallbackLocale:o,fallbackWarn:l,missingWarn:c,fallbackContext:u}=e,h={locale:t,modifiers:s,pluralRules:n,messages:(d,f)=>{let m=a(i,d);if(m==null&&(u||f)){let[,,_]=Z4(u||e,d,t,o,l,c);m=a(_,d)}if(De(m)||Cr(m)){let _=!1,y=F4(e,d,t,m,d,()=>{_=!0});return _?n6:y}else return Ji(m)?m:n6}};return e.processor&&(h.processor=e.processor),r.list&&(h.list=r.list),r.named&&(h.named=r.named),Qt(r.plural)&&(h.pluralIndex=r.plural),h}JC();var jk="11.3.0";function Kk(){typeof __VUE_I18N_FULL_INSTALL__!="boolean"&&(Ks().__VUE_I18N_FULL_INSTALL__=!0),typeof __VUE_I18N_LEGACY_API__!="boolean"&&(Ks().__VUE_I18N_LEGACY_API__=!0),typeof __INTLIFY_DROP_MESSAGE_COMPILER__!="boolean"&&(Ks().__INTLIFY_DROP_MESSAGE_COMPILER__=!1),typeof __INTLIFY_PROD_DEVTOOLS__!="boolean"&&(Ks().__INTLIFY_PROD_DEVTOOLS__=!1)}var Dn={UNEXPECTED_RETURN_TYPE:24,INVALID_ARGUMENT:25,MUST_BE_CALL_SETUP_TOP:26,NOT_INSTALLED:27,NOT_INSTALLED_WITH_PROVIDE:31,UNEXPECTED_ERROR:32};function al(e,...t){return wc(e,null,void 0)}var o6=on("__translateVNode"),l6=on("__datetimeParts"),c6=on("__numberParts"),qk=on("__setPluralRules"),z4=on("__injectWithOption"),Eu=on("__dispose");function ol(e){if(!_t(e)||Cr(e))return e;for(let t in e)if(Wi(e,t))if(!t.includes("."))_t(e[t])&&ol(e[t]);else{let i=t.split("."),r=i.length-1,s=e,n=!1;for(let a=0;a<r;a++){if(i[a]==="__proto__")throw Error(`unsafe key: ${i[a]}`);if(i[a]in s||(s[i[a]]=Pt()),!_t(s[i[a]])){n=!0;break}s=s[i[a]]}if(n||(Cr(s)?I4.includes(i[r])||delete e[t]:(s[i[r]]=e[t],delete e[t])),!Cr(s)){let a=s[i[r]];_t(a)&&ol(a)}}return e}function U4(e,t){let{messages:i,__i18n:r,messageResolver:s,flatJson:n}=t,a=ft(i)?i:zt(r)?Pt():{[e]:Pt()};if(zt(r)&&r.forEach(o=>{if("locale"in o&&"resource"in o){let{locale:l,resource:c}=o;l?(a[l]=a[l]||Pt(),o0(c,a[l])):o0(c,a)}else De(o)&&o0(JSON.parse(o),a)}),s==null&&n)for(let o in a)Wi(a,o)&&ol(a[o]);return a}function Gk(e){return e.type}function Yk(e,t,i){let r=_t(t.messages)?t.messages:Pt();"__i18nGlobal"in i&&(r=U4(e.locale.value,{messages:r,__i18n:i.__i18nGlobal}));let s=Object.keys(r);if(s.length&&s.forEach(n=>{e.mergeLocaleMessage(n,r[n])}),_t(t.datetimeFormats)){let n=Object.keys(t.datetimeFormats);n.length&&n.forEach(a=>{e.mergeDateTimeFormat(a,t.datetimeFormats[a])})}if(_t(t.numberFormats)){let n=Object.keys(t.numberFormats);n.length&&n.forEach(a=>{e.mergeNumberFormat(a,t.numberFormats[a])})}}function u6(e){return Y(As,null,e,0)}function W4(){return ki()}var h6=()=>[],Xk=()=>!1,d6=0;function f6(e){return(t,i,r,s)=>e(i,r,W4()||void 0,s)}function Jk(e={}){let{__root:t,__injectWithOption:i}=e,r=t===void 0,s=e.flatJson,n=Ff?X:Ar,a=Ht(e.inheritLocale)?e.inheritLocale:!0,o=n(t&&a?t.locale.value:De(e.locale)?e.locale:D0),l=n(t&&a?t.fallbackLocale.value:De(e.fallbackLocale)||zt(e.fallbackLocale)||ft(e.fallbackLocale)||e.fallbackLocale===!1?e.fallbackLocale:o.value),c=n(U4(o.value,e)),u=n(ft(e.datetimeFormats)?e.datetimeFormats:{[o.value]:{}}),h=n(ft(e.numberFormats)?e.numberFormats:{[o.value]:{}}),d=t?t.missingWarn:Ht(e.missingWarn)||R0(e.missingWarn)?e.missingWarn:!0,f=t?t.fallbackWarn:Ht(e.fallbackWarn)||R0(e.fallbackWarn)?e.fallbackWarn:!0,m=t?t.fallbackRoot:Ht(e.fallbackRoot)?e.fallbackRoot:!0,_=!!e.fallbackFormat,y=$t(e.missing)?e.missing:null,p=$t(e.missing)?f6(e.missing):null,C=$t(e.postTranslation)?e.postTranslation:null,w=t?t.warnHtmlMessage:Ht(e.warnHtmlMessage)?e.warnHtmlMessage:!0,v=!!e.escapeParameter,k=t?t.modifiers:ft(e.modifiers)?e.modifiers:{},$=e.pluralRules||t&&t.pluralRules,M;M=(()=>{r&&Qf(null);let I={version:jk,locale:o.value,fallbackLocale:l.value,messages:c.value,modifiers:k,pluralRules:$,missing:p===null?void 0:p,missingWarn:d,fallbackWarn:f,fallbackFormat:_,unresolving:!0,postTranslation:C===null?void 0:C,warnHtmlMessage:w,escapeParameter:v,messageResolver:e.messageResolver,messageCompiler:e.messageCompiler,__meta:{framework:"vue"}};I.datetimeFormats=u.value,I.numberFormats=h.value,I.__datetimeFormatters=ft(M)?M.__datetimeFormatters:void 0,I.__numberFormatters=ft(M)?M.__numberFormatters:void 0;let z=xk(I);return r&&Qf(z),z})(),po(M,o.value,l.value);function D(){return[o.value,l.value,c.value,u.value,h.value]}let H=Q({get:()=>o.value,set:I=>{M.locale=I,o.value=I}}),R=Q({get:()=>l.value,set:I=>{M.fallbackLocale=I,l.value=I,po(M,o.value,I)}}),V=Q(()=>c.value),N=Q(()=>u.value),P=Q(()=>h.value);function U(){return $t(C)?C:null}function j(I){C=I,M.postTranslation=I}function oe(){return y}function te(I){I!==null&&(p=f6(I)),y=I,M.missing=p}let ne=(I,z,W,ae,ye,ke)=>{D();let Oe;try{__INTLIFY_PROD_DEVTOOLS__,r||(M.fallbackContext=t?$k():void 0),Oe=I(M)}finally{__INTLIFY_PROD_DEVTOOLS__,r||(M.fallbackContext=void 0)}if(W!=="translate exists"&&Qt(Oe)&&Oe===-1||W==="translate exists"&&!Oe){let[je,Ee]=z();return t&&m?ae(t):ye(je)}else{if(ke(Oe))return Oe;throw al(Dn.UNEXPECTED_RETURN_TYPE)}};function J(...I){return ne(z=>Reflect.apply(a6,null,[z,...I]),()=>Lu(...I),"translate",z=>Reflect.apply(z.t,z,[...I]),z=>z,z=>De(z))}function fe(...I){let[z,W,ae]=I;if(ae&&!_t(ae))throw al(Dn.INVALID_ARGUMENT);return J(z,W,Si({resolvedMessage:!0},ae||{}))}function re(...I){return ne(z=>Reflect.apply(t6,null,[z,...I]),()=>Au(...I),"datetime format",z=>Reflect.apply(z.d,z,[...I]),()=>"",z=>De(z)||zt(z))}function _e(...I){return ne(z=>Reflect.apply(r6,null,[z,...I]),()=>Mu(...I),"number format",z=>Reflect.apply(z.n,z,[...I]),()=>"",z=>De(z)||zt(z))}function Ne(I){return I.map(z=>De(z)||Qt(z)||Ht(z)?u6(String(z)):z)}let $e={normalize:Ne,interpolate:I=>I,type:"vnode"};function be(...I){return ne(z=>{let W,ae=z;try{ae.processor=$e,W=Reflect.apply(a6,null,[ae,...I])}finally{ae.processor=null}return W},()=>Lu(...I),"translate",z=>z[o6](...I),z=>[u6(z)],z=>zt(z))}function me(...I){return ne(z=>Reflect.apply(r6,null,[z,...I]),()=>Mu(...I),"number format",z=>z[c6](...I),h6,z=>De(z)||zt(z))}function O(...I){return ne(z=>Reflect.apply(t6,null,[z,...I]),()=>Au(...I),"datetime format",z=>z[l6](...I),h6,z=>De(z)||zt(z))}function ie(I){$=I,M.pluralRules=$}function le(I,z){return ne(()=>{if(!I)return!1;let W=De(z)?z:o.value,ae=De(z)?[W]:ku(M,l.value,W);for(let ye=0;ye<ae.length;ye++){let ke=x(ae[ye]),Oe=M.messageResolver(ke,I);if(Oe===null&&(Oe=ke[I]),Cr(Oe)||Ji(Oe)||De(Oe))return!0}return!1},()=>[I],"translate exists",W=>Reflect.apply(W.te,W,[I,z]),Xk,W=>Ht(W))}function ge(I){let z=null,W=ku(M,l.value,o.value);for(let ae=0;ae<W.length;ae++){let ye=c.value[W[ae]]||{},ke=M.messageResolver(ye,I);if(ke!=null){z=ke;break}}return z}function Se(I){return ge(I)??(t&&t.tm(I)||{})}function x(I){return c.value[I]||{}}function T(I,z){if(s){let W={[I]:z};for(let ae in W)Wi(W,ae)&&ol(W[ae]);z=W[I]}c.value[I]=z,M.messages=c.value}function K(I,z){c.value[I]=c.value[I]||{};let W={[I]:z};if(s)for(let ae in W)Wi(W,ae)&&ol(W[ae]);z=W[I],o0(z,c.value[I]),M.messages=c.value}function se(I){return u.value[I]||{}}function he(I,z){u.value[I]=z,M.datetimeFormats=u.value,i6(M,I,z)}function pe(I,z){u.value[I]=Si(u.value[I]||{},z),M.datetimeFormats=u.value,i6(M,I,z)}function S(I){return h.value[I]||{}}function A(I,z){h.value[I]=z,M.numberFormats=h.value,s6(M,I,z)}function B(I,z){h.value[I]=Si(h.value[I]||{},z),M.numberFormats=h.value,s6(M,I,z)}d6++,t&&Ff&&(Fe(t.locale,I=>{a&&(o.value=I,M.locale=I,po(M,o.value,l.value))}),Fe(t.fallbackLocale,I=>{a&&(l.value=I,M.fallbackLocale=I,po(M,o.value,l.value))}));let L={id:d6,locale:H,fallbackLocale:R,get inheritLocale(){return a},set inheritLocale(I){a=I,I&&t&&(o.value=t.locale.value,l.value=t.fallbackLocale.value,po(M,o.value,l.value))},get availableLocales(){return Object.keys(c.value).sort()},messages:V,get modifiers(){return k},get pluralRules(){return $||{}},get isGlobal(){return r},get missingWarn(){return d},set missingWarn(I){d=I,M.missingWarn=d},get fallbackWarn(){return f},set fallbackWarn(I){f=I,M.fallbackWarn=f},get fallbackRoot(){return m},set fallbackRoot(I){m=I},get fallbackFormat(){return _},set fallbackFormat(I){_=I,M.fallbackFormat=_},get warnHtmlMessage(){return w},set warnHtmlMessage(I){w=I,M.warnHtmlMessage=I},get escapeParameter(){return v},set escapeParameter(I){v=I,M.escapeParameter=I},t:J,getLocaleMessage:x,setLocaleMessage:T,mergeLocaleMessage:K,getPostTranslationHandler:U,setPostTranslationHandler:j,getMissingHandler:oe,setMissingHandler:te,[qk]:ie};return L.datetimeFormats=N,L.numberFormats=P,L.rt=fe,L.te=le,L.tm=Se,L.d=re,L.n=_e,L.getDateTimeFormat=se,L.setDateTimeFormat=he,L.mergeDateTimeFormat=pe,L.getNumberFormat=S,L.setNumberFormat=A,L.mergeNumberFormat=B,L[z4]=i,L[o6]=be,L[l6]=O,L[c6]=me,L}var $u={tag:{type:[String,Object]},locale:{type:String},scope:{type:String,validator:e=>e==="parent"||e==="global",default:"parent"},i18n:{type:Object}};Si({keypath:{type:String,required:!0},plural:{type:[Number,String],validator:e=>Qt(e)||!isNaN(e)}},$u),Si({value:{type:Number,required:!0},format:{type:[String,Object]}},$u);var Qk=on("global-vue-i18n");function eA(e={}){let t=W4();if(t==null)throw al(Dn.MUST_BE_CALL_SETUP_TOP);if(!t.isCE&&t.appContext.app!=null&&!t.appContext.app.__VUE_I18N_SYMBOL__)throw al(Dn.NOT_INSTALLED);let i=tA(t),r=rA(i),s=Gk(t),n=iA(e,s);if(n==="global")return Yk(r,e,s),r;if(n==="parent"){let l=sA(i,t,e.__useComponent);return l??(l=r),l}let a=i,o=a.__getInstance(t);if(o==null){let l=Si({},e);"__i18n"in s&&(l.__i18n=s.__i18n),r&&(l.__root=r),o=Jk(l),a.__composerExtend&&(o[Eu]=a.__composerExtend(o)),aA(a,t,o),a.__setInstance(t,o)}return o}function tA(e){let t=ai(e.isCE?Qk:e.appContext.app.__VUE_I18N_SYMBOL__);if(!t)throw al(e.isCE?Dn.NOT_INSTALLED_WITH_PROVIDE:Dn.UNEXPECTED_ERROR);return t}function iA(e,t){return yc(e)?"__i18n"in t?"local":"global":e.useScope?e.useScope:"local"}function rA(e){return e.mode==="composition"?e.global:e.global.__composer}function sA(e,t,i=!1){let r=null,s=t.root,n=nA(t,i);for(;n!=null;){let a=e;if(e.mode==="composition")r=a.__getInstance(n);else if(__VUE_I18N_LEGACY_API__){let o=a.__getInstance(n);o!=null&&(r=o.__composer,i&&r&&!r[z4]&&(r=null))}if(r!=null||s===n)break;n=n.parent}return r}function nA(e,t=!1){return e==null?null:t&&e.vnode.ctx||e.parent}function aA(e,t,i){ut(()=>{},t),Ii(()=>{let r=i;e.__deleteInstance(t);let s=r[Eu];s&&(s(),delete r[Eu])},t)}if(Si({value:{type:[Number,Date],required:!0},format:{type:[String,Object]}},$u),Kk(),Mk(lk),Lk(Ck),Ek(ku),__INTLIFY_PROD_DEVTOOLS__){let e=Ks();e.__INTLIFY__=!0,ck(e.__INTLIFY_DEVTOOLS_GLOBAL_HOOK__)}const aa=(e,t,i)=>{const r=s=>Me("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:t,fill:"currentColor",...s,innerHTML:i});return r.displayName="NbGlyph",r.glyphName=e,r},oA=aa("check","0 0 256 256",'<path d="M226.83,74.83l-128,128a4,4,0,0,1-5.66,0l-56-56a4,4,0,0,1,5.66-5.66L96,194.34,221.17,69.17a4,4,0,1,1,5.66,5.66Z"/>'),lA=aa("check","0 0 256 256",'<path d="M228.24,76.24l-128,128a6,6,0,0,1-8.48,0l-56-56a6,6,0,0,1,8.48-8.48L96,191.51,219.76,67.76a6,6,0,0,1,8.48,8.48Z"/>'),V0=aa("check","0 0 256 256",'<path d="M229.66,77.66l-128,128a8,8,0,0,1-11.32,0l-56-56a8,8,0,0,1,11.32-11.32L96,188.69,218.34,66.34a8,8,0,0,1,11.32,11.32Z"/>'),cA=aa("check","0 0 256 256",'<path d="M232.49,80.49l-128,128a12,12,0,0,1-17,0l-56-56a12,12,0,1,1,17-17L96,183,215.51,63.51a12,12,0,0,1,17,17Z"/>'),uA=aa("check","0 0 256 256",'<path d="M216,40H40A16,16,0,0,0,24,56V200a16,16,0,0,0,16,16H216a16,16,0,0,0,16-16V56A16,16,0,0,0,216,40ZM205.66,85.66l-96,96a8,8,0,0,1-11.32,0l-40-40a8,8,0,0,1,11.32-11.32L104,164.69l90.34-90.35a8,8,0,0,1,11.32,11.32Z"/>'),hA=aa("check","0 0 256 256",'<path d="M232,56V200a16,16,0,0,1-16,16H40a16,16,0,0,1-16-16V56A16,16,0,0,1,40,40H216A16,16,0,0,1,232,56Z" opacity="0.2"/><path d="M205.66,85.66l-96,96a8,8,0,0,1-11.32,0l-40-40a8,8,0,0,1,11.32-11.32L104,164.69l90.34-90.35a8,8,0,0,1,11.32,11.32Z"/>'),dA="check",Ss=Object.freeze(Object.defineProperty({__proto__:null,bold:cA,default:V0,duotone:hA,fill:uA,glyphName:dA,light:lA,regular:V0,thin:oA},Symbol.toStringTag,{value:"Module"})),fA=(e,t,i)=>{const r=s=>Me("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:t,fill:"currentColor",...s,innerHTML:i});return r.displayName="NbGlyph",r.glyphName=e,r},pA=fA("users","0 0 256 256",'<path d="M117.25,157.92a60,60,0,1,0-66.5,0A95.83,95.83,0,0,0,3.53,195.63a8,8,0,1,0,13.4,8.74,80,80,0,0,1,134.14,0,8,8,0,0,0,13.4-8.74A95.83,95.83,0,0,0,117.25,157.92ZM40,108a44,44,0,1,1,44,44A44.05,44.05,0,0,1,40,108Zm210.14,98.7a8,8,0,0,1-11.07-2.33A79.83,79.83,0,0,0,172,168a8,8,0,0,1,0-16,44,44,0,1,0-16.34-84.87,8,8,0,1,1-5.94-14.85,60,60,0,0,1,55.53,105.64,95.83,95.83,0,0,1,47.22,37.71A8,8,0,0,1,250.14,206.7Z"/>'),oa=(e,t,i)=>{const r=s=>Me("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:t,fill:"currentColor",...s,innerHTML:i});return r.displayName="NbGlyph",r.glyphName=e,r},_A=oa("plus","0 0 256 256",'<path d="M220,128a4,4,0,0,1-4,4H132v84a4,4,0,0,1-8,0V132H40a4,4,0,0,1,0-8h84V40a4,4,0,0,1,8,0v84h84A4,4,0,0,1,220,128Z"/>'),mA=oa("plus","0 0 256 256",'<path d="M222,128a6,6,0,0,1-6,6H134v82a6,6,0,0,1-12,0V134H40a6,6,0,0,1,0-12h82V40a6,6,0,0,1,12,0v82h82A6,6,0,0,1,222,128Z"/>'),ll=oa("plus","0 0 256 256",'<path d="M224,128a8,8,0,0,1-8,8H136v80a8,8,0,0,1-16,0V136H40a8,8,0,0,1,0-16h80V40a8,8,0,0,1,16,0v80h80A8,8,0,0,1,224,128Z"/>'),gA=oa("plus","0 0 256 256",'<path d="M228,128a12,12,0,0,1-12,12H140v76a12,12,0,0,1-24,0V140H40a12,12,0,0,1,0-24h76V40a12,12,0,0,1,24,0v76h76A12,12,0,0,1,228,128Z"/>'),vA=oa("plus","0 0 256 256",'<path d="M208,32H48A16,16,0,0,0,32,48V208a16,16,0,0,0,16,16H208a16,16,0,0,0,16-16V48A16,16,0,0,0,208,32ZM184,136H136v48a8,8,0,0,1-16,0V136H72a8,8,0,0,1,0-16h48V72a8,8,0,0,1,16,0v48h48a8,8,0,0,1,0,16Z"/>'),bA=oa("plus","0 0 256 256",'<path d="M216,56V200a16,16,0,0,1-16,16H56a16,16,0,0,1-16-16V56A16,16,0,0,1,56,40H200A16,16,0,0,1,216,56Z" opacity="0.2"/><path d="M224,128a8,8,0,0,1-8,8H136v80a8,8,0,0,1-16,0V136H40a8,8,0,0,1,0-16h80V40a8,8,0,0,1,16,0v80h80A8,8,0,0,1,224,128Z"/>'),yA="plus",wA=Object.freeze(Object.defineProperty({__proto__:null,bold:gA,default:ll,duotone:bA,fill:vA,glyphName:yA,light:mA,regular:ll,thin:_A},Symbol.toStringTag,{value:"Module"})),SA=(e,t,i)=>{const r=s=>Me("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:t,fill:"currentColor",...s,innerHTML:i});return r.displayName="NbGlyph",r.glyphName=e,r},CA=SA("user","0 0 256 256",'<path d="M230.92,212c-15.23-26.33-38.7-45.21-66.09-54.16a72,72,0,1,0-73.66,0C63.78,166.78,40.31,185.66,25.08,212a8,8,0,1,0,13.85,8c18.84-32.56,52.14-52,89.07-52s70.23,19.44,89.07,52a8,8,0,1,0,13.85-8ZM72,96a56,56,0,1,1,56,56A56.06,56.06,0,0,1,72,96Z"/>'),kA=(e,t,i)=>{const r=s=>Me("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:t,fill:"currentColor",...s,innerHTML:i});return r.displayName="NbGlyph",r.glyphName=e,r},j4=kA("sign-out","0 0 256 256",'<path d="M120,216a8,8,0,0,1-8,8H48a8,8,0,0,1-8-8V40a8,8,0,0,1,8-8h64a8,8,0,0,1,0,16H56V208h56A8,8,0,0,1,120,216Zm109.66-93.66-40-40a8,8,0,0,0-11.32,11.32L204.69,120H112a8,8,0,0,0,0,16h92.69l-26.35,26.34a8,8,0,0,0,11.32,11.32l40-40A8,8,0,0,0,229.66,122.34Z"/>');var AA=["title","aria-expanded","disabled"],MA={class:"nb-user-menu__avatar","aria-hidden":"true"},LA=["src"],EA={class:"nb-user-menu__identity-text"},$A={class:"nb-user-menu__identity-name"},xA={key:0,class:"nb-user-menu__identity-email"},TA=["title","aria-label","aria-expanded","disabled"],NA=["src"],HA={class:"nb-user-menu__label"},PA={class:"nb-user-menu__email"},OA=["disabled","onClick"],IA={class:"nb-user-menu__account-main"},RA={class:"nb-user-menu__account-email"},DA={key:0,class:"nb-user-menu__account-name"},VA={class:"nb-user-menu__brand"},BA={class:"nb-user-menu__brand-line"},ZA={class:"nb-user-menu__brand-name"},FA="Nubisco Platform",zA=Re({__name:"UserMenu",props:{user:{},accounts:{default:void 0},accountsUnknown:{type:Boolean,default:!1},showAccountActions:{type:Boolean,default:!0},showProfile:{type:Boolean,default:!0},brand:{default:"footer"},placement:{default:"right-end"},trigger:{default:"avatar"},disabled:{type:Boolean,default:!1}},emits:["switch","remove","switch-account","add-account","profile","sign-out","open","close"],setup(e,{expose:t,emit:i}){let r={en:{ACCOUNT_MENU:"Account menu",SIGNED_IN_AS:"Signed in as",SWITCH_ACCOUNT:"Switch account",USE_ANOTHER_ACCOUNT:"Use another account",REMOVE_ACCOUNT:"Sign this account out of this browser",PROFILE:"Profile",SIGN_OUT:"Sign out",poweredBy:"Powered by Nubisco Platform"},pt:{ACCOUNT_MENU:"Menu de conta",SIGNED_IN_AS:"Sessão iniciada como",SWITCH_ACCOUNT:"Mudar de conta",USE_ANOTHER_ACCOUNT:"Usar outra conta",REMOVE_ACCOUNT:"Terminar a sessão desta conta neste browser",PROFILE:"Perfil",SIGN_OUT:"Terminar sessão",poweredBy:"Fornecido pela Nubisco Platform"}},{t:s,te:n,locale:a}=eA({useScope:"global"});function o(te){var J;if(n(te))return s(te);let ne=te.slice(9);return((J=r[String(a.value).toLowerCase().split("-")[0]])==null?void 0:J[ne])??r.en[ne]??te}let l=e,c=ai("nb-shell-sidebar-variant",null),u=Q(()=>l.trigger==="identity"&&((c==null?void 0:c.value)??"verbose")==="verbose"),h=Q(()=>{var te;return((te=l.user.name)==null?void 0:te.trim())||l.user.email}),d=Q(()=>{var ne;let te=(ne=l.user.name)==null?void 0:ne.trim();return te?te.toLowerCase()===l.user.email.trim().toLowerCase()?"":l.user.email:""}),f=X(!1);Fe(()=>l.user.picture,()=>{f.value=!1});let m=Q(()=>!!l.user.picture&&!f.value),_=Q(()=>{let te=o("userMenu.poweredBy"),ne=te.indexOf(FA);return ne<0?{prefix:"",name:te}:{prefix:te.slice(0,ne),name:te.slice(ne)}}),y=i,p=X(null),C=X(null),w=X(!1),v=X({});function k(te){return vS(te)}function $(){var ne;let te=(ne=p.value)==null?void 0:ne.getBoundingClientRect();te&&(l.placement==="top-start"?v.value={left:`${Math.round(te.left)}px`,bottom:`${Math.round(window.innerHeight-te.top+8)}px`}:v.value={left:`${Math.round(te.right+12)}px`,bottom:`${Math.round(window.innerHeight-te.bottom)}px`})}function M(){l.disabled||(w.value?D():($(),w.value=!0,y("open")))}function D(){w.value&&(w.value=!1,y("close"))}function H(te){te.current||(D(),y("switch",te))}function R(te){y("remove",te)}function V(){D(),y("switch-account")}function N(){D(),y("add-account")}function P(){D(),y("profile")}function U(){D(),y("sign-out")}function j(te){var J,fe;if(!w.value)return;let ne=te.target;(J=p.value)!=null&&J.contains(ne)||(fe=C.value)!=null&&fe.contains(ne)||D()}function oe(te){te.key==="Escape"&&D()}return ut(()=>{document.addEventListener("click",j),document.addEventListener("keydown",oe)}),Gi(()=>{document.removeEventListener("click",j),document.removeEventListener("keydown",oe)}),t({open:w,toggle:M,close:D}),(te,ne)=>(g(),E("div",{ref_key:"rootRef",ref:p,class:xe(["nb-user-menu",{"nb-user-menu--identity":u.value}])},[Pe(te.$slots,"trigger",{open:w.value,toggle:M},()=>[u.value?(g(),E("button",{key:0,type:"button",class:"nb-user-menu__identity",title:l.user.email,"aria-haspopup":"menu","aria-expanded":w.value,disabled:e.disabled,onClick:M},[b("span",MA,[m.value?(g(),E("img",{key:0,class:"nb-user-menu__picture",src:l.user.picture??void 0,alt:"",onError:ne[0]||(ne[0]=J=>f.value=!0)},null,40,LA)):(g(),E(we,{key:1},[ce(Z(k(l.user)),1)],64))]),b("span",EA,[b("span",$A,Z(h.value),1),d.value?(g(),E("span",xA,Z(d.value),1)):F("",!0)])],8,AA)):(g(),E("button",{key:1,type:"button",class:"nb-user-menu__avatar",title:l.user.email,"aria-label":o("userMenu.ACCOUNT_MENU"),"aria-haspopup":"menu","aria-expanded":w.value,disabled:e.disabled,onClick:M},[m.value?(g(),E("img",{key:0,class:"nb-user-menu__picture",src:l.user.picture??void 0,alt:"",onError:ne[1]||(ne[1]=J=>f.value=!0)},null,40,NA)):(g(),E(we,{key:1},[ce(Z(k(l.user)),1)],64))],8,TA))]),(g(),de(br,{to:"body"},[Y(jh,{name:"nb-user-menu-pop"},{default:ee(()=>[w.value?(g(),E("div",{key:0,ref_key:"panelRef",ref:C,class:"nb-user-menu__panel",style:Ci(v.value),role:"menu"},[b("p",HA,Z(o("userMenu.SIGNED_IN_AS")),1),b("p",PA,Z(l.user.email),1),e.showAccountActions?(g(),E(we,{key:0},[ne[2]||(ne[2]=b("div",{class:"nb-user-menu__divider",role:"separator"},null,-1)),l.accounts&&l.accounts.length?(g(!0),E(we,{key:0},Be(l.accounts,J=>(g(),E("button",{key:J.id,type:"button",role:"menuitem",class:xe(["nb-user-menu__account",{"nb-user-menu__account--current":J.current}]),disabled:J.current,onClick:fe=>H(J)},[b("span",IA,[b("span",RA,Z(J.email),1),J.name?(g(),E("span",DA,Z(J.name),1)):F("",!0)]),J.current?(g(),de(Ge,{key:0,name:ue(V0),size:14,class:"nb-user-menu__check"},null,8,["name"])):J.removable===!1?F("",!0):(g(),de(Ge,{key:1,name:ue(rl),size:13,class:"nb-user-menu__remove",title:o("userMenu.REMOVE_ACCOUNT"),onClick:at(fe=>R(J),["stop"])},null,8,["name","title","onClick"]))],10,OA))),128)):l.accountsUnknown?(g(),E("button",{key:1,type:"button",role:"menuitem",class:"nb-user-menu__action",onClick:V},[Y(Ge,{name:ue(pA),size:15},null,8,["name"]),ce(" "+Z(o("userMenu.SWITCH_ACCOUNT")),1)])):F("",!0),b("button",{type:"button",role:"menuitem",class:"nb-user-menu__action",onClick:N},[Y(Ge,{name:ue(ll),size:15},null,8,["name"]),ce(" "+Z(o("userMenu.USE_ANOTHER_ACCOUNT")),1)])],64)):F("",!0),te.$slots.default?(g(),E(we,{key:1},[ne[3]||(ne[3]=b("div",{class:"nb-user-menu__divider",role:"separator"},null,-1)),Pe(te.$slots,"default",{close:D})],64)):F("",!0),ne[5]||(ne[5]=b("div",{class:"nb-user-menu__divider",role:"separator"},null,-1)),e.showProfile?(g(),E("button",{key:2,type:"button",role:"menuitem",class:"nb-user-menu__action",onClick:P},[Y(Ge,{name:ue(CA),size:15},null,8,["name"]),ce(" "+Z(o("userMenu.PROFILE")),1)])):F("",!0),b("button",{type:"button",role:"menuitem",class:"nb-user-menu__action nb-user-menu__action--danger",onClick:U},[Y(Ge,{name:ue(j4),size:15},null,8,["name"]),ce(" "+Z(o("userMenu.SIGN_OUT")),1)]),l.brand==="none"?F("",!0):(g(),E(we,{key:3},[ne[4]||(ne[4]=b("div",{class:"nb-user-menu__divider",role:"separator"},null,-1)),Pe(te.$slots,"brand",{},()=>[b("p",VA,[Y(vC,{size:13,class:"nb-user-menu__mark"}),b("span",BA,[ce(Z(_.value.prefix),1),b("span",ZA,Z(_.value.name),1)])])])],64))],4)):F("",!0)]),_:3})]))],2))}}),UA=Symbol("NB_CHECKBOX_GROUP_CONTEXT"),WA={class:"nb-checkbox__control"},jA=["checked","disabled","indeterminate"],KA={class:"nb-checkbox__box"},qA={key:0,class:"nb-checkbox__check",viewBox:"0 0 10 8",fill:"none"},GA={key:1,class:"nb-checkbox__dash"},YA={key:0,class:"nb-checkbox__label"},p6=ht(Re({__name:"Checkbox",props:{modelValue:{type:Boolean,default:!1},indeterminate:{type:Boolean,default:!1},name:{},disabled:{type:Boolean,default:!1},required:{type:Boolean},id:{default:"checkbox"},label:{}},emits:["update:modelValue"],setup(e,{emit:t}){let i=e,r=t,s=ai(UA,null),n=Q(()=>i.disabled||!!(s!=null&&s.disabled.value));function a(o){n.value||r("update:modelValue",o.target.checked)}return(o,l)=>(g(),E("label",{class:xe(["nb-checkbox",{"nb-checkbox--disabled":n.value}])},[b("span",WA,[b("input",{type:"checkbox",checked:e.modelValue,disabled:n.value,indeterminate:e.indeterminate,class:"nb-checkbox__input",onChange:a},null,40,jA),b("span",KA,[e.modelValue&&!e.indeterminate?(g(),E("svg",qA,[...l[0]||(l[0]=[b("path",{d:"M1 4l3 3 5-6",stroke:"currentColor","stroke-width":"1.5","stroke-linecap":"round","stroke-linejoin":"round"},null,-1)])])):F("",!0),e.indeterminate?(g(),E("span",GA)):F("",!0)])]),e.label?(g(),E("span",YA,Z(e.label),1)):Pe(o.$slots,"default",{key:1},void 0,!0)],2))}}),[["__scopeId","data-v-3f69d297"]]),xu=function(e){return e.Small="sm",e.Medium="md",e.Large="lg",e}(xu||{}),Tu=function(e){return e.Primary="primary",e.Secondary="secondary",e}(Tu||{}),XA=["for"],JA=["id","name","disabled"],Sc=ht(Re({__name:"Switch",props:V_({id:{type:String,default:()=>null},label:{type:String,default:""},size:{type:String,default:xu.Medium,validator:e=>Object.values(xu).includes(e)},verbose:Boolean,name:{type:String,required:!0},disabled:Boolean,variant:{type:String,default:Tu.Primary,validator:e=>Object.values(Tu).includes(e)}},{modelValue:{type:Boolean},modelModifiers:{}}),emits:["update:modelValue"],setup(e){let t=z_(e,"modelValue"),i=e,r=cd(i),s=Q(()=>({"aria-disabled":i.disabled})),n=Q(()=>({"nb-switch":!0,disabled:i.disabled})),a=Q(()=>({"nb-switch-wrapper":!0,verbose:i.verbose,[i.size]:!0,[`nb-${i.variant}`]:!0}));return(o,l)=>(g(),de(Qi,{id:ue(r),class:xe(n.value),align:"center",gap:"sm"},{default:ee(()=>[e.label?(g(),de(sa,{key:0,for:`${ue(r)}-input`,disabled:e.disabled},{default:ee(()=>[ce(Z(e.label),1)]),_:1},8,["for","disabled"])):F("",!0),b("label",Jt({for:`${ue(r)}-input`,class:a.value},s.value,{onClick:l[1]||(l[1]=at(()=>{},["stop"]))}),[Xs(b("input",{id:`${ue(r)}-input`,"onUpdate:modelValue":l[0]||(l[0]=c=>t.value=c),name:e.name,type:"checkbox",disabled:e.disabled},null,8,JA),[[fm,t.value]]),l[2]||(l[2]=b("div",{class:"slider round"},null,-1))],16,XA)]),_:1},8,["id","class"]))}}),[["__scopeId","data-v-e4a5c8ba"]]);const la=(e,t,i)=>{const r=s=>Me("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:t,fill:"currentColor",...s,innerHTML:i});return r.displayName="NbGlyph",r.glyphName=e,r},QA=la("arrows-down-up","0 0 256 256",'<path d="M114.83,173.17a4,4,0,0,1,0,5.66l-32,32a4,4,0,0,1-5.66,0l-32-32a4,4,0,0,1,5.66-5.66L76,198.34V48a4,4,0,0,1,8,0V198.34l25.17-25.17A4,4,0,0,1,114.83,173.17Zm96-96-32-32a4,4,0,0,0-5.66,0l-32,32a4,4,0,0,0,5.66,5.66L172,57.66V208a4,4,0,0,0,8,0V57.66l25.17,25.17a4,4,0,1,0,5.66-5.66Z"/>'),eM=la("arrows-down-up","0 0 256 256",'<path d="M116.24,171.76a6,6,0,0,1,0,8.48l-32,32a6,6,0,0,1-8.48,0l-32-32a6,6,0,0,1,8.48-8.48L74,193.51V48a6,6,0,0,1,12,0V193.51l21.76-21.75A6,6,0,0,1,116.24,171.76Zm96-96-32-32a6,6,0,0,0-8.48,0l-32,32a6,6,0,0,0,8.48,8.48L170,62.49V208a6,6,0,0,0,12,0V62.49l21.76,21.75a6,6,0,0,0,8.48-8.48Z"/>'),_6=la("arrows-down-up","0 0 256 256",'<path d="M117.66,170.34a8,8,0,0,1,0,11.32l-32,32a8,8,0,0,1-11.32,0l-32-32a8,8,0,0,1,11.32-11.32L72,188.69V48a8,8,0,0,1,16,0V188.69l18.34-18.35A8,8,0,0,1,117.66,170.34Zm96-96-32-32a8,8,0,0,0-11.32,0l-32,32a8,8,0,0,0,11.32,11.32L168,67.31V208a8,8,0,0,0,16,0V67.31l18.34,18.35a8,8,0,0,0,11.32-11.32Z"/>'),tM=la("arrows-down-up","0 0 256 256",'<path d="M120.49,167.51a12,12,0,0,1,0,17l-32,32a12,12,0,0,1-17,0l-32-32a12,12,0,1,1,17-17L68,179V48a12,12,0,0,1,24,0V179l11.51-11.52A12,12,0,0,1,120.49,167.51Zm96-96-32-32a12,12,0,0,0-17,0l-32,32a12,12,0,0,0,17,17L164,77V208a12,12,0,0,0,24,0V77l11.51,11.52a12,12,0,0,0,17-17Z"/>'),iM=la("arrows-down-up","0 0 256 256",'<path d="M119.39,172.94a8,8,0,0,1-1.73,8.72l-32,32a8,8,0,0,1-11.32,0l-32-32A8,8,0,0,1,48,168H72V48a8,8,0,0,1,16,0V168h24A8,8,0,0,1,119.39,172.94Zm94.27-98.6-32-32a8,8,0,0,0-11.32,0l-32,32A8,8,0,0,0,144,88h24V208a8,8,0,0,0,16,0V88h24a8,8,0,0,0,5.66-13.66Z"/>'),rM=la("arrows-down-up","0 0 256 256",'<path d="M176,48V208H80V48Z" opacity="0.2"/><path d="M117.66,170.34a8,8,0,0,1,0,11.32l-32,32a8,8,0,0,1-11.32,0l-32-32a8,8,0,0,1,11.32-11.32L72,188.69V48a8,8,0,0,1,16,0V188.69l18.34-18.35A8,8,0,0,1,117.66,170.34Zm96-96-32-32a8,8,0,0,0-11.32,0l-32,32a8,8,0,0,0,11.32,11.32L168,67.31V208a8,8,0,0,0,16,0V67.31l18.34,18.35a8,8,0,0,0,11.32-11.32Z"/>'),sM="arrows-down-up",nM=Object.freeze(Object.defineProperty({__proto__:null,bold:tM,default:_6,duotone:rM,fill:iM,glyphName:sM,light:eM,regular:_6,thin:QA},Symbol.toStringTag,{value:"Module"})),ca=(e,t,i)=>{const r=s=>Me("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:t,fill:"currentColor",...s,innerHTML:i});return r.displayName="NbGlyph",r.glyphName=e,r},aM=ca("arrow-up","0 0 256 256",'<path d="M202.83,114.83a4,4,0,0,1-5.66,0L132,49.66V216a4,4,0,0,1-8,0V49.66L58.83,114.83a4,4,0,0,1-5.66-5.66l72-72a4,4,0,0,1,5.66,0l72,72A4,4,0,0,1,202.83,114.83Z"/>'),oM=ca("arrow-up","0 0 256 256",'<path d="M204.24,116.24a6,6,0,0,1-8.48,0L134,54.49V216a6,6,0,0,1-12,0V54.49L60.24,116.24a6,6,0,0,1-8.48-8.48l72-72a6,6,0,0,1,8.48,0l72,72A6,6,0,0,1,204.24,116.24Z"/>'),m6=ca("arrow-up","0 0 256 256",'<path d="M205.66,117.66a8,8,0,0,1-11.32,0L136,59.31V216a8,8,0,0,1-16,0V59.31L61.66,117.66a8,8,0,0,1-11.32-11.32l72-72a8,8,0,0,1,11.32,0l72,72A8,8,0,0,1,205.66,117.66Z"/>'),lM=ca("arrow-up","0 0 256 256",'<path d="M208.49,120.49a12,12,0,0,1-17,0L140,69V216a12,12,0,0,1-24,0V69L64.49,120.49a12,12,0,0,1-17-17l72-72a12,12,0,0,1,17,0l72,72A12,12,0,0,1,208.49,120.49Z"/>'),cM=ca("arrow-up","0 0 256 256",'<path d="M207.39,115.06A8,8,0,0,1,200,120H136v96a8,8,0,0,1-16,0V120H56a8,8,0,0,1-5.66-13.66l72-72a8,8,0,0,1,11.32,0l72,72A8,8,0,0,1,207.39,115.06Z"/>'),uM=ca("arrow-up","0 0 256 256",'<path d="M200,112H56l72-72Z" opacity="0.2"/><path d="M205.66,106.34l-72-72a8,8,0,0,0-11.32,0l-72,72A8,8,0,0,0,56,120h64v96a8,8,0,0,0,16,0V120h64a8,8,0,0,0,5.66-13.66ZM75.31,104,128,51.31,180.69,104Z"/>'),hM="arrow-up",dM=Object.freeze(Object.defineProperty({__proto__:null,bold:lM,default:m6,duotone:uM,fill:cM,glyphName:hM,light:oM,regular:m6,thin:aM},Symbol.toStringTag,{value:"Module"})),ua=(e,t,i)=>{const r=s=>Me("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:t,fill:"currentColor",...s,innerHTML:i});return r.displayName="NbGlyph",r.glyphName=e,r},fM=ua("arrow-down","0 0 256 256",'<path d="M202.83,146.83l-72,72a4,4,0,0,1-5.66,0l-72-72a4,4,0,0,1,5.66-5.66L124,206.34V40a4,4,0,0,1,8,0V206.34l65.17-65.17a4,4,0,0,1,5.66,5.66Z"/>'),pM=ua("arrow-down","0 0 256 256",'<path d="M204.24,148.24l-72,72a6,6,0,0,1-8.48,0l-72-72a6,6,0,0,1,8.48-8.48L122,201.51V40a6,6,0,0,1,12,0V201.51l61.76-61.75a6,6,0,0,1,8.48,8.48Z"/>'),g6=ua("arrow-down","0 0 256 256",'<path d="M205.66,149.66l-72,72a8,8,0,0,1-11.32,0l-72-72a8,8,0,0,1,11.32-11.32L120,196.69V40a8,8,0,0,1,16,0V196.69l58.34-58.35a8,8,0,0,1,11.32,11.32Z"/>'),_M=ua("arrow-down","0 0 256 256",'<path d="M208.49,152.49l-72,72a12,12,0,0,1-17,0l-72-72a12,12,0,0,1,17-17L116,187V40a12,12,0,0,1,24,0V187l51.51-51.52a12,12,0,0,1,17,17Z"/>'),mM=ua("arrow-down","0 0 256 256",'<path d="M205.66,149.66l-72,72a8,8,0,0,1-11.32,0l-72-72A8,8,0,0,1,56,136h64V40a8,8,0,0,1,16,0v96h64a8,8,0,0,1,5.66,13.66Z"/>'),gM=ua("arrow-down","0 0 256 256",'<path d="M200,144l-72,72L56,144Z" opacity="0.2"/><path d="M207.39,140.94A8,8,0,0,0,200,136H136V40a8,8,0,0,0-16,0v96H56a8,8,0,0,0-5.66,13.66l72,72a8,8,0,0,0,11.32,0l72-72A8,8,0,0,0,207.39,140.94ZM128,204.69,75.31,152H180.69Z"/>'),vM="arrow-down",bM=Object.freeze(Object.defineProperty({__proto__:null,bold:_M,default:g6,duotone:gM,fill:mM,glyphName:vM,light:pM,regular:g6,thin:fM},Symbol.toStringTag,{value:"Module"}));var yM={key:0,class:"nb-data-table__toolbar"},wM=["inert","aria-hidden"],SM={key:0},CM={key:0,class:"nb-data-table__title"},kM={key:1,class:"nb-data-table__description"},AM=["inert","aria-hidden"],MM={key:1,class:"nb-data-table__batch",role:"region","aria-label":"Table batch actions"},LM={class:"nb-data-table__batch-count"},EM={class:"nb-data-table__batch-actions"},$M={class:"nb-data-table__scroll"},xM=["aria-label","aria-busy"],TM={key:0,class:"nb-data-table__col-select"},NM={key:1,class:"nb-data-table__col-actions"},HM={class:"nb-data-table__head"},PM={key:0,scope:"col",class:"nb-data-table__th nb-data-table__select-cell"},OM=["aria-sort"],IM=["onClick"],RM={class:"nb-data-table__th-label"},DM={key:1,class:"nb-data-table__th-label"},VM={key:1,scope:"col",class:"nb-data-table__th nb-data-table__actions-cell"},BM={class:"nb-data-table__body"},ZM={key:0,class:"nb-data-table__td"},FM={key:1,class:"nb-data-table__td"},zM={key:1,class:"nb-data-table__state-row"},UM=["colspan"],WM={key:2,class:"nb-data-table__state-row"},jM=["colspan"],KM=["aria-selected","onClick"],qM=["checked","aria-label","onChange"],GM={key:1,class:"nb-data-table__footer"},K4=ht(Re({__name:"DataTable",props:{columns:{},rows:{},rowKey:{},size:{default:d4.Medium},sortState:{default:null},selectable:{default:"none"},selected:{default:()=>[]},loading:{type:Boolean,default:!1},skeletonRows:{default:5},error:{default:void 0},emptyMessage:{default:void 0},stickyHeader:{type:Boolean,default:!0},zebra:{type:Boolean,default:!1},fill:{type:Boolean,default:!1},title:{default:void 0},description:{default:void 0},ariaLabel:{default:void 0}},emits:["sort","update:selected","row-click"],setup(e,{emit:t}){let i=e,{layerProps:r}=In(),s=t,n=ks(),a=`nb-data-table-select-${qi()}`,o=Q(()=>i.size),l=Q(()=>i.columns.filter(O=>!O.hidden)),c=Q(()=>i.selectable!=="none"),u=Q(()=>!!n["row-actions"]),h=Q(()=>l.value.length+(c.value?1:0)+(u.value?1:0));function d(O){if(O.width!=null)return{width:typeof O.width=="number"?`${O.width}px`:O.width}}function f(O,ie){return ie[O.key]}function m(O){return O==null?"":String(O)}let _=O=>{var ie,le;return((le=(ie=O.column).render)==null?void 0:le.call(ie,O.row,f(O.column,O.row),O.rowIndex))??null};_.props=["column","row","rowIndex"];function y(O){let ie=i.rowKey;return typeof ie=="function"?ie(O):O[ie]}let p=Q(()=>new Set(i.selected)),C=Q(()=>i.selected),w=Q(()=>i.selected.length);function v(O){return p.value.has(y(O))}let k=Q(()=>i.rows.map(O=>y(O))),$=Q(()=>k.value.length>0&&k.value.every(O=>p.value.has(O))),M=Q(()=>!$.value&&k.value.some(O=>p.value.has(O))),D=X(null),H=!1;function R(O){H=O.shiftKey}Fe(k,()=>{D.value=null});function V(O,ie){let le=y(O),ge=new Set(i.selected),Se=!ge.has(le),x=D.value,T=K=>{Se?ge.add(K):ge.delete(K)};if(H&&x!==null&&x!==ie){let K=Math.min(x,ie),se=Math.max(x,ie);for(let he=K;he<=se;he++){let pe=i.rows[he];pe&&T(y(pe))}}else T(le),D.value=ie;H=!1,s("update:selected",[...ge])}function N(O){s("update:selected",[y(O)])}function P(){let O=new Set(i.selected);$.value?k.value.forEach(ie=>O.delete(ie)):k.value.forEach(ie=>O.add(ie)),s("update:selected",[...O])}function U(){s("update:selected",[])}let j=Q(()=>i.selectable!=="none"&&!!n["batch-actions"]),oe=Q(()=>j.value&&w.value>0),te=Q(()=>!!i.title||!!i.description||!!n.toolbar||!!n.search||!!n["toolbar-actions"]),ne=Q(()=>te.value||j.value);function J(O){return!!i.sortState&&i.sortState.key===O.key&&i.sortState.direction!=="none"}function fe(O){return J(O)?i.sortState.direction==="asc"?"ascending":"descending":"none"}function re(O){return J(O)?i.sortState.direction==="asc"?dM:bM:nM}function _e(O){return O==="asc"?"desc":O==="desc"?"none":"asc"}function Ne(O){let ie=i.sortState&&i.sortState.key===O.key?i.sortState.direction:"none";s("sort",{key:O.key,direction:_e(ie)})}let $e=ki(),be=Q(()=>{var O;return!!((O=$e==null?void 0:$e.vnode.props)!=null&&O.onRowClick)});function me(O,ie){s("row-click",O,ie)}return(O,ie)=>(g(),E("div",Jt({class:["nb-data-table",`nb-data-table--${e.size}`,{"nb-data-table--zebra":e.zebra},{"nb-data-table--sticky":e.stickyHeader},{"nb-data-table--fill":e.fill}]},ue(r)),[ne.value?(g(),E("div",yM,[b("div",{class:"nb-data-table__toolbar-heading",inert:oe.value||void 0,"aria-hidden":oe.value||void 0},[Pe(O.$slots,"toolbar",{selectedCount:w.value},()=>[e.title||e.description?(g(),E("div",SM,[e.title?(g(),E("h2",CM,Z(e.title),1)):F("",!0),e.description?(g(),E("p",kM,Z(e.description),1)):F("",!0)])):F("",!0)],!0)],8,wM),O.$slots.search||O.$slots["toolbar-actions"]?(g(),E("div",{key:0,class:"nb-data-table__toolbar-tools",inert:oe.value||void 0,"aria-hidden":oe.value||void 0},[Pe(O.$slots,"search",{},void 0,!0),Pe(O.$slots,"toolbar-actions",{},void 0,!0)],8,AM)):F("",!0),oe.value?(g(),E("div",MM,[b("span",LM,Z(w.value)+" selected ",1),b("div",EM,[Pe(O.$slots,"batch-actions",{selectedKeys:C.value,clear:U},void 0,!0)]),Y(oi,{class:"nb-data-table__batch-cancel",variant:"ghost",size:o.value,onClick:U},{default:ee(()=>[...ie[2]||(ie[2]=[ce(" Cancel ",-1)])]),_:1},8,["size"])])):F("",!0)])):F("",!0),b("div",$M,[b("table",{class:"nb-data-table__table","aria-label":e.ariaLabel||e.title||void 0,"aria-busy":e.loading||void 0},[b("colgroup",null,[c.value?(g(),E("col",TM)):F("",!0),(g(!0),E(we,null,Be(l.value,le=>(g(),E("col",{key:`col-${le.key}`,style:Ci(d(le))},null,4))),128)),u.value?(g(),E("col",NM)):F("",!0)]),b("thead",HM,[b("tr",null,[c.value?(g(),E("th",PM,[e.selectable==="multiple"?(g(),de(p6,{key:0,"model-value":$.value,indeterminate:M.value,"aria-label":"Select all rows","onUpdate:modelValue":P},null,8,["model-value","indeterminate"])):F("",!0)])):F("",!0),(g(!0),E(we,null,Be(l.value,le=>(g(),E("th",{key:`th-${le.key}`,scope:"col",class:xe(["nb-data-table__th",`nb-data-table__th--${le.align||"left"}`,{"nb-data-table__th--sortable":le.sortable},{"nb-data-table__th--sorted":J(le)}]),"aria-sort":le.sortable?fe(le):void 0},[le.sortable?(g(),E("button",{key:0,type:"button",class:"nb-data-table__sort",onClick:ge=>Ne(le)},[b("span",RM,[Pe(O.$slots,`header-${le.key}`,{column:le},()=>[ce(Z(le.header),1)],!0)]),Y(Ge,{name:re(le),class:"nb-data-table__sort-icon","aria-hidden":"true"},null,8,["name"])],8,IM)):(g(),E("span",DM,[Pe(O.$slots,`header-${le.key}`,{column:le},()=>[ce(Z(le.header),1)],!0)]))],10,OM))),128)),u.value?(g(),E("th",VM,[...ie[3]||(ie[3]=[b("span",{class:"nb-sr-only"},"Row actions",-1)])])):F("",!0)])]),b("tbody",BM,[e.loading?(g(!0),E(we,{key:0},Be(e.skeletonRows,le=>(g(),E("tr",{key:`skeleton-${le}`,class:"nb-data-table__row nb-data-table__row--skeleton"},[c.value?(g(),E("td",ZM,[...ie[4]||(ie[4]=[b("span",{class:"nb-data-table__skeleton nb-data-table__skeleton--box"},null,-1)])])):F("",!0),(g(!0),E(we,null,Be(l.value,ge=>(g(),E("td",{key:`sk-${le}-${ge.key}`,class:"nb-data-table__td"},[...ie[5]||(ie[5]=[b("span",{class:"nb-data-table__skeleton"},null,-1)])]))),128)),u.value?(g(),E("td",FM,[...ie[6]||(ie[6]=[b("span",{class:"nb-data-table__skeleton nb-data-table__skeleton--box"},null,-1)])])):F("",!0)]))),128)):e.error?(g(),E("tr",zM,[b("td",{colspan:h.value,class:"nb-data-table__state nb-data-table__state--error"},[Pe(O.$slots,"error",{error:e.error},()=>[Y(Qi,{is:"span",align:"center",justify:"center",gap:"xs",class:"nb-data-table__state-inner"},{default:ee(()=>[Y(Ge,{name:"warning-circle-fill","aria-hidden":"true"}),b("span",null,Z(e.error),1)]),_:1})],!0)],8,UM)])):e.rows.length?(g(!0),E(we,{key:3},Be(e.rows,(le,ge)=>(g(),E("tr",{key:y(le),class:xe(["nb-data-table__row",{"nb-data-table__row--selected":v(le)},{"nb-data-table__row--clickable":be.value}]),"aria-selected":e.selectable==="none"?void 0:v(le),onClick:Se=>me(le,ge)},[c.value?(g(),E("td",{key:0,class:"nb-data-table__td nb-data-table__select-cell",onClick:ie[0]||(ie[0]=at(()=>{},["stop"])),onMousedown:R,onKeydown:R},[e.selectable==="multiple"?(g(),de(p6,{key:0,"model-value":v(le),"aria-label":`Select row ${ge+1}`,"onUpdate:modelValue":Se=>V(le,ge)},null,8,["model-value","aria-label","onUpdate:modelValue"])):(g(),E("input",{key:1,type:"radio",class:"nb-data-table__radio",name:a,checked:v(le),"aria-label":`Select row ${ge+1}`,onChange:Se=>N(le)},null,40,qM))],32)):F("",!0),(g(!0),E(we,null,Be(l.value,Se=>(g(),E("td",{key:`td-${y(le)}-${Se.key}`,class:xe(["nb-data-table__td",`nb-data-table__td--${Se.align||"left"}`,Se.cellClass])},[Pe(O.$slots,`cell-${Se.key}`,{row:le,value:f(Se,le),column:Se,rowIndex:ge},()=>[Se.render?(g(),de(_,{key:0,column:Se,row:le,"row-index":ge},null,8,["column","row","row-index"])):(g(),E(we,{key:1},[ce(Z(m(f(Se,le))),1)],64))],!0)],2))),128)),u.value?(g(),E("td",{key:1,class:"nb-data-table__td nb-data-table__actions-cell",onClick:ie[1]||(ie[1]=at(()=>{},["stop"]))},[Pe(O.$slots,"row-actions",{row:le,rowIndex:ge},void 0,!0)])):F("",!0)],10,KM))),128)):(g(),E("tr",WM,[b("td",{colspan:h.value,class:"nb-data-table__state nb-data-table__state--empty"},[Pe(O.$slots,"empty",{},()=>[b("span",null,Z(e.emptyMessage||"No data to display"),1)],!0)],8,jM)]))])],8,xM)]),O.$slots.footer?(g(),E("div",GM,[Pe(O.$slots,"footer",{},void 0,!0)])):F("",!0)],16))}}),[["__scopeId","data-v-e2562ae7"]]);const YM=(e,t,i)=>{const r=s=>Me("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:t,fill:"currentColor",...s,innerHTML:i});return r.displayName="NbGlyph",r.glyphName=e,r},v6=YM("caret-up","0 0 256 256",'<path d="M213.66,165.66a8,8,0,0,1-11.32,0L128,91.31,53.66,165.66a8,8,0,0,1-11.32-11.32l80-80a8,8,0,0,1,11.32,0l80,80A8,8,0,0,1,213.66,165.66Z"/>');var XM=["id","aria-expanded","aria-disabled","aria-required","disabled"],JM=["id","aria-expanded","aria-disabled","aria-required","disabled"],QM={key:1,class:"nb-select__inner-label"},eL={key:0,class:"nb-select__asterisk","aria-hidden":"true"},tL=["aria-multiselectable"],iL=["aria-selected","aria-disabled","onMouseenter","onClick"],rL={key:0,class:"nb-select__option-check","aria-hidden":"true"},sL={key:0,viewBox:"0 0 10 8",fill:"none",width:"10",height:"8"},nL={class:"nb-select__option-label"},aL={key:0,class:"nb-select__empty"},oL=["placeholder","onKeydown"],Cc=Re({__name:"Select",props:{modelValue:{default:null},options:{default:()=>[]},multiple:{type:Boolean,default:!1},creatable:{type:Boolean,default:!1},createPlaceholder:{default:""},placeholder:{default:"Select…"},name:{default:""},disabled:{type:Boolean,default:!1},required:{type:Boolean,default:!1},id:{default:void 0},label:{default:""},error:{default:""},warning:{default:""},helper:{default:""},variant:{default:"default"},size:{default:"md"}},emits:["update:modelValue","change","create"],setup(e,{expose:t,emit:i}){let r=e,s=i,n=X("");function a(){let U=n.value.trim();U&&(s("create",U),n.value="")}let o=X(!1),l=X(!1),c=X(-1),u=X(null),h=X(null),d=X(null),f=X({position:"fixed",top:"0px",left:"0px",width:"0px",zIndex:"9999"}),m=`nb-select-${qi()}`,_=Q(()=>r.id??m),y=Q(()=>r.modelValue==null?[]:Array.isArray(r.modelValue)?r.modelValue:[r.modelValue]),p=Q(()=>{var U;if(!(r.multiple||y.value.length!==1))return(U=(r.options??[]).find(j=>j.value===y.value[0]))==null?void 0:U.icon}),C=Q(()=>{var j,oe;if(y.value.length===0)return"";let U=r.options??[];return r.multiple?y.value.length===1?((j=U.find(te=>te.value===y.value[0]))==null?void 0:j.label)??String(y.value[0]):y.value.length===2?y.value.map(te=>{var ne;return((ne=U.find(J=>J.value===te))==null?void 0:ne.label)??String(te)}).join(", "):`${y.value.length} selected`:((oe=U.find(te=>te.value===y.value[0]))==null?void 0:oe.label)??String(y.value[0])});function w(U){return y.value.includes(U)}function v(U){if(U.disabled)return;let j;if(r.multiple){let oe=[...y.value],te=oe.indexOf(U.value);te>=0?oe.splice(te,1):oe.push(U.value),j=oe}else j=U.value,M();s("update:modelValue",j),s("change",j)}function k(){var ne;if(!h.value)return;let U=h.value.getBoundingClientRect(),j=((ne=d.value)==null?void 0:ne.offsetHeight)??0,oe=window.innerHeight-U.bottom,te=U.top;f.value={position:"fixed",top:j>0&&oe<j&&te>oe?`${U.top-j}px`:`${U.bottom}px`,left:`${U.left}px`,width:`${U.width}px`,zIndex:"9999"}}function $(){if(r.disabled)return;o.value=!0,k();let U=r.options??[];c.value=y.value.length>0?Math.max(0,U.findIndex(j=>j.value===y.value[0])):-1,_i(()=>{k(),N()})}function M(){o.value=!1,c.value=-1}function D(){o.value?M():$()}function H(U){var ne,J;let j=U.target,oe=((ne=u.value)==null?void 0:ne.contains(j))??!1,te=((J=d.value)==null?void 0:J.contains(j))??!1;!oe&&!te&&M()}function R(){o.value&&k()}Fe(o,U=>{U?(document.addEventListener("mousedown",H),window.addEventListener("scroll",R,!0),window.addEventListener("resize",R)):(document.removeEventListener("mousedown",H),window.removeEventListener("scroll",R,!0),window.removeEventListener("resize",R))}),Gi(()=>{document.removeEventListener("mousedown",H),window.removeEventListener("scroll",R,!0),window.removeEventListener("resize",R)});function V(U){let j=r.options??[];if(!o.value){(U.key==="Enter"||U.key===" "||U.key==="ArrowDown")&&(U.preventDefault(),$());return}U.key==="Escape"?(M(),U.preventDefault()):U.key==="Tab"?M():U.key==="ArrowDown"?(U.preventDefault(),c.value=Math.min(c.value+1,j.length-1),N()):U.key==="ArrowUp"?(U.preventDefault(),c.value=Math.max(c.value-1,0),N()):(U.key==="Enter"||U.key===" ")&&c.value>=0&&(U.preventDefault(),v(j[c.value]))}function N(){_i(()=>{var U;!d.value||c.value<0||((U=d.value.querySelectorAll(".nb-select__option")[c.value])==null||U.scrollIntoView({block:"nearest"}))})}let P=Q(()=>["nb-select",`nb-select--${r.variant}`,`nb-select--${r.size}`,{"nb-select--open":o.value,"nb-select--focused":l.value&&!o.value,"nb-select--error":!!r.error,"nb-select--warning":!r.error&&!!r.warning,"nb-select--multiple":r.multiple}]);return t({open:$,close:M}),(U,j)=>(g(),E(we,null,[b("div",{ref_key:"rootRef",ref:u,class:xe(P.value),onKeydown:V},[e.variant==="default"?(g(),E(we,{key:0},[U.$slots.label?Pe(U.$slots,"label",{key:0}):e.label?(g(),de(sa,{key:1,for:_.value,required:e.required,disabled:e.disabled},{default:ee(()=>[ce(Z(e.label),1)]),_:1},8,["for","required","disabled"])):F("",!0),b("button",{id:_.value,ref_key:"triggerRef",ref:h,type:"button",class:"nb-select__trigger",role:"combobox","aria-expanded":o.value,"aria-haspopup":"listbox","aria-disabled":e.disabled||void 0,"aria-required":e.required||void 0,disabled:e.disabled||void 0,onClick:D,onFocus:j[0]||(j[0]=oe=>l.value=!0),onBlur:j[1]||(j[1]=oe=>l.value=!1)},[b("span",{class:xe(["nb-select__value",{"nb-select__value--placeholder":!C.value,"nb-select__value--with-icon":!!p.value}])},[p.value?(g(),de(Ge,{key:0,class:"nb-select__value-icon",name:p.value,size:16},null,8,["name"])):F("",!0),C.value?Pe(U.$slots,"value",{key:1,values:y.value},()=>[ce(Z(C.value),1)]):(g(),E(we,{key:2},[ce(Z(e.placeholder),1)],64))],2),e.error?(g(),de(Qe,{key:0,variant:"error","icon-only":!0,class:"nb-select__status-icon"},{default:ee(()=>[ce(Z(e.error),1)]),_:1})):e.warning?(g(),de(Qe,{key:1,variant:"warning","icon-only":!0,class:"nb-select__status-icon"},{default:ee(()=>[ce(Z(e.warning),1)]),_:1})):F("",!0),Y(Qi,{align:"center",justify:"center",class:"nb-select__caret"},{default:ee(()=>[Y(Ge,{name:o.value?ue(v6):ue(Hf),size:16},null,8,["name"])]),_:1})],40,XM),e.error?(g(),de(Qe,{key:2,variant:"error",class:"nb-select__message"},{default:ee(()=>[ce(Z(e.error),1)]),_:1})):e.warning?(g(),de(Qe,{key:3,variant:"warning",class:"nb-select__message"},{default:ee(()=>[ce(Z(e.warning),1)]),_:1})):e.helper?(g(),de(Qe,{key:4,variant:"helper",class:"nb-select__message"},{default:ee(()=>[ce(Z(e.helper),1)]),_:1})):F("",!0)],64)):e.variant==="fluid"?(g(),E(we,{key:1},[b("button",{id:_.value,ref_key:"triggerRef",ref:h,type:"button",class:"nb-select__trigger",role:"combobox","aria-expanded":o.value,"aria-haspopup":"listbox","aria-disabled":e.disabled||void 0,"aria-required":e.required||void 0,disabled:e.disabled||void 0,onClick:D,onFocus:j[2]||(j[2]=oe=>l.value=!0),onBlur:j[3]||(j[3]=oe=>l.value=!1)},[e.label||U.$slots.label?(g(),de(Qi,{key:0,dir:"row",align:"center",gap:"xs",class:"nb-select__inner-header"},{default:ee(()=>[U.$slots.label?Pe(U.$slots,"label",{key:0}):(g(),E("label",QM,[ce(Z(e.label)+" ",1),e.required?(g(),E("span",eL,"*")):F("",!0)])),e.helper&&!e.error&&!e.warning?(g(),de(Qe,{key:2,variant:"helper","icon-only":!0,class:"nb-select__inner-message"},{default:ee(()=>[ce(Z(e.helper),1)]),_:1})):F("",!0)]),_:3})):F("",!0),Y(Qi,{dir:"row",align:"end",flex:"",class:"nb-select__value-row"},{default:ee(()=>[b("span",{class:xe(["nb-select__value",{"nb-select__value--placeholder":!C.value,"nb-select__value--with-icon":!!p.value}])},[p.value?(g(),de(Ge,{key:0,class:"nb-select__value-icon",name:p.value,size:16},null,8,["name"])):F("",!0),C.value?Pe(U.$slots,"value",{key:1,values:y.value},()=>[ce(Z(C.value),1)]):(g(),E(we,{key:2},[ce(Z(e.placeholder),1)],64))],2),Y(Qi,{align:"center",justify:"center",class:"nb-select__caret"},{default:ee(()=>[Y(Ge,{name:o.value?ue(v6):ue(Hf),size:16},null,8,["name"])]),_:1})]),_:3})],40,JM),e.error?(g(),de(Qe,{key:0,variant:"error",class:"nb-select__fluid-message"},{default:ee(()=>[ce(Z(e.error),1)]),_:1})):e.warning?(g(),de(Qe,{key:1,variant:"warning",class:"nb-select__fluid-message"},{default:ee(()=>[ce(Z(e.warning),1)]),_:1})):F("",!0)],64)):F("",!0)],34),(g(),de(br,{to:"body"},[o.value?(g(),E("div",{key:0,ref_key:"dropdownRef",ref:d,class:"nb-select__dropdown",style:Ci(f.value),role:"listbox","aria-multiselectable":e.multiple||void 0},[(g(!0),E(we,null,Be(e.options,(oe,te)=>(g(),E("div",{key:oe.value,class:xe(["nb-select__option",{"nb-select__option--selected":w(oe.value),"nb-select__option--highlighted":c.value===te,"nb-select__option--disabled":oe.disabled}]),role:"option","aria-selected":w(oe.value),"aria-disabled":oe.disabled||void 0,onMouseenter:ne=>c.value=te,onClick:ne=>v(oe)},[e.multiple?(g(),E("span",rL,[w(oe.value)?(g(),E("svg",sL,[...j[7]||(j[7]=[b("path",{d:"M1 4l3 3 5-6",stroke:"currentColor","stroke-width":"1.5","stroke-linecap":"round","stroke-linejoin":"round"},null,-1)])])):F("",!0)])):F("",!0),oe.icon?(g(),de(Ge,{key:1,class:"nb-select__option-icon",name:oe.icon,size:16},null,8,["name"])):F("",!0),b("span",nL,[Pe(U.$slots,"option",{option:oe},()=>[ce(Z(oe.label),1)])])],42,iL))),128)),!e.options||e.options.length===0?(g(),E("div",aL," No options ")):F("",!0),e.creatable?(g(),E("div",{key:1,class:"nb-select__create",onMousedown:j[6]||(j[6]=at(()=>{},["prevent"]))},[Xs(b("input",{"onUpdate:modelValue":j[4]||(j[4]=oe=>n.value=oe),type:"text",class:"nb-select__create-input",placeholder:e.createPlaceholder||"Add new…",onKeydown:[Br(at(a,["prevent"]),["enter"]),j[5]||(j[5]=at(()=>{},["stop"]))]},null,40,oL),[[L0,n.value]])],32)):F("",!0)],12,tL)):F("",!0)]))],64))}}),lL=["width","height","aria-label"],cL={key:0},uL=["x1","x2","y1","y2"],hL={class:"nb-chart__axis"},dL=["x","y"],fL={class:"nb-chart__axis"},pL=["x","y"],_L=["x1","x2","y1","y2"],mL=["y","transform"],gL=["x","y"],vL=["d","fill"],bL=["d","stroke"],yL=["cx","cy","r","fill","onMousedown","onContextmenu"],wL={key:5},SL=["x1","x2","y1","y2"],CL=["x1","x2","y1","y2"],kL="var(--nb-c-surface)",AL=ht(Re({__name:"InterpolationChart",props:{modelValue:{default:()=>[]},inputLabel:{default:void 0},outputLabel:{default:void 0},inputMin:{default:0},inputMax:{default:100},outputMin:{default:0},outputMax:{default:100},editable:{type:Boolean,default:!0},minPoints:{default:2},inputStep:{default:0},outputStep:{default:0},title:{default:void 0},subtitle:{default:void 0},height:{default:280},showLegend:{type:Boolean,default:!1},showTooltip:{type:Boolean,default:!0},showGrid:{type:Boolean,default:!0},colors:{default:()=>[]}},emits:["update:modelValue"],setup(e,{emit:t}){let i=e,r=t,s=Q(()=>fd(0,i.colors)),n={top:16,right:16,bottom:32,left:48},a=X(null),o=_d(a,{width:480,height:240}),l=Q(()=>Math.max(0,o.value.width-n.left-n.right)),c=Q(()=>Math.max(0,o.value.height-n.top-n.bottom)),u=Q(()=>[...i.modelValue].sort((be,me)=>be.input-me.input)),h=Q(()=>[i.inputMin,i.inputMax]),d=Q(()=>{let be=u.value.map(me=>me.output);return pd(Math.min(i.outputMin,...be),Math.max(i.outputMax,...be),.05)}),f=Q(()=>O0(h.value,[n.left,o.value.width-n.right])),m=Q(()=>O0(d.value,[o.value.height-n.bottom,n.top])),_=Q(()=>f.value.ticks(6)),y=Q(()=>m.value.ticks(5)),p=be=>{let[me,O]=h.value,[ie,le]=f.value.range;return me+(be-ie)/(le-ie)*(O-me)},C=be=>{let[me,O]=d.value,[ie,le]=m.value.range;return me+(be-ie)/(le-ie)*(O-me)},w=(be,me)=>!me||me<=0?be:Math.round(be/me)*me,v=(be,me,O)=>Math.max(me,Math.min(O,be)),k=(be,me=1)=>Math.round(be*10**me)/10**me,$=Q(()=>{let be=u.value;return be.length<2?"":be.map((me,O)=>`${O===0?"M":"L"}${f.value(me.input)},${m.value(me.output)}`).join(" ")}),M=Q(()=>{let be=u.value;if(be.length<2)return"";let me=o.value.height-n.bottom;return`${be.map((O,ie)=>`${ie===0?"M":"L"}${f.value(O.input)},${m.value(O.output)}`).join(" ")} L${f.value(be[be.length-1].input)},${me} L${f.value(be[0].input)},${me} Z`}),D=X(null),H=X(null);function R(be){r("update:modelValue",[...be].sort((me,O)=>me.input-O.input))}function V(be,me){i.editable&&(D.value=be,window.addEventListener("mousemove",P),window.addEventListener("mouseup",U))}function N(be){var ie;let me=(ie=a.value)==null?void 0:ie.querySelector("svg");if(!me)return null;let O=me.getBoundingClientRect();return{px:be.clientX-O.left,py:be.clientY-O.top}}function P(be){if(D.value===null)return;let me=N(be);if(!me)return;let O=p(me.px),ie=C(me.py),le=[...u.value],ge=D.value,Se=i.inputStep>0?i.inputStep:.1;le[ge]={input:k(w(v(O,ge>0?le[ge-1].input+Se:i.inputMin,ge<le.length-1?le[ge+1].input-Se:i.inputMax),i.inputStep)),output:k(w(v(ie,i.outputMin,i.outputMax),i.outputStep))},R(le)}function U(){D.value=null,window.removeEventListener("mousemove",P),window.removeEventListener("mouseup",U)}function j(be){if(D.value!==null)return;let me=N(be);if(!me)return;let O=-1,ie=1/0;for(let le=0;le<u.value.length;le++){let ge=u.value[le],Se=f.value(ge.input)-me.px,x=m.value(ge.output)-me.py,T=Math.sqrt(Se*Se+x*x);T<ie&&(ie=T,O=le)}H.value=ie<20?O:null,fe.value={x:me.px+12,y:me.py-12}}function oe(){D.value===null&&(H.value=null)}function te(){D.value!==null&&(D.value=null,window.removeEventListener("mousemove",P),window.removeEventListener("mouseup",U))}function ne(be){if(!i.editable)return;let me=N(be);if(!me)return;let O=p(me.px),ie=C(me.py);if(O<i.inputMin||O>i.inputMax||ie<i.outputMin||ie>i.outputMax)return;let le=k(w(v(O,i.inputMin,i.inputMax),i.inputStep)),ge=k(w(v(ie,i.outputMin,i.outputMax),i.outputStep));R([...u.value,{input:le,output:ge}])}function J(be){i.editable&&(u.value.length<=i.minPoints||R(u.value.filter((me,O)=>O!==be)))}Gi(()=>{window.removeEventListener("mousemove",P),window.removeEventListener("mouseup",U)});let fe=X({x:0,y:0}),re=Q(()=>H.value!==null||D.value!==null),_e=Q(()=>{let be=D.value??H.value;return be===null?"":`Point ${be+1}`}),Ne=Q(()=>{let be=D.value??H.value;if(be===null||be>=u.value.length)return[];let me=u.value[be];return[{label:i.inputLabel||"Input",value:$e(me.input),color:s.value},{label:i.outputLabel||"Output",value:$e(me.output),color:s.value}]}),$e=be=>Number.isInteger(be)?String(be):be.toFixed(1);return(be,me)=>(g(),de(hd,{title:e.title,subtitle:e.subtitle,height:e.height,"show-legend":!1},{default:ee(()=>[b("div",{ref_key:"root",ref:a,class:"nb-interpolation-chart"},[(g(),E("svg",{width:ue(o).width,height:ue(o).height,class:"nb-chart__svg",role:"img","aria-label":e.title||"Interpolation chart",onMousemove:j,onMouseleave:oe,onMouseup:te,onDblclick:ne,onContextmenu:me[0]||(me[0]=at(()=>{},["prevent"]))},[e.showGrid&&ue(o).width>0?(g(),E("g",cL,[(g(!0),E(we,null,Be(y.value,O=>(g(),E("line",{key:`grid-${O}`,class:"nb-chart__gridline",x1:n.left,x2:ue(o).width-n.right,y1:m.value(O),y2:m.value(O)},null,8,uL))),128))])):F("",!0),b("g",hL,[(g(!0),E(we,null,Be(y.value,O=>(g(),E("text",{key:`yt-${O}`,x:n.left-6,y:m.value(O),"text-anchor":"end","dominant-baseline":"middle"},Z($e(O)),9,dL))),128))]),b("g",fL,[(g(!0),E(we,null,Be(_.value,O=>(g(),E("text",{key:`xt-${O}`,x:f.value(O),y:ue(o).height-n.bottom+14,"text-anchor":"middle"},Z($e(O)),9,pL))),128))]),b("line",{class:"nb-chart__axis-line",x1:n.left,x2:ue(o).width-n.right,y1:ue(o).height-n.bottom,y2:ue(o).height-n.bottom},null,8,_L),e.outputLabel?(g(),E("text",{key:1,class:"nb-chart__axis-label",x:12,y:n.top+c.value/2,"text-anchor":"middle",transform:`rotate(-90, 12, ${n.top+c.value/2})`},Z(e.outputLabel),9,mL)):F("",!0),e.inputLabel?(g(),E("text",{key:2,class:"nb-chart__axis-label",x:n.left+l.value/2,y:ue(o).height-2,"text-anchor":"middle"},Z(e.inputLabel),9,gL)):F("",!0),u.value.length>=2?(g(),E("path",{key:3,class:"nb-interpolation-chart__area",d:M.value,fill:s.value,opacity:"0.12"},null,8,vL)):F("",!0),u.value.length>=2?(g(),E("path",{key:4,class:"nb-interpolation-chart__line",d:$.value,stroke:s.value,fill:"none","stroke-width":"2","stroke-linejoin":"round","stroke-linecap":"round"},null,8,bL)):F("",!0),(g(!0),E(we,null,Be(u.value,(O,ie)=>(g(),E("circle",{key:`pt-${ie}`,class:xe(["nb-interpolation-chart__point",{"nb-interpolation-chart__point--editable":e.editable,"nb-interpolation-chart__point--dragging":D.value===ie,"nb-interpolation-chart__point--hover":H.value===ie&&D.value===null}]),cx:f.value(O.input),cy:m.value(O.output),r:D.value===ie?7:H.value===ie?6:5,fill:s.value,stroke:kL,"stroke-width":"2",onMousedown:at(le=>V(ie,le),["prevent"]),onContextmenu:at(le=>J(ie),["prevent"])},null,42,yL))),128)),D.value===null?F("",!0):(g(),E("g",wL,[b("line",{class:"nb-interpolation-chart__crosshair",x1:f.value(u.value[D.value].input),x2:f.value(u.value[D.value].input),y1:n.top,y2:ue(o).height-n.bottom},null,8,SL),b("line",{class:"nb-interpolation-chart__crosshair",x1:n.left,x2:ue(o).width-n.right,y1:m.value(u.value[D.value].output),y2:m.value(u.value[D.value].output)},null,8,CL)]))],40,lL)),Y(dd,{visible:e.showTooltip&&re.value,x:fe.value.x,y:fe.value.y,title:_e.value,rows:Ne.value},null,8,["visible","x","y","title","rows"])],512)]),_:1},8,["title","subtitle","height"]))}}),[["__scopeId","data-v-676875de"]]),ML=["width","height","aria-label"],LL={key:0},EL=["x1","x2","y1","y2"],$L={class:"nb-chart__axis"},xL=["x","y"],TL={class:"nb-chart__axis"},NL=["x","y"],HL=["x1","x2","y1","y2"],PL=["d","fill"],OL=["d","stroke"],IL=["cx","cy","r","fill"],RL=["x1","x2","y1","y2"],DL=ht(Re({__name:"LineChart",props:{series:{default:()=>[]},area:{type:Boolean,default:!1},points:{type:Boolean,default:!1},curve:{default:"smooth"},title:{default:void 0},subtitle:{default:void 0},height:{default:280},showLegend:{type:Boolean,default:!0},showTooltip:{type:Boolean,default:!0},showGrid:{type:Boolean,default:!0},colors:{default:()=>P0}},setup(e){let t=e,i={top:12,right:16,bottom:28,left:44},r=X(null),s=_d(r,{width:480,height:240}),n=Q(()=>t.series.map((k,$)=>({name:k.name,data:k.data,color:k.color??fd($,t.colors)}))),a=Q(()=>{var k;return(((k=t.series[0])==null?void 0:k.data)??[]).map($=>$.x)}),o=Q(()=>{let k=t.series.flatMap($=>$.data.map(M=>M.y));return k.length?pd(Math.min(0,...k),Math.max(...k),.1):[0,1]}),l=Q(()=>O0(o.value,[Math.max(i.top,s.value.height-i.bottom),i.top])),c=Q(()=>l.value.ticks(5)),u=Q(()=>Math.max(0,s.value.width-i.left-i.right)),h=k=>{let $=a.value.length;return $<=1?i.left+u.value/2:i.left+k/($-1)*u.value},d=Q(()=>{let k=a.value,$=Math.max(1,Math.ceil(k.length/6)),M=[];for(let D=0;D<k.length;D+=$)M.push({index:D,value:k[D]});return k.length&&M[M.length-1].index!==k.length-1&&M.push({index:k.length-1,value:k[k.length-1]}),M}),f=k=>k.length?_(k.map(($,M)=>[h(M),l.value($.y)]),t.curve):"",m=k=>{if(!k.length)return"";let $=k.map((D,H)=>[h(H),l.value(D.y)]),M=s.value.height-i.bottom;return`${_($,t.curve)} L${$[$.length-1][0]},${M} L${$[0][0]},${M} Z`},_=(k,$)=>{if(!k.length)return"";if(k.length===1)return`M${k[0][0]},${k[0][1]}`;if($==="linear")return k.map((H,R)=>`${R===0?"M":"L"}${H[0]},${H[1]}`).join(" ");if($==="step"){let H=`M${k[0][0]},${k[0][1]}`;for(let R=1;R<k.length;R++){let[V,N]=k[R-1],[P,U]=k[R],j=(V+P)/2;H+=` L${j},${N} L${j},${U} L${P},${U}`}return H}let M=.2,D=`M${k[0][0]},${k[0][1]}`;for(let H=0;H<k.length-1;H++){let R=k[H-1]??k[H],V=k[H],N=k[H+1],P=k[H+2]??N,U=V[0]+(N[0]-R[0])*M,j=V[1]+(N[1]-R[1])*M,oe=N[0]-(P[0]-V[0])*M,te=N[1]-(P[1]-V[1])*M;D+=` C${U},${j} ${oe},${te} ${N[0]},${N[1]}`}return D},y=k=>Math.abs(k)>=1e3?`${(k/1e3).toFixed(1)}k`:Number.isInteger(k)?String(k):k.toFixed(1),p=X(null),C=X({x:0,y:0}),w=k=>{let $=k.currentTarget.getBoundingClientRect(),M=k.clientX-$.left,D=a.value.length;if(!D)return;let H=(M-i.left)/Math.max(1,u.value);p.value=Math.round(Math.min(1,Math.max(0,H))*(D-1)),C.value={x:k.clientX-$.left+12,y:k.clientY-$.top+12}},v=Q(()=>p.value===null?[]:n.value.map(k=>{var $;return{label:k.name,value:y((($=k.data[p.value])==null?void 0:$.y)??0),color:k.color}}));return(k,$)=>(g(),de(hd,{title:e.title,subtitle:e.subtitle,height:e.height,"show-legend":e.showLegend&&n.value.length>0},{legend:ee(()=>[Y(S4,{items:n.value.map(M=>({label:M.name,color:M.color}))},null,8,["items"])]),default:ee(()=>[b("div",{ref_key:"root",ref:r,class:"nb-line-chart"},[(g(),E("svg",{width:ue(s).width,height:ue(s).height,class:"nb-chart__svg",role:"img","aria-label":e.title||"Line chart",onMouseleave:$[0]||($[0]=M=>p.value=null),onMousemove:w},[e.showGrid&&ue(s).width>0?(g(),E("g",LL,[(g(!0),E(we,null,Be(c.value,M=>(g(),E("line",{key:`grid-${M}`,class:"nb-chart__gridline",x1:i.left,x2:ue(s).width-i.right,y1:l.value(M),y2:l.value(M)},null,8,EL))),128))])):F("",!0),b("g",$L,[(g(!0),E(we,null,Be(c.value,M=>(g(),E("text",{key:`yt-${M}`,x:i.left-6,y:l.value(M),"text-anchor":"end","dominant-baseline":"middle"},Z(y(M)),9,xL))),128))]),b("g",TL,[(g(!0),E(we,null,Be(d.value,(M,D)=>(g(),E("text",{key:`xt-${D}`,x:h(M.index),y:ue(s).height-i.bottom+14,"text-anchor":"middle"},Z(M.value),9,NL))),128))]),b("line",{class:"nb-chart__axis-line",x1:i.left,x2:ue(s).width-i.right,y1:ue(s).height-i.bottom,y2:ue(s).height-i.bottom},null,8,HL),(g(!0),E(we,null,Be(n.value,(M,D)=>(g(),E("g",{key:`s-${D}`},[e.area?(g(),E("path",{key:0,class:"nb-chart__area",d:m(M.data),fill:M.color,opacity:"0.18"},null,8,PL)):F("",!0),b("path",{class:"nb-chart__line",d:f(M.data),stroke:M.color,fill:"none","stroke-width":"2","stroke-linejoin":"round","stroke-linecap":"round"},null,8,OL),e.points?(g(!0),E(we,{key:1},Be(M.data,(H,R)=>(g(),E("circle",{key:`p-${D}-${R}`,cx:h(R),cy:l.value(H.y),r:p.value===R?4:3,fill:M.color,class:"nb-chart__point"},null,8,IL))),128)):F("",!0)]))),128)),p.value===null?F("",!0):(g(),E("line",{key:1,class:"nb-chart__hover-line",x1:h(p.value),x2:h(p.value),y1:i.top,y2:ue(s).height-i.bottom},null,8,RL))],40,ML)),Y(dd,{visible:e.showTooltip&&p.value!==null,x:C.value.x,y:C.value.y,title:p.value===null?"":String(a.value[p.value]),rows:v.value},null,8,["visible","x","y","title","rows"])],512)]),_:1},8,["title","subtitle","height","show-legend"]))}}),[["__scopeId","data-v-728da300"]]),VL=["for","title"],BL={class:"nb-field__control"},ZL={key:2,class:"nb-field__hint"},Sd=ht(Re({__name:"Field",props:{label:{default:void 0},hint:{default:void 0},orientation:{default:"row"},align:{default:"center"},control:{default:"fill"},labelFor:{default:void 0}},setup(e){let t=e,i=qi(),r=Q(()=>t.labelFor??i);return(s,n)=>(g(),E("div",{class:xe(["nb-field",`nb-field--${e.orientation}`,`nb-field--align-${e.align}`,`nb-field--control-${e.control}`])},[s.$slots.label?Pe(s.$slots,"label",{key:0},void 0,!0):e.label?(g(),E("label",{key:1,class:"nb-field__label",for:r.value,title:e.label},Z(e.label),9,VL)):F("",!0),b("div",BL,[Pe(s.$slots,"default",{id:r.value},void 0,!0)]),e.hint||s.$slots.hint?(g(),E("div",ZL,[Pe(s.$slots,"hint",{},()=>[ce(Z(e.hint),1)],!0)])):F("",!0)],2))}}),[["__scopeId","data-v-aae1dce4"]]),Bo=0,q4="";function FL(){typeof document>"u"||(Bo===0&&(q4=document.body.style.overflow,document.body.style.overflow="hidden"),Bo+=1)}function zL(){typeof document>"u"||Bo!==0&&(--Bo,Bo===0&&(document.body.style.overflow=q4))}var UL=['a[href]:not([tabindex="-1"])','area[href]:not([tabindex="-1"])','button:not([disabled]):not([tabindex="-1"])','input:not([disabled]):not([type="hidden"]):not([tabindex="-1"])','select:not([disabled]):not([tabindex="-1"])','textarea:not([disabled]):not([tabindex="-1"])','summary:not([tabindex="-1"])','audio[controls]:not([tabindex="-1"])','video[controls]:not([tabindex="-1"])','iframe:not([tabindex="-1"])','[contenteditable]:not([contenteditable="false"]):not([tabindex="-1"])','[tabindex]:not([tabindex="-1"])'].map(e=>`${e}:not([hidden]):not([aria-hidden="true"])`).join(",");function WL(e){return e?Array.from(e.querySelectorAll(UL)).filter(t=>t.getAttribute("aria-disabled")!=="true"):[]}function jL(){return typeof document>"u"?[]:Array.from(document.querySelectorAll('[aria-modal="true"]'))}function b6(e){if(!e)return!1;let t=jL();return t.length===0||t[t.length-1]===e}function KL(e){let{container:t,active:i,initialFocus:r,floatingSelector:s}=e;function n(y){let p=s==null?void 0:s();return!p||!y?!1:!!y.closest(p)}function a(y){let p=t();return!!p&&!!y&&p.contains(y)}function o(){return WL(t())}function l(){var y;(y=t())==null||y.focus()}function c(){let y=o()[0];y?y.focus():l()}let u=null;function h(){let y=u;u=null,y!=null&&y.isConnected&&y.focus()}function d(){u=document.activeElement instanceof HTMLElement?document.activeElement:null}function f(y){if(y.key!=="Tab"||!i())return;let p=t();if(!p||!b6(p)||n(document.activeElement))return;let C=o(),w=document.activeElement;if(C.length===0){y.preventDefault(),a(w)||l();return}let v=C[0],k=C[C.length-1];y.shiftKey&&(w===v||!a(w))?(y.preventDefault(),k.focus()):!y.shiftKey&&w===k?(y.preventDefault(),v.focus()):a(w)||(y.preventDefault(),v.focus())}function m(y){if(!i())return;let p=y.relatedTarget;if(p instanceof Element){if(a(p)||n(p))return}else if(p!==null)return;requestAnimationFrame(()=>{if(!i())return;let C=document.activeElement;a(C)||n(C)||C&&C!==document.body&&!C.isConnected||b6(t())&&c()})}typeof document<"u"&&(document.addEventListener("keydown",f,!0),document.addEventListener("focusout",m,!0));async function _(){if(await _i(),!i())return;let y=(r==null?void 0:r())??null;y?y.focus():c()}return Fe(i,(y,p)=>{y!==p&&(y?(d(),_()):h())}),ut(()=>{i()&&(d(),_())}),Ii(()=>{typeof document<"u"&&(document.removeEventListener("keydown",f,!0),document.removeEventListener("focusout",m,!0)),h()}),{focusInside:c,restoreFocus:h}}var qL=["[data-nb-confirm-floating]",".nb-select__dropdown",".nb-menu",".nb-date-picker__calendar",".nb-user-menu__panel",".nb-sidebar-menu-item__flyout"],GL=new Set;function G4(e=[]){return[...qL,...GL,...e].map(t=>t.trim()).filter(Boolean).join(",")}function YL(e,t){if(!e)return;let i=`${t?0:200}ms`;e.style.transitionDuration=i;let r=e.parentElement;r instanceof HTMLElement&&(r.style.transitionDuration=i)}var XL=["role","aria-labelledby","aria-describedby","aria-busy"],JL={key:0,class:"nb-modal--header"},QL=["disabled","aria-disabled"],eE=["tabindex","role","aria-labelledby"],tE=ht(Re({__name:"Modal",props:{open:{type:Boolean,default:!1},title:{default:void 0},size:{default:d4.Medium},closeOnOverlay:{type:Boolean,default:!0},role:{default:"dialog"},labelledBy:{default:void 0},describedBy:{default:void 0},busy:{type:Boolean,default:!1},closeDisabled:{type:Boolean,default:!1},closeOnEscape:{type:Boolean,default:!0},trapFocus:{type:Boolean,default:!0},initialFocus:{type:[String,Function],default:void 0},floatingSelectors:{default:void 0}},emits:["close"],setup(e,{expose:t,emit:i}){let r=e,s=i,n=ks(),a=Q(()=>!!n.header||!!r.title),o=`nb-modal-title-${qi()}`,l=X(null),c=X(null),{layerProps:u}=In({overlay:!0});function h(){r.closeOnOverlay&&s("close")}function d(){var H;let D=r.initialFocus;return D?typeof D=="function"?D():((H=l.value)==null?void 0:H.querySelector(D))??null:null}KL({container:()=>l.value,active:()=>r.open&&r.trapFocus,initialFocus:d,floatingSelector:()=>G4(r.floatingSelectors)});let f=!1;function m(){f||(f=!0,FL())}function _(){f&&(f=!1,zL())}let y=X(!1);function p(){let D=c.value;if(!D)return;let H=D.scrollHeight-D.clientHeight;!y.value&&H>4?y.value=!0:y.value&&H<=0&&(y.value=!1)}let C=null,w=null;function v(){let D=c.value;D&&(k(),typeof ResizeObserver<"u"&&(C=new ResizeObserver(()=>p()),C.observe(D)),typeof MutationObserver<"u"&&(w=new MutationObserver(()=>p()),w.observe(D,{childList:!0,subtree:!0,characterData:!0})),p())}function k(){C==null||C.disconnect(),C=null,w==null||w.disconnect(),w=null}Fe(()=>r.open,async D=>{D?m():_(),await _i(),D?v():(k(),y.value=!1)},{immediate:!0}),Ii(()=>{_(),k()});function $(){let D=l.value;if(!D)return!1;let H=Array.from(document.querySelectorAll('[aria-modal="true"]'));return H.length===0||H[H.length-1]===D}function M(D){D.key==="Escape"&&(!r.open||!r.closeOnEscape||r.closeDisabled||$()&&s("close"))}return ut(()=>{document.addEventListener("keydown",M),r.open&&v()}),Ii(()=>{document.removeEventListener("keydown",M)}),t({dialogEl:()=>l.value,bodyEl:()=>c.value}),(D,H)=>(g(),de(br,{to:"body"},[Y(jh,{name:"nb-modal"},{default:ee(()=>[e.open?(g(),E("div",{key:0,class:"nb-modal--overlay",onClick:at(h,["self"])},[b("div",Jt({ref_key:"contentRef",ref:l,class:["nb-modal--content",`nb-modal--content--${e.size}`]},ue(u),{role:e.role,"aria-modal":"true","aria-labelledby":e.labelledBy??(a.value?o:void 0),"aria-describedby":e.describedBy,"aria-busy":e.busy?"true":void 0,tabindex:"-1",onClick:H[1]||(H[1]=at(()=>{},["stop"]))}),[a.value?(g(),E("header",JL,[b("span",{id:o,class:"nb-modal--title"},[Pe(D.$slots,"header",{},()=>[ce(Z(e.title),1)],!0)]),b("button",{class:"nb-modal--close","aria-label":"Close",disabled:e.closeDisabled,"aria-disabled":e.closeDisabled?"true":void 0,onClick:H[0]||(H[0]=R=>s("close"))},[Y(Ge,{name:ue(rl)},null,8,["name"])],8,QL)])):F("",!0),b("main",{ref_key:"bodyRef",ref:c,class:"nb-modal--body",tabindex:y.value?0:void 0,role:y.value?"region":void 0,"aria-labelledby":y.value?e.labelledBy??(a.value?o:void 0):void 0},[Pe(D.$slots,"default",{},void 0,!0)],8,eE),D.$slots.footer?(g(),de(Qi,{key:1,is:"footer",justify:"end",class:"nb-modal--footer",distributed:""},{default:ee(()=>[Pe(D.$slots,"footer",{},void 0,!0)]),_:3})):F("",!0)],16,XL)])):F("",!0)]),_:3})]))}}),[["__scopeId","data-v-bac1817a"]]),iE={key:0,class:"nb-text-input__overlay-wrap"},rE=["innerHTML"],sE=["id","value","placeholder","disabled","readonly","name","maxlength"],nE=["id","value","placeholder","disabled","readonly","name","maxlength"],aE=["id","placeholder","disabled","readonly","name","maxlength","rows"],oE=["id","type","placeholder","disabled","readonly","required","name","min","max","step","maxlength"],lE={key:2,class:"nb-text-input__actions"},cE={key:0,class:"nb-text-input__inner-header"},uE=["for"],hE={key:0,class:"nb-text-input__asterisk","aria-hidden":"true"},dE=["id","type","placeholder","disabled","readonly","required","name","min","max","step","maxlength"],ha=ht(Re({inheritAttrs:!1,__name:"TextInput",props:V_({type:{default:"text"},min:{default:void 0},max:{default:void 0},step:{default:void 0},maxlength:{default:void 0},multiline:{type:Boolean,default:!1},rows:{default:3},highlight:{type:Function,default:void 0},readonly:{type:Boolean,default:!1},placeholder:{default:""},name:{default:""},disabled:{type:Boolean,default:!1},required:{type:Boolean,default:!1},id:{default:void 0},label:{default:""},error:{default:""},warning:{default:""},helper:{default:""},variant:{default:"default"},size:{default:"md"}},{modelValue:{default:""},modelModifiers:{}}),emits:["update:modelValue"],setup(e,{expose:t}){let i=e,r=z_(e,"modelValue"),s=X(null),n=X(null);t({focus:()=>{var y;return(y=s.value)==null?void 0:y.focus()},blur:()=>{var y;return(y=s.value)==null?void 0:y.blur()},nativeEl:s});let a=X(!1),o=`nb-input-${qi()}`,l=Q(()=>i.id??o),c=Q(()=>!!i.highlight),u=Q(()=>{if(!i.highlight)return"";let y=String(r.value??"");return i.highlight(y)+`
|
|
42
|
-
`});function h(){n.value&&s.value&&(n.value.scrollTop=s.value.scrollTop)}Fe(u,()=>_i(h));let d=Q(()=>i.error?"error":i.warning?"warning":"helper"),f=Q(()=>i.error||i.warning||i.helper||""),m=Q(()=>!!f.value),_=Q(()=>({"nb-text-input__field-wrapper--focused":a.value,"nb-text-input__field-wrapper--error":!!i.error,"nb-text-input__field-wrapper--warning":!i.error&&!!i.warning,"nb-text-input__field-wrapper--disabled":i.disabled,"nb-text-input__field-wrapper--readonly":i.readonly,"nb-text-input__field-wrapper--overlay":c.value,"nb-text-input__field-wrapper--multiline":i.multiline}));return(y,p)=>(g(),de(Qi,{dir:"col",class:xe(["nb-text-input",`nb-text-input--${e.variant}`,`nb-text-input--${e.size}`,{"nb-text-input--multiline":e.multiline}])},{default:ee(()=>[e.variant==="default"?(g(),E(we,{key:0},[y.$slots.label?Pe(y.$slots,"label",{key:0},void 0,!0):e.label?(g(),de(sa,{key:1,for:l.value,required:e.required,disabled:e.disabled},{default:ee(()=>[ce(Z(e.label),1)]),_:1},8,["for","required","disabled"])):F("",!0),b("div",{class:xe(["nb-text-input__field-wrapper",_.value])},[Pe(y.$slots,"leading",{},void 0,!0),c.value?(g(),E("div",iE,[b("div",{ref_key:"mirrorRef",ref:n,class:"nb-text-input__mirror","aria-hidden":"true",innerHTML:u.value},null,8,rE),e.multiline?(g(),E("textarea",Jt({key:0,id:l.value,ref_key:"nativeRef",ref:s},y.$attrs,{class:"nb-text-input__field--transparent",value:r.value,placeholder:e.placeholder,disabled:e.disabled,readonly:e.readonly,name:e.name,maxlength:e.maxlength,spellcheck:"false",autocomplete:"off",autocorrect:"off",onInput:p[0]||(p[0]=C=>r.value=C.target.value),onFocus:p[1]||(p[1]=C=>a.value=!0),onBlur:p[2]||(p[2]=C=>a.value=!1),onScroll:h}),null,16,sE)):(g(),E("input",Jt({key:1,id:l.value,ref_key:"nativeRef",ref:s},y.$attrs,{type:"text",class:"nb-text-input__field--transparent",value:r.value,placeholder:e.placeholder,disabled:e.disabled,readonly:e.readonly,name:e.name,maxlength:e.maxlength,spellcheck:"false",onInput:p[3]||(p[3]=C=>r.value=C.target.value),onFocus:p[4]||(p[4]=C=>a.value=!0),onBlur:p[5]||(p[5]=C=>a.value=!1)}),null,16,nE))])):(g(),E(we,{key:1},[e.multiline?Xs((g(),E("textarea",Jt({key:0,id:l.value,ref_key:"nativeRef",ref:s},y.$attrs,{"onUpdate:modelValue":p[6]||(p[6]=C=>r.value=C),class:"nb-text-input__field",placeholder:e.placeholder,disabled:e.disabled,readonly:e.readonly,name:e.name,maxlength:e.maxlength,rows:e.rows,onFocus:p[7]||(p[7]=C=>a.value=!0),onBlur:p[8]||(p[8]=C=>a.value=!1)}),null,16,aE)),[[L0,r.value]]):Xs((g(),E("input",Jt({key:1,id:l.value,ref_key:"nativeRef",ref:s},y.$attrs,{"onUpdate:modelValue":p[9]||(p[9]=C=>r.value=C),class:"nb-text-input__field",type:e.type,placeholder:e.placeholder,disabled:e.disabled,readonly:e.readonly,required:e.required,name:e.name,min:e.min,max:e.max,step:e.step,maxlength:e.maxlength,onFocus:p[10]||(p[10]=C=>a.value=!0),onBlur:p[11]||(p[11]=C=>a.value=!1)}),null,16,oE)),[[H2,r.value]])],64)),Pe(y.$slots,"trailing",{},void 0,!0),y.$slots.actions?(g(),E("div",lE,[Pe(y.$slots,"actions",{},void 0,!0)])):F("",!0)],2),m.value?(g(),de(Qe,{key:2,variant:d.value,class:"nb-text-input__message"},{default:ee(()=>[ce(Z(f.value),1)]),_:1},8,["variant"])):F("",!0),Pe(y.$slots,"dropdown",{},void 0,!0)],64)):e.variant==="fluid"?(g(),E("div",{key:1,class:xe(["nb-text-input__field-wrapper",_.value])},[e.label||y.$slots.label?(g(),E("div",cE,[y.$slots.label?Pe(y.$slots,"label",{key:0},void 0,!0):(g(),E("label",{key:1,for:l.value,class:xe(["nb-text-input__inner-label",{"nb-text-input__inner-label--required":e.required}])},[ce(Z(e.label)+" ",1),e.required?(g(),E("span",hE,"*")):F("",!0)],10,uE)),m.value?(g(),de(Qe,{key:2,variant:d.value,"icon-only":"",class:"nb-text-input__inner-message"},{default:ee(()=>[ce(Z(f.value),1)]),_:1},8,["variant"])):F("",!0)])):F("",!0),Xs(b("input",Jt({id:l.value,ref_key:"nativeRef",ref:s},y.$attrs,{"onUpdate:modelValue":p[12]||(p[12]=C=>r.value=C),class:"nb-text-input__field",type:e.type,placeholder:e.placeholder,disabled:e.disabled,readonly:e.readonly,required:e.required,name:e.name,min:e.min,max:e.max,step:e.step,maxlength:e.maxlength,onFocus:p[13]||(p[13]=C=>a.value=!0),onBlur:p[14]||(p[14]=C=>a.value=!1)}),null,16,dE),[[H2,r.value]])],2)):F("",!0)]),_:3},8,["class"]))}}),[["__scopeId","data-v-ee23eb9e"]]),fE={key:0,class:"nb-confirm__message"},pE={key:0,class:"nb-confirm__subject-kind"},_E={class:"nb-confirm__subject-name"},mE={key:1,class:"nb-confirm__gate"},gE={class:"nb-confirm__live"},vE={key:0,class:"nb-confirm__status",role:"status"},bE={key:1,class:"nb-confirm__status nb-confirm__status--success",role:"status"},yE=ht(Re({__name:"Confirm",props:{open:{type:Boolean,default:!1},title:{},message:{default:void 0},subject:{default:void 0},subjectLabel:{default:void 0},confirmLabel:{default:"Confirm"},cancelLabel:{default:"Cancel"},tone:{default:"danger"},typeToConfirm:{default:void 0},typeToConfirmLabel:{default:void 0},typeToConfirmHelper:{default:void 0},busy:{type:Boolean,default:!1},busyLabel:{default:"Working..."},succeeded:{type:Boolean,default:!1},successLabel:{default:void 0},error:{default:void 0},size:{default:"sm"},floatingSelectors:{default:()=>[]},contentClass:{default:void 0}},emits:["confirm","cancel"],setup(e,{expose:t,emit:i}){let r=e,s=i,n=qi(),a=`nb-confirm-title-${n}`,o=`nb-confirm-body-${n}`,l=ks(),c=X(null),u=X(null),h=X(null),d=X(""),f=P7(),m=Q(()=>r.busy||r.succeeded);function _(){return!!r.message||!!r.subject||!!l.default}let y=Q(()=>r.tone==="danger"?"danger":"primary"),p=Q(()=>r.typeToConfirmLabel??`Type ${r.typeToConfirm} to confirm`),C=Q(()=>!r.typeToConfirm||d.value.trim()===r.typeToConfirm),w=Q(()=>C.value&&!m.value);function v(){w.value&&s("confirm")}function k(){var ie;let O=(ie=h.value)==null?void 0:ie.$el;return O instanceof HTMLElement?O:null}function $(){var O;return((O=c.value)==null?void 0:O.closest('[role="dialog"],[role="alertdialog"]'))??null}function M(){return typeof document>"u"?[]:Array.from(document.querySelectorAll('[aria-modal="true"]'))}function D(){let O=$();if(!O)return!1;let ie=M();return ie.length===0||ie[ie.length-1]===O}let H=['a[href]:not([tabindex="-1"])','area[href]:not([tabindex="-1"])','button:not([disabled]):not([tabindex="-1"])','input:not([disabled]):not([type="hidden"]):not([tabindex="-1"])','select:not([disabled]):not([tabindex="-1"])','textarea:not([disabled]):not([tabindex="-1"])','summary:not([tabindex="-1"])','audio[controls]:not([tabindex="-1"])','video[controls]:not([tabindex="-1"])','iframe:not([tabindex="-1"])','[contenteditable]:not([contenteditable="false"]):not([tabindex="-1"])','[tabindex]:not([tabindex="-1"])'].map(O=>`${O}:not([hidden]):not([aria-hidden="true"])`).join(",");function R(){return G4(r.floatingSelectors)}function V(O){return O instanceof Element?!!O.closest(R()):!1}function N(O){let ie=$();return!!ie&&!!O&&ie.contains(O)}function P(){let O=$();return O?Array.from(O.querySelectorAll(H)).filter(ie=>ie.getAttribute("aria-disabled")!=="true"):[]}function U(){let O=$();return O?(O.focus(),!0):!1}function j(){let O=P()[0];O?O.focus():U()}let oe=null;function te(){let O=oe;oe=null,O!=null&&O.isConnected&&O.focus()}function ne(){YL($(),f.value)}Fe(f,()=>{r.open&&ne()}),Fe(()=>[r.busy,r.error],async(O,ie)=>{if(!r.open)return;let[le,ge]=O,Se=(ie==null?void 0:ie[0])??!1;if(await _i(),le){P().length===0&&U();return}if(Se&&ge){let T=u.value;T?T.focus():j();return}let x=document.activeElement;!N(x)&&!V(x)&&j()}),Fe(()=>r.open,async O=>{var ie;O?(oe=document.activeElement instanceof HTMLElement?document.activeElement:null,d.value="",await _i(),ne(),k()?(ie=k())==null||ie.focus():U()):te()},{immediate:!0});function J(){m.value||s("cancel")}let fe=!1,re=!1;function _e(O){let ie=O.target;fe=N(ie)||V(ie)}function Ne(O){re=N(O.target)}function $e(){let O=fe&&!re;fe=!1,!O&&J()}function be(O){if(!r.open||V(document.activeElement))return;if(O.key==="Escape"){if(!D())return;O.preventDefault(),O.stopPropagation(),O.stopImmediatePropagation(),J();return}if(O.key!=="Tab"||!D())return;let ie=P();if(ie.length===0){O.preventDefault(),N(document.activeElement)||U();return}let le=ie[0],ge=ie[ie.length-1],Se=document.activeElement;O.shiftKey&&(Se===le||!N(Se))?(O.preventDefault(),ge.focus()):!O.shiftKey&&Se===ge?(O.preventDefault(),le.focus()):N(Se)||(O.preventDefault(),le.focus())}function me(O){if(!r.open)return;let ie=O.relatedTarget;if(ie instanceof Element){if(N(ie)||V(ie))return}else if(ie!==null)return;requestAnimationFrame(()=>{if(!r.open)return;let le=document.activeElement;N(le)||V(le)||le&&le!==document.body&&!le.isConnected||D()&&j()})}return typeof document<"u"&&(document.addEventListener("keydown",be,!0),document.addEventListener("focusout",me,!0),document.addEventListener("mousedown",_e,!0),document.addEventListener("touchstart",_e,!0),document.addEventListener("click",Ne,!0)),ut(()=>{var O;r.open&&(ne(),k()?(O=k())==null||O.focus():U())}),Ii(()=>{typeof document<"u"&&(document.removeEventListener("keydown",be,!0),document.removeEventListener("focusout",me,!0),document.removeEventListener("mousedown",_e,!0),document.removeEventListener("touchstart",_e,!0),document.removeEventListener("click",Ne,!0)),te()}),t({focusCancel:()=>{var O;return(O=k())==null?void 0:O.focus()},restoreFocus:te,isTopmost:D}),(O,ie)=>(g(),de(tE,{open:e.open,size:e.size,role:e.tone==="danger"?"alertdialog":"dialog","labelled-by":a,"described-by":_()?o:void 0,busy:e.busy,"close-on-overlay":!m.value,"close-disabled":m.value,"close-on-escape":!1,"trap-focus":!1,onClose:$e},{header:ee(()=>[b("span",{id:a,class:xe(["nb-confirm__heading",`nb-confirm__heading--${e.tone}`])},[e.tone==="danger"?(g(),de(Ge,{key:0,name:ue(mr),size:16,"aria-hidden":"true"},null,8,["name"])):F("",!0),b("span",null,Z(e.title),1)],2)]),footer:ee(()=>[Y(oi,{ref_key:"cancelRef",ref:h,class:"nb-confirm__action nb-confirm__action--cancel",variant:"ghost",size:"lg",disabled:m.value,"data-nb-confirm":"cancel",onClick:J},{default:ee(()=>[ce(Z(e.cancelLabel),1)]),_:1},8,["disabled"]),Y(oi,{class:"nb-confirm__action nb-confirm__action--confirm",variant:y.value,size:"lg",disabled:!w.value,loading:e.busy,"data-nb-confirm":"confirm",onClick:v},{default:ee(()=>[ce(Z(e.confirmLabel),1)]),_:1},8,["variant","disabled","loading"])]),default:ee(()=>[b("div",{ref_key:"rootRef",ref:c,class:xe(["nb-confirm",e.contentClass])},[_()?(g(),E("div",{key:0,id:o,class:"nb-confirm__body"},[Pe(O.$slots,"default",{},()=>[e.message?(g(),E("p",fE,Z(e.message),1)):F("",!0)],!0),e.subject?(g(),E("p",{key:0,class:xe(["nb-confirm__subject",`nb-confirm__subject--${e.tone}`])},[e.subjectLabel?(g(),E("span",pE,Z(e.subjectLabel),1)):F("",!0),b("span",_E,Z(e.subject),1)],2)):F("",!0)])):F("",!0),e.typeToConfirm?(g(),E("div",mE,[Y(ha,{modelValue:d.value,"onUpdate:modelValue":ie[0]||(ie[0]=le=>d.value=le),class:"nb-confirm__gate-field",label:p.value,helper:e.typeToConfirmHelper,disabled:m.value,autocomplete:"off",spellcheck:"false","data-nb-confirm":"gate",onKeydown:ie[1]||(ie[1]=Br(at(()=>{},["prevent"]),["enter"]))},null,8,["modelValue","label","helper","disabled"])])):F("",!0),b("div",gE,[e.busy?(g(),E("p",vE,Z(e.busyLabel),1)):F("",!0),e.succeeded&&e.successLabel?(g(),E("p",bE,[Y(Ge,{name:ue(V0),size:14,"aria-hidden":"true"},null,8,["name"]),b("span",null,Z(e.successLabel),1)])):F("",!0),e.error?(g(),E("div",{key:2,ref_key:"errorRef",ref:u,class:"nb-confirm__error",tabindex:"-1"},[Y(Qe,{variant:"error"},{default:ee(()=>[ce(Z(e.error),1)]),_:1})],512)):F("",!0)])],2)]),_:3},8,["open","size","role","described-by","busy","close-on-overlay","close-disabled"]))}}),[["__scopeId","data-v-683eafb1"]]),Sl=ht(Re({__name:"Panel",props:{layer:{default:void 0}},setup(e){let t=e,{layerProps:i}=In({level:()=>t.layer});return(r,s)=>(g(),E("div",Jt({class:"nb-panel"},ue(i)),[Pe(r.$slots,"default",{},void 0,!0)],16))}}),[["__scopeId","data-v-a0d6ea95"]]),wE=Symbol("nb-shell-slots"),SE=0;function CE(){let e=X([]),t=new Map,i=new Map;function r(n){let a=t.get(n);return a||(a=Ar(null),t.set(n,a)),a}function s(n){let a=i.get(n);return a||(a=Q(()=>{let o=e.value.filter(l=>l.name===n&&!l.deactivated);if(o.length===0)return[];if(o.some(l=>l.claim==="last")){let l=o[0];for(let c of o)c.seq>l.seq&&(l=c);return[l.id]}return[...o].sort((l,c)=>l.order-c.order||l.seq-c.seq).map(l=>l.id)}),i.set(n,a)),a}return{registry:{register(n){e.value=[...e.value,n]},unregister(n){let a=e.value.filter(o=>o.id!==n);a.length!==e.value.length&&(e.value=a)},elementFor:r,activeIds:s,setActive(n,a){let o=e.value.find(l=>l.id===n);!o||o.deactivated===!a||(o.deactivated=!a,a&&(o.seq=SE++))}},count:n=>e.value.filter(a=>a.name===n&&!a.deactivated).length,sharedCount:n=>e.value.filter(a=>a.name===n&&!a.deactivated&&a.claim==="all").length,setElement:(n,a)=>{r(n).value=a}}}function Y4(e){return e.some(t=>t.type===Xt?!1:t.type===As?typeof t.children=="string"&&t.children.trim().length>0:t.type===we?Array.isArray(t.children)?Y4(t.children):!1:!0)}function X4(e,t){var r;let i=(r=e[t])==null?void 0:r.call(e);return i?Y4(i):!1}var kE=Re({__name:"SurfaceLayerScope",props:{level:{}},setup(e){let t=e;return ps(mu,Q(()=>N0(t.level))),(i,r)=>Pe(i.$slots,"default")}}),AE=["href"],ME={class:"nb-shell__middle"},LE=["id","aria-label","tabindex","inert","aria-hidden"],EE={class:"nb-shell__sidebar-logo"},$E={class:"nb-shell__sidebar-nav"},xE={class:"nb-shell__sidebar-bottom"},TE={class:"nb-shell__right"},NE={key:2,class:"nb-shell__menubar"},HE={key:3,class:"nb-shell__topbar"},PE=["aria-label","aria-expanded","aria-controls"],OE={class:"nb-shell__content-row"},IE=["inert","aria-hidden"],RE=["aria-expanded"],DE={class:"nb-shell__contextbar-toggle-glyph","aria-hidden":"true"},VE={class:"nb-shell__main-row"},BE=["aria-label"],ZE=["id"],FE=["aria-label","inert","aria-hidden"],zE=["aria-label"],UE=["aria-label","aria-valuenow","aria-valuemax"],_o=288,WE=16,jE=64,KE=ht(Re({__name:"Shell",props:{inspectorVisible:{type:Boolean,default:!1},inspectorExpanded:{type:Boolean,default:!1},inspectorSize:{default:"md"},resizable:{type:Boolean,default:!1},inspectorWidth:{},mainPadding:{type:Boolean,default:!0},sidebarVariant:{default:"compact"},topbar:{default:"auto"},skipToContent:{type:Boolean,default:!0},skipToContentLabel:{default:"Skip to content"},mainId:{},sidebarLabel:{default:"Primary"},inspectorLabel:{default:"Inspector"},contextbarLabel:{default:"Browse"},collapseAt:{default:"md"},sidebarOpen:{type:Boolean},navToggleLabel:{default:"Navigation"},inspectorCloseLabel:{default:"Close inspector"}},emits:["update:inspectorWidth","update:sidebarOpen","update:inspectorVisible"],setup(e,{expose:t,emit:i}){var Tl;let r=ks();function s(G){return X4(r,G)}let{registry:n,count:a,sharedCount:o,setElement:l}=CE();ps(wE,n);let c=new Map;function u(G){let q=c.get(G);return q||(q=Ce=>l(G,Ce??null),c.set(G,q)),q}function h(G){return s(G)||a(G)>0}function d(G){return o(G)>0?"nb-shell__region--ordered":null}let f=Q(()=>{for(let G of["sidebar-logo","sidebar-nav","sidebar-bottom"])if(s(G))return!0;return!1}),m=e,_=X(!1),y=i,p={md:672,lg:1056},C=X(typeof window<"u"?window.innerWidth:1/0);function w(G){let q=p[m.collapseAt];return q!=null&&G<q}let v=0;function k(){let G=window.innerWidth;w(G)!==w(C.value)&&(C.value=G)}function $(){v||(v=window.requestAnimationFrame(()=>{v=0,C.value=window.innerWidth}))}function M(){typeof window>"u"||(window.removeEventListener("resize",$),v&&(v=(window.cancelAnimationFrame(v),0)))}function D(){typeof window>"u"||(C.value=window.innerWidth,window.addEventListener("resize",$,{passive:!0}))}let H=Q(()=>w(C.value)),R=((Tl=ki())==null?void 0:Tl.vnode.props)??{};function V(G,q){return G in R||q in R}function N(G,q){if(G in R)return R[G];if(q in R)return R[q]}function P(G,q){return V(G,q)&&N(G,q)!==void 0}let U=P("sidebarOpen","sidebar-open"),j=X(!1);V("sidebarOpen","sidebar-open")&&!U&&Fe(()=>m.sidebarOpen,G=>{j.value=G===!0});let oe=Q(()=>U?m.sidebarOpen===!0:j.value),te=qi(),ne=Q(()=>`nb-shell-sidebar-${te}`),J=X(null),fe=X(null),re=Q(()=>f.value&&H.value),_e=Q(()=>f.value&&H.value&&!oe.value);function Ne(G){U||(j.value=G),y("update:sidebarOpen",G)}function $e(){if(f.value&&H.value&&oe.value){Ne(!1);return}le.value&&ge(!1)}Fe(oe,async G=>{var q,Ce,We,Ze,ti;H.value&&(await _i(),G?(We=(Ce=((q=fe.value)==null?void 0:q.querySelector('a[href], button:not([disabled]), [tabindex]:not([tabindex="-1"])'))??fe.value)==null?void 0:Ce.focus)==null||We.call(Ce):(ti=(Ze=J.value)==null?void 0:Ze.focus)==null||ti.call(Ze))}),Fe(H,G=>{!G&&oe.value&&Ne(!1)});let be=P("inspectorVisible","inspector-visible"),me=X(m.inspectorVisible===!0);V("inspectorVisible","inspector-visible")&&!be&&Fe(()=>m.inspectorVisible,G=>{me.value=G===!0});let O=X(!1),ie=Q(()=>(be?m.inspectorVisible===!0:me.value)?!(H.value&&O.value):!1),le=Q(()=>H.value&&ie.value);function ge(G){be?O.value=!G:(me.value=G,O.value=!1),y("update:inspectorVisible",G)}Fe(()=>m.inspectorVisible,G=>{G&&(O.value=!1)}),Fe(H,G=>{G||(O.value=!1)});let Se=X(null),x=X(null);Fe(le,async G=>{var q,Ce,We;if(G)x.value=document.activeElement??null,await _i(),(Ce=(q=Se.value)==null?void 0:q.focus)==null||Ce.call(q);else{let Ze=x.value;x.value=null,Ze!=null&&Ze.isConnected&&(await _i(),(We=Ze.focus)==null||We.call(Ze))}});let T=Q(()=>le.value),K=X(null),se=qi(),he=Q(()=>m.mainId||`nb-shell-main-${se}`);function pe(){var G;(G=K.value)==null||G.focus()}let S=Q(()=>re.value||m.topbar==="always"?!0:m.topbar==="never"?!1:s("topbar-left")||s("topbar-right")||a("topbar-left")>0||a("topbar-right")>0),{layerProps:A}=In(),{layerProps:B}=In({level:0,probe:!1,provideContext:!1});ps("nb-shell-sidebar-variant",N5(m,"sidebarVariant"));let L=X(null),I=X(!1);ut(()=>l("inspector",L.value)),Fe(L,G=>l("inspector",G));let z={lg:.5,xl:.75},W={xs:288,sm:360,md:560},ae=Q(()=>Number.isFinite(C.value)?C.value:1280),ye=Q(()=>Math.max(_o,ae.value*.5));function ke(G){return Math.round(Math.max(_o,Math.min(G,ye.value)))}let Oe=P("inspectorWidth","inspector-width"),je=X(null),Ee=Q(()=>Oe?m.inspectorWidth??null:je.value);function lt(G){Oe||(je.value=G),y("update:inspectorWidth",G)}let Ot=Q(()=>{let G=Ee.value;if(!(!m.resizable||!ie.value||G==null))return{"--nb-shell-inspector-width":`${ke(G)}px`}}),$i=Q(()=>{let G=Ee.value;if(G!=null)return ke(G);if(m.inspectorExpanded)return Math.round(ae.value*.5);let q=z[m.inspectorSize],Ce=q==null?W[m.inspectorSize]??_o:ae.value*q;return Math.round(m.inspectorSize==="xl"?Ce:Math.min(Ce,ye.value))}),Er=Q(()=>Math.round(Math.max(ye.value,$i.value))),Mt=Q(()=>$i.value);function li(){return $i.value}function es(G){let q=L.value;if(!q)return;let Ce=q.getBoundingClientRect().right;lt(ke(Ce-G.clientX))}function Yi(){I.value=!1,window.removeEventListener("pointermove",es),window.removeEventListener("pointerup",Yi),window.removeEventListener("pointercancel",Yi)}function Dc(G){m.resizable&&(G.preventDefault(),I.value=!0,window.addEventListener("pointermove",es),window.addEventListener("pointerup",Yi),window.addEventListener("pointercancel",Yi))}function Vc(){lt(null)}function Bc(G){if(!m.resizable)return;let q=G.shiftKey?jE:WE,Ce;switch(G.key){case"ArrowLeft":Ce=li()+q;break;case"ArrowRight":Ce=li()-q;break;case"Home":Ce=_o;break;case"End":Ce=ye.value;break;case"Enter":case" ":Ce=null;break;default:return}G.preventDefault(),lt(Ce==null?null:ke(Ce))}return ut(()=>{typeof window>"u"||(C.value=window.innerWidth,window.addEventListener("resize",k,{passive:!0}),m.resizable&&D())}),Fe(()=>m.collapseAt,()=>{typeof window<"u"&&(C.value=window.innerWidth)}),Fe(()=>m.resizable,G=>G?D():M()),Gi(()=>{Yi(),M(),typeof window<"u"&&window.removeEventListener("resize",k)}),t({mainEl:K,sidebarEl:fe,inspectorEl:L,focusMain:()=>{var G;return(G=K.value)==null?void 0:G.focus()},setSidebarOpen:Ne,setInspectorVisible:ge}),(G,q)=>(g(),E("div",Jt({class:"nb-shell"},ue(A),{class:[{"nb-shell--no-sidebar":!f.value},f.value?`nb-shell--sidebar-${e.sidebarVariant}`:null,{"nb-shell--collapsed":H.value,"nb-shell--drawer-open":H.value&&oe.value}],onKeydown:Br($e,["esc"])}),[e.skipToContent?(g(),E("a",{key:0,class:"nb-shell__skip-link",href:`#${he.value}`,onClick:pe},Z(e.skipToContentLabel),9,AE)):F("",!0),h("outer-menu")?(g(),E("div",{key:1,ref:u("outer-menu"),class:xe(["nb-shell__outer-menu",d("outer-menu")])},[Pe(G.$slots,"outer-menu",{},void 0,!0)],2)):F("",!0),b("div",ME,[f.value?(g(),E("nav",{key:0,id:ne.value,ref_key:"sidebarRef",ref:fe,class:"nb-shell__sidebar","aria-label":e.sidebarLabel,tabindex:H.value?-1:void 0,inert:_e.value||void 0,"aria-hidden":_e.value||void 0},[b("div",EE,[Pe(G.$slots,"sidebar-logo",{},void 0,!0)]),b("div",$E,[Pe(G.$slots,"sidebar-nav",{},void 0,!0)]),q[4]||(q[4]=b("div",{class:"nb-shell__sidebar-spacer"},null,-1)),b("div",xE,[Pe(G.$slots,"sidebar-bottom",{},void 0,!0)])],8,LE)):F("",!0),f.value&&H.value&&oe.value?(g(),E("div",{key:1,class:"nb-shell__scrim",onClick:q[0]||(q[0]=Ce=>Ne(!1))})):F("",!0),b("div",TE,[h("inner-menu")?(g(),E("div",{key:0,ref:u("inner-menu"),class:xe(["nb-shell__inner-menu",d("inner-menu")])},[Pe(G.$slots,"inner-menu",{},void 0,!0)],2)):F("",!0),h("notification")?(g(),E("div",{key:1,ref:u("notification"),class:xe(["nb-shell__notification",d("notification")])},[Pe(G.$slots,"notification",{},void 0,!0)],2)):F("",!0),s("menubar")?(g(),E("div",NE,[Pe(G.$slots,"menubar",{},void 0,!0)])):F("",!0),S.value?(g(),E("div",HE,[re.value?(g(),E("button",{key:0,ref_key:"navToggleRef",ref:J,type:"button",class:"nb-shell__nav-toggle","aria-label":e.navToggleLabel,"aria-expanded":oe.value,"aria-controls":ne.value,onClick:q[1]||(q[1]=Ce=>Ne(!oe.value))},[...q[5]||(q[5]=[b("span",{class:"nb-shell__nav-toggle-glyph","aria-hidden":"true"},[b("span"),b("span"),b("span")],-1)])],8,PE)):F("",!0),b("div",{ref:u("topbar-left"),class:"nb-shell__topbar-left"},[Pe(G.$slots,"topbar-left",{},void 0,!0)],512),b("div",{ref:u("topbar-right"),class:"nb-shell__topbar-right"},[Pe(G.$slots,"topbar-right",{},void 0,!0)],512)])):F("",!0),b("div",OE,[b("div",{class:"nb-shell__body",inert:T.value||void 0,"aria-hidden":T.value||void 0},[h("fixedbar")?(g(),E("div",{key:0,ref:u("fixedbar"),class:"nb-shell__fixedbar"},[Pe(G.$slots,"fixedbar",{},void 0,!0)],512)):F("",!0),H.value&&h("contextbar")?(g(),E("button",{key:1,type:"button",class:"nb-shell__contextbar-toggle","aria-expanded":_.value,onClick:q[2]||(q[2]=Ce=>_.value=!_.value)},[b("span",null,Z(e.contextbarLabel),1),b("span",DE,Z(_.value?"▾":"▸"),1)],8,RE)):F("",!0),b("div",VE,[h("contextbar")?Xs((g(),E("aside",{key:0,ref:u("contextbar"),class:xe(["nb-shell__contextbar",d("contextbar")]),"aria-label":e.contextbarLabel},[Pe(G.$slots,"contextbar",{},void 0,!0)],10,BE)),[[dm,!H.value||_.value]]):F("",!0),b("main",Jt({id:he.value,ref_key:"mainRef",ref:K,tabindex:"-1",class:["nb-shell__main",{"nb-shell__main--no-padding":!e.mainPadding}]},ue(B)),[Y(kE,{level:1},{default:ee(()=>[Pe(G.$slots,"default",{},void 0,!0)]),_:3})],16,ZE)]),h("bottom")?(g(),E("div",{key:2,ref:u("bottom"),class:"nb-shell__bottom"},[Pe(G.$slots,"bottom",{},void 0,!0)],512)):F("",!0)],8,IE),b("aside",{ref_key:"inspectorRef",ref:L,class:xe(["nb-shell__inspector",{"nb-shell__inspector--visible":ie.value,"nb-shell__inspector--expanded":ie.value&&e.inspectorExpanded,[`nb-shell__inspector--${e.inspectorSize}`]:ie.value,"nb-shell__inspector--resizing":I.value,"nb-shell__inspector--overlay":le.value}]),"aria-label":e.inspectorLabel,inert:!ie.value||void 0,"aria-hidden":!ie.value||void 0,style:Ci(Ot.value)},[le.value?(g(),E("button",{key:0,ref_key:"inspectorDismissRef",ref:Se,type:"button",class:"nb-shell__inspector-dismiss","aria-label":e.inspectorCloseLabel,onClick:q[3]||(q[3]=Ce=>ge(!1))},[...q[6]||(q[6]=[b("span",{class:"nb-shell__inspector-dismiss-glyph","aria-hidden":"true"},"×",-1)])],8,zE)):F("",!0),e.resizable&&ie.value&&!H.value?(g(),E("div",{key:1,class:"nb-shell__inspector-resize",role:"separator",tabindex:"0","aria-orientation":"vertical","aria-label":`Resize ${e.inspectorLabel}`,"aria-valuenow":Mt.value,"aria-valuemin":_o,"aria-valuemax":Er.value,title:"Drag or use the arrow keys to resize, Enter or double-click to reset",onPointerdown:Dc,onDblclick:Vc,onKeydown:Bc},null,40,UE)):F("",!0),Pe(G.$slots,"inspector",{},void 0,!0)],14,FE)])])])],16))}}),[["__scopeId","data-v-77259f9a"]]),qE=ht(Re({__name:"SidebarLink",props:{to:{default:void 0},href:{default:void 0},tooltip:{default:void 0},active:{type:Boolean,default:!1},disabled:{type:Boolean,default:!1},danger:{type:Boolean,default:!1}},emits:["click"],setup(e){let t=e,i=C4(),r=Q(()=>t.to!=null&&!!i.value),s=Q(()=>{if(typeof t.to=="string")return t.to;if(t.href)return t.href}),n=Q(()=>r.value?i.value:s.value?"a":"button"),a=Q(()=>n.value==="a"?{href:s.value}:{});return(o,l)=>(g(),de(uc(n.value),Jt({class:["nb-sidebar-link",{"nb-sidebar-link--active":e.active,"nb-sidebar-link--danger":e.danger,"nb-sidebar-link--disabled":e.disabled}],to:r.value?e.to:void 0},a.value,{disabled:n.value==="button"&&e.disabled||void 0,"aria-disabled":n.value!=="button"&&e.disabled?!0:void 0,"data-tooltip":e.tooltip||void 0,onClick:l[0]||(l[0]=c=>e.disabled?void 0:o.$emit("click",c))}),{default:ee(()=>[Pe(o.$slots,"default",{},void 0,!0)]),_:3},16,["class","to","disabled","aria-disabled","data-tooltip"]))}}),[["__scopeId","data-v-24809884"]]),J4=function(e){return e.Small="sm",e.Medium="md",e}(J4||{}),Zs=function(e){return e.Active="active",e.Finished="finished",e.Error="error",e}(Zs||{}),GE={key:0,class:"nb-progress-bar__header"},YE=["aria-label","aria-valuemax","aria-valuenow"],Q4=ht(Re({__name:"ProgressBar",props:{value:{default:void 0},max:{default:100},helper:{default:void 0},size:{default:J4.Medium},status:{default:Zs.Active},id:{default:"progress-bar"},label:{}},setup(e){let t=e,i=Q(()=>t.value==null&&t.status===Zs.Active),r=Q(()=>t.status===Zs.Active?t.value==null||t.max<=0?0:Math.min(Math.max(t.value/t.max,0),1):1),s=Q(()=>i.value?void 0:r.value*t.max),n=Q(()=>["nb-progress-bar",`nb-progress-bar--${t.size}`,`nb-progress-bar--${t.status}`,{"nb-progress-bar--indeterminate":i.value}]),a=Q(()=>({transform:`scaleX(${r.value})`})),o=Q(()=>t.status===Zs.Finished?ud:t.status===Zs.Error?_4:null),l=Q(()=>t.status===Zs.Error?I0.Error:I0.Helper);return(c,u)=>(g(),E("div",{class:xe(n.value)},[e.label?(g(),E("div",GE,[Y(sa,null,{default:ee(()=>[ce(Z(e.label),1)]),_:1}),o.value?(g(),de(Ge,{key:0,name:o.value,size:14,class:"nb-progress-bar__status-icon"},null,8,["name"])):F("",!0)])):F("",!0),b("div",{class:"nb-progress-bar__track",role:"progressbar","aria-label":e.label,"aria-valuemin":"0","aria-valuemax":e.max,"aria-valuenow":s.value},[b("div",{class:"nb-progress-bar__bar",style:Ci(a.value)},null,4)],8,YE),e.helper?(g(),de(Qe,{key:1,variant:l.value,class:"nb-progress-bar__message"},{default:ee(()=>[ce(Z(e.helper),1)]),_:1},8,["variant"])):F("",!0)],2))}}),[["__scopeId","data-v-5c8dd315"]]),eg=function(e){return e.Horizontal="horizontal",e.Vertical="vertical",e}(eg||{}),XE={class:"nb-radio__control"},JE=["name","value","checked","disabled","readonly","onChange"],QE={class:"nb-radio__circle"},e$={key:0,class:"nb-radio__dot"},t$={class:"nb-radio__text"},i$=ht(Re({__name:"Radio",props:{modelValue:{},options:{},name:{},direction:{default:eg.Vertical},readonly:{type:Boolean,default:!1},disabled:{type:Boolean,default:!1},required:{type:Boolean},id:{default:"radio"},label:{},error:{default:void 0},warning:{default:void 0},helper:{default:void 0}},emits:["update:modelValue"],setup(e){let t=e,i=Q(()=>["nb-radio",{"nb-radio--error":!!t.error,"nb-radio--warning":!t.error&&!!t.warning,"nb-radio--disabled":t.disabled,"nb-radio--readonly":t.readonly}]);function r(s){return["nb-radio__option",{"nb-radio__option--disabled":t.disabled||s.disabled,"nb-radio__option--readonly":t.readonly}]}return(s,n)=>(g(),E("div",{class:xe(i.value)},[e.label?(g(),de(sa,{key:0},{default:ee(()=>[ce(Z(e.label),1)]),_:1})):F("",!0),b("div",{class:xe(["nb-radio__group",`nb-radio__group--${e.direction}`])},[(g(!0),E(we,null,Be(e.options,a=>(g(),E("label",{key:a.value,class:xe(r(a))},[b("span",XE,[b("input",{type:"radio",name:e.name,value:a.value,checked:e.modelValue===a.value,disabled:e.disabled||a.disabled,readonly:e.readonly,class:"nb-radio__input",onChange:o=>!e.readonly&&s.$emit("update:modelValue",a.value)},null,40,JE),b("span",QE,[e.modelValue===a.value?(g(),E("span",e$)):F("",!0)])]),b("span",t$,Z(a.label),1)],2))),128))],2),e.error?(g(),de(Qe,{key:1,variant:"error",class:"nb-radio__message"},{default:ee(()=>[ce(Z(e.error),1)]),_:1})):e.warning?(g(),de(Qe,{key:2,variant:"warning",class:"nb-radio__message"},{default:ee(()=>[ce(Z(e.warning),1)]),_:1})):e.helper?(g(),de(Qe,{key:3,variant:"helper",class:"nb-radio__message"},{default:ee(()=>[ce(Z(e.helper),1)]),_:1})):F("",!0)],2))}}),[["__scopeId","data-v-e4a0c524"]]);const da=(e,t,i)=>{const r=s=>Me("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:t,fill:"currentColor",...s,innerHTML:i});return r.displayName="NbGlyph",r.glyphName=e,r},r$=da("bell","0 0 256 256",'<path d="M218.35,178C212.58,168,204,140.13,204,104a76,76,0,1,0-152,0c0,36.13-8.59,64-14.36,73.95A12,12,0,0,0,48,196H92.23a36,36,0,0,0,71.54,0H208A12,12,0,0,0,218.35,178ZM128,220a28,28,0,0,1-27.71-24h55.42A28,28,0,0,1,128,220Zm83.45-34a3.91,3.91,0,0,1-3.44,2H48a3.91,3.91,0,0,1-3.44-2,4,4,0,0,1,0-4C52,169.17,60,139.32,60,104a68,68,0,1,1,136,0c0,35.31,8,65.17,15.44,78A4,4,0,0,1,211.45,186Z"/>'),s$=da("bell","0 0 256 256",'<path d="M220.07,176.94C214.41,167.2,206,139.73,206,104a78,78,0,1,0-156,0c0,35.74-8.42,63.2-14.08,72.94A14,14,0,0,0,48,198H90.48a38,38,0,0,0,75,0H208a14,14,0,0,0,12.06-21.06ZM128,218a26,26,0,0,1-25.29-20h50.58A26,26,0,0,1,128,218Zm81.71-33a1.9,1.9,0,0,1-1.7,1H48a1.9,1.9,0,0,1-1.7-1,2,2,0,0,1,0-2C53.87,170,62,139.69,62,104a66,66,0,1,1,132,0c0,35.68,8.14,65.95,15.71,79A2,2,0,0,1,209.71,185Z"/>'),y6=da("bell","0 0 256 256",'<path d="M221.8,175.94C216.25,166.38,208,139.33,208,104a80,80,0,1,0-160,0c0,35.34-8.26,62.38-13.81,71.94A16,16,0,0,0,48,200H88.81a40,40,0,0,0,78.38,0H208a16,16,0,0,0,13.8-24.06ZM128,216a24,24,0,0,1-22.62-16h45.24A24,24,0,0,1,128,216ZM48,184c7.7-13.24,16-43.92,16-80a64,64,0,1,1,128,0c0,36.05,8.28,66.73,16,80Z"/>'),n$=da("bell","0 0 256 256",'<path d="M225.29,165.93C216.61,151,212,129.57,212,104a84,84,0,0,0-168,0c0,25.58-4.59,47-13.27,61.93A20.08,20.08,0,0,0,30.66,186,19.77,19.77,0,0,0,48,196H84.18a44,44,0,0,0,87.64,0H208a19.77,19.77,0,0,0,17.31-10A20.08,20.08,0,0,0,225.29,165.93ZM128,212a20,20,0,0,1-19.6-16h39.2A20,20,0,0,1,128,212ZM54.66,172C63.51,154,68,131.14,68,104a60,60,0,0,1,120,0c0,27.13,4.48,50,13.33,68Z"/>'),a$=da("bell","0 0 256 256",'<path d="M221.8,175.94C216.25,166.38,208,139.33,208,104a80,80,0,1,0-160,0c0,35.34-8.26,62.38-13.81,71.94A16,16,0,0,0,48,200H88.81a40,40,0,0,0,78.38,0H208a16,16,0,0,0,13.8-24.06ZM128,216a24,24,0,0,1-22.62-16h45.24A24,24,0,0,1,128,216Z"/>'),o$=da("bell","0 0 256 256",'<path d="M208,192H48a8,8,0,0,1-6.88-12C47.71,168.6,56,139.81,56,104a72,72,0,0,1,144,0c0,35.82,8.3,64.6,14.9,76A8,8,0,0,1,208,192Z" opacity="0.2"/><path d="M221.8,175.94C216.25,166.38,208,139.33,208,104a80,80,0,1,0-160,0c0,35.34-8.26,62.38-13.81,71.94A16,16,0,0,0,48,200H88.81a40,40,0,0,0,78.38,0H208a16,16,0,0,0,13.8-24.06ZM128,216a24,24,0,0,1-22.62-16h45.24A24,24,0,0,1,128,216ZM48,184c7.7-13.24,16-43.92,16-80a64,64,0,1,1,128,0c0,36.05,8.28,66.73,16,80Z"/>'),l$="bell",c$=Object.freeze(Object.defineProperty({__proto__:null,bold:n$,default:y6,duotone:o$,fill:a$,glyphName:l$,light:s$,regular:y6,thin:r$},Symbol.toStringTag,{value:"Module"})),u$=(e,t,i)=>{const r=s=>Me("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:t,fill:"currentColor",...s,innerHTML:i});return r.displayName="NbGlyph",r.glyphName=e,r},w6=u$("minus","0 0 256 256",'<path d="M224,128a8,8,0,0,1-8,8H40a8,8,0,0,1,0-16H216A8,8,0,0,1,224,128Z"/>');var h$=["id","placeholder","min","max","step","disabled","required"],d$={class:"nb-number-input__steppers"},f$=["disabled"],p$=["disabled"],_$={key:0,class:"nb-number-input__inner-header"},m$=["for"],g$={key:0,class:"nb-number-input__asterisk","aria-hidden":"true"},v$={class:"nb-number-input__fluid-row"},b$=["id","placeholder","min","max","step","disabled","required"],y$={class:"nb-number-input__steppers"},w$=["disabled"],S$=["disabled"],Cd=ht(Re({__name:"NumberInput",props:{modelValue:{default:null},min:{default:void 0},max:{default:void 0},step:{default:1},placeholder:{default:""},name:{},disabled:{type:Boolean,default:!1},required:{type:Boolean,default:!1},id:{default:void 0},label:{default:""},error:{default:""},warning:{default:""},helper:{default:""},variant:{default:"default"},size:{default:"md"}},emits:["update:modelValue","change"],setup(e,{expose:t,emit:i}){let r=e,s=i,n=X(null),a=X(!1),o=`nb-number-input-${qi()}`,l=Q(()=>r.id??o),c=Q(()=>r.min!==void 0&&r.modelValue!==null&&r.modelValue!==void 0&&r.modelValue<=r.min),u=Q(()=>r.max!==void 0&&r.modelValue!==null&&r.modelValue!==void 0&&r.modelValue>=r.max);function h(w){let v=w;return r.min!==void 0&&(v=Math.max(r.min,v)),r.max!==void 0&&(v=Math.min(r.max,v)),v}function d(w){n.value&&(n.value.value=w==null?"":String(w))}ut(()=>d(r.modelValue)),Fe(()=>r.modelValue,w=>{a.value||d(w)});function f(){let w=h((r.modelValue??0)+r.step);s("update:modelValue",w),s("change",w),d(w)}function m(){let w=h((r.modelValue??0)-r.step);s("update:modelValue",w),s("change",w),d(w)}function _(){if(!n.value)return;let w=n.value.value;if(w==="")s("update:modelValue",null);else{let v=parseFloat(w);isNaN(v)||s("update:modelValue",v)}}function y(){if(a.value=!1,!n.value)return;let w=n.value.value;if(w===""){s("update:modelValue",null),s("change",null);return}let v=parseFloat(w);if(!isNaN(v)){let k=h(v);s("update:modelValue",k),s("change",k),d(k)}}let p=Q(()=>["nb-number-input",`nb-number-input--${r.variant}`,`nb-number-input--${r.size}`,{"nb-number-input--error":!!r.error,"nb-number-input--warning":!r.error&&!!r.warning,"nb-number-input--disabled":r.disabled}]),C=Q(()=>({"nb-number-input__field-wrapper--focused":a.value,"nb-number-input__field-wrapper--error":!!r.error,"nb-number-input__field-wrapper--warning":!r.error&&!!r.warning,"nb-number-input__field-wrapper--disabled":r.disabled}));return t({focus:()=>{var w;return(w=n.value)==null?void 0:w.focus()}}),(w,v)=>(g(),E("div",{class:xe(p.value)},[e.variant==="default"?(g(),E(we,{key:0},[e.label?(g(),de(sa,{key:0,for:l.value,required:e.required,disabled:e.disabled},{default:ee(()=>[ce(Z(e.label),1)]),_:1},8,["for","required","disabled"])):F("",!0),b("div",{class:xe(["nb-number-input__field-wrapper",C.value])},[b("input",{id:l.value,ref_key:"inputRef",ref:n,type:"number",class:"nb-number-input__field",placeholder:e.placeholder,min:e.min,max:e.max,step:e.step,disabled:e.disabled,required:e.required,onInput:_,onBlur:y,onKeydown:v[0]||(v[0]=Br(at(()=>{var k;return(k=n.value)==null?void 0:k.blur()},["prevent"]),["enter"])),onFocus:v[1]||(v[1]=k=>a.value=!0)},null,40,h$),e.error?(g(),de(Qe,{key:0,variant:"error","icon-only":!0,class:"nb-number-input__status"},{default:ee(()=>[ce(Z(e.error),1)]),_:1})):e.warning?(g(),de(Qe,{key:1,variant:"warning","icon-only":!0,class:"nb-number-input__status"},{default:ee(()=>[ce(Z(e.warning),1)]),_:1})):F("",!0),b("div",d$,[b("button",{type:"button",class:xe(["nb-number-input__stepper",{"nb-number-input__stepper--at-limit":c.value}]),disabled:e.disabled,"aria-label":"Decrease",onMousedown:v[2]||(v[2]=at(()=>{},["prevent"])),onClick:m},[Y(Ge,{name:ue(w6),size:16},null,8,["name"])],42,f$),b("button",{type:"button",class:xe(["nb-number-input__stepper",{"nb-number-input__stepper--at-limit":u.value}]),disabled:e.disabled,"aria-label":"Increase",onMousedown:v[3]||(v[3]=at(()=>{},["prevent"])),onClick:f},[Y(Ge,{name:ue(ll),size:16},null,8,["name"])],42,p$)])],2),e.error?(g(),de(Qe,{key:1,variant:"error",class:"nb-number-input__message"},{default:ee(()=>[ce(Z(e.error),1)]),_:1})):e.warning?(g(),de(Qe,{key:2,variant:"warning",class:"nb-number-input__message"},{default:ee(()=>[ce(Z(e.warning),1)]),_:1})):e.helper?(g(),de(Qe,{key:3,variant:"helper",class:"nb-number-input__message"},{default:ee(()=>[ce(Z(e.helper),1)]),_:1})):F("",!0)],64)):e.variant==="fluid"?(g(),E(we,{key:1},[b("div",{class:xe(["nb-number-input__field-wrapper",C.value])},[e.label?(g(),E("div",_$,[b("label",{for:l.value,class:"nb-number-input__inner-label"},[ce(Z(e.label)+" ",1),e.required?(g(),E("span",g$,"*")):F("",!0)],8,m$),e.helper&&!e.error&&!e.warning?(g(),de(Qe,{key:0,variant:"helper","icon-only":!0,class:"nb-number-input__inner-message"},{default:ee(()=>[ce(Z(e.helper),1)]),_:1})):F("",!0)])):F("",!0),b("div",v$,[b("input",{id:l.value,ref_key:"inputRef",ref:n,type:"number",class:"nb-number-input__field",placeholder:e.placeholder,min:e.min,max:e.max,step:e.step,disabled:e.disabled,required:e.required,onInput:_,onBlur:y,onKeydown:v[4]||(v[4]=Br(at(()=>{var k;return(k=n.value)==null?void 0:k.blur()},["prevent"]),["enter"])),onFocus:v[5]||(v[5]=k=>a.value=!0)},null,40,b$),e.error?(g(),de(Qe,{key:0,variant:"error","icon-only":!0,class:"nb-number-input__status"},{default:ee(()=>[ce(Z(e.error),1)]),_:1})):e.warning?(g(),de(Qe,{key:1,variant:"warning","icon-only":!0,class:"nb-number-input__status"},{default:ee(()=>[ce(Z(e.warning),1)]),_:1})):F("",!0),b("div",y$,[b("button",{type:"button",class:xe(["nb-number-input__stepper",{"nb-number-input__stepper--at-limit":c.value}]),disabled:e.disabled,"aria-label":"Decrease",onMousedown:v[6]||(v[6]=at(()=>{},["prevent"])),onClick:m},[Y(Ge,{name:ue(w6),size:16},null,8,["name"])],42,w$),b("button",{type:"button",class:xe(["nb-number-input__stepper",{"nb-number-input__stepper--at-limit":u.value}]),disabled:e.disabled,"aria-label":"Increase",onMousedown:v[7]||(v[7]=at(()=>{},["prevent"])),onClick:f},[Y(Ge,{name:ue(ll),size:16},null,8,["name"])],42,S$)])])],2),e.error?(g(),de(Qe,{key:0,variant:"error",class:"nb-number-input__fluid-message"},{default:ee(()=>[ce(Z(e.error),1)]),_:1})):e.warning?(g(),de(Qe,{key:1,variant:"warning",class:"nb-number-input__fluid-message"},{default:ee(()=>[ce(Z(e.warning),1)]),_:1})):F("",!0)],64)):F("",!0)],2))}}),[["__scopeId","data-v-89630543"]]),C$=["stop-color"],k$=["stop-color"],A$=["d","fill"],M$=["d","stroke","stroke-width"],S6=100,fn=30,L$=ht(Re({__name:"Sparkline",props:{data:{},color:{default:"var(--nb-c-primary)"},height:{default:40},width:{default:"100%"},strokeWidth:{default:1.5},fill:{type:Boolean,default:!0},smooth:{type:Boolean,default:!0}},setup(e){let t=e,i=`0 0 ${S6} ${fn}`,r=`nb-sparkline-grad-${qi()}`,s=Q(()=>({width:typeof t.width=="number"?`${t.width}px`:t.width,height:typeof t.height=="number"?`${t.height}px`:t.height})),n=Q(()=>{let a=t.data;if(!a||a.length<2)return{line:"",area:""};let o=Math.max(...a),l=Math.min(...a),c=o-l||1,u=S6/(a.length-1),h=fn*.08,d=fn-h*2,f=a.map((p,C)=>({x:C*u,y:fn-h-(p-l)/c*d})),m=`M ${f[0].x.toFixed(2)} ${f[0].y.toFixed(2)}`;if(t.smooth)for(let p=1;p<f.length;p++){let C=f[p-1],w=f[p],v=C.x+u*.45,k=C.y,$=w.x-u*.45,M=w.y;m+=` C ${v.toFixed(2)} ${k.toFixed(2)}, ${$.toFixed(2)} ${M.toFixed(2)}, ${w.x.toFixed(2)} ${w.y.toFixed(2)}`}else for(let p=1;p<f.length;p++)m+=` L ${f[p].x.toFixed(2)} ${f[p].y.toFixed(2)}`;let _=f[f.length-1],y=`${m} L ${_.x.toFixed(2)} ${fn} L ${f[0].x.toFixed(2)} ${fn} Z`;return{line:m,area:y}});return(a,o)=>(g(),E("svg",{class:"nb-sparkline",style:Ci(s.value),viewBox:i,preserveAspectRatio:"none",role:"img","aria-label":"Sparkline",xmlns:"http://www.w3.org/2000/svg"},[b("defs",null,[b("linearGradient",{id:r,x1:"0",y1:"0",x2:"0",y2:"1"},[b("stop",{offset:"0%","stop-color":e.color,"stop-opacity":"0.3"},null,8,C$),b("stop",{offset:"100%","stop-color":e.color,"stop-opacity":"0"},null,8,k$)])]),e.fill&&n.value.area?(g(),E("path",{key:0,d:n.value.area,fill:`url(#${r})`,stroke:"none"},null,8,A$)):F("",!0),n.value.line?(g(),E("path",{key:1,d:n.value.line,stroke:e.color,"stroke-width":e.strokeWidth,"vector-effect":"non-scaling-stroke",fill:"none","stroke-linecap":"round","stroke-linejoin":"round"},null,8,M$)):F("",!0)],4))}}),[["__scopeId","data-v-e796f74d"]]),tg=function(e){return e.Line="line",e.Contained="contained",e}(tg||{}),Nu=function(e){return e.Small="sm",e.Medium="md",e.Large="lg",e}(Nu||{}),E$=["aria-label"],$$=["id","data-tab-id","aria-selected","aria-controls","tabindex","disabled","onClick"],x$={class:"nb-tabs__label"},T$=["id","aria-labelledby"],N$=ht(Re({__name:"Tabs",props:{items:{},ariaLabel:{default:void 0},modelValue:{default:void 0},variant:{default:tg.Line},size:{default:Nu.Medium},disabled:{type:Boolean,default:!1},fullWidth:{type:Boolean,default:!1},id:{default:void 0}},emits:["update:modelValue","change"],setup(e,{emit:t}){var k;let i=e,r=t,s=ks(),n=cd(i),a=X(null),o=Q(()=>i.items.filter($=>!d($))),l=X(i.modelValue??((k=o.value[0])==null?void 0:k.id));Fe(()=>i.modelValue,$=>{$!=null&&(l.value=$)});let c=Q(()=>{var D;let $=i.modelValue??l.value,M=i.items.find(H=>H.id===$);return M&&!d(M)?M.id:(D=o.value[0])==null?void 0:D.id}),u=Q(()=>i.size===Nu.Large?18:16),h=Q(()=>["nb-tabs",`nb-tabs--${i.variant}`,`nb-tabs--${i.size}`,{"nb-tabs--full-width":i.fullWidth,"nb-tabs--disabled":i.disabled}]);function d($){return i.disabled||!!$.disabled}function f($){return`${n}-tab-${$}`}function m($){return`${n}-panel-${$}`}function _($){return X4(s,$)}function y($){d($)||$.id===c.value||(l.value=$.id,r("update:modelValue",$.id),r("change",$.id,$))}function p($){var M,D;(D=(M=a.value)==null?void 0:M.querySelectorAll("[data-tab-id]"))==null||D.forEach(H=>{H.dataset.tabId===$&&H.focus()})}function C($){let M=o.value;if(!M.length)return;let D=M[(M.findIndex(H=>H.id===c.value)+$+M.length)%M.length];y(D),p(D.id)}function w($){$&&(y($),p($.id))}function v($){switch($.key){case"ArrowRight":C(1);break;case"ArrowLeft":C(-1);break;case"Home":w(o.value[0]);break;case"End":w(o.value[o.value.length-1]);break;default:return}$.preventDefault()}return($,M)=>(g(),E("div",{class:xe(h.value)},[b("div",{ref_key:"listRef",ref:a,class:"nb-tabs__list",role:"tablist","aria-label":e.ariaLabel||void 0,onKeydown:v},[(g(!0),E(we,null,Be(e.items,D=>(g(),E("button",{id:f(D.id),key:D.id,"data-tab-id":D.id,type:"button",role:"tab",class:xe(["nb-tabs__tab",{"nb-tabs__tab--active":D.id===c.value}]),"aria-selected":D.id===c.value,"aria-controls":_(D.id)?m(D.id):void 0,tabindex:D.id===c.value?0:-1,disabled:d(D),onClick:H=>y(D)},[D.icon?(g(),de(Ge,{key:0,name:D.icon,size:u.value,class:"nb-tabs__icon"},null,8,["name","size"])):F("",!0),b("span",x$,Z(D.label),1),D.badge==null?F("",!0):(g(),de(an,{key:1,size:"sm",class:"nb-tabs__badge"},{default:ee(()=>[ce(Z(D.badge),1)]),_:2},1024))],10,$$))),128))],40,E$),(g(!0),E(we,null,Be(e.items,D=>(g(),E(we,{key:`panel-${D.id}`},[D.id===c.value&&_(D.id)?(g(),E("div",{key:0,id:m(D.id),class:"nb-tabs__panel",role:"tabpanel","aria-labelledby":f(D.id),tabindex:"0"},[Pe($.$slots,D.id,{item:D},void 0,!0)],8,T$)):F("",!0)],64))),128))],2))}}),[["__scopeId","data-v-84dd1ef0"]]),H$={class:"nb-shell-panel__header"},P$={class:"nb-shell-panel__header-left"},O$={key:0,class:"nb-shell-panel__title"},I$={class:"nb-shell-panel__header-center"},R$={class:"nb-shell-panel__toolbar"},D$=["aria-label"],V$=["aria-pressed"],B$=["aria-pressed"],Z$=["aria-pressed"],F$={key:0,class:"nb-shell-panel__content"},kd=ht(Re({__name:"ShellPanel",props:{size:{default:"default"},title:{default:""},fluid:{type:Boolean,default:!1},fill:{type:Boolean,default:!1}},emits:["update:size"],setup(e,{expose:t,emit:i}){let r=e,{layerProps:s}=In(),n=i,a=X(r.size);Fe(()=>r.size,c=>a.value=c);let o=Q({get:()=>a.value,set:c=>{a.value=c,n("update:size",c)}});function l(c){o.value=c}return t({setSize:l}),(c,u)=>(g(),E("div",Jt({class:"nb-shell-panel"},ue(s),{class:[o.value,{"nb-shell-panel--fluid":e.fluid,"nb-shell-panel--fill":e.fill}]}),[b("div",H$,[b("div",P$,[e.title?(g(),E("span",O$,Z(e.title),1)):F("",!0),Pe(c.$slots,"title",{},void 0,!0)]),b("div",I$,[b("div",R$,[Pe(c.$slots,"toolbar",{},void 0,!0)])]),b("div",{class:"nb-shell-panel__header-right",role:"group","aria-label":e.title?`${e.title} panel size`:"Panel size"},[Pe(c.$slots,"controls",{},()=>[b("button",{type:"button",class:xe(["nb-shell-panel__size-btn",{active:o.value==="collapsed"}]),"aria-pressed":o.value==="collapsed",title:"Minimize","aria-label":"Minimize",onClick:u[0]||(u[0]=h=>l("collapsed"))},[...u[3]||(u[3]=[b("svg",{width:"12",height:"12",viewBox:"0 0 12 12","aria-hidden":"true"},[b("line",{x1:"2",y1:"10",x2:"10",y2:"10",stroke:"currentColor","stroke-width":"1.5"})],-1)])],10,V$),b("button",{type:"button",class:xe(["nb-shell-panel__size-btn",{active:o.value==="default"}]),"aria-pressed":o.value==="default",title:"Default","aria-label":"Default",onClick:u[1]||(u[1]=h=>l("default"))},[...u[4]||(u[4]=[b("svg",{width:"12",height:"12",viewBox:"0 0 12 12","aria-hidden":"true"},[b("rect",{x:"1",y:"5",width:"10",height:"6",rx:"1",fill:"none",stroke:"currentColor","stroke-width":"1.2"})],-1)])],10,B$),b("button",{type:"button",class:xe(["nb-shell-panel__size-btn",{active:o.value==="full"}]),"aria-pressed":o.value==="full",title:"Maximize","aria-label":"Maximize",onClick:u[2]||(u[2]=h=>l("full"))},[...u[5]||(u[5]=[b("svg",{width:"12",height:"12",viewBox:"0 0 12 12","aria-hidden":"true"},[b("rect",{x:"1",y:"1",width:"10",height:"10",rx:"1",fill:"none",stroke:"currentColor","stroke-width":"1.2"}),b("line",{x1:"1",y1:"3.5",x2:"11",y2:"3.5",stroke:"currentColor","stroke-width":"1.2"})],-1)])],10,Z$)],!0)],8,D$)]),o.value==="collapsed"?F("",!0):(g(),E("div",F$,[Pe(c.$slots,"default",{},void 0,!0)]))],16))}}),[["__scopeId","data-v-9b368e15"]]);const z$="modulepreload",U$=function(e){return"/"+e},C6={},k6=function(t,i,r){let s=Promise.resolve();if(i&&i.length>0){document.getElementsByTagName("link");const a=document.querySelector("meta[property=csp-nonce]"),o=(a==null?void 0:a.nonce)||(a==null?void 0:a.getAttribute("nonce"));s=Promise.allSettled(i.map(l=>{if(l=U$(l),l in C6)return;C6[l]=!0;const c=l.endsWith(".css"),u=c?'[rel="stylesheet"]':"";if(document.querySelector(`link[href="${l}"]${u}`))return;const h=document.createElement("link");if(h.rel=c?"stylesheet":z$,c||(h.as="script"),h.crossOrigin="",h.href=l,o&&h.setAttribute("nonce",o),document.head.appendChild(h),c)return new Promise((d,f)=>{h.addEventListener("load",d),h.addEventListener("error",()=>f(new Error(`Unable to preload CSS for ${l}`)))})}))}function n(a){const o=new Event("vite:preloadError",{cancelable:!0});if(o.payload=a,window.dispatchEvent(o),!o.defaultPrevented)throw a}return s.then(a=>{for(const o of a||[])o.status==="rejected"&&n(o.reason);return t().catch(n)})};var W$=900,ig=class extends Error{constructor(){super("confirm timed out"),this.name="ConfirmTimeout"}},j$="This is taking longer than expected. It may still be running. Check before trying again.",Cs=Ar(null),kc=X(!1),Cn=X(!1),B0=X(!1),Z0=X(void 0),rg=[],pn=null,Ul=null,l0=null,c0=null;function K$(){return rd()?0:200}function q$(){c0&&clearTimeout(c0),c0=null}function G$(e){if(e instanceof Error&&e.message)return e.message;let t=String(e);return t==="[object Object]"?"Something went wrong.":t}function Y$(){l0=null;let e=rg.shift()??null;Cs.value=e,kc.value=!!e}function A6(e,t){return!e.done&&e.attempt===t&&Cs.value===e}function u0(e,t=Cs.value){!t||t.done||t===Cs.value&&(t.done=!0,q$(),kc.value=!1,Cn.value=!1,B0.value=!1,Z0.value=void 0,t.resolve(e),l0&&clearTimeout(l0),l0=setTimeout(Y$,K$()))}function X$(e,t){return new Promise((i,r)=>{let s=setTimeout(()=>r(new ig),t);e.then(n=>{clearTimeout(s),i(n)},n=>{clearTimeout(s),r(n)})})}async function J$(){let e=Cs.value;if(!e||e.done||Cn.value||B0.value)return;let{onConfirm:t,formatError:i,timeout:r,timeoutMessage:s,successLabel:n}=e.options;if(!t){u0(!0,e);return}let a=++e.attempt;Cn.value=!0,Z0.value=void 0;try{let o=Promise.resolve(t());if(await(r&&r>0?X$(o,r):o),!A6(e,a))return;Cn.value=!1,n?(B0.value=!0,c0=setTimeout(()=>u0(!0,e),W$)):u0(!0,e)}catch(o){if(!A6(e,a))return;Cn.value=!1,Z0.value=o instanceof ig?s??j$:(i??G$)(o)}}function Q$(e){let t={...e??{title:""}};return delete t.onConfirm,delete t.formatError,delete t.body,t}var ex=Re({name:"NbConfirmHost",setup(){return()=>{var i;let e=((i=Cs.value)==null?void 0:i.options)??null,t=e==null?void 0:e.body;return Me(yE,{...Q$(e),open:kc.value,busy:Cn.value,succeeded:B0.value,error:Z0.value??"",onConfirm:J$,onCancel:()=>u0(!1)},t?{default:()=>t()}:void 0)}}});function tx(){if(!pn){if(typeof document>"u")throw Error("[NbConfirm] confirm() needs a DOM. It cannot run during server-side rendering or in a non-browser environment. Call it from an event handler, not from setup().");Ul=document.createElement("div"),Ul.setAttribute("data-nb-confirm-host",""),document.body.appendChild(Ul),pn=_m(ex),pn.component("NbIcon",Ge),pn.component("NbGrid",Qi),pn.config.warnHandler=(e,t,i)=>{if(e.includes("Failed to resolve component")){console.error(`[NbConfirm] ${e} The dialog runs in its own Vue app, so a sibling resolved by name has to be registered in useConfirm.composable.ts. Import it in NbConfirm instead where you can.`);return}console.warn(`[NbConfirm] ${e}${i}`)},pn.mount(Ul)}}function ix(e){return tx(),new Promise(t=>{let i={options:e,resolve:t,attempt:0,done:!1};if(Cs.value){rg.push(i);return}Cs.value=i,kc.value=!0})}function rx(){return ix}var sg={storageKey:"nubisco.theme",defaultTheme:"system",darkClass:"dark"},ng="(prefers-color-scheme: dark)",Vn={...sg},ag=!1,_n=null,hs=X(sg.defaultTheme),F0=X("light");function sx(e){return e==="light"||e==="dark"||e==="system"}function nx(){try{if(typeof localStorage>"u")return null;let e=localStorage.getItem(Vn.storageKey);return sx(e)?e:null}catch{return null}}function ax(e){try{if(typeof localStorage>"u")return;localStorage.setItem(Vn.storageKey,e)}catch{}}function ox(){return typeof window>"u"||typeof window.matchMedia!="function"?!1:window.matchMedia(ng).matches}function Hu(){let e=hs.value==="dark"||hs.value==="system"&&ox();F0.value=e?"dark":"light",!(typeof document>"u")&&(document.documentElement.classList.toggle(Vn.darkClass,e),document.documentElement.style.colorScheme=F0.value)}function lx(){if(_n==null||_n(),_n=null,typeof window>"u"||typeof window.matchMedia!="function")return;let e=window.matchMedia(ng),t=()=>Hu();typeof e.addEventListener=="function"?(e.addEventListener("change",t),_n=()=>e.removeEventListener("change",t)):typeof e.addListener=="function"&&(e.addListener(t),_n=()=>e.removeListener(t))}var Wl=null;function og(){hs.value=nx()??Vn.defaultTheme,Hu(),lx(),Wl==null||Wl(),Wl=Fe(hs,e=>{ax(e),Hu()}),ag=!0}function cx(e={}){Vn={...Vn,...e},og()}function Ad(){return ag||og(),{theme:xn(hs),resolved:xn(F0),followsSystem:Q(()=>hs.value==="system"),setTheme:e=>{hs.value=e},toggle:()=>{hs.value=F0.value==="dark"?"light":"dark"}}}var lg={storageKey:"nubisco.named-theme",defaultTheme:null,attribute:"data-nb-theme",themes:null,persist:!0},Pi={...lg},Pu=X(lg.defaultTheme);function cg(e){return typeof e=="string"&&/^[a-z0-9-]{1,64}$/.test(e)}function ug(e){return!Pi.themes||Pi.themes.includes(e)}function ux(){if(!Pi.persist)return null;try{if(typeof localStorage>"u")return null;let e=localStorage.getItem(Pi.storageKey);return e===null||e===""?null:cg(e)&&ug(e)?e:null}catch{return null}}function hx(e){if(Pi.persist)try{if(typeof localStorage>"u")return;e===null?localStorage.removeItem(Pi.storageKey):localStorage.setItem(Pi.storageKey,e)}catch{}}function M6(){if(typeof document>"u")return;let e=Pu.value;e===null?document.documentElement.removeAttribute(Pi.attribute):document.documentElement.setAttribute(Pi.attribute,e)}var jl=null;function dx(){let e=ux(),t=Pi.defaultTheme;Pu.value=e??(t!==null&&cg(t)&&ug(t)?t:null),M6(),jl==null||jl(),jl=Fe(Pu,i=>{hx(i),M6()})}function fx(e={}){Pi={...Pi,...e,themes:e.themes??Pi.themes},dx()}const px=4,hg=pc("notifications",()=>{const e=X([]),t=Q(()=>e.value.slice(0,px));function i(n){e.value.push(n)}function r(n){const a=e.value.findIndex(o=>o.id===n);a!==-1&&e.value.splice(a,1)}function s(){e.value=[]}return{queue:e,visible:t,add:i,remove:r,clear:s}}),_x={class:"toast-layer","aria-live":"polite","aria-atomic":"true"},mx={class:"toast-body"},gx={key:0,class:"toast-title"},vx={class:"toast-message"},bx=Re({__name:"NotificationToasts",setup(e){const t=hg(),i=new Map;Fe(()=>t.visible.map(s=>({id:s.id,duration:s.duration??3200})),s=>{for(const n of s){if(i.has(n.id))continue;const a=setTimeout(()=>{t.remove(n.id),i.delete(n.id)},n.duration);i.set(n.id,a)}},{immediate:!0,deep:!0});function r(s){const n=i.get(s);n&&(clearTimeout(n),i.delete(s)),t.remove(s)}return(s,n)=>{const a=oi;return g(),E("div",_x,[(g(!0),E(we,null,Be(ue(t).visible,o=>(g(),E("div",{key:o.id,class:xe(["toast",`toast--${o.variant}`])},[b("div",mx,[o.title?(g(),E("div",gx,Z(o.title),1)):F("",!0),b("div",vx,Z(o.message),1)]),Y(a,{variant:"ghost",size:"xs",icon:bu,title:"Dismiss",onClick:l=>r(o.id)},null,8,["onClick"])],2))),128))])}}}),jt=(e,t)=>{const i=e.__vccOpts||e;for(const[r,s]of t)i[r]=s;return i},yx=jt(bx,[["__scopeId","data-v-5b1d791e"]]),wx=Re({__name:"App",setup(e){return(t,i)=>{const r=qo("RouterView");return g(),E(we,null,[Y(r),Y(yx)],64)}}});/*!
|
|
43
|
-
* vue-router v4.6.4
|
|
44
|
-
* (c) 2025 Eduardo San Martin Morote
|
|
45
|
-
* @license MIT
|
|
46
|
-
*/const wn=typeof document<"u";function dg(e){return typeof e=="object"||"displayName"in e||"props"in e||"__vccOpts"in e}function Sx(e){return e.__esModule||e[Symbol.toStringTag]==="Module"||e.default&&dg(e.default)}const it=Object.assign;function h1(e,t){const i={};for(const r in t){const s=t[r];i[r]=rr(s)?s.map(e):e(s)}return i}const Zo=()=>{},rr=Array.isArray;function L6(e,t){const i={};for(const r in e)i[r]=r in t?t[r]:e[r];return i}const fg=/#/g,Cx=/&/g,kx=/\//g,Ax=/=/g,Mx=/\?/g,pg=/\+/g,Lx=/%5B/g,Ex=/%5D/g,_g=/%5E/g,$x=/%60/g,mg=/%7B/g,xx=/%7C/g,gg=/%7D/g,Tx=/%20/g;function Md(e){return e==null?"":encodeURI(""+e).replace(xx,"|").replace(Lx,"[").replace(Ex,"]")}function Nx(e){return Md(e).replace(mg,"{").replace(gg,"}").replace(_g,"^")}function Ou(e){return Md(e).replace(pg,"%2B").replace(Tx,"+").replace(fg,"%23").replace(Cx,"%26").replace($x,"`").replace(mg,"{").replace(gg,"}").replace(_g,"^")}function Hx(e){return Ou(e).replace(Ax,"%3D")}function Px(e){return Md(e).replace(fg,"%23").replace(Mx,"%3F")}function Ox(e){return Px(e).replace(kx,"%2F")}function cl(e){if(e==null)return null;try{return decodeURIComponent(""+e)}catch{}return""+e}const Ix=/\/$/,Rx=e=>e.replace(Ix,"");function d1(e,t,i="/"){let r,s={},n="",a="";const o=t.indexOf("#");let l=t.indexOf("?");return l=o>=0&&l>o?-1:l,l>=0&&(r=t.slice(0,l),n=t.slice(l,o>0?o:t.length),s=e(n.slice(1))),o>=0&&(r=r||t.slice(0,o),a=t.slice(o,t.length)),r=Zx(r??t,i),{fullPath:r+n+a,path:r,query:s,hash:cl(a)}}function Dx(e,t){const i=t.query?e(t.query):"";return t.path+(i&&"?")+i+(t.hash||"")}function E6(e,t){return!t||!e.toLowerCase().startsWith(t.toLowerCase())?e:e.slice(t.length)||"/"}function Vx(e,t,i){const r=t.matched.length-1,s=i.matched.length-1;return r>-1&&r===s&&Bn(t.matched[r],i.matched[s])&&vg(t.params,i.params)&&e(t.query)===e(i.query)&&t.hash===i.hash}function Bn(e,t){return(e.aliasOf||e)===(t.aliasOf||t)}function vg(e,t){if(Object.keys(e).length!==Object.keys(t).length)return!1;for(var i in e)if(!Bx(e[i],t[i]))return!1;return!0}function Bx(e,t){return rr(e)?$6(e,t):rr(t)?$6(t,e):(e==null?void 0:e.valueOf())===(t==null?void 0:t.valueOf())}function $6(e,t){return rr(t)?e.length===t.length&&e.every((i,r)=>i===t[r]):e.length===1&&e[0]===t}function Zx(e,t){if(e.startsWith("/"))return e;if(!e)return t;const i=t.split("/"),r=e.split("/"),s=r[r.length-1];(s===".."||s===".")&&r.push("");let n=i.length-1,a,o;for(a=0;a<r.length;a++)if(o=r[a],o!==".")if(o==="..")n>1&&n--;else break;return i.slice(0,n).join("/")+"/"+r.slice(a).join("/")}const is={path:"/",name:void 0,params:{},query:{},hash:"",fullPath:"/",matched:[],meta:{},redirectedFrom:void 0};let Iu=function(e){return e.pop="pop",e.push="push",e}({}),f1=function(e){return e.back="back",e.forward="forward",e.unknown="",e}({});function Fx(e){if(!e)if(wn){const t=document.querySelector("base");e=t&&t.getAttribute("href")||"/",e=e.replace(/^\w+:\/\/[^\/]+/,"")}else e="/";return e[0]!=="/"&&e[0]!=="#"&&(e="/"+e),Rx(e)}const zx=/^[^#]+#/;function Ux(e,t){return e.replace(zx,"#")+t}function Wx(e,t){const i=document.documentElement.getBoundingClientRect(),r=e.getBoundingClientRect();return{behavior:t.behavior,left:r.left-i.left-(t.left||0),top:r.top-i.top-(t.top||0)}}const Ac=()=>({left:window.scrollX,top:window.scrollY});function jx(e){let t;if("el"in e){const i=e.el,r=typeof i=="string"&&i.startsWith("#"),s=typeof i=="string"?r?document.getElementById(i.slice(1)):document.querySelector(i):i;if(!s)return;t=Wx(s,e)}else t=e;"scrollBehavior"in document.documentElement.style?window.scrollTo(t):window.scrollTo(t.left!=null?t.left:window.scrollX,t.top!=null?t.top:window.scrollY)}function x6(e,t){return(history.state?history.state.position-t:-1)+e}const Ru=new Map;function Kx(e,t){Ru.set(e,t)}function qx(e){const t=Ru.get(e);return Ru.delete(e),t}function Gx(e){return typeof e=="string"||e&&typeof e=="object"}function bg(e){return typeof e=="string"||typeof e=="symbol"}let Lt=function(e){return e[e.MATCHER_NOT_FOUND=1]="MATCHER_NOT_FOUND",e[e.NAVIGATION_GUARD_REDIRECT=2]="NAVIGATION_GUARD_REDIRECT",e[e.NAVIGATION_ABORTED=4]="NAVIGATION_ABORTED",e[e.NAVIGATION_CANCELLED=8]="NAVIGATION_CANCELLED",e[e.NAVIGATION_DUPLICATED=16]="NAVIGATION_DUPLICATED",e}({});const yg=Symbol("");Lt.MATCHER_NOT_FOUND+"",Lt.NAVIGATION_GUARD_REDIRECT+"",Lt.NAVIGATION_ABORTED+"",Lt.NAVIGATION_CANCELLED+"",Lt.NAVIGATION_DUPLICATED+"";function Zn(e,t){return it(new Error,{type:e,[yg]:!0},t)}function Hr(e,t){return e instanceof Error&&yg in e&&(t==null||!!(e.type&t))}const Yx=["params","query","hash"];function Xx(e){if(typeof e=="string")return e;if(e.path!=null)return e.path;const t={};for(const i of Yx)i in e&&(t[i]=e[i]);return JSON.stringify(t,null,2)}function Jx(e){const t={};if(e===""||e==="?")return t;const i=(e[0]==="?"?e.slice(1):e).split("&");for(let r=0;r<i.length;++r){const s=i[r].replace(pg," "),n=s.indexOf("="),a=cl(n<0?s:s.slice(0,n)),o=n<0?null:cl(s.slice(n+1));if(a in t){let l=t[a];rr(l)||(l=t[a]=[l]),l.push(o)}else t[a]=o}return t}function T6(e){let t="";for(let i in e){const r=e[i];if(i=Hx(i),r==null){r!==void 0&&(t+=(t.length?"&":"")+i);continue}(rr(r)?r.map(s=>s&&Ou(s)):[r&&Ou(r)]).forEach(s=>{s!==void 0&&(t+=(t.length?"&":"")+i,s!=null&&(t+="="+s))})}return t}function Qx(e){const t={};for(const i in e){const r=e[i];r!==void 0&&(t[i]=rr(r)?r.map(s=>s==null?null:""+s):r==null?r:""+r)}return t}const eT=Symbol(""),N6=Symbol(""),Mc=Symbol(""),Ld=Symbol(""),Du=Symbol("");function mo(){let e=[];function t(r){return e.push(r),()=>{const s=e.indexOf(r);s>-1&&e.splice(s,1)}}function i(){e=[]}return{add:t,list:()=>e.slice(),reset:i}}function cs(e,t,i,r,s,n=a=>a()){const a=r&&(r.enterCallbacks[s]=r.enterCallbacks[s]||[]);return()=>new Promise((o,l)=>{const c=d=>{d===!1?l(Zn(Lt.NAVIGATION_ABORTED,{from:i,to:t})):d instanceof Error?l(d):Gx(d)?l(Zn(Lt.NAVIGATION_GUARD_REDIRECT,{from:t,to:d})):(a&&r.enterCallbacks[s]===a&&typeof d=="function"&&a.push(d),o())},u=n(()=>e.call(r&&r.instances[s],t,i,c));let h=Promise.resolve(u);e.length<3&&(h=h.then(c)),h.catch(d=>l(d))})}function p1(e,t,i,r,s=n=>n()){const n=[];for(const a of e)for(const o in a.components){let l=a.components[o];if(!(t!=="beforeRouteEnter"&&!a.instances[o]))if(dg(l)){const c=(l.__vccOpts||l)[t];c&&n.push(cs(c,i,r,a,o,s))}else{let c=l();n.push(()=>c.then(u=>{if(!u)throw new Error(`Couldn't resolve component "${o}" at "${a.path}"`);const h=Sx(u)?u.default:u;a.mods[o]=u,a.components[o]=h;const d=(h.__vccOpts||h)[t];return d&&cs(d,i,r,a,o,s)()}))}}return n}function tT(e,t){const i=[],r=[],s=[],n=Math.max(t.matched.length,e.matched.length);for(let a=0;a<n;a++){const o=t.matched[a];o&&(e.matched.find(c=>Bn(c,o))?r.push(o):i.push(o));const l=e.matched[a];l&&(t.matched.find(c=>Bn(c,l))||s.push(l))}return[i,r,s]}/*!
|
|
47
|
-
* vue-router v4.6.4
|
|
48
|
-
* (c) 2025 Eduardo San Martin Morote
|
|
49
|
-
* @license MIT
|
|
50
|
-
*/let iT=()=>location.protocol+"//"+location.host;function wg(e,t){const{pathname:i,search:r,hash:s}=t,n=e.indexOf("#");if(n>-1){let a=s.includes(e.slice(n))?e.slice(n).length:1,o=s.slice(a);return o[0]!=="/"&&(o="/"+o),E6(o,"")}return E6(i,e)+r+s}function rT(e,t,i,r){let s=[],n=[],a=null;const o=({state:d})=>{const f=wg(e,location),m=i.value,_=t.value;let y=0;if(d){if(i.value=f,t.value=d,a&&a===m){a=null;return}y=_?d.position-_.position:0}else r(f);s.forEach(p=>{p(i.value,m,{delta:y,type:Iu.pop,direction:y?y>0?f1.forward:f1.back:f1.unknown})})};function l(){a=i.value}function c(d){s.push(d);const f=()=>{const m=s.indexOf(d);m>-1&&s.splice(m,1)};return n.push(f),f}function u(){if(document.visibilityState==="hidden"){const{history:d}=window;if(!d.state)return;d.replaceState(it({},d.state,{scroll:Ac()}),"")}}function h(){for(const d of n)d();n=[],window.removeEventListener("popstate",o),window.removeEventListener("pagehide",u),document.removeEventListener("visibilitychange",u)}return window.addEventListener("popstate",o),window.addEventListener("pagehide",u),document.addEventListener("visibilitychange",u),{pauseListeners:l,listen:c,destroy:h}}function H6(e,t,i,r=!1,s=!1){return{back:e,current:t,forward:i,replaced:r,position:window.history.length,scroll:s?Ac():null}}function sT(e){const{history:t,location:i}=window,r={value:wg(e,i)},s={value:t.state};s.value||n(r.value,{back:null,current:r.value,forward:null,position:t.length-1,replaced:!0,scroll:null},!0);function n(l,c,u){const h=e.indexOf("#"),d=h>-1?(i.host&&document.querySelector("base")?e:e.slice(h))+l:iT()+e+l;try{t[u?"replaceState":"pushState"](c,"",d),s.value=c}catch(f){console.error(f),i[u?"replace":"assign"](d)}}function a(l,c){n(l,it({},t.state,H6(s.value.back,l,s.value.forward,!0),c,{position:s.value.position}),!0),r.value=l}function o(l,c){const u=it({},s.value,t.state,{forward:l,scroll:Ac()});n(u.current,u,!0),n(l,it({},H6(r.value,l,null),{position:u.position+1},c),!1),r.value=l}return{location:r,state:s,push:o,replace:a}}function nT(e){e=Fx(e);const t=sT(e),i=rT(e,t.state,t.location,t.replace);function r(n,a=!0){a||i.pauseListeners(),history.go(n)}const s=it({location:"",base:e,go:r,createHref:Ux.bind(null,e)},t,i);return Object.defineProperty(s,"location",{enumerable:!0,get:()=>t.location.value}),Object.defineProperty(s,"state",{enumerable:!0,get:()=>t.state.value}),s}let qs=function(e){return e[e.Static=0]="Static",e[e.Param=1]="Param",e[e.Group=2]="Group",e}({});var Ft=function(e){return e[e.Static=0]="Static",e[e.Param=1]="Param",e[e.ParamRegExp=2]="ParamRegExp",e[e.ParamRegExpEnd=3]="ParamRegExpEnd",e[e.EscapeNext=4]="EscapeNext",e}(Ft||{});const aT={type:qs.Static,value:""},oT=/[a-zA-Z0-9_]/;function lT(e){if(!e)return[[]];if(e==="/")return[[aT]];if(!e.startsWith("/"))throw new Error(`Invalid path "${e}"`);function t(f){throw new Error(`ERR (${i})/"${c}": ${f}`)}let i=Ft.Static,r=i;const s=[];let n;function a(){n&&s.push(n),n=[]}let o=0,l,c="",u="";function h(){c&&(i===Ft.Static?n.push({type:qs.Static,value:c}):i===Ft.Param||i===Ft.ParamRegExp||i===Ft.ParamRegExpEnd?(n.length>1&&(l==="*"||l==="+")&&t(`A repeatable param (${c}) must be alone in its segment. eg: '/:ids+.`),n.push({type:qs.Param,value:c,regexp:u,repeatable:l==="*"||l==="+",optional:l==="*"||l==="?"})):t("Invalid state to consume buffer"),c="")}function d(){c+=l}for(;o<e.length;){if(l=e[o++],l==="\\"&&i!==Ft.ParamRegExp){r=i,i=Ft.EscapeNext;continue}switch(i){case Ft.Static:l==="/"?(c&&h(),a()):l===":"?(h(),i=Ft.Param):d();break;case Ft.EscapeNext:d(),i=r;break;case Ft.Param:l==="("?i=Ft.ParamRegExp:oT.test(l)?d():(h(),i=Ft.Static,l!=="*"&&l!=="?"&&l!=="+"&&o--);break;case Ft.ParamRegExp:l===")"?u[u.length-1]=="\\"?u=u.slice(0,-1)+l:i=Ft.ParamRegExpEnd:u+=l;break;case Ft.ParamRegExpEnd:h(),i=Ft.Static,l!=="*"&&l!=="?"&&l!=="+"&&o--,u="";break;default:t("Unknown state");break}}return i===Ft.ParamRegExp&&t(`Unfinished custom RegExp for param "${c}"`),h(),a(),s}const P6="[^/]+?",cT={sensitive:!1,strict:!1,start:!0,end:!0};var yi=function(e){return e[e._multiplier=10]="_multiplier",e[e.Root=90]="Root",e[e.Segment=40]="Segment",e[e.SubSegment=30]="SubSegment",e[e.Static=40]="Static",e[e.Dynamic=20]="Dynamic",e[e.BonusCustomRegExp=10]="BonusCustomRegExp",e[e.BonusWildcard=-50]="BonusWildcard",e[e.BonusRepeatable=-20]="BonusRepeatable",e[e.BonusOptional=-8]="BonusOptional",e[e.BonusStrict=.7000000000000001]="BonusStrict",e[e.BonusCaseSensitive=.25]="BonusCaseSensitive",e}(yi||{});const uT=/[.+*?^${}()[\]/\\]/g;function hT(e,t){const i=it({},cT,t),r=[];let s=i.start?"^":"";const n=[];for(const c of e){const u=c.length?[]:[yi.Root];i.strict&&!c.length&&(s+="/");for(let h=0;h<c.length;h++){const d=c[h];let f=yi.Segment+(i.sensitive?yi.BonusCaseSensitive:0);if(d.type===qs.Static)h||(s+="/"),s+=d.value.replace(uT,"\\$&"),f+=yi.Static;else if(d.type===qs.Param){const{value:m,repeatable:_,optional:y,regexp:p}=d;n.push({name:m,repeatable:_,optional:y});const C=p||P6;if(C!==P6){f+=yi.BonusCustomRegExp;try{`${C}`}catch(v){throw new Error(`Invalid custom RegExp for param "${m}" (${C}): `+v.message)}}let w=_?`((?:${C})(?:/(?:${C}))*)`:`(${C})`;h||(w=y&&c.length<2?`(?:/${w})`:"/"+w),y&&(w+="?"),s+=w,f+=yi.Dynamic,y&&(f+=yi.BonusOptional),_&&(f+=yi.BonusRepeatable),C===".*"&&(f+=yi.BonusWildcard)}u.push(f)}r.push(u)}if(i.strict&&i.end){const c=r.length-1;r[c][r[c].length-1]+=yi.BonusStrict}i.strict||(s+="/?"),i.end?s+="$":i.strict&&!s.endsWith("/")&&(s+="(?:/|$)");const a=new RegExp(s,i.sensitive?"":"i");function o(c){const u=c.match(a),h={};if(!u)return null;for(let d=1;d<u.length;d++){const f=u[d]||"",m=n[d-1];h[m.name]=f&&m.repeatable?f.split("/"):f}return h}function l(c){let u="",h=!1;for(const d of e){(!h||!u.endsWith("/"))&&(u+="/"),h=!1;for(const f of d)if(f.type===qs.Static)u+=f.value;else if(f.type===qs.Param){const{value:m,repeatable:_,optional:y}=f,p=m in c?c[m]:"";if(rr(p)&&!_)throw new Error(`Provided param "${m}" is an array but it is not repeatable (* or + modifiers)`);const C=rr(p)?p.join("/"):p;if(!C)if(y)d.length<2&&(u.endsWith("/")?u=u.slice(0,-1):h=!0);else throw new Error(`Missing required param "${m}"`);u+=C}}return u||"/"}return{re:a,score:r,keys:n,parse:o,stringify:l}}function dT(e,t){let i=0;for(;i<e.length&&i<t.length;){const r=t[i]-e[i];if(r)return r;i++}return e.length<t.length?e.length===1&&e[0]===yi.Static+yi.Segment?-1:1:e.length>t.length?t.length===1&&t[0]===yi.Static+yi.Segment?1:-1:0}function Sg(e,t){let i=0;const r=e.score,s=t.score;for(;i<r.length&&i<s.length;){const n=dT(r[i],s[i]);if(n)return n;i++}if(Math.abs(s.length-r.length)===1){if(O6(r))return 1;if(O6(s))return-1}return s.length-r.length}function O6(e){const t=e[e.length-1];return e.length>0&&t[t.length-1]<0}const fT={strict:!1,end:!0,sensitive:!1};function pT(e,t,i){const r=hT(lT(e.path),i),s=it(r,{record:e,parent:t,children:[],alias:[]});return t&&!s.record.aliasOf==!t.record.aliasOf&&t.children.push(s),s}function _T(e,t){const i=[],r=new Map;t=L6(fT,t);function s(h){return r.get(h)}function n(h,d,f){const m=!f,_=R6(h);_.aliasOf=f&&f.record;const y=L6(t,h),p=[_];if("alias"in h){const v=typeof h.alias=="string"?[h.alias]:h.alias;for(const k of v)p.push(R6(it({},_,{components:f?f.record.components:_.components,path:k,aliasOf:f?f.record:_})))}let C,w;for(const v of p){const{path:k}=v;if(d&&k[0]!=="/"){const $=d.record.path,M=$[$.length-1]==="/"?"":"/";v.path=d.record.path+(k&&M+k)}if(C=pT(v,d,y),f?f.alias.push(C):(w=w||C,w!==C&&w.alias.push(C),m&&h.name&&!D6(C)&&a(h.name)),Cg(C)&&l(C),_.children){const $=_.children;for(let M=0;M<$.length;M++)n($[M],C,f&&f.children[M])}f=f||C}return w?()=>{a(w)}:Zo}function a(h){if(bg(h)){const d=r.get(h);d&&(r.delete(h),i.splice(i.indexOf(d),1),d.children.forEach(a),d.alias.forEach(a))}else{const d=i.indexOf(h);d>-1&&(i.splice(d,1),h.record.name&&r.delete(h.record.name),h.children.forEach(a),h.alias.forEach(a))}}function o(){return i}function l(h){const d=vT(h,i);i.splice(d,0,h),h.record.name&&!D6(h)&&r.set(h.record.name,h)}function c(h,d){let f,m={},_,y;if("name"in h&&h.name){if(f=r.get(h.name),!f)throw Zn(Lt.MATCHER_NOT_FOUND,{location:h});y=f.record.name,m=it(I6(d.params,f.keys.filter(w=>!w.optional).concat(f.parent?f.parent.keys.filter(w=>w.optional):[]).map(w=>w.name)),h.params&&I6(h.params,f.keys.map(w=>w.name))),_=f.stringify(m)}else if(h.path!=null)_=h.path,f=i.find(w=>w.re.test(_)),f&&(m=f.parse(_),y=f.record.name);else{if(f=d.name?r.get(d.name):i.find(w=>w.re.test(d.path)),!f)throw Zn(Lt.MATCHER_NOT_FOUND,{location:h,currentLocation:d});y=f.record.name,m=it({},d.params,h.params),_=f.stringify(m)}const p=[];let C=f;for(;C;)p.unshift(C.record),C=C.parent;return{name:y,path:_,params:m,matched:p,meta:gT(p)}}e.forEach(h=>n(h));function u(){i.length=0,r.clear()}return{addRoute:n,resolve:c,removeRoute:a,clearRoutes:u,getRoutes:o,getRecordMatcher:s}}function I6(e,t){const i={};for(const r of t)r in e&&(i[r]=e[r]);return i}function R6(e){const t={path:e.path,redirect:e.redirect,name:e.name,meta:e.meta||{},aliasOf:e.aliasOf,beforeEnter:e.beforeEnter,props:mT(e),children:e.children||[],instances:{},leaveGuards:new Set,updateGuards:new Set,enterCallbacks:{},components:"components"in e?e.components||null:e.component&&{default:e.component}};return Object.defineProperty(t,"mods",{value:{}}),t}function mT(e){const t={},i=e.props||!1;if("component"in e)t.default=i;else for(const r in e.components)t[r]=typeof i=="object"?i[r]:i;return t}function D6(e){for(;e;){if(e.record.aliasOf)return!0;e=e.parent}return!1}function gT(e){return e.reduce((t,i)=>it(t,i.meta),{})}function vT(e,t){let i=0,r=t.length;for(;i!==r;){const n=i+r>>1;Sg(e,t[n])<0?r=n:i=n+1}const s=bT(e);return s&&(r=t.lastIndexOf(s,r-1)),r}function bT(e){let t=e;for(;t=t.parent;)if(Cg(t)&&Sg(e,t)===0)return t}function Cg({record:e}){return!!(e.name||e.components&&Object.keys(e.components).length||e.redirect)}function V6(e){const t=ai(Mc),i=ai(Ld),r=Q(()=>{const l=ue(e.to);return t.resolve(l)}),s=Q(()=>{const{matched:l}=r.value,{length:c}=l,u=l[c-1],h=i.matched;if(!u||!h.length)return-1;const d=h.findIndex(Bn.bind(null,u));if(d>-1)return d;const f=B6(l[c-2]);return c>1&&B6(u)===f&&h[h.length-1].path!==f?h.findIndex(Bn.bind(null,l[c-2])):d}),n=Q(()=>s.value>-1&&kT(i.params,r.value.params)),a=Q(()=>s.value>-1&&s.value===i.matched.length-1&&vg(i.params,r.value.params));function o(l={}){if(CT(l)){const c=t[ue(e.replace)?"replace":"push"](ue(e.to)).catch(Zo);return e.viewTransition&&typeof document<"u"&&"startViewTransition"in document&&document.startViewTransition(()=>c),c}return Promise.resolve()}return{route:r,href:Q(()=>r.value.href),isActive:n,isExactActive:a,navigate:o}}function yT(e){return e.length===1?e[0]:e}const wT=Re({name:"RouterLink",compatConfig:{MODE:3},props:{to:{type:[String,Object],required:!0},replace:Boolean,activeClass:String,exactActiveClass:String,custom:Boolean,ariaCurrentValue:{type:String,default:"page"},viewTransition:Boolean},useLink:V6,setup(e,{slots:t}){const i=tn(V6(e)),{options:r}=ai(Mc),s=Q(()=>({[Z6(e.activeClass,r.linkActiveClass,"router-link-active")]:i.isActive,[Z6(e.exactActiveClass,r.linkExactActiveClass,"router-link-exact-active")]:i.isExactActive}));return()=>{const n=t.default&&yT(t.default(i));return e.custom?n:Me("a",{"aria-current":i.isExactActive?e.ariaCurrentValue:null,href:i.href,onClick:i.navigate,class:s.value},n)}}}),ST=wT;function CT(e){if(!(e.metaKey||e.altKey||e.ctrlKey||e.shiftKey)&&!e.defaultPrevented&&!(e.button!==void 0&&e.button!==0)){if(e.currentTarget&&e.currentTarget.getAttribute){const t=e.currentTarget.getAttribute("target");if(/\b_blank\b/i.test(t))return}return e.preventDefault&&e.preventDefault(),!0}}function kT(e,t){for(const i in t){const r=t[i],s=e[i];if(typeof r=="string"){if(r!==s)return!1}else if(!rr(s)||s.length!==r.length||r.some((n,a)=>n.valueOf()!==s[a].valueOf()))return!1}return!0}function B6(e){return e?e.aliasOf?e.aliasOf.path:e.path:""}const Z6=(e,t,i)=>e??t??i,AT=Re({name:"RouterView",inheritAttrs:!1,props:{name:{type:String,default:"default"},route:Object},compatConfig:{MODE:3},setup(e,{attrs:t,slots:i}){const r=ai(Du),s=Q(()=>e.route||r.value),n=ai(N6,0),a=Q(()=>{let c=ue(n);const{matched:u}=s.value;let h;for(;(h=u[c])&&!h.components;)c++;return c}),o=Q(()=>s.value.matched[a.value]);ps(N6,Q(()=>a.value+1)),ps(eT,o),ps(Du,s);const l=X();return Fe(()=>[l.value,o.value,e.name],([c,u,h],[d,f,m])=>{u&&(u.instances[h]=c,f&&f!==u&&c&&c===d&&(u.leaveGuards.size||(u.leaveGuards=f.leaveGuards),u.updateGuards.size||(u.updateGuards=f.updateGuards))),c&&u&&(!f||!Bn(u,f)||!d)&&(u.enterCallbacks[h]||[]).forEach(_=>_(c))},{flush:"post"}),()=>{const c=s.value,u=e.name,h=o.value,d=h&&h.components[u];if(!d)return F6(i.default,{Component:d,route:c});const f=h.props[u],m=f?f===!0?c.params:typeof f=="function"?f(c):f:null,y=Me(d,it({},m,t,{onVnodeUnmounted:p=>{p.component.isUnmounted&&(h.instances[u]=null)},ref:l}));return F6(i.default,{Component:y,route:c})||y}}});function F6(e,t){if(!e)return null;const i=e(t);return i.length===1?i[0]:i}const MT=AT;function LT(e){const t=_T(e.routes,e),i=e.parseQuery||Jx,r=e.stringifyQuery||T6,s=e.history,n=mo(),a=mo(),o=mo(),l=Ar(is);let c=is;wn&&e.scrollBehavior&&"scrollRestoration"in history&&(history.scrollRestoration="manual");const u=h1.bind(null,O=>""+O),h=h1.bind(null,Ox),d=h1.bind(null,cl);function f(O,ie){let le,ge;return bg(O)?(le=t.getRecordMatcher(O),ge=ie):ge=O,t.addRoute(ge,le)}function m(O){const ie=t.getRecordMatcher(O);ie&&t.removeRoute(ie)}function _(){return t.getRoutes().map(O=>O.record)}function y(O){return!!t.getRecordMatcher(O)}function p(O,ie){if(ie=it({},ie||l.value),typeof O=="string"){const K=d1(i,O,ie.path),se=t.resolve({path:K.path},ie),he=s.createHref(K.fullPath);return it(K,se,{params:d(se.params),hash:cl(K.hash),redirectedFrom:void 0,href:he})}let le;if(O.path!=null)le=it({},O,{path:d1(i,O.path,ie.path).path});else{const K=it({},O.params);for(const se in K)K[se]==null&&delete K[se];le=it({},O,{params:h(K)}),ie.params=h(ie.params)}const ge=t.resolve(le,ie),Se=O.hash||"";ge.params=u(d(ge.params));const x=Dx(r,it({},O,{hash:Nx(Se),path:ge.path})),T=s.createHref(x);return it({fullPath:x,hash:Se,query:r===T6?Qx(O.query):O.query||{}},ge,{redirectedFrom:void 0,href:T})}function C(O){return typeof O=="string"?d1(i,O,l.value.path):it({},O)}function w(O,ie){if(c!==O)return Zn(Lt.NAVIGATION_CANCELLED,{from:ie,to:O})}function v(O){return M(O)}function k(O){return v(it(C(O),{replace:!0}))}function $(O,ie){const le=O.matched[O.matched.length-1];if(le&&le.redirect){const{redirect:ge}=le;let Se=typeof ge=="function"?ge(O,ie):ge;return typeof Se=="string"&&(Se=Se.includes("?")||Se.includes("#")?Se=C(Se):{path:Se},Se.params={}),it({query:O.query,hash:O.hash,params:Se.path!=null?{}:O.params},Se)}}function M(O,ie){const le=c=p(O),ge=l.value,Se=O.state,x=O.force,T=O.replace===!0,K=$(le,ge);if(K)return M(it(C(K),{state:typeof K=="object"?it({},Se,K.state):Se,force:x,replace:T}),ie||le);const se=le;se.redirectedFrom=ie;let he;return!x&&Vx(r,ge,le)&&(he=Zn(Lt.NAVIGATION_DUPLICATED,{to:se,from:ge}),re(ge,ge,!0,!1)),(he?Promise.resolve(he):R(se,ge)).catch(pe=>Hr(pe)?Hr(pe,Lt.NAVIGATION_GUARD_REDIRECT)?pe:fe(pe):ne(pe,se,ge)).then(pe=>{if(pe){if(Hr(pe,Lt.NAVIGATION_GUARD_REDIRECT))return M(it({replace:T},C(pe.to),{state:typeof pe.to=="object"?it({},Se,pe.to.state):Se,force:x}),ie||se)}else pe=N(se,ge,!0,T,Se);return V(se,ge,pe),pe})}function D(O,ie){const le=w(O,ie);return le?Promise.reject(le):Promise.resolve()}function H(O){const ie=$e.values().next().value;return ie&&typeof ie.runWithContext=="function"?ie.runWithContext(O):O()}function R(O,ie){let le;const[ge,Se,x]=tT(O,ie);le=p1(ge.reverse(),"beforeRouteLeave",O,ie);for(const K of ge)K.leaveGuards.forEach(se=>{le.push(cs(se,O,ie))});const T=D.bind(null,O,ie);return le.push(T),me(le).then(()=>{le=[];for(const K of n.list())le.push(cs(K,O,ie));return le.push(T),me(le)}).then(()=>{le=p1(Se,"beforeRouteUpdate",O,ie);for(const K of Se)K.updateGuards.forEach(se=>{le.push(cs(se,O,ie))});return le.push(T),me(le)}).then(()=>{le=[];for(const K of x)if(K.beforeEnter)if(rr(K.beforeEnter))for(const se of K.beforeEnter)le.push(cs(se,O,ie));else le.push(cs(K.beforeEnter,O,ie));return le.push(T),me(le)}).then(()=>(O.matched.forEach(K=>K.enterCallbacks={}),le=p1(x,"beforeRouteEnter",O,ie,H),le.push(T),me(le))).then(()=>{le=[];for(const K of a.list())le.push(cs(K,O,ie));return le.push(T),me(le)}).catch(K=>Hr(K,Lt.NAVIGATION_CANCELLED)?K:Promise.reject(K))}function V(O,ie,le){o.list().forEach(ge=>H(()=>ge(O,ie,le)))}function N(O,ie,le,ge,Se){const x=w(O,ie);if(x)return x;const T=ie===is,K=wn?history.state:{};le&&(ge||T?s.replace(O.fullPath,it({scroll:T&&K&&K.scroll},Se)):s.push(O.fullPath,Se)),l.value=O,re(O,ie,le,T),fe()}let P;function U(){P||(P=s.listen((O,ie,le)=>{if(!be.listening)return;const ge=p(O),Se=$(ge,be.currentRoute.value);if(Se){M(it(Se,{replace:!0,force:!0}),ge).catch(Zo);return}c=ge;const x=l.value;wn&&Kx(x6(x.fullPath,le.delta),Ac()),R(ge,x).catch(T=>Hr(T,Lt.NAVIGATION_ABORTED|Lt.NAVIGATION_CANCELLED)?T:Hr(T,Lt.NAVIGATION_GUARD_REDIRECT)?(M(it(C(T.to),{force:!0}),ge).then(K=>{Hr(K,Lt.NAVIGATION_ABORTED|Lt.NAVIGATION_DUPLICATED)&&!le.delta&&le.type===Iu.pop&&s.go(-1,!1)}).catch(Zo),Promise.reject()):(le.delta&&s.go(-le.delta,!1),ne(T,ge,x))).then(T=>{T=T||N(ge,x,!1),T&&(le.delta&&!Hr(T,Lt.NAVIGATION_CANCELLED)?s.go(-le.delta,!1):le.type===Iu.pop&&Hr(T,Lt.NAVIGATION_ABORTED|Lt.NAVIGATION_DUPLICATED)&&s.go(-1,!1)),V(ge,x,T)}).catch(Zo)}))}let j=mo(),oe=mo(),te;function ne(O,ie,le){fe(O);const ge=oe.list();return ge.length?ge.forEach(Se=>Se(O,ie,le)):console.error(O),Promise.reject(O)}function J(){return te&&l.value!==is?Promise.resolve():new Promise((O,ie)=>{j.add([O,ie])})}function fe(O){return te||(te=!O,U(),j.list().forEach(([ie,le])=>O?le(O):ie()),j.reset()),O}function re(O,ie,le,ge){const{scrollBehavior:Se}=e;if(!wn||!Se)return Promise.resolve();const x=!le&&qx(x6(O.fullPath,0))||(ge||!le)&&history.state&&history.state.scroll||null;return _i().then(()=>Se(O,ie,x)).then(T=>T&&jx(T)).catch(T=>ne(T,O,ie))}const _e=O=>s.go(O);let Ne;const $e=new Set,be={currentRoute:l,listening:!0,addRoute:f,removeRoute:m,clearRoutes:t.clearRoutes,hasRoute:y,getRoutes:_,resolve:p,options:e,push:v,replace:k,go:_e,back:()=>_e(-1),forward:()=>_e(1),beforeEach:n.add,beforeResolve:a.add,afterEach:o.add,onError:oe.add,isReady:J,install(O){O.component("RouterLink",ST),O.component("RouterView",MT),O.config.globalProperties.$router=be,Object.defineProperty(O.config.globalProperties,"$route",{enumerable:!0,get:()=>ue(l)}),wn&&!Ne&&l.value===is&&(Ne=!0,v(s.location).catch(ge=>{}));const ie={};for(const ge in is)Object.defineProperty(ie,ge,{get:()=>l.value[ge],enumerable:!0});O.provide(Mc,be),O.provide(Ld,m_(ie)),O.provide(Du,l);const le=O.unmount;$e.add(O),O.unmount=function(){$e.delete(O),$e.size<1&&(c=is,P&&P(),P=null,l.value=is,Ne=!1,te=!1),le()}}};function me(O){return O.reduce((ie,le)=>ie.then(()=>H(le)),Promise.resolve())}return be}function Cl(){return ai(Mc)}function Lc(e){return ai(Ld)}const ET="/logo.svg",fa=(e,t,i)=>{const r=s=>Me("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:t,fill:"currentColor",...s,innerHTML:i});return r.displayName="NbGlyph",r.glyphName=e,r},$T=fa("arrow-circle-up","0 0 256 256",'<path d="M128,28A100,100,0,1,0,228,128,100.11,100.11,0,0,0,128,28Zm0,192a92,92,0,1,1,92-92A92.1,92.1,0,0,1,128,220Zm34.83-102.83a4,4,0,0,1-5.66,5.66L132,97.66V168a4,4,0,0,1-8,0V97.66L98.83,122.83a4,4,0,0,1-5.66-5.66l32-32a4,4,0,0,1,5.66,0Z"/>'),xT=fa("arrow-circle-up","0 0 256 256",'<path d="M128,26A102,102,0,1,0,230,128,102.12,102.12,0,0,0,128,26Zm0,192a90,90,0,1,1,90-90A90.1,90.1,0,0,1,128,218Zm36.24-102.24a6,6,0,1,1-8.48,8.48L134,102.49V168a6,6,0,0,1-12,0V102.49l-21.76,21.75a6,6,0,0,1-8.48-8.48l32-32a6,6,0,0,1,8.48,0Z"/>'),Vu=fa("arrow-circle-up","0 0 256 256",'<path d="M128,24A104,104,0,1,0,232,128,104.11,104.11,0,0,0,128,24Zm0,192a88,88,0,1,1,88-88A88.1,88.1,0,0,1,128,216Zm37.66-101.66a8,8,0,0,1-11.32,11.32L136,107.31V168a8,8,0,0,1-16,0V107.31l-18.34,18.35a8,8,0,0,1-11.32-11.32l32-32a8,8,0,0,1,11.32,0Z"/>'),TT=fa("arrow-circle-up","0 0 256 256",'<path d="M128,20A108,108,0,1,0,236,128,108.12,108.12,0,0,0,128,20Zm0,192a84,84,0,1,1,84-84A84.09,84.09,0,0,1,128,212Zm40.49-100.49a12,12,0,0,1-17,17L140,117v51a12,12,0,0,1-24,0V117l-11.51,11.52a12,12,0,0,1-17-17l32-32a12,12,0,0,1,17,0Z"/>'),NT=fa("arrow-circle-up","0 0 256 256",'<path d="M128,24A104,104,0,1,0,232,128,104.11,104.11,0,0,0,128,24Zm37.66,101.66a8,8,0,0,1-11.32,0L136,107.31V168a8,8,0,0,1-16,0V107.31l-18.34,18.35a8,8,0,0,1-11.32-11.32l32-32a8,8,0,0,1,11.32,0l32,32A8,8,0,0,1,165.66,125.66Z"/>'),HT=fa("arrow-circle-up","0 0 256 256",'<path d="M224,128a96,96,0,1,1-96-96A96,96,0,0,1,224,128Z" opacity="0.2"/><path d="M128,24A104,104,0,1,0,232,128,104.11,104.11,0,0,0,128,24Zm0,192a88,88,0,1,1,88-88A88.1,88.1,0,0,1,128,216Zm37.66-101.66a8,8,0,0,1-11.32,11.32L136,107.31V168a8,8,0,0,1-16,0V107.31l-18.34,18.35a8,8,0,0,1-11.32-11.32l32-32a8,8,0,0,1,11.32,0Z"/>'),PT="arrow-circle-up",Ed=Object.freeze(Object.defineProperty({__proto__:null,bold:TT,default:Vu,duotone:HT,fill:NT,glyphName:PT,light:xT,regular:Vu,thin:$T},Symbol.toStringTag,{value:"Module"})),OT="/api";async function mt(e){const t=await fetch(`${OT}${e}`);if(!t.ok)throw new Error(`${t.status} ${t.statusText}`);return t.json()}async function z6(e,t){try{const i=await e.json(),r=i==null?void 0:i.message;if(typeof r=="string"&&r.trim()!=="")return r}catch{}return`${t}: ${e.status}`}const Ie={health:()=>mt("/health"),system:()=>mt("/system"),qr:()=>mt("/qr"),deviceEvents:(e,t=100)=>mt(`/devices/${encodeURIComponent(e)}/events?limit=${t}`),deviceObservations:(e,t=50)=>mt(`/devices/${encodeURIComponent(e)}/observations?limit=${t}`),reportObservation:(e,t)=>fetch(`/api/devices/${encodeURIComponent(e)}/observations`,{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify(t)}).then(async i=>{if(!i.ok)throw new Error((await i.json()).error??`HTTP ${i.status}`);return i.json()}),plugins:()=>mt("/plugins"),pluginsRefresh:()=>fetch("/api/plugins/refresh",{method:"POST"}).then(e=>e.json()),plugin:e=>mt(`/plugins/${e}`),setPluginDisabled:(e,t)=>fetch(`/api/plugins/${e}/disabled`,{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({disabled:t})}).then(i=>{if(!i.ok)throw new Error(`Set disabled failed: ${i.status}`);return i.json()}),bridge:()=>mt("/bridge"),saveBridge:e=>fetch("/api/bridge",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify(e)}).then(t=>{if(!t.ok)throw new Error(`Save failed: ${t.status}`);return t.json()}),accessories:()=>mt("/accessories"),devices:()=>mt("/devices"),controlDevice:(e,t,i)=>fetch(`/api/devices/${encodeURIComponent(e)}/control`,{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({control:t,value:i})}).then(r=>{if(!r.ok)throw new Error(`Control failed: ${r.status}`);return r.json()}),renameDevice:(e,t)=>fetch(`/api/devices/${encodeURIComponent(e)}/rename`,{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({name:t})}).then(i=>{if(!i.ok)throw new Error(`Rename failed: ${i.status}`);return i.json()}),deviceHistory:(e,t,i)=>{const r=new URLSearchParams({period:t});return i&&r.set("date",i),mt(`/devices/${encodeURIComponent(e)}/history?${r}`)},deviceMetrics:(e,t={})=>{const i=new URLSearchParams;t.metric&&i.set("metric",t.metric),t.from!==void 0&&i.set("from",String(t.from)),t.to!==void 0&&i.set("to",String(t.to)),t.maxPoints!==void 0&&i.set("maxPoints",String(t.maxPoints));const r=i.toString();return mt(`/devices/${encodeURIComponent(e)}/metrics${r?`?${r}`:""}`)},homekitHidden:()=>mt("/homekit/hidden"),setHomekitVisibility:(e,t)=>fetch(`/api/homekit/visibility/${encodeURIComponent(e)}`,{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({visible:t})}).then(i=>{if(!i.ok)throw new Error(`Visibility change failed: ${i.status}`);return i.json()}),deviceAccessory:e=>mt(`/devices/${encodeURIComponent(e)}/accessory`),homekitServiceTypes:()=>mt("/homekit/service-types"),setHomekitServiceType:(e,t,i)=>fetch(`/api/homekit/service-type/${encodeURIComponent(e)}`,{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({serviceUuid:t,type:i})}).then(async r=>{var s;if(!r.ok)throw new Error(((s=await r.json().catch(()=>null))==null?void 0:s.message)??`Type change failed: ${r.status}`);return r.json()}),setCharacteristic:(e,t,i,r)=>fetch(`/api/accessories/${e}/characteristics`,{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({serviceUuid:t,charUuid:i,value:r})}).then(s=>{if(!s.ok)throw new Error(`Set failed: ${s.status}`);return s.json()}),logs:(e,t=200)=>{const i=new URLSearchParams({limit:String(t)});return e&&i.set("plugin",e),mt(`/logs?${i}`)},pluginTelemetry:e=>mt(`/plugins/${encodeURIComponent(e)}/telemetry`),config:{get:()=>mt("/config"),save:e=>fetch("/api/config",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({content:e})}).then(t=>{if(!t.ok)throw new Error(`Save failed: ${t.status}`);return t.json()}),getPlatform:e=>mt(`/config/platform/${encodeURIComponent(e)}`),savePlatform:e=>fetch("/api/config/platform",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({platform:e})}).then(t=>{if(!t.ok)throw new Error(`Save failed: ${t.status}`);return t.json()}),getHbPlugin:(e,t)=>mt(`/config/hb-plugin/${encodeURIComponent(e)}${t?`?packageName=${encodeURIComponent(t)}`:""}`),saveHbPlugin:(e,t,i)=>fetch("/api/config/hb-plugin",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({name:e,packageName:i,config:t})}).then(r=>{if(!r.ok)throw new Error(`Save failed: ${r.status}`);return r.json()}),getPlugin:e=>mt(`/config/plugin/${encodeURIComponent(e)}`),savePlugin:(e,t)=>fetch("/api/config/plugin",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({name:e,config:t})}).then(i=>{if(!i.ok)throw new Error(`Save failed: ${i.status}`);return i.json()})},pluginInfo:e=>mt(`/marketplace/plugin-info/${encodeURIComponent(e)}`),daemon:{restart:()=>fetch("/api/daemon/restart",{method:"POST"}).then(e=>{if(!e.ok)throw new Error(`Restart failed: ${e.status}`);return e.json()})},updates:{check:()=>mt("/updates/check"),apply:()=>fetch("/api/updates/apply",{method:"POST"}).then(async e=>{if(!e.ok)throw new Error(await z6(e,"Update failed"));return e.json()}),rollback:()=>fetch("/api/updates/rollback",{method:"POST"}).then(async e=>{if(!e.ok)throw new Error(await z6(e,"Rollback failed"));return e.json()})},marketplace:{search:(e="",t=0,i=20)=>{const r=new URLSearchParams({q:e,from:String(t),size:String(i)});return mt(`/marketplace/search?${r}`)},enriched:e=>fetch(`/api/marketplace/enriched/${encodeURIComponent(e)}`).then(t=>t.ok?t.json():Promise.reject(new Error(`Enrichment failed: ${t.status}`))),installed:()=>mt("/marketplace/installed"),local:()=>mt("/marketplace/local"),install:e=>fetch("/api/marketplace/install",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({package:e})}).then(t=>{if(!t.ok)throw new Error(`Install failed: ${t.status}`);return t.json()}),update:e=>fetch(`/api/marketplace/update/${encodeURIComponent(e)}`,{method:"POST"}).then(t=>{if(!t.ok)throw new Error(`Update failed: ${t.status}`);return t.json()}),uninstall:e=>fetch(`/api/marketplace/uninstall/${encodeURIComponent(e)}`,{method:"DELETE"}).then(t=>{if(!t.ok)throw new Error(`Uninstall failed: ${t.status}`);return t.json()})}},xs=pc("daemon",()=>{const e=X(null),t=X([]),i=X([]),r=X([]),s=X(!1),n=X(null),a=X(!1),o=Q(()=>t.value.filter(y=>y.status==="running").length),l=Q(()=>t.value.filter(y=>y.status==="error").length);async function c(){try{e.value=await Ie.health(),a.value=!0,n.value=null}catch{a.value=!1,e.value=null}}async function u(){s.value=!0;try{const y=await Ie.plugins();t.value=y.plugins}catch(y){n.value=String(y)}finally{s.value=!1}}async function h(){try{const y=await Ie.accessories();i.value=y.accessories}catch{}}async function d(y){try{const p=await Ie.logs(y);r.value=p.entries}catch(p){n.value=String(p)}}let f=null;function m(){if(f)return;const y=location.protocol==="https:"?"wss:":"ws:";f=new WebSocket(`${y}//${location.host}/ws/logs`),f.onmessage=p=>{if(!document.hidden)try{const C=JSON.parse(p.data);r.value.push(C),r.value.length>500&&r.value.shift()}catch{}},f.onclose=()=>{f=null,setTimeout(m,3e3)}}function _(){f==null||f.close(),f=null}return{health:e,plugins:t,accessories:i,logs:r,loading:s,error:n,connected:a,runningCount:o,errorCount:l,fetchHealth:c,fetchPlugins:u,fetchAccessories:h,fetchLogs:d,connectLiveLogs:m,disconnectLiveLogs:_}}),U6=Object.freeze(Object.defineProperty({__proto__:null,useDaemonStore:xs},Symbol.toStringTag,{value:"Module"})),kl=pc("inspector",()=>{const e=X(!1),t=X("plugin"),i=X(null),r=X(null);function s(c){i.value=c,r.value=null,t.value="plugin",e.value=!0}function n(){i.value=null,r.value=null,t.value="marketplace",e.value=!0}function a(c){r.value=c,i.value=null,t.value="device",e.value=!0}function o(c){r.value&&t.value==="device"&&(c.kind==="native"&&r.value.kind==="native"?c.dev.id===r.value.dev.id&&(r.value=c):c.kind==="hap"&&r.value.kind==="hap"&&c.acc.uuid===r.value.acc.uuid&&(r.value=c))}function l(){e.value=!1,i.value=null,r.value=null}return{visible:e,mode:t,selectedPlugin:i,selectedDevice:r,openPlugin:s,openMarketplace:n,openDevice:a,updateDevice:o,close:l}}),ln=pc("layout",()=>{const e=X(""),t=X(null),i=X(!1);function r(s,n,a){e.value=s,t.value=n??null,i.value=(a==null?void 0:a.fullBleed)??!1}return{title:e,count:t,fullBleed:i,setPage:r}}),IT="openbridge_platform_state",W6="openbridge_platform_expected_sub",_1="openbridge_last_account",Rs=X(null),Ds=X(null),go=X(!1);function Ec(){async function e(){if(Ds.value)return Ds.value;const _=await fetch("/auth/platform/config");if(!_.ok){const p={enabled:!1,issuer:null,appId:null};return Ds.value=p,p}const y=await _.json();return Ds.value=y,y}function t(){try{const _=localStorage.getItem(_1);if(!_)return null;const y=JSON.parse(_);return y.sub&&y.email?y:null}catch{return null}}function i(_){try{localStorage.setItem(_1,JSON.stringify(_))}catch{}}function r(){try{localStorage.removeItem(_1)}catch{}}async function s(){if(!(await e()).enabled)return Rs.value=null,go.value=!0,!0;try{const y=await fetch("/auth/me",{credentials:"include"});if(!y.ok)return Rs.value=null,go.value=!0,!1;const p=await y.json();return Rs.value=p.user,i({sub:p.user.id,email:p.user.email}),go.value=!0,!0}catch{return Rs.value=null,go.value=!0,!1}}async function n(_={}){const y=await e();if(!y.enabled||!y.issuer)return;const p=y.appId??"openbridge",C=Array.from(crypto.getRandomValues(new Uint8Array(16))).map(k=>k.toString(16).padStart(2,"0")).join("");sessionStorage.setItem(IT,C),_.expectedSub?sessionStorage.setItem(W6,_.expectedSub):sessionStorage.removeItem(W6);const w=`${window.location.origin}/auth/callback`,v=new URL(`${y.issuer}/api/auth/sso`);v.searchParams.set("app_id",p),v.searchParams.set("redirect_uri",w),v.searchParams.set("state",C),_.prompt&&v.searchParams.set("prompt",_.prompt),_.loginHint&&v.searchParams.set("login_hint",_.loginHint),window.location.href=v.toString()}async function a(){const _=t();return _?(await n({loginHint:_.email,expectedSub:_.sub}),!0):!1}async function o(_){await n({loginHint:_})}async function l(){await n({prompt:"login"})}async function c(){await n({prompt:"select_account"})}async function u(){const _=await e();if(!_.enabled||!_.issuer)return[];try{const y=await fetch(`${_.issuer}/api/auth/identities`,{credentials:"include"});return y.ok?(await y.json()).identities??[]:[]}catch{return[]}}async function h(_){const y=await e();if(!y.enabled||!y.issuer)return!1;try{return(await fetch(`${y.issuer}/api/auth/identities/remove`,{method:"POST",headers:{"Content-Type":"application/json"},credentials:"include",body:JSON.stringify({user_id:_})})).ok}catch{return!1}}async function d(){await fetch("/auth/logout",{method:"POST",credentials:"include"}).catch(()=>null),Rs.value=null,r(),window.location.href="/login?logged_out=1"}async function f(){await fetch("/auth/logout",{method:"POST",credentials:"include"}).catch(()=>null),Rs.value=null,r();const _=Ds.value;if(_!=null&&_.enabled&&_.issuer&&_.appId){const y=`${window.location.origin}/login?logged_out=1`,p=new URL("/api/auth/sso/end-session",_.issuer);p.searchParams.set("app_id",_.appId),p.searchParams.set("post_logout_redirect_uri",y),window.location.href=p.toString();return}window.location.href="/login?logged_out=1"}const m=Q(()=>{var y;const _=(y=Ds.value)==null?void 0:y.issuer;if(!_)return!1;try{const p=new URL(_).hostname;return p==="nubisco.io"||p.endsWith(".nubisco.io")}catch{return!1}});return{user:Rs,config:Ds,ready:go,isNubiscoPlatform:m,loadConfig:e,checkAuth:s,startPlatformLogin:n,resumeLastAccount:a,switchAccount:o,addAccount:l,chooseAccount:c,listIdentities:u,removeIdentity:h,getLastAccount:t,clearLastAccount:r,logout:d,logoutEverywhere:f}}const pa=(e,t,i)=>{const r=s=>Me("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:t,fill:"currentColor",...s,innerHTML:i});return r.displayName="NbGlyph",r.glyphName=e,r},RT=pa("puzzle-piece","0 0 256 256",'<path d="M218.14,161.93a4,4,0,0,0-3.86-.24,24,24,0,0,1-34.23-23.25,24,24,0,0,1,34.23-20.13A4,4,0,0,0,220,114.7V72a12,12,0,0,0-12-12H167a32,32,0,1,0-62.91-10.33A32.57,32.57,0,0,0,105,60H64A12,12,0,0,0,52,72v37a32,32,0,1,0-10.33,62.91A32.28,32.28,0,0,0,52,171v37a12,12,0,0,0,12,12H208a12,12,0,0,0,12-12V165.31A4,4,0,0,0,218.14,161.93ZM212,208a4,4,0,0,1-4,4H64a4,4,0,0,1-4-4V165.31a4,4,0,0,0-1.86-3.38,4,4,0,0,0-3.85-.24,24,24,0,0,1-34.24-20.13,24,24,0,0,1,34.24-23.25A4,4,0,0,0,60,114.7V72a4,4,0,0,1,4-4h46.69a4,4,0,0,0,3.62-5.71,24,24,0,0,1,20.13-34.24,24,24,0,0,1,23.25,34.24A4,4,0,0,0,161.31,68H208a4,4,0,0,1,4,4v37a32.57,32.57,0,0,0-10.33-.94A32,32,0,1,0,212,171Z"/>'),DT=pa("puzzle-piece","0 0 256 256",'<path d="M219.21,160.24a6,6,0,0,0-5.78-.35,22,22,0,1,1-11.05-41.83,22.15,22.15,0,0,1,11.05,2.06A6,6,0,0,0,222,114.7V72a14,14,0,0,0-14-14H169.48a35,35,0,0,0,.52-6,34.1,34.1,0,0,0-10.73-24.78,33.64,33.64,0,0,0-25.45-9.15A34,34,0,0,0,102.54,58H64A14,14,0,0,0,50,72v34.53a34,34,0,0,0-30.79,10.2,34,34,0,0,0,22.31,57.18,34.34,34.34,0,0,0,8.48-.44V208a14,14,0,0,0,14,14H208a14,14,0,0,0,14-14V165.31A6,6,0,0,0,219.21,160.24ZM210,208a2,2,0,0,1-2,2H64a2,2,0,0,1-2-2V165.31a6,6,0,0,0-6-6,5.92,5.92,0,0,0-2.57.58,22,22,0,0,1-31.38-18.46,22,22,0,0,1,31.38-21.31A6,6,0,0,0,62,114.7V72a2,2,0,0,1,2-2h46.69a6,6,0,0,0,5.42-8.57,22.25,22.25,0,0,1-2-11,22,22,0,1,1,41.83,11A6,6,0,0,0,161.3,70H208a2,2,0,0,1,2,2v34.54a34,34,0,0,0-39.93,31.28,33.71,33.71,0,0,0,9.14,25.45A34.15,34.15,0,0,0,210,173.48Z"/>'),rn=pa("puzzle-piece","0 0 256 256",'<path d="M220.27,158.54a8,8,0,0,0-7.7-.46,20,20,0,1,1,0-36.16A8,8,0,0,0,224,114.69V72a16,16,0,0,0-16-16H171.78a35.36,35.36,0,0,0,.22-4,36.11,36.11,0,0,0-11.36-26.24,36,36,0,0,0-60.55,23.62,36.56,36.56,0,0,0,.14,6.62H64A16,16,0,0,0,48,72v32.22a35.36,35.36,0,0,0-4-.22,36.12,36.12,0,0,0-26.24,11.36,35.7,35.7,0,0,0-9.69,27,36.08,36.08,0,0,0,33.31,33.6,35.68,35.68,0,0,0,6.62-.14V208a16,16,0,0,0,16,16H208a16,16,0,0,0,16-16V165.31A8,8,0,0,0,220.27,158.54ZM208,208H64V165.31a8,8,0,0,0-11.43-7.23,20,20,0,1,1,0-36.16A8,8,0,0,0,64,114.69V72h46.69a8,8,0,0,0,7.23-11.43,20,20,0,1,1,36.16,0A8,8,0,0,0,161.31,72H208v32.23a35.68,35.68,0,0,0-6.62-.14A36,36,0,0,0,204,176a35.36,35.36,0,0,0,4-.22Z"/>'),VT=pa("puzzle-piece","0 0 256 256",'<path d="M222.41,155.16a12,12,0,0,0-11.56-.69A16,16,0,0,1,188,139,16.2,16.2,0,0,1,202.8,124a15.83,15.83,0,0,1,8,1.5A12,12,0,0,0,228,114.7V72a20,20,0,0,0-20-20H176a40.15,40.15,0,0,0-12.62-29.16,39.67,39.67,0,0,0-29.94-10.76,40.08,40.08,0,0,0-37.34,37C96,50.07,96,51,96,52H64A20,20,0,0,0,44,72v28a40.15,40.15,0,0,0-29.16,12.62A40,40,0,0,0,41.1,179.9a28.3,28.3,0,0,0,2.9.1v28a20,20,0,0,0,20,20H208a20,20,0,0,0,20-20V165.31A12,12,0,0,0,222.41,155.16ZM204,204H68V165.31a12,12,0,0,0-17.15-10.84A15.9,15.9,0,0,1,42.8,156,16.2,16.2,0,0,1,28,141.06a16,16,0,0,1,22.82-15.52A12,12,0,0,0,68,114.7V76h42.7a12,12,0,0,0,10.83-17.15A15.9,15.9,0,0,1,120,50.8,16.19,16.19,0,0,1,134.94,36a16,16,0,0,1,15.53,22.81A12,12,0,0,0,161.31,76H204v24c-1,0-1.93,0-2.9.11A40,40,0,0,0,204,180h0Z"/>'),BT=pa("puzzle-piece","0 0 256 256",'<path d="M165.78,224H208a16,16,0,0,0,16-16V170.35A8,8,0,0,0,212.94,163a23.37,23.37,0,0,1-8.94,1.77c-13.23,0-24-11.1-24-24.73s10.77-24.73,24-24.73a23.37,23.37,0,0,1,8.94,1.77A8,8,0,0,0,224,109.65V72a16,16,0,0,0-16-16H171.78a35.36,35.36,0,0,0,.22-4,36,36,0,0,0-72,0,35.36,35.36,0,0,0,.22,4H64A16,16,0,0,0,48,72v32.22a35.36,35.36,0,0,0-4-.22,36,36,0,0,0,0,72,35.36,35.36,0,0,0,4-.22V208a16,16,0,0,0,16,16h42.22"/>'),ZT=pa("puzzle-piece","0 0 256 256",'<path d="M204,168a28,28,0,0,0,12-2.69V208a8,8,0,0,1-8,8H64a8,8,0,0,1-8-8V165.31a28,28,0,1,1,0-50.62V72a8,8,0,0,1,8-8h46.69a28,28,0,1,1,50.61,0H208a8,8,0,0,1,8,8v42.69A28,28,0,1,0,204,168Z" opacity="0.2"/><path d="M220.27,158.54a8,8,0,0,0-7.7-.46,20,20,0,1,1,0-36.16A8,8,0,0,0,224,114.69V72a16,16,0,0,0-16-16H171.78a35.36,35.36,0,0,0,.22-4,36.15,36.15,0,0,0-11.36-26.25,36,36,0,0,0-60.55,23.63,36.56,36.56,0,0,0,.14,6.62H64A16,16,0,0,0,48,72v32.22a35.36,35.36,0,0,0-4-.22,36.12,36.12,0,0,0-26.24,11.36,35.7,35.7,0,0,0-9.69,27,36.08,36.08,0,0,0,33.31,33.6,36.56,36.56,0,0,0,6.62-.14V208a16,16,0,0,0,16,16H208a16,16,0,0,0,16-16V165.31A8,8,0,0,0,220.27,158.54ZM208,208H64V165.31a8,8,0,0,0-11.43-7.23,20,20,0,1,1,0-36.16A8,8,0,0,0,64,114.69V72h46.69a8,8,0,0,0,7.23-11.43,20,20,0,1,1,36.16,0A8,8,0,0,0,161.31,72H208v32.23a35.68,35.68,0,0,0-6.62-.14A36,36,0,0,0,204,176a35.36,35.36,0,0,0,4-.22Z"/>'),FT="puzzle-piece",zT=Object.freeze(Object.defineProperty({__proto__:null,bold:VT,default:rn,duotone:ZT,fill:BT,glyphName:FT,light:DT,regular:rn,thin:RT},Symbol.toStringTag,{value:"Module"})),_a=(e,t,i)=>{const r=s=>Me("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:t,fill:"currentColor",...s,innerHTML:i});return r.displayName="NbGlyph",r.glyphName=e,r},UT=_a("trash","0 0 256 256",'<path d="M216,52H172V40a20,20,0,0,0-20-20H104A20,20,0,0,0,84,40V52H40a4,4,0,0,0,0,8H52V208a12,12,0,0,0,12,12H192a12,12,0,0,0,12-12V60h12a4,4,0,0,0,0-8ZM92,40a12,12,0,0,1,12-12h48a12,12,0,0,1,12,12V52H92ZM196,208a4,4,0,0,1-4,4H64a4,4,0,0,1-4-4V60H196ZM108,104v64a4,4,0,0,1-8,0V104a4,4,0,0,1,8,0Zm48,0v64a4,4,0,0,1-8,0V104a4,4,0,0,1,8,0Z"/>'),WT=_a("trash","0 0 256 256",'<path d="M216,50H174V40a22,22,0,0,0-22-22H104A22,22,0,0,0,82,40V50H40a6,6,0,0,0,0,12H50V208a14,14,0,0,0,14,14H192a14,14,0,0,0,14-14V62h10a6,6,0,0,0,0-12ZM94,40a10,10,0,0,1,10-10h48a10,10,0,0,1,10,10V50H94ZM194,208a2,2,0,0,1-2,2H64a2,2,0,0,1-2-2V62H194ZM110,104v64a6,6,0,0,1-12,0V104a6,6,0,0,1,12,0Zm48,0v64a6,6,0,0,1-12,0V104a6,6,0,0,1,12,0Z"/>'),j6=_a("trash","0 0 256 256",'<path d="M216,48H176V40a24,24,0,0,0-24-24H104A24,24,0,0,0,80,40v8H40a8,8,0,0,0,0,16h8V208a16,16,0,0,0,16,16H192a16,16,0,0,0,16-16V64h8a8,8,0,0,0,0-16ZM96,40a8,8,0,0,1,8-8h48a8,8,0,0,1,8,8v8H96Zm96,168H64V64H192ZM112,104v64a8,8,0,0,1-16,0V104a8,8,0,0,1,16,0Zm48,0v64a8,8,0,0,1-16,0V104a8,8,0,0,1,16,0Z"/>'),jT=_a("trash","0 0 256 256",'<path d="M216,48H180V36A28,28,0,0,0,152,8H104A28,28,0,0,0,76,36V48H40a12,12,0,0,0,0,24h4V208a20,20,0,0,0,20,20H192a20,20,0,0,0,20-20V72h4a12,12,0,0,0,0-24ZM100,36a4,4,0,0,1,4-4h48a4,4,0,0,1,4,4V48H100Zm88,168H68V72H188ZM116,104v64a12,12,0,0,1-24,0V104a12,12,0,0,1,24,0Zm48,0v64a12,12,0,0,1-24,0V104a12,12,0,0,1,24,0Z"/>'),KT=_a("trash","0 0 256 256",'<path d="M216,48H176V40a24,24,0,0,0-24-24H104A24,24,0,0,0,80,40v8H40a8,8,0,0,0,0,16h8V208a16,16,0,0,0,16,16H192a16,16,0,0,0,16-16V64h8a8,8,0,0,0,0-16ZM112,168a8,8,0,0,1-16,0V104a8,8,0,0,1,16,0Zm48,0a8,8,0,0,1-16,0V104a8,8,0,0,1,16,0Zm0-120H96V40a8,8,0,0,1,8-8h48a8,8,0,0,1,8,8Z"/>'),qT=_a("trash","0 0 256 256",'<path d="M200,56V208a8,8,0,0,1-8,8H64a8,8,0,0,1-8-8V56Z" opacity="0.2"/><path d="M216,48H176V40a24,24,0,0,0-24-24H104A24,24,0,0,0,80,40v8H40a8,8,0,0,0,0,16h8V208a16,16,0,0,0,16,16H192a16,16,0,0,0,16-16V64h8a8,8,0,0,0,0-16ZM96,40a8,8,0,0,1,8-8h48a8,8,0,0,1,8,8v8H96Zm96,168H64V64H192ZM112,104v64a8,8,0,0,1-16,0V104a8,8,0,0,1,16,0Zm48,0v64a8,8,0,0,1-16,0V104a8,8,0,0,1,16,0Z"/>'),GT="trash",$d=Object.freeze(Object.defineProperty({__proto__:null,bold:jT,default:j6,duotone:qT,fill:KT,glyphName:GT,light:WT,regular:j6,thin:UT},Symbol.toStringTag,{value:"Module"})),ma=(e,t,i)=>{const r=s=>Me("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:t,fill:"currentColor",...s,innerHTML:i});return r.displayName="NbGlyph",r.glyphName=e,r},YT=ma("spinner","0 0 256 256",'<path d="M132,32V64a4,4,0,0,1-8,0V32a4,4,0,0,1,8,0Zm41.25,54.75a4,4,0,0,0,2.83-1.18L198.71,63a4,4,0,0,0-5.66-5.66L170.43,79.92a4,4,0,0,0,2.82,6.83ZM224,124H192a4,4,0,0,0,0,8h32a4,4,0,0,0,0-8Zm-47.92,46.43a4,4,0,1,0-5.65,5.65l22.62,22.63a4,4,0,0,0,5.66-5.66ZM128,188a4,4,0,0,0-4,4v32a4,4,0,0,0,8,0V192A4,4,0,0,0,128,188ZM79.92,170.43,57.29,193.05A4,4,0,0,0,63,198.71l22.62-22.63a4,4,0,1,0-5.65-5.65ZM68,128a4,4,0,0,0-4-4H32a4,4,0,0,0,0,8H64A4,4,0,0,0,68,128ZM63,57.29A4,4,0,0,0,57.29,63L79.92,85.57a4,4,0,1,0,5.65-5.65Z"/>'),XT=ma("spinner","0 0 256 256",'<path d="M134,32V64a6,6,0,0,1-12,0V32a6,6,0,0,1,12,0Zm39.25,56.75A6,6,0,0,0,177.5,87l22.62-22.63a6,6,0,0,0-8.48-8.48L169,78.5a6,6,0,0,0,4.24,10.25ZM224,122H192a6,6,0,0,0,0,12h32a6,6,0,0,0,0-12Zm-46.5,47A6,6,0,0,0,169,177.5l22.63,22.62a6,6,0,0,0,8.48-8.48ZM128,186a6,6,0,0,0-6,6v32a6,6,0,0,0,12,0V192A6,6,0,0,0,128,186ZM78.5,169,55.88,191.64a6,6,0,1,0,8.48,8.48L87,177.5A6,6,0,1,0,78.5,169ZM70,128a6,6,0,0,0-6-6H32a6,6,0,0,0,0,12H64A6,6,0,0,0,70,128ZM64.36,55.88a6,6,0,0,0-8.48,8.48L78.5,87A6,6,0,1,0,87,78.5Z"/>'),Fn=ma("spinner","0 0 256 256",'<path d="M136,32V64a8,8,0,0,1-16,0V32a8,8,0,0,1,16,0Zm37.25,58.75a8,8,0,0,0,5.66-2.35l22.63-22.62a8,8,0,0,0-11.32-11.32L167.6,77.09a8,8,0,0,0,5.65,13.66ZM224,120H192a8,8,0,0,0,0,16h32a8,8,0,0,0,0-16Zm-45.09,47.6a8,8,0,0,0-11.31,11.31l22.62,22.63a8,8,0,0,0,11.32-11.32ZM128,184a8,8,0,0,0-8,8v32a8,8,0,0,0,16,0V192A8,8,0,0,0,128,184ZM77.09,167.6,54.46,190.22a8,8,0,0,0,11.32,11.32L88.4,178.91A8,8,0,0,0,77.09,167.6ZM72,128a8,8,0,0,0-8-8H32a8,8,0,0,0,0,16H64A8,8,0,0,0,72,128ZM65.78,54.46A8,8,0,0,0,54.46,65.78L77.09,88.4A8,8,0,0,0,88.4,77.09Z"/>'),JT=ma("spinner","0 0 256 256",'<path d="M140,32V64a12,12,0,0,1-24,0V32a12,12,0,0,1,24,0Zm33.25,62.75a12,12,0,0,0,8.49-3.52L204.37,68.6a12,12,0,0,0-17-17L164.77,74.26a12,12,0,0,0,8.48,20.49ZM224,116H192a12,12,0,0,0,0,24h32a12,12,0,0,0,0-24Zm-42.26,48.77a12,12,0,1,0-17,17l22.63,22.63a12,12,0,0,0,17-17ZM128,180a12,12,0,0,0-12,12v32a12,12,0,0,0,24,0V192A12,12,0,0,0,128,180ZM74.26,164.77,51.63,187.4a12,12,0,0,0,17,17l22.63-22.63a12,12,0,1,0-17-17ZM76,128a12,12,0,0,0-12-12H32a12,12,0,0,0,0,24H64A12,12,0,0,0,76,128ZM68.6,51.63a12,12,0,1,0-17,17L74.26,91.23a12,12,0,0,0,17-17Z"/>'),QT=ma("spinner","0 0 256 256",'<path d="M128,24A104,104,0,1,0,232,128,104.11,104.11,0,0,0,128,24Zm33.94,58.75,17-17a8,8,0,0,1,11.32,11.32l-17,17a8,8,0,0,1-11.31-11.31ZM48,136a8,8,0,0,1,0-16H72a8,8,0,0,1,0,16Zm46.06,37.25-17,17a8,8,0,0,1-11.32-11.32l17-17a8,8,0,0,1,11.31,11.31Zm0-79.19a8,8,0,0,1-11.31,0l-17-17A8,8,0,0,1,77.09,65.77l17,17A8,8,0,0,1,94.06,94.06ZM136,208a8,8,0,0,1-16,0V184a8,8,0,0,1,16,0Zm0-136a8,8,0,0,1-16,0V48a8,8,0,0,1,16,0Zm54.23,118.23a8,8,0,0,1-11.32,0l-17-17a8,8,0,0,1,11.31-11.31l17,17A8,8,0,0,1,190.23,190.23ZM208,136H184a8,8,0,0,1,0-16h24a8,8,0,0,1,0,16Z"/>'),eN=ma("spinner","0 0 256 256",'<path d="M224,128a96,96,0,1,1-96-96A96,96,0,0,1,224,128Z" opacity="0.2"/><path d="M136,32V64a8,8,0,0,1-16,0V32a8,8,0,0,1,16,0Zm37.25,58.75a8,8,0,0,0,5.66-2.35l22.63-22.62a8,8,0,0,0-11.32-11.32L167.6,77.09a8,8,0,0,0,5.65,13.66ZM224,120H192a8,8,0,0,0,0,16h32a8,8,0,0,0,0-16Zm-45.09,47.6a8,8,0,0,0-11.31,11.31l22.62,22.63a8,8,0,0,0,11.32-11.32ZM128,184a8,8,0,0,0-8,8v32a8,8,0,0,0,16,0V192A8,8,0,0,0,128,184ZM77.09,167.6,54.46,190.22a8,8,0,0,0,11.32,11.32L88.4,178.91A8,8,0,0,0,77.09,167.6ZM72,128a8,8,0,0,0-8-8H32a8,8,0,0,0,0,16H64A8,8,0,0,0,72,128ZM65.78,54.46A8,8,0,0,0,54.46,65.78L77.09,88.4A8,8,0,0,0,88.4,77.09Z"/>'),tN="spinner",ul=Object.freeze(Object.defineProperty({__proto__:null,bold:JT,default:Fn,duotone:eN,fill:QT,glyphName:tN,light:XT,regular:Fn,thin:YT},Symbol.toStringTag,{value:"Module"})),ga=(e,t,i)=>{const r=s=>Me("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:t,fill:"currentColor",...s,innerHTML:i});return r.displayName="NbGlyph",r.glyphName=e,r},iN=ga("floppy-disk","0 0 256 256",'<path d="M216.49,74.83,181.17,39.51A11.93,11.93,0,0,0,172.69,36H48A12,12,0,0,0,36,48V208a12,12,0,0,0,12,12H208a12,12,0,0,0,12-12V83.31A11.93,11.93,0,0,0,216.49,74.83ZM172,212H84V152a4,4,0,0,1,4-4h80a4,4,0,0,1,4,4Zm40-4a4,4,0,0,1-4,4H180V152a12,12,0,0,0-12-12H88a12,12,0,0,0-12,12v60H48a4,4,0,0,1-4-4V48a4,4,0,0,1,4-4H172.69a4,4,0,0,1,2.82,1.17l35.32,35.32A4,4,0,0,1,212,83.31ZM156,72a4,4,0,0,1-4,4H96a4,4,0,0,1,0-8h56A4,4,0,0,1,156,72Z"/>'),rN=ga("floppy-disk","0 0 256 256",'<path d="M217.9,73.42,182.58,38.1a13.9,13.9,0,0,0-9.89-4.1H48A14,14,0,0,0,34,48V208a14,14,0,0,0,14,14H208a14,14,0,0,0,14-14V83.31A13.9,13.9,0,0,0,217.9,73.42ZM170,210H86V152a2,2,0,0,1,2-2h80a2,2,0,0,1,2,2Zm40-2a2,2,0,0,1-2,2H182V152a14,14,0,0,0-14-14H88a14,14,0,0,0-14,14v58H48a2,2,0,0,1-2-2V48a2,2,0,0,1,2-2H172.69a2,2,0,0,1,1.41.58L209.42,81.9a2,2,0,0,1,.58,1.41ZM158,72a6,6,0,0,1-6,6H96a6,6,0,0,1,0-12h56A6,6,0,0,1,158,72Z"/>'),K6=ga("floppy-disk","0 0 256 256",'<path d="M219.31,72,184,36.69A15.86,15.86,0,0,0,172.69,32H48A16,16,0,0,0,32,48V208a16,16,0,0,0,16,16H208a16,16,0,0,0,16-16V83.31A15.86,15.86,0,0,0,219.31,72ZM168,208H88V152h80Zm40,0H184V152a16,16,0,0,0-16-16H88a16,16,0,0,0-16,16v56H48V48H172.69L208,83.31ZM160,72a8,8,0,0,1-8,8H96a8,8,0,0,1,0-16h56A8,8,0,0,1,160,72Z"/>'),sN=ga("floppy-disk","0 0 256 256",'<path d="M222.14,69.17,186.83,33.86A19.86,19.86,0,0,0,172.69,28H48A20,20,0,0,0,28,48V208a20,20,0,0,0,20,20H208a20,20,0,0,0,20-20V83.31A19.86,19.86,0,0,0,222.14,69.17ZM164,204H92V160h72Zm40,0H188V156a20,20,0,0,0-20-20H88a20,20,0,0,0-20,20v48H52V52H171l33,33ZM164,84a12,12,0,0,1-12,12H96a12,12,0,0,1,0-24h56A12,12,0,0,1,164,84Z"/>'),nN=ga("floppy-disk","0 0 256 256",'<path d="M219.31,72,184,36.69A15.86,15.86,0,0,0,172.69,32H48A16,16,0,0,0,32,48V208a16,16,0,0,0,16,16H208a16,16,0,0,0,16-16V83.31A15.86,15.86,0,0,0,219.31,72ZM208,208H184V152a16,16,0,0,0-16-16H88a16,16,0,0,0-16,16v56H48V48H172.69L208,83.31ZM160,72a8,8,0,0,1-8,8H96a8,8,0,0,1,0-16h56A8,8,0,0,1,160,72Z"/>'),aN=ga("floppy-disk","0 0 256 256",'<path d="M216,83.31V208a8,8,0,0,1-8,8H176V152a8,8,0,0,0-8-8H88a8,8,0,0,0-8,8v64H48a8,8,0,0,1-8-8V48a8,8,0,0,1,8-8H172.69a8,8,0,0,1,5.65,2.34l35.32,35.32A8,8,0,0,1,216,83.31Z" opacity="0.2"/><path d="M219.31,72,184,36.69A15.86,15.86,0,0,0,172.69,32H48A16,16,0,0,0,32,48V208a16,16,0,0,0,16,16H208a16,16,0,0,0,16-16V83.31A15.86,15.86,0,0,0,219.31,72ZM168,208H88V152h80Zm40,0H184V152a16,16,0,0,0-16-16H88a16,16,0,0,0-16,16v56H48V48H172.69L208,83.31ZM160,72a8,8,0,0,1-8,8H96a8,8,0,0,1,0-16h56A8,8,0,0,1,160,72Z"/>'),oN="floppy-disk",z0=Object.freeze(Object.defineProperty({__proto__:null,bold:sN,default:K6,duotone:aN,fill:nN,glyphName:oN,light:rN,regular:K6,thin:iN},Symbol.toStringTag,{value:"Module"})),va=(e,t,i)=>{const r=s=>Me("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:t,fill:"currentColor",...s,innerHTML:i});return r.displayName="NbGlyph",r.glyphName=e,r},lN=va("arrows-clockwise","0 0 256 256",'<path d="M220,48V96a4,4,0,0,1-4,4H168a4,4,0,0,1,0-8h38.34L184.89,70.54A84,84,0,0,0,66.8,69.85a4,4,0,1,1-5.6-5.72,92,92,0,0,1,129.34.76L212,86.34V48a4,4,0,0,1,8,0ZM189.2,186.15a83.44,83.44,0,0,1-58.68,23.91h-.47a83.52,83.52,0,0,1-58.94-24.6L49.66,164H88a4,4,0,0,0,0-8H40a4,4,0,0,0-4,4v48a4,4,0,0,0,8,0V169.66l21.46,21.45A91.43,91.43,0,0,0,130,218.06h.51a91.45,91.45,0,0,0,64.28-26.19,4,4,0,1,0-5.6-5.72Z"/>'),cN=va("arrows-clockwise","0 0 256 256",'<path d="M222,48V96a6,6,0,0,1-6,6H168a6,6,0,0,1,0-12h33.52L183.47,72a81.51,81.51,0,0,0-57.53-24h-.46A81.5,81.5,0,0,0,68.19,71.28a6,6,0,1,1-8.38-8.58,93.38,93.38,0,0,1,65.67-26.76H126a93.45,93.45,0,0,1,66,27.53l18,18V48a6,6,0,0,1,12,0ZM187.81,184.72a81.5,81.5,0,0,1-57.29,23.34h-.46a81.51,81.51,0,0,1-57.53-24L54.48,166H88a6,6,0,0,0,0-12H40a6,6,0,0,0-6,6v48a6,6,0,0,0,12,0V174.48l18,18.05a93.45,93.45,0,0,0,66,27.53h.52a93.38,93.38,0,0,0,65.67-26.76,6,6,0,1,0-8.38-8.58Z"/>'),q6=va("arrows-clockwise","0 0 256 256",'<path d="M224,48V96a8,8,0,0,1-8,8H168a8,8,0,0,1,0-16h28.69L182.06,73.37a79.56,79.56,0,0,0-56.13-23.43h-.45A79.52,79.52,0,0,0,69.59,72.71,8,8,0,0,1,58.41,61.27a96,96,0,0,1,135,.79L208,76.69V48a8,8,0,0,1,16,0ZM186.41,183.29a80,80,0,0,1-112.47-.66L59.31,168H88a8,8,0,0,0,0-16H40a8,8,0,0,0-8,8v48a8,8,0,0,0,16,0V179.31l14.63,14.63A95.43,95.43,0,0,0,130,222.06h.53a95.36,95.36,0,0,0,67.07-27.33,8,8,0,0,0-11.18-11.44Z"/>'),uN=va("arrows-clockwise","0 0 256 256",'<path d="M228,48V96a12,12,0,0,1-12,12H168a12,12,0,0,1,0-24h19l-7.8-7.8a75.55,75.55,0,0,0-53.32-22.26h-.43A75.49,75.49,0,0,0,72.39,75.57,12,12,0,1,1,55.61,58.41a99.38,99.38,0,0,1,69.87-28.47H126A99.42,99.42,0,0,1,196.2,59.23L204,67V48a12,12,0,0,1,24,0ZM183.61,180.43a75.49,75.49,0,0,1-53.09,21.63h-.43A75.55,75.55,0,0,1,76.77,179.8L69,172H88a12,12,0,0,0,0-24H40a12,12,0,0,0-12,12v48a12,12,0,0,0,24,0V189l7.8,7.8A99.42,99.42,0,0,0,130,226.06h.56a99.38,99.38,0,0,0,69.87-28.47,12,12,0,0,0-16.78-17.16Z"/>'),hN=va("arrows-clockwise","0 0 256 256",'<path d="M224,48V96a8,8,0,0,1-8,8H168a8,8,0,0,1-5.66-13.66L180.65,72a79.48,79.48,0,0,0-54.72-22.09h-.45A79.52,79.52,0,0,0,69.59,72.71,8,8,0,0,1,58.41,61.27,96,96,0,0,1,192,60.7l18.36-18.36A8,8,0,0,1,224,48ZM186.41,183.29A80,80,0,0,1,75.35,184l18.31-18.31A8,8,0,0,0,88,152H40a8,8,0,0,0-8,8v48a8,8,0,0,0,13.66,5.66L64,195.3a95.42,95.42,0,0,0,66,26.76h.53a95.36,95.36,0,0,0,67.07-27.33,8,8,0,0,0-11.18-11.44Z"/>'),dN=va("arrows-clockwise","0 0 256 256",'<path d="M216,128a88,88,0,1,1-88-88A88,88,0,0,1,216,128Z" opacity="0.2"/><path d="M224,48V96a8,8,0,0,1-8,8H168a8,8,0,0,1,0-16h28.69L182.06,73.37a79.56,79.56,0,0,0-56.13-23.43h-.45A79.52,79.52,0,0,0,69.59,72.71,8,8,0,0,1,58.41,61.27a96,96,0,0,1,135,.79L208,76.69V48a8,8,0,0,1,16,0ZM186.41,183.29a80,80,0,0,1-112.47-.66L59.31,168H88a8,8,0,0,0,0-16H40a8,8,0,0,0-8,8v48a8,8,0,0,0,16,0V179.31l14.63,14.63A95.43,95.43,0,0,0,130,222.06h.53a95.36,95.36,0,0,0,67.07-27.33,8,8,0,0,0-11.18-11.44Z"/>'),fN="arrows-clockwise",Qs=Object.freeze(Object.defineProperty({__proto__:null,bold:uN,default:q6,duotone:dN,fill:hN,glyphName:fN,light:cN,regular:q6,thin:lN},Symbol.toStringTag,{value:"Module"})),ba=(e,t,i)=>{const r=s=>Me("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:t,fill:"currentColor",...s,innerHTML:i});return r.displayName="NbGlyph",r.glyphName=e,r},pN=ba("download","0 0 256 256",'<path d="M236,136v64a12,12,0,0,1-12,12H32a12,12,0,0,1-12-12V136a12,12,0,0,1,12-12H72a4,4,0,0,1,0,8H32a4,4,0,0,0-4,4v64a4,4,0,0,0,4,4H224a4,4,0,0,0,4-4V136a4,4,0,0,0-4-4H184a4,4,0,0,1,0-8h40A12,12,0,0,1,236,136Zm-110.83-5.17a4,4,0,0,0,5.66,0l48-48a4,4,0,1,0-5.66-5.66L132,118.34V24a4,4,0,0,0-8,0v94.34L82.83,77.17a4,4,0,0,0-5.66,5.66ZM196,168a8,8,0,1,0-8,8A8,8,0,0,0,196,168Z"/>'),_N=ba("download","0 0 256 256",'<path d="M238,136v64a14,14,0,0,1-14,14H32a14,14,0,0,1-14-14V136a14,14,0,0,1,14-14H72a6,6,0,0,1,0,12H32a2,2,0,0,0-2,2v64a2,2,0,0,0,2,2H224a2,2,0,0,0,2-2V136a2,2,0,0,0-2-2H184a6,6,0,0,1,0-12h40A14,14,0,0,1,238,136Zm-114.24-3.76a6,6,0,0,0,8.48,0l48-48a6,6,0,0,0-8.48-8.48L134,113.51V24a6,6,0,0,0-12,0v89.51L84.24,75.76a6,6,0,0,0-8.48,8.48ZM198,168a10,10,0,1,0-10,10A10,10,0,0,0,198,168Z"/>'),G6=ba("download","0 0 256 256",'<path d="M240,136v64a16,16,0,0,1-16,16H32a16,16,0,0,1-16-16V136a16,16,0,0,1,16-16H72a8,8,0,0,1,0,16H32v64H224V136H184a8,8,0,0,1,0-16h40A16,16,0,0,1,240,136Zm-117.66-2.34a8,8,0,0,0,11.32,0l48-48a8,8,0,0,0-11.32-11.32L136,108.69V24a8,8,0,0,0-16,0v84.69L85.66,74.34A8,8,0,0,0,74.34,85.66ZM200,168a12,12,0,1,0-12,12A12,12,0,0,0,200,168Z"/>'),mN=ba("download","0 0 256 256",'<path d="M71.51,88.49a12,12,0,0,1,17-17L116,99V24a12,12,0,0,1,24,0V99l27.51-27.52a12,12,0,0,1,17,17l-48,48a12,12,0,0,1-17,0ZM224,116H188a12,12,0,0,0,0,24h32v56H36V140H68a12,12,0,0,0,0-24H32a20,20,0,0,0-20,20v64a20,20,0,0,0,20,20H224a20,20,0,0,0,20-20V136A20,20,0,0,0,224,116Zm-20,52a16,16,0,1,0-16,16A16,16,0,0,0,204,168Z"/>'),gN=ba("download","0 0 256 256",'<path d="M74.34,85.66A8,8,0,0,1,85.66,74.34L120,108.69V24a8,8,0,0,1,16,0v84.69l34.34-34.35a8,8,0,0,1,11.32,11.32l-48,48a8,8,0,0,1-11.32,0ZM240,136v64a16,16,0,0,1-16,16H32a16,16,0,0,1-16-16V136a16,16,0,0,1,16-16H84.4a4,4,0,0,1,2.83,1.17L111,145A24,24,0,0,0,145,145l23.8-23.8A4,4,0,0,1,171.6,120H224A16,16,0,0,1,240,136Zm-40,32a12,12,0,1,0-12,12A12,12,0,0,0,200,168Z"/>'),vN=ba("download","0 0 256 256",'<path d="M232,136v64a8,8,0,0,1-8,8H32a8,8,0,0,1-8-8V136a8,8,0,0,1,8-8H224A8,8,0,0,1,232,136Z" opacity="0.2"/><path d="M240,136v64a16,16,0,0,1-16,16H32a16,16,0,0,1-16-16V136a16,16,0,0,1,16-16H72a8,8,0,0,1,0,16H32v64H224V136H184a8,8,0,0,1,0-16h40A16,16,0,0,1,240,136Zm-117.66-2.34a8,8,0,0,0,11.32,0l48-48a8,8,0,0,0-11.32-11.32L136,108.69V24a8,8,0,0,0-16,0v84.69L85.66,74.34A8,8,0,0,0,74.34,85.66ZM200,168a12,12,0,1,0-12,12A12,12,0,0,0,200,168Z"/>'),bN="download",yN=Object.freeze(Object.defineProperty({__proto__:null,bold:mN,default:G6,duotone:vN,fill:gN,glyphName:bN,light:_N,regular:G6,thin:pN},Symbol.toStringTag,{value:"Module"})),ya=(e,t,i)=>{const r=s=>Me("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:t,fill:"currentColor",...s,innerHTML:i});return r.displayName="NbGlyph",r.glyphName=e,r},wN=ya("upload","0 0 256 256",'<path d="M236,136v64a12,12,0,0,1-12,12H32a12,12,0,0,1-12-12V136a12,12,0,0,1,12-12H80a4,4,0,0,1,0,8H32a4,4,0,0,0-4,4v64a4,4,0,0,0,4,4H224a4,4,0,0,0,4-4V136a4,4,0,0,0-4-4H176a4,4,0,0,1,0-8h48A12,12,0,0,1,236,136ZM82.83,74.83,124,33.66V128a4,4,0,0,0,8,0V33.66l41.17,41.17a4,4,0,1,0,5.66-5.66l-48-48a4,4,0,0,0-5.66,0l-48,48a4,4,0,0,0,5.66,5.66ZM196,168a8,8,0,1,0-8,8A8,8,0,0,0,196,168Z"/>'),SN=ya("upload","0 0 256 256",'<path d="M238,136v64a14,14,0,0,1-14,14H32a14,14,0,0,1-14-14V136a14,14,0,0,1,14-14H80a6,6,0,0,1,0,12H32a2,2,0,0,0-2,2v64a2,2,0,0,0,2,2H224a2,2,0,0,0,2-2V136a2,2,0,0,0-2-2H176a6,6,0,0,1,0-12h48A14,14,0,0,1,238,136ZM84.24,76.24,122,38.49V128a6,6,0,0,0,12,0V38.49l37.76,37.75a6,6,0,0,0,8.48-8.48l-48-48a6,6,0,0,0-8.48,0l-48,48a6,6,0,0,0,8.48,8.48ZM198,168a10,10,0,1,0-10,10A10,10,0,0,0,198,168Z"/>'),Y6=ya("upload","0 0 256 256",'<path d="M240,136v64a16,16,0,0,1-16,16H32a16,16,0,0,1-16-16V136a16,16,0,0,1,16-16H80a8,8,0,0,1,0,16H32v64H224V136H176a8,8,0,0,1,0-16h48A16,16,0,0,1,240,136ZM85.66,77.66,120,43.31V128a8,8,0,0,0,16,0V43.31l34.34,34.35a8,8,0,0,0,11.32-11.32l-48-48a8,8,0,0,0-11.32,0l-48,48A8,8,0,0,0,85.66,77.66ZM200,168a12,12,0,1,0-12,12A12,12,0,0,0,200,168Z"/>'),CN=ya("upload","0 0 256 256",'<path d="M188,184a16,16,0,1,1,16-16A16,16,0,0,1,188,184Zm36-68H180a12,12,0,0,0,0,24h40v56H36V140H76a12,12,0,0,0,0-24H32a20,20,0,0,0-20,20v64a20,20,0,0,0,20,20H224a20,20,0,0,0,20-20V136A20,20,0,0,0,224,116ZM88.49,80.49,116,53v75a12,12,0,0,0,24,0V53l27.51,27.52a12,12,0,1,0,17-17l-48-48a12,12,0,0,0-17,0l-48,48a12,12,0,1,0,17,17Z"/>'),kN=ya("upload","0 0 256 256",'<path d="M74.34,77.66a8,8,0,0,1,0-11.32l48-48a8,8,0,0,1,11.32,0l48,48a8,8,0,0,1-11.32,11.32L136,43.31V128a8,8,0,0,1-16,0V43.31L85.66,77.66A8,8,0,0,1,74.34,77.66ZM240,136v64a16,16,0,0,1-16,16H32a16,16,0,0,1-16-16V136a16,16,0,0,1,16-16h68a4,4,0,0,1,4,4v3.46c0,13.45,11,24.79,24.46,24.54A24,24,0,0,0,152,128v-4a4,4,0,0,1,4-4h68A16,16,0,0,1,240,136Zm-40,32a12,12,0,1,0-12,12A12,12,0,0,0,200,168Z"/>'),AN=ya("upload","0 0 256 256",'<path d="M232,136v64a8,8,0,0,1-8,8H32a8,8,0,0,1-8-8V136a8,8,0,0,1,8-8H224A8,8,0,0,1,232,136Z" opacity="0.2"/><path d="M240,136v64a16,16,0,0,1-16,16H32a16,16,0,0,1-16-16V136a16,16,0,0,1,16-16H80a8,8,0,0,1,0,16H32v64H224V136H176a8,8,0,0,1,0-16h48A16,16,0,0,1,240,136ZM85.66,77.66,120,43.31V128a8,8,0,0,0,16,0V43.31l34.34,34.35a8,8,0,0,0,11.32-11.32l-48-48a8,8,0,0,0-11.32,0l-48,48A8,8,0,0,0,85.66,77.66ZM200,168a12,12,0,1,0-12,12A12,12,0,0,0,200,168Z"/>'),MN="upload",LN=Object.freeze(Object.defineProperty({__proto__:null,bold:CN,default:Y6,duotone:AN,fill:kN,glyphName:MN,light:SN,regular:Y6,thin:wN},Symbol.toStringTag,{value:"Module"}));var wa={},EN=function(){return typeof Promise=="function"&&Promise.prototype&&Promise.prototype.then},kg={},Di={};let xd;const $N=[0,26,44,70,100,134,172,196,242,292,346,404,466,532,581,655,733,815,901,991,1085,1156,1258,1364,1474,1588,1706,1828,1921,2051,2185,2323,2465,2611,2761,2876,3034,3196,3362,3532,3706];Di.getSymbolSize=function(t){if(!t)throw new Error('"version" cannot be null or undefined');if(t<1||t>40)throw new Error('"version" should be in range from 1 to 40');return t*4+17};Di.getSymbolTotalCodewords=function(t){return $N[t]};Di.getBCHDigit=function(e){let t=0;for(;e!==0;)t++,e>>>=1;return t};Di.setToSJISFunction=function(t){if(typeof t!="function")throw new Error('"toSJISFunc" is not a valid function.');xd=t};Di.isKanjiModeEnabled=function(){return typeof xd<"u"};Di.toSJIS=function(t){return xd(t)};var $c={};(function(e){e.L={bit:1},e.M={bit:0},e.Q={bit:3},e.H={bit:2};function t(i){if(typeof i!="string")throw new Error("Param is not a string");switch(i.toLowerCase()){case"l":case"low":return e.L;case"m":case"medium":return e.M;case"q":case"quartile":return e.Q;case"h":case"high":return e.H;default:throw new Error("Unknown EC Level: "+i)}}e.isValid=function(r){return r&&typeof r.bit<"u"&&r.bit>=0&&r.bit<4},e.from=function(r,s){if(e.isValid(r))return r;try{return t(r)}catch{return s}}})($c);function Ag(){this.buffer=[],this.length=0}Ag.prototype={get:function(e){const t=Math.floor(e/8);return(this.buffer[t]>>>7-e%8&1)===1},put:function(e,t){for(let i=0;i<t;i++)this.putBit((e>>>t-i-1&1)===1)},getLengthInBits:function(){return this.length},putBit:function(e){const t=Math.floor(this.length/8);this.buffer.length<=t&&this.buffer.push(0),e&&(this.buffer[t]|=128>>>this.length%8),this.length++}};var xN=Ag;function Al(e){if(!e||e<1)throw new Error("BitMatrix size must be defined and greater than 0");this.size=e,this.data=new Uint8Array(e*e),this.reservedBit=new Uint8Array(e*e)}Al.prototype.set=function(e,t,i,r){const s=e*this.size+t;this.data[s]=i,r&&(this.reservedBit[s]=!0)};Al.prototype.get=function(e,t){return this.data[e*this.size+t]};Al.prototype.xor=function(e,t,i){this.data[e*this.size+t]^=i};Al.prototype.isReserved=function(e,t){return this.reservedBit[e*this.size+t]};var TN=Al,Mg={};(function(e){const t=Di.getSymbolSize;e.getRowColCoords=function(r){if(r===1)return[];const s=Math.floor(r/7)+2,n=t(r),a=n===145?26:Math.ceil((n-13)/(2*s-2))*2,o=[n-7];for(let l=1;l<s-1;l++)o[l]=o[l-1]-a;return o.push(6),o.reverse()},e.getPositions=function(r){const s=[],n=e.getRowColCoords(r),a=n.length;for(let o=0;o<a;o++)for(let l=0;l<a;l++)o===0&&l===0||o===0&&l===a-1||o===a-1&&l===0||s.push([n[o],n[l]]);return s}})(Mg);var Lg={};const NN=Di.getSymbolSize,X6=7;Lg.getPositions=function(t){const i=NN(t);return[[0,0],[i-X6,0],[0,i-X6]]};var Eg={};(function(e){e.Patterns={PATTERN000:0,PATTERN001:1,PATTERN010:2,PATTERN011:3,PATTERN100:4,PATTERN101:5,PATTERN110:6,PATTERN111:7};const t={N1:3,N2:3,N3:40,N4:10};e.isValid=function(s){return s!=null&&s!==""&&!isNaN(s)&&s>=0&&s<=7},e.from=function(s){return e.isValid(s)?parseInt(s,10):void 0},e.getPenaltyN1=function(s){const n=s.size;let a=0,o=0,l=0,c=null,u=null;for(let h=0;h<n;h++){o=l=0,c=u=null;for(let d=0;d<n;d++){let f=s.get(h,d);f===c?o++:(o>=5&&(a+=t.N1+(o-5)),c=f,o=1),f=s.get(d,h),f===u?l++:(l>=5&&(a+=t.N1+(l-5)),u=f,l=1)}o>=5&&(a+=t.N1+(o-5)),l>=5&&(a+=t.N1+(l-5))}return a},e.getPenaltyN2=function(s){const n=s.size;let a=0;for(let o=0;o<n-1;o++)for(let l=0;l<n-1;l++){const c=s.get(o,l)+s.get(o,l+1)+s.get(o+1,l)+s.get(o+1,l+1);(c===4||c===0)&&a++}return a*t.N2},e.getPenaltyN3=function(s){const n=s.size;let a=0,o=0,l=0;for(let c=0;c<n;c++){o=l=0;for(let u=0;u<n;u++)o=o<<1&2047|s.get(c,u),u>=10&&(o===1488||o===93)&&a++,l=l<<1&2047|s.get(u,c),u>=10&&(l===1488||l===93)&&a++}return a*t.N3},e.getPenaltyN4=function(s){let n=0;const a=s.data.length;for(let l=0;l<a;l++)n+=s.data[l];return Math.abs(Math.ceil(n*100/a/5)-10)*t.N4};function i(r,s,n){switch(r){case e.Patterns.PATTERN000:return(s+n)%2===0;case e.Patterns.PATTERN001:return s%2===0;case e.Patterns.PATTERN010:return n%3===0;case e.Patterns.PATTERN011:return(s+n)%3===0;case e.Patterns.PATTERN100:return(Math.floor(s/2)+Math.floor(n/3))%2===0;case e.Patterns.PATTERN101:return s*n%2+s*n%3===0;case e.Patterns.PATTERN110:return(s*n%2+s*n%3)%2===0;case e.Patterns.PATTERN111:return(s*n%3+(s+n)%2)%2===0;default:throw new Error("bad maskPattern:"+r)}}e.applyMask=function(s,n){const a=n.size;for(let o=0;o<a;o++)for(let l=0;l<a;l++)n.isReserved(l,o)||n.xor(l,o,i(s,l,o))},e.getBestMask=function(s,n){const a=Object.keys(e.Patterns).length;let o=0,l=1/0;for(let c=0;c<a;c++){n(c),e.applyMask(c,s);const u=e.getPenaltyN1(s)+e.getPenaltyN2(s)+e.getPenaltyN3(s)+e.getPenaltyN4(s);e.applyMask(c,s),u<l&&(l=u,o=c)}return o}})(Eg);var xc={};const ds=$c,Kl=[1,1,1,1,1,1,1,1,1,1,2,2,1,2,2,4,1,2,4,4,2,4,4,4,2,4,6,5,2,4,6,6,2,5,8,8,4,5,8,8,4,5,8,11,4,8,10,11,4,9,12,16,4,9,16,16,6,10,12,18,6,10,17,16,6,11,16,19,6,13,18,21,7,14,21,25,8,16,20,25,8,17,23,25,9,17,23,34,9,18,25,30,10,20,27,32,12,21,29,35,12,23,34,37,12,25,34,40,13,26,35,42,14,28,38,45,15,29,40,48,16,31,43,51,17,33,45,54,18,35,48,57,19,37,51,60,19,38,53,63,20,40,56,66,21,43,59,70,22,45,62,74,24,47,65,77,25,49,68,81],ql=[7,10,13,17,10,16,22,28,15,26,36,44,20,36,52,64,26,48,72,88,36,64,96,112,40,72,108,130,48,88,132,156,60,110,160,192,72,130,192,224,80,150,224,264,96,176,260,308,104,198,288,352,120,216,320,384,132,240,360,432,144,280,408,480,168,308,448,532,180,338,504,588,196,364,546,650,224,416,600,700,224,442,644,750,252,476,690,816,270,504,750,900,300,560,810,960,312,588,870,1050,336,644,952,1110,360,700,1020,1200,390,728,1050,1260,420,784,1140,1350,450,812,1200,1440,480,868,1290,1530,510,924,1350,1620,540,980,1440,1710,570,1036,1530,1800,570,1064,1590,1890,600,1120,1680,1980,630,1204,1770,2100,660,1260,1860,2220,720,1316,1950,2310,750,1372,2040,2430];xc.getBlocksCount=function(t,i){switch(i){case ds.L:return Kl[(t-1)*4+0];case ds.M:return Kl[(t-1)*4+1];case ds.Q:return Kl[(t-1)*4+2];case ds.H:return Kl[(t-1)*4+3];default:return}};xc.getTotalCodewordsCount=function(t,i){switch(i){case ds.L:return ql[(t-1)*4+0];case ds.M:return ql[(t-1)*4+1];case ds.Q:return ql[(t-1)*4+2];case ds.H:return ql[(t-1)*4+3];default:return}};var $g={},Tc={};const Fo=new Uint8Array(512),U0=new Uint8Array(256);(function(){let t=1;for(let i=0;i<255;i++)Fo[i]=t,U0[t]=i,t<<=1,t&256&&(t^=285);for(let i=255;i<512;i++)Fo[i]=Fo[i-255]})();Tc.log=function(t){if(t<1)throw new Error("log("+t+")");return U0[t]};Tc.exp=function(t){return Fo[t]};Tc.mul=function(t,i){return t===0||i===0?0:Fo[U0[t]+U0[i]]};(function(e){const t=Tc;e.mul=function(r,s){const n=new Uint8Array(r.length+s.length-1);for(let a=0;a<r.length;a++)for(let o=0;o<s.length;o++)n[a+o]^=t.mul(r[a],s[o]);return n},e.mod=function(r,s){let n=new Uint8Array(r);for(;n.length-s.length>=0;){const a=n[0];for(let l=0;l<s.length;l++)n[l]^=t.mul(s[l],a);let o=0;for(;o<n.length&&n[o]===0;)o++;n=n.slice(o)}return n},e.generateECPolynomial=function(r){let s=new Uint8Array([1]);for(let n=0;n<r;n++)s=e.mul(s,new Uint8Array([1,t.exp(n)]));return s}})($g);const xg=$g;function Td(e){this.genPoly=void 0,this.degree=e,this.degree&&this.initialize(this.degree)}Td.prototype.initialize=function(t){this.degree=t,this.genPoly=xg.generateECPolynomial(this.degree)};Td.prototype.encode=function(t){if(!this.genPoly)throw new Error("Encoder not initialized");const i=new Uint8Array(t.length+this.degree);i.set(t);const r=xg.mod(i,this.genPoly),s=this.degree-r.length;if(s>0){const n=new Uint8Array(this.degree);return n.set(r,s),n}return r};var HN=Td,Tg={},Ts={},Nd={};Nd.isValid=function(t){return!isNaN(t)&&t>=1&&t<=40};var Lr={};const Ng="[0-9]+",PN="[A-Z $%*+\\-./:]+";let hl="(?:[u3000-u303F]|[u3040-u309F]|[u30A0-u30FF]|[uFF00-uFFEF]|[u4E00-u9FAF]|[u2605-u2606]|[u2190-u2195]|u203B|[u2010u2015u2018u2019u2025u2026u201Cu201Du2225u2260]|[u0391-u0451]|[u00A7u00A8u00B1u00B4u00D7u00F7])+";hl=hl.replace(/u/g,"\\u");const ON="(?:(?![A-Z0-9 $%*+\\-./:]|"+hl+`)(?:.|[\r
|
|
51
|
-
]))+`;Lr.KANJI=new RegExp(hl,"g");Lr.BYTE_KANJI=new RegExp("[^A-Z0-9 $%*+\\-./:]+","g");Lr.BYTE=new RegExp(ON,"g");Lr.NUMERIC=new RegExp(Ng,"g");Lr.ALPHANUMERIC=new RegExp(PN,"g");const IN=new RegExp("^"+hl+"$"),RN=new RegExp("^"+Ng+"$"),DN=new RegExp("^[A-Z0-9 $%*+\\-./:]+$");Lr.testKanji=function(t){return IN.test(t)};Lr.testNumeric=function(t){return RN.test(t)};Lr.testAlphanumeric=function(t){return DN.test(t)};(function(e){const t=Nd,i=Lr;e.NUMERIC={id:"Numeric",bit:1,ccBits:[10,12,14]},e.ALPHANUMERIC={id:"Alphanumeric",bit:2,ccBits:[9,11,13]},e.BYTE={id:"Byte",bit:4,ccBits:[8,16,16]},e.KANJI={id:"Kanji",bit:8,ccBits:[8,10,12]},e.MIXED={bit:-1},e.getCharCountIndicator=function(n,a){if(!n.ccBits)throw new Error("Invalid mode: "+n);if(!t.isValid(a))throw new Error("Invalid version: "+a);return a>=1&&a<10?n.ccBits[0]:a<27?n.ccBits[1]:n.ccBits[2]},e.getBestModeForData=function(n){return i.testNumeric(n)?e.NUMERIC:i.testAlphanumeric(n)?e.ALPHANUMERIC:i.testKanji(n)?e.KANJI:e.BYTE},e.toString=function(n){if(n&&n.id)return n.id;throw new Error("Invalid mode")},e.isValid=function(n){return n&&n.bit&&n.ccBits};function r(s){if(typeof s!="string")throw new Error("Param is not a string");switch(s.toLowerCase()){case"numeric":return e.NUMERIC;case"alphanumeric":return e.ALPHANUMERIC;case"kanji":return e.KANJI;case"byte":return e.BYTE;default:throw new Error("Unknown mode: "+s)}}e.from=function(n,a){if(e.isValid(n))return n;try{return r(n)}catch{return a}}})(Ts);(function(e){const t=Di,i=xc,r=$c,s=Ts,n=Nd,a=7973,o=t.getBCHDigit(a);function l(d,f,m){for(let _=1;_<=40;_++)if(f<=e.getCapacity(_,m,d))return _}function c(d,f){return s.getCharCountIndicator(d,f)+4}function u(d,f){let m=0;return d.forEach(function(_){const y=c(_.mode,f);m+=y+_.getBitsLength()}),m}function h(d,f){for(let m=1;m<=40;m++)if(u(d,m)<=e.getCapacity(m,f,s.MIXED))return m}e.from=function(f,m){return n.isValid(f)?parseInt(f,10):m},e.getCapacity=function(f,m,_){if(!n.isValid(f))throw new Error("Invalid QR Code version");typeof _>"u"&&(_=s.BYTE);const y=t.getSymbolTotalCodewords(f),p=i.getTotalCodewordsCount(f,m),C=(y-p)*8;if(_===s.MIXED)return C;const w=C-c(_,f);switch(_){case s.NUMERIC:return Math.floor(w/10*3);case s.ALPHANUMERIC:return Math.floor(w/11*2);case s.KANJI:return Math.floor(w/13);case s.BYTE:default:return Math.floor(w/8)}},e.getBestVersionForData=function(f,m){let _;const y=r.from(m,r.M);if(Array.isArray(f)){if(f.length>1)return h(f,y);if(f.length===0)return 1;_=f[0]}else _=f;return l(_.mode,_.getLength(),y)},e.getEncodedBits=function(f){if(!n.isValid(f)||f<7)throw new Error("Invalid QR Code version");let m=f<<12;for(;t.getBCHDigit(m)-o>=0;)m^=a<<t.getBCHDigit(m)-o;return f<<12|m}})(Tg);var Hg={};const Bu=Di,Pg=1335,VN=21522,J6=Bu.getBCHDigit(Pg);Hg.getEncodedBits=function(t,i){const r=t.bit<<3|i;let s=r<<10;for(;Bu.getBCHDigit(s)-J6>=0;)s^=Pg<<Bu.getBCHDigit(s)-J6;return(r<<10|s)^VN};var Og={};const BN=Ts;function zn(e){this.mode=BN.NUMERIC,this.data=e.toString()}zn.getBitsLength=function(t){return 10*Math.floor(t/3)+(t%3?t%3*3+1:0)};zn.prototype.getLength=function(){return this.data.length};zn.prototype.getBitsLength=function(){return zn.getBitsLength(this.data.length)};zn.prototype.write=function(t){let i,r,s;for(i=0;i+3<=this.data.length;i+=3)r=this.data.substr(i,3),s=parseInt(r,10),t.put(s,10);const n=this.data.length-i;n>0&&(r=this.data.substr(i),s=parseInt(r,10),t.put(s,n*3+1))};var ZN=zn;const FN=Ts,m1=["0","1","2","3","4","5","6","7","8","9","A","B","C","D","E","F","G","H","I","J","K","L","M","N","O","P","Q","R","S","T","U","V","W","X","Y","Z"," ","$","%","*","+","-",".","/",":"];function Un(e){this.mode=FN.ALPHANUMERIC,this.data=e}Un.getBitsLength=function(t){return 11*Math.floor(t/2)+6*(t%2)};Un.prototype.getLength=function(){return this.data.length};Un.prototype.getBitsLength=function(){return Un.getBitsLength(this.data.length)};Un.prototype.write=function(t){let i;for(i=0;i+2<=this.data.length;i+=2){let r=m1.indexOf(this.data[i])*45;r+=m1.indexOf(this.data[i+1]),t.put(r,11)}this.data.length%2&&t.put(m1.indexOf(this.data[i]),6)};var zN=Un;const UN=Ts;function Wn(e){this.mode=UN.BYTE,typeof e=="string"?this.data=new TextEncoder().encode(e):this.data=new Uint8Array(e)}Wn.getBitsLength=function(t){return t*8};Wn.prototype.getLength=function(){return this.data.length};Wn.prototype.getBitsLength=function(){return Wn.getBitsLength(this.data.length)};Wn.prototype.write=function(e){for(let t=0,i=this.data.length;t<i;t++)e.put(this.data[t],8)};var WN=Wn;const jN=Ts,KN=Di;function jn(e){this.mode=jN.KANJI,this.data=e}jn.getBitsLength=function(t){return t*13};jn.prototype.getLength=function(){return this.data.length};jn.prototype.getBitsLength=function(){return jn.getBitsLength(this.data.length)};jn.prototype.write=function(e){let t;for(t=0;t<this.data.length;t++){let i=KN.toSJIS(this.data[t]);if(i>=33088&&i<=40956)i-=33088;else if(i>=57408&&i<=60351)i-=49472;else throw new Error("Invalid SJIS character: "+this.data[t]+`
|
|
52
|
-
Make sure your charset is UTF-8`);i=(i>>>8&255)*192+(i&255),e.put(i,13)}};var qN=jn,Ig={exports:{}};(function(e){var t={single_source_shortest_paths:function(i,r,s){var n={},a={};a[r]=0;var o=t.PriorityQueue.make();o.push(r,0);for(var l,c,u,h,d,f,m,_,y;!o.empty();){l=o.pop(),c=l.value,h=l.cost,d=i[c]||{};for(u in d)d.hasOwnProperty(u)&&(f=d[u],m=h+f,_=a[u],y=typeof a[u]>"u",(y||_>m)&&(a[u]=m,o.push(u,m),n[u]=c))}if(typeof s<"u"&&typeof a[s]>"u"){var p=["Could not find a path from ",r," to ",s,"."].join("");throw new Error(p)}return n},extract_shortest_path_from_predecessor_list:function(i,r){for(var s=[],n=r;n;)s.push(n),i[n],n=i[n];return s.reverse(),s},find_path:function(i,r,s){var n=t.single_source_shortest_paths(i,r,s);return t.extract_shortest_path_from_predecessor_list(n,s)},PriorityQueue:{make:function(i){var r=t.PriorityQueue,s={},n;i=i||{};for(n in r)r.hasOwnProperty(n)&&(s[n]=r[n]);return s.queue=[],s.sorter=i.sorter||r.default_sorter,s},default_sorter:function(i,r){return i.cost-r.cost},push:function(i,r){var s={value:i,cost:r};this.queue.push(s),this.queue.sort(this.sorter)},pop:function(){return this.queue.shift()},empty:function(){return this.queue.length===0}}};e.exports=t})(Ig);var GN=Ig.exports;(function(e){const t=Ts,i=ZN,r=zN,s=WN,n=qN,a=Lr,o=Di,l=GN;function c(p){return unescape(encodeURIComponent(p)).length}function u(p,C,w){const v=[];let k;for(;(k=p.exec(w))!==null;)v.push({data:k[0],index:k.index,mode:C,length:k[0].length});return v}function h(p){const C=u(a.NUMERIC,t.NUMERIC,p),w=u(a.ALPHANUMERIC,t.ALPHANUMERIC,p);let v,k;return o.isKanjiModeEnabled()?(v=u(a.BYTE,t.BYTE,p),k=u(a.KANJI,t.KANJI,p)):(v=u(a.BYTE_KANJI,t.BYTE,p),k=[]),C.concat(w,v,k).sort(function(M,D){return M.index-D.index}).map(function(M){return{data:M.data,mode:M.mode,length:M.length}})}function d(p,C){switch(C){case t.NUMERIC:return i.getBitsLength(p);case t.ALPHANUMERIC:return r.getBitsLength(p);case t.KANJI:return n.getBitsLength(p);case t.BYTE:return s.getBitsLength(p)}}function f(p){return p.reduce(function(C,w){const v=C.length-1>=0?C[C.length-1]:null;return v&&v.mode===w.mode?(C[C.length-1].data+=w.data,C):(C.push(w),C)},[])}function m(p){const C=[];for(let w=0;w<p.length;w++){const v=p[w];switch(v.mode){case t.NUMERIC:C.push([v,{data:v.data,mode:t.ALPHANUMERIC,length:v.length},{data:v.data,mode:t.BYTE,length:v.length}]);break;case t.ALPHANUMERIC:C.push([v,{data:v.data,mode:t.BYTE,length:v.length}]);break;case t.KANJI:C.push([v,{data:v.data,mode:t.BYTE,length:c(v.data)}]);break;case t.BYTE:C.push([{data:v.data,mode:t.BYTE,length:c(v.data)}])}}return C}function _(p,C){const w={},v={start:{}};let k=["start"];for(let $=0;$<p.length;$++){const M=p[$],D=[];for(let H=0;H<M.length;H++){const R=M[H],V=""+$+H;D.push(V),w[V]={node:R,lastCount:0},v[V]={};for(let N=0;N<k.length;N++){const P=k[N];w[P]&&w[P].node.mode===R.mode?(v[P][V]=d(w[P].lastCount+R.length,R.mode)-d(w[P].lastCount,R.mode),w[P].lastCount+=R.length):(w[P]&&(w[P].lastCount=R.length),v[P][V]=d(R.length,R.mode)+4+t.getCharCountIndicator(R.mode,C))}}k=D}for(let $=0;$<k.length;$++)v[k[$]].end=0;return{map:v,table:w}}function y(p,C){let w;const v=t.getBestModeForData(p);if(w=t.from(C,v),w!==t.BYTE&&w.bit<v.bit)throw new Error('"'+p+'" cannot be encoded with mode '+t.toString(w)+`.
|
|
53
|
-
Suggested mode is: `+t.toString(v));switch(w===t.KANJI&&!o.isKanjiModeEnabled()&&(w=t.BYTE),w){case t.NUMERIC:return new i(p);case t.ALPHANUMERIC:return new r(p);case t.KANJI:return new n(p);case t.BYTE:return new s(p)}}e.fromArray=function(C){return C.reduce(function(w,v){return typeof v=="string"?w.push(y(v,null)):v.data&&w.push(y(v.data,v.mode)),w},[])},e.fromString=function(C,w){const v=h(C,o.isKanjiModeEnabled()),k=m(v),$=_(k,w),M=l.find_path($.map,"start","end"),D=[];for(let H=1;H<M.length-1;H++)D.push($.table[M[H]].node);return e.fromArray(f(D))},e.rawSplit=function(C){return e.fromArray(h(C,o.isKanjiModeEnabled()))}})(Og);const Nc=Di,g1=$c,YN=xN,XN=TN,JN=Mg,QN=Lg,Zu=Eg,Fu=xc,eH=HN,W0=Tg,tH=Hg,iH=Ts,v1=Og;function rH(e,t){const i=e.size,r=QN.getPositions(t);for(let s=0;s<r.length;s++){const n=r[s][0],a=r[s][1];for(let o=-1;o<=7;o++)if(!(n+o<=-1||i<=n+o))for(let l=-1;l<=7;l++)a+l<=-1||i<=a+l||(o>=0&&o<=6&&(l===0||l===6)||l>=0&&l<=6&&(o===0||o===6)||o>=2&&o<=4&&l>=2&&l<=4?e.set(n+o,a+l,!0,!0):e.set(n+o,a+l,!1,!0))}}function sH(e){const t=e.size;for(let i=8;i<t-8;i++){const r=i%2===0;e.set(i,6,r,!0),e.set(6,i,r,!0)}}function nH(e,t){const i=JN.getPositions(t);for(let r=0;r<i.length;r++){const s=i[r][0],n=i[r][1];for(let a=-2;a<=2;a++)for(let o=-2;o<=2;o++)a===-2||a===2||o===-2||o===2||a===0&&o===0?e.set(s+a,n+o,!0,!0):e.set(s+a,n+o,!1,!0)}}function aH(e,t){const i=e.size,r=W0.getEncodedBits(t);let s,n,a;for(let o=0;o<18;o++)s=Math.floor(o/3),n=o%3+i-8-3,a=(r>>o&1)===1,e.set(s,n,a,!0),e.set(n,s,a,!0)}function b1(e,t,i){const r=e.size,s=tH.getEncodedBits(t,i);let n,a;for(n=0;n<15;n++)a=(s>>n&1)===1,n<6?e.set(n,8,a,!0):n<8?e.set(n+1,8,a,!0):e.set(r-15+n,8,a,!0),n<8?e.set(8,r-n-1,a,!0):n<9?e.set(8,15-n-1+1,a,!0):e.set(8,15-n-1,a,!0);e.set(r-8,8,1,!0)}function oH(e,t){const i=e.size;let r=-1,s=i-1,n=7,a=0;for(let o=i-1;o>0;o-=2)for(o===6&&o--;;){for(let l=0;l<2;l++)if(!e.isReserved(s,o-l)){let c=!1;a<t.length&&(c=(t[a]>>>n&1)===1),e.set(s,o-l,c),n--,n===-1&&(a++,n=7)}if(s+=r,s<0||i<=s){s-=r,r=-r;break}}}function lH(e,t,i){const r=new YN;i.forEach(function(l){r.put(l.mode.bit,4),r.put(l.getLength(),iH.getCharCountIndicator(l.mode,e)),l.write(r)});const s=Nc.getSymbolTotalCodewords(e),n=Fu.getTotalCodewordsCount(e,t),a=(s-n)*8;for(r.getLengthInBits()+4<=a&&r.put(0,4);r.getLengthInBits()%8!==0;)r.putBit(0);const o=(a-r.getLengthInBits())/8;for(let l=0;l<o;l++)r.put(l%2?17:236,8);return cH(r,e,t)}function cH(e,t,i){const r=Nc.getSymbolTotalCodewords(t),s=Fu.getTotalCodewordsCount(t,i),n=r-s,a=Fu.getBlocksCount(t,i),o=r%a,l=a-o,c=Math.floor(r/a),u=Math.floor(n/a),h=u+1,d=c-u,f=new eH(d);let m=0;const _=new Array(a),y=new Array(a);let p=0;const C=new Uint8Array(e.buffer);for(let M=0;M<a;M++){const D=M<l?u:h;_[M]=C.slice(m,m+D),y[M]=f.encode(_[M]),m+=D,p=Math.max(p,D)}const w=new Uint8Array(r);let v=0,k,$;for(k=0;k<p;k++)for($=0;$<a;$++)k<_[$].length&&(w[v++]=_[$][k]);for(k=0;k<d;k++)for($=0;$<a;$++)w[v++]=y[$][k];return w}function uH(e,t,i,r){let s;if(Array.isArray(e))s=v1.fromArray(e);else if(typeof e=="string"){let c=t;if(!c){const u=v1.rawSplit(e);c=W0.getBestVersionForData(u,i)}s=v1.fromString(e,c||40)}else throw new Error("Invalid data");const n=W0.getBestVersionForData(s,i);if(!n)throw new Error("The amount of data is too big to be stored in a QR Code");if(!t)t=n;else if(t<n)throw new Error(`
|
|
54
|
-
The chosen QR Code version cannot contain this amount of data.
|
|
55
|
-
Minimum version required to store current data is: `+n+`.
|
|
56
|
-
`);const a=lH(t,i,s),o=Nc.getSymbolSize(t),l=new XN(o);return rH(l,t),sH(l),nH(l,t),b1(l,i,0),t>=7&&aH(l,t),oH(l,a),isNaN(r)&&(r=Zu.getBestMask(l,b1.bind(null,l,i))),Zu.applyMask(r,l),b1(l,i,r),{modules:l,version:t,errorCorrectionLevel:i,maskPattern:r,segments:s}}kg.create=function(t,i){if(typeof t>"u"||t==="")throw new Error("No input text");let r=g1.M,s,n;return typeof i<"u"&&(r=g1.from(i.errorCorrectionLevel,g1.M),s=W0.from(i.version),n=Zu.from(i.maskPattern),i.toSJISFunc&&Nc.setToSJISFunction(i.toSJISFunc)),uH(t,s,r,n)};var Rg={},Hd={};(function(e){function t(i){if(typeof i=="number"&&(i=i.toString()),typeof i!="string")throw new Error("Color should be defined as hex string");let r=i.slice().replace("#","").split("");if(r.length<3||r.length===5||r.length>8)throw new Error("Invalid hex color: "+i);(r.length===3||r.length===4)&&(r=Array.prototype.concat.apply([],r.map(function(n){return[n,n]}))),r.length===6&&r.push("F","F");const s=parseInt(r.join(""),16);return{r:s>>24&255,g:s>>16&255,b:s>>8&255,a:s&255,hex:"#"+r.slice(0,6).join("")}}e.getOptions=function(r){r||(r={}),r.color||(r.color={});const s=typeof r.margin>"u"||r.margin===null||r.margin<0?4:r.margin,n=r.width&&r.width>=21?r.width:void 0,a=r.scale||4;return{width:n,scale:n?4:a,margin:s,color:{dark:t(r.color.dark||"#000000ff"),light:t(r.color.light||"#ffffffff")},type:r.type,rendererOpts:r.rendererOpts||{}}},e.getScale=function(r,s){return s.width&&s.width>=r+s.margin*2?s.width/(r+s.margin*2):s.scale},e.getImageWidth=function(r,s){const n=e.getScale(r,s);return Math.floor((r+s.margin*2)*n)},e.qrToImageData=function(r,s,n){const a=s.modules.size,o=s.modules.data,l=e.getScale(a,n),c=Math.floor((a+n.margin*2)*l),u=n.margin*l,h=[n.color.light,n.color.dark];for(let d=0;d<c;d++)for(let f=0;f<c;f++){let m=(d*c+f)*4,_=n.color.light;if(d>=u&&f>=u&&d<c-u&&f<c-u){const y=Math.floor((d-u)/l),p=Math.floor((f-u)/l);_=h[o[y*a+p]?1:0]}r[m++]=_.r,r[m++]=_.g,r[m++]=_.b,r[m]=_.a}}})(Hd);(function(e){const t=Hd;function i(s,n,a){s.clearRect(0,0,n.width,n.height),n.style||(n.style={}),n.height=a,n.width=a,n.style.height=a+"px",n.style.width=a+"px"}function r(){try{return document.createElement("canvas")}catch{throw new Error("You need to specify a canvas element")}}e.render=function(n,a,o){let l=o,c=a;typeof l>"u"&&(!a||!a.getContext)&&(l=a,a=void 0),a||(c=r()),l=t.getOptions(l);const u=t.getImageWidth(n.modules.size,l),h=c.getContext("2d"),d=h.createImageData(u,u);return t.qrToImageData(d.data,n,l),i(h,c,u),h.putImageData(d,0,0),c},e.renderToDataURL=function(n,a,o){let l=o;typeof l>"u"&&(!a||!a.getContext)&&(l=a,a=void 0),l||(l={});const c=e.render(n,a,l),u=l.type||"image/png",h=l.rendererOpts||{};return c.toDataURL(u,h.quality)}})(Rg);var Dg={};const hH=Hd;function Q6(e,t){const i=e.a/255,r=t+'="'+e.hex+'"';return i<1?r+" "+t+'-opacity="'+i.toFixed(2).slice(1)+'"':r}function y1(e,t,i){let r=e+t;return typeof i<"u"&&(r+=" "+i),r}function dH(e,t,i){let r="",s=0,n=!1,a=0;for(let o=0;o<e.length;o++){const l=Math.floor(o%t),c=Math.floor(o/t);!l&&!n&&(n=!0),e[o]?(a++,o>0&&l>0&&e[o-1]||(r+=n?y1("M",l+i,.5+c+i):y1("m",s,0),s=0,n=!1),l+1<t&&e[o+1]||(r+=y1("h",a),a=0)):s++}return r}Dg.render=function(t,i,r){const s=hH.getOptions(i),n=t.modules.size,a=t.modules.data,o=n+s.margin*2,l=s.color.light.a?"<path "+Q6(s.color.light,"fill")+' d="M0 0h'+o+"v"+o+'H0z"/>':"",c="<path "+Q6(s.color.dark,"stroke")+' d="'+dH(a,n,s.margin)+'"/>',u='viewBox="0 0 '+o+" "+o+'"',d='<svg xmlns="http://www.w3.org/2000/svg" '+(s.width?'width="'+s.width+'" height="'+s.width+'" ':"")+u+' shape-rendering="crispEdges">'+l+c+`</svg>
|
|
57
|
-
`;return typeof r=="function"&&r(null,d),d};const fH=EN,zu=kg,Vg=Rg,pH=Dg;function Pd(e,t,i,r,s){const n=[].slice.call(arguments,1),a=n.length,o=typeof n[a-1]=="function";if(!o&&!fH())throw new Error("Callback required as last argument");if(o){if(a<2)throw new Error("Too few arguments provided");a===2?(s=i,i=t,t=r=void 0):a===3&&(t.getContext&&typeof s>"u"?(s=r,r=void 0):(s=r,r=i,i=t,t=void 0))}else{if(a<1)throw new Error("Too few arguments provided");return a===1?(i=t,t=r=void 0):a===2&&!t.getContext&&(r=i,i=t,t=void 0),new Promise(function(l,c){try{const u=zu.create(i,r);l(e(u,t,r))}catch(u){c(u)}})}try{const l=zu.create(i,r);s(null,e(l,t,r))}catch(l){s(l)}}wa.create=zu.create;wa.toCanvas=Pd.bind(null,Vg.render);wa.toDataURL=Pd.bind(null,Vg.renderToDataURL);wa.toString=Pd.bind(null,function(e,t,i){return pH.render(e,i)});function e8(e,t){(t==null||t>e.length)&&(t=e.length);for(var i=0,r=Array(t);i<t;i++)r[i]=e[i];return r}function _H(e){if(Array.isArray(e))return e}function mH(e,t,i){return(t=CH(t))in e?Object.defineProperty(e,t,{value:i,enumerable:!0,configurable:!0,writable:!0}):e[t]=i,e}function gH(e,t){var i=e==null?null:typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(i!=null){var r,s,n,a,o=[],l=!0,c=!1;try{if(n=(i=i.call(e)).next,t!==0)for(;!(l=(r=n.call(i)).done)&&(o.push(r.value),o.length!==t);l=!0);}catch(u){c=!0,s=u}finally{try{if(!l&&i.return!=null&&(a=i.return(),Object(a)!==a))return}finally{if(c)throw s}}return o}}function vH(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
|
|
58
|
-
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function t8(e,t){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(s){return Object.getOwnPropertyDescriptor(e,s).enumerable})),i.push.apply(i,r)}return i}function i8(e){for(var t=1;t<arguments.length;t++){var i=arguments[t]!=null?arguments[t]:{};t%2?t8(Object(i),!0).forEach(function(r){mH(e,r,i[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(i)):t8(Object(i)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(i,r))})}return e}function bH(e,t){if(e==null)return{};var i,r,s=yH(e,t);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);for(r=0;r<n.length;r++)i=n[r],t.indexOf(i)===-1&&{}.propertyIsEnumerable.call(e,i)&&(s[i]=e[i])}return s}function yH(e,t){if(e==null)return{};var i={};for(var r in e)if({}.hasOwnProperty.call(e,r)){if(t.indexOf(r)!==-1)continue;i[r]=e[r]}return i}function wH(e,t){return _H(e)||gH(e,t)||kH(e,t)||vH()}function SH(e,t){if(typeof e!="object"||!e)return e;var i=e[Symbol.toPrimitive];if(i!==void 0){var r=i.call(e,t);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function CH(e){var t=SH(e,"string");return typeof t=="symbol"?t:t+""}function kH(e,t){if(e){if(typeof e=="string")return e8(e,t);var i={}.toString.call(e).slice(8,-1);return i==="Object"&&e.constructor&&(i=e.constructor.name),i==="Map"||i==="Set"?Array.from(e):i==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(i)?e8(e,t):void 0}}function AH(e,t,i){return t in e?Object.defineProperty(e,t,{value:i,enumerable:!0,configurable:!0,writable:!0}):e[t]=i,e}function r8(e,t){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(s){return Object.getOwnPropertyDescriptor(e,s).enumerable})),i.push.apply(i,r)}return i}function s8(e){for(var t=1;t<arguments.length;t++){var i=arguments[t]!=null?arguments[t]:{};t%2?r8(Object(i),!0).forEach(function(r){AH(e,r,i[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(i)):r8(Object(i)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(i,r))})}return e}function MH(){for(var e=arguments.length,t=new Array(e),i=0;i<e;i++)t[i]=arguments[i];return function(r){return t.reduceRight(function(s,n){return n(s)},r)}}function Mo(e){return function t(){for(var i=this,r=arguments.length,s=new Array(r),n=0;n<r;n++)s[n]=arguments[n];return s.length>=e.length?e.apply(this,s):function(){for(var a=arguments.length,o=new Array(a),l=0;l<a;l++)o[l]=arguments[l];return t.apply(i,[].concat(s,o))}}}function j0(e){return{}.toString.call(e).includes("Object")}function LH(e){return!Object.keys(e).length}function dl(e){return typeof e=="function"}function EH(e,t){return Object.prototype.hasOwnProperty.call(e,t)}function $H(e,t){return j0(t)||ms("changeType"),Object.keys(t).some(function(i){return!EH(e,i)})&&ms("changeField"),t}function xH(e){dl(e)||ms("selectorType")}function TH(e){dl(e)||j0(e)||ms("handlerType"),j0(e)&&Object.values(e).some(function(t){return!dl(t)})&&ms("handlersType")}function NH(e){e||ms("initialIsRequired"),j0(e)||ms("initialType"),LH(e)&&ms("initialContent")}function HH(e,t){throw new Error(e[t]||e.default)}var PH={initialIsRequired:"initial state is required",initialType:"initial state should be an object",initialContent:"initial state shouldn't be an empty object",handlerType:"handler should be an object or a function",handlersType:"all handlers should be a functions",selectorType:"selector should be a function",changeType:"provided value of changes should be an object",changeField:'it seams you want to change a field in the state which is not specified in the "initial" state',default:"an unknown error accured in `state-local` package"},ms=Mo(HH)(PH),Gl={changes:$H,selector:xH,handler:TH,initial:NH};function OH(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};Gl.initial(e),Gl.handler(t);var i={current:e},r=Mo(DH)(i,t),s=Mo(RH)(i),n=Mo(Gl.changes)(e),a=Mo(IH)(i);function o(){var c=arguments.length>0&&arguments[0]!==void 0?arguments[0]:function(u){return u};return Gl.selector(c),c(i.current)}function l(c){MH(r,s,n,a)(c)}return[o,l]}function IH(e,t){return dl(t)?t(e.current):t}function RH(e,t){return e.current=s8(s8({},e.current),t),t}function DH(e,t,i){return dl(t)?t(e.current):Object.keys(i).forEach(function(r){var s;return(s=t[r])===null||s===void 0?void 0:s.call(t,e.current[r])}),i}var VH={create:OH},BH={paths:{vs:"https://cdn.jsdelivr.net/npm/monaco-editor@0.55.1/min/vs"}};function ZH(e){return function t(){for(var i=this,r=arguments.length,s=new Array(r),n=0;n<r;n++)s[n]=arguments[n];return s.length>=e.length?e.apply(this,s):function(){for(var a=arguments.length,o=new Array(a),l=0;l<a;l++)o[l]=arguments[l];return t.apply(i,[].concat(s,o))}}}function FH(e){return{}.toString.call(e).includes("Object")}function zH(e){return e||n8("configIsRequired"),FH(e)||n8("configType"),e.urls?(UH(),{paths:{vs:e.urls.monacoBase}}):e}function UH(){console.warn(Bg.deprecation)}function WH(e,t){throw new Error(e[t]||e.default)}var Bg={configIsRequired:"the configuration object is required",configType:"the configuration object should be an object",default:"an unknown error accured in `@monaco-editor/loader` package",deprecation:`Deprecation warning!
|
|
59
|
-
You are using deprecated way of configuration.
|
|
60
|
-
|
|
61
|
-
Instead of using
|
|
62
|
-
monaco.config({ urls: { monacoBase: '...' } })
|
|
63
|
-
use
|
|
64
|
-
monaco.config({ paths: { vs: '...' } })
|
|
65
|
-
|
|
66
|
-
For more please check the link https://github.com/suren-atoyan/monaco-loader#config
|
|
67
|
-
`},n8=ZH(WH)(Bg),jH={config:zH},KH=function(){for(var t=arguments.length,i=new Array(t),r=0;r<t;r++)i[r]=arguments[r];return function(s){return i.reduceRight(function(n,a){return a(n)},s)}};function Zg(e,t){return Object.keys(t).forEach(function(i){t[i]instanceof Object&&e[i]&&Object.assign(t[i],Zg(e[i],t[i]))}),i8(i8({},e),t)}var qH={type:"cancelation",msg:"operation is manually canceled"};function w1(e){var t=!1,i=new Promise(function(r,s){e.then(function(n){return t?s(qH):r(n)}),e.catch(s)});return i.cancel=function(){return t=!0},i}var GH=["monaco"],YH=VH.create({config:BH,isInitialized:!1,resolve:null,reject:null,monaco:null}),Fg=wH(YH,2),Ml=Fg[0],Hc=Fg[1];function XH(e){var t=jH.config(e),i=t.monaco,r=bH(t,GH);Hc(function(s){return{config:Zg(s.config,r),monaco:i}})}function JH(){var e=Ml(function(t){var i=t.monaco,r=t.isInitialized,s=t.resolve;return{monaco:i,isInitialized:r,resolve:s}});if(!e.isInitialized){if(Hc({isInitialized:!0}),e.monaco)return e.resolve(e.monaco),w1(S1);if(window.monaco&&window.monaco.editor)return zg(window.monaco),e.resolve(window.monaco),w1(S1);KH(QH,tP)(iP)}return w1(S1)}function QH(e){return document.body.appendChild(e)}function eP(e){var t=document.createElement("script");return e&&(t.src=e),t}function tP(e){var t=Ml(function(r){var s=r.config,n=r.reject;return{config:s,reject:n}}),i=eP("".concat(t.config.paths.vs,"/loader.js"));return i.onload=function(){return e()},i.onerror=t.reject,i}function iP(){var e=Ml(function(i){var r=i.config,s=i.resolve,n=i.reject;return{config:r,resolve:s,reject:n}}),t=window.require;t.config(e.config),t(["vs/editor/editor.main"],function(i){var r=i.m||i;zg(r),e.resolve(r)},function(i){e.reject(i)})}function zg(e){Ml().monaco||Hc({monaco:e})}function rP(){return Ml(function(e){var t=e.monaco;return t})}var S1=new Promise(function(e,t){return Hc({resolve:e,reject:t})}),Ug={config:XH,init:JH,__getMonacoInstance:rP};const sP={key:0,class:"monaco-skeleton"},nP=Re({__name:"MonacoJsonEditor",props:{modelValue:{},height:{}},emits:["update:modelValue"],setup(e,{emit:t}){const i=e,r=t,{resolved:s}=Ad(),n=X(null),a=Ar(null),o=X(!1);let l=!1;return ut(async()=>{const c=await Ug.init();n.value&&(Fe(s,u=>c.editor.setTheme(u==="dark"?"vs-dark":"vs")),a.value=c.editor.create(n.value,{value:i.modelValue,language:"json",theme:s.value==="dark"?"vs-dark":"vs",fontSize:12,fontFamily:'"MesloLGS NF", monospace',minimap:{enabled:!1},scrollBeyondLastLine:!1,lineNumbers:"off",wordWrap:"on",automaticLayout:!0,tabSize:2,folding:!1,renderLineHighlight:"none",overviewRulerLanes:0,scrollbar:{verticalScrollbarSize:6}}),a.value.onDidChangeModelContent(()=>{l||r("update:modelValue",a.value.getValue())}),o.value=!0)}),Gi(()=>{var c;(c=a.value)==null||c.dispose()}),Fe(()=>i.modelValue,c=>{if(!a.value)return;a.value.getValue()!==c&&(l=!0,a.value.setValue(c),l=!1)}),(c,u)=>(g(),E("div",{style:Ci({height:`${e.height??220}px`,width:"100%",position:"relative"})},[b("div",{ref_key:"containerEl",ref:n,style:{height:"100%",width:"100%"}},null,512),o.value?F("",!0):(g(),E("div",sP))],4))}}),a8=jt(nP,[["__scopeId","data-v-0c34d464"]]),aP={class:"pcf-root"},oP={key:1,class:"pcf-no-schema"},lP=Re({__name:"PluginConfigForm",props:{hbSchema:{},modelValue:{}},emits:["update:modelValue"],setup(e,{emit:t}){const i=e,r=t;function s(h,d){const f=JSON.parse(JSON.stringify(i.modelValue));let m=f;for(let _=0;_<h.length-1;_++)(m[h[_]]===void 0||typeof m[h[_]]!="object")&&(m[h[_]]={}),m=m[h[_]];m[h[h.length-1]]=d,r("update:modelValue",f)}function n(h){let d=i.modelValue;for(const f of h){if(d==null||typeof d!="object")return;d=d[f]}return d}function a(h){return Array.isArray(h.type)?h.type[0]:h.type??"string"}function o(h,d){const f=n(h)??[],m=d.default??(a(d)==="string"?"":a(d)==="number"?0:"");s(h,[...f,m])}function l(h,d){const f=[...n(h)??[]];f.splice(d,1),s(h,f)}function c(h,d,f){const m=[...n(h)??[]];m[d]=f,s(h,m)}const u=Q(()=>i.hbSchema.schema??{type:"object",properties:{}});return(h,d)=>{const f=qo("PluginConfigField");return g(),E("div",aP,[u.value.properties?(g(!0),E(we,{key:0},Be(u.value.properties,(m,_)=>{var y;return g(),de(f,{key:_,"field-key":String(_),field:m,path:[String(_)],required:((y=u.value.required)==null?void 0:y.includes(String(_)))??!1,value:n([String(_)]),onChange:p=>s([String(_)],p),onAddArray:d[0]||(d[0]=(p,C)=>o(p,C)),onRemoveArray:d[1]||(d[1]=(p,C)=>l(p,C)),onUpdateArray:d[2]||(d[2]=(p,C,w)=>c(p,C,w))},null,8,["field-key","field","path","required","value","onChange"])}),128)):(g(),E("div",oP,"No configurable fields found in schema."))])}}}),cP=jt(lP,[["__scopeId","data-v-d9cf6b0f"]]),uP={key:0,class:"inspector nb-inspector"},hP={class:"inspector-header"},dP={class:"inspector-title"},fP={class:"inspector-name"},pP={class:"inspector-version"},_P={class:"inspector-body"},mP={class:"field-value"},gP={class:"field-value"},vP={class:"hap-bridge-info"},bP={class:"hap-qr"},yP=["src"],wP={class:"hap-details"},SP={class:"field-value mono"},CP={class:"field-value"},kP={class:"field-value"},AP={key:0,class:"setup-loading"},MP={key:0,class:"platform-tabs"},LP=["onClick"],EP={key:1,class:"visual-editor-wrap"},$P={key:0,class:"json-error"},xP={key:1,class:"json-error"},TP={key:3,class:"save-error"},NP={class:"setup-actions"},HP={key:0,class:"json-error"},PP={key:0,class:"save-error"},OP={class:"setup-actions"},IP={class:"import-export-row"},RP={class:"plugin-device-name"},DP={class:"plugin-device-type"},VP={class:"field-value"},BP={class:"field-value"},ZP={class:"field-value"},FP={class:"field-value"},zP={class:"error-text"},UP={class:"plog-time"},WP={class:"plog-msg"},o8="openbridge.pluginInspector.sections",jP=Re({__name:"PluginInspector",setup(e){const t=xs(),i=X(!1),r=X("");async function s(){if(!i.value){i.value=!0;try{await Ie.daemon.restart();let L=0;const I=setInterval(async()=>{L++;try{await Ie.health(),clearInterval(I),location.reload()}catch{}L>60&&(clearInterval(I),i.value=!1)},1e3)}catch{i.value=!1}}}const n=kl(),a=[{id:"visual",label:"Visual",icon:"sliders"},{id:"json",label:"JSON",icon:"brackets-curly"}],o={status:"default",hap:"default",update:"default",manage:"collapsed",config:"default",transfer:"collapsed",devices:"default",manifest:"collapsed",error:"default",logs:"default"},l=X({...o});try{const L=JSON.parse(localStorage.getItem(o8)??"{}");l.value={...o,...L}}catch{}Fe(l,L=>localStorage.setItem(o8,JSON.stringify(L)),{deep:!0}),Fe(()=>{var L,I;return(I=(L=n.selectedPlugin)==null?void 0:L.hapBridge)==null?void 0:I.setupURI},async L=>{if(L)try{r.value=await wa.toDataURL(L,{width:160,margin:1})}catch{r.value=""}else r.value=""},{immediate:!0});const c=Q(()=>{const L=n.selectedPlugin;return L!=null&&L.devices?Object.values(L.devices):[]}),u={switch:"plugs",light:"lamp",thermostat:"thermometer",dehumidifier:"drop",energy_meter:"lightning",gate:"garage",sensor:"pulse"};function h(L){return u[L]??"cube"}const d={idle:"Idle",loading:"Loading",running:"Running",stopped:"Stopped",error:"Error"},f=X(!1);async function m(){if(!(!n.selectedPlugin||f.value)){f.value=!0;try{await Ie.marketplace.update(n.selectedPlugin.manifest.name),await t.fetchPlugins(),await s()}catch(L){console.error("Failed to update plugin:",L)}finally{f.value=!1}}}const _=X(!1),y=X(!1);async function p(){if(!(!n.selectedPlugin||y.value)){y.value=!0;try{await Ie.marketplace.uninstall(n.selectedPlugin.manifest.name),await t.fetchPlugins(),n.close(),await Ie.daemon.restart()}catch(L){console.error("Failed to remove plugin:",L)}finally{y.value=!1,_.value=!1}}}const C=X(!1);async function w(){if(!n.selectedPlugin||C.value)return;const L=!n.selectedPlugin.disabled;C.value=!0;try{const I=await Ie.setPluginDisabled(n.selectedPlugin.id,L);n.selectedPlugin.disabled=I.disabled}catch(I){console.error("Failed to toggle plugin disabled state:",I)}finally{C.value=!1}}const v=X(null),k=X(!1),$=X(""),M=X(""),D=X(!1),H=X(null),R=X(!1),V=X(null),N=X({}),P=X("visual"),U=Q(()=>{var L;return((L=V.value)==null?void 0:L.schema)!=null}),j=Q(()=>{var L;return((L=n.selectedPlugin)==null?void 0:L.source)==="homebridge"}),oe=Q(()=>n.selectedPlugin!=null&&n.selectedPlugin.source!=="homebridge"),te=X(""),ne=X(!1),J=X(null),fe=X(!1),re=Q(()=>{try{return JSON.parse(te.value),!0}catch{return!1}});Fe(()=>n.selectedPlugin,async L=>{if(te.value="",J.value=null,fe.value=!1,!(!L||L.source==="homebridge"))try{const I=await Ie.config.getPlugin(L.manifest.name);te.value=JSON.stringify(I.config??{},null,2)}catch{te.value="{}"}});const _e=X(null);function Ne(){var L;(L=_e.value)==null||L.click()}function $e(){if(!n.selectedPlugin)return;const L=n.selectedPlugin.manifest.name,I=j.value?M.value:te.value;if(!I)return;const z=new Blob([I],{type:"application/json"}),W=URL.createObjectURL(z),ae=document.createElement("a");ae.href=W,ae.download=`${L.replace(/[^a-z0-9-]/gi,"-")}-config.json`,ae.click(),URL.revokeObjectURL(W)}async function be(L){var z;const I=(z=L.target.files)==null?void 0:z[0];if(!(!I||!n.selectedPlugin))try{const W=await I.text(),ae=JSON.parse(W);let ye;if(ae.platform&&typeof ae.platform=="string"){const{plugin:ke,...Oe}=ae;ye=Oe}else ye=ae;await Ie.config.savePlugin(n.selectedPlugin.manifest.name,ye),j.value?M.value=JSON.stringify(ye,null,2):te.value=JSON.stringify(ye,null,2),_e.value&&(_e.value.value="")}catch(W){console.error("Import failed:",W)}}async function me(){if(ne.value||!n.selectedPlugin)return;let L;try{L=JSON.parse(te.value)}catch{J.value="Invalid JSON: fix the syntax first";return}ne.value=!0,J.value=null,fe.value=!1;try{await Ie.config.savePlugin(n.selectedPlugin.manifest.name,L),fe.value=!0,setTimeout(()=>{fe.value=!1},3e3)}catch(I){J.value=String(I)}finally{ne.value=!1}}const O=Q(()=>{const L=n.selectedPlugin;return!L||L.source!=="homebridge"?"":L.platformName??L.id??L.manifest.name});Fe(()=>n.selectedPlugin,async L=>{if(v.value=null,$.value="",M.value="",V.value=null,N.value={},H.value=null,R.value=!1,!(!L||L.source!=="homebridge")){k.value=!0;try{const I=await Ie.config.getHbPlugin(O.value,L.packageName);if(I.config){$.value=O.value,M.value=JSON.stringify(I.config,null,2),N.value=I.config,await ie(L.manifest.name);return}const z=await Ie.pluginInfo(L.packageName??L.manifest.name);v.value=z,z.platforms.length>0&&await le(z.platforms[0],z.mainFile),await ie(L.manifest.name)}catch{try{const I=await Ie.config.getHbPlugin(O.value,L.packageName);I.config&&($.value=O.value,M.value=JSON.stringify(I.config,null,2),N.value=I.config)}catch{}}finally{k.value=!1}}});async function ie(L){try{const I=await fetch(`/api/marketplace/plugin-schema/${encodeURIComponent(L)}`);if(I.ok){const z=await I.json();V.value=z.schema}}catch{}}async function le(L,I){var z,W;$.value=L;try{const ae=await Ie.config.getPlatform(L),ye=ae.config?ae.config:{platform:L,plugin:I??((z=v.value)==null?void 0:z.mainFile)??""};M.value=JSON.stringify(ye,null,2),N.value=ye}catch{const ae={platform:L,plugin:I??((W=v.value)==null?void 0:W.mainFile)??""};M.value=JSON.stringify(ae,null,2),N.value=ae}}function ge(L){N.value=L,M.value=JSON.stringify(L,null,2)}function Se(L){M.value=L;try{N.value=JSON.parse(L)}catch{}}function x(){try{return JSON.parse(M.value)}catch{return null}}const T=Q(()=>x()!==null),K=Q(()=>{const L=x();return L!==null&&typeof L.platform!="string"}),se=X([]),he=X(null);let pe=null;function S(){if(pe&&(pe.close(),pe=null),!n.selectedPlugin)return;const L=location.protocol==="https:"?"wss:":"ws:";pe=new WebSocket(`${L}//${location.host}/ws/logs`),pe.onmessage=I=>{var z,W;try{const ae=JSON.parse(I.data);(ae.plugin===((z=n.selectedPlugin)==null?void 0:z.id)||ae.plugin===((W=n.selectedPlugin)==null?void 0:W.manifest.name))&&(se.value=[...se.value.slice(-199),ae],setTimeout(()=>{he.value&&(he.value.scrollTop=he.value.scrollHeight)},10))}catch{}},pe.onclose=()=>{n.selectedPlugin&&setTimeout(S,3e3)}}Fe(()=>n.selectedPlugin,async L=>{if(se.value=[],pe==null||pe.close(),pe=null,!!L){try{const I=await Ie.logs(L.manifest.name,100);se.value=I.entries,setTimeout(()=>{he.value&&(he.value.scrollTop=he.value.scrollHeight)},20)}catch{}S()}}),ut(()=>{n.selectedPlugin&&S()}),Gi(()=>{pe==null||pe.close()});const A={debug:"var(--nb-c-text-muted)",info:"var(--nb-c-info)",warn:"var(--nb-c-warning)",error:"var(--nb-c-danger)"};async function B(){if(D.value||!n.selectedPlugin)return;const L=x();if(!L){H.value="Invalid JSON: fix the syntax first";return}D.value=!0,H.value=null,R.value=!1;try{const I=n.selectedPlugin;I.source==="homebridge"?await Ie.config.saveHbPlugin(O.value,L,I.packageName):await Ie.config.savePlugin(I.manifest.name,L),R.value=!0,setTimeout(()=>{R.value=!1},3e3)}catch(I){H.value=String(I)}finally{D.value=!1}}return(L,I)=>{const z=Ge,W=Sd,ae=Sc,ye=kd,ke=oi,Oe=bc,je=N$;return ue(n).selectedPlugin?(g(),E("div",uP,[b("div",hP,[b("div",{class:xe(["inspector-avatar",ue(n).selectedPlugin.status])},[Y(z,{name:ue(rn),size:24},null,8,["name"])],2),b("div",dP,[b("h2",fP,Z(ue(n).selectedPlugin.manifest.name),1),b("span",pP,"v"+Z(ue(n).selectedPlugin.manifest.version),1)])]),b("div",_P,[Y(ye,{size:l.value.status,"onUpdate:size":I[0]||(I[0]=Ee=>l.value.status=Ee),title:"Status",fluid:""},{default:ee(()=>[Y(W,{label:"Status",control:"fit"},{default:ee(()=>[b("span",{class:xe(["status-badge",ue(n).selectedPlugin.status])},Z(d[ue(n).selectedPlugin.status]),3)]),_:1}),ue(n).selectedPlugin.startedAt?(g(),de(W,{key:0,label:"Started",control:"fit"},{default:ee(()=>[b("span",mP,Z(new Date(ue(n).selectedPlugin.startedAt).toLocaleString()),1)]),_:1})):F("",!0),ue(n).selectedPlugin.stoppedAt?(g(),de(W,{key:1,label:"Stopped",control:"fit"},{default:ee(()=>[b("span",gP,Z(new Date(ue(n).selectedPlugin.stoppedAt).toLocaleString()),1)]),_:1})):F("",!0),Y(W,{label:"Disabled",control:"fit"},{default:ee(()=>[Y(ae,{name:`plugin-disabled-${ue(n).selectedPlugin.id}`,"model-value":ue(n).selectedPlugin.disabled??!1,disabled:C.value,"onUpdate:modelValue":w},null,8,["name","model-value","disabled"])]),_:1})]),_:1},8,["size"]),ue(n).selectedPlugin.hapBridge?(g(),de(ye,{key:0,size:l.value.hap,"onUpdate:size":I[1]||(I[1]=Ee=>l.value.hap=Ee),title:"HomeKit pairing",fluid:""},{default:ee(()=>[b("div",vP,[b("div",bP,[r.value?(g(),E("img",{key:0,src:r.value,alt:"HomeKit QR Code",class:"hap-qr-img"},null,8,yP)):F("",!0)]),b("div",wP,[Y(W,{label:"PIN",control:"fit"},{default:ee(()=>[b("span",SP,Z(ue(n).selectedPlugin.hapBridge.pincode),1)]),_:1}),Y(W,{label:"Port",control:"fit"},{default:ee(()=>[b("span",CP,Z(ue(n).selectedPlugin.hapBridge.port),1)]),_:1}),Y(W,{label:"Bridge",control:"fit"},{default:ee(()=>[b("span",kP,Z(ue(n).selectedPlugin.hapBridge.name),1)]),_:1})])]),I[15]||(I[15]=b("p",{class:"hap-hint"},"Scan with the Home app or enter the PIN manually to pair this plugin's devices.",-1))]),_:1},8,["size"])):F("",!0),ue(n).selectedPlugin.availableUpdate?(g(),de(ye,{key:1,size:l.value.update,"onUpdate:size":I[2]||(I[2]=Ee=>l.value.update=Ee),title:"Update",fluid:""},{default:ee(()=>[Y(Oe,{status:"info",icon:Ed,title:`Version ${ue(n).selectedPlugin.availableUpdate} is available`},{action:ee(()=>[Y(ke,{variant:"primary",size:"sm",loading:f.value,disabled:f.value,onClick:m},{default:ee(()=>[ce(Z(f.value?"Updating...":"Update"),1)]),_:1},8,["loading","disabled"])]),default:ee(()=>[ce(" Currently on "+Z(ue(n).selectedPlugin.manifest.version)+". ",1)]),_:1},8,["title"])]),_:1},8,["size"])):F("",!0),Y(ye,{size:l.value.manage,"onUpdate:size":I[5]||(I[5]=Ee=>l.value.manage=Ee),title:"Manage",fluid:""},{default:ee(()=>[_.value?(g(),de(Oe,{key:1,status:"error",title:"This uninstalls the plugin and removes its configuration"},{action:ee(()=>[Y(ke,{variant:"ghost",size:"sm",onClick:I[4]||(I[4]=Ee=>_.value=!1)},{default:ee(()=>[...I[17]||(I[17]=[ce("Cancel",-1)])]),_:1}),Y(ke,{variant:"primary",size:"sm",loading:y.value,style:{background:"var(--nb-c-danger)","border-color":"var(--nb-c-danger)"},onClick:p},{default:ee(()=>[...I[18]||(I[18]=[ce(" Remove ",-1)])]),_:1},8,["loading"])]),default:ee(()=>[I[19]||(I[19]=ce(" OpenBridge needs a restart afterwards. ",-1))]),_:1})):(g(),de(ke,{key:0,variant:"ghost",size:"sm",icon:$d,style:{color:"var(--nb-c-danger)"},onClick:I[3]||(I[3]=Ee=>_.value=!0)},{default:ee(()=>[...I[16]||(I[16]=[ce(" Remove plugin ",-1)])]),_:1}))]),_:1},8,["size"]),j.value?(g(),de(ye,{key:2,size:l.value.config,"onUpdate:size":I[7]||(I[7]=Ee=>l.value.config=Ee),title:"Platform config",fluid:""},{default:ee(()=>[k.value?(g(),E("div",AP,[Y(z,{name:ue(Fn),size:14},null,8,["name"]),I[20]||(I[20]=ce(" Loading config… ",-1))])):(g(),E(we,{key:1},[v.value&&v.value.platforms.length>1?(g(),E("div",MP,[(g(!0),E(we,null,Be(v.value.platforms,Ee=>(g(),E("button",{key:Ee,class:xe(["platform-tab",{active:$.value===Ee}]),onClick:lt=>le(Ee)},Z(Ee),11,LP))),128))])):v.value&&v.value.platforms.length===0?(g(),de(Oe,{key:1,status:"warning",variant:"callout",title:"No platform detected"},{default:ee(()=>[...I[21]||(I[21]=[ce(" Add a ",-1),b("code",null,"platforms[]",-1),ce(" entry manually in Config. ",-1)])]),_:1})):F("",!0),!v.value||v.value.platforms.length>0?(g(),E(we,{key:2},[U.value?(g(),de(je,{key:0,"model-value":P.value,items:a,variant:"contained",size:"sm","onUpdate:modelValue":I[6]||(I[6]=Ee=>P.value=Ee)},null,8,["model-value"])):F("",!0),P.value==="visual"&&U.value?(g(),E("div",EP,[Y(cP,{"hb-schema":V.value,"model-value":N.value,"onUpdate:modelValue":ge},null,8,["hb-schema","model-value"])])):F("",!0),P.value==="json"||!U.value?(g(),E("div",{key:2,class:xe(["config-editor-wrap",{invalid:M.value&&!T.value}])},[Y(a8,{"model-value":M.value,height:220,"onUpdate:modelValue":Se},null,8,["model-value"]),M.value&&!T.value?(g(),E("div",$P,"Invalid JSON")):K.value?(g(),E("div",xP,'Missing "platform" field')):F("",!0)],2)):F("",!0),H.value?(g(),E("div",TP,[Y(z,{name:ue(mr),size:13},null,8,["name"]),ce(" "+Z(H.value),1)])):F("",!0),b("div",NP,[Y(ke,{variant:"primary",size:"sm",loading:D.value,disabled:D.value||!T.value||K.value,icon:R.value?Ss:z0,onClick:B},{default:ee(()=>[ce(Z(R.value?"Saved!":"Save config"),1)]),_:1},8,["loading","disabled","icon"]),R.value?(g(),de(ke,{key:0,variant:"secondary",size:"sm",outlined:"",loading:i.value,icon:i.value?ul:Qs,onClick:s},{default:ee(()=>[ce(Z(i.value?"Restarting…":"Restart OpenBridge"),1)]),_:1},8,["loading","icon"])):F("",!0)])],64)):F("",!0)],64))]),_:1},8,["size"])):F("",!0),oe.value?(g(),de(ye,{key:3,size:l.value.config,"onUpdate:size":I[9]||(I[9]=Ee=>l.value.config=Ee),title:"Plugin config",fluid:""},{default:ee(()=>[b("div",{class:xe(["config-editor-wrap",{invalid:te.value&&!re.value}])},[Y(a8,{"model-value":te.value,height:220,"onUpdate:modelValue":I[8]||(I[8]=Ee=>te.value=Ee)},null,8,["model-value"]),te.value&&!re.value?(g(),E("div",HP,"Invalid JSON")):F("",!0)],2),J.value?(g(),E("div",PP,[Y(z,{name:ue(mr),size:13},null,8,["name"]),ce(" "+Z(J.value),1)])):F("",!0),b("div",OP,[Y(ke,{variant:"primary",size:"sm",loading:ne.value,disabled:ne.value||!re.value,icon:fe.value?Ss:z0,onClick:me},{default:ee(()=>[ce(Z(fe.value?"Saved!":"Save config"),1)]),_:1},8,["loading","disabled","icon"]),fe.value?(g(),de(ke,{key:0,variant:"secondary",size:"sm",outlined:"",loading:i.value,icon:i.value?ul:Qs,onClick:s},{default:ee(()=>[ce(Z(i.value?"Restarting…":"Restart OpenBridge"),1)]),_:1},8,["loading","icon"])):F("",!0)])]),_:1},8,["size"])):F("",!0),Y(ye,{size:l.value.transfer,"onUpdate:size":I[10]||(I[10]=Ee=>l.value.transfer=Ee),title:"Import & export",fluid:""},{default:ee(()=>[b("div",IP,[Y(ke,{variant:"ghost",size:"sm",icon:yN,onClick:$e},{default:ee(()=>[...I[22]||(I[22]=[ce("Export config",-1)])]),_:1}),Y(ke,{variant:"ghost",size:"sm",icon:LN,onClick:Ne},{default:ee(()=>[...I[23]||(I[23]=[ce("Import config",-1)])]),_:1}),b("input",{ref_key:"importInput",ref:_e,type:"file",accept:".json",style:{display:"none"},onChange:be},null,544)])]),_:1},8,["size"]),c.value.length>0?(g(),de(ye,{key:4,size:l.value.devices,"onUpdate:size":I[11]||(I[11]=Ee=>l.value.devices=Ee),title:`Devices (${c.value.length})`,fluid:""},{default:ee(()=>[(g(!0),E(we,null,Be(c.value,Ee=>(g(),E("div",{key:Ee.id,class:"plugin-device-row"},[Y(z,{name:h(Ee.widgetType),size:14},null,8,["name"]),b("span",RP,Z(Ee.name),1),b("span",DP,Z(Ee.widgetType),1)]))),128))]),_:1},8,["size","title"])):F("",!0),Y(ye,{size:l.value.manifest,"onUpdate:size":I[12]||(I[12]=Ee=>l.value.manifest=Ee),title:"Manifest",fluid:""},{default:ee(()=>[Y(W,{label:"Name",control:"fit"},{default:ee(()=>[b("span",VP,Z(ue(n).selectedPlugin.manifest.name),1)]),_:1}),Y(W,{label:"Version",control:"fit"},{default:ee(()=>[b("span",BP,Z(ue(n).selectedPlugin.manifest.version),1)]),_:1}),ue(n).selectedPlugin.manifest.description?(g(),de(W,{key:0,label:"Description",control:"fit"},{default:ee(()=>[b("span",ZP,Z(ue(n).selectedPlugin.manifest.description),1)]),_:1})):F("",!0),ue(n).selectedPlugin.manifest.author?(g(),de(W,{key:1,label:"Author",control:"fit"},{default:ee(()=>[b("span",FP,Z(ue(n).selectedPlugin.manifest.author),1)]),_:1})):F("",!0)]),_:1},8,["size"]),ue(n).selectedPlugin.error?(g(),de(ye,{key:5,size:l.value.error,"onUpdate:size":I[13]||(I[13]=Ee=>l.value.error=Ee),title:"Error",fluid:""},{default:ee(()=>[Y(Oe,{status:"error"},{default:ee(()=>[b("code",zP,Z(ue(n).selectedPlugin.error),1)]),_:1})]),_:1},8,["size"])):F("",!0),se.value.length>0?(g(),de(ye,{key:6,size:l.value.logs,"onUpdate:size":I[14]||(I[14]=Ee=>l.value.logs=Ee),title:"Recent logs",fluid:""},{default:ee(()=>[b("div",{ref_key:"logsEl",ref:he,class:"plugin-log-terminal"},[(g(!0),E(we,null,Be(se.value,(Ee,lt)=>(g(),E("div",{key:lt,class:"plugin-log-line"},[b("span",UP,Z(new Date(Ee.timestamp).toLocaleTimeString()),1),b("span",{class:"plog-level",style:Ci({color:A[Ee.level]})},Z(Ee.level.toUpperCase()),5),b("span",WP,Z(Ee.message),1)]))),128))],512)]),_:1},8,["size"])):F("",!0)])])):F("",!0)}}}),KP=jt(jP,[["__scopeId","data-v-b8eb965d"]]),qP=(e,t,i)=>{const r=s=>Me("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:t,fill:"currentColor",...s,innerHTML:i});return r.displayName="NbGlyph",r.glyphName=e,r},l8=qP("arrow-square-out","0 0 256 256",'<path d="M224,104a8,8,0,0,1-16,0V59.32l-66.33,66.34a8,8,0,0,1-11.32-11.32L196.68,48H152a8,8,0,0,1,0-16h64a8,8,0,0,1,8,8Zm-40,24a8,8,0,0,0-8,8v72H48V80h72a8,8,0,0,0,0-16H48A16,16,0,0,0,32,80V208a16,16,0,0,0,16,16H176a16,16,0,0,0,16-16V136A8,8,0,0,0,184,128Z"/>'),GP=(e,t,i)=>{const r=s=>Me("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:t,fill:"currentColor",...s,innerHTML:i});return r.displayName="NbGlyph",r.glyphName=e,r},kn=GP("diamond","0 0 256 256",'<path d="M235.33,116.72,139.28,20.66a16,16,0,0,0-22.56,0l-96,96.06a16,16,0,0,0,0,22.56l96.05,96.06h0a16,16,0,0,0,22.56,0l96.05-96.06a16,16,0,0,0,0-22.56ZM128,224h0L32,128,128,32,224,128Z"/>'),YP=(e,t,i)=>{const r=s=>Me("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:t,fill:"currentColor",...s,innerHTML:i});return r.displayName="NbGlyph",r.glyphName=e,r},XP=YP("folder","0 0 256 256",'<path d="M216,72H131.31L104,44.69A15.86,15.86,0,0,0,92.69,40H40A16,16,0,0,0,24,56V200.62A15.4,15.4,0,0,0,39.38,216H216.89A15.13,15.13,0,0,0,232,200.89V88A16,16,0,0,0,216,72ZM40,56H92.69l16,16H40ZM216,200H40V88H216Z"/>'),JP=(e,t,i)=>{const r=s=>Me("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:t,fill:"currentColor",...s,innerHTML:i});return r.displayName="NbGlyph",r.glyphName=e,r},QP=JP("cloud-arrow-down","0 0 256 256",'<path d="M248,128a87.34,87.34,0,0,1-17.6,52.81,8,8,0,1,1-12.8-9.62A71.34,71.34,0,0,0,232,128a72,72,0,0,0-144,0,8,8,0,0,1-16,0,88,88,0,0,1,3.29-23.88C74.2,104,73.1,104,72,104a48,48,0,0,0,0,96H96a8,8,0,0,1,0,16H72A64,64,0,1,1,81.29,88.68,88,88,0,0,1,248,128Zm-69.66,42.34L160,188.69V128a8,8,0,0,0-16,0v60.69l-18.34-18.35a8,8,0,0,0-11.32,11.32l32,32a8,8,0,0,0,11.32,0l32-32a8,8,0,0,0-11.32-11.32Z"/>'),eO=(e,t,i)=>{const r=s=>Me("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:t,fill:"currentColor",...s,innerHTML:i});return r.displayName="NbGlyph",r.glyphName=e,r},tO=eO("star","0 0 256 256",'<path d="M234.29,114.85l-45,38.83L203,211.75a16.4,16.4,0,0,1-24.5,17.82L128,198.49,77.47,229.57A16.4,16.4,0,0,1,53,211.75l13.76-58.07-45-38.83A16.46,16.46,0,0,1,31.08,86l59-4.76,22.76-55.08a16.36,16.36,0,0,1,30.27,0l22.75,55.08,59,4.76a16.46,16.46,0,0,1,9.37,28.86Z"/>'),iO=(e,t,i)=>{const r=s=>Me("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:t,fill:"currentColor",...s,innerHTML:i});return r.displayName="NbGlyph",r.glyphName=e,r},Wg=iO("heart","0 0 256 256",'<path d="M240,102c0,70-103.79,126.66-108.21,129a8,8,0,0,1-7.58,0C119.79,228.66,16,172,16,102A62.07,62.07,0,0,1,78,40c20.65,0,38.73,8.88,50,23.89C139.27,48.88,157.35,40,178,40A62.07,62.07,0,0,1,240,102Z"/>'),rO=(e,t,i)=>{const r=s=>Me("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:t,fill:"currentColor",...s,innerHTML:i});return r.displayName="NbGlyph",r.glyphName=e,r},jg=rO("book-open","0 0 256 256",'<path d="M232,48H160a40,40,0,0,0-32,16A40,40,0,0,0,96,48H24a8,8,0,0,0-8,8V200a8,8,0,0,0,8,8H96a24,24,0,0,1,24,24,8,8,0,0,0,16,0,24,24,0,0,1,24-24h72a8,8,0,0,0,8-8V56A8,8,0,0,0,232,48ZM96,192H32V64H96a24,24,0,0,1,24,24V200A39.81,39.81,0,0,0,96,192Zm128,0H160a39.81,39.81,0,0,0-24,8V88a24,24,0,0,1,24-24h64Z"/>');let sO=0;function nO(){return`notif-${Date.now()}-${++sO}`}function Kg(){const e=hg();function t(i,r,s){e.add({id:nO(),variant:i,message:r,title:s==null?void 0:s.title,duration:(s==null?void 0:s.duration)??(i==="error"?6e3:3200)})}return{success:(i,r)=>t("success",i,r),error:(i,r)=>t("error",i,r),warning:(i,r)=>t("warning",i,r),info:(i,r)=>t("info",i,r),dismiss:i=>e.remove(i),clear:()=>e.clear()}}const aO={class:"mp-panel"},oO={class:"mp-header"},lO={class:"mp-search-wrap"},cO={key:0,class:"mp-count"},uO={key:3,class:"mp-local-section"},hO={class:"mp-local-heading"},dO={class:"mp-avatar mp-avatar--ob"},fO={class:"mp-info"},pO={class:"mp-name-row"},_O={class:"mp-name"},mO={class:"badge badge--native"},gO={class:"badge badge--local"},vO={class:"mp-ver"},bO={key:0,class:"mp-desc"},yO={class:"mp-meta"},wO={key:0},SO={class:"mp-action"},CO={class:"mp-list"},kO={key:0,class:"mp-loading"},AO=["src","alt"],MO={class:"mp-info"},LO={class:"mp-name-row"},EO={class:"mp-name"},$O={class:"mp-ver"},xO={key:0,class:"mp-desc"},TO={class:"mp-meta"},NO={key:0},HO={key:1,class:"mp-sep"},PO={class:"mp-enriched"},OO={key:0,class:"mp-stat"},IO={key:1,class:"mp-stat"},RO=["href"],DO=["href"],VO=["href"],BO={class:"mp-action"},ZO={key:1,class:"mp-load-more-wrap"},FO="https://marketplace.openbridge.nubisco.io",zO=20,UO="https://marketplace.openbridge.nubisco.io/api",WO=Re({__name:"MarketplacePanel",setup(e){const t=xs(),i=Kg(),r=X(null),s=X(""),n=X([]),a=X(0),o=X(!1),l=X(null),c=X(null),u=X(new Map),h=X(null),d=X(0),f=X([]);function m(V){return{name:V.name,version:V.version,description:V.description??"",author:V.author?{name:V.author}:void 0,date:V.last_published_at,weeklyDownloads:V.weekly_downloads,githubStars:V.github_stars??void 0,githubSponsorsUrl:V.github_sponsors_url??void 0,documentationUrl:V.homepage??void 0,links:{npm:V.npm_url,homepage:V.homepage??void 0,repository:V.repository_url??void 0}}}function _(V){return V?V>=1e6?`${(V/1e6).toFixed(1)}M`:V>=1e3?`${(V/1e3).toFixed(1)}K`:V.toString():"0"}async function y(V=!0){V&&(d.value=0,n.value=[]),o.value=!0,l.value=null;try{const N=d.value+1,P=new URLSearchParams({q:s.value,page:String(N),limit:String(zO)}),U=await fetch(`${UO}/plugins?${P}`);if(!U.ok)throw new Error(`Marketplace API error: ${U.status}`);const j=await U.json(),oe=j.plugins.map(m);n.value=V?oe:[...n.value,...oe],a.value=j.total}catch(N){l.value=String(N)}finally{o.value=!1}}async function p(V){if(!c.value){c.value=V.name,l.value=null;try{const N=await Ie.marketplace.install(V.name);u.value.set(V.name,N.mainFile),h.value={name:V.name,mainFile:N.mainFile},await Ie.pluginsRefresh(),await t.fetchPlugins(),i.success(`Installed ${V.name}`)}catch(N){l.value=`Failed to install ${V.name}: ${N}`,i.error(`Failed to install ${V.name}`)}finally{c.value=null}}}async function C(V){if(!r.value){r.value=V,l.value=null;try{await Ie.marketplace.uninstall(V),u.value.delete(V),await t.fetchPlugins(),i.success(`Removed ${V}`)}catch(N){l.value=`Failed to uninstall ${V}: ${N}`,i.error(`Failed to remove ${V}`)}finally{r.value=null}}}async function w(V){if(!(c.value||!V.platform)){c.value=V.name,l.value=null;try{await Ie.config.savePlugin(V.name,{platform:V.platform}),u.value.set(V.name,`${V.path}/dist/index.js`),h.value={name:V.name,mainFile:`${V.path}/dist/index.js`},await t.fetchPlugins(),i.success(`Activated ${V.name}`)}catch(N){l.value=`Failed to activate ${V.name}: ${N}`,i.error(`Failed to activate ${V.name}`)}finally{c.value=null}}}function v(V){var U,j;const P=(((U=V.links)==null?void 0:U.repository)??((j=V.links)==null?void 0:j.homepage)??"").match(/github\.com\/([^/]+)/);return P?`https://github.com/${P[1]}.png?size=48`:null}function k(V){return V.name.includes("openbridge-")||Array.isArray(V.badges)&&V.badges.includes("openbridge-plugin")}function $(V){return V.author?typeof V.author=="string"?V.author:V.author.name??"":""}function M(V){const N=Math.floor((Date.now()-new Date(V).getTime())/864e5);return N===0?"today":N<30?`${N}d ago`:N<365?`${Math.floor(N/30)}mo ago`:`${Math.floor(N/365)}y ago`}function D(){d.value++,y(!1)}let H=null;function R(){H&&clearTimeout(H),H=setTimeout(()=>y(),350)}return ut(async()=>{try{const V=await Ie.marketplace.installed();for(const N of V.packages)u.value.set(N.name,N.mainFile)}catch{}try{const V=await Ie.marketplace.local();f.value=V.plugins}catch{}y()}),(V,N)=>{const P=Ge,U=ha,j=bc,oe=Qe,te=oi,ne=Sl;return g(),E("div",aO,[b("div",oO,[N[4]||(N[4]=b("span",{class:"mp-title"},"Browse Plugins",-1)),b("a",{class:"mp-external",href:FO,target:"_blank",rel:"noopener noreferrer",title:"Open the full marketplace in a new tab"},[Y(P,{name:ue(l8),size:12},null,8,["name"]),N[3]||(N[3]=ce(" Marketplace ",-1))])]),b("div",lO,[Y(U,{modelValue:s.value,"onUpdate:modelValue":[N[0]||(N[0]=J=>s.value=J),R],placeholder:"Search plugins",size:"sm"},null,8,["modelValue"])]),a.value>0?(g(),E("div",cO,Z(a.value.toLocaleString())+" plugins found",1)):F("",!0),h.value?(g(),de(j,{key:1,status:"success",dismissible:"",class:"mp-installed-banner",title:`${h.value.name} installed`,onDismiss:N[1]||(N[1]=J=>h.value=null)},{default:ee(()=>[...N[5]||(N[5]=[ce(" Click it in your plugins list to configure it. ",-1)])]),_:1},8,["title"])):F("",!0),l.value?(g(),de(oe,{key:2,variant:"error"},{default:ee(()=>[ce(Z(l.value),1)]),_:1})):F("",!0),f.value.length>0?(g(),E("div",uO,[b("div",hO,[Y(P,{name:ue(kn),size:11},null,8,["name"]),N[6]||(N[6]=ce(" Local plugins ",-1))]),(g(!0),E(we,null,Be(f.value,J=>(g(),de(ne,{key:J.name,class:"mp-row mp-row--ob mp-row--local"},{default:ee(()=>[b("div",dO,[Y(P,{name:ue(kn),size:16},null,8,["name"])]),b("div",fO,[b("div",pO,[b("span",_O,Z(J.name),1),b("span",mO,[Y(P,{name:ue(kn),size:9},null,8,["name"]),N[7]||(N[7]=ce(" Native ",-1))]),b("span",gO,[Y(P,{name:ue(XP),size:9},null,8,["name"]),N[8]||(N[8]=ce(" Local ",-1))]),b("span",vO,"v"+Z(J.version),1)]),J.description?(g(),E("p",bO,Z(J.description),1)):F("",!0),b("div",yO,[J.author?(g(),E("span",wO,Z(J.author),1)):F("",!0)])]),b("div",SO,[u.value.has(J.name)?(g(),de(te,{key:0,variant:"ghost",size:"sm",disabled:"",icon:Ss},{default:ee(()=>[...N[9]||(N[9]=[ce("Active",-1)])]),_:1})):(g(),de(te,{key:1,variant:"primary",size:"sm",loading:c.value===J.name,disabled:!!c.value||!J.platform,title:J.platform?"":"No platform declared in package.json openbridge.platform",onClick:fe=>w(J)},{default:ee(()=>[...N[10]||(N[10]=[ce(" Activate ",-1)])]),_:1},8,["loading","disabled","title","onClick"]))])]),_:2},1024))),128))])):F("",!0),b("div",CO,[o.value&&n.value.length===0?(g(),E("div",kO,[Y(P,{name:ue(Fn),size:22},null,8,["name"]),N[11]||(N[11]=b("span",null,"Searching npm…",-1))])):F("",!0),(g(!0),E(we,null,Be(n.value,J=>(g(),de(ne,{key:J.name,class:xe(["mp-row",{"mp-row--ob":k(J)}])},{default:ee(()=>[b("div",{class:xe(["mp-avatar",{"mp-avatar--ob":k(J)}])},[v(J)?(g(),E("img",{key:0,src:v(J),alt:J.name,class:"mp-avatar-img",onError:N[2]||(N[2]=fe=>fe.target.style.display="none")},null,40,AO)):F("",!0),k(J)?(g(),de(P,{key:1,name:ue(kn),size:16},null,8,["name"])):(g(),de(P,{key:2,name:ue(rn),size:16},null,8,["name"]))],2),b("div",MO,[b("div",LO,[b("span",EO,Z(J.name),1),b("span",$O,"v"+Z(J.version),1)]),J.description?(g(),E("p",xO,Z(J.description),1)):F("",!0),b("div",TO,[$(J)?(g(),E("span",NO,Z($(J)),1)):F("",!0),$(J)?(g(),E("span",HO,"·")):F("",!0),b("span",null,Z(M(J.date)),1)]),b("div",PO,[J.weeklyDownloads?(g(),E("span",OO,[Y(P,{name:ue(QP),size:11},null,8,["name"]),ce(" "+Z(_(J.weeklyDownloads)),1)])):F("",!0),J.githubStars?(g(),E("span",IO,[Y(P,{name:ue(tO),weight:"fill",size:11},null,8,["name"]),ce(" "+Z(_(J.githubStars)),1)])):F("",!0),J.githubSponsorsUrl?(g(),E("a",{key:2,href:J.githubSponsorsUrl,target:"_blank",rel:"noopener",class:"mp-stat mp-stat--link"},[Y(P,{name:ue(Wg),weight:"fill",size:11},null,8,["name"]),N[12]||(N[12]=ce(" Sponsor ",-1))],8,RO)):F("",!0),J.documentationUrl?(g(),E("a",{key:3,href:J.documentationUrl,target:"_blank",rel:"noopener",class:"mp-stat mp-stat--link"},[Y(P,{name:ue(jg),size:11},null,8,["name"]),N[13]||(N[13]=ce(" Docs ",-1))],8,DO)):F("",!0),b("a",{href:`https://marketplace.openbridge.nubisco.io/plugins/${J.name}`,target:"_blank",rel:"noopener",class:"mp-stat mp-stat--link mp-stat--marketplace"},[Y(P,{name:ue(l8),size:11},null,8,["name"]),N[14]||(N[14]=ce(" Marketplace ",-1))],8,VO)])]),b("div",BO,[u.value.has(J.name)?(g(),de(te,{key:0,variant:"danger",size:"sm",outlined:"",loading:r.value===J.name,disabled:!!r.value,onClick:fe=>C(J.name)},{default:ee(()=>[...N[15]||(N[15]=[ce(" Remove ",-1)])]),_:1},8,["loading","disabled","onClick"])):(g(),de(te,{key:1,variant:"primary",size:"sm",loading:c.value===J.name,disabled:!!c.value,onClick:fe=>p(J)},{default:ee(()=>[...N[16]||(N[16]=[ce(" Install ",-1)])]),_:1},8,["loading","disabled","onClick"]))])]),_:2},1032,["class"]))),128)),n.value.length>0&&n.value.length<a.value?(g(),E("div",ZO,[Y(te,{variant:"ghost",size:"sm",loading:o.value,disabled:o.value,onClick:D},{default:ee(()=>[ce(Z(o.value?"Loading…":`Load more (${a.value-n.value.length} remaining)`),1)]),_:1},8,["loading","disabled"])])):F("",!0)])])}}}),jO=jt(WO,[["__scopeId","data-v-789c3f61"]]),KO={key:0,class:"inspector-content nb-inspector"},qO={class:"detail-header"},GO={class:"detail-icon native-icon"},YO={style:{flex:"1","min-width":"0"}},XO={key:1,class:"rename-row"},JO={class:"detail-type"},QO={class:"info-grid"},eI={class:"info-val"},tI={class:"info-val"},iI={class:"info-val"},rI={class:"info-val"},sI={class:"info-val mono"},nI={key:0,class:"widget-energy"},aI={class:"energy-primary"},oI={class:"energy-value"},lI={class:"energy-secondary"},cI={key:0,class:"energy-item"},uI={class:"energy-item-val"},hI={key:1,class:"energy-item"},dI={class:"energy-item-val"},fI={key:1,class:"widget-thermo"},pI={class:"thermo-row"},_I={class:"thermo-value"},mI={class:"thermo-row"},gI={class:"thermo-value accent"},vI={class:"thermo-row"},bI={key:2,class:"widget-thermo"},yI={class:"thermo-row"},wI={class:"thermo-value"},SI={class:"thermo-row"},CI={class:"thermo-value accent"},kI={class:"thermo-row"},AI={key:3,class:"widget-generic"},MI={key:0,class:"no-telemetry"},LI={class:"char-name"},EI={class:"char-value"},$I={class:"event-list"},xI=["title"],TI={class:"event-body"},NI={class:"event-message"},HI={key:0,class:"event-source"},PI={class:"history-tabs"},OI=["onClick"],II={key:0,class:"history-nav"},RI={class:"history-nav-center"},DI={class:"history-total"},VI={class:"history-date"},BI={key:2,class:"no-history"},ZI={key:3,class:"no-history"},FI={key:4,class:"no-history"},zI={class:"obs-help"},UI={class:"obs-form"},WI={class:"obs-verdicts"},jI={key:1,class:"obs-list"},KI={class:"obs-list-head"},qI={class:"obs-when"},GI={class:"obs-temp"},YI={key:0,class:"obs-note"},XI={class:"calibration-actions"},JI={class:"char-list"},QI={class:"char-name"},eR={class:"char-value"},tR={key:0,class:"homekit-notice"},iR={class:"homekit-row"},rR={key:1,class:"homekit-notice"},sR={class:"detail-header"},nR={class:"detail-icon"},aR={style:{flex:"1","min-width":"0"}},oR={key:1,class:"rename-row"},lR={class:"detail-type"},cR={class:"info-grid"},uR={key:0,class:"info-key"},hR={key:1,class:"info-val"},dR={key:0,class:"homekit-row"},fR={key:1,class:"homekit-notice"},pR={class:"char-list"},_R={class:"char-name"},mR={class:"homekit-row"},gR={key:0,class:"homekit-notice"},vR={class:"detail-uuid"},bR=Re({__name:"DeviceInspector",setup(e){const t=X(new Set),i=X(!1),r=X("");function s(G){return!t.value.has(G)}async function n(){try{const{hidden:G}=await Ie.homekitHidden();t.value=new Set(G)}catch{}}async function a(G,q){i.value=!0,r.value="";try{const Ce=await Ie.setHomekitVisibility(G,q),We=new Set(t.value);q?We.delete(G):We.add(G),t.value=We,Ce.applied||(r.value="Saved. This takes effect after the next OpenBridge restart.")}catch(Ce){r.value=`Could not change visibility: ${Ce.message}`}finally{i.value=!1}}const o=X({}),l=X([]),c=X(""),u=Q(()=>[{value:"",label:"Default (as published)"},...l.value.map(G=>({value:G.key,label:G.label}))]);function h(G){return l.value.some(q=>q.serviceUuid===G)}function d(G,q){var Ce;return((Ce=o.value[G])==null?void 0:Ce[q])??""}const f=X(null);function m(G){return G.homekitType||G.widgetType}async function _(G){f.value=null;try{const{accessory:q}=await Ie.deviceAccessory(G);f.value=q}catch{}}async function y(){try{const{overrides:G,available:q}=await Ie.homekitServiceTypes();o.value=G,l.value=q}catch{}}async function p(G,q,Ce){i.value=!0,c.value="";try{await Ie.setHomekitServiceType(G,q,Ce||null);const We={...o.value},Ze={...We[G]??{}};Ce?Ze[q]=Ce:delete Ze[q],Object.keys(Ze).length>0?We[G]=Ze:delete We[G],o.value=We,c.value="Saved. This takes effect after the next OpenBridge restart."}catch(We){c.value=`Could not change type: ${We.message}`}finally{i.value=!1}}ut(()=>{n(),y()});const C=kl(),w=rx(),v=X(""),k=X(""),$=X("success"),M=Q(()=>{const G=C.selectedDevice;return!G||G.kind!=="native"?null:G.dev.health??null}),D=Q(()=>{var q;const G=(q=M.value)==null?void 0:q.lastSeen;return G?`Not responding since ${new Date(G).toLocaleString()}`:"Not responding"}),H=[{id:"cold",label:"Too cold"},{id:"ok",label:"About right"},{id:"warm",label:"Too warm"}],R=X(null),V=X("ok"),N=X(""),P=X(!1),U=X(""),j=X([]),oe=X(0);async function te(){const G=C.selectedDevice;if(!G||G.kind!=="native"||!G.dev.observations){j.value=[],oe.value=0;return}try{const q=await Ie.deviceObservations(G.dev.id,20);j.value=q.observations,oe.value=q.total}catch{}}async function ne(){const G=C.selectedDevice;if(!(!G||G.kind!=="native"||R.value===null)){P.value=!0,U.value="";try{await Ie.reportObservation(G.dev.id,{roomTemperature:R.value,comfort:V.value,...N.value.trim()?{note:N.value.trim()}:{}}),N.value="",await te()}catch(q){U.value=q instanceof Error?q.message:String(q)}finally{P.value=!1}}}Fe(()=>C.selectedDevice,()=>{U.value="",N.value="",te()},{immediate:!0});const J=Q(()=>{const G=C.selectedDevice;return!G||G.kind!=="native"?[]:G.dev.actions??[]});async function fe(G){const q=C.selectedDevice;if(!(!q||q.kind!=="native")&&!(G.confirm&&!await w({title:G.label,subjectLabel:"Device",subject:q.dev.name,message:G.confirm,confirmLabel:G.label}))){v.value=G.id,k.value="";try{await Ie.controlDevice(q.dev.id,G.id,!0),$.value="success",k.value=`${G.label} sent.`}catch(Ce){$.value="error",k.value=`${G.label} failed: ${Ce.message}`}finally{v.value=""}}}const re=Q(()=>C.selectedDevice),_e=Q(()=>re.value?re.value.kind==="native"?re.value.dev.id:re.value.acc.uuid:null),Ne={1:{label:"Other",icon:"cube"},2:{label:"Bridge",icon:"intersect"},3:{label:"Fan",icon:"fan"},4:{label:"Garage Door",icon:"garage"},5:{label:"Light",icon:"lightbulb"},6:{label:"Lock",icon:"lock"},7:{label:"Outlet",icon:"plugs"},8:{label:"Switch",icon:"toggle-right"},9:{label:"Thermostat",icon:"thermometer"},10:{label:"Sensor",icon:"pulse"},11:{label:"Security",icon:"shield"},12:{label:"Door",icon:"door"},13:{label:"Window",icon:"app-window"},14:{label:"Window Covering",icon:"rows"},15:{label:"Programm. Switch",icon:"sliders"},16:{label:"Range Extender",icon:"broadcast"},17:{label:"Camera",icon:"camera"},18:{label:"Video Doorbell",icon:"bell"},19:{label:"Air Purifier",icon:"wind"},20:{label:"Heater/Cooler",icon:"thermometer-hot"},21:{label:"Air Conditioner",icon:"snowflake"},22:{label:"Humidifier",icon:"drop"},23:{label:"Dehumidifier",icon:"drop"},26:{label:"Speaker",icon:"speaker-high"},28:{label:"Sprinkler",icon:"drop"},29:{label:"Faucet",icon:"drop"},30:{label:"Shower",icon:"drop"},32:{label:"TV",icon:"television"},34:{label:"Router",icon:"broadcast"},36:{label:"Target Control",icon:"game-controller"},38:{label:"Smart Speaker",icon:"speaker-hifi"}};function $e(G){return Ne[G]??{label:`Category ${G}`,icon:"cube"}}const be=new Set(["AccessoryInformation","0000003E-0000-1000-8000-0026BB765291","ProtocolInformation","000000A2-0000-1000-8000-0026BB765291"]);function me(G){return G.services.filter(q=>!be.has(q.name)&&!be.has(q.uuid))}function O(G){return G.services.find(q=>be.has(q.name)||be.has(q.uuid))}function ie(G){const q=O(G);if(!q)return null;const Ce=We=>{var Ze;return(Ze=q.characteristics.find(ti=>ti.name===We||ti.name.includes(We)))==null?void 0:Ze.value};return{manufacturer:Ce("Manufacturer")??Ce("Manuf"),model:Ce("Model"),serial:Ce("SerialNumber")??Ce("Serial"),firmware:Ce("FirmwareRevision")??Ce("Firmware")}}function le(G){return G.value===null||G.value===void 0?"—":G.format==="bool"?G.value?"On":"Off":typeof G.value=="number"?String(Math.round(G.value*100)/100):String(G.value)}function ge(G){return G.perms.includes("pw")}const Se=X(!1),x=X("");function T(G){x.value=G,Se.value=!0}async function K(G){var q,Ce;if(x.value.trim())try{const We=x.value.trim();await Ie.renameDevice(G,We),Se.value=!1,((q=re.value)==null?void 0:q.kind)==="native"?re.value.dev.name=We:((Ce=re.value)==null?void 0:Ce.kind)==="hap"&&(re.value.acc.displayName=We);const{useDaemonStore:Ze}=await k6(async()=>{const{useDaemonStore:bt}=await Promise.resolve().then(()=>U6);return{useDaemonStore:bt}},void 0);await Ze().fetchAccessories()}catch(We){console.error("Rename failed:",We)}}async function se(G,q,Ce,We){try{await Ie.setCharacteristic(G,q,Ce,We);const{useDaemonStore:Ze}=await k6(async()=>{const{useDaemonStore:bt}=await Promise.resolve().then(()=>U6);return{useDaemonStore:bt}},void 0);await Ze().fetchAccessories()}catch(Ze){console.error("Failed to set characteristic:",Ze)}}const he=X([]);function pe(G){const q=new Date(G);return Number.isNaN(q.getTime())?G:new Date().toDateString()===q.toDateString()?q.toLocaleTimeString(void 0,{hour:"2-digit",minute:"2-digit",second:"2-digit"}):q.toLocaleString(void 0,{month:"short",day:"numeric",hour:"2-digit",minute:"2-digit"})}async function S(){const G=re.value;if((G==null?void 0:G.kind)!=="native"){he.value=[];return}try{const q=await Ie.deviceEvents(G.dev.id,100);he.value=q.events}catch{he.value=[]}}const A={switch:"plugs",light:"lightbulb",thermostat:"thermometer",dehumidifier:"drop",energy_meter:"lightning",gate:"garage",sensor:"pulse",camera:"camera"},B={camera:"Camera",switch:"Switch",light:"Light",thermostat:"Thermostat",dehumidifier:"Dehumidifier",energy_meter:"Energy Meter",gate:"Gate",sensor:"Sensor"};function L(G){return A[G]??"cube"}function I(G){return B[G]??G}function z(G,q=1){if(G==null)return"—";const Ce=Number(G);return isFinite(Ce)?Ce.toFixed(q):String(G)}function W(G){return Object.entries(G.telemetry).filter(([q])=>!q.startsWith("_"))}const ae=X("day"),ye=X(new Date().toISOString().slice(0,10)),ke=X(null),Oe=X(!1);async function je(G){if(!Oe.value){Oe.value=!0;try{ke.value=await Ie.deviceHistory(G,ae.value,ye.value)}catch{}finally{Oe.value=!1}}}function Ee(G){var Ce;const q=new Date(ye.value+(ye.value.length<=7?"-01":""));ae.value==="day"?(q.setDate(q.getDate()+G),ye.value=q.toISOString().slice(0,10)):ae.value==="month"?(q.setMonth(q.getMonth()+G),ye.value=q.toISOString().slice(0,7)):(q.setFullYear(q.getFullYear()+G),ye.value=String(q.getFullYear())),((Ce=re.value)==null?void 0:Ce.kind)==="native"&&je(re.value.dev.id)}Fe(ae,()=>{var q;const G=new Date;ae.value==="day"?ye.value=G.toISOString().slice(0,10):ae.value==="month"?ye.value=G.toISOString().slice(0,7):ye.value=String(G.getFullYear()),((q=re.value)==null?void 0:q.kind)==="native"&&re.value.dev.widgetType==="energy_meter"&&je(re.value.dev.id)}),Fe(_e,(G,q)=>{if(G===q&&ke.value)return;const Ce=re.value;(Ce==null?void 0:Ce.kind)==="native"?_(Ce.dev.id):f.value=null,S(),(Ce==null?void 0:Ce.kind)==="native"&&Ce.dev.widgetType==="energy_meter"&&(ye.value=new Date().toISOString().slice(0,10),ae.value="day",je(Ce.dev.id))},{immediate:!0});const lt=X([]),Ot=X([]),$i=X(!1),Er=X(!1),Mt=X(!1),li=Q(()=>JSON.stringify(lt.value)!==JSON.stringify(Ot.value)),es=Q(()=>!re.value||re.value.kind!=="native"?null:re.value.dev);async function Yi(G){const{plugins:q}=await Ie.plugins(),Ce=q.find(Ze=>Ze.id===G.pluginId);if(!Ce)return null;if(Ce.source!=="homebridge"){const{config:Ze}=await Ie.config.getPlugin(G.pluginId);return Ze?{pluginConfig:Ze,isNative:!0,pluginName:G.pluginId,platformName:void 0}:null}else{const Ze=Ce.platformName??G.pluginId,{config:ti}=await Ie.config.getPlatform(Ze);return ti?{pluginConfig:ti,isNative:!1,pluginName:G.pluginId,platformName:Ze}:null}}async function Dc(){const G=es.value;if(G!=null&&G.interpolation){$i.value=!0,Mt.value=!1;try{const q=await Yi(G);if(!q)return;const We=(q.pluginConfig.devices??[]).find(un=>un.id===G.id);if(!We)return;const Ze=G.interpolation,bt=(We[Ze.configField]??[]).map(un=>({input:un[Ze.configShape.inputKey]??0,output:un[Ze.configShape.outputKey]??0}));lt.value=bt,Ot.value=JSON.parse(JSON.stringify(bt))}catch(q){console.error("Failed to load interpolation config:",q)}finally{$i.value=!1}}}async function Vc(){const G=es.value;if(G!=null&&G.interpolation){Er.value=!0,Mt.value=!1;try{const q=await Yi(G);if(!q)return;const Ce=G.interpolation,We=q.pluginConfig.devices??[],Ze=We.findIndex(bt=>bt.id===G.id);if(Ze<0)return;const ti=lt.value.map(bt=>({[Ce.configShape.inputKey]:bt.input,[Ce.configShape.outputKey]:bt.output}));We[Ze]={...We[Ze],[Ce.configField]:ti},q.pluginConfig.devices=We,q.isNative?await Ie.config.savePlugin(q.pluginName,q.pluginConfig):await Ie.config.savePlatform(q.pluginConfig),Ot.value=JSON.parse(JSON.stringify(lt.value)),Mt.value=!0}catch(q){console.error("Failed to save interpolation config:",q)}finally{Er.value=!1}}}function Bc(){lt.value=JSON.parse(JSON.stringify(Ot.value)),Mt.value=!1}Fe(_e,(G,q)=>{var Ce;G===q&&Ot.value.length>0||(Mt.value=!1,((Ce=re.value)==null?void 0:Ce.kind)==="native"&&re.value.dev.interpolation?Dc():(lt.value=[],Ot.value=[]))},{immediate:!0});const Tl=Q(()=>{var q;return(q=ke.value)!=null&&q.buckets?[{name:"kWh",data:ke.value.buckets.map(Ce=>{let We=Ce.label;return ae.value==="day"?We=parseInt(Ce.label)%6===0?Ce.label:"":ae.value==="month"&&(We=parseInt(Ce.label)%5===1?Ce.label:""),{x:We,y:Math.max(0,Math.round((Ce.kwh??0)*100)/100)}})}]:[]});return(G,q)=>{const Ce=Ge,We=ha,Ze=oi,ti=bc,bt=kd,un=N9,Fv=Cd,zv=Qe,Uv=an,Wv=AL,Wd=Cc,Zc=Sc;return re.value?(g(),E("div",KO,[re.value.kind==="native"?(g(),E(we,{key:0},[b("div",qO,[b("div",GO,[Y(Ce,{name:L(m(re.value.dev)),size:26},null,8,["name"])]),b("div",YO,[Se.value?(g(),E("div",XO,[Y(We,{modelValue:x.value,"onUpdate:modelValue":q[1]||(q[1]=Le=>x.value=Le),size:"sm",onKeyup:[q[2]||(q[2]=Br(Le=>K(re.value.dev.id),["enter"])),q[3]||(q[3]=Br(Le=>Se.value=!1,["escape"]))]},null,8,["modelValue"]),Y(Ze,{variant:"primary",size:"sm",icon:Ss,"aria-label":"Save name",onClick:q[4]||(q[4]=Le=>K(re.value.dev.id))}),Y(Ze,{variant:"ghost",size:"sm",icon:bu,"aria-label":"Cancel rename",onClick:q[5]||(q[5]=Le=>Se.value=!1)})])):(g(),E("h2",{key:0,class:"detail-name",title:"Click to rename",onClick:q[0]||(q[0]=Le=>T(re.value.dev.name))},Z(re.value.dev.name),1)),b("div",JO,Z(I(m(re.value.dev))),1)])]),Y(bt,{title:"Device info",fluid:""},R_({default:ee(()=>[M.value&&M.value.status==="stale"?(g(),de(ti,{key:0,status:"warning",title:D.value,style:{"margin-bottom":"0.5rem"}},{default:ee(()=>[ce(Z(M.value.reason),1)]),_:1},8,["title"])):F("",!0),k.value?(g(),de(ti,{key:1,status:$.value,title:k.value,style:{"margin-bottom":"0.5rem"}},null,8,["status","title"])):F("",!0),b("div",QO,[q[21]||(q[21]=b("span",{class:"info-key"},"Plugin",-1)),b("span",eI,Z(re.value.dev.pluginId),1),re.value.dev.manufacturer?(g(),E(we,{key:0},[q[19]||(q[19]=b("span",{class:"info-key"},"Manufacturer",-1)),b("span",tI,Z(re.value.dev.manufacturer),1)],64)):F("",!0),re.value.dev.model?(g(),E(we,{key:1},[q[20]||(q[20]=b("span",{class:"info-key"},"Model",-1)),b("span",iI,Z(re.value.dev.model),1)],64)):F("",!0),q[22]||(q[22]=b("span",{class:"info-key"},"Status",-1)),b("span",rI,Z(re.value.dev.pluginStatus),1),q[23]||(q[23]=b("span",{class:"info-key"},"ID",-1)),b("span",sI,Z(re.value.dev.id),1)])]),_:2},[J.value.length>0?{name:"toolbar",fn:ee(()=>[(g(!0),E(we,null,Be(J.value,Le=>(g(),de(Ze,{key:Le.id,size:"xs",variant:Le.danger?"danger":"ghost",disabled:v.value!=="",loading:v.value===Le.id,onClick:ct=>fe(Le)},{default:ee(()=>[ce(Z(Le.label),1)]),_:2},1032,["variant","disabled","loading","onClick"]))),128))]),key:"0"}:void 0]),1024),Y(bt,{title:"State",fluid:""},{default:ee(()=>[re.value.dev.widgetType==="energy_meter"?(g(),E("div",nI,[b("div",aI,[b("span",oI,Z(z(re.value.dev.telemetry.power,1)),1),q[24]||(q[24]=b("span",{class:"energy-unit"},"W",-1))]),b("div",lI,[re.value.dev.telemetry.voltage!==void 0?(g(),E("span",cI,[q[25]||(q[25]=b("span",{class:"energy-label"},"Voltage",-1)),b("span",uI,Z(z(re.value.dev.telemetry.voltage,1))+" V",1)])):F("",!0),re.value.dev.telemetry.current!==void 0?(g(),E("span",hI,[q[26]||(q[26]=b("span",{class:"energy-label"},"Current",-1)),b("span",dI,Z(z(re.value.dev.telemetry.current,3))+" A",1)])):F("",!0)])])):re.value.dev.widgetType==="thermostat"?(g(),E("div",fI,[b("div",pI,[q[27]||(q[27]=b("span",{class:"thermo-label"},"Current",-1)),b("span",_I,Z(z(re.value.dev.telemetry.currentTemperature,1))+"°C",1)]),b("div",mI,[q[28]||(q[28]=b("span",{class:"thermo-label"},"Target",-1)),b("span",gI,Z(z(re.value.dev.telemetry.targetTemperature,1))+"°C ",1)]),b("div",vI,[q[29]||(q[29]=b("span",{class:"thermo-label"},"Active",-1)),b("span",{class:xe(["thermo-value",re.value.dev.telemetry.active?"on":"off"])},Z(re.value.dev.telemetry.active?"On":"Off"),3)])])):re.value.dev.widgetType==="dehumidifier"?(g(),E("div",bI,[b("div",yI,[q[30]||(q[30]=b("span",{class:"thermo-label"},"Humidity",-1)),b("span",wI,Z(z(re.value.dev.telemetry.currentHumidity,0))+"%",1)]),b("div",SI,[q[31]||(q[31]=b("span",{class:"thermo-label"},"Target",-1)),b("span",CI,Z(z(re.value.dev.telemetry.targetHumidity,0))+"%",1)]),b("div",kI,[q[32]||(q[32]=b("span",{class:"thermo-label"},"Active",-1)),b("span",{class:xe(["thermo-value",re.value.dev.telemetry.active?"on":"off"])},Z(re.value.dev.telemetry.active?"On":"Off"),3)])])):(g(),E("div",AI,[Object.keys(re.value.dev.telemetry).filter(Le=>!Le.startsWith("_")).length===0?(g(),E("span",MI,"No telemetry yet")):F("",!0),(g(!0),E(we,null,Be(W(re.value.dev),([Le,ct])=>(g(),E("div",{key:Le,class:"char-row"},[b("span",LI,Z(Le),1),b("span",EI,Z(String(ct)),1)]))),128))]))]),_:1}),he.value.length>0?(g(),de(bt,{key:0,title:"Recent activity",fluid:""},{default:ee(()=>[b("ul",$I,[(g(!0),E(we,null,Be(he.value,(Le,ct)=>(g(),E("li",{key:`${Le.at}-${ct}`,class:"event"},[b("span",{class:"event-time",title:Le.at},Z(pe(Le.at)),9,xI),b("span",TI,[b("span",NI,Z(Le.message),1),Le.source?(g(),E("span",HI,Z(Le.source),1)):F("",!0)])]))),128))])]),_:1})):F("",!0),re.value.dev.widgetType==="energy_meter"?(g(),de(bt,{key:1,title:"Energy history",class:"energy-history",fluid:""},{default:ee(()=>[b("div",PI,[(g(),E(we,null,Be(["day","month","year"],Le=>b("button",{key:Le,class:xe(["history-tab",{active:ae.value===Le}]),onClick:ct=>ae.value=Le},Z(Le),11,OI)),64))]),ke.value?(g(),E("div",II,[Y(Ze,{variant:"ghost",size:"xs",icon:K9,title:"Previous",onClick:q[6]||(q[6]=Le=>Ee(-1))}),b("div",RI,[b("span",DI,[ce(Z(ke.value.totalKwh.toFixed(2))+" ",1),q[33]||(q[33]=b("span",{class:"history-unit"},"kWh",-1))]),b("span",VI,Z(ke.value.date),1)]),Y(Ze,{variant:"ghost",size:"xs",icon:dS,title:"Next",onClick:q[7]||(q[7]=Le=>Ee(1))})])):F("",!0),ke.value&&ke.value.totalKwh>0?(g(),de(un,{key:1,series:Tl.value,height:120,"show-legend":!1,"show-tooltip":!0},null,8,["series"])):F("",!0),ke.value&&ke.value.totalKwh===0?(g(),E("div",BI," No consumption recorded for this period. Data accumulates every 5 minutes. ")):F("",!0),!ke.value&&!Oe.value?(g(),E("div",ZI,"No data available for this period.")):F("",!0),Oe.value?(g(),E("div",FI,"Loading history…")):F("",!0)]),_:1})):F("",!0),re.value.dev.observations?(g(),de(bt,{key:2,title:"Report",fluid:""},{default:ee(()=>[b("p",zI,Z(re.value.dev.observations.help??"Tell the plugin what this device cannot measure itself."),1),b("div",UI,[Y(Fv,{modelValue:R.value,"onUpdate:modelValue":q[8]||(q[8]=Le=>R.value=Le),size:"sm",min:re.value.dev.observations.min,max:re.value.dev.observations.max,step:.5,label:`${re.value.dev.observations.label} (${re.value.dev.observations.unit})`},null,8,["modelValue","min","max","label"]),b("div",WI,[(g(),E(we,null,Be(H,Le=>Y(Ze,{key:Le.id,size:"sm",variant:V.value===Le.id?"primary":"ghost",onClick:ct=>V.value=Le.id},{default:ee(()=>[ce(Z(Le.label),1)]),_:2},1032,["variant","onClick"])),64))]),Y(We,{modelValue:N.value,"onUpdate:modelValue":q[9]||(q[9]=Le=>N.value=Le),size:"sm",placeholder:"Anything worth noting (sunny, window open)"},null,8,["modelValue"]),Y(Ze,{size:"sm",variant:"primary",disabled:R.value===null||P.value,onClick:ne},{default:ee(()=>[...q[34]||(q[34]=[ce(" Save report ",-1)])]),_:1},8,["disabled"])]),U.value?(g(),de(zv,{key:0,variant:"error"},{default:ee(()=>[ce(Z(U.value),1)]),_:1})):F("",!0),j.value.length>0?(g(),E("div",jI,[b("div",KI,Z(oe.value)+" report"+Z(oe.value===1?"":"s")+" so far",1),(g(!0),E(we,null,Be(j.value,(Le,ct)=>(g(),E("div",{key:ct,class:"obs-row"},[b("span",qI,Z(new Date(Le.at).toLocaleString()),1),b("span",GI,Z(Le.roomTemperature)+"°",1),Y(Uv,{variant:Le.comfort==="ok"?"green":Le.comfort==="cold"?"blue":"orange",size:"sm"},{default:ee(()=>[ce(Z(Le.comfort),1)]),_:2},1032,["variant"]),Le.note?(g(),E("span",YI,Z(Le.note),1)):F("",!0)]))),128))])):F("",!0)]),_:1})):F("",!0),re.value.dev.interpolation&<.value.length>0?(g(),de(bt,{key:3,title:"Calibration",fluid:""},{default:ee(()=>[Y(Wv,{modelValue:lt.value,"onUpdate:modelValue":q[10]||(q[10]=Le=>lt.value=Le),height:220,"input-label":re.value.dev.interpolation.inputLabel,"output-label":re.value.dev.interpolation.outputLabel,"input-min":re.value.dev.interpolation.inputMin,"input-max":re.value.dev.interpolation.inputMax,"output-min":re.value.dev.interpolation.outputMin,"output-max":re.value.dev.interpolation.outputMax,"input-step":.5,"output-step":1,"show-grid":!0,"show-tooltip":!0},null,8,["modelValue","input-label","output-label","input-min","input-max","output-min","output-max"]),q[37]||(q[37]=b("div",{class:"calibration-hint"},"Drag points to adjust. Double-click to add. Right-click to remove.",-1)),b("div",XI,[Y(Ze,{variant:"primary",size:"sm",disabled:!li.value||Er.value,onClick:Vc},{default:ee(()=>[ce(Z(Er.value?"Saving...":"Save"),1)]),_:1},8,["disabled"]),Y(Ze,{variant:"ghost",size:"sm",disabled:!li.value,onClick:Bc},{default:ee(()=>[...q[35]||(q[35]=[ce(" Reset ",-1)])]),_:1},8,["disabled"])]),Mt.value?(g(),de(ti,{key:0,status:"success",title:"Configuration saved"},{default:ee(()=>[...q[36]||(q[36]=[ce(" Restart the plugin to apply the new mapping. ",-1)])]),_:1})):F("",!0)]),_:1})):re.value.dev.interpolation&&$i.value?(g(),de(bt,{key:4,title:"Calibration",fluid:""},{default:ee(()=>[...q[38]||(q[38]=[b("div",{class:"no-history"},"Loading calibration data...",-1)])]),_:1})):F("",!0),W(re.value.dev).length>0?(g(),de(bt,{key:5,title:"All telemetry",fluid:""},{default:ee(()=>[b("div",JI,[(g(!0),E(we,null,Be(W(re.value.dev),([Le,ct])=>(g(),E("div",{key:Le,class:"char-row"},[b("span",QI,Z(Le),1),b("span",eR,Z(String(ct)),1)]))),128))])]),_:1})):F("",!0),f.value?(g(),de(bt,{key:6,title:"HomeKit",fluid:""},{default:ee(()=>[(g(!0),E(we,null,Be(me(f.value),Le=>Xs((g(),E("div",{key:Le.uuid,class:"homekit-row"},[q[39]||(q[39]=b("div",{class:"homekit-copy"},[b("span",{class:"homekit-title"},"Show in HomeKit as"),b("span",{class:"homekit-hint"}," A plugin cannot know what a generic relay drives. Set it here and OpenBridge re-applies it on every restart, so the Home app stops reverting to a switch. ")],-1)),Y(Wd,{"model-value":d(f.value.uuid,Le.uuid),options:u.value,disabled:i.value,size:"sm","onUpdate:modelValue":ct=>p(f.value.uuid,Le.uuid,String(ct))},null,8,["model-value","options","disabled","onUpdate:modelValue"])])),[[dm,h(Le.uuid)]])),128)),c.value?(g(),E("div",tR,Z(c.value),1)):F("",!0),b("div",iR,[q[40]||(q[40]=b("div",{class:"homekit-copy"},[b("span",{class:"homekit-title"},"Expose to HomeKit"),b("span",{class:"homekit-hint"}," Hide devices the Home app cannot represent usefully. OpenBridge keeps its telemetry and history either way. ")],-1)),Y(Zc,{name:`homekit-visible-${f.value.uuid}`,"model-value":s(f.value.uuid),disabled:i.value,"onUpdate:modelValue":q[11]||(q[11]=Le=>a(f.value.uuid,!!Le))},null,8,["name","model-value","disabled"])]),r.value?(g(),E("div",rR,Z(r.value),1)):F("",!0)]),_:1})):F("",!0)],64)):re.value.kind==="hap"?(g(),E(we,{key:1},[b("div",sR,[b("div",nR,[Y(Ce,{name:$e(re.value.acc.category).icon,size:26},null,8,["name"])]),b("div",aR,[Se.value?(g(),E("div",oR,[Y(We,{modelValue:x.value,"onUpdate:modelValue":q[13]||(q[13]=Le=>x.value=Le),size:"sm",onKeyup:[q[14]||(q[14]=Br(Le=>K(re.value.acc.uuid),["enter"])),q[15]||(q[15]=Br(Le=>Se.value=!1,["escape"]))]},null,8,["modelValue"]),Y(Ze,{variant:"primary",size:"sm",icon:Ss,"aria-label":"Save name",onClick:q[16]||(q[16]=Le=>K(re.value.acc.uuid))}),Y(Ze,{variant:"ghost",size:"sm",icon:bu,"aria-label":"Cancel rename",onClick:q[17]||(q[17]=Le=>Se.value=!1)})])):(g(),E("h2",{key:0,class:"detail-name",title:"Click to rename",onClick:q[12]||(q[12]=Le=>T(re.value.acc.displayName))},Z(re.value.acc.displayName),1)),b("div",lR,Z($e(re.value.acc.category).label),1)])]),ie(re.value.acc)?(g(),de(bt,{key:0,title:"Device info",fluid:""},{default:ee(()=>[b("div",cR,[(g(!0),E(we,null,Be(Object.entries(ie(re.value.acc)),([Le,ct])=>(g(),E(we,{key:Le},[ct?(g(),E("span",uR,Z(Le),1)):F("",!0),ct?(g(),E("span",hR,Z(ct),1)):F("",!0)],64))),128))])]),_:1})):F("",!0),(g(!0),E(we,null,Be(me(re.value.acc),Le=>(g(),de(bt,{key:Le.uuid,title:Le.displayName||Le.name,fluid:""},{default:ee(()=>[h(Le.uuid)?(g(),E("div",dR,[q[41]||(q[41]=b("div",{class:"homekit-copy"},[b("span",{class:"homekit-title"},"Show in HomeKit as"),b("span",{class:"homekit-hint"}," A plugin cannot know what a generic relay drives. Set it here and OpenBridge re-applies it on every restart, so the Home app stops reverting to a switch. ")],-1)),Y(Wd,{"model-value":d(re.value.acc.uuid,Le.uuid),options:u.value,disabled:i.value,size:"sm","onUpdate:modelValue":ct=>p(re.value.acc.uuid,Le.uuid,String(ct))},null,8,["model-value","options","disabled","onUpdate:modelValue"])])):F("",!0),c.value?(g(),E("div",fR,Z(c.value),1)):F("",!0),b("div",pR,[(g(!0),E(we,null,Be(Le.characteristics,ct=>(g(),E("div",{key:ct.uuid,class:"char-row"},[b("span",_R,Z(ct.name),1),ge(ct)&&ct.format==="bool"?(g(),de(Zc,{key:0,name:`hap-char-${Le.uuid}-${ct.uuid}`,"model-value":!!ct.value,"onUpdate:modelValue":jv=>se(re.value.acc.uuid,Le.uuid,ct.uuid,jv?1:0)},null,8,["name","model-value","onUpdate:modelValue"])):(g(),E("span",{key:1,class:xe(["char-value",{on:ct.format==="bool"&&ct.value}])},Z(le(ct)),3))]))),128))])]),_:2},1032,["title"]))),128)),Y(bt,{title:"HomeKit",fluid:""},{default:ee(()=>[b("div",mR,[q[42]||(q[42]=b("div",{class:"homekit-copy"},[b("span",{class:"homekit-title"},"Expose to HomeKit"),b("span",{class:"homekit-hint"}," Hide devices the Home app cannot represent usefully. OpenBridge keeps its telemetry and history either way. ")],-1)),Y(Zc,{name:`homekit-visible-${re.value.acc.uuid}`,"model-value":s(re.value.acc.uuid),disabled:i.value,"onUpdate:modelValue":q[18]||(q[18]=Le=>a(re.value.acc.uuid,!!Le))},null,8,["name","model-value","disabled"])]),r.value?(g(),E("div",gR,Z(r.value),1)):F("",!0)]),_:1}),b("div",vR,"UUID: "+Z(re.value.acc.uuid),1)],64)):F("",!0)])):F("",!0)}}}),yR=jt(bR,[["__scopeId","data-v-93cac877"]]),wR={class:"logs-filter"},SR={key:0,class:"log-empty"},CR={class:"log-time"},kR={class:"log-plugin"},AR={class:"log-msg"},c8="openbridge.logs.panelSize",MR=Re({__name:"LiveLogsPanel",setup(e){const t=xs(),i=["collapsed","default","full"],r=X("collapsed");ut(()=>{const c=localStorage.getItem(c8);c&&i.includes(c)&&(r.value=c)}),Fe(r,c=>localStorage.setItem(c8,c));const s=X([]),n=X(null),a=Q(()=>[{value:"system",label:"system"},...t.plugins.map(c=>({value:c.manifest.name,label:c.manifest.name}))]),o=Q(()=>s.value.length===0?t.logs:t.logs.filter(c=>s.value.includes(c.plugin)));function l(){t.logs.length=0}return Fe(()=>o.value.length,async()=>{const c=n.value;!c||!(c.scrollHeight-c.scrollTop-c.clientHeight<40)||(await _i(),c.scrollTop=c.scrollHeight)}),(c,u)=>{const h=Cc,d=oi,f=kd;return g(),de(f,{size:r.value,"onUpdate:size":u[1]||(u[1]=m=>r.value=m),title:"Live Logs"},{toolbar:ee(()=>[b("div",wR,[Y(h,{modelValue:s.value,"onUpdate:modelValue":u[0]||(u[0]=m=>s.value=m),multiple:"",options:a.value,placeholder:"All plugins",size:"xs"},null,8,["modelValue","options"])]),Y(d,{size:"xs",variant:"ghost",icon:$d,title:"Clear",onClick:l})]),default:ee(()=>[b("div",{ref_key:"logsEl",ref:n,class:"log-list"},[o.value.length===0?(g(),E("div",SR,"No log entries yet.")):F("",!0),(g(!0),E(we,null,Be(o.value,(m,_)=>(g(),E("div",{key:_,class:"log-line"},[b("span",CR,Z(new Date(m.timestamp).toLocaleTimeString()),1),b("span",{class:xe(["log-level",`log-level--${m.level}`])},Z(m.level.toUpperCase()),3),b("span",kR,Z(m.plugin),1),b("span",AR,Z(m.message),1)]))),128))],512)]),_:1},8,["size"])}}}),LR=jt(MR,[["__scopeId","data-v-2d8d29ff"]]),ER=["data-tooltip"],$R=["onClick"],xR=Re({__name:"AppLayout",setup(e){const t=Lc(),i=Cl(),r=xs(),s=kl(),n=ln(),a=Ec();async function o(){await a.logout()}const{theme:l,resolved:c,followsSystem:u,setTheme:h}=Ad(),d=[{value:"light",label:"Light"},{value:"dark",label:"Dark"},{value:"system",label:"System"}],f=Q({get:()=>l.value,set:R=>h(R)}),m=Q(()=>u.value?`Following your system, currently ${c.value}`:"Pinned, ignoring your system setting");function _(){var V;const R=(V=a.config.value)==null?void 0:V.issuer;R&&window.open(`${R}/profile`,"_blank","noopener")}const y=X([]),p=X(!0),C=Q(()=>y.value.map(R=>{var V;return{id:R.sub,email:R.email,name:R.name,current:R.sub===((V=a.user.value)==null?void 0:V.id)}}));async function w(){const R=await a.listIdentities();y.value=R,p.value=R.length===0}function v(R){a.switchAccount(R.email)}async function k(R){await a.removeIdentity(R.id),await w()}const $=X(null),M=X(!1);async function D(){try{const R=await fetch("/api/updates/check");if(!R.ok)return;const V=await R.json();V.updateAvailable&&V.latest&&($.value=V.latest)}catch{}}const H=[{name:"dashboard",icon:"house",label:"Dashboard",href:"/dashboard"},{name:"plugins",icon:"puzzle-piece",label:"Plugins",href:"/plugins"},{name:"devices",icon:"devices",label:"Devices",href:"/devices"},{name:"config",icon:"brackets-curly",label:"Config",href:"/config"},{name:"terminal",icon:"terminal",label:"Terminal",href:"/terminal"},{name:"settings",icon:"gear",label:"Settings",href:"/settings"}];return Fe(()=>t.name,()=>s.close()),ut(async()=>{await r.fetchHealth(),await r.fetchPlugins(),r.fetchLogs(),r.connectLiveLogs();const R=setInterval(()=>r.fetchHealth(),1e4);Ii(()=>clearInterval(R)),D()}),Ii(()=>r.disconnectLiveLogs()),(R,V)=>{const N=qo("RouterLink"),P=Ge,U=qE,j=i$,oe=Sd,te=zA,ne=g4,J=an,fe=oi,re=bc,_e=qo("RouterView"),Ne=KE;return g(),de(Ne,{"inspector-visible":ue(s).visible,"main-padding":!ue(n).fullBleed},R_({"sidebar-logo":ee(()=>[Y(N,{to:"/dashboard","data-tooltip":"OpenBridge",class:"sidebar-logo"},{default:ee(()=>[...V[4]||(V[4]=[b("img",{src:ET,width:"32",height:"32",alt:"OpenBridge logo"},null,-1)])]),_:1})]),"sidebar-nav":ee(()=>[(g(),E(we,null,Be(H,$e=>Y(U,{key:$e.name,to:$e.href,tooltip:$e.label,active:ue(t).name===$e.name,onClick:at(be=>ue(i).push($e.href),["prevent"])},{default:ee(()=>[Y(P,{name:$e.icon,size:18},null,8,["name"])]),_:2},1032,["to","tooltip","active","onClick"])),64))]),"sidebar-bottom":ee(()=>{var $e;return[b("div",{class:xe(["daemon-status",ue(r).connected?"online":"offline"]),"data-tooltip":ue(r).connected?"Daemon connected":"Daemon offline"},[...V[5]||(V[5]=[b("span",{class:"daemon-dot"},null,-1)])],10,ER),($e=ue(a).config.value)!=null&&$e.enabled&&ue(a).user.value?(g(),de(te,{key:0,user:{email:ue(a).user.value.email,picture:ue(a).user.value.picture},accounts:C.value,"accounts-unknown":p.value,"show-account-actions":ue(a).isNubiscoPlatform.value,"show-profile":ue(a).isNubiscoPlatform.value,brand:ue(a).isNubiscoPlatform.value?"footer":void 0,onOpen:w,onSwitch:v,onSwitchAccount:V[1]||(V[1]=be=>ue(a).chooseAccount()),onAddAccount:V[2]||(V[2]=be=>ue(a).addAccount()),onRemove:k,onProfile:_,onSignOut:o},{default:ee(({close:be})=>[Y(oe,{label:"Theme",hint:m.value,control:"fit",class:"menu-theme"},{default:ee(()=>[Y(j,{modelValue:f.value,"onUpdate:modelValue":V[0]||(V[0]=me=>f.value=me),name:"theme",options:d,direction:"horizontal"},null,8,["modelValue"])]),_:1},8,["hint"]),b("button",{type:"button",role:"menuitem",class:"nb-user-menu__action nb-user-menu__action--danger",onClick:me=>(be(),ue(a).logoutEverywhere())},[Y(P,{name:ue(j4),size:15},null,8,["name"]),V[6]||(V[6]=ce(" Sign out of all apps ",-1))],8,$R)]),_:1},8,["user","accounts","accounts-unknown","show-account-actions","show-profile","brand"])):F("",!0)]}),"topbar-left":ee(()=>[Y(ne,{subtitle:ue(n).title},null,8,["subtitle"]),ue(n).count!==null?(g(),de(J,{key:0},{default:ee(()=>[ce(Z(ue(n).count),1)]),_:1})):F("",!0),V[7]||(V[7]=b("div",{id:"ob-topbar-left",class:"topbar-slot"},null,-1))]),"topbar-right":ee(()=>[V[8]||(V[8]=b("div",{id:"ob-topbar-right",class:"topbar-slot"},null,-1))]),inspector:ee(()=>[ue(s).mode==="plugin"?(g(),de(KP,{key:0})):ue(s).mode==="marketplace"?(g(),de(jO,{key:1})):ue(s).mode==="device"?(g(),de(yR,{key:2})):F("",!0)]),bottom:ee(()=>[Y(LR)]),default:ee(()=>[Y(_e)]),_:2},[$.value&&!M.value?{name:"notification",fn:ee(()=>[Y(re,{status:"info",icon:Ed,flush:"",dismissible:"",title:`OpenBridge v${$.value} is available`,onDismiss:V[3]||(V[3]=$e=>M.value=!0)},{action:ee(()=>[Y(fe,{variant:"ghost",size:"sm",href:"https://github.com/nubisco/openbridge/releases",target:"_blank",rel:"noopener"},{default:ee(()=>[...V[9]||(V[9]=[ce(" See what's new ",-1)])]),_:1})]),_:1},8,["title"])]),key:"0"}:void 0]),1032,["inspector-visible","main-padding"])}}}),TR=jt(xR,[["__scopeId","data-v-01a1c16f"]]),NR=(e,t,i)=>{const r=s=>Me("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:t,fill:"currentColor",...s,innerHTML:i});return r.displayName="NbGlyph",r.glyphName=e,r},HR=NR("qr-code","0 0 256 256",'<path d="M104,40H56A16,16,0,0,0,40,56v48a16,16,0,0,0,16,16h48a16,16,0,0,0,16-16V56A16,16,0,0,0,104,40Zm0,64H56V56h48v48Zm0,32H56a16,16,0,0,0-16,16v48a16,16,0,0,0,16,16h48a16,16,0,0,0,16-16V152A16,16,0,0,0,104,136Zm0,64H56V152h48v48ZM200,40H152a16,16,0,0,0-16,16v48a16,16,0,0,0,16,16h48a16,16,0,0,0,16-16V56A16,16,0,0,0,200,40Zm0,64H152V56h48v48Zm-64,72V144a8,8,0,0,1,16,0v32a8,8,0,0,1-16,0Zm80-16a8,8,0,0,1-8,8H184v40a8,8,0,0,1-8,8H144a8,8,0,0,1,0-16h24V144a8,8,0,0,1,16,0v8h24A8,8,0,0,1,216,160Zm0,32v16a8,8,0,0,1-16,0V192a8,8,0,0,1,16,0Z"/>'),PR=(e,t,i)=>{const r=s=>Me("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:t,fill:"currentColor",...s,innerHTML:i});return r.displayName="NbGlyph",r.glyphName=e,r},OR=PR("cpu","0 0 256 256",'<path d="M152,96H104a8,8,0,0,0-8,8v48a8,8,0,0,0,8,8h48a8,8,0,0,0,8-8V104A8,8,0,0,0,152,96Zm-8,48H112V112h32Zm88,0H216V112h16a8,8,0,0,0,0-16H216V56a16,16,0,0,0-16-16H160V24a8,8,0,0,0-16,0V40H112V24a8,8,0,0,0-16,0V40H56A16,16,0,0,0,40,56V96H24a8,8,0,0,0,0,16H40v32H24a8,8,0,0,0,0,16H40v40a16,16,0,0,0,16,16H96v16a8,8,0,0,0,16,0V216h32v16a8,8,0,0,0,16,0V216h40a16,16,0,0,0,16-16V160h16a8,8,0,0,0,0-16Zm-32,56H56V56H200v95.87s0,.09,0,.13,0,.09,0,.13V200Z"/>'),IR=(e,t,i)=>{const r=s=>Me("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:t,fill:"currentColor",...s,innerHTML:i});return r.displayName="NbGlyph",r.glyphName=e,r},RR=IR("database","0 0 256 256",'<path d="M128,24C74.17,24,32,48.6,32,80v96c0,31.4,42.17,56,96,56s96-24.6,96-56V80C224,48.6,181.83,24,128,24Zm80,104c0,9.62-7.88,19.43-21.61,26.92C170.93,163.35,150.19,168,128,168s-42.93-4.65-58.39-13.08C55.88,147.43,48,137.62,48,128V111.36c17.06,15,46.23,24.64,80,24.64s62.94-9.68,80-24.64ZM69.61,53.08C85.07,44.65,105.81,40,128,40s42.93,4.65,58.39,13.08C200.12,60.57,208,70.38,208,80s-7.88,19.43-21.61,26.92C170.93,115.35,150.19,120,128,120s-42.93-4.65-58.39-13.08C55.88,99.43,48,89.62,48,80S55.88,60.57,69.61,53.08ZM186.39,202.92C170.93,211.35,150.19,216,128,216s-42.93-4.65-58.39-13.08C55.88,195.43,48,185.62,48,176V159.36c17.06,15,46.23,24.64,80,24.64s62.94-9.68,80-24.64V176C208,185.62,200.12,195.43,186.39,202.92Z"/>'),DR=(e,t,i)=>{const r=s=>Me("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:t,fill:"currentColor",...s,innerHTML:i});return r.displayName="NbGlyph",r.glyphName=e,r},VR=DR("clock","0 0 256 256",'<path d="M128,24A104,104,0,1,0,232,128,104.11,104.11,0,0,0,128,24Zm0,192a88,88,0,1,1,88-88A88.1,88.1,0,0,1,128,216Zm64-88a8,8,0,0,1-8,8H128a8,8,0,0,1-8-8V72a8,8,0,0,1,16,0v48h48A8,8,0,0,1,192,128Z"/>'),Sa=(e,t,i)=>{const r=s=>Me("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:t,fill:"currentColor",...s,innerHTML:i});return r.displayName="NbGlyph",r.glyphName=e,r},BR=Sa("pulse","0 0 256 256",'<path d="M236,128a4,4,0,0,1-4,4H202.47l-38.89,77.79A4,4,0,0,1,160,212h-.2a4,4,0,0,1-3.54-2.58l-60.59-159-36,79.28A4,4,0,0,1,56,132H24a4,4,0,0,1,0-8H53.42L92.36,38.35a4,4,0,0,1,7.38.23L160.5,198.06l35.92-71.85A4,4,0,0,1,200,124h32A4,4,0,0,1,236,128Z"/>'),ZR=Sa("pulse","0 0 256 256",'<path d="M238,128a6,6,0,0,1-6,6H203.71l-38.34,76.68A6,6,0,0,1,160,214h-.3a6,6,0,0,1-5.31-3.85L95.51,55.57,61.46,130.48A6,6,0,0,1,56,134H24a6,6,0,0,1,0-12H52.14l38.4-84.48a6,6,0,0,1,11.07.34L160.74,193.1l33.89-67.78A6,6,0,0,1,200,122h32A6,6,0,0,1,238,128Z"/>'),Uu=Sa("pulse","0 0 256 256",'<path d="M240,128a8,8,0,0,1-8,8H204.94l-37.78,75.58A8,8,0,0,1,160,216h-.4a8,8,0,0,1-7.08-5.14L95.35,60.76,63.28,131.31A8,8,0,0,1,56,136H24a8,8,0,0,1,0-16H50.85L88.72,36.69a8,8,0,0,1,14.76.46l57.51,151,31.85-63.71A8,8,0,0,1,200,120h32A8,8,0,0,1,240,128Z"/>'),FR=Sa("pulse","0 0 256 256",'<path d="M244,128a12,12,0,0,1-12,12H207.42l-36.69,73.37A12,12,0,0,1,160,220h-.6a12,12,0,0,1-10.61-7.72L95,71.15,66.92,133A12,12,0,0,1,56,140H24a12,12,0,0,1,0-24H48.27L85.08,35a12,12,0,0,1,22.13.7l54.28,142.46,27.78-55.56A12,12,0,0,1,200,116h32A12,12,0,0,1,244,128Z"/>'),zR=Sa("pulse","0 0 256 256",'<path d="M216,40H40A16,16,0,0,0,24,56V200a16,16,0,0,0,16,16H216a16,16,0,0,0,16-16V56A16,16,0,0,0,216,40Zm-8,96H188.64L159,188a8,8,0,0,1-6.95,4h-.46a8,8,0,0,1-6.89-4.84L103,89.92,79,132a8,8,0,0,1-7,4H48a8,8,0,0,1,0-16H67.36L97.05,68a8,8,0,0,1,14.3.82L153,166.08l24-42.05a8,8,0,0,1,6.95-4h24a8,8,0,0,1,0,16Z"/>'),UR=Sa("pulse","0 0 256 256",'<path d="M96,40l33.52,88H56Zm104,88H129.52L160,208Z" opacity="0.2"/><path d="M240,128a8,8,0,0,1-8,8H204.94l-37.78,75.58A8,8,0,0,1,160,216h-.4a8,8,0,0,1-7.08-5.14L95.35,60.76,63.28,131.31A8,8,0,0,1,56,136H24a8,8,0,0,1,0-16H50.85L88.72,36.69a8,8,0,0,1,14.76.46l57.51,151,31.85-63.71A8,8,0,0,1,200,120h32A8,8,0,0,1,240,128Z"/>'),WR="pulse",jR=Object.freeze(Object.defineProperty({__proto__:null,bold:FR,default:Uu,duotone:UR,fill:zR,glyphName:WR,light:ZR,regular:Uu,thin:BR},Symbol.toStringTag,{value:"Module"})),KR={class:"dashboard"},qR={class:"top-row"},GR={class:"hk-body"},YR={key:0,class:"qr-wrap"},XR=["src"],JR={key:1,class:"qr-placeholder"},QR={class:"hk-details"},eD={key:0,class:"pin-display"},tD={key:1,class:"pin-label"},iD={class:"hk-status"},rD={key:2,class:"hk-error"},sD={key:0,class:"sys-grid"},nD={class:"sys-val"},aD={class:"sys-val"},oD={class:"sys-val"},lD={class:"sys-val"},cD={class:"sys-val"},uD={class:"sys-val"},hD={class:"sys-val"},dD={class:"sys-val mono"},fD={class:"sys-val mono"},pD={class:"sys-val mono"},_D={key:1,class:"loading-inline"},mD={class:"card-title"},gD={class:"plugins-counts"},vD={key:0,class:"pill red"},bD={key:0,class:"empty-inline"},yD={key:1,class:"plugins-list"},wD={class:"plugin-name"},SD={class:"plugin-ver"},CD={class:"metrics-row"},kD={class:"metric-header"},AD={class:"metric-icon purple"},MD={class:"metric-values"},LD={class:"metric-big"},ED={key:0,class:"metric-sub"},$D={class:"metric-chart"},xD={class:"metric-header"},TD={class:"metric-icon blue"},ND={class:"metric-values"},HD={class:"metric-big"},PD={class:"metric-sub"},OD={class:"metric-chart"},ID={class:"metric-header"},RD={class:"metric-icon green"},DD={class:"uptime-rows"},VD={class:"uptime-row"},BD={class:"uptime-val"},ZD={class:"uptime-row"},FD={class:"uptime-val"},zD={style:{"margin-top":"0.75rem"}},UD={class:"metric-header"},WD={class:"metric-icon amber"},jD={class:"net-values"},KD={class:"net-val"},qD={class:"net-val"},GD={class:"metric-chart net-charts"},YD=Re({__name:"DashboardView",setup(e){const t=xs(),i=ln();function r(N){return N==="running"?"green":N==="error"?"red":N==="loading"?"blue":"grey"}const s=X(!1),n=X(!1);async function a(){if(!s.value){s.value=!0,n.value=!1;try{await Ie.daemon.restart(),n.value=!0;let N=0;const P=setInterval(async()=>{N++;try{await Ie.health(),clearInterval(P),location.reload()}catch{}N>60&&(clearInterval(P),s.value=!1)},1e3)}catch{s.value=!1}}}const o=X(null),l=X(""),c=X(""),u=X(""),h=Q(()=>t.connected?u.value?"red":"green":"gray"),d=Q(()=>t.connected?u.value?"HomeKit offline":"Bridge running":"Daemon offline"),f=X([]),m=X([]),_=X([]),y=X([]),p=Ar(null);let C=null;function w(){C&&(C.onclose=null,C.close(),C=null);const N=location.protocol==="https:"?"wss:":"ws:";C=new WebSocket(`${N}//${location.host}/ws/metrics`),C.onmessage=P=>{if(!document.hidden)try{const U=JSON.parse(P.data);if(U.type==="history"){const j=U.data;f.value=j.map(oe=>oe.cpu),m.value=j.map(oe=>$(oe)),_.value=j.map(oe=>oe.netRxSec),y.value=j.map(oe=>oe.netTxSec),j.length&&(p.value=j[j.length-1])}else if(U.type==="snapshot"){const j=U.data;p.value=j,k(f,j.cpu),k(m,$(j)),k(_,j.netRxSec),k(y,j.netTxSec)}}catch{}},C.onclose=()=>{C=null,setTimeout(w,3e3)}}function v(){document.hidden||w()}function k(N,P){N.value=[...N.value.slice(-59),P]}function $(N){return N.memTotal?Math.round((N.memTotal-N.memFree)/N.memTotal*100):0}function M(N){return N<1024?`${N} B`:N<1024**2?`${(N/1024).toFixed(1)} KB`:N<1024**3?`${(N/1024**2).toFixed(1)} MB`:`${(N/1024**3).toFixed(1)} GB`}function D(N){const P=Math.floor(N/86400),U=Math.floor(N%86400/3600),j=Math.floor(N%3600/60);return P>0?`${P}d ${U}h`:U>0?`${U}h ${j}m`:`${j}m`}const H=Q(()=>p.value?M(p.value.memTotal-p.value.memFree):"—"),R=Q(()=>p.value?M(p.value.memTotal):"—"),V=Q(()=>p.value?$(p.value):0);return ut(async()=>{i.setPage("Dashboard"),t.fetchPlugins();try{o.value=await Ie.system()}catch{}try{const N=await Ie.qr();u.value=N.error??"",N.setupURI&&(c.value=N.pincode??"",l.value=await wa.toDataURL(N.setupURI,{width:148,margin:1,color:{dark:"#000000",light:"#ffffff"}}))}catch{}w(),document.addEventListener("visibilitychange",v)}),Ii(()=>{C==null||C.close(),C=null,document.removeEventListener("visibilitychange",v)}),(N,P)=>{const U=Ge,j=Sl,oe=an,te=L$,ne=Q4,J=oi;return g(),E("div",KR,[b("div",qR,[Y(j,{class:"hk-card"},{default:ee(()=>[P[0]||(P[0]=b("div",{class:"card-title"},"HomeKit Pairing",-1)),b("div",GR,[l.value?(g(),E("div",YR,[b("img",{src:l.value,alt:"HomeKit QR Code",class:"qr-img"},null,8,XR)])):(g(),E("div",JR,[Y(U,{name:ue(HR),size:48},null,8,["name"]),b("span",null,Z(u.value?"HomeKit bridge unavailable":"No HAP bridge configured"),1)])),b("div",QR,[c.value?(g(),E("div",eD,Z(c.value),1)):F("",!0),c.value?(g(),E("div",tD,"Scan to add to HomeKit")):F("",!0),b("div",iD,[b("span",{class:xe(["dot",h.value])},null,2),ce(" "+Z(d.value),1)]),u.value?(g(),E("div",rD,Z(u.value),1)):F("",!0)])])]),_:1}),Y(j,{class:"sys-card"},{default:ee(()=>{var fe;return[P[12]||(P[12]=b("div",{class:"card-title"},"System Information",-1)),o.value?(g(),E("div",sD,[P[1]||(P[1]=b("span",{class:"sys-key"},"OS",-1)),b("span",nD,Z(o.value.os),1),P[2]||(P[2]=b("span",{class:"sys-key"},"Arch",-1)),b("span",aD,Z(o.value.arch),1),P[3]||(P[3]=b("span",{class:"sys-key"},"Hostname",-1)),b("span",oD,Z(o.value.hostname),1),P[4]||(P[4]=b("span",{class:"sys-key"},"IP Address",-1)),b("span",lD,Z(o.value.ip),1),P[5]||(P[5]=b("span",{class:"sys-key"},"User",-1)),b("span",cD,Z(o.value.user),1),P[6]||(P[6]=b("span",{class:"sys-key"},"Node.js",-1)),b("span",uD,Z(o.value.nodeVersion),1),P[7]||(P[7]=b("span",{class:"sys-key"},"OpenBridge",-1)),b("span",hD,"v"+Z(((fe=ue(t).health)==null?void 0:fe.version)??"—"),1),P[8]||(P[8]=b("span",{class:"sys-key"},"Config",-1)),b("span",dD,Z(o.value.configPath),1),P[9]||(P[9]=b("span",{class:"sys-key"},"OB plugins",-1)),b("span",fD,Z(o.value.obPluginsDir),1),P[10]||(P[10]=b("span",{class:"sys-key"},"HB plugins",-1)),b("span",pD,Z(o.value.hbPluginsDir),1)])):(g(),E("div",_D,[Y(U,{name:ue(Fn),size:16},null,8,["name"]),P[11]||(P[11]=ce(" Loading... ",-1))]))]}),_:1}),Y(j,{class:"plugins-card"},{default:ee(()=>[b("div",mD,[P[13]||(P[13]=ce(" Plugins ",-1)),b("span",gD,[Y(oe,{variant:"green"},{default:ee(()=>[ce(Z(ue(t).runningCount)+" running",1)]),_:1}),ue(t).errorCount?(g(),E("span",vD,Z(ue(t).errorCount)+" error",1)):F("",!0)])]),ue(t).plugins.length===0?(g(),E("div",bD,"No plugins loaded yet.")):(g(),E("div",yD,[(g(!0),E(we,null,Be(ue(t).plugins,fe=>(g(),E("div",{key:fe.id,class:"plugin-row"},[b("div",{class:xe(["plugin-dot",fe.status])},null,2),b("span",wD,Z(fe.manifest.name),1),b("span",SD,"v"+Z(fe.manifest.version),1),fe.source==="homebridge"?(g(),de(oe,{key:0,variant:"orange",size:"sm"},{default:ee(()=>[...P[14]||(P[14]=[ce("HB",-1)])]),_:1})):F("",!0),Y(oe,{variant:r(fe.status),size:"sm"},{default:ee(()=>[ce(Z(fe.status),1)]),_:2},1032,["variant"])]))),128))]))]),_:1})]),b("div",CD,[Y(j,{class:"metric-card"},{default:ee(()=>{var fe,re;return[b("div",kD,[b("div",AD,[Y(U,{name:ue(OR),size:13},null,8,["name"])]),P[15]||(P[15]=b("span",{class:"metric-title"},"CPU",-1))]),b("div",MD,[b("div",LD,[ce(Z(((fe=p.value)==null?void 0:fe.cpu)??"—")+" ",1),P[16]||(P[16]=b("span",{class:"metric-unit"},"%",-1))]),(re=p.value)!=null&&re.cpuTemp&&p.value.cpuTemp>0?(g(),E("div",ED,Z(p.value.cpuTemp)+"°C",1)):F("",!0)]),b("div",$D,[Y(te,{data:f.value,color:"var(--nb-c-primary)",height:40},null,8,["data"])])]}),_:1}),Y(j,{class:"metric-card"},{default:ee(()=>[b("div",xD,[b("div",TD,[Y(U,{name:ue(RR),size:13},null,8,["name"])]),P[17]||(P[17]=b("span",{class:"metric-title"},"Memory",-1))]),b("div",ND,[b("div",HD,[ce(Z(V.value)+" ",1),P[18]||(P[18]=b("span",{class:"metric-unit"},"%",-1))]),b("div",PD,Z(H.value)+" / "+Z(R.value),1)]),Y(ne,{value:V.value,max:100,size:"sm"},null,8,["value"]),b("div",OD,[Y(te,{data:m.value,color:"var(--nb-c-info)",height:32},null,8,["data"])])]),_:1}),Y(j,{class:"metric-card"},{default:ee(()=>[b("div",ID,[b("div",RD,[Y(U,{name:ue(VR),size:13},null,8,["name"])]),P[19]||(P[19]=b("span",{class:"metric-title"},"Uptime",-1))]),b("div",DD,[b("div",VD,[b("span",BD,Z(o.value?D(o.value.uptimeSystem):"—"),1),P[20]||(P[20]=b("span",{class:"uptime-label"},"System",-1))]),P[22]||(P[22]=b("div",{class:"uptime-divider"},null,-1)),b("div",ZD,[b("span",FD,Z(o.value?D(o.value.uptimeProcess):"—"),1),P[21]||(P[21]=b("span",{class:"uptime-label"},"Process",-1))])]),b("div",zD,[Y(J,{variant:"secondary",size:"sm",outlined:"",style:{width:"100%","justify-content":"center"},loading:s.value,icon:n.value?Ss:s.value?ul:Qs,onClick:a},{default:ee(()=>[ce(Z(n.value?"Restarted":s.value?"Restarting…":"Restart OpenBridge"),1)]),_:1},8,["loading","icon"])])]),_:1}),Y(j,{class:"metric-card net-card"},{default:ee(()=>[b("div",UD,[b("div",WD,[Y(U,{name:ue(Uu),size:13},null,8,["name"])]),P[23]||(P[23]=b("span",{class:"metric-title"},"Network",-1))]),b("div",jD,[b("div",null,[b("div",KD,Z(p.value?M(p.value.netRxSec)+"/s":"—"),1),P[24]||(P[24]=b("div",{class:"net-label"},"↓ Received",-1))]),b("div",null,[b("div",qD,Z(p.value?M(p.value.netTxSec)+"/s":"—"),1),P[25]||(P[25]=b("div",{class:"net-label"},"↑ Sent",-1))])]),b("div",GD,[Y(te,{data:_.value,color:"var(--nb-c-success)",height:28},null,8,["data"]),Y(te,{data:y.value,color:"var(--nb-c-warning)",height:28},null,8,["data"])])]),_:1})])])}}}),XD=jt(YD,[["__scopeId","data-v-d9b075b5"]]),Ca=(e,t,i)=>{const r=s=>Me("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:t,fill:"currentColor",...s,innerHTML:i});return r.displayName="NbGlyph",r.glyphName=e,r},JD=Ca("arrow-clockwise","0 0 256 256",'<path d="M236,56v48a4,4,0,0,1-4,4H184a4,4,0,0,1,0-8h37.7L187.53,68.69l-.13-.12a84,84,0,1,0-1.75,120.51,4,4,0,0,1,5.5,5.82A91.43,91.43,0,0,1,128,220h-1.26A92,92,0,1,1,193,62.84l35,32.05V56a4,4,0,1,1,8,0Z"/>'),QD=Ca("arrow-clockwise","0 0 256 256",'<path d="M238,56v48a6,6,0,0,1-6,6H184a6,6,0,0,1,0-12h32.55l-30.38-27.8c-.06-.06-.12-.13-.19-.19a82,82,0,1,0-1.7,117.65,6,6,0,0,1,8.24,8.73A93.46,93.46,0,0,1,128,222h-1.28A94,94,0,1,1,194.37,61.4L226,90.35V56a6,6,0,1,1,12,0Z"/>'),u8=Ca("arrow-clockwise","0 0 256 256",'<path d="M240,56v48a8,8,0,0,1-8,8H184a8,8,0,0,1,0-16H211.4L184.81,71.64l-.25-.24a80,80,0,1,0-1.67,114.78,8,8,0,0,1,11,11.63A95.44,95.44,0,0,1,128,224h-1.32A96,96,0,1,1,195.75,60L224,85.8V56a8,8,0,1,1,16,0Z"/>'),eV=Ca("arrow-clockwise","0 0 256 256",'<path d="M244,56v48a12,12,0,0,1-12,12H184a12,12,0,1,1,0-24H201.1l-19-17.38c-.13-.12-.26-.24-.38-.37A76,76,0,1,0,127,204h1a75.53,75.53,0,0,0,52.15-20.72,12,12,0,0,1,16.49,17.45A99.45,99.45,0,0,1,128,228h-1.37A100,100,0,1,1,198.51,57.06L220,76.72V56a12,12,0,0,1,24,0Z"/>'),tV=Ca("arrow-clockwise","0 0 256 256",'<path d="M240,56v48a8,8,0,0,1-8,8H184a8,8,0,0,1-5.66-13.66l17-17-10.55-9.65-.25-.24a80,80,0,1,0-1.67,114.78,8,8,0,1,1,11,11.63A95.44,95.44,0,0,1,128,224h-1.32A96,96,0,1,1,195.75,60l10.93,10L226.34,50.3A8,8,0,0,1,240,56Z"/>'),iV=Ca("arrow-clockwise","0 0 256 256",'<path d="M216,128a88,88,0,1,1-88-88A88,88,0,0,1,216,128Z" opacity="0.2"/><path d="M240,56v48a8,8,0,0,1-8,8H184a8,8,0,0,1,0-16H211.4L184.81,71.64l-.25-.24a80,80,0,1,0-1.67,114.78,8,8,0,0,1,11,11.63A95.44,95.44,0,0,1,128,224h-1.32A96,96,0,1,1,195.75,60L224,85.8V56a8,8,0,1,1,16,0Z"/>'),rV="arrow-clockwise",sV=Object.freeze(Object.defineProperty({__proto__:null,bold:eV,default:u8,duotone:iV,fill:tV,glyphName:rV,light:QD,regular:u8,thin:JD},Symbol.toStringTag,{value:"Module"})),qg=Object.freeze(Object.defineProperty({__proto__:null},Symbol.toStringTag,{value:"Module"})),ka=(e,t,i)=>{const r=s=>Me("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:t,fill:"currentColor",...s,innerHTML:i});return r.displayName="NbGlyph",r.glyphName=e,r},nV=ka("list","0 0 256 256",'<path d="M220,128a4,4,0,0,1-4,4H40a4,4,0,0,1,0-8H216A4,4,0,0,1,220,128ZM40,68H216a4,4,0,0,0,0-8H40a4,4,0,0,0,0,8ZM216,188H40a4,4,0,0,0,0,8H216a4,4,0,0,0,0-8Z"/>'),aV=ka("list","0 0 256 256",'<path d="M222,128a6,6,0,0,1-6,6H40a6,6,0,0,1,0-12H216A6,6,0,0,1,222,128ZM40,70H216a6,6,0,0,0,0-12H40a6,6,0,0,0,0,12ZM216,186H40a6,6,0,0,0,0,12H216a6,6,0,0,0,0-12Z"/>'),h8=ka("list","0 0 256 256",'<path d="M224,128a8,8,0,0,1-8,8H40a8,8,0,0,1,0-16H216A8,8,0,0,1,224,128ZM40,72H216a8,8,0,0,0,0-16H40a8,8,0,0,0,0,16ZM216,184H40a8,8,0,0,0,0,16H216a8,8,0,0,0,0-16Z"/>'),oV=ka("list","0 0 256 256",'<path d="M228,128a12,12,0,0,1-12,12H40a12,12,0,0,1,0-24H216A12,12,0,0,1,228,128ZM40,76H216a12,12,0,0,0,0-24H40a12,12,0,0,0,0,24ZM216,180H40a12,12,0,0,0,0,24H216a12,12,0,0,0,0-24Z"/>'),lV=ka("list","0 0 256 256",'<path d="M208,32H48A16,16,0,0,0,32,48V208a16,16,0,0,0,16,16H208a16,16,0,0,0,16-16V48A16,16,0,0,0,208,32ZM192,184H64a8,8,0,0,1,0-16H192a8,8,0,0,1,0,16Zm0-48H64a8,8,0,0,1,0-16H192a8,8,0,0,1,0,16Zm0-48H64a8,8,0,0,1,0-16H192a8,8,0,0,1,0,16Z"/>'),cV=ka("list","0 0 256 256",'<path d="M216,64V192H40V64Z" opacity="0.2"/><path d="M224,128a8,8,0,0,1-8,8H40a8,8,0,0,1,0-16H216A8,8,0,0,1,224,128ZM40,72H216a8,8,0,0,0,0-16H40a8,8,0,0,0,0,16ZM216,184H40a8,8,0,0,0,0,16H216a8,8,0,0,0,0-16Z"/>'),uV="list",Gg=Object.freeze(Object.defineProperty({__proto__:null,bold:oV,default:h8,duotone:cV,fill:lV,glyphName:uV,light:aV,regular:h8,thin:nV},Symbol.toStringTag,{value:"Module"})),Aa=(e,t,i)=>{const r=s=>Me("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:t,fill:"currentColor",...s,innerHTML:i});return r.displayName="NbGlyph",r.glyphName=e,r},hV=Aa("squares-four","0 0 256 256",'<path d="M104,44H56A12,12,0,0,0,44,56v48a12,12,0,0,0,12,12h48a12,12,0,0,0,12-12V56A12,12,0,0,0,104,44Zm4,60a4,4,0,0,1-4,4H56a4,4,0,0,1-4-4V56a4,4,0,0,1,4-4h48a4,4,0,0,1,4,4Zm92-60H152a12,12,0,0,0-12,12v48a12,12,0,0,0,12,12h48a12,12,0,0,0,12-12V56A12,12,0,0,0,200,44Zm4,60a4,4,0,0,1-4,4H152a4,4,0,0,1-4-4V56a4,4,0,0,1,4-4h48a4,4,0,0,1,4,4ZM104,140H56a12,12,0,0,0-12,12v48a12,12,0,0,0,12,12h48a12,12,0,0,0,12-12V152A12,12,0,0,0,104,140Zm4,60a4,4,0,0,1-4,4H56a4,4,0,0,1-4-4V152a4,4,0,0,1,4-4h48a4,4,0,0,1,4,4Zm92-60H152a12,12,0,0,0-12,12v48a12,12,0,0,0,12,12h48a12,12,0,0,0,12-12V152A12,12,0,0,0,200,140Zm4,60a4,4,0,0,1-4,4H152a4,4,0,0,1-4-4V152a4,4,0,0,1,4-4h48a4,4,0,0,1,4,4Z"/>'),dV=Aa("squares-four","0 0 256 256",'<path d="M104,42H56A14,14,0,0,0,42,56v48a14,14,0,0,0,14,14h48a14,14,0,0,0,14-14V56A14,14,0,0,0,104,42Zm2,62a2,2,0,0,1-2,2H56a2,2,0,0,1-2-2V56a2,2,0,0,1,2-2h48a2,2,0,0,1,2,2Zm94-62H152a14,14,0,0,0-14,14v48a14,14,0,0,0,14,14h48a14,14,0,0,0,14-14V56A14,14,0,0,0,200,42Zm2,62a2,2,0,0,1-2,2H152a2,2,0,0,1-2-2V56a2,2,0,0,1,2-2h48a2,2,0,0,1,2,2Zm-98,34H56a14,14,0,0,0-14,14v48a14,14,0,0,0,14,14h48a14,14,0,0,0,14-14V152A14,14,0,0,0,104,138Zm2,62a2,2,0,0,1-2,2H56a2,2,0,0,1-2-2V152a2,2,0,0,1,2-2h48a2,2,0,0,1,2,2Zm94-62H152a14,14,0,0,0-14,14v48a14,14,0,0,0,14,14h48a14,14,0,0,0,14-14V152A14,14,0,0,0,200,138Zm2,62a2,2,0,0,1-2,2H152a2,2,0,0,1-2-2V152a2,2,0,0,1,2-2h48a2,2,0,0,1,2,2Z"/>'),d8=Aa("squares-four","0 0 256 256",'<path d="M104,40H56A16,16,0,0,0,40,56v48a16,16,0,0,0,16,16h48a16,16,0,0,0,16-16V56A16,16,0,0,0,104,40Zm0,64H56V56h48v48Zm96-64H152a16,16,0,0,0-16,16v48a16,16,0,0,0,16,16h48a16,16,0,0,0,16-16V56A16,16,0,0,0,200,40Zm0,64H152V56h48v48Zm-96,32H56a16,16,0,0,0-16,16v48a16,16,0,0,0,16,16h48a16,16,0,0,0,16-16V152A16,16,0,0,0,104,136Zm0,64H56V152h48v48Zm96-64H152a16,16,0,0,0-16,16v48a16,16,0,0,0,16,16h48a16,16,0,0,0,16-16V152A16,16,0,0,0,200,136Zm0,64H152V152h48v48Z"/>'),fV=Aa("squares-four","0 0 256 256",'<path d="M100,36H56A20,20,0,0,0,36,56v44a20,20,0,0,0,20,20h44a20,20,0,0,0,20-20V56A20,20,0,0,0,100,36ZM96,96H60V60H96ZM200,36H156a20,20,0,0,0-20,20v44a20,20,0,0,0,20,20h44a20,20,0,0,0,20-20V56A20,20,0,0,0,200,36Zm-4,60H160V60h36Zm-96,40H56a20,20,0,0,0-20,20v44a20,20,0,0,0,20,20h44a20,20,0,0,0,20-20V156A20,20,0,0,0,100,136Zm-4,60H60V160H96Zm104-60H156a20,20,0,0,0-20,20v44a20,20,0,0,0,20,20h44a20,20,0,0,0,20-20V156A20,20,0,0,0,200,136Zm-4,60H160V160h36Z"/>'),pV=Aa("squares-four","0 0 256 256",'<path d="M120,56v48a16,16,0,0,1-16,16H56a16,16,0,0,1-16-16V56A16,16,0,0,1,56,40h48A16,16,0,0,1,120,56Zm80-16H152a16,16,0,0,0-16,16v48a16,16,0,0,0,16,16h48a16,16,0,0,0,16-16V56A16,16,0,0,0,200,40Zm-96,96H56a16,16,0,0,0-16,16v48a16,16,0,0,0,16,16h48a16,16,0,0,0,16-16V152A16,16,0,0,0,104,136Zm96,0H152a16,16,0,0,0-16,16v48a16,16,0,0,0,16,16h48a16,16,0,0,0,16-16V152A16,16,0,0,0,200,136Z"/>'),_V=Aa("squares-four","0 0 256 256",'<path d="M112,56v48a8,8,0,0,1-8,8H56a8,8,0,0,1-8-8V56a8,8,0,0,1,8-8h48A8,8,0,0,1,112,56Zm88-8H152a8,8,0,0,0-8,8v48a8,8,0,0,0,8,8h48a8,8,0,0,0,8-8V56A8,8,0,0,0,200,48Zm-96,96H56a8,8,0,0,0-8,8v48a8,8,0,0,0,8,8h48a8,8,0,0,0,8-8V152A8,8,0,0,0,104,144Zm96,0H152a8,8,0,0,0-8,8v48a8,8,0,0,0,8,8h48a8,8,0,0,0,8-8V152A8,8,0,0,0,200,144Z" opacity="0.2"/><path d="M200,136H152a16,16,0,0,0-16,16v48a16,16,0,0,0,16,16h48a16,16,0,0,0,16-16V152A16,16,0,0,0,200,136Zm0,64H152V152h48v48ZM104,40H56A16,16,0,0,0,40,56v48a16,16,0,0,0,16,16h48a16,16,0,0,0,16-16V56A16,16,0,0,0,104,40Zm0,64H56V56h48v48Zm96-64H152a16,16,0,0,0-16,16v48a16,16,0,0,0,16,16h48a16,16,0,0,0,16-16V56A16,16,0,0,0,200,40Zm0,64H152V56h48v48Zm-96,32H56a16,16,0,0,0-16,16v48a16,16,0,0,0,16,16h48a16,16,0,0,0,16-16V152A16,16,0,0,0,104,136Zm0,64H56V152h48v48Z"/>'),mV="squares-four",Yg=Object.freeze(Object.defineProperty({__proto__:null,bold:fV,default:d8,duotone:_V,fill:pV,glyphName:mV,light:dV,regular:d8,thin:hV},Symbol.toStringTag,{value:"Module"})),gV={key:0,class:"plugin-cards"},vV={class:"plugin-avatar"},bV=["src","alt"],yV={class:"plugin-meta"},wV={class:"plugin-name"},SV={key:0,class:"plugin-platform"},CV={class:"plugin-version"},kV={key:0,class:"plugin-desc"},AV={key:1,class:"plugin-author"},MV={key:2,class:"plugin-links"},LV=["href"],EV=["href"],$V={key:3,class:"plugin-error"},xV={class:"cell-name"},TV={class:"plugin-avatar plugin-avatar--sm"},NV=["src","alt"],HV={class:"plugin-name"},PV={key:0,class:"plugin-platform"},OV=Re({__name:"PluginList",props:{rows:{},view:{},selectedId:{}},emits:["select"],setup(e,{emit:t}){const i=e,r=t;function s(l){return l==="running"?"green":l==="error"?"red":l==="loading"?"blue":"grey"}const n=X({key:"name",direction:"asc"}),a=[{key:"name",header:"Plugin",sortable:!0},{key:"version",header:"Version",sortable:!0,width:140},{key:"source",header:"Source",sortable:!0,width:120},{key:"status",header:"Status",sortable:!0,width:120},{key:"author",header:"Author",sortable:!0}],o=Q(()=>{const l=i.rows.map(h=>({id:h.plugin.id,name:h.plugin.manifest.name,version:`v${h.plugin.manifest.version}`,availableUpdate:h.plugin.availableUpdate,source:h.plugin.source==="homebridge"?"Homebridge":"Native",status:h.plugin.status,author:h.plugin.manifest.author??"—",platform:h.plugin.source==="homebridge"?h.plugin.platformName:void 0,avatarUrl:h.avatarUrl,isOpenBridge:h.isOpenBridge,plugin:h.plugin})),c=n.value;if(!c||c.direction==="none")return l;const u=c.direction==="asc"?1:-1;return[...l].sort((h,d)=>u*String(h[c.key]??"").localeCompare(String(d[c.key]??"")))});return(l,c)=>{const u=Ge,h=an,d=Qi,f=Sl,m=K4;return e.view==="cards"?(g(),E("div",gV,[(g(!0),E(we,null,Be(e.rows,_=>(g(),de(f,{key:_.plugin.id,class:xe(["plugin-card",{"plugin-card--selected":_.plugin.id===e.selectedId}]),onClick:y=>r("select",_.plugin)},{default:ee(()=>[b("span",{class:xe(["plugin-card__accent",`plugin-card__accent--${_.plugin.status}`])},null,2),Y(d,{dir:"row",align:"start",gap:"sm",class:"plugin-card__header"},{default:ee(()=>[b("div",vV,[_.avatarUrl?(g(),E("img",{key:0,src:_.avatarUrl,alt:_.plugin.manifest.name,onError:c[0]||(c[0]=y=>y.target.style.display="none")},null,40,bV)):(g(),de(u,{key:1,name:_.isOpenBridge?ue(kn):ue(rn),size:20},null,8,["name"]))]),b("div",yV,[b("div",wV,Z(_.plugin.manifest.name),1),_.plugin.source==="homebridge"&&_.plugin.platformName?(g(),E("div",SV," Platform: "+Z(_.plugin.platformName),1)):F("",!0),b("div",CV,[ce(" v"+Z(_.plugin.manifest.version)+" ",1),_.plugin.availableUpdate?(g(),de(h,{key:0,variant:"blue",size:"sm"},{default:ee(()=>[ce(" v"+Z(_.plugin.availableUpdate)+" available ",1)]),_:2},1024)):F("",!0)])]),Y(h,{variant:s(_.plugin.status)},{default:ee(()=>[ce(Z(_.plugin.status),1)]),_:2},1032,["variant"])]),_:2},1024),_.plugin.manifest.description?(g(),E("p",kV,Z(_.plugin.manifest.description),1)):F("",!0),_.plugin.manifest.author?(g(),E("p",AV,"by "+Z(_.plugin.manifest.author),1)):F("",!0),_.sponsorUrl||_.docsUrl?(g(),E("div",MV,[_.sponsorUrl?(g(),E("a",{key:0,href:_.sponsorUrl,target:"_blank",rel:"noopener",onClick:c[1]||(c[1]=at(()=>{},["stop"]))},[Y(u,{name:ue(Wg),weight:"fill",size:11},null,8,["name"]),c[6]||(c[6]=ce(" Sponsor ",-1))],8,LV)):F("",!0),_.docsUrl?(g(),E("a",{key:1,href:_.docsUrl,target:"_blank",rel:"noopener",onClick:c[2]||(c[2]=at(()=>{},["stop"]))},[Y(u,{name:ue(jg),size:11},null,8,["name"]),c[7]||(c[7]=ce(" Docs ",-1))],8,EV)):F("",!0)])):F("",!0),_.plugin.error?(g(),E("div",$V,Z(_.plugin.error),1)):F("",!0)]),_:2},1032,["class","onClick"]))),128))])):(g(),de(m,{key:1,columns:a,rows:o.value,"row-key":"id",size:"sm",zebra:"","sort-state":n.value,onSort:c[4]||(c[4]=_=>n.value=_),onRowClick:c[5]||(c[5]=_=>r("select",_.plugin))},{"cell-name":ee(({row:_})=>[b("div",xV,[b("div",TV,[_.avatarUrl?(g(),E("img",{key:0,src:_.avatarUrl,alt:_.name,onError:c[3]||(c[3]=y=>y.target.style.display="none")},null,40,NV)):(g(),de(u,{key:1,name:_.isOpenBridge?ue(kn):ue(rn),size:14},null,8,["name"]))]),b("div",null,[b("div",HV,Z(_.name),1),_.platform?(g(),E("div",PV,"Platform: "+Z(_.platform),1)):F("",!0)])])]),"cell-version":ee(({row:_})=>[ce(Z(_.version)+" ",1),_.availableUpdate?(g(),de(h,{key:0,variant:"blue",size:"sm"},{default:ee(()=>[ce("v"+Z(_.availableUpdate),1)]),_:2},1024)):F("",!0)]),"cell-status":ee(({row:_})=>[Y(h,{variant:s(_.status)},{default:ee(()=>[ce(Z(_.status),1)]),_:2},1032,["variant"])]),_:1},8,["rows","sort-state"]))}}}),IV=jt(OV,[["__scopeId","data-v-8fdf7ec9"]]),RV={class:"plugins-view"},DV={key:0,class:"empty-state"},VV={key:0},f8="openbridge.plugins.view",BV=Re({__name:"PluginsView",setup(e){const t=xs(),i=kl(),r=ln(),s=Kg(),n=X(""),a=X(new Map),o=X(new Set),l=X(!1),c=X(localStorage.getItem(f8)==="table"?"table":"cards");function u(){c.value=c.value==="cards"?"table":"cards",localStorage.setItem(f8,c.value)}const h=Q(()=>{var H;return i.visible&&i.mode==="plugin"?((H=i.selectedPlugin)==null?void 0:H.id)??null:null}),d=Q(()=>_().map(H=>{const R=C(H);return{plugin:H,avatarUrl:$(H),isOpenBridge:p(H),sponsorUrl:R==null?void 0:R.githubSponsorsUrl,docsUrl:R==null?void 0:R.documentationUrl}}));function f(H){if(H.source==="homebridge"){const V=(H.manifest.description??"").match(/Homebridge platform:\s*([^\s]+)/);if(V!=null&&V[1])return V[1]}return H.manifest.name}function m(H){var P;const V=(P=(H.manifest.description??"").match(/Homebridge platform:\s*([^\s]+)/))==null?void 0:P[1],N=[f(H),V,H.manifest.name,H.id];return Array.from(new Set(N.filter(U=>!!U&&U.trim().length>0)))}function _(){const H=n.value.toLowerCase();return t.plugins.filter(R=>R.manifest.name.toLowerCase().includes(H)||(R.manifest.description??"").toLowerCase().includes(H))}function y(H){var R;((R=i.selectedPlugin)==null?void 0:R.id)===H.id&&i.visible&&i.mode==="plugin"?i.close():i.openPlugin(H)}function p(H){return H.manifest.name.includes("openbridge-")||H.source==="native"}function C(H){const R=m(H);for(const V of R){const N=a.value.get(V);if(N)return N}if(H.enrichedMetadata)return H.enrichedMetadata}async function w(H,R=!1){var N;const V=m(H);for(const P of V)if(!(!R&&a.value.has(P))&&!(!R&&o.value.has(P))){o.value.add(P);try{const U=await Ie.marketplace.enriched(P),j=new Map(a.value);if(j.set(P,U),j.set(f(H),U),a.value=j,H.enrichedMetadata=U,U.documentationUrl||U.githubSponsorsUrl||(N=U.links)!=null&&N.repository)return}catch{}finally{const U=new Set(o.value);U.delete(P),o.value=U}}}const v=X(new Map);function k(H){const V=H.trim().replace(/^github:/,"https://github.com/").replace(/^git\+/,"").replace(/^git@github\.com:/,"https://github.com/").match(/github\.com[/:]([^/]+)/);return V?`https://github.com/${V[1]}.png?size=48`:null}function $(H){var P,U;const R=C(H),V=((P=R==null?void 0:R.links)==null?void 0:P.repository)??((U=R==null?void 0:R.links)==null?void 0:U.homepage)??"";if(V){const j=k(V);if(j)return j}const N=m(H);for(const j of N){const oe=v.value.get(j);if(oe)return oe}return null}async function M(H,R=!1){var V;if(!(!R&&v.value.has(H)))try{const N=await fetch(`https://registry.npmjs.org/${encodeURIComponent(H)}/latest`,{signal:AbortSignal.timeout(5e3)});if(!N.ok){v.value.set(H,"");return}const P=await N.json(),U=((V=P==null?void 0:P.repository)==null?void 0:V.url)??(P==null?void 0:P.homepage)??"";v.value.set(H,k(U)??"")}catch{v.value.set(H,"")}}async function D(H=!1){if(!l.value){l.value=!0;try{H&&(a.value=new Map,v.value=new Map);const R=t.plugins;for(const V of R){const N=m(V);for(const P of N)await M(P,H);await w(V,H)}H&&s.success("Plugin metadata refreshed")}catch{s.error("Failed to refresh plugin metadata")}finally{l.value=!1}}}return ut(async()=>{await t.fetchPlugins()}),Fe(()=>t.plugins.length,H=>{r.setPage("Plugins",H)},{immediate:!0}),(H,R)=>{const V=ha,N=oi,P=Ge;return g(),E("div",RV,[(g(),de(br,{defer:"",to:"#ob-topbar-right"},[Y(V,{modelValue:n.value,"onUpdate:modelValue":R[0]||(R[0]=U=>n.value=U),placeholder:"Search plugins...",size:"sm",style:{width:"200px"}},null,8,["modelValue"]),Y(N,{variant:"ghost",size:"sm",icon:sV,title:"Refresh metadata",loading:l.value,disabled:l.value,onClick:R[1]||(R[1]=U=>D(!0))},null,8,["loading","disabled"]),Y(N,{variant:"ghost",size:"sm",icon:c.value===qg?Gg:Yg,title:c.value==="cards"?"Show as table":"Show as cards",onClick:u},null,8,["icon","title"]),Y(N,{variant:"primary",size:"sm",icon:Of,onClick:R[2]||(R[2]=U=>ue(i).openMarketplace())},{default:ee(()=>[...R[5]||(R[5]=[ce(" Browse plugins ",-1)])]),_:1})])),d.value.length===0?(g(),E("div",DV,[Y(P,{name:ue(rn),size:40},null,8,["name"]),n.value?(g(),E("p",VV,'No plugins matching "'+Z(n.value)+'"',1)):(g(),E(we,{key:1},[R[7]||(R[7]=b("p",null,"No plugins loaded yet.",-1)),Y(N,{variant:"primary",size:"sm",icon:Of,onClick:R[3]||(R[3]=U=>ue(i).openMarketplace())},{default:ee(()=>[...R[6]||(R[6]=[ce(" Browse & install plugins ",-1)])]),_:1})],64))])):(g(),E("div",{key:1,class:"plugins-body",onClick:R[4]||(R[4]=at(U=>ue(i).close(),["self"]))},[Y(IV,{rows:d.value,view:c.value,"selected-id":h.value,onSelect:y},null,8,["rows","view","selected-id"])]))])}}}),ZV=jt(BV,[["__scopeId","data-v-95e3ebc4"]]),Ma=(e,t,i)=>{const r=s=>Me("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:t,fill:"currentColor",...s,innerHTML:i});return r.displayName="NbGlyph",r.glyphName=e,r},FV=Ma("devices","0 0 256 256",'<path d="M224,76H204V64a20,20,0,0,0-20-20H40A20,20,0,0,0,20,64v96a20,20,0,0,0,20,20H156v12a20,20,0,0,0,20,20h48a20,20,0,0,0,20-20V96A20,20,0,0,0,224,76ZM40,172a12,12,0,0,1-12-12V64A12,12,0,0,1,40,52H184a12,12,0,0,1,12,12V76H176a20,20,0,0,0-20,20v76Zm196,20a12,12,0,0,1-12,12H176a12,12,0,0,1-12-12V96a12,12,0,0,1,12-12h48a12,12,0,0,1,12,12ZM132,208a4,4,0,0,1-4,4H88a4,4,0,0,1,0-8h40A4,4,0,0,1,132,208Zm80-96a4,4,0,0,1-4,4H192a4,4,0,0,1,0-8h16A4,4,0,0,1,212,112Z"/>'),zV=Ma("devices","0 0 256 256",'<path d="M224,74H206V64a22,22,0,0,0-22-22H40A22,22,0,0,0,18,64v96a22,22,0,0,0,22,22H154v10a22,22,0,0,0,22,22h48a22,22,0,0,0,22-22V96A22,22,0,0,0,224,74ZM40,170a10,10,0,0,1-10-10V64A10,10,0,0,1,40,54H184a10,10,0,0,1,10,10V74H176a22,22,0,0,0-22,22v74Zm194,22a10,10,0,0,1-10,10H176a10,10,0,0,1-10-10V96a10,10,0,0,1,10-10h48a10,10,0,0,1,10,10ZM134,208a6,6,0,0,1-6,6H88a6,6,0,0,1,0-12h40A6,6,0,0,1,134,208Zm80-96a6,6,0,0,1-6,6H192a6,6,0,0,1,0-12h16A6,6,0,0,1,214,112Z"/>'),Wu=Ma("devices","0 0 256 256",'<path d="M224,72H208V64a24,24,0,0,0-24-24H40A24,24,0,0,0,16,64v96a24,24,0,0,0,24,24H152v8a24,24,0,0,0,24,24h48a24,24,0,0,0,24-24V96A24,24,0,0,0,224,72ZM40,168a8,8,0,0,1-8-8V64a8,8,0,0,1,8-8H184a8,8,0,0,1,8,8v8H176a24,24,0,0,0-24,24v72Zm192,24a8,8,0,0,1-8,8H176a8,8,0,0,1-8-8V96a8,8,0,0,1,8-8h48a8,8,0,0,1,8,8Zm-96,16a8,8,0,0,1-8,8H88a8,8,0,0,1,0-16h40A8,8,0,0,1,136,208Zm80-96a8,8,0,0,1-8,8H192a8,8,0,0,1,0-16h16A8,8,0,0,1,216,112Z"/>'),UV=Ma("devices","0 0 256 256",'<path d="M224,72H212V64a28,28,0,0,0-28-28H40A28,28,0,0,0,12,64v88a28,28,0,0,0,28,28h96v12a28,28,0,0,0,28,28h60a28,28,0,0,0,28-28V100A28,28,0,0,0,224,72ZM40,156a4,4,0,0,1-4-4V64a4,4,0,0,1,4-4H184a4,4,0,0,1,4,4v8H164a28,28,0,0,0-28,28v56Zm188,36a4,4,0,0,1-4,4H164a4,4,0,0,1-4-4V100a4,4,0,0,1,4-4h60a4,4,0,0,1,4,4ZM124,208a12,12,0,0,1-12,12H88a12,12,0,0,1,0-24h24A12,12,0,0,1,124,208Zm88-84a12,12,0,0,1-12,12H188a12,12,0,0,1,0-24h12A12,12,0,0,1,212,124Z"/>'),WV=Ma("devices","0 0 256 256",'<path d="M224,72H208V64a24,24,0,0,0-24-24H40A24,24,0,0,0,16,64v96a24,24,0,0,0,24,24H152v8a24,24,0,0,0,24,24h48a24,24,0,0,0,24-24V96A24,24,0,0,0,224,72Zm8,120a8,8,0,0,1-8,8H176a8,8,0,0,1-8-8V96a8,8,0,0,1,8-8h48a8,8,0,0,1,8,8Zm-96,16a8,8,0,0,1-8,8H88a8,8,0,0,1,0-16h40A8,8,0,0,1,136,208Zm80-96a8,8,0,0,1-8,8H192a8,8,0,0,1,0-16h16A8,8,0,0,1,216,112Z"/>'),jV=Ma("devices","0 0 256 256",'<path d="M200,64V80H176a16,16,0,0,0-16,16v80H40a16,16,0,0,1-16-16V64A16,16,0,0,1,40,48H184A16,16,0,0,1,200,64Z" opacity="0.2"/><path d="M224,72H208V64a24,24,0,0,0-24-24H40A24,24,0,0,0,16,64v96a24,24,0,0,0,24,24H152v8a24,24,0,0,0,24,24h48a24,24,0,0,0,24-24V96A24,24,0,0,0,224,72ZM40,168a8,8,0,0,1-8-8V64a8,8,0,0,1,8-8H184a8,8,0,0,1,8,8v8H176a24,24,0,0,0-24,24v72Zm192,24a8,8,0,0,1-8,8H176a8,8,0,0,1-8-8V96a8,8,0,0,1,8-8h48a8,8,0,0,1,8,8Zm-96,16a8,8,0,0,1-8,8H88a8,8,0,0,1,0-16h40A8,8,0,0,1,136,208Zm80-96a8,8,0,0,1-8,8H192a8,8,0,0,1,0-16h16A8,8,0,0,1,216,112Z"/>'),KV="devices",qV=Object.freeze(Object.defineProperty({__proto__:null,bold:UV,default:Wu,duotone:jV,fill:WV,glyphName:KV,light:zV,regular:Wu,thin:FV},Symbol.toStringTag,{value:"Module"})),GV={class:"devices-view"},YV={class:"toolbar-count"},XV={key:1,class:"empty-state"},JV={class:"device-icon native-icon"},QV={class:"device-info"},eB={class:"device-name"},tB={class:"device-type"},iB={class:"device-summary"},rB={key:0,class:"summary-primary"},sB={class:"summary-primary"},nB={key:0,class:"summary-secondary"},aB={key:2,class:"summary-primary"},oB=["title"],lB={class:"device-info"},cB={class:"device-name"},uB={class:"device-type"},hB={key:0,class:"device-summary"},dB={class:"summary-primary"},fB=["title"],pB=["title"],_B={key:1},mB={class:"confirm-dialog"},gB={class:"confirm-icon"},vB={class:"confirm-message"},bB={class:"confirm-actions"},p8="openbridge.devices.view",yB=Re({__name:"DevicesView",setup(e){const t=xs(),i=kl(),r=Cl();function s(x){var T;return((T=x.health)==null?void 0:T.status)==="stale"}function n(x){return x<90?`${Math.round(x)} seconds`:x<5400?`${Math.round(x/60)} minutes`:x<172800?`${Math.round(x/3600)} hours`:`${Math.round(x/86400)} days`}function a(x){const T=x.health;if(!T||T.status!=="stale")return"";const K=["Not responding"];return T.silentForSeconds!==null?K.push(`Silent for ${n(T.silentForSeconds)}.`):T.lastSeen&&K.push(`Last seen ${new Date(T.lastSeen).toLocaleString()}.`),T.reason&&K.push(T.reason),K.push("OpenBridge is running: the device itself is not answering. Check it is powered and reachable at its configured address.","Click to open it for its address, readings and recent events."),K.join(`
|
|
68
|
-
`)}const o=["Not responding","HomeKit reports this accessory as unreachable. Check it is powered and on the network.","Click to open it for its services and characteristics."].join(`
|
|
69
|
-
`);function l(x){var K;const T=(K=x.health)==null?void 0:K.status;return T==="ok"?"online":T==="stale"?"stale":"offline"}function c(x){var K;const T=(K=x.health)==null?void 0:K.status;return T==="ok"?"Responding":T==="stale"?"Not responding":"No data yet"}function u(x){r.push({name:"device-detail",params:{id:x.id}})}const h=ln(),d=X(!1),f=X([]),m=X(localStorage.getItem(p8)==="table"?"table":"cards");function _(){m.value=m.value==="cards"?"table":"cards",localStorage.setItem(p8,m.value)}const y=X({key:"name",direction:"asc"}),p=[{key:"name",header:"Device",sortable:!0},{key:"type",header:"Type",sortable:!0,width:160},{key:"source",header:"Source",sortable:!0,width:120},{key:"state",header:"State",sortable:!0,width:120},{key:"detail",header:"Reading",sortable:!0,width:160}],C=Q(()=>{const x=[...f.value.map(se=>({key:"native:"+se.id,name:se.name,type:P(v(se)),source:"Native",state:se.telemetry.active===void 0?"":se.telemetry.active?"On":"Off",stateOn:!!se.telemetry.active,detail:w(se),icon:N(v(se)),unhealthy:s(se),healthTooltip:a(se),select:()=>M(se)})),...t.accessories.map(se=>{const he=te(se);return{key:"hap:"+se.uuid,name:se.displayName,type:H(se.category).label,source:"HomeKit",state:se.reachable?he?he.value?"On":"Off":"":"Not responding",stateOn:se.reachable&&!!(he!=null&&he.value),detail:ne(se)??"",icon:H(se.category).icon,unhealthy:!se.reachable,healthTooltip:se.reachable?"":o,select:()=>$(se)}})],T=y.value;if(!T||T.direction==="none")return x;const K=T.direction==="asc"?1:-1;return[...x].sort((se,he)=>K*String(se[T.key]??"").localeCompare(String(he[T.key]??"")))});function w(x){const T=x.telemetry;return x.widgetType==="energy_meter"&&T.power!==void 0?`${fe(T.power,1)} W`:x.widgetType==="thermostat"&&T.currentTemperature!==void 0?`${fe(T.currentTemperature,1)}°C`:x.widgetType==="dehumidifier"&&T.currentHumidity!==void 0?`${fe(T.currentHumidity,0)}%`:T.power!==void 0?`${fe(T.power,1)} W`:""}function v(x){return x.homekitType||x.widgetType}const k=Q(()=>i.mode!=="device"||!i.selectedDevice?null:i.selectedDevice.kind==="native"?i.selectedDevice.dev.id:i.selectedDevice.acc.uuid);function $(x){k.value===x.uuid?i.close():i.openDevice({kind:"hap",acc:x})}function M(x){k.value===x.id?i.close():i.openDevice({kind:"native",dev:x})}const D={1:{label:"Other",icon:"cube"},2:{label:"Bridge",icon:"intersect"},3:{label:"Fan",icon:"fan"},4:{label:"Garage Door",icon:"garage"},5:{label:"Light",icon:"lightbulb"},6:{label:"Lock",icon:"lock"},7:{label:"Outlet",icon:"plugs"},8:{label:"Switch",icon:"toggle-right"},9:{label:"Thermostat",icon:"thermometer"},10:{label:"Sensor",icon:"pulse"},11:{label:"Security",icon:"shield"},12:{label:"Door",icon:"door"},13:{label:"Window",icon:"app-window"},14:{label:"Window Covering",icon:"rows"},15:{label:"Programm. Switch",icon:"sliders"},16:{label:"Range Extender",icon:"broadcast"},17:{label:"Camera",icon:"camera"},18:{label:"Video Doorbell",icon:"bell"},19:{label:"Air Purifier",icon:"wind"},20:{label:"Heater/Cooler",icon:"thermometer-hot"},21:{label:"Air Conditioner",icon:"snowflake"},22:{label:"Humidifier",icon:"drop"},23:{label:"Dehumidifier",icon:"drop"},26:{label:"Speaker",icon:"speaker-high"},28:{label:"Sprinkler",icon:"drop"},29:{label:"Faucet",icon:"drop"},30:{label:"Shower",icon:"drop"},32:{label:"TV",icon:"television"},34:{label:"Router",icon:"broadcast"},36:{label:"Target Control",icon:"game-controller"},38:{label:"Smart Speaker",icon:"speaker-hifi"}};function H(x){return D[x]??{label:`Category ${x}`,icon:"cube"}}const R={switch:"plugs",light:"lightbulb",thermostat:"thermometer",dehumidifier:"drop",energy_meter:"lightning",gate:"garage",sensor:"pulse",camera:"camera"},V={camera:"Camera",switch:"Switch",light:"Light",thermostat:"Thermostat",dehumidifier:"Dehumidifier",energy_meter:"Energy Meter",gate:"Gate",sensor:"Sensor"};function N(x){return R[x]??"cube"}function P(x){return V[x]??x}const U=new Set(["AccessoryInformation","0000003E-0000-1000-8000-0026BB765291","ProtocolInformation","000000A2-0000-1000-8000-0026BB765291"]),j=new Set(["On","Active","LockTargetState","TargetDoorState"]);function oe(x){return x.services.find(T=>!U.has(T.name)&&!U.has(T.uuid))}function te(x){const T=oe(x);return T?T.characteristics.find(K=>j.has(K.name)&&K.perms.includes("pw"))??null:null}function ne(x){if(!x.reachable)return"Not responding";const T=oe(x);if(!T)return null;for(const se of T.characteristics){if(se.name==="CurrentTemperature"&&se.value!=null)return`${Number(se.value).toFixed(1)}°C`;if(se.name==="CurrentRelativeHumidity"&&se.value!=null)return`${Math.round(Number(se.value))}%`;if(se.name==="CurrentPosition"&&se.value!=null)return`${Math.round(Number(se.value))}%`;if(se.name==="Brightness"&&se.value!=null)return`${Math.round(Number(se.value))}%`}const K=T.characteristics.find(se=>se.name==="On");return K?K.value?"On":"Off":null}async function J(x,T){const K=oe(x),se=te(x);if(!(!K||!se))try{await Ie.setCharacteristic(x.uuid,K.uuid,se.uuid,T?1:0),await t.fetchAccessories()}catch(he){console.error("HAP control failed",he)}}function fe(x,T=1){if(x==null)return"—";const K=Number(x);return isFinite(K)?K.toFixed(T):String(x)}const re=Q(()=>t.accessories.length+f.value.length);async function _e(){var x;try{const T=await Ie.devices();if(f.value=T.devices,i.mode==="device"&&((x=i.selectedDevice)==null?void 0:x.kind)==="native"){const K=i.selectedDevice.dev.id,se=T.devices.find(he=>he.id===K);se&&i.updateDevice({kind:"native",dev:se})}}catch{}}async function Ne(){d.value=!0,await Promise.all([t.fetchAccessories(),_e()]),d.value=!1}let $e=null;const be=X({visible:!1,deviceId:"",control:"",value:null,message:""});function me(x,T,K){return x.widgetType==="energy_meter"&&T==="active"?K?`Turn on ${x.name}? This will energise the connected circuit.`:`Turn off ${x.name}? This will cut power to the connected circuit.`:!1}async function O(x,T,K){try{await Ie.controlDevice(x,T,K),await _e()}catch(se){console.error("Control failed",se)}}function ie(x,T,K){const se=me(x,T,K);se?be.value={visible:!0,deviceId:x.id,control:T,value:K,message:se}:O(x.id,T,K)}function le(){const{deviceId:x,control:T,value:K}=be.value;be.value.visible=!1,O(x,T,K)}function ge(){be.value.visible=!1}async function Se(){var x;if(await Promise.all([t.fetchAccessories(),_e()]),i.mode==="device"&&((x=i.selectedDevice)==null?void 0:x.kind)==="hap"){const T=i.selectedDevice.acc.uuid,K=t.accessories.find(se=>se.uuid===T);K&&i.updateDevice({kind:"hap",acc:K})}}return ut(async()=>{h.setPage("Devices"),await Se(),$e=setInterval(Se,3e3)}),Ii(()=>{$e&&clearInterval($e)}),(x,T)=>{const K=an,se=oi,he=Ge,pe=Sc,S=Cd,A=Sl,B=K4;return g(),E("div",GV,[re.value>0?(g(),de(br,{key:0,defer:"",to:"#ob-topbar-left"},[b("span",YV,Z(re.value)+" device"+Z(re.value!==1?"s":""),1),f.value.length>0?(g(),de(K,{key:0},{default:ee(()=>[ce(Z(f.value.length)+" native",1)]),_:1})):F("",!0)])):F("",!0),(g(),de(br,{defer:"",to:"#ob-topbar-right"},[Y(se,{variant:"ghost",size:"sm",icon:m.value===qg?Gg:Yg,title:m.value==="cards"?"Show as table":"Show as cards",onClick:_},null,8,["icon","title"]),Y(se,{variant:"ghost",size:"sm",icon:Qs,title:"Refresh",loading:d.value,onClick:Ne},null,8,["loading"])])),re.value===0?(g(),E("div",XV,[Y(he,{name:ue(Wu),size:40},null,8,["name"]),T[8]||(T[8]=b("p",null,"No devices registered yet.",-1)),T[9]||(T[9]=b("p",{class:"empty-hint"},[ce(" Devices appear here once a platform plugin registers accessories. "),b("br"),ce(" This page auto-refreshes every 3 seconds: discovery can take up to 60s. ")],-1))])):(g(),E("div",{key:2,class:"devices-layout",onClick:T[7]||(T[7]=at(L=>ue(i).close(),["self"]))},[m.value==="cards"?(g(),E("div",{key:0,class:"device-grid",onClick:T[4]||(T[4]=at(L=>ue(i).close(),["self"]))},[(g(!0),E(we,null,Be(f.value,L=>(g(),de(A,{key:"native:"+L.id,class:xe(["device-card native-card",{selected:k.value===L.id,unhealthy:s(L)}]),title:s(L)?a(L):void 0,onClick:I=>M(L),onDblclick:I=>u(L)},{default:ee(()=>{var I;return[T[10]||(T[10]=b("span",{class:"device-card__accent"},null,-1)),b("div",JV,[Y(he,{name:N(v(L)),size:22},null,8,["name"])]),b("div",QV,[b("div",eB,[s(L)?(g(),de(he,{key:0,name:ue(mr),size:14,class:"name-health-icon"},null,8,["name"])):F("",!0),b("span",null,Z(L.name),1)]),b("div",tB,Z(P(v(L))),1),b("div",iB,[L.widgetType==="energy_meter"&&L.telemetry.power!==void 0?(g(),E("span",rB,Z(fe(L.telemetry.power,1))+" W",1)):L.widgetType==="thermostat"&&L.telemetry.currentTemperature!==void 0?(g(),E(we,{key:1},[b("span",sB,Z(fe(L.telemetry.currentTemperature,1))+"°C",1),L.telemetry.targetTemperature!==void 0?(g(),E("span",nB," target "+Z(fe(L.telemetry.targetTemperature,1))+"°C ",1)):F("",!0)],64)):L.widgetType==="dehumidifier"&&L.telemetry.currentHumidity!==void 0?(g(),E("span",aB,Z(fe(L.telemetry.currentHumidity,0))+"%",1)):L.telemetry.active!==void 0?(g(),E("span",{key:3,class:xe(["summary-status",L.telemetry.active?"on":"off"])},Z(L.telemetry.active?"On":"Off"),3)):F("",!0)]),L.telemetry.active!==void 0?(g(),E("div",{key:0,class:"card-controls",onClick:T[0]||(T[0]=at(()=>{},["stop"]))},[Y(pe,{name:`device-active-${L.id}`,"model-value":!!L.telemetry.active,"onUpdate:modelValue":z=>ie(L,"active",z)},null,8,["name","model-value","onUpdate:modelValue"])])):F("",!0),L.widgetType==="thermostat"&&L.telemetry.targetTemperature!==void 0?(g(),E("div",{key:1,class:"card-controls",onClick:T[1]||(T[1]=at(()=>{},["stop"]))},[Y(S,{"model-value":Number(L.telemetry.targetTemperature),size:"xs",min:5,max:35,step:1,"onUpdate:modelValue":z=>z!==null&&O(L.id,"targetTemperature",z)},null,8,["model-value","onUpdate:modelValue"])])):F("",!0),L.widgetType==="dehumidifier"&&L.telemetry.targetHumidity!==void 0?(g(),E("div",{key:2,class:"card-controls",onClick:T[2]||(T[2]=at(()=>{},["stop"]))},[Y(S,{"model-value":Number(L.telemetry.targetHumidity),size:"xs",min:30,max:80,step:5,"onUpdate:modelValue":z=>z!==null&&O(L.id,"targetHumidity",z)},null,8,["model-value","onUpdate:modelValue"])])):F("",!0)]),b("div",{class:xe(["device-reachability",l(L)]),title:((I=L.health)==null?void 0:I.reason)??c(L)},null,10,oB)]}),_:2},1032,["class","title","onClick","onDblclick"]))),128)),(g(!0),E(we,null,Be(ue(t).accessories,L=>(g(),de(A,{key:L.uuid,class:xe(["device-card hap-card",{selected:k.value===L.uuid,unreachable:!L.reachable,unhealthy:!L.reachable}]),title:L.reachable?void 0:ue(o),onClick:I=>$(L)},{default:ee(()=>{var I;return[b("div",{class:xe(["device-icon hap-icon",{unreachable:!L.reachable}])},[Y(he,{name:H(L.category).icon,size:22},null,8,["name"])],2),b("div",lB,[b("div",cB,[L.reachable?F("",!0):(g(),de(he,{key:0,name:ue(mr),size:14,class:"name-health-icon"},null,8,["name"])),b("span",null,Z(L.displayName),1)]),b("div",uB,Z(H(L.category).label),1),ne(L)?(g(),E("div",hB,[b("span",dB,Z(ne(L)),1)])):F("",!0),te(L)?(g(),E("div",{key:1,class:"card-controls",onClick:T[3]||(T[3]=at(()=>{},["stop"]))},[Y(pe,{name:`hap-on-${L.uuid}`,"model-value":!!((I=te(L))!=null&&I.value),"onUpdate:modelValue":z=>J(L,!!z)},null,8,["name","model-value","onUpdate:modelValue"])])):F("",!0)]),b("div",{class:xe(["device-reachability",L.reachable?"online":"stale"]),title:L.reachable?"Responding":ue(o)},null,10,fB)]}),_:2},1032,["class","title","onClick"]))),128))])):(g(),de(B,{key:1,columns:p,rows:C.value,"row-key":"key",size:"sm",zebra:"","sort-state":y.value,onSort:T[5]||(T[5]=L=>y.value=L),onRowClick:T[6]||(T[6]=L=>L.select())},{"cell-name":ee(({row:L})=>[b("div",{class:"cell-name",title:L.healthTooltip||void 0},[Y(he,{name:L.icon,size:16},null,8,["name"]),b("span",null,Z(L.name),1),L.unhealthy?(g(),de(he,{key:0,name:ue(mr),size:14,class:"cell-health-icon"},null,8,["name"])):F("",!0)],8,pB)]),"cell-state":ee(({row:L})=>[L.state?(g(),de(K,{key:0,variant:L.unhealthy?"orange":L.stateOn?"green":"grey"},{default:ee(()=>[ce(Z(L.state),1)]),_:2},1032,["variant"])):(g(),E("span",_B,"—"))]),_:1},8,["rows","sort-state"]))])),(g(),de(br,{to:"body"},[be.value.visible?(g(),E("div",{key:0,class:"confirm-overlay",onClick:at(ge,["self"])},[b("div",mB,[b("div",gB,[Y(he,{name:ue(mr),size:24},null,8,["name"])]),b("p",vB,Z(be.value.message),1),b("div",bB,[Y(se,{variant:"ghost",size:"sm",onClick:ge},{default:ee(()=>[...T[11]||(T[11]=[ce("Cancel",-1)])]),_:1}),Y(se,{variant:"primary",size:"sm",onClick:le},{default:ee(()=>[...T[12]||(T[12]=[ce("Confirm",-1)])]),_:1})])])])):F("",!0)]))])}}}),wB=jt(yB,[["__scopeId","data-v-5ae916c1"]]),La=(e,t,i)=>{const r=s=>Me("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:t,fill:"currentColor",...s,innerHTML:i});return r.displayName="NbGlyph",r.glyphName=e,r},SB=La("arrow-left","0 0 256 256",'<path d="M220,128a4,4,0,0,1-4,4H49.66l65.17,65.17a4,4,0,0,1-5.66,5.66l-72-72a4,4,0,0,1,0-5.66l72-72a4,4,0,0,1,5.66,5.66L49.66,124H216A4,4,0,0,1,220,128Z"/>'),CB=La("arrow-left","0 0 256 256",'<path d="M222,128a6,6,0,0,1-6,6H54.49l61.75,61.76a6,6,0,1,1-8.48,8.48l-72-72a6,6,0,0,1,0-8.48l72-72a6,6,0,0,1,8.48,8.48L54.49,122H216A6,6,0,0,1,222,128Z"/>'),_8=La("arrow-left","0 0 256 256",'<path d="M224,128a8,8,0,0,1-8,8H59.31l58.35,58.34a8,8,0,0,1-11.32,11.32l-72-72a8,8,0,0,1,0-11.32l72-72a8,8,0,0,1,11.32,11.32L59.31,120H216A8,8,0,0,1,224,128Z"/>'),kB=La("arrow-left","0 0 256 256",'<path d="M228,128a12,12,0,0,1-12,12H69l51.52,51.51a12,12,0,0,1-17,17l-72-72a12,12,0,0,1,0-17l72-72a12,12,0,0,1,17,17L69,116H216A12,12,0,0,1,228,128Z"/>'),AB=La("arrow-left","0 0 256 256",'<path d="M224,128a8,8,0,0,1-8,8H120v64a8,8,0,0,1-13.66,5.66l-72-72a8,8,0,0,1,0-11.32l72-72A8,8,0,0,1,120,56v64h96A8,8,0,0,1,224,128Z"/>'),MB=La("arrow-left","0 0 256 256",'<path d="M112,56V200L40,128Z" opacity="0.2"/><path d="M216,120H120V56a8,8,0,0,0-13.66-5.66l-72,72a8,8,0,0,0,0,11.32l72,72A8,8,0,0,0,120,200V136h96a8,8,0,0,0,0-16ZM104,180.69,51.31,128,104,75.31Z"/>'),LB="arrow-left",EB=Object.freeze(Object.defineProperty({__proto__:null,bold:kB,default:_8,duotone:MB,fill:AB,glyphName:LB,light:CB,regular:_8,thin:SB},Symbol.toStringTag,{value:"Module"})),$B={class:"device-detail"},xB={key:0,class:"detail-message"},TB={class:"summary-row"},NB=["onClick"],HB={class:"tile-label"},PB={class:"tile-value"},OB={class:"tile-unit"},IB={key:0,class:"detail-message"},RB={class:"chart-toolbar"},DB={class:"range-tabs"},VB=["onClick"],BB={key:0,class:"resolution-note"},ZB={class:"chart-panel"},FB={key:1,class:"chart-empty"},zB={key:2,class:"chart-empty"},UB={key:2,class:"detail-message"},WB=Re({__name:"DeviceDetailView",setup(e){const t=Lc(),i=Cl(),r=Q(()=>String(t.params.id??"")),s=X(null),n=X([]),a=X(""),o=X(!1),l=X(""),c=X(0),u=X([]),h=[{key:"1h",label:"1 hour",seconds:3600},{key:"24h",label:"24 hours",seconds:86400},{key:"7d",label:"7 days",seconds:7*86400},{key:"30d",label:"30 days",seconds:30*86400},{key:"1y",label:"1 year",seconds:365*86400}],d=X("24h"),f=Q(()=>{var R;return((R=s.value)==null?void 0:R.model)??"Device"}),m=Q(()=>n.value.find(R=>R.key===a.value)??null),_=Q(()=>{const R=m.value;if(!R||u.value.length===0)return[];const V={name:R.label,data:u.value.map(P=>({x:new Date(P.t*1e3),y:P.value??0}))};return u.value.some(P=>P.min!==void 0&&P.min!==null&&P.min!==P.value)?[V,{name:"Min",data:u.value.map(P=>({x:new Date(P.t*1e3),y:P.min??P.value??0}))},{name:"Max",data:u.value.map(P=>({x:new Date(P.t*1e3),y:P.max??P.value??0}))}]:[V]}),y=Q(()=>{if(!c.value)return"";const R=c.value;return R<60?`${R}s resolution`:R<3600?`${Math.round(R/60)} min resolution`:`${Math.round(R/3600)} h resolution`});function p(R){var P,U;const V=(U=(P=s.value)==null?void 0:P.telemetry)==null?void 0:U[R.key],N=Number(V);return Number.isFinite(N)?N:null}function C(R,V){return R===null?"—":R.toFixed(V.precision??2)}function w(){i.push({name:"devices"})}function v(R){a.value!==R&&(a.value=R,M())}function k(R){d.value!==R&&(d.value=R,M())}async function $(){try{const{devices:R}=await Ie.devices(),V=R.find(N=>N.id===r.value);if(!V){l.value=`Device "${r.value}" was not found. It may have been removed, or its plugin stopped.`;return}s.value=V,n.value=V.metrics??[],!a.value&&n.value.length>0&&(a.value=n.value[0].key)}catch(R){l.value=`Could not load device: ${R.message}`}}async function M(){var P,U;if(!a.value)return;const R=h.find(j=>j.key===d.value),V=Math.floor(Date.now()/1e3),N=V-R.seconds;o.value=!0;try{const j=await Ie.deviceMetrics(r.value,{metric:a.value,from:N,to:V});u.value=((P=j.series)==null?void 0:P.points)??[],c.value=((U=j.series)==null?void 0:U.resolution)??0}catch(j){l.value=`Could not load history: ${j.message}`}finally{o.value=!1}}let D=null,H=null;return ut(async()=>{await $(),await M(),D=setInterval(()=>void $(),5e3),H=setInterval(()=>void M(),3e4)}),Gi(()=>{D&&clearInterval(D),H&&clearInterval(H)}),Fe(r,async()=>{s.value=null,n.value=[],a.value="",u.value=[],l.value="",await $(),await M()}),(R,V)=>{var oe;const N=oi,P=g4,U=Qe,j=DL;return g(),E("div",$B,[Y(P,{title:f.value,subtitle:((oe=s.value)==null?void 0:oe.name)??r.value},{default:ee(()=>[Y(N,{variant:"ghost",size:"sm",icon:EB,onClick:w},{default:ee(()=>[...V[0]||(V[0]=[ce("Devices",-1)])]),_:1})]),_:1},8,["title","subtitle"]),l.value?(g(),E("div",xB,[Y(U,{variant:"error"},{default:ee(()=>[ce(Z(l.value),1)]),_:1})])):s.value?(g(),E(we,{key:1},[b("div",TB,[(g(!0),E(we,null,Be(n.value,te=>(g(),E("div",{key:te.key,class:xe(["summary-tile",{active:te.key===a.value}]),onClick:ne=>v(te.key)},[b("span",HB,Z(te.label),1),b("span",PB,[ce(Z(C(p(te),te))+" ",1),b("span",OB,Z(te.unit),1)])],10,NB))),128))]),n.value.length===0?(g(),E("div",IB,[Y(U,{variant:"helper"},{default:ee(()=>[...V[1]||(V[1]=[ce(" This device does not declare any metrics, so there is nothing to chart. Plugins opt in by describing their series in the device descriptor. ",-1)])]),_:1})])):(g(),E(we,{key:1},[b("div",RB,[b("div",DB,[(g(),E(we,null,Be(h,te=>b("button",{key:te.key,class:xe(["range-tab",{active:te.key===d.value}]),onClick:ne=>k(te.key)},Z(te.label),11,VB)),64))]),y.value?(g(),E("span",BB,Z(y.value),1)):F("",!0)]),b("div",ZB,[_.value.length>0&&_.value[0].data.length>0?(g(),de(j,{key:0,series:_.value,height:320,"show-legend":_.value.length>1,"show-grid":!0,"show-tooltip":!0,points:!1,curve:"smooth"},null,8,["series","show-legend"])):o.value?(g(),E("div",FB,"Loading…")):(g(),E("div",zB," No data recorded yet for this range. History starts accumulating once the device reports. "))])],64))],64)):(g(),E("div",UB,"Loading…"))])}}}),jB=jt(WB,[["__scopeId","data-v-df1516e5"]]),Ea=(e,t,i)=>{const r=s=>Me("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:t,fill:"currentColor",...s,innerHTML:i});return r.displayName="NbGlyph",r.glyphName=e,r},KB=Ea("magic-wand","0 0 256 256",'<path d="M244,152a4,4,0,0,1-4,4H220v20a4,4,0,0,1-8,0V156H192a4,4,0,0,1,0-8h20V128a4,4,0,0,1,8,0v20h20A4,4,0,0,1,244,152ZM56,68H76V88a4,4,0,0,0,8,0V68h20a4,4,0,0,0,0-8H84V40a4,4,0,0,0-8,0V60H56a4,4,0,0,0,0,8ZM184,196H172V184a4,4,0,0,0-8,0v12H152a4,4,0,0,0,0,8h12v12a4,4,0,0,0,8,0V204h12a4,4,0,0,0,0-8ZM216.48,77.17,77.17,216.49a12,12,0,0,1-17,0L39.51,195.8a12,12,0,0,1,0-17L178.83,39.51a12,12,0,0,1,17,0L216.48,60.2A12,12,0,0,1,216.48,77.17ZM170.34,112,144,85.66,45.17,184.49a4,4,0,0,0,0,5.65l20.68,20.69a4,4,0,0,0,5.66,0Zm40.49-46.14L190.14,45.17a4,4,0,0,0-5.66,0L149.65,80,176,106.34l34.83-34.83A4,4,0,0,0,210.83,65.86Z"/>'),qB=Ea("magic-wand","0 0 256 256",'<path d="M246,152a6,6,0,0,1-6,6H222v18a6,6,0,0,1-12,0V158H192a6,6,0,0,1,0-12h18V128a6,6,0,0,1,12,0v18h18A6,6,0,0,1,246,152ZM56,70H74V88a6,6,0,0,0,12,0V70h18a6,6,0,0,0,0-12H86V40a6,6,0,0,0-12,0V58H56a6,6,0,0,0,0,12ZM184,194H174V184a6,6,0,0,0-12,0v10H152a6,6,0,0,0,0,12h10v10a6,6,0,0,0,12,0V206h10a6,6,0,0,0,0-12ZM217.9,78.59,78.58,217.9a14,14,0,0,1-19.8,0L38.09,197.21a14,14,0,0,1,0-19.8L177.41,38.1a14,14,0,0,1,19.8,0L217.9,58.79A14,14,0,0,1,217.9,78.59ZM167.51,112,144,88.49,46.58,185.9a2,2,0,0,0,0,2.83l20.69,20.68a2,2,0,0,0,2.82,0h0Zm41.9-44.73L188.73,46.59a2,2,0,0,0-2.83,0L152.48,80,176,103.52,209.41,70.1A2,2,0,0,0,209.41,67.27Z"/>'),m8=Ea("magic-wand","0 0 256 256",'<path d="M48,64a8,8,0,0,1,8-8H72V40a8,8,0,0,1,16,0V56h16a8,8,0,0,1,0,16H88V88a8,8,0,0,1-16,0V72H56A8,8,0,0,1,48,64ZM184,192h-8v-8a8,8,0,0,0-16,0v8h-8a8,8,0,0,0,0,16h8v8a8,8,0,0,0,16,0v-8h8a8,8,0,0,0,0-16Zm56-48H224V128a8,8,0,0,0-16,0v16H192a8,8,0,0,0,0,16h16v16a8,8,0,0,0,16,0V160h16a8,8,0,0,0,0-16ZM219.31,80,80,219.31a16,16,0,0,1-22.62,0L36.68,198.63a16,16,0,0,1,0-22.63L176,36.69a16,16,0,0,1,22.63,0l20.68,20.68A16,16,0,0,1,219.31,80Zm-54.63,32L144,91.31l-96,96L68.68,208ZM208,68.69,187.31,48l-32,32L176,100.69Z"/>'),GB=Ea("magic-wand","0 0 256 256",'<path d="M252,152a12,12,0,0,1-12,12H228v12a12,12,0,0,1-24,0V164H192a12,12,0,0,1,0-24h12V128a12,12,0,0,1,24,0v12h12A12,12,0,0,1,252,152ZM56,76H68V88a12,12,0,0,0,24,0V76h12a12,12,0,1,0,0-24H92V40a12,12,0,0,0-24,0V52H56a12,12,0,0,0,0,24ZM184,188h-4v-4a12,12,0,0,0-24,0v4h-4a12,12,0,0,0,0,24h4v4a12,12,0,0,0,24,0v-4h4a12,12,0,0,0,0-24ZM222.14,82.83,82.82,222.14a20,20,0,0,1-28.28,0L33.85,201.46a20,20,0,0,1,0-28.29L173.17,33.86a20,20,0,0,1,28.28,0l20.69,20.68A20,20,0,0,1,222.14,82.83ZM159,112,144,97,53.65,187.31l15,15Zm43.31-43.31-15-15L161,80l15,15Z"/>'),YB=Ea("magic-wand","0 0 256 256",'<path d="M248,152a8,8,0,0,1-8,8H224v16a8,8,0,0,1-16,0V160H192a8,8,0,0,1,0-16h16V128a8,8,0,0,1,16,0v16h16A8,8,0,0,1,248,152ZM56,72H72V88a8,8,0,0,0,16,0V72h16a8,8,0,0,0,0-16H88V40a8,8,0,0,0-16,0V56H56a8,8,0,0,0,0,16ZM184,192h-8v-8a8,8,0,0,0-16,0v8h-8a8,8,0,0,0,0,16h8v8a8,8,0,0,0,16,0v-8h8a8,8,0,0,0,0-16ZM219.31,80,80,219.31a16,16,0,0,1-22.62,0L36.68,198.63a16,16,0,0,1,0-22.63L176,36.69a16,16,0,0,1,22.63,0l20.68,20.68A16,16,0,0,1,219.31,80ZM208,68.69,187.31,48l-32,32L176,100.69Z"/>'),XB=Ea("magic-wand","0 0 256 256",'<path d="M176,112,74.34,213.66a8,8,0,0,1-11.31,0L42.34,193a8,8,0,0,1,0-11.31L144,80Z" opacity="0.2"/><path d="M248,152a8,8,0,0,1-8,8H224v16a8,8,0,0,1-16,0V160H192a8,8,0,0,1,0-16h16V128a8,8,0,0,1,16,0v16h16A8,8,0,0,1,248,152ZM56,72H72V88a8,8,0,0,0,16,0V72h16a8,8,0,0,0,0-16H88V40a8,8,0,0,0-16,0V56H56a8,8,0,0,0,0,16ZM184,192h-8v-8a8,8,0,0,0-16,0v8h-8a8,8,0,0,0,0,16h8v8a8,8,0,0,0,16,0v-8h8a8,8,0,0,0,0-16ZM219.31,80,80,219.31a16,16,0,0,1-22.62,0L36.68,198.63a16,16,0,0,1,0-22.63L176,36.69a16,16,0,0,1,22.63,0l20.68,20.68A16,16,0,0,1,219.31,80Zm-54.63,32L144,91.31l-96,96L68.68,208ZM208,68.69,187.31,48l-32,32L176,100.69Z"/>'),JB="magic-wand",QB=Object.freeze(Object.defineProperty({__proto__:null,bold:GB,default:m8,duotone:XB,fill:YB,glyphName:JB,light:qB,regular:m8,thin:KB},Symbol.toStringTag,{value:"Module"})),eZ={class:"config-view"},tZ={key:0,class:"error-banner"},iZ={key:1,class:"loading-state"},rZ=Re({__name:"ConfigView",setup(e){const t=ln(),{resolved:i}=Ad(),r=X(null),s=Ar(null),n=X(!1),a=X(!1),o=X(null),l=X(!0);ut(async()=>{t.setPage("Config",void 0,{fullBleed:!0});let h="{}";try{h=(await Ie.config.get()).content}catch(f){o.value=`Failed to load config: ${f}`}finally{l.value=!1}const d=await Ug.init();d.languages.json.jsonDefaults.setDiagnosticsOptions({validate:!0,schemas:[{uri:"openbridge://config-schema",fileMatch:["*"],schema:{type:"object",properties:{bridge:{type:"object",description:"Bridge configuration",properties:{name:{type:"string",description:"Bridge display name"},port:{type:"number",description:"HTTP API port (default 8582)"},hapPort:{type:"number",description:"HomeKit HAP port (default 51829)"},pincode:{type:"string",description:"HomeKit pairing PIN (format: XXX-XX-XXX)"},username:{type:"string",description:"HAP username (MAC address format)"},logLevel:{type:"string",enum:["debug","info","warn","error"]}}},platforms:{type:"array",description:"Homebridge-compatible platform plugins",items:{type:"object",required:["platform"],properties:{platform:{type:"string",description:"Platform identifier"},plugin:{type:"string",description:"Absolute path to the plugin JS file"},enabled:{type:"boolean",default:!0}},additionalProperties:!0}},plugins:{type:"array",description:"Native OpenBridge plugins",items:{type:"object",required:["name"],properties:{name:{type:"string"},path:{type:"string"},enabled:{type:"boolean",default:!0},config:{type:"object"}}}}}}}]}),r.value&&(Fe(i,f=>d.editor.setTheme(f==="dark"?"vs-dark":"vs")),s.value=d.editor.create(r.value,{value:h,language:"json",theme:i.value==="dark"?"vs-dark":"vs",fontSize:13,fontFamily:'"MesloLGS NF", monospace',minimap:{enabled:!0},scrollBeyondLastLine:!1,formatOnPaste:!0,formatOnType:!0,tabSize:2,automaticLayout:!0,wordWrap:"off",bracketPairColorization:{enabled:!0},guides:{bracketPairs:!0},lineNumbers:"on",renderLineHighlight:"all",smoothScrolling:!0}))}),Gi(()=>{var h;(h=s.value)==null||h.dispose()});async function c(){var h;if(!n.value){n.value=!0,o.value=null,a.value=!1;try{const d=((h=s.value)==null?void 0:h.getValue())??"";await Ie.config.save(d),a.value=!0,setTimeout(()=>{a.value=!1},2500)}catch(d){o.value=String(d)}finally{n.value=!1}}}function u(){var h,d;(d=(h=s.value)==null?void 0:h.getAction("editor.action.formatDocument"))==null||d.run()}return(h,d)=>{const f=oi,m=Ge;return g(),E("div",eZ,[(g(),de(br,{defer:"",to:"#ob-topbar-left"},[d[0]||(d[0]=b("span",{class:"config-path"},"~/.openbridge/config.json",-1))])),(g(),de(br,{defer:"",to:"#ob-topbar-right"},[Y(f,{variant:"ghost",size:"sm",icon:QB,title:"Format JSON",onClick:u},{default:ee(()=>[...d[1]||(d[1]=[ce("Format",-1)])]),_:1}),Y(f,{variant:"primary",size:"sm",icon:a.value?Ss:z0,loading:n.value,disabled:n.value,title:"Changes take effect after restarting the daemon",onClick:c},{default:ee(()=>[ce(Z(a.value?"Saved!":n.value?"Saving…":"Save"),1)]),_:1},8,["icon","loading","disabled"])])),o.value?(g(),E("div",tZ,[Y(m,{name:ue(mr),size:14},null,8,["name"]),ce(" "+Z(o.value),1)])):F("",!0),l.value?(g(),E("div",iZ,[Y(m,{name:ue(Fn),size:28},null,8,["name"]),d[2]||(d[2]=b("span",null,"Loading config...",-1))])):(g(),E("div",{key:2,ref_key:"editorContainer",ref:r,class:"editor-container"},null,512))])}}}),sZ=jt(rZ,[["__scopeId","data-v-483debe2"]]),nZ=(e,t,i)=>{const r=s=>Me("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:t,fill:"currentColor",...s,innerHTML:i});return r.displayName="NbGlyph",r.glyphName=e,r},aZ=nZ("bridge","0 0 256 256",'<path d="M232,160H200V101.34a71.89,71.89,0,0,0,29,21.42,8,8,0,0,0,6-14.83A55.78,55.78,0,0,1,200,56a8,8,0,0,0-16,0A56,56,0,0,1,72,56a8,8,0,0,0-16,0,55.78,55.78,0,0,1-35,51.93,8,8,0,0,0,6,14.83,71.89,71.89,0,0,0,29-21.42V160H24a8,8,0,0,0,0,16H56v24a8,8,0,0,0,16,0V176H184v24a8,8,0,0,0,16,0V176h32a8,8,0,0,0,0-16Zm-88-33.8V160H112V126.2a72,72,0,0,0,32,0Zm-72-25a72.47,72.47,0,0,0,24,19.27V160H72ZM160,160V120.48a72.47,72.47,0,0,0,24-19.27V160Z"/>'),oZ={class:"settings-view"},lZ={class:"card-header"},cZ={class:"card-icon"},uZ={class:"pin-row"},hZ={class:"card-actions"},dZ={key:0,class:"action-hint"},fZ={class:"card-header"},pZ={class:"card-icon"},_Z={class:"update-row"},mZ={class:"update-versions"},gZ={class:"update-actions"},vZ={class:"update-command"},bZ={key:3,class:"update-error-row"},yZ={class:"info-title"},wZ=Re({__name:"SettingsView",setup(e){const t=ln(),i=[{value:"debug",label:"Debug"},{value:"info",label:"Info"},{value:"warn",label:"Warn"},{value:"error",label:"Error"}],r=X(!1),s=X(!1),n=X(null),a=X(!1),o=X(null),l=X(!1),c=X(!1),u=X(!1),h=X(null),d=X(""),f=X(0),m=X("");let _=null;async function y(){l.value=!0,h.value=null;try{o.value=await Ie.updates.check()}catch(H){h.value=String(H)}finally{l.value=!1}}function p(){const H=location.protocol==="https:"?"wss":"ws";_=new WebSocket(`${H}://${location.host}/ws/updates`),_.onmessage=R=>{try{const V=JSON.parse(R.data);d.value=V.stage??"",f.value=Math.round((V.progress??0)*100),m.value=V.message??"",V.stage==="restarting"&&C(),V.stage==="error"&&(h.value=V.message,c.value=!1)}catch{}},_.onclose=()=>{c.value&&C()}}function C(){let H=0;const R=setInterval(async()=>{H++;try{await Ie.health(),clearInterval(R),c.value=!1,d.value="",m.value="",o.value=null,await y()}catch{}H>60&&(clearInterval(R),c.value=!1,h.value="Timed out waiting for restart")},2e3)}async function w(){if(!c.value){c.value=!0,u.value=!1,h.value=null,d.value="downloading",m.value="Starting update...",f.value=0,p();try{await Ie.updates.apply(),u.value=!0}catch(H){h.value=H instanceof Error?H.message:String(H),c.value=!1}}}async function v(){if(!c.value){c.value=!0,h.value=null,m.value="Rolling back...";try{await Ie.updates.rollback(),C()}catch(H){h.value=H instanceof Error?H.message:String(H),c.value=!1}}}const k=X({name:"OpenBridge",port:8582,hapPort:51829,pincode:"031-45-154",username:"",logLevel:"info"});ut(async()=>{t.setPage("Settings");try{const H=await Ie.bridge();H&&typeof H=="object"&&(k.value={name:H.name??"OpenBridge",port:H.port??8582,hapPort:H.hapPort??51829,pincode:H.pincode??"031-45-154",username:H.username??"",logLevel:H.logLevel??"info"})}catch{}y()}),Ii(()=>{_&&(_.close(),_=null)});async function $(){if(!r.value){r.value=!0,n.value=null,s.value=!1;try{const H={name:k.value.name,port:Number(k.value.port),hapPort:Number(k.value.hapPort),pincode:k.value.pincode,logLevel:k.value.logLevel};k.value.username&&(H.username=k.value.username),await Ie.saveBridge(H),s.value=!0,setTimeout(()=>{s.value=!1},3e3)}catch(H){n.value=String(H)}finally{r.value=!1}}}async function M(){if(!a.value){a.value=!0;try{await Ie.daemon.restart();let H=0;const R=setInterval(async()=>{H++;try{await Ie.health(),clearInterval(R),location.reload()}catch{}H>60&&(clearInterval(R),a.value=!1)},1e3)}catch{a.value=!1}}}function D(){const H=()=>Math.floor(Math.random()*9)+1,R=()=>`${H()}${Math.floor(Math.random()*10)}${Math.floor(Math.random()*10)}`,V=()=>`${Math.floor(Math.random()*10)}${Math.floor(Math.random()*10)}`;k.value.pincode=`${R()}-${V()}-${R()}`}return(H,R)=>{const V=Ge,N=ha,P=Sd,U=Cd,j=oi,oe=Cc,te=Qi,ne=Qe,J=Sl,fe=an,re=Q4;return g(),E("div",oZ,[Y(J,{class:"settings-card"},{default:ee(()=>[b("div",lZ,[b("div",cZ,[Y(V,{name:ue(aZ),size:18},null,8,["name"])]),R[6]||(R[6]=b("div",null,[b("h2",{class:"card-title"},"Bridge"),b("p",{class:"card-subtitle"},"HomeKit bridge identity and network settings")],-1))]),Y(te,{dir:"col",gap:"sm",class:"field-grid"},{default:ee(()=>[Y(P,{label:"Bridge name",hint:"Displayed in the Home app"},{default:ee(()=>[Y(N,{modelValue:k.value.name,"onUpdate:modelValue":R[0]||(R[0]=_e=>k.value.name=_e),size:"sm",placeholder:"OpenBridge"},null,8,["modelValue"])]),_:1}),Y(P,{label:"HTTP port",hint:"OpenBridge web UI & API",control:"fit"},{default:ee(()=>[Y(U,{modelValue:k.value.port,"onUpdate:modelValue":R[1]||(R[1]=_e=>k.value.port=_e),size:"sm",min:1024,max:65535},null,8,["modelValue"])]),_:1}),Y(P,{label:"HAP port",hint:"HomeKit accessory protocol port",control:"fit"},{default:ee(()=>[Y(U,{modelValue:k.value.hapPort,"onUpdate:modelValue":R[2]||(R[2]=_e=>k.value.hapPort=_e),size:"sm",min:1024,max:65535},null,8,["modelValue"])]),_:1}),Y(P,{label:"PIN code",hint:"Format: XXX-XX-XXX, used to pair with HomeKit"},{default:ee(()=>[b("div",uZ,[Y(N,{modelValue:k.value.pincode,"onUpdate:modelValue":R[3]||(R[3]=_e=>k.value.pincode=_e),size:"sm",placeholder:"031-45-154"},null,8,["modelValue"]),Y(j,{variant:"ghost",size:"sm",icon:Qs,title:"Generate random PIN",onClick:D})])]),_:1}),Y(P,{label:"Bridge MAC",hint:"Leave empty to auto-generate. Change this only if pairing with HomeKit fails."},{default:ee(()=>[Y(N,{modelValue:k.value.username,"onUpdate:modelValue":R[4]||(R[4]=_e=>k.value.username=_e),size:"sm",class:"mono",placeholder:"AA:BB:CC:DD:EE:FF"},null,8,["modelValue"])]),_:1}),Y(P,{label:"Log level",control:"fit"},{default:ee(()=>[Y(oe,{modelValue:k.value.logLevel,"onUpdate:modelValue":R[5]||(R[5]=_e=>k.value.logLevel=_e),size:"sm",options:i},null,8,["modelValue"])]),_:1})]),_:1}),n.value?(g(),de(ne,{key:0,variant:"error"},{default:ee(()=>[ce(Z(n.value),1)]),_:1})):F("",!0),b("div",hZ,[Y(j,{variant:"primary",size:"sm",loading:r.value,icon:s.value?Ss:z0,onClick:$},{default:ee(()=>[ce(Z(s.value?"Saved!":"Save"),1)]),_:1},8,["loading","icon"]),Y(j,{variant:"secondary",size:"sm",outlined:"",loading:a.value,icon:a.value?ul:Qs,onClick:M},{default:ee(()=>[ce(Z(a.value?"Restarting…":"Save & Restart OpenBridge"),1)]),_:1},8,["loading","icon"]),s.value&&!a.value?(g(),E("span",dZ,[Y(V,{name:ue(H0),size:12},null,8,["name"]),R[7]||(R[7]=ce(" Restart the daemon for changes to take effect ",-1))])):F("",!0)])]),_:1}),Y(J,{class:"settings-card"},{default:ee(()=>{var _e,Ne;return[b("div",fZ,[b("div",pZ,[Y(V,{name:ue(Vu),size:18},null,8,["name"])]),R[8]||(R[8]=b("div",null,[b("h2",{class:"card-title"},"Updates"),b("p",{class:"card-subtitle"},"OpenBridge daemon and UI")],-1))]),b("div",_Z,[b("div",mZ,[Y(fe,{variant:"grey"},{default:ee(()=>{var $e;return[ce("Current: v"+Z((($e=o.value)==null?void 0:$e.current)??"…"),1)]}),_:1}),o.value&&!l.value?(g(),E(we,{key:0},[o.value.updateAvailable?(g(),de(fe,{key:0,variant:"blue"},{default:ee(()=>[ce("Available: v"+Z(o.value.latest),1)]),_:1})):o.value.latest===null?(g(),de(fe,{key:1,variant:"orange"},{default:ee(()=>[...R[9]||(R[9]=[ce("Unable to check",-1)])]),_:1})):(g(),de(fe,{key:2,variant:"green"},{default:ee(()=>[...R[10]||(R[10]=[ce("Up to date",-1)])]),_:1}))],64)):F("",!0),l.value?(g(),de(fe,{key:1,variant:"grey"},{default:ee(()=>[...R[11]||(R[11]=[ce("Checking…",-1)])]),_:1})):F("",!0)]),b("div",gZ,[Y(j,{variant:"secondary",size:"sm",outlined:"",loading:l.value,icon:Qs,onClick:y},{default:ee(()=>[...R[12]||(R[12]=[ce(" Check ",-1)])]),_:1},8,["loading"]),(_e=o.value)!=null&&_e.updateAvailable&&o.value.updateMethod==="self"?(g(),de(j,{key:0,variant:"primary",size:"sm",loading:c.value,icon:c.value?ul:Ed,onClick:w},{default:ee(()=>[ce(Z(c.value?"Updating…":"Install update"),1)]),_:1},8,["loading","icon"])):F("",!0)])]),c.value&&d.value?(g(),de(re,{key:0,label:m.value,value:d.value==="downloading"&&f.value>0?f.value:void 0,max:100,status:"active",size:"sm"},null,8,["label","value"])):F("",!0),c.value&&!d.value?(g(),de(ne,{key:1,variant:"helper"},{default:ee(()=>[...R[13]||(R[13]=[ce(" Starting update... This page will reconnect automatically. ",-1)])]),_:1})):F("",!0),((Ne=o.value)==null?void 0:Ne.updateMethod)==="manual"&&o.value.updateAvailable?(g(),de(ne,{key:2,variant:"helper"},{default:ee(()=>[o.value.pinnedTo?(g(),E(we,{key:0},[ce(" This deployment is pinned to "+Z(o.value.pinnedTo)+". To move version: ",1)],64)):o.value.updateBlockedBy?(g(),E(we,{key:1},[ce(" Self-update is not available here ("+Z(o.value.updateBlockedBy)+"). To update: ",1)],64)):(g(),E(we,{key:2},[ce("Self-update is not available for this install. To update:")],64)),b("code",vZ,Z(o.value.updateCommand),1)]),_:1})):F("",!0),h.value?(g(),E("div",bZ,[Y(ne,{variant:"error"},{default:ee(()=>[ce(Z(h.value),1)]),_:1}),u.value?(g(),de(j,{key:0,variant:"ghost",size:"sm",onClick:v},{default:ee(()=>[...R[14]||(R[14]=[ce("Rollback",-1)])]),_:1})):F("",!0)])):F("",!0)]}),_:1}),Y(J,{class:"settings-card info-card"},{default:ee(()=>[b("h3",yZ,[Y(V,{name:ue(H0),size:14},null,8,["name"]),R[15]||(R[15]=ce(" How to pair with HomeKit ",-1))]),R[16]||(R[16]=b("ol",{class:"info-list"},[b("li",null,[ce(" Open the "),b("strong",null,"Home"),ce(" app on your iPhone or iPad ")]),b("li",null,[ce(" Tap "),b("strong",null,"+"),ce(" → "),b("strong",null,"Add Accessory")]),b("li",null,[ce(" Scan the QR code from the Dashboard, or tap "),b("strong",null,"More options"),ce(" and enter the PIN code manually ")]),b("li",null,"If you change the PIN or username, unpair first from the Home app, then re-pair")],-1))]),_:1})])}}}),SZ=jt(wZ,[["__scopeId","data-v-4dc01a9f"]]);/**
|
|
70
|
-
* Copyright (c) 2014-2024 The xterm.js authors. All rights reserved.
|
|
71
|
-
* @license MIT
|
|
72
|
-
*
|
|
73
|
-
* Copyright (c) 2012-2013, Christopher Jeffrey (MIT License)
|
|
74
|
-
* @license MIT
|
|
75
|
-
*
|
|
76
|
-
* Originally forked from (with the author's permission):
|
|
77
|
-
* Fabrice Bellard's javascript vt100 for jslinux:
|
|
78
|
-
* http://bellard.org/jslinux/
|
|
79
|
-
* Copyright (c) 2011 Fabrice Bellard
|
|
80
|
-
*/var Xg=Object.defineProperty,CZ=Object.getOwnPropertyDescriptor,kZ=(e,t)=>{for(var i in t)Xg(e,i,{get:t[i],enumerable:!0})},Tt=(e,t,i,r)=>{for(var s=r>1?void 0:r?CZ(t,i):t,n=e.length-1,a;n>=0;n--)(a=e[n])&&(s=(r?a(t,i,s):a(s))||s);return r&&s&&Xg(t,i,s),s},Te=(e,t)=>(i,r)=>t(i,r,e),g8="Terminal input",ju={get:()=>g8,set:e=>g8=e},v8="Too much output to announce, navigate to rows manually to read",Ku={get:()=>v8,set:e=>v8=e};function AZ(e){return e.replace(/\r?\n/g,"\r")}function MZ(e,t){return t?"\x1B[200~"+e+"\x1B[201~":e}function LZ(e,t){e.clipboardData&&e.clipboardData.setData("text/plain",t.selectionText),e.preventDefault()}function EZ(e,t,i,r){if(e.stopPropagation(),e.clipboardData){let s=e.clipboardData.getData("text/plain");Jg(s,t,i,r)}}function Jg(e,t,i,r){e=AZ(e),e=MZ(e,i.decPrivateModes.bracketedPasteMode&&r.rawOptions.ignoreBracketedPasteMode!==!0),i.triggerDataEvent(e,!0),t.value=""}function Qg(e,t,i){let r=i.getBoundingClientRect(),s=e.clientX-r.left-10,n=e.clientY-r.top-10;t.style.width="20px",t.style.height="20px",t.style.left=`${s}px`,t.style.top=`${n}px`,t.style.zIndex="1000",t.focus()}function b8(e,t,i,r,s){Qg(e,t,i),s&&r.rightClickSelect(e),t.value=r.selectionText,t.select()}function us(e){return e>65535?(e-=65536,String.fromCharCode((e>>10)+55296)+String.fromCharCode(e%1024+56320)):String.fromCharCode(e)}function Pc(e,t=0,i=e.length){let r="";for(let s=t;s<i;++s){let n=e[s];n>65535?(n-=65536,r+=String.fromCharCode((n>>10)+55296)+String.fromCharCode(n%1024+56320)):r+=String.fromCharCode(n)}return r}var $Z=class{constructor(){this._interim=0}clear(){this._interim=0}decode(e,t){let i=e.length;if(!i)return 0;let r=0,s=0;if(this._interim){let n=e.charCodeAt(s++);56320<=n&&n<=57343?t[r++]=(this._interim-55296)*1024+n-56320+65536:(t[r++]=this._interim,t[r++]=n),this._interim=0}for(let n=s;n<i;++n){let a=e.charCodeAt(n);if(55296<=a&&a<=56319){if(++n>=i)return this._interim=a,r;let o=e.charCodeAt(n);56320<=o&&o<=57343?t[r++]=(a-55296)*1024+o-56320+65536:(t[r++]=a,t[r++]=o);continue}a!==65279&&(t[r++]=a)}return r}},xZ=class{constructor(){this.interim=new Uint8Array(3)}clear(){this.interim.fill(0)}decode(e,t){let i=e.length;if(!i)return 0;let r=0,s,n,a,o,l=0,c=0;if(this.interim[0]){let d=!1,f=this.interim[0];f&=(f&224)===192?31:(f&240)===224?15:7;let m=0,_;for(;(_=this.interim[++m]&63)&&m<4;)f<<=6,f|=_;let y=(this.interim[0]&224)===192?2:(this.interim[0]&240)===224?3:4,p=y-m;for(;c<p;){if(c>=i)return 0;if(_=e[c++],(_&192)!==128){c--,d=!0;break}else this.interim[m++]=_,f<<=6,f|=_&63}d||(y===2?f<128?c--:t[r++]=f:y===3?f<2048||f>=55296&&f<=57343||f===65279||(t[r++]=f):f<65536||f>1114111||(t[r++]=f)),this.interim.fill(0)}let u=i-4,h=c;for(;h<i;){for(;h<u&&!((s=e[h])&128)&&!((n=e[h+1])&128)&&!((a=e[h+2])&128)&&!((o=e[h+3])&128);)t[r++]=s,t[r++]=n,t[r++]=a,t[r++]=o,h+=4;if(s=e[h++],s<128)t[r++]=s;else if((s&224)===192){if(h>=i)return this.interim[0]=s,r;if(n=e[h++],(n&192)!==128){h--;continue}if(l=(s&31)<<6|n&63,l<128){h--;continue}t[r++]=l}else if((s&240)===224){if(h>=i)return this.interim[0]=s,r;if(n=e[h++],(n&192)!==128){h--;continue}if(h>=i)return this.interim[0]=s,this.interim[1]=n,r;if(a=e[h++],(a&192)!==128){h--;continue}if(l=(s&15)<<12|(n&63)<<6|a&63,l<2048||l>=55296&&l<=57343||l===65279)continue;t[r++]=l}else if((s&248)===240){if(h>=i)return this.interim[0]=s,r;if(n=e[h++],(n&192)!==128){h--;continue}if(h>=i)return this.interim[0]=s,this.interim[1]=n,r;if(a=e[h++],(a&192)!==128){h--;continue}if(h>=i)return this.interim[0]=s,this.interim[1]=n,this.interim[2]=a,r;if(o=e[h++],(o&192)!==128){h--;continue}if(l=(s&7)<<18|(n&63)<<12|(a&63)<<6|o&63,l<65536||l>1114111)continue;t[r++]=l}}return r}},ev="",fs=" ",Ll=class tv{constructor(){this.fg=0,this.bg=0,this.extended=new K0}static toColorRGB(t){return[t>>>16&255,t>>>8&255,t&255]}static fromColorRGB(t){return(t[0]&255)<<16|(t[1]&255)<<8|t[2]&255}clone(){let t=new tv;return t.fg=this.fg,t.bg=this.bg,t.extended=this.extended.clone(),t}isInverse(){return this.fg&67108864}isBold(){return this.fg&134217728}isUnderline(){return this.hasExtendedAttrs()&&this.extended.underlineStyle!==0?1:this.fg&268435456}isBlink(){return this.fg&536870912}isInvisible(){return this.fg&1073741824}isItalic(){return this.bg&67108864}isDim(){return this.bg&134217728}isStrikethrough(){return this.fg&2147483648}isProtected(){return this.bg&536870912}isOverline(){return this.bg&1073741824}getFgColorMode(){return this.fg&50331648}getBgColorMode(){return this.bg&50331648}isFgRGB(){return(this.fg&50331648)===50331648}isBgRGB(){return(this.bg&50331648)===50331648}isFgPalette(){return(this.fg&50331648)===16777216||(this.fg&50331648)===33554432}isBgPalette(){return(this.bg&50331648)===16777216||(this.bg&50331648)===33554432}isFgDefault(){return(this.fg&50331648)===0}isBgDefault(){return(this.bg&50331648)===0}isAttributeDefault(){return this.fg===0&&this.bg===0}getFgColor(){switch(this.fg&50331648){case 16777216:case 33554432:return this.fg&255;case 50331648:return this.fg&16777215;default:return-1}}getBgColor(){switch(this.bg&50331648){case 16777216:case 33554432:return this.bg&255;case 50331648:return this.bg&16777215;default:return-1}}hasExtendedAttrs(){return this.bg&268435456}updateExtended(){this.extended.isEmpty()?this.bg&=-268435457:this.bg|=268435456}getUnderlineColor(){if(this.bg&268435456&&~this.extended.underlineColor)switch(this.extended.underlineColor&50331648){case 16777216:case 33554432:return this.extended.underlineColor&255;case 50331648:return this.extended.underlineColor&16777215;default:return this.getFgColor()}return this.getFgColor()}getUnderlineColorMode(){return this.bg&268435456&&~this.extended.underlineColor?this.extended.underlineColor&50331648:this.getFgColorMode()}isUnderlineColorRGB(){return this.bg&268435456&&~this.extended.underlineColor?(this.extended.underlineColor&50331648)===50331648:this.isFgRGB()}isUnderlineColorPalette(){return this.bg&268435456&&~this.extended.underlineColor?(this.extended.underlineColor&50331648)===16777216||(this.extended.underlineColor&50331648)===33554432:this.isFgPalette()}isUnderlineColorDefault(){return this.bg&268435456&&~this.extended.underlineColor?(this.extended.underlineColor&50331648)===0:this.isFgDefault()}getUnderlineStyle(){return this.fg&268435456?this.bg&268435456?this.extended.underlineStyle:1:0}getUnderlineVariantOffset(){return this.extended.underlineVariantOffset}},K0=class iv{constructor(t=0,i=0){this._ext=0,this._urlId=0,this._ext=t,this._urlId=i}get ext(){return this._urlId?this._ext&-469762049|this.underlineStyle<<26:this._ext}set ext(t){this._ext=t}get underlineStyle(){return this._urlId?5:(this._ext&469762048)>>26}set underlineStyle(t){this._ext&=-469762049,this._ext|=t<<26&469762048}get underlineColor(){return this._ext&67108863}set underlineColor(t){this._ext&=-67108864,this._ext|=t&67108863}get urlId(){return this._urlId}set urlId(t){this._urlId=t}get underlineVariantOffset(){let t=(this._ext&3758096384)>>29;return t<0?t^4294967288:t}set underlineVariantOffset(t){this._ext&=536870911,this._ext|=t<<29&3758096384}clone(){return new iv(this._ext,this._urlId)}isEmpty(){return this.underlineStyle===0&&this._urlId===0}},Ki=class rv extends Ll{constructor(){super(...arguments),this.content=0,this.fg=0,this.bg=0,this.extended=new K0,this.combinedData=""}static fromCharData(t){let i=new rv;return i.setFromCharData(t),i}isCombined(){return this.content&2097152}getWidth(){return this.content>>22}getChars(){return this.content&2097152?this.combinedData:this.content&2097151?us(this.content&2097151):""}getCode(){return this.isCombined()?this.combinedData.charCodeAt(this.combinedData.length-1):this.content&2097151}setFromCharData(t){this.fg=t[0],this.bg=0;let i=!1;if(t[1].length>2)i=!0;else if(t[1].length===2){let r=t[1].charCodeAt(0);if(55296<=r&&r<=56319){let s=t[1].charCodeAt(1);56320<=s&&s<=57343?this.content=(r-55296)*1024+s-56320+65536|t[2]<<22:i=!0}else i=!0}else this.content=t[1].charCodeAt(0)|t[2]<<22;i&&(this.combinedData=t[1],this.content=2097152|t[2]<<22)}getAsCharData(){return[this.fg,this.getChars(),this.getWidth(),this.getCode()]}},y8="di$target",qu="di$dependencies",C1=new Map;function TZ(e){return e[qu]||[]}function ei(e){if(C1.has(e))return C1.get(e);let t=function(i,r,s){if(arguments.length!==3)throw new Error("@IServiceName-decorator can only be used to decorate a parameter");NZ(t,i,s)};return t._id=e,C1.set(e,t),t}function NZ(e,t,i){t[y8]===t?t[qu].push({id:e,index:i}):(t[qu]=[{id:e,index:i}],t[y8]=t)}var Ai=ei("BufferService"),sv=ei("CoreMouseService"),cn=ei("CoreService"),HZ=ei("CharsetService"),Od=ei("InstantiationService"),nv=ei("LogService"),Mi=ei("OptionsService"),av=ei("OscLinkService"),PZ=ei("UnicodeService"),El=ei("DecorationService"),Gu=class{constructor(e,t,i){this._bufferService=e,this._optionsService=t,this._oscLinkService=i}provideLinks(e,t){var u;let i=this._bufferService.buffer.lines.get(e-1);if(!i){t(void 0);return}let r=[],s=this._optionsService.rawOptions.linkHandler,n=new Ki,a=i.getTrimmedLength(),o=-1,l=-1,c=!1;for(let h=0;h<a;h++)if(!(l===-1&&!i.hasContent(h))){if(i.loadCell(h,n),n.hasExtendedAttrs()&&n.extended.urlId)if(l===-1){l=h,o=n.extended.urlId;continue}else c=n.extended.urlId!==o;else l!==-1&&(c=!0);if(c||l!==-1&&h===a-1){let d=(u=this._oscLinkService.getLinkData(o))==null?void 0:u.uri;if(d){let f={start:{x:l+1,y:e},end:{x:h+(!c&&h===a-1?1:0),y:e}},m=!1;if(!(s!=null&&s.allowNonHttpProtocols))try{let _=new URL(d);["http:","https:"].includes(_.protocol)||(m=!0)}catch{m=!0}m||r.push({text:d,range:f,activate:(_,y)=>s?s.activate(_,y,f):OZ(_,y),hover:(_,y)=>{var p;return(p=s==null?void 0:s.hover)==null?void 0:p.call(s,_,y,f)},leave:(_,y)=>{var p;return(p=s==null?void 0:s.leave)==null?void 0:p.call(s,_,y,f)}})}c=!1,n.hasExtendedAttrs()&&n.extended.urlId?(l=h,o=n.extended.urlId):(l=-1,o=-1)}}t(r)}};Gu=Tt([Te(0,Ai),Te(1,Mi),Te(2,av)],Gu);function OZ(e,t){if(confirm(`Do you want to navigate to ${t}?
|
|
81
|
-
|
|
82
|
-
WARNING: This link could potentially be dangerous`)){let i=window.open();if(i){try{i.opener=null}catch{}i.location.href=t}else console.warn("Opening link blocked as opener could not be cleared")}}var Oc=ei("CharSizeService"),Jr=ei("CoreBrowserService"),Id=ei("MouseService"),Qr=ei("RenderService"),IZ=ei("SelectionService"),ov=ei("CharacterJoinerService"),$a=ei("ThemeService"),lv=ei("LinkProviderService"),RZ=class{constructor(){this.listeners=[],this.unexpectedErrorHandler=function(e){setTimeout(()=>{throw e.stack?w8.isErrorNoTelemetry(e)?new w8(e.message+`
|
|
83
|
-
|
|
84
|
-
`+e.stack):new Error(e.message+`
|
|
85
|
-
|
|
86
|
-
`+e.stack):e},0)}}addListener(e){return this.listeners.push(e),()=>{this._removeListener(e)}}emit(e){this.listeners.forEach(t=>{t(e)})}_removeListener(e){this.listeners.splice(this.listeners.indexOf(e),1)}setUnexpectedErrorHandler(e){this.unexpectedErrorHandler=e}getUnexpectedErrorHandler(){return this.unexpectedErrorHandler}onUnexpectedError(e){this.unexpectedErrorHandler(e),this.emit(e)}onUnexpectedExternalError(e){this.unexpectedErrorHandler(e)}},DZ=new RZ;function h0(e){VZ(e)||DZ.onUnexpectedError(e)}var Yu="Canceled";function VZ(e){return e instanceof BZ?!0:e instanceof Error&&e.name===Yu&&e.message===Yu}var BZ=class extends Error{constructor(){super(Yu),this.name=this.message}};function ZZ(e){return new Error(`Illegal argument: ${e}`)}var w8=class Xu extends Error{constructor(t){super(t),this.name="CodeExpectedError"}static fromError(t){if(t instanceof Xu)return t;let i=new Xu;return i.message=t.message,i.stack=t.stack,i}static isErrorNoTelemetry(t){return t.name==="CodeExpectedError"}},Ju=class cv extends Error{constructor(t){super(t||"An unexpected bug occurred."),Object.setPrototypeOf(this,cv.prototype)}};function xi(e,t=0){return e[e.length-(1+t)]}var FZ;(e=>{function t(n){return n<0}e.isLessThan=t;function i(n){return n<=0}e.isLessThanOrEqual=i;function r(n){return n>0}e.isGreaterThan=r;function s(n){return n===0}e.isNeitherLessOrGreaterThan=s,e.greaterThan=1,e.lessThan=-1,e.neitherLessOrGreaterThan=0})(FZ||(FZ={}));function zZ(e,t){let i=this,r=!1,s;return function(){return r||(r=!0,t||(s=e.apply(i,arguments))),s}}var uv;(e=>{function t(v){return v&&typeof v=="object"&&typeof v[Symbol.iterator]=="function"}e.is=t;let i=Object.freeze([]);function r(){return i}e.empty=r;function*s(v){yield v}e.single=s;function n(v){return t(v)?v:s(v)}e.wrap=n;function a(v){return v||i}e.from=a;function*o(v){for(let k=v.length-1;k>=0;k--)yield v[k]}e.reverse=o;function l(v){return!v||v[Symbol.iterator]().next().done===!0}e.isEmpty=l;function c(v){return v[Symbol.iterator]().next().value}e.first=c;function u(v,k){let $=0;for(let M of v)if(k(M,$++))return!0;return!1}e.some=u;function h(v,k){for(let $ of v)if(k($))return $}e.find=h;function*d(v,k){for(let $ of v)k($)&&(yield $)}e.filter=d;function*f(v,k){let $=0;for(let M of v)yield k(M,$++)}e.map=f;function*m(v,k){let $=0;for(let M of v)yield*k(M,$++)}e.flatMap=m;function*_(...v){for(let k of v)yield*k}e.concat=_;function y(v,k,$){let M=$;for(let D of v)M=k(M,D);return M}e.reduce=y;function*p(v,k,$=v.length){for(k<0&&(k+=v.length),$<0?$+=v.length:$>v.length&&($=v.length);k<$;k++)yield v[k]}e.slice=p;function C(v,k=Number.POSITIVE_INFINITY){let $=[];if(k===0)return[$,v];let M=v[Symbol.iterator]();for(let D=0;D<k;D++){let H=M.next();if(H.done)return[$,e.empty()];$.push(H.value)}return[$,{[Symbol.iterator](){return M}}]}e.consume=C;async function w(v){let k=[];for await(let $ of v)k.push($);return Promise.resolve(k)}e.asyncToArray=w})(uv||(uv={}));function sn(e){if(uv.is(e)){let t=[];for(let i of e)if(i)try{i.dispose()}catch(r){t.push(r)}if(t.length===1)throw t[0];if(t.length>1)throw new AggregateError(t,"Encountered errors while disposing of store");return Array.isArray(e)?[]:e}else if(e)return e.dispose(),e}function UZ(...e){return St(()=>sn(e))}function St(e){return{dispose:zZ(()=>{e()})}}var hv=class dv{constructor(){this._toDispose=new Set,this._isDisposed=!1}dispose(){this._isDisposed||(this._isDisposed=!0,this.clear())}get isDisposed(){return this._isDisposed}clear(){if(this._toDispose.size!==0)try{sn(this._toDispose)}finally{this._toDispose.clear()}}add(t){if(!t)return t;if(t===this)throw new Error("Cannot register a disposable on itself!");return this._isDisposed?dv.DISABLE_DISPOSED_WARNING||console.warn(new Error("Trying to add a disposable to a DisposableStore that has already been disposed of. The added object will be leaked!").stack):this._toDispose.add(t),t}delete(t){if(t){if(t===this)throw new Error("Cannot dispose a disposable on itself!");this._toDispose.delete(t),t.dispose()}}deleteAndLeak(t){t&&this._toDispose.has(t)&&(this._toDispose.delete(t),void 0)}};hv.DISABLE_DISPOSED_WARNING=!1;var gs=hv,qe=class{constructor(){this._store=new gs,this._store}dispose(){this._store.dispose()}_register(e){if(e===this)throw new Error("Cannot register a disposable on itself!");return this._store.add(e)}};qe.None=Object.freeze({dispose(){}});var Kn=class{constructor(){this._isDisposed=!1}get value(){return this._isDisposed?void 0:this._value}set value(e){var t;this._isDisposed||e===this._value||((t=this._value)==null||t.dispose(),this._value=e)}clear(){this.value=void 0}dispose(){var e;this._isDisposed=!0,(e=this._value)==null||e.dispose(),this._value=void 0}clearAndLeak(){let e=this._value;return this._value=void 0,e}},Wr=typeof window=="object"?window:globalThis,Qu=class eh{constructor(t){this.element=t,this.next=eh.Undefined,this.prev=eh.Undefined}};Qu.Undefined=new Qu(void 0);var Ct=Qu,S8=class{constructor(){this._first=Ct.Undefined,this._last=Ct.Undefined,this._size=0}get size(){return this._size}isEmpty(){return this._first===Ct.Undefined}clear(){let e=this._first;for(;e!==Ct.Undefined;){let t=e.next;e.prev=Ct.Undefined,e.next=Ct.Undefined,e=t}this._first=Ct.Undefined,this._last=Ct.Undefined,this._size=0}unshift(e){return this._insert(e,!1)}push(e){return this._insert(e,!0)}_insert(e,t){let i=new Ct(e);if(this._first===Ct.Undefined)this._first=i,this._last=i;else if(t){let s=this._last;this._last=i,i.prev=s,s.next=i}else{let s=this._first;this._first=i,i.next=s,s.prev=i}this._size+=1;let r=!1;return()=>{r||(r=!0,this._remove(i))}}shift(){if(this._first!==Ct.Undefined){let e=this._first.element;return this._remove(this._first),e}}pop(){if(this._last!==Ct.Undefined){let e=this._last.element;return this._remove(this._last),e}}_remove(e){if(e.prev!==Ct.Undefined&&e.next!==Ct.Undefined){let t=e.prev;t.next=e.next,e.next.prev=t}else e.prev===Ct.Undefined&&e.next===Ct.Undefined?(this._first=Ct.Undefined,this._last=Ct.Undefined):e.next===Ct.Undefined?(this._last=this._last.prev,this._last.next=Ct.Undefined):e.prev===Ct.Undefined&&(this._first=this._first.next,this._first.prev=Ct.Undefined);this._size-=1}*[Symbol.iterator](){let e=this._first;for(;e!==Ct.Undefined;)yield e.element,e=e.next}},WZ=globalThis.performance&&typeof globalThis.performance.now=="function",jZ=class fv{static create(t){return new fv(t)}constructor(t){this._now=WZ&&t===!1?Date.now:globalThis.performance.now.bind(globalThis.performance),this._startTime=this._now(),this._stopTime=-1}stop(){this._stopTime=this._now()}reset(){this._startTime=this._now(),this._stopTime=-1}elapsed(){return this._stopTime!==-1?this._stopTime-this._startTime:this._now()-this._startTime}},si;(e=>{e.None=()=>qe.None;function t(N,P){return h(N,()=>{},0,void 0,!0,void 0,P)}e.defer=t;function i(N){return(P,U=null,j)=>{let oe=!1,te;return te=N(ne=>{if(!oe)return te?te.dispose():oe=!0,P.call(U,ne)},null,j),oe&&te.dispose(),te}}e.once=i;function r(N,P,U){return c((j,oe=null,te)=>N(ne=>j.call(oe,P(ne)),null,te),U)}e.map=r;function s(N,P,U){return c((j,oe=null,te)=>N(ne=>{P(ne),j.call(oe,ne)},null,te),U)}e.forEach=s;function n(N,P,U){return c((j,oe=null,te)=>N(ne=>P(ne)&&j.call(oe,ne),null,te),U)}e.filter=n;function a(N){return N}e.signal=a;function o(...N){return(P,U=null,j)=>{let oe=UZ(...N.map(te=>te(ne=>P.call(U,ne))));return u(oe,j)}}e.any=o;function l(N,P,U,j){let oe=U;return r(N,te=>(oe=P(oe,te),oe),j)}e.reduce=l;function c(N,P){let U,j={onWillAddFirstListener(){U=N(oe.fire,oe)},onDidRemoveLastListener(){U==null||U.dispose()}},oe=new Ae(j);return P==null||P.add(oe),oe.event}function u(N,P){return P instanceof Array?P.push(N):P&&P.add(N),N}function h(N,P,U=100,j=!1,oe=!1,te,ne){let J,fe,re,_e=0,Ne,$e={leakWarningThreshold:te,onWillAddFirstListener(){J=N(me=>{_e++,fe=P(fe,me),j&&!re&&(be.fire(fe),fe=void 0),Ne=()=>{let O=fe;fe=void 0,re=void 0,(!j||_e>1)&&be.fire(O),_e=0},typeof U=="number"?(clearTimeout(re),re=setTimeout(Ne,U)):re===void 0&&(re=0,queueMicrotask(Ne))})},onWillRemoveListener(){oe&&_e>0&&(Ne==null||Ne())},onDidRemoveLastListener(){Ne=void 0,J.dispose()}},be=new Ae($e);return ne==null||ne.add(be),be.event}e.debounce=h;function d(N,P=0,U){return e.debounce(N,(j,oe)=>j?(j.push(oe),j):[oe],P,void 0,!0,void 0,U)}e.accumulate=d;function f(N,P=(j,oe)=>j===oe,U){let j=!0,oe;return n(N,te=>{let ne=j||!P(te,oe);return j=!1,oe=te,ne},U)}e.latch=f;function m(N,P,U){return[e.filter(N,P,U),e.filter(N,j=>!P(j),U)]}e.split=m;function _(N,P=!1,U=[],j){let oe=U.slice(),te=N(fe=>{oe?oe.push(fe):J.fire(fe)});j&&j.add(te);let ne=()=>{oe==null||oe.forEach(fe=>J.fire(fe)),oe=null},J=new Ae({onWillAddFirstListener(){te||(te=N(fe=>J.fire(fe)),j&&j.add(te))},onDidAddFirstListener(){oe&&(P?setTimeout(ne):ne())},onDidRemoveLastListener(){te&&te.dispose(),te=null}});return j&&j.add(J),J.event}e.buffer=_;function y(N,P){return(U,j,oe)=>{let te=P(new C);return N(function(ne){let J=te.evaluate(ne);J!==p&&U.call(j,J)},void 0,oe)}}e.chain=y;let p=Symbol("HaltChainable");class C{constructor(){this.steps=[]}map(P){return this.steps.push(P),this}forEach(P){return this.steps.push(U=>(P(U),U)),this}filter(P){return this.steps.push(U=>P(U)?U:p),this}reduce(P,U){let j=U;return this.steps.push(oe=>(j=P(j,oe),j)),this}latch(P=(U,j)=>U===j){let U=!0,j;return this.steps.push(oe=>{let te=U||!P(oe,j);return U=!1,j=oe,te?oe:p}),this}evaluate(P){for(let U of this.steps)if(P=U(P),P===p)break;return P}}function w(N,P,U=j=>j){let j=(...J)=>ne.fire(U(...J)),oe=()=>N.on(P,j),te=()=>N.removeListener(P,j),ne=new Ae({onWillAddFirstListener:oe,onDidRemoveLastListener:te});return ne.event}e.fromNodeEventEmitter=w;function v(N,P,U=j=>j){let j=(...J)=>ne.fire(U(...J)),oe=()=>N.addEventListener(P,j),te=()=>N.removeEventListener(P,j),ne=new Ae({onWillAddFirstListener:oe,onDidRemoveLastListener:te});return ne.event}e.fromDOMEventEmitter=v;function k(N){return new Promise(P=>i(N)(P))}e.toPromise=k;function $(N){let P=new Ae;return N.then(U=>{P.fire(U)},()=>{P.fire(void 0)}).finally(()=>{P.dispose()}),P.event}e.fromPromise=$;function M(N,P){return N(U=>P.fire(U))}e.forward=M;function D(N,P,U){return P(U),N(j=>P(j))}e.runAndSubscribe=D;class H{constructor(P,U){this._observable=P,this._counter=0,this._hasChanged=!1;let j={onWillAddFirstListener:()=>{P.addObserver(this)},onDidRemoveLastListener:()=>{P.removeObserver(this)}};this.emitter=new Ae(j),U&&U.add(this.emitter)}beginUpdate(P){this._counter++}handlePossibleChange(P){}handleChange(P,U){this._hasChanged=!0}endUpdate(P){this._counter--,this._counter===0&&(this._observable.reportChanges(),this._hasChanged&&(this._hasChanged=!1,this.emitter.fire(this._observable.get())))}}function R(N,P){return new H(N,P).emitter.event}e.fromObservable=R;function V(N){return(P,U,j)=>{let oe=0,te=!1,ne={beginUpdate(){oe++},endUpdate(){oe--,oe===0&&(N.reportChanges(),te&&(te=!1,P.call(U)))},handlePossibleChange(){},handleChange(){te=!0}};N.addObserver(ne),N.reportChanges();let J={dispose(){N.removeObserver(ne)}};return j instanceof gs?j.add(J):Array.isArray(j)&&j.push(J),J}}e.fromObservableLight=V})(si||(si={}));var th=class ih{constructor(t){this.listenerCount=0,this.invocationCount=0,this.elapsedOverall=0,this.durations=[],this.name=`${t}_${ih._idPool++}`,ih.all.add(this)}start(t){this._stopWatch=new jZ,this.listenerCount=t}stop(){if(this._stopWatch){let t=this._stopWatch.elapsed();this.durations.push(t),this.elapsedOverall+=t,this.invocationCount+=1,this._stopWatch=void 0}}};th.all=new Set,th._idPool=0;var KZ=th,qZ=-1,pv=class _v{constructor(t,i,r=(_v._idPool++).toString(16).padStart(3,"0")){this._errorHandler=t,this.threshold=i,this.name=r,this._warnCountdown=0}dispose(){var t;(t=this._stacks)==null||t.clear()}check(t,i){let r=this.threshold;if(r<=0||i<r)return;this._stacks||(this._stacks=new Map);let s=this._stacks.get(t.value)||0;if(this._stacks.set(t.value,s+1),this._warnCountdown-=1,this._warnCountdown<=0){this._warnCountdown=r*.5;let[n,a]=this.getMostFrequentStack(),o=`[${this.name}] potential listener LEAK detected, having ${i} listeners already. MOST frequent listener (${a}):`;console.warn(o),console.warn(n);let l=new XZ(o,n);this._errorHandler(l)}return()=>{let n=this._stacks.get(t.value)||0;this._stacks.set(t.value,n-1)}}getMostFrequentStack(){if(!this._stacks)return;let t,i=0;for(let[r,s]of this._stacks)(!t||i<s)&&(t=[r,s],i=s);return t}};pv._idPool=1;var GZ=pv,YZ=class mv{constructor(t){this.value=t}static create(){let t=new Error;return new mv(t.stack??"")}print(){console.warn(this.value.split(`
|
|
87
|
-
`).slice(2).join(`
|
|
88
|
-
`))}},XZ=class extends Error{constructor(e,t){super(e),this.name="ListenerLeakError",this.stack=t}},JZ=class extends Error{constructor(e,t){super(e),this.name="ListenerRefusalError",this.stack=t}},QZ=0,k1=class{constructor(e){this.value=e,this.id=QZ++}},eF=2,tF,Ae=class{constructor(e){var t,i,r,s;this._size=0,this._options=e,this._leakageMon=(t=this._options)!=null&&t.leakWarningThreshold?new GZ((e==null?void 0:e.onListenerError)??h0,((i=this._options)==null?void 0:i.leakWarningThreshold)??qZ):void 0,this._perfMon=(r=this._options)!=null&&r._profName?new KZ(this._options._profName):void 0,this._deliveryQueue=(s=this._options)==null?void 0:s.deliveryQueue}dispose(){var e,t,i,r;this._disposed||(this._disposed=!0,((e=this._deliveryQueue)==null?void 0:e.current)===this&&this._deliveryQueue.reset(),this._listeners&&(this._listeners=void 0,this._size=0),(i=(t=this._options)==null?void 0:t.onDidRemoveLastListener)==null||i.call(t),(r=this._leakageMon)==null||r.dispose())}get event(){return this._event??(this._event=(e,t,i)=>{var a,o,l,c,u;if(this._leakageMon&&this._size>this._leakageMon.threshold**2){let h=`[${this._leakageMon.name}] REFUSES to accept new listeners because it exceeded its threshold by far (${this._size} vs ${this._leakageMon.threshold})`;console.warn(h);let d=this._leakageMon.getMostFrequentStack()??["UNKNOWN stack",-1],f=new JZ(`${h}. HINT: Stack shows most frequent listener (${d[1]}-times)`,d[0]);return(((a=this._options)==null?void 0:a.onListenerError)||h0)(f),qe.None}if(this._disposed)return qe.None;t&&(e=e.bind(t));let r=new k1(e),s;this._leakageMon&&this._size>=Math.ceil(this._leakageMon.threshold*.2)&&(r.stack=YZ.create(),s=this._leakageMon.check(r.stack,this._size+1)),this._listeners?this._listeners instanceof k1?(this._deliveryQueue??(this._deliveryQueue=new iF),this._listeners=[this._listeners,r]):this._listeners.push(r):((l=(o=this._options)==null?void 0:o.onWillAddFirstListener)==null||l.call(o,this),this._listeners=r,(u=(c=this._options)==null?void 0:c.onDidAddFirstListener)==null||u.call(c,this)),this._size++;let n=St(()=>{s==null||s(),this._removeListener(r)});return i instanceof gs?i.add(n):Array.isArray(i)&&i.push(n),n}),this._event}_removeListener(e){var s,n,a,o;if((n=(s=this._options)==null?void 0:s.onWillRemoveListener)==null||n.call(s,this),!this._listeners)return;if(this._size===1){this._listeners=void 0,(o=(a=this._options)==null?void 0:a.onDidRemoveLastListener)==null||o.call(a,this),this._size=0;return}let t=this._listeners,i=t.indexOf(e);if(i===-1)throw console.log("disposed?",this._disposed),console.log("size?",this._size),console.log("arr?",JSON.stringify(this._listeners)),new Error("Attempted to dispose unknown listener");this._size--,t[i]=void 0;let r=this._deliveryQueue.current===this;if(this._size*eF<=t.length){let l=0;for(let c=0;c<t.length;c++)t[c]?t[l++]=t[c]:r&&(this._deliveryQueue.end--,l<this._deliveryQueue.i&&this._deliveryQueue.i--);t.length=l}}_deliver(e,t){var r;if(!e)return;let i=((r=this._options)==null?void 0:r.onListenerError)||h0;if(!i){e.value(t);return}try{e.value(t)}catch(s){i(s)}}_deliverQueue(e){let t=e.current._listeners;for(;e.i<e.end;)this._deliver(t[e.i++],e.value);e.reset()}fire(e){var t,i,r,s;if((t=this._deliveryQueue)!=null&&t.current&&(this._deliverQueue(this._deliveryQueue),(i=this._perfMon)==null||i.stop()),(r=this._perfMon)==null||r.start(this._size),this._listeners)if(this._listeners instanceof k1)this._deliver(this._listeners,e);else{let n=this._deliveryQueue;n.enqueue(this,e,this._listeners.length),this._deliverQueue(n)}(s=this._perfMon)==null||s.stop()}hasListeners(){return this._size>0}},iF=class{constructor(){this.i=-1,this.end=0}enqueue(e,t,i){this.i=0,this.end=i,this.current=e,this.value=t}reset(){this.i=this.end,this.current=void 0,this.value=void 0}},rh=class{constructor(){this.mapWindowIdToZoomLevel=new Map,this._onDidChangeZoomLevel=new Ae,this.onDidChangeZoomLevel=this._onDidChangeZoomLevel.event,this.mapWindowIdToZoomFactor=new Map,this._onDidChangeFullscreen=new Ae,this.onDidChangeFullscreen=this._onDidChangeFullscreen.event,this.mapWindowIdToFullScreen=new Map}getZoomLevel(t){return this.mapWindowIdToZoomLevel.get(this.getWindowId(t))??0}setZoomLevel(t,i){if(this.getZoomLevel(i)===t)return;let r=this.getWindowId(i);this.mapWindowIdToZoomLevel.set(r,t),this._onDidChangeZoomLevel.fire(r)}getZoomFactor(t){return this.mapWindowIdToZoomFactor.get(this.getWindowId(t))??1}setZoomFactor(t,i){this.mapWindowIdToZoomFactor.set(this.getWindowId(i),t)}setFullscreen(t,i){if(this.isFullscreen(i)===t)return;let r=this.getWindowId(i);this.mapWindowIdToFullScreen.set(r,t),this._onDidChangeFullscreen.fire(r)}isFullscreen(t){return!!this.mapWindowIdToFullScreen.get(this.getWindowId(t))}getWindowId(t){return t.vscodeWindowId}};rh.INSTANCE=new rh;var Rd=rh;function rF(e,t,i){typeof t=="string"&&(t=e.matchMedia(t)),t.addEventListener("change",i)}Rd.INSTANCE.onDidChangeZoomLevel;function sF(e){return Rd.INSTANCE.getZoomFactor(e)}Rd.INSTANCE.onDidChangeFullscreen;var xa=typeof navigator=="object"?navigator.userAgent:"",sh=xa.indexOf("Firefox")>=0,nF=xa.indexOf("AppleWebKit")>=0,Dd=xa.indexOf("Chrome")>=0,aF=!Dd&&xa.indexOf("Safari")>=0;xa.indexOf("Electron/")>=0;xa.indexOf("Android")>=0;var A1=!1;if(typeof Wr.matchMedia=="function"){let e=Wr.matchMedia("(display-mode: standalone) or (display-mode: window-controls-overlay)"),t=Wr.matchMedia("(display-mode: fullscreen)");A1=e.matches,rF(Wr,e,({matches:i})=>{A1&&t.matches||(A1=i)})}var An="en",nh=!1,ah=!1,d0=!1,gv=!1,Yl,f0=An,C8=An,oF,Xi,en=globalThis,ii,zp;typeof en.vscode<"u"&&typeof en.vscode.process<"u"?ii=en.vscode.process:typeof process<"u"&&typeof((zp=process==null?void 0:process.versions)==null?void 0:zp.node)=="string"&&(ii=process);var Up,lF=typeof((Up=ii==null?void 0:ii.versions)==null?void 0:Up.electron)=="string",cF=lF&&(ii==null?void 0:ii.type)==="renderer",Wp;if(typeof ii=="object"){nh=ii.platform==="win32",ah=ii.platform==="darwin",d0=ii.platform==="linux",d0&&ii.env.SNAP&&ii.env.SNAP_REVISION,ii.env.CI||ii.env.BUILD_ARTIFACTSTAGINGDIRECTORY,Yl=An,f0=An;let e=ii.env.VSCODE_NLS_CONFIG;if(e)try{let t=JSON.parse(e);Yl=t.userLocale,C8=t.osLocale,f0=t.resolvedLanguage||An,oF=(Wp=t.languagePack)==null?void 0:Wp.translationsConfigFile}catch{}gv=!0}else typeof navigator=="object"&&!cF?(Xi=navigator.userAgent,nh=Xi.indexOf("Windows")>=0,ah=Xi.indexOf("Macintosh")>=0,(Xi.indexOf("Macintosh")>=0||Xi.indexOf("iPad")>=0||Xi.indexOf("iPhone")>=0)&&navigator.maxTouchPoints&&navigator.maxTouchPoints>0,d0=Xi.indexOf("Linux")>=0,(Xi==null?void 0:Xi.indexOf("Mobi"))>=0,f0=globalThis._VSCODE_NLS_LANGUAGE||An,Yl=navigator.language.toLowerCase(),C8=Yl):console.error("Unable to resolve platform.");var vv=nh,kr=ah,uF=d0,k8=gv,Mr=Xi,rs=f0,hF;(e=>{function t(){return rs}e.value=t;function i(){return rs.length===2?rs==="en":rs.length>=3?rs[0]==="e"&&rs[1]==="n"&&rs[2]==="-":!1}e.isDefaultVariant=i;function r(){return rs==="en"}e.isDefault=r})(hF||(hF={}));var dF=typeof en.postMessage=="function"&&!en.importScripts;(()=>{if(dF){let e=[];en.addEventListener("message",i=>{if(i.data&&i.data.vscodeScheduleAsyncWork)for(let r=0,s=e.length;r<s;r++){let n=e[r];if(n.id===i.data.vscodeScheduleAsyncWork){e.splice(r,1),n.callback();return}}});let t=0;return i=>{let r=++t;e.push({id:r,callback:i}),en.postMessage({vscodeScheduleAsyncWork:r},"*")}}return e=>setTimeout(e)})();var fF=!!(Mr&&Mr.indexOf("Chrome")>=0);Mr&&Mr.indexOf("Firefox")>=0;!fF&&Mr&&Mr.indexOf("Safari")>=0;Mr&&Mr.indexOf("Edg/")>=0;Mr&&Mr.indexOf("Android")>=0;var mn=typeof navigator=="object"?navigator:{};k8||document.queryCommandSupported&&document.queryCommandSupported("copy")||mn&&mn.clipboard&&mn.clipboard.writeText,k8||mn&&mn.clipboard&&mn.clipboard.readText;var Vd=class{constructor(){this._keyCodeToStr=[],this._strToKeyCode=Object.create(null)}define(e,t){this._keyCodeToStr[e]=t,this._strToKeyCode[t.toLowerCase()]=e}keyCodeToStr(e){return this._keyCodeToStr[e]}strToKeyCode(e){return this._strToKeyCode[e.toLowerCase()]||0}},M1=new Vd,A8=new Vd,M8=new Vd,pF=new Array(230),bv;(e=>{function t(o){return M1.keyCodeToStr(o)}e.toString=t;function i(o){return M1.strToKeyCode(o)}e.fromString=i;function r(o){return A8.keyCodeToStr(o)}e.toUserSettingsUS=r;function s(o){return M8.keyCodeToStr(o)}e.toUserSettingsGeneral=s;function n(o){return A8.strToKeyCode(o)||M8.strToKeyCode(o)}e.fromUserSettings=n;function a(o){if(o>=98&&o<=113)return null;switch(o){case 16:return"Up";case 18:return"Down";case 15:return"Left";case 17:return"Right"}return M1.keyCodeToStr(o)}e.toElectronAccelerator=a})(bv||(bv={}));var _F=class yv{constructor(t,i,r,s,n){this.ctrlKey=t,this.shiftKey=i,this.altKey=r,this.metaKey=s,this.keyCode=n}equals(t){return t instanceof yv&&this.ctrlKey===t.ctrlKey&&this.shiftKey===t.shiftKey&&this.altKey===t.altKey&&this.metaKey===t.metaKey&&this.keyCode===t.keyCode}getHashCode(){let t=this.ctrlKey?"1":"0",i=this.shiftKey?"1":"0",r=this.altKey?"1":"0",s=this.metaKey?"1":"0";return`K${t}${i}${r}${s}${this.keyCode}`}isModifierKey(){return this.keyCode===0||this.keyCode===5||this.keyCode===57||this.keyCode===6||this.keyCode===4}toKeybinding(){return new mF([this])}isDuplicateModifierCase(){return this.ctrlKey&&this.keyCode===5||this.shiftKey&&this.keyCode===4||this.altKey&&this.keyCode===6||this.metaKey&&this.keyCode===57}},mF=class{constructor(e){if(e.length===0)throw ZZ("chords");this.chords=e}getHashCode(){let e="";for(let t=0,i=this.chords.length;t<i;t++)t!==0&&(e+=";"),e+=this.chords[t].getHashCode();return e}equals(e){if(e===null||this.chords.length!==e.chords.length)return!1;for(let t=0;t<this.chords.length;t++)if(!this.chords[t].equals(e.chords[t]))return!1;return!0}};function gF(e){if(e.charCode){let i=String.fromCharCode(e.charCode).toUpperCase();return bv.fromString(i)}let t=e.keyCode;if(t===3)return 7;if(sh)switch(t){case 59:return 85;case 60:if(uF)return 97;break;case 61:return 86;case 107:return 109;case 109:return 111;case 173:return 88;case 224:if(kr)return 57;break}else if(nF&&(kr&&t===93||!kr&&t===92))return 57;return pF[t]||0}var vF=kr?256:2048,bF=512,yF=1024,wF=kr?2048:256,L8=class{constructor(e){var i;this._standardKeyboardEventBrand=!0;let t=e;this.browserEvent=t,this.target=t.target,this.ctrlKey=t.ctrlKey,this.shiftKey=t.shiftKey,this.altKey=t.altKey,this.metaKey=t.metaKey,this.altGraphKey=(i=t.getModifierState)==null?void 0:i.call(t,"AltGraph"),this.keyCode=gF(t),this.code=t.code,this.ctrlKey=this.ctrlKey||this.keyCode===5,this.altKey=this.altKey||this.keyCode===6,this.shiftKey=this.shiftKey||this.keyCode===4,this.metaKey=this.metaKey||this.keyCode===57,this._asKeybinding=this._computeKeybinding(),this._asKeyCodeChord=this._computeKeyCodeChord()}preventDefault(){this.browserEvent&&this.browserEvent.preventDefault&&this.browserEvent.preventDefault()}stopPropagation(){this.browserEvent&&this.browserEvent.stopPropagation&&this.browserEvent.stopPropagation()}toKeyCodeChord(){return this._asKeyCodeChord}equals(e){return this._asKeybinding===e}_computeKeybinding(){let e=0;this.keyCode!==5&&this.keyCode!==4&&this.keyCode!==6&&this.keyCode!==57&&(e=this.keyCode);let t=0;return this.ctrlKey&&(t|=vF),this.altKey&&(t|=bF),this.shiftKey&&(t|=yF),this.metaKey&&(t|=wF),t|=e,t}_computeKeyCodeChord(){let e=0;return this.keyCode!==5&&this.keyCode!==4&&this.keyCode!==6&&this.keyCode!==57&&(e=this.keyCode),new _F(this.ctrlKey,this.shiftKey,this.altKey,this.metaKey,e)}},E8=new WeakMap;function SF(e){if(!e.parent||e.parent===e)return null;try{let t=e.location,i=e.parent.location;if(t.origin!=="null"&&i.origin!=="null"&&t.origin!==i.origin)return null}catch{return null}return e.parent}var CF=class{static getSameOriginWindowChain(e){let t=E8.get(e);if(!t){t=[],E8.set(e,t);let i=e,r;do r=SF(i),r?t.push({window:new WeakRef(i),iframeElement:i.frameElement||null}):t.push({window:new WeakRef(i),iframeElement:null}),i=r;while(i)}return t.slice(0)}static getPositionOfChildWindowRelativeToAncestorWindow(e,t){if(!t||e===t)return{top:0,left:0};let i=0,r=0,s=this.getSameOriginWindowChain(e);for(let n of s){let a=n.window.deref();if(i+=(a==null?void 0:a.scrollY)??0,r+=(a==null?void 0:a.scrollX)??0,a===t||!n.iframeElement)break;let o=n.iframeElement.getBoundingClientRect();i+=o.top,r+=o.left}return{top:i,left:r}}},Xl=class{constructor(e,t){this.timestamp=Date.now(),this.browserEvent=t,this.leftButton=t.button===0,this.middleButton=t.button===1,this.rightButton=t.button===2,this.buttons=t.buttons,this.target=t.target,this.detail=t.detail||1,t.type==="dblclick"&&(this.detail=2),this.ctrlKey=t.ctrlKey,this.shiftKey=t.shiftKey,this.altKey=t.altKey,this.metaKey=t.metaKey,typeof t.pageX=="number"?(this.posx=t.pageX,this.posy=t.pageY):(this.posx=t.clientX+this.target.ownerDocument.body.scrollLeft+this.target.ownerDocument.documentElement.scrollLeft,this.posy=t.clientY+this.target.ownerDocument.body.scrollTop+this.target.ownerDocument.documentElement.scrollTop);let i=CF.getPositionOfChildWindowRelativeToAncestorWindow(e,t.view);this.posx-=i.left,this.posy-=i.top}preventDefault(){this.browserEvent.preventDefault()}stopPropagation(){this.browserEvent.stopPropagation()}},$8=class{constructor(e,t=0,i=0){var s;this.browserEvent=e||null,this.target=e?e.target||e.targetNode||e.srcElement:null,this.deltaY=i,this.deltaX=t;let r=!1;if(Dd){let n=navigator.userAgent.match(/Chrome\/(\d+)/);r=(n?parseInt(n[1]):123)<=122}if(e){let n=e,a=e,o=((s=e.view)==null?void 0:s.devicePixelRatio)||1;if(typeof n.wheelDeltaY<"u")r?this.deltaY=n.wheelDeltaY/(120*o):this.deltaY=n.wheelDeltaY/120;else if(typeof a.VERTICAL_AXIS<"u"&&a.axis===a.VERTICAL_AXIS)this.deltaY=-a.detail/3;else if(e.type==="wheel"){let l=e;l.deltaMode===l.DOM_DELTA_LINE?sh&&!kr?this.deltaY=-e.deltaY/3:this.deltaY=-e.deltaY:this.deltaY=-e.deltaY/40}if(typeof n.wheelDeltaX<"u")aF&&vv?this.deltaX=-(n.wheelDeltaX/120):r?this.deltaX=n.wheelDeltaX/(120*o):this.deltaX=n.wheelDeltaX/120;else if(typeof a.HORIZONTAL_AXIS<"u"&&a.axis===a.HORIZONTAL_AXIS)this.deltaX=-e.detail/3;else if(e.type==="wheel"){let l=e;l.deltaMode===l.DOM_DELTA_LINE?sh&&!kr?this.deltaX=-e.deltaX/3:this.deltaX=-e.deltaX:this.deltaX=-e.deltaX/40}this.deltaY===0&&this.deltaX===0&&e.wheelDelta&&(r?this.deltaY=e.wheelDelta/(120*o):this.deltaY=e.wheelDelta/120)}}preventDefault(){var e;(e=this.browserEvent)==null||e.preventDefault()}stopPropagation(){var e;(e=this.browserEvent)==null||e.stopPropagation()}},wv=Object.freeze(function(e,t){let i=setTimeout(e.bind(t),0);return{dispose(){clearTimeout(i)}}}),kF;(e=>{function t(i){return i===e.None||i===e.Cancelled||i instanceof AF?!0:!i||typeof i!="object"?!1:typeof i.isCancellationRequested=="boolean"&&typeof i.onCancellationRequested=="function"}e.isCancellationToken=t,e.None=Object.freeze({isCancellationRequested:!1,onCancellationRequested:si.None}),e.Cancelled=Object.freeze({isCancellationRequested:!0,onCancellationRequested:wv})})(kF||(kF={}));var AF=class{constructor(){this._isCancelled=!1,this._emitter=null}cancel(){this._isCancelled||(this._isCancelled=!0,this._emitter&&(this._emitter.fire(void 0),this.dispose()))}get isCancellationRequested(){return this._isCancelled}get onCancellationRequested(){return this._isCancelled?wv:(this._emitter||(this._emitter=new Ae),this._emitter.event)}dispose(){this._emitter&&(this._emitter.dispose(),this._emitter=null)}},Bd=class{constructor(e,t){this._isDisposed=!1,this._token=-1,typeof e=="function"&&typeof t=="number"&&this.setIfNotSet(e,t)}dispose(){this.cancel(),this._isDisposed=!0}cancel(){this._token!==-1&&(clearTimeout(this._token),this._token=-1)}cancelAndSet(e,t){if(this._isDisposed)throw new Ju("Calling 'cancelAndSet' on a disposed TimeoutTimer");this.cancel(),this._token=setTimeout(()=>{this._token=-1,e()},t)}setIfNotSet(e,t){if(this._isDisposed)throw new Ju("Calling 'setIfNotSet' on a disposed TimeoutTimer");this._token===-1&&(this._token=setTimeout(()=>{this._token=-1,e()},t))}},MF=class{constructor(){this.disposable=void 0,this.isDisposed=!1}cancel(){var e;(e=this.disposable)==null||e.dispose(),this.disposable=void 0}cancelAndSet(e,t,i=globalThis){if(this.isDisposed)throw new Ju("Calling 'cancelAndSet' on a disposed IntervalTimer");this.cancel();let r=i.setInterval(()=>{e()},t);this.disposable=St(()=>{i.clearInterval(r),this.disposable=void 0})}dispose(){this.cancel(),this.isDisposed=!0}},LF;(e=>{async function t(r){let s,n=await Promise.all(r.map(a=>a.then(o=>o,o=>{s||(s=o)})));if(typeof s<"u")throw s;return n}e.settled=t;function i(r){return new Promise(async(s,n)=>{try{await r(s,n)}catch(a){n(a)}})}e.withAsyncBody=i})(LF||(LF={}));var x8=class Zi{static fromArray(t){return new Zi(i=>{i.emitMany(t)})}static fromPromise(t){return new Zi(async i=>{i.emitMany(await t)})}static fromPromises(t){return new Zi(async i=>{await Promise.all(t.map(async r=>i.emitOne(await r)))})}static merge(t){return new Zi(async i=>{await Promise.all(t.map(async r=>{for await(let s of r)i.emitOne(s)}))})}constructor(t,i){this._state=0,this._results=[],this._error=null,this._onReturn=i,this._onStateChanged=new Ae,queueMicrotask(async()=>{let r={emitOne:s=>this.emitOne(s),emitMany:s=>this.emitMany(s),reject:s=>this.reject(s)};try{await Promise.resolve(t(r)),this.resolve()}catch(s){this.reject(s)}finally{r.emitOne=void 0,r.emitMany=void 0,r.reject=void 0}})}[Symbol.asyncIterator](){let t=0;return{next:async()=>{do{if(this._state===2)throw this._error;if(t<this._results.length)return{done:!1,value:this._results[t++]};if(this._state===1)return{done:!0,value:void 0};await si.toPromise(this._onStateChanged.event)}while(!0)},return:async()=>{var i;return(i=this._onReturn)==null||i.call(this),{done:!0,value:void 0}}}}static map(t,i){return new Zi(async r=>{for await(let s of t)r.emitOne(i(s))})}map(t){return Zi.map(this,t)}static filter(t,i){return new Zi(async r=>{for await(let s of t)i(s)&&r.emitOne(s)})}filter(t){return Zi.filter(this,t)}static coalesce(t){return Zi.filter(t,i=>!!i)}coalesce(){return Zi.coalesce(this)}static async toPromise(t){let i=[];for await(let r of t)i.push(r);return i}toPromise(){return Zi.toPromise(this)}emitOne(t){this._state===0&&(this._results.push(t),this._onStateChanged.fire())}emitMany(t){this._state===0&&(this._results=this._results.concat(t),this._onStateChanged.fire())}resolve(){this._state===0&&(this._state=1,this._onStateChanged.fire())}reject(t){this._state===0&&(this._state=2,this._error=t,this._onStateChanged.fire())}};x8.EMPTY=x8.fromArray([]);var{getWindow:gr,getWindowId:EF,onDidRegisterWindow:$F}=function(){let e=new Map,t={window:Wr,disposables:new gs};e.set(Wr.vscodeWindowId,t);let i=new Ae,r=new Ae,s=new Ae;function n(a,o){return(typeof a=="number"?e.get(a):void 0)??(o?t:void 0)}return{onDidRegisterWindow:i.event,onWillUnregisterWindow:s.event,onDidUnregisterWindow:r.event,registerWindow(a){if(e.has(a.vscodeWindowId))return qe.None;let o=new gs,l={window:a,disposables:o.add(new gs)};return e.set(a.vscodeWindowId,l),o.add(St(()=>{e.delete(a.vscodeWindowId),r.fire(a)})),o.add(ze(a,Kt.BEFORE_UNLOAD,()=>{s.fire(a)})),i.fire(l),o},getWindows(){return e.values()},getWindowsCount(){return e.size},getWindowId(a){return a.vscodeWindowId},hasWindow(a){return e.has(a)},getWindowById:n,getWindow(a){var c;let o=a;if((c=o==null?void 0:o.ownerDocument)!=null&&c.defaultView)return o.ownerDocument.defaultView.window;let l=a;return l!=null&&l.view?l.view.window:Wr},getDocument(a){return gr(a).document}}}(),xF=class{constructor(e,t,i,r){this._node=e,this._type=t,this._handler=i,this._options=r||!1,this._node.addEventListener(this._type,this._handler,this._options)}dispose(){this._handler&&(this._node.removeEventListener(this._type,this._handler,this._options),this._node=null,this._handler=null)}};function ze(e,t,i,r){return new xF(e,t,i,r)}var T8=function(e,t,i,r){return ze(e,t,i,r)},Zd,TF=class extends MF{constructor(e){super(),this.defaultTarget=e&&gr(e)}cancelAndSet(e,t,i){return super.cancelAndSet(e,t,i??this.defaultTarget)}},N8=class{constructor(e,t=0){this._runner=e,this.priority=t,this._canceled=!1}dispose(){this._canceled=!0}execute(){if(!this._canceled)try{this._runner()}catch(e){h0(e)}}static sort(e,t){return t.priority-e.priority}};(function(){let e=new Map,t=new Map,i=new Map,r=new Map,s=n=>{i.set(n,!1);let a=e.get(n)??[];for(t.set(n,a),e.set(n,[]),r.set(n,!0);a.length>0;)a.sort(N8.sort),a.shift().execute();r.set(n,!1)};Zd=(n,a,o=0)=>{let l=EF(n),c=new N8(a,o),u=e.get(l);return u||(u=[],e.set(l,u)),u.push(c),i.get(l)||(i.set(l,!0),n.requestAnimationFrame(()=>s(l))),c}})();function NF(e){let t=e.getBoundingClientRect(),i=gr(e);return{left:t.left+i.scrollX,top:t.top+i.scrollY,width:t.width,height:t.height}}var Kt={CLICK:"click",MOUSE_DOWN:"mousedown",MOUSE_OVER:"mouseover",MOUSE_LEAVE:"mouseleave",MOUSE_WHEEL:"wheel",POINTER_UP:"pointerup",POINTER_DOWN:"pointerdown",POINTER_MOVE:"pointermove",KEY_DOWN:"keydown",KEY_UP:"keyup",BEFORE_UNLOAD:"beforeunload",CHANGE:"change",FOCUS:"focus",BLUR:"blur",INPUT:"input"},HF=class{constructor(e){this.domNode=e,this._maxWidth="",this._width="",this._height="",this._top="",this._left="",this._bottom="",this._right="",this._paddingTop="",this._paddingLeft="",this._paddingBottom="",this._paddingRight="",this._fontFamily="",this._fontWeight="",this._fontSize="",this._fontStyle="",this._fontFeatureSettings="",this._fontVariationSettings="",this._textDecoration="",this._lineHeight="",this._letterSpacing="",this._className="",this._display="",this._position="",this._visibility="",this._color="",this._backgroundColor="",this._layerHint=!1,this._contain="none",this._boxShadow=""}setMaxWidth(e){let t=Li(e);this._maxWidth!==t&&(this._maxWidth=t,this.domNode.style.maxWidth=this._maxWidth)}setWidth(e){let t=Li(e);this._width!==t&&(this._width=t,this.domNode.style.width=this._width)}setHeight(e){let t=Li(e);this._height!==t&&(this._height=t,this.domNode.style.height=this._height)}setTop(e){let t=Li(e);this._top!==t&&(this._top=t,this.domNode.style.top=this._top)}setLeft(e){let t=Li(e);this._left!==t&&(this._left=t,this.domNode.style.left=this._left)}setBottom(e){let t=Li(e);this._bottom!==t&&(this._bottom=t,this.domNode.style.bottom=this._bottom)}setRight(e){let t=Li(e);this._right!==t&&(this._right=t,this.domNode.style.right=this._right)}setPaddingTop(e){let t=Li(e);this._paddingTop!==t&&(this._paddingTop=t,this.domNode.style.paddingTop=this._paddingTop)}setPaddingLeft(e){let t=Li(e);this._paddingLeft!==t&&(this._paddingLeft=t,this.domNode.style.paddingLeft=this._paddingLeft)}setPaddingBottom(e){let t=Li(e);this._paddingBottom!==t&&(this._paddingBottom=t,this.domNode.style.paddingBottom=this._paddingBottom)}setPaddingRight(e){let t=Li(e);this._paddingRight!==t&&(this._paddingRight=t,this.domNode.style.paddingRight=this._paddingRight)}setFontFamily(e){this._fontFamily!==e&&(this._fontFamily=e,this.domNode.style.fontFamily=this._fontFamily)}setFontWeight(e){this._fontWeight!==e&&(this._fontWeight=e,this.domNode.style.fontWeight=this._fontWeight)}setFontSize(e){let t=Li(e);this._fontSize!==t&&(this._fontSize=t,this.domNode.style.fontSize=this._fontSize)}setFontStyle(e){this._fontStyle!==e&&(this._fontStyle=e,this.domNode.style.fontStyle=this._fontStyle)}setFontFeatureSettings(e){this._fontFeatureSettings!==e&&(this._fontFeatureSettings=e,this.domNode.style.fontFeatureSettings=this._fontFeatureSettings)}setFontVariationSettings(e){this._fontVariationSettings!==e&&(this._fontVariationSettings=e,this.domNode.style.fontVariationSettings=this._fontVariationSettings)}setTextDecoration(e){this._textDecoration!==e&&(this._textDecoration=e,this.domNode.style.textDecoration=this._textDecoration)}setLineHeight(e){let t=Li(e);this._lineHeight!==t&&(this._lineHeight=t,this.domNode.style.lineHeight=this._lineHeight)}setLetterSpacing(e){let t=Li(e);this._letterSpacing!==t&&(this._letterSpacing=t,this.domNode.style.letterSpacing=this._letterSpacing)}setClassName(e){this._className!==e&&(this._className=e,this.domNode.className=this._className)}toggleClassName(e,t){this.domNode.classList.toggle(e,t),this._className=this.domNode.className}setDisplay(e){this._display!==e&&(this._display=e,this.domNode.style.display=this._display)}setPosition(e){this._position!==e&&(this._position=e,this.domNode.style.position=this._position)}setVisibility(e){this._visibility!==e&&(this._visibility=e,this.domNode.style.visibility=this._visibility)}setColor(e){this._color!==e&&(this._color=e,this.domNode.style.color=this._color)}setBackgroundColor(e){this._backgroundColor!==e&&(this._backgroundColor=e,this.domNode.style.backgroundColor=this._backgroundColor)}setLayerHinting(e){this._layerHint!==e&&(this._layerHint=e,this.domNode.style.transform=this._layerHint?"translate3d(0px, 0px, 0px)":"")}setBoxShadow(e){this._boxShadow!==e&&(this._boxShadow=e,this.domNode.style.boxShadow=e)}setContain(e){this._contain!==e&&(this._contain=e,this.domNode.style.contain=this._contain)}setAttribute(e,t){this.domNode.setAttribute(e,t)}removeAttribute(e){this.domNode.removeAttribute(e)}appendChild(e){this.domNode.appendChild(e.domNode)}removeChild(e){this.domNode.removeChild(e.domNode)}};function Li(e){return typeof e=="number"?`${e}px`:e}function zo(e){return new HF(e)}var Sv=class{constructor(){this._hooks=new gs,this._pointerMoveCallback=null,this._onStopCallback=null}dispose(){this.stopMonitoring(!1),this._hooks.dispose()}stopMonitoring(e,t){if(!this.isMonitoring())return;this._hooks.clear(),this._pointerMoveCallback=null;let i=this._onStopCallback;this._onStopCallback=null,e&&i&&i(t)}isMonitoring(){return!!this._pointerMoveCallback}startMonitoring(e,t,i,r,s){this.isMonitoring()&&this.stopMonitoring(!1),this._pointerMoveCallback=r,this._onStopCallback=s;let n=e;try{e.setPointerCapture(t),this._hooks.add(St(()=>{try{e.releasePointerCapture(t)}catch{}}))}catch{n=gr(e)}this._hooks.add(ze(n,Kt.POINTER_MOVE,a=>{if(a.buttons!==i){this.stopMonitoring(!0);return}a.preventDefault(),this._pointerMoveCallback(a)})),this._hooks.add(ze(n,Kt.POINTER_UP,a=>this.stopMonitoring(!0)))}};function PF(e,t,i){let r=null,s=null;if(typeof i.value=="function"?(r="value",s=i.value,s.length!==0&&console.warn("Memoize should only be used in functions with zero parameters")):typeof i.get=="function"&&(r="get",s=i.get),!s)throw new Error("not supported");let n=`$memoize$${t}`;i[r]=function(...a){return this.hasOwnProperty(n)||Object.defineProperty(this,n,{configurable:!1,enumerable:!1,writable:!1,value:s.apply(this,a)}),this[n]}}var hr;(e=>(e.Tap="-xterm-gesturetap",e.Change="-xterm-gesturechange",e.Start="-xterm-gesturestart",e.End="-xterm-gesturesend",e.Contextmenu="-xterm-gesturecontextmenu"))(hr||(hr={}));var Lo=class ci extends qe{constructor(){super(),this.dispatched=!1,this.targets=new S8,this.ignoreTargets=new S8,this.activeTouches={},this.handle=null,this._lastSetTapCountTime=0,this._register(si.runAndSubscribe($F,({window:t,disposables:i})=>{i.add(ze(t.document,"touchstart",r=>this.onTouchStart(r),{passive:!1})),i.add(ze(t.document,"touchend",r=>this.onTouchEnd(t,r))),i.add(ze(t.document,"touchmove",r=>this.onTouchMove(r),{passive:!1}))},{window:Wr,disposables:this._store}))}static addTarget(t){if(!ci.isTouchDevice())return qe.None;ci.INSTANCE||(ci.INSTANCE=new ci);let i=ci.INSTANCE.targets.push(t);return St(i)}static ignoreTarget(t){if(!ci.isTouchDevice())return qe.None;ci.INSTANCE||(ci.INSTANCE=new ci);let i=ci.INSTANCE.ignoreTargets.push(t);return St(i)}static isTouchDevice(){return"ontouchstart"in Wr||navigator.maxTouchPoints>0}dispose(){this.handle&&(this.handle.dispose(),this.handle=null),super.dispose()}onTouchStart(t){let i=Date.now();this.handle&&(this.handle.dispose(),this.handle=null);for(let r=0,s=t.targetTouches.length;r<s;r++){let n=t.targetTouches.item(r);this.activeTouches[n.identifier]={id:n.identifier,initialTarget:n.target,initialTimeStamp:i,initialPageX:n.pageX,initialPageY:n.pageY,rollingTimestamps:[i],rollingPageX:[n.pageX],rollingPageY:[n.pageY]};let a=this.newGestureEvent(hr.Start,n.target);a.pageX=n.pageX,a.pageY=n.pageY,this.dispatchEvent(a)}this.dispatched&&(t.preventDefault(),t.stopPropagation(),this.dispatched=!1)}onTouchEnd(t,i){let r=Date.now(),s=Object.keys(this.activeTouches).length;for(let n=0,a=i.changedTouches.length;n<a;n++){let o=i.changedTouches.item(n);if(!this.activeTouches.hasOwnProperty(String(o.identifier))){console.warn("move of an UNKNOWN touch",o);continue}let l=this.activeTouches[o.identifier],c=Date.now()-l.initialTimeStamp;if(c<ci.HOLD_DELAY&&Math.abs(l.initialPageX-xi(l.rollingPageX))<30&&Math.abs(l.initialPageY-xi(l.rollingPageY))<30){let u=this.newGestureEvent(hr.Tap,l.initialTarget);u.pageX=xi(l.rollingPageX),u.pageY=xi(l.rollingPageY),this.dispatchEvent(u)}else if(c>=ci.HOLD_DELAY&&Math.abs(l.initialPageX-xi(l.rollingPageX))<30&&Math.abs(l.initialPageY-xi(l.rollingPageY))<30){let u=this.newGestureEvent(hr.Contextmenu,l.initialTarget);u.pageX=xi(l.rollingPageX),u.pageY=xi(l.rollingPageY),this.dispatchEvent(u)}else if(s===1){let u=xi(l.rollingPageX),h=xi(l.rollingPageY),d=xi(l.rollingTimestamps)-l.rollingTimestamps[0],f=u-l.rollingPageX[0],m=h-l.rollingPageY[0],_=[...this.targets].filter(y=>l.initialTarget instanceof Node&&y.contains(l.initialTarget));this.inertia(t,_,r,Math.abs(f)/d,f>0?1:-1,u,Math.abs(m)/d,m>0?1:-1,h)}this.dispatchEvent(this.newGestureEvent(hr.End,l.initialTarget)),delete this.activeTouches[o.identifier]}this.dispatched&&(i.preventDefault(),i.stopPropagation(),this.dispatched=!1)}newGestureEvent(t,i){let r=document.createEvent("CustomEvent");return r.initEvent(t,!1,!0),r.initialTarget=i,r.tapCount=0,r}dispatchEvent(t){if(t.type===hr.Tap){let i=new Date().getTime(),r=0;i-this._lastSetTapCountTime>ci.CLEAR_TAP_COUNT_TIME?r=1:r=2,this._lastSetTapCountTime=i,t.tapCount=r}else(t.type===hr.Change||t.type===hr.Contextmenu)&&(this._lastSetTapCountTime=0);if(t.initialTarget instanceof Node){for(let r of this.ignoreTargets)if(r.contains(t.initialTarget))return;let i=[];for(let r of this.targets)if(r.contains(t.initialTarget)){let s=0,n=t.initialTarget;for(;n&&n!==r;)s++,n=n.parentElement;i.push([s,r])}i.sort((r,s)=>r[0]-s[0]);for(let[r,s]of i)s.dispatchEvent(t),this.dispatched=!0}}inertia(t,i,r,s,n,a,o,l,c){this.handle=Zd(t,()=>{let u=Date.now(),h=u-r,d=0,f=0,m=!0;s+=ci.SCROLL_FRICTION*h,o+=ci.SCROLL_FRICTION*h,s>0&&(m=!1,d=n*s*h),o>0&&(m=!1,f=l*o*h);let _=this.newGestureEvent(hr.Change);_.translationX=d,_.translationY=f,i.forEach(y=>y.dispatchEvent(_)),m||this.inertia(t,i,u,s,n,a+d,o,l,c+f)})}onTouchMove(t){let i=Date.now();for(let r=0,s=t.changedTouches.length;r<s;r++){let n=t.changedTouches.item(r);if(!this.activeTouches.hasOwnProperty(String(n.identifier))){console.warn("end of an UNKNOWN touch",n);continue}let a=this.activeTouches[n.identifier],o=this.newGestureEvent(hr.Change,a.initialTarget);o.translationX=n.pageX-xi(a.rollingPageX),o.translationY=n.pageY-xi(a.rollingPageY),o.pageX=n.pageX,o.pageY=n.pageY,this.dispatchEvent(o),a.rollingPageX.length>3&&(a.rollingPageX.shift(),a.rollingPageY.shift(),a.rollingTimestamps.shift()),a.rollingPageX.push(n.pageX),a.rollingPageY.push(n.pageY),a.rollingTimestamps.push(i)}this.dispatched&&(t.preventDefault(),t.stopPropagation(),this.dispatched=!1)}};Lo.SCROLL_FRICTION=-.005,Lo.HOLD_DELAY=700,Lo.CLEAR_TAP_COUNT_TIME=400,Tt([PF],Lo,"isTouchDevice",1);var OF=Lo,Fd=class extends qe{onclick(e,t){this._register(ze(e,Kt.CLICK,i=>t(new Xl(gr(e),i))))}onmousedown(e,t){this._register(ze(e,Kt.MOUSE_DOWN,i=>t(new Xl(gr(e),i))))}onmouseover(e,t){this._register(ze(e,Kt.MOUSE_OVER,i=>t(new Xl(gr(e),i))))}onmouseleave(e,t){this._register(ze(e,Kt.MOUSE_LEAVE,i=>t(new Xl(gr(e),i))))}onkeydown(e,t){this._register(ze(e,Kt.KEY_DOWN,i=>t(new L8(i))))}onkeyup(e,t){this._register(ze(e,Kt.KEY_UP,i=>t(new L8(i))))}oninput(e,t){this._register(ze(e,Kt.INPUT,t))}onblur(e,t){this._register(ze(e,Kt.BLUR,t))}onfocus(e,t){this._register(ze(e,Kt.FOCUS,t))}onchange(e,t){this._register(ze(e,Kt.CHANGE,t))}ignoreGesture(e){return OF.ignoreTarget(e)}},H8=11,IF=class extends Fd{constructor(e){super(),this._onActivate=e.onActivate,this.bgDomNode=document.createElement("div"),this.bgDomNode.className="arrow-background",this.bgDomNode.style.position="absolute",this.bgDomNode.style.width=e.bgWidth+"px",this.bgDomNode.style.height=e.bgHeight+"px",typeof e.top<"u"&&(this.bgDomNode.style.top="0px"),typeof e.left<"u"&&(this.bgDomNode.style.left="0px"),typeof e.bottom<"u"&&(this.bgDomNode.style.bottom="0px"),typeof e.right<"u"&&(this.bgDomNode.style.right="0px"),this.domNode=document.createElement("div"),this.domNode.className=e.className,this.domNode.style.position="absolute",this.domNode.style.width=H8+"px",this.domNode.style.height=H8+"px",typeof e.top<"u"&&(this.domNode.style.top=e.top+"px"),typeof e.left<"u"&&(this.domNode.style.left=e.left+"px"),typeof e.bottom<"u"&&(this.domNode.style.bottom=e.bottom+"px"),typeof e.right<"u"&&(this.domNode.style.right=e.right+"px"),this._pointerMoveMonitor=this._register(new Sv),this._register(T8(this.bgDomNode,Kt.POINTER_DOWN,t=>this._arrowPointerDown(t))),this._register(T8(this.domNode,Kt.POINTER_DOWN,t=>this._arrowPointerDown(t))),this._pointerdownRepeatTimer=this._register(new TF),this._pointerdownScheduleRepeatTimer=this._register(new Bd)}_arrowPointerDown(e){if(!e.target||!(e.target instanceof Element))return;let t=()=>{this._pointerdownRepeatTimer.cancelAndSet(()=>this._onActivate(),1e3/24,gr(e))};this._onActivate(),this._pointerdownRepeatTimer.cancel(),this._pointerdownScheduleRepeatTimer.cancelAndSet(t,200),this._pointerMoveMonitor.startMonitoring(e.target,e.pointerId,e.buttons,i=>{},()=>{this._pointerdownRepeatTimer.cancel(),this._pointerdownScheduleRepeatTimer.cancel()}),e.preventDefault()}},RF=class oh{constructor(t,i,r,s,n,a,o){this._forceIntegerValues=t,this._scrollStateBrand=void 0,this._forceIntegerValues&&(i=i|0,r=r|0,s=s|0,n=n|0,a=a|0,o=o|0),this.rawScrollLeft=s,this.rawScrollTop=o,i<0&&(i=0),s+i>r&&(s=r-i),s<0&&(s=0),n<0&&(n=0),o+n>a&&(o=a-n),o<0&&(o=0),this.width=i,this.scrollWidth=r,this.scrollLeft=s,this.height=n,this.scrollHeight=a,this.scrollTop=o}equals(t){return this.rawScrollLeft===t.rawScrollLeft&&this.rawScrollTop===t.rawScrollTop&&this.width===t.width&&this.scrollWidth===t.scrollWidth&&this.scrollLeft===t.scrollLeft&&this.height===t.height&&this.scrollHeight===t.scrollHeight&&this.scrollTop===t.scrollTop}withScrollDimensions(t,i){return new oh(this._forceIntegerValues,typeof t.width<"u"?t.width:this.width,typeof t.scrollWidth<"u"?t.scrollWidth:this.scrollWidth,i?this.rawScrollLeft:this.scrollLeft,typeof t.height<"u"?t.height:this.height,typeof t.scrollHeight<"u"?t.scrollHeight:this.scrollHeight,i?this.rawScrollTop:this.scrollTop)}withScrollPosition(t){return new oh(this._forceIntegerValues,this.width,this.scrollWidth,typeof t.scrollLeft<"u"?t.scrollLeft:this.rawScrollLeft,this.height,this.scrollHeight,typeof t.scrollTop<"u"?t.scrollTop:this.rawScrollTop)}createScrollEvent(t,i){let r=this.width!==t.width,s=this.scrollWidth!==t.scrollWidth,n=this.scrollLeft!==t.scrollLeft,a=this.height!==t.height,o=this.scrollHeight!==t.scrollHeight,l=this.scrollTop!==t.scrollTop;return{inSmoothScrolling:i,oldWidth:t.width,oldScrollWidth:t.scrollWidth,oldScrollLeft:t.scrollLeft,width:this.width,scrollWidth:this.scrollWidth,scrollLeft:this.scrollLeft,oldHeight:t.height,oldScrollHeight:t.scrollHeight,oldScrollTop:t.scrollTop,height:this.height,scrollHeight:this.scrollHeight,scrollTop:this.scrollTop,widthChanged:r,scrollWidthChanged:s,scrollLeftChanged:n,heightChanged:a,scrollHeightChanged:o,scrollTopChanged:l}}},DF=class extends qe{constructor(e){super(),this._scrollableBrand=void 0,this._onScroll=this._register(new Ae),this.onScroll=this._onScroll.event,this._smoothScrollDuration=e.smoothScrollDuration,this._scheduleAtNextAnimationFrame=e.scheduleAtNextAnimationFrame,this._state=new RF(e.forceIntegerValues,0,0,0,0,0,0),this._smoothScrolling=null}dispose(){this._smoothScrolling&&(this._smoothScrolling.dispose(),this._smoothScrolling=null),super.dispose()}setSmoothScrollDuration(e){this._smoothScrollDuration=e}validateScrollPosition(e){return this._state.withScrollPosition(e)}getScrollDimensions(){return this._state}setScrollDimensions(e,t){var r;let i=this._state.withScrollDimensions(e,t);this._setState(i,!!this._smoothScrolling),(r=this._smoothScrolling)==null||r.acceptScrollDimensions(this._state)}getFutureScrollPosition(){return this._smoothScrolling?this._smoothScrolling.to:this._state}getCurrentScrollPosition(){return this._state}setScrollPositionNow(e){let t=this._state.withScrollPosition(e);this._smoothScrolling&&(this._smoothScrolling.dispose(),this._smoothScrolling=null),this._setState(t,!1)}setScrollPositionSmooth(e,t){if(this._smoothScrollDuration===0)return this.setScrollPositionNow(e);if(this._smoothScrolling){e={scrollLeft:typeof e.scrollLeft>"u"?this._smoothScrolling.to.scrollLeft:e.scrollLeft,scrollTop:typeof e.scrollTop>"u"?this._smoothScrolling.to.scrollTop:e.scrollTop};let i=this._state.withScrollPosition(e);if(this._smoothScrolling.to.scrollLeft===i.scrollLeft&&this._smoothScrolling.to.scrollTop===i.scrollTop)return;let r;t?r=new O8(this._smoothScrolling.from,i,this._smoothScrolling.startTime,this._smoothScrolling.duration):r=this._smoothScrolling.combine(this._state,i,this._smoothScrollDuration),this._smoothScrolling.dispose(),this._smoothScrolling=r}else{let i=this._state.withScrollPosition(e);this._smoothScrolling=O8.start(this._state,i,this._smoothScrollDuration)}this._smoothScrolling.animationFrameDisposable=this._scheduleAtNextAnimationFrame(()=>{this._smoothScrolling&&(this._smoothScrolling.animationFrameDisposable=null,this._performSmoothScrolling())})}hasPendingScrollAnimation(){return!!this._smoothScrolling}_performSmoothScrolling(){if(!this._smoothScrolling)return;let e=this._smoothScrolling.tick(),t=this._state.withScrollPosition(e);if(this._setState(t,!0),!!this._smoothScrolling){if(e.isDone){this._smoothScrolling.dispose(),this._smoothScrolling=null;return}this._smoothScrolling.animationFrameDisposable=this._scheduleAtNextAnimationFrame(()=>{this._smoothScrolling&&(this._smoothScrolling.animationFrameDisposable=null,this._performSmoothScrolling())})}}_setState(e,t){let i=this._state;i.equals(e)||(this._state=e,this._onScroll.fire(this._state.createScrollEvent(i,t)))}},P8=class{constructor(e,t,i){this.scrollLeft=e,this.scrollTop=t,this.isDone=i}};function L1(e,t){let i=t-e;return function(r){return e+i*ZF(r)}}function VF(e,t,i){return function(r){return r<i?e(r/i):t((r-i)/(1-i))}}var O8=class lh{constructor(t,i,r,s){this.from=t,this.to=i,this.duration=s,this.startTime=r,this.animationFrameDisposable=null,this._initAnimations()}_initAnimations(){this.scrollLeft=this._initAnimation(this.from.scrollLeft,this.to.scrollLeft,this.to.width),this.scrollTop=this._initAnimation(this.from.scrollTop,this.to.scrollTop,this.to.height)}_initAnimation(t,i,r){if(Math.abs(t-i)>2.5*r){let s,n;return t<i?(s=t+.75*r,n=i-.75*r):(s=t-.75*r,n=i+.75*r),VF(L1(t,s),L1(n,i),.33)}return L1(t,i)}dispose(){this.animationFrameDisposable!==null&&(this.animationFrameDisposable.dispose(),this.animationFrameDisposable=null)}acceptScrollDimensions(t){this.to=t.withScrollPosition(this.to),this._initAnimations()}tick(){return this._tick(Date.now())}_tick(t){let i=(t-this.startTime)/this.duration;if(i<1){let r=this.scrollLeft(i),s=this.scrollTop(i);return new P8(r,s,!1)}return new P8(this.to.scrollLeft,this.to.scrollTop,!0)}combine(t,i,r){return lh.start(t,i,r)}static start(t,i,r){r=r+10;let s=Date.now()-10;return new lh(t,i,s,r)}};function BF(e){return Math.pow(e,3)}function ZF(e){return 1-BF(1-e)}var FF=class extends qe{constructor(e,t,i){super(),this._visibility=e,this._visibleClassName=t,this._invisibleClassName=i,this._domNode=null,this._isVisible=!1,this._isNeeded=!1,this._rawShouldBeVisible=!1,this._shouldBeVisible=!1,this._revealTimer=this._register(new Bd)}setVisibility(e){this._visibility!==e&&(this._visibility=e,this._updateShouldBeVisible())}setShouldBeVisible(e){this._rawShouldBeVisible=e,this._updateShouldBeVisible()}_applyVisibilitySetting(){return this._visibility===2?!1:this._visibility===3?!0:this._rawShouldBeVisible}_updateShouldBeVisible(){let e=this._applyVisibilitySetting();this._shouldBeVisible!==e&&(this._shouldBeVisible=e,this.ensureVisibility())}setIsNeeded(e){this._isNeeded!==e&&(this._isNeeded=e,this.ensureVisibility())}setDomNode(e){this._domNode=e,this._domNode.setClassName(this._invisibleClassName),this.setShouldBeVisible(!1)}ensureVisibility(){if(!this._isNeeded){this._hide(!1);return}this._shouldBeVisible?this._reveal():this._hide(!0)}_reveal(){this._isVisible||(this._isVisible=!0,this._revealTimer.setIfNotSet(()=>{var e;(e=this._domNode)==null||e.setClassName(this._visibleClassName)},0))}_hide(e){var t;this._revealTimer.cancel(),this._isVisible&&(this._isVisible=!1,(t=this._domNode)==null||t.setClassName(this._invisibleClassName+(e?" fade":"")))}},zF=140,Cv=class extends Fd{constructor(e){super(),this._lazyRender=e.lazyRender,this._host=e.host,this._scrollable=e.scrollable,this._scrollByPage=e.scrollByPage,this._scrollbarState=e.scrollbarState,this._visibilityController=this._register(new FF(e.visibility,"visible scrollbar "+e.extraScrollbarClassName,"invisible scrollbar "+e.extraScrollbarClassName)),this._visibilityController.setIsNeeded(this._scrollbarState.isNeeded()),this._pointerMoveMonitor=this._register(new Sv),this._shouldRender=!0,this.domNode=zo(document.createElement("div")),this.domNode.setAttribute("role","presentation"),this.domNode.setAttribute("aria-hidden","true"),this._visibilityController.setDomNode(this.domNode),this.domNode.setPosition("absolute"),this._register(ze(this.domNode.domNode,Kt.POINTER_DOWN,t=>this._domNodePointerDown(t)))}_createArrow(e){let t=this._register(new IF(e));this.domNode.domNode.appendChild(t.bgDomNode),this.domNode.domNode.appendChild(t.domNode)}_createSlider(e,t,i,r){this.slider=zo(document.createElement("div")),this.slider.setClassName("slider"),this.slider.setPosition("absolute"),this.slider.setTop(e),this.slider.setLeft(t),typeof i=="number"&&this.slider.setWidth(i),typeof r=="number"&&this.slider.setHeight(r),this.slider.setLayerHinting(!0),this.slider.setContain("strict"),this.domNode.domNode.appendChild(this.slider.domNode),this._register(ze(this.slider.domNode,Kt.POINTER_DOWN,s=>{s.button===0&&(s.preventDefault(),this._sliderPointerDown(s))})),this.onclick(this.slider.domNode,s=>{s.leftButton&&s.stopPropagation()})}_onElementSize(e){return this._scrollbarState.setVisibleSize(e)&&(this._visibilityController.setIsNeeded(this._scrollbarState.isNeeded()),this._shouldRender=!0,this._lazyRender||this.render()),this._shouldRender}_onElementScrollSize(e){return this._scrollbarState.setScrollSize(e)&&(this._visibilityController.setIsNeeded(this._scrollbarState.isNeeded()),this._shouldRender=!0,this._lazyRender||this.render()),this._shouldRender}_onElementScrollPosition(e){return this._scrollbarState.setScrollPosition(e)&&(this._visibilityController.setIsNeeded(this._scrollbarState.isNeeded()),this._shouldRender=!0,this._lazyRender||this.render()),this._shouldRender}beginReveal(){this._visibilityController.setShouldBeVisible(!0)}beginHide(){this._visibilityController.setShouldBeVisible(!1)}render(){this._shouldRender&&(this._shouldRender=!1,this._renderDomNode(this._scrollbarState.getRectangleLargeSize(),this._scrollbarState.getRectangleSmallSize()),this._updateSlider(this._scrollbarState.getSliderSize(),this._scrollbarState.getArrowSize()+this._scrollbarState.getSliderPosition()))}_domNodePointerDown(e){e.target===this.domNode.domNode&&this._onPointerDown(e)}delegatePointerDown(e){let t=this.domNode.domNode.getClientRects()[0].top,i=t+this._scrollbarState.getSliderPosition(),r=t+this._scrollbarState.getSliderPosition()+this._scrollbarState.getSliderSize(),s=this._sliderPointerPosition(e);i<=s&&s<=r?e.button===0&&(e.preventDefault(),this._sliderPointerDown(e)):this._onPointerDown(e)}_onPointerDown(e){let t,i;if(e.target===this.domNode.domNode&&typeof e.offsetX=="number"&&typeof e.offsetY=="number")t=e.offsetX,i=e.offsetY;else{let s=NF(this.domNode.domNode);t=e.pageX-s.left,i=e.pageY-s.top}let r=this._pointerDownRelativePosition(t,i);this._setDesiredScrollPositionNow(this._scrollByPage?this._scrollbarState.getDesiredScrollPositionFromOffsetPaged(r):this._scrollbarState.getDesiredScrollPositionFromOffset(r)),e.button===0&&(e.preventDefault(),this._sliderPointerDown(e))}_sliderPointerDown(e){if(!e.target||!(e.target instanceof Element))return;let t=this._sliderPointerPosition(e),i=this._sliderOrthogonalPointerPosition(e),r=this._scrollbarState.clone();this.slider.toggleClassName("active",!0),this._pointerMoveMonitor.startMonitoring(e.target,e.pointerId,e.buttons,s=>{let n=this._sliderOrthogonalPointerPosition(s),a=Math.abs(n-i);if(vv&&a>zF){this._setDesiredScrollPositionNow(r.getScrollPosition());return}let o=this._sliderPointerPosition(s)-t;this._setDesiredScrollPositionNow(r.getDesiredScrollPositionFromDelta(o))},()=>{this.slider.toggleClassName("active",!1),this._host.onDragEnd()}),this._host.onDragStart()}_setDesiredScrollPositionNow(e){let t={};this.writeScrollPosition(t,e),this._scrollable.setScrollPositionNow(t)}updateScrollbarSize(e){this._updateScrollbarSize(e),this._scrollbarState.setScrollbarSize(e),this._shouldRender=!0,this._lazyRender||this.render()}isNeeded(){return this._scrollbarState.isNeeded()}},kv=class ch{constructor(t,i,r,s,n,a){this._scrollbarSize=Math.round(i),this._oppositeScrollbarSize=Math.round(r),this._arrowSize=Math.round(t),this._visibleSize=s,this._scrollSize=n,this._scrollPosition=a,this._computedAvailableSize=0,this._computedIsNeeded=!1,this._computedSliderSize=0,this._computedSliderRatio=0,this._computedSliderPosition=0,this._refreshComputedValues()}clone(){return new ch(this._arrowSize,this._scrollbarSize,this._oppositeScrollbarSize,this._visibleSize,this._scrollSize,this._scrollPosition)}setVisibleSize(t){let i=Math.round(t);return this._visibleSize!==i?(this._visibleSize=i,this._refreshComputedValues(),!0):!1}setScrollSize(t){let i=Math.round(t);return this._scrollSize!==i?(this._scrollSize=i,this._refreshComputedValues(),!0):!1}setScrollPosition(t){let i=Math.round(t);return this._scrollPosition!==i?(this._scrollPosition=i,this._refreshComputedValues(),!0):!1}setScrollbarSize(t){this._scrollbarSize=Math.round(t)}setOppositeScrollbarSize(t){this._oppositeScrollbarSize=Math.round(t)}static _computeValues(t,i,r,s,n){let a=Math.max(0,r-t),o=Math.max(0,a-2*i),l=s>0&&s>r;if(!l)return{computedAvailableSize:Math.round(a),computedIsNeeded:l,computedSliderSize:Math.round(o),computedSliderRatio:0,computedSliderPosition:0};let c=Math.round(Math.max(20,Math.floor(r*o/s))),u=(o-c)/(s-r),h=n*u;return{computedAvailableSize:Math.round(a),computedIsNeeded:l,computedSliderSize:Math.round(c),computedSliderRatio:u,computedSliderPosition:Math.round(h)}}_refreshComputedValues(){let t=ch._computeValues(this._oppositeScrollbarSize,this._arrowSize,this._visibleSize,this._scrollSize,this._scrollPosition);this._computedAvailableSize=t.computedAvailableSize,this._computedIsNeeded=t.computedIsNeeded,this._computedSliderSize=t.computedSliderSize,this._computedSliderRatio=t.computedSliderRatio,this._computedSliderPosition=t.computedSliderPosition}getArrowSize(){return this._arrowSize}getScrollPosition(){return this._scrollPosition}getRectangleLargeSize(){return this._computedAvailableSize}getRectangleSmallSize(){return this._scrollbarSize}isNeeded(){return this._computedIsNeeded}getSliderSize(){return this._computedSliderSize}getSliderPosition(){return this._computedSliderPosition}getDesiredScrollPositionFromOffset(t){if(!this._computedIsNeeded)return 0;let i=t-this._arrowSize-this._computedSliderSize/2;return Math.round(i/this._computedSliderRatio)}getDesiredScrollPositionFromOffsetPaged(t){if(!this._computedIsNeeded)return 0;let i=t-this._arrowSize,r=this._scrollPosition;return i<this._computedSliderPosition?r-=this._visibleSize:r+=this._visibleSize,r}getDesiredScrollPositionFromDelta(t){if(!this._computedIsNeeded)return 0;let i=this._computedSliderPosition+t;return Math.round(i/this._computedSliderRatio)}},UF=class extends Cv{constructor(e,t,i){let r=e.getScrollDimensions(),s=e.getCurrentScrollPosition();if(super({lazyRender:t.lazyRender,host:i,scrollbarState:new kv(t.horizontalHasArrows?t.arrowSize:0,t.horizontal===2?0:t.horizontalScrollbarSize,t.vertical===2?0:t.verticalScrollbarSize,r.width,r.scrollWidth,s.scrollLeft),visibility:t.horizontal,extraScrollbarClassName:"horizontal",scrollable:e,scrollByPage:t.scrollByPage}),t.horizontalHasArrows)throw new Error("horizontalHasArrows is not supported in xterm.js");this._createSlider(Math.floor((t.horizontalScrollbarSize-t.horizontalSliderSize)/2),0,void 0,t.horizontalSliderSize)}_updateSlider(e,t){this.slider.setWidth(e),this.slider.setLeft(t)}_renderDomNode(e,t){this.domNode.setWidth(e),this.domNode.setHeight(t),this.domNode.setLeft(0),this.domNode.setBottom(0)}onDidScroll(e){return this._shouldRender=this._onElementScrollSize(e.scrollWidth)||this._shouldRender,this._shouldRender=this._onElementScrollPosition(e.scrollLeft)||this._shouldRender,this._shouldRender=this._onElementSize(e.width)||this._shouldRender,this._shouldRender}_pointerDownRelativePosition(e,t){return e}_sliderPointerPosition(e){return e.pageX}_sliderOrthogonalPointerPosition(e){return e.pageY}_updateScrollbarSize(e){this.slider.setHeight(e)}writeScrollPosition(e,t){e.scrollLeft=t}updateOptions(e){this.updateScrollbarSize(e.horizontal===2?0:e.horizontalScrollbarSize),this._scrollbarState.setOppositeScrollbarSize(e.vertical===2?0:e.verticalScrollbarSize),this._visibilityController.setVisibility(e.horizontal),this._scrollByPage=e.scrollByPage}},WF=class extends Cv{constructor(e,t,i){let r=e.getScrollDimensions(),s=e.getCurrentScrollPosition();if(super({lazyRender:t.lazyRender,host:i,scrollbarState:new kv(t.verticalHasArrows?t.arrowSize:0,t.vertical===2?0:t.verticalScrollbarSize,0,r.height,r.scrollHeight,s.scrollTop),visibility:t.vertical,extraScrollbarClassName:"vertical",scrollable:e,scrollByPage:t.scrollByPage}),t.verticalHasArrows)throw new Error("horizontalHasArrows is not supported in xterm.js");this._createSlider(0,Math.floor((t.verticalScrollbarSize-t.verticalSliderSize)/2),t.verticalSliderSize,void 0)}_updateSlider(e,t){this.slider.setHeight(e),this.slider.setTop(t)}_renderDomNode(e,t){this.domNode.setWidth(t),this.domNode.setHeight(e),this.domNode.setRight(0),this.domNode.setTop(0)}onDidScroll(e){return this._shouldRender=this._onElementScrollSize(e.scrollHeight)||this._shouldRender,this._shouldRender=this._onElementScrollPosition(e.scrollTop)||this._shouldRender,this._shouldRender=this._onElementSize(e.height)||this._shouldRender,this._shouldRender}_pointerDownRelativePosition(e,t){return t}_sliderPointerPosition(e){return e.pageY}_sliderOrthogonalPointerPosition(e){return e.pageX}_updateScrollbarSize(e){this.slider.setWidth(e)}writeScrollPosition(e,t){e.scrollTop=t}updateOptions(e){this.updateScrollbarSize(e.vertical===2?0:e.verticalScrollbarSize),this._scrollbarState.setOppositeScrollbarSize(0),this._visibilityController.setVisibility(e.vertical),this._scrollByPage=e.scrollByPage}},jF=500,I8=50,KF=class{constructor(e,t,i){this.timestamp=e,this.deltaX=t,this.deltaY=i,this.score=0}},uh=class{constructor(){this._capacity=5,this._memory=[],this._front=-1,this._rear=-1}isPhysicalMouseWheel(){if(this._front===-1&&this._rear===-1)return!1;let t=1,i=0,r=1,s=this._rear;do{let n=s===this._front?t:Math.pow(2,-r);if(t-=n,i+=this._memory[s].score*n,s===this._front)break;s=(this._capacity+s-1)%this._capacity,r++}while(!0);return i<=.5}acceptStandardWheelEvent(t){if(Dd){let i=gr(t.browserEvent),r=sF(i);this.accept(Date.now(),t.deltaX*r,t.deltaY*r)}else this.accept(Date.now(),t.deltaX,t.deltaY)}accept(t,i,r){let s=null,n=new KF(t,i,r);this._front===-1&&this._rear===-1?(this._memory[0]=n,this._front=0,this._rear=0):(s=this._memory[this._rear],this._rear=(this._rear+1)%this._capacity,this._rear===this._front&&(this._front=(this._front+1)%this._capacity),this._memory[this._rear]=n),n.score=this._computeScore(n,s)}_computeScore(t,i){if(Math.abs(t.deltaX)>0&&Math.abs(t.deltaY)>0)return 1;let r=.5;if((!this._isAlmostInt(t.deltaX)||!this._isAlmostInt(t.deltaY))&&(r+=.25),i){let s=Math.abs(t.deltaX),n=Math.abs(t.deltaY),a=Math.abs(i.deltaX),o=Math.abs(i.deltaY),l=Math.max(Math.min(s,a),1),c=Math.max(Math.min(n,o),1),u=Math.max(s,a),h=Math.max(n,o);u%l===0&&h%c===0&&(r-=.5)}return Math.min(Math.max(r,0),1)}_isAlmostInt(t){return Math.abs(Math.round(t)-t)<.01}};uh.INSTANCE=new uh;var qF=uh,GF=class extends Fd{constructor(e,t,i){super(),this._onScroll=this._register(new Ae),this.onScroll=this._onScroll.event,this._onWillScroll=this._register(new Ae),this.onWillScroll=this._onWillScroll.event,this._options=XF(t),this._scrollable=i,this._register(this._scrollable.onScroll(s=>{this._onWillScroll.fire(s),this._onDidScroll(s),this._onScroll.fire(s)}));let r={onMouseWheel:s=>this._onMouseWheel(s),onDragStart:()=>this._onDragStart(),onDragEnd:()=>this._onDragEnd()};this._verticalScrollbar=this._register(new WF(this._scrollable,this._options,r)),this._horizontalScrollbar=this._register(new UF(this._scrollable,this._options,r)),this._domNode=document.createElement("div"),this._domNode.className="xterm-scrollable-element "+this._options.className,this._domNode.setAttribute("role","presentation"),this._domNode.style.position="relative",this._domNode.appendChild(e),this._domNode.appendChild(this._horizontalScrollbar.domNode.domNode),this._domNode.appendChild(this._verticalScrollbar.domNode.domNode),this._options.useShadows?(this._leftShadowDomNode=zo(document.createElement("div")),this._leftShadowDomNode.setClassName("shadow"),this._domNode.appendChild(this._leftShadowDomNode.domNode),this._topShadowDomNode=zo(document.createElement("div")),this._topShadowDomNode.setClassName("shadow"),this._domNode.appendChild(this._topShadowDomNode.domNode),this._topLeftShadowDomNode=zo(document.createElement("div")),this._topLeftShadowDomNode.setClassName("shadow"),this._domNode.appendChild(this._topLeftShadowDomNode.domNode)):(this._leftShadowDomNode=null,this._topShadowDomNode=null,this._topLeftShadowDomNode=null),this._listenOnDomNode=this._options.listenOnDomNode||this._domNode,this._mouseWheelToDispose=[],this._setListeningToMouseWheel(this._options.handleMouseWheel),this.onmouseover(this._listenOnDomNode,s=>this._onMouseOver(s)),this.onmouseleave(this._listenOnDomNode,s=>this._onMouseLeave(s)),this._hideTimeout=this._register(new Bd),this._isDragging=!1,this._mouseIsOver=!1,this._shouldRender=!0,this._revealOnScroll=!0}get options(){return this._options}dispose(){this._mouseWheelToDispose=sn(this._mouseWheelToDispose),super.dispose()}getDomNode(){return this._domNode}getOverviewRulerLayoutInfo(){return{parent:this._domNode,insertBefore:this._verticalScrollbar.domNode.domNode}}delegateVerticalScrollbarPointerDown(e){this._verticalScrollbar.delegatePointerDown(e)}getScrollDimensions(){return this._scrollable.getScrollDimensions()}setScrollDimensions(e){this._scrollable.setScrollDimensions(e,!1)}updateClassName(e){this._options.className=e,kr&&(this._options.className+=" mac"),this._domNode.className="xterm-scrollable-element "+this._options.className}updateOptions(e){typeof e.handleMouseWheel<"u"&&(this._options.handleMouseWheel=e.handleMouseWheel,this._setListeningToMouseWheel(this._options.handleMouseWheel)),typeof e.mouseWheelScrollSensitivity<"u"&&(this._options.mouseWheelScrollSensitivity=e.mouseWheelScrollSensitivity),typeof e.fastScrollSensitivity<"u"&&(this._options.fastScrollSensitivity=e.fastScrollSensitivity),typeof e.scrollPredominantAxis<"u"&&(this._options.scrollPredominantAxis=e.scrollPredominantAxis),typeof e.horizontal<"u"&&(this._options.horizontal=e.horizontal),typeof e.vertical<"u"&&(this._options.vertical=e.vertical),typeof e.horizontalScrollbarSize<"u"&&(this._options.horizontalScrollbarSize=e.horizontalScrollbarSize),typeof e.verticalScrollbarSize<"u"&&(this._options.verticalScrollbarSize=e.verticalScrollbarSize),typeof e.scrollByPage<"u"&&(this._options.scrollByPage=e.scrollByPage),this._horizontalScrollbar.updateOptions(this._options),this._verticalScrollbar.updateOptions(this._options),this._options.lazyRender||this._render()}setRevealOnScroll(e){this._revealOnScroll=e}delegateScrollFromMouseWheelEvent(e){this._onMouseWheel(new $8(e))}_setListeningToMouseWheel(e){if(this._mouseWheelToDispose.length>0!==e&&(this._mouseWheelToDispose=sn(this._mouseWheelToDispose),e)){let t=i=>{this._onMouseWheel(new $8(i))};this._mouseWheelToDispose.push(ze(this._listenOnDomNode,Kt.MOUSE_WHEEL,t,{passive:!1}))}}_onMouseWheel(e){var s;if((s=e.browserEvent)!=null&&s.defaultPrevented)return;let t=qF.INSTANCE;t.acceptStandardWheelEvent(e);let i=!1;if(e.deltaY||e.deltaX){let n=e.deltaY*this._options.mouseWheelScrollSensitivity,a=e.deltaX*this._options.mouseWheelScrollSensitivity;this._options.scrollPredominantAxis&&(this._options.scrollYToX&&a+n===0?a=n=0:Math.abs(n)>=Math.abs(a)?a=0:n=0),this._options.flipAxes&&([n,a]=[a,n]);let o=!kr&&e.browserEvent&&e.browserEvent.shiftKey;(this._options.scrollYToX||o)&&!a&&(a=n,n=0),e.browserEvent&&e.browserEvent.altKey&&(a=a*this._options.fastScrollSensitivity,n=n*this._options.fastScrollSensitivity);let l=this._scrollable.getFutureScrollPosition(),c={};if(n){let u=I8*n,h=l.scrollTop-(u<0?Math.floor(u):Math.ceil(u));this._verticalScrollbar.writeScrollPosition(c,h)}if(a){let u=I8*a,h=l.scrollLeft-(u<0?Math.floor(u):Math.ceil(u));this._horizontalScrollbar.writeScrollPosition(c,h)}c=this._scrollable.validateScrollPosition(c),(l.scrollLeft!==c.scrollLeft||l.scrollTop!==c.scrollTop)&&(this._options.mouseWheelSmoothScroll&&t.isPhysicalMouseWheel()?this._scrollable.setScrollPositionSmooth(c):this._scrollable.setScrollPositionNow(c),i=!0)}let r=i;!r&&this._options.alwaysConsumeMouseWheel&&(r=!0),!r&&this._options.consumeMouseWheelIfScrollbarIsNeeded&&(this._verticalScrollbar.isNeeded()||this._horizontalScrollbar.isNeeded())&&(r=!0),r&&(e.preventDefault(),e.stopPropagation())}_onDidScroll(e){this._shouldRender=this._horizontalScrollbar.onDidScroll(e)||this._shouldRender,this._shouldRender=this._verticalScrollbar.onDidScroll(e)||this._shouldRender,this._options.useShadows&&(this._shouldRender=!0),this._revealOnScroll&&this._reveal(),this._options.lazyRender||this._render()}renderNow(){if(!this._options.lazyRender)throw new Error("Please use `lazyRender` together with `renderNow`!");this._render()}_render(){if(this._shouldRender&&(this._shouldRender=!1,this._horizontalScrollbar.render(),this._verticalScrollbar.render(),this._options.useShadows)){let e=this._scrollable.getCurrentScrollPosition(),t=e.scrollTop>0,i=e.scrollLeft>0,r=i?" left":"",s=t?" top":"",n=i||t?" top-left-corner":"";this._leftShadowDomNode.setClassName(`shadow${r}`),this._topShadowDomNode.setClassName(`shadow${s}`),this._topLeftShadowDomNode.setClassName(`shadow${n}${s}${r}`)}}_onDragStart(){this._isDragging=!0,this._reveal()}_onDragEnd(){this._isDragging=!1,this._hide()}_onMouseLeave(e){this._mouseIsOver=!1,this._hide()}_onMouseOver(e){this._mouseIsOver=!0,this._reveal()}_reveal(){this._verticalScrollbar.beginReveal(),this._horizontalScrollbar.beginReveal(),this._scheduleHide()}_hide(){!this._mouseIsOver&&!this._isDragging&&(this._verticalScrollbar.beginHide(),this._horizontalScrollbar.beginHide())}_scheduleHide(){!this._mouseIsOver&&!this._isDragging&&this._hideTimeout.cancelAndSet(()=>this._hide(),jF)}},YF=class extends GF{constructor(e,t,i){super(e,t,i)}setScrollPosition(e){e.reuseAnimation?this._scrollable.setScrollPositionSmooth(e,e.reuseAnimation):this._scrollable.setScrollPositionNow(e)}getScrollPosition(){return this._scrollable.getCurrentScrollPosition()}};function XF(e){let t={lazyRender:typeof e.lazyRender<"u"?e.lazyRender:!1,className:typeof e.className<"u"?e.className:"",useShadows:typeof e.useShadows<"u"?e.useShadows:!0,handleMouseWheel:typeof e.handleMouseWheel<"u"?e.handleMouseWheel:!0,flipAxes:typeof e.flipAxes<"u"?e.flipAxes:!1,consumeMouseWheelIfScrollbarIsNeeded:typeof e.consumeMouseWheelIfScrollbarIsNeeded<"u"?e.consumeMouseWheelIfScrollbarIsNeeded:!1,alwaysConsumeMouseWheel:typeof e.alwaysConsumeMouseWheel<"u"?e.alwaysConsumeMouseWheel:!1,scrollYToX:typeof e.scrollYToX<"u"?e.scrollYToX:!1,mouseWheelScrollSensitivity:typeof e.mouseWheelScrollSensitivity<"u"?e.mouseWheelScrollSensitivity:1,fastScrollSensitivity:typeof e.fastScrollSensitivity<"u"?e.fastScrollSensitivity:5,scrollPredominantAxis:typeof e.scrollPredominantAxis<"u"?e.scrollPredominantAxis:!0,mouseWheelSmoothScroll:typeof e.mouseWheelSmoothScroll<"u"?e.mouseWheelSmoothScroll:!0,arrowSize:typeof e.arrowSize<"u"?e.arrowSize:11,listenOnDomNode:typeof e.listenOnDomNode<"u"?e.listenOnDomNode:null,horizontal:typeof e.horizontal<"u"?e.horizontal:1,horizontalScrollbarSize:typeof e.horizontalScrollbarSize<"u"?e.horizontalScrollbarSize:10,horizontalSliderSize:typeof e.horizontalSliderSize<"u"?e.horizontalSliderSize:0,horizontalHasArrows:typeof e.horizontalHasArrows<"u"?e.horizontalHasArrows:!1,vertical:typeof e.vertical<"u"?e.vertical:1,verticalScrollbarSize:typeof e.verticalScrollbarSize<"u"?e.verticalScrollbarSize:10,verticalHasArrows:typeof e.verticalHasArrows<"u"?e.verticalHasArrows:!1,verticalSliderSize:typeof e.verticalSliderSize<"u"?e.verticalSliderSize:0,scrollByPage:typeof e.scrollByPage<"u"?e.scrollByPage:!1};return t.horizontalSliderSize=typeof e.horizontalSliderSize<"u"?e.horizontalSliderSize:t.horizontalScrollbarSize,t.verticalSliderSize=typeof e.verticalSliderSize<"u"?e.verticalSliderSize:t.verticalScrollbarSize,kr&&(t.className+=" mac"),t}var hh=class extends qe{constructor(e,t,i,r,s,n,a,o){super(),this._bufferService=i,this._optionsService=a,this._renderService=o,this._onRequestScrollLines=this._register(new Ae),this.onRequestScrollLines=this._onRequestScrollLines.event,this._isSyncing=!1,this._isHandlingScroll=!1,this._suppressOnScrollHandler=!1;let l=this._register(new DF({forceIntegerValues:!1,smoothScrollDuration:this._optionsService.rawOptions.smoothScrollDuration,scheduleAtNextAnimationFrame:c=>Zd(r.window,c)}));this._register(this._optionsService.onSpecificOptionChange("smoothScrollDuration",()=>{l.setSmoothScrollDuration(this._optionsService.rawOptions.smoothScrollDuration)})),this._scrollableElement=this._register(new YF(t,{vertical:1,horizontal:2,useShadows:!1,mouseWheelSmoothScroll:!0,...this._getChangeOptions()},l)),this._register(this._optionsService.onMultipleOptionChange(["scrollSensitivity","fastScrollSensitivity","overviewRuler"],()=>this._scrollableElement.updateOptions(this._getChangeOptions()))),this._register(s.onProtocolChange(c=>{this._scrollableElement.updateOptions({handleMouseWheel:!(c&16)})})),this._scrollableElement.setScrollDimensions({height:0,scrollHeight:0}),this._register(si.runAndSubscribe(n.onChangeColors,()=>{this._scrollableElement.getDomNode().style.backgroundColor=n.colors.background.css})),e.appendChild(this._scrollableElement.getDomNode()),this._register(St(()=>this._scrollableElement.getDomNode().remove())),this._styleElement=r.mainDocument.createElement("style"),t.appendChild(this._styleElement),this._register(St(()=>this._styleElement.remove())),this._register(si.runAndSubscribe(n.onChangeColors,()=>{this._styleElement.textContent=[".xterm .xterm-scrollable-element > .scrollbar > .slider {",` background: ${n.colors.scrollbarSliderBackground.css};`,"}",".xterm .xterm-scrollable-element > .scrollbar > .slider:hover {",` background: ${n.colors.scrollbarSliderHoverBackground.css};`,"}",".xterm .xterm-scrollable-element > .scrollbar > .slider.active {",` background: ${n.colors.scrollbarSliderActiveBackground.css};`,"}"].join(`
|
|
89
|
-
`)})),this._register(this._bufferService.onResize(()=>this.queueSync())),this._register(this._bufferService.buffers.onBufferActivate(()=>{this._latestYDisp=void 0,this.queueSync()})),this._register(this._bufferService.onScroll(()=>this._sync())),this._register(this._scrollableElement.onScroll(c=>this._handleScroll(c)))}scrollLines(e){let t=this._scrollableElement.getScrollPosition();this._scrollableElement.setScrollPosition({reuseAnimation:!0,scrollTop:t.scrollTop+e*this._renderService.dimensions.css.cell.height})}scrollToLine(e,t){t&&(this._latestYDisp=e),this._scrollableElement.setScrollPosition({reuseAnimation:!t,scrollTop:e*this._renderService.dimensions.css.cell.height})}_getChangeOptions(){var e;return{mouseWheelScrollSensitivity:this._optionsService.rawOptions.scrollSensitivity,fastScrollSensitivity:this._optionsService.rawOptions.fastScrollSensitivity,verticalScrollbarSize:((e=this._optionsService.rawOptions.overviewRuler)==null?void 0:e.width)||14}}queueSync(e){e!==void 0&&(this._latestYDisp=e),this._queuedAnimationFrame===void 0&&(this._queuedAnimationFrame=this._renderService.addRefreshCallback(()=>{this._queuedAnimationFrame=void 0,this._sync(this._latestYDisp)}))}_sync(e=this._bufferService.buffer.ydisp){!this._renderService||this._isSyncing||(this._isSyncing=!0,this._suppressOnScrollHandler=!0,this._scrollableElement.setScrollDimensions({height:this._renderService.dimensions.css.canvas.height,scrollHeight:this._renderService.dimensions.css.cell.height*this._bufferService.buffer.lines.length}),this._suppressOnScrollHandler=!1,e!==this._latestYDisp&&this._scrollableElement.setScrollPosition({scrollTop:e*this._renderService.dimensions.css.cell.height}),this._isSyncing=!1)}_handleScroll(e){if(!this._renderService||this._isHandlingScroll||this._suppressOnScrollHandler)return;this._isHandlingScroll=!0;let t=Math.round(e.scrollTop/this._renderService.dimensions.css.cell.height),i=t-this._bufferService.buffer.ydisp;i!==0&&(this._latestYDisp=t,this._onRequestScrollLines.fire(i)),this._isHandlingScroll=!1}};hh=Tt([Te(2,Ai),Te(3,Jr),Te(4,sv),Te(5,$a),Te(6,Mi),Te(7,Qr)],hh);var dh=class extends qe{constructor(e,t,i,r,s){super(),this._screenElement=e,this._bufferService=t,this._coreBrowserService=i,this._decorationService=r,this._renderService=s,this._decorationElements=new Map,this._altBufferIsActive=!1,this._dimensionsChanged=!1,this._container=document.createElement("div"),this._container.classList.add("xterm-decoration-container"),this._screenElement.appendChild(this._container),this._register(this._renderService.onRenderedViewportChange(()=>this._doRefreshDecorations())),this._register(this._renderService.onDimensionsChange(()=>{this._dimensionsChanged=!0,this._queueRefresh()})),this._register(this._coreBrowserService.onDprChange(()=>this._queueRefresh())),this._register(this._bufferService.buffers.onBufferActivate(()=>{this._altBufferIsActive=this._bufferService.buffer===this._bufferService.buffers.alt})),this._register(this._decorationService.onDecorationRegistered(()=>this._queueRefresh())),this._register(this._decorationService.onDecorationRemoved(n=>this._removeDecoration(n))),this._register(St(()=>{this._container.remove(),this._decorationElements.clear()}))}_queueRefresh(){this._animationFrame===void 0&&(this._animationFrame=this._renderService.addRefreshCallback(()=>{this._doRefreshDecorations(),this._animationFrame=void 0}))}_doRefreshDecorations(){for(let e of this._decorationService.decorations)this._renderDecoration(e);this._dimensionsChanged=!1}_renderDecoration(e){this._refreshStyle(e),this._dimensionsChanged&&this._refreshXPosition(e)}_createElement(e){var r;let t=this._coreBrowserService.mainDocument.createElement("div");t.classList.add("xterm-decoration"),t.classList.toggle("xterm-decoration-top-layer",((r=e==null?void 0:e.options)==null?void 0:r.layer)==="top"),t.style.width=`${Math.round((e.options.width||1)*this._renderService.dimensions.css.cell.width)}px`,t.style.height=`${(e.options.height||1)*this._renderService.dimensions.css.cell.height}px`,t.style.top=`${(e.marker.line-this._bufferService.buffers.active.ydisp)*this._renderService.dimensions.css.cell.height}px`,t.style.lineHeight=`${this._renderService.dimensions.css.cell.height}px`;let i=e.options.x??0;return i&&i>this._bufferService.cols&&(t.style.display="none"),this._refreshXPosition(e,t),t}_refreshStyle(e){let t=e.marker.line-this._bufferService.buffers.active.ydisp;if(t<0||t>=this._bufferService.rows)e.element&&(e.element.style.display="none",e.onRenderEmitter.fire(e.element));else{let i=this._decorationElements.get(e);i||(i=this._createElement(e),e.element=i,this._decorationElements.set(e,i),this._container.appendChild(i),e.onDispose(()=>{this._decorationElements.delete(e),i.remove()})),i.style.display=this._altBufferIsActive?"none":"block",this._altBufferIsActive||(i.style.width=`${Math.round((e.options.width||1)*this._renderService.dimensions.css.cell.width)}px`,i.style.height=`${(e.options.height||1)*this._renderService.dimensions.css.cell.height}px`,i.style.top=`${t*this._renderService.dimensions.css.cell.height}px`,i.style.lineHeight=`${this._renderService.dimensions.css.cell.height}px`),e.onRenderEmitter.fire(i)}}_refreshXPosition(e,t=e.element){if(!t)return;let i=e.options.x??0;(e.options.anchor||"left")==="right"?t.style.right=i?`${i*this._renderService.dimensions.css.cell.width}px`:"":t.style.left=i?`${i*this._renderService.dimensions.css.cell.width}px`:""}_removeDecoration(e){var t;(t=this._decorationElements.get(e))==null||t.remove(),this._decorationElements.delete(e),e.dispose()}};dh=Tt([Te(1,Ai),Te(2,Jr),Te(3,El),Te(4,Qr)],dh);var JF=class{constructor(){this._zones=[],this._zonePool=[],this._zonePoolIndex=0,this._linePadding={full:0,left:0,center:0,right:0}}get zones(){return this._zonePool.length=Math.min(this._zonePool.length,this._zones.length),this._zones}clear(){this._zones.length=0,this._zonePoolIndex=0}addDecoration(e){if(e.options.overviewRulerOptions){for(let t of this._zones)if(t.color===e.options.overviewRulerOptions.color&&t.position===e.options.overviewRulerOptions.position){if(this._lineIntersectsZone(t,e.marker.line))return;if(this._lineAdjacentToZone(t,e.marker.line,e.options.overviewRulerOptions.position)){this._addLineToZone(t,e.marker.line);return}}if(this._zonePoolIndex<this._zonePool.length){this._zonePool[this._zonePoolIndex].color=e.options.overviewRulerOptions.color,this._zonePool[this._zonePoolIndex].position=e.options.overviewRulerOptions.position,this._zonePool[this._zonePoolIndex].startBufferLine=e.marker.line,this._zonePool[this._zonePoolIndex].endBufferLine=e.marker.line,this._zones.push(this._zonePool[this._zonePoolIndex++]);return}this._zones.push({color:e.options.overviewRulerOptions.color,position:e.options.overviewRulerOptions.position,startBufferLine:e.marker.line,endBufferLine:e.marker.line}),this._zonePool.push(this._zones[this._zones.length-1]),this._zonePoolIndex++}}setPadding(e){this._linePadding=e}_lineIntersectsZone(e,t){return t>=e.startBufferLine&&t<=e.endBufferLine}_lineAdjacentToZone(e,t,i){return t>=e.startBufferLine-this._linePadding[i||"full"]&&t<=e.endBufferLine+this._linePadding[i||"full"]}_addLineToZone(e,t){e.startBufferLine=Math.min(e.startBufferLine,t),e.endBufferLine=Math.max(e.endBufferLine,t)}},cr={full:0,left:0,center:0,right:0},ss={full:0,left:0,center:0,right:0},vo={full:0,left:0,center:0,right:0},q0=class extends qe{constructor(e,t,i,r,s,n,a,o){var c;super(),this._viewportElement=e,this._screenElement=t,this._bufferService=i,this._decorationService=r,this._renderService=s,this._optionsService=n,this._themeService=a,this._coreBrowserService=o,this._colorZoneStore=new JF,this._shouldUpdateDimensions=!0,this._shouldUpdateAnchor=!0,this._lastKnownBufferLength=0,this._canvas=this._coreBrowserService.mainDocument.createElement("canvas"),this._canvas.classList.add("xterm-decoration-overview-ruler"),this._refreshCanvasDimensions(),(c=this._viewportElement.parentElement)==null||c.insertBefore(this._canvas,this._viewportElement),this._register(St(()=>{var u;return(u=this._canvas)==null?void 0:u.remove()}));let l=this._canvas.getContext("2d");if(l)this._ctx=l;else throw new Error("Ctx cannot be null");this._register(this._decorationService.onDecorationRegistered(()=>this._queueRefresh(void 0,!0))),this._register(this._decorationService.onDecorationRemoved(()=>this._queueRefresh(void 0,!0))),this._register(this._renderService.onRenderedViewportChange(()=>this._queueRefresh())),this._register(this._bufferService.buffers.onBufferActivate(()=>{this._canvas.style.display=this._bufferService.buffer===this._bufferService.buffers.alt?"none":"block"})),this._register(this._bufferService.onScroll(()=>{this._lastKnownBufferLength!==this._bufferService.buffers.normal.lines.length&&(this._refreshDrawHeightConstants(),this._refreshColorZonePadding())})),this._register(this._renderService.onRender(()=>{(!this._containerHeight||this._containerHeight!==this._screenElement.clientHeight)&&(this._queueRefresh(!0),this._containerHeight=this._screenElement.clientHeight)})),this._register(this._coreBrowserService.onDprChange(()=>this._queueRefresh(!0))),this._register(this._optionsService.onSpecificOptionChange("overviewRuler",()=>this._queueRefresh(!0))),this._register(this._themeService.onChangeColors(()=>this._queueRefresh())),this._queueRefresh(!0)}get _width(){var e;return((e=this._optionsService.options.overviewRuler)==null?void 0:e.width)||0}_refreshDrawConstants(){let e=Math.floor((this._canvas.width-1)/3),t=Math.ceil((this._canvas.width-1)/3);ss.full=this._canvas.width,ss.left=e,ss.center=t,ss.right=e,this._refreshDrawHeightConstants(),vo.full=1,vo.left=1,vo.center=1+ss.left,vo.right=1+ss.left+ss.center}_refreshDrawHeightConstants(){cr.full=Math.round(2*this._coreBrowserService.dpr);let e=this._canvas.height/this._bufferService.buffer.lines.length,t=Math.round(Math.max(Math.min(e,12),6)*this._coreBrowserService.dpr);cr.left=t,cr.center=t,cr.right=t}_refreshColorZonePadding(){this._colorZoneStore.setPadding({full:Math.floor(this._bufferService.buffers.active.lines.length/(this._canvas.height-1)*cr.full),left:Math.floor(this._bufferService.buffers.active.lines.length/(this._canvas.height-1)*cr.left),center:Math.floor(this._bufferService.buffers.active.lines.length/(this._canvas.height-1)*cr.center),right:Math.floor(this._bufferService.buffers.active.lines.length/(this._canvas.height-1)*cr.right)}),this._lastKnownBufferLength=this._bufferService.buffers.normal.lines.length}_refreshCanvasDimensions(){this._canvas.style.width=`${this._width}px`,this._canvas.width=Math.round(this._width*this._coreBrowserService.dpr),this._canvas.style.height=`${this._screenElement.clientHeight}px`,this._canvas.height=Math.round(this._screenElement.clientHeight*this._coreBrowserService.dpr),this._refreshDrawConstants(),this._refreshColorZonePadding()}_refreshDecorations(){this._shouldUpdateDimensions&&this._refreshCanvasDimensions(),this._ctx.clearRect(0,0,this._canvas.width,this._canvas.height),this._colorZoneStore.clear();for(let t of this._decorationService.decorations)this._colorZoneStore.addDecoration(t);this._ctx.lineWidth=1,this._renderRulerOutline();let e=this._colorZoneStore.zones;for(let t of e)t.position!=="full"&&this._renderColorZone(t);for(let t of e)t.position==="full"&&this._renderColorZone(t);this._shouldUpdateDimensions=!1,this._shouldUpdateAnchor=!1}_renderRulerOutline(){this._ctx.fillStyle=this._themeService.colors.overviewRulerBorder.css,this._ctx.fillRect(0,0,1,this._canvas.height),this._optionsService.rawOptions.overviewRuler.showTopBorder&&this._ctx.fillRect(1,0,this._canvas.width-1,1),this._optionsService.rawOptions.overviewRuler.showBottomBorder&&this._ctx.fillRect(1,this._canvas.height-1,this._canvas.width-1,this._canvas.height)}_renderColorZone(e){this._ctx.fillStyle=e.color,this._ctx.fillRect(vo[e.position||"full"],Math.round((this._canvas.height-1)*(e.startBufferLine/this._bufferService.buffers.active.lines.length)-cr[e.position||"full"]/2),ss[e.position||"full"],Math.round((this._canvas.height-1)*((e.endBufferLine-e.startBufferLine)/this._bufferService.buffers.active.lines.length)+cr[e.position||"full"]))}_queueRefresh(e,t){this._shouldUpdateDimensions=e||this._shouldUpdateDimensions,this._shouldUpdateAnchor=t||this._shouldUpdateAnchor,this._animationFrame===void 0&&(this._animationFrame=this._coreBrowserService.window.requestAnimationFrame(()=>{this._refreshDecorations(),this._animationFrame=void 0}))}};q0=Tt([Te(2,Ai),Te(3,El),Te(4,Qr),Te(5,Mi),Te(6,$a),Te(7,Jr)],q0);var ve;(e=>(e.NUL="\0",e.SOH="",e.STX="",e.ETX="",e.EOT="",e.ENQ="",e.ACK="",e.BEL="\x07",e.BS="\b",e.HT=" ",e.LF=`
|
|
90
|
-
`,e.VT="\v",e.FF="\f",e.CR="\r",e.SO="",e.SI="",e.DLE="",e.DC1="",e.DC2="",e.DC3="",e.DC4="",e.NAK="",e.SYN="",e.ETB="",e.CAN="",e.EM="",e.SUB="",e.ESC="\x1B",e.FS="",e.GS="",e.RS="",e.US="",e.SP=" ",e.DEL=""))(ve||(ve={}));var p0;(e=>(e.PAD="",e.HOP="",e.BPH="",e.NBH="",e.IND="",e.NEL="
",e.SSA="",e.ESA="",e.HTS="",e.HTJ="",e.VTS="",e.PLD="",e.PLU="",e.RI="",e.SS2="",e.SS3="",e.DCS="",e.PU1="",e.PU2="",e.STS="",e.CCH="",e.MW="",e.SPA="",e.EPA="",e.SOS="",e.SGCI="",e.SCI="",e.CSI="",e.ST="",e.OSC="",e.PM="",e.APC=""))(p0||(p0={}));var Av;(e=>e.ST=`${ve.ESC}\\`)(Av||(Av={}));var fh=class{constructor(e,t,i,r,s,n){this._textarea=e,this._compositionView=t,this._bufferService=i,this._optionsService=r,this._coreService=s,this._renderService=n,this._isComposing=!1,this._isSendingComposition=!1,this._compositionPosition={start:0,end:0},this._dataAlreadySent=""}get isComposing(){return this._isComposing}compositionstart(){this._isComposing=!0,this._compositionPosition.start=this._textarea.value.length,this._compositionView.textContent="",this._dataAlreadySent="",this._compositionView.classList.add("active")}compositionupdate(e){this._compositionView.textContent=e.data,this.updateCompositionElements(),setTimeout(()=>{this._compositionPosition.end=this._textarea.value.length},0)}compositionend(){this._finalizeComposition(!0)}keydown(e){if(this._isComposing||this._isSendingComposition){if(e.keyCode===20||e.keyCode===229||e.keyCode===16||e.keyCode===17||e.keyCode===18)return!1;this._finalizeComposition(!1)}return e.keyCode===229?(this._handleAnyTextareaChanges(),!1):!0}_finalizeComposition(e){if(this._compositionView.classList.remove("active"),this._isComposing=!1,e){let t={start:this._compositionPosition.start,end:this._compositionPosition.end};this._isSendingComposition=!0,setTimeout(()=>{if(this._isSendingComposition){this._isSendingComposition=!1;let i;t.start+=this._dataAlreadySent.length,this._isComposing?i=this._textarea.value.substring(t.start,this._compositionPosition.start):i=this._textarea.value.substring(t.start),i.length>0&&this._coreService.triggerDataEvent(i,!0)}},0)}else{this._isSendingComposition=!1;let t=this._textarea.value.substring(this._compositionPosition.start,this._compositionPosition.end);this._coreService.triggerDataEvent(t,!0)}}_handleAnyTextareaChanges(){let e=this._textarea.value;setTimeout(()=>{if(!this._isComposing){let t=this._textarea.value,i=t.replace(e,"");this._dataAlreadySent=i,t.length>e.length?this._coreService.triggerDataEvent(i,!0):t.length<e.length?this._coreService.triggerDataEvent(`${ve.DEL}`,!0):t.length===e.length&&t!==e&&this._coreService.triggerDataEvent(t,!0)}},0)}updateCompositionElements(e){if(this._isComposing){if(this._bufferService.buffer.isCursorInViewport){let t=Math.min(this._bufferService.buffer.x,this._bufferService.cols-1),i=this._renderService.dimensions.css.cell.height,r=this._bufferService.buffer.y*this._renderService.dimensions.css.cell.height,s=t*this._renderService.dimensions.css.cell.width;this._compositionView.style.left=s+"px",this._compositionView.style.top=r+"px",this._compositionView.style.height=i+"px",this._compositionView.style.lineHeight=i+"px",this._compositionView.style.fontFamily=this._optionsService.rawOptions.fontFamily,this._compositionView.style.fontSize=this._optionsService.rawOptions.fontSize+"px";let n=this._compositionView.getBoundingClientRect();this._textarea.style.left=s+"px",this._textarea.style.top=r+"px",this._textarea.style.width=Math.max(n.width,1)+"px",this._textarea.style.height=Math.max(n.height,1)+"px",this._textarea.style.lineHeight=n.height+"px"}e||setTimeout(()=>this.updateCompositionElements(!0),0)}}};fh=Tt([Te(2,Ai),Te(3,Mi),Te(4,cn),Te(5,Qr)],fh);var qt=0,Gt=0,Yt=0,Et=0,R8={css:"#00000000",rgba:0},Rt;(e=>{function t(s,n,a,o){return o!==void 0?`#${Vs(s)}${Vs(n)}${Vs(a)}${Vs(o)}`:`#${Vs(s)}${Vs(n)}${Vs(a)}`}e.toCss=t;function i(s,n,a,o=255){return(s<<24|n<<16|a<<8|o)>>>0}e.toRgba=i;function r(s,n,a,o){return{css:e.toCss(s,n,a,o),rgba:e.toRgba(s,n,a,o)}}e.toColor=r})(Rt||(Rt={}));var vt;(e=>{function t(l,c){if(Et=(c.rgba&255)/255,Et===1)return{css:c.css,rgba:c.rgba};let u=c.rgba>>24&255,h=c.rgba>>16&255,d=c.rgba>>8&255,f=l.rgba>>24&255,m=l.rgba>>16&255,_=l.rgba>>8&255;qt=f+Math.round((u-f)*Et),Gt=m+Math.round((h-m)*Et),Yt=_+Math.round((d-_)*Et);let y=Rt.toCss(qt,Gt,Yt),p=Rt.toRgba(qt,Gt,Yt);return{css:y,rgba:p}}e.blend=t;function i(l){return(l.rgba&255)===255}e.isOpaque=i;function r(l,c,u){let h=_0.ensureContrastRatio(l.rgba,c.rgba,u);if(h)return Rt.toColor(h>>24&255,h>>16&255,h>>8&255)}e.ensureContrastRatio=r;function s(l){let c=(l.rgba|255)>>>0;return[qt,Gt,Yt]=_0.toChannels(c),{css:Rt.toCss(qt,Gt,Yt),rgba:c}}e.opaque=s;function n(l,c){return Et=Math.round(c*255),[qt,Gt,Yt]=_0.toChannels(l.rgba),{css:Rt.toCss(qt,Gt,Yt,Et),rgba:Rt.toRgba(qt,Gt,Yt,Et)}}e.opacity=n;function a(l,c){return Et=l.rgba&255,n(l,Et*c/255)}e.multiplyOpacity=a;function o(l){return[l.rgba>>24&255,l.rgba>>16&255,l.rgba>>8&255]}e.toColorRGB=o})(vt||(vt={}));var kt;(e=>{let t,i;try{let s=document.createElement("canvas");s.width=1,s.height=1;let n=s.getContext("2d",{willReadFrequently:!0});n&&(t=n,t.globalCompositeOperation="copy",i=t.createLinearGradient(0,0,1,1))}catch{}function r(s){if(s.match(/#[\da-f]{3,8}/i))switch(s.length){case 4:return qt=parseInt(s.slice(1,2).repeat(2),16),Gt=parseInt(s.slice(2,3).repeat(2),16),Yt=parseInt(s.slice(3,4).repeat(2),16),Rt.toColor(qt,Gt,Yt);case 5:return qt=parseInt(s.slice(1,2).repeat(2),16),Gt=parseInt(s.slice(2,3).repeat(2),16),Yt=parseInt(s.slice(3,4).repeat(2),16),Et=parseInt(s.slice(4,5).repeat(2),16),Rt.toColor(qt,Gt,Yt,Et);case 7:return{css:s,rgba:(parseInt(s.slice(1),16)<<8|255)>>>0};case 9:return{css:s,rgba:parseInt(s.slice(1),16)>>>0}}let n=s.match(/rgba?\(\s*(\d{1,3})\s*,\s*(\d{1,3})\s*,\s*(\d{1,3})\s*(,\s*(0|1|\d?\.(\d+))\s*)?\)/);if(n)return qt=parseInt(n[1]),Gt=parseInt(n[2]),Yt=parseInt(n[3]),Et=Math.round((n[5]===void 0?1:parseFloat(n[5]))*255),Rt.toColor(qt,Gt,Yt,Et);if(!t||!i)throw new Error("css.toColor: Unsupported css format");if(t.fillStyle=i,t.fillStyle=s,typeof t.fillStyle!="string")throw new Error("css.toColor: Unsupported css format");if(t.fillRect(0,0,1,1),[qt,Gt,Yt,Et]=t.getImageData(0,0,1,1).data,Et!==255)throw new Error("css.toColor: Unsupported css format");return{rgba:Rt.toRgba(qt,Gt,Yt,Et),css:s}}e.toColor=r})(kt||(kt={}));var gi;(e=>{function t(r){return i(r>>16&255,r>>8&255,r&255)}e.relativeLuminance=t;function i(r,s,n){let a=r/255,o=s/255,l=n/255,c=a<=.03928?a/12.92:Math.pow((a+.055)/1.055,2.4),u=o<=.03928?o/12.92:Math.pow((o+.055)/1.055,2.4),h=l<=.03928?l/12.92:Math.pow((l+.055)/1.055,2.4);return c*.2126+u*.7152+h*.0722}e.relativeLuminance2=i})(gi||(gi={}));var _0;(e=>{function t(a,o){if(Et=(o&255)/255,Et===1)return o;let l=o>>24&255,c=o>>16&255,u=o>>8&255,h=a>>24&255,d=a>>16&255,f=a>>8&255;return qt=h+Math.round((l-h)*Et),Gt=d+Math.round((c-d)*Et),Yt=f+Math.round((u-f)*Et),Rt.toRgba(qt,Gt,Yt)}e.blend=t;function i(a,o,l){let c=gi.relativeLuminance(a>>8),u=gi.relativeLuminance(o>>8);if(Pr(c,u)<l){if(u<c){let f=r(a,o,l),m=Pr(c,gi.relativeLuminance(f>>8));if(m<l){let _=s(a,o,l),y=Pr(c,gi.relativeLuminance(_>>8));return m>y?f:_}return f}let h=s(a,o,l),d=Pr(c,gi.relativeLuminance(h>>8));if(d<l){let f=r(a,o,l),m=Pr(c,gi.relativeLuminance(f>>8));return d>m?h:f}return h}}e.ensureContrastRatio=i;function r(a,o,l){let c=a>>24&255,u=a>>16&255,h=a>>8&255,d=o>>24&255,f=o>>16&255,m=o>>8&255,_=Pr(gi.relativeLuminance2(d,f,m),gi.relativeLuminance2(c,u,h));for(;_<l&&(d>0||f>0||m>0);)d-=Math.max(0,Math.ceil(d*.1)),f-=Math.max(0,Math.ceil(f*.1)),m-=Math.max(0,Math.ceil(m*.1)),_=Pr(gi.relativeLuminance2(d,f,m),gi.relativeLuminance2(c,u,h));return(d<<24|f<<16|m<<8|255)>>>0}e.reduceLuminance=r;function s(a,o,l){let c=a>>24&255,u=a>>16&255,h=a>>8&255,d=o>>24&255,f=o>>16&255,m=o>>8&255,_=Pr(gi.relativeLuminance2(d,f,m),gi.relativeLuminance2(c,u,h));for(;_<l&&(d<255||f<255||m<255);)d=Math.min(255,d+Math.ceil((255-d)*.1)),f=Math.min(255,f+Math.ceil((255-f)*.1)),m=Math.min(255,m+Math.ceil((255-m)*.1)),_=Pr(gi.relativeLuminance2(d,f,m),gi.relativeLuminance2(c,u,h));return(d<<24|f<<16|m<<8|255)>>>0}e.increaseLuminance=s;function n(a){return[a>>24&255,a>>16&255,a>>8&255,a&255]}e.toChannels=n})(_0||(_0={}));function Vs(e){let t=e.toString(16);return t.length<2?"0"+t:t}function Pr(e,t){return e<t?(t+.05)/(e+.05):(e+.05)/(t+.05)}var QF=class extends Ll{constructor(e,t,i){super(),this.content=0,this.combinedData="",this.fg=e.fg,this.bg=e.bg,this.combinedData=t,this._width=i}isCombined(){return 2097152}getWidth(){return this._width}getChars(){return this.combinedData}getCode(){return 2097151}setFromCharData(e){throw new Error("not implemented")}getAsCharData(){return[this.fg,this.getChars(),this.getWidth(),this.getCode()]}},G0=class{constructor(e){this._bufferService=e,this._characterJoiners=[],this._nextCharacterJoinerId=0,this._workCell=new Ki}register(e){let t={id:this._nextCharacterJoinerId++,handler:e};return this._characterJoiners.push(t),t.id}deregister(e){for(let t=0;t<this._characterJoiners.length;t++)if(this._characterJoiners[t].id===e)return this._characterJoiners.splice(t,1),!0;return!1}getJoinedCharacters(e){if(this._characterJoiners.length===0)return[];let t=this._bufferService.buffer.lines.get(e);if(!t||t.length===0)return[];let i=[],r=t.translateToString(!0),s=0,n=0,a=0,o=t.getFg(0),l=t.getBg(0);for(let c=0;c<t.getTrimmedLength();c++)if(t.loadCell(c,this._workCell),this._workCell.getWidth()!==0){if(this._workCell.fg!==o||this._workCell.bg!==l){if(c-s>1){let u=this._getJoinedRanges(r,a,n,t,s);for(let h=0;h<u.length;h++)i.push(u[h])}s=c,a=n,o=this._workCell.fg,l=this._workCell.bg}n+=this._workCell.getChars().length||fs.length}if(this._bufferService.cols-s>1){let c=this._getJoinedRanges(r,a,n,t,s);for(let u=0;u<c.length;u++)i.push(c[u])}return i}_getJoinedRanges(e,t,i,r,s){let n=e.substring(t,i),a=[];try{a=this._characterJoiners[0].handler(n)}catch(o){console.error(o)}for(let o=1;o<this._characterJoiners.length;o++)try{let l=this._characterJoiners[o].handler(n);for(let c=0;c<l.length;c++)G0._mergeRanges(a,l[c])}catch(l){console.error(l)}return this._stringRangesToCellRanges(a,r,s),a}_stringRangesToCellRanges(e,t,i){let r=0,s=!1,n=0,a=e[r];if(a){for(let o=i;o<this._bufferService.cols;o++){let l=t.getWidth(o),c=t.getString(o).length||fs.length;if(l!==0){if(!s&&a[0]<=n&&(a[0]=o,s=!0),a[1]<=n){if(a[1]=o,a=e[++r],!a)break;a[0]<=n?(a[0]=o,s=!0):s=!1}n+=c}}a&&(a[1]=this._bufferService.cols)}}static _mergeRanges(e,t){let i=!1;for(let r=0;r<e.length;r++){let s=e[r];if(i){if(t[1]<=s[0])return e[r-1][1]=t[1],e;if(t[1]<=s[1])return e[r-1][1]=Math.max(t[1],s[1]),e.splice(r,1),e;e.splice(r,1),r--}else{if(t[1]<=s[0])return e.splice(r,0,t),e;if(t[1]<=s[1])return s[0]=Math.min(t[0],s[0]),e;t[0]<s[1]&&(s[0]=Math.min(t[0],s[0]),i=!0);continue}}return i?e[e.length-1][1]=t[1]:e.push(t),e}};G0=Tt([Te(0,Ai)],G0);function ez(e){return 57508<=e&&e<=57558}function tz(e){return 9472<=e&&e<=9631}function iz(e){return ez(e)||tz(e)}function rz(){return{css:{canvas:Jl(),cell:Jl()},device:{canvas:Jl(),cell:Jl(),char:{width:0,height:0,left:0,top:0}}}}function Jl(){return{width:0,height:0}}var ph=class{constructor(e,t,i,r,s,n,a){this._document=e,this._characterJoinerService=t,this._optionsService=i,this._coreBrowserService=r,this._coreService=s,this._decorationService=n,this._themeService=a,this._workCell=new Ki,this._columnSelectMode=!1,this.defaultSpacing=0}handleSelectionChanged(e,t,i){this._selectionStart=e,this._selectionEnd=t,this._columnSelectMode=i}createRow(e,t,i,r,s,n,a,o,l,c,u){let h=[],d=this._characterJoinerService.getJoinedCharacters(t),f=this._themeService.colors,m=e.getNoBgTrimmedLength();i&&m<n+1&&(m=n+1);let _,y=0,p="",C=0,w=0,v=0,k=0,$=!1,M=0,D=!1,H=0,R=0,V=[],N=c!==-1&&u!==-1;for(let P=0;P<m;P++){e.loadCell(P,this._workCell);let U=this._workCell.getWidth();if(U===0)continue;let j=!1,oe=P>=R,te=P,ne=this._workCell;if(d.length>0&&P===d[0][0]&&oe){let T=d.shift(),K=this._isCellInSelection(T[0],t);for(C=T[0]+1;C<T[1];C++)oe&&(oe=K===this._isCellInSelection(C,t));oe&&(oe=!i||n<T[0]||n>=T[1]),oe?(j=!0,ne=new QF(this._workCell,e.translateToString(!0,T[0],T[1]),T[1]-T[0]),te=T[1]-1,U=ne.getWidth()):R=T[1]}let J=this._isCellInSelection(P,t),fe=i&&P===n,re=N&&P>=c&&P<=u,_e=!1;this._decorationService.forEachDecorationAtCell(P,t,void 0,T=>{_e=!0});let Ne=ne.getChars()||fs;if(Ne===" "&&(ne.isUnderline()||ne.isOverline())&&(Ne=" "),H=U*o-l.get(Ne,ne.isBold(),ne.isItalic()),!_)_=this._document.createElement("span");else if(y&&(J&&D||!J&&!D&&ne.bg===w)&&(J&&D&&f.selectionForeground||ne.fg===v)&&ne.extended.ext===k&&re===$&&H===M&&!fe&&!j&&!_e&&oe){ne.isInvisible()?p+=fs:p+=Ne,y++;continue}else y&&(_.textContent=p),_=this._document.createElement("span"),y=0,p="";if(w=ne.bg,v=ne.fg,k=ne.extended.ext,$=re,M=H,D=J,j&&n>=P&&n<=te&&(n=P),!this._coreService.isCursorHidden&&fe&&this._coreService.isCursorInitialized){if(V.push("xterm-cursor"),this._coreBrowserService.isFocused)a&&V.push("xterm-cursor-blink"),V.push(r==="bar"?"xterm-cursor-bar":r==="underline"?"xterm-cursor-underline":"xterm-cursor-block");else if(s)switch(s){case"outline":V.push("xterm-cursor-outline");break;case"block":V.push("xterm-cursor-block");break;case"bar":V.push("xterm-cursor-bar");break;case"underline":V.push("xterm-cursor-underline");break}}if(ne.isBold()&&V.push("xterm-bold"),ne.isItalic()&&V.push("xterm-italic"),ne.isDim()&&V.push("xterm-dim"),ne.isInvisible()?p=fs:p=ne.getChars()||fs,ne.isUnderline()&&(V.push(`xterm-underline-${ne.extended.underlineStyle}`),p===" "&&(p=" "),!ne.isUnderlineColorDefault()))if(ne.isUnderlineColorRGB())_.style.textDecorationColor=`rgb(${Ll.toColorRGB(ne.getUnderlineColor()).join(",")})`;else{let T=ne.getUnderlineColor();this._optionsService.rawOptions.drawBoldTextInBrightColors&&ne.isBold()&&T<8&&(T+=8),_.style.textDecorationColor=f.ansi[T].css}ne.isOverline()&&(V.push("xterm-overline"),p===" "&&(p=" ")),ne.isStrikethrough()&&V.push("xterm-strikethrough"),re&&(_.style.textDecoration="underline");let $e=ne.getFgColor(),be=ne.getFgColorMode(),me=ne.getBgColor(),O=ne.getBgColorMode(),ie=!!ne.isInverse();if(ie){let T=$e;$e=me,me=T;let K=be;be=O,O=K}let le,ge,Se=!1;this._decorationService.forEachDecorationAtCell(P,t,void 0,T=>{T.options.layer!=="top"&&Se||(T.backgroundColorRGB&&(O=50331648,me=T.backgroundColorRGB.rgba>>8&16777215,le=T.backgroundColorRGB),T.foregroundColorRGB&&(be=50331648,$e=T.foregroundColorRGB.rgba>>8&16777215,ge=T.foregroundColorRGB),Se=T.options.layer==="top")}),!Se&&J&&(le=this._coreBrowserService.isFocused?f.selectionBackgroundOpaque:f.selectionInactiveBackgroundOpaque,me=le.rgba>>8&16777215,O=50331648,Se=!0,f.selectionForeground&&(be=50331648,$e=f.selectionForeground.rgba>>8&16777215,ge=f.selectionForeground)),Se&&V.push("xterm-decoration-top");let x;switch(O){case 16777216:case 33554432:x=f.ansi[me],V.push(`xterm-bg-${me}`);break;case 50331648:x=Rt.toColor(me>>16,me>>8&255,me&255),this._addStyle(_,`background-color:#${D8((me>>>0).toString(16),"0",6)}`);break;case 0:default:ie?(x=f.foreground,V.push("xterm-bg-257")):x=f.background}switch(le||ne.isDim()&&(le=vt.multiplyOpacity(x,.5)),be){case 16777216:case 33554432:ne.isBold()&&$e<8&&this._optionsService.rawOptions.drawBoldTextInBrightColors&&($e+=8),this._applyMinimumContrast(_,x,f.ansi[$e],ne,le,void 0)||V.push(`xterm-fg-${$e}`);break;case 50331648:let T=Rt.toColor($e>>16&255,$e>>8&255,$e&255);this._applyMinimumContrast(_,x,T,ne,le,ge)||this._addStyle(_,`color:#${D8($e.toString(16),"0",6)}`);break;case 0:default:this._applyMinimumContrast(_,x,f.foreground,ne,le,ge)||ie&&V.push("xterm-fg-257")}V.length&&(_.className=V.join(" "),V.length=0),!fe&&!j&&!_e&&oe?y++:_.textContent=p,H!==this.defaultSpacing&&(_.style.letterSpacing=`${H}px`),h.push(_),P=te}return _&&y&&(_.textContent=p),h}_applyMinimumContrast(e,t,i,r,s,n){if(this._optionsService.rawOptions.minimumContrastRatio===1||iz(r.getCode()))return!1;let a=this._getContrastCache(r),o;if(!s&&!n&&(o=a.getColor(t.rgba,i.rgba)),o===void 0){let l=this._optionsService.rawOptions.minimumContrastRatio/(r.isDim()?2:1);o=vt.ensureContrastRatio(s||t,n||i,l),a.setColor((s||t).rgba,(n||i).rgba,o??null)}return o?(this._addStyle(e,`color:${o.css}`),!0):!1}_getContrastCache(e){return e.isDim()?this._themeService.colors.halfContrastCache:this._themeService.colors.contrastCache}_addStyle(e,t){e.setAttribute("style",`${e.getAttribute("style")||""}${t};`)}_isCellInSelection(e,t){let i=this._selectionStart,r=this._selectionEnd;return!i||!r?!1:this._columnSelectMode?i[0]<=r[0]?e>=i[0]&&t>=i[1]&&e<r[0]&&t<=r[1]:e<i[0]&&t>=i[1]&&e>=r[0]&&t<=r[1]:t>i[1]&&t<r[1]||i[1]===r[1]&&t===i[1]&&e>=i[0]&&e<r[0]||i[1]<r[1]&&t===r[1]&&e<r[0]||i[1]<r[1]&&t===i[1]&&e>=i[0]}};ph=Tt([Te(1,ov),Te(2,Mi),Te(3,Jr),Te(4,cn),Te(5,El),Te(6,$a)],ph);function D8(e,t,i){for(;e.length<i;)e=t+e;return e}var sz=class{constructor(e,t){this._flat=new Float32Array(256),this._font="",this._fontSize=0,this._weight="normal",this._weightBold="bold",this._measureElements=[],this._container=e.createElement("div"),this._container.classList.add("xterm-width-cache-measure-container"),this._container.setAttribute("aria-hidden","true"),this._container.style.whiteSpace="pre",this._container.style.fontKerning="none";let i=e.createElement("span");i.classList.add("xterm-char-measure-element");let r=e.createElement("span");r.classList.add("xterm-char-measure-element"),r.style.fontWeight="bold";let s=e.createElement("span");s.classList.add("xterm-char-measure-element"),s.style.fontStyle="italic";let n=e.createElement("span");n.classList.add("xterm-char-measure-element"),n.style.fontWeight="bold",n.style.fontStyle="italic",this._measureElements=[i,r,s,n],this._container.appendChild(i),this._container.appendChild(r),this._container.appendChild(s),this._container.appendChild(n),t.appendChild(this._container),this.clear()}dispose(){this._container.remove(),this._measureElements.length=0,this._holey=void 0}clear(){this._flat.fill(-9999),this._holey=new Map}setFont(e,t,i,r){e===this._font&&t===this._fontSize&&i===this._weight&&r===this._weightBold||(this._font=e,this._fontSize=t,this._weight=i,this._weightBold=r,this._container.style.fontFamily=this._font,this._container.style.fontSize=`${this._fontSize}px`,this._measureElements[0].style.fontWeight=`${i}`,this._measureElements[1].style.fontWeight=`${r}`,this._measureElements[2].style.fontWeight=`${i}`,this._measureElements[3].style.fontWeight=`${r}`,this.clear())}get(e,t,i){let r=0;if(!t&&!i&&e.length===1&&(r=e.charCodeAt(0))<256){if(this._flat[r]!==-9999)return this._flat[r];let a=this._measure(e,0);return a>0&&(this._flat[r]=a),a}let s=e;t&&(s+="B"),i&&(s+="I");let n=this._holey.get(s);if(n===void 0){let a=0;t&&(a|=1),i&&(a|=2),n=this._measure(e,a),n>0&&this._holey.set(s,n)}return n}_measure(e,t){let i=this._measureElements[t];return i.textContent=e.repeat(32),i.offsetWidth/32}},nz=class{constructor(){this.clear()}clear(){this.hasSelection=!1,this.columnSelectMode=!1,this.viewportStartRow=0,this.viewportEndRow=0,this.viewportCappedStartRow=0,this.viewportCappedEndRow=0,this.startCol=0,this.endCol=0,this.selectionStart=void 0,this.selectionEnd=void 0}update(e,t,i,r=!1){if(this.selectionStart=t,this.selectionEnd=i,!t||!i||t[0]===i[0]&&t[1]===i[1]){this.clear();return}let s=e.buffers.active.ydisp,n=t[1]-s,a=i[1]-s,o=Math.max(n,0),l=Math.min(a,e.rows-1);if(o>=e.rows||l<0){this.clear();return}this.hasSelection=!0,this.columnSelectMode=r,this.viewportStartRow=n,this.viewportEndRow=a,this.viewportCappedStartRow=o,this.viewportCappedEndRow=l,this.startCol=t[0],this.endCol=i[0]}isCellSelected(e,t,i){return this.hasSelection?(i-=e.buffer.active.viewportY,this.columnSelectMode?this.startCol<=this.endCol?t>=this.startCol&&i>=this.viewportCappedStartRow&&t<this.endCol&&i<=this.viewportCappedEndRow:t<this.startCol&&i>=this.viewportCappedStartRow&&t>=this.endCol&&i<=this.viewportCappedEndRow:i>this.viewportStartRow&&i<this.viewportEndRow||this.viewportStartRow===this.viewportEndRow&&i===this.viewportStartRow&&t>=this.startCol&&t<this.endCol||this.viewportStartRow<this.viewportEndRow&&i===this.viewportEndRow&&t<this.endCol||this.viewportStartRow<this.viewportEndRow&&i===this.viewportStartRow&&t>=this.startCol):!1}};function az(){return new nz}var E1="xterm-dom-renderer-owner-",Bi="xterm-rows",Ql="xterm-fg-",V8="xterm-bg-",bo="xterm-focus",e0="xterm-selection",oz=1,_h=class extends qe{constructor(e,t,i,r,s,n,a,o,l,c,u,h,d,f){super(),this._terminal=e,this._document=t,this._element=i,this._screenElement=r,this._viewportElement=s,this._helperContainer=n,this._linkifier2=a,this._charSizeService=l,this._optionsService=c,this._bufferService=u,this._coreService=h,this._coreBrowserService=d,this._themeService=f,this._terminalClass=oz++,this._rowElements=[],this._selectionRenderModel=az(),this.onRequestRedraw=this._register(new Ae).event,this._rowContainer=this._document.createElement("div"),this._rowContainer.classList.add(Bi),this._rowContainer.style.lineHeight="normal",this._rowContainer.setAttribute("aria-hidden","true"),this._refreshRowElements(this._bufferService.cols,this._bufferService.rows),this._selectionContainer=this._document.createElement("div"),this._selectionContainer.classList.add(e0),this._selectionContainer.setAttribute("aria-hidden","true"),this.dimensions=rz(),this._updateDimensions(),this._register(this._optionsService.onOptionChange(()=>this._handleOptionsChanged())),this._register(this._themeService.onChangeColors(m=>this._injectCss(m))),this._injectCss(this._themeService.colors),this._rowFactory=o.createInstance(ph,document),this._element.classList.add(E1+this._terminalClass),this._screenElement.appendChild(this._rowContainer),this._screenElement.appendChild(this._selectionContainer),this._register(this._linkifier2.onShowLinkUnderline(m=>this._handleLinkHover(m))),this._register(this._linkifier2.onHideLinkUnderline(m=>this._handleLinkLeave(m))),this._register(St(()=>{this._element.classList.remove(E1+this._terminalClass),this._rowContainer.remove(),this._selectionContainer.remove(),this._widthCache.dispose(),this._themeStyleElement.remove(),this._dimensionsStyleElement.remove()})),this._widthCache=new sz(this._document,this._helperContainer),this._widthCache.setFont(this._optionsService.rawOptions.fontFamily,this._optionsService.rawOptions.fontSize,this._optionsService.rawOptions.fontWeight,this._optionsService.rawOptions.fontWeightBold),this._setDefaultSpacing()}_updateDimensions(){let e=this._coreBrowserService.dpr;this.dimensions.device.char.width=this._charSizeService.width*e,this.dimensions.device.char.height=Math.ceil(this._charSizeService.height*e),this.dimensions.device.cell.width=this.dimensions.device.char.width+Math.round(this._optionsService.rawOptions.letterSpacing),this.dimensions.device.cell.height=Math.floor(this.dimensions.device.char.height*this._optionsService.rawOptions.lineHeight),this.dimensions.device.char.left=0,this.dimensions.device.char.top=0,this.dimensions.device.canvas.width=this.dimensions.device.cell.width*this._bufferService.cols,this.dimensions.device.canvas.height=this.dimensions.device.cell.height*this._bufferService.rows,this.dimensions.css.canvas.width=Math.round(this.dimensions.device.canvas.width/e),this.dimensions.css.canvas.height=Math.round(this.dimensions.device.canvas.height/e),this.dimensions.css.cell.width=this.dimensions.css.canvas.width/this._bufferService.cols,this.dimensions.css.cell.height=this.dimensions.css.canvas.height/this._bufferService.rows;for(let i of this._rowElements)i.style.width=`${this.dimensions.css.canvas.width}px`,i.style.height=`${this.dimensions.css.cell.height}px`,i.style.lineHeight=`${this.dimensions.css.cell.height}px`,i.style.overflow="hidden";this._dimensionsStyleElement||(this._dimensionsStyleElement=this._document.createElement("style"),this._screenElement.appendChild(this._dimensionsStyleElement));let t=`${this._terminalSelector} .${Bi} span { display: inline-block; height: 100%; vertical-align: top;}`;this._dimensionsStyleElement.textContent=t,this._selectionContainer.style.height=this._viewportElement.style.height,this._screenElement.style.width=`${this.dimensions.css.canvas.width}px`,this._screenElement.style.height=`${this.dimensions.css.canvas.height}px`}_injectCss(e){this._themeStyleElement||(this._themeStyleElement=this._document.createElement("style"),this._screenElement.appendChild(this._themeStyleElement));let t=`${this._terminalSelector} .${Bi} { pointer-events: none; color: ${e.foreground.css}; font-family: ${this._optionsService.rawOptions.fontFamily}; font-size: ${this._optionsService.rawOptions.fontSize}px; font-kerning: none; white-space: pre}`;t+=`${this._terminalSelector} .${Bi} .xterm-dim { color: ${vt.multiplyOpacity(e.foreground,.5).css};}`,t+=`${this._terminalSelector} span:not(.xterm-bold) { font-weight: ${this._optionsService.rawOptions.fontWeight};}${this._terminalSelector} span.xterm-bold { font-weight: ${this._optionsService.rawOptions.fontWeightBold};}${this._terminalSelector} span.xterm-italic { font-style: italic;}`;let i=`blink_underline_${this._terminalClass}`,r=`blink_bar_${this._terminalClass}`,s=`blink_block_${this._terminalClass}`;t+=`@keyframes ${i} { 50% { border-bottom-style: hidden; }}`,t+=`@keyframes ${r} { 50% { box-shadow: none; }}`,t+=`@keyframes ${s} { 0% { background-color: ${e.cursor.css}; color: ${e.cursorAccent.css}; } 50% { background-color: inherit; color: ${e.cursor.css}; }}`,t+=`${this._terminalSelector} .${Bi}.${bo} .xterm-cursor.xterm-cursor-blink.xterm-cursor-underline { animation: ${i} 1s step-end infinite;}${this._terminalSelector} .${Bi}.${bo} .xterm-cursor.xterm-cursor-blink.xterm-cursor-bar { animation: ${r} 1s step-end infinite;}${this._terminalSelector} .${Bi}.${bo} .xterm-cursor.xterm-cursor-blink.xterm-cursor-block { animation: ${s} 1s step-end infinite;}${this._terminalSelector} .${Bi} .xterm-cursor.xterm-cursor-block { background-color: ${e.cursor.css}; color: ${e.cursorAccent.css};}${this._terminalSelector} .${Bi} .xterm-cursor.xterm-cursor-block:not(.xterm-cursor-blink) { background-color: ${e.cursor.css} !important; color: ${e.cursorAccent.css} !important;}${this._terminalSelector} .${Bi} .xterm-cursor.xterm-cursor-outline { outline: 1px solid ${e.cursor.css}; outline-offset: -1px;}${this._terminalSelector} .${Bi} .xterm-cursor.xterm-cursor-bar { box-shadow: ${this._optionsService.rawOptions.cursorWidth}px 0 0 ${e.cursor.css} inset;}${this._terminalSelector} .${Bi} .xterm-cursor.xterm-cursor-underline { border-bottom: 1px ${e.cursor.css}; border-bottom-style: solid; height: calc(100% - 1px);}`,t+=`${this._terminalSelector} .${e0} { position: absolute; top: 0; left: 0; z-index: 1; pointer-events: none;}${this._terminalSelector}.focus .${e0} div { position: absolute; background-color: ${e.selectionBackgroundOpaque.css};}${this._terminalSelector} .${e0} div { position: absolute; background-color: ${e.selectionInactiveBackgroundOpaque.css};}`;for(let[n,a]of e.ansi.entries())t+=`${this._terminalSelector} .${Ql}${n} { color: ${a.css}; }${this._terminalSelector} .${Ql}${n}.xterm-dim { color: ${vt.multiplyOpacity(a,.5).css}; }${this._terminalSelector} .${V8}${n} { background-color: ${a.css}; }`;t+=`${this._terminalSelector} .${Ql}257 { color: ${vt.opaque(e.background).css}; }${this._terminalSelector} .${Ql}257.xterm-dim { color: ${vt.multiplyOpacity(vt.opaque(e.background),.5).css}; }${this._terminalSelector} .${V8}257 { background-color: ${e.foreground.css}; }`,this._themeStyleElement.textContent=t}_setDefaultSpacing(){let e=this.dimensions.css.cell.width-this._widthCache.get("W",!1,!1);this._rowContainer.style.letterSpacing=`${e}px`,this._rowFactory.defaultSpacing=e}handleDevicePixelRatioChange(){this._updateDimensions(),this._widthCache.clear(),this._setDefaultSpacing()}_refreshRowElements(e,t){for(let i=this._rowElements.length;i<=t;i++){let r=this._document.createElement("div");this._rowContainer.appendChild(r),this._rowElements.push(r)}for(;this._rowElements.length>t;)this._rowContainer.removeChild(this._rowElements.pop())}handleResize(e,t){this._refreshRowElements(e,t),this._updateDimensions(),this.handleSelectionChanged(this._selectionRenderModel.selectionStart,this._selectionRenderModel.selectionEnd,this._selectionRenderModel.columnSelectMode)}handleCharSizeChanged(){this._updateDimensions(),this._widthCache.clear(),this._setDefaultSpacing()}handleBlur(){this._rowContainer.classList.remove(bo),this.renderRows(0,this._bufferService.rows-1)}handleFocus(){this._rowContainer.classList.add(bo),this.renderRows(this._bufferService.buffer.y,this._bufferService.buffer.y)}handleSelectionChanged(e,t,i){if(this._selectionContainer.replaceChildren(),this._rowFactory.handleSelectionChanged(e,t,i),this.renderRows(0,this._bufferService.rows-1),!e||!t||(this._selectionRenderModel.update(this._terminal,e,t,i),!this._selectionRenderModel.hasSelection))return;let r=this._selectionRenderModel.viewportStartRow,s=this._selectionRenderModel.viewportEndRow,n=this._selectionRenderModel.viewportCappedStartRow,a=this._selectionRenderModel.viewportCappedEndRow,o=this._document.createDocumentFragment();if(i){let l=e[0]>t[0];o.appendChild(this._createSelectionElement(n,l?t[0]:e[0],l?e[0]:t[0],a-n+1))}else{let l=r===n?e[0]:0,c=n===s?t[0]:this._bufferService.cols;o.appendChild(this._createSelectionElement(n,l,c));let u=a-n-1;if(o.appendChild(this._createSelectionElement(n+1,0,this._bufferService.cols,u)),n!==a){let h=s===a?t[0]:this._bufferService.cols;o.appendChild(this._createSelectionElement(a,0,h))}}this._selectionContainer.appendChild(o)}_createSelectionElement(e,t,i,r=1){let s=this._document.createElement("div"),n=t*this.dimensions.css.cell.width,a=this.dimensions.css.cell.width*(i-t);return n+a>this.dimensions.css.canvas.width&&(a=this.dimensions.css.canvas.width-n),s.style.height=`${r*this.dimensions.css.cell.height}px`,s.style.top=`${e*this.dimensions.css.cell.height}px`,s.style.left=`${n}px`,s.style.width=`${a}px`,s}handleCursorMove(){}_handleOptionsChanged(){this._updateDimensions(),this._injectCss(this._themeService.colors),this._widthCache.setFont(this._optionsService.rawOptions.fontFamily,this._optionsService.rawOptions.fontSize,this._optionsService.rawOptions.fontWeight,this._optionsService.rawOptions.fontWeightBold),this._setDefaultSpacing()}clear(){for(let e of this._rowElements)e.replaceChildren()}renderRows(e,t){let i=this._bufferService.buffer,r=i.ybase+i.y,s=Math.min(i.x,this._bufferService.cols-1),n=this._coreService.decPrivateModes.cursorBlink??this._optionsService.rawOptions.cursorBlink,a=this._coreService.decPrivateModes.cursorStyle??this._optionsService.rawOptions.cursorStyle,o=this._optionsService.rawOptions.cursorInactiveStyle;for(let l=e;l<=t;l++){let c=l+i.ydisp,u=this._rowElements[l],h=i.lines.get(c);if(!u||!h)break;u.replaceChildren(...this._rowFactory.createRow(h,c,c===r,a,o,s,n,this.dimensions.css.cell.width,this._widthCache,-1,-1))}}get _terminalSelector(){return`.${E1}${this._terminalClass}`}_handleLinkHover(e){this._setCellUnderline(e.x1,e.x2,e.y1,e.y2,e.cols,!0)}_handleLinkLeave(e){this._setCellUnderline(e.x1,e.x2,e.y1,e.y2,e.cols,!1)}_setCellUnderline(e,t,i,r,s,n){i<0&&(e=0),r<0&&(t=0);let a=this._bufferService.rows-1;i=Math.max(Math.min(i,a),0),r=Math.max(Math.min(r,a),0),s=Math.min(s,this._bufferService.cols);let o=this._bufferService.buffer,l=o.ybase+o.y,c=Math.min(o.x,s-1),u=this._optionsService.rawOptions.cursorBlink,h=this._optionsService.rawOptions.cursorStyle,d=this._optionsService.rawOptions.cursorInactiveStyle;for(let f=i;f<=r;++f){let m=f+o.ydisp,_=this._rowElements[f],y=o.lines.get(m);if(!_||!y)break;_.replaceChildren(...this._rowFactory.createRow(y,m,m===l,h,d,c,u,this.dimensions.css.cell.width,this._widthCache,n?f===i?e:0:-1,n?(f===r?t:s)-1:-1))}}};_h=Tt([Te(7,Od),Te(8,Oc),Te(9,Mi),Te(10,Ai),Te(11,cn),Te(12,Jr),Te(13,$a)],_h);var mh=class extends qe{constructor(e,t,i){super(),this._optionsService=i,this.width=0,this.height=0,this._onCharSizeChange=this._register(new Ae),this.onCharSizeChange=this._onCharSizeChange.event;try{this._measureStrategy=this._register(new cz(this._optionsService))}catch{this._measureStrategy=this._register(new lz(e,t,this._optionsService))}this._register(this._optionsService.onMultipleOptionChange(["fontFamily","fontSize"],()=>this.measure()))}get hasValidSize(){return this.width>0&&this.height>0}measure(){let e=this._measureStrategy.measure();(e.width!==this.width||e.height!==this.height)&&(this.width=e.width,this.height=e.height,this._onCharSizeChange.fire())}};mh=Tt([Te(2,Mi)],mh);var Mv=class extends qe{constructor(){super(...arguments),this._result={width:0,height:0}}_validateAndSet(e,t){e!==void 0&&e>0&&t!==void 0&&t>0&&(this._result.width=e,this._result.height=t)}},lz=class extends Mv{constructor(e,t,i){super(),this._document=e,this._parentElement=t,this._optionsService=i,this._measureElement=this._document.createElement("span"),this._measureElement.classList.add("xterm-char-measure-element"),this._measureElement.textContent="W".repeat(32),this._measureElement.setAttribute("aria-hidden","true"),this._measureElement.style.whiteSpace="pre",this._measureElement.style.fontKerning="none",this._parentElement.appendChild(this._measureElement)}measure(){return this._measureElement.style.fontFamily=this._optionsService.rawOptions.fontFamily,this._measureElement.style.fontSize=`${this._optionsService.rawOptions.fontSize}px`,this._validateAndSet(Number(this._measureElement.offsetWidth)/32,Number(this._measureElement.offsetHeight)),this._result}},cz=class extends Mv{constructor(e){super(),this._optionsService=e,this._canvas=new OffscreenCanvas(100,100),this._ctx=this._canvas.getContext("2d");let t=this._ctx.measureText("W");if(!("width"in t&&"fontBoundingBoxAscent"in t&&"fontBoundingBoxDescent"in t))throw new Error("Required font metrics not supported")}measure(){this._ctx.font=`${this._optionsService.rawOptions.fontSize}px ${this._optionsService.rawOptions.fontFamily}`;let e=this._ctx.measureText("W");return this._validateAndSet(e.width,e.fontBoundingBoxAscent+e.fontBoundingBoxDescent),this._result}},uz=class extends qe{constructor(e,t,i){super(),this._textarea=e,this._window=t,this.mainDocument=i,this._isFocused=!1,this._cachedIsFocused=void 0,this._screenDprMonitor=this._register(new hz(this._window)),this._onDprChange=this._register(new Ae),this.onDprChange=this._onDprChange.event,this._onWindowChange=this._register(new Ae),this.onWindowChange=this._onWindowChange.event,this._register(this.onWindowChange(r=>this._screenDprMonitor.setWindow(r))),this._register(si.forward(this._screenDprMonitor.onDprChange,this._onDprChange)),this._register(ze(this._textarea,"focus",()=>this._isFocused=!0)),this._register(ze(this._textarea,"blur",()=>this._isFocused=!1))}get window(){return this._window}set window(e){this._window!==e&&(this._window=e,this._onWindowChange.fire(this._window))}get dpr(){return this.window.devicePixelRatio}get isFocused(){return this._cachedIsFocused===void 0&&(this._cachedIsFocused=this._isFocused&&this._textarea.ownerDocument.hasFocus(),queueMicrotask(()=>this._cachedIsFocused=void 0)),this._cachedIsFocused}},hz=class extends qe{constructor(e){super(),this._parentWindow=e,this._windowResizeListener=this._register(new Kn),this._onDprChange=this._register(new Ae),this.onDprChange=this._onDprChange.event,this._outerListener=()=>this._setDprAndFireIfDiffers(),this._currentDevicePixelRatio=this._parentWindow.devicePixelRatio,this._updateDpr(),this._setWindowResizeListener(),this._register(St(()=>this.clearListener()))}setWindow(e){this._parentWindow=e,this._setWindowResizeListener(),this._setDprAndFireIfDiffers()}_setWindowResizeListener(){this._windowResizeListener.value=ze(this._parentWindow,"resize",()=>this._setDprAndFireIfDiffers())}_setDprAndFireIfDiffers(){this._parentWindow.devicePixelRatio!==this._currentDevicePixelRatio&&this._onDprChange.fire(this._parentWindow.devicePixelRatio),this._updateDpr()}_updateDpr(){var e;this._outerListener&&((e=this._resolutionMediaMatchList)==null||e.removeListener(this._outerListener),this._currentDevicePixelRatio=this._parentWindow.devicePixelRatio,this._resolutionMediaMatchList=this._parentWindow.matchMedia(`screen and (resolution: ${this._parentWindow.devicePixelRatio}dppx)`),this._resolutionMediaMatchList.addListener(this._outerListener))}clearListener(){!this._resolutionMediaMatchList||!this._outerListener||(this._resolutionMediaMatchList.removeListener(this._outerListener),this._resolutionMediaMatchList=void 0,this._outerListener=void 0)}},dz=class extends qe{constructor(){super(),this.linkProviders=[],this._register(St(()=>this.linkProviders.length=0))}registerLinkProvider(e){return this.linkProviders.push(e),{dispose:()=>{let t=this.linkProviders.indexOf(e);t!==-1&&this.linkProviders.splice(t,1)}}}};function zd(e,t,i){let r=i.getBoundingClientRect(),s=e.getComputedStyle(i),n=parseInt(s.getPropertyValue("padding-left")),a=parseInt(s.getPropertyValue("padding-top"));return[t.clientX-r.left-n,t.clientY-r.top-a]}function fz(e,t,i,r,s,n,a,o,l){if(!n)return;let c=zd(e,t,i);if(c)return c[0]=Math.ceil((c[0]+(l?a/2:0))/a),c[1]=Math.ceil(c[1]/o),c[0]=Math.min(Math.max(c[0],1),r+(l?1:0)),c[1]=Math.min(Math.max(c[1],1),s),c}var gh=class{constructor(e,t){this._renderService=e,this._charSizeService=t}getCoords(e,t,i,r,s){return fz(window,e,t,i,r,this._charSizeService.hasValidSize,this._renderService.dimensions.css.cell.width,this._renderService.dimensions.css.cell.height,s)}getMouseReportCoords(e,t){let i=zd(window,e,t);if(this._charSizeService.hasValidSize)return i[0]=Math.min(Math.max(i[0],0),this._renderService.dimensions.css.canvas.width-1),i[1]=Math.min(Math.max(i[1],0),this._renderService.dimensions.css.canvas.height-1),{col:Math.floor(i[0]/this._renderService.dimensions.css.cell.width),row:Math.floor(i[1]/this._renderService.dimensions.css.cell.height),x:Math.floor(i[0]),y:Math.floor(i[1])}}};gh=Tt([Te(0,Qr),Te(1,Oc)],gh);var pz=class{constructor(e,t){this._renderCallback=e,this._coreBrowserService=t,this._refreshCallbacks=[]}dispose(){this._animationFrame&&(this._coreBrowserService.window.cancelAnimationFrame(this._animationFrame),this._animationFrame=void 0)}addRefreshCallback(e){return this._refreshCallbacks.push(e),this._animationFrame||(this._animationFrame=this._coreBrowserService.window.requestAnimationFrame(()=>this._innerRefresh())),this._animationFrame}refresh(e,t,i){this._rowCount=i,e=e!==void 0?e:0,t=t!==void 0?t:this._rowCount-1,this._rowStart=this._rowStart!==void 0?Math.min(this._rowStart,e):e,this._rowEnd=this._rowEnd!==void 0?Math.max(this._rowEnd,t):t,!this._animationFrame&&(this._animationFrame=this._coreBrowserService.window.requestAnimationFrame(()=>this._innerRefresh()))}_innerRefresh(){if(this._animationFrame=void 0,this._rowStart===void 0||this._rowEnd===void 0||this._rowCount===void 0){this._runRefreshCallbacks();return}let e=Math.max(this._rowStart,0),t=Math.min(this._rowEnd,this._rowCount-1);this._rowStart=void 0,this._rowEnd=void 0,this._renderCallback(e,t),this._runRefreshCallbacks()}_runRefreshCallbacks(){for(let e of this._refreshCallbacks)e(0);this._refreshCallbacks=[]}},Lv={};kZ(Lv,{getSafariVersion:()=>mz,isChromeOS:()=>Tv,isFirefox:()=>Ev,isIpad:()=>gz,isIphone:()=>vz,isLegacyEdge:()=>_z,isLinux:()=>Ud,isMac:()=>Y0,isNode:()=>Ic,isSafari:()=>$v,isWindows:()=>xv});var Ic=typeof process<"u"&&"title"in process,$l=Ic?"node":navigator.userAgent,xl=Ic?"node":navigator.platform,Ev=$l.includes("Firefox"),_z=$l.includes("Edge"),$v=/^((?!chrome|android).)*safari/i.test($l);function mz(){if(!$v)return 0;let e=$l.match(/Version\/(\d+)/);return e===null||e.length<2?0:parseInt(e[1])}var Y0=["Macintosh","MacIntel","MacPPC","Mac68K"].includes(xl),gz=xl==="iPad",vz=xl==="iPhone",xv=["Windows","Win16","Win32","WinCE"].includes(xl),Ud=xl.indexOf("Linux")>=0,Tv=/\bCrOS\b/.test($l),Nv=class{constructor(){this._tasks=[],this._i=0}enqueue(e){this._tasks.push(e),this._start()}flush(){for(;this._i<this._tasks.length;)this._tasks[this._i]()||this._i++;this.clear()}clear(){this._idleCallback&&(this._cancelCallback(this._idleCallback),this._idleCallback=void 0),this._i=0,this._tasks.length=0}_start(){this._idleCallback||(this._idleCallback=this._requestCallback(this._process.bind(this)))}_process(e){this._idleCallback=void 0;let t=0,i=0,r=e.timeRemaining(),s=0;for(;this._i<this._tasks.length;){if(t=performance.now(),this._tasks[this._i]()||this._i++,t=Math.max(1,performance.now()-t),i=Math.max(t,i),s=e.timeRemaining(),i*1.5>s){r-t<-20&&console.warn(`task queue exceeded allotted deadline by ${Math.abs(Math.round(r-t))}ms`),this._start();return}r=s}this.clear()}},bz=class extends Nv{_requestCallback(e){return setTimeout(()=>e(this._createDeadline(16)))}_cancelCallback(e){clearTimeout(e)}_createDeadline(e){let t=performance.now()+e;return{timeRemaining:()=>Math.max(0,t-performance.now())}}},yz=class extends Nv{_requestCallback(e){return requestIdleCallback(e)}_cancelCallback(e){cancelIdleCallback(e)}},X0=!Ic&&"requestIdleCallback"in window?yz:bz,wz=class{constructor(){this._queue=new X0}set(e){this._queue.clear(),this._queue.enqueue(e)}flush(){this._queue.flush()}},vh=class extends qe{constructor(e,t,i,r,s,n,a,o,l){super(),this._rowCount=e,this._optionsService=i,this._charSizeService=r,this._coreService=s,this._coreBrowserService=o,this._renderer=this._register(new Kn),this._pausedResizeTask=new wz,this._observerDisposable=this._register(new Kn),this._isPaused=!1,this._needsFullRefresh=!1,this._isNextRenderRedrawOnly=!0,this._needsSelectionRefresh=!1,this._canvasWidth=0,this._canvasHeight=0,this._selectionState={start:void 0,end:void 0,columnSelectMode:!1},this._onDimensionsChange=this._register(new Ae),this.onDimensionsChange=this._onDimensionsChange.event,this._onRenderedViewportChange=this._register(new Ae),this.onRenderedViewportChange=this._onRenderedViewportChange.event,this._onRender=this._register(new Ae),this.onRender=this._onRender.event,this._onRefreshRequest=this._register(new Ae),this.onRefreshRequest=this._onRefreshRequest.event,this._renderDebouncer=new pz((c,u)=>this._renderRows(c,u),this._coreBrowserService),this._register(this._renderDebouncer),this._syncOutputHandler=new Sz(this._coreBrowserService,this._coreService,()=>this._fullRefresh()),this._register(St(()=>this._syncOutputHandler.dispose())),this._register(this._coreBrowserService.onDprChange(()=>this.handleDevicePixelRatioChange())),this._register(a.onResize(()=>this._fullRefresh())),this._register(a.buffers.onBufferActivate(()=>{var c;return(c=this._renderer.value)==null?void 0:c.clear()})),this._register(this._optionsService.onOptionChange(()=>this._handleOptionsChanged())),this._register(this._charSizeService.onCharSizeChange(()=>this.handleCharSizeChanged())),this._register(n.onDecorationRegistered(()=>this._fullRefresh())),this._register(n.onDecorationRemoved(()=>this._fullRefresh())),this._register(this._optionsService.onMultipleOptionChange(["customGlyphs","drawBoldTextInBrightColors","letterSpacing","lineHeight","fontFamily","fontSize","fontWeight","fontWeightBold","minimumContrastRatio","rescaleOverlappingGlyphs"],()=>{this.clear(),this.handleResize(a.cols,a.rows),this._fullRefresh()})),this._register(this._optionsService.onMultipleOptionChange(["cursorBlink","cursorStyle"],()=>this.refreshRows(a.buffer.y,a.buffer.y,!0))),this._register(l.onChangeColors(()=>this._fullRefresh())),this._registerIntersectionObserver(this._coreBrowserService.window,t),this._register(this._coreBrowserService.onWindowChange(c=>this._registerIntersectionObserver(c,t)))}get dimensions(){return this._renderer.value.dimensions}_registerIntersectionObserver(e,t){if("IntersectionObserver"in e){let i=new e.IntersectionObserver(r=>this._handleIntersectionChange(r[r.length-1]),{threshold:0});i.observe(t),this._observerDisposable.value=St(()=>i.disconnect())}}_handleIntersectionChange(e){this._isPaused=e.isIntersecting===void 0?e.intersectionRatio===0:!e.isIntersecting,!this._isPaused&&!this._charSizeService.hasValidSize&&this._charSizeService.measure(),!this._isPaused&&this._needsFullRefresh&&(this._pausedResizeTask.flush(),this.refreshRows(0,this._rowCount-1),this._needsFullRefresh=!1)}refreshRows(e,t,i=!1){if(this._isPaused){this._needsFullRefresh=!0;return}if(this._coreService.decPrivateModes.synchronizedOutput){this._syncOutputHandler.bufferRows(e,t);return}let r=this._syncOutputHandler.flush();r&&(e=Math.min(e,r.start),t=Math.max(t,r.end)),i||(this._isNextRenderRedrawOnly=!1),this._renderDebouncer.refresh(e,t,this._rowCount)}_renderRows(e,t){if(this._renderer.value){if(this._coreService.decPrivateModes.synchronizedOutput){this._syncOutputHandler.bufferRows(e,t);return}e=Math.min(e,this._rowCount-1),t=Math.min(t,this._rowCount-1),this._renderer.value.renderRows(e,t),this._needsSelectionRefresh&&(this._renderer.value.handleSelectionChanged(this._selectionState.start,this._selectionState.end,this._selectionState.columnSelectMode),this._needsSelectionRefresh=!1),this._isNextRenderRedrawOnly||this._onRenderedViewportChange.fire({start:e,end:t}),this._onRender.fire({start:e,end:t}),this._isNextRenderRedrawOnly=!0}}resize(e,t){this._rowCount=t,this._fireOnCanvasResize()}_handleOptionsChanged(){this._renderer.value&&(this.refreshRows(0,this._rowCount-1),this._fireOnCanvasResize())}_fireOnCanvasResize(){this._renderer.value&&(this._renderer.value.dimensions.css.canvas.width===this._canvasWidth&&this._renderer.value.dimensions.css.canvas.height===this._canvasHeight||this._onDimensionsChange.fire(this._renderer.value.dimensions))}hasRenderer(){return!!this._renderer.value}setRenderer(e){this._renderer.value=e,this._renderer.value&&(this._renderer.value.onRequestRedraw(t=>this.refreshRows(t.start,t.end,!0)),this._needsSelectionRefresh=!0,this._fullRefresh())}addRefreshCallback(e){return this._renderDebouncer.addRefreshCallback(e)}_fullRefresh(){this._isPaused?this._needsFullRefresh=!0:this.refreshRows(0,this._rowCount-1)}clearTextureAtlas(){var e,t;this._renderer.value&&((t=(e=this._renderer.value).clearTextureAtlas)==null||t.call(e),this._fullRefresh())}handleDevicePixelRatioChange(){this._charSizeService.measure(),this._renderer.value&&(this._renderer.value.handleDevicePixelRatioChange(),this.refreshRows(0,this._rowCount-1))}handleResize(e,t){this._renderer.value&&(this._isPaused?this._pausedResizeTask.set(()=>{var i;return(i=this._renderer.value)==null?void 0:i.handleResize(e,t)}):this._renderer.value.handleResize(e,t),this._fullRefresh())}handleCharSizeChanged(){var e;(e=this._renderer.value)==null||e.handleCharSizeChanged()}handleBlur(){var e;(e=this._renderer.value)==null||e.handleBlur()}handleFocus(){var e;(e=this._renderer.value)==null||e.handleFocus()}handleSelectionChanged(e,t,i){var r;this._selectionState.start=e,this._selectionState.end=t,this._selectionState.columnSelectMode=i,(r=this._renderer.value)==null||r.handleSelectionChanged(e,t,i)}handleCursorMove(){var e;(e=this._renderer.value)==null||e.handleCursorMove()}clear(){var e;(e=this._renderer.value)==null||e.clear()}};vh=Tt([Te(2,Mi),Te(3,Oc),Te(4,cn),Te(5,El),Te(6,Ai),Te(7,Jr),Te(8,$a)],vh);var Sz=class{constructor(e,t,i){this._coreBrowserService=e,this._coreService=t,this._onTimeout=i,this._start=0,this._end=0,this._isBuffering=!1}bufferRows(e,t){this._isBuffering?(this._start=Math.min(this._start,e),this._end=Math.max(this._end,t)):(this._start=e,this._end=t,this._isBuffering=!0),this._timeout===void 0&&(this._timeout=this._coreBrowserService.window.setTimeout(()=>{this._timeout=void 0,this._coreService.decPrivateModes.synchronizedOutput=!1,this._onTimeout()},1e3))}flush(){if(this._timeout!==void 0&&(this._coreBrowserService.window.clearTimeout(this._timeout),this._timeout=void 0),!this._isBuffering)return;let e={start:this._start,end:this._end};return this._isBuffering=!1,e}dispose(){this._timeout!==void 0&&(this._coreBrowserService.window.clearTimeout(this._timeout),this._timeout=void 0)}};function Cz(e,t,i,r){let s=i.buffer.x,n=i.buffer.y;if(!i.buffer.hasScrollback)return Mz(s,n,e,t,i,r)+Rc(n,t,i,r)+Lz(s,n,e,t,i,r);let a;if(n===t)return a=s>e?"D":"C",pl(Math.abs(s-e),fl(a,r));a=n>t?"D":"C";let o=Math.abs(n-t),l=Az(n>t?e:s,i)+(o-1)*i.cols+1+kz(n>t?s:e);return pl(l,fl(a,r))}function kz(e,t){return e-1}function Az(e,t){return t.cols-e}function Mz(e,t,i,r,s,n){return Rc(t,r,s,n).length===0?"":pl(Pv(e,t,e,t-nn(t,s),!1,s).length,fl("D",n))}function Rc(e,t,i,r){let s=e-nn(e,i),n=t-nn(t,i),a=Math.abs(s-n)-Ez(e,t,i);return pl(a,fl(Hv(e,t),r))}function Lz(e,t,i,r,s,n){let a;Rc(t,r,s,n).length>0?a=r-nn(r,s):a=t;let o=r,l=$z(e,t,i,r,s,n);return pl(Pv(e,a,i,o,l==="C",s).length,fl(l,n))}function Ez(e,t,i){var a;let r=0,s=e-nn(e,i),n=t-nn(t,i);for(let o=0;o<Math.abs(s-n);o++){let l=Hv(e,t)==="A"?-1:1;(a=i.buffer.lines.get(s+l*o))!=null&&a.isWrapped&&r++}return r}function nn(e,t){let i=0,r=t.buffer.lines.get(e),s=r==null?void 0:r.isWrapped;for(;s&&e>=0&&e<t.rows;)i++,r=t.buffer.lines.get(--e),s=r==null?void 0:r.isWrapped;return i}function $z(e,t,i,r,s,n){let a;return Rc(i,r,s,n).length>0?a=r-nn(r,s):a=t,e<i&&a<=r||e>=i&&a<r?"C":"D"}function Hv(e,t){return e>t?"A":"B"}function Pv(e,t,i,r,s,n){let a=e,o=t,l="";for(;(a!==i||o!==r)&&o>=0&&o<n.buffer.lines.length;)a+=s?1:-1,s&&a>n.cols-1?(l+=n.buffer.translateBufferLineToString(o,!1,e,a),a=0,e=0,o++):!s&&a<0&&(l+=n.buffer.translateBufferLineToString(o,!1,0,e+1),a=n.cols-1,e=a,o--);return l+n.buffer.translateBufferLineToString(o,!1,e,a)}function fl(e,t){let i=t?"O":"[";return ve.ESC+i+e}function pl(e,t){e=Math.floor(e);let i="";for(let r=0;r<e;r++)i+=t;return i}var xz=class{constructor(e){this._bufferService=e,this.isSelectAllActive=!1,this.selectionStartLength=0}clearSelection(){this.selectionStart=void 0,this.selectionEnd=void 0,this.isSelectAllActive=!1,this.selectionStartLength=0}get finalSelectionStart(){return this.isSelectAllActive?[0,0]:!this.selectionEnd||!this.selectionStart?this.selectionStart:this.areSelectionValuesReversed()?this.selectionEnd:this.selectionStart}get finalSelectionEnd(){if(this.isSelectAllActive)return[this._bufferService.cols,this._bufferService.buffer.ybase+this._bufferService.rows-1];if(this.selectionStart){if(!this.selectionEnd||this.areSelectionValuesReversed()){let e=this.selectionStart[0]+this.selectionStartLength;return e>this._bufferService.cols?e%this._bufferService.cols===0?[this._bufferService.cols,this.selectionStart[1]+Math.floor(e/this._bufferService.cols)-1]:[e%this._bufferService.cols,this.selectionStart[1]+Math.floor(e/this._bufferService.cols)]:[e,this.selectionStart[1]]}if(this.selectionStartLength&&this.selectionEnd[1]===this.selectionStart[1]){let e=this.selectionStart[0]+this.selectionStartLength;return e>this._bufferService.cols?[e%this._bufferService.cols,this.selectionStart[1]+Math.floor(e/this._bufferService.cols)]:[Math.max(e,this.selectionEnd[0]),this.selectionEnd[1]]}return this.selectionEnd}}areSelectionValuesReversed(){let e=this.selectionStart,t=this.selectionEnd;return!e||!t?!1:e[1]>t[1]||e[1]===t[1]&&e[0]>t[0]}handleTrim(e){return this.selectionStart&&(this.selectionStart[1]-=e),this.selectionEnd&&(this.selectionEnd[1]-=e),this.selectionEnd&&this.selectionEnd[1]<0?(this.clearSelection(),!0):(this.selectionStart&&this.selectionStart[1]<0&&(this.selectionStart[1]=0),!1)}};function B8(e,t){if(e.start.y>e.end.y)throw new Error(`Buffer range end (${e.end.x}, ${e.end.y}) cannot be before start (${e.start.x}, ${e.start.y})`);return t*(e.end.y-e.start.y)+(e.end.x-e.start.x+1)}var $1=50,Tz=15,Nz=50,Hz=500,Pz=" ",Oz=new RegExp(Pz,"g"),bh=class extends qe{constructor(e,t,i,r,s,n,a,o,l){super(),this._element=e,this._screenElement=t,this._linkifier=i,this._bufferService=r,this._coreService=s,this._mouseService=n,this._optionsService=a,this._renderService=o,this._coreBrowserService=l,this._dragScrollAmount=0,this._enabled=!0,this._workCell=new Ki,this._mouseDownTimeStamp=0,this._oldHasSelection=!1,this._oldSelectionStart=void 0,this._oldSelectionEnd=void 0,this._onLinuxMouseSelection=this._register(new Ae),this.onLinuxMouseSelection=this._onLinuxMouseSelection.event,this._onRedrawRequest=this._register(new Ae),this.onRequestRedraw=this._onRedrawRequest.event,this._onSelectionChange=this._register(new Ae),this.onSelectionChange=this._onSelectionChange.event,this._onRequestScrollLines=this._register(new Ae),this.onRequestScrollLines=this._onRequestScrollLines.event,this._mouseMoveListener=c=>this._handleMouseMove(c),this._mouseUpListener=c=>this._handleMouseUp(c),this._coreService.onUserInput(()=>{this.hasSelection&&this.clearSelection()}),this._trimListener=this._bufferService.buffer.lines.onTrim(c=>this._handleTrim(c)),this._register(this._bufferService.buffers.onBufferActivate(c=>this._handleBufferActivate(c))),this.enable(),this._model=new xz(this._bufferService),this._activeSelectionMode=0,this._register(St(()=>{this._removeMouseDownListeners()})),this._register(this._bufferService.onResize(c=>{c.rowsChanged&&this.clearSelection()}))}reset(){this.clearSelection()}disable(){this.clearSelection(),this._enabled=!1}enable(){this._enabled=!0}get selectionStart(){return this._model.finalSelectionStart}get selectionEnd(){return this._model.finalSelectionEnd}get hasSelection(){let e=this._model.finalSelectionStart,t=this._model.finalSelectionEnd;return!e||!t?!1:e[0]!==t[0]||e[1]!==t[1]}get selectionText(){let e=this._model.finalSelectionStart,t=this._model.finalSelectionEnd;if(!e||!t)return"";let i=this._bufferService.buffer,r=[];if(this._activeSelectionMode===3){if(e[0]===t[0])return"";let s=e[0]<t[0]?e[0]:t[0],n=e[0]<t[0]?t[0]:e[0];for(let a=e[1];a<=t[1];a++){let o=i.translateBufferLineToString(a,!0,s,n);r.push(o)}}else{let s=e[1]===t[1]?t[0]:void 0;r.push(i.translateBufferLineToString(e[1],!0,e[0],s));for(let n=e[1]+1;n<=t[1]-1;n++){let a=i.lines.get(n),o=i.translateBufferLineToString(n,!0);a!=null&&a.isWrapped?r[r.length-1]+=o:r.push(o)}if(e[1]!==t[1]){let n=i.lines.get(t[1]),a=i.translateBufferLineToString(t[1],!0,0,t[0]);n&&n.isWrapped?r[r.length-1]+=a:r.push(a)}}return r.map(s=>s.replace(Oz," ")).join(xv?`\r
|
|
91
|
-
`:`
|
|
92
|
-
`)}clearSelection(){this._model.clearSelection(),this._removeMouseDownListeners(),this.refresh(),this._onSelectionChange.fire()}refresh(e){this._refreshAnimationFrame||(this._refreshAnimationFrame=this._coreBrowserService.window.requestAnimationFrame(()=>this._refresh())),Ud&&e&&this.selectionText.length&&this._onLinuxMouseSelection.fire(this.selectionText)}_refresh(){this._refreshAnimationFrame=void 0,this._onRedrawRequest.fire({start:this._model.finalSelectionStart,end:this._model.finalSelectionEnd,columnSelectMode:this._activeSelectionMode===3})}_isClickInSelection(e){let t=this._getMouseBufferCoords(e),i=this._model.finalSelectionStart,r=this._model.finalSelectionEnd;return!i||!r||!t?!1:this._areCoordsInSelection(t,i,r)}isCellInSelection(e,t){let i=this._model.finalSelectionStart,r=this._model.finalSelectionEnd;return!i||!r?!1:this._areCoordsInSelection([e,t],i,r)}_areCoordsInSelection(e,t,i){return e[1]>t[1]&&e[1]<i[1]||t[1]===i[1]&&e[1]===t[1]&&e[0]>=t[0]&&e[0]<i[0]||t[1]<i[1]&&e[1]===i[1]&&e[0]<i[0]||t[1]<i[1]&&e[1]===t[1]&&e[0]>=t[0]}_selectWordAtCursor(e,t){var s,n;let i=(n=(s=this._linkifier.currentLink)==null?void 0:s.link)==null?void 0:n.range;if(i)return this._model.selectionStart=[i.start.x-1,i.start.y-1],this._model.selectionStartLength=B8(i,this._bufferService.cols),this._model.selectionEnd=void 0,!0;let r=this._getMouseBufferCoords(e);return r?(this._selectWordAt(r,t),this._model.selectionEnd=void 0,!0):!1}selectAll(){this._model.isSelectAllActive=!0,this.refresh(),this._onSelectionChange.fire()}selectLines(e,t){this._model.clearSelection(),e=Math.max(e,0),t=Math.min(t,this._bufferService.buffer.lines.length-1),this._model.selectionStart=[0,e],this._model.selectionEnd=[this._bufferService.cols,t],this.refresh(),this._onSelectionChange.fire()}_handleTrim(e){this._model.handleTrim(e)&&this.refresh()}_getMouseBufferCoords(e){let t=this._mouseService.getCoords(e,this._screenElement,this._bufferService.cols,this._bufferService.rows,!0);if(t)return t[0]--,t[1]--,t[1]+=this._bufferService.buffer.ydisp,t}_getMouseEventScrollAmount(e){let t=zd(this._coreBrowserService.window,e,this._screenElement)[1],i=this._renderService.dimensions.css.canvas.height;return t>=0&&t<=i?0:(t>i&&(t-=i),t=Math.min(Math.max(t,-$1),$1),t/=$1,t/Math.abs(t)+Math.round(t*(Tz-1)))}shouldForceSelection(e){return Y0?e.altKey&&this._optionsService.rawOptions.macOptionClickForcesSelection:e.shiftKey}handleMouseDown(e){if(this._mouseDownTimeStamp=e.timeStamp,!(e.button===2&&this.hasSelection)&&e.button===0){if(!this._enabled){if(!this.shouldForceSelection(e))return;e.stopPropagation()}e.preventDefault(),this._dragScrollAmount=0,this._enabled&&e.shiftKey?this._handleIncrementalClick(e):e.detail===1?this._handleSingleClick(e):e.detail===2?this._handleDoubleClick(e):e.detail===3&&this._handleTripleClick(e),this._addMouseDownListeners(),this.refresh(!0)}}_addMouseDownListeners(){this._screenElement.ownerDocument&&(this._screenElement.ownerDocument.addEventListener("mousemove",this._mouseMoveListener),this._screenElement.ownerDocument.addEventListener("mouseup",this._mouseUpListener)),this._dragScrollIntervalTimer=this._coreBrowserService.window.setInterval(()=>this._dragScroll(),Nz)}_removeMouseDownListeners(){this._screenElement.ownerDocument&&(this._screenElement.ownerDocument.removeEventListener("mousemove",this._mouseMoveListener),this._screenElement.ownerDocument.removeEventListener("mouseup",this._mouseUpListener)),this._coreBrowserService.window.clearInterval(this._dragScrollIntervalTimer),this._dragScrollIntervalTimer=void 0}_handleIncrementalClick(e){this._model.selectionStart&&(this._model.selectionEnd=this._getMouseBufferCoords(e))}_handleSingleClick(e){if(this._model.selectionStartLength=0,this._model.isSelectAllActive=!1,this._activeSelectionMode=this.shouldColumnSelect(e)?3:0,this._model.selectionStart=this._getMouseBufferCoords(e),!this._model.selectionStart)return;this._model.selectionEnd=void 0;let t=this._bufferService.buffer.lines.get(this._model.selectionStart[1]);t&&t.length!==this._model.selectionStart[0]&&t.hasWidth(this._model.selectionStart[0])===0&&this._model.selectionStart[0]++}_handleDoubleClick(e){this._selectWordAtCursor(e,!0)&&(this._activeSelectionMode=1)}_handleTripleClick(e){let t=this._getMouseBufferCoords(e);t&&(this._activeSelectionMode=2,this._selectLineAt(t[1]))}shouldColumnSelect(e){return e.altKey&&!(Y0&&this._optionsService.rawOptions.macOptionClickForcesSelection)}_handleMouseMove(e){if(e.stopImmediatePropagation(),!this._model.selectionStart)return;let t=this._model.selectionEnd?[this._model.selectionEnd[0],this._model.selectionEnd[1]]:null;if(this._model.selectionEnd=this._getMouseBufferCoords(e),!this._model.selectionEnd){this.refresh(!0);return}this._activeSelectionMode===2?this._model.selectionEnd[1]<this._model.selectionStart[1]?this._model.selectionEnd[0]=0:this._model.selectionEnd[0]=this._bufferService.cols:this._activeSelectionMode===1&&this._selectToWordAt(this._model.selectionEnd),this._dragScrollAmount=this._getMouseEventScrollAmount(e),this._activeSelectionMode!==3&&(this._dragScrollAmount>0?this._model.selectionEnd[0]=this._bufferService.cols:this._dragScrollAmount<0&&(this._model.selectionEnd[0]=0));let i=this._bufferService.buffer;if(this._model.selectionEnd[1]<i.lines.length){let r=i.lines.get(this._model.selectionEnd[1]);r&&r.hasWidth(this._model.selectionEnd[0])===0&&this._model.selectionEnd[0]<this._bufferService.cols&&this._model.selectionEnd[0]++}(!t||t[0]!==this._model.selectionEnd[0]||t[1]!==this._model.selectionEnd[1])&&this.refresh(!0)}_dragScroll(){if(!(!this._model.selectionEnd||!this._model.selectionStart)&&this._dragScrollAmount){this._onRequestScrollLines.fire({amount:this._dragScrollAmount,suppressScrollEvent:!1});let e=this._bufferService.buffer;this._dragScrollAmount>0?(this._activeSelectionMode!==3&&(this._model.selectionEnd[0]=this._bufferService.cols),this._model.selectionEnd[1]=Math.min(e.ydisp+this._bufferService.rows,e.lines.length-1)):(this._activeSelectionMode!==3&&(this._model.selectionEnd[0]=0),this._model.selectionEnd[1]=e.ydisp),this.refresh()}}_handleMouseUp(e){let t=e.timeStamp-this._mouseDownTimeStamp;if(this._removeMouseDownListeners(),this.selectionText.length<=1&&t<Hz&&e.altKey&&this._optionsService.rawOptions.altClickMovesCursor){if(this._bufferService.buffer.ybase===this._bufferService.buffer.ydisp){let i=this._mouseService.getCoords(e,this._element,this._bufferService.cols,this._bufferService.rows,!1);if(i&&i[0]!==void 0&&i[1]!==void 0){let r=Cz(i[0]-1,i[1]-1,this._bufferService,this._coreService.decPrivateModes.applicationCursorKeys);this._coreService.triggerDataEvent(r,!0)}}}else this._fireEventIfSelectionChanged()}_fireEventIfSelectionChanged(){let e=this._model.finalSelectionStart,t=this._model.finalSelectionEnd,i=!!e&&!!t&&(e[0]!==t[0]||e[1]!==t[1]);if(!i){this._oldHasSelection&&this._fireOnSelectionChange(e,t,i);return}!e||!t||(!this._oldSelectionStart||!this._oldSelectionEnd||e[0]!==this._oldSelectionStart[0]||e[1]!==this._oldSelectionStart[1]||t[0]!==this._oldSelectionEnd[0]||t[1]!==this._oldSelectionEnd[1])&&this._fireOnSelectionChange(e,t,i)}_fireOnSelectionChange(e,t,i){this._oldSelectionStart=e,this._oldSelectionEnd=t,this._oldHasSelection=i,this._onSelectionChange.fire()}_handleBufferActivate(e){this.clearSelection(),this._trimListener.dispose(),this._trimListener=e.activeBuffer.lines.onTrim(t=>this._handleTrim(t))}_convertViewportColToCharacterIndex(e,t){let i=t;for(let r=0;t>=r;r++){let s=e.loadCell(r,this._workCell).getChars().length;this._workCell.getWidth()===0?i--:s>1&&t!==r&&(i+=s-1)}return i}setSelection(e,t,i){this._model.clearSelection(),this._removeMouseDownListeners(),this._model.selectionStart=[e,t],this._model.selectionStartLength=i,this.refresh(),this._fireEventIfSelectionChanged()}rightClickSelect(e){this._isClickInSelection(e)||(this._selectWordAtCursor(e,!1)&&this.refresh(!0),this._fireEventIfSelectionChanged())}_getWordAt(e,t,i=!0,r=!0){if(e[0]>=this._bufferService.cols)return;let s=this._bufferService.buffer,n=s.lines.get(e[1]);if(!n)return;let a=s.translateBufferLineToString(e[1],!1),o=this._convertViewportColToCharacterIndex(n,e[0]),l=o,c=e[0]-o,u=0,h=0,d=0,f=0;if(a.charAt(o)===" "){for(;o>0&&a.charAt(o-1)===" ";)o--;for(;l<a.length&&a.charAt(l+1)===" ";)l++}else{let y=e[0],p=e[0];n.getWidth(y)===0&&(u++,y--),n.getWidth(p)===2&&(h++,p++);let C=n.getString(p).length;for(C>1&&(f+=C-1,l+=C-1);y>0&&o>0&&!this._isCharWordSeparator(n.loadCell(y-1,this._workCell));){n.loadCell(y-1,this._workCell);let w=this._workCell.getChars().length;this._workCell.getWidth()===0?(u++,y--):w>1&&(d+=w-1,o-=w-1),o--,y--}for(;p<n.length&&l+1<a.length&&!this._isCharWordSeparator(n.loadCell(p+1,this._workCell));){n.loadCell(p+1,this._workCell);let w=this._workCell.getChars().length;this._workCell.getWidth()===2?(h++,p++):w>1&&(f+=w-1,l+=w-1),l++,p++}}l++;let m=o+c-u+d,_=Math.min(this._bufferService.cols,l-o+u+h-d-f);if(!(!t&&a.slice(o,l).trim()==="")){if(i&&m===0&&n.getCodePoint(0)!==32){let y=s.lines.get(e[1]-1);if(y&&n.isWrapped&&y.getCodePoint(this._bufferService.cols-1)!==32){let p=this._getWordAt([this._bufferService.cols-1,e[1]-1],!1,!0,!1);if(p){let C=this._bufferService.cols-p.start;m-=C,_+=C}}}if(r&&m+_===this._bufferService.cols&&n.getCodePoint(this._bufferService.cols-1)!==32){let y=s.lines.get(e[1]+1);if(y!=null&&y.isWrapped&&y.getCodePoint(0)!==32){let p=this._getWordAt([0,e[1]+1],!1,!1,!0);p&&(_+=p.length)}}return{start:m,length:_}}}_selectWordAt(e,t){let i=this._getWordAt(e,t);if(i){for(;i.start<0;)i.start+=this._bufferService.cols,e[1]--;this._model.selectionStart=[i.start,e[1]],this._model.selectionStartLength=i.length}}_selectToWordAt(e){let t=this._getWordAt(e,!0);if(t){let i=e[1];for(;t.start<0;)t.start+=this._bufferService.cols,i--;if(!this._model.areSelectionValuesReversed())for(;t.start+t.length>this._bufferService.cols;)t.length-=this._bufferService.cols,i++;this._model.selectionEnd=[this._model.areSelectionValuesReversed()?t.start:t.start+t.length,i]}}_isCharWordSeparator(e){return e.getWidth()===0?!1:this._optionsService.rawOptions.wordSeparator.indexOf(e.getChars())>=0}_selectLineAt(e){let t=this._bufferService.buffer.getWrappedRangeForLine(e),i={start:{x:0,y:t.first},end:{x:this._bufferService.cols-1,y:t.last}};this._model.selectionStart=[0,t.first],this._model.selectionEnd=void 0,this._model.selectionStartLength=B8(i,this._bufferService.cols)}};bh=Tt([Te(3,Ai),Te(4,cn),Te(5,Id),Te(6,Mi),Te(7,Qr),Te(8,Jr)],bh);var Z8=class{constructor(){this._data={}}set(e,t,i){this._data[e]||(this._data[e]={}),this._data[e][t]=i}get(e,t){return this._data[e]?this._data[e][t]:void 0}clear(){this._data={}}},F8=class{constructor(){this._color=new Z8,this._css=new Z8}setCss(e,t,i){this._css.set(e,t,i)}getCss(e,t){return this._css.get(e,t)}setColor(e,t,i){this._color.set(e,t,i)}getColor(e,t){return this._color.get(e,t)}clear(){this._color.clear(),this._css.clear()}},Bt=Object.freeze((()=>{let e=[kt.toColor("#2e3436"),kt.toColor("#cc0000"),kt.toColor("#4e9a06"),kt.toColor("#c4a000"),kt.toColor("#3465a4"),kt.toColor("#75507b"),kt.toColor("#06989a"),kt.toColor("#d3d7cf"),kt.toColor("#555753"),kt.toColor("#ef2929"),kt.toColor("#8ae234"),kt.toColor("#fce94f"),kt.toColor("#729fcf"),kt.toColor("#ad7fa8"),kt.toColor("#34e2e2"),kt.toColor("#eeeeec")],t=[0,95,135,175,215,255];for(let i=0;i<216;i++){let r=t[i/36%6|0],s=t[i/6%6|0],n=t[i%6];e.push({css:Rt.toCss(r,s,n),rgba:Rt.toRgba(r,s,n)})}for(let i=0;i<24;i++){let r=8+i*10;e.push({css:Rt.toCss(r,r,r),rgba:Rt.toRgba(r,r,r)})}return e})()),Fs=kt.toColor("#ffffff"),Eo=kt.toColor("#000000"),z8=kt.toColor("#ffffff"),U8=Eo,yo={css:"rgba(255, 255, 255, 0.3)",rgba:4294967117},Iz=Fs,yh=class extends qe{constructor(e){super(),this._optionsService=e,this._contrastCache=new F8,this._halfContrastCache=new F8,this._onChangeColors=this._register(new Ae),this.onChangeColors=this._onChangeColors.event,this._colors={foreground:Fs,background:Eo,cursor:z8,cursorAccent:U8,selectionForeground:void 0,selectionBackgroundTransparent:yo,selectionBackgroundOpaque:vt.blend(Eo,yo),selectionInactiveBackgroundTransparent:yo,selectionInactiveBackgroundOpaque:vt.blend(Eo,yo),scrollbarSliderBackground:vt.opacity(Fs,.2),scrollbarSliderHoverBackground:vt.opacity(Fs,.4),scrollbarSliderActiveBackground:vt.opacity(Fs,.5),overviewRulerBorder:Fs,ansi:Bt.slice(),contrastCache:this._contrastCache,halfContrastCache:this._halfContrastCache},this._updateRestoreColors(),this._setTheme(this._optionsService.rawOptions.theme),this._register(this._optionsService.onSpecificOptionChange("minimumContrastRatio",()=>this._contrastCache.clear())),this._register(this._optionsService.onSpecificOptionChange("theme",()=>this._setTheme(this._optionsService.rawOptions.theme)))}get colors(){return this._colors}_setTheme(e={}){let t=this._colors;if(t.foreground=dt(e.foreground,Fs),t.background=dt(e.background,Eo),t.cursor=vt.blend(t.background,dt(e.cursor,z8)),t.cursorAccent=vt.blend(t.background,dt(e.cursorAccent,U8)),t.selectionBackgroundTransparent=dt(e.selectionBackground,yo),t.selectionBackgroundOpaque=vt.blend(t.background,t.selectionBackgroundTransparent),t.selectionInactiveBackgroundTransparent=dt(e.selectionInactiveBackground,t.selectionBackgroundTransparent),t.selectionInactiveBackgroundOpaque=vt.blend(t.background,t.selectionInactiveBackgroundTransparent),t.selectionForeground=e.selectionForeground?dt(e.selectionForeground,R8):void 0,t.selectionForeground===R8&&(t.selectionForeground=void 0),vt.isOpaque(t.selectionBackgroundTransparent)&&(t.selectionBackgroundTransparent=vt.opacity(t.selectionBackgroundTransparent,.3)),vt.isOpaque(t.selectionInactiveBackgroundTransparent)&&(t.selectionInactiveBackgroundTransparent=vt.opacity(t.selectionInactiveBackgroundTransparent,.3)),t.scrollbarSliderBackground=dt(e.scrollbarSliderBackground,vt.opacity(t.foreground,.2)),t.scrollbarSliderHoverBackground=dt(e.scrollbarSliderHoverBackground,vt.opacity(t.foreground,.4)),t.scrollbarSliderActiveBackground=dt(e.scrollbarSliderActiveBackground,vt.opacity(t.foreground,.5)),t.overviewRulerBorder=dt(e.overviewRulerBorder,Iz),t.ansi=Bt.slice(),t.ansi[0]=dt(e.black,Bt[0]),t.ansi[1]=dt(e.red,Bt[1]),t.ansi[2]=dt(e.green,Bt[2]),t.ansi[3]=dt(e.yellow,Bt[3]),t.ansi[4]=dt(e.blue,Bt[4]),t.ansi[5]=dt(e.magenta,Bt[5]),t.ansi[6]=dt(e.cyan,Bt[6]),t.ansi[7]=dt(e.white,Bt[7]),t.ansi[8]=dt(e.brightBlack,Bt[8]),t.ansi[9]=dt(e.brightRed,Bt[9]),t.ansi[10]=dt(e.brightGreen,Bt[10]),t.ansi[11]=dt(e.brightYellow,Bt[11]),t.ansi[12]=dt(e.brightBlue,Bt[12]),t.ansi[13]=dt(e.brightMagenta,Bt[13]),t.ansi[14]=dt(e.brightCyan,Bt[14]),t.ansi[15]=dt(e.brightWhite,Bt[15]),e.extendedAnsi){let i=Math.min(t.ansi.length-16,e.extendedAnsi.length);for(let r=0;r<i;r++)t.ansi[r+16]=dt(e.extendedAnsi[r],Bt[r+16])}this._contrastCache.clear(),this._halfContrastCache.clear(),this._updateRestoreColors(),this._onChangeColors.fire(this.colors)}restoreColor(e){this._restoreColor(e),this._onChangeColors.fire(this.colors)}_restoreColor(e){if(e===void 0){for(let t=0;t<this._restoreColors.ansi.length;++t)this._colors.ansi[t]=this._restoreColors.ansi[t];return}switch(e){case 256:this._colors.foreground=this._restoreColors.foreground;break;case 257:this._colors.background=this._restoreColors.background;break;case 258:this._colors.cursor=this._restoreColors.cursor;break;default:this._colors.ansi[e]=this._restoreColors.ansi[e]}}modifyColors(e){e(this._colors),this._onChangeColors.fire(this.colors)}_updateRestoreColors(){this._restoreColors={foreground:this._colors.foreground,background:this._colors.background,cursor:this._colors.cursor,ansi:this._colors.ansi.slice()}}};yh=Tt([Te(0,Mi)],yh);function dt(e,t){if(e!==void 0)try{return kt.toColor(e)}catch{}return t}var Rz=class{constructor(...e){this._entries=new Map;for(let[t,i]of e)this.set(t,i)}set(e,t){let i=this._entries.get(e);return this._entries.set(e,t),i}forEach(e){for(let[t,i]of this._entries.entries())e(t,i)}has(e){return this._entries.has(e)}get(e){return this._entries.get(e)}},Dz=class{constructor(){this._services=new Rz,this._services.set(Od,this)}setService(e,t){this._services.set(e,t)}getService(e){return this._services.get(e)}createInstance(e,...t){let i=TZ(e).sort((n,a)=>n.index-a.index),r=[];for(let n of i){let a=this._services.get(n.id);if(!a)throw new Error(`[createInstance] ${e.name} depends on UNKNOWN service ${n.id._id}.`);r.push(a)}let s=i.length>0?i[0].index:t.length;if(t.length!==s)throw new Error(`[createInstance] First service dependency of ${e.name} at position ${s+1} conflicts with ${t.length} static arguments`);return new e(...t,...r)}},Vz={trace:0,debug:1,info:2,warn:3,error:4,off:5},Bz="xterm.js: ",wh=class extends qe{constructor(e){super(),this._optionsService=e,this._logLevel=5,this._updateLogLevel(),this._register(this._optionsService.onSpecificOptionChange("logLevel",()=>this._updateLogLevel()))}get logLevel(){return this._logLevel}_updateLogLevel(){this._logLevel=Vz[this._optionsService.rawOptions.logLevel]}_evalLazyOptionalParams(e){for(let t=0;t<e.length;t++)typeof e[t]=="function"&&(e[t]=e[t]())}_log(e,t,i){this._evalLazyOptionalParams(i),e.call(console,(this._optionsService.options.logger?"":Bz)+t,...i)}trace(e,...t){var i;this._logLevel<=0&&this._log(((i=this._optionsService.options.logger)==null?void 0:i.trace.bind(this._optionsService.options.logger))??console.log,e,t)}debug(e,...t){var i;this._logLevel<=1&&this._log(((i=this._optionsService.options.logger)==null?void 0:i.debug.bind(this._optionsService.options.logger))??console.log,e,t)}info(e,...t){var i;this._logLevel<=2&&this._log(((i=this._optionsService.options.logger)==null?void 0:i.info.bind(this._optionsService.options.logger))??console.info,e,t)}warn(e,...t){var i;this._logLevel<=3&&this._log(((i=this._optionsService.options.logger)==null?void 0:i.warn.bind(this._optionsService.options.logger))??console.warn,e,t)}error(e,...t){var i;this._logLevel<=4&&this._log(((i=this._optionsService.options.logger)==null?void 0:i.error.bind(this._optionsService.options.logger))??console.error,e,t)}};wh=Tt([Te(0,Mi)],wh);var W8=class extends qe{constructor(e){super(),this._maxLength=e,this.onDeleteEmitter=this._register(new Ae),this.onDelete=this.onDeleteEmitter.event,this.onInsertEmitter=this._register(new Ae),this.onInsert=this.onInsertEmitter.event,this.onTrimEmitter=this._register(new Ae),this.onTrim=this.onTrimEmitter.event,this._array=new Array(this._maxLength),this._startIndex=0,this._length=0}get maxLength(){return this._maxLength}set maxLength(e){if(this._maxLength===e)return;let t=new Array(e);for(let i=0;i<Math.min(e,this.length);i++)t[i]=this._array[this._getCyclicIndex(i)];this._array=t,this._maxLength=e,this._startIndex=0}get length(){return this._length}set length(e){if(e>this._length)for(let t=this._length;t<e;t++)this._array[t]=void 0;this._length=e}get(e){return this._array[this._getCyclicIndex(e)]}set(e,t){this._array[this._getCyclicIndex(e)]=t}push(e){this._array[this._getCyclicIndex(this._length)]=e,this._length===this._maxLength?(this._startIndex=++this._startIndex%this._maxLength,this.onTrimEmitter.fire(1)):this._length++}recycle(){if(this._length!==this._maxLength)throw new Error("Can only recycle when the buffer is full");return this._startIndex=++this._startIndex%this._maxLength,this.onTrimEmitter.fire(1),this._array[this._getCyclicIndex(this._length-1)]}get isFull(){return this._length===this._maxLength}pop(){return this._array[this._getCyclicIndex(this._length---1)]}splice(e,t,...i){if(t){for(let r=e;r<this._length-t;r++)this._array[this._getCyclicIndex(r)]=this._array[this._getCyclicIndex(r+t)];this._length-=t,this.onDeleteEmitter.fire({index:e,amount:t})}for(let r=this._length-1;r>=e;r--)this._array[this._getCyclicIndex(r+i.length)]=this._array[this._getCyclicIndex(r)];for(let r=0;r<i.length;r++)this._array[this._getCyclicIndex(e+r)]=i[r];if(i.length&&this.onInsertEmitter.fire({index:e,amount:i.length}),this._length+i.length>this._maxLength){let r=this._length+i.length-this._maxLength;this._startIndex+=r,this._length=this._maxLength,this.onTrimEmitter.fire(r)}else this._length+=i.length}trimStart(e){e>this._length&&(e=this._length),this._startIndex+=e,this._length-=e,this.onTrimEmitter.fire(e)}shiftElements(e,t,i){if(!(t<=0)){if(e<0||e>=this._length)throw new Error("start argument out of range");if(e+i<0)throw new Error("Cannot shift elements in list beyond index 0");if(i>0){for(let s=t-1;s>=0;s--)this.set(e+s+i,this.get(e+s));let r=e+t+i-this._length;if(r>0)for(this._length+=r;this._length>this._maxLength;)this._length--,this._startIndex++,this.onTrimEmitter.fire(1)}else for(let r=0;r<t;r++)this.set(e+r+i,this.get(e+r))}}_getCyclicIndex(e){return(this._startIndex+e)%this._maxLength}},Ke=3,It=Object.freeze(new Ll),t0=0,x1=2,$o=class Ov{constructor(t,i,r=!1){this.isWrapped=r,this._combined={},this._extendedAttrs={},this._data=new Uint32Array(t*Ke);let s=i||Ki.fromCharData([0,ev,1,0]);for(let n=0;n<t;++n)this.setCell(n,s);this.length=t}get(t){let i=this._data[t*Ke+0],r=i&2097151;return[this._data[t*Ke+1],i&2097152?this._combined[t]:r?us(r):"",i>>22,i&2097152?this._combined[t].charCodeAt(this._combined[t].length-1):r]}set(t,i){this._data[t*Ke+1]=i[0],i[1].length>1?(this._combined[t]=i[1],this._data[t*Ke+0]=t|2097152|i[2]<<22):this._data[t*Ke+0]=i[1].charCodeAt(0)|i[2]<<22}getWidth(t){return this._data[t*Ke+0]>>22}hasWidth(t){return this._data[t*Ke+0]&12582912}getFg(t){return this._data[t*Ke+1]}getBg(t){return this._data[t*Ke+2]}hasContent(t){return this._data[t*Ke+0]&4194303}getCodePoint(t){let i=this._data[t*Ke+0];return i&2097152?this._combined[t].charCodeAt(this._combined[t].length-1):i&2097151}isCombined(t){return this._data[t*Ke+0]&2097152}getString(t){let i=this._data[t*Ke+0];return i&2097152?this._combined[t]:i&2097151?us(i&2097151):""}isProtected(t){return this._data[t*Ke+2]&536870912}loadCell(t,i){return t0=t*Ke,i.content=this._data[t0+0],i.fg=this._data[t0+1],i.bg=this._data[t0+2],i.content&2097152&&(i.combinedData=this._combined[t]),i.bg&268435456&&(i.extended=this._extendedAttrs[t]),i}setCell(t,i){i.content&2097152&&(this._combined[t]=i.combinedData),i.bg&268435456&&(this._extendedAttrs[t]=i.extended),this._data[t*Ke+0]=i.content,this._data[t*Ke+1]=i.fg,this._data[t*Ke+2]=i.bg}setCellFromCodepoint(t,i,r,s){s.bg&268435456&&(this._extendedAttrs[t]=s.extended),this._data[t*Ke+0]=i|r<<22,this._data[t*Ke+1]=s.fg,this._data[t*Ke+2]=s.bg}addCodepointToCell(t,i,r){let s=this._data[t*Ke+0];s&2097152?this._combined[t]+=us(i):s&2097151?(this._combined[t]=us(s&2097151)+us(i),s&=-2097152,s|=2097152):s=i|1<<22,r&&(s&=-12582913,s|=r<<22),this._data[t*Ke+0]=s}insertCells(t,i,r){if(t%=this.length,t&&this.getWidth(t-1)===2&&this.setCellFromCodepoint(t-1,0,1,r),i<this.length-t){let s=new Ki;for(let n=this.length-t-i-1;n>=0;--n)this.setCell(t+i+n,this.loadCell(t+n,s));for(let n=0;n<i;++n)this.setCell(t+n,r)}else for(let s=t;s<this.length;++s)this.setCell(s,r);this.getWidth(this.length-1)===2&&this.setCellFromCodepoint(this.length-1,0,1,r)}deleteCells(t,i,r){if(t%=this.length,i<this.length-t){let s=new Ki;for(let n=0;n<this.length-t-i;++n)this.setCell(t+n,this.loadCell(t+i+n,s));for(let n=this.length-i;n<this.length;++n)this.setCell(n,r)}else for(let s=t;s<this.length;++s)this.setCell(s,r);t&&this.getWidth(t-1)===2&&this.setCellFromCodepoint(t-1,0,1,r),this.getWidth(t)===0&&!this.hasContent(t)&&this.setCellFromCodepoint(t,0,1,r)}replaceCells(t,i,r,s=!1){if(s){for(t&&this.getWidth(t-1)===2&&!this.isProtected(t-1)&&this.setCellFromCodepoint(t-1,0,1,r),i<this.length&&this.getWidth(i-1)===2&&!this.isProtected(i)&&this.setCellFromCodepoint(i,0,1,r);t<i&&t<this.length;)this.isProtected(t)||this.setCell(t,r),t++;return}for(t&&this.getWidth(t-1)===2&&this.setCellFromCodepoint(t-1,0,1,r),i<this.length&&this.getWidth(i-1)===2&&this.setCellFromCodepoint(i,0,1,r);t<i&&t<this.length;)this.setCell(t++,r)}resize(t,i){if(t===this.length)return this._data.length*4*x1<this._data.buffer.byteLength;let r=t*Ke;if(t>this.length){if(this._data.buffer.byteLength>=r*4)this._data=new Uint32Array(this._data.buffer,0,r);else{let s=new Uint32Array(r);s.set(this._data),this._data=s}for(let s=this.length;s<t;++s)this.setCell(s,i)}else{this._data=this._data.subarray(0,r);let s=Object.keys(this._combined);for(let a=0;a<s.length;a++){let o=parseInt(s[a],10);o>=t&&delete this._combined[o]}let n=Object.keys(this._extendedAttrs);for(let a=0;a<n.length;a++){let o=parseInt(n[a],10);o>=t&&delete this._extendedAttrs[o]}}return this.length=t,r*4*x1<this._data.buffer.byteLength}cleanupMemory(){if(this._data.length*4*x1<this._data.buffer.byteLength){let t=new Uint32Array(this._data.length);return t.set(this._data),this._data=t,1}return 0}fill(t,i=!1){if(i){for(let r=0;r<this.length;++r)this.isProtected(r)||this.setCell(r,t);return}this._combined={},this._extendedAttrs={};for(let r=0;r<this.length;++r)this.setCell(r,t)}copyFrom(t){this.length!==t.length?this._data=new Uint32Array(t._data):this._data.set(t._data),this.length=t.length,this._combined={};for(let i in t._combined)this._combined[i]=t._combined[i];this._extendedAttrs={};for(let i in t._extendedAttrs)this._extendedAttrs[i]=t._extendedAttrs[i];this.isWrapped=t.isWrapped}clone(){let t=new Ov(0);t._data=new Uint32Array(this._data),t.length=this.length;for(let i in this._combined)t._combined[i]=this._combined[i];for(let i in this._extendedAttrs)t._extendedAttrs[i]=this._extendedAttrs[i];return t.isWrapped=this.isWrapped,t}getTrimmedLength(){for(let t=this.length-1;t>=0;--t)if(this._data[t*Ke+0]&4194303)return t+(this._data[t*Ke+0]>>22);return 0}getNoBgTrimmedLength(){for(let t=this.length-1;t>=0;--t)if(this._data[t*Ke+0]&4194303||this._data[t*Ke+2]&50331648)return t+(this._data[t*Ke+0]>>22);return 0}copyCellsFrom(t,i,r,s,n){let a=t._data;if(n)for(let l=s-1;l>=0;l--){for(let c=0;c<Ke;c++)this._data[(r+l)*Ke+c]=a[(i+l)*Ke+c];a[(i+l)*Ke+2]&268435456&&(this._extendedAttrs[r+l]=t._extendedAttrs[i+l])}else for(let l=0;l<s;l++){for(let c=0;c<Ke;c++)this._data[(r+l)*Ke+c]=a[(i+l)*Ke+c];a[(i+l)*Ke+2]&268435456&&(this._extendedAttrs[r+l]=t._extendedAttrs[i+l])}let o=Object.keys(t._combined);for(let l=0;l<o.length;l++){let c=parseInt(o[l],10);c>=i&&(this._combined[c-i+r]=t._combined[c])}}translateToString(t,i,r,s){i=i??0,r=r??this.length,t&&(r=Math.min(r,this.getTrimmedLength())),s&&(s.length=0);let n="";for(;i<r;){let a=this._data[i*Ke+0],o=a&2097151,l=a&2097152?this._combined[i]:o?us(o):fs;if(n+=l,s)for(let c=0;c<l.length;++c)s.push(i);i+=a>>22||1}return s&&s.push(i),n}};function Zz(e,t,i,r,s,n){let a=[];for(let o=0;o<e.length-1;o++){let l=o,c=e.get(++l);if(!c.isWrapped)continue;let u=[e.get(o)];for(;l<e.length&&c.isWrapped;)u.push(c),c=e.get(++l);if(!n&&r>=o&&r<l){o+=u.length-1;continue}let h=0,d=_l(u,h,t),f=1,m=0;for(;f<u.length;){let y=_l(u,f,t),p=y-m,C=i-d,w=Math.min(p,C);u[h].copyCellsFrom(u[f],m,d,w,!1),d+=w,d===i&&(h++,d=0),m+=w,m===y&&(f++,m=0),d===0&&h!==0&&u[h-1].getWidth(i-1)===2&&(u[h].copyCellsFrom(u[h-1],i-1,d++,1,!1),u[h-1].setCell(i-1,s))}u[h].replaceCells(d,i,s);let _=0;for(let y=u.length-1;y>0&&(y>h||u[y].getTrimmedLength()===0);y--)_++;_>0&&(a.push(o+u.length-_),a.push(_)),o+=u.length-1}return a}function Fz(e,t){let i=[],r=0,s=t[r],n=0;for(let a=0;a<e.length;a++)if(s===a){let o=t[++r];e.onDeleteEmitter.fire({index:a-n,amount:o}),a+=o-1,n+=o,s=t[++r]}else i.push(a);return{layout:i,countRemoved:n}}function zz(e,t){let i=[];for(let r=0;r<t.length;r++)i.push(e.get(t[r]));for(let r=0;r<i.length;r++)e.set(r,i[r]);e.length=t.length}function Uz(e,t,i){let r=[],s=e.map((l,c)=>_l(e,c,t)).reduce((l,c)=>l+c),n=0,a=0,o=0;for(;o<s;){if(s-o<i){r.push(s-o);break}n+=i;let l=_l(e,a,t);n>l&&(n-=l,a++);let c=e[a].getWidth(n-1)===2;c&&n--;let u=c?i-1:i;r.push(u),o+=u}return r}function _l(e,t,i){if(t===e.length-1)return e[t].getTrimmedLength();let r=!e[t].hasContent(i-1)&&e[t].getWidth(i-1)===1,s=e[t+1].getWidth(0)===2;return r&&s?i-1:i}var Iv=class Rv{constructor(t){this.line=t,this.isDisposed=!1,this._disposables=[],this._id=Rv._nextId++,this._onDispose=this.register(new Ae),this.onDispose=this._onDispose.event}get id(){return this._id}dispose(){this.isDisposed||(this.isDisposed=!0,this.line=-1,this._onDispose.fire(),sn(this._disposables),this._disposables.length=0)}register(t){return this._disposables.push(t),t}};Iv._nextId=1;var Wz=Iv,Wt={},zs=Wt.B;Wt[0]={"`":"◆",a:"▒",b:"␉",c:"␌",d:"␍",e:"␊",f:"°",g:"±",h:"",i:"␋",j:"┘",k:"┐",l:"┌",m:"└",n:"┼",o:"⎺",p:"⎻",q:"─",r:"⎼",s:"⎽",t:"├",u:"┤",v:"┴",w:"┬",x:"│",y:"≤",z:"≥","{":"π","|":"≠","}":"£","~":"·"};Wt.A={"#":"£"};Wt.B=void 0;Wt[4]={"#":"£","@":"¾","[":"ij","\\":"½","]":"|","{":"¨","|":"f","}":"¼","~":"´"};Wt.C=Wt[5]={"[":"Ä","\\":"Ö","]":"Å","^":"Ü","`":"é","{":"ä","|":"ö","}":"å","~":"ü"};Wt.R={"#":"£","@":"à","[":"°","\\":"ç","]":"§","{":"é","|":"ù","}":"è","~":"¨"};Wt.Q={"@":"à","[":"â","\\":"ç","]":"ê","^":"î","`":"ô","{":"é","|":"ù","}":"è","~":"û"};Wt.K={"@":"§","[":"Ä","\\":"Ö","]":"Ü","{":"ä","|":"ö","}":"ü","~":"ß"};Wt.Y={"#":"£","@":"§","[":"°","\\":"ç","]":"é","`":"ù","{":"à","|":"ò","}":"è","~":"ì"};Wt.E=Wt[6]={"@":"Ä","[":"Æ","\\":"Ø","]":"Å","^":"Ü","`":"ä","{":"æ","|":"ø","}":"å","~":"ü"};Wt.Z={"#":"£","@":"§","[":"¡","\\":"Ñ","]":"¿","{":"°","|":"ñ","}":"ç"};Wt.H=Wt[7]={"@":"É","[":"Ä","\\":"Ö","]":"Å","^":"Ü","`":"é","{":"ä","|":"ö","}":"å","~":"ü"};Wt["="]={"#":"ù","@":"à","[":"é","\\":"ç","]":"ê","^":"î",_:"è","`":"ô","{":"ä","|":"ö","}":"ü","~":"û"};var j8=4294967295,K8=class{constructor(e,t,i){this._hasScrollback=e,this._optionsService=t,this._bufferService=i,this.ydisp=0,this.ybase=0,this.y=0,this.x=0,this.tabs={},this.savedY=0,this.savedX=0,this.savedCurAttrData=It.clone(),this.savedCharset=zs,this.markers=[],this._nullCell=Ki.fromCharData([0,ev,1,0]),this._whitespaceCell=Ki.fromCharData([0,fs,1,32]),this._isClearing=!1,this._memoryCleanupQueue=new X0,this._memoryCleanupPosition=0,this._cols=this._bufferService.cols,this._rows=this._bufferService.rows,this.lines=new W8(this._getCorrectBufferLength(this._rows)),this.scrollTop=0,this.scrollBottom=this._rows-1,this.setupTabStops()}getNullCell(e){return e?(this._nullCell.fg=e.fg,this._nullCell.bg=e.bg,this._nullCell.extended=e.extended):(this._nullCell.fg=0,this._nullCell.bg=0,this._nullCell.extended=new K0),this._nullCell}getWhitespaceCell(e){return e?(this._whitespaceCell.fg=e.fg,this._whitespaceCell.bg=e.bg,this._whitespaceCell.extended=e.extended):(this._whitespaceCell.fg=0,this._whitespaceCell.bg=0,this._whitespaceCell.extended=new K0),this._whitespaceCell}getBlankLine(e,t){return new $o(this._bufferService.cols,this.getNullCell(e),t)}get hasScrollback(){return this._hasScrollback&&this.lines.maxLength>this._rows}get isCursorInViewport(){let e=this.ybase+this.y-this.ydisp;return e>=0&&e<this._rows}_getCorrectBufferLength(e){if(!this._hasScrollback)return e;let t=e+this._optionsService.rawOptions.scrollback;return t>j8?j8:t}fillViewportRows(e){if(this.lines.length===0){e===void 0&&(e=It);let t=this._rows;for(;t--;)this.lines.push(this.getBlankLine(e))}}clear(){this.ydisp=0,this.ybase=0,this.y=0,this.x=0,this.lines=new W8(this._getCorrectBufferLength(this._rows)),this.scrollTop=0,this.scrollBottom=this._rows-1,this.setupTabStops()}resize(e,t){let i=this.getNullCell(It),r=0,s=this._getCorrectBufferLength(t);if(s>this.lines.maxLength&&(this.lines.maxLength=s),this.lines.length>0){if(this._cols<e)for(let a=0;a<this.lines.length;a++)r+=+this.lines.get(a).resize(e,i);let n=0;if(this._rows<t)for(let a=this._rows;a<t;a++)this.lines.length<t+this.ybase&&(this._optionsService.rawOptions.windowsMode||this._optionsService.rawOptions.windowsPty.backend!==void 0||this._optionsService.rawOptions.windowsPty.buildNumber!==void 0?this.lines.push(new $o(e,i)):this.ybase>0&&this.lines.length<=this.ybase+this.y+n+1?(this.ybase--,n++,this.ydisp>0&&this.ydisp--):this.lines.push(new $o(e,i)));else for(let a=this._rows;a>t;a--)this.lines.length>t+this.ybase&&(this.lines.length>this.ybase+this.y+1?this.lines.pop():(this.ybase++,this.ydisp++));if(s<this.lines.maxLength){let a=this.lines.length-s;a>0&&(this.lines.trimStart(a),this.ybase=Math.max(this.ybase-a,0),this.ydisp=Math.max(this.ydisp-a,0),this.savedY=Math.max(this.savedY-a,0)),this.lines.maxLength=s}this.x=Math.min(this.x,e-1),this.y=Math.min(this.y,t-1),n&&(this.y+=n),this.savedX=Math.min(this.savedX,e-1),this.scrollTop=0}if(this.scrollBottom=t-1,this._isReflowEnabled&&(this._reflow(e,t),this._cols>e))for(let n=0;n<this.lines.length;n++)r+=+this.lines.get(n).resize(e,i);this._cols=e,this._rows=t,this._memoryCleanupQueue.clear(),r>.1*this.lines.length&&(this._memoryCleanupPosition=0,this._memoryCleanupQueue.enqueue(()=>this._batchedMemoryCleanup()))}_batchedMemoryCleanup(){let e=!0;this._memoryCleanupPosition>=this.lines.length&&(this._memoryCleanupPosition=0,e=!1);let t=0;for(;this._memoryCleanupPosition<this.lines.length;)if(t+=this.lines.get(this._memoryCleanupPosition++).cleanupMemory(),t>100)return!0;return e}get _isReflowEnabled(){let e=this._optionsService.rawOptions.windowsPty;return e&&e.buildNumber?this._hasScrollback&&e.backend==="conpty"&&e.buildNumber>=21376:this._hasScrollback&&!this._optionsService.rawOptions.windowsMode}_reflow(e,t){this._cols!==e&&(e>this._cols?this._reflowLarger(e,t):this._reflowSmaller(e,t))}_reflowLarger(e,t){let i=this._optionsService.rawOptions.reflowCursorLine,r=Zz(this.lines,this._cols,e,this.ybase+this.y,this.getNullCell(It),i);if(r.length>0){let s=Fz(this.lines,r);zz(this.lines,s.layout),this._reflowLargerAdjustViewport(e,t,s.countRemoved)}}_reflowLargerAdjustViewport(e,t,i){let r=this.getNullCell(It),s=i;for(;s-- >0;)this.ybase===0?(this.y>0&&this.y--,this.lines.length<t&&this.lines.push(new $o(e,r))):(this.ydisp===this.ybase&&this.ydisp--,this.ybase--);this.savedY=Math.max(this.savedY-i,0)}_reflowSmaller(e,t){let i=this._optionsService.rawOptions.reflowCursorLine,r=this.getNullCell(It),s=[],n=0;for(let a=this.lines.length-1;a>=0;a--){let o=this.lines.get(a);if(!o||!o.isWrapped&&o.getTrimmedLength()<=e)continue;let l=[o];for(;o.isWrapped&&a>0;)o=this.lines.get(--a),l.unshift(o);if(!i){let w=this.ybase+this.y;if(w>=a&&w<a+l.length)continue}let c=l[l.length-1].getTrimmedLength(),u=Uz(l,this._cols,e),h=u.length-l.length,d;this.ybase===0&&this.y!==this.lines.length-1?d=Math.max(0,this.y-this.lines.maxLength+h):d=Math.max(0,this.lines.length-this.lines.maxLength+h);let f=[];for(let w=0;w<h;w++){let v=this.getBlankLine(It,!0);f.push(v)}f.length>0&&(s.push({start:a+l.length+n,newLines:f}),n+=f.length),l.push(...f);let m=u.length-1,_=u[m];_===0&&(m--,_=u[m]);let y=l.length-h-1,p=c;for(;y>=0;){let w=Math.min(p,_);if(l[m]===void 0)break;if(l[m].copyCellsFrom(l[y],p-w,_-w,w,!0),_-=w,_===0&&(m--,_=u[m]),p-=w,p===0){y--;let v=Math.max(y,0);p=_l(l,v,this._cols)}}for(let w=0;w<l.length;w++)u[w]<e&&l[w].setCell(u[w],r);let C=h-d;for(;C-- >0;)this.ybase===0?this.y<t-1?(this.y++,this.lines.pop()):(this.ybase++,this.ydisp++):this.ybase<Math.min(this.lines.maxLength,this.lines.length+n)-t&&(this.ybase===this.ydisp&&this.ydisp++,this.ybase++);this.savedY=Math.min(this.savedY+h,this.ybase+t-1)}if(s.length>0){let a=[],o=[];for(let _=0;_<this.lines.length;_++)o.push(this.lines.get(_));let l=this.lines.length,c=l-1,u=0,h=s[u];this.lines.length=Math.min(this.lines.maxLength,this.lines.length+n);let d=0;for(let _=Math.min(this.lines.maxLength-1,l+n-1);_>=0;_--)if(h&&h.start>c+d){for(let y=h.newLines.length-1;y>=0;y--)this.lines.set(_--,h.newLines[y]);_++,a.push({index:c+1,amount:h.newLines.length}),d+=h.newLines.length,h=s[++u]}else this.lines.set(_,o[c--]);let f=0;for(let _=a.length-1;_>=0;_--)a[_].index+=f,this.lines.onInsertEmitter.fire(a[_]),f+=a[_].amount;let m=Math.max(0,l+n-this.lines.maxLength);m>0&&this.lines.onTrimEmitter.fire(m)}}translateBufferLineToString(e,t,i=0,r){let s=this.lines.get(e);return s?s.translateToString(t,i,r):""}getWrappedRangeForLine(e){let t=e,i=e;for(;t>0&&this.lines.get(t).isWrapped;)t--;for(;i+1<this.lines.length&&this.lines.get(i+1).isWrapped;)i++;return{first:t,last:i}}setupTabStops(e){for(e!=null?this.tabs[e]||(e=this.prevStop(e)):(this.tabs={},e=0);e<this._cols;e+=this._optionsService.rawOptions.tabStopWidth)this.tabs[e]=!0}prevStop(e){for(e==null&&(e=this.x);!this.tabs[--e]&&e>0;);return e>=this._cols?this._cols-1:e<0?0:e}nextStop(e){for(e==null&&(e=this.x);!this.tabs[++e]&&e<this._cols;);return e>=this._cols?this._cols-1:e<0?0:e}clearMarkers(e){this._isClearing=!0;for(let t=0;t<this.markers.length;t++)this.markers[t].line===e&&(this.markers[t].dispose(),this.markers.splice(t--,1));this._isClearing=!1}clearAllMarkers(){this._isClearing=!0;for(let e=0;e<this.markers.length;e++)this.markers[e].dispose();this.markers.length=0,this._isClearing=!1}addMarker(e){let t=new Wz(e);return this.markers.push(t),t.register(this.lines.onTrim(i=>{t.line-=i,t.line<0&&t.dispose()})),t.register(this.lines.onInsert(i=>{t.line>=i.index&&(t.line+=i.amount)})),t.register(this.lines.onDelete(i=>{t.line>=i.index&&t.line<i.index+i.amount&&t.dispose(),t.line>i.index&&(t.line-=i.amount)})),t.register(t.onDispose(()=>this._removeMarker(t))),t}_removeMarker(e){this._isClearing||this.markers.splice(this.markers.indexOf(e),1)}},jz=class extends qe{constructor(e,t){super(),this._optionsService=e,this._bufferService=t,this._onBufferActivate=this._register(new Ae),this.onBufferActivate=this._onBufferActivate.event,this.reset(),this._register(this._optionsService.onSpecificOptionChange("scrollback",()=>this.resize(this._bufferService.cols,this._bufferService.rows))),this._register(this._optionsService.onSpecificOptionChange("tabStopWidth",()=>this.setupTabStops()))}reset(){this._normal=new K8(!0,this._optionsService,this._bufferService),this._normal.fillViewportRows(),this._alt=new K8(!1,this._optionsService,this._bufferService),this._activeBuffer=this._normal,this._onBufferActivate.fire({activeBuffer:this._normal,inactiveBuffer:this._alt}),this.setupTabStops()}get alt(){return this._alt}get active(){return this._activeBuffer}get normal(){return this._normal}activateNormalBuffer(){this._activeBuffer!==this._normal&&(this._normal.x=this._alt.x,this._normal.y=this._alt.y,this._alt.clearAllMarkers(),this._alt.clear(),this._activeBuffer=this._normal,this._onBufferActivate.fire({activeBuffer:this._normal,inactiveBuffer:this._alt}))}activateAltBuffer(e){this._activeBuffer!==this._alt&&(this._alt.fillViewportRows(e),this._alt.x=this._normal.x,this._alt.y=this._normal.y,this._activeBuffer=this._alt,this._onBufferActivate.fire({activeBuffer:this._alt,inactiveBuffer:this._normal}))}resize(e,t){this._normal.resize(e,t),this._alt.resize(e,t),this.setupTabStops(e)}setupTabStops(e){this._normal.setupTabStops(e),this._alt.setupTabStops(e)}},Dv=2,Vv=1,Sh=class extends qe{constructor(e){super(),this.isUserScrolling=!1,this._onResize=this._register(new Ae),this.onResize=this._onResize.event,this._onScroll=this._register(new Ae),this.onScroll=this._onScroll.event,this.cols=Math.max(e.rawOptions.cols||0,Dv),this.rows=Math.max(e.rawOptions.rows||0,Vv),this.buffers=this._register(new jz(e,this)),this._register(this.buffers.onBufferActivate(t=>{this._onScroll.fire(t.activeBuffer.ydisp)}))}get buffer(){return this.buffers.active}resize(e,t){let i=this.cols!==e,r=this.rows!==t;this.cols=e,this.rows=t,this.buffers.resize(e,t),this._onResize.fire({cols:e,rows:t,colsChanged:i,rowsChanged:r})}reset(){this.buffers.reset(),this.isUserScrolling=!1}scroll(e,t=!1){let i=this.buffer,r;r=this._cachedBlankLine,(!r||r.length!==this.cols||r.getFg(0)!==e.fg||r.getBg(0)!==e.bg)&&(r=i.getBlankLine(e,t),this._cachedBlankLine=r),r.isWrapped=t;let s=i.ybase+i.scrollTop,n=i.ybase+i.scrollBottom;if(i.scrollTop===0){let a=i.lines.isFull;n===i.lines.length-1?a?i.lines.recycle().copyFrom(r):i.lines.push(r.clone()):i.lines.splice(n+1,0,r.clone()),a?this.isUserScrolling&&(i.ydisp=Math.max(i.ydisp-1,0)):(i.ybase++,this.isUserScrolling||i.ydisp++)}else{let a=n-s+1;i.lines.shiftElements(s+1,a-1,-1),i.lines.set(n,r.clone())}this.isUserScrolling||(i.ydisp=i.ybase),this._onScroll.fire(i.ydisp)}scrollLines(e,t){let i=this.buffer;if(e<0){if(i.ydisp===0)return;this.isUserScrolling=!0}else e+i.ydisp>=i.ybase&&(this.isUserScrolling=!1);let r=i.ydisp;i.ydisp=Math.max(Math.min(i.ydisp+e,i.ybase),0),r!==i.ydisp&&(t||this._onScroll.fire(i.ydisp))}};Sh=Tt([Te(0,Mi)],Sh);var gn={cols:80,rows:24,cursorBlink:!1,cursorStyle:"block",cursorWidth:1,cursorInactiveStyle:"outline",customGlyphs:!0,drawBoldTextInBrightColors:!0,documentOverride:null,fastScrollModifier:"alt",fastScrollSensitivity:5,fontFamily:"monospace",fontSize:15,fontWeight:"normal",fontWeightBold:"bold",ignoreBracketedPasteMode:!1,lineHeight:1,letterSpacing:0,linkHandler:null,logLevel:"info",logger:null,scrollback:1e3,scrollOnEraseInDisplay:!1,scrollOnUserInput:!0,scrollSensitivity:1,screenReaderMode:!1,smoothScrollDuration:0,macOptionIsMeta:!1,macOptionClickForcesSelection:!1,minimumContrastRatio:1,disableStdin:!1,allowProposedApi:!1,allowTransparency:!1,tabStopWidth:8,theme:{},reflowCursorLine:!1,rescaleOverlappingGlyphs:!1,rightClickSelectsWord:Y0,windowOptions:{},windowsMode:!1,windowsPty:{},wordSeparator:" ()[]{}',\"`",altClickMovesCursor:!0,convertEol:!1,termName:"xterm",cancelEvents:!1,overviewRuler:{}},Kz=["normal","bold","100","200","300","400","500","600","700","800","900"],qz=class extends qe{constructor(e){super(),this._onOptionChange=this._register(new Ae),this.onOptionChange=this._onOptionChange.event;let t={...gn};for(let i in e)if(i in t)try{let r=e[i];t[i]=this._sanitizeAndValidateOption(i,r)}catch(r){console.error(r)}this.rawOptions=t,this.options={...t},this._setupOptions(),this._register(St(()=>{this.rawOptions.linkHandler=null,this.rawOptions.documentOverride=null}))}onSpecificOptionChange(e,t){return this.onOptionChange(i=>{i===e&&t(this.rawOptions[e])})}onMultipleOptionChange(e,t){return this.onOptionChange(i=>{e.indexOf(i)!==-1&&t()})}_setupOptions(){let e=i=>{if(!(i in gn))throw new Error(`No option with key "${i}"`);return this.rawOptions[i]},t=(i,r)=>{if(!(i in gn))throw new Error(`No option with key "${i}"`);r=this._sanitizeAndValidateOption(i,r),this.rawOptions[i]!==r&&(this.rawOptions[i]=r,this._onOptionChange.fire(i))};for(let i in this.rawOptions){let r={get:e.bind(this,i),set:t.bind(this,i)};Object.defineProperty(this.options,i,r)}}_sanitizeAndValidateOption(e,t){switch(e){case"cursorStyle":if(t||(t=gn[e]),!Gz(t))throw new Error(`"${t}" is not a valid value for ${e}`);break;case"wordSeparator":t||(t=gn[e]);break;case"fontWeight":case"fontWeightBold":if(typeof t=="number"&&1<=t&&t<=1e3)break;t=Kz.includes(t)?t:gn[e];break;case"cursorWidth":t=Math.floor(t);case"lineHeight":case"tabStopWidth":if(t<1)throw new Error(`${e} cannot be less than 1, value: ${t}`);break;case"minimumContrastRatio":t=Math.max(1,Math.min(21,Math.round(t*10)/10));break;case"scrollback":if(t=Math.min(t,4294967295),t<0)throw new Error(`${e} cannot be less than 0, value: ${t}`);break;case"fastScrollSensitivity":case"scrollSensitivity":if(t<=0)throw new Error(`${e} cannot be less than or equal to 0, value: ${t}`);break;case"rows":case"cols":if(!t&&t!==0)throw new Error(`${e} must be numeric, value: ${t}`);break;case"windowsPty":t=t??{};break}return t}};function Gz(e){return e==="block"||e==="underline"||e==="bar"}function xo(e,t=5){if(typeof e!="object")return e;let i=Array.isArray(e)?[]:{};for(let r in e)i[r]=t<=1?e[r]:e[r]&&xo(e[r],t-1);return i}var q8=Object.freeze({insertMode:!1}),G8=Object.freeze({applicationCursorKeys:!1,applicationKeypad:!1,bracketedPasteMode:!1,cursorBlink:void 0,cursorStyle:void 0,origin:!1,reverseWraparound:!1,sendFocus:!1,synchronizedOutput:!1,wraparound:!0}),Ch=class extends qe{constructor(e,t,i){super(),this._bufferService=e,this._logService=t,this._optionsService=i,this.isCursorInitialized=!1,this.isCursorHidden=!1,this._onData=this._register(new Ae),this.onData=this._onData.event,this._onUserInput=this._register(new Ae),this.onUserInput=this._onUserInput.event,this._onBinary=this._register(new Ae),this.onBinary=this._onBinary.event,this._onRequestScrollToBottom=this._register(new Ae),this.onRequestScrollToBottom=this._onRequestScrollToBottom.event,this.modes=xo(q8),this.decPrivateModes=xo(G8)}reset(){this.modes=xo(q8),this.decPrivateModes=xo(G8)}triggerDataEvent(e,t=!1){if(this._optionsService.rawOptions.disableStdin)return;let i=this._bufferService.buffer;t&&this._optionsService.rawOptions.scrollOnUserInput&&i.ybase!==i.ydisp&&this._onRequestScrollToBottom.fire(),t&&this._onUserInput.fire(),this._logService.debug(`sending data "${e}"`),this._logService.trace("sending data (codes)",()=>e.split("").map(r=>r.charCodeAt(0))),this._onData.fire(e)}triggerBinaryEvent(e){this._optionsService.rawOptions.disableStdin||(this._logService.debug(`sending binary "${e}"`),this._logService.trace("sending binary (codes)",()=>e.split("").map(t=>t.charCodeAt(0))),this._onBinary.fire(e))}};Ch=Tt([Te(0,Ai),Te(1,nv),Te(2,Mi)],Ch);var Y8={NONE:{events:0,restrict:()=>!1},X10:{events:1,restrict:e=>e.button===4||e.action!==1?!1:(e.ctrl=!1,e.alt=!1,e.shift=!1,!0)},VT200:{events:19,restrict:e=>e.action!==32},DRAG:{events:23,restrict:e=>!(e.action===32&&e.button===3)},ANY:{events:31,restrict:e=>!0}};function T1(e,t){let i=(e.ctrl?16:0)|(e.shift?4:0)|(e.alt?8:0);return e.button===4?(i|=64,i|=e.action):(i|=e.button&3,e.button&4&&(i|=64),e.button&8&&(i|=128),e.action===32?i|=32:e.action===0&&!t&&(i|=3)),i}var N1=String.fromCharCode,X8={DEFAULT:e=>{let t=[T1(e,!1)+32,e.col+32,e.row+32];return t[0]>255||t[1]>255||t[2]>255?"":`\x1B[M${N1(t[0])}${N1(t[1])}${N1(t[2])}`},SGR:e=>{let t=e.action===0&&e.button!==4?"m":"M";return`\x1B[<${T1(e,!0)};${e.col};${e.row}${t}`},SGR_PIXELS:e=>{let t=e.action===0&&e.button!==4?"m":"M";return`\x1B[<${T1(e,!0)};${e.x};${e.y}${t}`}},kh=class extends qe{constructor(e,t,i){super(),this._bufferService=e,this._coreService=t,this._optionsService=i,this._protocols={},this._encodings={},this._activeProtocol="",this._activeEncoding="",this._lastEvent=null,this._wheelPartialScroll=0,this._onProtocolChange=this._register(new Ae),this.onProtocolChange=this._onProtocolChange.event;for(let r of Object.keys(Y8))this.addProtocol(r,Y8[r]);for(let r of Object.keys(X8))this.addEncoding(r,X8[r]);this.reset()}addProtocol(e,t){this._protocols[e]=t}addEncoding(e,t){this._encodings[e]=t}get activeProtocol(){return this._activeProtocol}get areMouseEventsActive(){return this._protocols[this._activeProtocol].events!==0}set activeProtocol(e){if(!this._protocols[e])throw new Error(`unknown protocol "${e}"`);this._activeProtocol=e,this._onProtocolChange.fire(this._protocols[e].events)}get activeEncoding(){return this._activeEncoding}set activeEncoding(e){if(!this._encodings[e])throw new Error(`unknown encoding "${e}"`);this._activeEncoding=e}reset(){this.activeProtocol="NONE",this.activeEncoding="DEFAULT",this._lastEvent=null,this._wheelPartialScroll=0}consumeWheelEvent(e,t,i){if(e.deltaY===0||e.shiftKey||t===void 0||i===void 0)return 0;let r=t/i,s=this._applyScrollModifier(e.deltaY,e);return e.deltaMode===WheelEvent.DOM_DELTA_PIXEL?(s/=r+0,Math.abs(e.deltaY)<50&&(s*=.3),this._wheelPartialScroll+=s,s=Math.floor(Math.abs(this._wheelPartialScroll))*(this._wheelPartialScroll>0?1:-1),this._wheelPartialScroll%=1):e.deltaMode===WheelEvent.DOM_DELTA_PAGE&&(s*=this._bufferService.rows),s}_applyScrollModifier(e,t){return t.altKey||t.ctrlKey||t.shiftKey?e*this._optionsService.rawOptions.fastScrollSensitivity*this._optionsService.rawOptions.scrollSensitivity:e*this._optionsService.rawOptions.scrollSensitivity}triggerMouseEvent(e){if(e.col<0||e.col>=this._bufferService.cols||e.row<0||e.row>=this._bufferService.rows||e.button===4&&e.action===32||e.button===3&&e.action!==32||e.button!==4&&(e.action===2||e.action===3)||(e.col++,e.row++,e.action===32&&this._lastEvent&&this._equalEvents(this._lastEvent,e,this._activeEncoding==="SGR_PIXELS"))||!this._protocols[this._activeProtocol].restrict(e))return!1;let t=this._encodings[this._activeEncoding](e);return t&&(this._activeEncoding==="DEFAULT"?this._coreService.triggerBinaryEvent(t):this._coreService.triggerDataEvent(t,!0)),this._lastEvent=e,!0}explainEvents(e){return{down:!!(e&1),up:!!(e&2),drag:!!(e&4),move:!!(e&8),wheel:!!(e&16)}}_equalEvents(e,t,i){if(i){if(e.x!==t.x||e.y!==t.y)return!1}else if(e.col!==t.col||e.row!==t.row)return!1;return!(e.button!==t.button||e.action!==t.action||e.ctrl!==t.ctrl||e.alt!==t.alt||e.shift!==t.shift)}};kh=Tt([Te(0,Ai),Te(1,cn),Te(2,Mi)],kh);var H1=[[768,879],[1155,1158],[1160,1161],[1425,1469],[1471,1471],[1473,1474],[1476,1477],[1479,1479],[1536,1539],[1552,1557],[1611,1630],[1648,1648],[1750,1764],[1767,1768],[1770,1773],[1807,1807],[1809,1809],[1840,1866],[1958,1968],[2027,2035],[2305,2306],[2364,2364],[2369,2376],[2381,2381],[2385,2388],[2402,2403],[2433,2433],[2492,2492],[2497,2500],[2509,2509],[2530,2531],[2561,2562],[2620,2620],[2625,2626],[2631,2632],[2635,2637],[2672,2673],[2689,2690],[2748,2748],[2753,2757],[2759,2760],[2765,2765],[2786,2787],[2817,2817],[2876,2876],[2879,2879],[2881,2883],[2893,2893],[2902,2902],[2946,2946],[3008,3008],[3021,3021],[3134,3136],[3142,3144],[3146,3149],[3157,3158],[3260,3260],[3263,3263],[3270,3270],[3276,3277],[3298,3299],[3393,3395],[3405,3405],[3530,3530],[3538,3540],[3542,3542],[3633,3633],[3636,3642],[3655,3662],[3761,3761],[3764,3769],[3771,3772],[3784,3789],[3864,3865],[3893,3893],[3895,3895],[3897,3897],[3953,3966],[3968,3972],[3974,3975],[3984,3991],[3993,4028],[4038,4038],[4141,4144],[4146,4146],[4150,4151],[4153,4153],[4184,4185],[4448,4607],[4959,4959],[5906,5908],[5938,5940],[5970,5971],[6002,6003],[6068,6069],[6071,6077],[6086,6086],[6089,6099],[6109,6109],[6155,6157],[6313,6313],[6432,6434],[6439,6440],[6450,6450],[6457,6459],[6679,6680],[6912,6915],[6964,6964],[6966,6970],[6972,6972],[6978,6978],[7019,7027],[7616,7626],[7678,7679],[8203,8207],[8234,8238],[8288,8291],[8298,8303],[8400,8431],[12330,12335],[12441,12442],[43014,43014],[43019,43019],[43045,43046],[64286,64286],[65024,65039],[65056,65059],[65279,65279],[65529,65531]],Yz=[[68097,68099],[68101,68102],[68108,68111],[68152,68154],[68159,68159],[119143,119145],[119155,119170],[119173,119179],[119210,119213],[119362,119364],[917505,917505],[917536,917631],[917760,917999]],Zt;function Xz(e,t){let i=0,r=t.length-1,s;if(e<t[0][0]||e>t[r][1])return!1;for(;r>=i;)if(s=i+r>>1,e>t[s][1])i=s+1;else if(e<t[s][0])r=s-1;else return!0;return!1}var Jz=class{constructor(){if(this.version="6",!Zt){Zt=new Uint8Array(65536),Zt.fill(1),Zt[0]=0,Zt.fill(0,1,32),Zt.fill(0,127,160),Zt.fill(2,4352,4448),Zt[9001]=2,Zt[9002]=2,Zt.fill(2,11904,42192),Zt[12351]=1,Zt.fill(2,44032,55204),Zt.fill(2,63744,64256),Zt.fill(2,65040,65050),Zt.fill(2,65072,65136),Zt.fill(2,65280,65377),Zt.fill(2,65504,65511);for(let e=0;e<H1.length;++e)Zt.fill(0,H1[e][0],H1[e][1]+1)}}wcwidth(e){return e<32?0:e<127?1:e<65536?Zt[e]:Xz(e,Yz)?0:e>=131072&&e<=196605||e>=196608&&e<=262141?2:1}charProperties(e,t){let i=this.wcwidth(e),r=i===0&&t!==0;if(r){let s=Gs.extractWidth(t);s===0?r=!1:s>i&&(i=s)}return Gs.createPropertyValue(0,i,r)}},Gs=class m0{constructor(){this._providers=Object.create(null),this._active="",this._onChange=new Ae,this.onChange=this._onChange.event;let t=new Jz;this.register(t),this._active=t.version,this._activeProvider=t}static extractShouldJoin(t){return(t&1)!==0}static extractWidth(t){return t>>1&3}static extractCharKind(t){return t>>3}static createPropertyValue(t,i,r=!1){return(t&16777215)<<3|(i&3)<<1|(r?1:0)}dispose(){this._onChange.dispose()}get versions(){return Object.keys(this._providers)}get activeVersion(){return this._active}set activeVersion(t){if(!this._providers[t])throw new Error(`unknown Unicode version "${t}"`);this._active=t,this._activeProvider=this._providers[t],this._onChange.fire(t)}register(t){this._providers[t.version]=t}wcwidth(t){return this._activeProvider.wcwidth(t)}getStringCellWidth(t){let i=0,r=0,s=t.length;for(let n=0;n<s;++n){let a=t.charCodeAt(n);if(55296<=a&&a<=56319){if(++n>=s)return i+this.wcwidth(a);let c=t.charCodeAt(n);56320<=c&&c<=57343?a=(a-55296)*1024+c-56320+65536:i+=this.wcwidth(c)}let o=this.charProperties(a,r),l=m0.extractWidth(o);m0.extractShouldJoin(o)&&(l-=m0.extractWidth(r)),i+=l,r=o}return i}charProperties(t,i){return this._activeProvider.charProperties(t,i)}},Qz=class{constructor(){this.glevel=0,this._charsets=[]}reset(){this.charset=void 0,this._charsets=[],this.glevel=0}setgLevel(e){this.glevel=e,this.charset=this._charsets[e]}setgCharset(e,t){this._charsets[e]=t,this.glevel===e&&(this.charset=t)}};function J8(e){var r;let t=(r=e.buffer.lines.get(e.buffer.ybase+e.buffer.y-1))==null?void 0:r.get(e.cols-1),i=e.buffer.lines.get(e.buffer.ybase+e.buffer.y);i&&t&&(i.isWrapped=t[3]!==0&&t[3]!==32)}var wo=2147483647,eU=256,Bv=class Ah{constructor(t=32,i=32){if(this.maxLength=t,this.maxSubParamsLength=i,i>eU)throw new Error("maxSubParamsLength must not be greater than 256");this.params=new Int32Array(t),this.length=0,this._subParams=new Int32Array(i),this._subParamsLength=0,this._subParamsIdx=new Uint16Array(t),this._rejectDigits=!1,this._rejectSubDigits=!1,this._digitIsSub=!1}static fromArray(t){let i=new Ah;if(!t.length)return i;for(let r=Array.isArray(t[0])?1:0;r<t.length;++r){let s=t[r];if(Array.isArray(s))for(let n=0;n<s.length;++n)i.addSubParam(s[n]);else i.addParam(s)}return i}clone(){let t=new Ah(this.maxLength,this.maxSubParamsLength);return t.params.set(this.params),t.length=this.length,t._subParams.set(this._subParams),t._subParamsLength=this._subParamsLength,t._subParamsIdx.set(this._subParamsIdx),t._rejectDigits=this._rejectDigits,t._rejectSubDigits=this._rejectSubDigits,t._digitIsSub=this._digitIsSub,t}toArray(){let t=[];for(let i=0;i<this.length;++i){t.push(this.params[i]);let r=this._subParamsIdx[i]>>8,s=this._subParamsIdx[i]&255;s-r>0&&t.push(Array.prototype.slice.call(this._subParams,r,s))}return t}reset(){this.length=0,this._subParamsLength=0,this._rejectDigits=!1,this._rejectSubDigits=!1,this._digitIsSub=!1}addParam(t){if(this._digitIsSub=!1,this.length>=this.maxLength){this._rejectDigits=!0;return}if(t<-1)throw new Error("values lesser than -1 are not allowed");this._subParamsIdx[this.length]=this._subParamsLength<<8|this._subParamsLength,this.params[this.length++]=t>wo?wo:t}addSubParam(t){if(this._digitIsSub=!0,!!this.length){if(this._rejectDigits||this._subParamsLength>=this.maxSubParamsLength){this._rejectSubDigits=!0;return}if(t<-1)throw new Error("values lesser than -1 are not allowed");this._subParams[this._subParamsLength++]=t>wo?wo:t,this._subParamsIdx[this.length-1]++}}hasSubParams(t){return(this._subParamsIdx[t]&255)-(this._subParamsIdx[t]>>8)>0}getSubParams(t){let i=this._subParamsIdx[t]>>8,r=this._subParamsIdx[t]&255;return r-i>0?this._subParams.subarray(i,r):null}getSubParamsAll(){let t={};for(let i=0;i<this.length;++i){let r=this._subParamsIdx[i]>>8,s=this._subParamsIdx[i]&255;s-r>0&&(t[i]=this._subParams.slice(r,s))}return t}addDigit(t){let i;if(this._rejectDigits||!(i=this._digitIsSub?this._subParamsLength:this.length)||this._digitIsSub&&this._rejectSubDigits)return;let r=this._digitIsSub?this._subParams:this.params,s=r[i-1];r[i-1]=~s?Math.min(s*10+t,wo):t}},So=[],tU=class{constructor(){this._state=0,this._active=So,this._id=-1,this._handlers=Object.create(null),this._handlerFb=()=>{},this._stack={paused:!1,loopPosition:0,fallThrough:!1}}registerHandler(e,t){this._handlers[e]===void 0&&(this._handlers[e]=[]);let i=this._handlers[e];return i.push(t),{dispose:()=>{let r=i.indexOf(t);r!==-1&&i.splice(r,1)}}}clearHandler(e){this._handlers[e]&&delete this._handlers[e]}setHandlerFallback(e){this._handlerFb=e}dispose(){this._handlers=Object.create(null),this._handlerFb=()=>{},this._active=So}reset(){if(this._state===2)for(let e=this._stack.paused?this._stack.loopPosition-1:this._active.length-1;e>=0;--e)this._active[e].end(!1);this._stack.paused=!1,this._active=So,this._id=-1,this._state=0}_start(){if(this._active=this._handlers[this._id]||So,!this._active.length)this._handlerFb(this._id,"START");else for(let e=this._active.length-1;e>=0;e--)this._active[e].start()}_put(e,t,i){if(!this._active.length)this._handlerFb(this._id,"PUT",Pc(e,t,i));else for(let r=this._active.length-1;r>=0;r--)this._active[r].put(e,t,i)}start(){this.reset(),this._state=1}put(e,t,i){if(this._state!==3){if(this._state===1)for(;t<i;){let r=e[t++];if(r===59){this._state=2,this._start();break}if(r<48||57<r){this._state=3;return}this._id===-1&&(this._id=0),this._id=this._id*10+r-48}this._state===2&&i-t>0&&this._put(e,t,i)}}end(e,t=!0){if(this._state!==0){if(this._state!==3)if(this._state===1&&this._start(),!this._active.length)this._handlerFb(this._id,"END",e);else{let i=!1,r=this._active.length-1,s=!1;if(this._stack.paused&&(r=this._stack.loopPosition-1,i=t,s=this._stack.fallThrough,this._stack.paused=!1),!s&&i===!1){for(;r>=0&&(i=this._active[r].end(e),i!==!0);r--)if(i instanceof Promise)return this._stack.paused=!0,this._stack.loopPosition=r,this._stack.fallThrough=!1,i;r--}for(;r>=0;r--)if(i=this._active[r].end(!1),i instanceof Promise)return this._stack.paused=!0,this._stack.loopPosition=r,this._stack.fallThrough=!0,i}this._active=So,this._id=-1,this._state=0}}},Ti=class{constructor(e){this._handler=e,this._data="",this._hitLimit=!1}start(){this._data="",this._hitLimit=!1}put(e,t,i){this._hitLimit||(this._data+=Pc(e,t,i),this._data.length>1e7&&(this._data="",this._hitLimit=!0))}end(e){let t=!1;if(this._hitLimit)t=!1;else if(e&&(t=this._handler(this._data),t instanceof Promise))return t.then(i=>(this._data="",this._hitLimit=!1,i));return this._data="",this._hitLimit=!1,t}},Co=[],iU=class{constructor(){this._handlers=Object.create(null),this._active=Co,this._ident=0,this._handlerFb=()=>{},this._stack={paused:!1,loopPosition:0,fallThrough:!1}}dispose(){this._handlers=Object.create(null),this._handlerFb=()=>{},this._active=Co}registerHandler(e,t){this._handlers[e]===void 0&&(this._handlers[e]=[]);let i=this._handlers[e];return i.push(t),{dispose:()=>{let r=i.indexOf(t);r!==-1&&i.splice(r,1)}}}clearHandler(e){this._handlers[e]&&delete this._handlers[e]}setHandlerFallback(e){this._handlerFb=e}reset(){if(this._active.length)for(let e=this._stack.paused?this._stack.loopPosition-1:this._active.length-1;e>=0;--e)this._active[e].unhook(!1);this._stack.paused=!1,this._active=Co,this._ident=0}hook(e,t){if(this.reset(),this._ident=e,this._active=this._handlers[e]||Co,!this._active.length)this._handlerFb(this._ident,"HOOK",t);else for(let i=this._active.length-1;i>=0;i--)this._active[i].hook(t)}put(e,t,i){if(!this._active.length)this._handlerFb(this._ident,"PUT",Pc(e,t,i));else for(let r=this._active.length-1;r>=0;r--)this._active[r].put(e,t,i)}unhook(e,t=!0){if(!this._active.length)this._handlerFb(this._ident,"UNHOOK",e);else{let i=!1,r=this._active.length-1,s=!1;if(this._stack.paused&&(r=this._stack.loopPosition-1,i=t,s=this._stack.fallThrough,this._stack.paused=!1),!s&&i===!1){for(;r>=0&&(i=this._active[r].unhook(e),i!==!0);r--)if(i instanceof Promise)return this._stack.paused=!0,this._stack.loopPosition=r,this._stack.fallThrough=!1,i;r--}for(;r>=0;r--)if(i=this._active[r].unhook(!1),i instanceof Promise)return this._stack.paused=!0,this._stack.loopPosition=r,this._stack.fallThrough=!0,i}this._active=Co,this._ident=0}},To=new Bv;To.addParam(0);var Q8=class{constructor(e){this._handler=e,this._data="",this._params=To,this._hitLimit=!1}hook(e){this._params=e.length>1||e.params[0]?e.clone():To,this._data="",this._hitLimit=!1}put(e,t,i){this._hitLimit||(this._data+=Pc(e,t,i),this._data.length>1e7&&(this._data="",this._hitLimit=!0))}unhook(e){let t=!1;if(this._hitLimit)t=!1;else if(e&&(t=this._handler(this._data,this._params),t instanceof Promise))return t.then(i=>(this._params=To,this._data="",this._hitLimit=!1,i));return this._params=To,this._data="",this._hitLimit=!1,t}},rU=class{constructor(e){this.table=new Uint8Array(e)}setDefault(e,t){this.table.fill(e<<4|t)}add(e,t,i,r){this.table[t<<8|e]=i<<4|r}addMany(e,t,i,r){for(let s=0;s<e.length;s++)this.table[t<<8|e[s]]=i<<4|r}},Fi=160,sU=function(){let e=new rU(4095),t=Array.apply(null,Array(256)).map((o,l)=>l),i=(o,l)=>t.slice(o,l),r=i(32,127),s=i(0,24);s.push(25),s.push.apply(s,i(28,32));let n=i(0,14),a;e.setDefault(1,0),e.addMany(r,0,2,0);for(a in n)e.addMany([24,26,153,154],a,3,0),e.addMany(i(128,144),a,3,0),e.addMany(i(144,152),a,3,0),e.add(156,a,0,0),e.add(27,a,11,1),e.add(157,a,4,8),e.addMany([152,158,159],a,0,7),e.add(155,a,11,3),e.add(144,a,11,9);return e.addMany(s,0,3,0),e.addMany(s,1,3,1),e.add(127,1,0,1),e.addMany(s,8,0,8),e.addMany(s,3,3,3),e.add(127,3,0,3),e.addMany(s,4,3,4),e.add(127,4,0,4),e.addMany(s,6,3,6),e.addMany(s,5,3,5),e.add(127,5,0,5),e.addMany(s,2,3,2),e.add(127,2,0,2),e.add(93,1,4,8),e.addMany(r,8,5,8),e.add(127,8,5,8),e.addMany([156,27,24,26,7],8,6,0),e.addMany(i(28,32),8,0,8),e.addMany([88,94,95],1,0,7),e.addMany(r,7,0,7),e.addMany(s,7,0,7),e.add(156,7,0,0),e.add(127,7,0,7),e.add(91,1,11,3),e.addMany(i(64,127),3,7,0),e.addMany(i(48,60),3,8,4),e.addMany([60,61,62,63],3,9,4),e.addMany(i(48,60),4,8,4),e.addMany(i(64,127),4,7,0),e.addMany([60,61,62,63],4,0,6),e.addMany(i(32,64),6,0,6),e.add(127,6,0,6),e.addMany(i(64,127),6,0,0),e.addMany(i(32,48),3,9,5),e.addMany(i(32,48),5,9,5),e.addMany(i(48,64),5,0,6),e.addMany(i(64,127),5,7,0),e.addMany(i(32,48),4,9,5),e.addMany(i(32,48),1,9,2),e.addMany(i(32,48),2,9,2),e.addMany(i(48,127),2,10,0),e.addMany(i(48,80),1,10,0),e.addMany(i(81,88),1,10,0),e.addMany([89,90,92],1,10,0),e.addMany(i(96,127),1,10,0),e.add(80,1,11,9),e.addMany(s,9,0,9),e.add(127,9,0,9),e.addMany(i(28,32),9,0,9),e.addMany(i(32,48),9,9,12),e.addMany(i(48,60),9,8,10),e.addMany([60,61,62,63],9,9,10),e.addMany(s,11,0,11),e.addMany(i(32,128),11,0,11),e.addMany(i(28,32),11,0,11),e.addMany(s,10,0,10),e.add(127,10,0,10),e.addMany(i(28,32),10,0,10),e.addMany(i(48,60),10,8,10),e.addMany([60,61,62,63],10,0,11),e.addMany(i(32,48),10,9,12),e.addMany(s,12,0,12),e.add(127,12,0,12),e.addMany(i(28,32),12,0,12),e.addMany(i(32,48),12,9,12),e.addMany(i(48,64),12,0,11),e.addMany(i(64,127),12,12,13),e.addMany(i(64,127),10,12,13),e.addMany(i(64,127),9,12,13),e.addMany(s,13,13,13),e.addMany(r,13,13,13),e.add(127,13,0,13),e.addMany([27,156,24,26],13,14,0),e.add(Fi,0,2,0),e.add(Fi,8,5,8),e.add(Fi,6,0,6),e.add(Fi,11,0,11),e.add(Fi,13,13,13),e}(),nU=class extends qe{constructor(e=sU){super(),this._transitions=e,this._parseStack={state:0,handlers:[],handlerPos:0,transition:0,chunkPos:0},this.initialState=0,this.currentState=this.initialState,this._params=new Bv,this._params.addParam(0),this._collect=0,this.precedingJoinState=0,this._printHandlerFb=(t,i,r)=>{},this._executeHandlerFb=t=>{},this._csiHandlerFb=(t,i)=>{},this._escHandlerFb=t=>{},this._errorHandlerFb=t=>t,this._printHandler=this._printHandlerFb,this._executeHandlers=Object.create(null),this._csiHandlers=Object.create(null),this._escHandlers=Object.create(null),this._register(St(()=>{this._csiHandlers=Object.create(null),this._executeHandlers=Object.create(null),this._escHandlers=Object.create(null)})),this._oscParser=this._register(new tU),this._dcsParser=this._register(new iU),this._errorHandler=this._errorHandlerFb,this.registerEscHandler({final:"\\"},()=>!0)}_identifier(e,t=[64,126]){let i=0;if(e.prefix){if(e.prefix.length>1)throw new Error("only one byte as prefix supported");if(i=e.prefix.charCodeAt(0),i&&60>i||i>63)throw new Error("prefix must be in range 0x3c .. 0x3f")}if(e.intermediates){if(e.intermediates.length>2)throw new Error("only two bytes as intermediates are supported");for(let s=0;s<e.intermediates.length;++s){let n=e.intermediates.charCodeAt(s);if(32>n||n>47)throw new Error("intermediate must be in range 0x20 .. 0x2f");i<<=8,i|=n}}if(e.final.length!==1)throw new Error("final must be a single byte");let r=e.final.charCodeAt(0);if(t[0]>r||r>t[1])throw new Error(`final must be in range ${t[0]} .. ${t[1]}`);return i<<=8,i|=r,i}identToString(e){let t=[];for(;e;)t.push(String.fromCharCode(e&255)),e>>=8;return t.reverse().join("")}setPrintHandler(e){this._printHandler=e}clearPrintHandler(){this._printHandler=this._printHandlerFb}registerEscHandler(e,t){let i=this._identifier(e,[48,126]);this._escHandlers[i]===void 0&&(this._escHandlers[i]=[]);let r=this._escHandlers[i];return r.push(t),{dispose:()=>{let s=r.indexOf(t);s!==-1&&r.splice(s,1)}}}clearEscHandler(e){this._escHandlers[this._identifier(e,[48,126])]&&delete this._escHandlers[this._identifier(e,[48,126])]}setEscHandlerFallback(e){this._escHandlerFb=e}setExecuteHandler(e,t){this._executeHandlers[e.charCodeAt(0)]=t}clearExecuteHandler(e){this._executeHandlers[e.charCodeAt(0)]&&delete this._executeHandlers[e.charCodeAt(0)]}setExecuteHandlerFallback(e){this._executeHandlerFb=e}registerCsiHandler(e,t){let i=this._identifier(e);this._csiHandlers[i]===void 0&&(this._csiHandlers[i]=[]);let r=this._csiHandlers[i];return r.push(t),{dispose:()=>{let s=r.indexOf(t);s!==-1&&r.splice(s,1)}}}clearCsiHandler(e){this._csiHandlers[this._identifier(e)]&&delete this._csiHandlers[this._identifier(e)]}setCsiHandlerFallback(e){this._csiHandlerFb=e}registerDcsHandler(e,t){return this._dcsParser.registerHandler(this._identifier(e),t)}clearDcsHandler(e){this._dcsParser.clearHandler(this._identifier(e))}setDcsHandlerFallback(e){this._dcsParser.setHandlerFallback(e)}registerOscHandler(e,t){return this._oscParser.registerHandler(e,t)}clearOscHandler(e){this._oscParser.clearHandler(e)}setOscHandlerFallback(e){this._oscParser.setHandlerFallback(e)}setErrorHandler(e){this._errorHandler=e}clearErrorHandler(){this._errorHandler=this._errorHandlerFb}reset(){this.currentState=this.initialState,this._oscParser.reset(),this._dcsParser.reset(),this._params.reset(),this._params.addParam(0),this._collect=0,this.precedingJoinState=0,this._parseStack.state!==0&&(this._parseStack.state=2,this._parseStack.handlers=[])}_preserveStack(e,t,i,r,s){this._parseStack.state=e,this._parseStack.handlers=t,this._parseStack.handlerPos=i,this._parseStack.transition=r,this._parseStack.chunkPos=s}parse(e,t,i){let r=0,s=0,n=0,a;if(this._parseStack.state)if(this._parseStack.state===2)this._parseStack.state=0,n=this._parseStack.chunkPos+1;else{if(i===void 0||this._parseStack.state===1)throw this._parseStack.state=1,new Error("improper continuation due to previous async handler, giving up parsing");let o=this._parseStack.handlers,l=this._parseStack.handlerPos-1;switch(this._parseStack.state){case 3:if(i===!1&&l>-1){for(;l>=0&&(a=o[l](this._params),a!==!0);l--)if(a instanceof Promise)return this._parseStack.handlerPos=l,a}this._parseStack.handlers=[];break;case 4:if(i===!1&&l>-1){for(;l>=0&&(a=o[l](),a!==!0);l--)if(a instanceof Promise)return this._parseStack.handlerPos=l,a}this._parseStack.handlers=[];break;case 6:if(r=e[this._parseStack.chunkPos],a=this._dcsParser.unhook(r!==24&&r!==26,i),a)return a;r===27&&(this._parseStack.transition|=1),this._params.reset(),this._params.addParam(0),this._collect=0;break;case 5:if(r=e[this._parseStack.chunkPos],a=this._oscParser.end(r!==24&&r!==26,i),a)return a;r===27&&(this._parseStack.transition|=1),this._params.reset(),this._params.addParam(0),this._collect=0;break}this._parseStack.state=0,n=this._parseStack.chunkPos+1,this.precedingJoinState=0,this.currentState=this._parseStack.transition&15}for(let o=n;o<t;++o){switch(r=e[o],s=this._transitions.table[this.currentState<<8|(r<160?r:Fi)],s>>4){case 2:for(let d=o+1;;++d){if(d>=t||(r=e[d])<32||r>126&&r<Fi){this._printHandler(e,o,d),o=d-1;break}if(++d>=t||(r=e[d])<32||r>126&&r<Fi){this._printHandler(e,o,d),o=d-1;break}if(++d>=t||(r=e[d])<32||r>126&&r<Fi){this._printHandler(e,o,d),o=d-1;break}if(++d>=t||(r=e[d])<32||r>126&&r<Fi){this._printHandler(e,o,d),o=d-1;break}}break;case 3:this._executeHandlers[r]?this._executeHandlers[r]():this._executeHandlerFb(r),this.precedingJoinState=0;break;case 0:break;case 1:if(this._errorHandler({position:o,code:r,currentState:this.currentState,collect:this._collect,params:this._params,abort:!1}).abort)return;break;case 7:let l=this._csiHandlers[this._collect<<8|r],c=l?l.length-1:-1;for(;c>=0&&(a=l[c](this._params),a!==!0);c--)if(a instanceof Promise)return this._preserveStack(3,l,c,s,o),a;c<0&&this._csiHandlerFb(this._collect<<8|r,this._params),this.precedingJoinState=0;break;case 8:do switch(r){case 59:this._params.addParam(0);break;case 58:this._params.addSubParam(-1);break;default:this._params.addDigit(r-48)}while(++o<t&&(r=e[o])>47&&r<60);o--;break;case 9:this._collect<<=8,this._collect|=r;break;case 10:let u=this._escHandlers[this._collect<<8|r],h=u?u.length-1:-1;for(;h>=0&&(a=u[h](),a!==!0);h--)if(a instanceof Promise)return this._preserveStack(4,u,h,s,o),a;h<0&&this._escHandlerFb(this._collect<<8|r),this.precedingJoinState=0;break;case 11:this._params.reset(),this._params.addParam(0),this._collect=0;break;case 12:this._dcsParser.hook(this._collect<<8|r,this._params);break;case 13:for(let d=o+1;;++d)if(d>=t||(r=e[d])===24||r===26||r===27||r>127&&r<Fi){this._dcsParser.put(e,o,d),o=d-1;break}break;case 14:if(a=this._dcsParser.unhook(r!==24&&r!==26),a)return this._preserveStack(6,[],0,s,o),a;r===27&&(s|=1),this._params.reset(),this._params.addParam(0),this._collect=0,this.precedingJoinState=0;break;case 4:this._oscParser.start();break;case 5:for(let d=o+1;;d++)if(d>=t||(r=e[d])<32||r>127&&r<Fi){this._oscParser.put(e,o,d),o=d-1;break}break;case 6:if(a=this._oscParser.end(r!==24&&r!==26),a)return this._preserveStack(5,[],0,s,o),a;r===27&&(s|=1),this._params.reset(),this._params.addParam(0),this._collect=0,this.precedingJoinState=0;break}this.currentState=s&15}}},aU=/^([\da-f])\/([\da-f])\/([\da-f])$|^([\da-f]{2})\/([\da-f]{2})\/([\da-f]{2})$|^([\da-f]{3})\/([\da-f]{3})\/([\da-f]{3})$|^([\da-f]{4})\/([\da-f]{4})\/([\da-f]{4})$/,oU=/^[\da-f]+$/;function ep(e){if(!e)return;let t=e.toLowerCase();if(t.indexOf("rgb:")===0){t=t.slice(4);let i=aU.exec(t);if(i){let r=i[1]?15:i[4]?255:i[7]?4095:65535;return[Math.round(parseInt(i[1]||i[4]||i[7]||i[10],16)/r*255),Math.round(parseInt(i[2]||i[5]||i[8]||i[11],16)/r*255),Math.round(parseInt(i[3]||i[6]||i[9]||i[12],16)/r*255)]}}else if(t.indexOf("#")===0&&(t=t.slice(1),oU.exec(t)&&[3,6,9,12].includes(t.length))){let i=t.length/3,r=[0,0,0];for(let s=0;s<3;++s){let n=parseInt(t.slice(i*s,i*s+i),16);r[s]=i===1?n<<4:i===2?n:i===3?n>>4:n>>8}return r}}function P1(e,t){let i=e.toString(16),r=i.length<2?"0"+i:i;switch(t){case 4:return i[0];case 8:return r;case 12:return(r+r).slice(0,3);default:return r+r}}function lU(e,t=16){let[i,r,s]=e;return`rgb:${P1(i,t)}/${P1(r,t)}/${P1(s,t)}`}var cU={"(":0,")":1,"*":2,"+":3,"-":1,".":2},ns=131072,tp=10;function ip(e,t){if(e>24)return t.setWinLines||!1;switch(e){case 1:return!!t.restoreWin;case 2:return!!t.minimizeWin;case 3:return!!t.setWinPosition;case 4:return!!t.setWinSizePixels;case 5:return!!t.raiseWin;case 6:return!!t.lowerWin;case 7:return!!t.refreshWin;case 8:return!!t.setWinSizeChars;case 9:return!!t.maximizeWin;case 10:return!!t.fullscreenWin;case 11:return!!t.getWinState;case 13:return!!t.getWinPosition;case 14:return!!t.getWinSizePixels;case 15:return!!t.getScreenSizePixels;case 16:return!!t.getCellSizePixels;case 18:return!!t.getWinSizeChars;case 19:return!!t.getScreenSizeChars;case 20:return!!t.getIconTitle;case 21:return!!t.getWinTitle;case 22:return!!t.pushTitle;case 23:return!!t.popTitle;case 24:return!!t.setWinLines}return!1}var rp=5e3,sp=0,uU=class extends qe{constructor(e,t,i,r,s,n,a,o,l=new nU){super(),this._bufferService=e,this._charsetService=t,this._coreService=i,this._logService=r,this._optionsService=s,this._oscLinkService=n,this._coreMouseService=a,this._unicodeService=o,this._parser=l,this._parseBuffer=new Uint32Array(4096),this._stringDecoder=new $Z,this._utf8Decoder=new xZ,this._windowTitle="",this._iconName="",this._windowTitleStack=[],this._iconNameStack=[],this._curAttrData=It.clone(),this._eraseAttrDataInternal=It.clone(),this._onRequestBell=this._register(new Ae),this.onRequestBell=this._onRequestBell.event,this._onRequestRefreshRows=this._register(new Ae),this.onRequestRefreshRows=this._onRequestRefreshRows.event,this._onRequestReset=this._register(new Ae),this.onRequestReset=this._onRequestReset.event,this._onRequestSendFocus=this._register(new Ae),this.onRequestSendFocus=this._onRequestSendFocus.event,this._onRequestSyncScrollBar=this._register(new Ae),this.onRequestSyncScrollBar=this._onRequestSyncScrollBar.event,this._onRequestWindowsOptionsReport=this._register(new Ae),this.onRequestWindowsOptionsReport=this._onRequestWindowsOptionsReport.event,this._onA11yChar=this._register(new Ae),this.onA11yChar=this._onA11yChar.event,this._onA11yTab=this._register(new Ae),this.onA11yTab=this._onA11yTab.event,this._onCursorMove=this._register(new Ae),this.onCursorMove=this._onCursorMove.event,this._onLineFeed=this._register(new Ae),this.onLineFeed=this._onLineFeed.event,this._onScroll=this._register(new Ae),this.onScroll=this._onScroll.event,this._onTitleChange=this._register(new Ae),this.onTitleChange=this._onTitleChange.event,this._onColor=this._register(new Ae),this.onColor=this._onColor.event,this._parseStack={paused:!1,cursorStartX:0,cursorStartY:0,decodedLength:0,position:0},this._specialColors=[256,257,258],this._register(this._parser),this._dirtyRowTracker=new Mh(this._bufferService),this._activeBuffer=this._bufferService.buffer,this._register(this._bufferService.buffers.onBufferActivate(c=>this._activeBuffer=c.activeBuffer)),this._parser.setCsiHandlerFallback((c,u)=>{this._logService.debug("Unknown CSI code: ",{identifier:this._parser.identToString(c),params:u.toArray()})}),this._parser.setEscHandlerFallback(c=>{this._logService.debug("Unknown ESC code: ",{identifier:this._parser.identToString(c)})}),this._parser.setExecuteHandlerFallback(c=>{this._logService.debug("Unknown EXECUTE code: ",{code:c})}),this._parser.setOscHandlerFallback((c,u,h)=>{this._logService.debug("Unknown OSC code: ",{identifier:c,action:u,data:h})}),this._parser.setDcsHandlerFallback((c,u,h)=>{u==="HOOK"&&(h=h.toArray()),this._logService.debug("Unknown DCS code: ",{identifier:this._parser.identToString(c),action:u,payload:h})}),this._parser.setPrintHandler((c,u,h)=>this.print(c,u,h)),this._parser.registerCsiHandler({final:"@"},c=>this.insertChars(c)),this._parser.registerCsiHandler({intermediates:" ",final:"@"},c=>this.scrollLeft(c)),this._parser.registerCsiHandler({final:"A"},c=>this.cursorUp(c)),this._parser.registerCsiHandler({intermediates:" ",final:"A"},c=>this.scrollRight(c)),this._parser.registerCsiHandler({final:"B"},c=>this.cursorDown(c)),this._parser.registerCsiHandler({final:"C"},c=>this.cursorForward(c)),this._parser.registerCsiHandler({final:"D"},c=>this.cursorBackward(c)),this._parser.registerCsiHandler({final:"E"},c=>this.cursorNextLine(c)),this._parser.registerCsiHandler({final:"F"},c=>this.cursorPrecedingLine(c)),this._parser.registerCsiHandler({final:"G"},c=>this.cursorCharAbsolute(c)),this._parser.registerCsiHandler({final:"H"},c=>this.cursorPosition(c)),this._parser.registerCsiHandler({final:"I"},c=>this.cursorForwardTab(c)),this._parser.registerCsiHandler({final:"J"},c=>this.eraseInDisplay(c,!1)),this._parser.registerCsiHandler({prefix:"?",final:"J"},c=>this.eraseInDisplay(c,!0)),this._parser.registerCsiHandler({final:"K"},c=>this.eraseInLine(c,!1)),this._parser.registerCsiHandler({prefix:"?",final:"K"},c=>this.eraseInLine(c,!0)),this._parser.registerCsiHandler({final:"L"},c=>this.insertLines(c)),this._parser.registerCsiHandler({final:"M"},c=>this.deleteLines(c)),this._parser.registerCsiHandler({final:"P"},c=>this.deleteChars(c)),this._parser.registerCsiHandler({final:"S"},c=>this.scrollUp(c)),this._parser.registerCsiHandler({final:"T"},c=>this.scrollDown(c)),this._parser.registerCsiHandler({final:"X"},c=>this.eraseChars(c)),this._parser.registerCsiHandler({final:"Z"},c=>this.cursorBackwardTab(c)),this._parser.registerCsiHandler({final:"`"},c=>this.charPosAbsolute(c)),this._parser.registerCsiHandler({final:"a"},c=>this.hPositionRelative(c)),this._parser.registerCsiHandler({final:"b"},c=>this.repeatPrecedingCharacter(c)),this._parser.registerCsiHandler({final:"c"},c=>this.sendDeviceAttributesPrimary(c)),this._parser.registerCsiHandler({prefix:">",final:"c"},c=>this.sendDeviceAttributesSecondary(c)),this._parser.registerCsiHandler({final:"d"},c=>this.linePosAbsolute(c)),this._parser.registerCsiHandler({final:"e"},c=>this.vPositionRelative(c)),this._parser.registerCsiHandler({final:"f"},c=>this.hVPosition(c)),this._parser.registerCsiHandler({final:"g"},c=>this.tabClear(c)),this._parser.registerCsiHandler({final:"h"},c=>this.setMode(c)),this._parser.registerCsiHandler({prefix:"?",final:"h"},c=>this.setModePrivate(c)),this._parser.registerCsiHandler({final:"l"},c=>this.resetMode(c)),this._parser.registerCsiHandler({prefix:"?",final:"l"},c=>this.resetModePrivate(c)),this._parser.registerCsiHandler({final:"m"},c=>this.charAttributes(c)),this._parser.registerCsiHandler({final:"n"},c=>this.deviceStatus(c)),this._parser.registerCsiHandler({prefix:"?",final:"n"},c=>this.deviceStatusPrivate(c)),this._parser.registerCsiHandler({intermediates:"!",final:"p"},c=>this.softReset(c)),this._parser.registerCsiHandler({intermediates:" ",final:"q"},c=>this.setCursorStyle(c)),this._parser.registerCsiHandler({final:"r"},c=>this.setScrollRegion(c)),this._parser.registerCsiHandler({final:"s"},c=>this.saveCursor(c)),this._parser.registerCsiHandler({final:"t"},c=>this.windowOptions(c)),this._parser.registerCsiHandler({final:"u"},c=>this.restoreCursor(c)),this._parser.registerCsiHandler({intermediates:"'",final:"}"},c=>this.insertColumns(c)),this._parser.registerCsiHandler({intermediates:"'",final:"~"},c=>this.deleteColumns(c)),this._parser.registerCsiHandler({intermediates:'"',final:"q"},c=>this.selectProtected(c)),this._parser.registerCsiHandler({intermediates:"$",final:"p"},c=>this.requestMode(c,!0)),this._parser.registerCsiHandler({prefix:"?",intermediates:"$",final:"p"},c=>this.requestMode(c,!1)),this._parser.setExecuteHandler(ve.BEL,()=>this.bell()),this._parser.setExecuteHandler(ve.LF,()=>this.lineFeed()),this._parser.setExecuteHandler(ve.VT,()=>this.lineFeed()),this._parser.setExecuteHandler(ve.FF,()=>this.lineFeed()),this._parser.setExecuteHandler(ve.CR,()=>this.carriageReturn()),this._parser.setExecuteHandler(ve.BS,()=>this.backspace()),this._parser.setExecuteHandler(ve.HT,()=>this.tab()),this._parser.setExecuteHandler(ve.SO,()=>this.shiftOut()),this._parser.setExecuteHandler(ve.SI,()=>this.shiftIn()),this._parser.setExecuteHandler(p0.IND,()=>this.index()),this._parser.setExecuteHandler(p0.NEL,()=>this.nextLine()),this._parser.setExecuteHandler(p0.HTS,()=>this.tabSet()),this._parser.registerOscHandler(0,new Ti(c=>(this.setTitle(c),this.setIconName(c),!0))),this._parser.registerOscHandler(1,new Ti(c=>this.setIconName(c))),this._parser.registerOscHandler(2,new Ti(c=>this.setTitle(c))),this._parser.registerOscHandler(4,new Ti(c=>this.setOrReportIndexedColor(c))),this._parser.registerOscHandler(8,new Ti(c=>this.setHyperlink(c))),this._parser.registerOscHandler(10,new Ti(c=>this.setOrReportFgColor(c))),this._parser.registerOscHandler(11,new Ti(c=>this.setOrReportBgColor(c))),this._parser.registerOscHandler(12,new Ti(c=>this.setOrReportCursorColor(c))),this._parser.registerOscHandler(104,new Ti(c=>this.restoreIndexedColor(c))),this._parser.registerOscHandler(110,new Ti(c=>this.restoreFgColor(c))),this._parser.registerOscHandler(111,new Ti(c=>this.restoreBgColor(c))),this._parser.registerOscHandler(112,new Ti(c=>this.restoreCursorColor(c))),this._parser.registerEscHandler({final:"7"},()=>this.saveCursor()),this._parser.registerEscHandler({final:"8"},()=>this.restoreCursor()),this._parser.registerEscHandler({final:"D"},()=>this.index()),this._parser.registerEscHandler({final:"E"},()=>this.nextLine()),this._parser.registerEscHandler({final:"H"},()=>this.tabSet()),this._parser.registerEscHandler({final:"M"},()=>this.reverseIndex()),this._parser.registerEscHandler({final:"="},()=>this.keypadApplicationMode()),this._parser.registerEscHandler({final:">"},()=>this.keypadNumericMode()),this._parser.registerEscHandler({final:"c"},()=>this.fullReset()),this._parser.registerEscHandler({final:"n"},()=>this.setgLevel(2)),this._parser.registerEscHandler({final:"o"},()=>this.setgLevel(3)),this._parser.registerEscHandler({final:"|"},()=>this.setgLevel(3)),this._parser.registerEscHandler({final:"}"},()=>this.setgLevel(2)),this._parser.registerEscHandler({final:"~"},()=>this.setgLevel(1)),this._parser.registerEscHandler({intermediates:"%",final:"@"},()=>this.selectDefaultCharset()),this._parser.registerEscHandler({intermediates:"%",final:"G"},()=>this.selectDefaultCharset());for(let c in Wt)this._parser.registerEscHandler({intermediates:"(",final:c},()=>this.selectCharset("("+c)),this._parser.registerEscHandler({intermediates:")",final:c},()=>this.selectCharset(")"+c)),this._parser.registerEscHandler({intermediates:"*",final:c},()=>this.selectCharset("*"+c)),this._parser.registerEscHandler({intermediates:"+",final:c},()=>this.selectCharset("+"+c)),this._parser.registerEscHandler({intermediates:"-",final:c},()=>this.selectCharset("-"+c)),this._parser.registerEscHandler({intermediates:".",final:c},()=>this.selectCharset("."+c)),this._parser.registerEscHandler({intermediates:"/",final:c},()=>this.selectCharset("/"+c));this._parser.registerEscHandler({intermediates:"#",final:"8"},()=>this.screenAlignmentPattern()),this._parser.setErrorHandler(c=>(this._logService.error("Parsing error: ",c),c)),this._parser.registerDcsHandler({intermediates:"$",final:"q"},new Q8((c,u)=>this.requestStatusString(c,u)))}getAttrData(){return this._curAttrData}_preserveStack(e,t,i,r){this._parseStack.paused=!0,this._parseStack.cursorStartX=e,this._parseStack.cursorStartY=t,this._parseStack.decodedLength=i,this._parseStack.position=r}_logSlowResolvingAsync(e){this._logService.logLevel<=3&&Promise.race([e,new Promise((t,i)=>setTimeout(()=>i("#SLOW_TIMEOUT"),rp))]).catch(t=>{if(t!=="#SLOW_TIMEOUT")throw t;console.warn(`async parser handler taking longer than ${rp} ms`)})}_getCurrentLinkId(){return this._curAttrData.extended.urlId}parse(e,t){let i,r=this._activeBuffer.x,s=this._activeBuffer.y,n=0,a=this._parseStack.paused;if(a){if(i=this._parser.parse(this._parseBuffer,this._parseStack.decodedLength,t))return this._logSlowResolvingAsync(i),i;r=this._parseStack.cursorStartX,s=this._parseStack.cursorStartY,this._parseStack.paused=!1,e.length>ns&&(n=this._parseStack.position+ns)}if(this._logService.logLevel<=1&&this._logService.debug(`parsing data ${typeof e=="string"?` "${e}"`:` "${Array.prototype.map.call(e,c=>String.fromCharCode(c)).join("")}"`}`),this._logService.logLevel===0&&this._logService.trace("parsing data (codes)",typeof e=="string"?e.split("").map(c=>c.charCodeAt(0)):e),this._parseBuffer.length<e.length&&this._parseBuffer.length<ns&&(this._parseBuffer=new Uint32Array(Math.min(e.length,ns))),a||this._dirtyRowTracker.clearRange(),e.length>ns)for(let c=n;c<e.length;c+=ns){let u=c+ns<e.length?c+ns:e.length,h=typeof e=="string"?this._stringDecoder.decode(e.substring(c,u),this._parseBuffer):this._utf8Decoder.decode(e.subarray(c,u),this._parseBuffer);if(i=this._parser.parse(this._parseBuffer,h))return this._preserveStack(r,s,h,c),this._logSlowResolvingAsync(i),i}else if(!a){let c=typeof e=="string"?this._stringDecoder.decode(e,this._parseBuffer):this._utf8Decoder.decode(e,this._parseBuffer);if(i=this._parser.parse(this._parseBuffer,c))return this._preserveStack(r,s,c,0),this._logSlowResolvingAsync(i),i}(this._activeBuffer.x!==r||this._activeBuffer.y!==s)&&this._onCursorMove.fire();let o=this._dirtyRowTracker.end+(this._bufferService.buffer.ybase-this._bufferService.buffer.ydisp),l=this._dirtyRowTracker.start+(this._bufferService.buffer.ybase-this._bufferService.buffer.ydisp);l<this._bufferService.rows&&this._onRequestRefreshRows.fire({start:Math.min(l,this._bufferService.rows-1),end:Math.min(o,this._bufferService.rows-1)})}print(e,t,i){let r,s,n=this._charsetService.charset,a=this._optionsService.rawOptions.screenReaderMode,o=this._bufferService.cols,l=this._coreService.decPrivateModes.wraparound,c=this._coreService.modes.insertMode,u=this._curAttrData,h=this._activeBuffer.lines.get(this._activeBuffer.ybase+this._activeBuffer.y);this._dirtyRowTracker.markDirty(this._activeBuffer.y),this._activeBuffer.x&&i-t>0&&h.getWidth(this._activeBuffer.x-1)===2&&h.setCellFromCodepoint(this._activeBuffer.x-1,0,1,u);let d=this._parser.precedingJoinState;for(let f=t;f<i;++f){if(r=e[f],r<127&&n){let p=n[String.fromCharCode(r)];p&&(r=p.charCodeAt(0))}let m=this._unicodeService.charProperties(r,d);s=Gs.extractWidth(m);let _=Gs.extractShouldJoin(m),y=_?Gs.extractWidth(d):0;if(d=m,a&&this._onA11yChar.fire(us(r)),this._getCurrentLinkId()&&this._oscLinkService.addLineToLink(this._getCurrentLinkId(),this._activeBuffer.ybase+this._activeBuffer.y),this._activeBuffer.x+s-y>o){if(l){let p=h,C=this._activeBuffer.x-y;for(this._activeBuffer.x=y,this._activeBuffer.y++,this._activeBuffer.y===this._activeBuffer.scrollBottom+1?(this._activeBuffer.y--,this._bufferService.scroll(this._eraseAttrData(),!0)):(this._activeBuffer.y>=this._bufferService.rows&&(this._activeBuffer.y=this._bufferService.rows-1),this._activeBuffer.lines.get(this._activeBuffer.ybase+this._activeBuffer.y).isWrapped=!0),h=this._activeBuffer.lines.get(this._activeBuffer.ybase+this._activeBuffer.y),y>0&&h instanceof $o&&h.copyCellsFrom(p,C,0,y,!1);C<o;)p.setCellFromCodepoint(C++,0,1,u)}else if(this._activeBuffer.x=o-1,s===2)continue}if(_&&this._activeBuffer.x){let p=h.getWidth(this._activeBuffer.x-1)?1:2;h.addCodepointToCell(this._activeBuffer.x-p,r,s);for(let C=s-y;--C>=0;)h.setCellFromCodepoint(this._activeBuffer.x++,0,0,u);continue}if(c&&(h.insertCells(this._activeBuffer.x,s-y,this._activeBuffer.getNullCell(u)),h.getWidth(o-1)===2&&h.setCellFromCodepoint(o-1,0,1,u)),h.setCellFromCodepoint(this._activeBuffer.x++,r,s,u),s>0)for(;--s;)h.setCellFromCodepoint(this._activeBuffer.x++,0,0,u)}this._parser.precedingJoinState=d,this._activeBuffer.x<o&&i-t>0&&h.getWidth(this._activeBuffer.x)===0&&!h.hasContent(this._activeBuffer.x)&&h.setCellFromCodepoint(this._activeBuffer.x,0,1,u),this._dirtyRowTracker.markDirty(this._activeBuffer.y)}registerCsiHandler(e,t){return e.final==="t"&&!e.prefix&&!e.intermediates?this._parser.registerCsiHandler(e,i=>ip(i.params[0],this._optionsService.rawOptions.windowOptions)?t(i):!0):this._parser.registerCsiHandler(e,t)}registerDcsHandler(e,t){return this._parser.registerDcsHandler(e,new Q8(t))}registerEscHandler(e,t){return this._parser.registerEscHandler(e,t)}registerOscHandler(e,t){return this._parser.registerOscHandler(e,new Ti(t))}bell(){return this._onRequestBell.fire(),!0}lineFeed(){return this._dirtyRowTracker.markDirty(this._activeBuffer.y),this._optionsService.rawOptions.convertEol&&(this._activeBuffer.x=0),this._activeBuffer.y++,this._activeBuffer.y===this._activeBuffer.scrollBottom+1?(this._activeBuffer.y--,this._bufferService.scroll(this._eraseAttrData())):this._activeBuffer.y>=this._bufferService.rows?this._activeBuffer.y=this._bufferService.rows-1:this._activeBuffer.lines.get(this._activeBuffer.ybase+this._activeBuffer.y).isWrapped=!1,this._activeBuffer.x>=this._bufferService.cols&&this._activeBuffer.x--,this._dirtyRowTracker.markDirty(this._activeBuffer.y),this._onLineFeed.fire(),!0}carriageReturn(){return this._activeBuffer.x=0,!0}backspace(){var e;if(!this._coreService.decPrivateModes.reverseWraparound)return this._restrictCursor(),this._activeBuffer.x>0&&this._activeBuffer.x--,!0;if(this._restrictCursor(this._bufferService.cols),this._activeBuffer.x>0)this._activeBuffer.x--;else if(this._activeBuffer.x===0&&this._activeBuffer.y>this._activeBuffer.scrollTop&&this._activeBuffer.y<=this._activeBuffer.scrollBottom&&((e=this._activeBuffer.lines.get(this._activeBuffer.ybase+this._activeBuffer.y))!=null&&e.isWrapped)){this._activeBuffer.lines.get(this._activeBuffer.ybase+this._activeBuffer.y).isWrapped=!1,this._activeBuffer.y--,this._activeBuffer.x=this._bufferService.cols-1;let t=this._activeBuffer.lines.get(this._activeBuffer.ybase+this._activeBuffer.y);t.hasWidth(this._activeBuffer.x)&&!t.hasContent(this._activeBuffer.x)&&this._activeBuffer.x--}return this._restrictCursor(),!0}tab(){if(this._activeBuffer.x>=this._bufferService.cols)return!0;let e=this._activeBuffer.x;return this._activeBuffer.x=this._activeBuffer.nextStop(),this._optionsService.rawOptions.screenReaderMode&&this._onA11yTab.fire(this._activeBuffer.x-e),!0}shiftOut(){return this._charsetService.setgLevel(1),!0}shiftIn(){return this._charsetService.setgLevel(0),!0}_restrictCursor(e=this._bufferService.cols-1){this._activeBuffer.x=Math.min(e,Math.max(0,this._activeBuffer.x)),this._activeBuffer.y=this._coreService.decPrivateModes.origin?Math.min(this._activeBuffer.scrollBottom,Math.max(this._activeBuffer.scrollTop,this._activeBuffer.y)):Math.min(this._bufferService.rows-1,Math.max(0,this._activeBuffer.y)),this._dirtyRowTracker.markDirty(this._activeBuffer.y)}_setCursor(e,t){this._dirtyRowTracker.markDirty(this._activeBuffer.y),this._coreService.decPrivateModes.origin?(this._activeBuffer.x=e,this._activeBuffer.y=this._activeBuffer.scrollTop+t):(this._activeBuffer.x=e,this._activeBuffer.y=t),this._restrictCursor(),this._dirtyRowTracker.markDirty(this._activeBuffer.y)}_moveCursor(e,t){this._restrictCursor(),this._setCursor(this._activeBuffer.x+e,this._activeBuffer.y+t)}cursorUp(e){let t=this._activeBuffer.y-this._activeBuffer.scrollTop;return t>=0?this._moveCursor(0,-Math.min(t,e.params[0]||1)):this._moveCursor(0,-(e.params[0]||1)),!0}cursorDown(e){let t=this._activeBuffer.scrollBottom-this._activeBuffer.y;return t>=0?this._moveCursor(0,Math.min(t,e.params[0]||1)):this._moveCursor(0,e.params[0]||1),!0}cursorForward(e){return this._moveCursor(e.params[0]||1,0),!0}cursorBackward(e){return this._moveCursor(-(e.params[0]||1),0),!0}cursorNextLine(e){return this.cursorDown(e),this._activeBuffer.x=0,!0}cursorPrecedingLine(e){return this.cursorUp(e),this._activeBuffer.x=0,!0}cursorCharAbsolute(e){return this._setCursor((e.params[0]||1)-1,this._activeBuffer.y),!0}cursorPosition(e){return this._setCursor(e.length>=2?(e.params[1]||1)-1:0,(e.params[0]||1)-1),!0}charPosAbsolute(e){return this._setCursor((e.params[0]||1)-1,this._activeBuffer.y),!0}hPositionRelative(e){return this._moveCursor(e.params[0]||1,0),!0}linePosAbsolute(e){return this._setCursor(this._activeBuffer.x,(e.params[0]||1)-1),!0}vPositionRelative(e){return this._moveCursor(0,e.params[0]||1),!0}hVPosition(e){return this.cursorPosition(e),!0}tabClear(e){let t=e.params[0];return t===0?delete this._activeBuffer.tabs[this._activeBuffer.x]:t===3&&(this._activeBuffer.tabs={}),!0}cursorForwardTab(e){if(this._activeBuffer.x>=this._bufferService.cols)return!0;let t=e.params[0]||1;for(;t--;)this._activeBuffer.x=this._activeBuffer.nextStop();return!0}cursorBackwardTab(e){if(this._activeBuffer.x>=this._bufferService.cols)return!0;let t=e.params[0]||1;for(;t--;)this._activeBuffer.x=this._activeBuffer.prevStop();return!0}selectProtected(e){let t=e.params[0];return t===1&&(this._curAttrData.bg|=536870912),(t===2||t===0)&&(this._curAttrData.bg&=-536870913),!0}_eraseInBufferLine(e,t,i,r=!1,s=!1){let n=this._activeBuffer.lines.get(this._activeBuffer.ybase+e);n.replaceCells(t,i,this._activeBuffer.getNullCell(this._eraseAttrData()),s),r&&(n.isWrapped=!1)}_resetBufferLine(e,t=!1){let i=this._activeBuffer.lines.get(this._activeBuffer.ybase+e);i&&(i.fill(this._activeBuffer.getNullCell(this._eraseAttrData()),t),this._bufferService.buffer.clearMarkers(this._activeBuffer.ybase+e),i.isWrapped=!1)}eraseInDisplay(e,t=!1){var r;this._restrictCursor(this._bufferService.cols);let i;switch(e.params[0]){case 0:for(i=this._activeBuffer.y,this._dirtyRowTracker.markDirty(i),this._eraseInBufferLine(i++,this._activeBuffer.x,this._bufferService.cols,this._activeBuffer.x===0,t);i<this._bufferService.rows;i++)this._resetBufferLine(i,t);this._dirtyRowTracker.markDirty(i);break;case 1:for(i=this._activeBuffer.y,this._dirtyRowTracker.markDirty(i),this._eraseInBufferLine(i,0,this._activeBuffer.x+1,!0,t),this._activeBuffer.x+1>=this._bufferService.cols&&(this._activeBuffer.lines.get(i+1).isWrapped=!1);i--;)this._resetBufferLine(i,t);this._dirtyRowTracker.markDirty(0);break;case 2:if(this._optionsService.rawOptions.scrollOnEraseInDisplay){for(i=this._bufferService.rows,this._dirtyRowTracker.markRangeDirty(0,i-1);i--&&!((r=this._activeBuffer.lines.get(this._activeBuffer.ybase+i))!=null&&r.getTrimmedLength()););for(;i>=0;i--)this._bufferService.scroll(this._eraseAttrData())}else{for(i=this._bufferService.rows,this._dirtyRowTracker.markDirty(i-1);i--;)this._resetBufferLine(i,t);this._dirtyRowTracker.markDirty(0)}break;case 3:let s=this._activeBuffer.lines.length-this._bufferService.rows;s>0&&(this._activeBuffer.lines.trimStart(s),this._activeBuffer.ybase=Math.max(this._activeBuffer.ybase-s,0),this._activeBuffer.ydisp=Math.max(this._activeBuffer.ydisp-s,0),this._onScroll.fire(0));break}return!0}eraseInLine(e,t=!1){switch(this._restrictCursor(this._bufferService.cols),e.params[0]){case 0:this._eraseInBufferLine(this._activeBuffer.y,this._activeBuffer.x,this._bufferService.cols,this._activeBuffer.x===0,t);break;case 1:this._eraseInBufferLine(this._activeBuffer.y,0,this._activeBuffer.x+1,!1,t);break;case 2:this._eraseInBufferLine(this._activeBuffer.y,0,this._bufferService.cols,!0,t);break}return this._dirtyRowTracker.markDirty(this._activeBuffer.y),!0}insertLines(e){this._restrictCursor();let t=e.params[0]||1;if(this._activeBuffer.y>this._activeBuffer.scrollBottom||this._activeBuffer.y<this._activeBuffer.scrollTop)return!0;let i=this._activeBuffer.ybase+this._activeBuffer.y,r=this._bufferService.rows-1-this._activeBuffer.scrollBottom,s=this._bufferService.rows-1+this._activeBuffer.ybase-r+1;for(;t--;)this._activeBuffer.lines.splice(s-1,1),this._activeBuffer.lines.splice(i,0,this._activeBuffer.getBlankLine(this._eraseAttrData()));return this._dirtyRowTracker.markRangeDirty(this._activeBuffer.y,this._activeBuffer.scrollBottom),this._activeBuffer.x=0,!0}deleteLines(e){this._restrictCursor();let t=e.params[0]||1;if(this._activeBuffer.y>this._activeBuffer.scrollBottom||this._activeBuffer.y<this._activeBuffer.scrollTop)return!0;let i=this._activeBuffer.ybase+this._activeBuffer.y,r;for(r=this._bufferService.rows-1-this._activeBuffer.scrollBottom,r=this._bufferService.rows-1+this._activeBuffer.ybase-r;t--;)this._activeBuffer.lines.splice(i,1),this._activeBuffer.lines.splice(r,0,this._activeBuffer.getBlankLine(this._eraseAttrData()));return this._dirtyRowTracker.markRangeDirty(this._activeBuffer.y,this._activeBuffer.scrollBottom),this._activeBuffer.x=0,!0}insertChars(e){this._restrictCursor();let t=this._activeBuffer.lines.get(this._activeBuffer.ybase+this._activeBuffer.y);return t&&(t.insertCells(this._activeBuffer.x,e.params[0]||1,this._activeBuffer.getNullCell(this._eraseAttrData())),this._dirtyRowTracker.markDirty(this._activeBuffer.y)),!0}deleteChars(e){this._restrictCursor();let t=this._activeBuffer.lines.get(this._activeBuffer.ybase+this._activeBuffer.y);return t&&(t.deleteCells(this._activeBuffer.x,e.params[0]||1,this._activeBuffer.getNullCell(this._eraseAttrData())),this._dirtyRowTracker.markDirty(this._activeBuffer.y)),!0}scrollUp(e){let t=e.params[0]||1;for(;t--;)this._activeBuffer.lines.splice(this._activeBuffer.ybase+this._activeBuffer.scrollTop,1),this._activeBuffer.lines.splice(this._activeBuffer.ybase+this._activeBuffer.scrollBottom,0,this._activeBuffer.getBlankLine(this._eraseAttrData()));return this._dirtyRowTracker.markRangeDirty(this._activeBuffer.scrollTop,this._activeBuffer.scrollBottom),!0}scrollDown(e){let t=e.params[0]||1;for(;t--;)this._activeBuffer.lines.splice(this._activeBuffer.ybase+this._activeBuffer.scrollBottom,1),this._activeBuffer.lines.splice(this._activeBuffer.ybase+this._activeBuffer.scrollTop,0,this._activeBuffer.getBlankLine(It));return this._dirtyRowTracker.markRangeDirty(this._activeBuffer.scrollTop,this._activeBuffer.scrollBottom),!0}scrollLeft(e){if(this._activeBuffer.y>this._activeBuffer.scrollBottom||this._activeBuffer.y<this._activeBuffer.scrollTop)return!0;let t=e.params[0]||1;for(let i=this._activeBuffer.scrollTop;i<=this._activeBuffer.scrollBottom;++i){let r=this._activeBuffer.lines.get(this._activeBuffer.ybase+i);r.deleteCells(0,t,this._activeBuffer.getNullCell(this._eraseAttrData())),r.isWrapped=!1}return this._dirtyRowTracker.markRangeDirty(this._activeBuffer.scrollTop,this._activeBuffer.scrollBottom),!0}scrollRight(e){if(this._activeBuffer.y>this._activeBuffer.scrollBottom||this._activeBuffer.y<this._activeBuffer.scrollTop)return!0;let t=e.params[0]||1;for(let i=this._activeBuffer.scrollTop;i<=this._activeBuffer.scrollBottom;++i){let r=this._activeBuffer.lines.get(this._activeBuffer.ybase+i);r.insertCells(0,t,this._activeBuffer.getNullCell(this._eraseAttrData())),r.isWrapped=!1}return this._dirtyRowTracker.markRangeDirty(this._activeBuffer.scrollTop,this._activeBuffer.scrollBottom),!0}insertColumns(e){if(this._activeBuffer.y>this._activeBuffer.scrollBottom||this._activeBuffer.y<this._activeBuffer.scrollTop)return!0;let t=e.params[0]||1;for(let i=this._activeBuffer.scrollTop;i<=this._activeBuffer.scrollBottom;++i){let r=this._activeBuffer.lines.get(this._activeBuffer.ybase+i);r.insertCells(this._activeBuffer.x,t,this._activeBuffer.getNullCell(this._eraseAttrData())),r.isWrapped=!1}return this._dirtyRowTracker.markRangeDirty(this._activeBuffer.scrollTop,this._activeBuffer.scrollBottom),!0}deleteColumns(e){if(this._activeBuffer.y>this._activeBuffer.scrollBottom||this._activeBuffer.y<this._activeBuffer.scrollTop)return!0;let t=e.params[0]||1;for(let i=this._activeBuffer.scrollTop;i<=this._activeBuffer.scrollBottom;++i){let r=this._activeBuffer.lines.get(this._activeBuffer.ybase+i);r.deleteCells(this._activeBuffer.x,t,this._activeBuffer.getNullCell(this._eraseAttrData())),r.isWrapped=!1}return this._dirtyRowTracker.markRangeDirty(this._activeBuffer.scrollTop,this._activeBuffer.scrollBottom),!0}eraseChars(e){this._restrictCursor();let t=this._activeBuffer.lines.get(this._activeBuffer.ybase+this._activeBuffer.y);return t&&(t.replaceCells(this._activeBuffer.x,this._activeBuffer.x+(e.params[0]||1),this._activeBuffer.getNullCell(this._eraseAttrData())),this._dirtyRowTracker.markDirty(this._activeBuffer.y)),!0}repeatPrecedingCharacter(e){let t=this._parser.precedingJoinState;if(!t)return!0;let i=e.params[0]||1,r=Gs.extractWidth(t),s=this._activeBuffer.x-r,n=this._activeBuffer.lines.get(this._activeBuffer.ybase+this._activeBuffer.y).getString(s),a=new Uint32Array(n.length*i),o=0;for(let c=0;c<n.length;){let u=n.codePointAt(c)||0;a[o++]=u,c+=u>65535?2:1}let l=o;for(let c=1;c<i;++c)a.copyWithin(l,0,o),l+=o;return this.print(a,0,l),!0}sendDeviceAttributesPrimary(e){return e.params[0]>0||(this._is("xterm")||this._is("rxvt-unicode")||this._is("screen")?this._coreService.triggerDataEvent(ve.ESC+"[?1;2c"):this._is("linux")&&this._coreService.triggerDataEvent(ve.ESC+"[?6c")),!0}sendDeviceAttributesSecondary(e){return e.params[0]>0||(this._is("xterm")?this._coreService.triggerDataEvent(ve.ESC+"[>0;276;0c"):this._is("rxvt-unicode")?this._coreService.triggerDataEvent(ve.ESC+"[>85;95;0c"):this._is("linux")?this._coreService.triggerDataEvent(e.params[0]+"c"):this._is("screen")&&this._coreService.triggerDataEvent(ve.ESC+"[>83;40003;0c")),!0}_is(e){return(this._optionsService.rawOptions.termName+"").indexOf(e)===0}setMode(e){for(let t=0;t<e.length;t++)switch(e.params[t]){case 4:this._coreService.modes.insertMode=!0;break;case 20:this._optionsService.options.convertEol=!0;break}return!0}setModePrivate(e){for(let t=0;t<e.length;t++)switch(e.params[t]){case 1:this._coreService.decPrivateModes.applicationCursorKeys=!0;break;case 2:this._charsetService.setgCharset(0,zs),this._charsetService.setgCharset(1,zs),this._charsetService.setgCharset(2,zs),this._charsetService.setgCharset(3,zs);break;case 3:this._optionsService.rawOptions.windowOptions.setWinLines&&(this._bufferService.resize(132,this._bufferService.rows),this._onRequestReset.fire());break;case 6:this._coreService.decPrivateModes.origin=!0,this._setCursor(0,0);break;case 7:this._coreService.decPrivateModes.wraparound=!0;break;case 12:this._optionsService.options.cursorBlink=!0;break;case 45:this._coreService.decPrivateModes.reverseWraparound=!0;break;case 66:this._logService.debug("Serial port requested application keypad."),this._coreService.decPrivateModes.applicationKeypad=!0,this._onRequestSyncScrollBar.fire();break;case 9:this._coreMouseService.activeProtocol="X10";break;case 1e3:this._coreMouseService.activeProtocol="VT200";break;case 1002:this._coreMouseService.activeProtocol="DRAG";break;case 1003:this._coreMouseService.activeProtocol="ANY";break;case 1004:this._coreService.decPrivateModes.sendFocus=!0,this._onRequestSendFocus.fire();break;case 1005:this._logService.debug("DECSET 1005 not supported (see #2507)");break;case 1006:this._coreMouseService.activeEncoding="SGR";break;case 1015:this._logService.debug("DECSET 1015 not supported (see #2507)");break;case 1016:this._coreMouseService.activeEncoding="SGR_PIXELS";break;case 25:this._coreService.isCursorHidden=!1;break;case 1048:this.saveCursor();break;case 1049:this.saveCursor();case 47:case 1047:this._bufferService.buffers.activateAltBuffer(this._eraseAttrData()),this._coreService.isCursorInitialized=!0,this._onRequestRefreshRows.fire(void 0),this._onRequestSyncScrollBar.fire();break;case 2004:this._coreService.decPrivateModes.bracketedPasteMode=!0;break;case 2026:this._coreService.decPrivateModes.synchronizedOutput=!0;break}return!0}resetMode(e){for(let t=0;t<e.length;t++)switch(e.params[t]){case 4:this._coreService.modes.insertMode=!1;break;case 20:this._optionsService.options.convertEol=!1;break}return!0}resetModePrivate(e){for(let t=0;t<e.length;t++)switch(e.params[t]){case 1:this._coreService.decPrivateModes.applicationCursorKeys=!1;break;case 3:this._optionsService.rawOptions.windowOptions.setWinLines&&(this._bufferService.resize(80,this._bufferService.rows),this._onRequestReset.fire());break;case 6:this._coreService.decPrivateModes.origin=!1,this._setCursor(0,0);break;case 7:this._coreService.decPrivateModes.wraparound=!1;break;case 12:this._optionsService.options.cursorBlink=!1;break;case 45:this._coreService.decPrivateModes.reverseWraparound=!1;break;case 66:this._logService.debug("Switching back to normal keypad."),this._coreService.decPrivateModes.applicationKeypad=!1,this._onRequestSyncScrollBar.fire();break;case 9:case 1e3:case 1002:case 1003:this._coreMouseService.activeProtocol="NONE";break;case 1004:this._coreService.decPrivateModes.sendFocus=!1;break;case 1005:this._logService.debug("DECRST 1005 not supported (see #2507)");break;case 1006:this._coreMouseService.activeEncoding="DEFAULT";break;case 1015:this._logService.debug("DECRST 1015 not supported (see #2507)");break;case 1016:this._coreMouseService.activeEncoding="DEFAULT";break;case 25:this._coreService.isCursorHidden=!0;break;case 1048:this.restoreCursor();break;case 1049:case 47:case 1047:this._bufferService.buffers.activateNormalBuffer(),e.params[t]===1049&&this.restoreCursor(),this._coreService.isCursorInitialized=!0,this._onRequestRefreshRows.fire(void 0),this._onRequestSyncScrollBar.fire();break;case 2004:this._coreService.decPrivateModes.bracketedPasteMode=!1;break;case 2026:this._coreService.decPrivateModes.synchronizedOutput=!1,this._onRequestRefreshRows.fire(void 0);break}return!0}requestMode(e,t){(_=>(_[_.NOT_RECOGNIZED=0]="NOT_RECOGNIZED",_[_.SET=1]="SET",_[_.RESET=2]="RESET",_[_.PERMANENTLY_SET=3]="PERMANENTLY_SET",_[_.PERMANENTLY_RESET=4]="PERMANENTLY_RESET"))(void 0||(i={}));let r=this._coreService.decPrivateModes,{activeProtocol:s,activeEncoding:n}=this._coreMouseService,a=this._coreService,{buffers:o,cols:l}=this._bufferService,{active:c,alt:u}=o,h=this._optionsService.rawOptions,d=(_,y)=>(a.triggerDataEvent(`${ve.ESC}[${t?"":"?"}${_};${y}$y`),!0),f=_=>_?1:2,m=e.params[0];return t?m===2?d(m,4):m===4?d(m,f(a.modes.insertMode)):m===12?d(m,3):m===20?d(m,f(h.convertEol)):d(m,0):m===1?d(m,f(r.applicationCursorKeys)):m===3?d(m,h.windowOptions.setWinLines?l===80?2:l===132?1:0:0):m===6?d(m,f(r.origin)):m===7?d(m,f(r.wraparound)):m===8?d(m,3):m===9?d(m,f(s==="X10")):m===12?d(m,f(h.cursorBlink)):m===25?d(m,f(!a.isCursorHidden)):m===45?d(m,f(r.reverseWraparound)):m===66?d(m,f(r.applicationKeypad)):m===67?d(m,4):m===1e3?d(m,f(s==="VT200")):m===1002?d(m,f(s==="DRAG")):m===1003?d(m,f(s==="ANY")):m===1004?d(m,f(r.sendFocus)):m===1005?d(m,4):m===1006?d(m,f(n==="SGR")):m===1015?d(m,4):m===1016?d(m,f(n==="SGR_PIXELS")):m===1048?d(m,1):m===47||m===1047||m===1049?d(m,f(c===u)):m===2004?d(m,f(r.bracketedPasteMode)):m===2026?d(m,f(r.synchronizedOutput)):d(m,0)}_updateAttrColor(e,t,i,r,s){return t===2?(e|=50331648,e&=-16777216,e|=Ll.fromColorRGB([i,r,s])):t===5&&(e&=-50331904,e|=33554432|i&255),e}_extractColor(e,t,i){let r=[0,0,-1,0,0,0],s=0,n=0;do{if(r[n+s]=e.params[t+n],e.hasSubParams(t+n)){let a=e.getSubParams(t+n),o=0;do r[1]===5&&(s=1),r[n+o+1+s]=a[o];while(++o<a.length&&o+n+1+s<r.length);break}if(r[1]===5&&n+s>=2||r[1]===2&&n+s>=5)break;r[1]&&(s=1)}while(++n+t<e.length&&n+s<r.length);for(let a=2;a<r.length;++a)r[a]===-1&&(r[a]=0);switch(r[0]){case 38:i.fg=this._updateAttrColor(i.fg,r[1],r[3],r[4],r[5]);break;case 48:i.bg=this._updateAttrColor(i.bg,r[1],r[3],r[4],r[5]);break;case 58:i.extended=i.extended.clone(),i.extended.underlineColor=this._updateAttrColor(i.extended.underlineColor,r[1],r[3],r[4],r[5])}return n}_processUnderline(e,t){t.extended=t.extended.clone(),(!~e||e>5)&&(e=1),t.extended.underlineStyle=e,t.fg|=268435456,e===0&&(t.fg&=-268435457),t.updateExtended()}_processSGR0(e){e.fg=It.fg,e.bg=It.bg,e.extended=e.extended.clone(),e.extended.underlineStyle=0,e.extended.underlineColor&=-67108864,e.updateExtended()}charAttributes(e){if(e.length===1&&e.params[0]===0)return this._processSGR0(this._curAttrData),!0;let t=e.length,i,r=this._curAttrData;for(let s=0;s<t;s++)i=e.params[s],i>=30&&i<=37?(r.fg&=-50331904,r.fg|=16777216|i-30):i>=40&&i<=47?(r.bg&=-50331904,r.bg|=16777216|i-40):i>=90&&i<=97?(r.fg&=-50331904,r.fg|=16777216|i-90|8):i>=100&&i<=107?(r.bg&=-50331904,r.bg|=16777216|i-100|8):i===0?this._processSGR0(r):i===1?r.fg|=134217728:i===3?r.bg|=67108864:i===4?(r.fg|=268435456,this._processUnderline(e.hasSubParams(s)?e.getSubParams(s)[0]:1,r)):i===5?r.fg|=536870912:i===7?r.fg|=67108864:i===8?r.fg|=1073741824:i===9?r.fg|=2147483648:i===2?r.bg|=134217728:i===21?this._processUnderline(2,r):i===22?(r.fg&=-134217729,r.bg&=-134217729):i===23?r.bg&=-67108865:i===24?(r.fg&=-268435457,this._processUnderline(0,r)):i===25?r.fg&=-536870913:i===27?r.fg&=-67108865:i===28?r.fg&=-1073741825:i===29?r.fg&=2147483647:i===39?(r.fg&=-67108864,r.fg|=It.fg&16777215):i===49?(r.bg&=-67108864,r.bg|=It.bg&16777215):i===38||i===48||i===58?s+=this._extractColor(e,s,r):i===53?r.bg|=1073741824:i===55?r.bg&=-1073741825:i===59?(r.extended=r.extended.clone(),r.extended.underlineColor=-1,r.updateExtended()):i===100?(r.fg&=-67108864,r.fg|=It.fg&16777215,r.bg&=-67108864,r.bg|=It.bg&16777215):this._logService.debug("Unknown SGR attribute: %d.",i);return!0}deviceStatus(e){switch(e.params[0]){case 5:this._coreService.triggerDataEvent(`${ve.ESC}[0n`);break;case 6:let t=this._activeBuffer.y+1,i=this._activeBuffer.x+1;this._coreService.triggerDataEvent(`${ve.ESC}[${t};${i}R`);break}return!0}deviceStatusPrivate(e){switch(e.params[0]){case 6:let t=this._activeBuffer.y+1,i=this._activeBuffer.x+1;this._coreService.triggerDataEvent(`${ve.ESC}[?${t};${i}R`);break}return!0}softReset(e){return this._coreService.isCursorHidden=!1,this._onRequestSyncScrollBar.fire(),this._activeBuffer.scrollTop=0,this._activeBuffer.scrollBottom=this._bufferService.rows-1,this._curAttrData=It.clone(),this._coreService.reset(),this._charsetService.reset(),this._activeBuffer.savedX=0,this._activeBuffer.savedY=this._activeBuffer.ybase,this._activeBuffer.savedCurAttrData.fg=this._curAttrData.fg,this._activeBuffer.savedCurAttrData.bg=this._curAttrData.bg,this._activeBuffer.savedCharset=this._charsetService.charset,this._coreService.decPrivateModes.origin=!1,!0}setCursorStyle(e){let t=e.length===0?1:e.params[0];if(t===0)this._coreService.decPrivateModes.cursorStyle=void 0,this._coreService.decPrivateModes.cursorBlink=void 0;else{switch(t){case 1:case 2:this._coreService.decPrivateModes.cursorStyle="block";break;case 3:case 4:this._coreService.decPrivateModes.cursorStyle="underline";break;case 5:case 6:this._coreService.decPrivateModes.cursorStyle="bar";break}let i=t%2===1;this._coreService.decPrivateModes.cursorBlink=i}return!0}setScrollRegion(e){let t=e.params[0]||1,i;return(e.length<2||(i=e.params[1])>this._bufferService.rows||i===0)&&(i=this._bufferService.rows),i>t&&(this._activeBuffer.scrollTop=t-1,this._activeBuffer.scrollBottom=i-1,this._setCursor(0,0)),!0}windowOptions(e){if(!ip(e.params[0],this._optionsService.rawOptions.windowOptions))return!0;let t=e.length>1?e.params[1]:0;switch(e.params[0]){case 14:t!==2&&this._onRequestWindowsOptionsReport.fire(0);break;case 16:this._onRequestWindowsOptionsReport.fire(1);break;case 18:this._bufferService&&this._coreService.triggerDataEvent(`${ve.ESC}[8;${this._bufferService.rows};${this._bufferService.cols}t`);break;case 22:(t===0||t===2)&&(this._windowTitleStack.push(this._windowTitle),this._windowTitleStack.length>tp&&this._windowTitleStack.shift()),(t===0||t===1)&&(this._iconNameStack.push(this._iconName),this._iconNameStack.length>tp&&this._iconNameStack.shift());break;case 23:(t===0||t===2)&&this._windowTitleStack.length&&this.setTitle(this._windowTitleStack.pop()),(t===0||t===1)&&this._iconNameStack.length&&this.setIconName(this._iconNameStack.pop());break}return!0}saveCursor(e){return this._activeBuffer.savedX=this._activeBuffer.x,this._activeBuffer.savedY=this._activeBuffer.ybase+this._activeBuffer.y,this._activeBuffer.savedCurAttrData.fg=this._curAttrData.fg,this._activeBuffer.savedCurAttrData.bg=this._curAttrData.bg,this._activeBuffer.savedCharset=this._charsetService.charset,!0}restoreCursor(e){return this._activeBuffer.x=this._activeBuffer.savedX||0,this._activeBuffer.y=Math.max(this._activeBuffer.savedY-this._activeBuffer.ybase,0),this._curAttrData.fg=this._activeBuffer.savedCurAttrData.fg,this._curAttrData.bg=this._activeBuffer.savedCurAttrData.bg,this._charsetService.charset=this._savedCharset,this._activeBuffer.savedCharset&&(this._charsetService.charset=this._activeBuffer.savedCharset),this._restrictCursor(),!0}setTitle(e){return this._windowTitle=e,this._onTitleChange.fire(e),!0}setIconName(e){return this._iconName=e,!0}setOrReportIndexedColor(e){let t=[],i=e.split(";");for(;i.length>1;){let r=i.shift(),s=i.shift();if(/^\d+$/.exec(r)){let n=parseInt(r);if(np(n))if(s==="?")t.push({type:0,index:n});else{let a=ep(s);a&&t.push({type:1,index:n,color:a})}}}return t.length&&this._onColor.fire(t),!0}setHyperlink(e){let t=e.indexOf(";");if(t===-1)return!0;let i=e.slice(0,t).trim(),r=e.slice(t+1);return r?this._createHyperlink(i,r):i.trim()?!1:this._finishHyperlink()}_createHyperlink(e,t){this._getCurrentLinkId()&&this._finishHyperlink();let i=e.split(":"),r,s=i.findIndex(n=>n.startsWith("id="));return s!==-1&&(r=i[s].slice(3)||void 0),this._curAttrData.extended=this._curAttrData.extended.clone(),this._curAttrData.extended.urlId=this._oscLinkService.registerLink({id:r,uri:t}),this._curAttrData.updateExtended(),!0}_finishHyperlink(){return this._curAttrData.extended=this._curAttrData.extended.clone(),this._curAttrData.extended.urlId=0,this._curAttrData.updateExtended(),!0}_setOrReportSpecialColor(e,t){let i=e.split(";");for(let r=0;r<i.length&&!(t>=this._specialColors.length);++r,++t)if(i[r]==="?")this._onColor.fire([{type:0,index:this._specialColors[t]}]);else{let s=ep(i[r]);s&&this._onColor.fire([{type:1,index:this._specialColors[t],color:s}])}return!0}setOrReportFgColor(e){return this._setOrReportSpecialColor(e,0)}setOrReportBgColor(e){return this._setOrReportSpecialColor(e,1)}setOrReportCursorColor(e){return this._setOrReportSpecialColor(e,2)}restoreIndexedColor(e){if(!e)return this._onColor.fire([{type:2}]),!0;let t=[],i=e.split(";");for(let r=0;r<i.length;++r)if(/^\d+$/.exec(i[r])){let s=parseInt(i[r]);np(s)&&t.push({type:2,index:s})}return t.length&&this._onColor.fire(t),!0}restoreFgColor(e){return this._onColor.fire([{type:2,index:256}]),!0}restoreBgColor(e){return this._onColor.fire([{type:2,index:257}]),!0}restoreCursorColor(e){return this._onColor.fire([{type:2,index:258}]),!0}nextLine(){return this._activeBuffer.x=0,this.index(),!0}keypadApplicationMode(){return this._logService.debug("Serial port requested application keypad."),this._coreService.decPrivateModes.applicationKeypad=!0,this._onRequestSyncScrollBar.fire(),!0}keypadNumericMode(){return this._logService.debug("Switching back to normal keypad."),this._coreService.decPrivateModes.applicationKeypad=!1,this._onRequestSyncScrollBar.fire(),!0}selectDefaultCharset(){return this._charsetService.setgLevel(0),this._charsetService.setgCharset(0,zs),!0}selectCharset(e){return e.length!==2?(this.selectDefaultCharset(),!0):(e[0]==="/"||this._charsetService.setgCharset(cU[e[0]],Wt[e[1]]||zs),!0)}index(){return this._restrictCursor(),this._activeBuffer.y++,this._activeBuffer.y===this._activeBuffer.scrollBottom+1?(this._activeBuffer.y--,this._bufferService.scroll(this._eraseAttrData())):this._activeBuffer.y>=this._bufferService.rows&&(this._activeBuffer.y=this._bufferService.rows-1),this._restrictCursor(),!0}tabSet(){return this._activeBuffer.tabs[this._activeBuffer.x]=!0,!0}reverseIndex(){if(this._restrictCursor(),this._activeBuffer.y===this._activeBuffer.scrollTop){let e=this._activeBuffer.scrollBottom-this._activeBuffer.scrollTop;this._activeBuffer.lines.shiftElements(this._activeBuffer.ybase+this._activeBuffer.y,e,1),this._activeBuffer.lines.set(this._activeBuffer.ybase+this._activeBuffer.y,this._activeBuffer.getBlankLine(this._eraseAttrData())),this._dirtyRowTracker.markRangeDirty(this._activeBuffer.scrollTop,this._activeBuffer.scrollBottom)}else this._activeBuffer.y--,this._restrictCursor();return!0}fullReset(){return this._parser.reset(),this._onRequestReset.fire(),!0}reset(){this._curAttrData=It.clone(),this._eraseAttrDataInternal=It.clone()}_eraseAttrData(){return this._eraseAttrDataInternal.bg&=-67108864,this._eraseAttrDataInternal.bg|=this._curAttrData.bg&67108863,this._eraseAttrDataInternal}setgLevel(e){return this._charsetService.setgLevel(e),!0}screenAlignmentPattern(){let e=new Ki;e.content=1<<22|69,e.fg=this._curAttrData.fg,e.bg=this._curAttrData.bg,this._setCursor(0,0);for(let t=0;t<this._bufferService.rows;++t){let i=this._activeBuffer.ybase+this._activeBuffer.y+t,r=this._activeBuffer.lines.get(i);r&&(r.fill(e),r.isWrapped=!1)}return this._dirtyRowTracker.markAllDirty(),this._setCursor(0,0),!0}requestStatusString(e,t){let i=a=>(this._coreService.triggerDataEvent(`${ve.ESC}${a}${ve.ESC}\\`),!0),r=this._bufferService.buffer,s=this._optionsService.rawOptions;return i(e==='"q'?`P1$r${this._curAttrData.isProtected()?1:0}"q`:e==='"p'?'P1$r61;1"p':e==="r"?`P1$r${r.scrollTop+1};${r.scrollBottom+1}r`:e==="m"?"P1$r0m":e===" q"?`P1$r${{block:2,underline:4,bar:6}[s.cursorStyle]-(s.cursorBlink?1:0)} q`:"P0$r")}markRangeDirty(e,t){this._dirtyRowTracker.markRangeDirty(e,t)}},Mh=class{constructor(e){this._bufferService=e,this.clearRange()}clearRange(){this.start=this._bufferService.buffer.y,this.end=this._bufferService.buffer.y}markDirty(e){e<this.start?this.start=e:e>this.end&&(this.end=e)}markRangeDirty(e,t){e>t&&(sp=e,e=t,t=sp),e<this.start&&(this.start=e),t>this.end&&(this.end=t)}markAllDirty(){this.markRangeDirty(0,this._bufferService.rows-1)}};Mh=Tt([Te(0,Ai)],Mh);function np(e){return 0<=e&&e<256}var hU=5e7,ap=12,dU=50,fU=class extends qe{constructor(e){super(),this._action=e,this._writeBuffer=[],this._callbacks=[],this._pendingData=0,this._bufferOffset=0,this._isSyncWriting=!1,this._syncCalls=0,this._didUserInput=!1,this._onWriteParsed=this._register(new Ae),this.onWriteParsed=this._onWriteParsed.event}handleUserInput(){this._didUserInput=!0}writeSync(e,t){if(t!==void 0&&this._syncCalls>t){this._syncCalls=0;return}if(this._pendingData+=e.length,this._writeBuffer.push(e),this._callbacks.push(void 0),this._syncCalls++,this._isSyncWriting)return;this._isSyncWriting=!0;let i;for(;i=this._writeBuffer.shift();){this._action(i);let r=this._callbacks.shift();r&&r()}this._pendingData=0,this._bufferOffset=2147483647,this._isSyncWriting=!1,this._syncCalls=0}write(e,t){if(this._pendingData>hU)throw new Error("write data discarded, use flow control to avoid losing data");if(!this._writeBuffer.length){if(this._bufferOffset=0,this._didUserInput){this._didUserInput=!1,this._pendingData+=e.length,this._writeBuffer.push(e),this._callbacks.push(t),this._innerWrite();return}setTimeout(()=>this._innerWrite())}this._pendingData+=e.length,this._writeBuffer.push(e),this._callbacks.push(t)}_innerWrite(e=0,t=!0){let i=e||performance.now();for(;this._writeBuffer.length>this._bufferOffset;){let r=this._writeBuffer[this._bufferOffset],s=this._action(r,t);if(s){let a=o=>performance.now()-i>=ap?setTimeout(()=>this._innerWrite(0,o)):this._innerWrite(i,o);s.catch(o=>(queueMicrotask(()=>{throw o}),Promise.resolve(!1))).then(a);return}let n=this._callbacks[this._bufferOffset];if(n&&n(),this._bufferOffset++,this._pendingData-=r.length,performance.now()-i>=ap)break}this._writeBuffer.length>this._bufferOffset?(this._bufferOffset>dU&&(this._writeBuffer=this._writeBuffer.slice(this._bufferOffset),this._callbacks=this._callbacks.slice(this._bufferOffset),this._bufferOffset=0),setTimeout(()=>this._innerWrite())):(this._writeBuffer.length=0,this._callbacks.length=0,this._pendingData=0,this._bufferOffset=0),this._onWriteParsed.fire()}},Lh=class{constructor(e){this._bufferService=e,this._nextId=1,this._entriesWithId=new Map,this._dataByLinkId=new Map}registerLink(e){let t=this._bufferService.buffer;if(e.id===void 0){let o=t.addMarker(t.ybase+t.y),l={data:e,id:this._nextId++,lines:[o]};return o.onDispose(()=>this._removeMarkerFromLink(l,o)),this._dataByLinkId.set(l.id,l),l.id}let i=e,r=this._getEntryIdKey(i),s=this._entriesWithId.get(r);if(s)return this.addLineToLink(s.id,t.ybase+t.y),s.id;let n=t.addMarker(t.ybase+t.y),a={id:this._nextId++,key:this._getEntryIdKey(i),data:i,lines:[n]};return n.onDispose(()=>this._removeMarkerFromLink(a,n)),this._entriesWithId.set(a.key,a),this._dataByLinkId.set(a.id,a),a.id}addLineToLink(e,t){let i=this._dataByLinkId.get(e);if(i&&i.lines.every(r=>r.line!==t)){let r=this._bufferService.buffer.addMarker(t);i.lines.push(r),r.onDispose(()=>this._removeMarkerFromLink(i,r))}}getLinkData(e){var t;return(t=this._dataByLinkId.get(e))==null?void 0:t.data}_getEntryIdKey(e){return`${e.id};;${e.uri}`}_removeMarkerFromLink(e,t){let i=e.lines.indexOf(t);i!==-1&&(e.lines.splice(i,1),e.lines.length===0&&(e.data.id!==void 0&&this._entriesWithId.delete(e.key),this._dataByLinkId.delete(e.id)))}};Lh=Tt([Te(0,Ai)],Lh);var op=!1,pU=class extends qe{constructor(e){super(),this._windowsWrappingHeuristics=this._register(new Kn),this._onBinary=this._register(new Ae),this.onBinary=this._onBinary.event,this._onData=this._register(new Ae),this.onData=this._onData.event,this._onLineFeed=this._register(new Ae),this.onLineFeed=this._onLineFeed.event,this._onResize=this._register(new Ae),this.onResize=this._onResize.event,this._onWriteParsed=this._register(new Ae),this.onWriteParsed=this._onWriteParsed.event,this._onScroll=this._register(new Ae),this._instantiationService=new Dz,this.optionsService=this._register(new qz(e)),this._instantiationService.setService(Mi,this.optionsService),this._bufferService=this._register(this._instantiationService.createInstance(Sh)),this._instantiationService.setService(Ai,this._bufferService),this._logService=this._register(this._instantiationService.createInstance(wh)),this._instantiationService.setService(nv,this._logService),this.coreService=this._register(this._instantiationService.createInstance(Ch)),this._instantiationService.setService(cn,this.coreService),this.coreMouseService=this._register(this._instantiationService.createInstance(kh)),this._instantiationService.setService(sv,this.coreMouseService),this.unicodeService=this._register(this._instantiationService.createInstance(Gs)),this._instantiationService.setService(PZ,this.unicodeService),this._charsetService=this._instantiationService.createInstance(Qz),this._instantiationService.setService(HZ,this._charsetService),this._oscLinkService=this._instantiationService.createInstance(Lh),this._instantiationService.setService(av,this._oscLinkService),this._inputHandler=this._register(new uU(this._bufferService,this._charsetService,this.coreService,this._logService,this.optionsService,this._oscLinkService,this.coreMouseService,this.unicodeService)),this._register(si.forward(this._inputHandler.onLineFeed,this._onLineFeed)),this._register(this._inputHandler),this._register(si.forward(this._bufferService.onResize,this._onResize)),this._register(si.forward(this.coreService.onData,this._onData)),this._register(si.forward(this.coreService.onBinary,this._onBinary)),this._register(this.coreService.onRequestScrollToBottom(()=>this.scrollToBottom(!0))),this._register(this.coreService.onUserInput(()=>this._writeBuffer.handleUserInput())),this._register(this.optionsService.onMultipleOptionChange(["windowsMode","windowsPty"],()=>this._handleWindowsPtyOptionChange())),this._register(this._bufferService.onScroll(()=>{this._onScroll.fire({position:this._bufferService.buffer.ydisp}),this._inputHandler.markRangeDirty(this._bufferService.buffer.scrollTop,this._bufferService.buffer.scrollBottom)})),this._writeBuffer=this._register(new fU((t,i)=>this._inputHandler.parse(t,i))),this._register(si.forward(this._writeBuffer.onWriteParsed,this._onWriteParsed))}get onScroll(){return this._onScrollApi||(this._onScrollApi=this._register(new Ae),this._onScroll.event(e=>{var t;(t=this._onScrollApi)==null||t.fire(e.position)})),this._onScrollApi.event}get cols(){return this._bufferService.cols}get rows(){return this._bufferService.rows}get buffers(){return this._bufferService.buffers}get options(){return this.optionsService.options}set options(e){for(let t in e)this.optionsService.options[t]=e[t]}write(e,t){this._writeBuffer.write(e,t)}writeSync(e,t){this._logService.logLevel<=3&&!op&&(this._logService.warn("writeSync is unreliable and will be removed soon."),op=!0),this._writeBuffer.writeSync(e,t)}input(e,t=!0){this.coreService.triggerDataEvent(e,t)}resize(e,t){isNaN(e)||isNaN(t)||(e=Math.max(e,Dv),t=Math.max(t,Vv),this._bufferService.resize(e,t))}scroll(e,t=!1){this._bufferService.scroll(e,t)}scrollLines(e,t){this._bufferService.scrollLines(e,t)}scrollPages(e){this.scrollLines(e*(this.rows-1))}scrollToTop(){this.scrollLines(-this._bufferService.buffer.ydisp)}scrollToBottom(e){this.scrollLines(this._bufferService.buffer.ybase-this._bufferService.buffer.ydisp)}scrollToLine(e){let t=e-this._bufferService.buffer.ydisp;t!==0&&this.scrollLines(t)}registerEscHandler(e,t){return this._inputHandler.registerEscHandler(e,t)}registerDcsHandler(e,t){return this._inputHandler.registerDcsHandler(e,t)}registerCsiHandler(e,t){return this._inputHandler.registerCsiHandler(e,t)}registerOscHandler(e,t){return this._inputHandler.registerOscHandler(e,t)}_setup(){this._handleWindowsPtyOptionChange()}reset(){this._inputHandler.reset(),this._bufferService.reset(),this._charsetService.reset(),this.coreService.reset(),this.coreMouseService.reset()}_handleWindowsPtyOptionChange(){let e=!1,t=this.optionsService.rawOptions.windowsPty;t&&t.buildNumber!==void 0&&t.buildNumber!==void 0?e=t.backend==="conpty"&&t.buildNumber<21376:this.optionsService.rawOptions.windowsMode&&(e=!0),e?this._enableWindowsWrappingHeuristics():this._windowsWrappingHeuristics.clear()}_enableWindowsWrappingHeuristics(){if(!this._windowsWrappingHeuristics.value){let e=[];e.push(this.onLineFeed(J8.bind(null,this._bufferService))),e.push(this.registerCsiHandler({final:"H"},()=>(J8(this._bufferService),!1))),this._windowsWrappingHeuristics.value=St(()=>{for(let t of e)t.dispose()})}}},_U={48:["0",")"],49:["1","!"],50:["2","@"],51:["3","#"],52:["4","$"],53:["5","%"],54:["6","^"],55:["7","&"],56:["8","*"],57:["9","("],186:[";",":"],187:["=","+"],188:[",","<"],189:["-","_"],190:[".",">"],191:["/","?"],192:["`","~"],219:["[","{"],220:["\\","|"],221:["]","}"],222:["'",'"']};function mU(e,t,i,r){var a;let s={type:0,cancel:!1,key:void 0},n=(e.shiftKey?1:0)|(e.altKey?2:0)|(e.ctrlKey?4:0)|(e.metaKey?8:0);switch(e.keyCode){case 0:e.key==="UIKeyInputUpArrow"?t?s.key=ve.ESC+"OA":s.key=ve.ESC+"[A":e.key==="UIKeyInputLeftArrow"?t?s.key=ve.ESC+"OD":s.key=ve.ESC+"[D":e.key==="UIKeyInputRightArrow"?t?s.key=ve.ESC+"OC":s.key=ve.ESC+"[C":e.key==="UIKeyInputDownArrow"&&(t?s.key=ve.ESC+"OB":s.key=ve.ESC+"[B");break;case 8:s.key=e.ctrlKey?"\b":ve.DEL,e.altKey&&(s.key=ve.ESC+s.key);break;case 9:if(e.shiftKey){s.key=ve.ESC+"[Z";break}s.key=ve.HT,s.cancel=!0;break;case 13:s.key=e.altKey?ve.ESC+ve.CR:ve.CR,s.cancel=!0;break;case 27:s.key=ve.ESC,e.altKey&&(s.key=ve.ESC+ve.ESC),s.cancel=!0;break;case 37:if(e.metaKey)break;n?s.key=ve.ESC+"[1;"+(n+1)+"D":t?s.key=ve.ESC+"OD":s.key=ve.ESC+"[D";break;case 39:if(e.metaKey)break;n?s.key=ve.ESC+"[1;"+(n+1)+"C":t?s.key=ve.ESC+"OC":s.key=ve.ESC+"[C";break;case 38:if(e.metaKey)break;n?s.key=ve.ESC+"[1;"+(n+1)+"A":t?s.key=ve.ESC+"OA":s.key=ve.ESC+"[A";break;case 40:if(e.metaKey)break;n?s.key=ve.ESC+"[1;"+(n+1)+"B":t?s.key=ve.ESC+"OB":s.key=ve.ESC+"[B";break;case 45:!e.shiftKey&&!e.ctrlKey&&(s.key=ve.ESC+"[2~");break;case 46:n?s.key=ve.ESC+"[3;"+(n+1)+"~":s.key=ve.ESC+"[3~";break;case 36:n?s.key=ve.ESC+"[1;"+(n+1)+"H":t?s.key=ve.ESC+"OH":s.key=ve.ESC+"[H";break;case 35:n?s.key=ve.ESC+"[1;"+(n+1)+"F":t?s.key=ve.ESC+"OF":s.key=ve.ESC+"[F";break;case 33:e.shiftKey?s.type=2:e.ctrlKey?s.key=ve.ESC+"[5;"+(n+1)+"~":s.key=ve.ESC+"[5~";break;case 34:e.shiftKey?s.type=3:e.ctrlKey?s.key=ve.ESC+"[6;"+(n+1)+"~":s.key=ve.ESC+"[6~";break;case 112:n?s.key=ve.ESC+"[1;"+(n+1)+"P":s.key=ve.ESC+"OP";break;case 113:n?s.key=ve.ESC+"[1;"+(n+1)+"Q":s.key=ve.ESC+"OQ";break;case 114:n?s.key=ve.ESC+"[1;"+(n+1)+"R":s.key=ve.ESC+"OR";break;case 115:n?s.key=ve.ESC+"[1;"+(n+1)+"S":s.key=ve.ESC+"OS";break;case 116:n?s.key=ve.ESC+"[15;"+(n+1)+"~":s.key=ve.ESC+"[15~";break;case 117:n?s.key=ve.ESC+"[17;"+(n+1)+"~":s.key=ve.ESC+"[17~";break;case 118:n?s.key=ve.ESC+"[18;"+(n+1)+"~":s.key=ve.ESC+"[18~";break;case 119:n?s.key=ve.ESC+"[19;"+(n+1)+"~":s.key=ve.ESC+"[19~";break;case 120:n?s.key=ve.ESC+"[20;"+(n+1)+"~":s.key=ve.ESC+"[20~";break;case 121:n?s.key=ve.ESC+"[21;"+(n+1)+"~":s.key=ve.ESC+"[21~";break;case 122:n?s.key=ve.ESC+"[23;"+(n+1)+"~":s.key=ve.ESC+"[23~";break;case 123:n?s.key=ve.ESC+"[24;"+(n+1)+"~":s.key=ve.ESC+"[24~";break;default:if(e.ctrlKey&&!e.shiftKey&&!e.altKey&&!e.metaKey)e.keyCode>=65&&e.keyCode<=90?s.key=String.fromCharCode(e.keyCode-64):e.keyCode===32?s.key=ve.NUL:e.keyCode>=51&&e.keyCode<=55?s.key=String.fromCharCode(e.keyCode-51+27):e.keyCode===56?s.key=ve.DEL:e.keyCode===219?s.key=ve.ESC:e.keyCode===220?s.key=ve.FS:e.keyCode===221&&(s.key=ve.GS);else if((!i||r)&&e.altKey&&!e.metaKey){let o=(a=_U[e.keyCode])==null?void 0:a[e.shiftKey?1:0];if(o)s.key=ve.ESC+o;else if(e.keyCode>=65&&e.keyCode<=90){let l=e.ctrlKey?e.keyCode-64:e.keyCode+32,c=String.fromCharCode(l);e.shiftKey&&(c=c.toUpperCase()),s.key=ve.ESC+c}else if(e.keyCode===32)s.key=ve.ESC+(e.ctrlKey?ve.NUL:" ");else if(e.key==="Dead"&&e.code.startsWith("Key")){let l=e.code.slice(3,4);e.shiftKey||(l=l.toLowerCase()),s.key=ve.ESC+l,s.cancel=!0}}else i&&!e.altKey&&!e.ctrlKey&&!e.shiftKey&&e.metaKey?e.keyCode===65&&(s.type=1):e.key&&!e.ctrlKey&&!e.altKey&&!e.metaKey&&e.keyCode>=48&&e.key.length===1?s.key=e.key:e.key&&e.ctrlKey&&(e.key==="_"&&(s.key=ve.US),e.key==="@"&&(s.key=ve.NUL));break}return s}var Nt=0,gU=class{constructor(e){this._getKey=e,this._array=[],this._insertedValues=[],this._flushInsertedTask=new X0,this._isFlushingInserted=!1,this._deletedIndices=[],this._flushDeletedTask=new X0,this._isFlushingDeleted=!1}clear(){this._array.length=0,this._insertedValues.length=0,this._flushInsertedTask.clear(),this._isFlushingInserted=!1,this._deletedIndices.length=0,this._flushDeletedTask.clear(),this._isFlushingDeleted=!1}insert(e){this._flushCleanupDeleted(),this._insertedValues.length===0&&this._flushInsertedTask.enqueue(()=>this._flushInserted()),this._insertedValues.push(e)}_flushInserted(){let e=this._insertedValues.sort((s,n)=>this._getKey(s)-this._getKey(n)),t=0,i=0,r=new Array(this._array.length+this._insertedValues.length);for(let s=0;s<r.length;s++)i>=this._array.length||this._getKey(e[t])<=this._getKey(this._array[i])?(r[s]=e[t],t++):r[s]=this._array[i++];this._array=r,this._insertedValues.length=0}_flushCleanupInserted(){!this._isFlushingInserted&&this._insertedValues.length>0&&this._flushInsertedTask.flush()}delete(e){if(this._flushCleanupInserted(),this._array.length===0)return!1;let t=this._getKey(e);if(t===void 0||(Nt=this._search(t),Nt===-1)||this._getKey(this._array[Nt])!==t)return!1;do if(this._array[Nt]===e)return this._deletedIndices.length===0&&this._flushDeletedTask.enqueue(()=>this._flushDeleted()),this._deletedIndices.push(Nt),!0;while(++Nt<this._array.length&&this._getKey(this._array[Nt])===t);return!1}_flushDeleted(){this._isFlushingDeleted=!0;let e=this._deletedIndices.sort((s,n)=>s-n),t=0,i=new Array(this._array.length-e.length),r=0;for(let s=0;s<this._array.length;s++)e[t]===s?t++:i[r++]=this._array[s];this._array=i,this._deletedIndices.length=0,this._isFlushingDeleted=!1}_flushCleanupDeleted(){!this._isFlushingDeleted&&this._deletedIndices.length>0&&this._flushDeletedTask.flush()}*getKeyIterator(e){if(this._flushCleanupInserted(),this._flushCleanupDeleted(),this._array.length!==0&&(Nt=this._search(e),!(Nt<0||Nt>=this._array.length)&&this._getKey(this._array[Nt])===e))do yield this._array[Nt];while(++Nt<this._array.length&&this._getKey(this._array[Nt])===e)}forEachByKey(e,t){if(this._flushCleanupInserted(),this._flushCleanupDeleted(),this._array.length!==0&&(Nt=this._search(e),!(Nt<0||Nt>=this._array.length)&&this._getKey(this._array[Nt])===e))do t(this._array[Nt]);while(++Nt<this._array.length&&this._getKey(this._array[Nt])===e)}values(){return this._flushCleanupInserted(),this._flushCleanupDeleted(),[...this._array].values()}_search(e){let t=0,i=this._array.length-1;for(;i>=t;){let r=t+i>>1,s=this._getKey(this._array[r]);if(s>e)i=r-1;else if(s<e)t=r+1;else{for(;r>0&&this._getKey(this._array[r-1])===e;)r--;return r}}return t}},O1=0,lp=0,vU=class extends qe{constructor(){super(),this._decorations=new gU(e=>e==null?void 0:e.marker.line),this._onDecorationRegistered=this._register(new Ae),this.onDecorationRegistered=this._onDecorationRegistered.event,this._onDecorationRemoved=this._register(new Ae),this.onDecorationRemoved=this._onDecorationRemoved.event,this._register(St(()=>this.reset()))}get decorations(){return this._decorations.values()}registerDecoration(e){if(e.marker.isDisposed)return;let t=new bU(e);if(t){let i=t.marker.onDispose(()=>t.dispose()),r=t.onDispose(()=>{r.dispose(),t&&(this._decorations.delete(t)&&this._onDecorationRemoved.fire(t),i.dispose())});this._decorations.insert(t),this._onDecorationRegistered.fire(t)}return t}reset(){for(let e of this._decorations.values())e.dispose();this._decorations.clear()}*getDecorationsAtCell(e,t,i){let r=0,s=0;for(let n of this._decorations.getKeyIterator(t))r=n.options.x??0,s=r+(n.options.width??1),e>=r&&e<s&&(!i||(n.options.layer??"bottom")===i)&&(yield n)}forEachDecorationAtCell(e,t,i,r){this._decorations.forEachByKey(t,s=>{O1=s.options.x??0,lp=O1+(s.options.width??1),e>=O1&&e<lp&&(!i||(s.options.layer??"bottom")===i)&&r(s)})}},bU=class extends gs{constructor(e){super(),this.options=e,this.onRenderEmitter=this.add(new Ae),this.onRender=this.onRenderEmitter.event,this._onDispose=this.add(new Ae),this.onDispose=this._onDispose.event,this._cachedBg=null,this._cachedFg=null,this.marker=e.marker,this.options.overviewRulerOptions&&!this.options.overviewRulerOptions.position&&(this.options.overviewRulerOptions.position="full")}get backgroundColorRGB(){return this._cachedBg===null&&(this.options.backgroundColor?this._cachedBg=kt.toColor(this.options.backgroundColor):this._cachedBg=void 0),this._cachedBg}get foregroundColorRGB(){return this._cachedFg===null&&(this.options.foregroundColor?this._cachedFg=kt.toColor(this.options.foregroundColor):this._cachedFg=void 0),this._cachedFg}dispose(){this._onDispose.fire(),super.dispose()}},yU=1e3,wU=class{constructor(e,t=yU){this._renderCallback=e,this._debounceThresholdMS=t,this._lastRefreshMs=0,this._additionalRefreshRequested=!1}dispose(){this._refreshTimeoutID&&clearTimeout(this._refreshTimeoutID)}refresh(e,t,i){this._rowCount=i,e=e!==void 0?e:0,t=t!==void 0?t:this._rowCount-1,this._rowStart=this._rowStart!==void 0?Math.min(this._rowStart,e):e,this._rowEnd=this._rowEnd!==void 0?Math.max(this._rowEnd,t):t;let r=performance.now();if(r-this._lastRefreshMs>=this._debounceThresholdMS)this._lastRefreshMs=r,this._innerRefresh();else if(!this._additionalRefreshRequested){let s=r-this._lastRefreshMs,n=this._debounceThresholdMS-s;this._additionalRefreshRequested=!0,this._refreshTimeoutID=window.setTimeout(()=>{this._lastRefreshMs=performance.now(),this._innerRefresh(),this._additionalRefreshRequested=!1,this._refreshTimeoutID=void 0},n)}}_innerRefresh(){if(this._rowStart===void 0||this._rowEnd===void 0||this._rowCount===void 0)return;let e=Math.max(this._rowStart,0),t=Math.min(this._rowEnd,this._rowCount-1);this._rowStart=void 0,this._rowEnd=void 0,this._renderCallback(e,t)}},cp=20,J0=class extends qe{constructor(e,t,i,r){super(),this._terminal=e,this._coreBrowserService=i,this._renderService=r,this._rowColumns=new WeakMap,this._liveRegionLineCount=0,this._charsToConsume=[],this._charsToAnnounce="";let s=this._coreBrowserService.mainDocument;this._accessibilityContainer=s.createElement("div"),this._accessibilityContainer.classList.add("xterm-accessibility"),this._rowContainer=s.createElement("div"),this._rowContainer.setAttribute("role","list"),this._rowContainer.classList.add("xterm-accessibility-tree"),this._rowElements=[];for(let n=0;n<this._terminal.rows;n++)this._rowElements[n]=this._createAccessibilityTreeNode(),this._rowContainer.appendChild(this._rowElements[n]);if(this._topBoundaryFocusListener=n=>this._handleBoundaryFocus(n,0),this._bottomBoundaryFocusListener=n=>this._handleBoundaryFocus(n,1),this._rowElements[0].addEventListener("focus",this._topBoundaryFocusListener),this._rowElements[this._rowElements.length-1].addEventListener("focus",this._bottomBoundaryFocusListener),this._accessibilityContainer.appendChild(this._rowContainer),this._liveRegion=s.createElement("div"),this._liveRegion.classList.add("live-region"),this._liveRegion.setAttribute("aria-live","assertive"),this._accessibilityContainer.appendChild(this._liveRegion),this._liveRegionDebouncer=this._register(new wU(this._renderRows.bind(this))),!this._terminal.element)throw new Error("Cannot enable accessibility before Terminal.open");this._terminal.element.insertAdjacentElement("afterbegin",this._accessibilityContainer),this._register(this._terminal.onResize(n=>this._handleResize(n.rows))),this._register(this._terminal.onRender(n=>this._refreshRows(n.start,n.end))),this._register(this._terminal.onScroll(()=>this._refreshRows())),this._register(this._terminal.onA11yChar(n=>this._handleChar(n))),this._register(this._terminal.onLineFeed(()=>this._handleChar(`
|
|
93
|
-
`))),this._register(this._terminal.onA11yTab(n=>this._handleTab(n))),this._register(this._terminal.onKey(n=>this._handleKey(n.key))),this._register(this._terminal.onBlur(()=>this._clearLiveRegion())),this._register(this._renderService.onDimensionsChange(()=>this._refreshRowsDimensions())),this._register(ze(s,"selectionchange",()=>this._handleSelectionChange())),this._register(this._coreBrowserService.onDprChange(()=>this._refreshRowsDimensions())),this._refreshRowsDimensions(),this._refreshRows(),this._register(St(()=>{this._accessibilityContainer.remove(),this._rowElements.length=0}))}_handleTab(e){for(let t=0;t<e;t++)this._handleChar(" ")}_handleChar(e){this._liveRegionLineCount<cp+1&&(this._charsToConsume.length>0?this._charsToConsume.shift()!==e&&(this._charsToAnnounce+=e):this._charsToAnnounce+=e,e===`
|
|
94
|
-
`&&(this._liveRegionLineCount++,this._liveRegionLineCount===cp+1&&(this._liveRegion.textContent+=Ku.get())))}_clearLiveRegion(){this._liveRegion.textContent="",this._liveRegionLineCount=0}_handleKey(e){this._clearLiveRegion(),new RegExp("\\p{Control}","u").test(e)||this._charsToConsume.push(e)}_refreshRows(e,t){this._liveRegionDebouncer.refresh(e,t,this._terminal.rows)}_renderRows(e,t){let i=this._terminal.buffer,r=i.lines.length.toString();for(let s=e;s<=t;s++){let n=i.lines.get(i.ydisp+s),a=[],o=(n==null?void 0:n.translateToString(!0,void 0,void 0,a))||"",l=(i.ydisp+s+1).toString(),c=this._rowElements[s];c&&(o.length===0?(c.textContent=" ",this._rowColumns.set(c,[0,1])):(c.textContent=o,this._rowColumns.set(c,a)),c.setAttribute("aria-posinset",l),c.setAttribute("aria-setsize",r),this._alignRowWidth(c))}this._announceCharacters()}_announceCharacters(){this._charsToAnnounce.length!==0&&(this._liveRegion.textContent+=this._charsToAnnounce,this._charsToAnnounce="")}_handleBoundaryFocus(e,t){let i=e.target,r=this._rowElements[t===0?1:this._rowElements.length-2],s=i.getAttribute("aria-posinset"),n=t===0?"1":`${this._terminal.buffer.lines.length}`;if(s===n||e.relatedTarget!==r)return;let a,o;if(t===0?(a=i,o=this._rowElements.pop(),this._rowContainer.removeChild(o)):(a=this._rowElements.shift(),o=i,this._rowContainer.removeChild(a)),a.removeEventListener("focus",this._topBoundaryFocusListener),o.removeEventListener("focus",this._bottomBoundaryFocusListener),t===0){let l=this._createAccessibilityTreeNode();this._rowElements.unshift(l),this._rowContainer.insertAdjacentElement("afterbegin",l)}else{let l=this._createAccessibilityTreeNode();this._rowElements.push(l),this._rowContainer.appendChild(l)}this._rowElements[0].addEventListener("focus",this._topBoundaryFocusListener),this._rowElements[this._rowElements.length-1].addEventListener("focus",this._bottomBoundaryFocusListener),this._terminal.scrollLines(t===0?-1:1),this._rowElements[t===0?1:this._rowElements.length-2].focus(),e.preventDefault(),e.stopImmediatePropagation()}_handleSelectionChange(){var o;if(this._rowElements.length===0)return;let e=this._coreBrowserService.mainDocument.getSelection();if(!e)return;if(e.isCollapsed){this._rowContainer.contains(e.anchorNode)&&this._terminal.clearSelection();return}if(!e.anchorNode||!e.focusNode){console.error("anchorNode and/or focusNode are null");return}let t={node:e.anchorNode,offset:e.anchorOffset},i={node:e.focusNode,offset:e.focusOffset};if((t.node.compareDocumentPosition(i.node)&Node.DOCUMENT_POSITION_PRECEDING||t.node===i.node&&t.offset>i.offset)&&([t,i]=[i,t]),t.node.compareDocumentPosition(this._rowElements[0])&(Node.DOCUMENT_POSITION_CONTAINED_BY|Node.DOCUMENT_POSITION_FOLLOWING)&&(t={node:this._rowElements[0].childNodes[0],offset:0}),!this._rowContainer.contains(t.node))return;let r=this._rowElements.slice(-1)[0];if(i.node.compareDocumentPosition(r)&(Node.DOCUMENT_POSITION_CONTAINED_BY|Node.DOCUMENT_POSITION_PRECEDING)&&(i={node:r,offset:((o=r.textContent)==null?void 0:o.length)??0}),!this._rowContainer.contains(i.node))return;let s=({node:l,offset:c})=>{let u=l instanceof Text?l.parentNode:l,h=parseInt(u==null?void 0:u.getAttribute("aria-posinset"),10)-1;if(isNaN(h))return console.warn("row is invalid. Race condition?"),null;let d=this._rowColumns.get(u);if(!d)return console.warn("columns is null. Race condition?"),null;let f=c<d.length?d[c]:d.slice(-1)[0]+1;return f>=this._terminal.cols&&(++h,f=0),{row:h,column:f}},n=s(t),a=s(i);if(!(!n||!a)){if(n.row>a.row||n.row===a.row&&n.column>=a.column)throw new Error("invalid range");this._terminal.select(n.column,n.row,(a.row-n.row)*this._terminal.cols-n.column+a.column)}}_handleResize(e){this._rowElements[this._rowElements.length-1].removeEventListener("focus",this._bottomBoundaryFocusListener);for(let t=this._rowContainer.children.length;t<this._terminal.rows;t++)this._rowElements[t]=this._createAccessibilityTreeNode(),this._rowContainer.appendChild(this._rowElements[t]);for(;this._rowElements.length>e;)this._rowContainer.removeChild(this._rowElements.pop());this._rowElements[this._rowElements.length-1].addEventListener("focus",this._bottomBoundaryFocusListener),this._refreshRowsDimensions()}_createAccessibilityTreeNode(){let e=this._coreBrowserService.mainDocument.createElement("div");return e.setAttribute("role","listitem"),e.tabIndex=-1,this._refreshRowDimensions(e),e}_refreshRowsDimensions(){if(this._renderService.dimensions.css.cell.height){Object.assign(this._accessibilityContainer.style,{width:`${this._renderService.dimensions.css.canvas.width}px`,fontSize:`${this._terminal.options.fontSize}px`}),this._rowElements.length!==this._terminal.rows&&this._handleResize(this._terminal.rows);for(let e=0;e<this._terminal.rows;e++)this._refreshRowDimensions(this._rowElements[e]),this._alignRowWidth(this._rowElements[e])}}_refreshRowDimensions(e){e.style.height=`${this._renderService.dimensions.css.cell.height}px`}_alignRowWidth(e){var s,n;e.style.transform="";let t=e.getBoundingClientRect().width,i=(n=(s=this._rowColumns.get(e))==null?void 0:s.slice(-1))==null?void 0:n[0];if(!i)return;let r=i*this._renderService.dimensions.css.cell.width;e.style.transform=`scaleX(${r/t})`}};J0=Tt([Te(1,Od),Te(2,Jr),Te(3,Qr)],J0);var Eh=class extends qe{constructor(e,t,i,r,s){super(),this._element=e,this._mouseService=t,this._renderService=i,this._bufferService=r,this._linkProviderService=s,this._linkCacheDisposables=[],this._isMouseOut=!0,this._wasResized=!1,this._activeLine=-1,this._onShowLinkUnderline=this._register(new Ae),this.onShowLinkUnderline=this._onShowLinkUnderline.event,this._onHideLinkUnderline=this._register(new Ae),this.onHideLinkUnderline=this._onHideLinkUnderline.event,this._register(St(()=>{var n;sn(this._linkCacheDisposables),this._linkCacheDisposables.length=0,this._lastMouseEvent=void 0,(n=this._activeProviderReplies)==null||n.clear()})),this._register(this._bufferService.onResize(()=>{this._clearCurrentLink(),this._wasResized=!0})),this._register(ze(this._element,"mouseleave",()=>{this._isMouseOut=!0,this._clearCurrentLink()})),this._register(ze(this._element,"mousemove",this._handleMouseMove.bind(this))),this._register(ze(this._element,"mousedown",this._handleMouseDown.bind(this))),this._register(ze(this._element,"mouseup",this._handleMouseUp.bind(this)))}get currentLink(){return this._currentLink}_handleMouseMove(e){this._lastMouseEvent=e;let t=this._positionFromMouseEvent(e,this._element,this._mouseService);if(!t)return;this._isMouseOut=!1;let i=e.composedPath();for(let r=0;r<i.length;r++){let s=i[r];if(s.classList.contains("xterm"))break;if(s.classList.contains("xterm-hover"))return}(!this._lastBufferCell||t.x!==this._lastBufferCell.x||t.y!==this._lastBufferCell.y)&&(this._handleHover(t),this._lastBufferCell=t)}_handleHover(e){if(this._activeLine!==e.y||this._wasResized){this._clearCurrentLink(),this._askForLink(e,!1),this._wasResized=!1;return}this._currentLink&&this._linkAtPosition(this._currentLink.link,e)||(this._clearCurrentLink(),this._askForLink(e,!0))}_askForLink(e,t){var r,s;(!this._activeProviderReplies||!t)&&((r=this._activeProviderReplies)==null||r.forEach(n=>{n==null||n.forEach(a=>{a.link.dispose&&a.link.dispose()})}),this._activeProviderReplies=new Map,this._activeLine=e.y);let i=!1;for(let[n,a]of this._linkProviderService.linkProviders.entries())t?(s=this._activeProviderReplies)!=null&&s.get(n)&&(i=this._checkLinkProviderResult(n,e,i)):a.provideLinks(e.y,o=>{var c,u;if(this._isMouseOut)return;let l=o==null?void 0:o.map(h=>({link:h}));(c=this._activeProviderReplies)==null||c.set(n,l),i=this._checkLinkProviderResult(n,e,i),((u=this._activeProviderReplies)==null?void 0:u.size)===this._linkProviderService.linkProviders.length&&this._removeIntersectingLinks(e.y,this._activeProviderReplies)})}_removeIntersectingLinks(e,t){let i=new Set;for(let r=0;r<t.size;r++){let s=t.get(r);if(s)for(let n=0;n<s.length;n++){let a=s[n],o=a.link.range.start.y<e?0:a.link.range.start.x,l=a.link.range.end.y>e?this._bufferService.cols:a.link.range.end.x;for(let c=o;c<=l;c++){if(i.has(c)){s.splice(n--,1);break}i.add(c)}}}}_checkLinkProviderResult(e,t,i){var n;if(!this._activeProviderReplies)return i;let r=this._activeProviderReplies.get(e),s=!1;for(let a=0;a<e;a++)(!this._activeProviderReplies.has(a)||this._activeProviderReplies.get(a))&&(s=!0);if(!s&&r){let a=r.find(o=>this._linkAtPosition(o.link,t));a&&(i=!0,this._handleNewLink(a))}if(this._activeProviderReplies.size===this._linkProviderService.linkProviders.length&&!i)for(let a=0;a<this._activeProviderReplies.size;a++){let o=(n=this._activeProviderReplies.get(a))==null?void 0:n.find(l=>this._linkAtPosition(l.link,t));if(o){i=!0,this._handleNewLink(o);break}}return i}_handleMouseDown(){this._mouseDownLink=this._currentLink}_handleMouseUp(e){if(!this._currentLink)return;let t=this._positionFromMouseEvent(e,this._element,this._mouseService);t&&this._mouseDownLink&&SU(this._mouseDownLink.link,this._currentLink.link)&&this._linkAtPosition(this._currentLink.link,t)&&this._currentLink.link.activate(e,this._currentLink.link.text)}_clearCurrentLink(e,t){!this._currentLink||!this._lastMouseEvent||(!e||!t||this._currentLink.link.range.start.y>=e&&this._currentLink.link.range.end.y<=t)&&(this._linkLeave(this._element,this._currentLink.link,this._lastMouseEvent),this._currentLink=void 0,sn(this._linkCacheDisposables),this._linkCacheDisposables.length=0)}_handleNewLink(e){if(!this._lastMouseEvent)return;let t=this._positionFromMouseEvent(this._lastMouseEvent,this._element,this._mouseService);t&&this._linkAtPosition(e.link,t)&&(this._currentLink=e,this._currentLink.state={decorations:{underline:e.link.decorations===void 0?!0:e.link.decorations.underline,pointerCursor:e.link.decorations===void 0?!0:e.link.decorations.pointerCursor},isHovered:!0},this._linkHover(this._element,e.link,this._lastMouseEvent),e.link.decorations={},Object.defineProperties(e.link.decorations,{pointerCursor:{get:()=>{var i,r;return(r=(i=this._currentLink)==null?void 0:i.state)==null?void 0:r.decorations.pointerCursor},set:i=>{var r;(r=this._currentLink)!=null&&r.state&&this._currentLink.state.decorations.pointerCursor!==i&&(this._currentLink.state.decorations.pointerCursor=i,this._currentLink.state.isHovered&&this._element.classList.toggle("xterm-cursor-pointer",i))}},underline:{get:()=>{var i,r;return(r=(i=this._currentLink)==null?void 0:i.state)==null?void 0:r.decorations.underline},set:i=>{var r,s,n;(r=this._currentLink)!=null&&r.state&&((n=(s=this._currentLink)==null?void 0:s.state)==null?void 0:n.decorations.underline)!==i&&(this._currentLink.state.decorations.underline=i,this._currentLink.state.isHovered&&this._fireUnderlineEvent(e.link,i))}}}),this._linkCacheDisposables.push(this._renderService.onRenderedViewportChange(i=>{if(!this._currentLink)return;let r=i.start===0?0:i.start+1+this._bufferService.buffer.ydisp,s=this._bufferService.buffer.ydisp+1+i.end;if(this._currentLink.link.range.start.y>=r&&this._currentLink.link.range.end.y<=s&&(this._clearCurrentLink(r,s),this._lastMouseEvent)){let n=this._positionFromMouseEvent(this._lastMouseEvent,this._element,this._mouseService);n&&this._askForLink(n,!1)}})))}_linkHover(e,t,i){var r;(r=this._currentLink)!=null&&r.state&&(this._currentLink.state.isHovered=!0,this._currentLink.state.decorations.underline&&this._fireUnderlineEvent(t,!0),this._currentLink.state.decorations.pointerCursor&&e.classList.add("xterm-cursor-pointer")),t.hover&&t.hover(i,t.text)}_fireUnderlineEvent(e,t){let i=e.range,r=this._bufferService.buffer.ydisp,s=this._createLinkUnderlineEvent(i.start.x-1,i.start.y-r-1,i.end.x,i.end.y-r-1,void 0);(t?this._onShowLinkUnderline:this._onHideLinkUnderline).fire(s)}_linkLeave(e,t,i){var r;(r=this._currentLink)!=null&&r.state&&(this._currentLink.state.isHovered=!1,this._currentLink.state.decorations.underline&&this._fireUnderlineEvent(t,!1),this._currentLink.state.decorations.pointerCursor&&e.classList.remove("xterm-cursor-pointer")),t.leave&&t.leave(i,t.text)}_linkAtPosition(e,t){let i=e.range.start.y*this._bufferService.cols+e.range.start.x,r=e.range.end.y*this._bufferService.cols+e.range.end.x,s=t.y*this._bufferService.cols+t.x;return i<=s&&s<=r}_positionFromMouseEvent(e,t,i){let r=i.getCoords(e,t,this._bufferService.cols,this._bufferService.rows);if(r)return{x:r[0],y:r[1]+this._bufferService.buffer.ydisp}}_createLinkUnderlineEvent(e,t,i,r,s){return{x1:e,y1:t,x2:i,y2:r,cols:this._bufferService.cols,fg:s}}};Eh=Tt([Te(1,Id),Te(2,Qr),Te(3,Ai),Te(4,lv)],Eh);function SU(e,t){return e.text===t.text&&e.range.start.x===t.range.start.x&&e.range.start.y===t.range.start.y&&e.range.end.x===t.range.end.x&&e.range.end.y===t.range.end.y}var CU=class extends pU{constructor(e={}){super(e),this._linkifier=this._register(new Kn),this.browser=Lv,this._keyDownHandled=!1,this._keyDownSeen=!1,this._keyPressHandled=!1,this._unprocessedDeadKey=!1,this._accessibilityManager=this._register(new Kn),this._onCursorMove=this._register(new Ae),this.onCursorMove=this._onCursorMove.event,this._onKey=this._register(new Ae),this.onKey=this._onKey.event,this._onRender=this._register(new Ae),this.onRender=this._onRender.event,this._onSelectionChange=this._register(new Ae),this.onSelectionChange=this._onSelectionChange.event,this._onTitleChange=this._register(new Ae),this.onTitleChange=this._onTitleChange.event,this._onBell=this._register(new Ae),this.onBell=this._onBell.event,this._onFocus=this._register(new Ae),this._onBlur=this._register(new Ae),this._onA11yCharEmitter=this._register(new Ae),this._onA11yTabEmitter=this._register(new Ae),this._onWillOpen=this._register(new Ae),this._setup(),this._decorationService=this._instantiationService.createInstance(vU),this._instantiationService.setService(El,this._decorationService),this._linkProviderService=this._instantiationService.createInstance(dz),this._instantiationService.setService(lv,this._linkProviderService),this._linkProviderService.registerLinkProvider(this._instantiationService.createInstance(Gu)),this._register(this._inputHandler.onRequestBell(()=>this._onBell.fire())),this._register(this._inputHandler.onRequestRefreshRows(t=>this.refresh((t==null?void 0:t.start)??0,(t==null?void 0:t.end)??this.rows-1))),this._register(this._inputHandler.onRequestSendFocus(()=>this._reportFocus())),this._register(this._inputHandler.onRequestReset(()=>this.reset())),this._register(this._inputHandler.onRequestWindowsOptionsReport(t=>this._reportWindowsOptions(t))),this._register(this._inputHandler.onColor(t=>this._handleColorEvent(t))),this._register(si.forward(this._inputHandler.onCursorMove,this._onCursorMove)),this._register(si.forward(this._inputHandler.onTitleChange,this._onTitleChange)),this._register(si.forward(this._inputHandler.onA11yChar,this._onA11yCharEmitter)),this._register(si.forward(this._inputHandler.onA11yTab,this._onA11yTabEmitter)),this._register(this._bufferService.onResize(t=>this._afterResize(t.cols,t.rows))),this._register(St(()=>{var t,i;this._customKeyEventHandler=void 0,(i=(t=this.element)==null?void 0:t.parentNode)==null||i.removeChild(this.element)}))}get linkifier(){return this._linkifier.value}get onFocus(){return this._onFocus.event}get onBlur(){return this._onBlur.event}get onA11yChar(){return this._onA11yCharEmitter.event}get onA11yTab(){return this._onA11yTabEmitter.event}get onWillOpen(){return this._onWillOpen.event}_handleColorEvent(e){if(this._themeService)for(let t of e){let i,r="";switch(t.index){case 256:i="foreground",r="10";break;case 257:i="background",r="11";break;case 258:i="cursor",r="12";break;default:i="ansi",r="4;"+t.index}switch(t.type){case 0:let s=vt.toColorRGB(i==="ansi"?this._themeService.colors.ansi[t.index]:this._themeService.colors[i]);this.coreService.triggerDataEvent(`${ve.ESC}]${r};${lU(s)}${Av.ST}`);break;case 1:if(i==="ansi")this._themeService.modifyColors(n=>n.ansi[t.index]=Rt.toColor(...t.color));else{let n=i;this._themeService.modifyColors(a=>a[n]=Rt.toColor(...t.color))}break;case 2:this._themeService.restoreColor(t.index);break}}}_setup(){super._setup(),this._customKeyEventHandler=void 0}get buffer(){return this.buffers.active}focus(){this.textarea&&this.textarea.focus({preventScroll:!0})}_handleScreenReaderModeOptionChange(e){e?!this._accessibilityManager.value&&this._renderService&&(this._accessibilityManager.value=this._instantiationService.createInstance(J0,this)):this._accessibilityManager.clear()}_handleTextAreaFocus(e){this.coreService.decPrivateModes.sendFocus&&this.coreService.triggerDataEvent(ve.ESC+"[I"),this.element.classList.add("focus"),this._showCursor(),this._onFocus.fire()}blur(){var e;return(e=this.textarea)==null?void 0:e.blur()}_handleTextAreaBlur(){this.textarea.value="",this.refresh(this.buffer.y,this.buffer.y),this.coreService.decPrivateModes.sendFocus&&this.coreService.triggerDataEvent(ve.ESC+"[O"),this.element.classList.remove("focus"),this._onBlur.fire()}_syncTextArea(){if(!this.textarea||!this.buffer.isCursorInViewport||this._compositionHelper.isComposing||!this._renderService)return;let e=this.buffer.ybase+this.buffer.y,t=this.buffer.lines.get(e);if(!t)return;let i=Math.min(this.buffer.x,this.cols-1),r=this._renderService.dimensions.css.cell.height,s=t.getWidth(i),n=this._renderService.dimensions.css.cell.width*s,a=this.buffer.y*this._renderService.dimensions.css.cell.height,o=i*this._renderService.dimensions.css.cell.width;this.textarea.style.left=o+"px",this.textarea.style.top=a+"px",this.textarea.style.width=n+"px",this.textarea.style.height=r+"px",this.textarea.style.lineHeight=r+"px",this.textarea.style.zIndex="-5"}_initGlobal(){this._bindKeys(),this._register(ze(this.element,"copy",t=>{this.hasSelection()&&LZ(t,this._selectionService)}));let e=t=>EZ(t,this.textarea,this.coreService,this.optionsService);this._register(ze(this.textarea,"paste",e)),this._register(ze(this.element,"paste",e)),Ev?this._register(ze(this.element,"mousedown",t=>{t.button===2&&b8(t,this.textarea,this.screenElement,this._selectionService,this.options.rightClickSelectsWord)})):this._register(ze(this.element,"contextmenu",t=>{b8(t,this.textarea,this.screenElement,this._selectionService,this.options.rightClickSelectsWord)})),Ud&&this._register(ze(this.element,"auxclick",t=>{t.button===1&&Qg(t,this.textarea,this.screenElement)}))}_bindKeys(){this._register(ze(this.textarea,"keyup",e=>this._keyUp(e),!0)),this._register(ze(this.textarea,"keydown",e=>this._keyDown(e),!0)),this._register(ze(this.textarea,"keypress",e=>this._keyPress(e),!0)),this._register(ze(this.textarea,"compositionstart",()=>this._compositionHelper.compositionstart())),this._register(ze(this.textarea,"compositionupdate",e=>this._compositionHelper.compositionupdate(e))),this._register(ze(this.textarea,"compositionend",()=>this._compositionHelper.compositionend())),this._register(ze(this.textarea,"input",e=>this._inputEvent(e),!0)),this._register(this.onRender(()=>this._compositionHelper.updateCompositionElements()))}open(e){var s;if(!e)throw new Error("Terminal requires a parent element.");if(e.isConnected||this._logService.debug("Terminal.open was called on an element that was not attached to the DOM"),((s=this.element)==null?void 0:s.ownerDocument.defaultView)&&this._coreBrowserService){this.element.ownerDocument.defaultView!==this._coreBrowserService.window&&(this._coreBrowserService.window=this.element.ownerDocument.defaultView);return}this._document=e.ownerDocument,this.options.documentOverride&&this.options.documentOverride instanceof Document&&(this._document=this.optionsService.rawOptions.documentOverride),this.element=this._document.createElement("div"),this.element.dir="ltr",this.element.classList.add("terminal"),this.element.classList.add("xterm"),e.appendChild(this.element);let t=this._document.createDocumentFragment();this._viewportElement=this._document.createElement("div"),this._viewportElement.classList.add("xterm-viewport"),t.appendChild(this._viewportElement),this.screenElement=this._document.createElement("div"),this.screenElement.classList.add("xterm-screen"),this._register(ze(this.screenElement,"mousemove",n=>this.updateCursorStyle(n))),this._helperContainer=this._document.createElement("div"),this._helperContainer.classList.add("xterm-helpers"),this.screenElement.appendChild(this._helperContainer),t.appendChild(this.screenElement);let i=this.textarea=this._document.createElement("textarea");this.textarea.classList.add("xterm-helper-textarea"),this.textarea.setAttribute("aria-label",ju.get()),Tv||this.textarea.setAttribute("aria-multiline","false"),this.textarea.setAttribute("autocorrect","off"),this.textarea.setAttribute("autocapitalize","off"),this.textarea.setAttribute("spellcheck","false"),this.textarea.tabIndex=0,this._register(this.optionsService.onSpecificOptionChange("disableStdin",()=>i.readOnly=this.optionsService.rawOptions.disableStdin)),this.textarea.readOnly=this.optionsService.rawOptions.disableStdin,this._coreBrowserService=this._register(this._instantiationService.createInstance(uz,this.textarea,e.ownerDocument.defaultView??window,this._document??typeof window<"u"?window.document:null)),this._instantiationService.setService(Jr,this._coreBrowserService),this._register(ze(this.textarea,"focus",n=>this._handleTextAreaFocus(n))),this._register(ze(this.textarea,"blur",()=>this._handleTextAreaBlur())),this._helperContainer.appendChild(this.textarea),this._charSizeService=this._instantiationService.createInstance(mh,this._document,this._helperContainer),this._instantiationService.setService(Oc,this._charSizeService),this._themeService=this._instantiationService.createInstance(yh),this._instantiationService.setService($a,this._themeService),this._characterJoinerService=this._instantiationService.createInstance(G0),this._instantiationService.setService(ov,this._characterJoinerService),this._renderService=this._register(this._instantiationService.createInstance(vh,this.rows,this.screenElement)),this._instantiationService.setService(Qr,this._renderService),this._register(this._renderService.onRenderedViewportChange(n=>this._onRender.fire(n))),this.onResize(n=>this._renderService.resize(n.cols,n.rows)),this._compositionView=this._document.createElement("div"),this._compositionView.classList.add("composition-view"),this._compositionHelper=this._instantiationService.createInstance(fh,this.textarea,this._compositionView),this._helperContainer.appendChild(this._compositionView),this._mouseService=this._instantiationService.createInstance(gh),this._instantiationService.setService(Id,this._mouseService);let r=this._linkifier.value=this._register(this._instantiationService.createInstance(Eh,this.screenElement));this.element.appendChild(t);try{this._onWillOpen.fire(this.element)}catch{}this._renderService.hasRenderer()||this._renderService.setRenderer(this._createRenderer()),this._register(this.onCursorMove(()=>{this._renderService.handleCursorMove(),this._syncTextArea()})),this._register(this.onResize(()=>this._renderService.handleResize(this.cols,this.rows))),this._register(this.onBlur(()=>this._renderService.handleBlur())),this._register(this.onFocus(()=>this._renderService.handleFocus())),this._viewport=this._register(this._instantiationService.createInstance(hh,this.element,this.screenElement)),this._register(this._viewport.onRequestScrollLines(n=>{super.scrollLines(n,!1),this.refresh(0,this.rows-1)})),this._selectionService=this._register(this._instantiationService.createInstance(bh,this.element,this.screenElement,r)),this._instantiationService.setService(IZ,this._selectionService),this._register(this._selectionService.onRequestScrollLines(n=>this.scrollLines(n.amount,n.suppressScrollEvent))),this._register(this._selectionService.onSelectionChange(()=>this._onSelectionChange.fire())),this._register(this._selectionService.onRequestRedraw(n=>this._renderService.handleSelectionChanged(n.start,n.end,n.columnSelectMode))),this._register(this._selectionService.onLinuxMouseSelection(n=>{this.textarea.value=n,this.textarea.focus(),this.textarea.select()})),this._register(si.any(this._onScroll.event,this._inputHandler.onScroll)(()=>{var n;this._selectionService.refresh(),(n=this._viewport)==null||n.queueSync()})),this._register(this._instantiationService.createInstance(dh,this.screenElement)),this._register(ze(this.element,"mousedown",n=>this._selectionService.handleMouseDown(n))),this.coreMouseService.areMouseEventsActive?(this._selectionService.disable(),this.element.classList.add("enable-mouse-events")):this._selectionService.enable(),this.options.screenReaderMode&&(this._accessibilityManager.value=this._instantiationService.createInstance(J0,this)),this._register(this.optionsService.onSpecificOptionChange("screenReaderMode",n=>this._handleScreenReaderModeOptionChange(n))),this.options.overviewRuler.width&&(this._overviewRulerRenderer=this._register(this._instantiationService.createInstance(q0,this._viewportElement,this.screenElement))),this.optionsService.onSpecificOptionChange("overviewRuler",n=>{!this._overviewRulerRenderer&&n&&this._viewportElement&&this.screenElement&&(this._overviewRulerRenderer=this._register(this._instantiationService.createInstance(q0,this._viewportElement,this.screenElement)))}),this._charSizeService.measure(),this.refresh(0,this.rows-1),this._initGlobal(),this.bindMouse()}_createRenderer(){return this._instantiationService.createInstance(_h,this,this._document,this.element,this.screenElement,this._viewportElement,this._helperContainer,this.linkifier)}bindMouse(){let e=this,t=this.element;function i(n){var c,u,h,d,f;let a=e._mouseService.getMouseReportCoords(n,e.screenElement);if(!a)return!1;let o,l;switch(n.overrideType||n.type){case"mousemove":l=32,n.buttons===void 0?(o=3,n.button!==void 0&&(o=n.button<3?n.button:3)):o=n.buttons&1?0:n.buttons&4?1:n.buttons&2?2:3;break;case"mouseup":l=0,o=n.button<3?n.button:3;break;case"mousedown":l=1,o=n.button<3?n.button:3;break;case"wheel":if(e._customWheelEventHandler&&e._customWheelEventHandler(n)===!1)return!1;let m=n.deltaY;if(m===0||e.coreMouseService.consumeWheelEvent(n,(d=(h=(u=(c=e._renderService)==null?void 0:c.dimensions)==null?void 0:u.device)==null?void 0:h.cell)==null?void 0:d.height,(f=e._coreBrowserService)==null?void 0:f.dpr)===0)return!1;l=m<0?0:1,o=4;break;default:return!1}return l===void 0||o===void 0||o>4?!1:e.coreMouseService.triggerMouseEvent({col:a.col,row:a.row,x:a.x,y:a.y,button:o,action:l,ctrl:n.ctrlKey,alt:n.altKey,shift:n.shiftKey})}let r={mouseup:null,wheel:null,mousedrag:null,mousemove:null},s={mouseup:n=>(i(n),n.buttons||(this._document.removeEventListener("mouseup",r.mouseup),r.mousedrag&&this._document.removeEventListener("mousemove",r.mousedrag)),this.cancel(n)),wheel:n=>(i(n),this.cancel(n,!0)),mousedrag:n=>{n.buttons&&i(n)},mousemove:n=>{n.buttons||i(n)}};this._register(this.coreMouseService.onProtocolChange(n=>{n?(this.optionsService.rawOptions.logLevel==="debug"&&this._logService.debug("Binding to mouse events:",this.coreMouseService.explainEvents(n)),this.element.classList.add("enable-mouse-events"),this._selectionService.disable()):(this._logService.debug("Unbinding from mouse events."),this.element.classList.remove("enable-mouse-events"),this._selectionService.enable()),n&8?r.mousemove||(t.addEventListener("mousemove",s.mousemove),r.mousemove=s.mousemove):(t.removeEventListener("mousemove",r.mousemove),r.mousemove=null),n&16?r.wheel||(t.addEventListener("wheel",s.wheel,{passive:!1}),r.wheel=s.wheel):(t.removeEventListener("wheel",r.wheel),r.wheel=null),n&2?r.mouseup||(r.mouseup=s.mouseup):(this._document.removeEventListener("mouseup",r.mouseup),r.mouseup=null),n&4?r.mousedrag||(r.mousedrag=s.mousedrag):(this._document.removeEventListener("mousemove",r.mousedrag),r.mousedrag=null)})),this.coreMouseService.activeProtocol=this.coreMouseService.activeProtocol,this._register(ze(t,"mousedown",n=>{if(n.preventDefault(),this.focus(),!(!this.coreMouseService.areMouseEventsActive||this._selectionService.shouldForceSelection(n)))return i(n),r.mouseup&&this._document.addEventListener("mouseup",r.mouseup),r.mousedrag&&this._document.addEventListener("mousemove",r.mousedrag),this.cancel(n)})),this._register(ze(t,"wheel",n=>{var a,o,l,c,u;if(!r.wheel){if(this._customWheelEventHandler&&this._customWheelEventHandler(n)===!1)return!1;if(!this.buffer.hasScrollback){if(n.deltaY===0)return!1;if(e.coreMouseService.consumeWheelEvent(n,(c=(l=(o=(a=e._renderService)==null?void 0:a.dimensions)==null?void 0:o.device)==null?void 0:l.cell)==null?void 0:c.height,(u=e._coreBrowserService)==null?void 0:u.dpr)===0)return this.cancel(n,!0);let h=ve.ESC+(this.coreService.decPrivateModes.applicationCursorKeys?"O":"[")+(n.deltaY<0?"A":"B");return this.coreService.triggerDataEvent(h,!0),this.cancel(n,!0)}}},{passive:!1}))}refresh(e,t){var i;(i=this._renderService)==null||i.refreshRows(e,t)}updateCursorStyle(e){var t;(t=this._selectionService)!=null&&t.shouldColumnSelect(e)?this.element.classList.add("column-select"):this.element.classList.remove("column-select")}_showCursor(){this.coreService.isCursorInitialized||(this.coreService.isCursorInitialized=!0,this.refresh(this.buffer.y,this.buffer.y))}scrollLines(e,t){this._viewport?this._viewport.scrollLines(e):super.scrollLines(e,t),this.refresh(0,this.rows-1)}scrollPages(e){this.scrollLines(e*(this.rows-1))}scrollToTop(){this.scrollLines(-this._bufferService.buffer.ydisp)}scrollToBottom(e){e&&this._viewport?this._viewport.scrollToLine(this.buffer.ybase,!0):this.scrollLines(this._bufferService.buffer.ybase-this._bufferService.buffer.ydisp)}scrollToLine(e){let t=e-this._bufferService.buffer.ydisp;t!==0&&this.scrollLines(t)}paste(e){Jg(e,this.textarea,this.coreService,this.optionsService)}attachCustomKeyEventHandler(e){this._customKeyEventHandler=e}attachCustomWheelEventHandler(e){this._customWheelEventHandler=e}registerLinkProvider(e){return this._linkProviderService.registerLinkProvider(e)}registerCharacterJoiner(e){if(!this._characterJoinerService)throw new Error("Terminal must be opened first");let t=this._characterJoinerService.register(e);return this.refresh(0,this.rows-1),t}deregisterCharacterJoiner(e){if(!this._characterJoinerService)throw new Error("Terminal must be opened first");this._characterJoinerService.deregister(e)&&this.refresh(0,this.rows-1)}get markers(){return this.buffer.markers}registerMarker(e){return this.buffer.addMarker(this.buffer.ybase+this.buffer.y+e)}registerDecoration(e){return this._decorationService.registerDecoration(e)}hasSelection(){return this._selectionService?this._selectionService.hasSelection:!1}select(e,t,i){this._selectionService.setSelection(e,t,i)}getSelection(){return this._selectionService?this._selectionService.selectionText:""}getSelectionPosition(){if(!(!this._selectionService||!this._selectionService.hasSelection))return{start:{x:this._selectionService.selectionStart[0],y:this._selectionService.selectionStart[1]},end:{x:this._selectionService.selectionEnd[0],y:this._selectionService.selectionEnd[1]}}}clearSelection(){var e;(e=this._selectionService)==null||e.clearSelection()}selectAll(){var e;(e=this._selectionService)==null||e.selectAll()}selectLines(e,t){var i;(i=this._selectionService)==null||i.selectLines(e,t)}_keyDown(e){if(this._keyDownHandled=!1,this._keyDownSeen=!0,this._customKeyEventHandler&&this._customKeyEventHandler(e)===!1)return!1;let t=this.browser.isMac&&this.options.macOptionIsMeta&&e.altKey;if(!t&&!this._compositionHelper.keydown(e))return this.options.scrollOnUserInput&&this.buffer.ybase!==this.buffer.ydisp&&this.scrollToBottom(!0),!1;!t&&(e.key==="Dead"||e.key==="AltGraph")&&(this._unprocessedDeadKey=!0);let i=mU(e,this.coreService.decPrivateModes.applicationCursorKeys,this.browser.isMac,this.options.macOptionIsMeta);if(this.updateCursorStyle(e),i.type===3||i.type===2){let r=this.rows-1;return this.scrollLines(i.type===2?-r:r),this.cancel(e,!0)}if(i.type===1&&this.selectAll(),this._isThirdLevelShift(this.browser,e)||(i.cancel&&this.cancel(e,!0),!i.key)||e.key&&!e.ctrlKey&&!e.altKey&&!e.metaKey&&e.key.length===1&&e.key.charCodeAt(0)>=65&&e.key.charCodeAt(0)<=90)return!0;if(this._unprocessedDeadKey)return this._unprocessedDeadKey=!1,!0;if((i.key===ve.ETX||i.key===ve.CR)&&(this.textarea.value=""),this._onKey.fire({key:i.key,domEvent:e}),this._showCursor(),this.coreService.triggerDataEvent(i.key,!0),!this.optionsService.rawOptions.screenReaderMode||e.altKey||e.ctrlKey)return this.cancel(e,!0);this._keyDownHandled=!0}_isThirdLevelShift(e,t){let i=e.isMac&&!this.options.macOptionIsMeta&&t.altKey&&!t.ctrlKey&&!t.metaKey||e.isWindows&&t.altKey&&t.ctrlKey&&!t.metaKey||e.isWindows&&t.getModifierState("AltGraph");return t.type==="keypress"?i:i&&(!t.keyCode||t.keyCode>47)}_keyUp(e){this._keyDownSeen=!1,!(this._customKeyEventHandler&&this._customKeyEventHandler(e)===!1)&&(kU(e)||this.focus(),this.updateCursorStyle(e),this._keyPressHandled=!1)}_keyPress(e){let t;if(this._keyPressHandled=!1,this._keyDownHandled||this._customKeyEventHandler&&this._customKeyEventHandler(e)===!1)return!1;if(this.cancel(e),e.charCode)t=e.charCode;else if(e.which===null||e.which===void 0)t=e.keyCode;else if(e.which!==0&&e.charCode!==0)t=e.which;else return!1;return!t||(e.altKey||e.ctrlKey||e.metaKey)&&!this._isThirdLevelShift(this.browser,e)?!1:(t=String.fromCharCode(t),this._onKey.fire({key:t,domEvent:e}),this._showCursor(),this.coreService.triggerDataEvent(t,!0),this._keyPressHandled=!0,this._unprocessedDeadKey=!1,!0)}_inputEvent(e){if(e.data&&e.inputType==="insertText"&&(!e.composed||!this._keyDownSeen)&&!this.optionsService.rawOptions.screenReaderMode){if(this._keyPressHandled)return!1;this._unprocessedDeadKey=!1;let t=e.data;return this.coreService.triggerDataEvent(t,!0),this.cancel(e),!0}return!1}resize(e,t){if(e===this.cols&&t===this.rows){this._charSizeService&&!this._charSizeService.hasValidSize&&this._charSizeService.measure();return}super.resize(e,t)}_afterResize(e,t){var i;(i=this._charSizeService)==null||i.measure()}clear(){if(!(this.buffer.ybase===0&&this.buffer.y===0)){this.buffer.clearAllMarkers(),this.buffer.lines.set(0,this.buffer.lines.get(this.buffer.ybase+this.buffer.y)),this.buffer.lines.length=1,this.buffer.ydisp=0,this.buffer.ybase=0,this.buffer.y=0;for(let e=1;e<this.rows;e++)this.buffer.lines.push(this.buffer.getBlankLine(It));this._onScroll.fire({position:this.buffer.ydisp}),this.refresh(0,this.rows-1)}}reset(){var t;this.options.rows=this.rows,this.options.cols=this.cols;let e=this._customKeyEventHandler;this._setup(),super.reset(),(t=this._selectionService)==null||t.reset(),this._decorationService.reset(),this._customKeyEventHandler=e,this.refresh(0,this.rows-1)}clearTextureAtlas(){var e;(e=this._renderService)==null||e.clearTextureAtlas()}_reportFocus(){var e;(e=this.element)!=null&&e.classList.contains("focus")?this.coreService.triggerDataEvent(ve.ESC+"[I"):this.coreService.triggerDataEvent(ve.ESC+"[O")}_reportWindowsOptions(e){if(this._renderService)switch(e){case 0:let t=this._renderService.dimensions.css.canvas.width.toFixed(0),i=this._renderService.dimensions.css.canvas.height.toFixed(0);this.coreService.triggerDataEvent(`${ve.ESC}[4;${i};${t}t`);break;case 1:let r=this._renderService.dimensions.css.cell.width.toFixed(0),s=this._renderService.dimensions.css.cell.height.toFixed(0);this.coreService.triggerDataEvent(`${ve.ESC}[6;${s};${r}t`);break}}cancel(e,t){if(!(!this.options.cancelEvents&&!t))return e.preventDefault(),e.stopPropagation(),!1}};function kU(e){return e.keyCode===16||e.keyCode===17||e.keyCode===18}var AU=class{constructor(){this._addons=[]}dispose(){for(let e=this._addons.length-1;e>=0;e--)this._addons[e].instance.dispose()}loadAddon(e,t){let i={instance:t,dispose:t.dispose,isDisposed:!1};this._addons.push(i),t.dispose=()=>this._wrappedAddonDispose(i),t.activate(e)}_wrappedAddonDispose(e){if(e.isDisposed)return;let t=-1;for(let i=0;i<this._addons.length;i++)if(this._addons[i]===e){t=i;break}if(t===-1)throw new Error("Could not dispose an addon that has not been loaded");e.isDisposed=!0,e.dispose.apply(e.instance),this._addons.splice(t,1)}},MU=class{constructor(e){this._line=e}get isWrapped(){return this._line.isWrapped}get length(){return this._line.length}getCell(e,t){if(!(e<0||e>=this._line.length))return t?(this._line.loadCell(e,t),t):this._line.loadCell(e,new Ki)}translateToString(e,t,i){return this._line.translateToString(e,t,i)}},up=class{constructor(e,t){this._buffer=e,this.type=t}init(e){return this._buffer=e,this}get cursorY(){return this._buffer.y}get cursorX(){return this._buffer.x}get viewportY(){return this._buffer.ydisp}get baseY(){return this._buffer.ybase}get length(){return this._buffer.lines.length}getLine(e){let t=this._buffer.lines.get(e);if(t)return new MU(t)}getNullCell(){return new Ki}},LU=class extends qe{constructor(e){super(),this._core=e,this._onBufferChange=this._register(new Ae),this.onBufferChange=this._onBufferChange.event,this._normal=new up(this._core.buffers.normal,"normal"),this._alternate=new up(this._core.buffers.alt,"alternate"),this._core.buffers.onBufferActivate(()=>this._onBufferChange.fire(this.active))}get active(){if(this._core.buffers.active===this._core.buffers.normal)return this.normal;if(this._core.buffers.active===this._core.buffers.alt)return this.alternate;throw new Error("Active buffer is neither normal nor alternate")}get normal(){return this._normal.init(this._core.buffers.normal)}get alternate(){return this._alternate.init(this._core.buffers.alt)}},EU=class{constructor(e){this._core=e}registerCsiHandler(e,t){return this._core.registerCsiHandler(e,i=>t(i.toArray()))}addCsiHandler(e,t){return this.registerCsiHandler(e,t)}registerDcsHandler(e,t){return this._core.registerDcsHandler(e,(i,r)=>t(i,r.toArray()))}addDcsHandler(e,t){return this.registerDcsHandler(e,t)}registerEscHandler(e,t){return this._core.registerEscHandler(e,t)}addEscHandler(e,t){return this.registerEscHandler(e,t)}registerOscHandler(e,t){return this._core.registerOscHandler(e,t)}addOscHandler(e,t){return this.registerOscHandler(e,t)}},$U=class{constructor(e){this._core=e}register(e){this._core.unicodeService.register(e)}get versions(){return this._core.unicodeService.versions}get activeVersion(){return this._core.unicodeService.activeVersion}set activeVersion(e){this._core.unicodeService.activeVersion=e}},xU=["cols","rows"],ur=0,TU=class extends qe{constructor(e){super(),this._core=this._register(new CU(e)),this._addonManager=this._register(new AU),this._publicOptions={...this._core.options};let t=r=>this._core.options[r],i=(r,s)=>{this._checkReadonlyOptions(r),this._core.options[r]=s};for(let r in this._core.options){let s={get:t.bind(this,r),set:i.bind(this,r)};Object.defineProperty(this._publicOptions,r,s)}}_checkReadonlyOptions(e){if(xU.includes(e))throw new Error(`Option "${e}" can only be set in the constructor`)}_checkProposedApi(){if(!this._core.optionsService.rawOptions.allowProposedApi)throw new Error("You must set the allowProposedApi option to true to use proposed API")}get onBell(){return this._core.onBell}get onBinary(){return this._core.onBinary}get onCursorMove(){return this._core.onCursorMove}get onData(){return this._core.onData}get onKey(){return this._core.onKey}get onLineFeed(){return this._core.onLineFeed}get onRender(){return this._core.onRender}get onResize(){return this._core.onResize}get onScroll(){return this._core.onScroll}get onSelectionChange(){return this._core.onSelectionChange}get onTitleChange(){return this._core.onTitleChange}get onWriteParsed(){return this._core.onWriteParsed}get element(){return this._core.element}get parser(){return this._parser||(this._parser=new EU(this._core)),this._parser}get unicode(){return this._checkProposedApi(),new $U(this._core)}get textarea(){return this._core.textarea}get rows(){return this._core.rows}get cols(){return this._core.cols}get buffer(){return this._buffer||(this._buffer=this._register(new LU(this._core))),this._buffer}get markers(){return this._checkProposedApi(),this._core.markers}get modes(){let e=this._core.coreService.decPrivateModes,t="none";switch(this._core.coreMouseService.activeProtocol){case"X10":t="x10";break;case"VT200":t="vt200";break;case"DRAG":t="drag";break;case"ANY":t="any";break}return{applicationCursorKeysMode:e.applicationCursorKeys,applicationKeypadMode:e.applicationKeypad,bracketedPasteMode:e.bracketedPasteMode,insertMode:this._core.coreService.modes.insertMode,mouseTrackingMode:t,originMode:e.origin,reverseWraparoundMode:e.reverseWraparound,sendFocusMode:e.sendFocus,synchronizedOutputMode:e.synchronizedOutput,wraparoundMode:e.wraparound}}get options(){return this._publicOptions}set options(e){for(let t in e)this._publicOptions[t]=e[t]}blur(){this._core.blur()}focus(){this._core.focus()}input(e,t=!0){this._core.input(e,t)}resize(e,t){this._verifyIntegers(e,t),this._core.resize(e,t)}open(e){this._core.open(e)}attachCustomKeyEventHandler(e){this._core.attachCustomKeyEventHandler(e)}attachCustomWheelEventHandler(e){this._core.attachCustomWheelEventHandler(e)}registerLinkProvider(e){return this._core.registerLinkProvider(e)}registerCharacterJoiner(e){return this._checkProposedApi(),this._core.registerCharacterJoiner(e)}deregisterCharacterJoiner(e){this._checkProposedApi(),this._core.deregisterCharacterJoiner(e)}registerMarker(e=0){return this._verifyIntegers(e),this._core.registerMarker(e)}registerDecoration(e){return this._checkProposedApi(),this._verifyPositiveIntegers(e.x??0,e.width??0,e.height??0),this._core.registerDecoration(e)}hasSelection(){return this._core.hasSelection()}select(e,t,i){this._verifyIntegers(e,t,i),this._core.select(e,t,i)}getSelection(){return this._core.getSelection()}getSelectionPosition(){return this._core.getSelectionPosition()}clearSelection(){this._core.clearSelection()}selectAll(){this._core.selectAll()}selectLines(e,t){this._verifyIntegers(e,t),this._core.selectLines(e,t)}dispose(){super.dispose()}scrollLines(e){this._verifyIntegers(e),this._core.scrollLines(e)}scrollPages(e){this._verifyIntegers(e),this._core.scrollPages(e)}scrollToTop(){this._core.scrollToTop()}scrollToBottom(){this._core.scrollToBottom()}scrollToLine(e){this._verifyIntegers(e),this._core.scrollToLine(e)}clear(){this._core.clear()}write(e,t){this._core.write(e,t)}writeln(e,t){this._core.write(e),this._core.write(`\r
|
|
95
|
-
`,t)}paste(e){this._core.paste(e)}refresh(e,t){this._verifyIntegers(e,t),this._core.refresh(e,t)}reset(){this._core.reset()}clearTextureAtlas(){this._core.clearTextureAtlas()}loadAddon(e){this._addonManager.loadAddon(this,e)}static get strings(){return{get promptLabel(){return ju.get()},set promptLabel(e){ju.set(e)},get tooMuchOutput(){return Ku.get()},set tooMuchOutput(e){Ku.set(e)}}}_verifyIntegers(...e){for(ur of e)if(ur===1/0||isNaN(ur)||ur%1!==0)throw new Error("This API only accepts integers")}_verifyPositiveIntegers(...e){for(ur of e)if(ur&&(ur===1/0||isNaN(ur)||ur%1!==0||ur<0))throw new Error("This API only accepts positive integers")}};/**
|
|
96
|
-
* Copyright (c) 2014-2024 The xterm.js authors. All rights reserved.
|
|
97
|
-
* @license MIT
|
|
98
|
-
*
|
|
99
|
-
* Copyright (c) 2012-2013, Christopher Jeffrey (MIT License)
|
|
100
|
-
* @license MIT
|
|
101
|
-
*
|
|
102
|
-
* Originally forked from (with the author's permission):
|
|
103
|
-
* Fabrice Bellard's javascript vt100 for jslinux:
|
|
104
|
-
* http://bellard.org/jslinux/
|
|
105
|
-
* Copyright (c) 2011 Fabrice Bellard
|
|
106
|
-
*/var NU=2,HU=1,PU=class{activate(e){this._terminal=e}dispose(){}fit(){let e=this.proposeDimensions();if(!e||!this._terminal||isNaN(e.cols)||isNaN(e.rows))return;let t=this._terminal._core;(this._terminal.rows!==e.rows||this._terminal.cols!==e.cols)&&(t._renderService.clear(),this._terminal.resize(e.cols,e.rows))}proposeDimensions(){var h;if(!this._terminal||!this._terminal.element||!this._terminal.element.parentElement)return;let e=this._terminal._core._renderService.dimensions;if(e.css.cell.width===0||e.css.cell.height===0)return;let t=this._terminal.options.scrollback===0?0:((h=this._terminal.options.overviewRuler)==null?void 0:h.width)||14,i=window.getComputedStyle(this._terminal.element.parentElement),r=parseInt(i.getPropertyValue("height")),s=Math.max(0,parseInt(i.getPropertyValue("width"))),n=window.getComputedStyle(this._terminal.element),a={top:parseInt(n.getPropertyValue("padding-top")),bottom:parseInt(n.getPropertyValue("padding-bottom")),right:parseInt(n.getPropertyValue("padding-right")),left:parseInt(n.getPropertyValue("padding-left"))},o=a.top+a.bottom,l=a.right+a.left,c=r-o,u=s-l-t;return{cols:Math.max(NU,Math.floor(u/e.css.cell.width)),rows:Math.max(HU,Math.floor(c/e.css.cell.height))}}};const OU={class:"terminal-view"},IU={class:"conn-status"},RU={class:"conn-label"},DU=Re({__name:"TerminalView",setup(e){const t=ln(),i=X(null),r=Ar(null),s=Ar(null);let n=null,a=null;const o=X(!1);function l(){const u=location.protocol==="https:"?"wss:":"ws:";n=new WebSocket(`${u}//${location.host}/ws/shell`),n.onopen=()=>{o.value=!0,c()},n.onmessage=h=>{var d;(d=r.value)==null||d.write(h.data)},n.onclose=()=>{var h;o.value=!1,(h=r.value)==null||h.write(`\r
|
|
107
|
-
\x1B[90m- disconnected -\x1B[0m\r
|
|
108
|
-
`)},n.onerror=()=>n==null?void 0:n.close()}function c(){!n||n.readyState!==n.OPEN||!r.value||n.send(JSON.stringify({type:"resize",cols:r.value.cols,rows:r.value.rows}))}return ut(async()=>{t.setPage("Terminal",void 0,{fullBleed:!0}),await document.fonts.ready;const u=new TU({theme:{background:"#0d1117",foreground:"#e6edf3",cursor:"#58a6ff",selectionBackground:"rgba(88,166,255,0.3)",black:"#0d1117",brightBlack:"#6e7681",red:"#ff7b72",brightRed:"#ffa198",green:"#3fb950",brightGreen:"#56d364",yellow:"#d29922",brightYellow:"#e3b341",blue:"#58a6ff",brightBlue:"#79c0ff",magenta:"#bc8cff",brightMagenta:"#d2a8ff",cyan:"#39c5cf",brightCyan:"#56d4dd",white:"#b1bac4",brightWhite:"#f0f6fc"},fontFamily:'"MesloLGS NF", monospace',fontSize:13,lineHeight:1.45,cursorStyle:"block",cursorBlink:!0,scrollback:5e3,convertEol:!0,disableStdin:!1,allowTransparency:!1}),h=new PU;u.loadAddon(h),r.value=u,s.value=h,i.value&&(u.open(i.value),h.fit()),u.onData(d=>{(n==null?void 0:n.readyState)===WebSocket.OPEN&&n.send(JSON.stringify({type:"input",data:d}))}),a=new ResizeObserver(()=>{h.fit(),c()}),i.value&&a.observe(i.value),l()}),Gi(()=>{var u;n==null||n.close(),n=null,a==null||a.disconnect(),(u=r.value)==null||u.dispose()}),(u,h)=>(g(),E("div",OU,[(g(),de(br,{defer:"",to:"#ob-topbar-right"},[b("div",IU,[b("div",{class:xe(["conn-dot",o.value?"live":"dead"])},null,2),b("span",RU,Z(o.value?"Connected":"Disconnected"),1)])])),b("div",{ref_key:"containerEl",ref:i,class:"terminal-container"},null,512)]))}}),VU=jt(DU,[["__scopeId","data-v-be882a56"]]),BU={class:"login-page"},ZU={class:"login-card"},FU={key:0},zU={key:1},hp="openbridge_auto_resume_attempted",UU=Re({__name:"LoginView",setup(e){const t=Lc(),i=Cl(),{user:r,loadConfig:s,checkAuth:n,startPlatformLogin:a,resumeLastAccount:o,chooseAccount:l}=Ec(),c=X(!1),u=X(null),h=Q(()=>t.query.logged_out==="1");async function d(){c.value=!0,u.value=null;try{const m=typeof t.query.login_hint=="string"?t.query.login_hint:void 0;await a(m?{loginHint:m}:{})}catch(m){c.value=!1,u.value=m instanceof Error?m.message:"Unable to start sign-in."}}async function f(){c.value=!0,u.value=null;try{await l()}catch(m){c.value=!1,u.value=m instanceof Error?m.message:"Unable to start sign-in."}}return ut(async()=>{if(!(await s()).enabled){i.replace("/");return}if(t.query.error==="account_changed"){u.value="Your platform account changed. Please sign in again.";return}const _=typeof t.query.login_hint=="string"?t.query.login_hint:"";if(await n()){if(_&&r.value&&r.value.email.toLowerCase()!==_.toLowerCase()){c.value=!0,await a({loginHint:_});return}i.replace("/");return}if(_){c.value=!0,await a({loginHint:_});return}if(!h.value&&!sessionStorage.getItem(hp)){if(sessionStorage.setItem(hp,"1"),c.value=!0,await o())return;c.value=!1}}),(m,_)=>{const y=Qe,p=oi;return g(),E("div",BU,[b("div",ZU,[_[2]||(_[2]=b("h1",{class:"login-title"},"OpenBridge",-1)),_[3]||(_[3]=b("p",{class:"login-subtitle"},"Sign in via Nubisco Platform to manage this OpenBridge instance.",-1)),u.value?(g(),de(y,{key:0,variant:"error",class:"login-error"},{default:ee(()=>[ce(Z(u.value),1)]),_:1})):h.value?(g(),de(y,{key:1,variant:"success",class:"login-error"},{default:ee(()=>[..._[0]||(_[0]=[ce("You have been signed out.",-1)])]),_:1})):F("",!0),Y(p,{variant:"primary",size:"lg",disabled:c.value,class:"login-btn",onClick:d},{default:ee(()=>[c.value?(g(),E("span",FU,"Redirecting…")):(g(),E("span",zU,"Sign in via Nubisco Platform"))]),_:1},8,["disabled"]),Y(p,{variant:"ghost",size:"sm",disabled:c.value,onClick:f},{default:ee(()=>[..._[1]||(_[1]=[ce("Use a different account",-1)])]),_:1},8,["disabled"])])])}}}),WU=jt(UU,[["__scopeId","data-v-de234ae2"]]),jU={class:"callback-page"},KU={key:1,class:"callback-loading"},qU=Re({__name:"AuthCallbackView",setup(e){const t=Lc(),i=Cl(),{checkAuth:r,clearLastAccount:s}=Ec(),n=X(null);return ut(async()=>{const a=typeof t.query.token=="string"?t.query.token:"",o=typeof t.query.state=="string"?t.query.state:"",l=typeof t.query.error=="string"?t.query.error:"",c=sessionStorage.getItem("openbridge_platform_state");sessionStorage.removeItem("openbridge_platform_state");const u=sessionStorage.getItem("openbridge_platform_expected_sub");if(sessionStorage.removeItem("openbridge_platform_expected_sub"),l){n.value=l==="not_a_member"?"Your account does not have access to this OpenBridge instance.":l==="domain_not_allowed"?"Your account is not eligible for this OpenBridge instance.":`Sign-in failed: ${l}`;return}if(!c||!o||c!==o){n.value="The sign-in request is no longer valid. Please try again.";return}if(!a){n.value="Platform did not return an OpenBridge access token.";return}const h=await fetch("/auth/platform/callback",{method:"POST",headers:{"Content-Type":"application/json"},credentials:"include",body:JSON.stringify({token:a,...u?{expected_sub:u}:{}})});if(!h.ok){const d=await h.json().catch(()=>null);if((d==null?void 0:d.error)==="subject_mismatch"){s(),i.replace({path:"/login",query:{error:"account_changed"}});return}n.value=(d==null?void 0:d.error)==="invalid_token"?"Your platform sign-in is no longer valid. Please try again.":(d==null?void 0:d.error)==="wrong_app"?"The sign-in was issued for a different application. Please try again.":"Sign-in failed. Please try again.";return}await r(),sessionStorage.removeItem("openbridge_auto_resume_attempted"),i.replace("/")}),(a,o)=>{const l=Qe;return g(),E("div",jU,[n.value?(g(),de(l,{key:0,variant:"error"},{default:ee(()=>[ce(Z(n.value),1)]),_:1})):(g(),E("p",KU,"Signing you in…"))])}}}),GU=jt(qU,[["__scopeId","data-v-6ea5c514"]]),Zv=LT({history:nT(),routes:[{path:"/login",name:"login",component:WU},{path:"/auth/callback",name:"auth-callback",component:GU},{path:"/",component:TR,redirect:"/dashboard",children:[{path:"dashboard",name:"dashboard",component:XD},{path:"plugins",name:"plugins",component:ZV},{path:"devices",name:"devices",component:wB},{path:"devices/:id",name:"device-detail",component:jB},{path:"config",name:"config",component:sZ},{path:"settings",name:"settings",component:SZ},{path:"terminal",name:"terminal",component:VU}]}]});let dp=!1;Zv.beforeEach(async e=>{var a;if(e.name==="login"||e.name==="auth-callback")return!0;const{config:t,user:i,loadConfig:r,checkAuth:s}=Ec();if(t.value||await r(),!((a=t.value)!=null&&a.enabled))return!0;const n=typeof e.query.login_hint=="string"?e.query.login_hint:"";if(dp){if(!i.value)return n?{path:"/login",query:{login_hint:n}}:"/login"}else{const o=await s();if(dp=!0,!o)return n?{path:"/login",query:{login_hint:n}}:"/login"}if(n){if(i.value&&i.value.email.toLowerCase()!==n.toLowerCase())return{path:"/login",query:{login_hint:n}};const o={...e.query};return delete o.login_hint,{path:e.path,query:o}}return!0});const Ta=(e,t,i)=>{const r=s=>Me("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:t,fill:"currentColor",...s,innerHTML:i});return r.displayName="NbGlyph",r.glyphName=e,r},YU=Ta("app-window","0 0 256 256",'<path d="M216,44H40A12,12,0,0,0,28,56V200a12,12,0,0,0,12,12H216a12,12,0,0,0,12-12V56A12,12,0,0,0,216,44Zm4,156a4,4,0,0,1-4,4H40a4,4,0,0,1-4-4V56a4,4,0,0,1,4-4H216a4,4,0,0,1,4,4ZM76,84a8,8,0,1,1-8-8A8,8,0,0,1,76,84Zm40,0a8,8,0,1,1-8-8A8,8,0,0,1,116,84Z"/>'),XU=Ta("app-window","0 0 256 256",'<path d="M216,42H40A14,14,0,0,0,26,56V200a14,14,0,0,0,14,14H216a14,14,0,0,0,14-14V56A14,14,0,0,0,216,42Zm2,158a2,2,0,0,1-2,2H40a2,2,0,0,1-2-2V56a2,2,0,0,1,2-2H216a2,2,0,0,1,2,2ZM78,84A10,10,0,1,1,68,74,10,10,0,0,1,78,84Zm40,0a10,10,0,1,1-10-10A10,10,0,0,1,118,84Z"/>'),fp=Ta("app-window","0 0 256 256",'<path d="M216,40H40A16,16,0,0,0,24,56V200a16,16,0,0,0,16,16H216a16,16,0,0,0,16-16V56A16,16,0,0,0,216,40Zm0,160H40V56H216V200ZM80,84A12,12,0,1,1,68,72,12,12,0,0,1,80,84Zm40,0a12,12,0,1,1-12-12A12,12,0,0,1,120,84Z"/>'),JU=Ta("app-window","0 0 256 256",'<path d="M216,36H40A20,20,0,0,0,20,56V200a20,20,0,0,0,20,20H216a20,20,0,0,0,20-20V56A20,20,0,0,0,216,36Zm-4,160H44V60H212ZM60,92a16,16,0,1,1,16,16A16,16,0,0,1,60,92Zm48,0a16,16,0,1,1,16,16A16,16,0,0,1,108,92Z"/>'),QU=Ta("app-window","0 0 256 256",'<path d="M216,40H40A16,16,0,0,0,24,56V200a16,16,0,0,0,16,16H216a16,16,0,0,0,16-16V56A16,16,0,0,0,216,40ZM68,96A12,12,0,1,1,80,84,12,12,0,0,1,68,96Zm40,0a12,12,0,1,1,12-12A12,12,0,0,1,108,96Z"/>'),eW=Ta("app-window","0 0 256 256",'<path d="M224,56V200a8,8,0,0,1-8,8H40a8,8,0,0,1-8-8V56a8,8,0,0,1,8-8H216A8,8,0,0,1,224,56Z" opacity="0.2"/><path d="M216,40H40A16,16,0,0,0,24,56V200a16,16,0,0,0,16,16H216a16,16,0,0,0,16-16V56A16,16,0,0,0,216,40Zm0,160H40V56H216V200ZM80,84A12,12,0,1,1,68,72,12,12,0,0,1,80,84Zm40,0a12,12,0,1,1-12-12A12,12,0,0,1,120,84Z"/>'),tW="app-window",iW=Object.freeze(Object.defineProperty({__proto__:null,bold:JU,default:fp,duotone:eW,fill:QU,glyphName:tW,light:XU,regular:fp,thin:YU},Symbol.toStringTag,{value:"Module"})),Na=(e,t,i)=>{const r=s=>Me("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:t,fill:"currentColor",...s,innerHTML:i});return r.displayName="NbGlyph",r.glyphName=e,r},rW=Na("brackets-curly","0 0 256 256",'<path d="M35.89,128C52,136.23,52,155.64,52,172c0,24.8,1.35,40,28,40a4,4,0,0,1,0,8c-36,0-36-26.61-36-48,0-24.8-1.35-40-28-40a4,4,0,0,1,0-8c26.65,0,28-15.2,28-40,0-21.39,0-48,36-48a4,4,0,0,1,0,8C53.35,44,52,59.2,52,84,52,100.36,52,119.77,35.89,128ZM240,124c-26.65,0-28-15.2-28-40,0-21.39,0-48-36-48a4,4,0,0,0,0,8c26.65,0,28,15.2,28,40,0,16.36,0,35.77,16.11,44C204,136.23,204,155.64,204,172c0,24.8-1.35,40-28,40a4,4,0,0,0,0,8c36,0,36-26.61,36-48,0-24.8,1.35-40,28-40a4,4,0,0,0,0-8Z"/>'),sW=Na("brackets-curly","0 0 256 256",'<path d="M39.91,128a27.68,27.68,0,0,1,9.49,11.13C54,148.62,54,160.51,54,172c0,24.27,1.21,38,26,38a6,6,0,0,1,0,12c-16.88,0-27.81-5.6-33.4-17.13C42,195.38,42,183.49,42,172c0-24.27-1.21-38-26-38a6,6,0,0,1,0-12c24.79,0,26-13.73,26-38,0-11.49,0-23.38,4.6-32.87C52.19,39.6,63.12,34,80,34a6,6,0,0,1,0,12C55.21,46,54,59.73,54,84c0,11.49,0,23.38-4.6,32.87A27.68,27.68,0,0,1,39.91,128ZM240,122c-24.79,0-26-13.73-26-38,0-11.49,0-23.38-4.6-32.87C203.81,39.6,192.88,34,176,34a6,6,0,0,0,0,12c24.79,0,26,13.73,26,38,0,11.49,0,23.38,4.6,32.87A27.68,27.68,0,0,0,216.09,128a27.68,27.68,0,0,0-9.49,11.13C202,148.62,202,160.51,202,172c0,24.27-1.21,38-26,38a6,6,0,0,0,0,12c16.88,0,27.81-5.6,33.4-17.13,4.6-9.49,4.6-21.38,4.6-32.87,0-24.27,1.21-38,26-38a6,6,0,0,0,0-12Z"/>'),pp=Na("brackets-curly","0 0 256 256",'<path d="M43.18,128a29.78,29.78,0,0,1,8,10.26c4.8,9.9,4.8,22,4.8,33.74,0,24.31,1,36,24,36a8,8,0,0,1,0,16c-17.48,0-29.32-6.14-35.2-18.26-4.8-9.9-4.8-22-4.8-33.74,0-24.31-1-36-24-36a8,8,0,0,1,0-16c23,0,24-11.69,24-36,0-11.72,0-23.84,4.8-33.74C50.68,38.14,62.52,32,80,32a8,8,0,0,1,0,16C57,48,56,59.69,56,84c0,11.72,0,23.84-4.8,33.74A29.78,29.78,0,0,1,43.18,128ZM240,120c-23,0-24-11.69-24-36,0-11.72,0-23.84-4.8-33.74C205.32,38.14,193.48,32,176,32a8,8,0,0,0,0,16c23,0,24,11.69,24,36,0,11.72,0,23.84,4.8,33.74a29.78,29.78,0,0,0,8,10.26,29.78,29.78,0,0,0-8,10.26c-4.8,9.9-4.8,22-4.8,33.74,0,24.31-1,36-24,36a8,8,0,0,0,0,16c17.48,0,29.32-6.14,35.2-18.26,4.8-9.9,4.8-22,4.8-33.74,0-24.31,1-36,24-36a8,8,0,0,0,0-16Z"/>'),nW=Na("brackets-curly","0 0 256 256",'<path d="M54.8,119.49A35.06,35.06,0,0,1,49.05,128a35.06,35.06,0,0,1,5.75,8.51C60,147.24,60,159.83,60,172c0,25.94,1.84,32,20,32a12,12,0,0,1,0,24c-19.14,0-32.2-6.9-38.8-20.51C36,196.76,36,184.17,36,172c0-25.94-1.84-32-20-32a12,12,0,0,1,0-24c18.16,0,20-6.06,20-32,0-12.17,0-24.76,5.2-35.49C47.8,34.9,60.86,28,80,28a12,12,0,0,1,0,24c-18.16,0-20,6.06-20,32C60,96.17,60,108.76,54.8,119.49ZM240,116c-18.16,0-20-6.06-20-32,0-12.17,0-24.76-5.2-35.49C208.2,34.9,195.14,28,176,28a12,12,0,0,0,0,24c18.16,0,20,6.06,20,32,0,12.17,0,24.76,5.2,35.49A35.06,35.06,0,0,0,207,128a35.06,35.06,0,0,0-5.75,8.51C196,147.24,196,159.83,196,172c0,25.94-1.84,32-20,32a12,12,0,0,0,0,24c19.14,0,32.2-6.9,38.8-20.51C220,196.76,220,184.17,220,172c0-25.94,1.84-32,20-32a12,12,0,0,0,0-24Z"/>'),aW=Na("brackets-curly","0 0 256 256",'<path d="M216,40H40A16,16,0,0,0,24,56V200a16,16,0,0,0,16,16H216a16,16,0,0,0,16-16V56A16,16,0,0,0,216,40ZM88,155.84c.29,14.26.41,20.16,16,20.16a8,8,0,0,1,0,16c-31.27,0-31.72-22.43-32-35.84C71.71,141.9,71.59,136,56,136a8,8,0,0,1,0-16c15.59,0,15.71-5.9,16-20.16C72.28,86.43,72.73,64,104,64a8,8,0,0,1,0,16c-15.59,0-15.71,5.9-16,20.16-.17,8.31-.41,20.09-8,27.84C87.59,135.75,87.83,147.53,88,155.84ZM200,136c-15.59,0-15.71,5.9-16,20.16-.28,13.41-.73,35.84-32,35.84a8,8,0,0,1,0-16c15.59,0,15.71-5.9,16-20.16.17-8.31.41-20.09,8-27.84-7.6-7.75-7.84-19.53-8-27.84C167.71,85.9,167.59,80,152,80a8,8,0,0,1,0-16c31.27,0,31.72,22.43,32,35.84.29,14.26.41,20.16,16,20.16a8,8,0,0,1,0,16Z"/>'),oW=Na("brackets-curly","0 0 256 256",'<path d="M240,128c-64,0,0,88-64,88H80c-64,0,0-88-64-88,64,0,0-88,64-88h96C240,40,176,128,240,128Z" opacity="0.2"/><path d="M43.18,128a29.78,29.78,0,0,1,8,10.26c4.8,9.9,4.8,22,4.8,33.74,0,24.31,1,36,24,36a8,8,0,0,1,0,16c-17.48,0-29.32-6.14-35.2-18.26-4.8-9.9-4.8-22-4.8-33.74,0-24.31-1-36-24-36a8,8,0,0,1,0-16c23,0,24-11.69,24-36,0-11.72,0-23.84,4.8-33.74C50.68,38.14,62.52,32,80,32a8,8,0,0,1,0,16C57,48,56,59.69,56,84c0,11.72,0,23.84-4.8,33.74A29.78,29.78,0,0,1,43.18,128ZM240,120c-23,0-24-11.69-24-36,0-11.72,0-23.84-4.8-33.74C205.32,38.14,193.48,32,176,32a8,8,0,0,0,0,16c23,0,24,11.69,24,36,0,11.72,0,23.84,4.8,33.74a29.78,29.78,0,0,0,8,10.26,29.78,29.78,0,0,0-8,10.26c-4.8,9.9-4.8,22-4.8,33.74,0,24.31-1,36-24,36a8,8,0,0,0,0,16c17.48,0,29.32-6.14,35.2-18.26,4.8-9.9,4.8-22,4.8-33.74,0-24.31,1-36,24-36a8,8,0,0,0,0-16Z"/>'),lW="brackets-curly",cW=Object.freeze(Object.defineProperty({__proto__:null,bold:nW,default:pp,duotone:oW,fill:aW,glyphName:lW,light:sW,regular:pp,thin:rW},Symbol.toStringTag,{value:"Module"})),Ha=(e,t,i)=>{const r=s=>Me("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:t,fill:"currentColor",...s,innerHTML:i});return r.displayName="NbGlyph",r.glyphName=e,r},uW=Ha("broadcast","0 0 256 256",'<path d="M128,92a36,36,0,1,0,36,36A36,36,0,0,0,128,92Zm0,64a28,28,0,1,1,28-28A28,28,0,0,1,128,156Zm76-28a75.74,75.74,0,0,1-19.35,50.67,4,4,0,0,1-6-5.34,67.92,67.92,0,0,0,0-90.66,4,4,0,0,1,6-5.34A75.74,75.74,0,0,1,204,128ZM65.34,101.53a67.92,67.92,0,0,0,12,71.8,4,4,0,0,1-6,5.34,75.93,75.93,0,0,1,0-101.34,4,4,0,1,1,6,5.34A68,68,0,0,0,65.34,101.53ZM244,128a115.68,115.68,0,0,1-33.14,81.18,4,4,0,0,1-5.72-5.6,107.89,107.89,0,0,0,0-151.16,4,4,0,0,1,5.72-5.6A115.68,115.68,0,0,1,244,128ZM50.86,203.58a4,4,0,0,1-5.72,5.6,115.91,115.91,0,0,1,0-162.36,4,4,0,1,1,5.72,5.6,107.89,107.89,0,0,0,0,151.16Z"/>'),hW=Ha("broadcast","0 0 256 256",'<path d="M128,90a38,38,0,1,0,38,38A38,38,0,0,0,128,90Zm0,64a26,26,0,1,1,26-26A26,26,0,0,1,128,154Zm78-26a77.74,77.74,0,0,1-19.86,52,6,6,0,0,1-8.94-8,65.93,65.93,0,0,0,0-88,6,6,0,1,1,8.94-8A77.74,77.74,0,0,1,206,128ZM67.18,102.31A65.93,65.93,0,0,0,78.8,172a6,6,0,0,1-.47,8.47,6,6,0,0,1-8.47-.47,77.93,77.93,0,0,1,0-104,6,6,0,1,1,8.94,8A66.21,66.21,0,0,0,67.18,102.31ZM246,128a117.71,117.71,0,0,1-33.71,82.58,6,6,0,0,1-8.58-8.4,105.88,105.88,0,0,0,0-148.36,6,6,0,0,1,8.58-8.4A117.71,117.71,0,0,1,246,128ZM52.29,202.18a6,6,0,0,1-8.58,8.4,117.92,117.92,0,0,1,0-165.16,6,6,0,1,1,8.58,8.4,105.88,105.88,0,0,0,0,148.36Z"/>'),_p=Ha("broadcast","0 0 256 256",'<path d="M128,88a40,40,0,1,0,40,40A40,40,0,0,0,128,88Zm0,64a24,24,0,1,1,24-24A24,24,0,0,1,128,152Zm73.71,7.14a80,80,0,0,1-14.08,22.2,8,8,0,0,1-11.92-10.67,63.95,63.95,0,0,0,0-85.33,8,8,0,1,1,11.92-10.67,80.08,80.08,0,0,1,14.08,84.47ZM69,103.09a64,64,0,0,0,11.26,67.58,8,8,0,0,1-11.92,10.67,79.93,79.93,0,0,1,0-106.67A8,8,0,1,1,80.29,85.34,63.77,63.77,0,0,0,69,103.09ZM248,128a119.58,119.58,0,0,1-34.29,84,8,8,0,1,1-11.42-11.2,103.9,103.9,0,0,0,0-145.56A8,8,0,1,1,213.71,44,119.58,119.58,0,0,1,248,128ZM53.71,200.78A8,8,0,1,1,42.29,212a119.87,119.87,0,0,1,0-168,8,8,0,1,1,11.42,11.2,103.9,103.9,0,0,0,0,145.56Z"/>'),dW=Ha("broadcast","0 0 256 256",'<path d="M128,84a44,44,0,1,0,44,44A44.05,44.05,0,0,0,128,84Zm0,64a20,20,0,1,1,20-20A20,20,0,0,1,128,148Zm77.39,12.7A83.94,83.94,0,0,1,190.61,184a12,12,0,0,1-17.89-16,59.92,59.92,0,0,0,0-80,12,12,0,0,1,17.89-16,84.07,84.07,0,0,1,14.78,88.7ZM83.28,168a12,12,0,0,1-17.89,16,83.94,83.94,0,0,1,0-112A12,12,0,0,1,83.28,88a59.92,59.92,0,0,0,0,80ZM252,128a123.63,123.63,0,0,1-35.43,86.78A12,12,0,1,1,199.43,198a99.88,99.88,0,0,0,0-140,12,12,0,0,1,17.14-16.8A123.63,123.63,0,0,1,252,128ZM56.57,198a12,12,0,0,1-17.14,16.8,123.89,123.89,0,0,1,0-173.56A12,12,0,0,1,56.57,58a99.88,99.88,0,0,0,0,140Z"/>'),fW=Ha("broadcast","0 0 256 256",'<path d="M168,128a40,40,0,1,1-40-40A40,40,0,0,1,168,128Zm40,0a79.74,79.74,0,0,0-20.37-53.33,8,8,0,1,0-11.92,10.67,64,64,0,0,1,0,85.33,8,8,0,0,0,11.92,10.67A79.79,79.79,0,0,0,208,128ZM80.29,85.34A8,8,0,1,0,68.37,74.67a79.94,79.94,0,0,0,0,106.67,8,8,0,0,0,11.92-10.67,63.95,63.95,0,0,1,0-85.33Zm158.28-4A119.48,119.48,0,0,0,213.71,44a8,8,0,1,0-11.42,11.2,103.9,103.9,0,0,1,0,145.56A8,8,0,1,0,213.71,212,120.12,120.12,0,0,0,238.57,81.29ZM32.17,168.48A103.9,103.9,0,0,1,53.71,55.22,8,8,0,1,0,42.29,44a119.87,119.87,0,0,0,0,168,8,8,0,1,0,11.42-11.2A103.61,103.61,0,0,1,32.17,168.48Z"/>'),pW=Ha("broadcast","0 0 256 256",'<path d="M160,128a32,32,0,1,1-32-32A32,32,0,0,1,160,128Z" opacity="0.2"/><path d="M128,88a40,40,0,1,0,40,40A40,40,0,0,0,128,88Zm0,64a24,24,0,1,1,24-24A24,24,0,0,1,128,152Zm73.71,7.14a80,80,0,0,1-14.08,22.2,8,8,0,0,1-11.92-10.67,63.95,63.95,0,0,0,0-85.33,8,8,0,1,1,11.92-10.67,80.08,80.08,0,0,1,14.08,84.47ZM69,103.09a64,64,0,0,0,11.26,67.58,8,8,0,0,1-11.92,10.67,79.93,79.93,0,0,1,0-106.67A8,8,0,1,1,80.29,85.34,63.77,63.77,0,0,0,69,103.09ZM248,128a119.58,119.58,0,0,1-34.29,84,8,8,0,1,1-11.42-11.2,103.9,103.9,0,0,0,0-145.56A8,8,0,1,1,213.71,44,119.58,119.58,0,0,1,248,128ZM53.71,200.78A8,8,0,1,1,42.29,212a119.87,119.87,0,0,1,0-168,8,8,0,1,1,11.42,11.2,103.9,103.9,0,0,0,0,145.56Z"/>'),_W="broadcast",mW=Object.freeze(Object.defineProperty({__proto__:null,bold:dW,default:_p,duotone:pW,fill:fW,glyphName:_W,light:hW,regular:_p,thin:uW},Symbol.toStringTag,{value:"Module"})),Pa=(e,t,i)=>{const r=s=>Me("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:t,fill:"currentColor",...s,innerHTML:i});return r.displayName="NbGlyph",r.glyphName=e,r},gW=Pa("camera","0 0 256 256",'<path d="M208,60H178.13L163.32,37.78A4,4,0,0,0,160,36H96a4,4,0,0,0-3.32,1.78L77.85,60H48A20,20,0,0,0,28,80V192a20,20,0,0,0,20,20H208a20,20,0,0,0,20-20V80A20,20,0,0,0,208,60Zm12,132a12,12,0,0,1-12,12H48a12,12,0,0,1-12-12V80A12,12,0,0,1,48,68H80a4,4,0,0,0,3.33-1.78L98.13,44h59.72l14.82,22.22A4,4,0,0,0,176,68h32a12,12,0,0,1,12,12ZM128,92a40,40,0,1,0,40,40A40,40,0,0,0,128,92Zm0,72a32,32,0,1,1,32-32A32,32,0,0,1,128,164Z"/>'),vW=Pa("camera","0 0 256 256",'<path d="M208,58H179.21L165,36.67A6,6,0,0,0,160,34H96a6,6,0,0,0-5,2.67L76.78,58H48A22,22,0,0,0,26,80V192a22,22,0,0,0,22,22H208a22,22,0,0,0,22-22V80A22,22,0,0,0,208,58Zm10,134a10,10,0,0,1-10,10H48a10,10,0,0,1-10-10V80A10,10,0,0,1,48,70H80a6,6,0,0,0,5-2.67L99.21,46h57.57L171,67.33A6,6,0,0,0,176,70h32a10,10,0,0,1,10,10ZM128,90a42,42,0,1,0,42,42A42,42,0,0,0,128,90Zm0,72a30,30,0,1,1,30-30A30,30,0,0,1,128,162Z"/>'),mp=Pa("camera","0 0 256 256",'<path d="M208,56H180.28L166.65,35.56A8,8,0,0,0,160,32H96a8,8,0,0,0-6.65,3.56L75.71,56H48A24,24,0,0,0,24,80V192a24,24,0,0,0,24,24H208a24,24,0,0,0,24-24V80A24,24,0,0,0,208,56Zm8,136a8,8,0,0,1-8,8H48a8,8,0,0,1-8-8V80a8,8,0,0,1,8-8H80a8,8,0,0,0,6.66-3.56L100.28,48h55.43l13.63,20.44A8,8,0,0,0,176,72h32a8,8,0,0,1,8,8ZM128,88a44,44,0,1,0,44,44A44.05,44.05,0,0,0,128,88Zm0,72a28,28,0,1,1,28-28A28,28,0,0,1,128,160Z"/>'),bW=Pa("camera","0 0 256 256",'<path d="M208,52H182.42L170,33.34A12,12,0,0,0,160,28H96a12,12,0,0,0-10,5.34L73.57,52H48A28,28,0,0,0,20,80V192a28,28,0,0,0,28,28H208a28,28,0,0,0,28-28V80A28,28,0,0,0,208,52Zm4,140a4,4,0,0,1-4,4H48a4,4,0,0,1-4-4V80a4,4,0,0,1,4-4H80a12,12,0,0,0,10-5.34L102.42,52h51.15L166,70.66A12,12,0,0,0,176,76h32a4,4,0,0,1,4,4ZM128,84a48,48,0,1,0,48,48A48.05,48.05,0,0,0,128,84Zm0,72a24,24,0,1,1,24-24A24,24,0,0,1,128,156Z"/>'),yW=Pa("camera","0 0 256 256",'<path d="M208,56H180.28L166.65,35.56A8,8,0,0,0,160,32H96a8,8,0,0,0-6.65,3.56L75.71,56H48A24,24,0,0,0,24,80V192a24,24,0,0,0,24,24H208a24,24,0,0,0,24-24V80A24,24,0,0,0,208,56Zm-44,76a36,36,0,1,1-36-36A36,36,0,0,1,164,132Z"/>'),wW=Pa("camera","0 0 256 256",'<path d="M208,64H176L160,40H96L80,64H48A16,16,0,0,0,32,80V192a16,16,0,0,0,16,16H208a16,16,0,0,0,16-16V80A16,16,0,0,0,208,64ZM128,168a36,36,0,1,1,36-36A36,36,0,0,1,128,168Z" opacity="0.2"/><path d="M208,56H180.28L166.65,35.56A8,8,0,0,0,160,32H96a8,8,0,0,0-6.65,3.56L75.71,56H48A24,24,0,0,0,24,80V192a24,24,0,0,0,24,24H208a24,24,0,0,0,24-24V80A24,24,0,0,0,208,56Zm8,136a8,8,0,0,1-8,8H48a8,8,0,0,1-8-8V80a8,8,0,0,1,8-8H80a8,8,0,0,0,6.66-3.56L100.28,48h55.43l13.63,20.44A8,8,0,0,0,176,72h32a8,8,0,0,1,8,8ZM128,88a44,44,0,1,0,44,44A44.05,44.05,0,0,0,128,88Zm0,72a28,28,0,1,1,28-28A28,28,0,0,1,128,160Z"/>'),SW="camera",CW=Object.freeze(Object.defineProperty({__proto__:null,bold:bW,default:mp,duotone:wW,fill:yW,glyphName:SW,light:vW,regular:mp,thin:gW},Symbol.toStringTag,{value:"Module"})),Oa=(e,t,i)=>{const r=s=>Me("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:t,fill:"currentColor",...s,innerHTML:i});return r.displayName="NbGlyph",r.glyphName=e,r},kW=Oa("cube","0 0 256 256",'<path d="M221.76,69.66l-88-48.18a12,12,0,0,0-11.52,0l-88,48.18A12,12,0,0,0,28,80.18v95.64a12,12,0,0,0,6.24,10.52l88,48.18a11.95,11.95,0,0,0,11.52,0l88-48.18A12,12,0,0,0,228,175.82V80.18A12,12,0,0,0,221.76,69.66ZM126.08,28.5a3.94,3.94,0,0,1,3.84,0L216.67,76,128,124.52,39.33,76Zm-88,150.83A4,4,0,0,1,36,175.82V83.29l88,48.16v94.91Zm179.84,0-85.92,47V131.45l88-48.16v92.53A4,4,0,0,1,217.92,179.32Z"/>'),AW=Oa("cube","0 0 256 256",'<path d="M222.72,67.9l-88-48.17a13.9,13.9,0,0,0-13.44,0l-88,48.18A14,14,0,0,0,26,80.18v95.64a14,14,0,0,0,7.28,12.27l88,48.18a13.92,13.92,0,0,0,13.44,0l88-48.18A14,14,0,0,0,230,175.82V80.18A14,14,0,0,0,222.72,67.9ZM127,30.25a2,2,0,0,1,1.92,0L212.51,76,128,122.24,43.49,76ZM39,177.57a2,2,0,0,1-1-1.75V86.66l84,46V223Zm177.92,0L134,223V132.64l84-46v89.16A2,2,0,0,1,217,177.57Z"/>'),gp=Oa("cube","0 0 256 256",'<path d="M223.68,66.15,135.68,18h0a15.88,15.88,0,0,0-15.36,0l-88,48.17a16,16,0,0,0-8.32,14v95.64a16,16,0,0,0,8.32,14l88,48.17a15.88,15.88,0,0,0,15.36,0l88-48.17a16,16,0,0,0,8.32-14V80.18A16,16,0,0,0,223.68,66.15ZM128,32h0l80.34,44L128,120,47.66,76ZM40,90l80,43.78v85.79L40,175.82Zm96,129.57V133.82L216,90v85.78Z"/>'),MW=Oa("cube","0 0 256 256",'<path d="M225.6,62.64l-88-48.17a19.91,19.91,0,0,0-19.2,0l-88,48.17A20,20,0,0,0,20,80.19v95.62a20,20,0,0,0,10.4,17.55l88,48.17a19.89,19.89,0,0,0,19.2,0l88-48.17A20,20,0,0,0,236,175.81V80.19A20,20,0,0,0,225.6,62.64ZM128,36.57,200,76,128,115.4,56,76ZM44,96.79l72,39.4v76.67L44,173.44Zm96,116.07V136.19l72-39.4v76.65Z"/>'),LW=Oa("cube","0 0 256 256",'<path d="M223.68,66.15,135.68,18a15.88,15.88,0,0,0-15.36,0l-88,48.17a16,16,0,0,0-8.32,14v95.64a16,16,0,0,0,8.32,14l88,48.17a15.88,15.88,0,0,0,15.36,0l88-48.17a16,16,0,0,0,8.32-14V80.18A16,16,0,0,0,223.68,66.15ZM128,120,47.65,76,128,32l80.35,44Zm8,99.64V133.83l80-43.78v85.76Z"/>'),EW=Oa("cube","0 0 256 256",'<path d="M128,129.09V232a8,8,0,0,1-3.84-1l-88-48.16a8,8,0,0,1-4.16-7V80.2a8,8,0,0,1,.7-3.27Z" opacity="0.2"/><path d="M223.68,66.15,135.68,18h0a15.88,15.88,0,0,0-15.36,0l-88,48.17a16,16,0,0,0-8.32,14v95.64a16,16,0,0,0,8.32,14l88,48.17a15.88,15.88,0,0,0,15.36,0l88-48.17a16,16,0,0,0,8.32-14V80.18A16,16,0,0,0,223.68,66.15ZM128,32h0l80.34,44L128,120,47.66,76ZM40,90l80,43.78v85.79L40,175.82Zm96,129.57V133.82L216,90v85.78Z"/>'),$W="cube",xW=Object.freeze(Object.defineProperty({__proto__:null,bold:MW,default:gp,duotone:EW,fill:LW,glyphName:$W,light:AW,regular:gp,thin:kW},Symbol.toStringTag,{value:"Module"})),Ia=(e,t,i)=>{const r=s=>Me("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:t,fill:"currentColor",...s,innerHTML:i});return r.displayName="NbGlyph",r.glyphName=e,r},TW=Ia("door","0 0 256 256",'<path d="M232,220H204V40a12,12,0,0,0-12-12H64A12,12,0,0,0,52,40V220H24a4,4,0,0,0,0,8H232a4,4,0,0,0,0-8ZM60,40a4,4,0,0,1,4-4H192a4,4,0,0,1,4,4V220H60Zm104,92a8,8,0,1,1-8-8A8,8,0,0,1,164,132Z"/>'),NW=Ia("door","0 0 256 256",'<path d="M232,218H206V40a14,14,0,0,0-14-14H64A14,14,0,0,0,50,40V218H24a6,6,0,0,0,0,12H232a6,6,0,0,0,0-12ZM62,40a2,2,0,0,1,2-2H192a2,2,0,0,1,2,2V218H62Zm104,92a10,10,0,1,1-10-10A10,10,0,0,1,166,132Z"/>'),vp=Ia("door","0 0 256 256",'<path d="M232,216H208V40a16,16,0,0,0-16-16H64A16,16,0,0,0,48,40V216H24a8,8,0,0,0,0,16H232a8,8,0,0,0,0-16ZM64,40H192V216H64Zm104,92a12,12,0,1,1-12-12A12,12,0,0,1,168,132Z"/>'),HW=Ia("door","0 0 256 256",'<path d="M232,212H212V40a20,20,0,0,0-20-20H64A20,20,0,0,0,44,40V212H24a12,12,0,0,0,0,24H232a12,12,0,0,0,0-24ZM68,44H188V212H68Zm104,88a16,16,0,1,1-16-16A16,16,0,0,1,172,132Z"/>'),PW=Ia("door","0 0 256 256",'<path d="M232,216H208V40a16,16,0,0,0-16-16H64A16,16,0,0,0,48,40V216H24a8,8,0,0,0,0,16H232a8,8,0,0,0,0-16Zm-68-72a12,12,0,1,1,12-12A12,12,0,0,1,164,144Z"/>'),OW=Ia("door","0 0 256 256",'<path d="M200,40V224H56V40a8,8,0,0,1,8-8H192A8,8,0,0,1,200,40Z" opacity="0.2"/><path d="M232,216H208V40a16,16,0,0,0-16-16H64A16,16,0,0,0,48,40V216H24a8,8,0,0,0,0,16H232a8,8,0,0,0,0-16ZM64,40H192V216H64Zm104,92a12,12,0,1,1-12-12A12,12,0,0,1,168,132Z"/>'),IW="door",RW=Object.freeze(Object.defineProperty({__proto__:null,bold:HW,default:vp,duotone:OW,fill:PW,glyphName:IW,light:NW,regular:vp,thin:TW},Symbol.toStringTag,{value:"Module"})),Ra=(e,t,i)=>{const r=s=>Me("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:t,fill:"currentColor",...s,innerHTML:i});return r.displayName="NbGlyph",r.glyphName=e,r},DW=Ra("drop","0 0 256 256",'<path d="M171,50.38a250,250,0,0,0-40.73-37.66,4,4,0,0,0-4.58,0A250,250,0,0,0,85,50.38C58.17,81.21,44,113.58,44,144a84,84,0,0,0,168,0C212,113.58,197.83,81.21,171,50.38ZM128,220a76.08,76.08,0,0,1-76-76c0-35.9,21.15-67.8,38.9-88.24A255,255,0,0,1,128,21a255,255,0,0,1,37.1,34.8C182.85,76.2,204,108.1,204,144A76.08,76.08,0,0,1,128,220Zm51.94-67.33a53.51,53.51,0,0,1-43.28,43.27,3.68,3.68,0,0,1-.66.06,4,4,0,0,1-.66-7.94c18.18-3.06,33.63-18.51,36.72-36.73a4,4,0,0,1,7.88,1.34Z"/>'),VW=Ra("drop","0 0 256 256",'<path d="M172.53,49.06a252.86,252.86,0,0,0-41.09-38,6,6,0,0,0-6.88,0,252.86,252.86,0,0,0-41.09,38C56.34,80.26,42,113.09,42,144a86,86,0,0,0,172,0C214,113.09,199.66,80.26,172.53,49.06ZM128,218a74.09,74.09,0,0,1-74-74c0-59.62,59-108.93,74-120.51C143,35.07,202,84.38,202,144A74.09,74.09,0,0,1,128,218Zm53.92-65A55.58,55.58,0,0,1,137,197.92a7,7,0,0,1-1,.08,6,6,0,0,1-1-11.92c17.38-2.92,32.13-17.68,35.08-35.08a6,6,0,1,1,11.84,2Z"/>'),bp=Ra("drop","0 0 256 256",'<path d="M174,47.75a254.19,254.19,0,0,0-41.45-38.3,8,8,0,0,0-9.18,0A254.19,254.19,0,0,0,82,47.75C54.51,79.32,40,112.6,40,144a88,88,0,0,0,176,0C216,112.6,201.49,79.32,174,47.75ZM128,216a72.08,72.08,0,0,1-72-72c0-57.23,55.47-105,72-118,16.53,13,72,60.75,72,118A72.08,72.08,0,0,1,128,216Zm55.89-62.66a57.6,57.6,0,0,1-46.56,46.55A8.75,8.75,0,0,1,136,200a8,8,0,0,1-1.32-15.89c16.57-2.79,30.63-16.85,33.44-33.45a8,8,0,0,1,15.78,2.68Z"/>'),BW=Ra("drop","0 0 256 256",'<path d="M134.88,6.17a12,12,0,0,0-13.76,0,259,259,0,0,0-42.18,39C50.85,77.43,36,111.62,36,144a92,92,0,0,0,184,0C220,66.64,138.36,8.6,134.88,6.17ZM128,212a68.07,68.07,0,0,1-68-68c0-33.31,20-63.37,36.7-82.71A249.35,249.35,0,0,1,128,31.11a249.35,249.35,0,0,1,31.3,30.18C176,80.63,196,110.69,196,144A68.07,68.07,0,0,1,128,212Zm49.62-52.4a52,52,0,0,1-34,34,12.2,12.2,0,0,1-3.6.55,12,12,0,0,1-3.6-23.45,28,28,0,0,0,18.32-18.32,12,12,0,0,1,22.9,7.2Z"/>'),ZW=Ra("drop","0 0 256 256",'<path d="M174,47.75a254.19,254.19,0,0,0-41.45-38.3,8,8,0,0,0-9.18,0A254.19,254.19,0,0,0,82,47.75C54.51,79.32,40,112.6,40,144a88,88,0,0,0,176,0C216,112.6,201.49,79.32,174,47.75Zm9.85,105.59a57.6,57.6,0,0,1-46.56,46.55A8.75,8.75,0,0,1,136,200a8,8,0,0,1-1.32-15.89c16.57-2.79,30.63-16.85,33.44-33.45a8,8,0,0,1,15.78,2.68Z"/>'),FW=Ra("drop","0 0 256 256",'<path d="M208,144a80,80,0,0,1-160,0c0-72,80-128,80-128S208,72,208,144Z" opacity="0.2"/><path d="M174,47.75a254.19,254.19,0,0,0-41.45-38.3,8,8,0,0,0-9.18,0A254.19,254.19,0,0,0,82,47.75C54.51,79.32,40,112.6,40,144a88,88,0,0,0,176,0C216,112.6,201.49,79.32,174,47.75ZM128,216a72.08,72.08,0,0,1-72-72c0-57.23,55.47-105,72-118,16.53,13,72,60.75,72,118A72.08,72.08,0,0,1,128,216Zm55.89-62.66a57.6,57.6,0,0,1-46.56,46.55A8.75,8.75,0,0,1,136,200a8,8,0,0,1-1.32-15.89c16.57-2.79,30.63-16.85,33.44-33.45a8,8,0,0,1,15.78,2.68Z"/>'),zW="drop",UW=Object.freeze(Object.defineProperty({__proto__:null,bold:BW,default:bp,duotone:FW,fill:ZW,glyphName:zW,light:VW,regular:bp,thin:DW},Symbol.toStringTag,{value:"Module"})),Da=(e,t,i)=>{const r=s=>Me("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:t,fill:"currentColor",...s,innerHTML:i});return r.displayName="NbGlyph",r.glyphName=e,r},WW=Da("fan","0 0 256 256",'<path d="M229.12,136a56,56,0,0,0-86-31.56,28.25,28.25,0,0,0-4.56-2.39l17.27-68.94a4,4,0,0,0-1.72-4.34A56,56,0,1,0,100,126.62c0,.46,0,.92,0,1.38a27.39,27.39,0,0,0,.26,3.76L31.91,151.28A4,4,0,0,0,29,154.94a56,56,0,0,0,41.45,56.62,56.46,56.46,0,0,0,14.59,1.93,56.07,56.07,0,0,0,55.73-60.59,27.93,27.93,0,0,0,4.33-2.77l51.09,49.44A4,4,0,0,0,199,200.7a4.06,4.06,0,0,0,1.84-.45A56,56,0,0,0,229.12,136ZM128,148a20,20,0,1,1,20-20A20,20,0,0,1,128,148ZM76,76a48,48,0,0,1,71.4-41.92l-16.55,66.06c-.94-.09-1.89-.14-2.85-.14a28.06,28.06,0,0,0-26.34,18.49A47.82,47.82,0,0,1,76,76Zm33,123a48,48,0,0,1-72-40.87l65.5-18.7A28,28,0,0,0,128,156a28.81,28.81,0,0,0,4.94-.44A47.81,47.81,0,0,1,109,199ZM216.6,174.54a47.93,47.93,0,0,1-17,17.22l-49-47.37a27.91,27.91,0,0,0-1.3-34.44,48,48,0,0,1,67.22,64.59Z"/>'),jW=Da("fan","0 0 256 256",'<path d="M231.06,135.52a58,58,0,0,0-88-33.42c-.69-.41-1.41-.8-2.14-1.15l16.86-67.32a6,6,0,0,0-2.58-6.51A58,58,0,1,0,98,127.86V128c0,.77,0,1.54.1,2.3L31.37,149.36A6,6,0,0,0,27,154.85,58,58,0,1,0,142.88,154c.7-.4,1.39-.83,2.06-1.29L194.81,201a6,6,0,0,0,6.94,1,58,58,0,0,0,29.31-66.51ZM110,128a18,18,0,1,1,18,18A18,18,0,0,1,110,128ZM78,76a46,46,0,0,1,67.08-40.9L129.32,98q-.66,0-1.32,0a30,30,0,0,0-27.33,17.66A45.84,45.84,0,0,1,78,76Zm30,121.3a46,46,0,0,1-69-37.64l62.39-17.82A30,30,0,0,0,128,158a29.29,29.29,0,0,0,3-.15A45.85,45.85,0,0,1,108,197.3Zm106.9-23.76a45.91,45.91,0,0,1-15,15.7l-46.63-45.12a29.91,29.91,0,0,0-.93-33.62,46,46,0,0,1,62.52,63Z"/>'),yp=Da("fan","0 0 256 256",'<path d="M233,135a60,60,0,0,0-89.62-35.45l16.39-65.44a8,8,0,0,0-3.45-8.68A60,60,0,1,0,95.69,128.91L30.82,147.44a8,8,0,0,0-5.8,7.32,60,60,0,0,0,44.42,60.66,60.52,60.52,0,0,0,15.62,2.07,60.07,60.07,0,0,0,59.88-62l48.48,46.92a8,8,0,0,0,9.25,1.35A60,60,0,0,0,233,135Zm-121-7a16,16,0,1,1,16,16A16,16,0,0,1,112,128ZM80,76a44,44,0,0,1,62.75-39.82L127.77,96A32,32,0,0,0,99.85,112.8,43.85,43.85,0,0,1,80,76Zm27,119.57a44,44,0,0,1-65.86-34.43l59.31-16.94A32,32,0,0,0,128,160l.91,0A43.82,43.82,0,0,1,107,195.57Zm106.17-23a43.92,43.92,0,0,1-13,14.14l-44.32-42.89a31.91,31.91,0,0,0-.59-32.57,44,44,0,0,1,57.91,61.32Z"/>'),KW=Da("fan","0 0 256 256",'<path d="M236.85,134a64,64,0,0,0-87.43-42.11l14.22-56.77a12,12,0,0,0-5.17-13A64,64,0,0,0,86,127.52L29.72,143.59a12,12,0,0,0-8.69,11,64,64,0,0,0,127.56,10l42,40.7a12,12,0,0,0,13.86,2A64,64,0,0,0,236.85,134ZM116,128a12,12,0,1,1,12,12A12,12,0,0,1,116,128Zm8-92a40,40,0,0,1,14,2.53L124.6,92.17a36,36,0,0,0-25.85,14.88A40,40,0,0,1,124,36ZM105,192.1A40,40,0,0,1,45.5,164l53.18-15.19a36,36,0,0,0,25.8,15A39.84,39.84,0,0,1,105,192.1Zm104.7-21.56a39.92,39.92,0,0,1-9.21,10.89L160.73,143a35.9,35.9,0,0,0,.05-29.83,40,40,0,0,1,48.89,57.4Z"/>'),qW=Da("fan","0 0 256 256",'<path d="M233,135a60,60,0,0,0-89.62-35.45l16.39-65.44a8,8,0,0,0-3.45-8.68A60,60,0,1,0,95.69,128.91L30.82,147.44a8,8,0,0,0-5.8,7.32,60,60,0,0,0,44.42,60.66,60.52,60.52,0,0,0,15.62,2.07,60.07,60.07,0,0,0,59.88-62l48.48,46.92a8,8,0,0,0,9.25,1.35A60,60,0,0,0,233,135ZM130.44,147.85a20,20,0,1,1,17.41-22.29A20,20,0,0,1,130.44,147.85Z"/>'),GW=Da("fan","0 0 256 256",'<path d="M136.5,150.45A52,52,0,1,1,33,155.13l71.91-20.54h0A24,24,0,0,0,128,152a23.75,23.75,0,0,0,8.5-1.56Zm-32.19-26.31h0a24,24,0,0,1,29.52-19.42h0L152,32.17a52,52,0,1,0-47.69,92ZM201,105.5a52,52,0,0,0-57.84,3.91h0a24,24,0,0,1,2.06,35.26h0l53.74,52a52,52,0,0,0,2-91.2Z" opacity="0.2"/><path d="M233,135a60,60,0,0,0-89.62-35.45l16.39-65.44a8,8,0,0,0-3.45-8.68A60,60,0,1,0,95.69,128.91L30.82,147.44a8,8,0,0,0-5.8,7.32,60,60,0,0,0,44.42,60.66,60.52,60.52,0,0,0,15.62,2.07,60.07,60.07,0,0,0,59.88-62l48.48,46.92a8,8,0,0,0,9.25,1.35A60,60,0,0,0,233,135Zm-121-7a16,16,0,1,1,16,16A16,16,0,0,1,112,128ZM80,76a44,44,0,0,1,62.75-39.82L127.77,96A32,32,0,0,0,99.85,112.8,43.85,43.85,0,0,1,80,76Zm27,119.57a44,44,0,0,1-65.86-34.43l59.31-16.94A32,32,0,0,0,128,160l.91,0A43.82,43.82,0,0,1,107,195.57Zm106.17-23a43.92,43.92,0,0,1-13,14.14l-44.32-42.89a31.91,31.91,0,0,0-.59-32.57,44,44,0,0,1,57.91,61.32Z"/>'),YW="fan",XW=Object.freeze(Object.defineProperty({__proto__:null,bold:KW,default:yp,duotone:GW,fill:qW,glyphName:YW,light:jW,regular:yp,thin:WW},Symbol.toStringTag,{value:"Module"})),Va=(e,t,i)=>{const r=s=>Me("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:t,fill:"currentColor",...s,innerHTML:i});return r.displayName="NbGlyph",r.glyphName=e,r},JW=Va("game-controller","0 0 256 256",'<path d="M176,108H152a4,4,0,0,1,0-8h24a4,4,0,0,1,0,8Zm-72-8H92V88a4,4,0,0,0-8,0v12H72a4,4,0,0,0,0,8H84v12a4,4,0,0,0,8,0V108h12a4,4,0,0,0,0-8Zm134.21,98.36a32,32,0,0,1-48.84,4.27l-.17-.18L148.29,156H107.72L66.81,202.44l-.18.19A32.08,32.08,0,0,1,44,212a32,32,0,0,1-31.5-37.56L28.87,90.21A55.87,55.87,0,0,1,83.89,44H172a56.07,56.07,0,0,1,55.1,46.1.29.29,0,0,1,0,.1l16.37,84.16A31.86,31.86,0,0,1,238.21,198.36ZM172,148a48,48,0,1,0,0-96H83.9A47.9,47.9,0,0,0,36.74,91.67L20.36,175.9a24,24,0,0,0,19.48,27.73,24,24,0,0,0,21-6.58l42-47.69a4,4,0,0,1,3-1.36Zm63.63,27.83-11-56.66A56.09,56.09,0,0,1,172,156H159l36.16,41.06a24,24,0,0,0,40.52-21.23Z"/>'),QW=Va("game-controller","0 0 256 256",'<path d="M176,110H152a6,6,0,0,1,0-12h24a6,6,0,0,1,0,12ZM104,98H94V88a6,6,0,0,0-12,0V98H72a6,6,0,0,0,0,12H82v10a6,6,0,0,0,12,0V110h10a6,6,0,0,0,0-12ZM239.84,199.5A34,34,0,0,1,212,214,34.11,34.11,0,0,1,188,204.05l-.26-.28L147.38,158H108.62L68.31,203.76,68,204A34,34,0,0,1,44,214a34,34,0,0,1-33.46-39.91s0-.06,0-.1L26.9,89.88A57.89,57.89,0,0,1,83.89,42H172a58.07,58.07,0,0,1,57.05,47.63c0,.07,0,.12,0,.19L245.46,174s0,.07,0,.11A33.75,33.75,0,0,1,239.84,199.5ZM172,146a46,46,0,0,0,0-92H83.89A45.9,45.9,0,0,0,38.71,92a.36.36,0,0,0,0,.1L22.33,176.23a22,22,0,0,0,37.11,19.45l42-47.65a6,6,0,0,1,4.5-2Zm61.67,30.23-9.79-50.35A58.06,58.06,0,0,1,172,158h-8.63l33.19,37.68a22,22,0,0,0,37.11-19.45Z"/>'),wp=Va("game-controller","0 0 256 256",'<path d="M176,112H152a8,8,0,0,1,0-16h24a8,8,0,0,1,0,16ZM104,96H96V88a8,8,0,0,0-16,0v8H72a8,8,0,0,0,0,16h8v8a8,8,0,0,0,16,0v-8h8a8,8,0,0,0,0-16ZM241.48,200.65a36,36,0,0,1-54.94,4.81c-.12-.12-.24-.24-.35-.37L146.48,160h-37L69.81,205.09l-.35.37A36.08,36.08,0,0,1,44,216,36,36,0,0,1,8.56,173.75a.68.68,0,0,1,0-.14L24.93,89.52A59.88,59.88,0,0,1,83.89,40H172a60.08,60.08,0,0,1,59,49.25c0,.06,0,.12,0,.18l16.37,84.17a.68.68,0,0,1,0,.14A35.74,35.74,0,0,1,241.48,200.65ZM172,144a44,44,0,0,0,0-88H83.89A43.9,43.9,0,0,0,40.68,92.37l0,.13L24.3,176.59A20,20,0,0,0,58,194.3l41.92-47.59a8,8,0,0,1,6-2.71Zm59.7,32.59-8.74-45A60,60,0,0,1,172,160h-4.2L198,194.31a20.09,20.09,0,0,0,17.46,5.39,20,20,0,0,0,16.23-23.11Z"/>'),ej=Va("game-controller","0 0 256 256",'<path d="M176,116H152a12,12,0,0,1,0-24h24a12,12,0,0,1,0,24ZM104,92h-4V88a12,12,0,0,0-24,0v4H72a12,12,0,0,0,0,24h4v4a12,12,0,0,0,24,0v-4h4a12,12,0,0,0,0-24ZM244.76,202.94a40,40,0,0,1-61,5.35,7,7,0,0,1-.53-.56L144.67,164H111.33L72.81,207.73c-.17.19-.35.38-.53.56A40,40,0,0,1,4.62,173.05a1.18,1.18,0,0,1,0-.2L21,88.79A63.88,63.88,0,0,1,83.88,36H172a64.08,64.08,0,0,1,62.93,52.48,1.8,1.8,0,0,1,0,.19l16.36,84.17a1.77,1.77,0,0,1,0,.2A39.74,39.74,0,0,1,244.76,202.94ZM172,140a40,40,0,0,0,0-80H83.89A39.9,39.9,0,0,0,44.62,93.06a1.55,1.55,0,0,0,0,.21l-16.34,84a16,16,0,0,0,13,18.44,16.07,16.07,0,0,0,13.86-4.21L96.9,144.07a12,12,0,0,1,9-4.07Zm55.76,37.31-7-35.95a63.84,63.84,0,0,1-44.27,22.46l24.41,27.72a16,16,0,0,0,26.85-14.23Z"/>'),tj=Va("game-controller","0 0 256 256",'<path d="M247.44,173.75a.68.68,0,0,0,0-.14L231.05,89.44c0-.06,0-.12,0-.18A60.08,60.08,0,0,0,172,40H83.89a59.88,59.88,0,0,0-59,49.52L8.58,173.61a.68.68,0,0,0,0,.14,36,36,0,0,0,60.9,31.71l.35-.37L109.52,160h37l39.71,45.09c.11.13.23.25.35.37A36.08,36.08,0,0,0,212,216a36,36,0,0,0,35.43-42.25ZM104,112H96v8a8,8,0,0,1-16,0v-8H72a8,8,0,0,1,0-16h8V88a8,8,0,0,1,16,0v8h8a8,8,0,0,1,0,16Zm40-8a8,8,0,0,1,8-8h24a8,8,0,0,1,0,16H152A8,8,0,0,1,144,104Zm84.37,87.47a19.84,19.84,0,0,1-12.9,8.23A20.09,20.09,0,0,1,198,194.31L167.8,160H172a60,60,0,0,0,51-28.38l8.74,45A19.82,19.82,0,0,1,228.37,191.47Z"/>'),ij=Va("game-controller","0 0 256 256",'<path d="M216.86,207.57a28,28,0,0,1-24.66-7.77L150.09,152H172a51.94,51.94,0,0,0,51.2-61h0l16.36,84.17A28,28,0,0,1,216.86,207.57Z" opacity="0.2"/><path d="M176,112H152a8,8,0,0,1,0-16h24a8,8,0,0,1,0,16ZM104,96H96V88a8,8,0,0,0-16,0v8H72a8,8,0,0,0,0,16h8v8a8,8,0,0,0,16,0v-8h8a8,8,0,0,0,0-16ZM241.48,200.65a36,36,0,0,1-54.94,4.81c-.12-.12-.24-.24-.35-.37L146.48,160h-37L69.81,205.09l-.35.37A36.08,36.08,0,0,1,44,216,36,36,0,0,1,8.56,173.75a.68.68,0,0,1,0-.14L24.93,89.52A59.88,59.88,0,0,1,83.89,40H172a60.08,60.08,0,0,1,59,49.25c0,.06,0,.12,0,.18l16.37,84.17a.68.68,0,0,1,0,.14A35.74,35.74,0,0,1,241.48,200.65ZM172,144a44,44,0,0,0,0-88H83.89A43.9,43.9,0,0,0,40.68,92.37l0,.13L24.3,176.59A20,20,0,0,0,58,194.3l41.92-47.59a8,8,0,0,1,6-2.71Zm59.7,32.59-8.74-45A60,60,0,0,1,172,160h-4.2L198,194.31a20.09,20.09,0,0,0,17.46,5.39,20,20,0,0,0,16.23-23.11Z"/>'),rj="game-controller",sj=Object.freeze(Object.defineProperty({__proto__:null,bold:ej,default:wp,duotone:ij,fill:tj,glyphName:rj,light:QW,regular:wp,thin:JW},Symbol.toStringTag,{value:"Module"})),Ba=(e,t,i)=>{const r=s=>Me("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:t,fill:"currentColor",...s,innerHTML:i});return r.displayName="NbGlyph",r.glyphName=e,r},nj=Ba("garage","0 0 256 256",'<path d="M240,196H228V98.67a12,12,0,0,0-5.34-10L134.66,30a12,12,0,0,0-13.32,0l-88,58.67a12,12,0,0,0-5.34,10V196H16a4,4,0,0,0,0,8H240a4,4,0,0,0,0-8ZM36,98.67a4,4,0,0,1,1.78-3.33l88-58.66a4,4,0,0,1,4.44,0l88,58.66A4,4,0,0,1,220,98.67V196H188V136a4,4,0,0,0-4-4H72a4,4,0,0,0-4,4v60H36ZM180,140v24H132V140Zm-56,24H76V140h48Zm-48,8h48v24H76Zm56,0h48v24H132Z"/>'),aj=Ba("garage","0 0 256 256",'<path d="M240,194H230V98.67A14,14,0,0,0,223.77,87l-88-58.66a14,14,0,0,0-15.54,0L32.23,87A14,14,0,0,0,26,98.67V194H16a6,6,0,0,0,0,12H240a6,6,0,0,0,0-12ZM38,98.67A2,2,0,0,1,38.89,97l88-58.67a2,2,0,0,1,2.22,0l88,58.67a2,2,0,0,1,.89,1.66V194H190V136a6,6,0,0,0-6-6H72a6,6,0,0,0-6,6v58H38ZM178,142v20H134V142Zm-56,20H78V142h44ZM78,174h44v20H78Zm56,0h44v20H134Z"/>'),Sp=Ba("garage","0 0 256 256",'<path d="M240,192h-8V98.67a16,16,0,0,0-7.12-13.31l-88-58.67a16,16,0,0,0-17.75,0l-88,58.67A16,16,0,0,0,24,98.67V192H16a8,8,0,0,0,0,16H240a8,8,0,0,0,0-16ZM40,98.67,128,40l88,58.66V192H192V136a8,8,0,0,0-8-8H72a8,8,0,0,0-8,8v56H40ZM176,144v16H136V144Zm-56,16H80V144h40ZM80,176h40v16H80Zm56,0h40v16H136Z"/>'),oj=Ba("garage","0 0 256 256",'<path d="M240,188h-4V98.67A20,20,0,0,0,227.09,82l-88-58.66a19.94,19.94,0,0,0-22.18,0L28.91,82A20,20,0,0,0,20,98.67V188H16a12,12,0,0,0,0,24H240a12,12,0,0,0,0-24ZM44,100.81l84-56,84,56V188H196V120a12,12,0,0,0-12-12H72a12,12,0,0,0-12,12v68H44ZM172,132v16H140V132Zm-56,16H84V132h32ZM84,172h32v16H84Zm56,0h32v16H140Z"/>'),lj=Ba("garage","0 0 256 256",'<path d="M240,192h-8V98.67a16,16,0,0,0-7.12-13.31l-88-58.67a16,16,0,0,0-17.75,0l-88,58.67A16,16,0,0,0,24,98.67V192H16a8,8,0,0,0,0,16H240a8,8,0,0,0,0-16ZM136,128h56v24H136Zm-16,24H64V128h56ZM64,168h56v24H64Zm72,0h56v24H136Z"/>'),cj=Ba("garage","0 0 256 256",'<path d="M184,136v64H72V136Z" opacity="0.2"/><path d="M240,192h-8V98.67a16,16,0,0,0-7.12-13.31l-88-58.67a16,16,0,0,0-17.75,0l-88,58.67A16,16,0,0,0,24,98.67V192H16a8,8,0,0,0,0,16H240a8,8,0,0,0,0-16ZM40,98.67,128,40l88,58.66V192H192V136a8,8,0,0,0-8-8H72a8,8,0,0,0-8,8v56H40ZM176,144v16H136V144Zm-56,16H80V144h40ZM80,176h40v16H80Zm56,0h40v16H136Z"/>'),uj="garage",hj=Object.freeze(Object.defineProperty({__proto__:null,bold:oj,default:Sp,duotone:cj,fill:lj,glyphName:uj,light:aj,regular:Sp,thin:nj},Symbol.toStringTag,{value:"Module"})),Za=(e,t,i)=>{const r=s=>Me("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:t,fill:"currentColor",...s,innerHTML:i});return r.displayName="NbGlyph",r.glyphName=e,r},dj=Za("gear","0 0 256 256",'<path d="M128,84a44,44,0,1,0,44,44A44.05,44.05,0,0,0,128,84Zm0,80a36,36,0,1,1,36-36A36,36,0,0,1,128,164Zm83.93-32.49q.13-3.51,0-7l15.83-19.79a4,4,0,0,0,.75-3.53A103.64,103.64,0,0,0,218,75.9a4,4,0,0,0-3-2l-25.19-2.8c-1.58-1.71-3.24-3.37-4.95-4.95L182.07,41a4,4,0,0,0-2-3A104,104,0,0,0,154.82,27.5a4,4,0,0,0-3.53.74L131.51,44.07q-3.51-.14-7,0L104.7,28.24a4,4,0,0,0-3.53-.75A103.64,103.64,0,0,0,75.9,38a4,4,0,0,0-2,3l-2.8,25.19c-1.71,1.58-3.37,3.24-4.95,4.95L41,73.93a4,4,0,0,0-3,2A104,104,0,0,0,27.5,101.18a4,4,0,0,0,.74,3.53l15.83,19.78q-.14,3.51,0,7L28.24,151.3a4,4,0,0,0-.75,3.53A103.64,103.64,0,0,0,38,180.1a4,4,0,0,0,3,2l25.19,2.8c1.58,1.71,3.24,3.37,4.95,4.95l2.8,25.2a4,4,0,0,0,2,3,104,104,0,0,0,25.28,10.46,4,4,0,0,0,3.53-.74l19.78-15.83q3.51.13,7,0l19.79,15.83a4,4,0,0,0,2.5.88,4,4,0,0,0,1-.13A103.64,103.64,0,0,0,180.1,218a4,4,0,0,0,2-3l2.8-25.19c1.71-1.58,3.37-3.24,4.95-4.95l25.2-2.8a4,4,0,0,0,3-2,104,104,0,0,0,10.46-25.28,4,4,0,0,0-.74-3.53Zm.17,42.83-24.67,2.74a4,4,0,0,0-2.55,1.32,76.2,76.2,0,0,1-6.48,6.48,4,4,0,0,0-1.32,2.55l-2.74,24.66a95.45,95.45,0,0,1-19.64,8.15l-19.38-15.51a4,4,0,0,0-2.5-.87h-.24a73.67,73.67,0,0,1-9.16,0,4,4,0,0,0-2.74.87l-19.37,15.5a95.33,95.33,0,0,1-19.65-8.13l-2.74-24.67a4,4,0,0,0-1.32-2.55,76.2,76.2,0,0,1-6.48-6.48,4,4,0,0,0-2.55-1.32l-24.66-2.74a95.45,95.45,0,0,1-8.15-19.64l15.51-19.38a4,4,0,0,0,.87-2.74,77.76,77.76,0,0,1,0-9.16,4,4,0,0,0-.87-2.74l-15.5-19.37A95.33,95.33,0,0,1,43.9,81.66l24.67-2.74a4,4,0,0,0,2.55-1.32,76.2,76.2,0,0,1,6.48-6.48,4,4,0,0,0,1.32-2.55l2.74-24.66a95.45,95.45,0,0,1,19.64-8.15l19.38,15.51a4,4,0,0,0,2.74.87,73.67,73.67,0,0,1,9.16,0,4,4,0,0,0,2.74-.87l19.37-15.5a95.33,95.33,0,0,1,19.65,8.13l2.74,24.67a4,4,0,0,0,1.32,2.55,76.2,76.2,0,0,1,6.48,6.48,4,4,0,0,0,2.55,1.32l24.66,2.74a95.45,95.45,0,0,1,8.15,19.64l-15.51,19.38a4,4,0,0,0-.87,2.74,77.76,77.76,0,0,1,0,9.16,4,4,0,0,0,.87,2.74l15.5,19.37A95.33,95.33,0,0,1,212.1,174.34Z"/>'),fj=Za("gear","0 0 256 256",'<path d="M128,82a46,46,0,1,0,46,46A46.06,46.06,0,0,0,128,82Zm0,80a34,34,0,1,1,34-34A34,34,0,0,1,128,162ZM214,130.84c.06-1.89.06-3.79,0-5.68L229.33,106a6,6,0,0,0,1.11-5.29A105.34,105.34,0,0,0,219.76,74.9a6,6,0,0,0-4.53-3l-24.45-2.71q-1.93-2.07-4-4l-2.72-24.46a6,6,0,0,0-3-4.53,105.65,105.65,0,0,0-25.77-10.66A6,6,0,0,0,150,26.68l-19.2,15.37c-1.89-.06-3.79-.06-5.68,0L106,26.67a6,6,0,0,0-5.29-1.11A105.34,105.34,0,0,0,74.9,36.24a6,6,0,0,0-3,4.53L69.23,65.22q-2.07,1.94-4,4L40.76,72a6,6,0,0,0-4.53,3,105.65,105.65,0,0,0-10.66,25.77A6,6,0,0,0,26.68,106l15.37,19.2c-.06,1.89-.06,3.79,0,5.68L26.67,150.05a6,6,0,0,0-1.11,5.29A105.34,105.34,0,0,0,36.24,181.1a6,6,0,0,0,4.53,3l24.45,2.71q1.94,2.07,4,4L72,215.24a6,6,0,0,0,3,4.53,105.65,105.65,0,0,0,25.77,10.66,6,6,0,0,0,5.29-1.11L125.16,214c1.89.06,3.79.06,5.68,0l19.21,15.38a6,6,0,0,0,3.75,1.31,6.2,6.2,0,0,0,1.54-.2,105.34,105.34,0,0,0,25.76-10.68,6,6,0,0,0,3-4.53l2.71-24.45q2.07-1.93,4-4l24.46-2.72a6,6,0,0,0,4.53-3,105.49,105.49,0,0,0,10.66-25.77,6,6,0,0,0-1.11-5.29Zm-3.1,41.63-23.64,2.63a6,6,0,0,0-3.82,2,75.14,75.14,0,0,1-6.31,6.31,6,6,0,0,0-2,3.82l-2.63,23.63A94.28,94.28,0,0,1,155.14,218l-18.57-14.86a6,6,0,0,0-3.75-1.31h-.36a78.07,78.07,0,0,1-8.92,0,6,6,0,0,0-4.11,1.3L100.87,218a94.13,94.13,0,0,1-17.34-7.17L80.9,187.21a6,6,0,0,0-2-3.82,75.14,75.14,0,0,1-6.31-6.31,6,6,0,0,0-3.82-2l-23.63-2.63A94.28,94.28,0,0,1,38,155.14l14.86-18.57a6,6,0,0,0,1.3-4.11,78.07,78.07,0,0,1,0-8.92,6,6,0,0,0-1.3-4.11L38,100.87a94.13,94.13,0,0,1,7.17-17.34L68.79,80.9a6,6,0,0,0,3.82-2,75.14,75.14,0,0,1,6.31-6.31,6,6,0,0,0,2-3.82l2.63-23.63A94.28,94.28,0,0,1,100.86,38l18.57,14.86a6,6,0,0,0,4.11,1.3,78.07,78.07,0,0,1,8.92,0,6,6,0,0,0,4.11-1.3L155.13,38a94.13,94.13,0,0,1,17.34,7.17l2.63,23.64a6,6,0,0,0,2,3.82,75.14,75.14,0,0,1,6.31,6.31,6,6,0,0,0,3.82,2l23.63,2.63A94.28,94.28,0,0,1,218,100.86l-14.86,18.57a6,6,0,0,0-1.3,4.11,78.07,78.07,0,0,1,0,8.92,6,6,0,0,0,1.3,4.11L218,155.13A94.13,94.13,0,0,1,210.85,172.47Z"/>'),Cp=Za("gear","0 0 256 256",'<path d="M128,80a48,48,0,1,0,48,48A48.05,48.05,0,0,0,128,80Zm0,80a32,32,0,1,1,32-32A32,32,0,0,1,128,160Zm88-29.84q.06-2.16,0-4.32l14.92-18.64a8,8,0,0,0,1.48-7.06,107.21,107.21,0,0,0-10.88-26.25,8,8,0,0,0-6-3.93l-23.72-2.64q-1.48-1.56-3-3L186,40.54a8,8,0,0,0-3.94-6,107.71,107.71,0,0,0-26.25-10.87,8,8,0,0,0-7.06,1.49L130.16,40Q128,40,125.84,40L107.2,25.11a8,8,0,0,0-7.06-1.48A107.6,107.6,0,0,0,73.89,34.51a8,8,0,0,0-3.93,6L67.32,64.27q-1.56,1.49-3,3L40.54,70a8,8,0,0,0-6,3.94,107.71,107.71,0,0,0-10.87,26.25,8,8,0,0,0,1.49,7.06L40,125.84Q40,128,40,130.16L25.11,148.8a8,8,0,0,0-1.48,7.06,107.21,107.21,0,0,0,10.88,26.25,8,8,0,0,0,6,3.93l23.72,2.64q1.49,1.56,3,3L70,215.46a8,8,0,0,0,3.94,6,107.71,107.71,0,0,0,26.25,10.87,8,8,0,0,0,7.06-1.49L125.84,216q2.16.06,4.32,0l18.64,14.92a8,8,0,0,0,7.06,1.48,107.21,107.21,0,0,0,26.25-10.88,8,8,0,0,0,3.93-6l2.64-23.72q1.56-1.48,3-3L215.46,186a8,8,0,0,0,6-3.94,107.71,107.71,0,0,0,10.87-26.25,8,8,0,0,0-1.49-7.06Zm-16.1-6.5a73.93,73.93,0,0,1,0,8.68,8,8,0,0,0,1.74,5.48l14.19,17.73a91.57,91.57,0,0,1-6.23,15L187,173.11a8,8,0,0,0-5.1,2.64,74.11,74.11,0,0,1-6.14,6.14,8,8,0,0,0-2.64,5.1l-2.51,22.58a91.32,91.32,0,0,1-15,6.23l-17.74-14.19a8,8,0,0,0-5-1.75h-.48a73.93,73.93,0,0,1-8.68,0,8,8,0,0,0-5.48,1.74L100.45,215.8a91.57,91.57,0,0,1-15-6.23L82.89,187a8,8,0,0,0-2.64-5.1,74.11,74.11,0,0,1-6.14-6.14,8,8,0,0,0-5.1-2.64L46.43,170.6a91.32,91.32,0,0,1-6.23-15l14.19-17.74a8,8,0,0,0,1.74-5.48,73.93,73.93,0,0,1,0-8.68,8,8,0,0,0-1.74-5.48L40.2,100.45a91.57,91.57,0,0,1,6.23-15L69,82.89a8,8,0,0,0,5.1-2.64,74.11,74.11,0,0,1,6.14-6.14A8,8,0,0,0,82.89,69L85.4,46.43a91.32,91.32,0,0,1,15-6.23l17.74,14.19a8,8,0,0,0,5.48,1.74,73.93,73.93,0,0,1,8.68,0,8,8,0,0,0,5.48-1.74L155.55,40.2a91.57,91.57,0,0,1,15,6.23L173.11,69a8,8,0,0,0,2.64,5.1,74.11,74.11,0,0,1,6.14,6.14,8,8,0,0,0,5.1,2.64l22.58,2.51a91.32,91.32,0,0,1,6.23,15l-14.19,17.74A8,8,0,0,0,199.87,123.66Z"/>'),pj=Za("gear","0 0 256 256",'<path d="M128,76a52,52,0,1,0,52,52A52.06,52.06,0,0,0,128,76Zm0,80a28,28,0,1,1,28-28A28,28,0,0,1,128,156Zm92-27.21v-1.58l14-17.51a12,12,0,0,0,2.23-10.59A111.75,111.75,0,0,0,225,71.89,12,12,0,0,0,215.89,66L193.61,63.5l-1.11-1.11L190,40.1A12,12,0,0,0,184.11,31a111.67,111.67,0,0,0-27.23-11.27A12,12,0,0,0,146.3,22L128.79,36h-1.58L109.7,22a12,12,0,0,0-10.59-2.23A111.75,111.75,0,0,0,71.89,31.05,12,12,0,0,0,66,40.11L63.5,62.39,62.39,63.5,40.1,66A12,12,0,0,0,31,71.89,111.67,111.67,0,0,0,19.77,99.12,12,12,0,0,0,22,109.7l14,17.51v1.58L22,146.3a12,12,0,0,0-2.23,10.59,111.75,111.75,0,0,0,11.29,27.22A12,12,0,0,0,40.11,190l22.28,2.48,1.11,1.11L66,215.9A12,12,0,0,0,71.89,225a111.67,111.67,0,0,0,27.23,11.27A12,12,0,0,0,109.7,234l17.51-14h1.58l17.51,14a12,12,0,0,0,10.59,2.23A111.75,111.75,0,0,0,184.11,225a12,12,0,0,0,5.91-9.06l2.48-22.28,1.11-1.11L215.9,190a12,12,0,0,0,9.06-5.91,111.67,111.67,0,0,0,11.27-27.23A12,12,0,0,0,234,146.3Zm-24.12-4.89a70.1,70.1,0,0,1,0,8.2,12,12,0,0,0,2.61,8.22l12.84,16.05A86.47,86.47,0,0,1,207,166.86l-20.43,2.27a12,12,0,0,0-7.65,4,69,69,0,0,1-5.8,5.8,12,12,0,0,0-4,7.65L166.86,207a86.47,86.47,0,0,1-10.49,4.35l-16.05-12.85a12,12,0,0,0-7.5-2.62c-.24,0-.48,0-.72,0a70.1,70.1,0,0,1-8.2,0,12.06,12.06,0,0,0-8.22,2.6L99.63,211.33A86.47,86.47,0,0,1,89.14,207l-2.27-20.43a12,12,0,0,0-4-7.65,69,69,0,0,1-5.8-5.8,12,12,0,0,0-7.65-4L49,166.86a86.47,86.47,0,0,1-4.35-10.49l12.84-16.05a12,12,0,0,0,2.61-8.22,70.1,70.1,0,0,1,0-8.2,12,12,0,0,0-2.61-8.22L44.67,99.63A86.47,86.47,0,0,1,49,89.14l20.43-2.27a12,12,0,0,0,7.65-4,69,69,0,0,1,5.8-5.8,12,12,0,0,0,4-7.65L89.14,49a86.47,86.47,0,0,1,10.49-4.35l16.05,12.85a12.06,12.06,0,0,0,8.22,2.6,70.1,70.1,0,0,1,8.2,0,12,12,0,0,0,8.22-2.6l16.05-12.85A86.47,86.47,0,0,1,166.86,49l2.27,20.43a12,12,0,0,0,4,7.65,69,69,0,0,1,5.8,5.8,12,12,0,0,0,7.65,4L207,89.14a86.47,86.47,0,0,1,4.35,10.49l-12.84,16.05A12,12,0,0,0,195.88,123.9Z"/>'),_j=Za("gear","0 0 256 256",'<path d="M216,130.16q.06-2.16,0-4.32l14.92-18.64a8,8,0,0,0,1.48-7.06,107.6,107.6,0,0,0-10.88-26.25,8,8,0,0,0-6-3.93l-23.72-2.64q-1.48-1.56-3-3L186,40.54a8,8,0,0,0-3.94-6,107.29,107.29,0,0,0-26.25-10.86,8,8,0,0,0-7.06,1.48L130.16,40Q128,40,125.84,40L107.2,25.11a8,8,0,0,0-7.06-1.48A107.6,107.6,0,0,0,73.89,34.51a8,8,0,0,0-3.93,6L67.32,64.27q-1.56,1.49-3,3L40.54,70a8,8,0,0,0-6,3.94,107.71,107.71,0,0,0-10.87,26.25,8,8,0,0,0,1.49,7.06L40,125.84Q40,128,40,130.16L25.11,148.8a8,8,0,0,0-1.48,7.06,107.6,107.6,0,0,0,10.88,26.25,8,8,0,0,0,6,3.93l23.72,2.64q1.49,1.56,3,3L70,215.46a8,8,0,0,0,3.94,6,107.71,107.71,0,0,0,26.25,10.87,8,8,0,0,0,7.06-1.49L125.84,216q2.16.06,4.32,0l18.64,14.92a8,8,0,0,0,7.06,1.48,107.21,107.21,0,0,0,26.25-10.88,8,8,0,0,0,3.93-6l2.64-23.72q1.56-1.48,3-3L215.46,186a8,8,0,0,0,6-3.94,107.71,107.71,0,0,0,10.87-26.25,8,8,0,0,0-1.49-7.06ZM128,168a40,40,0,1,1,40-40A40,40,0,0,1,128,168Z"/>'),mj=Za("gear","0 0 256 256",'<path d="M207.86,123.18l16.78-21a99.14,99.14,0,0,0-10.07-24.29l-26.7-3a81,81,0,0,0-6.81-6.81l-3-26.71a99.43,99.43,0,0,0-24.3-10l-21,16.77a81.59,81.59,0,0,0-9.64,0l-21-16.78A99.14,99.14,0,0,0,77.91,41.43l-3,26.7a81,81,0,0,0-6.81,6.81l-26.71,3a99.43,99.43,0,0,0-10,24.3l16.77,21a81.59,81.59,0,0,0,0,9.64l-16.78,21a99.14,99.14,0,0,0,10.07,24.29l26.7,3a81,81,0,0,0,6.81,6.81l3,26.71a99.43,99.43,0,0,0,24.3,10l21-16.77a81.59,81.59,0,0,0,9.64,0l21,16.78a99.14,99.14,0,0,0,24.29-10.07l3-26.7a81,81,0,0,0,6.81-6.81l26.71-3a99.43,99.43,0,0,0,10-24.3l-16.77-21A81.59,81.59,0,0,0,207.86,123.18ZM128,168a40,40,0,1,1,40-40A40,40,0,0,1,128,168Z" opacity="0.2"/><path d="M128,80a48,48,0,1,0,48,48A48.05,48.05,0,0,0,128,80Zm0,80a32,32,0,1,1,32-32A32,32,0,0,1,128,160Zm88-29.84q.06-2.16,0-4.32l14.92-18.64a8,8,0,0,0,1.48-7.06,107.6,107.6,0,0,0-10.88-26.25,8,8,0,0,0-6-3.93l-23.72-2.64q-1.48-1.56-3-3L186,40.54a8,8,0,0,0-3.94-6,107.29,107.29,0,0,0-26.25-10.86,8,8,0,0,0-7.06,1.48L130.16,40Q128,40,125.84,40L107.2,25.11a8,8,0,0,0-7.06-1.48A107.6,107.6,0,0,0,73.89,34.51a8,8,0,0,0-3.93,6L67.32,64.27q-1.56,1.49-3,3L40.54,70a8,8,0,0,0-6,3.94,107.71,107.71,0,0,0-10.87,26.25,8,8,0,0,0,1.49,7.06L40,125.84Q40,128,40,130.16L25.11,148.8a8,8,0,0,0-1.48,7.06,107.6,107.6,0,0,0,10.88,26.25,8,8,0,0,0,6,3.93l23.72,2.64q1.49,1.56,3,3L70,215.46a8,8,0,0,0,3.94,6,107.71,107.71,0,0,0,26.25,10.87,8,8,0,0,0,7.06-1.49L125.84,216q2.16.06,4.32,0l18.64,14.92a8,8,0,0,0,7.06,1.48,107.21,107.21,0,0,0,26.25-10.88,8,8,0,0,0,3.93-6l2.64-23.72q1.56-1.48,3-3L215.46,186a8,8,0,0,0,6-3.94,107.71,107.71,0,0,0,10.87-26.25,8,8,0,0,0-1.49-7.06Zm-16.1-6.5a73.93,73.93,0,0,1,0,8.68,8,8,0,0,0,1.74,5.48l14.19,17.73a91.57,91.57,0,0,1-6.23,15L187,173.11a8,8,0,0,0-5.1,2.64,74.11,74.11,0,0,1-6.14,6.14,8,8,0,0,0-2.64,5.1l-2.51,22.58a91.32,91.32,0,0,1-15,6.23l-17.74-14.19a8,8,0,0,0-5-1.75h-.48a73.93,73.93,0,0,1-8.68,0,8.06,8.06,0,0,0-5.48,1.74L100.45,215.8a91.57,91.57,0,0,1-15-6.23L82.89,187a8,8,0,0,0-2.64-5.1,74.11,74.11,0,0,1-6.14-6.14,8,8,0,0,0-5.1-2.64L46.43,170.6a91.32,91.32,0,0,1-6.23-15l14.19-17.74a8,8,0,0,0,1.74-5.48,73.93,73.93,0,0,1,0-8.68,8,8,0,0,0-1.74-5.48L40.2,100.45a91.57,91.57,0,0,1,6.23-15L69,82.89a8,8,0,0,0,5.1-2.64,74.11,74.11,0,0,1,6.14-6.14A8,8,0,0,0,82.89,69L85.4,46.43a91.32,91.32,0,0,1,15-6.23l17.74,14.19a8,8,0,0,0,5.48,1.74,73.93,73.93,0,0,1,8.68,0,8.06,8.06,0,0,0,5.48-1.74L155.55,40.2a91.57,91.57,0,0,1,15,6.23L173.11,69a8,8,0,0,0,2.64,5.1,74.11,74.11,0,0,1,6.14,6.14,8,8,0,0,0,5.1,2.64l22.58,2.51a91.32,91.32,0,0,1,6.23,15l-14.19,17.74A8,8,0,0,0,199.87,123.66Z"/>'),gj="gear",vj=Object.freeze(Object.defineProperty({__proto__:null,bold:pj,default:Cp,duotone:mj,fill:_j,glyphName:gj,light:fj,regular:Cp,thin:dj},Symbol.toStringTag,{value:"Module"})),Fa=(e,t,i)=>{const r=s=>Me("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:t,fill:"currentColor",...s,innerHTML:i});return r.displayName="NbGlyph",r.glyphName=e,r},bj=Fa("house","0 0 256 256",'<path d="M216.49,111.51l-80-80a12,12,0,0,0-17,0l-80,80A12,12,0,0,0,36,120v96a4,4,0,0,0,4,4h64a4,4,0,0,0,4-4V156h40v60a4,4,0,0,0,4,4h64a4,4,0,0,0,4-4V120A12,12,0,0,0,216.49,111.51ZM212,212H156V152a4,4,0,0,0-4-4H104a4,4,0,0,0-4,4v60H44V120a4,4,0,0,1,1.17-2.83l80-80a4,4,0,0,1,5.66,0l80,80A4,4,0,0,1,212,120Z"/>'),yj=Fa("house","0 0 256 256",'<path d="M217.9,110.1l-80-80a14,14,0,0,0-19.8,0l-80,80A13.92,13.92,0,0,0,34,120v96a6,6,0,0,0,6,6h64a6,6,0,0,0,6-6V158h36v58a6,6,0,0,0,6,6h64a6,6,0,0,0,6-6V120A13.92,13.92,0,0,0,217.9,110.1ZM210,210H158V152a6,6,0,0,0-6-6H104a6,6,0,0,0-6,6v58H46V120a2,2,0,0,1,.58-1.42l80-80a2,2,0,0,1,2.84,0l80,80A2,2,0,0,1,210,120Z"/>'),kp=Fa("house","0 0 256 256",'<path d="M219.31,108.68l-80-80a16,16,0,0,0-22.62,0l-80,80A15.87,15.87,0,0,0,32,120v96a8,8,0,0,0,8,8h64a8,8,0,0,0,8-8V160h32v56a8,8,0,0,0,8,8h64a8,8,0,0,0,8-8V120A15.87,15.87,0,0,0,219.31,108.68ZM208,208H160V152a8,8,0,0,0-8-8H104a8,8,0,0,0-8,8v56H48V120l80-80,80,80Z"/>'),wj=Fa("house","0 0 256 256",'<path d="M222.14,105.85l-80-80a20,20,0,0,0-28.28,0l-80,80A19.86,19.86,0,0,0,28,120v96a12,12,0,0,0,12,12h64a12,12,0,0,0,12-12V164h24v52a12,12,0,0,0,12,12h64a12,12,0,0,0,12-12V120A19.86,19.86,0,0,0,222.14,105.85ZM204,204H164V152a12,12,0,0,0-12-12H104a12,12,0,0,0-12,12v52H52V121.65l76-76,76,76Z"/>'),Sj=Fa("house","0 0 256 256",'<path d="M224,120v96a8,8,0,0,1-8,8H160a8,8,0,0,1-8-8V164a4,4,0,0,0-4-4H108a4,4,0,0,0-4,4v52a8,8,0,0,1-8,8H40a8,8,0,0,1-8-8V120a16,16,0,0,1,4.69-11.31l80-80a16,16,0,0,1,22.62,0l80,80A16,16,0,0,1,224,120Z"/>'),Cj=Fa("house","0 0 256 256",'<path d="M216,120v96H152V152H104v64H40V120a8,8,0,0,1,2.34-5.66l80-80a8,8,0,0,1,11.32,0l80,80A8,8,0,0,1,216,120Z" opacity="0.2"/><path d="M219.31,108.68l-80-80a16,16,0,0,0-22.62,0l-80,80A15.87,15.87,0,0,0,32,120v96a8,8,0,0,0,8,8h64a8,8,0,0,0,8-8V160h32v56a8,8,0,0,0,8,8h64a8,8,0,0,0,8-8V120A15.87,15.87,0,0,0,219.31,108.68ZM208,208H160V152a8,8,0,0,0-8-8H104a8,8,0,0,0-8,8v56H48V120l80-80,80,80Z"/>'),kj="house",Aj=Object.freeze(Object.defineProperty({__proto__:null,bold:wj,default:kp,duotone:Cj,fill:Sj,glyphName:kj,light:yj,regular:kp,thin:bj},Symbol.toStringTag,{value:"Module"})),za=(e,t,i)=>{const r=s=>Me("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:t,fill:"currentColor",...s,innerHTML:i});return r.displayName="NbGlyph",r.glyphName=e,r},Mj=za("intersect","0 0 256 256",'<path d="M171.17,84.83a76,76,0,1,0-86.34,86.34,76,76,0,1,0,86.34-86.34ZM28,96A68,68,0,0,1,162.93,84.07c-1,0-2-.07-2.93-.07a76.08,76.08,0,0,0-76,76c0,1,0,2,.07,2.93A68.1,68.1,0,0,1,28,96Zm136,0a67.59,67.59,0,0,1-7.45,30.89L129.11,99.45A67.59,67.59,0,0,1,160,92c1.3,0,2.6,0,3.88.12C164,93.4,164,94.7,164,96ZM92,160a67.59,67.59,0,0,1,7.45-30.89l27.44,27.44A67.59,67.59,0,0,1,96,164c-1.3,0-2.6-.05-3.88-.12C92.05,162.6,92,161.3,92,160Zm42-7.64L103.64,122A68.74,68.74,0,0,1,122,103.64L152.36,134A68.74,68.74,0,0,1,134,152.36ZM160,228a68.1,68.1,0,0,1-66.93-56.07c1,0,2,.07,2.93.07a76.08,76.08,0,0,0,76-76c0-1,0-2-.07-2.93A68,68,0,0,1,160,228Z"/>'),Lj=za("intersect","0 0 256 256",'<path d="M172.91,83.09a78,78,0,1,0-89.82,89.82,78,78,0,1,0,89.82-89.82ZM30,96A66,66,0,0,1,160.49,82H160a78.09,78.09,0,0,0-78,78c0,.17,0,.33,0,.49A66.1,66.1,0,0,1,30,96Zm64,64a65.62,65.62,0,0,1,6-27.49L123.49,156A65.62,65.62,0,0,1,96,162c-.65,0-1.3,0-2-.05C94,161.3,94,160.65,94,160Zm40.23-10.25-28-28a66.47,66.47,0,0,1,15.52-15.52l28,28A66.47,66.47,0,0,1,134.23,149.75ZM162,96a65.62,65.62,0,0,1-6,27.49L132.51,100A65.62,65.62,0,0,1,160,94c.65,0,1.3,0,1.95,0C162,94.7,162,95.35,162,96Zm-2,130a66.1,66.1,0,0,1-64.49-52H96a78.09,78.09,0,0,0,78-78c0-.17,0-.33,0-.49A66,66,0,0,1,160,226Z"/>'),Ap=za("intersect","0 0 256 256",'<path d="M174.63,81.37a80,80,0,1,0-93.26,93.26,80,80,0,1,0,93.26-93.26ZM100.69,136,120,155.31A63.48,63.48,0,0,1,96,160,63.48,63.48,0,0,1,100.69,136Zm33.75,11.13-25.57-25.57a64.65,64.65,0,0,1,12.69-12.69l25.57,25.57A64.65,64.65,0,0,1,134.44,147.13ZM155.31,120,136,100.69A63.48,63.48,0,0,1,160,96,63.48,63.48,0,0,1,155.31,120ZM32,96a64,64,0,0,1,126-16A80.08,80.08,0,0,0,80.05,158,64.11,64.11,0,0,1,32,96ZM160,224A64.11,64.11,0,0,1,98,176,80.08,80.08,0,0,0,176,98,64,64,0,0,1,160,224Z"/>'),Ej=za("intersect","0 0 256 256",'<path d="M178,78A84,84,0,1,0,78,178,84,84,0,1,0,178,78Zm-22.19,22.19a59.57,59.57,0,0,1-9.81,28.9L126.94,110A59.57,59.57,0,0,1,155.84,100.16Zm-79.5,52.51a60,60,0,1,1,76.33-76.33A84.11,84.11,0,0,0,76.34,152.67Zm23.82,3.17a59.57,59.57,0,0,1,9.81-28.9L129.06,146A59.57,59.57,0,0,1,100.16,155.84ZM160,220a60.09,60.09,0,0,1-56.67-40.34,84.11,84.11,0,0,0,76.33-76.33A60,60,0,0,1,160,220Z"/>'),$j=za("intersect","0 0 256 256",'<path d="M174.63,81.37a80,80,0,1,0-93.26,93.26,80,80,0,1,0,93.26-93.26ZM32,96a64,64,0,0,1,126-16A80.08,80.08,0,0,0,80.05,158,64.11,64.11,0,0,1,32,96ZM160,224A64.11,64.11,0,0,1,98,176,80.08,80.08,0,0,0,176,98,64,64,0,0,1,160,224Z"/>'),xj=za("intersect","0 0 256 256",'<path d="M168,96a72,72,0,0,1-72,72,73.37,73.37,0,0,1-7.6-.4A73.37,73.37,0,0,1,88,160a72,72,0,0,1,72-72,73.37,73.37,0,0,1,7.6.4A73.37,73.37,0,0,1,168,96Z" opacity="0.2"/><path d="M174.63,81.37a80,80,0,1,0-93.26,93.26,80,80,0,1,0,93.26-93.26ZM32,96a64,64,0,0,1,126-16A80.08,80.08,0,0,0,80.05,158,64.11,64.11,0,0,1,32,96Zm128,0a64.07,64.07,0,0,1-64,64A64.07,64.07,0,0,1,160,96Zm0,128A64.11,64.11,0,0,1,98,176,80.08,80.08,0,0,0,176,98,64,64,0,0,1,160,224Z"/>'),Tj="intersect",Nj=Object.freeze(Object.defineProperty({__proto__:null,bold:Ej,default:Ap,duotone:xj,fill:$j,glyphName:Tj,light:Lj,regular:Ap,thin:Mj},Symbol.toStringTag,{value:"Module"})),Ua=(e,t,i)=>{const r=s=>Me("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:t,fill:"currentColor",...s,innerHTML:i});return r.displayName="NbGlyph",r.glyphName=e,r},Hj=Ua("lamp","0 0 256 256",'<path d="M243.68,150.42l-48-112A4,4,0,0,0,192,36H64a4,4,0,0,0-3.68,2.42l-48,112A4,4,0,0,0,16,156H124v56H96a4,4,0,0,0,0,8h64a4,4,0,0,0,0-8H132V156h64v36a4,4,0,0,0,8,0V156h36a4,4,0,0,0,3.68-5.58ZM22.07,148,66.64,44H189.36l44.57,104Z"/>'),Pj=Ua("lamp","0 0 256 256",'<path d="M245.51,149.64l-48-112A6,6,0,0,0,192,34H64a6,6,0,0,0-5.51,3.64l-48,112A6,6,0,0,0,16,158H122v52H96a6,6,0,0,0,0,12h64a6,6,0,0,0,0-12H134V158h60v34a6,6,0,0,0,12,0V158h34a6,6,0,0,0,5.51-8.36ZM25.1,146,68,46H188L230.9,146Z"/>'),Mp=Ua("lamp","0 0 256 256",'<path d="M247.35,148.85l-48-112A8,8,0,0,0,192,32H64a8,8,0,0,0-7.35,4.85l-48,112A8,8,0,0,0,16,160H120v48H96a8,8,0,0,0,0,16h64a8,8,0,0,0,0-16H136V160h56v32a8,8,0,0,0,16,0V160h32a8,8,0,0,0,7.35-11.15ZM28.13,144,69.28,48H186.72l41.15,96Z"/>'),Oj=Ua("lamp","0 0 256 256",'<path d="M251,147.27l-48-112A12,12,0,0,0,192,28H64a12,12,0,0,0-11,7.27l-48,112A12,12,0,0,0,16,164H116v40H96a12,12,0,0,0,0,24h64a12,12,0,0,0,0-24H140V164h48v28a12,12,0,0,0,24,0V164h28a12,12,0,0,0,11-16.73ZM34.2,140,71.91,52H184.09l37.71,88Z"/>'),Ij=Ua("lamp","0 0 256 256",'<path d="M246.68,156.4A8,8,0,0,1,240,160H208v32a8,8,0,0,1-16,0V160H136v48h24a8,8,0,0,1,0,16H96a8,8,0,0,1,0-16h24V160H16a8,8,0,0,1-7.35-11.15l48-112A8,8,0,0,1,64,32H192a8,8,0,0,1,7.35,4.85l48,112A8,8,0,0,1,246.68,156.4Z"/>'),Rj=Ua("lamp","0 0 256 256",'<path d="M240,152H16L64,40H192Z" opacity="0.2"/><path d="M247.35,148.85l-48-112A8,8,0,0,0,192,32H64a8,8,0,0,0-7.35,4.85l-48,112A8,8,0,0,0,16,160H120v48H96a8,8,0,0,0,0,16h64a8,8,0,0,0,0-16H136V160h56v32a8,8,0,0,0,16,0V160h32a8,8,0,0,0,7.35-11.15ZM28.13,144,69.28,48H186.72l41.15,96Z"/>'),Dj="lamp",Vj=Object.freeze(Object.defineProperty({__proto__:null,bold:Oj,default:Mp,duotone:Rj,fill:Ij,glyphName:Dj,light:Pj,regular:Mp,thin:Hj},Symbol.toStringTag,{value:"Module"})),Wa=(e,t,i)=>{const r=s=>Me("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:t,fill:"currentColor",...s,innerHTML:i});return r.displayName="NbGlyph",r.glyphName=e,r},Bj=Wa("lightbulb","0 0 256 256",'<path d="M172,232a4,4,0,0,1-4,4H88a4,4,0,0,1,0-8h80A4,4,0,0,1,172,232Zm40-128a83.59,83.59,0,0,1-32.11,66.06A20.2,20.2,0,0,0,172,186v6a12,12,0,0,1-12,12H96a12,12,0,0,1-12-12v-6a20,20,0,0,0-7.76-15.81A83.58,83.58,0,0,1,44,104.47C43.75,59,80.52,21.09,126,20a84,84,0,0,1,86,84Zm-8,0a76,76,0,0,0-77.83-76C85,29,51.77,63.27,52,104.43a75.62,75.62,0,0,0,29.17,59.43A28,28,0,0,1,92,186v6a4,4,0,0,0,4,4h64a4,4,0,0,0,4-4v-6a28.14,28.14,0,0,1,10.94-22.2A75.62,75.62,0,0,0,204,104ZM136.66,52.06a4,4,0,0,0-1.32,7.88C153.53,63,169,78.45,172.06,96.67A4,4,0,0,0,176,100a3.88,3.88,0,0,0,.67-.06,4,4,0,0,0,3.27-4.61A53.51,53.51,0,0,0,136.66,52.06Z"/>'),Zj=Wa("lightbulb","0 0 256 256",'<path d="M174,232a6,6,0,0,1-6,6H88a6,6,0,0,1,0-12h80A6,6,0,0,1,174,232Zm40-128a85.56,85.56,0,0,1-32.88,67.64A18.23,18.23,0,0,0,174,186v6a14,14,0,0,1-14,14H96a14,14,0,0,1-14-14v-6a18,18,0,0,0-7-14.23h0a85.59,85.59,0,0,1-33-67.24C41.74,57.91,79.39,19.12,125.93,18A86,86,0,0,1,214,104Zm-12,0a74,74,0,0,0-75.79-74C86.17,31,53.78,64.34,54,104.42a73.67,73.67,0,0,0,28.4,57.87A29.92,29.92,0,0,1,94,186v6a2,2,0,0,0,2,2h64a2,2,0,0,0,2-2v-6a30.18,30.18,0,0,1,11.7-23.78A73.59,73.59,0,0,0,202,104Zm-20.08-9A55.58,55.58,0,0,0,137,50.08a6,6,0,1,0-2,11.84C152.38,64.84,167.13,79.6,170.08,97a6,6,0,0,0,5.91,5,6.87,6.87,0,0,0,1-.08A6,6,0,0,0,181.92,95Z"/>'),Lp=Wa("lightbulb","0 0 256 256",'<path d="M176,232a8,8,0,0,1-8,8H88a8,8,0,0,1,0-16h80A8,8,0,0,1,176,232Zm40-128a87.55,87.55,0,0,1-33.64,69.21A16.24,16.24,0,0,0,176,186v6a16,16,0,0,1-16,16H96a16,16,0,0,1-16-16v-6a16,16,0,0,0-6.23-12.66A87.59,87.59,0,0,1,40,104.49C39.74,56.83,78.26,17.14,125.88,16A88,88,0,0,1,216,104Zm-16,0a72,72,0,0,0-73.74-72c-39,.92-70.47,33.39-70.26,72.39a71.65,71.65,0,0,0,27.64,56.3A32,32,0,0,1,96,186v6h64v-6a32.15,32.15,0,0,1,12.47-25.35A71.65,71.65,0,0,0,200,104Zm-16.11-9.34a57.6,57.6,0,0,0-46.56-46.55,8,8,0,0,0-2.66,15.78c16.57,2.79,30.63,16.85,33.44,33.45A8,8,0,0,0,176,104a9,9,0,0,0,1.35-.11A8,8,0,0,0,183.89,94.66Z"/>'),Fj=Wa("lightbulb","0 0 256 256",'<path d="M180,232a12,12,0,0,1-12,12H88a12,12,0,0,1,0-24h80A12,12,0,0,1,180,232Zm40-128a91.51,91.51,0,0,1-35.17,72.35A12.26,12.26,0,0,0,180,186v2a20,20,0,0,1-20,20H96a20,20,0,0,1-20-20v-2a12,12,0,0,0-4.7-9.51A91.57,91.57,0,0,1,36,104.52C35.73,54.69,76,13.2,125.79,12A92,92,0,0,1,220,104Zm-24,0a68,68,0,0,0-69.65-68C89.56,36.88,59.8,67.55,60,104.38a67.71,67.71,0,0,0,26.1,53.19A35.87,35.87,0,0,1,100,184h56.1A36.13,36.13,0,0,1,170,157.49,67.68,67.68,0,0,0,196,104Zm-20.07-5.32a48.5,48.5,0,0,0-31.91-40,12,12,0,0,0-8,22.62,24.31,24.31,0,0,1,16.09,20,12,12,0,0,0,23.86-2.64Z"/>'),zj=Wa("lightbulb","0 0 256 256",'<path d="M176,232a8,8,0,0,1-8,8H88a8,8,0,0,1,0-16h80A8,8,0,0,1,176,232Zm40-128a87.55,87.55,0,0,1-33.64,69.21A16.24,16.24,0,0,0,176,186v6a16,16,0,0,1-16,16H96a16,16,0,0,1-16-16v-6a16,16,0,0,0-6.23-12.66A87.59,87.59,0,0,1,40,104.49C39.74,56.83,78.26,17.14,125.88,16A88,88,0,0,1,216,104Zm-32.11-9.34a57.6,57.6,0,0,0-46.56-46.55,8,8,0,0,0-2.66,15.78c16.57,2.79,30.63,16.85,33.44,33.45A8,8,0,0,0,176,104a9,9,0,0,0,1.35-.11A8,8,0,0,0,183.89,94.66Z"/>'),Uj=Wa("lightbulb","0 0 256 256",'<path d="M208,104a79.86,79.86,0,0,1-30.59,62.92A24.29,24.29,0,0,0,168,186v6a8,8,0,0,1-8,8H96a8,8,0,0,1-8-8v-6a24.11,24.11,0,0,0-9.3-19A79.87,79.87,0,0,1,48,104.45C47.76,61.09,82.72,25,126.07,24A80,80,0,0,1,208,104Z" opacity="0.2"/><path d="M176,232a8,8,0,0,1-8,8H88a8,8,0,0,1,0-16h80A8,8,0,0,1,176,232Zm40-128a87.55,87.55,0,0,1-33.64,69.21A16.24,16.24,0,0,0,176,186v6a16,16,0,0,1-16,16H96a16,16,0,0,1-16-16v-6a16,16,0,0,0-6.23-12.66A87.59,87.59,0,0,1,40,104.49C39.74,56.83,78.26,17.14,125.88,16A88,88,0,0,1,216,104Zm-16,0a72,72,0,0,0-73.74-72c-39,.92-70.47,33.39-70.26,72.39a71.65,71.65,0,0,0,27.64,56.3A32,32,0,0,1,96,186v6h64v-6a32.15,32.15,0,0,1,12.47-25.35A71.65,71.65,0,0,0,200,104Zm-16.11-9.34a57.6,57.6,0,0,0-46.56-46.55,8,8,0,0,0-2.66,15.78c16.57,2.79,30.63,16.85,33.44,33.45A8,8,0,0,0,176,104a9,9,0,0,0,1.35-.11A8,8,0,0,0,183.89,94.66Z"/>'),Wj="lightbulb",jj=Object.freeze(Object.defineProperty({__proto__:null,bold:Fj,default:Lp,duotone:Uj,fill:zj,glyphName:Wj,light:Zj,regular:Lp,thin:Bj},Symbol.toStringTag,{value:"Module"})),ja=(e,t,i)=>{const r=s=>Me("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:t,fill:"currentColor",...s,innerHTML:i});return r.displayName="NbGlyph",r.glyphName=e,r},Kj=ja("lightning","0 0 256 256",'<path d="M211.89,119.09a4,4,0,0,0-2.49-2.84l-60.81-22.8,15.33-76.67a4,4,0,0,0-6.84-3.51l-112,120a4,4,0,0,0-1,3.64,4,4,0,0,0,2.49,2.84l60.81,22.8L92.08,239.22a4,4,0,0,0,6.84,3.51l112-120A4,4,0,0,0,211.89,119.09ZM102.68,227l13.24-66.2a4,4,0,0,0-2.52-4.53L55,134.36,153.32,29l-13.24,66.2a4,4,0,0,0,2.52,4.53L201,121.64Z"/>'),qj=ja("lightning","0 0 256 256",'<path d="M213.84,118.63a6,6,0,0,0-3.73-4.25L150.88,92.17l15-75a6,6,0,0,0-10.27-5.27l-112,120a6,6,0,0,0,2.28,9.71l59.23,22.21-15,75a6,6,0,0,0,3.14,6.52A6.07,6.07,0,0,0,96,246a6,6,0,0,0,4.39-1.91l112-120A6,6,0,0,0,213.84,118.63ZM106,220.46l11.85-59.28a6,6,0,0,0-3.77-6.8l-55.6-20.85,91.46-98L138.12,94.82a6,6,0,0,0,3.77,6.8l55.6,20.85Z"/>'),Ep=ja("lightning","0 0 256 256",'<path d="M215.79,118.17a8,8,0,0,0-5-5.66L153.18,90.9l14.66-73.33a8,8,0,0,0-13.69-7l-112,120a8,8,0,0,0,3,13l57.63,21.61L88.16,238.43a8,8,0,0,0,13.69,7l112-120A8,8,0,0,0,215.79,118.17ZM109.37,214l10.47-52.38a8,8,0,0,0-5-9.06L62,132.71l84.62-90.66L136.16,94.43a8,8,0,0,0,5,9.06l52.8,19.8Z"/>'),Gj=ja("lightning","0 0 256 256",'<path d="M219.71,117.38a12,12,0,0,0-7.25-8.52L161.28,88.39l10.59-70.61a12,12,0,0,0-20.64-10l-112,120a12,12,0,0,0,4.31,19.33l51.18,20.47L84.13,238.22a12,12,0,0,0,20.64,10l112-120A12,12,0,0,0,219.71,117.38ZM113.6,203.55l6.27-41.77a12,12,0,0,0-7.41-12.92L68.74,131.37,142.4,52.45l-6.27,41.77a12,12,0,0,0,7.41,12.92l43.72,17.49Z"/>'),Yj=ja("lightning","0 0 256 256",'<path d="M213.85,125.46l-112,120a8,8,0,0,1-13.69-7l14.66-73.33L45.19,143.49a8,8,0,0,1-3-13l112-120a8,8,0,0,1,13.69,7L153.18,90.9l57.63,21.61a8,8,0,0,1,3,12.95Z"/>'),Xj=ja("lightning","0 0 256 256",'<path d="M96,240l16-80L48,136,160,16,144,96l64,24Z" opacity="0.2"/><path d="M215.79,118.17a8,8,0,0,0-5-5.66L153.18,90.9l14.66-73.33a8,8,0,0,0-13.69-7l-112,120a8,8,0,0,0,3,13l57.63,21.61L88.16,238.43a8,8,0,0,0,13.69,7l112-120A8,8,0,0,0,215.79,118.17ZM109.37,214l10.47-52.38a8,8,0,0,0-5-9.06L62,132.71l84.62-90.66L136.16,94.43a8,8,0,0,0,5,9.06l52.8,19.8Z"/>'),Jj="lightning",Qj=Object.freeze(Object.defineProperty({__proto__:null,bold:Gj,default:Ep,duotone:Xj,fill:Yj,glyphName:Jj,light:qj,regular:Ep,thin:Kj},Symbol.toStringTag,{value:"Module"})),Ka=(e,t,i)=>{const r=s=>Me("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:t,fill:"currentColor",...s,innerHTML:i});return r.displayName="NbGlyph",r.glyphName=e,r},eK=Ka("lock","0 0 256 256",'<path d="M208,84H172V56a44,44,0,0,0-88,0V84H48A12,12,0,0,0,36,96V208a12,12,0,0,0,12,12H208a12,12,0,0,0,12-12V96A12,12,0,0,0,208,84ZM92,56a36,36,0,0,1,72,0V84H92ZM212,208a4,4,0,0,1-4,4H48a4,4,0,0,1-4-4V96a4,4,0,0,1,4-4H208a4,4,0,0,1,4,4Zm-76-56a8,8,0,1,1-8-8A8,8,0,0,1,136,152Z"/>'),tK=Ka("lock","0 0 256 256",'<path d="M208,82H174V56a46,46,0,0,0-92,0V82H48A14,14,0,0,0,34,96V208a14,14,0,0,0,14,14H208a14,14,0,0,0,14-14V96A14,14,0,0,0,208,82ZM94,56a34,34,0,0,1,68,0V82H94ZM210,208a2,2,0,0,1-2,2H48a2,2,0,0,1-2-2V96a2,2,0,0,1,2-2H208a2,2,0,0,1,2,2Zm-72-56a10,10,0,1,1-10-10A10,10,0,0,1,138,152Z"/>'),$p=Ka("lock","0 0 256 256",'<path d="M208,80H176V56a48,48,0,0,0-96,0V80H48A16,16,0,0,0,32,96V208a16,16,0,0,0,16,16H208a16,16,0,0,0,16-16V96A16,16,0,0,0,208,80ZM96,56a32,32,0,0,1,64,0V80H96ZM208,208H48V96H208V208Zm-68-56a12,12,0,1,1-12-12A12,12,0,0,1,140,152Z"/>'),iK=Ka("lock","0 0 256 256",'<path d="M208,76H180V56A52,52,0,0,0,76,56V76H48A20,20,0,0,0,28,96V208a20,20,0,0,0,20,20H208a20,20,0,0,0,20-20V96A20,20,0,0,0,208,76ZM100,56a28,28,0,0,1,56,0V76H100ZM204,204H52V100H204Zm-60-52a16,16,0,1,1-16-16A16,16,0,0,1,144,152Z"/>'),rK=Ka("lock","0 0 256 256",'<path d="M208,80H176V56a48,48,0,0,0-96,0V80H48A16,16,0,0,0,32,96V208a16,16,0,0,0,16,16H208a16,16,0,0,0,16-16V96A16,16,0,0,0,208,80Zm-80,84a12,12,0,1,1,12-12A12,12,0,0,1,128,164Zm32-84H96V56a32,32,0,0,1,64,0Z"/>'),sK=Ka("lock","0 0 256 256",'<path d="M216,96V208a8,8,0,0,1-8,8H48a8,8,0,0,1-8-8V96a8,8,0,0,1,8-8H208A8,8,0,0,1,216,96Z" opacity="0.2"/><path d="M208,80H176V56a48,48,0,0,0-96,0V80H48A16,16,0,0,0,32,96V208a16,16,0,0,0,16,16H208a16,16,0,0,0,16-16V96A16,16,0,0,0,208,80ZM96,56a32,32,0,0,1,64,0V80H96ZM208,208H48V96H208V208Zm-68-56a12,12,0,1,1-12-12A12,12,0,0,1,140,152Z"/>'),nK="lock",aK=Object.freeze(Object.defineProperty({__proto__:null,bold:iK,default:$p,duotone:sK,fill:rK,glyphName:nK,light:tK,regular:$p,thin:eK},Symbol.toStringTag,{value:"Module"})),qa=(e,t,i)=>{const r=s=>Me("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:t,fill:"currentColor",...s,innerHTML:i});return r.displayName="NbGlyph",r.glyphName=e,r},oK=qa("plugs","0 0 256 256",'<path d="M146.83,141.17a4,4,0,0,0-5.66,0L120,162.34,93.66,136l21.17-21.17a4,4,0,0,0-5.66-5.66L88,130.34,66.83,109.17a4,4,0,0,0-5.66,5.66L70.34,124,44.2,150.14a28,28,0,0,0,0,39.6l8.2,8.2L21.17,229.17a4,4,0,0,0,5.66,5.66L58.06,203.6l8.2,8.2a28,28,0,0,0,39.6,0L132,185.66l9.17,9.17a4,4,0,0,0,5.66-5.66L125.66,168l21.17-21.17A4,4,0,0,0,146.83,141.17Zm-46.63,65a20,20,0,0,1-28.28,0L49.86,184.08a20,20,0,0,1,0-28.28L76,129.66,126.34,180Zm134.63-185a4,4,0,0,0-5.66,0L197.94,52.4l-8.2-8.2a28,28,0,0,0-39.6,0L124,70.34l-9.17-9.17a4,4,0,0,0-5.66,5.66l80,80a4,4,0,0,0,5.66-5.66L185.66,132l26.14-26.14a28,28,0,0,0,0-39.6l-8.2-8.2,31.23-31.23A4,4,0,0,0,234.83,21.17ZM212,86.06a19.86,19.86,0,0,1-5.86,14.14L180,126.34,129.66,76,155.8,49.86a20,20,0,0,1,28.28,0l22.06,22.06A19.85,19.85,0,0,1,212,86.06Z"/>'),lK=qa("plugs","0 0 256 256",'<path d="M148.24,139.76a6,6,0,0,0-8.48,0L120,159.51,96.49,136l19.75-19.76a6,6,0,0,0-8.48-8.48L88,127.51,68.24,107.76a6,6,0,0,0-8.48,8.48L67.51,124,42.79,148.73a30,30,0,0,0,0,42.42l6.78,6.79L19.76,227.76a6,6,0,1,0,8.48,8.48l29.82-29.81,6.79,6.78a30,30,0,0,0,42.42,0L132,188.49l7.76,7.75a6,6,0,0,0,8.48-8.48L128.49,168l19.75-19.76A6,6,0,0,0,148.24,139.76Zm-49.45,65a18,18,0,0,1-25.46,0L51.27,182.67a18,18,0,0,1,0-25.46L76,132.49,123.51,180Zm137.45-185a6,6,0,0,0-8.48,0L197.94,49.57l-6.79-6.78a30,30,0,0,0-42.42,0L124,67.51l-7.76-7.75a6,6,0,0,0-8.48,8.48l80,80a6,6,0,0,0,8.48-8.48L188.49,132l24.72-24.73a30,30,0,0,0,0-42.42l-6.78-6.79,29.81-29.82A6,6,0,0,0,236.24,19.76Zm-31.51,79L180,123.51,132.49,76l24.72-24.73a18,18,0,0,1,25.46,0l22.06,22.06a18,18,0,0,1,0,25.46Z"/>'),xp=qa("plugs","0 0 256 256",'<path d="M149.66,138.34a8,8,0,0,0-11.32,0L120,156.69,99.31,136l18.35-18.34a8,8,0,0,0-11.32-11.32L88,124.69,69.66,106.34a8,8,0,0,0-11.32,11.32L64.69,124,41.37,147.31a32,32,0,0,0,0,45.26l5.38,5.37-28.41,28.4a8,8,0,0,0,11.32,11.32l28.4-28.41,5.37,5.38a32,32,0,0,0,45.26,0L132,191.31l6.34,6.35a8,8,0,0,0,11.32-11.32L131.31,168l18.35-18.34A8,8,0,0,0,149.66,138.34Zm-52.29,65a16,16,0,0,1-22.62,0L52.69,181.25a16,16,0,0,1,0-22.62L76,135.31,120.69,180Zm140.29-185a8,8,0,0,0-11.32,0l-28.4,28.41-5.37-5.38a32.05,32.05,0,0,0-45.26,0L124,64.69l-6.34-6.35a8,8,0,0,0-11.32,11.32l80,80a8,8,0,0,0,11.32-11.32L191.31,132l23.32-23.31a32,32,0,0,0,0-45.26l-5.38-5.37,28.41-28.4A8,8,0,0,0,237.66,18.34Zm-34.35,79L180,120.69,135.31,76l23.32-23.31a16,16,0,0,1,22.62,0l22.06,22A16,16,0,0,1,203.31,97.37Z"/>'),cK=qa("plugs","0 0 256 256",'<path d="M137,168l11.52-11.51a12,12,0,0,0-17-17L120,151l-15-15,11.52-11.51a12,12,0,0,0-17-17L88,119,72.49,103.51a12,12,0,0,0-17,17L59,124,38.54,144.49a36,36,0,0,0,0,50.91l2.55,2.54L15.51,223.51a12,12,0,0,0,17,17l25.57-25.58,2.54,2.55a36.06,36.06,0,0,0,50.91,0L132,197l3.51,3.52a12,12,0,0,0,17-17ZM94.54,200.49a12,12,0,0,1-17,0L55.51,178.43a12,12,0,0,1,0-17L76,141l39,39Zm146-185a12,12,0,0,0-17,0L197.94,41.09l-2.54-2.55a36.05,36.05,0,0,0-50.91,0L124,59l-3.51-3.52a12,12,0,0,0-17,17l80,80a12,12,0,0,0,17-17L197,132l20.49-20.49a36,36,0,0,0,0-50.91l-2.55-2.54,25.58-25.57A12,12,0,0,0,240.49,15.51Zm-40,79L180,115,141,76l20.49-20.49a12,12,0,0,1,17,0l22.06,22.06a12,12,0,0,1,0,17Z"/>'),uK=qa("plugs","0 0 256 256",'<path d="M149.66,149.66,131.31,168l18.35,18.34a8,8,0,0,1-11.32,11.32L132,191.31l-23.31,23.32a32.06,32.06,0,0,1-45.26,0l-5.37-5.38-28.4,28.41a8,8,0,0,1-11.32-11.32l28.41-28.4-5.38-5.37a32,32,0,0,1,0-45.26L64.69,124l-6.35-6.34a8,8,0,0,1,11.32-11.32L88,124.69l18.34-18.35a8,8,0,0,1,11.32,11.32L99.31,136,120,156.69l18.34-18.35a8,8,0,0,1,11.32,11.32Zm88-131.32a8,8,0,0,0-11.32,0l-28.4,28.41-5.37-5.38a32.05,32.05,0,0,0-45.26,0L124,64.69l-6.34-6.35a8,8,0,0,0-11.32,11.32l80,80a8,8,0,0,0,11.32-11.32L191.31,132l23.32-23.31a32,32,0,0,0,0-45.26l-5.38-5.37,28.41-28.4A8,8,0,0,0,237.66,18.34Z"/>'),hK=qa("plugs","0 0 256 256",'<path d="M76,124l56,56-29,29a24,24,0,0,1-33.94,0L47,186.91A24,24,0,0,1,47,153ZM209,69.09,186.91,47A24,24,0,0,0,153,47L124,76l56,56,29-29A24,24,0,0,0,209,69.09Z" opacity="0.2"/><path d="M149.66,138.34a8,8,0,0,0-11.32,0L120,156.69,99.31,136l18.35-18.34a8,8,0,0,0-11.32-11.32L88,124.69,69.66,106.34a8,8,0,0,0-11.32,11.32L64.69,124,41.37,147.31a32,32,0,0,0,0,45.26l5.38,5.37-28.41,28.4a8,8,0,0,0,11.32,11.32l28.4-28.41,5.37,5.38a32,32,0,0,0,45.26,0L132,191.31l6.34,6.35a8,8,0,0,0,11.32-11.32L131.31,168l18.35-18.34A8,8,0,0,0,149.66,138.34Zm-52.29,65a16,16,0,0,1-22.62,0L52.69,181.25a16,16,0,0,1,0-22.62L76,135.31,120.69,180Zm140.29-185a8,8,0,0,0-11.32,0l-28.4,28.41-5.37-5.38a32.05,32.05,0,0,0-45.26,0L124,64.69l-6.34-6.35a8,8,0,0,0-11.32,11.32l80,80a8,8,0,0,0,11.32-11.32L191.31,132l23.32-23.31a32,32,0,0,0,0-45.26l-5.38-5.37,28.41-28.4A8,8,0,0,0,237.66,18.34Zm-34.35,79L180,120.69,135.31,76l23.32-23.31a16,16,0,0,1,22.62,0l22.06,22A16,16,0,0,1,203.31,97.37Z"/>'),dK="plugs",fK=Object.freeze(Object.defineProperty({__proto__:null,bold:cK,default:xp,duotone:hK,fill:uK,glyphName:dK,light:lK,regular:xp,thin:oK},Symbol.toStringTag,{value:"Module"})),Ga=(e,t,i)=>{const r=s=>Me("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:t,fill:"currentColor",...s,innerHTML:i});return r.displayName="NbGlyph",r.glyphName=e,r},pK=Ga("rows","0 0 256 256",'<path d="M208,140H48a12,12,0,0,0-12,12v40a12,12,0,0,0,12,12H208a12,12,0,0,0,12-12V152A12,12,0,0,0,208,140Zm4,52a4,4,0,0,1-4,4H48a4,4,0,0,1-4-4V152a4,4,0,0,1,4-4H208a4,4,0,0,1,4,4ZM208,52H48A12,12,0,0,0,36,64v40a12,12,0,0,0,12,12H208a12,12,0,0,0,12-12V64A12,12,0,0,0,208,52Zm4,52a4,4,0,0,1-4,4H48a4,4,0,0,1-4-4V64a4,4,0,0,1,4-4H208a4,4,0,0,1,4,4Z"/>'),_K=Ga("rows","0 0 256 256",'<path d="M208,138H48a14,14,0,0,0-14,14v40a14,14,0,0,0,14,14H208a14,14,0,0,0,14-14V152A14,14,0,0,0,208,138Zm2,54a2,2,0,0,1-2,2H48a2,2,0,0,1-2-2V152a2,2,0,0,1,2-2H208a2,2,0,0,1,2,2ZM208,50H48A14,14,0,0,0,34,64v40a14,14,0,0,0,14,14H208a14,14,0,0,0,14-14V64A14,14,0,0,0,208,50Zm2,54a2,2,0,0,1-2,2H48a2,2,0,0,1-2-2V64a2,2,0,0,1,2-2H208a2,2,0,0,1,2,2Z"/>'),Tp=Ga("rows","0 0 256 256",'<path d="M208,136H48a16,16,0,0,0-16,16v40a16,16,0,0,0,16,16H208a16,16,0,0,0,16-16V152A16,16,0,0,0,208,136Zm0,56H48V152H208v40Zm0-144H48A16,16,0,0,0,32,64v40a16,16,0,0,0,16,16H208a16,16,0,0,0,16-16V64A16,16,0,0,0,208,48Zm0,56H48V64H208v40Z"/>'),mK=Ga("rows","0 0 256 256",'<path d="M208,136H48a20,20,0,0,0-20,20v36a20,20,0,0,0,20,20H208a20,20,0,0,0,20-20V156A20,20,0,0,0,208,136Zm-4,52H52V160H204Zm4-144H48A20,20,0,0,0,28,64v36a20,20,0,0,0,20,20H208a20,20,0,0,0,20-20V64A20,20,0,0,0,208,44Zm-4,52H52V68H204Z"/>'),gK=Ga("rows","0 0 256 256",'<path d="M224,152v40a16,16,0,0,1-16,16H48a16,16,0,0,1-16-16V152a16,16,0,0,1,16-16H208A16,16,0,0,1,224,152ZM208,48H48A16,16,0,0,0,32,64v40a16,16,0,0,0,16,16H208a16,16,0,0,0,16-16V64A16,16,0,0,0,208,48Z"/>'),vK=Ga("rows","0 0 256 256",'<path d="M216,152v40a8,8,0,0,1-8,8H48a8,8,0,0,1-8-8V152a8,8,0,0,1,8-8H208A8,8,0,0,1,216,152Zm-8-96H48a8,8,0,0,0-8,8v40a8,8,0,0,0,8,8H208a8,8,0,0,0,8-8V64A8,8,0,0,0,208,56Z" opacity="0.2"/><path d="M208,136H48a16,16,0,0,0-16,16v40a16,16,0,0,0,16,16H208a16,16,0,0,0,16-16V152A16,16,0,0,0,208,136Zm0,56H48V152H208v40Zm0-144H48A16,16,0,0,0,32,64v40a16,16,0,0,0,16,16H208a16,16,0,0,0,16-16V64A16,16,0,0,0,208,48Zm0,56H48V64H208v40Z"/>'),bK="rows",yK=Object.freeze(Object.defineProperty({__proto__:null,bold:mK,default:Tp,duotone:vK,fill:gK,glyphName:bK,light:_K,regular:Tp,thin:pK},Symbol.toStringTag,{value:"Module"})),Ya=(e,t,i)=>{const r=s=>Me("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:t,fill:"currentColor",...s,innerHTML:i});return r.displayName="NbGlyph",r.glyphName=e,r},wK=Ya("shield","0 0 256 256",'<path d="M208,44H48A12,12,0,0,0,36,56v56c0,51.16,24.73,82.12,45.47,99.1,22.4,18.32,44.55,24.5,45.48,24.76a4,4,0,0,0,2.1,0c.93-.26,23.08-6.44,45.48-24.76,20.74-17,45.47-47.94,45.47-99.1V56A12,12,0,0,0,208,44Zm4,68c0,38.44-14.23,69.63-42.29,92.71A132.45,132.45,0,0,1,128,227.82a132.23,132.23,0,0,1-41.71-23.11C58.23,181.63,44,150.44,44,112V56a4,4,0,0,1,4-4H208a4,4,0,0,1,4,4Z"/>'),SK=Ya("shield","0 0 256 256",'<path d="M208,42H48A14,14,0,0,0,34,56v56c0,51.94,25.12,83.4,46.2,100.64,22.73,18.6,45.27,24.89,46.22,25.15a6,6,0,0,0,3.16,0c.95-.26,23.49-6.55,46.22-25.15C196.88,195.4,222,163.94,222,112V56A14,14,0,0,0,208,42Zm2,70c0,37.76-13.94,68.39-41.44,91.06A131.17,131.17,0,0,1,128,225.72a130.94,130.94,0,0,1-40.56-22.66C59.94,180.39,46,149.76,46,112V56a2,2,0,0,1,2-2H208a2,2,0,0,1,2,2Z"/>'),Np=Ya("shield","0 0 256 256",'<path d="M208,40H48A16,16,0,0,0,32,56v56c0,52.72,25.52,84.67,46.93,102.19,23.06,18.86,46,25.27,47,25.53a8,8,0,0,0,4.2,0c1-.26,23.91-6.67,47-25.53C198.48,196.67,224,164.72,224,112V56A16,16,0,0,0,208,40Zm0,72c0,37.07-13.66,67.16-40.6,89.42A129.3,129.3,0,0,1,128,223.62a128.25,128.25,0,0,1-38.92-21.81C61.82,179.51,48,149.3,48,112l0-56,160,0Z"/>'),CK=Ya("shield","0 0 256 256",'<path d="M208,36H48A20,20,0,0,0,28,56v56c0,54.29,26.32,87.22,48.4,105.29,23.71,19.39,47.44,26,48.44,26.29a12.1,12.1,0,0,0,6.32,0c1-.28,24.73-6.9,48.44-26.29,22.08-18.07,48.4-51,48.4-105.29V56A20,20,0,0,0,208,36Zm-4,76c0,35.71-13.09,64.69-38.91,86.15A126.28,126.28,0,0,1,128,219.38a126.14,126.14,0,0,1-37.09-21.23C65.09,176.69,52,147.71,52,112V60H204Z"/>'),kK=Ya("shield","0 0 256 256",'<path d="M224,56v56c0,52.72-25.52,84.67-46.93,102.19-23.06,18.86-46,25.27-47,25.53a8,8,0,0,1-4.2,0c-1-.26-23.91-6.67-47-25.53C57.52,196.67,32,164.72,32,112V56A16,16,0,0,1,48,40H208A16,16,0,0,1,224,56Z"/>'),AK=Ya("shield","0 0 256 256",'<path d="M216,56v56c0,96-88,120-88,120S40,208,40,112V56a8,8,0,0,1,8-8H208A8,8,0,0,1,216,56Z" opacity="0.2"/><path d="M208,40H48A16,16,0,0,0,32,56v56c0,52.72,25.52,84.67,46.93,102.19,23.06,18.86,46,25.27,47,25.53a8,8,0,0,0,4.2,0c1-.26,23.91-6.67,47-25.53C198.48,196.67,224,164.72,224,112V56A16,16,0,0,0,208,40Zm0,72c0,37.07-13.66,67.16-40.6,89.42A129.3,129.3,0,0,1,128,223.62a128.25,128.25,0,0,1-38.92-21.81C61.82,179.51,48,149.3,48,112l0-56,160,0Z"/>'),MK="shield",LK=Object.freeze(Object.defineProperty({__proto__:null,bold:CK,default:Np,duotone:AK,fill:kK,glyphName:MK,light:SK,regular:Np,thin:wK},Symbol.toStringTag,{value:"Module"})),Xa=(e,t,i)=>{const r=s=>Me("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:t,fill:"currentColor",...s,innerHTML:i});return r.displayName="NbGlyph",r.glyphName=e,r},EK=Xa("sliders","0 0 256 256",'<path d="M60,108.29V40a4,4,0,0,0-8,0v68.29a28,28,0,0,0,0,55.42V216a4,4,0,0,0,8,0V163.71a28,28,0,0,0,0-55.42ZM56,156a20,20,0,1,1,20-20A20,20,0,0,1,56,156Zm76-95.71V40a4,4,0,0,0-8,0V60.29a28,28,0,0,0,0,55.42V216a4,4,0,0,0,8,0V115.71a28,28,0,0,0,0-55.42ZM128,108a20,20,0,1,1,20-20A20,20,0,0,1,128,108Zm100,60a28,28,0,0,0-24-27.71V40a4,4,0,0,0-8,0V140.29a28,28,0,0,0,0,55.42V216a4,4,0,0,0,8,0V195.71A28,28,0,0,0,228,168Zm-28,20a20,20,0,1,1,20-20A20,20,0,0,1,200,188Z"/>'),$K=Xa("sliders","0 0 256 256",'<path d="M62,106.6V40a6,6,0,0,0-12,0v66.6a30,30,0,0,0,0,58.8V216a6,6,0,0,0,12,0V165.4a30,30,0,0,0,0-58.8ZM56,154a18,18,0,1,1,18-18A18,18,0,0,1,56,154Zm78-95.4V40a6,6,0,0,0-12,0V58.6a30,30,0,0,0,0,58.8V216a6,6,0,0,0,12,0V117.4a30,30,0,0,0,0-58.8ZM128,106a18,18,0,1,1,18-18A18,18,0,0,1,128,106Zm102,62a30.05,30.05,0,0,0-24-29.4V40a6,6,0,0,0-12,0v98.6a30,30,0,0,0,0,58.8V216a6,6,0,0,0,12,0V197.4A30.05,30.05,0,0,0,230,168Zm-30,18a18,18,0,1,1,18-18A18,18,0,0,1,200,186Z"/>'),Hp=Xa("sliders","0 0 256 256",'<path d="M64,105V40a8,8,0,0,0-16,0v65a32,32,0,0,0,0,62v49a8,8,0,0,0,16,0V167a32,32,0,0,0,0-62Zm-8,47a16,16,0,1,1,16-16A16,16,0,0,1,56,152Zm80-95V40a8,8,0,0,0-16,0V57a32,32,0,0,0,0,62v97a8,8,0,0,0,16,0V119a32,32,0,0,0,0-62Zm-8,47a16,16,0,1,1,16-16A16,16,0,0,1,128,104Zm104,64a32.06,32.06,0,0,0-24-31V40a8,8,0,0,0-16,0v97a32,32,0,0,0,0,62v17a8,8,0,0,0,16,0V199A32.06,32.06,0,0,0,232,168Zm-32,16a16,16,0,1,1,16-16A16,16,0,0,1,200,184Z"/>'),xK=Xa("sliders","0 0 256 256",'<path d="M68,102.06V40a12,12,0,0,0-24,0v62.06a36,36,0,0,0,0,67.88V216a12,12,0,0,0,24,0V169.94a36,36,0,0,0,0-67.88ZM56,148a12,12,0,1,1,12-12A12,12,0,0,1,56,148ZM164,88a36.07,36.07,0,0,0-24-33.94V40a12,12,0,0,0-24,0V54.06a36,36,0,0,0,0,67.88V216a12,12,0,0,0,24,0V121.94A36.07,36.07,0,0,0,164,88Zm-36,12a12,12,0,1,1,12-12A12,12,0,0,1,128,100Zm108,68a36.07,36.07,0,0,0-24-33.94V40a12,12,0,0,0-24,0v94.06a36,36,0,0,0,0,67.88V216a12,12,0,0,0,24,0V201.94A36.07,36.07,0,0,0,236,168Zm-36,12a12,12,0,1,1,12-12A12,12,0,0,1,200,180Z"/>'),TK=Xa("sliders","0 0 256 256",'<path d="M84,136a28,28,0,0,1-20,26.83V216a8,8,0,0,1-16,0V162.83a28,28,0,0,1,0-53.66V40a8,8,0,0,1,16,0v69.17A28,28,0,0,1,84,136Zm52-74.83V40a8,8,0,0,0-16,0V61.17a28,28,0,0,0,0,53.66V216a8,8,0,0,0,16,0V114.83a28,28,0,0,0,0-53.66Zm72,80V40a8,8,0,0,0-16,0V141.17a28,28,0,0,0,0,53.66V216a8,8,0,0,0,16,0V194.83a28,28,0,0,0,0-53.66Z"/>'),NK=Xa("sliders","0 0 256 256",'<path d="M80,136a24,24,0,1,1-24-24A24,24,0,0,1,80,136Zm48-72a24,24,0,1,0,24,24A24,24,0,0,0,128,64Zm72,80a24,24,0,1,0,24,24A24,24,0,0,0,200,144Z" opacity="0.2"/><path d="M64,105V40a8,8,0,0,0-16,0v65a32,32,0,0,0,0,62v49a8,8,0,0,0,16,0V167a32,32,0,0,0,0-62Zm-8,47a16,16,0,1,1,16-16A16,16,0,0,1,56,152Zm80-95V40a8,8,0,0,0-16,0V57a32,32,0,0,0,0,62v97a8,8,0,0,0,16,0V119a32,32,0,0,0,0-62Zm-8,47a16,16,0,1,1,16-16A16,16,0,0,1,128,104Zm104,64a32.06,32.06,0,0,0-24-31V40a8,8,0,0,0-16,0v97a32,32,0,0,0,0,62v17a8,8,0,0,0,16,0V199A32.06,32.06,0,0,0,232,168Zm-32,16a16,16,0,1,1,16-16A16,16,0,0,1,200,184Z"/>'),HK="sliders",PK=Object.freeze(Object.defineProperty({__proto__:null,bold:xK,default:Hp,duotone:NK,fill:TK,glyphName:HK,light:$K,regular:Hp,thin:EK},Symbol.toStringTag,{value:"Module"})),Ja=(e,t,i)=>{const r=s=>Me("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:t,fill:"currentColor",...s,innerHTML:i});return r.displayName="NbGlyph",r.glyphName=e,r},OK=Ja("snowflake","0 0 256 256",'<path d="M219.88,151.05a4,4,0,0,1-2.93,4.83l-28.6,7L195.86,191a4,4,0,0,1-2.83,4.9,3.65,3.65,0,0,1-1,.14,4,4,0,0,1-3.86-3L180,162.64l-48-27.71v55.41l22.83,22.83a4,4,0,0,1-5.66,5.66L128,197.66l-21.17,21.17a4,4,0,0,1-5.66-5.66L124,190.34V134.93L76,162.64,67.86,193A4,4,0,0,1,64,196a3.65,3.65,0,0,1-1-.14,4,4,0,0,1-2.83-4.9l7.51-28.05-28.6-7A4,4,0,1,1,41,148.12l31,7.61L120,128,72,100.27l-31,7.61a4.07,4.07,0,0,1-1,.12,4,4,0,0,1-1-7.88l28.6-7L60.14,65A4,4,0,0,1,67.86,63L76,93.36l48,27.71V65.66L101.17,42.83a4,4,0,0,1,5.66-5.66L128,58.34l21.17-21.17a4,4,0,1,1,5.66,5.66L132,65.66v55.41l48-27.71L188.14,63A4,4,0,0,1,195.86,65l-7.51,28.05,28.6,7A4,4,0,0,1,216,108a4.07,4.07,0,0,1-1-.12l-31-7.61L136,128l48,27.73,31-7.61A4,4,0,0,1,219.88,151.05Z"/>'),IK=Ja("snowflake","0 0 256 256",'<path d="M221.83,150.57a6,6,0,0,1-4.4,7.26l-26.62,6.54,7,26.08a6,6,0,0,1-4.24,7.35,6.4,6.4,0,0,1-1.55.2,6,6,0,0,1-5.8-4.45L178.27,164,134,138.39v51.13l22.24,22.24a6,6,0,1,1-8.48,8.48L128,200.49l-19.76,19.75a6,6,0,0,1-8.48-8.48L122,189.52V138.39L77.73,164l-7.93,29.6A6,6,0,0,1,64,198a6.4,6.4,0,0,1-1.55-.2,6,6,0,0,1-4.24-7.35l7-26.08-26.62-6.54a6,6,0,0,1,2.86-11.66l30.23,7.43L116,128,71.66,102.4l-30.23,7.43A5.88,5.88,0,0,1,40,110a6,6,0,0,1-1.43-11.83l26.62-6.54-7-26.08a6,6,0,1,1,11.59-3.1l7.93,29.6L122,117.61V66.48L99.76,44.24a6,6,0,0,1,8.48-8.48L128,55.51l19.76-19.75a6,6,0,0,1,8.48,8.48L134,66.48v51.13l44.27-25.56,7.93-29.6a6,6,0,1,1,11.59,3.1l-7,26.08,26.62,6.54A6,6,0,0,1,216,110a5.88,5.88,0,0,1-1.43-.17l-30.23-7.43L140,128l44.34,25.6,30.23-7.43A6,6,0,0,1,221.83,150.57Z"/>'),Pp=Ja("snowflake","0 0 256 256",'<path d="M223.77,150.09a8,8,0,0,1-5.86,9.68l-24.64,6,6.46,24.11a8,8,0,0,1-5.66,9.8A8.25,8.25,0,0,1,192,200a8,8,0,0,1-7.72-5.93l-7.72-28.8L136,141.86v46.83l21.66,21.65a8,8,0,0,1-11.32,11.32L128,203.31l-18.34,18.35a8,8,0,0,1-11.32-11.32L120,188.69V141.86L79.45,165.27l-7.72,28.8A8,8,0,0,1,64,200a8.25,8.25,0,0,1-2.08-.27,8,8,0,0,1-5.66-9.8l6.46-24.11-24.64-6a8,8,0,0,1,3.82-15.54l29.45,7.23L112,128,71.36,104.54l-29.45,7.23A7.85,7.85,0,0,1,40,112a8,8,0,0,1-1.91-15.77l24.64-6L56.27,66.07a8,8,0,0,1,15.46-4.14l7.72,28.8L120,114.14V67.31L98.34,45.66a8,8,0,0,1,11.32-11.32L128,52.69l18.34-18.35a8,8,0,0,1,11.32,11.32L136,67.31v46.83l40.55-23.41,7.72-28.8a8,8,0,0,1,15.46,4.14l-6.46,24.11,24.64,6A8,8,0,0,1,216,112a7.85,7.85,0,0,1-1.91-.23l-29.45-7.23L144,128l40.64,23.46,29.45-7.23A8,8,0,0,1,223.77,150.09Z"/>'),RK=Ja("snowflake","0 0 256 256",'<path d="M227.65,149.14a12,12,0,0,1-8.79,14.51l-20.67,5.08,5.4,20.16a12,12,0,0,1-23.18,6.22l-7.29-27.2L140,148.78V187l20.48,20.48a12,12,0,0,1-17,17L128,209l-15.51,15.52a12,12,0,0,1-17-17L116,187V148.78L82.88,167.91l-7.29,27.2a12,12,0,0,1-23.18-6.22l5.4-20.16-20.67-5.08a12,12,0,1,1,5.72-23.3l27.89,6.85L104,128,70.75,108.8l-27.89,6.85A11.8,11.8,0,0,1,40,116a12,12,0,0,1-2.85-23.65l20.67-5.08-5.4-20.16a12,12,0,0,1,23.18-6.22l7.29,27.2L116,107.21V69L95.52,48.48a12,12,0,0,1,17-17L128,47l15.51-15.52a12,12,0,1,1,17,17L140,69v38.24l33.12-19.12,7.29-27.2a12,12,0,0,1,23.18,6.22l-5.4,20.16,20.67,5.08A12,12,0,0,1,216,116a11.8,11.8,0,0,1-2.87-.35l-27.89-6.85L152,128l33.25,19.2,27.89-6.85A12,12,0,0,1,227.65,149.14Z"/>'),DK=Ja("snowflake","0 0 256 256",'<path d="M128,24A104,104,0,1,0,232,128,104.11,104.11,0,0,0,128,24Zm42.37,119.22,18.94-6.76a8,8,0,1,1,5.38,15.08l-15.48,5.52,4.52,16.87a8,8,0,0,1-5.66,9.8A8.23,8.23,0,0,1,176,184a8,8,0,0,1-7.73-5.93l-5.57-20.8L136,141.86v30.83l13.66,13.65a8,8,0,0,1-11.32,11.32L128,187.31l-10.34,10.35a8,8,0,0,1-11.32-11.32L120,172.69V141.86L93.3,157.27l-5.57,20.8A8,8,0,0,1,80,184a8.23,8.23,0,0,1-2.07-.27,8,8,0,0,1-5.66-9.8l4.52-16.87-15.48-5.52a8,8,0,0,1,5.38-15.08l18.94,6.76L112,128,85.63,112.78l-18.94,6.76A8.18,8.18,0,0,1,64,120a8,8,0,0,1-2.69-15.54l15.48-5.52L72.27,82.07a8,8,0,0,1,15.46-4.14l5.57,20.8L120,114.14V83.31L106.34,69.66a8,8,0,0,1,11.32-11.32L128,68.69l10.34-10.35a8,8,0,0,1,11.32,11.32L136,83.31v30.83l26.7-15.41,5.57-20.8a8,8,0,0,1,15.46,4.14l-4.52,16.87,15.48,5.52A8,8,0,0,1,192,120a8.18,8.18,0,0,1-2.69-.46l-18.94-6.76L144,128Z"/>'),VK=Ja("snowflake","0 0 256 256",'<path d="M220,128a92,92,0,1,1-92-92A92.1,92.1,0,0,1,220,128Z" opacity="0.2"/><path d="M223.77,150.09a8,8,0,0,1-5.86,9.68l-24.64,6,6.46,24.11a8,8,0,0,1-5.66,9.8A8.25,8.25,0,0,1,192,200a8,8,0,0,1-7.72-5.93l-7.72-28.8L136,141.86v46.83l21.66,21.65a8,8,0,0,1-11.32,11.32L128,203.31l-18.34,18.35a8,8,0,0,1-11.32-11.32L120,188.69V141.86L79.45,165.27l-7.72,28.8A8,8,0,0,1,64,200a8.25,8.25,0,0,1-2.08-.27,8,8,0,0,1-5.66-9.8l6.46-24.11-24.64-6a8,8,0,0,1,3.82-15.54l29.45,7.23L112,128,71.36,104.54l-29.45,7.23A7.85,7.85,0,0,1,40,112a8,8,0,0,1-1.91-15.77l24.64-6L56.27,66.07a8,8,0,0,1,15.46-4.14l7.72,28.8L120,114.14V67.31L98.34,45.66a8,8,0,0,1,11.32-11.32L128,52.69l18.34-18.35a8,8,0,0,1,11.32,11.32L136,67.31v46.83l40.55-23.41,7.72-28.8a8,8,0,0,1,15.46,4.14l-6.46,24.11,24.64,6A8,8,0,0,1,216,112a7.85,7.85,0,0,1-1.91-.23l-29.45-7.23L144,128l40.64,23.46,29.45-7.23A8,8,0,0,1,223.77,150.09Z"/>'),BK="snowflake",ZK=Object.freeze(Object.defineProperty({__proto__:null,bold:RK,default:Pp,duotone:VK,fill:DK,glyphName:BK,light:IK,regular:Pp,thin:OK},Symbol.toStringTag,{value:"Module"})),Qa=(e,t,i)=>{const r=s=>Me("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:t,fill:"currentColor",...s,innerHTML:i});return r.displayName="NbGlyph",r.glyphName=e,r},FK=Qa("speaker-hifi","0 0 256 256",'<path d="M192,28H64A12,12,0,0,0,52,40V216a12,12,0,0,0,12,12H192a12,12,0,0,0,12-12V40A12,12,0,0,0,192,28Zm4,188a4,4,0,0,1-4,4H64a4,4,0,0,1-4-4V40a4,4,0,0,1,4-4H192a4,4,0,0,1,4,4ZM120,76a8,8,0,1,1,8,8A8,8,0,0,1,120,76Zm8,40a36,36,0,1,0,36,36A36,36,0,0,0,128,116Zm0,64a28,28,0,1,1,28-28A28,28,0,0,1,128,180Z"/>'),zK=Qa("speaker-hifi","0 0 256 256",'<path d="M192,26H64A14,14,0,0,0,50,40V216a14,14,0,0,0,14,14H192a14,14,0,0,0,14-14V40A14,14,0,0,0,192,26Zm2,190a2,2,0,0,1-2,2H64a2,2,0,0,1-2-2V40a2,2,0,0,1,2-2H192a2,2,0,0,1,2,2ZM118,76a10,10,0,1,1,10,10A10,10,0,0,1,118,76Zm10,38a38,38,0,1,0,38,38A38,38,0,0,0,128,114Zm0,64a26,26,0,1,1,26-26A26,26,0,0,1,128,178Z"/>'),Op=Qa("speaker-hifi","0 0 256 256",'<path d="M192,24H64A16,16,0,0,0,48,40V216a16,16,0,0,0,16,16H192a16,16,0,0,0,16-16V40A16,16,0,0,0,192,24Zm0,192H64V40H192ZM116,76a12,12,0,1,1,12,12A12,12,0,0,1,116,76Zm12,116a40,40,0,1,0-40-40A40,40,0,0,0,128,192Zm0-64a24,24,0,1,1-24,24A24,24,0,0,1,128,128Z"/>'),UK=Qa("speaker-hifi","0 0 256 256",'<path d="M192,20H64A20,20,0,0,0,44,40V216a20,20,0,0,0,20,20H192a20,20,0,0,0,20-20V40A20,20,0,0,0,192,20Zm-4,192H68V44H188ZM112,76a16,16,0,1,1,16,16A16,16,0,0,1,112,76Zm16,120a44,44,0,1,0-44-44A44.05,44.05,0,0,0,128,196Zm0-64a20,20,0,1,1-20,20A20,20,0,0,1,128,132Z"/>'),WK=Qa("speaker-hifi","0 0 256 256",'<path d="M152,160a24,24,0,1,1-24-24A24,24,0,0,1,152,160ZM208,40V216a16,16,0,0,1-16,16H64a16,16,0,0,1-16-16V40A16,16,0,0,1,64,24H192A16,16,0,0,1,208,40ZM116,68a12,12,0,1,0,12-12A12,12,0,0,0,116,68Zm52,92a40,40,0,1,0-40,40A40,40,0,0,0,168,160Z"/>'),jK=Qa("speaker-hifi","0 0 256 256",'<path d="M192,32H64a8,8,0,0,0-8,8V216a8,8,0,0,0,8,8H192a8,8,0,0,0,8-8V40A8,8,0,0,0,192,32ZM128,184a32,32,0,1,1,32-32A32,32,0,0,1,128,184Z" opacity="0.2"/><path d="M192,24H64A16,16,0,0,0,48,40V216a16,16,0,0,0,16,16H192a16,16,0,0,0,16-16V40A16,16,0,0,0,192,24Zm0,192H64V40H192ZM116,76a12,12,0,1,1,12,12A12,12,0,0,1,116,76Zm12,116a40,40,0,1,0-40-40A40,40,0,0,0,128,192Zm0-64a24,24,0,1,1-24,24A24,24,0,0,1,128,128Z"/>'),KK="speaker-hifi",qK=Object.freeze(Object.defineProperty({__proto__:null,bold:UK,default:Op,duotone:jK,fill:WK,glyphName:KK,light:zK,regular:Op,thin:FK},Symbol.toStringTag,{value:"Module"})),eo=(e,t,i)=>{const r=s=>Me("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:t,fill:"currentColor",...s,innerHTML:i});return r.displayName="NbGlyph",r.glyphName=e,r},GK=eo("speaker-high","0 0 256 256",'<path d="M153.76,28.41a4,4,0,0,0-4.22.43L78.63,84H32A12,12,0,0,0,20,96v64a12,12,0,0,0,12,12H78.63l70.91,55.16A4.07,4.07,0,0,0,152,228a3.92,3.92,0,0,0,1.76-.41A4,4,0,0,0,156,224V32A4,4,0,0,0,153.76,28.41ZM28,160V96a4,4,0,0,1,4-4H76v72H32A4,4,0,0,1,28,160Zm120,55.82L84,166V90l64-49.78Zm47-111.61a36,36,0,0,1,0,47.59,4,4,0,1,1-6-5.3,28,28,0,0,0,0-37,4,4,0,0,1,6-5.28ZM244,128a75.88,75.88,0,0,1-19.35,50.67,4,4,0,0,1-6-5.34,68,68,0,0,0,0-90.66,4,4,0,0,1,6-5.34A75.88,75.88,0,0,1,244,128Z"/>'),YK=eo("speaker-high","0 0 256 256",'<path d="M154.64,26.61a6,6,0,0,0-6.32.65L77.94,82H32A14,14,0,0,0,18,96v64a14,14,0,0,0,14,14H77.94l70.38,54.74A6,6,0,0,0,158,224V32A6,6,0,0,0,154.64,26.61ZM30,160V96a2,2,0,0,1,2-2H74v68H32A2,2,0,0,1,30,160Zm116,51.73L86,165.07V90.93l60-46.66Zm50.53-108.85a38,38,0,0,1,0,50.24,6,6,0,1,1-9-7.94,26,26,0,0,0,0-34.37,6,6,0,0,1,9-7.93ZM246,128a77.86,77.86,0,0,1-19.86,52,6,6,0,1,1-8.94-8,66,66,0,0,0,0-88,6,6,0,1,1,8.94-8A77.86,77.86,0,0,1,246,128Z"/>'),Ip=eo("speaker-high","0 0 256 256",'<path d="M155.51,24.81a8,8,0,0,0-8.42.88L77.25,80H32A16,16,0,0,0,16,96v64a16,16,0,0,0,16,16H77.25l69.84,54.31A8,8,0,0,0,160,224V32A8,8,0,0,0,155.51,24.81ZM32,96H72v64H32ZM144,207.64,88,164.09V91.91l56-43.55Zm54-106.08a40,40,0,0,1,0,52.88,8,8,0,0,1-12-10.58,24,24,0,0,0,0-31.72,8,8,0,0,1,12-10.58ZM248,128a79.9,79.9,0,0,1-20.37,53.34,8,8,0,0,1-11.92-10.67,64,64,0,0,0,0-85.33,8,8,0,1,1,11.92-10.67A79.83,79.83,0,0,1,248,128Z"/>'),XK=eo("speaker-high","0 0 256 256",'<path d="M157.27,21.22a12,12,0,0,0-12.64,1.31L75.88,76H32A20,20,0,0,0,12,96v64a20,20,0,0,0,20,20H75.88l68.75,53.47A12,12,0,0,0,164,224V32A12,12,0,0,0,157.27,21.22ZM36,100H68v56H36Zm104,99.46L92,162.13V93.87l48-37.33ZM212,128a44,44,0,0,1-11,29.11,12,12,0,1,1-18-15.88,20,20,0,0,0,0-26.43,12,12,0,0,1,18-15.86A43.94,43.94,0,0,1,212,128Zm40,0a83.87,83.87,0,0,1-21.39,56,12,12,0,0,1-17.89-16,60,60,0,0,0,0-80,12,12,0,1,1,17.88-16A83.87,83.87,0,0,1,252,128Z"/>'),JK=eo("speaker-high","0 0 256 256",'<path d="M160,32.25V223.69a8.29,8.29,0,0,1-3.91,7.18,8,8,0,0,1-9-.56l-65.57-51A4,4,0,0,1,80,176.16V79.84a4,4,0,0,1,1.55-3.15l65.57-51a8,8,0,0,1,10,.16A8.27,8.27,0,0,1,160,32.25ZM60,80H32A16,16,0,0,0,16,96v64a16,16,0,0,0,16,16H60a4,4,0,0,0,4-4V84A4,4,0,0,0,60,80Zm126.77,20.84a8,8,0,0,0-.72,11.3,24,24,0,0,1,0,31.72,8,8,0,1,0,12,10.58,40,40,0,0,0,0-52.88A8,8,0,0,0,186.74,100.84Zm40.89-26.17a8,8,0,1,0-11.92,10.66,64,64,0,0,1,0,85.34,8,8,0,1,0,11.92,10.66,80,80,0,0,0,0-106.66Z"/>'),QK=eo("speaker-high","0 0 256 256",'<path d="M80,88v80H32a8,8,0,0,1-8-8V96a8,8,0,0,1,8-8Z" opacity="0.2"/><path d="M155.51,24.81a8,8,0,0,0-8.42.88L77.25,80H32A16,16,0,0,0,16,96v64a16,16,0,0,0,16,16H77.25l69.84,54.31A8,8,0,0,0,160,224V32A8,8,0,0,0,155.51,24.81ZM32,96H72v64H32ZM144,207.64,88,164.09V91.91l56-43.55Zm54-106.08a40,40,0,0,1,0,52.88,8,8,0,0,1-12-10.58,24,24,0,0,0,0-31.72,8,8,0,0,1,12-10.58ZM248,128a79.9,79.9,0,0,1-20.37,53.34,8,8,0,0,1-11.92-10.67,64,64,0,0,0,0-85.33,8,8,0,1,1,11.92-10.67A79.83,79.83,0,0,1,248,128Z"/>'),eq="speaker-high",tq=Object.freeze(Object.defineProperty({__proto__:null,bold:XK,default:Ip,duotone:QK,fill:JK,glyphName:eq,light:YK,regular:Ip,thin:GK},Symbol.toStringTag,{value:"Module"})),to=(e,t,i)=>{const r=s=>Me("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:t,fill:"currentColor",...s,innerHTML:i});return r.displayName="NbGlyph",r.glyphName=e,r},iq=to("television","0 0 256 256",'<path d="M216,68H137.66l41.17-41.17a4,4,0,1,0-5.66-5.66L128,66.34,82.83,21.17a4,4,0,0,0-5.66,5.66L118.34,68H40A12,12,0,0,0,28,80V200a12,12,0,0,0,12,12H216a12,12,0,0,0,12-12V80A12,12,0,0,0,216,68ZM36,200V80a4,4,0,0,1,4-4H148V204H40A4,4,0,0,1,36,200Zm184,0a4,4,0,0,1-4,4H156V76h60a4,4,0,0,1,4,4Zm-24-84a8,8,0,1,1-8-8A8,8,0,0,1,196,116Zm0,48a8,8,0,1,1-8-8A8,8,0,0,1,196,164Z"/>'),rq=to("television","0 0 256 256",'<path d="M216,66H142.48l37.76-37.76a6,6,0,0,0-8.48-8.48L128,63.51,84.24,19.76a6,6,0,1,0-8.48,8.48L113.52,66H40A14,14,0,0,0,26,80V200a14,14,0,0,0,14,14H216a14,14,0,0,0,14-14V80A14,14,0,0,0,216,66ZM38,200V80a2,2,0,0,1,2-2H146V202H40A2,2,0,0,1,38,200Zm180,0a2,2,0,0,1-2,2H158V78h58a2,2,0,0,1,2,2Zm-20-84a10,10,0,1,1-10-10A10,10,0,0,1,198,116Zm0,48a10,10,0,1,1-10-10A10,10,0,0,1,198,164Z"/>'),Rp=to("television","0 0 256 256",'<path d="M216,64H147.31l34.35-34.34a8,8,0,1,0-11.32-11.32L128,60.69,85.66,18.34A8,8,0,0,0,74.34,29.66L108.69,64H40A16,16,0,0,0,24,80V200a16,16,0,0,0,16,16H216a16,16,0,0,0,16-16V80A16,16,0,0,0,216,64ZM40,80H144V200H40ZM216,200H160V80h56V200Zm-16-84a12,12,0,1,1-12-12A12,12,0,0,1,200,116Zm0,48a12,12,0,1,1-12-12A12,12,0,0,1,200,164Z"/>'),sq=to("television","0 0 256 256",'<path d="M216,60H157l27.52-27.52a12,12,0,0,0-17-17L128,55,88.49,15.51a12,12,0,0,0-17,17L99,60H40A20,20,0,0,0,20,80V200a20,20,0,0,0,20,20H216a20,20,0,0,0,20-20V80A20,20,0,0,0,216,60ZM44,84h84V196H44ZM212,196H152V84h60Zm-44-80a16,16,0,1,1,16,16A16,16,0,0,1,168,116Zm32,48a16,16,0,1,1-16-16A16,16,0,0,1,200,164Z"/>'),nq=to("television","0 0 256 256",'<path d="M216,64H147.31l34.35-34.34a8,8,0,1,0-11.32-11.32L128,60.69,85.66,18.34A8,8,0,0,0,74.34,29.66L108.69,64H40A16,16,0,0,0,24,80V200a16,16,0,0,0,16,16H216a16,16,0,0,0,16-16V80A16,16,0,0,0,216,64Zm0,136H160V80h56V200Zm-16-84a12,12,0,1,1-12-12A12,12,0,0,1,200,116Zm0,48a12,12,0,1,1-12-12A12,12,0,0,1,200,164Z"/>'),aq=to("television","0 0 256 256",'<path d="M152,72V208H40a8,8,0,0,1-8-8V80a8,8,0,0,1,8-8Z" opacity="0.2"/><path d="M216,64H147.31l34.35-34.34a8,8,0,1,0-11.32-11.32L128,60.69,85.66,18.34A8,8,0,0,0,74.34,29.66L108.69,64H40A16,16,0,0,0,24,80V200a16,16,0,0,0,16,16H216a16,16,0,0,0,16-16V80A16,16,0,0,0,216,64ZM40,80H144V200H40ZM216,200H160V80h56V200Zm-16-84a12,12,0,1,1-12-12A12,12,0,0,1,200,116Zm0,48a12,12,0,1,1-12-12A12,12,0,0,1,200,164Z"/>'),oq="television",lq=Object.freeze(Object.defineProperty({__proto__:null,bold:sq,default:Rp,duotone:aq,fill:nq,glyphName:oq,light:rq,regular:Rp,thin:iq},Symbol.toStringTag,{value:"Module"})),io=(e,t,i)=>{const r=s=>Me("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:t,fill:"currentColor",...s,innerHTML:i});return r.displayName="NbGlyph",r.glyphName=e,r},cq=io("terminal","0 0 256 256",'<path d="M116,128a4,4,0,0,1-1.34,3l-72,64a4,4,0,1,1-5.32-6L106,128,37.34,67a4,4,0,0,1,5.32-6l72,64A4,4,0,0,1,116,128Zm100,60H120a4,4,0,0,0,0,8h96a4,4,0,0,0,0-8Z"/>'),uq=io("terminal","0 0 256 256",'<path d="M116,132.48l-72,64a6,6,0,0,1-8-9L103,128,36,68.49a6,6,0,0,1,8-9l72,64a6,6,0,0,1,0,9ZM216,186H120a6,6,0,0,0,0,12h96a6,6,0,0,0,0-12Z"/>'),Dp=io("terminal","0 0 256 256",'<path d="M117.31,134l-72,64a8,8,0,1,1-10.63-12L100,128,34.69,70A8,8,0,1,1,45.32,58l72,64a8,8,0,0,1,0,12ZM216,184H120a8,8,0,0,0,0,16h96a8,8,0,0,0,0-16Z"/>'),hq=io("terminal","0 0 256 256",'<path d="M120,137,48,201A12,12,0,1,1,32,183l61.91-55L32,73A12,12,0,1,1,48,55l72,64A12,12,0,0,1,120,137Zm96,43H120a12,12,0,0,0,0,24h96a12,12,0,0,0,0-24Z"/>'),dq=io("terminal","0 0 256 256",'<path d="M216,40H40A16,16,0,0,0,24,56V200a16,16,0,0,0,16,16H216a16,16,0,0,0,16-16V56A16,16,0,0,0,216,40ZM77.66,173.66a8,8,0,0,1-11.32-11.32L100.69,128,66.34,93.66A8,8,0,0,1,77.66,82.34l40,40a8,8,0,0,1,0,11.32ZM192,176H128a8,8,0,0,1,0-16h64a8,8,0,0,1,0,16Z"/>'),fq=io("terminal","0 0 256 256",'<path d="M216,80V192H40V64H200A16,16,0,0,1,216,80Z" opacity="0.2"/><path d="M117.31,134l-72,64a8,8,0,1,1-10.63-12L100,128,34.69,70A8,8,0,1,1,45.32,58l72,64a8,8,0,0,1,0,12ZM216,184H120a8,8,0,0,0,0,16h96a8,8,0,0,0,0-16Z"/>'),pq="terminal",_q=Object.freeze(Object.defineProperty({__proto__:null,bold:hq,default:Dp,duotone:fq,fill:dq,glyphName:pq,light:uq,regular:Dp,thin:cq},Symbol.toStringTag,{value:"Module"})),ro=(e,t,i)=>{const r=s=>Me("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:t,fill:"currentColor",...s,innerHTML:i});return r.displayName="NbGlyph",r.glyphName=e,r},mq=ro("thermometer","0 0 256 256",'<path d="M212,60a24,24,0,1,0,24,24A24,24,0,0,0,212,60Zm0,40a16,16,0,1,1,16-16A16,16,0,0,1,212,100Zm-88,56.29V88a4,4,0,0,0-8,0v68.29a28,28,0,1,0,8,0ZM120,204a20,20,0,1,1,20-20A20,20,0,0,1,120,204Zm36-68V48a36,36,0,0,0-72,0v88a60,60,0,1,0,72,0ZM120,236a52,52,0,0,1-29.71-94.68A4,4,0,0,0,92,138V48a28,28,0,0,1,56,0v90a4,4,0,0,0,1.71,3.28A52,52,0,0,1,120,236Z"/>'),gq=ro("thermometer","0 0 256 256",'<path d="M212,58a26,26,0,1,0,26,26A26,26,0,0,0,212,58Zm0,40a14,14,0,1,1,14-14A14,14,0,0,1,212,98Zm-86,56.6V88a6,6,0,0,0-12,0v66.6a30,30,0,1,0,12,0ZM120,202a18,18,0,1,1,18-18A18,18,0,0,1,120,202Zm38-67V48a38,38,0,0,0-76,0v87a62,62,0,1,0,76,0Zm-38,99a50,50,0,0,1-28.57-91A6,6,0,0,0,94,138V48a26,26,0,0,1,52,0v90a6,6,0,0,0,2.57,4.92A50,50,0,0,1,120,234Z"/>'),Vp=ro("thermometer","0 0 256 256",'<path d="M212,56a28,28,0,1,0,28,28A28,28,0,0,0,212,56Zm0,40a12,12,0,1,1,12-12A12,12,0,0,1,212,96Zm-84,57V88a8,8,0,0,0-16,0v65a32,32,0,1,0,16,0Zm-8,47a16,16,0,1,1,16-16A16,16,0,0,1,120,200Zm40-66V48a40,40,0,0,0-80,0v86a64,64,0,1,0,80,0Zm-40,98a48,48,0,0,1-27.42-87.4A8,8,0,0,0,96,138V48a24,24,0,0,1,48,0v90a8,8,0,0,0,3.42,6.56A48,48,0,0,1,120,232Z"/>'),vq=ro("thermometer","0 0 256 256",'<path d="M212,52a32,32,0,1,0,32,32A32,32,0,0,0,212,52Zm0,40a8,8,0,1,1,8-8A8,8,0,0,1,212,92ZM160,56A52,52,0,0,0,56,56v94.69a64,64,0,1,0,104,0ZM108,228a40,40,0,0,1-30.91-65.39A12,12,0,0,0,80,154.78V56a28,28,0,0,1,56,0v98.77a12,12,0,0,0,2.77,7.68A40,40,0,0,1,108,228Zm24-40a24,24,0,1,1-36-20.78V92a12,12,0,0,1,24,0v75.22A24,24,0,0,1,132,188Z"/>'),bq=ro("thermometer","0 0 256 256",'<path d="M212,56a28,28,0,1,0,28,28A28,28,0,0,0,212,56Zm0,40a12,12,0,1,1,12-12A12,12,0,0,1,212,96Zm-60,50.08V40a32,32,0,0,0-64,0V146.08a56,56,0,1,0,64,0ZM136,104H104V40a16,16,0,0,1,32,0Z"/>'),yq=ro("thermometer","0 0 256 256",'<path d="M152,138V48a32,32,0,0,0-64,0v90a56,56,0,1,0,64,0Zm-32,70a24,24,0,1,1,24-24A24,24,0,0,1,120,208Z" opacity="0.2"/><path d="M212,56a28,28,0,1,0,28,28A28,28,0,0,0,212,56Zm0,40a12,12,0,1,1,12-12A12,12,0,0,1,212,96Zm-84,57V88a8,8,0,0,0-16,0v65a32,32,0,1,0,16,0Zm-8,47a16,16,0,1,1,16-16A16,16,0,0,1,120,200Zm40-66V48a40,40,0,0,0-80,0v86a64,64,0,1,0,80,0Zm-40,98a48,48,0,0,1-27.42-87.4A8,8,0,0,0,96,138V48a24,24,0,0,1,48,0v90a8,8,0,0,0,3.42,6.56A48,48,0,0,1,120,232Z"/>'),wq="thermometer",Sq=Object.freeze(Object.defineProperty({__proto__:null,bold:vq,default:Vp,duotone:yq,fill:bq,glyphName:wq,light:gq,regular:Vp,thin:mq},Symbol.toStringTag,{value:"Module"})),so=(e,t,i)=>{const r=s=>Me("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:t,fill:"currentColor",...s,innerHTML:i});return r.displayName="NbGlyph",r.glyphName=e,r},Cq=so("thermometer-hot","0 0 256 256",'<path d="M124,156.29V48a4,4,0,0,0-8,0V156.29a28,28,0,1,0,8,0ZM120,204a20,20,0,1,1,20-20A20,20,0,0,1,120,204Zm36-68V48a36,36,0,0,0-72,0v88a60,60,0,1,0,72,0ZM120,236a52,52,0,0,1-29.71-94.68A4,4,0,0,0,92,138V48a28,28,0,0,1,56,0v90a4,4,0,0,0,1.71,3.28A52,52,0,0,1,120,236ZM180.65,78.59a4,4,0,0,1,1.17-5.54c13.24-8.63,23.07-4.43,31.75-.73,8.15,3.48,14.58,6.22,24.25-.07a4,4,0,1,1,4.36,6.7C236.43,82.7,231.32,84,226.67,84c-6.06,0-11.33-2.25-16.24-4.34-8.15-3.47-14.58-6.22-24.25.07A4,4,0,0,1,180.65,78.59Zm62.7,26.82a4,4,0,0,1-1.17,5.54c-5.75,3.75-10.86,5.07-15.51,5.07-6.06,0-11.33-2.25-16.24-4.34-8.15-3.47-14.58-6.22-24.25.07a4,4,0,1,1-4.36-6.7c13.24-8.63,23.07-4.43,31.75-.73,8.15,3.48,14.58,6.22,24.25-.07A4,4,0,0,1,243.35,105.41Z"/>'),kq=so("thermometer-hot","0 0 256 256",'<path d="M126,154.6V48a6,6,0,0,0-12,0V154.6a30,30,0,1,0,12,0ZM120,202a18,18,0,1,1,18-18A18,18,0,0,1,120,202Zm38-67V48a38,38,0,0,0-76,0v87a62,62,0,1,0,76,0Zm-38,99a50,50,0,0,1-28.57-91A6,6,0,0,0,94,138V48a26,26,0,0,1,52,0v90a6,6,0,0,0,2.57,4.92A50,50,0,0,1,120,234ZM179,79.68a6,6,0,0,1,1.75-8.3c14.14-9.21,24.95-4.61,33.63-.9,7.9,3.37,13.6,5.8,22.37.09a6,6,0,1,1,6.55,10.05c-6.12,4-11.62,5.39-16.59,5.39-6.51,0-12.11-2.39-17-4.49-7.89-3.37-13.59-5.8-22.37-.09A6,6,0,0,1,179,79.68ZM245,104.32a6,6,0,0,1-1.76,8.3c-6.12,4-11.62,5.39-16.59,5.39-6.51,0-12.11-2.39-17-4.49-7.89-3.37-13.59-5.8-22.37-.09a6,6,0,0,1-6.55-10.05c14.14-9.21,24.95-4.6,33.63-.9,7.9,3.37,13.6,5.8,22.37.09A6,6,0,0,1,245,104.32Z"/>'),Bp=so("thermometer-hot","0 0 256 256",'<path d="M128,153V48a8,8,0,0,0-16,0V153a32,32,0,1,0,16,0Zm-8,47a16,16,0,1,1,16-16A16,16,0,0,1,120,200Zm40-66V48a40,40,0,0,0-80,0v86a64,64,0,1,0,80,0Zm-40,98a48,48,0,0,1-27.42-87.4A8,8,0,0,0,96,138V48a24,24,0,0,1,48,0v90a8,8,0,0,0,3.42,6.56A48,48,0,0,1,120,232ZM177.3,80.77a8,8,0,0,1,2.33-11.07c15-9.79,26.87-4.75,35.51-1.06C223,72,227.76,74,235.63,68.89a8,8,0,0,1,8.74,13.41C237.88,86.53,232,88,226.69,88c-7,0-12.92-2.54-17.83-4.63C201,80,196.24,78,188.37,83.11A8,8,0,0,1,177.3,80.77Zm69.4,22.46a8,8,0,0,1-2.33,11.07C237.88,118.53,232,120,226.69,120c-7,0-12.92-2.54-17.83-4.63-7.87-3.36-12.62-5.38-20.49-.25a8,8,0,0,1-8.74-13.41c15-9.79,26.87-4.75,35.51-1.06,7.87,3.36,12.62,5.39,20.49.25A8,8,0,0,1,246.7,103.23Z"/>'),Aq=so("thermometer-hot","0 0 256 256",'<path d="M160,56A52,52,0,0,0,56,56v94.69a64,64,0,1,0,104,0ZM108,228a40,40,0,0,1-30.91-65.39A12,12,0,0,0,80,154.78V56a28,28,0,0,1,56,0v98.77a12,12,0,0,0,2.77,7.68A40,40,0,0,1,108,228Zm24-40a24,24,0,1,1-36-20.78V56a12,12,0,0,1,24,0V167.22A24,24,0,0,1,132,188ZM173.94,83a12,12,0,0,1,3.51-16.6c16.82-11,30.32-5.2,39.26-1.39,8.09,3.46,10.93,4.37,16.74.58a12,12,0,0,1,13.1,20.11C239.28,90.38,232.64,92,226.71,92c-7.79,0-14.34-2.8-19.42-5-8.09-3.46-10.93-4.37-16.74-.58A12,12,0,0,1,173.94,83Zm76.11,26.1a12,12,0,0,1-3.5,16.6c-7.27,4.73-13.91,6.35-19.84,6.35-7.79,0-14.34-2.8-19.42-5-8.09-3.46-10.93-4.37-16.74-.58a12,12,0,1,1-13.1-20.11c16.82-11,30.32-5.2,39.26-1.39,8.09,3.46,10.93,4.37,16.74.58A12,12,0,0,1,250.05,109.05Z"/>'),Mq=so("thermometer-hot","0 0 256 256",'<path d="M152,146.08V40a32,32,0,0,0-64,0V146.08a56,56,0,1,0,64,0ZM136,56H104V40a16,16,0,0,1,32,0Zm41.3,24.77a8,8,0,0,1,2.33-11.07c15-9.79,26.87-4.75,35.51-1.06C223,72,227.76,74,235.63,68.89a8,8,0,0,1,8.74,13.41C237.88,86.53,232,88,226.69,88c-7,0-12.92-2.54-17.83-4.63C201,80,196.24,78,188.37,83.11A8,8,0,0,1,177.3,80.77Zm69.4,22.46a8,8,0,0,1-2.33,11.07C237.88,118.53,232,120,226.69,120c-7,0-12.92-2.54-17.83-4.63-7.87-3.36-12.62-5.38-20.49-.25a8,8,0,0,1-8.74-13.41c15-9.79,26.87-4.75,35.51-1.06,7.87,3.36,12.62,5.39,20.49.25A8,8,0,0,1,246.7,103.23Z"/>'),Lq=so("thermometer-hot","0 0 256 256",'<path d="M152,138V48a32,32,0,0,0-64,0v90a56,56,0,1,0,64,0Zm-32,70a24,24,0,1,1,24-24A24,24,0,0,1,120,208Z" opacity="0.2"/><path d="M128,153V48a8,8,0,0,0-16,0V153a32,32,0,1,0,16,0Zm-8,47a16,16,0,1,1,16-16A16,16,0,0,1,120,200Zm40-66V48a40,40,0,0,0-80,0v86a64,64,0,1,0,80,0Zm-40,98a48,48,0,0,1-27.42-87.4A8,8,0,0,0,96,138V48a24,24,0,0,1,48,0v90a8,8,0,0,0,3.42,6.56A48,48,0,0,1,120,232ZM177.3,80.77a8,8,0,0,1,2.33-11.07c15-9.79,26.87-4.75,35.51-1.06C223,72,227.76,74,235.63,68.89a8,8,0,0,1,8.74,13.41C237.88,86.53,232,88,226.69,88c-7,0-12.92-2.54-17.83-4.63C201,80,196.24,78,188.37,83.11A8,8,0,0,1,177.3,80.77Zm69.4,22.46a8,8,0,0,1-2.33,11.07C237.88,118.53,232,120,226.69,120c-7,0-12.92-2.54-17.83-4.63-7.87-3.36-12.62-5.38-20.49-.25a8,8,0,0,1-8.74-13.41c15-9.79,26.87-4.75,35.51-1.06,7.87,3.36,12.62,5.39,20.49.25A8,8,0,0,1,246.7,103.23Z"/>'),Eq="thermometer-hot",$q=Object.freeze(Object.defineProperty({__proto__:null,bold:Aq,default:Bp,duotone:Lq,fill:Mq,glyphName:Eq,light:kq,regular:Bp,thin:Cq},Symbol.toStringTag,{value:"Module"})),no=(e,t,i)=>{const r=s=>Me("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:t,fill:"currentColor",...s,innerHTML:i});return r.displayName="NbGlyph",r.glyphName=e,r},xq=no("toggle-right","0 0 256 256",'<path d="M176,60H80a68,68,0,0,0,0,136h96a68,68,0,0,0,0-136Zm0,128H80A60,60,0,0,1,80,68h96a60,60,0,0,1,0,120Zm0-96a36,36,0,1,0,36,36A36,36,0,0,0,176,92Zm0,64a28,28,0,1,1,28-28A28,28,0,0,1,176,156Z"/>'),Tq=no("toggle-right","0 0 256 256",'<path d="M176,58H80a70,70,0,0,0,0,140h96a70,70,0,0,0,0-140Zm0,128H80A58,58,0,0,1,80,70h96a58,58,0,0,1,0,116Zm0-96a38,38,0,1,0,38,38A38,38,0,0,0,176,90Zm0,64a26,26,0,1,1,26-26A26,26,0,0,1,176,154Z"/>'),Zp=no("toggle-right","0 0 256 256",'<path d="M176,56H80a72,72,0,0,0,0,144h96a72,72,0,0,0,0-144Zm0,128H80A56,56,0,0,1,80,72h96a56,56,0,0,1,0,112Zm0-96a40,40,0,1,0,40,40A40,40,0,0,0,176,88Zm0,64a24,24,0,1,1,24-24A24,24,0,0,1,176,152Z"/>'),Nq=no("toggle-right","0 0 256 256",'<path d="M176,52H80a76,76,0,0,0,0,152h96a76,76,0,0,0,0-152Zm0,128H80A52,52,0,0,1,80,76h96a52,52,0,0,1,0,104Zm0-92a40,40,0,1,0,40,40A40,40,0,0,0,176,88Zm0,56a16,16,0,1,1,16-16A16,16,0,0,1,176,144Z"/>'),Hq=no("toggle-right","0 0 256 256",'<path d="M176,56H80a72,72,0,0,0,0,144h96a72,72,0,0,0,0-144Zm0,112a40,40,0,1,1,40-40A40,40,0,0,1,176,168Z"/>'),Pq=no("toggle-right","0 0 256 256",'<path d="M208,128a32,32,0,1,1-32-32A32,32,0,0,1,208,128Z" opacity="0.2"/><path d="M176,56H80a72,72,0,0,0,0,144h96a72,72,0,0,0,0-144Zm0,128H80A56,56,0,0,1,80,72h96a56,56,0,0,1,0,112Zm0-96a40,40,0,1,0,40,40A40,40,0,0,0,176,88Zm0,64a24,24,0,1,1,24-24A24,24,0,0,1,176,152Z"/>'),Oq="toggle-right",Iq=Object.freeze(Object.defineProperty({__proto__:null,bold:Nq,default:Zp,duotone:Pq,fill:Hq,glyphName:Oq,light:Tq,regular:Zp,thin:xq},Symbol.toStringTag,{value:"Module"})),ao=(e,t,i)=>{const r=s=>Me("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:t,fill:"currentColor",...s,innerHTML:i});return r.displayName="NbGlyph",r.glyphName=e,r},Rq=ao("wind","0 0 256 256",'<path d="M180,184a28,28,0,0,1-28,28c-12.09,0-23.76-7.83-27.75-18.61a4,4,0,1,1,7.5-2.78C134.58,198.24,143.28,204,152,204a20,20,0,0,0,0-40H40a4,4,0,0,1,0-8H152A28,28,0,0,1,180,184ZM148,72a28,28,0,0,0-28-28c-12.09,0-23.76,7.83-27.75,18.61a4,4,0,0,0,7.5,2.78C102.58,57.76,111.28,52,120,52a20,20,0,0,1,0,40H24a4,4,0,0,0,0,8h96A28,28,0,0,0,148,72Zm60,4c-12.09,0-23.76,7.83-27.75,18.61a4,4,0,1,0,7.5,2.78C190.58,89.76,199.28,84,208,84a20,20,0,0,1,0,40H32a4,4,0,0,0,0,8H208a28,28,0,0,0,0-56Z"/>'),Dq=ao("wind","0 0 256 256",'<path d="M182,184a30,30,0,0,1-30,30c-12.9,0-25.36-8.38-29.63-19.92a6,6,0,0,1,11.26-4.16C136.13,196.69,144.2,202,152,202a18,18,0,0,0,0-36H40a6,6,0,0,1,0-12H152A30,30,0,0,1,182,184ZM150,72a30,30,0,0,0-30-30c-12.9,0-25.36,8.38-29.63,19.92a6,6,0,1,0,11.26,4.16C104.13,59.31,112.2,54,120,54a18,18,0,0,1,0,36H24a6,6,0,0,0,0,12h96A30,30,0,0,0,150,72Zm58,2c-12.9,0-25.36,8.38-29.63,19.92a6,6,0,1,0,11.26,4.16C192.13,91.31,200.2,86,208,86a18,18,0,0,1,0,36H32a6,6,0,0,0,0,12H208a30,30,0,0,0,0-60Z"/>'),Fp=ao("wind","0 0 256 256",'<path d="M184,184a32,32,0,0,1-32,32c-13.7,0-26.95-8.93-31.5-21.22a8,8,0,0,1,15-5.56C137.74,195.27,145,200,152,200a16,16,0,0,0,0-32H40a8,8,0,0,1,0-16H152A32,32,0,0,1,184,184Zm-64-80a32,32,0,0,0,0-64c-13.7,0-26.95,8.93-31.5,21.22a8,8,0,0,0,15,5.56C105.74,60.73,113,56,120,56a16,16,0,0,1,0,32H24a8,8,0,0,0,0,16Zm88-32c-13.7,0-26.95,8.93-31.5,21.22a8,8,0,0,0,15,5.56C193.74,92.73,201,88,208,88a16,16,0,0,1,0,32H32a8,8,0,0,0,0,16H208a32,32,0,0,0,0-64Z"/>'),Vq=ao("wind","0 0 256 256",'<path d="M24,104a12,12,0,0,1,0-24h96a12,12,0,0,0,0-24,15.07,15.07,0,0,0-10.26,4.45,12,12,0,0,1-17-16.9A39.34,39.34,0,0,1,120,32a36,36,0,0,1,0,72ZM208,68a39.34,39.34,0,0,0-27.3,11.55,12,12,0,0,0,17,16.9A15.07,15.07,0,0,1,208,92a12,12,0,0,1,0,24H32a12,12,0,0,0,0,24H208a36,36,0,0,0,0-72Zm-56,84H40a12,12,0,0,0,0,24H152a12,12,0,0,1,0,24,15.11,15.11,0,0,1-10.27-4.45,12,12,0,1,0-17,16.9A39.34,39.34,0,0,0,152,224a36,36,0,0,0,0-72Z"/>'),Bq=ao("wind","0 0 256 256",'<path d="M120,104H24a8,8,0,0,1-8-8.53A8.17,8.17,0,0,1,24.27,88H112a8,8,0,0,0,8-8.53A8.17,8.17,0,0,0,111.73,72H92.29a4,4,0,0,1-4-4.58A32,32,0,1,1,120,104Zm119.92-2.29a32,32,0,0,0-63.59-2.29,4,4,0,0,0,4,4.58h19.44a8.17,8.17,0,0,1,8.25,7.47,8,8,0,0,1-8,8.53H32.27A8.17,8.17,0,0,0,24,127.47,8,8,0,0,0,32,136H208A32,32,0,0,0,239.92,101.71ZM152,152H40.27A8.17,8.17,0,0,0,32,159.47,8,8,0,0,0,40,168H143.73a8.17,8.17,0,0,1,8.25,7.47,8,8,0,0,1-8,8.53H124.29a4,4,0,0,0-4,4.58A32,32,0,1,0,152,152Z"/>'),Zq=ao("wind","0 0 256 256",'<path d="M120,96a24,24,0,1,1,24-24A24,24,0,0,1,120,96Zm88-16a24,24,0,1,0,24,24A24,24,0,0,0,208,80Zm-56,80a24,24,0,1,0,24,24A24,24,0,0,0,152,160Z" opacity="0.2"/><path d="M184,184a32,32,0,0,1-32,32c-13.7,0-26.95-8.93-31.5-21.22a8,8,0,0,1,15-5.56C137.74,195.27,145,200,152,200a16,16,0,0,0,0-32H40a8,8,0,0,1,0-16H152A32,32,0,0,1,184,184Zm-64-80a32,32,0,0,0,0-64c-13.7,0-26.95,8.93-31.5,21.22a8,8,0,0,0,15,5.56C105.74,60.73,113,56,120,56a16,16,0,0,1,0,32H24a8,8,0,0,0,0,16Zm88-32c-13.7,0-26.95,8.93-31.5,21.22a8,8,0,0,0,15,5.56C193.74,92.73,201,88,208,88a16,16,0,0,1,0,32H32a8,8,0,0,0,0,16H208a32,32,0,0,0,0-64Z"/>'),Fq="wind",zq=Object.freeze(Object.defineProperty({__proto__:null,bold:Vq,default:Fp,duotone:Zq,fill:Bq,glyphName:Fq,light:Dq,regular:Fp,thin:Rq},Symbol.toStringTag,{value:"Module"}));function Uq(){Iw({"app-window":iW,bell:c$,"brackets-curly":cW,broadcast:mW,camera:CW,cube:xW,devices:qV,door:RW,drop:UW,fan:XW,"game-controller":sj,garage:hj,gear:vj,house:Aj,intersect:Nj,lamp:Vj,lightbulb:jj,lightning:Qj,lock:aK,plugs:fK,pulse:jR,"puzzle-piece":zT,rows:yK,shield:LK,sliders:PK,snowflake:ZK,"speaker-hifi":qK,"speaker-high":tq,television:lq,terminal:_q,thermometer:Sq,"thermometer-hot":$q,"toggle-right":Iq,wind:zq})}const Wq={key:0,class:"pcf-section"},jq={class:"pcf-section-label"},Kq={class:"pcf-section-body"},qq={key:1,class:"pcf-row pcf-row--switch"},Gq={class:"pcf-label-wrap"},Yq={class:"pcf-label"},Xq={key:0,class:"pcf-required"},Jq={key:0,class:"pcf-hint"},Qq={key:2,class:"pcf-row"},eG={class:"pcf-label"},tG={key:0,class:"pcf-required"},iG={class:"pcf-control"},rG={key:0,class:"pcf-hint"},sG={key:3,class:"pcf-row pcf-row--array"},nG={class:"pcf-label"},aG={key:0,class:"pcf-required"},oG={class:"pcf-control"},lG={class:"pcf-array"},cG={key:0,class:"pcf-hint"},uG={key:4,class:"pcf-row"},hG={class:"pcf-label"},dG={key:0,class:"pcf-required"},fG={class:"pcf-control"},pG={key:0,class:"pcf-hint"},_G={key:5,class:"pcf-row"},mG={class:"pcf-label"},gG={key:0,class:"pcf-required"},vG={class:"pcf-control"},bG={key:0,class:"pcf-hint"},yG=Re({__name:"PluginConfigField",props:{fieldKey:{},field:{},path:{},required:{type:Boolean},value:{}},emits:["change","addArray","removeArray","updateArray"],setup(e,{emit:t}){const i=e,r=t;function s(){return Array.isArray(i.field.type)?i.field.type[0]:i.field.type??"string"}function n(){return i.field.title??i.fieldKey.replace(/([A-Z])/g," $1").replace(/^./,h=>h.toUpperCase())}function a(){return(i.field.enum??[]).map((h,d)=>{var f;return{value:h,label:((f=i.field.enumNames)==null?void 0:f[d])??String(h)}})}function o(){return i.value??i.field.default??""}function l(h){const d=i.value;return d==null?void 0:d[h]}function c(h,d){const f=typeof i.value=="object"&&i.value!==null?{...i.value}:{};f[h]=d,r("change",f)}function u(){return Array.isArray(i.value)?i.value:[]}return(h,d)=>{const f=qo("PluginConfigField",!0),m=Sc,_=Cc,y=ha,p=oi;return s()==="object"&&e.field.properties?(g(),E("div",Wq,[b("div",jq,Z(n()),1),b("div",Kq,[(g(!0),E(we,null,Be(e.field.properties,(C,w)=>{var v;return g(),de(f,{key:w,"field-key":String(w),field:C,path:[...e.path,String(w)],required:((v=e.field.required)==null?void 0:v.includes(String(w)))??!1,value:l(String(w)),onChange:k=>c(String(w),k),onAddArray:d[0]||(d[0]=(k,$)=>r("addArray",k,$)),onRemoveArray:d[1]||(d[1]=(k,$)=>r("removeArray",k,$)),onUpdateArray:d[2]||(d[2]=(k,$,M)=>r("updateArray",k,$,M))},null,8,["field-key","field","path","required","value","onChange"])}),128))])])):s()==="boolean"?(g(),E("div",qq,[b("div",Gq,[b("span",Yq,[ce(Z(n())+" ",1),e.required?(g(),E("span",Xq,"*")):F("",!0)]),e.field.description?(g(),E("span",Jq,Z(e.field.description),1)):F("",!0)]),Y(m,{"model-value":!!(e.value??e.field.default??!1),name:`pcf-${e.path.join("-")}`,size:"sm",variant:"primary","onUpdate:modelValue":d[3]||(d[3]=C=>r("change",C))},null,8,["model-value","name"])])):e.field.enum?(g(),E("div",Qq,[b("label",eG,[ce(Z(n())+" ",1),e.required?(g(),E("span",tG,"*")):F("",!0)]),b("div",iG,[Y(_,{"model-value":o(),options:a(),size:"sm","onUpdate:modelValue":d[4]||(d[4]=C=>r("change",C))},null,8,["model-value","options"]),e.field.description?(g(),E("span",rG,Z(e.field.description),1)):F("",!0)])])):s()==="array"?(g(),E("div",sG,[b("label",nG,[ce(Z(n())+" ",1),e.required?(g(),E("span",aG,"*")):F("",!0)]),b("div",oG,[b("div",lG,[(g(!0),E(we,null,Be(u(),(C,w)=>(g(),E("div",{key:w,class:"pcf-array-row"},[Y(y,{"model-value":String(C),size:"sm",placeholder:`${n()} ${w+1}`,style:{flex:"1"},"onUpdate:modelValue":v=>r("updateArray",e.path,w,v)},null,8,["model-value","placeholder","onUpdate:modelValue"]),Y(p,{variant:"ghost",size:"sm",icon:$d,"aria-label":`Remove ${n()} ${w+1}`,onClick:v=>r("removeArray",e.path,w)},null,8,["aria-label","onClick"])]))),128)),Y(p,{variant:"ghost",size:"sm",icon:wA,onClick:d[5]||(d[5]=C=>r("addArray",e.path,e.field.items??{type:"string"}))},{default:ee(()=>[...d[8]||(d[8]=[ce(" Add ",-1)])]),_:1})]),e.field.description?(g(),E("span",cG,Z(e.field.description),1)):F("",!0)])])):s()==="number"||s()==="integer"?(g(),E("div",uG,[b("label",hG,[ce(Z(n())+" ",1),e.required?(g(),E("span",dG,"*")):F("",!0)]),b("div",fG,[Y(y,{"model-value":e.value!==void 0?String(e.value):e.field.default!==void 0?String(e.field.default):"",type:"number",size:"sm",placeholder:e.field.default!==void 0?String(e.field.default):"",style:{"max-width":"180px"},"onUpdate:modelValue":d[6]||(d[6]=C=>r("change",Number(C)))},null,8,["model-value","placeholder"]),e.field.description?(g(),E("span",pG,Z(e.field.description),1)):F("",!0)])])):(g(),E("div",_G,[b("label",mG,[ce(Z(n())+" ",1),e.required?(g(),E("span",gG,"*")):F("",!0)]),b("div",vG,[Y(y,{"model-value":e.value!==void 0?String(e.value):e.field.default!==void 0?String(e.field.default):"",size:"sm",placeholder:e.field.default!==void 0?String(e.field.default):"","onUpdate:modelValue":d[7]||(d[7]=C=>r("change",C))},null,8,["model-value","placeholder"]),e.field.description?(g(),E("span",bG,Z(e.field.description),1)):F("",!0)])]))}}}),wG=jt(yG,[["__scopeId","data-v-79b9818f"]]);cx({storageKey:"openbridge.theme"});fx({themes:["openbridge"],defaultTheme:"openbridge"});const oo=_m(wx);oo.use(Eb());oo.use(Zv);oo.use(C7({legacy:!1,locale:navigator.language,fallbackLocale:"en"}));oo.use(Pw);Uq();oo.component("PluginConfigField",wG);oo.mount("#app");
|