diff --git a/docs/assets/index-C56kvnUS.js b/docs/assets/index-B1saULmb.js similarity index 82% rename from docs/assets/index-C56kvnUS.js rename to docs/assets/index-B1saULmb.js index 9de0206..978866a 100644 --- a/docs/assets/index-C56kvnUS.js +++ b/docs/assets/index-B1saULmb.js @@ -2,16 +2,16 @@ var lr=Object.defineProperty;var ar=(e,t,s)=>t in e?lr(e,t,{enumerable:!0,config * @vue/shared v3.5.8 * (c) 2018-present Yuxi (Evan) You and Vue contributors * @license MIT -**//*! #__NO_SIDE_EFFECTS__ */function Gs(e){const t=Object.create(null);for(const s of e.split(","))t[s]=1;return s=>s in t}const Z={},Tt=[],He=()=>{},ur=()=>!1,ps=e=>e.charCodeAt(0)===111&&e.charCodeAt(1)===110&&(e.charCodeAt(2)>122||e.charCodeAt(2)<97),qs=e=>e.startsWith("onUpdate:"),re=Object.assign,Js=(e,t)=>{const s=e.indexOf(t);s>-1&&e.splice(s,1)},fr=Object.prototype.hasOwnProperty,G=(e,t)=>fr.call(e,t),U=Array.isArray,Pt=e=>Kt(e)==="[object Map]",ms=e=>Kt(e)==="[object Set]",Cn=e=>Kt(e)==="[object Date]",W=e=>typeof e=="function",se=e=>typeof e=="string",Ne=e=>typeof e=="symbol",Q=e=>e!==null&&typeof e=="object",Qn=e=>(Q(e)||W(e))&&W(e.then)&&W(e.catch),ei=Object.prototype.toString,Kt=e=>ei.call(e),cr=e=>Kt(e).slice(8,-1),ti=e=>Kt(e)==="[object Object]",zs=e=>se(e)&&e!=="NaN"&&e[0]!=="-"&&""+parseInt(e,10)===e,Vt=Gs(",key,ref,ref_for,ref_key,onVnodeBeforeMount,onVnodeMounted,onVnodeBeforeUpdate,onVnodeUpdated,onVnodeBeforeUnmount,onVnodeUnmounted"),gs=e=>{const t=Object.create(null);return s=>t[s]||(t[s]=e(s))},dr=/-(\w)/g,pt=gs(e=>e.replace(dr,(t,s)=>s?s.toUpperCase():"")),hr=/\B([A-Z])/g,vt=gs(e=>e.replace(hr,"-$1").toLowerCase()),si=gs(e=>e.charAt(0).toUpperCase()+e.slice(1)),Ps=gs(e=>e?`on${si(e)}`:""),st=(e,t)=>!Object.is(e,t),ns=(e,...t)=>{for(let s=0;s{Object.defineProperty(e,t,{configurable:!0,enumerable:!1,writable:n,value:s})},Us=e=>{const t=parseFloat(e);return isNaN(t)?e:t};let wn;const ii=()=>wn||(wn=typeof globalThis<"u"?globalThis:typeof self<"u"?self:typeof window<"u"?window:typeof global<"u"?global:{});function Zs(e){if(U(e)){const t={};for(let s=0;s{if(s){const n=s.split(mr);n.length>1&&(t[n[0].trim()]=n[1].trim())}}),t}function Qs(e){let t="";if(se(e))t=e;else if(U(e))for(let s=0;svs(s,t))}const li=e=>!!(e&&e.__v_isRef===!0),De=e=>se(e)?e:e==null?"":U(e)||Q(e)&&(e.toString===ei||!W(e.toString))?li(e)?De(e.value):JSON.stringify(e,ai,2):String(e),ai=(e,t)=>li(t)?ai(e,t.value):Pt(t)?{[`Map(${t.size})`]:[...t.entries()].reduce((s,[n,i],r)=>(s[Ms(n,r)+" =>"]=i,s),{})}:ms(t)?{[`Set(${t.size})`]:[...t.values()].map(s=>Ms(s))}:Ne(t)?Ms(t):Q(t)&&!U(t)&&!ti(t)?String(t):t,Ms=(e,t="")=>{var s;return Ne(e)?`Symbol(${(s=e.description)!=null?s:t})`:e};/** +**//*! #__NO_SIDE_EFFECTS__ */function Gs(e){const t=Object.create(null);for(const s of e.split(","))t[s]=1;return s=>s in t}const Z={},Tt=[],He=()=>{},ur=()=>!1,ps=e=>e.charCodeAt(0)===111&&e.charCodeAt(1)===110&&(e.charCodeAt(2)>122||e.charCodeAt(2)<97),qs=e=>e.startsWith("onUpdate:"),re=Object.assign,Js=(e,t)=>{const s=e.indexOf(t);s>-1&&e.splice(s,1)},fr=Object.prototype.hasOwnProperty,G=(e,t)=>fr.call(e,t),U=Array.isArray,Pt=e=>Kt(e)==="[object Map]",ms=e=>Kt(e)==="[object Set]",Cn=e=>Kt(e)==="[object Date]",H=e=>typeof e=="function",se=e=>typeof e=="string",Ne=e=>typeof e=="symbol",Q=e=>e!==null&&typeof e=="object",Qn=e=>(Q(e)||H(e))&&H(e.then)&&H(e.catch),ei=Object.prototype.toString,Kt=e=>ei.call(e),cr=e=>Kt(e).slice(8,-1),ti=e=>Kt(e)==="[object Object]",zs=e=>se(e)&&e!=="NaN"&&e[0]!=="-"&&""+parseInt(e,10)===e,Vt=Gs(",key,ref,ref_for,ref_key,onVnodeBeforeMount,onVnodeMounted,onVnodeBeforeUpdate,onVnodeUpdated,onVnodeBeforeUnmount,onVnodeUnmounted"),gs=e=>{const t=Object.create(null);return s=>t[s]||(t[s]=e(s))},dr=/-(\w)/g,pt=gs(e=>e.replace(dr,(t,s)=>s?s.toUpperCase():"")),hr=/\B([A-Z])/g,vt=gs(e=>e.replace(hr,"-$1").toLowerCase()),si=gs(e=>e.charAt(0).toUpperCase()+e.slice(1)),Ps=gs(e=>e?`on${si(e)}`:""),st=(e,t)=>!Object.is(e,t),ns=(e,...t)=>{for(let s=0;s{Object.defineProperty(e,t,{configurable:!0,enumerable:!1,writable:n,value:s})},Us=e=>{const t=parseFloat(e);return isNaN(t)?e:t};let wn;const ii=()=>wn||(wn=typeof globalThis<"u"?globalThis:typeof self<"u"?self:typeof window<"u"?window:typeof global<"u"?global:{});function Zs(e){if(U(e)){const t={};for(let s=0;s{if(s){const n=s.split(mr);n.length>1&&(t[n[0].trim()]=n[1].trim())}}),t}function Qs(e){let t="";if(se(e))t=e;else if(U(e))for(let s=0;svs(s,t))}const li=e=>!!(e&&e.__v_isRef===!0),De=e=>se(e)?e:e==null?"":U(e)||Q(e)&&(e.toString===ei||!H(e.toString))?li(e)?De(e.value):JSON.stringify(e,ai,2):String(e),ai=(e,t)=>li(t)?ai(e,t.value):Pt(t)?{[`Map(${t.size})`]:[...t.entries()].reduce((s,[n,i],r)=>(s[Ms(n,r)+" =>"]=i,s),{})}:ms(t)?{[`Set(${t.size})`]:[...t.values()].map(s=>Ms(s))}:Ne(t)?Ms(t):Q(t)&&!U(t)&&!ti(t)?String(t):t,Ms=(e,t="")=>{var s;return Ne(e)?`Symbol(${(s=e.description)!=null?s:t})`:e};/** * @vue/reactivity v3.5.8 * (c) 2018-present Yuxi (Evan) You and Vue contributors * @license MIT -**/let we;class wr{constructor(t=!1){this.detached=t,this._active=!0,this.effects=[],this.cleanups=[],this._isPaused=!1,this.parent=we,!t&&we&&(this.index=(we.scopes||(we.scopes=[])).push(this)-1)}get active(){return this._active}pause(){if(this._active){this._isPaused=!0;let t,s;if(this.scopes)for(t=0,s=this.scopes.length;t0)return;let e;for(;Dt;){let t=Dt;for(Dt=void 0;t;){const s=t.next;if(t.next=void 0,t.flags&=-9,t.flags&1)try{t.trigger()}catch(n){e||(e=n)}t=s}}if(e)throw e}function di(e){for(let t=e.deps;t;t=t.nextDep)t.version=-1,t.prevActiveLink=t.dep.activeLink,t.dep.activeLink=t}function hi(e,t=!1){let s,n=e.depsTail,i=n;for(;i;){const r=i.prevDep;i.version===-1?(i===n&&(n=r),sn(i,t),Sr(i)):s=i,i.dep.activeLink=i.prevActiveLink,i.prevActiveLink=void 0,i=r}e.deps=s,e.depsTail=n}function Ws(e){for(let t=e.deps;t;t=t.nextDep)if(t.dep.version!==t.version||t.dep.computed&&(pi(t.dep.computed)||t.dep.version!==t.version))return!0;return!!e._dirty}function pi(e){if(e.flags&4&&!(e.flags&16)||(e.flags&=-17,e.globalVersion===jt))return;e.globalVersion=jt;const t=e.dep;if(e.flags|=2,t.version>0&&!e.isSSR&&e.deps&&!Ws(e)){e.flags&=-3;return}const s=z,n=_e;z=e,_e=!0;try{di(e);const i=e.fn(e._value);(t.version===0||st(i,e._value))&&(e._value=i,t.version++)}catch(i){throw t.version++,i}finally{z=s,_e=n,hi(e,!0),e.flags&=-3}}function sn(e,t=!1){const{dep:s,prevSub:n,nextSub:i}=e;if(n&&(n.nextSub=i,e.prevSub=void 0),i&&(i.prevSub=n,e.nextSub=void 0),s.subs===e&&(s.subs=n),!s.subs)if(s.computed){s.computed.flags&=-5;for(let r=s.computed.deps;r;r=r.nextDep)sn(r,!0)}else s.map&&!t&&(s.map.delete(s.key),s.map.size||as.delete(s.target))}function Sr(e){const{prevDep:t,nextDep:s}=e;t&&(t.nextDep=s,e.prevDep=void 0),s&&(s.prevDep=t,e.nextDep=void 0)}let _e=!0;const mi=[];function nt(){mi.push(_e),_e=!1}function it(){const e=mi.pop();_e=e===void 0?!0:e}function xn(e){const{cleanup:t}=e;if(e.cleanup=void 0,t){const s=z;z=void 0;try{t()}finally{z=s}}}let jt=0;class Tr{constructor(t,s){this.sub=t,this.dep=s,this.version=s.version,this.nextDep=this.prevDep=this.nextSub=this.prevSub=this.prevActiveLink=void 0}}class nn{constructor(t){this.computed=t,this.version=0,this.activeLink=void 0,this.subs=void 0,this.target=void 0,this.map=void 0,this.key=void 0}track(t){if(!z||!_e||z===this.computed)return;let s=this.activeLink;if(s===void 0||s.sub!==z)s=this.activeLink=new Tr(z,this),z.deps?(s.prevDep=z.depsTail,z.depsTail.nextDep=s,z.depsTail=s):z.deps=z.depsTail=s,z.flags&4&&gi(s);else if(s.version===-1&&(s.version=this.version,s.nextDep)){const n=s.nextDep;n.prevDep=s.prevDep,s.prevDep&&(s.prevDep.nextDep=n),s.prevDep=z.depsTail,s.nextDep=void 0,z.depsTail.nextDep=s,z.depsTail=s,z.deps===s&&(z.deps=n)}return s}trigger(t){this.version++,jt++,this.notify(t)}notify(t){en();try{for(let s=this.subs;s;s=s.prevSub)s.sub.notify()&&s.sub.dep.notify()}finally{tn()}}}function gi(e){const t=e.dep.computed;if(t&&!e.dep.subs){t.flags|=20;for(let n=t.deps;n;n=n.nextDep)gi(n)}const s=e.dep.subs;s!==e&&(e.prevSub=s,s&&(s.nextSub=e)),e.dep.subs=e}const as=new WeakMap,ht=Symbol(""),Hs=Symbol(""),$t=Symbol("");function ae(e,t,s){if(_e&&z){let n=as.get(e);n||as.set(e,n=new Map);let i=n.get(s);i||(n.set(s,i=new nn),i.target=e,i.map=n,i.key=s),i.track()}}function Ge(e,t,s,n,i,r){const o=as.get(e);if(!o){jt++;return}const l=u=>{u&&u.trigger()};if(en(),t==="clear")o.forEach(l);else{const u=U(e),p=u&&zs(s);if(u&&s==="length"){const c=Number(n);o.forEach((m,g)=>{(g==="length"||g===$t||!Ne(g)&&g>=c)&&l(m)})}else switch(s!==void 0&&l(o.get(s)),p&&l(o.get($t)),t){case"add":u?p&&l(o.get("length")):(l(o.get(ht)),Pt(e)&&l(o.get(Hs)));break;case"delete":u||(l(o.get(ht)),Pt(e)&&l(o.get(Hs)));break;case"set":Pt(e)&&l(o.get(ht));break}}tn()}function Ct(e){const t=q(e);return t===e?t:(ae(t,"iterate",$t),Ee(e)?t:t.map(ce))}function rn(e){return ae(e=q(e),"iterate",$t),e}const Pr={__proto__:null,[Symbol.iterator](){return Es(this,Symbol.iterator,ce)},concat(...e){return Ct(this).concat(...e.map(t=>U(t)?Ct(t):t))},entries(){return Es(this,"entries",e=>(e[1]=ce(e[1]),e))},every(e,t){return ke(this,"every",e,t,void 0,arguments)},filter(e,t){return ke(this,"filter",e,t,s=>s.map(ce),arguments)},find(e,t){return ke(this,"find",e,t,ce,arguments)},findIndex(e,t){return ke(this,"findIndex",e,t,void 0,arguments)},findLast(e,t){return ke(this,"findLast",e,t,ce,arguments)},findLastIndex(e,t){return ke(this,"findLastIndex",e,t,void 0,arguments)},forEach(e,t){return ke(this,"forEach",e,t,void 0,arguments)},includes(...e){return Rs(this,"includes",e)},indexOf(...e){return Rs(this,"indexOf",e)},join(e){return Ct(this).join(e)},lastIndexOf(...e){return Rs(this,"lastIndexOf",e)},map(e,t){return ke(this,"map",e,t,void 0,arguments)},pop(){return At(this,"pop")},push(...e){return At(this,"push",e)},reduce(e,...t){return Sn(this,"reduce",e,t)},reduceRight(e,...t){return Sn(this,"reduceRight",e,t)},shift(){return At(this,"shift")},some(e,t){return ke(this,"some",e,t,void 0,arguments)},splice(...e){return At(this,"splice",e)},toReversed(){return Ct(this).toReversed()},toSorted(e){return Ct(this).toSorted(e)},toSpliced(...e){return Ct(this).toSpliced(...e)},unshift(...e){return At(this,"unshift",e)},values(){return Es(this,"values",ce)}};function Es(e,t,s){const n=rn(e),i=n[t]();return n!==e&&!Ee(e)&&(i._next=i.next,i.next=()=>{const r=i._next();return r.value&&(r.value=s(r.value)),r}),i}const Mr=Array.prototype;function ke(e,t,s,n,i,r){const o=rn(e),l=o!==e&&!Ee(e),u=o[t];if(u!==Mr[t]){const m=u.apply(e,r);return l?ce(m):m}let p=s;o!==e&&(l?p=function(m,g){return s.call(this,ce(m),g,e)}:s.length>2&&(p=function(m,g){return s.call(this,m,g,e)}));const c=u.call(o,p,n);return l&&i?i(c):c}function Sn(e,t,s,n){const i=rn(e);let r=s;return i!==e&&(Ee(e)?s.length>3&&(r=function(o,l,u){return s.call(this,o,l,u,e)}):r=function(o,l,u){return s.call(this,o,ce(l),u,e)}),i[t](r,...n)}function Rs(e,t,s){const n=q(e);ae(n,"iterate",$t);const i=n[t](...s);return(i===-1||i===!1)&&fn(s[0])?(s[0]=q(s[0]),n[t](...s)):i}function At(e,t,s=[]){nt(),en();const n=q(e)[t].apply(e,s);return tn(),it(),n}const _r=Gs("__proto__,__v_isRef,__isVue"),vi=new Set(Object.getOwnPropertyNames(Symbol).filter(e=>e!=="arguments"&&e!=="caller").map(e=>Symbol[e]).filter(Ne));function Er(e){Ne(e)||(e=String(e));const t=q(this);return ae(t,"has",e),t.hasOwnProperty(e)}class bi{constructor(t=!1,s=!1){this._isReadonly=t,this._isShallow=s}get(t,s,n){const i=this._isReadonly,r=this._isShallow;if(s==="__v_isReactive")return!i;if(s==="__v_isReadonly")return i;if(s==="__v_isShallow")return r;if(s==="__v_raw")return n===(i?r?jr:xi:r?wi:Ci).get(t)||Object.getPrototypeOf(t)===Object.getPrototypeOf(n)?t:void 0;const o=U(t);if(!i){let u;if(o&&(u=Pr[s]))return u;if(s==="hasOwnProperty")return Er}const l=Reflect.get(t,s,le(t)?t:n);return(Ne(s)?vi.has(s):_r(s))||(i||ae(t,"get",s),r)?l:le(l)?o&&zs(s)?l:l.value:Q(l)?i?Si(l):an(l):l}}class yi extends bi{constructor(t=!1){super(!1,t)}set(t,s,n,i){let r=t[s];if(!this._isShallow){const u=mt(r);if(!Ee(n)&&!mt(n)&&(r=q(r),n=q(n)),!U(t)&&le(r)&&!le(n))return u?!1:(r.value=n,!0)}const o=U(t)&&zs(s)?Number(s)e,bs=e=>Reflect.getPrototypeOf(e);function Jt(e,t,s=!1,n=!1){e=e.__v_raw;const i=q(e),r=q(t);s||(st(t,r)&&ae(i,"get",t),ae(i,"get",r));const{has:o}=bs(i),l=n?on:s?cn:ce;if(o.call(i,t))return l(e.get(t));if(o.call(i,r))return l(e.get(r));e!==i&&e.get(t)}function zt(e,t=!1){const s=this.__v_raw,n=q(s),i=q(e);return t||(st(e,i)&&ae(n,"has",e),ae(n,"has",i)),e===i?s.has(e):s.has(e)||s.has(i)}function Zt(e,t=!1){return e=e.__v_raw,!t&&ae(q(e),"iterate",ht),Reflect.get(e,"size",e)}function Tn(e,t=!1){!t&&!Ee(e)&&!mt(e)&&(e=q(e));const s=q(this);return bs(s).has.call(s,e)||(s.add(e),Ge(s,"add",e,e)),this}function Pn(e,t,s=!1){!s&&!Ee(t)&&!mt(t)&&(t=q(t));const n=q(this),{has:i,get:r}=bs(n);let o=i.call(n,e);o||(e=q(e),o=i.call(n,e));const l=r.call(n,e);return n.set(e,t),o?st(t,l)&&Ge(n,"set",e,t):Ge(n,"add",e,t),this}function Mn(e){const t=q(this),{has:s,get:n}=bs(t);let i=s.call(t,e);i||(e=q(e),i=s.call(t,e)),n&&n.call(t,e);const r=t.delete(e);return i&&Ge(t,"delete",e,void 0),r}function _n(){const e=q(this),t=e.size!==0,s=e.clear();return t&&Ge(e,"clear",void 0,void 0),s}function Qt(e,t){return function(n,i){const r=this,o=r.__v_raw,l=q(o),u=t?on:e?cn:ce;return!e&&ae(l,"iterate",ht),o.forEach((p,c)=>n.call(i,u(p),u(c),r))}}function es(e,t,s){return function(...n){const i=this.__v_raw,r=q(i),o=Pt(r),l=e==="entries"||e===Symbol.iterator&&o,u=e==="keys"&&o,p=i[e](...n),c=s?on:t?cn:ce;return!t&&ae(r,"iterate",u?Hs:ht),{next(){const{value:m,done:g}=p.next();return g?{value:m,done:g}:{value:l?[c(m[0]),c(m[1])]:c(m),done:g}},[Symbol.iterator](){return this}}}}function Ze(e){return function(...t){return e==="delete"?!1:e==="clear"?void 0:this}}function Fr(){const e={get(r){return Jt(this,r)},get size(){return Zt(this)},has:zt,add:Tn,set:Pn,delete:Mn,clear:_n,forEach:Qt(!1,!1)},t={get(r){return Jt(this,r,!1,!0)},get size(){return Zt(this)},has:zt,add(r){return Tn.call(this,r,!0)},set(r,o){return Pn.call(this,r,o,!0)},delete:Mn,clear:_n,forEach:Qt(!1,!0)},s={get(r){return Jt(this,r,!0)},get size(){return Zt(this,!0)},has(r){return zt.call(this,r,!0)},add:Ze("add"),set:Ze("set"),delete:Ze("delete"),clear:Ze("clear"),forEach:Qt(!0,!1)},n={get(r){return Jt(this,r,!0,!0)},get size(){return Zt(this,!0)},has(r){return zt.call(this,r,!0)},add:Ze("add"),set:Ze("set"),delete:Ze("delete"),clear:Ze("clear"),forEach:Qt(!0,!0)};return["keys","values","entries",Symbol.iterator].forEach(r=>{e[r]=es(r,!1,!1),s[r]=es(r,!0,!1),t[r]=es(r,!1,!0),n[r]=es(r,!0,!0)}),[e,s,t,n]}const[Lr,Vr,Dr,Ur]=Fr();function ln(e,t){const s=t?e?Ur:Dr:e?Vr:Lr;return(n,i,r)=>i==="__v_isReactive"?!e:i==="__v_isReadonly"?e:i==="__v_raw"?n:Reflect.get(G(s,i)&&i in n?s:n,i,r)}const Wr={get:ln(!1,!1)},Hr={get:ln(!1,!0)},Nr={get:ln(!0,!1)};const Ci=new WeakMap,wi=new WeakMap,xi=new WeakMap,jr=new WeakMap;function $r(e){switch(e){case"Object":case"Array":return 1;case"Map":case"Set":case"WeakMap":case"WeakSet":return 2;default:return 0}}function Br(e){return e.__v_skip||!Object.isExtensible(e)?0:$r(cr(e))}function an(e){return mt(e)?e:un(e,!1,Or,Wr,Ci)}function kr(e){return un(e,!1,Ar,Hr,wi)}function Si(e){return un(e,!0,Ir,Nr,xi)}function un(e,t,s,n,i){if(!Q(e)||e.__v_raw&&!(t&&e.__v_isReactive))return e;const r=i.get(e);if(r)return r;const o=Br(e);if(o===0)return e;const l=new Proxy(e,o===2?n:s);return i.set(e,l),l}function Ut(e){return mt(e)?Ut(e.__v_raw):!!(e&&e.__v_isReactive)}function mt(e){return!!(e&&e.__v_isReadonly)}function Ee(e){return!!(e&&e.__v_isShallow)}function fn(e){return e?!!e.__v_raw:!1}function q(e){const t=e&&e.__v_raw;return t?q(t):e}function Yr(e){return!G(e,"__v_skip")&&Object.isExtensible(e)&&ni(e,"__v_skip",!0),e}const ce=e=>Q(e)?an(e):e,cn=e=>Q(e)?Si(e):e;function le(e){return e?e.__v_isRef===!0:!1}function D(e){return Kr(e,!1)}function Kr(e,t){return le(e)?e:new Xr(e,t)}class Xr{constructor(t,s){this.dep=new nn,this.__v_isRef=!0,this.__v_isShallow=!1,this._rawValue=s?t:q(t),this._value=s?t:ce(t),this.__v_isShallow=s}get value(){return this.dep.track(),this._value}set value(t){const s=this._rawValue,n=this.__v_isShallow||Ee(t)||mt(t);t=n?t:q(t),st(t,s)&&(this._rawValue=t,this._value=n?t:ce(t),this.dep.trigger())}}function Gr(e){return le(e)?e.value:e}const qr={get:(e,t,s)=>t==="__v_raw"?e:Gr(Reflect.get(e,t,s)),set:(e,t,s,n)=>{const i=e[t];return le(i)&&!le(s)?(i.value=s,!0):Reflect.set(e,t,s,n)}};function Ti(e){return Ut(e)?e:new Proxy(e,qr)}class Jr{constructor(t,s,n){this.fn=t,this.setter=s,this._value=void 0,this.dep=new nn(this),this.__v_isRef=!0,this.deps=void 0,this.depsTail=void 0,this.flags=16,this.globalVersion=jt-1,this.effect=this,this.__v_isReadonly=!s,this.isSSR=n}notify(){if(this.flags|=16,!(this.flags&8)&&z!==this)return ci(this),!0}get value(){const t=this.dep.track();return pi(this),t&&(t.version=this.dep.version),this._value}set value(t){this.setter&&this.setter(t)}}function zr(e,t,s=!1){let n,i;return W(e)?n=e:(n=e.get,i=e.set),new Jr(n,i,s)}const ts={},us=new WeakMap;let ct;function Zr(e,t=!1,s=ct){if(s){let n=us.get(s);n||us.set(s,n=[]),n.push(e)}}function Qr(e,t,s=Z){const{immediate:n,deep:i,once:r,scheduler:o,augmentJob:l,call:u}=s,p=E=>i?E:Ee(E)||i===!1||i===0?Xe(E,1):Xe(E);let c,m,g,y,P=!1,b=!1;if(le(e)?(m=()=>e.value,P=Ee(e)):Ut(e)?(m=()=>p(e),P=!0):U(e)?(b=!0,P=e.some(E=>Ut(E)||Ee(E)),m=()=>e.map(E=>{if(le(E))return E.value;if(Ut(E))return p(E);if(W(E))return u?u(E,2):E()})):W(e)?t?m=u?()=>u(e,2):e:m=()=>{if(g){nt();try{g()}finally{it()}}const E=ct;ct=c;try{return u?u(e,3,[y]):e(y)}finally{ct=E}}:m=He,t&&i){const E=m,N=i===!0?1/0:i;m=()=>Xe(E(),N)}const A=xr(),I=()=>{c.stop(),A&&Js(A.effects,c)};if(r&&t){const E=t;t=(...N)=>{E(...N),I()}}let F=b?new Array(e.length).fill(ts):ts;const V=E=>{if(!(!(c.flags&1)||!c.dirty&&!E))if(t){const N=c.run();if(i||P||(b?N.some((te,ee)=>st(te,F[ee])):st(N,F))){g&&g();const te=ct;ct=c;try{const ee=[N,F===ts?void 0:b&&F[0]===ts?[]:F,y];u?u(t,3,ee):t(...ee),F=N}finally{ct=te}}}else c.run()};return l&&l(V),c=new ui(m),c.scheduler=o?()=>o(V,!1):V,y=E=>Zr(E,!1,c),g=c.onStop=()=>{const E=us.get(c);if(E){if(u)u(E,4);else for(const N of E)N();us.delete(c)}},t?n?V(!0):F=c.run():o?o(V.bind(null,!0),!0):c.run(),I.pause=c.pause.bind(c),I.resume=c.resume.bind(c),I.stop=I,I}function Xe(e,t=1/0,s){if(t<=0||!Q(e)||e.__v_skip||(s=s||new Set,s.has(e)))return e;if(s.add(e),t--,le(e))Xe(e.value,t,s);else if(U(e))for(let n=0;n{Xe(n,t,s)});else if(ti(e)){for(const n in e)Xe(e[n],t,s);for(const n of Object.getOwnPropertySymbols(e))Object.prototype.propertyIsEnumerable.call(e,n)&&Xe(e[n],t,s)}return e}/** +**/let we;class wr{constructor(t=!1){this.detached=t,this._active=!0,this.effects=[],this.cleanups=[],this._isPaused=!1,this.parent=we,!t&&we&&(this.index=(we.scopes||(we.scopes=[])).push(this)-1)}get active(){return this._active}pause(){if(this._active){this._isPaused=!0;let t,s;if(this.scopes)for(t=0,s=this.scopes.length;t0)return;let e;for(;Dt;){let t=Dt;for(Dt=void 0;t;){const s=t.next;if(t.next=void 0,t.flags&=-9,t.flags&1)try{t.trigger()}catch(n){e||(e=n)}t=s}}if(e)throw e}function di(e){for(let t=e.deps;t;t=t.nextDep)t.version=-1,t.prevActiveLink=t.dep.activeLink,t.dep.activeLink=t}function hi(e,t=!1){let s,n=e.depsTail,i=n;for(;i;){const r=i.prevDep;i.version===-1?(i===n&&(n=r),sn(i,t),Sr(i)):s=i,i.dep.activeLink=i.prevActiveLink,i.prevActiveLink=void 0,i=r}e.deps=s,e.depsTail=n}function Ws(e){for(let t=e.deps;t;t=t.nextDep)if(t.dep.version!==t.version||t.dep.computed&&(pi(t.dep.computed)||t.dep.version!==t.version))return!0;return!!e._dirty}function pi(e){if(e.flags&4&&!(e.flags&16)||(e.flags&=-17,e.globalVersion===jt))return;e.globalVersion=jt;const t=e.dep;if(e.flags|=2,t.version>0&&!e.isSSR&&e.deps&&!Ws(e)){e.flags&=-3;return}const s=z,n=_e;z=e,_e=!0;try{di(e);const i=e.fn(e._value);(t.version===0||st(i,e._value))&&(e._value=i,t.version++)}catch(i){throw t.version++,i}finally{z=s,_e=n,hi(e,!0),e.flags&=-3}}function sn(e,t=!1){const{dep:s,prevSub:n,nextSub:i}=e;if(n&&(n.nextSub=i,e.prevSub=void 0),i&&(i.prevSub=n,e.nextSub=void 0),s.subs===e&&(s.subs=n),!s.subs)if(s.computed){s.computed.flags&=-5;for(let r=s.computed.deps;r;r=r.nextDep)sn(r,!0)}else s.map&&!t&&(s.map.delete(s.key),s.map.size||as.delete(s.target))}function Sr(e){const{prevDep:t,nextDep:s}=e;t&&(t.nextDep=s,e.prevDep=void 0),s&&(s.prevDep=t,e.nextDep=void 0)}let _e=!0;const mi=[];function nt(){mi.push(_e),_e=!1}function it(){const e=mi.pop();_e=e===void 0?!0:e}function xn(e){const{cleanup:t}=e;if(e.cleanup=void 0,t){const s=z;z=void 0;try{t()}finally{z=s}}}let jt=0;class Tr{constructor(t,s){this.sub=t,this.dep=s,this.version=s.version,this.nextDep=this.prevDep=this.nextSub=this.prevSub=this.prevActiveLink=void 0}}class nn{constructor(t){this.computed=t,this.version=0,this.activeLink=void 0,this.subs=void 0,this.target=void 0,this.map=void 0,this.key=void 0}track(t){if(!z||!_e||z===this.computed)return;let s=this.activeLink;if(s===void 0||s.sub!==z)s=this.activeLink=new Tr(z,this),z.deps?(s.prevDep=z.depsTail,z.depsTail.nextDep=s,z.depsTail=s):z.deps=z.depsTail=s,z.flags&4&&gi(s);else if(s.version===-1&&(s.version=this.version,s.nextDep)){const n=s.nextDep;n.prevDep=s.prevDep,s.prevDep&&(s.prevDep.nextDep=n),s.prevDep=z.depsTail,s.nextDep=void 0,z.depsTail.nextDep=s,z.depsTail=s,z.deps===s&&(z.deps=n)}return s}trigger(t){this.version++,jt++,this.notify(t)}notify(t){en();try{for(let s=this.subs;s;s=s.prevSub)s.sub.notify()&&s.sub.dep.notify()}finally{tn()}}}function gi(e){const t=e.dep.computed;if(t&&!e.dep.subs){t.flags|=20;for(let n=t.deps;n;n=n.nextDep)gi(n)}const s=e.dep.subs;s!==e&&(e.prevSub=s,s&&(s.nextSub=e)),e.dep.subs=e}const as=new WeakMap,ht=Symbol(""),Hs=Symbol(""),$t=Symbol("");function ae(e,t,s){if(_e&&z){let n=as.get(e);n||as.set(e,n=new Map);let i=n.get(s);i||(n.set(s,i=new nn),i.target=e,i.map=n,i.key=s),i.track()}}function Ge(e,t,s,n,i,r){const o=as.get(e);if(!o){jt++;return}const l=u=>{u&&u.trigger()};if(en(),t==="clear")o.forEach(l);else{const u=U(e),p=u&&zs(s);if(u&&s==="length"){const c=Number(n);o.forEach((m,g)=>{(g==="length"||g===$t||!Ne(g)&&g>=c)&&l(m)})}else switch(s!==void 0&&l(o.get(s)),p&&l(o.get($t)),t){case"add":u?p&&l(o.get("length")):(l(o.get(ht)),Pt(e)&&l(o.get(Hs)));break;case"delete":u||(l(o.get(ht)),Pt(e)&&l(o.get(Hs)));break;case"set":Pt(e)&&l(o.get(ht));break}}tn()}function Ct(e){const t=q(e);return t===e?t:(ae(t,"iterate",$t),Ee(e)?t:t.map(ce))}function rn(e){return ae(e=q(e),"iterate",$t),e}const Pr={__proto__:null,[Symbol.iterator](){return Es(this,Symbol.iterator,ce)},concat(...e){return Ct(this).concat(...e.map(t=>U(t)?Ct(t):t))},entries(){return Es(this,"entries",e=>(e[1]=ce(e[1]),e))},every(e,t){return ke(this,"every",e,t,void 0,arguments)},filter(e,t){return ke(this,"filter",e,t,s=>s.map(ce),arguments)},find(e,t){return ke(this,"find",e,t,ce,arguments)},findIndex(e,t){return ke(this,"findIndex",e,t,void 0,arguments)},findLast(e,t){return ke(this,"findLast",e,t,ce,arguments)},findLastIndex(e,t){return ke(this,"findLastIndex",e,t,void 0,arguments)},forEach(e,t){return ke(this,"forEach",e,t,void 0,arguments)},includes(...e){return Rs(this,"includes",e)},indexOf(...e){return Rs(this,"indexOf",e)},join(e){return Ct(this).join(e)},lastIndexOf(...e){return Rs(this,"lastIndexOf",e)},map(e,t){return ke(this,"map",e,t,void 0,arguments)},pop(){return At(this,"pop")},push(...e){return At(this,"push",e)},reduce(e,...t){return Sn(this,"reduce",e,t)},reduceRight(e,...t){return Sn(this,"reduceRight",e,t)},shift(){return At(this,"shift")},some(e,t){return ke(this,"some",e,t,void 0,arguments)},splice(...e){return At(this,"splice",e)},toReversed(){return Ct(this).toReversed()},toSorted(e){return Ct(this).toSorted(e)},toSpliced(...e){return Ct(this).toSpliced(...e)},unshift(...e){return At(this,"unshift",e)},values(){return Es(this,"values",ce)}};function Es(e,t,s){const n=rn(e),i=n[t]();return n!==e&&!Ee(e)&&(i._next=i.next,i.next=()=>{const r=i._next();return r.value&&(r.value=s(r.value)),r}),i}const Mr=Array.prototype;function ke(e,t,s,n,i,r){const o=rn(e),l=o!==e&&!Ee(e),u=o[t];if(u!==Mr[t]){const m=u.apply(e,r);return l?ce(m):m}let p=s;o!==e&&(l?p=function(m,g){return s.call(this,ce(m),g,e)}:s.length>2&&(p=function(m,g){return s.call(this,m,g,e)}));const c=u.call(o,p,n);return l&&i?i(c):c}function Sn(e,t,s,n){const i=rn(e);let r=s;return i!==e&&(Ee(e)?s.length>3&&(r=function(o,l,u){return s.call(this,o,l,u,e)}):r=function(o,l,u){return s.call(this,o,ce(l),u,e)}),i[t](r,...n)}function Rs(e,t,s){const n=q(e);ae(n,"iterate",$t);const i=n[t](...s);return(i===-1||i===!1)&&fn(s[0])?(s[0]=q(s[0]),n[t](...s)):i}function At(e,t,s=[]){nt(),en();const n=q(e)[t].apply(e,s);return tn(),it(),n}const _r=Gs("__proto__,__v_isRef,__isVue"),vi=new Set(Object.getOwnPropertyNames(Symbol).filter(e=>e!=="arguments"&&e!=="caller").map(e=>Symbol[e]).filter(Ne));function Er(e){Ne(e)||(e=String(e));const t=q(this);return ae(t,"has",e),t.hasOwnProperty(e)}class bi{constructor(t=!1,s=!1){this._isReadonly=t,this._isShallow=s}get(t,s,n){const i=this._isReadonly,r=this._isShallow;if(s==="__v_isReactive")return!i;if(s==="__v_isReadonly")return i;if(s==="__v_isShallow")return r;if(s==="__v_raw")return n===(i?r?jr:xi:r?wi:Ci).get(t)||Object.getPrototypeOf(t)===Object.getPrototypeOf(n)?t:void 0;const o=U(t);if(!i){let u;if(o&&(u=Pr[s]))return u;if(s==="hasOwnProperty")return Er}const l=Reflect.get(t,s,le(t)?t:n);return(Ne(s)?vi.has(s):_r(s))||(i||ae(t,"get",s),r)?l:le(l)?o&&zs(s)?l:l.value:Q(l)?i?Si(l):an(l):l}}class yi extends bi{constructor(t=!1){super(!1,t)}set(t,s,n,i){let r=t[s];if(!this._isShallow){const u=mt(r);if(!Ee(n)&&!mt(n)&&(r=q(r),n=q(n)),!U(t)&&le(r)&&!le(n))return u?!1:(r.value=n,!0)}const o=U(t)&&zs(s)?Number(s)e,bs=e=>Reflect.getPrototypeOf(e);function Jt(e,t,s=!1,n=!1){e=e.__v_raw;const i=q(e),r=q(t);s||(st(t,r)&&ae(i,"get",t),ae(i,"get",r));const{has:o}=bs(i),l=n?on:s?cn:ce;if(o.call(i,t))return l(e.get(t));if(o.call(i,r))return l(e.get(r));e!==i&&e.get(t)}function zt(e,t=!1){const s=this.__v_raw,n=q(s),i=q(e);return t||(st(e,i)&&ae(n,"has",e),ae(n,"has",i)),e===i?s.has(e):s.has(e)||s.has(i)}function Zt(e,t=!1){return e=e.__v_raw,!t&&ae(q(e),"iterate",ht),Reflect.get(e,"size",e)}function Tn(e,t=!1){!t&&!Ee(e)&&!mt(e)&&(e=q(e));const s=q(this);return bs(s).has.call(s,e)||(s.add(e),Ge(s,"add",e,e)),this}function Pn(e,t,s=!1){!s&&!Ee(t)&&!mt(t)&&(t=q(t));const n=q(this),{has:i,get:r}=bs(n);let o=i.call(n,e);o||(e=q(e),o=i.call(n,e));const l=r.call(n,e);return n.set(e,t),o?st(t,l)&&Ge(n,"set",e,t):Ge(n,"add",e,t),this}function Mn(e){const t=q(this),{has:s,get:n}=bs(t);let i=s.call(t,e);i||(e=q(e),i=s.call(t,e)),n&&n.call(t,e);const r=t.delete(e);return i&&Ge(t,"delete",e,void 0),r}function _n(){const e=q(this),t=e.size!==0,s=e.clear();return t&&Ge(e,"clear",void 0,void 0),s}function Qt(e,t){return function(n,i){const r=this,o=r.__v_raw,l=q(o),u=t?on:e?cn:ce;return!e&&ae(l,"iterate",ht),o.forEach((p,c)=>n.call(i,u(p),u(c),r))}}function es(e,t,s){return function(...n){const i=this.__v_raw,r=q(i),o=Pt(r),l=e==="entries"||e===Symbol.iterator&&o,u=e==="keys"&&o,p=i[e](...n),c=s?on:t?cn:ce;return!t&&ae(r,"iterate",u?Hs:ht),{next(){const{value:m,done:g}=p.next();return g?{value:m,done:g}:{value:l?[c(m[0]),c(m[1])]:c(m),done:g}},[Symbol.iterator](){return this}}}}function Ze(e){return function(...t){return e==="delete"?!1:e==="clear"?void 0:this}}function Fr(){const e={get(r){return Jt(this,r)},get size(){return Zt(this)},has:zt,add:Tn,set:Pn,delete:Mn,clear:_n,forEach:Qt(!1,!1)},t={get(r){return Jt(this,r,!1,!0)},get size(){return Zt(this)},has:zt,add(r){return Tn.call(this,r,!0)},set(r,o){return Pn.call(this,r,o,!0)},delete:Mn,clear:_n,forEach:Qt(!1,!0)},s={get(r){return Jt(this,r,!0)},get size(){return Zt(this,!0)},has(r){return zt.call(this,r,!0)},add:Ze("add"),set:Ze("set"),delete:Ze("delete"),clear:Ze("clear"),forEach:Qt(!0,!1)},n={get(r){return Jt(this,r,!0,!0)},get size(){return Zt(this,!0)},has(r){return zt.call(this,r,!0)},add:Ze("add"),set:Ze("set"),delete:Ze("delete"),clear:Ze("clear"),forEach:Qt(!0,!0)};return["keys","values","entries",Symbol.iterator].forEach(r=>{e[r]=es(r,!1,!1),s[r]=es(r,!0,!1),t[r]=es(r,!1,!0),n[r]=es(r,!0,!0)}),[e,s,t,n]}const[Lr,Vr,Dr,Ur]=Fr();function ln(e,t){const s=t?e?Ur:Dr:e?Vr:Lr;return(n,i,r)=>i==="__v_isReactive"?!e:i==="__v_isReadonly"?e:i==="__v_raw"?n:Reflect.get(G(s,i)&&i in n?s:n,i,r)}const Wr={get:ln(!1,!1)},Hr={get:ln(!1,!0)},Nr={get:ln(!0,!1)};const Ci=new WeakMap,wi=new WeakMap,xi=new WeakMap,jr=new WeakMap;function $r(e){switch(e){case"Object":case"Array":return 1;case"Map":case"Set":case"WeakMap":case"WeakSet":return 2;default:return 0}}function Br(e){return e.__v_skip||!Object.isExtensible(e)?0:$r(cr(e))}function an(e){return mt(e)?e:un(e,!1,Or,Wr,Ci)}function kr(e){return un(e,!1,Ar,Hr,wi)}function Si(e){return un(e,!0,Ir,Nr,xi)}function un(e,t,s,n,i){if(!Q(e)||e.__v_raw&&!(t&&e.__v_isReactive))return e;const r=i.get(e);if(r)return r;const o=Br(e);if(o===0)return e;const l=new Proxy(e,o===2?n:s);return i.set(e,l),l}function Ut(e){return mt(e)?Ut(e.__v_raw):!!(e&&e.__v_isReactive)}function mt(e){return!!(e&&e.__v_isReadonly)}function Ee(e){return!!(e&&e.__v_isShallow)}function fn(e){return e?!!e.__v_raw:!1}function q(e){const t=e&&e.__v_raw;return t?q(t):e}function Yr(e){return!G(e,"__v_skip")&&Object.isExtensible(e)&&ni(e,"__v_skip",!0),e}const ce=e=>Q(e)?an(e):e,cn=e=>Q(e)?Si(e):e;function le(e){return e?e.__v_isRef===!0:!1}function D(e){return Kr(e,!1)}function Kr(e,t){return le(e)?e:new Xr(e,t)}class Xr{constructor(t,s){this.dep=new nn,this.__v_isRef=!0,this.__v_isShallow=!1,this._rawValue=s?t:q(t),this._value=s?t:ce(t),this.__v_isShallow=s}get value(){return this.dep.track(),this._value}set value(t){const s=this._rawValue,n=this.__v_isShallow||Ee(t)||mt(t);t=n?t:q(t),st(t,s)&&(this._rawValue=t,this._value=n?t:ce(t),this.dep.trigger())}}function Gr(e){return le(e)?e.value:e}const qr={get:(e,t,s)=>t==="__v_raw"?e:Gr(Reflect.get(e,t,s)),set:(e,t,s,n)=>{const i=e[t];return le(i)&&!le(s)?(i.value=s,!0):Reflect.set(e,t,s,n)}};function Ti(e){return Ut(e)?e:new Proxy(e,qr)}class Jr{constructor(t,s,n){this.fn=t,this.setter=s,this._value=void 0,this.dep=new nn(this),this.__v_isRef=!0,this.deps=void 0,this.depsTail=void 0,this.flags=16,this.globalVersion=jt-1,this.effect=this,this.__v_isReadonly=!s,this.isSSR=n}notify(){if(this.flags|=16,!(this.flags&8)&&z!==this)return ci(this),!0}get value(){const t=this.dep.track();return pi(this),t&&(t.version=this.dep.version),this._value}set value(t){this.setter&&this.setter(t)}}function zr(e,t,s=!1){let n,i;return H(e)?n=e:(n=e.get,i=e.set),new Jr(n,i,s)}const ts={},us=new WeakMap;let ct;function Zr(e,t=!1,s=ct){if(s){let n=us.get(s);n||us.set(s,n=[]),n.push(e)}}function Qr(e,t,s=Z){const{immediate:n,deep:i,once:r,scheduler:o,augmentJob:l,call:u}=s,p=E=>i?E:Ee(E)||i===!1||i===0?Xe(E,1):Xe(E);let c,m,g,y,P=!1,b=!1;if(le(e)?(m=()=>e.value,P=Ee(e)):Ut(e)?(m=()=>p(e),P=!0):U(e)?(b=!0,P=e.some(E=>Ut(E)||Ee(E)),m=()=>e.map(E=>{if(le(E))return E.value;if(Ut(E))return p(E);if(H(E))return u?u(E,2):E()})):H(e)?t?m=u?()=>u(e,2):e:m=()=>{if(g){nt();try{g()}finally{it()}}const E=ct;ct=c;try{return u?u(e,3,[y]):e(y)}finally{ct=E}}:m=He,t&&i){const E=m,j=i===!0?1/0:i;m=()=>Xe(E(),j)}const A=xr(),I=()=>{c.stop(),A&&Js(A.effects,c)};if(r&&t){const E=t;t=(...j)=>{E(...j),I()}}let F=b?new Array(e.length).fill(ts):ts;const V=E=>{if(!(!(c.flags&1)||!c.dirty&&!E))if(t){const j=c.run();if(i||P||(b?j.some((te,ee)=>st(te,F[ee])):st(j,F))){g&&g();const te=ct;ct=c;try{const ee=[j,F===ts?void 0:b&&F[0]===ts?[]:F,y];u?u(t,3,ee):t(...ee),F=j}finally{ct=te}}}else c.run()};return l&&l(V),c=new ui(m),c.scheduler=o?()=>o(V,!1):V,y=E=>Zr(E,!1,c),g=c.onStop=()=>{const E=us.get(c);if(E){if(u)u(E,4);else for(const j of E)j();us.delete(c)}},t?n?V(!0):F=c.run():o?o(V.bind(null,!0),!0):c.run(),I.pause=c.pause.bind(c),I.resume=c.resume.bind(c),I.stop=I,I}function Xe(e,t=1/0,s){if(t<=0||!Q(e)||e.__v_skip||(s=s||new Set,s.has(e)))return e;if(s.add(e),t--,le(e))Xe(e.value,t,s);else if(U(e))for(let n=0;n{Xe(n,t,s)});else if(ti(e)){for(const n in e)Xe(e[n],t,s);for(const n of Object.getOwnPropertySymbols(e))Object.prototype.propertyIsEnumerable.call(e,n)&&Xe(e[n],t,s)}return e}/** * @vue/runtime-core v3.5.8 * (c) 2018-present Yuxi (Evan) You and Vue contributors * @license MIT -**/function Xt(e,t,s,n){try{return n?e(...n):e()}catch(i){ys(i,t,s)}}function je(e,t,s,n){if(W(e)){const i=Xt(e,t,s,n);return i&&Qn(i)&&i.catch(r=>{ys(r,t,s)}),i}if(U(e)){const i=[];for(let r=0;r>>1,i=de[n],r=kt(i);r=kt(s)?de.push(e):de.splice(so(t),0,e),e.flags|=1,Mi()}}function Mi(){!Bt&&!Ns&&(Ns=!0,dn=Pi.then(Ei))}function no(e){U(e)?Mt.push(...e):et&&e.id===-1?et.splice(xt+1,0,e):e.flags&1||(Mt.push(e),e.flags|=1),Mi()}function En(e,t,s=Bt?Ue+1:0){for(;skt(s)-kt(n));if(Mt.length=0,et){et.push(...t);return}for(et=t,xt=0;xte.id==null?e.flags&2?-1:1/0:e.id;function Ei(e){Ns=!1,Bt=!0;try{for(Ue=0;Ue{n._d&&Dn(-1);const r=fs(t);let o;try{o=e(...i)}finally{fs(r),n._d&&Dn(1)}return o};return n._n=!0,n._c=!0,n._d=!0,n}function H(e,t){if(Se===null)return e;const s=Ts(Se),n=e.dirs||(e.dirs=[]);for(let i=0;ie.__isTeleport;function pn(e,t){e.shapeFlag&6&&e.component?(e.transition=t,pn(e.component.subTree,t)):e.shapeFlag&128?(e.ssContent.transition=t.clone(e.ssContent),e.ssFallback.transition=t.clone(e.ssFallback)):e.transition=t}/*! #__NO_SIDE_EFFECTS__ */function Oi(e,t){return W(e)?re({name:e.name},t,{setup:e}):e}function Ii(e){e.ids=[e.ids[0]+e.ids[2]+++"-",0,0]}function js(e,t,s,n,i=!1){if(U(e)){e.forEach((P,b)=>js(P,t&&(U(t)?t[b]:t),s,n,i));return}if(Wt(n)&&!i)return;const r=n.shapeFlag&4?Ts(n.component):n.el,o=i?null:r,{i:l,r:u}=e,p=t&&t.r,c=l.refs===Z?l.refs={}:l.refs,m=l.setupState,g=q(m),y=m===Z?()=>!1:P=>G(g,P);if(p!=null&&p!==u&&(se(p)?(c[p]=null,y(p)&&(m[p]=null)):le(p)&&(p.value=null)),W(u))Xt(u,l,12,[o,c]);else{const P=se(u),b=le(u);if(P||b){const A=()=>{if(e.f){const I=P?y(u)?m[u]:c[u]:u.value;i?U(I)&&Js(I,r):U(I)?I.includes(r)||I.push(r):P?(c[u]=[r],y(u)&&(m[u]=c[u])):(u.value=[r],e.k&&(c[e.k]=u.value))}else P?(c[u]=o,y(u)&&(m[u]=o)):b&&(u.value=o,e.k&&(c[e.k]=o))};o?(A.id=-1,Ce(A,s)):A()}}}const Wt=e=>!!e.type.__asyncLoader,Ai=e=>e.type.__isKeepAlive;function lo(e,t){Fi(e,"a",t)}function ao(e,t){Fi(e,"da",t)}function Fi(e,t,s=he){const n=e.__wdc||(e.__wdc=()=>{let i=s;for(;i;){if(i.isDeactivated)return;i=i.parent}return e()});if(Cs(t,n,s),s){let i=s.parent;for(;i&&i.parent;)Ai(i.parent.vnode)&&uo(n,t,s,i),i=i.parent}}function uo(e,t,s,n){const i=Cs(t,e,n,!0);Vi(()=>{Js(n[t],i)},s)}function Cs(e,t,s=he,n=!1){if(s){const i=s[e]||(s[e]=[]),r=t.__weh||(t.__weh=(...o)=>{nt();const l=Gt(s),u=je(t,s,e,o);return l(),it(),u});return n?i.unshift(r):i.push(r),r}}const Je=e=>(t,s=he)=>{(!Ss||e==="sp")&&Cs(e,(...n)=>t(...n),s)},fo=Je("bm"),Li=Je("m"),co=Je("bu"),ho=Je("u"),po=Je("bum"),Vi=Je("um"),mo=Je("sp"),go=Je("rtg"),vo=Je("rtc");function bo(e,t=he){Cs("ec",e,t)}const yo=Symbol.for("v-ndc"),$s=e=>e?sr(e)?Ts(e):$s(e.parent):null,Ht=re(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=>$s(e.parent),$root:e=>$s(e.root),$host:e=>e.ce,$emit:e=>e.emit,$options:e=>mn(e),$forceUpdate:e=>e.f||(e.f=()=>{hn(e.update)}),$nextTick:e=>e.n||(e.n=to.bind(e.proxy)),$watch:e=>jo.bind(e)}),Os=(e,t)=>e!==Z&&!e.__isScriptSetup&&G(e,t),Co={get({_:e},t){if(t==="__v_skip")return!0;const{ctx:s,setupState:n,data:i,props:r,accessCache:o,type:l,appContext:u}=e;let p;if(t[0]!=="$"){const y=o[t];if(y!==void 0)switch(y){case 1:return n[t];case 2:return i[t];case 4:return s[t];case 3:return r[t]}else{if(Os(n,t))return o[t]=1,n[t];if(i!==Z&&G(i,t))return o[t]=2,i[t];if((p=e.propsOptions[0])&&G(p,t))return o[t]=3,r[t];if(s!==Z&&G(s,t))return o[t]=4,s[t];Bs&&(o[t]=0)}}const c=Ht[t];let m,g;if(c)return t==="$attrs"&&ae(e.attrs,"get",""),c(e);if((m=l.__cssModules)&&(m=m[t]))return m;if(s!==Z&&G(s,t))return o[t]=4,s[t];if(g=u.config.globalProperties,G(g,t))return g[t]},set({_:e},t,s){const{data:n,setupState:i,ctx:r}=e;return Os(i,t)?(i[t]=s,!0):n!==Z&&G(n,t)?(n[t]=s,!0):G(e.props,t)||t[0]==="$"&&t.slice(1)in e?!1:(r[t]=s,!0)},has({_:{data:e,setupState:t,accessCache:s,ctx:n,appContext:i,propsOptions:r}},o){let l;return!!s[o]||e!==Z&&G(e,o)||Os(t,o)||(l=r[0])&&G(l,o)||G(n,o)||G(Ht,o)||G(i.config.globalProperties,o)},defineProperty(e,t,s){return s.get!=null?e._.accessCache[t]=0:G(s,"value")&&this.set(e,t,s.value,null),Reflect.defineProperty(e,t,s)}};function Rn(e){return U(e)?e.reduce((t,s)=>(t[s]=null,t),{}):e}let Bs=!0;function wo(e){const t=mn(e),s=e.proxy,n=e.ctx;Bs=!1,t.beforeCreate&&On(t.beforeCreate,e,"bc");const{data:i,computed:r,methods:o,watch:l,provide:u,inject:p,created:c,beforeMount:m,mounted:g,beforeUpdate:y,updated:P,activated:b,deactivated:A,beforeDestroy:I,beforeUnmount:F,destroyed:V,unmounted:E,render:N,renderTracked:te,renderTriggered:ee,errorCaptured:pe,serverPrefetch:Re,expose:me,inheritAttrs:Te,components:Oe,directives:$e,filters:Ot}=t;if(p&&xo(p,n,null),o)for(const J in o){const K=o[J];W(K)&&(n[J]=K.bind(s))}if(i){const J=i.call(s,s);Q(J)&&(e.data=an(J))}if(Bs=!0,r)for(const J in r){const K=r[J],ue=W(K)?K.bind(s,s):W(K.get)?K.get.bind(s,s):He,Pe=!W(K)&&W(K.set)?K.set.bind(s):He,ge=al({get:ue,set:Pe});Object.defineProperty(n,J,{enumerable:!0,configurable:!0,get:()=>ge.value,set:ie=>ge.value=ie})}if(l)for(const J in l)Di(l[J],n,s,J);if(u){const J=W(u)?u.call(s):u;Reflect.ownKeys(J).forEach(K=>{Eo(K,J[K])})}c&&On(c,e,"c");function ne(J,K){U(K)?K.forEach(ue=>J(ue.bind(s))):K&&J(K.bind(s))}if(ne(fo,m),ne(Li,g),ne(co,y),ne(ho,P),ne(lo,b),ne(ao,A),ne(bo,pe),ne(vo,te),ne(go,ee),ne(po,F),ne(Vi,E),ne(mo,Re),U(me))if(me.length){const J=e.exposed||(e.exposed={});me.forEach(K=>{Object.defineProperty(J,K,{get:()=>s[K],set:ue=>s[K]=ue})})}else e.exposed||(e.exposed={});N&&e.render===He&&(e.render=N),Te!=null&&(e.inheritAttrs=Te),Oe&&(e.components=Oe),$e&&(e.directives=$e),Re&&Ii(e)}function xo(e,t,s=He){U(e)&&(e=ks(e));for(const n in e){const i=e[n];let r;Q(i)?"default"in i?r=is(i.from||n,i.default,!0):r=is(i.from||n):r=is(i),le(r)?Object.defineProperty(t,n,{enumerable:!0,configurable:!0,get:()=>r.value,set:o=>r.value=o}):t[n]=r}}function On(e,t,s){je(U(e)?e.map(n=>n.bind(t.proxy)):e.bind(t.proxy),t,s)}function Di(e,t,s,n){let i=n.includes(".")?Ji(s,n):()=>s[n];if(se(e)){const r=t[e];W(r)&&rs(i,r)}else if(W(e))rs(i,e.bind(s));else if(Q(e))if(U(e))e.forEach(r=>Di(r,t,s,n));else{const r=W(e.handler)?e.handler.bind(s):t[e.handler];W(r)&&rs(i,r,e)}}function mn(e){const t=e.type,{mixins:s,extends:n}=t,{mixins:i,optionsCache:r,config:{optionMergeStrategies:o}}=e.appContext,l=r.get(t);let u;return l?u=l:!i.length&&!s&&!n?u=t:(u={},i.length&&i.forEach(p=>cs(u,p,o,!0)),cs(u,t,o)),Q(t)&&r.set(t,u),u}function cs(e,t,s,n=!1){const{mixins:i,extends:r}=t;r&&cs(e,r,s,!0),i&&i.forEach(o=>cs(e,o,s,!0));for(const o in t)if(!(n&&o==="expose")){const l=So[o]||s&&s[o];e[o]=l?l(e[o],t[o]):t[o]}return e}const So={data:In,props:An,emits:An,methods:Lt,computed:Lt,beforeCreate:fe,created:fe,beforeMount:fe,mounted:fe,beforeUpdate:fe,updated:fe,beforeDestroy:fe,beforeUnmount:fe,destroyed:fe,unmounted:fe,activated:fe,deactivated:fe,errorCaptured:fe,serverPrefetch:fe,components:Lt,directives:Lt,watch:Po,provide:In,inject:To};function In(e,t){return t?e?function(){return re(W(e)?e.call(this,this):e,W(t)?t.call(this,this):t)}:t:e}function To(e,t){return Lt(ks(e),ks(t))}function ks(e){if(U(e)){const t={};for(let s=0;s1)return s&&W(t)?t.call(n&&n.proxy):t}}const Wi={},Hi=()=>Object.create(Wi),Ni=e=>Object.getPrototypeOf(e)===Wi;function Ro(e,t,s,n=!1){const i={},r=Hi();e.propsDefaults=Object.create(null),ji(e,t,i,r);for(const o in e.propsOptions[0])o in i||(i[o]=void 0);s?e.props=n?i:kr(i):e.type.props?e.props=i:e.props=r,e.attrs=r}function Oo(e,t,s,n){const{props:i,attrs:r,vnode:{patchFlag:o}}=e,l=q(i),[u]=e.propsOptions;let p=!1;if((n||o>0)&&!(o&16)){if(o&8){const c=e.vnode.dynamicProps;for(let m=0;m{u=!0;const[g,y]=$i(m,t,!0);re(o,g),y&&l.push(...y)};!s&&t.mixins.length&&t.mixins.forEach(c),e.extends&&c(e.extends),e.mixins&&e.mixins.forEach(c)}if(!r&&!u)return Q(e)&&n.set(e,Tt),Tt;if(U(r))for(let c=0;ce[0]==="_"||e==="$stable",gn=e=>U(e)?e.map(We):[We(e)],Ao=(e,t,s)=>{if(t._n)return t;const n=io((...i)=>gn(t(...i)),s);return n._c=!1,n},ki=(e,t,s)=>{const n=e._ctx;for(const i in e){if(Bi(i))continue;const r=e[i];if(W(r))t[i]=Ao(i,r,n);else if(r!=null){const o=gn(r);t[i]=()=>o}}},Yi=(e,t)=>{const s=gn(t);e.slots.default=()=>s},Ki=(e,t,s)=>{for(const n in t)(s||n!=="_")&&(e[n]=t[n])},Fo=(e,t,s)=>{const n=e.slots=Hi();if(e.vnode.shapeFlag&32){const i=t._;i?(Ki(n,t,s),s&&ni(n,"_",i,!0)):ki(t,n)}else t&&Yi(e,t)},Lo=(e,t,s)=>{const{vnode:n,slots:i}=e;let r=!0,o=Z;if(n.shapeFlag&32){const l=t._;l?s&&l===1?r=!1:Ki(i,t,s):(r=!t.$stable,ki(t,i)),o=t}else t&&(Yi(e,t),o={default:1});if(r)for(const l in i)!Bi(l)&&o[l]==null&&delete i[l]},Ce=Go;function Vo(e){return Do(e)}function Do(e,t){const s=ii();s.__VUE__=!0;const{insert:n,remove:i,patchProp:r,createElement:o,createText:l,createComment:u,setText:p,setElementText:c,parentNode:m,nextSibling:g,setScopeId:y=He,insertStaticContent:P}=e,b=(f,h,v,T=null,x=null,S=null,_=void 0,w=null,a=!!h.dynamicChildren)=>{if(f===h)return;f&&!Ft(f,h)&&(T=Be(f),ie(f,x,S,!0),f=null),h.patchFlag===-2&&(a=!1,h.dynamicChildren=null);const{type:d,ref:R,shapeFlag:M}=h;switch(d){case xs:A(f,h,v,T);break;case gt:I(f,h,v,T);break;case Fs:f==null&&F(h,v,T,_);break;case Ke:Oe(f,h,v,T,x,S,_,w,a);break;default:M&1?N(f,h,v,T,x,S,_,w,a):M&6?$e(f,h,v,T,x,S,_,w,a):(M&64||M&128)&&d.process(f,h,v,T,x,S,_,w,a,Ae)}R!=null&&x&&js(R,f&&f.ref,S,h||f,!h)},A=(f,h,v,T)=>{if(f==null)n(h.el=l(h.children),v,T);else{const x=h.el=f.el;h.children!==f.children&&p(x,h.children)}},I=(f,h,v,T)=>{f==null?n(h.el=u(h.children||""),v,T):h.el=f.el},F=(f,h,v,T)=>{[f.el,f.anchor]=P(f.children,h,v,T,f.el,f.anchor)},V=({el:f,anchor:h},v,T)=>{let x;for(;f&&f!==h;)x=g(f),n(f,v,T),f=x;n(h,v,T)},E=({el:f,anchor:h})=>{let v;for(;f&&f!==h;)v=g(f),i(f),f=v;i(h)},N=(f,h,v,T,x,S,_,w,a)=>{h.type==="svg"?_="svg":h.type==="math"&&(_="mathml"),f==null?te(h,v,T,x,S,_,w,a):Re(f,h,x,S,_,w,a)},te=(f,h,v,T,x,S,_,w)=>{let a,d;const{props:R,shapeFlag:M,transition:O,dirs:L}=f;if(a=f.el=o(f.type,S,R&&R.is,R),M&8?c(a,f.children):M&16&&pe(f.children,a,null,T,x,Is(f,S),_,w),L&&ut(f,null,T,"created"),ee(a,f,f.scopeId,_,T),R){for(const X in R)X!=="value"&&!Vt(X)&&r(a,X,null,R[X],S,T);"value"in R&&r(a,"value",null,R.value,S),(d=R.onVnodeBeforeMount)&&Le(d,T,f)}L&&ut(f,null,T,"beforeMount");const j=Uo(x,O);j&&O.beforeEnter(a),n(a,h,v),((d=R&&R.onVnodeMounted)||j||L)&&Ce(()=>{d&&Le(d,T,f),j&&O.enter(a),L&&ut(f,null,T,"mounted")},x)},ee=(f,h,v,T,x)=>{if(v&&y(f,v),T)for(let S=0;S{for(let d=a;d{const w=h.el=f.el;let{patchFlag:a,dynamicChildren:d,dirs:R}=h;a|=f.patchFlag&16;const M=f.props||Z,O=h.props||Z;let L;if(v&&ft(v,!1),(L=O.onVnodeBeforeUpdate)&&Le(L,v,h,f),R&&ut(h,f,v,"beforeUpdate"),v&&ft(v,!0),(M.innerHTML&&O.innerHTML==null||M.textContent&&O.textContent==null)&&c(w,""),d?me(f.dynamicChildren,d,w,v,T,Is(h,x),S):_||K(f,h,w,null,v,T,Is(h,x),S,!1),a>0){if(a&16)Te(w,M,O,v,x);else if(a&2&&M.class!==O.class&&r(w,"class",null,O.class,x),a&4&&r(w,"style",M.style,O.style,x),a&8){const j=h.dynamicProps;for(let X=0;X{L&&Le(L,v,h,f),R&&ut(h,f,v,"updated")},T)},me=(f,h,v,T,x,S,_)=>{for(let w=0;w{if(h!==v){if(h!==Z)for(const S in h)!Vt(S)&&!(S in v)&&r(f,S,h[S],null,x,T);for(const S in v){if(Vt(S))continue;const _=v[S],w=h[S];_!==w&&S!=="value"&&r(f,S,w,_,x,T)}"value"in v&&r(f,"value",h.value,v.value,x)}},Oe=(f,h,v,T,x,S,_,w,a)=>{const d=h.el=f?f.el:l(""),R=h.anchor=f?f.anchor:l("");let{patchFlag:M,dynamicChildren:O,slotScopeIds:L}=h;L&&(w=w?w.concat(L):L),f==null?(n(d,v,T),n(R,v,T),pe(h.children||[],v,R,x,S,_,w,a)):M>0&&M&64&&O&&f.dynamicChildren?(me(f.dynamicChildren,O,v,x,S,_,w),(h.key!=null||x&&h===x.subTree)&&Xi(f,h,!0)):K(f,h,v,R,x,S,_,w,a)},$e=(f,h,v,T,x,S,_,w,a)=>{h.slotScopeIds=w,f==null?h.shapeFlag&512?x.ctx.activate(h,v,T,_,a):Ot(h,v,T,x,S,_,a):rt(f,h,a)},Ot=(f,h,v,T,x,S,_)=>{const w=f.component=sl(f,T,x);if(Ai(f)&&(w.ctx.renderer=Ae),nl(w,!1,_),w.asyncDep){if(x&&x.registerDep(w,ne,_),!f.el){const a=w.subTree=qe(gt);I(null,a,h,v)}}else ne(w,f,h,v,x,S,_)},rt=(f,h,v)=>{const T=h.component=f.component;if(Ko(f,h,v))if(T.asyncDep&&!T.asyncResolved){J(T,h,v);return}else T.next=h,T.update();else h.el=f.el,T.vnode=h},ne=(f,h,v,T,x,S,_)=>{const w=()=>{if(f.isMounted){let{next:M,bu:O,u:L,parent:j,vnode:X}=f;{const be=Gi(f);if(be){M&&(M.el=X.el,J(f,M,_)),be.asyncDep.then(()=>{f.isUnmounted||w()});return}}let B=M,ve;ft(f,!1),M?(M.el=X.el,J(f,M,_)):M=X,O&&ns(O),(ve=M.props&&M.props.onVnodeBeforeUpdate)&&Le(ve,j,M,X),ft(f,!0);const oe=As(f),Me=f.subTree;f.subTree=oe,b(Me,oe,m(Me.el),Be(Me),f,x,S),M.el=oe.el,B===null&&Xo(f,oe.el),L&&Ce(L,x),(ve=M.props&&M.props.onVnodeUpdated)&&Ce(()=>Le(ve,j,M,X),x)}else{let M;const{el:O,props:L}=h,{bm:j,m:X,parent:B,root:ve,type:oe}=f,Me=Wt(h);if(ft(f,!1),j&&ns(j),!Me&&(M=L&&L.onVnodeBeforeMount)&&Le(M,B,h),ft(f,!0),O&&at){const be=()=>{f.subTree=As(f),at(O,f.subTree,f,x,null)};Me&&oe.__asyncHydrate?oe.__asyncHydrate(O,f,be):be()}else{ve.ce&&ve.ce._injectChildStyle(oe);const be=f.subTree=As(f);b(null,be,v,T,f,x,S),h.el=be.el}if(X&&Ce(X,x),!Me&&(M=L&&L.onVnodeMounted)){const be=h;Ce(()=>Le(M,B,be),x)}(h.shapeFlag&256||B&&Wt(B.vnode)&&B.vnode.shapeFlag&256)&&f.a&&Ce(f.a,x),f.isMounted=!0,h=v=T=null}};f.scope.on();const a=f.effect=new ui(w);f.scope.off();const d=f.update=a.run.bind(a),R=f.job=a.runIfDirty.bind(a);R.i=f,R.id=f.uid,a.scheduler=()=>hn(R),ft(f,!0),d()},J=(f,h,v)=>{h.component=f;const T=f.vnode.props;f.vnode=h,f.next=null,Oo(f,h.props,T,v),Lo(f,h.children,v),nt(),En(f),it()},K=(f,h,v,T,x,S,_,w,a=!1)=>{const d=f&&f.children,R=f?f.shapeFlag:0,M=h.children,{patchFlag:O,shapeFlag:L}=h;if(O>0){if(O&128){Pe(d,M,v,T,x,S,_,w,a);return}else if(O&256){ue(d,M,v,T,x,S,_,w,a);return}}L&8?(R&16&&Ie(d,x,S),M!==d&&c(v,M)):R&16?L&16?Pe(d,M,v,T,x,S,_,w,a):Ie(d,x,S,!0):(R&8&&c(v,""),L&16&&pe(M,v,T,x,S,_,w,a))},ue=(f,h,v,T,x,S,_,w,a)=>{f=f||Tt,h=h||Tt;const d=f.length,R=h.length,M=Math.min(d,R);let O;for(O=0;OR?Ie(f,x,S,!0,!1,M):pe(h,v,T,x,S,_,w,a,M)},Pe=(f,h,v,T,x,S,_,w,a)=>{let d=0;const R=h.length;let M=f.length-1,O=R-1;for(;d<=M&&d<=O;){const L=f[d],j=h[d]=a?tt(h[d]):We(h[d]);if(Ft(L,j))b(L,j,v,null,x,S,_,w,a);else break;d++}for(;d<=M&&d<=O;){const L=f[M],j=h[O]=a?tt(h[O]):We(h[O]);if(Ft(L,j))b(L,j,v,null,x,S,_,w,a);else break;M--,O--}if(d>M){if(d<=O){const L=O+1,j=LO)for(;d<=M;)ie(f[d],x,S,!0),d++;else{const L=d,j=d,X=new Map;for(d=j;d<=O;d++){const ye=h[d]=a?tt(h[d]):We(h[d]);ye.key!=null&&X.set(ye.key,d)}let B,ve=0;const oe=O-j+1;let Me=!1,be=0;const It=new Array(oe);for(d=0;d=oe){ie(ye,x,S,!0);continue}let Fe;if(ye.key!=null)Fe=X.get(ye.key);else for(B=j;B<=O;B++)if(It[B-j]===0&&Ft(ye,h[B])){Fe=B;break}Fe===void 0?ie(ye,x,S,!0):(It[Fe-j]=d+1,Fe>=be?be=Fe:Me=!0,b(ye,h[Fe],v,null,x,S,_,w,a),ve++)}const bn=Me?Wo(It):Tt;for(B=bn.length-1,d=oe-1;d>=0;d--){const ye=j+d,Fe=h[ye],yn=ye+1{const{el:S,type:_,transition:w,children:a,shapeFlag:d}=f;if(d&6){ge(f.component.subTree,h,v,T);return}if(d&128){f.suspense.move(h,v,T);return}if(d&64){_.move(f,h,v,Ae);return}if(_===Ke){n(S,h,v);for(let M=0;Mw.enter(S),x);else{const{leave:M,delayLeave:O,afterLeave:L}=w,j=()=>n(S,h,v),X=()=>{M(S,()=>{j(),L&&L()})};O?O(S,j,X):X()}else n(S,h,v)},ie=(f,h,v,T=!1,x=!1)=>{const{type:S,props:_,ref:w,children:a,dynamicChildren:d,shapeFlag:R,patchFlag:M,dirs:O,cacheIndex:L}=f;if(M===-2&&(x=!1),w!=null&&js(w,null,v,f,!0),L!=null&&(h.renderCache[L]=void 0),R&256){h.ctx.deactivate(f);return}const j=R&1&&O,X=!Wt(f);let B;if(X&&(B=_&&_.onVnodeBeforeUnmount)&&Le(B,h,f),R&6)yt(f.component,v,T);else{if(R&128){f.suspense.unmount(v,T);return}j&&ut(f,null,h,"beforeUnmount"),R&64?f.type.remove(f,h,v,Ae,T):d&&!d.hasOnce&&(S!==Ke||M>0&&M&64)?Ie(d,h,v,!1,!0):(S===Ke&&M&384||!x&&R&16)&&Ie(a,h,v),T&&ot(f)}(X&&(B=_&&_.onVnodeUnmounted)||j)&&Ce(()=>{B&&Le(B,h,f),j&&ut(f,null,h,"unmounted")},v)},ot=f=>{const{type:h,el:v,anchor:T,transition:x}=f;if(h===Ke){bt(v,T);return}if(h===Fs){E(f);return}const S=()=>{i(v),x&&!x.persisted&&x.afterLeave&&x.afterLeave()};if(f.shapeFlag&1&&x&&!x.persisted){const{leave:_,delayLeave:w}=x,a=()=>_(v,S);w?w(f.el,S,a):a()}else S()},bt=(f,h)=>{let v;for(;f!==h;)v=g(f),i(f),f=v;i(h)},yt=(f,h,v)=>{const{bum:T,scope:x,job:S,subTree:_,um:w,m:a,a:d}=f;Ln(a),Ln(d),T&&ns(T),x.stop(),S&&(S.flags|=8,ie(_,f,h,v)),w&&Ce(w,h),Ce(()=>{f.isUnmounted=!0},h),h&&h.pendingBranch&&!h.isUnmounted&&f.asyncDep&&!f.asyncResolved&&f.suspenseId===h.pendingId&&(h.deps--,h.deps===0&&h.resolve())},Ie=(f,h,v,T=!1,x=!1,S=0)=>{for(let _=S;_{if(f.shapeFlag&6)return Be(f.component.subTree);if(f.shapeFlag&128)return f.suspense.next();const h=g(f.anchor||f.el),v=h&&h[ro];return v?g(v):h};let ze=!1;const lt=(f,h,v)=>{f==null?h._vnode&&ie(h._vnode,null,null,!0):b(h._vnode||null,f,h,null,null,null,v),h._vnode=f,ze||(ze=!0,En(),_i(),ze=!1)},Ae={p:b,um:ie,m:ge,r:ot,mt:Ot,mc:pe,pc:K,pbc:me,n:Be,o:e};let qt,at;return{render:lt,hydrate:qt,createApp:_o(lt,qt)}}function Is({type:e,props:t},s){return s==="svg"&&e==="foreignObject"||s==="mathml"&&e==="annotation-xml"&&t&&t.encoding&&t.encoding.includes("html")?void 0:s}function ft({effect:e,job:t},s){s?(e.flags|=32,t.flags|=4):(e.flags&=-33,t.flags&=-5)}function Uo(e,t){return(!e||e&&!e.pendingBranch)&&t&&!t.persisted}function Xi(e,t,s=!1){const n=e.children,i=t.children;if(U(n)&&U(i))for(let r=0;r>1,e[s[l]]0&&(t[n]=s[r-1]),s[r]=n)}}for(r=s.length,o=s[r-1];r-- >0;)s[r]=o,o=t[o];return s}function Gi(e){const t=e.subTree.component;if(t)return t.asyncDep&&!t.asyncResolved?t:Gi(t)}function Ln(e){if(e)for(let t=0;tis(Ho);function rs(e,t,s){return qi(e,t,s)}function qi(e,t,s=Z){const{immediate:n,deep:i,flush:r,once:o}=s,l=re({},s);let u;if(Ss)if(r==="sync"){const g=No();u=g.__watcherHandles||(g.__watcherHandles=[])}else if(!t||n)l.once=!0;else{const g=()=>{};return g.stop=He,g.resume=He,g.pause=He,g}const p=he;l.call=(g,y,P)=>je(g,p,y,P);let c=!1;r==="post"?l.scheduler=g=>{Ce(g,p&&p.suspense)}:r!=="sync"&&(c=!0,l.scheduler=(g,y)=>{y?g():hn(g)}),l.augmentJob=g=>{t&&(g.flags|=4),c&&(g.flags|=2,p&&(g.id=p.uid,g.i=p))};const m=Qr(e,t,l);return u&&u.push(m),m}function jo(e,t,s){const n=this.proxy,i=se(e)?e.includes(".")?Ji(n,e):()=>n[e]:e.bind(n,n);let r;W(t)?r=t:(r=t.handler,s=t);const o=Gt(this),l=qi(i,r.bind(n),s);return o(),l}function Ji(e,t){const s=t.split(".");return()=>{let n=e;for(let i=0;it==="modelValue"||t==="model-value"?e.modelModifiers:e[`${t}Modifiers`]||e[`${pt(t)}Modifiers`]||e[`${vt(t)}Modifiers`];function Bo(e,t,...s){if(e.isUnmounted)return;const n=e.vnode.props||Z;let i=s;const r=t.startsWith("update:"),o=r&&$o(n,t.slice(7));o&&(o.trim&&(i=s.map(c=>se(c)?c.trim():c)),o.number&&(i=s.map(Us)));let l,u=n[l=Ps(t)]||n[l=Ps(pt(t))];!u&&r&&(u=n[l=Ps(vt(t))]),u&&je(u,e,6,i);const p=n[l+"Once"];if(p){if(!e.emitted)e.emitted={};else if(e.emitted[l])return;e.emitted[l]=!0,je(p,e,6,i)}}function zi(e,t,s=!1){const n=t.emitsCache,i=n.get(e);if(i!==void 0)return i;const r=e.emits;let o={},l=!1;if(!W(e)){const u=p=>{const c=zi(p,t,!0);c&&(l=!0,re(o,c))};!s&&t.mixins.length&&t.mixins.forEach(u),e.extends&&u(e.extends),e.mixins&&e.mixins.forEach(u)}return!r&&!l?(Q(e)&&n.set(e,null),null):(U(r)?r.forEach(u=>o[u]=null):re(o,r),Q(e)&&n.set(e,o),o)}function ws(e,t){return!e||!ps(t)?!1:(t=t.slice(2).replace(/Once$/,""),G(e,t[0].toLowerCase()+t.slice(1))||G(e,vt(t))||G(e,t))}function As(e){const{type:t,vnode:s,proxy:n,withProxy:i,propsOptions:[r],slots:o,attrs:l,emit:u,render:p,renderCache:c,props:m,data:g,setupState:y,ctx:P,inheritAttrs:b}=e,A=fs(e);let I,F;try{if(s.shapeFlag&4){const E=i||n,N=E;I=We(p.call(N,E,c,m,y,g,P)),F=l}else{const E=t;I=We(E.length>1?E(m,{attrs:l,slots:o,emit:u}):E(m,null)),F=t.props?l:ko(l)}}catch(E){Nt.length=0,ys(E,e,1),I=qe(gt)}let V=I;if(F&&b!==!1){const E=Object.keys(F),{shapeFlag:N}=V;E.length&&N&7&&(r&&E.some(qs)&&(F=Yo(F,r)),V=Rt(V,F,!1,!0))}return s.dirs&&(V=Rt(V,null,!1,!0),V.dirs=V.dirs?V.dirs.concat(s.dirs):s.dirs),s.transition&&pn(V,s.transition),I=V,fs(A),I}const ko=e=>{let t;for(const s in e)(s==="class"||s==="style"||ps(s))&&((t||(t={}))[s]=e[s]);return t},Yo=(e,t)=>{const s={};for(const n in e)(!qs(n)||!(n.slice(9)in t))&&(s[n]=e[n]);return s};function Ko(e,t,s){const{props:n,children:i,component:r}=e,{props:o,children:l,patchFlag:u}=t,p=r.emitsOptions;if(t.dirs||t.transition)return!0;if(s&&u>=0){if(u&1024)return!0;if(u&16)return n?Vn(n,o,p):!!o;if(u&8){const c=t.dynamicProps;for(let m=0;me.__isSuspense;function Go(e,t){t&&t.pendingBranch?U(e)?t.effects.push(...e):t.effects.push(e):no(e)}const Ke=Symbol.for("v-fgt"),xs=Symbol.for("v-txt"),gt=Symbol.for("v-cmt"),Fs=Symbol.for("v-stc"),Nt=[];let xe=null;function St(e=!1){Nt.push(xe=e?null:[])}function qo(){Nt.pop(),xe=Nt[Nt.length-1]||null}let Yt=1;function Dn(e){Yt+=e,e<0&&xe&&(xe.hasOnce=!0)}function Qi(e){return e.dynamicChildren=Yt>0?xe||Tt:null,qo(),Yt>0&&xe&&xe.push(e),e}function ss(e,t,s,n,i,r){return Qi(C(e,t,s,n,i,r,!0))}function er(e,t,s,n,i){return Qi(qe(e,t,s,n,i,!0))}function Jo(e){return e?e.__v_isVNode===!0:!1}function Ft(e,t){return e.type===t.type&&e.key===t.key}const tr=({key:e})=>e??null,os=({ref:e,ref_key:t,ref_for:s})=>(typeof e=="number"&&(e=""+e),e!=null?se(e)||le(e)||W(e)?{i:Se,r:e,k:t,f:!!s}:e:null);function C(e,t=null,s=null,n=0,i=null,r=e===Ke?0:1,o=!1,l=!1){const u={__v_isVNode:!0,__v_skip:!0,type:e,props:t,key:t&&tr(t),ref:t&&os(t),scopeId:Ri,slotScopeIds:null,children:s,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:n,dynamicProps:i,dynamicChildren:null,appContext:null,ctx:Se};return l?(vn(u,s),r&128&&e.normalize(u)):s&&(u.shapeFlag|=se(s)?8:16),Yt>0&&!o&&xe&&(u.patchFlag>0||r&6)&&u.patchFlag!==32&&xe.push(u),u}const qe=zo;function zo(e,t=null,s=null,n=0,i=null,r=!1){if((!e||e===yo)&&(e=gt),Jo(e)){const l=Rt(e,t,!0);return s&&vn(l,s),Yt>0&&!r&&xe&&(l.shapeFlag&6?xe[xe.indexOf(e)]=l:xe.push(l)),l.patchFlag=-2,l}if(ll(e)&&(e=e.__vccOpts),t){t=Zo(t);let{class:l,style:u}=t;l&&!se(l)&&(t.class=Qs(l)),Q(u)&&(fn(u)&&!U(u)&&(u=re({},u)),t.style=Zs(u))}const o=se(e)?1:Zi(e)?128:oo(e)?64:Q(e)?4:W(e)?2:0;return C(e,t,s,n,i,o,r,!0)}function Zo(e){return e?fn(e)||Ni(e)?re({},e):e:null}function Rt(e,t,s=!1,n=!1){const{props:i,ref:r,patchFlag:o,children:l,transition:u}=e,p=t?Qo(i||{},t):i,c={__v_isVNode:!0,__v_skip:!0,type:e.type,props:p,key:p&&tr(p),ref:t&&t.ref?s&&r?U(r)?r.concat(os(t)):[r,os(t)]:os(t):r,scopeId:e.scopeId,slotScopeIds:e.slotScopeIds,children:l,target:e.target,targetStart:e.targetStart,targetAnchor:e.targetAnchor,staticCount:e.staticCount,shapeFlag:e.shapeFlag,patchFlag:t&&e.type!==Ke?o===-1?16:o|16:o,dynamicProps:e.dynamicProps,dynamicChildren:e.dynamicChildren,appContext:e.appContext,dirs:e.dirs,transition:u,component:e.component,suspense:e.suspense,ssContent:e.ssContent&&Rt(e.ssContent),ssFallback:e.ssFallback&&Rt(e.ssFallback),el:e.el,anchor:e.anchor,ctx:e.ctx,ce:e.ce};return u&&n&&pn(c,u.clone(c)),c}function Y(e=" ",t=0){return qe(xs,null,e,t)}function Ls(e="",t=!1){return t?(St(),er(gt,null,e)):qe(gt,null,e)}function We(e){return e==null||typeof e=="boolean"?qe(gt):U(e)?qe(Ke,null,e.slice()):typeof e=="object"?tt(e):qe(xs,null,String(e))}function tt(e){return e.el===null&&e.patchFlag!==-1||e.memo?e:Rt(e)}function vn(e,t){let s=0;const{shapeFlag:n}=e;if(t==null)t=null;else if(U(t))s=16;else if(typeof t=="object")if(n&65){const i=t.default;i&&(i._c&&(i._d=!1),vn(e,i()),i._c&&(i._d=!0));return}else{s=32;const i=t._;!i&&!Ni(t)?t._ctx=Se:i===3&&Se&&(Se.slots._===1?t._=1:(t._=2,e.patchFlag|=1024))}else W(t)?(t={default:t,_ctx:Se},s=32):(t=String(t),n&64?(s=16,t=[Y(t)]):s=8);e.children=t,e.shapeFlag|=s}function Qo(...e){const t={};for(let s=0;s{let i;return(i=e[s])||(i=e[s]=[]),i.push(n),r=>{i.length>1?i.forEach(o=>o(r)):i[0](r)}};ds=t("__VUE_INSTANCE_SETTERS__",s=>he=s),Ks=t("__VUE_SSR_SETTERS__",s=>Ss=s)}const Gt=e=>{const t=he;return ds(e),e.scope.on(),()=>{e.scope.off(),ds(t)}},Un=()=>{he&&he.scope.off(),ds(null)};function sr(e){return e.vnode.shapeFlag&4}let Ss=!1;function nl(e,t=!1,s=!1){t&&Ks(t);const{props:n,children:i}=e.vnode,r=sr(e);Ro(e,n,r,t),Fo(e,i,s);const o=r?il(e,t):void 0;return t&&Ks(!1),o}function il(e,t){const s=e.type;e.accessCache=Object.create(null),e.proxy=new Proxy(e.ctx,Co);const{setup:n}=s;if(n){const i=e.setupContext=n.length>1?ol(e):null,r=Gt(e);nt();const o=Xt(n,e,0,[e.props,i]);if(it(),r(),Qn(o)){if(Wt(e)||Ii(e),o.then(Un,Un),t)return o.then(l=>{Wn(e,l,t)}).catch(l=>{ys(l,e,0)});e.asyncDep=o}else Wn(e,o,t)}else nr(e,t)}function Wn(e,t,s){W(t)?e.type.__ssrInlineRender?e.ssrRender=t:e.render=t:Q(t)&&(e.setupState=Ti(t)),nr(e,s)}let Hn;function nr(e,t,s){const n=e.type;if(!e.render){if(!t&&Hn&&!n.render){const i=n.template||mn(e).template;if(i){const{isCustomElement:r,compilerOptions:o}=e.appContext.config,{delimiters:l,compilerOptions:u}=n,p=re(re({isCustomElement:r,delimiters:l},o),u);n.render=Hn(i,p)}}e.render=n.render||He}{const i=Gt(e);nt();try{wo(e)}finally{it(),i()}}}const rl={get(e,t){return ae(e,"get",""),e[t]}};function ol(e){const t=s=>{e.exposed=s||{}};return{attrs:new Proxy(e.attrs,rl),slots:e.slots,emit:e.emit,expose:t}}function Ts(e){return e.exposed?e.exposeProxy||(e.exposeProxy=new Proxy(Ti(Yr(e.exposed)),{get(t,s){if(s in t)return t[s];if(s in Ht)return Ht[s](e)},has(t,s){return s in t||s in Ht}})):e.proxy}function ll(e){return W(e)&&"__vccOpts"in e}const al=(e,t)=>zr(e,t,Ss),ul="3.5.8";/** +**/function Xt(e,t,s,n){try{return n?e(...n):e()}catch(i){ys(i,t,s)}}function je(e,t,s,n){if(H(e)){const i=Xt(e,t,s,n);return i&&Qn(i)&&i.catch(r=>{ys(r,t,s)}),i}if(U(e)){const i=[];for(let r=0;r>>1,i=de[n],r=kt(i);r=kt(s)?de.push(e):de.splice(so(t),0,e),e.flags|=1,Mi()}}function Mi(){!Bt&&!Ns&&(Ns=!0,dn=Pi.then(Ei))}function no(e){U(e)?Mt.push(...e):et&&e.id===-1?et.splice(xt+1,0,e):e.flags&1||(Mt.push(e),e.flags|=1),Mi()}function En(e,t,s=Bt?Ue+1:0){for(;skt(s)-kt(n));if(Mt.length=0,et){et.push(...t);return}for(et=t,xt=0;xte.id==null?e.flags&2?-1:1/0:e.id;function Ei(e){Ns=!1,Bt=!0;try{for(Ue=0;Ue{n._d&&Dn(-1);const r=fs(t);let o;try{o=e(...i)}finally{fs(r),n._d&&Dn(1)}return o};return n._n=!0,n._c=!0,n._d=!0,n}function N(e,t){if(Se===null)return e;const s=Ts(Se),n=e.dirs||(e.dirs=[]);for(let i=0;ie.__isTeleport;function pn(e,t){e.shapeFlag&6&&e.component?(e.transition=t,pn(e.component.subTree,t)):e.shapeFlag&128?(e.ssContent.transition=t.clone(e.ssContent),e.ssFallback.transition=t.clone(e.ssFallback)):e.transition=t}/*! #__NO_SIDE_EFFECTS__ */function Oi(e,t){return H(e)?re({name:e.name},t,{setup:e}):e}function Ii(e){e.ids=[e.ids[0]+e.ids[2]+++"-",0,0]}function js(e,t,s,n,i=!1){if(U(e)){e.forEach((P,b)=>js(P,t&&(U(t)?t[b]:t),s,n,i));return}if(Wt(n)&&!i)return;const r=n.shapeFlag&4?Ts(n.component):n.el,o=i?null:r,{i:l,r:u}=e,p=t&&t.r,c=l.refs===Z?l.refs={}:l.refs,m=l.setupState,g=q(m),y=m===Z?()=>!1:P=>G(g,P);if(p!=null&&p!==u&&(se(p)?(c[p]=null,y(p)&&(m[p]=null)):le(p)&&(p.value=null)),H(u))Xt(u,l,12,[o,c]);else{const P=se(u),b=le(u);if(P||b){const A=()=>{if(e.f){const I=P?y(u)?m[u]:c[u]:u.value;i?U(I)&&Js(I,r):U(I)?I.includes(r)||I.push(r):P?(c[u]=[r],y(u)&&(m[u]=c[u])):(u.value=[r],e.k&&(c[e.k]=u.value))}else P?(c[u]=o,y(u)&&(m[u]=o)):b&&(u.value=o,e.k&&(c[e.k]=o))};o?(A.id=-1,Ce(A,s)):A()}}}const Wt=e=>!!e.type.__asyncLoader,Ai=e=>e.type.__isKeepAlive;function lo(e,t){Fi(e,"a",t)}function ao(e,t){Fi(e,"da",t)}function Fi(e,t,s=he){const n=e.__wdc||(e.__wdc=()=>{let i=s;for(;i;){if(i.isDeactivated)return;i=i.parent}return e()});if(Cs(t,n,s),s){let i=s.parent;for(;i&&i.parent;)Ai(i.parent.vnode)&&uo(n,t,s,i),i=i.parent}}function uo(e,t,s,n){const i=Cs(t,e,n,!0);Vi(()=>{Js(n[t],i)},s)}function Cs(e,t,s=he,n=!1){if(s){const i=s[e]||(s[e]=[]),r=t.__weh||(t.__weh=(...o)=>{nt();const l=Gt(s),u=je(t,s,e,o);return l(),it(),u});return n?i.unshift(r):i.push(r),r}}const Je=e=>(t,s=he)=>{(!Ss||e==="sp")&&Cs(e,(...n)=>t(...n),s)},fo=Je("bm"),Li=Je("m"),co=Je("bu"),ho=Je("u"),po=Je("bum"),Vi=Je("um"),mo=Je("sp"),go=Je("rtg"),vo=Je("rtc");function bo(e,t=he){Cs("ec",e,t)}const yo=Symbol.for("v-ndc"),$s=e=>e?sr(e)?Ts(e):$s(e.parent):null,Ht=re(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=>$s(e.parent),$root:e=>$s(e.root),$host:e=>e.ce,$emit:e=>e.emit,$options:e=>mn(e),$forceUpdate:e=>e.f||(e.f=()=>{hn(e.update)}),$nextTick:e=>e.n||(e.n=to.bind(e.proxy)),$watch:e=>jo.bind(e)}),Os=(e,t)=>e!==Z&&!e.__isScriptSetup&&G(e,t),Co={get({_:e},t){if(t==="__v_skip")return!0;const{ctx:s,setupState:n,data:i,props:r,accessCache:o,type:l,appContext:u}=e;let p;if(t[0]!=="$"){const y=o[t];if(y!==void 0)switch(y){case 1:return n[t];case 2:return i[t];case 4:return s[t];case 3:return r[t]}else{if(Os(n,t))return o[t]=1,n[t];if(i!==Z&&G(i,t))return o[t]=2,i[t];if((p=e.propsOptions[0])&&G(p,t))return o[t]=3,r[t];if(s!==Z&&G(s,t))return o[t]=4,s[t];Bs&&(o[t]=0)}}const c=Ht[t];let m,g;if(c)return t==="$attrs"&&ae(e.attrs,"get",""),c(e);if((m=l.__cssModules)&&(m=m[t]))return m;if(s!==Z&&G(s,t))return o[t]=4,s[t];if(g=u.config.globalProperties,G(g,t))return g[t]},set({_:e},t,s){const{data:n,setupState:i,ctx:r}=e;return Os(i,t)?(i[t]=s,!0):n!==Z&&G(n,t)?(n[t]=s,!0):G(e.props,t)||t[0]==="$"&&t.slice(1)in e?!1:(r[t]=s,!0)},has({_:{data:e,setupState:t,accessCache:s,ctx:n,appContext:i,propsOptions:r}},o){let l;return!!s[o]||e!==Z&&G(e,o)||Os(t,o)||(l=r[0])&&G(l,o)||G(n,o)||G(Ht,o)||G(i.config.globalProperties,o)},defineProperty(e,t,s){return s.get!=null?e._.accessCache[t]=0:G(s,"value")&&this.set(e,t,s.value,null),Reflect.defineProperty(e,t,s)}};function Rn(e){return U(e)?e.reduce((t,s)=>(t[s]=null,t),{}):e}let Bs=!0;function wo(e){const t=mn(e),s=e.proxy,n=e.ctx;Bs=!1,t.beforeCreate&&On(t.beforeCreate,e,"bc");const{data:i,computed:r,methods:o,watch:l,provide:u,inject:p,created:c,beforeMount:m,mounted:g,beforeUpdate:y,updated:P,activated:b,deactivated:A,beforeDestroy:I,beforeUnmount:F,destroyed:V,unmounted:E,render:j,renderTracked:te,renderTriggered:ee,errorCaptured:pe,serverPrefetch:Re,expose:me,inheritAttrs:Te,components:Oe,directives:$e,filters:Ot}=t;if(p&&xo(p,n,null),o)for(const J in o){const K=o[J];H(K)&&(n[J]=K.bind(s))}if(i){const J=i.call(s,s);Q(J)&&(e.data=an(J))}if(Bs=!0,r)for(const J in r){const K=r[J],ue=H(K)?K.bind(s,s):H(K.get)?K.get.bind(s,s):He,Pe=!H(K)&&H(K.set)?K.set.bind(s):He,ge=al({get:ue,set:Pe});Object.defineProperty(n,J,{enumerable:!0,configurable:!0,get:()=>ge.value,set:ie=>ge.value=ie})}if(l)for(const J in l)Di(l[J],n,s,J);if(u){const J=H(u)?u.call(s):u;Reflect.ownKeys(J).forEach(K=>{Eo(K,J[K])})}c&&On(c,e,"c");function ne(J,K){U(K)?K.forEach(ue=>J(ue.bind(s))):K&&J(K.bind(s))}if(ne(fo,m),ne(Li,g),ne(co,y),ne(ho,P),ne(lo,b),ne(ao,A),ne(bo,pe),ne(vo,te),ne(go,ee),ne(po,F),ne(Vi,E),ne(mo,Re),U(me))if(me.length){const J=e.exposed||(e.exposed={});me.forEach(K=>{Object.defineProperty(J,K,{get:()=>s[K],set:ue=>s[K]=ue})})}else e.exposed||(e.exposed={});j&&e.render===He&&(e.render=j),Te!=null&&(e.inheritAttrs=Te),Oe&&(e.components=Oe),$e&&(e.directives=$e),Re&&Ii(e)}function xo(e,t,s=He){U(e)&&(e=ks(e));for(const n in e){const i=e[n];let r;Q(i)?"default"in i?r=is(i.from||n,i.default,!0):r=is(i.from||n):r=is(i),le(r)?Object.defineProperty(t,n,{enumerable:!0,configurable:!0,get:()=>r.value,set:o=>r.value=o}):t[n]=r}}function On(e,t,s){je(U(e)?e.map(n=>n.bind(t.proxy)):e.bind(t.proxy),t,s)}function Di(e,t,s,n){let i=n.includes(".")?Ji(s,n):()=>s[n];if(se(e)){const r=t[e];H(r)&&rs(i,r)}else if(H(e))rs(i,e.bind(s));else if(Q(e))if(U(e))e.forEach(r=>Di(r,t,s,n));else{const r=H(e.handler)?e.handler.bind(s):t[e.handler];H(r)&&rs(i,r,e)}}function mn(e){const t=e.type,{mixins:s,extends:n}=t,{mixins:i,optionsCache:r,config:{optionMergeStrategies:o}}=e.appContext,l=r.get(t);let u;return l?u=l:!i.length&&!s&&!n?u=t:(u={},i.length&&i.forEach(p=>cs(u,p,o,!0)),cs(u,t,o)),Q(t)&&r.set(t,u),u}function cs(e,t,s,n=!1){const{mixins:i,extends:r}=t;r&&cs(e,r,s,!0),i&&i.forEach(o=>cs(e,o,s,!0));for(const o in t)if(!(n&&o==="expose")){const l=So[o]||s&&s[o];e[o]=l?l(e[o],t[o]):t[o]}return e}const So={data:In,props:An,emits:An,methods:Lt,computed:Lt,beforeCreate:fe,created:fe,beforeMount:fe,mounted:fe,beforeUpdate:fe,updated:fe,beforeDestroy:fe,beforeUnmount:fe,destroyed:fe,unmounted:fe,activated:fe,deactivated:fe,errorCaptured:fe,serverPrefetch:fe,components:Lt,directives:Lt,watch:Po,provide:In,inject:To};function In(e,t){return t?e?function(){return re(H(e)?e.call(this,this):e,H(t)?t.call(this,this):t)}:t:e}function To(e,t){return Lt(ks(e),ks(t))}function ks(e){if(U(e)){const t={};for(let s=0;s1)return s&&H(t)?t.call(n&&n.proxy):t}}const Wi={},Hi=()=>Object.create(Wi),Ni=e=>Object.getPrototypeOf(e)===Wi;function Ro(e,t,s,n=!1){const i={},r=Hi();e.propsDefaults=Object.create(null),ji(e,t,i,r);for(const o in e.propsOptions[0])o in i||(i[o]=void 0);s?e.props=n?i:kr(i):e.type.props?e.props=i:e.props=r,e.attrs=r}function Oo(e,t,s,n){const{props:i,attrs:r,vnode:{patchFlag:o}}=e,l=q(i),[u]=e.propsOptions;let p=!1;if((n||o>0)&&!(o&16)){if(o&8){const c=e.vnode.dynamicProps;for(let m=0;m{u=!0;const[g,y]=$i(m,t,!0);re(o,g),y&&l.push(...y)};!s&&t.mixins.length&&t.mixins.forEach(c),e.extends&&c(e.extends),e.mixins&&e.mixins.forEach(c)}if(!r&&!u)return Q(e)&&n.set(e,Tt),Tt;if(U(r))for(let c=0;ce[0]==="_"||e==="$stable",gn=e=>U(e)?e.map(We):[We(e)],Ao=(e,t,s)=>{if(t._n)return t;const n=io((...i)=>gn(t(...i)),s);return n._c=!1,n},ki=(e,t,s)=>{const n=e._ctx;for(const i in e){if(Bi(i))continue;const r=e[i];if(H(r))t[i]=Ao(i,r,n);else if(r!=null){const o=gn(r);t[i]=()=>o}}},Yi=(e,t)=>{const s=gn(t);e.slots.default=()=>s},Ki=(e,t,s)=>{for(const n in t)(s||n!=="_")&&(e[n]=t[n])},Fo=(e,t,s)=>{const n=e.slots=Hi();if(e.vnode.shapeFlag&32){const i=t._;i?(Ki(n,t,s),s&&ni(n,"_",i,!0)):ki(t,n)}else t&&Yi(e,t)},Lo=(e,t,s)=>{const{vnode:n,slots:i}=e;let r=!0,o=Z;if(n.shapeFlag&32){const l=t._;l?s&&l===1?r=!1:Ki(i,t,s):(r=!t.$stable,ki(t,i)),o=t}else t&&(Yi(e,t),o={default:1});if(r)for(const l in i)!Bi(l)&&o[l]==null&&delete i[l]},Ce=Go;function Vo(e){return Do(e)}function Do(e,t){const s=ii();s.__VUE__=!0;const{insert:n,remove:i,patchProp:r,createElement:o,createText:l,createComment:u,setText:p,setElementText:c,parentNode:m,nextSibling:g,setScopeId:y=He,insertStaticContent:P}=e,b=(f,h,v,T=null,x=null,S=null,_=void 0,w=null,a=!!h.dynamicChildren)=>{if(f===h)return;f&&!Ft(f,h)&&(T=Be(f),ie(f,x,S,!0),f=null),h.patchFlag===-2&&(a=!1,h.dynamicChildren=null);const{type:d,ref:R,shapeFlag:M}=h;switch(d){case xs:A(f,h,v,T);break;case gt:I(f,h,v,T);break;case Fs:f==null&&F(h,v,T,_);break;case Ke:Oe(f,h,v,T,x,S,_,w,a);break;default:M&1?j(f,h,v,T,x,S,_,w,a):M&6?$e(f,h,v,T,x,S,_,w,a):(M&64||M&128)&&d.process(f,h,v,T,x,S,_,w,a,Ae)}R!=null&&x&&js(R,f&&f.ref,S,h||f,!h)},A=(f,h,v,T)=>{if(f==null)n(h.el=l(h.children),v,T);else{const x=h.el=f.el;h.children!==f.children&&p(x,h.children)}},I=(f,h,v,T)=>{f==null?n(h.el=u(h.children||""),v,T):h.el=f.el},F=(f,h,v,T)=>{[f.el,f.anchor]=P(f.children,h,v,T,f.el,f.anchor)},V=({el:f,anchor:h},v,T)=>{let x;for(;f&&f!==h;)x=g(f),n(f,v,T),f=x;n(h,v,T)},E=({el:f,anchor:h})=>{let v;for(;f&&f!==h;)v=g(f),i(f),f=v;i(h)},j=(f,h,v,T,x,S,_,w,a)=>{h.type==="svg"?_="svg":h.type==="math"&&(_="mathml"),f==null?te(h,v,T,x,S,_,w,a):Re(f,h,x,S,_,w,a)},te=(f,h,v,T,x,S,_,w)=>{let a,d;const{props:R,shapeFlag:M,transition:O,dirs:L}=f;if(a=f.el=o(f.type,S,R&&R.is,R),M&8?c(a,f.children):M&16&&pe(f.children,a,null,T,x,Is(f,S),_,w),L&&ut(f,null,T,"created"),ee(a,f,f.scopeId,_,T),R){for(const X in R)X!=="value"&&!Vt(X)&&r(a,X,null,R[X],S,T);"value"in R&&r(a,"value",null,R.value,S),(d=R.onVnodeBeforeMount)&&Le(d,T,f)}L&&ut(f,null,T,"beforeMount");const W=Uo(x,O);W&&O.beforeEnter(a),n(a,h,v),((d=R&&R.onVnodeMounted)||W||L)&&Ce(()=>{d&&Le(d,T,f),W&&O.enter(a),L&&ut(f,null,T,"mounted")},x)},ee=(f,h,v,T,x)=>{if(v&&y(f,v),T)for(let S=0;S{for(let d=a;d{const w=h.el=f.el;let{patchFlag:a,dynamicChildren:d,dirs:R}=h;a|=f.patchFlag&16;const M=f.props||Z,O=h.props||Z;let L;if(v&&ft(v,!1),(L=O.onVnodeBeforeUpdate)&&Le(L,v,h,f),R&&ut(h,f,v,"beforeUpdate"),v&&ft(v,!0),(M.innerHTML&&O.innerHTML==null||M.textContent&&O.textContent==null)&&c(w,""),d?me(f.dynamicChildren,d,w,v,T,Is(h,x),S):_||K(f,h,w,null,v,T,Is(h,x),S,!1),a>0){if(a&16)Te(w,M,O,v,x);else if(a&2&&M.class!==O.class&&r(w,"class",null,O.class,x),a&4&&r(w,"style",M.style,O.style,x),a&8){const W=h.dynamicProps;for(let X=0;X{L&&Le(L,v,h,f),R&&ut(h,f,v,"updated")},T)},me=(f,h,v,T,x,S,_)=>{for(let w=0;w{if(h!==v){if(h!==Z)for(const S in h)!Vt(S)&&!(S in v)&&r(f,S,h[S],null,x,T);for(const S in v){if(Vt(S))continue;const _=v[S],w=h[S];_!==w&&S!=="value"&&r(f,S,w,_,x,T)}"value"in v&&r(f,"value",h.value,v.value,x)}},Oe=(f,h,v,T,x,S,_,w,a)=>{const d=h.el=f?f.el:l(""),R=h.anchor=f?f.anchor:l("");let{patchFlag:M,dynamicChildren:O,slotScopeIds:L}=h;L&&(w=w?w.concat(L):L),f==null?(n(d,v,T),n(R,v,T),pe(h.children||[],v,R,x,S,_,w,a)):M>0&&M&64&&O&&f.dynamicChildren?(me(f.dynamicChildren,O,v,x,S,_,w),(h.key!=null||x&&h===x.subTree)&&Xi(f,h,!0)):K(f,h,v,R,x,S,_,w,a)},$e=(f,h,v,T,x,S,_,w,a)=>{h.slotScopeIds=w,f==null?h.shapeFlag&512?x.ctx.activate(h,v,T,_,a):Ot(h,v,T,x,S,_,a):rt(f,h,a)},Ot=(f,h,v,T,x,S,_)=>{const w=f.component=sl(f,T,x);if(Ai(f)&&(w.ctx.renderer=Ae),nl(w,!1,_),w.asyncDep){if(x&&x.registerDep(w,ne,_),!f.el){const a=w.subTree=qe(gt);I(null,a,h,v)}}else ne(w,f,h,v,x,S,_)},rt=(f,h,v)=>{const T=h.component=f.component;if(Ko(f,h,v))if(T.asyncDep&&!T.asyncResolved){J(T,h,v);return}else T.next=h,T.update();else h.el=f.el,T.vnode=h},ne=(f,h,v,T,x,S,_)=>{const w=()=>{if(f.isMounted){let{next:M,bu:O,u:L,parent:W,vnode:X}=f;{const be=Gi(f);if(be){M&&(M.el=X.el,J(f,M,_)),be.asyncDep.then(()=>{f.isUnmounted||w()});return}}let B=M,ve;ft(f,!1),M?(M.el=X.el,J(f,M,_)):M=X,O&&ns(O),(ve=M.props&&M.props.onVnodeBeforeUpdate)&&Le(ve,W,M,X),ft(f,!0);const oe=As(f),Me=f.subTree;f.subTree=oe,b(Me,oe,m(Me.el),Be(Me),f,x,S),M.el=oe.el,B===null&&Xo(f,oe.el),L&&Ce(L,x),(ve=M.props&&M.props.onVnodeUpdated)&&Ce(()=>Le(ve,W,M,X),x)}else{let M;const{el:O,props:L}=h,{bm:W,m:X,parent:B,root:ve,type:oe}=f,Me=Wt(h);if(ft(f,!1),W&&ns(W),!Me&&(M=L&&L.onVnodeBeforeMount)&&Le(M,B,h),ft(f,!0),O&&at){const be=()=>{f.subTree=As(f),at(O,f.subTree,f,x,null)};Me&&oe.__asyncHydrate?oe.__asyncHydrate(O,f,be):be()}else{ve.ce&&ve.ce._injectChildStyle(oe);const be=f.subTree=As(f);b(null,be,v,T,f,x,S),h.el=be.el}if(X&&Ce(X,x),!Me&&(M=L&&L.onVnodeMounted)){const be=h;Ce(()=>Le(M,B,be),x)}(h.shapeFlag&256||B&&Wt(B.vnode)&&B.vnode.shapeFlag&256)&&f.a&&Ce(f.a,x),f.isMounted=!0,h=v=T=null}};f.scope.on();const a=f.effect=new ui(w);f.scope.off();const d=f.update=a.run.bind(a),R=f.job=a.runIfDirty.bind(a);R.i=f,R.id=f.uid,a.scheduler=()=>hn(R),ft(f,!0),d()},J=(f,h,v)=>{h.component=f;const T=f.vnode.props;f.vnode=h,f.next=null,Oo(f,h.props,T,v),Lo(f,h.children,v),nt(),En(f),it()},K=(f,h,v,T,x,S,_,w,a=!1)=>{const d=f&&f.children,R=f?f.shapeFlag:0,M=h.children,{patchFlag:O,shapeFlag:L}=h;if(O>0){if(O&128){Pe(d,M,v,T,x,S,_,w,a);return}else if(O&256){ue(d,M,v,T,x,S,_,w,a);return}}L&8?(R&16&&Ie(d,x,S),M!==d&&c(v,M)):R&16?L&16?Pe(d,M,v,T,x,S,_,w,a):Ie(d,x,S,!0):(R&8&&c(v,""),L&16&&pe(M,v,T,x,S,_,w,a))},ue=(f,h,v,T,x,S,_,w,a)=>{f=f||Tt,h=h||Tt;const d=f.length,R=h.length,M=Math.min(d,R);let O;for(O=0;OR?Ie(f,x,S,!0,!1,M):pe(h,v,T,x,S,_,w,a,M)},Pe=(f,h,v,T,x,S,_,w,a)=>{let d=0;const R=h.length;let M=f.length-1,O=R-1;for(;d<=M&&d<=O;){const L=f[d],W=h[d]=a?tt(h[d]):We(h[d]);if(Ft(L,W))b(L,W,v,null,x,S,_,w,a);else break;d++}for(;d<=M&&d<=O;){const L=f[M],W=h[O]=a?tt(h[O]):We(h[O]);if(Ft(L,W))b(L,W,v,null,x,S,_,w,a);else break;M--,O--}if(d>M){if(d<=O){const L=O+1,W=LO)for(;d<=M;)ie(f[d],x,S,!0),d++;else{const L=d,W=d,X=new Map;for(d=W;d<=O;d++){const ye=h[d]=a?tt(h[d]):We(h[d]);ye.key!=null&&X.set(ye.key,d)}let B,ve=0;const oe=O-W+1;let Me=!1,be=0;const It=new Array(oe);for(d=0;d=oe){ie(ye,x,S,!0);continue}let Fe;if(ye.key!=null)Fe=X.get(ye.key);else for(B=W;B<=O;B++)if(It[B-W]===0&&Ft(ye,h[B])){Fe=B;break}Fe===void 0?ie(ye,x,S,!0):(It[Fe-W]=d+1,Fe>=be?be=Fe:Me=!0,b(ye,h[Fe],v,null,x,S,_,w,a),ve++)}const bn=Me?Wo(It):Tt;for(B=bn.length-1,d=oe-1;d>=0;d--){const ye=W+d,Fe=h[ye],yn=ye+1{const{el:S,type:_,transition:w,children:a,shapeFlag:d}=f;if(d&6){ge(f.component.subTree,h,v,T);return}if(d&128){f.suspense.move(h,v,T);return}if(d&64){_.move(f,h,v,Ae);return}if(_===Ke){n(S,h,v);for(let M=0;Mw.enter(S),x);else{const{leave:M,delayLeave:O,afterLeave:L}=w,W=()=>n(S,h,v),X=()=>{M(S,()=>{W(),L&&L()})};O?O(S,W,X):X()}else n(S,h,v)},ie=(f,h,v,T=!1,x=!1)=>{const{type:S,props:_,ref:w,children:a,dynamicChildren:d,shapeFlag:R,patchFlag:M,dirs:O,cacheIndex:L}=f;if(M===-2&&(x=!1),w!=null&&js(w,null,v,f,!0),L!=null&&(h.renderCache[L]=void 0),R&256){h.ctx.deactivate(f);return}const W=R&1&&O,X=!Wt(f);let B;if(X&&(B=_&&_.onVnodeBeforeUnmount)&&Le(B,h,f),R&6)yt(f.component,v,T);else{if(R&128){f.suspense.unmount(v,T);return}W&&ut(f,null,h,"beforeUnmount"),R&64?f.type.remove(f,h,v,Ae,T):d&&!d.hasOnce&&(S!==Ke||M>0&&M&64)?Ie(d,h,v,!1,!0):(S===Ke&&M&384||!x&&R&16)&&Ie(a,h,v),T&&ot(f)}(X&&(B=_&&_.onVnodeUnmounted)||W)&&Ce(()=>{B&&Le(B,h,f),W&&ut(f,null,h,"unmounted")},v)},ot=f=>{const{type:h,el:v,anchor:T,transition:x}=f;if(h===Ke){bt(v,T);return}if(h===Fs){E(f);return}const S=()=>{i(v),x&&!x.persisted&&x.afterLeave&&x.afterLeave()};if(f.shapeFlag&1&&x&&!x.persisted){const{leave:_,delayLeave:w}=x,a=()=>_(v,S);w?w(f.el,S,a):a()}else S()},bt=(f,h)=>{let v;for(;f!==h;)v=g(f),i(f),f=v;i(h)},yt=(f,h,v)=>{const{bum:T,scope:x,job:S,subTree:_,um:w,m:a,a:d}=f;Ln(a),Ln(d),T&&ns(T),x.stop(),S&&(S.flags|=8,ie(_,f,h,v)),w&&Ce(w,h),Ce(()=>{f.isUnmounted=!0},h),h&&h.pendingBranch&&!h.isUnmounted&&f.asyncDep&&!f.asyncResolved&&f.suspenseId===h.pendingId&&(h.deps--,h.deps===0&&h.resolve())},Ie=(f,h,v,T=!1,x=!1,S=0)=>{for(let _=S;_{if(f.shapeFlag&6)return Be(f.component.subTree);if(f.shapeFlag&128)return f.suspense.next();const h=g(f.anchor||f.el),v=h&&h[ro];return v?g(v):h};let ze=!1;const lt=(f,h,v)=>{f==null?h._vnode&&ie(h._vnode,null,null,!0):b(h._vnode||null,f,h,null,null,null,v),h._vnode=f,ze||(ze=!0,En(),_i(),ze=!1)},Ae={p:b,um:ie,m:ge,r:ot,mt:Ot,mc:pe,pc:K,pbc:me,n:Be,o:e};let qt,at;return{render:lt,hydrate:qt,createApp:_o(lt,qt)}}function Is({type:e,props:t},s){return s==="svg"&&e==="foreignObject"||s==="mathml"&&e==="annotation-xml"&&t&&t.encoding&&t.encoding.includes("html")?void 0:s}function ft({effect:e,job:t},s){s?(e.flags|=32,t.flags|=4):(e.flags&=-33,t.flags&=-5)}function Uo(e,t){return(!e||e&&!e.pendingBranch)&&t&&!t.persisted}function Xi(e,t,s=!1){const n=e.children,i=t.children;if(U(n)&&U(i))for(let r=0;r>1,e[s[l]]0&&(t[n]=s[r-1]),s[r]=n)}}for(r=s.length,o=s[r-1];r-- >0;)s[r]=o,o=t[o];return s}function Gi(e){const t=e.subTree.component;if(t)return t.asyncDep&&!t.asyncResolved?t:Gi(t)}function Ln(e){if(e)for(let t=0;tis(Ho);function rs(e,t,s){return qi(e,t,s)}function qi(e,t,s=Z){const{immediate:n,deep:i,flush:r,once:o}=s,l=re({},s);let u;if(Ss)if(r==="sync"){const g=No();u=g.__watcherHandles||(g.__watcherHandles=[])}else if(!t||n)l.once=!0;else{const g=()=>{};return g.stop=He,g.resume=He,g.pause=He,g}const p=he;l.call=(g,y,P)=>je(g,p,y,P);let c=!1;r==="post"?l.scheduler=g=>{Ce(g,p&&p.suspense)}:r!=="sync"&&(c=!0,l.scheduler=(g,y)=>{y?g():hn(g)}),l.augmentJob=g=>{t&&(g.flags|=4),c&&(g.flags|=2,p&&(g.id=p.uid,g.i=p))};const m=Qr(e,t,l);return u&&u.push(m),m}function jo(e,t,s){const n=this.proxy,i=se(e)?e.includes(".")?Ji(n,e):()=>n[e]:e.bind(n,n);let r;H(t)?r=t:(r=t.handler,s=t);const o=Gt(this),l=qi(i,r.bind(n),s);return o(),l}function Ji(e,t){const s=t.split(".");return()=>{let n=e;for(let i=0;it==="modelValue"||t==="model-value"?e.modelModifiers:e[`${t}Modifiers`]||e[`${pt(t)}Modifiers`]||e[`${vt(t)}Modifiers`];function Bo(e,t,...s){if(e.isUnmounted)return;const n=e.vnode.props||Z;let i=s;const r=t.startsWith("update:"),o=r&&$o(n,t.slice(7));o&&(o.trim&&(i=s.map(c=>se(c)?c.trim():c)),o.number&&(i=s.map(Us)));let l,u=n[l=Ps(t)]||n[l=Ps(pt(t))];!u&&r&&(u=n[l=Ps(vt(t))]),u&&je(u,e,6,i);const p=n[l+"Once"];if(p){if(!e.emitted)e.emitted={};else if(e.emitted[l])return;e.emitted[l]=!0,je(p,e,6,i)}}function zi(e,t,s=!1){const n=t.emitsCache,i=n.get(e);if(i!==void 0)return i;const r=e.emits;let o={},l=!1;if(!H(e)){const u=p=>{const c=zi(p,t,!0);c&&(l=!0,re(o,c))};!s&&t.mixins.length&&t.mixins.forEach(u),e.extends&&u(e.extends),e.mixins&&e.mixins.forEach(u)}return!r&&!l?(Q(e)&&n.set(e,null),null):(U(r)?r.forEach(u=>o[u]=null):re(o,r),Q(e)&&n.set(e,o),o)}function ws(e,t){return!e||!ps(t)?!1:(t=t.slice(2).replace(/Once$/,""),G(e,t[0].toLowerCase()+t.slice(1))||G(e,vt(t))||G(e,t))}function As(e){const{type:t,vnode:s,proxy:n,withProxy:i,propsOptions:[r],slots:o,attrs:l,emit:u,render:p,renderCache:c,props:m,data:g,setupState:y,ctx:P,inheritAttrs:b}=e,A=fs(e);let I,F;try{if(s.shapeFlag&4){const E=i||n,j=E;I=We(p.call(j,E,c,m,y,g,P)),F=l}else{const E=t;I=We(E.length>1?E(m,{attrs:l,slots:o,emit:u}):E(m,null)),F=t.props?l:ko(l)}}catch(E){Nt.length=0,ys(E,e,1),I=qe(gt)}let V=I;if(F&&b!==!1){const E=Object.keys(F),{shapeFlag:j}=V;E.length&&j&7&&(r&&E.some(qs)&&(F=Yo(F,r)),V=Rt(V,F,!1,!0))}return s.dirs&&(V=Rt(V,null,!1,!0),V.dirs=V.dirs?V.dirs.concat(s.dirs):s.dirs),s.transition&&pn(V,s.transition),I=V,fs(A),I}const ko=e=>{let t;for(const s in e)(s==="class"||s==="style"||ps(s))&&((t||(t={}))[s]=e[s]);return t},Yo=(e,t)=>{const s={};for(const n in e)(!qs(n)||!(n.slice(9)in t))&&(s[n]=e[n]);return s};function Ko(e,t,s){const{props:n,children:i,component:r}=e,{props:o,children:l,patchFlag:u}=t,p=r.emitsOptions;if(t.dirs||t.transition)return!0;if(s&&u>=0){if(u&1024)return!0;if(u&16)return n?Vn(n,o,p):!!o;if(u&8){const c=t.dynamicProps;for(let m=0;me.__isSuspense;function Go(e,t){t&&t.pendingBranch?U(e)?t.effects.push(...e):t.effects.push(e):no(e)}const Ke=Symbol.for("v-fgt"),xs=Symbol.for("v-txt"),gt=Symbol.for("v-cmt"),Fs=Symbol.for("v-stc"),Nt=[];let xe=null;function St(e=!1){Nt.push(xe=e?null:[])}function qo(){Nt.pop(),xe=Nt[Nt.length-1]||null}let Yt=1;function Dn(e){Yt+=e,e<0&&xe&&(xe.hasOnce=!0)}function Qi(e){return e.dynamicChildren=Yt>0?xe||Tt:null,qo(),Yt>0&&xe&&xe.push(e),e}function ss(e,t,s,n,i,r){return Qi(C(e,t,s,n,i,r,!0))}function er(e,t,s,n,i){return Qi(qe(e,t,s,n,i,!0))}function Jo(e){return e?e.__v_isVNode===!0:!1}function Ft(e,t){return e.type===t.type&&e.key===t.key}const tr=({key:e})=>e??null,os=({ref:e,ref_key:t,ref_for:s})=>(typeof e=="number"&&(e=""+e),e!=null?se(e)||le(e)||H(e)?{i:Se,r:e,k:t,f:!!s}:e:null);function C(e,t=null,s=null,n=0,i=null,r=e===Ke?0:1,o=!1,l=!1){const u={__v_isVNode:!0,__v_skip:!0,type:e,props:t,key:t&&tr(t),ref:t&&os(t),scopeId:Ri,slotScopeIds:null,children:s,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:n,dynamicProps:i,dynamicChildren:null,appContext:null,ctx:Se};return l?(vn(u,s),r&128&&e.normalize(u)):s&&(u.shapeFlag|=se(s)?8:16),Yt>0&&!o&&xe&&(u.patchFlag>0||r&6)&&u.patchFlag!==32&&xe.push(u),u}const qe=zo;function zo(e,t=null,s=null,n=0,i=null,r=!1){if((!e||e===yo)&&(e=gt),Jo(e)){const l=Rt(e,t,!0);return s&&vn(l,s),Yt>0&&!r&&xe&&(l.shapeFlag&6?xe[xe.indexOf(e)]=l:xe.push(l)),l.patchFlag=-2,l}if(ll(e)&&(e=e.__vccOpts),t){t=Zo(t);let{class:l,style:u}=t;l&&!se(l)&&(t.class=Qs(l)),Q(u)&&(fn(u)&&!U(u)&&(u=re({},u)),t.style=Zs(u))}const o=se(e)?1:Zi(e)?128:oo(e)?64:Q(e)?4:H(e)?2:0;return C(e,t,s,n,i,o,r,!0)}function Zo(e){return e?fn(e)||Ni(e)?re({},e):e:null}function Rt(e,t,s=!1,n=!1){const{props:i,ref:r,patchFlag:o,children:l,transition:u}=e,p=t?Qo(i||{},t):i,c={__v_isVNode:!0,__v_skip:!0,type:e.type,props:p,key:p&&tr(p),ref:t&&t.ref?s&&r?U(r)?r.concat(os(t)):[r,os(t)]:os(t):r,scopeId:e.scopeId,slotScopeIds:e.slotScopeIds,children:l,target:e.target,targetStart:e.targetStart,targetAnchor:e.targetAnchor,staticCount:e.staticCount,shapeFlag:e.shapeFlag,patchFlag:t&&e.type!==Ke?o===-1?16:o|16:o,dynamicProps:e.dynamicProps,dynamicChildren:e.dynamicChildren,appContext:e.appContext,dirs:e.dirs,transition:u,component:e.component,suspense:e.suspense,ssContent:e.ssContent&&Rt(e.ssContent),ssFallback:e.ssFallback&&Rt(e.ssFallback),el:e.el,anchor:e.anchor,ctx:e.ctx,ce:e.ce};return u&&n&&pn(c,u.clone(c)),c}function Y(e=" ",t=0){return qe(xs,null,e,t)}function Ls(e="",t=!1){return t?(St(),er(gt,null,e)):qe(gt,null,e)}function We(e){return e==null||typeof e=="boolean"?qe(gt):U(e)?qe(Ke,null,e.slice()):typeof e=="object"?tt(e):qe(xs,null,String(e))}function tt(e){return e.el===null&&e.patchFlag!==-1||e.memo?e:Rt(e)}function vn(e,t){let s=0;const{shapeFlag:n}=e;if(t==null)t=null;else if(U(t))s=16;else if(typeof t=="object")if(n&65){const i=t.default;i&&(i._c&&(i._d=!1),vn(e,i()),i._c&&(i._d=!0));return}else{s=32;const i=t._;!i&&!Ni(t)?t._ctx=Se:i===3&&Se&&(Se.slots._===1?t._=1:(t._=2,e.patchFlag|=1024))}else H(t)?(t={default:t,_ctx:Se},s=32):(t=String(t),n&64?(s=16,t=[Y(t)]):s=8);e.children=t,e.shapeFlag|=s}function Qo(...e){const t={};for(let s=0;s{let i;return(i=e[s])||(i=e[s]=[]),i.push(n),r=>{i.length>1?i.forEach(o=>o(r)):i[0](r)}};ds=t("__VUE_INSTANCE_SETTERS__",s=>he=s),Ks=t("__VUE_SSR_SETTERS__",s=>Ss=s)}const Gt=e=>{const t=he;return ds(e),e.scope.on(),()=>{e.scope.off(),ds(t)}},Un=()=>{he&&he.scope.off(),ds(null)};function sr(e){return e.vnode.shapeFlag&4}let Ss=!1;function nl(e,t=!1,s=!1){t&&Ks(t);const{props:n,children:i}=e.vnode,r=sr(e);Ro(e,n,r,t),Fo(e,i,s);const o=r?il(e,t):void 0;return t&&Ks(!1),o}function il(e,t){const s=e.type;e.accessCache=Object.create(null),e.proxy=new Proxy(e.ctx,Co);const{setup:n}=s;if(n){const i=e.setupContext=n.length>1?ol(e):null,r=Gt(e);nt();const o=Xt(n,e,0,[e.props,i]);if(it(),r(),Qn(o)){if(Wt(e)||Ii(e),o.then(Un,Un),t)return o.then(l=>{Wn(e,l,t)}).catch(l=>{ys(l,e,0)});e.asyncDep=o}else Wn(e,o,t)}else nr(e,t)}function Wn(e,t,s){H(t)?e.type.__ssrInlineRender?e.ssrRender=t:e.render=t:Q(t)&&(e.setupState=Ti(t)),nr(e,s)}let Hn;function nr(e,t,s){const n=e.type;if(!e.render){if(!t&&Hn&&!n.render){const i=n.template||mn(e).template;if(i){const{isCustomElement:r,compilerOptions:o}=e.appContext.config,{delimiters:l,compilerOptions:u}=n,p=re(re({isCustomElement:r,delimiters:l},o),u);n.render=Hn(i,p)}}e.render=n.render||He}{const i=Gt(e);nt();try{wo(e)}finally{it(),i()}}}const rl={get(e,t){return ae(e,"get",""),e[t]}};function ol(e){const t=s=>{e.exposed=s||{}};return{attrs:new Proxy(e.attrs,rl),slots:e.slots,emit:e.emit,expose:t}}function Ts(e){return e.exposed?e.exposeProxy||(e.exposeProxy=new Proxy(Ti(Yr(e.exposed)),{get(t,s){if(s in t)return t[s];if(s in Ht)return Ht[s](e)},has(t,s){return s in t||s in Ht}})):e.proxy}function ll(e){return H(e)&&"__vccOpts"in e}const al=(e,t)=>zr(e,t,Ss),ul="3.5.8";/** * @vue/runtime-dom v3.5.8 * (c) 2018-present Yuxi (Evan) You and Vue contributors * @license MIT -**/let Xs;const Nn=typeof window<"u"&&window.trustedTypes;if(Nn)try{Xs=Nn.createPolicy("vue",{createHTML:e=>e})}catch{}const ir=Xs?e=>Xs.createHTML(e):e=>e,fl="http://www.w3.org/2000/svg",cl="http://www.w3.org/1998/Math/MathML",Ye=typeof document<"u"?document:null,jn=Ye&&Ye.createElement("template"),dl={insert:(e,t,s)=>{t.insertBefore(e,s||null)},remove:e=>{const t=e.parentNode;t&&t.removeChild(e)},createElement:(e,t,s,n)=>{const i=t==="svg"?Ye.createElementNS(fl,e):t==="mathml"?Ye.createElementNS(cl,e):s?Ye.createElement(e,{is:s}):Ye.createElement(e);return e==="select"&&n&&n.multiple!=null&&i.setAttribute("multiple",n.multiple),i},createText:e=>Ye.createTextNode(e),createComment:e=>Ye.createComment(e),setText:(e,t)=>{e.nodeValue=t},setElementText:(e,t)=>{e.textContent=t},parentNode:e=>e.parentNode,nextSibling:e=>e.nextSibling,querySelector:e=>Ye.querySelector(e),setScopeId(e,t){e.setAttribute(t,"")},insertStaticContent(e,t,s,n,i,r){const o=s?s.previousSibling:t.lastChild;if(i&&(i===r||i.nextSibling))for(;t.insertBefore(i.cloneNode(!0),s),!(i===r||!(i=i.nextSibling)););else{jn.innerHTML=ir(n==="svg"?`${e}`:n==="mathml"?`${e}`:e);const l=jn.content;if(n==="svg"||n==="mathml"){const u=l.firstChild;for(;u.firstChild;)l.appendChild(u.firstChild);l.removeChild(u)}t.insertBefore(l,s)}return[o?o.nextSibling:t.firstChild,s?s.previousSibling:t.lastChild]}},hl=Symbol("_vtc");function pl(e,t,s){const n=e[hl];n&&(t=(t?[t,...n]:[...n]).join(" ")),t==null?e.removeAttribute("class"):s?e.setAttribute("class",t):e.className=t}const $n=Symbol("_vod"),ml=Symbol("_vsh"),gl=Symbol(""),vl=/(^|;)\s*display\s*:/;function bl(e,t,s){const n=e.style,i=se(s);let r=!1;if(s&&!i){if(t)if(se(t))for(const o of t.split(";")){const l=o.slice(0,o.indexOf(":")).trim();s[l]==null&&ls(n,l,"")}else for(const o in t)s[o]==null&&ls(n,o,"");for(const o in s)o==="display"&&(r=!0),ls(n,o,s[o])}else if(i){if(t!==s){const o=n[gl];o&&(s+=";"+o),n.cssText=s,r=vl.test(s)}}else t&&e.removeAttribute("style");$n in e&&(e[$n]=r?n.display:"",e[ml]&&(n.display="none"))}const Bn=/\s*!important$/;function ls(e,t,s){if(U(s))s.forEach(n=>ls(e,t,n));else if(s==null&&(s=""),t.startsWith("--"))e.setProperty(t,s);else{const n=yl(e,t);Bn.test(s)?e.setProperty(vt(n),s.replace(Bn,""),"important"):e[n]=s}}const kn=["Webkit","Moz","ms"],Vs={};function yl(e,t){const s=Vs[t];if(s)return s;let n=pt(t);if(n!=="filter"&&n in e)return Vs[t]=n;n=si(n);for(let i=0;iDs||(Tl.then(()=>Ds=0),Ds=Date.now());function Ml(e,t){const s=n=>{if(!n._vts)n._vts=Date.now();else if(n._vts<=s.attached)return;je(_l(n,s.value),t,5,[n])};return s.value=e,s.attached=Pl(),s}function _l(e,t){if(U(t)){const s=e.stopImmediatePropagation;return e.stopImmediatePropagation=()=>{s.call(e),e._stopped=!0},t.map(n=>i=>!i._stopped&&n&&n(i))}else return t}const qn=e=>e.charCodeAt(0)===111&&e.charCodeAt(1)===110&&e.charCodeAt(2)>96&&e.charCodeAt(2)<123,El=(e,t,s,n,i,r)=>{const o=i==="svg";t==="class"?pl(e,n,o):t==="style"?bl(e,s,n):ps(t)?qs(t)||xl(e,t,s,n,r):(t[0]==="."?(t=t.slice(1),!0):t[0]==="^"?(t=t.slice(1),!1):Rl(e,t,n,o))?(Cl(e,t,n),!e.tagName.includes("-")&&(t==="value"||t==="checked"||t==="selected")&&Kn(e,t,n,o,r,t!=="value")):(t==="true-value"?e._trueValue=n:t==="false-value"&&(e._falseValue=n),Kn(e,t,n,o))};function Rl(e,t,s,n){if(n)return!!(t==="innerHTML"||t==="textContent"||t in e&&qn(t)&&W(s));if(t==="spellcheck"||t==="draggable"||t==="translate"||t==="form"||t==="list"&&e.tagName==="INPUT"||t==="type"&&e.tagName==="TEXTAREA")return!1;if(t==="width"||t==="height"){const i=e.tagName;if(i==="IMG"||i==="VIDEO"||i==="CANVAS"||i==="SOURCE")return!1}return qn(t)&&se(s)?!1:!!(t in e||e._isVueCE&&(/[A-Z]/.test(t)||!se(s)))}const hs=e=>{const t=e.props["onUpdate:modelValue"]||!1;return U(t)?s=>ns(t,s):t};function Ol(e){e.target.composing=!0}function Jn(e){const t=e.target;t.composing&&(t.composing=!1,t.dispatchEvent(new Event("input")))}const Et=Symbol("_assign"),$={created(e,{modifiers:{lazy:t,trim:s,number:n}},i){e[Et]=hs(i);const r=n||i.props&&i.props.type==="number";dt(e,t?"change":"input",o=>{if(o.target.composing)return;let l=e.value;s&&(l=l.trim()),r&&(l=Us(l)),e[Et](l)}),s&&dt(e,"change",()=>{e.value=e.value.trim()}),t||(dt(e,"compositionstart",Ol),dt(e,"compositionend",Jn),dt(e,"change",Jn))},mounted(e,{value:t}){e.value=t??""},beforeUpdate(e,{value:t,oldValue:s,modifiers:{lazy:n,trim:i,number:r}},o){if(e[Et]=hs(o),e.composing)return;const l=(r||e.type==="number")&&!/^0\d/.test(e.value)?Us(e.value):e.value,u=t??"";l!==u&&(document.activeElement===e&&e.type!=="range"&&(n&&t===s||i&&e.value.trim()===u)||(e.value=u))}},wt={deep:!0,created(e,t,s){e[Et]=hs(s),dt(e,"change",()=>{const n=e._modelValue,i=Il(e),r=e.checked,o=e[Et];if(U(n)){const l=oi(n,i),u=l!==-1;if(r&&!u)o(n.concat(i));else if(!r&&u){const p=[...n];p.splice(l,1),o(p)}}else if(ms(n)){const l=new Set(n);r?l.add(i):l.delete(i),o(l)}else o(rr(e,r))})},mounted:zn,beforeUpdate(e,t,s){e[Et]=hs(s),zn(e,t,s)}};function zn(e,{value:t,oldValue:s},n){e._modelValue=t;let i;U(t)?i=oi(t,n.props.value)>-1:ms(t)?i=t.has(n.props.value):i=vs(t,rr(e,!0)),e.checked!==i&&(e.checked=i)}function Il(e){return"_value"in e?e._value:e.value}function rr(e,t){const s=t?"_trueValue":"_falseValue";return s in e?e[s]:t}const Al=re({patchProp:El},dl);let Zn;function Fl(){return Zn||(Zn=Vo(Al))}const Ll=(...e)=>{const t=Fl().createApp(...e),{mount:s}=t;return t.mount=n=>{const i=Dl(n);if(!i)return;const r=t._component;!W(r)&&!r.render&&!r.template&&(r.template=i.innerHTML),i.nodeType===1&&(i.textContent="");const o=s(i,!1,Vl(i));return i instanceof Element&&(i.removeAttribute("v-cloak"),i.setAttribute("data-v-app","")),o},t};function Vl(e){if(e instanceof SVGElement)return"svg";if(typeof MathMLElement=="function"&&e instanceof MathMLElement)return"mathml"}function Dl(e){return se(e)?document.querySelector(e):e}const Qe=80,Ve=80;class Ul{constructor(t,s){k(this,"scale",1);k(this,"offsetX",0);k(this,"offsetY",0);k(this,"primaryColor","#ff0000");k(this,"mmToPixel");k(this,"canvasCtx");k(this,"offscreenCanvas");k(this,"canvas");k(this,"stampOffsetX",0);k(this,"stampOffsetY",0);k(this,"agingIntensity",50);k(this,"ruler",{showRuler:!0,showFullRuler:!0});k(this,"drawStar",{svgPath:"M 0 -1 L 0.588 0.809 L -0.951 -0.309 L 0.951 -0.309 L -0.588 0.809 Z",drawStar:!1,starDiameter:14,starPositionY:0,scaleToSmallStar:!1});k(this,"securityPattern",{openSecurityPattern:!0,securityPatternWidth:.15,securityPatternLength:3,securityPatternCount:5,securityPatternAngleRange:40,securityPatternParams:[]});k(this,"company",{companyName:"印章绘制有限责任公司",compression:1,borderOffset:1,textDistributionFactor:20,fontFamily:"SimSun",fontHeight:4.2});k(this,"taxNumber",{code:"000000000000000000",compression:.7,fontHeight:3.7,fontFamily:"Arial",fontWidth:1.3,letterSpacing:8,positionY:0,totalWidth:26});k(this,"stampCode",{code:"1234567890",compression:1,fontHeight:1.2,fontFamily:"Arial",borderOffset:1,fontWidth:1.2,textDistributionFactor:50});k(this,"stampType",{stampType:"发票专用章",fontHeight:4.6,fontWidth:3,compression:.75,letterSpacing:0,positionY:-3});k(this,"agingEffect",{applyAging:!1,agingIntensity:50,agingEffectParams:[]});k(this,"innerCircle",{drawInnerCircle:!0,innerCircleLineWidth:.5,innerCircleLineRadiusX:16,innerCircleLineRadiusY:12});k(this,"outThinCircle",{drawInnerCircle:!0,innerCircleLineWidth:.2,innerCircleLineRadiusX:36,innerCircleLineRadiusY:27});k(this,"drawStampConfigs",{ruler:this.ruler,drawStar:this.drawStar,securityPattern:this.securityPattern,company:this.company,stampCode:this.stampCode,width:40,height:30,stampType:this.stampType,primaryColor:this.primaryColor,borderWidth:1,refreshSecurityPattern:!1,refreshOld:!1,taxNumber:this.taxNumber,agingEffect:this.agingEffect,shouldDrawRuler:!0,innerCircle:this.innerCircle,outThinCircle:this.outThinCircle,openManualAging:!1});k(this,"cvReady",!1);k(this,"isDragging",!1);k(this,"dragStartX",0);k(this,"dragStartY",0);k(this,"onMouseUp",()=>{this.isDragging=!1,this.refreshStamp(!1,!1)});k(this,"onCanvasClick",t=>{this.canvas});k(this,"onMouseLeave",t=>{this.isDragging=!1,this.refreshStamp()});k(this,"onMouseDown",t=>{this.isDragging=!0,this.dragStartX=t.clientX-this.stampOffsetX*this.mmToPixel,this.dragStartY=t.clientY-this.stampOffsetY*this.mmToPixel});k(this,"onMouseMove",t=>{if(!this.drawStampConfigs.openManualAging)if(this.isDragging){const s=(t.clientX-this.dragStartX)/this.mmToPixel,n=(t.clientY-this.dragStartY)/this.mmToPixel;this.stampOffsetX=Math.round(s*10)/10,this.stampOffsetY=Math.round(n*10)/10,this.refreshStamp()}else{const s=this.canvas.getBoundingClientRect(),n=t.clientX-s.left,i=t.clientY-s.top,r=Math.round((n-Qe)/this.mmToPixel*10)/10,o=Math.round((i-Ve)/this.mmToPixel*10)/10;this.refreshStamp(),this.highlightRulerPosition(this.canvasCtx,r,o),this.drawCrossLines(n,i)}});k(this,"highlightRulerPosition",(t,s,n)=>{const i=s*this.mmToPixel+Qe,r=n*this.mmToPixel+Ve;t.fillStyle=this.drawStampConfigs.primaryColor,t.fillRect(Qe,r-1,this.canvas.width-Qe,2),t.fillRect(i-1,Ve,2,this.canvas.height-Ve),t.fillStyle="black",t.font="bold 12px Arial",t.textAlign="left",t.textBaseline="top";const o=s/this.scale,l=n/this.scale;t.fillText(`${o.toFixed(1)}mm, ${l.toFixed(1)}mm, scale: ${this.scale.toFixed(2)}`,Qe+5,Ve+5)});k(this,"drawCrossLines",(t,s)=>{const n=this.offscreenCanvas;if(!n)return;const i=n.getContext("2d");if(!i)return;i.clearRect(0,0,n.width,n.height),i.beginPath(),i.strokeStyle="rgba(255, 0, 0, 0.5)",i.lineWidth=1,i.moveTo(Qe,s),i.lineTo(n.width,s),i.moveTo(t,Ve),i.lineTo(t,n.height),i.stroke();const r=this.canvas;if(r){const o=r.getContext("2d");o&&o.drawImage(n,0,0)}});if(!t)throw new Error("Canvas is null");const n=t.getContext("2d");if(!n)throw new Error("Failed to get canvas context");this.canvasCtx=n,this.mmToPixel=s,this.canvas=t,this.offscreenCanvas=document.createElement("canvas"),this.canvas&&this.offscreenCanvas&&(this.offscreenCanvas.width=t.width,this.offscreenCanvas.height=t.height),this.addCanvasListener(),this.initOpenCV()}initOpenCV(){typeof cv<"u"?(this.cvReady=!0,console.log("OpenCV.js 已加载")):(console.log("等待 OpenCV.js 加载..."),document.addEventListener("opencv-ready",()=>{this.cvReady=!0,console.log("OpenCV.js 已加载")}))}getDrawConfigs(){return this.drawStampConfigs}addManualAgingEffect(t,s,n){console.log("手动做旧 1",t,s,this.drawStampConfigs.agingEffect.agingEffectParams);const i=1*this.mmToPixel,r=t-this.stampOffsetX*this.mmToPixel,o=s-this.stampOffsetY*this.mmToPixel;for(let l=0;l<10;l++)this.drawStampConfigs.agingEffect.agingEffectParams.push({x:r,y:o,noiseSize:Math.random()*3+1,noise:Math.random()*200*n,strongNoiseSize:Math.random()*5+2,strongNoise:Math.random()*250*n+5,fade:Math.random()*50*n,seed:Math.random()});this.refreshStamp(!1,!1),this.canvasCtx.save(),this.canvasCtx.globalCompositeOperation="destination-out",this.canvasCtx.beginPath(),this.canvasCtx.arc(t,s,i,0,Math.PI*2,!0),this.canvasCtx.fillStyle="rgba(255, 255, 255, 0.5)",this.canvasCtx.fill(),this.canvasCtx.restore()}setDrawConfigs(t){this.drawStampConfigs=t}addCanvasListener(){this.canvas.addEventListener("mousemove",t=>{if(this.drawStampConfigs.openManualAging&&t.buttons===1){const s=this.canvas.getBoundingClientRect(),n=t.clientX-s.left,i=t.clientY-s.top,r=this.drawStampConfigs.agingEffect.agingIntensity/100;this.addManualAgingEffect(n,i,r)}else this.onMouseMove(t)}),this.canvas.addEventListener("mouseleave",t=>{this.onMouseLeave(t)}),this.canvas.addEventListener("mousedown",t=>{if(this.onMouseDown(t),this.drawStampConfigs.openManualAging){const s=this.canvas.getBoundingClientRect(),n=t.clientX-s.left,i=t.clientY-s.top,r=this.drawStampConfigs.agingEffect.agingIntensity/100;this.addManualAgingEffect(n,i,r)}}),this.canvas.addEventListener("mouseup",t=>{this.onMouseUp()}),this.canvas.addEventListener("click",t=>{this.onCanvasClick(t)}),this.canvas.addEventListener("wheel",t=>{if(t.ctrlKey){t.preventDefault();const s=t.deltaY>0?.9:1.1;this.zoomCanvas(t.offsetX,t.offsetY,s)}})}zoomCanvas(t,s,n){const i=this.scale;this.scale*=n,this.scale=Math.max(.1,Math.min(5,this.scale)),this.offsetX=t-(t-this.offsetX)*(this.scale/i),this.offsetY=s-(s-this.offsetY)*(this.scale/i),this.refreshStamp()}extractRedStamp(t){return this.cvReady?this.extractRedStampWithColor(t,this.primaryColor):(console.error("OpenCV.js 未加载"),null)}extractStampWithColor(t,s,n){return this.cvReady?this.extractStampWithColor(t,s,n):(console.error("OpenCV.js 未加载"),null)}hexToRgba(t){let s=parseInt(t.slice(1,3),16),n=parseInt(t.slice(3,5),16),i=parseInt(t.slice(5,7),16),r=255;return t.length===9&&(r=parseInt(t.slice(7,9),16)),[s,n,i,r]}extractRedStampWithFile(t){return new Promise((s,n)=>{const i=new Image;i.onload=()=>{const r=this.extractRedStampWithColor(i,this.primaryColor);s(r)},i.onerror=r=>{console.error("图片加载失败",r),n(new Error("图片加载失败"))},i.src=URL.createObjectURL(t)})}extractStampWithFile(t,s,n){return new Promise((i,r)=>{const o=new Image;o.onload=()=>{const l=this.extractStampWithColorImpl(o,s,n);i(l)},o.onerror=l=>{console.error("图片加载失败",l),r(new Error("图片加载失败"))},o.src=URL.createObjectURL(t)})}extractRedStampWithColor(t,s){if(this.cvReady){const n=t.width,i=t.height;console.log("图片宽度:",n,"图片高度:",i);let r=cv.imread(t),o=new cv.Mat,l=new cv.Mat;cv.cvtColor(r,o,cv.COLOR_RGBA2RGB),cv.cvtColor(o,o,cv.COLOR_RGB2HSV);let u=new cv.Mat(o.rows,o.cols,o.type(),[0,100,100,0]),p=new cv.Mat(o.rows,o.cols,o.type(),[10,255,255,255]),c=new cv.Mat(o.rows,o.cols,o.type(),[160,100,100,0]),m=new cv.Mat(o.rows,o.cols,o.type(),[180,255,255,255]),g=new cv.Mat,y=new cv.Mat;cv.inRange(o,u,p,g),cv.inRange(o,c,m,y),cv.add(g,y,l);const P=this.hexToRgba(s);console.log("dstColor:",P);let b=new cv.Mat(r.rows,r.cols,r.type(),P);b.copyTo(o,l);const A=document.createElement("canvas");A.width=o.cols,A.height=o.rows,cv.imshow(A,o);let I=A.toDataURL("image/png"),F=document.createElement("a");return F.download="extracted_red_image.png",F.href=I,F.click(),r.delete(),o.delete(),l.delete(),g.delete(),y.delete(),u.delete(),p.delete(),c.delete(),m.delete(),b.delete(),o}else return console.error("OpenCV.js 未加载"),t}extractStampWithColorImpl(t,s="#ff0000",n="#ff0000"){if(this.cvReady){const i=t.width,r=t.height;console.log("图片宽度:",i,"图片高度:",r);let o=cv.imread(t),l=new cv.Mat,u=new cv.Mat;cv.cvtColor(o,l,cv.COLOR_RGBA2RGB),cv.cvtColor(l,l,cv.COLOR_RGB2HSV);const p=this.hexToRgba(s),c=cv.matFromArray(1,1,cv.CV_8UC3,[p[0],p[1],p[2]]);cv.cvtColor(c,c,cv.COLOR_RGB2HSV);const m=c.data32F;let g,y;if(s.toLowerCase()==="#ff0000")g=new cv.Mat(l.rows,l.cols,l.type(),[0,100,100,0]),y=new cv.Mat(l.rows,l.cols,l.type(),[10,255,255,255]);else if(s.toLowerCase()==="#00ff00")g=new cv.Mat(l.rows,l.cols,l.type(),[60,100,100,0]),y=new cv.Mat(l.rows,l.cols,l.type(),[80,255,255,255]);else if(s.toLowerCase()==="#000000")g=new cv.Mat(l.rows,l.cols,l.type(),[0,0,0,0]),y=new cv.Mat(l.rows,l.cols,l.type(),[180,255,30,255]);else{const V=m[0],E=10;g=new cv.Mat(l.rows,l.cols,l.type(),[Math.max(0,V-E),100,100,0]),y=new cv.Mat(l.rows,l.cols,l.type(),[Math.min(180,V+E),255,255,255])}cv.inRange(l,g,y,u);const P=this.hexToRgba(n);console.log("dstColor:",P);let b=new cv.Mat(o.rows,o.cols,cv.CV_8UC4,[0,0,0,0]),A=new cv.Mat(o.rows,o.cols,cv.CV_8UC4,[...P.slice(0,3),255]);A.copyTo(b,u);const I=document.createElement("canvas");I.width=b.cols,I.height=b.rows,cv.imshow(I,b);let F=I.toDataURL("image/png");return o.delete(),l.delete(),u.delete(),g.delete(),y.delete(),c.delete(),A.delete(),b.delete(),F}else return console.error("OpenCV.js 未加载"),t}saveImage(t,s){let n=document.createElement("canvas");n.width=s.cols,n.height=s.rows,t.imshow(n,s);let i=n.toDataURL("image/png"),r=document.createElement("a");r.download="extracted_red_image.png",r.href=i,r.click()}parseSVGPath(t){const s=[],n=/([MmLlHhVvCcSsQqTtAaZz])|(-?\d*\.?\d+)/g;let i,r="",o=[];for(;(i=n.exec(t))!==null;)i[1]?(r&&(s.push({command:r,params:o}),o=[]),r=i[1]):i[2]&&o.push(parseFloat(i[2]));return r&&s.push({command:r,params:o}),s}scaleSVGPathTo10mm(t){const s=this.parseSVGPath(t);let n=1/0,i=1/0,r=-1/0,o=-1/0,l=0,u=0;s.forEach(({command:y,params:P})=>{switch(y){case"M":case"L":case"C":case"S":case"Q":case"T":for(let b=0;b{const b=P.map(A=>A*m);return{command:y,params:b}});return this.convertPathDataToString(g)}convertPathDataToString(t){return t.map(({command:s,params:n})=>s+n.map(i=>i.toFixed(2)).join(" ")).join(" ")}drawSVGPath(t,s,n,i,r=1){t.save(),t.translate(n,i),t.scale(r,r);const o=new Path2D(s);t.fillStyle=this.primaryColor,t.fill(o),t.restore()}drawSVGPath2(t,s,n,i,r=1){t.save(),t.translate(n,i),t.scale(r,r),t.beginPath();let o=0,l=0,u=0,p=0,c=0,m=0;s.forEach(({command:g,params:y})=>{const P=y.length;switch(g){case"M":case"m":g==="M"?(o=y[0],l=y[1]):(o+=y[0],l+=y[1]),t.moveTo(o,l),u=o,p=l;break;case"L":case"l":for(let b=0;bee%2===0?te+o:te+l);t.bezierCurveTo(A,I,F,V,E,N),c=F,m=V,o=E,l=N}break;case"S":case"s":for(let b=0;bee%2===0?te+o:te+l);const E=o+(o-c),N=l+(l-m);t.bezierCurveTo(E,N,A,I,F,V),c=A,m=I,o=F,l=V}break;case"Q":case"q":for(let b=0;bN%2===0?E+o:E+l);t.quadraticCurveTo(A,I,F,V),c=A,m=I,o=F,l=V}break;case"T":case"t":for(let b=0;b{console.log("svg content img loaded",n,i,u,p,c),t.save(),t.translate(n,i),t.scale(r,r),t.drawImage(c,-u/2,-p/2,u,p),t.restore(),URL.revokeObjectURL(g)},c.src=g,c.onerror=y=>{console.error("加载SVG图像时出错:",y)}}drawStampType(t,s,n,i,r){const o=s.fontHeight*this.mmToPixel,l=s.letterSpacing,u=s.positionY;t.save(),t.font=`${o}px SimSun`,t.fillStyle=this.primaryColor,t.textAlign="center",t.textBaseline="middle";const p=i+r*.5+u*this.mmToPixel;t.save(),t.translate(n,p);const c=s.stampType.split(""),m=c.map(P=>t.measureText(P).width);let y=-(m.reduce((P,b)=>P+b,0)+(c.length-1)*l*this.mmToPixel)/2;t.scale(this.drawStampConfigs.stampType.compression,1),c.forEach((P,b)=>{t.fillText(P,y+m[b]/2,0),y+=m[b]+l*this.mmToPixel}),t.restore()}drawSecurityPattern(t,s,n,i,r,o){if(!this.securityPattern.openSecurityPattern)return;t.save(),t.strokeStyle="#FFFFFF",t.lineWidth=this.securityPattern.securityPatternWidth*this.mmToPixel,t.globalCompositeOperation="destination-out";const l=this.securityPattern.securityPatternAngleRange*Math.PI/180;if(o||this.drawStampConfigs.securityPattern.securityPatternParams.length===0){this.drawStampConfigs.securityPattern.securityPatternParams=[];for(let u=0;u{const c=s+i*Math.cos(u),m=n+r*Math.sin(u),g=this.securityPattern.securityPatternLength*this.mmToPixel,y=c-g/2*Math.cos(p),P=m-g/2*Math.sin(p),b=c+g/2*Math.cos(p),A=m+g/2*Math.sin(p);t.beginPath(),t.moveTo(y,P),t.lineTo(b,A),t.stroke()}),t.restore()}drawEllipse(t,s,n,i,r,o,l){t.beginPath(),t.ellipse(s,n,i,r,0,0,Math.PI*2),t.strokeStyle=l,t.lineWidth=o,t.stroke()}drawCompanyName(t,s,n,i,r,o){const l=s.fontHeight*this.mmToPixel;t.save(),t.font=`${l}px ${s.fontFamily}`,t.fillStyle=this.primaryColor,t.textAlign="center",t.textBaseline="bottom";const u=s.companyName.split(""),p=u.length,c=s.borderOffset*this.mmToPixel,m=Math.PI*(1+p/s.textDistributionFactor),g=Math.PI+(Math.PI-m)/2,y=m/p;u.forEach((P,b)=>{const A=g+y*(b+.5),I=n+Math.cos(A)*(r-l-c),F=i+Math.sin(A)*(o-l-c);t.save(),t.translate(I,F),t.rotate(A+Math.PI/2),t.scale(s.compression,1),t.fillText(P,0,0),t.restore()}),t.restore()}drawCode(t,s,n,i,r,o){const l=s.fontHeight*this.mmToPixel,u=s.code;t.save(),t.font=`${l}px ${s.fontFamily}`,t.fillStyle=this.primaryColor,t.textAlign="center",t.textBaseline="middle";const p=u.split(""),c=p.length,m=Math.PI*((1+c)/s.textDistributionFactor),g=Math.PI/2+m/2,y=m/(c-1);p.forEach((P,b)=>{const A=g-y*b,I=n+Math.cos(A)*(r-l/2-s.borderOffset*this.mmToPixel),F=i+Math.sin(A)*(o-l/2-s.borderOffset*this.mmToPixel);t.save(),t.translate(I,F),t.rotate(A-Math.PI/2),t.scale(s.compression,1),t.fillText(P,0,0),t.restore()}),t.restore()}drawTaxNumber(t,s,n,i){const r=s.fontHeight*this.mmToPixel,o=s.totalWidth*this.mmToPixel,l=s.positionY*this.mmToPixel+.3;t.save(),t.font=`${r}px ${s.fontFamily}`,t.fillStyle=this.primaryColor,t.textAlign="center",t.textBaseline="middle";const u=s.code.split(""),p=u.length,c=this.drawStampConfigs.taxNumber.letterSpacing*this.mmToPixel,g=(o*this.drawStampConfigs.taxNumber.compression-(p-1)*c)/p,y=p*g+(p-1)*c,P=n-y/2+g/2,b=i+l*this.mmToPixel;u.forEach((A,I)=>{const F=P+I*(g+c);t.save(),t.translate(F,b),t.scale(this.drawStampConfigs.taxNumber.compression,1.35),t.fillText(A,0,0),t.restore()}),t.restore()}addAgingEffect(t,s,n,i=!1){if(!this.drawStampConfigs.agingEffect.applyAging)return;const r=t.getImageData(0,0,s,n),o=r.data,l=s/(2*this.scale)+this.stampOffsetX*this.mmToPixel/this.scale,u=n/(2*this.scale)+this.stampOffsetY*this.mmToPixel/this.scale,p=Math.max(s,n)/2*this.mmToPixel/this.scale;if(i||this.drawStampConfigs.agingEffect.agingEffectParams.length===0){this.drawStampConfigs.agingEffect.agingEffectParams=[];for(let c=0;c200&&o[g+1]<50&&o[g+2]<50){const P=this.drawStampConfigs.agingEffect.agingIntensity/100,b=Math.random();this.drawStampConfigs.agingEffect.agingEffectParams.push({x:m-this.stampOffsetX*this.mmToPixel,y:c-this.stampOffsetY*this.mmToPixel,noiseSize:Math.random()*3+1,noise:Math.random()*200*P,strongNoiseSize:Math.random()*5+2,strongNoise:Math.random()*250*P+5,fade:Math.random()*50*P,seed:b})}}}this.drawStampConfigs.agingEffect.agingEffectParams.forEach(c=>{const{x:m,y:g,noiseSize:y,noise:P,strongNoiseSize:b,strongNoise:A,fade:I,seed:F}=c,V=m+this.stampOffsetX*this.mmToPixel,E=g+this.stampOffsetY*this.mmToPixel,N=(Math.round(E)*s+Math.round(V))*4;F<.4&&this.addCircularNoise(o,s,V,E,y,P,!0),F<.05&&this.addCircularNoise(o,s,V,E,b,A,!0),F<.2&&(o[N+3]=Math.max(0,o[N+3]-I))}),t.putImageData(r,0,0)}addCircularNoise(t,s,n,i,r,o,l=!1){const u=r*r/4;for(let p=-r/2;p=0&&y{const s=document.createElement("canvas");s.width=t,s.height=t;const n=s.getContext("2d");if(!n)return;n.clearRect(0,0,t,t);const i=(Math.max(this.drawStampConfigs.width,this.drawStampConfigs.height)+2)*this.mmToPixel,r=(this.canvas.width-i)/2+this.stampOffsetX*this.mmToPixel,o=(this.canvas.height-i)/2+this.stampOffsetY*this.mmToPixel,l=t*.01,u=t-2*l;n.drawImage(this.canvas,r,o,i,i,l,l,u,u),this.drawStampConfigs.agingEffect.applyAging&&this.addAgingEffect(n,t,t,!1);const p=s.toDataURL("image/png"),c=document.createElement("a");c.href=p,c.download="印章.png",document.body.appendChild(c),c.click(),document.body.removeChild(c),this.drawStampConfigs.shouldDrawRuler=!0,this.refreshStamp()},50)}refreshStamp(t=!1,s=!1){this.canvasCtx.clearRect(0,0,this.canvas.width,this.canvas.height),this.canvasCtx.save(),this.canvasCtx.translate(this.offsetX,this.offsetY),this.canvasCtx.scale(this.scale,this.scale);const n=this.canvas.width/2/this.scale,i=this.canvas.height/2/this.scale,r=this.mmToPixel,o=(this.drawStampConfigs.width-this.drawStampConfigs.borderWidth)/2,l=(this.drawStampConfigs.height-this.drawStampConfigs.borderWidth)/2,u=this.stampOffsetX*this.mmToPixel,p=this.stampOffsetY*this.mmToPixel,c=n+u,m=i+p;this.drawStamp(this.canvasCtx,c,m,o*r,l*r,this.drawStampConfigs.borderWidth*r,this.drawStampConfigs.primaryColor,t,s),this.canvasCtx.restore(),this.drawStampConfigs.shouldDrawRuler&&(this.drawRuler(this.canvasCtx,this.canvas.width,Ve,!0),this.drawRuler(this.canvasCtx,this.canvas.height,Ve,!1),this.drawFullRuler(this.canvasCtx,this.canvas.width,this.canvas.height))}resetZoom(){this.scale=1,this.offsetX=0,this.offsetY=0,this.refreshStamp()}drawStamp(t,s,n,i,r,o,l,u=!1,p=!1){t.clearRect(0,0,this.canvas.width,this.canvas.height);const c=this.offscreenCanvas;c.width=this.canvas.width,c.height=this.canvas.height;const m=c.getContext("2d");if(m){if(m.beginPath(),m.ellipse(s,n,i,r,0,0,Math.PI*2),m.strokeStyle="white",m.lineWidth=o,m.stroke(),m.fillStyle="white",t.fillStyle="white",t.fillRect(0,0,this.canvas.width,this.canvas.height),this.drawEllipse(m,s,n,i,r,o,l),this.drawStampConfigs.innerCircle.drawInnerCircle){const g=this.drawStampConfigs.innerCircle,y=(g.innerCircleLineRadiusX-g.innerCircleLineWidth)/2,P=(g.innerCircleLineRadiusY-g.innerCircleLineWidth)/2;this.drawEllipse(m,s,n,y*this.mmToPixel,P*this.mmToPixel,g.innerCircleLineWidth*this.mmToPixel,this.drawStampConfigs.primaryColor)}if(this.drawStampConfigs.outThinCircle.drawInnerCircle){const g=this.drawStampConfigs.outThinCircle,y=(g.innerCircleLineRadiusX-g.innerCircleLineWidth)/2,P=(g.innerCircleLineRadiusY-g.innerCircleLineWidth)/2;this.drawEllipse(m,s,n,y*this.mmToPixel,P*this.mmToPixel,g.innerCircleLineWidth*this.mmToPixel,this.drawStampConfigs.primaryColor)}this.drawSecurityPattern(m,s,n,i,r,u),this.drawStampConfigs.drawStar.drawStar&&this.drawStarShape(m,this.drawStampConfigs.drawStar,s,n),this.drawCompanyName(m,this.drawStampConfigs.company,s,n,i,r),this.drawStampType(m,this.drawStampConfigs.stampType,s,n,i),this.drawCode(m,this.drawStampConfigs.stampCode,s,n,i,r),this.drawTaxNumber(m,this.drawStampConfigs.taxNumber,s,n),t.save(),t.globalCompositeOperation="source-over",t.fillStyle=l,t.fillRect(0,0,this.canvas.width,this.canvas.height),t.globalCompositeOperation="destination-in",t.drawImage(c,0,0),t.restore(),this.addAgingEffect(t,this.canvas.width,this.canvas.height,p)}}}const Wl={class:"container"},Hl={class:"button-group",style:{position:"sticky",top:"0","z-index":"1000","background-color":"white",padding:"10px"}},Nl={class:"control-group",id:"stamp-settings"},jl={class:"control-group",id:"inner-circle-settings"},$l={class:"checkbox-label"},Bl={class:"control-group",id:"out-thin-circle-settings"},kl={class:"checkbox-label"},Yl={class:"control-group",id:"company-name-settings"},Kl={class:"control-group",id:"bottom-text-settings"},Xl={class:"control-group",id:"code-settings"},Gl={class:"control-group",id:"tax-number-settings"},ql={class:"control-group",id:"star-settings"},Jl={class:"checkbox-label"},zl={key:0},Zl={key:1},Ql={class:"control-group"},ea={class:"canvas-container"},ta={style:{display:"flex","flex-direction":"row","margin-top":"12px"}},sa={class:"control-group"},na={class:"checkbox-label"},ia={class:"checkbox-label"},ra={key:0},oa=10,la=Oi({__name:"DrawStampUtilsDemo",setup(e){const t=D(null),s=D(null),n=D("绘制印章有限责任公司"),i=D("1234567890123"),r=D("000000000000000000"),o=D(4.2),l=D(1.2),u=D(1.2),p=D(20),c=D(1),m=D("#ff0000"),g=D(14),y=D(!1),P=D(!1),b=D(50),A=D(20),I=D(1),F=D(1),V=D(20),E=D("合同专用章"),N=D(4.6),te=D(3),ee=D(0),pe=D(0),Re=D(-5),me=D(1),Te=D(1),Oe=D(1),$e=D(!0),Ot=D(.5),rt=D(.2),ne=D("#FF0000"),J=D(5),K=D(2);D(!1);const ue=D(!1),Pe=D(1),ge=D(.3),ie=D(0),ot=D(!1),bt=D(.5),yt=D(15),Ie=D(12),Be=D(!1),ze=D(.5),lt=D(15),Ae=D(12),qt=()=>{v.saveStampAsPNG(512)},at=D(40),f=D(30),h=()=>{const w=document.createElement("input");w.type="file",w.accept="image/*",w.onchange=a=>{var R;const d=(R=a.target.files)==null?void 0:R[0];d?(console.log("选择了图片",d),v.extractStampWithFile(d,"#ff0000","#ff0000").then(M=>{console.log(M)})):console.error("未选择图片")},w.click()};let v;const T=()=>{v=new Ul(s.value,oa)},x=(w=!1,a=!1)=>{v.refreshStamp(w,a)},S=()=>{const w=v.getDrawConfigs(),a=w.agingEffect;a.applyAging=y.value,a.agingIntensity=b.value,w.openManualAging=P.value;const d=w.securityPattern;d.openSecurityPattern=$e.value,d.securityPatternCount=J.value,d.securityPatternWidth=rt.value,d.securityPatternLength=K.value;const R=w.company;R.companyName=n.value,R.textDistributionFactor=A.value,R.borderOffset=I.value,R.fontHeight=o.value,R.compression=me.value;const M=w.taxNumber;M.code=r.value,M.compression=Pe.value,M.positionY=ie.value,M.letterSpacing=ge.value;const O=w.stampType;O.stampType=E.value,O.fontHeight=N.value,O.fontWidth=te.value,O.letterSpacing=ee.value,O.positionY=Re.value,O.compression=Te.value;const L=w.stampCode;L.code=i.value,L.compression=Oe.value,L.fontHeight=l.value,L.fontWidth=u.value,L.borderOffset=F.value,L.textDistributionFactor=V.value,w.primaryColor=m.value,w.borderWidth=c.value,w.width=at.value,w.height=f.value;const j=w.drawStar;j.drawStar=ue.value,j.starDiameter=g.value,j.starPositionY=pe.value;const X=w.innerCircle;X.drawInnerCircle=ot.value,X.innerCircleLineWidth=bt.value,X.innerCircleLineRadiusX=yt.value,X.innerCircleLineRadiusY=Ie.value;const B=w.outThinCircle;B.drawInnerCircle=Be.value,B.innerCircleLineWidth=ze.value,B.innerCircleLineRadiusX=lt.value,B.innerCircleLineRadiusY=Ae.value,x()},_=()=>{const w=v.getDrawConfigs(),a=w.company;n.value=a.companyName,o.value=a.fontHeight,me.value=a.compression,A.value=a.textDistributionFactor,I.value=a.borderOffset;const d=w.stampCode;i.value=d.code,l.value=d.fontHeight,u.value=d.fontWidth,V.value=d.textDistributionFactor,F.value=d.borderOffset;const R=w.taxNumber;r.value=R.code,Pe.value=R.compression,ge.value=R.letterSpacing,ie.value=R.positionY;const M=w.stampType;E.value=M.stampType,N.value=M.fontHeight,te.value=M.fontWidth,ee.value=M.letterSpacing,Re.value=M.positionY,ue.value=w.drawStar.drawStar,g.value=w.drawStar.starDiameter,pe.value=w.drawStar.starPositionY,m.value=w.primaryColor,P.value=w.openManualAging};return Li(()=>{T(),_(),x()}),rs([n,i,o,l,p,c,m,g,V,A,I,F,b,E,N,ee,Re,r,y,b,me,Te,Oe,ee,ne,Ot,ne,$e,J,K,rt,at,f,ue,pe,Pe,ge,ie,g,ot,bt,yt,Ie,ze,lt,Ae,Be,P],()=>{S()}),(w,a)=>(St(),ss("div",Wl,[C("div",{class:"editor-controls",ref_key:"editorControls",ref:t},[C("div",Hl,[C("button",{onClick:a[0]||(a[0]=d=>h())},"提取印章"),C("button",{onClick:qt},"保存印章")]),C("div",Nl,[a[58]||(a[58]=C("h3",null,"印章基本设置",-1)),C("label",null,[a[44]||(a[44]=Y("印章宽度 (mm): ")),H(C("input",{type:"number","onUpdate:modelValue":a[1]||(a[1]=d=>at.value=d),min:"1",max:"50",step:"1"},null,512),[[$,at.value,void 0,{number:!0}]])]),C("label",null,[a[45]||(a[45]=Y("印章高度 (mm): ")),H(C("input",{type:"number","onUpdate:modelValue":a[2]||(a[2]=d=>f.value=d),min:"1",max:"50",step:"1"},null,512),[[$,f.value,void 0,{number:!0}]])]),C("label",null,[a[46]||(a[46]=Y("圆形边框宽度 (mm): ")),H(C("input",{type:"number",step:"0.1","onUpdate:modelValue":a[3]||(a[3]=d=>c.value=d)},null,512),[[$,c.value,void 0,{number:!0}]])]),C("label",null,[a[47]||(a[47]=Y("圆形边框颜色: ")),H(C("input",{type:"color","onUpdate:modelValue":a[4]||(a[4]=d=>m.value=d)},null,512),[[$,m.value]])]),C("div",jl,[a[52]||(a[52]=C("h3",null,"内圈圆形设置",-1)),C("label",$l,[H(C("input",{type:"checkbox","onUpdate:modelValue":a[5]||(a[5]=d=>ot.value=d)},null,512),[[wt,ot.value]]),a[48]||(a[48]=Y(" 绘制内圈圆形 "))]),C("label",null,[a[49]||(a[49]=Y(" 内圈圆形线宽 (mm): ")),H(C("input",{type:"number","onUpdate:modelValue":a[6]||(a[6]=d=>bt.value=d),min:"0.1",max:"2",step:"0.1"},null,512),[[$,bt.value,void 0,{number:!0}]])]),C("label",null,[a[50]||(a[50]=Y(" 内圈圆形宽度 (mm): ")),H(C("input",{type:"number","onUpdate:modelValue":a[7]||(a[7]=d=>yt.value=d),min:"1",max:"50",step:"0.5"},null,512),[[$,yt.value,void 0,{number:!0}]])]),C("label",null,[a[51]||(a[51]=Y(" 内圈圆形高度 (mm): ")),H(C("input",{type:"number","onUpdate:modelValue":a[8]||(a[8]=d=>Ie.value=d),min:"1",max:"50",step:"0.5"},null,512),[[$,Ie.value,void 0,{number:!0}]])])]),C("div",Bl,[a[57]||(a[57]=C("h3",null,"外部细圈设置",-1)),C("label",kl,[H(C("input",{type:"checkbox","onUpdate:modelValue":a[9]||(a[9]=d=>Be.value=d)},null,512),[[wt,Be.value]]),a[53]||(a[53]=Y(" 绘制外部细圈 "))]),C("label",null,[a[54]||(a[54]=Y(" 外部细圈线宽 (mm): ")),H(C("input",{type:"number","onUpdate:modelValue":a[10]||(a[10]=d=>ze.value=d),min:"0.1",max:"2",step:"0.1"},null,512),[[$,ze.value,void 0,{number:!0}]])]),C("label",null,[a[55]||(a[55]=Y(" 外部细圈宽度 (mm): ")),H(C("input",{type:"number","onUpdate:modelValue":a[11]||(a[11]=d=>lt.value=d),min:"1",max:"50",step:"0.5"},null,512),[[$,lt.value,void 0,{number:!0}]])]),C("label",null,[a[56]||(a[56]=Y(" 外部细圈高度 (mm): ")),H(C("input",{type:"number","onUpdate:modelValue":a[12]||(a[12]=d=>Ae.value=d),min:"1",max:"50",step:"0.5"},null,512),[[$,Ae.value,void 0,{number:!0}]])])])]),C("div",Yl,[a[62]||(a[62]=C("h3",null,"公司名称设置",-1)),C("label",null,[a[59]||(a[59]=Y("公司名称: ")),H(C("input",{"onUpdate:modelValue":a[13]||(a[13]=d=>n.value=d)},null,512),[[$,n.value]])]),C("label",null,[a[60]||(a[60]=Y("字体大小 (mm): ")),H(C("input",{type:"number","onUpdate:modelValue":a[14]||(a[14]=d=>o.value=d),step:"0.1"},null,512),[[$,o.value,void 0,{number:!0}]])]),C("label",null,[C("span",null,"压缩比例:"+De(me.value.toFixed(2)),1),H(C("input",{type:"range","onUpdate:modelValue":a[15]||(a[15]=d=>me.value=d),min:"0.5",max:"1.5",step:"0.05"},null,512),[[$,me.value,void 0,{number:!0}]])]),C("label",null,[C("span",null,"分布因子:"+De(A.value.toFixed(1)),1),H(C("input",{type:"range","onUpdate:modelValue":a[16]||(a[16]=d=>A.value=d),min:"1",max:"100",step:"0.5"},null,512),[[$,A.value,void 0,{number:!0}]])]),C("label",null,[a[61]||(a[61]=C("span",null,"边距 (mm): ",-1)),H(C("input",{type:"number","onUpdate:modelValue":a[17]||(a[17]=d=>I.value=d),min:"-10",max:"10",step:"0.05"},null,512),[[$,I.value,void 0,{number:!0}]])])]),C("div",Kl,[a[66]||(a[66]=C("h3",null,"底部文字设置",-1)),C("label",null,[a[63]||(a[63]=Y("底部文字: ")),H(C("input",{type:"text","onUpdate:modelValue":a[18]||(a[18]=d=>E.value=d)},null,512),[[$,E.value]])]),C("label",null,[a[64]||(a[64]=Y("字体大小 (mm): ")),H(C("input",{type:"number","onUpdate:modelValue":a[19]||(a[19]=d=>N.value=d),min:"1",max:"10",step:"0.1"},null,512),[[$,N.value,void 0,{number:!0}]])]),C("label",null,[C("span",null,"压缩比例:"+De(Te.value.toFixed(2)),1),H(C("input",{type:"range","onUpdate:modelValue":a[20]||(a[20]=d=>Te.value=d),min:"0.5",max:"1.5",step:"0.05"},null,512),[[$,Te.value,void 0,{number:!0}]])]),C("label",null,[C("span",null,"字符间距 (mm):"+De(ee.value.toFixed(2)),1),H(C("input",{type:"range","onUpdate:modelValue":a[21]||(a[21]=d=>ee.value=d),min:"-1",max:"10",step:"0.05"},null,512),[[$,ee.value,void 0,{number:!0}]])]),C("label",null,[a[65]||(a[65]=Y(" 垂直位置调整 (mm): ")),H(C("input",{type:"number","onUpdate:modelValue":a[22]||(a[22]=d=>Re.value=d),min:"-10",max:"10",step:"0.1"},null,512),[[$,Re.value,void 0,{number:!0}]])])]),C("div",Xl,[a[70]||(a[70]=C("h3",null,"印章编码设置",-1)),C("label",null,[a[67]||(a[67]=Y("印章编码: ")),H(C("input",{"onUpdate:modelValue":a[23]||(a[23]=d=>i.value=d)},null,512),[[$,i.value]])]),C("label",null,[a[68]||(a[68]=Y("字体大小 (mm): ")),H(C("input",{type:"number","onUpdate:modelValue":a[24]||(a[24]=d=>l.value=d),step:"0.1"},null,512),[[$,l.value,void 0,{number:!0}]])]),C("label",null,[C("span",null,"压缩比例:"+De(Oe.value.toFixed(2)),1),H(C("input",{type:"range","onUpdate:modelValue":a[25]||(a[25]=d=>Oe.value=d),min:"0.0",max:"3",step:"0.01"},null,512),[[$,Oe.value,void 0,{number:!0}]])]),C("label",null,[C("span",null,"分布因子: "+De(V.value.toFixed(1)),1),H(C("input",{type:"range","onUpdate:modelValue":a[26]||(a[26]=d=>V.value=d),min:"0",max:"100",step:"0.5"},null,512),[[$,V.value,void 0,{number:!0}]])]),C("label",null,[a[69]||(a[69]=Y(" 边距 (mm): ")),H(C("input",{type:"number","onUpdate:modelValue":a[27]||(a[27]=d=>F.value=d),min:"-10",max:"20",step:"0.05"},null,512),[[$,F.value,void 0,{number:!0}]])])]),C("div",Gl,[a[72]||(a[72]=C("h3",null,"税号设置",-1)),C("label",null,[a[71]||(a[71]=Y("税号: ")),H(C("input",{"onUpdate:modelValue":a[28]||(a[28]=d=>r.value=d)},null,512),[[$,r.value]])]),C("label",null,[C("span",null,"压缩比例:"+De(Pe.value.toFixed(2)),1),H(C("input",{type:"range","onUpdate:modelValue":a[29]||(a[29]=d=>Pe.value=d),min:"0.0",max:"3",step:"0.01"},null,512),[[$,Pe.value,void 0,{number:!0}]])]),C("label",null,[C("span",null,"字符间距 (mm):"+De(ge.value.toFixed(2)),1),H(C("input",{type:"range","onUpdate:modelValue":a[30]||(a[30]=d=>ge.value=d),min:"-1",max:"20",step:"0.05"},null,512),[[$,ge.value,void 0,{number:!0}]])]),C("label",null,[C("span",null,"垂直位置调整 (mm):"+De(ie.value.toFixed(1)),1),H(C("input",{type:"range","onUpdate:modelValue":a[31]||(a[31]=d=>ie.value=d),min:"-10",max:"10",step:"0.1"},null,512),[[$,ie.value,void 0,{number:!0}]])])]),C("div",ql,[a[76]||(a[76]=C("h3",null,"五角星设置",-1)),C("label",Jl,[H(C("input",{type:"checkbox","onUpdate:modelValue":a[32]||(a[32]=d=>ue.value=d)},null,512),[[wt,ue.value]]),a[73]||(a[73]=Y(" 绘制五角星 "))]),ue.value?(St(),ss("label",zl,[a[74]||(a[74]=Y(" 五角星直径 (mm): ")),H(C("input",{type:"number","onUpdate:modelValue":a[33]||(a[33]=d=>g.value=d),step:"0.1"},null,512),[[$,g.value,void 0,{number:!0}]])])):Ls("",!0),ue.value?(St(),ss("label",Zl,[a[75]||(a[75]=Y(" 五角星垂直位置 (mm): ")),H(C("input",{type:"number","onUpdate:modelValue":a[34]||(a[34]=d=>pe.value=d),min:"-10",max:"10",step:"0.1"},null,512),[[$,pe.value,void 0,{number:!0}]])])):Ls("",!0)]),C("div",Ql,[a[81]||(a[81]=C("h3",null,"防伪纹路设置",-1)),C("label",null,[a[77]||(a[77]=Y(" 启用防伪纹路: ")),H(C("input",{type:"checkbox","onUpdate:modelValue":a[35]||(a[35]=d=>$e.value=d)},null,512),[[wt,$e.value]])]),C("button",{onClick:a[36]||(a[36]=d=>x(!0,!1))},"刷新纹路"),C("label",null,[a[78]||(a[78]=Y("纹路数量: ")),H(C("input",{type:"range","onUpdate:modelValue":a[37]||(a[37]=d=>J.value=d),min:"1",max:"20",step:"1"},null,512),[[$,J.value,void 0,{number:!0}]])]),C("label",null,[a[79]||(a[79]=Y("纹路长度 (mm): ")),H(C("input",{type:"range","onUpdate:modelValue":a[38]||(a[38]=d=>K.value=d),min:"0.1",max:"20",step:"0.1"},null,512),[[$,K.value,void 0,{number:!0}]])]),C("label",null,[a[80]||(a[80]=Y("纹路宽度 (mm): ")),H(C("input",{type:"range","onUpdate:modelValue":a[39]||(a[39]=d=>rt.value=d),min:"0.05",max:"0.5",step:"0.05"},null,512),[[$,rt.value,void 0,{number:!0}]])])])],512),C("div",ea,[C("div",ta,[C("div",sa,[a[85]||(a[85]=C("h3",null,"做旧效果",-1)),C("label",na,[H(C("input",{type:"checkbox","onUpdate:modelValue":a[40]||(a[40]=d=>y.value=d)},null,512),[[wt,y.value]]),a[82]||(a[82]=Y(" 启用做旧效果 "))]),C("label",ia,[H(C("input",{type:"checkbox","onUpdate:modelValue":a[41]||(a[41]=d=>P.value=d)},null,512),[[wt,P.value]]),a[83]||(a[83]=Y(" 手动做旧 "))]),y.value?(St(),ss("label",ra,[a[84]||(a[84]=Y(" 做旧强度: ")),H(C("input",{type:"range","onUpdate:modelValue":a[42]||(a[42]=d=>b.value=d),min:"0",max:"100",step:"1"},null,512),[[$,b.value,void 0,{number:!0}]])])):Ls("",!0),C("button",{onClick:a[43]||(a[43]=d=>x(!1,!0))},"刷新做旧")])]),C("canvas",{ref_key:"stampCanvas",ref:s,width:"600",height:"600"},null,512)])]))}}),or=(e,t)=>{const s=e.__vccOpts||e;for(const[n,i]of t)s[n]=i;return s},aa=or(la,[["__scopeId","data-v-e692db2a"]]),ua=Oi({__name:"App",setup(e){return(t,s)=>(St(),er(aa))}}),fa=or(ua,[["__scopeId","data-v-16a1c733"]]);Ll(fa).mount("#app"); +**/let Xs;const Nn=typeof window<"u"&&window.trustedTypes;if(Nn)try{Xs=Nn.createPolicy("vue",{createHTML:e=>e})}catch{}const ir=Xs?e=>Xs.createHTML(e):e=>e,fl="http://www.w3.org/2000/svg",cl="http://www.w3.org/1998/Math/MathML",Ye=typeof document<"u"?document:null,jn=Ye&&Ye.createElement("template"),dl={insert:(e,t,s)=>{t.insertBefore(e,s||null)},remove:e=>{const t=e.parentNode;t&&t.removeChild(e)},createElement:(e,t,s,n)=>{const i=t==="svg"?Ye.createElementNS(fl,e):t==="mathml"?Ye.createElementNS(cl,e):s?Ye.createElement(e,{is:s}):Ye.createElement(e);return e==="select"&&n&&n.multiple!=null&&i.setAttribute("multiple",n.multiple),i},createText:e=>Ye.createTextNode(e),createComment:e=>Ye.createComment(e),setText:(e,t)=>{e.nodeValue=t},setElementText:(e,t)=>{e.textContent=t},parentNode:e=>e.parentNode,nextSibling:e=>e.nextSibling,querySelector:e=>Ye.querySelector(e),setScopeId(e,t){e.setAttribute(t,"")},insertStaticContent(e,t,s,n,i,r){const o=s?s.previousSibling:t.lastChild;if(i&&(i===r||i.nextSibling))for(;t.insertBefore(i.cloneNode(!0),s),!(i===r||!(i=i.nextSibling)););else{jn.innerHTML=ir(n==="svg"?`${e}`:n==="mathml"?`${e}`:e);const l=jn.content;if(n==="svg"||n==="mathml"){const u=l.firstChild;for(;u.firstChild;)l.appendChild(u.firstChild);l.removeChild(u)}t.insertBefore(l,s)}return[o?o.nextSibling:t.firstChild,s?s.previousSibling:t.lastChild]}},hl=Symbol("_vtc");function pl(e,t,s){const n=e[hl];n&&(t=(t?[t,...n]:[...n]).join(" ")),t==null?e.removeAttribute("class"):s?e.setAttribute("class",t):e.className=t}const $n=Symbol("_vod"),ml=Symbol("_vsh"),gl=Symbol(""),vl=/(^|;)\s*display\s*:/;function bl(e,t,s){const n=e.style,i=se(s);let r=!1;if(s&&!i){if(t)if(se(t))for(const o of t.split(";")){const l=o.slice(0,o.indexOf(":")).trim();s[l]==null&&ls(n,l,"")}else for(const o in t)s[o]==null&&ls(n,o,"");for(const o in s)o==="display"&&(r=!0),ls(n,o,s[o])}else if(i){if(t!==s){const o=n[gl];o&&(s+=";"+o),n.cssText=s,r=vl.test(s)}}else t&&e.removeAttribute("style");$n in e&&(e[$n]=r?n.display:"",e[ml]&&(n.display="none"))}const Bn=/\s*!important$/;function ls(e,t,s){if(U(s))s.forEach(n=>ls(e,t,n));else if(s==null&&(s=""),t.startsWith("--"))e.setProperty(t,s);else{const n=yl(e,t);Bn.test(s)?e.setProperty(vt(n),s.replace(Bn,""),"important"):e[n]=s}}const kn=["Webkit","Moz","ms"],Vs={};function yl(e,t){const s=Vs[t];if(s)return s;let n=pt(t);if(n!=="filter"&&n in e)return Vs[t]=n;n=si(n);for(let i=0;iDs||(Tl.then(()=>Ds=0),Ds=Date.now());function Ml(e,t){const s=n=>{if(!n._vts)n._vts=Date.now();else if(n._vts<=s.attached)return;je(_l(n,s.value),t,5,[n])};return s.value=e,s.attached=Pl(),s}function _l(e,t){if(U(t)){const s=e.stopImmediatePropagation;return e.stopImmediatePropagation=()=>{s.call(e),e._stopped=!0},t.map(n=>i=>!i._stopped&&n&&n(i))}else return t}const qn=e=>e.charCodeAt(0)===111&&e.charCodeAt(1)===110&&e.charCodeAt(2)>96&&e.charCodeAt(2)<123,El=(e,t,s,n,i,r)=>{const o=i==="svg";t==="class"?pl(e,n,o):t==="style"?bl(e,s,n):ps(t)?qs(t)||xl(e,t,s,n,r):(t[0]==="."?(t=t.slice(1),!0):t[0]==="^"?(t=t.slice(1),!1):Rl(e,t,n,o))?(Cl(e,t,n),!e.tagName.includes("-")&&(t==="value"||t==="checked"||t==="selected")&&Kn(e,t,n,o,r,t!=="value")):(t==="true-value"?e._trueValue=n:t==="false-value"&&(e._falseValue=n),Kn(e,t,n,o))};function Rl(e,t,s,n){if(n)return!!(t==="innerHTML"||t==="textContent"||t in e&&qn(t)&&H(s));if(t==="spellcheck"||t==="draggable"||t==="translate"||t==="form"||t==="list"&&e.tagName==="INPUT"||t==="type"&&e.tagName==="TEXTAREA")return!1;if(t==="width"||t==="height"){const i=e.tagName;if(i==="IMG"||i==="VIDEO"||i==="CANVAS"||i==="SOURCE")return!1}return qn(t)&&se(s)?!1:!!(t in e||e._isVueCE&&(/[A-Z]/.test(t)||!se(s)))}const hs=e=>{const t=e.props["onUpdate:modelValue"]||!1;return U(t)?s=>ns(t,s):t};function Ol(e){e.target.composing=!0}function Jn(e){const t=e.target;t.composing&&(t.composing=!1,t.dispatchEvent(new Event("input")))}const Et=Symbol("_assign"),$={created(e,{modifiers:{lazy:t,trim:s,number:n}},i){e[Et]=hs(i);const r=n||i.props&&i.props.type==="number";dt(e,t?"change":"input",o=>{if(o.target.composing)return;let l=e.value;s&&(l=l.trim()),r&&(l=Us(l)),e[Et](l)}),s&&dt(e,"change",()=>{e.value=e.value.trim()}),t||(dt(e,"compositionstart",Ol),dt(e,"compositionend",Jn),dt(e,"change",Jn))},mounted(e,{value:t}){e.value=t??""},beforeUpdate(e,{value:t,oldValue:s,modifiers:{lazy:n,trim:i,number:r}},o){if(e[Et]=hs(o),e.composing)return;const l=(r||e.type==="number")&&!/^0\d/.test(e.value)?Us(e.value):e.value,u=t??"";l!==u&&(document.activeElement===e&&e.type!=="range"&&(n&&t===s||i&&e.value.trim()===u)||(e.value=u))}},wt={deep:!0,created(e,t,s){e[Et]=hs(s),dt(e,"change",()=>{const n=e._modelValue,i=Il(e),r=e.checked,o=e[Et];if(U(n)){const l=oi(n,i),u=l!==-1;if(r&&!u)o(n.concat(i));else if(!r&&u){const p=[...n];p.splice(l,1),o(p)}}else if(ms(n)){const l=new Set(n);r?l.add(i):l.delete(i),o(l)}else o(rr(e,r))})},mounted:zn,beforeUpdate(e,t,s){e[Et]=hs(s),zn(e,t,s)}};function zn(e,{value:t,oldValue:s},n){e._modelValue=t;let i;U(t)?i=oi(t,n.props.value)>-1:ms(t)?i=t.has(n.props.value):i=vs(t,rr(e,!0)),e.checked!==i&&(e.checked=i)}function Il(e){return"_value"in e?e._value:e.value}function rr(e,t){const s=t?"_trueValue":"_falseValue";return s in e?e[s]:t}const Al=re({patchProp:El},dl);let Zn;function Fl(){return Zn||(Zn=Vo(Al))}const Ll=(...e)=>{const t=Fl().createApp(...e),{mount:s}=t;return t.mount=n=>{const i=Dl(n);if(!i)return;const r=t._component;!H(r)&&!r.render&&!r.template&&(r.template=i.innerHTML),i.nodeType===1&&(i.textContent="");const o=s(i,!1,Vl(i));return i instanceof Element&&(i.removeAttribute("v-cloak"),i.setAttribute("data-v-app","")),o},t};function Vl(e){if(e instanceof SVGElement)return"svg";if(typeof MathMLElement=="function"&&e instanceof MathMLElement)return"mathml"}function Dl(e){return se(e)?document.querySelector(e):e}const Qe=80,Ve=80;class Ul{constructor(t,s){k(this,"scale",1);k(this,"offsetX",0);k(this,"offsetY",0);k(this,"primaryColor","#ff0000");k(this,"mmToPixel");k(this,"canvasCtx");k(this,"offscreenCanvas");k(this,"canvas");k(this,"stampOffsetX",0);k(this,"stampOffsetY",0);k(this,"agingIntensity",50);k(this,"ruler",{showRuler:!0,showFullRuler:!0});k(this,"drawStar",{svgPath:"M 0 -1 L 0.588 0.809 L -0.951 -0.309 L 0.951 -0.309 L -0.588 0.809 Z",drawStar:!1,starDiameter:14,starPositionY:0,scaleToSmallStar:!1});k(this,"securityPattern",{openSecurityPattern:!0,securityPatternWidth:.15,securityPatternLength:3,securityPatternCount:5,securityPatternAngleRange:40,securityPatternParams:[]});k(this,"company",{companyName:"印章绘制有限责任公司",compression:1,borderOffset:1,textDistributionFactor:20,fontFamily:"SimSun",fontHeight:4.2});k(this,"taxNumber",{code:"000000000000000000",compression:.7,fontHeight:3.7,fontFamily:"Arial",fontWidth:1.3,letterSpacing:8,positionY:0,totalWidth:26});k(this,"stampCode",{code:"1234567890",compression:1,fontHeight:1.2,fontFamily:"Arial",borderOffset:1,fontWidth:1.2,textDistributionFactor:50});k(this,"stampType",{stampType:"发票专用章",fontHeight:4.6,fontWidth:3,compression:.75,letterSpacing:0,positionY:-3});k(this,"agingEffect",{applyAging:!1,agingIntensity:50,agingEffectParams:[]});k(this,"innerCircle",{drawInnerCircle:!0,innerCircleLineWidth:.5,innerCircleLineRadiusX:16,innerCircleLineRadiusY:12});k(this,"outThinCircle",{drawInnerCircle:!0,innerCircleLineWidth:.2,innerCircleLineRadiusX:36,innerCircleLineRadiusY:27});k(this,"drawStampConfigs",{ruler:this.ruler,drawStar:this.drawStar,securityPattern:this.securityPattern,company:this.company,stampCode:this.stampCode,width:40,height:30,stampType:this.stampType,primaryColor:this.primaryColor,borderWidth:1,refreshSecurityPattern:!1,refreshOld:!1,taxNumber:this.taxNumber,agingEffect:this.agingEffect,shouldDrawRuler:!0,innerCircle:this.innerCircle,outThinCircle:this.outThinCircle,openManualAging:!1});k(this,"cvReady",!1);k(this,"isDragging",!1);k(this,"dragStartX",0);k(this,"dragStartY",0);k(this,"onMouseUp",()=>{this.isDragging=!1,this.refreshStamp(!1,!1)});k(this,"onCanvasClick",t=>{this.canvas});k(this,"onMouseLeave",t=>{this.isDragging=!1,this.refreshStamp()});k(this,"onMouseDown",t=>{this.isDragging=!0,this.dragStartX=t.clientX-this.stampOffsetX*this.mmToPixel,this.dragStartY=t.clientY-this.stampOffsetY*this.mmToPixel});k(this,"onMouseMove",t=>{if(!this.drawStampConfigs.openManualAging)if(this.isDragging){const s=(t.clientX-this.dragStartX)/this.mmToPixel,n=(t.clientY-this.dragStartY)/this.mmToPixel;this.stampOffsetX=Math.round(s*10)/10,this.stampOffsetY=Math.round(n*10)/10,this.refreshStamp()}else{const s=this.canvas.getBoundingClientRect(),n=t.clientX-s.left,i=t.clientY-s.top,r=Math.round((n-Qe)/this.mmToPixel*10)/10,o=Math.round((i-Ve)/this.mmToPixel*10)/10;this.refreshStamp(),this.highlightRulerPosition(this.canvasCtx,r,o),this.drawCrossLines(n,i)}});k(this,"highlightRulerPosition",(t,s,n)=>{const i=s*this.mmToPixel+Qe,r=n*this.mmToPixel+Ve;t.fillStyle=this.drawStampConfigs.primaryColor,t.fillRect(Qe,r-1,this.canvas.width-Qe,2),t.fillRect(i-1,Ve,2,this.canvas.height-Ve),t.fillStyle="black",t.font="bold 12px Arial",t.textAlign="left",t.textBaseline="top";const o=s/this.scale,l=n/this.scale;t.fillText(`${o.toFixed(1)}mm, ${l.toFixed(1)}mm, scale: ${this.scale.toFixed(2)}`,Qe+5,Ve+5)});k(this,"drawCrossLines",(t,s)=>{const n=this.offscreenCanvas;if(!n)return;const i=n.getContext("2d");if(!i)return;i.clearRect(0,0,n.width,n.height),i.beginPath(),i.strokeStyle="rgba(255, 0, 0, 0.5)",i.lineWidth=1,i.moveTo(Qe,s),i.lineTo(n.width,s),i.moveTo(t,Ve),i.lineTo(t,n.height),i.stroke();const r=this.canvas;if(r){const o=r.getContext("2d");o&&o.drawImage(n,0,0)}});if(!t)throw new Error("Canvas is null");const n=t.getContext("2d");if(!n)throw new Error("Failed to get canvas context");this.canvasCtx=n,this.mmToPixel=s,this.canvas=t,this.offscreenCanvas=document.createElement("canvas"),this.canvas&&this.offscreenCanvas&&(this.offscreenCanvas.width=t.width,this.offscreenCanvas.height=t.height),this.addCanvasListener(),this.initOpenCV()}initOpenCV(){typeof cv<"u"?(this.cvReady=!0,console.log("OpenCV.js 已加载")):(console.log("等待 OpenCV.js 加载..."),document.addEventListener("opencv-ready",()=>{this.cvReady=!0,console.log("OpenCV.js 已加载")}))}getDrawConfigs(){return this.drawStampConfigs}addManualAgingEffect(t,s,n){console.log("手动做旧 1",t,s,this.drawStampConfigs.agingEffect.agingEffectParams);const i=1*this.mmToPixel,r=t-this.stampOffsetX*this.mmToPixel,o=s-this.stampOffsetY*this.mmToPixel;for(let l=0;l<10;l++)this.drawStampConfigs.agingEffect.agingEffectParams.push({x:r,y:o,noiseSize:Math.random()*3+1,noise:Math.random()*200*n,strongNoiseSize:Math.random()*5+2,strongNoise:Math.random()*250*n+5,fade:Math.random()*50*n,seed:Math.random()});this.refreshStamp(!1,!1),this.canvasCtx.save(),this.canvasCtx.globalCompositeOperation="destination-out",this.canvasCtx.beginPath(),this.canvasCtx.arc(t,s,i,0,Math.PI*2,!0),this.canvasCtx.fillStyle="rgba(255, 255, 255, 0.5)",this.canvasCtx.fill(),this.canvasCtx.restore()}setDrawConfigs(t){this.drawStampConfigs=t}addCanvasListener(){this.canvas.addEventListener("mousemove",t=>{if(this.drawStampConfigs.openManualAging&&t.buttons===1){const s=this.canvas.getBoundingClientRect(),n=t.clientX-s.left,i=t.clientY-s.top,r=this.drawStampConfigs.agingEffect.agingIntensity/100;this.addManualAgingEffect(n,i,r)}else this.onMouseMove(t)}),this.canvas.addEventListener("mouseleave",t=>{this.onMouseLeave(t)}),this.canvas.addEventListener("mousedown",t=>{if(this.onMouseDown(t),this.drawStampConfigs.openManualAging){const s=this.canvas.getBoundingClientRect(),n=t.clientX-s.left,i=t.clientY-s.top,r=this.drawStampConfigs.agingEffect.agingIntensity/100;this.addManualAgingEffect(n,i,r)}}),this.canvas.addEventListener("mouseup",t=>{this.onMouseUp()}),this.canvas.addEventListener("click",t=>{this.onCanvasClick(t)}),this.canvas.addEventListener("wheel",t=>{if(t.ctrlKey){t.preventDefault();const s=t.deltaY>0?.9:1.1;this.zoomCanvas(t.offsetX,t.offsetY,s)}})}zoomCanvas(t,s,n){const i=this.scale;this.scale*=n,this.scale=Math.max(.1,Math.min(5,this.scale)),this.offsetX=t-(t-this.offsetX)*(this.scale/i),this.offsetY=s-(s-this.offsetY)*(this.scale/i),this.refreshStamp()}extractRedStamp(t){return this.cvReady?this.extractRedStampWithColor(t,this.primaryColor):(console.error("OpenCV.js 未加载"),null)}extractStampWithColor(t,s,n){return this.cvReady?this.extractStampWithColor(t,s,n):(console.error("OpenCV.js 未加载"),null)}hexToRgba(t){let s=parseInt(t.slice(1,3),16),n=parseInt(t.slice(3,5),16),i=parseInt(t.slice(5,7),16),r=255;return t.length===9&&(r=parseInt(t.slice(7,9),16)),[s,n,i,r]}extractRedStampWithFile(t){return new Promise((s,n)=>{const i=new Image;i.onload=()=>{const r=this.extractRedStampWithColor(i,this.primaryColor);s(r)},i.onerror=r=>{console.error("图片加载失败",r),n(new Error("图片加载失败"))},i.src=URL.createObjectURL(t)})}extractStampWithFile(t,s,n){return new Promise((i,r)=>{const o=new Image;o.onload=()=>{const l=this.extractStampWithColorImpl(o,s,n);i(l)},o.onerror=l=>{console.error("图片加载失败",l),r(new Error("图片加载失败"))},o.src=URL.createObjectURL(t)})}extractRedStampWithColor(t,s){if(this.cvReady){const n=t.width,i=t.height;console.log("图片宽度:",n,"图片高度:",i);let r=cv.imread(t),o=new cv.Mat,l=new cv.Mat;cv.cvtColor(r,o,cv.COLOR_RGBA2RGB),cv.cvtColor(o,o,cv.COLOR_RGB2HSV);let u=new cv.Mat(o.rows,o.cols,o.type(),[0,100,100,0]),p=new cv.Mat(o.rows,o.cols,o.type(),[10,255,255,255]),c=new cv.Mat(o.rows,o.cols,o.type(),[160,100,100,0]),m=new cv.Mat(o.rows,o.cols,o.type(),[180,255,255,255]),g=new cv.Mat,y=new cv.Mat;cv.inRange(o,u,p,g),cv.inRange(o,c,m,y),cv.add(g,y,l);const P=this.hexToRgba(s);console.log("dstColor:",P);let b=new cv.Mat(r.rows,r.cols,r.type(),P);b.copyTo(o,l);const A=document.createElement("canvas");A.width=o.cols,A.height=o.rows,cv.imshow(A,o);let I=A.toDataURL("image/png"),F=document.createElement("a");return F.download="extracted_red_image.png",F.href=I,F.click(),r.delete(),o.delete(),l.delete(),g.delete(),y.delete(),u.delete(),p.delete(),c.delete(),m.delete(),b.delete(),o}else return console.error("OpenCV.js 未加载"),t}extractStampWithColorImpl(t,s="#ff0000",n="#ff0000"){if(this.cvReady){const i=t.width,r=t.height;console.log("图片宽度:",i,"图片高度:",r);let o=cv.imread(t),l=new cv.Mat,u=new cv.Mat;cv.cvtColor(o,l,cv.COLOR_RGBA2RGB),cv.cvtColor(l,l,cv.COLOR_RGB2HSV);const p=this.hexToRgba(s),c=cv.matFromArray(1,1,cv.CV_8UC3,[p[0],p[1],p[2]]);cv.cvtColor(c,c,cv.COLOR_RGB2HSV);const m=c.data32F;let g,y;if(s.toLowerCase()==="#ff0000")g=new cv.Mat(l.rows,l.cols,l.type(),[0,100,100,0]),y=new cv.Mat(l.rows,l.cols,l.type(),[10,255,255,255]);else if(s.toLowerCase()==="#00ff00")g=new cv.Mat(l.rows,l.cols,l.type(),[60,100,100,0]),y=new cv.Mat(l.rows,l.cols,l.type(),[80,255,255,255]);else if(s.toLowerCase()==="#000000")g=new cv.Mat(l.rows,l.cols,l.type(),[0,0,0,0]),y=new cv.Mat(l.rows,l.cols,l.type(),[180,255,30,255]);else{const V=m[0],E=10;g=new cv.Mat(l.rows,l.cols,l.type(),[Math.max(0,V-E),100,100,0]),y=new cv.Mat(l.rows,l.cols,l.type(),[Math.min(180,V+E),255,255,255])}cv.inRange(l,g,y,u);const P=this.hexToRgba(n);console.log("dstColor:",P);let b=new cv.Mat(o.rows,o.cols,cv.CV_8UC4,[0,0,0,0]),A=new cv.Mat(o.rows,o.cols,cv.CV_8UC4,[...P.slice(0,3),255]);A.copyTo(b,u);const I=document.createElement("canvas");I.width=b.cols,I.height=b.rows,cv.imshow(I,b);let F=I.toDataURL("image/png");return o.delete(),l.delete(),u.delete(),g.delete(),y.delete(),c.delete(),A.delete(),b.delete(),F}else return console.error("OpenCV.js 未加载"),t}saveImage(t,s){let n=document.createElement("canvas");n.width=s.cols,n.height=s.rows,t.imshow(n,s);let i=n.toDataURL("image/png"),r=document.createElement("a");r.download="extracted_red_image.png",r.href=i,r.click()}parseSVGPath(t){const s=[],n=/([MmLlHhVvCcSsQqTtAaZz])|(-?\d*\.?\d+)/g;let i,r="",o=[];for(;(i=n.exec(t))!==null;)i[1]?(r&&(s.push({command:r,params:o}),o=[]),r=i[1]):i[2]&&o.push(parseFloat(i[2]));return r&&s.push({command:r,params:o}),s}scaleSVGPathTo10mm(t){const s=this.parseSVGPath(t);let n=1/0,i=1/0,r=-1/0,o=-1/0,l=0,u=0;s.forEach(({command:y,params:P})=>{switch(y){case"M":case"L":case"C":case"S":case"Q":case"T":for(let b=0;b{const b=P.map(A=>A*m);return{command:y,params:b}});return this.convertPathDataToString(g)}convertPathDataToString(t){return t.map(({command:s,params:n})=>s+n.map(i=>i.toFixed(2)).join(" ")).join(" ")}drawSVGPath(t,s,n,i,r=1){t.save(),t.translate(n,i),t.scale(r,r);const o=new Path2D(s);t.fillStyle=this.primaryColor,t.fill(o),t.restore()}drawSVGPath2(t,s,n,i,r=1){t.save(),t.translate(n,i),t.scale(r,r),t.beginPath();let o=0,l=0,u=0,p=0,c=0,m=0;s.forEach(({command:g,params:y})=>{const P=y.length;switch(g){case"M":case"m":g==="M"?(o=y[0],l=y[1]):(o+=y[0],l+=y[1]),t.moveTo(o,l),u=o,p=l;break;case"L":case"l":for(let b=0;bee%2===0?te+o:te+l);t.bezierCurveTo(A,I,F,V,E,j),c=F,m=V,o=E,l=j}break;case"S":case"s":for(let b=0;bee%2===0?te+o:te+l);const E=o+(o-c),j=l+(l-m);t.bezierCurveTo(E,j,A,I,F,V),c=A,m=I,o=F,l=V}break;case"Q":case"q":for(let b=0;bj%2===0?E+o:E+l);t.quadraticCurveTo(A,I,F,V),c=A,m=I,o=F,l=V}break;case"T":case"t":for(let b=0;b{console.log("svg content img loaded",n,i,u,p,c),t.save(),t.translate(n,i),t.scale(r,r),t.drawImage(c,-u/2,-p/2,u,p),t.restore(),URL.revokeObjectURL(g)},c.src=g,c.onerror=y=>{console.error("加载SVG图像时出错:",y)}}drawStampType(t,s,n,i,r){const o=s.fontHeight*this.mmToPixel,l=s.letterSpacing,u=s.positionY;t.save(),t.font=`${o}px SimSun`,t.fillStyle=this.primaryColor,t.textAlign="center",t.textBaseline="middle";const p=i+r*.5+u*this.mmToPixel;t.save(),t.translate(n,p);const c=s.stampType.split(""),m=c.map(P=>t.measureText(P).width);let y=-(m.reduce((P,b)=>P+b,0)+(c.length-1)*l*this.mmToPixel)/2;t.scale(this.drawStampConfigs.stampType.compression,1),c.forEach((P,b)=>{t.fillText(P,y+m[b]/2,0),y+=m[b]+l*this.mmToPixel}),t.restore()}drawSecurityPattern(t,s,n,i,r,o){if(!this.securityPattern.openSecurityPattern)return;t.save(),t.strokeStyle="#FFFFFF",t.lineWidth=this.securityPattern.securityPatternWidth*this.mmToPixel,t.globalCompositeOperation="destination-out";const l=this.securityPattern.securityPatternAngleRange*Math.PI/180;if(o||this.drawStampConfigs.securityPattern.securityPatternParams.length===0){this.drawStampConfigs.securityPattern.securityPatternParams=[];for(let u=0;u{const c=s+i*Math.cos(u),m=n+r*Math.sin(u),g=this.securityPattern.securityPatternLength*this.mmToPixel,y=c-g/2*Math.cos(p),P=m-g/2*Math.sin(p),b=c+g/2*Math.cos(p),A=m+g/2*Math.sin(p);t.beginPath(),t.moveTo(y,P),t.lineTo(b,A),t.stroke()}),t.restore()}drawEllipse(t,s,n,i,r,o,l){t.beginPath(),t.ellipse(s,n,i,r,0,0,Math.PI*2),t.strokeStyle=l,t.lineWidth=o,t.stroke()}drawCompanyName(t,s,n,i,r,o){const l=s.fontHeight*this.mmToPixel;t.save(),t.font=`${l}px ${s.fontFamily}`,t.fillStyle=this.primaryColor,t.textAlign="center",t.textBaseline="bottom";const u=s.companyName.split(""),p=u.length,c=s.borderOffset*this.mmToPixel,m=Math.PI*(1+p/s.textDistributionFactor),g=Math.PI+(Math.PI-m)/2,y=m/p;u.forEach((P,b)=>{const A=g+y*(b+.5),I=n+Math.cos(A)*(r-l-c),F=i+Math.sin(A)*(o-l-c);t.save(),t.translate(I,F),t.rotate(A+Math.PI/2),t.scale(s.compression,1),t.fillText(P,0,0),t.restore()}),t.restore()}drawCode(t,s,n,i,r,o){const l=s.fontHeight*this.mmToPixel,u=s.code;t.save(),t.font=`${l}px ${s.fontFamily}`,t.fillStyle=this.primaryColor,t.textAlign="center",t.textBaseline="middle";const p=u.split(""),c=p.length,m=Math.PI*((1+c)/s.textDistributionFactor),g=Math.PI/2+m/2,y=m/(c-1);p.forEach((P,b)=>{const A=g-y*b,I=n+Math.cos(A)*(r-l/2-s.borderOffset*this.mmToPixel),F=i+Math.sin(A)*(o-l/2-s.borderOffset*this.mmToPixel);t.save(),t.translate(I,F),t.rotate(A-Math.PI/2),t.scale(s.compression,1),t.fillText(P,0,0),t.restore()}),t.restore()}drawTaxNumber(t,s,n,i){const r=s.fontHeight*this.mmToPixel,o=s.totalWidth*this.mmToPixel,l=s.positionY*this.mmToPixel+.3;t.save(),t.font=`${r}px ${s.fontFamily}`,t.fillStyle=this.primaryColor,t.textAlign="center",t.textBaseline="middle";const u=s.code.split(""),p=u.length,c=this.drawStampConfigs.taxNumber.letterSpacing*this.mmToPixel,g=(o*this.drawStampConfigs.taxNumber.compression-(p-1)*c)/p,y=p*g+(p-1)*c,P=n-y/2+g/2,b=i+l*this.mmToPixel;u.forEach((A,I)=>{const F=P+I*(g+c);t.save(),t.translate(F,b),t.scale(this.drawStampConfigs.taxNumber.compression,1.35),t.fillText(A,0,0),t.restore()}),t.restore()}addAgingEffect(t,s,n,i=!1){if(!this.drawStampConfigs.agingEffect.applyAging)return;const r=t.getImageData(0,0,s,n),o=r.data,l=s/(2*this.scale)+this.stampOffsetX*this.mmToPixel/this.scale,u=n/(2*this.scale)+this.stampOffsetY*this.mmToPixel/this.scale,p=Math.max(s,n)/2*this.mmToPixel/this.scale;if(i||this.drawStampConfigs.agingEffect.agingEffectParams.length===0){this.drawStampConfigs.agingEffect.agingEffectParams=[];for(let c=0;c200&&o[g+1]<50&&o[g+2]<50){const P=this.drawStampConfigs.agingEffect.agingIntensity/100,b=Math.random();this.drawStampConfigs.agingEffect.agingEffectParams.push({x:m-this.stampOffsetX*this.mmToPixel,y:c-this.stampOffsetY*this.mmToPixel,noiseSize:Math.random()*3+1,noise:Math.random()*200*P,strongNoiseSize:Math.random()*5+2,strongNoise:Math.random()*250*P+5,fade:Math.random()*50*P,seed:b})}}}this.drawStampConfigs.agingEffect.agingEffectParams.forEach(c=>{const{x:m,y:g,noiseSize:y,noise:P,strongNoiseSize:b,strongNoise:A,fade:I,seed:F}=c,V=m+this.stampOffsetX*this.mmToPixel,E=g+this.stampOffsetY*this.mmToPixel,j=(Math.round(E)*s+Math.round(V))*4;F<.4&&this.addCircularNoise(o,s,V,E,y,P,!0),F<.05&&this.addCircularNoise(o,s,V,E,b,A,!0),F<.2&&(o[j+3]=Math.max(0,o[j+3]-I))}),t.putImageData(r,0,0)}addCircularNoise(t,s,n,i,r,o,l=!1){const u=r*r/4;for(let p=-r/2;p=0&&y{const s=document.createElement("canvas");s.width=t,s.height=t;const n=s.getContext("2d");if(!n)return;n.clearRect(0,0,t,t);const i=(Math.max(this.drawStampConfigs.width,this.drawStampConfigs.height)+2)*this.mmToPixel,r=(this.canvas.width-i)/2+this.stampOffsetX*this.mmToPixel,o=(this.canvas.height-i)/2+this.stampOffsetY*this.mmToPixel,l=t*.01,u=t-2*l;n.drawImage(this.canvas,r,o,i,i,l,l,u,u),this.drawStampConfigs.agingEffect.applyAging&&this.addAgingEffect(n,t,t,!1);const p=s.toDataURL("image/png"),c=document.createElement("a");c.href=p,c.download="印章.png",document.body.appendChild(c),c.click(),document.body.removeChild(c),this.drawStampConfigs.shouldDrawRuler=!0,this.refreshStamp()},50)}refreshStamp(t=!1,s=!1){this.canvasCtx.clearRect(0,0,this.canvas.width,this.canvas.height),this.canvasCtx.save(),this.canvasCtx.translate(this.offsetX,this.offsetY),this.canvasCtx.scale(this.scale,this.scale);const n=this.canvas.width/2/this.scale,i=this.canvas.height/2/this.scale,r=this.mmToPixel,o=(this.drawStampConfigs.width-this.drawStampConfigs.borderWidth)/2,l=(this.drawStampConfigs.height-this.drawStampConfigs.borderWidth)/2,u=this.stampOffsetX*this.mmToPixel,p=this.stampOffsetY*this.mmToPixel,c=n+u,m=i+p;this.drawStamp(this.canvasCtx,c,m,o*r,l*r,this.drawStampConfigs.borderWidth*r,this.drawStampConfigs.primaryColor,t,s),this.canvasCtx.restore(),this.drawStampConfigs.shouldDrawRuler&&(this.drawRuler(this.canvasCtx,this.canvas.width,Ve,!0),this.drawRuler(this.canvasCtx,this.canvas.height,Ve,!1),this.drawFullRuler(this.canvasCtx,this.canvas.width,this.canvas.height))}resetZoom(){this.scale=1,this.offsetX=0,this.offsetY=0,this.refreshStamp()}drawStamp(t,s,n,i,r,o,l,u=!1,p=!1){t.clearRect(0,0,this.canvas.width,this.canvas.height);const c=this.offscreenCanvas;c.width=this.canvas.width,c.height=this.canvas.height;const m=c.getContext("2d");if(m){if(m.beginPath(),m.ellipse(s,n,i,r,0,0,Math.PI*2),m.strokeStyle="white",m.lineWidth=o,m.stroke(),m.fillStyle="white",t.fillStyle="white",t.fillRect(0,0,this.canvas.width,this.canvas.height),this.drawEllipse(m,s,n,i,r,o,l),this.drawStampConfigs.innerCircle.drawInnerCircle){const g=this.drawStampConfigs.innerCircle,y=(g.innerCircleLineRadiusX-g.innerCircleLineWidth)/2,P=(g.innerCircleLineRadiusY-g.innerCircleLineWidth)/2;this.drawEllipse(m,s,n,y*this.mmToPixel,P*this.mmToPixel,g.innerCircleLineWidth*this.mmToPixel,this.drawStampConfigs.primaryColor)}if(this.drawStampConfigs.outThinCircle.drawInnerCircle){const g=this.drawStampConfigs.outThinCircle,y=(g.innerCircleLineRadiusX-g.innerCircleLineWidth)/2,P=(g.innerCircleLineRadiusY-g.innerCircleLineWidth)/2;this.drawEllipse(m,s,n,y*this.mmToPixel,P*this.mmToPixel,g.innerCircleLineWidth*this.mmToPixel,this.drawStampConfigs.primaryColor)}this.drawSecurityPattern(m,s,n,i,r,u),this.drawStampConfigs.drawStar.drawStar&&this.drawStarShape(m,this.drawStampConfigs.drawStar,s,n),this.drawCompanyName(m,this.drawStampConfigs.company,s,n,i,r),this.drawStampType(m,this.drawStampConfigs.stampType,s,n,i),this.drawCode(m,this.drawStampConfigs.stampCode,s,n,i,r),this.drawTaxNumber(m,this.drawStampConfigs.taxNumber,s,n),t.save(),t.globalCompositeOperation="source-over",t.fillStyle=l,t.fillRect(0,0,this.canvas.width,this.canvas.height),t.globalCompositeOperation="destination-in",t.drawImage(c,0,0),t.restore(),this.addAgingEffect(t,this.canvas.width,this.canvas.height,p)}}}const Wl={class:"container"},Hl={class:"button-group",style:{position:"sticky",top:"0","z-index":"1000","background-color":"white",padding:"10px"}},Nl={class:"control-group",id:"stamp-settings"},jl={class:"control-group",id:"inner-circle-settings"},$l={class:"checkbox-label"},Bl={class:"control-group",id:"out-thin-circle-settings"},kl={class:"checkbox-label"},Yl={class:"control-group",id:"company-name-settings"},Kl={class:"control-group",id:"bottom-text-settings"},Xl={class:"control-group",id:"code-settings"},Gl={class:"control-group",id:"tax-number-settings"},ql={class:"control-group",id:"star-settings"},Jl={class:"checkbox-label"},zl={key:0},Zl={key:1},Ql={class:"control-group"},ea={class:"canvas-container"},ta={style:{display:"flex","flex-direction":"row","margin-top":"12px"}},sa={class:"control-group"},na={class:"checkbox-label"},ia={class:"checkbox-label"},ra={key:0},oa=10,la=Oi({__name:"DrawStampUtilsDemo",setup(e){const t=D(null),s=D(null),n=D("绘制印章有限责任公司"),i=D("1234567890123"),r=D("000000000000000000"),o=D(4.2),l=D(1.2),u=D(1.2),p=D(20),c=D(1),m=D("#ff0000"),g=D(14),y=D(!1),P=D(!1),b=D(50),A=D(20),I=D(1),F=D(1),V=D(20),E=D("合同专用章"),j=D(4.6),te=D(3),ee=D(0),pe=D(0),Re=D(-5),me=D(1),Te=D(1),Oe=D(1),$e=D(!0),Ot=D(.5),rt=D(.2),ne=D("#FF0000"),J=D(5),K=D(2);D(!1);const ue=D(!1),Pe=D(1),ge=D(.3),ie=D(0),ot=D(!1),bt=D(.5),yt=D(15),Ie=D(12),Be=D(!1),ze=D(.5),lt=D(15),Ae=D(12),qt=()=>{v.saveStampAsPNG(512)},at=D(40),f=D(30),h=()=>{const w=document.createElement("input");w.type="file",w.accept="image/*",w.onchange=a=>{var R;const d=(R=a.target.files)==null?void 0:R[0];d?(console.log("选择了图片",d),v.extractStampWithFile(d,"#ff0000","#ff0000").then(M=>{(L=>{const W=document.createElement("a");W.href=L,W.download="提取的印章.png",document.body.appendChild(W),W.click(),document.body.removeChild(W)})(M),console.log(M)})):console.error("未选择图片")},w.click()};let v;const T=()=>{v=new Ul(s.value,oa)},x=(w=!1,a=!1)=>{v.refreshStamp(w,a)},S=()=>{const w=v.getDrawConfigs(),a=w.agingEffect;a.applyAging=y.value,a.agingIntensity=b.value,w.openManualAging=P.value;const d=w.securityPattern;d.openSecurityPattern=$e.value,d.securityPatternCount=J.value,d.securityPatternWidth=rt.value,d.securityPatternLength=K.value;const R=w.company;R.companyName=n.value,R.textDistributionFactor=A.value,R.borderOffset=I.value,R.fontHeight=o.value,R.compression=me.value;const M=w.taxNumber;M.code=r.value,M.compression=Pe.value,M.positionY=ie.value,M.letterSpacing=ge.value;const O=w.stampType;O.stampType=E.value,O.fontHeight=j.value,O.fontWidth=te.value,O.letterSpacing=ee.value,O.positionY=Re.value,O.compression=Te.value;const L=w.stampCode;L.code=i.value,L.compression=Oe.value,L.fontHeight=l.value,L.fontWidth=u.value,L.borderOffset=F.value,L.textDistributionFactor=V.value,w.primaryColor=m.value,w.borderWidth=c.value,w.width=at.value,w.height=f.value;const W=w.drawStar;W.drawStar=ue.value,W.starDiameter=g.value,W.starPositionY=pe.value;const X=w.innerCircle;X.drawInnerCircle=ot.value,X.innerCircleLineWidth=bt.value,X.innerCircleLineRadiusX=yt.value,X.innerCircleLineRadiusY=Ie.value;const B=w.outThinCircle;B.drawInnerCircle=Be.value,B.innerCircleLineWidth=ze.value,B.innerCircleLineRadiusX=lt.value,B.innerCircleLineRadiusY=Ae.value,x()},_=()=>{const w=v.getDrawConfigs(),a=w.company;n.value=a.companyName,o.value=a.fontHeight,me.value=a.compression,A.value=a.textDistributionFactor,I.value=a.borderOffset;const d=w.stampCode;i.value=d.code,l.value=d.fontHeight,u.value=d.fontWidth,V.value=d.textDistributionFactor,F.value=d.borderOffset;const R=w.taxNumber;r.value=R.code,Pe.value=R.compression,ge.value=R.letterSpacing,ie.value=R.positionY;const M=w.stampType;E.value=M.stampType,j.value=M.fontHeight,te.value=M.fontWidth,ee.value=M.letterSpacing,Re.value=M.positionY,ue.value=w.drawStar.drawStar,g.value=w.drawStar.starDiameter,pe.value=w.drawStar.starPositionY,m.value=w.primaryColor,P.value=w.openManualAging};return Li(()=>{T(),_(),x()}),rs([n,i,o,l,p,c,m,g,V,A,I,F,b,E,j,ee,Re,r,y,b,me,Te,Oe,ee,ne,Ot,ne,$e,J,K,rt,at,f,ue,pe,Pe,ge,ie,g,ot,bt,yt,Ie,ze,lt,Ae,Be,P],()=>{S()}),(w,a)=>(St(),ss("div",Wl,[C("div",{class:"editor-controls",ref_key:"editorControls",ref:t},[C("div",Hl,[C("button",{onClick:a[0]||(a[0]=d=>h())},"提取印章"),C("button",{onClick:qt},"保存印章")]),C("div",Nl,[a[58]||(a[58]=C("h3",null,"印章基本设置",-1)),C("label",null,[a[44]||(a[44]=Y("印章宽度 (mm): ")),N(C("input",{type:"number","onUpdate:modelValue":a[1]||(a[1]=d=>at.value=d),min:"1",max:"50",step:"1"},null,512),[[$,at.value,void 0,{number:!0}]])]),C("label",null,[a[45]||(a[45]=Y("印章高度 (mm): ")),N(C("input",{type:"number","onUpdate:modelValue":a[2]||(a[2]=d=>f.value=d),min:"1",max:"50",step:"1"},null,512),[[$,f.value,void 0,{number:!0}]])]),C("label",null,[a[46]||(a[46]=Y("圆形边框宽度 (mm): ")),N(C("input",{type:"number",step:"0.1","onUpdate:modelValue":a[3]||(a[3]=d=>c.value=d)},null,512),[[$,c.value,void 0,{number:!0}]])]),C("label",null,[a[47]||(a[47]=Y("圆形边框颜色: ")),N(C("input",{type:"color","onUpdate:modelValue":a[4]||(a[4]=d=>m.value=d)},null,512),[[$,m.value]])]),C("div",jl,[a[52]||(a[52]=C("h3",null,"内圈圆形设置",-1)),C("label",$l,[N(C("input",{type:"checkbox","onUpdate:modelValue":a[5]||(a[5]=d=>ot.value=d)},null,512),[[wt,ot.value]]),a[48]||(a[48]=Y(" 绘制内圈圆形 "))]),C("label",null,[a[49]||(a[49]=Y(" 内圈圆形线宽 (mm): ")),N(C("input",{type:"number","onUpdate:modelValue":a[6]||(a[6]=d=>bt.value=d),min:"0.1",max:"2",step:"0.1"},null,512),[[$,bt.value,void 0,{number:!0}]])]),C("label",null,[a[50]||(a[50]=Y(" 内圈圆形宽度 (mm): ")),N(C("input",{type:"number","onUpdate:modelValue":a[7]||(a[7]=d=>yt.value=d),min:"1",max:"50",step:"0.5"},null,512),[[$,yt.value,void 0,{number:!0}]])]),C("label",null,[a[51]||(a[51]=Y(" 内圈圆形高度 (mm): ")),N(C("input",{type:"number","onUpdate:modelValue":a[8]||(a[8]=d=>Ie.value=d),min:"1",max:"50",step:"0.5"},null,512),[[$,Ie.value,void 0,{number:!0}]])])]),C("div",Bl,[a[57]||(a[57]=C("h3",null,"外部细圈设置",-1)),C("label",kl,[N(C("input",{type:"checkbox","onUpdate:modelValue":a[9]||(a[9]=d=>Be.value=d)},null,512),[[wt,Be.value]]),a[53]||(a[53]=Y(" 绘制外部细圈 "))]),C("label",null,[a[54]||(a[54]=Y(" 外部细圈线宽 (mm): ")),N(C("input",{type:"number","onUpdate:modelValue":a[10]||(a[10]=d=>ze.value=d),min:"0.1",max:"2",step:"0.1"},null,512),[[$,ze.value,void 0,{number:!0}]])]),C("label",null,[a[55]||(a[55]=Y(" 外部细圈宽度 (mm): ")),N(C("input",{type:"number","onUpdate:modelValue":a[11]||(a[11]=d=>lt.value=d),min:"1",max:"50",step:"0.5"},null,512),[[$,lt.value,void 0,{number:!0}]])]),C("label",null,[a[56]||(a[56]=Y(" 外部细圈高度 (mm): ")),N(C("input",{type:"number","onUpdate:modelValue":a[12]||(a[12]=d=>Ae.value=d),min:"1",max:"50",step:"0.5"},null,512),[[$,Ae.value,void 0,{number:!0}]])])])]),C("div",Yl,[a[62]||(a[62]=C("h3",null,"公司名称设置",-1)),C("label",null,[a[59]||(a[59]=Y("公司名称: ")),N(C("input",{"onUpdate:modelValue":a[13]||(a[13]=d=>n.value=d)},null,512),[[$,n.value]])]),C("label",null,[a[60]||(a[60]=Y("字体大小 (mm): ")),N(C("input",{type:"number","onUpdate:modelValue":a[14]||(a[14]=d=>o.value=d),step:"0.1"},null,512),[[$,o.value,void 0,{number:!0}]])]),C("label",null,[C("span",null,"压缩比例:"+De(me.value.toFixed(2)),1),N(C("input",{type:"range","onUpdate:modelValue":a[15]||(a[15]=d=>me.value=d),min:"0.5",max:"1.5",step:"0.05"},null,512),[[$,me.value,void 0,{number:!0}]])]),C("label",null,[C("span",null,"分布因子:"+De(A.value.toFixed(1)),1),N(C("input",{type:"range","onUpdate:modelValue":a[16]||(a[16]=d=>A.value=d),min:"1",max:"100",step:"0.5"},null,512),[[$,A.value,void 0,{number:!0}]])]),C("label",null,[a[61]||(a[61]=C("span",null,"边距 (mm): ",-1)),N(C("input",{type:"number","onUpdate:modelValue":a[17]||(a[17]=d=>I.value=d),min:"-10",max:"10",step:"0.05"},null,512),[[$,I.value,void 0,{number:!0}]])])]),C("div",Kl,[a[66]||(a[66]=C("h3",null,"底部文字设置",-1)),C("label",null,[a[63]||(a[63]=Y("底部文字: ")),N(C("input",{type:"text","onUpdate:modelValue":a[18]||(a[18]=d=>E.value=d)},null,512),[[$,E.value]])]),C("label",null,[a[64]||(a[64]=Y("字体大小 (mm): ")),N(C("input",{type:"number","onUpdate:modelValue":a[19]||(a[19]=d=>j.value=d),min:"1",max:"10",step:"0.1"},null,512),[[$,j.value,void 0,{number:!0}]])]),C("label",null,[C("span",null,"压缩比例:"+De(Te.value.toFixed(2)),1),N(C("input",{type:"range","onUpdate:modelValue":a[20]||(a[20]=d=>Te.value=d),min:"0.5",max:"1.5",step:"0.05"},null,512),[[$,Te.value,void 0,{number:!0}]])]),C("label",null,[C("span",null,"字符间距 (mm):"+De(ee.value.toFixed(2)),1),N(C("input",{type:"range","onUpdate:modelValue":a[21]||(a[21]=d=>ee.value=d),min:"-1",max:"10",step:"0.05"},null,512),[[$,ee.value,void 0,{number:!0}]])]),C("label",null,[a[65]||(a[65]=Y(" 垂直位置调整 (mm): ")),N(C("input",{type:"number","onUpdate:modelValue":a[22]||(a[22]=d=>Re.value=d),min:"-10",max:"10",step:"0.1"},null,512),[[$,Re.value,void 0,{number:!0}]])])]),C("div",Xl,[a[70]||(a[70]=C("h3",null,"印章编码设置",-1)),C("label",null,[a[67]||(a[67]=Y("印章编码: ")),N(C("input",{"onUpdate:modelValue":a[23]||(a[23]=d=>i.value=d)},null,512),[[$,i.value]])]),C("label",null,[a[68]||(a[68]=Y("字体大小 (mm): ")),N(C("input",{type:"number","onUpdate:modelValue":a[24]||(a[24]=d=>l.value=d),step:"0.1"},null,512),[[$,l.value,void 0,{number:!0}]])]),C("label",null,[C("span",null,"压缩比例:"+De(Oe.value.toFixed(2)),1),N(C("input",{type:"range","onUpdate:modelValue":a[25]||(a[25]=d=>Oe.value=d),min:"0.0",max:"3",step:"0.01"},null,512),[[$,Oe.value,void 0,{number:!0}]])]),C("label",null,[C("span",null,"分布因子: "+De(V.value.toFixed(1)),1),N(C("input",{type:"range","onUpdate:modelValue":a[26]||(a[26]=d=>V.value=d),min:"0",max:"100",step:"0.5"},null,512),[[$,V.value,void 0,{number:!0}]])]),C("label",null,[a[69]||(a[69]=Y(" 边距 (mm): ")),N(C("input",{type:"number","onUpdate:modelValue":a[27]||(a[27]=d=>F.value=d),min:"-10",max:"20",step:"0.05"},null,512),[[$,F.value,void 0,{number:!0}]])])]),C("div",Gl,[a[72]||(a[72]=C("h3",null,"税号设置",-1)),C("label",null,[a[71]||(a[71]=Y("税号: ")),N(C("input",{"onUpdate:modelValue":a[28]||(a[28]=d=>r.value=d)},null,512),[[$,r.value]])]),C("label",null,[C("span",null,"压缩比例:"+De(Pe.value.toFixed(2)),1),N(C("input",{type:"range","onUpdate:modelValue":a[29]||(a[29]=d=>Pe.value=d),min:"0.0",max:"3",step:"0.01"},null,512),[[$,Pe.value,void 0,{number:!0}]])]),C("label",null,[C("span",null,"字符间距 (mm):"+De(ge.value.toFixed(2)),1),N(C("input",{type:"range","onUpdate:modelValue":a[30]||(a[30]=d=>ge.value=d),min:"-1",max:"20",step:"0.05"},null,512),[[$,ge.value,void 0,{number:!0}]])]),C("label",null,[C("span",null,"垂直位置调整 (mm):"+De(ie.value.toFixed(1)),1),N(C("input",{type:"range","onUpdate:modelValue":a[31]||(a[31]=d=>ie.value=d),min:"-10",max:"10",step:"0.1"},null,512),[[$,ie.value,void 0,{number:!0}]])])]),C("div",ql,[a[76]||(a[76]=C("h3",null,"五角星设置",-1)),C("label",Jl,[N(C("input",{type:"checkbox","onUpdate:modelValue":a[32]||(a[32]=d=>ue.value=d)},null,512),[[wt,ue.value]]),a[73]||(a[73]=Y(" 绘制五角星 "))]),ue.value?(St(),ss("label",zl,[a[74]||(a[74]=Y(" 五角星直径 (mm): ")),N(C("input",{type:"number","onUpdate:modelValue":a[33]||(a[33]=d=>g.value=d),step:"0.1"},null,512),[[$,g.value,void 0,{number:!0}]])])):Ls("",!0),ue.value?(St(),ss("label",Zl,[a[75]||(a[75]=Y(" 五角星垂直位置 (mm): ")),N(C("input",{type:"number","onUpdate:modelValue":a[34]||(a[34]=d=>pe.value=d),min:"-10",max:"10",step:"0.1"},null,512),[[$,pe.value,void 0,{number:!0}]])])):Ls("",!0)]),C("div",Ql,[a[81]||(a[81]=C("h3",null,"防伪纹路设置",-1)),C("label",null,[a[77]||(a[77]=Y(" 启用防伪纹路: ")),N(C("input",{type:"checkbox","onUpdate:modelValue":a[35]||(a[35]=d=>$e.value=d)},null,512),[[wt,$e.value]])]),C("button",{onClick:a[36]||(a[36]=d=>x(!0,!1))},"刷新纹路"),C("label",null,[a[78]||(a[78]=Y("纹路数量: ")),N(C("input",{type:"range","onUpdate:modelValue":a[37]||(a[37]=d=>J.value=d),min:"1",max:"20",step:"1"},null,512),[[$,J.value,void 0,{number:!0}]])]),C("label",null,[a[79]||(a[79]=Y("纹路长度 (mm): ")),N(C("input",{type:"range","onUpdate:modelValue":a[38]||(a[38]=d=>K.value=d),min:"0.1",max:"20",step:"0.1"},null,512),[[$,K.value,void 0,{number:!0}]])]),C("label",null,[a[80]||(a[80]=Y("纹路宽度 (mm): ")),N(C("input",{type:"range","onUpdate:modelValue":a[39]||(a[39]=d=>rt.value=d),min:"0.05",max:"0.5",step:"0.05"},null,512),[[$,rt.value,void 0,{number:!0}]])])])],512),C("div",ea,[C("div",ta,[C("div",sa,[a[85]||(a[85]=C("h3",null,"做旧效果",-1)),C("label",na,[N(C("input",{type:"checkbox","onUpdate:modelValue":a[40]||(a[40]=d=>y.value=d)},null,512),[[wt,y.value]]),a[82]||(a[82]=Y(" 启用做旧效果 "))]),C("label",ia,[N(C("input",{type:"checkbox","onUpdate:modelValue":a[41]||(a[41]=d=>P.value=d)},null,512),[[wt,P.value]]),a[83]||(a[83]=Y(" 手动做旧 "))]),y.value?(St(),ss("label",ra,[a[84]||(a[84]=Y(" 做旧强度: ")),N(C("input",{type:"range","onUpdate:modelValue":a[42]||(a[42]=d=>b.value=d),min:"0",max:"100",step:"1"},null,512),[[$,b.value,void 0,{number:!0}]])])):Ls("",!0),C("button",{onClick:a[43]||(a[43]=d=>x(!1,!0))},"刷新做旧")])]),C("canvas",{ref_key:"stampCanvas",ref:s,width:"600",height:"600"},null,512)])]))}}),or=(e,t)=>{const s=e.__vccOpts||e;for(const[n,i]of t)s[n]=i;return s},aa=or(la,[["__scopeId","data-v-ed6f8ea0"]]),ua=Oi({__name:"App",setup(e){return(t,s)=>(St(),er(aa))}}),fa=or(ua,[["__scopeId","data-v-16a1c733"]]);Ll(fa).mount("#app"); diff --git a/docs/assets/index-CbKZPORV.css b/docs/assets/index-BNU8a4kY.css similarity index 60% rename from docs/assets/index-CbKZPORV.css rename to docs/assets/index-BNU8a4kY.css index 9af80e7..fbf8777 100644 --- a/docs/assets/index-CbKZPORV.css +++ b/docs/assets/index-BNU8a4kY.css @@ -1 +1 @@ -:root{font-family:Inter,system-ui,Avenir,Helvetica,Arial,sans-serif;line-height:1.5;font-weight:400;color-scheme:light dark;color:#ffffffde;background-color:#242424;font-synthesis:none;text-rendering:optimizeLegibility;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale}a{font-weight:500;color:#646cff;text-decoration:inherit}a:hover{color:#535bf2}body{margin:0;display:flex;place-items:center;min-width:320px;min-height:100vh}h1{font-size:3.2em;line-height:1.1}button{border-radius:8px;border:1px solid transparent;padding:.6em 1.2em;font-size:1em;font-weight:500;font-family:inherit;background-color:#1a1a1a;cursor:pointer;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{max-width:1280px;margin:0 auto;padding:2rem;text-align:center}@media (prefers-color-scheme: light){:root{color:#213547;background-color:#fff}a:hover{color:#747bff}button{background-color:#f9f9f9}}.container[data-v-e692db2a]{display:flex;height:50%;overflow:hidden}.editor-controls[data-v-e692db2a]{width:300px;padding:10px;background-color:#f0f0f0;overflow-y:auto;max-height:70vh;box-sizing:border-box}.control-group[data-v-e692db2a]{margin-bottom:15px;padding:10px;background-color:#fff;border-radius:5px;box-shadow:0 1px 3px #0000001f}.control-group h3[data-v-e692db2a]{margin-top:0;margin-bottom:10px;font-size:16px;color:#333}.editor-controls label[data-v-e692db2a]{display:flex;flex-direction:column;margin-bottom:8px;font-size:14px}.editor-controls input[type=text][data-v-e692db2a],.editor-controls input[type=number][data-v-e692db2a],.editor-controls input[type=range][data-v-e692db2a]{width:100%;padding:5px;border:1px solid #ccc;border-radius:3px;box-sizing:border-box}.editor-controls input[type=color][data-v-e692db2a]{width:100%;height:30px;padding:0;border:none}.checkbox-label[data-v-e692db2a]{flex-direction:row!important;align-items:center}.checkbox-label input[data-v-e692db2a]{margin-right:5px}.button-group[data-v-e692db2a]{display:flex;justify-content:space-between;margin-bottom:15px}button[data-v-e692db2a]{padding:8px 16px;background-color:#4caf50;color:#fff;border:none;border-radius:4px;cursor:pointer;font-size:14px}button[data-v-e692db2a]:hover{background-color:#45a049}.canvas-container[data-v-e692db2a]{flex-grow:1;flex-direction:column;background-color:#f0f8ff;display:flex;justify-content:center;align-items:center;overflow:auto}canvas[data-v-e692db2a]{max-width:100%;max-height:100%;object-fit:contain}.logo[data-v-16a1c733]{height:6em;padding:1.5em;will-change:filter;transition:filter .3s}.logo[data-v-16a1c733]:hover{filter:drop-shadow(0 0 2em #646cffaa)}.logo.vue[data-v-16a1c733]:hover{filter:drop-shadow(0 0 2em #42b883aa)} +:root{font-family:Inter,system-ui,Avenir,Helvetica,Arial,sans-serif;line-height:1.5;font-weight:400;color-scheme:light dark;color:#ffffffde;background-color:#242424;font-synthesis:none;text-rendering:optimizeLegibility;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale}a{font-weight:500;color:#646cff;text-decoration:inherit}a:hover{color:#535bf2}body{margin:0;display:flex;place-items:center;min-width:320px;min-height:100vh}h1{font-size:3.2em;line-height:1.1}button{border-radius:8px;border:1px solid transparent;padding:.6em 1.2em;font-size:1em;font-weight:500;font-family:inherit;background-color:#1a1a1a;cursor:pointer;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{max-width:1280px;margin:0 auto;padding:2rem;text-align:center}@media (prefers-color-scheme: light){:root{color:#213547;background-color:#fff}a:hover{color:#747bff}button{background-color:#f9f9f9}}.container[data-v-ed6f8ea0]{display:flex;height:50%;overflow:hidden}.editor-controls[data-v-ed6f8ea0]{width:300px;padding:10px;background-color:#f0f0f0;overflow-y:auto;max-height:70vh;box-sizing:border-box}.control-group[data-v-ed6f8ea0]{margin-bottom:15px;padding:10px;background-color:#fff;border-radius:5px;box-shadow:0 1px 3px #0000001f}.control-group h3[data-v-ed6f8ea0]{margin-top:0;margin-bottom:10px;font-size:16px;color:#333}.editor-controls label[data-v-ed6f8ea0]{display:flex;flex-direction:column;margin-bottom:8px;font-size:14px}.editor-controls input[type=text][data-v-ed6f8ea0],.editor-controls input[type=number][data-v-ed6f8ea0],.editor-controls input[type=range][data-v-ed6f8ea0]{width:100%;padding:5px;border:1px solid #ccc;border-radius:3px;box-sizing:border-box}.editor-controls input[type=color][data-v-ed6f8ea0]{width:100%;height:30px;padding:0;border:none}.checkbox-label[data-v-ed6f8ea0]{flex-direction:row!important;align-items:center}.checkbox-label input[data-v-ed6f8ea0]{margin-right:5px}.button-group[data-v-ed6f8ea0]{display:flex;justify-content:space-between;margin-bottom:15px}button[data-v-ed6f8ea0]{padding:8px 16px;background-color:#4caf50;color:#fff;border:none;border-radius:4px;cursor:pointer;font-size:14px}button[data-v-ed6f8ea0]:hover{background-color:#45a049}.canvas-container[data-v-ed6f8ea0]{flex-grow:1;flex-direction:column;background-color:#f0f8ff;display:flex;justify-content:center;align-items:center;overflow:auto}canvas[data-v-ed6f8ea0]{max-width:100%;max-height:100%;object-fit:contain}.logo[data-v-16a1c733]{height:6em;padding:1.5em;will-change:filter;transition:filter .3s}.logo[data-v-16a1c733]:hover{filter:drop-shadow(0 0 2em #646cffaa)}.logo.vue[data-v-16a1c733]:hover{filter:drop-shadow(0 0 2em #42b883aa)} diff --git a/docs/index.html b/docs/index.html index a5febfa..6c0b799 100644 --- a/docs/index.html +++ b/docs/index.html @@ -6,8 +6,8 @@ Vite + Vue + TS - - + +
diff --git a/docs/stamp_extract.png b/docs/stamp_extract.png new file mode 100644 index 0000000..70ca589 Binary files /dev/null and b/docs/stamp_extract.png differ diff --git a/docs/stamp_origin.png b/docs/stamp_origin.png new file mode 100644 index 0000000..6367873 Binary files /dev/null and b/docs/stamp_origin.png differ