page-harness 0.1.0 → 0.1.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +23 -5
- package/README.zh-CN.md +23 -5
- package/THIRD_PARTY_LICENSES.md +31 -0
- package/dist/cli.js +574 -111
- package/dist/cli.js.map +1 -1
- package/dist/client/app/assets/history-Clt0CHe-.js +1 -0
- package/dist/client/app/assets/history-SejuExAu.css +1 -0
- package/dist/client/app/assets/{index.es-pLGXQA_f.js → index.es-BK9-mTsa.js} +1 -1
- package/dist/client/app/assets/{jspdf.es.min-OsUFBIXu.js → jspdf.es.min-Qzb6sJ_Q.js} +4 -4
- package/dist/client/app/assets/panel-B47-AaSQ.js +2 -0
- package/dist/client/app/assets/panel-CSA_nlud.css +1 -0
- package/dist/client/app/assets/{ws-B8OO397O.js → ws-DAWfQL6l.js} +21 -21
- package/dist/client/app/assets/{ws-BhXqMf5F.css → ws-DtkfUYSX.css} +1 -1
- package/dist/client/app/history.html +4 -4
- package/dist/client/app/panel.html +4 -4
- package/dist/client/page/live-overlay.js +6 -3
- package/dist/client/page/overlay.js +16 -13
- package/package.json +1 -1
- package/dist/client/app/assets/history-DTQ4t3U_.js +0 -1
- package/dist/client/app/assets/history-DfMi5ceT.css +0 -1
- package/dist/client/app/assets/panel-5OkTcFqg.css +0 -1
- package/dist/client/app/assets/panel-dt4wG7is.js +0 -2
|
@@ -1,15 +1,15 @@
|
|
|
1
1
|
const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["assets/javascript-Yelw-5ZN.js","assets/javascript-BzbQS41l.js","assets/typescript-Utq2Cl8c.js","assets/typescript-j_1H8WHN.js","assets/jsx-hEbJ82HF.js","assets/jsx-D3KKoC5L.js","assets/tsx-5f3ulCja.js","assets/tsx-BOvsFOI6.js","assets/json-CaljABEy.js","assets/json-B88Oqtu5.js","assets/html-WQKKblVZ.js","assets/html-DSw1lh5G.js","assets/css-BGIxQoYs.js","assets/css-DUjzNfgv.js","assets/scss-8bKmll0B.js","assets/vue-BqdMUtqy.js","assets/svelte-CdeT-Ich.js","assets/postcss-D_Wz94rJ.js","assets/astro-BZ97kZFP.js","assets/yaml-CxbubiML.js","assets/yaml-DijMHRDA.js","assets/xml-CoDIzWF0.js","assets/xml-WY0zc4PG.js","assets/java-BtIQNnN0.js","assets/bash-BiGZg9Om.js","assets/shellscript-CqHdAlCp.js","assets/java-DxlWrXwe.js","assets/c-DWGmR78Y.js","assets/c-SSSlmE39.js","assets/cpp-CJIxL8VH.js","assets/cpp-Cts1PyIS.js","assets/php-D7kNSOJl.js","assets/sql-CNu3Or2W.js","assets/ruby-dXJhvJjh.js","assets/graphql-DEIChqxY.js","assets/sql-BOsskAmu.js","assets/graphql-DAzSVzvB.js","assets/core-R68uHlmr.js","assets/rolldown-runtime-hePW80VL.js"])))=>i.map(i=>d[i]);
|
|
2
2
|
import{n as e}from"./rolldown-runtime-hePW80VL.js";(function(){let e=document.createElement(`link`).relList;if(e&&e.supports&&e.supports(`modulepreload`))return;for(let e of document.querySelectorAll(`link[rel="modulepreload"]`))n(e);new MutationObserver(e=>{for(let t of e)if(t.type===`childList`)for(let e of t.addedNodes)e.tagName===`LINK`&&e.rel===`modulepreload`&&n(e)}).observe(document,{childList:!0,subtree:!0});function t(e){let t={};return e.integrity&&(t.integrity=e.integrity),e.referrerPolicy&&(t.referrerPolicy=e.referrerPolicy),t.credentials=e.crossOrigin===`use-credentials`?`include`:e.crossOrigin===`anonymous`?`omit`:`same-origin`,t}function n(e){if(e.ep)return;e.ep=!0;let n=t(e);fetch(e.href,n)}})();function t(e){let t=Object.create(null);for(let n of e.split(`,`))t[n]=1;return e=>e in t}var n={},r=[],i=()=>{},a=()=>!1,o=e=>e.charCodeAt(0)===111&&e.charCodeAt(1)===110&&(e.charCodeAt(2)>122||e.charCodeAt(2)<97),s=e=>e.startsWith(`onUpdate:`),c=Object.assign,l=(e,t)=>{let n=e.indexOf(t);n>-1&&e.splice(n,1)},u=Object.prototype.hasOwnProperty,d=(e,t)=>u.call(e,t),f=Array.isArray,p=e=>S(e)===`[object Map]`,m=e=>S(e)===`[object Set]`,h=e=>S(e)===`[object Date]`,g=e=>typeof e==`function`,_=e=>typeof e==`string`,v=e=>typeof e==`symbol`,y=e=>typeof e==`object`&&!!e,b=e=>(y(e)||g(e))&&g(e.then)&&g(e.catch),x=Object.prototype.toString,S=e=>x.call(e),C=e=>S(e).slice(8,-1),ee=e=>S(e)===`[object Object]`,w=e=>_(e)&&e!==`NaN`&&e[0]!==`-`&&``+parseInt(e,10)===e,te=t(`,key,ref,ref_for,ref_key,onVnodeBeforeMount,onVnodeMounted,onVnodeBeforeUpdate,onVnodeUpdated,onVnodeBeforeUnmount,onVnodeUnmounted`),ne=e=>{let t=Object.create(null);return(n=>t[n]||(t[n]=e(n)))},re=/-\w/g,T=ne(e=>e.replace(re,e=>e.slice(1).toUpperCase())),ie=/\B([A-Z])/g,E=ne(e=>e.replace(ie,`-$1`).toLowerCase()),ae=ne(e=>e.charAt(0).toUpperCase()+e.slice(1)),oe=ne(e=>e?`on${ae(e)}`:``),se=(e,t)=>!Object.is(e,t),D=(e,...t)=>{for(let n=0;n<e.length;n++)e[n](...t)},ce=(e,t,n,r=!1)=>{Object.defineProperty(e,t,{configurable:!0,enumerable:!1,writable:r,value:n})},le=e=>{let t=parseFloat(e);return isNaN(t)?e:t},ue,de=()=>ue||=typeof globalThis<`u`?globalThis:typeof self<`u`?self:typeof window<`u`?window:typeof global<`u`?global:{};function O(e){if(f(e)){let t={};for(let n=0;n<e.length;n++){let r=e[n],i=_(r)?he(r):O(r);if(i)for(let e in i)t[e]=i[e]}return t}if(_(e)||y(e))return e}var fe=/;(?![^(]*\))/g,pe=/:([^]+)/,me=/"(?:[^"\\]|\\[^])*"|'(?:[^'\\]|\\[^])*'|\\[^]|\/\*[^]*?\*\//g;function he(e){let t={};return e.replace(me,e=>e.startsWith(`/*`)?``:e).split(fe).forEach(e=>{if(e){let n=e.split(pe);n.length>1&&(t[n[0].trim()]=n[1].trim())}}),t}function k(e){let t=``;if(_(e))t=e;else if(f(e))for(let n=0;n<e.length;n++){let r=k(e[n]);r&&(t+=r+` `)}else if(y(e))for(let n in e)e[n]&&(t+=n+` `);return t.trim()}var ge=`itemscope,allowfullscreen,formnovalidate,ismap,nomodule,novalidate,readonly`,_e=t(ge);ge+``;function ve(e){return!!e||e===``}function ye(e,t,n){if(e.length!==t.length)return!1;let r=!0;for(let i=0;r&&i<e.length;i++)r=xe(e[i],t[i],n);return r}function A(e,t,n){if(e.size!==t.size)return!1;let r=Array.from(t),i=new Uint8Array(r.length);for(let t of e){let e=-1;for(let a=0;a<r.length;a++)if(!i[a]&&xe(t,r[a],n)){e=a;break}if(e<0)return!1;i[e]=1}return!0}function be(e,t,n){let r=p(e),i=p(t);if(r||i||(r=m(e),i=m(t),r||i))return r&&i?A(e,t,n):!1;if(Object.keys(e).length!==Object.keys(t).length)return!1;for(let r in e){let i=e.hasOwnProperty(r),a=t.hasOwnProperty(r);if(i&&!a||!i&&a||!xe(e[r],t[r],n))return!1}return String(e)===String(t)}function j(e,t,n,r){n||=[new Map,new Map];let[i,a]=n;if(i.has(e)||a.has(t))return i.get(e)===t&&a.get(t)===e;i.set(e,t),a.set(t,e);let o=r(e,t,n);return i.delete(e),a.delete(t),o}function xe(e,t,n){if(e===t)return!0;let r=h(e),i=h(t);return r||i?r&&i?e.getTime()===t.getTime():!1:(r=v(e),i=v(t),r||i?e===t:(r=f(e),i=f(t),r||i?r&&i?j(e,t,n,ye):!1:(r=y(e),i=y(t),r||i?!r||!i?!1:j(e,t,n,be):String(e)===String(t))))}function Se(e,t){return e.findIndex(e=>xe(e,t))}var Ce=e=>!!(e&&e.__v_isRef===!0),M=e=>_(e)?e:e==null?``:f(e)||y(e)&&(e.toString===x||!g(e.toString))?Ce(e)?M(e.value):JSON.stringify(e,we,2):String(e),we=(e,t)=>Ce(t)?we(e,t.value):p(t)?{[`Map(${t.size})`]:[...t.entries()].reduce((e,[t,n],r)=>(e[Te(t,r)+` =>`]=n,e),{})}:m(t)?{[`Set(${t.size})`]:[...t.values()].map(e=>Te(e))}:v(t)?Te(t):y(t)&&!f(t)&&!ee(t)?String(t):t,Te=(e,t=``)=>v(e)?`Symbol(${e.description??t})`:e,N,Ee=class{constructor(e=!1){this.detached=e,this._active=!0,this._on=0,this.effects=[],this.cleanups=[],this._isPaused=!1,this._warnOnRun=!0,this.__v_skip=!0,!e&&N&&(N.active?(this.parent=N,this.index=(N.scopes||(N.scopes=[])).push(this)-1):(this._active=!1,this._warnOnRun=!1))}get active(){return this._active}pause(){if(this._active){this._isPaused=!0;let e,t;if(this.scopes){let n=this.scopes.slice();for(e=0,t=n.length;e<t;e++)n[e].pause()}for(e=0,t=this.effects.length;e<t;e++)this.effects[e].pause()}}resume(){if(this._active&&this._isPaused){this._isPaused=!1;let e,t;if(this.scopes){let n=this.scopes.slice();for(e=0,t=n.length;e<t;e++)n[e].resume()}let n=this.effects.slice();for(e=0,t=n.length;e<t;e++)n[e].resume()}}run(e){if(this._active){let t=N;try{return N=this,e()}finally{N=t}}}on(){++this._on===1&&(this.prevScope=N,N=this)}off(){if(this._on>0&&--this._on===0){if(N===this)N=this.prevScope;else{let e=N;for(;e;){if(e.prevScope===this){e.prevScope=this.prevScope;break}e=e.prevScope}}this.prevScope=void 0}}stop(e){if(this._active){this._active=!1;let t,n;for(t=0,n=this.effects.length;t<n;t++)this.effects[t].stop();for(this.effects.length=0,t=0,n=this.cleanups.length;t<n;t++)this.cleanups[t]();if(this.cleanups.length=0,this.scopes){let e=this.scopes.slice();for(t=0,n=e.length;t<n;t++)e[t].stop(!0);this.scopes.length=0}if(!this.detached&&this.parent&&!e){let e=this.parent.scopes.pop();e&&e!==this&&(this.parent.scopes[this.index]=e,e.index=this.index)}this.parent=void 0}}};function De(){return N}var P,Oe=new WeakSet,ke=class{constructor(e){this.fn=e,this.deps=void 0,this.depsTail=void 0,this.flags=5,this.next=void 0,this.cleanup=void 0,this.scheduler=void 0,N&&(N.active?N.effects.push(this):this.flags&=-2)}pause(){this.flags|=64}resume(){this.flags&64&&(this.flags&=-65,Oe.has(this)&&(Oe.delete(this),this.trigger()))}notify(){this.flags&2&&!(this.flags&32)||this.flags&8||Ne(this)}run(){if(!(this.flags&1))return this.fn();this.flags|=2,Ke(this),Ie(this);let e=P,t=He;P=this,He=!0;try{return this.fn()}finally{Le(this),P=e,He=t,this.flags&=-3}}stop(){if(this.flags&1){for(let e=this.deps;e;e=e.nextDep)Be(e);this.deps=this.depsTail=void 0,Ke(this),this.onStop&&this.onStop(),this.flags&=-2}}trigger(){this.flags&64?Oe.add(this):this.scheduler?this.scheduler():this.runIfDirty()}runIfDirty(){Re(this)&&this.run()}get dirty(){return Re(this)}},Ae=0,je,Me;function Ne(e,t=!1){if(e.flags|=8,t){e.next=Me,Me=e;return}e.next=je,je=e}function Pe(){Ae++}function Fe(){if(--Ae>0)return;if(Me){let e=Me;for(Me=void 0;e;){let t=e.next;e.next=void 0,e.flags&=-9,e=t}}let e;for(;je;){let t=je;for(je=void 0;t;){let n=t.next;if(t.next=void 0,t.flags&=-9,t.flags&1)try{t.trigger()}catch(t){e||=t}t=n}}if(e)throw e}function Ie(e){for(let t=e.deps;t;t=t.nextDep)t.version=-1,t.prevActiveLink=t.dep.activeLink,t.dep.activeLink=t}function Le(e){let t,n=e.depsTail,r=n;for(;r;){let e=r.prevDep;r.version===-1?(r===n&&(n=e),Be(r),Ve(r)):t=r,r.dep.activeLink=r.prevActiveLink,r.prevActiveLink=void 0,r=e}e.deps=t,e.depsTail=n}function Re(e){for(let t=e.deps;t;t=t.nextDep)if(t.dep.version!==t.version||t.dep.computed&&(ze(t.dep.computed)||t.dep.version!==t.version))return!0;return!!e._dirty}function ze(e){if(e.flags&4&&!(e.flags&16)||(e.flags&=-17,e.globalVersion===qe)||(e.globalVersion=qe,!e.isSSR&&e.flags&128&&(!e.deps&&!e._dirty||!Re(e))))return;e.flags|=2;let t=e.dep,n=P,r=He;P=e,He=!0;try{Ie(e);let n=e.fn(e._value);(t.version===0||se(n,e._value))&&(e.flags|=128,e._value=n,t.version++)}catch(e){throw t.version++,e}finally{P=n,He=r,Le(e),e.flags&=-3}}function Be(e,t=!1){let{dep:n,prevSub:r,nextSub:i}=e;if(r&&(r.nextSub=i,e.prevSub=void 0),i&&(i.prevSub=r,e.nextSub=void 0),n.subs===e&&(n.subs=r,!r&&n.computed)){n.computed.flags&=-5;for(let e=n.computed.deps;e;e=e.nextDep)Be(e,!0)}!t&&!--n.sc&&n.map&&n.map.delete(n.key)}function Ve(e){let{prevDep:t,nextDep:n}=e;t&&(t.nextDep=n,e.prevDep=void 0),n&&(n.prevDep=t,e.nextDep=void 0)}var He=!0,Ue=[];function We(){Ue.push(He),He=!1}function Ge(){let e=Ue.pop();He=e===void 0||e}function Ke(e){let{cleanup:t}=e;if(e.cleanup=void 0,t){let e=P;P=void 0;try{t()}finally{P=e}}}var qe=0,Je=class{constructor(e,t){this.sub=e,this.dep=t,this.version=t.version,this.nextDep=this.prevDep=this.nextSub=this.prevSub=this.prevActiveLink=void 0}},Ye=class{constructor(e){this.computed=e,this.version=0,this.activeLink=void 0,this.subs=void 0,this.map=void 0,this.key=void 0,this.sc=0,this.__v_skip=!0}track(e){if(!P||!He||P===this.computed)return;let t=this.activeLink;if(t===void 0||t.sub!==P)t=this.activeLink=new Je(P,this),P.deps?(t.prevDep=P.depsTail,P.depsTail.nextDep=t,P.depsTail=t):P.deps=P.depsTail=t,Xe(t);else if(t.version===-1&&(t.version=this.version,t.nextDep)){let e=t.nextDep;e.prevDep=t.prevDep,t.prevDep&&(t.prevDep.nextDep=e),t.prevDep=P.depsTail,t.nextDep=void 0,P.depsTail.nextDep=t,P.depsTail=t,P.deps===t&&(P.deps=e)}return t}trigger(e){this.version++,qe++,this.notify(e)}notify(e){Pe();try{for(let e=this.subs;e;e=e.prevSub)e.sub.notify()&&e.sub.dep.notify()}finally{Fe()}}};function Xe(e){if(e.dep.sc++,e.sub.flags&4){let t=e.dep.computed;if(t&&!e.dep.subs){t.flags|=20;for(let e=t.deps;e;e=e.nextDep)Xe(e)}let n=e.dep.subs;n!==e&&(e.prevSub=n,n&&(n.nextSub=e)),e.dep.subs=e}}var Ze=new WeakMap,Qe=Symbol(``),$e=Symbol(``),et=Symbol(``);function tt(e,t,n){if(He&&P){let t=Ze.get(e);t||Ze.set(e,t=new Map);let r=t.get(n);r||(t.set(n,r=new Ye),r.map=t,r.key=n),r.track()}}function nt(e,t,n,r,i,a){let o=Ze.get(e);if(!o){qe++;return}let s=e=>{e&&e.trigger()};if(Pe(),t===`clear`)o.forEach(s);else{let i=f(e),a=i&&w(n);if(i&&n===`length`){let e=Number(r);o.forEach((t,n)=>{(n===`length`||n===et||!v(n)&&n>=e)&&s(t)})}else switch((n!==void 0||o.has(void 0))&&s(o.get(n)),a&&s(o.get(et)),t){case`add`:i?a&&s(o.get(`length`)):(s(o.get(Qe)),p(e)&&s(o.get($e)));break;case`delete`:i||(s(o.get(Qe)),p(e)&&s(o.get($e)));break;case`set`:p(e)&&s(o.get(Qe))}}Fe()}function rt(e){let t=I(e);return t===e||(tt(t,`iterate`,et),Vt(e))?t:Bt(e)?zt(e)?t.map(e=>Gt(Wt(e))):t.map(Gt):t.map(Wt)}function it(e){return tt(e=I(e),`iterate`,et),e}function at(e,t){return Bt(e)?Gt(zt(e)?Wt(t):t):Wt(t)}var ot={__proto__:null,[Symbol.iterator](){return st(this,Symbol.iterator,e=>at(this,e))},concat(...e){return rt(this).concat(...e.map(e=>f(e)?rt(e):e))},entries(){return st(this,`entries`,e=>(e[1]=at(this,e[1]),e))},every(e,t){return F(this,`every`,e,t,void 0,arguments)},filter(e,t){return F(this,`filter`,e,t,e=>e.map(e=>at(this,e)),arguments)},find(e,t){return F(this,`find`,e,t,e=>at(this,e),arguments)},findIndex(e,t){return F(this,`findIndex`,e,t,void 0,arguments)},findLast(e,t){return F(this,`findLast`,e,t,e=>at(this,e),arguments)},findLastIndex(e,t){return F(this,`findLastIndex`,e,t,void 0,arguments)},forEach(e,t){return F(this,`forEach`,e,t,void 0,arguments)},includes(...e){return ut(this,`includes`,e)},indexOf(...e){return ut(this,`indexOf`,e)},join(e){return rt(this).join(e)},lastIndexOf(...e){return ut(this,`lastIndexOf`,e)},map(e,t){return F(this,`map`,e,t,void 0,arguments)},pop(){return dt(this,`pop`)},push(...e){return dt(this,`push`,e)},reduce(e,...t){return lt(this,`reduce`,e,t)},reduceRight(e,...t){return lt(this,`reduceRight`,e,t)},shift(){return dt(this,`shift`)},some(e,t){return F(this,`some`,e,t,void 0,arguments)},splice(...e){return dt(this,`splice`,e)},toReversed(){return rt(this).toReversed()},toSorted(e){return rt(this).toSorted(e)},toSpliced(...e){return rt(this).toSpliced(...e)},unshift(...e){return dt(this,`unshift`,e)},values(){return st(this,`values`,e=>at(this,e))}};function st(e,t,n){let r=it(e),i=r[t]();return r!==e&&!Vt(e)&&(i._next=i.next,i.next=()=>{let e=i._next();return e.done||(e.value=n(e.value)),e}),i}var ct=Array.prototype;function F(e,t,n,r,i,a){let o=it(e),s=o!==e&&!Vt(e),c=o[t];if(c!==ct[t]){let t=c.apply(e,a);return s?Wt(t):t}let l=n;o!==e&&(s?l=function(t,r){return n.call(this,at(e,t),r,e)}:n.length>2&&(l=function(t,r){return n.call(this,t,r,e)}));let u=c.call(o,l,r);return s&&i?i(u):u}function lt(e,t,n,r){let i=it(e),a=i!==e&&!Vt(e),o=n,s=!1;i!==e&&(a?(s=r.length===0,o=function(t,r,i){return s&&(s=!1,t=at(e,t)),n.call(this,t,at(e,r),i,e)}):n.length>3&&(o=function(t,r,i){return n.call(this,t,r,i,e)}));let c=i[t](o,...r);return s?at(e,c):c}function ut(e,t,n){let r=I(e);tt(r,`iterate`,et);let i=r[t](...n);return(i===-1||i===!1)&&Ht(n[0])?(n[0]=I(n[0]),r[t](...n)):i}function dt(e,t,n=[]){We(),Pe();let r=I(e)[t].apply(e,n);return Fe(),Ge(),r}var ft=t(`__proto__,__v_isRef,__isVue`),pt=new Set(Object.getOwnPropertyNames(Symbol).filter(e=>e!==`arguments`&&e!==`caller`).map(e=>Symbol[e]).filter(v));function mt(e){v(e)||(e=String(e));let t=I(this);return tt(t,`has`,e),t.hasOwnProperty(e)}var ht=class{constructor(e=!1,t=!1){this._isReadonly=e,this._isShallow=t}get(e,t,n){if(t===`__v_skip`)return e.__v_skip;let r=this._isReadonly,i=this._isShallow;if(t===`__v_isReactive`)return!r;if(t===`__v_isReadonly`)return r;if(t===`__v_isShallow`)return i;if(t===`__v_raw`)return n===(r?i?Nt:Mt:i?jt:At).get(e)||Object.getPrototypeOf(e)===Object.getPrototypeOf(n)?e:void 0;let a=f(e);if(!r){let e;if(a&&(e=ot[t]))return e;if(t===`hasOwnProperty`)return mt}let o=Reflect.get(e,t,L(e)?e:n);if((v(t)?pt.has(t):ft(t))||(r||tt(e,`get`,t),i))return o;if(L(o)){let e=a&&w(t)?o:o.value;return r&&y(e)?Lt(e):e}return y(o)?r?Lt(o):Ft(o):o}},gt=class extends ht{constructor(e=!1){super(!1,e)}set(e,t,n,r){let i=e[t],a=f(e)&&w(t);if(!this._isShallow){let e=Bt(i);if(!Vt(n)&&!Bt(n)&&(i=I(i),n=I(n)),!a&&L(i)&&!L(n))return e||(i.value=n),!0}let o=a?Number(t)<e.length:d(e,t),s=Reflect.set(e,t,n,L(e)?e:r);return e===I(r)&&s&&(o?se(n,i)&&nt(e,`set`,t,n,i):nt(e,`add`,t,n)),s}deleteProperty(e,t){let n=d(e,t),r=e[t],i=Reflect.deleteProperty(e,t);return i&&n&&nt(e,`delete`,t,void 0,r),i}has(e,t){let n=Reflect.has(e,t);return(!v(t)||!pt.has(t))&&tt(e,`has`,t),n}ownKeys(e){return tt(e,`iterate`,f(e)?`length`:Qe),Reflect.ownKeys(e)}},_t=class extends ht{constructor(e=!1){super(!0,e)}set(e,t){return!0}deleteProperty(e,t){return!0}},vt=new gt,yt=new _t,bt=new gt(!0),xt=e=>e,St=e=>Reflect.getPrototypeOf(e);function Ct(e,t,n){return function(...r){let i=this.__v_raw,a=I(i),o=p(a),s=e===`entries`||e===Symbol.iterator&&o,l=e===`keys`&&o,u=i[e](...r),d=n?xt:t?Gt:Wt;return!t&&tt(a,`iterate`,l?$e:Qe),c(Object.create(u),{next(){let{value:e,done:t}=u.next();return t?{value:e,done:t}:{value:s?[d(e[0]),d(e[1])]:d(e),done:t}}})}}function wt(e){return function(...t){return e===`delete`?!1:e===`clear`?void 0:this}}function Tt(e,t){let n={get(n){let r=this.__v_raw,i=I(r),a=I(n);e||(se(n,a)&&tt(i,`get`,n),tt(i,`get`,a));let{has:o}=St(i),s=t?xt:e?Gt:Wt;if(o.call(i,n))return s(r.get(n));if(o.call(i,a))return s(r.get(a));r!==i&&r.get(n)},get size(){let t=this.__v_raw;return!e&&tt(I(t),`iterate`,Qe),t.size},has(t){let n=this.__v_raw,r=I(n),i=I(t);return e||(se(t,i)&&tt(r,`has`,t),tt(r,`has`,i)),t===i?n.has(t):n.has(t)||n.has(i)},forEach(n,r){let i=this,a=i.__v_raw,o=I(a),s=t?xt:e?Gt:Wt;return!e&&tt(o,`iterate`,Qe),a.forEach((e,t)=>n.call(r,s(e),s(t),i))}};return c(n,e?{add:wt(`add`),set:wt(`set`),delete:wt(`delete`),clear:wt(`clear`)}:{add(e){let n=I(this),r=St(n),i=I(e),a=!t&&!Vt(e)&&!Bt(e)?i:e;return r.has.call(n,a)||se(e,a)&&r.has.call(n,e)||se(i,a)&&r.has.call(n,i)||(n.add(a),nt(n,`add`,a,a)),this},set(e,n){!t&&!Vt(n)&&!Bt(n)&&(n=I(n));let r=I(this),{has:i,get:a}=St(r),o=i.call(r,e);o||=(e=I(e),i.call(r,e));let s=a.call(r,e);return r.set(e,n),o?se(n,s)&&nt(r,`set`,e,n,s):nt(r,`add`,e,n),this},delete(e){let t=I(this),{has:n,get:r}=St(t),i=n.call(t,e);i||=(e=I(e),n.call(t,e));let a=r?r.call(t,e):void 0,o=t.delete(e);return i&&nt(t,`delete`,e,void 0,a),o},clear(){let e=I(this),t=e.size!==0,n=e.clear();return t&&nt(e,`clear`,void 0,void 0,void 0),n}}),[`keys`,`values`,`entries`,Symbol.iterator].forEach(r=>{n[r]=Ct(r,e,t)}),n}function Et(e,t){let n=Tt(e,t);return(t,r,i)=>r===`__v_isReactive`?!e:r===`__v_isReadonly`?e:r===`__v_raw`?t:Reflect.get(d(n,r)&&r in t?n:t,r,i)}var Dt={get:Et(!1,!1)},Ot={get:Et(!1,!0)},kt={get:Et(!0,!1)},At=new WeakMap,jt=new WeakMap,Mt=new WeakMap,Nt=new WeakMap;function Pt(e){switch(e){case`Object`:case`Array`:return 1;case`Map`:case`Set`:case`WeakMap`:case`WeakSet`:return 2;default:return 0}}function Ft(e){return Bt(e)?e:Rt(e,!1,vt,Dt,At)}function It(e){return Rt(e,!1,bt,Ot,jt)}function Lt(e){return Rt(e,!0,yt,kt,Mt)}function Rt(e,t,n,r,i){if(!y(e)||e.__v_raw&&!(t&&e.__v_isReactive)||e.__v_skip||!Object.isExtensible(e))return e;let a=i.get(e);if(a)return a;let o=Pt(C(e));if(o===0)return e;let s=new Proxy(e,o===2?r:n);return i.set(e,s),s}function zt(e){return Bt(e)?zt(e.__v_raw):!!(e&&e.__v_isReactive)}function Bt(e){return!!(e&&e.__v_isReadonly)}function Vt(e){return!!(e&&e.__v_isShallow)}function Ht(e){return e?!!e.__v_raw:!1}function I(e){let t=e&&e.__v_raw;return t?I(t):e}function Ut(e){return!d(e,`__v_skip`)&&Object.isExtensible(e)&&ce(e,`__v_skip`,!0),e}var Wt=e=>y(e)?Ft(e):e,Gt=e=>y(e)?Lt(e):e;function L(e){return e?e.__v_isRef===!0:!1}function Kt(e){return Jt(e,!1)}function qt(e){return Jt(e,!0)}function Jt(e,t){return L(e)?e:new Yt(e,t)}var Yt=class{constructor(e,t){this.dep=new Ye,this.__v_isRef=!0,this.__v_isShallow=!1,this._rawValue=t?e:I(e),this._value=t?e:Wt(e),this.__v_isShallow=t}get value(){return this.dep.track(),this._value}set value(e){let t=this._rawValue,n=this.__v_isShallow||Vt(e)||Bt(e);e=n?e:I(e),se(e,t)&&(this._rawValue=e,this._value=n?e:Wt(e),this.dep.trigger())}};function R(e){return L(e)?e.value:e}var Xt={get:(e,t,n)=>t===`__v_raw`?e:R(Reflect.get(e,t,n)),set:(e,t,n,r)=>{let i=e[t];return L(i)&&!L(n)?(i.value=n,!0):Reflect.set(e,t,n,r)}};function Zt(e){return zt(e)?e:new Proxy(e,Xt)}var Qt=class{constructor(e,t,n){this.fn=e,this.setter=t,this._value=void 0,this.dep=new Ye(this),this.__v_isRef=!0,this.deps=void 0,this.depsTail=void 0,this.flags=16,this.globalVersion=qe-1,this.next=void 0,this.effect=this,this.__v_isReadonly=!t,this.isSSR=n}notify(){if(this.flags|=16,!(this.flags&8)&&P!==this)return Ne(this,!0),!0}get value(){let e=this.dep.track();return ze(this),e&&(e.version=this.dep.version),this._value}set value(e){this.setter&&this.setter(e)}};function $t(e,t,n=!1){let r,i;return g(e)?r=e:(r=e.get,i=e.set),new Qt(r,i,n)}var en={},tn=new WeakMap,nn=void 0;function rn(e,t=!1,n=nn){if(n){let t=tn.get(n);t||tn.set(n,t=[]),t.push(e)}}function an(e,t,r=n){let{immediate:a,deep:o,once:s,scheduler:c,augmentJob:u,call:d}=r,p=e=>o?e:Vt(e)||o===!1||o===0?on(e,1):on(e),m,h,_,v,y=!1,b=!1;if(L(e)?(h=()=>e.value,y=Vt(e)):zt(e)?(h=()=>p(e),y=!0):f(e)?(b=!0,y=e.some(e=>zt(e)||Vt(e)),h=()=>e.map(e=>{if(L(e))return e.value;if(zt(e))return p(e);if(g(e))return d?d(e,2):e()})):h=g(e)?t?d?()=>d(e,2):e:()=>{if(_){We();try{_()}finally{Ge()}}let t=nn;nn=m;try{return d?d(e,3,[v]):e(v)}finally{nn=t}}:i,t&&o){let e=h,t=o===!0?1/0:o;h=()=>on(e(),t)}let x=De(),S=()=>{m.stop(),x&&x.active&&l(x.effects,m)};if(s&&t){let e=t;t=(...t)=>{let n=e(...t);return S(),n}}let C=b?Array(e.length).fill(en):en,ee=e=>{if(m.flags&1&&(m.dirty||e)){if(t){let n=m.run();if(e||o||y||(b?n.some((e,t)=>se(e,C[t])):se(n,C))){_&&_();let e=nn;nn=m;try{let e=[n,C===en?void 0:b&&C[0]===en?[]:C,v];C=n,d?d(t,3,e):t(...e)}finally{nn=e}}}else m.run()}};return u&&u(ee),m=new ke(h),m.scheduler=c?()=>c(ee,!1):ee,v=e=>rn(e,!1,m),_=m.onStop=()=>{let e=tn.get(m);if(e){if(d)d(e,4);else for(let t of e)t();tn.delete(m)}},t?a?ee(!0):C=m.run():c?c(ee.bind(null,!0),!0):m.run(),S.pause=m.pause.bind(m),S.resume=m.resume.bind(m),S.stop=S,S}function on(e,t=1/0,n){if(t<=0||!y(e)||e.__v_skip||(n||=new Map,(n.get(e)||0)>=t))return e;if(n.set(e,t),t--,L(e))on(e.value,t,n);else if(f(e))for(let r=0;r<e.length;r++)on(e[r],t,n);else if(m(e)||p(e))e.forEach(e=>{on(e,t,n)});else if(ee(e)){for(let r in e)on(e[r],t,n);for(let r of Object.getOwnPropertySymbols(e))Object.prototype.propertyIsEnumerable.call(e,r)&&on(e[r],t,n)}return e}function sn(e,t,n,r){try{return r?e(...r):e()}catch(e){ln(e,t,n)}}function cn(e,t,n,r){if(g(e)){let i=sn(e,t,n,r);return i&&b(i)&&i.catch(e=>{ln(e,t,n)}),i}if(f(e)){let i=[];for(let a=0;a<e.length;a++)i.push(cn(e[a],t,n,r));return i}}function ln(e,t,r,i=!0){let a=t?t.vnode:null,{errorHandler:o,throwUnhandledErrorInProduction:s}=t&&t.appContext.config||n;if(t){let n=t.parent,i=t.proxy,a=`https://vuejs.org/error-reference/#runtime-${r}`;for(;n;){let t=n.ec;if(t){for(let n=0;n<t.length;n++)if(t[n](e,i,a)===!1)return}n=n.parent}if(o){We(),sn(o,null,10,[e,i,a]),Ge();return}}un(e,r,a,i,s)}function un(e,t,n,r=!0,i=!1){if(i)throw e;console.error(e)}var dn=[],fn=-1,pn=[],mn=null,hn=0,gn=Promise.resolve(),_n=null;function vn(e){let t=_n||gn;return e?t.then(this?e.bind(this):e):t}function yn(e){let t=fn+1,n=dn.length;for(;t<n;){let r=t+n>>>1,i=dn[r],a=Tn(i);a<e||a===e&&i.flags&2?t=r+1:n=r}return t}function bn(e){if(!(e.flags&1)){let t=Tn(e),n=dn[dn.length-1];!n||!(e.flags&2)&&t>=Tn(n)?dn.push(e):dn.splice(yn(t),0,e),e.flags|=1,xn()}}function xn(){_n||=gn.then(En)}function Sn(e){if(!f(e))mn&&e.id===-1?mn.splice(hn+1,0,e):e.flags&1||(pn.push(e),e.flags|=1);else for(let t=0;t<e.length;t++)pn.push(e[t]);xn()}function Cn(e,t,n=fn+1){for(;n<dn.length;n++){let t=dn[n];if(t&&t.flags&2){if(e&&t.id!==e.uid)continue;dn.splice(n,1),n--,t.flags&4&&(t.flags&=-2),t(),t.flags&4||(t.flags&=-2)}}}function wn(e){if(pn.length){let e=[...new Set(pn)].sort((e,t)=>Tn(e)-Tn(t));if(pn.length=0,mn){for(let t=0;t<e.length;t++)mn.push(e[t]);return}for(mn=e,hn=0;hn<mn.length;hn++){let e=mn[hn];e.flags&4&&(e.flags&=-2),e.flags&8||e(),e.flags&=-2}mn=null,hn=0}}var Tn=e=>e.id==null?e.flags&2?-1:1/0:e.id;function En(e){try{for(fn=0;fn<dn.length;fn++){let e=dn[fn];e&&!(e.flags&8)&&(e.flags&4&&(e.flags&=-2),sn(e,e.i,e.i?15:14),e.flags&4||(e.flags&=-2))}}finally{for(;fn<dn.length;fn++){let e=dn[fn];e&&(e.flags&=-2)}fn=-1,dn.length=0,wn(e),_n=null,(dn.length||pn.length)&&En(e)}}var Dn=null,On=null;function kn(e){let t=Dn;return Dn=e,On=e&&e.type.__scopeId||null,t}function An(e,t=Dn,n){if(!t||e._n)return e;let r=(...n)=>{r._d&&Wi(-1);let i=kn(t),a=Bi.length,o;try{o=e(...n)}finally{for(let e=Bi.length;e>a;e--)Hi();kn(i),r._d&&Wi(1)}return o};return r._n=!0,r._c=!0,r._d=!0,r}function jn(e,t){if(Dn===null)return e;let r=Ca(Dn),i=e.dirs||=[];for(let e=0;e<t.length;e++){let[a,o,s,c=n]=t[e];a&&(g(a)&&(a={mounted:a,updated:a}),a.deep&&on(o),i.push({dir:a,instance:r,value:o,oldValue:void 0,arg:s,modifiers:c}))}return e}function Mn(e,t,n,r){let i=e.dirs,a=t&&t.dirs;for(let o=0;o<i.length;o++){let s=i[o];a&&(s.oldValue=a[o].value);let c=s.dir[r];c&&(We(),cn(c,n,8,[e.el,s,e,t]),Ge())}}function Nn(e,t){if(la){let n=la.provides,r=la.parent&&la.parent.provides;r===n&&(n=la.provides=Object.create(r)),n[e]=t}}function Pn(e,t,n=!1){let r=ua();if(r||qr){let i=qr?qr._context.provides:r?r.parent==null||r.ce?r.vnode.appContext&&r.vnode.appContext.provides:r.parent.provides:void 0;if(i&&e in i)return i[e];if(arguments.length>1)return n&&g(t)?t.call(r&&r.proxy):t}}var Fn=Symbol.for(`v-scx`),In=()=>Pn(Fn);function Ln(e,t){return zn(e,null,t)}function Rn(e,t,n){return zn(e,t,n)}function zn(e,t,r=n){let{immediate:a,deep:o,flush:s,once:l}=r,u=c({},r),d=t&&a||!t&&s!==`post`,f;if(ga){if(s===`sync`){let e=In();f=e.__watcherHandles||=[]}else if(!d){let e=()=>{};return e.stop=i,e.resume=i,e.pause=i,e}}let p=la;u.call=(e,t,n)=>cn(e,p,t,n);let m=!1;s===`post`?u.scheduler=e=>{wi(e,p&&p.suspense)}:s!==`sync`&&(m=!0,u.scheduler=(e,t)=>{t?e():bn(e)}),u.augmentJob=e=>{t&&(e.flags|=4),m&&(e.flags|=2,p&&(e.id=p.uid,e.i=p))};let h=an(e,t,u);return ga&&(f?f.push(h):d&&h()),h}function Bn(e,t,n){let r=this.proxy,i=_(e)?e.includes(`.`)?Vn(r,e):()=>r[e]:e.bind(r,r),a;g(t)?a=t:(a=t.handler,n=t);let o=pa(this),s=zn(i,a.bind(r),n);return o(),s}function Vn(e,t){let n=t.split(`.`);return()=>{let t=e;for(let e=0;e<n.length&&t;e++)t=t[n[e]];return t}}var Hn=Symbol(`_vte`),Un=e=>e.__isTeleport,Wn=Symbol(`_leaveCb`);function Gn(e){let t=e[0];if(e.length>1){for(let n of e)if(n.type!==Ri){t=n;break}}return t}function Kn(e){if(!tr(e))return Un(e.type)&&e.children?Gn(e.children):e;if(e.component)return e.component.subTree;let{shapeFlag:t,children:n}=e;if(n){if(t&16)return n[0];if(t&32&&g(n.default))return n.default()}}function qn(e,t){if(e.shapeFlag&6&&e.component){e.transition=t;let n=e.component.subTree;qn(Un(n.type)&&Kn(n)||n,t)}else e.shapeFlag&128?(e.ssContent.transition=t.clone(e.ssContent),e.ssFallback.transition=t.clone(e.ssFallback)):e.transition=t}function Jn(e,t){return g(e)?c({name:e.name},t,{setup:e}):e}function Yn(e){e.ids=[e.ids[0]+e.ids[2]+++`-`,0,0]}function Xn(e,t){let n;return!!((n=Object.getOwnPropertyDescriptor(e,t))&&!n.configurable)}var Zn=new WeakMap;function Qn(e,t,r,i,o=!1){if(f(e)){e.forEach((e,n)=>Qn(e,t&&(f(t)?t[n]:t),r,i,o));return}if(er(i)&&!o){i.shapeFlag&512&&i.type.__asyncResolved&&i.component.subTree.component&&Qn(e,t,r,i.component.subTree);return}let s=i.shapeFlag&4?Ca(i.component):i.el,c=o?null:s,{i:u,r:p}=e,m=t&&t.r,h=u.refs===n?u.refs={}:u.refs,v=u.setupState,y=I(v),b=v===n?a:e=>!Xn(h,e)&&d(y,e),x=(e,t)=>!(t&&Xn(h,t));if(m!=null&&m!==p){if($n(t),_(m))h[m]=null,b(m)&&(v[m]=null);else if(L(m)){let e=t;x(m,e.k)&&(m.value=null),e.k&&(h[e.k]=null)}}if(g(p))sn(p,u,12,[c,h]);else{let t=_(p),n=L(p);if(t||n){let i=()=>{if(e.f){let n=t?b(p)?v[p]:h[p]:x(p)||!e.k?p.value:h[e.k];if(o)f(n)&&l(n,s);else if(f(n))n.includes(s)||n.push(s);else if(t)h[p]=[s],b(p)&&(v[p]=h[p]);else{let t=[s];x(p,e.k)&&(p.value=t),e.k&&(h[e.k]=t)}}else t?(h[p]=c,b(p)&&(v[p]=c)):n&&(x(p,e.k)&&(p.value=c),e.k&&(h[e.k]=c))};if(c){let t=()=>{i(),Zn.delete(e)};t.id=-1,Zn.set(e,t),wi(t,r)}else $n(e),i()}}}function $n(e){let t=Zn.get(e);t&&(t.flags|=8,Zn.delete(e))}de().requestIdleCallback,de().cancelIdleCallback;var er=e=>!!e.type.__asyncLoader,tr=e=>e.type.__isKeepAlive;function nr(e,t){ir(e,`a`,t)}function rr(e,t){ir(e,`da`,t)}function ir(e,t,n=la){let r=e.__wdc||=()=>{let t=n;for(;t;){if(t.isDeactivated)return;t=t.parent}return e()};if(or(t,r,n),n){let e=n.parent;for(;e&&e.parent;)tr(e.parent.vnode)&&ar(r,t,n,e),e=e.parent}}function ar(e,t,n,r){let i=or(t,e,r,!0);pr(()=>{l(r[t],i)},n)}function or(e,t,n=la,r=!1){if(n){let i=n[e]||(n[e]=[]),a=t.__weh||=(...r)=>{We();let i=pa(n),a=cn(t,n,e,r);return i(),Ge(),a};return r?i.unshift(a):i.push(a),a}}var sr=e=>(t,n=la)=>{(!ga||e===`sp`)&&or(e,(...e)=>t(...e),n)},cr=sr(`bm`),lr=sr(`m`),ur=sr(`bu`),dr=sr(`u`),fr=sr(`bum`),pr=sr(`um`),mr=sr(`sp`),hr=sr(`rtg`),gr=sr(`rtc`);function _r(e,t=la){or(`ec`,e,t)}var vr=`components`;function yr(e,t){return xr(vr,e,!0,t)||e}var br=Symbol.for(`v-ndc`);function xr(e,t,n=!0,r=!1){let i=Dn||la;if(i){let n=i.type;if(e===vr){let e=wa(n,!1);if(e&&(e===t||e===T(t)||e===ae(T(t))))return n}let a=Sr(i[e]||n[e],t)||Sr(i.appContext[e],t);return!a&&r?n:a}}function Sr(e,t){return e&&(e[t]||e[T(t)]||e[ae(T(t))])}function Cr(e,t,n,r){let i,a=n&&n[r],o=f(e);if(o||_(e)){let n=o&&zt(e),r=!1,s=!1;n&&(r=!Vt(e),s=Bt(e),e=it(e)),i=Array(e.length);for(let n=0,o=e.length;n<o;n++)i[n]=t(r?s?Gt(Wt(e[n])):Wt(e[n]):e[n],n,void 0,a&&a[n])}else if(typeof e==`number`){i=Array(e);for(let n=0;n<e;n++)i[n]=t(n+1,n,void 0,a&&a[n])}else if(y(e)){if(e[Symbol.iterator])i=Array.from(e,(e,n)=>t(e,n,void 0,a&&a[n]));else{let n=Object.keys(e);i=Array(n.length);for(let r=0,o=n.length;r<o;r++){let o=n[r];i[r]=t(e[o],o,r,a&&a[r])}}}else i=[];return n&&(n[r]=i),i}var wr=e=>e?ha(e)?Ca(e):wr(e.parent):null,Tr=c(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=>wr(e.parent),$root:e=>wr(e.root),$host:e=>e.ce,$emit:e=>e.emit,$options:e=>Pr(e),$forceUpdate:e=>e.f||=()=>{bn(e.update)},$nextTick:e=>e.n||=vn.bind(e.proxy),$watch:e=>Bn.bind(e)}),Er=(e,t)=>e!==n&&!e.__isScriptSetup&&d(e,t),Dr={get({_:e},t){if(t===`__v_skip`)return!0;let{ctx:r,setupState:i,data:a,props:o,accessCache:s,type:c,appContext:l}=e;if(t[0]!==`$`){let e=s[t];if(e!==void 0)switch(e){case 1:return i[t];case 2:return a[t];case 4:return r[t];case 3:return o[t]}else if(Er(i,t))return s[t]=1,i[t];else if(a!==n&&d(a,t))return s[t]=2,a[t];else if(d(o,t))return s[t]=3,o[t];else if(r!==n&&d(r,t))return s[t]=4,r[t];else kr&&(s[t]=0)}let u=Tr[t],f,p;if(u)return t===`$attrs`&&tt(e.attrs,`get`,``),u(e);if((f=c.__cssModules)&&(f=f[t]))return f;if(r!==n&&d(r,t))return s[t]=4,r[t];if(p=l.config.globalProperties,d(p,t))return p[t]},set({_:e},t,r){let{data:i,setupState:a,ctx:o}=e;return Er(a,t)?(a[t]=r,!0):i!==n&&d(i,t)?(i[t]=r,!0):d(e.props,t)||t[0]===`$`&&t.slice(1)in e?!1:(o[t]=r,!0)},has({_:{data:e,setupState:t,accessCache:r,ctx:i,appContext:a,props:o,type:s}},c){let l;return!!(r[c]||e!==n&&c[0]!==`$`&&d(e,c)||Er(t,c)||d(o,c)||d(i,c)||d(Tr,c)||d(a.config.globalProperties,c)||(l=s.__cssModules)&&l[c])},defineProperty(e,t,n){return n.get==null?d(n,`value`)&&this.set(e,t,n.value,null):e._.accessCache[t]=0,Reflect.defineProperty(e,t,n)}};function Or(e){return f(e)?e.reduce((e,t)=>(e[t]=null,e),{}):e}var kr=!0;function Ar(e){let t=Pr(e),n=e.proxy,r=e.ctx;kr=!1,t.beforeCreate&&Mr(t.beforeCreate,e,`bc`);let{data:a,computed:o,methods:s,watch:c,provide:l,inject:u,created:d,beforeMount:p,mounted:m,beforeUpdate:h,updated:_,activated:v,deactivated:b,beforeDestroy:x,beforeUnmount:S,destroyed:C,unmounted:ee,render:w,renderTracked:te,renderTriggered:ne,errorCaptured:re,serverPrefetch:T,expose:ie,inheritAttrs:E,components:ae,directives:oe,filters:se}=t;if(u&&jr(u,r,null),s)for(let e in s){let t=s[e];g(t)&&(r[e]=t.bind(n))}if(a){let t=a.call(n,n);y(t)&&(e.data=Ft(t))}if(kr=!0,o)for(let e in o){let t=o[e],a=G({get:g(t)?t.bind(n,n):g(t.get)?t.get.bind(n,n):i,set:!g(t)&&g(t.set)?t.set.bind(n):i});Object.defineProperty(r,e,{enumerable:!0,configurable:!0,get:()=>a.value,set:e=>a.value=e})}if(c)for(let e in c)Nr(c[e],r,n,e);if(l){let e=g(l)?l.call(n):l;Reflect.ownKeys(e).forEach(t=>{Nn(t,e[t])})}d&&Mr(d,e,`c`);function D(e,t){f(t)?t.forEach(t=>e(t.bind(n))):t&&e(t.bind(n))}if(D(cr,p),D(lr,m),D(ur,h),D(dr,_),D(nr,v),D(rr,b),D(_r,re),D(gr,te),D(hr,ne),D(fr,S),D(pr,ee),D(mr,T),f(ie)){if(ie.length){let t=e.exposed||={};ie.forEach(e=>{Object.defineProperty(t,e,{get:()=>n[e],set:t=>n[e]=t,enumerable:!0})})}else e.exposed||={}}w&&e.render===i&&(e.render=w),E!=null&&(e.inheritAttrs=E),ae&&(e.components=ae),oe&&(e.directives=oe),T&&Yn(e)}function jr(e,t,n=i){f(e)&&(e=zr(e));for(let n in e){let r=e[n],i;i=y(r)?`default`in r?Pn(r.from||n,r.default,!0):Pn(r.from||n):Pn(r),L(i)?Object.defineProperty(t,n,{enumerable:!0,configurable:!0,get:()=>i.value,set:e=>i.value=e}):t[n]=i}}function Mr(e,t,n){cn(f(e)?e.map(e=>e.bind(t.proxy)):e.bind(t.proxy),t,n)}function Nr(e,t,n,r){let i=r.includes(`.`)?Vn(n,r):()=>n[r];if(_(e)){let n=t[e];g(n)&&Rn(i,n)}else if(g(e))Rn(i,e.bind(n));else if(y(e)){if(f(e))e.forEach(e=>Nr(e,t,n,r));else{let r=g(e.handler)?e.handler.bind(n):t[e.handler];g(r)&&Rn(i,r,e)}}}function Pr(e){let t=e.type,{mixins:n,extends:r}=t,{mixins:i,optionsCache:a,config:{optionMergeStrategies:o}}=e.appContext,s=a.get(t),c;return s?c=s:!i.length&&!n&&!r?c=t:(c={},i.length&&i.forEach(e=>Fr(c,e,o,!0)),Fr(c,t,o)),y(t)&&a.set(t,c),c}function Fr(e,t,n,r=!1){let{mixins:i,extends:a}=t;a&&Fr(e,a,n,!0),i&&i.forEach(t=>Fr(e,t,n,!0));for(let i in t)if(!(r&&i===`expose`)){let r=Ir[i]||n&&n[i];e[i]=r?r(e[i],t[i]):t[i]}return e}var Ir={data:Lr,props:Hr,emits:Hr,methods:Vr,computed:Vr,beforeCreate:Br,created:Br,beforeMount:Br,mounted:Br,beforeUpdate:Br,updated:Br,beforeDestroy:Br,beforeUnmount:Br,destroyed:Br,unmounted:Br,activated:Br,deactivated:Br,errorCaptured:Br,serverPrefetch:Br,components:Vr,directives:Vr,watch:Ur,provide:Lr,inject:Rr};function Lr(e,t){return t?e?function(){return c(g(e)?e.call(this,this):e,g(t)?t.call(this,this):t)}:t:e}function Rr(e,t){return Vr(zr(e),zr(t))}function zr(e){if(f(e)){let t={};for(let n=0;n<e.length;n++)t[e[n]]=e[n];return t}return e}function Br(e,t){return e?[...new Set([].concat(e,t))]:t}function Vr(e,t){return e?c(Object.create(null),e,t):t}function Hr(e,t){return e?f(e)&&f(t)?[...new Set([...e,...t])]:c(Object.create(null),Or(e),Or(t??{})):t}function Ur(e,t){if(!e)return t;if(!t)return e;let n=c(Object.create(null),e);for(let r in t)n[r]=Br(e[r],t[r]);return n}function Wr(){return{app:null,config:{isNativeTag:a,performance:!1,globalProperties:{},optionMergeStrategies:{},errorHandler:void 0,warnHandler:void 0,compilerOptions:{}},mixins:[],components:{},directives:{},provides:Object.create(null),optionsCache:new WeakMap,propsCache:new WeakMap,emitsCache:new WeakMap}}var Gr=0;function Kr(e,t){return function(n,r=null){g(n)||(n=c({},n)),r!=null&&!y(r)&&(r=null);let i=Wr(),a=new WeakSet,o=[],s=!1,l=i.app={_uid:Gr++,_component:n,_props:r,_container:null,_context:i,_instance:null,version:Ea,get config(){return i.config},set config(e){},use(e,...t){return a.has(e)||(e&&g(e.install)?(a.add(e),e.install(l,...t)):g(e)&&(a.add(e),e(l,...t))),l},mixin(e){return i.mixins.includes(e)||i.mixins.push(e),l},component(e,t){return t?(i.components[e]=t,l):i.components[e]},directive(e,t){return t?(i.directives[e]=t,l):i.directives[e]},mount(a,o,c){if(!s){let u=l._ceVNode||U(n,r);return u.appContext=i,c===!0?c=`svg`:c===!1&&(c=void 0),o&&t?t(u,a):e(u,a,c),s=!0,l._container=a,a.__vue_app__=l,Ca(u.component)}},onUnmount(e){o.push(e)},unmount(){s&&(cn(o,l._instance,16),e(null,l._container),delete l._container.__vue_app__)},provide(e,t){return i.provides[e]=t,l},runWithContext(e){let t=qr;qr=l;try{return e()}finally{qr=t}}};return l}}var qr=null,Jr=(e,t)=>t===`modelValue`||t===`model-value`?e.modelModifiers:e[`${t}Modifiers`]||e[`${T(t)}Modifiers`]||e[`${E(t)}Modifiers`];function Yr(e,t,...r){if(e.isUnmounted)return;let i=e.vnode.props||n,a=r,o=t.startsWith(`update:`),s=o&&Jr(i,t.slice(7));s&&(s.trim&&(a=r.map(e=>_(e)?e.trim():e)),s.number&&(a=a.map(le)));let c,l=i[c=oe(t)]||i[c=oe(T(t))];!l&&o&&(l=i[c=oe(E(t))]),l&&cn(l,e,6,a);let u=i[c+`Once`];if(u){if(!e.emitted)e.emitted={};else if(e.emitted[c])return;e.emitted[c]=!0,cn(u,e,6,a)}}var Xr=new WeakMap;function Zr(e,t,n=!1){let r=n?Xr:t.emitsCache,i=r.get(e);if(i!==void 0)return i;let a=e.emits,o={},s=!1;if(!g(e)){let r=e=>{let n=Zr(e,t,!0);n&&(s=!0,c(o,n))};!n&&t.mixins.length&&t.mixins.forEach(r),e.extends&&r(e.extends),e.mixins&&e.mixins.forEach(r)}return!a&&!s?(y(e)&&r.set(e,null),null):(f(a)?a.forEach(e=>o[e]=null):c(o,a),y(e)&&r.set(e,o),o)}function Qr(e,t){return!e||!o(t)?!1:(t=t.slice(2),t=t===`Once`?t:t.replace(/Once$/,``),d(e,t[0].toLowerCase()+t.slice(1))||d(e,E(t))||d(e,t))}function $r(e){let{type:t,vnode:n,proxy:r,withProxy:i,propsOptions:[a],slots:o,attrs:c,emit:l,render:u,renderCache:d,props:f,data:p,setupState:m,ctx:h,inheritAttrs:g}=e,_=kn(e),v,y;try{if(n.shapeFlag&4){let e=i||r,t=e;v=ta(u.call(t,e,d,f,m,p,h)),y=c}else{let e=t;v=ta(e.length>1?e(f,{attrs:c,slots:o,emit:l}):e(f,null)),y=t.props?c:ei(c)}}catch(t){Bi.length=0,ln(t,e,1),v=U(Ri)}let b=v;if(y&&g!==!1){let e=Object.keys(y),{shapeFlag:t}=b;e.length&&t&7&&(a&&e.some(s)&&(y=ti(y,a)),b=$i(b,y,!1,!0))}return n.dirs&&(b=$i(b,null,!1,!0),b.dirs=b.dirs?b.dirs.concat(n.dirs):n.dirs),n.transition&&qn(Un(b.type)&&Kn(b)||b,n.transition),v=b,kn(_),v}var ei=e=>{let t;for(let n in e)(n===`class`||n===`style`||o(n))&&((t||={})[n]=e[n]);return t},ti=(e,t)=>{let n={};for(let r in e)(!s(r)||!(r.slice(9)in t))&&(n[r]=e[r]);return n};function ni(e,t,n){let{props:r,children:i,component:a}=e,{props:o,children:s,patchFlag:c}=t,l=a.emitsOptions;if(t.dirs||t.transition)return!0;if(n&&c>=0){if(c&1024)return!0;if(c&16)return r?ri(r,o,l):!!o;if(c&8){let e=t.dynamicProps;for(let t=0;t<e.length;t++){let n=e[t];if(ii(o,r,n)&&!Qr(l,n))return!0}}}else return(i||s)&&(!s||!s.$stable)?!0:r===o?!1:r?!o||ri(r,o,l):!!o;return!1}function ri(e,t,n){let r=Object.keys(t);if(r.length!==Object.keys(e).length)return!0;for(let i=0;i<r.length;i++){let a=r[i];if(ii(t,e,a)&&!Qr(n,a))return!0}return!1}function ii(e,t,n){let r=e[n],i=t[n];return n===`style`&&y(r)&&y(i)?!xe(r,i):r!==i}function ai({vnode:e,parent:t,suspense:n},r){for(;t;){let n=t.subTree;if(n.suspense&&n.suspense.activeBranch===e&&(n.suspense.vnode.el=n.el=r,e=n),n===e)(e=t.vnode).el=r,t=t.parent;else break}n&&n.activeBranch===e&&(n.vnode.el=r)}var oi={},si=()=>Object.create(oi),ci=e=>Object.getPrototypeOf(e)===oi;function li(e,t,n,r=!1){let i={},a=si();e.propsDefaults=Object.create(null),di(e,t,i,a);for(let t in e.propsOptions[0])t in i||(i[t]=void 0);e.props=n?r?i:It(i):e.type.props?i:a,e.attrs=a}function ui(e,t,n,r){let{props:i,attrs:a,vnode:{patchFlag:o}}=e,s=I(i),[c]=e.propsOptions,l=!1;if((r||o>0)&&!(o&16)){if(o&8){let n=e.vnode.dynamicProps;for(let r=0;r<n.length;r++){let o=n[r];if(Qr(e.emitsOptions,o))continue;let u=t[o];if(c){if(d(a,o))u!==a[o]&&(a[o]=u,l=!0);else{let t=T(o);i[t]=fi(c,s,t,u,e,!1)}}else u!==a[o]&&(a[o]=u,l=!0)}}}else{di(e,t,i,a)&&(l=!0);let r;for(let a in s)(!t||!d(t,a)&&((r=E(a))===a||!d(t,r)))&&(c?n&&(n[a]!==void 0||n[r]!==void 0)&&(i[a]=fi(c,s,a,void 0,e,!0)):delete i[a]);if(a!==s)for(let e in a)(!t||!d(t,e))&&(delete a[e],l=!0)}l&&nt(e.attrs,`set`,``)}function di(e,t,r,i){let[a,o]=e.propsOptions,s=!1,c;if(t)for(let n in t){if(te(n))continue;let l=t[n],u;a&&d(a,u=T(n))?!o||!o.includes(u)?r[u]=l:(c||={})[u]=l:Qr(e.emitsOptions,n)||(!(n in i)||l!==i[n])&&(i[n]=l,s=!0)}if(o){let t=I(r),i=c||n;for(let n=0;n<o.length;n++){let s=o[n];r[s]=fi(a,t,s,i[s],e,!d(i,s))}}return s}function fi(e,t,n,r,i,a){let o=e[n];if(o!=null){let e=d(o,`default`);if(e&&r===void 0){let e=o.default;if(o.type!==Function&&!o.skipFactory&&g(e)){let{propsDefaults:a}=i;if(n in a)r=a[n];else{let o=pa(i);r=a[n]=e.call(null,t),o()}}else r=e;i.ce&&i.ce._setProp(n,r)}o[0]&&(a&&!e?r=!1:o[1]&&(r===``||r===E(n))&&(r=!0))}return r}var pi=new WeakMap;function mi(e,t,i=!1){let a=i?pi:t.propsCache,o=a.get(e);if(o)return o;let s=e.props,l={},u=[],p=!1;if(!g(e)){let n=e=>{p=!0;let[n,r]=mi(e,t,!0);c(l,n),r&&u.push(...r)};!i&&t.mixins.length&&t.mixins.forEach(n),e.extends&&n(e.extends),e.mixins&&e.mixins.forEach(n)}if(!s&&!p)return y(e)&&a.set(e,r),r;if(f(s))for(let e=0;e<s.length;e++){let t=T(s[e]);hi(t)&&(l[t]=n)}else if(s)for(let e in s){let t=T(e);if(hi(t)){let n=s[e],r=l[t]=f(n)||g(n)?{type:n}:c({},n),i=r.type,a=!1,o=!0;if(f(i))for(let e=0;e<i.length;++e){let t=i[e],n=g(t)&&t.name;if(n===`Boolean`){a=!0;break}n===`String`&&(o=!1)}else a=g(i)&&i.name===`Boolean`;r[0]=a,r[1]=o,(a||d(r,`default`))&&u.push(t)}}let m=[l,u];return y(e)&&a.set(e,m),m}function hi(e){return e[0]!==`$`&&!te(e)}var gi=e=>e===`_`||e===`_ctx`||e===`$stable`,_i=e=>f(e)?e.map(ta):[ta(e)],vi=(e,t,n)=>{if(t._n)return t;let r=An((...e)=>_i(t(...e)),n);return r._c=!1,r},yi=(e,t,n)=>{let r=e._ctx;for(let n in e){if(gi(n))continue;let i=e[n];if(g(i))t[n]=vi(n,i,r);else if(i!=null){let e=_i(i);t[n]=()=>e}}},bi=(e,t)=>{let n=_i(t);e.slots.default=()=>n},xi=(e,t,n)=>{for(let r in t)(n||!gi(r))&&(e[r]=t[r])},Si=(e,t,n)=>{let r=e.slots=si();if(e.vnode.shapeFlag&32){let e=t._;e?(xi(r,t,n),n&&ce(r,`_`,e,!0)):yi(t,r)}else t&&bi(e,t)},Ci=(e,t,r)=>{let{vnode:i,slots:a}=e,o=!0,s=n;if(i.shapeFlag&32){let e=t._;e?r&&e===1?o=!1:xi(a,t,r):(o=!t.$stable,yi(t,a)),s=t}else t&&(bi(e,t),s={default:1});if(o)for(let e in a)!gi(e)&&s[e]==null&&delete a[e]},wi=Ii;function Ti(e){return Ei(e)}function Ei(e,t){let a=de();a.__VUE__=!0;let{insert:o,remove:s,patchProp:c,createElement:l,createText:u,createComment:d,setText:f,setElementText:p,parentNode:m,nextSibling:h,setScopeId:g=i,insertStaticContent:_}=e,v=(e,t,n,i=null,a=null,o=null,s=void 0,c=null,l=!!t.dynamicChildren)=>{if(e===t)return;e&&!Ji(e,t)&&(i=ye(e),he(e,a,o,!0),e=null),t.patchFlag===-2&&(l=!1,t.dynamicChildren=null),t.dynamicChildren&&e&&e.dynamicChildren&&e.dynamicChildren.hasOnce&&(t.dynamicChildren===r&&(t.dynamicChildren=[]),t.dynamicChildren.hasOnce=!0);let{type:u,ref:d,shapeFlag:f}=t;switch(u){case Li:y(e,t,n,i);break;case Ri:b(e,t,n,i);break;case zi:e??x(t,n,i,s);break;case z:ae(e,t,n,i,a,o,s,c,l);break;default:f&1?ee(e,t,n,i,a,o,s,c,l):f&6?oe(e,t,n,i,a,o,s,c,l):(f&64||f&128)&&u.process(e,t,n,i,a,o,s,c,l,j)}d!=null&&a?Qn(d,e&&e.ref,o,t||e,!t):d==null&&e&&e.ref!=null&&Qn(e.ref,null,o,e,!0)},y=(e,t,n,r)=>{if(e==null)o(t.el=u(t.children),n,r);else{let n=t.el=e.el;t.children!==e.children&&f(n,t.children)}},b=(e,t,n,r)=>{e==null?o(t.el=d(t.children||``),n,r):t.el=e.el},x=(e,t,n,r)=>{[e.el,e.anchor]=_(e.children,t,n,r,e.el,e.anchor)},S=({el:e,anchor:t},n,r)=>{let i;for(;e&&e!==t;)i=h(e),o(e,n,r),e=i;o(t,n,r)},C=({el:e,anchor:t})=>{let n;for(;e&&e!==t;)n=h(e),s(e),e=n;s(t)},ee=(e,t,n,r,i,a,o,s,c)=>{if(t.type===`svg`?o=`svg`:t.type===`math`&&(o=`mathml`),e==null)w(t,n,r,i,a,o,s,c);else{let n=e.el&&e.el._isVueCE?e.el:null;try{n&&n._beginPatch(),T(e,t,i,a,o,s,c)}finally{n&&n._endPatch()}}},w=(e,t,n,r,i,a,s,u)=>{let d,f,{props:m,shapeFlag:h,transition:g,dirs:_}=e;if(d=e.el=l(e.type,a,m&&m.is,m),h&8?p(d,e.children):h&16&&re(e.children,d,null,r,i,Di(e,a),s,u),_&&Mn(e,null,r,`created`),ne(d,e,e.scopeId,s,r),m){for(let e in m)e!==`value`&&!te(e)&&c(d,e,null,m[e],a,r);`value`in m&&c(d,`value`,null,m.value,a),(f=m.onVnodeBeforeMount)&&aa(f,r,e)}_&&Mn(e,null,r,`beforeMount`);let v=ki(i,g);v&&g.beforeEnter(d),o(d,t,n),((f=m&&m.onVnodeMounted)||v||_)&&wi(()=>{try{f&&aa(f,r,e),v&&g.enter(d),_&&Mn(e,null,r,`mounted`)}finally{}},i)},ne=(e,t,n,r,i)=>{if(n&&g(e,n),r)for(let t=0;t<r.length;t++)g(e,r[t]);if(i){let n=i.subTree;if(t===n||Fi(n.type)&&(n.ssContent===t||n.ssFallback===t)){let t=i.vnode;ne(e,t,t.scopeId,t.slotScopeIds,i.parent)}}},re=(e,t,n,r,i,a,o,s,c=0)=>{for(let l=c;l<e.length;l++){let c=e[l]=s?na(e[l]):ta(e[l]);v(null,c,t,n,r,i,a,o,s)}},T=(e,t,r,i,a,o,s)=>{let l=t.el=e.el,{patchFlag:u,dynamicChildren:d,dirs:f}=t;u|=e.patchFlag&16;let m=e.props||n,h=t.props||n,g;if(r&&Oi(r,!1),(g=h.onVnodeBeforeUpdate)&&aa(g,r,t,e),f&&Mn(t,e,r,`beforeUpdate`),r&&Oi(r,!0),d&&(!e.dynamicChildren||e.dynamicChildren.length!==d.length)&&(u=0,s=!1,d=null),(m.innerHTML&&h.innerHTML==null||m.textContent&&h.textContent==null)&&p(l,``),d?ie(e.dynamicChildren,d,l,r,i,Di(t,a),o):s||O(e,t,l,null,r,i,Di(t,a),o,!1),u>0){if(u&16)E(l,m,h,r,a);else if(u&2&&m.class!==h.class&&c(l,`class`,null,h.class,a),u&4&&c(l,`style`,m.style,h.style,a),u&8){let e=t.dynamicProps;for(let t=0;t<e.length;t++){let n=e[t],i=m[n],o=h[n];(o!==i||n===`value`)&&c(l,n,i,o,a,r)}}u&1&&e.children!==t.children&&p(l,t.children)}else!s&&d==null&&E(l,m,h,r,a);((g=h.onVnodeUpdated)||f)&&wi(()=>{g&&aa(g,r,t,e),f&&Mn(t,e,r,`updated`)},i)},ie=(e,t,n,r,i,a,o)=>{for(let s=0;s<t.length;s++){let c=e[s],l=t[s],u=c.el&&(c.type===z||!Ji(c,l)||c.shapeFlag&198)?m(c.el):n;v(c,l,u,null,r,i,a,o,!0)}},E=(e,t,r,i,a)=>{if(t!==r){if(t!==n)for(let n in t)!te(n)&&!(n in r)&&c(e,n,t[n],null,a,i);for(let n in r){if(te(n))continue;let o=r[n],s=t[n];o!==s&&n!==`value`&&c(e,n,s,o,a,i)}`value`in r&&c(e,`value`,t.value,r.value,a)}},ae=(e,t,n,r,i,a,s,c,l)=>{let d=t.el=e?e.el:u(``),f=t.anchor=e?e.anchor:u(``),{patchFlag:p,dynamicChildren:m,slotScopeIds:h}=t;h&&(c=c?c.concat(h):h),e==null?(o(d,n,r),o(f,n,r),re(t.children||[],n,f,i,a,s,c,l)):p>0&&p&64&&m&&e.dynamicChildren&&e.dynamicChildren.length===m.length?(ie(e.dynamicChildren,m,n,i,a,s,c),(t.key!=null||i&&t===i.subTree)&&Ai(e,t,!0)):O(e,t,n,f,i,a,s,c,l)},oe=(e,t,n,r,i,a,o,s,c)=>{t.slotScopeIds=s,e==null?t.shapeFlag&512?i.ctx.activate(t,n,r,o,c):se(t,n,r,i,a,o,c):ce(e,t,c)},se=(e,t,n,r,i,a,o)=>{let s=e.component=ca(e,r,i);if(tr(e)&&(s.ctx.renderer=j),_a(s,!1,o),s.asyncDep){if(i&&i.registerDep(s,le,o),!e.el){let r=s.subTree=U(Ri);b(null,r,t,n),e.placeholder=r.el}}else le(s,e,t,n,i,a,o)},ce=(e,t,n)=>{let r=t.component=e.component;if(ni(e,t,n)){if(r.asyncDep&&!r.asyncResolved){t.el=e.el,ue(r,t,n);return}r.next=t,r.update()}else t.el=e.el,r.vnode=t},le=(e,t,n,r,i,a,o)=>{let s=()=>{if(e.isMounted){let{next:t,bu:n,u:r,parent:s,vnode:c}=e;{let n=Mi(e);if(n){t&&(t.el=c.el,ue(e,t,o)),n.asyncDep.then(()=>{wi(()=>{e.isUnmounted||l()},i)});return}}let u=t,d;Oi(e,!1),t?(t.el=c.el,ue(e,t,o)):t=c,n&&D(n),(d=t.props&&t.props.onVnodeBeforeUpdate)&&aa(d,s,t,c),Oi(e,!0);let f=$r(e),p=e.subTree;e.subTree=f,v(p,f,m(p.el),ye(p),e,i,a),t.el=f.el,u===null&&ai(e,f.el),r&&wi(r,i),(d=t.props&&t.props.onVnodeUpdated)&&wi(()=>aa(d,s,t,c),i)}else{let o,{el:s,props:c}=t,{bm:l,m:u,parent:d,root:f,type:p}=e,m=er(t);if(Oi(e,!1),l&&D(l),!m&&(o=c&&c.onVnodeBeforeMount)&&aa(o,d,t),Oi(e,!0),s&&Se){let t=()=>{e.subTree=$r(e),Se(s,e.subTree,e,i,null)};m&&p.__asyncHydrate?p.__asyncHydrate(s,e,t):t()}else{f.ce&&f.ce._hasShadowRoot()&&f.ce._injectChildStyle(p,e.parent?e.parent.type:void 0);let o=e.subTree=$r(e);v(null,o,n,r,e,i,a),t.el=o.el}if(u&&wi(u,i),!m&&(o=c&&c.onVnodeMounted)){let e=t;wi(()=>aa(o,d,e),i)}(t.shapeFlag&256||d&&er(d.vnode)&&d.vnode.shapeFlag&256)&&e.a&&wi(e.a,i),e.isMounted=!0,t=n=r=null}};e.scope.on();let c=e.effect=new ke(s);e.scope.off();let l=e.update=c.run.bind(c),u=e.job=c.runIfDirty.bind(c);u.i=e,u.id=e.uid,c.scheduler=()=>bn(u),Oi(e,!0),l()},ue=(e,t,n)=>{t.component=e;let r=e.vnode.props;e.vnode=t,e.next=null,ui(e,t.props,r,n),Ci(e,t.children,n),We(),Cn(e),Ge()},O=(e,t,n,r,i,a,o,s,c=!1)=>{let l=e&&e.children,u=e?e.shapeFlag:0,d=t.children,{patchFlag:f,shapeFlag:m}=t;if(f>0){if(f&128){pe(l,d,n,r,i,a,o,s,c);return}if(f&256){fe(l,d,n,r,i,a,o,s,c);return}}m&8?(u&16&&ve(l,i,a),d!==l&&p(n,d)):u&16?m&16?pe(l,d,n,r,i,a,o,s,c):ve(l,i,a,!0):(u&8&&p(n,``),m&16&&re(d,n,r,i,a,o,s,c))},fe=(e,t,n,i,a,o,s,c,l)=>{e||=r,t||=r;let u=e.length,d=t.length,f=Math.min(u,d),p=0;for(;p<f;p++){let r=t[p]=l?na(t[p]):ta(t[p]);v(e[p],r,n,null,a,o,s,c,l)}u>d?ve(e,a,o,!0,!1,f):re(t,n,i,a,o,s,c,l,f)},pe=(e,t,n,i,a,o,s,c,l)=>{let u=0,d=t.length,f=e.length-1,p=d-1;for(;u<=f&&u<=p;){let r=e[u],i=t[u]=l?na(t[u]):ta(t[u]);if(Ji(r,i))v(r,i,n,null,a,o,s,c,l);else break;u++}for(;u<=f&&u<=p;){let r=e[f],i=t[p]=l?na(t[p]):ta(t[p]);if(Ji(r,i))v(r,i,n,null,a,o,s,c,l);else break;f--,p--}if(u>f){if(u<=p){let e=p+1,r=e<d?t[e].el:i;for(;u<=p;)v(null,t[u]=l?na(t[u]):ta(t[u]),n,r,a,o,s,c,l),u++}}else if(u>p)for(;u<=f;)he(e[u],a,o,!0),u++;else{let m=u,h=u,g=new Map;for(u=h;u<=p;u++){let e=t[u]=l?na(t[u]):ta(t[u]);e.key!=null&&g.set(e.key,u)}let _,y=0,b=p-h+1,x=!1,S=0,C=Array(b);for(u=0;u<b;u++)C[u]=0;for(u=m;u<=f;u++){let r=e[u];if(y>=b){he(r,a,o,!0);continue}let i;if(r.key!=null)i=g.get(r.key);else for(_=h;_<=p;_++)if(C[_-h]===0&&Ji(r,t[_])){i=_;break}i===void 0?he(r,a,o,!0):(C[i-h]=u+1,i>=S?S=i:x=!0,v(r,t[i],n,null,a,o,s,c,l),y++)}let ee=x?ji(C):r;for(_=ee.length-1,u=b-1;u>=0;u--){let e=h+u,r=t[e],f=t[e+1],p=e+1<d?f.el||Pi(f):i;C[u]===0?v(null,r,n,p,a,o,s,c,l):x&&(_<0||u!==ee[_]?me(r,n,p,2):_--)}}},me=(e,t,n,r,i=null)=>{let{el:a,type:c,transition:l,children:u,shapeFlag:d}=e;if(d&6){me(e.component.subTree,t,n,r);return}if(d&128){e.suspense.move(t,n,r);return}if(d&64){c.move(e,t,n,j);return}if(c===z){o(a,t,n);for(let e=0;e<u.length;e++)me(u[e],t,n,r);o(e.anchor,t,n);return}if(c===zi){S(e,t,n);return}if(r!==2&&d&1&&l){if(r===0)l.persisted&&!a[Wn]?o(a,t,n):(l.beforeEnter(a),o(a,t,n),wi(()=>l.enter(a),i));else{let{leave:r,delayLeave:i,afterLeave:c}=l,u=()=>{e.ctx.isUnmounted?s(a):o(a,t,n)},d=()=>{let e=a._isLeaving||!!a[Wn];a._isLeaving&&a[Wn](!0),l.persisted&&!e?u():r(a,()=>{u(),c&&c()})};i?i(a,u,d):d()}}else o(a,t,n)},he=(e,t,n,r=!1,i=!1)=>{let{type:a,props:o,ref:s,children:c,dynamicChildren:l,shapeFlag:u,patchFlag:d,dirs:f,cacheIndex:p,memo:m}=e;if((d===-2||l&&l.hasOnce)&&(i=!1),s!=null&&(We(),Qn(s,null,n,e,!0),Ge()),p!=null&&(!e.ctx||e.ctx===t)&&(t.renderCache[p]=void 0),u&256){t.ctx.deactivate(e);return}let h=u&1&&f,g=!er(e),_;if(g&&(_=o&&o.onVnodeBeforeUnmount)&&aa(_,t,e),u&6)_e(e.component,n,r);else{if(u&128){e.suspense.unmount(n,r);return}h&&Mn(e,null,t,`beforeUnmount`),u&64?e.type.remove(e,t,n,j,r):l&&!l.hasOnce&&(a!==z||d>0&&d&64)?ve(l,t,n,!1,!0):(a===z&&d&384||!i&&u&16)&&ve(c,t,n),r&&k(e)}let v=m!=null&&p==null;(g&&(_=o&&o.onVnodeUnmounted)||h||v)&&wi(()=>{_&&aa(_,t,e),h&&Mn(e,null,t,`unmounted`),v&&(e.el=null)},n)},k=e=>{let{type:t,el:n,anchor:r,transition:i}=e;if(t===z){ge(n,r);return}if(t===zi){C(e),i&&!i.persisted&&i.afterLeave&&i.afterLeave();return}let a=()=>{s(n),i&&!i.persisted&&i.afterLeave&&i.afterLeave()};if(e.shapeFlag&1&&i&&!i.persisted){let{leave:t,delayLeave:r}=i,o=()=>t(n,a);r?r(e.el,a,o):o()}else a()},ge=(e,t)=>{let n;for(;e!==t;)n=h(e),s(e),e=n;s(t)},_e=(e,t,n)=>{let{bum:r,scope:i,job:a,subTree:o,um:s,m:c,a:l}=e;Ni(c),Ni(l),r&&D(r),i.stop(),a?(a.flags|=8,he(o,e,t,n)):e.vnode.el&&o&&(o.transition=e.vnode.transition,he(o,e,t,n)),s&&wi(s,t),wi(()=>{e.isUnmounted=!0},t)},ve=(e,t,n,r=!1,i=!1,a=0)=>{for(let o=a;o<e.length;o++)he(e[o],t,n,r,i)},ye=e=>{if(e.shapeFlag&6)return ye(e.component.subTree);if(e.shapeFlag&128)return e.suspense.next();let t=h(e.anchor||e.el),n=t&&t[Hn];return n?h(n):t},A=!1,be=(e,t,n)=>{let r;e==null?t._vnode&&(he(t._vnode,null,null,!0),r=t._vnode.component):v(t._vnode||null,e,t,null,null,null,n),t._vnode=e,A||=(A=!0,Cn(r),wn(),!1)},j={p:v,um:he,m:me,r:k,mt:se,mc:re,pc:O,pbc:ie,n:ye,o:e},xe,Se;return t&&([xe,Se]=t(j)),{render:be,hydrate:xe,createApp:Kr(be,xe)}}function Di({type:e,props:t},n){return n===`svg`&&e===`foreignObject`||n===`mathml`&&e===`annotation-xml`&&t&&t.encoding&&t.encoding.includes(`html`)?void 0:n}function Oi({effect:e,job:t},n){n?(e.flags|=32,t.flags|=4):(e.flags&=-33,t.flags&=-5)}function ki(e,t){return(!e||e&&!e.pendingBranch)&&t&&!t.persisted}function Ai(e,t,n=!1){let r=e.children,i=t.children;if(f(r)&&f(i))for(let e=0;e<r.length;e++){let t=r[e],a=i[e];a.shapeFlag&1&&!a.dynamicChildren&&((a.patchFlag<=0||a.patchFlag===32)&&(a=i[e]=na(i[e]),a.el=t.el),!n&&a.patchFlag!==-2&&Ai(t,a)),a.type===Li&&(a.patchFlag===-1&&(a=i[e]=na(a)),a.el=t.el),a.type===Ri&&!a.el&&(a.el=t.el)}}function ji(e){let t=e.slice(),n=[0],r,i,a,o,s,c=e.length;for(r=0;r<c;r++){let c=e[r];if(c!==0){if(i=n[n.length-1],e[i]<c){t[r]=i,n.push(r);continue}for(a=0,o=n.length-1;a<o;)s=a+o>>1,e[n[s]]<c?a=s+1:o=s;c<e[n[a]]&&(a>0&&(t[r]=n[a-1]),n[a]=r)}}for(a=n.length,o=n[a-1];a-->0;)n[a]=o,o=t[o];return n}function Mi(e){let t=e.subTree.component;if(t)return t.asyncDep&&!t.asyncResolved?t:Mi(t)}function Ni(e){if(e)for(let t=0;t<e.length;t++)e[t].flags|=8}function Pi(e){if(e.placeholder)return e.placeholder;let t=e.component;return t?Pi(t.subTree):null}var Fi=e=>e.__isSuspense;function Ii(e,t){t&&t.pendingBranch?f(e)?t.effects.push(...e):t.effects.push(e):Sn(e)}var z=Symbol.for(`v-fgt`),Li=Symbol.for(`v-txt`),Ri=Symbol.for(`v-cmt`),zi=Symbol.for(`v-stc`),Bi=[],Vi=null;function B(e=!1){Bi.push(Vi=e?null:[])}function Hi(){Bi.pop(),Vi=Bi[Bi.length-1]||null}var Ui=1;function Wi(e,t=!1){Ui+=e,e<0&&Vi&&t&&(Vi.hasOnce=!0)}function Gi(e){return e.dynamicChildren=Ui>0?Vi||r:null,Hi(),Ui>0&&Vi&&Vi.push(e),e}function V(e,t,n,r,i,a){return Gi(H(e,t,n,r,i,a,!0))}function Ki(e,t,n,r,i){return Gi(U(e,t,n,r,i,!0))}function qi(e){return e?e.__v_isVNode===!0:!1}function Ji(e,t){return e.type===t.type&&e.key===t.key}var Yi=({key:e})=>e??null,Xi=({ref:e,ref_key:t,ref_for:n})=>(typeof e==`number`&&(e=``+e),e==null?null:_(e)||L(e)||g(e)?{i:Dn,r:e,k:t,f:!!n}:e);function H(e,t=null,n=null,r=0,i=null,a=e===z?0:1,o=!1,s=!1){let c={__v_isVNode:!0,__v_skip:!0,type:e,props:t,key:t&&Yi(t),ref:t&&Xi(t),scopeId:On,slotScopeIds:null,children:n,component:null,suspense:null,ssContent:null,ssFallback:null,dirs:null,transition:null,el:null,anchor:null,target:null,targetStart:null,targetAnchor:null,staticCount:0,shapeFlag:a,patchFlag:r,dynamicProps:i,dynamicChildren:null,appContext:null,ctx:Dn};return s?(ra(c,n),a&128&&e.normalize(c)):n&&(c.shapeFlag|=_(n)?8:16),Ui>0&&!o&&Vi&&(c.patchFlag>0||a&6)&&c.patchFlag!==32&&Vi.push(c),c}var U=Zi;function Zi(e,t=null,n=null,r=0,i=null,a=!1){if((!e||e===br)&&(e=Ri),qi(e)){let r=$i(e,t,!0);return n&&ra(r,n),Ui>0&&!a&&Vi&&(r.shapeFlag&6?Vi[Vi.indexOf(e)]=r:Vi.push(r)),r.patchFlag=-2,r}if(Ta(e)&&(e=e.__vccOpts),t){t=Qi(t);let{class:e,style:n}=t;e&&!_(e)&&(t.class=k(e)),y(n)&&(Ht(n)&&!f(n)&&(n=c({},n)),t.style=O(n))}let o=_(e)?1:Fi(e)?128:Un(e)?64:y(e)?4:g(e)?2:0;return H(e,t,n,r,i,o,a,!0)}function Qi(e){return e?Ht(e)||ci(e)?c({},e):e:null}function $i(e,t,n=!1,r=!1){let{props:i,ref:a,patchFlag:o,children:s,transition:c}=e,l=t?ia(i||{},t):i,u={__v_isVNode:!0,__v_skip:!0,type:e.type,props:l,key:l&&Yi(l),ref:t&&t.ref?n&&a?f(a)?a.concat(Xi(t)):[a,Xi(t)]:Xi(t):a,scopeId:e.scopeId,slotScopeIds:e.slotScopeIds,children:s,target:e.target,targetStart:e.targetStart,targetAnchor:e.targetAnchor,staticCount:e.staticCount,shapeFlag:e.shapeFlag,patchFlag:t&&e.type!==z?o===-1?16:o|16:o,dynamicProps:e.dynamicProps,dynamicChildren:e.dynamicChildren,appContext:e.appContext,dirs:e.dirs,transition:c,component:e.component,suspense:e.suspense,ssContent:e.ssContent&&$i(e.ssContent),ssFallback:e.ssFallback&&$i(e.ssFallback),placeholder:e.placeholder,el:e.el,anchor:e.anchor,ctx:e.ctx,ce:e.ce,cacheIndex:e.cacheIndex};return c&&r&&qn(u,c.clone(u)),u}function ea(e=` `,t=0){return U(Li,null,e,t)}function W(e=``,t=!1){return t?(B(),Ki(Ri,null,e)):U(Ri,null,e)}function ta(e){return e==null||typeof e==`boolean`?U(Ri):f(e)?U(z,null,e.slice()):qi(e)?na(e):U(Li,null,String(e))}function na(e){return e.el===null&&e.patchFlag!==-1||e.memo?e:$i(e)}function ra(e,t){let n=0,{shapeFlag:r}=e;if(t==null)t=null;else if(f(t))n=16;else if(typeof t==`object`){if(r&65){let n=t.default;n&&(n._c&&(n._d=!1),ra(e,n()),n._c&&(n._d=!0));return}{n=32;let r=t._;!r&&!ci(t)?t._ctx=Dn:r===3&&Dn&&(Dn.slots._===1?t._=1:(t._=2,e.patchFlag|=1024))}}else if(g(t)){if(r&65){ra(e,{default:t});return}t={default:t,_ctx:Dn},n=32}else t=String(t),r&64?(n=16,t=[ea(t)]):n=8;e.children=t,e.shapeFlag|=n}function ia(...e){let t={};for(let n=0;n<e.length;n++){let r=e[n];for(let e in r)if(e===`class`)t.class!==r.class&&(t.class=k([t.class,r.class]));else if(e===`style`)t.style=O([t.style,r.style]);else if(o(e)){let n=t[e],i=r[e];i&&n!==i&&!(f(n)&&n.includes(i))?t[e]=n?[].concat(n,i):i:i==null&&n==null&&!s(e)&&(t[e]=i)}else e!==``&&(t[e]=r[e])}return t}function aa(e,t,n,r=null){cn(e,t,7,[n,r])}var oa=Wr(),sa=0;function ca(e,t,r){let i=e.type,a=(t?t.appContext:e.appContext)||oa,o={uid:sa++,vnode:e,type:i,parent:t,appContext:a,root:null,next:null,subTree:null,effect:null,update:null,job:null,scope:new Ee(!0),render:null,proxy:null,exposed:null,exposeProxy:null,withProxy:null,provides:t?t.provides:Object.create(a.provides),ids:t?t.ids:[``,0,0],accessCache:null,renderCache:[],components:null,directives:null,propsOptions:mi(i,a),emitsOptions:Zr(i,a),emit:null,emitted:null,propsDefaults:n,inheritAttrs:i.inheritAttrs,ctx:n,data:n,props:n,attrs:n,slots:n,refs:n,setupState:n,setupContext:null,suspense:r,suspenseId:r?r.pendingId:0,asyncDep:null,asyncResolved:!1,isMounted:!1,isUnmounted:!1,isDeactivated:!1,bc:null,c:null,bm:null,m:null,bu:null,u:null,um:null,bum:null,da:null,a:null,rtg:null,rtc:null,ec:null,sp:null};return o.ctx={_:o},o.root=t?t.root:o,o.emit=Yr.bind(null,o),e.ce&&e.ce(o),o}var la=null,ua=()=>la||Dn,da,fa;{let e=de(),t=(t,n)=>{let r;return(r=e[t])||(r=e[t]=[]),r.push(n),e=>{r.length>1?r.forEach(t=>t(e)):r[0](e)}};da=t(`__VUE_INSTANCE_SETTERS__`,e=>la=e),fa=t(`__VUE_SSR_SETTERS__`,e=>ga=e)}var pa=e=>{let t=la;return da(e),e.scope.on(),()=>{e.scope.off(),da(t)}},ma=()=>{la&&la.scope.off(),da(null)};function ha(e){return e.vnode.shapeFlag&4}var ga=!1;function _a(e,t=!1,n=!1){t&&fa(t);let{props:r,children:i}=e.vnode,a=ha(e);li(e,r,a,t),Si(e,i,n||t);let o=a?va(e,t):void 0;return t&&fa(!1),o}function va(e,t){let n=e.type;e.accessCache=Object.create(null),e.proxy=new Proxy(e.ctx,Dr);let{setup:r}=n;if(r){We();let n=e.setupContext=r.length>1?Sa(e):null,i=pa(e),a=sn(r,e,0,[e.props,n]),o=b(a);if(Ge(),i(),(o||e.sp)&&!er(e)&&Yn(e),o){if(a.then(ma,ma),t)return a.then(n=>{fa(!0);try{ya(e,n,t)}finally{fa(!1)}}).catch(t=>{ln(t,e,0)});e.asyncDep=a}else ya(e,a,t)}else ba(e,t)}function ya(e,t,n){g(t)?e.type.__ssrInlineRender?e.ssrRender=t:e.render=t:y(t)&&(e.setupState=Zt(t)),ba(e,n)}function ba(e,t,n){let r=e.type;e.render||=r.render||i;{let t=pa(e);We();try{Ar(e)}finally{Ge(),t()}}}var xa={get(e,t){return tt(e,`get`,``),e[t]}};function Sa(e){return{attrs:new Proxy(e.attrs,xa),slots:e.slots,emit:e.emit,expose:t=>{e.exposed=t||{}}}}function Ca(e){return e.exposed?e.exposeProxy||=new Proxy(Zt(Ut(e.exposed)),{get(t,n){if(n in t)return t[n];if(n in Tr)return Tr[n](e)},has(e,t){return t in e||t in Tr}}):e.proxy}function wa(e,t=!0){return g(e)?e.displayName||e.name:e.name||t&&e.__name}function Ta(e){return g(e)&&`__vccOpts`in e}var G=(e,t)=>$t(e,t,ga),Ea=`3.5.43`,Da=void 0,Oa=typeof window<`u`&&window.trustedTypes;if(Oa)try{Da=Oa.createPolicy(`vue`,{createHTML:e=>e})}catch{}var ka=Da?e=>Da.createHTML(e):e=>e,Aa=`http://www.w3.org/2000/svg`,ja=`http://www.w3.org/1998/Math/MathML`,Ma=typeof document<`u`?document:null,Na=Ma&&Ma.createElement(`template`),Pa={insert:(e,t,n)=>{t.insertBefore(e,n||null)},remove:e=>{let t=e.parentNode;t&&t.removeChild(e)},createElement:(e,t,n,r)=>{let i=t===`svg`?Ma.createElementNS(Aa,e):t===`mathml`?Ma.createElementNS(ja,e):n?Ma.createElement(e,{is:n}):Ma.createElement(e);return e===`select`&&r&&r.multiple!=null&&i.setAttribute(`multiple`,r.multiple),i},createText:e=>Ma.createTextNode(e),createComment:e=>Ma.createComment(e),setText:(e,t)=>{e.nodeValue=t},setElementText:(e,t)=>{e.textContent=t},parentNode:e=>e.parentNode,nextSibling:e=>e.nextSibling,querySelector:e=>Ma.querySelector(e),setScopeId(e,t){e.setAttribute(t,``)},insertStaticContent(e,t,n,r,i,a){let o=n?n.previousSibling:t.lastChild;if(i&&(i===a||i.nextSibling))for(;t.insertBefore(i.cloneNode(!0),n),i!==a&&(i=i.nextSibling););else{Na.innerHTML=ka(r===`svg`?`<svg>${e}</svg>`:r===`mathml`?`<math>${e}</math>`:e);let i=Na.content;if(r===`svg`||r===`mathml`){let e=i.firstChild;for(;e.firstChild;)i.appendChild(e.firstChild);i.removeChild(e)}t.insertBefore(i,n)}return[o?o.nextSibling:t.firstChild,n?n.previousSibling:t.lastChild]}},Fa=Symbol(`_vtc`);function Ia(e,t,n){let r=e[Fa];r&&(t=(t?[t,...r]:[...r]).join(` `)),t==null?e.removeAttribute(`class`):n?e.setAttribute(`class`,t):e.className=t}var La=Symbol(`_vod`),Ra=Symbol(`_vsh`),za=Symbol(``),Ba=/(?:^|;)\s*display\s*:/;function Va(e,t,n){let r=e.style,i=_(n),a=!1;if(n&&!i){if(t){if(_(t))for(let e of t.split(`;`)){let t=e.slice(0,e.indexOf(`:`)).trim();n[t]??Ua(r,t,``)}else for(let e in t)n[e]??Ua(r,e,``)}for(let i in n){i===`display`&&(a=!0);let o=n[i];o==null?Ua(r,i,``):qa(e,i,!_(t)&&t?t[i]:void 0,o)||Ua(r,i,o)}}else if(i){if(t!==n){let e=r[za];e&&(n+=`;`+e),r.cssText=n,a=Ba.test(n)}}else t&&e.removeAttribute(`style`);La in e&&(e[La]=a?r.display:``,e[Ra]&&(r.display=`none`))}var Ha=/\s*!important$/;function Ua(e,t,n){if(f(n))n.forEach(n=>Ua(e,t,n));else if(n??=``,t.startsWith(`--`))Ha.test(n)?e.setProperty(t,n.replace(Ha,``),`important`):e.setProperty(t,n);else{let r=Ka(e,t);Ha.test(n)?e.setProperty(E(r),n.replace(Ha,``),`important`):e[r]=n}}var Wa=[`Webkit`,`Moz`,`ms`],Ga={};function Ka(e,t){let n=Ga[t];if(n)return n;let r=T(t);if(r!==`filter`&&r in e)return Ga[t]=r;r=ae(r);for(let n=0;n<Wa.length;n++){let i=Wa[n]+r;if(i in e)return Ga[t]=i}return t}function qa(e,t,n,r){return e.tagName===`TEXTAREA`&&(t===`width`||t===`height`)&&_(r)&&n===r}var Ja=`http://www.w3.org/1999/xlink`;function Ya(e,t,n,r,i,a=_e(t)){r&&t.startsWith(`xlink:`)?n==null?e.removeAttributeNS(Ja,t.slice(6,t.length)):e.setAttributeNS(Ja,t,n):n==null||a&&!ve(n)?e.removeAttribute(t):e.setAttribute(t,a?``:v(n)?String(n):n)}function Xa(e,t,n,r,i){if(t===`innerHTML`||t===`textContent`){n!=null&&(e[t]=t===`innerHTML`?ka(n):n);return}let a=e.tagName;if(t===`value`&&a!==`PROGRESS`&&!a.includes(`-`)){let r=a===`OPTION`?e.getAttribute(`value`)||``:e.value,i=n==null?e.type===`checkbox`?`on`:``:String(n);(r!==i||!(`_value`in e))&&(e.value=i),n??e.removeAttribute(t),e._value=n;return}let o=!1;if(n===``||n==null){let r=typeof e[t];r===`boolean`?n=ve(n):n==null&&r===`string`?(n=``,o=!0):r===`number`&&(n=0,o=!0)}try{e[t]=n}catch{}o&&e.removeAttribute(i||t)}function Za(e,t,n,r){e.addEventListener(t,n,r)}function Qa(e,t,n,r){e.removeEventListener(t,n,r)}var $a=Symbol(`_vei`);function eo(e,t,n,r,i=null){let a=e[$a]||(e[$a]={}),o=a[t];if(r&&o)o.value=r;else{let[n,s]=ro(t);r?Za(e,n,a[t]=so(r,i),s):o&&(Qa(e,n,o,s),a[t]=void 0)}}var to=/(Once|Passive|Capture)$/,no=/^on:?(?:Once|Passive|Capture)$/;function ro(e){let t,n;for(;(n=e.match(to))&&!no.test(e);)t||={},e=e.slice(0,e.length-n[1].length),t[n[1].toLowerCase()]=!0;return[e[2]===`:`?e.slice(3):E(e.slice(2)),t]}var io=0,ao=Promise.resolve(),oo=()=>io||=(ao.then(()=>io=0),Date.now());function so(e,t){let n=e=>{if(!e._vts)e._vts=Date.now();else if(e._vts<=n.attached)return;let r=n.value;if(f(r)){let n=e.stopImmediatePropagation;e.stopImmediatePropagation=()=>{n.call(e),e._stopped=!0};let i=r.slice(),a=[e];for(let n=0;n<i.length&&!e._stopped;n++){let e=i[n];e&&cn(e,t,5,a)}}else cn(r,t,5,[e])};return n.value=e,n.attached=oo(),n}var co=e=>e.charCodeAt(0)===111&&e.charCodeAt(1)===110&&e.charCodeAt(2)>96&&e.charCodeAt(2)<123,lo=(e,t,n,r,i,a)=>{let c=i===`svg`;t===`class`?Ia(e,r,c):t===`style`?Va(e,n,r):o(t)?s(t)||eo(e,t,n,r,a):(t[0]===`.`?(t=t.slice(1),1):t[0]===`^`?(t=t.slice(1),0):uo(e,t,r,c))?(Xa(e,t,r),!e.tagName.includes(`-`)&&(t===`value`||t===`checked`||t===`selected`)&&Ya(e,t,r,c,a,t!==`value`)):e._isVueCE&&(fo(e,t)||e._def.__asyncLoader&&(/[A-Z]/.test(t)||!_(r)))?Xa(e,T(t),r,a,t):(t===`true-value`?e._trueValue=r:t===`false-value`&&(e._falseValue=r),Ya(e,t,r,c))};function uo(e,t,n,r){if(r)return!!(t===`innerHTML`||t===`textContent`||t in e&&co(t)&&g(n));if(t===`spellcheck`||t===`draggable`||t===`translate`||t===`autocorrect`||t===`sandbox`&&e.tagName===`IFRAME`||t===`form`||t===`list`&&e.tagName===`INPUT`||t===`type`&&e.tagName===`TEXTAREA`)return!1;if(t===`width`||t===`height`){let t=e.tagName;if(t===`IMG`||t===`VIDEO`||t===`CANVAS`||t===`SOURCE`)return!1}return co(t)&&_(n)?!1:t in e}function fo(e,t){let n=e._def.props;if(!n)return!1;let r=T(t);return Array.isArray(n)?n.some(e=>T(e)===r):Object.keys(n).some(e=>T(e)===r)}var po=e=>{let t=e.props[`onUpdate:modelValue`]||!1;return f(t)?e=>D(t,e):t};function mo(e){e.target.composing=!0}function ho(e){let t=e.target;t.composing&&(t.composing=!1,t.dispatchEvent(new Event(`input`)))}var go=Symbol(`_assign`),_o=Symbol(`_initialValue`);function vo(e,t,n){return t&&(e=e.trim()),n&&(e=le(e)),e}var yo={created(e,{modifiers:{lazy:t,trim:n,number:r}},i){e.parentNode&&(e.type===`text`?e[_o]=e.defaultValue.replace(/[\r\n]/g,``):e.type===`textarea`&&(e[_o]=e.defaultValue.replace(/\r\n?/g,`
|
|
3
|
-
`))),e[go]=po(i);let a=r||i.props&&i.props.type===`number`;Za(e,t?`change`:`input`,t=>{t.target.composing||e[go](vo(e.value,n,a))}),(n||a)&&Za(e,`change`,()=>{e.value=vo(e.value,n,a)}),t||(Za(e,`compositionstart`,mo),Za(e,`compositionend`,ho),Za(e,`change`,ho))},mounted(e,{value:t,modifiers:{trim:n,number:r}}){let i=t??``,a=e[_o];delete e[_o],a!==void 0&&(e.type===`text`||e.type===`textarea`)&&e.value!==a?e[go](vo(e.value,n,r)):e.value=i},beforeUpdate(e,{value:t,oldValue:n,modifiers:{lazy:r,trim:i,number:a}},o){if(e[go]=po(o),e.composing)return;let s=(a||e.type===`number`)&&!/^0\d/.test(e.value)?le(e.value):e.value,c=t??``;if(s===c)return;let l=e.getRootNode();(l instanceof Document||l instanceof ShadowRoot)&&l.activeElement===e&&e.type!==`range`&&(r&&t===n||i&&e.value.trim()===c)||(e.value=c)}},bo={deep:!0,created(e,t,n){e[go]=po(n),Za(e,`change`,()=>{let t=e._modelValue,n=Eo(e),r=e.checked,i=e[go];if(f(t)){let e=Se(t,n),a=e!==-1;if(r&&!a)i(t.concat(n));else if(!r&&a){let n=[...t];n.splice(e,1),i(n)}}else if(m(t)){let e=new Set(t);r?e.add(n):e.delete(n),i(e)}else i(Do(e,r))})},mounted:xo,beforeUpdate(e,t,n){e[go]=po(n),xo(e,t,n)}};function xo(e,{value:t,oldValue:n},r){e._modelValue=t;let i;if(f(t))i=Se(t,r.props.value)>-1;else if(m(t))i=t.has(r.props.value);else{if(t===n)return;i=xe(t,Do(e,!0))}e.checked!==i&&(e.checked=i)}var So={created(e,{value:t},n){e.checked=xe(t,n.props.value),e[go]=po(n),Za(e,`change`,()=>{e[go](Eo(e))})},beforeUpdate(e,{value:t,oldValue:n},r){e[go]=po(r),t!==n&&(e.checked=xe(t,r.props.value))}},Co={deep:!0,created(e,{value:t,modifiers:{number:n}},r){e._modelValue=t,Za(e,`change`,()=>{let t=Array.prototype.filter.call(e.options,e=>e.selected).map(e=>n?le(Eo(e)):Eo(e)),r=e.multiple,i=r?m(e._modelValue)?new Set(t):t:t[0],a=e._pendingValue=[r,r?f(i)?t.slice():t:i];try{e[go](i)}finally{vn(()=>{e._pendingValue===a&&(e._pendingValue=void 0)})}}),e[go]=po(r)},mounted(e,{value:t}){To(e,t)},beforeUpdate(e,{value:t},n){e._modelValue=t,e[go]=po(n)},updated(e,{value:t}){let n=e._pendingValue;e._pendingValue=void 0,(!n||n[0]!==e.multiple||!wo(t,n[1],n[0]))&&To(e,t)}};function wo(e,t,n){if(!n||f(e))return xe(e,t);if(m(e)){if(e.size!==t.length)return!1;for(let n of t)if(!e.has(n))return!1;return!0}return!1}function To(e,t){let n=e.multiple,r=f(t);if(!n||r||m(t)){for(let i=0,a=e.options.length;i<a;i++){let a=e.options[i],o=Eo(a);if(n){if(r){let e=typeof o;a.selected=e===`string`||e===`number`?t.some(e=>String(e)===String(o)):Se(t,o)>-1}else a.selected=t.has(o)}else if(xe(Eo(a),t)){e.selectedIndex!==i&&(e.selectedIndex=i);return}}!n&&e.selectedIndex!==-1&&(e.selectedIndex=-1)}}function Eo(e){return`_value`in e?e._value:e.value}function Do(e,t){let n=t?`_trueValue`:`_falseValue`;return n in e?e[n]:t}var Oo={created(e,t,n){Ao(e,t,n,null,`created`)},mounted(e,t,n){Ao(e,t,n,null,`mounted`)},beforeUpdate(e,t,n,r){Ao(e,t,n,r,`beforeUpdate`)},updated(e,t,n,r){Ao(e,t,n,r,`updated`)}};function ko(e,t){switch(e){case`SELECT`:return Co;case`TEXTAREA`:return yo;default:switch(t){case`checkbox`:return bo;case`radio`:return So;default:return yo}}}function Ao(e,t,n,r,i){let a=ko(e.tagName,n.props&&n.props.type)[i];a&&a(e,t,n,r)}var jo=[`ctrl`,`shift`,`alt`,`meta`],Mo={stop:e=>e.stopPropagation(),prevent:e=>e.preventDefault(),self:e=>e.target!==e.currentTarget,ctrl:e=>!e.ctrlKey,shift:e=>!e.shiftKey,alt:e=>!e.altKey,meta:e=>!e.metaKey,left:e=>`button`in e&&e.button!==0,middle:e=>`button`in e&&e.button!==1,right:e=>`button`in e&&e.button!==2,exact:(e,t)=>jo.some(n=>e[`${n}Key`]&&!t.includes(n))},No=(e,t)=>{if(!e)return e;let n=e._withMods||={},r=t.join(`.`);return n[r]||(n[r]=((n,...r)=>{for(let e=0;e<t.length;e++){let r=Mo[t[e]];if(r&&r(n,t))return}return e(n,...r)}))},Po={esc:`escape`,space:` `,up:`arrow-up`,left:`arrow-left`,right:`arrow-right`,down:`arrow-down`,delete:`backspace`},Fo=(e,t)=>{let n=e._withKeys||={},r=t.join(`.`);return n[r]||(n[r]=(n=>{if(!(`key`in n))return;let r=E(n.key);if(t.some(e=>e===r||Po[e]===r))return e(n)}))},Io=c({patchProp:lo},Pa),Lo;function Ro(){return Lo||=Ti(Io)}var zo=((...e)=>{let t=Ro().createApp(...e),{mount:n}=t;return t.mount=e=>{let r=Vo(e);if(!r)return;let i=t._component;!g(i)&&!i.render&&!i.template&&(i.template=r.innerHTML),r.nodeType===1&&(r.textContent=``);let a=n(r,!1,Bo(r));return r instanceof Element&&(r.removeAttribute(`v-cloak`),r.setAttribute(`data-v-app`,``)),a},t});function Bo(e){if(e instanceof SVGElement)return`svg`;if(typeof MathMLElement==`function`&&e instanceof MathMLElement)return`mathml`}function Vo(e){return _(e)?document.querySelector(e):e}var Ho={"--font":`"Inter Variable", Inter, ui-sans-serif, system-ui, -apple-system, "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif`,"--mono":`"JetBrains Mono Variable", "JetBrains Mono", ui-monospace, SFMono-Regular, Menlo, Consolas, monospace`,"--fs":`13px`,"--fs-lg":`14px`,"--fs-sm":`12px`,"--fs-xs":`11px`,"--r-sm":`6px`,"--r":`8px`,"--r-lg":`12px`,"--r-xl":`16px`,"--h":`28px`,"--h-sm":`24px`,"--h-lg":`32px`,"--dur":`160ms`,"--ease":`cubic-bezier(0.16, 1, 0.3, 1)`,"--grad-size":`200% 100%`},Uo={"--base":`#fafafb`,"--bg":`#ffffff`,"--bg2":`#f4f4f5`,"--bg3":`#e9e9ec`,"--fg":`#18181b`,"--fg2":`#52525b`,"--fg3":`#a1a1aa`,"--line":`#e5e5e8`,"--line2":`#eeeef0`,"--line-strong":`#d4d4d8`,"--accent":`#7b61ff`,"--accent-hover":`#6a4ff0`,"--accent-2":`#4f46e5`,"--accent-fg":`#ffffff`,"--accent-soft":`#eef0ff`,"--agent":`#0ea5c6`,"--agent-soft":`rgba(14, 165, 198, 0.12)`,"--ok":`#16a34a`,"--ok-bg":`#dcfce7`,"--warn":`#d97706`,"--warn-bg":`#fef3c7`,"--err":`#dc2626`,"--err-bg":`#fef2f2`,"--info":`#2563eb`,"--user-bg":`#f3f1ff`,"--user-line":`rgba(123, 97, 255, 0.3)`,"--code-bg":`#f4f4f5`,"--mask":`rgba(15, 15, 20, 0.35)`,"--shadow":`0 8px 28px rgba(16, 24, 40, 0.14)`,"--shadow-sm":`0 1px 2px rgba(16, 24, 40, 0.06), 0 1px 2px rgba(16, 24, 40, 0.04)`,"--shadow-pop":`0 2px 10px rgba(26, 35, 50, 0.12)`,"--focus":`0 0 0 3px rgba(123, 97, 255, 0.2)`,"--grad":`linear-gradient(90deg, #6d28d9 0%, #7b61ff 30%, #6366f1 55%, #4f46e5 75%, #7b61ff 100%)`},Wo={"--base":`#0a0a0b`,"--bg":`#141417`,"--bg2":`#1c1c21`,"--bg3":`#26262c`,"--fg":`#ededf0`,"--fg2":`#a1a1aa`,"--fg3":`#6e6e78`,"--line":`#26262b`,"--line2":`#202025`,"--line-strong":`#36363e`,"--accent":`#7b61ff`,"--accent-hover":`#8f78ff`,"--accent-2":`#818cf8`,"--accent-fg":`#ffffff`,"--accent-soft":`#1f1f36`,"--agent":`#22d3ee`,"--agent-soft":`rgba(34, 211, 238, 0.14)`,"--ok":`#34d399`,"--ok-bg":`rgba(52, 211, 153, 0.12)`,"--warn":`#fbbf24`,"--warn-bg":`rgba(251, 191, 36, 0.12)`,"--err":`#f87171`,"--err-bg":`rgba(220, 38, 38, 0.12)`,"--info":`#60a5fa`,"--user-bg":`#1f1f36`,"--user-line":`rgba(123, 97, 255, 0.35)`,"--code-bg":`#0a0a0b`,"--mask":`rgba(0, 0, 0, 0.55)`,"--shadow":`0 8px 28px rgba(0, 0, 0, 0.55)`,"--shadow-sm":`0 1px 2px rgba(0, 0, 0, 0.4), 0 1px 3px rgba(0, 0, 0, 0.25)`,"--shadow-pop":`0 4px 16px rgba(0, 0, 0, 0.5)`,"--focus":`0 0 0 3px rgba(123, 97, 255, 0.3)`,"--grad":`linear-gradient(90deg, #7b61ff 0%, #818cf8 35%, #6366f1 55%, #7b61ff 75%, #a78bfa 100%)`},Go=e=>Object.entries(e).map(([e,t])=>`${e}: ${t};`).join(` `);function Ko(e,t){return`${e} { ${Go(Ho)} ${Go(Uo)} color-scheme: light; }\n${t} { ${Go(Wo)} color-scheme: dark; }\n`}function qo(){let e=document.createElement(`style`);e.textContent=Ko(`:root`,`:root[data-theme='dark']`),document.head.prepend(e)}function Jo(){try{let e=localStorage.getItem(`ph:theme`);if(e===`dark`||e===`light`)return e}catch{}return`light`}var Yo=Kt(Jo());Ln(()=>{document.documentElement.dataset.theme=Yo.value;try{localStorage.setItem(`ph:theme`,Yo.value)}catch{}});var Xo={viewBox:`0 0 24 24`,fill:`none`,stroke:`currentColor`,"stroke-width":`2`,"stroke-linecap":`round`,"stroke-linejoin":`round`,"aria-hidden":`true`},Zo=[`d`],K=Jn({__name:`Icon`,props:{name:{}},setup(e){let t={plus:`M12 5v14M5 12h14`,gear:`M12 15a3 3 0 1 0 0-6 3 3 0 0 0 0 6zM19.4 15a1.7 1.7 0 0 0 .3 1.8l.1.1a2 2 0 1 1-2.8 2.8l-.1-.1a1.7 1.7 0 0 0-1.8-.3 1.7 1.7 0 0 0-1 1.5V21a2 2 0 1 1-4 0v-.1a1.7 1.7 0 0 0-1.1-1.5 1.7 1.7 0 0 0-1.8.3l-.1.1a2 2 0 1 1-2.8-2.8l.1-.1a1.7 1.7 0 0 0 .3-1.8 1.7 1.7 0 0 0-1.5-1H3a2 2 0 1 1 0-4h.1a1.7 1.7 0 0 0 1.5-1.1 1.7 1.7 0 0 0-.3-1.8l-.1-.1a2 2 0 1 1 2.8-2.8l.1.1a1.7 1.7 0 0 0 1.8.3H9a1.7 1.7 0 0 0 1-1.5V3a2 2 0 1 1 4 0v.1a1.7 1.7 0 0 0 1 1.5 1.7 1.7 0 0 0 1.8-.3l.1-.1a2 2 0 1 1 2.8 2.8l-.1.1a1.7 1.7 0 0 0-.3 1.8V9a1.7 1.7 0 0 0 1.5 1H21a2 2 0 1 1 0 4h-.1a1.7 1.7 0 0 0-1.5 1z`,clip:`M21.4 11.1l-9.2 9.2a6 6 0 0 1-8.5-8.5l9.2-9.2a4 4 0 0 1 5.7 5.7l-9.2 9.2a2 2 0 0 1-2.8-2.8l8.5-8.5`,send:`M22 2L11 13M22 2l-7 20-4-9-9-4 20-7z`,stop:`M6 6h12v12H6z`,x:`M6 6l12 12M18 6L6 18`,chevron:`M6 9l6 6 6-6`,right:`M9 6l6 6-6 6`,left:`M15 6l-6 6 6 6`,down:`M12 5v14M5 12l7 7 7-7`,edit:`M12 20h9M16.5 3.5a2.1 2.1 0 0 1 3 3L7 19l-4 1 1-4z`,undo:`M3 7v6h6M21 17a9 9 0 0 0-15-6.7L3 13`,grip:`M9 5h.01M9 12h.01M9 19h.01M15 5h.01M15 12h.01M15 19h.01`,tool:`M14.7 6.3a1 1 0 0 0 0 1.4l1.6 1.6a1 1 0 0 0 1.4 0l3.8-3.8a6 6 0 0 1-7.9 7.9l-6.9 6.9a2.1 2.1 0 0 1-3-3l6.9-6.9a6 6 0 0 1 7.9-7.9z`,file:`M14 2H6a2 2 0 0 0-2 2v16a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V8zM14 2v6h6`,image:`M3 3h18v18H3zM8.5 10a1.5 1.5 0 1 0 0-3 1.5 1.5 0 0 0 0 3zM21 15l-5-5L5 21`,target:`M12 22a10 10 0 1 0 0-20 10 10 0 0 0 0 20zM12 18a6 6 0 1 0 0-12 6 6 0 0 0 0 12zM12 14a2 2 0 1 0 0-4 2 2 0 0 0 0 4z`,pen:`M12 19l7-7 3 3-7 7zM18 13l-1.5-7.5L2 2l3.5 14.5L13 18zM2 2l7.6 7.6`,check:`M20 6L9 17l-5-5`,copy:`M9 9h11v11H9zM5 15H4a1 1 0 0 1-1-1V4a1 1 0 0 1 1-1h10a1 1 0 0 1 1 1v1`,download:`M21 15v4a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2v-4M7 10l5 5 5-5M12 15V3`,zoom:`M15 3h6v6M9 21H3v-6M21 3l-7 7M3 21l7-7`,monitor:`M2 3h20v14H2zM8 21h8M12 17v4`,phone:`M7 2h10v20H7zM12 18h.01`,history:`M3 3v5h5M3.05 13A9 9 0 1 0 6 5.3L3 8M12 7v5l4 2`,sparkle:`M12 3l1.9 5.8L20 11l-6.1 2.2L12 19l-1.9-5.8L4 11l6.1-2.2z`,refresh:`M23 4v6h-6M1 20v-6h6M3.5 9a9 9 0 0 1 14.9-3.4L23 10M1 14l4.6 4.4A9 9 0 0 0 20.5 15`,trash:`M3 6h18M8 6V4h8v2M19 6l-1 14H6L5 6`,search:`M11 19a8 8 0 1 0 0-16 8 8 0 0 0 0 16zM21 21l-4.3-4.3`,external:`M18 13v6a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2V8a2 2 0 0 1 2-2h6M15 3h6v6M10 14L21 3`,sun:`M12 17a5 5 0 1 0 0-10 5 5 0 0 0 0 10zM12 1v2M12 21v2M4.2 4.2l1.4 1.4M18.4 18.4l1.4 1.4M1 12h2M21 12h2M4.2 19.8l1.4-1.4M18.4 5.6l1.4-1.4`,robot:`M12 8V4H8M4 8h16v12H4zM2 14h2M20 14h2M15 13v2M9 13v2`,chat:`M21 15a2 2 0 0 1-2 2H7l-4 4V5a2 2 0 0 1 2-2h14a2 2 0 0 1 2 2z`,chevrons:`M7 13l5 5 5-5M7 6l5 5 5-5`,alert:`M12 22a10 10 0 1 0 0-20 10 10 0 0 0 0 20zM12 8v4M12 16h.01`,cpu:`M5 5h14v14H5zM9 9h6v6H9zM9 2v3M15 2v3M9 19v3M15 19v3M19 9h3M19 14h3M2 9h3M2 14h3`,moon:`M21 12.8A9 9 0 1 1 11.2 3a7 7 0 0 0 9.8 9.8z`};return(n,r)=>(B(),V(`svg`,Xo,[H(`path`,{d:t[e.name]??``},null,8,Zo)]))}});function Qo(e,t){if(t.t===`turn_begin`)return e.some(e=>e.id===t.turnId)||e.push({id:t.turnId,ts:t.ts,user:t.user,agent:t.agent,model:t.model,items:[],status:`running`,files:[],artifacts:[],lastSeq:t.seq}),e;let n=$o(e,t.turnId);if(!n||t.seq<=n.lastSeq&&t.seq!==0)return e;n.lastSeq=t.seq;let r=n.items[n.items.length-1];switch(t.t){case`text`:case`thinking`:{let e=t.t;r&&r.kind===e?r.text+=t.delta:n.items.push({kind:e,text:t.delta});break}case`tool`:{let e=n.items.find(e=>e.kind===`tool`&&e.id===t.id);e?(e.status=t.status,t.input!==void 0&&(e.input=t.input),t.output!==void 0&&(e.output=t.output),t.name&&e.name!==t.name&&(e.name=t.name)):n.items.push({kind:`tool`,id:t.id,name:t.name,input:t.input,status:t.status,output:t.output});for(let e of t.files??[])n.files.includes(e)||n.files.push(e);break}case`ask`:n.items.push({kind:`ask`,askId:t.askId,spec:t.spec});break;case`ask_answer`:{let e=n.items.find(e=>e.kind===`ask`&&e.askId===t.askId);e&&(e.answer=t.answer);break}case`artifact`:n.artifacts.push({name:t.name,version:t.version});break;case`notice`:n.items.push({kind:`notice`,level:t.level,message:t.message});break;case`error`:n.items.push({kind:`error`,message:t.message});break;case`turn_end`:n.status=t.status,n.endTs=t.ts,n.usage=t.usage,n.durationMs=t.durationMs,n.message=t.message}return e}function $o(e,t){for(let n=e.length-1;n>=0;n--)if(e[n].id===t)return e[n]}function es(e){return e.status!==`running`&&!e.items.some(e=>e.kind===`text`&&e.text.trim()||e.kind===`tool`||e.kind===`ask`||e.kind===`error`)}var ts=class extends Error{status;constructor(e,t){super(t),this.status=e}};async function ns(e,t,n,r){let i={};e!==`GET`&&(i[`X-PH`]=`1`),n!==void 0&&(i[`Content-Type`]=`application/json`);let a=await fetch(`/__ph/api/${t}`,{method:e,headers:i,body:r??(n===void 0?void 0:JSON.stringify(n)),credentials:`same-origin`}),o=(a.headers.get(`content-type`)??``).includes(`json`)?await a.json():await a.text();if(!a.ok)throw new ts(a.status,(o&&typeof o==`object`&&`error`in o?String(o.error):String(o))||a.statusText);return o}var rs={get:e=>ns(`GET`,e),post:(e,t)=>ns(`POST`,e,t??{}),patch:(e,t)=>ns(`PATCH`,e,t),del:e=>ns(`DELETE`,e),upload:(e,t)=>ns(`POST`,`uploads?name=${encodeURIComponent(t)}&mime=${encodeURIComponent(e.type||`application/octet-stream`)}`,void 0,e)},is=(e,t,n=!1)=>`/__ph/api/artifacts/${encodeURIComponent(e)}/raw${t?`?v=${t}`:``}${n?`${t?`&`:`?`}download`:``}`,as=e=>`/__ph/api/uploads/${encodeURIComponent(e)}`,os={connecting:`正在连接…`,ready:`已就绪`,netError:`网络错误,正在重试…`,retryNow:`立即重试`,newChat:`新对话`,untitled:`未命名对话`,rename:`改名`,delete:`删除`,confirmDelete:`删除这个对话及其记录?`,history:`聊天记录`,agent:`Agent`,model:`模型`,defaultModel:`默认模型`,notInstalled:`未安装`,settings:`页面协作设置`,allowControl:`允许 Agent 操作此页面`,controlPrivacy:`Agent 可以读取当前页面的内容(密码框除外)并点击、输入、滚动。数据只在本机与 Agent CLI 之间传递。`,status_online:`在线`,status_transferred:`已转到其它标签页`,status_paused:`已暂停(页面在后台)`,status_offline:`离线`,status_disabled:`未开启`,status_unsupported:`页面脚本版本过旧,请刷新页面`,liveToggle:`页面候选(Live)`,liveDesc:`在页面上选中元素后可让 Agent 直接生成 2–4 个候选,原位切换、并排挑选、采用或放弃。`,reviewerTitle:`页面评审`,reviewerNameLabel:`你的名字(显示在你的意见上)`,reviewerNamePh:`例如:小王 / 设计`,reviewerJoin:`开始评审`,reviewerRole:`评审成员`,reviewerStats:`未解决 {open} 条 · 我写的 {mine} 条`,reviewerHowComment:`点底栏「取点」,选中页面上的元素后点「评论」,留下意见。`,reviewerHowEdit:`选中元素后点「编辑」可以直接改元素的文字、颜色、字号、间距或图片,大家都能看到效果,也能切回原版对比。`,reviewerHowThread:`点页面上的图钉可以回复、标记已解决。`,reviewerHowApprove:`在意见列表里对当前页面点「通过」或「需修改」。`,reviewerLimits:`你看到的修改只存在于这次评审里,不会改动线上网站;对话和 Agent 仅发起人可用。`,teamTitle:`团队评审`,myName:`你的名字(显示在意见上)`,teamShareDesc:`把这个链接发给同一网络里的同事,他们打开后以评审身份加入:能评论、回复、审批和改文字样式,不能使用 Agent。`,teamNoShare:`启动时加上 --share,就能生成邀请链接,让同事一起评审这个页面。`,copyLink:`复制链接`,liveReviewDesc:`这个页面没有源码(评审模式):候选以页面修改的形式出现(文字、样式、图片,可以同时改多个元素),原位切换,采用后存为修改意见。`,reviewEmptyTitle:`想对这个页面提点什么意见?`,reviewEmptyHint:`没有源码时,Agent 会在页面上直接做临时修改、或钉一条批注,不会生成 HTML 原型。用「取点」选中元素可以引用、评论、编辑或要 Live 候选;「意见」里查看全部并导出。`,language:`语言`,placeholder:`描述你想在页面上改什么…`,placeholderBusy:`Agent 正在工作,新消息会排队…`,send:`发送回复`,stop:`停止`,attach:`添加附件`,removeDraft:`移除`,queue:`待发送`,edit:`编辑`,withdraw:`撤回`,dragToReorder:`拖动排序`,thinking:`思考中…`,thoughts:`思考过程`,writing:`输出中`,done:`已完成`,cancelled:`已停止`,interrupted:`已中断`,failed:`失败`,emptyReply:`空回复:Agent 没有输出内容`,retry:`重试`,rateLimited:`Agent 触发了限流或额度不足,请稍后重试。`,changedFiles:`改动的文件`,artifacts:`产物`,tool:`工具`,input:`入参`,output:`输出`,running:`运行中`,backToBottom:`有新消息`,loadOlder:`加载更早的记录`,noMore:`没有更早的记录了`,emptyChat:`在页面上取点,或直接描述你想改什么。`,you:`你`,me:`我`,toolsUsed:`调用了 {n} 个工具`,thoughtInterrupted:`思考已中断`,enterHint:`Enter 发送 · Shift+Enter 换行`,headerLine:`{agent} · {n} 轮对话`,newCount:`{n} 条新消息`,emptyTitle:`想在这个页面上改点什么?`,emptyHint:`用「取点」选中元素、「修改」生成候选,或直接描述需求。产物会出现在「产物」里。`,searchModels:`搜索模型…`,defaultAuto:`默认(由 Agent 决定)`,useCustom:`使用 “{id}”`,modelsFailed:`没能读取模型列表,可以直接输入模型 id`,noModels:`没有匹配的模型`,loadingModels:`正在读取模型…`,groupOther:`其他`,agentVersion:`版本 {v}`,picks:`取点`,marks:`批注`,files:`附件`,question:`问题`,other:`其他`,otherPlaceholder:`自己填写…`,recommended:`推荐`,skip:`跳过`,next:`下一题`,prev:`上一题`,submit:`提交`,skipped:`已跳过`,answerTimeout:`未作答(超时)`,answerCancelled:`已取消`,required:`必填`,liveActive:`{n} 个候选进行中`,discardAll:`全部放弃({n})`,discardAllHint:`放弃所有未采用的候选,并还原页面上的候选改动`,confirmDiscardAll:`放弃 {n} 个候选?页面上的候选改动会被还原,进行中的生成会停止。`,clearFailed:`清除失败({n})`,clearFailedHint:`只移除失败的候选,其他候选不受影响`,inplace:`原位切换`,compare:`并排对比`,accept:`采用`,discard:`放弃`,retryAccept:`重试并采用`,live_generating:`生成中`,live_refining:`细化中`,live_accepting:`采用中`,live_discarding:`放弃中`,live_ready:`可挑选`,live_failed:`失败`,live_accepted:`已采用`,live_discarded:`已放弃`,allArtifacts:`全部产物`,noArtifacts:`还没有产物。Agent 写入的方案、报告、原型会出现在这里。`,new:`新`,updated:`已更新`,version:`版本`,readOnly:`历史版本(只读)`,desktop:`桌面`,mobile:`手机`,zoom:`放大`,copy:`复制`,copied:`已复制`,download:`下载`,exportPng:`导出 PNG`,exportPdf:`导出 PDF`,structured:`结构化`,raw:`原始`,loadFailed:`加载失败`,close:`关闭`,binary:`二进制文件,无法预览`,search:`搜索聊天记录…`,noChats:`还没有对话`,turns:`{n} 轮`,continueInPanel:`在面板中继续`,continueHint:`已设为面板的当前对话,回到页面打开对话即可继续。`,exportMd:`导出 Markdown`,results:`{n} 条结果`,noResults:`没有匹配的记录`,duration:`耗时`,tokens:`tokens`,selectChat:`选择左侧的对话查看记录`,justNow:`刚刚`,minutesAgo:`{n} 分钟前`,hoursAgo:`{n} 小时前`,daysAgo:`{n} 天前`},ss={connecting:`Connecting…`,ready:`Ready`,netError:`Network error, retrying…`,retryNow:`Retry now`,newChat:`New chat`,untitled:`Untitled chat`,rename:`Rename`,delete:`Delete`,confirmDelete:`Delete this chat and its history?`,history:`History`,agent:`Agent`,model:`Model`,defaultModel:`Default model`,notInstalled:`not installed`,settings:`Page collaboration`,allowControl:`Allow the agent to operate this page`,controlPrivacy:`The agent can read this page (except password fields) and click, type and scroll. Data only travels between this machine and the agent CLI.`,status_online:`Online`,status_transferred:`Moved to another tab`,status_paused:`Paused (page in background)`,status_offline:`Offline`,status_disabled:`Off`,status_unsupported:`Page script is outdated, reload the page`,liveToggle:`Page candidates (Live)`,liveDesc:`Select an element on the page and the agent renders 2–4 candidates right there: switch in place, compare side by side, accept or discard.`,reviewerTitle:`Page review`,reviewerNameLabel:`Your name (shown on your notes)`,reviewerNamePh:`e.g. Alex / Design`,reviewerJoin:`Start reviewing`,reviewerRole:`Reviewer`,reviewerStats:`{open} open · {mine} by you`,reviewerHowComment:`Click Pick in the dock, choose an element on the page, then Comment.`,reviewerHowEdit:`After picking, Edit changes an element's text, color, size, spacing or image so everyone sees it; compare with the original any time.`,reviewerHowThread:`Click a pin to reply or mark it resolved.`,reviewerHowApprove:`In the Notes list, approve the current page or request changes.`,reviewerLimits:`Changes exist only in this review; the live site is never touched. Chat and the agent are for the host only.`,teamTitle:`Team review`,myName:`Your name (shown on notes)`,teamShareDesc:`Send this link to teammates on your network. They join as reviewers: comment, reply, approve and edit text/style, but cannot use the agent.`,teamNoShare:`Start with --share to get an invite link so teammates can review this page with you.`,copyLink:`Copy link`,liveReviewDesc:`No source for this page (review mode): candidates are page changes (text, styles, images, possibly several elements), switched in place; accepting saves them as changes in Notes.`,reviewEmptyTitle:`What would you like reviewed on this page?`,reviewEmptyHint:`Without source, the agent changes the page in place or pins a note on it; no HTML mockups. Pick an element to quote, comment, edit or ask for Live candidates; Notes lists everything and exports it.`,language:`Language`,placeholder:`Describe what to change on this page…`,placeholderBusy:`The agent is working; new messages are queued…`,send:`Send`,stop:`Stop`,attach:`Attach files`,removeDraft:`Remove`,queue:`Queued`,edit:`Edit`,withdraw:`Withdraw`,dragToReorder:`Drag to reorder`,thinking:`Thinking…`,thoughts:`Thoughts`,writing:`Writing`,done:`Done`,cancelled:`Stopped`,interrupted:`Interrupted`,failed:`Failed`,emptyReply:`Empty reply: the agent produced no output`,retry:`Retry`,rateLimited:`The agent hit a rate limit or ran out of quota. Try again later.`,changedFiles:`Changed files`,artifacts:`Artifacts`,tool:`Tool`,input:`Input`,output:`Output`,running:`Running`,backToBottom:`New messages`,loadOlder:`Load earlier messages`,noMore:`No earlier messages`,emptyChat:`Pick something on the page, or just describe what to change.`,you:`You`,me:`Me`,toolsUsed:`Used {n} tool|Used {n} tools`,thoughtInterrupted:`Thinking interrupted`,enterHint:`Enter to send · Shift+Enter for a new line`,headerLine:`{agent} · {n} turn|{agent} · {n} turns`,newCount:`{n} new message|{n} new messages`,emptyTitle:`What should change on this page?`,emptyHint:`Pick an element, Modify it to get candidates, or just describe what you want. Artifacts land in Artifacts.`,searchModels:`Search models…`,defaultAuto:`Default (the agent decides)`,useCustom:`Use “{id}”`,modelsFailed:`Could not load models — type a model id`,noModels:`No matching models`,loadingModels:`Loading models…`,groupOther:`Other`,agentVersion:`Version {v}`,picks:`Picks`,marks:`Marks`,files:`Files`,question:`Question`,other:`Other`,otherPlaceholder:`Type your own…`,recommended:`Recommended`,skip:`Skip`,next:`Next`,prev:`Back`,submit:`Submit`,skipped:`Skipped`,answerTimeout:`Not answered (timed out)`,answerCancelled:`Cancelled`,required:`Required`,liveActive:`{n} candidate set open|{n} candidate sets open`,discardAll:`Discard all ({n})`,discardAllHint:`Discard every candidate not yet accepted and revert its changes on the page`,confirmDiscardAll:`Discard {n} candidate set? Its changes on the page will be reverted and any generation in progress will stop.|Discard {n} candidate sets? Their changes on the page will be reverted and any generation in progress will stop.`,clearFailed:`Clear failed ({n})`,clearFailedHint:`Remove only the failed candidates; the others stay as they are`,inplace:`In place`,compare:`Side by side`,accept:`Accept`,discard:`Discard`,retryAccept:`Retry & accept`,live_generating:`Generating`,live_refining:`Refining`,live_accepting:`Accepting`,live_discarding:`Discarding`,live_ready:`Ready`,live_failed:`Failed`,live_accepted:`Accepted`,live_discarded:`Discarded`,allArtifacts:`All artifacts`,noArtifacts:`No artifacts yet. Plans, reports and mockups the agent writes show up here.`,new:`New`,updated:`Updated`,version:`Version`,readOnly:`Old version (read-only)`,desktop:`Desktop`,mobile:`Mobile`,zoom:`Zoom`,copy:`Copy`,copied:`Copied`,download:`Download`,exportPng:`Export PNG`,exportPdf:`Export PDF`,structured:`Structured`,raw:`Raw`,loadFailed:`Failed to load`,close:`Close`,binary:`Binary file, no preview`,search:`Search history…`,noChats:`No chats yet`,turns:`{n} turn|{n} turns`,continueInPanel:`Continue in panel`,continueHint:`Set as the panel’s current chat; open the chat on the page to continue.`,exportMd:`Export Markdown`,results:`{n} result|{n} results`,noResults:`No matches`,duration:`Duration`,tokens:`tokens`,selectChat:`Select a chat on the left`,justNow:`just now`,minutesAgo:`{n} min ago`,hoursAgo:`{n} h ago`,daysAgo:`{n} d ago`};function cs(){try{let e=localStorage.getItem(`ph:lang`);if(e===`en`||e===`zh-CN`)return e}catch{}return null}var ls=Kt(cs()??(navigator.language?.toLowerCase().startsWith(`zh`)?`zh-CN`:`en`)),us=Kt(cs()!==null);function ds(e,t=!0){if(ls.value=e,document.documentElement.lang=e,t){us.value=!0;try{localStorage.setItem(`ph:lang`,e)}catch{}}}var q=G(()=>ls.value===`en`?ss:os);function fs(e,t){return e.includes(`|`)&&t.n!==void 0&&(e=e.split(`|`)[Number(t.n)===1?0:1]),e.replace(/\{(\w+)\}/g,(e,n)=>String(t[n]??``))}function ps(e,t=Date.now()){let n=Math.max(0,t-e),r=q.value;return n<6e4?r.justNow:n<36e5?fs(r.minutesAgo,{n:Math.floor(n/6e4)}):n<864e5?fs(r.hoursAgo,{n:Math.floor(n/36e5)}):n<6048e5?fs(r.daysAgo,{n:Math.floor(n/864e5)}):new Date(e).toLocaleDateString(ls.value)}function ms(e){if(!e)return``;if(e<1e3)return`${e}ms`;let t=Math.round(e/1e3);return t<60?`${t}s`:`${Math.floor(t/60)}m${t%60?` ${t%60}s`:``}`}var hs={class:`ask card`},gs={key:0,class:`title`},_s={key:0,class:`sum`},vs={class:`qp`},ys={class:`qv`},bs={key:1,class:`sum`},xs={class:`qp`},Ss={class:`qv`},Cs={key:2,class:`faint`},ws={key:0,class:`dots`},Ts=[`onClick`],Es={class:`prompt`},Ds={class:`opts`},Os=[`type`,`name`,`checked`,`onChange`],ks={class:`ol`},As={key:0,class:`rec`},js={key:1,class:`od`},Ms={key:0,class:`opt other`},Ns={class:`ol`},Ps=[`placeholder`],Fs={class:`foot`},Is=[`disabled`],Ls=[`disabled`],Rs={key:0,class:`muted`},zs={key:0},Bs=[`onUpdate:modelValue`,`placeholder`],Vs=[`onUpdate:modelValue`,`type`,`placeholder`],Hs={class:`foot`},Us=[`disabled`],Ws=Jn({__name:`AskCard`,props:{askId:{},spec:{},answer:{},pending:{type:Boolean},turnRunning:{type:Boolean}},emits:[`answer`],setup(e,{emit:t}){let n=e,r=t,i=Kt(0),a=Ft({}),o=Ft({}),s=Ft({});if(n.spec.kind===`form`)for(let e of n.spec.fields)s[e.name]=e.default??``;let c=G(()=>!n.answer&&n.pending),l=G(()=>n.spec.kind===`question`?n.spec.questions:[]),u=G(()=>l.value[i.value]);function d(e,t,n){let r=a[e]??[];a[e]=n?r.includes(t)?r.filter(e=>e!==t):[...r,t]:[t]}let f=e=>(a[e]?.length??0)>0||!!o[e]?.trim();function p(){let e={};for(let t of l.value)e[t.id]={selected:a[t.id]??[],other:o[t.id]?.trim()||void 0};r(`answer`,n.askId,{answers:e})}let m=G(()=>n.spec.kind!==`form`||n.spec.fields.every(e=>!e.required||s[e.name]?.trim()));function h(){m.value&&r(`answer`,n.askId,{values:{...s}})}let g=()=>r(`answer`,n.askId,{skipped:!0}),_=G(()=>{let e=n.answer;return e?`skipped`in e?q.value.skipped:`timeout`in e?q.value.answerTimeout:`cancelled`in e?q.value.answerCancelled:``:n.turnRunning?``:q.value.answerCancelled}),v=(e,t)=>l.value.find(t=>t.id===e)?.options.find(e=>e.id===t)?.label??t;return(t,n)=>(B(),V(`div`,hs,[e.spec.title?(B(),V(`div`,gs,M(e.spec.title),1)):W(`v-if`,!0),W(` answered / closed `),c.value?e.spec.kind===`question`&&u.value?(B(),V(z,{key:2},[W(` question `),l.value.length>1?(B(),V(`div`,ws,[(B(!0),V(z,null,Cr(l.value,(e,t)=>(B(),V(`span`,{key:e.id,class:k({cur:t===i.value,done:f(e.id)}),onClick:e=>i.value=t},null,10,Ts))),128))])):W(`v-if`,!0),H(`div`,Es,M(u.value.prompt),1),H(`div`,Ds,[(B(!0),V(z,null,Cr(u.value.options,t=>(B(),V(`label`,{key:t.id,class:k([`opt`,{on:a[u.value.id]?.includes(t.id)}])},[H(`input`,{type:u.value.multiple?`checkbox`:`radio`,name:e.askId+u.value.id,checked:a[u.value.id]?.includes(t.id),onChange:e=>d(u.value.id,t.id,u.value.multiple)},null,40,Os),H(`span`,ks,[H(`span`,null,M(t.label),1),t.recommended?(B(),V(`span`,As,M(R(q).recommended),1)):W(`v-if`,!0),t.description?(B(),V(`span`,js,M(t.description),1)):W(`v-if`,!0)])],2))),128)),u.value.allowOther===!1?W(`v-if`,!0):(B(),V(`label`,Ms,[H(`span`,Ns,M(R(q).other),1),jn(H(`input`,{"onUpdate:modelValue":n[0]||=e=>o[u.value.id]=e,class:`input`,placeholder:R(q).otherPlaceholder,onKeydown:n[1]||=No(()=>{},[`stop`])},null,40,Ps),[[yo,o[u.value.id]]])]))]),H(`div`,Fs,[H(`button`,{class:`btn ghost sm`,onClick:g},M(R(q).skip),1),n[6]||=H(`span`,{class:`spacer`},null,-1),i.value>0?(B(),V(`button`,{key:0,class:`btn sm`,onClick:n[2]||=e=>i.value--},M(R(q).prev),1)):W(`v-if`,!0),i.value<l.value.length-1?(B(),V(`button`,{key:1,class:`btn sm primary`,disabled:!f(u.value.id),onClick:n[3]||=e=>i.value++},M(R(q).next),9,Is)):(B(),V(`button`,{key:2,class:`btn sm primary`,disabled:!l.value.every(e=>f(e.id)),onClick:p},M(R(q).submit),9,Ls))])],64)):e.spec.kind===`form`?(B(),V(z,{key:3},[W(` form `),e.spec.description?(B(),V(`div`,Rs,M(e.spec.description),1)):W(`v-if`,!0),(B(!0),V(z,null,Cr(e.spec.fields,e=>(B(),V(`label`,{key:e.name,class:`field`},[H(`span`,null,[ea(M(e.label),1),e.required?(B(),V(`em`,zs,` *`)):W(`v-if`,!0)]),e.type===`textarea`?jn((B(),V(`textarea`,{key:0,"onUpdate:modelValue":t=>s[e.name]=t,class:`input ta`,placeholder:e.placeholder,rows:`3`,onKeydown:n[4]||=No(()=>{},[`stop`])},null,40,Bs)),[[yo,s[e.name]]]):jn((B(),V(`input`,{key:1,"onUpdate:modelValue":t=>s[e.name]=t,class:`input`,type:e.type===`url`?`url`:`text`,placeholder:e.placeholder,onKeydown:[n[5]||=No(()=>{},[`stop`]),Fo(h,[`enter`])]},null,40,Vs)),[[Oo,s[e.name]]])]))),128)),H(`div`,Hs,[H(`button`,{class:`btn ghost sm`,onClick:g},M(R(q).skip),1),n[7]||=H(`span`,{class:`spacer`},null,-1),H(`button`,{class:`btn sm primary`,disabled:!m.value,onClick:h},M(R(q).submit),9,Us)])],64)):W(`v-if`,!0):(B(),V(z,{key:1},[e.answer&&`answers`in e.answer?(B(),V(`div`,_s,[(B(!0),V(z,null,Cr(l.value,t=>(B(),V(`div`,{key:t.id,class:`qa`},[H(`div`,vs,M(t.prompt),1),H(`div`,ys,M([...(e.answer.answers[t.id]?.selected??[]).map(e=>v(t.id,e)),e.answer.answers[t.id]?.other?`${R(q).other}: ${e.answer.answers[t.id]?.other}`:``].filter(Boolean).join(`、`)||`—`),1)]))),128))])):e.answer&&`values`in e.answer&&e.spec.kind===`form`?(B(),V(`div`,bs,[(B(!0),V(z,null,Cr(e.spec.fields,t=>(B(),V(`div`,{key:t.name,class:`qa`},[H(`div`,xs,M(t.label),1),H(`div`,Ss,M(e.answer.values[t.name]||`—`),1)]))),128))])):W(`v-if`,!0),_.value?(B(),V(`div`,Cs,M(_.value),1)):W(`v-if`,!0)],64))]))}}),Gs=(e,t)=>{let n=e.__vccOpts||e;for(let[e,r]of t)n[e]=r;return n},Ks=Gs(Ws,[[`__scopeId`,`data-v-5d5b7c6b`]]),qs=[`data-side`],Js={class:`top`},Ys=[`title`],Xs={key:0,class:`spin`},Zs={key:0,class:`prompt muted`},Qs={key:1,class:`err`},$s={key:0,class:`vars`},ec=[`onClick`],tc={key:1,class:`vars`},nc={class:`acts`},rc=Gs(Jn({__name:`LiveCard`,props:{session:{},title:{},view:{},interactive:{type:Boolean},compact:{type:Boolean},agent:{type:Boolean}},emits:[`op`,`nav`],setup(e,{emit:t}){let n=e,r=t,i=G(()=>n.session),a=G(()=>n.view?.current??i.value?.variants[0]?.index??1),o=G(()=>n.view?.display??i.value?.display??`inplace`),s=G(()=>!!i.value&&[`generating`,`refining`,`accepting`,`discarding`].includes(i.value.status)),c=G(()=>i.value?q.value[`live_${i.value.status}`]??i.value.status:``);function l(e){if(!i.value)return;let t=i.value.variants.map(e=>e.index),n=t.indexOf(a.value);r(`nav`,i.value.sid,t[(n+e+t.length)%t.length],`inplace`)}return(t,n)=>(B(),V(`div`,{class:k([`live card`,[i.value?.status,{compact:e.compact,agent:e.agent}]]),"data-side":e.agent?`agent`:`user`},[H(`div`,Js,[U(K,{name:`sparkle`,class:`ic`}),H(`span`,{class:`title`,title:e.title},M(e.title),9,Ys),i.value?(B(),V(`span`,{key:0,class:k([`st`,{busy:s.value}])},[s.value?(B(),V(`span`,Xs)):W(`v-if`,!0),ea(M(c.value),1)],2)):W(`v-if`,!0)]),i.value?.prompt&&!e.agent?(B(),V(`div`,Zs,M(i.value.prompt),1)):W(`v-if`,!0),i.value?.error&&i.value.status===`failed`&&!e.compact?(B(),V(`div`,Qs,M(i.value.error),1)):W(`v-if`,!0),i.value&&e.interactive&&!e.compact?(B(),V(z,{key:2},[i.value.variants.length&&i.value.status===`ready`?(B(),V(`div`,$s,[H(`button`,{class:`btn icon sm`,onClick:n[0]||=e=>l(-1)},[U(K,{name:`left`})]),(B(!0),V(z,null,Cr(i.value.variants,e=>(B(),V(`button`,{key:e.index,class:k([`btn sm`,{on:e.index===a.value}]),onClick:t=>r(`nav`,i.value.sid,e.index,`inplace`)},M(e.index)+` · `+M(e.label),11,ec))),128)),H(`button`,{class:`btn icon sm`,onClick:n[1]||=e=>l(1)},[U(K,{name:`right`})])])):i.value.variants.length?(B(),V(`div`,tc,[(B(!0),V(z,null,Cr(i.value.variants,e=>(B(),V(`span`,{key:e.index,class:k([`chip`,{acc:i.value.accepted===e.index&&i.value.status===`accepted`}])},M(e.index)+` · `+M(e.label),3))),128))])):W(`v-if`,!0),H(`div`,nc,[i.value.status===`ready`?(B(),V(z,{key:0},[H(`button`,{class:`btn sm`,onClick:n[2]||=e=>r(`nav`,i.value.sid,void 0,o.value===`compare`?`inplace`:`compare`)},M(o.value===`compare`?R(q).inplace:R(q).compare),1),n[9]||=H(`span`,{class:`spacer`},null,-1),H(`button`,{class:`btn sm`,onClick:n[3]||=e=>r(`op`,{op:`discard`,sid:i.value.sid})},M(R(q).discard),1),H(`button`,{class:`btn sm primary`,onClick:n[4]||=e=>r(`op`,{op:`accept`,sid:i.value.sid,variant:a.value})},M(R(q).accept),1)],64)):i.value.status===`failed`?(B(),V(z,{key:1},[n[10]||=H(`span`,{class:`spacer`},null,-1),H(`button`,{class:`btn sm`,onClick:n[5]||=e=>r(`op`,{op:`discard`,sid:i.value.sid})},M(R(q).discard),1),i.value.accepted===void 0?W(`v-if`,!0):(B(),V(`button`,{key:0,class:`btn sm`,onClick:n[6]||=e=>r(`op`,{op:`retry`,sid:i.value.sid,andAccept:!0})},M(R(q).retryAccept),1)),H(`button`,{class:`btn sm primary`,onClick:n[7]||=e=>r(`op`,{op:`retry`,sid:i.value.sid})},M(R(q).retry),1)],64)):i.value.status===`generating`||i.value.status===`refining`?(B(),V(z,{key:2},[n[11]||=H(`span`,{class:`spacer`},null,-1),H(`button`,{class:`btn sm`,onClick:n[8]||=e=>r(`op`,{op:`discard`,sid:i.value.sid})},M(R(q).discard),1)],64)):W(`v-if`,!0)])],64)):W(`v-if`,!0)],10,qs))}}),[[`__scopeId`,`data-v-1e552fb6`]]),ic=e({default:()=>Al});function ac(e,t){this.v=e,this.k=t}function oc(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,r=Array(t);n<t;n++)r[n]=e[n];return r}function sc(e){if(Array.isArray(e))return e}function cc(e,t){var n=e==null?null:typeof Symbol<`u`&&e[Symbol.iterator]||e[`@@iterator`];if(n!=null){var r,i,a,o,s=[],c=!0,l=!1;try{if(a=(n=n.call(e)).next,t===0){if(Object(n)!==n)return;c=!1}else for(;!(c=(r=a.call(n)).done)&&(s.push(r.value),s.length!==t);c=!0);}catch(e){l=!0,i=e}finally{try{if(!c&&n.return!=null&&(o=n.return(),Object(o)!==o))return}finally{if(l)throw i}}return s}}function lc(){throw TypeError(`Invalid attempt to destructure non-iterable instance.
|
|
4
|
-
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function uc(e,t){return sc(e)||cc(e,t)||dc(e,t)||lc()}function dc(e,t){if(e){if(typeof e==`string`)return oc(e,t);var n={}.toString.call(e).slice(8,-1);return n===`Object`&&e.constructor&&(n=e.constructor.name),n===`Map`||n===`Set`?Array.from(e):n===`Arguments`||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?oc(e,t):void 0}}function fc(e){var t,n;function r(t,n){try{var a=e[t](n),o=a.value,s=o instanceof ac;Promise.resolve(s?o.v:o).then(function(n){if(s){var c=t===`return`&&o.k?t:`next`;if(!o.k||n.done)return r(c,n);n=e[c](n).value}i(!!a.done,n)},function(e){r(`throw`,e)})}catch(e){i(2,e)}}function i(e,i){e===2?t.reject(i):t.resolve({value:i,done:e}),(t=t.next)?r(t.key,t.arg):n=null}this._invoke=function(e,i){return new Promise(function(a,o){var s={key:e,arg:i,resolve:a,reject:o,next:null};n?n=n.next=s:(t=n=s,r(e,i))})},typeof e.return!=`function`&&(this.return=void 0)}fc.prototype[typeof Symbol==`function`&&Symbol.asyncIterator||`@@asyncIterator`]=function(){return this},fc.prototype.next=function(e){return this._invoke(`next`,e)},fc.prototype.throw=function(e){return this._invoke(`throw`,e)},fc.prototype.return=function(e){return this._invoke(`return`,e)};var pc=Object.entries,mc=Object.setPrototypeOf,hc=Object.isFrozen,gc=Object.getPrototypeOf,_c=Object.getOwnPropertyDescriptor,J=Object.freeze,vc=Object.seal,yc=Object.create,bc=typeof Reflect<`u`&&Reflect,xc=bc.apply,Sc=bc.construct;J||=function(e){return e},vc||=function(e){return e},xc||=function(e,t){var n=[...arguments].slice(2);return e.apply(t,n)},Sc||=function(e){return new e(...[...arguments].slice(1))};var Cc=Y(Array.prototype.forEach);Array.prototype.indexOf;var wc=Y(Array.prototype.lastIndexOf),Tc=Y(Array.prototype.pop),Ec=Y(Array.prototype.push);Array.prototype.slice;var Dc=Y(Array.prototype.splice),Oc=Array.isArray,kc=Y(String.prototype.toLowerCase),Ac=Y(String.prototype.toString),jc=Y(String.prototype.match),Mc=Y(String.prototype.replace),Nc=Y(String.prototype.indexOf),Pc=Y(String.prototype.trim),Fc=Y(Number.prototype.toString),Ic=Y(Boolean.prototype.toString),Lc=typeof BigInt>`u`?null:Y(BigInt.prototype.toString),Rc=typeof Symbol>`u`?null:Y(Symbol.prototype.toString),zc=Y(Object.prototype.hasOwnProperty),Bc=Y(Object.prototype.toString),Vc=Y(RegExp.prototype.test),Hc=Uc(TypeError);function Y(e){return function(t){t instanceof RegExp&&(t.lastIndex=0);var n=[...arguments].slice(1);return xc(e,t,n)}}function Uc(e){return function(){return Sc(e,[...arguments])}}function X(e,t){let n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:kc;if(mc&&mc(e,null),!Oc(t))return e;let r=t.length;for(;r--;){let i=t[r];if(typeof i==`string`){let e=n(i);e!==i&&(hc(t)||(t[r]=e),i=e)}e[i]=!0}return e}function Wc(e){for(let t=0;t<e.length;t++)zc(e,t)||(e[t]=null);return e}function Gc(e){let t=yc(null);for(let r of pc(e)){var n=uc(r,2);let i=n[0],a=n[1];zc(e,i)&&(t[i]=Oc(a)?Wc(a):a&&typeof a==`object`&&a.constructor===Object?Gc(a):a)}return t}function Kc(e){switch(typeof e){case`string`:return e;case`number`:return Fc(e);case`boolean`:return Ic(e);case`bigint`:return Lc?Lc(e):`0`;case`symbol`:return Rc?Rc(e):`Symbol()`;case`undefined`:return Bc(e);case`function`:case`object`:{if(e===null)return Bc(e);let t=e,n=qc(t,`toString`);if(typeof n==`function`){let e=n(t);return typeof e==`string`?e:Bc(e)}return Bc(e)}default:return Bc(e)}}function qc(e,t){for(;e!==null;){let n=_c(e,t);if(n){if(n.get)return Y(n.get);if(typeof n.value==`function`)return Y(n.value)}e=gc(e)}function n(){return null}return n}function Jc(e){try{return Vc(e,``),!0}catch{return!1}}var Yc=J(`a.abbr.acronym.address.area.article.aside.audio.b.bdi.bdo.big.blink.blockquote.body.br.button.canvas.caption.center.cite.code.col.colgroup.content.data.datalist.dd.decorator.del.details.dfn.dialog.dir.div.dl.dt.element.em.fieldset.figcaption.figure.font.footer.form.h1.h2.h3.h4.h5.h6.head.header.hgroup.hr.html.i.img.input.ins.kbd.label.legend.li.main.map.mark.marquee.menu.menuitem.meter.nav.nobr.ol.optgroup.option.output.p.picture.pre.progress.q.rp.rt.ruby.s.samp.search.section.select.shadow.slot.small.source.spacer.span.strike.strong.style.sub.summary.sup.table.tbody.td.template.textarea.tfoot.th.thead.time.tr.track.tt.u.ul.var.video.wbr`.split(`.`)),Xc=J(`svg.a.altglyph.altglyphdef.altglyphitem.animatecolor.animatemotion.animatetransform.circle.clippath.defs.desc.ellipse.enterkeyhint.exportparts.filter.font.g.glyph.glyphref.hkern.image.inputmode.line.lineargradient.marker.mask.metadata.mpath.part.path.pattern.polygon.polyline.radialgradient.rect.stop.style.switch.symbol.text.textpath.title.tref.tspan.view.vkern`.split(`.`)),Zc=J([`feBlend`,`feColorMatrix`,`feComponentTransfer`,`feComposite`,`feConvolveMatrix`,`feDiffuseLighting`,`feDisplacementMap`,`feDistantLight`,`feDropShadow`,`feFlood`,`feFuncA`,`feFuncB`,`feFuncG`,`feFuncR`,`feGaussianBlur`,`feImage`,`feMerge`,`feMergeNode`,`feMorphology`,`feOffset`,`fePointLight`,`feSpecularLighting`,`feSpotLight`,`feTile`,`feTurbulence`]),Qc=J([`animate`,`color-profile`,`cursor`,`discard`,`font-face`,`font-face-format`,`font-face-name`,`font-face-src`,`font-face-uri`,`foreignobject`,`hatch`,`hatchpath`,`mesh`,`meshgradient`,`meshpatch`,`meshrow`,`missing-glyph`,`script`,`set`,`solidcolor`,`unknown`,`use`]),$c=J(`math.menclose.merror.mfenced.mfrac.mglyph.mi.mlabeledtr.mmultiscripts.mn.mo.mover.mpadded.mphantom.mroot.mrow.ms.mspace.msqrt.mstyle.msub.msup.msubsup.mtable.mtd.mtext.mtr.munder.munderover.mprescripts`.split(`.`)),el=J([`maction`,`maligngroup`,`malignmark`,`mlongdiv`,`mscarries`,`mscarry`,`msgroup`,`mstack`,`msline`,`msrow`,`semantics`,`annotation`,`annotation-xml`,`mprescripts`,`none`]),tl=J([`#text`]),nl=J(`accept.action.align.alt.autocapitalize.autocomplete.autopictureinpicture.autoplay.background.bgcolor.border.capture.cellpadding.cellspacing.checked.cite.class.clear.color.cols.colspan.command.commandfor.controls.controlslist.coords.crossorigin.datetime.decoding.default.dir.disabled.disablepictureinpicture.disableremoteplayback.download.draggable.enctype.enterkeyhint.exportparts.face.for.headers.height.hidden.high.href.hreflang.id.inert.inputmode.integrity.ismap.kind.label.lang.list.loading.loop.low.max.maxlength.media.method.min.minlength.multiple.muted.name.nonce.noshade.novalidate.nowrap.open.optimum.part.pattern.placeholder.playsinline.popover.popovertarget.popovertargetaction.poster.preload.pubdate.radiogroup.readonly.rel.required.rev.reversed.role.rows.rowspan.spellcheck.scope.selected.shape.size.sizes.slot.span.srclang.start.src.srcset.step.style.summary.tabindex.title.translate.type.usemap.valign.value.width.wrap.xmlns`.split(`.`)),rl=J(`accent-height.accumulate.additive.alignment-baseline.amplitude.ascent.attributename.attributetype.azimuth.basefrequency.baseline-shift.begin.bias.by.class.clip.clippathunits.clip-path.clip-rule.color.color-interpolation.color-interpolation-filters.color-profile.color-rendering.cx.cy.d.dx.dy.diffuseconstant.direction.display.divisor.dominant-baseline.dur.edgemode.elevation.end.exponent.fill.fill-opacity.fill-rule.filter.filterunits.flood-color.flood-opacity.font-family.font-size.font-size-adjust.font-stretch.font-style.font-variant.font-weight.fx.fy.g1.g2.glyph-name.glyphref.gradientunits.gradienttransform.height.href.id.image-rendering.in.in2.intercept.k.k1.k2.k3.k4.kerning.keypoints.keysplines.keytimes.lang.lengthadjust.letter-spacing.kernelmatrix.kernelunitlength.lighting-color.local.marker-end.marker-mid.marker-start.markerheight.markerunits.markerwidth.maskcontentunits.maskunits.max.mask.mask-type.media.method.mode.min.name.numoctaves.offset.operator.opacity.order.orient.orientation.origin.overflow.paint-order.path.pathlength.patterncontentunits.patterntransform.patternunits.pointer-events.points.preservealpha.preserveaspectratio.primitiveunits.r.rx.ry.radius.refx.refy.repeatcount.repeatdur.restart.result.rotate.scale.seed.shape-rendering.slope.specularconstant.specularexponent.spreadmethod.startoffset.stddeviation.stitchtiles.stop-color.stop-opacity.stroke-dasharray.stroke-dashoffset.stroke-linecap.stroke-linejoin.stroke-miterlimit.stroke-opacity.stroke.stroke-width.style.surfacescale.systemlanguage.tabindex.tablevalues.targetx.targety.transform.transform-origin.text-anchor.text-decoration.text-orientation.text-rendering.textlength.type.u1.u2.unicode.values.vector-effect.viewbox.visibility.version.vert-adv-y.vert-origin-x.vert-origin-y.width.word-spacing.wrap.writing-mode.xchannelselector.ychannelselector.x.x1.x2.xmlns.y.y1.y2.z.zoomandpan`.split(`.`)),il=J(`accent.accentunder.align.bevelled.close.columnalign.columnlines.columnspacing.columnspan.denomalign.depth.dir.display.displaystyle.encoding.fence.frame.height.href.id.largeop.length.linethickness.lquote.lspace.mathbackground.mathcolor.mathsize.mathvariant.maxsize.minsize.movablelimits.notation.numalign.open.rowalign.rowlines.rowspacing.rowspan.rspace.rquote.scriptlevel.scriptminsize.scriptsizemultiplier.selection.separator.separators.stretchy.subscriptshift.supscriptshift.symmetric.voffset.width.xmlns`.split(`.`)),al=J([`xlink:href`,`xml:id`,`xlink:title`,`xml:space`,`xmlns:xlink`]),ol=vc(/{{[\w\W]*|^[\w\W]*}}/g),sl=vc(/<%[\w\W]*|^[\w\W]*%>/g),cl=vc(/\${[\w\W]*/g),ll=vc(/^data-[\-\w.\u00B7-\uFFFF]+$/),ul=vc(/^aria-[\-\w]+$/),dl=vc(/^(?:(?:(?:f|ht)tps?|mailto|tel|callto|sms|cid|xmpp|matrix):|[^a-z]|[a-z+.\-]+(?:[^a-z+.\-:]|$))/i),fl=vc(/^(?:\w+script|data):/i),pl=vc(/[\u0000-\u0020\u00A0\u1680\u180E\u2000-\u2029\u205F\u3000]/g),ml=vc(/^html$/i),hl=vc(/^[a-z][.\w]*(-[.\w]+)+$/i),gl=vc(/<[/\w!]/g),_l=vc(/<[/\w]/g),vl=vc(/<\/no(script|embed|frames)/i),yl=vc(/\/>/i),bl={element:1,attribute:2,text:3,cdataSection:4,entityReference:5,entityNode:6,processingInstruction:7,comment:8,document:9,documentType:10,documentFragment:11,notation:12},xl=[`style`,`script`,`xmp`,`iframe`,`noembed`,`noframes`,`plaintext`,`noscript`],Sl=J(X({},xl)),Cl=function(){let e={};return Cc(xl,t=>{e[t]=vc(RegExp(`</`+t+`(?=[\\t\\n\\f\\r />])`,`i`))}),J(e)}(),wl=function(){return typeof window>`u`?null:window},Tl=function(e,t){if(typeof e!=`object`||typeof e.createPolicy!=`function`)return null;let n=null,r=`data-tt-policy-suffix`;t&&t.hasAttribute(r)&&(n=t.getAttribute(r));let i=`dompurify`+(n?`#`+n:``);try{return e.createPolicy(i,{createHTML(e){return e},createScriptURL(e){return e}})}catch{return console.warn(`TrustedTypes policy `+i+` could not be created.`),null}},El=function(){return{afterSanitizeAttributes:[],afterSanitizeElements:[],afterSanitizeShadowDOM:[],beforeSanitizeAttributes:[],beforeSanitizeElements:[],beforeSanitizeShadowDOM:[],uponSanitizeAttribute:[],uponSanitizeElement:[],uponSanitizeShadowNode:[]}},Dl=function(e,t,n,r){return zc(e,t)&&Oc(e[t])?X(r.base?Gc(r.base):{},e[t],r.transform):n},Ol=function(e,t,n){let r=zc(e,t)?e[t]:void 0;return r&&typeof r==`object`?Gc(r):n()};function kl(){let e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:wl(),t=e=>kl(e);if(t.version=`3.4.16`,t.removed=[],!e||!e.document||e.document.nodeType!==bl.document||!e.Element)return t.isSupported=!1,t;let n=e.document,r=n,i=r.currentScript;e.DocumentFragment;let a=e.HTMLTemplateElement,o=e.Node,s=e.Element,c=e.NodeFilter;e.NamedNodeMap===void 0&&(e.NamedNodeMap||e.MozNamedAttrMap),e.HTMLFormElement;let l=e.DOMParser,u=e.trustedTypes,d=s.prototype,f=qc(d,`cloneNode`),p=qc(d,`remove`),m=qc(d,`removeAttributeNode`),h=qc(d,`nextSibling`),g=qc(d,`childNodes`),_=qc(d,`parentNode`),v=qc(d,`shadowRoot`),y=qc(d,`attributes`),b=o&&o.prototype?qc(o.prototype,`nodeType`):null,x=o&&o.prototype?qc(o.prototype,`nodeName`):null,S=o&&o.prototype?qc(o.prototype,`ownerDocument`):null,C=function(e){return b?b(e):e.nodeType},ee=function(e){return x?x(e):e.nodeName};if(typeof a==`function`){let e=n.createElement(`template`);e.content&&e.content.ownerDocument&&(n=e.content.ownerDocument)}let w,te=``,ne,re=!1,T=0,ie=function(){if(T>0)throw Hc(`A configured TRUSTED_TYPES_POLICY callback (createHTML or createScriptURL) must not call DOMPurify.sanitize, as that causes infinite recursion. Do not pass a policy whose callbacks wrap DOMPurify as TRUSTED_TYPES_POLICY; see the "DOMPurify and Trusted Types" section of the README.`)},E=function(e){ie(),T++;try{return w.createHTML(e)}finally{T--}},ae=function(e){ie(),T++;try{return w.createScriptURL(e)}finally{T--}},oe=function(){return re||=(ne=Tl(u,i),!0),ne},se=n,D=se.implementation,ce=se.createNodeIterator,le=se.createDocumentFragment,ue=se.getElementsByTagName,de=r.importNode,O=El();t.isSupported=typeof pc==`function`&&typeof _==`function`&&D&&D.createHTMLDocument!==void 0;let fe=ol,pe=sl,me=cl,he=ll,k=ul,ge=fl,_e=pl,ve=hl,ye=dl,A=null,be=X({},[...Yc,...Xc,...Zc,...$c,...tl]),j=null,xe=X({},[...nl,...rl,...il,...al]),Se=Object.seal(yc(null,{tagNameCheck:{writable:!0,configurable:!1,enumerable:!0,value:null},attributeNameCheck:{writable:!0,configurable:!1,enumerable:!0,value:null},allowCustomizedBuiltInElements:{writable:!0,configurable:!1,enumerable:!0,value:!1}})),Ce=null,M=null,we=Object.seal(yc(null,{tagCheck:{writable:!0,configurable:!1,enumerable:!0,value:null},attributeCheck:{writable:!0,configurable:!1,enumerable:!0,value:null}})),Te=!0,N=!0,Ee=!1,De=!0,P=!1,Oe=!0,ke=!1,Ae=!1,je=null,Me=null,Ne=!1,Pe=!1,Fe=!1,Ie=!1,Le=!0,Re=!1,ze=`user-content-`,Be=!0,Ve=!1,He={},Ue=null,We=X({},`annotation-xml.audio.colgroup.desc.foreignobject.head.iframe.math.mi.mn.mo.ms.mtext.noembed.noframes.noscript.plaintext.script.selectedcontent.style.svg.template.thead.title.video.xmp`.split(`.`)),Ge=null,Ke=X({},[`audio`,`video`,`img`,`source`,`image`,`track`]),qe=null,Je=X({},[`alt`,`class`,`for`,`id`,`label`,`name`,`pattern`,`placeholder`,`role`,`summary`,`title`,`value`,`style`,`xmlns`]),Ye=`http://www.w3.org/1998/Math/MathML`,Xe=`http://www.w3.org/2000/svg`,Ze=`http://www.w3.org/1999/xhtml`,Qe=Ze,$e=!1,et=null,tt=X({},[Ye,Xe,Ze],Ac),nt=J([`mi`,`mo`,`mn`,`ms`,`mtext`]),rt=X({},nt),it=J([`annotation-xml`]),at=X({},it),ot=X({},[`title`,`style`,`font`,`a`,`script`]),st=null,ct=[`application/xhtml+xml`,`text/html`],F=null,lt=null,ut=n.createElement(`form`),dt=function(e){return e instanceof RegExp||e instanceof Function},ft=function(){let e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};if(lt&<===e)return;(!e||typeof e!=`object`)&&(e={}),e=Gc(e),st=ct.indexOf(e.PARSER_MEDIA_TYPE)===-1?`text/html`:e.PARSER_MEDIA_TYPE,F=st===`application/xhtml+xml`?Ac:kc,A=Dl(e,`ALLOWED_TAGS`,be,{transform:F}),j=Dl(e,`ALLOWED_ATTR`,xe,{transform:F}),et=Dl(e,`ALLOWED_NAMESPACES`,tt,{transform:Ac}),qe=Dl(e,`ADD_URI_SAFE_ATTR`,Je,{transform:F,base:Je}),Ge=Dl(e,`ADD_DATA_URI_TAGS`,Ke,{transform:F,base:Ke}),Ue=Dl(e,`FORBID_CONTENTS`,We,{transform:F}),Ce=Dl(e,`FORBID_TAGS`,Gc({}),{transform:F}),M=Dl(e,`FORBID_ATTR`,Gc({}),{transform:F}),He=zc(e,`USE_PROFILES`)?e.USE_PROFILES&&typeof e.USE_PROFILES==`object`?Gc(e.USE_PROFILES):e.USE_PROFILES:!1,Te=e.ALLOW_ARIA_ATTR!==!1,N=e.ALLOW_DATA_ATTR!==!1,Ee=e.ALLOW_UNKNOWN_PROTOCOLS||!1,De=e.ALLOW_SELF_CLOSE_IN_ATTR!==!1,P=e.SAFE_FOR_TEMPLATES||!1,Oe=e.SAFE_FOR_XML!==!1,ke=e.WHOLE_DOCUMENT||!1,Pe=e.RETURN_DOM||!1,Fe=e.RETURN_DOM_FRAGMENT||!1,Ie=e.RETURN_TRUSTED_TYPE||!1,Ne=e.FORCE_BODY||!1,Le=e.SANITIZE_DOM!==!1,Re=e.SANITIZE_NAMED_PROPS||!1,Be=e.KEEP_CONTENT!==!1,Ve=e.IN_PLACE||!1,ye=Jc(e.ALLOWED_URI_REGEXP)?e.ALLOWED_URI_REGEXP:dl,Qe=typeof e.NAMESPACE==`string`?e.NAMESPACE:Ze,rt=Ol(e,`MATHML_TEXT_INTEGRATION_POINTS`,()=>X({},nt)),at=Ol(e,`HTML_INTEGRATION_POINTS`,()=>X({},it));let t=Ol(e,`CUSTOM_ELEMENT_HANDLING`,()=>yc(null));if(Se=yc(null),zc(t,`tagNameCheck`)&&dt(t.tagNameCheck)&&(Se.tagNameCheck=t.tagNameCheck),zc(t,`attributeNameCheck`)&&dt(t.attributeNameCheck)&&(Se.attributeNameCheck=t.attributeNameCheck),zc(t,`allowCustomizedBuiltInElements`)&&typeof t.allowCustomizedBuiltInElements==`boolean`&&(Se.allowCustomizedBuiltInElements=t.allowCustomizedBuiltInElements),vc(Se),P&&(N=!1),Fe&&(Pe=!0),He&&(A=X({},tl),j=yc(null),He.html===!0&&(X(A,Yc),X(j,nl)),He.svg===!0&&(X(A,Xc),X(j,rl),X(j,al)),He.svgFilters===!0&&(X(A,Zc),X(j,rl),X(j,al)),He.mathMl===!0&&(X(A,$c),X(j,il),X(j,al))),we.tagCheck=null,we.attributeCheck=null,zc(e,`ADD_TAGS`)&&(typeof e.ADD_TAGS==`function`?we.tagCheck=e.ADD_TAGS:Oc(e.ADD_TAGS)&&(A===be&&(A=Gc(A)),X(A,e.ADD_TAGS,F))),zc(e,`ADD_ATTR`)&&(typeof e.ADD_ATTR==`function`?we.attributeCheck=e.ADD_ATTR:Oc(e.ADD_ATTR)&&(j===xe&&(j=Gc(j)),X(j,e.ADD_ATTR,F))),zc(e,`ADD_FORBID_CONTENTS`)&&Oc(e.ADD_FORBID_CONTENTS)&&(Ue===We&&(Ue=Gc(Ue)),X(Ue,e.ADD_FORBID_CONTENTS,F)),Be&&(A[`#text`]=!0),ke&&X(A,[`html`,`head`,`body`]),A.table&&(X(A,[`tbody`]),delete Ce.tbody),e.TRUSTED_TYPES_POLICY){if(typeof e.TRUSTED_TYPES_POLICY.createHTML!=`function`)throw Hc(`TRUSTED_TYPES_POLICY configuration option must provide a "createHTML" hook.`);if(typeof e.TRUSTED_TYPES_POLICY.createScriptURL!=`function`)throw Hc(`TRUSTED_TYPES_POLICY configuration option must provide a "createScriptURL" hook.`);let t=w;w=e.TRUSTED_TYPES_POLICY;try{te=E(``)}catch(e){throw w=t,e}}else e.TRUSTED_TYPES_POLICY===null?(w=void 0,te=``):(w===void 0&&(w=oe()),w&&typeof te==`string`&&(te=E(``)));J&&J(e),lt=e},pt=X({},[...Xc,...Zc,...Qc]),mt=X({},[...$c,...el]),ht=function(e,t,n){return t.namespaceURI===Ze?e===`svg`:t.namespaceURI===Ye?e===`svg`&&(n===`annotation-xml`||rt[n]):!!pt[e]},gt=function(e,t,n){return t.namespaceURI===Ze?e===`math`:t.namespaceURI===Xe?e===`math`&&at[n]:!!mt[e]},_t=function(e,t,n){return t.namespaceURI===Xe&&!at[n]||t.namespaceURI===Ye&&!rt[n]?!1:!mt[e]&&(ot[e]||!pt[e])},vt=function(e){let t=_(e);(!t||!t.tagName)&&(t={namespaceURI:Qe,tagName:`template`});let n=kc(e.tagName),r=kc(t.tagName);return et[e.namespaceURI]?e.namespaceURI===Xe?ht(n,t,r):e.namespaceURI===Ye?gt(n,t,r):e.namespaceURI===Ze?_t(n,t,r):!!(st===`application/xhtml+xml`&&et[e.namespaceURI]):!1},yt=function(e){Ec(t.removed,{element:e});try{_(e).removeChild(e)}catch{if(p(e),!_(e))throw Hc(`a node selected for removal could not be detached from its tree and cannot be safely returned; refusing to sanitize in place`)}},bt=function(e,t,n){try{m(e,t)}catch{try{e.removeAttribute(n)}catch{}}},xt=function(e){wt(e);let t=g(e);if(t){let e=[];Cc(t,t=>{Ec(e,t)}),Cc(e,e=>{try{p(e)}catch{}})}let n=y(e);if(n)for(let t=n.length-1;t>=0;--t){let r=n[t],i=r&&r.name;typeof i==`string`&&bt(e,r,i)}},St=function(e,n,r){if(!r)try{r=n.getAttributeNode(e)}catch{r=null}Ec(t.removed,{attribute:r||null,from:n});try{r?m(n,r):n.removeAttribute(e)}catch{try{n.removeAttribute(e)}catch{}}if(e===`is`){if(Pe||Fe)try{yt(n)}catch{}else try{n.setAttribute(e,``)}catch{}}},Ct=function(e){let t=y(e);if(t)for(let n=t.length-1;n>=0;--n){let r=t[n],i=r&&r.name;typeof i!=`string`||j[F(i)]||bt(e,r,i)}},wt=function(e){let t=[e];for(;t.length>0;){let e=t.pop();C(e)===bl.element&&Ct(e);let n=g(e);if(n)for(let e=n.length-1;e>=0;--e)t.push(n[e])}},Tt=function(e,t){return Oe?e===`patchsrc`||e===`for`&&t!==`label`&&t!==`output`:!1},Et=function(e){if(!Oe)return;let t=[e];for(;t.length>0;){let e=t.pop(),n=C(e);if(n===bl.processingInstruction||n===bl.comment&&Vc(_l,e.data)){try{p(e)}catch{}continue}if(n===bl.element){let t=e,n=F(ee(e));try{t.hasAttribute&&t.hasAttribute(`patchsrc`)&&t.removeAttribute(`patchsrc`),t.hasAttribute&&t.hasAttribute(`for`)&&Tt(`for`,n)&&t.removeAttribute(`for`)}catch{}}let r=g(e);if(r)for(let e=r.length-1;e>=0;--e)t.push(r[e])}},Dt=function(e){let t=null,r=null;if(Ne)e=`<remove></remove>`+e;else{let t=jc(e,/^[\r\n\t ]+/);r=t&&t[0]}st===`application/xhtml+xml`&&Qe===Ze&&(e=`<html xmlns="http://www.w3.org/1999/xhtml"><head></head><body>`+e+`</body></html>`);let i=w?E(e):e;if(Qe===Ze)try{t=new l().parseFromString(i,st)}catch{}if(!t||!t.documentElement){t=D.createDocument(Qe,`template`,null);try{t.documentElement.innerHTML=$e?te:i}catch{}}let a=t.body||t.documentElement;return e&&r&&a.insertBefore(n.createTextNode(r),a.childNodes[0]||null),Qe===Ze?ue.call(t,ke?`html`:`body`)[0]:ke?t.documentElement:a},Ot=function(e){let t=S?S(e):e.ownerDocument;return ce.call(t||e,e,c.SHOW_ELEMENT|c.SHOW_COMMENT|c.SHOW_TEXT|c.SHOW_PROCESSING_INSTRUCTION|c.SHOW_CDATA_SECTION,null)},kt=function(e){return e=Mc(e,fe,` `),e=Mc(e,pe,` `),e=Mc(e,me,` `),e},At=function(e){e.normalize();let t=S?S(e):e.ownerDocument,n=ce.call(t||e,e,c.SHOW_TEXT|c.SHOW_COMMENT|c.SHOW_CDATA_SECTION|c.SHOW_PROCESSING_INSTRUCTION,null),r=n.nextNode();for(;r;)r.data=kt(r.data),r=n.nextNode();let i=e.querySelectorAll?.call(e,`template`);i&&Cc(i,e=>{Mt(e.content)&&At(e.content)})},jt=function(e){let t=x?x(e):null;return typeof t!=`string`||F(t)!==`form`?!1:typeof e.nodeName!=`string`||typeof e.textContent!=`string`||typeof e.removeChild!=`function`||e.attributes!==y(e)||typeof e.removeAttribute!=`function`||typeof e.removeAttributeNode!=`function`||typeof e.getAttributeNode!=`function`||typeof e.setAttribute!=`function`||typeof e.namespaceURI!=`string`||typeof e.insertBefore!=`function`||typeof e.hasChildNodes!=`function`||e.nodeType!==b(e)||e.childNodes!==g(e)},Mt=function(e){if(!b||typeof e!=`object`||!e)return!1;try{return b(e)===bl.documentFragment}catch{return!1}},Nt=function(e){if(!b||typeof e!=`object`||!e)return!1;try{return typeof b(e)==`number`}catch{return!1}};function Pt(e,n,r){e.length!==0&&Cc(e,e=>{e.call(t,n,r,lt)})}let Ft=function(e,t){return!!(Oe&&e.hasChildNodes()&&!Nt(e.firstElementChild)&&Vc(gl,e.textContent)&&Vc(gl,e.innerHTML)||Oe&&e.namespaceURI===Ze&&Sl[t]&&(Nt(e.firstElementChild)||typeof e.textContent==`string`&&Vc(Cl[t],e.textContent))||e.nodeType===bl.processingInstruction||Oe&&e.nodeType===bl.comment&&Vc(_l,e.data))},It=function(e,t){return e instanceof RegExp?Vc(e,t):e instanceof Function&&!!e(t,...[...arguments].slice(2))},Lt=function(e,t,n){if(!Ce[t]&&I(t)&&It(Se.tagNameCheck,t))return!1;if(Be&&!Ue[t]){let t=_(e),r=g(e);if(r&&t){let i=r.length;for(let a=i-1;a>=0;--a){let i=e===n?f(r[a],!0):r[a];t.insertBefore(i,h(e))}}}return yt(e),!0},Rt=function(e,t,n,r){return e.length===0?t:t===n||t===r?Gc(t):t},zt=function(e,t){return e===t||_(e)!==null?!1:(Ve&&wt(e),!0)},Bt=function(e,n){if(Pt(O.beforeSanitizeElements,e,null),zt(e,n))return!0;if(jt(e))return yt(e),!0;let r=F(ee(e));if(A=Rt(O.uponSanitizeElement,A,be,je),Pt(O.uponSanitizeElement,e,{tagName:r,allowedTags:A}),zt(e,n))return!0;if(Ft(e,r))return yt(e),!0;if(Ce[r]||!(we.tagCheck instanceof Function&&we.tagCheck(r))&&!A[r]){let t=Lt(e,r,n);return t===!1&&(Pt(O.afterSanitizeElements,e,null),zt(e,n))?!0:t}if(C(e)===bl.element&&!vt(e)||(r===`noscript`||r===`noembed`||r===`noframes`)&&Vc(vl,e.innerHTML))return yt(e),!0;if(P&&e.nodeType===bl.text){let n=kt(e.textContent);e.textContent!==n&&(Ec(t.removed,{element:e.cloneNode()}),e.textContent=n)}return Pt(O.afterSanitizeElements,e,null),zt(e,n)},Vt=function(e,t,r){if(M[t]||Tt(t,e)||Le&&(t===`id`||t===`name`)&&(r in n||r in ut))return!1;let i=j[t]||we.attributeCheck instanceof Function&&we.attributeCheck(t,e);return N&&Vc(he,t)||Te&&Vc(k,t)?!0:i?qe[t]||Vc(ye,Mc(r,_e,``))||(t===`src`||t===`xlink:href`||t===`href`)&&e!==`script`&&Nc(r,`data:`)===0&&Ge[e]||Ee&&!Vc(ge,Mc(r,_e,``))?!0:!r:I(e)&&It(Se.tagNameCheck,e)&&It(Se.attributeNameCheck,t,e)||t===`is`&&Se.allowCustomizedBuiltInElements&&It(Se.tagNameCheck,r)},Ht=X({},[`annotation-xml`,`color-profile`,`font-face`,`font-face-format`,`font-face-name`,`font-face-src`,`font-face-uri`,`missing-glyph`]),I=function(e){return!Ht[kc(e)]&&Vc(ve,e)},Ut=function(e,t,n,r){if(w&&typeof u==`object`&&typeof u.getAttributeType==`function`&&!n)switch(u.getAttributeType(e,t)){case`TrustedHTML`:return E(r);case`TrustedScriptURL`:return ae(r)}return r},Wt=function(e,t,n,r){try{return n?e.setAttributeNS(n,t,r):e.setAttribute(t,r),!jt(e)||(yt(e),!1)}catch{return St(t,e),!1}},Gt=function(e,n){if(Pt(O.beforeSanitizeAttributes,e,null),zt(e,n))return;let r=e.attributes;if(!r||jt(e))return;j=Rt(O.uponSanitizeAttribute,j,xe,Me);let i={attrName:``,attrValue:``,keepAttr:!0,allowedAttributes:j,forceKeepAttr:void 0},a=r.length,o=F(e.nodeName);for(;a--;){let n=r[a],s=n.name,c=n.namespaceURI,l=n.value,u=F(s),d=l,f=s===`value`?d:Pc(d),p=!1;if(i.attrName=u,i.attrValue=f,i.keepAttr=!0,i.forceKeepAttr=void 0,Pt(O.uponSanitizeAttribute,e,i),f=i.attrValue,Re&&(u===`id`||u===`name`)&&Nc(f,ze)!==0&&(St(s,e,n),f=ze+f,p=!0),Oe&&Vc(/((--!?|])>)|<\/(style|script|title|xmp|textarea|noscript|iframe|noembed|noframes)/i,f)){St(s,e,n);continue}if(u===`attributename`&&jc(f,`href`)){St(s,e,n);continue}if(!i.forceKeepAttr){if(!i.keepAttr){St(s,e,n);continue}if(!De&&Vc(yl,f)){St(s,e,n);continue}if(P&&(f=kt(f)),!Vt(o,u,f)){St(s,e,n);continue}f=Ut(o,u,c,f),f!==d&&Wt(e,s,c,f)&&p&&Tc(t.removed)}}Pt(O.afterSanitizeAttributes,e,null),zt(e,n)},L=function(e){let t=null,n=Ot(e);for(Pt(O.beforeSanitizeShadowDOM,e,null);t=n.nextNode();)if(Pt(O.uponSanitizeShadowNode,t,null),Bt(t,e),Gt(t,e),Mt(t.content)&&L(t.content),C(t)===bl.element){let e=v(t);Mt(e)&&(Kt(e),L(e))}Pt(O.afterSanitizeShadowDOM,e,null)},Kt=function(e){let t=[{node:e,shadow:null}];for(;t.length>0;){let e=t.pop();if(e.shadow){L(e.shadow);continue}let n=e.node,r=C(n)===bl.element,i=g(n);if(i)for(let e=i.length-1;e>=0;--e)t.push({node:i[e],shadow:null});if(r){let e=x?x(n):null;if(typeof e==`string`&&F(e)===`template`){let e=n.content;Mt(e)&&t.push({node:e,shadow:null})}}if(r){let e=v(n);Mt(e)&&t.push({node:null,shadow:e},{node:e,shadow:null})}}};return t.sanitize=function(e){let n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},i=null,a=null,o=null,s=null;if($e=!e,$e&&(e=`<!-->`),typeof e!=`string`&&!Nt(e)&&(e=Kc(e),typeof e!=`string`))throw Hc(`dirty is not a string, aborting`);if(!t.isSupported)return e;Ae?(A=je,j=Me):ft(n),(O.uponSanitizeElement.length>0||O.uponSanitizeAttribute.length>0)&&(A=Gc(A)),O.uponSanitizeAttribute.length>0&&(j=Gc(j)),t.removed=[];let c=Ve&&typeof e!=`string`&&Nt(e);if(c){Et(e);let t=ee(e);if(typeof t==`string`){let n=F(t);if(!A[n]||Ce[n])throw xt(e),Hc(`root node is forbidden and cannot be sanitized in-place`)}if(jt(e))throw xt(e),Hc(`root node is clobbered and cannot be sanitized in-place`);try{Kt(e)}catch(t){throw xt(e),t}}else if(Nt(e))i=Dt(`<!---->`),a=i.ownerDocument.importNode(e,!0),a.nodeType===bl.element&&a.nodeName===`BODY`||a.nodeName===`HTML`?i=a:i.appendChild(a),Kt(i);else{if(!Pe&&!P&&!ke&&e.indexOf(`<`)===-1)return w&&Ie?E(e):e;if(i=Dt(e),!i)return Pe?null:Ie?te:``}i&&Ne&&yt(i.firstChild);let l=c?e:i;try{let e=Ot(l);for(;o=e.nextNode();)Bt(o,l),Gt(o,l),Mt(o.content)&&L(o.content)}catch(n){throw c&&(xt(e),Cc(t.removed,e=>{e.element&&wt(e.element)})),n}if(c){let n=!1;if(Cc(t.removed,t=>{t.element&&(t.element===e&&(n=!0),wt(t.element))}),n)throw Hc(`a node selected for removal could not be safely returned; refusing to sanitize in place`);return P&&At(e),e}if(Pe){if(P&&At(i),Fe)for(s=le.call(i.ownerDocument);i.firstChild;)s.appendChild(i.firstChild);else s=i;return(j.shadowroot||j.shadowrootmode)&&(s=de.call(r,s,!0)),s}let u=ke?i.outerHTML:i.innerHTML;return ke&&A[`!doctype`]&&i.ownerDocument&&i.ownerDocument.doctype&&i.ownerDocument.doctype.name&&Vc(ml,i.ownerDocument.doctype.name)&&(u=`<!DOCTYPE `+i.ownerDocument.doctype.name+`>
|
|
5
|
-
`+u),P&&(u=kt(u)),w&&Ie?E(u):u},t.setConfig=function(){let e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};ft(e),Ae=!0,je=A,Me=j},t.clearConfig=function(){lt=null,Ae=!1,je=null,Me=null,w=ne,te=``},t.isValidAttribute=function(e,t,n){lt||ft({});let r=F(e),i=F(t);return Vt(r,i,n)},t.addHook=function(e,t){typeof t==`function`&&
|
|
6
|
-
]`).replace(`lheading`,
|
|
7
|
-
`),n=t.length-1;for(;n>=0&&
|
|
8
|
-
`)}function
|
|
3
|
+
`))),e[go]=po(i);let a=r||i.props&&i.props.type===`number`;Za(e,t?`change`:`input`,t=>{t.target.composing||e[go](vo(e.value,n,a))}),(n||a)&&Za(e,`change`,()=>{e.value=vo(e.value,n,a)}),t||(Za(e,`compositionstart`,mo),Za(e,`compositionend`,ho),Za(e,`change`,ho))},mounted(e,{value:t,modifiers:{trim:n,number:r}}){let i=t??``,a=e[_o];delete e[_o],a!==void 0&&(e.type===`text`||e.type===`textarea`)&&e.value!==a?e[go](vo(e.value,n,r)):e.value=i},beforeUpdate(e,{value:t,oldValue:n,modifiers:{lazy:r,trim:i,number:a}},o){if(e[go]=po(o),e.composing)return;let s=(a||e.type===`number`)&&!/^0\d/.test(e.value)?le(e.value):e.value,c=t??``;if(s===c)return;let l=e.getRootNode();(l instanceof Document||l instanceof ShadowRoot)&&l.activeElement===e&&e.type!==`range`&&(r&&t===n||i&&e.value.trim()===c)||(e.value=c)}},bo={deep:!0,created(e,t,n){e[go]=po(n),Za(e,`change`,()=>{let t=e._modelValue,n=Eo(e),r=e.checked,i=e[go];if(f(t)){let e=Se(t,n),a=e!==-1;if(r&&!a)i(t.concat(n));else if(!r&&a){let n=[...t];n.splice(e,1),i(n)}}else if(m(t)){let e=new Set(t);r?e.add(n):e.delete(n),i(e)}else i(Do(e,r))})},mounted:xo,beforeUpdate(e,t,n){e[go]=po(n),xo(e,t,n)}};function xo(e,{value:t,oldValue:n},r){e._modelValue=t;let i;if(f(t))i=Se(t,r.props.value)>-1;else if(m(t))i=t.has(r.props.value);else{if(t===n)return;i=xe(t,Do(e,!0))}e.checked!==i&&(e.checked=i)}var So={created(e,{value:t},n){e.checked=xe(t,n.props.value),e[go]=po(n),Za(e,`change`,()=>{e[go](Eo(e))})},beforeUpdate(e,{value:t,oldValue:n},r){e[go]=po(r),t!==n&&(e.checked=xe(t,r.props.value))}},Co={deep:!0,created(e,{value:t,modifiers:{number:n}},r){e._modelValue=t,Za(e,`change`,()=>{let t=Array.prototype.filter.call(e.options,e=>e.selected).map(e=>n?le(Eo(e)):Eo(e)),r=e.multiple,i=r?m(e._modelValue)?new Set(t):t:t[0],a=e._pendingValue=[r,r?f(i)?t.slice():t:i];try{e[go](i)}finally{vn(()=>{e._pendingValue===a&&(e._pendingValue=void 0)})}}),e[go]=po(r)},mounted(e,{value:t}){To(e,t)},beforeUpdate(e,{value:t},n){e._modelValue=t,e[go]=po(n)},updated(e,{value:t}){let n=e._pendingValue;e._pendingValue=void 0,(!n||n[0]!==e.multiple||!wo(t,n[1],n[0]))&&To(e,t)}};function wo(e,t,n){if(!n||f(e))return xe(e,t);if(m(e)){if(e.size!==t.length)return!1;for(let n of t)if(!e.has(n))return!1;return!0}return!1}function To(e,t){let n=e.multiple,r=f(t);if(!n||r||m(t)){for(let i=0,a=e.options.length;i<a;i++){let a=e.options[i],o=Eo(a);if(n){if(r){let e=typeof o;a.selected=e===`string`||e===`number`?t.some(e=>String(e)===String(o)):Se(t,o)>-1}else a.selected=t.has(o)}else if(xe(Eo(a),t)){e.selectedIndex!==i&&(e.selectedIndex=i);return}}!n&&e.selectedIndex!==-1&&(e.selectedIndex=-1)}}function Eo(e){return`_value`in e?e._value:e.value}function Do(e,t){let n=t?`_trueValue`:`_falseValue`;return n in e?e[n]:t}var Oo={created(e,t,n){Ao(e,t,n,null,`created`)},mounted(e,t,n){Ao(e,t,n,null,`mounted`)},beforeUpdate(e,t,n,r){Ao(e,t,n,r,`beforeUpdate`)},updated(e,t,n,r){Ao(e,t,n,r,`updated`)}};function ko(e,t){switch(e){case`SELECT`:return Co;case`TEXTAREA`:return yo;default:switch(t){case`checkbox`:return bo;case`radio`:return So;default:return yo}}}function Ao(e,t,n,r,i){let a=ko(e.tagName,n.props&&n.props.type)[i];a&&a(e,t,n,r)}var jo=[`ctrl`,`shift`,`alt`,`meta`],Mo={stop:e=>e.stopPropagation(),prevent:e=>e.preventDefault(),self:e=>e.target!==e.currentTarget,ctrl:e=>!e.ctrlKey,shift:e=>!e.shiftKey,alt:e=>!e.altKey,meta:e=>!e.metaKey,left:e=>`button`in e&&e.button!==0,middle:e=>`button`in e&&e.button!==1,right:e=>`button`in e&&e.button!==2,exact:(e,t)=>jo.some(n=>e[`${n}Key`]&&!t.includes(n))},No=(e,t)=>{if(!e)return e;let n=e._withMods||={},r=t.join(`.`);return n[r]||(n[r]=((n,...r)=>{for(let e=0;e<t.length;e++){let r=Mo[t[e]];if(r&&r(n,t))return}return e(n,...r)}))},Po={esc:`escape`,space:` `,up:`arrow-up`,left:`arrow-left`,right:`arrow-right`,down:`arrow-down`,delete:`backspace`},Fo=(e,t)=>{let n=e._withKeys||={},r=t.join(`.`);return n[r]||(n[r]=(n=>{if(!(`key`in n))return;let r=E(n.key);if(t.some(e=>e===r||Po[e]===r))return e(n)}))},Io=c({patchProp:lo},Pa),Lo;function Ro(){return Lo||=Ti(Io)}var zo=((...e)=>{let t=Ro().createApp(...e),{mount:n}=t;return t.mount=e=>{let r=Vo(e);if(!r)return;let i=t._component;!g(i)&&!i.render&&!i.template&&(i.template=r.innerHTML),r.nodeType===1&&(r.textContent=``);let a=n(r,!1,Bo(r));return r instanceof Element&&(r.removeAttribute(`v-cloak`),r.setAttribute(`data-v-app`,``)),a},t});function Bo(e){if(e instanceof SVGElement)return`svg`;if(typeof MathMLElement==`function`&&e instanceof MathMLElement)return`mathml`}function Vo(e){return _(e)?document.querySelector(e):e}var Ho={"--font":`"Inter Variable", Inter, ui-sans-serif, system-ui, -apple-system, "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif`,"--mono":`"JetBrains Mono Variable", "JetBrains Mono", ui-monospace, SFMono-Regular, Menlo, Consolas, monospace`,"--fs":`13px`,"--fs-lg":`14px`,"--fs-sm":`12px`,"--fs-xs":`11px`,"--r-sm":`6px`,"--r":`8px`,"--r-lg":`12px`,"--r-xl":`16px`,"--h":`28px`,"--h-sm":`24px`,"--h-lg":`32px`,"--dur":`160ms`,"--ease":`cubic-bezier(0.16, 1, 0.3, 1)`,"--grad-size":`200% 100%`},Uo={"--base":`#fafafb`,"--bg":`#ffffff`,"--bg2":`#f4f4f5`,"--bg3":`#e9e9ec`,"--fg":`#18181b`,"--fg2":`#52525b`,"--fg3":`#a1a1aa`,"--line":`#e5e5e8`,"--line2":`#eeeef0`,"--line-strong":`#d4d4d8`,"--accent":`#7b61ff`,"--accent-hover":`#6a4ff0`,"--accent-2":`#4f46e5`,"--accent-fg":`#ffffff`,"--accent-soft":`#eef0ff`,"--agent":`#0ea5c6`,"--agent-soft":`rgba(14, 165, 198, 0.12)`,"--ok":`#16a34a`,"--ok-bg":`#dcfce7`,"--warn":`#d97706`,"--warn-bg":`#fef3c7`,"--err":`#dc2626`,"--err-bg":`#fef2f2`,"--info":`#2563eb`,"--user-bg":`#f3f1ff`,"--user-line":`rgba(123, 97, 255, 0.3)`,"--code-bg":`#f4f4f5`,"--mask":`rgba(15, 15, 20, 0.35)`,"--shadow":`0 8px 28px rgba(16, 24, 40, 0.14)`,"--shadow-sm":`0 1px 2px rgba(16, 24, 40, 0.06), 0 1px 2px rgba(16, 24, 40, 0.04)`,"--shadow-pop":`0 2px 10px rgba(26, 35, 50, 0.12)`,"--focus":`0 0 0 3px rgba(123, 97, 255, 0.2)`,"--grad":`linear-gradient(90deg, #6d28d9 0%, #7b61ff 30%, #6366f1 55%, #4f46e5 75%, #7b61ff 100%)`},Wo={"--base":`#0a0a0b`,"--bg":`#141417`,"--bg2":`#1c1c21`,"--bg3":`#26262c`,"--fg":`#ededf0`,"--fg2":`#a1a1aa`,"--fg3":`#6e6e78`,"--line":`#26262b`,"--line2":`#202025`,"--line-strong":`#36363e`,"--accent":`#7b61ff`,"--accent-hover":`#8f78ff`,"--accent-2":`#818cf8`,"--accent-fg":`#ffffff`,"--accent-soft":`#1f1f36`,"--agent":`#22d3ee`,"--agent-soft":`rgba(34, 211, 238, 0.14)`,"--ok":`#34d399`,"--ok-bg":`rgba(52, 211, 153, 0.12)`,"--warn":`#fbbf24`,"--warn-bg":`rgba(251, 191, 36, 0.12)`,"--err":`#f87171`,"--err-bg":`rgba(220, 38, 38, 0.12)`,"--info":`#60a5fa`,"--user-bg":`#1f1f36`,"--user-line":`rgba(123, 97, 255, 0.35)`,"--code-bg":`#0a0a0b`,"--mask":`rgba(0, 0, 0, 0.55)`,"--shadow":`0 8px 28px rgba(0, 0, 0, 0.55)`,"--shadow-sm":`0 1px 2px rgba(0, 0, 0, 0.4), 0 1px 3px rgba(0, 0, 0, 0.25)`,"--shadow-pop":`0 4px 16px rgba(0, 0, 0, 0.5)`,"--focus":`0 0 0 3px rgba(123, 97, 255, 0.3)`,"--grad":`linear-gradient(90deg, #7b61ff 0%, #818cf8 35%, #6366f1 55%, #7b61ff 75%, #a78bfa 100%)`},Go=e=>Object.entries(e).map(([e,t])=>`${e}: ${t};`).join(` `);function Ko(e,t){return`${e} { ${Go(Ho)} ${Go(Uo)} color-scheme: light; }\n${t} { ${Go(Wo)} color-scheme: dark; }\n`}function qo(){let e=document.createElement(`style`);e.textContent=Ko(`:root`,`:root[data-theme='dark']`),document.head.prepend(e)}function Jo(){try{let e=localStorage.getItem(`ph:theme`);if(e===`dark`||e===`light`)return e}catch{}return`light`}var Yo=Kt(Jo());Ln(()=>{document.documentElement.dataset.theme=Yo.value;try{localStorage.setItem(`ph:theme`,Yo.value)}catch{}});var Xo={claude:`M4.709 15.955l4.72-2.647.08-.23-.08-.128H9.2l-.79-.048-2.698-.073-2.339-.097-2.266-.122-.571-.121L0 11.784l.055-.352.48-.321.686.06 1.52.103 2.278.158 1.652.097 2.449.255h.389l.055-.157-.134-.098-.103-.097-2.358-1.596-2.552-1.688-1.336-.972-.724-.491-.364-.462-.158-1.008.656-.722.881.06.225.061.893.686 1.908 1.476 2.491 1.833.365.304.145-.103.019-.073-.164-.274-1.355-2.446-1.446-2.49-.644-1.032-.17-.619a2.97 2.97 0 01-.104-.729L6.283.134 6.696 0l.996.134.42.364.62 1.414 1.002 2.229 1.555 3.03.456.898.243.832.091.255h.158V9.01l.128-1.706.237-2.095.23-2.695.08-.76.376-.91.747-.492.584.28.48.685-.067.444-.286 1.851-.559 2.903-.364 1.942h.212l.243-.242.985-1.306 1.652-2.064.73-.82.85-.904.547-.431h1.033l.76 1.129-.34 1.166-1.064 1.347-.881 1.142-1.264 1.7-.79 1.36.073.11.188-.02 2.856-.606 1.543-.28 1.841-.315.833.388.091.395-.328.807-1.969.486-2.309.462-3.439.813-.042.03.049.061 1.549.146.662.036h1.622l3.02.225.79.522.474.638-.079.485-1.215.62-1.64-.389-3.829-.91-1.312-.329h-.182v.11l1.093 1.068 2.006 1.81 2.509 2.33.127.578-.322.455-.34-.049-2.205-1.657-.851-.747-1.926-1.62h-.128v.17l.444.649 2.345 3.521.122 1.08-.17.353-.608.213-.668-.122-1.374-1.925-1.415-2.167-1.143-1.943-.14.08-.674 7.254-.316.37-.729.28-.607-.461-.322-.747.322-1.476.389-1.924.315-1.53.286-1.9.17-.632-.012-.042-.14.018-1.434 1.967-2.18 2.945-1.726 1.845-.414.164-.717-.37.067-.662.401-.589 2.388-3.036 1.44-1.882.93-1.086-.006-.158h-.055L4.132 18.56l-1.13.146-.487-.456.061-.746.231-.243 1.908-1.312-.006.006z`,codex:`M8.086.457a6.105 6.105 0 013.046-.415c1.333.153 2.521.72 3.564 1.7a.117.117 0 00.107.029c1.408-.346 2.762-.224 4.061.366l.063.03.154.076c1.357.703 2.33 1.77 2.918 3.198.278.679.418 1.388.421 2.126a5.655 5.655 0 01-.18 1.631.167.167 0 00.04.155 5.982 5.982 0 011.578 2.891c.385 1.901-.01 3.615-1.183 5.14l-.182.22a6.063 6.063 0 01-2.934 1.851.162.162 0 00-.108.102c-.255.736-.511 1.364-.987 1.992-1.199 1.582-2.962 2.462-4.948 2.451-1.583-.008-2.986-.587-4.21-1.736a.145.145 0 00-.14-.032c-.518.167-1.04.191-1.604.185a5.924 5.924 0 01-2.595-.622 6.058 6.058 0 01-2.146-1.781c-.203-.269-.404-.522-.551-.821a7.74 7.74 0 01-.495-1.283 6.11 6.11 0 01-.017-3.064.166.166 0 00.008-.074.115.115 0 00-.037-.064 5.958 5.958 0 01-1.38-2.202 5.196 5.196 0 01-.333-1.589 6.915 6.915 0 01.188-2.132c.45-1.484 1.309-2.648 2.577-3.493.282-.188.55-.334.802-.438.286-.12.573-.22.861-.304a.129.129 0 00.087-.087A6.016 6.016 0 015.635 2.31C6.315 1.464 7.132.846 8.086.457zm-.804 7.85a.848.848 0 00-1.473.842l1.694 2.965-1.688 2.848a.849.849 0 001.46.864l1.94-3.272a.849.849 0 00.007-.854l-1.94-3.393zm5.446 6.24a.849.849 0 000 1.695h4.848a.849.849 0 000-1.696h-4.848z`,cursor:`M22.106 5.68L12.5.135a.998.998 0 00-.998 0L1.893 5.68a.84.84 0 00-.419.726v11.186c0 .3.16.577.42.727l9.607 5.547a.999.999 0 00.998 0l9.608-5.547a.84.84 0 00.42-.727V6.407a.84.84 0 00-.42-.726zm-.603 1.176L12.228 22.92c-.063.108-.228.064-.228-.061V12.34a.59.59 0 00-.295-.51l-9.11-5.26c-.107-.062-.063-.228.062-.228h18.55c.264 0 .428.286.296.514z`,codebuddy:`M18.777 1.647c.28-.02.536.114.972.51 1.018.926 2.437 2.828 3.318 4.452l.34.631.482.24.11.06v3.638a5.206 5.206 0 00-5.32-1.23c-.491.166-1.021.471-2.08 1.082l-6.09 3.516c-1.057.61-1.586.916-1.975 1.259a5.208 5.208 0 00-1.493 5.572c.165.49.471 1.02 1.082 2.08l.315.543h-3.26c-.685 0-1.34-.135-1.939-.377-.169-.956-.009-1.789.469-2.335.158-.18.164-.189.13-.493a11.846 11.846 0 01-.057-1.711l.02-.444-.667-1.18C2.1 15.622 1.445 14.078 1.192 12.9c-.133-.647-.125-.934.04-1.146.1-.128.427-.261.822-.334.994-.175 3.162-.017 5.575.41l.25.043.551-.487c.915-.81 1.522-1.264 2.641-1.962 1.167-.73 2.484-1.331 3.967-1.807l.476-.152.261-.688c.937-2.471 1.896-4.293 2.58-4.9.235-.21.25-.22.422-.23z M12.139 18.2a1.203 1.203 0 011.642.44l1.296 2.243a1.204 1.204 0 01-2.083 1.203l-1.296-2.243a1.203 1.203 0 01.44-1.644zM18.629 14.452a1.203 1.203 0 011.642.44l1.295 2.244a1.203 1.203 0 11-2.083 1.203l-1.295-2.243a1.203 1.203 0 01.44-1.644z`,opencode:`M16 6H8v12h8V6zm4 16H4V2h16v20z`},Zo={claude:{short:`Claude`,color:`#d97757`,logo:Xo.claude,install:`npm i -g @anthropic-ai/claude-code`},codex:{short:`Codex`,color:`#4f5bff`,logo:Xo.codex,install:`npm i -g @openai/codex`},cursor:{short:`Cursor`,color:`var(--fg)`,logo:Xo.cursor,install:`curl https://cursor.com/install -fsS | bash`},codebuddy:{short:`CodeBuddy`,color:`#6c4dff`,logo:Xo.codebuddy,install:`npm i -g @tencent-ai/codebuddy-code`},opencode:{short:`OpenCode`,color:`var(--fg)`,logo:Xo.opencode,install:`npm i -g opencode-ai`},fake:{short:`Test`,color:`#0ea5c6`,glyph:`M9 3h6M10 3v6l-5 9a2 2 0 0 0 1.8 3h10.4a2 2 0 0 0 1.8-3l-5-9V3M7.5 15h9`}},Qo={short:``,color:`#8b8b96`,glyph:`M5 7h14v10H5zM9 11h.01M15 11h.01M10 17v3M14 17v3`};function $o(e){let t=Zo[e]??Qo;return t.short?t:{...t,short:e}}var es=[`claude`,`codex`,`cursor`,`codebuddy`,`opencode`];function ts(e){let t=e=>e===`fake`?es.length+1:es.includes(e)?es.indexOf(e):es.length;return[...e].sort((e,n)=>t(e.id)-t(n.id))}var ns=[`data-agent-badge`],rs={key:0,class:`logo`,viewBox:`0 0 24 24`,fill:`currentColor`,"fill-rule":`evenodd`,"clip-rule":`evenodd`},is=[`d`],as={key:1,viewBox:`0 0 24 24`,fill:`none`,stroke:`currentColor`,"stroke-width":`2.2`,"stroke-linecap":`round`,"stroke-linejoin":`round`},os=[`d`],ss=Jn({__name:`AgentBadge`,props:{id:{},size:{},off:{type:Boolean}},setup(e){let t=e,n=G(()=>$o(t.id));return(t,r)=>(B(),V(`span`,{class:k([`ab`,[e.size??`sm`,{off:e.off}]]),style:O({"--ab":n.value.color}),"data-agent-badge":e.id,"aria-hidden":`true`},[n.value.logo?(B(),V(`svg`,rs,[H(`path`,{d:n.value.logo},null,8,is)])):(B(),V(`svg`,as,[H(`path`,{d:n.value.glyph},null,8,os)]))],14,ns))}}),cs=(e,t)=>{let n=e.__vccOpts||e;for(let[e,r]of t)n[e]=r;return n},ls=cs(ss,[[`__scopeId`,`data-v-f49720be`]]),us={viewBox:`0 0 24 24`,fill:`none`,stroke:`currentColor`,"stroke-width":`2`,"stroke-linecap":`round`,"stroke-linejoin":`round`,"aria-hidden":`true`},ds=[`d`],K=Jn({__name:`Icon`,props:{name:{}},setup(e){let t={plus:`M12 5v14M5 12h14`,gear:`M12 15a3 3 0 1 0 0-6 3 3 0 0 0 0 6zM19.4 15a1.7 1.7 0 0 0 .3 1.8l.1.1a2 2 0 1 1-2.8 2.8l-.1-.1a1.7 1.7 0 0 0-1.8-.3 1.7 1.7 0 0 0-1 1.5V21a2 2 0 1 1-4 0v-.1a1.7 1.7 0 0 0-1.1-1.5 1.7 1.7 0 0 0-1.8.3l-.1.1a2 2 0 1 1-2.8-2.8l.1-.1a1.7 1.7 0 0 0 .3-1.8 1.7 1.7 0 0 0-1.5-1H3a2 2 0 1 1 0-4h.1a1.7 1.7 0 0 0 1.5-1.1 1.7 1.7 0 0 0-.3-1.8l-.1-.1a2 2 0 1 1 2.8-2.8l.1.1a1.7 1.7 0 0 0 1.8.3H9a1.7 1.7 0 0 0 1-1.5V3a2 2 0 1 1 4 0v.1a1.7 1.7 0 0 0 1 1.5 1.7 1.7 0 0 0 1.8-.3l.1-.1a2 2 0 1 1 2.8 2.8l-.1.1a1.7 1.7 0 0 0-.3 1.8V9a1.7 1.7 0 0 0 1.5 1H21a2 2 0 1 1 0 4h-.1a1.7 1.7 0 0 0-1.5 1z`,clip:`M21.4 11.1l-9.2 9.2a6 6 0 0 1-8.5-8.5l9.2-9.2a4 4 0 0 1 5.7 5.7l-9.2 9.2a2 2 0 0 1-2.8-2.8l8.5-8.5`,send:`M22 2L11 13M22 2l-7 20-4-9-9-4 20-7z`,stop:`M6 6h12v12H6z`,x:`M6 6l12 12M18 6L6 18`,chevron:`M6 9l6 6 6-6`,right:`M9 6l6 6-6 6`,left:`M15 6l-6 6 6 6`,down:`M12 5v14M5 12l7 7 7-7`,edit:`M12 20h9M16.5 3.5a2.1 2.1 0 0 1 3 3L7 19l-4 1 1-4z`,undo:`M3 7v6h6M21 17a9 9 0 0 0-15-6.7L3 13`,reset:`M1 4v6h6M3.5 15a9 9 0 1 0 2.1-9.4L1 10`,zap:`M13 2L3 14h9l-1 8 10-12h-9l1-8z`,grip:`M9 5h.01M9 12h.01M9 19h.01M15 5h.01M15 12h.01M15 19h.01`,tool:`M14.7 6.3a1 1 0 0 0 0 1.4l1.6 1.6a1 1 0 0 0 1.4 0l3.8-3.8a6 6 0 0 1-7.9 7.9l-6.9 6.9a2.1 2.1 0 0 1-3-3l6.9-6.9a6 6 0 0 1 7.9-7.9z`,file:`M14 2H6a2 2 0 0 0-2 2v16a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V8zM14 2v6h6`,image:`M3 3h18v18H3zM8.5 10a1.5 1.5 0 1 0 0-3 1.5 1.5 0 0 0 0 3zM21 15l-5-5L5 21`,target:`M12 22a10 10 0 1 0 0-20 10 10 0 0 0 0 20zM12 18a6 6 0 1 0 0-12 6 6 0 0 0 0 12zM12 14a2 2 0 1 0 0-4 2 2 0 0 0 0 4z`,pen:`M12 19l7-7 3 3-7 7zM18 13l-1.5-7.5L2 2l3.5 14.5L13 18zM2 2l7.6 7.6`,check:`M20 6L9 17l-5-5`,copy:`M9 9h11v11H9zM5 15H4a1 1 0 0 1-1-1V4a1 1 0 0 1 1-1h10a1 1 0 0 1 1 1v1`,download:`M21 15v4a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2v-4M7 10l5 5 5-5M12 15V3`,zoom:`M15 3h6v6M9 21H3v-6M21 3l-7 7M3 21l7-7`,monitor:`M2 3h20v14H2zM8 21h8M12 17v4`,phone:`M7 2h10v20H7zM12 18h.01`,history:`M3 3v5h5M3.05 13A9 9 0 1 0 6 5.3L3 8M12 7v5l4 2`,sparkle:`M12 3l1.9 5.8L20 11l-6.1 2.2L12 19l-1.9-5.8L4 11l6.1-2.2z`,refresh:`M23 4v6h-6M1 20v-6h6M3.5 9a9 9 0 0 1 14.9-3.4L23 10M1 14l4.6 4.4A9 9 0 0 0 20.5 15`,trash:`M3 6h18M8 6V4h8v2M19 6l-1 14H6L5 6`,search:`M11 19a8 8 0 1 0 0-16 8 8 0 0 0 0 16zM21 21l-4.3-4.3`,external:`M18 13v6a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2V8a2 2 0 0 1 2-2h6M15 3h6v6M10 14L21 3`,sun:`M12 17a5 5 0 1 0 0-10 5 5 0 0 0 0 10zM12 1v2M12 21v2M4.2 4.2l1.4 1.4M18.4 18.4l1.4 1.4M1 12h2M21 12h2M4.2 19.8l1.4-1.4M18.4 5.6l1.4-1.4`,robot:`M12 8V4H8M4 8h16v12H4zM2 14h2M20 14h2M15 13v2M9 13v2`,chat:`M21 15a2 2 0 0 1-2 2H7l-4 4V5a2 2 0 0 1 2-2h14a2 2 0 0 1 2 2z`,chevrons:`M7 13l5 5 5-5M7 6l5 5 5-5`,alert:`M12 22a10 10 0 1 0 0-20 10 10 0 0 0 0 20zM12 8v4M12 16h.01`,cpu:`M5 5h14v14H5zM9 9h6v6H9zM9 2v3M15 2v3M9 19v3M15 19v3M19 9h3M19 14h3M2 9h3M2 14h3`,moon:`M21 12.8A9 9 0 1 1 11.2 3a7 7 0 0 0 9.8 9.8z`};return(n,r)=>(B(),V(`svg`,us,[H(`path`,{d:t[e.name]??``},null,8,ds)]))}});function fs(e,t){if(t.t===`turn_begin`)return e.some(e=>e.id===t.turnId)||e.push({id:t.turnId,ts:t.ts,user:t.user,agent:t.agent,model:t.model,items:[],status:`running`,files:[],artifacts:[],lastSeq:t.seq}),e;let n=ps(e,t.turnId);if(!n||t.seq<=n.lastSeq&&t.seq!==0)return e;n.lastSeq=t.seq;let r=n.items[n.items.length-1];switch(t.t){case`text`:case`thinking`:{let e=t.t;r&&r.kind===e?r.text+=t.delta:n.items.push({kind:e,text:t.delta});break}case`tool`:{let e=n.items.find(e=>e.kind===`tool`&&e.id===t.id);e?(e.status=t.status,t.input!==void 0&&(e.input=t.input),t.output!==void 0&&(e.output=t.output),t.name&&e.name!==t.name&&(e.name=t.name)):n.items.push({kind:`tool`,id:t.id,name:t.name,input:t.input,status:t.status,output:t.output});for(let e of t.files??[])n.files.includes(e)||n.files.push(e);break}case`ask`:n.items.push({kind:`ask`,askId:t.askId,spec:t.spec});break;case`ask_answer`:{let e=n.items.find(e=>e.kind===`ask`&&e.askId===t.askId);e&&(e.answer=t.answer);break}case`artifact`:n.artifacts.push({name:t.name,version:t.version});break;case`notice`:n.items.push({kind:`notice`,level:t.level,message:t.message});break;case`error`:n.items.push({kind:`error`,message:t.message});break;case`turn_end`:n.status=t.status,n.endTs=t.ts,n.usage=t.usage,n.durationMs=t.durationMs,n.message=t.message}return e}function ps(e,t){for(let n=e.length-1;n>=0;n--)if(e[n].id===t)return e[n]}function ms(e){return e.status!==`running`&&!e.items.some(e=>e.kind===`text`&&e.text.trim()||e.kind===`tool`||e.kind===`ask`||e.kind===`error`)}var hs=class extends Error{status;constructor(e,t){super(t),this.status=e}};async function gs(e,t,n,r){let i={};e!==`GET`&&(i[`X-PH`]=`1`),n!==void 0&&(i[`Content-Type`]=`application/json`);let a=await fetch(`/__ph/api/${t}`,{method:e,headers:i,body:r??(n===void 0?void 0:JSON.stringify(n)),credentials:`same-origin`}),o=(a.headers.get(`content-type`)??``).includes(`json`)?await a.json():await a.text();if(!a.ok)throw new hs(a.status,(o&&typeof o==`object`&&`error`in o?String(o.error):String(o))||a.statusText);return o}var _s={get:e=>gs(`GET`,e),post:(e,t)=>gs(`POST`,e,t??{}),patch:(e,t)=>gs(`PATCH`,e,t),del:e=>gs(`DELETE`,e),upload:(e,t)=>gs(`POST`,`uploads?name=${encodeURIComponent(t)}&mime=${encodeURIComponent(e.type||`application/octet-stream`)}`,void 0,e)},vs=(e,t,n=!1)=>`/__ph/api/artifacts/${encodeURIComponent(e)}/raw${t?`?v=${t}`:``}${n?`${t?`&`:`?`}download`:``}`,ys=e=>`/__ph/api/uploads/${encodeURIComponent(e)}`,bs={connecting:`正在连接…`,ready:`已就绪`,netError:`网络错误,正在重试…`,retryNow:`立即重试`,newChat:`新对话`,untitled:`未命名对话`,rename:`改名`,delete:`删除`,confirmDelete:`删除这个对话及其记录?`,history:`聊天记录`,agent:`Agent`,model:`模型`,defaultModel:`默认模型`,notInstalled:`未安装`,agentMissing:`{agent} 未安装。装好后重启 page-harness:`,agentPathHint:`已经装了?启动时用 {flag} 指定路径。`,agentMissingNoCmd:`{agent} 未安装。`,settings:`页面协作设置`,allowControl:`允许 Agent 操作此页面`,controlPrivacy:`Agent 可以读取当前页面的内容(密码框除外)并点击、输入、滚动。数据只在本机与 Agent CLI 之间传递。`,status_online:`在线`,status_transferred:`已转到其它标签页`,status_paused:`已暂停(页面在后台)`,status_offline:`离线`,status_disabled:`未开启`,status_unsupported:`页面脚本版本过旧,请刷新页面`,liveToggle:`页面候选(Live)`,liveDesc:`在页面上选中元素后可让 Agent 直接生成 2–4 个候选,原位切换、并排挑选、采用或放弃。`,reviewerTitle:`页面评审`,reviewerNameLabel:`你的名字(显示在你的意见上)`,reviewerNamePh:`例如:小王 / 设计`,reviewerJoin:`开始评审`,reviewerRole:`评审成员`,reviewerStats:`未解决 {open} 条 · 我写的 {mine} 条`,reviewerHowComment:`点底栏「取点」,选中页面上的元素后点「评论」,留下意见。`,reviewerHowEdit:`选中元素后点「编辑」可以直接改元素的文字、颜色、字号、间距或图片,大家都能看到效果,也能切回原版对比。`,reviewerHowThread:`点页面上的图钉可以回复、标记已解决。`,reviewerHowApprove:`在意见列表里对当前页面点「通过」或「需修改」。`,reviewerLimits:`你看到的修改只存在于这次评审里,不会改动线上网站;对话和 Agent 仅发起人可用。`,teamTitle:`团队评审`,myName:`你的名字(显示在意见上)`,teamShareDesc:`把这个链接发给同一网络里的同事,他们打开后以评审身份加入:能评论、回复、审批和改文字样式,不能使用 Agent。`,teamNoShare:`启动时加上 --share,就能生成邀请链接,让同事一起评审这个页面。`,copyLink:`复制链接`,liveReviewDesc:`这个页面没有源码(评审模式):候选以页面修改的形式出现(文字、样式、图片,可以同时改多个元素),原位切换,采用后存为修改意见。`,reviewEmptyTitle:`想对这个页面提点什么意见?`,reviewEmptyHint:`没有源码时,Agent 会在页面上直接做临时修改、或钉一条批注,不会生成 HTML 原型。用「取点」选中元素可以引用、评论、编辑或要 Live 候选;「意见」里查看全部并导出。`,language:`语言`,placeholder:`描述你想在页面上改什么…`,placeholderBusy:`Agent 正在工作,新消息会排队…`,send:`发送回复`,stop:`停止`,attach:`添加附件`,removeDraft:`移除`,queue:`待发送`,edit:`编辑`,withdraw:`撤回`,dragToReorder:`拖动排序`,thinking:`思考中…`,thoughts:`思考过程`,writing:`输出中`,done:`已完成`,cancelled:`已停止`,interrupted:`已中断`,failed:`失败`,emptyReply:`空回复:Agent 没有输出内容`,retry:`重试`,rateLimited:`Agent 触发了限流或额度不足,请稍后重试。`,changedFiles:`改动的文件`,artifacts:`产物`,tool:`工具`,input:`入参`,output:`输出`,running:`运行中`,backToBottom:`有新消息`,loadOlder:`加载更早的记录`,noMore:`没有更早的记录了`,emptyChat:`在页面上取点,或直接描述你想改什么。`,you:`你`,me:`我`,toolsUsed:`调用了 {n} 个工具`,thoughtInterrupted:`思考已中断`,enterHint:`Enter 发送 · Shift+Enter 换行`,headerLine:`{agent} · {n} 轮对话`,newCount:`{n} 条新消息`,emptyTitle:`想在这个页面上改点什么?`,emptyHint:`用「取点」选中元素、「修改」生成候选,或直接描述需求。产物会出现在「产物」里。`,searchModels:`搜索模型…`,defaultAuto:`默认(由 Agent 决定)`,useCustom:`使用 “{id}”`,modelsFailed:`没能读取模型列表,可以直接输入模型 id`,noModels:`没有匹配的模型`,loadingModels:`正在读取模型…`,groupOther:`其他`,agentVersion:`版本 {v}`,effort:`思考强度`,effortDefault:`默认`,effortReset:`恢复默认({v})`,fastMode:`快速模式`,fastSpeed:`{n} 倍速度`,fastUsage:`用量更多`,fastShort:`快速`,effortNames:{none:`无`,minimal:`最低`,low:`低`,medium:`中`,high:`高`,xhigh:`超高`,max:`最高`,ultra:`极致`},picks:`取点`,marks:`批注`,files:`附件`,question:`问题`,other:`其他`,otherPlaceholder:`自己填写…`,recommended:`推荐`,skip:`跳过`,next:`下一题`,prev:`上一题`,submit:`提交`,skipped:`已跳过`,answerTimeout:`未作答(超时)`,answerCancelled:`已取消`,required:`必填`,liveActive:`{n} 个候选进行中`,discardAll:`全部放弃({n})`,discardAllHint:`放弃所有未采用的候选,并还原页面上的候选改动`,confirmDiscardAll:`放弃 {n} 个候选?页面上的候选改动会被还原,进行中的生成会停止。`,clearFailed:`清除失败({n})`,clearFailedHint:`只移除失败的候选,其他候选不受影响`,inplace:`原位切换`,compare:`并排对比`,accept:`采用`,discard:`放弃`,retryAccept:`重试并采用`,live_generating:`生成中`,live_refining:`细化中`,live_accepting:`采用中`,live_discarding:`放弃中`,live_ready:`可挑选`,live_failed:`失败`,live_accepted:`已采用`,live_discarded:`已放弃`,allArtifacts:`全部产物`,noArtifacts:`还没有产物。Agent 写入的方案、报告、原型会出现在这里。`,new:`新`,updated:`已更新`,version:`版本`,readOnly:`历史版本(只读)`,desktop:`桌面`,mobile:`手机`,zoom:`放大`,copy:`复制`,copied:`已复制`,download:`下载`,exportPng:`导出 PNG`,exportPdf:`导出 PDF`,structured:`结构化`,raw:`原始`,loadFailed:`加载失败`,close:`关闭`,binary:`二进制文件,无法预览`,search:`搜索聊天记录…`,noChats:`还没有对话`,turns:`{n} 轮`,continueInPanel:`在面板中继续`,continueHint:`已设为面板的当前对话,回到页面打开对话即可继续。`,exportMd:`导出 Markdown`,results:`{n} 条结果`,noResults:`没有匹配的记录`,duration:`耗时`,tokens:`tokens`,selectChat:`选择左侧的对话查看记录`,justNow:`刚刚`,minutesAgo:`{n} 分钟前`,hoursAgo:`{n} 小时前`,daysAgo:`{n} 天前`},xs={connecting:`Connecting…`,ready:`Ready`,netError:`Network error, retrying…`,retryNow:`Retry now`,newChat:`New chat`,untitled:`Untitled chat`,rename:`Rename`,delete:`Delete`,confirmDelete:`Delete this chat and its history?`,history:`History`,agent:`Agent`,model:`Model`,defaultModel:`Default model`,notInstalled:`not installed`,agentMissing:`{agent} is not installed. Install it, then restart page-harness:`,agentPathHint:`Already installed? Pass {flag} when starting.`,agentMissingNoCmd:`{agent} is not installed.`,settings:`Page collaboration`,allowControl:`Allow the agent to operate this page`,controlPrivacy:`The agent can read this page (except password fields) and click, type and scroll. Data only travels between this machine and the agent CLI.`,status_online:`Online`,status_transferred:`Moved to another tab`,status_paused:`Paused (page in background)`,status_offline:`Offline`,status_disabled:`Off`,status_unsupported:`Page script is outdated, reload the page`,liveToggle:`Page candidates (Live)`,liveDesc:`Select an element on the page and the agent renders 2–4 candidates right there: switch in place, compare side by side, accept or discard.`,reviewerTitle:`Page review`,reviewerNameLabel:`Your name (shown on your notes)`,reviewerNamePh:`e.g. Alex / Design`,reviewerJoin:`Start reviewing`,reviewerRole:`Reviewer`,reviewerStats:`{open} open · {mine} by you`,reviewerHowComment:`Click Pick in the dock, choose an element on the page, then Comment.`,reviewerHowEdit:`After picking, Edit changes an element's text, color, size, spacing or image so everyone sees it; compare with the original any time.`,reviewerHowThread:`Click a pin to reply or mark it resolved.`,reviewerHowApprove:`In the Notes list, approve the current page or request changes.`,reviewerLimits:`Changes exist only in this review; the live site is never touched. Chat and the agent are for the host only.`,teamTitle:`Team review`,myName:`Your name (shown on notes)`,teamShareDesc:`Send this link to teammates on your network. They join as reviewers: comment, reply, approve and edit text/style, but cannot use the agent.`,teamNoShare:`Start with --share to get an invite link so teammates can review this page with you.`,copyLink:`Copy link`,liveReviewDesc:`No source for this page (review mode): candidates are page changes (text, styles, images, possibly several elements), switched in place; accepting saves them as changes in Notes.`,reviewEmptyTitle:`What would you like reviewed on this page?`,reviewEmptyHint:`Without source, the agent changes the page in place or pins a note on it; no HTML mockups. Pick an element to quote, comment, edit or ask for Live candidates; Notes lists everything and exports it.`,language:`Language`,placeholder:`Describe what to change on this page…`,placeholderBusy:`The agent is working; new messages are queued…`,send:`Send`,stop:`Stop`,attach:`Attach files`,removeDraft:`Remove`,queue:`Queued`,edit:`Edit`,withdraw:`Withdraw`,dragToReorder:`Drag to reorder`,thinking:`Thinking…`,thoughts:`Thoughts`,writing:`Writing`,done:`Done`,cancelled:`Stopped`,interrupted:`Interrupted`,failed:`Failed`,emptyReply:`Empty reply: the agent produced no output`,retry:`Retry`,rateLimited:`The agent hit a rate limit or ran out of quota. Try again later.`,changedFiles:`Changed files`,artifacts:`Artifacts`,tool:`Tool`,input:`Input`,output:`Output`,running:`Running`,backToBottom:`New messages`,loadOlder:`Load earlier messages`,noMore:`No earlier messages`,emptyChat:`Pick something on the page, or just describe what to change.`,you:`You`,me:`Me`,toolsUsed:`Used {n} tool|Used {n} tools`,thoughtInterrupted:`Thinking interrupted`,enterHint:`Enter to send · Shift+Enter for a new line`,headerLine:`{agent} · {n} turn|{agent} · {n} turns`,newCount:`{n} new message|{n} new messages`,emptyTitle:`What should change on this page?`,emptyHint:`Pick an element, Modify it to get candidates, or just describe what you want. Artifacts land in Artifacts.`,searchModels:`Search models…`,defaultAuto:`Default (the agent decides)`,useCustom:`Use “{id}”`,modelsFailed:`Could not load models — type a model id`,noModels:`No matching models`,loadingModels:`Loading models…`,groupOther:`Other`,agentVersion:`Version {v}`,effort:`Reasoning`,effortDefault:`Default`,effortReset:`Reset to default ({v})`,fastMode:`Fast mode`,fastSpeed:`{n}x speed`,fastUsage:`Uses more of your limit`,fastShort:`Fast`,effortNames:{none:`None`,minimal:`Minimal`,low:`Low`,medium:`Medium`,high:`High`,xhigh:`Extra high`,max:`Max`,ultra:`Ultra`},picks:`Picks`,marks:`Marks`,files:`Files`,question:`Question`,other:`Other`,otherPlaceholder:`Type your own…`,recommended:`Recommended`,skip:`Skip`,next:`Next`,prev:`Back`,submit:`Submit`,skipped:`Skipped`,answerTimeout:`Not answered (timed out)`,answerCancelled:`Cancelled`,required:`Required`,liveActive:`{n} candidate set open|{n} candidate sets open`,discardAll:`Discard all ({n})`,discardAllHint:`Discard every candidate not yet accepted and revert its changes on the page`,confirmDiscardAll:`Discard {n} candidate set? Its changes on the page will be reverted and any generation in progress will stop.|Discard {n} candidate sets? Their changes on the page will be reverted and any generation in progress will stop.`,clearFailed:`Clear failed ({n})`,clearFailedHint:`Remove only the failed candidates; the others stay as they are`,inplace:`In place`,compare:`Side by side`,accept:`Accept`,discard:`Discard`,retryAccept:`Retry & accept`,live_generating:`Generating`,live_refining:`Refining`,live_accepting:`Accepting`,live_discarding:`Discarding`,live_ready:`Ready`,live_failed:`Failed`,live_accepted:`Accepted`,live_discarded:`Discarded`,allArtifacts:`All artifacts`,noArtifacts:`No artifacts yet. Plans, reports and mockups the agent writes show up here.`,new:`New`,updated:`Updated`,version:`Version`,readOnly:`Old version (read-only)`,desktop:`Desktop`,mobile:`Mobile`,zoom:`Zoom`,copy:`Copy`,copied:`Copied`,download:`Download`,exportPng:`Export PNG`,exportPdf:`Export PDF`,structured:`Structured`,raw:`Raw`,loadFailed:`Failed to load`,close:`Close`,binary:`Binary file, no preview`,search:`Search history…`,noChats:`No chats yet`,turns:`{n} turn|{n} turns`,continueInPanel:`Continue in panel`,continueHint:`Set as the panel’s current chat; open the chat on the page to continue.`,exportMd:`Export Markdown`,results:`{n} result|{n} results`,noResults:`No matches`,duration:`Duration`,tokens:`tokens`,selectChat:`Select a chat on the left`,justNow:`just now`,minutesAgo:`{n} min ago`,hoursAgo:`{n} h ago`,daysAgo:`{n} d ago`};function Ss(){try{let e=localStorage.getItem(`ph:lang`);if(e===`en`||e===`zh-CN`)return e}catch{}return null}var Cs=Kt(Ss()??(navigator.language?.toLowerCase().startsWith(`zh`)?`zh-CN`:`en`)),ws=Kt(Ss()!==null);function Ts(e,t=!0){if(Cs.value=e,document.documentElement.lang=e,t){ws.value=!0;try{localStorage.setItem(`ph:lang`,e)}catch{}}}var q=G(()=>Cs.value===`en`?xs:bs);function Es(e,t){return e.includes(`|`)&&t.n!==void 0&&(e=e.split(`|`)[Number(t.n)===1?0:1]),e.replace(/\{(\w+)\}/g,(e,n)=>String(t[n]??``))}function Ds(e,t=Date.now()){let n=Math.max(0,t-e),r=q.value;return n<6e4?r.justNow:n<36e5?Es(r.minutesAgo,{n:Math.floor(n/6e4)}):n<864e5?Es(r.hoursAgo,{n:Math.floor(n/36e5)}):n<6048e5?Es(r.daysAgo,{n:Math.floor(n/864e5)}):new Date(e).toLocaleDateString(Cs.value)}function Os(e){if(!e)return``;if(e<1e3)return`${e}ms`;let t=Math.round(e/1e3);return t<60?`${t}s`:`${Math.floor(t/60)}m${t%60?` ${t%60}s`:``}`}var ks={class:`ask card`},As={key:0,class:`title`},js={key:0,class:`sum`},Ms={class:`qp`},Ns={class:`qv`},Ps={key:1,class:`sum`},Fs={class:`qp`},Is={class:`qv`},Ls={key:2,class:`faint`},Rs={key:0,class:`dots`},zs=[`onClick`],Bs={class:`prompt`},Vs={class:`opts`},Hs=[`type`,`name`,`checked`,`onChange`],Us={class:`ol`},Ws={key:0,class:`rec`},Gs={key:1,class:`od`},Ks={key:0,class:`opt other`},qs={class:`ol`},Js=[`placeholder`],Ys={class:`foot`},Xs=[`disabled`],Zs=[`disabled`],Qs={key:0,class:`muted`},$s={key:0},ec=[`onUpdate:modelValue`,`placeholder`],tc=[`onUpdate:modelValue`,`type`,`placeholder`],nc={class:`foot`},rc=[`disabled`],ic=cs(Jn({__name:`AskCard`,props:{askId:{},spec:{},answer:{},pending:{type:Boolean},turnRunning:{type:Boolean}},emits:[`answer`],setup(e,{emit:t}){let n=e,r=t,i=Kt(0),a=Ft({}),o=Ft({}),s=Ft({});if(n.spec.kind===`form`)for(let e of n.spec.fields)s[e.name]=e.default??``;let c=G(()=>!n.answer&&n.pending),l=G(()=>n.spec.kind===`question`?n.spec.questions:[]),u=G(()=>l.value[i.value]);function d(e,t,n){let r=a[e]??[];a[e]=n?r.includes(t)?r.filter(e=>e!==t):[...r,t]:[t]}let f=e=>(a[e]?.length??0)>0||!!o[e]?.trim();function p(){let e={};for(let t of l.value)e[t.id]={selected:a[t.id]??[],other:o[t.id]?.trim()||void 0};r(`answer`,n.askId,{answers:e})}let m=G(()=>n.spec.kind!==`form`||n.spec.fields.every(e=>!e.required||s[e.name]?.trim()));function h(){m.value&&r(`answer`,n.askId,{values:{...s}})}let g=()=>r(`answer`,n.askId,{skipped:!0}),_=G(()=>{let e=n.answer;return e?`skipped`in e?q.value.skipped:`timeout`in e?q.value.answerTimeout:`cancelled`in e?q.value.answerCancelled:``:n.turnRunning?``:q.value.answerCancelled}),v=(e,t)=>l.value.find(t=>t.id===e)?.options.find(e=>e.id===t)?.label??t;return(t,n)=>(B(),V(`div`,ks,[e.spec.title?(B(),V(`div`,As,M(e.spec.title),1)):W(`v-if`,!0),W(` answered / closed `),c.value?e.spec.kind===`question`&&u.value?(B(),V(z,{key:2},[W(` question `),l.value.length>1?(B(),V(`div`,Rs,[(B(!0),V(z,null,Cr(l.value,(e,t)=>(B(),V(`span`,{key:e.id,class:k({cur:t===i.value,done:f(e.id)}),onClick:e=>i.value=t},null,10,zs))),128))])):W(`v-if`,!0),H(`div`,Bs,M(u.value.prompt),1),H(`div`,Vs,[(B(!0),V(z,null,Cr(u.value.options,t=>(B(),V(`label`,{key:t.id,class:k([`opt`,{on:a[u.value.id]?.includes(t.id)}])},[H(`input`,{type:u.value.multiple?`checkbox`:`radio`,name:e.askId+u.value.id,checked:a[u.value.id]?.includes(t.id),onChange:e=>d(u.value.id,t.id,u.value.multiple)},null,40,Hs),H(`span`,Us,[H(`span`,null,M(t.label),1),t.recommended?(B(),V(`span`,Ws,M(R(q).recommended),1)):W(`v-if`,!0),t.description?(B(),V(`span`,Gs,M(t.description),1)):W(`v-if`,!0)])],2))),128)),u.value.allowOther===!1?W(`v-if`,!0):(B(),V(`label`,Ks,[H(`span`,qs,M(R(q).other),1),jn(H(`input`,{"onUpdate:modelValue":n[0]||=e=>o[u.value.id]=e,class:`input`,placeholder:R(q).otherPlaceholder,onKeydown:n[1]||=No(()=>{},[`stop`])},null,40,Js),[[yo,o[u.value.id]]])]))]),H(`div`,Ys,[H(`button`,{class:`btn ghost sm`,onClick:g},M(R(q).skip),1),n[6]||=H(`span`,{class:`spacer`},null,-1),i.value>0?(B(),V(`button`,{key:0,class:`btn sm`,onClick:n[2]||=e=>i.value--},M(R(q).prev),1)):W(`v-if`,!0),i.value<l.value.length-1?(B(),V(`button`,{key:1,class:`btn sm primary`,disabled:!f(u.value.id),onClick:n[3]||=e=>i.value++},M(R(q).next),9,Xs)):(B(),V(`button`,{key:2,class:`btn sm primary`,disabled:!l.value.every(e=>f(e.id)),onClick:p},M(R(q).submit),9,Zs))])],64)):e.spec.kind===`form`?(B(),V(z,{key:3},[W(` form `),e.spec.description?(B(),V(`div`,Qs,M(e.spec.description),1)):W(`v-if`,!0),(B(!0),V(z,null,Cr(e.spec.fields,e=>(B(),V(`label`,{key:e.name,class:`field`},[H(`span`,null,[ea(M(e.label),1),e.required?(B(),V(`em`,$s,` *`)):W(`v-if`,!0)]),e.type===`textarea`?jn((B(),V(`textarea`,{key:0,"onUpdate:modelValue":t=>s[e.name]=t,class:`input ta`,placeholder:e.placeholder,rows:`3`,onKeydown:n[4]||=No(()=>{},[`stop`])},null,40,ec)),[[yo,s[e.name]]]):jn((B(),V(`input`,{key:1,"onUpdate:modelValue":t=>s[e.name]=t,class:`input`,type:e.type===`url`?`url`:`text`,placeholder:e.placeholder,onKeydown:[n[5]||=No(()=>{},[`stop`]),Fo(h,[`enter`])]},null,40,tc)),[[Oo,s[e.name]]])]))),128)),H(`div`,nc,[H(`button`,{class:`btn ghost sm`,onClick:g},M(R(q).skip),1),n[7]||=H(`span`,{class:`spacer`},null,-1),H(`button`,{class:`btn sm primary`,disabled:!m.value,onClick:h},M(R(q).submit),9,rc)])],64)):W(`v-if`,!0):(B(),V(z,{key:1},[e.answer&&`answers`in e.answer?(B(),V(`div`,js,[(B(!0),V(z,null,Cr(l.value,t=>(B(),V(`div`,{key:t.id,class:`qa`},[H(`div`,Ms,M(t.prompt),1),H(`div`,Ns,M([...(e.answer.answers[t.id]?.selected??[]).map(e=>v(t.id,e)),e.answer.answers[t.id]?.other?`${R(q).other}: ${e.answer.answers[t.id]?.other}`:``].filter(Boolean).join(`、`)||`—`),1)]))),128))])):e.answer&&`values`in e.answer&&e.spec.kind===`form`?(B(),V(`div`,Ps,[(B(!0),V(z,null,Cr(e.spec.fields,t=>(B(),V(`div`,{key:t.name,class:`qa`},[H(`div`,Fs,M(t.label),1),H(`div`,Is,M(e.answer.values[t.name]||`—`),1)]))),128))])):W(`v-if`,!0),_.value?(B(),V(`div`,Ls,M(_.value),1)):W(`v-if`,!0)],64))]))}}),[[`__scopeId`,`data-v-5d5b7c6b`]]),ac=[`data-side`],oc={class:`top`},sc=[`title`],cc={key:0,class:`spin`},lc={key:0,class:`prompt muted`},uc={key:1,class:`err`},dc={key:0,class:`vars`},fc=[`onClick`],pc={key:1,class:`vars`},mc={class:`acts`},hc=cs(Jn({__name:`LiveCard`,props:{session:{},title:{},view:{},interactive:{type:Boolean},compact:{type:Boolean},agent:{type:Boolean}},emits:[`op`,`nav`],setup(e,{emit:t}){let n=e,r=t,i=G(()=>n.session),a=G(()=>n.view?.current??i.value?.variants[0]?.index??1),o=G(()=>n.view?.display??i.value?.display??`inplace`),s=G(()=>!!i.value&&[`generating`,`refining`,`accepting`,`discarding`].includes(i.value.status)),c=G(()=>i.value?q.value[`live_${i.value.status}`]??i.value.status:``);function l(e){if(!i.value)return;let t=i.value.variants.map(e=>e.index),n=t.indexOf(a.value);r(`nav`,i.value.sid,t[(n+e+t.length)%t.length],`inplace`)}return(t,n)=>(B(),V(`div`,{class:k([`live card`,[i.value?.status,{compact:e.compact,agent:e.agent}]]),"data-side":e.agent?`agent`:`user`},[H(`div`,oc,[U(K,{name:`sparkle`,class:`ic`}),H(`span`,{class:`title`,title:e.title},M(e.title),9,sc),i.value?(B(),V(`span`,{key:0,class:k([`st`,{busy:s.value}])},[s.value?(B(),V(`span`,cc)):W(`v-if`,!0),ea(M(c.value),1)],2)):W(`v-if`,!0)]),i.value?.prompt&&!e.agent?(B(),V(`div`,lc,M(i.value.prompt),1)):W(`v-if`,!0),i.value?.error&&i.value.status===`failed`&&!e.compact?(B(),V(`div`,uc,M(i.value.error),1)):W(`v-if`,!0),i.value&&e.interactive&&!e.compact?(B(),V(z,{key:2},[i.value.variants.length&&i.value.status===`ready`?(B(),V(`div`,dc,[H(`button`,{class:`btn icon sm`,onClick:n[0]||=e=>l(-1)},[U(K,{name:`left`})]),(B(!0),V(z,null,Cr(i.value.variants,e=>(B(),V(`button`,{key:e.index,class:k([`btn sm`,{on:e.index===a.value}]),onClick:t=>r(`nav`,i.value.sid,e.index,`inplace`)},M(e.index)+` · `+M(e.label),11,fc))),128)),H(`button`,{class:`btn icon sm`,onClick:n[1]||=e=>l(1)},[U(K,{name:`right`})])])):i.value.variants.length?(B(),V(`div`,pc,[(B(!0),V(z,null,Cr(i.value.variants,e=>(B(),V(`span`,{key:e.index,class:k([`chip`,{acc:i.value.accepted===e.index&&i.value.status===`accepted`}])},M(e.index)+` · `+M(e.label),3))),128))])):W(`v-if`,!0),H(`div`,mc,[i.value.status===`ready`?(B(),V(z,{key:0},[H(`button`,{class:`btn sm`,onClick:n[2]||=e=>r(`nav`,i.value.sid,void 0,o.value===`compare`?`inplace`:`compare`)},M(o.value===`compare`?R(q).inplace:R(q).compare),1),n[9]||=H(`span`,{class:`spacer`},null,-1),H(`button`,{class:`btn sm`,onClick:n[3]||=e=>r(`op`,{op:`discard`,sid:i.value.sid})},M(R(q).discard),1),H(`button`,{class:`btn sm primary`,onClick:n[4]||=e=>r(`op`,{op:`accept`,sid:i.value.sid,variant:a.value})},M(R(q).accept),1)],64)):i.value.status===`failed`?(B(),V(z,{key:1},[n[10]||=H(`span`,{class:`spacer`},null,-1),H(`button`,{class:`btn sm`,onClick:n[5]||=e=>r(`op`,{op:`discard`,sid:i.value.sid})},M(R(q).discard),1),i.value.accepted===void 0?W(`v-if`,!0):(B(),V(`button`,{key:0,class:`btn sm`,onClick:n[6]||=e=>r(`op`,{op:`retry`,sid:i.value.sid,andAccept:!0})},M(R(q).retryAccept),1)),H(`button`,{class:`btn sm primary`,onClick:n[7]||=e=>r(`op`,{op:`retry`,sid:i.value.sid})},M(R(q).retry),1)],64)):i.value.status===`generating`||i.value.status===`refining`?(B(),V(z,{key:2},[n[11]||=H(`span`,{class:`spacer`},null,-1),H(`button`,{class:`btn sm`,onClick:n[8]||=e=>r(`op`,{op:`discard`,sid:i.value.sid})},M(R(q).discard),1)],64)):W(`v-if`,!0)])],64)):W(`v-if`,!0)],10,ac))}}),[[`__scopeId`,`data-v-1e552fb6`]]),gc=e({default:()=>Hl});function _c(e,t){this.v=e,this.k=t}function vc(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,r=Array(t);n<t;n++)r[n]=e[n];return r}function yc(e){if(Array.isArray(e))return e}function bc(e,t){var n=e==null?null:typeof Symbol<`u`&&e[Symbol.iterator]||e[`@@iterator`];if(n!=null){var r,i,a,o,s=[],c=!0,l=!1;try{if(a=(n=n.call(e)).next,t===0){if(Object(n)!==n)return;c=!1}else for(;!(c=(r=a.call(n)).done)&&(s.push(r.value),s.length!==t);c=!0);}catch(e){l=!0,i=e}finally{try{if(!c&&n.return!=null&&(o=n.return(),Object(o)!==o))return}finally{if(l)throw i}}return s}}function xc(){throw TypeError(`Invalid attempt to destructure non-iterable instance.
|
|
4
|
+
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function Sc(e,t){return yc(e)||bc(e,t)||Cc(e,t)||xc()}function Cc(e,t){if(e){if(typeof e==`string`)return vc(e,t);var n={}.toString.call(e).slice(8,-1);return n===`Object`&&e.constructor&&(n=e.constructor.name),n===`Map`||n===`Set`?Array.from(e):n===`Arguments`||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?vc(e,t):void 0}}function wc(e){var t,n;function r(t,n){try{var a=e[t](n),o=a.value,s=o instanceof _c;Promise.resolve(s?o.v:o).then(function(n){if(s){var c=t===`return`&&o.k?t:`next`;if(!o.k||n.done)return r(c,n);n=e[c](n).value}i(!!a.done,n)},function(e){r(`throw`,e)})}catch(e){i(2,e)}}function i(e,i){e===2?t.reject(i):t.resolve({value:i,done:e}),(t=t.next)?r(t.key,t.arg):n=null}this._invoke=function(e,i){return new Promise(function(a,o){var s={key:e,arg:i,resolve:a,reject:o,next:null};n?n=n.next=s:(t=n=s,r(e,i))})},typeof e.return!=`function`&&(this.return=void 0)}wc.prototype[typeof Symbol==`function`&&Symbol.asyncIterator||`@@asyncIterator`]=function(){return this},wc.prototype.next=function(e){return this._invoke(`next`,e)},wc.prototype.throw=function(e){return this._invoke(`throw`,e)},wc.prototype.return=function(e){return this._invoke(`return`,e)};var Tc=Object.entries,Ec=Object.setPrototypeOf,Dc=Object.isFrozen,Oc=Object.getPrototypeOf,kc=Object.getOwnPropertyDescriptor,J=Object.freeze,Ac=Object.seal,jc=Object.create,Mc=typeof Reflect<`u`&&Reflect,Nc=Mc.apply,Pc=Mc.construct;J||=function(e){return e},Ac||=function(e){return e},Nc||=function(e,t){var n=[...arguments].slice(2);return e.apply(t,n)},Pc||=function(e){return new e(...[...arguments].slice(1))};var Fc=Y(Array.prototype.forEach);Array.prototype.indexOf;var Ic=Y(Array.prototype.lastIndexOf),Lc=Y(Array.prototype.pop),Rc=Y(Array.prototype.push);Array.prototype.slice;var zc=Y(Array.prototype.splice),Bc=Array.isArray,Vc=Y(String.prototype.toLowerCase),Hc=Y(String.prototype.toString),Uc=Y(String.prototype.match),Wc=Y(String.prototype.replace),Gc=Y(String.prototype.indexOf),Kc=Y(String.prototype.trim),qc=Y(Number.prototype.toString),Jc=Y(Boolean.prototype.toString),Yc=typeof BigInt>`u`?null:Y(BigInt.prototype.toString),Xc=typeof Symbol>`u`?null:Y(Symbol.prototype.toString),Zc=Y(Object.prototype.hasOwnProperty),Qc=Y(Object.prototype.toString),$c=Y(RegExp.prototype.test),el=tl(TypeError);function Y(e){return function(t){t instanceof RegExp&&(t.lastIndex=0);var n=[...arguments].slice(1);return Nc(e,t,n)}}function tl(e){return function(){return Pc(e,[...arguments])}}function X(e,t){let n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:Vc;if(Ec&&Ec(e,null),!Bc(t))return e;let r=t.length;for(;r--;){let i=t[r];if(typeof i==`string`){let e=n(i);e!==i&&(Dc(t)||(t[r]=e),i=e)}e[i]=!0}return e}function nl(e){for(let t=0;t<e.length;t++)Zc(e,t)||(e[t]=null);return e}function rl(e){let t=jc(null);for(let r of Tc(e)){var n=Sc(r,2);let i=n[0],a=n[1];Zc(e,i)&&(t[i]=Bc(a)?nl(a):a&&typeof a==`object`&&a.constructor===Object?rl(a):a)}return t}function il(e){switch(typeof e){case`string`:return e;case`number`:return qc(e);case`boolean`:return Jc(e);case`bigint`:return Yc?Yc(e):`0`;case`symbol`:return Xc?Xc(e):`Symbol()`;case`undefined`:return Qc(e);case`function`:case`object`:{if(e===null)return Qc(e);let t=e,n=al(t,`toString`);if(typeof n==`function`){let e=n(t);return typeof e==`string`?e:Qc(e)}return Qc(e)}default:return Qc(e)}}function al(e,t){for(;e!==null;){let n=kc(e,t);if(n){if(n.get)return Y(n.get);if(typeof n.value==`function`)return Y(n.value)}e=Oc(e)}function n(){return null}return n}function ol(e){try{return $c(e,``),!0}catch{return!1}}var sl=J(`a.abbr.acronym.address.area.article.aside.audio.b.bdi.bdo.big.blink.blockquote.body.br.button.canvas.caption.center.cite.code.col.colgroup.content.data.datalist.dd.decorator.del.details.dfn.dialog.dir.div.dl.dt.element.em.fieldset.figcaption.figure.font.footer.form.h1.h2.h3.h4.h5.h6.head.header.hgroup.hr.html.i.img.input.ins.kbd.label.legend.li.main.map.mark.marquee.menu.menuitem.meter.nav.nobr.ol.optgroup.option.output.p.picture.pre.progress.q.rp.rt.ruby.s.samp.search.section.select.shadow.slot.small.source.spacer.span.strike.strong.style.sub.summary.sup.table.tbody.td.template.textarea.tfoot.th.thead.time.tr.track.tt.u.ul.var.video.wbr`.split(`.`)),cl=J(`svg.a.altglyph.altglyphdef.altglyphitem.animatecolor.animatemotion.animatetransform.circle.clippath.defs.desc.ellipse.enterkeyhint.exportparts.filter.font.g.glyph.glyphref.hkern.image.inputmode.line.lineargradient.marker.mask.metadata.mpath.part.path.pattern.polygon.polyline.radialgradient.rect.stop.style.switch.symbol.text.textpath.title.tref.tspan.view.vkern`.split(`.`)),ll=J([`feBlend`,`feColorMatrix`,`feComponentTransfer`,`feComposite`,`feConvolveMatrix`,`feDiffuseLighting`,`feDisplacementMap`,`feDistantLight`,`feDropShadow`,`feFlood`,`feFuncA`,`feFuncB`,`feFuncG`,`feFuncR`,`feGaussianBlur`,`feImage`,`feMerge`,`feMergeNode`,`feMorphology`,`feOffset`,`fePointLight`,`feSpecularLighting`,`feSpotLight`,`feTile`,`feTurbulence`]),ul=J([`animate`,`color-profile`,`cursor`,`discard`,`font-face`,`font-face-format`,`font-face-name`,`font-face-src`,`font-face-uri`,`foreignobject`,`hatch`,`hatchpath`,`mesh`,`meshgradient`,`meshpatch`,`meshrow`,`missing-glyph`,`script`,`set`,`solidcolor`,`unknown`,`use`]),dl=J(`math.menclose.merror.mfenced.mfrac.mglyph.mi.mlabeledtr.mmultiscripts.mn.mo.mover.mpadded.mphantom.mroot.mrow.ms.mspace.msqrt.mstyle.msub.msup.msubsup.mtable.mtd.mtext.mtr.munder.munderover.mprescripts`.split(`.`)),fl=J([`maction`,`maligngroup`,`malignmark`,`mlongdiv`,`mscarries`,`mscarry`,`msgroup`,`mstack`,`msline`,`msrow`,`semantics`,`annotation`,`annotation-xml`,`mprescripts`,`none`]),pl=J([`#text`]),ml=J(`accept.action.align.alt.autocapitalize.autocomplete.autopictureinpicture.autoplay.background.bgcolor.border.capture.cellpadding.cellspacing.checked.cite.class.clear.color.cols.colspan.command.commandfor.controls.controlslist.coords.crossorigin.datetime.decoding.default.dir.disabled.disablepictureinpicture.disableremoteplayback.download.draggable.enctype.enterkeyhint.exportparts.face.for.headers.height.hidden.high.href.hreflang.id.inert.inputmode.integrity.ismap.kind.label.lang.list.loading.loop.low.max.maxlength.media.method.min.minlength.multiple.muted.name.nonce.noshade.novalidate.nowrap.open.optimum.part.pattern.placeholder.playsinline.popover.popovertarget.popovertargetaction.poster.preload.pubdate.radiogroup.readonly.rel.required.rev.reversed.role.rows.rowspan.spellcheck.scope.selected.shape.size.sizes.slot.span.srclang.start.src.srcset.step.style.summary.tabindex.title.translate.type.usemap.valign.value.width.wrap.xmlns`.split(`.`)),hl=J(`accent-height.accumulate.additive.alignment-baseline.amplitude.ascent.attributename.attributetype.azimuth.basefrequency.baseline-shift.begin.bias.by.class.clip.clippathunits.clip-path.clip-rule.color.color-interpolation.color-interpolation-filters.color-profile.color-rendering.cx.cy.d.dx.dy.diffuseconstant.direction.display.divisor.dominant-baseline.dur.edgemode.elevation.end.exponent.fill.fill-opacity.fill-rule.filter.filterunits.flood-color.flood-opacity.font-family.font-size.font-size-adjust.font-stretch.font-style.font-variant.font-weight.fx.fy.g1.g2.glyph-name.glyphref.gradientunits.gradienttransform.height.href.id.image-rendering.in.in2.intercept.k.k1.k2.k3.k4.kerning.keypoints.keysplines.keytimes.lang.lengthadjust.letter-spacing.kernelmatrix.kernelunitlength.lighting-color.local.marker-end.marker-mid.marker-start.markerheight.markerunits.markerwidth.maskcontentunits.maskunits.max.mask.mask-type.media.method.mode.min.name.numoctaves.offset.operator.opacity.order.orient.orientation.origin.overflow.paint-order.path.pathlength.patterncontentunits.patterntransform.patternunits.pointer-events.points.preservealpha.preserveaspectratio.primitiveunits.r.rx.ry.radius.refx.refy.repeatcount.repeatdur.restart.result.rotate.scale.seed.shape-rendering.slope.specularconstant.specularexponent.spreadmethod.startoffset.stddeviation.stitchtiles.stop-color.stop-opacity.stroke-dasharray.stroke-dashoffset.stroke-linecap.stroke-linejoin.stroke-miterlimit.stroke-opacity.stroke.stroke-width.style.surfacescale.systemlanguage.tabindex.tablevalues.targetx.targety.transform.transform-origin.text-anchor.text-decoration.text-orientation.text-rendering.textlength.type.u1.u2.unicode.values.vector-effect.viewbox.visibility.version.vert-adv-y.vert-origin-x.vert-origin-y.width.word-spacing.wrap.writing-mode.xchannelselector.ychannelselector.x.x1.x2.xmlns.y.y1.y2.z.zoomandpan`.split(`.`)),gl=J(`accent.accentunder.align.bevelled.close.columnalign.columnlines.columnspacing.columnspan.denomalign.depth.dir.display.displaystyle.encoding.fence.frame.height.href.id.largeop.length.linethickness.lquote.lspace.mathbackground.mathcolor.mathsize.mathvariant.maxsize.minsize.movablelimits.notation.numalign.open.rowalign.rowlines.rowspacing.rowspan.rspace.rquote.scriptlevel.scriptminsize.scriptsizemultiplier.selection.separator.separators.stretchy.subscriptshift.supscriptshift.symmetric.voffset.width.xmlns`.split(`.`)),_l=J([`xlink:href`,`xml:id`,`xlink:title`,`xml:space`,`xmlns:xlink`]),vl=Ac(/{{[\w\W]*|^[\w\W]*}}/g),yl=Ac(/<%[\w\W]*|^[\w\W]*%>/g),bl=Ac(/\${[\w\W]*/g),xl=Ac(/^data-[\-\w.\u00B7-\uFFFF]+$/),Sl=Ac(/^aria-[\-\w]+$/),Cl=Ac(/^(?:(?:(?:f|ht)tps?|mailto|tel|callto|sms|cid|xmpp|matrix):|[^a-z]|[a-z+.\-]+(?:[^a-z+.\-:]|$))/i),wl=Ac(/^(?:\w+script|data):/i),Tl=Ac(/[\u0000-\u0020\u00A0\u1680\u180E\u2000-\u2029\u205F\u3000]/g),El=Ac(/^html$/i),Dl=Ac(/^[a-z][.\w]*(-[.\w]+)+$/i),Ol=Ac(/<[/\w!]/g),kl=Ac(/<[/\w]/g),Al=Ac(/<\/no(script|embed|frames)/i),jl=Ac(/\/>/i),Ml={element:1,attribute:2,text:3,cdataSection:4,entityReference:5,entityNode:6,processingInstruction:7,comment:8,document:9,documentType:10,documentFragment:11,notation:12},Nl=[`style`,`script`,`xmp`,`iframe`,`noembed`,`noframes`,`plaintext`,`noscript`],Pl=J(X({},Nl)),Fl=function(){let e={};return Fc(Nl,t=>{e[t]=Ac(RegExp(`</`+t+`(?=[\\t\\n\\f\\r />])`,`i`))}),J(e)}(),Il=function(){return typeof window>`u`?null:window},Ll=function(e,t){if(typeof e!=`object`||typeof e.createPolicy!=`function`)return null;let n=null,r=`data-tt-policy-suffix`;t&&t.hasAttribute(r)&&(n=t.getAttribute(r));let i=`dompurify`+(n?`#`+n:``);try{return e.createPolicy(i,{createHTML(e){return e},createScriptURL(e){return e}})}catch{return console.warn(`TrustedTypes policy `+i+` could not be created.`),null}},Rl=function(){return{afterSanitizeAttributes:[],afterSanitizeElements:[],afterSanitizeShadowDOM:[],beforeSanitizeAttributes:[],beforeSanitizeElements:[],beforeSanitizeShadowDOM:[],uponSanitizeAttribute:[],uponSanitizeElement:[],uponSanitizeShadowNode:[]}},zl=function(e,t,n,r){return Zc(e,t)&&Bc(e[t])?X(r.base?rl(r.base):{},e[t],r.transform):n},Bl=function(e,t,n){let r=Zc(e,t)?e[t]:void 0;return r&&typeof r==`object`?rl(r):n()};function Vl(){let e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:Il(),t=e=>Vl(e);if(t.version=`3.4.16`,t.removed=[],!e||!e.document||e.document.nodeType!==Ml.document||!e.Element)return t.isSupported=!1,t;let n=e.document,r=n,i=r.currentScript;e.DocumentFragment;let a=e.HTMLTemplateElement,o=e.Node,s=e.Element,c=e.NodeFilter;e.NamedNodeMap===void 0&&(e.NamedNodeMap||e.MozNamedAttrMap),e.HTMLFormElement;let l=e.DOMParser,u=e.trustedTypes,d=s.prototype,f=al(d,`cloneNode`),p=al(d,`remove`),m=al(d,`removeAttributeNode`),h=al(d,`nextSibling`),g=al(d,`childNodes`),_=al(d,`parentNode`),v=al(d,`shadowRoot`),y=al(d,`attributes`),b=o&&o.prototype?al(o.prototype,`nodeType`):null,x=o&&o.prototype?al(o.prototype,`nodeName`):null,S=o&&o.prototype?al(o.prototype,`ownerDocument`):null,C=function(e){return b?b(e):e.nodeType},ee=function(e){return x?x(e):e.nodeName};if(typeof a==`function`){let e=n.createElement(`template`);e.content&&e.content.ownerDocument&&(n=e.content.ownerDocument)}let w,te=``,ne,re=!1,T=0,ie=function(){if(T>0)throw el(`A configured TRUSTED_TYPES_POLICY callback (createHTML or createScriptURL) must not call DOMPurify.sanitize, as that causes infinite recursion. Do not pass a policy whose callbacks wrap DOMPurify as TRUSTED_TYPES_POLICY; see the "DOMPurify and Trusted Types" section of the README.`)},E=function(e){ie(),T++;try{return w.createHTML(e)}finally{T--}},ae=function(e){ie(),T++;try{return w.createScriptURL(e)}finally{T--}},oe=function(){return re||=(ne=Ll(u,i),!0),ne},se=n,D=se.implementation,ce=se.createNodeIterator,le=se.createDocumentFragment,ue=se.getElementsByTagName,de=r.importNode,O=Rl();t.isSupported=typeof Tc==`function`&&typeof _==`function`&&D&&D.createHTMLDocument!==void 0;let fe=vl,pe=yl,me=bl,he=xl,k=Sl,ge=wl,_e=Tl,ve=Dl,ye=Cl,A=null,be=X({},[...sl,...cl,...ll,...dl,...pl]),j=null,xe=X({},[...ml,...hl,...gl,..._l]),Se=Object.seal(jc(null,{tagNameCheck:{writable:!0,configurable:!1,enumerable:!0,value:null},attributeNameCheck:{writable:!0,configurable:!1,enumerable:!0,value:null},allowCustomizedBuiltInElements:{writable:!0,configurable:!1,enumerable:!0,value:!1}})),Ce=null,M=null,we=Object.seal(jc(null,{tagCheck:{writable:!0,configurable:!1,enumerable:!0,value:null},attributeCheck:{writable:!0,configurable:!1,enumerable:!0,value:null}})),Te=!0,N=!0,Ee=!1,De=!0,P=!1,Oe=!0,ke=!1,Ae=!1,je=null,Me=null,Ne=!1,Pe=!1,Fe=!1,Ie=!1,Le=!0,Re=!1,ze=`user-content-`,Be=!0,Ve=!1,He={},Ue=null,We=X({},`annotation-xml.audio.colgroup.desc.foreignobject.head.iframe.math.mi.mn.mo.ms.mtext.noembed.noframes.noscript.plaintext.script.selectedcontent.style.svg.template.thead.title.video.xmp`.split(`.`)),Ge=null,Ke=X({},[`audio`,`video`,`img`,`source`,`image`,`track`]),qe=null,Je=X({},[`alt`,`class`,`for`,`id`,`label`,`name`,`pattern`,`placeholder`,`role`,`summary`,`title`,`value`,`style`,`xmlns`]),Ye=`http://www.w3.org/1998/Math/MathML`,Xe=`http://www.w3.org/2000/svg`,Ze=`http://www.w3.org/1999/xhtml`,Qe=Ze,$e=!1,et=null,tt=X({},[Ye,Xe,Ze],Hc),nt=J([`mi`,`mo`,`mn`,`ms`,`mtext`]),rt=X({},nt),it=J([`annotation-xml`]),at=X({},it),ot=X({},[`title`,`style`,`font`,`a`,`script`]),st=null,ct=[`application/xhtml+xml`,`text/html`],F=null,lt=null,ut=n.createElement(`form`),dt=function(e){return e instanceof RegExp||e instanceof Function},ft=function(){let e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};if(lt&<===e)return;(!e||typeof e!=`object`)&&(e={}),e=rl(e),st=ct.indexOf(e.PARSER_MEDIA_TYPE)===-1?`text/html`:e.PARSER_MEDIA_TYPE,F=st===`application/xhtml+xml`?Hc:Vc,A=zl(e,`ALLOWED_TAGS`,be,{transform:F}),j=zl(e,`ALLOWED_ATTR`,xe,{transform:F}),et=zl(e,`ALLOWED_NAMESPACES`,tt,{transform:Hc}),qe=zl(e,`ADD_URI_SAFE_ATTR`,Je,{transform:F,base:Je}),Ge=zl(e,`ADD_DATA_URI_TAGS`,Ke,{transform:F,base:Ke}),Ue=zl(e,`FORBID_CONTENTS`,We,{transform:F}),Ce=zl(e,`FORBID_TAGS`,rl({}),{transform:F}),M=zl(e,`FORBID_ATTR`,rl({}),{transform:F}),He=Zc(e,`USE_PROFILES`)?e.USE_PROFILES&&typeof e.USE_PROFILES==`object`?rl(e.USE_PROFILES):e.USE_PROFILES:!1,Te=e.ALLOW_ARIA_ATTR!==!1,N=e.ALLOW_DATA_ATTR!==!1,Ee=e.ALLOW_UNKNOWN_PROTOCOLS||!1,De=e.ALLOW_SELF_CLOSE_IN_ATTR!==!1,P=e.SAFE_FOR_TEMPLATES||!1,Oe=e.SAFE_FOR_XML!==!1,ke=e.WHOLE_DOCUMENT||!1,Pe=e.RETURN_DOM||!1,Fe=e.RETURN_DOM_FRAGMENT||!1,Ie=e.RETURN_TRUSTED_TYPE||!1,Ne=e.FORCE_BODY||!1,Le=e.SANITIZE_DOM!==!1,Re=e.SANITIZE_NAMED_PROPS||!1,Be=e.KEEP_CONTENT!==!1,Ve=e.IN_PLACE||!1,ye=ol(e.ALLOWED_URI_REGEXP)?e.ALLOWED_URI_REGEXP:Cl,Qe=typeof e.NAMESPACE==`string`?e.NAMESPACE:Ze,rt=Bl(e,`MATHML_TEXT_INTEGRATION_POINTS`,()=>X({},nt)),at=Bl(e,`HTML_INTEGRATION_POINTS`,()=>X({},it));let t=Bl(e,`CUSTOM_ELEMENT_HANDLING`,()=>jc(null));if(Se=jc(null),Zc(t,`tagNameCheck`)&&dt(t.tagNameCheck)&&(Se.tagNameCheck=t.tagNameCheck),Zc(t,`attributeNameCheck`)&&dt(t.attributeNameCheck)&&(Se.attributeNameCheck=t.attributeNameCheck),Zc(t,`allowCustomizedBuiltInElements`)&&typeof t.allowCustomizedBuiltInElements==`boolean`&&(Se.allowCustomizedBuiltInElements=t.allowCustomizedBuiltInElements),Ac(Se),P&&(N=!1),Fe&&(Pe=!0),He&&(A=X({},pl),j=jc(null),He.html===!0&&(X(A,sl),X(j,ml)),He.svg===!0&&(X(A,cl),X(j,hl),X(j,_l)),He.svgFilters===!0&&(X(A,ll),X(j,hl),X(j,_l)),He.mathMl===!0&&(X(A,dl),X(j,gl),X(j,_l))),we.tagCheck=null,we.attributeCheck=null,Zc(e,`ADD_TAGS`)&&(typeof e.ADD_TAGS==`function`?we.tagCheck=e.ADD_TAGS:Bc(e.ADD_TAGS)&&(A===be&&(A=rl(A)),X(A,e.ADD_TAGS,F))),Zc(e,`ADD_ATTR`)&&(typeof e.ADD_ATTR==`function`?we.attributeCheck=e.ADD_ATTR:Bc(e.ADD_ATTR)&&(j===xe&&(j=rl(j)),X(j,e.ADD_ATTR,F))),Zc(e,`ADD_FORBID_CONTENTS`)&&Bc(e.ADD_FORBID_CONTENTS)&&(Ue===We&&(Ue=rl(Ue)),X(Ue,e.ADD_FORBID_CONTENTS,F)),Be&&(A[`#text`]=!0),ke&&X(A,[`html`,`head`,`body`]),A.table&&(X(A,[`tbody`]),delete Ce.tbody),e.TRUSTED_TYPES_POLICY){if(typeof e.TRUSTED_TYPES_POLICY.createHTML!=`function`)throw el(`TRUSTED_TYPES_POLICY configuration option must provide a "createHTML" hook.`);if(typeof e.TRUSTED_TYPES_POLICY.createScriptURL!=`function`)throw el(`TRUSTED_TYPES_POLICY configuration option must provide a "createScriptURL" hook.`);let t=w;w=e.TRUSTED_TYPES_POLICY;try{te=E(``)}catch(e){throw w=t,e}}else e.TRUSTED_TYPES_POLICY===null?(w=void 0,te=``):(w===void 0&&(w=oe()),w&&typeof te==`string`&&(te=E(``)));J&&J(e),lt=e},pt=X({},[...cl,...ll,...ul]),mt=X({},[...dl,...fl]),ht=function(e,t,n){return t.namespaceURI===Ze?e===`svg`:t.namespaceURI===Ye?e===`svg`&&(n===`annotation-xml`||rt[n]):!!pt[e]},gt=function(e,t,n){return t.namespaceURI===Ze?e===`math`:t.namespaceURI===Xe?e===`math`&&at[n]:!!mt[e]},_t=function(e,t,n){return t.namespaceURI===Xe&&!at[n]||t.namespaceURI===Ye&&!rt[n]?!1:!mt[e]&&(ot[e]||!pt[e])},vt=function(e){let t=_(e);(!t||!t.tagName)&&(t={namespaceURI:Qe,tagName:`template`});let n=Vc(e.tagName),r=Vc(t.tagName);return et[e.namespaceURI]?e.namespaceURI===Xe?ht(n,t,r):e.namespaceURI===Ye?gt(n,t,r):e.namespaceURI===Ze?_t(n,t,r):!!(st===`application/xhtml+xml`&&et[e.namespaceURI]):!1},yt=function(e){Rc(t.removed,{element:e});try{_(e).removeChild(e)}catch{if(p(e),!_(e))throw el(`a node selected for removal could not be detached from its tree and cannot be safely returned; refusing to sanitize in place`)}},bt=function(e,t,n){try{m(e,t)}catch{try{e.removeAttribute(n)}catch{}}},xt=function(e){wt(e);let t=g(e);if(t){let e=[];Fc(t,t=>{Rc(e,t)}),Fc(e,e=>{try{p(e)}catch{}})}let n=y(e);if(n)for(let t=n.length-1;t>=0;--t){let r=n[t],i=r&&r.name;typeof i==`string`&&bt(e,r,i)}},St=function(e,n,r){if(!r)try{r=n.getAttributeNode(e)}catch{r=null}Rc(t.removed,{attribute:r||null,from:n});try{r?m(n,r):n.removeAttribute(e)}catch{try{n.removeAttribute(e)}catch{}}if(e===`is`){if(Pe||Fe)try{yt(n)}catch{}else try{n.setAttribute(e,``)}catch{}}},Ct=function(e){let t=y(e);if(t)for(let n=t.length-1;n>=0;--n){let r=t[n],i=r&&r.name;typeof i!=`string`||j[F(i)]||bt(e,r,i)}},wt=function(e){let t=[e];for(;t.length>0;){let e=t.pop();C(e)===Ml.element&&Ct(e);let n=g(e);if(n)for(let e=n.length-1;e>=0;--e)t.push(n[e])}},Tt=function(e,t){return Oe?e===`patchsrc`||e===`for`&&t!==`label`&&t!==`output`:!1},Et=function(e){if(!Oe)return;let t=[e];for(;t.length>0;){let e=t.pop(),n=C(e);if(n===Ml.processingInstruction||n===Ml.comment&&$c(kl,e.data)){try{p(e)}catch{}continue}if(n===Ml.element){let t=e,n=F(ee(e));try{t.hasAttribute&&t.hasAttribute(`patchsrc`)&&t.removeAttribute(`patchsrc`),t.hasAttribute&&t.hasAttribute(`for`)&&Tt(`for`,n)&&t.removeAttribute(`for`)}catch{}}let r=g(e);if(r)for(let e=r.length-1;e>=0;--e)t.push(r[e])}},Dt=function(e){let t=null,r=null;if(Ne)e=`<remove></remove>`+e;else{let t=Uc(e,/^[\r\n\t ]+/);r=t&&t[0]}st===`application/xhtml+xml`&&Qe===Ze&&(e=`<html xmlns="http://www.w3.org/1999/xhtml"><head></head><body>`+e+`</body></html>`);let i=w?E(e):e;if(Qe===Ze)try{t=new l().parseFromString(i,st)}catch{}if(!t||!t.documentElement){t=D.createDocument(Qe,`template`,null);try{t.documentElement.innerHTML=$e?te:i}catch{}}let a=t.body||t.documentElement;return e&&r&&a.insertBefore(n.createTextNode(r),a.childNodes[0]||null),Qe===Ze?ue.call(t,ke?`html`:`body`)[0]:ke?t.documentElement:a},Ot=function(e){let t=S?S(e):e.ownerDocument;return ce.call(t||e,e,c.SHOW_ELEMENT|c.SHOW_COMMENT|c.SHOW_TEXT|c.SHOW_PROCESSING_INSTRUCTION|c.SHOW_CDATA_SECTION,null)},kt=function(e){return e=Wc(e,fe,` `),e=Wc(e,pe,` `),e=Wc(e,me,` `),e},At=function(e){e.normalize();let t=S?S(e):e.ownerDocument,n=ce.call(t||e,e,c.SHOW_TEXT|c.SHOW_COMMENT|c.SHOW_CDATA_SECTION|c.SHOW_PROCESSING_INSTRUCTION,null),r=n.nextNode();for(;r;)r.data=kt(r.data),r=n.nextNode();let i=e.querySelectorAll?.call(e,`template`);i&&Fc(i,e=>{Mt(e.content)&&At(e.content)})},jt=function(e){let t=x?x(e):null;return typeof t!=`string`||F(t)!==`form`?!1:typeof e.nodeName!=`string`||typeof e.textContent!=`string`||typeof e.removeChild!=`function`||e.attributes!==y(e)||typeof e.removeAttribute!=`function`||typeof e.removeAttributeNode!=`function`||typeof e.getAttributeNode!=`function`||typeof e.setAttribute!=`function`||typeof e.namespaceURI!=`string`||typeof e.insertBefore!=`function`||typeof e.hasChildNodes!=`function`||e.nodeType!==b(e)||e.childNodes!==g(e)},Mt=function(e){if(!b||typeof e!=`object`||!e)return!1;try{return b(e)===Ml.documentFragment}catch{return!1}},Nt=function(e){if(!b||typeof e!=`object`||!e)return!1;try{return typeof b(e)==`number`}catch{return!1}};function Pt(e,n,r){e.length!==0&&Fc(e,e=>{e.call(t,n,r,lt)})}let Ft=function(e,t){return!!(Oe&&e.hasChildNodes()&&!Nt(e.firstElementChild)&&$c(Ol,e.textContent)&&$c(Ol,e.innerHTML)||Oe&&e.namespaceURI===Ze&&Pl[t]&&(Nt(e.firstElementChild)||typeof e.textContent==`string`&&$c(Fl[t],e.textContent))||e.nodeType===Ml.processingInstruction||Oe&&e.nodeType===Ml.comment&&$c(kl,e.data))},It=function(e,t){return e instanceof RegExp?$c(e,t):e instanceof Function&&!!e(t,...[...arguments].slice(2))},Lt=function(e,t,n){if(!Ce[t]&&I(t)&&It(Se.tagNameCheck,t))return!1;if(Be&&!Ue[t]){let t=_(e),r=g(e);if(r&&t){let i=r.length;for(let a=i-1;a>=0;--a){let i=e===n?f(r[a],!0):r[a];t.insertBefore(i,h(e))}}}return yt(e),!0},Rt=function(e,t,n,r){return e.length===0?t:t===n||t===r?rl(t):t},zt=function(e,t){return e===t||_(e)!==null?!1:(Ve&&wt(e),!0)},Bt=function(e,n){if(Pt(O.beforeSanitizeElements,e,null),zt(e,n))return!0;if(jt(e))return yt(e),!0;let r=F(ee(e));if(A=Rt(O.uponSanitizeElement,A,be,je),Pt(O.uponSanitizeElement,e,{tagName:r,allowedTags:A}),zt(e,n))return!0;if(Ft(e,r))return yt(e),!0;if(Ce[r]||!(we.tagCheck instanceof Function&&we.tagCheck(r))&&!A[r]){let t=Lt(e,r,n);return t===!1&&(Pt(O.afterSanitizeElements,e,null),zt(e,n))?!0:t}if(C(e)===Ml.element&&!vt(e)||(r===`noscript`||r===`noembed`||r===`noframes`)&&$c(Al,e.innerHTML))return yt(e),!0;if(P&&e.nodeType===Ml.text){let n=kt(e.textContent);e.textContent!==n&&(Rc(t.removed,{element:e.cloneNode()}),e.textContent=n)}return Pt(O.afterSanitizeElements,e,null),zt(e,n)},Vt=function(e,t,r){if(M[t]||Tt(t,e)||Le&&(t===`id`||t===`name`)&&(r in n||r in ut))return!1;let i=j[t]||we.attributeCheck instanceof Function&&we.attributeCheck(t,e);return N&&$c(he,t)||Te&&$c(k,t)?!0:i?qe[t]||$c(ye,Wc(r,_e,``))||(t===`src`||t===`xlink:href`||t===`href`)&&e!==`script`&&Gc(r,`data:`)===0&&Ge[e]||Ee&&!$c(ge,Wc(r,_e,``))?!0:!r:I(e)&&It(Se.tagNameCheck,e)&&It(Se.attributeNameCheck,t,e)||t===`is`&&Se.allowCustomizedBuiltInElements&&It(Se.tagNameCheck,r)},Ht=X({},[`annotation-xml`,`color-profile`,`font-face`,`font-face-format`,`font-face-name`,`font-face-src`,`font-face-uri`,`missing-glyph`]),I=function(e){return!Ht[Vc(e)]&&$c(ve,e)},Ut=function(e,t,n,r){if(w&&typeof u==`object`&&typeof u.getAttributeType==`function`&&!n)switch(u.getAttributeType(e,t)){case`TrustedHTML`:return E(r);case`TrustedScriptURL`:return ae(r)}return r},Wt=function(e,t,n,r){try{return n?e.setAttributeNS(n,t,r):e.setAttribute(t,r),!jt(e)||(yt(e),!1)}catch{return St(t,e),!1}},Gt=function(e,n){if(Pt(O.beforeSanitizeAttributes,e,null),zt(e,n))return;let r=e.attributes;if(!r||jt(e))return;j=Rt(O.uponSanitizeAttribute,j,xe,Me);let i={attrName:``,attrValue:``,keepAttr:!0,allowedAttributes:j,forceKeepAttr:void 0},a=r.length,o=F(e.nodeName);for(;a--;){let n=r[a],s=n.name,c=n.namespaceURI,l=n.value,u=F(s),d=l,f=s===`value`?d:Kc(d),p=!1;if(i.attrName=u,i.attrValue=f,i.keepAttr=!0,i.forceKeepAttr=void 0,Pt(O.uponSanitizeAttribute,e,i),f=i.attrValue,Re&&(u===`id`||u===`name`)&&Gc(f,ze)!==0&&(St(s,e,n),f=ze+f,p=!0),Oe&&$c(/((--!?|])>)|<\/(style|script|title|xmp|textarea|noscript|iframe|noembed|noframes)/i,f)){St(s,e,n);continue}if(u===`attributename`&&Uc(f,`href`)){St(s,e,n);continue}if(!i.forceKeepAttr){if(!i.keepAttr){St(s,e,n);continue}if(!De&&$c(jl,f)){St(s,e,n);continue}if(P&&(f=kt(f)),!Vt(o,u,f)){St(s,e,n);continue}f=Ut(o,u,c,f),f!==d&&Wt(e,s,c,f)&&p&&Lc(t.removed)}}Pt(O.afterSanitizeAttributes,e,null),zt(e,n)},L=function(e){let t=null,n=Ot(e);for(Pt(O.beforeSanitizeShadowDOM,e,null);t=n.nextNode();)if(Pt(O.uponSanitizeShadowNode,t,null),Bt(t,e),Gt(t,e),Mt(t.content)&&L(t.content),C(t)===Ml.element){let e=v(t);Mt(e)&&(Kt(e),L(e))}Pt(O.afterSanitizeShadowDOM,e,null)},Kt=function(e){let t=[{node:e,shadow:null}];for(;t.length>0;){let e=t.pop();if(e.shadow){L(e.shadow);continue}let n=e.node,r=C(n)===Ml.element,i=g(n);if(i)for(let e=i.length-1;e>=0;--e)t.push({node:i[e],shadow:null});if(r){let e=x?x(n):null;if(typeof e==`string`&&F(e)===`template`){let e=n.content;Mt(e)&&t.push({node:e,shadow:null})}}if(r){let e=v(n);Mt(e)&&t.push({node:null,shadow:e},{node:e,shadow:null})}}};return t.sanitize=function(e){let n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},i=null,a=null,o=null,s=null;if($e=!e,$e&&(e=`<!-->`),typeof e!=`string`&&!Nt(e)&&(e=il(e),typeof e!=`string`))throw el(`dirty is not a string, aborting`);if(!t.isSupported)return e;Ae?(A=je,j=Me):ft(n),(O.uponSanitizeElement.length>0||O.uponSanitizeAttribute.length>0)&&(A=rl(A)),O.uponSanitizeAttribute.length>0&&(j=rl(j)),t.removed=[];let c=Ve&&typeof e!=`string`&&Nt(e);if(c){Et(e);let t=ee(e);if(typeof t==`string`){let n=F(t);if(!A[n]||Ce[n])throw xt(e),el(`root node is forbidden and cannot be sanitized in-place`)}if(jt(e))throw xt(e),el(`root node is clobbered and cannot be sanitized in-place`);try{Kt(e)}catch(t){throw xt(e),t}}else if(Nt(e))i=Dt(`<!---->`),a=i.ownerDocument.importNode(e,!0),a.nodeType===Ml.element&&a.nodeName===`BODY`||a.nodeName===`HTML`?i=a:i.appendChild(a),Kt(i);else{if(!Pe&&!P&&!ke&&e.indexOf(`<`)===-1)return w&&Ie?E(e):e;if(i=Dt(e),!i)return Pe?null:Ie?te:``}i&&Ne&&yt(i.firstChild);let l=c?e:i;try{let e=Ot(l);for(;o=e.nextNode();)Bt(o,l),Gt(o,l),Mt(o.content)&&L(o.content)}catch(n){throw c&&(xt(e),Fc(t.removed,e=>{e.element&&wt(e.element)})),n}if(c){let n=!1;if(Fc(t.removed,t=>{t.element&&(t.element===e&&(n=!0),wt(t.element))}),n)throw el(`a node selected for removal could not be safely returned; refusing to sanitize in place`);return P&&At(e),e}if(Pe){if(P&&At(i),Fe)for(s=le.call(i.ownerDocument);i.firstChild;)s.appendChild(i.firstChild);else s=i;return(j.shadowroot||j.shadowrootmode)&&(s=de.call(r,s,!0)),s}let u=ke?i.outerHTML:i.innerHTML;return ke&&A[`!doctype`]&&i.ownerDocument&&i.ownerDocument.doctype&&i.ownerDocument.doctype.name&&$c(El,i.ownerDocument.doctype.name)&&(u=`<!DOCTYPE `+i.ownerDocument.doctype.name+`>
|
|
5
|
+
`+u),P&&(u=kt(u)),w&&Ie?E(u):u},t.setConfig=function(){let e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};ft(e),Ae=!0,je=A,Me=j},t.clearConfig=function(){lt=null,Ae=!1,je=null,Me=null,w=ne,te=``},t.isValidAttribute=function(e,t,n){lt||ft({});let r=F(e),i=F(t);return Vt(r,i,n)},t.addHook=function(e,t){typeof t==`function`&&Zc(O,e)&&Rc(O[e],t)},t.removeHook=function(e,t){if(Zc(O,e)){if(t!==void 0){let n=Ic(O[e],t);return n===-1?void 0:zc(O[e],n,1)[0]}return Lc(O[e])}},t.removeHooks=function(e){Zc(O,e)&&(O[e]=[])},t.removeAllHooks=function(){O=Rl()},t}var Hl=Vl();function Ul(){return{async:!1,breaks:!1,extensions:null,gfm:!0,hooks:null,pedantic:!1,renderer:null,silent:!1,tokenizer:null,walkTokens:null}}var Wl=Ul();function Gl(e){Wl=e}var Kl={exec:()=>null};function ql(e){let t=[];return n=>{let r=Math.max(0,Math.min(3,n-1)),i=t[r];return i||(i=e(r),t[r]=i),i}}function Z(e,t=``){let n=typeof e==`string`?e:e.source,r={replace:(e,t)=>{let i=typeof t==`string`?t:t.source;return i=i.replace(Yl.caret,`$1`),n=n.replace(e,i),r},getRegex:()=>new RegExp(n,t)};return r}var Jl=((e=``)=>{try{return!!RegExp(`(?<=1)(?<!1)`+e)}catch{return!1}})(),Yl={codeRemoveIndent:/^(?: {0,3}\t| {1,4})/gm,outputLinkReplace:/\\([\[\]])/g,indentCodeCompensation:/^(\s+)(?:```)/,beginningSpace:/^\s+/,endingHash:/#$/,startingSpaceChar:/^ /,endingSpaceChar:/ $/,endingSpaceTabChar:/[ \t]$/,nonSpaceChar:/[^ ]/,newLineCharGlobal:/\n/g,tabCharGlobal:/\t/g,leadingSpaceTab:/^[ \t]+/,multipleSpaceGlobal:/\s+/g,blankLine:/^[ \t]*$/,doubleBlankLine:/\n[ \t]*\n[ \t]*$/,blockquoteStart:/^ {0,3}>/,blockquoteSetextReplace:/\n {0,3}((?:=+|-+) *)(?=\n|$)/g,blockquoteSetextReplace2:/^ {0,3}>[ \t]?/gm,listReplaceNesting:/^ {1,4}(?=( {4})*[^ ])/g,listIsTask:/^\[[ xX]\] +\S/,listReplaceTask:/^\[[ xX]\] +/,listTaskCheckbox:/\[[ xX]\]/,anyLine:/\n.*\n/,hrefBrackets:/^<(.*)>$/,tableDelimiter:/[:|]/,tableAlignChars:/^\||\| *$/g,tableRowBlankLine:/\n[ \t]*$/,tableAlignRight:/^ *-+: *$/,tableAlignCenter:/^ *:-+: *$/,tableAlignLeft:/^ *:-+ *$/,startATag:/^<a /i,endATag:/^<\/a>/i,startPreScriptTag:/^<(pre|code|kbd|script)(\s|>)/i,endPreScriptTag:/^<\/(pre|code|kbd|script)(\s|>)/i,startAngleBracket:/^</,endAngleBracket:/>$/,pedanticHrefTitle:/^([^'"]*[^\s])\s+(['"])(.*)\2/,unicodeAlphaNumeric:/[\p{L}\p{N}]/u,numericCharacterReference:/&#(?:(\d{1,7})|[Xx]([A-Fa-f0-9]{1,6}));/g,escapeTest:/[&<>"']/,escapeReplace:/[&<>"']/g,escapeTestNoEncode:/[<>"']|&(?!(#\d{1,7}|#[Xx][a-fA-F0-9]{1,6}|\w+);)/,escapeReplaceNoEncode:/[<>"']|&(?!(#\d{1,7}|#[Xx][a-fA-F0-9]{1,6}|\w+);)/g,caret:/(^|[^\[])\^/g,percentDecode:/%25/g,findPipe:/\|/g,splitPipe:/ \|/,slashPipe:/\\\|/g,carriageReturn:/\r\n|\r/g,spaceLine:/^ +$/gm,notSpaceStart:/^\S*/,endingNewline:/\n$/,listItemRegex:e=>RegExp(`^( {0,3}${e})((?:[ ][^\\n]*)?(?:\\n|$))`),nextBulletRegex:ql(e=>RegExp(`^ {0,${e}}(?:[*+-]|\\d{1,9}[.)])((?:[ ][^\\n]*)?(?:\\n|$))`)),hrRegex:ql(e=>RegExp(`^ {0,${e}}((?:-[ ]*){3,}|(?:_[ ]*){3,}|(?:\\*[ ]*){3,})(?:\\n+|$)`)),fencesBeginRegex:ql(e=>RegExp(`^ {0,${e}}(?:\`\`\`|~~~)`)),headingBeginRegex:ql(e=>RegExp(`^ {0,${e}}#`)),htmlBeginRegex:ql(e=>RegExp(`^ {0,${e}}(?:</?(?:${uu})(?: +|$|/?>)|<(?:script|pre|style|textarea|!--))`,`i`)),blockquoteBeginRegex:ql(e=>RegExp(`^ {0,${e}}>`))},Xl=/^(?:[ \t]*(?:\n|$))+/,Zl=/^((?: {4}| {0,3}\t)[^\n]+(?:\n(?:[ \t]*(?:\n|$))*)?)+/,Ql=/^ {0,3}(`{3,}(?=[^`\n]*(?:\n|$))|~{3,})([^\n]*)(?:\n|$)(?:|([\s\S]*?)(?:\n|$))(?: {0,3}\1[~`]* *(?=\n|$)|$)/,$l=/^ {0,3}((?:-[\t ]*){3,}|(?:_[ \t]*){3,}|(?:\*[ \t]*){3,})(?:\n+|$)/,eu=/^ {0,3}(#{1,6})(?=\s|$)(.*)(?:\n+|$)/,tu=/ {0,3}(?:[*+-]|\d{1,9}[.)])/,nu=/^(?!bull |blockCode|fences|blockquote|heading|html|table)((?:.|\n(?!\s*?\n|bull |fences|blockquote|heading|hr|html|table))+?)\n {0,3}(=+|-+) *(?:\n+|$)/,ru=Z(nu).replace(/bull/g,tu).replace(/blockCode/g,/(?: {4}| {0,3}\t)/).replace(/fences/g,/ {0,3}(?:`{3,}|~{3,})/).replace(/blockquote/g,/ {0,3}>/).replace(/heading/g,/ {0,3}#{1,6}(?:\s|$)/).replace(/hr/g,/ {0,3}(?:(?:-[\t ]*){3,}|(?:_[ \t]*){3,}|(?:\*[ \t]*){3,})(?:\n+|$)/).replace(/html/g,/ {0,3}<[^\n>]+>\n/).replace(/\|table/g,``).getRegex(),iu=Z(nu).replace(/bull/g,tu).replace(/blockCode/g,/(?: {4}| {0,3}\t)/).replace(/fences/g,/ {0,3}(?:`{3,}|~{3,})/).replace(/blockquote/g,/ {0,3}>/).replace(/heading/g,/ {0,3}#{1,6}(?:\s|$)/).replace(/hr/g,/ {0,3}(?:(?:-[\t ]*){3,}|(?:_[ \t]*){3,}|(?:\*[ \t]*){3,})(?:\n+|$)/).replace(/html/g,/ {0,3}<[^\n>]+>\n/).replace(/table/g,/ {0,3}\|?(?:[:\- ]*\|)+[\:\- ]*\n/).getRegex(),au=/^([^\n]+(?:\n(?!hr|heading|lheading|blockquote|fences|list|html|table|[ \t]+\n)[^\n]+)*)/,ou=/^[^\n]+/,su=/(?!\s*\])(?:\\[\s\S]|[^\[\]\\])+/,cu=Z(/^ {0,3}\[(label)\]: *(?:\n[ \t]*)?([^<\s][^\s]*|<.*?>)(?:(?: +(?:\n[ \t]*)?| *\n[ \t]*)(title))? *(?:\n+|$)/).replace(`label`,su).replace(`title`,/(?:"(?:\\"?|[^"\\])*"|'[^'\n]*(?:\n[^'\n]+)*\n?'|\([^()]*\))/).getRegex(),lu=Z(/^(bull)([ \t][^\n]*?)?(?:\n|$)/).replace(/bull/g,tu).getRegex(),uu=`address|article|aside|base|basefont|blockquote|body|caption|center|col|colgroup|dd|details|dialog|dir|div|dl|dt|fieldset|figcaption|figure|footer|form|frame|frameset|h[1-6]|head|header|hr|html|iframe|legend|li|link|main|menu|menuitem|meta|nav|noframes|ol|optgroup|option|p|param|search|section|summary|table|tbody|td|tfoot|th|thead|title|tr|track|ul`,du=/<!--(?:-?>|[\s\S]*?(?:-->|$))/,fu=Z(`^ {0,3}(?:<(script|pre|style|textarea)[\\s>][\\s\\S]*?(?:</\\1>[^\\n]*\\n*|$)|comment[^\\n]*(\\n+|$)|<\\?[\\s\\S]*?(?:\\?>[^\\n]*\\n*|$)|<![A-Z][\\s\\S]*?(?:>[^\\n]*\\n*|$)|<!\\[CDATA\\[[\\s\\S]*?(?:\\]\\]>[^\\n]*\\n*|$)|</?(tag)(?: +|\\n|/?>)[\\s\\S]*?(?:(?:\\n[ ]*)+\\n|$)|<(?!script|pre|style|textarea)([a-z][a-z0-9-]*)(?:attribute)*? */?>(?=[ \\t]*(?:\\n|$))[\\s\\S]*?(?:(?:\\n[ ]*)+\\n|$)|</(?!script|pre|style|textarea)[a-z][a-z0-9-]*\\s*>(?=[ \\t]*(?:\\n|$))[\\s\\S]*?(?:(?:\\n[ ]*)+\\n|$))`,`i`).replace(`comment`,du).replace(`tag`,uu).replace(`attribute`,/ +[a-zA-Z:_][\w.:-]*(?: *= *"[^"\n]*"| *= *'[^'\n]*'| *= *[^\s"'=<>`]+)?/).getRegex(),pu=e=>Z(au).replace(`hr`,$l).replace(`heading`,` {0,3}#{1,6}(?:\\s|$)`).replace(`|lheading`,``).replace(`|table`,``).replace(`blockquote`,` {0,3}>`).replace(`fences`," {0,3}(?:`{3,}(?=[^`\\n]*(?:\\n|$))|~~~)[^\\n]*(?:\\n|$)").replace(`list`,e).replace(`html`,`</?(?:tag)(?: +|\\n|/?>)|<(?:script|pre|style|textarea|!--)`).replace(`tag`,uu).getRegex(),mu=pu(/ {0,3}(?:[*+-]|1[.)])[ \t]+[^ \t\n]/),hu=pu(/ {0,3}(?:[*+-]|\d{1,9}[.)])(?:[ \t]|\n|$)/),gu={blockquote:Z(/^( {0,3}> ?(paragraph|[^\n]*)(?:\n|$))+/).replace(`paragraph`,hu).getRegex(),code:Zl,def:cu,fences:Ql,heading:eu,hr:$l,html:fu,lheading:ru,list:lu,newline:Xl,paragraph:mu,table:Kl,text:ou},_u=Z(`^ *([^\\n ].*)\\n {0,3}((?:\\| *)?:?-+:? *(?:\\| *:?-+:? *)*(?:\\| *)?)(?:\\n((?:(?! *\\n|hr|heading|blockquote|code|fences|list|html).*(?:\\n|$))*)\\n*|$)`).replace(`hr`,$l).replace(`heading`,` {0,3}#{1,6}(?:\\s|$)`).replace(`blockquote`,` {0,3}>`).replace(`code`,`(?: {4}| {0,3} )[^\\n]`).replace(`fences`," {0,3}(?:`{3,}(?=[^`\\n]*(?:\\n|$))|~~~)[^\\n]*(?:\\n|$)").replace(`list`,` {0,3}(?:[*+-]|1[.)])[ \\t]`).replace(`html`,`</?(?:tag)(?: +|\\n|/?>)|<(?:script|pre|style|textarea|!--)`).replace(`tag`,uu).getRegex(),vu={...gu,lheading:iu,table:_u,paragraph:Z(au).replace(`hr`,$l).replace(`heading`,` {0,3}#{1,6}(?:\\s|$)`).replace(`|lheading`,``).replace(`table`,_u).replace(`blockquote`,` {0,3}>`).replace(`fences`," {0,3}(?:`{3,}(?=[^`\\n]*(?:\\n|$))|~~~)[^\\n]*(?:\\n|$)").replace(`list`,` {0,3}(?:[*+-]|1[.)])[ \\t]+[^ \\t\\n]`).replace(`html`,`</?(?:tag)(?: +|\\n|/?>)|<(?:script|pre|style|textarea|!--)`).replace(`tag`,uu).getRegex()},yu={...gu,html:Z(`^ *(?:comment *(?:\\n|\\s*$)|<(tag)[\\s\\S]+?</\\1> *(?:\\n{2,}|\\s*$)|<tag(?:"[^"]*"|'[^']*'|\\s[^'"/>\\s]*)*?/?> *(?:\\n{2,}|\\s*$))`).replace(`comment`,du).replace(/tag/g,`(?!(?:a|em|strong|small|s|cite|q|dfn|abbr|data|time|code|var|samp|kbd|sub|sup|i|b|u|mark|ruby|rt|rp|bdi|bdo|span|br|wbr|ins|del|img)\\b)\\w+(?!:|[^\\w\\s@]*@)\\b`).getRegex(),def:/^ *\[([^\]]+)\]: *<?([^\s>]+)>?(?: +(["(][^\n]+[")]))? *(?:\n+|$)/,heading:/^(#{1,6})(.*)(?:\n+|$)/,fences:Kl,lheading:/^(.+?)\n {0,3}(=+|-+) *(?:\n+|$)/,paragraph:Z(au).replace(`hr`,$l).replace(`heading`,` *#{1,6} *[^
|
|
6
|
+
]`).replace(`lheading`,ru).replace(`|table`,``).replace(`blockquote`,` {0,3}>`).replace(`|fences`,``).replace(`|list`,``).replace(`|html`,``).replace(`|tag`,``).getRegex()},bu=/^\\([!"#$%&'()*+,\-./:;<=>?@\[\]\\^_`{|}~])/,xu=/^(`+)([^`]|[^`][\s\S]*?[^`])\1(?!`)/,Su=/^( {2,}|\\)\n(?!\s*$)[ \t]*/,Cu=/^(`+|[^`])(?:(?= {2,}\n)|[\s\S]*?(?:(?=[\\<!\[`*_]|\b_|$)|[^ ](?= {2,}\n)))/,wu=/[\p{P}\p{S}]/u,Tu=/[\s\p{P}\p{S}]/u,Eu=/[^\s\p{P}\p{S}]/u,Du=Z(/^((?![*_])punctSpace)/,`u`).replace(/punctSpace/g,Tu).getRegex(),Ou=/[\p{Pi}\p{Ps}"']/u,ku=/(?!~)[\p{P}\p{S}]/u,Au=/(?!~)[\s\p{P}\p{S}]/u,ju=/(?:[^\s\p{P}\p{S}]|~)/u,Mu=Z(/link|precode-code|html/,`g`).replace(`link`,/\[(?:[^\[\]`]|(?<a>`+)[^`]+\k<a>(?!`))*?\]\((?:\\[\s\S]|[^\\\(\)]|\((?:\\[\s\S]|[^\\\(\)])*\))*\)/).replace(`precode-`,Jl?"(?<!`)()":"(^^|[^`])").replace(`code`,/(?<b>`+)[^`]+\k<b>(?!`)/).replace(`html`,/<(?! )[^<>]*?>/).getRegex(),Nu=/^(?:\*+(?:((?!\*)punct)|([^\s*]))?)|^_+(?:((?!_)punct)|([^\s_]))?/,Pu=Z(Nu,`u`).replace(/punct/g,wu).getRegex(),Fu=Z(Nu,`u`).replace(/punct/g,ku).getRegex(),Iu=Z(/^(?:\*+(?:((?!\*)(?!openQuote)punct)|([^\s*]))?)|^_+(?:((?!_)(?!openQuote)punct)|([^\s_]))?/,`u`).replace(/openQuote/g,Ou).replace(/punct/g,wu).getRegex(),Lu=`^[^_*]*?__[^_*]*?\\*[^_*]*?(?=__)|[^*]+(?=[^*])|(?!\\*)punct(\\*+)(?=[\\s]|$)|notPunctSpace(\\*+)(?!\\*)(?=punctSpace|$)|(?!\\*)punctSpace(\\*+)(?=notPunctSpace)|[\\s](\\*+)(?!\\*)(?=punct)|(?!\\*)punct(\\*+)(?!\\*)(?=punct)|notPunctSpace(\\*+)(?=notPunctSpace)`,Ru=Z(Lu,`gu`).replace(/notPunctSpace/g,Eu).replace(/punctSpace/g,Tu).replace(/punct/g,wu).getRegex(),zu=Z(Lu,`gu`).replace(/notPunctSpace/g,ju).replace(/punctSpace/g,Au).replace(/punct/g,ku).getRegex(),Bu=Z(`^[^_*]*?__[^_*]*?\\*[^_*]*?(?=__)|[^*]+(?=[^*])|(?!\\*)punct(\\*+)(?=[\\s]|$)|notPunctSpace(\\*+)(?!\\*)(?=punctSpace|$)|(?!\\*)[\\s](\\*+)(?=notPunctSpace)|[\\s](\\*+)(?!\\*)(?=punct)|(?!\\*)punct(\\*+)(?!\\*)(?=punct)|(?:(?!\\*)punct|notPunctSpace)(\\*+)(?!\\*)(?=notPunctSpace)`,`gu`).replace(/notPunctSpace/g,Eu).replace(/punctSpace/g,Tu).replace(/punct/g,wu).getRegex(),Vu=Z(`^[^_*]*?\\*\\*[^_*]*?_[^_*]*?(?=\\*\\*)|[^_]+(?=[^_])|(?!_)punct(_+)(?=[\\s]|$)|notPunctSpace(_+)(?!_)(?=punctSpace|$)|(?!_)punctSpace(_+)(?=notPunctSpace)|[\\s](_+)(?!_)(?=punct)|(?!_)punct(_+)(?!_)(?=punct)`,`gu`).replace(/notPunctSpace/g,Eu).replace(/punctSpace/g,Tu).replace(/punct/g,wu).getRegex(),Hu=Z(`^[^_*]*?\\*\\*[^_*]*?_[^_*]*?(?=\\*\\*)|[^_]+(?=[^_])|(?!_)punct(_+)(?=[\\s]|$)|notPunctSpace(_+)(?!_)(?=punctSpace|$)|(?!_)[\\s](_+)(?=notPunctSpace)|[\\s](_+)(?!_)(?=punct)|(?!_)punct(_+)(?!_)(?=punct)|(?:(?!_)punct|notPunctSpace)(_+)(?!_)(?=notPunctSpace)`,`gu`).replace(/notPunctSpace/g,Eu).replace(/punctSpace/g,Tu).replace(/punct/g,wu).getRegex(),Uu=Z(/^~~?(?:((?!~)punct)|[^\s~])/,`u`).replace(/punct/g,wu).getRegex(),Wu=Z(`^[^~]+(?=[^~])|(?!~)punct(~~?)(?=[\\s]|$)|notPunctSpace(~~?)(?!~)(?=punctSpace|$)|(?!~)punctSpace(~~?)(?=notPunctSpace)|[\\s](~~?)(?!~)(?=punct)|(?!~)punct(~~?)(?!~)(?=punct)|notPunctSpace(~~?)(?=notPunctSpace)`,`gu`).replace(/notPunctSpace/g,Eu).replace(/punctSpace/g,Tu).replace(/punct/g,wu).getRegex(),Gu=Z(/\\(punct)/,`gu`).replace(/punct/g,wu).getRegex(),Ku=Z(/^<(scheme:[^\s\x00-\x1f<>]*|email)>/).replace(`scheme`,/[a-zA-Z][a-zA-Z0-9+.-]{1,31}/).replace(`email`,/[a-zA-Z0-9.!#$%&'*+/=?^_`{|}~-]+(@)[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?(?:\.[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?)+(?![-_])/).getRegex(),qu=Z(du).replace(`(?:-->|$)`,`-->`).getRegex(),Ju=Z(`^comment|^</[a-zA-Z][a-zA-Z0-9-]*\\s*>|^<[a-zA-Z][a-zA-Z0-9-]*(?:attribute)*?\\s*/?>|^<\\?[\\s\\S]*?\\?>|^<![a-zA-Z]+\\s[\\s\\S]*?>|^<!\\[CDATA\\[[\\s\\S]*?\\]\\]>`).replace(`comment`,qu).replace(`attribute`,/\s+[a-zA-Z:_][\w.:-]*(?:\s*=\s*"[^"]*"|\s*=\s*'[^']*'|\s*=\s*[^\s"'=<>`]+)?/).getRegex(),Yu=/\[(?:\\[\s\S]|[^\[\]\\])*\]/,Xu=Z(/(?:\[(?:brackets|\\[\s\S]|[^\[\]\\])*\]|\\[\s\S]|`+(?!`)[^`]*?`+(?!`)|``+(?=\])|[^\[\]\\`])*?/).replace(`brackets`,Yu).getRegex(),Zu=Z(/^!?\[(label)\]\(\s*(href)(?:(?:[ \t]+(?:\n[ \t]*)?|\n[ \t]*)(title))?\s*\)/).replace(`label`,Xu).replace(`href`,/<(?:\\.|[^\n<>\\])+>|[^ \t\n\x00-\x1f]+|(?=\))/).replace(`title`,/"(?:\\"?|[^"\\])*"|'(?:\\'?|[^'\\])*'|\((?:\\\)?|[^)\\])*\)/).getRegex(),Qu=Z(/^!?\[(label)\]\[(ref)\]/).replace(`label`,Xu).replace(`ref`,su).getRegex(),$u=Z(/^!?\[(ref)\](?:\[\])?/).replace(`ref`,su).getRegex(),ed=/(?!\s*\])(?:\\[\s\S]|[^\[\]\\]){1,999}/,td=Z(/(?:[^\[\]\\`]*(?:\[(?:brackets|\\[\s\S]|[^\[\]\\])*\]|\\[\s\S]|`+(?!`)[^`]*?`+(?!`)|``+(?=\]))){0,999}?[^\[\]\\`]*?/).replace(`brackets`,Yu).getRegex(),nd=Z(`reflink|nolink(?!\\()`,`g`).replace(`reflink`,Z(/^!?\[(label)\]\[(ref)\]/).replace(`label`,td).replace(`ref`,ed).getRegex()).replace(`nolink`,Z(/^!?\[(ref)\](?:\[\])?/).replace(`ref`,ed).getRegex()).getRegex(),rd=/[hH][tT][tT][pP][sS]?|[fF][tT][pP]/,id=Z(/(?:mailto:email|xmpp:email(?:\/[A-Za-z0-9@.]+)?)/).replace(/email/g,/[A-Za-z0-9._+-]+@[a-zA-Z0-9-_]+(?:\.[a-zA-Z0-9-_]*[a-zA-Z0-9])+(?![\w-])/).getRegex(),ad={_backpedal:Kl,anyPunctuation:Gu,autolink:Ku,blockSkip:Mu,br:Su,code:xu,del:Kl,delLDelim:Kl,delRDelim:Kl,emStrongLDelim:Pu,emStrongRDelimAst:Ru,emStrongRDelimUnd:Vu,escape:bu,link:Zu,nolink:$u,punctuation:Du,reflink:Qu,reflinkSearch:nd,tag:Ju,text:Cu,url:Kl},od={...ad,emStrongLDelim:Iu,emStrongRDelimAst:Bu,emStrongRDelimUnd:Hu,link:Z(/^!?\[(label)\]\((.*?)\)/).replace(`label`,Xu).getRegex(),reflink:Z(/^!?\[(label)\]\s*\[([^\]]*)\]/).replace(`label`,Xu).getRegex()},sd={...ad,emStrongRDelimAst:zu,emStrongLDelim:Fu,delLDelim:Uu,delRDelim:Wu,url:Z(/^emailProtocol|^((?:protocol):\/\/|www\.)(?:[a-zA-Z0-9\-]+\.?)+[^\s<]*|^email/).replace(`emailProtocol`,id).replace(`protocol`,rd).replace(`email`,/[A-Za-z0-9._+-]+(@)[a-zA-Z0-9-_]+(?:\.[a-zA-Z0-9-_]*[a-zA-Z0-9])+(?![\w-])/).getRegex(),_backpedal:/(?:[^?!.,:;*_'"~()&]+|\([^)]*\)|&(?![a-zA-Z0-9]+;$)|[?!.,:;*_'"~)]+(?!$))+/,del:/^(~~?)(?=[^\s~])((?:\\[\s\S]|[^\\])*?(?:\\[\s\S]|[^\s~\\]))\1(?=[^~]|$)/,text:Z(/^(?:[^a-zA-Z0-9](?=emailProtocol)|(`+|~+|[^`~])(?:(?=[`~])|(?= {2,}\n)|(?=[a-zA-Z0-9.!#$%&'*+\/=?_`{\|}~-]+@)|[\s\S]*?(?:(?=[\\<!\[`*~_]|\b_|protocol:\/\/|www\.|$)|[^ ](?= {2,}\n)|[^a-zA-Z0-9](?=emailProtocol)|[^a-zA-Z0-9.!#$%&'*+\/=?_`{\|}~-](?=[a-zA-Z0-9.!#$%&'*+\/=?_`{\|}~-]+@))))/).replace(`protocol`,rd).replace(/emailProtocol/g,/(?:mailto|xmpp):/).getRegex()},cd={...sd,br:Z(Su).replace(`{2,}`,`*`).getRegex(),text:Z(sd.text).replace(`\\b_`,`\\b_| {2,}\\n`).replace(/\{2,\}/g,`*`).getRegex()},ld={normal:gu,gfm:vu,pedantic:yu},ud={normal:ad,gfm:sd,breaks:cd,pedantic:od},dd={"&":`&`,"<":`<`,">":`>`,'"':`"`,"'":`'`},fd=e=>dd[e];function pd(e,t){if(t){if(Yl.escapeTest.test(e))return e.replace(Yl.escapeReplace,fd)}else if(Yl.escapeTestNoEncode.test(e))return e.replace(Yl.escapeReplaceNoEncode,fd);return e}function md(e){return e.replace(Yl.numericCharacterReference,(e,t,n)=>{let r=t===void 0?Number.parseInt(n,16):Number.parseInt(t,10);return r===0||r>1114111||r>=55296&&r<=57343?`�`:String.fromCodePoint(r)})}function hd(e){try{e=encodeURI(e).replace(Yl.percentDecode,`%`)}catch{return null}return e}function gd(e,t){let n=e.replace(Yl.findPipe,(e,t,n)=>{let r=!1,i=t;for(;--i>=0&&n[i]===`\\`;)r=!r;return r?`|`:` |`}).split(Yl.splitPipe),r=0;if(n[0].trim()||n.shift(),n.length>0&&!n.at(-1)?.trim()&&n.pop(),t){if(n.length>t)n.splice(t);else for(;n.length<t;)n.push(``)}for(;r<n.length;r++)n[r]=n[r].trim().replace(Yl.slashPipe,`|`);return n}function _d(e,t,n){let r=e.length;if(r===0)return``;let i=0;for(;i<r;){let a=e.charAt(r-i-1);if(a===t&&!n)i++;else if(a!==t&&n)i++;else break}return e.slice(0,r-i)}function vd(e){let t=e.split(`
|
|
7
|
+
`),n=t.length-1;for(;n>=0&&Yl.blankLine.test(t[n]);)n--;return t.length-n<=2?e:t.slice(0,n+1).join(`
|
|
8
|
+
`)}function yd(e){return e.trim().toLowerCase().toUpperCase().toLowerCase()}function bd(e,t){if(e.indexOf(t[1])===-1)return-1;let n=0;for(let r=0;r<e.length;r++)if(e[r]===`\\`)r++;else if(e[r]===t[0])n++;else if(e[r]===t[1]&&(n--,n<0))return r;return n>0?-2:-1}function xd(e,t=0){let n=t,r=``;for(let t of e)if(t===` `){let e=4-n%4;r+=` `.repeat(e),n+=e}else r+=t,n++;return r}function Sd(e,t,n,r,i){let a=t.href,o=t.title||null,s=e[1].replace(i.other.outputLinkReplace,`$1`),c=e[0].charAt(0)===`!`;r.state.inLink=!0;let l=r.state.linkEmitted,u=r.state.inRawBlock;r.state.linkEmitted=!1;let d=r.inlineTokens(s),f=r.state.linkEmitted;if(r.state.linkEmitted=l,r.state.inLink=!1,!c){if(f){r.state.inRawBlock=u;return}r.state.linkEmitted=!0}return{type:c?`image`:`link`,raw:n,href:a,title:o,text:s,tokens:d}}function Cd(e,t,n){let r=e.match(n.other.indentCodeCompensation);if(r===null)return t;let i=r[1];return t.split(`
|
|
9
9
|
`).map(e=>{let t=e.match(n.other.beginningSpace);if(t===null)return e;let[r]=t;return e.slice(Math.min(r.length,i.length))}).join(`
|
|
10
|
-
`)}function
|
|
11
|
-
`),depth:t[1].length,text:e,tokens:this.lexer.inline(e)}}}hr(e){let t=this.rules.block.hr.exec(e);if(t)return{type:`hr`,raw:
|
|
12
|
-
`)}}blockquote(e){let t=this.rules.block.blockquote.exec(e);if(t){let e=
|
|
10
|
+
`)}function wd(e,t,n,r){if(!t.includes(`<`))return!1;for(let i=0;i<t.length;i++){if(t[i]===`\\`){i++;continue}if(t[i]==="`"){let e=r.inline.code.exec(t.slice(i));if(e){i+=e[0].length-1;continue}}if(t[i]!==`<`)continue;let a=e.slice(n+i),o=r.inline.tag.exec(a)||r.inline.autolink.exec(a);if(o){if(o[0].length>t.length-i)return!0;i+=o[0].length-1}}return!1}var Td=class{options;rules;lexer;constructor(e){this.options=e||Wl}space(e){let t=this.rules.block.newline.exec(e);if(t&&t[0].length>0)return{type:`space`,raw:t[0]}}code(e){let t=this.rules.block.code.exec(e);if(t){let e=this.options.pedantic?t[0]:vd(t[0]);return{type:`code`,raw:e,codeBlockStyle:`indented`,text:e.replace(this.rules.other.codeRemoveIndent,``)}}}fences(e){let t=this.rules.block.fences.exec(e);if(t){let e=t[0],n=Cd(e,t[3]||``,this.rules);return{type:`code`,raw:e,lang:t[2]?t[2].trim().replace(this.rules.inline.anyPunctuation,`$1`):t[2],text:n}}}heading(e){let t=this.rules.block.heading.exec(e);if(t){let e=t[2].trim();if(this.rules.other.endingHash.test(e)){let t=_d(e,`#`);(this.options.pedantic||!t||this.rules.other.endingSpaceTabChar.test(t))&&(e=t.trim())}return{type:`heading`,raw:_d(t[0],`
|
|
11
|
+
`),depth:t[1].length,text:e,tokens:this.lexer.inline(e)}}}hr(e){let t=this.rules.block.hr.exec(e);if(t)return{type:`hr`,raw:_d(t[0],`
|
|
12
|
+
`)}}blockquote(e){let t=this.rules.block.blockquote.exec(e);if(t){let e=_d(t[0],`
|
|
13
13
|
`).split(`
|
|
14
14
|
`),n=``,r=``,i=[];for(;e.length>0;){let t=!1,a=[],o=0;for(;o<e.length;o++)if(this.rules.other.blockquoteStart.test(e[o]))a.push(e[o]),t=!0;else if(!t)a.push(e[o]);else break;e=e.slice(o);let s=a.join(`
|
|
15
15
|
`),c=s.replace(this.rules.other.blockquoteSetextReplace,`
|
|
@@ -24,19 +24,19 @@ ${d.join(`
|
|
|
24
24
|
`+e.join(`
|
|
25
25
|
`),o=this.list(a);i[i.length-1]=o,n=n.substring(0,n.length-u.raw.length)+o.raw,r=r.substring(0,r.length-t.raw.length)+o.raw,e=a.substring(i.at(-1).raw.length).split(`
|
|
26
26
|
`);continue}}return{type:`blockquote`,raw:n,tokens:i,text:r}}}list(e){let t=this.rules.block.list.exec(e);if(t){let n=t[1].trim(),r=n.length>1,i={type:`list`,raw:``,ordered:r,start:r?+n.slice(0,-1):``,loose:!1,items:[]};n=r?`\\d{1,9}\\${n.slice(-1)}`:`\\${n}`,this.options.pedantic&&(n=r?n:`[*+-]`);let a=this.rules.other.listItemRegex(n),o=!1;for(;e;){let n=!1,r=``,s=``;if(!(t=a.exec(e))||this.rules.block.hr.test(e))break;r=t[0],e=e.substring(r.length);let c=t[2].split(`
|
|
27
|
-
`,1)[0],l=t[1].length,u=this.options.pedantic?
|
|
27
|
+
`,1)[0],l=t[1].length,u=this.options.pedantic?xd(c,l):c.replace(this.rules.other.leadingSpaceTab,e=>xd(e,l)),d=e.split(`
|
|
28
28
|
`,1)[0],f=!u.trim(),p=0;if(this.options.pedantic?(p=2,s=u.trimStart()):f?p=l+1:(p=u.search(this.rules.other.nonSpaceChar),p=p>4?1:p,s=u.slice(p),p+=l),f&&this.rules.other.blankLine.test(d)&&(r+=d+`
|
|
29
29
|
`,e=e.substring(d.length+1),n=!0),!n){let t=this.rules.other.nextBulletRegex(p),n=this.rules.other.hrRegex(p),i=this.rules.other.fencesBeginRegex(p),a=this.rules.other.headingBeginRegex(p),o=this.rules.other.htmlBeginRegex(p),c=this.rules.other.blockquoteBeginRegex(p);for(;e;){let l=e.split(`
|
|
30
30
|
`,1)[0],m;if(d=l,this.options.pedantic?(d=d.replace(this.rules.other.listReplaceNesting,` `),m=d):m=d.replace(this.rules.other.leadingSpaceTab,e=>e.replace(this.rules.other.tabCharGlobal,` `)),i.test(d)||a.test(d)||o.test(d)||c.test(d)||t.test(d)||n.test(d))break;if(m.search(this.rules.other.nonSpaceChar)>=p||!d.trim())s+=`
|
|
31
31
|
`+m.slice(p);else{if(f||u.replace(this.rules.other.tabCharGlobal,` `).search(this.rules.other.nonSpaceChar)>=4||i.test(u)||a.test(u)||n.test(u))break;s+=`
|
|
32
32
|
`+d}f=!d.trim(),r+=l+`
|
|
33
|
-
`,e=e.substring(l.length+1),u=m.slice(p)}}i.loose||(o?i.loose=!0:this.rules.other.doubleBlankLine.test(r)&&(o=!0)),i.items.push({type:`list_item`,raw:r,task:!!this.options.gfm&&this.rules.other.listIsTask.test(s),loose:!1,text:s,tokens:[]}),i.raw+=r}let s=i.items.at(-1);if(s)s.raw=s.raw.trimEnd(),s.text=s.text.trimEnd();else return;i.raw=i.raw.trimEnd();for(let e of i.items)if(this.lexer.state.top=!1,e.tokens=this.lexer.blockTokens(e.text,[]),!i.loose){let t=e.tokens.filter(e=>e.type===`space`);i.loose=t.length>0&&t.some(e=>this.rules.other.anyLine.test(e.raw))}for(let e of i.items){let t=e.tokens[0];if(e.task&&(t?.type===`text`||t?.type===`paragraph`)){e.text=e.text.replace(this.rules.other.listReplaceTask,``),t.raw=t.raw.replace(this.rules.other.listReplaceTask,``),t.text=t.text.replace(this.rules.other.listReplaceTask,``);for(let e=this.lexer.inlineQueue.length-1;e>=0;e--)if(this.rules.other.listIsTask.test(this.lexer.inlineQueue[e].src)){this.lexer.inlineQueue[e].src=this.lexer.inlineQueue[e].src.replace(this.rules.other.listReplaceTask,``);break}let n=this.rules.other.listTaskCheckbox.exec(e.raw);if(n){let t={type:`checkbox`,raw:n[0]+` `,checked:n[0]!==`[ ]`};e.checked=t.checked,i.loose?e.tokens[0]&&[`paragraph`,`text`].includes(e.tokens[0].type)&&`tokens`in e.tokens[0]&&e.tokens[0].tokens?(e.tokens[0].raw=t.raw+e.tokens[0].raw,e.tokens[0].text=t.raw+e.tokens[0].text,e.tokens[0].tokens.unshift(t)):e.tokens.unshift({type:`paragraph`,raw:t.raw,text:t.raw,tokens:[t]}):e.tokens.unshift(t)}}else e.task&&=!1}if(i.loose)for(let e of i.items){e.loose=!0;for(let t of e.tokens)t.type===`text`&&(t.type=`paragraph`)}return i}}html(e){let t=this.rules.block.html.exec(e);if(t){let e=
|
|
34
|
-
`),href:n,title:r}}}table(e){let t=this.rules.block.table.exec(e);if(!t||!this.rules.other.tableDelimiter.test(t[2]))return;let n=
|
|
35
|
-
`):[],a={type:`table`,raw:
|
|
36
|
-
`),header:[],align:[],rows:[]};if(n.length===r.length){for(let e of r)this.rules.other.tableAlignRight.test(e)?a.align.push(`right`):this.rules.other.tableAlignCenter.test(e)?a.align.push(`center`):this.rules.other.tableAlignLeft.test(e)?a.align.push(`left`):a.align.push(null);for(let e=0;e<n.length;e++)a.header.push({text:n[e],tokens:this.lexer.inline(n[e]),header:!0,align:a.align[e]});for(let e of i)a.rows.push(
|
|
33
|
+
`,e=e.substring(l.length+1),u=m.slice(p)}}i.loose||(o?i.loose=!0:this.rules.other.doubleBlankLine.test(r)&&(o=!0)),i.items.push({type:`list_item`,raw:r,task:!!this.options.gfm&&this.rules.other.listIsTask.test(s),loose:!1,text:s,tokens:[]}),i.raw+=r}let s=i.items.at(-1);if(s)s.raw=s.raw.trimEnd(),s.text=s.text.trimEnd();else return;i.raw=i.raw.trimEnd();for(let e of i.items)if(this.lexer.state.top=!1,e.tokens=this.lexer.blockTokens(e.text,[]),!i.loose){let t=e.tokens.filter(e=>e.type===`space`);i.loose=t.length>0&&t.some(e=>this.rules.other.anyLine.test(e.raw))}for(let e of i.items){let t=e.tokens[0];if(e.task&&(t?.type===`text`||t?.type===`paragraph`)){e.text=e.text.replace(this.rules.other.listReplaceTask,``),t.raw=t.raw.replace(this.rules.other.listReplaceTask,``),t.text=t.text.replace(this.rules.other.listReplaceTask,``);for(let e=this.lexer.inlineQueue.length-1;e>=0;e--)if(this.rules.other.listIsTask.test(this.lexer.inlineQueue[e].src)){this.lexer.inlineQueue[e].src=this.lexer.inlineQueue[e].src.replace(this.rules.other.listReplaceTask,``);break}let n=this.rules.other.listTaskCheckbox.exec(e.raw);if(n){let t={type:`checkbox`,raw:n[0]+` `,checked:n[0]!==`[ ]`};e.checked=t.checked,i.loose?e.tokens[0]&&[`paragraph`,`text`].includes(e.tokens[0].type)&&`tokens`in e.tokens[0]&&e.tokens[0].tokens?(e.tokens[0].raw=t.raw+e.tokens[0].raw,e.tokens[0].text=t.raw+e.tokens[0].text,e.tokens[0].tokens.unshift(t)):e.tokens.unshift({type:`paragraph`,raw:t.raw,text:t.raw,tokens:[t]}):e.tokens.unshift(t)}}else e.task&&=!1}if(i.loose)for(let e of i.items){e.loose=!0;for(let t of e.tokens)t.type===`text`&&(t.type=`paragraph`)}return i}}html(e){let t=this.rules.block.html.exec(e);if(t){let e=vd(t[0]);return{type:`html`,block:!0,raw:e,pre:t[1]===`pre`||t[1]===`script`||t[1]===`style`,text:e}}}def(e){let t=this.rules.block.def.exec(e);if(t){let e=yd(t[1]).replace(this.rules.other.multipleSpaceGlobal,` `),n=t[2]?t[2].replace(this.rules.other.hrefBrackets,`$1`).replace(this.rules.inline.anyPunctuation,`$1`):``,r=t[3]?t[3].substring(1,t[3].length-1).replace(this.rules.inline.anyPunctuation,`$1`):t[3];return{type:`def`,tag:e,raw:_d(t[0],`
|
|
34
|
+
`),href:n,title:r}}}table(e){let t=this.rules.block.table.exec(e);if(!t||!this.rules.other.tableDelimiter.test(t[2]))return;let n=gd(t[1]),r=t[2].replace(this.rules.other.tableAlignChars,``).split(`|`),i=t[3]?.trim()?t[3].replace(this.rules.other.tableRowBlankLine,``).split(`
|
|
35
|
+
`):[],a={type:`table`,raw:_d(t[0],`
|
|
36
|
+
`),header:[],align:[],rows:[]};if(n.length===r.length){for(let e of r)this.rules.other.tableAlignRight.test(e)?a.align.push(`right`):this.rules.other.tableAlignCenter.test(e)?a.align.push(`center`):this.rules.other.tableAlignLeft.test(e)?a.align.push(`left`):a.align.push(null);for(let e=0;e<n.length;e++)a.header.push({text:n[e],tokens:this.lexer.inline(n[e]),header:!0,align:a.align[e]});for(let e of i)a.rows.push(gd(e,a.header.length).map((e,t)=>({text:e,tokens:this.lexer.inline(e),header:!1,align:a.align[t]})));return a}}lheading(e){let t=this.rules.block.lheading.exec(e);if(t){let e=t[1].trim();return{type:`heading`,raw:_d(t[0],`
|
|
37
37
|
`),depth:t[2].charAt(0)===`=`?1:2,text:e,tokens:this.lexer.inline(e)}}}paragraph(e){let t=this.rules.block.paragraph.exec(e);if(t){let e=t[1].charAt(t[1].length-1)===`
|
|
38
|
-
`?t[1].slice(0,-1):t[1];return{type:`paragraph`,raw:t[0],text:e,tokens:this.lexer.inline(e)}}}text(e){let t=this.rules.block.text.exec(e);if(t)return{type:`text`,raw:t[0],text:t[0],tokens:this.lexer.inline(t[0])}}escape(e){let t=this.rules.inline.escape.exec(e);if(t)return{type:`escape`,raw:t[0],text:t[1]}}tag(e){let t=this.rules.inline.tag.exec(e);if(t)return!this.lexer.state.inLink&&this.rules.other.startATag.test(t[0])?this.lexer.state.inLink=!0:this.lexer.state.inLink&&this.rules.other.endATag.test(t[0])&&(this.lexer.state.inLink=!1),!this.lexer.state.inRawBlock&&this.rules.other.startPreScriptTag.test(t[0])?this.lexer.state.inRawBlock=!0:this.lexer.state.inRawBlock&&this.rules.other.endPreScriptTag.test(t[0])&&(this.lexer.state.inRawBlock=!1),{type:`html`,raw:t[0],inLink:this.lexer.state.inLink,inRawBlock:this.lexer.state.inRawBlock,block:!1,text:t[0]}}link(e){let t=this.rules.inline.link.exec(e);if(t){let n=t[0].charAt(0)===`!`?2:1;if(!this.options.pedantic&&
|
|
39
|
-
`),this.blockTokens(e,this.tokens);for(let e=0;e<this.inlineQueue.length;e++){let t=this.inlineQueue[e];this.inlineTokens(t.src,t.tokens)}return this.inlineQueue=[],this.tokens}blockTokens(e,t=[],n=!1){this.tokenizer.lexer=this,this.options.pedantic&&(e=e.replace(
|
|
38
|
+
`?t[1].slice(0,-1):t[1];return{type:`paragraph`,raw:t[0],text:e,tokens:this.lexer.inline(e)}}}text(e){let t=this.rules.block.text.exec(e);if(t)return{type:`text`,raw:t[0],text:t[0],tokens:this.lexer.inline(t[0])}}escape(e){let t=this.rules.inline.escape.exec(e);if(t)return{type:`escape`,raw:t[0],text:t[1]}}tag(e){let t=this.rules.inline.tag.exec(e);if(t)return!this.lexer.state.inLink&&this.rules.other.startATag.test(t[0])?this.lexer.state.inLink=!0:this.lexer.state.inLink&&this.rules.other.endATag.test(t[0])&&(this.lexer.state.inLink=!1),!this.lexer.state.inRawBlock&&this.rules.other.startPreScriptTag.test(t[0])?this.lexer.state.inRawBlock=!0:this.lexer.state.inRawBlock&&this.rules.other.endPreScriptTag.test(t[0])&&(this.lexer.state.inRawBlock=!1),{type:`html`,raw:t[0],inLink:this.lexer.state.inLink,inRawBlock:this.lexer.state.inRawBlock,block:!1,text:t[0]}}link(e){let t=this.rules.inline.link.exec(e);if(t){let n=t[0].charAt(0)===`!`?2:1;if(!this.options.pedantic&&wd(e,t[1],n,this.rules))return;let r=t[2].trim();if(!this.options.pedantic&&this.rules.other.startAngleBracket.test(r)){if(!this.rules.other.endAngleBracket.test(r))return;let e=_d(r.slice(0,-1),`\\`);if((r.length-e.length)%2==0)return}else{let e=bd(t[2],`()`);if(e===-2)return;if(e>-1){let n=(t[0].indexOf(`!`)===0?5:4)+t[1].length+e;t[2]=t[2].substring(0,e),t[0]=t[0].substring(0,n).trim(),t[3]=``}}let i=t[2],a=``;if(this.options.pedantic){let e=this.rules.other.pedanticHrefTitle.exec(i);e&&(i=e[1],a=e[3])}else a=t[3]?t[3].slice(1,-1):``;return i=i.trim(),this.rules.other.startAngleBracket.test(i)&&(i=this.options.pedantic&&!this.rules.other.endAngleBracket.test(r)?i.slice(1):i.slice(1,-1)),Sd(t,{href:i&&i.replace(this.rules.inline.anyPunctuation,`$1`),title:a&&a.replace(this.rules.inline.anyPunctuation,`$1`)},t[0],this.lexer,this.rules)}}reflink(e,t){let n;if((n=this.rules.inline.reflink.exec(e))||(n=this.rules.inline.nolink.exec(e))){let r=n[0].charAt(0)===`!`?2:1;if(!this.options.pedantic&&wd(e,n[1],r,this.rules))return;let i=t[yd((n[2]||n[1]).replace(this.rules.other.multipleSpaceGlobal,` `))];if(!i){let e=n[0].charAt(0);return{type:`text`,raw:e,text:e}}return Sd(n,i,n[0],this.lexer,this.rules)}}emStrong(e,t,n=``){let r=this.rules.inline.emStrongLDelim.exec(e);if(!(!r||!r[1]&&!r[2]&&!r[3]&&!r[4]||r[4]&&n.match(this.rules.other.unicodeAlphaNumeric))&&(!(r[1]||r[3])||!n||this.rules.inline.punctuation.exec(n))){let i=[...r[0]].length-1,a,o,s=i,c=0,l=r[0][0],u=n===l,d=l===`*`?this.rules.inline.emStrongRDelimAst:this.rules.inline.emStrongRDelimUnd;for(d.lastIndex=0,t=t.slice(-1*e.length+i);(r=d.exec(t))!==null;){if(a=r[1]||r[2]||r[3]||r[4]||r[5]||r[6],!a)continue;if(o=[...a].length,r[3]||r[4]){s+=o;continue}if(r[5]||r[6]){if(i%3&&!((i+o)%3)){c+=o;continue}if(u)break}if(s-=o,s>0)continue;o=Math.min(o,o+s+c);let t=[...r[0]][0].length,n=e.slice(0,i+r.index+t+o);if(Math.min(i,o)%2){let e=n.slice(1,-1);return{type:`em`,raw:n,text:e,tokens:this.lexer.inlineTokens(e)}}let l=n.slice(2,-2);return{type:`strong`,raw:n,text:l,tokens:this.lexer.inlineTokens(l)}}}}codespan(e){let t=this.rules.inline.code.exec(e);if(t){let e=t[2].replace(this.rules.other.newLineCharGlobal,` `),n=this.rules.other.nonSpaceChar.test(e),r=this.rules.other.startingSpaceChar.test(e)&&this.rules.other.endingSpaceChar.test(e);return n&&r&&(e=e.substring(1,e.length-1)),{type:`codespan`,raw:t[0],text:e}}}br(e){let t=this.rules.inline.br.exec(e);if(t)return{type:`br`,raw:t[0]}}del(e,t,n=``){let r=this.rules.inline.delLDelim.exec(e);if(r&&(!r[1]||!n||this.rules.inline.punctuation.exec(n))){let n=[...r[0]].length-1,i,a,o=n,s=this.rules.inline.delRDelim;for(s.lastIndex=0,t=t.slice(-1*e.length+n);(r=s.exec(t))!==null;){if(i=r[1]||r[2]||r[3]||r[4]||r[5]||r[6],!i||(a=[...i].length,a!==n))continue;if(r[3]||r[4]){o+=a;continue}if(o-=a,o>0)continue;a=Math.min(a,a+o);let t=[...r[0]][0].length,s=e.slice(0,n+r.index+t+a),c=s.slice(n,-n);return{type:`del`,raw:s,text:c,tokens:this.lexer.inlineTokens(c)}}}}autolink(e){let t=this.rules.inline.autolink.exec(e);if(t){let e,n;return t[2]===`@`?(e=t[1],n=`mailto:`+e):(e=t[1],n=e),{type:`link`,raw:t[0],text:e,href:n,autolink:!0,tokens:[{type:`text`,raw:e,text:e}]}}}url(e){let t;if(t=this.rules.inline.url.exec(e)){let e,n;if(t[2]===`@`)e=t[0],n=`mailto:`+e;else{let r;do r=t[0],t[0]=this.rules.inline._backpedal.exec(t[0])?.[0]??``;while(r!==t[0]);e=t[0],n=t[1]===`www.`?`http://`+t[0]:t[0]}return{type:`link`,raw:t[0],text:e,href:n,autolink:!0,tokens:[{type:`text`,raw:e,text:e}]}}}inlineText(e){let t=this.rules.inline.text.exec(e);if(t){let e=this.lexer.state.inRawBlock;return{type:`text`,raw:t[0],text:e?t[0]:md(t[0]),escaped:e}}}},Ed=class e{tokens;options;state;inlineQueue;tokenizer;constructor(e){this.tokens=[],this.tokens.links=Object.create(null),this.options=e||Wl,this.options.tokenizer=this.options.tokenizer||new Td,this.tokenizer=this.options.tokenizer,this.tokenizer.options=this.options,this.tokenizer.lexer=this,this.inlineQueue=[],this.state={inLink:!1,inRawBlock:!1,linkEmitted:!1,top:!0};let t={other:Yl,block:ld.normal,inline:ud.normal};this.options.pedantic?(t.block=ld.pedantic,t.inline=ud.pedantic):this.options.gfm&&(t.block=ld.gfm,t.inline=this.options.breaks?ud.breaks:ud.gfm),this.tokenizer.rules=t}static get rules(){return{block:ld,inline:ud}}static lex(t,n){return new e(n).lex(t)}static lexInline(t,n){return new e(n).inlineTokens(t)}lex(e){e=e.replace(Yl.carriageReturn,`
|
|
39
|
+
`),this.blockTokens(e,this.tokens);for(let e=0;e<this.inlineQueue.length;e++){let t=this.inlineQueue[e];this.inlineTokens(t.src,t.tokens)}return this.inlineQueue=[],this.tokens}blockTokens(e,t=[],n=!1){this.tokenizer.lexer=this,this.options.pedantic&&(e=e.replace(Yl.tabCharGlobal,` `).replace(Yl.spaceLine,``));let r=1/0;for(;e;){if(e.length<r)r=e.length;else{this.infiniteLoopError(e.charCodeAt(0));break}let i;if(this.options.extensions?.block?.some(n=>(i=n.call({lexer:this},e,t))?(e=e.substring(i.raw.length),t.push(i),!0):!1))continue;if(i=this.tokenizer.space(e)){e=e.substring(i.raw.length);let n=t.at(-1);i.raw.length===1&&n!==void 0?n.raw+=`
|
|
40
40
|
`:t.push(i);continue}if(i=this.tokenizer.code(e)){e=e.substring(i.raw.length);let n=t.at(-1);n?.type===`paragraph`||n?.type===`text`?(n.raw+=(n.raw.endsWith(`
|
|
41
41
|
`)?``:`
|
|
42
42
|
`)+i.raw,n.text+=`
|
|
@@ -49,9 +49,9 @@ ${d.join(`
|
|
|
49
49
|
`+i.text,this.inlineQueue.pop(),this.inlineQueue.at(-1).src=r.text):t.push(i),n=a.length!==e.length,e=e.substring(i.raw.length);continue}if(i=this.tokenizer.text(e)){e=e.substring(i.raw.length);let n=t.at(-1);n?.type===`text`?(n.raw+=(n.raw.endsWith(`
|
|
50
50
|
`)?``:`
|
|
51
51
|
`)+i.raw,n.text+=`
|
|
52
|
-
`+i.text,this.inlineQueue.pop(),this.inlineQueue.at(-1).src=n.text):t.push(i);continue}if(e){this.infiniteLoopError(e.charCodeAt(0));break}}return this.state.top=!0,t}inline(e,t=[]){return this.inlineQueue.push({src:e,tokens:t}),t}linkInText(e){if(!e.includes(`[`))return!1;let t=this.tokenizer.rules.inline.link;for(let n of e.matchAll(this.tokenizer.rules.inline.blockSkip))if(t.test(n[0])&&e.charAt(n.index-1)!==`!`)return!0;for(let t of e.matchAll(this.tokenizer.rules.inline.reflinkSearch)){let e=t[0],n=e.lastIndexOf(`[`);if(e.charAt(0)!==`!`&&Object.hasOwn(this.tokens.links,
|
|
53
|
-
`:``;return r?`<pre><code class="language-`+
|
|
54
|
-
`:`<pre><code>`+(n?i:
|
|
52
|
+
`+i.text,this.inlineQueue.pop(),this.inlineQueue.at(-1).src=n.text):t.push(i);continue}if(e){this.infiniteLoopError(e.charCodeAt(0));break}}return this.state.top=!0,t}inline(e,t=[]){return this.inlineQueue.push({src:e,tokens:t}),t}linkInText(e){if(!e.includes(`[`))return!1;let t=this.tokenizer.rules.inline.link;for(let n of e.matchAll(this.tokenizer.rules.inline.blockSkip))if(t.test(n[0])&&e.charAt(n.index-1)!==`!`)return!0;for(let t of e.matchAll(this.tokenizer.rules.inline.reflinkSearch)){let e=t[0],n=e.lastIndexOf(`[`);if(e.charAt(0)!==`!`&&Object.hasOwn(this.tokens.links,yd(e.slice(n+1,-1)))&&!(n>1&&this.linkInText(e.slice(1,n-1))))return!0}return!1}inlineTokens(e,t=[]){this.tokenizer.lexer=this;let n=e;if(this.tokens.links&&e.includes(`[`)){let e=this.tokenizer.rules.inline.reflinkSearch,t=n=>{let r=n.lastIndexOf(`[`);if(!Object.hasOwn(this.tokens.links,yd(n.slice(r+1,-1))))return n;if(r>1&&n.charAt(0)!==`!`){let i=n.slice(1,r-1);if(this.linkInText(i))return`[`+i.replace(e,t)+`][`+`a`.repeat(n.length-r-2)+`]`}return`[`+`a`.repeat(n.length-2)+`]`};n=n.replace(e,t)}n=n.replace(this.tokenizer.rules.inline.anyPunctuation,e=>`+`.repeat(e.length)),n=n.replace(this.tokenizer.rules.inline.blockSkip,(e,t,n)=>{let r=n?n.length:0;return e.slice(0,r)+`[`+`a`.repeat(e.length-r-2)+`]`}),n=this.options.hooks?.emStrongMask?.call({lexer:this},n)??n;let r=!1,i=``,a=1/0;for(;e;){if(e.length<a)a=e.length;else{this.infiniteLoopError(e.charCodeAt(0));break}r||(i=``),r=!1;let o;if(this.options.extensions?.inline?.some(n=>(o=n.call({lexer:this},e,t))?(e=e.substring(o.raw.length),t.push(o),!0):!1))continue;if(o=this.tokenizer.escape(e)){e=e.substring(o.raw.length),t.push(o);continue}if(o=this.tokenizer.tag(e)){e=e.substring(o.raw.length),t.push(o);continue}if(o=this.tokenizer.link(e)){e=e.substring(o.raw.length),t.push(o);continue}if(o=this.tokenizer.reflink(e,this.tokens.links)){e=e.substring(o.raw.length);let n=t.at(-1);o.type===`text`&&n?.type===`text`?(n.raw+=o.raw,n.text+=o.text):t.push(o);continue}if(o=this.tokenizer.emStrong(e,n,i)){e=e.substring(o.raw.length),t.push(o);continue}if(o=this.tokenizer.codespan(e)){e=e.substring(o.raw.length),t.push(o);continue}if(o=this.tokenizer.br(e)){e=e.substring(o.raw.length),t.push(o);continue}if(o=this.tokenizer.del(e,n,i)){e=e.substring(o.raw.length),t.push(o);continue}if(o=this.tokenizer.autolink(e)){e=e.substring(o.raw.length),t.push(o);continue}if(!this.state.inLink&&(o=this.tokenizer.url(e))){e=e.substring(o.raw.length),t.push(o);continue}let s=e;if(this.options.extensions?.startInline){let t=1/0,n=e.slice(1),r;this.options.extensions.startInline.forEach(e=>{r=e.call({lexer:this},n),typeof r==`number`&&r>=0&&(t=Math.min(t,r))}),t<1/0&&t>=0&&(s=e.substring(0,t+1))}if(o=this.tokenizer.inlineText(s)){e=e.substring(o.raw.length),o.raw.slice(-1)!==`_`&&(i=o.raw.slice(-1)),r=!0;let n=t.at(-1);n?.type===`text`?(n.raw+=o.raw,n.text+=o.text):t.push(o);continue}if(e){this.infiniteLoopError(e.charCodeAt(0));break}}return t}infiniteLoopError(e){let t=`Infinite loop on byte: `+e;if(this.options.silent)console.error(t);else throw Error(t)}},Dd=class{options;parser;constructor(e){this.options=e||Wl}space(e){return``}code({text:e,lang:t,escaped:n}){let r=(t||``).match(Yl.notSpaceStart)?.[0],i=e?e.replace(Yl.endingNewline,``)+`
|
|
53
|
+
`:``;return r?`<pre><code class="language-`+pd(r)+`">`+(n?i:pd(i,!0))+`</code></pre>
|
|
54
|
+
`:`<pre><code>`+(n?i:pd(i,!0))+`</code></pre>
|
|
55
55
|
`}blockquote({tokens:e}){return`<blockquote>
|
|
56
56
|
${this.parser.parse(e)}</blockquote>
|
|
57
57
|
`}html({text:e}){return e}def(e){return``}heading({tokens:e,depth:t}){return`<h${t}>${this.parser.parseInline(e)}</h${t}>
|
|
@@ -67,5 +67,5 @@ ${this.parser.parse(e)}</blockquote>
|
|
|
67
67
|
`}tablerow({text:e}){return`<tr>
|
|
68
68
|
${e}</tr>
|
|
69
69
|
`}tablecell(e){let t=this.parser.parseInline(e.tokens),n=e.header?`th`:`td`;return(e.align?`<${n} align="${e.align}">`:`<${n}>`)+t+`</${n}>
|
|
70
|
-
`}strong({tokens:e}){return`<strong>${this.parser.parseInline(e)}</strong>`}em({tokens:e}){return`<em>${this.parser.parseInline(e)}</em>`}codespan({text:e}){return`<code>${
|
|
71
|
-
Please report this to https://github.com/markedjs/marked.`,e){let e=`<p>An error occurred:</p><pre>`+td(n.message+``,!0)+`</pre>`;return t?Promise.resolve(e):e}if(t)return Promise.reject(n);throw n}}},bd=new yd;function Q(e,t){return bd.parse(e,t)}Q.options=Q.setOptions=function(e){return bd.setOptions(e),Q.defaults=bd.defaults,Nl(Q.defaults),Q},Q.getDefaults=jl,Q.defaults=Ml;function xd(...e){return bd.use(...e),Q.defaults=bd.defaults,Nl(Q.defaults),Q}Q.use=xd,Q.walkTokens=function(e,t){return bd.walkTokens(e,t)},Q.parseInline=bd.parseInline,Q.Parser=_d,Q.parser=_d.parse,Q.Renderer=hd,Q.TextRenderer=gd,Q.Lexer=md,Q.lexer=md.lex,Q.Tokenizer=pd,Q.Hooks=vd,Q.parse=Q,Q.options,Q.setOptions,Q.walkTokens,Q.parseInline,_d.parse,md.lex;var Sd=`modulepreload`,Cd=function(e){return`/__ph/app/`+e},wd={},Td=function(e){return e.pathname.endsWith(`.css`)},$=function(e,t,n){let r=Promise.resolve();if(t&&t.length>0){let e,i=document.querySelector(`meta[property=csp-nonce]`),a=i?.nonce||i?.getAttribute(`nonce`);function o(e){return Promise.all(e.map(e=>Promise.resolve(e).then(e=>({status:`fulfilled`,value:e}),e=>({status:`rejected`,reason:e}))))}function s(e){return import.meta.resolve?new URL(import.meta.resolve(e)):new URL(e,import.meta.url)}r=o(t.map(t=>{t=Cd(t,n);let r=s(t);if(r.href in wd)return;wd[r.href]=!0;let i=Td(r);if(e===void 0){e={all:new Set,styles:new Set};let t=document.getElementsByTagName(`link`);for(let n=t.length-1;n>=0;n--){let r=t[n];e.all.add(r.href),r.rel===`stylesheet`&&e.styles.add(r.href)}}if((i?e.styles:e.all).has(r.href))return;let o=document.createElement(`link`);if(o.rel=i?`stylesheet`:Sd,i||(o.as=`script`),o.crossOrigin=``,o.href=r.href,a&&o.setAttribute(`nonce`,a),document.head.appendChild(o),i)return new Promise((e,t)=>{o.addEventListener(`load`,e),o.addEventListener(`error`,()=>t(Error(`Unable to preload CSS for ${r}`)))})}).filter(e=>e!==void 0))}function i(e){let t=new Event(`vite:preloadError`,{cancelable:!0});if(t.payload=e,window.dispatchEvent(t),!t.defaultPrevented)throw e}return r.then(t=>{for(let e of t||[])e.status===`rejected`&&i(e.reason);return e().catch(i)})},Ed=new yd({gfm:!0,breaks:!0});Al.addHook(`afterSanitizeAttributes`,e=>{e.tagName===`A`&&(e.setAttribute(`target`,`_blank`),e.setAttribute(`rel`,`noopener noreferrer`))});var Dd=e=>Al.sanitize(e,{USE_PROFILES:{html:!0},FORBID_TAGS:[`style`,`form`,`input`,`button`],FORBID_ATTR:[`style`],ADD_DATA_URI_TAGS:[`img`]});function Od(e,t){let n=Ed.lexer(e),r=[],i=new Set;for(let e of n){if(e.type===`space`)continue;let a=`${e.type}\u0000${e.raw}`,o=t.get(a);if(o===void 0){let r=Object.assign([e],{links:n.links});o=Dd(Ed.parser(r)),t.set(a,o)}i.add(a),r.push(o)}if(t.size>i.size+64)for(let e of t.keys())i.has(e)||t.delete(e);return r}var kd={js:`javascript`,mjs:`javascript`,cjs:`javascript`,ts:`typescript`,mts:`typescript`,sh:`bash`,shell:`bash`,zsh:`bash`,console:`bash`,yml:`yaml`,md:`markdown`,py:`python`,rb:`ruby`,htm:`html`,golang:`go`,rs:`rust`,"c++":`cpp`,cs:`csharp`,kt:`kotlin`,ps1:`powershell`,docker:`dockerfile`,patch:`diff`,h:`c`,hpp:`cpp`,svg:`xml`,gql:`graphql`},Ad={javascript:()=>$(()=>import(`./javascript-Yelw-5ZN.js`),__vite__mapDeps([0,1])),typescript:()=>$(()=>import(`./typescript-Utq2Cl8c.js`),__vite__mapDeps([2,3])),jsx:()=>$(()=>import(`./jsx-hEbJ82HF.js`),__vite__mapDeps([4,5])),tsx:()=>$(()=>import(`./tsx-5f3ulCja.js`),__vite__mapDeps([6,7])),json:()=>$(()=>import(`./json-CaljABEy.js`),__vite__mapDeps([8,9])),jsonc:()=>$(()=>import(`./jsonc-CYpm1nAK.js`),[]),html:()=>$(()=>import(`./html-WQKKblVZ.js`),__vite__mapDeps([10,11,1,12])),css:()=>$(()=>import(`./css-DUjzNfgv.js`),__vite__mapDeps([13,12])),scss:()=>$(()=>import(`./scss-8bKmll0B.js`),__vite__mapDeps([14,12])),less:()=>$(()=>import(`./less-DVTAwKKz.js`),[]),vue:()=>$(()=>import(`./vue-BqdMUtqy.js`),__vite__mapDeps([15,9,1,3,12,11])),svelte:()=>$(()=>import(`./svelte-CdeT-Ich.js`),__vite__mapDeps([16,1,3,12,17])),astro:()=>$(()=>import(`./astro-BZ97kZFP.js`),__vite__mapDeps([18,9,1,3,12,17,7])),markdown:()=>$(()=>import(`./markdown-BYOwaDjH.js`),[]),yaml:()=>$(()=>import(`./yaml-CxbubiML.js`),__vite__mapDeps([19,20])),toml:()=>$(()=>import(`./toml-CcmNWLt0.js`),[]),xml:()=>$(()=>import(`./xml-CoDIzWF0.js`),__vite__mapDeps([21,22,23])),bash:()=>$(()=>import(`./bash-BiGZg9Om.js`),__vite__mapDeps([24,25])),powershell:()=>$(()=>import(`./powershell-QtSnmXcu.js`),[]),dockerfile:()=>$(()=>import(`./dockerfile-IyjqRm3v.js`),[]),python:()=>$(()=>import(`./python-gzcpVVnB.js`),[]),go:()=>$(()=>import(`./go-rLFTqkRN.js`),[]),rust:()=>$(()=>import(`./rust-DpiIf5JO.js`),[]),java:()=>$(()=>import(`./java-DxlWrXwe.js`),__vite__mapDeps([26,23])),kotlin:()=>$(()=>import(`./kotlin-DhhofPvG.js`),[]),swift:()=>$(()=>import(`./swift-CyEgAFGc.js`),[]),c:()=>$(()=>import(`./c-DWGmR78Y.js`),__vite__mapDeps([27,28])),cpp:()=>$(()=>import(`./cpp-CJIxL8VH.js`),__vite__mapDeps([29,30,28])),csharp:()=>$(()=>import(`./csharp-dmMxLVLW.js`),[]),php:()=>$(()=>import(`./php-D7kNSOJl.js`),__vite__mapDeps([31,9,1,12,11,22,23,32])),ruby:()=>$(()=>import(`./ruby-dXJhvJjh.js`),__vite__mapDeps([33,1,12,25,28,30,34,3,7,5,11,22,23,32,20])),sql:()=>$(()=>import(`./sql-BOsskAmu.js`),__vite__mapDeps([35,32])),graphql:()=>$(()=>import(`./graphql-DAzSVzvB.js`),__vite__mapDeps([36,34,1,3,7,5])),diff:()=>$(()=>import(`./diff-woXpYk--.js`),[]),ini:()=>$(()=>import(`./ini-B5eOa1yu.js`),[]),dart:()=>$(()=>import(`./dart-CHZY9Xhz.js`),[])},jd=null;async function Md(){return jd??=(async()=>{let[{createHighlighterCore:e},{createJavaScriptRegexEngine:t}]=await Promise.all([$(()=>import(`./core-R68uHlmr.js`),__vite__mapDeps([37,38])),$(()=>import(`./engine-javascript-CYgs891E.js`),[])]);return e({themes:[$(()=>import(`./github-light-EUqPIrTm.js`),[]),$(()=>import(`./github-dark-C-LZuMrd.js`),[])],langs:[],engine:t()})})(),jd}async function Nd(e,t){let n=(kd[t.toLowerCase()]??t.toLowerCase()).trim();if(!n||n===`text`||n===`plain`||e.length>2e5)return null;try{let t=Ad[n];if(!t)return null;let r=await Md();if(!r.getLoadedLanguages().includes(n)){let e=await t();await r.loadLanguage(e.default)}return r.codeToHtml(e,{lang:n,themes:{light:`github-light`,dark:`github-dark`},defaultColor:!1})}catch{return null}}async function Pd(e){let t=e.querySelectorAll(`pre > code[class*="language-"]:not([data-hl])`);for(let e of t){e.dataset.hl=`1`;let t=/language-([\w+#-]+)/.exec(e.className);if(!t)continue;let n=await Nd(e.textContent??``,t[1]);if(!n||!e.isConnected)continue;let r=e.parentElement,i=document.createElement(`div`);i.className=`code-block`,i.innerHTML=Al.sanitize(n);let a=document.createElement(`span`);a.className=`code-lang`,a.textContent=t[1],i.prepend(a),r.replaceWith(i)}}var Fd=160,Id=70,Ld=40,Rd=6e3,zd=()=>typeof matchMedia==`function`&&matchMedia(`(prefers-reduced-motion: reduce)`).matches;function Bd(e,t){let n=Kt(e()),r=n.value.length,i=0,a=0,o=0,s=()=>{a&&cancelAnimationFrame(a),a=0},c=s=>{a=0;let l=e(),u=l.length-r;if(u<=0||u>Rd||zd()){r=l.length,n.value=l;return}let d=Math.min(64,o?s-o:16);o=s;let f=t()?Fd:Id;i+=Math.max(u*(1-Math.exp(-d/f)),Ld*d/1e3);let p=Math.floor(i);if(p<1){a=requestAnimationFrame(c);return}i-=p,p=Math.min(p,u);let m=r+p,h=l.charCodeAt(m-1);h>=55296&&h<=56319&&m<l.length&&m++,r=m,n.value=l.slice(0,r),r<l.length&&(a=requestAnimationFrame(c))},l=()=>{a||=(o=0,requestAnimationFrame(c))},u=t();return Rn(e,e=>{if(!u||!e.startsWith(n.value)){s(),r=e.length,n.value=e;return}l()}),Rn(t,t=>{t&&(u=!0),e().length>r&&l()}),fr(s),n}var Vd=[`innerHTML`],Hd=Gs(Jn({__name:`Markdown`,props:{source:{},streaming:{type:Boolean}},emits:[`image`],setup(e,{emit:t}){let n=e,r=t,i=Kt(),a=Bd(()=>n.source,()=>!!n.streaming),o=G(()=>!!n.streaming||a.value.length<n.source.length),s=new Map,c=G(()=>Od(a.value,s)),l=()=>{let e=i.value;if(!e)return;let t=Array.from(e.children),n=o.value?t.slice(0,-1):t;for(let e of n)e.querySelector(`pre > code[class*="language-"]:not([data-hl])`)&&Pd(e)};lr(l),Rn([()=>c.value.length,o],()=>vn(l));function u(e){let t=e.target;t.tagName===`IMG`&&r(`image`,t.src)}return(e,t)=>(B(),V(`div`,{ref_key:`el`,ref:i,class:k([`md`,{streaming:o.value}]),onClick:u},[(B(!0),V(z,null,Cr(c.value,(e,t)=>(B(),V(`div`,{key:t,class:`mb`,innerHTML:e},null,8,Vd))),128))],2))}}),[[`__scopeId`,`data-v-36991c76`]]),Ud=[`data-state`],Wd=Gs(Jn({__name:`ThoughtStatus`,props:{state:{}},setup(e){let t=e,n=G(()=>t.state===`generating`?q.value.thinking:t.state===`done`?q.value.thoughts:q.value.thoughtInterrupted);return(t,r)=>(B(),V(`span`,{class:`ts`,"data-state":e.state,"data-testid":`thought-status`},[U(K,{name:e.state===`interrupted`?`alert`:`sparkle`,class:`ic`},null,8,[`name`]),H(`span`,null,M(n.value),1),e.state===`done`?(B(),Ki(K,{key:0,name:`check`,class:`ok`})):W(`v-if`,!0)],8,Ud))}}),[[`__scopeId`,`data-v-7dbe7b9b`]]),Gd={class:`code-view`},Kd=[`innerHTML`],qd={key:1},Jd=Gs(Jn({__name:`CodeView`,props:{code:{},lang:{}},setup(e){let t=e,n=Kt(null);return Ln(async()=>{let e=t.code;n.value=null;let r=await Nd(e,t.lang);t.code===e&&(n.value=r?Al.sanitize(r):null)}),(t,r)=>(B(),V(`div`,Gd,[n.value?(B(),V(`div`,{key:0,class:`hl`,innerHTML:n.value},null,8,Kd)):(B(),V(`pre`,qd,M(e.code),1))]))}}),[[`__scopeId`,`data-v-1a55757b`]]),Yd={key:0,class:`spin`},Xd={class:`name`},Zd={class:`sum mono`},Qd={key:0,class:`body`},$d={key:0,class:`sec`},ef={class:`lbl`},tf={key:1,class:`sec`},nf={class:`lbl`},rf={class:`out`},af={key:2,class:`sec faint`},of=e=>e.replace(/^mcp__page-harness__/,``).replace(/^page-harness[_.]/,``),sf=Gs(Jn({__name:`ToolCard`,props:{item:{}},setup(e){let t=e,n=Kt(!1),r=G(()=>of(t.item.name)),i=G(()=>{let e=t.item.input;if(!e||typeof e!=`object`)return``;let n=e.command??e.file_path??e.path??e.name??e.pattern??e.query??e.url??e.description??e.sid;return typeof n==`string`?n:Array.isArray(n)?n.join(` `):``}),a=G(()=>t.item.input===void 0?``:JSON.stringify(t.item.input,null,2));return(t,o)=>(B(),V(`div`,{class:k([`tool`,e.item.status])},[H(`button`,{class:`head`,onClick:o[0]||=e=>n.value=!n.value},[e.item.status===`start`?(B(),V(`span`,Yd)):(B(),Ki(K,{key:1,name:e.item.status===`error`?`x`:`tool`,class:`ic`},null,8,[`name`])),H(`span`,Xd,M(r.value),1),H(`span`,Zd,M(i.value),1),U(K,{name:`chevron`,class:k([`chev`,{open:n.value}])},null,8,[`class`])]),n.value?(B(),V(`div`,Qd,[a.value?(B(),V(`div`,$d,[H(`div`,ef,M(R(q).input),1),U(Jd,{code:a.value,lang:`json`},null,8,[`code`])])):W(`v-if`,!0),e.item.output?(B(),V(`div`,tf,[H(`div`,nf,M(R(q).output),1),H(`pre`,rf,M(e.item.output),1)])):W(`v-if`,!0),!a.value&&!e.item.output?(B(),V(`div`,af,M(R(q).running)+`…`,1)):W(`v-if`,!0)])):W(`v-if`,!0)],2))}}),[[`__scopeId`,`data-v-594c2211`]]),cf=[`aria-expanded`],lf={key:0,class:`spin`},uf={class:`count`},df={class:`names mono`},ff={key:0,class:`list`},pf=Gs(Jn({__name:`ToolGroup`,props:{items:{}},setup(e){let t=e,n=Kt(!1),r=G(()=>t.items.some(e=>e.status===`start`)),i=G(()=>t.items.filter(e=>e.status===`error`).length),a=G(()=>[...new Set(t.items.map(e=>of(e.name)))].join(`, `));return(t,o)=>(B(),V(`div`,{class:k([`tools`,{open:n.value,failed:i.value>0}]),"data-testid":`tool-group`},[H(`button`,{class:`head`,"aria-expanded":n.value,onClick:o[0]||=e=>n.value=!n.value},[r.value?(B(),V(`span`,lf)):i.value?(B(),Ki(K,{key:1,name:`alert`,class:`ic err`})):(B(),Ki(K,{key:2,name:`check`,class:`ic ok`})),H(`span`,uf,M(R(fs)(R(q).toolsUsed,{n:e.items.length})),1),H(`span`,df,M(a.value),1),U(K,{name:`chevron`,class:`chev`})],8,cf),n.value?(B(),V(`div`,ff,[(B(!0),V(z,null,Cr(e.items,e=>(B(),Ki(sf,{key:e.id,item:e},null,8,[`item`]))),128))])):W(`v-if`,!0)],2))}}),[[`__scopeId`,`data-v-f67aaedd`]]),mf=[`data-turn`],hf={class:`row user`},gf={class:`av me`},_f={class:`col`},vf={key:1,class:`bubble`},yf={key:0,class:`chips`},bf=[`title`],xf={key:0,class:`chip`},Sf={key:1,class:`text`},Cf={key:2,class:`atts`},wf=[`src`,`alt`,`onClick`],Tf=[`href`],Ef={class:`row agent`},Df={class:`av bot`},Of={class:`col`},kf={key:0,class:`busy indicator`},Af=[`open`],jf=[`onClick`],Mf={class:`think-body`},Nf={key:1,class:`msg`},Pf={key:4,class:`err-box`,role:`alert`},Ff={class:`err-body`},If={class:`err-title`},Lf={class:`err-msg mono`},Rf={key:0,class:`shimmer`},zf={key:2,class:`empty-reply`,role:`alert`},Bf={key:3,class:`arts`},Vf=[`onClick`],Hf={key:4,class:`files`},Uf={key:0},Wf=[`title`],Gf=Gs(Jn({__name:`TurnBlock`,props:{turn:{},interactive:{type:Boolean},pendingAsks:{},liveSessions:{},liveViews:{},liveLatest:{type:Boolean},now:{}},emits:[`answer`,`retry`,`live`,`nav`,`image`,`artifact`],setup(e,{emit:t}){let n=e,r=t,i=G(()=>n.turn.status===`running`),a=e=>e.kind===`error`&&e.message===`cancelled`,o=G(()=>{let e=n.turn.items.filter(e=>e.kind===`error`);return n.turn.status===`error`&&e.length>0&&e.every(a)?`cancelled`:n.turn.status}),s=G(()=>es(n.turn)),c=G(()=>n.turn.user.live),l=G(()=>c.value?.sid?n.liveSessions?.find(e=>e.sid===c.value.sid):void 0),u=G(()=>!!c.value&&!!l.value&&!!n.liveLatest&&!i.value&&c.value.op!==`accept`&&c.value.op!==`discard`),d=Kt(!1),f=Kt({}),p=e=>/rate.?limit|429|quota|too many requests|usage limit|overloaded/i.test(e),m=G(()=>{let e=[];return n.turn.items.forEach((t,n)=>{if(a(t))return;let r=e[e.length-1];t.kind===`tool`?r?.kind===`tools`?r.items.push(t):e.push({kind:`tools`,items:[t],last:!1,key:`g${n}`}):e.push({kind:`item`,item:t,index:n,last:!1,key:`i${n}`})}),e.length&&(e[e.length-1].last=!0),e}),h=G(()=>n.turn.items[n.turn.items.length-1]),g=G(()=>i.value&&h.value?.kind===`text`),_=G(()=>i.value?`generating`:o.value===`done`?`done`:`interrupted`),v=G(()=>{switch(o.value){case`done`:return q.value.done;case`cancelled`:return q.value.cancelled;case`interrupted`:return q.value.interrupted;case`error`:return q.value.failed;default:return``}}),y=G(()=>{let e=n.turn.usage,t=e?(e.inputTokens??0)+(e.outputTokens??0):0;return[n.turn.durationMs?ms(n.turn.durationMs):``,t?`${t.toLocaleString()} ${q.value.tokens}`:``,n.turn.model??``,n.turn.agent??``].filter(Boolean).join(` · `)}),b=G(()=>n.interactive&&!c.value&&!s.value&&[`error`,`cancelled`,`interrupted`].includes(o.value));function x(e,t,n){n.preventDefault();let r=!n.currentTarget.parentElement.open;if(r===(i.value&&t)){if(e in f.value){let t={...f.value};delete t[e],f.value=t}return}f.value={...f.value,[e]:r}}return(t,n)=>(B(),V(`div`,{class:`turn`,"data-turn":e.turn.id},[H(`div`,hf,[H(`div`,gf,M(R(q).me),1),H(`div`,_f,[c.value?(B(),Ki(rc,{key:0,compact:``,session:l.value,title:e.turn.user.text,interactive:!1},null,8,[`session`,`title`])):(B(),V(`div`,vf,[e.turn.user.picks.length||e.turn.user.marks?.length?(B(),V(`div`,yf,[(B(!0),V(z,null,Cr(e.turn.user.picks,e=>(B(),V(`span`,{key:e.id,class:`chip`,title:e.selector},[U(K,{name:`target`}),ea(`<`+M(e.tagName.toLowerCase())+`> `+M(e.text||e.selector),1)],8,bf))),128)),e.turn.user.marks?.length?(B(),V(`span`,xf,[U(K,{name:`pen`}),ea(M(R(q).marks)+` × `+M(e.turn.user.marks.length),1)])):W(`v-if`,!0)])):W(`v-if`,!0),e.turn.user.text?(B(),V(`div`,Sf,M(e.turn.user.text),1)):W(`v-if`,!0),e.turn.user.attachments.length?(B(),V(`div`,Cf,[(B(!0),V(z,null,Cr(e.turn.user.attachments,e=>(B(),V(z,{key:e.id},[e.kind===`image`?(B(),V(`img`,{key:0,src:R(as)(e.id),alt:e.name,class:`thumb`,onClick:t=>r(`image`,R(as)(e.id))},null,8,wf)):(B(),V(`a`,{key:1,href:R(as)(e.id),target:`_blank`,rel:`noopener`,class:`file`},[U(K,{name:`file`}),ea(M(e.name),1)],8,Tf))],64))),128))])):W(`v-if`,!0)]))])]),H(`div`,Ef,[H(`div`,Df,[U(K,{name:`robot`})]),H(`div`,Of,[i.value&&!e.turn.items.length?(B(),V(`div`,kf,[n[7]||=H(`span`,{class:`typing-dots`},[H(`i`),H(`i`),H(`i`)],-1),ea(M(R(q).thinking),1)])):W(`v-if`,!0),(B(!0),V(z,null,Cr(m.value,t=>(B(),V(z,{key:t.key},[t.kind===`tools`?(B(),Ki(pf,{key:0,items:t.items},null,8,[`items`])):(B(),V(z,{key:1},[t.item.kind===`thinking`?(B(),V(`details`,{key:0,class:`thinking`,open:f.value[t.index]??(i.value&&t.last)},[H(`summary`,{onClick:e=>x(t.index,t.last,e)},[U(Wd,{state:i.value&&!t.last?`done`:_.value},null,8,[`state`]),U(K,{name:`chevron`,class:`chev`})],8,jf),H(`div`,Mf,M(t.item.text),1)],8,Af)):t.item.kind===`text`?(B(),V(`div`,Nf,[U(Hd,{source:t.item.text,streaming:i.value&&t.last,onImage:n[0]||=e=>r(`image`,e)},null,8,[`source`,`streaming`])])):t.item.kind===`ask`?(B(),Ki(Ks,{key:2,"ask-id":t.item.askId,spec:t.item.spec,answer:t.item.answer,pending:e.interactive&&!!e.pendingAsks?.has(t.item.askId),"turn-running":i.value,onAnswer:n[1]||=(e,t)=>r(`answer`,e,t)},null,8,[`ask-id`,`spec`,`answer`,`pending`,`turn-running`])):t.item.kind===`notice`?(B(),V(`div`,{key:3,class:k([`notice`,t.item.level])},[U(K,{name:`alert`}),ea(M(t.item.message),1)],2)):t.item.kind===`error`?(B(),V(`div`,Pf,[U(K,{name:`alert`}),H(`div`,Ff,[H(`div`,If,M(p(t.item.message)?R(q).rateLimited:R(q).failed),1),H(`div`,Lf,M(t.item.message),1)])])):W(`v-if`,!0)],64))],64))),128)),i.value&&e.turn.items.length?(B(),V(`div`,{key:1,class:k([`indicator`,{writing:g.value}])},[g.value?(B(),V(`span`,Rf,M(R(q).writing),1)):(B(),V(z,{key:1},[n[8]||=H(`span`,{class:`typing-dots`},[H(`i`),H(`i`),H(`i`)],-1),ea(M(h.value?.kind===`tool`?R(q).running:R(q).thinking),1)],64))],2)):W(`v-if`,!0),s.value&&o.value!==`cancelled`?(B(),V(`div`,zf,[U(K,{name:`alert`}),H(`span`,null,M(R(q).emptyReply),1),e.interactive&&!c.value?(B(),V(`button`,{key:0,class:`btn sm danger`,onClick:n[2]||=t=>r(`retry`,e.turn.id)},[U(K,{name:`refresh`}),ea(M(R(q).retry),1)])):W(`v-if`,!0)])):W(`v-if`,!0),e.turn.artifacts.length?(B(),V(`div`,Bf,[(B(!0),V(z,null,Cr(e.turn.artifacts,e=>(B(),V(`button`,{key:e.name+e.version,class:`chip art`,onClick:t=>r(`artifact`,e.name,e.version)},[U(K,{name:`file`}),ea(M(e.name)+` · v`+M(e.version),1)],8,Vf))),128))])):W(`v-if`,!0),e.turn.files.length?(B(),V(`div`,Hf,[H(`button`,{class:`files-head`,onClick:n[3]||=e=>d.value=!d.value},[U(K,{name:`edit`}),ea(M(R(q).changedFiles)+` (`+M(e.turn.files.length)+`)`,1),U(K,{name:`chevron`,style:O({transform:d.value?`rotate(180deg)`:``})},null,8,[`style`])]),d.value?(B(),V(`ul`,Uf,[(B(!0),V(z,null,Cr(e.turn.files,e=>(B(),V(`li`,{key:e,class:`mono`},M(e),1))),128))])):W(`v-if`,!0)])):W(`v-if`,!0),u.value?(B(),Ki(rc,{key:5,agent:``,session:l.value,title:e.turn.user.text,view:l.value?e.liveViews?.[l.value.sid]:void 0,interactive:e.interactive,onOp:n[4]||=e=>r(`live`,e),onNav:n[5]||=(e,t,n)=>r(`nav`,e,t,n)},null,8,[`session`,`title`,`view`,`interactive`])):W(`v-if`,!0),i.value?W(`v-if`,!0):(B(),V(`div`,{key:6,class:`foot`,title:y.value},[H(`span`,{class:k([`st`,o.value])},[o.value===`done`?(B(),Ki(K,{key:0,name:`check`})):o.value===`running`?W(`v-if`,!0):(B(),Ki(K,{key:1,name:`alert`})),ea(M(v.value),1)],2),n[9]||=H(`span`,{class:`spacer`},null,-1),b.value?(B(),V(`button`,{key:0,class:`btn ghost sm`,onClick:n[6]||=t=>r(`retry`,e.turn.id)},[U(K,{name:`refresh`}),ea(M(R(q).retry),1)])):W(`v-if`,!0),H(`span`,null,M(R(ps)(e.turn.endTs??e.turn.ts,e.now)),1)],8,Wf))])])],8,mf))}}),[[`__scopeId`,`data-v-d25ee966`]]);function Kf(e,t){let n=Kt(`connecting`),r=Kt(0),i=null,a=0,o=0,s=!1,c=()=>{if(s)return;r.value>0&&(n.value=r.value>2?`error`:`connecting`);let u=location.protocol===`https:`?`wss`:`ws`;i=new WebSocket(`${u}://${location.host}/__ph/ws`),i.onopen=()=>{r.value=0,n.value=`ready`,t(),clearInterval(o),o=window.setInterval(()=>l({type:`ping`}),25e3)},i.onmessage=t=>{try{e(JSON.parse(t.data))}catch(e){console.error(`[page-harness] bad message`,e)}},i.onclose=()=>{clearInterval(o),!s&&(r.value++,n.value=r.value>2?`error`:`connecting`,clearTimeout(a),a=window.setTimeout(c,Math.min(8e3,400*2**Math.min(r.value,5))))}},l=e=>i?.readyState===WebSocket.OPEN&&(i.send(JSON.stringify(e)),!0);return c(),{state:n,failures:r,send:l,reconnect(){r.value=0,i?.close(),clearTimeout(a),c()},close(){s=!0,i?.close()}}}export{V as A,Rn as B,Fo as C,H as D,G as E,fr as F,R as G,Ft as H,lr as I,M as J,k as K,B as L,U as M,Jn as N,Ki as O,vn as P,Cr as R,yo as S,z as T,Kt as U,jn as V,qt as W,K as _,$ as a,zo as b,fs as c,ps as d,ds as f,Qo as g,is as h,Hd as i,ea as j,W as k,ls as l,rs as m,Gf as n,ic as o,q as p,O as q,Jd as r,Gs as s,Kf as t,us as u,qo as v,No as w,bo as x,Yo as y,yr as z};
|
|
70
|
+
`}strong({tokens:e}){return`<strong>${this.parser.parseInline(e)}</strong>`}em({tokens:e}){return`<em>${this.parser.parseInline(e)}</em>`}codespan({text:e}){return`<code>${pd(e,!0)}</code>`}br(e){return`<br>`}del({tokens:e}){return`<del>${this.parser.parseInline(e)}</del>`}link({href:e,title:t,text:n,tokens:r,autolink:i}){let a=i?pd(n,!0):this.parser.parseInline(r),o=hd(e);if(o===null)return a;e=pd(o,i);let s=`<a href="`+e+`"`;return t&&(s+=` title="`+pd(t)+`"`),s+=`>`+a+`</a>`,s}image({href:e,title:t,text:n,tokens:r}){r&&(n=this.parser.parseInline(r,this.parser.textRenderer));let i=hd(e);if(i===null)return pd(n);e=i;let a=`<img src="${pd(e)}" alt="${pd(n)}"`;return t&&(a+=` title="${pd(t)}"`),a+=`>`,a}text(e){return`tokens`in e&&e.tokens?this.parser.parseInline(e.tokens):`escaped`in e&&e.escaped?e.text:pd(e.text)}},Od=class{strong({text:e}){return e}em({text:e}){return e}codespan({text:e}){return e}del({text:e}){return e}html({text:e}){return e}text({text:e}){return e}link({text:e}){return``+e}image({text:e}){return``+e}br(){return``}checkbox({raw:e}){return e}},kd=class e{options;renderer;textRenderer;constructor(e){this.options=e||Wl,this.options.renderer=this.options.renderer||new Dd,this.renderer=this.options.renderer,this.renderer.options=this.options,this.renderer.parser=this,this.textRenderer=new Od}static parse(t,n){return new e(n).parse(t)}static parseInline(t,n){return new e(n).parseInline(t)}parse(e){this.renderer.parser=this;let t=``;for(let n=0;n<e.length;n++){let r=e[n];if(this.options.extensions?.renderers?.[r.type]){let e=r,n=this.options.extensions.renderers[e.type].call({parser:this},e);if(n!==!1||![`space`,`hr`,`heading`,`code`,`table`,`blockquote`,`list`,`checkbox`,`html`,`def`,`paragraph`,`text`].includes(e.type)){t+=n||``;continue}}let i=r;switch(i.type){case`space`:t+=this.renderer.space(i);break;case`hr`:t+=this.renderer.hr(i);break;case`heading`:t+=this.renderer.heading(i);break;case`code`:t+=this.renderer.code(i);break;case`table`:t+=this.renderer.table(i);break;case`blockquote`:t+=this.renderer.blockquote(i);break;case`list`:t+=this.renderer.list(i);break;case`checkbox`:t+=this.renderer.checkbox(i);break;case`html`:t+=this.renderer.html(i);break;case`def`:t+=this.renderer.def(i);break;case`paragraph`:t+=this.renderer.paragraph(i);break;case`text`:t+=this.renderer.text(i);break;default:{let e=`Token with "`+i.type+`" type was not found.`;if(this.options.silent)return console.error(e),``;throw Error(e)}}}return t}parseInline(e,t=this.renderer){this.renderer.parser=this;let n=``;for(let r=0;r<e.length;r++){let i=e[r];if(this.options.extensions?.renderers?.[i.type]){let e=this.options.extensions.renderers[i.type].call({parser:this},i);if(e!==!1||![`escape`,`html`,`link`,`image`,`checkbox`,`strong`,`em`,`codespan`,`br`,`del`,`text`].includes(i.type)){n+=e||``;continue}}let a=i;switch(a.type){case`escape`:n+=t.text(a);break;case`html`:n+=t.html(a);break;case`link`:n+=t.link(a);break;case`image`:n+=t.image(a);break;case`checkbox`:n+=t.checkbox(a);break;case`strong`:n+=t.strong(a);break;case`em`:n+=t.em(a);break;case`codespan`:n+=t.codespan(a);break;case`br`:n+=t.br(a);break;case`del`:n+=t.del(a);break;case`text`:n+=t.text(a);break;default:{let e=`Token with "`+a.type+`" type was not found.`;if(this.options.silent)return console.error(e),``;throw Error(e)}}}return n}},Ad=class{options;block;constructor(e){this.options=e||Wl}static passThroughHooks=new Set([`preprocess`,`postprocess`,`processAllTokens`,`emStrongMask`]);static passThroughHooksRespectAsync=new Set([`preprocess`,`postprocess`,`processAllTokens`]);preprocess(e){return e}postprocess(e){return e}processAllTokens(e){return e}emStrongMask(e){return e}provideLexer(e=this.block){return e?Ed.lex:Ed.lexInline}provideParser(e=this.block){return e?kd.parse:kd.parseInline}},jd=class{defaults=Ul();options=this.setOptions;parse=this.parseMarkdown(!0);parseInline=this.parseMarkdown(!1);Parser=kd;Renderer=Dd;TextRenderer=Od;Lexer=Ed;Tokenizer=Td;Hooks=Ad;constructor(...e){this.use(...e)}walkTokens(e,t){let n=[];for(let r of e)switch(n=n.concat(t.call(this,r)),r.type){case`table`:{let e=r;for(let r of e.header)n=n.concat(this.walkTokens(r.tokens,t));for(let r of e.rows)for(let e of r)n=n.concat(this.walkTokens(e.tokens,t));break}case`list`:{let e=r;n=n.concat(this.walkTokens(e.items,t));break}default:{let e=r;this.defaults.extensions?.childTokens?.[e.type]?this.defaults.extensions.childTokens[e.type].forEach(r=>{let i=e[r].flat(1/0);n=n.concat(this.walkTokens(i,t))}):e.tokens&&(n=n.concat(this.walkTokens(e.tokens,t)))}}return n}use(...e){let t=this.defaults.extensions||{renderers:{},childTokens:{}};return e.forEach(e=>{let n={...e};if(n.async=this.defaults.async||n.async||!1,e.extensions&&(e.extensions.forEach(e=>{if(!e.name)throw Error(`extension name required`);if(`renderer`in e){let n=t.renderers[e.name];n?t.renderers[e.name]=function(...t){let r=e.renderer.apply(this,t);return r===!1&&(r=n.apply(this,t)),r}:t.renderers[e.name]=e.renderer}if(`tokenizer`in e){if(!e.level||e.level!==`block`&&e.level!==`inline`)throw Error(`extension level must be 'block' or 'inline'`);let n=t[e.level];n?n.unshift(e.tokenizer):t[e.level]=[e.tokenizer],e.start&&(e.level===`block`?t.startBlock?t.startBlock.push(e.start):t.startBlock=[e.start]:e.level===`inline`&&(t.startInline?t.startInline.push(e.start):t.startInline=[e.start]))}`childTokens`in e&&e.childTokens&&(t.childTokens[e.name]=e.childTokens)}),n.extensions=t),e.renderer){let t=this.defaults.renderer||new Dd(this.defaults);for(let n in e.renderer){if(!(n in t))throw Error(`renderer '${n}' does not exist`);if([`options`,`parser`].includes(n))continue;let r=n,i=e.renderer[r],a=t[r];t[r]=(...e)=>{let n=i.apply(t,e);return n===!1&&(n=a.apply(t,e)),n||``}}n.renderer=t}if(e.tokenizer){let t=this.defaults.tokenizer||new Td(this.defaults);for(let n in e.tokenizer){if(!(n in t))throw Error(`tokenizer '${n}' does not exist`);if([`options`,`rules`,`lexer`].includes(n))continue;let r=n,i=e.tokenizer[r],a=t[r];t[r]=(...e)=>{let n=i.apply(t,e);return n===!1&&(n=a.apply(t,e)),n}}n.tokenizer=t}if(e.hooks){let t=this.defaults.hooks||new Ad;for(let n in e.hooks){if(!(n in t))throw Error(`hook '${n}' does not exist`);if([`options`,`block`].includes(n))continue;let r=n,i=e.hooks[r],a=t[r];t[r]=Ad.passThroughHooks.has(n)?e=>{if(this.defaults.async&&Ad.passThroughHooksRespectAsync.has(n))return(async()=>{let n=await i.call(t,e);return a.call(t,n)})();let r=i.call(t,e);return a.call(t,r)}:(...e)=>{if(this.defaults.async)return(async()=>{let n=await i.apply(t,e);return n===!1&&(n=await a.apply(t,e)),n})();let n=i.apply(t,e);return n===!1&&(n=a.apply(t,e)),n}}n.hooks=t}if(e.walkTokens){let t=this.defaults.walkTokens,r=e.walkTokens;n.walkTokens=function(e){let n=[];return n.push(r.call(this,e)),t&&(n=n.concat(t.call(this,e))),n}}this.defaults={...this.defaults,...n}}),this}setOptions(e){return this.defaults={...this.defaults,...e},this}lexer(e,t){return Ed.lex(e,t??this.defaults)}parser(e,t){return kd.parse(e,t??this.defaults)}parseMarkdown(e){return(t,n)=>{let r={...n},i={...this.defaults,...r},a=this.onError(!!i.silent,!!i.async);if(this.defaults.async===!0&&r.async===!1)return a(Error(`marked(): The async option was set to true by an extension. Remove async: false from the parse options object to return a Promise.`));if(typeof t>`u`||t===null)return a(Error(`marked(): input parameter is undefined or null`));if(typeof t!=`string`)return a(Error(`marked(): input parameter is of type `+Object.prototype.toString.call(t)+`, string expected`));if(i.hooks&&(i.hooks.options=i,i.hooks.block=e),i.async)return(async()=>{let n=i.hooks?await i.hooks.preprocess(t):t,r=await(i.hooks?await i.hooks.provideLexer(e):e?Ed.lex:Ed.lexInline)(n,i),a=i.hooks?await i.hooks.processAllTokens(r):r;i.walkTokens&&await Promise.all(this.walkTokens(a,i.walkTokens));let o=await(i.hooks?await i.hooks.provideParser(e):e?kd.parse:kd.parseInline)(a,i);return i.hooks?await i.hooks.postprocess(o):o})().catch(a);try{i.hooks&&(t=i.hooks.preprocess(t));let n=(i.hooks?i.hooks.provideLexer(e):e?Ed.lex:Ed.lexInline)(t,i);i.hooks&&(n=i.hooks.processAllTokens(n)),i.walkTokens&&this.walkTokens(n,i.walkTokens);let r=(i.hooks?i.hooks.provideParser(e):e?kd.parse:kd.parseInline)(n,i);return i.hooks&&(r=i.hooks.postprocess(r)),r}catch(e){return a(e)}}}onError(e,t){return n=>{if(n.message+=`
|
|
71
|
+
Please report this to https://github.com/markedjs/marked.`,e){let e=`<p>An error occurred:</p><pre>`+pd(n.message+``,!0)+`</pre>`;return t?Promise.resolve(e):e}if(t)return Promise.reject(n);throw n}}},Md=new jd;function Q(e,t){return Md.parse(e,t)}Q.options=Q.setOptions=function(e){return Md.setOptions(e),Q.defaults=Md.defaults,Gl(Q.defaults),Q},Q.getDefaults=Ul,Q.defaults=Wl;function Nd(...e){return Md.use(...e),Q.defaults=Md.defaults,Gl(Q.defaults),Q}Q.use=Nd,Q.walkTokens=function(e,t){return Md.walkTokens(e,t)},Q.parseInline=Md.parseInline,Q.Parser=kd,Q.parser=kd.parse,Q.Renderer=Dd,Q.TextRenderer=Od,Q.Lexer=Ed,Q.lexer=Ed.lex,Q.Tokenizer=Td,Q.Hooks=Ad,Q.parse=Q,Q.options,Q.setOptions,Q.walkTokens,Q.parseInline,kd.parse,Ed.lex;var Pd=`modulepreload`,Fd=function(e){return`/__ph/app/`+e},Id={},Ld=function(e){return e.pathname.endsWith(`.css`)},$=function(e,t,n){let r=Promise.resolve();if(t&&t.length>0){let e,i=document.querySelector(`meta[property=csp-nonce]`),a=i?.nonce||i?.getAttribute(`nonce`);function o(e){return Promise.all(e.map(e=>Promise.resolve(e).then(e=>({status:`fulfilled`,value:e}),e=>({status:`rejected`,reason:e}))))}function s(e){return import.meta.resolve?new URL(import.meta.resolve(e)):new URL(e,import.meta.url)}r=o(t.map(t=>{t=Fd(t,n);let r=s(t);if(r.href in Id)return;Id[r.href]=!0;let i=Ld(r);if(e===void 0){e={all:new Set,styles:new Set};let t=document.getElementsByTagName(`link`);for(let n=t.length-1;n>=0;n--){let r=t[n];e.all.add(r.href),r.rel===`stylesheet`&&e.styles.add(r.href)}}if((i?e.styles:e.all).has(r.href))return;let o=document.createElement(`link`);if(o.rel=i?`stylesheet`:Pd,i||(o.as=`script`),o.crossOrigin=``,o.href=r.href,a&&o.setAttribute(`nonce`,a),document.head.appendChild(o),i)return new Promise((e,t)=>{o.addEventListener(`load`,e),o.addEventListener(`error`,()=>t(Error(`Unable to preload CSS for ${r}`)))})}).filter(e=>e!==void 0))}function i(e){let t=new Event(`vite:preloadError`,{cancelable:!0});if(t.payload=e,window.dispatchEvent(t),!t.defaultPrevented)throw e}return r.then(t=>{for(let e of t||[])e.status===`rejected`&&i(e.reason);return e().catch(i)})},Rd=new jd({gfm:!0,breaks:!0});Hl.addHook(`afterSanitizeAttributes`,e=>{e.tagName===`A`&&(e.setAttribute(`target`,`_blank`),e.setAttribute(`rel`,`noopener noreferrer`))});var zd=e=>Hl.sanitize(e,{USE_PROFILES:{html:!0},FORBID_TAGS:[`style`,`form`,`input`,`button`],FORBID_ATTR:[`style`],ADD_DATA_URI_TAGS:[`img`]});function Bd(e,t){let n=Rd.lexer(e),r=[],i=new Set;for(let e of n){if(e.type===`space`)continue;let a=`${e.type}\u0000${e.raw}`,o=t.get(a);if(o===void 0){let r=Object.assign([e],{links:n.links});o=zd(Rd.parser(r)),t.set(a,o)}i.add(a),r.push(o)}if(t.size>i.size+64)for(let e of t.keys())i.has(e)||t.delete(e);return r}var Vd={js:`javascript`,mjs:`javascript`,cjs:`javascript`,ts:`typescript`,mts:`typescript`,sh:`bash`,shell:`bash`,zsh:`bash`,console:`bash`,yml:`yaml`,md:`markdown`,py:`python`,rb:`ruby`,htm:`html`,golang:`go`,rs:`rust`,"c++":`cpp`,cs:`csharp`,kt:`kotlin`,ps1:`powershell`,docker:`dockerfile`,patch:`diff`,h:`c`,hpp:`cpp`,svg:`xml`,gql:`graphql`},Hd={javascript:()=>$(()=>import(`./javascript-Yelw-5ZN.js`),__vite__mapDeps([0,1])),typescript:()=>$(()=>import(`./typescript-Utq2Cl8c.js`),__vite__mapDeps([2,3])),jsx:()=>$(()=>import(`./jsx-hEbJ82HF.js`),__vite__mapDeps([4,5])),tsx:()=>$(()=>import(`./tsx-5f3ulCja.js`),__vite__mapDeps([6,7])),json:()=>$(()=>import(`./json-CaljABEy.js`),__vite__mapDeps([8,9])),jsonc:()=>$(()=>import(`./jsonc-CYpm1nAK.js`),[]),html:()=>$(()=>import(`./html-WQKKblVZ.js`),__vite__mapDeps([10,11,1,12])),css:()=>$(()=>import(`./css-DUjzNfgv.js`),__vite__mapDeps([13,12])),scss:()=>$(()=>import(`./scss-8bKmll0B.js`),__vite__mapDeps([14,12])),less:()=>$(()=>import(`./less-DVTAwKKz.js`),[]),vue:()=>$(()=>import(`./vue-BqdMUtqy.js`),__vite__mapDeps([15,9,1,3,12,11])),svelte:()=>$(()=>import(`./svelte-CdeT-Ich.js`),__vite__mapDeps([16,1,3,12,17])),astro:()=>$(()=>import(`./astro-BZ97kZFP.js`),__vite__mapDeps([18,9,1,3,12,17,7])),markdown:()=>$(()=>import(`./markdown-BYOwaDjH.js`),[]),yaml:()=>$(()=>import(`./yaml-CxbubiML.js`),__vite__mapDeps([19,20])),toml:()=>$(()=>import(`./toml-CcmNWLt0.js`),[]),xml:()=>$(()=>import(`./xml-CoDIzWF0.js`),__vite__mapDeps([21,22,23])),bash:()=>$(()=>import(`./bash-BiGZg9Om.js`),__vite__mapDeps([24,25])),powershell:()=>$(()=>import(`./powershell-QtSnmXcu.js`),[]),dockerfile:()=>$(()=>import(`./dockerfile-IyjqRm3v.js`),[]),python:()=>$(()=>import(`./python-gzcpVVnB.js`),[]),go:()=>$(()=>import(`./go-rLFTqkRN.js`),[]),rust:()=>$(()=>import(`./rust-DpiIf5JO.js`),[]),java:()=>$(()=>import(`./java-DxlWrXwe.js`),__vite__mapDeps([26,23])),kotlin:()=>$(()=>import(`./kotlin-DhhofPvG.js`),[]),swift:()=>$(()=>import(`./swift-CyEgAFGc.js`),[]),c:()=>$(()=>import(`./c-DWGmR78Y.js`),__vite__mapDeps([27,28])),cpp:()=>$(()=>import(`./cpp-CJIxL8VH.js`),__vite__mapDeps([29,30,28])),csharp:()=>$(()=>import(`./csharp-dmMxLVLW.js`),[]),php:()=>$(()=>import(`./php-D7kNSOJl.js`),__vite__mapDeps([31,9,1,12,11,22,23,32])),ruby:()=>$(()=>import(`./ruby-dXJhvJjh.js`),__vite__mapDeps([33,1,12,25,28,30,34,3,7,5,11,22,23,32,20])),sql:()=>$(()=>import(`./sql-BOsskAmu.js`),__vite__mapDeps([35,32])),graphql:()=>$(()=>import(`./graphql-DAzSVzvB.js`),__vite__mapDeps([36,34,1,3,7,5])),diff:()=>$(()=>import(`./diff-woXpYk--.js`),[]),ini:()=>$(()=>import(`./ini-B5eOa1yu.js`),[]),dart:()=>$(()=>import(`./dart-CHZY9Xhz.js`),[])},Ud=null;async function Wd(){return Ud??=(async()=>{let[{createHighlighterCore:e},{createJavaScriptRegexEngine:t}]=await Promise.all([$(()=>import(`./core-R68uHlmr.js`),__vite__mapDeps([37,38])),$(()=>import(`./engine-javascript-CYgs891E.js`),[])]);return e({themes:[$(()=>import(`./github-light-EUqPIrTm.js`),[]),$(()=>import(`./github-dark-C-LZuMrd.js`),[])],langs:[],engine:t()})})(),Ud}async function Gd(e,t){let n=(Vd[t.toLowerCase()]??t.toLowerCase()).trim();if(!n||n===`text`||n===`plain`||e.length>2e5)return null;try{let t=Hd[n];if(!t)return null;let r=await Wd();if(!r.getLoadedLanguages().includes(n)){let e=await t();await r.loadLanguage(e.default)}return r.codeToHtml(e,{lang:n,themes:{light:`github-light`,dark:`github-dark`},defaultColor:!1})}catch{return null}}async function Kd(e){let t=e.querySelectorAll(`pre > code[class*="language-"]:not([data-hl])`);for(let e of t){e.dataset.hl=`1`;let t=/language-([\w+#-]+)/.exec(e.className);if(!t)continue;let n=await Gd(e.textContent??``,t[1]);if(!n||!e.isConnected)continue;let r=e.parentElement,i=document.createElement(`div`);i.className=`code-block`,i.innerHTML=Hl.sanitize(n);let a=document.createElement(`span`);a.className=`code-lang`,a.textContent=t[1],i.prepend(a),r.replaceWith(i)}}var qd=160,Jd=70,Yd=40,Xd=6e3,Zd=()=>typeof matchMedia==`function`&&matchMedia(`(prefers-reduced-motion: reduce)`).matches;function Qd(e,t){let n=Kt(e()),r=n.value.length,i=0,a=0,o=0,s=()=>{a&&cancelAnimationFrame(a),a=0},c=s=>{a=0;let l=e(),u=l.length-r;if(u<=0||u>Xd||Zd()){r=l.length,n.value=l;return}let d=Math.min(64,o?s-o:16);o=s;let f=t()?qd:Jd;i+=Math.max(u*(1-Math.exp(-d/f)),Yd*d/1e3);let p=Math.floor(i);if(p<1){a=requestAnimationFrame(c);return}i-=p,p=Math.min(p,u);let m=r+p,h=l.charCodeAt(m-1);h>=55296&&h<=56319&&m<l.length&&m++,r=m,n.value=l.slice(0,r),r<l.length&&(a=requestAnimationFrame(c))},l=()=>{a||=(o=0,requestAnimationFrame(c))},u=t();return Rn(e,e=>{if(!u||!e.startsWith(n.value)){s(),r=e.length,n.value=e;return}l()}),Rn(t,t=>{t&&(u=!0),e().length>r&&l()}),fr(s),n}var $d=[`innerHTML`],ef=cs(Jn({__name:`Markdown`,props:{source:{},streaming:{type:Boolean}},emits:[`image`],setup(e,{emit:t}){let n=e,r=t,i=Kt(),a=Qd(()=>n.source,()=>!!n.streaming),o=G(()=>!!n.streaming||a.value.length<n.source.length),s=new Map,c=G(()=>Bd(a.value,s)),l=()=>{let e=i.value;if(!e)return;let t=Array.from(e.children),n=o.value?t.slice(0,-1):t;for(let e of n)e.querySelector(`pre > code[class*="language-"]:not([data-hl])`)&&Kd(e)};lr(l),Rn([()=>c.value.length,o],()=>vn(l));function u(e){let t=e.target;t.tagName===`IMG`&&r(`image`,t.src)}return(e,t)=>(B(),V(`div`,{ref_key:`el`,ref:i,class:k([`md`,{streaming:o.value}]),onClick:u},[(B(!0),V(z,null,Cr(c.value,(e,t)=>(B(),V(`div`,{key:t,class:`mb`,innerHTML:e},null,8,$d))),128))],2))}}),[[`__scopeId`,`data-v-36991c76`]]),tf=[`data-state`],nf=cs(Jn({__name:`ThoughtStatus`,props:{state:{}},setup(e){let t=e,n=G(()=>t.state===`generating`?q.value.thinking:t.state===`done`?q.value.thoughts:q.value.thoughtInterrupted);return(t,r)=>(B(),V(`span`,{class:`ts`,"data-state":e.state,"data-testid":`thought-status`},[U(K,{name:e.state===`interrupted`?`alert`:`sparkle`,class:`ic`},null,8,[`name`]),H(`span`,null,M(n.value),1),e.state===`done`?(B(),Ki(K,{key:0,name:`check`,class:`ok`})):W(`v-if`,!0)],8,tf))}}),[[`__scopeId`,`data-v-7dbe7b9b`]]),rf={class:`code-view`},af=[`innerHTML`],of={key:1},sf=cs(Jn({__name:`CodeView`,props:{code:{},lang:{}},setup(e){let t=e,n=Kt(null);return Ln(async()=>{let e=t.code;n.value=null;let r=await Gd(e,t.lang);t.code===e&&(n.value=r?Hl.sanitize(r):null)}),(t,r)=>(B(),V(`div`,rf,[n.value?(B(),V(`div`,{key:0,class:`hl`,innerHTML:n.value},null,8,af)):(B(),V(`pre`,of,M(e.code),1))]))}}),[[`__scopeId`,`data-v-1a55757b`]]),cf={key:0,class:`spin`},lf={class:`name`},uf={class:`sum mono`},df={key:0,class:`body`},ff={key:0,class:`sec`},pf={class:`lbl`},mf={key:1,class:`sec`},hf={class:`lbl`},gf={class:`out`},_f={key:2,class:`sec faint`},vf=e=>e.replace(/^mcp__page-harness__/,``).replace(/^page-harness[_.]/,``),yf=cs(Jn({__name:`ToolCard`,props:{item:{}},setup(e){let t=e,n=Kt(!1),r=G(()=>vf(t.item.name)),i=G(()=>{let e=t.item.input;if(!e||typeof e!=`object`)return``;let n=e.command??e.file_path??e.filePath??e.path??e.name??e.pattern??e.query??e.url??e.description??e.sid;return typeof n==`string`?n:Array.isArray(n)?n.join(` `):``}),a=G(()=>t.item.input===void 0?``:JSON.stringify(t.item.input,null,2));return(t,o)=>(B(),V(`div`,{class:k([`tool`,e.item.status])},[H(`button`,{class:`head`,onClick:o[0]||=e=>n.value=!n.value},[e.item.status===`start`?(B(),V(`span`,cf)):(B(),Ki(K,{key:1,name:e.item.status===`error`?`x`:`tool`,class:`ic`},null,8,[`name`])),H(`span`,lf,M(r.value),1),H(`span`,uf,M(i.value),1),U(K,{name:`chevron`,class:k([`chev`,{open:n.value}])},null,8,[`class`])]),n.value?(B(),V(`div`,df,[a.value?(B(),V(`div`,ff,[H(`div`,pf,M(R(q).input),1),U(sf,{code:a.value,lang:`json`},null,8,[`code`])])):W(`v-if`,!0),e.item.output?(B(),V(`div`,mf,[H(`div`,hf,M(R(q).output),1),H(`pre`,gf,M(e.item.output),1)])):W(`v-if`,!0),!a.value&&!e.item.output?(B(),V(`div`,_f,M(R(q).running)+`…`,1)):W(`v-if`,!0)])):W(`v-if`,!0)],2))}}),[[`__scopeId`,`data-v-862deeb1`]]),bf=[`aria-expanded`],xf={key:0,class:`spin`},Sf={class:`count`},Cf={class:`names mono`},wf={key:0,class:`list`},Tf=cs(Jn({__name:`ToolGroup`,props:{items:{}},setup(e){let t=e,n=Kt(!1),r=G(()=>t.items.some(e=>e.status===`start`)),i=G(()=>t.items.filter(e=>e.status===`error`).length),a=G(()=>[...new Set(t.items.map(e=>vf(e.name)))].join(`, `));return(t,o)=>(B(),V(`div`,{class:k([`tools`,{open:n.value,failed:i.value>0}]),"data-testid":`tool-group`},[H(`button`,{class:`head`,"aria-expanded":n.value,onClick:o[0]||=e=>n.value=!n.value},[r.value?(B(),V(`span`,xf)):i.value?(B(),Ki(K,{key:1,name:`alert`,class:`ic err`})):(B(),Ki(K,{key:2,name:`check`,class:`ic ok`})),H(`span`,Sf,M(R(Es)(R(q).toolsUsed,{n:e.items.length})),1),H(`span`,Cf,M(a.value),1),U(K,{name:`chevron`,class:`chev`})],8,bf),n.value?(B(),V(`div`,wf,[(B(!0),V(z,null,Cr(e.items,e=>(B(),Ki(yf,{key:e.id,item:e},null,8,[`item`]))),128))])):W(`v-if`,!0)],2))}}),[[`__scopeId`,`data-v-f67aaedd`]]),Ef=[`data-turn`],Df={class:`row user`},Of={class:`av me`},kf={class:`col`},Af={key:1,class:`bubble`},jf={key:0,class:`chips`},Mf=[`title`],Nf={key:0,class:`chip`},Pf={key:1,class:`text`},Ff={key:2,class:`atts`},If=[`src`,`alt`,`onClick`],Lf=[`href`],Rf={class:`row agent`},zf={class:`av bot`},Bf={class:`col`},Vf={key:0,class:`busy indicator`},Hf=[`open`],Uf=[`onClick`],Wf={class:`think-body`},Gf={key:1,class:`msg`},Kf={key:4,class:`err-box`,role:`alert`},qf={class:`err-body`},Jf={class:`err-title`},Yf={class:`err-msg mono`},Xf={key:0,class:`shimmer`},Zf={key:2,class:`empty-reply`,role:`alert`},Qf={key:3,class:`arts`},$f=[`onClick`],ep={key:4,class:`files`},tp={key:0},np=[`title`],rp=cs(Jn({__name:`TurnBlock`,props:{turn:{},interactive:{type:Boolean},pendingAsks:{},liveSessions:{},liveViews:{},liveLatest:{type:Boolean},now:{}},emits:[`answer`,`retry`,`live`,`nav`,`image`,`artifact`],setup(e,{emit:t}){let n=e,r=t,i=G(()=>n.turn.status===`running`),a=e=>e.kind===`error`&&e.message===`cancelled`,o=G(()=>{let e=n.turn.items.filter(e=>e.kind===`error`);return n.turn.status===`error`&&e.length>0&&e.every(a)?`cancelled`:n.turn.status}),s=G(()=>ms(n.turn)),c=G(()=>n.turn.user.live),l=G(()=>c.value?.sid?n.liveSessions?.find(e=>e.sid===c.value.sid):void 0),u=G(()=>!!c.value&&!!l.value&&!!n.liveLatest&&!i.value&&c.value.op!==`accept`&&c.value.op!==`discard`),d=Kt(!1),f=Kt({}),p=e=>/rate.?limit|429|quota|too many requests|usage limit|overloaded/i.test(e),m=G(()=>{let e=[];return n.turn.items.forEach((t,n)=>{if(a(t))return;let r=e[e.length-1];t.kind===`tool`?r?.kind===`tools`?r.items.push(t):e.push({kind:`tools`,items:[t],last:!1,key:`g${n}`}):e.push({kind:`item`,item:t,index:n,last:!1,key:`i${n}`})}),e.length&&(e[e.length-1].last=!0),e}),h=G(()=>n.turn.items[n.turn.items.length-1]),g=G(()=>i.value&&h.value?.kind===`text`),_=G(()=>i.value?`generating`:o.value===`done`?`done`:`interrupted`),v=G(()=>{switch(o.value){case`done`:return q.value.done;case`cancelled`:return q.value.cancelled;case`interrupted`:return q.value.interrupted;case`error`:return q.value.failed;default:return``}}),y=G(()=>{let e=n.turn.usage,t=e?(e.inputTokens??0)+(e.outputTokens??0):0;return[n.turn.durationMs?Os(n.turn.durationMs):``,t?`${t.toLocaleString()} ${q.value.tokens}`:``,n.turn.model??``,n.turn.agent??``].filter(Boolean).join(` · `)}),b=G(()=>n.interactive&&!c.value&&!s.value&&[`error`,`cancelled`,`interrupted`].includes(o.value));function x(e,t,n){n.preventDefault();let r=!n.currentTarget.parentElement.open;if(r===(i.value&&t)){if(e in f.value){let t={...f.value};delete t[e],f.value=t}return}f.value={...f.value,[e]:r}}return(t,n)=>(B(),V(`div`,{class:`turn`,"data-turn":e.turn.id},[H(`div`,Df,[H(`div`,Of,M(R(q).me),1),H(`div`,kf,[c.value?(B(),Ki(hc,{key:0,compact:``,session:l.value,title:e.turn.user.text,interactive:!1},null,8,[`session`,`title`])):(B(),V(`div`,Af,[e.turn.user.picks.length||e.turn.user.marks?.length?(B(),V(`div`,jf,[(B(!0),V(z,null,Cr(e.turn.user.picks,e=>(B(),V(`span`,{key:e.id,class:`chip`,title:e.selector},[U(K,{name:`target`}),ea(`<`+M(e.tagName.toLowerCase())+`> `+M(e.text||e.selector),1)],8,Mf))),128)),e.turn.user.marks?.length?(B(),V(`span`,Nf,[U(K,{name:`pen`}),ea(M(R(q).marks)+` × `+M(e.turn.user.marks.length),1)])):W(`v-if`,!0)])):W(`v-if`,!0),e.turn.user.text?(B(),V(`div`,Pf,M(e.turn.user.text),1)):W(`v-if`,!0),e.turn.user.attachments.length?(B(),V(`div`,Ff,[(B(!0),V(z,null,Cr(e.turn.user.attachments,e=>(B(),V(z,{key:e.id},[e.kind===`image`?(B(),V(`img`,{key:0,src:R(ys)(e.id),alt:e.name,class:`thumb`,onClick:t=>r(`image`,R(ys)(e.id))},null,8,If)):(B(),V(`a`,{key:1,href:R(ys)(e.id),target:`_blank`,rel:`noopener`,class:`file`},[U(K,{name:`file`}),ea(M(e.name),1)],8,Lf))],64))),128))])):W(`v-if`,!0)]))])]),H(`div`,Rf,[H(`div`,zf,[U(K,{name:`robot`})]),H(`div`,Bf,[i.value&&!e.turn.items.length?(B(),V(`div`,Vf,[n[7]||=H(`span`,{class:`typing-dots`},[H(`i`),H(`i`),H(`i`)],-1),ea(M(R(q).thinking),1)])):W(`v-if`,!0),(B(!0),V(z,null,Cr(m.value,t=>(B(),V(z,{key:t.key},[t.kind===`tools`?(B(),Ki(Tf,{key:0,items:t.items},null,8,[`items`])):(B(),V(z,{key:1},[t.item.kind===`thinking`?(B(),V(`details`,{key:0,class:`thinking`,open:f.value[t.index]??(i.value&&t.last)},[H(`summary`,{onClick:e=>x(t.index,t.last,e)},[U(nf,{state:i.value&&!t.last?`done`:_.value},null,8,[`state`]),U(K,{name:`chevron`,class:`chev`})],8,Uf),H(`div`,Wf,M(t.item.text),1)],8,Hf)):t.item.kind===`text`?(B(),V(`div`,Gf,[U(ef,{source:t.item.text,streaming:i.value&&t.last,onImage:n[0]||=e=>r(`image`,e)},null,8,[`source`,`streaming`])])):t.item.kind===`ask`?(B(),Ki(ic,{key:2,"ask-id":t.item.askId,spec:t.item.spec,answer:t.item.answer,pending:e.interactive&&!!e.pendingAsks?.has(t.item.askId),"turn-running":i.value,onAnswer:n[1]||=(e,t)=>r(`answer`,e,t)},null,8,[`ask-id`,`spec`,`answer`,`pending`,`turn-running`])):t.item.kind===`notice`?(B(),V(`div`,{key:3,class:k([`notice`,t.item.level])},[U(K,{name:`alert`}),ea(M(t.item.message),1)],2)):t.item.kind===`error`?(B(),V(`div`,Kf,[U(K,{name:`alert`}),H(`div`,qf,[H(`div`,Jf,M(p(t.item.message)?R(q).rateLimited:R(q).failed),1),H(`div`,Yf,M(t.item.message),1)])])):W(`v-if`,!0)],64))],64))),128)),i.value&&e.turn.items.length?(B(),V(`div`,{key:1,class:k([`indicator`,{writing:g.value}])},[g.value?(B(),V(`span`,Xf,M(R(q).writing),1)):(B(),V(z,{key:1},[n[8]||=H(`span`,{class:`typing-dots`},[H(`i`),H(`i`),H(`i`)],-1),ea(M(h.value?.kind===`tool`?R(q).running:R(q).thinking),1)],64))],2)):W(`v-if`,!0),s.value&&o.value!==`cancelled`?(B(),V(`div`,Zf,[U(K,{name:`alert`}),H(`span`,null,M(R(q).emptyReply),1),e.interactive&&!c.value?(B(),V(`button`,{key:0,class:`btn sm danger`,onClick:n[2]||=t=>r(`retry`,e.turn.id)},[U(K,{name:`refresh`}),ea(M(R(q).retry),1)])):W(`v-if`,!0)])):W(`v-if`,!0),e.turn.artifacts.length?(B(),V(`div`,Qf,[(B(!0),V(z,null,Cr(e.turn.artifacts,e=>(B(),V(`button`,{key:e.name+e.version,class:`chip art`,onClick:t=>r(`artifact`,e.name,e.version)},[U(K,{name:`file`}),ea(M(e.name)+` · v`+M(e.version),1)],8,$f))),128))])):W(`v-if`,!0),e.turn.files.length?(B(),V(`div`,ep,[H(`button`,{class:`files-head`,onClick:n[3]||=e=>d.value=!d.value},[U(K,{name:`edit`}),ea(M(R(q).changedFiles)+` (`+M(e.turn.files.length)+`)`,1),U(K,{name:`chevron`,style:O({transform:d.value?`rotate(180deg)`:``})},null,8,[`style`])]),d.value?(B(),V(`ul`,tp,[(B(!0),V(z,null,Cr(e.turn.files,e=>(B(),V(`li`,{key:e,class:`mono`},M(e),1))),128))])):W(`v-if`,!0)])):W(`v-if`,!0),u.value?(B(),Ki(hc,{key:5,agent:``,session:l.value,title:e.turn.user.text,view:l.value?e.liveViews?.[l.value.sid]:void 0,interactive:e.interactive,onOp:n[4]||=e=>r(`live`,e),onNav:n[5]||=(e,t,n)=>r(`nav`,e,t,n)},null,8,[`session`,`title`,`view`,`interactive`])):W(`v-if`,!0),i.value?W(`v-if`,!0):(B(),V(`div`,{key:6,class:`foot`,title:y.value},[H(`span`,{class:k([`st`,o.value])},[o.value===`done`?(B(),Ki(K,{key:0,name:`check`})):o.value===`running`?W(`v-if`,!0):(B(),Ki(K,{key:1,name:`alert`})),ea(M(v.value),1)],2),n[9]||=H(`span`,{class:`spacer`},null,-1),b.value?(B(),V(`button`,{key:0,class:`btn ghost sm`,onClick:n[6]||=t=>r(`retry`,e.turn.id)},[U(K,{name:`refresh`}),ea(M(R(q).retry),1)])):W(`v-if`,!0),H(`span`,null,M(R(Ds)(e.turn.endTs??e.turn.ts,e.now)),1)],8,np))])])],8,Ef))}}),[[`__scopeId`,`data-v-d25ee966`]]);function ip(e,t){let n=Kt(`connecting`),r=Kt(0),i=null,a=0,o=0,s=!1,c=()=>{if(s)return;r.value>0&&(n.value=r.value>2?`error`:`connecting`);let u=location.protocol===`https:`?`wss`:`ws`;i=new WebSocket(`${u}://${location.host}/__ph/ws`),i.onopen=()=>{r.value=0,n.value=`ready`,t(),clearInterval(o),o=window.setInterval(()=>l({type:`ping`}),25e3)},i.onmessage=t=>{try{e(JSON.parse(t.data))}catch(e){console.error(`[page-harness] bad message`,e)}},i.onclose=()=>{clearInterval(o),!s&&(r.value++,n.value=r.value>2?`error`:`connecting`,clearTimeout(a),a=window.setTimeout(c,Math.min(8e3,400*2**Math.min(r.value,5))))}},l=e=>i?.readyState===WebSocket.OPEN&&(i.send(JSON.stringify(e)),!0);return c(),{state:n,failures:r,send:l,reconnect(){r.value=0,i?.close(),clearTimeout(a),c()},close(){s=!0,i?.close()}}}export{H as A,B,zo as C,No as D,Fo as E,U as F,Ft as G,yr as H,Jn as I,R as J,Kt as K,vn as L,W as M,V as N,z as O,ea as P,fr as R,Yo as S,yo as T,Rn as U,Cr as V,jn as W,O as X,k as Y,M as Z,ls as _,$ as a,ts as b,Cs as c,Ts as d,q as f,K as g,fs as h,ef as i,Ki as j,G as k,ws as l,vs as m,rp as n,gc as o,_s as p,qt as q,sf as r,Es as s,ip as t,Ds as u,cs as v,bo as w,qo as x,$o as y,lr as z};
|