52 行
291 KiB
JavaScript
52 行
291 KiB
JavaScript
|
|
var av=Object.defineProperty;var iv=(e,n,a)=>n in e?av(e,n,{enumerable:!0,configurable:!0,writable:!0,value:a}):e[n]=a;var tr=(e,n,a)=>iv(e,typeof n!="symbol"?n+"":n,a);(function(){const n=document.createElement("link").relList;if(n&&n.supports&&n.supports("modulepreload"))return;for(const r of document.querySelectorAll('link[rel="modulepreload"]'))i(r);new MutationObserver(r=>{for(const u of r)if(u.type==="childList")for(const d of u.addedNodes)d.tagName==="LINK"&&d.rel==="modulepreload"&&i(d)}).observe(document,{childList:!0,subtree:!0});function a(r){const u={};return r.integrity&&(u.integrity=r.integrity),r.referrerPolicy&&(u.referrerPolicy=r.referrerPolicy),r.crossOrigin==="use-credentials"?u.credentials="include":r.crossOrigin==="anonymous"?u.credentials="omit":u.credentials="same-origin",u}function i(r){if(r.ep)return;r.ep=!0;const u=a(r);fetch(r.href,u)}})();/**
|
|||
|
|
* @vue/shared v3.5.39
|
|||
|
|
* (c) 2018-present Yuxi (Evan) You and Vue contributors
|
|||
|
|
* @license MIT
|
|||
|
|
**/function Ar(e){const n=Object.create(null);for(const a of e.split(","))n[a]=1;return a=>a in n}const Be={},ho=[],kl=()=>{},Yu=()=>!1,li=e=>e.charCodeAt(0)===111&&e.charCodeAt(1)===110&&(e.charCodeAt(2)>122||e.charCodeAt(2)<97),ni=e=>e.startsWith("onUpdate:"),ot=Object.assign,Mr=(e,n)=>{const a=e.indexOf(n);a>-1&&e.splice(a,1)},rv=Object.prototype.hasOwnProperty,xe=(e,n)=>rv.call(e,n),ae=Array.isArray,yo=e=>na(e)==="[object Map]",oi=e=>na(e)==="[object Set]",cu=e=>na(e)==="[object Date]",ce=e=>typeof e=="function",Qe=e=>typeof e=="string",Cl=e=>typeof e=="symbol",Se=e=>e!==null&&typeof e=="object",Xu=e=>(Se(e)||ce(e))&&ce(e.then)&&ce(e.catch),Zu=Object.prototype.toString,na=e=>Zu.call(e),sv=e=>na(e).slice(8,-1),ec=e=>na(e)==="[object Object]",Nr=e=>Qe(e)&&e!=="NaN"&&e[0]!=="-"&&""+parseInt(e,10)===e,Uo=Ar(",key,ref,ref_for,ref_key,onVnodeBeforeMount,onVnodeMounted,onVnodeBeforeUpdate,onVnodeUpdated,onVnodeBeforeUnmount,onVnodeUnmounted"),ai=e=>{const n=Object.create(null);return(a=>n[a]||(n[a]=e(a)))},uv=/-\w/g,il=ai(e=>e.replace(uv,n=>n.slice(1).toUpperCase())),cv=/\B([A-Z])/g,un=ai(e=>e.replace(cv,"-$1").toLowerCase()),tc=ai(e=>e.charAt(0).toUpperCase()+e.slice(1)),lr=ai(e=>e?`on${tc(e)}`:""),wl=(e,n)=>!Object.is(e,n),Fa=(e,...n)=>{for(let a=0;a<e.length;a++)e[a](...n)},lc=(e,n,a,i=!1)=>{Object.defineProperty(e,n,{configurable:!0,enumerable:!1,writable:i,value:a})},ii=e=>{const n=parseFloat(e);return isNaN(n)?e:n},dv=e=>{const n=Qe(e)?Number(e):NaN;return isNaN(n)?e:n};let du;const ri=()=>du||(du=typeof globalThis<"u"?globalThis:typeof self<"u"?self:typeof window<"u"?window:typeof global<"u"?global:{});function et(e){if(ae(e)){const n={};for(let a=0;a<e.length;a++){const i=e[a],r=Qe(i)?mv(i):et(i);if(r)for(const u in r)n[u]=r[u]}return n}else if(Qe(e)||Se(e))return e}const fv=/;(?![^(]*\))/g,pv=/:([^]+)/,vv=/\/\*[^]*?\*\//g;function mv(e){const n={};return e.replace(vv,"").split(fv).forEach(a=>{if(a){const i=a.split(pv);i.length>1&&(n[i[0].trim()]=i[1].trim())}}),n}function z(e){let n="";if(Qe(e))n=e;else if(ae(e))for(let a=0;a<e.length;a++){const i=z(e[a]);i&&(n+=i+" ")}else if(Se(e))for(const a in e)e[a]&&(n+=a+" ");return n.trim()}const gv="itemscope,allowfullscreen,formnovalidate,ismap,nomodule,novalidate,readonly",hv=Ar(gv);function nc(e){return!!e||e===""}function yv(e,n){if(e.length!==n.length)return!1;let a=!0;for(let i=0;a&&i<e.length;i++)a=oa(e[i],n[i]);return a}function oa(e,n){if(e===n)return!0;let a=cu(e),i=cu(n);if(a||i)return a&&i?e.getTime()===n.getTime():!1;if(a=Cl(e),i=Cl(n),a||i)return e===n;if(a=ae(e),i=ae(n),a||i)return a&&i?yv(e,n):!1;if(a=Se(e),i=Se(n),a||i){if(!a||!i)return!1;const r=Object.keys(e).length,u=Object.keys(n).length;if(r!==u)return!1;for(const d in e){const v=e.hasOwnProperty(d),h=n.hasOwnProperty(d);if(v&&!h||!v&&h||!oa(e[d],n[d]))return!1}}return String(e)===String(n)}function bv(e,n){return e.findIndex(a=>oa(a,n))}const oc=e=>!!(e&&e.__v_isRef===!0),p=e=>Qe(e)?e:e==null?"":ae(e)||Se(e)&&(e.toString===Zu||!ce(e.toString))?oc(e)?p(e.value):JSON.stringify(e,ac,2):String(e),ac=(e,n)=>oc(n)?ac(e,n.value):yo(n)?{[`Map(${n.size})`]:[...n.entries()].reduce((a,[i,r],u)=>(a[nr(i,u)+" =>"]=r,a),{})}:oi(n)?{[`Set(${n.size})`]:[...n.values()].map(a=>nr(a))}:Cl(n)?nr(n):Se(n)&&!ae(n)&&!ec(n)?String(n):n,nr=(e,n="")=>{var a;return Cl(e)?`Symbol(${(a=e.description)!=null?a:n})`:e};/**
|
|||
|
|
* @vue/reactivity v3.5.39
|
|||
|
|
* (c) 2018-present Yuxi (Evan) You and Vue contributors
|
|||
|
|
* @license MIT
|
|||
|
|
**/let ft;class _v{constructor(n=!1){this.detached=n,this._active=!0,this._on=0,this.effects=[],this.cleanups=[],this._isPaused=!1,this._warnOnRun=!0,this.__v_skip=!0,!n&&ft&&(ft.active?(this.parent=ft,this.index=(ft.scopes||(ft.scopes=[])).push(this)-1):(this._active=!1,this._warnOnRun=!1))}get active(){return this._active}pause(){if(this._active){this._isPaused=!0;let n,a;if(this.scopes)for(n=0,a=this.scopes.length;n<a;n++)this.scopes[n].pause();for(n=0,a=this.effects.length;n<a;n++)this.effects[n].pause()}}resume(){if(this._active&&this._isPaused){this._isPaused=!1;let n,a;if(this.scopes)for(n=0,a=this.scopes.length;n<a;n++)this.scopes[n].resume();for(n=0,a=this.effects.length;n<a;n++)this.effects[n].resume()}}run(n){if(this._active){const a=ft;try{return ft=this,n()}finally{ft=a}}}on(){++this._on===1&&(this.prevScope=ft,ft=this)}off(){if(this._on>0&&--this._on===0){if(ft===this)ft=this.prevScope;else{let n=ft;for(;n;){if(n.prevScope===this){n.prevScope=this.prevScope;break}n=n.prevScope}}this.prevScope=void 0}}stop(n){if(this._active){this._active=!1;let a,i;for(a=0,i=this.effects.length;a<i;a++)this.effects[a].stop();for(this.effects.length=0,a=0,i=this.cleanups.length;a<i;a++)this.cleanups[a]();if(this.cleanups.length=0,this.scopes){for(a=0,i=this.scopes.length;a<i;a++)this.scopes[a].stop(!0);this.scopes.length=0}if(!this.detached&&this.parent&&!n){const r=this.parent.scopes.pop();r&&r!==this&&(this.parent.scopes[this.index]=r,r.index=this.index)}this.parent=void 0}}}function wv(){return ft}let Oe;const or=new WeakSet;class ic{constructor(n){this.fn=n,this.deps=void 0,this.depsTail=void 0,this.flags=5,this.next=void 0,this.cleanup=void 0,this.scheduler=void 0,ft&&(ft.active?ft.effects.push(this):this.flags&=-2)}pause(){this.flags|=64}resume(){this.flags&64&&(this.flags&=-65,or.has(this)&&(or.delete(this),this.trigger()))}notify(){this.flags&2&&!(this.flags&32)||this.flags&8||sc(this)}run(){if(!(this.flags&1))return this.fn();this.flags|=2,fu(this),uc(this);const n=Oe,a=rl;Oe=this,rl=!0;try{return this.fn()}finally{cc(this),Oe=n,rl=a,this.flags&=-3}}stop(){if(this.flags&1){for(let n=this.deps;n;n=n.nextDep)Er(n);this.deps=this.depsTail=void 0,fu(this),this.onStop&&this.onStop(),this.flags&=-2}}trigger(){this.flags&64?or.add(this):this.scheduler?this.scheduler():this.runIfDirty()}runIfDirty(){hr(this)&&this.run()}get dirty(){return hr(this)}}let rc=0,Ho,Ko;function sc(e,n=!1){if(e.flags|=8,n){e.next=Ko,Ko=e;return}e.next=Ho,Ho=e}function Tr(){rc++}function qr(){if(--rc>0)return;if(Ko){let n=Ko;for(Ko=void 0;n;){const a=n.next;n.next=void 0,n.flags&=-9,n=a}}let e;for(;Ho;){let n=Ho;for(Ho=void 0;n;){const a=n.next;if(n.next=void 0,n.flags&=-9,n.flags&1)try{n.trigger()}catch(i){e||(e=i)}n=a}}if(e)throw e}function uc(e){for(let n=e.deps;n;n=n.nextDep)n.version=-1,n.prevActiveLink=n.dep.activeLink,n.dep.activeLink=n}function cc(e){let n,a=e.depsTail,i=a;for(;i;){const r=i.prevDep;i.version===-1?(i===a&&(a=r),Er(i),kv(i)):n=i,i.dep.activeLink=i.prevActiveLink,i.prevActiveLink=void 0,i=r}e.deps=n,e.depsTail=a}function hr(e){for(let n=e.deps;n;n=n.nextDep)if(n.dep.version!==n.version||n.dep.computed&&(dc(n.dep.computed)||n.dep.version!==n.version))return!0;return!!e._dirty}function dc(e){if(e.flags&4&&!(e.flags&16)||(e.flags&=-17,e.globalVersion===Yo)||(e.globalVersion=Yo,!e.isSSR&&e.flags&128&&(!e.deps&&!e._dirty||!hr(e))))return;e.flags|=2;const n=e.dep,a=Oe,i=rl;Oe=e,rl=!0;try{uc(e);const r=e.fn(e._value);(n.version===0||wl(r,e._value))&&(e.flags|=128,e._value=r,n.version++)}catch(r){throw n.version++,r}finally{Oe=a,rl=i,cc(e),e.flags&=-3}}function Er(e,n=!1){const{dep:a,prevSub:i,nextSub:r}=e;if(i&&(i.nextSub=r,e.prevSub=void 0),r&&(r.prevSub=i,e.nextSub=void 0),a.subs===e&&(a.subs=i,!i&&a.computed)){a.computed.flags&=-5;for(let u=a.computed.deps;u;u=u.nextDep)Er(u,!0)}!n&&!--a.sc&&a.map&&a.map.delete(a.key)}function kv(e){const{prevDep:n,nextDep:a}=e;n&&(n.nextDep=a,e.prevDep=void 0),a&&(a.prevDep=n,e.nextDep=void 0)}let rl=!0;const fc=[];function Il(){fc.push(rl),rl=!1}function $l(){const e=fc.pop();rl=e===void 0?!0:
|
|||
|
|
* @vue/runtime-core v3.5.39
|
|||
|
|
* (c) 2018-present Yuxi (Evan) You and Vue contributors
|
|||
|
|
* @license MIT
|
|||
|
|
**/function aa(e,n,a,i){try{return i?e(...i):e()}catch(r){ui(r,n,a)}}function Xt(e,n,a,i){if(ce(e)){const r=aa(e,n,a,i);return r&&Xu(r)&&r.catch(u=>{ui(u,n,a)}),r}if(ae(e)){const r=[];for(let u=0;u<e.length;u++)r.push(Xt(e[u],n,a,i));return r}}function ui(e,n,a,i=!0){const r=n?n.vnode:null,{errorHandler:u,throwUnhandledErrorInProduction:d}=n&&n.appContext.config||Be;if(n){let v=n.parent;const h=n.proxy,$=`https://vuejs.org/error-reference/#runtime-${a}`;for(;v;){const k=v.ec;if(k){for(let x=0;x<k.length;x++)if(k[x](e,h,$)===!1)return}v=v.parent}if(u){Il(),aa(u,null,10,[e,h,$]),$l();return}}zv(e,a,r,i,d)}function zv(e,n,a,i=!0,r=!1){if(r)throw e;console.error(e)}const At=[];let yl=-1;const bo=[];let an=null,go=0;const kc=Promise.resolve();let Ha=null;function rn(e){const n=Ha||kc;return e?n.then(this?e.bind(this):e):n}function Qv(e){let n=yl+1,a=At.length;for(;n<a;){const i=n+a>>>1,r=At[i],u=Zo(r);u<e||u===e&&r.flags&2?n=i+1:a=i}return n}function Fr(e){if(!(e.flags&1)){const n=Zo(e),a=At[At.length-1];!a||!(e.flags&2)&&n>=Zo(a)?At.push(e):At.splice(Qv(n),0,e),e.flags|=1,Cc()}}function Cc(){Ha||(Ha=kc.then($c))}function Jv(e){ae(e)?bo.push(...e):an&&e.id===-1?an.splice(go+1,0,e):e.flags&1||(bo.push(e),e.flags|=1),Cc()}function vu(e,n,a=yl+1){for(;a<At.length;a++){const i=At[a];if(i&&i.flags&2){if(e&&i.id!==e.uid)continue;At.splice(a,1),a--,i.flags&4&&(i.flags&=-2),i(),i.flags&4||(i.flags&=-2)}}}function Ic(e){if(bo.length){const n=[...new Set(bo)].sort((a,i)=>Zo(a)-Zo(i));if(bo.length=0,an){an.push(...n);return}for(an=n,go=0;go<an.length;go++){const a=an[go];a.flags&4&&(a.flags&=-2),a.flags&8||a(),a.flags&=-2}an=null,go=0}}const Zo=e=>e.id==null?e.flags&2?-1:1/0:e.id;function $c(e){try{for(yl=0;yl<At.length;yl++){const n=At[yl];n&&!(n.flags&8)&&(n.flags&4&&(n.flags&=-2),aa(n,n.i,n.i?15:14),n.flags&4||(n.flags&=-2))}}finally{for(;yl<At.length;yl++){const n=At[yl];n&&(n.flags&=-2)}yl=-1,At.length=0,Ic(),Ha=null,(At.length||bo.length)&&$c()}}let Jt=null,Pc=null;function Ka(e){const n=Jt;return Jt=e,Pc=e&&e.type.__scopeId||null,n}function Ze(e,n=Jt,a){if(!n||e._n)return e;const i=(...r)=>{i._d&&Qa(-1);const u=Ka(n);let d;try{d=e(...r)}finally{Ka(u),i._d&&Qa(1)}return d};return i._n=!0,i._c=!0,i._d=!0,i}function Te(e,n){if(Jt===null)return e;const a=vi(Jt),i=e.dirs||(e.dirs=[]);for(let r=0;r<n.length;r++){let[u,d,v,h=Be]=n[r];u&&(ce(u)&&(u={mounted:u,updated:u}),u.deep&&Dl(d),i.push({dir:u,instance:a,value:d,oldValue:void 0,arg:v,modifiers:h}))}return e}function qn(e,n,a,i){const r=e.dirs,u=n&&n.dirs;for(let d=0;d<r.length;d++){const v=r[d];u&&(v.oldValue=u[d].value);let h=v.dir[i];h&&(Il(),Xt(h,a,8,[e.el,v,e,n]),$l())}}function Yv(e,n){if(Nt){let a=Nt.provides;const i=Nt.parent&&Nt.parent.provides;i===a&&(a=Nt.provides=Object.create(i)),a[e]=n}}function Wa(e,n,a=!1){const i=Kr();if(i||_o){let r=_o?_o._context.provides:i?i.parent==null||i.ce?i.vnode.appContext&&i.vnode.appContext.provides:i.parent.provides:void 0;if(r&&e in r)return r[e];if(arguments.length>1)return a&&ce(n)?n.call(i&&i.proxy):n}}const Xv=Symbol.for("v-scx"),Zv=()=>Wa(Xv);function St(e,n,a){return xc(e,n,a)}function xc(e,n,a=Be){const{immediate:i,deep:r,flush:u,once:d}=a,v=ot({},a),h=n&&i||!n&&u!=="post";let $;if(la){if(u==="sync"){const H=Zv();$=H.__watcherHandles||(H.__watcherHandles=[])}else if(!h){const H=()=>{};return H.stop=kl,H.resume=kl,H.pause=kl,H}}const k=Nt;v.call=(H,de,le)=>Xt(H,k,de,le);let x=!1;u==="post"?v.scheduler=H=>{Et(H,k&&k.suspense)}:u!=="sync"&&(x=!0,v.scheduler=(H,de)=>{de?H():Fr(H)}),v.augmentJob=H=>{n&&(H.flags|=4),x&&(H.flags|=2,k&&(H.id=k.uid,H.i=k))};const O=Gv(e,n,v);return la&&($?$.push(O):h&&O()),O}function em(e,n,a){const i=this.proxy,r=Qe(e)?e.includes(".")?Sc(i,e):()=>i[e]:e.bind(i,i);let u;ce(n)?u=n:(u=n.handler,a=n);const d=ia(this),v=xc(r,u.bind(i),a);return d(),v}function Sc(e,n){const a=n.split(".");return()=>{let i=e;for(let r=0;r<a.length&&i;r++)i=i[a[r]];return i}}const tm=Symbol("_vte"),Ac=e=>e.__isTeleport,Qt=Symbol("_leaveCb"),Fo=Symbol("_enterCb");function Mc(){const e={isMounted:!1,isLeaving:!1,isUnmounting:!1,le
|
|||
|
|
* @vue/runtime-dom v3.5.39
|
|||
|
|
* (c) 2018-present Yuxi (Evan) You and Vue contributors
|
|||
|
|
* @license MIT
|
|||
|
|
**/let xr;const Su=typeof window<"u"&&window.trustedTypes;if(Su)try{xr=Su.createPolicy("vue",{createHTML:e=>e})}catch{}const rd=xr?e=>xr.createHTML(e):e=>e,tg="http://www.w3.org/2000/svg",lg="http://www.w3.org/1998/Math/MathML",Rl=typeof document<"u"?document:null,Au=Rl&&Rl.createElement("template"),ng={insert:(e,n,a)=>{n.insertBefore(e,a||null)},remove:e=>{const n=e.parentNode;n&&n.removeChild(e)},createElement:(e,n,a,i)=>{const r=n==="svg"?Rl.createElementNS(tg,e):n==="mathml"?Rl.createElementNS(lg,e):a?Rl.createElement(e,{is:a}):Rl.createElement(e);return e==="select"&&i&&i.multiple!=null&&r.setAttribute("multiple",i.multiple),r},createText:e=>Rl.createTextNode(e),createComment:e=>Rl.createComment(e),setText:(e,n)=>{e.nodeValue=n},setElementText:(e,n)=>{e.textContent=n},parentNode:e=>e.parentNode,nextSibling:e=>e.nextSibling,querySelector:e=>Rl.querySelector(e),setScopeId(e,n){e.setAttribute(n,"")},insertStaticContent(e,n,a,i,r,u){const d=a?a.previousSibling:n.lastChild;if(r&&(r===u||r.nextSibling))for(;n.insertBefore(r.cloneNode(!0),a),!(r===u||!(r=r.nextSibling)););else{Au.innerHTML=rd(i==="svg"?`<svg>${e}</svg>`:i==="mathml"?`<math>${e}</math>`:e);const v=Au.content;if(i==="svg"||i==="mathml"){const h=v.firstChild;for(;h.firstChild;)v.appendChild(h.firstChild);v.removeChild(h)}n.insertBefore(v,a)}return[d?d.nextSibling:n.firstChild,a?a.previousSibling:n.lastChild]}},nn="transition",Wo="animation",Co=Symbol("_vtc"),sd={name:String,type:String,css:{type:Boolean,default:!0},duration:[String,Number,Object],enterFromClass:String,enterActiveClass:String,enterToClass:String,appearFromClass:String,appearActiveClass:String,appearToClass:String,leaveFromClass:String,leaveActiveClass:String,leaveToClass:String},ud=ot({},Nc,sd),og=e=>(e.displayName="Transition",e.props=ud,e),gt=og((e,{slots:n})=>Zm(nm,cd(e),n)),Ln=(e,n=[])=>{ae(e)?e.forEach(a=>a(...n)):e&&e(...n)},Mu=e=>e?ae(e)?e.some(n=>n.length>1):e.length>1:!1;function cd(e){const n={};for(const K in e)K in sd||(n[K]=e[K]);if(e.css===!1)return n;const{name:a="v",type:i,duration:r,enterFromClass:u=`${a}-enter-from`,enterActiveClass:d=`${a}-enter-active`,enterToClass:v=`${a}-enter-to`,appearFromClass:h=u,appearActiveClass:$=d,appearToClass:k=v,leaveFromClass:x=`${a}-leave-from`,leaveActiveClass:O=`${a}-leave-active`,leaveToClass:H=`${a}-leave-to`}=e,de=ag(r),le=de&&de[0],ne=de&&de[1],{onBeforeEnter:fe,onEnter:F,onEnterCancelled:_e,onLeave:J,onLeaveCancelled:ye,onBeforeAppear:De=fe,onAppear:Ke=F,onAppearCancelled:tt=_e}=n,re=(K,qe,at,bt)=>{K._enterCancelled=bt,on(K,qe?k:v),on(K,qe?$:d),at&&at()},ue=(K,qe)=>{K._isLeaving=!1,on(K,x),on(K,H),on(K,O),qe&&qe()},Ie=K=>(qe,at)=>{const bt=K?Ke:F,Fe=()=>re(qe,K,at);Ln(bt,[qe,Fe]),Nu(()=>{on(qe,K?h:u),hl(qe,K?k:v),Mu(bt)||Tu(qe,i,le,Fe)})};return ot(n,{onBeforeEnter(K){Ln(fe,[K]),hl(K,u),hl(K,d)},onBeforeAppear(K){Ln(De,[K]),hl(K,h),hl(K,$)},onEnter:Ie(!1),onAppear:Ie(!0),onLeave(K,qe){K._isLeaving=!0;const at=()=>ue(K,qe);hl(K,x),K._enterCancelled?(hl(K,O),Sr(K)):(Sr(K),hl(K,O)),Nu(()=>{K._isLeaving&&(on(K,x),hl(K,H),Mu(J)||Tu(K,i,ne,at))}),Ln(J,[K,at])},onEnterCancelled(K){re(K,!1,void 0,!0),Ln(_e,[K])},onAppearCancelled(K){re(K,!0,void 0,!0),Ln(tt,[K])},onLeaveCancelled(K){ue(K),Ln(ye,[K])}})}function ag(e){if(e==null)return null;if(Se(e))return[dr(e.enter),dr(e.leave)];{const n=dr(e);return[n,n]}}function dr(e){return dv(e)}function hl(e,n){n.split(/\s+/).forEach(a=>a&&e.classList.add(a)),(e[Co]||(e[Co]=new Set)).add(n)}function on(e,n){n.split(/\s+/).forEach(i=>i&&e.classList.remove(i));const a=e[Co];a&&(a.delete(n),a.size||(e[Co]=void 0))}function Nu(e){requestAnimationFrame(()=>{requestAnimationFrame(e)})}let ig=0;function Tu(e,n,a,i){const r=e._endId=++ig,u=()=>{r===e._endId&&i()};if(a!=null)return setTimeout(u,a);const{type:d,timeout:v,propCount:h}=dd(e,n);if(!d)return i();const $=d+"end";let k=0;const x=()=>{e.removeEventListener($,O),u()},O=H=>{H.target===e&&++k>=h&&x()};setTimeout(()=>{k<h&&x()},v+1),e.addEventListener($,O)}function dd(e,n){const a=window.getComputedStyle(e),i=de=>(a[de]||"").split(", "),r=i(`${nn}Delay`),u
|
|||
|
|
`)}function Ws(t){const l=be.value,s=ke.value;return{source:"standalone_web_workflow_chat",ui_node_id:Me.value,ui_node_title:l.title,ui_node_phase:l.phase,ui_node_status:l.status,profile_id:s.profileId,profile_name:s.name,workflow_id:s.workflowId,source_language:"auto",target_prompt_language:"en",translation_mode:"backend_llm",user_instruction:t,persona_split_fields_ready:Ca.value,persona_split_fields_total:ka.value,selected_material_ids:Kt.value.map(c=>c.id),selected_draft_image_ids:Ve.value.map(c=>c.image_id)}}async function Ef(){var s;const t=P.value.trim();!t||me.value||!await Hi({promptPatch:Fs(t),metadata:Ws(t)})||(R.value=t,E.value=`${be.value.title} / ${((s=Zn.value)==null?void 0:s.label)??rt.value}`)}function Vs(){!Ge.value||!nt(Ge.value)||(mn.value="generation",Ft("imageViewer"),so(),Zt.value=!0)}function js(t){const l=(t?Ia.value.find(s=>s.image_id===t):null)??In.value;!l||!nt(l)||(Ie.value=l.image_id,Vs())}function Lf(){Ve.value.length&&(mn.value="workflowCompare",Ft("imageViewer"),so(),Zt.value=!0)}function Us(t){var l;t&&Bs(t),(l=dt.value)!=null&&l.imageUrl&&(mn.value="quickProfile",Ft("imageViewer"),so(),Zt.value=!0)}function Sa(){Zt.value=!1,Pl.value=!1}function so(){dl.value=1,Gl.value={x:0,y:0}}function qo(t){dl.value=Fp(Number((dl.value+t).toFixed(2)),.5,4),dl.value<=1&&(Gl.value={x:0,y:0})}function Vi(t){qo(t.deltaY<0?.12:-.12)}function Rf(){if(dl.value>1){so();return}dl.value=2.2,Gl.value={x:0,y:0}}function ji(t){dl.value<=1||(Pl.value=!0,gn.value={pointerId:t.pointerId,x:t.clientX,y:t.clientY,offsetX:Gl.value.x,offsetY:Gl.value.y},t.currentTarget instanceof HTMLElement&&t.currentTarget.setPointerCapture(t.pointerId))}function Ui(t){!Pl.value||t.pointerId!==gn.value.pointerId||(Gl.value={x:gn.value.offsetX+t.clientX-gn.value.x,y:gn.value.offsetY+t.clientY-gn.value.y})}function Nl(t){!Pl.value||t.pointerId!==gn.value.pointerId||(Pl.value=!1,t.currentTarget instanceof HTMLElement&&t.currentTarget.hasPointerCapture(t.pointerId)&&t.currentTarget.releasePointerCapture(t.pointerId))}function Bf(){Ft("search"),gi.value=!0,Gn.value=!0}function Eo(){Ft("personaQuestionnaire"),Ul.value="",we.value=!0}function Of(){Ft("externalProfileImport"),Ye.value=!0,rn(()=>{var t;(t=document.querySelector("[data-profile-import-input]"))==null||t.focus()})}function Df(){Ft("quickProfileDetail"),We.value=!0}function Ff(t){Vl.value=t,Ft("materialDetail"),j.value=!0}async function Wf(t){if(t.enabled){if(t.actionKey==="personaQuestionnaire"){Eo();return}if(t.actionKey==="workflowCompare"){Lf();return}if(t.actionKey==="externalProfileImport"){Of();return}if(t.actionKey==="workflowPersonaSplit"){await Hf();return}if(t.actionKey==="workflowSaveVersion"){await np();return}if(t.actionKey==="workflowCreateBranchFromNode"){await Uf();return}if(t.actionKey==="workflowNodeGenerate"){t.id==="hires"&&Me.value!=="hires-fix"&&(ol("hires-fix"),await rn()),await Hi();return}if(t.actionKey==="workflowNodeRetry"){await Hi({retry:!0});return}if(t.actionKey==="workflowNodeComplete"){await Kf();return}if(t.actionKey==="workflowNodeReview"){await Qf();return}if(t.actionKey==="workflowReviewAdopt"){await ep();return}if(t.actionKey==="workflowPromptPlanSave"){await Gf();return}if(t.actionKey==="workflowPromptPlanNext"){ol("prompt-plan");return}if(t.actionKey==="workflowMaterialBindSave"){await zf();return}if(t.actionKey==="workflowArchiveFinal"){await Vf();return}t.nav&&t.module&&nl(t.nav,t.module)}}async function Vf(){const t=ke.value;if(!t||me.value)return;const l=$t("入库");if(l){Z.value=l;return}if(!t.workflowId){Z.value="请先生成角色档案并创建后端工作流,再执行入库。";return}const s=t.workflowId,c=Ot("archive",t);if(!c){Z.value="当前工作流缺少后端入库节点 final_pack。";return}const m=xn(s).find(q=>q.node_id===c);if(m&&["completed","selected"].includes(ct(m.status))){Z.value="入库节点已经完成。如需修改,请从对应节点创建新分支。";return}const g=Ot("hires-fix",t)??Ot(Me.value,t),I=zs(g);if(!I.length){Z.value="还没有可入库的真实后端图片。请先完成“高清修复与统
|
|||
|
|
`)}}function Aa(t,l,s,c,m){return{id:t,title:l,prompt:s,negative:c,weight_suggestions:[{label:"identity",value:1.25,reason:"keep character identity stable"},{label:"style",value:.85,reason:"avoid overfitting style over identity"}],inherits:m,status:"ready"}}function lp(t){const l=Kt.value,s=h.map((c,m)=>{const g=l.find(I=>I.category===c.category);return{id:`rule_${c.category}_${m+1}`,category:c.category,material_id:(g==null?void 0:g.id)??"",material_label:(g==null?void 0:g.label)??"",material_group:(g==null?void 0:g.group)??(g==null?void 0:g.category)??"",material_prompt:(g==null?void 0:g.prompt)??"",material_colors:(g==null?void 0:g.colors)??[],bind_to_stages:Ks(c.category),inheritance_rule:g?`${c.category} only affects explicitly bound downstream stages.`:"do not use reference unless user explicitly selects one",reference_strength:g?Gs(c.category):"弱",required:!!(g&&["风格","服装"].includes(c.category)),status:g?"ready":"pending"}});return{profile_id:t.profileId,profile_name:t.name,selected_material_ids:l.map(c=>c.id),rules:s}}function Ks(t){return{风格:[{stage_id:"portrait-draft",stage_title:"头像草稿"},{stage_id:"halfbody-draft",stage_title:"半身草稿"},{stage_id:"body-sheet",stage_title:"全身与设定图"},{stage_id:"review-archive",stage_title:"修复入库"}],构图:[{stage_id:"portrait-draft",stage_title:"头像草稿"},{stage_id:"body-sheet",stage_title:"全身与设定图"}],服装:[{stage_id:"halfbody-draft",stage_title:"半身草稿"},{stage_id:"body-sheet",stage_title:"全身与设定图"}],鞋袜:[{stage_id:"body-sheet",stage_title:"全身与设定图"}],配饰:[{stage_id:"body-sheet",stage_title:"全身与设定图"},{stage_id:"review-archive",stage_title:"修复入库"}]}[t]??[{stage_id:"body-sheet",stage_title:"全身与设定图"}]}function Gs(t){return t==="风格"||t==="服装"?"强":t==="构图"?"中":"弱"}async function np(){var s;const t=ke.value;if(!t||Kn.value)return;const l=$t("保存快照");if(l){fn.value=l;return}if(!t.workflowId){fn.value="请先生成档案并创建后端工作流,再保存快照。";return}Kn.value=!0,fn.value="";try{const c=await Ee(L.workflowHistory(t.workflowId),{action:"save_version",title:`${t.name} / ${((s=be.value)==null?void 0:s.title)??"工作流快照"}`,node_id:Ot(Me.value,t),include_nodes:!0,metadata:{source:"standalone_web",ui_node_id:Me.value,profile_id:t.profileId,profile_name:t.name,profile_status:t.status}});$o.value=c.created_at}catch(c){fn.value=`保存快照失败:${ze(c)}`}finally{Kn.value=!1}}function Ot(t,l){if(!l.workflowId)return;const c=xn(l.workflowId).find(g=>uo(g)===t);if(c)return c.node_id;const m=l.workflowNodeIds??[];if(t!=="brief-import"&&t==="persona-split")return m[0]}function xn(t){var c;const l=lt.value[t]??[],s=(c=It.value[t])==null?void 0:c.current_branch;return s?l.filter(m=>m.branch_name===s):l}function zs(t){var s;const l=[...Ve.value.map(c=>c.image_id),(s=In.value)==null?void 0:s.image_id,...t?(Ut.value[t]??[]).map(c=>c.image_id):[]];return Array.from(new Set(l.filter(c=>!!(c&&Lo(c)))))}function Lo(t){return!t.startsWith("mock-")}async function op(){if(!is.value||jl.value)return;const t=$t("生成档案");if(t){Ul.value=t;return}Lt.value+=1;const l=cp(ie.value,Lt.value);jl.value=!0,Ul.value="";try{const s=await Ee(L.quickProfileDraft,ap(l,ie.value,it.value)),c={...l,name:s.profile_preview.name||l.name,style:s.profile_preview.style_prompt||l.style,negative:s.profile_preview.negative_prompt||l.negative},m=await Ee(L.quickProfileDraftSave,ip(c,ie.value,it.value,s)),g=sp(m,c),I=await Fi(g),q={...g,workflowId:I.workflow.workflow_id,workflowNodeIds:I.nodes.map(U=>U.node_id),status:"工作流就绪"};Xe.value=[q,...Xe.value.filter(U=>U.id!==q.id)],Oi(q),ue.value="workflow",Me.value="brief-import",vt("personaQuestionnaire"),rn(()=>{var U;(U=document.querySelector(`[data-profile-card-id="${q.id}"]`))==null||U.scrollIntoView({block:"nearest",behavior:"smooth"})})}catch(s){Ul.value=`后端生成或保存失败:${ze(s)}`}finally{jl.value=!1}}function ap(t,l,s){return{questionnaire:{...Qs(l,s),name:t.name,identity:t.id
|
|||
|
|
<svg xmlns="http://www.w3.org/2000/svg" width="${W}" height="${Ne}" viewBox="0 0 ${W} ${Ne}" preserveAspectRatio="xMidYMid meet">
|
|||
|
|
<defs>
|
|||
|
|
<linearGradient id="bg" x1="0" y1="0" x2="1" y2="1">
|
|||
|
|
<stop offset="0%" stop-color="${g}" />
|
|||
|
|
<stop offset="58%" stop-color="${I}" />
|
|||
|
|
<stop offset="100%" stop-color="#111827" />
|
|||
|
|
</linearGradient>
|
|||
|
|
<radialGradient id="halo" cx="72%" cy="22%" r="55%">
|
|||
|
|
<stop offset="0%" stop-color="${q}" stop-opacity="0.82" />
|
|||
|
|
<stop offset="100%" stop-color="${q}" stop-opacity="0" />
|
|||
|
|
</radialGradient>
|
|||
|
|
<pattern id="grid" width="${ml}" height="${ml}" patternUnits="userSpaceOnUse">
|
|||
|
|
<path d="M${ml} 0H0V${ml}" fill="none" stroke="#ffffff" stroke-opacity="0.13" stroke-width="2" />
|
|||
|
|
</pattern>
|
|||
|
|
</defs>
|
|||
|
|
<rect width="${W}" height="${Ne}" fill="url(#bg)" />
|
|||
|
|
<rect width="${W}" height="${Ne}" fill="url(#grid)" />
|
|||
|
|
<circle cx="${Jp}" cy="${Yp}" r="${Xp}" fill="url(#halo)" />
|
|||
|
|
<circle cx="${Zp}" cy="${ev}" r="${tv}" fill="#ffffff" opacity="0.11" />
|
|||
|
|
<rect x="${pe}" y="${pe}" width="${Kp}" height="${Gp}" rx="${al}" fill="#ffffff" opacity="0.14" />
|
|||
|
|
<rect x="${Pt}" y="${Pt}" width="${zp}" height="${Qp}" rx="${Math.round(al*.72)}" fill="#0f172a" opacity="0.24" />
|
|||
|
|
<text x="${Pt+Math.round(Le*.035)}" y="${ln}" fill="#ffffff" opacity="0.72" font-family="Inter, Microsoft YaHei, sans-serif" font-size="${po}" font-weight="700">IMAGESTUDIO TEST ${U}</text>
|
|||
|
|
<text x="${Pt+Math.round(Le*.035)}" y="${Gt}" fill="#ffffff" font-family="Inter, Microsoft YaHei, sans-serif" font-size="${Tn}" font-weight="800">${X}</text>
|
|||
|
|
<text x="${Pt+Math.round(Le*.035)}" y="${Nn}" fill="#ffffff" opacity="0.78" font-family="Inter, Microsoft YaHei, sans-serif" font-size="${fo}">${y}</text>
|
|||
|
|
<text x="${lv}" y="${ln+Math.round(Le*.02)}" text-anchor="middle" fill="#ffffff" opacity="0.86" font-family="Inter, Microsoft YaHei, sans-serif" font-size="${Ea}" font-weight="900">${U}</text>
|
|||
|
|
<text x="${W-pe}" y="${Ne-Math.round(pe*.35)}" text-anchor="end" fill="#ffffff" opacity="0.72" font-family="Inter, Microsoft YaHei, sans-serif" font-size="${Math.max(18,Math.round(Le*.027))}" font-weight="800">${nv}</text>
|
|||
|
|
</svg>`;return`data:image/svg+xml;charset=UTF-8,${encodeURIComponent(ov)}`}function Bp(t){const l=t.match(/(\d+)\s*x\s*(\d+)/i);if(!l)return[4,3];const s=Number(l[1]),c=Number(l[2]);if(!Number.isFinite(s)||!Number.isFinite(c)||s<=0||c<=0)return[4,3];const m=Op(s,c);return[Math.round(s/m),Math.round(c/m)]}function Op(t,l){let s=Math.abs(Math.round(t)),c=Math.abs(Math.round(l));for(;c;){const m=s%c;s=c,c=m}return s||1}function su(t){return t.replace(/[&<>"']/g,l=>({"&":"&","<":"<",">":">",'"':""","'":"'"})[l]??l)}function je(t){return"title"in t&&t.title?t.title:t.node_id||t.workflow_id||t.profile_id||Tl(t.image_id)}function nt(t){return t.thumbnail_url||t.image_url||""}function Dp(t){if(t.status==="confirmed_unsupported")return!1;if(t.dialect==="openai_images"||t.dialect==="comfyui")return!0;const l=t.capabilities||{};return!!(l.text_to_image||l.image_generation||l.workflow_graph||Object.keys(l).some(s=>["text_to_image","image_generation","workflow_graph"].includes(s)))}function Tl(t){return t.length>10?`${t.slice(0,6)}...${t.slice(-4)}`:t}function Ta(t){const l=Number(t.progress);return Number.isFinite(l)?Math.max(0,Math.min(100,l)):0}function Fp(t,l,s){return Math.max(l,Math.min(s,t))}function ct(t){return String(t||"").trim().toLowerCase()}function Qi(t){const l=ct(t);return["failed","dead_letter","cancelled"].includes(l)?"is-bad":["running","queued","created","pending"].includes(l)?"is-warn":["completed","succeeded"].includes(l)?"is-good":"is-idle"}function Mn(t){return t<1024?`${t} B`:t<1024*1024?`${(t/1024).toFixed(1)} KB`:t<1024*1024*1024?`${(t/1024/1024).toFixed(1)} MB`:`${(t/1024/1024/1024).toFixed(1)} GB`}function ql(t){if(!t)return"-";const l=new Date(t);return Number.isNaN(l.getTime())?t:new Intl.DateTimeFormat("zh-CN",{month:"2-digit",day:"2-digit",hour:"2-digit",minute:"2-digit"}).format(l)}function Ji(t){const l=er(t.created_at);if(!l)return"-";const s=Math.max(0,Math.round((Date.now()-l)/6e4));return s<1?"刚刚":s<60?`${s} 分钟`:`${Math.round(s/60)} 小时`}function Wp(){const t=localStorage.getItem(fl.theme);(t==="light"||t==="dark")&&(cl.value=t),Hl.value=localStorage.getItem(fl.primary)||Hl.value,Kl.value=localStorage.getItem(fl.accent)||Kl.value,Ht.value=uu(localStorage.getItem(fl.readNotifications)),zn.value=uu(localStorage.getItem(fl.dismissedNotifications))}function Vp(){localStorage.setItem(fl.theme,cl.value),localStorage.setItem(fl.primary,Hl.value),localStorage.setItem(fl.accent,Kl.value),localStorage.setItem(fl.readNotifications,JSON.stringify(Ht.value)),localStorage.setItem(fl.dismissedNotifications,JSON.stringify(zn.value))}function uu(t){if(!t)return[];try{const l=JSON.parse(t);return Array.isArray(l)?l.filter(s=>typeof s=="string"):[]}catch{return[]}}function El(t,l){const s=Zi(t);return s?`rgba(${s.r}, ${s.g}, ${s.b}, ${l})`:`rgba(118, 104, 232, ${l})`}function Yi(t,l,s){const c=Zi(t),m=Zi(l);if(!c||!m)return t;const g=Math.min(1,Math.max(0,s));return`#${Xi(c.r*(1-g)+m.r*g)}${Xi(c.g*(1-g)+m.g*g)}${Xi(c.b*(1-g)+m.b*g)}`}function Xi(t){return Math.round(t).toString(16).padStart(2,"0")}function Zi(t){const l=t.replace("#","");return/^[0-9a-fA-F]{6}$/.test(l)?{r:Number.parseInt(l.slice(0,2),16),g:Number.parseInt(l.slice(2,4),16),b:Number.parseInt(l.slice(4,6),16)}:null}function mt(t,l){const s=t==null?void 0:t[l];return typeof s=="string"?s:""}function jp(t){return!qa(t)||typeof t.task_id!="string"?null:{task_id:t.task_id,task_type:typeof t.task_type=="string"?t.task_type:"generation",status:typeof t.status=="string"?t.status:"created",progress:typeof t.progress=="number"?t.progress:0,created_at:typeof t.created_at=="string"?t.created_at:"",updated_at:typeof t.updated_at=="string"?t.updated_at:"",profile_id:typeof t.profile_id=="string"?t.profile_id:null,workflow_id:typeof t.workflow_id=="string"?t.workflow_id:null,node_id:typeof t.node_id=="string"?t.node_id:null,model_route:typeof t.model_route=="string"?t.model_route:null,idempotency_key:typeof t.idempotency_key=="string"?t.idempotency_key:null,request:qa(t.request)?t.request:void 0,result:qa(t.result)?t.result:void 0
|
|||
|
|
身份:近未来港区巡查员\r
|
|||
|
|
性格:冷静、可靠、行动快\r
|
|||
|
|
外观:黑色短发,青绿色眼睛\r
|
|||
|
|
服装:轻机能外套、短靴、发光臂章\r
|
|||
|
|
避雷:低质量、结构错误`},null,512),[[Re,Ct.value]])]),o("aside",g_,[o("header",null,[o("div",null,[l[149]||(l[149]=o("span",null,"识别预览",-1)),o("strong",null,p(_d.value)+" / "+p(_i.value.length),1)]),o("em",null,p(Xn.value?`${Xn.value.length} 字`:"待粘贴"),1)]),o("dl",null,[(b(!0),_(V,null,G(_i.value,f=>(b(),_("div",{key:f.key,class:z({pending:Xn.value&&!f.recognized})},[o("dt",null,[ja(p(f.label)+" ",1),o("span",null,p(f.recognized?"已识别":"待整理"),1)]),o("dd",null,p(f.value||"粘贴文本后显示"),1)],2))),128))])])]),o("footer",null,[o("span",null,p(Xn.value?"识别结果会先填入问卷,仍可在问卷里继续微调。":"等待外部角色卡文本。"),1),o("button",{type:"button",onClick:l[28]||(l[28]=f=>vt("externalProfileImport"))},"取消"),o("button",{type:"button",disabled:!Xn.value,onClick:pp}," 识别并填入问卷 ",8,h_)])])])):se("",!0)]),_:1}),Ce(gt,{name:"viewer-fade"},{default:Ze(()=>[we.value?(b(),_("div",y_,[o("section",b_,[o("header",null,[l[150]||(l[150]=o("div",null,[o("span",null,"快速角色"),o("strong",null,"创建角色档案问卷")],-1)),o("button",{type:"button",title:"关闭",onClick:l[29]||(l[29]=f=>vt("personaQuestionnaire"))},"×")]),o("div",__,[o("label",null,[l[151]||(l[151]=o("span",null,"角色核心",-1)),Te(o("textarea",{"onUpdate:modelValue":l[30]||(l[30]=f=>ie.value.roleCore=f),rows:"3",placeholder:"角色名、身份、核心定位,可以只写一句。"},null,512),[[Re,ie.value.roleCore]])]),o("label",null,[l[152]||(l[152]=o("span",null,"性格关键词",-1)),Te(o("textarea",{"onUpdate:modelValue":l[31]||(l[31]=f=>ie.value.personality=f),rows:"3",placeholder:"外显性格、内在矛盾、行动方式。"},null,512),[[Re,ie.value.personality]])]),o("label",null,[l[153]||(l[153]=o("span",null,"外观特征",-1)),Te(o("textarea",{"onUpdate:modelValue":l[32]||(l[32]=f=>ie.value.appearance=f),rows:"3",placeholder:"发色、发型、眼睛、五官和视觉记忆点。"},null,512),[[Re,ie.value.appearance]])]),o("label",null,[l[154]||(l[154]=o("span",null,"服装与配饰",-1)),Te(o("textarea",{"onUpdate:modelValue":l[33]||(l[33]=f=>ie.value.outfit=f),rows:"3",placeholder:"服装风格、配饰、武器或随身物。"},null,512),[[Re,ie.value.outfit]])]),o("label",null,[l[155]||(l[155]=o("span",null,"常用场景",-1)),Te(o("textarea",{"onUpdate:modelValue":l[34]||(l[34]=f=>ie.value.scene=f),rows:"3",placeholder:"常驻地点、画面背景、适合出现的环境。"},null,512),[[Re,ie.value.scene]])]),o("label",null,[l[156]||(l[156]=o("span",null,"避雷内容",-1)),Te(o("textarea",{"onUpdate:modelValue":l[35]||(l[35]=f=>ie.value.avoid=f),rows:"3",placeholder:"不想要的设计方向、负面词和禁用元素。"},null,512),[[Re,ie.value.avoid]])]),it.value==="advanced"?(b(),_(V,{key:0},[o("label",null,[l[157]||(l[157]=o("span",null,"世界观",-1)),Te(o("textarea",{"onUpdate:modelValue":l[36]||(l[36]=f=>ie.value.worldview=f),rows:"3",placeholder:"现代、赛博、奇幻、末世、校园、古风、星际等。"},null,512),[[Re,ie.value.worldview]])]),o("label",null,[l[158]||(l[158]=o("span",null,"背景经历",-1)),Te(o("textarea",{"onUpdate:modelValue":l[37]||(l[37]=f=>ie.value.background=f),rows:"3",placeholder:"所属组织、过往经历、当前处境。"},null,512),[[Re,ie.value.background]])]),o("label",null,[l[159]||(l[159]=o("span",null,"身高 / 身材",-1)),Te(o("textarea",{"onUpdate:modelValue":l[38]||(l[38]=f=>ie.value.heightBuild=f),rows:"3",placeholder:"身高范围、体型、姿态气质、肤色。"},null,512),[[Re,ie.value.heightBuild]])]),o("label",null,[l[160]||(l[160]=o("span",null,"身体记忆点",-1)),Te(o("textarea",{"onUpdate:modelValue":l[39]||(l[39]=f=>ie.value.bodyFeatures=f),rows:"3",placeholder:"伤疤、痣、纹身、义体、异色瞳等。"},null,512),[[Re,ie.value.bodyFeatures]])]),o("label",null,[l[161]||(l[161]=o("span",null,"喜好",-1)),Te(o("textarea",{"onUpdate:modelValue":l[40]||(l[40]=f=>ie.value.likes=f),rows:"3",placeholder:"颜色、食物、饮品、兴趣、常去地点。"},null,51
|