2024-12-03 19:38:44 +01:00
<!--
This is a single file build of the frontend.
It is automatically generated by the build process.
Do not edit this file directly.
To make changes, refer to the "Web UI" section in the README.
-->
<!DOCTYPE html>
2023-07-04 16:05:27 +02:00
< html >
< head >
< meta charset = "UTF-8" >
< meta name = "viewport" content = "width=device-width, initial-scale=1, maximum-scale=1" / >
2023-08-01 10:56:23 +02:00
< meta name = "color-scheme" content = "light dark" >
2024-11-07 22:31:10 +01:00
< title > 🦙 llama.cpp - chat< / title >
2024-12-03 19:38:44 +01:00
< script type = "module" crossorigin > ( f u n c t i o n ( ) { c o n s t t = d o c u m e n t . c r e a t e E l e m e n t ( " l i n k " ) . r e l L i s t ; i f ( t & & t . s u p p o r t s & & t . s u p p o r t s ( " m o d u l e p r e l o a d " ) ) r e t u r n ; f o r ( c o n s t r o f d o c u m e n t . q u e r y S e l e c t o r A l l ( ' l i n k [ r e l = " m o d u l e p r e l o a d " ] ' ) ) n ( r ) ; n e w M u t a t i o n O b s e r v e r ( r = > { f o r ( c o n s t i o f r ) i f ( i . t y p e = = = " c h i l d L i s t " ) f o r ( c o n s t s o f i . a d d e d N o d e s ) s . t a g N a m e = = = " L I N K " & & s . r e l = = = " m o d u l e p r e l o a d " & & n ( s ) } ) . o b s e r v e ( d o c u m e n t , { c h i l d L i s t : ! 0 , s u b t r e e : ! 0 } ) ; f u n c t i o n u ( r ) { c o n s t i = { } ; r e t u r n r . i n t e g r i t y & & ( i . i n t e g r i t y = r . i n t e g r i t y ) , r . r e f e r r e r P o l i c y & & ( i . r e f e r r e r P o l i c y = r . r e f e r r e r P o l i c y ) , r . c r o s s O r i g i n = = = " u s e - c r e d e n t i a l s " ? i . c r e d e n t i a l s = " i n c l u d e " : r . c r o s s O r i g i n = = = " a n o n y m o u s " ? i . c r e d e n t i a l s = " o m i t " : i . c r e d e n t i a l s = " s a m e - o r i g i n " , i } f u n c t i o n n ( r ) { i f ( r . e p ) r e t u r n ; r . e p = ! 0 ; c o n s t i = u ( r ) ; f e t c h ( r . h r e f , i ) } } ) ( ) ; / * *
* @vue/shared v3.5.13
* (c) 2018-present Yuxi (Evan) You and Vue contributors
* @license MIT
**//*! #__NO_SIDE_EFFECTS__ */function Be(e){const t=Object.create(null);for(const u of e.split(","))t[u]=1;return u=>u in t}const ee={},Pu=[],we=()=>{},dn=()=>!1,vu=e=>e.charCodeAt(0)===111& & e.charCodeAt(1)===110& & (e.charCodeAt(2)>122||e.charCodeAt(2)< 97 ) , Rs = e= > e.startsWith("onUpdate:"),te=Object.assign,Ms=(e,t)=>{const u=e.indexOf(t);u>-1& & e.splice(u,1)},Uf=Object.prototype.hasOwnProperty,re=(e,t)=>Uf.call(e,t),$=Array.isArray,Lu=e=>tn(e)==="[object Map]",Du=e=>tn(e)==="[object Set]",Ko=e=>tn(e)==="[object Date]",qf=e=>tn(e)==="[object RegExp]",W=e=>typeof e=="function",Z=e=>typeof e=="string",Ze=e=>typeof e=="symbol",oe=e=>e!==null& & typeof e=="object",Ps=e=>(oe(e)||W(e))& & W(e.then)& & W(e.catch),yl=Object.prototype.toString,tn=e=>yl.call(e),jf=e=>tn(e).slice(8,-1),ti=e=>tn(e)==="[object Object]",Ls=e=>Z(e)& & e!=="NaN"& & e[0]!=="-"& & ""+parseInt(e,10)===e,tu=Be(",key,ref,ref_for,ref_key,onVnodeBeforeMount,onVnodeMounted,onVnodeBeforeUpdate,onVnodeUpdated,onVnodeBeforeUnmount,onVnodeUnmounted"),zf=Be("bind,cloak,else-if,else,for,html,if,model,on,once,pre,show,slot,text,memo"),ui=e=>{const t=Object.create(null);return u=>t[u]||(t[u]=e(u))},Kf=/-(\w)/g,de=ui(e=>e.replace(Kf,(t,u)=>u?u.toUpperCase():"")),Wf=/\B([A-Z])/g,qe=ui(e=>e.replace(Wf,"-$1").toLowerCase()),Tu=ui(e=>e.charAt(0).toUpperCase()+e.slice(1)),Bu=ui(e=>e?`on${Tu(e)}`:""),He=(e,t)=>!Object.is(e,t),Vu=(e,...t)=>{for(let u=0;u< e.length ; u + + ) e [ u ] ( . . . t ) } , ju = (e,t,u,n=!1)= > {Object.defineProperty(e,t,{configurable:!0,enumerable:!1,writable:n,value:u})},Sr=e=>{const t=parseFloat(e);return isNaN(t)?e:t},vr=e=>{const t=Z(e)?Number(e):NaN;return isNaN(t)?e:t};let Wo;const gu=()=>Wo||(Wo=typeof globalThis< "u"?globalThis:typeof self< "u"?self:typeof window< "u"?window:typeof global< "u"?global:{});function Gf(e,t){return e+JSON.stringify(t,(u,n)=>typeof n=="function"?n.toString():n)}const Zf="Infinity,undefined,NaN,isFinite,isNaN,parseFloat,parseInt,decodeURI,decodeURIComponent,encodeURI,encodeURIComponent,Math,Number,Date,Array,Object,Boolean,String,RegExp,Map,Set,JSON,Intl,BigInt,console,Error,Symbol",Jf=Be(Zf);function un(e){if($(e)){const t={};for(let u=0;u< e.length ; u + + ) { const n = e[u],r=Z(n)?xl(n):un(n);if(r)for(const i in r ) t [ i ] = r [ i ] } return t } else if ( Z ( e ) | | oe ( e ) ) return e } const Yf = /;(?![^(]*\))/g,Xf=/:([^]+)/,Qf=/\/\*[^]*?\*\//g;function xl ( e ) { const t = {};return e . replace ( Qf , " " ) . split ( Yf ) . forEach ( u = > {if(u){const n = u.split(Xf);n.length > 1& & (t[n[0].trim()]=n[1].trim())}}),t}function ed(e){if(!e)return"";if(Z(e))return e;let t="";for(const u in e){const n=e[u];if(Z(n)||typeof n=="number"){const r=u.startsWith("--")?u:qe(u);t+=`${r}:${n};`}}return t}function nn(e){let t="";if(Z(e))t=e;else if($(e))for(let u=0;u< e.length ; u + + ) { const n = nn(e[u]);n&&(t+=n+" " ) } else if ( oe ( e ) ) for ( const u in e ) e [ u ] & & ( t + = u + " " ) ; return t . trim ( ) } function td ( e ) { if ( ! e ) return null ; let { class:t , style:u } = e ; return t & & ! Z ( t ) & & ( e . class = nn(t)),u&&(e.style=un(u)),e}const ud = "html,body,base,head,link,meta,style,title,address,article,aside,footer,header,hgroup,h1,h2,h3,h4,h5,h6,nav,section,div,dd,dl,dt,figcaption,figure,picture,hr,img,li,main,ol,p,pre,ul,a,b,abbr,bdi,bdo,br,cite,code,data,dfn,em,i,kbd,mark,q,rp,rt,ruby,s,samp,small,span,strong,sub,sup,time,u,var,wbr,area,audio,map,track,video,embed,object,param,source,canvas,script,noscript,del,ins,caption,col,colgroup,table,thead,tbody,td,th,tr,button,datalist,fieldset,form,input,label,legend,meter,optgroup,option,output,progress,select,textarea,details,dialog,menu,summary,template,blockquote,iframe,tfoot" , nd = "svg,animate,animateMotion,animateTransform,circle,clipPath,color-profile,defs,desc,discard,ellipse,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,filter,foreignObject,g,hatch,hatchpath,image,line,linearGradient,marker,mask,mesh,meshgradient,meshpatch,meshrow,metadata,mpath,path,pattern,polygon,polyline,radialGradi
* @vue/reactivity v3.5.13
* (c) 2018-present Yuxi (Evan) You and Vue contributors
* @license MIT
**/let $e;class Vs{constructor(t=!1){this.detached=t,this._active=!0,this.effects=[],this.cleanups=[],this._isPaused=!1,this.parent=$e,!t& & $e& & (this.index=($e.scopes||($e.scopes=[])).push(this)-1)}get active(){return this._active}pause(){if(this._active){this._isPaused=!0;let t,u;if(this.scopes)for(t=0,u=this.scopes.length;t< u ; t + + ) this . scopes [ t ] . pause ( ) ; for ( t = 0,u=this.effects.length;t<u;t++)this.effects[t].pause()}}resume(){if(this._active&&this._isPaused){this._isPaused=!1;let t , u ; if ( this . scopes ) for ( t = 0,u=this.scopes.length;t<u;t++)this.scopes[t].resume();for(t=0,u=this.effects.length;t<u;t++)this.effects[t].resume()}}run(t){if(this._active){const u = $e;try{return $ e = this,t()}finally{$e=u}}}on(){$e=this}off(){$e=this.parent}stop(t){if(this._active){this._active=!1;let u , n ; for ( u = 0,n=this.effects.length;u<n;u++)this.effects[u].stop();for(this.effects.length=0,u=0,n=this.cleanups.length;u<n;u++)this.cleanups[u]();if(this.cleanups.length=0,this.scopes){for(u=0,n=this.scopes.length;u<n;u++)this.scopes[u].stop(!0);this.scopes.length=0}if(!this.detached&&this.parent&&!t){const r = this.parent.scopes.pop();r&&r!==this&&(this.parent.scopes[this.index]=r,r.index=this.index)}this.parent=void 0 } } } function gd ( e ) { return new Vs ( e ) } function Sl ( ) { return $ e } function _d ( e , t = !1){$e&&$e.cleanups.push(e)}let le ; const Ri = new WeakSet ; class vn { constructor ( t ) { this . fn = t,this.deps=void 0 , this . depsTail = void 0 , this . flags = 5,this.next=void 0 , this . cleanup = void 0 , this . scheduler = void 0 , $ e & & $ e . active & & $ e . effects . push ( this ) } pause ( ) { this . flags | = 64 } resume ( ) { this . flags & 64 & & ( this . flags & = -65 , Ri . has ( this ) & & ( Ri . delete ( this ) , this . trigger ( ) ) ) } notify ( ) { this . flags & 2 & & ! ( this . flags & 32 ) | | this . flags & 8 | | Dl ( this ) } run ( ) { if ( ! ( this . flags & 1 ) ) return this . fn ( ) ; this . flags | = 2 , Zo ( this ) , Tl ( this ) ; const t = le,u=bt;le=this,bt=!0;try{return this . fn ( ) } finally { wl ( this ) , le = t,bt=u,this.flags&=-3}}stop(){if(this.flags&1){for(let t = this.deps;t;t=t.nextDep)Us(t);this.deps=this.depsTail=void 0 , Zo ( this ) , this . onStop & & this . onStop ( ) , this . flags & = -2 } } trigger ( ) { this . flags & 64 ? Ri . add ( this ) :this . scheduler ? this . scheduler ( ) :this . runIfDirty ( ) } runIfDirty ( ) { ts ( this ) & & this . run ( ) } get dirty ( ) { return ts ( this ) } } let vl = 0,gn,_n;function Dl ( e , t = !1){if(e.flags|=8,t){e.next=_n,_n=e;return}e.next=gn,gn=e}function $ s ( ) { vl + + } function Hs ( ) { if ( --vl > 0)return;if(_n){let t=_n;for(_n=void 0;t;){const u=t.next;t.next=void 0,t.flags& =-9,t=u}}let e;for(;gn;){let t=gn;for(gn=void 0;t;){const u=t.next;if(t.next=void 0,t.flags& =-9,t.flags& 1)try{t.trigger()}catch(n){e||(e=n)}t=u}}if(e)throw e}function Tl(e){for(let t=e.deps;t;t=t.nextDep)t.version=-1,t.prevActiveLink=t.dep.activeLink,t.dep.activeLink=t}function wl(e){let t,u=e.depsTail,n=u;for(;n;){const r=n.prevDep;n.version===-1?(n===u& & (u=r),Us(n),yd(n)):t=n,n.dep.activeLink=n.prevActiveLink,n.prevActiveLink=void 0,n=r}e.deps=t,e.depsTail=u}function ts(e){for(let t=e.deps;t;t=t.nextDep)if(t.dep.version!==t.version||t.dep.computed&&(Fl(t.dep.computed)||t.dep.version!==t.version))return!0; return!!e._dirty}function Fl(e){if(e.flags&4&&!(e.flags&16)||(e.flags&=-17,e.globalVersion===Dn))return; e.globalVersion=Dn;const t=e.dep;if(e.flags|=2,t.version>0&&!e.isSSR&&e.deps&&!ts(e)){e.flags&=-3; return}const u=le,n=bt;le=e,bt=!0;try{Tl(e);const r=e.fn(e._value);(t.version===0||He(r,e._value))& & (e._value=r,t.version++)}catch(r){throw t.version++,r}finally{le=u,bt=n,wl(e),e.flags& =-3}}function Us(e,t=!1){const{dep:u,prevSub:n,nextSub:r}=e;if(n& & (n.nextSub=r,e.prevSub=void 0),r& & (r.prevSub=n,e.nextSub=void 0),u.subs===e&&(u.subs=n,!n&&u.computed)){u.computed.flags&=-5; for(let i=u.computed.deps;i;i=i.nextDep)Us(i,!0)}!t& & !--u.sc& & u.map& & u.map.delete(u.key)}function yd(e){const{prevDep:t,nextDep:u}=e;t& & (t.nextDep=u,e.prevDep=void 0),u& & (u.prevDep=t,e.nextDep=void 0)}function xd(e,t){e.effect instanceof vn&&(e=e.effect.fn); const u=new vn(e);t&&te(u,t); try{u.run()}catch(r){throw u.stop(),r}const n=u.run.bind(u);return n.effect=u,n}function Ed(e){e.effect.stop()}let bt=!0;const Il=[];function $t(){Il.push(bt),bt=!1}function Ht(){const e=Il.pop();bt=e===void 0?!0:e}function Zo(e){const{cleanup:t}=e;if(e
* @vue/runtime-core v3.5.13
* (c) 2018-present Yuxi (Evan) You and Vue contributors
* @license MIT
**/const yu=[];function uh(e){yu.push(e)}function nh(){yu.pop()}let Li=!1;function zt(e,...t){if(Li)return;Li=!0,$t();const u=yu.length?yu[yu.length-1].component:null,n=u&&u.appContext.config.warnHandler,r=rh(); if(n)wu(n,u,11,[e+t.map(i=>{var s,o;return(o=(s=i.toString)==null?void 0:s.call(i))!=null?o:JSON.stringify(i)}).join(""),u& & u.proxy,r.map(({vnode:i})=>`at < ${e0(u,i.type)}>`).join(`
`),r]);else{const i=[`[Vue warn]: ${e}`,...t];r.length& & i.push(`
`,...ih(r)),console.warn(...i)}Ht(),Li=!1}function rh(){let e=yu[yu.length-1];if(!e)return[];const t=[];for(;e;){const u=t[0];u&&u.vnode===e?u.recurseCount++:t.push({vnode:e,recurseCount:0}); const n=e.component&&e.component.parent; e=n& & n.vnode}return t}function ih(e){const t=[];return e.forEach((u,n)=>{t.push(...n===0?[]:[`
`],...sh(u))}),t}function sh({vnode:e,recurseCount:t}){const u=t>0?`... (${t} recursive calls)`:"",n=e.component?e.component.parent==null:!1,r=` at < ${e0(e.component,e.type,n)}`,i=">"+u;return e.props?[r,...oh(e.props),i]:[r+i]}function oh(e){const t=[],u=Object.keys(e);return u.slice(0,3).forEach(n=>{t.push(...Wl(n,e[n]))}),u.length>3& & t.push(" ..."),t}function Wl(e,t,u){return Z(t)?(t=JSON.stringify(t),u?t:[`${e}=${t}`]):typeof t=="number"||typeof t=="boolean"||t==null?u?t:[`${e}=${t}`]:Ce(t)?(t=Wl(e,Q(t.value),!0),u?t:[`${e}=Ref< `,t,">"]):W(t)?[`${e}=fn${t.name?`< ${t.name}>`:""}`]:(t=Q(t),u?t:[`${e}=`,t])}function ch(e,t){}const lh={SETUP_FUNCTION:0,0:"SETUP_FUNCTION",RENDER_FUNCTION:1,1:"RENDER_FUNCTION",NATIVE_EVENT_HANDLER:5,5:"NATIVE_EVENT_HANDLER",COMPONENT_EVENT_HANDLER:6,6:"COMPONENT_EVENT_HANDLER",VNODE_HOOK:7,7:"VNODE_HOOK",DIRECTIVE_HOOK:8,8:"DIRECTIVE_HOOK",TRANSITION_HOOK:9,9:"TRANSITION_HOOK",APP_ERROR_HANDLER:10,10:"APP_ERROR_HANDLER",APP_WARN_HANDLER:11,11:"APP_WARN_HANDLER",FUNCTION_REF:12,12:"FUNCTION_REF",ASYNC_COMPONENT_LOADER:13,13:"ASYNC_COMPONENT_LOADER",SCHEDULER:14,14:"SCHEDULER",COMPONENT_UPDATE:15,15:"COMPONENT_UPDATE",APP_UNMOUNT_CLEANUP:16,16:"APP_UNMOUNT_CLEANUP"},ah={sp:"serverPrefetch hook",bc:"beforeCreate hook",c:"created hook",bm:"beforeMount hook",m:"mounted hook",bu:"beforeUpdate hook",u:"updated",bum:"beforeUnmount hook",um:"unmounted hook",a:"activated hook",da:"deactivated hook",ec:"errorCaptured hook",rtc:"renderTracked hook",rtg:"renderTriggered hook",0:"setup function",1:"render function",2:"watcher getter",3:"watcher callback",4:"watcher cleanup function",5:"native event handler",6:"component event handler",7:"vnode hook",8:"directive hook",9:"transition hook",10:"app errorHandler",11:"app warnHandler",12:"ref function",13:"async component loader",14:"scheduler flush",15:"component update",16:"app unmount cleanup function"};function wu(e,t,u,n){try{return n?e(...n):e()}catch(r){Fu(r,t,u)}}function lt(e,t,u,n){if(W(e)){const r=wu(e,t,u,n);return r& & Ps(r)& & r.catch(i=>{Fu(i,t,u)}),r}if($(e)){const r=[];for(let i=0;i< e.length ; i + + ) r . push ( lt ( e [ i ] , t , u , n ) ) ; return r } } function Fu ( e , t , u , n = !0){const r = t?t.vnode:null,{errorHandler:i,throwUnhandledErrorInProduction:s}=t&&t.appContext.config||ee;if(t){let o = t.parent;const c = t.proxy,l=`https://vuejs.org/error-reference/#runtime-${u}`;for(;o;){const a = o.ec;if(a){for(let f = 0;f<a.length;f++)if(a[f](e,c,l)===!1)return}o=o.parent}if(i){$t(),wu(i,null,10,[e,c,l]),Ht();return}}fh(e,u,r,n,s)}function fh ( e , t , u , n = !0,r=!1){if(r)throw e ; console . error ( e ) } const Ue = [];let Ct = -1;const $ u = [];let Gt = null,Mu=0;const Gl = Promise.resolve();let wr = null;function fi ( e ) { const t = wr||Gl;return e ? t . then ( this ? e . bind ( this ) :e ) :t } function dh ( e ) { let t = Ct+1,u=Ue.length;for(;t<u;){const n = t+u > >>1,r=Ue[n],i=Fn(r);i< e | | i = ==e&&r.flags&2?t=n+1:u=n}return t } function Ks ( e ) { if ( ! ( e . flags & 1 ) ) { const t = Fn(e),u=Ue[Ue.length-1];!u||!(e.flags&2)&&t > =Fn(u)?Ue.push(e):Ue.splice(dh(t),0,e),e.flags|=1,Zl()}}function Zl(){wr||(wr=Gl.then(Jl))}function wn(e){$(e)?$u.push(...e):Gt& & e.id===-1?Gt.splice(Mu+1,0,e):e.flags& 1||($u.push(e),e.flags|=1),Zl()}function Yo(e,t,u=Ct+1){for(;u< Ue.length ; u + + ) { const n = Ue[u];if(n&&n.flags&2){if(e&&n.id!==e.uid)continue;Ue.splice(u,1),u--,n.flags&4&&(n.flags&=-2),n(),n.flags&4||(n.flags&=-2)}}}function Fr ( e ) { if ( $ u . length ) { const t = [...new Set ( $ u ) ] . sort ( ( u , n ) = > Fn(u)-Fn(n));if($u.length=0,Gt){Gt.push(...t);return}for(Gt=t,Mu=0;Mu< Gt.length ; Mu + + ) { const u = Gt[Mu];u.flags&4&&(u.flags&=-2),u.flags&8||u(),u.flags&=-2}Gt=null,Mu=0}}const Fn = e= > e.id==null?e.flags&2?-1:1/0:e.id; function Jl(e){try{for(Ct=0;Ct< Ue.length ; Ct + + ) { const t = Ue[Ct];t&&!(t.flags&8)&&(t.flags&4&&(t.flags&=-2),wu(t,t.i,t.i?15:14),t.flags&4||(t.flags&=-2))}}finally{for(;Ct<Ue.length;Ct++){const t = Ue[Ct];t&&(t.flags&=-2)}Ct=-1,Ue.length=0,Fr(),wr=null,(Ue.length||$u.length)&&Jl()}}let pt , hn = [],is=!1;function di ( e , . . . t ) { pt ? pt . emit ( e , . . . t ) :is | | hn . push ( { event:e , args:t } ) } function Ws ( e , t ) { var u , n ; pt = e,pt?(pt.enabled=!0,hn.forEach(({event:r,args:i})= > pt.emit(r,...i)),hn=[]):typeof window< "u"& & window.HTMLElement&
- rendered on server: ${JSON.stringify(m.data)}
- expected on client: ${JSON.stringify(g.children)}`),au(),m.data=g.children),H=i(m));break;case ye:E(m)?(H=i(m),A(g.el=m.content.firstChild,m,x)):z!==8||C?H=S():H=i(m);break;case ru:if(C&&(m=i(m),z=m.nodeType),z===1||z===3){H=m; const J=!g.children.length;for(let j=0;j< g.staticCount ; j + + ) J & & ( g . children + = H . nodeType = ==1?H.outerHTML:H.data),j===g.staticCount-1&&(g.anchor=H),H=i(H);return C ? i ( H ) :H } else S ( ) ; break ; case Ee:C ? H = h(m,g,x,k,I,w):H=S();break;default:if(P&1)(z!==1||g.type.toLowerCase()!==m.tagName.toLowerCase())&&!E(m)?H=S():H=p(m,g,x,k,I,w);else if ( P & 6 ) { g . slotScopeIds = I;const J = s(m);if(C?H=v(m):pu(m)&&m.data==="teleport start " ? H = v(m,m.data,"teleport end " ) :H = i(m),t(g,J,null,x,k,lr(J),w),nu(g)&&!g.type.__asyncResolved){let j ; C ? ( j = fe(Ee),j.anchor=H?H.previousSibling:J.lastChild):j=m.nodeType===3?oo(""):fe("div"),j.el=m,g.component.subTree=j}}else P & 64 ? z ! = = 8 ? H = S():H=g.type.hydrate(m,g,x,k,I,w,e,d):P&128?H=g.type.hydrate(m,g,x,k,lr(s(m)),I,w,e,f):__VUE_PROD_HYDRATION_MISMATCH_DETAILS__&&zt("Invalid HostVNode type: " , R , ` ( $ { typeof R } ) ` ) } return T ! = null & & On ( T , null , k , g ) , H } , p = (m,g,x,k,I,w)= > {w=w||!!g.dynamicChildren;const{type:C,props:S,patchFlag:R,shapeFlag:T,dirs:P,transition:q}=g,z=C==="input"||C==="option";if(z||R!==-1){P&&kt(g,null,x,"created"); let H=!1;if(E(m)){H=Na(null,q)&&x&&x.vnode.props&&x.vnode.props.appear; const j=m.content.firstChild;H& & q.beforeEnter(j),A(j,m,x),g.el=m=j}if(T& 16& & !(S& & (S.innerHTML||S.textContent))){let j=d(m.firstChild,g,m,x,k,I,w),be=!1;for(;j;){pn(m,1)||(__VUE_PROD_HYDRATION_MISMATCH_DETAILS__& & !be& & (zt("Hydration children mismatch on",m,`
Server rendered element contains more child nodes than client vdom.`),be=!0),au());const je=j;j=j.nextSibling,o(je)}}else if(T& 8){let j=g.children;j[0]===`
`& & (m.tagName==="PRE"||m.tagName==="TEXTAREA")& & (j=j.slice(1)),m.textContent!==j& & (pn(m,0)||(__VUE_PROD_HYDRATION_MISMATCH_DETAILS__& & zt("Hydration text content mismatch on",m,`
- rendered on server: ${m.textContent}
- expected on client: ${g.children}`),au()),m.textContent=g.children)}if(S){if(__VUE_PROD_HYDRATION_MISMATCH_DETAILS__||z||!w||R& 48){const j=m.tagName.includes("-");for(const be in S)__VUE_PROD_HYDRATION_MISMATCH_DETAILS__& & !(P& & P.some(je=>je.dir.created))& & Fh(m,be,S[be],g,x)& & au(),(z& & (be.endsWith("value")||be==="indeterminate")||vu(be)& & !tu(be)||be[0]==="."||j)& & n(m,be,null,S[be],void 0,x)}else if(S.onClick)n(m,"onClick",null,S.onClick,void 0,x);else if(R& 4& & uu(S.style))for(const j in S.style)S.style[j]}let J;(J=S& & S.onVnodeBeforeMount)& & Ke(J,x,g),P& & kt(g,null,x,"beforeMount"),((J=S& & S.onVnodeMounted)||P||H)& & Ua(()=>{J& & Ke(J,x,g),H& & q.enter(m),P& & kt(g,null,x,"mounted")},k)}return m.nextSibling},d=(m,g,x,k,I,w,C)=>{C=C||!!g.dynamicChildren;const S=g.children,R=S.length;let T=!1;for(let P=0;P< R ; P + + ) { const q = C?S[P]:S[P]=We(S[P]),z=q.type===Pt;m?(z&&!C&&P+1<R&&We(S[P+1]).type===Pt&&(c(r(m.data.slice(q.children.length)),x,i(m)),m.data=q.children),m=f(m,q,k,I,w,C)):z&&!q.children?c(q.el=r(""),x):(pn(x,1)||(__VUE_PROD_HYDRATION_MISMATCH_DETAILS__&&!T&&(zt("Hydration children mismatch on " , x , `
Server rendered element contains fewer child nodes than client vdom.`),T=!0),au()),u(null,q,x,null,k,I,lr(x),w))}return m},h=(m,g,x,k,I,w)=>{const{slotScopeIds:C}=g;C&&(I=I?I.concat(C):C); const S=s(m),R=d(i(m),g,S,x,k,I,w);return R& & pu(R)& & R.data==="]"?i(g.anchor=R):(au(),c(g.anchor=l("]"),S,R),R)},_=(m,g,x,k,I,w)=>{if(pn(m.parentElement,1)||(__VUE_PROD_HYDRATION_MISMATCH_DETAILS__& & zt(`Hydration node mismatch:
- rendered on server:`,m,m.nodeType===3?"(text)":pu(m)& & m.data==="["?"(start of fragment)":"",`
- expected on client:`,g.type),au()),g.el=null,w){const R=v(m);for(;;){const T=i(m);if(T&&T!==R)o(T); else break}}const C=i(m),S=s(m);return o(m),u(null,g,S,C,x,k,lr(S),I),x& & (x.vnode.el=g.el,xi(x,g.el)),C},v=(m,g="[",x="]")=>{let k=0;for(;m;)if(m=i(m),m& & pu(m)& & (m.data===g& & k++,m.data===x)){if(k===0)return i(m);k--}return m},A=(m,g,x)=>{const k=g.parentNode;k&&k.replaceChild(m,g); let I=x;for(;I;)I.vnode.el===g&&(I.vnode.el=I.subTree.el=m),I=I.parent},E=m=>m.nodeType===1&&m.tagName==="TEMPLATE"; return[a,f]}function Fh(e,t,u,n,r){let i,s,o,c;if(t==="class")o=e.getAttribute("class"),c=nn(u),Ih(nc(o||""),nc(c))||(i=2,s="class");else if(t==="style"){o=e.getAttribute("style")||"",c=Z(u)?u:ed(un(u));const l=rc(o),a=rc(c);if(n.dirs)for(const{dir:f,value:p}of n.dirs)f.name==="show"&&!p&&a.set("display","none"); r& & sa(r,n,a),Oh(l,a)||(i=3,s="style")}else(e instanceof SVGElement& & dd(t)||e instanceof HTMLElement&&(Go(t)||fd(t)))&&(Go(t)?(o=e.hasAttribute(t),c=Bs(u)):u==null?(o=e.hasAttribute(t),c=!1):(e.hasAttribute(t)?o=e.getAttribute(t):t==="value"&&e.tagName==="TEXTAREA"?o=e.value:o=!1,c=hd(u)?String(u):!1),o!==c&&(i=4,s=t)); if(i!=null& & !pn(e,i)){const l=p=>p===!1?"(not rendered)":`${s}="${p}"`,a=`Hydration ${oa[i]} mismatch on`,f=`
- rendered on server: ${l(o)}
- expected on client: ${l(c)}
Note: this mismatch is check-only. The DOM will not be rectified in production due to performance overhead.
You should fix the source of the mismatch.`;return zt(a,e,f),!0}return!1}function nc(e){return new Set(e.trim().split(/\s+/))}function Ih(e,t){if(e.size!==t.size)return!1;for(const u of e)if(!t.has(u))return!1;return!0}function rc(e){const t=new Map;for(const u of e.split(";")){let[n,r]=u.split(":");n=n.trim(),r=r& & r.trim(),n& & r& & t.set(n,r)}return t}function Oh(e,t){if(e.size!==t.size)return!1;for(const[u,n]of e)if(n!==t.get(u))return!1;return!0}function sa(e,t,u){const n=e.subTree;if(e.getCssVars& & (t===n||n& & n.type===Ee& & n.children.includes(t))){const r=e.getCssVars();for(const i in r)u.set(`--${md(i)}`,String(r[i]))}t===n& & e.parent& & sa(e.parent,e.vnode,u)}const ic="data-allow-mismatch",oa={0:"text",1:"children",2:"class",3:"style",4:"attribute"};function pn(e,t){if(t===0||t===1)for(;e&&!e.hasAttribute(ic); )e=e.parentElement;const u=e&&e.getAttribute(ic); if(u==null)return!1;if(u==="")return!0;{const n=u.split(",");return t===0& & n.includes("children")?!0:u.split(",").includes(oa[t])}}const Nh=gu().requestIdleCallback||(e=>setTimeout(e,1)),Rh=gu().cancelIdleCallback||(e=>clearTimeout(e)),Mh=(e=1e4)=>t=>{const u=Nh(t,{timeout:e});return()=>Rh(u)};function Ph(e){const{top:t,left:u,bottom:n,right:r}=e.getBoundingClientRect(),{innerHeight:i,innerWidth:s}=window;return(t>0& & t< i | | n > 0& & n< i ) & & ( u > 0& & u< s | | r > 0& & r< s ) } const Lh = e= > (t,u)=>{const n=new IntersectionObserver(r=>{for(const i of r)if(i.isIntersecting){n.disconnect(),t();break}},e);return u(r=>{if(r instanceof Element){if(Ph(r))return t(),n.disconnect(),!1;n.observe(r)}}),()=>n.disconnect()},Bh=e=>t=>{if(e){const u=matchMedia(e);if(u.matches)t();else return u.addEventListener("change",t,{once:!0}),()=>u.removeEventListener("change",t)}},Vh=(e=[])=>(t,u)=>{Z(e)&&(e=[e]); let n=!1;const r=s=>{n||(n=!0,i(),t(),s.target.dispatchEvent(new s.constructor(s.type,s)))},i=()=>{u(s=>{for(const o of e)s.removeEventListener(o,r)})};return u(s=>{for(const o of e)s.addEventListener(o,r,{once:!0})}),i};function $h(e,t){if(pu(e)& & e.data==="["){let u=1,n=e.nextSibling;for(;n;){if(n.nodeType===1){if(t(n)===!1)break}else if(pu(n))if(n.data==="]"){if(--u===0)break}else n.data==="["&&u++; n=n.nextSibling}}else t(e)}const nu=e=>!!e.type.__asyncLoader;/*! #__NO_SIDE_EFFECTS__ */function Hh(e){W(e)&&(e={loader:e}); const{loader:t,loadingComponent:u,errorComponent:n,delay:r=200,hydrate:i,timeout:s,suspensible:o=!0,onError:c}=e;let l=null,a,f=0;const p=()=>(f++,l=null,d()),d=()=>{let h;return l||(h=l=t().catch(_=>{if(_=_ instanceof Error?_:new Error(String(_)),c)return new Promise((v,A)=>{c(_,()=>v(p()),()=>A(_),f+1)});throw _}).then(_=>h!==l&&l?l:(_&&(_.__esModule||_[Symbol.toStringTag]==="Module")&&(_=_.default),a=_,_)))}; return Kn({name:"AsyncComponentWrapper",__asyncLoader:d,__asyncHydrate(h,_,v){const A=i?()=>{const E=i(v,m=>$h(h,m));E&&(_.bum||(_.bum=[])).push(E)}:v; a?A():d().then(()=>!_.isUnmounted& & A())},get __asyncResolved(){return a},setup(){const h=Se;if(Xs(h),a)return()=>Vi(a,h);const _=m=>{l=null,Fu(m,h,13,!n)};if(o& & h.suspense||Ku)return d().then(m=>()=>Vi(m,h)).catch(m=>(_(m),()=>n?fe(n,{error:m}):null));const v=yn(!1),A=yn(),E=yn(!!r);return r& & setTimeout(()=>{E.value=!1},r),s!=null& & setTimeout(()=>{if(!v.value& & !A.value){const m=new Error(`Async component timed out after ${s}ms.`);_(m),A.value=m}},s),d().then(()=>{v.value=!0,h.parent& & Wn(h.parent.vnode)& & h.parent.update()}).catch(m=>{_(m),A.value=m}),()=>{if(v.value& & a)return Vi(a,h);if(A.value& & n)return fe(n,{error:A.value});if(u& & !E.value)return fe(u)}}})}function Vi(e,t){const{ref:u,props:n,children:r,ce:i}=t.vnode,s=fe(e,n,r);return s.ref=u,s.ce=i,delete t.vnode.ce,s}const Wn=e=>e.type.__isKeepAlive,Uh={name:"KeepAlive",__isKeepAlive:!0,props:{include:[String,RegExp,Array],exclude:[String,RegExp,Array],max:[String,Number]},setup(e,{slots:t}){const u=ft(),n=u.ctx;if(!n.renderer)return()=>{const E=t.default&&t.default(); return E&&E.length===1?E[0]:E}; const r=new Map,i=new Set;let s=null;__VUE_PROD_DEVTOOLS__&&(u.__v_cache=r); const o=u.suspense,{renderer:{p:c,m:l,um:a,o:{createElement:f}}}=n,p=f("div");n.activate=(E,m,g,x,k)=>{const I
* @vue/runtime-dom v3.5.13
* (c) 2018-present Yuxi (Evan) You and Vue contributors
* @license MIT
**/let xs;const hc=typeof window< "u"&&window.trustedTypes; if(hc)try{xs=hc.createPolicy("vue",{createHTML:e=>e})}catch{}const u0=xs?e=>xs.createHTML(e):e=>e,mp="http://www.w3.org/2000/svg",bp="http://www.w3.org/1998/Math/MathML",Ot=typeof document< "u"?document:null,pc=Ot& & Ot.createElement("template"),gp={insert:(e,t,u)=>{t.insertBefore(e,u||null)},remove:e=>{const t=e.parentNode;t& & t.removeChild(e)},createElement:(e,t,u,n)=>{const r=t==="svg"?Ot.createElementNS(mp,e):t==="mathml"?Ot.createElementNS(bp,e):u?Ot.createElement(e,{is:u}):Ot.createElement(e);return e==="select"& & n& & n.multiple!=null& & r.setAttribute("multiple",n.multiple),r},createText:e=>Ot.createTextNode(e),createComment:e=>Ot.createComment(e),setText:(e,t)=>{e.nodeValue=t},setElementText:(e,t)=>{e.textContent=t},parentNode:e=>e.parentNode,nextSibling:e=>e.nextSibling,querySelector:e=>Ot.querySelector(e),setScopeId(e,t){e.setAttribute(t,"")},insertStaticContent(e,t,u,n,r,i){const s=u?u.previousSibling:t.lastChild;if(r&&(r===i||r.nextSibling))for(; t.insertBefore(r.cloneNode(!0),u),!(r===i||!(r=r.nextSibling)););else{pc.innerHTML=u0(n==="svg"?`< svg > ${e}< / svg > `:n==="mathml"?`< math > ${e}< / math > `:e);const o=pc.content;if(n==="svg"||n==="mathml"){const c=o.firstChild;for(;c.firstChild;)o.appendChild(c.firstChild);o.removeChild(c)}t.insertBefore(o,u)}return[s?s.nextSibling:t.firstChild,u?u.previousSibling:t.lastChild]}},qt="transition",ln="animation",Wu=Symbol("_vtc"),n0={name:String,type:String,css:{type:Boolean,default:!0},duration:[String,Number,Object],enterFromClass:String,enterActiveClass:String,enterToClass:String,appearFromClass:String,appearActiveClass:String,appearToClass:String,leaveFromClass:String,leaveActiveClass:String,leaveToClass:String},r0=te({},Ys,n0),_p=e=>(e.displayName="Transition",e.props=r0,e),yp=_p((e,{slots:t})=>ao(ra,i0(e),t)),du=(e,t=[])=>{$(e)?e.forEach(u=>u(...t)):e&&e(...t)},mc=e=>e?$(e)?e.some(t=>t.length>1):e.length>1:!1; function i0(e){const t={};for(const T in e)T in n0||(t[T]=e[T]);if(e.css===!1)return t;const{name:u="v",type:n,duration:r,enterFromClass:i=`${u}-enter-from`,enterActiveClass:s=`${u}-enter-active`,enterToClass:o=`${u}-enter-to`,appearFromClass:c=i,appearActiveClass:l=s,appearToClass:a=o,leaveFromClass:f=`${u}-leave-from`,leaveActiveClass:p=`${u}-leave-active`,leaveToClass:d=`${u}-leave-to`}=e,h=xp(r),_=h& & h[0],v=h& & h[1],{onBeforeEnter:A,onEnter:E,onEnterCancelled:m,onLeave:g,onLeaveCancelled:x,onBeforeAppear:k=A,onAppear:I=E,onAppearCancelled:w=m}=t,C=(T,P,q,z)=>{T._enterCancelled=z,Kt(T,P?a:o),Kt(T,P?l:s),q& & q()},S=(T,P)=>{T._isLeaving=!1,Kt(T,f),Kt(T,d),Kt(T,p),P& & P()},R=T=>(P,q)=>{const z=T?I:E,H=()=>C(P,T,q);du(z,[P,H]),bc(()=>{Kt(P,T?c:i),Et(P,T?a:o),mc(z)||gc(P,n,_,H)})};return te(t,{onBeforeEnter(T){du(A,[T]),Et(T,i),Et(T,s)},onBeforeAppear(T){du(k,[T]),Et(T,c),Et(T,l)},onEnter:R(!1),onAppear:R(!0),onLeave(T,P){T._isLeaving=!0;const q=()=>S(T,P);Et(T,f),T._enterCancelled?(Et(T,p),Es()):(Es(),Et(T,p)),bc(()=>{T._isLeaving& & (Kt(T,f),Et(T,d),mc(g)||gc(T,n,v,q))}),du(g,[T,q])},onEnterCancelled(T){C(T,!1,void 0,!0),du(m,[T])},onAppearCancelled(T){C(T,!0,void 0,!0),du(w,[T])},onLeaveCancelled(T){S(T),du(x,[T])}})}function xp(e){if(e==null)return null;if(oe(e))return[qi(e.enter),qi(e.leave)];{const t=qi(e);return[t,t]}}function qi(e){return vr(e)}function Et(e,t){t.split(/\s+/).forEach(u=>u& & e.classList.add(u)),(e[Wu]||(e[Wu]=new Set)).add(t)}function Kt(e,t){t.split(/\s+/).forEach(n=>n&&e.classList.remove(n)); const u=e[Wu];u& & (u.delete(t),u.size||(e[Wu]=void 0))}function bc(e){requestAnimationFrame(()=>{requestAnimationFrame(e)})}let Ep=0;function gc(e,t,u,n){const r=e._endId=++Ep,i=()=>{r===e._endId&&n()}; if(u!=null)return setTimeout(i,u);const{type:s,timeout:o,propCount:c}=s0(e,t);if(!s)return n();const l=s+"end";let a=0;const f=()=>{e.removeEventListener(l,p),i()},p=d=>{d.target===e&&++a>=c&&f()}; setTimeout(()=>{a< c & & f ( ) } , o + 1 ) , e . addEventListener ( l , p ) } function s0 ( e , t ) { const u = window.getComputedStyle(e),n=h= > (u[h]||"").split(", "),r=n(`${qt}Delay`),i=n(`${qt}Duration`),s=_c(r,i),o=n(`${ln}Delay`),c=n(`${ln}Duration`),
* @vue/compiler-core v3.5.13
* (c) 2018-present Yuxi (Evan) You and Vue contributors
* @license MIT
**/const Pn=Symbol(""),Sn=Symbol(""),po=Symbol(""),qr=Symbol(""),S0=Symbol(""),Su=Symbol(""),v0=Symbol(""),D0=Symbol(""),mo=Symbol(""),bo=Symbol(""),Yn=Symbol(""),go=Symbol(""),T0=Symbol(""),_o=Symbol(""),yo=Symbol(""),xo=Symbol(""),Eo=Symbol(""),Co=Symbol(""),ko=Symbol(""),w0=Symbol(""),F0=Symbol(""),Ci=Symbol(""),jr=Symbol(""),Ao=Symbol(""),So=Symbol(""),Ln=Symbol(""),Xn=Symbol(""),vo=Symbol(""),ks=Symbol(""),r2=Symbol(""),As=Symbol(""),zr=Symbol(""),i2=Symbol(""),s2=Symbol(""),Do=Symbol(""),o2=Symbol(""),c2=Symbol(""),To=Symbol(""),I0=Symbol(""),Zu={[Pn]:"Fragment",[Sn]:"Teleport",[po]:"Suspense",[qr]:"KeepAlive",[S0]:"BaseTransition",[Su]:"openBlock",[v0]:"createBlock",[D0]:"createElementBlock",[mo]:"createVNode",[bo]:"createElementVNode",[Yn]:"createCommentVNode",[go]:"createTextVNode",[T0]:"createStaticVNode",[_o]:"resolveComponent",[yo]:"resolveDynamicComponent",[xo]:"resolveDirective",[Eo]:"resolveFilter",[Co]:"withDirectives",[ko]:"renderList",[w0]:"renderSlot",[F0]:"createSlots",[Ci]:"toDisplayString",[jr]:"mergeProps",[Ao]:"normalizeClass",[So]:"normalizeStyle",[Ln]:"normalizeProps",[Xn]:"guardReactiveProps",[vo]:"toHandlers",[ks]:"camelize",[r2]:"capitalize",[As]:"toHandlerKey",[zr]:"setBlockTracking",[i2]:"pushScopeId",[s2]:"popScopeId",[Do]:"withCtx",[o2]:"unref",[c2]:"isRef",[To]:"withMemo",[I0]:"isMemoSame"};function l2(e){Object.getOwnPropertySymbols(e).forEach(t=>{Zu[t]=e[t]})}const rt={start:{line:1,column:1,offset:0},end:{line:1,column:1,offset:0},source:""};function a2(e,t=""){return{type:0,source:t,children:e,helpers:new Set,components:[],directives:[],hoists:[],imports:[],cached:[],temps:0,codegenNode:void 0,loc:rt}}function Bn(e,t,u,n,r,i,s,o=!1,c=!1,l=!1,a=rt){return e& & (o?(e.helper(Su),e.helper(Xu(e.inSSR,l))):e.helper(Yu(e.inSSR,l)),s& & e.helper(Co)),{type:13,tag:t,props:u,children:n,patchFlag:r,dynamicProps:i,directives:s,isBlock:o,disableTracking:c,isComponent:l,loc:a}}function Eu(e,t=rt){return{type:17,loc:t,elements:e}}function ot(e,t=rt){return{type:15,loc:t,properties:e}}function xe(e,t){return{type:16,loc:rt,key:Z(e)?X(e,!0):e,value:t}}function X(e,t=!1,u=rt,n=0){return{type:4,loc:u,content:e,isStatic:t,constType:t?3:n}}function gt(e,t=rt){return{type:8,loc:t,children:e}}function Ae(e,t=[],u=rt){return{type:14,loc:u,callee:e,arguments:t}}function Ju(e,t=void 0,u=!1,n=!1,r=rt){return{type:18,params:e,returns:t,newline:u,isSlot:n,loc:r}}function Ss(e,t,u,n=!0){return{type:19,test:e,consequent:t,alternate:u,newline:n,loc:rt}}function f2(e,t,u=!1,n=!1){return{type:20,index:e,value:t,needPauseTracking:u,inVOnce:n,needArraySpread:!1,loc:rt}}function d2(e){return{type:21,body:e,loc:rt}}function Yu(e,t){return e||t?mo:bo}function Xu(e,t){return e||t?v0:D0}function wo(e,{helper:t,removeHelper:u,inSSR:n}){e.isBlock||(e.isBlock=!0,u(Yu(n,e.isComponent)),t(Su),t(Xu(n,e.isComponent)))}const Mc=new Uint8Array([123,123]),Pc=new Uint8Array([125,125]);function Lc(e){return e>=97& & e< =122||e>=65& & e< =90}function et(e){return e===32||e===10||e===9||e===12||e===13}function jt(e){return e===47||e===62||et(e)}function Kr(e){const t=new Uint8Array(e.length);for(let u=0;u< e.length ; u + + ) t [ u ] = e . charCodeAt ( u ) ; return t } const Oe = {Cdata:new Uint8Array ( [ 67 , 68 , 65 , 84 , 65 , 91 ] ) , CdataEnd:new Uint8Array ( [ 93 , 93 , 62 ] ) , CommentEnd:new Uint8Array ( [ 45 , 45 , 62 ] ) , ScriptEnd:new Uint8Array ( [ 60 , 47 , 115 , 99 , 114 , 105 , 112 , 116 ] ) , StyleEnd:new Uint8Array ( [ 60 , 47 , 115 , 116 , 121 , 108 , 101 ] ) , TitleEnd:new Uint8Array ( [ 60 , 47 , 116 , 105 , 116 , 108 , 101 ] ) , TextareaEnd:new Uint8Array ( [ 60 , 47 , 116 , 101 , 120 , 116 , 97 , 114 , 101 , 97 ] ) } ; class h2 { constructor ( t , u ) { this . stack = t,this.cbs=u,this.state=1,this.buffer="",this.sectionStart=0,this.index=0,this.entityStart=0,this.baseState=1,this.inRCDATA=!1,this.inXML=!1,this.inVPre=!1,this.newlines=[],this.mode=0,this.delimiterOpen=Mc,this.delimiterClose=Pc,this.delimiterIndex=-1,this.currentSequence=void 0 , this . sequenceIndex = 0}get inSFCRoot ( ) { return this . mode = ==2&&this.stack.length===0}reset(){this.state=1,this.mode=0,this.buffer="",this.sectionStart=0,this.index=0,this.baseState=1,this.inRCDATA=!1,this.currentSequence=void 0 , this . newlines . leng
`);else if(R2(i.content)){const s=e[r-1]&&e[r-1].type,o=e[r+1]&&e[r+1].type; !s||!o||u& & (s===3& & (o===3||o===1)||s===1& & (o===3||o===1& & M2(i.content)))?(n=!0,e[r]=null):i.content=" "}else u& & (i.content=$0(i.content))}return n?e.filter(Boolean):e}function R2(e){for(let t=0;t< e.length ; t + + ) if ( ! et ( e . charCodeAt ( t ) ) ) return ! 1 ; return ! 0 } function M2 ( e ) { for ( let t = 0;t<e.length;t++){const u = e.charCodeAt(t);if(u===10||u===13)return!0}return!1}function $ 0 ( e ) { let t = "" , u = !1;for(let n = 0;n<e.length;n++)et(e.charCodeAt(n))?u||(t+=" " , u = !0):(t+=e[n],u=!1);return t } function Ds ( e ) { ( pe [ 0 ] | | Hn ) . children . push ( e ) } function _e ( e , t ) { return { start:ge . getPos ( e ) , end:t = =null?t:ge.getPos(t),source:t==null?t:Fe(e,t)}}function P2 ( e ) { return _e ( e . start . offset , e . end . offset ) } function bu ( e , t ) { e . end = ge.getPos(t),e.source=Fe(e.start.offset,t)}function L2 ( e ) { const t = {type:6,name:e.rawName,nameLoc:_e(e.loc.start.offset,e.loc.start.offset+e.rawName.length),value:void 0 , loc:e . loc } ; if ( e . exp ) { const u = e.exp.loc;u.end.offset<e.loc.end.offset&&(u.start.offset--,u.start.column--,u.end.offset++,u.end.column++),t.value={type:2,content:e.exp.content,loc:u}}return t } function Cr ( e , t = !1,u,n=0,r=0){return X ( e , t , u , n ) } function Ft ( e , t , u ) { ie . onError ( me ( e , _e ( t , t ) ) ) } function B2 ( ) { ge . reset ( ) , Ne = null,ne=null,ze="",It=-1,hu=-1,pe.length=0}function V2 ( e , t ) { if ( B2 ( ) , Lt = e,ie=te({},L0),t){let r ; for ( r in t ) t [ r ] ! = null & & ( ie [ r ] = t [ r ] ) } ge . mode = ie.parseMode==="html"?1:ie.parseMode==="sfc"?2:0,ge.inXML=ie.ns===1||ie.ns===2;const u = t&&t.delimiters;u&&(ge.delimiterOpen=Kr(u[0]),ge.delimiterClose=Kr(u[1]));const n = Hn=a2([],e);return ge . parse ( Lt ) , n . loc = _e(0,e.length),n.children=V0(n.children),Hn=null,n}function $ 2 ( e , t ) { kr ( e , void 0 , t , H0 ( e , e . children [ 0 ] ) ) } function H0 ( e , t ) { const { children:u } = e ; return u . length = ==1&&t.type===1&&!Gr(t)}function kr ( e , t , u , n = !1,r=!1){const{children:i}=e,s=[];for(let a = 0;a<i.length;a++){const f = i[a];if(f.type===1&&f.tagType===0){const p = n?0:tt(f,u);if(p > 0){if(p>=2){f.codegenNode.patchFlag=-1,s.push(f);continue}}else{const d=f.codegenNode;if(d.type===13){const h=d.patchFlag;if((h===void 0||h===512||h===1)& & q0(f,u)>=2){const _=j0(f);_& & (d.props=u.hoist(_))}d.dynamicProps& & (d.dynamicProps=u.hoist(d.dynamicProps))}}}else if(f.type===12&&(n?0:tt(f,u))>=2){s.push(f); continue}if(f.type===1){const p=f.tagType===1;p& & u.scopes.vSlot++,kr(f,e,u,!1,r),p& & u.scopes.vSlot--}else if(f.type===11)kr(f,e,u,f.children.length===1,!0);else if(f.type===9)for(let p=0;p< f.branches.length ; p + + ) kr ( f . branches [ p ] , e , u , f . branches [ p ] . children . length = ==1,r)}let o = !1;if(s.length===i.length&&e.type===1){if(e.tagType===0&&e.codegenNode&&e.codegenNode.type===13&&$(e.codegenNode.children))e.codegenNode.children=c(Eu(e.codegenNode.children)),o=!0;else if ( e . tagType = ==1&&e.codegenNode&&e.codegenNode.type===13&&e.codegenNode.children&&!$(e.codegenNode.children)&&e.codegenNode.children.type===15){const a = l(e.codegenNode,"default");a&&(a.returns=c(Eu(a.returns)),o=!0)}else if ( e . tagType = ==3&&t&&t.type===1&&t.tagType===1&&t.codegenNode&&t.codegenNode.type===13&&t.codegenNode.children&&!$(t.codegenNode.children)&&t.codegenNode.children.type===15){const a = st(e,"slot",!0),f=a&&a.arg&&l(t.codegenNode,a.arg);f&&(f.returns=c(Eu(f.returns)),o=!0)}}if(!o)for(const a of s ) a . codegenNode = u.cache(a.codegenNode);function c ( a ) { const f = u.cache(a);return r & & u . hmr & & ( f . needArraySpread = !0),f}function l ( a , f ) { if ( a . children & & ! $ ( a . children ) & & a . children . type = ==15){const p = a.children.properties.find(d= > d.key===f||d.key.content===f);return p& & p.value}}s.length& & u.transformHoist& & u.transformHoist(i,u,e)}function tt(e,t){const{constantCache:u}=t;switch(e.type){case 1:if(e.tagType!==0)return 0;const n=u.get(e);if(n!==void 0)return n;const r=e.codegenNode;if(r.type!==13||r.isBlock& & e.tag!=="svg"& & e.tag!=="foreignObject"& & e.tag!=="math")return 0;if(r.patchFlag===void 0){let s=3;const o=q0(e,t);if(o===0)return u.set(e,0),0;o< s & & ( s = o);for(let c = 0;c<e.children.length;c++){const l = tt(e.children[c],t);if(l===0)return u . set ( e , 0 ) , 0 ; l < s & & ( s = l)}if(s > 1)for(let c=0;c< e.props.length ; c + + ) { const l = e.props[c];if(l.type===7&&l.name==="bind"&&l.exp){const a = tt(l.exp,t);if(a===0)r
`+" ".repeat(_),0)}return d}function W2(e,t={}){const u=K2(e,t);t.onContextCreated&&t.onContextCreated(u); const{mode:n,push:r,prefixIdentifiers:i,indent:s,deindent:o,newline:c,scopeId:l,ssr:a}=u,f=Array.from(e.helpers),p=f.length>0,d=!i&&n!=="module"; G2(e,u);const _=a?"ssrRender":"render",A=(a?["_ctx","_push","_parent","_attrs"]:["_ctx","_cache"]).join(", ");if(r(`function ${_}(${A}) {`),s(),d& & (r("with (_ctx) {"),s(),p& & (r(`const { ${f.map(K0).join(", ")} } = _Vue
`,-1),c())),e.components.length& & (Wi(e.components,"component",u),(e.directives.length||e.temps>0)& & c()),e.directives.length& & (Wi(e.directives,"directive",u),e.temps>0& & c()),e.filters& & e.filters.length& & (c(),Wi(e.filters,"filter",u),c()),e.temps>0){r("let ");for(let E=0;E< e.temps ; E + + ) r ( ` $ { E > 0?", ":""}_temp${E}`)}return(e.components.length||e.directives.length||e.temps)& & (r(`
`,0),c()),a||r("return "),e.codegenNode?Le(e.codegenNode,u):r("null"),d& & (o(),r("}")),o(),r("}"),{ast:e,code:u.code,preamble:"",map:u.map?u.map.toJSON():void 0}}function G2(e,t){const{ssr:u,prefixIdentifiers:n,push:r,newline:i,runtimeModuleName:s,runtimeGlobalName:o,ssrRuntimeModuleName:c}=t,l=o,a=Array.from(e.helpers);if(a.length>0& & (r(`const _Vue = ${l}
`,-1),e.hoists.length)){const f=[mo,bo,Yn,go,T0].filter(p=>a.includes(p)).map(K0).join(", ");r(`const { ${f} } = _Vue
`,-1)}Z2(e.hoists,t),i(),r("return ")}function Wi(e,t,{helper:u,push:n,newline:r,isTS:i}){const s=u(t==="filter"?Eo:t==="component"?_o:xo);for(let o=0;o< e.length ; o + + ) { let c = e[o];const l = c.endsWith("__self");l&&(c=c.slice(0,-6)),n(`const $ { $ n ( c , t ) } = $ { s } ( $ { JSON . stringify ( c ) } $ { l ? " , true " : " " } ) $ { i ? " ! " : " " } ` ) , o < e . length-1 & & r ( ) } } function Z2 ( e , t ) { if ( ! e . length ) return ; t . pure = !0;const{push:u,newline:n}=t;n();for(let r = 0;r<e.length;r++){const i = e[r];i&&(u(`const _hoisted_ $ { r + 1 } = ` ) , Le ( i , t ) , n ( ) ) } t . pure = !1}function No ( e , t ) { const u = e.length > 3||!1;t.push("["),u& & t.indent(),Qn(e,t,u),u& & t.deindent(),t.push("]")}function Qn(e,t,u=!1,n=!0){const{push:r,newline:i}=t;for(let s=0;s< e.length ; s + + ) { const o = e[s];Z(o)?r(o,-3):$(o)?No(o,t):Le(o,t),s<e.length-1&&(u?(n&&r(","),i()):n&&r(", " ) ) } } function Le ( e , t ) { if ( Z ( e ) ) { t . push ( e , -3 ) ; return } if ( Ze ( e ) ) { t . push ( t . helper ( e ) ) ; return } switch ( e . type ) { case 1:case 9:case 11:Le ( e . codegenNode , t ) ; break ; case 2:J2 ( e , t ) ; break ; case 4:W0 ( e , t ) ; break ; case 5:Y2 ( e , t ) ; break ; case 12:Le ( e . codegenNode , t ) ; break ; case 8:G0 ( e , t ) ; break ; case 3:Q2 ( e , t ) ; break ; case 13:em ( e , t ) ; break ; case 14:um ( e , t ) ; break ; case 15:nm ( e , t ) ; break ; case 17:rm ( e , t ) ; break ; case 18:im ( e , t ) ; break ; case 19:sm ( e , t ) ; break ; case 20:om ( e , t ) ; break ; case 21:Qn ( e . body , t , ! 0 , ! 1 ) ; break } } function J2 ( e , t ) { t . push ( JSON . stringify ( e . content ) , -3 , e ) } function W0 ( e , t ) { const { content:u , isStatic:n } = e ; t . push ( n ? JSON . stringify ( u ) :u , -3 , e ) } function Y2 ( e , t ) { const { push:u , helper:n , pure:r } = t ; r & & u ( Si ) , u ( ` $ { n ( Ci ) } ( ` ) , Le ( e . content , t ) , u ( " ) " ) } function G0 ( e , t ) { for ( let u = 0;u<e.children.length;u++){const n = e.children[u];Z(n)?t.push(n,-3):Le(n,t)}}function X2 ( e , t ) { const { push:u } = t ; if ( e . type = ==8)u("["),G0(e,t),u("]");else if ( e . isStatic ) { const n = Io(e.content)?e.content:JSON.stringify(e.content);u(n,-2,e)}else u ( ` [ $ { e . content } ] ` , -3 , e ) } function Q2 ( e , t ) { const { push:u , helper:n , pure:r } = t ; r & & u ( Si ) , u ( ` $ { n ( Yn ) } ( $ { JSON . stringify ( e . content ) } ) ` , -3 , e ) } function em ( e , t ) { const { push:u , helper:n , pure:r } = t , { tag:i , props:s , children:o , patchFlag:c , dynamicProps:l , directives:a , isBlock:f , disableTracking:p , isComponent:d } = e ; let h ; c & & ( h = String(c)),a&&u(n(Co)+"("),f&&u(`(${n(Su)}(${p?"true":""}), ` ) , r & & u ( Si ) ; const _ = f?Xu(t.inSSR,d):Yu(t.inSSR,d);u(n(_)+"(",-2,e),Qn(tm([i,s,o,h,l]),t),u(")"),f&&u(")"),a&&(u(", " ) , Le ( a , t ) , u ( " ) " ) ) } function tm ( e ) { let t = e.length;for(;t--&&e[t]==null;);return e . slice ( 0 , t + 1 ) . map ( u = > u||"null")}function um ( e , t ) { const { push:u , helper:n , pure:r } = t , i = Z(e.callee)?e.callee:n(e.callee);r&&u(Si),u(i+"(",-2,e),Qn(e.arguments,t),u(")")}function nm ( e , t ) { const { push:u , indent:n , deindent:r , newline:i } = t , { properties:s } = e ; if ( ! s . length ) { u ( " { } " , -2 , e ) ; return } const o = s.length > 1||!1;u(o?"{":"{ "),o&&n(); for(let c=0;c< s.length ; c + + ) { const { key:l , value:a } = s [ c ] ; X2 ( l , t ) , u ( " : " ) , Le ( a , t ) , c < s . length-1 & & ( u ( " , " ) , i ( ) ) } o & & r ( ) , u ( o ? " } " : " } " ) } function rm ( e , t ) { No ( e . elements , t ) } function im ( e , t ) { const { push:u , indent:n , deindent:r } = t , { params:i , returns:s , body:o , newline:c , isSlot:l } = e ; l & & u ( ` _ $ { Zu [ Do ] } ( ` ) , u ( " ( " , -2 , e ) , $ ( i ) ? Qn ( i , t ) :i & & Le ( i , t ) , u ( " ) = > "),(c||o)& & (u("{"),n()),s?(c& & u("return "),$(s)?No(s,t):Le(s,t)):o& & Le(o,t),(c||o)& & (r(),u("}")),l& & (e.isNonScopedSlot& & u(", undefined, true"),u(")"))}function sm(e,t){const{test:u,consequent:n,alternate:r,newline:i}=e,{push:s,indent:o,deindent:c,newline:l}=t;if(u.type===4){const f=!Io(u.content);f& & s("("),W0(u,t),f& & s(")")}else s("("),Le(u,t),s(")");i& & o(),t.indentLevel++,i||s(" "),s("? "),Le(n,t),t.indentLevel--,i& & l(),i||s(" "),s(": ");const a=r.type===19;a||t.indentLevel++,Le(r,t),a||t.indentLevel--,i& & c(!0)}function om(e,t){const{push:u,helper:n,indent:r,deindent:i,newline:s}=t,{needPauseTracking:o,needArraySpread:c}=e;c& & u("[...("),u(`_cache[${e.index}] || (`),o& & (r(),u(`${n(zr)}(-1`),e.inVOnce& & u(", true"),u("),"),s(),u("(")),u(`_cache[${e.index}] = `),Le(e.value,t),o& & (u(`).cacheIndex = ${e.index},`),s(),u(`${n(zr)}(1),`),s(),u(`_cache[${e.index}]`),i()),u(")"),c& & u(")]")}new RegExp("\\b"+"arguments,await,break,case,catch,class,const,continue,debugger,default,delete,do,else,export,extends,finally,for,function,if,import,let,new,return,super,switch,throw,try,var,void,while,with,yield".split(",").join("\\b|\\b")+"\\
* @vue/compiler-dom v3.5.13
* (c) 2018-present Yuxi (Evan) You and Vue contributors
* @license MIT
**/const uf=Symbol(""),nf=Symbol(""),rf=Symbol(""),sf=Symbol(""),Fs=Symbol(""),of=Symbol(""),cf=Symbol(""),lf=Symbol(""),af=Symbol(""),ff=Symbol("");l2({[uf]:"vModelRadio",[nf]:"vModelCheckbox",[rf]:"vModelText",[sf]:"vModelSelect",[Fs]:"vModelDynamic",[of]:"withModifiers",[cf]:"withKeys",[lf]:"vShow",[af]:"Transition",[ff]:"TransitionGroup"});let Nu;function Rm(e,t=!1){return Nu||(Nu=document.createElement("div")),t?(Nu.innerHTML=`< div foo = "${e.replace(/" / g , " & quot ; " ) } " > `,Nu.children[0].getAttribute("foo")):(Nu.innerHTML=e,Nu.textContent)}const Mm={parseMode:"html",isVoidTag:ld,isNativeTag:e=>sd(e)||od(e)||cd(e),isPreTag:e=>e==="pre",isIgnoreNewlineTag:e=>e==="pre"||e==="textarea",decodeEntities:Rm,isBuiltInComponent:e=>{if(e==="Transition"||e==="transition")return af;if(e==="TransitionGroup"||e==="transition-group")return ff},getNamespace(e,t,u){let n=t?t.ns:u;if(t& & n===2)if(t.tag==="annotation-xml"){if(e==="svg")return 1;t.props.some(r=>r.type===6&&r.name==="encoding"&&r.value!=null&&(r.value.content==="text/html"||r.value.content==="application/xhtml+xml"))&&(n=0)}else/^m(?:[ions]|text)$/.test(t.tag)&&e!=="mglyph"&&e!=="malignmark"&&(n=0); else t&&n===1&&(t.tag==="foreignObject"||t.tag==="desc"||t.tag==="title")&&(n=0); if(n===0){if(e==="svg")return 1;if(e==="math")return 2}return n}},Pm=e=>{e.type===1& & e.props.forEach((t,u)=>{t.type===6& & t.name==="style"& & t.value& & (e.props[u]={type:7,name:"bind",arg:X("style",!0,t.loc),exp:Lm(t.value.content,t.loc),modifiers:[],loc:t.loc})})},Lm=(e,t)=>{const u=xl(e);return X(JSON.stringify(u),!1,t,3)};function iu(e,t){return me(e,t)}const Bm=(e,t,u)=>{const{exp:n,loc:r}=e;return n||u.onError(iu(53,r)),t.children.length&&(u.onError(iu(54,r)),t.children.length=0),{props:[xe(X("innerHTML",!0,r),n||X("",!0))]}},Vm=(e,t,u)=>{const{exp:n,loc:r}=e; return n||u.onError(iu(55,r)),t.children.length& & (u.onError(iu(56,r)),t.children.length=0),{props:[xe(X("textContent",!0),n?tt(n,u)>0?n:Ae(u.helperString(Ci),[n],r):X("",!0))]}},$m=(e,t,u)=>{const n=tf(e,t,u);if(!n.props.length||t.tagType===1)return n;e.arg&&u.onError(iu(58,e.arg.loc)); const{tag:r}=t,i=u.isCustomElement(r);if(r==="input"||r==="textarea"||r==="select"||i){let s=rf,o=!1;if(r==="input"||i){const c=ki(t,"type");if(c){if(c.type===7)s=Fs;else if(c.value)switch(c.value.content){case"radio":s=uf;break;case"checkbox":s=nf;break;case"file":o=!0,u.onError(iu(59,e.loc));break}}else C2(t)& & (s=Fs)}else r==="select"&&(s=sf); o||(n.needRuntime=u.helper(s))}else u.onError(iu(57,e.loc));return n.props=n.props.filter(s=>!(s.key.type===4& & s.key.content==="modelValue")),n},Hm=Be("passive,once,capture"),Um=Be("stop,prevent,self,ctrl,shift,alt,meta,exact,middle"),qm=Be("left,right"),df=Be("onkeyup,onkeydown,onkeypress"),jm=(e,t,u,n)=>{const r=[],i=[],s=[];for(let o=0;o< t.length ; o + + ) { const c = t[o].content;c==="native"&&Vn("COMPILER_V_ON_NATIVE",u)||Hm(c)?s.push(c):qm(c)?Ge(e)?df(e.content.toLowerCase())?r.push(c):i.push(c):(r.push(c),i.push(c)):Um(c)?i.push(c):r.push(c)}return{keyModifiers:r,nonKeyModifiers:i,eventOptionModifiers:s}},Xc=(e,t)= > Ge(e)& & e.content.toLowerCase()==="onclick"?X(t,!0):e.type!==4?gt(["(",e,`) === "onClick" ? "${t}" : (`,e,")"]):e,zm=(e,t,u)=>ef(e,t,u,n=>{const{modifiers:r}=e;if(!r.length)return n;let{key:i,value:s}=n.props[0];const{keyModifiers:o,nonKeyModifiers:c,eventOptionModifiers:l}=jm(i,r,u,e.loc);if(c.includes("right")& & (i=Xc(i,"onContextmenu")),c.includes("middle")& & (i=Xc(i,"onMouseup")),c.length& & (s=Ae(u.helper(of),[s,JSON.stringify(c)])),o.length& & (!Ge(i)||df(i.content.toLowerCase()))& & (s=Ae(u.helper(cf),[s,JSON.stringify(o)])),l.length){const a=l.map(Tu).join("");i=Ge(i)?X(`${i.content}${a}`,!0):gt(["(",i,`) + "${a}"`])}return{props:[xe(i,s)]}}),Km=(e,t,u)=>{const{exp:n,loc:r}=e;return n||u.onError(iu(61,r)),{props:[],needRuntime:u.helper(lf)}},Wm=(e,t)=>{e.type===1&&e.tagType===0&&(e.tag==="script"||e.tag==="style")&&t.removeNode()},Gm=[Pm],Zm={cloak:Nm,html:Bm,text:Vm,model:$m,on:zm,show:Km}; function Jm(e,t={}){return Om(e,te({},Mm,t,{nodeTransforms:[Wm,...Gm,...t.nodeTransforms||[]],directiveTransforms:te({},Zm,t.dire
* vue v3.5.13
* (c) 2018-present Yuxi (Evan) You and Vue contributors
* @license MIT
**/const Qc=Object.create(null);function Ym(e,t){if(!Z(e))if(e.nodeType)e=e.innerHTML;else return we;const u=Gf(e,t),n=Qc[u];if(n)return n;if(e[0]==="#"){const o=document.querySelector(e);e=o?o.innerHTML:""}const r=te({hoistStatic:!0,onError:void 0,onWarn:we},t);!r.isCustomElement& & typeof customElements< "u"&&(r.isCustomElement=o=>!!customElements.get(o)); const{code:i}=Jm(e,r),s=new Function("Vue",i)(n2);return s._rc=!0,Qc[u]=s}Ya(Ym);const Xm={stream:!0,temperature:.2};let Qm=null;class el extends Error{constructor(t,u,n){super(t),this.name=u}}async function*eb(e,t={},u={}){var p;let n=u.controller;const r=((p=u.api_url)==null?void 0:p.replace(/\/+$/,""))||"";n||(n=new AbortController);const i={...Xm,...t,prompt:e},s=await fetch(`${r}${u.endpoint||"/completion"}`,{method:"POST",body:JSON.stringify(i),headers:{Connection:"keep-alive","Content-Type":"application/json",Accept:"text/event-stream",...t.api_key?{Authorization:`Bearer ${t.api_key}`}:{}},signal:n.signal});if(s.status!==200)try{const d=await s.json();if(d& & d.error& & d.error.message)throw new el(d.error.message,"ServerError")}catch(d){throw new el(d.message,"ServerError")}const c=s.body.getReader(),l=new TextDecoder;let a="",f="";try{let d=!0;for(;d;){const h=await c.read();if(h.done)break;const _=f+l.decode(h.value),v=_.endsWith(`
`);let A=_.split(`
`);v?f="":f=A.pop();const E=/^(\S+):\s(.*)$/gm;for(const m of A){const g=E.exec(m);if(g){if(h[g[1]]=g[2],h.data==="[DONE]"){d=!1;break}if(h.data& & (h.data=JSON.parse(h.data),a+=h.data.content,yield h,h.data.stop)){h.data.generation_settings&&(Qm=h.data.generation_settings),d=!1; break}if(h.error)try{if(h.error=JSON.parse(h.error),h.error.message.includes("slot unavailable"))throw new Error("slot unavailable");console.error(`llama.cpp error [${h.error.code} - ${h.error.type}]: ${h.error.message}`)}catch{console.error(`llama.cpp error ${h.error}`)}}}}}catch(d){throw d.name!=="AbortError"& & console.error("llama error: ",d),d}finally{n.abort()}return a}const tl={};function tb(e){let t=tl[e];if(t)return t;t=tl[e]=[];for(let u=0;u< 128 ; u + + ) { const n = String.fromCharCode(u);t.push(n)}for(let u = 0;u<e.length;u++){const n = e.charCodeAt(u);t[n]="%"+("0"+n.toString(16).toUpperCase()).slice(-2)}return t } function Qu ( e , t ) { typeof t ! = " string " & & ( t = Qu.defaultChars);const u = tb(t);return e . replace ( / ( % [ a-f0-9 ] { 2 } ) + / gi , function ( n ) { let r = "" ; for ( let i = 0,s=n.length;i<s;i+=3){const o = parseInt(n.slice(i+1,i+3),16);if(o<128){r+=u[o];continue}if((o&224)===192&&i+3<s){const c = parseInt(n.slice(i+4,i+6),16);if((c&192)===128){const l = o<<6&1984|c&63;l<128?r+="<22> <> ":r+=String.fromCharCode(l),i+=3;continue}}if((o&240)===224&&i+6<s){const c = parseInt(n.slice(i+4,i+6),16),l=parseInt(n.slice(i+7,i+9),16);if((c&192)===128&&(l&192)===128){const a = o<<12&61440|c<<6&4032|l&63;a<2048||a > =55296&&a<=57343?r+="<22> <> <EFBFBD> ":r+=String.fromCharCode(a),i+=6; continue}}if((o& 248)===240& & i+9< s ) { const c = parseInt(n.slice(i+4,i+6),16),l=parseInt(n.slice(i+7,i+9),16),a=parseInt(n.slice(i+10,i+12),16);if((c&192)===128&&(l&192)===128&&(a&192)===128){let f = o<<18&1835008|c<<12&258048|l<<6&4032|a&63;f<65536||f > 1114111?r+="<22> <> <EFBFBD> <EFBFBD> ":(f-=65536,r+=String.fromCharCode(55296+(f>>10),56320+(f&1023))),i+=9; continue}}r+="<22> "}return r})}Qu.defaultChars=";/?:@&=+$,#"; Qu.componentChars="";const ul={};function ub(e){let t=ul[e];if(t)return t;t=ul[e]=[];for(let u=0;u< 128 ; u + + ) { const n = String.fromCharCode(u);/^[0-9a-z]$/i.test(n)?t.push(n):t.push("%"+("0"+u.toString(16).toUpperCase()).slice(-2))}for(let u = 0;u<e.length;u++)t[e.charCodeAt(u)]=e[u];return t } function er ( e , t , u ) { typeof t ! = " string " & & ( u = t,t=er.defaultChars),typeof u > "u"&&(u=!0); const n=ub(t);let r="";for(let i=0,s=e.length;i< s ; i + + ) { const o = e.charCodeAt(i);if(u&&o===37&&i+2<s&&/^[0-9a-f]{2}$/i.test(e.slice(i+1,i+3))){r+=e.slice(i,i+3),i+=2;continue}if(o<128){r+=n[o];continue}if(o > =55296& & o< =57343){if(o>=55296& & o< =56319& & i+1< s ) { const c = e.charCodeAt(i+1);if(c > =56320&&c<=57343){r+=encodeURIComponent(e[i]+e[i+1]),i++; continue}}r+="%EF%BF%BD";continue}r+=encodeURIComponent(e[i])}return r}er.defaultChars=";/?:@&=+$,-_.!~*'()#"; er.componentChars="-_.!~*'()";function Ro(e){let t="";return t+=e.protocol||"",t+=e.slashes?"//":"",t+=e.auth?e.auth+"@":"",e.hostname& & e.hostname.indexOf(":")!==-1?t+="["+e.hostname+"]":t+=e.hostname||"",t+=e.port?":"+e.port:"",t+=e.pathname||"",t+=e.search||"",t+=e.hash||"",t}function Yr(){this.protocol=null,this.slashes=null,this.auth=null,this.port=null,this.hostname=null,this.hash=null,this.search=null,this.pathname=null}const nb=/^([a-z0-9.+-]+:)/i,rb=/:[0-9]*$/,ib=/^(\/\/?(?!\/)[^\?\s]*)(\?[^\s]*)?$/,sb=["< ",">",'"',"`"," ","\r",`
`," "],ob=["{","}","|","\\","^","`"].concat(sb),cb=["'"].concat(ob),nl=["%","/","?",";","#"].concat(cb),rl=["/","?","#"],lb=255,il=/^[+a-z0-9A-Z_-]{0,63}$/,ab=/^([+a-z0-9A-Z_-]{0,63})(.*)$/,sl={javascript:!0,"javascript:":!0},ol={http:!0,https:!0,ftp:!0,gopher:!0,file:!0,"http:":!0,"https:":!0,"ftp:":!0,"gopher:":!0,"file:":!0};function Mo(e,t){if(e& & e instanceof Yr)return e;const u=new Yr;return u.parse(e,t),u}Yr.prototype.parse=function(e,t){let u,n,r,i=e;if(i=i.trim(),!t& & e.split("#").length===1){const l=ib.exec(i);if(l)return this.pathname=l[1],l[2]& & (this.search=l[2]),this}let s=nb.exec(i);if(s& & (s=s[0],u=s.toLowerCase(),this.protocol=s,i=i.substr(s.length)),(t||s||i.match(/^\/\/[^@\/]+@[^@\/]+/))& & (r=i.substr(0,2)==="//",r& & !(s& & sl[s])& & (i=i.substr(2),this.slashes=!0)),!sl[s]& & (r||s& & !ol[s])){let l=-1;for(let h=0;h< rl.length ; h + + ) n = i.indexOf(rl[h]),n!==-1&&(l===-1||n<l)&&(l=n);let a , f ; l = ==-1?f=i.lastIndexOf("@"):f=i.lastIndexOf("@",l),f!==-1&&(a=i.slice(0,f),i=i.slice(f+1),this.auth=a),l=-1;for(let h = 0;h<nl.length;h++)n=i.indexOf(nl[h]),n!==-1&&(l===-1||n<l)&&(l=n);l===-1&&(l=i.length),i[l-1]===":"&&l--;const p = i.slice(0,l);i=i.slice(l),this.parseHost(p),this.hostname=this.hostname||"";const d = this.hostname[0]==="["&&this.hostname[this.hostname.length-1]==="]";if(!d){const h = this.hostname.split(/\./);for(let _ = 0,v=h.length;_<v;_++){const A = h[_];if(A&&!A.match(il)){let E = "" ; for ( let m = 0,g=A.length;m<g;m++)A.charCodeAt(m) > 127?E+="x":E+=A[m];if(!E.match(il)){const m=h.slice(0,_),g=h.slice(_+1),x=A.match(ab);x&&(m.push(x[1]),g.unshift(x[2])),g.length&&(i=g.join(".")+i),this.hostname=m.join("."); break}}}}this.hostname.length>lb& & (this.hostname=""),d& & (this.hostname=this.hostname.substr(1,this.hostname.length-2))}const o=i.indexOf("#");o!==-1&&(this.hash=i.substr(o),i=i.slice(0,o)); const c=i.indexOf("?");return c!==-1&&(this.search=i.substr(c),i=i.slice(0,c)),i&&(this.pathname=i),ol[u]&&this.hostname&&!this.pathname&&(this.pathname=""),this}; Yr.prototype.parseHost=function(e){let t=rb.exec(e);t&&(t=t[0],t!==":"&&(this.port=t.substr(1)),e=e.substr(0,e.length-t.length)),e&&(this.hostname=e)}; const fb=Object.freeze(Object.defineProperty({__proto__:null,decode:Qu,encode:er,format:Ro,parse:Mo},Symbol.toStringTag,{value:"Module"})),hf=/[\0-\uD7FF\uE000-\uFFFF]|[\uD800-\uDBFF][\uDC00-\uDFFF]|[\uD800-\uDBFF](?![\uDC00-\uDFFF])|(?:[^\uD800-\uDBFF]|^)[\uDC00-\uDFFF]/,pf=/[\0-\x1F\x7F-\x9F]/,db=/[\xAD\u0600-\u0605\u061C\u06DD\u070F\u0890\u0891\u08E2\u180E\u200B-\u200F\u202A-\u202E\u2060-\u2064\u2066-\u206F\uFEFF\uFFF9-\uFFFB]|\uD804[\uDCBD\uDCCD]|\uD80D[\uDC30-\uDC3F]|\uD82F[\uDCA0-\uDCA3]|\uD834[\uDD73-\uDD7A]|\uDB40[\uDC01\uDC20-\uDC7F]/,Po=/[!-#%-\*,-\/:;\?@\[-\]_\{\}\xA1\xA7\xAB\xB6\xB7\xBB\xBF\u037E\u0387\u055A-\u055F\u0589\u058A\u05BE\u05C0\u05C3\u05C6\u05F3\u05F4\u0609\u060A\u060C\u060D\u061B\u061D-\u061F\u066A-\u066D\u06D4\u0700-\u070D\u07F7-\u07F9\u0830-\u083E\u085E\u0964\u0965\u0970\u09FD\u0A76\u0AF0\u0C77\u0C84\u0DF4\u0E4F\u0E5A\u0E5B\u0F04-\u0F12\u0F14\u0F3A-\u0F3D\u0F85\u0FD0-\u0FD4\u0FD9\u0FDA\u104A-\u104F\u10FB\u1360-\u1368\u1400\u166E\u169B\u169C\u16EB-\u16ED\u1735\u1736\u17D4-\u17D6\u17D8-\u17DA\u1800-\u180A\u1944\u1945\u1A1E\u1A1F\u1AA0-\u1AA6\u1AA8-\u1AAD\u1B5A-\u1B60\u1B7D\u1B7E\u1BFC-\u1BFF\u1C3B-\u1C3F\u1C7E\u1C7F\u1CC0-\u1CC7\u1CD3\u2010-\u2027\u2030-\u2043\u2045-\u2051\u2053-\u205E\u207D\u207E\u208D\u208E\u2308-\u230B\u2329\u232A\u2768-\u2775\u27C5\u27C6\u27E6-\u27EF\u2983-\u2998\u29D8-\u29DB\u29FC\u29FD\u2CF9-\u2CFC\u2CFE\u2CFF\u2D70\u2E00-\u2E2E\u2E30-\u2E4F\u2E52-\u2E5D\u3001-\u3003\u3008-\u3011\u3014-\u301F\u3030\u303D\u30A0\u30FB\uA4FE\uA4FF\uA60D-\uA60F\uA673\uA67E\uA6F2-\uA6F7\uA874-\uA877\uA8CE\uA8CF\uA8F8-\uA8FA\uA8FC\uA92E\uA92F\uA95F\uA9C1-\uA9CD\uA9DE\uA9DF\uAA5C-\uAA5F\uAADE\uAADF\uAAF0\uAAF1\uABEB\uFD3E\uFD3F\uFE10-\uFE19\uFE30-\uFE52\uFE54-\uFE61\uFE63\uFE68\uFE6A\uFE6B\uFF01-\uFF03\uFF05-\uFF0A\uFF0C-\uFF0F\uFF1A\uFF1B\uFF1F\uFF20\uFF3B-\uFF3D\uFF3F\uFF5B\uFF5D\uFF5F-\uFF65]|\uD800[\uDD00-\uDD02\uDF9F\uDFD0]|\uD801\uDD6F|\uD802[\uDC57\uDD1F\uDD3F\uDE50-\uDE58\uDE7F\uDEF0-\uDEF6\uDF39-\uDF3F\uD
`};Dt.fence=function(e,t,u,n,r){const i=e[t],s=i.info?en(i.info).trim():"";let o="",c="";if(s){const a=s.split(/(\s+)/g);o=a[0],c=a.slice(2).join("")}let l;if(u.highlight?l=u.highlight(i.content,o,c)||lu(i.content):l=lu(i.content),l.indexOf("< pre " ) = = = 0 ) return l + `
`;if(s){const a=i.attrIndex("class"),f=i.attrs?i.attrs.slice():[];a< 0 ? f . push ( [ " class " , u . langPrefix + o ] ) : ( f [ a ] = f [ a ] . slice ( ) , f [ a ] [ 1 ] + = " " + u . langPrefix + o ) ; const p = {attrs:f};return`<pre > < code $ { r . renderAttrs ( p ) } > ${l}< / code > < / pre >
`}return`< pre > < code $ { r . renderAttrs ( i ) } > ${l}< / code > < / pre >
`};Dt.image=function(e,t,u,n,r){const i=e[t];return i.attrs[i.attrIndex("alt")][1]=r.renderInlineAsText(i.children,u,n),r.renderToken(e,t,u)};Dt.hardbreak=function(e,t,u){return u.xhtmlOut?`< br / >
`:`< br >
`};Dt.softbreak=function(e,t,u){return u.breaks?u.xhtmlOut?`< br / >
`:`< br >
`:`
`};Dt.text=function(e,t){return lu(e[t].content)};Dt.html_block=function(e,t){return e[t].content};Dt.html_inline=function(e,t){return e[t].content};function rn(){this.rules=vi({},Dt)}rn.prototype.renderAttrs=function(t){let u,n,r;if(!t.attrs)return"";for(r="",u=0,n=t.attrs.length;u< n ; u + + ) r + = " " + lu ( t . attrs [ u ] [ 0 ] ) + ' = " ' + lu ( t . attrs [ u ] [ 1 ] ) + ' " ' ; return r } ; rn . prototype . renderToken = function(t,u,n){const r = t[u];let i = "" ; if ( r . hidden ) return " " ; r . block & & r . nesting ! = = -1 & & u & & t [ u-1 ] . hidden & & ( i + = `
`),i+=(r.nesting===-1?"< /":"< ")+r.tag,i+=this.renderAttrs(r),r.nesting===0& & n.xhtmlOut& & (i+=" /");let s=!1;if(r.block& & (s=!0,r.nesting===1& & u+1< t.length ) ) { const o = t[u+1];(o.type==="inline"||o.hidden||o.nesting===-1&&o.tag===r.tag)&&(s=!1)}return i + = s ? ` >
`:">",i};rn.prototype.renderInline=function(e,t,u){let n="";const r=this.rules;for(let i=0,s=e.length;i< s ; i + + ) { const o = e[i].type;typeof r [ o ] < " u " ? n + = r [ o ] ( e , i , t , u , this ) :n + = this . renderToken ( e , i , t ) } return n } ; rn . prototype . renderInlineAsText = function(e,t,u){let n = "" ; for ( let r = 0,i=e.length;r<i;r++)switch(e[r].type){case"text":n+=e[r].content;break;case"image":n+=this.renderInlineAsText(e[r].children,t,u);break;case"html_inline":case"html_block":n+=e[r].content;break;case"softbreak":case"hardbreak":n+=`
`;break}return n};rn.prototype.render=function(e,t,u){let n="";const r=this.rules;for(let i=0,s=e.length;i< s ; i + + ) { const o = e[i].type;o==="inline"?n+=this.renderInline(e[i].children,t,u):typeof r [ o ] < " u " ? n + = r [ o ] ( e , i , t , u , this ) :n + = this . renderToken ( e , i , t , u ) } return n } ; function Je ( ) { this . __rules__ = [],this.__cache__=null}Je.prototype.__find__=function(e){for(let t = 0;t<this.__rules__.length;t++)if(this.__rules__[t].name===e)return t ; return-1 } ; Je . prototype . __compile__ = function(){const e = this,t=[""];e.__rules__.forEach(function(u){u.enabled&&u.alt.forEach(function(n){t.indexOf(n)<0&&t.push(n)})}),e.__cache__={},t.forEach(function(u){e.__cache__[u]=[],e.__rules__.forEach(function(n){n.enabled&&(u&&n.alt.indexOf(u)<0||e.__cache__[u].push(n.fn))})})};Je.prototype.at=function(e,t,u){const n = this.__find__(e),r=u||{};if(n===-1)throw new Error ( " Parser rule not found: " + e ) ; this . __rules__ [ n ] . fn = t,this.__rules__[n].alt=r.alt||[],this.__cache__=null};Je.prototype.before=function(e,t,u,n){const r = this.__find__(e),i=n||{};if(r===-1)throw new Error ( " Parser rule not found: " + e ) ; this . __rules__ . splice ( r , 0 , { name:t , enabled: ! 0 , fn:u , alt:i . alt | | [ ] } ) , this . __cache__ = null};Je.prototype.after=function(e,t,u,n){const r = this.__find__(e),i=n||{};if(r===-1)throw new Error ( " Parser rule not found: " + e ) ; this . __rules__ . splice ( r + 1 , 0 , { name:t , enabled: ! 0 , fn:u , alt:i . alt | | [ ] } ) , this . __cache__ = null};Je.prototype.push=function(e,t,u){const n = u||{};this.__rules__.push({name:e,enabled:!0,fn:t,alt:n.alt||[]}),this.__cache__=null};Je.prototype.enable=function(e,t){Array.isArray(e)||(e=[e]);const u = [];return e . forEach ( function ( n ) { const r = this.__find__(n);if(r<0){if(t)return;throw new Error ( " Rules manager: invalid rule name " + n ) } this . __rules__ [ r ] . enabled = !0,u.push(n)},this),this.__cache__=null,u};Je.prototype.enableOnly=function(e,t){Array.isArray(e)||(e=[e]),this.__rules__.forEach(function(u){u.enabled=!1}),this.enable(e,t)};Je.prototype.disable=function(e,t){Array.isArray(e)||(e=[e]);const u = [];return e . forEach ( function ( n ) { const r = this.__find__(n);if(r<0){if(t)return;throw new Error ( " Rules manager: invalid rule name " + n ) } this . __rules__ [ r ] . enabled = !1,u.push(n)},this),this.__cache__=null,u};Je.prototype.getRules=function(e){return this . __cache__ = ==null&&this.__compile__(),this.__cache__[e]||[]};function _t ( e , t , u ) { this . type = e,this.tag=t,this.attrs=null,this.map=null,this.nesting=u,this.level=0,this.children=null,this.content="",this.markup="",this.info="",this.meta=null,this.block=!1,this.hidden=!1}_t.prototype.attrIndex=function(t){if(!this.attrs)return-1;const u = this.attrs;for(let n = 0,r=u.length;n<r;n++)if(u[n][0]===t)return n ; return-1 } ; _t . prototype . attrPush = function(t){this.attrs?this.attrs.push(t):this.attrs=[t]};_t.prototype.attrSet=function(t,u){const n = this.attrIndex(t),r=[t,u];n<0?this.attrPush(r):this.attrs[n]=r};_t.prototype.attrGet=function(t){const u = this.attrIndex(t);let n = null;return u > =0&&(n=this.attrs[u][1]),n}; _t.prototype.attrJoin=function(t,u){const n=this.attrIndex(t);n< 0 ? this . attrPush ( [ t , u ] ) :this . attrs [ n ] [ 1 ] = this . attrs [ n ] [ 1 ] + " " + u } ; function Ef ( e , t , u ) { this . src = e,this.env=u,this.tokens=[],this.inlineMode=!1,this.md=t}Ef.prototype.Token=_t;const Kb = /\r\n?|\n/g,Wb=/\0/g;function Gb ( e ) { let t ; t = e.src.replace(Kb,`
`),t=t.replace(Wb,"<22> "),e.src=t}function Zb(e){let t;e.inlineMode?(t=new e.Token("inline","",0),t.content=e.src,t.map=[0,1],t.children=[],e.tokens.push(t)):e.md.block.parse(e.src,e.md,e.env,e.tokens)}function Jb(e){const t=e.tokens;for(let u=0,n=t.length;u< n ; u + + ) { const r = t[u];r.type==="inline"&&e.md.inline.parse(r.content,e.md,e.env,r.children)}}function Yb ( e ) { return / ^ < a [ > \s]/i.test(e)}function Xb(e){return/^< \/a\s*>/i.test(e)}function Qb(e){const t=e.tokens;if(e.md.options.linkify)for(let u=0,n=t.length;u< n ; u + + ) { if ( t [ u ] . type ! = = " inline " | | ! e . md . linkify . pretest ( t [ u ] . content ) ) continue ; let r = t[u].children,i=0;for(let s = r.length-1;s > =0;s--){const o=r[s];if(o.type==="link_close"){for(s--;r[s].level!==o.level&&r[s].type!=="link_open"; )s--;continue}if(o.type==="html_inline"& & (Yb(o.content)& & i>0& & i--,Xb(o.content)& & i++),!(i>0)& & o.type==="text"& & e.md.linkify.test(o.content)){const c=o.content;let l=e.md.linkify.match(c);const a=[];let f=o.level,p=0;l.length>0&&l[0].index===0&&s>0&&r[s-1].type==="text_special"&&(l=l.slice(1)); for(let d=0;d< l.length ; d + + ) { const h = l[d].url,_=e.md.normalizeLink(h);if(!e.md.validateLink(_))continue;let v = l[d].text;l[d].schema?l[d].schema==="mailto:"&&!/^mailto:/i.test(v)?v=e.md.normalizeLinkText("mailto:"+v).replace(/^mailto:/,""):v=e.md.normalizeLinkText(v):v=e.md.normalizeLinkText("http://"+v).replace(/^http:\/\//,"");const A = l[d].index;if(A > p){const x=new e.Token("text","",0);x.content=c.slice(p,A),x.level=f,a.push(x)}const E=new e.Token("link_open","a",1);E.attrs=[["href",_]],E.level=f++,E.markup="linkify",E.info="auto",a.push(E);const m=new e.Token("text","",0);m.content=v,m.level=f,a.push(m);const g=new e.Token("link_close","a",-1);g.level=--f,g.markup="linkify",g.info="auto",a.push(g),p=l[d].lastIndex}if(p< c.length ) { const d = new e . Token ( " text " , " " , 0 ) ; d . content = c.slice(p),d.level=f,a.push(d)}t[u].children=r=yf(r,s,a)}}}}const Cf = /\+-|\.\.|\?\?\?\?|!!!!|,,|--/,eg=/\((c|tm|r)\)/i,tg=/\((c|tm|r)\)/ig,ug={c:"©",r:"®",tm:"™"};function ng ( e , t ) { return ug [ t . toLowerCase ( ) ] } function rg ( e ) { let t = 0;for(let u = e.length-1;u > =0;u--){const n=e[u];n.type==="text"& & !t& & (n.content=n.content.replace(tg,ng)),n.type==="link_open"& & n.info==="auto"& & t--,n.type==="link_close"& & n.info==="auto"& & t++}}function ig(e){let t=0;for(let u=e.length-1;u>=0;u--){const n=e[u];n.type==="text"& & !t& & Cf.test(n.content)& & (n.content=n.content.replace(/\+-/g,"±").replace(/\.{2,}/g,"…").replace(/([?!])…/g,"$1..").replace(/([?!]){4,}/g,"$1$1$1").replace(/,{2,}/g,",").replace(/(^|[^-])---(?=[^-]|$)/mg,"$1—").replace(/(^|\s)--(?=\s|$)/mg,"$1– ").replace(/(^|[^-\s])--(?=[^-\s]|$)/mg,"$1– ")),n.type==="link_open"& & n.info==="auto"& & t--,n.type==="link_close"& & n.info==="auto"& & t++}}function sg(e){let t;if(e.md.options.typographer)for(t=e.tokens.length-1;t>=0;t--)e.tokens[t].type==="inline"& & (eg.test(e.tokens[t].content)& & rg(e.tokens[t].children),Cf.test(e.tokens[t].content)& & ig(e.tokens[t].children))}const og=/['"]/,cl=/['"]/g,ll="’ ";function mr(e,t,u){return e.slice(0,t)+u+e.slice(t+1)}function cg(e,t){let u;const n=[];for(let r=0;r< e.length ; r + + ) { const i = e[r],s=e[r].level;for(u=n.length-1;u > =0&&!(n[u].level<=s); u--);if(n.length=u+1,i.type!=="text")continue;let o=i.content,c=0,l=o.length;e:for(;c< l ; ) { cl . lastIndex = c;const a = cl.exec(o);if(!a)break;let f = !0,p=!0;c=a.index+1;const d = a[0]==="'";let h = 32;if(a.index-1 > =0)h=o.charCodeAt(a.index-1);else for(u=r-1;u>=0&&!(e[u].type==="softbreak"||e[u].type==="hardbreak"); u--)if(e[u].content){h=e[u].content.charCodeAt(e[u].content.length-1);break}let _=32;if(c< l ) _ = o.charCodeAt(c);else for ( u = r+1;u<e.length&&!(e[u].type==="softbreak"||e[u].type==="hardbreak");u++)if(e[u].content){_=e[u].content.charCodeAt(0);break}const v = jn(h)||qn(String.fromCharCode(h)),A=jn(_)||qn(String.fromCharCode(_)),E=Un(h),m=Un(_);if(m?f=!1:A&&(E||v||(f=!1)),E?p=!1:v&&(m||A||(p=!1)),_===34&&a[0]==='"'&&h > =48&&h<=57&&(p=f=!1),f&&p&&(f=v,p=A),!f&&!p){d&&(i.content=mr(i.content,a.index,ll)); continue}if(p)for(u=n.length-1;u>=0;u--){let g=n[u];if(n[u].level< s ) break ; if ( g . single = ==d&&n[u].level===s){g=n[u];let x , k ; d ? ( x = t.md.optio
`,i.map=[t,e.line],!0}function pg(e,t,u,n){let r=e.bMarks[t]+e.tShift[t],i=e.eMarks[t];if(e.sCount[t]-e.blkIndent>=4||r+3>i)return!1;const s=e.src.charCodeAt(r);if(s!==126&&s!==96)return!1; let o=r;r=e.skipChars(r,s);let c=r-o;if(c< 3 ) return ! 1 ; const l = e.src.slice(o,r),a=e.src.slice(r,i);if(s===96&&a.indexOf(String.fromCharCode(s)) > =0)return!1;if(n)return!0;let f=t,p=!1;for(;f++,!(f>=u||(r=o=e.bMarks[f]+e.tShift[f],i=e.eMarks[f],r< i & & e . sCount [ f ] < e . blkIndent ) ) ; ) if ( e . src . charCodeAt ( r ) = = = s & & ! ( e . sCount [ f ] -e . blkIndent > =4)&&(r=e.skipChars(r,s),!(r-o<c)&&(r=e.skipSpaces(r),!(r<i)))){p=!0; break}c=e.sCount[t],e.line=f+(p?1:0);const d=e.push("fence","code",0);return d.info=a,d.content=e.getLines(t+1,f,c,!0),d.markup=l,d.map=[t,e.line],!0}function mg(e,t,u,n){let r=e.bMarks[t]+e.tShift[t],i=e.eMarks[t];const s=e.lineMax;if(e.sCount[t]-e.blkIndent>=4||e.src.charCodeAt(r)!==62)return!1;if(n)return!0;const o=[],c=[],l=[],a=[],f=e.md.block.ruler.getRules("blockquote"),p=e.parentType;e.parentType="blockquote";let d=!1,h;for(h=t;h< u ; h + + ) { const m = e.sCount[h]<e.blkIndent;if(r=e.bMarks[h]+e.tShift[h],i=e.eMarks[h],r > =i)break;if(e.src.charCodeAt(r++)===62& & !m){let x=e.sCount[h]+1,k,I;e.src.charCodeAt(r)===32?(r++,x++,I=!1,k=!0):e.src.charCodeAt(r)===9?(k=!0,(e.bsCount[h]+x)%4===3?(r++,x++,I=!1):I=!0):k=!1;let w=x;for(o.push(e.bMarks[h]),e.bMarks[h]=r;r< i ; ) { const C = e.src.charCodeAt(r);if(ae(C))C===9?w+=4-(w+e.bsCount[h]+(I?1:0))%4:w++;else break ; r + + } d = r > =i,c.push(e.bsCount[h]),e.bsCount[h]=e.sCount[h]+1+(k?1:0),l.push(e.sCount[h]),e.sCount[h]=w-x,a.push(e.tShift[h]),e.tShift[h]=r-e.bMarks[h];continue}if(d)break;let g=!1;for(let x=0,k=f.length;x< k ; x + + ) if ( f [ x ] ( e , h , u , ! 0 ) ) { g = !0;break}if(g){e.lineMax=h,e.blkIndent!==0&&(o.push(e.bMarks[h]),c.push(e.bsCount[h]),a.push(e.tShift[h]),l.push(e.sCount[h]),e.sCount[h]-=e.blkIndent);break}o.push(e.bMarks[h]),c.push(e.bsCount[h]),a.push(e.tShift[h]),l.push(e.sCount[h]),e.sCount[h]=-1}const _ = e.blkIndent;e.blkIndent=0;const v = e.push("blockquote_open","blockquote",1);v.markup=" > ";const A=[t,0];v.map=A,e.md.block.tokenize(e,t,h);const E=e.push("blockquote_close","blockquote",-1);E.markup=">",e.lineMax=s,e.parentType=p,A[1]=e.line;for(let m=0;m< a.length ; m + + ) e . bMarks [ m + t ] = o [ m ] , e . tShift [ m + t ] = a [ m ] , e . sCount [ m + t ] = l [ m ] , e . bsCount [ m + t ] = c [ m ] ; return e . blkIndent = _,!0}function bg ( e , t , u , n ) { const r = e.eMarks[t];if(e.sCount[t]-e.blkIndent > =4)return!1;let i=e.bMarks[t]+e.tShift[t];const s=e.src.charCodeAt(i++);if(s!==42&&s!==45&&s!==95)return!1; let o=1;for(;i< r ; ) { const l = e.src.charCodeAt(i++);if(l!==s&&!ae(l))return!1;l===s&&o++}if(o<3)return!1;if(n)return!0;e.line=t+1;const c = e.push("hr","hr",0);return c . map = [t,e.line],c.markup=Array(o+1).join(String.fromCharCode(s)),!0}function fl ( e , t ) { const u = e.eMarks[t];let n = e.bMarks[t]+e.tShift[t];const r = e.src.charCodeAt(n++);if(r!==42&&r!==45&&r!==43)return-1;if(n<u){const i = e.src.charCodeAt(n);if(!ae(i))return-1}return n } function dl ( e , t ) { const u = e.bMarks[t]+e.tShift[t],n=e.eMarks[t];let r = u;if(r+1 > =n)return-1;let i=e.src.charCodeAt(r++);if(i< 48 | | i > 57)return-1;for(;;){if(r>=n)return-1;if(i=e.src.charCodeAt(r++),i>=48&&i<=57){if(r-u>=10)return-1; continue}if(i===41||i===46)break;return-1}return r< n & & ( i = e.src.charCodeAt(r),!ae(i))?-1:r}function gg ( e , t ) { const u = e.level+2;for(let n = t+2,r=e.tokens.length-2;n<r;n++)e.tokens[n].level===u&&e.tokens[n].type==="paragraph_open"&&(e.tokens[n+2].hidden=!0,e.tokens[n].hidden=!0,n+=2)}function _g ( e , t , u , n ) { let r , i , s , o , c = t,l=!0;if(e.sCount[c]-e.blkIndent > =4||e.listIndent>=0&&e.sCount[c]-e.listIndent>=4&&e.sCount[c]<e.blkIndent)return!1; let a=!1;n&&e.parentType==="paragraph"&&e.sCount[c]>=e.blkIndent&&(a=!0); let f,p,d;if((d=dl(e,c))>=0){if(f=!0,s=e.bMarks[c]+e.tShift[c],p=Number(e.src.slice(s,d-1)),a& & p!==1)return!1}else if((d=fl(e,c))>=0)f=!1;else return!1;if(a&&e.skipSpaces(d)>=e.eMarks[c])return!1; if(n)return!0;const h=e.src.charCodeAt(d-1),_=e.tokens.length;f?(o=e.push("ordered_list_open","ol",1),p!==1&&(o.attrs=[["start",p]])):o=e.push("bullet_list_open","ul",1); const v=[c,0];o.map=v,o.markup=String.fromCharCode(h);let A=!1;const E=e.md.block.ruler.ge
< div class = "text-right sticky top-4 mb-2 mr-2 h-0" >
< button class = "badge btn-mini" onclick = "copyStr(${U3(JSON.stringify(o))})" > 📋 Copy< / button >
< / div >
${c}
< / div > `},window.copyStr=Bf;const n=lo(()=>t.value.render(e.source));return()=>ao("div",{innerHTML:n.value})},{props:["source"]}),G3=Kn({template:document.getElementById("settings-modal-short-input").innerHTML,props:{label:{type:String,required:!1},configKey:String,configDefault:Object,configInfo:Object,modelValue:[Object,String,Number]}}),he={getAllConversations(){const e=[];for(const t in localStorage)t.startsWith("conv-")&&e.push(JSON.parse(localStorage.getItem(t))); return e.sort((t,u)=>u.lastModified-t.lastModified),e},getOneConversation(e){return JSON.parse(localStorage.getItem(e)||"null")},appendMsg(e,t){if(t.content===null)return;const u=he.getOneConversation(e)||{id:e,lastModified:Date.now(),messages:[]};u.messages.push(t),u.lastModified=Date.now(),localStorage.setItem(e,JSON.stringify(u))},getNewConvId(){return`conv-${Date.now()}`},remove(e){localStorage.removeItem(e)},filterAndKeepMsgs(e,t){const u=he.getOneConversation(e);u& & (u.messages=u.messages.filter(t),u.lastModified=Date.now(),localStorage.setItem(e,JSON.stringify(u)))},popMsg(e){const t=he.getOneConversation(e);if(!t)return;const u=t.messages.pop();return t.lastModified=Date.now(),t.messages.length===0?he.remove(e):localStorage.setItem(e,JSON.stringify(t)),u},getConfig(){const e=JSON.parse(localStorage.getItem("config")||"{}");return{...ei,...e}},setConfig(e){localStorage.setItem("config",JSON.stringify(e))},getTheme(){return localStorage.getItem("theme")||"auto"},setTheme(e){e==="auto"?localStorage.removeItem("theme"):localStorage.setItem("theme",e)}},fn=e=>{const t=document.getElementById("messages-list"),u=t.scrollHeight-t.scrollTop-t.clientHeight;(!e||u< 100 ) & & setTimeout ( ( ) = > t.scrollTo({top:t.scrollHeight}),1)},Vf=Ur({components:{VueMarkdown:W3,SettingsModalShortInput:G3},data(){return{conversations:he.getAllConversations(),messages:[],viewingConvId:he.getNewConvId(),inputMsg:"",isGenerating:!1,pendingMsg:null,stopGeneration:()=>{},selectedTheme:he.getTheme(),config:he.getConfig(),showConfigDialog:!1,editingMsg:null,themes:K3,configDefault:{...ei},configInfo:{...j3}}},computed:{},mounted(){document.getElementById("app").classList.remove("opacity-0");const e=document.getElementById("pending-msg");new ResizeObserver(()=>{this.isGenerating& & fn(!0)}).observe(e)},methods:{hideSidebar(){document.getElementById("toggle-drawer").checked=!1},setSelectedTheme(e){this.selectedTheme=e,he.setTheme(e)},newConversation(){this.isGenerating||(this.viewingConvId=he.getNewConvId(),this.editingMsg=null,this.fetchMessages(),fn(),this.hideSidebar())},setViewingConv(e){this.isGenerating||(this.viewingConvId=e,this.editingMsg=null,this.fetchMessages(),fn(),this.hideSidebar())},deleteConv(e){this.isGenerating||window.confirm("Are you sure to delete this conversation?")& & (he.remove(e),this.viewingConvId===e& & (this.viewingConvId=he.getNewConvId(),this.editingMsg=null),this.fetchConversation(),this.fetchMessages())},downloadConv(e){const t=he.getOneConversation(e);if(!t){alert("Conversation not found.");return}const u=JSON.stringify(t,null,2),n=new Blob([u],{type:"application/json"}),r=URL.createObjectURL(n),i=document.createElement("a");i.href=r,i.download=`conversation_${e}.json`,document.body.appendChild(i),i.click(),document.body.removeChild(i),URL.revokeObjectURL(r)},async sendMessage(){if(!this.inputMsg)return;const e=this.viewingConvId;he.appendMsg(e,{id:Date.now(),role:"user",content:this.inputMsg}),this.fetchConversation(),this.fetchMessages(),this.inputMsg="",this.editingMsg=null,this.generateMessage(e),fn()},async generateMessage(e){if(!this.isGenerating){this.pendingMsg={id:Date.now()+1,role:"assistant",content:null},this.isGenerating=!0,this.editingMsg=null;try{const t=new AbortController;this.stopGeneration=()=>t.abort();const u={messages:[{role:"system",content:this.config.systemMessage},...this.messages],stream:!0,cache_prompt:!0,samplers:this.config.samplers,temperature:this.config.temperature,dynatemp_range:this.config.dynatemp_range,dynatemp_exponent:this.config.dynatemp_exponent,top_k:this.config.top_k,top_p:this.config.top_p,min_p:this.config.min_p,ty
Failed to start app. Please try clearing localStorage and try again.< br / >
< br / >
< button class = "btn" onClick = "localStorage.clear(); window.location.reload();" > Clear localStorage< / button >
< / div > `}< / script >
< style rel = "stylesheet" crossorigin > * , : b e f o r e , : a f t e r { - - t w - b o r d e r - s p a c i n g - x : 0 ; - - t w - b o r d e r - s p a c i n g - y : 0 ; - - t w - t r a n s l a t e - x : 0 ; - - t w - t r a n s l a t e - y : 0 ; - - t w - r o t a t e : 0 ; - - t w - s k e w - x : 0 ; - - t w - s k e w - y : 0 ; - - t w - s c a l e - x : 1 ; - - t w - s c a l e - y : 1 ; - - t w - p a n - x : ; - - t w - p a n - y : ; - - t w - p i n c h - z o o m : ; - - t w - s c r o l l - s n a p - s t r i c t n e s s : p r o x i m i t y ; - - t w - g r a d i e n t - f r o m - p o s i t i o n : ; - - t w - g r a d i e n t - v i a - p o s i t i o n : ; - - t w - g r a d i e n t - t o - p o s i t i o n : ; - - t w - o r d i n a l : ; - - t w - s l a s h e d - z e r o : ; - - t w - n u m e r i c - f i g u r e : ; - - t w - n u m e r i c - s p a c i n g : ; - - t w - n u m e r i c - f r a c t i o n : ; - - t w - r i n g - i n s e t : ; - - t w - r i n g - o f f s e t - w i d t h : 0 p x ; - - t w - r i n g - o f f s e t - c o l o r : # f f f ; - - t w - r i n g - c o l o r : r g b ( 5 9 1 3 0 2 4 6 / . 5 ) ; - - t w - r i n g - o f f s e t - s h a d o w : 0 0 # 0 0 0 0 ; - - t w - r i n g - s h a d o w : 0 0 # 0 0 0 0 ; - - t w - s h a d o w : 0 0 # 0 0 0 0 ; - - t w - s h a d o w - c o l o r e d : 0 0 # 0 0 0 0 ; - - t w - b l u r : ; - - t w - b r i g h t n e s s : ; - - t w - c o n t r a s t : ; - - t w - g r a y s c a l e : ; - - t w - h u e - r o t a t e : ; - - t w - i n v e r t : ; - - t w - s a t u r a t e : ; - - t w - s e p i a : ; - - t w - d r o p - s h a d o w : ; - - t w - b a c k d r o p - b l u r : ; - - t w - b a c k d r o p - b r i g h t n e s s : ; - - t w - b a c k d r o p - c o n t r a s t : ; - - t w - b a c k d r o p - g r a y s c a l e : ; - - t w - b a c k d r o p - h u e - r o t a t e : ; - - t w - b a c k d r o p - i n v e r t : ; - - t w - b a c k d r o p - o p a c i t y : ; - - t w - b a c k d r o p - s a t u r a t e : ; - - t w - b a c k d r o p - s e p i a : ; - - t w - c o n t a i n - s i z e : ; - - t w - c o n t a i n - l a y o u t : ; - - t w - c o n t a i n - p a i n t : ; - - t w - c o n t a i n - s t y l e : } : : b a c k d r o p { - - t w - b o r d e r - s p a c i n g - x : 0 ; - - t w - b o r d e r - s p a c i n g - y : 0 ; - - t w - t r a n s l a t e - x : 0 ; - - t w - t r a n s l a t e - y : 0 ; - - t w - r o t a t e : 0 ; - - t w - s k e w - x : 0 ; - - t w - s k e w - y : 0 ; - - t w - s c a l e - x : 1 ; - - t w - s c a l e - y : 1 ; - - t w - p a n - x : ; - - t w - p a n - y : ; - - t w - p i n c h - z o o m : ; - - t w - s c r o l l - s n a p - s t r i c t n e s s : p r o x i m i t y ; - - t w - g r a d i e n t - f r o m - p o s i t i o n : ; - - t w - g r a d i e n t - v i a - p o s i t i o n : ; - - t w - g r a d i e n t - t o - p o s i t i o n : ; - - t w - o r d i n a l : ; - - t w - s l a s h e d - z e r o : ; - - t w - n u m e r i c - f i g u r e : ; - - t w - n u m e r i c - s p a c i n g : ; - - t w - n u m e r i c - f r a c t i o n : ; - - t w - r i n g - i n s e t : ; - - t w - r i n g - o f f s e t - w i d t h : 0 p x ; - - t w - r i n g - o f f s e t - c o l o r : # f f f ; - - t w - r i n g - c o l o r : r g b ( 5 9 1 3 0 2 4 6 / . 5 ) ; - - t w - r i n g - o f f s e t - s h a d o w : 0 0 # 0 0 0 0 ; - - t w - r i n g - s h a d o w : 0 0 # 0 0 0 0 ; - - t w - s h a d o w : 0 0 # 0 0 0 0 ; - - t w - s h a d o w - c o l o r e d : 0 0 # 0 0 0 0 ; - - t w - b l u r : ; - - t w - b r i g h t n e s s : ; - - t w - c o n t r a s t : ; - - t w - g r a y s c a l e : ; - - t w - h u e - r o t a t e : ; - - t w - i n v e r t : ; - - t w - s a t u r a t e : ; - - t w - s e p i a : ; - - t w - d r o p - s h a d o w : ; - - t w - b a c k d r o p - b l u r : ; - - t w - b a c k d r o p - b r i g h t n e s s : ; - - t w - b a c k d r o p - c o n t r a s t : ; - - t w - b a c k d r o p - g r a y s c a l e : ; - - t w - b a c k d r o p - h u e - r o t a t e : ; - - t w - b a c k d r o p - i n v e r t : ; - - t w - b a c k d r o p - o p a c i t y : ; - - t w - b a c k d r o p - s a t u r a t e : ; - - t w - b a c k d r o p - s e p i a : ; - - t w - c o n t a i n - s i z e : ; - - t w - c o n t a i n - l a y o u t : ; - - t w - c o n t a i n - p a i n t : ; - - t w - c o n t a i n - s t y l e : } * , : b e f o r e , : a f t e r { b o x - s i z i n g : b o r d e r - b o x ; b o r d e r - w i d t h : 0 ; b o r d e r - s t y l e : s o l i d ; b o r d e r - c o l o r : # e 5 e 7 e b } : b e f o r e , : a f t e r { - - t w - c o n t e n t : " " } h t m l , : h o s t { l i n e - h e i g h t : 1 . 5 ; - w e b k i t - t e x t - s i z e - a d j u s t : 1 0 0 % ; - m o z - t a b - s i z e : 4 ; - o - t a b - s i z e : 4 ; t a b - s i z e : 4 ; f o n t - f a m i l y : u i - s a n s - s e r i f , s y s t e m - u i , s a n s - s e r i f , " A p p l e C o l o r E m o j i " , " S e g o e U I E m o j i " , S e g o e U I S y m b o l , " N o t o C o l o r E m o j i " ; f o n t - f e a t u r e - s e t t i n g s : n o r m a l ; f o n t - v a r i a t i o n - s e t t i n g s : n o r m a l ; - w e b k i t - t a p - h i g h l i g h t - c o l o r : t r a n s p a r e n t } b o d y { m a r g i n : 0 ; l i n e - h e i g h t : i n h e r i t } h r { h e i g h t : 0 ; c o l o r : i n h e r i t ; b o r d e r - t o p - w i d t h : 1 p x } a b b r : w h e r e ( [ t i t l e ] ) { - w e b k i t - t e x t - d e c o r a t i o n : u n d e r l i n e d o t t e d ; t e x t - d e c o r a t i o n : u n d e r l i n e d o t t e d } h 1 , h 2 , h 3 , h 4 , h 5 , h 6 { f o n t - s i z e : i n h e r i t ; f o n t - w e i g h t : i n h e r i t } a { c o l o r : i n h e r i t ; t e x t - d e c o r a t i o n : i n h e r i t } b , s t r o n g { f o n t - w e i g h t : b o l d e r } c o d e , k b d , s a m p , p r e { f o n t - f a m i l y : u i - m o n o s p a c e , S F M o n o - R e g u l a r , M e n l o , M o n a c o , C o n s o l a s , L i b e r a t i o n M o n o , C o u r i e r N e w , m o n o s p a c e ; f o n t - f e a t u r e - s e t t i n g s : n o r m a l ; f o n t - v a r i a t i o n - s e t t i n g s : n o r m a l ; f o n t - s i z e : 1 e m } s m a l l { f o n t - s i z e : 8 0 % } s u b , s u p { f o n t - s i z e : 7 5 % ; l i n e - h e i g h t : 0 ; p o s i t i o n : r e l a t i v e ; v e r t i c a l - a l i g n : b a s e l i n e } s u b { b o t t o m : - . 2 5 e m } s u p { t o p : - . 5 e m } t a b l e { t e x t - i n d e n t : 0 ; b o r d e r - c o l o r : i n h e r i t ; b o r d e r - c o l l a p s e : c o l l a p s e } b u t t o n , i n p u t , o p t g r o u p , s e l e c t , t e x t a r e a { f o n t - f a m i l y : i n h e r i t ; f o n t - f e a t u r e - s e t t i n g s : i n h e r i t ; f o n t - v a r i a t i o n - s e t t i n g s : i n h e r i t ; f o n t - s i z e : 1 0 0 % ; f o n t - w e i g h t : i n h e r i t ; l i n e - h e i g h t : i n h e r i t ; l e t t e r - s p a c i n g : i n h e r i t ; c o l o r : i n h e r i t ; m a r g i n : 0 ; p a d d i n g : 0 } b u t t o n , s e l e c t { t e x t - t r a n s f o r m : n o n e } b u t t o n , i n p u t : w h e r e ( [ t y p e = b u t t o n ] ) , i n p u t : w h e r e ( [ t y p e = r e s e t ] ) , i n p u t : w h e r e ( [ t y p e = s u b m i t ] ) { - w e b k i t - a p p e a r a n c e : b u t t o n ; b a c k g r o u n d - c o l o r : t r a n s p a r e n t ; b a c k g r o u n d - i m a g e : n o n e } : - m o z - f o c u s r i n g { o u t l i n e : a u t o } : - m o z - u i - i n v a l i d { b o x - s h a d o w : n o n e } p r o g r e s s { v e r t i c a l - a l i g n : b a s e l i n e } : : - w e b k i t - i n n e r - s p i n - b u t t o n , : : - w e b k i t - o u t e r - s p i n - b u t t o n { h e i g h t : a u t o } [ t y p e = s e a r c h ] { - w e b k i t - a p p e a r a n c e : t e x t f i e l d ; o u t l i n e - o f f s e t : - 2 p x } : : - w e b k i
2024-11-07 22:31:10 +01:00
< / head >
2023-07-04 16:05:27 +02:00
2024-11-07 22:31:10 +01:00
< body >
2024-12-03 19:38:44 +01:00
< div id = "app" class = "opacity-0" > <!-- opacity - 0 will be removed on app mounted -->
< div class = "flex flex-row drawer lg:drawer-open" >
< input id = "toggle-drawer" type = "checkbox" class = "drawer-toggle" checked / >
2024-11-07 22:31:10 +01:00
2024-12-03 19:38:44 +01:00
<!-- sidebar -->
< div class = "drawer-side h-screen lg:h-screen z-50 lg:max-w-64" >
< label for = "toggle-drawer" aria-label = "close sidebar" class = "drawer-overlay" > < / label >
< div class = "flex flex-col bg-base-200 min-h-full max-w-[calc(100vw-2em)] py-4 px-4" >
< div class = "flex flex-row items-center justify-between mb-4 mt-4" >
< h2 class = "font-bold ml-4" > Conversations< / h2 >
2024-11-07 22:31:10 +01:00
2024-12-03 19:38:44 +01:00
<!-- close sidebar button -->
< label for = "toggle-drawer" class = "btn btn-ghost lg:hidden" >
< svg xmlns = "http://www.w3.org/2000/svg" width = "16" height = "16" fill = "currentColor" class = "bi bi-arrow-bar-left" viewBox = "0 0 16 16" >
< path fill-rule = "evenodd" d = "M12.5 15a.5.5 0 0 1-.5-.5v-13a.5.5 0 0 1 1 0v13a.5.5 0 0 1-.5.5M10 8a.5.5 0 0 1-.5.5H3.707l2.147 2.146a.5.5 0 0 1-.708.708l-3-3a.5.5 0 0 1 0-.708l3-3a.5.5 0 1 1 .708.708L3.707 7.5H9.5a.5.5 0 0 1 .5.5" / >
< / svg >
< / label >
< / div >
<!-- list of conversations -->
< div :class = "{
'btn btn-ghost justify-start': true,
'btn-active': messages.length === 0,
}" @click="newConversation">
+ New conversation
< / div >
< div v-for = "conv in conversations" :class = "{
'btn btn-ghost justify-start font-normal': true,
'btn-active': conv.id === viewingConvId,
}" @click="setViewingConv(conv.id)">
< span class = "truncate" > {{ conv.messages[0].content }}< / span >
< / div >
< div class = "text-center text-xs opacity-40 mt-auto mx-4" >
Conversations are saved to browser's localStorage
< / div >
2024-11-07 22:31:10 +01:00
< / div >
2024-12-03 19:38:44 +01:00
< / div >
2024-07-26 00:10:16 +02:00
2024-12-03 19:38:44 +01:00
<!-- main view -->
< div class = "chat-screen drawer-content grow flex flex-col h-screen w-screen mx-auto px-4" >
<!-- header -->
< div class = "flex flex-row items-center mt-6 mb-6" >
<!-- open sidebar button -->
< label for = "toggle-drawer" class = "btn btn-ghost lg:hidden" >
< svg xmlns = "http://www.w3.org/2000/svg" width = "16" height = "16" fill = "currentColor" class = "bi bi-list" viewBox = "0 0 16 16" >
< path fill-rule = "evenodd" d = "M2.5 12a.5.5 0 0 1 .5-.5h10a.5.5 0 0 1 0 1H3a.5.5 0 0 1-.5-.5m0-4a.5.5 0 0 1 .5-.5h10a.5.5 0 0 1 0 1H3a.5.5 0 0 1-.5-.5m0-4a.5.5 0 0 1 .5-.5h10a.5.5 0 0 1 0 1H3a.5.5 0 0 1-.5-.5" / >
2024-11-25 17:11:55 +01:00
< / svg >
2024-12-03 19:38:44 +01:00
< / label >
2024-11-07 22:31:10 +01:00
2024-12-03 19:38:44 +01:00
< div class = "grow text-2xl font-bold ml-2" > llama.cpp< / div >
<!-- action buttons (top right) -->
< div class = "flex items-center" >
< div v-if = "messages.length > 0" class = "dropdown dropdown-end" >
<!-- "more" button -->
< button tabindex = "0" role = "button" class = "btn m-1" :disabled = "isGenerating" >
< svg xmlns = "http://www.w3.org/2000/svg" width = "16" height = "16" fill = "currentColor" class = "bi bi-three-dots-vertical" viewBox = "0 0 16 16" >
< path d = "M9.5 13a1.5 1.5 0 1 1-3 0 1.5 1.5 0 0 1 3 0m0-5a1.5 1.5 0 1 1-3 0 1.5 1.5 0 0 1 3 0m0-5a1.5 1.5 0 1 1-3 0 1.5 1.5 0 0 1 3 0" / >
< / svg >
< / button >
<!-- "more" dropdown menu -->
< ul tabindex = "0" class = "dropdown-content menu bg-base-100 rounded-box z-[1] w-52 p-2 shadow" >
< li @ click = "downloadConv(viewingConvId)" > < a > Download< / a > < / li >
< li class = "text-error" @ click = "deleteConv(viewingConvId)" > < a > Delete< / a > < / li >
< / ul >
< / div >
< button class = "btn" @ click = "showConfigDialog = true" :disabled = "isGenerating" >
<!-- settings button -->
< svg xmlns = "http://www.w3.org/2000/svg" width = "16" height = "16" fill = "currentColor" class = "bi bi-gear" viewBox = "0 0 16 16" >
< path d = "M8 4.754a3.246 3.246 0 1 0 0 6.492 3.246 3.246 0 0 0 0-6.492M5.754 8a2.246 2.246 0 1 1 4.492 0 2.246 2.246 0 0 1-4.492 0" / >
< path d = "M9.796 1.343c-.527-1.79-3.065-1.79-3.592 0l-.094.319a.873.873 0 0 1-1.255.52l-.292-.16c-1.64-.892-3.433.902-2.54 2.541l.159.292a.873.873 0 0 1-.52 1.255l-.319.094c-1.79.527-1.79 3.065 0 3.592l.319.094a.873.873 0 0 1 .52 1.255l-.16.292c-.892 1.64.901 3.434 2.541 2.54l.292-.159a.873.873 0 0 1 1.255.52l.094.319c.527 1.79 3.065 1.79 3.592 0l.094-.319a.873.873 0 0 1 1.255-.52l.292.16c1.64.893 3.434-.902 2.54-2.541l-.159-.292a.873.873 0 0 1 .52-1.255l.319-.094c1.79-.527 1.79-3.065 0-3.592l-.319-.094a.873.873 0 0 1-.52-1.255l.16-.292c.893-1.64-.902-3.433-2.541-2.54l-.292.159a.873.873 0 0 1-1.255-.52zm-2.633.283c.246-.835 1.428-.835 1.674 0l.094.319a1.873 1.873 0 0 0 2.693 1.115l.291-.16c.764-.415 1.6.42 1.184 1.185l-.159.292a1.873 1.873 0 0 0 1.116 2.692l.318.094c.835.246.835 1.428 0 1.674l-.319.094a1.873 1.873 0 0 0-1.115 2.693l.16.291c.415.764-.42 1.6-1.185 1.184l-.291-.159a1.873 1.873 0 0 0-2.693 1.116l-.094.318c-.246.835-1.428.835-1.674 0l-.094-.319a1.873 1.873 0 0 0-2.692-1.115l-.292.16c-.764.415-1.6-.42-1.184-1.185l.159-.291A1.873 1.873 0 0 0 1.945 8.93l-.319-.094c-.835-.246-.835-1.428 0-1.674l.319-.094A1.873 1.873 0 0 0 3.06 4.377l-.16-.292c-.415-.764.42-1.6 1.185-1.184l.292.159a1.873 1.873 0 0 0 2.692-1.115z" / >
2024-11-07 22:31:10 +01:00
< / svg >
2024-12-03 19:38:44 +01:00
< / button >
<!-- theme controller is copied from https://daisyui.com/components/theme - controller/ -->
< div class = "dropdown dropdown-end dropdown-bottom" >
< div tabindex = "0" role = "button" class = "btn m-1" >
< svg xmlns = "http://www.w3.org/2000/svg" width = "16" height = "16" fill = "currentColor" class = "bi bi-palette2" viewBox = "0 0 16 16" >
< path d = "M0 .5A.5.5 0 0 1 .5 0h5a.5.5 0 0 1 .5.5v5.277l4.147-4.131a.5.5 0 0 1 .707 0l3.535 3.536a.5.5 0 0 1 0 .708L10.261 10H15.5a.5.5 0 0 1 .5.5v5a.5.5 0 0 1-.5.5H3a3 3 0 0 1-2.121-.879A3 3 0 0 1 0 13.044m6-.21 7.328-7.3-2.829-2.828L6 7.188zM4.5 13a1.5 1.5 0 1 0-3 0 1.5 1.5 0 0 0 3 0M15 15v-4H9.258l-4.015 4zM0 .5v12.495zm0 12.495V13z" / >
< / svg >
< / div >
< ul tabindex = "0" class = "dropdown-content bg-base-300 rounded-box z-[1] w-52 p-2 shadow-2xl h-80 overflow-y-auto" >
< li >
< button
class="btn btn-sm btn-block btn-ghost justify-start"
:class="{ 'btn-active': selectedTheme === 'auto' }"
@click="setSelectedTheme('auto')">
auto
< / button >
< / li >
< li v-for = "theme in themes" >
< input
type="radio"
name="theme-dropdown"
class="theme-controller btn btn-sm btn-block btn-ghost justify-start"
:aria-label="theme"
:value="theme"
:checked="selectedTheme === theme"
@click="setSelectedTheme(theme)" />
< / li >
< / ul >
2024-11-07 22:31:10 +01:00
< / div >
< / div >
< / div >
2023-07-04 16:05:27 +02:00
2024-12-03 19:38:44 +01:00
<!-- chat messages -->
< div id = "messages-list" class = "flex flex-col grow overflow-y-auto" >
< div class = "mt-auto flex justify-center" >
<!-- placeholder to shift the message to the bottom -->
{{ messages.length === 0 ? 'Send a message to start' : '' }}
< / div >
< div v-for = "msg in messages" class = "group" >
2024-11-07 22:31:10 +01:00
< div :class = "{
2024-12-03 19:38:44 +01:00
'chat': true,
'chat-start': msg.role !== 'user',
'chat-end': msg.role === 'user',
2024-11-07 22:31:10 +01:00
}">
2024-12-03 19:38:44 +01:00
< div :class = "{
'chat-bubble markdown': true,
'chat-bubble-base-300': msg.role !== 'user',
}">
<!-- textarea for editing message -->
< template v-if = "editingMsg && editingMsg.id === msg.id" >
< textarea
class="textarea textarea-bordered bg-base-100 text-base-content w-[calc(90vw-8em)] lg:w-96"
v-model="msg.content">< / textarea >
< br / >
< button class = "btn btn-ghost mt-2 mr-2" @ click = "editingMsg = null" > Cancel< / button >
< button class = "btn mt-2" @ click = "editUserMsgAndRegenerate(msg)" > Submit< / button >
< / template >
<!-- render message as markdown -->
< vue-markdown v-else :source = "msg.content" / >
< / div >
< / div >
<!-- actions for each message -->
< div :class = "{'text-right': msg.role === 'user'}" class = "mx-4 mt-2 mb-2" >
<!-- user message -->
< button v-if = "msg.role === 'user'" class = "badge btn-mini show-on-hover" @ click = "editingMsg = msg" :disabled = "isGenerating" >
✍️ Edit
< / button >
<!-- assistant message -->
< button v-if = "msg.role === 'assistant'" class = "badge btn-mini show-on-hover mr-2" @ click = "regenerateMsg(msg)" :disabled = "isGenerating" >
🔄 Regenerate
< / button >
< button v-if = "msg.role === 'assistant'" class = "badge btn-mini show-on-hover mr-2" @ click = "copyMsg(msg)" :disabled = "isGenerating" >
📋 Copy
< / button >
2024-11-07 22:31:10 +01:00
< / div >
< / div >
2023-07-04 16:05:27 +02:00
2024-12-03 19:38:44 +01:00
<!-- pending (ongoing) assistant message -->
< div id = "pending-msg" class = "chat chat-start" >
< div v-if = "pendingMsg" class = "chat-bubble markdown chat-bubble-base-300" >
< span v-if = "!pendingMsg.content" class = "loading loading-dots loading-md" > < / span >
< vue-markdown v-else :source = "pendingMsg.content" / >
< / div >
2024-11-07 22:31:10 +01:00
< / div >
< / div >
2023-07-04 16:05:27 +02:00
2024-12-03 19:38:44 +01:00
<!-- chat input -->
< div class = "flex flex-row items-center mt-8 mb-6" >
< textarea
class="textarea textarea-bordered w-full"
placeholder="Type a message (Shift+Enter to add a new line)"
v-model="inputMsg"
@keydown.enter.exact.prevent="sendMessage"
@keydown.enter.shift.exact.prevent="inputMsg += '\n'"
:disabled="isGenerating"
id="msg-input"
>< / textarea >
< button v-if = "!isGenerating" class = "btn btn-primary ml-2" @ click = "sendMessage" :disabled = "inputMsg.length === 0" > Send< / button >
< button v-else class = "btn btn-neutral ml-2" @ click = "stopGeneration" > Stop< / button >
2024-11-07 22:31:10 +01:00
< / div >
< / div >
< / div >
2024-12-03 19:38:44 +01:00
2024-11-07 22:31:10 +01:00
<!-- modal for editing config -->
< dialog class = "modal" :class = "{'modal-open': showConfigDialog}" >
< div class = "modal-box" >
< h3 class = "text-lg font-bold mb-6" > Settings< / h3 >
< div class = "h-[calc(90vh-12rem)] overflow-y-auto" >
< p class = "opacity-40 mb-6" > Settings below are saved in browser's localStorage< / p >
2024-11-15 10:48:49 +01:00
< settings-modal-short-input :config-key = "'apiKey'" :config-default = "configDefault" :config-info = "configInfo" v-model = "config.apiKey" > < / settings-modal-short-input >
2024-11-07 22:31:10 +01:00
< label class = "form-control mb-2" >
< div class = "label" > System Message< / div >
< textarea class = "textarea textarea-bordered h-24" :placeholder = "'Default: ' + configDefault.systemMessage" v-model = "config.systemMessage" > < / textarea >
< / label >
2024-11-10 20:42:25 +01:00
< template v-for = "configKey in ['temperature', 'top_k', 'top_p', 'min_p', 'max_tokens']" >
2024-12-03 19:38:44 +01:00
< settings-modal-short-input :config-key = "configKey" :config-default = "configDefault" :config-info = "configInfo" v-model = "config[configKey]" > < / settings-modal-short-input >
2024-11-07 22:31:10 +01:00
< / template >
<!-- TODO: add more sampling - related configs, please regroup them into different "collapse" sections -->
2024-11-10 20:42:25 +01:00
<!-- Section: Other sampler settings -->
< details class = "collapse collapse-arrow bg-base-200 mb-2 overflow-visible" >
< summary class = "collapse-title font-bold" > Other sampler settings< / summary >
< div class = "collapse-content" >
2024-11-16 14:26:54 +01:00
<!-- Samplers queue -->
< settings-modal-short-input label = "Samplers queue" :config-key = "'samplers'" :config-default = "configDefault" :config-info = "configInfo" v-model = "config.samplers" > < / settings-modal-short-input >
<!-- Samplers -->
2024-11-10 20:42:25 +01:00
< template v-for = "configKey in ['dynatemp_range', 'dynatemp_exponent', 'typical_p', 'xtc_probability', 'xtc_threshold']" >
2024-12-03 19:38:44 +01:00
< settings-modal-short-input :config-key = "configKey" :config-default = "configDefault" :config-info = "configInfo" v-model = "config[configKey]" > < / settings-modal-short-input >
2024-11-10 20:42:25 +01:00
< / template >
< / div >
< / details >
<!-- Section: Penalties settings -->
< details class = "collapse collapse-arrow bg-base-200 mb-2 overflow-visible" >
< summary class = "collapse-title font-bold" > Penalties settings< / summary >
< div class = "collapse-content" >
< template v-for = "configKey in ['repeat_last_n', 'repeat_penalty', 'presence_penalty', 'frequency_penalty', 'dry_multiplier', 'dry_base', 'dry_allowed_length', 'dry_penalty_last_n']" >
2024-12-03 19:38:44 +01:00
< settings-modal-short-input :config-key = "configKey" :config-default = "configDefault" :config-info = "configInfo" v-model = "config[configKey]" > < / settings-modal-short-input >
2024-11-10 20:42:25 +01:00
< / template >
< / div >
< / details >
<!-- Section: Advanced config -->
< details class = "collapse collapse-arrow bg-base-200 mb-2 overflow-visible" >
< summary class = "collapse-title font-bold" > Advanced config< / summary >
2024-11-07 22:31:10 +01:00
< div class = "collapse-content" >
< label class = "form-control mb-2" >
2024-11-16 14:26:54 +01:00
<!-- Custom parameters input -->
2024-11-07 22:31:10 +01:00
< div class = "label inline" > Custom JSON config (For more info, refer to < a class = "underline" href = "https://github.com/ggerganov/llama.cpp/blob/master/examples/server/README.md" target = "_blank" rel = "noopener noreferrer" > server documentation< / a > )< / div >
< textarea class = "textarea textarea-bordered h-24" placeholder = "Example: { "mirostat": 1, "min_p": 0.1 }" v-model = "config.custom" > < / textarea >
< / label >
2024-07-26 00:10:16 +02:00
< / div >
2024-11-10 20:42:25 +01:00
< / details >
2024-11-07 22:31:10 +01:00
< / div >
2023-07-04 16:05:27 +02:00
2024-11-07 22:31:10 +01:00
<!-- action buttons -->
< div class = "modal-action" >
< button class = "btn" @ click = "resetConfigDialog" > Reset to default< / button >
< button class = "btn" @ click = "closeAndDiscardConfigDialog" > Close< / button >
2024-12-03 19:38:44 +01:00
< button class = "btn btn-primary" @ click = "closeAndSaveConfigDialog" > Save< / button >
2024-11-07 22:31:10 +01:00
< / div >
< / div >
< / dialog >
2024-12-03 19:38:44 +01:00
2024-11-07 22:31:10 +01:00
< / div >
2023-10-12 08:51:53 +02:00
2024-11-10 20:42:25 +01:00
<!-- Template to be used by settings modal -->
2024-11-15 10:48:49 +01:00
< template id = "settings-modal-short-input" >
2024-11-10 20:42:25 +01:00
< label class = "input input-bordered join-item grow flex items-center gap-2 mb-2" >
<!-- Show help message on hovering on the input label -->
< div class = "dropdown dropdown-hover" >
2024-11-16 14:26:54 +01:00
< div tabindex = "0" role = "button" class = "font-bold" > {{ label || configKey }}< / div >
2024-11-10 20:42:25 +01:00
< div class = "dropdown-content menu bg-base-100 rounded-box z-10 w-64 p-2 shadow mt-4" >
{{ configInfo[configKey] || '(no help message available)' }}
< / div >
< / div >
<!-- Here we forward v - model from parent to child component, see: https://stackoverflow.com/questions/47311936/v - model - and - child - components -->
< input type = "text" class = "grow" :placeholder = "'Default: ' + (configDefault[configKey] || 'none')" :value = "modelValue" @ input = "$emit('update:modelValue', $event.target.value)" / >
< / label >
< / template >
2023-07-04 16:05:27 +02:00
< / body >
< / html >