From b125ceef9509fba0bc142f70b99ff000a14335c8 Mon Sep 17 00:00:00 2001 From: Lizandro Guarnizo <77708265+lizandrogd@users.noreply.github.com> Date: Thu, 20 Aug 2026 23:15:28 -0500 Subject: [PATCH] =?UTF-8?q?fix(umind):=20la=20config=20de=20IA=20de=20un?= =?UTF-8?q?=20cliente=20pod=C3=ADa=20atender=20tareas=20del=20sistema?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Auditando el aislamiento apareció el agujero al revés del que se buscaba: no un cliente leyendo datos de otro, sino la cuenta de IA de un cliente pagando trabajo nuestro. GetAiConfigForService recorre las configs activas y devuelve la primera sin módulo asignado. Las configs de cliente no llevan módulo — ninguna lo lleva, es parte del diseño — así que caían justo en ese fallback. Con un cliente que hubiera conectado su cuenta, su clave terminaba clasificando correos de soporte, importando plantillas o atendiendo la vCard. Ninguno de los dos se enteraba: la respuesta llegaba igual y la factura le llegaba a él. Todos los resolvedores globales filtran ahora tenant_id IS NULL. Un test lo verifica sobre el código de cada uno, porque son consultas a base y acá no hay una. El de embeddings además no podía ser de cliente por otra razón: los vectores de todos los agentes tienen que salir del mismo modelo o la similitud coseno entre ellos no significa nada. Un cliente con su propio modelo de embeddings rompía su propia búsqueda sin un solo error visible. Del alcance entre clientes, que era lo que se auditaba: los 39 handlers de uMind validan, y el CRUD de espacios y planes ni siquiera se monta en las rutas del portal. Lo que faltaba era prueba: UmindScopeDe distingue "staff" de "cliente sin espacios" por nil contra slice vacío, y esa diferencia no tenía un solo test. Ahora la cubre uno que además falla si se invierte el fail-closed de una ruta sin scope — probado inyectando las dos fugas. Y dos cosas que quedaban colgando: En /app/ai-config toda config de cliente se mostraba como "Global", que es justo lo que no es. Ahora dice de qué espacio es, por nombre. El consumo de una cuenta propia se registraba con el costo del plan. Se sigue midiendo —el cliente quiere ver cuánto usa su asistente— pero con costo cero y marcado como cuenta propia: cobrarlo también sería cobrar dos veces lo mismo. En la pantalla de consumo aparece "va por tu cuenta de IA" en vez de un "$0" que parecería un error. El OCR y la transcripción siguen costando: son servicios nuestros, los use quien los use. Co-Authored-By: Claude Opus 5 --- orchestrator/src/views/Uso.vue | 7 +- pkg/models/ai_config.go | 25 +++- pkg/models/ai_config_test.go | 47 ++++++- pkg/models/umind.go | 15 +++ pkg/models/umind_uso.go | 32 ++++- .../{index-YAZk1p08.js => index-DN4RTleh.js} | 8 +- ...{index-DjoN7J4s.css => index-Ds3rxNrq.css} | 2 +- public/orchestrator/index.html | 4 +- resources/views/ai_config.html | 11 +- rest/controllers/ai_config_controller.go | 10 ++ rest/middlewares/umind_scope_test.go | 121 ++++++++++++------ 11 files changed, 221 insertions(+), 61 deletions(-) rename public/orchestrator/assets/{index-YAZk1p08.js => index-DN4RTleh.js} (83%) rename public/orchestrator/assets/{index-DjoN7J4s.css => index-Ds3rxNrq.css} (69%) diff --git a/orchestrator/src/views/Uso.vue b/orchestrator/src/views/Uso.vue index c59270b..ee80238 100644 --- a/orchestrator/src/views/Uso.vue +++ b/orchestrator/src/views/Uso.vue @@ -174,7 +174,12 @@ watch(() => props.id, cargar, { immediate: true }) {{ numero(r.cantidad) }} {{ r.unidad }} · {{ numero(r.eventos) }} usos

- {{ money(r.costo) }} + + {{ money(r.costo) }} + + va por tu
cuenta de IA +
diff --git a/pkg/models/ai_config.go b/pkg/models/ai_config.go index a298ba3..47bdef1 100644 --- a/pkg/models/ai_config.go +++ b/pkg/models/ai_config.go @@ -189,7 +189,7 @@ func QuitarAgenteBotSalvo(id uint) { // GetAgenteBotConfig retorna la config marcada como agente Telegram, con su TelegramConfig cargada. func GetAgenteBotConfig() (*AiConfig, *TelegramConfig, error) { var ai AiConfig - if err := app.Http.Database.DB.Where("es_agente_bot = ? AND is_active = ?", true, true).First(&ai).Error; err != nil { + if err := app.Http.Database.DB.Where("es_agente_bot = ? AND is_active = ? AND tenant_id IS NULL", true, true).First(&ai).Error; err != nil { return nil, nil, fmt.Errorf("no hay agente bot configurado: %w", err) } if ai.TelegramConfigID == nil { @@ -207,7 +207,7 @@ func GetAgenteBotConfig() (*AiConfig, *TelegramConfig, error) { // asignado. La usa el chat propio del dashboard para compartir el mismo motor. func GetAgenteBotAiConfig() (*AiConfig, error) { var ai AiConfig - if err := app.Http.Database.DB.Where("es_agente_bot = ? AND is_active = ?", true, true).First(&ai).Error; err != nil { + if err := app.Http.Database.DB.Where("es_agente_bot = ? AND is_active = ? AND tenant_id IS NULL", true, true).First(&ai).Error; err != nil { return nil, fmt.Errorf("no hay agente configurado: %w", err) } return &ai, nil @@ -220,7 +220,15 @@ func GetAgenteBotAiConfig() (*AiConfig, error) { // 3. Cualquier config activa (último recurso) func GetAiConfigForService(service string) (*AiConfig, error) { var items []AiConfig - if err := app.Http.Database.DB.Where("is_active = ?", true).Order("id ASC").Find(&items).Error; err != nil { + // tenant_id IS NULL: las configs de un cliente son SUYAS y solo las usa su + // agente. Sin este filtro, la del cliente que no tiene módulo asignado + // —ninguna lo tiene— caía en el fallback global y terminaba atendiendo + // tareas nuestras: clasificar correos de soporte, importar plantillas, la + // vCard. Es decir, su cuenta pagando nuestro trabajo, sin que se entere + // ninguno de los dos. + if err := app.Http.Database.DB. + Where("is_active = ? AND tenant_id IS NULL", true). + Order("id ASC").Find(&items).Error; err != nil { return nil, fmt.Errorf("error leyendo ai_configs: %w", err) } if len(items) == 0 { @@ -276,7 +284,7 @@ func esConfigDeUsoEspecial(modulo string) bool { // tiene fallback a la global y a cualquier activa. func HayAiConfigParaModulo(modulo string) bool { var items []AiConfig - if err := app.Http.Database.DB.Where("is_active = ?", true).Find(&items).Error; err != nil { + if err := app.Http.Database.DB.Where("is_active = ? AND tenant_id IS NULL", true).Find(&items).Error; err != nil { return false } for i := range items { @@ -296,7 +304,8 @@ func HayAiConfigParaModulo(modulo string) bool { // transcribir contra un proveedor que no soporta ese endpoint (ej. Anthropic). func GetWhisperConfig() (*AiConfig, error) { var items []AiConfig - if err := app.Http.Database.DB.Where("is_active = ?", true).Find(&items).Error; err != nil { + // Solo configs del staff, por lo mismo que GetAiConfigForService. + if err := app.Http.Database.DB.Where("is_active = ? AND tenant_id IS NULL", true).Find(&items).Error; err != nil { return nil, fmt.Errorf("error leyendo ai_configs: %w", err) } for i := range items { @@ -319,7 +328,11 @@ func GetWhisperConfig() (*AiConfig, error) { // en vez de caer a cualquier config activa. func GetUmindEmbeddingsConfig() (*AiConfig, error) { var items []AiConfig - if err := app.Http.Database.DB.Where("is_active = ?", true).Find(&items).Error; err != nil { + // Global obligatoriamente: los vectores de todos los agentes tienen que + // salir del mismo modelo o la similitud coseno entre ellos no significa + // nada. Un cliente con su propio modelo de embeddings rompería su propia + // búsqueda sin ningún error visible. + if err := app.Http.Database.DB.Where("is_active = ? AND tenant_id IS NULL", true).Find(&items).Error; err != nil { return nil, fmt.Errorf("error leyendo ai_configs: %w", err) } for i := range items { diff --git a/pkg/models/ai_config_test.go b/pkg/models/ai_config_test.go index 0b1a90b..91c2084 100644 --- a/pkg/models/ai_config_test.go +++ b/pkg/models/ai_config_test.go @@ -1,6 +1,10 @@ package models -import "testing" +import ( + "os" + "strings" + "testing" +) // El fallback de GetAiConfigForService puede terminar usando una config que no // declara el servicio pedido. Lo que no puede es agarrar una dedicada a @@ -21,3 +25,44 @@ func TestConfigsDeUsoEspecialNoSirvenDeComodin(t *testing.T) { } } } + +// La consulta de todo resolvedor global tiene que excluir las configs de +// cliente. Sin ese filtro, la config que carga un cliente —que no lleva módulo, +// ninguna lo lleva— cae en el fallback y pasa a atender tareas nuestras: +// clasificar correos de soporte, importar plantillas, la vCard. Su cuenta +// pagando nuestro trabajo, y sin que se entere ninguno de los dos. +// +// Se verifica sobre el código porque son consultas a base: acá no hay una. +func TestLosResolvedoresGlobalesExcluyenConfigsDeCliente(t *testing.T) { + fuente, err := os.ReadFile("ai_config.go") + if err != nil { + t.Fatal(err) + } + texto := string(fuente) + + // Toda función que resuelve una config para uso del sistema. + resolvedores := []string{ + "func GetAiConfigForService(", + "func GetWhisperConfig(", + "func GetUmindEmbeddingsConfig(", + "func GetAgenteBotAiConfig(", + "func GetAgenteBotConfig(", + "func HayAiConfigParaModulo(", + } + + for _, firma := range resolvedores { + i := strings.Index(texto, firma) + if i < 0 { + t.Errorf("no encontré %s — ¿se renombró?", firma) + continue + } + // El cuerpo hasta la próxima función de nivel superior. + resto := texto[i+len(firma):] + if j := strings.Index(resto, "\nfunc "); j > 0 { + resto = resto[:j] + } + if !strings.Contains(resto, "tenant_id IS NULL") { + t.Errorf("%s no filtra tenant_id IS NULL: puede devolver la config de un cliente para una tarea del sistema", firma) + } + } +} diff --git a/pkg/models/umind.go b/pkg/models/umind.go index 4313032..38c47c2 100644 --- a/pkg/models/umind.go +++ b/pkg/models/umind.go @@ -150,6 +150,21 @@ type UmindDocumento struct { AutoActualizar bool `json:"auto_actualizar" gorm:"column:auto_actualizar;default:false"` } +// NombresDeTenantsUmind devuelve id → nombre para poder etiquetar cosas que +// solo guardan el id. Una consulta y no una por fila: son pocos y se usan para +// pintar una lista entera. +func NombresDeTenantsUmind() map[uint]string { + var filas []UmindTenant + out := map[uint]string{} + if err := app.Http.Database.DB.Select("id, nombre").Find(&filas).Error; err != nil { + return out + } + for _, f := range filas { + out[f.ID] = f.Nombre + } + return out +} + func (UmindDocumento) TableName() string { return "umind_documentos" } func CreateUmindDocumento(d *UmindDocumento) error { diff --git a/pkg/models/umind_uso.go b/pkg/models/umind_uso.go index 62e906c..9b9ddf0 100644 --- a/pkg/models/umind_uso.go +++ b/pkg/models/umind_uso.go @@ -33,6 +33,11 @@ type UmindUso struct { Moneda string `json:"moneda" gorm:"column:moneda;size:3"` // FacturadoAt null = pendiente de cobrar en el próximo ciclo. FacturadoAt *time.Time `json:"facturado_at" gorm:"column:facturado_at;index"` + // CuentaPropia marca el consumo que salió por la cuenta de IA del propio + // cliente. Se sigue midiendo —quiere ver cuánto usa su asistente— pero con + // costo cero: ya se lo factura su proveedor, y cobrárselo también sería + // cobrar dos veces por lo mismo. + CuentaPropia bool `json:"cuenta_propia" gorm:"column:cuenta_propia;default:false;index"` } func (UmindUso) TableName() string { return "umind_uso" } @@ -55,12 +60,22 @@ func RegistrarUsoUmind(agenteID uint, tipo string, cantidad float64, unidad stri if plan != nil { moneda = plan.Moneda } - costo := costoDeUso(plan, tipo, cantidad) + + // Si el agente corre sobre la cuenta de IA del propio cliente, el consumo + // se registra igual pero no se le cobra: su proveedor ya se lo factura. + // Solo aplica a los tokens de IA — el OCR y la transcripción son nuestros + // servicios, los use quien los use. + propia := tipo == UsoTipoIA && agenteUsaCuentaPropia(agente) + + costo := 0.0 + if !propia { + costo = costoDeUso(plan, tipo, cantidad) + } uso := &UmindUso{ TenantID: agente.TenantID, AgenteID: agenteID, Tipo: tipo, Cantidad: cantidad, Unidad: unidad, - Costo: costo, Moneda: moneda, + Costo: costo, Moneda: moneda, CuentaPropia: propia, } if err := app.Http.Database.DB.Create(uso).Error; err != nil { log.Printf("[UMIND_USO] no se pudo registrar consumo del agente %d (%s %.2f %s): %v", agenteID, tipo, cantidad, unidad, err) @@ -204,3 +219,16 @@ func MarcarUsoFacturadoPorCliente(clienteID uint) { log.Printf("[UMIND_USO] no se pudo marcar como facturado el consumo del cliente %d: %v", clienteID, err) } } + +// agenteUsaCuentaPropia dice si el agente apunta a una config de IA cargada por +// el cliente (con tenant), en vez de a una nuestra. +func agenteUsaCuentaPropia(agente *UmindAgente) bool { + if agente == nil || agente.AiConfigID == nil { + return false + } + var cfg AiConfig + if err := GetAiConfigByID(*agente.AiConfigID, &cfg); err != nil { + return false + } + return cfg.TenantID != nil +} diff --git a/public/orchestrator/assets/index-YAZk1p08.js b/public/orchestrator/assets/index-DN4RTleh.js similarity index 83% rename from public/orchestrator/assets/index-YAZk1p08.js rename to public/orchestrator/assets/index-DN4RTleh.js index 6caa756..eeab5c3 100644 --- a/public/orchestrator/assets/index-YAZk1p08.js +++ b/public/orchestrator/assets/index-DN4RTleh.js @@ -6,15 +6,15 @@ * @vue/reactivity v3.5.41 * (c) 2018-present Yuxi (Evan) You and Vue contributors * @license MIT -**/let Ue;class ll{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&&Ue&&(Ue.active?(this.parent=Ue,this.index=(Ue.scopes||(Ue.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(Ue===this)Ue=this.prevScope;else{let t=Ue;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(Rn){let t=Rn;for(Rn=void 0;t;){const n=t.next;t.next=void 0,t.flags&=-9,t=n}}let e;for(;$n;){let t=$n;for($n=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 Or(e){for(let t=e.deps;t;t=t.nextDep)t.version=-1,t.prevActiveLink=t.dep.activeLink,t.dep.activeLink=t}function Tr(e){let t,n=e.depsTail,s=n;for(;s;){const o=s.prevDep;s.version===-1?(s===n&&(n=o),uo(s),ul(s)):t=s,s.dep.activeLink=s.prevActiveLink,s.prevActiveLink=void 0,s=o}e.deps=t,e.depsTail=n}function Hs(e){for(let t=e.deps;t;t=t.nextDep)if(t.dep.version!==t.version||t.dep.computed&&(Dr(t.dep.computed)||t.dep.version!==t.version))return!0;return!!e._dirty}function Dr(e){if(e.flags&4&&!(e.flags&16)||(e.flags&=-17,e.globalVersion===Dn)||(e.globalVersion=Dn,!e.isSSR&&e.flags&128&&(!e.deps&&!e._dirty||!Hs(e))))return;e.flags|=2;const t=e.dep,n=ye,s=dt;ye=e,dt=!0;try{Or(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{ye=n,dt=s,Tr(e),e.flags&=-3}}function uo(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)uo(r,!0)}!t&&!--n.sc&&n.map&&n.map.delete(n.key)}function ul(e){const{prevDep:t,nextDep:n}=e;t&&(t.nextDep=n,e.prevDep=void 0),n&&(n.prevDep=t,e.nextDep=void 0)}let dt=!0;const Nr=[];function jt(){Nr.push(dt),dt=!1}function Ut(){const e=Nr.pop();dt=e===void 0?!0:e}function Io(e){const{cleanup:t}=e;if(e.cleanup=void 0,t){const n=ye;ye=void 0;try{t()}finally{ye=n}}}let Dn=0;class cl{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 co{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(!ye||!dt||ye===this.computed)return;let n=this.activeLink;if(n===void 0||n.sub!==ye)n=this.activeLink=new cl(ye,this),ye.deps?(n.prevDep=ye.depsTail,ye.depsTail.nextDep=n,ye.depsTail=n):ye.deps=ye.depsTail=n,Mr(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=ye.depsTail,n.nextDep=void 0,ye.depsTail.nextDep=n,ye.depsTail=n,ye.deps===n&&(ye.deps=s)}return n}trigger(t){this.version++,Dn++,this.notify(t)}notify(t){lo();try{for(let n=this.subs;n;n=n.prevSub)n.sub.notify()&&n.sub.dep.notify()}finally{ao()}}}function Mr(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)Mr(s)}const n=e.dep.subs;n!==e&&(e.prevSub=n,n&&(n.nextSub=e)),e.dep.subs=e}}const Bs=new WeakMap,en=Symbol(""),Gs=Symbol(""),Nn=Symbol("");function He(e,t,n){if(dt&&ye){let s=Bs.get(e);s||Bs.set(e,s=new Map);let o=s.get(n);o||(s.set(n,o=new co),o.map=s,o.key=n),o.track()}}function Tt(e,t,n,s,o,r){const i=Bs.get(e);if(!i){Dn++;return}const a=u=>{u&&u.trigger()};if(lo(),t==="clear")i.forEach(a);else{const u=Z(e),d=u&&ro(n);if(u&&n==="length"){const c=Number(s);i.forEach((p,h)=>{(h==="length"||h===Nn||!pt(h)&&h>=c)&&a(p)})}else switch((n!==void 0||i.has(void 0))&&a(i.get(n)),d&&a(i.get(Nn)),t){case"add":u?d&&a(i.get("length")):(a(i.get(en)),un(e)&&a(i.get(Gs)));break;case"delete":u||(a(i.get(en)),un(e)&&a(i.get(Gs)));break;case"set":un(e)&&a(i.get(en));break}}ao()}function on(e){const t=ve(e);return t===e?t:(He(t,"iterate",Nn),at(e)?t:t.map(mt))}function bs(e){return He(e=ve(e),"iterate",Nn),e}function yt(e,t){return Lt(e)?mn(tn(e)?mt(t):t):mt(t)}const dl={__proto__:null,[Symbol.iterator](){return Ps(this,Symbol.iterator,e=>yt(this,e))},concat(...e){return on(this).concat(...e.map(t=>Z(t)?on(t):t))},entries(){return Ps(this,"entries",e=>(e[1]=yt(this,e[1]),e))},every(e,t){return At(this,"every",e,t,void 0,arguments)},filter(e,t){return At(this,"filter",e,t,n=>n.map(s=>yt(this,s)),arguments)},find(e,t){return At(this,"find",e,t,n=>yt(this,n),arguments)},findIndex(e,t){return At(this,"findIndex",e,t,void 0,arguments)},findLast(e,t){return At(this,"findLast",e,t,n=>yt(this,n),arguments)},findLastIndex(e,t){return At(this,"findLastIndex",e,t,void 0,arguments)},forEach(e,t){return At(this,"forEach",e,t,void 0,arguments)},includes(...e){return Os(this,"includes",e)},indexOf(...e){return Os(this,"indexOf",e)},join(e){return on(this).join(e)},lastIndexOf(...e){return Os(this,"lastIndexOf",e)},map(e,t){return At(this,"map",e,t,void 0,arguments)},pop(){return wn(this,"pop")},push(...e){return wn(this,"push",e)},reduce(e,...t){return $o(this,"reduce",e,t)},reduceRight(e,...t){return $o(this,"reduceRight",e,t)},shift(){return wn(this,"shift")},some(e,t){return At(this,"some",e,t,void 0,arguments)},splice(...e){return wn(this,"splice",e)},toReversed(){return on(this).toReversed()},toSorted(e){return on(this).toSorted(e)},toSpliced(...e){return on(this).toSpliced(...e)},unshift(...e){return wn(this,"unshift",e)},values(){return Ps(this,"values",e=>yt(this,e))}};function Ps(e,t,n){const s=bs(e),o=s[t]();return s!==e&&!at(e)&&(o._next=o.next,o.next=()=>{const r=o._next();return r.done||(r.value=n(r.value)),r}),o}const fl=Array.prototype;function At(e,t,n,s,o,r){const i=bs(e),a=i!==e&&!at(e),u=i[t];if(u!==fl[t]){const p=u.apply(e,r);return a?mt(p):p}let d=n;i!==e&&(a?d=function(p,h){return n.call(this,yt(e,p),h,e)}:n.length>2&&(d=function(p,h){return n.call(this,p,h,e)}));const c=u.call(i,d,s);return a&&o?o(c):c}function $o(e,t,n,s){const o=bs(e),r=o!==e&&!at(e);let i=n,a=!1;o!==e&&(r?(a=s.length===0,i=function(d,c,p){return a&&(a=!1,d=yt(e,d)),n.call(this,d,yt(e,c),p,e)}):n.length>3&&(i=function(d,c,p){return n.call(this,d,c,p,e)}));const u=o[t](i,...s);return a?yt(e,u):u}function Os(e,t,n){const s=ve(e);He(s,"iterate",Nn);const o=s[t](...n);return(o===-1||o===!1)&&mo(n[0])?(n[0]=ve(n[0]),s[t](...n)):o}function wn(e,t,n=[]){jt(),lo();const s=ve(e)[t].apply(e,n);return ao(),Ut(),s}const pl=so("__proto__,__v_isRef,__isVue"),Vr=new Set(Object.getOwnPropertyNames(Symbol).filter(e=>e!=="arguments"&&e!=="caller").map(e=>Symbol[e]).filter(pt));function ml(e){pt(e)||(e=String(e));const t=ve(this);return He(t,"has",e),t.hasOwnProperty(e)}class jr{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?kl:qr:r?Fr:Lr).get(t)||Object.getPrototypeOf(t)===Object.getPrototypeOf(s)?t:void 0;const i=Z(t);if(!o){let u;if(i&&(u=dl[n]))return u;if(n==="hasOwnProperty")return ml}const a=Reflect.get(t,n,Ge(t)?t:s);if((pt(n)?Vr.has(n):pl(n))||(o||He(t,"get",n),r))return a;if(Ge(a)){const u=i&&ro(n)?a:a.value;return o&&xe(u)?Ws(u):u}return xe(a)?o?Ws(a):xs(a):a}}class Ur extends jr{constructor(t=!1){super(!1,t)}set(t,n,s,o){let r=t[n];const i=Z(t)&&ro(n);if(!this._isShallow){const d=Lt(r);if(!at(s)&&!Lt(s)&&(r=ve(r),s=ve(s)),!i&&Ge(r)&&!Ge(s))return d||(r.value=s),!0}const a=i?Number(n)e,zn=e=>Reflect.getPrototypeOf(e);function xl(e,t,n){return function(...s){const o=this.__v_raw,r=ve(o),i=un(r),a=e==="entries"||e===Symbol.iterator&&i,u=e==="keys"&&i,d=o[e](...s),c=n?Ks:t?mn:mt;return!t&&He(r,"iterate",u?Gs:en),Fe(Object.create(d),{next(){const{value:p,done:h}=d.next();return h?{value:p,done:h}:{value:a?[c(p[0]),c(p[1])]:c(p),done:h}}})}}function Jn(e){return function(...t){return e==="delete"?!1:e==="clear"?void 0:this}}function _l(e,t){const n={get(o){const r=this.__v_raw,i=ve(r),a=ve(o);e||(Ct(o,a)&&He(i,"get",o),He(i,"get",a));const{has:u}=zn(i),d=t?Ks:e?mn:mt;if(u.call(i,o))return d(r.get(o));if(u.call(i,a))return d(r.get(a));r!==i&&r.get(o)},get size(){const o=this.__v_raw;return!e&&He(ve(o),"iterate",en),o.size},has(o){const r=this.__v_raw,i=ve(r),a=ve(o);return e||(Ct(o,a)&&He(i,"has",o),He(i,"has",a)),o===a?r.has(o):r.has(o)||r.has(a)},forEach(o,r){const i=this,a=i.__v_raw,u=ve(a),d=t?Ks:e?mn:mt;return!e&&He(u,"iterate",en),a.forEach((c,p)=>o.call(r,d(c),d(p),i))}};return Fe(n,e?{add:Jn("add"),set:Jn("set"),delete:Jn("delete"),clear:Jn("clear")}:{add(o){const r=ve(this),i=zn(r),a=ve(o),u=!t&&!at(o)&&!Lt(o)?a:o;return i.has.call(r,u)||Ct(o,u)&&i.has.call(r,o)||Ct(a,u)&&i.has.call(r,a)||(r.add(u),Tt(r,"add",u,u)),this},set(o,r){!t&&!at(r)&&!Lt(r)&&(r=ve(r));const i=ve(this),{has:a,get:u}=zn(i);let d=a.call(i,o);d||(o=ve(o),d=a.call(i,o));const c=u.call(i,o);return i.set(o,r),d?Ct(r,c)&&Tt(i,"set",o,r):Tt(i,"add",o,r),this},delete(o){const r=ve(this),{has:i,get:a}=zn(r);let u=i.call(r,o);u||(o=ve(o),u=i.call(r,o)),a&&a.call(r,o);const d=r.delete(o);return u&&Tt(r,"delete",o,void 0),d},clear(){const o=ve(this),r=o.size!==0,i=o.clear();return r&&Tt(o,"clear",void 0,void 0),i}}),["keys","values","entries",Symbol.iterator].forEach(o=>{n[o]=xl(o,e,t)}),n}function fo(e,t){const n=_l(e,t);return(s,o,r)=>o==="__v_isReactive"?!e:o==="__v_isReadonly"?e:o==="__v_raw"?s:Reflect.get(ge(n,o)&&o in s?n:s,o,r)}const yl={get:fo(!1,!1)},wl={get:fo(!1,!0)},Cl={get:fo(!0,!1)};const Lr=new WeakMap,Fr=new WeakMap,qr=new WeakMap,kl=new WeakMap;function El(e){switch(e){case"Object":case"Array":return 1;case"Map":case"Set":case"WeakMap":case"WeakSet":return 2;default:return 0}}function xs(e){return Lt(e)?e:po(e,!1,vl,yl,Lr)}function Hr(e){return po(e,!1,bl,wl,Fr)}function Ws(e){return po(e,!0,gl,Cl,qr)}function po(e,t,n,s,o){if(!xe(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=El(Yi(e));if(i===0)return e;const a=new Proxy(e,i===2?s:n);return o.set(e,a),a}function tn(e){return Lt(e)?tn(e.__v_raw):!!(e&&e.__v_isReactive)}function Lt(e){return!!(e&&e.__v_isReadonly)}function at(e){return!!(e&&e.__v_isShallow)}function mo(e){return e?!!e.__v_raw:!1}function ve(e){const t=e&&e.__v_raw;return t?ve(t):e}function Sl(e){return!ge(e,"__v_skip")&&Object.isExtensible(e)&&Er(e,"__v_skip",!0),e}const mt=e=>xe(e)?xs(e):e,mn=e=>xe(e)?Ws(e):e;function Ge(e){return e?e.__v_isRef===!0:!1}function G(e){return Br(e,!1)}function Al(e){return Br(e,!0)}function Br(e,t){return Ge(e)?e:new Il(e,t)}class Il{constructor(t,n){this.dep=new co,this.__v_isRef=!0,this.__v_isShallow=!1,this._rawValue=n?t:ve(t),this._value=n?t:mt(t),this.__v_isShallow=n}get value(){return this.dep.track(),this._value}set value(t){const n=this._rawValue,s=this.__v_isShallow||at(t)||Lt(t);t=s?t:ve(t),Ct(t,n)&&(this._rawValue=t,this._value=s?t:mt(t),this.dep.trigger())}}function je(e){return Ge(e)?e.value:e}const $l={get:(e,t,n)=>t==="__v_raw"?e:je(Reflect.get(e,t,n)),set:(e,t,n,s)=>{const o=e[t];return Ge(o)&&!Ge(n)?(o.value=n,!0):Reflect.set(e,t,n,s)}};function Gr(e){return tn(e)?e:new Proxy(e,$l)}class Rl{constructor(t,n,s){this.fn=t,this.setter=n,this._value=void 0,this.dep=new co(this),this.__v_isRef=!0,this.deps=void 0,this.depsTail=void 0,this.flags=16,this.globalVersion=Dn-1,this.next=void 0,this.effect=this,this.__v_isReadonly=!n,this.isSSR=s}notify(){if(this.flags|=16,!(this.flags&8)&&ye!==this)return Pr(this,!0),!0}get value(){const t=this.dep.track();return Dr(this),t&&(t.version=this.dep.version),this._value}set value(t){this.setter&&this.setter(t)}}function Pl(e,t,n=!1){let s,o;return re(e)?s=e:(s=e.get,o=e.set),new Rl(s,o,n)}const Qn={},os=new WeakMap;let Xt;function Ol(e,t=!1,n=Xt){if(n){let s=os.get(n);s||os.set(n,s=[]),s.push(e)}}function Tl(e,t,n=_e){const{immediate:s,deep:o,once:r,scheduler:i,augmentJob:a,call:u}=n,d=k=>o?k:at(k)||o===!1||o===0?Dt(k,1):Dt(k);let c,p,h,_,N=!1,P=!1;if(Ge(e)?(p=()=>e.value,N=at(e)):tn(e)?(p=()=>d(e),N=!0):Z(e)?(P=!0,N=e.some(k=>tn(k)||at(k)),p=()=>e.map(k=>{if(Ge(k))return k.value;if(tn(k))return d(k);if(re(k))return u?u(k,2):k()})):re(e)?t?p=u?()=>u(e,2):e:p=()=>{if(h){jt();try{h()}finally{Ut()}}const k=Xt;Xt=c;try{return u?u(e,3,[_]):e(_)}finally{Xt=k}}:p=kt,t&&o){const k=p,x=o===!0?1/0:o;p=()=>Dt(k(),x)}const W=al(),H=()=>{c.stop(),W&&W.active&&oo(W.effects,c)};if(r&&t){const k=t;t=(...x)=>{const O=k(...x);return H(),O}}let D=P?new Array(e.length).fill(Qn):Qn;const B=k=>{if(!(!(c.flags&1)||!c.dirty&&!k))if(t){const x=c.run();if(k||o||N||(P?x.some((O,U)=>Ct(O,D[U])):Ct(x,D))){h&&h();const O=Xt;Xt=c;try{const U=[x,D===Qn?void 0:P&&D[0]===Qn?[]:D,_];D=x,u?u(t,3,U):t(...U)}finally{Xt=O}}}else c.run()};return a&&a(B),c=new $r(p),c.scheduler=i?()=>i(B,!1):B,_=k=>Ol(k,!1,c),h=c.onStop=()=>{const k=os.get(c);if(k){if(u)u(k,4);else for(const x of k)x();os.delete(c)}},t?s?B(!0):D=c.run():i?i(B.bind(null,!0),!0):c.run(),H.pause=c.pause.bind(c),H.resume=c.resume.bind(c),H.stop=H,H}function Dt(e,t=1/0,n){if(t<=0||!xe(e)||e.__v_skip||(n=n||new Map,(n.get(e)||0)>=t))return e;if(n.set(e,t),t--,Ge(e))Dt(e.value,t,n);else if(Z(e))for(let s=0;s{Dt(s,t,n)});else if(kr(e)){for(const s in e)Dt(e[s],t,n);for(const s of Object.getOwnPropertySymbols(e))Object.prototype.propertyIsEnumerable.call(e,s)&&Dt(e[s],t,n)}return e}/** +**/let Ue;class ll{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&&Ue&&(Ue.active?(this.parent=Ue,this.index=(Ue.scopes||(Ue.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(Ue===this)Ue=this.prevScope;else{let t=Ue;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(Rn){let t=Rn;for(Rn=void 0;t;){const n=t.next;t.next=void 0,t.flags&=-9,t=n}}let e;for(;$n;){let t=$n;for($n=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 Or(e){for(let t=e.deps;t;t=t.nextDep)t.version=-1,t.prevActiveLink=t.dep.activeLink,t.dep.activeLink=t}function Tr(e){let t,n=e.depsTail,s=n;for(;s;){const o=s.prevDep;s.version===-1?(s===n&&(n=o),uo(s),ul(s)):t=s,s.dep.activeLink=s.prevActiveLink,s.prevActiveLink=void 0,s=o}e.deps=t,e.depsTail=n}function Hs(e){for(let t=e.deps;t;t=t.nextDep)if(t.dep.version!==t.version||t.dep.computed&&(Dr(t.dep.computed)||t.dep.version!==t.version))return!0;return!!e._dirty}function Dr(e){if(e.flags&4&&!(e.flags&16)||(e.flags&=-17,e.globalVersion===Dn)||(e.globalVersion=Dn,!e.isSSR&&e.flags&128&&(!e.deps&&!e._dirty||!Hs(e))))return;e.flags|=2;const t=e.dep,n=ye,s=dt;ye=e,dt=!0;try{Or(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{ye=n,dt=s,Tr(e),e.flags&=-3}}function uo(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)uo(r,!0)}!t&&!--n.sc&&n.map&&n.map.delete(n.key)}function ul(e){const{prevDep:t,nextDep:n}=e;t&&(t.nextDep=n,e.prevDep=void 0),n&&(n.prevDep=t,e.nextDep=void 0)}let dt=!0;const Nr=[];function jt(){Nr.push(dt),dt=!1}function Ut(){const e=Nr.pop();dt=e===void 0?!0:e}function Io(e){const{cleanup:t}=e;if(e.cleanup=void 0,t){const n=ye;ye=void 0;try{t()}finally{ye=n}}}let Dn=0;class cl{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 co{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(!ye||!dt||ye===this.computed)return;let n=this.activeLink;if(n===void 0||n.sub!==ye)n=this.activeLink=new cl(ye,this),ye.deps?(n.prevDep=ye.depsTail,ye.depsTail.nextDep=n,ye.depsTail=n):ye.deps=ye.depsTail=n,Mr(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=ye.depsTail,n.nextDep=void 0,ye.depsTail.nextDep=n,ye.depsTail=n,ye.deps===n&&(ye.deps=s)}return n}trigger(t){this.version++,Dn++,this.notify(t)}notify(t){lo();try{for(let n=this.subs;n;n=n.prevSub)n.sub.notify()&&n.sub.dep.notify()}finally{ao()}}}function Mr(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)Mr(s)}const n=e.dep.subs;n!==e&&(e.prevSub=n,n&&(n.nextSub=e)),e.dep.subs=e}}const Bs=new WeakMap,en=Symbol(""),Gs=Symbol(""),Nn=Symbol("");function He(e,t,n){if(dt&&ye){let s=Bs.get(e);s||Bs.set(e,s=new Map);let o=s.get(n);o||(s.set(n,o=new co),o.map=s,o.key=n),o.track()}}function Tt(e,t,n,s,o,r){const i=Bs.get(e);if(!i){Dn++;return}const a=u=>{u&&u.trigger()};if(lo(),t==="clear")i.forEach(a);else{const u=Z(e),d=u&&ro(n);if(u&&n==="length"){const c=Number(s);i.forEach((p,h)=>{(h==="length"||h===Nn||!pt(h)&&h>=c)&&a(p)})}else switch((n!==void 0||i.has(void 0))&&a(i.get(n)),d&&a(i.get(Nn)),t){case"add":u?d&&a(i.get("length")):(a(i.get(en)),un(e)&&a(i.get(Gs)));break;case"delete":u||(a(i.get(en)),un(e)&&a(i.get(Gs)));break;case"set":un(e)&&a(i.get(en));break}}ao()}function on(e){const t=ve(e);return t===e?t:(He(t,"iterate",Nn),at(e)?t:t.map(mt))}function bs(e){return He(e=ve(e),"iterate",Nn),e}function yt(e,t){return Lt(e)?mn(tn(e)?mt(t):t):mt(t)}const dl={__proto__:null,[Symbol.iterator](){return Ps(this,Symbol.iterator,e=>yt(this,e))},concat(...e){return on(this).concat(...e.map(t=>Z(t)?on(t):t))},entries(){return Ps(this,"entries",e=>(e[1]=yt(this,e[1]),e))},every(e,t){return At(this,"every",e,t,void 0,arguments)},filter(e,t){return At(this,"filter",e,t,n=>n.map(s=>yt(this,s)),arguments)},find(e,t){return At(this,"find",e,t,n=>yt(this,n),arguments)},findIndex(e,t){return At(this,"findIndex",e,t,void 0,arguments)},findLast(e,t){return At(this,"findLast",e,t,n=>yt(this,n),arguments)},findLastIndex(e,t){return At(this,"findLastIndex",e,t,void 0,arguments)},forEach(e,t){return At(this,"forEach",e,t,void 0,arguments)},includes(...e){return Os(this,"includes",e)},indexOf(...e){return Os(this,"indexOf",e)},join(e){return on(this).join(e)},lastIndexOf(...e){return Os(this,"lastIndexOf",e)},map(e,t){return At(this,"map",e,t,void 0,arguments)},pop(){return wn(this,"pop")},push(...e){return wn(this,"push",e)},reduce(e,...t){return $o(this,"reduce",e,t)},reduceRight(e,...t){return $o(this,"reduceRight",e,t)},shift(){return wn(this,"shift")},some(e,t){return At(this,"some",e,t,void 0,arguments)},splice(...e){return wn(this,"splice",e)},toReversed(){return on(this).toReversed()},toSorted(e){return on(this).toSorted(e)},toSpliced(...e){return on(this).toSpliced(...e)},unshift(...e){return wn(this,"unshift",e)},values(){return Ps(this,"values",e=>yt(this,e))}};function Ps(e,t,n){const s=bs(e),o=s[t]();return s!==e&&!at(e)&&(o._next=o.next,o.next=()=>{const r=o._next();return r.done||(r.value=n(r.value)),r}),o}const fl=Array.prototype;function At(e,t,n,s,o,r){const i=bs(e),a=i!==e&&!at(e),u=i[t];if(u!==fl[t]){const p=u.apply(e,r);return a?mt(p):p}let d=n;i!==e&&(a?d=function(p,h){return n.call(this,yt(e,p),h,e)}:n.length>2&&(d=function(p,h){return n.call(this,p,h,e)}));const c=u.call(i,d,s);return a&&o?o(c):c}function $o(e,t,n,s){const o=bs(e),r=o!==e&&!at(e);let i=n,a=!1;o!==e&&(r?(a=s.length===0,i=function(d,c,p){return a&&(a=!1,d=yt(e,d)),n.call(this,d,yt(e,c),p,e)}):n.length>3&&(i=function(d,c,p){return n.call(this,d,c,p,e)}));const u=o[t](i,...s);return a?yt(e,u):u}function Os(e,t,n){const s=ve(e);He(s,"iterate",Nn);const o=s[t](...n);return(o===-1||o===!1)&&mo(n[0])?(n[0]=ve(n[0]),s[t](...n)):o}function wn(e,t,n=[]){jt(),lo();const s=ve(e)[t].apply(e,n);return ao(),Ut(),s}const pl=so("__proto__,__v_isRef,__isVue"),Vr=new Set(Object.getOwnPropertyNames(Symbol).filter(e=>e!=="arguments"&&e!=="caller").map(e=>Symbol[e]).filter(pt));function ml(e){pt(e)||(e=String(e));const t=ve(this);return He(t,"has",e),t.hasOwnProperty(e)}class jr{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?kl:qr:r?Fr:Lr).get(t)||Object.getPrototypeOf(t)===Object.getPrototypeOf(s)?t:void 0;const i=Z(t);if(!o){let u;if(i&&(u=dl[n]))return u;if(n==="hasOwnProperty")return ml}const a=Reflect.get(t,n,Ge(t)?t:s);if((pt(n)?Vr.has(n):pl(n))||(o||He(t,"get",n),r))return a;if(Ge(a)){const u=i&&ro(n)?a:a.value;return o&&xe(u)?Ws(u):u}return xe(a)?o?Ws(a):xs(a):a}}class Ur extends jr{constructor(t=!1){super(!1,t)}set(t,n,s,o){let r=t[n];const i=Z(t)&&ro(n);if(!this._isShallow){const d=Lt(r);if(!at(s)&&!Lt(s)&&(r=ve(r),s=ve(s)),!i&&Ge(r)&&!Ge(s))return d||(r.value=s),!0}const a=i?Number(n)e,zn=e=>Reflect.getPrototypeOf(e);function xl(e,t,n){return function(...s){const o=this.__v_raw,r=ve(o),i=un(r),a=e==="entries"||e===Symbol.iterator&&i,u=e==="keys"&&i,d=o[e](...s),c=n?Ks:t?mn:mt;return!t&&He(r,"iterate",u?Gs:en),Fe(Object.create(d),{next(){const{value:p,done:h}=d.next();return h?{value:p,done:h}:{value:a?[c(p[0]),c(p[1])]:c(p),done:h}}})}}function Jn(e){return function(...t){return e==="delete"?!1:e==="clear"?void 0:this}}function _l(e,t){const n={get(o){const r=this.__v_raw,i=ve(r),a=ve(o);e||(Ct(o,a)&&He(i,"get",o),He(i,"get",a));const{has:u}=zn(i),d=t?Ks:e?mn:mt;if(u.call(i,o))return d(r.get(o));if(u.call(i,a))return d(r.get(a));r!==i&&r.get(o)},get size(){const o=this.__v_raw;return!e&&He(ve(o),"iterate",en),o.size},has(o){const r=this.__v_raw,i=ve(r),a=ve(o);return e||(Ct(o,a)&&He(i,"has",o),He(i,"has",a)),o===a?r.has(o):r.has(o)||r.has(a)},forEach(o,r){const i=this,a=i.__v_raw,u=ve(a),d=t?Ks:e?mn:mt;return!e&&He(u,"iterate",en),a.forEach((c,p)=>o.call(r,d(c),d(p),i))}};return Fe(n,e?{add:Jn("add"),set:Jn("set"),delete:Jn("delete"),clear:Jn("clear")}:{add(o){const r=ve(this),i=zn(r),a=ve(o),u=!t&&!at(o)&&!Lt(o)?a:o;return i.has.call(r,u)||Ct(o,u)&&i.has.call(r,o)||Ct(a,u)&&i.has.call(r,a)||(r.add(u),Tt(r,"add",u,u)),this},set(o,r){!t&&!at(r)&&!Lt(r)&&(r=ve(r));const i=ve(this),{has:a,get:u}=zn(i);let d=a.call(i,o);d||(o=ve(o),d=a.call(i,o));const c=u.call(i,o);return i.set(o,r),d?Ct(r,c)&&Tt(i,"set",o,r):Tt(i,"add",o,r),this},delete(o){const r=ve(this),{has:i,get:a}=zn(r);let u=i.call(r,o);u||(o=ve(o),u=i.call(r,o)),a&&a.call(r,o);const d=r.delete(o);return u&&Tt(r,"delete",o,void 0),d},clear(){const o=ve(this),r=o.size!==0,i=o.clear();return r&&Tt(o,"clear",void 0,void 0),i}}),["keys","values","entries",Symbol.iterator].forEach(o=>{n[o]=xl(o,e,t)}),n}function fo(e,t){const n=_l(e,t);return(s,o,r)=>o==="__v_isReactive"?!e:o==="__v_isReadonly"?e:o==="__v_raw"?s:Reflect.get(ge(n,o)&&o in s?n:s,o,r)}const yl={get:fo(!1,!1)},wl={get:fo(!1,!0)},Cl={get:fo(!0,!1)};const Lr=new WeakMap,Fr=new WeakMap,qr=new WeakMap,kl=new WeakMap;function El(e){switch(e){case"Object":case"Array":return 1;case"Map":case"Set":case"WeakMap":case"WeakSet":return 2;default:return 0}}function xs(e){return Lt(e)?e:po(e,!1,vl,yl,Lr)}function Hr(e){return po(e,!1,bl,wl,Fr)}function Ws(e){return po(e,!0,gl,Cl,qr)}function po(e,t,n,s,o){if(!xe(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=El(Yi(e));if(i===0)return e;const a=new Proxy(e,i===2?s:n);return o.set(e,a),a}function tn(e){return Lt(e)?tn(e.__v_raw):!!(e&&e.__v_isReactive)}function Lt(e){return!!(e&&e.__v_isReadonly)}function at(e){return!!(e&&e.__v_isShallow)}function mo(e){return e?!!e.__v_raw:!1}function ve(e){const t=e&&e.__v_raw;return t?ve(t):e}function Sl(e){return!ge(e,"__v_skip")&&Object.isExtensible(e)&&Er(e,"__v_skip",!0),e}const mt=e=>xe(e)?xs(e):e,mn=e=>xe(e)?Ws(e):e;function Ge(e){return e?e.__v_isRef===!0:!1}function G(e){return Br(e,!1)}function Al(e){return Br(e,!0)}function Br(e,t){return Ge(e)?e:new Il(e,t)}class Il{constructor(t,n){this.dep=new co,this.__v_isRef=!0,this.__v_isShallow=!1,this._rawValue=n?t:ve(t),this._value=n?t:mt(t),this.__v_isShallow=n}get value(){return this.dep.track(),this._value}set value(t){const n=this._rawValue,s=this.__v_isShallow||at(t)||Lt(t);t=s?t:ve(t),Ct(t,n)&&(this._rawValue=t,this._value=s?t:mt(t),this.dep.trigger())}}function je(e){return Ge(e)?e.value:e}const $l={get:(e,t,n)=>t==="__v_raw"?e:je(Reflect.get(e,t,n)),set:(e,t,n,s)=>{const o=e[t];return Ge(o)&&!Ge(n)?(o.value=n,!0):Reflect.set(e,t,n,s)}};function Gr(e){return tn(e)?e:new Proxy(e,$l)}class Rl{constructor(t,n,s){this.fn=t,this.setter=n,this._value=void 0,this.dep=new co(this),this.__v_isRef=!0,this.deps=void 0,this.depsTail=void 0,this.flags=16,this.globalVersion=Dn-1,this.next=void 0,this.effect=this,this.__v_isReadonly=!n,this.isSSR=s}notify(){if(this.flags|=16,!(this.flags&8)&&ye!==this)return Pr(this,!0),!0}get value(){const t=this.dep.track();return Dr(this),t&&(t.version=this.dep.version),this._value}set value(t){this.setter&&this.setter(t)}}function Pl(e,t,n=!1){let s,o;return re(e)?s=e:(s=e.get,o=e.set),new Rl(s,o,n)}const Qn={},os=new WeakMap;let Xt;function Ol(e,t=!1,n=Xt){if(n){let s=os.get(n);s||os.set(n,s=[]),s.push(e)}}function Tl(e,t,n=_e){const{immediate:s,deep:o,once:r,scheduler:i,augmentJob:a,call:u}=n,d=k=>o?k:at(k)||o===!1||o===0?Dt(k,1):Dt(k);let c,p,h,_,N=!1,P=!1;if(Ge(e)?(p=()=>e.value,N=at(e)):tn(e)?(p=()=>d(e),N=!0):Z(e)?(P=!0,N=e.some(k=>tn(k)||at(k)),p=()=>e.map(k=>{if(Ge(k))return k.value;if(tn(k))return d(k);if(re(k))return u?u(k,2):k()})):re(e)?t?p=u?()=>u(e,2):e:p=()=>{if(h){jt();try{h()}finally{Ut()}}const k=Xt;Xt=c;try{return u?u(e,3,[_]):e(_)}finally{Xt=k}}:p=kt,t&&o){const k=p,b=o===!0?1/0:o;p=()=>Dt(k(),b)}const W=al(),H=()=>{c.stop(),W&&W.active&&oo(W.effects,c)};if(r&&t){const k=t;t=(...b)=>{const O=k(...b);return H(),O}}let D=P?new Array(e.length).fill(Qn):Qn;const B=k=>{if(!(!(c.flags&1)||!c.dirty&&!k))if(t){const b=c.run();if(k||o||N||(P?b.some((O,U)=>Ct(O,D[U])):Ct(b,D))){h&&h();const O=Xt;Xt=c;try{const U=[b,D===Qn?void 0:P&&D[0]===Qn?[]:D,_];D=b,u?u(t,3,U):t(...U)}finally{Xt=O}}}else c.run()};return a&&a(B),c=new $r(p),c.scheduler=i?()=>i(B,!1):B,_=k=>Ol(k,!1,c),h=c.onStop=()=>{const k=os.get(c);if(k){if(u)u(k,4);else for(const b of k)b();os.delete(c)}},t?s?B(!0):D=c.run():i?i(B.bind(null,!0),!0):c.run(),H.pause=c.pause.bind(c),H.resume=c.resume.bind(c),H.stop=H,H}function Dt(e,t=1/0,n){if(t<=0||!xe(e)||e.__v_skip||(n=n||new Map,(n.get(e)||0)>=t))return e;if(n.set(e,t),t--,Ge(e))Dt(e.value,t,n);else if(Z(e))for(let s=0;s{Dt(s,t,n)});else if(kr(e)){for(const s in e)Dt(e[s],t,n);for(const s of Object.getOwnPropertySymbols(e))Object.prototype.propertyIsEnumerable.call(e,s)&&Dt(e[s],t,n)}return e}/** * @vue/runtime-core v3.5.41 * (c) 2018-present Yuxi (Evan) You and Vue contributors * @license MIT -**/function Hn(e,t,n,s){try{return s?e(...s):e()}catch(o){_s(o,t,n)}}function ht(e,t,n,s){if(re(e)){const o=Hn(e,t,n,s);return o&&wr(o)&&o.catch(r=>{_s(r,t,n)}),o}if(Z(e)){const o=[];for(let r=0;r>>1,o=Qe[s],r=Mn(o);r=Mn(n)?Qe.push(e):Qe.splice(Nl(t),0,e),e.flags|=1,Wr()}}function Wr(){rs||(rs=Kr.then(Jr))}function Ml(e){if(!Z(e))Gt&&e.id===-1?Gt.splice(rn+1,0,e):e.flags&1||(cn.push(e),e.flags|=1);else for(let t=0;tMn(n)-Mn(s));if(cn.length=0,Gt){for(let n=0;ne.id==null?e.flags&2?-1:1/0:e.id;function Jr(e){try{for(_t=0;_t{s._d&&us(-1);const r=is(t),i=Vt.length;let a;try{a=e(...o)}finally{for(let u=Vt.length;u>i;u--)wo();is(r),s._d&&us(1)}return a};return s._n=!0,s._c=!0,s._d=!0,s}function ne(e,t){if(Le===null)return e;const n=Es(Le),s=e.dirs||(e.dirs=[]);for(let o=0;o1)return n&&re(t)?t.call(s&&s.proxy):t}}const Vl=Symbol.for("v-scx"),jl=()=>ft(Vl);function Mt(e,t,n){return Yr(e,t,n)}function Yr(e,t,n=_e){const{immediate:s,deep:o,flush:r,once:i}=n,a=Fe({},n),u=t&&s||!t&&r!=="post";let d;if(Ln){if(r==="sync"){const _=jl();d=_.__watcherHandles||(_.__watcherHandles=[])}else if(!u){const _=()=>{};return _.stop=kt,_.resume=kt,_.pause=kt,_}}const c=Be;a.call=(_,N,P)=>ht(_,c,N,P);let p=!1;r==="post"?a.scheduler=_=>{et(_,c&&c.suspense)}:r!=="sync"&&(p=!0,a.scheduler=(_,N)=>{N?_():vo(_)}),a.augmentJob=_=>{t&&(_.flags|=4),p&&(_.flags|=2,c&&(_.id=c.uid,_.i=c))};const h=Tl(e,t,a);return Ln&&(d?d.push(h):u&&h()),h}function Ul(e,t,n){const s=this.proxy,o=Oe(e)?e.includes(".")?Xr(s,e):()=>s[e]:e.bind(s,s);let r;re(t)?r=t:(r=t.handler,n=t);const i=Bn(this),a=Yr(o,r.bind(s),n);return i(),a}function Xr(e,t){const n=t.split(".");return()=>{let s=e;for(let o=0;oe.__isTeleport,Ts=Symbol("_leaveCb");function Fl(e){let t=e[0];if(e.length>1){for(const n of e)if(n.type!==Et){t=n;break}}return t}function Zr(e){if(!bo(e))return ys(e.type)&&e.children?Fl(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&&re(n.default))return n.default()}}function go(e,t){if(e.shapeFlag&6&&e.component){e.transition=t;const n=e.component.subTree;go(ys(n.type)&&Zr(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 ei(e,t){return re(e)?Fe({name:e.name},t,{setup:e}):e}function ti(e){e.ids=[e.ids[0]+e.ids[2]+++"-",0,0]}function Po(e,t){let n;return!!((n=Object.getOwnPropertyDescriptor(e,t))&&!n.configurable)}const ls=new WeakMap;function Pn(e,t,n,s,o=!1){if(Z(e)){e.forEach((P,W)=>Pn(P,t&&(Z(t)?t[W]:t),n,s,o));return}if(dn(s)&&!o){s.shapeFlag&512&&s.type.__asyncResolved&&s.component.subTree.component&&Pn(e,t,n,s.component.subTree);return}const r=s.shapeFlag&4?Es(s.component):s.el,i=o?null:r,{i:a,r:u}=e,d=t&&t.r,c=a.refs===_e?a.refs={}:a.refs,p=a.setupState,h=ve(p),_=p===_e?yr:P=>Po(c,P)?!1:ge(h,P),N=(P,W)=>!(W&&Po(c,W));if(d!=null&&d!==u){if(Oo(t),Oe(d))c[d]=null,_(d)&&(p[d]=null);else if(Ge(d)){const P=t;N(d,P.k)&&(d.value=null),P.k&&(c[P.k]=null)}}if(re(u))Hn(u,a,12,[i,c]);else{const P=Oe(u),W=Ge(u);if(P||W){const H=()=>{if(e.f){const D=P?_(u)?p[u]:c[u]:N()||!e.k?u.value:c[e.k];if(o)Z(D)&&oo(D,r);else if(Z(D))D.includes(r)||D.push(r);else if(P)c[u]=[r],_(u)&&(p[u]=c[u]);else{const B=[r];N(u,e.k)&&(u.value=B),e.k&&(c[e.k]=B)}}else P?(c[u]=i,_(u)&&(p[u]=i)):W&&(N(u,e.k)&&(u.value=i),e.k&&(c[e.k]=i))};if(i){const D=()=>{H(),ls.delete(e)};D.id=-1,ls.set(e,D),et(D,n)}else Oo(e),H()}}}function Oo(e){const t=ls.get(e);t&&(t.flags|=8,ls.delete(e))}gs().requestIdleCallback;gs().cancelIdleCallback;const dn=e=>!!e.type.__asyncLoader,bo=e=>e.type.__isKeepAlive;function ql(e,t){ni(e,"a",t)}function Hl(e,t){ni(e,"da",t)}function ni(e,t,n=Be){const s=e.__wdc||(e.__wdc=()=>{let o=n;for(;o;){if(o.isDeactivated)return;o=o.parent}return e()});if(ws(t,s,n),n){let o=n.parent;for(;o&&o.parent;)bo(o.parent.vnode)&&Bl(s,t,n,o),o=o.parent}}function Bl(e,t,n,s){const o=ws(t,e,s,!0);si(()=>{oo(s[t],o)},n)}function ws(e,t,n=Be,s=!1){if(n){const o=n[e]||(n[e]=[]),r=t.__weh||(t.__weh=(...i)=>{jt();const a=Bn(n),u=ht(t,n,e,i);return a(),Ut(),u});return s?o.unshift(r):o.push(r),r}}const Ft=e=>(t,n=Be)=>{(!Ln||e==="sp")&&ws(e,(...s)=>t(...s),n)},Gl=Ft("bm"),xo=Ft("m"),Kl=Ft("bu"),Wl=Ft("u"),zl=Ft("bum"),si=Ft("um"),Jl=Ft("sp"),Ql=Ft("rtg"),Yl=Ft("rtc");function Xl(e,t=Be){ws("ec",e,t)}const Zl="components";function yn(e,t){return ta(Zl,e,!0,t)||e}const ea=Symbol.for("v-ndc");function ta(e,t,n=!0,s=!1){const o=Le||Be;if(o){const r=o.type;{const a=La(r,!1);if(a&&(a===t||a===Xe(t)||a===hs(Xe(t))))return r}const i=To(o[e]||r[e],t)||To(o.appContext[e],t);return!i&&s?r:i}}function To(e,t){return e&&(e[t]||e[Xe(t)]||e[hs(Xe(t))])}function Pe(e,t,n,s){let o;const r=n,i=Z(e);if(i||Oe(e)){const a=i&&tn(e);let u=!1,d=!1;a&&(u=!at(e),d=Lt(e),e=bs(e)),o=new Array(e.length);for(let c=0,p=e.length;ct(a,u,void 0,r));else{const a=Object.keys(e);o=new Array(a.length);for(let u=0,d=a.length;u0;return w(),tt(ie,null,[Ce("slot",d,s)],c?-2:64)}let i=e[t];i&&i._c&&(i._d=!1);const a=Vt.length;w();let u;try{const d=i&&oi(i(n)),c=n.key||r||d&&d.key;u=tt(ie,{key:(c&&!pt(c)?c:`_${t}`)+(!d&&s?"_fb":"")},d||(s?s():[]),d&&e._===1?64:-2)}catch(d){for(let c=Vt.length;c>a;c--)wo();throw d}finally{i&&i._c&&(i._d=!0)}return u.scopeId&&(u.slotScopeIds=[u.scopeId+"-s"]),u}function oi(e){return e.some(t=>jn(t)?!(t.type===Et||t.type===ie&&!oi(t.children)):!0)?e:null}const zs=e=>e?Ei(e)?Es(e):zs(e.parent):null,On=Fe(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=>zs(e.parent),$root:e=>zs(e.root),$host:e=>e.ce,$emit:e=>e.emit,$options:e=>ii(e),$forceUpdate:e=>e.f||(e.f=()=>{vo(e.update)}),$nextTick:e=>e.n||(e.n=ho.bind(e.proxy)),$watch:e=>Ul.bind(e)}),Ds=(e,t)=>e!==_e&&!e.__isScriptSetup&&ge(e,t),sa={get({_:e},t){if(t==="__v_skip")return!0;const{ctx:n,setupState:s,data:o,props:r,accessCache:i,type:a,appContext:u}=e;if(t[0]!=="$"){const h=i[t];if(h!==void 0)switch(h){case 1:return s[t];case 2:return o[t];case 4:return n[t];case 3:return r[t]}else{if(Ds(s,t))return i[t]=1,s[t];if(o!==_e&&ge(o,t))return i[t]=2,o[t];if(ge(r,t))return i[t]=3,r[t];if(n!==_e&&ge(n,t))return i[t]=4,n[t];Js&&(i[t]=0)}}const d=On[t];let c,p;if(d)return t==="$attrs"&&He(e.attrs,"get",""),d(e);if((c=a.__cssModules)&&(c=c[t]))return c;if(n!==_e&&ge(n,t))return i[t]=4,n[t];if(p=u.config.globalProperties,ge(p,t))return p[t]},set({_:e},t,n){const{data:s,setupState:o,ctx:r}=e;return Ds(o,t)?(o[t]=n,!0):s!==_e&&ge(s,t)?(s[t]=n,!0):ge(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}},a){let u;return!!(n[a]||e!==_e&&a[0]!=="$"&&ge(e,a)||Ds(t,a)||ge(r,a)||ge(s,a)||ge(On,a)||ge(o.config.globalProperties,a)||(u=i.__cssModules)&&u[a])},defineProperty(e,t,n){return n.get!=null?e._.accessCache[t]=0:ge(n,"value")&&this.set(e,t,n.value,null),Reflect.defineProperty(e,t,n)}};function Do(e){return Z(e)?e.reduce((t,n)=>(t[n]=null,t),{}):e}let Js=!0;function oa(e){const t=ii(e),n=e.proxy,s=e.ctx;Js=!1,t.beforeCreate&&No(t.beforeCreate,e,"bc");const{data:o,computed:r,methods:i,watch:a,provide:u,inject:d,created:c,beforeMount:p,mounted:h,beforeUpdate:_,updated:N,activated:P,deactivated:W,beforeDestroy:H,beforeUnmount:D,destroyed:B,unmounted:k,render:x,renderTracked:O,renderTriggered:U,errorCaptured:L,serverPrefetch:Ae,expose:ee,inheritAttrs:V,components:De,directives:z,filters:Ze}=t;if(d&&ra(d,s,null),i)for(const de in i){const ue=i[de];re(ue)&&(s[de]=ue.bind(n))}if(o){const de=o.call(n,n);xe(de)&&(e.data=xs(de))}if(Js=!0,r)for(const de in r){const ue=r[de],ut=re(ue)?ue.bind(n,n):re(ue.get)?ue.get.bind(n,n):kt,gt=!re(ue)&&re(ue.set)?ue.set.bind(n):kt,Ke=we({get:ut,set:gt});Object.defineProperty(s,de,{enumerable:!0,configurable:!0,get:()=>Ke.value,set:Te=>Ke.value=Te})}if(a)for(const de in a)ri(a[de],s,n,de);if(u){const de=re(u)?u.call(n):u;Reflect.ownKeys(de).forEach(ue=>{ts(ue,de[ue])})}c&&No(c,e,"c");function Se(de,ue){Z(ue)?ue.forEach(ut=>de(ut.bind(n))):ue&&de(ue.bind(n))}if(Se(Gl,p),Se(xo,h),Se(Kl,_),Se(Wl,N),Se(ql,P),Se(Hl,W),Se(Xl,L),Se(Yl,O),Se(Ql,U),Se(zl,D),Se(si,k),Se(Jl,Ae),Z(ee))if(ee.length){const de=e.exposed||(e.exposed={});ee.forEach(ue=>{Object.defineProperty(de,ue,{get:()=>n[ue],set:ut=>n[ue]=ut,enumerable:!0})})}else e.exposed||(e.exposed={});x&&e.render===kt&&(e.render=x),V!=null&&(e.inheritAttrs=V),De&&(e.components=De),z&&(e.directives=z),Ae&&ti(e)}function ra(e,t,n=kt){Z(e)&&(e=Qs(e));for(const s in e){const o=e[s];let r;xe(o)?"default"in o?r=ft(o.from||s,o.default,!0):r=ft(o.from||s):r=ft(o),Ge(r)?Object.defineProperty(t,s,{enumerable:!0,configurable:!0,get:()=>r.value,set:i=>r.value=i}):t[s]=r}}function No(e,t,n){ht(Z(e)?e.map(s=>s.bind(t.proxy)):e.bind(t.proxy),t,n)}function ri(e,t,n,s){let o=s.includes(".")?Xr(n,s):()=>n[s];if(Oe(e)){const r=t[e];re(r)&&Mt(o,r)}else if(re(e))Mt(o,e.bind(n));else if(xe(e))if(Z(e))e.forEach(r=>ri(r,t,n,s));else{const r=re(e.handler)?e.handler.bind(n):t[e.handler];re(r)&&Mt(o,r,e)}}function ii(e){const t=e.type,{mixins:n,extends:s}=t,{mixins:o,optionsCache:r,config:{optionMergeStrategies:i}}=e.appContext,a=r.get(t);let u;return a?u=a:!o.length&&!n&&!s?u=t:(u={},o.length&&o.forEach(d=>as(u,d,i,!0)),as(u,t,i)),xe(t)&&r.set(t,u),u}function as(e,t,n,s=!1){const{mixins:o,extends:r}=t;r&&as(e,r,n,!0),o&&o.forEach(i=>as(e,i,n,!0));for(const i in t)if(!(s&&i==="expose")){const a=ia[i]||n&&n[i];e[i]=a?a(e[i],t[i]):t[i]}return e}const ia={data:Mo,props:Vo,emits:Vo,methods:En,computed:En,beforeCreate:ze,created:ze,beforeMount:ze,mounted:ze,beforeUpdate:ze,updated:ze,beforeDestroy:ze,beforeUnmount:ze,destroyed:ze,unmounted:ze,activated:ze,deactivated:ze,errorCaptured:ze,serverPrefetch:ze,components:En,directives:En,watch:aa,provide:Mo,inject:la};function Mo(e,t){return t?e?function(){return Fe(re(e)?e.call(this,this):e,re(t)?t.call(this,this):t)}:t:e}function la(e,t){return En(Qs(e),Qs(t))}function Qs(e){if(Z(e)){const t={};for(let n=0;nt==="modelValue"||t==="model-value"?e.modelModifiers:e[`${t}Modifiers`]||e[`${Xe(t)}Modifiers`]||e[`${sn(t)}Modifiers`];function fa(e,t,...n){if(e.isUnmounted)return;const s=e.vnode.props||_e;let o=n;const r=t.startsWith("update:"),i=r&&da(s,t.slice(7));i&&(i.trim&&(o=n.map(c=>Oe(c)?c.trim():c)),i.number&&(o=n.map(vs)));let a,u=s[a=Is(t)]||s[a=Is(Xe(t))];!u&&r&&(u=s[a=Is(sn(t))]),u&&ht(u,e,6,o);const d=s[a+"Once"];if(d){if(!e.emitted)e.emitted={};else if(e.emitted[a])return;e.emitted[a]=!0,ht(d,e,6,o)}}const pa=new WeakMap;function ai(e,t,n=!1){const s=n?pa:t.emitsCache,o=s.get(e);if(o!==void 0)return o;const r=e.emits;let i={},a=!1;if(!re(e)){const u=d=>{const c=ai(d,t,!0);c&&(a=!0,Fe(i,c))};!n&&t.mixins.length&&t.mixins.forEach(u),e.extends&&u(e.extends),e.mixins&&e.mixins.forEach(u)}return!r&&!a?(xe(e)&&s.set(e,null),null):(Z(r)?r.forEach(u=>i[u]=null):Fe(i,r),xe(e)&&s.set(e,i),i)}function Cs(e,t){return!e||!fs(t)?!1:(t=t.slice(2),t=t==="Once"?t:t.replace(/Once$/,""),ge(e,t[0].toLowerCase()+t.slice(1))||ge(e,sn(t))||ge(e,t))}function jo(e){const{type:t,vnode:n,proxy:s,withProxy:o,propsOptions:[r],slots:i,attrs:a,emit:u,render:d,renderCache:c,props:p,data:h,setupState:_,ctx:N,inheritAttrs:P}=e,W=is(e);let H,D;try{if(n.shapeFlag&4){const k=o||s,x=k;H=wt(d.call(x,k,c,p,_,h,N)),D=a}else{const k=t;H=wt(k.length>1?k(p,{attrs:a,slots:i,emit:u}):k(p,null)),D=t.props?a:ma(a)}}catch(k){Vt.length=0,_s(k,e,1),H=Ce(Et)}let B=H;if(D&&P!==!1){const k=Object.keys(D),{shapeFlag:x}=B;k.length&&x&7&&(r&&k.some(ps)&&(D=ha(D,r)),B=hn(B,D,!1,!0))}if(n.dirs&&(B=hn(B,null,!1,!0),B.dirs=B.dirs?B.dirs.concat(n.dirs):n.dirs),n.transition){const k=ys(B.type)&&Zr(B)||B;go(k,n.transition)}return H=B,is(W),H}const ma=e=>{let t;for(const n in e)(n==="class"||n==="style"||fs(n))&&((t||(t={}))[n]=e[n]);return t},ha=(e,t)=>{const n={};for(const s in e)(!ps(s)||!(s.slice(9)in t))&&(n[s]=e[s]);return n};function va(e,t,n){const{props:s,children:o,component:r}=e,{props:i,children:a,patchFlag:u}=t,d=r.emitsOptions;if(t.dirs||t.transition)return!0;if(n&&u>=0){if(u&1024)return!0;if(u&16)return s?Uo(s,i,d):!!i;if(u&8){const c=t.dynamicProps;for(let p=0;pObject.create(ci),fi=e=>Object.getPrototypeOf(e)===ci;function ba(e,t,n,s=!1){const o={},r=di();e.propsDefaults=Object.create(null),pi(e,t,o,r);for(const i in e.propsOptions[0])i in o||(o[i]=void 0);n?e.props=s?o:Hr(o):e.type.props?e.props=o:e.props=r,e.attrs=r}function xa(e,t,n,s){const{props:o,attrs:r,vnode:{patchFlag:i}}=e,a=ve(o),[u]=e.propsOptions;let d=!1;if((s||i>0)&&!(i&16)){if(i&8){const c=e.vnode.dynamicProps;for(let p=0;p{u=!0;const[h,_]=mi(p,t,!0);Fe(i,h),_&&a.push(..._)};!n&&t.mixins.length&&t.mixins.forEach(c),e.extends&&c(e.extends),e.mixins&&e.mixins.forEach(c)}if(!r&&!u)return xe(e)&&s.set(e,an),an;if(Z(r))for(let c=0;ce==="_"||e==="_ctx"||e==="$stable",yo=e=>Z(e)?e.map(wt):[wt(e)],ya=(e,t,n)=>{if(t._n)return t;const s=ct((...o)=>yo(t(...o)),n);return s._c=!1,s},hi=(e,t,n)=>{const s=e._ctx;for(const o in e){if(_o(o))continue;const r=e[o];if(re(r))t[o]=ya(o,r,s);else if(r!=null){const i=yo(r);t[o]=()=>i}}},vi=(e,t)=>{const n=yo(t);e.slots.default=()=>n},gi=(e,t,n)=>{for(const s in t)(n||!_o(s))&&(e[s]=t[s])},wa=(e,t,n)=>{const s=e.slots=di();if(e.vnode.shapeFlag&32){const o=t._;o?(gi(s,t,n),n&&Er(s,"_",o,!0)):hi(t,s)}else t&&vi(e,t)},Ca=(e,t,n)=>{const{vnode:s,slots:o}=e;let r=!0,i=_e;if(s.shapeFlag&32){const a=t._;a?n&&a===1?r=!1:gi(o,t,n):(r=!t.$stable,hi(t,o)),i=t}else t&&(vi(e,t),i={default:1});if(r)for(const a in o)!_o(a)&&i[a]==null&&delete o[a]},et=Ia;function ka(e){return Ea(e)}function Ea(e,t){const n=gs();n.__VUE__=!0;const{insert:s,remove:o,patchProp:r,createElement:i,createText:a,createComment:u,setText:d,setElementText:c,parentNode:p,nextSibling:h,setScopeId:_=kt,insertStaticContent:N}=e,P=(f,m,g,y=null,A=null,E=null,j=void 0,M=null,T=!!m.dynamicChildren)=>{if(f===m)return;f&&!Cn(f,m)&&(y=S(f),Te(f,A,E,!0),f=null),m.patchFlag===-2&&(T=!1,m.dynamicChildren=null);const{type:$,ref:X,shapeFlag:q}=m;switch($){case ks:W(f,m,g,y);break;case Et:H(f,m,g,y);break;case ns:f==null&&D(m,g,y,j);break;case ie:De(f,m,g,y,A,E,j,M,T);break;default:q&1?x(f,m,g,y,A,E,j,M,T):q&6?z(f,m,g,y,A,E,j,M,T):(q&64||q&128)&&$.process(f,m,g,y,A,E,j,M,T,Y)}X!=null&&A?Pn(X,f&&f.ref,E,m||f,!m):X==null&&f&&f.ref!=null&&Pn(f.ref,null,E,f,!0)},W=(f,m,g,y)=>{if(f==null)s(m.el=a(m.children),g,y);else{const A=m.el=f.el;m.children!==f.children&&d(A,m.children)}},H=(f,m,g,y)=>{f==null?s(m.el=u(m.children||""),g,y):m.el=f.el},D=(f,m,g,y)=>{[f.el,f.anchor]=N(f.children,m,g,y,f.el,f.anchor)},B=({el:f,anchor:m},g,y)=>{let A;for(;f&&f!==m;)A=h(f),s(f,g,y),f=A;s(m,g,y)},k=({el:f,anchor:m})=>{let g;for(;f&&f!==m;)g=h(f),o(f),f=g;o(m)},x=(f,m,g,y,A,E,j,M,T)=>{if(m.type==="svg"?j="svg":m.type==="math"&&(j="mathml"),f==null)O(m,g,y,A,E,j,M,T);else{const $=f.el&&f.el._isVueCE?f.el:null;try{$&&$._beginPatch(),Ae(f,m,A,E,j,M,T)}finally{$&&$._endPatch()}}},O=(f,m,g,y,A,E,j,M)=>{let T,$;const{props:X,shapeFlag:q,transition:Q,dirs:te}=f;if(T=f.el=i(f.type,E,X&&X.is,X),q&8?c(T,f.children):q&16&&L(f.children,T,null,y,A,Ns(f,E),j,M),te&&Qt(f,null,y,"created"),U(T,f,f.scopeId,j,y),X){for(const be in X)be!=="value"&&!In(be)&&r(T,be,null,X[be],E,y);"value"in X&&r(T,"value",null,X.value,E),($=X.onVnodeBeforeMount)&&xt($,y,f)}te&&Qt(f,null,y,"beforeMount");const ce=Sa(A,Q);ce&&Q.beforeEnter(T),s(T,m,g),(($=X&&X.onVnodeMounted)||ce||te)&&et(()=>{try{$&&xt($,y,f),ce&&Q.enter(T),te&&Qt(f,null,y,"mounted")}finally{}},A)},U=(f,m,g,y,A)=>{if(g&&_(f,g),y)for(let E=0;E{for(let $=T;${const M=m.el=f.el;let{patchFlag:T,dynamicChildren:$,dirs:X}=m;T|=f.patchFlag&16;const q=f.props||_e,Q=m.props||_e;let te;if(g&&Yt(g,!1),(te=Q.onVnodeBeforeUpdate)&&xt(te,g,m,f),X&&Qt(m,f,g,"beforeUpdate"),g&&Yt(g,!0),$&&(!f.dynamicChildren||f.dynamicChildren.length!==$.length)&&(T=0,j=!1,$=null),(q.innerHTML&&Q.innerHTML==null||q.textContent&&Q.textContent==null)&&c(M,""),$?ee(f.dynamicChildren,$,M,g,y,Ns(m,A),E):j||ue(f,m,M,null,g,y,Ns(m,A),E,!1),T>0){if(T&16)V(M,q,Q,g,A);else if(T&2&&q.class!==Q.class&&r(M,"class",null,Q.class,A),T&4&&r(M,"style",q.style,Q.style,A),T&8){const ce=m.dynamicProps;for(let be=0;be{te&&xt(te,g,m,f),X&&Qt(m,f,g,"updated")},y)},ee=(f,m,g,y,A,E,j)=>{for(let M=0;M{if(m!==g){if(m!==_e)for(const E in m)!In(E)&&!(E in g)&&r(f,E,m[E],null,A,y);for(const E in g){if(In(E))continue;const j=g[E],M=m[E];j!==M&&E!=="value"&&r(f,E,M,j,A,y)}"value"in g&&r(f,"value",m.value,g.value,A)}},De=(f,m,g,y,A,E,j,M,T)=>{const $=m.el=f?f.el:a(""),X=m.anchor=f?f.anchor:a("");let{patchFlag:q,dynamicChildren:Q,slotScopeIds:te}=m;te&&(M=M?M.concat(te):te),f==null?(s($,g,y),s(X,g,y),L(m.children||[],g,X,A,E,j,M,T)):q>0&&q&64&&Q&&f.dynamicChildren&&f.dynamicChildren.length===Q.length?(ee(f.dynamicChildren,Q,g,A,E,j,M),(m.key!=null||A&&m===A.subTree)&&bi(f,m,!0)):ue(f,m,g,X,A,E,j,M,T)},z=(f,m,g,y,A,E,j,M,T)=>{m.slotScopeIds=M,f==null?m.shapeFlag&512?A.ctx.activate(m,g,y,j,T):Ze(m,g,y,A,E,j,T):qt(f,m,T)},Ze=(f,m,g,y,A,E,j)=>{const M=f.component=Da(f,y,A);if(bo(f)&&(M.ctx.renderer=Y),Ma(M,!1,j),M.asyncDep){if(A&&A.registerDep(M,Se,j),!f.el){const T=M.subTree=Ce(Et);H(null,T,m,g),f.placeholder=T.el}}else Se(M,f,m,g,A,E,j)},qt=(f,m,g)=>{const y=m.component=f.component;if(va(f,m,g))if(y.asyncDep&&!y.asyncResolved){de(y,m,g);return}else y.next=m,y.update();else m.el=f.el,y.vnode=m},Se=(f,m,g,y,A,E,j)=>{const M=()=>{if(f.isMounted){let{next:q,bu:Q,u:te,parent:ce,vnode:be}=f;{const ot=xi(f);if(ot){q&&(q.el=be.el,de(f,q,j)),ot.asyncDep.then(()=>{et(()=>{f.isUnmounted||$()},A)});return}}let me=q,Ie;Yt(f,!1),q?(q.el=be.el,de(f,q,j)):q=be,Q&&es(Q),(Ie=q.props&&q.props.onVnodeBeforeUpdate)&&xt(Ie,ce,q,be),Yt(f,!0);const $e=jo(f),st=f.subTree;f.subTree=$e,P(st,$e,p(st.el),S(st),f,A,E),q.el=$e.el,me===null&&ga(f,$e.el),te&&et(te,A),(Ie=q.props&&q.props.onVnodeUpdated)&&et(()=>xt(Ie,ce,q,be),A)}else{let q;const{el:Q,props:te}=m,{bm:ce,m:be,parent:me,root:Ie,type:$e}=f,st=dn(m);Yt(f,!1),ce&&es(ce),!st&&(q=te&&te.onVnodeBeforeMount)&&xt(q,me,m),Yt(f,!0);{Ie.ce&&Ie.ce._hasShadowRoot()&&Ie.ce._injectChildStyle($e,f.parent?f.parent.type:void 0);const ot=f.subTree=jo(f);P(null,ot,g,y,f,A,E),m.el=ot.el}if(be&&et(be,A),!st&&(q=te&&te.onVnodeMounted)){const ot=m;et(()=>xt(q,me,ot),A)}(m.shapeFlag&256||me&&dn(me.vnode)&&me.vnode.shapeFlag&256)&&f.a&&et(f.a,A),f.isMounted=!0,m=g=y=null}};f.scope.on();const T=f.effect=new $r(M);f.scope.off();const $=f.update=T.run.bind(T),X=f.job=T.runIfDirty.bind(T);X.i=f,X.id=f.uid,T.scheduler=()=>vo(X),Yt(f,!0),$()},de=(f,m,g)=>{m.component=f;const y=f.vnode.props;f.vnode=m,f.next=null,xa(f,m.props,y,g),Ca(f,m.children,g),jt(),Ro(f),Ut()},ue=(f,m,g,y,A,E,j,M,T=!1)=>{const $=f&&f.children,X=f?f.shapeFlag:0,q=m.children,{patchFlag:Q,shapeFlag:te}=m;if(Q>0){if(Q&128){gt($,q,g,y,A,E,j,M,T);return}else if(Q&256){ut($,q,g,y,A,E,j,M,T);return}}te&8?(X&16&&qe($,A,E),q!==$&&c(g,q)):X&16?te&16?gt($,q,g,y,A,E,j,M,T):qe($,A,E,!0):(X&8&&c(g,""),te&16&&L(q,g,y,A,E,j,M,T))},ut=(f,m,g,y,A,E,j,M,T)=>{f=f||an,m=m||an;const $=f.length,X=m.length,q=Math.min($,X);let Q;for(Q=0;QX?qe(f,A,E,!0,!1,q):L(m,g,y,A,E,j,M,T,q)},gt=(f,m,g,y,A,E,j,M,T)=>{let $=0;const X=m.length;let q=f.length-1,Q=X-1;for(;$<=q&&$<=Q;){const te=f[$],ce=m[$]=T?Pt(m[$]):wt(m[$]);if(Cn(te,ce))P(te,ce,g,null,A,E,j,M,T);else break;$++}for(;$<=q&&$<=Q;){const te=f[q],ce=m[Q]=T?Pt(m[Q]):wt(m[Q]);if(Cn(te,ce))P(te,ce,g,null,A,E,j,M,T);else break;q--,Q--}if($>q){if($<=Q){const te=Q+1,ce=teQ)for(;$<=q;)Te(f[$],A,E,!0),$++;else{const te=$,ce=$,be=new Map;for($=ce;$<=Q;$++){const Ne=m[$]=T?Pt(m[$]):wt(m[$]);Ne.key!=null&&be.set(Ne.key,$)}let me,Ie=0;const $e=Q-ce+1;let st=!1,ot=0;const Jt=new Array($e);for($=0;$<$e;$++)Jt[$]=0;for($=te;$<=q;$++){const Ne=f[$];if(Ie>=$e){Te(Ne,A,E,!0);continue}let We;if(Ne.key!=null)We=be.get(Ne.key);else for(me=ce;me<=Q;me++)if(Jt[me-ce]===0&&Cn(Ne,m[me])){We=me;break}We===void 0?Te(Ne,A,E,!0):(Jt[We-ce]=$+1,We>=ot?ot=We:st=!0,P(Ne,m[We],g,null,A,E,j,M,T),Ie++)}const Gn=st?Aa(Jt):an;for(me=Gn.length-1,$=$e-1;$>=0;$--){const Ne=ce+$,We=m[Ne],Ht=m[Ne+1],Kn=Ne+1{const{el:E,type:j,transition:M,children:T,shapeFlag:$}=f;if($&6){Ke(f.component.subTree,m,g,y);return}if($&128){f.suspense.move(m,g,y);return}if($&64){j.move(f,m,g,Y);return}if(j===ie){s(E,m,g);for(let q=0;qM.enter(E),A));else{const{leave:q,delayLeave:Q,afterLeave:te}=M,ce=()=>{f.ctx.isUnmounted?o(E):s(E,m,g)},be=()=>{const me=E._isLeaving||!!E[Ts];E._isLeaving&&E[Ts](!0),M.persisted&&!me?ce():q(E,()=>{ce(),te&&te()})};Q?Q(E,ce,be):be()}else s(E,m,g)},Te=(f,m,g,y=!1,A=!1)=>{const{type:E,props:j,ref:M,children:T,dynamicChildren:$,shapeFlag:X,patchFlag:q,dirs:Q,cacheIndex:te,memo:ce}=f;if(q===-2&&(A=!1),M!=null&&(jt(),Pn(M,null,g,f,!0),Ut()),te!=null&&(m.renderCache[te]=void 0),X&256){m.ctx.deactivate(f);return}const be=X&1&&Q,me=!dn(f);let Ie;if(me&&(Ie=j&&j.onVnodeBeforeUnmount)&&xt(Ie,m,f),X&6)bt(f.component,g,y);else{if(X&128){f.suspense.unmount(g,y);return}be&&Qt(f,null,m,"beforeUnmount"),X&64?f.type.remove(f,m,g,Y,y):$&&!$.hasOnce&&(E!==ie||q>0&&q&64)?qe($,m,g,!1,!0):(E===ie&&q&384||!A&&X&16)&&qe(T,m,g),y&&nt(f)}const $e=ce!=null&&te==null;(me&&(Ie=j&&j.onVnodeUnmounted)||be||$e)&&et(()=>{Ie&&xt(Ie,m,f),be&&Qt(f,null,m,"unmounted"),$e&&(f.el=null)},g)},nt=f=>{const{type:m,el:g,anchor:y,transition:A}=f;if(m===ie){le(g,y);return}if(m===ns){k(f);return}const E=()=>{o(g),A&&!A.persisted&&A.afterLeave&&A.afterLeave()};if(f.shapeFlag&1&&A&&!A.persisted){const{leave:j,delayLeave:M}=A,T=()=>j(g,E);M?M(f.el,E,T):T()}else E()},le=(f,m)=>{let g;for(;f!==m;)g=h(f),o(f),f=g;o(m)},bt=(f,m,g)=>{const{bum:y,scope:A,job:E,subTree:j,um:M,m:T,a:$}=f;Fo(T),Fo($),y&&es(y),A.stop(),E&&(E.flags|=8,Te(j,f,m,g)),M&&et(M,m),et(()=>{f.isUnmounted=!0},m)},qe=(f,m,g,y=!1,A=!1,E=0)=>{for(let j=E;j{if(f.shapeFlag&6)return S(f.component.subTree);if(f.shapeFlag&128)return f.suspense.next();const m=h(f.anchor||f.el),g=m&&m[Ll];return g?h(g):m};let K=!1;const F=(f,m,g)=>{let y;f==null?m._vnode&&(Te(m._vnode,null,null,!0),y=m._vnode.component):P(m._vnode||null,f,m,null,null,null,g),m._vnode=f,K||(K=!0,Ro(y),zr(),K=!1)},Y={p:P,um:Te,m:Ke,r:nt,mt:Ze,mc:L,pc:ue,pbc:ee,n:S,o:e};return{render:F,hydrate:void 0,createApp:ca(F)}}function Ns({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 Yt({effect:e,job:t},n){n?(e.flags|=32,t.flags|=4):(e.flags&=-33,t.flags&=-5)}function Sa(e,t){return(!e||e&&!e.pendingBranch)&&t&&!t.persisted}function bi(e,t,n=!1){const s=e.children,o=t.children;if(Z(s)&&Z(o))for(let r=0;r>1,e[n[a]]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 xi(e){const t=e.subTree.component;if(t)return t.asyncDep&&!t.asyncResolved?t:xi(t)}function Fo(e){if(e)for(let t=0;te.__isSuspense;function Ia(e,t){t&&t.pendingBranch?Z(e)?t.effects.push(...e):t.effects.push(e):Ml(e)}const ie=Symbol.for("v-fgt"),ks=Symbol.for("v-txt"),Et=Symbol.for("v-cmt"),ns=Symbol.for("v-stc"),Vt=[];let rt=null;function w(e=!1){Vt.push(rt=e?null:[])}function wo(){Vt.pop(),rt=Vt[Vt.length-1]||null}let Vn=1;function us(e,t=!1){Vn+=e,e<0&&rt&&t&&(rt.hasOnce=!0)}function wi(e){return e.dynamicChildren=Vn>0?rt||an:null,wo(),Vn>0&&rt&&rt.push(e),e}function C(e,t,n,s,o,r){return wi(l(e,t,n,s,o,r,!0))}function tt(e,t,n,s,o){return wi(Ce(e,t,n,s,o,!0))}function jn(e){return e?e.__v_isVNode===!0:!1}function Cn(e,t){return e.type===t.type&&e.key===t.key}const Ci=({key:e})=>e??null,ss=({ref:e,ref_key:t,ref_for:n})=>(typeof e=="number"&&(e=""+e),e!=null?Oe(e)||Ge(e)||re(e)?{i:Le,r:e,k:t,f:!!n}:e:null);function l(e,t=null,n=null,s=0,o=null,r=e===ie?0:1,i=!1,a=!1){const u={__v_isVNode:!0,__v_skip:!0,type:e,props:t,key:t&&Ci(t),ref:t&&ss(t),scopeId:Qr,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:Le};return a?(cs(u,n),r&128&&e.normalize(u)):n&&(u.shapeFlag|=Oe(n)?8:16),Vn>0&&!i&&rt&&(u.patchFlag>0||r&6)&&u.patchFlag!==32&&rt.push(u),u}const Ce=$a;function $a(e,t=null,n=null,s=0,o=null,r=!1){if((!e||e===ea)&&(e=Et),jn(e)){const a=hn(e,t,!0);return n&&cs(a,n),Vn>0&&!r&&rt&&(a.shapeFlag&6?rt[rt.indexOf(e)]=a:rt.push(a)),a.patchFlag=-2,a}if(Fa(e)&&(e=e.__vccOpts),t){t=Ra(t);let{class:a,style:u}=t;a&&!Oe(a)&&(t.class=Ee(a)),xe(u)&&(mo(u)&&!Z(u)&&(u=Fe({},u)),t.style=nn(u))}const i=Oe(e)?1:yi(e)?128:ys(e)?64:xe(e)?4:re(e)?2:0;return l(e,t,n,s,o,i,r,!0)}function Ra(e){return e?mo(e)||fi(e)?Fe({},e):e:null}function hn(e,t,n=!1,s=!1){const{props:o,ref:r,patchFlag:i,children:a,transition:u}=e,d=t?Pa(o||{},t):o,c={__v_isVNode:!0,__v_skip:!0,type:e.type,props:d,key:d&&Ci(d),ref:t&&t.ref?n&&r?Z(r)?r.concat(ss(t)):[r,ss(t)]:ss(t):r,scopeId:e.scopeId,slotScopeIds:e.slotScopeIds,children:a,target:e.target,targetStart:e.targetStart,targetAnchor:e.targetAnchor,staticCount:e.staticCount,shapeFlag:e.shapeFlag,patchFlag:t&&e.type!==ie?i===-1?16:i|16:i,dynamicProps:e.dynamicProps,dynamicChildren:e.dynamicChildren,appContext:e.appContext,dirs:e.dirs,transition:u,component:e.component,suspense:e.suspense,ssContent:e.ssContent&&hn(e.ssContent),ssFallback:e.ssFallback&&hn(e.ssFallback),placeholder:e.placeholder,el:e.el,anchor:e.anchor,ctx:e.ctx,ce:e.ce};return u&&s&&go(c,u.clone(c)),c}function pe(e=" ",t=0){return Ce(ks,null,e,t)}function ki(e,t){const n=Ce(ns,null,e);return n.staticCount=t,n}function J(e="",t=!1){return t?(w(),tt(Et,null,e)):Ce(Et,null,e)}function wt(e){return e==null||typeof e=="boolean"?Ce(Et):Z(e)?Ce(ie,null,e.slice()):jn(e)?Pt(e):Ce(ks,null,String(e))}function Pt(e){return e.el===null&&e.patchFlag!==-1||e.memo?e:hn(e)}function cs(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),cs(e,o()),o._c&&(o._d=!0));return}else{n=32;const o=t._;!o&&!fi(t)?t._ctx=Le:o===3&&Le&&(Le.slots._===1?t._=1:(t._=2,e.patchFlag|=1024))}else if(re(t)){if(s&65){cs(e,{default:t});return}t={default:t,_ctx:Le},n=32}else t=String(t),s&64?(n=16,t=[pe(t)]):n=8;e.children=t,e.shapeFlag|=n}function Pa(...e){const t={};for(let n=0;nBe||Le;let ds,Un;{const e=gs(),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)}};ds=t("__VUE_INSTANCE_SETTERS__",n=>Be=n),Un=t("__VUE_SSR_SETTERS__",n=>Ln=n)}const Bn=e=>{const t=Be;return ds(e),e.scope.on(),()=>{e.scope.off(),ds(t)}},qo=()=>{Be&&Be.scope.off(),ds(null)};function Ei(e){return e.vnode.shapeFlag&4}let Ln=!1;function Ma(e,t=!1,n=!1){t&&Un(t);const{props:s,children:o}=e.vnode,r=Ei(e);ba(e,s,r,t),wa(e,o,n||t);const i=r?Va(e,t):void 0;return t&&Un(!1),i}function Va(e,t){const n=e.type;e.accessCache=Object.create(null),e.proxy=new Proxy(e.ctx,sa);const{setup:s}=n;if(s){jt();const o=e.setupContext=s.length>1?Ua(e):null,r=Bn(e),i=Hn(s,e,0,[e.props,o]),a=wr(i);if(Ut(),r(),(a||e.sp)&&!dn(e)&&ti(e),a){if(i.then(qo,qo),t)return i.then(u=>{Un(!0);try{Ho(e,u,t)}finally{Un(!1)}}).catch(u=>{_s(u,e,0)});e.asyncDep=i}else Ho(e,i)}else Si(e)}function Ho(e,t,n){re(t)?e.type.__ssrInlineRender?e.ssrRender=t:e.render=t:xe(t)&&(e.setupState=Gr(t)),Si(e)}function Si(e,t,n){const s=e.type;e.render||(e.render=s.render||kt);{const o=Bn(e);jt();try{oa(e)}finally{Ut(),o()}}}const ja={get(e,t){return He(e,"get",""),e[t]}};function Ua(e){const t=n=>{e.exposed=n||{}};return{attrs:new Proxy(e.attrs,ja),slots:e.slots,emit:e.emit,expose:t}}function Es(e){return e.exposed?e.exposeProxy||(e.exposeProxy=new Proxy(Gr(Sl(e.exposed)),{get(t,n){if(n in t)return t[n];if(n in On)return On[n](e)},has(t,n){return n in t||n in On}})):e.proxy}function La(e,t=!0){return re(e)?e.displayName||e.name:e.name||t&&e.__name}function Fa(e){return re(e)&&"__vccOpts"in e}const we=(e,t)=>Pl(e,t,Ln);function Ai(e,t,n){try{us(-1);const s=arguments.length;return s===2?xe(t)&&!Z(t)?jn(t)?Ce(e,null,[t]):Ce(e,t):Ce(e,null,t):(s>3?n=Array.prototype.slice.call(arguments,2):s===3&&jn(n)&&(n=[n]),Ce(e,t,n))}finally{us(1)}}const qa="3.5.41";/** +**/function Hn(e,t,n,s){try{return s?e(...s):e()}catch(o){_s(o,t,n)}}function ht(e,t,n,s){if(re(e)){const o=Hn(e,t,n,s);return o&&wr(o)&&o.catch(r=>{_s(r,t,n)}),o}if(Z(e)){const o=[];for(let r=0;r>>1,o=Qe[s],r=Mn(o);r=Mn(n)?Qe.push(e):Qe.splice(Nl(t),0,e),e.flags|=1,Wr()}}function Wr(){rs||(rs=Kr.then(Jr))}function Ml(e){if(!Z(e))Gt&&e.id===-1?Gt.splice(rn+1,0,e):e.flags&1||(cn.push(e),e.flags|=1);else for(let t=0;tMn(n)-Mn(s));if(cn.length=0,Gt){for(let n=0;ne.id==null?e.flags&2?-1:1/0:e.id;function Jr(e){try{for(_t=0;_t{s._d&&us(-1);const r=is(t),i=Vt.length;let a;try{a=e(...o)}finally{for(let u=Vt.length;u>i;u--)wo();is(r),s._d&&us(1)}return a};return s._n=!0,s._c=!0,s._d=!0,s}function ne(e,t){if(Le===null)return e;const n=Es(Le),s=e.dirs||(e.dirs=[]);for(let o=0;o1)return n&&re(t)?t.call(s&&s.proxy):t}}const Vl=Symbol.for("v-scx"),jl=()=>ft(Vl);function Mt(e,t,n){return Yr(e,t,n)}function Yr(e,t,n=_e){const{immediate:s,deep:o,flush:r,once:i}=n,a=Fe({},n),u=t&&s||!t&&r!=="post";let d;if(Ln){if(r==="sync"){const _=jl();d=_.__watcherHandles||(_.__watcherHandles=[])}else if(!u){const _=()=>{};return _.stop=kt,_.resume=kt,_.pause=kt,_}}const c=Be;a.call=(_,N,P)=>ht(_,c,N,P);let p=!1;r==="post"?a.scheduler=_=>{et(_,c&&c.suspense)}:r!=="sync"&&(p=!0,a.scheduler=(_,N)=>{N?_():vo(_)}),a.augmentJob=_=>{t&&(_.flags|=4),p&&(_.flags|=2,c&&(_.id=c.uid,_.i=c))};const h=Tl(e,t,a);return Ln&&(d?d.push(h):u&&h()),h}function Ul(e,t,n){const s=this.proxy,o=Oe(e)?e.includes(".")?Xr(s,e):()=>s[e]:e.bind(s,s);let r;re(t)?r=t:(r=t.handler,n=t);const i=Bn(this),a=Yr(o,r.bind(s),n);return i(),a}function Xr(e,t){const n=t.split(".");return()=>{let s=e;for(let o=0;oe.__isTeleport,Ts=Symbol("_leaveCb");function Fl(e){let t=e[0];if(e.length>1){for(const n of e)if(n.type!==Et){t=n;break}}return t}function Zr(e){if(!bo(e))return ys(e.type)&&e.children?Fl(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&&re(n.default))return n.default()}}function go(e,t){if(e.shapeFlag&6&&e.component){e.transition=t;const n=e.component.subTree;go(ys(n.type)&&Zr(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 ei(e,t){return re(e)?Fe({name:e.name},t,{setup:e}):e}function ti(e){e.ids=[e.ids[0]+e.ids[2]+++"-",0,0]}function Po(e,t){let n;return!!((n=Object.getOwnPropertyDescriptor(e,t))&&!n.configurable)}const ls=new WeakMap;function Pn(e,t,n,s,o=!1){if(Z(e)){e.forEach((P,W)=>Pn(P,t&&(Z(t)?t[W]:t),n,s,o));return}if(dn(s)&&!o){s.shapeFlag&512&&s.type.__asyncResolved&&s.component.subTree.component&&Pn(e,t,n,s.component.subTree);return}const r=s.shapeFlag&4?Es(s.component):s.el,i=o?null:r,{i:a,r:u}=e,d=t&&t.r,c=a.refs===_e?a.refs={}:a.refs,p=a.setupState,h=ve(p),_=p===_e?yr:P=>Po(c,P)?!1:ge(h,P),N=(P,W)=>!(W&&Po(c,W));if(d!=null&&d!==u){if(Oo(t),Oe(d))c[d]=null,_(d)&&(p[d]=null);else if(Ge(d)){const P=t;N(d,P.k)&&(d.value=null),P.k&&(c[P.k]=null)}}if(re(u))Hn(u,a,12,[i,c]);else{const P=Oe(u),W=Ge(u);if(P||W){const H=()=>{if(e.f){const D=P?_(u)?p[u]:c[u]:N()||!e.k?u.value:c[e.k];if(o)Z(D)&&oo(D,r);else if(Z(D))D.includes(r)||D.push(r);else if(P)c[u]=[r],_(u)&&(p[u]=c[u]);else{const B=[r];N(u,e.k)&&(u.value=B),e.k&&(c[e.k]=B)}}else P?(c[u]=i,_(u)&&(p[u]=i)):W&&(N(u,e.k)&&(u.value=i),e.k&&(c[e.k]=i))};if(i){const D=()=>{H(),ls.delete(e)};D.id=-1,ls.set(e,D),et(D,n)}else Oo(e),H()}}}function Oo(e){const t=ls.get(e);t&&(t.flags|=8,ls.delete(e))}gs().requestIdleCallback;gs().cancelIdleCallback;const dn=e=>!!e.type.__asyncLoader,bo=e=>e.type.__isKeepAlive;function ql(e,t){ni(e,"a",t)}function Hl(e,t){ni(e,"da",t)}function ni(e,t,n=Be){const s=e.__wdc||(e.__wdc=()=>{let o=n;for(;o;){if(o.isDeactivated)return;o=o.parent}return e()});if(ws(t,s,n),n){let o=n.parent;for(;o&&o.parent;)bo(o.parent.vnode)&&Bl(s,t,n,o),o=o.parent}}function Bl(e,t,n,s){const o=ws(t,e,s,!0);si(()=>{oo(s[t],o)},n)}function ws(e,t,n=Be,s=!1){if(n){const o=n[e]||(n[e]=[]),r=t.__weh||(t.__weh=(...i)=>{jt();const a=Bn(n),u=ht(t,n,e,i);return a(),Ut(),u});return s?o.unshift(r):o.push(r),r}}const Ft=e=>(t,n=Be)=>{(!Ln||e==="sp")&&ws(e,(...s)=>t(...s),n)},Gl=Ft("bm"),xo=Ft("m"),Kl=Ft("bu"),Wl=Ft("u"),zl=Ft("bum"),si=Ft("um"),Jl=Ft("sp"),Ql=Ft("rtg"),Yl=Ft("rtc");function Xl(e,t=Be){ws("ec",e,t)}const Zl="components";function yn(e,t){return ta(Zl,e,!0,t)||e}const ea=Symbol.for("v-ndc");function ta(e,t,n=!0,s=!1){const o=Le||Be;if(o){const r=o.type;{const a=La(r,!1);if(a&&(a===t||a===Xe(t)||a===hs(Xe(t))))return r}const i=To(o[e]||r[e],t)||To(o.appContext[e],t);return!i&&s?r:i}}function To(e,t){return e&&(e[t]||e[Xe(t)]||e[hs(Xe(t))])}function Pe(e,t,n,s){let o;const r=n,i=Z(e);if(i||Oe(e)){const a=i&&tn(e);let u=!1,d=!1;a&&(u=!at(e),d=Lt(e),e=bs(e)),o=new Array(e.length);for(let c=0,p=e.length;ct(a,u,void 0,r));else{const a=Object.keys(e);o=new Array(a.length);for(let u=0,d=a.length;u0;return w(),tt(ie,null,[Ce("slot",d,s)],c?-2:64)}let i=e[t];i&&i._c&&(i._d=!1);const a=Vt.length;w();let u;try{const d=i&&oi(i(n)),c=n.key||r||d&&d.key;u=tt(ie,{key:(c&&!pt(c)?c:`_${t}`)+(!d&&s?"_fb":"")},d||(s?s():[]),d&&e._===1?64:-2)}catch(d){for(let c=Vt.length;c>a;c--)wo();throw d}finally{i&&i._c&&(i._d=!0)}return u.scopeId&&(u.slotScopeIds=[u.scopeId+"-s"]),u}function oi(e){return e.some(t=>jn(t)?!(t.type===Et||t.type===ie&&!oi(t.children)):!0)?e:null}const zs=e=>e?Ei(e)?Es(e):zs(e.parent):null,On=Fe(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=>zs(e.parent),$root:e=>zs(e.root),$host:e=>e.ce,$emit:e=>e.emit,$options:e=>ii(e),$forceUpdate:e=>e.f||(e.f=()=>{vo(e.update)}),$nextTick:e=>e.n||(e.n=ho.bind(e.proxy)),$watch:e=>Ul.bind(e)}),Ds=(e,t)=>e!==_e&&!e.__isScriptSetup&&ge(e,t),sa={get({_:e},t){if(t==="__v_skip")return!0;const{ctx:n,setupState:s,data:o,props:r,accessCache:i,type:a,appContext:u}=e;if(t[0]!=="$"){const h=i[t];if(h!==void 0)switch(h){case 1:return s[t];case 2:return o[t];case 4:return n[t];case 3:return r[t]}else{if(Ds(s,t))return i[t]=1,s[t];if(o!==_e&&ge(o,t))return i[t]=2,o[t];if(ge(r,t))return i[t]=3,r[t];if(n!==_e&&ge(n,t))return i[t]=4,n[t];Js&&(i[t]=0)}}const d=On[t];let c,p;if(d)return t==="$attrs"&&He(e.attrs,"get",""),d(e);if((c=a.__cssModules)&&(c=c[t]))return c;if(n!==_e&&ge(n,t))return i[t]=4,n[t];if(p=u.config.globalProperties,ge(p,t))return p[t]},set({_:e},t,n){const{data:s,setupState:o,ctx:r}=e;return Ds(o,t)?(o[t]=n,!0):s!==_e&&ge(s,t)?(s[t]=n,!0):ge(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}},a){let u;return!!(n[a]||e!==_e&&a[0]!=="$"&&ge(e,a)||Ds(t,a)||ge(r,a)||ge(s,a)||ge(On,a)||ge(o.config.globalProperties,a)||(u=i.__cssModules)&&u[a])},defineProperty(e,t,n){return n.get!=null?e._.accessCache[t]=0:ge(n,"value")&&this.set(e,t,n.value,null),Reflect.defineProperty(e,t,n)}};function Do(e){return Z(e)?e.reduce((t,n)=>(t[n]=null,t),{}):e}let Js=!0;function oa(e){const t=ii(e),n=e.proxy,s=e.ctx;Js=!1,t.beforeCreate&&No(t.beforeCreate,e,"bc");const{data:o,computed:r,methods:i,watch:a,provide:u,inject:d,created:c,beforeMount:p,mounted:h,beforeUpdate:_,updated:N,activated:P,deactivated:W,beforeDestroy:H,beforeUnmount:D,destroyed:B,unmounted:k,render:b,renderTracked:O,renderTriggered:U,errorCaptured:L,serverPrefetch:Ae,expose:ee,inheritAttrs:V,components:De,directives:z,filters:Ze}=t;if(d&&ra(d,s,null),i)for(const fe in i){const ue=i[fe];re(ue)&&(s[fe]=ue.bind(n))}if(o){const fe=o.call(n,n);xe(fe)&&(e.data=xs(fe))}if(Js=!0,r)for(const fe in r){const ue=r[fe],ut=re(ue)?ue.bind(n,n):re(ue.get)?ue.get.bind(n,n):kt,gt=!re(ue)&&re(ue.set)?ue.set.bind(n):kt,Ke=we({get:ut,set:gt});Object.defineProperty(s,fe,{enumerable:!0,configurable:!0,get:()=>Ke.value,set:Te=>Ke.value=Te})}if(a)for(const fe in a)ri(a[fe],s,n,fe);if(u){const fe=re(u)?u.call(n):u;Reflect.ownKeys(fe).forEach(ue=>{ts(ue,fe[ue])})}c&&No(c,e,"c");function Se(fe,ue){Z(ue)?ue.forEach(ut=>fe(ut.bind(n))):ue&&fe(ue.bind(n))}if(Se(Gl,p),Se(xo,h),Se(Kl,_),Se(Wl,N),Se(ql,P),Se(Hl,W),Se(Xl,L),Se(Yl,O),Se(Ql,U),Se(zl,D),Se(si,k),Se(Jl,Ae),Z(ee))if(ee.length){const fe=e.exposed||(e.exposed={});ee.forEach(ue=>{Object.defineProperty(fe,ue,{get:()=>n[ue],set:ut=>n[ue]=ut,enumerable:!0})})}else e.exposed||(e.exposed={});b&&e.render===kt&&(e.render=b),V!=null&&(e.inheritAttrs=V),De&&(e.components=De),z&&(e.directives=z),Ae&&ti(e)}function ra(e,t,n=kt){Z(e)&&(e=Qs(e));for(const s in e){const o=e[s];let r;xe(o)?"default"in o?r=ft(o.from||s,o.default,!0):r=ft(o.from||s):r=ft(o),Ge(r)?Object.defineProperty(t,s,{enumerable:!0,configurable:!0,get:()=>r.value,set:i=>r.value=i}):t[s]=r}}function No(e,t,n){ht(Z(e)?e.map(s=>s.bind(t.proxy)):e.bind(t.proxy),t,n)}function ri(e,t,n,s){let o=s.includes(".")?Xr(n,s):()=>n[s];if(Oe(e)){const r=t[e];re(r)&&Mt(o,r)}else if(re(e))Mt(o,e.bind(n));else if(xe(e))if(Z(e))e.forEach(r=>ri(r,t,n,s));else{const r=re(e.handler)?e.handler.bind(n):t[e.handler];re(r)&&Mt(o,r,e)}}function ii(e){const t=e.type,{mixins:n,extends:s}=t,{mixins:o,optionsCache:r,config:{optionMergeStrategies:i}}=e.appContext,a=r.get(t);let u;return a?u=a:!o.length&&!n&&!s?u=t:(u={},o.length&&o.forEach(d=>as(u,d,i,!0)),as(u,t,i)),xe(t)&&r.set(t,u),u}function as(e,t,n,s=!1){const{mixins:o,extends:r}=t;r&&as(e,r,n,!0),o&&o.forEach(i=>as(e,i,n,!0));for(const i in t)if(!(s&&i==="expose")){const a=ia[i]||n&&n[i];e[i]=a?a(e[i],t[i]):t[i]}return e}const ia={data:Mo,props:Vo,emits:Vo,methods:En,computed:En,beforeCreate:ze,created:ze,beforeMount:ze,mounted:ze,beforeUpdate:ze,updated:ze,beforeDestroy:ze,beforeUnmount:ze,destroyed:ze,unmounted:ze,activated:ze,deactivated:ze,errorCaptured:ze,serverPrefetch:ze,components:En,directives:En,watch:aa,provide:Mo,inject:la};function Mo(e,t){return t?e?function(){return Fe(re(e)?e.call(this,this):e,re(t)?t.call(this,this):t)}:t:e}function la(e,t){return En(Qs(e),Qs(t))}function Qs(e){if(Z(e)){const t={};for(let n=0;nt==="modelValue"||t==="model-value"?e.modelModifiers:e[`${t}Modifiers`]||e[`${Xe(t)}Modifiers`]||e[`${sn(t)}Modifiers`];function fa(e,t,...n){if(e.isUnmounted)return;const s=e.vnode.props||_e;let o=n;const r=t.startsWith("update:"),i=r&&da(s,t.slice(7));i&&(i.trim&&(o=n.map(c=>Oe(c)?c.trim():c)),i.number&&(o=n.map(vs)));let a,u=s[a=Is(t)]||s[a=Is(Xe(t))];!u&&r&&(u=s[a=Is(sn(t))]),u&&ht(u,e,6,o);const d=s[a+"Once"];if(d){if(!e.emitted)e.emitted={};else if(e.emitted[a])return;e.emitted[a]=!0,ht(d,e,6,o)}}const pa=new WeakMap;function ai(e,t,n=!1){const s=n?pa:t.emitsCache,o=s.get(e);if(o!==void 0)return o;const r=e.emits;let i={},a=!1;if(!re(e)){const u=d=>{const c=ai(d,t,!0);c&&(a=!0,Fe(i,c))};!n&&t.mixins.length&&t.mixins.forEach(u),e.extends&&u(e.extends),e.mixins&&e.mixins.forEach(u)}return!r&&!a?(xe(e)&&s.set(e,null),null):(Z(r)?r.forEach(u=>i[u]=null):Fe(i,r),xe(e)&&s.set(e,i),i)}function Cs(e,t){return!e||!fs(t)?!1:(t=t.slice(2),t=t==="Once"?t:t.replace(/Once$/,""),ge(e,t[0].toLowerCase()+t.slice(1))||ge(e,sn(t))||ge(e,t))}function jo(e){const{type:t,vnode:n,proxy:s,withProxy:o,propsOptions:[r],slots:i,attrs:a,emit:u,render:d,renderCache:c,props:p,data:h,setupState:_,ctx:N,inheritAttrs:P}=e,W=is(e);let H,D;try{if(n.shapeFlag&4){const k=o||s,b=k;H=wt(d.call(b,k,c,p,_,h,N)),D=a}else{const k=t;H=wt(k.length>1?k(p,{attrs:a,slots:i,emit:u}):k(p,null)),D=t.props?a:ma(a)}}catch(k){Vt.length=0,_s(k,e,1),H=Ce(Et)}let B=H;if(D&&P!==!1){const k=Object.keys(D),{shapeFlag:b}=B;k.length&&b&7&&(r&&k.some(ps)&&(D=ha(D,r)),B=hn(B,D,!1,!0))}if(n.dirs&&(B=hn(B,null,!1,!0),B.dirs=B.dirs?B.dirs.concat(n.dirs):n.dirs),n.transition){const k=ys(B.type)&&Zr(B)||B;go(k,n.transition)}return H=B,is(W),H}const ma=e=>{let t;for(const n in e)(n==="class"||n==="style"||fs(n))&&((t||(t={}))[n]=e[n]);return t},ha=(e,t)=>{const n={};for(const s in e)(!ps(s)||!(s.slice(9)in t))&&(n[s]=e[s]);return n};function va(e,t,n){const{props:s,children:o,component:r}=e,{props:i,children:a,patchFlag:u}=t,d=r.emitsOptions;if(t.dirs||t.transition)return!0;if(n&&u>=0){if(u&1024)return!0;if(u&16)return s?Uo(s,i,d):!!i;if(u&8){const c=t.dynamicProps;for(let p=0;pObject.create(ci),fi=e=>Object.getPrototypeOf(e)===ci;function ba(e,t,n,s=!1){const o={},r=di();e.propsDefaults=Object.create(null),pi(e,t,o,r);for(const i in e.propsOptions[0])i in o||(o[i]=void 0);n?e.props=s?o:Hr(o):e.type.props?e.props=o:e.props=r,e.attrs=r}function xa(e,t,n,s){const{props:o,attrs:r,vnode:{patchFlag:i}}=e,a=ve(o),[u]=e.propsOptions;let d=!1;if((s||i>0)&&!(i&16)){if(i&8){const c=e.vnode.dynamicProps;for(let p=0;p{u=!0;const[h,_]=mi(p,t,!0);Fe(i,h),_&&a.push(..._)};!n&&t.mixins.length&&t.mixins.forEach(c),e.extends&&c(e.extends),e.mixins&&e.mixins.forEach(c)}if(!r&&!u)return xe(e)&&s.set(e,an),an;if(Z(r))for(let c=0;ce==="_"||e==="_ctx"||e==="$stable",yo=e=>Z(e)?e.map(wt):[wt(e)],ya=(e,t,n)=>{if(t._n)return t;const s=ct((...o)=>yo(t(...o)),n);return s._c=!1,s},hi=(e,t,n)=>{const s=e._ctx;for(const o in e){if(_o(o))continue;const r=e[o];if(re(r))t[o]=ya(o,r,s);else if(r!=null){const i=yo(r);t[o]=()=>i}}},vi=(e,t)=>{const n=yo(t);e.slots.default=()=>n},gi=(e,t,n)=>{for(const s in t)(n||!_o(s))&&(e[s]=t[s])},wa=(e,t,n)=>{const s=e.slots=di();if(e.vnode.shapeFlag&32){const o=t._;o?(gi(s,t,n),n&&Er(s,"_",o,!0)):hi(t,s)}else t&&vi(e,t)},Ca=(e,t,n)=>{const{vnode:s,slots:o}=e;let r=!0,i=_e;if(s.shapeFlag&32){const a=t._;a?n&&a===1?r=!1:gi(o,t,n):(r=!t.$stable,hi(t,o)),i=t}else t&&(vi(e,t),i={default:1});if(r)for(const a in o)!_o(a)&&i[a]==null&&delete o[a]},et=Ia;function ka(e){return Ea(e)}function Ea(e,t){const n=gs();n.__VUE__=!0;const{insert:s,remove:o,patchProp:r,createElement:i,createText:a,createComment:u,setText:d,setElementText:c,parentNode:p,nextSibling:h,setScopeId:_=kt,insertStaticContent:N}=e,P=(f,m,g,y=null,A=null,E=null,j=void 0,M=null,T=!!m.dynamicChildren)=>{if(f===m)return;f&&!Cn(f,m)&&(y=S(f),Te(f,A,E,!0),f=null),m.patchFlag===-2&&(T=!1,m.dynamicChildren=null);const{type:$,ref:X,shapeFlag:q}=m;switch($){case ks:W(f,m,g,y);break;case Et:H(f,m,g,y);break;case ns:f==null&&D(m,g,y,j);break;case ie:De(f,m,g,y,A,E,j,M,T);break;default:q&1?b(f,m,g,y,A,E,j,M,T):q&6?z(f,m,g,y,A,E,j,M,T):(q&64||q&128)&&$.process(f,m,g,y,A,E,j,M,T,Y)}X!=null&&A?Pn(X,f&&f.ref,E,m||f,!m):X==null&&f&&f.ref!=null&&Pn(f.ref,null,E,f,!0)},W=(f,m,g,y)=>{if(f==null)s(m.el=a(m.children),g,y);else{const A=m.el=f.el;m.children!==f.children&&d(A,m.children)}},H=(f,m,g,y)=>{f==null?s(m.el=u(m.children||""),g,y):m.el=f.el},D=(f,m,g,y)=>{[f.el,f.anchor]=N(f.children,m,g,y,f.el,f.anchor)},B=({el:f,anchor:m},g,y)=>{let A;for(;f&&f!==m;)A=h(f),s(f,g,y),f=A;s(m,g,y)},k=({el:f,anchor:m})=>{let g;for(;f&&f!==m;)g=h(f),o(f),f=g;o(m)},b=(f,m,g,y,A,E,j,M,T)=>{if(m.type==="svg"?j="svg":m.type==="math"&&(j="mathml"),f==null)O(m,g,y,A,E,j,M,T);else{const $=f.el&&f.el._isVueCE?f.el:null;try{$&&$._beginPatch(),Ae(f,m,A,E,j,M,T)}finally{$&&$._endPatch()}}},O=(f,m,g,y,A,E,j,M)=>{let T,$;const{props:X,shapeFlag:q,transition:Q,dirs:te}=f;if(T=f.el=i(f.type,E,X&&X.is,X),q&8?c(T,f.children):q&16&&L(f.children,T,null,y,A,Ns(f,E),j,M),te&&Qt(f,null,y,"created"),U(T,f,f.scopeId,j,y),X){for(const be in X)be!=="value"&&!In(be)&&r(T,be,null,X[be],E,y);"value"in X&&r(T,"value",null,X.value,E),($=X.onVnodeBeforeMount)&&xt($,y,f)}te&&Qt(f,null,y,"beforeMount");const ce=Sa(A,Q);ce&&Q.beforeEnter(T),s(T,m,g),(($=X&&X.onVnodeMounted)||ce||te)&&et(()=>{try{$&&xt($,y,f),ce&&Q.enter(T),te&&Qt(f,null,y,"mounted")}finally{}},A)},U=(f,m,g,y,A)=>{if(g&&_(f,g),y)for(let E=0;E{for(let $=T;${const M=m.el=f.el;let{patchFlag:T,dynamicChildren:$,dirs:X}=m;T|=f.patchFlag&16;const q=f.props||_e,Q=m.props||_e;let te;if(g&&Yt(g,!1),(te=Q.onVnodeBeforeUpdate)&&xt(te,g,m,f),X&&Qt(m,f,g,"beforeUpdate"),g&&Yt(g,!0),$&&(!f.dynamicChildren||f.dynamicChildren.length!==$.length)&&(T=0,j=!1,$=null),(q.innerHTML&&Q.innerHTML==null||q.textContent&&Q.textContent==null)&&c(M,""),$?ee(f.dynamicChildren,$,M,g,y,Ns(m,A),E):j||ue(f,m,M,null,g,y,Ns(m,A),E,!1),T>0){if(T&16)V(M,q,Q,g,A);else if(T&2&&q.class!==Q.class&&r(M,"class",null,Q.class,A),T&4&&r(M,"style",q.style,Q.style,A),T&8){const ce=m.dynamicProps;for(let be=0;be{te&&xt(te,g,m,f),X&&Qt(m,f,g,"updated")},y)},ee=(f,m,g,y,A,E,j)=>{for(let M=0;M{if(m!==g){if(m!==_e)for(const E in m)!In(E)&&!(E in g)&&r(f,E,m[E],null,A,y);for(const E in g){if(In(E))continue;const j=g[E],M=m[E];j!==M&&E!=="value"&&r(f,E,M,j,A,y)}"value"in g&&r(f,"value",m.value,g.value,A)}},De=(f,m,g,y,A,E,j,M,T)=>{const $=m.el=f?f.el:a(""),X=m.anchor=f?f.anchor:a("");let{patchFlag:q,dynamicChildren:Q,slotScopeIds:te}=m;te&&(M=M?M.concat(te):te),f==null?(s($,g,y),s(X,g,y),L(m.children||[],g,X,A,E,j,M,T)):q>0&&q&64&&Q&&f.dynamicChildren&&f.dynamicChildren.length===Q.length?(ee(f.dynamicChildren,Q,g,A,E,j,M),(m.key!=null||A&&m===A.subTree)&&bi(f,m,!0)):ue(f,m,g,X,A,E,j,M,T)},z=(f,m,g,y,A,E,j,M,T)=>{m.slotScopeIds=M,f==null?m.shapeFlag&512?A.ctx.activate(m,g,y,j,T):Ze(m,g,y,A,E,j,T):qt(f,m,T)},Ze=(f,m,g,y,A,E,j)=>{const M=f.component=Da(f,y,A);if(bo(f)&&(M.ctx.renderer=Y),Ma(M,!1,j),M.asyncDep){if(A&&A.registerDep(M,Se,j),!f.el){const T=M.subTree=Ce(Et);H(null,T,m,g),f.placeholder=T.el}}else Se(M,f,m,g,A,E,j)},qt=(f,m,g)=>{const y=m.component=f.component;if(va(f,m,g))if(y.asyncDep&&!y.asyncResolved){fe(y,m,g);return}else y.next=m,y.update();else m.el=f.el,y.vnode=m},Se=(f,m,g,y,A,E,j)=>{const M=()=>{if(f.isMounted){let{next:q,bu:Q,u:te,parent:ce,vnode:be}=f;{const ot=xi(f);if(ot){q&&(q.el=be.el,fe(f,q,j)),ot.asyncDep.then(()=>{et(()=>{f.isUnmounted||$()},A)});return}}let me=q,Ie;Yt(f,!1),q?(q.el=be.el,fe(f,q,j)):q=be,Q&&es(Q),(Ie=q.props&&q.props.onVnodeBeforeUpdate)&&xt(Ie,ce,q,be),Yt(f,!0);const $e=jo(f),st=f.subTree;f.subTree=$e,P(st,$e,p(st.el),S(st),f,A,E),q.el=$e.el,me===null&&ga(f,$e.el),te&&et(te,A),(Ie=q.props&&q.props.onVnodeUpdated)&&et(()=>xt(Ie,ce,q,be),A)}else{let q;const{el:Q,props:te}=m,{bm:ce,m:be,parent:me,root:Ie,type:$e}=f,st=dn(m);Yt(f,!1),ce&&es(ce),!st&&(q=te&&te.onVnodeBeforeMount)&&xt(q,me,m),Yt(f,!0);{Ie.ce&&Ie.ce._hasShadowRoot()&&Ie.ce._injectChildStyle($e,f.parent?f.parent.type:void 0);const ot=f.subTree=jo(f);P(null,ot,g,y,f,A,E),m.el=ot.el}if(be&&et(be,A),!st&&(q=te&&te.onVnodeMounted)){const ot=m;et(()=>xt(q,me,ot),A)}(m.shapeFlag&256||me&&dn(me.vnode)&&me.vnode.shapeFlag&256)&&f.a&&et(f.a,A),f.isMounted=!0,m=g=y=null}};f.scope.on();const T=f.effect=new $r(M);f.scope.off();const $=f.update=T.run.bind(T),X=f.job=T.runIfDirty.bind(T);X.i=f,X.id=f.uid,T.scheduler=()=>vo(X),Yt(f,!0),$()},fe=(f,m,g)=>{m.component=f;const y=f.vnode.props;f.vnode=m,f.next=null,xa(f,m.props,y,g),Ca(f,m.children,g),jt(),Ro(f),Ut()},ue=(f,m,g,y,A,E,j,M,T=!1)=>{const $=f&&f.children,X=f?f.shapeFlag:0,q=m.children,{patchFlag:Q,shapeFlag:te}=m;if(Q>0){if(Q&128){gt($,q,g,y,A,E,j,M,T);return}else if(Q&256){ut($,q,g,y,A,E,j,M,T);return}}te&8?(X&16&&qe($,A,E),q!==$&&c(g,q)):X&16?te&16?gt($,q,g,y,A,E,j,M,T):qe($,A,E,!0):(X&8&&c(g,""),te&16&&L(q,g,y,A,E,j,M,T))},ut=(f,m,g,y,A,E,j,M,T)=>{f=f||an,m=m||an;const $=f.length,X=m.length,q=Math.min($,X);let Q;for(Q=0;QX?qe(f,A,E,!0,!1,q):L(m,g,y,A,E,j,M,T,q)},gt=(f,m,g,y,A,E,j,M,T)=>{let $=0;const X=m.length;let q=f.length-1,Q=X-1;for(;$<=q&&$<=Q;){const te=f[$],ce=m[$]=T?Pt(m[$]):wt(m[$]);if(Cn(te,ce))P(te,ce,g,null,A,E,j,M,T);else break;$++}for(;$<=q&&$<=Q;){const te=f[q],ce=m[Q]=T?Pt(m[Q]):wt(m[Q]);if(Cn(te,ce))P(te,ce,g,null,A,E,j,M,T);else break;q--,Q--}if($>q){if($<=Q){const te=Q+1,ce=teQ)for(;$<=q;)Te(f[$],A,E,!0),$++;else{const te=$,ce=$,be=new Map;for($=ce;$<=Q;$++){const Ne=m[$]=T?Pt(m[$]):wt(m[$]);Ne.key!=null&&be.set(Ne.key,$)}let me,Ie=0;const $e=Q-ce+1;let st=!1,ot=0;const Jt=new Array($e);for($=0;$<$e;$++)Jt[$]=0;for($=te;$<=q;$++){const Ne=f[$];if(Ie>=$e){Te(Ne,A,E,!0);continue}let We;if(Ne.key!=null)We=be.get(Ne.key);else for(me=ce;me<=Q;me++)if(Jt[me-ce]===0&&Cn(Ne,m[me])){We=me;break}We===void 0?Te(Ne,A,E,!0):(Jt[We-ce]=$+1,We>=ot?ot=We:st=!0,P(Ne,m[We],g,null,A,E,j,M,T),Ie++)}const Gn=st?Aa(Jt):an;for(me=Gn.length-1,$=$e-1;$>=0;$--){const Ne=ce+$,We=m[Ne],Ht=m[Ne+1],Kn=Ne+1{const{el:E,type:j,transition:M,children:T,shapeFlag:$}=f;if($&6){Ke(f.component.subTree,m,g,y);return}if($&128){f.suspense.move(m,g,y);return}if($&64){j.move(f,m,g,Y);return}if(j===ie){s(E,m,g);for(let q=0;qM.enter(E),A));else{const{leave:q,delayLeave:Q,afterLeave:te}=M,ce=()=>{f.ctx.isUnmounted?o(E):s(E,m,g)},be=()=>{const me=E._isLeaving||!!E[Ts];E._isLeaving&&E[Ts](!0),M.persisted&&!me?ce():q(E,()=>{ce(),te&&te()})};Q?Q(E,ce,be):be()}else s(E,m,g)},Te=(f,m,g,y=!1,A=!1)=>{const{type:E,props:j,ref:M,children:T,dynamicChildren:$,shapeFlag:X,patchFlag:q,dirs:Q,cacheIndex:te,memo:ce}=f;if(q===-2&&(A=!1),M!=null&&(jt(),Pn(M,null,g,f,!0),Ut()),te!=null&&(m.renderCache[te]=void 0),X&256){m.ctx.deactivate(f);return}const be=X&1&&Q,me=!dn(f);let Ie;if(me&&(Ie=j&&j.onVnodeBeforeUnmount)&&xt(Ie,m,f),X&6)bt(f.component,g,y);else{if(X&128){f.suspense.unmount(g,y);return}be&&Qt(f,null,m,"beforeUnmount"),X&64?f.type.remove(f,m,g,Y,y):$&&!$.hasOnce&&(E!==ie||q>0&&q&64)?qe($,m,g,!1,!0):(E===ie&&q&384||!A&&X&16)&&qe(T,m,g),y&&nt(f)}const $e=ce!=null&&te==null;(me&&(Ie=j&&j.onVnodeUnmounted)||be||$e)&&et(()=>{Ie&&xt(Ie,m,f),be&&Qt(f,null,m,"unmounted"),$e&&(f.el=null)},g)},nt=f=>{const{type:m,el:g,anchor:y,transition:A}=f;if(m===ie){le(g,y);return}if(m===ns){k(f);return}const E=()=>{o(g),A&&!A.persisted&&A.afterLeave&&A.afterLeave()};if(f.shapeFlag&1&&A&&!A.persisted){const{leave:j,delayLeave:M}=A,T=()=>j(g,E);M?M(f.el,E,T):T()}else E()},le=(f,m)=>{let g;for(;f!==m;)g=h(f),o(f),f=g;o(m)},bt=(f,m,g)=>{const{bum:y,scope:A,job:E,subTree:j,um:M,m:T,a:$}=f;Fo(T),Fo($),y&&es(y),A.stop(),E&&(E.flags|=8,Te(j,f,m,g)),M&&et(M,m),et(()=>{f.isUnmounted=!0},m)},qe=(f,m,g,y=!1,A=!1,E=0)=>{for(let j=E;j{if(f.shapeFlag&6)return S(f.component.subTree);if(f.shapeFlag&128)return f.suspense.next();const m=h(f.anchor||f.el),g=m&&m[Ll];return g?h(g):m};let K=!1;const F=(f,m,g)=>{let y;f==null?m._vnode&&(Te(m._vnode,null,null,!0),y=m._vnode.component):P(m._vnode||null,f,m,null,null,null,g),m._vnode=f,K||(K=!0,Ro(y),zr(),K=!1)},Y={p:P,um:Te,m:Ke,r:nt,mt:Ze,mc:L,pc:ue,pbc:ee,n:S,o:e};return{render:F,hydrate:void 0,createApp:ca(F)}}function Ns({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 Yt({effect:e,job:t},n){n?(e.flags|=32,t.flags|=4):(e.flags&=-33,t.flags&=-5)}function Sa(e,t){return(!e||e&&!e.pendingBranch)&&t&&!t.persisted}function bi(e,t,n=!1){const s=e.children,o=t.children;if(Z(s)&&Z(o))for(let r=0;r>1,e[n[a]]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 xi(e){const t=e.subTree.component;if(t)return t.asyncDep&&!t.asyncResolved?t:xi(t)}function Fo(e){if(e)for(let t=0;te.__isSuspense;function Ia(e,t){t&&t.pendingBranch?Z(e)?t.effects.push(...e):t.effects.push(e):Ml(e)}const ie=Symbol.for("v-fgt"),ks=Symbol.for("v-txt"),Et=Symbol.for("v-cmt"),ns=Symbol.for("v-stc"),Vt=[];let rt=null;function w(e=!1){Vt.push(rt=e?null:[])}function wo(){Vt.pop(),rt=Vt[Vt.length-1]||null}let Vn=1;function us(e,t=!1){Vn+=e,e<0&&rt&&t&&(rt.hasOnce=!0)}function wi(e){return e.dynamicChildren=Vn>0?rt||an:null,wo(),Vn>0&&rt&&rt.push(e),e}function C(e,t,n,s,o,r){return wi(l(e,t,n,s,o,r,!0))}function tt(e,t,n,s,o){return wi(Ce(e,t,n,s,o,!0))}function jn(e){return e?e.__v_isVNode===!0:!1}function Cn(e,t){return e.type===t.type&&e.key===t.key}const Ci=({key:e})=>e??null,ss=({ref:e,ref_key:t,ref_for:n})=>(typeof e=="number"&&(e=""+e),e!=null?Oe(e)||Ge(e)||re(e)?{i:Le,r:e,k:t,f:!!n}:e:null);function l(e,t=null,n=null,s=0,o=null,r=e===ie?0:1,i=!1,a=!1){const u={__v_isVNode:!0,__v_skip:!0,type:e,props:t,key:t&&Ci(t),ref:t&&ss(t),scopeId:Qr,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:Le};return a?(cs(u,n),r&128&&e.normalize(u)):n&&(u.shapeFlag|=Oe(n)?8:16),Vn>0&&!i&&rt&&(u.patchFlag>0||r&6)&&u.patchFlag!==32&&rt.push(u),u}const Ce=$a;function $a(e,t=null,n=null,s=0,o=null,r=!1){if((!e||e===ea)&&(e=Et),jn(e)){const a=hn(e,t,!0);return n&&cs(a,n),Vn>0&&!r&&rt&&(a.shapeFlag&6?rt[rt.indexOf(e)]=a:rt.push(a)),a.patchFlag=-2,a}if(Fa(e)&&(e=e.__vccOpts),t){t=Ra(t);let{class:a,style:u}=t;a&&!Oe(a)&&(t.class=Ee(a)),xe(u)&&(mo(u)&&!Z(u)&&(u=Fe({},u)),t.style=nn(u))}const i=Oe(e)?1:yi(e)?128:ys(e)?64:xe(e)?4:re(e)?2:0;return l(e,t,n,s,o,i,r,!0)}function Ra(e){return e?mo(e)||fi(e)?Fe({},e):e:null}function hn(e,t,n=!1,s=!1){const{props:o,ref:r,patchFlag:i,children:a,transition:u}=e,d=t?Pa(o||{},t):o,c={__v_isVNode:!0,__v_skip:!0,type:e.type,props:d,key:d&&Ci(d),ref:t&&t.ref?n&&r?Z(r)?r.concat(ss(t)):[r,ss(t)]:ss(t):r,scopeId:e.scopeId,slotScopeIds:e.slotScopeIds,children:a,target:e.target,targetStart:e.targetStart,targetAnchor:e.targetAnchor,staticCount:e.staticCount,shapeFlag:e.shapeFlag,patchFlag:t&&e.type!==ie?i===-1?16:i|16:i,dynamicProps:e.dynamicProps,dynamicChildren:e.dynamicChildren,appContext:e.appContext,dirs:e.dirs,transition:u,component:e.component,suspense:e.suspense,ssContent:e.ssContent&&hn(e.ssContent),ssFallback:e.ssFallback&&hn(e.ssFallback),placeholder:e.placeholder,el:e.el,anchor:e.anchor,ctx:e.ctx,ce:e.ce};return u&&s&&go(c,u.clone(c)),c}function de(e=" ",t=0){return Ce(ks,null,e,t)}function ki(e,t){const n=Ce(ns,null,e);return n.staticCount=t,n}function J(e="",t=!1){return t?(w(),tt(Et,null,e)):Ce(Et,null,e)}function wt(e){return e==null||typeof e=="boolean"?Ce(Et):Z(e)?Ce(ie,null,e.slice()):jn(e)?Pt(e):Ce(ks,null,String(e))}function Pt(e){return e.el===null&&e.patchFlag!==-1||e.memo?e:hn(e)}function cs(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),cs(e,o()),o._c&&(o._d=!0));return}else{n=32;const o=t._;!o&&!fi(t)?t._ctx=Le:o===3&&Le&&(Le.slots._===1?t._=1:(t._=2,e.patchFlag|=1024))}else if(re(t)){if(s&65){cs(e,{default:t});return}t={default:t,_ctx:Le},n=32}else t=String(t),s&64?(n=16,t=[de(t)]):n=8;e.children=t,e.shapeFlag|=n}function Pa(...e){const t={};for(let n=0;nBe||Le;let ds,Un;{const e=gs(),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)}};ds=t("__VUE_INSTANCE_SETTERS__",n=>Be=n),Un=t("__VUE_SSR_SETTERS__",n=>Ln=n)}const Bn=e=>{const t=Be;return ds(e),e.scope.on(),()=>{e.scope.off(),ds(t)}},qo=()=>{Be&&Be.scope.off(),ds(null)};function Ei(e){return e.vnode.shapeFlag&4}let Ln=!1;function Ma(e,t=!1,n=!1){t&&Un(t);const{props:s,children:o}=e.vnode,r=Ei(e);ba(e,s,r,t),wa(e,o,n||t);const i=r?Va(e,t):void 0;return t&&Un(!1),i}function Va(e,t){const n=e.type;e.accessCache=Object.create(null),e.proxy=new Proxy(e.ctx,sa);const{setup:s}=n;if(s){jt();const o=e.setupContext=s.length>1?Ua(e):null,r=Bn(e),i=Hn(s,e,0,[e.props,o]),a=wr(i);if(Ut(),r(),(a||e.sp)&&!dn(e)&&ti(e),a){if(i.then(qo,qo),t)return i.then(u=>{Un(!0);try{Ho(e,u,t)}finally{Un(!1)}}).catch(u=>{_s(u,e,0)});e.asyncDep=i}else Ho(e,i)}else Si(e)}function Ho(e,t,n){re(t)?e.type.__ssrInlineRender?e.ssrRender=t:e.render=t:xe(t)&&(e.setupState=Gr(t)),Si(e)}function Si(e,t,n){const s=e.type;e.render||(e.render=s.render||kt);{const o=Bn(e);jt();try{oa(e)}finally{Ut(),o()}}}const ja={get(e,t){return He(e,"get",""),e[t]}};function Ua(e){const t=n=>{e.exposed=n||{}};return{attrs:new Proxy(e.attrs,ja),slots:e.slots,emit:e.emit,expose:t}}function Es(e){return e.exposed?e.exposeProxy||(e.exposeProxy=new Proxy(Gr(Sl(e.exposed)),{get(t,n){if(n in t)return t[n];if(n in On)return On[n](e)},has(t,n){return n in t||n in On}})):e.proxy}function La(e,t=!0){return re(e)?e.displayName||e.name:e.name||t&&e.__name}function Fa(e){return re(e)&&"__vccOpts"in e}const we=(e,t)=>Pl(e,t,Ln);function Ai(e,t,n){try{us(-1);const s=arguments.length;return s===2?xe(t)&&!Z(t)?jn(t)?Ce(e,null,[t]):Ce(e,t):Ce(e,null,t):(s>3?n=Array.prototype.slice.call(arguments,2):s===3&&jn(n)&&(n=[n]),Ce(e,t,n))}finally{us(1)}}const qa="3.5.41";/** * @vue/runtime-dom v3.5.41 * (c) 2018-present Yuxi (Evan) You and Vue contributors * @license MIT -**/let Xs;const Bo=typeof window<"u"&&window.trustedTypes;if(Bo)try{Xs=Bo.createPolicy("vue",{createHTML:e=>e})}catch{}const Ii=Xs?e=>Xs.createHTML(e):e=>e,Ha="http://www.w3.org/2000/svg",Ba="http://www.w3.org/1998/Math/MathML",$t=typeof document<"u"?document:null,Go=$t&&$t.createElement("template"),Ga={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"?$t.createElementNS(Ha,e):t==="mathml"?$t.createElementNS(Ba,e):n?$t.createElement(e,{is:n}):$t.createElement(e);return e==="select"&&s&&s.multiple!=null&&o.setAttribute("multiple",s.multiple),o},createText:e=>$t.createTextNode(e),createComment:e=>$t.createComment(e),setText:(e,t)=>{e.nodeValue=t},setElementText:(e,t)=>{e.textContent=t},parentNode:e=>e.parentNode,nextSibling:e=>e.nextSibling,querySelector:e=>$t.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{Go.innerHTML=Ii(s==="svg"?`${e}`:s==="mathml"?`${e}`:e);const a=Go.content;if(s==="svg"||s==="mathml"){const u=a.firstChild;for(;u.firstChild;)a.appendChild(u.firstChild);a.removeChild(u)}t.insertBefore(a,n)}return[i?i.nextSibling:t.firstChild,n?n.previousSibling:t.lastChild]}},Ka=Symbol("_vtc");function Wa(e,t,n){const s=e[Ka];s&&(t=(t?[t,...s]:[...s]).join(" ")),t==null?e.removeAttribute("class"):n?e.setAttribute("class",t):e.className=t}const Ko=Symbol("_vod"),za=Symbol("_vsh"),Ja=Symbol(""),Qa=/(?:^|;)\s*display\s*:/;function Ya(e,t,n){const s=e.style,o=Oe(n);let r=!1;if(n&&!o){if(t)if(Oe(t))for(const i of t.split(";")){const a=i.slice(0,i.indexOf(":")).trim();n[a]==null&&Sn(s,a,"")}else for(const i in t)n[i]==null&&Sn(s,i,"");for(const i in n){i==="display"&&(r=!0);const a=n[i];a!=null?Za(e,i,!Oe(t)&&t?t[i]:void 0,a)||Sn(s,i,a):Sn(s,i,"")}}else if(o){if(t!==n){const i=s[Ja];i&&(n+=";"+i),s.cssText=n,r=Qa.test(n)}}else t&&e.removeAttribute("style");Ko in e&&(e[Ko]=r?s.display:"",e[za]&&(s.display="none"))}const Wo=/\s*!important$/;function Sn(e,t,n){if(Z(n))n.forEach(s=>Sn(e,t,s));else if(n==null&&(n=""),t.startsWith("--"))e.setProperty(t,n);else{const s=Xa(e,t);Wo.test(n)?e.setProperty(sn(s),n.replace(Wo,""),"important"):e[s]=n}}const zo=["Webkit","Moz","ms"],Ms={};function Xa(e,t){const n=Ms[t];if(n)return n;let s=Xe(t);if(s!=="filter"&&s in e)return Ms[t]=s;s=hs(s);for(let o=0;oVs||(ru.then(()=>Vs=0),Vs=Date.now());function lu(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(),a=[s];for(let u=0;ue.charCodeAt(0)===111&&e.charCodeAt(1)===110&&e.charCodeAt(2)>96&&e.charCodeAt(2)<123,au=(e,t,n,s,o,r)=>{const i=o==="svg";t==="class"?Wa(e,s,i):t==="style"?Ya(e,n,s):fs(t)?ps(t)||tu(e,t,n,s,r):(t[0]==="."?(t=t.slice(1),!0):t[0]==="^"?(t=t.slice(1),!1):uu(e,t,s,i))?(Yo(e,t,s),!e.tagName.includes("-")&&(t==="value"||t==="checked"||t==="selected")&&Qo(e,t,s,i,r,t!=="value")):e._isVueCE&&(cu(e,t)||e._def.__asyncLoader&&(/[A-Z]/.test(t)||!Oe(s)))?Yo(e,Xe(t),s,r,t):(t==="true-value"?e._trueValue=s:t==="false-value"&&(e._falseValue=s),Qo(e,t,s,i))};function uu(e,t,n,s){if(s)return!!(t==="innerHTML"||t==="textContent"||t in e&&Zo(t)&&re(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 Zo(t)&&Oe(n)?!1:t in e}function cu(e,t){const n=e._def.props;if(!n)return!1;const s=Xe(t);return Array.isArray(n)?n.some(o=>Xe(o)===s):Object.keys(n).some(o=>Xe(o)===s)}const zt=e=>{const t=e.props["onUpdate:modelValue"]||!1;return Z(t)?n=>es(t,n):t};function du(e){e.target.composing=!0}function er(e){const t=e.target;t.composing&&(t.composing=!1,t.dispatchEvent(new Event("input")))}const it=Symbol("_assign"),Yn=Symbol("_initialValue");function js(e,t,n){return t&&(e=e.trim()),n&&(e=vs(e)),e}const fe={created(e,{modifiers:{lazy:t,trim:n,number:s}},o){e.parentNode&&(e.type==="text"?e[Yn]=e.defaultValue.replace(/[\r\n]/g,""):e.type==="textarea"&&(e[Yn]=e.defaultValue.replace(/\r\n?/g,` +**/let Xs;const Bo=typeof window<"u"&&window.trustedTypes;if(Bo)try{Xs=Bo.createPolicy("vue",{createHTML:e=>e})}catch{}const Ii=Xs?e=>Xs.createHTML(e):e=>e,Ha="http://www.w3.org/2000/svg",Ba="http://www.w3.org/1998/Math/MathML",$t=typeof document<"u"?document:null,Go=$t&&$t.createElement("template"),Ga={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"?$t.createElementNS(Ha,e):t==="mathml"?$t.createElementNS(Ba,e):n?$t.createElement(e,{is:n}):$t.createElement(e);return e==="select"&&s&&s.multiple!=null&&o.setAttribute("multiple",s.multiple),o},createText:e=>$t.createTextNode(e),createComment:e=>$t.createComment(e),setText:(e,t)=>{e.nodeValue=t},setElementText:(e,t)=>{e.textContent=t},parentNode:e=>e.parentNode,nextSibling:e=>e.nextSibling,querySelector:e=>$t.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{Go.innerHTML=Ii(s==="svg"?`${e}`:s==="mathml"?`${e}`:e);const a=Go.content;if(s==="svg"||s==="mathml"){const u=a.firstChild;for(;u.firstChild;)a.appendChild(u.firstChild);a.removeChild(u)}t.insertBefore(a,n)}return[i?i.nextSibling:t.firstChild,n?n.previousSibling:t.lastChild]}},Ka=Symbol("_vtc");function Wa(e,t,n){const s=e[Ka];s&&(t=(t?[t,...s]:[...s]).join(" ")),t==null?e.removeAttribute("class"):n?e.setAttribute("class",t):e.className=t}const Ko=Symbol("_vod"),za=Symbol("_vsh"),Ja=Symbol(""),Qa=/(?:^|;)\s*display\s*:/;function Ya(e,t,n){const s=e.style,o=Oe(n);let r=!1;if(n&&!o){if(t)if(Oe(t))for(const i of t.split(";")){const a=i.slice(0,i.indexOf(":")).trim();n[a]==null&&Sn(s,a,"")}else for(const i in t)n[i]==null&&Sn(s,i,"");for(const i in n){i==="display"&&(r=!0);const a=n[i];a!=null?Za(e,i,!Oe(t)&&t?t[i]:void 0,a)||Sn(s,i,a):Sn(s,i,"")}}else if(o){if(t!==n){const i=s[Ja];i&&(n+=";"+i),s.cssText=n,r=Qa.test(n)}}else t&&e.removeAttribute("style");Ko in e&&(e[Ko]=r?s.display:"",e[za]&&(s.display="none"))}const Wo=/\s*!important$/;function Sn(e,t,n){if(Z(n))n.forEach(s=>Sn(e,t,s));else if(n==null&&(n=""),t.startsWith("--"))e.setProperty(t,n);else{const s=Xa(e,t);Wo.test(n)?e.setProperty(sn(s),n.replace(Wo,""),"important"):e[s]=n}}const zo=["Webkit","Moz","ms"],Ms={};function Xa(e,t){const n=Ms[t];if(n)return n;let s=Xe(t);if(s!=="filter"&&s in e)return Ms[t]=s;s=hs(s);for(let o=0;oVs||(ru.then(()=>Vs=0),Vs=Date.now());function lu(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(),a=[s];for(let u=0;ue.charCodeAt(0)===111&&e.charCodeAt(1)===110&&e.charCodeAt(2)>96&&e.charCodeAt(2)<123,au=(e,t,n,s,o,r)=>{const i=o==="svg";t==="class"?Wa(e,s,i):t==="style"?Ya(e,n,s):fs(t)?ps(t)||tu(e,t,n,s,r):(t[0]==="."?(t=t.slice(1),!0):t[0]==="^"?(t=t.slice(1),!1):uu(e,t,s,i))?(Yo(e,t,s),!e.tagName.includes("-")&&(t==="value"||t==="checked"||t==="selected")&&Qo(e,t,s,i,r,t!=="value")):e._isVueCE&&(cu(e,t)||e._def.__asyncLoader&&(/[A-Z]/.test(t)||!Oe(s)))?Yo(e,Xe(t),s,r,t):(t==="true-value"?e._trueValue=s:t==="false-value"&&(e._falseValue=s),Qo(e,t,s,i))};function uu(e,t,n,s){if(s)return!!(t==="innerHTML"||t==="textContent"||t in e&&Zo(t)&&re(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 Zo(t)&&Oe(n)?!1:t in e}function cu(e,t){const n=e._def.props;if(!n)return!1;const s=Xe(t);return Array.isArray(n)?n.some(o=>Xe(o)===s):Object.keys(n).some(o=>Xe(o)===s)}const zt=e=>{const t=e.props["onUpdate:modelValue"]||!1;return Z(t)?n=>es(t,n):t};function du(e){e.target.composing=!0}function er(e){const t=e.target;t.composing&&(t.composing=!1,t.dispatchEvent(new Event("input")))}const it=Symbol("_assign"),Yn=Symbol("_initialValue");function js(e,t,n){return t&&(e=e.trim()),n&&(e=vs(e)),e}const pe={created(e,{modifiers:{lazy:t,trim:n,number:s}},o){e.parentNode&&(e.type==="text"?e[Yn]=e.defaultValue.replace(/[\r\n]/g,""):e.type==="textarea"&&(e[Yn]=e.defaultValue.replace(/\r\n?/g,` `))),e[it]=zt(o);const r=s||o.props&&o.props.type==="number";Nt(e,t?"change":"input",i=>{i.target.composing||e[it](js(e.value,n,r))}),(n||r)&&Nt(e,"change",()=>{e.value=js(e.value,n,r)}),t||(Nt(e,"compositionstart",du),Nt(e,"compositionend",er),Nt(e,"change",er))},mounted(e,{value:t,modifiers:{trim:n,number:s}}){const o=t??"",r=e[Yn];delete e[Yn],r!==void 0&&(e.type==="text"||e.type==="textarea")&&e.value!==r?e[it](js(e.value,n,s)):e.value=o},beforeUpdate(e,{value:t,oldValue:n,modifiers:{lazy:s,trim:o,number:r}},i){if(e[it]=zt(i),e.composing)return;const a=(r||e.type==="number")&&!/^0\d/.test(e.value)?vs(e.value):e.value,u=t??"";if(a===u)return;const d=e.getRootNode();(d instanceof Document||d instanceof ShadowRoot)&&d.activeElement===e&&e.type!=="range"&&(s&&t===n||o&&e.value.trim()===u)||(e.value=u)}},Rt={deep:!0,created(e,t,n){e[it]=zt(n),Nt(e,"change",()=>{const s=e._modelValue,o=gn(e),r=e.checked,i=e[it];if(Z(s)){const a=io(s,o),u=a!==-1;if(r&&!u)i(s.concat(o));else if(!r&&u){const d=[...s];d.splice(a,1),i(d)}}else if(_n(s)){const a=new Set(s);r?a.add(o):a.delete(o),i(a)}else i($i(e,r))})},mounted:tr,beforeUpdate(e,t,n){e[it]=zt(n),tr(e,t,n)}};function tr(e,{value:t,oldValue:n},s){e._modelValue=t;let o;if(Z(t))o=io(t,s.props.value)>-1;else if(_n(t))o=t.has(s.props.value);else{if(t===n)return;o=Wt(t,$i(e,!0))}e.checked!==o&&(e.checked=o)}const fu={created(e,{value:t},n){e.checked=Wt(t,n.props.value),e[it]=zt(n),Nt(e,"change",()=>{e[it](gn(e))})},beforeUpdate(e,{value:t,oldValue:n},s){e[it]=zt(s),t!==n&&(e.checked=Wt(t,s.props.value))}},vn={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?vs(gn(r)):gn(r));e[it](e.multiple?_n(e._modelValue)?new Set(o):o:o[0]),e._assigning=!0,ho(()=>{e._assigning=!1})}),e[it]=zt(s)},mounted(e,{value:t}){nr(e,t)},beforeUpdate(e,{value:t},n){e._modelValue=t,e[it]=zt(n)},updated(e,{value:t}){e._assigning||nr(e,t)}};function nr(e,t){const n=e.multiple,s=Z(t);if(!(n&&!s&&!_n(t))){for(let o=0,r=e.options.length;oString(d)===String(a)):i.selected=io(t,a)>-1}else i.selected=t.has(a);else if(Wt(gn(i),t)){e.selectedIndex!==o&&(e.selectedIndex=o);return}}!n&&e.selectedIndex!==-1&&(e.selectedIndex=-1)}}function gn(e){return"_value"in e?e._value:e.value}function $i(e,t){const n=t?"_trueValue":"_falseValue";return n in e?e[n]:t}const pu=["ctrl","shift","alt","meta"],mu={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)=>pu.some(n=>e[`${n}Key`]&&!t.includes(n))},Ve=(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=vu().createApp(...e),{mount:n}=t;return t.mount=s=>{const o=xu(s);if(!o)return;const r=t._component;!re(r)&&!r.render&&!r.template&&(r.template=o.innerHTML),o.nodeType===1&&(o.textContent="");const i=n(o,!1,bu(o));return o instanceof Element&&(o.removeAttribute("v-cloak"),o.setAttribute("data-v-app","")),i},t});function bu(e){if(e instanceof SVGElement)return"svg";if(typeof MathMLElement=="function"&&e instanceof MathMLElement)return"mathml"}function xu(e){return Oe(e)?document.querySelector(e):e}/*! * vue-router v4.6.4 * (c) 2025 Eduardo San Martin Morote @@ -23,4 +23,4 @@ * vue-router v4.6.4 * (c) 2025 Eduardo San Martin Morote * @license MIT - */let ec=()=>location.protocol+"//"+location.host;function Ui(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,a=o.slice(i);return a[0]!=="/"&&(a="/"+a),rr(a,"")}return rr(n,e)+s+o}function tc(e,t,n,s){let o=[],r=[],i=null;const a=({state:h})=>{const _=Ui(e,location),N=n.value,P=t.value;let W=0;if(h){if(n.value=_,t.value=h,i&&i===N){i=null;return}W=P?h.position-P.position:0}else s(_);o.forEach(H=>{H(n.value,N,{delta:W,type:eo.pop,direction:W?W>0?Fs.forward:Fs.back:Fs.unknown})})};function u(){i=n.value}function d(h){o.push(h);const _=()=>{const N=o.indexOf(h);N>-1&&o.splice(N,1)};return r.push(_),_}function c(){if(document.visibilityState==="hidden"){const{history:h}=window;if(!h.state)return;h.replaceState(he({},h.state,{scroll:Ss()}),"")}}function p(){for(const h of r)h();r=[],window.removeEventListener("popstate",a),window.removeEventListener("pagehide",c),document.removeEventListener("visibilitychange",c)}return window.addEventListener("popstate",a),window.addEventListener("pagehide",c),document.addEventListener("visibilitychange",c),{pauseListeners:u,listen:d,destroy:p}}function cr(e,t,n,s=!1,o=!1){return{back:e,current:t,forward:n,replaced:s,position:window.history.length,scroll:o?Ss():null}}function nc(e){const{history:t,location:n}=window,s={value:Ui(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(u,d,c){const p=e.indexOf("#"),h=p>-1?(n.host&&document.querySelector("base")?e:e.slice(p))+u:ec()+e+u;try{t[c?"replaceState":"pushState"](d,"",h),o.value=d}catch(_){console.error(_),n[c?"replace":"assign"](h)}}function i(u,d){r(u,he({},t.state,cr(o.value.back,u,o.value.forward,!0),d,{position:o.value.position}),!0),s.value=u}function a(u,d){const c=he({},o.value,t.state,{forward:u,scroll:Ss()});r(c.current,c,!0),r(u,he({},cr(s.value,u,null),{position:c.position+1},d),!1),s.value=u}return{location:s,state:o,push:a,replace:i}}function sc(e){e=Lu(e);const t=nc(e),n=tc(e,t.state,t.location,t.replace);function s(r,i=!0){i||n.pauseListeners(),history.go(r)}const o=he({location:"",base:e,go:s,createHref:qu.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 Zt=(function(e){return e[e.Static=0]="Static",e[e.Param=1]="Param",e[e.Group=2]="Group",e})({});var Me=(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})(Me||{});const oc={type:Zt.Static,value:""},rc=/[a-zA-Z0-9_]/;function ic(e){if(!e)return[[]];if(e==="/")return[[oc]];if(!e.startsWith("/"))throw new Error(`Invalid path "${e}"`);function t(_){throw new Error(`ERR (${n})/"${d}": ${_}`)}let n=Me.Static,s=n;const o=[];let r;function i(){r&&o.push(r),r=[]}let a=0,u,d="",c="";function p(){d&&(n===Me.Static?r.push({type:Zt.Static,value:d}):n===Me.Param||n===Me.ParamRegExp||n===Me.ParamRegExpEnd?(r.length>1&&(u==="*"||u==="+")&&t(`A repeatable param (${d}) must be alone in its segment. eg: '/:ids+.`),r.push({type:Zt.Param,value:d,regexp:c,repeatable:u==="*"||u==="+",optional:u==="*"||u==="?"})):t("Invalid state to consume buffer"),d="")}function h(){d+=u}for(;at.length?t.length===1&&t[0]===Je.Static+Je.Segment?1:-1:0}function Li(e,t){let n=0;const s=e.score,o=t.score;for(;n0&&t[t.length-1]<0}const dc={strict:!1,end:!0,sensitive:!1};function fc(e,t,n){const s=uc(ic(e.path),n),o=he(s,{record:e,parent:t,children:[],alias:[]});return t&&!o.record.aliasOf==!t.record.aliasOf&&t.children.push(o),o}function pc(e,t){const n=[],s=new Map;t=or(dc,t);function o(p){return s.get(p)}function r(p,h,_){const N=!_,P=mr(p);P.aliasOf=_&&_.record;const W=or(t,p),H=[P];if("alias"in p){const k=typeof p.alias=="string"?[p.alias]:p.alias;for(const x of k)H.push(mr(he({},P,{components:_?_.record.components:P.components,path:x,aliasOf:_?_.record:P})))}let D,B;for(const k of H){const{path:x}=k;if(h&&x[0]!=="/"){const O=h.record.path,U=O[O.length-1]==="/"?"":"/";k.path=h.record.path+(x&&U+x)}if(D=fc(k,h,W),_?_.alias.push(D):(B=B||D,B!==D&&B.alias.push(D),N&&p.name&&!hr(D)&&i(p.name)),Fi(D)&&u(D),P.children){const O=P.children;for(let U=0;U{i(B)}:Tn}function i(p){if(Vi(p)){const h=s.get(p);h&&(s.delete(p),n.splice(n.indexOf(h),1),h.children.forEach(i),h.alias.forEach(i))}else{const h=n.indexOf(p);h>-1&&(n.splice(h,1),p.record.name&&s.delete(p.record.name),p.children.forEach(i),p.alias.forEach(i))}}function a(){return n}function u(p){const h=vc(p,n);n.splice(h,0,p),p.record.name&&!hr(p)&&s.set(p.record.name,p)}function d(p,h){let _,N={},P,W;if("name"in p&&p.name){if(_=s.get(p.name),!_)throw xn(Re.MATCHER_NOT_FOUND,{location:p});W=_.record.name,N=he(pr(h.params,_.keys.filter(B=>!B.optional).concat(_.parent?_.parent.keys.filter(B=>B.optional):[]).map(B=>B.name)),p.params&&pr(p.params,_.keys.map(B=>B.name))),P=_.stringify(N)}else if(p.path!=null)P=p.path,_=n.find(B=>B.re.test(P)),_&&(N=_.parse(P),W=_.record.name);else{if(_=h.name?s.get(h.name):n.find(B=>B.re.test(h.path)),!_)throw xn(Re.MATCHER_NOT_FOUND,{location:p,currentLocation:h});W=_.record.name,N=he({},h.params,p.params),P=_.stringify(N)}const H=[];let D=_;for(;D;)H.unshift(D.record),D=D.parent;return{name:W,path:P,params:N,matched:H,meta:hc(H)}}e.forEach(p=>r(p));function c(){n.length=0,s.clear()}return{addRoute:r,resolve:d,removeRoute:i,clearRoutes:c,getRoutes:a,getRecordMatcher:o}}function pr(e,t){const n={};for(const s of t)s in e&&(n[s]=e[s]);return n}function mr(e){const t={path:e.path,redirect:e.redirect,name:e.name,meta:e.meta||{},aliasOf:e.aliasOf,beforeEnter:e.beforeEnter,props:mc(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 mc(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 hr(e){for(;e;){if(e.record.aliasOf)return!0;e=e.parent}return!1}function hc(e){return e.reduce((t,n)=>he(t,n.meta),{})}function vc(e,t){let n=0,s=t.length;for(;n!==s;){const r=n+s>>1;Li(e,t[r])<0?s=r:n=r+1}const o=gc(e);return o&&(s=t.lastIndexOf(o,s-1)),s}function gc(e){let t=e;for(;t=t.parent;)if(Fi(t)&&Li(e,t)===0)return t}function Fi({record:e}){return!!(e.name||e.components&&Object.keys(e.components).length||e.redirect)}function vr(e){const t=ft(As),n=ft(ko),s=we(()=>{const u=je(e.to);return t.resolve(u)}),o=we(()=>{const{matched:u}=s.value,{length:d}=u,c=u[d-1],p=n.matched;if(!c||!p.length)return-1;const h=p.findIndex(bn.bind(null,c));if(h>-1)return h;const _=gr(u[d-2]);return d>1&&gr(c)===_&&p[p.length-1].path!==_?p.findIndex(bn.bind(null,u[d-2])):h}),r=we(()=>o.value>-1&&wc(n.params,s.value.params)),i=we(()=>o.value>-1&&o.value===n.matched.length-1&&Mi(n.params,s.value.params));function a(u={}){if(yc(u)){const d=t[je(e.replace)?"replace":"push"](je(e.to)).catch(Tn);return e.viewTransition&&typeof document<"u"&&"startViewTransition"in document&&document.startViewTransition(()=>d),d}return Promise.resolve()}return{route:s,href:we(()=>s.value.href),isActive:r,isExactActive:i,navigate:a}}function bc(e){return e.length===1?e[0]:e}const xc=ei({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:vr,setup(e,{slots:t}){const n=xs(vr(e)),{options:s}=ft(As),o=we(()=>({[br(e.activeClass,s.linkActiveClass,"router-link-active")]:n.isActive,[br(e.exactActiveClass,s.linkExactActiveClass,"router-link-exact-active")]:n.isExactActive}));return()=>{const r=t.default&&bc(t.default(n));return e.custom?r:Ai("a",{"aria-current":n.isExactActive?e.ariaCurrentValue:null,href:n.href,onClick:n.navigate,class:o.value},r)}}}),_c=xc;function yc(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 wc(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(!vt(o)||o.length!==s.length||s.some((r,i)=>r.valueOf()!==o[i].valueOf()))return!1}return!0}function gr(e){return e?e.aliasOf?e.aliasOf.path:e.path:""}const br=(e,t,n)=>e??t??n,Cc=ei({name:"RouterView",inheritAttrs:!1,props:{name:{type:String,default:"default"},route:Object},compatConfig:{MODE:3},setup(e,{attrs:t,slots:n}){const s=ft(no),o=we(()=>e.route||s.value),r=ft(ur,0),i=we(()=>{let d=je(r);const{matched:c}=o.value;let p;for(;(p=c[d])&&!p.components;)d++;return d}),a=we(()=>o.value.matched[i.value]);ts(ur,we(()=>i.value+1)),ts(Xu,a),ts(no,o);const u=G();return Mt(()=>[u.value,a.value,e.name],([d,c,p],[h,_,N])=>{c&&(c.instances[p]=d,_&&_!==c&&d&&d===h&&(c.leaveGuards.size||(c.leaveGuards=_.leaveGuards),c.updateGuards.size||(c.updateGuards=_.updateGuards))),d&&c&&(!_||!bn(c,_)||!h)&&(c.enterCallbacks[p]||[]).forEach(P=>P(d))},{flush:"post"}),()=>{const d=o.value,c=e.name,p=a.value,h=p&&p.components[c];if(!h)return xr(n.default,{Component:h,route:d});const _=p.props[c],N=_?_===!0?d.params:typeof _=="function"?_(d):_:null,W=Ai(h,he({},N,t,{onVnodeUnmounted:H=>{H.component.isUnmounted&&(p.instances[c]=null)},ref:u}));return xr(n.default,{Component:W,route:d})||W}}});function xr(e,t){if(!e)return null;const n=e(t);return n.length===1?n[0]:n}const kc=Cc;function Ec(e){const t=pc(e.routes,e),n=e.parseQuery||Qu,s=e.stringifyQuery||ar,o=e.history,r=kn(),i=kn(),a=kn(),u=Al(Bt);let d=Bt;ln&&e.scrollBehavior&&"scrollRestoration"in history&&(history.scrollRestoration="manual");const c=Us.bind(null,S=>""+S),p=Us.bind(null,Tu),h=Us.bind(null,Fn);function _(S,K){let F,Y;return Vi(S)?(F=t.getRecordMatcher(S),Y=K):Y=S,t.addRoute(Y,F)}function N(S){const K=t.getRecordMatcher(S);K&&t.removeRoute(K)}function P(){return t.getRoutes().map(S=>S.record)}function W(S){return!!t.getRecordMatcher(S)}function H(S,K){if(K=he({},K||u.value),typeof S=="string"){const g=Ls(n,S,K.path),y=t.resolve({path:g.path},K),A=o.createHref(g.fullPath);return he(g,y,{params:h(y.params),hash:Fn(g.hash),redirectedFrom:void 0,href:A})}let F;if(S.path!=null)F=he({},S,{path:Ls(n,S.path,K.path).path});else{const g=he({},S.params);for(const y in g)g[y]==null&&delete g[y];F=he({},S,{params:p(g)}),K.params=p(K.params)}const Y=t.resolve(F,K),ae=S.hash||"";Y.params=c(h(Y.params));const f=Mu(s,he({},S,{hash:Ru(ae),path:Y.path})),m=o.createHref(f);return he({fullPath:f,hash:ae,query:s===ar?Yu(S.query):S.query||{}},Y,{redirectedFrom:void 0,href:m})}function D(S){return typeof S=="string"?Ls(n,S,u.value.path):he({},S)}function B(S,K){if(d!==S)return xn(Re.NAVIGATION_CANCELLED,{from:K,to:S})}function k(S){return U(S)}function x(S){return k(he(D(S),{replace:!0}))}function O(S,K){const F=S.matched[S.matched.length-1];if(F&&F.redirect){const{redirect:Y}=F;let ae=typeof Y=="function"?Y(S,K):Y;return typeof ae=="string"&&(ae=ae.includes("?")||ae.includes("#")?ae=D(ae):{path:ae},ae.params={}),he({query:S.query,hash:S.hash,params:ae.path!=null?{}:S.params},ae)}}function U(S,K){const F=d=H(S),Y=u.value,ae=S.state,f=S.force,m=S.replace===!0,g=O(F,Y);if(g)return U(he(D(g),{state:typeof g=="object"?he({},ae,g.state):ae,force:f,replace:m}),K||F);const y=F;y.redirectedFrom=K;let A;return!f&&Vu(s,Y,F)&&(A=xn(Re.NAVIGATION_DUPLICATED,{to:y,from:Y}),Ke(Y,Y,!0,!1)),(A?Promise.resolve(A):ee(y,Y)).catch(E=>It(E)?It(E,Re.NAVIGATION_GUARD_REDIRECT)?E:gt(E):ue(E,y,Y)).then(E=>{if(E){if(It(E,Re.NAVIGATION_GUARD_REDIRECT))return U(he({replace:m},D(E.to),{state:typeof E.to=="object"?he({},ae,E.to.state):ae,force:f}),K||y)}else E=De(y,Y,!0,m,ae);return V(y,Y,E),E})}function L(S,K){const F=B(S,K);return F?Promise.reject(F):Promise.resolve()}function Ae(S){const K=le.values().next().value;return K&&typeof K.runWithContext=="function"?K.runWithContext(S):S()}function ee(S,K){let F;const[Y,ae,f]=Zu(S,K);F=qs(Y.reverse(),"beforeRouteLeave",S,K);for(const g of Y)g.leaveGuards.forEach(y=>{F.push(Kt(y,S,K))});const m=L.bind(null,S,K);return F.push(m),qe(F).then(()=>{F=[];for(const g of r.list())F.push(Kt(g,S,K));return F.push(m),qe(F)}).then(()=>{F=qs(ae,"beforeRouteUpdate",S,K);for(const g of ae)g.updateGuards.forEach(y=>{F.push(Kt(y,S,K))});return F.push(m),qe(F)}).then(()=>{F=[];for(const g of f)if(g.beforeEnter)if(vt(g.beforeEnter))for(const y of g.beforeEnter)F.push(Kt(y,S,K));else F.push(Kt(g.beforeEnter,S,K));return F.push(m),qe(F)}).then(()=>(S.matched.forEach(g=>g.enterCallbacks={}),F=qs(f,"beforeRouteEnter",S,K,Ae),F.push(m),qe(F))).then(()=>{F=[];for(const g of i.list())F.push(Kt(g,S,K));return F.push(m),qe(F)}).catch(g=>It(g,Re.NAVIGATION_CANCELLED)?g:Promise.reject(g))}function V(S,K,F){a.list().forEach(Y=>Ae(()=>Y(S,K,F)))}function De(S,K,F,Y,ae){const f=B(S,K);if(f)return f;const m=K===Bt,g=ln?history.state:{};F&&(Y||m?o.replace(S.fullPath,he({scroll:m&&g&&g.scroll},ae)):o.push(S.fullPath,ae)),u.value=S,Ke(S,K,F,m),gt()}let z;function Ze(){z||(z=o.listen((S,K,F)=>{if(!bt.listening)return;const Y=H(S),ae=O(Y,bt.currentRoute.value);if(ae){U(he(ae,{replace:!0,force:!0}),Y).catch(Tn);return}d=Y;const f=u.value;ln&&Gu(lr(f.fullPath,F.delta),Ss()),ee(Y,f).catch(m=>It(m,Re.NAVIGATION_ABORTED|Re.NAVIGATION_CANCELLED)?m:It(m,Re.NAVIGATION_GUARD_REDIRECT)?(U(he(D(m.to),{force:!0}),Y).then(g=>{It(g,Re.NAVIGATION_ABORTED|Re.NAVIGATION_DUPLICATED)&&!F.delta&&F.type===eo.pop&&o.go(-1,!1)}).catch(Tn),Promise.reject()):(F.delta&&o.go(-F.delta,!1),ue(m,Y,f))).then(m=>{m=m||De(Y,f,!1),m&&(F.delta&&!It(m,Re.NAVIGATION_CANCELLED)?o.go(-F.delta,!1):F.type===eo.pop&&It(m,Re.NAVIGATION_ABORTED|Re.NAVIGATION_DUPLICATED)&&o.go(-1,!1)),V(Y,f,m)}).catch(Tn)}))}let qt=kn(),Se=kn(),de;function ue(S,K,F){gt(S);const Y=Se.list();return Y.length?Y.forEach(ae=>ae(S,K,F)):console.error(S),Promise.reject(S)}function ut(){return de&&u.value!==Bt?Promise.resolve():new Promise((S,K)=>{qt.add([S,K])})}function gt(S){return de||(de=!S,Ze(),qt.list().forEach(([K,F])=>S?F(S):K()),qt.reset()),S}function Ke(S,K,F,Y){const{scrollBehavior:ae}=e;if(!ln||!ae)return Promise.resolve();const f=!F&&Ku(lr(S.fullPath,0))||(Y||!F)&&history.state&&history.state.scroll||null;return ho().then(()=>ae(S,K,f)).then(m=>m&&Bu(m)).catch(m=>ue(m,S,K))}const Te=S=>o.go(S);let nt;const le=new Set,bt={currentRoute:u,listening:!0,addRoute:_,removeRoute:N,clearRoutes:t.clearRoutes,hasRoute:W,getRoutes:P,resolve:H,options:e,push:k,replace:x,go:Te,back:()=>Te(-1),forward:()=>Te(1),beforeEach:r.add,beforeResolve:i.add,afterEach:a.add,onError:Se.add,isReady:ut,install(S){S.component("RouterLink",_c),S.component("RouterView",kc),S.config.globalProperties.$router=bt,Object.defineProperty(S.config.globalProperties,"$route",{enumerable:!0,get:()=>je(u)}),ln&&!nt&&u.value===Bt&&(nt=!0,k(o.location).catch(Y=>{}));const K={};for(const Y in Bt)Object.defineProperty(K,Y,{get:()=>u.value[Y],enumerable:!0});S.provide(As,bt),S.provide(ko,Hr(K)),S.provide(no,u);const F=S.unmount;le.add(S),S.unmount=function(){le.delete(S),le.size<1&&(d=Bt,z&&z(),z=null,u.value=Bt,nt=!1,de=!1),F()}}};function qe(S){return S.reduce((K,F)=>K.then(()=>Ae(F)),Promise.resolve())}return bt}function Eo(){return ft(As)}function qi(e){return ft(ko)}const Xn=window.location.pathname.startsWith("/portal/"),Ye={esPortal:Xn,baseRuta:Xn?"/portal/studio/":"/studio/",apiBase:Xn?"/portal":"/app",urlLogin:Xn?"/portal/login":"/login"};function se(e){return Ye.apiBase+e}async function Zn(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=Ye.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=>Zn(e),post:(e,t)=>Zn(e,{method:"POST",body:JSON.stringify(t)}),put:(e,t)=>Zn(e,{method:"PUT",body:JSON.stringify(t)}),del:e=>Zn(e,{method:"DELETE"})},An=G(!1),Sc={class:"h-14 px-4 flex items-center gap-2 border-b border-borde"},Ac={key:0,class:"px-3 pt-3"},Ic={key:1,class:"px-3 pt-2 text-xs text-red-600 dark:text-red-400"},$c={class:"flex-1 overflow-y-auto px-2 py-3 space-y-0.5"},Rc={key:0,class:"px-2 text-xs text-tenue"},Pc={key:1,class:"px-2 text-xs text-tenue"},Oc={class:"truncate"},Tc={class:"flex items-center gap-1 mt-0.5"},Dc={class:"text-[11px] text-tenue"},Nc={key:0,class:"flex opacity-0 group-hover:opacity-100 transition-opacity pr-1.5 gap-0.5"},Mc=["onClick"],Vc=["onClick"],jc={class:"card w-full max-w-lg p-6 animate-escalar shadow-2xl"},Uc={class:"font-semibold text-texto mb-4"},Lc={key:0,class:"grid grid-cols-2 gap-3"},Fc=["value"],qc={class:"text-[11px] text-tenue mt-1"},Hc=["value"],Bc={class:"text-[11px] text-tenue mt-1"},Gc={class:"flex items-center gap-2 text-sm text-texto"},Kc={class:"flex justify-end gap-2 pt-2"},Wc={__name:"Sidebar",setup(e,{expose:t}){const n=qi(),s=Eo(),o=G([]),r=G([]),i=G([]),a=G(!0),u=G(""),d=G(!1),c=G(null),p=G(_()),h=we(()=>n.params.tenantId||n.params.id);Mt(()=>n.fullPath,()=>{An.value=!1});function _(){return{nombre:"",dominios_permitidos:"",activo:!0,cliente_id:null,plan_id:null}}async function N(){a.value=!0,u.value="";try{const x=await oe.get(se("/umind/tenants"));o.value=x.items||[]}catch(x){u.value=x.message}finally{a.value=!1}}function P(x){return Array.isArray(x)?x:(x==null?void 0:x.items)||(x==null?void 0:x.registros)||[]}async function W(){if(Ye.esPortal)return;const[x,O]=await Promise.allSettled([oe.get("/app/api/clientes/select"),oe.get("/app/umind-planes/list")]);r.value=x.status==="fulfilled"?P(x.value):[],i.value=O.status==="fulfilled"?P(O.value):[];const U=[];x.status==="rejected"&&U.push("clientes"),O.status==="rejected"&&U.push("planes"),U.length&&(u.value=`No se pudo cargar la lista de ${U.join(" ni ")}.`)}function H(){c.value=null,p.value=_(),d.value=!0}function D(x){c.value=x,p.value={nombre:x.nombre,dominios_permitidos:x.dominios_permitidos,activo:x.activo,cliente_id:x.cliente_id??null,plan_id:x.plan_id??null},d.value=!0}async function B(){const x={...p.value,dominios_permitidos:p.value.dominios_permitidos.split(",").map(O=>O.trim()).filter(Boolean)};try{if(c.value)await oe.put(se(`/umind/tenants/${c.value.ID}`),x),d.value=!1,await N();else{const O=await oe.post(se("/umind/tenants"),x);d.value=!1,await N(),s.push(`/tenants/${O.id}`)}}catch(O){u.value=O.message}}async function k(x){confirm(`¿Eliminar el espacio "${x.nombre}"? Esto borra también sus agentes. No se puede deshacer.`)&&(await oe.del(se(`/umind/tenants/${x.ID}`)),h.value===String(x.ID)&&s.push("/"),await N())}return t({recargar:N}),xo(()=>{N(),W()}),(x,O)=>{const U=yn("router-link");return w(),C(ie,null,[je(An)?(w(),C("div",{key:0,class:"fixed inset-0 bg-black/50 z-30 md:hidden",onClick:O[0]||(O[0]=L=>An.value=!1)})):J("",!0),l("aside",{class:Ee(["w-64 shrink-0 flex flex-col border-r border-borde bg-superficie fixed inset-y-0 left-0 z-40 transition-transform duration-200 md:static md:h-screen md:sticky md:top-0 md:translate-x-0",je(An)?"translate-x-0":"-translate-x-full"])},[l("div",Sc,[Ce(U,{to:"/",class:"flex items-center gap-2 text-base font-semibold text-texto"},{default:ct(()=>[...O[8]||(O[8]=[l("svg",{viewBox:"0 0 96 96",class:"w-6 h-6 shrink-0","aria-hidden":"true"},[l("rect",{width:"96",height:"96",rx:"22",fill:"#8eb02f"}),l("path",{d:"M32,42 V58 A14,14 0 0 0 60,58 V42",fill:"none",stroke:"#fff","stroke-width":"10","stroke-linecap":"round","stroke-linejoin":"round"}),l("path",{d:"M60,58 V64",fill:"none",stroke:"#fff","stroke-width":"10","stroke-linecap":"round"}),l("circle",{cx:"60",cy:"28",r:"7",fill:"#fff"})],-1),l("span",null,[pe("uMind "),l("span",{class:"text-brand"},"Studio")],-1)])]),_:1})]),je(Ye).esPortal?J("",!0):(w(),C("div",Ac,[l("button",{class:"btn-primary w-full",onClick:H}," + Nuevo espacio ")])),u.value?(w(),C("p",Ic,R(u.value),1)):J("",!0),l("nav",$c,[a.value?(w(),C("p",Rc,"Cargando...")):o.value.length===0?(w(),C("p",Pc,R(je(Ye).esPortal?"Todavía no tenés ningún espacio asignado. Escribinos y lo activamos.":"Sin espacios todavía."),1)):J("",!0),(w(!0),C(ie,null,Pe(o.value,L=>(w(),C("div",{key:L.ID,class:Ee(["group flex items-center rounded-lg transition-colors",h.value===String(L.ID)?"bg-brand/10":"hover:bg-elevado"])},[Ce(U,{to:`/tenants/${L.ID}`,class:Ee(["flex-1 min-w-0 px-2.5 py-2 text-sm",h.value===String(L.ID)?"text-brand font-medium":"text-texto"])},{default:ct(()=>[l("div",Oc,R(L.nombre),1),l("div",Tc,[l("span",{class:Ee(["w-1.5 h-1.5 rounded-full",L.activo?"bg-green-500":"bg-tenue/40"])},null,2),l("span",Dc,R(L.activo?"activo":"inactivo"),1)])]),_:2},1032,["to","class"]),je(Ye).esPortal?J("",!0):(w(),C("div",Nc,[l("button",{class:"p-1 text-tenue hover:text-texto",title:"Editar",onClick:Ae=>D(L)}," ✎ ",8,Mc),l("button",{class:"p-1 text-tenue hover:text-red-600",title:"Eliminar",onClick:Ae=>k(L)}," ✕ ",8,Vc)]))],2))),128))])],2),d.value?(w(),C("div",{key:1,class:"fixed inset-0 bg-black/40 flex items-center justify-center p-4 z-50",onClick:O[7]||(O[7]=Ve(L=>d.value=!1,["self"]))},[l("div",jc,[l("h2",Uc,R(c.value?"Editar espacio":"Nuevo espacio"),1),O[17]||(O[17]=l("p",{class:"text-xs text-tenue mb-3"}," Un espacio es el negocio o sitio dueño de los dominios permitidos. La config de IA, tono y demás se configuran por agente, dentro del tenant. ",-1)),l("form",{class:"space-y-3",onSubmit:Ve(B,["prevent"])},[l("div",null,[O[9]||(O[9]=l("label",{class:"label"},"Nombre",-1)),ne(l("input",{"onUpdate:modelValue":O[1]||(O[1]=L=>p.value.nombre=L),required:"",class:"input"},null,512),[[fe,p.value.nombre]])]),l("div",null,[O[10]||(O[10]=l("label",{class:"label"},"Dominios permitidos (separados por coma)",-1)),ne(l("input",{"onUpdate:modelValue":O[2]||(O[2]=L=>p.value.dominios_permitidos=L),placeholder:"ejemplo.com, www.ejemplo.com",required:"",class:"input"},null,512),[[fe,p.value.dominios_permitidos]])]),je(Ye).esPortal?J("",!0):(w(),C("div",Lc,[l("div",null,[O[12]||(O[12]=l("label",{class:"label"},"Cliente",-1)),ne(l("select",{"onUpdate:modelValue":O[3]||(O[3]=L=>p.value.cliente_id=L),class:"input"},[O[11]||(O[11]=l("option",{value:null},"— sin asignar —",-1)),(w(!0),C(ie,null,Pe(r.value,L=>(w(),C("option",{key:L.ID,value:L.ID},R(L.nombre),9,Fc))),128))],512),[[vn,p.value.cliente_id]]),l("p",qc,R(r.value.length?"Define quién ve este espacio desde el portal.":"No hay clientes activos — creá uno en Clientes."),1)]),l("div",null,[O[14]||(O[14]=l("label",{class:"label"},"Plan",-1)),ne(l("select",{"onUpdate:modelValue":O[4]||(O[4]=L=>p.value.plan_id=L),class:"input"},[O[13]||(O[13]=l("option",{value:null},"— sin plan —",-1)),(w(!0),C(ie,null,Pe(i.value,L=>(w(),C("option",{key:L.ID,value:L.ID},R(L.nombre)+" ("+R(L.max_agentes===0?"∞":L.max_agentes)+" agentes) ",9,Hc))),128))],512),[[vn,p.value.plan_id]]),l("p",Bc,R(i.value.length?"Límite de agentes y precios de consumo.":"No hay planes — creá uno en uMind Planes."),1)])])),l("label",Gc,[ne(l("input",{"onUpdate:modelValue":O[5]||(O[5]=L=>p.value.activo=L),type:"checkbox"},null,512),[[Rt,p.value.activo]]),O[15]||(O[15]=pe(" Activo ",-1))]),l("div",Kc,[l("button",{type:"button",class:"btn-ghost",onClick:O[6]||(O[6]=L=>d.value=!1)}," Cancelar "),O[16]||(O[16]=l("button",{type:"submit",class:"btn-primary"}," Guardar ",-1))])],32)])])):J("",!0)],64)}}},Hi="umind-tema";function zc(){return window.matchMedia("(prefers-color-scheme: dark)").matches?"oscuro":"claro"}const pn=G(localStorage.getItem(Hi)||zc());function Bi(){document.documentElement.classList.toggle("dark",pn.value==="oscuro")}function _r(){pn.value=pn.value==="oscuro"?"claro":"oscuro",localStorage.setItem(Hi,pn.value),Bi()}Bi();const Jc={class:"min-h-screen flex"},Qc={class:"flex-1 min-w-0 flex flex-col"},Yc={class:"h-14 shrink-0 flex items-center gap-1 px-4 sm:px-6 border-b border-borde"},Xc=["title"],Zc={class:"text-base leading-none"},ed={class:"flex-1 max-w-5xl w-full mx-auto px-4 sm:px-6 lg:px-8 py-6 sm:py-8 animate-aparecer"},td={__name:"App",setup(e){return(t,n)=>{const s=yn("router-view");return w(),C("div",Jc,[Ce(Wc),l("main",Qc,[l("header",Yc,[l("button",{class:"btn-ghost !px-2 !py-1.5 md:hidden","aria-label":"Abrir menú",onClick:n[0]||(n[0]=o=>An.value=!0)},[...n[2]||(n[2]=[l("svg",{class:"w-5 h-5",fill:"none",stroke:"currentColor","stroke-width":"2",viewBox:"0 0 24 24"},[l("path",{"stroke-linecap":"round","stroke-linejoin":"round",d:"M4 6h16M4 12h16M4 18h16"})],-1)])]),n[3]||(n[3]=l("span",{class:"flex-1"},null,-1)),l("button",{class:"btn-ghost !px-2.5 !py-1.5",title:je(pn)==="oscuro"?"Cambiar a claro":"Cambiar a oscuro",onClick:n[1]||(n[1]=(...o)=>je(_r)&&je(_r)(...o))},[l("span",Zc,R(je(pn)==="oscuro"?"☀️":"🌙"),1)],8,Xc)]),l("div",ed,[Ce(s)])])])}}},nd=(e,t)=>{const n=e.__vccOpts||e;for(const[s,o]of t)n[s]=o;return n},sd=["width","height","aria-label"],od=["fill"],rd=["stroke"],id=["cy"],ld=["cy"],ad=["cy"],ud=["cy"],cd={key:1,d:"M41,66 h12 M67,66 h12",class:"umi-linea","stroke-width":"5","stroke-linecap":"round",fill:"none"},dd={key:4,d:"M50,78 q10,8 20,0",class:"umi-linea","stroke-width":"4",fill:"none","stroke-linecap":"round"},fd={__name:"UiMascota",props:{estado:{type:String,default:"normal"},tam:{type:[Number,String],default:72}},setup(e){return(t,n)=>(w(),C("svg",{width:e.tam,height:e.tam,viewBox:"0 0 120 120",class:"shrink-0",role:"img","aria-label":`Umi, la mascota de uMind (${e.estado})`},[l("circle",{cx:"60",cy:"26",r:"6",fill:e.estado==="alerta"?"#dc2626":"currentColor",class:Ee(e.estado==="pensando"?"umi-late":"")},null,10,od),l("line",{x1:"60",y1:"32",x2:"60",y2:"44",stroke:e.estado==="alerta"?"#dc2626":"currentColor","stroke-width":"4","stroke-linecap":"round"},null,8,rd),n[7]||(n[7]=l("path",{d:"M30,46 V76 A30,30 0 0 0 90,76 V46 Z",fill:"currentColor"},null,-1)),e.estado==="normal"||e.estado==="contenta"||e.estado==="alerta"?(w(),C(ie,{key:0},[l("circle",{cx:"47",cy:e.estado==="contenta"?64:66,r:"6",class:"umi-ojo"},null,8,id),l("circle",{cx:"73",cy:e.estado==="contenta"?64:66,r:"6",class:"umi-ojo"},null,8,ld),l("circle",{cx:"48",cy:e.estado==="contenta"?65:67,r:"3",class:"umi-pupila"},null,8,ad),l("circle",{cx:"74",cy:e.estado==="contenta"?65:67,r:"3",class:"umi-pupila"},null,8,ud)],64)):e.estado==="durmiendo"?(w(),C("path",cd)):e.estado==="pensando"?(w(),C(ie,{key:2},[n[0]||(n[0]=l("circle",{cx:"45",cy:"66",r:"4.5",class:"umi-ojo umi-p1"},null,-1)),n[1]||(n[1]=l("circle",{cx:"60",cy:"66",r:"4.5",class:"umi-ojo umi-p2"},null,-1)),n[2]||(n[2]=l("circle",{cx:"75",cy:"66",r:"4.5",class:"umi-ojo umi-p3"},null,-1))],64)):e.estado==="buscando"?(w(),C(ie,{key:3},[n[3]||(n[3]=l("circle",{cx:"47",cy:"66",r:"6",class:"umi-ojo"},null,-1)),n[4]||(n[4]=l("circle",{cx:"73",cy:"66",r:"6",class:"umi-ojo"},null,-1)),n[5]||(n[5]=l("circle",{cx:"50",cy:"66",r:"3",class:"umi-pupila"},null,-1)),n[6]||(n[6]=l("circle",{cx:"76",cy:"66",r:"3",class:"umi-pupila"},null,-1))],64)):J("",!0),e.estado==="contenta"?(w(),C("path",dd)):J("",!0)],8,sd))}},Gi=nd(fd,[["__scopeId","data-v-551897a0"]]),pd={key:0,class:"flex flex-col items-center justify-center py-24 text-sm text-tenue"},md={key:1,class:"max-w-md mx-auto text-center py-20"},hd={key:2,class:"flex flex-col items-center justify-center text-center py-24"},vd={class:"text-lg font-medium text-texto"},gd={class:"text-sm text-tenue mt-1"},bd={__name:"Home",setup(e){const t=Eo(),n=G(Ye.esPortal),s=G(!1);async function o(){if(Ye.esPortal)try{const i=(await oe.get(se("/umind/tenants"))).items||[];if(i.length===0){s.value=!0;return}if(i.length!==1)return;const a=i[0].ID,d=(await oe.get(se(`/umind/agentes?tenant_id=${a}`))).items||[];if(d.length===1){t.replace(`/tenants/${a}/agentes/${d[0].ID}`);return}t.replace(`/tenants/${a}`)}catch{}finally{n.value=!1}}return xo(o),(r,i)=>n.value?(w(),C("div",pd," Abriendo tu asistente… ")):s.value?(w(),C("div",md,[Ce(Gi,{estado:"durmiendo",tam:80,class:"mx-auto mb-4 text-brand"}),i[0]||(i[0]=ki('

Todavía no tenés un asistente activo

uMind contesta por vos en WhatsApp y en tu sitio, con la información de tu negocio. Entiende las notas de voz y lee las fotos y archivos que te mandan tus clientes.

Quiero activarlo

Volver al portal

',4))])):(w(),C("div",hd,[i[1]||(i[1]=l("div",{class:"text-4xl mb-4"},"💬",-1)),l("h1",vd,R(je(Ye).esPortal?"Elegí tu espacio de la izquierda":"Elegí un espacio de la izquierda"),1),l("p",gd,R(je(Ye).esPortal?"Adentro vas a poder crear y configurar tus agentes.":"o creá uno nuevo para empezar a configurar su agente."),1)]))}},xd={class:"flex flex-col items-center justify-center text-center py-12 px-6"},_d={key:0,class:"text-3xl mb-3 opacity-70"},yd={class:"text-sm font-medium text-texto"},wd={key:2,class:"text-xs text-tenue mt-1.5 max-w-sm leading-relaxed"},Cd={key:3,class:"mt-4"},Ot={__name:"UiEmptyState",props:{estado:{type:String,default:"durmiendo"},titulo:String,detalle:String,icono:{type:String,default:""}},setup(e){return(t,n)=>(w(),C("div",xd,[e.icono?(w(),C("div",_d,R(e.icono),1)):(w(),tt(Gi,{key:1,estado:e.estado,tam:64,class:"mb-3 text-brand"},null,8,["estado"])),l("p",yd,R(e.titulo),1),e.detalle?(w(),C("p",wd,R(e.detalle),1)):J("",!0),t.$slots.default?(w(),C("div",Cd,[na(t.$slots,"default")])):J("",!0)]))}},kd={key:0,class:"mb-6"},Ed={class:"flex items-start justify-between gap-4"},Sd={class:"text-xl font-semibold text-texto"},Ad={class:"text-xs text-tenue mt-1"},Id={key:1,class:"text-sm text-red-600 dark:text-red-400 mb-4"},$d={class:"flex items-center justify-between mb-4"},Rd={class:"flex items-center gap-2"},Pd={key:0,class:"badge-alerta"},Od={key:1,class:"badge-neutro"},Td=["disabled"],Dd={key:2,class:"text-xs text-tenue -mt-2 mb-4"},Nd={key:3,class:"text-xs text-tenue -mt-2 mb-4"},Md={key:4,class:"grid gap-3 sm:grid-cols-2"},Vd=["disabled"],jd={key:6,class:"grid gap-3 sm:grid-cols-2"},Ud={class:"flex items-start gap-3"},Ld={class:"min-w-0 flex-1"},Fd={class:"flex items-center gap-2"},qd={class:"font-medium text-texto truncate"},Hd={class:"text-xs text-tenue mt-0.5 truncate"},Bd={class:"flex gap-0.5 opacity-0 group-hover:opacity-100 transition-opacity shrink-0"},Gd=["onClick"],Kd=["onClick"],Wd=["onClick"],zd={class:"flex items-center gap-4 mt-3.5 pt-3 border-t border-borde text-xs text-tenue"},Jd={class:"tabular-nums"},Qd={class:"text-texto font-medium"},Yd={class:"tabular-nums"},Xd={class:"text-texto font-medium"},Zd={class:"tabular-nums"},ef={class:"text-texto font-medium"},tf={class:"bg-white dark:bg-gray-900 border border-gray-200 dark:border-gray-800 rounded-xl p-6 w-full max-w-lg max-h-[calc(100vh-2rem)] overflow-y-auto"},nf={class:"font-semibold text-gray-800 dark:text-gray-100 mb-4"},sf={key:0},of={class:"grid gap-1.5"},rf=["value"],lf={class:"min-w-0"},af={class:"block text-sm text-texto"},uf={class:"block text-xs text-tenue"},cf={key:0,class:"block text-xs text-tenue mt-0.5"},df=["value"],ff={class:"flex items-center gap-2"},pf={class:"flex items-center gap-2 text-sm text-gray-600 dark:text-gray-300"},mf={class:"flex justify-end gap-2 pt-2"},hf={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=we(()=>Number(t.id)),s=Eo(),o=G(null),r=G([]),i=G([]),a=G(""),u=G(!1),d=G(null),c=G(D()),p=G(null),h=G({}),_=G(!0);function N(ee){const V=h.value[ee.ID]||{};return ee.activo?V.documentos>0?{tipo:"ok",texto:"listo"}:{tipo:"alerta",texto:"sin conocimiento"}:{tipo:"neutro",texto:"inactivo"}}function P(ee){const V=h.value[ee.ID]||{};return{documentos:V.documentos||0,canales:V.canales||0,conversaciones:V.conversaciones_7d||0}}function W(ee){return String(ee||"?").trim().split(/\s+/).slice(0,2).map(V=>V[0]).join("").toUpperCase()}const H=we(()=>{if(!p.value)return{sinPlan:!0};const ee=p.value.max_agentes||0;return{sinPlan:!1,nombre:p.value.nombre,ilimitado:ee<=0,max:ee,usados:r.value.length,lleno:ee>0&&r.value.length>=ee}});function D(){return{nombre:"",ai_config_id:null,tono:"",mensaje_bienvenida:"",color:"#8eb02f",activo:!0,plantilla_rubro:""}}const B=G([]);async function k(){a.value="",_.value=!0;try{const[ee,V,De,z]=await Promise.all([oe.get(se("/umind/tenants")),oe.get(se(`/umind/agentes?tenant_id=${t.id}`)),oe.get(se("/umind/ai-configs")),oe.get(se("/umind/plantillas-rubro"))]);o.value=(ee.items||[]).find(Ze=>String(Ze.ID)===t.id)||null,r.value=V.items||[],p.value=V.plan||null,h.value=V.resumen||{},i.value=De.items||[],B.value=z.items||[]}catch(ee){a.value=ee.message}finally{_.value=!1}}async function x(ee){const V=prompt(`Nombre de la copia de "${ee.nombre}":`,`${ee.nombre} (copia)`);if(V!==null){a.value="";try{const De=await oe.post(se(`/umind/agentes/${ee.ID}/duplicar`),{tenant_id:Number(n.value),nombre:V.trim()});await k(),De.aviso&&alert(De.aviso)}catch(De){a.value=De.message}}}function O(){d.value=null,c.value=D(),u.value=!0}function U(ee){d.value=ee,c.value={nombre:ee.nombre,ai_config_id:ee.ai_config_id,tono:ee.tono,mensaje_bienvenida:ee.mensaje_bienvenida,color:ee.color||"#8eb02f",activo:ee.activo},u.value=!0}async function L(){try{if(d.value)await oe.put(se(`/umind/agentes/${d.value.ID}`),{tenant_id:n.value,...c.value}),u.value=!1,await k();else{const ee=await oe.post(se("/umind/agentes"),{tenant_id:n.value,...c.value});u.value=!1,s.push(`/tenants/${n.value}/agentes/${ee.id}`)}}catch(ee){a.value=ee.message}}async function Ae(ee){confirm(`¿Eliminar el agente "${ee.nombre}"? Esto no se puede deshacer.`)&&(await oe.del(se(`/umind/agentes/${ee.ID}`)),await k())}return Mt(()=>t.id,k,{immediate:!0}),(ee,V)=>{const De=yn("router-link");return w(),C("div",null,[o.value?(w(),C("div",kd,[l("div",Ed,[l("div",null,[l("h1",Sd,R(o.value.nombre),1),l("p",Ad,R(o.value.dominios_permitidos||"sin dominios configurados"),1)]),Ce(De,{to:`/tenants/${n.value??e.id}/ia`,class:"btn-ghost"},{default:ct(()=>[...V[10]||(V[10]=[pe("Tu IA",-1)])]),_:1},8,["to"]),Ce(De,{to:`/tenants/${n.value??e.id}/uso`,class:"btn-ghost"},{default:ct(()=>[...V[11]||(V[11]=[pe("📊 Consumo",-1)])]),_:1},8,["to"])])])):J("",!0),a.value?(w(),C("p",Id,R(a.value),1)):J("",!0),l("div",$d,[l("div",Rd,[V[12]||(V[12]=l("h2",{class:"text-sm font-medium text-tenue"},"Agentes",-1)),H.value.sinPlan?(w(),C("span",Pd,"sin plan · sin límite")):H.value.ilimitado?(w(),C("span",Od,R(H.value.nombre)+" · ilimitado",1)):(w(),C("span",{key:2,class:Ee(H.value.lleno?"badge-alerta":"badge-neutro")},R(H.value.nombre)+" · "+R(H.value.usados)+" de "+R(H.value.max),3))]),l("button",{class:"btn-primary",disabled:H.value.lleno,onClick:O},"+ Nuevo agente",8,Td)]),H.value.sinPlan&&!je(Ye).esPortal?(w(),C("p",Dd," Este espacio no tiene plan asignado, así que no se le aplica ningún límite de agentes. Asignale uno desde el lápiz del espacio, en la barra izquierda. ")):H.value.lleno?(w(),C("p",Nd," Alcanzaste el máximo de agentes de tu plan. ")):J("",!0),_.value?(w(),C("div",Md,[(w(),C(ie,null,Pe(2,z=>l("div",{key:z,class:"card p-4 animate-pulse"},[...V[13]||(V[13]=[ki('
',2)])])),64))])):r.value.length===0?(w(),tt(Ot,{key:5,class:"card",estado:"durmiendo",titulo:"Todavía no hay agentes",detalle:"Creá el primero y cargale su base de conocimiento para que empiece a responder."},{default:ct(()=>[l("button",{class:"btn-primary",disabled:H.value.lleno,onClick:O},"+ Crear el primer agente",8,Vd)]),_:1})):(w(),C("div",jd,[(w(!0),C(ie,null,Pe(r.value,z=>(w(),tt(De,{key:z.ID,to:`/tenants/${n.value}/agentes/${z.ID}`,class:"card p-4 relative group hover:shadow-lg hover:-translate-y-0.5 transition-all overflow-hidden"},{default:ct(()=>[l("span",{class:"absolute inset-x-0 top-0 h-1",style:nn({background:z.color||"#8eb02f"})},null,4),l("div",Ud,[l("span",{class:"w-10 h-10 rounded-xl flex items-center justify-center text-white text-sm font-semibold shrink-0",style:nn({background:z.color||"#8eb02f",opacity:z.activo?1:.4})},R(W(z.nombre)),5),l("div",Ld,[l("div",Fd,[l("span",qd,R(z.nombre),1),l("span",{class:Ee(`badge-${N(z).tipo}`)},R(N(z).texto),3)]),l("p",Hd,R(z.tono||"sin tono definido"),1)]),l("div",Bd,[l("button",{class:"p-1 text-tenue hover:text-texto",title:"Editar",onClick:Ve(Ze=>U(z),["prevent","stop"])},"✎",8,Gd),l("button",{class:"p-1 text-tenue hover:text-texto",title:"Duplicar: copia el conocimiento y las herramientas a un agente nuevo",onClick:Ve(Ze=>x(z),["prevent","stop"])},"⧉",8,Kd),l("button",{class:"p-1 text-tenue hover:text-red-600",title:"Eliminar",onClick:Ve(Ze=>Ae(z),["prevent","stop"])},"✕",8,Wd)])]),l("div",zd,[l("span",Jd,[l("b",Qd,R(P(z).conversaciones),1),V[14]||(V[14]=pe(" conversaciones · 7d",-1))]),l("span",Yd,[l("b",Xd,R(P(z).documentos),1),V[15]||(V[15]=pe(" fuentes",-1))]),l("span",Zd,[l("b",ef,R(P(z).canales),1),V[16]||(V[16]=pe(" canales",-1))])])]),_:2},1032,["to"]))),128))])),u.value?(w(),C("div",{key:7,class:"fixed inset-0 bg-black/40 flex items-center justify-center p-4 z-50",onClick:V[9]||(V[9]=Ve(z=>u.value=!1,["self"]))},[l("div",tf,[l("h2",nf,R(d.value?"Editar agente":"Nuevo agente"),1),l("form",{class:"space-y-3",onSubmit:Ve(L,["prevent"])},[l("div",null,[V[17]||(V[17]=l("label",{class:"label"},"Nombre",-1)),ne(l("input",{"onUpdate:modelValue":V[0]||(V[0]=z=>c.value.nombre=z),required:"",placeholder:"ej: Ventas, Soporte",class:"input"},null,512),[[fe,c.value.nombre]])]),!d.value&&B.value.length?(w(),C("div",sf,[V[18]||(V[18]=l("label",{class:"label"},"Arrancar con",-1)),l("div",of,[(w(!0),C(ie,null,Pe([{clave:"",nombre:"Agente en blanco",descripcion:"Sin conocimiento cargado. Lo escribís vos desde cero."},...B.value],z=>(w(),C("label",{key:z.clave,class:Ee(["flex gap-2.5 p-2.5 rounded-lg border cursor-pointer transition-colors",c.value.plantilla_rubro===z.clave?"border-brand bg-brand/5":"border-borde hover:border-brand/40"])},[ne(l("input",{"onUpdate:modelValue":V[1]||(V[1]=Ze=>c.value.plantilla_rubro=Ze),type:"radio",value:z.clave,class:"mt-1 text-brand focus:ring-brand"},null,8,rf),[[fu,c.value.plantilla_rubro]]),l("span",lf,[l("span",af,R(z.nombre),1),l("span",uf,R(z.descripcion),1),z.notas?(w(),C("span",cf,R(z.notas)+" notas listas para editar · "+R(z.resumen),1)):J("",!0)])],2))),128))]),V[19]||(V[19]=l("p",{class:"text-xs text-tenue mt-1.5"}," Las notas vienen con ejemplos entre corchetes — abrilas y reemplazalas por tus datos reales. ",-1))])):J("",!0),l("div",null,[V[21]||(V[21]=l("label",{class:"label"},"Config de IA",-1)),ne(l("select",{"onUpdate:modelValue":V[2]||(V[2]=z=>c.value.ai_config_id=z),class:"input"},[V[20]||(V[20]=l("option",{value:null},"— sin asignar —",-1)),(w(!0),C(ie,null,Pe(i.value,z=>(w(),C("option",{key:z.ID,value:z.ID},R(z.nombre)+" ("+R(z.provider)+")",9,df))),128))],512),[[vn,c.value.ai_config_id]])]),l("div",null,[V[22]||(V[22]=l("label",{class:"label"},"Tono / personalidad",-1)),ne(l("textarea",{"onUpdate:modelValue":V[3]||(V[3]=z=>c.value.tono=z),rows:"2",class:"input"},null,512),[[fe,c.value.tono]])]),l("div",null,[V[23]||(V[23]=l("label",{class:"label"},"Mensaje de bienvenida",-1)),ne(l("input",{"onUpdate:modelValue":V[4]||(V[4]=z=>c.value.mensaje_bienvenida=z),class:"input"},null,512),[[fe,c.value.mensaje_bienvenida]])]),l("div",null,[V[24]||(V[24]=l("label",{class:"label"},"Color del widget",-1)),l("div",ff,[ne(l("input",{"onUpdate:modelValue":V[5]||(V[5]=z=>c.value.color=z),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),[[fe,c.value.color]]),ne(l("input",{"onUpdate:modelValue":V[6]||(V[6]=z=>c.value.color=z),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),[[fe,c.value.color]])])]),l("label",pf,[ne(l("input",{"onUpdate:modelValue":V[7]||(V[7]=z=>c.value.activo=z),type:"checkbox"},null,512),[[Rt,c.value.activo]]),V[25]||(V[25]=pe(" Activo ",-1))]),l("div",mf,[l("button",{type:"button",class:"px-4 py-2 text-sm text-gray-500 dark:text-gray-400",onClick:V[8]||(V[8]=z=>u.value=!1)},"Cancelar"),l("button",hf,R(d.value?"Guardar":"Crear"),1)])],32)])])):J("",!0)])}}},gf={key:0,class:"mb-6 mt-1 flex items-start justify-between gap-4"},bf={class:"min-w-0"},xf={class:"text-xl font-semibold text-texto"},_f={class:"text-xs text-tenue mt-1"},yf={class:"bg-elevado px-1.5 py-0.5 rounded"},wf=["href"],Cf={key:1,class:"text-sm text-red-600 dark:text-red-400 mb-4"},kf={class:"flex gap-1.5 mb-6 overflow-x-auto sin-barra pb-1"},Ef=["onClick"],Sf={key:2},Af={class:"card p-4 mb-4"},If={class:"flex gap-1 mb-3"},$f=["onClick"],Rf={class:"flex items-center justify-between"},Pf=["disabled"],Of={class:"flex items-center justify-between"},Tf=["disabled"],Df={class:"flex gap-2"},Nf={class:"flex items-center justify-between"},Mf={class:"flex items-center gap-2 text-xs text-tenue cursor-pointer"},Vf=["disabled"],jf={class:"card divide-y divide-borde"},Uf={class:"text-sm text-texto"},Lf={class:"text-xs text-tenue mt-0.5"},Ff={key:0},qf={key:1},Hf={key:2},Bf={key:3,class:"text-red-600 dark:text-red-400"},Gf={class:"flex items-center gap-3 shrink-0"},Kf=["title","onClick"],Wf=["onClick"],zf=["disabled","title","onClick"],Jf=["onClick"],Qf={class:"card w-full max-w-2xl p-6 max-h-[calc(100vh-2rem)] overflow-y-auto"},Yf={class:"flex justify-end gap-2 pt-1"},Xf=["disabled"],Zf={key:3},ep={class:"card divide-y divide-borde"},tp={class:"text-sm text-texto font-mono"},np={class:"label mt-0.5"},sp={class:"text-xs text-tenue mt-0.5"},op={key:0,class:"ml-1 text-green-600 dark:text-green-400"},rp={key:1,class:"ml-1 text-gray-400"},ip={class:"flex gap-3 text-sm shrink-0"},lp=["onClick"],ap=["onClick"],up={class:"card p-6 w-full max-w-xl max-h-[85vh] overflow-y-auto"},cp={class:"font-semibold text-texto mb-4"},dp={class:"border border-borde rounded-lg p-3 space-y-2"},fp=["onUpdate:modelValue"],pp=["onUpdate:modelValue"],mp=["onUpdate:modelValue"],hp={class:"label flex items-center gap-1"},vp=["onUpdate:modelValue"],gp=["onClick"],bp={key:0,class:"text-xs text-gray-400"},xp={class:"border border-borde rounded-lg p-3 space-y-2"},_p={class:"flex items-center gap-2 label"},yp={class:"flex items-center gap-2 text-sm text-texto"},wp={class:"flex justify-end gap-2 pt-2"},Cp={key:4},kp={class:"card p-4 mb-4"},Ep={class:"flex items-center justify-between mb-2"},Sp={class:"bg-elevado border border-borde rounded-lg p-2.5 text-xs text-texto overflow-x-auto"},Ap={class:"card divide-y divide-borde"},Ip={class:"flex items-center justify-between"},$p={class:"font-medium text-texto capitalize"},Rp={class:"flex gap-3 text-sm"},Pp=["onClick"],Op=["onClick"],Tp={class:"flex gap-4 mt-2 text-xs"},Dp={class:"flex items-center gap-1.5 text-texto cursor-pointer"},Np=["checked","onChange"],Mp={class:"flex items-center gap-1.5 text-texto cursor-pointer"},Vp=["checked","onChange"],jp={class:"flex items-center gap-1.5 text-texto cursor-pointer"},Up=["checked","onChange"],Lp={class:"label mt-1 break-all"},Fp={class:"bg-elevado px-1 rounded"},qp={key:0,class:"text-xs text-tenue mt-1"},Hp={key:1,class:"text-xs text-red-600 dark:text-red-400 mt-1"},Bp={class:"card p-6 w-full max-w-md"},Gp={key:0},Kp={class:"flex flex-col gap-2 pt-1"},Wp={class:"flex items-center gap-2 text-sm text-texto cursor-pointer"},zp={class:"flex items-center gap-2 text-sm text-texto cursor-pointer"},Jp={class:"flex items-center gap-2 text-sm text-texto cursor-pointer"},Qp={class:"flex justify-end gap-2 pt-2"},Yp={key:5},Xp={class:"flex gap-2 mb-4"},Zp={class:"card divide-y divide-borde"},em={class:"font-medium text-texto capitalize"},tm={class:"ml-2 text-sm text-tenue"},nm=["onClick"],sm={key:6,class:"card p-4 flex flex-col h-[28rem]"},om={class:"flex-1 overflow-y-auto space-y-2 mb-3"},rm={key:0,class:"text-sm text-tenue"},im={key:1,class:"text-xs text-tenue"},lm=["disabled"],am={key:7,class:"grid grid-cols-3 gap-4"},um={class:"col-span-1 card divide-y divide-borde max-h-[28rem] overflow-y-auto"},cm=["onClick"],dm={class:"text-texto truncate"},fm={class:"text-xs text-tenue mt-0.5"},pm={class:"col-span-2 card p-4 max-h-[28rem] overflow-y-auto space-y-2"},mm={key:0,class:"text-sm text-tenue"},hm={key:8},vm={class:"card divide-y divide-borde max-h-[32rem] overflow-y-auto"},gm={class:"cursor-pointer flex items-center gap-2 text-sm"},bm={class:"text-tenue text-xs shrink-0"},xm={class:"text-texto truncate"},_m={class:"text-tenue text-xs ml-auto shrink-0"},ym={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"},wm={__name:"AgenteDetail",props:{tenantId:{type:String,required:!0},agenteId:{type:String,required:!0}},setup(e){const t=e,n=we(()=>Number(t.agenteId)),s=qi(),o=G(null),r=G(""),i=G(typeof s.query.tab=="string"?s.query.tab:Ye.esPortal?"conversaciones":"conocimiento"),a=G([]),u=G(""),d=G(30),c=G(!1);async function p(){const I=await oe.get(se(`/umind/agentes?tenant_id=${t.tenantId}`));o.value=(I.items||[]).find(v=>String(v.ID)===t.agenteId)||null}async function h(){const I=await oe.get(se(`/umind/documentos?agente_id=${t.agenteId}`));a.value=I.items||[]}const _=G("texto"),N=G(!0),P=G(""),W=G(""),H=G(null);async function D(){if(u.value.trim()){c.value=!0,r.value="";try{await oe.post(se("/umind/documentos"),{agente_id:n.value,url:u.value.trim(),max_paginas:Number(d.value)||30,auto_actualizar:N.value}),u.value="",await h()}catch(I){r.value=I.message}finally{c.value=!1}}}async function B(){if(W.value.trim()){c.value=!0,r.value="";try{await oe.post(se("/umind/documentos/texto"),{agente_id:n.value,titulo:P.value.trim(),contenido:W.value}),P.value="",W.value="",await h()}catch(I){r.value=I.message}finally{c.value=!1}}}async function k(){var v,St;const I=(St=(v=H.value)==null?void 0:v.files)==null?void 0:St[0];if(I){c.value=!0,r.value="";try{const b=new FormData;b.append("agente_id",String(n.value)),b.append("archivo",I);const ke=await fetch(se("/umind/documentos/archivo"),{method:"POST",body:b}),lt=await ke.json();if(!ke.ok)throw new Error(lt.error||"No se pudo subir");H.value.value="",await h()}catch(b){r.value=b.message}finally{c.value=!1}}}const x=G(null),O=G({titulo:"",contenido:""}),U=G(!1);function L(I){x.value=I,O.value={titulo:I.origen,contenido:I.contenido||""}}async function Ae(){if(x.value){U.value=!0,r.value="";try{await oe.put(se(`/umind/documentos/${x.value.ID}`),{titulo:O.value.titulo,contenido:O.value.contenido}),x.value=null,await h()}catch(I){r.value=I.message}finally{U.value=!1}}}async function ee(I){r.value="";try{await oe.post(se(`/umind/documentos/${I.ID}/reprocesar`),{}),await h()}catch(v){r.value=v.message}}async function V(I){try{await oe.put(se(`/umind/documentos/${I.ID}`),{auto_actualizar:!I.auto_actualizar}),await h()}catch(v){r.value=v.message}}function De(I){if(!I)return"sin procesar";const v=Math.floor((Date.now()-new Date(I))/864e5);if(v<=0)return"hoy";if(v===1)return"ayer";if(v<30)return`hace ${v} días`;const St=Math.floor(v/30);return St===1?"hace un mes":`hace ${St} meses`}function z(I){return I.procesado_at?Date.now()-new Date(I.procesado_at)>60*864e5:!1}async function Ze(I){confirm("¿Eliminar esta fuente y sus fragmentos indexados?")&&(await oe.del(se(`/umind/documentos/${I}`)),await h())}const qt=we(()=>I=>({listo:"badge-ok",procesando:"badge-alerta",pendiente:"badge-neutro",error:"badge-error"})[I]||"badge-neutro"),Se=G([]),de=G([]),ue=G(null);async function ut(){const I=await oe.get(se(`/umind/sesiones?agente_id=${t.agenteId}`));Se.value=I.items||[]}async function gt(I){ue.value=I;const v=await oe.get(se(`/umind/historial?agente_id=${t.agenteId}&session_id=${I}`));de.value=v.items||[]}const Ke=G([]),Te=G(!1),nt=G(null),le=G(bt());function bt(){return{nombre:"",descripcion:"",url:"",auth_header_nombre:"",auth_header_valor:"",tocarAuth:!1,parametros:[],activa:!0}}async function qe(){const I=await oe.get(se(`/umind/tools?agente_id=${t.agenteId}`));Ke.value=I.items||[]}function S(){nt.value=null,le.value=bt(),Te.value=!0}function K(I){nt.value=I;let v=[];try{v=JSON.parse(I.parametros_json||"[]")||[]}catch{v=[]}le.value={nombre:I.nombre,descripcion:I.descripcion,url:I.url,auth_header_nombre:I.auth_header_nombre,auth_header_valor:"",tocarAuth:!1,parametros:v,activa:I.activa},Te.value=!0}function F(){le.value.parametros.push({nombre:"",tipo:"string",descripcion:"",requerido:!1})}function Y(I){le.value.parametros.splice(I,1)}async function ae(){const I={agente_id:n.value,nombre:le.value.nombre.trim(),descripcion:le.value.descripcion,url:le.value.url.trim(),auth_header_nombre:le.value.auth_header_nombre,parametros:le.value.parametros,activa:le.value.activa};le.value.tocarAuth&&(I.auth_header_valor=le.value.auth_header_valor);try{nt.value?await oe.put(se(`/umind/tools/${nt.value.ID}`),I):await oe.post(se("/umind/tools"),I),Te.value=!1,await qe()}catch(v){r.value=v.message}}async function f(I){confirm(`¿Eliminar la herramienta "${I.nombre}"?`)&&(await oe.del(se(`/umind/tools/${I.ID}`)),await qe())}const m=G([]),g=G(!1),y=G(T()),A=G(!1),E=we(()=>{const I=new Date,v=new Date(I.getFullYear(),I.getMonth(),1).toISOString().slice(0,10),St=I.toISOString().slice(0,10);return se(`/umind/reporte.xlsx?agente_id=${t.agenteId}&desde=${v}&hasta=${St}`)}),j=we(()=>{var v;const I=((v=o.value)==null?void 0:v.site_key)||"TU_SITE_KEY";return` - + + + + -