diff --git a/orchestrator/src/components/Sidebar.vue b/orchestrator/src/components/Sidebar.vue
index 6c4a86d..99ca33d 100644
--- a/orchestrator/src/components/Sidebar.vue
+++ b/orchestrator/src/components/Sidebar.vue
@@ -37,21 +37,31 @@ async function cargar() {
}
}
-// Clientes y planes solo los necesita el staff para asignarlos; si el endpoint
-// no está disponible (portal del cliente) el formulario sigue funcionando.
+// Los endpoints del panel no comparten una forma de respuesta: el de clientes
+// devuelve el array pelado y el de planes lo envuelve en {items}. Aceptar las
+// dos evita que un select quede vacío sin que nadie se entere.
+function lista(r) {
+ if (Array.isArray(r)) return r
+ return r?.items || r?.registros || []
+}
+
+// Clientes y planes solo los necesita el staff para asignarlos; en el portal
+// del cliente esos endpoints no se alcanzan y el formulario no los muestra.
+// Se cargan por separado a propósito: que falle uno no debe vaciar el otro.
async function cargarAsignables() {
- if (contexto.esPortal) return // endpoints de staff: el cliente no los alcanza
- try {
- const [c, p] = await Promise.all([
- api.get('/app/api/clientes/select'),
- api.get('/app/umind-planes/list'),
- ])
- clientes.value = c.registros || c.items || []
- planes.value = p.items || []
- } catch {
- clientes.value = []
- planes.value = []
- }
+ if (contexto.esPortal) return
+ const [c, p] = await Promise.allSettled([
+ api.get('/app/api/clientes/select'),
+ api.get('/app/umind-planes/list'),
+ ])
+ clientes.value = c.status === 'fulfilled' ? lista(c.value) : []
+ planes.value = p.status === 'fulfilled' ? lista(p.value) : []
+ // Sin esto un fallo se veía igual que "no hay nada configurado", que es
+ // justo lo que hizo que los campos Cliente y Plan no aparecieran.
+ const fallos = []
+ if (c.status === 'rejected') fallos.push('clientes')
+ if (p.status === 'rejected') fallos.push('planes')
+ if (fallos.length) error.value = `No se pudo cargar la lista de ${fallos.join(' ni ')}.`
}
function nuevoTenant() {
@@ -202,7 +212,7 @@ onMounted(() => {
class="input"
/>
-
+
Cliente
{
— sin asignar —
{{ c.nombre }}
-
Define quién ve este tenant desde el portal.
+
+ {{ clientes.length ? 'Define quién ve este tenant desde el portal.' : 'No hay clientes activos — creá uno en Clientes.' }}
+
Plan
@@ -225,7 +237,9 @@ onMounted(() => {
{{ p.nombre }} ({{ p.max_agentes === 0 ? '∞' : p.max_agentes }} agentes)
-
Límite de agentes y precios de consumo.
+
+ {{ planes.length ? 'Límite de agentes y precios de consumo.' : 'No hay planes — creá uno en uMind Planes.' }}
+
diff --git a/public/orchestrator/assets/index-D9xKBSe-.js b/public/orchestrator/assets/index-D9xKBSe-.js
new file mode 100644
index 0000000..d5c0f3c
--- /dev/null
+++ b/public/orchestrator/assets/index-D9xKBSe-.js
@@ -0,0 +1,26 @@
+(function(){const t=document.createElement("link").relList;if(t&&t.supports&&t.supports("modulepreload"))return;for(const o of document.querySelectorAll('link[rel="modulepreload"]'))s(o);new MutationObserver(o=>{for(const r of o)if(r.type==="childList")for(const i of r.addedNodes)i.tagName==="LINK"&&i.rel==="modulepreload"&&s(i)}).observe(document,{childList:!0,subtree:!0});function n(o){const r={};return o.integrity&&(r.integrity=o.integrity),o.referrerPolicy&&(r.referrerPolicy=o.referrerPolicy),o.crossOrigin==="use-credentials"?r.credentials="include":o.crossOrigin==="anonymous"?r.credentials="omit":r.credentials="same-origin",r}function s(o){if(o.ep)return;o.ep=!0;const r=n(o);fetch(o.href,r)}})();/**
+* @vue/shared v3.5.41
+* (c) 2018-present Yuxi (Evan) You and Vue contributors
+* @license MIT
+**/function qs(e){const t=Object.create(null);for(const n of e.split(","))t[n]=1;return n=>n in t}const he={},Wt=[],pt=()=>{},fr=()=>!1,es=e=>e.charCodeAt(0)===111&&e.charCodeAt(1)===110&&(e.charCodeAt(2)>122||e.charCodeAt(2)<97),ts=e=>e.startsWith("onUpdate:"),ke=Object.assign,Ws=(e,t)=>{const n=e.indexOf(t);n>-1&&e.splice(n,1)},Mi=Object.prototype.hasOwnProperty,ce=(e,t)=>Mi.call(e,t),z=Array.isArray,zt=e=>Tn(e)==="[object Map]",rn=e=>Tn(e)==="[object Set]",go=e=>Tn(e)==="[object Date]",Q=e=>typeof e=="function",xe=e=>typeof e=="string",Qe=e=>typeof e=="symbol",de=e=>e!==null&&typeof e=="object",dr=e=>(de(e)||Q(e))&&Q(e.then)&&Q(e.catch),pr=Object.prototype.toString,Tn=e=>pr.call(e),Vi=e=>Tn(e).slice(8,-1),hr=e=>Tn(e)==="[object Object]",zs=e=>xe(e)&&e!=="NaN"&&e[0]!=="-"&&""+parseInt(e,10)===e,hn=qs(",key,ref,ref_for,ref_key,onVnodeBeforeMount,onVnodeMounted,onVnodeBeforeUpdate,onVnodeUpdated,onVnodeBeforeUnmount,onVnodeUnmounted"),ns=e=>{const t=Object.create(null);return(n=>t[n]||(t[n]=e(n)))},ji=/-\w/g,je=ns(e=>e.replace(ji,t=>t.slice(1).toUpperCase())),Ui=/\B([A-Z])/g,Bt=ns(e=>e.replace(Ui,"-$1").toLowerCase()),ss=ns(e=>e.charAt(0).toUpperCase()+e.slice(1)),gs=ns(e=>e?`on${ss(e)}`:""),ct=(e,t)=>!Object.is(e,t),Hn=(e,...t)=>{for(let n=0;n{Object.defineProperty(e,t,{configurable:!0,enumerable:!1,writable:s,value:n})},os=e=>{const t=parseFloat(e);return isNaN(t)?e:t};let vo;const rs=()=>vo||(vo=typeof globalThis<"u"?globalThis:typeof self<"u"?self:typeof window<"u"?window:typeof global<"u"?global:{});function Zt(e){if(z(e)){const t={};for(let n=0;n{if(n){const s=n.split(Fi);s.length>1&&(t[s[0].trim()]=s[1].trim())}}),t}function Re(e){let t="";if(xe(e))t=e;else if(z(e))for(let n=0;nln(n,t))}const vr=e=>!!(e&&e.__v_isRef===!0),U=e=>xe(e)?e:e==null?"":z(e)||de(e)&&(e.toString===pr||!Q(e.toString))?vr(e)?U(e.value):JSON.stringify(e,br,2):String(e),br=(e,t)=>vr(t)?br(e,t.value):zt(t)?{[`Map(${t.size})`]:[...t.entries()].reduce((n,[s,o],r)=>(n[vs(s,r)+" =>"]=o,n),{})}:rn(t)?{[`Set(${t.size})`]:[...t.values()].map(n=>vs(n))}:Qe(t)?vs(t):de(t)&&!z(t)&&!hr(t)?String(t):t,vs=(e,t="")=>{var n;return Qe(e)?`Symbol(${(n=e.description)!=null?n:t})`:e};/**
+* @vue/reactivity v3.5.41
+* (c) 2018-present Yuxi (Evan) You and Vue contributors
+* @license MIT
+**/let Se;class Wi{constructor(t=!1){this.detached=t,this._active=!0,this._on=0,this.effects=[],this.cleanups=[],this._isPaused=!1,this._warnOnRun=!0,this.__v_skip=!0,!t&&Se&&(Se.active?(this.parent=Se,this.index=(Se.scopes||(Se.scopes=[])).push(this)-1):(this._active=!1,this._warnOnRun=!1))}get active(){return this._active}pause(){if(this._active){this._isPaused=!0;let t,n;if(this.scopes){const s=this.scopes.slice();for(t=0,n=s.length;t0&&--this._on===0){if(Se===this)Se=this.prevScope;else{let t=Se;for(;t;){if(t.prevScope===this){t.prevScope=this.prevScope;break}t=t.prevScope}}this.prevScope=void 0}}stop(t){if(this._active){this._active=!1;let n,s;for(n=0,s=this.effects.length;n0)return;if(gn){let t=gn;for(gn=void 0;t;){const n=t.next;t.next=void 0,t.flags&=-9,t=n}}let e;for(;mn;){let t=mn;for(mn=void 0;t;){const n=t.next;if(t.next=void 0,t.flags&=-9,t.flags&1)try{t.trigger()}catch(s){e||(e=s)}t=n}}if(e)throw e}function wr(e){for(let t=e.deps;t;t=t.nextDep)t.version=-1,t.prevActiveLink=t.dep.activeLink,t.dep.activeLink=t}function Cr(e){let t,n=e.depsTail,s=n;for(;s;){const o=s.prevDep;s.version===-1?(s===n&&(n=o),Xs(s),Ji(s)):t=s,s.dep.activeLink=s.prevActiveLink,s.prevActiveLink=void 0,s=o}e.deps=t,e.depsTail=n}function Ps(e){for(let t=e.deps;t;t=t.nextDep)if(t.dep.version!==t.version||t.dep.computed&&(Er(t.dep.computed)||t.dep.version!==t.version))return!0;return!!e._dirty}function Er(e){if(e.flags&4&&!(e.flags&16)||(e.flags&=-17,e.globalVersion===xn)||(e.globalVersion=xn,!e.isSSR&&e.flags&128&&(!e.deps&&!e._dirty||!Ps(e))))return;e.flags|=2;const t=e.dep,n=me,s=Je;me=e,Je=!0;try{wr(e);const o=e.fn(e._value);(t.version===0||ct(o,e._value))&&(e.flags|=128,e._value=o,t.version++)}catch(o){throw t.version++,o}finally{me=n,Je=s,Cr(e),e.flags&=-3}}function Xs(e,t=!1){const{dep:n,prevSub:s,nextSub:o}=e;if(s&&(s.nextSub=o,e.prevSub=void 0),o&&(o.prevSub=s,e.nextSub=void 0),n.subs===e&&(n.subs=s,!s&&n.computed)){n.computed.flags&=-5;for(let r=n.computed.deps;r;r=r.nextDep)Xs(r,!0)}!t&&!--n.sc&&n.map&&n.map.delete(n.key)}function Ji(e){const{prevDep:t,nextDep:n}=e;t&&(t.nextDep=n,e.prevDep=void 0),n&&(n.prevDep=t,e.nextDep=void 0)}let Je=!0;const Sr=[];function St(){Sr.push(Je),Je=!1}function At(){const e=Sr.pop();Je=e===void 0?!0:e}function bo(e){const{cleanup:t}=e;if(e.cleanup=void 0,t){const n=me;me=void 0;try{t()}finally{me=n}}}let xn=0;class Yi{constructor(t,n){this.sub=t,this.dep=n,this.version=n.version,this.nextDep=this.prevDep=this.nextSub=this.prevSub=this.prevActiveLink=void 0}}class Zs{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(!me||!Je||me===this.computed)return;let n=this.activeLink;if(n===void 0||n.sub!==me)n=this.activeLink=new Yi(me,this),me.deps?(n.prevDep=me.depsTail,me.depsTail.nextDep=n,me.depsTail=n):me.deps=me.depsTail=n,Ar(n);else if(n.version===-1&&(n.version=this.version,n.nextDep)){const s=n.nextDep;s.prevDep=n.prevDep,n.prevDep&&(n.prevDep.nextDep=s),n.prevDep=me.depsTail,n.nextDep=void 0,me.depsTail.nextDep=n,me.depsTail=n,me.deps===n&&(me.deps=s)}return n}trigger(t){this.version++,xn++,this.notify(t)}notify(t){Ys();try{for(let n=this.subs;n;n=n.prevSub)n.sub.notify()&&n.sub.dep.notify()}finally{Qs()}}}function Ar(e){if(e.dep.sc++,e.sub.flags&4){const t=e.dep.computed;if(t&&!e.dep.subs){t.flags|=20;for(let s=t.deps;s;s=s.nextDep)Ar(s)}const n=e.dep.subs;n!==e&&(e.prevSub=n,n&&(n.nextSub=e)),e.dep.subs=e}}const Ns=new WeakMap,Ft=Symbol(""),$s=Symbol(""),yn=Symbol("");function Te(e,t,n){if(Je&&me){let s=Ns.get(e);s||Ns.set(e,s=new Map);let o=s.get(n);o||(s.set(n,o=new Zs),o.map=s,o.key=n),o.track()}}function wt(e,t,n,s,o,r){const i=Ns.get(e);if(!i){xn++;return}const l=a=>{a&&a.trigger()};if(Ys(),t==="clear")i.forEach(l);else{const a=z(e),d=a&&zs(n);if(a&&n==="length"){const c=Number(s);i.forEach((h,v)=>{(v==="length"||v===yn||!Qe(v)&&v>=c)&&l(h)})}else switch((n!==void 0||i.has(void 0))&&l(i.get(n)),d&&l(i.get(yn)),t){case"add":a?d&&l(i.get("length")):(l(i.get(Ft)),zt(e)&&l(i.get($s)));break;case"delete":a||(l(i.get(Ft)),zt(e)&&l(i.get($s)));break;case"set":zt(e)&&l(i.get(Ft));break}}Qs()}function Kt(e){const t=ue(e);return t===e?t:(Te(t,"iterate",yn),ze(e)?t:t.map(Xe))}function is(e){return Te(e=ue(e),"iterate",yn),e}function lt(e,t){return Rt(e)?en(Ht(e)?Xe(t):t):Xe(t)}const Qi={__proto__:null,[Symbol.iterator](){return _s(this,Symbol.iterator,e=>lt(this,e))},concat(...e){return Kt(this).concat(...e.map(t=>z(t)?Kt(t):t))},entries(){return _s(this,"entries",e=>(e[1]=lt(this,e[1]),e))},every(e,t){return bt(this,"every",e,t,void 0,arguments)},filter(e,t){return bt(this,"filter",e,t,n=>n.map(s=>lt(this,s)),arguments)},find(e,t){return bt(this,"find",e,t,n=>lt(this,n),arguments)},findIndex(e,t){return bt(this,"findIndex",e,t,void 0,arguments)},findLast(e,t){return bt(this,"findLast",e,t,n=>lt(this,n),arguments)},findLastIndex(e,t){return bt(this,"findLastIndex",e,t,void 0,arguments)},forEach(e,t){return bt(this,"forEach",e,t,void 0,arguments)},includes(...e){return xs(this,"includes",e)},indexOf(...e){return xs(this,"indexOf",e)},join(e){return Kt(this).join(e)},lastIndexOf(...e){return xs(this,"lastIndexOf",e)},map(e,t){return bt(this,"map",e,t,void 0,arguments)},pop(){return un(this,"pop")},push(...e){return un(this,"push",e)},reduce(e,...t){return _o(this,"reduce",e,t)},reduceRight(e,...t){return _o(this,"reduceRight",e,t)},shift(){return un(this,"shift")},some(e,t){return bt(this,"some",e,t,void 0,arguments)},splice(...e){return un(this,"splice",e)},toReversed(){return Kt(this).toReversed()},toSorted(e){return Kt(this).toSorted(e)},toSpliced(...e){return Kt(this).toSpliced(...e)},unshift(...e){return un(this,"unshift",e)},values(){return _s(this,"values",e=>lt(this,e))}};function _s(e,t,n){const s=is(e),o=s[t]();return s!==e&&!ze(e)&&(o._next=o.next,o.next=()=>{const r=o._next();return r.done||(r.value=n(r.value)),r}),o}const Xi=Array.prototype;function bt(e,t,n,s,o,r){const i=is(e),l=i!==e&&!ze(e),a=i[t];if(a!==Xi[t]){const h=a.apply(e,r);return l?Xe(h):h}let d=n;i!==e&&(l?d=function(h,v){return n.call(this,lt(e,h),v,e)}:n.length>2&&(d=function(h,v){return n.call(this,h,v,e)}));const c=a.call(i,d,s);return l&&o?o(c):c}function _o(e,t,n,s){const o=is(e),r=o!==e&&!ze(e);let i=n,l=!1;o!==e&&(r?(l=s.length===0,i=function(d,c,h){return l&&(l=!1,d=lt(e,d)),n.call(this,d,lt(e,c),h,e)}):n.length>3&&(i=function(d,c,h){return n.call(this,d,c,h,e)}));const a=o[t](i,...s);return l?lt(e,a):a}function xs(e,t,n){const s=ue(e);Te(s,"iterate",yn);const o=s[t](...n);return(o===-1||o===!1)&&no(n[0])?(n[0]=ue(n[0]),s[t](...n)):o}function un(e,t,n=[]){St(),Ys();const s=ue(e)[t].apply(e,n);return Qs(),At(),s}const Zi=qs("__proto__,__v_isRef,__isVue"),Rr=new Set(Object.getOwnPropertyNames(Symbol).filter(e=>e!=="arguments"&&e!=="caller").map(e=>Symbol[e]).filter(Qe));function el(e){Qe(e)||(e=String(e));const t=ue(this);return Te(t,"has",e),t.hasOwnProperty(e)}class Ir{constructor(t=!1,n=!1){this._isReadonly=t,this._isShallow=n}get(t,n,s){if(n==="__v_skip")return t.__v_skip;const o=this._isReadonly,r=this._isShallow;if(n==="__v_isReactive")return!o;if(n==="__v_isReadonly")return o;if(n==="__v_isShallow")return r;if(n==="__v_raw")return s===(o?r?cl:Pr:r?Tr:Or).get(t)||Object.getPrototypeOf(t)===Object.getPrototypeOf(s)?t:void 0;const i=z(t);if(!o){let a;if(i&&(a=Qi[n]))return a;if(n==="hasOwnProperty")return el}const l=Reflect.get(t,n,$e(t)?t:s);if((Qe(n)?Rr.has(n):Zi(n))||(o||Te(t,"get",n),r))return l;if($e(l)){const a=i&&zs(n)?l:l.value;return o&&de(a)?Ms(a):a}return de(l)?o?Ms(l):ls(l):l}}class kr extends Ir{constructor(t=!1){super(!1,t)}set(t,n,s,o){let r=t[n];const i=z(t)&&zs(n);if(!this._isShallow){const d=Rt(r);if(!ze(s)&&!Rt(s)&&(r=ue(r),s=ue(s)),!i&&$e(r)&&!$e(s))return d||(r.value=s),!0}const l=i?Number(n)e,Mn=e=>Reflect.getPrototypeOf(e);function rl(e,t,n){return function(...s){const o=this.__v_raw,r=ue(o),i=zt(r),l=e==="entries"||e===Symbol.iterator&&i,a=e==="keys"&&i,d=o[e](...s),c=n?Ds:t?en:Xe;return!t&&Te(r,"iterate",a?$s:Ft),ke(Object.create(d),{next(){const{value:h,done:v}=d.next();return v?{value:h,done:v}:{value:l?[c(h[0]),c(h[1])]:c(h),done:v}}})}}function Vn(e){return function(...t){return e==="delete"?!1:e==="clear"?void 0:this}}function il(e,t){const n={get(o){const r=this.__v_raw,i=ue(r),l=ue(o);e||(ct(o,l)&&Te(i,"get",o),Te(i,"get",l));const{has:a}=Mn(i),d=t?Ds:e?en:Xe;if(a.call(i,o))return d(r.get(o));if(a.call(i,l))return d(r.get(l));r!==i&&r.get(o)},get size(){const o=this.__v_raw;return!e&&Te(ue(o),"iterate",Ft),o.size},has(o){const r=this.__v_raw,i=ue(r),l=ue(o);return e||(ct(o,l)&&Te(i,"has",o),Te(i,"has",l)),o===l?r.has(o):r.has(o)||r.has(l)},forEach(o,r){const i=this,l=i.__v_raw,a=ue(l),d=t?Ds:e?en:Xe;return!e&&Te(a,"iterate",Ft),l.forEach((c,h)=>o.call(r,d(c),d(h),i))}};return ke(n,e?{add:Vn("add"),set:Vn("set"),delete:Vn("delete"),clear:Vn("clear")}:{add(o){const r=ue(this),i=Mn(r),l=ue(o),a=!t&&!ze(o)&&!Rt(o)?l:o;return i.has.call(r,a)||ct(o,a)&&i.has.call(r,o)||ct(l,a)&&i.has.call(r,l)||(r.add(a),wt(r,"add",a,a)),this},set(o,r){!t&&!ze(r)&&!Rt(r)&&(r=ue(r));const i=ue(this),{has:l,get:a}=Mn(i);let d=l.call(i,o);d||(o=ue(o),d=l.call(i,o));const c=a.call(i,o);return i.set(o,r),d?ct(r,c)&&wt(i,"set",o,r):wt(i,"add",o,r),this},delete(o){const r=ue(this),{has:i,get:l}=Mn(r);let a=i.call(r,o);a||(o=ue(o),a=i.call(r,o)),l&&l.call(r,o);const d=r.delete(o);return a&&wt(r,"delete",o,void 0),d},clear(){const o=ue(this),r=o.size!==0,i=o.clear();return r&&wt(o,"clear",void 0,void 0),i}}),["keys","values","entries",Symbol.iterator].forEach(o=>{n[o]=rl(o,e,t)}),n}function eo(e,t){const n=il(e,t);return(s,o,r)=>o==="__v_isReactive"?!e:o==="__v_isReadonly"?e:o==="__v_raw"?s:Reflect.get(ce(n,o)&&o in s?n:s,o,r)}const ll={get:eo(!1,!1)},al={get:eo(!1,!0)},ul={get:eo(!0,!1)};const Or=new WeakMap,Tr=new WeakMap,Pr=new WeakMap,cl=new WeakMap;function fl(e){switch(e){case"Object":case"Array":return 1;case"Map":case"Set":case"WeakMap":case"WeakSet":return 2;default:return 0}}function ls(e){return Rt(e)?e:to(e,!1,nl,ll,Or)}function Nr(e){return to(e,!1,ol,al,Tr)}function Ms(e){return to(e,!0,sl,ul,Pr)}function to(e,t,n,s,o){if(!de(e)||e.__v_raw&&!(t&&e.__v_isReactive)||e.__v_skip||!Object.isExtensible(e))return e;const r=o.get(e);if(r)return r;const i=fl(Vi(e));if(i===0)return e;const l=new Proxy(e,i===2?s:n);return o.set(e,l),l}function Ht(e){return Rt(e)?Ht(e.__v_raw):!!(e&&e.__v_isReactive)}function Rt(e){return!!(e&&e.__v_isReadonly)}function ze(e){return!!(e&&e.__v_isShallow)}function no(e){return e?!!e.__v_raw:!1}function ue(e){const t=e&&e.__v_raw;return t?ue(t):e}function dl(e){return!ce(e,"__v_skip")&&Object.isExtensible(e)&&mr(e,"__v_skip",!0),e}const Xe=e=>de(e)?ls(e):e,en=e=>de(e)?Ms(e):e;function $e(e){return e?e.__v_isRef===!0:!1}function J(e){return $r(e,!1)}function pl(e){return $r(e,!0)}function $r(e,t){return $e(e)?e:new hl(e,t)}class hl{constructor(t,n){this.dep=new Zs,this.__v_isRef=!0,this.__v_isShallow=!1,this._rawValue=n?t:ue(t),this._value=n?t:Xe(t),this.__v_isShallow=n}get value(){return this.dep.track(),this._value}set value(t){const n=this._rawValue,s=this.__v_isShallow||ze(t)||Rt(t);t=s?t:ue(t),ct(t,n)&&(this._rawValue=t,this._value=s?t:Xe(t),this.dep.trigger())}}function Ne(e){return $e(e)?e.value:e}const ml={get:(e,t,n)=>t==="__v_raw"?e:Ne(Reflect.get(e,t,n)),set:(e,t,n,s)=>{const o=e[t];return $e(o)&&!$e(n)?(o.value=n,!0):Reflect.set(e,t,n,s)}};function Dr(e){return Ht(e)?e:new Proxy(e,ml)}class gl{constructor(t,n,s){this.fn=t,this.setter=n,this._value=void 0,this.dep=new Zs(this),this.__v_isRef=!0,this.deps=void 0,this.depsTail=void 0,this.flags=16,this.globalVersion=xn-1,this.next=void 0,this.effect=this,this.__v_isReadonly=!n,this.isSSR=s}notify(){if(this.flags|=16,!(this.flags&8)&&me!==this)return yr(this,!0),!0}get value(){const t=this.dep.track();return Er(this),t&&(t.version=this.dep.version),this._value}set value(t){this.setter&&this.setter(t)}}function vl(e,t,n=!1){let s,o;return Q(e)?s=e:(s=e.get,o=e.set),new gl(s,o,n)}const jn={},qn=new WeakMap;let jt;function bl(e,t=!1,n=jt){if(n){let s=qn.get(n);s||qn.set(n,s=[]),s.push(e)}}function _l(e,t,n=he){const{immediate:s,deep:o,once:r,scheduler:i,augmentJob:l,call:a}=n,d=x=>o?x:ze(x)||o===!1||o===0?Ct(x,1):Ct(x);let c,h,v,_,j=!1,P=!1;if($e(e)?(h=()=>e.value,j=ze(e)):Ht(e)?(h=()=>d(e),j=!0):z(e)?(P=!0,j=e.some(x=>Ht(x)||ze(x)),h=()=>e.map(x=>{if($e(x))return x.value;if(Ht(x))return d(x);if(Q(x))return a?a(x,2):x()})):Q(e)?t?h=a?()=>a(e,2):e:h=()=>{if(v){St();try{v()}finally{At()}}const x=jt;jt=c;try{return a?a(e,3,[_]):e(_)}finally{jt=x}}:h=pt,t&&o){const x=h,R=o===!0?1/0:o;h=()=>Ct(x(),R)}const K=zi(),V=()=>{c.stop(),K&&K.active&&Ws(K.effects,c)};if(r&&t){const x=t;t=(...R)=>{const M=x(...R);return V(),M}}let C=P?new Array(e.length).fill(jn):jn;const H=x=>{if(!(!(c.flags&1)||!c.dirty&&!x))if(t){const R=c.run();if(x||o||j||(P?R.some((M,Y)=>ct(M,C[Y])):ct(R,C))){v&&v();const M=jt;jt=c;try{const Y=[R,C===jn?void 0:P&&C[0]===jn?[]:C,_];C=R,a?a(t,3,Y):t(...Y)}finally{jt=M}}}else c.run()};return l&&l(H),c=new _r(h),c.scheduler=i?()=>i(H,!1):H,_=x=>bl(x,!1,c),v=c.onStop=()=>{const x=qn.get(c);if(x){if(a)a(x,4);else for(const R of x)R();qn.delete(c)}},t?s?H(!0):C=c.run():i?i(H.bind(null,!0),!0):c.run(),V.pause=c.pause.bind(c),V.resume=c.resume.bind(c),V.stop=V,V}function Ct(e,t=1/0,n){if(t<=0||!de(e)||e.__v_skip||(n=n||new Map,(n.get(e)||0)>=t))return e;if(n.set(e,t),t--,$e(e))Ct(e.value,t,n);else if(z(e))for(let s=0;s{Ct(s,t,n)});else if(hr(e)){for(const s in e)Ct(e[s],t,n);for(const s of Object.getOwnPropertySymbols(e))Object.prototype.propertyIsEnumerable.call(e,s)&&Ct(e[s],t,n)}return e}/**
+* @vue/runtime-core v3.5.41
+* (c) 2018-present Yuxi (Evan) You and Vue contributors
+* @license MIT
+**/function Pn(e,t,n,s){try{return s?e(...s):e()}catch(o){as(o,t,n)}}function Ze(e,t,n,s){if(Q(e)){const o=Pn(e,t,n,s);return o&&dr(o)&&o.catch(r=>{as(r,t,n)}),o}if(z(e)){const o=[];for(let r=0;r>>1,o=Ve[s],r=wn(o);r=wn(n)?Ve.push(e):Ve.splice(yl(t),0,e),e.flags|=1,Vr()}}function Vr(){Wn||(Wn=Mr.then(Ur))}function wl(e){if(!z(e))Tt&&e.id===-1?Tt.splice(Gt+1,0,e):e.flags&1||(Jt.push(e),e.flags|=1);else for(let t=0;twn(n)-wn(s));if(Jt.length=0,Tt){for(let n=0;ne.id==null?e.flags&2?-1:1/0:e.id;function Ur(e){try{for(it=0;it{s._d&&Qn(-1);const r=zn(t),i=Et.length;let l;try{l=e(...o)}finally{for(let a=Et.length;a>i;a--)uo();zn(r),s._d&&Qn(1)}return l};return s._n=!0,s._c=!0,s._d=!0,s}function se(e,t){if(Ie===null)return e;const n=ps(Ie),s=e.dirs||(e.dirs=[]);for(let o=0;o1)return n&&Q(t)?t.call(s&&s.proxy):t}}const Cl=Symbol.for("v-scx"),El=()=>Ye(Cl);function Kn(e,t,n){return Fr(e,t,n)}function Fr(e,t,n=he){const{immediate:s,deep:o,flush:r,once:i}=n,l=ke({},n),a=t&&s||!t&&r!=="post";let d;if(Rn){if(r==="sync"){const _=El();d=_.__watcherHandles||(_.__watcherHandles=[])}else if(!a){const _=()=>{};return _.stop=pt,_.resume=pt,_.pause=pt,_}}const c=Pe;l.call=(_,j,P)=>Ze(_,c,j,P);let h=!1;r==="post"?l.scheduler=_=>{Fe(_,c&&c.suspense)}:r!=="sync"&&(h=!0,l.scheduler=(_,j)=>{j?_():oo(_)}),l.augmentJob=_=>{t&&(_.flags|=4),h&&(_.flags|=2,c&&(_.id=c.uid,_.i=c))};const v=_l(e,t,l);return Rn&&(d?d.push(v):a&&v()),v}function Sl(e,t,n){const s=this.proxy,o=xe(e)?e.includes(".")?Hr(s,e):()=>s[e]:e.bind(s,s);let r;Q(t)?r=t:(r=t.handler,n=t);const i=Dn(this),l=Fr(o,r.bind(s),n);return i(),l}function Hr(e,t){const n=t.split(".");return()=>{let s=e;for(let o=0;oe.__isTeleport,ys=Symbol("_leaveCb");function Rl(e){let t=e[0];if(e.length>1){for(const n of e)if(n.type!==ht){t=n;break}}return t}function Br(e){if(!io(e))return us(e.type)&&e.children?Rl(e.children):e;if(e.component)return e.component.subTree;const{shapeFlag:t,children:n}=e;if(n){if(t&16)return n[0];if(t&32&&Q(n.default))return n.default()}}function ro(e,t){if(e.shapeFlag&6&&e.component){e.transition=t;const n=e.component.subTree;ro(us(n.type)&&Br(n)||n,t)}else e.shapeFlag&128?(e.ssContent.transition=t.clone(e.ssContent),e.ssFallback.transition=t.clone(e.ssFallback)):e.transition=t}function Kr(e,t){return Q(e)?ke({name:e.name},t,{setup:e}):e}function Gr(e){e.ids=[e.ids[0]+e.ids[2]+++"-",0,0]}function yo(e,t){let n;return!!((n=Object.getOwnPropertyDescriptor(e,t))&&!n.configurable)}const Jn=new WeakMap;function vn(e,t,n,s,o=!1){if(z(e)){e.forEach((P,K)=>vn(P,t&&(z(t)?t[K]:t),n,s,o));return}if(Yt(s)&&!o){s.shapeFlag&512&&s.type.__asyncResolved&&s.component.subTree.component&&vn(e,t,n,s.component.subTree);return}const r=s.shapeFlag&4?ps(s.component):s.el,i=o?null:r,{i:l,r:a}=e,d=t&&t.r,c=l.refs===he?l.refs={}:l.refs,h=l.setupState,v=ue(h),_=h===he?fr:P=>yo(c,P)?!1:ce(v,P),j=(P,K)=>!(K&&yo(c,K));if(d!=null&&d!==a){if(wo(t),xe(d))c[d]=null,_(d)&&(h[d]=null);else if($e(d)){const P=t;j(d,P.k)&&(d.value=null),P.k&&(c[P.k]=null)}}if(Q(a))Pn(a,l,12,[i,c]);else{const P=xe(a),K=$e(a);if(P||K){const V=()=>{if(e.f){const C=P?_(a)?h[a]:c[a]:j()||!e.k?a.value:c[e.k];if(o)z(C)&&Ws(C,r);else if(z(C))C.includes(r)||C.push(r);else if(P)c[a]=[r],_(a)&&(h[a]=c[a]);else{const H=[r];j(a,e.k)&&(a.value=H),e.k&&(c[e.k]=H)}}else P?(c[a]=i,_(a)&&(h[a]=i)):K&&(j(a,e.k)&&(a.value=i),e.k&&(c[e.k]=i))};if(i){const C=()=>{V(),Jn.delete(e)};C.id=-1,Jn.set(e,C),Fe(C,n)}else wo(e),V()}}}function wo(e){const t=Jn.get(e);t&&(t.flags|=8,Jn.delete(e))}rs().requestIdleCallback;rs().cancelIdleCallback;const Yt=e=>!!e.type.__asyncLoader,io=e=>e.type.__isKeepAlive;function Il(e,t){qr(e,"a",t)}function kl(e,t){qr(e,"da",t)}function qr(e,t,n=Pe){const s=e.__wdc||(e.__wdc=()=>{let o=n;for(;o;){if(o.isDeactivated)return;o=o.parent}return e()});if(cs(t,s,n),n){let o=n.parent;for(;o&&o.parent;)io(o.parent.vnode)&&Ol(s,t,n,o),o=o.parent}}function Ol(e,t,n,s){const o=cs(t,e,s,!0);Wr(()=>{Ws(s[t],o)},n)}function cs(e,t,n=Pe,s=!1){if(n){const o=n[e]||(n[e]=[]),r=t.__weh||(t.__weh=(...i)=>{St();const l=Dn(n),a=Ze(t,n,e,i);return l(),At(),a});return s?o.unshift(r):o.push(r),r}}const It=e=>(t,n=Pe)=>{(!Rn||e==="sp")&&cs(e,(...s)=>t(...s),n)},Tl=It("bm"),Nn=It("m"),Pl=It("bu"),Nl=It("u"),$l=It("bum"),Wr=It("um"),Dl=It("sp"),Ml=It("rtg"),Vl=It("rtc");function jl(e,t=Pe){cs("ec",e,t)}const Ul="components";function $n(e,t){return Fl(Ul,e,!0,t)||e}const Ll=Symbol.for("v-ndc");function Fl(e,t,n=!0,s=!1){const o=Ie||Pe;if(o){const r=o.type;{const l=Aa(r,!1);if(l&&(l===t||l===je(t)||l===ss(je(t))))return r}const i=Co(o[e]||r[e],t)||Co(o.appContext[e],t);return!i&&s?r:i}}function Co(e,t){return e&&(e[t]||e[je(t)]||e[ss(je(t))])}function Ae(e,t,n,s){let o;const r=n,i=z(e);if(i||xe(e)){const l=i&&Ht(e);let a=!1,d=!1;l&&(a=!ze(e),d=Rt(e),e=is(e)),o=new Array(e.length);for(let c=0,h=e.length;ct(l,a,void 0,r));else{const l=Object.keys(e);o=new Array(l.length);for(let a=0,d=l.length;a0;return O(),En(le,null,[be("slot",d,s)],c?-2:64)}let i=e[t];i&&i._c&&(i._d=!1);const l=Et.length;O();let a;try{const d=i&&zr(i(n)),c=n.key||r||d&&d.key;a=En(le,{key:(c&&!Qe(c)?c:`_${t}`)+(!d&&s?"_fb":"")},d||(s?s():[]),d&&e._===1?64:-2)}catch(d){for(let c=Et.length;c>l;c--)uo();throw d}finally{i&&i._c&&(i._d=!0)}return a.scopeId&&(a.slotScopeIds=[a.scopeId+"-s"]),a}function zr(e){return e.some(t=>Sn(t)?!(t.type===ht||t.type===le&&!zr(t.children)):!0)?e:null}const Vs=e=>e?hi(e)?ps(e):Vs(e.parent):null,bn=ke(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=>Vs(e.parent),$root:e=>Vs(e.root),$host:e=>e.ce,$emit:e=>e.emit,$options:e=>Yr(e),$forceUpdate:e=>e.f||(e.f=()=>{oo(e.update)}),$nextTick:e=>e.n||(e.n=so.bind(e.proxy)),$watch:e=>Sl.bind(e)}),ws=(e,t)=>e!==he&&!e.__isScriptSetup&&ce(e,t),Bl={get({_:e},t){if(t==="__v_skip")return!0;const{ctx:n,setupState:s,data:o,props:r,accessCache:i,type:l,appContext:a}=e;if(t[0]!=="$"){const v=i[t];if(v!==void 0)switch(v){case 1:return s[t];case 2:return o[t];case 4:return n[t];case 3:return r[t]}else{if(ws(s,t))return i[t]=1,s[t];if(o!==he&&ce(o,t))return i[t]=2,o[t];if(ce(r,t))return i[t]=3,r[t];if(n!==he&&ce(n,t))return i[t]=4,n[t];js&&(i[t]=0)}}const d=bn[t];let c,h;if(d)return t==="$attrs"&&Te(e.attrs,"get",""),d(e);if((c=l.__cssModules)&&(c=c[t]))return c;if(n!==he&&ce(n,t))return i[t]=4,n[t];if(h=a.config.globalProperties,ce(h,t))return h[t]},set({_:e},t,n){const{data:s,setupState:o,ctx:r}=e;return ws(o,t)?(o[t]=n,!0):s!==he&&ce(s,t)?(s[t]=n,!0):ce(e.props,t)||t[0]==="$"&&t.slice(1)in e?!1:(r[t]=n,!0)},has({_:{data:e,setupState:t,accessCache:n,ctx:s,appContext:o,props:r,type:i}},l){let a;return!!(n[l]||e!==he&&l[0]!=="$"&&ce(e,l)||ws(t,l)||ce(r,l)||ce(s,l)||ce(bn,l)||ce(o.config.globalProperties,l)||(a=i.__cssModules)&&a[l])},defineProperty(e,t,n){return n.get!=null?e._.accessCache[t]=0:ce(n,"value")&&this.set(e,t,n.value,null),Reflect.defineProperty(e,t,n)}};function Eo(e){return z(e)?e.reduce((t,n)=>(t[n]=null,t),{}):e}let js=!0;function Kl(e){const t=Yr(e),n=e.proxy,s=e.ctx;js=!1,t.beforeCreate&&So(t.beforeCreate,e,"bc");const{data:o,computed:r,methods:i,watch:l,provide:a,inject:d,created:c,beforeMount:h,mounted:v,beforeUpdate:_,updated:j,activated:P,deactivated:K,beforeDestroy:V,beforeUnmount:C,destroyed:H,unmounted:x,render:R,renderTracked:M,renderTriggered:Y,errorCaptured:k,serverPrefetch:ye,expose:Ue,inheritAttrs:tt,components:mt,directives:We,filters:Dt}=t;if(d&&Gl(d,s,null),i)for(const re in i){const te=i[re];Q(te)&&(s[re]=te.bind(n))}if(o){const re=o.call(n,n);de(re)&&(e.data=ls(re))}if(js=!0,r)for(const re in r){const te=r[re],ee=Q(te)?te.bind(n,n):Q(te.get)?te.get.bind(n,n):pt,He=!Q(te)&&Q(te.set)?te.set.bind(n):pt,Be=ve({get:ee,set:He});Object.defineProperty(s,re,{enumerable:!0,configurable:!0,get:()=>Be.value,set:Oe=>Be.value=Oe})}if(l)for(const re in l)Jr(l[re],s,n,re);if(a){const re=Q(a)?a.call(n):a;Reflect.ownKeys(re).forEach(te=>{Bn(te,re[te])})}c&&So(c,e,"c");function we(re,te){z(te)?te.forEach(ee=>re(ee.bind(n))):te&&re(te.bind(n))}if(we(Tl,h),we(Nn,v),we(Pl,_),we(Nl,j),we(Il,P),we(kl,K),we(jl,k),we(Vl,M),we(Ml,Y),we($l,C),we(Wr,x),we(Dl,ye),z(Ue))if(Ue.length){const re=e.exposed||(e.exposed={});Ue.forEach(te=>{Object.defineProperty(re,te,{get:()=>n[te],set:ee=>n[te]=ee,enumerable:!0})})}else e.exposed||(e.exposed={});R&&e.render===pt&&(e.render=R),tt!=null&&(e.inheritAttrs=tt),mt&&(e.components=mt),We&&(e.directives=We),ye&&Gr(e)}function Gl(e,t,n=pt){z(e)&&(e=Us(e));for(const s in e){const o=e[s];let r;de(o)?"default"in o?r=Ye(o.from||s,o.default,!0):r=Ye(o.from||s):r=Ye(o),$e(r)?Object.defineProperty(t,s,{enumerable:!0,configurable:!0,get:()=>r.value,set:i=>r.value=i}):t[s]=r}}function So(e,t,n){Ze(z(e)?e.map(s=>s.bind(t.proxy)):e.bind(t.proxy),t,n)}function Jr(e,t,n,s){let o=s.includes(".")?Hr(n,s):()=>n[s];if(xe(e)){const r=t[e];Q(r)&&Kn(o,r)}else if(Q(e))Kn(o,e.bind(n));else if(de(e))if(z(e))e.forEach(r=>Jr(r,t,n,s));else{const r=Q(e.handler)?e.handler.bind(n):t[e.handler];Q(r)&&Kn(o,r,e)}}function Yr(e){const t=e.type,{mixins:n,extends:s}=t,{mixins:o,optionsCache:r,config:{optionMergeStrategies:i}}=e.appContext,l=r.get(t);let a;return l?a=l:!o.length&&!n&&!s?a=t:(a={},o.length&&o.forEach(d=>Yn(a,d,i,!0)),Yn(a,t,i)),de(t)&&r.set(t,a),a}function Yn(e,t,n,s=!1){const{mixins:o,extends:r}=t;r&&Yn(e,r,n,!0),o&&o.forEach(i=>Yn(e,i,n,!0));for(const i in t)if(!(s&&i==="expose")){const l=ql[i]||n&&n[i];e[i]=l?l(e[i],t[i]):t[i]}return e}const ql={data:Ao,props:Ro,emits:Ro,methods:dn,computed:dn,beforeCreate:De,created:De,beforeMount:De,mounted:De,beforeUpdate:De,updated:De,beforeDestroy:De,beforeUnmount:De,destroyed:De,unmounted:De,activated:De,deactivated:De,errorCaptured:De,serverPrefetch:De,components:dn,directives:dn,watch:zl,provide:Ao,inject:Wl};function Ao(e,t){return t?e?function(){return ke(Q(e)?e.call(this,this):e,Q(t)?t.call(this,this):t)}:t:e}function Wl(e,t){return dn(Us(e),Us(t))}function Us(e){if(z(e)){const t={};for(let n=0;nt==="modelValue"||t==="model-value"?e.modelModifiers:e[`${t}Modifiers`]||e[`${je(t)}Modifiers`]||e[`${Bt(t)}Modifiers`];function Xl(e,t,...n){if(e.isUnmounted)return;const s=e.vnode.props||he;let o=n;const r=t.startsWith("update:"),i=r&&Ql(s,t.slice(7));i&&(i.trim&&(o=n.map(c=>xe(c)?c.trim():c)),i.number&&(o=n.map(os)));let l,a=s[l=gs(t)]||s[l=gs(je(t))];!a&&r&&(a=s[l=gs(Bt(t))]),a&&Ze(a,e,6,o);const d=s[l+"Once"];if(d){if(!e.emitted)e.emitted={};else if(e.emitted[l])return;e.emitted[l]=!0,Ze(d,e,6,o)}}const Zl=new WeakMap;function Xr(e,t,n=!1){const s=n?Zl:t.emitsCache,o=s.get(e);if(o!==void 0)return o;const r=e.emits;let i={},l=!1;if(!Q(e)){const a=d=>{const c=Xr(d,t,!0);c&&(l=!0,ke(i,c))};!n&&t.mixins.length&&t.mixins.forEach(a),e.extends&&a(e.extends),e.mixins&&e.mixins.forEach(a)}return!r&&!l?(de(e)&&s.set(e,null),null):(z(r)?r.forEach(a=>i[a]=null):ke(i,r),de(e)&&s.set(e,i),i)}function fs(e,t){return!e||!es(t)?!1:(t=t.slice(2),t=t==="Once"?t:t.replace(/Once$/,""),ce(e,t[0].toLowerCase()+t.slice(1))||ce(e,Bt(t))||ce(e,t))}function Io(e){const{type:t,vnode:n,proxy:s,withProxy:o,propsOptions:[r],slots:i,attrs:l,emit:a,render:d,renderCache:c,props:h,data:v,setupState:_,ctx:j,inheritAttrs:P}=e,K=zn(e);let V,C;try{if(n.shapeFlag&4){const x=o||s,R=x;V=at(d.call(R,x,c,h,_,v,j)),C=l}else{const x=t;V=at(x.length>1?x(h,{attrs:l,slots:i,emit:a}):x(h,null)),C=t.props?l:ea(l)}}catch(x){Et.length=0,as(x,e,1),V=be(ht)}let H=V;if(C&&P!==!1){const x=Object.keys(C),{shapeFlag:R}=H;x.length&&R&7&&(r&&x.some(ts)&&(C=ta(C,r)),H=tn(H,C,!1,!0))}if(n.dirs&&(H=tn(H,null,!1,!0),H.dirs=H.dirs?H.dirs.concat(n.dirs):n.dirs),n.transition){const x=us(H.type)&&Br(H)||H;ro(x,n.transition)}return V=H,zn(K),V}const ea=e=>{let t;for(const n in e)(n==="class"||n==="style"||es(n))&&((t||(t={}))[n]=e[n]);return t},ta=(e,t)=>{const n={};for(const s in e)(!ts(s)||!(s.slice(9)in t))&&(n[s]=e[s]);return n};function na(e,t,n){const{props:s,children:o,component:r}=e,{props:i,children:l,patchFlag:a}=t,d=r.emitsOptions;if(t.dirs||t.transition)return!0;if(n&&a>=0){if(a&1024)return!0;if(a&16)return s?ko(s,i,d):!!i;if(a&8){const c=t.dynamicProps;for(let h=0;hObject.create(ei),ni=e=>Object.getPrototypeOf(e)===ei;function oa(e,t,n,s=!1){const o={},r=ti();e.propsDefaults=Object.create(null),si(e,t,o,r);for(const i in e.propsOptions[0])i in o||(o[i]=void 0);n?e.props=s?o:Nr(o):e.type.props?e.props=o:e.props=r,e.attrs=r}function ra(e,t,n,s){const{props:o,attrs:r,vnode:{patchFlag:i}}=e,l=ue(o),[a]=e.propsOptions;let d=!1;if((s||i>0)&&!(i&16)){if(i&8){const c=e.vnode.dynamicProps;for(let h=0;h{a=!0;const[v,_]=oi(h,t,!0);ke(i,v),_&&l.push(..._)};!n&&t.mixins.length&&t.mixins.forEach(c),e.extends&&c(e.extends),e.mixins&&e.mixins.forEach(c)}if(!r&&!a)return de(e)&&s.set(e,Wt),Wt;if(z(r))for(let c=0;ce==="_"||e==="_ctx"||e==="$stable",ao=e=>z(e)?e.map(at):[at(e)],la=(e,t,n)=>{if(t._n)return t;const s=$t((...o)=>ao(t(...o)),n);return s._c=!1,s},ri=(e,t,n)=>{const s=e._ctx;for(const o in e){if(lo(o))continue;const r=e[o];if(Q(r))t[o]=la(o,r,s);else if(r!=null){const i=ao(r);t[o]=()=>i}}},ii=(e,t)=>{const n=ao(t);e.slots.default=()=>n},li=(e,t,n)=>{for(const s in t)(n||!lo(s))&&(e[s]=t[s])},aa=(e,t,n)=>{const s=e.slots=ti();if(e.vnode.shapeFlag&32){const o=t._;o?(li(s,t,n),n&&mr(s,"_",o,!0)):ri(t,s)}else t&&ii(e,t)},ua=(e,t,n)=>{const{vnode:s,slots:o}=e;let r=!0,i=he;if(s.shapeFlag&32){const l=t._;l?n&&l===1?r=!1:li(o,t,n):(r=!t.$stable,ri(t,o)),i=t}else t&&(ii(e,t),i={default:1});if(r)for(const l in o)!lo(l)&&i[l]==null&&delete o[l]},Fe=ha;function ca(e){return fa(e)}function fa(e,t){const n=rs();n.__VUE__=!0;const{insert:s,remove:o,patchProp:r,createElement:i,createText:l,createComment:a,setText:d,setElementText:c,parentNode:h,nextSibling:v,setScopeId:_=pt,insertStaticContent:j}=e,P=(f,p,m,E=null,A=null,w=null,D=void 0,$=null,N=!!p.dynamicChildren)=>{if(f===p)return;f&&!cn(f,p)&&(E=S(f),Oe(f,A,w,!0),f=null),p.patchFlag===-2&&(N=!1,p.dynamicChildren=null);const{type:I,ref:W,shapeFlag:F}=p;switch(I){case ds:K(f,p,m,E);break;case ht:V(f,p,m,E);break;case Es:f==null&&C(p,m,E,D);break;case le:mt(f,p,m,E,A,w,D,$,N);break;default:F&1?R(f,p,m,E,A,w,D,$,N):F&6?We(f,p,m,E,A,w,D,$,N):(F&64||F&128)&&I.process(f,p,m,E,A,w,D,$,N,G)}W!=null&&A?vn(W,f&&f.ref,w,p||f,!p):W==null&&f&&f.ref!=null&&vn(f.ref,null,w,f,!0)},K=(f,p,m,E)=>{if(f==null)s(p.el=l(p.children),m,E);else{const A=p.el=f.el;p.children!==f.children&&d(A,p.children)}},V=(f,p,m,E)=>{f==null?s(p.el=a(p.children||""),m,E):p.el=f.el},C=(f,p,m,E)=>{[f.el,f.anchor]=j(f.children,p,m,E,f.el,f.anchor)},H=({el:f,anchor:p},m,E)=>{let A;for(;f&&f!==p;)A=v(f),s(f,m,E),f=A;s(p,m,E)},x=({el:f,anchor:p})=>{let m;for(;f&&f!==p;)m=v(f),o(f),f=m;o(p)},R=(f,p,m,E,A,w,D,$,N)=>{if(p.type==="svg"?D="svg":p.type==="math"&&(D="mathml"),f==null)M(p,m,E,A,w,D,$,N);else{const I=f.el&&f.el._isVueCE?f.el:null;try{I&&I._beginPatch(),ye(f,p,A,w,D,$,N)}finally{I&&I._endPatch()}}},M=(f,p,m,E,A,w,D,$)=>{let N,I;const{props:W,shapeFlag:F,transition:q,dirs:y}=f;if(N=f.el=i(f.type,w,W&&W.is,W),F&8?c(N,f.children):F&16&&k(f.children,N,null,E,A,Cs(f,w),D,$),y&&Mt(f,null,E,"created"),Y(N,f,f.scopeId,D,E),W){for(const fe in W)fe!=="value"&&!hn(fe)&&r(N,fe,null,W[fe],w,E);"value"in W&&r(N,"value",null,W.value,w),(I=W.onVnodeBeforeMount)&&rt(I,E,f)}y&&Mt(f,null,E,"beforeMount");const g=da(A,q);g&&q.beforeEnter(N),s(N,p,m),((I=W&&W.onVnodeMounted)||g||y)&&Fe(()=>{try{I&&rt(I,E,f),g&&q.enter(N),y&&Mt(f,null,E,"mounted")}finally{}},A)},Y=(f,p,m,E,A)=>{if(m&&_(f,m),E)for(let w=0;w{for(let I=N;I{const $=p.el=f.el;let{patchFlag:N,dynamicChildren:I,dirs:W}=p;N|=f.patchFlag&16;const F=f.props||he,q=p.props||he;let y;if(m&&Vt(m,!1),(y=q.onVnodeBeforeUpdate)&&rt(y,m,p,f),W&&Mt(p,f,m,"beforeUpdate"),m&&Vt(m,!0),I&&(!f.dynamicChildren||f.dynamicChildren.length!==I.length)&&(N=0,D=!1,I=null),(F.innerHTML&&q.innerHTML==null||F.textContent&&q.textContent==null)&&c($,""),I?Ue(f.dynamicChildren,I,$,m,E,Cs(p,A),w):D||te(f,p,$,null,m,E,Cs(p,A),w,!1),N>0){if(N&16)tt($,F,q,m,A);else if(N&2&&F.class!==q.class&&r($,"class",null,q.class,A),N&4&&r($,"style",F.style,q.style,A),N&8){const g=p.dynamicProps;for(let fe=0;fe{y&&rt(y,m,p,f),W&&Mt(p,f,m,"updated")},E)},Ue=(f,p,m,E,A,w,D)=>{for(let $=0;${if(p!==m){if(p!==he)for(const w in p)!hn(w)&&!(w in m)&&r(f,w,p[w],null,A,E);for(const w in m){if(hn(w))continue;const D=m[w],$=p[w];D!==$&&w!=="value"&&r(f,w,$,D,A,E)}"value"in m&&r(f,"value",p.value,m.value,A)}},mt=(f,p,m,E,A,w,D,$,N)=>{const I=p.el=f?f.el:l(""),W=p.anchor=f?f.anchor:l("");let{patchFlag:F,dynamicChildren:q,slotScopeIds:y}=p;y&&($=$?$.concat(y):y),f==null?(s(I,m,E),s(W,m,E),k(p.children||[],m,W,A,w,D,$,N)):F>0&&F&64&&q&&f.dynamicChildren&&f.dynamicChildren.length===q.length?(Ue(f.dynamicChildren,q,m,A,w,D,$),(p.key!=null||A&&p===A.subTree)&&ai(f,p,!0)):te(f,p,m,W,A,w,D,$,N)},We=(f,p,m,E,A,w,D,$,N)=>{p.slotScopeIds=$,f==null?p.shapeFlag&512?A.ctx.activate(p,m,E,D,N):Dt(p,m,E,A,w,D,N):kt(f,p,N)},Dt=(f,p,m,E,A,w,D)=>{const $=f.component=xa(f,E,A);if(io(f)&&($.ctx.renderer=G),wa($,!1,D),$.asyncDep){if(A&&A.registerDep($,we,D),!f.el){const N=$.subTree=be(ht);V(null,N,p,m),f.placeholder=N.el}}else we($,f,p,m,A,w,D)},kt=(f,p,m)=>{const E=p.component=f.component;if(na(f,p,m))if(E.asyncDep&&!E.asyncResolved){re(E,p,m);return}else E.next=p,E.update();else p.el=f.el,E.vnode=p},we=(f,p,m,E,A,w,D)=>{const $=()=>{if(f.isMounted){let{next:F,bu:q,u:y,parent:g,vnode:fe}=f;{const st=ui(f);if(st){F&&(F.el=fe.el,re(f,F,D)),st.asyncDep.then(()=>{Fe(()=>{f.isUnmounted||I()},A)});return}}let b=F,ne;Vt(f,!1),F?(F.el=fe.el,re(f,F,D)):F=fe,q&&Hn(q),(ne=F.props&&F.props.onVnodeBeforeUpdate)&&rt(ne,g,F,fe),Vt(f,!0);const pe=Io(f),nt=f.subTree;f.subTree=pe,P(nt,pe,h(nt.el),S(nt),f,A,w),F.el=pe.el,b===null&&sa(f,pe.el),y&&Fe(y,A),(ne=F.props&&F.props.onVnodeUpdated)&&Fe(()=>rt(ne,g,F,fe),A)}else{let F;const{el:q,props:y}=p,{bm:g,m:fe,parent:b,root:ne,type:pe}=f,nt=Yt(p);Vt(f,!1),g&&Hn(g),!nt&&(F=y&&y.onVnodeBeforeMount)&&rt(F,b,p),Vt(f,!0);{ne.ce&&ne.ce._hasShadowRoot()&&ne.ce._injectChildStyle(pe,f.parent?f.parent.type:void 0);const st=f.subTree=Io(f);P(null,st,m,E,f,A,w),p.el=st.el}if(fe&&Fe(fe,A),!nt&&(F=y&&y.onVnodeMounted)){const st=p;Fe(()=>rt(F,b,st),A)}(p.shapeFlag&256||b&&Yt(b.vnode)&&b.vnode.shapeFlag&256)&&f.a&&Fe(f.a,A),f.isMounted=!0,p=m=E=null}};f.scope.on();const N=f.effect=new _r($);f.scope.off();const I=f.update=N.run.bind(N),W=f.job=N.runIfDirty.bind(N);W.i=f,W.id=f.uid,N.scheduler=()=>oo(W),Vt(f,!0),I()},re=(f,p,m)=>{p.component=f;const E=f.vnode.props;f.vnode=p,f.next=null,ra(f,p.props,E,m),ua(f,p.children,m),St(),xo(f),At()},te=(f,p,m,E,A,w,D,$,N=!1)=>{const I=f&&f.children,W=f?f.shapeFlag:0,F=p.children,{patchFlag:q,shapeFlag:y}=p;if(q>0){if(q&128){He(I,F,m,E,A,w,D,$,N);return}else if(q&256){ee(I,F,m,E,A,w,D,$,N);return}}y&8?(W&16&&Le(I,A,w),F!==I&&c(m,F)):W&16?y&16?He(I,F,m,E,A,w,D,$,N):Le(I,A,w,!0):(W&8&&c(m,""),y&16&&k(F,m,E,A,w,D,$,N))},ee=(f,p,m,E,A,w,D,$,N)=>{f=f||Wt,p=p||Wt;const I=f.length,W=p.length,F=Math.min(I,W);let q;for(q=0;qW?Le(f,A,w,!0,!1,F):k(p,m,E,A,w,D,$,N,F)},He=(f,p,m,E,A,w,D,$,N)=>{let I=0;const W=p.length;let F=f.length-1,q=W-1;for(;I<=F&&I<=q;){const y=f[I],g=p[I]=N?yt(p[I]):at(p[I]);if(cn(y,g))P(y,g,m,null,A,w,D,$,N);else break;I++}for(;I<=F&&I<=q;){const y=f[F],g=p[q]=N?yt(p[q]):at(p[q]);if(cn(y,g))P(y,g,m,null,A,w,D,$,N);else break;F--,q--}if(I>F){if(I<=q){const y=q+1,g=yq)for(;I<=F;)Oe(f[I],A,w,!0),I++;else{const y=I,g=I,fe=new Map;for(I=g;I<=q;I++){const Ge=p[I]=N?yt(p[I]):at(p[I]);Ge.key!=null&&fe.set(Ge.key,I)}let b,ne=0;const pe=q-g+1;let nt=!1,st=0;const an=new Array(pe);for(I=0;I=pe){Oe(Ge,A,w,!0);continue}let ot;if(Ge.key!=null)ot=fe.get(Ge.key);else for(b=g;b<=q;b++)if(an[b-g]===0&&cn(Ge,p[b])){ot=b;break}ot===void 0?Oe(Ge,A,w,!0):(an[ot-g]=I+1,ot>=st?st=ot:nt=!0,P(Ge,p[ot],m,null,A,w,D,$,N),ne++)}const po=nt?pa(an):Wt;for(b=po.length-1,I=pe-1;I>=0;I--){const Ge=g+I,ot=p[Ge],ho=p[Ge+1],mo=Ge+1{const{el:w,type:D,transition:$,children:N,shapeFlag:I}=f;if(I&6){Be(f.component.subTree,p,m,E);return}if(I&128){f.suspense.move(p,m,E);return}if(I&64){D.move(f,p,m,G);return}if(D===le){s(w,p,m);for(let F=0;F$.enter(w),A));else{const{leave:F,delayLeave:q,afterLeave:y}=$,g=()=>{f.ctx.isUnmounted?o(w):s(w,p,m)},fe=()=>{const b=w._isLeaving||!!w[ys];w._isLeaving&&w[ys](!0),$.persisted&&!b?g():F(w,()=>{g(),y&&y()})};q?q(w,g,fe):fe()}else s(w,p,m)},Oe=(f,p,m,E=!1,A=!1)=>{const{type:w,props:D,ref:$,children:N,dynamicChildren:I,shapeFlag:W,patchFlag:F,dirs:q,cacheIndex:y,memo:g}=f;if(F===-2&&(A=!1),$!=null&&(St(),vn($,null,m,f,!0),At()),y!=null&&(p.renderCache[y]=void 0),W&256){p.ctx.deactivate(f);return}const fe=W&1&&q,b=!Yt(f);let ne;if(b&&(ne=D&&D.onVnodeBeforeUnmount)&&rt(ne,p,f),W&6)vt(f.component,m,E);else{if(W&128){f.suspense.unmount(m,E);return}fe&&Mt(f,null,p,"beforeUnmount"),W&64?f.type.remove(f,p,m,G,E):I&&!I.hasOnce&&(w!==le||F>0&&F&64)?Le(I,p,m,!1,!0):(w===le&&F&384||!A&&W&16)&&Le(N,p,m),E&>(f)}const pe=g!=null&&y==null;(b&&(ne=D&&D.onVnodeUnmounted)||fe||pe)&&Fe(()=>{ne&&rt(ne,p,f),fe&&Mt(f,null,p,"unmounted"),pe&&(f.el=null)},m)},gt=f=>{const{type:p,el:m,anchor:E,transition:A}=f;if(p===le){Ke(m,E);return}if(p===Es){x(f);return}const w=()=>{o(m),A&&!A.persisted&&A.afterLeave&&A.afterLeave()};if(f.shapeFlag&1&&A&&!A.persisted){const{leave:D,delayLeave:$}=A,N=()=>D(m,w);$?$(f.el,w,N):N()}else w()},Ke=(f,p)=>{let m;for(;f!==p;)m=v(f),o(f),f=m;o(p)},vt=(f,p,m)=>{const{bum:E,scope:A,job:w,subTree:D,um:$,m:N,a:I}=f;To(N),To(I),E&&Hn(E),A.stop(),w&&(w.flags|=8,Oe(D,f,p,m)),$&&Fe($,p),Fe(()=>{f.isUnmounted=!0},p)},Le=(f,p,m,E=!1,A=!1,w=0)=>{for(let D=w;D{if(f.shapeFlag&6)return S(f.component.subTree);if(f.shapeFlag&128)return f.suspense.next();const p=v(f.anchor||f.el),m=p&&p[Al];return m?v(m):p};let B=!1;const L=(f,p,m)=>{let E;f==null?p._vnode&&(Oe(p._vnode,null,null,!0),E=p._vnode.component):P(p._vnode||null,f,p,null,null,null,m),p._vnode=f,B||(B=!0,xo(E),jr(),B=!1)},G={p:P,um:Oe,m:Be,r:gt,mt:Dt,mc:k,pc:te,pbc:Ue,n:S,o:e};return{render:L,hydrate:void 0,createApp:Yl(L)}}function Cs({type:e,props:t},n){return n==="svg"&&e==="foreignObject"||n==="mathml"&&e==="annotation-xml"&&t&&t.encoding&&t.encoding.includes("html")?void 0:n}function Vt({effect:e,job:t},n){n?(e.flags|=32,t.flags|=4):(e.flags&=-33,t.flags&=-5)}function da(e,t){return(!e||e&&!e.pendingBranch)&&t&&!t.persisted}function ai(e,t,n=!1){const s=e.children,o=t.children;if(z(s)&&z(o))for(let r=0;r>1,e[n[l]]0&&(t[s]=n[r-1]),n[r]=s)}}for(r=n.length,i=n[r-1];r-- >0;)n[r]=i,i=t[i];return n}function ui(e){const t=e.subTree.component;if(t)return t.asyncDep&&!t.asyncResolved?t:ui(t)}function To(e){if(e)for(let t=0;te.__isSuspense;function ha(e,t){t&&t.pendingBranch?z(e)?t.effects.push(...e):t.effects.push(e):wl(e)}const le=Symbol.for("v-fgt"),ds=Symbol.for("v-txt"),ht=Symbol.for("v-cmt"),Es=Symbol.for("v-stc"),Et=[];let qe=null;function O(e=!1){Et.push(qe=e?null:[])}function uo(){Et.pop(),qe=Et[Et.length-1]||null}let Cn=1;function Qn(e,t=!1){Cn+=e,e<0&&qe&&t&&(qe.hasOnce=!0)}function di(e){return e.dynamicChildren=Cn>0?qe||Wt:null,uo(),Cn>0&&qe&&qe.push(e),e}function T(e,t,n,s,o,r){return di(u(e,t,n,s,o,r,!0))}function En(e,t,n,s,o){return di(be(e,t,n,s,o,!0))}function Sn(e){return e?e.__v_isVNode===!0:!1}function cn(e,t){return e.type===t.type&&e.key===t.key}const pi=({key:e})=>e??null,Gn=({ref:e,ref_key:t,ref_for:n})=>(typeof e=="number"&&(e=""+e),e!=null?xe(e)||$e(e)||Q(e)?{i:Ie,r:e,k:t,f:!!n}:e:null);function u(e,t=null,n=null,s=0,o=null,r=e===le?0:1,i=!1,l=!1){const a={__v_isVNode:!0,__v_skip:!0,type:e,props:t,key:t&&pi(t),ref:t&&Gn(t),scopeId:Lr,slotScopeIds:null,children:n,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:r,patchFlag:s,dynamicProps:o,dynamicChildren:null,appContext:null,ctx:Ie};return l?(Xn(a,n),r&128&&e.normalize(a)):n&&(a.shapeFlag|=xe(n)?8:16),Cn>0&&!i&&qe&&(a.patchFlag>0||r&6)&&a.patchFlag!==32&&qe.push(a),a}const be=ma;function ma(e,t=null,n=null,s=0,o=null,r=!1){if((!e||e===Ll)&&(e=ht),Sn(e)){const l=tn(e,t,!0);return n&&Xn(l,n),Cn>0&&!r&&qe&&(l.shapeFlag&6?qe[qe.indexOf(e)]=l:qe.push(l)),l.patchFlag=-2,l}if(Ra(e)&&(e=e.__vccOpts),t){t=ga(t);let{class:l,style:a}=t;l&&!xe(l)&&(t.class=Re(l)),de(a)&&(no(a)&&!z(a)&&(a=ke({},a)),t.style=Zt(a))}const i=xe(e)?1:fi(e)?128:us(e)?64:de(e)?4:Q(e)?2:0;return u(e,t,n,s,o,i,r,!0)}function ga(e){return e?no(e)||ni(e)?ke({},e):e:null}function tn(e,t,n=!1,s=!1){const{props:o,ref:r,patchFlag:i,children:l,transition:a}=e,d=t?va(o||{},t):o,c={__v_isVNode:!0,__v_skip:!0,type:e.type,props:d,key:d&&pi(d),ref:t&&t.ref?n&&r?z(r)?r.concat(Gn(t)):[r,Gn(t)]:Gn(t):r,scopeId:e.scopeId,slotScopeIds:e.slotScopeIds,children:l,target:e.target,targetStart:e.targetStart,targetAnchor:e.targetAnchor,staticCount:e.staticCount,shapeFlag:e.shapeFlag,patchFlag:t&&e.type!==le?i===-1?16:i|16:i,dynamicProps:e.dynamicProps,dynamicChildren:e.dynamicChildren,appContext:e.appContext,dirs:e.dirs,transition:a,component:e.component,suspense:e.suspense,ssContent:e.ssContent&&tn(e.ssContent),ssFallback:e.ssFallback&&tn(e.ssFallback),placeholder:e.placeholder,el:e.el,anchor:e.anchor,ctx:e.ctx,ce:e.ce};return a&&s&&ro(c,a.clone(c)),c}function Ce(e=" ",t=0){return be(ds,null,e,t)}function X(e="",t=!1){return t?(O(),En(ht,null,e)):be(ht,null,e)}function at(e){return e==null||typeof e=="boolean"?be(ht):z(e)?be(le,null,e.slice()):Sn(e)?yt(e):be(ds,null,String(e))}function yt(e){return e.el===null&&e.patchFlag!==-1||e.memo?e:tn(e)}function Xn(e,t){let n=0;const{shapeFlag:s}=e;if(t==null)t=null;else if(z(t))n=16;else if(typeof t=="object")if(s&65){const o=t.default;o&&(o._c&&(o._d=!1),Xn(e,o()),o._c&&(o._d=!0));return}else{n=32;const o=t._;!o&&!ni(t)?t._ctx=Ie:o===3&&Ie&&(Ie.slots._===1?t._=1:(t._=2,e.patchFlag|=1024))}else if(Q(t)){if(s&65){Xn(e,{default:t});return}t={default:t,_ctx:Ie},n=32}else t=String(t),s&64?(n=16,t=[Ce(t)]):n=8;e.children=t,e.shapeFlag|=n}function va(...e){const t={};for(let n=0;nPe||Ie;let Zn,An;{const e=rs(),t=(n,s)=>{let o;return(o=e[n])||(o=e[n]=[]),o.push(s),r=>{o.length>1?o.forEach(i=>i(r)):o[0](r)}};Zn=t("__VUE_INSTANCE_SETTERS__",n=>Pe=n),An=t("__VUE_SSR_SETTERS__",n=>Rn=n)}const Dn=e=>{const t=Pe;return Zn(e),e.scope.on(),()=>{e.scope.off(),Zn(t)}},Po=()=>{Pe&&Pe.scope.off(),Zn(null)};function hi(e){return e.vnode.shapeFlag&4}let Rn=!1;function wa(e,t=!1,n=!1){t&&An(t);const{props:s,children:o}=e.vnode,r=hi(e);oa(e,s,r,t),aa(e,o,n||t);const i=r?Ca(e,t):void 0;return t&&An(!1),i}function Ca(e,t){const n=e.type;e.accessCache=Object.create(null),e.proxy=new Proxy(e.ctx,Bl);const{setup:s}=n;if(s){St();const o=e.setupContext=s.length>1?Sa(e):null,r=Dn(e),i=Pn(s,e,0,[e.props,o]),l=dr(i);if(At(),r(),(l||e.sp)&&!Yt(e)&&Gr(e),l){if(i.then(Po,Po),t)return i.then(a=>{An(!0);try{No(e,a,t)}finally{An(!1)}}).catch(a=>{as(a,e,0)});e.asyncDep=i}else No(e,i)}else mi(e)}function No(e,t,n){Q(t)?e.type.__ssrInlineRender?e.ssrRender=t:e.render=t:de(t)&&(e.setupState=Dr(t)),mi(e)}function mi(e,t,n){const s=e.type;e.render||(e.render=s.render||pt);{const o=Dn(e);St();try{Kl(e)}finally{At(),o()}}}const Ea={get(e,t){return Te(e,"get",""),e[t]}};function Sa(e){const t=n=>{e.exposed=n||{}};return{attrs:new Proxy(e.attrs,Ea),slots:e.slots,emit:e.emit,expose:t}}function ps(e){return e.exposed?e.exposeProxy||(e.exposeProxy=new Proxy(Dr(dl(e.exposed)),{get(t,n){if(n in t)return t[n];if(n in bn)return bn[n](e)},has(t,n){return n in t||n in bn}})):e.proxy}function Aa(e,t=!0){return Q(e)?e.displayName||e.name:e.name||t&&e.__name}function Ra(e){return Q(e)&&"__vccOpts"in e}const ve=(e,t)=>vl(e,t,Rn);function gi(e,t,n){try{Qn(-1);const s=arguments.length;return s===2?de(t)&&!z(t)?Sn(t)?be(e,null,[t]):be(e,t):be(e,null,t):(s>3?n=Array.prototype.slice.call(arguments,2):s===3&&Sn(n)&&(n=[n]),be(e,t,n))}finally{Qn(1)}}const Ia="3.5.41";/**
+* @vue/runtime-dom v3.5.41
+* (c) 2018-present Yuxi (Evan) You and Vue contributors
+* @license MIT
+**/let Fs;const $o=typeof window<"u"&&window.trustedTypes;if($o)try{Fs=$o.createPolicy("vue",{createHTML:e=>e})}catch{}const vi=Fs?e=>Fs.createHTML(e):e=>e,ka="http://www.w3.org/2000/svg",Oa="http://www.w3.org/1998/Math/MathML",xt=typeof document<"u"?document:null,Do=xt&&xt.createElement("template"),Ta={insert:(e,t,n)=>{t.insertBefore(e,n||null)},remove:e=>{const t=e.parentNode;t&&t.removeChild(e)},createElement:(e,t,n,s)=>{const o=t==="svg"?xt.createElementNS(ka,e):t==="mathml"?xt.createElementNS(Oa,e):n?xt.createElement(e,{is:n}):xt.createElement(e);return e==="select"&&s&&s.multiple!=null&&o.setAttribute("multiple",s.multiple),o},createText:e=>xt.createTextNode(e),createComment:e=>xt.createComment(e),setText:(e,t)=>{e.nodeValue=t},setElementText:(e,t)=>{e.textContent=t},parentNode:e=>e.parentNode,nextSibling:e=>e.nextSibling,querySelector:e=>xt.querySelector(e),setScopeId(e,t){e.setAttribute(t,"")},insertStaticContent(e,t,n,s,o,r){const i=n?n.previousSibling:t.lastChild;if(o&&(o===r||o.nextSibling))for(;t.insertBefore(o.cloneNode(!0),n),!(o===r||!(o=o.nextSibling)););else{Do.innerHTML=vi(s==="svg"?`${e} `:s==="mathml"?`${e} `:e);const l=Do.content;if(s==="svg"||s==="mathml"){const a=l.firstChild;for(;a.firstChild;)l.appendChild(a.firstChild);l.removeChild(a)}t.insertBefore(l,n)}return[i?i.nextSibling:t.firstChild,n?n.previousSibling:t.lastChild]}},Pa=Symbol("_vtc");function Na(e,t,n){const s=e[Pa];s&&(t=(t?[t,...s]:[...s]).join(" ")),t==null?e.removeAttribute("class"):n?e.setAttribute("class",t):e.className=t}const Mo=Symbol("_vod"),$a=Symbol("_vsh"),Da=Symbol(""),Ma=/(?:^|;)\s*display\s*:/;function Va(e,t,n){const s=e.style,o=xe(n);let r=!1;if(n&&!o){if(t)if(xe(t))for(const i of t.split(";")){const l=i.slice(0,i.indexOf(":")).trim();n[l]==null&&pn(s,l,"")}else for(const i in t)n[i]==null&&pn(s,i,"");for(const i in n){i==="display"&&(r=!0);const l=n[i];l!=null?Ua(e,i,!xe(t)&&t?t[i]:void 0,l)||pn(s,i,l):pn(s,i,"")}}else if(o){if(t!==n){const i=s[Da];i&&(n+=";"+i),s.cssText=n,r=Ma.test(n)}}else t&&e.removeAttribute("style");Mo in e&&(e[Mo]=r?s.display:"",e[$a]&&(s.display="none"))}const Vo=/\s*!important$/;function pn(e,t,n){if(z(n))n.forEach(s=>pn(e,t,s));else if(n==null&&(n=""),t.startsWith("--"))e.setProperty(t,n);else{const s=ja(e,t);Vo.test(n)?e.setProperty(Bt(s),n.replace(Vo,""),"important"):e[s]=n}}const jo=["Webkit","Moz","ms"],Ss={};function ja(e,t){const n=Ss[t];if(n)return n;let s=je(t);if(s!=="filter"&&s in e)return Ss[t]=s;s=ss(s);for(let o=0;oAs||(Ga.then(()=>As=0),As=Date.now());function Wa(e,t){const n=s=>{if(!s._vts)s._vts=Date.now();else if(s._vts<=n.attached)return;const o=n.value;if(z(o)){const r=s.stopImmediatePropagation;s.stopImmediatePropagation=()=>{r.call(s),s._stopped=!0};const i=o.slice(),l=[s];for(let a=0;ae.charCodeAt(0)===111&&e.charCodeAt(1)===110&&e.charCodeAt(2)>96&&e.charCodeAt(2)<123,za=(e,t,n,s,o,r)=>{const i=o==="svg";t==="class"?Na(e,s,i):t==="style"?Va(e,n,s):es(t)?ts(t)||Fa(e,t,n,s,r):(t[0]==="."?(t=t.slice(1),!0):t[0]==="^"?(t=t.slice(1),!1):Ja(e,t,s,i))?(Fo(e,t,s),!e.tagName.includes("-")&&(t==="value"||t==="checked"||t==="selected")&&Lo(e,t,s,i,r,t!=="value")):e._isVueCE&&(Ya(e,t)||e._def.__asyncLoader&&(/[A-Z]/.test(t)||!xe(s)))?Fo(e,je(t),s,r,t):(t==="true-value"?e._trueValue=s:t==="false-value"&&(e._falseValue=s),Lo(e,t,s,i))};function Ja(e,t,n,s){if(s)return!!(t==="innerHTML"||t==="textContent"||t in e&&Bo(t)&&Q(n));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 o=e.tagName;if(o==="IMG"||o==="VIDEO"||o==="CANVAS"||o==="SOURCE")return!1}return Bo(t)&&xe(n)?!1:t in e}function Ya(e,t){const n=e._def.props;if(!n)return!1;const s=je(t);return Array.isArray(n)?n.some(o=>je(o)===s):Object.keys(n).some(o=>je(o)===s)}const nn=e=>{const t=e.props["onUpdate:modelValue"]||!1;return z(t)?n=>Hn(t,n):t};function Qa(e){e.target.composing=!0}function Ko(e){const t=e.target;t.composing&&(t.composing=!1,t.dispatchEvent(new Event("input")))}const dt=Symbol("_assign"),Un=Symbol("_initialValue");function Rs(e,t,n){return t&&(e=e.trim()),n&&(e=os(e)),e}const ge={created(e,{modifiers:{lazy:t,trim:n,number:s}},o){e.parentNode&&(e.type==="text"?e[Un]=e.defaultValue.replace(/[\r\n]/g,""):e.type==="textarea"&&(e[Un]=e.defaultValue.replace(/\r\n?/g,`
+`))),e[dt]=nn(o);const r=s||o.props&&o.props.type==="number";Nt(e,t?"change":"input",i=>{i.target.composing||e[dt](Rs(e.value,n,r))}),(n||r)&&Nt(e,"change",()=>{e.value=Rs(e.value,n,r)}),t||(Nt(e,"compositionstart",Qa),Nt(e,"compositionend",Ko),Nt(e,"change",Ko))},mounted(e,{value:t,modifiers:{trim:n,number:s}}){const o=t??"",r=e[Un];delete e[Un],r!==void 0&&(e.type==="text"||e.type==="textarea")&&e.value!==r?e[dt](Rs(e.value,n,s)):e.value=o},beforeUpdate(e,{value:t,oldValue:n,modifiers:{lazy:s,trim:o,number:r}},i){if(e[dt]=nn(i),e.composing)return;const l=(r||e.type==="number")&&!/^0\d/.test(e.value)?os(e.value):e.value,a=t??"";if(l===a)return;const d=e.getRootNode();(d instanceof Document||d instanceof ShadowRoot)&&d.activeElement===e&&e.type!=="range"&&(s&&t===n||o&&e.value.trim()===a)||(e.value=a)}},Ut={deep:!0,created(e,t,n){e[dt]=nn(n),Nt(e,"change",()=>{const s=e._modelValue,o=kn(e),r=e.checked,i=e[dt];if(z(s)){const l=Js(s,o),a=l!==-1;if(r&&!a)i(s.concat(o));else if(!r&&a){const d=[...s];d.splice(l,1),i(d)}}else if(rn(s)){const l=new Set(s);r?l.add(o):l.delete(o),i(l)}else i(bi(e,r))})},mounted:Go,beforeUpdate(e,t,n){e[dt]=nn(n),Go(e,t,n)}};function Go(e,{value:t,oldValue:n},s){e._modelValue=t;let o;if(z(t))o=Js(t,s.props.value)>-1;else if(rn(t))o=t.has(s.props.value);else{if(t===n)return;o=ln(t,bi(e,!0))}e.checked!==o&&(e.checked=o)}const In={deep:!0,created(e,{value:t,modifiers:{number:n}},s){e._modelValue=t,Nt(e,"change",()=>{const o=Array.prototype.filter.call(e.options,r=>r.selected).map(r=>n?os(kn(r)):kn(r));e[dt](e.multiple?rn(e._modelValue)?new Set(o):o:o[0]),e._assigning=!0,so(()=>{e._assigning=!1})}),e[dt]=nn(s)},mounted(e,{value:t}){qo(e,t)},beforeUpdate(e,{value:t},n){e._modelValue=t,e[dt]=nn(n)},updated(e,{value:t}){e._assigning||qo(e,t)}};function qo(e,t){const n=e.multiple,s=z(t);if(!(n&&!s&&!rn(t))){for(let o=0,r=e.options.length;oString(d)===String(l)):i.selected=Js(t,l)>-1}else i.selected=t.has(l);else if(ln(kn(i),t)){e.selectedIndex!==o&&(e.selectedIndex=o);return}}!n&&e.selectedIndex!==-1&&(e.selectedIndex=-1)}}function kn(e){return"_value"in e?e._value:e.value}function bi(e,t){const n=t?"_trueValue":"_falseValue";return n in e?e[n]:t}const Xa=["ctrl","shift","alt","meta"],Za={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)=>Xa.some(n=>e[`${n}Key`]&&!t.includes(n))},ut=(e,t)=>{if(!e)return e;const n=e._withMods||(e._withMods={}),s=t.join(".");return n[s]||(n[s]=((o,...r)=>{for(let i=0;i{const t=tu().createApp(...e),{mount:n}=t;return t.mount=s=>{const o=ou(s);if(!o)return;const r=t._component;!Q(r)&&!r.render&&!r.template&&(r.template=o.innerHTML),o.nodeType===1&&(o.textContent="");const i=n(o,!1,su(o));return o instanceof Element&&(o.removeAttribute("v-cloak"),o.setAttribute("data-v-app","")),i},t});function su(e){if(e instanceof SVGElement)return"svg";if(typeof MathMLElement=="function"&&e instanceof MathMLElement)return"mathml"}function ou(e){return xe(e)?document.querySelector(e):e}/*!
+ * vue-router v4.6.4
+ * (c) 2025 Eduardo San Martin Morote
+ * @license MIT
+ */const qt=typeof document<"u";function _i(e){return typeof e=="object"||"displayName"in e||"props"in e||"__vccOpts"in e}function ru(e){return e.__esModule||e[Symbol.toStringTag]==="Module"||e.default&&_i(e.default)}const ae=Object.assign;function Is(e,t){const n={};for(const s in t){const o=t[s];n[s]=et(o)?o.map(e):e(o)}return n}const _n=()=>{},et=Array.isArray;function zo(e,t){const n={};for(const s in e)n[s]=s in t?t[s]:e[s];return n}const xi=/#/g,iu=/&/g,lu=/\//g,au=/=/g,uu=/\?/g,yi=/\+/g,cu=/%5B/g,fu=/%5D/g,wi=/%5E/g,du=/%60/g,Ci=/%7B/g,pu=/%7C/g,Ei=/%7D/g,hu=/%20/g;function co(e){return e==null?"":encodeURI(""+e).replace(pu,"|").replace(cu,"[").replace(fu,"]")}function mu(e){return co(e).replace(Ci,"{").replace(Ei,"}").replace(wi,"^")}function Hs(e){return co(e).replace(yi,"%2B").replace(hu,"+").replace(xi,"%23").replace(iu,"%26").replace(du,"`").replace(Ci,"{").replace(Ei,"}").replace(wi,"^")}function gu(e){return Hs(e).replace(au,"%3D")}function vu(e){return co(e).replace(xi,"%23").replace(uu,"%3F")}function bu(e){return vu(e).replace(lu,"%2F")}function On(e){if(e==null)return null;try{return decodeURIComponent(""+e)}catch{}return""+e}const _u=/\/$/,xu=e=>e.replace(_u,"");function ks(e,t,n="/"){let s,o={},r="",i="";const l=t.indexOf("#");let a=t.indexOf("?");return a=l>=0&&a>l?-1:a,a>=0&&(s=t.slice(0,a),r=t.slice(a,l>0?l:t.length),o=e(r.slice(1))),l>=0&&(s=s||t.slice(0,l),i=t.slice(l,t.length)),s=Eu(s??t,n),{fullPath:s+r+i,path:s,query:o,hash:On(i)}}function yu(e,t){const n=t.query?e(t.query):"";return t.path+(n&&"?")+n+(t.hash||"")}function Jo(e,t){return!t||!e.toLowerCase().startsWith(t.toLowerCase())?e:e.slice(t.length)||"/"}function wu(e,t,n){const s=t.matched.length-1,o=n.matched.length-1;return s>-1&&s===o&&sn(t.matched[s],n.matched[o])&&Si(t.params,n.params)&&e(t.query)===e(n.query)&&t.hash===n.hash}function sn(e,t){return(e.aliasOf||e)===(t.aliasOf||t)}function Si(e,t){if(Object.keys(e).length!==Object.keys(t).length)return!1;for(var n in e)if(!Cu(e[n],t[n]))return!1;return!0}function Cu(e,t){return et(e)?Yo(e,t):et(t)?Yo(t,e):(e==null?void 0:e.valueOf())===(t==null?void 0:t.valueOf())}function Yo(e,t){return et(t)?e.length===t.length&&e.every((n,s)=>n===t[s]):e.length===1&&e[0]===t}function Eu(e,t){if(e.startsWith("/"))return e;if(!e)return t;const n=t.split("/"),s=e.split("/"),o=s[s.length-1];(o===".."||o===".")&&s.push("");let r=n.length-1,i,l;for(i=0;i1&&r--;else break;return n.slice(0,r).join("/")+"/"+s.slice(i).join("/")}const Ot={path:"/",name:void 0,params:{},query:{},hash:"",fullPath:"/",matched:[],meta:{},redirectedFrom:void 0};let Bs=(function(e){return e.pop="pop",e.push="push",e})({}),Os=(function(e){return e.back="back",e.forward="forward",e.unknown="",e})({});function Su(e){if(!e)if(qt){const t=document.querySelector("base");e=t&&t.getAttribute("href")||"/",e=e.replace(/^\w+:\/\/[^\/]+/,"")}else e="/";return e[0]!=="/"&&e[0]!=="#"&&(e="/"+e),xu(e)}const Au=/^[^#]+#/;function Ru(e,t){return e.replace(Au,"#")+t}function Iu(e,t){const n=document.documentElement.getBoundingClientRect(),s=e.getBoundingClientRect();return{behavior:t.behavior,left:s.left-n.left-(t.left||0),top:s.top-n.top-(t.top||0)}}const hs=()=>({left:window.scrollX,top:window.scrollY});function ku(e){let t;if("el"in e){const n=e.el,s=typeof n=="string"&&n.startsWith("#"),o=typeof n=="string"?s?document.getElementById(n.slice(1)):document.querySelector(n):n;if(!o)return;t=Iu(o,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 Qo(e,t){return(history.state?history.state.position-t:-1)+e}const Ks=new Map;function Ou(e,t){Ks.set(e,t)}function Tu(e){const t=Ks.get(e);return Ks.delete(e),t}function Pu(e){return typeof e=="string"||e&&typeof e=="object"}function Ai(e){return typeof e=="string"||typeof e=="symbol"}let _e=(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 Ri=Symbol("");_e.MATCHER_NOT_FOUND+"",_e.NAVIGATION_GUARD_REDIRECT+"",_e.NAVIGATION_ABORTED+"",_e.NAVIGATION_CANCELLED+"",_e.NAVIGATION_DUPLICATED+"";function on(e,t){return ae(new Error,{type:e,[Ri]:!0},t)}function _t(e,t){return e instanceof Error&&Ri in e&&(t==null||!!(e.type&t))}const Nu=["params","query","hash"];function $u(e){if(typeof e=="string")return e;if(e.path!=null)return e.path;const t={};for(const n of Nu)n in e&&(t[n]=e[n]);return JSON.stringify(t,null,2)}function Du(e){const t={};if(e===""||e==="?")return t;const n=(e[0]==="?"?e.slice(1):e).split("&");for(let s=0;so&&Hs(o)):[s&&Hs(s)]).forEach(o=>{o!==void 0&&(t+=(t.length?"&":"")+n,o!=null&&(t+="="+o))})}return t}function Mu(e){const t={};for(const n in e){const s=e[n];s!==void 0&&(t[n]=et(s)?s.map(o=>o==null?null:""+o):s==null?s:""+s)}return t}const Vu=Symbol(""),Zo=Symbol(""),ms=Symbol(""),fo=Symbol(""),Gs=Symbol("");function fn(){let e=[];function t(s){return e.push(s),()=>{const o=e.indexOf(s);o>-1&&e.splice(o,1)}}function n(){e=[]}return{add:t,list:()=>e.slice(),reset:n}}function Pt(e,t,n,s,o,r=i=>i()){const i=s&&(s.enterCallbacks[o]=s.enterCallbacks[o]||[]);return()=>new Promise((l,a)=>{const d=v=>{v===!1?a(on(_e.NAVIGATION_ABORTED,{from:n,to:t})):v instanceof Error?a(v):Pu(v)?a(on(_e.NAVIGATION_GUARD_REDIRECT,{from:t,to:v})):(i&&s.enterCallbacks[o]===i&&typeof v=="function"&&i.push(v),l())},c=r(()=>e.call(s&&s.instances[o],t,n,d));let h=Promise.resolve(c);e.length<3&&(h=h.then(d)),h.catch(v=>a(v))})}function Ts(e,t,n,s,o=r=>r()){const r=[];for(const i of e)for(const l in i.components){let a=i.components[l];if(!(t!=="beforeRouteEnter"&&!i.instances[l]))if(_i(a)){const d=(a.__vccOpts||a)[t];d&&r.push(Pt(d,n,s,i,l,o))}else{let d=a();r.push(()=>d.then(c=>{if(!c)throw new Error(`Couldn't resolve component "${l}" at "${i.path}"`);const h=ru(c)?c.default:c;i.mods[l]=c,i.components[l]=h;const v=(h.__vccOpts||h)[t];return v&&Pt(v,n,s,i,l,o)()}))}}return r}function ju(e,t){const n=[],s=[],o=[],r=Math.max(t.matched.length,e.matched.length);for(let i=0;isn(d,l))?s.push(l):n.push(l));const a=e.matched[i];a&&(t.matched.find(d=>sn(d,a))||o.push(a))}return[n,s,o]}/*!
+ * vue-router v4.6.4
+ * (c) 2025 Eduardo San Martin Morote
+ * @license MIT
+ */let Uu=()=>location.protocol+"//"+location.host;function Ii(e,t){const{pathname:n,search:s,hash:o}=t,r=e.indexOf("#");if(r>-1){let i=o.includes(e.slice(r))?e.slice(r).length:1,l=o.slice(i);return l[0]!=="/"&&(l="/"+l),Jo(l,"")}return Jo(n,e)+s+o}function Lu(e,t,n,s){let o=[],r=[],i=null;const l=({state:v})=>{const _=Ii(e,location),j=n.value,P=t.value;let K=0;if(v){if(n.value=_,t.value=v,i&&i===j){i=null;return}K=P?v.position-P.position:0}else s(_);o.forEach(V=>{V(n.value,j,{delta:K,type:Bs.pop,direction:K?K>0?Os.forward:Os.back:Os.unknown})})};function a(){i=n.value}function d(v){o.push(v);const _=()=>{const j=o.indexOf(v);j>-1&&o.splice(j,1)};return r.push(_),_}function c(){if(document.visibilityState==="hidden"){const{history:v}=window;if(!v.state)return;v.replaceState(ae({},v.state,{scroll:hs()}),"")}}function h(){for(const v of r)v();r=[],window.removeEventListener("popstate",l),window.removeEventListener("pagehide",c),document.removeEventListener("visibilitychange",c)}return window.addEventListener("popstate",l),window.addEventListener("pagehide",c),document.addEventListener("visibilitychange",c),{pauseListeners:a,listen:d,destroy:h}}function er(e,t,n,s=!1,o=!1){return{back:e,current:t,forward:n,replaced:s,position:window.history.length,scroll:o?hs():null}}function Fu(e){const{history:t,location:n}=window,s={value:Ii(e,n)},o={value:t.state};o.value||r(s.value,{back:null,current:s.value,forward:null,position:t.length-1,replaced:!0,scroll:null},!0);function r(a,d,c){const h=e.indexOf("#"),v=h>-1?(n.host&&document.querySelector("base")?e:e.slice(h))+a:Uu()+e+a;try{t[c?"replaceState":"pushState"](d,"",v),o.value=d}catch(_){console.error(_),n[c?"replace":"assign"](v)}}function i(a,d){r(a,ae({},t.state,er(o.value.back,a,o.value.forward,!0),d,{position:o.value.position}),!0),s.value=a}function l(a,d){const c=ae({},o.value,t.state,{forward:a,scroll:hs()});r(c.current,c,!0),r(a,ae({},er(s.value,a,null),{position:c.position+1},d),!1),s.value=a}return{location:s,state:o,push:l,replace:i}}function Hu(e){e=Su(e);const t=Fu(e),n=Lu(e,t.state,t.location,t.replace);function s(r,i=!0){i||n.pauseListeners(),history.go(r)}const o=ae({location:"",base:e,go:s,createHref:Ru.bind(null,e)},t,n);return Object.defineProperty(o,"location",{enumerable:!0,get:()=>t.location.value}),Object.defineProperty(o,"state",{enumerable:!0,get:()=>t.state.value}),o}let Lt=(function(e){return e[e.Static=0]="Static",e[e.Param=1]="Param",e[e.Group=2]="Group",e})({});var Ee=(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})(Ee||{});const Bu={type:Lt.Static,value:""},Ku=/[a-zA-Z0-9_]/;function Gu(e){if(!e)return[[]];if(e==="/")return[[Bu]];if(!e.startsWith("/"))throw new Error(`Invalid path "${e}"`);function t(_){throw new Error(`ERR (${n})/"${d}": ${_}`)}let n=Ee.Static,s=n;const o=[];let r;function i(){r&&o.push(r),r=[]}let l=0,a,d="",c="";function h(){d&&(n===Ee.Static?r.push({type:Lt.Static,value:d}):n===Ee.Param||n===Ee.ParamRegExp||n===Ee.ParamRegExpEnd?(r.length>1&&(a==="*"||a==="+")&&t(`A repeatable param (${d}) must be alone in its segment. eg: '/:ids+.`),r.push({type:Lt.Param,value:d,regexp:c,repeatable:a==="*"||a==="+",optional:a==="*"||a==="?"})):t("Invalid state to consume buffer"),d="")}function v(){d+=a}for(;lt.length?t.length===1&&t[0]===Me.Static+Me.Segment?1:-1:0}function ki(e,t){let n=0;const s=e.score,o=t.score;for(;n0&&t[t.length-1]<0}const Yu={strict:!1,end:!0,sensitive:!1};function Qu(e,t,n){const s=zu(Gu(e.path),n),o=ae(s,{record:e,parent:t,children:[],alias:[]});return t&&!o.record.aliasOf==!t.record.aliasOf&&t.children.push(o),o}function Xu(e,t){const n=[],s=new Map;t=zo(Yu,t);function o(h){return s.get(h)}function r(h,v,_){const j=!_,P=or(h);P.aliasOf=_&&_.record;const K=zo(t,h),V=[P];if("alias"in h){const x=typeof h.alias=="string"?[h.alias]:h.alias;for(const R of x)V.push(or(ae({},P,{components:_?_.record.components:P.components,path:R,aliasOf:_?_.record:P})))}let C,H;for(const x of V){const{path:R}=x;if(v&&R[0]!=="/"){const M=v.record.path,Y=M[M.length-1]==="/"?"":"/";x.path=v.record.path+(R&&Y+R)}if(C=Qu(x,v,K),_?_.alias.push(C):(H=H||C,H!==C&&H.alias.push(C),j&&h.name&&!rr(C)&&i(h.name)),Oi(C)&&a(C),P.children){const M=P.children;for(let Y=0;Y{i(H)}:_n}function i(h){if(Ai(h)){const v=s.get(h);v&&(s.delete(h),n.splice(n.indexOf(v),1),v.children.forEach(i),v.alias.forEach(i))}else{const v=n.indexOf(h);v>-1&&(n.splice(v,1),h.record.name&&s.delete(h.record.name),h.children.forEach(i),h.alias.forEach(i))}}function l(){return n}function a(h){const v=tc(h,n);n.splice(v,0,h),h.record.name&&!rr(h)&&s.set(h.record.name,h)}function d(h,v){let _,j={},P,K;if("name"in h&&h.name){if(_=s.get(h.name),!_)throw on(_e.MATCHER_NOT_FOUND,{location:h});K=_.record.name,j=ae(sr(v.params,_.keys.filter(H=>!H.optional).concat(_.parent?_.parent.keys.filter(H=>H.optional):[]).map(H=>H.name)),h.params&&sr(h.params,_.keys.map(H=>H.name))),P=_.stringify(j)}else if(h.path!=null)P=h.path,_=n.find(H=>H.re.test(P)),_&&(j=_.parse(P),K=_.record.name);else{if(_=v.name?s.get(v.name):n.find(H=>H.re.test(v.path)),!_)throw on(_e.MATCHER_NOT_FOUND,{location:h,currentLocation:v});K=_.record.name,j=ae({},v.params,h.params),P=_.stringify(j)}const V=[];let C=_;for(;C;)V.unshift(C.record),C=C.parent;return{name:K,path:P,params:j,matched:V,meta:ec(V)}}e.forEach(h=>r(h));function c(){n.length=0,s.clear()}return{addRoute:r,resolve:d,removeRoute:i,clearRoutes:c,getRoutes:l,getRecordMatcher:o}}function sr(e,t){const n={};for(const s of t)s in e&&(n[s]=e[s]);return n}function or(e){const t={path:e.path,redirect:e.redirect,name:e.name,meta:e.meta||{},aliasOf:e.aliasOf,beforeEnter:e.beforeEnter,props:Zu(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 Zu(e){const t={},n=e.props||!1;if("component"in e)t.default=n;else for(const s in e.components)t[s]=typeof n=="object"?n[s]:n;return t}function rr(e){for(;e;){if(e.record.aliasOf)return!0;e=e.parent}return!1}function ec(e){return e.reduce((t,n)=>ae(t,n.meta),{})}function tc(e,t){let n=0,s=t.length;for(;n!==s;){const r=n+s>>1;ki(e,t[r])<0?s=r:n=r+1}const o=nc(e);return o&&(s=t.lastIndexOf(o,s-1)),s}function nc(e){let t=e;for(;t=t.parent;)if(Oi(t)&&ki(e,t)===0)return t}function Oi({record:e}){return!!(e.name||e.components&&Object.keys(e.components).length||e.redirect)}function ir(e){const t=Ye(ms),n=Ye(fo),s=ve(()=>{const a=Ne(e.to);return t.resolve(a)}),o=ve(()=>{const{matched:a}=s.value,{length:d}=a,c=a[d-1],h=n.matched;if(!c||!h.length)return-1;const v=h.findIndex(sn.bind(null,c));if(v>-1)return v;const _=lr(a[d-2]);return d>1&&lr(c)===_&&h[h.length-1].path!==_?h.findIndex(sn.bind(null,a[d-2])):v}),r=ve(()=>o.value>-1&&lc(n.params,s.value.params)),i=ve(()=>o.value>-1&&o.value===n.matched.length-1&&Si(n.params,s.value.params));function l(a={}){if(ic(a)){const d=t[Ne(e.replace)?"replace":"push"](Ne(e.to)).catch(_n);return e.viewTransition&&typeof document<"u"&&"startViewTransition"in document&&document.startViewTransition(()=>d),d}return Promise.resolve()}return{route:s,href:ve(()=>s.value.href),isActive:r,isExactActive:i,navigate:l}}function sc(e){return e.length===1?e[0]:e}const oc=Kr({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:ir,setup(e,{slots:t}){const n=ls(ir(e)),{options:s}=Ye(ms),o=ve(()=>({[ar(e.activeClass,s.linkActiveClass,"router-link-active")]:n.isActive,[ar(e.exactActiveClass,s.linkExactActiveClass,"router-link-exact-active")]:n.isExactActive}));return()=>{const r=t.default&&sc(t.default(n));return e.custom?r:gi("a",{"aria-current":n.isExactActive?e.ariaCurrentValue:null,href:n.href,onClick:n.navigate,class:o.value},r)}}}),rc=oc;function ic(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 lc(e,t){for(const n in t){const s=t[n],o=e[n];if(typeof s=="string"){if(s!==o)return!1}else if(!et(o)||o.length!==s.length||s.some((r,i)=>r.valueOf()!==o[i].valueOf()))return!1}return!0}function lr(e){return e?e.aliasOf?e.aliasOf.path:e.path:""}const ar=(e,t,n)=>e??t??n,ac=Kr({name:"RouterView",inheritAttrs:!1,props:{name:{type:String,default:"default"},route:Object},compatConfig:{MODE:3},setup(e,{attrs:t,slots:n}){const s=Ye(Gs),o=ve(()=>e.route||s.value),r=Ye(Zo,0),i=ve(()=>{let d=Ne(r);const{matched:c}=o.value;let h;for(;(h=c[d])&&!h.components;)d++;return d}),l=ve(()=>o.value.matched[i.value]);Bn(Zo,ve(()=>i.value+1)),Bn(Vu,l),Bn(Gs,o);const a=J();return Kn(()=>[a.value,l.value,e.name],([d,c,h],[v,_,j])=>{c&&(c.instances[h]=d,_&&_!==c&&d&&d===v&&(c.leaveGuards.size||(c.leaveGuards=_.leaveGuards),c.updateGuards.size||(c.updateGuards=_.updateGuards))),d&&c&&(!_||!sn(c,_)||!v)&&(c.enterCallbacks[h]||[]).forEach(P=>P(d))},{flush:"post"}),()=>{const d=o.value,c=e.name,h=l.value,v=h&&h.components[c];if(!v)return ur(n.default,{Component:v,route:d});const _=h.props[c],j=_?_===!0?d.params:typeof _=="function"?_(d):_:null,K=gi(v,ae({},j,t,{onVnodeUnmounted:V=>{V.component.isUnmounted&&(h.instances[c]=null)},ref:a}));return ur(n.default,{Component:K,route:d})||K}}});function ur(e,t){if(!e)return null;const n=e(t);return n.length===1?n[0]:n}const uc=ac;function cc(e){const t=Xu(e.routes,e),n=e.parseQuery||Du,s=e.stringifyQuery||Xo,o=e.history,r=fn(),i=fn(),l=fn(),a=pl(Ot);let d=Ot;qt&&e.scrollBehavior&&"scrollRestoration"in history&&(history.scrollRestoration="manual");const c=Is.bind(null,S=>""+S),h=Is.bind(null,bu),v=Is.bind(null,On);function _(S,B){let L,G;return Ai(S)?(L=t.getRecordMatcher(S),G=B):G=S,t.addRoute(G,L)}function j(S){const B=t.getRecordMatcher(S);B&&t.removeRoute(B)}function P(){return t.getRoutes().map(S=>S.record)}function K(S){return!!t.getRecordMatcher(S)}function V(S,B){if(B=ae({},B||a.value),typeof S=="string"){const m=ks(n,S,B.path),E=t.resolve({path:m.path},B),A=o.createHref(m.fullPath);return ae(m,E,{params:v(E.params),hash:On(m.hash),redirectedFrom:void 0,href:A})}let L;if(S.path!=null)L=ae({},S,{path:ks(n,S.path,B.path).path});else{const m=ae({},S.params);for(const E in m)m[E]==null&&delete m[E];L=ae({},S,{params:h(m)}),B.params=h(B.params)}const G=t.resolve(L,B),Z=S.hash||"";G.params=c(v(G.params));const f=yu(s,ae({},S,{hash:mu(Z),path:G.path})),p=o.createHref(f);return ae({fullPath:f,hash:Z,query:s===Xo?Mu(S.query):S.query||{}},G,{redirectedFrom:void 0,href:p})}function C(S){return typeof S=="string"?ks(n,S,a.value.path):ae({},S)}function H(S,B){if(d!==S)return on(_e.NAVIGATION_CANCELLED,{from:B,to:S})}function x(S){return Y(S)}function R(S){return x(ae(C(S),{replace:!0}))}function M(S,B){const L=S.matched[S.matched.length-1];if(L&&L.redirect){const{redirect:G}=L;let Z=typeof G=="function"?G(S,B):G;return typeof Z=="string"&&(Z=Z.includes("?")||Z.includes("#")?Z=C(Z):{path:Z},Z.params={}),ae({query:S.query,hash:S.hash,params:Z.path!=null?{}:S.params},Z)}}function Y(S,B){const L=d=V(S),G=a.value,Z=S.state,f=S.force,p=S.replace===!0,m=M(L,G);if(m)return Y(ae(C(m),{state:typeof m=="object"?ae({},Z,m.state):Z,force:f,replace:p}),B||L);const E=L;E.redirectedFrom=B;let A;return!f&&wu(s,G,L)&&(A=on(_e.NAVIGATION_DUPLICATED,{to:E,from:G}),Be(G,G,!0,!1)),(A?Promise.resolve(A):Ue(E,G)).catch(w=>_t(w)?_t(w,_e.NAVIGATION_GUARD_REDIRECT)?w:He(w):te(w,E,G)).then(w=>{if(w){if(_t(w,_e.NAVIGATION_GUARD_REDIRECT))return Y(ae({replace:p},C(w.to),{state:typeof w.to=="object"?ae({},Z,w.to.state):Z,force:f}),B||E)}else w=mt(E,G,!0,p,Z);return tt(E,G,w),w})}function k(S,B){const L=H(S,B);return L?Promise.reject(L):Promise.resolve()}function ye(S){const B=Ke.values().next().value;return B&&typeof B.runWithContext=="function"?B.runWithContext(S):S()}function Ue(S,B){let L;const[G,Z,f]=ju(S,B);L=Ts(G.reverse(),"beforeRouteLeave",S,B);for(const m of G)m.leaveGuards.forEach(E=>{L.push(Pt(E,S,B))});const p=k.bind(null,S,B);return L.push(p),Le(L).then(()=>{L=[];for(const m of r.list())L.push(Pt(m,S,B));return L.push(p),Le(L)}).then(()=>{L=Ts(Z,"beforeRouteUpdate",S,B);for(const m of Z)m.updateGuards.forEach(E=>{L.push(Pt(E,S,B))});return L.push(p),Le(L)}).then(()=>{L=[];for(const m of f)if(m.beforeEnter)if(et(m.beforeEnter))for(const E of m.beforeEnter)L.push(Pt(E,S,B));else L.push(Pt(m.beforeEnter,S,B));return L.push(p),Le(L)}).then(()=>(S.matched.forEach(m=>m.enterCallbacks={}),L=Ts(f,"beforeRouteEnter",S,B,ye),L.push(p),Le(L))).then(()=>{L=[];for(const m of i.list())L.push(Pt(m,S,B));return L.push(p),Le(L)}).catch(m=>_t(m,_e.NAVIGATION_CANCELLED)?m:Promise.reject(m))}function tt(S,B,L){l.list().forEach(G=>ye(()=>G(S,B,L)))}function mt(S,B,L,G,Z){const f=H(S,B);if(f)return f;const p=B===Ot,m=qt?history.state:{};L&&(G||p?o.replace(S.fullPath,ae({scroll:p&&m&&m.scroll},Z)):o.push(S.fullPath,Z)),a.value=S,Be(S,B,L,p),He()}let We;function Dt(){We||(We=o.listen((S,B,L)=>{if(!vt.listening)return;const G=V(S),Z=M(G,vt.currentRoute.value);if(Z){Y(ae(Z,{replace:!0,force:!0}),G).catch(_n);return}d=G;const f=a.value;qt&&Ou(Qo(f.fullPath,L.delta),hs()),Ue(G,f).catch(p=>_t(p,_e.NAVIGATION_ABORTED|_e.NAVIGATION_CANCELLED)?p:_t(p,_e.NAVIGATION_GUARD_REDIRECT)?(Y(ae(C(p.to),{force:!0}),G).then(m=>{_t(m,_e.NAVIGATION_ABORTED|_e.NAVIGATION_DUPLICATED)&&!L.delta&&L.type===Bs.pop&&o.go(-1,!1)}).catch(_n),Promise.reject()):(L.delta&&o.go(-L.delta,!1),te(p,G,f))).then(p=>{p=p||mt(G,f,!1),p&&(L.delta&&!_t(p,_e.NAVIGATION_CANCELLED)?o.go(-L.delta,!1):L.type===Bs.pop&&_t(p,_e.NAVIGATION_ABORTED|_e.NAVIGATION_DUPLICATED)&&o.go(-1,!1)),tt(G,f,p)}).catch(_n)}))}let kt=fn(),we=fn(),re;function te(S,B,L){He(S);const G=we.list();return G.length?G.forEach(Z=>Z(S,B,L)):console.error(S),Promise.reject(S)}function ee(){return re&&a.value!==Ot?Promise.resolve():new Promise((S,B)=>{kt.add([S,B])})}function He(S){return re||(re=!S,Dt(),kt.list().forEach(([B,L])=>S?L(S):B()),kt.reset()),S}function Be(S,B,L,G){const{scrollBehavior:Z}=e;if(!qt||!Z)return Promise.resolve();const f=!L&&Tu(Qo(S.fullPath,0))||(G||!L)&&history.state&&history.state.scroll||null;return so().then(()=>Z(S,B,f)).then(p=>p&&ku(p)).catch(p=>te(p,S,B))}const Oe=S=>o.go(S);let gt;const Ke=new Set,vt={currentRoute:a,listening:!0,addRoute:_,removeRoute:j,clearRoutes:t.clearRoutes,hasRoute:K,getRoutes:P,resolve:V,options:e,push:x,replace:R,go:Oe,back:()=>Oe(-1),forward:()=>Oe(1),beforeEach:r.add,beforeResolve:i.add,afterEach:l.add,onError:we.add,isReady:ee,install(S){S.component("RouterLink",rc),S.component("RouterView",uc),S.config.globalProperties.$router=vt,Object.defineProperty(S.config.globalProperties,"$route",{enumerable:!0,get:()=>Ne(a)}),qt&&!gt&&a.value===Ot&&(gt=!0,x(o.location).catch(G=>{}));const B={};for(const G in Ot)Object.defineProperty(B,G,{get:()=>a.value[G],enumerable:!0});S.provide(ms,vt),S.provide(fo,Nr(B)),S.provide(Gs,a);const L=S.unmount;Ke.add(S),S.unmount=function(){Ke.delete(S),Ke.size<1&&(d=Ot,We&&We(),We=null,a.value=Ot,gt=!1,re=!1),L()}}};function Le(S){return S.reduce((B,L)=>B.then(()=>ye(L)),Promise.resolve())}return vt}function Ti(){return Ye(ms)}function Pi(e){return Ye(fo)}const Ln=window.location.pathname.startsWith("/portal/"),ft={esPortal:Ln,baseRuta:Ln?"/portal/studio/":"/studio/",apiBase:Ln?"/portal":"/app",urlLogin:Ln?"/portal/login":"/login"};function ie(e){return ft.apiBase+e}async function Fn(e,t={}){const n=await fetch(e,{...t,headers:{"Content-Type":"application/json",...t.headers}}),s=n.headers.get("content-type")||"";if(n.redirected||!s.includes("application/json"))throw window.location.href=ft.urlLogin,new Error("Sesión expirada");const o=await n.json();if(!n.ok){const r=typeof(o==null?void 0:o.error)=="string"?o.error:o==null?void 0:o.message;throw new Error(r||"Error de servidor")}return o}const oe={get:e=>Fn(e),post:(e,t)=>Fn(e,{method:"POST",body:JSON.stringify(t)}),put:(e,t)=>Fn(e,{method:"PUT",body:JSON.stringify(t)}),del:e=>Fn(e,{method:"DELETE"})},fc={class:"w-64 shrink-0 h-screen sticky top-0 flex flex-col border-r border-borde bg-superficie"},dc={class:"h-14 px-4 flex items-center border-b border-borde"},pc={key:0,class:"px-3 pt-3"},hc={key:1,class:"px-3 pt-2 text-xs text-red-600 dark:text-red-400"},mc={class:"flex-1 overflow-y-auto px-2 py-3 space-y-0.5"},gc={key:0,class:"px-2 text-xs text-tenue"},vc={key:1,class:"px-2 text-xs text-tenue"},bc={class:"truncate"},_c={class:"flex items-center gap-1 mt-0.5"},xc={class:"text-[11px] text-tenue"},yc={key:0,class:"flex opacity-0 group-hover:opacity-100 transition-opacity pr-1.5 gap-0.5"},wc=["onClick"],Cc=["onClick"],Ec={class:"card w-full max-w-lg p-6 animate-escalar shadow-2xl"},Sc={class:"font-semibold text-texto mb-4"},Ac={key:0,class:"grid grid-cols-2 gap-3"},Rc=["value"],Ic={class:"text-[11px] text-tenue mt-1"},kc=["value"],Oc={class:"text-[11px] text-tenue mt-1"},Tc={class:"flex items-center gap-2 text-sm text-texto"},Pc={class:"flex justify-end gap-2 pt-2"},Nc={__name:"Sidebar",setup(e,{expose:t}){const n=Pi(),s=Ti(),o=J([]),r=J([]),i=J([]),l=J(!0),a=J(""),d=J(!1),c=J(null),h=J(_()),v=ve(()=>n.params.tenantId||n.params.id);function _(){return{nombre:"",dominios_permitidos:"",activo:!0,cliente_id:null,plan_id:null}}async function j(){l.value=!0,a.value="";try{const R=await oe.get(ie("/umind/tenants"));o.value=R.items||[]}catch(R){a.value=R.message}finally{l.value=!1}}function P(R){return Array.isArray(R)?R:(R==null?void 0:R.items)||(R==null?void 0:R.registros)||[]}async function K(){if(ft.esPortal)return;const[R,M]=await Promise.allSettled([oe.get("/app/api/clientes/select"),oe.get("/app/umind-planes/list")]);r.value=R.status==="fulfilled"?P(R.value):[],i.value=M.status==="fulfilled"?P(M.value):[];const Y=[];R.status==="rejected"&&Y.push("clientes"),M.status==="rejected"&&Y.push("planes"),Y.length&&(a.value=`No se pudo cargar la lista de ${Y.join(" ni ")}.`)}function V(){c.value=null,h.value=_(),d.value=!0}function C(R){c.value=R,h.value={nombre:R.nombre,dominios_permitidos:R.dominios_permitidos,activo:R.activo,cliente_id:R.cliente_id??null,plan_id:R.plan_id??null},d.value=!0}async function H(){const R={...h.value,dominios_permitidos:h.value.dominios_permitidos.split(",").map(M=>M.trim()).filter(Boolean)};try{if(c.value)await oe.put(ie(`/umind/tenants/${c.value.ID}`),R),d.value=!1,await j();else{const M=await oe.post(ie("/umind/tenants"),R);d.value=!1,await j(),s.push(`/tenants/${M.id}`)}}catch(M){a.value=M.message}}async function x(R){confirm(`¿Eliminar el tenant "${R.nombre}"? Esto borra también sus agentes. No se puede deshacer.`)&&(await oe.del(ie(`/umind/tenants/${R.ID}`)),v.value===String(R.ID)&&s.push("/"),await j())}return t({recargar:j}),Nn(()=>{j(),K()}),(R,M)=>{const Y=$n("router-link");return O(),T(le,null,[u("aside",fc,[u("div",dc,[be(Y,{to:"/",class:"text-base font-semibold text-texto"},{default:$t(()=>[...M[7]||(M[7]=[Ce(" uMind ",-1),u("span",{class:"text-brand"},"Studio",-1)])]),_:1})]),Ne(ft).esPortal?X("",!0):(O(),T("div",pc,[u("button",{class:"btn-primary w-full",onClick:V}," + Nuevo tenant ")])),a.value?(O(),T("p",hc,U(a.value),1)):X("",!0),u("nav",mc,[l.value?(O(),T("p",gc,"Cargando...")):o.value.length===0?(O(),T("p",vc,U(Ne(ft).esPortal?"Todavía no tenés ningún espacio asignado. Escribinos y lo activamos.":"Sin tenants todavía."),1)):X("",!0),(O(!0),T(le,null,Ae(o.value,k=>(O(),T("div",{key:k.ID,class:Re(["group flex items-center rounded-lg transition-colors",v.value===String(k.ID)?"bg-brand/10":"hover:bg-elevado"])},[be(Y,{to:`/tenants/${k.ID}`,class:Re(["flex-1 min-w-0 px-2.5 py-2 text-sm",v.value===String(k.ID)?"text-brand font-medium":"text-texto"])},{default:$t(()=>[u("div",bc,U(k.nombre),1),u("div",_c,[u("span",{class:Re(["w-1.5 h-1.5 rounded-full",k.activo?"bg-green-500":"bg-tenue/40"])},null,2),u("span",xc,U(k.activo?"activo":"inactivo"),1)])]),_:2},1032,["to","class"]),Ne(ft).esPortal?X("",!0):(O(),T("div",yc,[u("button",{class:"p-1 text-tenue hover:text-texto",title:"Editar",onClick:ye=>C(k)}," ✎ ",8,wc),u("button",{class:"p-1 text-tenue hover:text-red-600",title:"Eliminar",onClick:ye=>x(k)}," ✕ ",8,Cc)]))],2))),128))])]),d.value?(O(),T("div",{key:0,class:"fixed inset-0 bg-black/40 flex items-center justify-center p-4 z-50",onClick:M[6]||(M[6]=ut(k=>d.value=!1,["self"]))},[u("div",Ec,[u("h2",Sc,U(c.value?"Editar tenant":"Nuevo tenant"),1),M[16]||(M[16]=u("p",{class:"text-xs text-tenue mb-3"}," Un tenant es el negocio/sitio dueño de los dominios permitidos. La config de IA, tono y demás se configuran por agente, dentro del tenant. ",-1)),u("form",{class:"space-y-3",onSubmit:ut(H,["prevent"])},[u("div",null,[M[8]||(M[8]=u("label",{class:"label"},"Nombre",-1)),se(u("input",{"onUpdate:modelValue":M[0]||(M[0]=k=>h.value.nombre=k),required:"",class:"input"},null,512),[[ge,h.value.nombre]])]),u("div",null,[M[9]||(M[9]=u("label",{class:"label"},"Dominios permitidos (separados por coma)",-1)),se(u("input",{"onUpdate:modelValue":M[1]||(M[1]=k=>h.value.dominios_permitidos=k),placeholder:"ejemplo.com, www.ejemplo.com",required:"",class:"input"},null,512),[[ge,h.value.dominios_permitidos]])]),Ne(ft).esPortal?X("",!0):(O(),T("div",Ac,[u("div",null,[M[11]||(M[11]=u("label",{class:"label"},"Cliente",-1)),se(u("select",{"onUpdate:modelValue":M[2]||(M[2]=k=>h.value.cliente_id=k),class:"input"},[M[10]||(M[10]=u("option",{value:null},"— sin asignar —",-1)),(O(!0),T(le,null,Ae(r.value,k=>(O(),T("option",{key:k.ID,value:k.ID},U(k.nombre),9,Rc))),128))],512),[[In,h.value.cliente_id]]),u("p",Ic,U(r.value.length?"Define quién ve este tenant desde el portal.":"No hay clientes activos — creá uno en Clientes."),1)]),u("div",null,[M[13]||(M[13]=u("label",{class:"label"},"Plan",-1)),se(u("select",{"onUpdate:modelValue":M[3]||(M[3]=k=>h.value.plan_id=k),class:"input"},[M[12]||(M[12]=u("option",{value:null},"— sin plan —",-1)),(O(!0),T(le,null,Ae(i.value,k=>(O(),T("option",{key:k.ID,value:k.ID},U(k.nombre)+" ("+U(k.max_agentes===0?"∞":k.max_agentes)+" agentes) ",9,kc))),128))],512),[[In,h.value.plan_id]]),u("p",Oc,U(i.value.length?"Límite de agentes y precios de consumo.":"No hay planes — creá uno en uMind Planes."),1)])])),u("label",Tc,[se(u("input",{"onUpdate:modelValue":M[4]||(M[4]=k=>h.value.activo=k),type:"checkbox"},null,512),[[Ut,h.value.activo]]),M[14]||(M[14]=Ce(" Activo ",-1))]),u("div",Pc,[u("button",{type:"button",class:"btn-ghost",onClick:M[5]||(M[5]=k=>d.value=!1)}," Cancelar "),M[15]||(M[15]=u("button",{type:"submit",class:"btn-primary"}," Guardar ",-1))])],32)])])):X("",!0)],64)}}},Ni="umind-tema";function $c(){return window.matchMedia("(prefers-color-scheme: dark)").matches?"oscuro":"claro"}const Xt=J(localStorage.getItem(Ni)||$c());function $i(){document.documentElement.classList.toggle("dark",Xt.value==="oscuro")}function cr(){Xt.value=Xt.value==="oscuro"?"claro":"oscuro",localStorage.setItem(Ni,Xt.value),$i()}$i();const Dc={class:"min-h-screen flex"},Mc={class:"flex-1 min-w-0 flex flex-col"},Vc={class:"h-14 shrink-0 flex items-center justify-end gap-1 px-6 border-b border-borde"},jc=["title"],Uc={class:"text-base leading-none"},Lc={class:"flex-1 max-w-5xl w-full mx-auto px-8 py-8 animate-aparecer"},Fc={__name:"App",setup(e){return(t,n)=>{const s=$n("router-view");return O(),T("div",Dc,[be(Nc),u("main",Mc,[u("header",Vc,[u("button",{class:"btn-ghost !px-2.5 !py-1.5",title:Ne(Xt)==="oscuro"?"Cambiar a claro":"Cambiar a oscuro",onClick:n[0]||(n[0]=(...o)=>Ne(cr)&&Ne(cr)(...o))},[u("span",Uc,U(Ne(Xt)==="oscuro"?"☀️":"🌙"),1)],8,jc)]),u("div",Lc,[be(s)])])])}}},Hc={class:"flex flex-col items-center justify-center text-center py-24"},Bc={class:"text-lg font-medium text-gray-700 dark:text-gray-200"},Kc={class:"text-sm text-gray-400 dark:text-gray-500 mt-1"},Gc={__name:"Home",setup(e){return(t,n)=>(O(),T("div",Hc,[n[0]||(n[0]=u("div",{class:"text-4xl mb-4"},"💬",-1)),u("h1",Bc,U(Ne(ft).esPortal?"Elegí tu espacio de la izquierda":"Elegí un tenant de la izquierda"),1),u("p",Kc,U(Ne(ft).esPortal?"Adentro vas a poder crear y configurar tus agentes.":"o creá uno nuevo para empezar a configurar su agente."),1)]))}},qc={class:"flex flex-col items-center justify-center text-center py-12 px-6"},Wc={key:0,class:"text-3xl mb-3 opacity-70"},zc={class:"text-sm font-medium text-texto"},Jc={key:1,class:"text-xs text-tenue mt-1 max-w-sm"},Yc={class:"mt-4"},Di={__name:"UiEmptyState",props:{icono:{type:String,default:""},titulo:String,detalle:String},setup(e){return(t,n)=>(O(),T("div",qc,[e.icono?(O(),T("div",Wc,U(e.icono),1)):X("",!0),u("p",zc,U(e.titulo),1),e.detalle?(O(),T("p",Jc,U(e.detalle),1)):X("",!0),u("div",Yc,[Hl(t.$slots,"default")])]))}},Qc={key:0,class:"mb-6"},Xc={class:"flex items-start justify-between gap-4"},Zc={class:"text-xl font-semibold text-texto"},ef={class:"text-xs text-tenue mt-1"},tf={key:1,class:"text-sm text-red-600 dark:text-red-400 mb-4"},nf={class:"card divide-y divide-borde overflow-hidden"},sf={class:"font-medium text-texto"},of={class:"flex items-center gap-1 mt-0.5"},rf={class:"text-xs text-tenue"},lf={class:"flex items-center gap-3 pr-4 text-sm"},af=["onClick"],uf=["onClick"],cf={class:"bg-white dark:bg-gray-900 border border-gray-200 dark:border-gray-800 rounded-xl p-6 w-full max-w-lg"},ff={class:"font-semibold text-gray-800 dark:text-gray-100 mb-4"},df=["value"],pf={class:"flex items-center gap-2"},hf={class:"flex items-center gap-2 text-sm text-gray-600 dark:text-gray-300"},mf={class:"flex justify-end gap-2 pt-2"},gf={type:"submit",class:"bg-brand hover:bg-brand-dark text-white text-sm font-medium px-4 py-2 rounded-lg"},vf={__name:"TenantAgentes",props:{id:{type:String,required:!0}},setup(e){const t=e,n=ve(()=>Number(t.id)),s=Ti(),o=J(null),r=J([]),i=J([]),l=J(""),a=J(!1),d=J(null),c=J(h());function h(){return{nombre:"",ai_config_id:null,tono:"",mensaje_bienvenida:"",color:"#8eb02f",activo:!0}}async function v(){l.value="";try{const[V,C,H]=await Promise.all([oe.get(ie("/umind/tenants")),oe.get(ie(`/umind/agentes?tenant_id=${t.id}`)),oe.get(ie("/umind/ai-configs"))]);o.value=(V.items||[]).find(x=>String(x.ID)===t.id)||null,r.value=C.items||[],i.value=H.items||[]}catch(V){l.value=V.message}}function _(){d.value=null,c.value=h(),a.value=!0}function j(V){d.value=V,c.value={nombre:V.nombre,ai_config_id:V.ai_config_id,tono:V.tono,mensaje_bienvenida:V.mensaje_bienvenida,color:V.color||"#8eb02f",activo:V.activo},a.value=!0}async function P(){try{if(d.value)await oe.put(ie(`/umind/agentes/${d.value.ID}`),{tenant_id:n.value,...c.value}),a.value=!1,await v();else{const V=await oe.post(ie("/umind/agentes"),{tenant_id:n.value,...c.value});a.value=!1,s.push(`/tenants/${n.value}/agentes/${V.id}`)}}catch(V){l.value=V.message}}async function K(V){confirm(`¿Eliminar el agente "${V.nombre}"? Esto no se puede deshacer.`)&&(await oe.del(ie(`/umind/agentes/${V.ID}`)),await v())}return Nn(v),(V,C)=>{const H=$n("router-link");return O(),T("div",null,[o.value?(O(),T("div",Qc,[u("div",Xc,[u("div",null,[u("h1",Zc,U(o.value.nombre),1),u("p",ef,U(o.value.dominios_permitidos||"sin dominios configurados"),1)]),be(H,{to:`/tenants/${n.value??e.id}/uso`,class:"btn-ghost"},{default:$t(()=>[...C[9]||(C[9]=[Ce("📊 Consumo",-1)])]),_:1},8,["to"])])])):X("",!0),l.value?(O(),T("p",tf,U(l.value),1)):X("",!0),u("div",{class:"flex items-center justify-between mb-4"},[C[10]||(C[10]=u("h2",{class:"text-sm font-medium text-tenue"},"Agentes",-1)),u("button",{class:"btn-primary",onClick:_},"+ Nuevo agente")]),u("div",nf,[r.value.length===0?(O(),En(Di,{key:0,icono:"🤖",titulo:"Todavía no hay agentes",detalle:"Creá el primero y cargale su base de conocimiento para que empiece a responder."})):X("",!0),(O(!0),T(le,null,Ae(r.value,x=>(O(),T("div",{key:x.ID,class:"group flex items-center justify-between hover:bg-elevado transition-colors"},[be(H,{to:`/tenants/${n.value}/agentes/${x.ID}`,class:"flex-1 min-w-0 p-4"},{default:$t(()=>[u("div",sf,U(x.nombre),1),u("div",of,[u("span",{class:Re(["w-1.5 h-1.5 rounded-full",!x.activo&&"bg-gray-300 dark:bg-gray-600"]),style:Zt({background:x.activo?x.color||"#22c55e":void 0})},null,6),u("span",rf,U(x.activo?"activo":"inactivo"),1)])]),_:2},1032,["to"]),u("div",lf,[be(H,{to:`/tenants/${n.value}/agentes/${x.ID}`,class:"text-brand font-medium opacity-0 group-hover:opacity-100 transition-opacity"},{default:$t(()=>[...C[11]||(C[11]=[Ce(" Configurar → ",-1)])]),_:1},8,["to"]),u("button",{class:"text-tenue hover:text-texto opacity-0 group-hover:opacity-100 transition-opacity",title:"Editar",onClick:R=>j(x)},"✎",8,af),u("button",{class:"text-tenue hover:text-red-600 opacity-0 group-hover:opacity-100 transition-opacity",title:"Eliminar",onClick:R=>K(x)},"✕",8,uf)])]))),128))]),a.value?(O(),T("div",{key:2,class:"fixed inset-0 bg-black/40 flex items-center justify-center p-4 z-50",onClick:C[8]||(C[8]=ut(x=>a.value=!1,["self"]))},[u("div",cf,[u("h2",ff,U(d.value?"Editar agente":"Nuevo agente"),1),u("form",{class:"space-y-3",onSubmit:ut(P,["prevent"])},[u("div",null,[C[12]||(C[12]=u("label",{class:"label"},"Nombre",-1)),se(u("input",{"onUpdate:modelValue":C[0]||(C[0]=x=>c.value.nombre=x),required:"",placeholder:"ej: Ventas, Soporte",class:"input"},null,512),[[ge,c.value.nombre]])]),u("div",null,[C[14]||(C[14]=u("label",{class:"label"},"Config de IA",-1)),se(u("select",{"onUpdate:modelValue":C[1]||(C[1]=x=>c.value.ai_config_id=x),class:"input"},[C[13]||(C[13]=u("option",{value:null},"— sin asignar —",-1)),(O(!0),T(le,null,Ae(i.value,x=>(O(),T("option",{key:x.ID,value:x.ID},U(x.nombre)+" ("+U(x.provider)+")",9,df))),128))],512),[[In,c.value.ai_config_id]])]),u("div",null,[C[15]||(C[15]=u("label",{class:"label"},"Tono / personalidad",-1)),se(u("textarea",{"onUpdate:modelValue":C[2]||(C[2]=x=>c.value.tono=x),rows:"2",class:"input"},null,512),[[ge,c.value.tono]])]),u("div",null,[C[16]||(C[16]=u("label",{class:"label"},"Mensaje de bienvenida",-1)),se(u("input",{"onUpdate:modelValue":C[3]||(C[3]=x=>c.value.mensaje_bienvenida=x),class:"input"},null,512),[[ge,c.value.mensaje_bienvenida]])]),u("div",null,[C[17]||(C[17]=u("label",{class:"label"},"Color del widget",-1)),u("div",pf,[se(u("input",{"onUpdate:modelValue":C[4]||(C[4]=x=>c.value.color=x),type:"color",class:"w-10 h-9 border border-gray-300 dark:border-gray-700 rounded cursor-pointer bg-white dark:bg-gray-800"},null,512),[[ge,c.value.color]]),se(u("input",{"onUpdate:modelValue":C[5]||(C[5]=x=>c.value.color=x),type:"text",pattern:"#[0-9a-fA-F]{6}",class:"flex-1 border border-gray-300 dark:border-gray-700 bg-white dark:bg-gray-800 text-gray-800 dark:text-gray-100 rounded-lg px-3 py-2 text-sm font-mono"},null,512),[[ge,c.value.color]])])]),u("label",hf,[se(u("input",{"onUpdate:modelValue":C[6]||(C[6]=x=>c.value.activo=x),type:"checkbox"},null,512),[[Ut,c.value.activo]]),C[18]||(C[18]=Ce(" Activo ",-1))]),u("div",mf,[u("button",{type:"button",class:"px-4 py-2 text-sm text-gray-500 dark:text-gray-400",onClick:C[7]||(C[7]=x=>a.value=!1)},"Cancelar"),u("button",gf,U(d.value?"Guardar":"Crear"),1)])],32)])])):X("",!0)])}}},bf={key:0,class:"mb-6 mt-1"},_f={class:"text-xl font-semibold text-texto"},xf={class:"text-xs text-tenue mt-1"},yf={class:"bg-elevado px-1.5 py-0.5 rounded"},wf={key:1,class:"text-sm text-red-600 dark:text-red-400 mb-4"},Cf={class:"flex gap-1.5 mb-6 overflow-x-auto pb-1"},Ef=["onClick"],Sf={key:2},Af=["disabled"],Rf={class:"card divide-y divide-borde"},If={key:0,class:"p-6 text-sm text-tenue"},kf={class:"text-sm text-texto"},Of={class:"text-xs text-tenue mt-0.5"},Tf={key:0},Pf={key:1,class:"text-red-600 dark:text-red-400"},Nf=["onClick"],$f={key:3},Df={class:"card divide-y divide-borde"},Mf={key:0,class:"p-6 text-sm text-tenue"},Vf={class:"text-sm text-texto font-mono"},jf={class:"label mt-0.5"},Uf={class:"text-xs text-tenue mt-0.5"},Lf={key:0,class:"ml-1 text-green-600 dark:text-green-400"},Ff={key:1,class:"ml-1 text-gray-400"},Hf={class:"flex gap-3 text-sm shrink-0"},Bf=["onClick"],Kf=["onClick"],Gf={class:"card p-6 w-full max-w-xl max-h-[85vh] overflow-y-auto"},qf={class:"font-semibold text-texto mb-4"},Wf={class:"border border-borde rounded-lg p-3 space-y-2"},zf=["onUpdate:modelValue"],Jf=["onUpdate:modelValue"],Yf=["onUpdate:modelValue"],Qf={class:"label flex items-center gap-1"},Xf=["onUpdate:modelValue"],Zf=["onClick"],ed={key:0,class:"text-xs text-gray-400"},td={class:"border border-borde rounded-lg p-3 space-y-2"},nd={class:"flex items-center gap-2 label"},sd={class:"flex items-center gap-2 text-sm text-texto"},od={class:"flex justify-end gap-2 pt-2"},rd={key:4},id={class:"card p-4 mb-4"},ld={class:"flex items-center justify-between mb-2"},ad={class:"bg-elevado border border-borde rounded-lg p-2.5 text-xs text-texto overflow-x-auto"},ud={class:"card divide-y divide-borde"},cd={key:0,class:"p-6 text-sm text-tenue"},fd={class:"flex items-center justify-between"},dd={class:"font-medium text-texto capitalize"},pd={class:"flex gap-3 text-sm"},hd=["onClick"],md=["onClick"],gd={class:"flex gap-4 mt-2 text-xs"},vd={class:"flex items-center gap-1.5 text-texto cursor-pointer"},bd=["checked","onChange"],_d={class:"flex items-center gap-1.5 text-texto cursor-pointer"},xd=["checked","onChange"],yd={class:"label mt-1 break-all"},wd={class:"bg-elevado px-1 rounded"},Cd={key:0,class:"text-xs text-tenue mt-1"},Ed={key:1,class:"text-xs text-red-600 dark:text-red-400 mt-1"},Sd={class:"card p-6 w-full max-w-md"},Ad={key:0},Rd={class:"flex flex-col gap-2 pt-1"},Id={class:"flex items-center gap-2 text-sm text-texto cursor-pointer"},kd={class:"flex items-center gap-2 text-sm text-texto cursor-pointer"},Od={class:"flex justify-end gap-2 pt-2"},Td={key:5},Pd={class:"flex gap-2 mb-4"},Nd={class:"card divide-y divide-borde"},$d={key:0,class:"p-6 text-sm text-tenue"},Dd={class:"font-medium text-texto capitalize"},Md={class:"ml-2 text-sm text-tenue"},Vd=["onClick"],jd={key:6,class:"card p-4 flex flex-col h-[28rem]"},Ud={class:"flex-1 overflow-y-auto space-y-2 mb-3"},Ld={key:0,class:"text-sm text-tenue"},Fd={key:1,class:"text-xs text-tenue"},Hd=["disabled"],Bd={key:7,class:"grid grid-cols-3 gap-4"},Kd={class:"col-span-1 card divide-y divide-borde max-h-[28rem] overflow-y-auto"},Gd={key:0,class:"p-4 text-sm text-tenue"},qd=["onClick"],Wd={class:"text-texto truncate"},zd={class:"text-xs text-tenue mt-0.5"},Jd={class:"col-span-2 card p-4 max-h-[28rem] overflow-y-auto space-y-2"},Yd={key:0,class:"text-sm text-tenue"},Qd={key:8},Xd={class:"card divide-y divide-borde max-h-[32rem] overflow-y-auto"},Zd={key:0,class:"p-6 text-sm text-tenue"},ep={class:"cursor-pointer flex items-center gap-2 text-sm"},tp={class:"text-tenue text-xs shrink-0"},np={class:"text-texto truncate"},sp={class:"text-tenue text-xs ml-auto shrink-0"},op={key:0,class:"mt-2 bg-elevado border border-borde rounded-lg p-2 text-xs text-gray-600 dark:text-gray-400 overflow-x-auto whitespace-pre-wrap"},rp={__name:"AgenteDetail",props:{tenantId:{type:String,required:!0},agenteId:{type:String,required:!0}},setup(e){const t=e,n=ve(()=>Number(t.agenteId)),s=Pi(),o=J(null),r=J(""),i=J(typeof s.query.tab=="string"?s.query.tab:"conocimiento"),l=J([]),a=J(""),d=J(30),c=J(!1);async function h(){const y=await oe.get(ie(`/umind/agentes?tenant_id=${t.tenantId}`));o.value=(y.items||[]).find(g=>String(g.ID)===t.agenteId)||null}async function v(){const y=await oe.get(ie(`/umind/documentos?agente_id=${t.agenteId}`));l.value=y.items||[]}async function _(){if(a.value.trim()){c.value=!0,r.value="";try{await oe.post(ie("/umind/documentos"),{agente_id:n.value,url:a.value.trim(),max_paginas:Number(d.value)||30}),a.value="",await v()}catch(y){r.value=y.message}finally{c.value=!1}}}async function j(y){confirm("¿Eliminar esta fuente y sus fragmentos indexados?")&&(await oe.del(ie(`/umind/documentos/${y}`)),await v())}const P=ve(()=>y=>({listo:"badge-ok",procesando:"badge-alerta",pendiente:"badge-neutro",error:"badge-error"})[y]||"badge-neutro"),K=J([]),V=J([]),C=J(null);async function H(){const y=await oe.get(ie(`/umind/sesiones?agente_id=${t.agenteId}`));K.value=y.items||[]}async function x(y){C.value=y;const g=await oe.get(ie(`/umind/historial?agente_id=${t.agenteId}&session_id=${y}`));V.value=g.items||[]}const R=J([]),M=J(!1),Y=J(null),k=J(ye());function ye(){return{nombre:"",descripcion:"",url:"",auth_header_nombre:"",auth_header_valor:"",tocarAuth:!1,parametros:[],activa:!0}}async function Ue(){const y=await oe.get(ie(`/umind/tools?agente_id=${t.agenteId}`));R.value=y.items||[]}function tt(){Y.value=null,k.value=ye(),M.value=!0}function mt(y){Y.value=y;let g=[];try{g=JSON.parse(y.parametros_json||"[]")||[]}catch{g=[]}k.value={nombre:y.nombre,descripcion:y.descripcion,url:y.url,auth_header_nombre:y.auth_header_nombre,auth_header_valor:"",tocarAuth:!1,parametros:g,activa:y.activa},M.value=!0}function We(){k.value.parametros.push({nombre:"",tipo:"string",descripcion:"",requerido:!1})}function Dt(y){k.value.parametros.splice(y,1)}async function kt(){const y={agente_id:n.value,nombre:k.value.nombre.trim(),descripcion:k.value.descripcion,url:k.value.url.trim(),auth_header_nombre:k.value.auth_header_nombre,parametros:k.value.parametros,activa:k.value.activa};k.value.tocarAuth&&(y.auth_header_valor=k.value.auth_header_valor);try{Y.value?await oe.put(ie(`/umind/tools/${Y.value.ID}`),y):await oe.post(ie("/umind/tools"),y),M.value=!1,await Ue()}catch(g){r.value=g.message}}async function we(y){confirm(`¿Eliminar la tool "${y.nombre}"?`)&&(await oe.del(ie(`/umind/tools/${y.ID}`)),await Ue())}const re=J([]),te=J(!1),ee=J(gt()),He=J(!1),Be=ve(()=>{var g;const y=((g=o.value)==null?void 0:g.site_key)||"TU_SITE_KEY";return`
+