From 5c1c27bf58e7f88f8722ab4a1d2446f8b9c0bcce Mon Sep 17 00:00:00 2001 From: ShaoHua <345265198@qqcom> Date: Wed, 11 Mar 2026 22:32:52 +0800 Subject: [PATCH] =?UTF-8?q?=E8=B0=83=E8=AF=95=E7=8E=AF=E5=A2=83=E6=AD=A3?= =?UTF-8?q?=E5=B8=B8=EF=BC=8C=E5=8F=91=E5=B8=83=E6=97=B6=E7=BB=9F=E4=B8=80?= =?UTF-8?q?=E5=8F=91=E5=B8=83=E5=89=8D=E5=90=8E=E5=8F=B0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- WebView2Demo/MainWindow.xaml.cs | 22 ++++++++++-- WebView2Demo/WebView2Demo.csproj | 9 ++++- WebView2Demo/wwwroot/assets/index-DJlihbf1.js | 1 + .../wwwroot/assets/index-onfabBEH.css | 1 + WebView2Demo/wwwroot/index.html | 14 ++++++++ WebView2Demo/wwwroot/vite.svg | 1 + publish.ps1 | 36 +++++++++++++++++++ web-app/vite.config.js | 1 + 8 files changed, 82 insertions(+), 3 deletions(-) create mode 100644 WebView2Demo/wwwroot/assets/index-DJlihbf1.js create mode 100644 WebView2Demo/wwwroot/assets/index-onfabBEH.css create mode 100644 WebView2Demo/wwwroot/index.html create mode 100644 WebView2Demo/wwwroot/vite.svg create mode 100644 publish.ps1 diff --git a/WebView2Demo/MainWindow.xaml.cs b/WebView2Demo/MainWindow.xaml.cs index 421eae5..3952e0d 100644 --- a/WebView2Demo/MainWindow.xaml.cs +++ b/WebView2Demo/MainWindow.xaml.cs @@ -1,3 +1,4 @@ +using System.IO; using System.Text; using System.Windows; using System.Windows.Controls; @@ -42,8 +43,25 @@ namespace WebView2Demo // 4. 监听消息 webView.WebMessageReceived += WebView_WebMessageReceived; - // 5. 初始化完成后再导航 - webView.Source = new Uri("http://localhost:5174"); + // 5. [合并发布配置] 配置本地虚拟映射加载静态资源 + // 这样发布后即便没有启动 Vue 开发服务器,也可以通过本地文件运行 + string localFolder = System.IO.Path.Combine(AppDomain.CurrentDomain.BaseDirectory, "wwwroot"); + if (Directory.Exists(localFolder) && File.Exists(System.IO.Path.Combine(localFolder, "index.html"))) + { + // 设置虚拟域名映射到本地文件夹 + webView.CoreWebView2.SetVirtualHostNameToFolderMapping( + "app.local", + localFolder, + CoreWebView2HostResourceAccessKind.Allow); + + // 导航到虚拟域名 + webView.Source = new Uri("https://app.local/index.html"); + } + else + { + // 开发模式:如果本地没有 wwwroot,则尝试加载 Vue 开发服务器地址 + webView.Source = new Uri("http://localhost:5174"); + } } catch (Exception ex) { diff --git a/WebView2Demo/WebView2Demo.csproj b/WebView2Demo/WebView2Demo.csproj index 9072817..881b516 100644 --- a/WebView2Demo/WebView2Demo.csproj +++ b/WebView2Demo/WebView2Demo.csproj @@ -1,4 +1,4 @@ - + WinExe @@ -12,4 +12,11 @@ + + + + PreserveNewest + + + diff --git a/WebView2Demo/wwwroot/assets/index-DJlihbf1.js b/WebView2Demo/wwwroot/assets/index-DJlihbf1.js new file mode 100644 index 0000000..8d052d0 --- /dev/null +++ b/WebView2Demo/wwwroot/assets/index-DJlihbf1.js @@ -0,0 +1 @@ +(function(){let e=document.createElement(`link`).relList;if(e&&e.supports&&e.supports(`modulepreload`))return;for(let e of document.querySelectorAll(`link[rel="modulepreload"]`))n(e);new MutationObserver(e=>{for(let t of e)if(t.type===`childList`)for(let e of t.addedNodes)e.tagName===`LINK`&&e.rel===`modulepreload`&&n(e)}).observe(document,{childList:!0,subtree:!0});function t(e){let t={};return e.integrity&&(t.integrity=e.integrity),e.referrerPolicy&&(t.referrerPolicy=e.referrerPolicy),e.crossOrigin===`use-credentials`?t.credentials=`include`:e.crossOrigin===`anonymous`?t.credentials=`omit`:t.credentials=`same-origin`,t}function n(e){if(e.ep)return;e.ep=!0;let n=t(e);fetch(e.href,n)}})();function e(e){let t=Object.create(null);for(let n of e.split(`,`))t[n]=1;return e=>e in t}var t={},n=[],r=()=>{},i=()=>!1,a=e=>e.charCodeAt(0)===111&&e.charCodeAt(1)===110&&(e.charCodeAt(2)>122||e.charCodeAt(2)<97),o=e=>e.startsWith(`onUpdate:`),s=Object.assign,c=(e,t)=>{let n=e.indexOf(t);n>-1&&e.splice(n,1)},l=Object.prototype.hasOwnProperty,u=(e,t)=>l.call(e,t),d=Array.isArray,f=e=>x(e)===`[object Map]`,p=e=>x(e)===`[object Set]`,m=e=>x(e)===`[object Date]`,h=e=>typeof e==`function`,g=e=>typeof e==`string`,_=e=>typeof e==`symbol`,v=e=>typeof e==`object`&&!!e,y=e=>(v(e)||h(e))&&h(e.then)&&h(e.catch),b=Object.prototype.toString,x=e=>b.call(e),S=e=>x(e).slice(8,-1),C=e=>x(e)===`[object Object]`,w=e=>g(e)&&e!==`NaN`&&e[0]!==`-`&&``+parseInt(e,10)===e,ee=e(`,key,ref,ref_for,ref_key,onVnodeBeforeMount,onVnodeMounted,onVnodeBeforeUpdate,onVnodeUpdated,onVnodeBeforeUnmount,onVnodeUnmounted`),te=e=>{let t=Object.create(null);return(n=>t[n]||(t[n]=e(n)))},ne=/-\w/g,T=te(e=>e.replace(ne,e=>e.slice(1).toUpperCase())),re=/\B([A-Z])/g,E=te(e=>e.replace(re,`-$1`).toLowerCase()),ie=te(e=>e.charAt(0).toUpperCase()+e.slice(1)),ae=te(e=>e?`on${ie(e)}`:``),D=(e,t)=>!Object.is(e,t),oe=(e,...t)=>{for(let n=0;n{Object.defineProperty(e,t,{configurable:!0,enumerable:!1,writable:r,value:n})},se=e=>{let t=parseFloat(e);return isNaN(t)?e:t},ce,le=()=>ce||=typeof globalThis<`u`?globalThis:typeof self<`u`?self:typeof window<`u`?window:typeof global<`u`?global:{};function ue(e){if(d(e)){let t={};for(let n=0;n{if(e){let n=e.split(fe);n.length>1&&(t[n[0].trim()]=n[1].trim())}}),t}function k(e){let t=``;if(g(e))t=e;else if(d(e))for(let n=0;n!!(e&&e.__v_isRef===!0),xe=e=>g(e)?e:e==null?``:d(e)||v(e)&&(e.toString===b||!h(e.toString))?be(e)?xe(e.value):JSON.stringify(e,Se,2):String(e),Se=(e,t)=>be(t)?Se(e,t.value):f(t)?{[`Map(${t.size})`]:[...t.entries()].reduce((e,[t,n],r)=>(e[Ce(t,r)+` =>`]=n,e),{})}:p(t)?{[`Set(${t.size})`]:[...t.values()].map(e=>Ce(e))}:_(t)?Ce(t):v(t)&&!d(t)&&!C(t)?String(t):t,Ce=(e,t=``)=>_(e)?`Symbol(${e.description??t})`:e,A,we=class{constructor(e=!1){this.detached=e,this._active=!0,this._on=0,this.effects=[],this.cleanups=[],this._isPaused=!1,this.__v_skip=!0,this.parent=A,!e&&A&&(this.index=(A.scopes||=[]).push(this)-1)}get active(){return this._active}pause(){if(this._active){this._isPaused=!0;let e,t;if(this.scopes)for(e=0,t=this.scopes.length;e0&&--this._on===0&&(A=this.prevScope,this.prevScope=void 0)}stop(e){if(this._active){this._active=!1;let t,n;for(t=0,n=this.effects.length;t0)return;if(Ae){let e=Ae;for(Ae=void 0;e;){let t=e.next;e.next=void 0,e.flags&=-9,e=t}}let e;for(;ke;){let t=ke;for(ke=void 0;t;){let n=t.next;if(t.next=void 0,t.flags&=-9,t.flags&1)try{t.trigger()}catch(t){e||=t}t=n}}if(e)throw e}function Pe(e){for(let t=e.deps;t;t=t.nextDep)t.version=-1,t.prevActiveLink=t.dep.activeLink,t.dep.activeLink=t}function Fe(e){let t,n=e.depsTail,r=n;for(;r;){let e=r.prevDep;r.version===-1?(r===n&&(n=e),Re(r),ze(r)):t=r,r.dep.activeLink=r.prevActiveLink,r.prevActiveLink=void 0,r=e}e.deps=t,e.depsTail=n}function Ie(e){for(let t=e.deps;t;t=t.nextDep)if(t.dep.version!==t.version||t.dep.computed&&(Le(t.dep.computed)||t.dep.version!==t.version))return!0;return!!e._dirty}function Le(e){if(e.flags&4&&!(e.flags&16)||(e.flags&=-17,e.globalVersion===Ue)||(e.globalVersion=Ue,!e.isSSR&&e.flags&128&&(!e.deps&&!e._dirty||!Ie(e))))return;e.flags|=2;let t=e.dep,n=j,r=M;j=e,M=!0;try{Pe(e);let n=e.fn(e._value);(t.version===0||D(n,e._value))&&(e.flags|=128,e._value=n,t.version++)}catch(e){throw t.version++,e}finally{j=n,M=r,Fe(e),e.flags&=-3}}function Re(e,t=!1){let{dep:n,prevSub:r,nextSub:i}=e;if(r&&(r.nextSub=i,e.prevSub=void 0),i&&(i.prevSub=r,e.nextSub=void 0),n.subs===e&&(n.subs=r,!r&&n.computed)){n.computed.flags&=-5;for(let e=n.computed.deps;e;e=e.nextDep)Re(e,!0)}!t&&!--n.sc&&n.map&&n.map.delete(n.key)}function ze(e){let{prevDep:t,nextDep:n}=e;t&&(t.nextDep=n,e.prevDep=void 0),n&&(n.prevDep=t,e.nextDep=void 0)}var M=!0,Be=[];function N(){Be.push(M),M=!1}function Ve(){let e=Be.pop();M=e===void 0?!0:e}function He(e){let{cleanup:t}=e;if(e.cleanup=void 0,t){let e=j;j=void 0;try{t()}finally{j=e}}}var Ue=0,We=class{constructor(e,t){this.sub=e,this.dep=t,this.version=t.version,this.nextDep=this.prevDep=this.nextSub=this.prevSub=this.prevActiveLink=void 0}},Ge=class{constructor(e){this.computed=e,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(e){if(!j||!M||j===this.computed)return;let t=this.activeLink;if(t===void 0||t.sub!==j)t=this.activeLink=new We(j,this),j.deps?(t.prevDep=j.depsTail,j.depsTail.nextDep=t,j.depsTail=t):j.deps=j.depsTail=t,Ke(t);else if(t.version===-1&&(t.version=this.version,t.nextDep)){let e=t.nextDep;e.prevDep=t.prevDep,t.prevDep&&(t.prevDep.nextDep=e),t.prevDep=j.depsTail,t.nextDep=void 0,j.depsTail.nextDep=t,j.depsTail=t,j.deps===t&&(j.deps=e)}return t}trigger(e){this.version++,Ue++,this.notify(e)}notify(e){Me();try{for(let e=this.subs;e;e=e.prevSub)e.sub.notify()&&e.sub.dep.notify()}finally{Ne()}}};function Ke(e){if(e.dep.sc++,e.sub.flags&4){let t=e.dep.computed;if(t&&!e.dep.subs){t.flags|=20;for(let e=t.deps;e;e=e.nextDep)Ke(e)}let n=e.dep.subs;n!==e&&(e.prevSub=n,n&&(n.nextSub=e)),e.dep.subs=e}}var qe=new WeakMap,Je=Symbol(``),Ye=Symbol(``),Xe=Symbol(``);function P(e,t,n){if(M&&j){let t=qe.get(e);t||qe.set(e,t=new Map);let r=t.get(n);r||(t.set(n,r=new Ge),r.map=t,r.key=n),r.track()}}function F(e,t,n,r,i,a){let o=qe.get(e);if(!o){Ue++;return}let s=e=>{e&&e.trigger()};if(Me(),t===`clear`)o.forEach(s);else{let i=d(e),a=i&&w(n);if(i&&n===`length`){let e=Number(r);o.forEach((t,n)=>{(n===`length`||n===Xe||!_(n)&&n>=e)&&s(t)})}else switch((n!==void 0||o.has(void 0))&&s(o.get(n)),a&&s(o.get(Xe)),t){case`add`:i?a&&s(o.get(`length`)):(s(o.get(Je)),f(e)&&s(o.get(Ye)));break;case`delete`:i||(s(o.get(Je)),f(e)&&s(o.get(Ye)));break;case`set`:f(e)&&s(o.get(Je));break}}Ne()}function Ze(e){let t=z(e);return t===e?t:(P(t,`iterate`,Xe),R(e)?t:t.map(B))}function Qe(e){return P(e=z(e),`iterate`,Xe),e}function I(e,t){return Pt(e)?Nt(e)?Lt(B(t)):Lt(t):B(t)}var $e={__proto__:null,[Symbol.iterator](){return et(this,Symbol.iterator,e=>I(this,e))},concat(...e){return Ze(this).concat(...e.map(e=>d(e)?Ze(e):e))},entries(){return et(this,`entries`,e=>(e[1]=I(this,e[1]),e))},every(e,t){return L(this,`every`,e,t,void 0,arguments)},filter(e,t){return L(this,`filter`,e,t,e=>e.map(e=>I(this,e)),arguments)},find(e,t){return L(this,`find`,e,t,e=>I(this,e),arguments)},findIndex(e,t){return L(this,`findIndex`,e,t,void 0,arguments)},findLast(e,t){return L(this,`findLast`,e,t,e=>I(this,e),arguments)},findLastIndex(e,t){return L(this,`findLastIndex`,e,t,void 0,arguments)},forEach(e,t){return L(this,`forEach`,e,t,void 0,arguments)},includes(...e){return rt(this,`includes`,e)},indexOf(...e){return rt(this,`indexOf`,e)},join(e){return Ze(this).join(e)},lastIndexOf(...e){return rt(this,`lastIndexOf`,e)},map(e,t){return L(this,`map`,e,t,void 0,arguments)},pop(){return it(this,`pop`)},push(...e){return it(this,`push`,e)},reduce(e,...t){return nt(this,`reduce`,e,t)},reduceRight(e,...t){return nt(this,`reduceRight`,e,t)},shift(){return it(this,`shift`)},some(e,t){return L(this,`some`,e,t,void 0,arguments)},splice(...e){return it(this,`splice`,e)},toReversed(){return Ze(this).toReversed()},toSorted(e){return Ze(this).toSorted(e)},toSpliced(...e){return Ze(this).toSpliced(...e)},unshift(...e){return it(this,`unshift`,e)},values(){return et(this,`values`,e=>I(this,e))}};function et(e,t,n){let r=Qe(e),i=r[t]();return r!==e&&!R(e)&&(i._next=i.next,i.next=()=>{let e=i._next();return e.done||(e.value=n(e.value)),e}),i}var tt=Array.prototype;function L(e,t,n,r,i,a){let o=Qe(e),s=o!==e&&!R(e),c=o[t];if(c!==tt[t]){let t=c.apply(e,a);return s?B(t):t}let l=n;o!==e&&(s?l=function(t,r){return n.call(this,I(e,t),r,e)}:n.length>2&&(l=function(t,r){return n.call(this,t,r,e)}));let u=c.call(o,l,r);return s&&i?i(u):u}function nt(e,t,n,r){let i=Qe(e),a=i!==e&&!R(e),o=n,s=!1;i!==e&&(a?(s=r.length===0,o=function(t,r,i){return s&&(s=!1,t=I(e,t)),n.call(this,t,I(e,r),i,e)}):n.length>3&&(o=function(t,r,i){return n.call(this,t,r,i,e)}));let c=i[t](o,...r);return s?I(e,c):c}function rt(e,t,n){let r=z(e);P(r,`iterate`,Xe);let i=r[t](...n);return(i===-1||i===!1)&&Ft(n[0])?(n[0]=z(n[0]),r[t](...n)):i}function it(e,t,n=[]){N(),Me();let r=z(e)[t].apply(e,n);return Ne(),Ve(),r}var at=e(`__proto__,__v_isRef,__isVue`),ot=new Set(Object.getOwnPropertyNames(Symbol).filter(e=>e!==`arguments`&&e!==`caller`).map(e=>Symbol[e]).filter(_));function st(e){_(e)||(e=String(e));let t=z(this);return P(t,`has`,e),t.hasOwnProperty(e)}var ct=class{constructor(e=!1,t=!1){this._isReadonly=e,this._isShallow=t}get(e,t,n){if(t===`__v_skip`)return e.__v_skip;let r=this._isReadonly,i=this._isShallow;if(t===`__v_isReactive`)return!r;if(t===`__v_isReadonly`)return r;if(t===`__v_isShallow`)return i;if(t===`__v_raw`)return n===(r?i?Et:Tt:i?wt:Ct).get(e)||Object.getPrototypeOf(e)===Object.getPrototypeOf(n)?e:void 0;let a=d(e);if(!r){let e;if(a&&(e=$e[t]))return e;if(t===`hasOwnProperty`)return st}let o=Reflect.get(e,t,V(e)?e:n);if((_(t)?ot.has(t):at(t))||(r||P(e,`get`,t),i))return o;if(V(o)){let e=a&&w(t)?o:o.value;return r&&v(e)?jt(e):e}return v(o)?r?jt(o):kt(o):o}},lt=class extends ct{constructor(e=!1){super(!1,e)}set(e,t,n,r){let i=e[t],a=d(e)&&w(t);if(!this._isShallow){let e=Pt(i);if(!R(n)&&!Pt(n)&&(i=z(i),n=z(n)),!a&&V(i)&&!V(n))return e||(i.value=n),!0}let o=a?Number(t)e,ht=e=>Reflect.getPrototypeOf(e);function gt(e,t,n){return function(...r){let i=this.__v_raw,a=z(i),o=f(a),c=e===`entries`||e===Symbol.iterator&&o,l=e===`keys`&&o,u=i[e](...r),d=n?mt:t?Lt:B;return!t&&P(a,`iterate`,l?Ye:Je),s(Object.create(u),{next(){let{value:e,done:t}=u.next();return t?{value:e,done:t}:{value:c?[d(e[0]),d(e[1])]:d(e),done:t}}})}}function _t(e){return function(...t){return e===`delete`?!1:e===`clear`?void 0:this}}function vt(e,t){let n={get(n){let r=this.__v_raw,i=z(r),a=z(n);e||(D(n,a)&&P(i,`get`,n),P(i,`get`,a));let{has:o}=ht(i),s=t?mt:e?Lt:B;if(o.call(i,n))return s(r.get(n));if(o.call(i,a))return s(r.get(a));r!==i&&r.get(n)},get size(){let t=this.__v_raw;return!e&&P(z(t),`iterate`,Je),t.size},has(t){let n=this.__v_raw,r=z(n),i=z(t);return e||(D(t,i)&&P(r,`has`,t),P(r,`has`,i)),t===i?n.has(t):n.has(t)||n.has(i)},forEach(n,r){let i=this,a=i.__v_raw,o=z(a),s=t?mt:e?Lt:B;return!e&&P(o,`iterate`,Je),a.forEach((e,t)=>n.call(r,s(e),s(t),i))}};return s(n,e?{add:_t(`add`),set:_t(`set`),delete:_t(`delete`),clear:_t(`clear`)}:{add(e){let n=z(this),r=ht(n),i=z(e),a=!t&&!R(e)&&!Pt(e)?i:e;return r.has.call(n,a)||D(e,a)&&r.has.call(n,e)||D(i,a)&&r.has.call(n,i)||(n.add(a),F(n,`add`,a,a)),this},set(e,n){!t&&!R(n)&&!Pt(n)&&(n=z(n));let r=z(this),{has:i,get:a}=ht(r),o=i.call(r,e);o||=(e=z(e),i.call(r,e));let s=a.call(r,e);return r.set(e,n),o?D(n,s)&&F(r,`set`,e,n,s):F(r,`add`,e,n),this},delete(e){let t=z(this),{has:n,get:r}=ht(t),i=n.call(t,e);i||=(e=z(e),n.call(t,e));let a=r?r.call(t,e):void 0,o=t.delete(e);return i&&F(t,`delete`,e,void 0,a),o},clear(){let e=z(this),t=e.size!==0,n=e.clear();return t&&F(e,`clear`,void 0,void 0,void 0),n}}),[`keys`,`values`,`entries`,Symbol.iterator].forEach(r=>{n[r]=gt(r,e,t)}),n}function yt(e,t){let n=vt(e,t);return(t,r,i)=>r===`__v_isReactive`?!e:r===`__v_isReadonly`?e:r===`__v_raw`?t:Reflect.get(u(n,r)&&r in t?n:t,r,i)}var bt={get:yt(!1,!1)},xt={get:yt(!1,!0)},St={get:yt(!0,!1)},Ct=new WeakMap,wt=new WeakMap,Tt=new WeakMap,Et=new WeakMap;function Dt(e){switch(e){case`Object`:case`Array`:return 1;case`Map`:case`Set`:case`WeakMap`:case`WeakSet`:return 2;default:return 0}}function Ot(e){return e.__v_skip||!Object.isExtensible(e)?0:Dt(S(e))}function kt(e){return Pt(e)?e:Mt(e,!1,dt,bt,Ct)}function At(e){return Mt(e,!1,pt,xt,wt)}function jt(e){return Mt(e,!0,ft,St,Tt)}function Mt(e,t,n,r,i){if(!v(e)||e.__v_raw&&!(t&&e.__v_isReactive))return e;let a=Ot(e);if(a===0)return e;let o=i.get(e);if(o)return o;let s=new Proxy(e,a===2?r:n);return i.set(e,s),s}function Nt(e){return Pt(e)?Nt(e.__v_raw):!!(e&&e.__v_isReactive)}function Pt(e){return!!(e&&e.__v_isReadonly)}function R(e){return!!(e&&e.__v_isShallow)}function Ft(e){return e?!!e.__v_raw:!1}function z(e){let t=e&&e.__v_raw;return t?z(t):e}function It(e){return!u(e,`__v_skip`)&&Object.isExtensible(e)&&O(e,`__v_skip`,!0),e}var B=e=>v(e)?kt(e):e,Lt=e=>v(e)?jt(e):e;function V(e){return e?e.__v_isRef===!0:!1}function Rt(e){return zt(e,!1)}function zt(e,t){return V(e)?e:new Bt(e,t)}var Bt=class{constructor(e,t){this.dep=new Ge,this.__v_isRef=!0,this.__v_isShallow=!1,this._rawValue=t?e:z(e),this._value=t?e:B(e),this.__v_isShallow=t}get value(){return this.dep.track(),this._value}set value(e){let t=this._rawValue,n=this.__v_isShallow||R(e)||Pt(e);e=n?e:z(e),D(e,t)&&(this._rawValue=e,this._value=n?e:B(e),this.dep.trigger())}};function H(e){return V(e)?e.value:e}var Vt={get:(e,t,n)=>t===`__v_raw`?e:H(Reflect.get(e,t,n)),set:(e,t,n,r)=>{let i=e[t];return V(i)&&!V(n)?(i.value=n,!0):Reflect.set(e,t,n,r)}};function Ht(e){return Nt(e)?e:new Proxy(e,Vt)}var Ut=class{constructor(e,t,n){this.fn=e,this.setter=t,this._value=void 0,this.dep=new Ge(this),this.__v_isRef=!0,this.deps=void 0,this.depsTail=void 0,this.flags=16,this.globalVersion=Ue-1,this.next=void 0,this.effect=this,this.__v_isReadonly=!t,this.isSSR=n}notify(){if(this.flags|=16,!(this.flags&8)&&j!==this)return je(this,!0),!0}get value(){let e=this.dep.track();return Le(this),e&&(e.version=this.dep.version),this._value}set value(e){this.setter&&this.setter(e)}};function Wt(e,t,n=!1){let r,i;return h(e)?r=e:(r=e.get,i=e.set),new Ut(r,i,n)}var Gt={},Kt=new WeakMap,qt=void 0;function Jt(e,t=!1,n=qt){if(n){let t=Kt.get(n);t||Kt.set(n,t=[]),t.push(e)}}function Yt(e,n,i=t){let{immediate:a,deep:o,once:s,scheduler:l,augmentJob:u,call:f}=i,p=e=>o?e:R(e)||o===!1||o===0?Xt(e,1):Xt(e),m,g,_,v,y=!1,b=!1;if(V(e)?(g=()=>e.value,y=R(e)):Nt(e)?(g=()=>p(e),y=!0):d(e)?(b=!0,y=e.some(e=>Nt(e)||R(e)),g=()=>e.map(e=>{if(V(e))return e.value;if(Nt(e))return p(e);if(h(e))return f?f(e,2):e()})):g=h(e)?n?f?()=>f(e,2):e:()=>{if(_){N();try{_()}finally{Ve()}}let t=qt;qt=m;try{return f?f(e,3,[v]):e(v)}finally{qt=t}}:r,n&&o){let e=g,t=o===!0?1/0:o;g=()=>Xt(e(),t)}let x=Te(),S=()=>{m.stop(),x&&x.active&&c(x.effects,m)};if(s&&n){let e=n;n=(...t)=>{e(...t),S()}}let C=b?Array(e.length).fill(Gt):Gt,w=e=>{if(!(!(m.flags&1)||!m.dirty&&!e))if(n){let e=m.run();if(o||y||(b?e.some((e,t)=>D(e,C[t])):D(e,C))){_&&_();let t=qt;qt=m;try{let t=[e,C===Gt?void 0:b&&C[0]===Gt?[]:C,v];C=e,f?f(n,3,t):n(...t)}finally{qt=t}}}else m.run()};return u&&u(w),m=new De(g),m.scheduler=l?()=>l(w,!1):w,v=e=>Jt(e,!1,m),_=m.onStop=()=>{let e=Kt.get(m);if(e){if(f)f(e,4);else for(let t of e)t();Kt.delete(m)}},n?a?w(!0):C=m.run():l?l(w.bind(null,!0),!0):m.run(),S.pause=m.pause.bind(m),S.resume=m.resume.bind(m),S.stop=S,S}function Xt(e,t=1/0,n){if(t<=0||!v(e)||e.__v_skip||(n||=new Map,(n.get(e)||0)>=t))return e;if(n.set(e,t),t--,V(e))Xt(e.value,t,n);else if(d(e))for(let r=0;r{Xt(e,t,n)});else if(C(e)){for(let r in e)Xt(e[r],t,n);for(let r of Object.getOwnPropertySymbols(e))Object.prototype.propertyIsEnumerable.call(e,r)&&Xt(e[r],t,n)}return e}function Zt(e,t,n,r){try{return r?e(...r):e()}catch(e){Qt(e,t,n)}}function U(e,t,n,r){if(h(e)){let i=Zt(e,t,n,r);return i&&y(i)&&i.catch(e=>{Qt(e,t,n)}),i}if(d(e)){let i=[];for(let a=0;a>>1,i=W[r],a=pn(i);a=pn(n)?W.push(e):W.splice(sn(t),0,e),e.flags|=1,ln()}}function ln(){an||=rn.then(mn)}function un(e){d(e)?en.push(...e):tn&&e.id===-1?tn.splice(nn+1,0,e):e.flags&1||(en.push(e),e.flags|=1),ln()}function dn(e,t,n=G+1){for(;npn(e)-pn(t));if(en.length=0,tn){tn.push(...e);return}for(tn=e,nn=0;nne.id==null?e.flags&2?-1:1/0:e.id;function mn(e){try{for(G=0;G{r._d&&bi(-1);let i=gn(t),a;try{a=e(...n)}finally{gn(i),r._d&&bi(1)}return a};return r._n=!0,r._c=!0,r._d=!0,r}function vn(e,t,n,r){let i=e.dirs,a=t&&t.dirs;for(let o=0;o1)return n&&h(t)?t.call(r&&r.proxy):t}}var xn=Symbol.for(`v-scx`),Sn=()=>bn(xn);function Cn(e,t,n){return wn(e,t,n)}function wn(e,n,i=t){let{immediate:a,deep:o,flush:c,once:l}=i,u=s({},i),d=n&&a||!n&&c!==`post`,f;if(Ki){if(c===`sync`){let e=Sn();f=e.__watcherHandles||=[]}else if(!d){let e=()=>{};return e.stop=r,e.resume=r,e.pause=r,e}}let p=$;u.call=(e,t,n)=>U(e,p,t,n);let m=!1;c===`post`?u.scheduler=e=>{J(e,p&&p.suspense)}:c!==`sync`&&(m=!0,u.scheduler=(e,t)=>{t?e():cn(e)}),u.augmentJob=e=>{n&&(e.flags|=4),m&&(e.flags|=2,p&&(e.id=p.uid,e.i=p))};let h=Yt(e,n,u);return Ki&&(f?f.push(h):d&&h()),h}function Tn(e,t,n){let r=this.proxy,i=g(e)?e.includes(`.`)?En(r,e):()=>r[e]:e.bind(r,r),a;h(t)?a=t:(a=t.handler,n=t);let o=Ui(this),s=wn(i,a.bind(r),n);return o(),s}function En(e,t){let n=t.split(`.`);return()=>{let t=e;for(let e=0;ee.__isTeleport,kn=Symbol(`_leaveCb`);function An(e,t){e.shapeFlag&6&&e.component?(e.transition=t,An(e.component.subTree,t)):e.shapeFlag&128?(e.ssContent.transition=t.clone(e.ssContent),e.ssFallback.transition=t.clone(e.ssFallback)):e.transition=t}function jn(e){e.ids=[e.ids[0]+ e.ids[2]+++`-`,0,0]}function Mn(e,t){let n;return!!((n=Object.getOwnPropertyDescriptor(e,t))&&!n.configurable)}var Nn=new WeakMap;function Pn(e,n,r,a,o=!1){if(d(e)){e.forEach((e,t)=>Pn(e,n&&(d(n)?n[t]:n),r,a,o));return}if(In(a)&&!o){a.shapeFlag&512&&a.type.__asyncResolved&&a.component.subTree.component&&Pn(e,n,r,a.component.subTree);return}let s=a.shapeFlag&4?ta(a.component):a.el,l=o?null:s,{i:f,r:p}=e,m=n&&n.r,_=f.refs===t?f.refs={}:f.refs,v=f.setupState,y=z(v),b=v===t?i:e=>Mn(_,e)?!1:u(y,e),x=(e,t)=>!(t&&Mn(_,t));if(m!=null&&m!==p){if(Fn(n),g(m))_[m]=null,b(m)&&(v[m]=null);else if(V(m)){let e=n;x(m,e.k)&&(m.value=null),e.k&&(_[e.k]=null)}}if(h(p))Zt(p,f,12,[l,_]);else{let t=g(p),n=V(p);if(t||n){let i=()=>{if(e.f){let n=t?b(p)?v[p]:_[p]:x(p)||!e.k?p.value:_[e.k];if(o)d(n)&&c(n,s);else if(d(n))n.includes(s)||n.push(s);else if(t)_[p]=[s],b(p)&&(v[p]=_[p]);else{let t=[s];x(p,e.k)&&(p.value=t),e.k&&(_[e.k]=t)}}else t?(_[p]=l,b(p)&&(v[p]=l)):n&&(x(p,e.k)&&(p.value=l),e.k&&(_[e.k]=l))};if(l){let t=()=>{i(),Nn.delete(e)};t.id=-1,Nn.set(e,t),J(t,r)}else Fn(e),i()}}}function Fn(e){let t=Nn.get(e);t&&(t.flags|=8,Nn.delete(e))}le().requestIdleCallback,le().cancelIdleCallback;var In=e=>!!e.type.__asyncLoader,Ln=e=>e.type.__isKeepAlive;function Rn(e,t){Bn(e,`a`,t)}function zn(e,t){Bn(e,`da`,t)}function Bn(e,t,n=$){let r=e.__wdc||=()=>{let t=n;for(;t;){if(t.isDeactivated)return;t=t.parent}return e()};if(Hn(t,r,n),n){let e=n.parent;for(;e&&e.parent;)Ln(e.parent.vnode)&&Vn(r,t,n,e),e=e.parent}}function Vn(e,t,n,r){let i=Hn(t,e,r,!0);Yn(()=>{c(r[t],i)},n)}function Hn(e,t,n=$,r=!1){if(n){let i=n[e]||(n[e]=[]),a=t.__weh||=(...r)=>{N();let i=Ui(n),a=U(t,n,e,r);return i(),Ve(),a};return r?i.unshift(a):i.push(a),a}}var Un=e=>(t,n=$)=>{(!Ki||e===`sp`)&&Hn(e,(...e)=>t(...e),n)},Wn=Un(`bm`),Gn=Un(`m`),Kn=Un(`bu`),qn=Un(`u`),Jn=Un(`bum`),Yn=Un(`um`),Xn=Un(`sp`),Zn=Un(`rtg`),Qn=Un(`rtc`);function $n(e,t=$){Hn(`ec`,e,t)}var er=Symbol.for(`v-ndc`),tr=e=>e?Gi(e)?ta(e):tr(e.parent):null,nr=s(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=>tr(e.parent),$root:e=>tr(e.root),$host:e=>e.ce,$emit:e=>e.emit,$options:e=>dr(e),$forceUpdate:e=>e.f||=()=>{cn(e.update)},$nextTick:e=>e.n||=on.bind(e.proxy),$watch:e=>Tn.bind(e)}),rr=(e,n)=>e!==t&&!e.__isScriptSetup&&u(e,n),ir={get({_:e},n){if(n===`__v_skip`)return!0;let{ctx:r,setupState:i,data:a,props:o,accessCache:s,type:c,appContext:l}=e;if(n[0]!==`$`){let e=s[n];if(e!==void 0)switch(e){case 1:return i[n];case 2:return a[n];case 4:return r[n];case 3:return o[n]}else if(rr(i,n))return s[n]=1,i[n];else if(a!==t&&u(a,n))return s[n]=2,a[n];else if(u(o,n))return s[n]=3,o[n];else if(r!==t&&u(r,n))return s[n]=4,r[n];else or&&(s[n]=0)}let d=nr[n],f,p;if(d)return n===`$attrs`&&P(e.attrs,`get`,``),d(e);if((f=c.__cssModules)&&(f=f[n]))return f;if(r!==t&&u(r,n))return s[n]=4,r[n];if(p=l.config.globalProperties,u(p,n))return p[n]},set({_:e},n,r){let{data:i,setupState:a,ctx:o}=e;return rr(a,n)?(a[n]=r,!0):i!==t&&u(i,n)?(i[n]=r,!0):u(e.props,n)||n[0]===`$`&&n.slice(1)in e?!1:(o[n]=r,!0)},has({_:{data:e,setupState:n,accessCache:r,ctx:i,appContext:a,props:o,type:s}},c){let l;return!!(r[c]||e!==t&&c[0]!==`$`&&u(e,c)||rr(n,c)||u(o,c)||u(i,c)||u(nr,c)||u(a.config.globalProperties,c)||(l=s.__cssModules)&&l[c])},defineProperty(e,t,n){return n.get==null?u(n,`value`)&&this.set(e,t,n.value,null):e._.accessCache[t]=0,Reflect.defineProperty(e,t,n)}};function ar(e){return d(e)?e.reduce((e,t)=>(e[t]=null,e),{}):e}var or=!0;function sr(e){let t=dr(e),n=e.proxy,i=e.ctx;or=!1,t.beforeCreate&&lr(t.beforeCreate,e,`bc`);let{data:a,computed:o,methods:s,watch:c,provide:l,inject:u,created:f,beforeMount:p,mounted:m,beforeUpdate:g,updated:_,activated:y,deactivated:b,beforeDestroy:x,beforeUnmount:S,destroyed:C,unmounted:w,render:ee,renderTracked:te,renderTriggered:ne,errorCaptured:T,serverPrefetch:re,expose:E,inheritAttrs:ie,components:ae,directives:D,filters:oe}=t;if(u&&cr(u,i,null),s)for(let e in s){let t=s[e];h(t)&&(i[e]=t.bind(n))}if(a){let t=a.call(n,n);v(t)&&(e.data=kt(t))}if(or=!0,o)for(let e in o){let t=o[e],a=ra({get:h(t)?t.bind(n,n):h(t.get)?t.get.bind(n,n):r,set:!h(t)&&h(t.set)?t.set.bind(n):r});Object.defineProperty(i,e,{enumerable:!0,configurable:!0,get:()=>a.value,set:e=>a.value=e})}if(c)for(let e in c)ur(c[e],i,n,e);if(l){let e=h(l)?l.call(n):l;Reflect.ownKeys(e).forEach(t=>{yn(t,e[t])})}f&&lr(f,e,`c`);function O(e,t){d(t)?t.forEach(t=>e(t.bind(n))):t&&e(t.bind(n))}if(O(Wn,p),O(Gn,m),O(Kn,g),O(qn,_),O(Rn,y),O(zn,b),O($n,T),O(Qn,te),O(Zn,ne),O(Jn,S),O(Yn,w),O(Xn,re),d(E))if(E.length){let t=e.exposed||={};E.forEach(e=>{Object.defineProperty(t,e,{get:()=>n[e],set:t=>n[e]=t,enumerable:!0})})}else e.exposed||={};ee&&e.render===r&&(e.render=ee),ie!=null&&(e.inheritAttrs=ie),ae&&(e.components=ae),D&&(e.directives=D),re&&jn(e)}function cr(e,t,n=r){d(e)&&(e=gr(e));for(let n in e){let r=e[n],i;i=v(r)?`default`in r?bn(r.from||n,r.default,!0):bn(r.from||n):bn(r),V(i)?Object.defineProperty(t,n,{enumerable:!0,configurable:!0,get:()=>i.value,set:e=>i.value=e}):t[n]=i}}function lr(e,t,n){U(d(e)?e.map(e=>e.bind(t.proxy)):e.bind(t.proxy),t,n)}function ur(e,t,n,r){let i=r.includes(`.`)?En(n,r):()=>n[r];if(g(e)){let n=t[e];h(n)&&Cn(i,n)}else if(h(e))Cn(i,e.bind(n));else if(v(e))if(d(e))e.forEach(e=>ur(e,t,n,r));else{let r=h(e.handler)?e.handler.bind(n):t[e.handler];h(r)&&Cn(i,r,e)}}function dr(e){let t=e.type,{mixins:n,extends:r}=t,{mixins:i,optionsCache:a,config:{optionMergeStrategies:o}}=e.appContext,s=a.get(t),c;return s?c=s:!i.length&&!n&&!r?c=t:(c={},i.length&&i.forEach(e=>fr(c,e,o,!0)),fr(c,t,o)),v(t)&&a.set(t,c),c}function fr(e,t,n,r=!1){let{mixins:i,extends:a}=t;a&&fr(e,a,n,!0),i&&i.forEach(t=>fr(e,t,n,!0));for(let i in t)if(!(r&&i===`expose`)){let r=pr[i]||n&&n[i];e[i]=r?r(e[i],t[i]):t[i]}return e}var pr={data:mr,props:vr,emits:vr,methods:_r,computed:_r,beforeCreate:q,created:q,beforeMount:q,mounted:q,beforeUpdate:q,updated:q,beforeDestroy:q,beforeUnmount:q,destroyed:q,unmounted:q,activated:q,deactivated:q,errorCaptured:q,serverPrefetch:q,components:_r,directives:_r,watch:yr,provide:mr,inject:hr};function mr(e,t){return t?e?function(){return s(h(e)?e.call(this,this):e,h(t)?t.call(this,this):t)}:t:e}function hr(e,t){return _r(gr(e),gr(t))}function gr(e){if(d(e)){let t={};for(let n=0;nt===`modelValue`||t===`model-value`?e.modelModifiers:e[`${t}Modifiers`]||e[`${T(t)}Modifiers`]||e[`${E(t)}Modifiers`];function Tr(e,n,...r){if(e.isUnmounted)return;let i=e.vnode.props||t,a=r,o=n.startsWith(`update:`),s=o&&wr(i,n.slice(7));s&&(s.trim&&(a=r.map(e=>g(e)?e.trim():e)),s.number&&(a=r.map(se)));let c,l=i[c=ae(n)]||i[c=ae(T(n))];!l&&o&&(l=i[c=ae(E(n))]),l&&U(l,e,6,a);let u=i[c+`Once`];if(u){if(!e.emitted)e.emitted={};else if(e.emitted[c])return;e.emitted[c]=!0,U(u,e,6,a)}}var Er=new WeakMap;function Dr(e,t,n=!1){let r=n?Er:t.emitsCache,i=r.get(e);if(i!==void 0)return i;let a=e.emits,o={},c=!1;if(!h(e)){let r=e=>{let n=Dr(e,t,!0);n&&(c=!0,s(o,n))};!n&&t.mixins.length&&t.mixins.forEach(r),e.extends&&r(e.extends),e.mixins&&e.mixins.forEach(r)}return!a&&!c?(v(e)&&r.set(e,null),null):(d(a)?a.forEach(e=>o[e]=null):s(o,a),v(e)&&r.set(e,o),o)}function Or(e,t){return!e||!a(t)?!1:(t=t.slice(2).replace(/Once$/,``),u(e,t[0].toLowerCase()+t.slice(1))||u(e,E(t))||u(e,t))}function kr(e){let{type:t,vnode:n,proxy:r,withProxy:i,propsOptions:[a],slots:s,attrs:c,emit:l,render:u,renderCache:d,props:f,data:p,setupState:m,ctx:h,inheritAttrs:g}=e,_=gn(e),v,y;try{if(n.shapeFlag&4){let e=i||r,t=e;v=Z(u.call(t,e,d,f,m,p,h)),y=c}else{let e=t;v=Z(e.length>1?e(f,{attrs:c,slots:s,emit:l}):e(f,null)),y=t.props?c:Ar(c)}}catch(t){gi.length=0,Qt(t,e,1),v=Oi(mi)}let b=v;if(y&&g!==!1){let e=Object.keys(y),{shapeFlag:t}=b;e.length&&t&7&&(a&&e.some(o)&&(y=jr(y,a)),b=ji(b,y,!1,!0))}return n.dirs&&(b=ji(b,null,!1,!0),b.dirs=b.dirs?b.dirs.concat(n.dirs):n.dirs),n.transition&&An(b,n.transition),v=b,gn(_),v}var Ar=e=>{let t;for(let n in e)(n===`class`||n===`style`||a(n))&&((t||={})[n]=e[n]);return t},jr=(e,t)=>{let n={};for(let r in e)(!o(r)||!(r.slice(9)in t))&&(n[r]=e[r]);return n};function Mr(e,t,n){let{props:r,children:i,component:a}=e,{props:o,children:s,patchFlag:c}=t,l=a.emitsOptions;if(t.dirs||t.transition)return!0;if(n&&c>=0){if(c&1024)return!0;if(c&16)return r?Nr(r,o,l):!!o;if(c&8){let e=t.dynamicProps;for(let t=0;tObject.create(Ir),Rr=e=>Object.getPrototypeOf(e)===Ir;function zr(e,t,n,r=!1){let i={},a=Lr();e.propsDefaults=Object.create(null),Vr(e,t,i,a);for(let t in e.propsOptions[0])t in i||(i[t]=void 0);n?e.props=r?i:At(i):e.type.props?e.props=i:e.props=a,e.attrs=a}function Br(e,t,n,r){let{props:i,attrs:a,vnode:{patchFlag:o}}=e,s=z(i),[c]=e.propsOptions,l=!1;if((r||o>0)&&!(o&16)){if(o&8){let n=e.vnode.dynamicProps;for(let r=0;r{p=!0;let[t,n]=Wr(e,r,!0);s(l,t),n&&f.push(...n)};!i&&r.mixins.length&&r.mixins.forEach(t),e.extends&&t(e.extends),e.mixins&&e.mixins.forEach(t)}if(!c&&!p)return v(e)&&a.set(e,n),n;if(d(c))for(let e=0;ee===`_`||e===`_ctx`||e===`$stable`,qr=e=>d(e)?e.map(Z):[Z(e)],Jr=(e,t,n)=>{if(t._n)return t;let r=_n((...e)=>qr(t(...e)),n);return r._c=!1,r},Yr=(e,t,n)=>{let r=e._ctx;for(let n in e){if(Kr(n))continue;let i=e[n];if(h(i))t[n]=Jr(n,i,r);else if(i!=null){let e=qr(i);t[n]=()=>e}}},Xr=(e,t)=>{let n=qr(t);e.slots.default=()=>n},Zr=(e,t,n)=>{for(let r in t)(n||!Kr(r))&&(e[r]=t[r])},Qr=(e,t,n)=>{let r=e.slots=Lr();if(e.vnode.shapeFlag&32){let e=t._;e?(Zr(r,t,n),n&&O(r,`_`,e,!0)):Yr(t,r)}else t&&Xr(e,t)},$r=(e,n,r)=>{let{vnode:i,slots:a}=e,o=!0,s=t;if(i.shapeFlag&32){let e=n._;e?r&&e===1?o=!1:Zr(a,n,r):(o=!n.$stable,Yr(n,a)),s=n}else n&&(Xr(e,n),s={default:1});if(o)for(let e in a)!Kr(e)&&s[e]==null&&delete a[e]},J=di;function ei(e){return ti(e)}function ti(e,i){let a=le();a.__VUE__=!0;let{insert:o,remove:s,patchProp:c,createElement:l,createText:u,createComment:d,setText:f,setElementText:p,parentNode:m,nextSibling:h,setScopeId:g=r,insertStaticContent:_}=e,v=(e,t,n,r=null,i=null,a=null,o=void 0,s=null,c=!!t.dynamicChildren)=>{if(e===t)return;e&&!Ti(e,t)&&(r=ye(e),k(e,i,a,!0),e=null),t.patchFlag===-2&&(c=!1,t.dynamicChildren=null);let{type:l,ref:u,shapeFlag:d}=t;switch(l){case pi:y(e,t,n,r);break;case mi:b(e,t,n,r);break;case hi:e??x(t,n,r,o);break;case fi:ae(e,t,n,r,i,a,o,s,c);break;default:d&1?w(e,t,n,r,i,a,o,s,c):d&6?D(e,t,n,r,i,a,o,s,c):(d&64||d&128)&&l.process(e,t,n,r,i,a,o,s,c,Se)}u!=null&&i?Pn(u,e&&e.ref,a,t||e,!t):u==null&&e&&e.ref!=null&&Pn(e.ref,null,a,e,!0)},y=(e,t,n,r)=>{if(e==null)o(t.el=u(t.children),n,r);else{let n=t.el=e.el;t.children!==e.children&&f(n,t.children)}},b=(e,t,n,r)=>{e==null?o(t.el=d(t.children||``),n,r):t.el=e.el},x=(e,t,n,r)=>{[e.el,e.anchor]=_(e.children,t,n,r,e.el,e.anchor)},S=({el:e,anchor:t},n,r)=>{let i;for(;e&&e!==t;)i=h(e),o(e,n,r),e=i;o(t,n,r)},C=({el:e,anchor:t})=>{let n;for(;e&&e!==t;)n=h(e),s(e),e=n;s(t)},w=(e,t,n,r,i,a,o,s,c)=>{if(t.type===`svg`?o=`svg`:t.type===`math`&&(o=`mathml`),e==null)te(t,n,r,i,a,o,s,c);else{let n=e.el&&e.el._isVueCE?e.el:null;try{n&&n._beginPatch(),re(e,t,i,a,o,s,c)}finally{n&&n._endPatch()}}},te=(e,t,n,r,i,a,s,u)=>{let d,f,{props:m,shapeFlag:h,transition:g,dirs:_}=e;if(d=e.el=l(e.type,a,m&&m.is,m),h&8?p(d,e.children):h&16&&T(e.children,d,null,r,i,ni(e,a),s,u),_&&vn(e,null,r,`created`),ne(d,e,e.scopeId,s,r),m){for(let e in m)e!==`value`&&!ee(e)&&c(d,e,null,m[e],a,r);`value`in m&&c(d,`value`,null,m.value,a),(f=m.onVnodeBeforeMount)&&Q(f,r,e)}_&&vn(e,null,r,`beforeMount`);let v=ii(i,g);v&&g.beforeEnter(d),o(d,t,n),((f=m&&m.onVnodeMounted)||v||_)&&J(()=>{f&&Q(f,r,e),v&&g.enter(d),_&&vn(e,null,r,`mounted`)},i)},ne=(e,t,n,r,i)=>{if(n&&g(e,n),r)for(let t=0;t{for(let l=c;l{let l=n.el=e.el,{patchFlag:u,dynamicChildren:d,dirs:f}=n;u|=e.patchFlag&16;let m=e.props||t,h=n.props||t,g;if(r&&ri(r,!1),(g=h.onVnodeBeforeUpdate)&&Q(g,r,n,e),f&&vn(n,e,r,`beforeUpdate`),r&&ri(r,!0),(m.innerHTML&&h.innerHTML==null||m.textContent&&h.textContent==null)&&p(l,``),d?E(e.dynamicChildren,d,l,r,i,ni(n,a),o):s||de(e,n,l,null,r,i,ni(n,a),o,!1),u>0){if(u&16)ie(l,m,h,r,a);else if(u&2&&m.class!==h.class&&c(l,`class`,null,h.class,a),u&4&&c(l,`style`,m.style,h.style,a),u&8){let e=n.dynamicProps;for(let t=0;t{g&&Q(g,r,n,e),f&&vn(n,e,r,`updated`)},i)},E=(e,t,n,r,i,a,o)=>{for(let s=0;s{if(n!==r){if(n!==t)for(let t in n)!ee(t)&&!(t in r)&&c(e,t,n[t],null,a,i);for(let t in r){if(ee(t))continue;let o=r[t],s=n[t];o!==s&&t!==`value`&&c(e,t,s,o,a,i)}`value`in r&&c(e,`value`,n.value,r.value,a)}},ae=(e,t,n,r,i,a,s,c,l)=>{let d=t.el=e?e.el:u(``),f=t.anchor=e?e.anchor:u(``),{patchFlag:p,dynamicChildren:m,slotScopeIds:h}=t;h&&(c=c?c.concat(h):h),e==null?(o(d,n,r),o(f,n,r),T(t.children||[],n,f,i,a,s,c,l)):p>0&&p&64&&m&&e.dynamicChildren&&e.dynamicChildren.length===m.length?(E(e.dynamicChildren,m,n,i,a,s,c),(t.key!=null||i&&t===i.subTree)&&ai(e,t,!0)):de(e,t,n,f,i,a,s,c,l)},D=(e,t,n,r,i,a,o,s,c)=>{t.slotScopeIds=s,e==null?t.shapeFlag&512?i.ctx.activate(t,n,r,o,c):O(t,n,r,i,a,o,c):se(e,t,c)},O=(e,t,n,r,i,a,o)=>{let s=e.component=zi(e,r,i);if(Ln(e)&&(s.ctx.renderer=Se),qi(s,!1,o),s.asyncDep){if(i&&i.registerDep(s,ce,o),!e.el){let r=s.subTree=Oi(mi);b(null,r,t,n),e.placeholder=r.el}}else ce(s,e,t,n,i,a,o)},se=(e,t,n)=>{let r=t.component=e.component;if(Mr(e,t,n))if(r.asyncDep&&!r.asyncResolved){ue(r,t,n);return}else r.next=t,r.update();else t.el=e.el,r.vnode=t},ce=(e,t,n,r,i,a,o)=>{let s=()=>{if(e.isMounted){let{next:t,bu:n,u:r,parent:s,vnode:c}=e;{let n=si(e);if(n){t&&(t.el=c.el,ue(e,t,o)),n.asyncDep.then(()=>{J(()=>{e.isUnmounted||l()},i)});return}}let u=t,d;ri(e,!1),t?(t.el=c.el,ue(e,t,o)):t=c,n&&oe(n),(d=t.props&&t.props.onVnodeBeforeUpdate)&&Q(d,s,t,c),ri(e,!0);let f=kr(e),p=e.subTree;e.subTree=f,v(p,f,m(p.el),ye(p),e,i,a),t.el=f.el,u===null&&Fr(e,f.el),r&&J(r,i),(d=t.props&&t.props.onVnodeUpdated)&&J(()=>Q(d,s,t,c),i)}else{let o,{el:s,props:c}=t,{bm:l,m:u,parent:d,root:f,type:p}=e,m=In(t);if(ri(e,!1),l&&oe(l),!m&&(o=c&&c.onVnodeBeforeMount)&&Q(o,d,t),ri(e,!0),s&&A){let t=()=>{e.subTree=kr(e),A(s,e.subTree,e,i,null)};m&&p.__asyncHydrate?p.__asyncHydrate(s,e,t):t()}else{f.ce&&f.ce._hasShadowRoot()&&f.ce._injectChildStyle(p,e.parent?e.parent.type:void 0);let o=e.subTree=kr(e);v(null,o,n,r,e,i,a),t.el=o.el}if(u&&J(u,i),!m&&(o=c&&c.onVnodeMounted)){let e=t;J(()=>Q(o,d,e),i)}(t.shapeFlag&256||d&&In(d.vnode)&&d.vnode.shapeFlag&256)&&e.a&&J(e.a,i),e.isMounted=!0,t=n=r=null}};e.scope.on();let c=e.effect=new De(s);e.scope.off();let l=e.update=c.run.bind(c),u=e.job=c.runIfDirty.bind(c);u.i=e,u.id=e.uid,c.scheduler=()=>cn(u),ri(e,!0),l()},ue=(e,t,n)=>{t.component=e;let r=e.vnode.props;e.vnode=t,e.next=null,Br(e,t.props,r,n),$r(e,t.children,n),N(),dn(e),Ve()},de=(e,t,n,r,i,a,o,s,c=!1)=>{let l=e&&e.children,u=e?e.shapeFlag:0,d=t.children,{patchFlag:f,shapeFlag:m}=t;if(f>0){if(f&128){pe(l,d,n,r,i,a,o,s,c);return}else if(f&256){fe(l,d,n,r,i,a,o,s,c);return}}m&8?(u&16&&ve(l,i,a),d!==l&&p(n,d)):u&16?m&16?pe(l,d,n,r,i,a,o,s,c):ve(l,i,a,!0):(u&8&&p(n,``),m&16&&T(d,n,r,i,a,o,s,c))},fe=(e,t,r,i,a,o,s,c,l)=>{e||=n,t||=n;let u=e.length,d=t.length,f=Math.min(u,d),p;for(p=0;pd?ve(e,a,o,!0,!1,f):T(t,r,i,a,o,s,c,l,f)},pe=(e,t,r,i,a,o,s,c,l)=>{let u=0,d=t.length,f=e.length-1,p=d-1;for(;u<=f&&u<=p;){let n=e[u],i=t[u]=l?Pi(t[u]):Z(t[u]);if(Ti(n,i))v(n,i,r,null,a,o,s,c,l);else break;u++}for(;u<=f&&u<=p;){let n=e[f],i=t[p]=l?Pi(t[p]):Z(t[p]);if(Ti(n,i))v(n,i,r,null,a,o,s,c,l);else break;f--,p--}if(u>f){if(u<=p){let e=p+1,n=ep)for(;u<=f;)k(e[u],a,o,!0),u++;else{let m=u,h=u,g=new Map;for(u=h;u<=p;u++){let e=t[u]=l?Pi(t[u]):Z(t[u]);e.key!=null&&g.set(e.key,u)}let _,y=0,b=p-h+1,x=!1,S=0,C=Array(b);for(u=0;u=b){k(n,a,o,!0);continue}let i;if(n.key!=null)i=g.get(n.key);else for(_=h;_<=p;_++)if(C[_-h]===0&&Ti(n,t[_])){i=_;break}i===void 0?k(n,a,o,!0):(C[i-h]=u+1,i>=S?S=i:x=!0,v(n,t[i],r,null,a,o,s,c,l),y++)}let w=x?oi(C):n;for(_=w.length-1,u=b-1;u>=0;u--){let e=h+u,n=t[e],f=t[e+1],p=e+1{let{el:a,type:c,transition:l,children:u,shapeFlag:d}=e;if(d&6){me(e.component.subTree,t,n,r);return}if(d&128){e.suspense.move(t,n,r);return}if(d&64){c.move(e,t,n,Se);return}if(c===fi){o(a,t,n);for(let e=0;el.enter(a),i);else{let{leave:r,delayLeave:i,afterLeave:c}=l,u=()=>{e.ctx.isUnmounted?s(a):o(a,t,n)},d=()=>{a._isLeaving&&a[kn](!0),r(a,()=>{u(),c&&c()})};i?i(a,u,d):d()}else o(a,t,n)},k=(e,t,n,r=!1,i=!1)=>{let{type:a,props:o,ref:s,children:c,dynamicChildren:l,shapeFlag:u,patchFlag:d,dirs:f,cacheIndex:p}=e;if(d===-2&&(i=!1),s!=null&&(N(),Pn(s,null,n,e,!0),Ve()),p!=null&&(t.renderCache[p]=void 0),u&256){t.ctx.deactivate(e);return}let m=u&1&&f,h=!In(e),g;if(h&&(g=o&&o.onVnodeBeforeUnmount)&&Q(g,t,e),u&6)_e(e.component,n,r);else{if(u&128){e.suspense.unmount(n,r);return}m&&vn(e,null,t,`beforeUnmount`),u&64?e.type.remove(e,t,n,Se,r):l&&!l.hasOnce&&(a!==fi||d>0&&d&64)?ve(l,t,n,!1,!0):(a===fi&&d&384||!i&&u&16)&&ve(c,t,n),r&&he(e)}(h&&(g=o&&o.onVnodeUnmounted)||m)&&J(()=>{g&&Q(g,t,e),m&&vn(e,null,t,`unmounted`)},n)},he=e=>{let{type:t,el:n,anchor:r,transition:i}=e;if(t===fi){ge(n,r);return}if(t===hi){C(e);return}let a=()=>{s(n),i&&!i.persisted&&i.afterLeave&&i.afterLeave()};if(e.shapeFlag&1&&i&&!i.persisted){let{leave:t,delayLeave:r}=i,o=()=>t(n,a);r?r(e.el,a,o):o()}else a()},ge=(e,t)=>{let n;for(;e!==t;)n=h(e),s(e),e=n;s(t)},_e=(e,t,n)=>{let{bum:r,scope:i,job:a,subTree:o,um:s,m:c,a:l}=e;ci(c),ci(l),r&&oe(r),i.stop(),a&&(a.flags|=8,k(o,e,t,n)),s&&J(s,t),J(()=>{e.isUnmounted=!0},t)},ve=(e,t,n,r=!1,i=!1,a=0)=>{for(let o=a;o{if(e.shapeFlag&6)return ye(e.component.subTree);if(e.shapeFlag&128)return e.suspense.next();let t=h(e.anchor||e.el),n=t&&t[Dn];return n?h(n):t},be=!1,xe=(e,t,n)=>{let r;e==null?t._vnode&&(k(t._vnode,null,null,!0),r=t._vnode.component):v(t._vnode||null,e,t,null,null,null,n),t._vnode=e,be||=(be=!0,dn(r),fn(),!1)},Se={p:v,um:k,m:me,r:he,mt:O,mc:T,pc:de,pbc:E,n:ye,o:e},Ce,A;return i&&([Ce,A]=i(Se)),{render:xe,hydrate:Ce,createApp:Sr(xe,Ce)}}function ni({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 ri({effect:e,job:t},n){n?(e.flags|=32,t.flags|=4):(e.flags&=-33,t.flags&=-5)}function ii(e,t){return(!e||e&&!e.pendingBranch)&&t&&!t.persisted}function ai(e,t,n=!1){let r=e.children,i=t.children;if(d(r)&&d(i))for(let e=0;e>1,e[n[s]]0&&(t[r]=n[a-1]),n[a]=r)}}for(a=n.length,o=n[a-1];a-- >0;)n[a]=o,o=t[o];return n}function si(e){let t=e.subTree.component;if(t)return t.asyncDep&&!t.asyncResolved?t:si(t)}function ci(e){if(e)for(let t=0;te.__isSuspense;function di(e,t){t&&t.pendingBranch?d(e)?t.effects.push(...e):t.effects.push(e):un(e)}var fi=Symbol.for(`v-fgt`),pi=Symbol.for(`v-txt`),mi=Symbol.for(`v-cmt`),hi=Symbol.for(`v-stc`),gi=[],Y=null;function _i(e=!1){gi.push(Y=e?null:[])}function vi(){gi.pop(),Y=gi[gi.length-1]||null}var yi=1;function bi(e,t=!1){yi+=e,e<0&&Y&&t&&(Y.hasOnce=!0)}function xi(e){return e.dynamicChildren=yi>0?Y||n:null,vi(),yi>0&&Y&&Y.push(e),e}function Si(e,t,n,r,i,a){return xi(X(e,t,n,r,i,a,!0))}function Ci(e,t,n,r,i){return xi(Oi(e,t,n,r,i,!0))}function wi(e){return e?e.__v_isVNode===!0:!1}function Ti(e,t){return e.type===t.type&&e.key===t.key}var Ei=({key:e})=>e??null,Di=({ref:e,ref_key:t,ref_for:n})=>(typeof e==`number`&&(e=``+e),e==null?null:g(e)||V(e)||h(e)?{i:K,r:e,k:t,f:!!n}:e);function X(e,t=null,n=null,r=0,i=null,a=e===fi?0:1,o=!1,s=!1){let c={__v_isVNode:!0,__v_skip:!0,type:e,props:t,key:t&&Ei(t),ref:t&&Di(t),scopeId:hn,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:a,patchFlag:r,dynamicProps:i,dynamicChildren:null,appContext:null,ctx:K};return s?(Fi(c,n),a&128&&e.normalize(c)):n&&(c.shapeFlag|=g(n)?8:16),yi>0&&!o&&Y&&(c.patchFlag>0||a&6)&&c.patchFlag!==32&&Y.push(c),c}var Oi=ki;function ki(e,t=null,n=null,r=0,i=null,a=!1){if((!e||e===er)&&(e=mi),wi(e)){let r=ji(e,t,!0);return n&&Fi(r,n),yi>0&&!a&&Y&&(r.shapeFlag&6?Y[Y.indexOf(e)]=r:Y.push(r)),r.patchFlag=-2,r}if(na(e)&&(e=e.__vccOpts),t){t=Ai(t);let{class:e,style:n}=t;e&&!g(e)&&(t.class=k(e)),v(n)&&(Ft(n)&&!d(n)&&(n=s({},n)),t.style=ue(n))}let o=g(e)?1:ui(e)?128:On(e)?64:v(e)?4:h(e)?2:0;return X(e,t,n,r,i,o,a,!0)}function Ai(e){return e?Ft(e)||Rr(e)?s({},e):e:null}function ji(e,t,n=!1,r=!1){let{props:i,ref:a,patchFlag:o,children:s,transition:c}=e,l=t?Ii(i||{},t):i,u={__v_isVNode:!0,__v_skip:!0,type:e.type,props:l,key:l&&Ei(l),ref:t&&t.ref?n&&a?d(a)?a.concat(Di(t)):[a,Di(t)]:Di(t):a,scopeId:e.scopeId,slotScopeIds:e.slotScopeIds,children:s,target:e.target,targetStart:e.targetStart,targetAnchor:e.targetAnchor,staticCount:e.staticCount,shapeFlag:e.shapeFlag,patchFlag:t&&e.type!==fi?o===-1?16:o|16:o,dynamicProps:e.dynamicProps,dynamicChildren:e.dynamicChildren,appContext:e.appContext,dirs:e.dirs,transition:c,component:e.component,suspense:e.suspense,ssContent:e.ssContent&&ji(e.ssContent),ssFallback:e.ssFallback&&ji(e.ssFallback),placeholder:e.placeholder,el:e.el,anchor:e.anchor,ctx:e.ctx,ce:e.ce};return c&&r&&An(u,c.clone(u)),u}function Mi(e=` `,t=0){return Oi(pi,null,e,t)}function Ni(e=``,t=!1){return t?(_i(),Ci(mi,null,e)):Oi(mi,null,e)}function Z(e){return e==null||typeof e==`boolean`?Oi(mi):d(e)?Oi(fi,null,e.slice()):wi(e)?Pi(e):Oi(pi,null,String(e))}function Pi(e){return e.el===null&&e.patchFlag!==-1||e.memo?e:ji(e)}function Fi(e,t){let n=0,{shapeFlag:r}=e;if(t==null)t=null;else if(d(t))n=16;else if(typeof t==`object`)if(r&65){let n=t.default;n&&(n._c&&(n._d=!1),Fi(e,n()),n._c&&(n._d=!0));return}else{n=32;let r=t._;!r&&!Rr(t)?t._ctx=K:r===3&&K&&(K.slots._===1?t._=1:(t._=2,e.patchFlag|=1024))}else h(t)?(t={default:t,_ctx:K},n=32):(t=String(t),r&64?(n=16,t=[Mi(t)]):n=8);e.children=t,e.shapeFlag|=n}function Ii(...e){let t={};for(let n=0;n$||K,Vi,Hi;{let e=le(),t=(t,n)=>{let r;return(r=e[t])||(r=e[t]=[]),r.push(n),e=>{r.length>1?r.forEach(t=>t(e)):r[0](e)}};Vi=t(`__VUE_INSTANCE_SETTERS__`,e=>$=e),Hi=t(`__VUE_SSR_SETTERS__`,e=>Ki=e)}var Ui=e=>{let t=$;return Vi(e),e.scope.on(),()=>{e.scope.off(),Vi(t)}},Wi=()=>{$&&$.scope.off(),Vi(null)};function Gi(e){return e.vnode.shapeFlag&4}var Ki=!1;function qi(e,t=!1,n=!1){t&&Hi(t);let{props:r,children:i}=e.vnode,a=Gi(e);zr(e,r,a,t),Qr(e,i,n||t);let o=a?Ji(e,t):void 0;return t&&Hi(!1),o}function Ji(e,t){let n=e.type;e.accessCache=Object.create(null),e.proxy=new Proxy(e.ctx,ir);let{setup:r}=n;if(r){N();let n=e.setupContext=r.length>1?ea(e):null,i=Ui(e),a=Zt(r,e,0,[e.props,n]),o=y(a);if(Ve(),i(),(o||e.sp)&&!In(e)&&jn(e),o){if(a.then(Wi,Wi),t)return a.then(n=>{Yi(e,n,t)}).catch(t=>{Qt(t,e,0)});e.asyncDep=a}else Yi(e,a,t)}else Qi(e,t)}function Yi(e,t,n){h(t)?e.type.__ssrInlineRender?e.ssrRender=t:e.render=t:v(t)&&(e.setupState=Ht(t)),Qi(e,n)}var Xi,Zi;function Qi(e,t,n){let i=e.type;if(!e.render){if(!t&&Xi&&!i.render){let t=i.template||dr(e).template;if(t){let{isCustomElement:n,compilerOptions:r}=e.appContext.config,{delimiters:a,compilerOptions:o}=i;i.render=Xi(t,s(s({isCustomElement:n,delimiters:a},r),o))}}e.render=i.render||r,Zi&&Zi(e)}{let t=Ui(e);N();try{sr(e)}finally{Ve(),t()}}}var $i={get(e,t){return P(e,`get`,``),e[t]}};function ea(e){return{attrs:new Proxy(e.attrs,$i),slots:e.slots,emit:e.emit,expose:t=>{e.exposed=t||{}}}}function ta(e){return e.exposed?e.exposeProxy||=new Proxy(Ht(It(e.exposed)),{get(t,n){if(n in t)return t[n];if(n in nr)return nr[n](e)},has(e,t){return t in e||t in nr}}):e.proxy}function na(e){return h(e)&&`__vccOpts`in e}var ra=(e,t)=>Wt(e,t,Ki),ia=`3.5.30`,aa=void 0,oa=typeof window<`u`&&window.trustedTypes;if(oa)try{aa=oa.createPolicy(`vue`,{createHTML:e=>e})}catch{}var sa=aa?e=>aa.createHTML(e):e=>e,ca=`http://www.w3.org/2000/svg`,la=`http://www.w3.org/1998/Math/MathML`,ua=typeof document<`u`?document:null,da=ua&&ua.createElement(`template`),fa={insert:(e,t,n)=>{t.insertBefore(e,n||null)},remove:e=>{let t=e.parentNode;t&&t.removeChild(e)},createElement:(e,t,n,r)=>{let i=t===`svg`?ua.createElementNS(ca,e):t===`mathml`?ua.createElementNS(la,e):n?ua.createElement(e,{is:n}):ua.createElement(e);return e===`select`&&r&&r.multiple!=null&&i.setAttribute(`multiple`,r.multiple),i},createText:e=>ua.createTextNode(e),createComment:e=>ua.createComment(e),setText:(e,t)=>{e.nodeValue=t},setElementText:(e,t)=>{e.textContent=t},parentNode:e=>e.parentNode,nextSibling:e=>e.nextSibling,querySelector:e=>ua.querySelector(e),setScopeId(e,t){e.setAttribute(t,``)},insertStaticContent(e,t,n,r,i,a){let o=n?n.previousSibling:t.lastChild;if(i&&(i===a||i.nextSibling))for(;t.insertBefore(i.cloneNode(!0),n),!(i===a||!(i=i.nextSibling)););else{da.innerHTML=sa(r===`svg`?`${e}`:r===`mathml`?`${e}`:e);let i=da.content;if(r===`svg`||r===`mathml`){let e=i.firstChild;for(;e.firstChild;)i.appendChild(e.firstChild);i.removeChild(e)}t.insertBefore(i,n)}return[o?o.nextSibling:t.firstChild,n?n.previousSibling:t.lastChild]}},pa=Symbol(`_vtc`);function ma(e,t,n){let r=e[pa];r&&(t=(t?[t,...r]:[...r]).join(` `)),t==null?e.removeAttribute(`class`):n?e.setAttribute(`class`,t):e.className=t}var ha=Symbol(`_vod`),ga=Symbol(`_vsh`),_a=Symbol(``),va=/(?:^|;)\s*display\s*:/;function ya(e,t,n){let r=e.style,i=g(n),a=!1;if(n&&!i){if(t)if(g(t))for(let e of t.split(`;`)){let t=e.slice(0,e.indexOf(`:`)).trim();n[t]??xa(r,t,``)}else for(let e in t)n[e]??xa(r,e,``);for(let e in n)e===`display`&&(a=!0),xa(r,e,n[e])}else if(i){if(t!==n){let e=r[_a];e&&(n+=`;`+e),r.cssText=n,a=va.test(n)}}else t&&e.removeAttribute(`style`);ha in e&&(e[ha]=a?r.display:``,e[ga]&&(r.display=`none`))}var ba=/\s*!important$/;function xa(e,t,n){if(d(n))n.forEach(n=>xa(e,t,n));else if(n??=``,t.startsWith(`--`))e.setProperty(t,n);else{let r=wa(e,t);ba.test(n)?e.setProperty(E(r),n.replace(ba,``),`important`):e[r]=n}}var Sa=[`Webkit`,`Moz`,`ms`],Ca={};function wa(e,t){let n=Ca[t];if(n)return n;let r=T(t);if(r!==`filter`&&r in e)return Ca[t]=r;r=ie(r);for(let n=0;nPa||=(Fa.then(()=>Pa=0),Date.now());function La(e,t){let n=e=>{if(!e._vts)e._vts=Date.now();else if(e._vts<=n.attached)return;U(Ra(e,n.value),t,5,[e])};return n.value=e,n.attached=Ia(),n}function Ra(e,t){if(d(t)){let n=e.stopImmediatePropagation;return e.stopImmediatePropagation=()=>{n.call(e),e._stopped=!0},t.map(e=>t=>!t._stopped&&e&&e(t))}else return t}var za=e=>e.charCodeAt(0)===111&&e.charCodeAt(1)===110&&e.charCodeAt(2)>96&&e.charCodeAt(2)<123,Ba=(e,t,n,r,i,s)=>{let c=i===`svg`;t===`class`?ma(e,r,c):t===`style`?ya(e,n,r):a(t)?o(t)||ja(e,t,n,r,s):(t[0]===`.`?(t=t.slice(1),!0):t[0]===`^`?(t=t.slice(1),!1):Va(e,t,r,c))?(Da(e,t,r),!e.tagName.includes(`-`)&&(t===`value`||t===`checked`||t===`selected`)&&Ea(e,t,r,c,s,t!==`value`)):e._isVueCE&&(Ha(e,t)||e._def.__asyncLoader&&(/[A-Z]/.test(t)||!g(r)))?Da(e,T(t),r,s,t):(t===`true-value`?e._trueValue=r:t===`false-value`&&(e._falseValue=r),Ea(e,t,r,c))};function Va(e,t,n,r){if(r)return!!(t===`innerHTML`||t===`textContent`||t in e&&za(t)&&h(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`){let t=e.tagName;if(t===`IMG`||t===`VIDEO`||t===`CANVAS`||t===`SOURCE`)return!1}return za(t)&&g(n)?!1:t in e}function Ha(e,t){let n=e._def.props;if(!n)return!1;let r=T(t);return Array.isArray(n)?n.some(e=>T(e)===r):Object.keys(n).some(e=>T(e)===r)}var Ua=s({patchProp:Ba},fa),Wa;function Ga(){return Wa||=ei(Ua)}var Ka=((...e)=>{let t=Ga().createApp(...e),{mount:n}=t;return t.mount=e=>{let r=Ja(e);if(!r)return;let i=t._component;!h(i)&&!i.render&&!i.template&&(i.template=r.innerHTML),r.nodeType===1&&(r.textContent=``);let a=n(r,!1,qa(r));return r instanceof Element&&(r.removeAttribute(`v-cloak`),r.setAttribute(`data-v-app`,``)),a},t});function qa(e){if(e instanceof SVGElement)return`svg`;if(typeof MathMLElement==`function`&&e instanceof MathMLElement)return`mathml`}function Ja(e){return g(e)?document.querySelector(e):e}var Ya=class{static async callApi(e,t=null){if(!window.chrome?.webview?.hostObjects?.gateway){let e=`WebView2 环境未就绪 (hostObjects.gateway 缺失)`;throw console.error(e),Error(e)}let n=window.chrome.webview.hostObjects.gateway,r={action:e,data:t};try{let t=await n.InvokeAction(JSON.stringify(r));console.log(`API [${e}] 原始响应:`,t);let i=JSON.parse(t);if(i.success)return i.data;{let t=i.message||`未知错误`;throw console.error(`API [${e}] 返回失败:`,t),Error(t)}}catch(t){throw console.error(`API 调用崩溃 [${e}]:`,t),t}}};function Xa(){let e=Rt(`等待消息...`),t=Rt(null),n=Rt(null),r=async()=>{try{t.value=await Ya.callApi(`GetSystemInfo`)}catch(e){alert(`获取失败: `+e.message)}},i=async()=>{try{await Ya.callApi(`ShowDialog`,`这是来自 Vue 的标准化信封消息!`)}catch(e){console.error(`弹窗指令发送失败:`,e)}},a=async()=>{try{n.value=await Ya.callApi(`Calculate`,{a:10,b:20})}catch(e){console.error(`计算失败:`,e)}},o=t=>{e.value=t.data};return Gn(()=>{window.chrome&&window.chrome.webview&&window.chrome.webview.addEventListener(`message`,o)}),{receivedMsg:e,systemInfo:t,calcResult:n,fetchSystemInfo:r,triggerNativeAlert:i,runCalculation:a}}var Za=(e,t)=>{let n=e.__vccOpts||e;for(let[e,r]of t)n[e]=r;return n},Qa={class:`container`},$a={class:`card`},eo={class:`card`},to={class:`btn-group`},no={key:0,class:`result-box`},ro={key:1,class:`result-box`};Ka(Za({__name:`App`,setup(e){let{receivedMsg:t,systemInfo:n,calcResult:r,fetchSystemInfo:i,triggerNativeAlert:a,runCalculation:o}=Xa();return(e,s)=>(_i(),Si(`div`,Qa,[s[7]||=X(`h1`,null,`WebView2 标准化交互网关`,-1),X(`div`,$a,[s[3]||=X(`h3`,null,`1. 属性同步 (WebMessage)`,-1),X(`p`,null,`来自 WPF 的推送: `+xe(H(t)),1)]),X(`div`,eo,[s[6]||=X(`h3`,null,`2. 动态 API 调用 (Host Objects + 信封)`,-1),X(`div`,to,[X(`button`,{onClick:s[0]||=(...e)=>H(i)&&H(i)(...e)},`获取 C# 系统信息`),X(`button`,{onClick:s[1]||=(...e)=>H(a)&&H(a)(...e),class:`btn-warning`},`触发原生弹窗`),X(`button`,{onClick:s[2]||=(...e)=>H(o)&&H(o)(...e),class:`btn-info`},`计算 10 + 20`)]),H(n)?(_i(),Si(`div`,no,[s[4]||=X(`b`,null,`系统信息:`,-1),Mi(` `+xe(H(n).OS)+` (`+xe(H(n).Runtime)+`) `,1)])):Ni(``,!0),H(r)===null?Ni(``,!0):(_i(),Si(`div`,ro,[s[5]||=X(`b`,null,`计算结果:`,-1),Mi(` `+xe(H(r)),1)]))])]))}},[[`__scopeId`,`data-v-d9e54285`]])).mount(`#app`); \ No newline at end of file diff --git a/WebView2Demo/wwwroot/assets/index-onfabBEH.css b/WebView2Demo/wwwroot/assets/index-onfabBEH.css new file mode 100644 index 0000000..82c8d5f --- /dev/null +++ b/WebView2Demo/wwwroot/assets/index-onfabBEH.css @@ -0,0 +1 @@ +:root{--lightningcss-light:initial;--lightningcss-dark: ;color-scheme:light dark;color:#ffffffde;font-synthesis:none;text-rendering:optimizelegibility;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale;background-color:#242424;font-family:system-ui,Avenir,Helvetica,Arial,sans-serif;font-weight:400;line-height:1.5}@media (prefers-color-scheme:dark){:root{--lightningcss-light: ;--lightningcss-dark:initial}}a{color:#646cff;-webkit-text-decoration:inherit;text-decoration:inherit;font-weight:500}a:hover{color:#535bf2}body{place-items:center;min-width:320px;min-height:100vh;margin:0;display:flex}h1{font-size:3.2em;line-height:1.1}button{cursor:pointer;background-color:#1a1a1a;border:1px solid #0000;border-radius:8px;padding:.6em 1.2em;font-family:inherit;font-size:1em;font-weight:500;transition:border-color .25s}button:hover{border-color:#646cff}button:focus,button:focus-visible{outline:4px auto -webkit-focus-ring-color}.card{padding:2em}#app{text-align:center;max-width:1280px;margin:0 auto;padding:2rem}@media (prefers-color-scheme:light){:root{color:#213547;background-color:#fff}a:hover{color:#747bff}button{background-color:#f9f9f9}}.container[data-v-d9e54285]{padding:20px;font-family:Segoe UI,Tahoma,Geneva,Verdana,sans-serif}.card[data-v-d9e54285]{background:#fff;border:1px solid #eee;border-radius:8px;margin-bottom:15px;padding:15px;box-shadow:0 2px 4px #0000000d}.btn-group[data-v-d9e54285]{flex-wrap:wrap;gap:10px;margin-top:10px;display:flex}button[data-v-d9e54285]{color:#fff;cursor:pointer;background:#42b883;border:none;border-radius:4px;padding:8px 16px}button[data-v-d9e54285]:hover{background:#3aa876}.btn-warning[data-v-d9e54285]{background:#f39c12}.btn-info[data-v-d9e54285]{background:#3498db}.result-box[data-v-d9e54285]{background:#f8f9fa;border-left:4px solid #42b883;margin-top:15px;padding:10px;font-size:.9em} diff --git a/WebView2Demo/wwwroot/index.html b/WebView2Demo/wwwroot/index.html new file mode 100644 index 0000000..415bc42 --- /dev/null +++ b/WebView2Demo/wwwroot/index.html @@ -0,0 +1,14 @@ + + + + + + + web-app + + + + +
+ + diff --git a/WebView2Demo/wwwroot/vite.svg b/WebView2Demo/wwwroot/vite.svg new file mode 100644 index 0000000..e7b8dfb --- /dev/null +++ b/WebView2Demo/wwwroot/vite.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/publish.ps1 b/publish.ps1 new file mode 100644 index 0000000..8aa225b --- /dev/null +++ b/publish.ps1 @@ -0,0 +1,36 @@ +# 1. Path Configuration +$rootPath = Get-Location +$vuePath = Join-Path $rootPath "web-app" +$wpfPath = Join-Path $rootPath "WebView2Demo" +$publishPath = Join-Path $rootPath "Publish" + +# 2. Cleanup old publish folder +Write-Host ">>> Cleaning old publish files..." -ForegroundColor Cyan +if (Test-Path $publishPath) { Remove-Item -Path $publishPath -Recurse -Force } +New-Item -ItemType Directory -Path $publishPath | Out-Null + +# 3. Build Vue Frontend +Write-Host ">>> Building Vue Frontend..." -ForegroundColor Cyan +Set-Location $vuePath +npm run build +if ($LASTEXITCODE -ne 0) { Write-Host "Vue build failed!" -ForegroundColor Red; exit } + +# 4. Copy Vue assets to WPF directory +Write-Host ">>> Syncing frontend assets to WPF project..." -ForegroundColor Cyan +$vueDist = Join-Path $vuePath "dist" +$wpfWwwroot = Join-Path $wpfPath "wwwroot" + +if (Test-Path $wpfWwwroot) { Remove-Item -Path $wpfWwwroot -Recurse -Force } +New-Item -ItemType Directory -Path $wpfWwwroot | Out-Null +Copy-Item -Path "$vueDist\*" -Destination $wpfWwwroot -Recurse -Force + +# 5. Build and Publish WPF Backend +Write-Host ">>> Publishing WPF project..." -ForegroundColor Cyan +Set-Location $wpfPath +dotnet publish -c Release -o $publishPath +if ($LASTEXITCODE -ne 0) { Write-Host "WPF publish failed!" -ForegroundColor Red; exit } + +Write-Host "`n>>> Publish complete! Output directory: $publishPath" -ForegroundColor Green +Write-Host ">>> You can run $publishPath\WebView2Demo.exe to start the application." -ForegroundColor Green + +Set-Location $rootPath diff --git a/web-app/vite.config.js b/web-app/vite.config.js index bbcf80c..8d08f8e 100644 --- a/web-app/vite.config.js +++ b/web-app/vite.config.js @@ -4,4 +4,5 @@ import vue from '@vitejs/plugin-vue' // https://vite.dev/config/ export default defineConfig({ plugins: [vue()], + base: './', // 关键:使用相对路径,确保在本地文件协议下能正确加载资源 })