@pagelines/widget 1.0.936 → 1.0.937
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/widget.js +21 -21
- package/package.json +2 -2
package/dist/widget.js
CHANGED
|
@@ -67,11 +67,11 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
67
67
|
* @vue/reactivity v3.5.45
|
|
68
68
|
* (c) 2018-present Yuxi (Evan) You and Vue contributors
|
|
69
69
|
* @license MIT
|
|
70
|
-
**/yl=class{constructor(t=!1){this.detached=t,this._active=!0,this._on=0,this.effects=[],this.cleanups=[],this._isPaused=!1,this._warnOnRun=!0,this.__v_skip=!0,!t&&Gt&&(Gt.active?(this.parent=Gt,this.index=(Gt.scopes||(Gt.scopes=[])).push(this)-1):(this._active=!1,this._warnOnRun=!1))}get active(){return this._active}pause(){if(this._active){this._isPaused=!0;let t,n;if(this.scopes){let i=this.scopes.slice();for(t=0,n=i.length;t<n;t++)i[t].pause()}for(t=0,n=this.effects.length;t<n;t++)this.effects[t].pause()}}resume(){if(this._active&&this._isPaused){this._isPaused=!1;let t,n;if(this.scopes){let r=this.scopes.slice();for(t=0,n=r.length;t<n;t++)r[t].resume()}let i=this.effects.slice();for(t=0,n=i.length;t<n;t++)i[t].resume()}}run(t){if(this._active){let n=Gt;try{return Gt=this,t()}finally{Gt=n}}}on(){++this._on===1&&(this.prevScope=Gt,Gt=this)}off(){if(this._on>0&&--this._on===0){if(Gt===this)Gt=this.prevScope;else{let t=Gt;for(;t;){if(t.prevScope===this){t.prevScope=this.prevScope;break}t=t.prevScope}}this.prevScope=void 0}}stop(t){if(this._active){this._active=!1;let n,i;for(n=0,i=this.effects.length;n<i;n++)this.effects[n].stop();for(this.effects.length=0,n=0,i=this.cleanups.length;n<i;n++)this.cleanups[n]();if(this.cleanups.length=0,this.scopes){let r=this.scopes.slice();for(n=0,i=r.length;n<i;n++)r[n].stop(!0);this.scopes.length=0}if(!this.detached&&this.parent&&!t){let r=this.parent.scopes.pop();r&&r!==this&&(this.parent.scopes[this.index]=r,r.index=this.index)}this.parent=void 0}}};Kb=new WeakSet,Sa=class{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,Gt&&(Gt.active?Gt.effects.push(this):this.flags&=-2)}pause(){this.flags|=64}resume(){this.flags&64&&(this.flags&=-65,Kb.has(this)&&(Kb.delete(this),this.trigger()))}notify(){this.flags&2&&!(this.flags&32)||this.flags&8||T$(this)}run(){if(!(this.flags&1))return this.fn();this.flags|=2,_$(this),N$(this);let t=ht,n=nn;ht=this,nn=!0;try{return this.fn()}finally{C$(this),ht=t,nn=n,this.flags&=-3}}stop(){if(this.flags&1){for(let t=this.deps;t;t=t.nextDep)a0(t);this.deps=this.depsTail=void 0,_$(this),this.onStop&&this.onStop(),this.flags&=-2}}trigger(){this.flags&64?Kb.add(this):this.scheduler?this.scheduler():this.runIfDirty()}runIfDirty(){Gb(this)&&this.run()}get dirty(){return Gb(this)}},E$=0;nn=!0,A$=[];wl=0,Jb=class{constructor(t,n){this.sub=t,this.dep=n,this.version=n.version,this.nextDep=this.prevDep=this.nextSub=this.prevSub=this.prevActiveLink=void 0}},Ia=class{constructor(t){this.computed=t,this.version=0,this.activeLink=void 0,this.subs=void 0,this.map=void 0,this.key=void 0,this.sc=0,this.__v_skip=!0}track(t){if(!ht||!nn||ht===this.computed)return;let n=this.activeLink;if(n===void 0||n.sub!==ht)n=this.activeLink=new Jb(ht,this),ht.deps?(n.prevDep=ht.depsTail,ht.depsTail.nextDep=n,ht.depsTail=n):ht.deps=ht.depsTail=n,O$(n);else if(n.version===-1&&(n.version=this.version,n.nextDep)){let i=n.nextDep;i.prevDep=n.prevDep,n.prevDep&&(n.prevDep.nextDep=i),n.prevDep=ht.depsTail,n.nextDep=void 0,ht.depsTail.nextDep=n,ht.depsTail=n,ht.deps===n&&(ht.deps=i)}return n}trigger(t){this.version++,wl++,this.notify(t)}notify(t){i0();try{for(let n=this.subs;n;n=n.prevSub)n.sub.notify()&&n.sub.dep.notify()}finally{o0()}}};Yb=new WeakMap,eo=Symbol(""),Xb=Symbol(""),kl=Symbol("");cA={__proto__:null,[Symbol.iterator](){return Wb(this,Symbol.iterator,e=>vn(this,e))},concat(...e){return $a(this).concat(...e.map(t=>xe(t)?$a(t):t))},entries(){return Wb(this,"entries",e=>(e[1]=vn(this,e[1]),e))},every(e,t){return Fn(this,"every",e,t,void 0,arguments)},filter(e,t){return Fn(this,"filter",e,t,n=>n.map(i=>vn(this,i)),arguments)},find(e,t){return Fn(this,"find",e,t,n=>vn(this,n),arguments)},findIndex(e,t){return Fn(this,"findIndex",e,t,void 0,arguments)},findLast(e,t){return Fn(this,"findLast",e,t,n=>vn(this,n),arguments)},findLastIndex(e,t){return Fn(this,"findLastIndex",e,t,void 0,arguments)},forEach(e,t){return Fn(this,"forEach",e,t,void 0,arguments)},includes(...e){return qb(this,"includes",e)},indexOf(...e){return qb(this,"indexOf",e)},join(e){return $a(this).join(e)},lastIndexOf(...e){return qb(this,"lastIndexOf",e)},map(e,t){return Fn(this,"map",e,t,void 0,arguments)},pop(){return gl(this,"pop")},push(...e){return gl(this,"push",e)},reduce(e,...t){return S$(this,"reduce",e,t)},reduceRight(e,...t){return S$(this,"reduceRight",e,t)},shift(){return gl(this,"shift")},some(e,t){return Fn(this,"some",e,t,void 0,arguments)},splice(...e){return gl(this,"splice",e)},toReversed(){return $a(this).toReversed()},toSorted(e){return $a(this).toSorted(e)},toSpliced(...e){return $a(this).toSpliced(...e)},unshift(...e){return gl(this,"unshift",e)},values(){return Wb(this,"values",e=>vn(this,e))}};D$=Array.prototype;uA=ga("__proto__,__v_isRef,__isVue"),P$=new Set(Object.getOwnPropertyNames(Symbol).filter(e=>e!=="arguments"&&e!=="caller").map(e=>Symbol[e]).filter(_r));Dd=class{constructor(t=!1,n=!1){this._isReadonly=t,this._isShallow=n}get(t,n,i){if(n==="__v_skip")return t.__v_skip;let r=this._isReadonly,o=this._isShallow;if(n==="__v_isReactive")return!r;if(n==="__v_isReadonly")return r;if(n==="__v_isShallow")return o;if(n==="__v_raw")return i===(r?o?wA:j$:o?U$:R$).get(t)||Object.getPrototypeOf(t)===Object.getPrototypeOf(i)?t:void 0;let a=xe(t);if(!r){let l;if(a&&(l=cA[n]))return l;if(n==="hasOwnProperty")return dA}let s=Reflect.get(t,n,Vt(t)?t:i);if((_r(n)?P$.has(n):uA(n))||(r||Jt(t,"get",n),o))return s;if(Vt(s)){let l=a&&Td(n)?s:s.value;return r&&qe(l)?Rd(l):l}return qe(s)?r?Rd(s):_l(s):s}},Pd=class extends Dd{constructor(t=!1){super(!1,t)}set(t,n,i,r){let o=t[n],a=xe(t)&&Td(n);if(!this._isShallow){let u=Vr(o);if(!$r(i)&&!Vr(i)&&(o=He(o),i=He(i)),!a&&Vt(o)&&!Vt(i))return u||(o.value=i),!0}let s=a?Number(n)<t.length:Ke(t,n),l=Reflect.set(t,n,i,Vt(t)?t:r);return t===He(r)&&l&&(s?Rt(i,o)&&bn(t,"set",n,i,o):bn(t,"add",n,i)),l}deleteProperty(t,n){let i=Ke(t,n),r=t[n],o=Reflect.deleteProperty(t,n);return o&&i&&bn(t,"delete",n,void 0,r),o}has(t,n){let i=Reflect.has(t,n);return(!_r(n)||!P$.has(n))&&Jt(t,"has",n),i}ownKeys(t){return Jt(t,"iterate",xe(t)?"length":eo),Reflect.ownKeys(t)}},Qb=class extends Dd{constructor(t=!1){super(!0,t)}set(t,n){return!0}deleteProperty(t,n){return!0}},pA=new Pd,mA=new Qb,fA=new Pd(!0),e0=e=>e,zd=e=>Reflect.getPrototypeOf(e);vA={get:s0(!1,!1)},bA={get:s0(!1,!0)},yA={get:s0(!0,!1)},R$=new WeakMap,U$=new WeakMap,j$=new WeakMap,wA=new WeakMap;Ar=e=>qe(e)?_l(e):e,Bn=e=>qe(e)?Rd(e):e;t0=class{constructor(t,n){this.dep=new Ia,this.__v_isRef=!0,this.__v_isShallow=!1,this._rawValue=n?t:He(t),this._value=n?t:Ar(t),this.__v_isShallow=n}get value(){return this.dep.track(),this._value}set value(t){let n=this._rawValue,i=this.__v_isShallow||$r(t)||Vr(t);t=i?t:He(t),Rt(t,n)&&(this._rawValue=t,this._value=i?t:Ar(t),this.dep.trigger())}};xA={get:(e,t,n)=>t==="__v_raw"?e:Ae(Reflect.get(e,t,n)),set:(e,t,n,i)=>{let r=e[t];return Vt(r)&&!Vt(n)?(r.value=n,!0):Reflect.set(e,t,n,i)}};r0=class{constructor(t){this.__v_isRef=!0,this._value=void 0;let n=this.dep=new Ia,{get:i,set:r}=t(n.track.bind(n),n.trigger.bind(n));this._get=i,this._set=r}get value(){return this._value=this._get()}set value(t){this._set(t)}};n0=class{constructor(t,n,i){this.fn=t,this.setter=n,this._value=void 0,this.dep=new Ia(this),this.__v_isRef=!0,this.deps=void 0,this.depsTail=void 0,this.flags=16,this.globalVersion=wl-1,this.next=void 0,this.effect=this,this.__v_isReadonly=!n,this.isSSR=i}notify(){if(this.flags|=16,!(this.flags&8)&&ht!==this)return T$(this,!0),!0}get value(){let t=this.dep.track();return z$(this),t&&(t.version=this.dep.version),this._value}set value(t){this.setter&&this.setter(t)}};Od={},Ud=new WeakMap});function jl(e,t,n,i){try{return i?e(...i):e()}catch(r){Yd(r,t,n)}}function Dr(e,t,n,i){if(Te(e)){let r=jl(e,t,n,i);return r&&Bb(r)&&r.catch(o=>{Yd(o,t,n,void 0,!0)}),r}if(xe(e)){let r=[];for(let o=0;o<e.length;o++)r.push(Dr(e[o],t,n,i));return r}}function Yd(e,t,n,i=!0,r=!1){let o=t?t.vnode:null,{errorHandler:a,throwUnhandledErrorInProduction:s}=t&&t.appContext.config||Ze;if(t){let l=t.parent,u=t.proxy,d=`https://vuejs.org/error-reference/#runtime-${n}`;for(;l;){let p=l.ec;if(p&&!l.isUnmounted&&(!r||l.scope.active)){for(let m=0;m<p.length;m++)if(p[m](e,u,d)===!1)return}l=l.parent}if(a){on(),jl(a,null,10,[e,u,d]),an();return}}SA(e,n,o,i,s)}function SA(e,t,n,i=!0,r=!1){if(r)throw e;console.error(e)}function oo(e){let t=Fd||oS;return e?t.then(this?e.bind(this):e):t}function IA(e){let t=sn+1,n=pr.length;for(;t<n;){let i=t+n>>>1,r=pr[i],o=Al(r);o<e||o===e&&r.flags&2?t=i+1:n=i}return t}function Xd(e){if(!(e.flags&1)){let t=Al(e),n=pr[pr.length-1];!n||!(e.flags&2)&&t>=Al(n)?pr.push(e):pr.splice(IA(t),0,e),e.flags|=1,aS()}}function aS(){Fd||(Fd=oS.then(uS))}function sS(e){if(!xe(e))Si&&e.id===-1?Si.splice(Ta+1,0,e):e.flags&1||(xn.push(e),e.flags|=1);else for(let t=0;t<e.length;t++)xn.push(e[t]);aS()}function lS(e,t,n,i=sn+1){for(;i<pr.length;i++){let r=pr[i];if(r&&r.flags&2){if(e&&r.id!==e.uid||t!==void 0&&!(r.id>=t))continue;pr.splice(i,1),i=e?i-1:sn,r.flags&4&&(r.flags&=-2),r(),r.flags&4||(r.flags&=-2)}}}function cS(e,t,n=0){if(xn.length){let i=xn,r=0;if(t){i=[];for(let a=0;a<xn.length;a++){let s=xn[a];(s.i!==void 0?!s.i||s.i.uid<n:t.has(s))?xn[r++]=s:i.push(s)}}let o=[...new Set(i)].sort((a,s)=>Al(a)-Al(s));if(xn.length=r,Si){for(let a=0;a<o.length;a++)Si.push(o[a]);return}for(Si=o,Ta=0;Ta<Si.length;Ta++){let a=Si[Ta];a.flags&4&&(a.flags&=-2),a.flags&8||a(),a.flags&=-2}Si=null,Ta=0}}function EA(e,t){if(p0){e();return}let n=t===void 0?void 0:new Set(xn);e(),p0=!0;try{lS(void 0,t),cS(void 0,n,t)}finally{p0=!1}}function uS(e){let t=ur;try{for(sn=0;sn<pr.length;sn++){let n=pr[sn];n&&!(n.flags&8)&&(n.flags&4&&(n.flags&=-2),jl(n,n.i,n.i?15:14),n.flags&4||(n.flags&=-2))}}finally{for(;sn<pr.length;sn++){let n=pr[sn];n&&(n.flags&=-2)}sn=-1,pr.length=0,cS(e),Fd=null,(pr.length||xn.length)&&uS(e)}}function Qd(e,...t){$n?$n.emit(e,...t):v0||Il.push({event:e,args:t})}function dS(e,t){var n,i;$n=e,$n?($n.enabled=!0,Il.forEach(({event:r,args:o})=>$n.emit(r,...o)),Il=[]):typeof window<"u"&&window.HTMLElement&&!((i=(n=window.navigator)==null?void 0:n.userAgent)!=null&&i.includes("jsdom"))?((t.__VUE_DEVTOOLS_HOOK_REPLAY__=t.__VUE_DEVTOOLS_HOOK_REPLAY__||[]).push(o=>{dS(o,t)}),setTimeout(()=>{$n||(t.__VUE_DEVTOOLS_HOOK_REPLAY__=null,v0=!0,Il=[])},3e3)):(v0=!0,Il=[])}function NA(e,t){Qd("app:init",e,t,{Fragment:ge,Text:Ml,Comment:Ft,Static:za})}function CA(e){Qd("app:unmount",e)}function $0(e){return t=>{Qd(e,t.appContext.app,t.uid,t.parent?t.parent.uid:void 0,t)}}function DA(e,t,n){Qd("component:emit",e.appContext.app,e,t,n)}function Bd(e){let t=Yt;return Yt=e,mS=e&&e.type.__scopeId||null,t}function ot(e,t=Yt,n){if(!t||e._n)return e;let i=(...r)=>{i._d&&qd(-1);let o=Bd(t),a=Hn.length,s;try{s=e(...r)}finally{for(let l=Hn.length;l>a;l--)P0();Bd(o),i._d&&qd(1)}return __VUE_PROD_DEVTOOLS__&&pS(t),s};return i._n=!0,i._c=!0,i._d=!0,i}function ep(e,t){if(Yt===null)return e;let n=op(Yt),i=e.dirs||(e.dirs=[]);for(let r=0;r<t.length;r++){let[o,a,s,l=Ze]=t[r];o&&(Te(o)&&(o={mounted:o,updated:o}),o.deep&&yn(a),i.push({dir:o,instance:n,value:a,oldValue:void 0,arg:s,modifiers:l}))}return e}function to(e,t,n,i){let r=e;if(i==="beforeMount")e._mount=e;else if(i==="beforeUpdate"){let s=t&&t._mount;s&&(s._latest=e,e._mount=s)}else if(i==="mounted"){let s=e._latest;e._mount=e._latest=void 0,s&&(r=s,s._mount=void 0)}let o=r.dirs,a=t&&t.dirs;for(let s=0;s<o.length;s++){let l=o[s];a?l.oldValue=a[s].value:i==="mounted"&&l.oldValue!==void 0&&(l=it({},l,{oldValue:void 0}));let u=l.dir[i];u&&(on(),Dr(u,n,8,[e.el,l,r,t]),an())}}function PA(e,t){if(nr){let n=nr.provides,i=nr.parent&&nr.parent.provides;i===n&&(n=nr.provides=Object.create(i)),n[e]=t}}function Ld(e,t,n=!1){let i=Ua();if(i||Ca){let r=Ca?Ca._context.provides:i?i.parent==null||i.ce?i.vnode.appContext&&i.vnode.appContext.provides:i.parent.provides:void 0;if(r&&e in r)return r[e];if(arguments.length>1)return n&&Te(t)?t.call(i&&i.proxy):t}}function jA(e,t){return S0(e,null,{flush:"sync"})}function mt(e,t,n){return S0(e,t,n)}function S0(e,t,n=Ze){let{immediate:i,deep:r,flush:o,once:a}=n,s=it({},n),l=t&&i||!t&&o!=="post",u;if(Ul){if(o==="sync"){let f=UA();u=f.__watcherHandles||(f.__watcherHandles=[])}else if(!l){let f=()=>{};return f.stop=ur,f.resume=ur,f.pause=ur,f}}let d=nr;s.call=(f,h,v)=>Dr(f,d,h,v);let p=!1;o==="post"?s.scheduler=f=>{f.i=d,rr(f,d&&d.suspense)}:o!=="sync"&&(p=!0,s.scheduler=(f,h)=>{h?f():Xd(f)}),s.augmentJob=f=>{t&&(f.flags|=4),p&&(f.flags|=2,d&&(f.id=d.uid,f.i=d))};let m=F$(e,t,s);return Ul&&(u?u.push(m):l&&m()),m}function MA(e,t,n){let i=this.proxy,r=pt(e)?e.includes(".")?fS(i,e):()=>i[e]:e.bind(i,i),o;Te(t)?o=t:(o=t.handler,n=t);let a=Ll(this),s=S0(r,o.bind(i),n);return a(),s}function fS(e,t){let n=t.split(".");return()=>{let i=e;for(let r=0;r<n.length&&i;r++)i=i[n[r]];return i}}function Md(e,t,n,{o:{insert:i},m:r},o=2){o===0&&(e.targetStart&&i(e.targetStart,t,n),i(e.targetAnchor,t,n),n=e.targetAnchor);let{el:a,anchor:s,shapeFlag:l,children:u,props:d}=e,p=o===2;if(p&&i(a,t,n),!$i.has(e)&&(!p||no(d))&&l&16)for(let m=0;m<u.length;m++)r(u[m],t,n,2);p&&i(s,t,n)}function FA(e,t,n,i,r,o,{o:{nextSibling:a,parentNode:s,querySelector:l,insert:u,createText:d}},p){function m(k,T){let S=T;for(;S;){if(S&&S.nodeType===8){if(S.data==="teleport start anchor")t.targetStart=S;else if(S.data==="teleport anchor"){t.targetAnchor=S,k._lpa=t.targetAnchor&&a(t.targetAnchor);break}}S=a(S)}}function f(k,T){T.anchor=p(a(k),T,s(k),n,i,r,o)}let h=t.target=b0(t.props,l),v=no(t.props);if(h){let k=h._lpa||h.firstChild;t.shapeFlag&16&&(v?(f(e,t),m(h,k),t.targetAnchor||y0(h,t,d,u,s(e)===h?e:null)):(t.anchor=a(e),m(h,k),t.targetAnchor||y0(h,t,d,u),p(k&&a(k),t,h,n,i,r,o))),El(t,v)}else v&&t.shapeFlag&16&&(f(e,t),t.targetStart=e,t.targetAnchor=a(e));return t.anchor&&a(t.anchor)}function El(e,t){let n=e.ctx;if(n&&n.ut){let i,r;for(t?(i=e.el,r=e.anchor):(i=e.targetStart,r=e.targetAnchor);i&&i!==r;)i.nodeType===1&&i.setAttribute("data-v-owner",n.uid),i=i.nextSibling;n.ut()}}function y0(e,t,n,i,r=null){let o=t.targetStart=n(""),a=t.targetAnchor=n("");return o[hS]=a,e&&(i(o,e,r),i(a,e,r)),a}function I0(){let e={isMounted:!1,isLeaving:!1,isUnmounting:!1,leavingVNodes:new Map};return Ut(()=>{e.isMounted=!0}),Da(()=>{e.isUnmounting=!0}),e}function vS(e){let t=e[0];if(e.length>1){let n=!1;for(let i of e)if(i.type!==Ft){t=i,n=!0;break}}return t}function yS(e,t){let{leavingVNodes:n}=e,i=n.get(t.type);return i||(i=Object.create(null),n.set(t.type,i)),i}function Aa(e,t,n,i){let{appear:r,mode:o,persisted:a=!1,onBeforeEnter:s,onEnter:l,onAfterEnter:u,onEnterCancelled:d,onBeforeLeave:p,onLeave:m,onAfterLeave:f,onLeaveCancelled:h,onBeforeAppear:v,onAppear:k,onAfterAppear:T,onAppearCancelled:S}=t,z=String(e.key),j=yS(n,e),O=(W,ce)=>{W&&Dr(W,i,9,ce)},U=(W,ce)=>{let se=ce[1];O(W,ce),xe(W)?W.every(pe=>pe.length<=1)&&se():W.length<=1&&se()},J={mode:o,persisted:a,beforeEnter(W){let ce=s;if(!n.isMounted)if(r)ce=v||s;else return;W[Br]&&W[Br](!0);let se=j[z];if(se&&io(e,se)){let pe=se.el[Br];if(!pe){let F=Ol(se);pe=F&&F.el[Br]}pe&&pe()}O(ce,[W])},enter(W){if(!TA&&j[z]===e)return;let ce=l,se=u,pe=d;if(!n.isMounted)if(r)ce=k||l,se=T||u,pe=S||d;else return;let F=!1;W[Sl]=Je=>{F||(F=!0,Je?O(pe,[W]):O(se,[W]),J.delayedLeave&&J.delayedLeave(),W[Sl]=void 0)};let ue=W[Sl].bind(null,!1);ce?U(ce,[W,ue]):ue()},leave(W,ce){let se=String(e.key);if(W[Sl]&&W[Sl](!0),n.isUnmounting)return ce();O(p,[W]);let pe=!1;W[Br]=ue=>{pe||(pe=!0,ce(),ue?O(h,[W]):O(f,[W]),W[Br]=void 0,j[se]===e&&delete j[se])};let F=W[Br].bind(null,!1);j[se]=e,m?U(m,[W,F]):F()},clone(W){let ce=Aa(W,t,n,i);return ce.afterLeave=()=>{J.afterLeave&&J.afterLeave()},ce.delayLeave=(se,pe,F)=>{J.delayLeave?J.delayLeave(se,pe,F):F()},ce.delayedLeave=()=>{J.delayedLeave&&J.delayedLeave()},ce}};return J}function m0(e){if(np(e))return e=Ii(e),e.children=null,e}function Zd(e){if(!np(e))return tp(e.type)&&e.children?vS(e.children):e;if(e.component)return e.component.subTree;let{shapeFlag:t,children:n}=e;if(n){if(t&16)return n[0];if(t&32&&Te(n.default))return n.default()}}function Sn(e,t){if(e.shapeFlag&6&&e.component){e.transition=t;let n=e.component.subTree;Sn(tp(n.type)&&Zd(n)||n,t)}else if(e.shapeFlag&128){let n=e.suspense;if(n){let i=n.isHydrating?n.pendingBranch:n.activeBranch;i&&Sn(i,t.clone(i))}else e.ssContent.transition=t.clone(e.ssContent),e.ssFallback.transition=t.clone(e.ssFallback)}else if(e.transition=t,e.type===ge&&xe(e.children)){let n=AS(e.children,!1);n&&Sn(n,t)}}function rp(e,t=!1,n){let i=[],r=0;for(let o=0;o<e.length;o++){let a=e[o],s=n==null?a.key:String(n)+String(a.key!=null?a.key:o);a.type===ge?(a.patchFlag&128&&r++,i=i.concat(rp(a.children,t,s))):(t||a.type!==Ft)&&i.push(s!=null?Ii(a,{key:s}):a)}if(r>1)for(let o=0;o<i.length;o++)i[o].patchFlag=-2;return i}function Ol(e){if(e.component)return Ol(e.component.subTree);if(e.type===ge){let t=xe(e.children)&&AS(e.children,!1);return t?Ol(t):void 0}if(e.type!==Ft)return e}function Pe(e,t){return Te(e)?it({name:e.name},t,{setup:e}):e}function wS(e){e.ids=[e.ids[0]+e.ids[2]+++"-",0,0]}function T0(e){let t=Ua(),n=We(null);if(t){let r=t.refs===Ze?t.refs={}:t.refs;Object.defineProperty(r,e,{enumerable:!0,get:()=>n.value,set:o=>n.value=o})}return n}function H$(e,t){let n;return!!((n=Object.getOwnPropertyDescriptor(e,t))&&!n.configurable)}function Nl(e,t,n,i,r=!1){if(xe(e)){e.forEach((v,k)=>Nl(v,t&&(xe(t)?t[k]:t),n,i,r));return}if(Na(i)&&!r){i.shapeFlag&512&&i.type.__asyncResolved&&i.component.subTree.component&&Nl(e,t,n,i.component.subTree);return}let o=i.shapeFlag&4?op(i.component):i.el,a=r?null:o,{i:s,r:l}=e,u=t&&t.r,d=s.refs===Ze?s.refs={}:s.refs,p=s.setupState,m=He(p),f=p===Ze?Fb:v=>H$(d,v)?!1:Ke(m,v),h=(v,k)=>!(k&&H$(d,k));if(u!=null&&u!==l){if(K$(t),pt(u))d[u]=null,f(u)&&(p[u]=null);else if(Vt(u)){let v=t;h(u,v.k)&&(u.value=null),v.k&&(d[v.k]=null)}}if(Te(l))jl(l,s,12,[a,d]);else{let v=pt(l),k=Vt(l);if(v||k){let T=()=>{if(e.f){let S=v?f(l)?p[l]:d[l]:h(l)||!e.k?l.value:d[e.k];if(r)xe(S)&&dl(S,o);else if(xe(S))S.includes(o)||S.push(o);else if(v)d[l]=[o],f(l)&&(p[l]=d[l]);else{let z=[o];h(l,e.k)&&(l.value=z),e.k&&(d[e.k]=z)}}else v?(d[l]=a,f(l)&&(p[l]=a)):k&&(h(l,e.k)&&(l.value=a),e.k&&(d[e.k]=a))};if(a){let S=()=>{T(),Hd.delete(e)};S.id=-1,Hd.set(e,S),rr(S,n)}else K$(e),T()}}}function K$(e){let t=Hd.get(e);t&&(t.flags|=8,Hd.delete(e))}function ZA(e,t){kS(e,"a",t)}function HA(e,t){kS(e,"da",t)}function kS(e,t,n=nr){let i=e.__wdc||(e.__wdc=()=>{let r=n;for(;r;){if(r.isDeactivated)return;r=r.parent}return e()});if(Dl(t,i,n),n){let r=n.parent;for(;r&&r.parent;)np(r.parent.vnode)&&KA(i,t,n,r),r=r.parent}}function KA(e,t,n,i){let r=Dl(t,e,i,!0),o=Dl("um",()=>dl(i[t],r),n);o.flags=16}function Dl(e,t,n=nr,i=!1){if(n){let r=n[e]||(n[e]=[]),o=t.__weh||(t.__weh=(...a)=>{on();let s=Ll(n),l=Dr(t,n,e,a);return s(),an(),l});return i?r.unshift(o):r.push(o),o}}function YA(e,t=nr){Dl("ec",e,t)}function SS(e){return pt(e)?XA(_S,e,!1)||e:e||$S}function XA(e,t,n=!0,i=!1){let r=Yt||nr;if(r){let o=r.type;if(e===_S){let s=OO(o,!1);if(s&&(s===t||s===Ct(t)||s===Xi(Ct(t))))return o}let a=W$(r[e]||o[e],t)||W$(r.appContext[e],t);return!a&&i?o:a}}function W$(e,t){return e&&(e[t]||e[Ct(t)]||e[Xi(Ct(t))])}function st(e,t,n,i){let r,o=n&&n[i],a=xe(e);if(a||pt(e)){let s=a&&wn(e),l=!1,u=!1;s&&(l=!$r(e),u=Vr(e),e=xl(e)),r=new Array(e.length);for(let d=0,p=e.length;d<p;d++)r[d]=t(l?u?Bn(Ar(e[d])):Ar(e[d]):e[d],d,void 0,o&&o[d])}else if(typeof e=="number")if(!Number.isInteger(e)||e<0)r=[];else{r=new Array(e);for(let s=0;s<e;s++)r[s]=t(s+1,s,void 0,o&&o[s])}else if(qe(e))if(e[Symbol.iterator])r=Array.from(e,(s,l)=>t(s,l,void 0,o&&o[l]));else{let s=Object.keys(e);r=new Array(s.length);for(let l=0,u=s.length;l<u;l++){let d=s[l];r[l]=t(e[d],d,l,o&&o[l])}}else r=[];return n&&(n[i]=r),r}function Pa(e,t){for(let n=0;n<t.length;n++){let i=t[n];if(xe(i))for(let r=0;r<i.length;r++)e[i[r].name]=i[r].fn;else i&&(e[i.name]=i.key?(...r)=>{let o=i.fn(...r);return o&&(o.key=i.key),o}:i.fn)}return e}function zt(e,t,n,i,r,o){if(n==null&&(n={}),Yt.ce||Yt.parent&&Na(Yt.parent)&&Yt.parent.ce){let u=o!=null&&n.key==null?it({},n,{key:o}):n,d=Object.keys(u).length>0;return t!=="default"&&(u.name=t),w(),Fe(ge,null,[be("slot",u,i&&i())],d?-2:64)}let a=e[t];a&&a._c&&(a._d=!1);let s=Hn.length;w();let l;try{let u=a&&IS(a(n)),d=n.key||o||u&&u.key;l=Fe(ge,{key:(d&&!_r(d)?d:`_${t}`)+(!u&&i?"_fb":"")},u||(i?i():[]),u&&e._===1?64:-2)}catch(u){for(let d=Hn.length;d>s;d--)P0();throw u}finally{a&&a._c&&(a._d=!0)}return!r&&l.scopeId&&(l.slotScopeIds=[l.scopeId+"-s"]),l}function IS(e){return e.some(t=>Oa(t)?!(t.type===Ft||t.type===ge&&!IS(t.children)):!0)?e:null}function Kd(e){return xe(e)?e.reduce((t,n)=>(t[n]=null,t),{}):e}function C0(e,t){return!e||!t?e||t:xe(e)&&xe(t)?e.concat(t):it({},Kd(e),Kd(t))}function eO(e){let t=z0(e),n=e.proxy,i=e.ctx;k0=!1,t.beforeCreate&&q$(t.beforeCreate,e,"bc");let{data:r,computed:o,methods:a,watch:s,provide:l,inject:u,created:d,beforeMount:p,mounted:m,beforeUpdate:f,updated:h,activated:v,deactivated:k,beforeDestroy:T,beforeUnmount:S,destroyed:z,unmounted:j,render:O,renderTracked:U,renderTriggered:J,errorCaptured:W,serverPrefetch:ce,expose:se,inheritAttrs:pe,components:F,directives:ue,filters:Je}=t;if(u&&tO(u,i,null),a)for(let Re in a){let Be=a[Re];Te(Be)&&(i[Re]=Be.bind(n))}if(r){let Re=r.call(n,n);qe(Re)&&(e.data=_l(Re))}if(k0=!0,o)for(let Re in o){let Be=o[Re],Mt=Te(Be)?Be.bind(n,n):Te(Be.get)?Be.get.bind(n,n):ur,Er=!Te(Be)&&Te(Be.set)?Be.set.bind(n):ur,mr=R({get:Mt,set:Er});Object.defineProperty(i,Re,{enumerable:!0,configurable:!0,get:()=>mr.value,set:gt=>mr.value=gt})}if(s)for(let Re in s)ES(s[Re],i,n,Re);if(l){let Re=Te(l)?l.call(n):l;Reflect.ownKeys(Re).forEach(Be=>{PA(Be,Re[Be])})}d&&q$(d,e,"c");function ft(Re,Be){xe(Be)?Be.forEach(Mt=>Re(Mt.bind(n))):Be&&Re(Be.bind(n))}if(ft(WA,p),ft(Ut,m),ft(xS,f),ft(N0,h),ft(ZA,v),ft(HA,k),ft(YA,W),ft(JA,U),ft(GA,J),ft(Da,S),ft(Wn,j),ft(qA,ce),xe(se))if(se.length){let Re=e.exposed||(e.exposed={});se.forEach(Be=>{Object.defineProperty(Re,Be,{get:()=>n[Be],set:Mt=>n[Be]=Mt,enumerable:!0})})}else e.exposed||(e.exposed={});O&&e.render===ur&&(e.render=O),pe!=null&&(e.inheritAttrs=pe),F&&(e.components=F),ue&&(e.directives=ue),ce&&wS(e)}function tO(e,t,n=ur){xe(e)&&(e=x0(e));for(let i in e){let r=e[i],o;qe(r)?"default"in r?o=Ld(r.from||i,r.default,!0):o=Ld(r.from||i):o=Ld(r),Vt(o)?Object.defineProperty(t,i,{enumerable:!0,configurable:!0,get:()=>o.value,set:a=>o.value=a}):t[i]=o}}function q$(e,t,n){Dr(xe(e)?e.map(i=>i.bind(t.proxy)):e.bind(t.proxy),t,n)}function ES(e,t,n,i){let r=i.includes(".")?fS(n,i):()=>n[i];if(pt(e)){let o=t[e];Te(o)&&mt(r,o)}else if(Te(e))mt(r,e.bind(n));else if(qe(e))if(xe(e))e.forEach(o=>ES(o,t,n,i));else{let o=Te(e.handler)?e.handler.bind(n):t[e.handler];Te(o)&&mt(r,o,e)}}function z0(e){let t=e.type,{mixins:n,extends:i}=t,{mixins:r,optionsCache:o,config:{optionMergeStrategies:a}}=e.appContext,s=o.get(t),l;return s?l=s:!r.length&&!n&&!i?l=t:(l={},r.length&&r.forEach(u=>Wd(l,u,a,!0)),Wd(l,t,a)),qe(t)&&o.set(t,l),l}function Wd(e,t,n,i=!1){let{mixins:r,extends:o}=t;o&&Wd(e,o,n,!0),r&&r.forEach(a=>Wd(e,a,n,!0));for(let a in t)if(!(i&&a==="expose")){let s=rO[a]||n&&n[a];e[a]=s?s(e[a],t[a]):t[a]}return e}function G$(e,t){return t?e?function(){return it(Te(e)?e.call(this,this):e,Te(t)?t.call(this,this):t)}:t:e}function nO(e,t){return Tl(x0(e),x0(t))}function x0(e){if(xe(e)){let t={};for(let n=0;n<e.length;n++)t[e[n]]=e[n];return t}return e}function dr(e,t){return e?[...new Set([].concat(e,t))]:t}function Tl(e,t){return e?it(Object.create(null),e,t):t}function J$(e,t){return e?xe(e)&&xe(t)?[...new Set([...e,...t])]:it(Object.create(null),Kd(e),Kd(t??{})):t}function iO(e,t){if(!e)return t;if(!t)return e;let n=it(Object.create(null),e);for(let i in t)n[i]=dr(e[i],t[i]);return n}function TS(){return{app:null,config:{isNativeTag:Fb,performance:!1,globalProperties:{},optionMergeStrategies:{},errorHandler:void 0,warnHandler:void 0,compilerOptions:{}},mixins:[],components:{},directives:{},provides:Object.create(null),optionsCache:new WeakMap,propsCache:new WeakMap,emitsCache:new WeakMap}}function aO(e,t){return function(i,r=null){Te(i)||(i=it({},i)),r!=null&&!qe(r)&&(r=null);let o=TS(),a=new WeakSet,s=[],l=!1,u=o.app={_uid:oO++,_component:i,_props:r,_container:null,_context:o,_instance:null,version:iS,get config(){return o.config},set config(d){},use(d,...p){return a.has(d)||(d&&Te(d.install)?(a.add(d),d.install(u,...p)):Te(d)&&(a.add(d),d(u,...p))),u},mixin(d){return __VUE_OPTIONS_API__&&(o.mixins.includes(d)||o.mixins.push(d)),u},component(d,p){return p?(o.components[d]=p,u):o.components[d]},directive(d,p){return p?(o.directives[d]=p,u):o.directives[d]},mount(d,p,m){if(!l){let f=u._ceVNode||be(i,r);return f.appContext=o,m===!0?m="svg":m===!1&&(m=void 0),p&&t?t(f,d):e(f,d,m),l=!0,u._container=d,d.__vue_app__=u,__VUE_PROD_DEVTOOLS__&&(u._instance=f.component,NA(u,iS)),op(f.component)}},onUnmount(d){s.push(d)},unmount(){l&&(Dr(s,u._instance,16),e(null,u._container),__VUE_PROD_DEVTOOLS__&&(u._instance=null,CA(u)),delete u._container.__vue_app__)},provide(d,p){return o.provides[d]=p,u},runWithContext(d){let p=Ca;Ca=u;try{return d()}finally{Ca=p}}};return u}}function NS(e,t,n=Ze){let i=Ua(),r=Ct(t),o=rn(t),a=CS(e,r),s=u0((l,u)=>{let d,p=Ze,m;return jA(()=>{let f=e[r];Rt(d,f)&&(d=f,u())}),{get(){return l(),n.get?n.get(d):d},set(f){let h=n.set?n.set(f):f;if(!Rt(h,d)&&!(p!==Ze&&Rt(f,p)))return;let v=i.vnode.props,k=!!(v&&(t in v||r in v||o in v)&&(`onUpdate:${t}`in v||`onUpdate:${r}`in v||`onUpdate:${o}`in v));k||(d=f,u()),i.emit(`update:${t}`,h),Rt(f,p)&&(Rt(f,h)&&!Rt(h,m)||k&&p!==Ze&&!Rt(h,d))&&u(),p=f,m=h}}});return s[Symbol.iterator]=()=>{let l=0;return{next(){return l<2?{value:l++?a||Ze:s,done:!1}:{done:!0}}}},s}function sO(e,t,...n){if(e.isUnmounted)return;let i=e.vnode.props||Ze,r=n,o=t.startsWith("update:"),a=o&&CS(i,t.slice(7));a&&(a.trim&&(r=n.map(d=>pt(d)?d.trim():d)),a.number&&(r=r.map(fl))),__VUE_PROD_DEVTOOLS__&&DA(e,t,r);let s,l=i[s=ml(t)]||i[s=ml(Ct(t))];!l&&o&&(l=i[s=ml(rn(t))]),l&&Dr(l,e,6,r);let u=i[s+"Once"];if(u){if(!e.emitted)e.emitted={};else if(e.emitted[s])return;e.emitted[s]=!0,Dr(u,e,6,r)}}function zS(e,t,n=!1){let i=__VUE_OPTIONS_API__&&n?lO:t.emitsCache,r=i.get(e);if(r!==void 0)return r;let o=e.emits,a={},s=!1;if(__VUE_OPTIONS_API__&&!Te(e)){let l=u=>{let d=zS(u,t,!0);d&&(s=!0,it(a,d))};!n&&t.mixins.length&&t.mixins.forEach(l),e.extends&&l(e.extends),e.mixins&&e.mixins.forEach(l)}return!o&&!s?(qe(e)&&i.set(e,null),null):(xe(o)?o.forEach(l=>a[l]=null):it(a,o),qe(e)&&i.set(e,a),a)}function ip(e,t){return!e||!va(t)?!1:(t=t.slice(2),t=t==="Once"?t:t.replace(/Once$/,""),Ke(e,t[0].toLowerCase()+t.slice(1))||Ke(e,rn(t))||Ke(e,t))}function h0(e){let{type:t,vnode:n,proxy:i,withProxy:r,propsOptions:[o],slots:a,attrs:s,emit:l,render:u,renderCache:d,props:p,data:m,setupState:f,ctx:h,inheritAttrs:v}=e,k=Bd(e),T,S;try{if(n.shapeFlag&4){let O=r||i,U=O;T=_n(u.call(U,O,d,p,f,m,h)),S=s}else{let O=t;T=_n(O.length>1?O(p,{attrs:s,slots:a,emit:l}):O(p,null)),S=t.props?s:cO(s)}}catch(O){Hn.length=0,Yd(O,e,1),T=be(Ft)}let z=T,j;if(S&&v!==!1){let O=Object.keys(S),{shapeFlag:U}=z;O.length&&U&7&&(o&&O.some(ba)&&(S=uO(S,o)),z=Ii(z,S,!1,!0))}if(n.dirs&&(z=Ii(z,null,!1,!0),z.dirs=z.dirs?z.dirs.concat(n.dirs):n.dirs),n.transition){let O=tp(z.type)&&Zd(z)||z;Sn(O,n.transition)}return T=z,Bd(k),T}function AS(e,t=!0){let n;for(let i=0;i<e.length;i++){let r=e[i];if(Oa(r)){if(r.type!==Ft||r.children==="v-if"){if(n)return;n=r}}else return}return n}function dO(e,t,n){let{props:i,children:r,component:o}=e,{props:a,children:s,patchFlag:l}=t,u=o.emitsOptions;if(t.dirs||t.transition)return!0;if(n&&l>=0){if(l&1024)return!0;if(l&16)return i?Y$(i,a,u):!!a;if(l&8){let d=t.dynamicProps;for(let p=0;p<d.length;p++){let m=d[p];if(OS(a,i,m)&&!ip(u,m))return!0}}}else return(r||s)&&(!s||!s.$stable)?!0:i===a?!1:i?a?Y$(i,a,u):!0:!!a;return!1}function Y$(e,t,n){let i=Object.keys(t);if(i.length!==Object.keys(e).length)return!0;for(let r=0;r<i.length;r++){let o=i[r];if(!Ke(e,o)||OS(t,e,o)&&!ip(n,o))return!0}return!1}function OS(e,t,n){let i=e[n],r=t[n];return n==="style"&&qe(i)&&qe(r)?!_a(i,r):i!==r}function pO({vnode:e,parent:t,suspense:n},i){for(;t;){let r=t.subTree;if(r.suspense&&r.suspense.activeBranch===e&&(r.suspense.vnode.el=r.el=i,e=r),r===e)(e=t.vnode).el=i,t=t.parent;else break}n&&n.activeBranch===e&&(n.vnode.el=i)}function mO(e,t,n,i=!1){let r={},o=PS();e.propsDefaults=Object.create(null),US(e,t,r,o);for(let a in e.propsOptions[0])a in r||(r[a]=void 0);n?e.props=i?r:Ea(r):e.type.props?e.props=r:e.props=o,e.attrs=o}function fO(e,t,n,i){let{props:r,attrs:o,vnode:{patchFlag:a}}=e,s=He(r),[l]=e.propsOptions,u=!1;if((i||a>0)&&!(a&16)){if(a&8){let d=e.vnode.dynamicProps;for(let p=0;p<d.length;p++){let m=d[p];if(ip(e.emitsOptions,m))continue;let f=t[m];if(l)if(Ke(o,m))f!==o[m]&&(o[m]=f,u=!0);else{let h=Ct(m);r[h]=_0(l,s,h,f,e,!1)}else f!==o[m]&&(o[m]=f,u=!0)}}}else{US(e,t,r,o)&&(u=!0);let d;for(let p in s)(!t||!Ke(t,p)&&((d=rn(p))===p||!Ke(t,d)))&&(l?n&&(n[p]!==void 0||n[d]!==void 0)&&(r[p]=_0(l,s,p,void 0,e,!0)):delete r[p]);if(o!==s)for(let p in o)(!t||!Ke(t,p))&&(delete o[p],u=!0)}u&&bn(e.attrs,"set","")}function US(e,t,n,i){let[r,o]=e.propsOptions,a=!1,s;if(t)for(let l in t){if(ya(l))continue;let u=t[l],d;r&&Ke(r,d=Ct(l))?!o||!o.includes(d)?n[d]=u:(s||(s={}))[d]=u:ip(e.emitsOptions,l)||(!(l in i)||u!==i[l])&&(i[l]=u,a=!0)}if(o){let l=He(n),u=s||Ze;for(let d=0;d<o.length;d++){let p=o[d];n[p]=_0(r,l,p,u[p],e,!Ke(u,p))}}return a}function _0(e,t,n,i,r,o){let a=e[n];if(a!=null){let s=Ke(a,"default");if(s&&i===void 0){let l=a.default;if(a.type!==Function&&!a.skipFactory&&Te(l)){let{propsDefaults:u}=r;if(n in u)i=u[n];else{let d=Ll(r);i=u[n]=l.call(null,t),d()}}else i=l;r.ce&&r.ce._setProp(n,i)}a[0]&&(o&&!s?i=!1:a[1]&&(i===""||i===rn(n))&&(i=!0))}return i}function jS(e,t,n=!1){let i=__VUE_OPTIONS_API__&&n?hO:t.propsCache,r=i.get(e);if(r)return r;let o=e.props,a={},s=[],l=!1;if(__VUE_OPTIONS_API__&&!Te(e)){let d=p=>{l=!0;let[m,f]=jS(p,t,!0);it(a,m),f&&s.push(...f)};!n&&t.mixins.length&&t.mixins.forEach(d),e.extends&&d(e.extends),e.mixins&&e.mixins.forEach(d)}if(!o&&!l)return qe(e)&&i.set(e,xi),xi;if(xe(o))for(let d=0;d<o.length;d++){let p=Ct(o[d]);X$(p)&&(a[p]=Ze)}else if(o)for(let d in o){let p=Ct(d);if(X$(p)){let m=o[d],f=a[p]=xe(m)||Te(m)?{type:m}:it({},m),h=f.type,v=!1,k=!0;if(xe(h))for(let T=0;T<h.length;++T){let S=h[T],z=Te(S)&&S.name;if(z==="Boolean"){v=!0;break}else z==="String"&&(k=!1)}else v=Te(h)&&h.name==="Boolean";f[0]=v,f[1]=k,(v||Ke(f,"default"))&&s.push(p)}}let u=[a,s];return qe(e)&&i.set(e,u),u}function X$(e){return e[0]!=="$"&&!ya(e)}function yO(){let e=[];typeof __VUE_OPTIONS_API__!="boolean"&&(_i().__VUE_OPTIONS_API__=!0),typeof __VUE_PROD_DEVTOOLS__!="boolean"&&(_i().__VUE_PROD_DEVTOOLS__=!1),typeof __VUE_PROD_HYDRATION_MISMATCH_DETAILS__!="boolean"&&(_i().__VUE_PROD_HYDRATION_MISMATCH_DETAILS__=!1)}function FS(e){return wO(e)}function wO(e,t){yO();let n=_i();n.__VUE__=!0,__VUE_PROD_DEVTOOLS__&&dS(n.__VUE_DEVTOOLS_GLOBAL_HOOK__,n);let{insert:i,remove:r,patchProp:o,createElement:a,createText:s,createComment:l,setText:u,setElementText:d,parentNode:p,nextSibling:m,setScopeId:f=ur,insertStaticContent:h}=e,v=(x,I,M,B=null,X=null,_=null,D=void 0,y=null,P=!!I.dynamicChildren)=>{if(x===I)return;x&&!io(x,I)&&(B=er(x),yt(x,X,_,!0),x=null),I.patchFlag===-2&&(P=!1,I.dynamicChildren=null),I.dynamicChildren&&x&&x.dynamicChildren&&x.dynamicChildren.hasOnce&&(I.dynamicChildren===xi&&(I.dynamicChildren=[]),I.dynamicChildren.hasOnce=!0);let{type:E,ref:Y,shapeFlag:ie}=I;switch(E){case Ml:k(x,I,M,B);break;case Ft:T(x,I,M,B);break;case za:x==null&&S(I,M,B,D);break;case ge:ue(x,I,M,B,X,_,D,y,P);break;default:ie&1?U(x,I,M,B,X,_,D,y,P):ie&6?Je(x,I,M,B,X,_,D,y,P):(ie&64||ie&128)&&E.process(x,I,M,B,X,_,D,y,P,fr)}Y!=null&&X?Nl(Y,x&&x.ref,_,I||x,!I):Y==null&&x&&x.ref!=null&&Nl(x.ref,null,_,x,!0)},k=(x,I,M,B)=>{if(x==null)i(I.el=s(I.children),M,B);else{let X=I.el=x.el;I.children!==x.children&&u(X,I.children)}},T=(x,I,M,B)=>{x==null?i(I.el=l(I.children||""),M,B):I.el=x.el},S=(x,I,M,B)=>{[x.el,x.anchor]=h(x.children,I,M,B,x.el,x.anchor)},z=(x,I,M,B)=>{if(I.children!==x.children){let X=m(x.anchor);O(x),[I.el,I.anchor]=h(I.children,M,X,B)}else I.el=x.el,I.anchor=x.anchor},j=({el:x,anchor:I},M,B)=>{let X;for(;x&&x!==I;)X=m(x),i(x,M,B),x=X;i(I,M,B)},O=({el:x,anchor:I})=>{let M;for(;x&&x!==I;)M=m(x),r(x),x=M;r(I)},U=(x,I,M,B,X,_,D,y,P)=>{if(I.type==="svg"?D="svg":I.type==="math"&&(D="mathml"),x==null)J(I,M,B,X,_,D,y,P);else{let E=x.el&&x.el._isVueCE?x.el:null;try{E&&E._beginPatch(),se(x,I,X,_,D,y,P)}finally{E&&E._endPatch()}}},J=(x,I,M,B,X,_,D,y)=>{let P,E,{props:Y,shapeFlag:ie,transition:fe,dirs:ve}=x;if(P=x.el=a(x.type,_,Y&&Y.is,Y),ie&8?d(P,x.children):ie&16&&ce(x.children,P,null,B,X,g0(x,_),D,y),ve&&to(x,null,B,"created"),W(P,x,x.scopeId,D,B),Y){for(let ye in Y)ye!=="value"&&!ya(ye)&&o(P,ye,null,Y[ye],_,B);"value"in Y&&o(P,"value",null,Y.value,_),(E=Y.onVnodeBeforeMount)&&kn(E,B,x)}__VUE_PROD_DEVTOOLS__&&(ka(P,"__vnode",x,!0),ka(P,"__vueParentComponent",B,!0)),ve&&to(x,null,B,"beforeMount");let we=kO(X,fe);we?fe.beforeEnter(P):fe&&!fe.persisted&&(P[_O]=!0),i(P,I,M),((E=Y&&Y.onVnodeMounted)||we||ve)&&rr(()=>{let Ne;E&&kn(E,B,x),we&&fe.enter(P),ve&&to(x,null,B,"mounted")},X)},W=(x,I,M,B,X)=>{if(M&&f(x,M),B)for(let _=0;_<B.length;_++)f(x,B[_]);if(X){let _=X.subTree;if(I===_||ZS(_.type)&&(_.ssContent===I||_.ssFallback===I)){let D=X.vnode;W(x,D,D.scopeId,D.slotScopeIds,X.parent)}}},ce=(x,I,M,B,X,_,D,y,P=0)=>{for(let E=P;E<x.length;E++){let Y=x[E]=y?Zn(x[E]):_n(x[E]);v(null,Y,I,M,B,X,_,D,y)}},se=(x,I,M,B,X,_,D)=>{let y=I.el=x.el;__VUE_PROD_DEVTOOLS__&&(y.__vnode=I);let{patchFlag:P,dynamicChildren:E,dirs:Y}=I;P|=x.patchFlag&16;let ie=x.props||Ze,fe=I.props||Ze,ve;if(M&&ro(M,!1),(ve=fe.onVnodeBeforeUpdate)&&kn(ve,M,I,x),Y&&to(I,x,M,"beforeUpdate"),M&&ro(M,!0),E&&(!x.dynamicChildren||x.dynamicChildren.length!==E.length)&&(P=0,D=!1,E=null),(ie.innerHTML&&fe.innerHTML==null||ie.textContent&&fe.textContent==null)&&d(y,""),E?pe(x.dynamicChildren,E,y,M,B,g0(I,X),_):D||Mt(x,I,y,null,M,B,g0(I,X),_,!1),P>0){if(P&16)F(y,ie,fe,M,X);else if(P&2&&ie.class!==fe.class&&o(y,"class",null,fe.class,X),P&4&&o(y,"style",ie.style,fe.style,X),P&8){let we=I.dynamicProps;for(let ye=0;ye<we.length;ye++){let Ne=we[ye],Me=ie[Ne],Xe=fe[Ne];(Xe!==Me||Ne==="value")&&o(y,Ne,Me,Xe,X,M)}}P&1&&x.children!==I.children&&d(y,I.children)}else!D&&E==null&&F(y,ie,fe,M,X);((ve=fe.onVnodeUpdated)||Y)&&rr(()=>{ve&&kn(ve,M,I,x),Y&&to(I,x,M,"updated")},B)},pe=(x,I,M,B,X,_,D)=>{for(let y=0;y<I.length;y++){let P=x[y],E=I[y],Y=P.el||zl(P),ie=Y&&(P.type===ge||!io(P,E)||P.shapeFlag&198)?p(Y):M;v(P,E,ie,null,B,X,_,D,!0)}},F=(x,I,M,B,X)=>{if(I!==M){if(I!==Ze)for(let _ in I)!ya(_)&&!(_ in M)&&o(x,_,I[_],null,X,B);for(let _ in M){if(ya(_))continue;let D=M[_],y=I[_];D!==y&&_!=="value"&&o(x,_,y,D,X,B)}"value"in M&&o(x,"value",I.value,M.value,X)}},ue=(x,I,M,B,X,_,D,y,P)=>{let E=I.el=x?x.el:s(""),Y=I.anchor=x?x.anchor:s(""),{patchFlag:ie,dynamicChildren:fe,slotScopeIds:ve}=I;ve&&(y=y?y.concat(ve):ve),x==null?(i(E,M,B),i(Y,M,B),ce(I.children||[],M,Y,X,_,D,y,P)):ie>0&&ie&64&&fe&&x.dynamicChildren&&x.dynamicChildren.length===fe.length?(pe(x.dynamicChildren,fe,M,X,_,D,y),(I.key!=null||X&&I===X.subTree)&&D0(x,I,!0)):Mt(x,I,M,Y,X,_,D,y,P)},Je=(x,I,M,B,X,_,D,y,P)=>{I.slotScopeIds=y,x==null?I.shapeFlag&512?X.ctx.activate(I,M,B,D,P):ct(I,M,B,X,_,D,P):ft(x,I,P)},ct=(x,I,M,B,X,_,D)=>{let y=x.component=TO(x,B,X);if(np(x)&&(y.ctx.renderer=fr),NO(y,!1,D),y.asyncDep){if(X&&X.registerDep(y,Re,D,_),!x.el){let P=y.subTree=be(Ft);T(null,P,I,M),x.placeholder=P.el}}else Re(y,x,I,M,X,_,D)},ft=(x,I,M)=>{let B=I.component=x.component;if(dO(x,I,M))if(B.asyncDep&&!B.asyncResolved){I.el=x.el,I.placeholder=x.placeholder,Be(B,I,M);return}else B.next=I,B.update();else I.el=x.el,I.placeholder=x.placeholder,B.vnode=I},Re=(x,I,M,B,X,_,D)=>{let y=()=>{if(x.isMounted){let{next:ie,bu:fe,u:ve,parent:we,vnode:ye}=x;{let $t=BS(x);if($t){ie&&(ie.el=ye.el,Be(x,ie,D)),$t.asyncDep.then(()=>{let St=()=>{x.job.flags&8||(X&&X.pendingBranch?rr(St,X):E())};St.flags=48,rr(St,X)});return}}let Ne=ie,Me;ro(x,!1),ie?(ie.el=ye.el,Be(x,ie,D)):ie=ye,fe&&wa(fe),(Me=ie.props&&ie.props.onVnodeBeforeUpdate)&&kn(Me,we,ie,ye),ro(x,!0);let Xe=h0(x),wt=x.subTree;x.subTree=Xe,v(wt,Xe,p(wt.el||zl(wt)),er(wt),x,X,_),ie.el=Xe.el,Ne===null&&pO(x,Xe.el),ve&&rr(ve,X),(Me=ie.props&&ie.props.onVnodeUpdated)&&rr(()=>kn(Me,we,ie,ye),X),__VUE_PROD_DEVTOOLS__&&pS(x)}else{let ie,{el:fe,props:ve}=I,{bm:we,m:ye,parent:Ne,root:Me,type:Xe}=x,wt=Na(I);if(ro(x,!1),we&&wa(we),!wt&&(ie=ve&&ve.onVnodeBeforeMount)&&kn(ie,Ne,I),ro(x,!0),fe&&hr){let $t=()=>{x.subTree=h0(x),hr(fe,x.subTree,x,X,null)};wt&&Xe.__asyncHydrate?Xe.__asyncHydrate(fe,x,$t):$t()}else{Me.ce&&Me.ce._hasShadowRoot()&&Me.ce._injectChildStyle(Xe,x.parent?x.parent.type:void 0);let $t=x.subTree=h0(x);v(null,$t,M,B,x,X,_),I.el=$t.el}if(ye&&rr(ye,X),!wt&&(ie=ve&&ve.onVnodeMounted)){let $t=I;rr(()=>kn(ie,Ne,$t),X)}(I.shapeFlag&256||Ne&&Na(Ne.vnode)&&Ne.vnode.shapeFlag&256)&&x.a&&rr(x.a,X),x.isMounted=!0,__VUE_PROD_DEVTOOLS__&&zA(x),I=M=B=null}};x.scope.on();let P=x.effect=new Sa(y);x.scope.off();let E=x.update=P.run.bind(P),Y=x.job=P.runIfDirty.bind(P);Y.i=x,Y.id=x.uid,P.scheduler=()=>Xd(Y),ro(x,!0),E()},Be=(x,I,M)=>{I.component=x;let B=x.vnode.props;x.vnode=I,x.next=null,fO(x,I.props,B,M),bO(x,I.children,M),on(),lS(x),an()},Mt=(x,I,M,B,X,_,D,y,P=!1)=>{let E=x&&x.children,Y=x?x.shapeFlag:0,ie=I.children,{patchFlag:fe,shapeFlag:ve}=I;if(fe>0){if(fe&128){mr(E,ie,M,B,X,_,D,y,P);return}else if(fe&256){Er(E,ie,M,B,X,_,D,y,P);return}}ve&8?(Y&16&&Ht(E,X,_),ie!==E&&d(M,ie)):Y&16?ve&16?mr(E,ie,M,B,X,_,D,y,P):Ht(E,X,_,!0):(Y&8&&d(M,""),ve&16&&ce(ie,M,B,X,_,D,y,P))},Er=(x,I,M,B,X,_,D,y,P)=>{x=x||xi,I=I||xi;let E=x.length,Y=I.length,ie=Math.min(E,Y),fe;for(fe=0;fe<ie;fe++){let ve=I[fe]=P?Zn(I[fe]):_n(I[fe]);v(x[fe],ve,M,null,X,_,D,y,P)}E>Y?Ht(x,X,_,!0,!1,ie):ce(I,M,B,X,_,D,y,P,ie)},mr=(x,I,M,B,X,_,D,y,P)=>{let E=0,Y=I.length,ie=x.length-1,fe=Y-1;for(;E<=ie&&E<=fe;){let ve=x[E],we=I[E]=P?Zn(I[E]):_n(I[E]);if(io(ve,we))v(ve,we,M,null,X,_,D,y,P);else break;E++}for(;E<=ie&&E<=fe;){let ve=x[ie],we=I[fe]=P?Zn(I[fe]):_n(I[fe]);if(io(ve,we))v(ve,we,M,null,X,_,D,y,P);else break;ie--,fe--}if(E>ie){if(E<=fe){let ve=fe+1,we=ve<Y?I[ve].el:B;for(;E<=fe;)v(null,I[E]=P?Zn(I[E]):_n(I[E]),M,we,X,_,D,y,P),E++}}else if(E>fe)for(;E<=ie;)yt(x[E],X,_,!0),E++;else{let ve=E,we=E,ye=new Map;for(E=we;E<=fe;E++){let vt=I[E]=P?Zn(I[E]):_n(I[E]);vt.key!=null&&ye.set(vt.key,E)}let Ne,Me=0,Xe=fe-we+1,wt=!1,$t=0,St=new Array(Xe);for(E=0;E<Xe;E++)St[E]=0;for(E=ve;E<=ie;E++){let vt=x[E];if(Me>=Xe){yt(vt,X,_,!0);continue}let Nt;if(vt.key!=null)Nt=ye.get(vt.key);else for(Ne=we;Ne<=fe;Ne++)if(St[Ne-we]===0&&io(vt,I[Ne])){Nt=Ne;break}Nt===void 0?yt(vt,X,_,!0):(St[Nt-we]=E+1,Nt>=$t?$t=Nt:wt=!0,v(vt,I[Nt],M,null,X,_,D,y,P),Me++)}let Kt=wt?xO(St):xi;for(Ne=Kt.length-1,E=Xe-1;E>=0;E--){let vt=we+E,Nt=I[vt],Gr=I[vt+1],$e=vt+1<Y?Gr.el||zl(Gr):B;St[E]===0?v(null,Nt,M,$e,X,_,D,y,P):wt&&(Ne<0||E!==Kt[Ne]?gt(Nt,M,$e,2):Ne--)}}},gt=(x,I,M,B,X=null)=>{let{el:_,type:D,transition:y,children:P,shapeFlag:E}=x;if(E&6){gt(x.component.subTree,I,M,B);return}if(E&128){x.suspense.move(I,M,B);return}if(E&64){D.move(x,I,M,fr);return}if(D===ge){i(_,I,M);for(let ie=0;ie<P.length;ie++)gt(P[ie],I,M,B);i(x.anchor,I,M);return}if(D===za){j(x,I,M);return}if(B!==2&&E&1&&y)if(B===0)y.persisted&&!_[Br]?i(_,I,M):(y.beforeEnter(_),i(_,I,M),rr(()=>y.enter(_),X));else{let{leave:ie,delayLeave:fe,afterLeave:ve}=y,we=()=>{x.ctx.isUnmounted?r(_):i(_,I,M)},ye=()=>{let Ne=_._isLeaving||!!_[Br];_._isLeaving&&_[Br](!0),y.persisted&&!Ne?we():ie(_,()=>{we(),ve&&ve()})};fe?fe(_,we,ye):ye()}else i(_,I,M)},yt=(x,I,M,B=!1,X=!1)=>{let{type:_,props:D,ref:y,children:P,dynamicChildren:E,shapeFlag:Y,patchFlag:ie,dirs:fe,cacheIndex:ve,memo:we}=x;if((ie===-2||E&&E.hasOnce)&&(X=!1),y!=null&&(on(),Nl(y,null,M,x,!0),an()),ve!=null&&(!x.ctx||x.ctx===I)&&(I.renderCache[ve]=void 0),Y&256&&I.ctx.deactivate(x))return;let ye=Y&1&&fe,Ne=!Na(x),Me;if(Ne&&(Me=D&&D.onVnodeBeforeUnmount)&&kn(Me,I,x),Y&6)Ye(x.component,M,B);else{if(Y&128){x.suspense.unmount(M,B);return}ye&&to(x,null,I,"beforeUnmount"),Y&64?x.type.remove(x,I,M,fr,B):E&&!E.hasOnce&&(_!==ge||ie>0&&ie&64)?Ht(E,I,M,!1,!0):(_===ge&&ie&384||!X&&Y&16)&&Ht(P,I,M),B&&Wr(x)}let Xe=we!=null&&ve==null;(Ne&&(Me=D&&D.onVnodeUnmounted)||ye||Xe)&&rr(()=>{Me&&kn(Me,I,x),ye&&to(x,null,I,"unmounted"),Xe&&(x.el=null)},M)},Wr=x=>{let{type:I,el:M,anchor:B,transition:X}=x,_=I===ge;if(_&&!X){Tt(M,B);return}if(I===za){O(x),X&&!X.persisted&&X.afterLeave&&X.afterLeave();return}let D=_?Ol(x):x,y=()=>{_?p(M)&&Tt(M,B):r(M),X&&!X.persisted&&X.afterLeave&&X.afterLeave()};if(D&&D.shapeFlag&1&&X&&!X.persisted){let{leave:P,delayLeave:E}=X,Y=D.el,ie=()=>P(Y,y);E?E(Y,y,ie):ie()}else y()},Tt=(x,I)=>{let M;for(;x!==I;)M=m(x),r(x),x=M;r(I)},Ye=(x,I,M)=>{let{bum:B,scope:X,job:_,subTree:D,um:y,m:P,a:E}=x;Q$(P),Q$(E),B&&wa(B),X.stop(),_?(_.flags|=8,yt(D,x,I,M)):D&&(D.transition=x.vnode.transition,yt(D,x,I,M)),y&&rr(y,I);let Y=()=>{x.isUnmounted=!0};Y.flags=16,rr(Y,I),__VUE_PROD_DEVTOOLS__&&OA(x)},Ht=(x,I,M,B=!1,X=!1,_=0)=>{for(let D=_;D<x.length;D++)yt(x[D],I,M,B,X)},er=x=>{if(x.shapeFlag&6)return er(x.component.subTree);if(x.shapeFlag&128)return x.suspense.next();let I=m(x.anchor||x.el),M=I&&I[hS];return M?m(M):I},Tr=(x,I,M)=>{let B=x&&I._vnode?void 0:x&&x.component?x.component.uid:EO();EA(()=>{x==null?I._vnode&&yt(I._vnode,null,null,!0):v(I._vnode||null,x,I,null,null,null,M),I._vnode=x},B)},fr={p:v,um:yt,m:gt,r:Wr,mt:ct,mc:ce,pc:Mt,pbc:pe,n:er,o:e},qr,hr;return t&&([qr,hr]=t(fr)),{render:Tr,hydrate:qr,createApp:aO(Tr,qr)}}function g0({type:e,props:t},n){return n==="svg"&&e==="foreignObject"||n==="mathml"&&e==="annotation-xml"&&t&&t.encoding&&t.encoding.includes("html")?void 0:n}function ro({effect:e,job:t},n){n?(e.flags|=32,t.flags|=4):(e.flags&=-33,t.flags&=-5)}function kO(e,t){return(!e||e&&!e.pendingBranch)&&t&&!t.persisted}function D0(e,t,n=!1){let i=e.children,r=t.children;if(xe(i)&&xe(r))for(let o=0;o<i.length;o++){let a=i[o],s=r[o];s.shapeFlag&1&&!s.dynamicChildren&&((s.patchFlag<=0||s.patchFlag===32)&&(s=r[o]=Zn(r[o]),s.el=a.el),!n&&s.patchFlag!==-2&&D0(a,s)),s.type===Ml&&(s.patchFlag===-1&&(s=r[o]=Zn(s)),s.el=a.el),s.type===Ft&&!s.el&&(s.el=a.el)}}function xO(e){let t=e.slice(),n=[0],i,r,o,a,s,l=e.length;for(i=0;i<l;i++){let u=e[i];if(u!==0){if(r=n[n.length-1],e[r]<u){t[i]=r,n.push(i);continue}for(o=0,a=n.length-1;o<a;)s=o+a>>1,e[n[s]]<u?o=s+1:a=s;u<e[n[o]]&&(o>0&&(t[i]=n[o-1]),n[o]=i)}}for(o=n.length,a=n[o-1];o-- >0;)n[o]=a,a=t[a];return n}function BS(e){let t=e.subTree.component;if(t)return t.asyncDep&&!t.asyncResolved?t:BS(t)}function Q$(e){if(e)for(let t=0;t<e.length;t++)e[t].flags|=8}function zl(e){if(e.placeholder)return e.placeholder;let t=e.component;if(t)return zl(t.subTree);let n=e.suspense;return n&&n.activeBranch?zl(n.activeBranch):null}function $O(e,t){t&&t.pendingBranch?xe(e)?t.effects.push(...e):t.effects.push(e):sS(e)}function w(e=!1){Hn.push(Or=e?null:[])}function P0(){Hn.pop(),Or=Hn[Hn.length-1]||null}function qd(e,t=!1){Pl+=e,e<0&&Or&&t&&(Or.hasOnce=!0)}function HS(e){return e.dynamicChildren=Pl>0?Or||xi:null,P0(),Pl>0&&Or&&Or.push(e),e}function $(e,t,n,i,r,o){return HS(b(e,t,n,i,r,o,!0))}function Fe(e,t,n,i,r){return HS(be(e,t,n,i,r,!0))}function Oa(e){return e?e.__v_isVNode===!0:!1}function io(e,t){return e.type===t.type&&e.key===t.key}function b(e,t=null,n=null,i=0,r=null,o=e===ge?0:1,a=!1,s=!1){let l={__v_isVNode:!0,__v_skip:!0,type:e,props:t,key:t&&KS(t),ref:t&&Vd(t),scopeId:mS,slotScopeIds:null,children:n,component:null,suspense:null,ssContent:null,ssFallback:null,dirs:null,transition:null,el:null,anchor:null,target:null,targetStart:null,targetAnchor:null,staticCount:0,shapeFlag:o,patchFlag:i,dynamicProps:r,dynamicChildren:null,appContext:null,ctx:Yt};return s?(Gd(l,n),o&128&&e.normalize(l)):n&&(l.shapeFlag|=pt(n)?8:16),Pl>0&&!a&&Or&&(l.patchFlag>0||o&6)&&l.patchFlag!==32&&Or.push(l),l}function SO(e,t=null,n=null,i=0,r=null,o=!1){if((!e||e===$S)&&(e=Ft),Oa(e)){let s=Ii(e,t,!0);return n&&Gd(s,n),Pl>0&&!o&&Or&&(s.shapeFlag&6?Or[Or.indexOf(e)]=s:Or.push(s)),s.patchFlag=-2,s}if(DO(e)&&(e=e.__vccOpts),t){t=Ra(t);let{class:s,style:l}=t;s&&!pt(s)&&(t.class=V(s)),qe(l)&&($l(l)&&!xe(l)&&(l=it({},l)),t.style=Se(l))}let a=pt(e)?1:ZS(e)?128:tp(e)?64:qe(e)?4:Te(e)?2:0;return b(e,t,n,i,r,a,o,!0)}function Ra(e){return e?$l(e)?it({},e):RS(e)?it({},e[YS]||e):e:null}function Ii(e,t,n=!1,i=!1){let{props:r,ref:o,patchFlag:a,children:s,transition:l}=e,u=t?R0(r||{},t):r,d={__v_isVNode:!0,__v_skip:!0,type:e.type,props:u,key:u&&KS(u),ref:t&&t.ref?n&&o?xe(o)?o.concat(Vd(t)):[o,Vd(t)]:Vd(t):o,scopeId:e.scopeId,slotScopeIds:e.slotScopeIds,children:s,target:e.target,targetStart:e.targetStart,targetAnchor:e.targetAnchor,staticCount:e.staticCount,shapeFlag:e.shapeFlag,patchFlag:t&&e.type!==ge?a===-1?16:a|16:a,dynamicProps:e.dynamicProps,dynamicChildren:e.dynamicChildren,appContext:e.appContext,dirs:e.dirs,transition:l,component:e.component,suspense:e.suspense,ssContent:e.ssContent&&Ii(e.ssContent),ssFallback:e.ssFallback&&Ii(e.ssFallback),placeholder:e.placeholder,el:e.el,anchor:e.anchor,ctx:e.ctx,ce:e.ce,cacheIndex:e.cacheIndex};return l&&i&&Sn(d,l.clone(d)),d}function xt(e=" ",t=0){return be(Ml,null,e,t)}function WS(e,t){let n=be(za,null,e);return n.staticCount=t,n}function te(e="",t=!1){return t?(w(),Fe(Ft,null,e)):be(Ft,null,e)}function _n(e){return e==null||typeof e=="boolean"?be(Ft):xe(e)?be(ge,null,e.slice()):Oa(e)?Zn(e):be(Ml,null,String(e))}function Zn(e){return e.el===null&&e.patchFlag!==-1||e.memo?e:Ii(e)}function Gd(e,t){let n=0,{shapeFlag:i}=e;if(t==null)t=null;else if(xe(t))n=16;else if(typeof t=="object")if(i&65){let r=t.default;r&&(r._c&&(r._d=!1),Gd(e,r()),r._c&&(r._d=!0));return}else{n=32;let r=t._;!r&&!RS(t)?t._ctx=Yt:r===3&&Yt&&(Yt.slots._===1?t._=1:(t._=2,e.patchFlag|=1024))}else if(Te(t)){if(i&65){Gd(e,{default:t});return}t={default:t,_ctx:Yt},n=32}else t=String(t),i&64?(n=16,t=[xt(t)]):n=8;e.children=t,e.shapeFlag|=n}function R0(...e){let t={};for(let n=0;n<e.length;n++){let i=e[n];for(let r in i)if(r==="class")t.class!==i.class&&(t.class=V([t.class,i.class]));else if(r==="style")t.style=Se([t.style,i.style]);else if(va(r)){let o=t[r],a=i[r];a&&o!==a&&!(xe(o)&&o.includes(a))?t[r]=o?[].concat(o,a):a:a==null&&o==null&&!ba(r)&&(t[r]=a)}else r!==""&&(t[r]=i[r])}return t}function kn(e,t,n,i=null){Dr(e,t,7,[n,i])}function EO(){return qS}function TO(e,t,n){let i=e.type,r=(t?t.appContext:e.appContext)||IO,o={uid:qS++,vnode:e,type:i,parent:t,appContext:r,root:null,next:null,subTree:null,effect:null,update:null,job:null,scope:new yl(!0),render:null,proxy:null,exposed:null,exposeProxy:null,withProxy:null,provides:t?t.provides:Object.create(r.provides),ids:t?t.ids:["",0,0],accessCache:null,renderCache:[],components:null,directives:null,propsOptions:jS(i,r),emitsOptions:zS(i,r),emit:null,emitted:null,propsDefaults:Ze,inheritAttrs:i.inheritAttrs,ctx:Ze,data:Ze,props:Ze,attrs:Ze,slots:Ze,refs:Ze,setupState:Ze,setupContext:null,suspense:n,suspenseId:n?n.pendingId:0,asyncDep:null,asyncResolved:!1,isMounted:!1,isUnmounted:!1,isDeactivated:!1,bc:null,c:null,bm:null,m:null,bu:null,u:null,um:null,bum:null,da:null,a:null,rtg:null,rtc:null,ec:null,sp:null};return o.ctx={_:o},o.root=t?t.root:o,o.emit=sO.bind(null,o),e.ce&&e.ce(o),o}function GS(e){return e.vnode.shapeFlag&4}function NO(e,t=!1,n=!1){t&&Rl(t);let{props:i,children:r}=e.vnode,o=GS(e);mO(e,i,o,t),vO(e,r,n||t);let a=o?CO(e,t):void 0;return t&&Rl(!1),a}function CO(e,t){let n=e.type;e.accessCache=Object.create(null),e.proxy=new Proxy(e.ctx,QA);let{setup:i}=n;if(i){on();let r=e.setupContext=i.length>1?AO(e):null,o=Ll(e),a=jl(i,e,0,[e.props,r]),s=Bb(a);if(an(),o(),(s||e.sp)&&!Na(e)&&wS(e),s){if(a.then(eS,eS),t)return a.then(l=>{Rl(!0);try{tS(e,l,t)}finally{Rl(!1)}}).catch(l=>{Yd(l,e,0,void 0,!0),e.ssrRender=(u,d)=>d("<!---->")});e.asyncDep=a}else tS(e,a,t)}else JS(e,t)}function tS(e,t,n){Te(t)?e.type.__ssrInlineRender?e.ssrRender=t:e.render=t:qe(t)&&(__VUE_PROD_DEVTOOLS__&&(e.devtoolsRawSetupState=t),e.setupState=jd(t)),JS(e,n)}function JS(e,t,n){let i=e.type;if(!e.render){if(!t&&rS&&!i.render){let r=i.template||__VUE_OPTIONS_API__&&z0(e).template;if(r){let{isCustomElement:o,compilerOptions:a}=e.appContext.config,{delimiters:s,compilerOptions:l}=i,u=it(it({isCustomElement:o,delimiters:s},a),l);i.render=rS(r,u)}}e.render=i.render||ur,nS&&nS(e)}if(__VUE_OPTIONS_API__){let r=Ll(e);on();try{eO(e)}finally{an(),r()}}}function AO(e){let t=n=>{e.exposed=n||{}};return{attrs:new Proxy(e.attrs,zO),slots:e.slots,emit:e.emit,expose:t}}function op(e){return e.exposed?e.exposeProxy||(e.exposeProxy=new Proxy(jd(c0(e.exposed)),{get(t,n){if(n in t)return t[n];if(n in Cl)return Cl[n](e)},has(t,n){return n in t||n in Cl}})):e.proxy}function OO(e,t=!0){return Te(e)?e.displayName||e.name:e.name||t&&e.__name}function DO(e){return Te(e)&&"__vccOpts"in e}function XS(e,t,n){try{qd(-1);let i=arguments.length;return i===2?qe(t)&&!xe(t)?Oa(t)?be(e,null,[t]):be(e,t):be(e,null,t):(i>3?n=Array.prototype.slice.call(arguments,2):i===3&&Oa(n)&&(n=[n]),be(e,t,n))}finally{qd(1)}}var pr,sn,xn,Si,Ta,oS,Fd,p0,Al,TA,$n,Il,v0,zA,pS,AA,OA,Yt,mS,RA,UA,$i,hS,tp,no,LA,B$,Z$,b0,VA,gS,Br,Sl,Fr,E0,BA,bS,Hd,ZB,HB,Na,np,Kn,WA,Ut,xS,N0,Da,Wn,qA,GA,JA,_S,$S,w0,Cl,f0,QA,k0,rO,oO,Ca,CS,lO,cO,uO,DS,PS,RS,hO,A0,O0,gO,MS,LS,VS,vO,bO,rr,ZS,_O,ge,Ml,Ft,za,Hn,Or,Pl,KS,Vd,be,IO,qS,nr,Ua,Jd,Rl,Ll,eS,Ul,rS,nS,YS,zO,R,iS,U0=re(()=>{d0();d0();hl();hl();/**
|
|
70
|
+
**/yl=class{constructor(t=!1){this.detached=t,this._active=!0,this._on=0,this.effects=[],this.cleanups=[],this._isPaused=!1,this._warnOnRun=!0,this.__v_skip=!0,!t&&Gt&&(Gt.active?(this.parent=Gt,this.index=(Gt.scopes||(Gt.scopes=[])).push(this)-1):(this._active=!1,this._warnOnRun=!1))}get active(){return this._active}pause(){if(this._active){this._isPaused=!0;let t,n;if(this.scopes){let i=this.scopes.slice();for(t=0,n=i.length;t<n;t++)i[t].pause()}for(t=0,n=this.effects.length;t<n;t++)this.effects[t].pause()}}resume(){if(this._active&&this._isPaused){this._isPaused=!1;let t,n;if(this.scopes){let r=this.scopes.slice();for(t=0,n=r.length;t<n;t++)r[t].resume()}let i=this.effects.slice();for(t=0,n=i.length;t<n;t++)i[t].resume()}}run(t){if(this._active){let n=Gt;try{return Gt=this,t()}finally{Gt=n}}}on(){++this._on===1&&(this.prevScope=Gt,Gt=this)}off(){if(this._on>0&&--this._on===0){if(Gt===this)Gt=this.prevScope;else{let t=Gt;for(;t;){if(t.prevScope===this){t.prevScope=this.prevScope;break}t=t.prevScope}}this.prevScope=void 0}}stop(t){if(this._active){this._active=!1;let n,i;for(n=0,i=this.effects.length;n<i;n++)this.effects[n].stop();for(this.effects.length=0,n=0,i=this.cleanups.length;n<i;n++)this.cleanups[n]();if(this.cleanups.length=0,this.scopes){let r=this.scopes.slice();for(n=0,i=r.length;n<i;n++)r[n].stop(!0);this.scopes.length=0}if(!this.detached&&this.parent&&!t){let r=this.parent.scopes.pop();r&&r!==this&&(this.parent.scopes[this.index]=r,r.index=this.index)}this.parent=void 0}}};Kb=new WeakSet,Sa=class{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,Gt&&(Gt.active?Gt.effects.push(this):this.flags&=-2)}pause(){this.flags|=64}resume(){this.flags&64&&(this.flags&=-65,Kb.has(this)&&(Kb.delete(this),this.trigger()))}notify(){this.flags&2&&!(this.flags&32)||this.flags&8||T$(this)}run(){if(!(this.flags&1))return this.fn();this.flags|=2,_$(this),N$(this);let t=ht,n=nn;ht=this,nn=!0;try{return this.fn()}finally{C$(this),ht=t,nn=n,this.flags&=-3}}stop(){if(this.flags&1){for(let t=this.deps;t;t=t.nextDep)a0(t);this.deps=this.depsTail=void 0,_$(this),this.onStop&&this.onStop(),this.flags&=-2}}trigger(){this.flags&64?Kb.add(this):this.scheduler?this.scheduler():this.runIfDirty()}runIfDirty(){Gb(this)&&this.run()}get dirty(){return Gb(this)}},E$=0;nn=!0,A$=[];wl=0,Jb=class{constructor(t,n){this.sub=t,this.dep=n,this.version=n.version,this.nextDep=this.prevDep=this.nextSub=this.prevSub=this.prevActiveLink=void 0}},Ia=class{constructor(t){this.computed=t,this.version=0,this.activeLink=void 0,this.subs=void 0,this.map=void 0,this.key=void 0,this.sc=0,this.__v_skip=!0}track(t){if(!ht||!nn||ht===this.computed)return;let n=this.activeLink;if(n===void 0||n.sub!==ht)n=this.activeLink=new Jb(ht,this),ht.deps?(n.prevDep=ht.depsTail,ht.depsTail.nextDep=n,ht.depsTail=n):ht.deps=ht.depsTail=n,O$(n);else if(n.version===-1&&(n.version=this.version,n.nextDep)){let i=n.nextDep;i.prevDep=n.prevDep,n.prevDep&&(n.prevDep.nextDep=i),n.prevDep=ht.depsTail,n.nextDep=void 0,ht.depsTail.nextDep=n,ht.depsTail=n,ht.deps===n&&(ht.deps=i)}return n}trigger(t){this.version++,wl++,this.notify(t)}notify(t){i0();try{for(let n=this.subs;n;n=n.prevSub)n.sub.notify()&&n.sub.dep.notify()}finally{o0()}}};Yb=new WeakMap,eo=Symbol(""),Xb=Symbol(""),kl=Symbol("");cA={__proto__:null,[Symbol.iterator](){return Wb(this,Symbol.iterator,e=>vn(this,e))},concat(...e){return $a(this).concat(...e.map(t=>xe(t)?$a(t):t))},entries(){return Wb(this,"entries",e=>(e[1]=vn(this,e[1]),e))},every(e,t){return Fn(this,"every",e,t,void 0,arguments)},filter(e,t){return Fn(this,"filter",e,t,n=>n.map(i=>vn(this,i)),arguments)},find(e,t){return Fn(this,"find",e,t,n=>vn(this,n),arguments)},findIndex(e,t){return Fn(this,"findIndex",e,t,void 0,arguments)},findLast(e,t){return Fn(this,"findLast",e,t,n=>vn(this,n),arguments)},findLastIndex(e,t){return Fn(this,"findLastIndex",e,t,void 0,arguments)},forEach(e,t){return Fn(this,"forEach",e,t,void 0,arguments)},includes(...e){return qb(this,"includes",e)},indexOf(...e){return qb(this,"indexOf",e)},join(e){return $a(this).join(e)},lastIndexOf(...e){return qb(this,"lastIndexOf",e)},map(e,t){return Fn(this,"map",e,t,void 0,arguments)},pop(){return gl(this,"pop")},push(...e){return gl(this,"push",e)},reduce(e,...t){return S$(this,"reduce",e,t)},reduceRight(e,...t){return S$(this,"reduceRight",e,t)},shift(){return gl(this,"shift")},some(e,t){return Fn(this,"some",e,t,void 0,arguments)},splice(...e){return gl(this,"splice",e)},toReversed(){return $a(this).toReversed()},toSorted(e){return $a(this).toSorted(e)},toSpliced(...e){return $a(this).toSpliced(...e)},unshift(...e){return gl(this,"unshift",e)},values(){return Wb(this,"values",e=>vn(this,e))}};D$=Array.prototype;uA=ga("__proto__,__v_isRef,__isVue"),P$=new Set(Object.getOwnPropertyNames(Symbol).filter(e=>e!=="arguments"&&e!=="caller").map(e=>Symbol[e]).filter(_r));Dd=class{constructor(t=!1,n=!1){this._isReadonly=t,this._isShallow=n}get(t,n,i){if(n==="__v_skip")return t.__v_skip;let r=this._isReadonly,o=this._isShallow;if(n==="__v_isReactive")return!r;if(n==="__v_isReadonly")return r;if(n==="__v_isShallow")return o;if(n==="__v_raw")return i===(r?o?wA:j$:o?U$:R$).get(t)||Object.getPrototypeOf(t)===Object.getPrototypeOf(i)?t:void 0;let a=xe(t);if(!r){let l;if(a&&(l=cA[n]))return l;if(n==="hasOwnProperty")return dA}let s=Reflect.get(t,n,Vt(t)?t:i);if((_r(n)?P$.has(n):uA(n))||(r||Jt(t,"get",n),o))return s;if(Vt(s)){let l=a&&Td(n)?s:s.value;return r&&qe(l)?Rd(l):l}return qe(s)?r?Rd(s):_l(s):s}},Pd=class extends Dd{constructor(t=!1){super(!1,t)}set(t,n,i,r){let o=t[n],a=xe(t)&&Td(n);if(!this._isShallow){let u=Vr(o);if(!$r(i)&&!Vr(i)&&(o=He(o),i=He(i)),!a&&Vt(o)&&!Vt(i))return u||(o.value=i),!0}let s=a?Number(n)<t.length:Ke(t,n),l=Reflect.set(t,n,i,Vt(t)?t:r);return t===He(r)&&l&&(s?Rt(i,o)&&bn(t,"set",n,i,o):bn(t,"add",n,i)),l}deleteProperty(t,n){let i=Ke(t,n),r=t[n],o=Reflect.deleteProperty(t,n);return o&&i&&bn(t,"delete",n,void 0,r),o}has(t,n){let i=Reflect.has(t,n);return(!_r(n)||!P$.has(n))&&Jt(t,"has",n),i}ownKeys(t){return Jt(t,"iterate",xe(t)?"length":eo),Reflect.ownKeys(t)}},Qb=class extends Dd{constructor(t=!1){super(!0,t)}set(t,n){return!0}deleteProperty(t,n){return!0}},pA=new Pd,mA=new Qb,fA=new Pd(!0),e0=e=>e,zd=e=>Reflect.getPrototypeOf(e);vA={get:s0(!1,!1)},bA={get:s0(!1,!0)},yA={get:s0(!0,!1)},R$=new WeakMap,U$=new WeakMap,j$=new WeakMap,wA=new WeakMap;Ar=e=>qe(e)?_l(e):e,Bn=e=>qe(e)?Rd(e):e;t0=class{constructor(t,n){this.dep=new Ia,this.__v_isRef=!0,this.__v_isShallow=!1,this._rawValue=n?t:He(t),this._value=n?t:Ar(t),this.__v_isShallow=n}get value(){return this.dep.track(),this._value}set value(t){let n=this._rawValue,i=this.__v_isShallow||$r(t)||Vr(t);t=i?t:He(t),Rt(t,n)&&(this._rawValue=t,this._value=i?t:Ar(t),this.dep.trigger())}};xA={get:(e,t,n)=>t==="__v_raw"?e:Ae(Reflect.get(e,t,n)),set:(e,t,n,i)=>{let r=e[t];return Vt(r)&&!Vt(n)?(r.value=n,!0):Reflect.set(e,t,n,i)}};r0=class{constructor(t){this.__v_isRef=!0,this._value=void 0;let n=this.dep=new Ia,{get:i,set:r}=t(n.track.bind(n),n.trigger.bind(n));this._get=i,this._set=r}get value(){return this._value=this._get()}set value(t){this._set(t)}};n0=class{constructor(t,n,i){this.fn=t,this.setter=n,this._value=void 0,this.dep=new Ia(this),this.__v_isRef=!0,this.deps=void 0,this.depsTail=void 0,this.flags=16,this.globalVersion=wl-1,this.next=void 0,this.effect=this,this.__v_isReadonly=!n,this.isSSR=i}notify(){if(this.flags|=16,!(this.flags&8)&&ht!==this)return T$(this,!0),!0}get value(){let t=this.dep.track();return z$(this),t&&(t.version=this.dep.version),this._value}set value(t){this.setter&&this.setter(t)}};Od={},Ud=new WeakMap});function jl(e,t,n,i){try{return i?e(...i):e()}catch(r){Yd(r,t,n)}}function Dr(e,t,n,i){if(Te(e)){let r=jl(e,t,n,i);return r&&Bb(r)&&r.catch(o=>{Yd(o,t,n,void 0,!0)}),r}if(xe(e)){let r=[];for(let o=0;o<e.length;o++)r.push(Dr(e[o],t,n,i));return r}}function Yd(e,t,n,i=!0,r=!1){let o=t?t.vnode:null,{errorHandler:a,throwUnhandledErrorInProduction:s}=t&&t.appContext.config||Ze;if(t){let l=t.parent,u=t.proxy,d=`https://vuejs.org/error-reference/#runtime-${n}`;for(;l;){let p=l.ec;if(p&&!l.isUnmounted&&(!r||l.scope.active)){for(let m=0;m<p.length;m++)if(p[m](e,u,d)===!1)return}l=l.parent}if(a){on(),jl(a,null,10,[e,u,d]),an();return}}SA(e,n,o,i,s)}function SA(e,t,n,i=!0,r=!1){if(r)throw e;console.error(e)}function oo(e){let t=Fd||oS;return e?t.then(this?e.bind(this):e):t}function IA(e){let t=sn+1,n=pr.length;for(;t<n;){let i=t+n>>>1,r=pr[i],o=Al(r);o<e||o===e&&r.flags&2?t=i+1:n=i}return t}function Xd(e){if(!(e.flags&1)){let t=Al(e),n=pr[pr.length-1];!n||!(e.flags&2)&&t>=Al(n)?pr.push(e):pr.splice(IA(t),0,e),e.flags|=1,aS()}}function aS(){Fd||(Fd=oS.then(uS))}function sS(e){if(!xe(e))Si&&e.id===-1?Si.splice(Ta+1,0,e):e.flags&1||(xn.push(e),e.flags|=1);else for(let t=0;t<e.length;t++)xn.push(e[t]);aS()}function lS(e,t,n,i=sn+1){for(;i<pr.length;i++){let r=pr[i];if(r&&r.flags&2){if(e&&r.id!==e.uid||t!==void 0&&!(r.id>=t))continue;pr.splice(i,1),i=e?i-1:sn,r.flags&4&&(r.flags&=-2),r(),r.flags&4||(r.flags&=-2)}}}function cS(e,t,n=0){if(xn.length){let i=xn,r=0;if(t){i=[];for(let a=0;a<xn.length;a++){let s=xn[a];(s.i!==void 0?!s.i||s.i.uid<n:t.has(s))?xn[r++]=s:i.push(s)}}let o=[...new Set(i)].sort((a,s)=>Al(a)-Al(s));if(xn.length=r,Si){for(let a=0;a<o.length;a++)Si.push(o[a]);return}for(Si=o,Ta=0;Ta<Si.length;Ta++){let a=Si[Ta];a.flags&4&&(a.flags&=-2),a.flags&8||a(),a.flags&=-2}Si=null,Ta=0}}function EA(e,t){if(p0){e();return}let n=t===void 0?void 0:new Set(xn);e(),p0=!0;try{lS(void 0,t),cS(void 0,n,t)}finally{p0=!1}}function uS(e){let t=ur;try{for(sn=0;sn<pr.length;sn++){let n=pr[sn];n&&!(n.flags&8)&&(n.flags&4&&(n.flags&=-2),jl(n,n.i,n.i?15:14),n.flags&4||(n.flags&=-2))}}finally{for(;sn<pr.length;sn++){let n=pr[sn];n&&(n.flags&=-2)}sn=-1,pr.length=0,cS(e),Fd=null,(pr.length||xn.length)&&uS(e)}}function Qd(e,...t){$n?$n.emit(e,...t):v0||Il.push({event:e,args:t})}function dS(e,t){var n,i;$n=e,$n?($n.enabled=!0,Il.forEach(({event:r,args:o})=>$n.emit(r,...o)),Il=[]):typeof window<"u"&&window.HTMLElement&&!((i=(n=window.navigator)==null?void 0:n.userAgent)!=null&&i.includes("jsdom"))?((t.__VUE_DEVTOOLS_HOOK_REPLAY__=t.__VUE_DEVTOOLS_HOOK_REPLAY__||[]).push(o=>{dS(o,t)}),setTimeout(()=>{$n||(t.__VUE_DEVTOOLS_HOOK_REPLAY__=null,v0=!0,Il=[])},3e3)):(v0=!0,Il=[])}function NA(e,t){Qd("app:init",e,t,{Fragment:ge,Text:Ml,Comment:Ft,Static:za})}function CA(e){Qd("app:unmount",e)}function $0(e){return t=>{Qd(e,t.appContext.app,t.uid,t.parent?t.parent.uid:void 0,t)}}function DA(e,t,n){Qd("component:emit",e.appContext.app,e,t,n)}function Bd(e){let t=Yt;return Yt=e,mS=e&&e.type.__scopeId||null,t}function ot(e,t=Yt,n){if(!t||e._n)return e;let i=(...r)=>{i._d&&qd(-1);let o=Bd(t),a=Hn.length,s;try{s=e(...r)}finally{for(let l=Hn.length;l>a;l--)P0();Bd(o),i._d&&qd(1)}return __VUE_PROD_DEVTOOLS__&&pS(t),s};return i._n=!0,i._c=!0,i._d=!0,i}function ep(e,t){if(Yt===null)return e;let n=op(Yt),i=e.dirs||(e.dirs=[]);for(let r=0;r<t.length;r++){let[o,a,s,l=Ze]=t[r];o&&(Te(o)&&(o={mounted:o,updated:o}),o.deep&&yn(a),i.push({dir:o,instance:n,value:a,oldValue:void 0,arg:s,modifiers:l}))}return e}function to(e,t,n,i){let r=e;if(i==="beforeMount")e._mount=e;else if(i==="beforeUpdate"){let s=t&&t._mount;s&&(s._latest=e,e._mount=s)}else if(i==="mounted"){let s=e._latest;e._mount=e._latest=void 0,s&&(r=s,s._mount=void 0)}let o=r.dirs,a=t&&t.dirs;for(let s=0;s<o.length;s++){let l=o[s];a?l.oldValue=a[s].value:i==="mounted"&&l.oldValue!==void 0&&(l=it({},l,{oldValue:void 0}));let u=l.dir[i];u&&(on(),Dr(u,n,8,[e.el,l,r,t]),an())}}function PA(e,t){if(nr){let n=nr.provides,i=nr.parent&&nr.parent.provides;i===n&&(n=nr.provides=Object.create(i)),n[e]=t}}function Ld(e,t,n=!1){let i=Ua();if(i||Ca){let r=Ca?Ca._context.provides:i?i.parent==null||i.ce?i.vnode.appContext&&i.vnode.appContext.provides:i.parent.provides:void 0;if(r&&e in r)return r[e];if(arguments.length>1)return n&&Te(t)?t.call(i&&i.proxy):t}}function jA(e,t){return S0(e,null,{flush:"sync"})}function mt(e,t,n){return S0(e,t,n)}function S0(e,t,n=Ze){let{immediate:i,deep:r,flush:o,once:a}=n,s=it({},n),l=t&&i||!t&&o!=="post",u;if(Ul){if(o==="sync"){let f=UA();u=f.__watcherHandles||(f.__watcherHandles=[])}else if(!l){let f=()=>{};return f.stop=ur,f.resume=ur,f.pause=ur,f}}let d=nr;s.call=(f,h,v)=>Dr(f,d,h,v);let p=!1;o==="post"?s.scheduler=f=>{f.i=d,rr(f,d&&d.suspense)}:o!=="sync"&&(p=!0,s.scheduler=(f,h)=>{h?f():Xd(f)}),s.augmentJob=f=>{t&&(f.flags|=4),p&&(f.flags|=2,d&&(f.id=d.uid,f.i=d))};let m=F$(e,t,s);return Ul&&(u?u.push(m):l&&m()),m}function MA(e,t,n){let i=this.proxy,r=pt(e)?e.includes(".")?fS(i,e):()=>i[e]:e.bind(i,i),o;Te(t)?o=t:(o=t.handler,n=t);let a=Ll(this),s=S0(r,o.bind(i),n);return a(),s}function fS(e,t){let n=t.split(".");return()=>{let i=e;for(let r=0;r<n.length&&i;r++)i=i[n[r]];return i}}function Md(e,t,n,{o:{insert:i},m:r},o=2){o===0&&(e.targetStart&&i(e.targetStart,t,n),i(e.targetAnchor,t,n),n=e.targetAnchor);let{el:a,anchor:s,shapeFlag:l,children:u,props:d}=e,p=o===2;if(p&&i(a,t,n),!$i.has(e)&&(!p||no(d))&&l&16)for(let m=0;m<u.length;m++)r(u[m],t,n,2);p&&i(s,t,n)}function FA(e,t,n,i,r,o,{o:{nextSibling:a,parentNode:s,querySelector:l,insert:u,createText:d}},p){function m(k,T){let S=T;for(;S;){if(S&&S.nodeType===8){if(S.data==="teleport start anchor")t.targetStart=S;else if(S.data==="teleport anchor"){t.targetAnchor=S,k._lpa=t.targetAnchor&&a(t.targetAnchor);break}}S=a(S)}}function f(k,T){T.anchor=p(a(k),T,s(k),n,i,r,o)}let h=t.target=b0(t.props,l),v=no(t.props);if(h){let k=h._lpa||h.firstChild;t.shapeFlag&16&&(v?(f(e,t),m(h,k),t.targetAnchor||y0(h,t,d,u,s(e)===h?e:null)):(t.anchor=a(e),m(h,k),t.targetAnchor||y0(h,t,d,u),p(k&&a(k),t,h,n,i,r,o))),El(t,v)}else v&&t.shapeFlag&16&&(f(e,t),t.targetStart=e,t.targetAnchor=a(e));return t.anchor&&a(t.anchor)}function El(e,t){let n=e.ctx;if(n&&n.ut){let i,r;for(t?(i=e.el,r=e.anchor):(i=e.targetStart,r=e.targetAnchor);i&&i!==r;)i.nodeType===1&&i.setAttribute("data-v-owner",n.uid),i=i.nextSibling;n.ut()}}function y0(e,t,n,i,r=null){let o=t.targetStart=n(""),a=t.targetAnchor=n("");return o[hS]=a,e&&(i(o,e,r),i(a,e,r)),a}function I0(){let e={isMounted:!1,isLeaving:!1,isUnmounting:!1,leavingVNodes:new Map};return Ut(()=>{e.isMounted=!0}),Da(()=>{e.isUnmounting=!0}),e}function vS(e){let t=e[0];if(e.length>1){let n=!1;for(let i of e)if(i.type!==Ft){t=i,n=!0;break}}return t}function yS(e,t){let{leavingVNodes:n}=e,i=n.get(t.type);return i||(i=Object.create(null),n.set(t.type,i)),i}function Aa(e,t,n,i){let{appear:r,mode:o,persisted:a=!1,onBeforeEnter:s,onEnter:l,onAfterEnter:u,onEnterCancelled:d,onBeforeLeave:p,onLeave:m,onAfterLeave:f,onLeaveCancelled:h,onBeforeAppear:v,onAppear:k,onAfterAppear:T,onAppearCancelled:S}=t,z=String(e.key),j=yS(n,e),O=(W,ce)=>{W&&Dr(W,i,9,ce)},U=(W,ce)=>{let se=ce[1];O(W,ce),xe(W)?W.every(pe=>pe.length<=1)&&se():W.length<=1&&se()},J={mode:o,persisted:a,beforeEnter(W){let ce=s;if(!n.isMounted)if(r)ce=v||s;else return;W[Br]&&W[Br](!0);let se=j[z];if(se&&io(e,se)){let pe=se.el[Br];if(!pe){let F=Ol(se);pe=F&&F.el[Br]}pe&&pe()}O(ce,[W])},enter(W){if(!TA&&j[z]===e)return;let ce=l,se=u,pe=d;if(!n.isMounted)if(r)ce=k||l,se=T||u,pe=S||d;else return;let F=!1;W[Sl]=Je=>{F||(F=!0,Je?O(pe,[W]):O(se,[W]),J.delayedLeave&&J.delayedLeave(),W[Sl]=void 0)};let ue=W[Sl].bind(null,!1);ce?U(ce,[W,ue]):ue()},leave(W,ce){let se=String(e.key);if(W[Sl]&&W[Sl](!0),n.isUnmounting)return ce();O(p,[W]);let pe=!1;W[Br]=ue=>{pe||(pe=!0,ce(),ue?O(h,[W]):O(f,[W]),W[Br]=void 0,j[se]===e&&delete j[se])};let F=W[Br].bind(null,!1);j[se]=e,m?U(m,[W,F]):F()},clone(W){let ce=Aa(W,t,n,i);return ce.afterLeave=()=>{J.afterLeave&&J.afterLeave()},ce.delayLeave=(se,pe,F)=>{J.delayLeave?J.delayLeave(se,pe,F):F()},ce.delayedLeave=()=>{J.delayedLeave&&J.delayedLeave()},ce}};return J}function m0(e){if(np(e))return e=Ii(e),e.children=null,e}function Zd(e){if(!np(e))return tp(e.type)&&e.children?vS(e.children):e;if(e.component)return e.component.subTree;let{shapeFlag:t,children:n}=e;if(n){if(t&16)return n[0];if(t&32&&Te(n.default))return n.default()}}function Sn(e,t){if(e.shapeFlag&6&&e.component){e.transition=t;let n=e.component.subTree;Sn(tp(n.type)&&Zd(n)||n,t)}else if(e.shapeFlag&128){let n=e.suspense;if(n){let i=n.isHydrating?n.pendingBranch:n.activeBranch;i&&Sn(i,t.clone(i))}else e.ssContent.transition=t.clone(e.ssContent),e.ssFallback.transition=t.clone(e.ssFallback)}else if(e.transition=t,e.type===ge&&xe(e.children)){let n=AS(e.children,!1);n&&Sn(n,t)}}function rp(e,t=!1,n){let i=[],r=0;for(let o=0;o<e.length;o++){let a=e[o],s=n==null?a.key:String(n)+String(a.key!=null?a.key:o);a.type===ge?(a.patchFlag&128&&r++,i=i.concat(rp(a.children,t,s))):(t||a.type!==Ft)&&i.push(s!=null?Ii(a,{key:s}):a)}if(r>1)for(let o=0;o<i.length;o++)i[o].patchFlag=-2;return i}function Ol(e){if(e.component)return Ol(e.component.subTree);if(e.type===ge){let t=xe(e.children)&&AS(e.children,!1);return t?Ol(t):void 0}if(e.type!==Ft)return e}function Pe(e,t){return Te(e)?it({name:e.name},t,{setup:e}):e}function wS(e){e.ids=[e.ids[0]+e.ids[2]+++"-",0,0]}function T0(e){let t=Ua(),n=We(null);if(t){let r=t.refs===Ze?t.refs={}:t.refs;Object.defineProperty(r,e,{enumerable:!0,get:()=>n.value,set:o=>n.value=o})}return n}function H$(e,t){let n;return!!((n=Object.getOwnPropertyDescriptor(e,t))&&!n.configurable)}function Nl(e,t,n,i,r=!1){if(xe(e)){e.forEach((v,k)=>Nl(v,t&&(xe(t)?t[k]:t),n,i,r));return}if(Na(i)&&!r){i.shapeFlag&512&&i.type.__asyncResolved&&i.component.subTree.component&&Nl(e,t,n,i.component.subTree);return}let o=i.shapeFlag&4?op(i.component):i.el,a=r?null:o,{i:s,r:l}=e,u=t&&t.r,d=s.refs===Ze?s.refs={}:s.refs,p=s.setupState,m=He(p),f=p===Ze?Fb:v=>H$(d,v)?!1:Ke(m,v),h=(v,k)=>!(k&&H$(d,k));if(u!=null&&u!==l){if(K$(t),pt(u))d[u]=null,f(u)&&(p[u]=null);else if(Vt(u)){let v=t;h(u,v.k)&&(u.value=null),v.k&&(d[v.k]=null)}}if(Te(l))jl(l,s,12,[a,d]);else{let v=pt(l),k=Vt(l);if(v||k){let T=()=>{if(e.f){let S=v?f(l)?p[l]:d[l]:h(l)||!e.k?l.value:d[e.k];if(r)xe(S)&&dl(S,o);else if(xe(S))S.includes(o)||S.push(o);else if(v)d[l]=[o],f(l)&&(p[l]=d[l]);else{let z=[o];h(l,e.k)&&(l.value=z),e.k&&(d[e.k]=z)}}else v?(d[l]=a,f(l)&&(p[l]=a)):k&&(h(l,e.k)&&(l.value=a),e.k&&(d[e.k]=a))};if(a){let S=()=>{T(),Hd.delete(e)};S.id=-1,Hd.set(e,S),rr(S,n)}else K$(e),T()}}}function K$(e){let t=Hd.get(e);t&&(t.flags|=8,Hd.delete(e))}function ZA(e,t){kS(e,"a",t)}function HA(e,t){kS(e,"da",t)}function kS(e,t,n=nr){let i=e.__wdc||(e.__wdc=()=>{let r=n;for(;r;){if(r.isDeactivated)return;r=r.parent}return e()});if(Dl(t,i,n),n){let r=n.parent;for(;r&&r.parent;)np(r.parent.vnode)&&KA(i,t,n,r),r=r.parent}}function KA(e,t,n,i){let r=Dl(t,e,i,!0),o=Dl("um",()=>dl(i[t],r),n);o.flags=16}function Dl(e,t,n=nr,i=!1){if(n){let r=n[e]||(n[e]=[]),o=t.__weh||(t.__weh=(...a)=>{on();let s=Ll(n),l=Dr(t,n,e,a);return s(),an(),l});return i?r.unshift(o):r.push(o),o}}function YA(e,t=nr){Dl("ec",e,t)}function SS(e){return pt(e)?XA(_S,e,!1)||e:e||$S}function XA(e,t,n=!0,i=!1){let r=Yt||nr;if(r){let o=r.type;if(e===_S){let s=OO(o,!1);if(s&&(s===t||s===Ct(t)||s===Xi(Ct(t))))return o}let a=W$(r[e]||o[e],t)||W$(r.appContext[e],t);return!a&&i?o:a}}function W$(e,t){return e&&(e[t]||e[Ct(t)]||e[Xi(Ct(t))])}function st(e,t,n,i){let r,o=n&&n[i],a=xe(e);if(a||pt(e)){let s=a&&wn(e),l=!1,u=!1;s&&(l=!$r(e),u=Vr(e),e=xl(e)),r=new Array(e.length);for(let d=0,p=e.length;d<p;d++)r[d]=t(l?u?Bn(Ar(e[d])):Ar(e[d]):e[d],d,void 0,o&&o[d])}else if(typeof e=="number")if(!Number.isInteger(e)||e<0)r=[];else{r=new Array(e);for(let s=0;s<e;s++)r[s]=t(s+1,s,void 0,o&&o[s])}else if(qe(e))if(e[Symbol.iterator])r=Array.from(e,(s,l)=>t(s,l,void 0,o&&o[l]));else{let s=Object.keys(e);r=new Array(s.length);for(let l=0,u=s.length;l<u;l++){let d=s[l];r[l]=t(e[d],d,l,o&&o[l])}}else r=[];return n&&(n[i]=r),r}function Pa(e,t){for(let n=0;n<t.length;n++){let i=t[n];if(xe(i))for(let r=0;r<i.length;r++)e[i[r].name]=i[r].fn;else i&&(e[i.name]=i.key?(...r)=>{let o=i.fn(...r);return o&&(o.key=i.key),o}:i.fn)}return e}function zt(e,t,n,i,r,o){if(n==null&&(n={}),Yt.ce||Yt.parent&&Na(Yt.parent)&&Yt.parent.ce){let u=o!=null&&n.key==null?it({},n,{key:o}):n,d=Object.keys(u).length>0;return t!=="default"&&(u.name=t),w(),Fe(ge,null,[be("slot",u,i&&i())],d?-2:64)}let a=e[t];a&&a._c&&(a._d=!1);let s=Hn.length;w();let l;try{let u=a&&IS(a(n)),d=n.key||o||u&&u.key;l=Fe(ge,{key:(d&&!_r(d)?d:`_${t}`)+(!u&&i?"_fb":"")},u||(i?i():[]),u&&e._===1?64:-2)}catch(u){for(let d=Hn.length;d>s;d--)P0();throw u}finally{a&&a._c&&(a._d=!0)}return!r&&l.scopeId&&(l.slotScopeIds=[l.scopeId+"-s"]),l}function IS(e){return e.some(t=>Oa(t)?!(t.type===Ft||t.type===ge&&!IS(t.children)):!0)?e:null}function Kd(e){return xe(e)?e.reduce((t,n)=>(t[n]=null,t),{}):e}function C0(e,t){return!e||!t?e||t:xe(e)&&xe(t)?e.concat(t):it({},Kd(e),Kd(t))}function eO(e){let t=z0(e),n=e.proxy,i=e.ctx;k0=!1,t.beforeCreate&&q$(t.beforeCreate,e,"bc");let{data:r,computed:o,methods:a,watch:s,provide:l,inject:u,created:d,beforeMount:p,mounted:m,beforeUpdate:f,updated:h,activated:v,deactivated:k,beforeDestroy:T,beforeUnmount:S,destroyed:z,unmounted:j,render:O,renderTracked:U,renderTriggered:J,errorCaptured:W,serverPrefetch:ce,expose:se,inheritAttrs:pe,components:F,directives:ue,filters:Je}=t;if(u&&tO(u,i,null),a)for(let Re in a){let Be=a[Re];Te(Be)&&(i[Re]=Be.bind(n))}if(r){let Re=r.call(n,n);qe(Re)&&(e.data=_l(Re))}if(k0=!0,o)for(let Re in o){let Be=o[Re],Mt=Te(Be)?Be.bind(n,n):Te(Be.get)?Be.get.bind(n,n):ur,Er=!Te(Be)&&Te(Be.set)?Be.set.bind(n):ur,mr=R({get:Mt,set:Er});Object.defineProperty(i,Re,{enumerable:!0,configurable:!0,get:()=>mr.value,set:gt=>mr.value=gt})}if(s)for(let Re in s)ES(s[Re],i,n,Re);if(l){let Re=Te(l)?l.call(n):l;Reflect.ownKeys(Re).forEach(Be=>{PA(Be,Re[Be])})}d&&q$(d,e,"c");function ft(Re,Be){xe(Be)?Be.forEach(Mt=>Re(Mt.bind(n))):Be&&Re(Be.bind(n))}if(ft(WA,p),ft(Ut,m),ft(xS,f),ft(N0,h),ft(ZA,v),ft(HA,k),ft(YA,W),ft(JA,U),ft(GA,J),ft(Da,S),ft(Wn,j),ft(qA,ce),xe(se))if(se.length){let Re=e.exposed||(e.exposed={});se.forEach(Be=>{Object.defineProperty(Re,Be,{get:()=>n[Be],set:Mt=>n[Be]=Mt,enumerable:!0})})}else e.exposed||(e.exposed={});O&&e.render===ur&&(e.render=O),pe!=null&&(e.inheritAttrs=pe),F&&(e.components=F),ue&&(e.directives=ue),ce&&wS(e)}function tO(e,t,n=ur){xe(e)&&(e=x0(e));for(let i in e){let r=e[i],o;qe(r)?"default"in r?o=Ld(r.from||i,r.default,!0):o=Ld(r.from||i):o=Ld(r),Vt(o)?Object.defineProperty(t,i,{enumerable:!0,configurable:!0,get:()=>o.value,set:a=>o.value=a}):t[i]=o}}function q$(e,t,n){Dr(xe(e)?e.map(i=>i.bind(t.proxy)):e.bind(t.proxy),t,n)}function ES(e,t,n,i){let r=i.includes(".")?fS(n,i):()=>n[i];if(pt(e)){let o=t[e];Te(o)&&mt(r,o)}else if(Te(e))mt(r,e.bind(n));else if(qe(e))if(xe(e))e.forEach(o=>ES(o,t,n,i));else{let o=Te(e.handler)?e.handler.bind(n):t[e.handler];Te(o)&&mt(r,o,e)}}function z0(e){let t=e.type,{mixins:n,extends:i}=t,{mixins:r,optionsCache:o,config:{optionMergeStrategies:a}}=e.appContext,s=o.get(t),l;return s?l=s:!r.length&&!n&&!i?l=t:(l={},r.length&&r.forEach(u=>Wd(l,u,a,!0)),Wd(l,t,a)),qe(t)&&o.set(t,l),l}function Wd(e,t,n,i=!1){let{mixins:r,extends:o}=t;o&&Wd(e,o,n,!0),r&&r.forEach(a=>Wd(e,a,n,!0));for(let a in t)if(!(i&&a==="expose")){let s=rO[a]||n&&n[a];e[a]=s?s(e[a],t[a]):t[a]}return e}function G$(e,t){return t?e?function(){return it(Te(e)?e.call(this,this):e,Te(t)?t.call(this,this):t)}:t:e}function nO(e,t){return Tl(x0(e),x0(t))}function x0(e){if(xe(e)){let t={};for(let n=0;n<e.length;n++)t[e[n]]=e[n];return t}return e}function dr(e,t){return e?[...new Set([].concat(e,t))]:t}function Tl(e,t){return e?it(Object.create(null),e,t):t}function J$(e,t){return e?xe(e)&&xe(t)?[...new Set([...e,...t])]:it(Object.create(null),Kd(e),Kd(t??{})):t}function iO(e,t){if(!e)return t;if(!t)return e;let n=it(Object.create(null),e);for(let i in t)n[i]=dr(e[i],t[i]);return n}function TS(){return{app:null,config:{isNativeTag:Fb,performance:!1,globalProperties:{},optionMergeStrategies:{},errorHandler:void 0,warnHandler:void 0,compilerOptions:{}},mixins:[],components:{},directives:{},provides:Object.create(null),optionsCache:new WeakMap,propsCache:new WeakMap,emitsCache:new WeakMap}}function aO(e,t){return function(i,r=null){Te(i)||(i=it({},i)),r!=null&&!qe(r)&&(r=null);let o=TS(),a=new WeakSet,s=[],l=!1,u=o.app={_uid:oO++,_component:i,_props:r,_container:null,_context:o,_instance:null,version:iS,get config(){return o.config},set config(d){},use(d,...p){return a.has(d)||(d&&Te(d.install)?(a.add(d),d.install(u,...p)):Te(d)&&(a.add(d),d(u,...p))),u},mixin(d){return __VUE_OPTIONS_API__&&(o.mixins.includes(d)||o.mixins.push(d)),u},component(d,p){return p?(o.components[d]=p,u):o.components[d]},directive(d,p){return p?(o.directives[d]=p,u):o.directives[d]},mount(d,p,m){if(!l){let f=u._ceVNode||be(i,r);return f.appContext=o,m===!0?m="svg":m===!1&&(m=void 0),p&&t?t(f,d):e(f,d,m),l=!0,u._container=d,d.__vue_app__=u,__VUE_PROD_DEVTOOLS__&&(u._instance=f.component,NA(u,iS)),op(f.component)}},onUnmount(d){s.push(d)},unmount(){l&&(Dr(s,u._instance,16),e(null,u._container),__VUE_PROD_DEVTOOLS__&&(u._instance=null,CA(u)),delete u._container.__vue_app__)},provide(d,p){return o.provides[d]=p,u},runWithContext(d){let p=Ca;Ca=u;try{return d()}finally{Ca=p}}};return u}}function NS(e,t,n=Ze){let i=Ua(),r=Ct(t),o=rn(t),a=CS(e,r),s=u0((l,u)=>{let d,p=Ze,m;return jA(()=>{let f=e[r];Rt(d,f)&&(d=f,u())}),{get(){return l(),n.get?n.get(d):d},set(f){let h=n.set?n.set(f):f;if(!Rt(h,d)&&!(p!==Ze&&Rt(f,p)))return;let v=i.vnode.props,k=!!(v&&(t in v||r in v||o in v)&&(`onUpdate:${t}`in v||`onUpdate:${r}`in v||`onUpdate:${o}`in v));k||(d=f,u()),i.emit(`update:${t}`,h),Rt(f,p)&&(Rt(f,h)&&!Rt(h,m)||k&&p!==Ze&&!Rt(h,d))&&u(),p=f,m=h}}});return s[Symbol.iterator]=()=>{let l=0;return{next(){return l<2?{value:l++?a||Ze:s,done:!1}:{done:!0}}}},s}function sO(e,t,...n){if(e.isUnmounted)return;let i=e.vnode.props||Ze,r=n,o=t.startsWith("update:"),a=o&&CS(i,t.slice(7));a&&(a.trim&&(r=n.map(d=>pt(d)?d.trim():d)),a.number&&(r=r.map(fl))),__VUE_PROD_DEVTOOLS__&&DA(e,t,r);let s,l=i[s=ml(t)]||i[s=ml(Ct(t))];!l&&o&&(l=i[s=ml(rn(t))]),l&&Dr(l,e,6,r);let u=i[s+"Once"];if(u){if(!e.emitted)e.emitted={};else if(e.emitted[s])return;e.emitted[s]=!0,Dr(u,e,6,r)}}function zS(e,t,n=!1){let i=__VUE_OPTIONS_API__&&n?lO:t.emitsCache,r=i.get(e);if(r!==void 0)return r;let o=e.emits,a={},s=!1;if(__VUE_OPTIONS_API__&&!Te(e)){let l=u=>{let d=zS(u,t,!0);d&&(s=!0,it(a,d))};!n&&t.mixins.length&&t.mixins.forEach(l),e.extends&&l(e.extends),e.mixins&&e.mixins.forEach(l)}return!o&&!s?(qe(e)&&i.set(e,null),null):(xe(o)?o.forEach(l=>a[l]=null):it(a,o),qe(e)&&i.set(e,a),a)}function ip(e,t){return!e||!va(t)?!1:(t=t.slice(2),t=t==="Once"?t:t.replace(/Once$/,""),Ke(e,t[0].toLowerCase()+t.slice(1))||Ke(e,rn(t))||Ke(e,t))}function h0(e){let{type:t,vnode:n,proxy:i,withProxy:r,propsOptions:[o],slots:a,attrs:s,emit:l,render:u,renderCache:d,props:p,data:m,setupState:f,ctx:h,inheritAttrs:v}=e,k=Bd(e),T,S;try{if(n.shapeFlag&4){let O=r||i,U=O;T=_n(u.call(U,O,d,p,f,m,h)),S=s}else{let O=t;T=_n(O.length>1?O(p,{attrs:s,slots:a,emit:l}):O(p,null)),S=t.props?s:cO(s)}}catch(O){Hn.length=0,Yd(O,e,1),T=be(Ft)}let z=T,j;if(S&&v!==!1){let O=Object.keys(S),{shapeFlag:U}=z;O.length&&U&7&&(o&&O.some(ba)&&(S=uO(S,o)),z=Ii(z,S,!1,!0))}if(n.dirs&&(z=Ii(z,null,!1,!0),z.dirs=z.dirs?z.dirs.concat(n.dirs):n.dirs),n.transition){let O=tp(z.type)&&Zd(z)||z;Sn(O,n.transition)}return T=z,Bd(k),T}function AS(e,t=!0){let n;for(let i=0;i<e.length;i++){let r=e[i];if(Oa(r)){if(r.type!==Ft||r.children==="v-if"){if(n)return;n=r}}else return}return n}function dO(e,t,n){let{props:i,children:r,component:o}=e,{props:a,children:s,patchFlag:l}=t,u=o.emitsOptions;if(t.dirs||t.transition)return!0;if(n&&l>=0){if(l&1024)return!0;if(l&16)return i?Y$(i,a,u):!!a;if(l&8){let d=t.dynamicProps;for(let p=0;p<d.length;p++){let m=d[p];if(OS(a,i,m)&&!ip(u,m))return!0}}}else return(r||s)&&(!s||!s.$stable)?!0:i===a?!1:i?a?Y$(i,a,u):!0:!!a;return!1}function Y$(e,t,n){let i=Object.keys(t);if(i.length!==Object.keys(e).length)return!0;for(let r=0;r<i.length;r++){let o=i[r];if(!Ke(e,o)||OS(t,e,o)&&!ip(n,o))return!0}return!1}function OS(e,t,n){let i=e[n],r=t[n];return n==="style"&&qe(i)&&qe(r)?!_a(i,r):i!==r}function pO({vnode:e,parent:t,suspense:n},i){for(;t;){let r=t.subTree;if(r.suspense&&r.suspense.activeBranch===e&&(r.suspense.vnode.el=r.el=i,e=r),r===e)(e=t.vnode).el=i,t=t.parent;else break}n&&n.activeBranch===e&&(n.vnode.el=i)}function mO(e,t,n,i=!1){let r={},o=PS();e.propsDefaults=Object.create(null),US(e,t,r,o);for(let a in e.propsOptions[0])a in r||(r[a]=void 0);n?e.props=i?r:Ea(r):e.type.props?e.props=r:e.props=o,e.attrs=o}function fO(e,t,n,i){let{props:r,attrs:o,vnode:{patchFlag:a}}=e,s=He(r),[l]=e.propsOptions,u=!1;if((i||a>0)&&!(a&16)){if(a&8){let d=e.vnode.dynamicProps;for(let p=0;p<d.length;p++){let m=d[p];if(ip(e.emitsOptions,m))continue;let f=t[m];if(l)if(Ke(o,m))f!==o[m]&&(o[m]=f,u=!0);else{let h=Ct(m);r[h]=_0(l,s,h,f,e,!1)}else f!==o[m]&&(o[m]=f,u=!0)}}}else{US(e,t,r,o)&&(u=!0);let d;for(let p in s)(!t||!Ke(t,p)&&((d=rn(p))===p||!Ke(t,d)))&&(l?n&&(n[p]!==void 0||n[d]!==void 0)&&(r[p]=_0(l,s,p,void 0,e,!0)):delete r[p]);if(o!==s)for(let p in o)(!t||!Ke(t,p))&&(delete o[p],u=!0)}u&&bn(e.attrs,"set","")}function US(e,t,n,i){let[r,o]=e.propsOptions,a=!1,s;if(t)for(let l in t){if(ya(l))continue;let u=t[l],d;r&&Ke(r,d=Ct(l))?!o||!o.includes(d)?n[d]=u:(s||(s={}))[d]=u:ip(e.emitsOptions,l)||(!(l in i)||u!==i[l])&&(i[l]=u,a=!0)}if(o){let l=He(n),u=s||Ze;for(let d=0;d<o.length;d++){let p=o[d];n[p]=_0(r,l,p,u[p],e,!Ke(u,p))}}return a}function _0(e,t,n,i,r,o){let a=e[n];if(a!=null){let s=Ke(a,"default");if(s&&i===void 0){let l=a.default;if(a.type!==Function&&!a.skipFactory&&Te(l)){let{propsDefaults:u}=r;if(n in u)i=u[n];else{let d=Ll(r);i=u[n]=l.call(null,t),d()}}else i=l;r.ce&&r.ce._setProp(n,i)}a[0]&&(o&&!s?i=!1:a[1]&&(i===""||i===rn(n))&&(i=!0))}return i}function jS(e,t,n=!1){let i=__VUE_OPTIONS_API__&&n?hO:t.propsCache,r=i.get(e);if(r)return r;let o=e.props,a={},s=[],l=!1;if(__VUE_OPTIONS_API__&&!Te(e)){let d=p=>{l=!0;let[m,f]=jS(p,t,!0);it(a,m),f&&s.push(...f)};!n&&t.mixins.length&&t.mixins.forEach(d),e.extends&&d(e.extends),e.mixins&&e.mixins.forEach(d)}if(!o&&!l)return qe(e)&&i.set(e,xi),xi;if(xe(o))for(let d=0;d<o.length;d++){let p=Ct(o[d]);X$(p)&&(a[p]=Ze)}else if(o)for(let d in o){let p=Ct(d);if(X$(p)){let m=o[d],f=a[p]=xe(m)||Te(m)?{type:m}:it({},m),h=f.type,v=!1,k=!0;if(xe(h))for(let T=0;T<h.length;++T){let S=h[T],z=Te(S)&&S.name;if(z==="Boolean"){v=!0;break}else z==="String"&&(k=!1)}else v=Te(h)&&h.name==="Boolean";f[0]=v,f[1]=k,(v||Ke(f,"default"))&&s.push(p)}}let u=[a,s];return qe(e)&&i.set(e,u),u}function X$(e){return e[0]!=="$"&&!ya(e)}function yO(){let e=[];typeof __VUE_OPTIONS_API__!="boolean"&&(_i().__VUE_OPTIONS_API__=!0),typeof __VUE_PROD_DEVTOOLS__!="boolean"&&(_i().__VUE_PROD_DEVTOOLS__=!1),typeof __VUE_PROD_HYDRATION_MISMATCH_DETAILS__!="boolean"&&(_i().__VUE_PROD_HYDRATION_MISMATCH_DETAILS__=!1)}function FS(e){return wO(e)}function wO(e,t){yO();let n=_i();n.__VUE__=!0,__VUE_PROD_DEVTOOLS__&&dS(n.__VUE_DEVTOOLS_GLOBAL_HOOK__,n);let{insert:i,remove:r,patchProp:o,createElement:a,createText:s,createComment:l,setText:u,setElementText:d,parentNode:p,nextSibling:m,setScopeId:f=ur,insertStaticContent:h}=e,v=(x,I,M,B=null,X=null,_=null,D=void 0,y=null,P=!!I.dynamicChildren)=>{if(x===I)return;x&&!io(x,I)&&(B=er(x),yt(x,X,_,!0),x=null),I.patchFlag===-2&&(P=!1,I.dynamicChildren=null),I.dynamicChildren&&x&&x.dynamicChildren&&x.dynamicChildren.hasOnce&&(I.dynamicChildren===xi&&(I.dynamicChildren=[]),I.dynamicChildren.hasOnce=!0);let{type:E,ref:Y,shapeFlag:ie}=I;switch(E){case Ml:k(x,I,M,B);break;case Ft:T(x,I,M,B);break;case za:x==null&&S(I,M,B,D);break;case ge:ue(x,I,M,B,X,_,D,y,P);break;default:ie&1?U(x,I,M,B,X,_,D,y,P):ie&6?Je(x,I,M,B,X,_,D,y,P):(ie&64||ie&128)&&E.process(x,I,M,B,X,_,D,y,P,fr)}Y!=null&&X?Nl(Y,x&&x.ref,_,I||x,!I):Y==null&&x&&x.ref!=null&&Nl(x.ref,null,_,x,!0)},k=(x,I,M,B)=>{if(x==null)i(I.el=s(I.children),M,B);else{let X=I.el=x.el;I.children!==x.children&&u(X,I.children)}},T=(x,I,M,B)=>{x==null?i(I.el=l(I.children||""),M,B):I.el=x.el},S=(x,I,M,B)=>{[x.el,x.anchor]=h(x.children,I,M,B,x.el,x.anchor)},z=(x,I,M,B)=>{if(I.children!==x.children){let X=m(x.anchor);O(x),[I.el,I.anchor]=h(I.children,M,X,B)}else I.el=x.el,I.anchor=x.anchor},j=({el:x,anchor:I},M,B)=>{let X;for(;x&&x!==I;)X=m(x),i(x,M,B),x=X;i(I,M,B)},O=({el:x,anchor:I})=>{let M;for(;x&&x!==I;)M=m(x),r(x),x=M;r(I)},U=(x,I,M,B,X,_,D,y,P)=>{if(I.type==="svg"?D="svg":I.type==="math"&&(D="mathml"),x==null)J(I,M,B,X,_,D,y,P);else{let E=x.el&&x.el._isVueCE?x.el:null;try{E&&E._beginPatch(),se(x,I,X,_,D,y,P)}finally{E&&E._endPatch()}}},J=(x,I,M,B,X,_,D,y)=>{let P,E,{props:Y,shapeFlag:ie,transition:fe,dirs:ve}=x;if(P=x.el=a(x.type,_,Y&&Y.is,Y),ie&8?d(P,x.children):ie&16&&ce(x.children,P,null,B,X,g0(x,_),D,y),ve&&to(x,null,B,"created"),W(P,x,x.scopeId,D,B),Y){for(let ye in Y)ye!=="value"&&!ya(ye)&&o(P,ye,null,Y[ye],_,B);"value"in Y&&o(P,"value",null,Y.value,_),(E=Y.onVnodeBeforeMount)&&kn(E,B,x)}__VUE_PROD_DEVTOOLS__&&(ka(P,"__vnode",x,!0),ka(P,"__vueParentComponent",B,!0)),ve&&to(x,null,B,"beforeMount");let we=kO(X,fe);we?fe.beforeEnter(P):fe&&!fe.persisted&&(P[_O]=!0),i(P,I,M),((E=Y&&Y.onVnodeMounted)||we||ve)&&rr(()=>{let Ne;E&&kn(E,B,x),we&&fe.enter(P),ve&&to(x,null,B,"mounted")},X)},W=(x,I,M,B,X)=>{if(M&&f(x,M),B)for(let _=0;_<B.length;_++)f(x,B[_]);if(X){let _=X.subTree;if(I===_||ZS(_.type)&&(_.ssContent===I||_.ssFallback===I)){let D=X.vnode;W(x,D,D.scopeId,D.slotScopeIds,X.parent)}}},ce=(x,I,M,B,X,_,D,y,P=0)=>{for(let E=P;E<x.length;E++){let Y=x[E]=y?Zn(x[E]):_n(x[E]);v(null,Y,I,M,B,X,_,D,y)}},se=(x,I,M,B,X,_,D)=>{let y=I.el=x.el;__VUE_PROD_DEVTOOLS__&&(y.__vnode=I);let{patchFlag:P,dynamicChildren:E,dirs:Y}=I;P|=x.patchFlag&16;let ie=x.props||Ze,fe=I.props||Ze,ve;if(M&&ro(M,!1),(ve=fe.onVnodeBeforeUpdate)&&kn(ve,M,I,x),Y&&to(I,x,M,"beforeUpdate"),M&&ro(M,!0),E&&(!x.dynamicChildren||x.dynamicChildren.length!==E.length)&&(P=0,D=!1,E=null),(ie.innerHTML&&fe.innerHTML==null||ie.textContent&&fe.textContent==null)&&d(y,""),E?pe(x.dynamicChildren,E,y,M,B,g0(I,X),_):D||Mt(x,I,y,null,M,B,g0(I,X),_,!1),P>0){if(P&16)F(y,ie,fe,M,X);else if(P&2&&ie.class!==fe.class&&o(y,"class",null,fe.class,X),P&4&&o(y,"style",ie.style,fe.style,X),P&8){let we=I.dynamicProps;for(let ye=0;ye<we.length;ye++){let Ne=we[ye],Me=ie[Ne],Xe=fe[Ne];(Xe!==Me||Ne==="value")&&o(y,Ne,Me,Xe,X,M)}}P&1&&x.children!==I.children&&d(y,I.children)}else!D&&E==null&&F(y,ie,fe,M,X);((ve=fe.onVnodeUpdated)||Y)&&rr(()=>{ve&&kn(ve,M,I,x),Y&&to(I,x,M,"updated")},B)},pe=(x,I,M,B,X,_,D)=>{for(let y=0;y<I.length;y++){let P=x[y],E=I[y],Y=P.el||zl(P),ie=Y&&(P.type===ge||!io(P,E)||P.shapeFlag&198)?p(Y):M;v(P,E,ie,null,B,X,_,D,!0)}},F=(x,I,M,B,X)=>{if(I!==M){if(I!==Ze)for(let _ in I)!ya(_)&&!(_ in M)&&o(x,_,I[_],null,X,B);for(let _ in M){if(ya(_))continue;let D=M[_],y=I[_];D!==y&&_!=="value"&&o(x,_,y,D,X,B)}"value"in M&&o(x,"value",I.value,M.value,X)}},ue=(x,I,M,B,X,_,D,y,P)=>{let E=I.el=x?x.el:s(""),Y=I.anchor=x?x.anchor:s(""),{patchFlag:ie,dynamicChildren:fe,slotScopeIds:ve}=I;ve&&(y=y?y.concat(ve):ve),x==null?(i(E,M,B),i(Y,M,B),ce(I.children||[],M,Y,X,_,D,y,P)):ie>0&&ie&64&&fe&&x.dynamicChildren&&x.dynamicChildren.length===fe.length?(pe(x.dynamicChildren,fe,M,X,_,D,y),(I.key!=null||X&&I===X.subTree)&&D0(x,I,!0)):Mt(x,I,M,Y,X,_,D,y,P)},Je=(x,I,M,B,X,_,D,y,P)=>{I.slotScopeIds=y,x==null?I.shapeFlag&512?X.ctx.activate(I,M,B,D,P):ct(I,M,B,X,_,D,P):ft(x,I,P)},ct=(x,I,M,B,X,_,D)=>{let y=x.component=TO(x,B,X);if(np(x)&&(y.ctx.renderer=fr),NO(y,!1,D),y.asyncDep){if(X&&X.registerDep(y,Re,D,_),!x.el){let P=y.subTree=be(Ft);T(null,P,I,M),x.placeholder=P.el}}else Re(y,x,I,M,X,_,D)},ft=(x,I,M)=>{let B=I.component=x.component;if(dO(x,I,M))if(B.asyncDep&&!B.asyncResolved){I.el=x.el,I.placeholder=x.placeholder,Be(B,I,M);return}else B.next=I,B.update();else I.el=x.el,I.placeholder=x.placeholder,B.vnode=I},Re=(x,I,M,B,X,_,D)=>{let y=()=>{if(x.isMounted){let{next:ie,bu:fe,u:ve,parent:we,vnode:ye}=x;{let $t=BS(x);if($t){ie&&(ie.el=ye.el,Be(x,ie,D)),$t.asyncDep.then(()=>{let St=()=>{x.job.flags&8||(X&&X.pendingBranch?rr(St,X):E())};St.flags=48,rr(St,X)});return}}let Ne=ie,Me;ro(x,!1),ie?(ie.el=ye.el,Be(x,ie,D)):ie=ye,fe&&wa(fe),(Me=ie.props&&ie.props.onVnodeBeforeUpdate)&&kn(Me,we,ie,ye),ro(x,!0);let Xe=h0(x),wt=x.subTree;x.subTree=Xe,v(wt,Xe,p(wt.el||zl(wt)),er(wt),x,X,_),ie.el=Xe.el,Ne===null&&pO(x,Xe.el),ve&&rr(ve,X),(Me=ie.props&&ie.props.onVnodeUpdated)&&rr(()=>kn(Me,we,ie,ye),X),__VUE_PROD_DEVTOOLS__&&pS(x)}else{let ie,{el:fe,props:ve}=I,{bm:we,m:ye,parent:Ne,root:Me,type:Xe}=x,wt=Na(I);if(ro(x,!1),we&&wa(we),!wt&&(ie=ve&&ve.onVnodeBeforeMount)&&kn(ie,Ne,I),ro(x,!0),fe&&hr){let $t=()=>{x.subTree=h0(x),hr(fe,x.subTree,x,X,null)};wt&&Xe.__asyncHydrate?Xe.__asyncHydrate(fe,x,$t):$t()}else{Me.ce&&Me.ce._hasShadowRoot()&&Me.ce._injectChildStyle(Xe,x.parent?x.parent.type:void 0);let $t=x.subTree=h0(x);v(null,$t,M,B,x,X,_),I.el=$t.el}if(ye&&rr(ye,X),!wt&&(ie=ve&&ve.onVnodeMounted)){let $t=I;rr(()=>kn(ie,Ne,$t),X)}(I.shapeFlag&256||Ne&&Na(Ne.vnode)&&Ne.vnode.shapeFlag&256)&&x.a&&rr(x.a,X),x.isMounted=!0,__VUE_PROD_DEVTOOLS__&&zA(x),I=M=B=null}};x.scope.on();let P=x.effect=new Sa(y);x.scope.off();let E=x.update=P.run.bind(P),Y=x.job=P.runIfDirty.bind(P);Y.i=x,Y.id=x.uid,P.scheduler=()=>Xd(Y),ro(x,!0),E()},Be=(x,I,M)=>{I.component=x;let B=x.vnode.props;x.vnode=I,x.next=null,fO(x,I.props,B,M),bO(x,I.children,M),on(),lS(x),an()},Mt=(x,I,M,B,X,_,D,y,P=!1)=>{let E=x&&x.children,Y=x?x.shapeFlag:0,ie=I.children,{patchFlag:fe,shapeFlag:ve}=I;if(fe>0){if(fe&128){mr(E,ie,M,B,X,_,D,y,P);return}else if(fe&256){Er(E,ie,M,B,X,_,D,y,P);return}}ve&8?(Y&16&&Ht(E,X,_),ie!==E&&d(M,ie)):Y&16?ve&16?mr(E,ie,M,B,X,_,D,y,P):Ht(E,X,_,!0):(Y&8&&d(M,""),ve&16&&ce(ie,M,B,X,_,D,y,P))},Er=(x,I,M,B,X,_,D,y,P)=>{x=x||xi,I=I||xi;let E=x.length,Y=I.length,ie=Math.min(E,Y),fe;for(fe=0;fe<ie;fe++){let ve=I[fe]=P?Zn(I[fe]):_n(I[fe]);v(x[fe],ve,M,null,X,_,D,y,P)}E>Y?Ht(x,X,_,!0,!1,ie):ce(I,M,B,X,_,D,y,P,ie)},mr=(x,I,M,B,X,_,D,y,P)=>{let E=0,Y=I.length,ie=x.length-1,fe=Y-1;for(;E<=ie&&E<=fe;){let ve=x[E],we=I[E]=P?Zn(I[E]):_n(I[E]);if(io(ve,we))v(ve,we,M,null,X,_,D,y,P);else break;E++}for(;E<=ie&&E<=fe;){let ve=x[ie],we=I[fe]=P?Zn(I[fe]):_n(I[fe]);if(io(ve,we))v(ve,we,M,null,X,_,D,y,P);else break;ie--,fe--}if(E>ie){if(E<=fe){let ve=fe+1,we=ve<Y?I[ve].el:B;for(;E<=fe;)v(null,I[E]=P?Zn(I[E]):_n(I[E]),M,we,X,_,D,y,P),E++}}else if(E>fe)for(;E<=ie;)yt(x[E],X,_,!0),E++;else{let ve=E,we=E,ye=new Map;for(E=we;E<=fe;E++){let vt=I[E]=P?Zn(I[E]):_n(I[E]);vt.key!=null&&ye.set(vt.key,E)}let Ne,Me=0,Xe=fe-we+1,wt=!1,$t=0,St=new Array(Xe);for(E=0;E<Xe;E++)St[E]=0;for(E=ve;E<=ie;E++){let vt=x[E];if(Me>=Xe){yt(vt,X,_,!0);continue}let Nt;if(vt.key!=null)Nt=ye.get(vt.key);else for(Ne=we;Ne<=fe;Ne++)if(St[Ne-we]===0&&io(vt,I[Ne])){Nt=Ne;break}Nt===void 0?yt(vt,X,_,!0):(St[Nt-we]=E+1,Nt>=$t?$t=Nt:wt=!0,v(vt,I[Nt],M,null,X,_,D,y,P),Me++)}let Kt=wt?xO(St):xi;for(Ne=Kt.length-1,E=Xe-1;E>=0;E--){let vt=we+E,Nt=I[vt],Gr=I[vt+1],$e=vt+1<Y?Gr.el||zl(Gr):B;St[E]===0?v(null,Nt,M,$e,X,_,D,y,P):wt&&(Ne<0||E!==Kt[Ne]?gt(Nt,M,$e,2):Ne--)}}},gt=(x,I,M,B,X=null)=>{let{el:_,type:D,transition:y,children:P,shapeFlag:E}=x;if(E&6){gt(x.component.subTree,I,M,B);return}if(E&128){x.suspense.move(I,M,B);return}if(E&64){D.move(x,I,M,fr);return}if(D===ge){i(_,I,M);for(let ie=0;ie<P.length;ie++)gt(P[ie],I,M,B);i(x.anchor,I,M);return}if(D===za){j(x,I,M);return}if(B!==2&&E&1&&y)if(B===0)y.persisted&&!_[Br]?i(_,I,M):(y.beforeEnter(_),i(_,I,M),rr(()=>y.enter(_),X));else{let{leave:ie,delayLeave:fe,afterLeave:ve}=y,we=()=>{x.ctx.isUnmounted?r(_):i(_,I,M)},ye=()=>{let Ne=_._isLeaving||!!_[Br];_._isLeaving&&_[Br](!0),y.persisted&&!Ne?we():ie(_,()=>{we(),ve&&ve()})};fe?fe(_,we,ye):ye()}else i(_,I,M)},yt=(x,I,M,B=!1,X=!1)=>{let{type:_,props:D,ref:y,children:P,dynamicChildren:E,shapeFlag:Y,patchFlag:ie,dirs:fe,cacheIndex:ve,memo:we}=x;if((ie===-2||E&&E.hasOnce)&&(X=!1),y!=null&&(on(),Nl(y,null,M,x,!0),an()),ve!=null&&(!x.ctx||x.ctx===I)&&(I.renderCache[ve]=void 0),Y&256&&I.ctx.deactivate(x))return;let ye=Y&1&&fe,Ne=!Na(x),Me;if(Ne&&(Me=D&&D.onVnodeBeforeUnmount)&&kn(Me,I,x),Y&6)Ye(x.component,M,B);else{if(Y&128){x.suspense.unmount(M,B);return}ye&&to(x,null,I,"beforeUnmount"),Y&64?x.type.remove(x,I,M,fr,B):E&&!E.hasOnce&&(_!==ge||ie>0&&ie&64)?Ht(E,I,M,!1,!0):(_===ge&&ie&384||!X&&Y&16)&&Ht(P,I,M),B&&Wr(x)}let Xe=we!=null&&ve==null;(Ne&&(Me=D&&D.onVnodeUnmounted)||ye||Xe)&&rr(()=>{Me&&kn(Me,I,x),ye&&to(x,null,I,"unmounted"),Xe&&(x.el=null)},M)},Wr=x=>{let{type:I,el:M,anchor:B,transition:X}=x,_=I===ge;if(_&&!X){Tt(M,B);return}if(I===za){O(x),X&&!X.persisted&&X.afterLeave&&X.afterLeave();return}let D=_?Ol(x):x,y=()=>{_?p(M)&&Tt(M,B):r(M),X&&!X.persisted&&X.afterLeave&&X.afterLeave()};if(D&&D.shapeFlag&1&&X&&!X.persisted){let{leave:P,delayLeave:E}=X,Y=D.el,ie=()=>P(Y,y);E?E(Y,y,ie):ie()}else y()},Tt=(x,I)=>{let M;for(;x!==I;)M=m(x),r(x),x=M;r(I)},Ye=(x,I,M)=>{let{bum:B,scope:X,job:_,subTree:D,um:y,m:P,a:E}=x;Q$(P),Q$(E),B&&wa(B),X.stop(),_?(_.flags|=8,yt(D,x,I,M)):D&&(D.transition=x.vnode.transition,yt(D,x,I,M)),y&&rr(y,I);let Y=()=>{x.isUnmounted=!0};Y.flags=16,rr(Y,I),__VUE_PROD_DEVTOOLS__&&OA(x)},Ht=(x,I,M,B=!1,X=!1,_=0)=>{for(let D=_;D<x.length;D++)yt(x[D],I,M,B,X)},er=x=>{if(x.shapeFlag&6)return er(x.component.subTree);if(x.shapeFlag&128)return x.suspense.next();let I=m(x.anchor||x.el),M=I&&I[hS];return M?m(M):I},Tr=(x,I,M)=>{let B=x&&I._vnode?void 0:x&&x.component?x.component.uid:EO();EA(()=>{x==null?I._vnode&&yt(I._vnode,null,null,!0):v(I._vnode||null,x,I,null,null,null,M),I._vnode=x},B)},fr={p:v,um:yt,m:gt,r:Wr,mt:ct,mc:ce,pc:Mt,pbc:pe,n:er,o:e},qr,hr;return t&&([qr,hr]=t(fr)),{render:Tr,hydrate:qr,createApp:aO(Tr,qr)}}function g0({type:e,props:t},n){return n==="svg"&&e==="foreignObject"||n==="mathml"&&e==="annotation-xml"&&t&&t.encoding&&t.encoding.includes("html")?void 0:n}function ro({effect:e,job:t},n){n?(e.flags|=32,t.flags|=4):(e.flags&=-33,t.flags&=-5)}function kO(e,t){return(!e||e&&!e.pendingBranch)&&t&&!t.persisted}function D0(e,t,n=!1){let i=e.children,r=t.children;if(xe(i)&&xe(r))for(let o=0;o<i.length;o++){let a=i[o],s=r[o];s.shapeFlag&1&&!s.dynamicChildren&&((s.patchFlag<=0||s.patchFlag===32)&&(s=r[o]=Zn(r[o]),s.el=a.el),!n&&s.patchFlag!==-2&&D0(a,s)),s.type===Ml&&(s.patchFlag===-1&&(s=r[o]=Zn(s)),s.el=a.el),s.type===Ft&&!s.el&&(s.el=a.el)}}function xO(e){let t=e.slice(),n=[0],i,r,o,a,s,l=e.length;for(i=0;i<l;i++){let u=e[i];if(u!==0){if(r=n[n.length-1],e[r]<u){t[i]=r,n.push(i);continue}for(o=0,a=n.length-1;o<a;)s=o+a>>1,e[n[s]]<u?o=s+1:a=s;u<e[n[o]]&&(o>0&&(t[i]=n[o-1]),n[o]=i)}}for(o=n.length,a=n[o-1];o-- >0;)n[o]=a,a=t[a];return n}function BS(e){let t=e.subTree.component;if(t)return t.asyncDep&&!t.asyncResolved?t:BS(t)}function Q$(e){if(e)for(let t=0;t<e.length;t++)e[t].flags|=8}function zl(e){if(e.placeholder)return e.placeholder;let t=e.component;if(t)return zl(t.subTree);let n=e.suspense;return n&&n.activeBranch?zl(n.activeBranch):null}function $O(e,t){t&&t.pendingBranch?xe(e)?t.effects.push(...e):t.effects.push(e):sS(e)}function w(e=!1){Hn.push(Or=e?null:[])}function P0(){Hn.pop(),Or=Hn[Hn.length-1]||null}function qd(e,t=!1){Pl+=e,e<0&&Or&&t&&(Or.hasOnce=!0)}function HS(e){return e.dynamicChildren=Pl>0?Or||xi:null,P0(),Pl>0&&Or&&Or.push(e),e}function $(e,t,n,i,r,o){return HS(b(e,t,n,i,r,o,!0))}function Fe(e,t,n,i,r){return HS(be(e,t,n,i,r,!0))}function Oa(e){return e?e.__v_isVNode===!0:!1}function io(e,t){return e.type===t.type&&e.key===t.key}function b(e,t=null,n=null,i=0,r=null,o=e===ge?0:1,a=!1,s=!1){let l={__v_isVNode:!0,__v_skip:!0,type:e,props:t,key:t&&KS(t),ref:t&&Vd(t),scopeId:mS,slotScopeIds:null,children:n,component:null,suspense:null,ssContent:null,ssFallback:null,dirs:null,transition:null,el:null,anchor:null,target:null,targetStart:null,targetAnchor:null,staticCount:0,shapeFlag:o,patchFlag:i,dynamicProps:r,dynamicChildren:null,appContext:null,ctx:Yt};return s?(Gd(l,n),o&128&&e.normalize(l)):n&&(l.shapeFlag|=pt(n)?8:16),Pl>0&&!a&&Or&&(l.patchFlag>0||o&6)&&l.patchFlag!==32&&Or.push(l),l}function SO(e,t=null,n=null,i=0,r=null,o=!1){if((!e||e===$S)&&(e=Ft),Oa(e)){let s=Ii(e,t,!0);return n&&Gd(s,n),Pl>0&&!o&&Or&&(s.shapeFlag&6?Or[Or.indexOf(e)]=s:Or.push(s)),s.patchFlag=-2,s}if(DO(e)&&(e=e.__vccOpts),t){t=Ra(t);let{class:s,style:l}=t;s&&!pt(s)&&(t.class=V(s)),qe(l)&&($l(l)&&!xe(l)&&(l=it({},l)),t.style=Se(l))}let a=pt(e)?1:ZS(e)?128:tp(e)?64:qe(e)?4:Te(e)?2:0;return b(e,t,n,i,r,a,o,!0)}function Ra(e){return e?$l(e)?it({},e):RS(e)?it({},e[YS]||e):e:null}function Ii(e,t,n=!1,i=!1){let{props:r,ref:o,patchFlag:a,children:s,transition:l}=e,u=t?R0(r||{},t):r,d={__v_isVNode:!0,__v_skip:!0,type:e.type,props:u,key:u&&KS(u),ref:t&&t.ref?n&&o?xe(o)?o.concat(Vd(t)):[o,Vd(t)]:Vd(t):o,scopeId:e.scopeId,slotScopeIds:e.slotScopeIds,children:s,target:e.target,targetStart:e.targetStart,targetAnchor:e.targetAnchor,staticCount:e.staticCount,shapeFlag:e.shapeFlag,patchFlag:t&&e.type!==ge?a===-1?16:a|16:a,dynamicProps:e.dynamicProps,dynamicChildren:e.dynamicChildren,appContext:e.appContext,dirs:e.dirs,transition:l,component:e.component,suspense:e.suspense,ssContent:e.ssContent&&Ii(e.ssContent),ssFallback:e.ssFallback&&Ii(e.ssFallback),placeholder:e.placeholder,el:e.el,anchor:e.anchor,ctx:e.ctx,ce:e.ce,cacheIndex:e.cacheIndex};return l&&i&&Sn(d,l.clone(d)),d}function xt(e=" ",t=0){return be(Ml,null,e,t)}function WS(e,t){let n=be(za,null,e);return n.staticCount=t,n}function te(e="",t=!1){return t?(w(),Fe(Ft,null,e)):be(Ft,null,e)}function _n(e){return e==null||typeof e=="boolean"?be(Ft):xe(e)?be(ge,null,e.slice()):Oa(e)?Zn(e):be(Ml,null,String(e))}function Zn(e){return e.el===null&&e.patchFlag!==-1||e.memo?e:Ii(e)}function Gd(e,t){let n=0,{shapeFlag:i}=e;if(t==null)t=null;else if(xe(t))n=16;else if(typeof t=="object")if(i&65){let r=t.default;r&&(r._c&&(r._d=!1),Gd(e,r()),r._c&&(r._d=!0));return}else{n=32;let r=t._;!r&&!RS(t)?t._ctx=Yt:r===3&&Yt&&(Yt.slots._===1?t._=1:(t._=2,e.patchFlag|=1024))}else if(Te(t)){if(i&65){Gd(e,{default:t});return}t={default:t,_ctx:Yt},n=32}else t=String(t),i&64?(n=16,t=[xt(t)]):n=8;e.children=t,e.shapeFlag|=n}function R0(...e){let t={};for(let n=0;n<e.length;n++){let i=e[n];for(let r in i)if(r==="class")t.class!==i.class&&(t.class=V([t.class,i.class]));else if(r==="style")t.style=Se([t.style,i.style]);else if(va(r)){let o=t[r],a=i[r];a&&o!==a&&!(xe(o)&&o.includes(a))?t[r]=o?[].concat(o,a):a:a==null&&o==null&&!ba(r)&&(t[r]=a)}else r!==""&&(t[r]=i[r])}return t}function kn(e,t,n,i=null){Dr(e,t,7,[n,i])}function EO(){return qS}function TO(e,t,n){let i=e.type,r=(t?t.appContext:e.appContext)||IO,o={uid:qS++,vnode:e,type:i,parent:t,appContext:r,root:null,next:null,subTree:null,effect:null,update:null,job:null,scope:new yl(!0),render:null,proxy:null,exposed:null,exposeProxy:null,withProxy:null,provides:t?t.provides:Object.create(r.provides),ids:t?t.ids:["",0,0],accessCache:null,renderCache:[],components:null,directives:null,propsOptions:jS(i,r),emitsOptions:zS(i,r),emit:null,emitted:null,propsDefaults:Ze,inheritAttrs:i.inheritAttrs,ctx:Ze,data:Ze,props:Ze,attrs:Ze,slots:Ze,refs:Ze,setupState:Ze,setupContext:null,suspense:n,suspenseId:n?n.pendingId:0,asyncDep:null,asyncResolved:!1,isMounted:!1,isUnmounted:!1,isDeactivated:!1,bc:null,c:null,bm:null,m:null,bu:null,u:null,um:null,bum:null,da:null,a:null,rtg:null,rtc:null,ec:null,sp:null};return o.ctx={_:o},o.root=t?t.root:o,o.emit=sO.bind(null,o),e.ce&&e.ce(o),o}function GS(e){return e.vnode.shapeFlag&4}function NO(e,t=!1,n=!1){t&&Rl(t);let{props:i,children:r}=e.vnode,o=GS(e);mO(e,i,o,t),vO(e,r,n||t);let a=o?CO(e,t):void 0;return t&&Rl(!1),a}function CO(e,t){let n=e.type;e.accessCache=Object.create(null),e.proxy=new Proxy(e.ctx,QA);let{setup:i}=n;if(i){on();let r=e.setupContext=i.length>1?AO(e):null,o=Ll(e),a=jl(i,e,0,[e.props,r]),s=Bb(a);if(an(),o(),(s||e.sp)&&!Na(e)&&wS(e),s){if(a.then(eS,eS),t)return a.then(l=>{Rl(!0);try{tS(e,l,t)}finally{Rl(!1)}}).catch(l=>{Yd(l,e,0,void 0,!0),e.ssrRender=(u,d)=>d("<!---->")});e.asyncDep=a}else tS(e,a,t)}else JS(e,t)}function tS(e,t,n){Te(t)?e.type.__ssrInlineRender?e.ssrRender=t:e.render=t:qe(t)&&(__VUE_PROD_DEVTOOLS__&&(e.devtoolsRawSetupState=t),e.setupState=jd(t)),JS(e,n)}function JS(e,t,n){let i=e.type;if(!e.render){if(!t&&rS&&!i.render){let r=i.template||__VUE_OPTIONS_API__&&z0(e).template;if(r){let{isCustomElement:o,compilerOptions:a}=e.appContext.config,{delimiters:s,compilerOptions:l}=i,u=it(it({isCustomElement:o,delimiters:s},a),l);i.render=rS(r,u)}}e.render=i.render||ur,nS&&nS(e)}if(__VUE_OPTIONS_API__){let r=Ll(e);on();try{eO(e)}finally{an(),r()}}}function AO(e){let t=n=>{e.exposed=n||{}};return{attrs:new Proxy(e.attrs,zO),slots:e.slots,emit:e.emit,expose:t}}function op(e){return e.exposed?e.exposeProxy||(e.exposeProxy=new Proxy(jd(c0(e.exposed)),{get(t,n){if(n in t)return t[n];if(n in Cl)return Cl[n](e)},has(t,n){return n in t||n in Cl}})):e.proxy}function OO(e,t=!0){return Te(e)?e.displayName||e.name:e.name||t&&e.__name}function DO(e){return Te(e)&&"__vccOpts"in e}function XS(e,t,n){try{qd(-1);let i=arguments.length;return i===2?qe(t)&&!xe(t)?Oa(t)?be(e,null,[t]):be(e,t):be(e,null,t):(i>3?n=Array.prototype.slice.call(arguments,2):i===3&&Oa(n)&&(n=[n]),be(e,t,n))}finally{qd(1)}}var pr,sn,xn,Si,Ta,oS,Fd,p0,Al,TA,$n,Il,v0,zA,pS,AA,OA,Yt,mS,RA,UA,$i,hS,tp,no,LA,B$,Z$,b0,VA,gS,Br,Sl,Fr,E0,BA,bS,Hd,KB,WB,Na,np,Kn,WA,Ut,xS,N0,Da,Wn,qA,GA,JA,_S,$S,w0,Cl,f0,QA,k0,rO,oO,Ca,CS,lO,cO,uO,DS,PS,RS,hO,A0,O0,gO,MS,LS,VS,vO,bO,rr,ZS,_O,ge,Ml,Ft,za,Hn,Or,Pl,KS,Vd,be,IO,qS,nr,Ua,Jd,Rl,Ll,eS,Ul,rS,nS,YS,zO,R,iS,U0=re(()=>{d0();d0();hl();hl();/**
|
|
71
71
|
* @vue/runtime-core v3.5.45
|
|
72
72
|
* (c) 2018-present Yuxi (Evan) You and Vue contributors
|
|
73
73
|
* @license MIT
|
|
74
|
-
**/pr=[],sn=-1,xn=[],Si=null,Ta=0,oS=Promise.resolve(),Fd=null;p0=!1;Al=e=>e.id==null?e.flags&2?-1:1/0:e.id;TA=!1,Il=[],v0=!1;zA=$0("component:added"),pS=$0("component:updated"),AA=$0("component:removed"),OA=e=>{$n&&typeof $n.cleanupBuffer=="function"&&!$n.cleanupBuffer(e)&&AA(e)};Yt=null,mS=null;RA=Symbol.for("v-scx"),UA=()=>{{let e=Ld(RA);return e}};$i=new WeakMap,hS=Symbol("_vte"),tp=e=>e.__isTeleport,no=e=>e&&(e.disabled||e.disabled===""),LA=e=>e&&(e.defer||e.defer===""),B$=e=>typeof SVGElement<"u"&&e instanceof SVGElement,Z$=e=>typeof MathMLElement=="function"&&e instanceof MathMLElement,b0=(e,t)=>{let n=e&&e.to;return pt(n)?t?t(n):null:n},VA={name:"Teleport",__isTeleport:!0,process(e,t,n,i,r,o,a,s,l,u){let{mc:d,pc:p,pbc:m,o:{insert:f,querySelector:h,createText:v,createComment:k,parentNode:T}}=u,S=no(t.props),{dynamicChildren:z}=t,j=(J,W,ce)=>{J.shapeFlag&16&&d(J.children,W,ce,r,o,a,s,l)},O=(J=t)=>{let W=no(J.props),ce=J.target=b0(J.props,h),se=y0(ce,J,v,f);ce&&(a!=="svg"&&B$(ce)?a="svg":a!=="mathml"&&Z$(ce)&&(a="mathml"),r&&r.isCE&&(r.ce._teleportTargets||(r.ce._teleportTargets=new Set)).add(ce),W||(j(J,ce,se),El(J,!1)))},U=J=>{let W=()=>{if($i.get(J)===W){if($i.delete(J),no(J.props)){let ce=T(J.el)||n;j(J,ce,J.anchor),El(J,!0)}O(J)}};$i.set(J,W),rr(W,o)};if(e==null){let J=t.el=v(""),W=t.anchor=v("");if(f(J,n,i),f(W,n,i),LA(t.props)||o&&o.pendingBranch){U(t);return}S&&(j(t,n,W),El(t,!0)),O()}else{t.el=e.el;let J=t.anchor=e.anchor,W=$i.get(e);if(W){W.flags|=8,$i.delete(e),U(t);return}t.targetStart=e.targetStart;let ce=t.target=e.target,se=t.targetAnchor=e.targetAnchor,pe=no(e.props),F=pe?n:ce,ue=pe?J:se;if(a==="svg"||B$(ce)?a="svg":(a==="mathml"||Z$(ce))&&(a="mathml"),z?(m(e.dynamicChildren,z,F,r,o,a,s),D0(e,t,!0)):l||p(e,t,F,ue,r,o,a,s,!1),S)pe?t.props&&e.props&&t.props.to!==e.props.to&&(t.props.to=e.props.to):Md(t,n,J,u,1);else if((t.props&&t.props.to)!==(e.props&&e.props.to)){let Je=b0(t.props,h);Je&&(t.target=Je,Md(t,Je,null,u,0))}else pe&&Md(t,ce,se,u,1);El(t,S)}},remove(e,t,n,{um:i,o:{remove:r}},o){let{shapeFlag:a,children:s,anchor:l,targetStart:u,targetAnchor:d,target:p,props:m}=e,f=no(m),h=o||!f,v=$i.get(e);if(v&&(v.flags|=8,$i.delete(e)),p&&(r(u),r(d)),o&&r(l),!v&&(f||p)&&a&16)for(let k=0;k<s.length;k++){let T=s[k];i(T,t,n,h,!!T.dynamicChildren)}},move:Md,hydrate:FA};gS=VA;Br=Symbol("_leaveCb"),Sl=Symbol("_enterCb");Fr=[Function,Array],E0={mode:String,appear:Boolean,persisted:Boolean,onBeforeEnter:Fr,onEnter:Fr,onAfterEnter:Fr,onEnterCancelled:Fr,onBeforeLeave:Fr,onLeave:Fr,onAfterLeave:Fr,onLeaveCancelled:Fr,onBeforeAppear:Fr,onAppear:Fr,onAfterAppear:Fr,onAppearCancelled:Fr},BA={name:"BaseTransition",props:E0,setup(e,{slots:t}){let n=Ua(),i=I0();return()=>{let r=t.default&&rp(t.default(),!0),o=r&&r.length?vS(r):n.subTree?te():void 0;if(!o)return;let a=He(e),{mode:s}=a;if(i.isLeaving)return m0(o);let l=Zd(o);if(!l)return m0(o);let u=Aa(l,a,i,n);l.type!==Ft&&Sn(l,u);let d=n.subTree&&Zd(n.subTree);if(d&&d.type!==Ft&&!io(d,l)&&Ol(n.subTree)){let p=Aa(d,a,i,n);if(Sn(d,p),s==="out-in"&&l.type!==Ft)return i.isLeaving=!0,p.afterLeave=()=>{if(i.isLeaving=!1,!(n.job.flags&8))if(n.effect.flags&2){let m=()=>{n.job.flags&8||n.update()};m.i=n,Xd(m)}else n.update();delete p.afterLeave,d=void 0},m0(o);s==="in-out"&&l.type!==Ft?p.delayLeave=(m,f,h)=>{let v=yS(i,d);v[String(d.key)]=d,m[Br]=()=>{f(),m[Br]=void 0,delete u.delayedLeave,d=void 0},u.delayedLeave=()=>{h(),delete u.delayedLeave,d=void 0}}:d=void 0}else d&&(d=void 0);return o}}};bS=BA;Hd=new WeakMap;ZB=_i().requestIdleCallback||(e=>setTimeout(e,1)),HB=_i().cancelIdleCallback||(e=>clearTimeout(e)),Na=e=>!!e.type.__asyncLoader,np=e=>e.type.__isKeepAlive;Kn=e=>(t,n=nr)=>{(!Ul||e==="sp")&&Dl(e,(...i)=>t(...i),n)},WA=Kn("bm"),Ut=Kn("m"),xS=Kn("bu"),N0=Kn("u"),Da=Kn("bum"),Wn=Kn("um"),qA=Kn("sp"),GA=Kn("rtg"),JA=Kn("rtc");_S="components",$S=Symbol.for("v-ndc");w0=e=>e?GS(e)?op(e):w0(e.parent):null,Cl=it(Object.create(null),{$:e=>e,$el:e=>e.vnode.el,$data:e=>e.data,$props:e=>e.props,$attrs:e=>e.attrs,$slots:e=>e.slots,$refs:e=>e.refs,$parent:e=>w0(e.parent),$root:e=>w0(e.root),$host:e=>e.ce,$emit:e=>e.emit,$options:e=>__VUE_OPTIONS_API__?z0(e):e.type,$forceUpdate:e=>e.f||(e.f=()=>{Xd(e.update)}),$nextTick:e=>e.n||(e.n=oo.bind(e.proxy)),$watch:e=>__VUE_OPTIONS_API__?MA.bind(e):ur}),f0=(e,t)=>e!==Ze&&!e.__isScriptSetup&&Ke(e,t),QA={get({_:e},t){if(t==="__v_skip")return!0;let{ctx:n,setupState:i,data:r,props:o,accessCache:a,type:s,appContext:l}=e;if(t[0]!=="$"){let m=a[t];if(m!==void 0)switch(m){case 1:return i[t];case 2:return r[t];case 4:return n[t];case 3:return o[t]}else{if(f0(i,t))return a[t]=1,i[t];if(__VUE_OPTIONS_API__&&r!==Ze&&Ke(r,t))return a[t]=2,r[t];if(Ke(o,t))return a[t]=3,o[t];if(n!==Ze&&Ke(n,t))return a[t]=4,n[t];(!__VUE_OPTIONS_API__||k0)&&(a[t]=0)}}let u=Cl[t],d,p;if(u)return t==="$attrs"&&Jt(e.attrs,"get",""),u(e);if((d=s.__cssModules)&&(d=d[t]))return d;if(n!==Ze&&Ke(n,t))return a[t]=4,n[t];if(p=l.config.globalProperties,Ke(p,t))return p[t]},set({_:e},t,n){let{data:i,setupState:r,ctx:o}=e;return f0(r,t)?(r[t]=n,!0):__VUE_OPTIONS_API__&&i!==Ze&&Ke(i,t)?(i[t]=n,!0):Ke(e.props,t)||t[0]==="$"&&t.slice(1)in e?!1:(o[t]=n,!0)},has({_:{data:e,setupState:t,accessCache:n,ctx:i,appContext:r,props:o,type:a}},s){let l;return!!(n[s]||__VUE_OPTIONS_API__&&e!==Ze&&s[0]!=="$"&&Ke(e,s)||f0(t,s)||Ke(o,s)||Ke(i,s)||Ke(Cl,s)||Ke(r.config.globalProperties,s)||(l=a.__cssModules)&&l[s])},defineProperty(e,t,n){return n.get!=null?e._.accessCache[t]=0:Ke(n,"value")&&this.set(e,t,n.value,null),Reflect.defineProperty(e,t,n)}};k0=!0;rO={data:G$,props:J$,emits:J$,methods:Tl,computed:Tl,beforeCreate:dr,created:dr,beforeMount:dr,mounted:dr,beforeUpdate:dr,updated:dr,beforeDestroy:dr,beforeUnmount:dr,destroyed:dr,unmounted:dr,activated:dr,deactivated:dr,errorCaptured:dr,serverPrefetch:dr,components:Tl,directives:Tl,watch:iO,provide:G$,inject:nO};oO=0;Ca=null;CS=(e,t)=>t==="modelValue"||t==="model-value"?e.modelModifiers:e[`${t}Modifiers`]||e[`${Ct(t)}Modifiers`]||e[`${rn(t)}Modifiers`];lO=new WeakMap;cO=e=>{let t;for(let n in e)(n==="class"||n==="style"||va(n))&&((t||(t={}))[n]=e[n]);return t},uO=(e,t)=>{let n={};for(let i in e)(!ba(i)||!(i.slice(9)in t))&&(n[i]=e[i]);return n};DS={},PS=()=>Object.create(DS),RS=e=>Object.getPrototypeOf(e)===DS;hO=new WeakMap;A0=e=>e==="_"||e==="_ctx"||e==="$stable",O0=e=>xe(e)?e.map(_n):[_n(e)],gO=(e,t,n)=>{if(t._n)return t;let i=ot((...r)=>O0(t(...r)),n);return i._c=!1,i},MS=(e,t,n)=>{let i=e._ctx;for(let r in e){if(A0(r))continue;let o=e[r];if(Te(o))t[r]=gO(r,o,i);else if(o!=null){let a=O0(o);t[r]=()=>a}}},LS=(e,t)=>{let n=O0(t);e.slots.default=()=>n},VS=(e,t,n)=>{for(let i in t)(n||!A0(i))&&(e[i]=t[i])},vO=(e,t,n)=>{let i=e.slots=PS();if(e.vnode.shapeFlag&32){let r=t._;r?(VS(i,t,n),n&&ka(i,"_",r,!0)):MS(t,i)}else t&&LS(e,t)},bO=(e,t,n)=>{let{vnode:i,slots:r}=e,o=!0,a=Ze;if(i.shapeFlag&32){let s=t._;s?n&&s===1?o=!1:VS(r,t,n):(o=!t.$stable,MS(t,r)),a=t}else t&&(LS(e,t),a={default:1});if(o)for(let s in r)!A0(s)&&a[s]==null&&delete r[s]};rr=$O;ZS=e=>e.__isSuspense,_O=Symbol("_deferredEnter");ge=Symbol.for("v-fgt"),Ml=Symbol.for("v-txt"),Ft=Symbol.for("v-cmt"),za=Symbol.for("v-stc"),Hn=[],Or=null;Pl=1;KS=({key:e})=>e??null,Vd=({ref:e,ref_key:t,ref_for:n})=>(typeof e=="number"&&(e=""+e),e!=null?pt(e)||Vt(e)||Te(e)?{i:Yt,r:e,k:t,f:!!n}:e:null);be=SO;IO=TS(),qS=0;nr=null,Ua=()=>nr||Yt;{let e=_i(),t=(n,i)=>{let r;return(r=e[n])||(r=e[n]=[]),r.push(i),o=>{r.length>1?r.forEach(a=>a(o)):r[0](o)}};Jd=t("__VUE_INSTANCE_SETTERS__",n=>nr=n),Rl=t("__VUE_SSR_SETTERS__",n=>Ul=n)}Ll=e=>{let t=nr;return Jd(e),e.scope.on(),()=>{e.scope.off(),Jd(t)}},eS=()=>{nr&&nr.scope.off(),Jd(null)};Ul=!1;YS=Symbol(),zO={get(e,t){return Jt(e,"get",""),t===YS?e:e[t]}};R=(e,t)=>L$(e,t,Ul);iS="3.5.45"});function k2(e){let t={};for(let F in e)F in y2||(t[F]=e[F]);if(e.css===!1)return t;let{name:n="v",type:i,duration:r,enterFromClass:o=`${n}-enter-from`,enterActiveClass:a=`${n}-enter-active`,enterToClass:s=`${n}-enter-to`,appearFromClass:l=o,appearActiveClass:u=a,appearToClass:d=s,leaveFromClass:p=`${n}-leave-from`,leaveActiveClass:m=`${n}-leave-active`,leaveToClass:f=`${n}-leave-to`}=e,h=MO(r),v=h&&h[0],k=h&&h[1],{onBeforeEnter:T,onEnter:S,onEnterCancelled:z,onLeave:j,onLeaveCancelled:O,onBeforeAppear:U=T,onAppear:J=S,onAppearCancelled:W=z}=t,ce=(F,ue,Je,ct)=>{F._enterCancelled=ct,Ti(F,ue?d:s),Ti(F,ue?u:a),Je&&Je()},se=(F,ue)=>{F._isLeaving=!1,Ti(F,p),Ti(F,f),Ti(F,m),ue&&ue()},pe=F=>(ue,Je)=>{let ct=F?J:S,ft=()=>ce(ue,F,Je);ao(ct,[ue,ft]),r2(()=>{Ti(ue,F?l:o),In(ue,F?d:s),t2(ct)||n2(ue,i,v,ft)})};return it(t,{onBeforeEnter(F){ao(T,[F]),In(F,o),In(F,a)},onBeforeAppear(F){ao(U,[F]),In(F,l),In(F,u)},onEnter:pe(!1),onAppear:pe(!0),onLeave(F,ue){F._isLeaving=!0;let Je=()=>se(F,ue);In(F,p),F._enterCancelled?(In(F,m),B0(F)):(B0(F),In(F,m)),r2(()=>{F._isLeaving&&(Ti(F,p),In(F,f),t2(j)||n2(F,i,k,Je))}),ao(j,[F,Je])},onEnterCancelled(F){ce(F,!1,void 0,!0),ao(z,[F])},onAppearCancelled(F){ce(F,!0,void 0,!0),ao(W,[F])},onLeaveCancelled(F){se(F),ao(O,[F])}})}function MO(e){if(e==null)return null;if(qe(e))return[j0(e.enter),j0(e.leave)];{let t=j0(e);return[t,t]}}function j0(e){return Hb(e)}function In(e,t){t.split(/\s+/).forEach(n=>n&&e.classList.add(n)),(e[Ma]||(e[Ma]=new Set)).add(t)}function Ti(e,t){t.split(/\s+/).forEach(i=>i&&e.classList.remove(i));let n=e[Ma];n&&(n.delete(t),n.size||(e[Ma]=void 0))}function r2(e){requestAnimationFrame(()=>{requestAnimationFrame(e)})}function n2(e,t,n,i){let r=e._endId=++LO,o=()=>{r===e._endId&&i()};if(n!=null)return setTimeout(o,n);let{type:a,timeout:s,propCount:l}=x2(e,t);if(!a)return i();let u=a+"end",d=0,p=()=>{e.removeEventListener(u,m),o()},m=f=>{f.target===e&&++d>=l&&p()};setTimeout(()=>{d<l&&p()},s+1),e.addEventListener(u,m)}function x2(e,t){let n=window.getComputedStyle(e),i=h=>(n[h]||"").split(", "),r=i(`${Ei}Delay`),o=i(`${Ei}Duration`),a=i2(r,o),s=i(`${Vl}Delay`),l=i(`${Vl}Duration`),u=i2(s,l),d=null,p=0,m=0;t===Ei?a>0&&(d=Ei,p=a,m=o.length):t===Vl?u>0&&(d=Vl,p=u,m=l.length):(p=Math.max(a,u),d=p>0?a>u?Ei:Vl:null,m=d?d===Ei?o.length:l.length:0);let f=d===Ei&&/\b(?:transform|all)(?:,|$)/.test(i(`${Ei}Property`).toString());return{type:d,timeout:p,propCount:m,hasTransform:f}}function i2(e,t){for(;e.length<t.length;)e=e.concat(e);return Math.max(...t.map((n,i)=>o2(n)+o2(e[i])))}function o2(e){return e==="auto"?0:Number(e.slice(0,-1).replace(",","."))*1e3}function B0(e){return(e?e.ownerDocument:document).body.offsetHeight}function VO(e,t,n){let i=e[Ma];i&&(t=(t?[t,...i]:[...i]).join(" ")),t==null?e.removeAttribute("class"):n?e.setAttribute("class",t):e.className=t}function ZO(e,t,n){let i=e.style,r=pt(n),o=!1;if(n&&!r){if(t)if(pt(t))for(let a of t.split(";")){let s=a.slice(0,a.indexOf(":")).trim();n[s]==null&&Fl(i,s,"")}else for(let a in t)n[a]==null&&Fl(i,a,"");for(let a in n){a==="display"&&(o=!0);let s=n[a];s!=null?KO(e,a,!pt(t)&&t?t[a]:void 0,s)||Fl(i,a,s):Fl(i,a,"")}}else if(r){if(t!==n){let a=i[FO];a&&(n+=";"+a),i.cssText=n,o=BO.test(n)}}else t&&e.removeAttribute("style");a2 in e&&((!r||t!==n)&&(e[a2]=o?i.display:""),e[_2]&&(i.display="none"))}function Fl(e,t,n){if(xe(n))n.forEach(i=>Fl(e,t,i));else if(n==null&&(n=""),t.startsWith("--"))ap.test(n)?e.setProperty(t,n.replace(ap,""),"important"):e.setProperty(t,n);else{let i=HO(e,t);ap.test(n)?e.setProperty(rn(i),n.replace(ap,""),"important"):e[i]=n}}function HO(e,t){let n=M0[t];if(n)return n;let i=Ct(t);if(i!=="filter"&&i in e)return M0[t]=i;i=Xi(i);for(let r=0;r<s2.length;r++){let o=s2[r]+i;if(o in e)return M0[t]=o}return t}function KO(e,t,n,i){return e.tagName==="TEXTAREA"&&(t==="width"||t==="height")&&pt(i)&&n===i}function c2(e,t,n,i,r,o=w$(t)){i&&t.startsWith("xlink:")?n==null?e.removeAttributeNS(l2,t.slice(6,t.length)):e.setAttributeNS(l2,t,n):n==null||o&&!Cd(n)?e.removeAttribute(t):e.setAttribute(t,o?"":_r(n)?String(n):n)}function u2(e,t,n,i,r){if(t==="innerHTML"||t==="textContent"){n!=null&&(e[t]=t==="innerHTML"?b2(n):n);return}let o=e.tagName;if(t==="value"&&o!=="PROGRESS"&&!o.includes("-")){let s=o==="OPTION"?e.getAttribute("value")||"":e.value,l=n==null?e.type==="checkbox"?"on":"":String(n);(s!==l||!("_value"in e))&&(e.value=l),n==null&&e.removeAttribute(t),e._value=n;return}let a=!1;if(n===""||n==null){let s=typeof e[t];s==="boolean"?n=Cd(n):n==null&&s==="string"?(n="",a=!0):s==="number"&&(n=0,a=!0)}try{e[t]=n}catch{}a&&e.removeAttribute(r||t)}function ja(e,t,n,i){e.addEventListener(t,n,i)}function WO(e,t,n,i){e.removeEventListener(t,n,i)}function qO(e,t,n,i,r=null){let o=e[d2]||(e[d2]={}),a=o[t];if(i&&a)a.value=i;else{let[s,l]=YO(t);if(i){let u=o[t]=e6(i,r);ja(e,s,u,l)}else a&&(WO(e,s,a,l),o[t]=void 0)}}function YO(e){let t,n;for(;(n=e.match(GO))&&!JO.test(e);)t||(t={}),e=e.slice(0,e.length-n[1].length),t[n[1].toLowerCase()]=!0;return[e[2]===":"?e.slice(3):rn(e.slice(2)),t]}function e6(e,t){let n=i=>{if(!i._vts)i._vts=Date.now();else if(i._vts<=n.attached)return;let r=n.value;if(xe(r)){let o=i.stopImmediatePropagation;i.stopImmediatePropagation=()=>{o.call(i),i._stopped=!0};let a=r.slice(),s=[i];for(let l=0;l<a.length&&!i._stopped;l++){let u=a[l];u&&Dr(u,t,5,s)}}else Dr(r,t,5,[i])};return n.value=e,n.attached=QO(),n}function r6(e,t,n,i){if(i)return!!(t==="innerHTML"||t==="textContent"||t in e&&p2(t)&&Te(n));if(t==="spellcheck"||t==="draggable"||t==="translate"||t==="autocorrect"||t==="sandbox"&&e.tagName==="IFRAME"||t==="form"||t==="list"&&e.tagName==="INPUT"||t==="type"&&e.tagName==="TEXTAREA")return!1;if(t==="width"||t==="height"){let r=e.tagName;if(r==="IMG"||r==="VIDEO"||r==="CANVAS"||r==="SOURCE")return!1}return p2(t)&&pt(n)?!1:t in e}function n6(e,t){let n=e._def.props;if(!n)return!1;let i=Ct(t);return Array.isArray(n)?n.some(r=>Ct(r)===i):Object.keys(n).some(r=>Ct(r)===i)}function a6(e){let t=e.el;t[cp]&&t[cp](),t[m2]&&t[m2]()}function f2(e){return e.moveClass||`${e.name||"v"}-move`}function s6(e,t){S2.set(e,up(e.el,t))}function l6(e){let t=$2.get(e),n=S2.get(e),i=t.left-n.left,r=t.top-n.top;if(i||r){let o=e.el,a=o.style,s=o.getBoundingClientRect(),l=1,u=1;return o.offsetWidth&&(l=s.width/o.offsetWidth),o.offsetHeight&&(u=s.height/o.offsetHeight),(!Number.isFinite(l)||l===0)&&(l=1),(!Number.isFinite(u)||u===0)&&(u=1),Math.abs(l-1)<.01&&(l=1),Math.abs(u-1)<.01&&(u=1),a.transform=a.webkitTransform=`translate(${i/l}px,${r/u}px)`,a.transitionDuration="0s",e}}function up(e,t){let n=e.getBoundingClientRect();return{left:n.left-(t?t.left:0),top:n.top-(t?t.top:0)}}function c6(e){let t;for(let n=e.parent;n;n=n.parent){let i=Z0.get(n);if(i){let r=u6(n.vnode.el,e.vnode.el);r&&(t||(t=[])).push(it(up(r),{item:r,willMove:i}))}}return t}function u6(e,t){let n=e.nodeType===1?e:e.parentNode;for(;t&&t.parentNode!==n;)t=t.parentNode;if(t&&t.nodeType===1)return t}function d6(e,t){let n=e.find(i=>i.willMove()&&i.item.contains(t));return n&&up(n.item,n)}function p6(e,t,n){let i=e.cloneNode(),r=e[Ma];r&&r.forEach(s=>{s.split(/\s+/).forEach(l=>l&&i.classList.remove(l))}),n.split(/\s+/).forEach(s=>s&&i.classList.add(s)),i.style.display="none";let o=t.nodeType===1?t:t.parentNode;o.appendChild(i);let{hasTransform:a}=x2(i);return o.removeChild(i),a}function m6(e){e.target.composing=!0}function g2(e){let t=e.target;t.composing&&(t.composing=!1,t.dispatchEvent(new Event("input")))}function V0(e,t,n){return t&&(e=e.trim()),n&&(e=fl(e)),e}function b6(){return v2||(v2=FS(v6))}function y6(e){if(e instanceof SVGElement)return"svg";if(typeof MathMLElement=="function"&&e instanceof MathMLElement)return"mathml"}function w6(e){return pt(e)?document.querySelector(e):e}var F0,QS,b2,PO,RO,qn,e2,UO,Ei,Vl,Ma,y2,w2,jO,so,ao,t2,LO,a2,_2,FO,BO,ap,s2,M0,l2,d2,GO,JO,L0,XO,QO,p2,t6,$2,S2,cp,m2,Z0,i6,o6,H0,h2,sp,lp,dp,f6,h6,Et,g6,Gn,v6,v2,Bl,I2=re(()=>{U0();U0();hl();/**
|
|
74
|
+
**/pr=[],sn=-1,xn=[],Si=null,Ta=0,oS=Promise.resolve(),Fd=null;p0=!1;Al=e=>e.id==null?e.flags&2?-1:1/0:e.id;TA=!1,Il=[],v0=!1;zA=$0("component:added"),pS=$0("component:updated"),AA=$0("component:removed"),OA=e=>{$n&&typeof $n.cleanupBuffer=="function"&&!$n.cleanupBuffer(e)&&AA(e)};Yt=null,mS=null;RA=Symbol.for("v-scx"),UA=()=>{{let e=Ld(RA);return e}};$i=new WeakMap,hS=Symbol("_vte"),tp=e=>e.__isTeleport,no=e=>e&&(e.disabled||e.disabled===""),LA=e=>e&&(e.defer||e.defer===""),B$=e=>typeof SVGElement<"u"&&e instanceof SVGElement,Z$=e=>typeof MathMLElement=="function"&&e instanceof MathMLElement,b0=(e,t)=>{let n=e&&e.to;return pt(n)?t?t(n):null:n},VA={name:"Teleport",__isTeleport:!0,process(e,t,n,i,r,o,a,s,l,u){let{mc:d,pc:p,pbc:m,o:{insert:f,querySelector:h,createText:v,createComment:k,parentNode:T}}=u,S=no(t.props),{dynamicChildren:z}=t,j=(J,W,ce)=>{J.shapeFlag&16&&d(J.children,W,ce,r,o,a,s,l)},O=(J=t)=>{let W=no(J.props),ce=J.target=b0(J.props,h),se=y0(ce,J,v,f);ce&&(a!=="svg"&&B$(ce)?a="svg":a!=="mathml"&&Z$(ce)&&(a="mathml"),r&&r.isCE&&(r.ce._teleportTargets||(r.ce._teleportTargets=new Set)).add(ce),W||(j(J,ce,se),El(J,!1)))},U=J=>{let W=()=>{if($i.get(J)===W){if($i.delete(J),no(J.props)){let ce=T(J.el)||n;j(J,ce,J.anchor),El(J,!0)}O(J)}};$i.set(J,W),rr(W,o)};if(e==null){let J=t.el=v(""),W=t.anchor=v("");if(f(J,n,i),f(W,n,i),LA(t.props)||o&&o.pendingBranch){U(t);return}S&&(j(t,n,W),El(t,!0)),O()}else{t.el=e.el;let J=t.anchor=e.anchor,W=$i.get(e);if(W){W.flags|=8,$i.delete(e),U(t);return}t.targetStart=e.targetStart;let ce=t.target=e.target,se=t.targetAnchor=e.targetAnchor,pe=no(e.props),F=pe?n:ce,ue=pe?J:se;if(a==="svg"||B$(ce)?a="svg":(a==="mathml"||Z$(ce))&&(a="mathml"),z?(m(e.dynamicChildren,z,F,r,o,a,s),D0(e,t,!0)):l||p(e,t,F,ue,r,o,a,s,!1),S)pe?t.props&&e.props&&t.props.to!==e.props.to&&(t.props.to=e.props.to):Md(t,n,J,u,1);else if((t.props&&t.props.to)!==(e.props&&e.props.to)){let Je=b0(t.props,h);Je&&(t.target=Je,Md(t,Je,null,u,0))}else pe&&Md(t,ce,se,u,1);El(t,S)}},remove(e,t,n,{um:i,o:{remove:r}},o){let{shapeFlag:a,children:s,anchor:l,targetStart:u,targetAnchor:d,target:p,props:m}=e,f=no(m),h=o||!f,v=$i.get(e);if(v&&(v.flags|=8,$i.delete(e)),p&&(r(u),r(d)),o&&r(l),!v&&(f||p)&&a&16)for(let k=0;k<s.length;k++){let T=s[k];i(T,t,n,h,!!T.dynamicChildren)}},move:Md,hydrate:FA};gS=VA;Br=Symbol("_leaveCb"),Sl=Symbol("_enterCb");Fr=[Function,Array],E0={mode:String,appear:Boolean,persisted:Boolean,onBeforeEnter:Fr,onEnter:Fr,onAfterEnter:Fr,onEnterCancelled:Fr,onBeforeLeave:Fr,onLeave:Fr,onAfterLeave:Fr,onLeaveCancelled:Fr,onBeforeAppear:Fr,onAppear:Fr,onAfterAppear:Fr,onAppearCancelled:Fr},BA={name:"BaseTransition",props:E0,setup(e,{slots:t}){let n=Ua(),i=I0();return()=>{let r=t.default&&rp(t.default(),!0),o=r&&r.length?vS(r):n.subTree?te():void 0;if(!o)return;let a=He(e),{mode:s}=a;if(i.isLeaving)return m0(o);let l=Zd(o);if(!l)return m0(o);let u=Aa(l,a,i,n);l.type!==Ft&&Sn(l,u);let d=n.subTree&&Zd(n.subTree);if(d&&d.type!==Ft&&!io(d,l)&&Ol(n.subTree)){let p=Aa(d,a,i,n);if(Sn(d,p),s==="out-in"&&l.type!==Ft)return i.isLeaving=!0,p.afterLeave=()=>{if(i.isLeaving=!1,!(n.job.flags&8))if(n.effect.flags&2){let m=()=>{n.job.flags&8||n.update()};m.i=n,Xd(m)}else n.update();delete p.afterLeave,d=void 0},m0(o);s==="in-out"&&l.type!==Ft?p.delayLeave=(m,f,h)=>{let v=yS(i,d);v[String(d.key)]=d,m[Br]=()=>{f(),m[Br]=void 0,delete u.delayedLeave,d=void 0},u.delayedLeave=()=>{h(),delete u.delayedLeave,d=void 0}}:d=void 0}else d&&(d=void 0);return o}}};bS=BA;Hd=new WeakMap;KB=_i().requestIdleCallback||(e=>setTimeout(e,1)),WB=_i().cancelIdleCallback||(e=>clearTimeout(e)),Na=e=>!!e.type.__asyncLoader,np=e=>e.type.__isKeepAlive;Kn=e=>(t,n=nr)=>{(!Ul||e==="sp")&&Dl(e,(...i)=>t(...i),n)},WA=Kn("bm"),Ut=Kn("m"),xS=Kn("bu"),N0=Kn("u"),Da=Kn("bum"),Wn=Kn("um"),qA=Kn("sp"),GA=Kn("rtg"),JA=Kn("rtc");_S="components",$S=Symbol.for("v-ndc");w0=e=>e?GS(e)?op(e):w0(e.parent):null,Cl=it(Object.create(null),{$:e=>e,$el:e=>e.vnode.el,$data:e=>e.data,$props:e=>e.props,$attrs:e=>e.attrs,$slots:e=>e.slots,$refs:e=>e.refs,$parent:e=>w0(e.parent),$root:e=>w0(e.root),$host:e=>e.ce,$emit:e=>e.emit,$options:e=>__VUE_OPTIONS_API__?z0(e):e.type,$forceUpdate:e=>e.f||(e.f=()=>{Xd(e.update)}),$nextTick:e=>e.n||(e.n=oo.bind(e.proxy)),$watch:e=>__VUE_OPTIONS_API__?MA.bind(e):ur}),f0=(e,t)=>e!==Ze&&!e.__isScriptSetup&&Ke(e,t),QA={get({_:e},t){if(t==="__v_skip")return!0;let{ctx:n,setupState:i,data:r,props:o,accessCache:a,type:s,appContext:l}=e;if(t[0]!=="$"){let m=a[t];if(m!==void 0)switch(m){case 1:return i[t];case 2:return r[t];case 4:return n[t];case 3:return o[t]}else{if(f0(i,t))return a[t]=1,i[t];if(__VUE_OPTIONS_API__&&r!==Ze&&Ke(r,t))return a[t]=2,r[t];if(Ke(o,t))return a[t]=3,o[t];if(n!==Ze&&Ke(n,t))return a[t]=4,n[t];(!__VUE_OPTIONS_API__||k0)&&(a[t]=0)}}let u=Cl[t],d,p;if(u)return t==="$attrs"&&Jt(e.attrs,"get",""),u(e);if((d=s.__cssModules)&&(d=d[t]))return d;if(n!==Ze&&Ke(n,t))return a[t]=4,n[t];if(p=l.config.globalProperties,Ke(p,t))return p[t]},set({_:e},t,n){let{data:i,setupState:r,ctx:o}=e;return f0(r,t)?(r[t]=n,!0):__VUE_OPTIONS_API__&&i!==Ze&&Ke(i,t)?(i[t]=n,!0):Ke(e.props,t)||t[0]==="$"&&t.slice(1)in e?!1:(o[t]=n,!0)},has({_:{data:e,setupState:t,accessCache:n,ctx:i,appContext:r,props:o,type:a}},s){let l;return!!(n[s]||__VUE_OPTIONS_API__&&e!==Ze&&s[0]!=="$"&&Ke(e,s)||f0(t,s)||Ke(o,s)||Ke(i,s)||Ke(Cl,s)||Ke(r.config.globalProperties,s)||(l=a.__cssModules)&&l[s])},defineProperty(e,t,n){return n.get!=null?e._.accessCache[t]=0:Ke(n,"value")&&this.set(e,t,n.value,null),Reflect.defineProperty(e,t,n)}};k0=!0;rO={data:G$,props:J$,emits:J$,methods:Tl,computed:Tl,beforeCreate:dr,created:dr,beforeMount:dr,mounted:dr,beforeUpdate:dr,updated:dr,beforeDestroy:dr,beforeUnmount:dr,destroyed:dr,unmounted:dr,activated:dr,deactivated:dr,errorCaptured:dr,serverPrefetch:dr,components:Tl,directives:Tl,watch:iO,provide:G$,inject:nO};oO=0;Ca=null;CS=(e,t)=>t==="modelValue"||t==="model-value"?e.modelModifiers:e[`${t}Modifiers`]||e[`${Ct(t)}Modifiers`]||e[`${rn(t)}Modifiers`];lO=new WeakMap;cO=e=>{let t;for(let n in e)(n==="class"||n==="style"||va(n))&&((t||(t={}))[n]=e[n]);return t},uO=(e,t)=>{let n={};for(let i in e)(!ba(i)||!(i.slice(9)in t))&&(n[i]=e[i]);return n};DS={},PS=()=>Object.create(DS),RS=e=>Object.getPrototypeOf(e)===DS;hO=new WeakMap;A0=e=>e==="_"||e==="_ctx"||e==="$stable",O0=e=>xe(e)?e.map(_n):[_n(e)],gO=(e,t,n)=>{if(t._n)return t;let i=ot((...r)=>O0(t(...r)),n);return i._c=!1,i},MS=(e,t,n)=>{let i=e._ctx;for(let r in e){if(A0(r))continue;let o=e[r];if(Te(o))t[r]=gO(r,o,i);else if(o!=null){let a=O0(o);t[r]=()=>a}}},LS=(e,t)=>{let n=O0(t);e.slots.default=()=>n},VS=(e,t,n)=>{for(let i in t)(n||!A0(i))&&(e[i]=t[i])},vO=(e,t,n)=>{let i=e.slots=PS();if(e.vnode.shapeFlag&32){let r=t._;r?(VS(i,t,n),n&&ka(i,"_",r,!0)):MS(t,i)}else t&&LS(e,t)},bO=(e,t,n)=>{let{vnode:i,slots:r}=e,o=!0,a=Ze;if(i.shapeFlag&32){let s=t._;s?n&&s===1?o=!1:VS(r,t,n):(o=!t.$stable,MS(t,r)),a=t}else t&&(LS(e,t),a={default:1});if(o)for(let s in r)!A0(s)&&a[s]==null&&delete r[s]};rr=$O;ZS=e=>e.__isSuspense,_O=Symbol("_deferredEnter");ge=Symbol.for("v-fgt"),Ml=Symbol.for("v-txt"),Ft=Symbol.for("v-cmt"),za=Symbol.for("v-stc"),Hn=[],Or=null;Pl=1;KS=({key:e})=>e??null,Vd=({ref:e,ref_key:t,ref_for:n})=>(typeof e=="number"&&(e=""+e),e!=null?pt(e)||Vt(e)||Te(e)?{i:Yt,r:e,k:t,f:!!n}:e:null);be=SO;IO=TS(),qS=0;nr=null,Ua=()=>nr||Yt;{let e=_i(),t=(n,i)=>{let r;return(r=e[n])||(r=e[n]=[]),r.push(i),o=>{r.length>1?r.forEach(a=>a(o)):r[0](o)}};Jd=t("__VUE_INSTANCE_SETTERS__",n=>nr=n),Rl=t("__VUE_SSR_SETTERS__",n=>Ul=n)}Ll=e=>{let t=nr;return Jd(e),e.scope.on(),()=>{e.scope.off(),Jd(t)}},eS=()=>{nr&&nr.scope.off(),Jd(null)};Ul=!1;YS=Symbol(),zO={get(e,t){return Jt(e,"get",""),t===YS?e:e[t]}};R=(e,t)=>L$(e,t,Ul);iS="3.5.45"});function k2(e){let t={};for(let F in e)F in y2||(t[F]=e[F]);if(e.css===!1)return t;let{name:n="v",type:i,duration:r,enterFromClass:o=`${n}-enter-from`,enterActiveClass:a=`${n}-enter-active`,enterToClass:s=`${n}-enter-to`,appearFromClass:l=o,appearActiveClass:u=a,appearToClass:d=s,leaveFromClass:p=`${n}-leave-from`,leaveActiveClass:m=`${n}-leave-active`,leaveToClass:f=`${n}-leave-to`}=e,h=MO(r),v=h&&h[0],k=h&&h[1],{onBeforeEnter:T,onEnter:S,onEnterCancelled:z,onLeave:j,onLeaveCancelled:O,onBeforeAppear:U=T,onAppear:J=S,onAppearCancelled:W=z}=t,ce=(F,ue,Je,ct)=>{F._enterCancelled=ct,Ti(F,ue?d:s),Ti(F,ue?u:a),Je&&Je()},se=(F,ue)=>{F._isLeaving=!1,Ti(F,p),Ti(F,f),Ti(F,m),ue&&ue()},pe=F=>(ue,Je)=>{let ct=F?J:S,ft=()=>ce(ue,F,Je);ao(ct,[ue,ft]),r2(()=>{Ti(ue,F?l:o),In(ue,F?d:s),t2(ct)||n2(ue,i,v,ft)})};return it(t,{onBeforeEnter(F){ao(T,[F]),In(F,o),In(F,a)},onBeforeAppear(F){ao(U,[F]),In(F,l),In(F,u)},onEnter:pe(!1),onAppear:pe(!0),onLeave(F,ue){F._isLeaving=!0;let Je=()=>se(F,ue);In(F,p),F._enterCancelled?(In(F,m),B0(F)):(B0(F),In(F,m)),r2(()=>{F._isLeaving&&(Ti(F,p),In(F,f),t2(j)||n2(F,i,k,Je))}),ao(j,[F,Je])},onEnterCancelled(F){ce(F,!1,void 0,!0),ao(z,[F])},onAppearCancelled(F){ce(F,!0,void 0,!0),ao(W,[F])},onLeaveCancelled(F){se(F),ao(O,[F])}})}function MO(e){if(e==null)return null;if(qe(e))return[j0(e.enter),j0(e.leave)];{let t=j0(e);return[t,t]}}function j0(e){return Hb(e)}function In(e,t){t.split(/\s+/).forEach(n=>n&&e.classList.add(n)),(e[Ma]||(e[Ma]=new Set)).add(t)}function Ti(e,t){t.split(/\s+/).forEach(i=>i&&e.classList.remove(i));let n=e[Ma];n&&(n.delete(t),n.size||(e[Ma]=void 0))}function r2(e){requestAnimationFrame(()=>{requestAnimationFrame(e)})}function n2(e,t,n,i){let r=e._endId=++LO,o=()=>{r===e._endId&&i()};if(n!=null)return setTimeout(o,n);let{type:a,timeout:s,propCount:l}=x2(e,t);if(!a)return i();let u=a+"end",d=0,p=()=>{e.removeEventListener(u,m),o()},m=f=>{f.target===e&&++d>=l&&p()};setTimeout(()=>{d<l&&p()},s+1),e.addEventListener(u,m)}function x2(e,t){let n=window.getComputedStyle(e),i=h=>(n[h]||"").split(", "),r=i(`${Ei}Delay`),o=i(`${Ei}Duration`),a=i2(r,o),s=i(`${Vl}Delay`),l=i(`${Vl}Duration`),u=i2(s,l),d=null,p=0,m=0;t===Ei?a>0&&(d=Ei,p=a,m=o.length):t===Vl?u>0&&(d=Vl,p=u,m=l.length):(p=Math.max(a,u),d=p>0?a>u?Ei:Vl:null,m=d?d===Ei?o.length:l.length:0);let f=d===Ei&&/\b(?:transform|all)(?:,|$)/.test(i(`${Ei}Property`).toString());return{type:d,timeout:p,propCount:m,hasTransform:f}}function i2(e,t){for(;e.length<t.length;)e=e.concat(e);return Math.max(...t.map((n,i)=>o2(n)+o2(e[i])))}function o2(e){return e==="auto"?0:Number(e.slice(0,-1).replace(",","."))*1e3}function B0(e){return(e?e.ownerDocument:document).body.offsetHeight}function VO(e,t,n){let i=e[Ma];i&&(t=(t?[t,...i]:[...i]).join(" ")),t==null?e.removeAttribute("class"):n?e.setAttribute("class",t):e.className=t}function ZO(e,t,n){let i=e.style,r=pt(n),o=!1;if(n&&!r){if(t)if(pt(t))for(let a of t.split(";")){let s=a.slice(0,a.indexOf(":")).trim();n[s]==null&&Fl(i,s,"")}else for(let a in t)n[a]==null&&Fl(i,a,"");for(let a in n){a==="display"&&(o=!0);let s=n[a];s!=null?KO(e,a,!pt(t)&&t?t[a]:void 0,s)||Fl(i,a,s):Fl(i,a,"")}}else if(r){if(t!==n){let a=i[FO];a&&(n+=";"+a),i.cssText=n,o=BO.test(n)}}else t&&e.removeAttribute("style");a2 in e&&((!r||t!==n)&&(e[a2]=o?i.display:""),e[_2]&&(i.display="none"))}function Fl(e,t,n){if(xe(n))n.forEach(i=>Fl(e,t,i));else if(n==null&&(n=""),t.startsWith("--"))ap.test(n)?e.setProperty(t,n.replace(ap,""),"important"):e.setProperty(t,n);else{let i=HO(e,t);ap.test(n)?e.setProperty(rn(i),n.replace(ap,""),"important"):e[i]=n}}function HO(e,t){let n=M0[t];if(n)return n;let i=Ct(t);if(i!=="filter"&&i in e)return M0[t]=i;i=Xi(i);for(let r=0;r<s2.length;r++){let o=s2[r]+i;if(o in e)return M0[t]=o}return t}function KO(e,t,n,i){return e.tagName==="TEXTAREA"&&(t==="width"||t==="height")&&pt(i)&&n===i}function c2(e,t,n,i,r,o=w$(t)){i&&t.startsWith("xlink:")?n==null?e.removeAttributeNS(l2,t.slice(6,t.length)):e.setAttributeNS(l2,t,n):n==null||o&&!Cd(n)?e.removeAttribute(t):e.setAttribute(t,o?"":_r(n)?String(n):n)}function u2(e,t,n,i,r){if(t==="innerHTML"||t==="textContent"){n!=null&&(e[t]=t==="innerHTML"?b2(n):n);return}let o=e.tagName;if(t==="value"&&o!=="PROGRESS"&&!o.includes("-")){let s=o==="OPTION"?e.getAttribute("value")||"":e.value,l=n==null?e.type==="checkbox"?"on":"":String(n);(s!==l||!("_value"in e))&&(e.value=l),n==null&&e.removeAttribute(t),e._value=n;return}let a=!1;if(n===""||n==null){let s=typeof e[t];s==="boolean"?n=Cd(n):n==null&&s==="string"?(n="",a=!0):s==="number"&&(n=0,a=!0)}try{e[t]=n}catch{}a&&e.removeAttribute(r||t)}function ja(e,t,n,i){e.addEventListener(t,n,i)}function WO(e,t,n,i){e.removeEventListener(t,n,i)}function qO(e,t,n,i,r=null){let o=e[d2]||(e[d2]={}),a=o[t];if(i&&a)a.value=i;else{let[s,l]=YO(t);if(i){let u=o[t]=e6(i,r);ja(e,s,u,l)}else a&&(WO(e,s,a,l),o[t]=void 0)}}function YO(e){let t,n;for(;(n=e.match(GO))&&!JO.test(e);)t||(t={}),e=e.slice(0,e.length-n[1].length),t[n[1].toLowerCase()]=!0;return[e[2]===":"?e.slice(3):rn(e.slice(2)),t]}function e6(e,t){let n=i=>{if(!i._vts)i._vts=Date.now();else if(i._vts<=n.attached)return;let r=n.value;if(xe(r)){let o=i.stopImmediatePropagation;i.stopImmediatePropagation=()=>{o.call(i),i._stopped=!0};let a=r.slice(),s=[i];for(let l=0;l<a.length&&!i._stopped;l++){let u=a[l];u&&Dr(u,t,5,s)}}else Dr(r,t,5,[i])};return n.value=e,n.attached=QO(),n}function r6(e,t,n,i){if(i)return!!(t==="innerHTML"||t==="textContent"||t in e&&p2(t)&&Te(n));if(t==="spellcheck"||t==="draggable"||t==="translate"||t==="autocorrect"||t==="sandbox"&&e.tagName==="IFRAME"||t==="form"||t==="list"&&e.tagName==="INPUT"||t==="type"&&e.tagName==="TEXTAREA")return!1;if(t==="width"||t==="height"){let r=e.tagName;if(r==="IMG"||r==="VIDEO"||r==="CANVAS"||r==="SOURCE")return!1}return p2(t)&&pt(n)?!1:t in e}function n6(e,t){let n=e._def.props;if(!n)return!1;let i=Ct(t);return Array.isArray(n)?n.some(r=>Ct(r)===i):Object.keys(n).some(r=>Ct(r)===i)}function a6(e){let t=e.el;t[cp]&&t[cp](),t[m2]&&t[m2]()}function f2(e){return e.moveClass||`${e.name||"v"}-move`}function s6(e,t){S2.set(e,up(e.el,t))}function l6(e){let t=$2.get(e),n=S2.get(e),i=t.left-n.left,r=t.top-n.top;if(i||r){let o=e.el,a=o.style,s=o.getBoundingClientRect(),l=1,u=1;return o.offsetWidth&&(l=s.width/o.offsetWidth),o.offsetHeight&&(u=s.height/o.offsetHeight),(!Number.isFinite(l)||l===0)&&(l=1),(!Number.isFinite(u)||u===0)&&(u=1),Math.abs(l-1)<.01&&(l=1),Math.abs(u-1)<.01&&(u=1),a.transform=a.webkitTransform=`translate(${i/l}px,${r/u}px)`,a.transitionDuration="0s",e}}function up(e,t){let n=e.getBoundingClientRect();return{left:n.left-(t?t.left:0),top:n.top-(t?t.top:0)}}function c6(e){let t;for(let n=e.parent;n;n=n.parent){let i=Z0.get(n);if(i){let r=u6(n.vnode.el,e.vnode.el);r&&(t||(t=[])).push(it(up(r),{item:r,willMove:i}))}}return t}function u6(e,t){let n=e.nodeType===1?e:e.parentNode;for(;t&&t.parentNode!==n;)t=t.parentNode;if(t&&t.nodeType===1)return t}function d6(e,t){let n=e.find(i=>i.willMove()&&i.item.contains(t));return n&&up(n.item,n)}function p6(e,t,n){let i=e.cloneNode(),r=e[Ma];r&&r.forEach(s=>{s.split(/\s+/).forEach(l=>l&&i.classList.remove(l))}),n.split(/\s+/).forEach(s=>s&&i.classList.add(s)),i.style.display="none";let o=t.nodeType===1?t:t.parentNode;o.appendChild(i);let{hasTransform:a}=x2(i);return o.removeChild(i),a}function m6(e){e.target.composing=!0}function g2(e){let t=e.target;t.composing&&(t.composing=!1,t.dispatchEvent(new Event("input")))}function V0(e,t,n){return t&&(e=e.trim()),n&&(e=fl(e)),e}function b6(){return v2||(v2=FS(v6))}function y6(e){if(e instanceof SVGElement)return"svg";if(typeof MathMLElement=="function"&&e instanceof MathMLElement)return"mathml"}function w6(e){return pt(e)?document.querySelector(e):e}var F0,QS,b2,PO,RO,qn,e2,UO,Ei,Vl,Ma,y2,w2,jO,so,ao,t2,LO,a2,_2,FO,BO,ap,s2,M0,l2,d2,GO,JO,L0,XO,QO,p2,t6,$2,S2,cp,m2,Z0,i6,o6,H0,h2,sp,lp,dp,f6,h6,Et,g6,Gn,v6,v2,Bl,I2=re(()=>{U0();U0();hl();/**
|
|
75
75
|
* @vue/runtime-dom v3.5.45
|
|
76
76
|
* (c) 2018-present Yuxi (Evan) You and Vue contributors
|
|
77
77
|
* @license MIT
|
|
@@ -81,26 +81,26 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
81
81
|
* (c) 2018-present Yuxi (Evan) You and Vue contributors
|
|
82
82
|
* @license MIT
|
|
83
83
|
**/});function $6(e){let t=e.toLowerCase().replace(/[^a-z0-9]/g,"");if(E2.includes(t))return!0;let n=e.replace(/([a-z0-9])([A-Z])/g,"$1 $2").toLowerCase().split(/[^a-z0-9]+/).filter(Boolean);return E2.some(i=>n.includes(i))}function j2(e,t=0){if(t>4||!(e instanceof Error))return;let n=e.code;return typeof n=="string"&&S6.has(n)?{code:n,error:e}:j2(e.cause,t+1)}function I6({code:e,error:t}){if(!(!U2.has(e)||!t.message.includes(e)||t.message.length>240))return t.message.match(/(?:localhost|(?:[a-z0-9-]+\.)+[a-z0-9-]+|\d{1,3}(?:\.\d{1,3}){3}|\[[a-f0-9:]+\])(?::\d{1,5})?/iu)?.[0]}function T2(e){return e?e.split(`
|
|
84
|
-
`).find(n=>(n.includes("/src/")||n.includes("/packages/"))&&!n.includes("node_modules"))?.trim():void 0}function co(e){return new L2({},e)}function V2(e=8){let t="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789",n="";for(let i=0;i<e;i++)n+=t.charAt(Math.floor(Math.random()*t.length));return n}function gp(e={}){let{prefix:t="id_"}=e,n=t.length>=3?t.substring(0,3):t.padEnd(3,"_"),i=Math.floor(Date.now()/1e3).toString(16).padStart(8,"0"),r="";for(let o=0;o<16;o++)r+=Math.floor(Math.random()*16).toString(16);return n+i+r}function F2(e){return N2[e]||N2.blue}function E6(e){return e?{secure:e.protocol==="https:",domain:void 0,path:"/"}:{path:"/"}}function C6(e){if(typeof e!="string"||!e.startsWith("/"))return!1;try{return N6.every(t=>new URL(e,t).origin===t)}catch{return!1}}function X2(e){if(s3(e.operation))return"changing";if(e.blocker?.bucket==="account"&&e.lifecycle!=="running")return"asleep";if(e.operation?.status==="failed")return"stuck";switch(e.lifecycle){case"running":return"awake";case"stopped":return"asleep";case"starting":return"changing";case"unreachable":case"error":return"stuck";case"unknown":return}}function a3(e,t){let n=e.operation,i=i3[e.lifecycle]??"Unknown",r=r3[e.lifecycle]??"grey",o=n?o3[n.kind]??"Working":void 0,a=o?n?.status==="failed"?`${o} failed`:o:i,s=n?n.status==="failed"?"red":"amber":r,l=`${t} \xB7 ${a}`;return{...e,color:s,label:a,tooltip:l}}function s3(e){return e?.status==="running"||e?.status==="coalesced"}function g3(e){let t=0;for(let n=0;n<e.length;n++)t=(t<<5)-t+e.charCodeAt(n),t|=0;return Math.abs(t)}function v3(e){let t=e?g3(e):0;return z2[t%z2.length]}function Wl(e){let t=e
|
|
84
|
+
`).find(n=>(n.includes("/src/")||n.includes("/packages/"))&&!n.includes("node_modules"))?.trim():void 0}function co(e){return new L2({},e)}function V2(e=8){let t="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789",n="";for(let i=0;i<e;i++)n+=t.charAt(Math.floor(Math.random()*t.length));return n}function gp(e={}){let{prefix:t="id_"}=e,n=t.length>=3?t.substring(0,3):t.padEnd(3,"_"),i=Math.floor(Date.now()/1e3).toString(16).padStart(8,"0"),r="";for(let o=0;o<16;o++)r+=Math.floor(Math.random()*16).toString(16);return n+i+r}function F2(e){return N2[e]||N2.blue}function E6(e){return e?{secure:e.protocol==="https:",domain:void 0,path:"/"}:{path:"/"}}function C6(e){if(typeof e!="string"||!e.startsWith("/"))return!1;try{return N6.every(t=>new URL(e,t).origin===t)}catch{return!1}}function X2(e){if(s3(e.operation))return"changing";if(e.blocker?.bucket==="account"&&e.lifecycle!=="running")return"asleep";if(e.operation?.status==="failed")return"stuck";switch(e.lifecycle){case"running":return"awake";case"stopped":return"asleep";case"starting":return"changing";case"unreachable":case"error":return"stuck";case"unknown":return}}function a3(e,t){let n=e.operation,i=i3[e.lifecycle]??"Unknown",r=r3[e.lifecycle]??"grey",o=n?o3[n.kind]??"Working":void 0,a=o?n?.status==="failed"?`${o} failed`:o:i,s=n?n.status==="failed"?"red":"amber":r,l=`${t} \xB7 ${a}`;return{...e,color:s,label:a,tooltip:l}}function s3(e){return e?.status==="running"||e?.status==="coalesced"}function g3(e){let t=0;for(let n=0;n<e.length;n++)t=(t<<5)-t+e.charCodeAt(n),t|=0;return Math.abs(t)}function v3(e,t){return(e?[...e][0].toUpperCase():t).replace(/&/g,"&").replace(/</g,"<").replace(/>/g,">")}function b3(e){return`data:image/svg+xml,${encodeURIComponent(e)}`}function y3(e){let t=e?g3(e):0;return z2[t%z2.length]}function Wl(e){let t=v3(e,"?"),[n,i]=y3(e),r=['<svg xmlns="http://www.w3.org/2000/svg" width="80" height="80" viewBox="0 0 80 80">','<defs><linearGradient id="g" x1="0" y1="0" x2="1" y2="1">',`<stop offset="0%" stop-color="${n}"/>`,`<stop offset="100%" stop-color="${i}"/>`,"</linearGradient></defs>",'<rect width="80" height="80" fill="url(#g)"/>',`<text x="40" y="40" text-anchor="middle" dominant-baseline="central" fill="white" font-family="system-ui,-apple-system,sans-serif" font-size="36" font-weight="600">${t}</text>`,"</svg>"].join("");return b3(r)}function x3(e){return e.trim().toUpperCase().replace(/\s+/g," ")}function vp(e){let t=x3(e);return t.length<=64&&k3.has(t)}function _3(e,t){return e&&e in A2?A2[e]:t}function iI(){try{return Intl.DateTimeFormat().resolvedOptions().timeZone||void 0}catch{return}}function uI(e,t){e.revisitAt&&e.disposition!=="deferred"&&t.addIssue({code:"custom",path:["revisitAt"],message:"revisitAt requires deferred disposition"})}function pI(e,t){let n=new Set;for(let i of e.participants){let r=`${i.type}:${i.id}`;n.has(r)&&t.addIssue({code:"custom",path:["participants"],message:"Duplicate conversation participant."}),n.add(r)}}function bI(e){if(e.event==="message"&&e.data.message.role==="user")return e.data.message.messageId}function Y3(e){if(e.event==="message_delta"||e.event==="working_state"||e.event==="tool_activity"||e.event==="working_end"||e.event==="stream_end")return e.data.turnId;if(e.event==="message"){let t=e.data.message.metadata?.turnId;return typeof t=="string"?t:void 0}}function X3(e,t){if(e.event==="status"||e.event==="error"||bI(e))return!0;let n=Y3(e);return t?n?n===t:e.event==="message"&&!e.data.message.metadata?.routine:!1}function ln(e,t,n){let i=e==="no-reply"?"The reply didn't make it back. Refresh to see if it landed.":e==="api"?"Couldn't send. Try again.":"Lost connection. Try again.";return{stage:e,detail:t,code:n??(e==="no-reply"?"EMPTY_STREAM":e==="api"?"SEND_FAILED":"STREAM_DISCONNECT"),bucket:"error",message:_3(n,e==="api"&&n&&t||i)}}async function yI(e){let t=e.fetchFn??fetch,n=e.headers??{},i=!1,r=!1,o=!1,a=!1,s,l=!1,u=!1,d,p=new AbortController,m=!1,f,h=()=>{},v=new Promise(O=>{h=O}),k=O=>{m||(m=!0,f&&clearTimeout(f),h(O))},T=(O,U,J)=>{o=!0,e.onTransportError(ln(O,U,J))},S=()=>{d?.cancel().catch(()=>{})};f=setTimeout(()=>{u=!0,T("stream-open","Timed out opening stream","STREAM_TIMEOUT"),p.abort(),k("failed")},e.streamOpenTimeoutMs??1e4);let z=(async()=>{try{let O=await t(e.streamUrl,{headers:n,signal:p.signal});if(!O.ok){k("failed"),T("stream-open",await Q3(O));return}if(d=O.body?.getReader(),!d){T("stream-open","No response stream"),k("failed");return}k("ready");for await(let U of Q0(d))if(s||(s=bI(U)),!(i&&!X3(U,s))){if(U.event==="status")e.onLiveStatus?.(U.data);else if(U.event==="working_state")i&&e.onStatus?.(U.data.description);else if(U.event==="tool_activity")i&&e.onToolActivity?.(U.data);else if(U.event==="working_end")i&&e.onWorkingEnd?.();else if(U.event==="message_delta")i&&e.onDelta(U.data.delta,U.data.role);else if(U.event==="error"){o=!0,e.onChatError(U.data);break}else if(U.event==="message"&&(U.data.message.role==="assistant"||U.data.message.role==="system")){if(!i)continue;a||(a=!0,e.onMessage?.(U.data.message))}else if(U.event==="stream_end")break}!o&&a?e.onDone():!o&&i&&!r&&T("no-reply","Stream ended before reply arrived")}catch(O){!r&&!u&&(k("failed"),T("stream-read",O instanceof Error?O.message:"Stream failed"))}finally{l=!0;try{await d?.cancel()}catch{}}})();if(await v==="failed"){await z;return}if(l){T("stream-open","Stream closed before send"),await z;return}try{i=!0;let O=await t(e.sendUrl,{method:"POST",headers:{"Content-Type":"application/json",...n},body:JSON.stringify(e.sendBody)}),U=await O.json();if(!U.ok){r=!0,p.abort(),S(),T("api",U.error||`Send failed: HTTP ${O.status}`,U.code),await z;return}s=U.data.messageId,e.onUserMessage?.(U.data)}catch(O){r=!0,p.abort(),S(),T("api",O instanceof Error?O.message:"Send failed"),await z;return}await z}async function Q3(e){let t="";try{let n=await e.text();n&&(t=` - ${n.slice(0,200)}`)}catch{}return`HTTP ${e.status}${t}`}async function*Q0(e){let t=new TextDecoder,n="";for(;;){let{done:i,value:r}=await e.read();if(i)break;n+=t.decode(r,{stream:!0});let o=n.indexOf(`
|
|
85
85
|
|
|
86
|
-
`);for(;o!==-1;){let a=n.slice(0,o);n=n.slice(o+2);let s=
|
|
86
|
+
`);for(;o!==-1;){let a=n.slice(0,o);n=n.slice(o+2);let s=eD(a);s&&(yield s),o=n.indexOf(`
|
|
87
87
|
|
|
88
|
-
`)}}}function
|
|
89
|
-
`).filter(r=>r.length>0),n,i;for(let r of t)r.startsWith("event:")?n=r.slice(6).trim():r.startsWith("data:")&&(i=r.slice(5).trim());if(!n||i===void 0)return null;try{let r=
|
|
88
|
+
`)}}}function eD(e){let t=e.split(`
|
|
89
|
+
`).filter(r=>r.length>0),n,i;for(let r of t)r.startsWith("event:")?n=r.slice(6).trim():r.startsWith("data:")&&(i=r.slice(5).trim());if(!n||i===void 0)return null;try{let r=J3.safeParse({event:n,data:JSON.parse(i)});return r.success?r.data:null}catch{return null}}function wI(e){let t;try{t=JSON.parse(e)}catch(i){return{ok:!1,reason:"invalid_json",message:i instanceof Error?i.message:"Invalid JSON"}}let n=rD.safeParse(t);return n.success?{ok:!0,spec:n.data}:{ok:!1,reason:"invalid_spec",message:n.error.issues.map(i=>i.message).join("; ")}}function lD(e){let t=new Set;for(let n of e)for(let i of Object.keys(n))t.add(i);return t}function _I(e,t,n){let i=lD(e);for(let r of t)i.has(r.value)||n.addIssue({code:"custom",path:r.path,message:`Unknown data key "${r.value}"`})}function $I(e,t,n){for(let[i,r]of e.entries())for(let o of t){let a=r[o.value];if(typeof a!="number"||!Number.isFinite(a)){n.addIssue({code:"custom",path:["data",i,o.value],message:`Data key "${o.value}" must be numeric`});continue}o.nonnegative&&a<0&&n.addIssue({code:"custom",path:["data",i,o.value],message:`Data key "${o.value}" must be nonnegative`})}}function hD(e){if(e&&typeof e=="object"&&"fallbackMarkdown"in e){let t=e.fallbackMarkdown;if(typeof t=="string"&&t.trim())return t.trim()}}function lo(e){return!!(e&&typeof e=="object"&&!Array.isArray(e))}function lt(e){return typeof e!="string"?void 0:e.trim()||void 0}function Tn(e){return String(e??"").replace(/\r?\n/g," ").replace(/\|/g,"\\|").trim()}function gD(e,t){if(!Array.isArray(e)||e.length===0||e.length>t)return null;let n=[];for(let i of e){if(!lo(i))return null;let r=lt(i.label),o=i.value;if(!r||typeof o!="number"||!Number.isFinite(o))return null;n.push({label:r,value:o})}return n}function vD(e){let t=lt(e.type);if(t==="bar"||t==="line"||t==="pie")return t;let n=lt(e.chartType);return t==="chart"&&(n==="bar"||n==="line"||n==="pie")?n:null}function bD(e){if(!lo(e)||"version"in e||"visualType"in e)return null;let t=vD(e);if(!t)return null;let n=lt(e.title);if(!n)return null;let i=gD(e.data,t==="pie"?16:120);if(!i)return null;let r=lt(e.subtitle),o=lt(e.source),a={title:n,...r?{description:r}:{},...o?{footer:o}:{}},s=lt(e.fallbackMarkdown);if(t==="pie")return{version:1,visualType:"chart",chartType:"pie",meta:a,nameKey:"label",valueKey:"value",data:i,fallbackMarkdown:s??i.map(p=>`- ${Tn(p.label)}: ${Tn(p.value)}`).join(`
|
|
90
90
|
`)};let l=lt(e.xAxis)??lt(e.xLabel),u=lt(e.yAxis)??lt(e.yLabel),d=u??"Value";return{version:1,visualType:"chart",chartType:t,meta:a,xKey:"label",...l?{xAxisLabel:l}:{},series:[{dataKey:"value",label:d,...u?{axisLabel:u}:{}}],data:i,fallbackMarkdown:s??[`| ${Tn(l??"Label")} | ${Tn(d)} |`,"|---|---:|",...i.map(p=>`| ${Tn(p.label)} | ${Tn(p.value)} |`)].join(`
|
|
91
|
-
`)}}function
|
|
92
|
-
`);return{version:1,visualType:"chart",chartType:n,meta:{title:u,...d?{description:d}:{},...p?{footer:p}:{}},xKey:r,...o?{xAxisLabel:o}:{},series:a,data:s,fallbackMarkdown:m}}function SI(e){let t;try{t=JSON.parse(e)}catch(i){let r=e.match(/"fallbackMarkdown"\s*:\s*"((?:[^"\\]|\\.)*)"/),o;if(r)try{o=JSON.parse(`"${r[1]}"`)}catch{}return{ok:!1,reason:"invalid_json",message:i instanceof Error?i.message:"Invalid JSON",fallbackMarkdown:o}}let n=O2.safeParse(t);if(!n.success){let i=
|
|
91
|
+
`)}}function yD(e){if(!lo(e)||(lt(e.visualType)??lt(e.kind))!=="chart")return null;let n=lt(e.chartType);if(n!=="bar"&&n!=="line"&&n!=="scatter")return null;let i=lo(e.xAxis)?e.xAxis:void 0,r=lt(e.xKey)??(i?lt(i.key)??lt(i.dataKey):void 0);if(!r)return null;let o=lt(e.xAxisLabel)??(i?lt(i.label):void 0);if(!Array.isArray(e.series))return null;let a=[];for(let f of e.series){if(!lo(f))return null;let h=lt(f.dataKey)??lt(f.key);if(!h)return null;let v=lt(f.label)??lt(f.name);a.push({dataKey:h,...v?{label:v}:{}})}if(a.length===0||!Array.isArray(e.data))return null;let s=e.data.filter(lo),l=lo(e.meta)?e.meta:e,u=lt(l.title);if(!u)return null;let d=lt(l.description)??lt(l.subtitle),p=lt(l.footer)??lt(l.source),m=lt(e.fallbackMarkdown)??[`| ${Tn(o??r)} | ${a.map(f=>Tn(f.label??f.dataKey)).join(" | ")} |`,`|---|${a.map(()=>"---:").join("|")}|`,...s.map(f=>`| ${Tn(f[r])} | ${a.map(h=>Tn(f[h.dataKey])).join(" | ")} |`)].join(`
|
|
92
|
+
`);return{version:1,visualType:"chart",chartType:n,meta:{title:u,...d?{description:d}:{},...p?{footer:p}:{}},xKey:r,...o?{xAxisLabel:o}:{},series:a,data:s,fallbackMarkdown:m}}function SI(e){let t;try{t=JSON.parse(e)}catch(i){let r=e.match(/"fallbackMarkdown"\s*:\s*"((?:[^"\\]|\\.)*)"/),o;if(r)try{o=JSON.parse(`"${r[1]}"`)}catch{}return{ok:!1,reason:"invalid_json",message:i instanceof Error?i.message:"Invalid JSON",fallbackMarkdown:o}}let n=O2.safeParse(t);if(!n.success){let i=bD(t)??yD(t);if(i){let r=O2.safeParse(i);if(r.success)return{ok:!0,spec:r.data}}return{ok:!1,reason:"invalid_spec",message:n.error.issues.map(r=>r.message).join("; "),fallbackMarkdown:hD(t)}}return{ok:!0,spec:n.data}}var k6,x6,Hl,Va,Jn,mp,La,_6,pp,E2,U2,S6,M2,L2,Nn,p7,m7,f7,h7,g7,uo,N2,T6,po,N6,z6,A6,O6,D6,G0,P6,B2,R6,U6,j6,M6,L6,V6,Bt,F6,B6,Z6,H6,K6,W6,w7,Z2,H2,K2,K0,x7,q6,W2,G6,C2,J6,Y6,X6,q2,E7,G2,Q6,e3,t3,J2,Kl,r3,n3,Y2,i3,o3,T7,l3,N7,Q2,c3,J0,u3,d3,z7,A7,p3,O7,D7,P7,R7,U7,j7,M7,eI,m3,f3,h3,z2,w3,k3,tI,A2,rI,$3,F7,S3,nI,I3,Yn,oI,E3,aI,sI,lI,cI,T3,W7,N3,C3,Y0,q7,dI,G7,J7,Y7,X7,Q7,z3,A3,eZ,tZ,nZ,O3,iZ,oZ,D3,aZ,sZ,P3,lZ,mI,R3,W0,pZ,fI,U3,gZ,vZ,hI,j3,gI,bZ,yZ,M3,wZ,kZ,L3,V3,Zl,X0,xZ,_Z,vI,bp,$Z,SZ,F3,B3,Z3,H3,K3,IZ,W3,EZ,TZ,q3,G3,J3,tD,rD,nD,q0,Xn,Fa,iD,kI,oD,aD,xI,sD,ey,cD,uD,dD,pD,mD,fD,O2,II,EI,OZ,DZ,PZ,RZ,UZ,jZ,Zr,wD,kD,xD,D2,_D,$D,LZ,SD,FZ,BZ,ID,ZZ,HZ,KZ,WZ,qZ,GZ,JZ,ED,TD,ND,CD,zD,QZ,eH,tH,nH,oH,AD,OD,DD,PD,sH,RD,UD,jD,MD,LD,cH,VD,dH,mH,hp,FD,BD,TI,ZD,HD,KD,WD,NI,hH,gH,vH,bH,wH,P2,CI,R2,ty,ql=re(()=>{"use strict";je();je();je();je();je();je();je();je();je();je();je();je();je();je();je();je();je();je();je();je();je();je();je();je();je();je();je();je();je();je();je();je();je();je();je();je();je();je();En();En();k6=Object.defineProperty,x6=(e,t)=>{for(var n in t)k6(e,n,{get:t[n],enumerable:!0})},Hl={appName:"pagelines-app",zeroState:{title:"Create your first bot",action:"Get started"},defaultWorkspaceName:"My Workspace",port:3222,primaryRegion:"lax",liveCanary:{email:"smoke-canary@pagelines.com",botHandle:"seneca"},gtmId:"GTM-WRN7DPK7",ga4MeasurementId:"G-WT51X9S6SK",urls:{app:"https://www.pagelines.com",dev:"https://dev-api.pagelines.com",appStore:"https://apps.apple.com/us/app/pagelines/id6764094785",memberGuide:"https://go.pagelines.com/guide"}},Va=globalThis.process,Jn=typeof window<"u",mp=typeof Va<"u"&&!Jn,La=Jn?typeof window<"u"&&window.location&&!window.location.hostname.includes("localhost"):mp&&typeof Va<"u"&&Va.env?.NODE_ENV==="production",_6=!La,pp={error:{priority:50,color:"#FF0000",nodeColor:"\x1B[31m"},warn:{priority:40,color:"#FFA500",nodeColor:"\x1B[33m"},info:{priority:30,color:"#00ABFF",nodeColor:"\x1B[36m"},debug:{priority:20,color:"#00BD0C",nodeColor:"\x1B[32m"},trace:{priority:10,color:"#5233FF",nodeColor:"\x1B[35m"}},E2=["password","token","secret","apikey","authorization","cookie"];U2=new Set(["CONNECT_TIMEOUT","ECONNREFUSED","ECONNRESET","ETIMEDOUT","ENOTFOUND","EHOSTUNREACH","EPIPE"]),S6=new Set([...U2,"CONNECTION_CLOSED","53300"]);M2=class fp{constructor(t={},n){this.enabledInBrowser=!1,this.context=n,this.settings={enabled:t.enabled??!0,minLevel:t.minLevel??this.getDefaultLevel(),timestamps:t.timestamps??!0},Jn&&this.initBrowserLogging()}getDefaultLevel(){if(mp&&typeof Va<"u"&&Va.env?.LOG_LEVEL)return Va.env.LOG_LEVEL;if(Jn&&typeof localStorage<"u"&&typeof localStorage.getItem=="function"){let t=localStorage.getItem("PAGELINES_LOG_LEVEL");if(t)return t}return"info"}initBrowserLogging(){if(!Jn)return;let n=typeof localStorage?.getItem=="function"&&localStorage.getItem("PAGELINES_LOG")==="true",i=window.location?.hostname||"";this.enabledInBrowser=_6||n||i==="localhost"||i.includes("127.0.0.1"),La&&!n&&!fp.hasShownHelp&&(console.log("%cPageLines Logger (disabled in production)","color: #888; font-size: 12px"),console.log('%cTo enable: localStorage.setItem("PAGELINES_LOG", "true")',"color: #888; font-size: 11px"),fp.hasShownHelp=!0)}shouldLog(t){if(!this.settings.enabled||Jn&&!this.enabledInBrowser)return!1;let n=pp[t].priority,i=pp[this.settings.minLevel].priority;return n>=i}formatTimestamp(){return new Date().toLocaleTimeString("en-GB",{hour12:!1,hour:"2-digit",minute:"2-digit",second:"2-digit"})}formatISOTimestamp(){return new Date().toISOString()}redactSensitive(t){if(typeof t!="object"||t===null)return t;if(Array.isArray(t))return t.map(i=>this.redactSensitive(i));let n={};for(let[i,r]of Object.entries(t))$6(i)?n[i]="[REDACTED]":typeof r=="object"&&r!==null?n[i]=this.redactSensitive(r):n[i]=r;return n}formatData(t,n=5,i=0){if(i>=n)return"[Max Depth]";if(t==null)return t;if(t instanceof Error){let r=j2(t);if(r){let a={name:t.name,code:r.code},s=I6(r);s&&(a.endpoint=s);let l=T2(t.stack)??T2(t.cause?.stack);return l&&(a.at=l),this.redactSensitive(a)}let o={name:t.name,message:t.message,stack:La?t.stack?.split(`
|
|
93
93
|
`).slice(0,3).join(`
|
|
94
|
-
`):t.stack};for(let[a,s]of Object.entries(t))o[a]=this.formatData(s,n,i+1);return"cause"in t&&(o.cause=this.formatData(t.cause,n,i+1)),this.redactSensitive(o)}if(t instanceof Date)return t.toISOString();if(typeof t!="object")return t;if(Array.isArray(t))return t.length>20&&La?`Array(${t.length}) [${t.slice(0,3).map(r=>this.formatData(r,n,i+1)).join(", ")}, ...]`:t.map(r=>this.formatData(r,n,i+1));try{let r={},o=Object.entries(t),a=La?50:200;for(let[s,l]of o.slice(0,a))r[s]=this.formatData(l,n,i+1);return o.length>a&&(r["..."]=`${o.length-a} more properties`),this.redactSensitive(r)}catch{return"[Unserializable]"}}logToBrowser(t){if(!Jn||!this.shouldLog(t.level))return;let{level:n,description:i,context:r,data:o,error:a}=t,s=pp[n],u=`[${r||this.context||"www"}] ${n.toUpperCase()}:`,d=`color: ${s.color}; font-weight: bold;`;o!==void 0?console[n](`%c${u}`,d,i,this.formatData(o)):console[n](`%c${u}`,d,i),a&&(a instanceof Error?console.error(a):console.error("Error details:",a))}logToNode(t){if(!mp||!this.shouldLog(t.level))return;let{level:n,description:i,context:r,data:o,error:a}=t,s=r||this.context||"www";if(La){let l={timestamp:this.formatISOTimestamp(),level:n.toUpperCase(),context:s,msg:i,message:i};o!==void 0&&(l.data=this.formatData(o)),a!==void 0&&(l.error=this.formatData(a));let u=JSON.stringify(l);n==="trace"?console.log(u):console[n](u)}else{let l=pp[n],u=this.formatTimestamp(),d="\x1B[0m",p="\x1B[2m",m=l.nodeColor||"",f=`${p}${u}${d} ${m}${n.toUpperCase()} (${s}):${d} ${i}`;console[n](f),o!==void 0&&console.log(JSON.stringify(this.formatData(o),null,2)),a&&(a instanceof Error?(console.error(`\x1B[31mError:${d}`,a.message),a.stack&&console.error(`\x1B[90m${a.stack}${d}`)):console.error("Error:",a))}}log(t){Jn?this.logToBrowser(t):mp&&this.logToNode(t)}error(t,n){this.log({level:"error",description:t,data:n,context:this.context})}warn(t,n){this.log({level:"warn",description:t,data:n,context:this.context})}info(t,n){this.log({level:"info",description:t,data:n,context:this.context})}debug(t,n){this.log({level:"debug",description:t,data:n,context:this.context})}trace(t,n){this.log({level:"trace",description:t,data:n,context:this.context})}isEnabled(){return Jn?this.enabledInBrowser:!0}setLevel(t){this.settings.minLevel=t}createContextLogger(t){let n=new fp(this.settings,t);return{error:(i,r)=>n.error(i,r),warn:(i,r)=>n.warn(i,r),info:(i,r)=>n.info(i,r),debug:(i,r)=>n.debug(i,r),trace:(i,r)=>n.trace(i,r),isEnabled:()=>n.isEnabled(),setLevel:i=>n.setLevel(i)}}};M2.hasShownHelp=!1;L2=M2;Nn=new L2,u7=Nn.error.bind(Nn),d7=Nn.warn.bind(Nn),p7=Nn.info.bind(Nn),m7=Nn.debug.bind(Nn),f7=Nn.trace.bind(Nn),uo=class{constructor(e,t){this.objectName=e,this.settings=t,this.logger=co(e)}};N2={green:{50:"oklch(98.2% 0.018 155.826)",100:"oklch(96.2% 0.044 156.743)",200:"oklch(92.5% 0.084 155.995)",300:"oklch(87.1% 0.15 154.449)",400:"oklch(79.2% 0.209 151.711)",500:"oklch(72.3% 0.219 149.579)",600:"oklch(62.7% 0.194 149.214)",700:"oklch(52.7% 0.154 150.069)",800:"oklch(44.8% 0.119 151.328)",900:"oklch(39.3% 0.095 152.535)",950:"oklch(26.6% 0.065 152.934)"},blue:{50:"oklch(97% 0.014 254.604)",100:"oklch(93.2% 0.032 255.585)",200:"oklch(88.2% 0.059 254.128)",300:"oklch(80.9% 0.105 251.813)",400:"oklch(70.7% 0.165 254.624)",500:"oklch(62.3% 0.214 259.815)",600:"oklch(54.6% 0.245 262.881)",700:"oklch(48.8% 0.243 264.376)",800:"oklch(42.4% 0.199 265.638)",900:"oklch(37.9% 0.146 265.522)",950:"oklch(28.2% 0.091 267.935)"},rose:{50:"oklch(96.9% 0.015 12.422)",100:"oklch(94.1% 0.03 12.58)",200:"oklch(89.2% 0.058 10.001)",300:"oklch(81% 0.117 11.638)",400:"oklch(71.2% 0.194 13.428)",500:"oklch(64.5% 0.246 16.439)",600:"oklch(58.6% 0.253 17.585)",700:"oklch(51.4% 0.222 16.935)",800:"oklch(45.5% 0.188 13.697)",900:"oklch(41% 0.159 10.272)",950:"oklch(27.1% 0.105 12.094)"},cyan:{50:"oklch(98.4% 0.019 200.873)",100:"oklch(95.6% 0.045 203.388)",200:"oklch(91.7% 0.08 205.041)",300:"oklch(86.5% 0.127 207.078)",400:"oklch(78.9% 0.154 211.53)",500:"oklch(71.5% 0.143 215.221)",600:"oklch(60.9% 0.126 221.723)",700:"oklch(52% 0.105 223.128)",800:"oklch(45% 0.085 224.283)",900:"oklch(39.8% 0.07 227.392)",950:"oklch(30.2% 0.056 229.695)"},purple:{50:"oklch(97.7% 0.014 308.299)",100:"oklch(94.6% 0.033 307.174)",200:"oklch(90.2% 0.063 306.703)",300:"oklch(82.7% 0.119 306.383)",400:"oklch(71.4% 0.203 305.504)",500:"oklch(62.7% 0.265 303.9)",600:"oklch(55.8% 0.288 302.321)",700:"oklch(49.6% 0.265 301.924)",800:"oklch(43.8% 0.218 303.724)",900:"oklch(38.1% 0.176 304.987)",950:"oklch(29.1% 0.149 302.717)"},amber:{50:"oklch(98.7% 0.022 95.277)",100:"oklch(96.2% 0.059 95.617)",200:"oklch(92.4% 0.12 95.746)",300:"oklch(87.9% 0.169 91.605)",400:"oklch(82.8% 0.189 84.429)",500:"oklch(76.9% 0.188 70.08)",600:"oklch(66.6% 0.179 58.318)",700:"oklch(55.5% 0.163 48.998)",800:"oklch(47.3% 0.137 46.201)",900:"oklch(41.4% 0.112 45.904)",950:"oklch(27.9% 0.077 45.635)"},indigo:{50:"oklch(96.2% 0.018 272.314)",100:"oklch(93% 0.034 272.788)",200:"oklch(87% 0.065 274.039)",300:"oklch(78.5% 0.115 274.713)",400:"oklch(67.3% 0.182 276.935)",500:"oklch(58.5% 0.233 277.117)",600:"oklch(51.1% 0.262 276.966)",700:"oklch(45.7% 0.24 277.023)",800:"oklch(39.8% 0.195 277.366)",900:"oklch(35.9% 0.144 278.697)",950:"oklch(25.7% 0.09 281.288)"},pink:{50:"oklch(97.1% 0.014 343.198)",100:"oklch(94.8% 0.028 342.258)",200:"oklch(89.9% 0.061 343.231)",300:"oklch(82.3% 0.12 346.018)",400:"oklch(71.8% 0.202 349.761)",500:"oklch(65.6% 0.241 354.308)",600:"oklch(59.2% 0.249 0.584)",700:"oklch(52.5% 0.223 3.958)",800:"oklch(45.9% 0.187 3.815)",900:"oklch(40.8% 0.153 2.432)",950:"oklch(28.4% 0.109 3.907)"},teal:{50:"oklch(98.4% 0.014 180.72)",100:"oklch(95.3% 0.051 180.801)",200:"oklch(91% 0.096 180.426)",300:"oklch(85.5% 0.138 181.071)",400:"oklch(77.7% 0.152 181.912)",500:"oklch(70.4% 0.14 182.503)",600:"oklch(60% 0.118 184.704)",700:"oklch(51.1% 0.096 186.391)",800:"oklch(43.7% 0.078 188.216)",900:"oklch(38.6% 0.063 188.416)",950:"oklch(27.7% 0.046 192.524)"},sky:{50:"oklch(97.7% 0.013 236.62)",100:"oklch(95.1% 0.026 236.824)",200:"oklch(90.1% 0.058 230.902)",300:"oklch(82.8% 0.111 230.318)",400:"oklch(74.6% 0.16 232.661)",500:"oklch(68.5% 0.169 237.323)",600:"oklch(58.8% 0.158 241.966)",700:"oklch(50% 0.134 242.749)",800:"oklch(44.3% 0.11 240.79)",900:"oklch(39.1% 0.09 240.876)",950:"oklch(29.3% 0.066 243.157)"}};T6=class{constructor(){this.tokenName="auth-token",this.deviceIdName="pl-device-id",this.tokenMaxAge=3600*24*90,this.fallbackStorageKey="token"}currentCookieOptions(){return E6(typeof window>"u"?void 0:window.location)}getCookie(e){if(typeof document>"u")return null;let t=document.cookie.split(";");for(let n of t){let[i,r]=n.trim().split("=");if(i===e)return decodeURIComponent(r||"")}return null}setCookie(e,t,n={}){if(typeof document>"u")return;let{secure:i=!0,sameSite:r="lax",maxAge:o=3600*24*7,domain:a,path:s="/"}=n,l=`${e}=${encodeURIComponent(t)}`;l+=`; Path=${s}`,l+=`; Max-Age=${o}`,l+=`; SameSite=${r}`,i&&(l+="; Secure"),a&&(l+=`; Domain=${a}`),document.cookie=l}removeCookie(e,t={}){this.setCookie(e,"",{...t,maxAge:0})}isLocalStorageFunctional(){return typeof window<"u"&&typeof window.localStorage?.getItem=="function"&&typeof window.localStorage?.setItem=="function"&&typeof window.localStorage?.removeItem=="function"}getAuthToken(){let e=this.getCookie(this.tokenName);if(e)return e;if(this.isLocalStorageFunctional()){let t=window.localStorage.getItem(this.fallbackStorageKey);if(t)return this.setAuthToken(t),window.localStorage.removeItem(this.fallbackStorageKey),t}return null}setAuthToken(e){let t=this.currentCookieOptions();this.setCookie(this.tokenName,e,{secure:t.secure,sameSite:"lax",maxAge:this.tokenMaxAge,domain:t.domain,path:t.path})}removeAuthToken(){let e=this.currentCookieOptions();this.removeCookie(this.tokenName,{domain:e.domain,path:e.path}),this.removeCookie(this.tokenName,{domain:".pagelines.com",path:"/"}),this.isLocalStorageFunctional()&&window.localStorage.removeItem(this.fallbackStorageKey)}getDeviceId(){return this.getCookie(this.deviceIdName)}},po=new T6,N6=["https://redirect-a.invalid","https://redirect-b.invalid"];z6=c.enum(["linkedin","x","facebook","tiktok","youtube","github","instagram","threads","email","phone","website","calendar"]),A6=c.object({platform:z6,handle:c.string(),url:c.string().optional()}),O6=c.preprocess(e=>Array.isArray(e)?e.filter(t=>t&&typeof t=="object"&&t.platform&&t.handle):e,c.array(A6)),D6=["image","audio","video","document"],G0=c.enum(D6),P6=["avatar","cover","general"],B2=c.enum(P6),R6=c.enum(["processing","active","failed","deleted"]),U6=c.enum(["low","standard","high"]),j6=c.enum(["jpg","jpeg","png","gif","webp","svg"]),M6=c.enum(["mp4","webm","ogg","mov","avi"]),L6=c.enum(["mp3","wav","ogg","opus","aac","flac","webm","m4a","mp4"]),V6=c.object({mediaId:c.string(),userId:c.string(),orgId:c.string(),botId:c.string().nullable().optional(),filename:c.string(),mimeType:c.string(),size:c.number(),src:c.string(),alt:c.string().optional(),context:B2.default("general"),status:R6.default("processing"),quality:U6.default("standard"),createdAt:c.string().optional(),updatedAt:c.string().optional()}),Bt=V6.extend({mediaType:G0.optional(),className:c.string().optional(),width:c.number().optional(),height:c.number().optional(),duration:c.number().optional(),blurhash:c.string().optional()}).partial(),F6=c.object({duration:c.number().optional(),thumbnail:c.string().optional(),autoplay:c.boolean().optional(),loop:c.boolean().optional(),muted:c.boolean().optional(),controls:c.boolean().optional()}),B6=c.object({duration:c.number().optional(),autoplay:c.boolean().optional(),loop:c.boolean().optional(),muted:c.boolean().optional(),controls:c.boolean().optional()}),Z6=Bt.extend({mediaType:c.literal("image"),imageFormat:j6.optional()}),H6=Bt.extend({mediaType:c.literal("video"),videoFormat:M6.optional(),video:F6.optional()}),K6=Bt.extend({mediaType:c.literal("audio"),audioFormat:L6.optional(),audio:B6.optional()}),W6=Bt.extend({mediaType:c.literal("document")}),b7=c.discriminatedUnion("mediaType",[Z6,H6,K6,W6]),Z2=c.enum(["xxs","xs","sm","md","lg","xl"]),H2=c.enum(["primary","default","overlay","red","green","indigo","orange"]),K2=c.enum(["ghost","link","outline","solid"]),K0=c.object({key:c.string().optional(),label:c.string().optional(),href:c.string().optional(),size:Z2.optional(),theme:H2.optional(),design:K2.optional(),icon:c.union([c.string(),Bt]).optional(),iconAfter:c.union([c.string(),Bt]).optional(),rounding:c.enum(["full","md","lg"]).optional(),loading:c.boolean().optional(),disabled:c.boolean().optional(),tooltip:c.string().optional(),onClick:c.any().optional(),testId:c.string().optional(),target:c.enum(["_blank","_self"]).optional(),type:c.enum(["button","submit","reset"]).optional()}),w7=c.object({buttons:c.array(K0).optional(),size:Z2.optional(),theme:H2.optional(),design:K2.optional()}),q6=["COMPUTER_BOOT_FAILED","COMPUTER_CREATE_FAILED","BOT_DELETED","COMPUTER_DELETE_FAILED","COMPUTER_INACTIVE","COMPUTER_LIMIT","COMPUTER_NOT_FOUND","BOT_NOT_FOUND","COMPUTER_NOT_DEPLOYED","BOT_TOKENS_MISSING","COMPUTER_UNREACHABLE","COMPUTER_UPDATE_FAILED","COMPUTER_WAKE_TIMEOUT","ADMISSION_REQUIRED","ALREADY_MEMBER","ATTACHMENT_TYPE_UNSUPPORTED","AUTH_ACCOUNT_NOT_FOUND","AUTH_BOT_BLOCKED","AUTH_DISPOSABLE_EMAIL","AUTH_EMAIL_IN_USE","AUTH_INVALID","AUTH_INVALID_CODE","AUTH_INVALID_HANDOFF","AUTH_LOCKED_OUT","AUTH_MISSING","AUTH_PROVIDER_FAILED","AUTH_PROVIDER_NOT_CONFIGURED","AUTH_RATE_LIMITED","AUTH_REVOKED","AUTH_TURNSTILE_MISSING","AUTH_UNKNOWN","AUTH_WRONG_TYPE","ROUTINE_CHANNEL_UNAVAILABLE","ROUTINE_PURPOSE_REQUIRED","BOT_REPLY_FAILED","BILLING_BUDGET_REACHED","BILLING_DEMO_SPENT","BILLING_NO_PLAN","BILLING_PAST_DUE","BILLING_RUNAWAY_CAP","BILLING_SEAT_LIMIT","CHECKOUT_FAILED","CONFIRMATION_REQUIRED","CREATE_FAILED","CREDIT_LIMIT","DELETE_FAILED","DUPLICATE_INVITE","EMAIL_DELIVERY_FAILED","EMAIL_FAILED","EMAIL_MISMATCH","EMAIL_RATE_LIMITED","EMAIL_REASON_NOT_ELIGIBLE","EMPTY_STREAM","EMPTY_PATCH","ENV_VAR_CONFLICT","ENV_VAR_RESERVED","EXTENSION_INACTIVE","FORBIDDEN","HANDLE_TAKEN","IMAGE_GENERATION_FAILED","IMAGE_GENERATION_UNCONFIGURED","INTERNAL_ERROR","INVALID_FILE","INVALID_PRIMARY_CHANNEL","UNKNOWN_ROUTINE_CHANNEL","INVITE_CONFLICT","INVITE_EXPIRED","INVITE_INVALID","INVITE_LIMIT","MCP_NOT_AVAILABLE","MCP_NOT_CONFIGURED","MEDIA_NOT_FOUND","MEDIA_SERVER_UNAVAILABLE","MEDIA_UPLOAD_FAILED","MEMORY_NOT_FOUND","MISSING_IDEMPOTENCY_KEY","NETWORK_ERROR","NO_WORKSPACE","NOT_A_MEMBER","NOT_AUTHORIZED","NOT_FOUND","ORG_NOT_FOUND","OVERAGE_CAP","OWNER_LOCK","OWNER_TURN_REQUIRED","PAIRING_VERIFY_FAILED","PAYMENT_FAILED","PHONE_COUNTRY_CLOSED","PLAN_LIMIT","PROVISIONER_UNAVAILABLE","RATE_LIMIT","RATE_LIMITED","REBUILD_FAILED","RESTART_FAILED","RUNTIME_UNPROVEN","SEND_FAILED","STOP_FAILED","STREAM_DISCONNECT","STREAM_TIMEOUT","STRIPE_LOAD","TIMEOUT","TOKEN_ERROR","TOOL_PROTOCOL","TRIAL_ENDED","TURN_ACTIVE","UPLOAD_FAILED","VALIDATION_ERROR","VOICE_BUSY","VOICE_UNAVAILABLE","WAKE_FAILED"],W2=c.enum(q6),G6=9900,C2=`$${G6/100}/month`,J6=c.enum(["account","error"]),Y6=["billing_no_plan","billing_seat_limit","billing_past_due","billing_runaway_cap","billing_budget_reached","billing_demo_spent","bot_deleted","computer_not_deployed","computer_boot_failed","computer_unreachable","computer_wake_timeout","provisioner_unavailable","stream_timeout","stream_disconnect","empty_stream","tool_protocol","rate_limit"],X6=c.enum(Y6),q2=c.object({bucket:J6,code:X6,title:c.string(),help:c.string().optional(),actionLabel:c.string(),actionUrl:c.string()}),S7={billing_no_plan:{bucket:"account",title:"Billing needed",help:`Add a payment method to turn live replies back on. Plans start at ${C2} per active assistant, cancel anytime.`,actionLabel:"Open billing",oneLine:`The workspace needs a payment method before this assistant can reply; plans start at ${C2} per active assistant.`},billing_seat_limit:{bucket:"account",title:"Active assistant limit reached",help:"Your active assistants are all in use. Put one assistant to sleep or ask us to raise the ceiling.",actionLabel:"Open billing",oneLine:"The workspace has no unused active-assistant slots; one assistant must sleep or the limit must be raised."},billing_past_due:{bucket:"account",title:"Assistants paused",help:"Payment is overdue. Fix it and we\u2019ll bring your assistants back online.",actionLabel:"Fix payment",oneLine:"The workspace payment is overdue; its owner must fix it before assistants come back online."},billing_runaway_cap:{bucket:"account",title:"Usage limit reached",help:"Your workspace reached its usage limit. Review billing or contact support to keep your assistant running.",actionLabel:"Contact support",oneLine:"The workspace reached its usage limit; its owner can review billing or contact support."},billing_budget_reached:{bucket:"account",title:"Not enough credits",help:"Your workspace needs more included credits for another reply. They refill at the next billing period.",actionLabel:"Review billing",oneLine:"The workspace needs more included credits; they refill at the next billing period."},billing_demo_spent:{bucket:"account",title:"Weekly usage used up",help:"Your bot has used this week's included usage. It refills next week.",actionLabel:"",oneLine:"This bot has used this week's included usage; it refills next week."},bot_deleted:{bucket:"error",title:"Assistant deleted",help:"This chat is still here, but the assistant can no longer reply.",actionLabel:"",oneLine:"This assistant was deleted. The chat history remains, but it can no longer reply."},computer_not_deployed:{bucket:"error",title:"Assistant asleep",help:"Open the assistant profile to wake it up before chatting.",actionLabel:"Open assistant",oneLine:"This assistant needs to wake up before it can reply."},computer_boot_failed:{bucket:"error",title:"Couldn't wake up",help:"Open the assistant profile to restart it or check what failed.",actionLabel:"Open assistant",oneLine:"This assistant tried to wake up but hit an error."},computer_unreachable:{bucket:"error",title:"Not responding",help:"Open the assistant profile to check status or restart it.",actionLabel:"Open assistant",oneLine:"This assistant is not responding right now; its owner can check its status."},computer_wake_timeout:{bucket:"error",title:"Still starting",help:"It is still starting up. Send your message again in a minute, or open the assistant to see what it is doing.",actionLabel:"Open assistant",oneLine:"This assistant is still starting up; send your message again in a minute."},provisioner_unavailable:{bucket:"error",title:"Couldn't reach computer",help:"PageLines couldn't reach your assistant's computer for a moment. Send your message again.",actionLabel:"Try again",oneLine:"PageLines couldn't reach this assistant's computer for a moment; try the message again."},stream_timeout:{bucket:"error",title:"Reply too slow",help:"Your assistant took too long to start replying. Try your message again.",actionLabel:"Try again",oneLine:"This assistant took too long to start replying; try the message again."},stream_disconnect:{bucket:"error",title:"Connection lost",help:"The connection dropped while your assistant was replying. Send your message again to retry.",actionLabel:"Try again",oneLine:"The connection dropped while this assistant was replying; try the message again."},empty_stream:{bucket:"error",title:"Empty reply",help:"Your assistant could not generate a reply. Try your message again.",actionLabel:"Try again",oneLine:"This assistant did not return a reply; try the message again."},tool_protocol:{bucket:"error",title:"Tool call failed",help:"Your assistant tried to use a tool in a format PageLines could not run. Try the message again.",actionLabel:"Try again",oneLine:"This assistant tried to use a tool in a format PageLines could not run; try the message again."},rate_limit:{bucket:"error",title:"Slow down",help:"Too many messages at once. Wait a moment, then send your message again.",actionLabel:"Try again",oneLine:"Too many messages arrived at once; wait a moment and try again."}},G2=c.enum(["unknown","stopped","starting","running","unreachable","error"]),Q6=c.enum(["wake","restart","rebuild","config_apply","setup"]),e3=c.enum(["running","coalesced","failed"]),t3=c.object({kind:Q6,status:e3,startedAt:c.string().datetime(),detail:c.string().optional()}).strict(),J2=c.object({lifecycle:G2,changedAt:c.string().datetime().optional(),detail:c.string().optional(),blocker:q2.optional(),operation:t3.optional()}).strict(),Kl=Object.freeze({lifecycle:"unknown"}),r3={running:"green",starting:"amber",unreachable:"red",error:"red",stopped:"grey",unknown:"grey"},n3=c.enum(["awake","asleep","changing","stuck"]),Y2={awake:"Awake",asleep:"Asleep",changing:"Changing",stuck:"Needs attention"};i3={running:"Online",starting:"Waking up",unreachable:"Unreachable",error:"Error",stopped:"Asleep",unknown:"Checking"},o3={wake:"Waking up",restart:"Restarting",rebuild:"Restarting",config_apply:"Applying config",setup:"Setting up"};I7=c.enum(["wake","sleep","restart","rebuild"]);l3=c.object({key:c.string().optional(),id:c.string().optional(),label:c.string().optional(),srLabel:c.string().optional(),subLabel:c.string().optional(),value:c.union([c.string(),c.number()]).optional(),description:c.string().optional(),state:n3.optional(),count:c.number().optional(),className:c.string().optional(),media:Bt.optional(),subMedia:Bt.optional(),cover:Bt.optional(),icon:Bt.optional(),iconAfter:Bt.optional(),subIcon:c.string().optional(),href:c.string().optional(),target:c.enum(["_self","_blank"]).optional(),onClick:c.any().optional(),theme:c.enum(["primary","default"]).optional(),isActive:c.boolean().optional(),isDisabled:c.boolean().optional(),isHidden:c.boolean().optional(),priority:c.number().optional(),testId:c.string().optional(),items:c.array(c.any()).optional(),badges:c.array(K0).optional(),meta:c.array(K0).optional(),menuItems:c.array(c.any()).optional()}),E7=c.object({title:c.string().optional(),description:c.string().optional(),items:c.array(l3).optional()}),Q2=c.string().trim().transform(e=>{if(!e.includes("/"))return e;try{let t=new URL(/^https?:\/\//i.test(e)?e:`https://${e}`),[n,i]=t.pathname.split("/").filter(Boolean),r=t.hostname.toLowerCase();if((r==="linkedin.com"||r.endsWith(".linkedin.com"))&&n?.toLowerCase()==="in"&&i)return i}catch{}return e}).pipe(c.string().min(3).max(100).regex(/^[a-zA-Z0-9-]+$/,"Use a LinkedIn username or profile URL")),c3=c.string().trim().transform((e,t)=>{try{let n=new URL(/^https?:\/\//i.test(e)?e:`https://${e}`),i=n.hostname.toLowerCase().replace(/^www\./,""),r=n.pathname.split("/").filter(Boolean)[0];if(!r||!["x.com","twitter.com","facebook.com"].includes(i))throw new Error("unsupported profile");return i==="twitter.com"?`https://x.com/${r}`:`https://${i}/${r}`}catch{return t.addIssue({code:"custom",message:"Use a LinkedIn username or an X or Facebook profile URL"}),c.NEVER}}),J0=c.string().trim().toLowerCase().pipe(c.email()),u3=c.enum(["member","pending"]),d3=c.object({lastBotId:c.string().nullable().optional(),userId:c.string(),email:c.string().optional(),handle:c.string().optional(),fullName:c.string().optional(),bio:c.string().optional(),linkedinUsername:Q2.optional(),avatarId:c.string().optional(),avatar:Bt.optional(),isEmailVerified:c.boolean().optional(),primaryOrgId:c.string().optional(),lastActiveOrgId:c.string().optional(),onboarding:c.any().optional(),location:c.string().optional(),geo:c.any().optional(),systemRole:c.string().optional(),status:c.string().optional(),lastSeenAt:c.string().optional(),admittedAt:c.string().optional(),access:u3.optional(),isMember:c.boolean().optional(),createdAt:c.string().optional(),updatedAt:c.string().optional(),onboarded:c.boolean().optional()}),N7=c.object({email:J0}),C7=c.object({email:J0,code:c.string().min(6,"Verification code is required"),timezone:c.string().max(64).optional(),phone:c.string().trim().min(7).max(30).optional(),phoneProof:c.string().max(300).optional()}),p3=c.object({phone:c.string().trim().min(7).max(30),purpose:c.enum(["apply","sign_in"]).optional(),invite:c.string().trim().max(64).optional()}),z7=c.object({codeSent:c.boolean()}),A7=p3.extend({code:c.string().trim().min(4).max(10)}),O7=c.object({phoneProof:c.string()}),D7=c.object({phone:c.string().trim().min(7).max(30),phoneProof:c.string().max(300),timezone:c.string().max(64).optional(),join:c.object({inviteCode:c.string().trim().max(64),name:c.string().trim().min(1,"Add your name").max(120),email:c.string().trim().toLowerCase().email("Enter your email").max(255),city:c.string().trim().min(1,"Add your city").max(120),placeId:c.string().max(16).optional()}).optional()}),P7=c.object({newEmail:J0}),R7=c.object({credential:c.string().optional(),code:c.string().optional(),timezone:c.string().max(64).optional(),source:c.enum(["web","ios"]).optional()}).refine(e=>e.credential||e.code,{message:"Either credential or code must be provided"}),U7=c.object({identityToken:c.string().min(1),fullName:c.string().optional(),timezone:c.string().max(64).optional()}),eI=c.object({orgId:c.string().optional(),handle:c.string().optional(),name:c.string().optional(),email:c.string().nullable().optional(),website:c.string().url().nullable().optional(),summary:c.string().nullable().optional(),avatarId:c.string().nullable().optional(),avatar:Bt.optional(),coverId:c.string().nullable().optional(),cover:Bt.optional(),accounts:O6.nullable().optional(),ownerId:c.string().optional(),isPersonal:c.boolean().optional(),stripeCustomerIdTest:c.string().nullable().optional(),stripeCustomerIdLive:c.string().nullable().optional(),maxUsers:c.number().optional(),timezone:c.string().nullable().optional(),apiKey:c.string().nullable().optional(),syncedPlan:c.string().nullable().optional(),syncedBillingStatus:c.string().nullable().optional(),firstPaidAt:c.string().nullable().optional(),entitlementDeleteAt:c.string().nullable().optional(),billingLastSyncedAt:c.string().nullable().optional(),syncedPeriodStart:c.string().nullable().optional(),syncedPeriodEnd:c.string().nullable().optional(),onboarding:c.any().optional(),status:c.string().optional(),createdAt:c.string().optional(),updatedAt:c.string().optional()}),m3=c.object({completedAt:c.string().datetime().optional(),setupBy:c.string().optional(),billingSetup:c.boolean().optional(),teamInvitesSetup:c.boolean().optional(),brandingSetup:c.boolean().optional(),domainsSetup:c.boolean().optional()}),f3=c.object({membershipId:c.string(),orgId:c.string(),name:c.string(),handle:c.string(),avatarId:c.string().optional(),avatar:Bt.optional(),coverId:c.string().optional(),cover:Bt.optional(),role:c.enum(["owner","admin","member","observer"]),inviterName:c.string().optional(),memberCount:c.number().optional(),hasComputer:c.boolean().optional(),computerCount:c.number().optional(),joinedAt:c.string().datetime(),onboarding:m3.optional()}),h3=d3.extend({orgs:c.array(f3).optional()}),z2=[["#6366f1","#8b5cf6"],["#3b82f6","#06b6d4"],["#10b981","#34d399"],["#f59e0b","#f97316"],["#ef4444","#f97316"],["#ec4899","#8b5cf6"],["#14b8a6","#3b82f6"],["#8b5cf6","#ec4899"]];b3=["[SILENT]","SILENT","NO_REPLY","NO REPLY","NO-OP","NOOP","NO_OP","NO OP","[NO-OP]","[NOOP]","[NO_OP]","[NO OP]","HEARTBEAT_OK"],y3=new Set(b3);tI={wake:300*1e3,bootGrace:420*1e3,provision:600*1e3,firstStart:45*1e3,stop:30*1e3},A2={AUTH_ACCOUNT_NOT_FOUND:"Account not found. Ask your workspace admin for an invite.",AUTH_INVALID:"Your session has expired. Sign in again to continue.",AUTH_LOCKED_OUT:"Too many failed attempts. Request a new code to try again.",AUTH_INVALID_CODE:"That code didn't match. Double-check the email and try again.",AUTH_INVALID_HANDOFF:"This link has expired. Open the dashboard from the app again.",AUTH_DISPOSABLE_EMAIL:"Please use your work email address.",AUTH_RATE_LIMITED:"Too many requests. Wait a minute and try again.",AUTH_PROVIDER_FAILED:"Sign-in failed. Try again or use email instead.",AUTH_PROVIDER_NOT_CONFIGURED:"That sign-in method isn't available right now.",ADMISSION_REQUIRED:"PageLines is invite-only. Request access to create your bot.",PLAN_LIMIT:"Your active computers are all in use. Put one computer to sleep or ask us to raise the ceiling.",CREDIT_LIMIT:"Your workspace reached its usage limit. Review billing or contact support to keep your assistant running.",STRIPE_LOAD:"Couldn't open checkout. Try again \u2014 if it persists, contact support.",CHECKOUT_FAILED:"Couldn't start checkout. Try again in a moment.",PAYMENT_FAILED:"Your payment couldn't go through. Update your card to continue.",WAKE_FAILED:"Your assistant didn't wake up. Try again in a moment.",VOICE_BUSY:"Your assistant is on another call. Try again in a moment.",VOICE_UNAVAILABLE:"Voice isn't available right now. Try again in a moment.",STOP_FAILED:"Couldn't put your assistant to sleep. Try again.",RESTART_FAILED:"Restart didn't finish. Try again \u2014 if it persists, rebuild.",REBUILD_FAILED:"Restart didn't finish. Try again or contact support.",CREATE_FAILED:"Couldn't create your assistant. Try again in a moment.",DELETE_FAILED:"Couldn't delete your assistant. Try again \u2014 your data is safe.",BOT_NOT_FOUND:"We couldn't find that assistant.",COMPUTER_NOT_FOUND:"We couldn't find that computer.",COMPUTER_INACTIVE:"This computer is off. Turn it on to start it.",ATTACHMENT_TYPE_UNSUPPORTED:"Your assistant can't read this file type yet.",ROUTINE_CHANNEL_UNAVAILABLE:"Your delivery channel isn't reachable. Pair it again or choose PageLines Messenger.",ROUTINE_PURPOSE_REQUIRED:"Say what the scheduled message or work should contain.",NETWORK_ERROR:"Network issue. Check your connection and try again.",TIMEOUT:"The request took too long. Try again in a moment.",FORBIDDEN:"You don't have access to this.",RATE_LIMITED:"Too many requests. Wait a moment and try again."};rI=c.enum(["active","stopped"]),x3=c.enum(["notFound","busy","rateLimited","timeout","invalidConfig","transient","fatal"]),L7=c.object({ok:c.literal(!1),error:c.string(),code:W2.optional(),issue:q2.optional(),providerErrorKind:x3.optional()}),_3=c.object({kind:c.enum(["icon","favicon","service"]),icon:c.string().min(1).optional(),domain:c.string().min(1).optional(),serviceKey:c.string().min(1).optional()}).strict(),nI=c.object({activityId:c.string().min(1),turnId:c.string().min(1),status:c.enum(["started","completed","failed"]),label:c.string().trim().min(1),kind:c.enum(["search","file","image","service","routine","handoff","other"]),toolName:c.string().min(1).optional(),serviceKey:c.string().min(1).optional(),startedAt:c.string().datetime().optional(),endedAt:c.string().datetime().optional(),durationMs:c.number().int().nonnegative().optional(),note:c.string().trim().min(1).optional(),visual:_3.optional()}).strict(),$3=nI.extend({status:c.enum(["completed","failed"])}),Yn=c.string().min(1).max(64).refine(e=>{try{return new Intl.DateTimeFormat("en-US",{timeZone:e}).format(new Date(0)),!0}catch{return!1}},"Invalid IANA timezone");oI=G0,S3=c.object({kind:c.literal("inline"),offset:c.number().int().nonnegative()}),aI=c.object({type:oI,src:c.url(),filename:c.string().min(1),mimeType:c.string().min(1),mediaId:c.string().min(1).optional(),size:c.number().int().nonnegative().optional(),width:c.number().int().positive().optional(),height:c.number().int().positive().optional(),duration:c.number().nonnegative().optional(),text:c.string().optional(),placement:S3.optional()}),sI=c.object({ref:c.string().min(1).max(256)}).strict(),lI=c.enum(["handled","dismissed","deferred"]),cI=c.iso.datetime();I3=sI.extend({disposition:lI.optional(),revisitAt:cI.optional()}).superRefine(uI),H7=sI.extend({disposition:lI,revisitAt:cI.optional()}).superRefine(uI),E3=c.object({turnId:c.string().min(1).optional(),turnOutcome:c.enum(["failed","stopped"]).optional(),attachments:c.array(aI).optional(),toolActivities:c.array($3).optional(),issue:c.object({code:c.string(),bucket:c.enum(["account","error"]),actionLabel:c.string(),actionUrl:c.string(),help:c.string().optional()}).optional(),notification:c.object({push:c.boolean().optional(),excludeUserId:c.string().min(1).optional()}).optional(),routine:c.object({run:c.object({routineRunId:c.string(),name:c.string().optional(),sourceKind:c.enum(["webhook","schedule","manual","heartbeat"]),sourceLabel:c.string().optional(),deliveryId:c.string().optional(),status:c.enum(["received","forwarded","owner_notified","needs_approval","completed","failed","dropped"])}).catchall(c.unknown())}).catchall(c.unknown()).optional(),voiceDelegated:c.literal(!0).optional(),ownerHandoff:c.literal(!0).optional(),attention:c.array(I3).max(20).optional()}).catchall(c.unknown()),T3=c.object({messageId:c.string().min(1),conversationId:c.string().min(1),role:c.enum(["user","assistant","system"]),authorParticipantId:c.string().nullable(),systemKind:c.string().nullable(),content:c.string(),sequence:c.string().min(1),clientNonce:c.string().nullable().optional(),metadata:E3.nullable().optional(),status:c.string().nullable().optional(),createdAt:c.string(),updatedAt:c.string()}),Y0=c.object({type:oI,mediaId:c.string().min(1)}),K7=c.object({conversationId:c.string().min(1),content:c.string().max(1e4).default(""),clientNonce:c.string().max(64).optional(),attachments:c.array(Y0).max(10).optional(),channel:c.enum(["ios","dashboard"]).optional(),actionUrls:c.object({billing:c.string().max(500),bot:c.string().max(500)}).optional(),viewerTimezone:Yn.optional()}).refine(e=>e.content.trim().length>0||(e.attachments?.length??0)>0,{path:["content"],message:"Message or attachment required"}),dI=c.object({type:c.enum(["user","bot"]),id:c.string().min(1)}).strict();W7=c.object({orgId:c.string().min(1),participants:c.array(dI).min(1).max(20)}).strict().superRefine(pI),q7=c.object({orgId:c.string().min(1),participants:c.array(dI).min(1).max(20)}).strict().superRefine((e,t)=>{pI(e,t),e.participants.some(n=>n.type==="bot")||t.addIssue({code:"custom",path:["participants"],message:"New sessions require at least one agent participant."})}),G7=c.object({category:c.string().min(1).max(30).optional(),reason:c.string().max(2e3).optional()}).strict(),J7=c.object({shareId:c.string(),url:c.string(),createdAt:c.string()}),Y7=c.object({shareId:c.string(),botName:c.string(),botAvatarUrl:c.string().nullable(),prompt:c.string().nullable(),content:c.string(),createdAt:c.string()}),N3=c.enum(["1:1","4:3","3:4","16:9","9:16"]),C3=c.enum(["1K","2K","4K"]),X7=c.object({prompt:c.string().trim().min(1).max(4e3),aspectRatio:N3.default("1:1"),outputFormat:c.enum(["png","jpeg","webp"]).default("webp"),resolution:C3.default("2K"),style:c.string().trim().max(200).optional(),altText:c.string().trim().max(500).optional(),referenceMediaIds:c.array(c.string().min(1)).max(4).optional()}).strict(),Q7=c.object({mediaId:c.string().min(1),src:c.url(),filename:c.string().min(1),mimeType:c.string().min(1),width:c.number().int().positive().optional(),height:c.number().int().positive().optional(),provider:c.string().min(1).optional(),providerRequestId:c.string().min(1).optional(),media:c.string().startsWith("MEDIA:"),attachment:aI.extend({type:c.literal("image")})}),tZ=c.object({identityToken:c.string().min(1),fullName:c.string().optional()}),z3=c.object({redirect:c.string(),redirectReason:c.string(),isNew:c.boolean(),deviceId:c.string()}),rZ=c.object({ok:c.literal(!0),data:z3,token:c.string()}),nZ=c.object({path:c.string().startsWith("/","path must be a relative dashboard path").refine(C6,"path must be a relative dashboard path")}),A3=c.object({url:c.string()}),iZ=c.object({ok:c.literal(!0),data:A3}),oZ=c.object({token:c.string().min(1)}),O3=c.object({redirect:c.string(),redirectReason:c.string(),deviceId:c.string()}),aZ=c.object({ok:c.literal(!0),data:O3,token:c.string()}),mI=B2,D3=G0,W0=c.object({mediaId:c.string(),src:c.string(),alt:c.string().nullable().optional(),filename:c.string().optional(),displayName:c.string().nullable().optional(),mimeType:c.string().optional(),mediaType:D3.optional(),size:c.number().optional(),width:c.number().nullable().optional(),height:c.number().nullable().optional(),duration:c.number().nullable().optional(),context:mI.nullable().optional(),blurhash:c.string().nullable().optional(),quality:c.string().optional(),status:c.string().optional(),userId:c.string().optional(),orgId:c.string().optional(),botId:c.string().nullable().optional(),createdAt:c.string().optional(),updatedAt:c.string().optional()}),uZ=c.object({file:c.string().describe("Binary file. multipart/form-data field \u2014 the actual upload. The server validates type + size and normalizes image uploads before storage. Audio/video/document uploads use the same uploader and are classified by MIME type."),context:mI.optional().default("general"),botId:c.string().optional(),orgId:c.string().optional(),duration:c.number().optional()}),fI=c.object({viewerTimezone:Yn.optional(),location:c.object({label:c.string().max(500),city:c.string().optional(),region:c.string().optional(),countryCode:c.string().optional(),timezone:c.string().optional(),source:c.literal("geoip"),precision:c.enum(["city","region","country"]),confidence:c.enum(["medium","low"]),vpnOrDatacenter:c.enum(["likely","unknown"])}).optional()}),P3=c.object({status:c.enum(["available","unavailable"]),user:c.string().max(16e3).optional(),memory:c.string().max(16e3).optional(),agents:c.string().max(4e3).optional()}).strict(),fZ=c.object({bot:c.object({id:c.string(),name:c.string(),title:c.string().nullable().optional(),timezone:Yn}),scope:c.enum(["private","org","public"]),channel:c.string().max(120),currentTime:c.iso.datetime(),scopePrompt:c.string().optional(),observations:fI.optional(),lastObservedTimezone:Yn.optional(),lean:P3.optional(),servicesNeedingSetup:c.array(c.object({name:c.string(),state:c.string()})).optional()}),hZ=c.object({reason:c.enum(["idle-timeout","session-cap","unavailable"])}).strict(),hI=c.enum(["woman","man"]),R3=[{key:"ava",gender:"woman",accent:"American",character:"Warm, patient and understanding",isDefault:!0},{key:"hope",gender:"woman",accent:"American",character:"Soft-spoken, smooth and kind"},{key:"lauren",gender:"woman",accent:"American",character:"Friendly, comforting and soft"},{key:"amy",gender:"woman",accent:"American",character:"Natural and sweet"},{key:"eve",gender:"woman",accent:"American",character:"Authentic, energetic and happy"},{key:"jessica",gender:"woman",accent:"British",character:"Smooth, articulate and warm"},{key:"adam",gender:"man",accent:"American",character:"Engaging, friendly and bright",isDefault:!0},{key:"jon",gender:"man",accent:"American",character:"Relaxed, deep and approachable"},{key:"joe",gender:"man",accent:"British",character:"Reflective and thoughtful"},{key:"peter",gender:"man",accent:"Australian",character:"Deep, warm and direct"}],gI=c.enum(R3.map(e=>e.key)),gZ=c.object({conversationId:c.string().min(1),viewerTimezone:Yn.optional()}).strict(),vZ=c.object({conversationId:c.string().min(1),botId:c.string().min(1),personaName:c.string().min(1),personaTitle:c.string().max(255).nullable().optional(),gender:hI,voiceKey:gI.nullable(),sessionScope:c.enum(["private","org","public"]),observations:fI.optional(),threadSummary:c.string(),capabilities:c.array(c.object({name:c.string().min(1),description:c.string().min(1)})).optional(),maxDurationSeconds:c.number().int().positive().max(3600).optional(),expiresAt:c.iso.datetime()}),U3=c.literal("livekit"),bZ=c.object({name:c.enum(["voice.ready","voice.first_playback","voice.failed"]),client:c.enum(["web","ios"]),botId:c.string().min(1).max(64).optional(),conversationId:c.string().min(1).max(64).optional(),provider:U3.optional(),durationMs:c.number().int().min(0).max(36e5),phase:c.enum(["idle","minting","connecting","live","ended"]).optional(),code:c.string().min(1).max(64).optional(),detail:c.string().min(1).max(300).optional(),appVersion:c.string().min(1).max(32).optional(),appBuild:c.string().min(1).max(32).optional()}).strict(),yZ=c.object({provider:c.literal("livekit"),url:c.string().min(1),token:c.string().min(1),room:c.string().min(1)}).strict(),j3=c.enum(["identity","working-style","complete"]),M3=c.string().min(1).max(50).regex(/^[a-z0-9]+(?:-[a-z0-9]+)*$/),Zl=c.object({botId:c.string().min(1),computerId:c.string().min(1),handle:c.string().min(2).max(50),name:c.string().min(1).max(100),emoji:c.string().max(8).nullable().optional(),title:c.string().max(120).nullable().optional(),summary:c.string().max(500).nullable().optional(),avatarId:c.string().nullable().optional(),coverId:c.string().nullable().optional(),avatar:Bt.optional(),cover:Bt.optional(),email:c.email().nullable().optional(),website:c.url().nullable().optional(),accounts:c.array(c.object({platform:c.enum(["linkedin","x","facebook","tiktok","youtube","github","instagram","threads","email","phone","website"]),handle:c.string()})).nullable().optional(),gender:hI.optional(),voiceKey:gI.nullable().optional(),isPrimary:c.boolean(),collaborationEnabled:c.boolean(),publicChatEnabled:c.boolean(),status:c.enum(["active","deleted"]),onboardingStage:j3.nullable().optional(),onboardedAt:c.string().nullable().optional(),routinePrimaryChannel:M3.optional(),firstMessageAt:c.string().nullable().optional(),firstValueAt:c.string().nullable().optional(),lastMessageAt:c.string().nullable().optional(),createdAt:c.string(),updatedAt:c.string()}).strict(),X0=Zl.pick({name:!0,emoji:!0,title:!0,summary:!0,gender:!0,voiceKey:!0}).extend({handle:Zl.shape.handle.optional(),avatarPreset:c.string().min(1).max(64).optional(),avatarMediaId:c.string().optional()}).strict(),wZ=X0.extend({computerId:c.string().min(1)}).strict(),kZ=Zl.pick({name:!0,handle:!0,emoji:!0,title:!0,summary:!0,email:!0,website:!0,gender:!0,voiceKey:!0,routinePrimaryChannel:!0,collaborationEnabled:!0,publicChatEnabled:!0}).partial().extend({avatarMediaId:c.string().nullable().optional(),coverMediaId:c.string().nullable().optional()}).strict(),vI=c.enum(["essential","pro","business"]),bp=J2.partial().extend({computerId:c.string().min(1),ownerId:c.string().min(1),owner:c.object({userId:c.string(),fullName:c.string().optional(),avatar:W0.optional()}).optional(),orgId:c.string().min(1),name:c.string().min(1).max(100),model:c.string().nullable(),timezone:Yn,billingTier:vI,desiredStatus:rI.nullable(),status:c.enum(["active","deleted"]),lastActiveAt:c.string().nullable().optional(),createdAt:c.string(),updatedAt:c.string()}).strict(),xZ=c.object({orgId:c.string().min(1),name:bp.shape.name.optional(),timezone:Yn.optional(),primaryBot:X0}).strict(),_Z=bp.pick({name:!0,model:!0,timezone:!0}).partial().strict(),L3=c.enum(["none","active_assistant"]),V3=c.enum(["none","active","trial","canceling","past_due","paused"]),F3=c.object({brand:c.string(),last4:c.string(),expMonth:c.number(),expYear:c.number()}),B3=c.object({date:c.string(),amount:c.number(),status:c.string(),invoicePdf:c.string().optional()}),Z3=c.object({graceEndsAt:c.string().optional(),suspended:c.boolean(),url:c.string().optional()}),$Z=c.object({plan:L3,status:V3,price:c.number(),tierRates:c.record(c.string(),c.number()).optional(),maxComputers:c.number(),activeComputers:c.number(),workspaceTier:vI.exclude(["essential"]).optional(),upcomingAmountDue:c.number().optional(),upcomingDueDate:c.string().optional(),nextBillDate:c.string().optional(),cancelAtPeriodEnd:c.boolean().optional(),cancelAt:c.string().optional(),trialEnd:c.string().optional(),trialDaysRemaining:c.number().optional(),paymentMethod:F3.optional(),paymentRecovery:Z3.optional(),invoices:c.array(B3),stripeError:c.string().optional()}),H3=c.enum(["demo_computer_exists","subscription_required","plan_limit"]),SZ=c.object({canCreate:c.boolean(),activeComputers:c.number().int().nonnegative(),computerLimit:c.number().int().nonnegative(),isDemo:c.boolean(),reason:H3.optional()}),IZ=c.object({orgId:c.string(),computerName:c.string().optional(),runtime:c.string().optional()}),K3=J2,W3=c.object({code:W2,message:c.string(),bucket:c.enum(["account","error"]),actionLabel:c.string().optional(),actionUrl:c.string().optional(),help:c.string().optional()}),q3=c.discriminatedUnion("event",[c.object({event:c.literal("status"),data:K3}),c.object({event:c.literal("message"),data:c.object({message:T3})}),c.object({event:c.literal("message_delta"),data:c.object({delta:c.string(),turnId:c.string(),messageId:c.string().optional(),role:c.enum(["assistant","system"]).optional()})}),c.object({event:c.literal("working_state"),data:c.object({description:c.string(),turnId:c.string().optional()})}),c.object({event:c.literal("tool_activity"),data:nI}),c.object({event:c.literal("working_end"),data:c.object({turnId:c.string().optional()}).strict()}),c.object({event:c.literal("stream_end"),data:c.object({turnId:c.string().optional()}).strict()}),c.object({event:c.literal("error"),data:W3})]);Q3=c.object({label:c.string().trim().min(1).max(40),reply:c.string().trim().min(1).max(500),style:c.enum(["primary","default","destructive"]).optional()}).strip(),eD=c.object({version:c.literal(1),title:c.string().trim().min(1).max(200),body:c.string().trim().min(1).max(8e3).optional(),actions:c.array(Q3).min(1).max(3).optional()}).strip();tD=c.string().trim().min(1).max(240),q0=c.string().trim().min(1).max(800),Xn=c.string().trim().min(1).max(80).regex(/^[A-Za-z0-9_.:-]+$/),Fa=c.string().trim().min(1).max(120),rD=c.union([c.string().max(500),c.number().finite(),c.boolean(),c.null()]),kI=c.record(Xn,rD),nD=c.enum(["compact","currency","duration","integer","percent","raw"]),iD=c.object({title:tD,description:q0.optional(),footer:q0.optional()}).strip(),xI=c.object({dataKey:Xn,label:Fa.optional(),axisLabel:Fa.optional(),valueFormat:nD.optional(),valuePrefix:c.string().trim().max(12).optional(),valueSuffix:c.string().trim().max(12).optional()}).strip(),oD=c.object({kind:c.literal("linear"),dataKey:Xn,label:Fa.optional()}).strip(),ey=c.object({version:c.literal(1),meta:iD,fallbackMarkdown:c.string().trim().min(1).max(4e3)}).strip();sD=ey.extend({visualType:c.literal("chart"),chartType:c.enum(["bar","line","scatter"]),xKey:Xn,xAxisLabel:Fa.optional(),series:c.array(xI).min(1).max(6),data:c.array(kI).min(1).max(120),layout:c.enum(["horizontal","vertical"]).optional(),stacking:c.enum(["grouped","stacked"]).optional(),trendLine:oD.optional()}).strip().superRefine((e,t)=>{e.stacking&&e.chartType!=="bar"&&t.addIssue({code:"custom",path:["stacking"],message:"Stacking is only supported for bar charts"}),e.trendLine&&e.chartType!=="line"&&e.chartType!=="scatter"&&t.addIssue({code:"custom",path:["trendLine"],message:"Trend lines are only supported for line and scatter charts"}),_I(e.data,[{path:["xKey"],value:e.xKey},...e.series.map((n,i)=>({path:["series",i,"dataKey"],value:n.dataKey})),...e.trendLine?[{path:["trendLine","dataKey"],value:e.trendLine.dataKey}]:[]],t),$I(e.data,[...e.series.map((n,i)=>({path:["series",i,"dataKey"],value:n.dataKey})),...e.trendLine?[{path:["trendLine","dataKey"],value:e.trendLine.dataKey}]:[]],t)}),lD=ey.extend({visualType:c.literal("chart"),chartType:c.literal("pie"),nameKey:Xn,valueKey:Xn,series:c.array(xI).max(1).optional(),data:c.array(kI).min(1).max(16)}).strip().superRefine((e,t)=>{_I(e.data,[{path:["nameKey"],value:e.nameKey},{path:["valueKey"],value:e.valueKey},...(e.series??[]).map((n,i)=>({path:["series",i,"dataKey"],value:n.dataKey}))],t),$I(e.data,[{path:["valueKey"],value:e.valueKey,nonnegative:!0}],t)}),cD=c.discriminatedUnion("chartType",[sD,lD]),uD=c.object({id:Xn,label:Fa,detail:q0.optional(),kind:c.enum(["actor","agent","decision","event","input","output","system","task"]).optional()}).strip(),dD=c.object({from:Xn,to:Xn,label:Fa.optional()}).strip(),pD=ey.extend({visualType:c.literal("diagram"),diagramType:c.enum(["flow","org","sequence","state"]),layout:c.enum(["auto","left-to-right","radial","top-to-bottom"]).default("auto"),nodes:c.array(uD).min(1).max(24),edges:c.array(dD).max(48)}).strip().superRefine((e,t)=>{let n=new Set(e.nodes.map(i=>i.id));for(let[i,r]of e.edges.entries())n.has(r.from)||t.addIssue({code:"custom",path:["edges",i,"from"],message:`Unknown node id "${r.from}"`}),n.has(r.to)||t.addIssue({code:"custom",path:["edges",i,"to"],message:`Unknown node id "${r.to}"`})}),O2=c.union([cD,pD]);II=c.object({conversationParticipantId:c.string().min(1),type:c.enum(["user","bot","anonymous"]),id:c.string(),role:c.enum(["owner","requester","member"]),status:c.enum(["active","left","deleted"]),displayName:c.string().optional(),handle:c.string().optional(),avatarUrl:c.string().optional()}).strict(),EI=c.object({messageId:c.string(),role:c.enum(["user","assistant","system"]),content:c.string(),sequence:c.string(),createdAt:c.string()}),zZ=c.object({conversationId:c.string(),orgId:c.string(),kind:c.enum(["direct","group"]),updatedAt:c.string(),viewerRole:c.enum(["owner","requester","member"]),participants:c.array(II),lastMessage:EI.nullable(),openingMessage:c.string().nullable(),unreadCount:c.number().int().nonnegative(),latestSequence:c.string().nullable()}),AZ=c.object({sequence:c.string().min(1)}),OZ=c.object({turnId:c.string().min(1).optional()}).strict(),DZ=c.object({cancelled:c.boolean(),cancelledTurnIds:c.array(c.string())}).strict(),PZ=c.object({conversationId:c.string(),messageId:c.string(),sequence:c.string(),snippet:c.string(),createdAt:c.string(),participants:c.array(II)}),RZ=c.object({conversationId:c.string(),lastMessage:EI.nullable(),unreadCount:c.number().int().nonnegative(),latestSequence:c.string().nullable()}),Zr=c.preprocess(e=>e===void 0?null:e,c.string().nullable()),bD=c.preprocess(e=>e===void 0?null:e,G2.nullable()),yD=c.preprocess(e=>e===void 0?null:e,rI.nullable()),wD=c.preprocess(e=>e===void 0?null:e,c.enum(["user","assistant","system"]).nullable()),D2=c.preprocess(e=>e===void 0?0:e,c.number()),kD=c.object({computerId:c.string(),handle:c.string(),name:c.string(),orgId:c.string(),orgName:Zr,orgHandle:Zr,ownerEmail:Zr,ownerName:Zr,state:bD,desiredStatus:yD,runtime:c.string(),imageVersion:Zr,lastHealthyAt:Zr,lastActiveAt:Zr,lastUserMessageAt:Zr,lastMessageAt:Zr,lastMessageRole:wD,lastMessageChannel:Zr,primaryChannel:Zr,totalMessages:D2,totalSessions:D2,error:Zr,appHandle:c.string(),hostAppExists:c.boolean(),plan:c.string(),billingStatus:c.string(),billingActive:c.boolean(),createdAt:c.string(),updatedAt:c.string()}),xD=c.object({running:c.number(),stopped:c.number(),error:c.number(),starting:c.number(),unknown:c.number(),total:c.number()}),jZ=c.object({computers:c.array(kD),summary:xD,orphanedApps:c.array(c.string()),dailyMessages30d:c.array(c.number().int()).optional(),hostAppCount:c.number().optional(),latestVersions:c.record(c.string(),c.string()).optional()}),_D=c.object({mediaId:c.string().optional(),src:c.string().optional(),alt:c.string().optional(),width:c.number().optional(),height:c.number().optional(),mimeType:c.string().optional(),mediaType:c.string().optional(),blurhash:c.string().optional()}),LZ=c.object({membershipId:c.string(),userId:c.string(),orgId:c.string(),email:c.string(),fullName:c.string().optional(),role:c.enum(["owner","admin","member","observer"]),status:c.enum(["active","suspended"]),joinedAt:c.string(),lastSeenAt:c.string().optional(),avatar:_D.optional()}),VZ=c.object({invitationId:c.string(),email:c.string(),role:c.enum(["admin","member"]),status:c.string(),expiresAt:c.string(),createdAt:c.string()}),$D=c.object({token:c.string(),email:c.string(),orgId:c.string(),orgName:c.string(),orgInitial:c.string(),inviterName:c.string().optional(),inviterEmail:c.string(),role:c.enum(["owner","admin","member","observer"]),status:c.enum(["pending","accepted","expired","revoked"]),expiresAt:c.string(),memberCount:c.number().optional()}),FZ=c.object({email:c.string().email(),role:c.enum(["admin","member"]).optional(),message:c.string().max(500).optional()}).strict(),BZ=c.object({role:c.enum(["admin","member"])}).strict(),ZZ=c.object({token:c.string().min(1)}).strict(),HZ=c.object({message:c.string()}),KZ=c.object({invitationId:c.string(),message:c.string()}),WZ=c.object({message:c.string(),membershipId:c.string(),orgId:c.string(),role:c.enum(["owner","admin","member","observer"])}),qZ=c.object({invite:$D.nullable()}),SD={};x6(SD,{zNotificationTelemetryAck:()=>ND,zNotificationTelemetryEvent:()=>TD,zRegisterDeviceRequest:()=>ID,zRegisterDeviceResponse:()=>ED});ID=c.object({deviceId:c.string().min(1).max(64),pushToken:c.string().min(1).max(200),alertsAllowed:c.boolean().optional(),appVersion:c.string().max(40).optional(),osVersion:c.string().max(40).optional(),model:c.string().max(80).optional()}),ED=c.object({deviceId:c.string().min(1).max(64)}),TD=c.object({deviceId:c.string().min(1).max(64),kind:c.string().min(1).max(30),action:c.enum(["displayed","tapped","dismissed"]),messageId:c.string().max(32).optional()}),ND=c.object({updated:c.boolean()}),YZ=eI.pick({orgId:!0,handle:!0,name:!0,email:!0,website:!0,avatarId:!0,coverId:!0,summary:!0,timezone:!0,isPersonal:!0,status:!0,updatedAt:!0}).extend({avatar:W0.nullable().optional(),cover:W0.nullable().optional()}),XZ=c.object({name:c.string().min(1).max(255),handle:c.string().min(2).max(50).optional(),timezone:Yn.optional()}).strict(),QZ=eI.pick({name:!0,email:!0,website:!0,summary:!0,timezone:!0}).extend({name:c.string().min(1).max(255).optional(),email:c.preprocess(e=>e===""?null:e,c.string().email().nullable()).optional(),timezone:Yn.optional(),avatarMediaId:c.string().nullable().optional(),coverMediaId:c.string().nullable().optional()}).strict(),tH=c.object({used:c.number().int().nonnegative(),limit:c.number().int().nonnegative(),remaining:c.number().int().nonnegative(),periodEnd:c.string(),isDemo:c.boolean(),state:c.enum(["ok","warning","exhausted"])}),nH=c.object({messagesHandled:c.number().int().nonnegative(),proactiveRuns:c.number().int().nonnegative(),approvalsWaiting:c.number().int().nonnegative(),approvalConversationId:c.string().optional(),approvalBotId:c.string().optional(),dailyHandled:c.array(c.number().int().nonnegative()).length(30),messagesByAssistant:c.array(c.object({botId:c.string(),count:c.number().int().nonnegative()})),briefingsDelivered:c.number().int().nonnegative(),scheduledRuns:c.number().int().nonnegative(),prev30MessagesHandled:c.number().int().nonnegative(),prev30BriefingsDelivered:c.number().int().nonnegative(),prev30ScheduledRuns:c.number().int().nonnegative(),since:c.string()}),CD=c.enum(["success","info","warning"]),zD=c.object({orgId:c.string(),name:c.string(),avatarUrl:c.string().nullable()}),AD=c.object({key:c.string(),label:c.string(),tone:CD,status:c.string(),trialDaysRemaining:c.number().optional()}),OD=c.object({activeComputerLimit:c.number().int().nonnegative(),activeComputerCount:c.number().int().nonnegative(),computerCount:c.number().int().nonnegative()}),oH=c.object({org:zD,plan:AD,quota:OD,memberCount:c.number().int().nonnegative()}),DD=c.object({sender:c.enum(["user","agent"]),text:c.string()}),PD=c.enum(["works-now","guided-setup","coming-soon","custom-workflow"]),RD=c.object({docsUrl:c.string(),verifiedAt:c.string(),version:c.string().optional(),versionPolicy:c.enum(["date-versioned","header-versioned","path-versioned","endpoint-versioned","unversioned"]),note:c.string().optional()}),UD=c.object({key:c.string(),label:c.string(),rank:c.number()}),jD=c.object({text:c.string(),tone:c.enum(["info","warning","success","danger"])}),sH=c.object({serviceKey:c.string(),name:c.string(),description:c.string(),shortDescription:c.string(),subtitle:c.string().optional(),icon:c.string().optional(),category:c.string(),categoryLabel:c.string(),categoryRank:c.number(),featuredRank:c.number().optional(),secondaryCategories:c.array(UD),badges:c.array(jD),tags:c.array(c.string()),searchAliases:c.array(c.string()),jtbd:c.string(),useCase:c.string(),demoScenario:c.string(),sampleConversation:c.array(DD),publicStatus:PD,apiVerification:RD.optional(),setupDifficulty:c.string(),risk:c.string(),price:c.string(),kind:c.string(),tier:c.string(),installLevel:c.enum(["computer","org","both"]),setupSummary:c.string().optional(),pagePath:c.string()}),MD=c.object({title:c.string().optional(),text:c.string()}),cH=c.object({content:c.string(),mediaType:c.enum(["application/json","text/plain"]),copyLabel:c.string(),action:c.object({label:c.string(),url:c.url()}),steps:c.array(MD)}),dH=c.object({fullName:c.string().min(1).max(100).optional(),bio:c.string().max(500).nullable().optional(),linkedinUsername:Q2.nullable().optional(),profileUrl:c3.nullable().optional(),avatarMediaId:c.string().nullable().optional(),lastBotId:c.string().nullable().optional(),lastActiveOrgId:c.string().nullable().optional()}).strict(),hp=8e3,LD=c.string().regex(/^[A-Z][A-Z0-9_]*$/),VD=c.object({name:c.string().trim().min(1).max(100),instructions:c.string().trim().min(1).max(hp),credentialNames:c.array(LD).max(10)}),TI=c.object({mediaId:c.string().min(1),sha256:c.string().regex(/^[a-f0-9]{64}$/).optional(),name:c.string().min(1).max(100)}).strict(),FD=VD.extend({toolId:c.string().min(1),assets:c.array(TI)}).strict(),BD=c.object({moment:c.enum(["briefing","checkin","closeout","custom"]),name:c.string().trim().min(1).max(100),policy:c.string().trim().min(1).max(hp),time:c.string().regex(/^([01]\d|2[0-3]):[0-5]\d$/),active:c.boolean()}).strict(),ZD=c.object({serviceKey:c.string().min(1).max(50)}).strict(),HD={schemaVersion:c.literal(1),name:c.string().min(1).max(100),summary:c.string().max(500)},NI=c.object({...HD,identity:X0.pick({name:!0,emoji:!0,title:!0,summary:!0,gender:!0}).strict(),guidance:c.string().max(hp),examples:c.array(c.string().max(hp)),tools:c.array(FD),assets:c.array(TI),routines:c.array(BD).optional(),services:c.array(ZD).optional()}).strict(),mH=c.object({templateId:c.string(),publisherId:c.string(),publisher:c.object({userId:c.string(),fullName:c.string(),avatar:c.object({src:c.string()}).strict().optional()}).strict(),name:c.string(),description:c.string(),snapshot:NI,createdAt:c.string()}).strict(),fH=c.object({reviewed:c.literal(!0),orgId:c.string().min(1),sourceBotId:c.string().min(1),snapshot:NI}).strict(),hH=c.object({templateId:c.string().min(1),destination:c.discriminatedUnion("kind",[c.object({kind:c.literal("computer"),computerId:c.string().min(1)}).strict(),c.object({kind:c.literal("first-computer"),orgId:c.string().min(1)}).strict()]),includedToolIds:c.array(c.string().min(1))}).strict(),gH=c.object({"idempotency-key":c.uuid().describe("One UUID per Add intent; reuse it for retries.")}),bH=c.object({user:h3,computers:c.array(bp),bots:c.array(Zl)}),P2=Object.keys(bp.shape),CI=class extends uo{constructor(e){super("Computer",e),this.computerId=Q(this.settings.computerId),this.ownerId=Q(this.settings.ownerId),this.owner=Q(this.settings.owner),this.orgId=Q(this.settings.orgId),this.name=Q(this.settings.name),this.model=Q(this.settings.model),this.timezone=Q(this.settings.timezone),this.billingTier=Q(this.settings.billingTier),this.desiredStatus=Q(this.settings.desiredStatus),this.status=Q(this.settings.status),this.lastActiveAt=Q(this.settings.lastActiveAt),this.createdAt=Q(this.settings.createdAt),this.updatedAt=Q(this.settings.updatedAt),this.lifecycle=Q(this.settings.lifecycle),this.changedAt=Q(this.settings.changedAt),this.detail=Q(this.settings.detail),this.blocker=Q(this.settings.blocker),this.operation=Q(this.settings.operation),this.ownerMarkUrl=R(()=>{let t=this.owner.value;return t?.avatar?.src||Wl(t?.fullName||this.ownerId.value)}),this.state=R(()=>a3({lifecycle:this.lifecycle.value??"unknown",changedAt:this.changedAt.value,detail:this.detail.value,blocker:this.blocker.value,operation:this.operation.value},this.name.value))}merge(e){if(e.computerId!==void 0&&e.computerId!==this.computerId.value)throw new Error("Cannot change a computer identity");for(let t of P2){if(!(t in e))continue;let n=this[t];n&&typeof n=="object"&&"value"in n&&(n.value=e[t])}}toData(){let e={};for(let t of P2){let n=this[t];n&&typeof n=="object"&&"value"in n&&(e[t]=n.value)}return e}toJSON(){return this.toData()}},R2=Object.keys(Zl.shape),ty=class extends uo{constructor(e,t){if(e.computerId!==t.computerId.value)throw new Error("Bot and computer identities do not match");super("Bot",e),this.botId=Q(this.settings.botId),this.computerId=Q(this.settings.computerId),this.name=Q(this.settings.name),this.handle=Q(this.settings.handle),this.emoji=Q(this.settings.emoji),this.title=Q(this.settings.title),this.summary=Q(this.settings.summary),this.avatarId=Q(this.settings.avatarId),this.coverId=Q(this.settings.coverId),this.avatar=Q(this.settings.avatar),this.cover=Q(this.settings.cover),this.email=Q(this.settings.email),this.website=Q(this.settings.website),this.accounts=Q(this.settings.accounts),this.gender=Q(this.settings.gender),this.voiceKey=Q(this.settings.voiceKey),this.publicChatEnabled=Q(this.settings.publicChatEnabled),this.isPrimary=Q(this.settings.isPrimary),this.collaborationEnabled=Q(this.settings.collaborationEnabled),this.status=Q(this.settings.status),this.onboardingStage=Q(this.settings.onboardingStage),this.onboardedAt=Q(this.settings.onboardedAt),this.routinePrimaryChannel=Q(this.settings.routinePrimaryChannel),this.firstMessageAt=Q(this.settings.firstMessageAt),this.firstValueAt=Q(this.settings.firstValueAt),this.lastMessageAt=Q(this.settings.lastMessageAt),this.createdAt=Q(this.settings.createdAt),this.updatedAt=Q(this.settings.updatedAt),this.displayName=R(()=>this.name.value||"Unnamed"),this.avatarUrl=R(()=>this.avatar.value?.src||Wl(this.name.value)),this.hasCustomHandle=R(()=>!!this.handle.value&&!/\d{13,}$/.test(this.handle.value)),this.displayHandle=R(()=>this.hasCustomHandle.value?`@${this.handle.value}`:void 0),this.hasReceivedMessage=R(()=>!!this.lastMessageAt.value),this.computer=t}get owner(){return this.computer.owner}get ownerMarkUrl(){return this.computer.ownerMarkUrl}get ownerId(){return this.computer.ownerId}get orgId(){return this.computer.orgId}get model(){return this.computer.model}get timezone(){return this.computer.timezone}get billingTier(){return this.computer.billingTier}get desiredStatus(){return this.computer.desiredStatus}get lifecycle(){return this.computer.lifecycle}get changedAt(){return this.computer.changedAt}get detail(){return this.computer.detail}get blocker(){return this.computer.blocker}get operation(){return this.computer.operation}get state(){return this.computer.state}get lastActiveAt(){return this.computer.lastActiveAt}merge(e){if(e.botId!==void 0&&e.botId!==this.botId.value)throw new Error("Cannot change a bot identity");if(e.computerId!==void 0&&e.computerId!==this.computerId.value)throw new Error("Cannot move a bot between computers");for(let t of R2){if(!(t in e))continue;let n=this[t];n&&typeof n=="object"&&"value"in n&&(n.value=e[t])}}toData(){let e={};for(let t of R2){let n=this[t];n&&typeof n=="object"&&"value"in n&&(e[t]=n.value)}return e}toJSON(){return this.toData()}}});function Qn(e,t){let n=Number(globalThis.process?.env?.PORT)||Hl.port;return e||(t?`http://localhost:${n}`:Hl.urls.app)}function KD(e,t,n){let i=Qn(e.apiBase,e.isDev);return async(r,o)=>{let a=po.getAuthToken(),s=new Headers(o?.headers);s.has("Content-Type")||s.set("Content-Type","application/json"),a&&!s.has("Authorization")&&s.set("Authorization",`Bearer ${a}`);let l=typeof r=="string"&&r.startsWith("/")?`${i}${r}`:r,u=await fetch(l,{...o,headers:s,credentials:"include"});if(n&&u.status===401&&(await u.clone().json().catch(()=>{}))?.code==="TOKEN_ERROR"&&n(),t){let d=u.json.bind(u);u.json=async()=>{let p=await d();return typeof p=="object"&&p&&"ok"in p&&("user"in p||"token"in p)&&t(p),p}}return u}}function Jl(e){"@babel/helpers - typeof";return Jl=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Jl(e)}function GD(e,t){if(Jl(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var i=n.call(e,t||"default");if(Jl(i)!="object")return i;throw TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function JD(e){var t=GD(e,"string");return Jl(t)=="symbol"?t:t+""}function G(e,t,n){return(t=JD(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}async function Ba(e,t){e.loading.value=!0,e.error.value=null;try{return await t()}finally{e.loading.value=!1}}function AI(e){if(e.role==="assistant"||e.role==="system")return{id:e.messageId,text:e.content,sender:e.role==="system"?"system":"bot",timestamp:e.createdAt,conversationId:e.conversationId,sequence:e.sequence,systemKind:e.systemKind,...e.metadata?.routine?{routine:e.metadata.routine}:{},...e.metadata?.turnOutcome?{turnOutcome:e.metadata.turnOutcome}:{},...e.metadata?.attachments?.length?{attachments:e.metadata.attachments}:{},...e.metadata?.toolActivities?.length?{toolActivities:e.metadata.toolActivities}:{},...e.metadata?.issue?{issue:e.metadata.issue}:{}}}var zI,Sr,Gl,OI,ny,WD,qD,iy,Za,yp,wp,kp,YD,XD,QD,ry,e5,t5,r5,n5,i5,xp,Yl,oy=re(()=>{"use strict";Pn();ql();En();Sr=[],Gl=0,OI=null,ny=4,WD=(zI=globalThis).nanostoresGlobal||(zI.nanostoresGlobal={epoch:0}),qD=()=>{let e,t;for(;Gl<Sr.length;){t=Gl,Gl+=ny;let n=OI?.get(Sr[t]);if(n){if(!n.has(Sr[t+1]))continue;n.clear()}try{Sr[t](Sr[t+1].value,Sr[t+2],Sr[t+3])}catch(i){e=i}}if(Sr.length=Gl=0,e)throw e},iy=e=>{let t=[],n={eq:Object.is,get(){return n.lc||n.listen(()=>{})(),n.value},init:e,lc:0,listen(i){return n.lc=t.push(i),()=>{OI?.get(i)?.delete(n);for(let o=Gl;o<Sr.length;)Sr[o]===i&&Sr[o+1]===n?Sr.splice(o,ny):o+=ny;let r=t.indexOf(i);~r&&(t.splice(r,1),--n.lc||n.off())}},notify(i,r){WD.epoch++;let o=!Sr.length&&!0;for(let a of t)Sr.push(a,n,i,r);o&&qD()},off(){},set(i){let r=n.value;n.eq(r,i)||(n.value=i,n.notify(r))},subscribe(i){let r=n.listen(i);return i(n.value),r},value:e};return n};Za=globalThis,yp=Za.__PL_AUTH_USER__??(Za.__PL_AUTH_USER__=iy(void 0)),wp=Za.__PL_AUTH_TOKEN__??(Za.__PL_AUTH_TOKEN__=iy(null)),kp=Za.__PL_AUTH_DEVICE_ID__??(Za.__PL_AUTH_DEVICE_ID__=iy(null)),YD=class{constructor(){G(this,"logger",co("SDKStorage"))}isLocalStorageFunctional(){return typeof window<"u"&&typeof localStorage?.getItem=="function"&&typeof localStorage?.setItem=="function"&&typeof localStorage?.removeItem=="function"}syncWithGlobalStores(e){let{activeUser:t,token:n,deviceId:i}=e,r=yp.get(),o=wp.get(),a=kp.get();r&&(t.value=r),o&&(n.value=o),a&&(i.value=a),mt(t,s=>yp.set(s),{immediate:!0}),mt(n,s=>wp.set(s),{immediate:!0}),mt(i,s=>kp.set(s),{immediate:!0}),yp.subscribe(s=>{s!==t.value&&(t.value=s)}),wp.subscribe(s=>{s!==n.value&&(n.value=s)}),kp.subscribe(s=>{s!==i.value&&(i.value=s)})}loadFromStorage(e){if(typeof window>"u")return;let t=po.getAuthToken();t&&(e.token.value=t);let n=po.getDeviceId();if(n&&(e.deviceId.value=n),this.isLocalStorageFunctional())try{let i=localStorage.getItem("pagelines-user");i&&(e.activeUser.value=JSON.parse(i))}catch(i){this.logger.error("Failed to load user from localStorage",{data:i})}}saveToStorage(e){if(typeof window<"u"&&(e.token.value?po.setAuthToken(e.token.value):po.removeAuthToken(),this.isLocalStorageFunctional()))try{e.activeUser.value?localStorage.setItem("pagelines-user",JSON.stringify(e.activeUser.value)):localStorage.removeItem("pagelines-user")}catch(t){this.logger.error("Failed to save user to localStorage",{data:t})}}clearStorage(){if(typeof window<"u"){if(po.removeAuthToken(),this.isLocalStorageFunctional())try{localStorage.removeItem("pagelines-user")}catch(e){this.logger.error("Failed to clear user from localStorage",{data:e})}yp.set(void 0),wp.set(null),kp.set(null)}}getItem(e){if(!this.isLocalStorageFunctional())return null;try{return localStorage.getItem(e)}catch(t){return this.logger.error("Failed to get item from localStorage",{key:e,error:t}),null}}setItem(e,t){if(this.isLocalStorageFunctional())try{localStorage.setItem(e,t)}catch(n){this.logger.error("Failed to set item in localStorage",{key:e,error:n})}}},XD=class{constructor(e){G(this,"ctx",void 0),G(this,"computers",Ea(new Map)),G(this,"bots",Ea(new Map)),this.ctx=e}get(e){return this.bots.get(e)}computer(e){return this.computers.get(e)}all(){return[...this.bots.values()]}hydrate(e){for(let t of e.computers){let n=this.computers.get(t.computerId);n?n.merge(t):this.computers.set(t.computerId,new CI(t))}return e.bots.map(t=>{let n=this.computers.get(t.computerId);if(!n)throw Error("Bot references an unknown computer");let i=this.bots.get(t.botId);if(i)return i.merge(t),i;let r=new ty(t,n);return this.bots.set(t.botId,r),r})}clear(){this.bots.clear(),this.computers.clear()}async webhook(e){let t=await this.ctx.apiFetch(`/api/bot-api/webhooks/routine-triggers/${encodeURIComponent(e.triggerId)}`,{method:"POST",headers:{"Content-Type":"application/json","X-PageLines-Key":e.key},body:JSON.stringify({type:e.type,data:e.data,...e.meta?{meta:e.meta}:{}})});if(!t.ok)throw Error(`Webhook delivery failed (${t.status})`);return t.json()}},QD=class{constructor(e,t){G(this,"ctx",void 0),G(this,"registry",void 0),this.ctx=e,this.registry=t}async create(e){let t=this.ctx.token.value,n=await(await this.ctx.apiFetch("/api/computers",{method:"POST",headers:{"Content-Type":"application/json","Idempotency-Key":crypto.randomUUID()},body:JSON.stringify(e)})).json();if(t!==this.ctx.token.value)throw Error("Your account changed. Try again.");if(!n.ok)throw Error(n.error||"Failed to create computer");return this.registry.hydrate({computers:[n.data.computer],bots:[n.data.bot]})[0]}async getLiveStatus(e){let t=this.ctx.token.value;try{let n=await(await this.ctx.apiFetch(`/api/computers/state?ids=${encodeURIComponent(e)}`)).json(),i=n.ok?n.data[e]??Kl:Kl;return t===this.ctx.token.value?(this.registry.computer(e)?.merge(i),i):Kl}catch(n){return this.ctx.logger.warn("Computer status unavailable",{computerId:e,error:n}),Kl}}async waitUntilReady(e){let t=Date.now(),n;for(;Date.now()-t<(e.timeoutMs??tI.wake);){let i=await this.getLiveStatus(e.computerId);if(i.lifecycle!==n&&(e.onStatus?.(i.lifecycle),n=i.lifecycle),i.lifecycle==="running")return;if(i.lifecycle==="error")throw Error("Your computer hit a problem starting");await new Promise(r=>setTimeout(r,e.pollIntervalMs??3e3))}throw Error("Your computer is taking longer than expected. Please try again.")}},ry="Signed in, but your account could not be loaded. Try again.";e5=class{constructor(e){G(this,"ctx",void 0),this.ctx=e}async authenticateWithCode(e,t){let n=await(await this.ctx.apiFetch("/api/auth/verify-code",{method:"POST",body:JSON.stringify({email:e,code:t})})).json();if(!n.ok)throw Error(n.error);let i=await this.getCurrentUser();if(!i)throw Error(ry);return i}async sendCode(e){return Ba(this.ctx,async()=>{try{let t=await(await this.ctx.apiFetch("/api/auth/check-email",{method:"POST",body:JSON.stringify({email:e})})).json();if(!t.ok)throw this.ctx.error.value=t.error,Error(t.error)}catch(t){this.ctx.logger.error("Send code error",{data:t});let n=t instanceof Error?t.message:"Failed to send verification code";throw this.ctx.error.value=n,t}})}async verifyCode(e,t){return Ba(this.ctx,async()=>{try{await this.authenticateWithCode(e,t)}catch(n){this.ctx.logger.error("Verify code error",{data:n});let i=n instanceof Error?n.message:"Failed to verify code";throw this.ctx.error.value=i,n}})}async logout(){return Ba(this.ctx,async()=>{try{await this.ctx.apiFetch("/api/auth/logout",{method:"POST"})}catch(e){this.ctx.logger.error("Logout error (user still logged out locally)",{data:e})}this.ctx.activeUser.value=void 0,this.ctx.token.value=null,this.ctx.storage.clearStorage(),this.ctx.clearRoster()})}async getCurrentUser(){let e=this.ctx.token.value;if(e)return Ba(this.ctx,async()=>{try{let t=await(await this.ctx.apiFetch("/api/users/me",{method:"GET"})).json();if(e!==this.ctx.token.value)return;if(!t.ok){this.ctx.error.value=t.error,t.error.includes("Authentication")&&(this.ctx.activeUser.value=void 0,this.ctx.token.value=null,this.ctx.storage.clearStorage(),this.ctx.clearRoster());return}return this.ctx.activeUser.value=t.data.user,this.ctx.hydrateRoster(t.data),t.data.user}catch(t){this.ctx.logger.error("Get current user error",{data:t}),this.ctx.error.value=t instanceof Error?t.message:"Failed to get user info";return}})}async requestAuthCode(e){return Ba(this.ctx,async()=>{try{let t=await(await this.ctx.apiFetch("/api/auth/check-email",{method:"POST",body:JSON.stringify({email:e.email})})).json();return t.ok?(this.ctx.logger.info("Auth code requested successfully",{email:e.email}),!0):(this.ctx.error.value=t.error,this.ctx.logger.error("Failed to request auth code",{email:e.email,error:t.error}),!1)}catch(t){return this.ctx.logger.error("Request auth code error",{email:e.email,error:t}),this.ctx.error.value=t instanceof Error?t.message:"Failed to request auth code",!1}})}async loginWithCode(e){return Ba(this.ctx,async()=>{try{return await this.authenticateWithCode(e.email,e.code),this.ctx.logger.info("Login successful",{email:e.email}),!0}catch(t){return this.ctx.logger.error("Login with code error",{email:e.email,error:t}),this.ctx.error.value=t instanceof Error?t.message:"Login failed",!1}})}loginWithGoogle(e){if(typeof window>"u"){this.ctx.logger.error("loginWithGoogle: Only available in browser");return}let t=Qn(this.ctx.apiBase,this.ctx.isDev),n=window.location.origin,i=`${t}/auth/google-popup?origin=${encodeURIComponent(n)}`,r=window.screenX+(window.outerWidth-500)/2,o=window.screenY+(window.outerHeight-600)/2,a=window.open(i,"google-auth",`width=500,height=600,left=${r},top=${o},popup=yes`);if(!a){let u="Popup was blocked. Please allow popups for this site.";this.ctx.error.value=u,e?.onError?.(u);return}let s=async u=>{let d=new URL(t).origin;if(u.origin===d){if(u.data?.type==="auth-success"){window.removeEventListener("message",s);let{token:p}=u.data;this.ctx.processApiResponse({ok:!0,data:{},token:p});let m=await this.getCurrentUser();if(!m){this.ctx.error.value=ry,this.ctx.logger.error("Google login: token accepted but user hydration failed"),e?.onError?.(ry);return}this.ctx.logger.info("Google login successful"),e?.onSuccess?.(m)}else if(u.data?.type==="auth-error"){window.removeEventListener("message",s);let p=u.data.error||"Google authentication failed";this.ctx.error.value=p,this.ctx.logger.error("Google login failed",{error:p}),e?.onError?.(p)}}};window.addEventListener("message",s);let l=setInterval(()=>{a.closed&&(clearInterval(l),window.removeEventListener("message",s))},500)}},t5=class{constructor(e){G(this,"ctx",void 0),this.ctx=e}async confirmCheckout(e){if(e?.sessionId){let t=Qn(this.ctx.apiBase,this.ctx.isDev),n=await(await fetch(`${t}/api/billing/complete-checkout`,{method:"POST",headers:{"Content-Type":"application/json",...this.ctx.token.value&&{Authorization:`Bearer ${this.ctx.token.value}`}},body:JSON.stringify({sessionId:e.sessionId})})).json();if(!n.ok){let i=n.error||"Failed to complete checkout";throw this.ctx.error.value=i,Error(i)}}return this.getStatus()}async getStatus(){let e=this.resolveOrgId(),t=Qn(this.ctx.apiBase,this.ctx.isDev),n=await(await fetch(`${t}/api/billing/details/${e}`,{headers:{...this.ctx.token.value&&{Authorization:`Bearer ${this.ctx.token.value}`}}})).json();if(!n.ok||!n.data)return{plan:void 0,status:"none",hasActiveBilling:!1,maxBots:0};let i=["active","trial","canceling"].includes(n.data.status)||n.data.status==="past_due"&&n.data.paymentRecovery?.suspended!==!0;return{plan:n.data.plan,status:n.data.status,hasActiveBilling:i,maxBots:n.data.maxBots,...n.data.trialEnd&&{trialEnd:n.data.trialEnd},...n.data.trialDaysRemaining!==void 0&&{trialDaysRemaining:n.data.trialDaysRemaining},...n.data.paymentRecovery&&{paymentRecovery:n.data.paymentRecovery}}}resolveOrgId(){let e=this.ctx.activeUser.value?.orgs?.[0]?.orgId;if(!e)throw Error("No organization found. Please sign in first.");return e}};r5=class{constructor(e){G(this,"ctx",void 0),this.ctx=e}async cancelConversationTurn(e){let t=Qn(this.ctx.apiBase,this.ctx.isDev),n=this.ctx.token.value?{Authorization:`Bearer ${this.ctx.token.value}`}:{},i=await fetch(`${t}/api/conversations/${encodeURIComponent(e.conversationId)}/cancel`,{method:"POST",headers:{"Content-Type":"application/json",...n},body:JSON.stringify(e.turnId?{turnId:e.turnId}:{})}),r=await i.json();if(!r.ok)throw Error(r.error||`Cancel failed: HTTP ${i.status}`);return r.data}async chatStreamPublic(e){let t=`${Qn(this.ctx.apiBase,this.ctx.isDev)}/api/bots/public/${encodeURIComponent(e.handle)}/chat/stream`,n="",i=!1,r=!1,o;try{let a=await fetch(t,{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({message:e.message,anonymousId:e.anonymousId,...e.attachments?.length?{attachments:e.attachments.map(({type:s,src:l,filename:u,mimeType:d,mediaId:p})=>({type:s,url:l,name:u,mimeType:d,mediaId:p}))}:{},...e.context?{context:e.context}:{}})});if(!a.ok){let s=await a.json().catch(()=>({error:"Request failed"}));e.onError(ln("api",s.error||`HTTP ${a.status}`,s.code));return}if(n=a.headers.get("X-Conversation-Id")||"",o=a.body?.getReader(),!o){e.onError(ln("stream-open","No response stream"));return}for await(let s of Q0(o))if(s.event==="working_state")e.onStatus?.(s.data.description);else if(s.event==="tool_activity")e.onToolActivity?.(s.data);else if(s.event==="working_end")e.onWorkingEnd?.();else if(s.event==="message_delta")e.onDelta(s.data.delta,s.data.role);else if(s.event==="error"){i=!0,e.onError(s.data);break}else if(s.event==="message"&&(s.data.message.role==="assistant"||s.data.message.role==="system")){r=!0;let l=AI(s.data.message);l&&e.onMessage?.(l)}else if(s.event==="stream_end")break;!i&&r?e.onDone(n):i||e.onError(ln("no-reply","Stream ended before reply arrived"))}catch(a){e.onError(ln("stream-read",a instanceof Error?a.message:"Stream failed","NETWORK_ERROR"))}finally{try{await o?.cancel()}catch{}}}async chatStreamAuthenticated(e){let t=Qn(this.ctx.apiBase,this.ctx.isDev),n=this.ctx.token.value?{Authorization:`Bearer ${this.ctx.token.value}`}:{},i=e.conversationId,r=e.latestSequence??null;if(!i)try{let l=await fetch(`${t}/api/conversations`,{method:"POST",headers:{"Content-Type":"application/json",...n},body:JSON.stringify({orgId:e.orgId,participants:[{type:"bot",id:e.botId}]})}),u=await l.json();if(!u.ok){e.onError(ln("api",u.error||`Conversation failed: HTTP ${l.status}`,u.code));return}i=u.data.conversationId,r=u.data.latestSequence??null}catch(l){e.onError(ln("api",l instanceof Error?l.message:"Conversation failed","NETWORK_ERROR"));return}let o=r?`${t}/api/conversations/${encodeURIComponent(i)}/stream?since=${encodeURIComponent(r)}`:`${t}/api/conversations/${encodeURIComponent(i)}/stream`,a=`nonce_${V2(16)}`,s=iI();await yI({streamUrl:o,sendUrl:`${t}/api/messages`,headers:n,sendBody:{conversationId:i,content:e.message,clientNonce:a,...s?{viewerTimezone:s}:{},...e.attachments&&e.attachments.length>0?{attachments:e.attachments}:{}},onStatus:e.onStatus,onDelta:e.onDelta,onToolActivity:e.onToolActivity,onWorkingEnd:e.onWorkingEnd,onMessage:l=>{let u=AI(l);u&&e.onMessage?.(u)},onDone:()=>e.onDone(i),onChatError:e.onError,onTransportError:e.onError})}},n5=class{constructor(e){G(this,"ctx",void 0),this.ctx=e}async getPublicBot(e){this.ctx.loading.value=!0,this.ctx.error.value=null;try{let t=await(await this.ctx.apiFetch(`/api/pub/bot/get-by-handle?handle=${encodeURIComponent(e.handle)}`)).json();if(!t.ok){this.ctx.error.value=t.error,this.ctx.logger.error("Failed to fetch public bot",{handle:e.handle,error:t.error});return}return this.ctx.hydrateRoster({bots:[t.data.bot],computers:[t.data.computer]})[0]}catch(t){this.ctx.logger.error("Get public bot error",{handle:e.handle,error:t}),this.ctx.error.value=t instanceof Error?t.message:"Failed to fetch bot";return}finally{this.ctx.loading.value=!1}}generateAnonId(){let e="pagelinesAnonId",t=this.ctx.storage.getItem(e);return t||(t=gp({prefix:"anon"}),this.ctx.storage.setItem(e,t)),t}track(e){try{typeof window<"u"&&window.parent!==window&&window.parent.postMessage({type:"pagelines_track",event:e.event,botId:e.botId,properties:e.properties||{}},"*"),this.ctx.logger.info("SDK event tracked",{event:e.event,botId:e.botId})}catch(t){this.ctx.logger.error("Track event error",{error:t,args:e})}}},i5=class{constructor(){G(this,"key","__PAGELINES_SDK__")}get(){if(typeof window<"u")return globalThis[this.key]}set(e){typeof window<"u"&&(globalThis[this.key]=e)}delete(){typeof window<"u"&&delete globalThis[this.key]}},xp=new i5,Yl=class DI extends uo{static getInstance(t={}){return xp.get()||new DI(t)}get isDev(){return this.settings.isDev??(typeof window<"u"?window.location.hostname==="localhost"||window.location.hostname.includes("127.0.0.1"):!1)}constructor(t={}){let n=xp.get();if(n)return console.debug("[PageLinesSDK] Returning existing singleton instance"),n;super("PageLinesSDK",t),G(this,"activeUser",Q()),G(this,"token",Q(null)),G(this,"deviceId",Q(null)),G(this,"loading",Q(!1)),G(this,"error",Q(null)),G(this,"apiBase",this.settings.apiBase||void 0),G(this,"storage",new YD),G(this,"sessionId",gp({prefix:"ses"})),G(this,"currentBot",R(()=>{let r=this.activeUser.value;return(r?.lastBotId?this.bot.get(r.lastBotId):void 0)??this.bot.all().find(o=>o.isPrimary.value&&o.ownerId.value===r?.userId)})),G(this,"currentOrg",R(()=>{let r=this.currentBot.value?.computer.orgId.value??this.activeUser.value?.lastActiveOrgId??this.activeUser.value?.primaryOrgId;return this.activeUser.value?.orgs?.find(o=>o.orgId===r)})),G(this,"initialized",void 0),G(this,"resolveUser",void 0),G(this,"bot",void 0),G(this,"computer",void 0),G(this,"auth",void 0),G(this,"billing",void 0),G(this,"chat",void 0),G(this,"user",void 0),G(this,"stopAccountWatch",void 0),xp.set(this);let i={apiFetch:KD({isDev:this.isDev,apiBase:this.apiBase},this.processApiResponse.bind(this),()=>this.clearSession()),apiBase:this.apiBase,isDev:this.isDev,activeUser:this.activeUser,token:this.token,loading:this.loading,error:this.error,currentBot:this.currentBot,hydrateRoster:r=>this.bot.hydrate(r),clearRoster:()=>this.bot.clear(),storage:this.storage,sessionId:this.sessionId,logger:this.logger,processApiResponse:this.processApiResponse.bind(this)};this.bot=new XD(i),this.computer=new QD(i,this.bot),this.auth=new e5(i),this.billing=new t5(i),this.chat=new r5(i),this.user=new n5(i),this.stopAccountWatch=mt(()=>this.activeUser.value?.userId,()=>this.bot.clear(),{flush:"sync"}),this.logger.info("PageLinesSDK initialized"),this.storage.loadFromStorage(this.authRefs()),this.storage.syncWithGlobalStores(this.authRefs()),this.initialized=new Promise(r=>{this.resolveUser=r}),this.token.value&&!this.activeUser.value?this.auth.getCurrentUser().then(r=>{this.resolveUser&&(this.resolveUser(r),this.resolveUser=void 0)}).catch(r=>{this.logger.error("Auto user fetch failed",{data:r}),this.resolveUser&&(this.resolveUser(void 0),this.resolveUser=void 0)}):this.activeUser.value?this.resolveUser?.(this.activeUser.value):this.resolveUser?.(void 0)}processApiResponse(t){if(!t.ok)return;let n=!1;t.user&&(this.activeUser.value=t.user,this.logger.info("User updated from API response",{data:t.user}),n=!0),t.token&&(this.token.value!==t.token&&(this.activeUser.value=void 0,this.bot.clear()),this.token.value=t.token,this.logger.info("Token updated from API response"),n=!0);let i=t.data?.deviceId;i&&(this.deviceId.value=i,n=!0),n&&this.persistAuth(),this.resolveUser&&(this.resolveUser(t.user),this.resolveUser=void 0)}authRefs(){return{activeUser:this.activeUser,token:this.token,deviceId:this.deviceId}}persistAuth(){this.storage.saveToStorage(this.authRefs())}clearSession(){this.bot.clear(),this.logger.info("Clearing session"),this.activeUser.value=void 0,this.token.value=null,this.deviceId.value=null,this.error.value=null,this.storage.clearStorage()}clear(){this.logger.info("Clearing SDK completely"),this.clearSession(),this.loading.value=!1,this.sessionId=gp({prefix:"ses"}),this.stopAccountWatch?.(),xp.delete()}}});function s5(e,t){return w(),$("div",a5,[...t[0]||(t[0]=[b("svg",{class:"ring-circular h-full w-full origin-center",viewBox:"25 25 50 50"},[b("circle",{class:"ring-path",cx:"50",cy:"50",r:"20",fill:"none",stroke:"currentColor","stroke-width":"5","stroke-miterlimit":"30"})],-1)])])}function l5(e){let t=Math.max(0,Math.floor(e.ms/1e3));return`${Math.floor(t/60)}:${(t%60).toString().padStart(2,"0")}`}function c5(e){return e.mimeType.includes("mp4")||e.mimeType.includes("m4a")?"m4a":e.mimeType.includes("ogg")?"ogg":e.mimeType.includes("wav")?"wav":"webm"}function u5(){return typeof MediaRecorder>"u"?"":["audio/webm;codecs=opus","audio/mp4","audio/webm"].find(e=>MediaRecorder.isTypeSupported?.(e))||""}function m5(e){return e.turnOutcome==="failed"?"failed":e.turnOutcome==="stopped"?"stopped":e.sender==="system"?"failed":"completed"}function Ap(e){if(!e)return;let t=Date.parse(e);return Number.isFinite(t)?t:void 0}function qa(e){return Ap(e.endedAt)??Ap(e.startedAt)??0}function wy(e,t){return qa(e)-qa(t)}function nc(e,t){let n=e.filter(r=>r.status==="completed"||r.status==="failed"&&!!r.note).filter(r=>!t.has(r.activityId)).slice().sort(wy),i=[];for(let r of n){let o=r.status==="completed"?"done":"failed",a=i[i.length-1];o==="done"&&a?.tone==="done"&&a.label===r.label&&qa(r)-a.lastMs<=f5?(a.count+=1,a.lastMs=qa(r)):i.push({id:r.activityId,tone:o,label:r.label,note:r.note,count:1,lastMs:qa(r)})}return i.map(r=>({id:r.id,tone:r.tone,label:r.count>1?`${r.label} \xB7 ${r.count}`:r.label,...r.note?{note:r.note}:{}}))}function Cp(e){return e.length<=ay?{visibleRows:e,hiddenRows:[]}:{visibleRows:e.slice(e.length-ay),hiddenRows:e.slice(0,e.length-ay)}}function ky(e){let{activities:t,outcome:n,nowMs:i,canNotifyOnCompletion:r,lastVisibleProgressAtMs:o,includeFailureNote:a=!0}=e;if(n==="completed")return{outcome:n,visibleRows:[],hiddenRows:nc(t,new Set),terminal:{id:"work-complete",tone:"completed",label:fo.completed}};if(n==="failed"){let z=t.filter(J=>J.status==="failed").sort(wy).pop(),j=new Set;z&&j.add(z.activityId);let{visibleRows:O,hiddenRows:U}=Cp(nc(t,j));return{outcome:n,visibleRows:O,hiddenRows:U,terminal:{id:"work-failed",tone:"failed",label:fo.failed,...a&&z?.note?{note:z.note}:{}}}}if(n==="stopped"){let{visibleRows:z,hiddenRows:j}=Cp(nc(t,new Set));return{outcome:n,visibleRows:z,hiddenRows:j,terminal:{id:"work-stopped",tone:"stopped",label:fo.stopped}}}let{visibleRows:s,hiddenRows:l}=Cp(nc(t,new Set)),u=t.filter(z=>z.status==="started").sort(wy).pop(),d=t.reduce((z,j)=>Math.max(z,qa(j)),o??-1/0),p=Number.isFinite(d)?d:i,m=t.reduce((z,j)=>{let O=Ap(j.startedAt)??Ap(j.endedAt);return O===void 0?z:Math.min(z,O)},1/0),f=p+uE,h=(Number.isFinite(m)?m:p)+h5,v=i>=f,k=u||v?{id:u?.activityId??"work-active",tone:"active",label:u?.label??fo.finishing}:void 0,T=v&&i>=h?r?fo.notifyHint:fo.leaveHint:void 0,S=[f,h].filter(z=>z>i).sort((z,j)=>z-j)[0];return{outcome:n,visibleRows:s,hiddenRows:l,...k?{terminal:k}:{},...T?{hint:T}:{},...S===void 0?{}:{nextBoundaryAtMs:S}}}function g5(e){let{segments:t,activities:n,nowMs:i,canNotifyOnCompletion:r,lastVisibleProgressAtMs:o}=e,a=new Map(n.map(f=>[f.activityId,f])),s=f=>ky({activities:f,outcome:"running",nowMs:i,canNotifyOnCompletion:r,...o===void 0?{}:{lastVisibleProgressAtMs:o}}),l=f=>{let{visibleRows:h,hiddenRows:v}=Cp(nc(f,new Set));if(h.length!==0||v.length!==0)return{outcome:"running",visibleRows:h,hiddenRows:v}},u=[],d=new Set(t.flatMap(f=>f.kind==="work"?f.activityIds:[])),p=l(n.filter(f=>!d.has(f.activityId)));p&&u.push({kind:"work",id:"work-unsegmented",journal:p}),t.forEach((f,h)=>{if(f.kind==="text"){f.content&&u.push({kind:"text",id:`text-${h}`,content:f.content});return}let v=f.activityIds.map(T=>a.get(T)).filter(T=>T!==void 0);if(v.length===0)return;let k=l(v);k&&u.push({kind:"work",id:`work-${f.activityIds[0]??h}`,journal:k})});let m=s(n);return m.terminal||m.hint?u.push({kind:"work",id:"work-tail",journal:{outcome:"running",visibleRows:[],hiddenRows:[],...m.terminal?{terminal:m.terminal}:{},...m.hint?{hint:m.hint}:{},...m.nextBoundaryAtMs===void 0?{}:{nextBoundaryAtMs:m.nextBoundaryAtMs}}}):u.push({kind:"loading",id:"work-tail"}),u}function _p(e){if(!e)return;let t=Date.parse(e);return Number.isFinite(t)?t:void 0}function v5(){return typeof navigator<"u"&&!!navigator.mediaDevices?.getUserMedia&&typeof RTCPeerConnection<"u"}function PI(e){return e?typeof e=="string"?e:e.src||"":""}function dE(e){return PI(e.cover)||PI(e.avatar)||Wl(e.name)}function ac(e){let t=e.target;t.dataset.fallbackUsed||(t.dataset.fallbackUsed="true",t.src=Wl())}function pE(e){let{template:t,bot:n}=e;return t.replace(/{name}/g,n.name||"Assistant").replace(/{title}/g,n.title||"").replace(/{handle}/g,n.handle||"")}function I5(e,t){switch(e){case"bot":return`${t} ended the call`;case"idle-timeout":return"Call ended after 30 seconds of silence";case"network":return"Call dropped. Connection lost.";case"session-cap":return"Call reached its time limit";case"unavailable":return"Call couldn\u2019t connect"}}function M5(e,t){this.v=e,this.k=t}function RI(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,i=Array(t);n<t;n++)i[n]=e[n];return i}function L5(e){if(Array.isArray(e))return e}function V5(e,t){var n=e==null?null:typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(n!=null){var i,r,o,a,s=[],l=!0,u=!1;try{if(o=(n=n.call(e)).next,t===0){if(Object(n)!==n)return;l=!1}else for(;!(l=(i=o.call(n)).done)&&(s.push(i.value),s.length!==t);l=!0);}catch(d){u=!0,r=d}finally{try{if(!l&&n.return!=null&&(a=n.return(),Object(a)!==a))return}finally{if(u)throw r}}return s}}function F5(){throw TypeError(`Invalid attempt to destructure non-iterable instance.
|
|
95
|
-
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function B5(e,t){return L5(e)||V5(e,t)||Z5(e,t)||F5()}function Z5(e,t){if(e){if(typeof e=="string")return RI(e,t);var n={}.toString.call(e).slice(8,-1);return n==="Object"&&e.constructor&&(n=e.constructor.name),n==="Map"||n==="Set"?Array.from(e):n==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?RI(e,t):void 0}}function $p(e){var t,n;function i(o,a){try{var s=e[o](a),l=s.value,u=l instanceof M5;Promise.resolve(u?l.v:l).then(function(d){if(u){var p=o==="return"&&l.k?o:"next";if(!l.k||d.done)return i(p,d);d=e[p](d).value}r(!!s.done,d)},function(d){i("throw",d)})}catch(d){r(2,d)}}function r(o,a){o===2?t.reject(a):t.resolve({value:a,done:o}),(t=t.next)?i(t.key,t.arg):n=null}this._invoke=function(o,a){return new Promise(function(s,l){var u={key:o,arg:a,resolve:s,reject:l,next:null};n?n=n.next=u:(t=n=u,i(o,a))})},typeof e.return!="function"&&(this.return=void 0)}function _t(e){return function(t){t instanceof RegExp&&(t.lastIndex=0);var n=[...arguments].slice(1);return _y(e,t,n)}}function vE(e){return function(){return $y(e,[...arguments])}}function Ge(e,t){let n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:ho;if(UI&&UI(e,null),!Ga(t))return e;let i=t.length;for(;i--;){let r=t[i];if(typeof r=="string"){let o=n(r);o!==r&&(H5(t)||(t[i]=o),r=o)}e[r]=!0}return e}function X5(e){for(let t=0;t<e.length;t++)Ir(e,t)||(e[t]=null);return e}function Rr(e){let t=Ha(null);for(let i of mE(e)){var n=B5(i,2);let r=n[0],o=n[1];Ir(e,r)&&(t[r]=Ga(o)?X5(o):o&&typeof o=="object"&&o.constructor===Object?Rr(o):o)}return t}function Q5(e){switch(typeof e){case"string":return e;case"number":return J5(e);case"boolean":return Y5(e);case"bigint":return VI?VI(e):"0";case"symbol":return FI?FI(e):"Symbol()";case"undefined":return tc(e);case"function":case"object":{if(e===null)return tc(e);let t=e,n=Hr(t,"toString");if(typeof n=="function"){let i=n(t);return typeof i=="string"?i:tc(i)}return tc(e)}default:return tc(e)}}function Hr(e,t){for(;e!==null;){let i=hE(e,t);if(i){if(i.get)return _t(i.get);if(typeof i.value=="function")return _t(i.value)}e=fE(e)}function n(){return null}return n}function eP(e,t){for(;e!==null;){let n=hE(e,t);if(n)return n.get?_t(n.get):null;e=fE(e)}return null}function tP(e){try{return Xt(e,""),!0}catch{return!1}}function bE(){let e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:hP(),t=oe=>bE(oe);if(t.version="3.4.17",t.removed=[],!e||!e.document||e.document.nodeType!==At.document||!e.Element)return t.isSupported=!1,t;let n=e.document,i=n,r=i.currentScript;e.DocumentFragment;let o=e.HTMLTemplateElement,a=e.Node,s=e.Element,l=e.NodeFilter;e.NamedNodeMap===void 0&&(e.NamedNodeMap||e.MozNamedAttrMap),e.HTMLFormElement;let u=e.DOMParser,d=e.trustedTypes,p=s.prototype,m=Hr(p,"cloneNode"),f=Hr(p,"remove"),h=Hr(p,"removeAttributeNode"),v=Hr(p,"nextSibling"),k=Hr(p,"childNodes"),T=Hr(p,"parentNode"),S=Hr(p,"shadowRoot"),z=Hr(p,"attributes"),j=a&&a.prototype?Hr(a.prototype,"nodeType"):null,O=a&&a.prototype?Hr(a.prototype,"nodeName"):null,U=a&&a.prototype?Hr(a.prototype,"ownerDocument"):null,J=function(g){return j?j(g):g.nodeType},W=function(g){return O?O(g):g.nodeName},ce=eP(p,"namespaceURI"),se=function(g){return ce?ce(g):g.namespaceURI};if(typeof o=="function"){let oe=n.createElement("template");oe.content&&oe.content.ownerDocument&&(n=oe.content.ownerDocument)}let pe,F="",ue,Je=!1,ct=0,ft=function(){if(ct>0)throw ti('A configured TRUSTED_TYPES_POLICY callback (createHTML or createScriptURL) must not call DOMPurify.sanitize, as that causes infinite recursion. Do not pass a policy whose callbacks wrap DOMPurify as TRUSTED_TYPES_POLICY; see the "DOMPurify and Trusted Types" section of the README.')},Re=function(g){ft(),ct++;try{return pe.createHTML(g)}finally{ct--}},Be=function(g){ft(),ct++;try{return pe.createScriptURL(g)}finally{ct--}},Mt=function(){return Je||(ue=gP(d,r),Je=!0),ue},Er=n,mr=Er.implementation,gt=Er.createNodeIterator,yt=Er.createDocumentFragment,Wr=Er.getElementsByTagName,Tt=i.importNode,Ye=JI();t.isSupported=typeof mE=="function"&&typeof T=="function"&&mr&&mr.createHTMLDocument!==void 0;let Ht=iP,er=oP,Tr=aP,fr=sP,qr=lP,hr=cP,x=uP,I=pP,M=WI,B=null,X=Ge({},[...BI,...dy,...py,...my,...ZI]),_=null,D=Ge({},[...HI,...fy,...KI,...Sp]),y=Object.seal(Ha(null,{tagNameCheck:{writable:!0,configurable:!1,enumerable:!0,value:null},attributeNameCheck:{writable:!0,configurable:!1,enumerable:!0,value:null},allowCustomizedBuiltInElements:{writable:!0,configurable:!1,enumerable:!0,value:!1}})),P=null,E=null,Y=Object.seal(Ha(null,{tagCheck:{writable:!0,configurable:!1,enumerable:!0,value:null},attributeCheck:{writable:!0,configurable:!1,enumerable:!0,value:null}})),ie=!0,fe=!0,ve=!1,we=!0,ye=!1,Ne=!0,Me=!1,Xe=!1,wt=null,$t=null,St=!1,Kt=!1,vt=!1,Nt=!1,Gr=!0,$e=!1,rs="user-content-",zi=!0,xo=!1,Jr=null,ni={},On=null,pc=Ge({},"annotation-xml.audio.colgroup.desc.foreignobject.head.iframe.math.mi.mn.mo.ms.mtext.noembed.noframes.noscript.plaintext.script.selectedcontent.style.svg.template.thead.title.video.xmp".split(".")),mc=null,ns=Ge({},["audio","video","img","source","image","track"]),ii=null,dn=Ge({},["alt","class","for","id","label","name","pattern","placeholder","role","summary","title","value","style","xmlns"]),Dn="http://www.w3.org/1998/Math/MathML",_o="http://www.w3.org/2000/svg",Ur="http://www.w3.org/1999/xhtml",oi=Ur,is=!1,os=null,fc=Ge({},[Dn,_o,Ur],uy),as=Zt(["mi","mo","mn","ms","mtext"]),ee=Ge({},as),L=Zt(["annotation-xml"]),H=Ge({},L),Qe=Ge({},["title","style","font","a","script"]),ke=null,bt=["application/xhtml+xml","text/html"],ut=null,$o=null,ZE=n.createElement("form"),Ly=function(g){return g instanceof RegExp||g instanceof Function},Kp=function(){let g=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};if($o&&$o===g)return;g&&typeof g=="object"||(g={}),g=Rr(g),ke=bt.indexOf(g.PARSER_MEDIA_TYPE)===-1?"text/html":g.PARSER_MEDIA_TYPE,ut=ke==="application/xhtml+xml"?uy:ho,B=Ni(g,"ALLOWED_TAGS",X,{transform:ut}),_=Ni(g,"ALLOWED_ATTR",D,{transform:ut}),os=Ni(g,"ALLOWED_NAMESPACES",fc,{transform:uy}),ii=Ni(g,"ADD_URI_SAFE_ATTR",dn,{transform:ut,base:dn}),mc=Ni(g,"ADD_DATA_URI_TAGS",ns,{transform:ut,base:ns}),On=Ni(g,"FORBID_CONTENTS",pc,{transform:ut}),P=Ni(g,"FORBID_TAGS",Rr({}),{transform:ut}),E=Ni(g,"FORBID_ATTR",Rr({}),{transform:ut}),ni=Ir(g,"USE_PROFILES")?g.USE_PROFILES&&typeof g.USE_PROFILES=="object"?Rr(g.USE_PROFILES):g.USE_PROFILES:!1,ie=g.ALLOW_ARIA_ATTR!==!1,fe=g.ALLOW_DATA_ATTR!==!1,ve=g.ALLOW_UNKNOWN_PROTOCOLS||!1,we=g.ALLOW_SELF_CLOSE_IN_ATTR!==!1,ye=g.SAFE_FOR_TEMPLATES||!1,Ne=g.SAFE_FOR_XML!==!1,Me=g.WHOLE_DOCUMENT||!1,Kt=g.RETURN_DOM||!1,vt=g.RETURN_DOM_FRAGMENT||!1,Nt=g.RETURN_TRUSTED_TYPE||!1,St=g.FORCE_BODY||!1,Gr=g.SANITIZE_DOM!==!1,$e=g.SANITIZE_NAMED_PROPS||!1,zi=g.KEEP_CONTENT!==!1,xo=g.IN_PLACE||!1,M=tP(g.ALLOWED_URI_REGEXP)?g.ALLOWED_URI_REGEXP:WI,oi=typeof g.NAMESPACE=="string"?g.NAMESPACE:Ur,ee=gy(g,"MATHML_TEXT_INTEGRATION_POINTS",()=>Ge({},as)),H=gy(g,"HTML_INTEGRATION_POINTS",()=>Ge({},L));let N=gy(g,"CUSTOM_ELEMENT_HANDLING",()=>Ha(null));if(y=Ha(null),Ir(N,"tagNameCheck")&&Ly(N.tagNameCheck)&&(y.tagNameCheck=N.tagNameCheck),Ir(N,"attributeNameCheck")&&Ly(N.attributeNameCheck)&&(y.attributeNameCheck=N.attributeNameCheck),Ir(N,"allowCustomizedBuiltInElements")&&typeof N.allowCustomizedBuiltInElements=="boolean"&&(y.allowCustomizedBuiltInElements=N.allowCustomizedBuiltInElements),Qt(y),ye&&(fe=!1),vt&&(Kt=!0),ni&&(B=Ge({},ZI),_=Ha(null),ni.html===!0&&(Ge(B,BI),Ge(_,HI)),ni.svg===!0&&(Ge(B,dy),Ge(_,fy),Ge(_,Sp)),ni.svgFilters===!0&&(Ge(B,py),Ge(_,fy),Ge(_,Sp)),ni.mathMl===!0&&(Ge(B,my),Ge(_,KI),Ge(_,Sp))),Y.tagCheck=null,Y.attributeCheck=null,Ir(g,"ADD_TAGS")&&(typeof g.ADD_TAGS=="function"?Y.tagCheck=g.ADD_TAGS:Ga(g.ADD_TAGS)&&(B===X&&(B=Rr(B)),Ge(B,g.ADD_TAGS,ut))),Ir(g,"ADD_ATTR")&&(typeof g.ADD_ATTR=="function"?Y.attributeCheck=g.ADD_ATTR:Ga(g.ADD_ATTR)&&(_===D&&(_=Rr(_)),Ge(_,g.ADD_ATTR,ut))),Ir(g,"ADD_FORBID_CONTENTS")&&Ga(g.ADD_FORBID_CONTENTS)&&(On===pc&&(On=Rr(On)),Ge(On,g.ADD_FORBID_CONTENTS,ut)),zi&&(B["#text"]=!0),Me&&Ge(B,["html","head","body"]),B.table&&(Ge(B,["tbody"]),delete P.tbody),g.TRUSTED_TYPES_POLICY){if(typeof g.TRUSTED_TYPES_POLICY.createHTML!="function")throw ti('TRUSTED_TYPES_POLICY configuration option must provide a "createHTML" hook.');if(typeof g.TRUSTED_TYPES_POLICY.createScriptURL!="function")throw ti('TRUSTED_TYPES_POLICY configuration option must provide a "createScriptURL" hook.');let ne=pe;pe=g.TRUSTED_TYPES_POLICY;try{F=Re("")}catch(ae){throw pe=ne,ae}}else g.TRUSTED_TYPES_POLICY===null?(pe=void 0,F=""):(pe===void 0&&(pe=Mt()),pe&&typeof F=="string"&&(F=Re("")));Zt&&Zt(g),$o=g},Vy=Ge({},[...dy,...py,...rP]),Fy=Ge({},[...my,...nP]),HE=function(g,N,ne){return N.namespaceURI===Ur?g==="svg":N.namespaceURI===Dn?g==="svg"&&(ne==="annotation-xml"||ee[ne]):!!Vy[g]},KE=function(g,N,ne){return N.namespaceURI===Ur?g==="math":N.namespaceURI===_o?g==="math"&&H[ne]:!!Fy[g]},WE=function(g,N,ne){return N.namespaceURI===_o&&!H[ne]||N.namespaceURI===Dn&&!ee[ne]?!1:!Fy[g]&&(Qe[g]||!Vy[g])},qE=function(g){let N=se(g),ne=ho(W(g)),ae=T(g),Ee,ze;return ae&&J(ae)===At.element?(Ee={namespaceURI:se(ae)},ze=ho(W(ae))):(Ee={namespaceURI:oi},ze="template"),os[N]?N===_o?HE(ne,Ee,ze):N===Dn?KE(ne,Ee,ze):N===Ur?WE(ne,Ee,ze):!!(ke==="application/xhtml+xml"&&os[N]):!1},Ai=function(g){Xl(t.removed,{element:g});try{T(g).removeChild(g)}catch{if(f(g),!T(g))throw ti("a node selected for removal could not be detached from its tree and cannot be safely returned; refusing to sanitize in place")}},By=function(g,N,ne){try{h(g,N)}catch{try{g.removeAttribute(ne)}catch{}}},Wp=function(g){Gp(g);let N=k(g);N&&ei(W5(N),ae=>{try{f(ae)}catch{}});let ne=J(g)===At.element?z(g):null;if(ne)for(let ae=ne.length-1;ae>=0;--ae){let Ee=ne[ae],ze=Ee&&Ee.name;typeof ze=="string"&&By(g,Ee,ze)}},So=function(g,N,ne){if(!ne)try{ne=N.getAttributeNode(g)}catch{ne=null}Xl(t.removed,{attribute:ne||null,from:N});try{ne?h(N,ne):N.removeAttribute(g)}catch{try{N.removeAttribute(g)}catch{}}if(g==="is")if(Kt||vt)try{Ai(N)}catch{}else try{N.setAttribute(g,"")}catch{}},Zy=function(g){let N=z(g);if(N)for(let ne=N.length-1;ne>=0;--ne){let ae=N[ne],Ee=ae&&ae.name;typeof Ee!="string"||_[ut(Ee)]||By(g,ae,Ee)}},qp=function(g,N){let ne=arguments.length>2&&arguments[2]!==void 0&&arguments[2],ae=[g];for(;ae.length>0;){let Ee=ae.pop();if(N(Ee)===!1)continue;if(ne&&J(Ee)===At.element){let Le=S(Ee);ai(Le)&&ae.push(Le)}let ze=k(Ee);if(ze)for(let Le=ze.length-1;Le>=0;--Le)ae.push(ze[Le])}},Gp=function(g){qp(g,N=>{J(N)===At.element&&Zy(N)})},Jp=function(g){let N=[];return qp(g,ne=>{N.push(ne)},!0),N},GE=function(g,N){let ne=ly();ei(Jp(g),ae=>{J(ae)===At.element&&cy(ne,ae)}),ei(N,ae=>{J(ae)===At.element&&!Ql(ne,ae)&&Zy(ae)})},Hy=function(g,N){let ne=!1;return ei(t.removed,ae=>{ae.element&&(ne=ne||ae.element===g,Gp(ae.element))}),GE(g,N),ne},JE=function(g,N){let ne=Jr,ae=null,Ee=()=>(ae||(ae=ly(),ei(N,ze=>{cy(ae,ze)})),ae);for(let ze=0;;ze++){let Le=Jp(g),Ot=[g],pn=!1;if(ei(Le,ir=>{J(ir)===At.documentFragment?Xl(Ot,ir):!pn&&!Ql(ne,ir)&&(pn=Ql(Ee(),ir))}),!pn)return;if(ze>=8)throw ti("the tree kept changing during in-place sanitization; refusing to return it");ei(Ot,(ir,gr)=>{YE(ir,gr>0,g,Ee())})}},YE=function(g,N,ne,ae){let Ee=Yp(g),ze;for(;ze=Ee.nextNode();)Ql(ae,ze)&&!Ql(Jr,ze)&&(N&&Yr(Ye.uponSanitizeShadowNode,ze,null),Qp(ze,ne),em(ze,ne),ai(ze.content)&&ls(ze.content))},XE=function(g){Jr&&cy(Jr,g)},Ky=function(g,N){return Ne?g==="patchsrc"||g==="for"&&N!=="label"&&N!=="output":!1},QE=function(g){Ne&&qp(g,N=>{let ne=J(N);if(ne===At.processingInstruction||ne===At.comment&&Xt(qI,N.data)){try{f(N)}catch{}return!1}if(ne===At.element){let ae=N,Ee=ut(W(N));try{ae.hasAttribute&&ae.hasAttribute("patchsrc")&&ae.removeAttribute("patchsrc"),ae.hasAttribute&&ae.hasAttribute("for")&&Ky("for",Ee)&&ae.removeAttribute("for")}catch{}}return!0})},Wy=function(g){let N=null,ne=null;if(St)g="<remove></remove>"+g;else{let ze=MI(g,/^[\r\n\t ]+/);ne=ze&&ze[0]}ke==="application/xhtml+xml"&&oi===Ur&&(g='<html xmlns="http://www.w3.org/1999/xhtml"><head></head><body>'+g+"</body></html>");let ae=pe?Re(g):g;if(oi===Ur)try{N=new u().parseFromString(ae,ke)}catch{}if(!N||!N.documentElement){N=mr.createDocument(oi,"template",null);try{N.documentElement.innerHTML=is?F:ae}catch{}}let Ee=N.body||N.documentElement;return g&&ne&&Ee.insertBefore(n.createTextNode(ne),Ee.childNodes[0]||null),oi===Ur?Wr.call(N,Me?"html":"body")[0]:Me?N.documentElement:Ee},Yp=function(g){let N=U?U(g):g.ownerDocument;return gt.call(N||g,g,l.SHOW_ELEMENT|l.SHOW_COMMENT|l.SHOW_TEXT|l.SHOW_PROCESSING_INSTRUCTION|l.SHOW_CDATA_SECTION,null)},hc=function(g){return g=ec(g,Ht," "),g=ec(g,er," "),g=ec(g,Tr," "),g},Xp=function(g){qy(g);let N=g.querySelectorAll?.call(g,"template");N&&ei(N,ne=>{ai(ne.content)&&Xp(ne.content)})},qy=function(g){g.normalize();let N=U?U(g):g.ownerDocument,ne=gt.call(N||g,g,l.SHOW_TEXT|l.SHOW_COMMENT|l.SHOW_CDATA_SECTION|l.SHOW_PROCESSING_INSTRUCTION,null),ae=ne.nextNode();for(;ae;)ae.data=hc(ae.data),ae=ne.nextNode()},gc=function(g){let N=O?O(g):null;return typeof N!="string"||ut(N)!=="form"?!1:typeof g.nodeName!="string"||typeof g.textContent!="string"||typeof g.removeChild!="function"||g.attributes!==z(g)||typeof g.removeAttribute!="function"||typeof g.removeAttributeNode!="function"||typeof g.getAttributeNode!="function"||typeof g.setAttribute!="function"||typeof g.namespaceURI!="string"||typeof g.insertBefore!="function"||typeof g.hasChildNodes!="function"||g.nodeType!==j(g)||g.childNodes!==k(g)},ai=function(g){if(!j||typeof g!="object"||!g)return!1;try{return j(g)===At.documentFragment}catch{return!1}},ss=function(g){if(!j||typeof g!="object"||!g)return!1;try{return typeof j(g)=="number"}catch{return!1}};function Yr(oe,g,N){oe.length!==0&&ei(oe,ne=>{ne.call(t,g,N,$o)})}let e4=function(g,N){return!!(Ne&&g.hasChildNodes()&&!ss(g.firstElementChild)&&Xt(hy,g.textContent)&&Xt(hy,g.innerHTML)||Ne&&fP[N]&&J(g)===At.element&&se(g)===Ur&&(ss(g.firstElementChild)||typeof g.textContent=="string"&&Xt(hy,g.textContent))||g.nodeType===At.processingInstruction||Ne&&g.nodeType===At.comment&&Xt(qI,g.data))},vc=function(g,N){return g instanceof RegExp?Xt(g,N):g instanceof Function&&!!g(N,...[...arguments].slice(2))},t4=function(g,N,ne){if(!P[N]&&Yy(N)&&vc(y.tagNameCheck,N))return!1;if(zi&&!On[N]&&!On[ho(N)]){let ae=T(g),Ee=k(g);if(Ee&&ae){let ze=Ee.length;for(let Le=ze-1;Le>=0;--Le){let Ot=g===ne?m(Ee[Le],!0):Ee[Le];ae.insertBefore(Ot,v(g))}}}return Ai(g),!0},Gy=function(g,N,ne,ae){return g.length===0?N:N===ne||N===ae?Rr(N):N},Io=function(g,N){return g===N||T(g)!==null?!1:(xo&&Gp(g),!0)},Qp=function(g,N){if(XE(g),Yr(Ye.beforeSanitizeElements,g,null),Io(g,N))return!0;if(gc(g))return Ai(g),!0;let ne=ut(W(g));if(B=Gy(Ye.uponSanitizeElement,B,X,wt),Yr(Ye.uponSanitizeElement,g,{tagName:ne,allowedTags:B}),Io(g,N))return!0;if(e4(g,ne))return Ai(g),!0;if(P[ne]||!(Y.tagCheck instanceof Function&&Y.tagCheck(ne))&&!B[ne]){let ae=t4(g,ne,N);return ae===!1&&(Yr(Ye.afterSanitizeElements,g,null),Io(g,N))?!0:ae}if(J(g)===At.element&&!qE(g)||(ne==="noscript"||ne==="noembed"||ne==="noframes")&&Xt(mP,g.innerHTML))return Ai(g),!0;if(ye&&g.nodeType===At.text){let ae=hc(g.textContent);g.textContent!==ae&&(Xl(t.removed,{element:g.cloneNode()}),g.textContent=ae)}return Yr(Ye.afterSanitizeElements,g,null),Io(g,N)},Jy=function(g,N,ne){if(E[N]||Ky(N,g)||Gr&&(N==="id"||N==="name")&&(ne in n||ne in ZE))return!1;let ae=_[N]||Y.attributeCheck instanceof Function&&Y.attributeCheck(N,g);return fe&&Xt(fr,N)||ie&&Xt(qr,N)?!0:ae?ii[N]||Xt(M,ec(ne,x,""))||(N==="src"||N==="xlink:href"||N==="href")&&g!=="script"&&LI(ne,"data:")===0&&mc[g]||ve&&!Xt(hr,ec(ne,x,""))?!0:!ne:Yy(g)&&vc(y.tagNameCheck,g)&&vc(y.attributeNameCheck,N,g)||N==="is"&&y.allowCustomizedBuiltInElements&&vc(y.tagNameCheck,ne)},r4=Ge({},["annotation-xml","color-profile","font-face","font-face-format","font-face-name","font-face-src","font-face-uri","missing-glyph"]),Yy=function(g){return!r4[ho(g)]&&Xt(I,g)},n4=function(g,N,ne,ae){if(pe&&typeof d=="object"&&typeof d.getAttributeType=="function"&&!ne)switch(d.getAttributeType(g,N)){case"TrustedHTML":return Re(ae);case"TrustedScriptURL":return Be(ae)}return ae},i4=function(g,N,ne,ae){try{return ne?g.setAttributeNS(ne,N,ae):g.setAttribute(N,ae),!gc(g)||(Ai(g),!1)}catch{return So(N,g),!1}},Xy=function(g,N){return Ne&&Xt(/((--!?|])>)|<\/(style|script|title|xmp|textarea|noscript|iframe|noembed|noframes)/i,N)?!0:ho(g)==="attributename"&&MI(N,"href")!==null},em=function(g,N){if(Yr(Ye.beforeSanitizeAttributes,g,null),Io(g,N))return;let ne=g.attributes;if(!ne||gc(g))return;_=Gy(Ye.uponSanitizeAttribute,_,D,$t);let ae={attrName:"",attrValue:"",keepAttr:!0,allowedAttributes:_,forceKeepAttr:void 0},Ee=ne.length,ze=ut(g.nodeName);for(;Ee--;){let Le=ne[Ee],Ot=Le.name,pn=Le.namespaceURI,ir=Le.value,gr=ut(Ot),Eo=ir,vr=Ot==="value"?Eo:G5(Eo),Qy=!1;ae.attrName=gr,ae.attrValue=vr,ae.keepAttr=!0,ae.forceKeepAttr=void 0,Yr(Ye.uponSanitizeAttribute,g,ae),vr=ae.attrValue,$e&&(gr==="id"||gr==="name")&&LI(vr,rs)!==0&&(So(Ot,g,Le),vr=rs+vr,Qy=!0),Xy(Ot,vr)?So(Ot,g,Le):ae.forceKeepAttr||(ae.keepAttr?!we&&Xt(GI,vr)?So(Ot,g,Le):(ye&&(vr=hc(vr)),Jy(ze,gr,vr)?(vr=n4(ze,gr,pn,vr),vr!==Eo&&i4(g,Ot,pn,vr)&&Qy&&jI(t.removed)):So(Ot,g,Le)):So(Ot,g,Le))}Yr(Ye.afterSanitizeAttributes,g,null),Io(g,N)},ls=function(g){let N=null,ne=Yp(g);for(Yr(Ye.beforeSanitizeShadowDOM,g,null);N=ne.nextNode();)if(Yr(Ye.uponSanitizeShadowNode,N,null),Qp(N,g),em(N,g),ai(N.content)&&ls(N.content),J(N)===At.element){let ae=S(N);ai(ae)&&(tm(ae),ls(ae))}ye&&qy(g),Yr(Ye.afterSanitizeShadowDOM,g,null)},tm=function(g){let N=[{node:g,shadow:null}];for(;N.length>0;){let ne=N.pop();if(ne.shadow){ls(ne.shadow);continue}let ae=ne.node,Ee=J(ae)===At.element,ze=k(ae);if(ze)for(let Le=ze.length-1;Le>=0;--Le)N.push({node:ze[Le],shadow:null});if(Ee){let Le=O?O(ae):null;if(typeof Le=="string"&&ut(Le)==="template"){let Ot=ae.content;ai(Ot)&&N.push({node:Ot,shadow:null})}}if(Ee){let Le=S(ae);ai(Le)&&N.push({node:null,shadow:Le},{node:Le,shadow:null})}}};return t.sanitize=function(oe){let g=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},N=null,ne=null,ae=null,Ee=null;if(is=!oe,is&&(oe="<!-->"),typeof oe!="string"&&!ss(oe)&&(oe=Q5(oe),typeof oe!="string"))throw ti("dirty is not a string, aborting");if(!t.isSupported)return oe;Xe?(B=wt,_=$t):Kp(g),(Ye.uponSanitizeElement.length>0||Ye.uponSanitizeAttribute.length>0)&&(B=Rr(B)),Ye.uponSanitizeAttribute.length>0&&(_=Rr(_)),t.removed=[];let ze=xo&&typeof oe!="string"&&ss(oe),Le=[],Ot=Jr;if(ze){QE(oe);let gr=W(oe);if(typeof gr=="string"){let Eo=ut(gr);if(!B[Eo]||P[Eo])throw Wp(oe),ti("root node is forbidden and cannot be sanitized in-place")}if(gc(oe))throw Wp(oe),ti("root node is clobbered and cannot be sanitized in-place");Le=Jp(oe),Jr=ly()}else if(ss(oe))N=Wy("<!---->"),ne=N.ownerDocument.importNode(oe,!0),ne.nodeType===At.element&&ne.nodeName==="BODY"||ne.nodeName==="HTML"?N=ne:N.appendChild(ne),tm(N);else{if(!Kt&&!ye&&!Me&&oe.indexOf("<")===-1)return pe&&Nt?Re(oe):oe;if(N=Wy(oe),!N)return Kt?null:Nt?F:""}N&&St&&Ai(N.firstChild);let pn=ze?oe:N;try{ze&&tm(oe);let gr=Yp(pn);for(;ae=gr.nextNode();)Qp(ae,pn),em(ae,pn),ai(ae.content)&&ls(ae.content);ze&&JE(oe,Le)}catch(gr){throw ze&&(Wp(oe),Hy(oe,Le)),gr}finally{Jr=Ot}if(ze){if(Hy(oe,Le))throw ti("a node selected for removal could not be safely returned; refusing to sanitize in place");return ye&&Xp(oe),oe}if(Kt){if(ye&&Xp(N),vt)for(Ee=yt.call(N.ownerDocument);N.firstChild;)Ee.appendChild(N.firstChild);else Ee=N;return(_.shadowroot||_.shadowrootmode)&&(Ee=Tt.call(i,Ee,!0)),Ee}let ir=Me?N.outerHTML:N.innerHTML;return Me&&B["!doctype"]&&N.ownerDocument&&N.ownerDocument.doctype&&N.ownerDocument.doctype.name&&Xt(dP,N.ownerDocument.doctype.name)&&(ir="<!DOCTYPE "+N.ownerDocument.doctype.name+`>
|
|
96
|
-
`+ir),ye&&(ir=hc(ir)),pe&&Nt?Re(ir):ir},t.setConfig=function(){let oe=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};Kp(oe),Xe=!0,wt=B,$t=_},t.clearConfig=function(){$o=null,Xe=!1,wt=null,$t=null,pe=ue,F=""},t.isValidAttribute=function(oe,g,N){$o||Kp({});let ne=ut(oe),ae=ut(g);return typeof N=="string"&&(Xy(g,N)||!we&&Xt(GI,N))?!1:Jy(ne,ae,N)},t.addHook=function(oe,g){typeof g=="function"&&Ir(Ye,oe)&&Xl(Ye[oe],g)},t.removeHook=function(oe,g){if(Ir(Ye,oe)){if(g!==void 0){let N=
|
|
94
|
+
`):t.stack};for(let[a,s]of Object.entries(t))o[a]=this.formatData(s,n,i+1);return"cause"in t&&(o.cause=this.formatData(t.cause,n,i+1)),this.redactSensitive(o)}if(t instanceof Date)return t.toISOString();if(typeof t!="object")return t;if(Array.isArray(t))return t.length>20&&La?`Array(${t.length}) [${t.slice(0,3).map(r=>this.formatData(r,n,i+1)).join(", ")}, ...]`:t.map(r=>this.formatData(r,n,i+1));try{let r={},o=Object.entries(t),a=La?50:200;for(let[s,l]of o.slice(0,a))r[s]=this.formatData(l,n,i+1);return o.length>a&&(r["..."]=`${o.length-a} more properties`),this.redactSensitive(r)}catch{return"[Unserializable]"}}logToBrowser(t){if(!Jn||!this.shouldLog(t.level))return;let{level:n,description:i,context:r,data:o,error:a}=t,s=pp[n],u=`[${r||this.context||"www"}] ${n.toUpperCase()}:`,d=`color: ${s.color}; font-weight: bold;`;o!==void 0?console[n](`%c${u}`,d,i,this.formatData(o)):console[n](`%c${u}`,d,i),a&&(a instanceof Error?console.error(a):console.error("Error details:",a))}logToNode(t){if(!mp||!this.shouldLog(t.level))return;let{level:n,description:i,context:r,data:o,error:a}=t,s=r||this.context||"www";if(La){let l={timestamp:this.formatISOTimestamp(),level:n.toUpperCase(),context:s,msg:i,message:i};o!==void 0&&(l.data=this.formatData(o)),a!==void 0&&(l.error=this.formatData(a));let u=JSON.stringify(l);n==="trace"?console.log(u):console[n](u)}else{let l=pp[n],u=this.formatTimestamp(),d="\x1B[0m",p="\x1B[2m",m=l.nodeColor||"",f=`${p}${u}${d} ${m}${n.toUpperCase()} (${s}):${d} ${i}`;console[n](f),o!==void 0&&console.log(JSON.stringify(this.formatData(o),null,2)),a&&(a instanceof Error?(console.error(`\x1B[31mError:${d}`,a.message),a.stack&&console.error(`\x1B[90m${a.stack}${d}`)):console.error("Error:",a))}}log(t){Jn?this.logToBrowser(t):mp&&this.logToNode(t)}error(t,n){this.log({level:"error",description:t,data:n,context:this.context})}warn(t,n){this.log({level:"warn",description:t,data:n,context:this.context})}info(t,n){this.log({level:"info",description:t,data:n,context:this.context})}debug(t,n){this.log({level:"debug",description:t,data:n,context:this.context})}trace(t,n){this.log({level:"trace",description:t,data:n,context:this.context})}isEnabled(){return Jn?this.enabledInBrowser:!0}setLevel(t){this.settings.minLevel=t}createContextLogger(t){let n=new fp(this.settings,t);return{error:(i,r)=>n.error(i,r),warn:(i,r)=>n.warn(i,r),info:(i,r)=>n.info(i,r),debug:(i,r)=>n.debug(i,r),trace:(i,r)=>n.trace(i,r),isEnabled:()=>n.isEnabled(),setLevel:i=>n.setLevel(i)}}};M2.hasShownHelp=!1;L2=M2;Nn=new L2,p7=Nn.error.bind(Nn),m7=Nn.warn.bind(Nn),f7=Nn.info.bind(Nn),h7=Nn.debug.bind(Nn),g7=Nn.trace.bind(Nn),uo=class{constructor(e,t){this.objectName=e,this.settings=t,this.logger=co(e)}};N2={green:{50:"oklch(98.2% 0.018 155.826)",100:"oklch(96.2% 0.044 156.743)",200:"oklch(92.5% 0.084 155.995)",300:"oklch(87.1% 0.15 154.449)",400:"oklch(79.2% 0.209 151.711)",500:"oklch(72.3% 0.219 149.579)",600:"oklch(62.7% 0.194 149.214)",700:"oklch(52.7% 0.154 150.069)",800:"oklch(44.8% 0.119 151.328)",900:"oklch(39.3% 0.095 152.535)",950:"oklch(26.6% 0.065 152.934)"},blue:{50:"oklch(97% 0.014 254.604)",100:"oklch(93.2% 0.032 255.585)",200:"oklch(88.2% 0.059 254.128)",300:"oklch(80.9% 0.105 251.813)",400:"oklch(70.7% 0.165 254.624)",500:"oklch(62.3% 0.214 259.815)",600:"oklch(54.6% 0.245 262.881)",700:"oklch(48.8% 0.243 264.376)",800:"oklch(42.4% 0.199 265.638)",900:"oklch(37.9% 0.146 265.522)",950:"oklch(28.2% 0.091 267.935)"},rose:{50:"oklch(96.9% 0.015 12.422)",100:"oklch(94.1% 0.03 12.58)",200:"oklch(89.2% 0.058 10.001)",300:"oklch(81% 0.117 11.638)",400:"oklch(71.2% 0.194 13.428)",500:"oklch(64.5% 0.246 16.439)",600:"oklch(58.6% 0.253 17.585)",700:"oklch(51.4% 0.222 16.935)",800:"oklch(45.5% 0.188 13.697)",900:"oklch(41% 0.159 10.272)",950:"oklch(27.1% 0.105 12.094)"},cyan:{50:"oklch(98.4% 0.019 200.873)",100:"oklch(95.6% 0.045 203.388)",200:"oklch(91.7% 0.08 205.041)",300:"oklch(86.5% 0.127 207.078)",400:"oklch(78.9% 0.154 211.53)",500:"oklch(71.5% 0.143 215.221)",600:"oklch(60.9% 0.126 221.723)",700:"oklch(52% 0.105 223.128)",800:"oklch(45% 0.085 224.283)",900:"oklch(39.8% 0.07 227.392)",950:"oklch(30.2% 0.056 229.695)"},purple:{50:"oklch(97.7% 0.014 308.299)",100:"oklch(94.6% 0.033 307.174)",200:"oklch(90.2% 0.063 306.703)",300:"oklch(82.7% 0.119 306.383)",400:"oklch(71.4% 0.203 305.504)",500:"oklch(62.7% 0.265 303.9)",600:"oklch(55.8% 0.288 302.321)",700:"oklch(49.6% 0.265 301.924)",800:"oklch(43.8% 0.218 303.724)",900:"oklch(38.1% 0.176 304.987)",950:"oklch(29.1% 0.149 302.717)"},amber:{50:"oklch(98.7% 0.022 95.277)",100:"oklch(96.2% 0.059 95.617)",200:"oklch(92.4% 0.12 95.746)",300:"oklch(87.9% 0.169 91.605)",400:"oklch(82.8% 0.189 84.429)",500:"oklch(76.9% 0.188 70.08)",600:"oklch(66.6% 0.179 58.318)",700:"oklch(55.5% 0.163 48.998)",800:"oklch(47.3% 0.137 46.201)",900:"oklch(41.4% 0.112 45.904)",950:"oklch(27.9% 0.077 45.635)"},indigo:{50:"oklch(96.2% 0.018 272.314)",100:"oklch(93% 0.034 272.788)",200:"oklch(87% 0.065 274.039)",300:"oklch(78.5% 0.115 274.713)",400:"oklch(67.3% 0.182 276.935)",500:"oklch(58.5% 0.233 277.117)",600:"oklch(51.1% 0.262 276.966)",700:"oklch(45.7% 0.24 277.023)",800:"oklch(39.8% 0.195 277.366)",900:"oklch(35.9% 0.144 278.697)",950:"oklch(25.7% 0.09 281.288)"},pink:{50:"oklch(97.1% 0.014 343.198)",100:"oklch(94.8% 0.028 342.258)",200:"oklch(89.9% 0.061 343.231)",300:"oklch(82.3% 0.12 346.018)",400:"oklch(71.8% 0.202 349.761)",500:"oklch(65.6% 0.241 354.308)",600:"oklch(59.2% 0.249 0.584)",700:"oklch(52.5% 0.223 3.958)",800:"oklch(45.9% 0.187 3.815)",900:"oklch(40.8% 0.153 2.432)",950:"oklch(28.4% 0.109 3.907)"},teal:{50:"oklch(98.4% 0.014 180.72)",100:"oklch(95.3% 0.051 180.801)",200:"oklch(91% 0.096 180.426)",300:"oklch(85.5% 0.138 181.071)",400:"oklch(77.7% 0.152 181.912)",500:"oklch(70.4% 0.14 182.503)",600:"oklch(60% 0.118 184.704)",700:"oklch(51.1% 0.096 186.391)",800:"oklch(43.7% 0.078 188.216)",900:"oklch(38.6% 0.063 188.416)",950:"oklch(27.7% 0.046 192.524)"},sky:{50:"oklch(97.7% 0.013 236.62)",100:"oklch(95.1% 0.026 236.824)",200:"oklch(90.1% 0.058 230.902)",300:"oklch(82.8% 0.111 230.318)",400:"oklch(74.6% 0.16 232.661)",500:"oklch(68.5% 0.169 237.323)",600:"oklch(58.8% 0.158 241.966)",700:"oklch(50% 0.134 242.749)",800:"oklch(44.3% 0.11 240.79)",900:"oklch(39.1% 0.09 240.876)",950:"oklch(29.3% 0.066 243.157)"}};T6=class{constructor(){this.tokenName="auth-token",this.deviceIdName="pl-device-id",this.tokenMaxAge=3600*24*90,this.fallbackStorageKey="token"}currentCookieOptions(){return E6(typeof window>"u"?void 0:window.location)}getCookie(e){if(typeof document>"u")return null;let t=document.cookie.split(";");for(let n of t){let[i,r]=n.trim().split("=");if(i===e)return decodeURIComponent(r||"")}return null}setCookie(e,t,n={}){if(typeof document>"u")return;let{secure:i=!0,sameSite:r="lax",maxAge:o=3600*24*7,domain:a,path:s="/"}=n,l=`${e}=${encodeURIComponent(t)}`;l+=`; Path=${s}`,l+=`; Max-Age=${o}`,l+=`; SameSite=${r}`,i&&(l+="; Secure"),a&&(l+=`; Domain=${a}`),document.cookie=l}removeCookie(e,t={}){this.setCookie(e,"",{...t,maxAge:0})}isLocalStorageFunctional(){return typeof window<"u"&&typeof window.localStorage?.getItem=="function"&&typeof window.localStorage?.setItem=="function"&&typeof window.localStorage?.removeItem=="function"}getAuthToken(){let e=this.getCookie(this.tokenName);if(e)return e;if(this.isLocalStorageFunctional()){let t=window.localStorage.getItem(this.fallbackStorageKey);if(t)return this.setAuthToken(t),window.localStorage.removeItem(this.fallbackStorageKey),t}return null}setAuthToken(e){let t=this.currentCookieOptions();this.setCookie(this.tokenName,e,{secure:t.secure,sameSite:"lax",maxAge:this.tokenMaxAge,domain:t.domain,path:t.path})}removeAuthToken(){let e=this.currentCookieOptions();this.removeCookie(this.tokenName,{domain:e.domain,path:e.path}),this.removeCookie(this.tokenName,{domain:".pagelines.com",path:"/"}),this.isLocalStorageFunctional()&&window.localStorage.removeItem(this.fallbackStorageKey)}getDeviceId(){return this.getCookie(this.deviceIdName)}},po=new T6,N6=["https://redirect-a.invalid","https://redirect-b.invalid"];z6=c.enum(["linkedin","x","facebook","tiktok","youtube","github","instagram","threads","email","phone","website","calendar"]),A6=c.object({platform:z6,handle:c.string(),url:c.string().optional()}),O6=c.preprocess(e=>Array.isArray(e)?e.filter(t=>t&&typeof t=="object"&&t.platform&&t.handle):e,c.array(A6)),D6=["image","audio","video","document"],G0=c.enum(D6),P6=["avatar","cover","general"],B2=c.enum(P6),R6=c.enum(["processing","active","failed","deleted"]),U6=c.enum(["low","standard","high"]),j6=c.enum(["jpg","jpeg","png","gif","webp","svg"]),M6=c.enum(["mp4","webm","ogg","mov","avi"]),L6=c.enum(["mp3","wav","ogg","opus","aac","flac","webm","m4a","mp4"]),V6=c.object({mediaId:c.string(),userId:c.string(),orgId:c.string(),botId:c.string().nullable().optional(),filename:c.string(),mimeType:c.string(),size:c.number(),src:c.string(),alt:c.string().optional(),context:B2.default("general"),status:R6.default("processing"),quality:U6.default("standard"),createdAt:c.string().optional(),updatedAt:c.string().optional()}),Bt=V6.extend({mediaType:G0.optional(),className:c.string().optional(),width:c.number().optional(),height:c.number().optional(),duration:c.number().optional(),blurhash:c.string().optional()}).partial(),F6=c.object({duration:c.number().optional(),thumbnail:c.string().optional(),autoplay:c.boolean().optional(),loop:c.boolean().optional(),muted:c.boolean().optional(),controls:c.boolean().optional()}),B6=c.object({duration:c.number().optional(),autoplay:c.boolean().optional(),loop:c.boolean().optional(),muted:c.boolean().optional(),controls:c.boolean().optional()}),Z6=Bt.extend({mediaType:c.literal("image"),imageFormat:j6.optional()}),H6=Bt.extend({mediaType:c.literal("video"),videoFormat:M6.optional(),video:F6.optional()}),K6=Bt.extend({mediaType:c.literal("audio"),audioFormat:L6.optional(),audio:B6.optional()}),W6=Bt.extend({mediaType:c.literal("document")}),w7=c.discriminatedUnion("mediaType",[Z6,H6,K6,W6]),Z2=c.enum(["xxs","xs","sm","md","lg","xl"]),H2=c.enum(["primary","default","overlay","red","green","indigo","orange"]),K2=c.enum(["ghost","link","outline","solid"]),K0=c.object({key:c.string().optional(),label:c.string().optional(),href:c.string().optional(),size:Z2.optional(),theme:H2.optional(),design:K2.optional(),icon:c.union([c.string(),Bt]).optional(),iconAfter:c.union([c.string(),Bt]).optional(),rounding:c.enum(["full","md","lg"]).optional(),loading:c.boolean().optional(),disabled:c.boolean().optional(),tooltip:c.string().optional(),onClick:c.any().optional(),testId:c.string().optional(),target:c.enum(["_blank","_self"]).optional(),type:c.enum(["button","submit","reset"]).optional()}),x7=c.object({buttons:c.array(K0).optional(),size:Z2.optional(),theme:H2.optional(),design:K2.optional()}),q6=["COMPUTER_BOOT_FAILED","COMPUTER_CREATE_FAILED","BOT_DELETED","COMPUTER_DELETE_FAILED","COMPUTER_INACTIVE","COMPUTER_LIMIT","COMPUTER_NOT_FOUND","BOT_NOT_FOUND","COMPUTER_NOT_DEPLOYED","BOT_TOKENS_MISSING","COMPUTER_UNREACHABLE","COMPUTER_UPDATE_FAILED","COMPUTER_WAKE_TIMEOUT","ADMISSION_REQUIRED","ALREADY_MEMBER","ATTACHMENT_TYPE_UNSUPPORTED","AUTH_ACCOUNT_NOT_FOUND","AUTH_BOT_BLOCKED","AUTH_DISPOSABLE_EMAIL","AUTH_EMAIL_IN_USE","AUTH_INVALID","AUTH_INVALID_CODE","AUTH_INVALID_HANDOFF","AUTH_LOCKED_OUT","AUTH_MISSING","AUTH_PROVIDER_FAILED","AUTH_PROVIDER_NOT_CONFIGURED","AUTH_RATE_LIMITED","AUTH_REVOKED","AUTH_TURNSTILE_MISSING","AUTH_UNKNOWN","AUTH_WRONG_TYPE","ROUTINE_CHANNEL_UNAVAILABLE","ROUTINE_PURPOSE_REQUIRED","BOT_REPLY_FAILED","BILLING_BUDGET_REACHED","BILLING_DEMO_SPENT","BILLING_NO_PLAN","BILLING_PAST_DUE","BILLING_RUNAWAY_CAP","BILLING_SEAT_LIMIT","CHECKOUT_FAILED","CONFIRMATION_REQUIRED","CREATE_FAILED","CREDIT_LIMIT","DELETE_FAILED","DUPLICATE_INVITE","EMAIL_DELIVERY_FAILED","EMAIL_FAILED","EMAIL_MISMATCH","EMAIL_RATE_LIMITED","EMAIL_REASON_NOT_ELIGIBLE","EMPTY_STREAM","EMPTY_PATCH","ENV_VAR_CONFLICT","ENV_VAR_RESERVED","EXTENSION_INACTIVE","FORBIDDEN","HANDLE_TAKEN","IMAGE_GENERATION_FAILED","IMAGE_GENERATION_UNCONFIGURED","INTERNAL_ERROR","INVALID_FILE","INVALID_PRIMARY_CHANNEL","UNKNOWN_ROUTINE_CHANNEL","INVITE_CONFLICT","INVITE_EXPIRED","INVITE_INVALID","INVITE_LIMIT","MCP_NOT_AVAILABLE","MCP_NOT_CONFIGURED","MEDIA_NOT_FOUND","MEDIA_SERVER_UNAVAILABLE","MEDIA_UPLOAD_FAILED","MEMORY_NOT_FOUND","MISSING_IDEMPOTENCY_KEY","NETWORK_ERROR","NO_WORKSPACE","NOT_A_MEMBER","NOT_AUTHORIZED","NOT_FOUND","ORG_NOT_FOUND","OVERAGE_CAP","OWNER_LOCK","OWNER_TURN_REQUIRED","PAIRING_VERIFY_FAILED","PAYMENT_FAILED","PHONE_COUNTRY_CLOSED","PLAN_LIMIT","PROVISIONER_UNAVAILABLE","RATE_LIMIT","RATE_LIMITED","REBUILD_FAILED","RESTART_FAILED","RUNTIME_UNPROVEN","SEND_FAILED","STOP_FAILED","STREAM_DISCONNECT","STREAM_TIMEOUT","STRIPE_LOAD","TIMEOUT","TOKEN_ERROR","TOOL_PROTOCOL","TRIAL_ENDED","TURN_ACTIVE","UPLOAD_FAILED","VALIDATION_ERROR","VOICE_BUSY","VOICE_UNAVAILABLE","WAKE_FAILED"],W2=c.enum(q6),G6=9900,C2=`$${G6/100}/month`,J6=c.enum(["account","error"]),Y6=["billing_no_plan","billing_seat_limit","billing_past_due","billing_runaway_cap","billing_budget_reached","billing_demo_spent","bot_deleted","computer_not_deployed","computer_boot_failed","computer_unreachable","computer_wake_timeout","provisioner_unavailable","stream_timeout","stream_disconnect","empty_stream","tool_protocol","rate_limit"],X6=c.enum(Y6),q2=c.object({bucket:J6,code:X6,title:c.string(),help:c.string().optional(),actionLabel:c.string(),actionUrl:c.string()}),E7={billing_no_plan:{bucket:"account",title:"Billing needed",help:`Add a payment method to turn live replies back on. Plans start at ${C2} per active assistant, cancel anytime.`,actionLabel:"Open billing",oneLine:`The workspace needs a payment method before this assistant can reply; plans start at ${C2} per active assistant.`},billing_seat_limit:{bucket:"account",title:"Active assistant limit reached",help:"Your active assistants are all in use. Put one assistant to sleep or ask us to raise the ceiling.",actionLabel:"Open billing",oneLine:"The workspace has no unused active-assistant slots; one assistant must sleep or the limit must be raised."},billing_past_due:{bucket:"account",title:"Assistants paused",help:"Payment is overdue. Fix it and we\u2019ll bring your assistants back online.",actionLabel:"Fix payment",oneLine:"The workspace payment is overdue; its owner must fix it before assistants come back online."},billing_runaway_cap:{bucket:"account",title:"Usage limit reached",help:"Your workspace reached its usage limit. Review billing or contact support to keep your assistant running.",actionLabel:"Contact support",oneLine:"The workspace reached its usage limit; its owner can review billing or contact support."},billing_budget_reached:{bucket:"account",title:"Not enough credits",help:"Your workspace needs more included credits for another reply. They refill at the next billing period.",actionLabel:"Review billing",oneLine:"The workspace needs more included credits; they refill at the next billing period."},billing_demo_spent:{bucket:"account",title:"Weekly usage used up",help:"Your bot has used this week's included usage. It refills next week.",actionLabel:"",oneLine:"This bot has used this week's included usage; it refills next week."},bot_deleted:{bucket:"error",title:"Assistant deleted",help:"This chat is still here, but the assistant can no longer reply.",actionLabel:"",oneLine:"This assistant was deleted. The chat history remains, but it can no longer reply."},computer_not_deployed:{bucket:"error",title:"Assistant asleep",help:"Open the assistant profile to wake it up before chatting.",actionLabel:"Open assistant",oneLine:"This assistant needs to wake up before it can reply."},computer_boot_failed:{bucket:"error",title:"Couldn't wake up",help:"Open the assistant profile to restart it or check what failed.",actionLabel:"Open assistant",oneLine:"This assistant tried to wake up but hit an error."},computer_unreachable:{bucket:"error",title:"Not responding",help:"Open the assistant profile to check status or restart it.",actionLabel:"Open assistant",oneLine:"This assistant is not responding right now; its owner can check its status."},computer_wake_timeout:{bucket:"error",title:"Still starting",help:"It is still starting up. Send your message again in a minute, or open the assistant to see what it is doing.",actionLabel:"Open assistant",oneLine:"This assistant is still starting up; send your message again in a minute."},provisioner_unavailable:{bucket:"error",title:"Couldn't reach computer",help:"PageLines couldn't reach your assistant's computer for a moment. Send your message again.",actionLabel:"Try again",oneLine:"PageLines couldn't reach this assistant's computer for a moment; try the message again."},stream_timeout:{bucket:"error",title:"Reply too slow",help:"Your assistant took too long to start replying. Try your message again.",actionLabel:"Try again",oneLine:"This assistant took too long to start replying; try the message again."},stream_disconnect:{bucket:"error",title:"Connection lost",help:"The connection dropped while your assistant was replying. Send your message again to retry.",actionLabel:"Try again",oneLine:"The connection dropped while this assistant was replying; try the message again."},empty_stream:{bucket:"error",title:"Empty reply",help:"Your assistant could not generate a reply. Try your message again.",actionLabel:"Try again",oneLine:"This assistant did not return a reply; try the message again."},tool_protocol:{bucket:"error",title:"Tool call failed",help:"Your assistant tried to use a tool in a format PageLines could not run. Try the message again.",actionLabel:"Try again",oneLine:"This assistant tried to use a tool in a format PageLines could not run; try the message again."},rate_limit:{bucket:"error",title:"Slow down",help:"Too many messages at once. Wait a moment, then send your message again.",actionLabel:"Try again",oneLine:"Too many messages arrived at once; wait a moment and try again."}},G2=c.enum(["unknown","stopped","starting","running","unreachable","error"]),Q6=c.enum(["wake","restart","rebuild","config_apply","setup"]),e3=c.enum(["running","coalesced","failed"]),t3=c.object({kind:Q6,status:e3,startedAt:c.string().datetime(),detail:c.string().optional()}).strict(),J2=c.object({lifecycle:G2,changedAt:c.string().datetime().optional(),detail:c.string().optional(),blocker:q2.optional(),operation:t3.optional()}).strict(),Kl=Object.freeze({lifecycle:"unknown"}),r3={running:"green",starting:"amber",unreachable:"red",error:"red",stopped:"grey",unknown:"grey"},n3=c.enum(["awake","asleep","changing","stuck"]),Y2={awake:"Awake",asleep:"Asleep",changing:"Changing",stuck:"Needs attention"};i3={running:"Online",starting:"Waking up",unreachable:"Unreachable",error:"Error",stopped:"Asleep",unknown:"Checking"},o3={wake:"Waking up",restart:"Restarting",rebuild:"Restarting",config_apply:"Applying config",setup:"Setting up"};T7=c.enum(["wake","sleep","restart","rebuild"]);l3=c.object({key:c.string().optional(),id:c.string().optional(),label:c.string().optional(),srLabel:c.string().optional(),subLabel:c.string().optional(),value:c.union([c.string(),c.number()]).optional(),description:c.string().optional(),state:n3.optional(),count:c.number().optional(),className:c.string().optional(),media:Bt.optional(),subMedia:Bt.optional(),cover:Bt.optional(),icon:Bt.optional(),iconAfter:Bt.optional(),subIcon:c.string().optional(),href:c.string().optional(),target:c.enum(["_self","_blank"]).optional(),onClick:c.any().optional(),theme:c.enum(["primary","default"]).optional(),isActive:c.boolean().optional(),isDisabled:c.boolean().optional(),isHidden:c.boolean().optional(),priority:c.number().optional(),testId:c.string().optional(),items:c.array(c.any()).optional(),badges:c.array(K0).optional(),meta:c.array(K0).optional(),menuItems:c.array(c.any()).optional()}),N7=c.object({title:c.string().optional(),description:c.string().optional(),items:c.array(l3).optional()}),Q2=c.string().trim().transform(e=>{if(!e.includes("/"))return e;try{let t=new URL(/^https?:\/\//i.test(e)?e:`https://${e}`),[n,i]=t.pathname.split("/").filter(Boolean),r=t.hostname.toLowerCase();if((r==="linkedin.com"||r.endsWith(".linkedin.com"))&&n?.toLowerCase()==="in"&&i)return i}catch{}return e}).pipe(c.string().min(3).max(100).regex(/^[a-zA-Z0-9-]+$/,"Use a LinkedIn username or profile URL")),c3=c.string().trim().transform((e,t)=>{try{let n=new URL(/^https?:\/\//i.test(e)?e:`https://${e}`),i=n.hostname.toLowerCase().replace(/^www\./,""),r=n.pathname.split("/").filter(Boolean)[0];if(!r||!["x.com","twitter.com","facebook.com"].includes(i))throw new Error("unsupported profile");return i==="twitter.com"?`https://x.com/${r}`:`https://${i}/${r}`}catch{return t.addIssue({code:"custom",message:"Use a LinkedIn username or an X or Facebook profile URL"}),c.NEVER}}),J0=c.string().trim().toLowerCase().pipe(c.email()),u3=c.enum(["member","pending"]),d3=c.object({lastBotId:c.string().nullable().optional(),userId:c.string(),email:c.string().optional(),handle:c.string().optional(),fullName:c.string().optional(),bio:c.string().optional(),linkedinUsername:Q2.optional(),avatarId:c.string().optional(),avatar:Bt.optional(),isEmailVerified:c.boolean().optional(),primaryOrgId:c.string().optional(),lastActiveOrgId:c.string().optional(),onboarding:c.any().optional(),location:c.string().optional(),geo:c.any().optional(),systemRole:c.string().optional(),status:c.string().optional(),lastSeenAt:c.string().optional(),admittedAt:c.string().optional(),access:u3.optional(),isMember:c.boolean().optional(),createdAt:c.string().optional(),updatedAt:c.string().optional(),onboarded:c.boolean().optional()}),z7=c.object({email:J0}),A7=c.object({email:J0,code:c.string().min(6,"Verification code is required"),timezone:c.string().max(64).optional(),phone:c.string().trim().min(7).max(30).optional(),phoneProof:c.string().max(300).optional()}),p3=c.object({phone:c.string().trim().min(7).max(30),purpose:c.enum(["apply","sign_in"]).optional(),invite:c.string().trim().max(64).optional()}),O7=c.object({codeSent:c.boolean()}),D7=p3.extend({code:c.string().trim().min(4).max(10)}),P7=c.object({phoneProof:c.string()}),R7=c.object({phone:c.string().trim().min(7).max(30),phoneProof:c.string().max(300),timezone:c.string().max(64).optional(),join:c.object({inviteCode:c.string().trim().max(64),name:c.string().trim().min(1,"Add your name").max(120),email:c.string().trim().toLowerCase().email("Enter your email").max(255),city:c.string().trim().min(1,"Add your city").max(120),placeId:c.string().max(16).optional()}).optional()}),U7=c.object({newEmail:J0}),j7=c.object({credential:c.string().optional(),code:c.string().optional(),timezone:c.string().max(64).optional(),source:c.enum(["web","ios"]).optional()}).refine(e=>e.credential||e.code,{message:"Either credential or code must be provided"}),M7=c.object({identityToken:c.string().min(1),fullName:c.string().optional(),timezone:c.string().max(64).optional()}),eI=c.object({orgId:c.string().optional(),handle:c.string().optional(),name:c.string().optional(),email:c.string().nullable().optional(),website:c.string().url().nullable().optional(),summary:c.string().nullable().optional(),avatarId:c.string().nullable().optional(),avatar:Bt.optional(),coverId:c.string().nullable().optional(),cover:Bt.optional(),accounts:O6.nullable().optional(),ownerId:c.string().optional(),isPersonal:c.boolean().optional(),stripeCustomerIdTest:c.string().nullable().optional(),stripeCustomerIdLive:c.string().nullable().optional(),maxUsers:c.number().optional(),timezone:c.string().nullable().optional(),apiKey:c.string().nullable().optional(),syncedPlan:c.string().nullable().optional(),syncedBillingStatus:c.string().nullable().optional(),firstPaidAt:c.string().nullable().optional(),entitlementDeleteAt:c.string().nullable().optional(),billingLastSyncedAt:c.string().nullable().optional(),syncedPeriodStart:c.string().nullable().optional(),syncedPeriodEnd:c.string().nullable().optional(),onboarding:c.any().optional(),status:c.string().optional(),createdAt:c.string().optional(),updatedAt:c.string().optional()}),m3=c.object({completedAt:c.string().datetime().optional(),setupBy:c.string().optional(),billingSetup:c.boolean().optional(),teamInvitesSetup:c.boolean().optional(),brandingSetup:c.boolean().optional(),domainsSetup:c.boolean().optional()}),f3=c.object({membershipId:c.string(),orgId:c.string(),name:c.string(),handle:c.string(),avatarId:c.string().optional(),avatar:Bt.optional(),coverId:c.string().optional(),cover:Bt.optional(),role:c.enum(["owner","admin","member","observer"]),inviterName:c.string().optional(),memberCount:c.number().optional(),hasComputer:c.boolean().optional(),computerCount:c.number().optional(),joinedAt:c.string().datetime(),onboarding:m3.optional()}),h3=d3.extend({orgs:c.array(f3).optional()}),z2=[["#6366f1","#8b5cf6"],["#3b82f6","#06b6d4"],["#10b981","#34d399"],["#f59e0b","#f97316"],["#ef4444","#f97316"],["#ec4899","#8b5cf6"],["#14b8a6","#3b82f6"],["#8b5cf6","#ec4899"]];w3=["[SILENT]","SILENT","NO_REPLY","NO REPLY","NO-OP","NOOP","NO_OP","NO OP","[NO-OP]","[NOOP]","[NO_OP]","[NO OP]","HEARTBEAT_OK"],k3=new Set(w3);tI={wake:300*1e3,bootGrace:420*1e3,provision:600*1e3,firstStart:45*1e3,stop:30*1e3},A2={AUTH_ACCOUNT_NOT_FOUND:"Account not found. Ask your workspace admin for an invite.",AUTH_INVALID:"Your session has expired. Sign in again to continue.",AUTH_LOCKED_OUT:"Too many failed attempts. Request a new code to try again.",AUTH_INVALID_CODE:"That code didn't match. Double-check the email and try again.",AUTH_INVALID_HANDOFF:"This link has expired. Open the dashboard from the app again.",AUTH_DISPOSABLE_EMAIL:"Please use your work email address.",AUTH_RATE_LIMITED:"Too many requests. Wait a minute and try again.",AUTH_PROVIDER_FAILED:"Sign-in failed. Try again or use email instead.",AUTH_PROVIDER_NOT_CONFIGURED:"That sign-in method isn't available right now.",ADMISSION_REQUIRED:"PageLines is invite-only. Request access to create your bot.",PLAN_LIMIT:"Your active computers are all in use. Put one computer to sleep or ask us to raise the ceiling.",CREDIT_LIMIT:"Your workspace reached its usage limit. Review billing or contact support to keep your assistant running.",STRIPE_LOAD:"Couldn't open checkout. Try again \u2014 if it persists, contact support.",CHECKOUT_FAILED:"Couldn't start checkout. Try again in a moment.",PAYMENT_FAILED:"Your payment couldn't go through. Update your card to continue.",WAKE_FAILED:"Your assistant didn't wake up. Try again in a moment.",VOICE_BUSY:"Your assistant is on another call. Try again in a moment.",VOICE_UNAVAILABLE:"Voice isn't available right now. Try again in a moment.",STOP_FAILED:"Couldn't put your assistant to sleep. Try again.",RESTART_FAILED:"Restart didn't finish. Try again \u2014 if it persists, rebuild.",REBUILD_FAILED:"Restart didn't finish. Try again or contact support.",CREATE_FAILED:"Couldn't create your assistant. Try again in a moment.",DELETE_FAILED:"Couldn't delete your assistant. Try again \u2014 your data is safe.",BOT_NOT_FOUND:"We couldn't find that assistant.",COMPUTER_NOT_FOUND:"We couldn't find that computer.",COMPUTER_INACTIVE:"This computer is off. Turn it on to start it.",ATTACHMENT_TYPE_UNSUPPORTED:"Your assistant can't read this file type yet.",ROUTINE_CHANNEL_UNAVAILABLE:"Your delivery channel isn't reachable. Pair it again or choose PageLines Messenger.",ROUTINE_PURPOSE_REQUIRED:"Say what the scheduled message or work should contain.",NETWORK_ERROR:"Network issue. Check your connection and try again.",TIMEOUT:"The request took too long. Try again in a moment.",FORBIDDEN:"You don't have access to this.",RATE_LIMITED:"Too many requests. Wait a moment and try again."};rI=c.enum(["active","stopped"]),$3=c.enum(["notFound","busy","rateLimited","timeout","invalidConfig","transient","fatal"]),F7=c.object({ok:c.literal(!1),error:c.string(),code:W2.optional(),issue:q2.optional(),providerErrorKind:$3.optional()}),S3=c.object({kind:c.enum(["icon","favicon","service"]),icon:c.string().min(1).optional(),domain:c.string().min(1).optional(),serviceKey:c.string().min(1).optional()}).strict(),nI=c.object({activityId:c.string().min(1),turnId:c.string().min(1),status:c.enum(["started","completed","failed"]),label:c.string().trim().min(1),kind:c.enum(["search","file","image","service","routine","handoff","other"]),toolName:c.string().min(1).optional(),serviceKey:c.string().min(1).optional(),startedAt:c.string().datetime().optional(),endedAt:c.string().datetime().optional(),durationMs:c.number().int().nonnegative().optional(),note:c.string().trim().min(1).optional(),visual:S3.optional()}).strict(),I3=nI.extend({status:c.enum(["completed","failed"])}),Yn=c.string().min(1).max(64).refine(e=>{try{return new Intl.DateTimeFormat("en-US",{timeZone:e}).format(new Date(0)),!0}catch{return!1}},"Invalid IANA timezone");oI=G0,E3=c.object({kind:c.literal("inline"),offset:c.number().int().nonnegative()}),aI=c.object({type:oI,src:c.url(),filename:c.string().min(1),mimeType:c.string().min(1),mediaId:c.string().min(1).optional(),size:c.number().int().nonnegative().optional(),width:c.number().int().positive().optional(),height:c.number().int().positive().optional(),duration:c.number().nonnegative().optional(),text:c.string().optional(),placement:E3.optional()}),sI=c.object({ref:c.string().min(1).max(256)}).strict(),lI=c.enum(["handled","dismissed","deferred"]),cI=c.iso.datetime();T3=sI.extend({disposition:lI.optional(),revisitAt:cI.optional()}).superRefine(uI),W7=sI.extend({disposition:lI,revisitAt:cI.optional()}).superRefine(uI),N3=c.object({turnId:c.string().min(1).optional(),turnOutcome:c.enum(["failed","stopped"]).optional(),attachments:c.array(aI).optional(),toolActivities:c.array(I3).optional(),issue:c.object({code:c.string(),bucket:c.enum(["account","error"]),actionLabel:c.string(),actionUrl:c.string(),help:c.string().optional()}).optional(),notification:c.object({push:c.boolean().optional(),excludeUserId:c.string().min(1).optional()}).optional(),routine:c.object({run:c.object({routineRunId:c.string(),name:c.string().optional(),sourceKind:c.enum(["webhook","schedule","manual","heartbeat"]),sourceLabel:c.string().optional(),deliveryId:c.string().optional(),status:c.enum(["received","forwarded","owner_notified","needs_approval","completed","failed","dropped"])}).catchall(c.unknown())}).catchall(c.unknown()).optional(),voiceDelegated:c.literal(!0).optional(),ownerHandoff:c.literal(!0).optional(),attention:c.array(T3).max(20).optional()}).catchall(c.unknown()),C3=c.object({messageId:c.string().min(1),conversationId:c.string().min(1),role:c.enum(["user","assistant","system"]),authorParticipantId:c.string().nullable(),systemKind:c.string().nullable(),content:c.string(),sequence:c.string().min(1),clientNonce:c.string().nullable().optional(),metadata:N3.nullable().optional(),status:c.string().nullable().optional(),createdAt:c.string(),updatedAt:c.string()}),Y0=c.object({type:oI,mediaId:c.string().min(1)}),q7=c.object({conversationId:c.string().min(1),content:c.string().max(1e4).default(""),clientNonce:c.string().max(64).optional(),attachments:c.array(Y0).max(10).optional(),channel:c.enum(["ios","dashboard"]).optional(),actionUrls:c.object({billing:c.string().max(500),bot:c.string().max(500)}).optional(),viewerTimezone:Yn.optional()}).refine(e=>e.content.trim().length>0||(e.attachments?.length??0)>0,{path:["content"],message:"Message or attachment required"}),dI=c.object({type:c.enum(["user","bot"]),id:c.string().min(1)}).strict();G7=c.object({orgId:c.string().min(1),participants:c.array(dI).min(1).max(20)}).strict().superRefine(pI),J7=c.object({orgId:c.string().min(1),participants:c.array(dI).min(1).max(20)}).strict().superRefine((e,t)=>{pI(e,t),e.participants.some(n=>n.type==="bot")||t.addIssue({code:"custom",path:["participants"],message:"New sessions require at least one agent participant."})}),Y7=c.object({category:c.string().min(1).max(30).optional(),reason:c.string().max(2e3).optional()}).strict(),X7=c.object({shareId:c.string(),url:c.string(),createdAt:c.string()}),Q7=c.object({shareId:c.string(),botName:c.string(),botAvatarUrl:c.string().nullable(),prompt:c.string().nullable(),content:c.string(),createdAt:c.string()}),z3=c.enum(["1:1","4:3","3:4","16:9","9:16"]),A3=c.enum(["1K","2K","4K"]),eZ=c.object({prompt:c.string().trim().min(1).max(4e3),aspectRatio:z3.default("1:1"),outputFormat:c.enum(["png","jpeg","webp"]).default("webp"),resolution:A3.default("2K"),style:c.string().trim().max(200).optional(),altText:c.string().trim().max(500).optional(),referenceMediaIds:c.array(c.string().min(1)).max(4).optional()}).strict(),tZ=c.object({mediaId:c.string().min(1),src:c.url(),filename:c.string().min(1),mimeType:c.string().min(1),width:c.number().int().positive().optional(),height:c.number().int().positive().optional(),provider:c.string().min(1).optional(),providerRequestId:c.string().min(1).optional(),media:c.string().startsWith("MEDIA:"),attachment:aI.extend({type:c.literal("image")})}),nZ=c.object({identityToken:c.string().min(1),fullName:c.string().optional()}),O3=c.object({redirect:c.string(),redirectReason:c.string(),isNew:c.boolean(),deviceId:c.string()}),iZ=c.object({ok:c.literal(!0),data:O3,token:c.string()}),oZ=c.object({path:c.string().startsWith("/","path must be a relative dashboard path").refine(C6,"path must be a relative dashboard path")}),D3=c.object({url:c.string()}),aZ=c.object({ok:c.literal(!0),data:D3}),sZ=c.object({token:c.string().min(1)}),P3=c.object({redirect:c.string(),redirectReason:c.string(),deviceId:c.string()}),lZ=c.object({ok:c.literal(!0),data:P3,token:c.string()}),mI=B2,R3=G0,W0=c.object({mediaId:c.string(),src:c.string(),alt:c.string().nullable().optional(),filename:c.string().optional(),displayName:c.string().nullable().optional(),mimeType:c.string().optional(),mediaType:R3.optional(),size:c.number().optional(),width:c.number().nullable().optional(),height:c.number().nullable().optional(),duration:c.number().nullable().optional(),context:mI.nullable().optional(),blurhash:c.string().nullable().optional(),quality:c.string().optional(),status:c.string().optional(),userId:c.string().optional(),orgId:c.string().optional(),botId:c.string().nullable().optional(),createdAt:c.string().optional(),updatedAt:c.string().optional()}),pZ=c.object({file:c.string().describe("Binary file. multipart/form-data field \u2014 the actual upload. The server validates type + size and normalizes image uploads before storage. Audio/video/document uploads use the same uploader and are classified by MIME type."),context:mI.optional().default("general"),botId:c.string().optional(),orgId:c.string().optional(),duration:c.number().optional()}),fI=c.object({viewerTimezone:Yn.optional(),location:c.object({label:c.string().max(500),city:c.string().optional(),region:c.string().optional(),countryCode:c.string().optional(),timezone:c.string().optional(),source:c.literal("geoip"),precision:c.enum(["city","region","country"]),confidence:c.enum(["medium","low"]),vpnOrDatacenter:c.enum(["likely","unknown"])}).optional()}),U3=c.object({status:c.enum(["available","unavailable"]),user:c.string().max(16e3).optional(),memory:c.string().max(16e3).optional(),agents:c.string().max(4e3).optional()}).strict(),gZ=c.object({bot:c.object({id:c.string(),name:c.string(),title:c.string().nullable().optional(),timezone:Yn}),scope:c.enum(["private","org","public"]),channel:c.string().max(120),currentTime:c.iso.datetime(),scopePrompt:c.string().optional(),observations:fI.optional(),lastObservedTimezone:Yn.optional(),lean:U3.optional(),servicesNeedingSetup:c.array(c.object({name:c.string(),state:c.string()})).optional()}),vZ=c.object({reason:c.enum(["idle-timeout","session-cap","unavailable"])}).strict(),hI=c.enum(["woman","man"]),j3=[{key:"ava",gender:"woman",accent:"American",character:"Warm, patient and understanding",isDefault:!0},{key:"hope",gender:"woman",accent:"American",character:"Soft-spoken, smooth and kind"},{key:"lauren",gender:"woman",accent:"American",character:"Friendly, comforting and soft"},{key:"amy",gender:"woman",accent:"American",character:"Natural and sweet"},{key:"eve",gender:"woman",accent:"American",character:"Authentic, energetic and happy"},{key:"jessica",gender:"woman",accent:"British",character:"Smooth, articulate and warm"},{key:"adam",gender:"man",accent:"American",character:"Engaging, friendly and bright",isDefault:!0},{key:"jon",gender:"man",accent:"American",character:"Relaxed, deep and approachable"},{key:"joe",gender:"man",accent:"British",character:"Reflective and thoughtful"},{key:"peter",gender:"man",accent:"Australian",character:"Deep, warm and direct"}],gI=c.enum(j3.map(e=>e.key)),bZ=c.object({conversationId:c.string().min(1),viewerTimezone:Yn.optional()}).strict(),yZ=c.object({conversationId:c.string().min(1),botId:c.string().min(1),personaName:c.string().min(1),personaTitle:c.string().max(255).nullable().optional(),gender:hI,voiceKey:gI.nullable(),sessionScope:c.enum(["private","org","public"]),observations:fI.optional(),threadSummary:c.string(),capabilities:c.array(c.object({name:c.string().min(1),description:c.string().min(1)})).optional(),maxDurationSeconds:c.number().int().positive().max(3600).optional(),expiresAt:c.iso.datetime()}),M3=c.literal("livekit"),wZ=c.object({name:c.enum(["voice.ready","voice.first_playback","voice.failed"]),client:c.enum(["web","ios"]),botId:c.string().min(1).max(64).optional(),conversationId:c.string().min(1).max(64).optional(),provider:M3.optional(),durationMs:c.number().int().min(0).max(36e5),phase:c.enum(["idle","minting","connecting","live","ended"]).optional(),code:c.string().min(1).max(64).optional(),detail:c.string().min(1).max(300).optional(),appVersion:c.string().min(1).max(32).optional(),appBuild:c.string().min(1).max(32).optional()}).strict(),kZ=c.object({provider:c.literal("livekit"),url:c.string().min(1),token:c.string().min(1),room:c.string().min(1)}).strict(),L3=c.enum(["identity","working-style","complete"]),V3=c.string().min(1).max(50).regex(/^[a-z0-9]+(?:-[a-z0-9]+)*$/),Zl=c.object({botId:c.string().min(1),computerId:c.string().min(1),handle:c.string().min(2).max(50),name:c.string().min(1).max(100),emoji:c.string().max(8).nullable().optional(),title:c.string().max(120).nullable().optional(),summary:c.string().max(500).nullable().optional(),avatarId:c.string().nullable().optional(),coverId:c.string().nullable().optional(),avatar:Bt.optional(),cover:Bt.optional(),email:c.email().nullable().optional(),website:c.url().nullable().optional(),accounts:c.array(c.object({platform:c.enum(["linkedin","x","facebook","tiktok","youtube","github","instagram","threads","email","phone","website"]),handle:c.string()})).nullable().optional(),gender:hI.optional(),voiceKey:gI.nullable().optional(),isPrimary:c.boolean(),collaborationEnabled:c.boolean(),publicChatEnabled:c.boolean(),status:c.enum(["active","deleted"]),onboardingStage:L3.nullable().optional(),onboardedAt:c.string().nullable().optional(),routinePrimaryChannel:V3.optional(),firstMessageAt:c.string().nullable().optional(),firstValueAt:c.string().nullable().optional(),lastMessageAt:c.string().nullable().optional(),createdAt:c.string(),updatedAt:c.string()}).strict(),X0=Zl.pick({name:!0,emoji:!0,title:!0,summary:!0,gender:!0,voiceKey:!0}).extend({handle:Zl.shape.handle.optional(),avatarPreset:c.string().min(1).max(64).optional(),avatarMediaId:c.string().optional()}).strict(),xZ=X0.extend({computerId:c.string().min(1)}).strict(),_Z=Zl.pick({name:!0,handle:!0,emoji:!0,title:!0,summary:!0,email:!0,website:!0,gender:!0,voiceKey:!0,routinePrimaryChannel:!0,collaborationEnabled:!0,publicChatEnabled:!0}).partial().extend({avatarMediaId:c.string().nullable().optional(),coverMediaId:c.string().nullable().optional()}).strict(),vI=c.enum(["essential","pro","business"]),bp=J2.partial().extend({computerId:c.string().min(1),ownerId:c.string().min(1),owner:c.object({userId:c.string(),fullName:c.string().optional(),avatar:W0.optional()}).optional(),orgId:c.string().min(1),name:c.string().min(1).max(100),model:c.string().nullable(),timezone:Yn,billingTier:vI,desiredStatus:rI.nullable(),status:c.enum(["active","deleted"]),lastActiveAt:c.string().nullable().optional(),createdAt:c.string(),updatedAt:c.string()}).strict(),$Z=c.object({orgId:c.string().min(1),name:bp.shape.name.optional(),timezone:Yn.optional(),primaryBot:X0}).strict(),SZ=bp.pick({name:!0,model:!0,timezone:!0}).partial().strict(),F3=c.enum(["none","active_assistant"]),B3=c.enum(["none","active","trial","canceling","past_due","paused"]),Z3=c.object({brand:c.string(),last4:c.string(),expMonth:c.number(),expYear:c.number()}),H3=c.object({date:c.string(),amount:c.number(),status:c.string(),invoicePdf:c.string().optional()}),K3=c.object({graceEndsAt:c.string().optional(),suspended:c.boolean(),url:c.string().optional()}),IZ=c.object({plan:F3,status:B3,price:c.number(),tierRates:c.record(c.string(),c.number()).optional(),maxComputers:c.number(),activeComputers:c.number(),workspaceTier:vI.exclude(["essential"]).optional(),upcomingAmountDue:c.number().optional(),upcomingDueDate:c.string().optional(),nextBillDate:c.string().optional(),cancelAtPeriodEnd:c.boolean().optional(),cancelAt:c.string().optional(),trialEnd:c.string().optional(),trialDaysRemaining:c.number().optional(),paymentMethod:Z3.optional(),paymentRecovery:K3.optional(),invoices:c.array(H3),stripeError:c.string().optional()}),W3=c.enum(["demo_computer_exists","subscription_required","plan_limit"]),EZ=c.object({canCreate:c.boolean(),activeComputers:c.number().int().nonnegative(),computerLimit:c.number().int().nonnegative(),isDemo:c.boolean(),reason:W3.optional()}),TZ=c.object({orgId:c.string(),computerName:c.string().optional(),runtime:c.string().optional()}),q3=J2,G3=c.object({code:W2,message:c.string(),bucket:c.enum(["account","error"]),actionLabel:c.string().optional(),actionUrl:c.string().optional(),help:c.string().optional()}),J3=c.discriminatedUnion("event",[c.object({event:c.literal("status"),data:q3}),c.object({event:c.literal("message"),data:c.object({message:C3})}),c.object({event:c.literal("message_delta"),data:c.object({delta:c.string(),turnId:c.string(),messageId:c.string().optional(),role:c.enum(["assistant","system"]).optional()})}),c.object({event:c.literal("working_state"),data:c.object({description:c.string(),turnId:c.string().optional()})}),c.object({event:c.literal("tool_activity"),data:nI}),c.object({event:c.literal("working_end"),data:c.object({turnId:c.string().optional()}).strict()}),c.object({event:c.literal("stream_end"),data:c.object({turnId:c.string().optional()}).strict()}),c.object({event:c.literal("error"),data:G3})]);tD=c.object({label:c.string().trim().min(1).max(40),reply:c.string().trim().min(1).max(500),style:c.enum(["primary","default","destructive"]).optional()}).strip(),rD=c.object({version:c.literal(1),title:c.string().trim().min(1).max(200),body:c.string().trim().min(1).max(8e3).optional(),actions:c.array(tD).min(1).max(3).optional()}).strip();nD=c.string().trim().min(1).max(240),q0=c.string().trim().min(1).max(800),Xn=c.string().trim().min(1).max(80).regex(/^[A-Za-z0-9_.:-]+$/),Fa=c.string().trim().min(1).max(120),iD=c.union([c.string().max(500),c.number().finite(),c.boolean(),c.null()]),kI=c.record(Xn,iD),oD=c.enum(["compact","currency","duration","integer","percent","raw"]),aD=c.object({title:nD,description:q0.optional(),footer:q0.optional()}).strip(),xI=c.object({dataKey:Xn,label:Fa.optional(),axisLabel:Fa.optional(),valueFormat:oD.optional(),valuePrefix:c.string().trim().max(12).optional(),valueSuffix:c.string().trim().max(12).optional()}).strip(),sD=c.object({kind:c.literal("linear"),dataKey:Xn,label:Fa.optional()}).strip(),ey=c.object({version:c.literal(1),meta:aD,fallbackMarkdown:c.string().trim().min(1).max(4e3)}).strip();cD=ey.extend({visualType:c.literal("chart"),chartType:c.enum(["bar","line","scatter"]),xKey:Xn,xAxisLabel:Fa.optional(),series:c.array(xI).min(1).max(6),data:c.array(kI).min(1).max(120),layout:c.enum(["horizontal","vertical"]).optional(),stacking:c.enum(["grouped","stacked"]).optional(),trendLine:sD.optional()}).strip().superRefine((e,t)=>{e.stacking&&e.chartType!=="bar"&&t.addIssue({code:"custom",path:["stacking"],message:"Stacking is only supported for bar charts"}),e.trendLine&&e.chartType!=="line"&&e.chartType!=="scatter"&&t.addIssue({code:"custom",path:["trendLine"],message:"Trend lines are only supported for line and scatter charts"}),_I(e.data,[{path:["xKey"],value:e.xKey},...e.series.map((n,i)=>({path:["series",i,"dataKey"],value:n.dataKey})),...e.trendLine?[{path:["trendLine","dataKey"],value:e.trendLine.dataKey}]:[]],t),$I(e.data,[...e.series.map((n,i)=>({path:["series",i,"dataKey"],value:n.dataKey})),...e.trendLine?[{path:["trendLine","dataKey"],value:e.trendLine.dataKey}]:[]],t)}),uD=ey.extend({visualType:c.literal("chart"),chartType:c.literal("pie"),nameKey:Xn,valueKey:Xn,series:c.array(xI).max(1).optional(),data:c.array(kI).min(1).max(16)}).strip().superRefine((e,t)=>{_I(e.data,[{path:["nameKey"],value:e.nameKey},{path:["valueKey"],value:e.valueKey},...(e.series??[]).map((n,i)=>({path:["series",i,"dataKey"],value:n.dataKey}))],t),$I(e.data,[{path:["valueKey"],value:e.valueKey,nonnegative:!0}],t)}),dD=c.discriminatedUnion("chartType",[cD,uD]),pD=c.object({id:Xn,label:Fa,detail:q0.optional(),kind:c.enum(["actor","agent","decision","event","input","output","system","task"]).optional()}).strip(),mD=c.object({from:Xn,to:Xn,label:Fa.optional()}).strip(),fD=ey.extend({visualType:c.literal("diagram"),diagramType:c.enum(["flow","org","sequence","state"]),layout:c.enum(["auto","left-to-right","radial","top-to-bottom"]).default("auto"),nodes:c.array(pD).min(1).max(24),edges:c.array(mD).max(48)}).strip().superRefine((e,t)=>{let n=new Set(e.nodes.map(i=>i.id));for(let[i,r]of e.edges.entries())n.has(r.from)||t.addIssue({code:"custom",path:["edges",i,"from"],message:`Unknown node id "${r.from}"`}),n.has(r.to)||t.addIssue({code:"custom",path:["edges",i,"to"],message:`Unknown node id "${r.to}"`})}),O2=c.union([dD,fD]);II=c.object({conversationParticipantId:c.string().min(1),type:c.enum(["user","bot","anonymous"]),id:c.string(),role:c.enum(["owner","requester","member"]),status:c.enum(["active","left","deleted"]),displayName:c.string().optional(),handle:c.string().optional(),avatarUrl:c.string().optional()}).strict(),EI=c.object({messageId:c.string(),role:c.enum(["user","assistant","system"]),content:c.string(),sequence:c.string(),createdAt:c.string()}),OZ=c.object({conversationId:c.string(),orgId:c.string(),kind:c.enum(["direct","group"]),updatedAt:c.string(),viewerRole:c.enum(["owner","requester","member"]),participants:c.array(II),lastMessage:EI.nullable(),openingMessage:c.string().nullable(),unreadCount:c.number().int().nonnegative(),latestSequence:c.string().nullable()}),DZ=c.object({sequence:c.string().min(1)}),PZ=c.object({turnId:c.string().min(1).optional()}).strict(),RZ=c.object({cancelled:c.boolean(),cancelledTurnIds:c.array(c.string())}).strict(),UZ=c.object({conversationId:c.string(),messageId:c.string(),sequence:c.string(),snippet:c.string(),createdAt:c.string(),participants:c.array(II)}),jZ=c.object({conversationId:c.string(),lastMessage:EI.nullable(),unreadCount:c.number().int().nonnegative(),latestSequence:c.string().nullable()}),Zr=c.preprocess(e=>e===void 0?null:e,c.string().nullable()),wD=c.preprocess(e=>e===void 0?null:e,G2.nullable()),kD=c.preprocess(e=>e===void 0?null:e,rI.nullable()),xD=c.preprocess(e=>e===void 0?null:e,c.enum(["user","assistant","system"]).nullable()),D2=c.preprocess(e=>e===void 0?0:e,c.number()),_D=c.object({computerId:c.string(),handle:c.string(),name:c.string(),orgId:c.string(),orgName:Zr,orgHandle:Zr,ownerEmail:Zr,ownerName:Zr,state:wD,desiredStatus:kD,runtime:c.string(),imageVersion:Zr,lastHealthyAt:Zr,lastActiveAt:Zr,lastUserMessageAt:Zr,lastMessageAt:Zr,lastMessageRole:xD,lastMessageChannel:Zr,primaryChannel:Zr,totalMessages:D2,totalSessions:D2,error:Zr,appHandle:c.string(),hostAppExists:c.boolean(),plan:c.string(),billingStatus:c.string(),billingActive:c.boolean(),createdAt:c.string(),updatedAt:c.string()}),$D=c.object({running:c.number(),stopped:c.number(),error:c.number(),starting:c.number(),unknown:c.number(),total:c.number()}),LZ=c.object({computers:c.array(_D),summary:$D,orphanedApps:c.array(c.string()),dailyMessages30d:c.array(c.number().int()).optional(),hostAppCount:c.number().optional(),latestVersions:c.record(c.string(),c.string()).optional()}),SD=c.object({mediaId:c.string().optional(),src:c.string().optional(),alt:c.string().optional(),width:c.number().optional(),height:c.number().optional(),mimeType:c.string().optional(),mediaType:c.string().optional(),blurhash:c.string().optional()}),FZ=c.object({membershipId:c.string(),userId:c.string(),orgId:c.string(),email:c.string(),fullName:c.string().optional(),role:c.enum(["owner","admin","member","observer"]),status:c.enum(["active","suspended"]),joinedAt:c.string(),lastSeenAt:c.string().optional(),avatar:SD.optional()}),BZ=c.object({invitationId:c.string(),email:c.string(),role:c.enum(["admin","member"]),status:c.string(),expiresAt:c.string(),createdAt:c.string()}),ID=c.object({token:c.string(),email:c.string(),orgId:c.string(),orgName:c.string(),orgInitial:c.string(),inviterName:c.string().optional(),inviterEmail:c.string(),role:c.enum(["owner","admin","member","observer"]),status:c.enum(["pending","accepted","expired","revoked"]),expiresAt:c.string(),memberCount:c.number().optional()}),ZZ=c.object({email:c.string().email(),role:c.enum(["admin","member"]).optional(),message:c.string().max(500).optional()}).strict(),HZ=c.object({role:c.enum(["admin","member"])}).strict(),KZ=c.object({token:c.string().min(1)}).strict(),WZ=c.object({message:c.string()}),qZ=c.object({invitationId:c.string(),message:c.string()}),GZ=c.object({message:c.string(),membershipId:c.string(),orgId:c.string(),role:c.enum(["owner","admin","member","observer"])}),JZ=c.object({invite:ID.nullable()}),ED={};x6(ED,{zNotificationTelemetryAck:()=>zD,zNotificationTelemetryEvent:()=>CD,zRegisterDeviceRequest:()=>TD,zRegisterDeviceResponse:()=>ND});TD=c.object({deviceId:c.string().min(1).max(64),pushToken:c.string().min(1).max(200),alertsAllowed:c.boolean().optional(),appVersion:c.string().max(40).optional(),osVersion:c.string().max(40).optional(),model:c.string().max(80).optional()}),ND=c.object({deviceId:c.string().min(1).max(64)}),CD=c.object({deviceId:c.string().min(1).max(64),kind:c.string().min(1).max(30),action:c.enum(["displayed","tapped","dismissed"]),messageId:c.string().max(32).optional()}),zD=c.object({updated:c.boolean()}),QZ=eI.pick({orgId:!0,handle:!0,name:!0,email:!0,website:!0,avatarId:!0,coverId:!0,summary:!0,timezone:!0,isPersonal:!0,status:!0,updatedAt:!0}).extend({avatar:W0.nullable().optional(),cover:W0.nullable().optional()}),eH=c.object({name:c.string().min(1).max(255),handle:c.string().min(2).max(50).optional(),timezone:Yn.optional()}).strict(),tH=eI.pick({name:!0,email:!0,website:!0,summary:!0,timezone:!0}).extend({name:c.string().min(1).max(255).optional(),email:c.preprocess(e=>e===""?null:e,c.string().email().nullable()).optional(),timezone:Yn.optional(),avatarMediaId:c.string().nullable().optional(),coverMediaId:c.string().nullable().optional()}).strict(),nH=c.object({used:c.number().int().nonnegative(),limit:c.number().int().nonnegative(),remaining:c.number().int().nonnegative(),periodEnd:c.string(),isDemo:c.boolean(),state:c.enum(["ok","warning","exhausted"])}),oH=c.object({messagesHandled:c.number().int().nonnegative(),proactiveRuns:c.number().int().nonnegative(),approvalsWaiting:c.number().int().nonnegative(),approvalConversationId:c.string().optional(),approvalBotId:c.string().optional(),dailyHandled:c.array(c.number().int().nonnegative()).length(30),messagesByAssistant:c.array(c.object({botId:c.string(),count:c.number().int().nonnegative()})),briefingsDelivered:c.number().int().nonnegative(),scheduledRuns:c.number().int().nonnegative(),prev30MessagesHandled:c.number().int().nonnegative(),prev30BriefingsDelivered:c.number().int().nonnegative(),prev30ScheduledRuns:c.number().int().nonnegative(),since:c.string()}),AD=c.enum(["success","info","warning"]),OD=c.object({orgId:c.string(),name:c.string(),avatarUrl:c.string().nullable()}),DD=c.object({key:c.string(),label:c.string(),tone:AD,status:c.string(),trialDaysRemaining:c.number().optional()}),PD=c.object({activeComputerLimit:c.number().int().nonnegative(),activeComputerCount:c.number().int().nonnegative(),computerCount:c.number().int().nonnegative()}),sH=c.object({org:OD,plan:DD,quota:PD,memberCount:c.number().int().nonnegative()}),RD=c.object({sender:c.enum(["user","agent"]),text:c.string()}),UD=c.enum(["works-now","guided-setup","coming-soon","custom-workflow"]),jD=c.object({docsUrl:c.string(),verifiedAt:c.string(),version:c.string().optional(),versionPolicy:c.enum(["date-versioned","header-versioned","path-versioned","endpoint-versioned","unversioned"]),note:c.string().optional()}),MD=c.object({key:c.string(),label:c.string(),rank:c.number()}),LD=c.object({text:c.string(),tone:c.enum(["info","warning","success","danger"])}),cH=c.object({serviceKey:c.string(),name:c.string(),description:c.string(),shortDescription:c.string(),subtitle:c.string().optional(),icon:c.string().optional(),category:c.string(),categoryLabel:c.string(),categoryRank:c.number(),featuredRank:c.number().optional(),secondaryCategories:c.array(MD),badges:c.array(LD),tags:c.array(c.string()),searchAliases:c.array(c.string()),jtbd:c.string(),useCase:c.string(),demoScenario:c.string(),sampleConversation:c.array(RD),publicStatus:UD,apiVerification:jD.optional(),setupDifficulty:c.string(),risk:c.string(),price:c.string(),kind:c.string(),tier:c.string(),installLevel:c.enum(["computer","org","both"]),setupSummary:c.string().optional(),pagePath:c.string()}),VD=c.object({title:c.string().optional(),text:c.string()}),dH=c.object({content:c.string(),mediaType:c.enum(["application/json","text/plain"]),copyLabel:c.string(),action:c.object({label:c.string(),url:c.url()}),steps:c.array(VD)}),mH=c.object({fullName:c.string().min(1).max(100).optional(),bio:c.string().max(500).nullable().optional(),linkedinUsername:Q2.nullable().optional(),profileUrl:c3.nullable().optional(),avatarMediaId:c.string().nullable().optional(),lastBotId:c.string().nullable().optional(),lastActiveOrgId:c.string().nullable().optional()}).strict(),hp=8e3,FD=c.string().regex(/^[A-Z][A-Z0-9_]*$/),BD=c.object({name:c.string().trim().min(1).max(100),instructions:c.string().trim().min(1).max(hp),credentialNames:c.array(FD).max(10)}),TI=c.object({mediaId:c.string().min(1),sha256:c.string().regex(/^[a-f0-9]{64}$/).optional(),name:c.string().min(1).max(100)}).strict(),ZD=BD.extend({toolId:c.string().min(1),assets:c.array(TI)}).strict(),HD=c.object({moment:c.enum(["briefing","checkin","closeout","custom"]),name:c.string().trim().min(1).max(100),policy:c.string().trim().min(1).max(hp),time:c.string().regex(/^([01]\d|2[0-3]):[0-5]\d$/),active:c.boolean()}).strict(),KD=c.object({serviceKey:c.string().min(1).max(50)}).strict(),WD={schemaVersion:c.literal(1),name:c.string().min(1).max(100),summary:c.string().max(500)},NI=c.object({...WD,identity:X0.pick({name:!0,emoji:!0,title:!0,summary:!0,gender:!0}).strict(),guidance:c.string().max(hp),examples:c.array(c.string().max(hp)),tools:c.array(ZD),assets:c.array(TI),routines:c.array(HD).optional(),services:c.array(KD).optional()}).strict(),hH=c.object({templateId:c.string(),publisherId:c.string(),publisher:c.object({userId:c.string(),fullName:c.string(),avatar:c.object({src:c.string()}).strict().optional()}).strict(),name:c.string(),description:c.string(),snapshot:NI,createdAt:c.string()}).strict(),gH=c.object({reviewed:c.literal(!0),orgId:c.string().min(1),sourceBotId:c.string().min(1),snapshot:NI}).strict(),vH=c.object({templateId:c.string().min(1),destination:c.discriminatedUnion("kind",[c.object({kind:c.literal("computer"),computerId:c.string().min(1)}).strict(),c.object({kind:c.literal("first-computer"),orgId:c.string().min(1)}).strict()]),includedToolIds:c.array(c.string().min(1))}).strict(),bH=c.object({"idempotency-key":c.uuid().describe("One UUID per Add intent; reuse it for retries.")}),wH=c.object({user:h3,computers:c.array(bp),bots:c.array(Zl)}),P2=Object.keys(bp.shape),CI=class extends uo{constructor(e){super("Computer",e),this.computerId=Q(this.settings.computerId),this.ownerId=Q(this.settings.ownerId),this.owner=Q(this.settings.owner),this.orgId=Q(this.settings.orgId),this.name=Q(this.settings.name),this.model=Q(this.settings.model),this.timezone=Q(this.settings.timezone),this.billingTier=Q(this.settings.billingTier),this.desiredStatus=Q(this.settings.desiredStatus),this.status=Q(this.settings.status),this.lastActiveAt=Q(this.settings.lastActiveAt),this.createdAt=Q(this.settings.createdAt),this.updatedAt=Q(this.settings.updatedAt),this.lifecycle=Q(this.settings.lifecycle),this.changedAt=Q(this.settings.changedAt),this.detail=Q(this.settings.detail),this.blocker=Q(this.settings.blocker),this.operation=Q(this.settings.operation),this.ownerMarkUrl=R(()=>{let t=this.owner.value;return t?.avatar?.src||Wl(t?.fullName||this.ownerId.value)}),this.state=R(()=>a3({lifecycle:this.lifecycle.value??"unknown",changedAt:this.changedAt.value,detail:this.detail.value,blocker:this.blocker.value,operation:this.operation.value},this.name.value))}merge(e){if(e.computerId!==void 0&&e.computerId!==this.computerId.value)throw new Error("Cannot change a computer identity");for(let t of P2){if(!(t in e))continue;let n=this[t];n&&typeof n=="object"&&"value"in n&&(n.value=e[t])}}toData(){let e={};for(let t of P2){let n=this[t];n&&typeof n=="object"&&"value"in n&&(e[t]=n.value)}return e}toJSON(){return this.toData()}},R2=Object.keys(Zl.shape),ty=class extends uo{constructor(e,t){if(e.computerId!==t.computerId.value)throw new Error("Bot and computer identities do not match");super("Bot",e),this.botId=Q(this.settings.botId),this.computerId=Q(this.settings.computerId),this.name=Q(this.settings.name),this.handle=Q(this.settings.handle),this.emoji=Q(this.settings.emoji),this.title=Q(this.settings.title),this.summary=Q(this.settings.summary),this.avatarId=Q(this.settings.avatarId),this.coverId=Q(this.settings.coverId),this.avatar=Q(this.settings.avatar),this.cover=Q(this.settings.cover),this.email=Q(this.settings.email),this.website=Q(this.settings.website),this.accounts=Q(this.settings.accounts),this.gender=Q(this.settings.gender),this.voiceKey=Q(this.settings.voiceKey),this.publicChatEnabled=Q(this.settings.publicChatEnabled),this.isPrimary=Q(this.settings.isPrimary),this.collaborationEnabled=Q(this.settings.collaborationEnabled),this.status=Q(this.settings.status),this.onboardingStage=Q(this.settings.onboardingStage),this.onboardedAt=Q(this.settings.onboardedAt),this.routinePrimaryChannel=Q(this.settings.routinePrimaryChannel),this.firstMessageAt=Q(this.settings.firstMessageAt),this.firstValueAt=Q(this.settings.firstValueAt),this.lastMessageAt=Q(this.settings.lastMessageAt),this.createdAt=Q(this.settings.createdAt),this.updatedAt=Q(this.settings.updatedAt),this.displayName=R(()=>this.name.value||"Unnamed"),this.avatarUrl=R(()=>this.avatar.value?.src||Wl(this.name.value)),this.hasCustomHandle=R(()=>!!this.handle.value&&!/\d{13,}$/.test(this.handle.value)),this.displayHandle=R(()=>this.hasCustomHandle.value?`@${this.handle.value}`:void 0),this.hasReceivedMessage=R(()=>!!this.lastMessageAt.value),this.computer=t}get owner(){return this.computer.owner}get ownerMarkUrl(){return this.computer.ownerMarkUrl}get ownerId(){return this.computer.ownerId}get orgId(){return this.computer.orgId}get model(){return this.computer.model}get timezone(){return this.computer.timezone}get billingTier(){return this.computer.billingTier}get desiredStatus(){return this.computer.desiredStatus}get lifecycle(){return this.computer.lifecycle}get changedAt(){return this.computer.changedAt}get detail(){return this.computer.detail}get blocker(){return this.computer.blocker}get operation(){return this.computer.operation}get state(){return this.computer.state}get lastActiveAt(){return this.computer.lastActiveAt}merge(e){if(e.botId!==void 0&&e.botId!==this.botId.value)throw new Error("Cannot change a bot identity");if(e.computerId!==void 0&&e.computerId!==this.computerId.value)throw new Error("Cannot move a bot between computers");for(let t of R2){if(!(t in e))continue;let n=this[t];n&&typeof n=="object"&&"value"in n&&(n.value=e[t])}}toData(){let e={};for(let t of R2){let n=this[t];n&&typeof n=="object"&&"value"in n&&(e[t]=n.value)}return e}toJSON(){return this.toData()}}});function Qn(e,t){let n=Number(globalThis.process?.env?.PORT)||Hl.port;return e||(t?`http://localhost:${n}`:Hl.urls.app)}function qD(e,t,n){let i=Qn(e.apiBase,e.isDev);return async(r,o)=>{let a=po.getAuthToken(),s=new Headers(o?.headers);s.has("Content-Type")||s.set("Content-Type","application/json"),a&&!s.has("Authorization")&&s.set("Authorization",`Bearer ${a}`);let l=typeof r=="string"&&r.startsWith("/")?`${i}${r}`:r,u=await fetch(l,{...o,headers:s,credentials:"include"});if(n&&u.status===401&&(await u.clone().json().catch(()=>{}))?.code==="TOKEN_ERROR"&&n(),t){let d=u.json.bind(u);u.json=async()=>{let p=await d();return typeof p=="object"&&p&&"ok"in p&&("user"in p||"token"in p)&&t(p),p}}return u}}function Jl(e){"@babel/helpers - typeof";return Jl=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Jl(e)}function YD(e,t){if(Jl(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var i=n.call(e,t||"default");if(Jl(i)!="object")return i;throw TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function XD(e){var t=YD(e,"string");return Jl(t)=="symbol"?t:t+""}function G(e,t,n){return(t=XD(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}async function Ba(e,t){e.loading.value=!0,e.error.value=null;try{return await t()}finally{e.loading.value=!1}}function AI(e){if(e.role==="assistant"||e.role==="system")return{id:e.messageId,text:e.content,sender:e.role==="system"?"system":"bot",timestamp:e.createdAt,conversationId:e.conversationId,sequence:e.sequence,systemKind:e.systemKind,...e.metadata?.routine?{routine:e.metadata.routine}:{},...e.metadata?.turnOutcome?{turnOutcome:e.metadata.turnOutcome}:{},...e.metadata?.attachments?.length?{attachments:e.metadata.attachments}:{},...e.metadata?.toolActivities?.length?{toolActivities:e.metadata.toolActivities}:{},...e.metadata?.issue?{issue:e.metadata.issue}:{}}}var zI,Sr,Gl,OI,ny,GD,JD,iy,Za,yp,wp,kp,QD,e5,t5,ry,r5,n5,i5,o5,a5,xp,Yl,oy=re(()=>{"use strict";Pn();ql();En();Sr=[],Gl=0,OI=null,ny=4,GD=(zI=globalThis).nanostoresGlobal||(zI.nanostoresGlobal={epoch:0}),JD=()=>{let e,t;for(;Gl<Sr.length;){t=Gl,Gl+=ny;let n=OI?.get(Sr[t]);if(n){if(!n.has(Sr[t+1]))continue;n.clear()}try{Sr[t](Sr[t+1].value,Sr[t+2],Sr[t+3])}catch(i){e=i}}if(Sr.length=Gl=0,e)throw e},iy=e=>{let t=[],n={eq:Object.is,get(){return n.lc||n.listen(()=>{})(),n.value},init:e,lc:0,listen(i){return n.lc=t.push(i),()=>{OI?.get(i)?.delete(n);for(let o=Gl;o<Sr.length;)Sr[o]===i&&Sr[o+1]===n?Sr.splice(o,ny):o+=ny;let r=t.indexOf(i);~r&&(t.splice(r,1),--n.lc||n.off())}},notify(i,r){GD.epoch++;let o=!Sr.length&&!0;for(let a of t)Sr.push(a,n,i,r);o&&JD()},off(){},set(i){let r=n.value;n.eq(r,i)||(n.value=i,n.notify(r))},subscribe(i){let r=n.listen(i);return i(n.value),r},value:e};return n};Za=globalThis,yp=Za.__PL_AUTH_USER__??(Za.__PL_AUTH_USER__=iy(void 0)),wp=Za.__PL_AUTH_TOKEN__??(Za.__PL_AUTH_TOKEN__=iy(null)),kp=Za.__PL_AUTH_DEVICE_ID__??(Za.__PL_AUTH_DEVICE_ID__=iy(null)),QD=class{constructor(){G(this,"logger",co("SDKStorage"))}isLocalStorageFunctional(){return typeof window<"u"&&typeof localStorage?.getItem=="function"&&typeof localStorage?.setItem=="function"&&typeof localStorage?.removeItem=="function"}syncWithGlobalStores(e){let{activeUser:t,token:n,deviceId:i}=e,r=yp.get(),o=wp.get(),a=kp.get();r&&(t.value=r),o&&(n.value=o),a&&(i.value=a),mt(t,s=>yp.set(s),{immediate:!0}),mt(n,s=>wp.set(s),{immediate:!0}),mt(i,s=>kp.set(s),{immediate:!0}),yp.subscribe(s=>{s!==t.value&&(t.value=s)}),wp.subscribe(s=>{s!==n.value&&(n.value=s)}),kp.subscribe(s=>{s!==i.value&&(i.value=s)})}loadFromStorage(e){if(typeof window>"u")return;let t=po.getAuthToken();t&&(e.token.value=t);let n=po.getDeviceId();if(n&&(e.deviceId.value=n),this.isLocalStorageFunctional())try{let i=localStorage.getItem("pagelines-user");i&&(e.activeUser.value=JSON.parse(i))}catch(i){this.logger.error("Failed to load user from localStorage",{data:i})}}saveToStorage(e){if(typeof window<"u"&&(e.token.value?po.setAuthToken(e.token.value):po.removeAuthToken(),this.isLocalStorageFunctional()))try{e.activeUser.value?localStorage.setItem("pagelines-user",JSON.stringify(e.activeUser.value)):localStorage.removeItem("pagelines-user")}catch(t){this.logger.error("Failed to save user to localStorage",{data:t})}}clearStorage(){if(typeof window<"u"){if(po.removeAuthToken(),this.isLocalStorageFunctional())try{localStorage.removeItem("pagelines-user")}catch(e){this.logger.error("Failed to clear user from localStorage",{data:e})}yp.set(void 0),wp.set(null),kp.set(null)}}getItem(e){if(!this.isLocalStorageFunctional())return null;try{return localStorage.getItem(e)}catch(t){return this.logger.error("Failed to get item from localStorage",{key:e,error:t}),null}}setItem(e,t){if(this.isLocalStorageFunctional())try{localStorage.setItem(e,t)}catch(n){this.logger.error("Failed to set item in localStorage",{key:e,error:n})}}},e5=class{constructor(e){G(this,"ctx",void 0),G(this,"computers",Ea(new Map)),G(this,"bots",Ea(new Map)),this.ctx=e}get(e){return this.bots.get(e)}computer(e){return this.computers.get(e)}all(){return[...this.bots.values()]}hydrate(e){for(let t of e.computers){let n=this.computers.get(t.computerId);n?n.merge(t):this.computers.set(t.computerId,new CI(t))}return e.bots.map(t=>{let n=this.computers.get(t.computerId);if(!n)throw Error("Bot references an unknown computer");let i=this.bots.get(t.botId);if(i)return i.merge(t),i;let r=new ty(t,n);return this.bots.set(t.botId,r),r})}clear(){this.bots.clear(),this.computers.clear()}async webhook(e){let t=await this.ctx.apiFetch(`/api/bot-api/webhooks/routine-triggers/${encodeURIComponent(e.triggerId)}`,{method:"POST",headers:{"Content-Type":"application/json","X-PageLines-Key":e.key},body:JSON.stringify({type:e.type,data:e.data,...e.meta?{meta:e.meta}:{}})});if(!t.ok)throw Error(`Webhook delivery failed (${t.status})`);return t.json()}},t5=class{constructor(e,t){G(this,"ctx",void 0),G(this,"registry",void 0),this.ctx=e,this.registry=t}async create(e){let t=this.ctx.token.value,n=await(await this.ctx.apiFetch("/api/computers",{method:"POST",headers:{"Content-Type":"application/json","Idempotency-Key":crypto.randomUUID()},body:JSON.stringify(e)})).json();if(t!==this.ctx.token.value)throw Error("Your account changed. Try again.");if(!n.ok)throw Error(n.error||"Failed to create computer");return this.registry.hydrate({computers:[n.data.computer],bots:[n.data.bot]})[0]}async getLiveStatus(e){let t=this.ctx.token.value;try{let n=await(await this.ctx.apiFetch(`/api/computers/state?ids=${encodeURIComponent(e)}`)).json(),i=n.ok?n.data[e]??Kl:Kl;return t===this.ctx.token.value?(this.registry.computer(e)?.merge(i),i):Kl}catch(n){return this.ctx.logger.warn("Computer status unavailable",{computerId:e,error:n}),Kl}}async waitUntilReady(e){let t=Date.now(),n;for(;Date.now()-t<(e.timeoutMs??tI.wake);){let i=await this.getLiveStatus(e.computerId);if(i.lifecycle!==n&&(e.onStatus?.(i.lifecycle),n=i.lifecycle),i.lifecycle==="running")return;if(i.lifecycle==="error")throw Error("Your computer hit a problem starting");await new Promise(r=>setTimeout(r,e.pollIntervalMs??3e3))}throw Error("Your computer is taking longer than expected. Please try again.")}},ry="Signed in, but your account could not be loaded. Try again.";r5=class{constructor(e){G(this,"ctx",void 0),this.ctx=e}async authenticateWithCode(e,t){let n=await(await this.ctx.apiFetch("/api/auth/verify-code",{method:"POST",body:JSON.stringify({email:e,code:t})})).json();if(!n.ok)throw Error(n.error);let i=await this.getCurrentUser();if(!i)throw Error(ry);return i}async sendCode(e){return Ba(this.ctx,async()=>{try{let t=await(await this.ctx.apiFetch("/api/auth/check-email",{method:"POST",body:JSON.stringify({email:e})})).json();if(!t.ok)throw this.ctx.error.value=t.error,Error(t.error)}catch(t){this.ctx.logger.error("Send code error",{data:t});let n=t instanceof Error?t.message:"Failed to send verification code";throw this.ctx.error.value=n,t}})}async verifyCode(e,t){return Ba(this.ctx,async()=>{try{await this.authenticateWithCode(e,t)}catch(n){this.ctx.logger.error("Verify code error",{data:n});let i=n instanceof Error?n.message:"Failed to verify code";throw this.ctx.error.value=i,n}})}async logout(){return Ba(this.ctx,async()=>{try{await this.ctx.apiFetch("/api/auth/logout",{method:"POST"})}catch(e){this.ctx.logger.error("Logout error (user still logged out locally)",{data:e})}this.ctx.activeUser.value=void 0,this.ctx.token.value=null,this.ctx.storage.clearStorage(),this.ctx.clearRoster()})}async getCurrentUser(){let e=this.ctx.token.value;if(e)return Ba(this.ctx,async()=>{try{let t=await(await this.ctx.apiFetch("/api/users/me",{method:"GET"})).json();if(e!==this.ctx.token.value)return;if(!t.ok){this.ctx.error.value=t.error,t.error.includes("Authentication")&&(this.ctx.activeUser.value=void 0,this.ctx.token.value=null,this.ctx.storage.clearStorage(),this.ctx.clearRoster());return}return this.ctx.activeUser.value=t.data.user,this.ctx.hydrateRoster(t.data),t.data.user}catch(t){this.ctx.logger.error("Get current user error",{data:t}),this.ctx.error.value=t instanceof Error?t.message:"Failed to get user info";return}})}async requestAuthCode(e){return Ba(this.ctx,async()=>{try{let t=await(await this.ctx.apiFetch("/api/auth/check-email",{method:"POST",body:JSON.stringify({email:e.email})})).json();return t.ok?(this.ctx.logger.info("Auth code requested successfully",{email:e.email}),!0):(this.ctx.error.value=t.error,this.ctx.logger.error("Failed to request auth code",{email:e.email,error:t.error}),!1)}catch(t){return this.ctx.logger.error("Request auth code error",{email:e.email,error:t}),this.ctx.error.value=t instanceof Error?t.message:"Failed to request auth code",!1}})}async loginWithCode(e){return Ba(this.ctx,async()=>{try{return await this.authenticateWithCode(e.email,e.code),this.ctx.logger.info("Login successful",{email:e.email}),!0}catch(t){return this.ctx.logger.error("Login with code error",{email:e.email,error:t}),this.ctx.error.value=t instanceof Error?t.message:"Login failed",!1}})}loginWithGoogle(e){if(typeof window>"u"){this.ctx.logger.error("loginWithGoogle: Only available in browser");return}let t=Qn(this.ctx.apiBase,this.ctx.isDev),n=window.location.origin,i=`${t}/auth/google-popup?origin=${encodeURIComponent(n)}`,r=window.screenX+(window.outerWidth-500)/2,o=window.screenY+(window.outerHeight-600)/2,a=window.open(i,"google-auth",`width=500,height=600,left=${r},top=${o},popup=yes`);if(!a){let u="Popup was blocked. Please allow popups for this site.";this.ctx.error.value=u,e?.onError?.(u);return}let s=async u=>{let d=new URL(t).origin;if(u.origin===d){if(u.data?.type==="auth-success"){window.removeEventListener("message",s);let{token:p}=u.data;this.ctx.processApiResponse({ok:!0,data:{},token:p});let m=await this.getCurrentUser();if(!m){this.ctx.error.value=ry,this.ctx.logger.error("Google login: token accepted but user hydration failed"),e?.onError?.(ry);return}this.ctx.logger.info("Google login successful"),e?.onSuccess?.(m)}else if(u.data?.type==="auth-error"){window.removeEventListener("message",s);let p=u.data.error||"Google authentication failed";this.ctx.error.value=p,this.ctx.logger.error("Google login failed",{error:p}),e?.onError?.(p)}}};window.addEventListener("message",s);let l=setInterval(()=>{a.closed&&(clearInterval(l),window.removeEventListener("message",s))},500)}},n5=class{constructor(e){G(this,"ctx",void 0),this.ctx=e}async confirmCheckout(e){if(e?.sessionId){let t=Qn(this.ctx.apiBase,this.ctx.isDev),n=await(await fetch(`${t}/api/billing/complete-checkout`,{method:"POST",headers:{"Content-Type":"application/json",...this.ctx.token.value&&{Authorization:`Bearer ${this.ctx.token.value}`}},body:JSON.stringify({sessionId:e.sessionId})})).json();if(!n.ok){let i=n.error||"Failed to complete checkout";throw this.ctx.error.value=i,Error(i)}}return this.getStatus()}async getStatus(){let e=this.resolveOrgId(),t=Qn(this.ctx.apiBase,this.ctx.isDev),n=await(await fetch(`${t}/api/billing/details/${e}`,{headers:{...this.ctx.token.value&&{Authorization:`Bearer ${this.ctx.token.value}`}}})).json();if(!n.ok||!n.data)return{plan:void 0,status:"none",hasActiveBilling:!1,maxBots:0};let i=["active","trial","canceling"].includes(n.data.status)||n.data.status==="past_due"&&n.data.paymentRecovery?.suspended!==!0;return{plan:n.data.plan,status:n.data.status,hasActiveBilling:i,maxBots:n.data.maxBots,...n.data.trialEnd&&{trialEnd:n.data.trialEnd},...n.data.trialDaysRemaining!==void 0&&{trialDaysRemaining:n.data.trialDaysRemaining},...n.data.paymentRecovery&&{paymentRecovery:n.data.paymentRecovery}}}resolveOrgId(){let e=this.ctx.activeUser.value?.orgs?.[0]?.orgId;if(!e)throw Error("No organization found. Please sign in first.");return e}};i5=class{constructor(e){G(this,"ctx",void 0),this.ctx=e}async cancelConversationTurn(e){let t=Qn(this.ctx.apiBase,this.ctx.isDev),n=this.ctx.token.value?{Authorization:`Bearer ${this.ctx.token.value}`}:{},i=await fetch(`${t}/api/conversations/${encodeURIComponent(e.conversationId)}/cancel`,{method:"POST",headers:{"Content-Type":"application/json",...n},body:JSON.stringify(e.turnId?{turnId:e.turnId}:{})}),r=await i.json();if(!r.ok)throw Error(r.error||`Cancel failed: HTTP ${i.status}`);return r.data}async chatStreamPublic(e){let t=`${Qn(this.ctx.apiBase,this.ctx.isDev)}/api/bots/public/${encodeURIComponent(e.handle)}/chat/stream`,n="",i=!1,r=!1,o;try{let a=await fetch(t,{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({message:e.message,anonymousId:e.anonymousId,...e.attachments?.length?{attachments:e.attachments.map(({type:s,src:l,filename:u,mimeType:d,mediaId:p})=>({type:s,url:l,name:u,mimeType:d,mediaId:p}))}:{},...e.context?{context:e.context}:{}})});if(!a.ok){let s=await a.json().catch(()=>({error:"Request failed"}));e.onError(ln("api",s.error||`HTTP ${a.status}`,s.code));return}if(n=a.headers.get("X-Conversation-Id")||"",o=a.body?.getReader(),!o){e.onError(ln("stream-open","No response stream"));return}for await(let s of Q0(o))if(s.event==="working_state")e.onStatus?.(s.data.description);else if(s.event==="tool_activity")e.onToolActivity?.(s.data);else if(s.event==="working_end")e.onWorkingEnd?.();else if(s.event==="message_delta")e.onDelta(s.data.delta,s.data.role);else if(s.event==="error"){i=!0,e.onError(s.data);break}else if(s.event==="message"&&(s.data.message.role==="assistant"||s.data.message.role==="system")){r=!0;let l=AI(s.data.message);l&&e.onMessage?.(l)}else if(s.event==="stream_end")break;!i&&r?e.onDone(n):i||e.onError(ln("no-reply","Stream ended before reply arrived"))}catch(a){e.onError(ln("stream-read",a instanceof Error?a.message:"Stream failed","NETWORK_ERROR"))}finally{try{await o?.cancel()}catch{}}}async chatStreamAuthenticated(e){let t=Qn(this.ctx.apiBase,this.ctx.isDev),n=this.ctx.token.value?{Authorization:`Bearer ${this.ctx.token.value}`}:{},i=e.conversationId,r=e.latestSequence??null;if(!i)try{let l=await fetch(`${t}/api/conversations`,{method:"POST",headers:{"Content-Type":"application/json",...n},body:JSON.stringify({orgId:e.orgId,participants:[{type:"bot",id:e.botId}]})}),u=await l.json();if(!u.ok){e.onError(ln("api",u.error||`Conversation failed: HTTP ${l.status}`,u.code));return}i=u.data.conversationId,r=u.data.latestSequence??null}catch(l){e.onError(ln("api",l instanceof Error?l.message:"Conversation failed","NETWORK_ERROR"));return}let o=r?`${t}/api/conversations/${encodeURIComponent(i)}/stream?since=${encodeURIComponent(r)}`:`${t}/api/conversations/${encodeURIComponent(i)}/stream`,a=`nonce_${V2(16)}`,s=iI();await yI({streamUrl:o,sendUrl:`${t}/api/messages`,headers:n,sendBody:{conversationId:i,content:e.message,clientNonce:a,...s?{viewerTimezone:s}:{},...e.attachments&&e.attachments.length>0?{attachments:e.attachments}:{}},onStatus:e.onStatus,onDelta:e.onDelta,onToolActivity:e.onToolActivity,onWorkingEnd:e.onWorkingEnd,onMessage:l=>{let u=AI(l);u&&e.onMessage?.(u)},onDone:()=>e.onDone(i),onChatError:e.onError,onTransportError:e.onError})}},o5=class{constructor(e){G(this,"ctx",void 0),this.ctx=e}async getPublicBot(e){this.ctx.loading.value=!0,this.ctx.error.value=null;try{let t=await(await this.ctx.apiFetch(`/api/pub/bot/get-by-handle?handle=${encodeURIComponent(e.handle)}`)).json();if(!t.ok){this.ctx.error.value=t.error,this.ctx.logger.error("Failed to fetch public bot",{handle:e.handle,error:t.error});return}return this.ctx.hydrateRoster({bots:[t.data.bot],computers:[t.data.computer]})[0]}catch(t){this.ctx.logger.error("Get public bot error",{handle:e.handle,error:t}),this.ctx.error.value=t instanceof Error?t.message:"Failed to fetch bot";return}finally{this.ctx.loading.value=!1}}generateAnonId(){let e="pagelinesAnonId",t=this.ctx.storage.getItem(e);return t||(t=gp({prefix:"anon"}),this.ctx.storage.setItem(e,t)),t}track(e){try{typeof window<"u"&&window.parent!==window&&window.parent.postMessage({type:"pagelines_track",event:e.event,botId:e.botId,properties:e.properties||{}},"*"),this.ctx.logger.info("SDK event tracked",{event:e.event,botId:e.botId})}catch(t){this.ctx.logger.error("Track event error",{error:t,args:e})}}},a5=class{constructor(){G(this,"key","__PAGELINES_SDK__")}get(){if(typeof window<"u")return globalThis[this.key]}set(e){typeof window<"u"&&(globalThis[this.key]=e)}delete(){typeof window<"u"&&delete globalThis[this.key]}},xp=new a5,Yl=class DI extends uo{static getInstance(t={}){return xp.get()||new DI(t)}get isDev(){return this.settings.isDev??(typeof window<"u"?window.location.hostname==="localhost"||window.location.hostname.includes("127.0.0.1"):!1)}constructor(t={}){let n=xp.get();if(n)return console.debug("[PageLinesSDK] Returning existing singleton instance"),n;super("PageLinesSDK",t),G(this,"activeUser",Q()),G(this,"token",Q(null)),G(this,"deviceId",Q(null)),G(this,"loading",Q(!1)),G(this,"error",Q(null)),G(this,"apiBase",this.settings.apiBase||void 0),G(this,"storage",new QD),G(this,"sessionId",gp({prefix:"ses"})),G(this,"currentBot",R(()=>{let r=this.activeUser.value;return(r?.lastBotId?this.bot.get(r.lastBotId):void 0)??this.bot.all().find(o=>o.isPrimary.value&&o.ownerId.value===r?.userId)})),G(this,"currentOrg",R(()=>{let r=this.currentBot.value?.computer.orgId.value??this.activeUser.value?.lastActiveOrgId??this.activeUser.value?.primaryOrgId;return this.activeUser.value?.orgs?.find(o=>o.orgId===r)})),G(this,"initialized",void 0),G(this,"resolveUser",void 0),G(this,"bot",void 0),G(this,"computer",void 0),G(this,"auth",void 0),G(this,"billing",void 0),G(this,"chat",void 0),G(this,"user",void 0),G(this,"stopAccountWatch",void 0),xp.set(this);let i={apiFetch:qD({isDev:this.isDev,apiBase:this.apiBase},this.processApiResponse.bind(this),()=>this.clearSession()),apiBase:this.apiBase,isDev:this.isDev,activeUser:this.activeUser,token:this.token,loading:this.loading,error:this.error,currentBot:this.currentBot,hydrateRoster:r=>this.bot.hydrate(r),clearRoster:()=>this.bot.clear(),storage:this.storage,sessionId:this.sessionId,logger:this.logger,processApiResponse:this.processApiResponse.bind(this)};this.bot=new e5(i),this.computer=new t5(i,this.bot),this.auth=new r5(i),this.billing=new n5(i),this.chat=new i5(i),this.user=new o5(i),this.stopAccountWatch=mt(()=>this.activeUser.value?.userId,()=>this.bot.clear(),{flush:"sync"}),this.logger.info("PageLinesSDK initialized"),this.storage.loadFromStorage(this.authRefs()),this.storage.syncWithGlobalStores(this.authRefs()),this.initialized=new Promise(r=>{this.resolveUser=r}),this.token.value&&!this.activeUser.value?this.auth.getCurrentUser().then(r=>{this.resolveUser&&(this.resolveUser(r),this.resolveUser=void 0)}).catch(r=>{this.logger.error("Auto user fetch failed",{data:r}),this.resolveUser&&(this.resolveUser(void 0),this.resolveUser=void 0)}):this.activeUser.value?this.resolveUser?.(this.activeUser.value):this.resolveUser?.(void 0)}processApiResponse(t){if(!t.ok)return;let n=!1;t.user&&(this.activeUser.value=t.user,this.logger.info("User updated from API response",{data:t.user}),n=!0),t.token&&(this.token.value!==t.token&&(this.activeUser.value=void 0,this.bot.clear()),this.token.value=t.token,this.logger.info("Token updated from API response"),n=!0);let i=t.data?.deviceId;i&&(this.deviceId.value=i,n=!0),n&&this.persistAuth(),this.resolveUser&&(this.resolveUser(t.user),this.resolveUser=void 0)}authRefs(){return{activeUser:this.activeUser,token:this.token,deviceId:this.deviceId}}persistAuth(){this.storage.saveToStorage(this.authRefs())}clearSession(){this.bot.clear(),this.logger.info("Clearing session"),this.activeUser.value=void 0,this.token.value=null,this.deviceId.value=null,this.error.value=null,this.storage.clearStorage()}clear(){this.logger.info("Clearing SDK completely"),this.clearSession(),this.loading.value=!1,this.sessionId=gp({prefix:"ses"}),this.stopAccountWatch?.(),xp.delete()}}});function c5(e,t){return w(),$("div",l5,[...t[0]||(t[0]=[b("svg",{class:"ring-circular h-full w-full origin-center",viewBox:"25 25 50 50"},[b("circle",{class:"ring-path",cx:"50",cy:"50",r:"20",fill:"none",stroke:"currentColor","stroke-width":"5","stroke-miterlimit":"30"})],-1)])])}function u5(e){let t=Math.max(0,Math.floor(e.ms/1e3));return`${Math.floor(t/60)}:${(t%60).toString().padStart(2,"0")}`}function d5(e){return e.mimeType.includes("mp4")||e.mimeType.includes("m4a")?"m4a":e.mimeType.includes("ogg")?"ogg":e.mimeType.includes("wav")?"wav":"webm"}function p5(){return typeof MediaRecorder>"u"?"":["audio/webm;codecs=opus","audio/mp4","audio/webm"].find(e=>MediaRecorder.isTypeSupported?.(e))||""}function h5(e){return e.turnOutcome==="failed"?"failed":e.turnOutcome==="stopped"?"stopped":e.sender==="system"?"failed":"completed"}function Ap(e){if(!e)return;let t=Date.parse(e);return Number.isFinite(t)?t:void 0}function qa(e){return Ap(e.endedAt)??Ap(e.startedAt)??0}function wy(e,t){return qa(e)-qa(t)}function nc(e,t){let n=e.filter(r=>r.status==="completed"||r.status==="failed"&&!!r.note).filter(r=>!t.has(r.activityId)).slice().sort(wy),i=[];for(let r of n){let o=r.status==="completed"?"done":"failed",a=i[i.length-1];o==="done"&&a?.tone==="done"&&a.label===r.label&&qa(r)-a.lastMs<=g5?(a.count+=1,a.lastMs=qa(r)):i.push({id:r.activityId,tone:o,label:r.label,note:r.note,count:1,lastMs:qa(r)})}return i.map(r=>({id:r.id,tone:r.tone,label:r.count>1?`${r.label} \xB7 ${r.count}`:r.label,...r.note?{note:r.note}:{}}))}function Cp(e){return e.length<=ay?{visibleRows:e,hiddenRows:[]}:{visibleRows:e.slice(e.length-ay),hiddenRows:e.slice(0,e.length-ay)}}function ky(e){let{activities:t,outcome:n,nowMs:i,canNotifyOnCompletion:r,lastVisibleProgressAtMs:o,includeFailureNote:a=!0}=e;if(n==="completed")return{outcome:n,visibleRows:[],hiddenRows:nc(t,new Set),terminal:{id:"work-complete",tone:"completed",label:fo.completed}};if(n==="failed"){let z=t.filter(J=>J.status==="failed").sort(wy).pop(),j=new Set;z&&j.add(z.activityId);let{visibleRows:O,hiddenRows:U}=Cp(nc(t,j));return{outcome:n,visibleRows:O,hiddenRows:U,terminal:{id:"work-failed",tone:"failed",label:fo.failed,...a&&z?.note?{note:z.note}:{}}}}if(n==="stopped"){let{visibleRows:z,hiddenRows:j}=Cp(nc(t,new Set));return{outcome:n,visibleRows:z,hiddenRows:j,terminal:{id:"work-stopped",tone:"stopped",label:fo.stopped}}}let{visibleRows:s,hiddenRows:l}=Cp(nc(t,new Set)),u=t.filter(z=>z.status==="started").sort(wy).pop(),d=t.reduce((z,j)=>Math.max(z,qa(j)),o??-1/0),p=Number.isFinite(d)?d:i,m=t.reduce((z,j)=>{let O=Ap(j.startedAt)??Ap(j.endedAt);return O===void 0?z:Math.min(z,O)},1/0),f=p+uE,h=(Number.isFinite(m)?m:p)+v5,v=i>=f,k=u||v?{id:u?.activityId??"work-active",tone:"active",label:u?.label??fo.finishing}:void 0,T=v&&i>=h?r?fo.notifyHint:fo.leaveHint:void 0,S=[f,h].filter(z=>z>i).sort((z,j)=>z-j)[0];return{outcome:n,visibleRows:s,hiddenRows:l,...k?{terminal:k}:{},...T?{hint:T}:{},...S===void 0?{}:{nextBoundaryAtMs:S}}}function b5(e){let{segments:t,activities:n,nowMs:i,canNotifyOnCompletion:r,lastVisibleProgressAtMs:o}=e,a=new Map(n.map(f=>[f.activityId,f])),s=f=>ky({activities:f,outcome:"running",nowMs:i,canNotifyOnCompletion:r,...o===void 0?{}:{lastVisibleProgressAtMs:o}}),l=f=>{let{visibleRows:h,hiddenRows:v}=Cp(nc(f,new Set));if(h.length!==0||v.length!==0)return{outcome:"running",visibleRows:h,hiddenRows:v}},u=[],d=new Set(t.flatMap(f=>f.kind==="work"?f.activityIds:[])),p=l(n.filter(f=>!d.has(f.activityId)));p&&u.push({kind:"work",id:"work-unsegmented",journal:p}),t.forEach((f,h)=>{if(f.kind==="text"){f.content&&u.push({kind:"text",id:`text-${h}`,content:f.content});return}let v=f.activityIds.map(T=>a.get(T)).filter(T=>T!==void 0);if(v.length===0)return;let k=l(v);k&&u.push({kind:"work",id:`work-${f.activityIds[0]??h}`,journal:k})});let m=s(n);return m.terminal||m.hint?u.push({kind:"work",id:"work-tail",journal:{outcome:"running",visibleRows:[],hiddenRows:[],...m.terminal?{terminal:m.terminal}:{},...m.hint?{hint:m.hint}:{},...m.nextBoundaryAtMs===void 0?{}:{nextBoundaryAtMs:m.nextBoundaryAtMs}}}):u.push({kind:"loading",id:"work-tail"}),u}function _p(e){if(!e)return;let t=Date.parse(e);return Number.isFinite(t)?t:void 0}function y5(){return typeof navigator<"u"&&!!navigator.mediaDevices?.getUserMedia&&typeof RTCPeerConnection<"u"}function PI(e){return e?typeof e=="string"?e:e.src||"":""}function dE(e){return PI(e.cover)||PI(e.avatar)||Wl(e.name)}function ac(e){let t=e.target;t.dataset.fallbackUsed||(t.dataset.fallbackUsed="true",t.src=Wl())}function pE(e){let{template:t,bot:n}=e;return t.replace(/{name}/g,n.name||"Assistant").replace(/{title}/g,n.title||"").replace(/{handle}/g,n.handle||"")}function T5(e,t){switch(e){case"bot":return`${t} ended the call`;case"idle-timeout":return"Call ended after 30 seconds of silence";case"network":return"Call dropped. Connection lost.";case"session-cap":return"Call reached its time limit";case"unavailable":return"Call couldn\u2019t connect"}}function V5(e,t){this.v=e,this.k=t}function RI(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,i=Array(t);n<t;n++)i[n]=e[n];return i}function F5(e){if(Array.isArray(e))return e}function B5(e,t){var n=e==null?null:typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(n!=null){var i,r,o,a,s=[],l=!0,u=!1;try{if(o=(n=n.call(e)).next,t===0){if(Object(n)!==n)return;l=!1}else for(;!(l=(i=o.call(n)).done)&&(s.push(i.value),s.length!==t);l=!0);}catch(d){u=!0,r=d}finally{try{if(!l&&n.return!=null&&(a=n.return(),Object(a)!==a))return}finally{if(u)throw r}}return s}}function Z5(){throw TypeError(`Invalid attempt to destructure non-iterable instance.
|
|
95
|
+
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function H5(e,t){return F5(e)||B5(e,t)||K5(e,t)||Z5()}function K5(e,t){if(e){if(typeof e=="string")return RI(e,t);var n={}.toString.call(e).slice(8,-1);return n==="Object"&&e.constructor&&(n=e.constructor.name),n==="Map"||n==="Set"?Array.from(e):n==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?RI(e,t):void 0}}function $p(e){var t,n;function i(o,a){try{var s=e[o](a),l=s.value,u=l instanceof V5;Promise.resolve(u?l.v:l).then(function(d){if(u){var p=o==="return"&&l.k?o:"next";if(!l.k||d.done)return i(p,d);d=e[p](d).value}r(!!s.done,d)},function(d){i("throw",d)})}catch(d){r(2,d)}}function r(o,a){o===2?t.reject(a):t.resolve({value:a,done:o}),(t=t.next)?i(t.key,t.arg):n=null}this._invoke=function(o,a){return new Promise(function(s,l){var u={key:o,arg:a,resolve:s,reject:l,next:null};n?n=n.next=u:(t=n=u,i(o,a))})},typeof e.return!="function"&&(this.return=void 0)}function _t(e){return function(t){t instanceof RegExp&&(t.lastIndex=0);var n=[...arguments].slice(1);return _y(e,t,n)}}function vE(e){return function(){return $y(e,[...arguments])}}function Ge(e,t){let n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:ho;if(UI&&UI(e,null),!Ga(t))return e;let i=t.length;for(;i--;){let r=t[i];if(typeof r=="string"){let o=n(r);o!==r&&(W5(t)||(t[i]=o),r=o)}e[r]=!0}return e}function eP(e){for(let t=0;t<e.length;t++)Ir(e,t)||(e[t]=null);return e}function Rr(e){let t=Ha(null);for(let i of mE(e)){var n=H5(i,2);let r=n[0],o=n[1];Ir(e,r)&&(t[r]=Ga(o)?eP(o):o&&typeof o=="object"&&o.constructor===Object?Rr(o):o)}return t}function tP(e){switch(typeof e){case"string":return e;case"number":return X5(e);case"boolean":return Q5(e);case"bigint":return VI?VI(e):"0";case"symbol":return FI?FI(e):"Symbol()";case"undefined":return tc(e);case"function":case"object":{if(e===null)return tc(e);let t=e,n=Hr(t,"toString");if(typeof n=="function"){let i=n(t);return typeof i=="string"?i:tc(i)}return tc(e)}default:return tc(e)}}function Hr(e,t){for(;e!==null;){let i=hE(e,t);if(i){if(i.get)return _t(i.get);if(typeof i.value=="function")return _t(i.value)}e=fE(e)}function n(){return null}return n}function rP(e,t){for(;e!==null;){let n=hE(e,t);if(n)return n.get?_t(n.get):null;e=fE(e)}return null}function nP(e){try{return Xt(e,""),!0}catch{return!1}}function bE(){let e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:vP(),t=oe=>bE(oe);if(t.version="3.4.17",t.removed=[],!e||!e.document||e.document.nodeType!==At.document||!e.Element)return t.isSupported=!1,t;let n=e.document,i=n,r=i.currentScript;e.DocumentFragment;let o=e.HTMLTemplateElement,a=e.Node,s=e.Element,l=e.NodeFilter;e.NamedNodeMap===void 0&&(e.NamedNodeMap||e.MozNamedAttrMap),e.HTMLFormElement;let u=e.DOMParser,d=e.trustedTypes,p=s.prototype,m=Hr(p,"cloneNode"),f=Hr(p,"remove"),h=Hr(p,"removeAttributeNode"),v=Hr(p,"nextSibling"),k=Hr(p,"childNodes"),T=Hr(p,"parentNode"),S=Hr(p,"shadowRoot"),z=Hr(p,"attributes"),j=a&&a.prototype?Hr(a.prototype,"nodeType"):null,O=a&&a.prototype?Hr(a.prototype,"nodeName"):null,U=a&&a.prototype?Hr(a.prototype,"ownerDocument"):null,J=function(g){return j?j(g):g.nodeType},W=function(g){return O?O(g):g.nodeName},ce=rP(p,"namespaceURI"),se=function(g){return ce?ce(g):g.namespaceURI};if(typeof o=="function"){let oe=n.createElement("template");oe.content&&oe.content.ownerDocument&&(n=oe.content.ownerDocument)}let pe,F="",ue,Je=!1,ct=0,ft=function(){if(ct>0)throw ti('A configured TRUSTED_TYPES_POLICY callback (createHTML or createScriptURL) must not call DOMPurify.sanitize, as that causes infinite recursion. Do not pass a policy whose callbacks wrap DOMPurify as TRUSTED_TYPES_POLICY; see the "DOMPurify and Trusted Types" section of the README.')},Re=function(g){ft(),ct++;try{return pe.createHTML(g)}finally{ct--}},Be=function(g){ft(),ct++;try{return pe.createScriptURL(g)}finally{ct--}},Mt=function(){return Je||(ue=bP(d,r),Je=!0),ue},Er=n,mr=Er.implementation,gt=Er.createNodeIterator,yt=Er.createDocumentFragment,Wr=Er.getElementsByTagName,Tt=i.importNode,Ye=JI();t.isSupported=typeof mE=="function"&&typeof T=="function"&&mr&&mr.createHTMLDocument!==void 0;let Ht=aP,er=sP,Tr=lP,fr=cP,qr=uP,hr=dP,x=pP,I=fP,M=WI,B=null,X=Ge({},[...BI,...dy,...py,...my,...ZI]),_=null,D=Ge({},[...HI,...fy,...KI,...Sp]),y=Object.seal(Ha(null,{tagNameCheck:{writable:!0,configurable:!1,enumerable:!0,value:null},attributeNameCheck:{writable:!0,configurable:!1,enumerable:!0,value:null},allowCustomizedBuiltInElements:{writable:!0,configurable:!1,enumerable:!0,value:!1}})),P=null,E=null,Y=Object.seal(Ha(null,{tagCheck:{writable:!0,configurable:!1,enumerable:!0,value:null},attributeCheck:{writable:!0,configurable:!1,enumerable:!0,value:null}})),ie=!0,fe=!0,ve=!1,we=!0,ye=!1,Ne=!0,Me=!1,Xe=!1,wt=null,$t=null,St=!1,Kt=!1,vt=!1,Nt=!1,Gr=!0,$e=!1,rs="user-content-",zi=!0,xo=!1,Jr=null,ni={},On=null,pc=Ge({},"annotation-xml.audio.colgroup.desc.foreignobject.head.iframe.math.mi.mn.mo.ms.mtext.noembed.noframes.noscript.plaintext.script.selectedcontent.style.svg.template.thead.title.video.xmp".split(".")),mc=null,ns=Ge({},["audio","video","img","source","image","track"]),ii=null,dn=Ge({},["alt","class","for","id","label","name","pattern","placeholder","role","summary","title","value","style","xmlns"]),Dn="http://www.w3.org/1998/Math/MathML",_o="http://www.w3.org/2000/svg",Ur="http://www.w3.org/1999/xhtml",oi=Ur,is=!1,os=null,fc=Ge({},[Dn,_o,Ur],uy),as=Zt(["mi","mo","mn","ms","mtext"]),ee=Ge({},as),L=Zt(["annotation-xml"]),H=Ge({},L),Qe=Ge({},["title","style","font","a","script"]),ke=null,bt=["application/xhtml+xml","text/html"],ut=null,$o=null,ZE=n.createElement("form"),Ly=function(g){return g instanceof RegExp||g instanceof Function},Kp=function(){let g=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};if($o&&$o===g)return;g&&typeof g=="object"||(g={}),g=Rr(g),ke=bt.indexOf(g.PARSER_MEDIA_TYPE)===-1?"text/html":g.PARSER_MEDIA_TYPE,ut=ke==="application/xhtml+xml"?uy:ho,B=Ni(g,"ALLOWED_TAGS",X,{transform:ut}),_=Ni(g,"ALLOWED_ATTR",D,{transform:ut}),os=Ni(g,"ALLOWED_NAMESPACES",fc,{transform:uy}),ii=Ni(g,"ADD_URI_SAFE_ATTR",dn,{transform:ut,base:dn}),mc=Ni(g,"ADD_DATA_URI_TAGS",ns,{transform:ut,base:ns}),On=Ni(g,"FORBID_CONTENTS",pc,{transform:ut}),P=Ni(g,"FORBID_TAGS",Rr({}),{transform:ut}),E=Ni(g,"FORBID_ATTR",Rr({}),{transform:ut}),ni=Ir(g,"USE_PROFILES")?g.USE_PROFILES&&typeof g.USE_PROFILES=="object"?Rr(g.USE_PROFILES):g.USE_PROFILES:!1,ie=g.ALLOW_ARIA_ATTR!==!1,fe=g.ALLOW_DATA_ATTR!==!1,ve=g.ALLOW_UNKNOWN_PROTOCOLS||!1,we=g.ALLOW_SELF_CLOSE_IN_ATTR!==!1,ye=g.SAFE_FOR_TEMPLATES||!1,Ne=g.SAFE_FOR_XML!==!1,Me=g.WHOLE_DOCUMENT||!1,Kt=g.RETURN_DOM||!1,vt=g.RETURN_DOM_FRAGMENT||!1,Nt=g.RETURN_TRUSTED_TYPE||!1,St=g.FORCE_BODY||!1,Gr=g.SANITIZE_DOM!==!1,$e=g.SANITIZE_NAMED_PROPS||!1,zi=g.KEEP_CONTENT!==!1,xo=g.IN_PLACE||!1,M=nP(g.ALLOWED_URI_REGEXP)?g.ALLOWED_URI_REGEXP:WI,oi=typeof g.NAMESPACE=="string"?g.NAMESPACE:Ur,ee=gy(g,"MATHML_TEXT_INTEGRATION_POINTS",()=>Ge({},as)),H=gy(g,"HTML_INTEGRATION_POINTS",()=>Ge({},L));let N=gy(g,"CUSTOM_ELEMENT_HANDLING",()=>Ha(null));if(y=Ha(null),Ir(N,"tagNameCheck")&&Ly(N.tagNameCheck)&&(y.tagNameCheck=N.tagNameCheck),Ir(N,"attributeNameCheck")&&Ly(N.attributeNameCheck)&&(y.attributeNameCheck=N.attributeNameCheck),Ir(N,"allowCustomizedBuiltInElements")&&typeof N.allowCustomizedBuiltInElements=="boolean"&&(y.allowCustomizedBuiltInElements=N.allowCustomizedBuiltInElements),Qt(y),ye&&(fe=!1),vt&&(Kt=!0),ni&&(B=Ge({},ZI),_=Ha(null),ni.html===!0&&(Ge(B,BI),Ge(_,HI)),ni.svg===!0&&(Ge(B,dy),Ge(_,fy),Ge(_,Sp)),ni.svgFilters===!0&&(Ge(B,py),Ge(_,fy),Ge(_,Sp)),ni.mathMl===!0&&(Ge(B,my),Ge(_,KI),Ge(_,Sp))),Y.tagCheck=null,Y.attributeCheck=null,Ir(g,"ADD_TAGS")&&(typeof g.ADD_TAGS=="function"?Y.tagCheck=g.ADD_TAGS:Ga(g.ADD_TAGS)&&(B===X&&(B=Rr(B)),Ge(B,g.ADD_TAGS,ut))),Ir(g,"ADD_ATTR")&&(typeof g.ADD_ATTR=="function"?Y.attributeCheck=g.ADD_ATTR:Ga(g.ADD_ATTR)&&(_===D&&(_=Rr(_)),Ge(_,g.ADD_ATTR,ut))),Ir(g,"ADD_FORBID_CONTENTS")&&Ga(g.ADD_FORBID_CONTENTS)&&(On===pc&&(On=Rr(On)),Ge(On,g.ADD_FORBID_CONTENTS,ut)),zi&&(B["#text"]=!0),Me&&Ge(B,["html","head","body"]),B.table&&(Ge(B,["tbody"]),delete P.tbody),g.TRUSTED_TYPES_POLICY){if(typeof g.TRUSTED_TYPES_POLICY.createHTML!="function")throw ti('TRUSTED_TYPES_POLICY configuration option must provide a "createHTML" hook.');if(typeof g.TRUSTED_TYPES_POLICY.createScriptURL!="function")throw ti('TRUSTED_TYPES_POLICY configuration option must provide a "createScriptURL" hook.');let ne=pe;pe=g.TRUSTED_TYPES_POLICY;try{F=Re("")}catch(ae){throw pe=ne,ae}}else g.TRUSTED_TYPES_POLICY===null?(pe=void 0,F=""):(pe===void 0&&(pe=Mt()),pe&&typeof F=="string"&&(F=Re("")));Zt&&Zt(g),$o=g},Vy=Ge({},[...dy,...py,...iP]),Fy=Ge({},[...my,...oP]),HE=function(g,N,ne){return N.namespaceURI===Ur?g==="svg":N.namespaceURI===Dn?g==="svg"&&(ne==="annotation-xml"||ee[ne]):!!Vy[g]},KE=function(g,N,ne){return N.namespaceURI===Ur?g==="math":N.namespaceURI===_o?g==="math"&&H[ne]:!!Fy[g]},WE=function(g,N,ne){return N.namespaceURI===_o&&!H[ne]||N.namespaceURI===Dn&&!ee[ne]?!1:!Fy[g]&&(Qe[g]||!Vy[g])},qE=function(g){let N=se(g),ne=ho(W(g)),ae=T(g),Ee,ze;return ae&&J(ae)===At.element?(Ee={namespaceURI:se(ae)},ze=ho(W(ae))):(Ee={namespaceURI:oi},ze="template"),os[N]?N===_o?HE(ne,Ee,ze):N===Dn?KE(ne,Ee,ze):N===Ur?WE(ne,Ee,ze):!!(ke==="application/xhtml+xml"&&os[N]):!1},Ai=function(g){Xl(t.removed,{element:g});try{T(g).removeChild(g)}catch{if(f(g),!T(g))throw ti("a node selected for removal could not be detached from its tree and cannot be safely returned; refusing to sanitize in place")}},By=function(g,N,ne){try{h(g,N)}catch{try{g.removeAttribute(ne)}catch{}}},Wp=function(g){Gp(g);let N=k(g);N&&ei(G5(N),ae=>{try{f(ae)}catch{}});let ne=J(g)===At.element?z(g):null;if(ne)for(let ae=ne.length-1;ae>=0;--ae){let Ee=ne[ae],ze=Ee&&Ee.name;typeof ze=="string"&&By(g,Ee,ze)}},So=function(g,N,ne){if(!ne)try{ne=N.getAttributeNode(g)}catch{ne=null}Xl(t.removed,{attribute:ne||null,from:N});try{ne?h(N,ne):N.removeAttribute(g)}catch{try{N.removeAttribute(g)}catch{}}if(g==="is")if(Kt||vt)try{Ai(N)}catch{}else try{N.setAttribute(g,"")}catch{}},Zy=function(g){let N=z(g);if(N)for(let ne=N.length-1;ne>=0;--ne){let ae=N[ne],Ee=ae&&ae.name;typeof Ee!="string"||_[ut(Ee)]||By(g,ae,Ee)}},qp=function(g,N){let ne=arguments.length>2&&arguments[2]!==void 0&&arguments[2],ae=[g];for(;ae.length>0;){let Ee=ae.pop();if(N(Ee)===!1)continue;if(ne&&J(Ee)===At.element){let Le=S(Ee);ai(Le)&&ae.push(Le)}let ze=k(Ee);if(ze)for(let Le=ze.length-1;Le>=0;--Le)ae.push(ze[Le])}},Gp=function(g){qp(g,N=>{J(N)===At.element&&Zy(N)})},Jp=function(g){let N=[];return qp(g,ne=>{N.push(ne)},!0),N},GE=function(g,N){let ne=ly();ei(Jp(g),ae=>{J(ae)===At.element&&cy(ne,ae)}),ei(N,ae=>{J(ae)===At.element&&!Ql(ne,ae)&&Zy(ae)})},Hy=function(g,N){let ne=!1;return ei(t.removed,ae=>{ae.element&&(ne=ne||ae.element===g,Gp(ae.element))}),GE(g,N),ne},JE=function(g,N){let ne=Jr,ae=null,Ee=()=>(ae||(ae=ly(),ei(N,ze=>{cy(ae,ze)})),ae);for(let ze=0;;ze++){let Le=Jp(g),Ot=[g],pn=!1;if(ei(Le,ir=>{J(ir)===At.documentFragment?Xl(Ot,ir):!pn&&!Ql(ne,ir)&&(pn=Ql(Ee(),ir))}),!pn)return;if(ze>=8)throw ti("the tree kept changing during in-place sanitization; refusing to return it");ei(Ot,(ir,gr)=>{YE(ir,gr>0,g,Ee())})}},YE=function(g,N,ne,ae){let Ee=Yp(g),ze;for(;ze=Ee.nextNode();)Ql(ae,ze)&&!Ql(Jr,ze)&&(N&&Yr(Ye.uponSanitizeShadowNode,ze,null),Qp(ze,ne),em(ze,ne),ai(ze.content)&&ls(ze.content))},XE=function(g){Jr&&cy(Jr,g)},Ky=function(g,N){return Ne?g==="patchsrc"||g==="for"&&N!=="label"&&N!=="output":!1},QE=function(g){Ne&&qp(g,N=>{let ne=J(N);if(ne===At.processingInstruction||ne===At.comment&&Xt(qI,N.data)){try{f(N)}catch{}return!1}if(ne===At.element){let ae=N,Ee=ut(W(N));try{ae.hasAttribute&&ae.hasAttribute("patchsrc")&&ae.removeAttribute("patchsrc"),ae.hasAttribute&&ae.hasAttribute("for")&&Ky("for",Ee)&&ae.removeAttribute("for")}catch{}}return!0})},Wy=function(g){let N=null,ne=null;if(St)g="<remove></remove>"+g;else{let ze=MI(g,/^[\r\n\t ]+/);ne=ze&&ze[0]}ke==="application/xhtml+xml"&&oi===Ur&&(g='<html xmlns="http://www.w3.org/1999/xhtml"><head></head><body>'+g+"</body></html>");let ae=pe?Re(g):g;if(oi===Ur)try{N=new u().parseFromString(ae,ke)}catch{}if(!N||!N.documentElement){N=mr.createDocument(oi,"template",null);try{N.documentElement.innerHTML=is?F:ae}catch{}}let Ee=N.body||N.documentElement;return g&&ne&&Ee.insertBefore(n.createTextNode(ne),Ee.childNodes[0]||null),oi===Ur?Wr.call(N,Me?"html":"body")[0]:Me?N.documentElement:Ee},Yp=function(g){let N=U?U(g):g.ownerDocument;return gt.call(N||g,g,l.SHOW_ELEMENT|l.SHOW_COMMENT|l.SHOW_TEXT|l.SHOW_PROCESSING_INSTRUCTION|l.SHOW_CDATA_SECTION,null)},hc=function(g){return g=ec(g,Ht," "),g=ec(g,er," "),g=ec(g,Tr," "),g},Xp=function(g){qy(g);let N=g.querySelectorAll?.call(g,"template");N&&ei(N,ne=>{ai(ne.content)&&Xp(ne.content)})},qy=function(g){g.normalize();let N=U?U(g):g.ownerDocument,ne=gt.call(N||g,g,l.SHOW_TEXT|l.SHOW_COMMENT|l.SHOW_CDATA_SECTION|l.SHOW_PROCESSING_INSTRUCTION,null),ae=ne.nextNode();for(;ae;)ae.data=hc(ae.data),ae=ne.nextNode()},gc=function(g){let N=O?O(g):null;return typeof N!="string"||ut(N)!=="form"?!1:typeof g.nodeName!="string"||typeof g.textContent!="string"||typeof g.removeChild!="function"||g.attributes!==z(g)||typeof g.removeAttribute!="function"||typeof g.removeAttributeNode!="function"||typeof g.getAttributeNode!="function"||typeof g.setAttribute!="function"||typeof g.namespaceURI!="string"||typeof g.insertBefore!="function"||typeof g.hasChildNodes!="function"||g.nodeType!==j(g)||g.childNodes!==k(g)},ai=function(g){if(!j||typeof g!="object"||!g)return!1;try{return j(g)===At.documentFragment}catch{return!1}},ss=function(g){if(!j||typeof g!="object"||!g)return!1;try{return typeof j(g)=="number"}catch{return!1}};function Yr(oe,g,N){oe.length!==0&&ei(oe,ne=>{ne.call(t,g,N,$o)})}let e4=function(g,N){return!!(Ne&&g.hasChildNodes()&&!ss(g.firstElementChild)&&Xt(hy,g.textContent)&&Xt(hy,g.innerHTML)||Ne&&gP[N]&&J(g)===At.element&&se(g)===Ur&&(ss(g.firstElementChild)||typeof g.textContent=="string"&&Xt(hy,g.textContent))||g.nodeType===At.processingInstruction||Ne&&g.nodeType===At.comment&&Xt(qI,g.data))},vc=function(g,N){return g instanceof RegExp?Xt(g,N):g instanceof Function&&!!g(N,...[...arguments].slice(2))},t4=function(g,N,ne){if(!P[N]&&Yy(N)&&vc(y.tagNameCheck,N))return!1;if(zi&&!On[N]&&!On[ho(N)]){let ae=T(g),Ee=k(g);if(Ee&&ae){let ze=Ee.length;for(let Le=ze-1;Le>=0;--Le){let Ot=g===ne?m(Ee[Le],!0):Ee[Le];ae.insertBefore(Ot,v(g))}}}return Ai(g),!0},Gy=function(g,N,ne,ae){return g.length===0?N:N===ne||N===ae?Rr(N):N},Io=function(g,N){return g===N||T(g)!==null?!1:(xo&&Gp(g),!0)},Qp=function(g,N){if(XE(g),Yr(Ye.beforeSanitizeElements,g,null),Io(g,N))return!0;if(gc(g))return Ai(g),!0;let ne=ut(W(g));if(B=Gy(Ye.uponSanitizeElement,B,X,wt),Yr(Ye.uponSanitizeElement,g,{tagName:ne,allowedTags:B}),Io(g,N))return!0;if(e4(g,ne))return Ai(g),!0;if(P[ne]||!(Y.tagCheck instanceof Function&&Y.tagCheck(ne))&&!B[ne]){let ae=t4(g,ne,N);return ae===!1&&(Yr(Ye.afterSanitizeElements,g,null),Io(g,N))?!0:ae}if(J(g)===At.element&&!qE(g)||(ne==="noscript"||ne==="noembed"||ne==="noframes")&&Xt(hP,g.innerHTML))return Ai(g),!0;if(ye&&g.nodeType===At.text){let ae=hc(g.textContent);g.textContent!==ae&&(Xl(t.removed,{element:g.cloneNode()}),g.textContent=ae)}return Yr(Ye.afterSanitizeElements,g,null),Io(g,N)},Jy=function(g,N,ne){if(E[N]||Ky(N,g)||Gr&&(N==="id"||N==="name")&&(ne in n||ne in ZE))return!1;let ae=_[N]||Y.attributeCheck instanceof Function&&Y.attributeCheck(N,g);return fe&&Xt(fr,N)||ie&&Xt(qr,N)?!0:ae?ii[N]||Xt(M,ec(ne,x,""))||(N==="src"||N==="xlink:href"||N==="href")&&g!=="script"&&LI(ne,"data:")===0&&mc[g]||ve&&!Xt(hr,ec(ne,x,""))?!0:!ne:Yy(g)&&vc(y.tagNameCheck,g)&&vc(y.attributeNameCheck,N,g)||N==="is"&&y.allowCustomizedBuiltInElements&&vc(y.tagNameCheck,ne)},r4=Ge({},["annotation-xml","color-profile","font-face","font-face-format","font-face-name","font-face-src","font-face-uri","missing-glyph"]),Yy=function(g){return!r4[ho(g)]&&Xt(I,g)},n4=function(g,N,ne,ae){if(pe&&typeof d=="object"&&typeof d.getAttributeType=="function"&&!ne)switch(d.getAttributeType(g,N)){case"TrustedHTML":return Re(ae);case"TrustedScriptURL":return Be(ae)}return ae},i4=function(g,N,ne,ae){try{return ne?g.setAttributeNS(ne,N,ae):g.setAttribute(N,ae),!gc(g)||(Ai(g),!1)}catch{return So(N,g),!1}},Xy=function(g,N){return Ne&&Xt(/((--!?|])>)|<\/(style|script|title|xmp|textarea|noscript|iframe|noembed|noframes)/i,N)?!0:ho(g)==="attributename"&&MI(N,"href")!==null},em=function(g,N){if(Yr(Ye.beforeSanitizeAttributes,g,null),Io(g,N))return;let ne=g.attributes;if(!ne||gc(g))return;_=Gy(Ye.uponSanitizeAttribute,_,D,$t);let ae={attrName:"",attrValue:"",keepAttr:!0,allowedAttributes:_,forceKeepAttr:void 0},Ee=ne.length,ze=ut(g.nodeName);for(;Ee--;){let Le=ne[Ee],Ot=Le.name,pn=Le.namespaceURI,ir=Le.value,gr=ut(Ot),Eo=ir,vr=Ot==="value"?Eo:Y5(Eo),Qy=!1;ae.attrName=gr,ae.attrValue=vr,ae.keepAttr=!0,ae.forceKeepAttr=void 0,Yr(Ye.uponSanitizeAttribute,g,ae),vr=ae.attrValue,$e&&(gr==="id"||gr==="name")&&LI(vr,rs)!==0&&(So(Ot,g,Le),vr=rs+vr,Qy=!0),Xy(Ot,vr)?So(Ot,g,Le):ae.forceKeepAttr||(ae.keepAttr?!we&&Xt(GI,vr)?So(Ot,g,Le):(ye&&(vr=hc(vr)),Jy(ze,gr,vr)?(vr=n4(ze,gr,pn,vr),vr!==Eo&&i4(g,Ot,pn,vr)&&Qy&&jI(t.removed)):So(Ot,g,Le)):So(Ot,g,Le))}Yr(Ye.afterSanitizeAttributes,g,null),Io(g,N)},ls=function(g){let N=null,ne=Yp(g);for(Yr(Ye.beforeSanitizeShadowDOM,g,null);N=ne.nextNode();)if(Yr(Ye.uponSanitizeShadowNode,N,null),Qp(N,g),em(N,g),ai(N.content)&&ls(N.content),J(N)===At.element){let ae=S(N);ai(ae)&&(tm(ae),ls(ae))}ye&&qy(g),Yr(Ye.afterSanitizeShadowDOM,g,null)},tm=function(g){let N=[{node:g,shadow:null}];for(;N.length>0;){let ne=N.pop();if(ne.shadow){ls(ne.shadow);continue}let ae=ne.node,Ee=J(ae)===At.element,ze=k(ae);if(ze)for(let Le=ze.length-1;Le>=0;--Le)N.push({node:ze[Le],shadow:null});if(Ee){let Le=O?O(ae):null;if(typeof Le=="string"&&ut(Le)==="template"){let Ot=ae.content;ai(Ot)&&N.push({node:Ot,shadow:null})}}if(Ee){let Le=S(ae);ai(Le)&&N.push({node:null,shadow:Le},{node:Le,shadow:null})}}};return t.sanitize=function(oe){let g=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},N=null,ne=null,ae=null,Ee=null;if(is=!oe,is&&(oe="<!-->"),typeof oe!="string"&&!ss(oe)&&(oe=tP(oe),typeof oe!="string"))throw ti("dirty is not a string, aborting");if(!t.isSupported)return oe;Xe?(B=wt,_=$t):Kp(g),(Ye.uponSanitizeElement.length>0||Ye.uponSanitizeAttribute.length>0)&&(B=Rr(B)),Ye.uponSanitizeAttribute.length>0&&(_=Rr(_)),t.removed=[];let ze=xo&&typeof oe!="string"&&ss(oe),Le=[],Ot=Jr;if(ze){QE(oe);let gr=W(oe);if(typeof gr=="string"){let Eo=ut(gr);if(!B[Eo]||P[Eo])throw Wp(oe),ti("root node is forbidden and cannot be sanitized in-place")}if(gc(oe))throw Wp(oe),ti("root node is clobbered and cannot be sanitized in-place");Le=Jp(oe),Jr=ly()}else if(ss(oe))N=Wy("<!---->"),ne=N.ownerDocument.importNode(oe,!0),ne.nodeType===At.element&&ne.nodeName==="BODY"||ne.nodeName==="HTML"?N=ne:N.appendChild(ne),tm(N);else{if(!Kt&&!ye&&!Me&&oe.indexOf("<")===-1)return pe&&Nt?Re(oe):oe;if(N=Wy(oe),!N)return Kt?null:Nt?F:""}N&&St&&Ai(N.firstChild);let pn=ze?oe:N;try{ze&&tm(oe);let gr=Yp(pn);for(;ae=gr.nextNode();)Qp(ae,pn),em(ae,pn),ai(ae.content)&&ls(ae.content);ze&&JE(oe,Le)}catch(gr){throw ze&&(Wp(oe),Hy(oe,Le)),gr}finally{Jr=Ot}if(ze){if(Hy(oe,Le))throw ti("a node selected for removal could not be safely returned; refusing to sanitize in place");return ye&&Xp(oe),oe}if(Kt){if(ye&&Xp(N),vt)for(Ee=yt.call(N.ownerDocument);N.firstChild;)Ee.appendChild(N.firstChild);else Ee=N;return(_.shadowroot||_.shadowrootmode)&&(Ee=Tt.call(i,Ee,!0)),Ee}let ir=Me?N.outerHTML:N.innerHTML;return Me&&B["!doctype"]&&N.ownerDocument&&N.ownerDocument.doctype&&N.ownerDocument.doctype.name&&Xt(mP,N.ownerDocument.doctype.name)&&(ir="<!DOCTYPE "+N.ownerDocument.doctype.name+`>
|
|
96
|
+
`+ir),ye&&(ir=hc(ir)),pe&&Nt?Re(ir):ir},t.setConfig=function(){let oe=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};Kp(oe),Xe=!0,wt=B,$t=_},t.clearConfig=function(){$o=null,Xe=!1,wt=null,$t=null,pe=ue,F=""},t.isValidAttribute=function(oe,g,N){$o||Kp({});let ne=ut(oe),ae=ut(g);return typeof N=="string"&&(Xy(g,N)||!we&&Xt(GI,N))?!1:Jy(ne,ae,N)},t.addHook=function(oe,g){typeof g=="function"&&Ir(Ye,oe)&&Xl(Ye[oe],g)},t.removeHook=function(oe,g){if(Ir(Ye,oe)){if(g!==void 0){let N=q5(Ye[oe],g);return N===-1?void 0:J5(Ye[oe],N,1)[0]}return jI(Ye[oe])}},t.removeHooks=function(oe){Ir(Ye,oe)&&(Ye[oe]=[])},t.removeAllHooks=function(){Ye=JI()},t}function yP(e,t){if(t.has(e))throw TypeError("Cannot initialize the same private elements twice on an object")}function wP(e,t){yP(e,t),t.add(e)}function Sy(e,t,n){if(typeof e=="function"?e===t:e.has(t))return arguments.length<3?t:n;throw TypeError("Private element is not present on this object")}function Ny(){return{async:!1,breaks:!1,extensions:null,gfm:!0,hooks:null,pedantic:!1,renderer:null,silent:!1,tokenizer:null,walkTokens:null}}function wE(e){bo=e}function mo(e){let t=[];return n=>{let i=Math.max(0,Math.min(3,n-1)),r=t[i];return r||(r=e(i),t[i]=r),r}}function Oe(e,t=""){let n=typeof e=="string"?e:e.source,i={replace:(r,o)=>{let a=typeof o=="string"?o:o.source;return a=a.replace(jt.caret,"$1"),n=n.replace(r,a),i},getRegex:()=>new RegExp(n,t)};return i}function Pr(e,t){if(t){if(jt.escapeTest.test(e))return e.replace(jt.escapeReplace,eE)}else if(jt.escapeTestNoEncode.test(e))return e.replace(jt.escapeReplaceNoEncode,eE);return e}function pR(e){return jt.numericCharacterReference.test(e)?e.replace(jt.numericCharacterReferenceOrAmpersand,(t,n,i)=>{if(n===void 0&&i===void 0)return"&";let r=n===void 0?Number.parseInt(i,16):Number.parseInt(n,10);return r===0||r>1114111||r>=55296&&r<=57343?"\uFFFD":r===38?"&":String.fromCodePoint(r)}):e}function tE(e){try{e=encodeURI(e).replace(jt.percentDecode,"%")}catch{return null}return e}function rE(e,t){let n=e.replace(jt.findPipe,(r,o,a)=>{let s=!1,l=o;for(;--l>=0&&a[l]==="\\";)s=!s;return s?"|":" |"}).split(jt.splitPipe),i=0;if(n[0].trim()||n.shift(),n.length>0&&!n.at(-1)?.trim()&&n.pop(),t)if(n.length>t)n.splice(t);else for(;n.length<t;)n.push("");for(;i<n.length;i++)n[i]=n[i].trim().replace(jt.slashPipe,"|");return n}function ri(e,t,n){let i=e.length;if(i===0)return"";let r=0;for(;r<i;){let o=e.charAt(i-r-1);if(o===t&&!n)r++;else if(o!==t&&n)r++;else break}return e.slice(0,i-r)}function nE(e){let t=e.split(`
|
|
97
97
|
`),n=t.length-1;for(;n>=0&&jt.blankLine.test(t[n]);)n--;return t.length-n<=2?e:t.slice(0,n+1).join(`
|
|
98
98
|
`)}function Dp(e){return e.trim().replace(jt.multipleSpaceGlobal," ").toLowerCase().toUpperCase().toLowerCase()}function iE(e,t){if(e.indexOf(t[0])===-1&&e.indexOf(t[1])===-1)return-1;let n=0;for(let i=0;i<e.length;i++)if(e[i]==="\\")i++;else if(e[i]===t[0])n++;else if(e[i]===t[1]&&(n--,n<0))return i;return n>0?-2:-1}function Ry(e){let t={"*":-1,_:-1},n=-1,i=e.length;for(let r=0;r<i;r++){let o=e[r];if(o!=="*"&&o!=="_"&&o!=="~")continue;let a=r===0?`
|
|
99
99
|
`:e[r-1],s=r+1;for(;s<i&&e[s]===o;)s++;a!==" "&&a!==" "&&a!==`
|
|
100
|
-
`&&a!=="\r"&&a!=="\f"&&(o==="~"?n=r:t[o]=r),r=s-1}return{maskedSrc:e,lastPossibleEmStrongCloserIndex:t,lastPossibleDelCloserIndex:n}}function
|
|
100
|
+
`&&a!=="\r"&&a!=="\f"&&(o==="~"?n=r:t[o]=r),r=s-1}return{maskedSrc:e,lastPossibleEmStrongCloserIndex:t,lastPossibleDelCloserIndex:n}}function mR(e,t){let n=Ry(t),i=Ja.get(e);i?i.push(n):Ja.set(e,[n])}function fR(e){let t=Ja.get(e);t&&(t.pop(),t.length===0&&Ja.delete(e))}function hR(e,t,n){let i=Ja.get(e)?.at(-1);return i&&i.maskedSrc===t?i.lastPossibleEmStrongCloserIndex[n]:Ry(t).lastPossibleEmStrongCloserIndex[n]}function gR(e,t){let n=Ja.get(e)?.at(-1);return n&&n.maskedSrc===t?n.lastPossibleDelCloserIndex:Ry(t).lastPossibleDelCloserIndex}function Tp(e,t=0){let n=t,i="";for(let r of e)if(r===" "){let o=4-n%4;i+=" ".repeat(o),n+=o}else i+=r,n++;return i}function oE(e,t,n,i,r){let o=t.href,a=t.title||null,s=e[1].replace(r.other.outputLinkReplace,"$1"),l=e[0].charAt(0)==="!",u=i.state.inLink,d=i.state.linkEmitted,p=i.state.inRawBlock;i.state.inLink=!0,i.state.linkEmitted=!1;let m=i.inlineTokens(s),f=i.state.linkEmitted;if(i.state.linkEmitted=d,i.state.inLink=u,!l){if(f){i.state.inRawBlock=p;return}i.state.linkEmitted=!0}return{type:l?"image":"link",raw:n,href:o,title:a,text:s,tokens:m}}function vR(e,t,n){let i=e.match(n.other.indentCodeCompensation);if(i===null)return t;let r=i[1];return t.split(`
|
|
101
101
|
`).map(o=>{let a=o.match(n.other.beginningSpace);if(a===null)return o;let[s]=a;return o.slice(Math.min(s.length,r.length))}).join(`
|
|
102
|
-
`)}function aE(e,t,n,i){if(!t.includes("<"))return!1;for(let r=0;r<t.length;r++){if(t[r]==="\\"){r++;continue}if(t[r]==="`"){let s=i.inline.code.exec(t.slice(r));if(s){r+=s[0].length-1;continue}}if(t[r]!=="<")continue;let o=e.slice(n+r),a=i.inline.tag.exec(o)||i.inline.autolink.exec(o);if(a){if(a[0].length>t.length-r)return!0;r+=a[0].length-1}}return!1}function gR(e,t){let n=e.includes("*")||e.includes("_")||e.includes("~")||this.options.hooks?.emStrongMask||this.tokenizer.emStrong!==Ya.prototype.emStrong||this.tokenizer.del!==Ya.prototype.del?Sy(oc,this,bR).call(this,e):e;dR(this.tokenizer,n);try{return Sy(oc,this,vR).call(this,e,n,t)}finally{pR(this.tokenizer)}}function vR(e,t,n){let i=!1,r="",o=1/0;for(;e;){if(e.length<o)o=e.length;else{this.infiniteLoopError(e.charCodeAt(0));break}i||(r=""),i=!1;let a;if(this.options.extensions?.inline?.some(l=>(a=l.call({lexer:this},e,n))?(e=e.substring(a.raw.length),n.push(a),!0):!1))continue;if((a=this.tokenizer.escape(e))||(a=this.tokenizer.tag(e))||(a=this.tokenizer.link(e))){e=e.substring(a.raw.length),n.push(a);continue}if(a=this.tokenizer.reflink(e,this.tokens.links)){e=e.substring(a.raw.length);let l=n.at(-1);a.type==="text"&&l?.type==="text"?(l.raw+=a.raw,l.text+=a.text):n.push(a);continue}if((a=this.tokenizer.emStrong(e,t,r))||(a=this.tokenizer.codespan(e))||(a=this.tokenizer.br(e))||(a=this.tokenizer.del(e,t,r))||(a=this.tokenizer.autolink(e))||!this.state.inLink&&(a=this.tokenizer.url(e))){e=e.substring(a.raw.length),n.push(a);continue}let s=e;if(this.options.extensions?.startInline){let l=1/0,u=e.slice(1),d;this.options.extensions.startInline.forEach(p=>{d=p.call({lexer:this},u),typeof d=="number"&&d>=0&&(l=Math.min(l,d))}),l<1/0&&l>=0&&(s=e.substring(0,l+1))}if(a=this.tokenizer.inlineText(s)){e=e.substring(a.raw.length),a.raw.slice(-1)!=="_"&&(r=a.raw.slice(-1)),i=!0;let l=n.at(-1);l?.type==="text"?(l.raw+=a.raw,l.text+=a.text):n.push(a)}else if(e){this.infiniteLoopError(e.charCodeAt(0));break}}return n}function bR(e){let t=e;if(this.tokens.links&&e.includes("[")){let n=this.tokenizer.rules.inline.reflinkSearch,i=r=>{let o=r.lastIndexOf("[");if(!Object.hasOwn(this.tokens.links,Dp(r.slice(o+1,-1))))return r;if(o>1&&r.charAt(0)!=="!"){let a=r.slice(1,o-1);if(this.linkInText(a))return"["+a.replace(n,i)+"]["+"a".repeat(r.length-o-2)+"]"}return"["+"a".repeat(r.length-2)+"]"};t=t.replace(n,i)}return t=t.replace(this.tokenizer.rules.inline.anyPunctuationOutsideCode,(n,i,r)=>r?"+".repeat(n.length):i?i+n.slice(i.length,-i.length).replace(/`/g,"+")+i:n),t=t.replace(this.tokenizer.rules.inline.blockSkip,(n,i,r)=>{let o=r?r.length:0;return n.slice(0,o)+"["+"a".repeat(n.length-o-2)+"]"}),t=this.options.hooks?.emStrongMask?.call({lexer:this},t)??t,t}function Ci(e,t){if(Array.isArray(t))for(let n=0;n<t.length;n++)e.push(t[n]);else e.push(t)}function et(e,t){return vo.parse(e,t)}function wR(...e){return vo.use(...e),et.defaults=vo.defaults,wE(et.defaults),et}function ER(e){let{orientation:t,maxRows:n,maxWidth:i}=e;if(t==="horizontal"||!i)return sE;let r=i-28-(n-1)*Ka;return Math.min(IR,Math.max(sE,Math.floor(r/n)))}function TR(e){return e.layout==="left-to-right"||e.layout==="radial"?"horizontal":e.layout==="top-to-bottom"?"vertical":e.diagramType==="sequence"?"horizontal":"vertical"}function NR(e){let t=new Set(e.nodes.map(a=>a.id)),n=new Set(e.edges.map(a=>a.to)),i=e.nodes.map(a=>a.id).filter(a=>!n.has(a)),r=new Map;for(let a of i.length?i:e.nodes.slice(0,1).map(s=>s.id))r.set(a,0);for(let a=0;a<e.nodes.length;a++){let s=!1;for(let l of e.edges){if(!t.has(l.from)||!t.has(l.to))continue;let u=r.get(l.from);if(u===void 0)continue;let d=u+1;(r.get(l.to)??-1)<d&&(r.set(l.to,d),s=!0)}if(!s)break}let o=Math.max(0,...r.values());for(let a of e.nodes)r.has(a.id)||r.set(a.id,++o);return r}function CR(e,t){let n=cE(e,TR(e),t?.maxWidth);return t?.maxWidth&&n.orientation==="horizontal"&&n.width>t.maxWidth?cE(e,"vertical",t.maxWidth):n}function cE(e,t,n){let i=NR(e),r=new Map;for(let f of e.nodes){let h=i.get(f.id)??0;r.set(h,[...r.get(h)??[],f])}let o=[...r.entries()].sort(([f],[h])=>f-h),a=Math.max(1,...o.map(([,f])=>f.length)),s=Math.max(1,o.length),l=ER({orientation:t,maxRows:a,...n===void 0?{}:{maxWidth:n}}),u=t==="horizontal"?28+s*l+(s-1)*Ka:28+a*l+(a-1)*Ka,d=t==="horizontal"?28+a*vy+(a-1)*lE:28+s*vy+(s-1)*lE,p=[];for(let[f,[,h]]of o.entries()){let v=(a-h.length)*(t==="horizontal"?86:l+Ka)/2;for(let[k,T]of h.entries()){let S=t==="horizontal"?Np+f*(l+Ka):Np+v+k*(l+Ka),z=t==="horizontal"?Np+v+k*86:Np+f*86;p.push({id:T.id,label:T.label,...T.detail?{detail:T.detail}:{},...T.kind?{kind:T.kind}:{},x:S,y:z,width:l,height:vy})}}let m=new Map(p.map(f=>[f.id,f]));return{width:u,height:d,orientation:t,nodes:p,edges:e.edges.flatMap((f,h)=>{let v=m.get(f.from),k=m.get(f.to);if(!v||!k)return[];let T=t==="horizontal"?v.x+v.width:v.x+v.width/2,S=t==="horizontal"?v.y+v.height/2:v.y+v.height,z=t==="horizontal"?k.x:k.x+k.width/2,j=t==="horizontal"?k.y+k.height/2:k.y;return[{key:`${f.from}-${f.to}-${h}`,from:f.from,to:f.to,...f.label?{label:f.label}:{},x1:T,y1:S,x2:z,y2:j,labelX:(T+z)/2,labelY:(S+j)/2}]})}}function CE(e){let{value:t}=e,n=Math.abs(t);return n>=1e6?`${(t/1e6).toFixed(1).replace(/\.0$/,"")}M`:n>=1e3?`${(t/1e3).toFixed(1).replace(/\.0$/,"")}k`:Number.isInteger(t)?`${t}`:t.toFixed(1)}function zE(e){let{seconds:t}=e,n=Math.round(Math.abs(t)),i=t<0?"-":"";if(n<60)return`${i}${n}s`;if(n<3600){let a=Math.floor(n/60),s=n%60;return s?`${i}${a}m ${s}s`:`${i}${a}m`}let r=Math.floor(n/3600),o=Math.floor(n%3600/60);return o?`${i}${r}h ${o}m`:`${i}${r}h`}function AE(e){return{prefix:e?.valuePrefix??(e?.valueFormat==="currency"?"$":""),suffix:e?.valueSuffix??(e?.valueFormat==="percent"?"%":"")}}function by(e){let{value:t,series:n}=e,{prefix:i,suffix:r}=AE(n),o;switch(n?.valueFormat){case"integer":o=`${Math.round(t)}`;break;case"duration":o=zE({seconds:t});break;case"raw":o=Number.isInteger(t)?`${t}`:t.toFixed(1);break;default:o=CE({value:t})}return`${i}${o}${r}`}function zR(e){let[t,...n]=e.series;if(t)return n.every(i=>i.valueFormat===t.valueFormat&&i.valuePrefix===t.valuePrefix&&i.valueSuffix===t.valueSuffix)?t:void 0}function AR(e){let{value:t,shared:n}=e;if(n?.valueFormat==="duration")return zE({seconds:t});let{prefix:i,suffix:r}=AE(n);return`${i}${CE({value:t})}${r}`}function UR(e){let{labels:t,plotWidth:n}=e;if(!t.length||n<=0)return{mode:"horizontal",entries:[]};let i=t.map(l=>l.length>RR?`${l.slice(0,15).trimEnd()}\u2026`:l),r=t.length-1;if(r===0)return{mode:"horizontal",entries:[{index:0,text:i[0]}]};if((Math.max(...i.map(l=>l.length*OR))+DR)*t.length<=n)return{mode:"horizontal",entries:i.map((l,u)=>({index:u,text:l}))};let o=Math.max(2,Math.floor(n/PR));if(t.length<=o)return{mode:"angled",entries:i.map((l,u)=>({index:u,text:l}))};let a=new Set([0,r]),s=r/(o-1);for(let l=1;l<o-1;l++)a.add(Math.round(l*s));return{mode:"angled",entries:[...a].sort((l,u)=>l-u).map(l=>({index:l,text:i[l]}))}}function XU(e){return e&&JU[e]||YU}function dj(e){return e.hadError?"error":e.sessionState==="live"?e.speaking.bot?"speaking":e.speaking.user?"listening":e.work.active?"working":e.providerThinking?"thinking":"listening":"connecting"}function pj(e){let t=dj(e),n=uj[t],i=t==="working"?e.work.description||"Working on it":n.label,r=t==="working"?i:n.visibleText??"",o=e.takingLonger&&(t==="thinking"||t==="working"),a=o?`${r} ${fo.slowHint}`:r;return{activity:t,label:o?a:i,tone:e.isMuted&&t==="listening"?"bg-theme-400":n.tone,visibleStatus:a,usesIdleWave:n.waits||e.isMuted&&t==="listening",takingLonger:o}}var Up,o5,a5,zp,d5,p5,fo,uE,f5,h5,ay,sc,b5,Xa,y5,jp,w5,Mp,k5,x5,_5,$5,S5,Lp,E5,T5,N5,C5,xy,z5,A5,O5,D5,P5,R5,U5,j5,sy,mE,UI,H5,fE,hE,Zt,Qt,Ha,gE,_y,$y,ei,K5,jI,Xl,W5,q5,Ga,ly,cy,Ql,ho,uy,MI,ec,LI,G5,J5,Y5,VI,FI,Ir,tc,Xt,ti,BI,dy,py,rP,my,nP,ZI,HI,fy,KI,Sp,iP,oP,aP,sP,lP,WI,cP,uP,dP,pP,hy,qI,mP,GI,At,fP,hP,gP,JI,Ni,gy,yE,oc,Ip,bo,go,kE,jt,yP,wP,kP,lc,xP,Cy,xE,_E,_P,zy,$P,Ay,SP,IP,cc,Oy,EP,$E,TP,NP,Dy,YI,CP,zP,AP,OP,SE,DP,Cn,Qa,uc,PP,RP,IE,UP,jP,MP,EE,LP,VP,FP,TE,BP,ZP,HP,KP,WP,qP,GP,JP,YP,XP,QP,eR,NE,Op,tR,rR,nR,XI,iR,oR,QI,aR,Py,sR,Iy,lR,Ep,rc,cR,eE,Ja,Ya,cn,Pp,Uy,un,ic,yR,vo,kR,xR,_R,$R,SR,sE,vy,Np,Ka,lE,IR,OR,DR,PR,RR,jR,MR,LR,VR,FR,BR,ZR,HR,KR,WR,qR,GR,JR,YR,XR,QR,eU,tU,rU,nU,iU,oU,aU,sU,lU,cU,uU,dU,pU,mU,fU,Wa,hU,gU,vU,bU,yU,wU,kU,xU,_U,$U,SU,IU,EU,TU,NU,CU,zU,AU,OU,DU,PU,RU,jy,UU,jU,MU,LU,VU,FU,BU,ZU,HU,KU,WU,qU,GU,JU,YU,Rp,OE,QU,ej,tj,rj,nj,ij,oj,aj,sj,yy,lj,cj,uj,mj,fj,hj,gj,vj,bj,yj,wj,kj,xj,_j,$j,Sj,Ij,Ej,Tj,Nj,Cj,zj,Aj,Oj,Dj,Pj,Rj,Uj,jj,Mj,Lj,Vj,Fj,Bj,Zj,Hj,Kj,Wj,qj,Gj,Jj,Yj,Xj,Qj,eM,tM,rM,nM,iM,oM,aM,sM,lM,cM,uM,dM,pM,mM,fM,hM,gM,vM,bM,yM,wM,kM,xM,_M,yo,$M,SM,IM,Vp,Fp=re(()=>{"use strict";Pn();oy();ql();En();Up=ew((e,t)=>{let n=e.__vccOpts||e;for(let[i,r]of t)n[i]=r;return n},"default"),o5={},a5={class:"spinner max-w-sm"};zp=Up(o5,[["render",s5]]);d5=400,p5=class extends uo{constructor(e){super("VoiceRecorderController",e),G(this,"state",Q({phase:"idle",elapsedMs:0})),G(this,"isActive",R(()=>this.state.value.phase!=="idle")),G(this,"isBusy",R(()=>this.state.value.phase!=="idle")),G(this,"elapsedLabel",R(()=>l5({ms:this.state.value.elapsedMs}))),G(this,"statusText",R(()=>this.state.value.phase==="preparing"?"Starting microphone":this.state.value.phase==="sending"?"Sending voice message":"Release to send")),G(this,"recorder",void 0),G(this,"stream",void 0),G(this,"chunks",[]),G(this,"timer",void 0),G(this,"startedAt",0),G(this,"cancelOnStop",!1),G(this,"stopAfterStart",!1),G(this,"startToken",0)}get canUseBrowserRecording(){return!!this.settings.getUserMedia||typeof navigator<"u"&&!!navigator.mediaDevices?.getUserMedia&&typeof MediaRecorder<"u"}async start(){if(!this.settings.getCanRecord()||this.state.value.phase!=="idle")return;if(!this.canUseBrowserRecording){this.settings.getChatController()?.notify("Voice recording is not available in this browser.");return}this.state.value={phase:"preparing",elapsedMs:0},this.cancelOnStop=!1;let e=++this.startToken;try{let t=await this.getUserMedia({constraints:{audio:!0}});if(e!==this.startToken){t.getTracks().forEach(r=>r.stop());return}let n=u5(),i=this.createRecorder({stream:t,mimeType:n});this.stream=t,this.recorder=i,this.chunks=[],i.addEventListener("dataavailable",r=>{r.data.size>0&&this.chunks.push(r.data)}),i.addEventListener("stop",async()=>{let r=new Blob(this.chunks,{type:i.mimeType||n||"audio/webm"}),o=this.now()-this.startedAt,a=!this.cancelOnStop&&r.size>0&&o>=d5;this.stopCapture(),a&&(this.state.value={phase:"sending",elapsedMs:this.state.value.elapsedMs},await this.sendBlob({blob:r})),this.reset()}),i.start(),this.startedAt=this.now(),this.state.value={phase:"recording",elapsedMs:0},this.timer=this.setInterval(()=>{this.state.value={phase:"recording",elapsedMs:this.now()-this.startedAt}},250),this.stopAfterStart&&this.finish({cancelled:this.cancelOnStop})}catch(t){if(e!==this.startToken)return;this.teardown();let n=t instanceof Error?t.message:"Microphone access failed.";this.settings.getChatController()?.notify(`Voice recording failed \u2014 ${n}`)}}finish(e){this.state.value.phase!=="idle"&&this.state.value.phase!=="sending"&&(this.state.value.phase==="preparing"?(this.stopAfterStart=!0,this.cancelOnStop=e.cancelled):!this.recorder||this.recorder.state!=="recording"?this.teardown():(this.cancelOnStop=e.cancelled,this.recorder.stop()))}teardown(){this.cancelOnStop=!0,this.startToken+=1,this.recorder?.state==="recording"&&this.recorder.stop(),this.stopCapture(),this.reset()}async getUserMedia(e){return(this.settings.getUserMedia||navigator.mediaDevices.getUserMedia.bind(navigator.mediaDevices))(e.constraints)}createRecorder(e){return this.settings.createRecorder?this.settings.createRecorder(e):e.mimeType?new MediaRecorder(e.stream,{mimeType:e.mimeType}):new MediaRecorder(e.stream)}async sendBlob(e){let t=this.settings.getUploadFn(),n=this.settings.getChatController();if(!t||!n)return;let i=e.blob.type||"audio/webm",r=new File([e.blob],`voice-${new Date().toISOString().replace(/[:.]/g,"-")}.${c5({mimeType:i})}`,{type:i});try{let o=await t(r);this.settings.onBeforeSend?.(),await n.sendChatMessage("",[o])}catch(o){let a=o instanceof Error?o.message:"Couldn't send that recording.";n.notify(`Voice message failed \u2014 ${a}`)}}stopCapture(){this.timer&&(this.clearInterval(this.timer),this.timer=void 0),this.stream?.getTracks().forEach(e=>e.stop()),this.stream=void 0,this.recorder=void 0,this.chunks=[],this.stopAfterStart=!1}reset(){this.state.value={phase:"idle",elapsedMs:0}}now(){return this.settings.now?.()??Date.now()}setInterval(e,t){return this.settings.setInterval?.(e,t)??setInterval(e,t)}clearInterval(e){(this.settings.clearInterval??clearInterval)(e)}};fo={finishing:"Finishing up",slowHint:"Taking longer than usual.",completed:"Work complete",failed:"Couldn\u2019t finish",stopped:"Stopped",notifyHint:"Taking longer than usual. You can leave and I\u2019ll notify you when it\u2019s ready.",leaveHint:"Taking longer than usual. You can leave this chat while I work."},uE=1e4,f5=15e3,h5=6e4,ay=3;sc=class extends uo{isQueuedMessage(e){return this.queuedMessageIdSet.value.has(e)}consumeQueuedThrough(e){if(!e||this.queuedMessageIdSet.value.size===0)return;let t=new Set(this.queuedMessageIdSet.value),n=this.sharedMessages.value.findIndex(i=>i.id===e);n<0?t.delete(e):this.sharedMessages.value.slice(0,n+1).forEach(i=>t.delete(i.id)),this.queuedMessageIdSet.value=t}get activeConversationId(){return this.conversationId}createVoiceClient(e){let{sdk:t,createVoiceClientFn:n}=this.settings,i=this._bot.botId.value,r=this._bot.orgId.value;if(t?.activeUser.value&&i&&r)return n?.({botId:i,orgId:r,conversationId:this.conversationId,handlers:e})}async refreshMessages(){await this.settings.refreshMessagesFn?.()}constructor(e){super("BotChatController",e),G(this,"isTextMode",!1),G(this,"lastMessage",{hash:"",time:0}),G(this,"isConnecting",!1),G(this,"turnEpoch",0),G(this,"nextStreamToken",0),G(this,"runningStreamToken",void 0),G(this,"suppressedStreamTokens",new Set),G(this,"queuedMessageIdSet",Q(new Set)),G(this,"queuedMessageIds",R(()=>this.queuedMessageIdSet.value)),G(this,"boundaryTimer",void 0),G(this,"nowMs",We(Date.now())),G(this,"toolActivityTiming",We({})),G(this,"lastVisibleProgressAtMs",We()),G(this,"liveSegments",We([])),G(this,"liveStreamMessageId",We(void 0)),G(this,"conversationId",void 0),G(this,"textState",Q({isActive:!1,isConnected:!1,isThinking:!1,connectionStatus:"disconnected"})),G(this,"botMode",Q("self")),G(this,"sharedMessages",Q([])),G(this,"composerState",Q({text:"",pendingAttachments:[],isUploading:!1})),G(this,"workJournal",R(()=>{let t=this.textState.value.isThinking?"running":this.textState.value.turnOutcome;if(!t)return;let n=this.textState.value.toolActivities;if(n?.length)return ky({activities:n,outcome:t,nowMs:this.nowMs.value,canNotifyOnCompletion:!1,lastVisibleProgressAtMs:this.lastVisibleProgressAtMs.value})})),G(this,"liveTurnBlocks",R(()=>{if(!this.textState.value.isThinking)return[];let t=this.textState.value.toolActivities??[],n=this.liveSegments.value;return!n.length&&!t.length?[]:g5({segments:n,activities:t,nowMs:this.nowMs.value,canNotifyOnCompletion:!1,lastVisibleProgressAtMs:this.lastVisibleProgressAtMs.value})})),G(this,"canUseComposer",R(()=>this.textState.value.sendBlockedReason!=="bot_deleted"&&!this.composerState.value.isUploading)),G(this,"canAttachFile",R(()=>!!this.settings.uploadFileFn)),G(this,"canRecordAudio",R(()=>this.canAttachFile.value&&this.canUseComposer.value&&!this.composerState.value.text.trim()&&this.composerState.value.pendingAttachments.length===0)),G(this,"voiceRecorder",new p5({getCanRecord:()=>this.canRecordAudio.value,getUploadFn:()=>{let t=this.settings.uploadFileFn;return t?n=>t({file:n}):void 0},getChatController:()=>this})),G(this,"canSend",R(()=>(this.composerState.value.text.trim().length>0||this.composerState.value.pendingAttachments.length>0)&&this.canUseComposer.value&&!this.voiceRecorder.isBusy.value)),G(this,"canStop",R(()=>this.textState.value.isThinking&&!this.composerState.value.isUploading&&!this.voiceRecorder.isBusy.value)),G(this,"composerAction",R(()=>this.canSend.value?"send":this.canStop.value?"stop":"idle")),G(this,"composerShowsSecondaryStop",R(()=>this.canStop.value&&this.composerAction.value==="send")),G(this,"canStartVoice",R(()=>{let t=this.settings.sdk;return this.textState.value.sendBlockedReason!=="bot_deleted"&&!!t?.activeUser.value&&!!this._bot.botId.value&&!!this._bot.orgId.value&&!!this.settings.createVoiceClientFn&&v5()})),G(this,"_bot",void 0),G(this,"localMessageSeq",0),this._bot=e.bot,this.setupModeWatcher(),this.setupAvailabilityWatcher(),this.setupBoundaryWatcher()}get chatEnabled(){let e=this._bot.state.value.lifecycle;return this._bot.lifecycle.value===void 0?this._bot.desiredStatus.value==="active":e==="running"}get chatUnavailableReason(){if(this.chatEnabled)return;let e=this._bot.displayName.value,t=this._bot.state.value.lifecycle;return t==="starting"?`${e} is waking up`:t==="stopped"?`${e} is asleep`:this._bot.desiredStatus.value==="active"?`${e} is unavailable`:`${e} is offline`}isDuplicateMessage(e,t){let n=`${t}:${e.toLowerCase().trim()}`,i=Date.now(),r=n===this.lastMessage.hash&&i-this.lastMessage.time<500;return r||(this.lastMessage={hash:n,time:i}),r}addMessage(e,t,n,i){this.isDuplicateMessage(e,t)||(this.sharedMessages.value=[...this.sharedMessages.value,{id:this.nextLocalMessageId(),text:e,sender:t,timestamp:new Date().toISOString(),attachments:n,...i}])}nextLocalMessageId(){return`${Date.now()}-${++this.localMessageSeq}`}notify(e,t){e&&this.addMessage(e,"system",void 0,t)}get messageShare(){return this.settings.messageShareFns}get canReportMessages(){return!!this.settings.reportMessageFn}async reportMessage(e){let t=this.settings.reportMessageFn;if(t)try{await t({messageId:e}),this.notify("Reported. Our team will review this message.")}catch(n){this.logger.warn("reportMessage failed",{messageId:e,error:n instanceof Error?n.message:String(n)}),this.notify("Could not report that message.")}}setComposerText(e){this.composerState.value={...this.composerState.value,text:e.text}}async attachFile(e){let t=this.settings.uploadFileFn;if(t&&!this.voiceRecorder.isBusy.value){this.composerState.value={...this.composerState.value,isUploading:!0};try{let n=await t({file:e.file});this.composerState.value={...this.composerState.value,pendingAttachments:[...this.composerState.value.pendingAttachments,n]}}catch(n){let i=n instanceof Error?n.message:"Couldn't attach that file.";this.notify(`Upload failed \u2014 ${i}`)}finally{this.composerState.value={...this.composerState.value,isUploading:!1}}}}removeAttachment(e){this.composerState.value={...this.composerState.value,pendingAttachments:this.composerState.value.pendingAttachments.filter((t,n)=>n!==e.index)}}addOfflineSystemReply(){let e=this._bot.displayName.value||"Your assistant",t=this._bot.state.value.blocker;if(t){let s=t.actionUrl.startsWith("pagelines://")?this.settings.billingUrl:t.actionUrl,l=[`${t.title}.${t.help?` ${t.help}`:""}`,t.actionLabel&&s?`[${t.actionLabel}](${s})`:t.actionLabel||""].filter(Boolean).join(" "),u=this.sharedMessages.value[this.sharedMessages.value.length-1];if(u?.sender==="system"&&u.text===l)return;this.addMessage(l,"system");return}let n=this.chatUnavailableReason??`${e} is unavailable`,i=this._bot.state.value.lifecycle==="stopped"||this._bot.desiredStatus.value!=="active",r=this.settings.manageUrl,o=i?r?`${n}, so your message can't be answered yet. [Wake ${e}](${r}), then send again.`:`${n}, so your message can't be answered yet. Wake it from the dashboard, then send again.`:`${n}. Give it a moment and send again.`,a=this.sharedMessages.value[this.sharedMessages.value.length-1];(a?.sender!=="system"||a.text!==o)&&this.addMessage(o,"system")}async sendComposerMessage(){if(!this.canSend.value)return;let e=this.composerState.value.text,t=this.composerState.value.pendingAttachments.length>0?[...this.composerState.value.pendingAttachments]:void 0;this.chatEnabled?(this.composerState.value={...this.composerState.value,text:"",pendingAttachments:[]},await this.sendChatMessage(e,t)):this.addOfflineSystemReply()}async handleComposerAction(){this.composerAction.value==="stop"?await this.stopChatTurn():this.composerAction.value==="send"&&await this.sendComposerMessage()}getDynamicSettings(){return{context:this.settings.context||"",firstMessage:this.settings.firstMessage||""}}updateState(e,t){e.value={...e.value,...t}}resetWorkJournalTiming(){this.toolActivityTiming.value={},this.lastVisibleProgressAtMs.value=void 0,this.liveSegments.value=[],this.liveStreamMessageId.value=void 0,this.clearBoundaryTimer()}resetState(){this.resetWorkJournalTiming(),this.updateState(this.textState,{isActive:!1,isConnected:!1,isThinking:!1,connectionStatus:"disconnected",error:void 0,sendBlockedReason:void 0,workingDescription:void 0,toolActivities:void 0,turnOutcome:void 0})}setupBoundaryWatcher(){mt(()=>this.workJournal.value?.nextBoundaryAtMs,e=>{this.scheduleBoundary(e)})}scheduleBoundary(e){if(this.clearBoundaryTimer(),e===void 0)return;let t=Math.max(0,e-Date.now());this.boundaryTimer=setTimeout(()=>{this.boundaryTimer=void 0,this.nowMs.value=Date.now()},t),this.boundaryTimer.unref?.()}clearBoundaryTimer(){this.boundaryTimer&&(clearTimeout(this.boundaryTimer),this.boundaryTimer=void 0)}rememberToolActivity(e){let t=_p(e.startedAt)??this.toolActivityTiming.value[e.activityId]?.startedAt??(e.status==="started"?Date.now():void 0),n=_p(e.endedAt)??this.toolActivityTiming.value[e.activityId]?.endedAt??(e.status==="started"?void 0:Date.now());t&&(this.toolActivityTiming.value={...this.toolActivityTiming.value,[e.activityId]:{startedAt:t,...n?{endedAt:n}:{}}})}withToolActivityTiming(e){let t=this.toolActivityTiming.value[e.activityId],n=Date.now(),i=_p(e.startedAt)??t?.startedAt??(e.status==="started"?n:void 0),r=_p(e.endedAt)??t?.endedAt??(e.status==="started"?void 0:n);return{...e,...i!==void 0&&!e.startedAt?{startedAt:new Date(i).toISOString()}:{},...r!==void 0&&!e.endedAt?{endedAt:new Date(r).toISOString()}:{}}}updateToolActivity(e){let t=this.textState.value.toolActivities??[],n=t.findIndex(o=>o.activityId===e.activityId),i=this.withToolActivityTiming({...n>=0?t[n]:{},...e}),r=n>=0?[...t.slice(0,n),i,...t.slice(n+1)]:[...t,i];this.rememberToolActivity(i),this.updateState(this.textState,{toolActivities:r})}finishToolActivities(e){let t=this.textState.value.toolActivities;if(!t?.length)return;let n=t.map(i=>i.status==="started"?this.withToolActivityTiming({...i,status:e}):i);n.forEach(i=>this.rememberToolActivity(i)),this.updateState(this.textState,{toolActivities:n})}workJournalFor(e){if(e.activities?.length)return ky({activities:e.activities,outcome:e.outcome,nowMs:this.nowMs.value,canNotifyOnCompletion:!1,includeFailureNote:e.includeFailureNote})}setupModeWatcher(){mt(this.botMode,async(e,t)=>{this.logger.info(`Mode changed from ${t} to ${e}`),this.isTextMode&&(t==="talk"||t==="chat")&&await this.endConversation()})}setupAvailabilityWatcher(){mt(()=>[this.chatEnabled,this._bot.state.value.lifecycle],([e])=>{this.isTextMode&&!this.isConnecting&&(e?this.textState.value.isConnected||this.updateState(this.textState,{isConnected:!0,connectionStatus:"connected",error:void 0}):this.textState.value.isConnected&&this.updateState(this.textState,{isConnected:!1,connectionStatus:"disconnected",error:this.chatUnavailableReason}))})}handleError(e){let t=e.message;this.logger.error("Conversation error:",{message:t,error:e}),this.addMessage(t,"system"),this.resetState(),this.updateState(this.textState,{error:t,connectionStatus:"error"})}async setMode(e){this.botMode.value!==e&&(this.botMode.value=e)}async startTextConversation(e={}){if(this.isConnecting)this.logger.info("Text conversation already connecting, ignoring duplicate request");else{this.isConnecting=!0,this.isTextMode=!0,this.updateState(this.textState,{isActive:!0,connectionStatus:"connecting"});try{if(!this.chatEnabled){this.isConnecting=!1,this.updateState(this.textState,{isConnected:!1,connectionStatus:"disconnected",error:this.chatUnavailableReason});return}this.isConnecting=!1,this.updateState(this.textState,{isConnected:!0,connectionStatus:"connected"}),e.onConnect?.(),this.logger.info("Text conversation ready")}catch(t){throw this.isConnecting=!1,this.handleError(t),t}}}async endConversation(){if(this.turnEpoch+=1,this.runningStreamToken=void 0,this.suppressedStreamTokens.clear(),this.queuedMessageIdSet.value=new Set,!this.isTextMode)this.resetState();else try{this.conversationId=void 0,this.resetState(),this.isTextMode=!1}catch{this.isTextMode=!1}}async sendChatMessage(e,t){if(!this.isTextMode)return;let{chatStreamFn:n}=this.settings;if(!this.chatEnabled){this.addOfflineSystemReply();return}if(this.textState.value.sendBlockedReason==="bot_deleted")return;let{sdk:i}=this.settings;if(!n&&!this._bot.handle.value){this.handleError(Error("Bot handle required for chat"));return}let r=this.textState.value.isThinking,o=this.sharedMessages.value.length;this.addMessage(e,"user",t);let a=this.sharedMessages.value.length>o?this.sharedMessages.value[this.sharedMessages.value.length-1]?.id:void 0,s=this.turnEpoch,l=++this.nextStreamToken;r&&a?this.queuedMessageIdSet.value=new Set(this.queuedMessageIdSet.value).add(a):(this.runningStreamToken=l,this.resetWorkJournalTiming(),this.updateState(this.textState,{isThinking:!0,workingDescription:void 0,toolActivities:[],transientIssue:void 0,turnOutcome:void 0}));let u=`stream-${Date.now()}-${l}`,d=!1,p=!1,m=()=>s===this.turnEpoch&&!this.suppressedStreamTokens.has(l),f=U=>{if(s!==this.turnEpoch||!a)return;let J=this.sharedMessages.value;if(this.sharedMessages.value=J.some(W=>W.id===U.id)?J.filter(W=>W.id!==a||W.id===U.id):J.map(W=>W.id===a?U:W),this.queuedMessageIdSet.value.has(a)){let W=new Set(this.queuedMessageIdSet.value);W.delete(a),W.add(U.id),this.queuedMessageIdSet.value=W}a=U.id},h=()=>{this.runningStreamToken!==l&&(this.runningStreamToken=l,this.consumeQueuedThrough(a),this.resetWorkJournalTiming(),this.updateState(this.textState,{isThinking:!0,workingDescription:void 0,toolActivities:[],transientIssue:void 0,turnOutcome:void 0}))},v=(U,J="assistant")=>{if(!m())return;h(),this.updateState(this.textState,{workingDescription:void 0}),J==="assistant"&&(this.lastVisibleProgressAtMs.value=Date.now()),d||(d=!0,this.liveStreamMessageId.value=u,this.sharedMessages.value=[...this.sharedMessages.value,{id:u,text:"",sender:J==="system"?"system":"bot",timestamp:new Date().toISOString()}]);let W=this.liveSegments.value,ce=W[W.length-1];this.liveSegments.value=ce?.kind==="text"?[...W.slice(0,-1),{kind:"text",content:ce.content+U}]:[...W,{kind:"text",content:U}];let se=this.sharedMessages.value,pe=se[se.length-1];pe?.id===u&&(pe.text+=U,this.sharedMessages.value=[...se])},k=U=>{if(!m())return;if(h(),p=!0,U.sender==="bot"&&vp(U.text)){this.liveSegments.value=[],this.liveStreamMessageId.value=void 0,this.sharedMessages.value=this.sharedMessages.value.filter(F=>F.id!==u);return}d=!0;let J=U.sender==="system"||U.turnOutcome==="failed"?"failed":"completed";this.finishToolActivities(J);let W=this.textState.value.toolActivities,ce=U.toolActivities?.length||!W?.length?U:{...U,toolActivities:W};this.liveSegments.value=[],this.liveStreamMessageId.value=void 0,this.updateState(this.textState,{workingDescription:void 0,toolActivities:[],turnOutcome:void 0});let se=this.sharedMessages.value.filter(F=>F.id!==u),pe=se.findIndex(F=>F.id===ce.id);pe>=0?this.sharedMessages.value=[...se.slice(0,pe),ce,...se.slice(pe+1)]:this.sharedMessages.value=[...se,ce],ce.sender==="system"&&ce.issue?.bucket==="account"?this.updateState(this.textState,{sendBlockedReason:"account"}):ce.sender==="system"&&ce.issue?.code==="BOT_DELETED"&&this.updateState(this.textState,{sendBlockedReason:"bot_deleted"})},T=U=>{if(!m())return;if(!d&&!p){S(ln("no-reply","Assistant returned no content"));return}this.finishToolActivities("completed");let J=this.sharedMessages.value,W=J[J.length-1];W?.id===u&&W.sender==="bot"&&vp(W.text)&&(this.sharedMessages.value=J.slice(0,-1)),U&&(this.conversationId=U),this.updateState(this.textState,{isThinking:!1,workingDescription:void 0,transientIssue:void 0}),this.settings.onTurnCompleted?.(U)},S=U=>{if(!m())return;if(this.runningStreamToken!==l){this.consumeQueuedThrough(a),this.sharedMessages.value=this.sharedMessages.value.filter(Re=>Re.id!==a),this.composerState.value.text||(this.composerState.value={...this.composerState.value,text:e,pendingAttachments:t??[]});return}this.updateState(this.textState,{workingDescription:void 0,turnOutcome:"failed"}),this.finishToolActivities("failed");let J=this.sharedMessages.value,W=J[J.length-1];W?.id===u&&!W.text&&(this.sharedMessages.value=J.slice(0,-1)),this.logger.warn("Chat turn failed:",U);let{code:ce,bucket:se,message:pe,actionLabel:F,actionUrl:ue,help:Je}=U,ct={...F?{actionLabel:F}:{},...ue?{actionUrl:ue}:{},...Je?{help:Je}:{}},ft=se==="account"?"account":ce==="BOT_DELETED"?"bot_deleted":void 0;ft?(this.addMessage(pe,"system",void 0,{issue:{code:ce,bucket:se,...ct}}),this.updateState(this.textState,{isThinking:!1,sendBlockedReason:ft})):this.updateState(this.textState,{isThinking:!1,transientIssue:{code:ce,message:pe,...ct}})},z=U=>{if(!m())return;h();let J=U.trim();this.updateState(this.textState,{workingDescription:J||void 0})},j=U=>{if(m()){if(h(),this.lastVisibleProgressAtMs.value=Date.now(),U.status==="started"){let J=this.liveSegments.value,W=J[J.length-1];W?.kind==="work"?W.activityIds.includes(U.activityId)||(this.liveSegments.value=[...J.slice(0,-1),{kind:"work",activityIds:[...W.activityIds,U.activityId]}]):this.liveSegments.value=[...J,{kind:"work",activityIds:[U.activityId]}]}this.updateToolActivity(U)}},O=()=>{m()&&this.updateState(this.textState,{workingDescription:void 0})};try{this.settings.onTurnStarted?.(),await(n?n({message:e,attachments:t,conversationId:this.conversationId,history:this.buildHistory(),onDelta:v,onMessage:k,onUserMessage:f,onDone:T,onError:S,onStatus:z,onToolActivity:j,onWorkingEnd:O}):i.chat.chatStreamPublic({handle:this._bot.handle.value,message:e,attachments:t,anonymousId:i.user.generateAnonId(),context:this.getDynamicSettings().context||void 0,onDelta:v,onMessage:k,onDone:T,onError:S,onStatus:z,onToolActivity:j,onWorkingEnd:O}))}catch(U){S(ln("api",U instanceof Error?U.message:"Chat failed","NETWORK_ERROR"))}finally{this.runningStreamToken===l&&(this.runningStreamToken=void 0)}}async stopChatTurn(){if(this.textState.value.isThinking){this.runningStreamToken!==void 0&&this.suppressedStreamTokens.add(this.runningStreamToken),this.runningStreamToken=void 0,this.updateState(this.textState,{isThinking:!1,turnOutcome:"stopped",workingDescription:void 0,transientIssue:void 0});try{await this.settings.cancelChatTurnFn?.({conversationId:this.conversationId})}catch(e){this.logger.warn("stopChatTurn: cancel failed",{conversationId:this.conversationId,error:e instanceof Error?e.message:String(e)})}}}buildHistory(){return this.sharedMessages.value.filter(e=>e.sender==="user"||e.sender==="bot").slice(-20).map(e=>({role:e.sender==="user"?"user":"assistant",content:e.text,...e.attachments?.length?{attachments:e.attachments}:{}})).filter(e=>e.content.length>0||e.attachments&&e.attachments.length>0)}loadMessages(e){this.conversationId=e.conversationId;let t=this.sharedMessages.value,n=e.messages.filter(d=>d.sender!=="bot"||!vp(d.text)),i=new Set(n.map(d=>d.id)),r=t.filter(d=>!i.has(d.id)),o=n[0]?.sequence,a=d=>!!o&&!!d.sequence&&d.sequence<o;if(this.sharedMessages.value=[...r.filter(a),...n,...r.filter(d=>!a(d))],this.runningStreamToken!==void 0)return;let s=new Set(this.sharedMessages.value.flatMap(d=>d.toolActivities?.map(p=>p.turnId)??[])),l=new Set(this.textState.value.turnOutcome==="stopped"?this.textState.value.toolActivities?.map(d=>d.turnId):[]),u=(e.activeToolActivities??[]).filter(d=>!s.has(d.turnId)&&!l.has(d.turnId));u.length?(u.forEach(d=>this.rememberToolActivity(d)),this.updateState(this.textState,{isThinking:!0,workingDescription:void 0,toolActivities:u,transientIssue:void 0,turnOutcome:void 0})):this.textState.value.toolActivities?.some(d=>s.has(d.turnId))&&this.updateState(this.textState,{isThinking:!1,workingDescription:void 0,toolActivities:[],turnOutcome:void 0})}async destroy(){this.clearBoundaryTimer(),this.voiceRecorder.teardown(),await this.endConversation()}};b5={key:0,class:"absolute inset-0 flex items-center justify-center"},Xa=Pe({__name:"ElBotButton",props:{theme:{default:"primary"},size:{default:"lg"},loading:{type:Boolean,default:!1},icon:{},iconAfter:{}},setup(e){let t=R(()=>({primary:"bg-primary-600 border-primary-400 hover:border-primary-300 hover:bg-primary-500",green:"bg-green-600 border-green-400 hover:border-green-300 hover:bg-green-500",red:"bg-red-600 border-red-400 hover:border-red-300 hover:bg-red-500",default:"bg-white/10 border-white/20 hover:border-white/40 hover:bg-white/20",dark:"bg-theme-900 border-transparent hover:bg-theme-800"})[e.theme]),n=R(()=>({sm:"px-4 py-2 text-sm",md:"px-6 py-3 text-base",lg:"px-8 py-4 text-base"})[e.size]),i=R(()=>({sm:"size-4",md:"size-4",lg:"size-5"})[e.size]);return(r,o)=>(w(),$("button",{class:V(["relative inline-flex items-center justify-center gap-2 font-medium rounded-full backdrop-blur-sm border-2 text-white transition-all duration-200 focus:outline-none active:opacity-80 disabled:opacity-50 disabled:cursor-not-allowed cursor-pointer",[t.value,n.value]])},[e.loading?(w(),$("div",b5,[...o[0]||(o[0]=[b("i",{class:"i-svg-spinners-90-ring-with-bg size-5"},null,-1)])])):te("",!0),b("span",{class:V(["flex items-center gap-2 transition-opacity duration-200",e.loading?"opacity-0":"opacity-100"])},[e.icon?(w(),$("i",{key:0,class:V([e.icon,i.value])},null,2)):te("",!0),zt(r.$slots,"default"),e.iconAfter?(w(),$("i",{key:1,class:V([e.iconAfter,i.value])},null,2)):te("",!0)],2)],2))}}),y5=["value"],jp=Pe({__name:"BotInputEmail",props:{modelValue:{default:""}},emits:["update:modelValue"],setup(e,{emit:t}){let n=t;return(i,r)=>(w(),$("input",{name:"username",type:"email",inputmode:"email",autocomplete:"username",autocapitalize:"off",autocorrect:"off",spellcheck:"false",placeholder:"Enter your email",value:e.modelValue,class:"w-full px-6 py-3 text-theme-900 placeholder-theme-500 bg-white border border-white rounded-full focus:outline-none transition-colors",style:{"font-size":"16px"},onInput:r[0]||(r[0]=o=>n("update:modelValue",o.target.value))},null,40,y5))}}),w5=["placeholder","value"],Mp=Pe({__name:"BotInputOneTimeCode",props:{modelValue:{},length:{},focusFirst:{type:Boolean}},emits:["update:modelValue","autoSubmit"],setup(e,{emit:t}){let n=e,i=t,r=Q(null),o=R(()=>"0".repeat(n.length));Ut(()=>{n.focusFirst&&!("ontouchstart"in window)&&r.value?.focus()});function a(s){let l=s.target.value.replace(/\D/g,"").slice(0,n.length);i("update:modelValue",l),l.length===n.length&&i("autoSubmit",l)}return(s,l)=>(w(),$("input",{ref_key:"input",ref:r,name:"one-time-code",type:"text",inputmode:"numeric",autocomplete:"one-time-code",autocapitalize:"off",autocorrect:"off",spellcheck:"false",enterkeyhint:"done",placeholder:o.value,value:e.modelValue,class:"w-full px-6 py-3 text-center font-mono tracking-[0.35em] text-theme-900 placeholder-theme-500 bg-white border border-white rounded-full focus:outline-none transition-colors",style:{"font-size":"16px"},onInput:a},null,40,w5))}}),k5={class:"relative flex-shrink-0"},x5=["src","alt"],_5={class:"absolute top-1 right-1"},$5={key:1,class:"size-3 bg-theme-400 rounded-full ring-2 ring-white"},S5={class:"min-w-0"},Lp=Pe({__name:"ElModeHeader",props:{bot:{},size:{default:"md"},isOnline:{type:Boolean,default:!1},layout:{default:"centered"}},setup(e){return(t,n)=>(w(),$("div",{class:V(["flex gap-4",[e.layout==="centered"?"flex-col items-center text-center":"flex-row items-center justify-center"]])},[b("div",k5,[b("div",{class:V(["rounded-full overflow-hidden border-white",e.size==="lg"?"w-20 h-20 sm:w-24 sm:h-24 border-4":"w-16 sm:size-16 border-2"])},[b("img",{src:e.bot.avatarUrl.value,alt:e.bot.displayName.value,class:"w-full h-full object-cover",onError:n[0]||(n[0]=(...i)=>Ae(ac)&&Ae(ac)(...i))},null,40,x5)],2),b("div",_5,[e.isOnline?(w(),$(ge,{key:0},[n[1]||(n[1]=b("div",{class:"size-3 bg-green-500 rounded-full ring-2 ring-white absolute animate-ping",style:{"animation-duration":"3s"}},null,-1)),n[2]||(n[2]=b("div",{class:"size-3 bg-green-500 rounded-full ring-2 ring-white"},null,-1))],64)):(w(),$("div",$5))])]),b("div",S5,[b("h1",{class:V(["font-light text-white mb-1 truncate",[e.size==="lg"?"text-3xl mb-2":"text-xl sm:text-2xl tracking-wide leading-tight",e.layout==="horizontal"?"text-white/95":""]])},de(e.bot.displayName.value),3),b("p",{class:V(["font-light line-clamp-1",[e.size==="lg"?"text-base text-white/60":"text-sm sm:text-base",e.layout==="horizontal"?"text-white/70 truncate":"text-white/60"]])},de(e.layout==="horizontal"?e.bot.title.value||"Assistant":e.bot.title.value),3)])],2))}});E5={class:"relative shrink-0 rounded-full"},T5=["src","alt"],N5=["src","alt"],C5=["aria-label"],xy=Pe({__name:"BotAvatar",props:{bot:{},showStatus:{type:Boolean,default:!0},showOwnerMark:{type:Boolean,default:!0},isLight:{type:Boolean,default:!0}},setup(e){let t={green:"bg-green-500",amber:"bg-amber-500",red:"bg-red-500",grey:"bg-theme-300"},n=R(()=>{let o=e.bot.state.value;return e.showStatus&&o.lifecycle!=="unknown"?t[o.color]:null}),i={width:"clamp(7px, 14%, 14px)",height:"clamp(7px, 14%, 14px)",top:"calc(14.6% - clamp(3.5px, 7%, 7px))",right:"calc(14.6% - clamp(3.5px, 7%, 7px))"},r=R(()=>e.isLight?"ring-white":"ring-theme-900");return(o,a)=>(w(),$("div",E5,[b("img",{src:e.bot.avatarUrl.value,alt:e.bot.displayName.value,class:V(["size-full rounded-full object-cover ring-1",e.isLight?"ring-black/5":"ring-white/10"])},null,10,T5),e.showOwnerMark&&e.bot.ownerMarkUrl.value?(w(),$("img",{key:0,src:e.bot.ownerMarkUrl.value,alt:e.bot.owner.value?.fullName?`Owned by ${e.bot.owner.value.fullName}`:"Owner",class:V(["absolute z-10 size-[36%] -bottom-[3%] -left-[3%] rounded-full object-cover ring-2",r.value])},null,10,N5)):te("",!0),n.value?(w(),$("span",{key:1,role:"status","aria-label":e.bot.state.value.tooltip,class:V(["absolute z-10 rounded-full ring-2",[n.value,r.value]]),style:i},null,10,C5)):te("",!0),n.value&&e.bot.state.value.lifecycle==="running"?(w(),$("span",{key:2,"aria-hidden":"true",class:V(["pointer-events-none absolute rounded-full animate-ping opacity-50 [animation-duration:3s]",n.value]),style:i},null,2)):te("",!0)]))}}),z5={key:0,class:"sr-only",role:"status","aria-live":"polite"},A5=["aria-expanded","disabled"],O5=["aria-expanded"],D5={class:"flex w-5 shrink-0 justify-center self-stretch","aria-hidden":"true"},P5=["data-journal-row"],R5={class:"flex w-5 shrink-0 flex-col items-center self-stretch","aria-hidden":"true"},U5={class:"flex h-[17px] shrink-0 items-center"},j5={key:0,class:"sr-only"},sy=Pe({__name:"BotToolActivityGroup",props:{model:{},isLight:{type:Boolean}},setup(e){let t=e,n=We(!1);function i(){n.value=!n.value}let r=R(()=>t.model.outcome==="completed"),o=R(()=>t.model.hiddenRows.length),a=R(()=>t.model.hint??(t.model.terminal?.tone==="active"?t.model.terminal.label:void 0)),s=R(()=>{let d=t.model;return r.value?n.value?d.hiddenRows:[]:[...n.value?d.hiddenRows:[],...d.visibleRows,...d.terminal?[d.terminal]:[]]}),l=R(()=>t.isLight?{spine:"bg-theme-200",dashed:"border-theme-300",doneMark:"text-theme-400",failedMark:"text-theme-400",activeLine:"text-theme-700",stoppedSquare:"bg-theme-400",muted:"text-theme-400",ring:"focus-visible:ring-theme-900"}:{spine:"bg-white/15",dashed:"border-white/25",doneMark:"text-white/45",failedMark:"text-white/55",activeLine:"text-white/85",stoppedSquare:"bg-white/50",muted:"text-white/50",ring:"focus-visible:ring-white"}),u=R(()=>{let d=t.isLight;return{done:{statusWord:"completed",label:d?"text-[12px] text-theme-400":"text-[12px] text-white/50",station:{tag:"i",class:`i-tabler-check size-3 ${l.value.doneMark}`}},active:{statusWord:"in progress",label:d?"text-[12px] font-medium text-theme-700":"text-[12px] font-medium text-white/85",station:{tag:"span",class:`chat-pulse-dot size-1.5 rounded-full bg-current ${l.value.activeLine}`}},failed:{statusWord:"failed",label:d?"text-[12px] font-medium text-theme-600":"text-[12px] font-medium text-white/70",station:{tag:"i",class:`i-tabler-alert-circle size-3.5 ${l.value.failedMark}`}},stopped:{label:d?"text-[12px] font-medium text-theme-600":"text-[12px] font-medium text-white/70",station:{tag:"span",class:`size-[9px] rounded-[2px] ${l.value.stoppedSquare}`}},completed:{label:d?"text-[12px] text-theme-400":"text-[12px] text-white/50",station:{tag:"i",class:"i-tabler-circle-check size-3.5 text-green-600"}}}});return(d,p)=>(w(),$("div",{class:V(["w-full py-0.5",l.value.muted])},[a.value?(w(),$("span",z5,de(a.value),1)):te("",!0),r.value?(w(),$("button",{key:1,type:"button","data-test":"messaging-tool-activity-summary","data-journal-disclosure":"","aria-expanded":n.value,disabled:o.value===0,class:V(["flex min-h-11 items-center gap-x-2 text-left focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-offset-2 disabled:cursor-default",l.value.ring]),onClick:i},[p[0]||(p[0]=b("i",{"data-journal-station":"completed",class:"i-tabler-circle-check size-3.5 shrink-0 text-green-600","aria-hidden":"true"},null,-1)),b("span",{class:V(["text-[12px] font-medium leading-none",l.value.muted])},de(e.model.terminal?.label),3),o.value?(w(),$("i",{key:0,class:V(["size-[13px] shrink-0",[n.value?"i-tabler-chevron-down":"i-tabler-chevron-right",l.value.muted]]),"aria-hidden":"true"},null,2)):te("",!0)],10,A5)):o.value?(w(),$("button",{key:2,type:"button","data-test":"messaging-tool-activity-summary","data-journal-disclosure":"","aria-expanded":n.value,class:V(["flex min-h-11 w-full gap-x-2.5 text-left focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-offset-2",l.value.ring]),onClick:i},[b("span",D5,[b("span",{"data-journal-spine":"dashed",class:V(["w-0 border-l border-dashed",l.value.dashed])},null,2)]),b("span",{class:V(["flex min-h-[20px] items-center gap-0.5 pb-2 text-[12px] leading-none",l.value.muted])},[xt(de(o.value)+" earlier updates ",1),b("i",{class:V(["size-3 shrink-0",n.value?"i-tabler-chevron-down":"i-tabler-chevron-right"]),"aria-hidden":"true"},null,2)],2)],10,O5)):te("",!0),(w(!0),$(ge,null,st(s.value,(m,f)=>(w(),$("div",{key:m.id,"data-test":"messaging-tool-activity-row","data-journal-row":m.tone,class:V([r.value?"pl-[22px]":"","flex gap-x-2.5"])},[b("div",R5,[b("span",U5,[(w(),Fe(SS(u.value[m.tone].station.tag),{"data-journal-station":m.tone,class:V(u.value[m.tone].station.class)},null,8,["data-journal-station","class"]))]),f===s.value.length-1?te("",!0):(w(),$("span",{key:0,class:V(["w-px flex-1",l.value.spine])},null,2))]),b("div",{class:V(["min-w-0 flex-1",f===s.value.length-1?"":"pb-2"])},[b("span",{class:V(["relative block leading-snug",u.value[m.tone].label])},[xt(de(m.label),1),u.value[m.tone].statusWord?(w(),$("span",j5,", "+de(u.value[m.tone].statusWord),1)):te("",!0)],2),m.note?(w(),$("p",{key:0,class:V(["pt-0.5 text-[12px] leading-snug",l.value.muted])},de(m.note),3)):te("",!0)],2)],10,P5))),128)),!r.value&&e.model.hint?(w(),$("p",{key:3,"data-test":"messaging-tool-activity-hint",class:V(["pl-[30px] pt-2.5 text-[12px] leading-snug",l.value.muted])},de(e.model.hint),3)):te("",!0)],2))}});$p.prototype[typeof Symbol=="function"&&Symbol.asyncIterator||"@@asyncIterator"]=function(){return this},$p.prototype.next=function(e){return this._invoke("next",e)},$p.prototype.throw=function(e){return this._invoke("throw",e)},$p.prototype.return=function(e){return this._invoke("return",e)};mE=Object.entries,UI=Object.setPrototypeOf,H5=Object.isFrozen,fE=Object.getPrototypeOf,hE=Object.getOwnPropertyDescriptor,Zt=Object.freeze,Qt=Object.seal,Ha=Object.create,gE=typeof Reflect<"u"&&Reflect,_y=gE.apply,$y=gE.construct;Zt||(Zt=function(t){return t}),Qt||(Qt=function(t){return t}),_y||(_y=function(t,n){var i=[...arguments].slice(2);return t.apply(n,i)}),$y||($y=function(t){return new t(...[...arguments].slice(1))});ei=_t(Array.prototype.forEach);Array.prototype.indexOf;K5=_t(Array.prototype.lastIndexOf),jI=_t(Array.prototype.pop),Xl=_t(Array.prototype.push),W5=_t(Array.prototype.slice),q5=_t(Array.prototype.splice),Ga=Array.isArray,ly=vE(Set),cy=_t(Set.prototype.add),Ql=_t(Set.prototype.has),ho=_t(String.prototype.toLowerCase),uy=_t(String.prototype.toString),MI=_t(String.prototype.match),ec=_t(String.prototype.replace),LI=_t(String.prototype.indexOf),G5=_t(String.prototype.trim),J5=_t(Number.prototype.toString),Y5=_t(Boolean.prototype.toString),VI=typeof BigInt>"u"?null:_t(BigInt.prototype.toString),FI=typeof Symbol>"u"?null:_t(Symbol.prototype.toString),Ir=_t(Object.prototype.hasOwnProperty),tc=_t(Object.prototype.toString),Xt=_t(RegExp.prototype.test),ti=vE(TypeError);BI=Zt("a.abbr.acronym.address.area.article.aside.audio.b.bdi.bdo.big.blink.blockquote.body.br.button.canvas.caption.center.cite.code.col.colgroup.content.data.datalist.dd.decorator.del.details.dfn.dialog.dir.div.dl.dt.element.em.fieldset.figcaption.figure.font.footer.form.h1.h2.h3.h4.h5.h6.head.header.hgroup.hr.html.i.img.input.ins.kbd.label.legend.li.main.map.mark.marquee.menu.menuitem.meter.nav.nobr.ol.optgroup.option.output.p.picture.pre.progress.q.rp.rt.ruby.s.samp.search.section.select.shadow.slot.small.source.spacer.span.strike.strong.style.sub.summary.sup.table.tbody.td.template.textarea.tfoot.th.thead.time.tr.track.tt.u.ul.var.video.wbr".split(".")),dy=Zt("svg.a.altglyph.altglyphdef.altglyphitem.animatecolor.animatemotion.animatetransform.circle.clippath.defs.desc.ellipse.enterkeyhint.exportparts.filter.font.g.glyph.glyphref.hkern.image.inputmode.line.lineargradient.marker.mask.metadata.mpath.part.path.pattern.polygon.polyline.radialgradient.rect.stop.style.switch.symbol.text.textpath.title.tref.tspan.view.vkern".split(".")),py=Zt(["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"]),rP=Zt(["animate","color-profile","cursor","discard","font-face","font-face-format","font-face-name","font-face-src","font-face-uri","foreignobject","hatch","hatchpath","mesh","meshgradient","meshpatch","meshrow","missing-glyph","script","set","solidcolor","unknown","use"]),my=Zt("math.menclose.merror.mfenced.mfrac.mglyph.mi.mlabeledtr.mmultiscripts.mn.mo.mover.mpadded.mphantom.mroot.mrow.ms.mspace.msqrt.mstyle.msub.msup.msubsup.mtable.mtd.mtext.mtr.munder.munderover.mprescripts".split(".")),nP=Zt(["maction","maligngroup","malignmark","mlongdiv","mscarries","mscarry","msgroup","mstack","msline","msrow","semantics","annotation","annotation-xml","mprescripts","none"]),ZI=Zt(["#text"]),HI=Zt("accept.action.align.alt.autocapitalize.autocomplete.autopictureinpicture.autoplay.background.bgcolor.border.capture.cellpadding.cellspacing.checked.cite.class.clear.color.cols.colspan.command.commandfor.controls.controlslist.coords.crossorigin.datetime.decoding.default.dir.disabled.disablepictureinpicture.disableremoteplayback.download.draggable.enctype.enterkeyhint.exportparts.face.for.headers.height.hidden.high.href.hreflang.id.inert.inputmode.integrity.ismap.kind.label.lang.list.loading.loop.low.max.maxlength.media.method.min.minlength.multiple.muted.name.nonce.noshade.novalidate.nowrap.open.optimum.part.pattern.placeholder.playsinline.popover.popovertarget.popovertargetaction.poster.preload.pubdate.radiogroup.readonly.rel.required.rev.reversed.role.rows.rowspan.spellcheck.scope.selected.shape.size.sizes.slot.span.srclang.start.src.srcset.step.style.summary.tabindex.title.translate.type.usemap.valign.value.width.wrap.xmlns".split(".")),fy=Zt("accent-height.accumulate.additive.alignment-baseline.amplitude.ascent.attributename.attributetype.azimuth.basefrequency.baseline-shift.begin.bias.by.class.clip.clippathunits.clip-path.clip-rule.color.color-interpolation.color-interpolation-filters.color-profile.color-rendering.cx.cy.d.dx.dy.diffuseconstant.direction.display.divisor.dominant-baseline.dur.edgemode.elevation.end.exponent.fill.fill-opacity.fill-rule.filter.filterunits.flood-color.flood-opacity.font-family.font-size.font-size-adjust.font-stretch.font-style.font-variant.font-weight.fx.fy.g1.g2.glyph-name.glyphref.gradientunits.gradienttransform.height.href.id.image-rendering.in.in2.intercept.k.k1.k2.k3.k4.kerning.keypoints.keysplines.keytimes.lang.lengthadjust.letter-spacing.kernelmatrix.kernelunitlength.lighting-color.local.marker-end.marker-mid.marker-start.markerheight.markerunits.markerwidth.maskcontentunits.maskunits.max.mask.mask-type.media.method.mode.min.name.numoctaves.offset.operator.opacity.order.orient.orientation.origin.overflow.paint-order.path.pathlength.patterncontentunits.patterntransform.patternunits.pointer-events.points.preservealpha.preserveaspectratio.primitiveunits.r.rx.ry.radius.refx.refy.repeatcount.repeatdur.restart.result.rotate.scale.seed.shape-rendering.slope.specularconstant.specularexponent.spreadmethod.startoffset.stddeviation.stitchtiles.stop-color.stop-opacity.stroke-dasharray.stroke-dashoffset.stroke-linecap.stroke-linejoin.stroke-miterlimit.stroke-opacity.stroke.stroke-width.style.surfacescale.systemlanguage.tabindex.tablevalues.targetx.targety.transform.transform-origin.text-anchor.text-decoration.text-orientation.text-rendering.textlength.type.u1.u2.unicode.values.vector-effect.viewbox.visibility.version.vert-adv-y.vert-origin-x.vert-origin-y.width.word-spacing.wrap.writing-mode.xchannelselector.ychannelselector.x.x1.x2.xmlns.y.y1.y2.z.zoomandpan".split(".")),KI=Zt("accent.accentunder.align.bevelled.close.columnalign.columnlines.columnspacing.columnspan.denomalign.depth.dir.display.displaystyle.encoding.fence.frame.height.href.id.largeop.length.linethickness.lquote.lspace.mathbackground.mathcolor.mathsize.mathvariant.maxsize.minsize.movablelimits.notation.numalign.open.rowalign.rowlines.rowspacing.rowspan.rspace.rquote.scriptlevel.scriptminsize.scriptsizemultiplier.selection.separator.separators.stretchy.subscriptshift.supscriptshift.symmetric.voffset.width.xmlns".split(".")),Sp=Zt(["xlink:href","xml:id","xlink:title","xml:space","xmlns:xlink"]),iP=Qt(/{{[\w\W]*|^[\w\W]*}}/g),oP=Qt(/<%[\w\W]*|^[\w\W]*%>/g),aP=Qt(/\${[\w\W]*/g),sP=Qt(/^data-[\-\w.\u00B7-\uFFFF]+$/),lP=Qt(/^aria-[\-\w]+$/),WI=Qt(/^(?:(?:(?:f|ht)tps?|mailto|tel|callto|sms|cid|xmpp|matrix):|[^a-z]|[a-z+.\-]+(?:[^a-z+.\-:]|$))/i),cP=Qt(/^(?:\w+script|data):/i),uP=Qt(/[\u0000-\u0020\u00A0\u1680\u180E\u2000-\u2029\u205F\u3000]/g),dP=Qt(/^html$/i),pP=Qt(/^[a-z][.\w]*(-[.\w]+)+$/i),hy=Qt(/<[/\w!]/g),qI=Qt(/<[/\w]/g),mP=Qt(/<\/no(script|embed|frames)/i),GI=Qt(/\/>/i),At={element:1,attribute:2,text:3,cdataSection:4,entityReference:5,entityNode:6,processingInstruction:7,comment:8,document:9,documentType:10,documentFragment:11,notation:12},fP=Zt(Ge({},["style","script","xmp","iframe","noembed","noframes","plaintext","noscript"])),hP=function(){return typeof window>"u"?null:window},gP=function(t,n){if(typeof t!="object"||typeof t.createPolicy!="function")return null;let i=null,r="data-tt-policy-suffix";n&&n.hasAttribute(r)&&(i=n.getAttribute(r));let o="dompurify"+(i?"#"+i:"");try{return t.createPolicy(o,{createHTML(a){return a},createScriptURL(a){return a}})}catch{return console.warn("TrustedTypes policy "+o+" could not be created."),null}},JI=function(){return{afterSanitizeAttributes:[],afterSanitizeElements:[],afterSanitizeShadowDOM:[],beforeSanitizeAttributes:[],beforeSanitizeElements:[],beforeSanitizeShadowDOM:[],uponSanitizeAttribute:[],uponSanitizeElement:[],uponSanitizeShadowNode:[]}},Ni=function(t,n,i,r){return Ir(t,n)&&Ga(t[n])?Ge(r.base?Rr(r.base):{},t[n],r.transform):i},gy=function(t,n,i){let r=Ir(t,n)?t[n]:void 0;return r&&typeof r=="object"?Rr(r):i()};yE=bE();bo=Ny();go={exec:()=>null};kE=((e="")=>{try{return!!RegExp("(?<=1)(?<!1)"+e)}catch{return!1}})(),jt={codeRemoveIndent:/^(?: {0,3}\t| {1,4})/gm,outputLinkReplace:/\\([\[\]])/g,indentCodeCompensation:/^(\s+)(?:```)/,beginningSpace:/^\s+/,endingHash:/#$/,startingSpaceChar:/^ /,endingSpaceChar:/ $/,endingSpaceTabChar:/[ \t]$/,nonSpaceChar:/[^ ]/,newLineCharGlobal:/\n/g,tabCharGlobal:/\t/g,leadingSpaceTab:/^[ \t]+/,multipleSpaceGlobal:/\s+/g,blankLine:/^[ \t]*$/,doubleBlankLine:/\n[ \t]*\n[ \t]*$/,blockquoteStart:/^ {0,3}>/,blockquoteSetextReplace:/\n {0,3}((?:=+|-+)[ \t]*)(?=\n|$)/g,blockquoteSetextReplace2:/^ {0,3}>[ \t]?/gm,blockquoteMarkerWhitespace:/^( {0,3}>)([ \t]+)/gm,listReplaceNesting:/^ {1,4}(?=( {4})*[^ ])/g,listIsTask:/^\[[ xX]\][ \t]+\S/,listReplaceTask:/^\[[ xX]\][ \t]+/,listTaskCheckbox:/\[[ xX]\]/,anyLine:/\n.*\n/,hrefBrackets:/^<(.*)>$/,tableDelimiter:/[:|]/,tableAlignChars:/^\||\| *$/g,tableRowBlankLine:/\n[ \t]*$/,tableAlignRight:/^ *-+: *$/,tableAlignCenter:/^ *:-+: *$/,tableAlignLeft:/^ *:-+ *$/,startATag:/^<a /i,endATag:/^<\/a>/i,startPreScriptTag:/^<(pre|code|kbd|script)(\s|>)/i,endPreScriptTag:/^<\/(pre|code|kbd|script)(\s|>)/i,startAngleBracket:/^</,endAngleBracket:/>$/,pedanticHrefTitle:/^([^'"]*[^\s])\s+(['"])(.*)\2/,unicodeAlphaNumeric:/[\p{L}\p{N}]/u,numericCharacterReference:/&#(?:(\d{1,7})|[Xx]([A-Fa-f0-9]{1,6}));/,numericCharacterReferenceOrAmpersand:/&#(?:(\d{1,7})|[Xx]([A-Fa-f0-9]{1,6}));|&(?!(#\d{1,7}|#[Xx][a-fA-F0-9]{1,6}|\w+);)/g,escapeTest:/[&<>"']/,escapeReplace:/[&<>"']/g,escapeTestNoEncode:/[<>"']|&(?!(#\d{1,7}|#[Xx][a-fA-F0-9]{1,6}|\w+);)/,escapeReplaceNoEncode:/[<>"']|&(?!(#\d{1,7}|#[Xx][a-fA-F0-9]{1,6}|\w+);)/g,caret:/(^|[^\[])\^/g,percentDecode:/%25/g,findPipe:/\|/g,splitPipe:/ \|/,slashPipe:/\\\|/g,carriageReturn:/\r\n|\r/g,spaceLine:/^ +$/gm,notSpaceStart:/^\S*/,endingNewline:/\n$/,listItemRegex:e=>RegExp(`^( {0,3}${e})((?:[ ][^\\n]*)?(?:\\n|$))`),nextBulletRegex:mo(e=>RegExp(`^ {0,${e}}(?:[*+-]|\\d{1,9}[.)])((?:[ ][^\\n]*)?(?:\\n|$))`)),hrRegex:mo(e=>RegExp(`^ {0,${e}}((?:-[ ]*){3,}|(?:_[ ]*){3,}|(?:\\*[ ]*){3,})(?:\\n+|$)`)),fencesBeginRegex:mo(e=>RegExp(`^ {0,${e}}(?:\`\`\`|~~~)`)),headingBeginRegex:mo(e=>RegExp(`^ {0,${e}}#{1,6}(?:\\s|$)`)),pedanticHeadingBeginRegex:mo(e=>RegExp(`^ {0,${e}}#`)),htmlBeginRegex:mo(e=>RegExp(`^ {0,${e}}(?:</?(?:${cc})(?: +|$|/?>)|<(?:(?:script|pre|style|textarea)(?:[\\s>]|$)|!--)|<\\?|<![A-Za-z]|<!\\[CDATA\\[)`,"i")),blockquoteBeginRegex:mo(e=>RegExp(`^ {0,${e}}>`))},yP=/^(?:[ \t]*(?:\n|$))+/,wP=/^((?: {4}| {0,3}\t)[^\n]+(?:\n(?:[ \t]*(?:\n|$))*)?)+/,kP=/^ {0,3}(`{3,}(?=[^`\n]*(?:\n|$))|~{3,})([^\n]*)(?:\n|$)(?:|([\s\S]*?)(?:\n|$))(?: {0,3}(?:(?=`)\1`*|(?=~)\1~*) *(?=\n|$)|$)/,lc=/^ {0,3}((?:-[\t ]*){3,}|(?:_[ \t]*){3,}|(?:\*[ \t]*){3,})(?:\n+|$)/,xP=/^ {0,3}(#{1,6})(?=\s|$)(.*)(?:\n+|$)/,Cy=/ {0,3}(?:[*+-]|\d{1,9}[.)])/,xE=/^(?!bull |blockCode|fences|blockquote|heading|html|table)((?:.|\n(?!\s*?\n|bull |fences|blockquote|heading|hr|html|table))+?)\n {0,3}(=+|-+)[ \t]*(?:\n+|$)/,_E=Oe(xE).replace(/bull/g,Cy).replace(/blockCode/g,/(?: {4}| {0,3}\t)/).replace(/fences/g,/ {0,3}(?:`{3,}|~{3,})/).replace(/blockquote/g,/ {0,3}>/).replace(/heading/g,/ {0,3}#{1,6}(?:\s|$)/).replace(/hr/g,/ {0,3}(?:(?:-[\t ]*){3,}|(?:_[ \t]*){3,}|(?:\*[ \t]*){3,})(?:\n+|$)/).replace(/html/g,/ {0,3}<[^\n>]+>\n/).replace(/\|table/g,"").getRegex(),_P=Oe(xE).replace(/bull/g,Cy).replace(/blockCode/g,/(?: {4}| {0,3}\t)/).replace(/fences/g,/ {0,3}(?:`{3,}|~{3,})/).replace(/blockquote/g,/ {0,3}>/).replace(/heading/g,/ {0,3}#{1,6}(?:\s|$)/).replace(/hr/g,/ {0,3}(?:(?:-[\t ]*){3,}|(?:_[ \t]*){3,}|(?:\*[ \t]*){3,})(?:\n+|$)/).replace(/html/g,/ {0,3}<[^\n>]+>\n/).replace(/table/g,/ {0,3}\|?(?:[:\- ]*\|)+[\:\- ]*\n/).getRegex(),zy=/^([^\n]+(?:\n(?!hr|heading|lheading|blockquote|fences|list|html|table|[ \t]+\n)[^\n]+)*)/,$P=/^[^\n]+/,Ay=/(?!\s*\])(?:\\[\s\S]|[^\[\]\\\n]|\n(?![ \t]*\n))+/,SP=Oe(/^ {0,3}\[(label)\]: *(?:\n[ \t]*)?([^<\s][^\s]*|<.*?>)(?:(?: +(?:\n[ \t]*)?| *\n[ \t]*)(title))? *(?:\n+|$)/).replace("label",Ay).replace("title",/(?:"(?:\\[\s\S]|[^"\\])*"|'(?:\\[\s\S]|[^'\\\n]|\n(?!\n))*'|\((?:\\[\s\S]|[^()\\])*\))/).getRegex(),IP=Oe(/^(bull)([ \t][^\n]*?)?(?:\n|$)/).replace(/bull/g,Cy).getRegex(),cc="address|article|aside|base|basefont|blockquote|body|caption|center|col|colgroup|dd|details|dialog|dir|div|dl|dt|fieldset|figcaption|figure|footer|form|frame|frameset|h[1-6]|head|header|hr|html|iframe|legend|li|link|main|menu|menuitem|meta|nav|noframes|ol|optgroup|option|p|param|search|section|summary|table|tbody|td|tfoot|th|thead|title|tr|track|ul",Oy=/<!--(?:-?>|[\s\S]*?(?:-->|$))/,EP=Oe("^ {0,3}(?:<(script|pre|style|textarea)[\\s>][\\s\\S]*?(?:</\\1>[^\\n]*\\n*|$)|comment[^\\n]*(\\n+|$)|<\\?[\\s\\S]*?(?:\\?>[^\\n]*\\n*|$)|<![A-Z][\\s\\S]*?(?:>[^\\n]*\\n*|$)|<!\\[CDATA\\[[\\s\\S]*?(?:\\]\\]>[^\\n]*\\n*|$)|</?(tag)(?:[ \\t]+|\\n|/?>|$)[\\s\\S]*?(?:(?:\\n[ ]*)+\\n|$)|<(?!(?:script|pre|style|textarea)(?![a-z0-9-]))([a-z][a-z0-9-]*)(?:attribute)*? */?>(?=[ \\t]*(?:\\n|$))[\\s\\S]*?(?:(?:\\n[ ]*)+\\n|$)|</[a-z][a-z0-9-]*\\s*>(?=[ \\t]*(?:\\n|$))[\\s\\S]*?(?:(?:\\n[ ]*)+\\n|$))","i").replace("comment",Oy).replace("tag",cc).replace("attribute",/ +[a-zA-Z:_][\w.:-]*(?: *= *"[^"\n]*"| *= *'[^'\n]*'| *= *[^\s"'=<>`]+)?/).getRegex(),$E=e=>Oe(zy).replace("hr",lc).replace("heading"," {0,3}#{1,6}(?:\\s|$)").replace("|lheading","").replace("|table","").replace("blockquote"," {0,3}>").replace("fences"," {0,3}(?:`{3,}(?=[^`\\n]*(?:\\n|$))|~~~)[^\\n]*(?:\\n|$)").replace("list",e).replace("html"," {0,3}(?:</?(?:tag)(?: +|\\n|/?>)|<(?:(?:script|pre|style|textarea)(?:[\\s>]|$)|!--)|<\\?|<![A-Za-z]|<!\\[CDATA\\[)").replace("tag",cc).getRegex(),TP=$E(/ {0,3}(?:[*+-]|1[.)])[ \t]+[^ \t\n]/),NP=$E(/ {0,3}(?:[*+-]|\d{1,9}[.)])(?:[ \t]|\n|$)/),Dy={blockquote:Oe(/^( {0,3}> ?(?:(?![ \t]*(?:\n|$))(paragraph)|[^\n]*)(?:\n|$))+/).replace("paragraph",NP).getRegex(),code:wP,def:SP,fences:kP,heading:xP,hr:lc,html:EP,lheading:_E,list:IP,newline:yP,paragraph:TP,table:go,text:$P},YI=Oe("^ *([^\\n ].*)\\n {0,3}((?:\\| *)?:?-+:? *(?:\\| *:?-+:? *)*(?:\\| *)?)(?:\\n((?:(?! *\\n|hr|heading|blockquote|code|fences|list|html).*(?:\\n|$))*)\\n*|$)").replace("hr",lc).replace("heading"," {0,3}#{1,6}(?:\\s|$)").replace("blockquote"," {0,3}>").replace("code","(?: {4}| {0,3} )[^\\n]").replace("fences"," {0,3}(?:`{3,}(?=[^`\\n]*(?:\\n|$))|~~~)[^\\n]*(?:\\n|$)").replace("list"," {0,3}(?:[*+-]|1[.)])[ \\t]").replace("html"," {0,3}(?:</?(?:tag)(?: +|\\n|/?>)|<(?:(?:script|pre|style|textarea)(?:[\\s>]|$)|!--)|<\\?|<![A-Za-z]|<!\\[CDATA\\[)").replace("tag",cc).getRegex(),CP={...Dy,lheading:_P,table:YI,paragraph:Oe(zy).replace("hr",lc).replace("heading"," {0,3}#{1,6}(?:\\s|$)").replace("|lheading","").replace("table",YI).replace("blockquote"," {0,3}>").replace("fences"," {0,3}(?:`{3,}(?=[^`\\n]*(?:\\n|$))|~~~)[^\\n]*(?:\\n|$)").replace("list"," {0,3}(?:[*+-]|1[.)])[ \\t]+[^ \\t\\n]").replace("html"," {0,3}(?:</?(?:tag)(?: +|\\n|/?>)|<(?:(?:script|pre|style|textarea)(?:[\\s>]|$)|!--)|<\\?|<![A-Za-z]|<!\\[CDATA\\[)").replace("tag",cc).getRegex()},zP={...Dy,html:Oe(`^ *(?:comment(?: *\\n|\\s*$)|<(tag)[\\s\\S]+?</\\1>(?: *\\n{2,}|\\s*$)|<tag(?:"[^"]*"|'[^']*'|\\s[^'"/>\\s]*)*?/?>(?: *\\n{2,}|\\s*$))`).replace("comment",Oy).replace(/tag/g,"(?!(?:a|em|strong|small|s|cite|q|dfn|abbr|data|time|code|var|samp|kbd|sub|sup|i|b|u|mark|ruby|rt|rp|bdi|bdo|span|br|wbr|ins|del|img)\\b)\\w+(?!:|[^\\w\\s@]*@)\\b").getRegex(),def:/^ *\[([^\]]+)\]: *<?([^\s>]+)>?(?: +(["(][^\n]+[")]))? *(?:\n+|$)/,heading:/^(#{1,6})(.*)(?:\n+|$)/,fences:go,lheading:/^(.+?)\n {0,3}(=+|-+) *(?:\n+|$)/,paragraph:Oe(zy).replace("hr",lc).replace("heading",` *#{1,6} *[^
|
|
103
|
-
]`).replace("lheading",_E).replace("|table","").replace("blockquote"," {0,3}>").replace("|fences","").replace("|list","").replace("|html","").replace("|tag","").getRegex()},
|
|
102
|
+
`)}function aE(e,t,n,i){if(!t.includes("<"))return!1;for(let r=0;r<t.length;r++){if(t[r]==="\\"){r++;continue}if(t[r]==="`"){let s=i.inline.code.exec(t.slice(r));if(s){r+=s[0].length-1;continue}}if(t[r]!=="<")continue;let o=e.slice(n+r),a=i.inline.tag.exec(o)||i.inline.autolink.exec(o);if(a){if(a[0].length>t.length-r)return!0;r+=a[0].length-1}}return!1}function bR(e,t){let n=e.includes("*")||e.includes("_")||e.includes("~")||this.options.hooks?.emStrongMask||this.tokenizer.emStrong!==Ya.prototype.emStrong||this.tokenizer.del!==Ya.prototype.del?Sy(oc,this,wR).call(this,e):e;mR(this.tokenizer,n);try{return Sy(oc,this,yR).call(this,e,n,t)}finally{fR(this.tokenizer)}}function yR(e,t,n){let i=!1,r="",o=1/0;for(;e;){if(e.length<o)o=e.length;else{this.infiniteLoopError(e.charCodeAt(0));break}i||(r=""),i=!1;let a;if(this.options.extensions?.inline?.some(l=>(a=l.call({lexer:this},e,n))?(e=e.substring(a.raw.length),n.push(a),!0):!1))continue;if((a=this.tokenizer.escape(e))||(a=this.tokenizer.tag(e))||(a=this.tokenizer.link(e))){e=e.substring(a.raw.length),n.push(a);continue}if(a=this.tokenizer.reflink(e,this.tokens.links)){e=e.substring(a.raw.length);let l=n.at(-1);a.type==="text"&&l?.type==="text"?(l.raw+=a.raw,l.text+=a.text):n.push(a);continue}if((a=this.tokenizer.emStrong(e,t,r))||(a=this.tokenizer.codespan(e))||(a=this.tokenizer.br(e))||(a=this.tokenizer.del(e,t,r))||(a=this.tokenizer.autolink(e))||!this.state.inLink&&(a=this.tokenizer.url(e))){e=e.substring(a.raw.length),n.push(a);continue}let s=e;if(this.options.extensions?.startInline){let l=1/0,u=e.slice(1),d;this.options.extensions.startInline.forEach(p=>{d=p.call({lexer:this},u),typeof d=="number"&&d>=0&&(l=Math.min(l,d))}),l<1/0&&l>=0&&(s=e.substring(0,l+1))}if(a=this.tokenizer.inlineText(s)){e=e.substring(a.raw.length),a.raw.slice(-1)!=="_"&&(r=a.raw.slice(-1)),i=!0;let l=n.at(-1);l?.type==="text"?(l.raw+=a.raw,l.text+=a.text):n.push(a)}else if(e){this.infiniteLoopError(e.charCodeAt(0));break}}return n}function wR(e){let t=e;if(this.tokens.links&&e.includes("[")){let n=this.tokenizer.rules.inline.reflinkSearch,i=r=>{let o=r.lastIndexOf("[");if(!Object.hasOwn(this.tokens.links,Dp(r.slice(o+1,-1))))return r;if(o>1&&r.charAt(0)!=="!"){let a=r.slice(1,o-1);if(this.linkInText(a))return"["+a.replace(n,i)+"]["+"a".repeat(r.length-o-2)+"]"}return"["+"a".repeat(r.length-2)+"]"};t=t.replace(n,i)}return t=t.replace(this.tokenizer.rules.inline.anyPunctuationOutsideCode,(n,i,r)=>r?"+".repeat(n.length):i?i+n.slice(i.length,-i.length).replace(/`/g,"+")+i:n),t=t.replace(this.tokenizer.rules.inline.blockSkip,(n,i,r)=>{let o=r?r.length:0;return n.slice(0,o)+"["+"a".repeat(n.length-o-2)+"]"}),t=this.options.hooks?.emStrongMask?.call({lexer:this},t)??t,t}function Ci(e,t){if(Array.isArray(t))for(let n=0;n<t.length;n++)e.push(t[n]);else e.push(t)}function et(e,t){return vo.parse(e,t)}function xR(...e){return vo.use(...e),et.defaults=vo.defaults,wE(et.defaults),et}function NR(e){let{orientation:t,maxRows:n,maxWidth:i}=e;if(t==="horizontal"||!i)return sE;let r=i-28-(n-1)*Ka;return Math.min(TR,Math.max(sE,Math.floor(r/n)))}function CR(e){return e.layout==="left-to-right"||e.layout==="radial"?"horizontal":e.layout==="top-to-bottom"?"vertical":e.diagramType==="sequence"?"horizontal":"vertical"}function zR(e){let t=new Set(e.nodes.map(a=>a.id)),n=new Set(e.edges.map(a=>a.to)),i=e.nodes.map(a=>a.id).filter(a=>!n.has(a)),r=new Map;for(let a of i.length?i:e.nodes.slice(0,1).map(s=>s.id))r.set(a,0);for(let a=0;a<e.nodes.length;a++){let s=!1;for(let l of e.edges){if(!t.has(l.from)||!t.has(l.to))continue;let u=r.get(l.from);if(u===void 0)continue;let d=u+1;(r.get(l.to)??-1)<d&&(r.set(l.to,d),s=!0)}if(!s)break}let o=Math.max(0,...r.values());for(let a of e.nodes)r.has(a.id)||r.set(a.id,++o);return r}function AR(e,t){let n=cE(e,CR(e),t?.maxWidth);return t?.maxWidth&&n.orientation==="horizontal"&&n.width>t.maxWidth?cE(e,"vertical",t.maxWidth):n}function cE(e,t,n){let i=zR(e),r=new Map;for(let f of e.nodes){let h=i.get(f.id)??0;r.set(h,[...r.get(h)??[],f])}let o=[...r.entries()].sort(([f],[h])=>f-h),a=Math.max(1,...o.map(([,f])=>f.length)),s=Math.max(1,o.length),l=NR({orientation:t,maxRows:a,...n===void 0?{}:{maxWidth:n}}),u=t==="horizontal"?28+s*l+(s-1)*Ka:28+a*l+(a-1)*Ka,d=t==="horizontal"?28+a*vy+(a-1)*lE:28+s*vy+(s-1)*lE,p=[];for(let[f,[,h]]of o.entries()){let v=(a-h.length)*(t==="horizontal"?86:l+Ka)/2;for(let[k,T]of h.entries()){let S=t==="horizontal"?Np+f*(l+Ka):Np+v+k*(l+Ka),z=t==="horizontal"?Np+v+k*86:Np+f*86;p.push({id:T.id,label:T.label,...T.detail?{detail:T.detail}:{},...T.kind?{kind:T.kind}:{},x:S,y:z,width:l,height:vy})}}let m=new Map(p.map(f=>[f.id,f]));return{width:u,height:d,orientation:t,nodes:p,edges:e.edges.flatMap((f,h)=>{let v=m.get(f.from),k=m.get(f.to);if(!v||!k)return[];let T=t==="horizontal"?v.x+v.width:v.x+v.width/2,S=t==="horizontal"?v.y+v.height/2:v.y+v.height,z=t==="horizontal"?k.x:k.x+k.width/2,j=t==="horizontal"?k.y+k.height/2:k.y;return[{key:`${f.from}-${f.to}-${h}`,from:f.from,to:f.to,...f.label?{label:f.label}:{},x1:T,y1:S,x2:z,y2:j,labelX:(T+z)/2,labelY:(S+j)/2}]})}}function CE(e){let{value:t}=e,n=Math.abs(t);return n>=1e6?`${(t/1e6).toFixed(1).replace(/\.0$/,"")}M`:n>=1e3?`${(t/1e3).toFixed(1).replace(/\.0$/,"")}k`:Number.isInteger(t)?`${t}`:t.toFixed(1)}function zE(e){let{seconds:t}=e,n=Math.round(Math.abs(t)),i=t<0?"-":"";if(n<60)return`${i}${n}s`;if(n<3600){let a=Math.floor(n/60),s=n%60;return s?`${i}${a}m ${s}s`:`${i}${a}m`}let r=Math.floor(n/3600),o=Math.floor(n%3600/60);return o?`${i}${r}h ${o}m`:`${i}${r}h`}function AE(e){return{prefix:e?.valuePrefix??(e?.valueFormat==="currency"?"$":""),suffix:e?.valueSuffix??(e?.valueFormat==="percent"?"%":"")}}function by(e){let{value:t,series:n}=e,{prefix:i,suffix:r}=AE(n),o;switch(n?.valueFormat){case"integer":o=`${Math.round(t)}`;break;case"duration":o=zE({seconds:t});break;case"raw":o=Number.isInteger(t)?`${t}`:t.toFixed(1);break;default:o=CE({value:t})}return`${i}${o}${r}`}function OR(e){let[t,...n]=e.series;if(t)return n.every(i=>i.valueFormat===t.valueFormat&&i.valuePrefix===t.valuePrefix&&i.valueSuffix===t.valueSuffix)?t:void 0}function DR(e){let{value:t,shared:n}=e;if(n?.valueFormat==="duration")return zE({seconds:t});let{prefix:i,suffix:r}=AE(n);return`${i}${CE({value:t})}${r}`}function MR(e){let{labels:t,plotWidth:n}=e;if(!t.length||n<=0)return{mode:"horizontal",entries:[]};let i=t.map(l=>l.length>jR?`${l.slice(0,15).trimEnd()}\u2026`:l),r=t.length-1;if(r===0)return{mode:"horizontal",entries:[{index:0,text:i[0]}]};if((Math.max(...i.map(l=>l.length*PR))+RR)*t.length<=n)return{mode:"horizontal",entries:i.map((l,u)=>({index:u,text:l}))};let o=Math.max(2,Math.floor(n/UR));if(t.length<=o)return{mode:"angled",entries:i.map((l,u)=>({index:u,text:l}))};let a=new Set([0,r]),s=r/(o-1);for(let l=1;l<o-1;l++)a.add(Math.round(l*s));return{mode:"angled",entries:[...a].sort((l,u)=>l-u).map(l=>({index:l,text:i[l]}))}}function ej(e){return e&&XU[e]||QU}function mj(e){return e.hadError?"error":e.sessionState==="live"?e.speaking.bot?"speaking":e.speaking.user?"listening":e.work.active?"working":e.providerThinking?"thinking":"listening":"connecting"}function fj(e){let t=mj(e),n=pj[t],i=t==="working"?e.work.description||"Working on it":n.label,r=t==="working"?i:n.visibleText??"",o=e.takingLonger&&(t==="thinking"||t==="working"),a=o?`${r} ${fo.slowHint}`:r;return{activity:t,label:o?a:i,tone:e.isMuted&&t==="listening"?"bg-theme-400":n.tone,visibleStatus:a,usesIdleWave:n.waits||e.isMuted&&t==="listening",takingLonger:o}}var Up,s5,l5,zp,m5,f5,fo,uE,g5,v5,ay,sc,w5,Xa,k5,jp,x5,Mp,_5,$5,S5,I5,E5,Lp,N5,C5,z5,A5,xy,O5,D5,P5,R5,U5,j5,M5,L5,sy,mE,UI,W5,fE,hE,Zt,Qt,Ha,gE,_y,$y,ei,q5,jI,Xl,G5,J5,Ga,ly,cy,Ql,ho,uy,MI,ec,LI,Y5,X5,Q5,VI,FI,Ir,tc,Xt,ti,BI,dy,py,iP,my,oP,ZI,HI,fy,KI,Sp,aP,sP,lP,cP,uP,WI,dP,pP,mP,fP,hy,qI,hP,GI,At,gP,vP,bP,JI,Ni,gy,yE,oc,Ip,bo,go,kE,jt,kP,xP,_P,lc,$P,Cy,xE,_E,SP,zy,IP,Ay,EP,TP,cc,Oy,NP,$E,CP,zP,Dy,YI,AP,OP,DP,PP,SE,RP,Cn,Qa,uc,UP,jP,IE,MP,LP,VP,EE,FP,BP,ZP,TE,HP,KP,WP,qP,GP,JP,YP,XP,QP,eR,tR,rR,NE,Op,nR,iR,oR,XI,aR,sR,QI,lR,Py,cR,Iy,uR,Ep,rc,dR,eE,Ja,Ya,cn,Pp,Uy,un,ic,kR,vo,_R,$R,SR,IR,ER,sE,vy,Np,Ka,lE,TR,PR,RR,UR,jR,LR,VR,FR,BR,ZR,HR,KR,WR,qR,GR,JR,YR,XR,QR,eU,tU,rU,nU,iU,oU,aU,sU,lU,cU,uU,dU,pU,mU,fU,hU,gU,Wa,vU,bU,yU,wU,kU,xU,_U,$U,SU,IU,EU,TU,NU,CU,zU,AU,OU,DU,PU,RU,UU,jU,jy,MU,LU,VU,FU,BU,ZU,HU,KU,WU,qU,GU,JU,YU,XU,QU,Rp,OE,tj,rj,nj,ij,oj,aj,sj,lj,cj,yy,uj,dj,pj,hj,gj,vj,bj,yj,wj,kj,xj,_j,$j,Sj,Ij,Ej,Tj,Nj,Cj,zj,Aj,Oj,Dj,Pj,Rj,Uj,jj,Mj,Lj,Vj,Fj,Bj,Zj,Hj,Kj,Wj,qj,Gj,Jj,Yj,Xj,Qj,eM,tM,rM,nM,iM,oM,aM,sM,lM,cM,uM,dM,pM,mM,fM,hM,gM,vM,bM,yM,wM,kM,xM,_M,$M,SM,yo,IM,EM,TM,Vp,Fp=re(()=>{"use strict";Pn();oy();ql();En();Up=ew((e,t)=>{let n=e.__vccOpts||e;for(let[i,r]of t)n[i]=r;return n},"default"),s5={},l5={class:"spinner max-w-sm"};zp=Up(s5,[["render",c5]]);m5=400,f5=class extends uo{constructor(e){super("VoiceRecorderController",e),G(this,"state",Q({phase:"idle",elapsedMs:0})),G(this,"isActive",R(()=>this.state.value.phase!=="idle")),G(this,"isBusy",R(()=>this.state.value.phase!=="idle")),G(this,"elapsedLabel",R(()=>u5({ms:this.state.value.elapsedMs}))),G(this,"statusText",R(()=>this.state.value.phase==="preparing"?"Starting microphone":this.state.value.phase==="sending"?"Sending voice message":"Release to send")),G(this,"recorder",void 0),G(this,"stream",void 0),G(this,"chunks",[]),G(this,"timer",void 0),G(this,"startedAt",0),G(this,"cancelOnStop",!1),G(this,"stopAfterStart",!1),G(this,"startToken",0)}get canUseBrowserRecording(){return!!this.settings.getUserMedia||typeof navigator<"u"&&!!navigator.mediaDevices?.getUserMedia&&typeof MediaRecorder<"u"}async start(){if(!this.settings.getCanRecord()||this.state.value.phase!=="idle")return;if(!this.canUseBrowserRecording){this.settings.getChatController()?.notify("Voice recording is not available in this browser.");return}this.state.value={phase:"preparing",elapsedMs:0},this.cancelOnStop=!1;let e=++this.startToken;try{let t=await this.getUserMedia({constraints:{audio:!0}});if(e!==this.startToken){t.getTracks().forEach(r=>r.stop());return}let n=p5(),i=this.createRecorder({stream:t,mimeType:n});this.stream=t,this.recorder=i,this.chunks=[],i.addEventListener("dataavailable",r=>{r.data.size>0&&this.chunks.push(r.data)}),i.addEventListener("stop",async()=>{let r=new Blob(this.chunks,{type:i.mimeType||n||"audio/webm"}),o=this.now()-this.startedAt,a=!this.cancelOnStop&&r.size>0&&o>=m5;this.stopCapture(),a&&(this.state.value={phase:"sending",elapsedMs:this.state.value.elapsedMs},await this.sendBlob({blob:r})),this.reset()}),i.start(),this.startedAt=this.now(),this.state.value={phase:"recording",elapsedMs:0},this.timer=this.setInterval(()=>{this.state.value={phase:"recording",elapsedMs:this.now()-this.startedAt}},250),this.stopAfterStart&&this.finish({cancelled:this.cancelOnStop})}catch(t){if(e!==this.startToken)return;this.teardown();let n=t instanceof Error?t.message:"Microphone access failed.";this.settings.getChatController()?.notify(`Voice recording failed \u2014 ${n}`)}}finish(e){this.state.value.phase!=="idle"&&this.state.value.phase!=="sending"&&(this.state.value.phase==="preparing"?(this.stopAfterStart=!0,this.cancelOnStop=e.cancelled):!this.recorder||this.recorder.state!=="recording"?this.teardown():(this.cancelOnStop=e.cancelled,this.recorder.stop()))}teardown(){this.cancelOnStop=!0,this.startToken+=1,this.recorder?.state==="recording"&&this.recorder.stop(),this.stopCapture(),this.reset()}async getUserMedia(e){return(this.settings.getUserMedia||navigator.mediaDevices.getUserMedia.bind(navigator.mediaDevices))(e.constraints)}createRecorder(e){return this.settings.createRecorder?this.settings.createRecorder(e):e.mimeType?new MediaRecorder(e.stream,{mimeType:e.mimeType}):new MediaRecorder(e.stream)}async sendBlob(e){let t=this.settings.getUploadFn(),n=this.settings.getChatController();if(!t||!n)return;let i=e.blob.type||"audio/webm",r=new File([e.blob],`voice-${new Date().toISOString().replace(/[:.]/g,"-")}.${d5({mimeType:i})}`,{type:i});try{let o=await t(r);this.settings.onBeforeSend?.(),await n.sendChatMessage("",[o])}catch(o){let a=o instanceof Error?o.message:"Couldn't send that recording.";n.notify(`Voice message failed \u2014 ${a}`)}}stopCapture(){this.timer&&(this.clearInterval(this.timer),this.timer=void 0),this.stream?.getTracks().forEach(e=>e.stop()),this.stream=void 0,this.recorder=void 0,this.chunks=[],this.stopAfterStart=!1}reset(){this.state.value={phase:"idle",elapsedMs:0}}now(){return this.settings.now?.()??Date.now()}setInterval(e,t){return this.settings.setInterval?.(e,t)??setInterval(e,t)}clearInterval(e){(this.settings.clearInterval??clearInterval)(e)}};fo={finishing:"Finishing up",slowHint:"Taking longer than usual.",completed:"Work complete",failed:"Couldn\u2019t finish",stopped:"Stopped",notifyHint:"Taking longer than usual. You can leave and I\u2019ll notify you when it\u2019s ready.",leaveHint:"Taking longer than usual. You can leave this chat while I work."},uE=1e4,g5=15e3,v5=6e4,ay=3;sc=class extends uo{isQueuedMessage(e){return this.queuedMessageIdSet.value.has(e)}consumeQueuedThrough(e){if(!e||this.queuedMessageIdSet.value.size===0)return;let t=new Set(this.queuedMessageIdSet.value),n=this.sharedMessages.value.findIndex(i=>i.id===e);n<0?t.delete(e):this.sharedMessages.value.slice(0,n+1).forEach(i=>t.delete(i.id)),this.queuedMessageIdSet.value=t}get activeConversationId(){return this.conversationId}createVoiceClient(e){let{sdk:t,createVoiceClientFn:n}=this.settings,i=this._bot.botId.value,r=this._bot.orgId.value;if(t?.activeUser.value&&i&&r)return n?.({botId:i,orgId:r,conversationId:this.conversationId,handlers:e})}async refreshMessages(){await this.settings.refreshMessagesFn?.()}constructor(e){super("BotChatController",e),G(this,"isTextMode",!1),G(this,"lastMessage",{hash:"",time:0}),G(this,"isConnecting",!1),G(this,"turnEpoch",0),G(this,"nextStreamToken",0),G(this,"runningStreamToken",void 0),G(this,"suppressedStreamTokens",new Set),G(this,"queuedMessageIdSet",Q(new Set)),G(this,"queuedMessageIds",R(()=>this.queuedMessageIdSet.value)),G(this,"boundaryTimer",void 0),G(this,"nowMs",We(Date.now())),G(this,"toolActivityTiming",We({})),G(this,"lastVisibleProgressAtMs",We()),G(this,"liveSegments",We([])),G(this,"liveStreamMessageId",We(void 0)),G(this,"conversationId",void 0),G(this,"textState",Q({isActive:!1,isConnected:!1,isThinking:!1,connectionStatus:"disconnected"})),G(this,"botMode",Q("self")),G(this,"sharedMessages",Q([])),G(this,"composerState",Q({text:"",pendingAttachments:[],isUploading:!1})),G(this,"workJournal",R(()=>{let t=this.textState.value.isThinking?"running":this.textState.value.turnOutcome;if(!t)return;let n=this.textState.value.toolActivities;if(n?.length)return ky({activities:n,outcome:t,nowMs:this.nowMs.value,canNotifyOnCompletion:!1,lastVisibleProgressAtMs:this.lastVisibleProgressAtMs.value})})),G(this,"liveTurnBlocks",R(()=>{if(!this.textState.value.isThinking)return[];let t=this.textState.value.toolActivities??[],n=this.liveSegments.value;return!n.length&&!t.length?[]:b5({segments:n,activities:t,nowMs:this.nowMs.value,canNotifyOnCompletion:!1,lastVisibleProgressAtMs:this.lastVisibleProgressAtMs.value})})),G(this,"canUseComposer",R(()=>this.textState.value.sendBlockedReason!=="bot_deleted"&&!this.composerState.value.isUploading)),G(this,"canAttachFile",R(()=>!!this.settings.uploadFileFn)),G(this,"canRecordAudio",R(()=>this.canAttachFile.value&&this.canUseComposer.value&&!this.composerState.value.text.trim()&&this.composerState.value.pendingAttachments.length===0)),G(this,"voiceRecorder",new f5({getCanRecord:()=>this.canRecordAudio.value,getUploadFn:()=>{let t=this.settings.uploadFileFn;return t?n=>t({file:n}):void 0},getChatController:()=>this})),G(this,"canSend",R(()=>(this.composerState.value.text.trim().length>0||this.composerState.value.pendingAttachments.length>0)&&this.canUseComposer.value&&!this.voiceRecorder.isBusy.value)),G(this,"canStop",R(()=>this.textState.value.isThinking&&!this.composerState.value.isUploading&&!this.voiceRecorder.isBusy.value)),G(this,"composerAction",R(()=>this.canSend.value?"send":this.canStop.value?"stop":"idle")),G(this,"composerShowsSecondaryStop",R(()=>this.canStop.value&&this.composerAction.value==="send")),G(this,"canStartVoice",R(()=>{let t=this.settings.sdk;return this.textState.value.sendBlockedReason!=="bot_deleted"&&!!t?.activeUser.value&&!!this._bot.botId.value&&!!this._bot.orgId.value&&!!this.settings.createVoiceClientFn&&y5()})),G(this,"_bot",void 0),G(this,"localMessageSeq",0),this._bot=e.bot,this.setupModeWatcher(),this.setupAvailabilityWatcher(),this.setupBoundaryWatcher()}get chatEnabled(){let e=this._bot.state.value.lifecycle;return this._bot.lifecycle.value===void 0?this._bot.desiredStatus.value==="active":e==="running"}get chatUnavailableReason(){if(this.chatEnabled)return;let e=this._bot.displayName.value,t=this._bot.state.value.lifecycle;return t==="starting"?`${e} is waking up`:t==="stopped"?`${e} is asleep`:this._bot.desiredStatus.value==="active"?`${e} is unavailable`:`${e} is offline`}isDuplicateMessage(e,t){let n=`${t}:${e.toLowerCase().trim()}`,i=Date.now(),r=n===this.lastMessage.hash&&i-this.lastMessage.time<500;return r||(this.lastMessage={hash:n,time:i}),r}addMessage(e,t,n,i){this.isDuplicateMessage(e,t)||(this.sharedMessages.value=[...this.sharedMessages.value,{id:this.nextLocalMessageId(),text:e,sender:t,timestamp:new Date().toISOString(),attachments:n,...i}])}nextLocalMessageId(){return`${Date.now()}-${++this.localMessageSeq}`}notify(e,t){e&&this.addMessage(e,"system",void 0,t)}get messageShare(){return this.settings.messageShareFns}get canReportMessages(){return!!this.settings.reportMessageFn}async reportMessage(e){let t=this.settings.reportMessageFn;if(t)try{await t({messageId:e}),this.notify("Reported. Our team will review this message.")}catch(n){this.logger.warn("reportMessage failed",{messageId:e,error:n instanceof Error?n.message:String(n)}),this.notify("Could not report that message.")}}setComposerText(e){this.composerState.value={...this.composerState.value,text:e.text}}async attachFile(e){let t=this.settings.uploadFileFn;if(t&&!this.voiceRecorder.isBusy.value){this.composerState.value={...this.composerState.value,isUploading:!0};try{let n=await t({file:e.file});this.composerState.value={...this.composerState.value,pendingAttachments:[...this.composerState.value.pendingAttachments,n]}}catch(n){let i=n instanceof Error?n.message:"Couldn't attach that file.";this.notify(`Upload failed \u2014 ${i}`)}finally{this.composerState.value={...this.composerState.value,isUploading:!1}}}}removeAttachment(e){this.composerState.value={...this.composerState.value,pendingAttachments:this.composerState.value.pendingAttachments.filter((t,n)=>n!==e.index)}}addOfflineSystemReply(){let e=this._bot.displayName.value||"Your assistant",t=this._bot.state.value.blocker;if(t){let s=t.actionUrl.startsWith("pagelines://")?this.settings.billingUrl:t.actionUrl,l=[`${t.title}.${t.help?` ${t.help}`:""}`,t.actionLabel&&s?`[${t.actionLabel}](${s})`:t.actionLabel||""].filter(Boolean).join(" "),u=this.sharedMessages.value[this.sharedMessages.value.length-1];if(u?.sender==="system"&&u.text===l)return;this.addMessage(l,"system");return}let n=this.chatUnavailableReason??`${e} is unavailable`,i=this._bot.state.value.lifecycle==="stopped"||this._bot.desiredStatus.value!=="active",r=this.settings.manageUrl,o=i?r?`${n}, so your message can't be answered yet. [Wake ${e}](${r}), then send again.`:`${n}, so your message can't be answered yet. Wake it from the dashboard, then send again.`:`${n}. Give it a moment and send again.`,a=this.sharedMessages.value[this.sharedMessages.value.length-1];(a?.sender!=="system"||a.text!==o)&&this.addMessage(o,"system")}async sendComposerMessage(){if(!this.canSend.value)return;let e=this.composerState.value.text,t=this.composerState.value.pendingAttachments.length>0?[...this.composerState.value.pendingAttachments]:void 0;this.chatEnabled?(this.composerState.value={...this.composerState.value,text:"",pendingAttachments:[]},await this.sendChatMessage(e,t)):this.addOfflineSystemReply()}async handleComposerAction(){this.composerAction.value==="stop"?await this.stopChatTurn():this.composerAction.value==="send"&&await this.sendComposerMessage()}getDynamicSettings(){return{context:this.settings.context||"",firstMessage:this.settings.firstMessage||""}}updateState(e,t){e.value={...e.value,...t}}resetWorkJournalTiming(){this.toolActivityTiming.value={},this.lastVisibleProgressAtMs.value=void 0,this.liveSegments.value=[],this.liveStreamMessageId.value=void 0,this.clearBoundaryTimer()}resetState(){this.resetWorkJournalTiming(),this.updateState(this.textState,{isActive:!1,isConnected:!1,isThinking:!1,connectionStatus:"disconnected",error:void 0,sendBlockedReason:void 0,workingDescription:void 0,toolActivities:void 0,turnOutcome:void 0})}setupBoundaryWatcher(){mt(()=>this.workJournal.value?.nextBoundaryAtMs,e=>{this.scheduleBoundary(e)})}scheduleBoundary(e){if(this.clearBoundaryTimer(),e===void 0)return;let t=Math.max(0,e-Date.now());this.boundaryTimer=setTimeout(()=>{this.boundaryTimer=void 0,this.nowMs.value=Date.now()},t),this.boundaryTimer.unref?.()}clearBoundaryTimer(){this.boundaryTimer&&(clearTimeout(this.boundaryTimer),this.boundaryTimer=void 0)}rememberToolActivity(e){let t=_p(e.startedAt)??this.toolActivityTiming.value[e.activityId]?.startedAt??(e.status==="started"?Date.now():void 0),n=_p(e.endedAt)??this.toolActivityTiming.value[e.activityId]?.endedAt??(e.status==="started"?void 0:Date.now());t&&(this.toolActivityTiming.value={...this.toolActivityTiming.value,[e.activityId]:{startedAt:t,...n?{endedAt:n}:{}}})}withToolActivityTiming(e){let t=this.toolActivityTiming.value[e.activityId],n=Date.now(),i=_p(e.startedAt)??t?.startedAt??(e.status==="started"?n:void 0),r=_p(e.endedAt)??t?.endedAt??(e.status==="started"?void 0:n);return{...e,...i!==void 0&&!e.startedAt?{startedAt:new Date(i).toISOString()}:{},...r!==void 0&&!e.endedAt?{endedAt:new Date(r).toISOString()}:{}}}updateToolActivity(e){let t=this.textState.value.toolActivities??[],n=t.findIndex(o=>o.activityId===e.activityId),i=this.withToolActivityTiming({...n>=0?t[n]:{},...e}),r=n>=0?[...t.slice(0,n),i,...t.slice(n+1)]:[...t,i];this.rememberToolActivity(i),this.updateState(this.textState,{toolActivities:r})}finishToolActivities(e){let t=this.textState.value.toolActivities;if(!t?.length)return;let n=t.map(i=>i.status==="started"?this.withToolActivityTiming({...i,status:e}):i);n.forEach(i=>this.rememberToolActivity(i)),this.updateState(this.textState,{toolActivities:n})}workJournalFor(e){if(e.activities?.length)return ky({activities:e.activities,outcome:e.outcome,nowMs:this.nowMs.value,canNotifyOnCompletion:!1,includeFailureNote:e.includeFailureNote})}setupModeWatcher(){mt(this.botMode,async(e,t)=>{this.logger.info(`Mode changed from ${t} to ${e}`),this.isTextMode&&(t==="talk"||t==="chat")&&await this.endConversation()})}setupAvailabilityWatcher(){mt(()=>[this.chatEnabled,this._bot.state.value.lifecycle],([e])=>{this.isTextMode&&!this.isConnecting&&(e?this.textState.value.isConnected||this.updateState(this.textState,{isConnected:!0,connectionStatus:"connected",error:void 0}):this.textState.value.isConnected&&this.updateState(this.textState,{isConnected:!1,connectionStatus:"disconnected",error:this.chatUnavailableReason}))})}handleError(e){let t=e.message;this.logger.error("Conversation error:",{message:t,error:e}),this.addMessage(t,"system"),this.resetState(),this.updateState(this.textState,{error:t,connectionStatus:"error"})}async setMode(e){this.botMode.value!==e&&(this.botMode.value=e)}async startTextConversation(e={}){if(this.isConnecting)this.logger.info("Text conversation already connecting, ignoring duplicate request");else{this.isConnecting=!0,this.isTextMode=!0,this.updateState(this.textState,{isActive:!0,connectionStatus:"connecting"});try{if(!this.chatEnabled){this.isConnecting=!1,this.updateState(this.textState,{isConnected:!1,connectionStatus:"disconnected",error:this.chatUnavailableReason});return}this.isConnecting=!1,this.updateState(this.textState,{isConnected:!0,connectionStatus:"connected"}),e.onConnect?.(),this.logger.info("Text conversation ready")}catch(t){throw this.isConnecting=!1,this.handleError(t),t}}}async endConversation(){if(this.turnEpoch+=1,this.runningStreamToken=void 0,this.suppressedStreamTokens.clear(),this.queuedMessageIdSet.value=new Set,!this.isTextMode)this.resetState();else try{this.conversationId=void 0,this.resetState(),this.isTextMode=!1}catch{this.isTextMode=!1}}async sendChatMessage(e,t){if(!this.isTextMode)return;let{chatStreamFn:n}=this.settings;if(!this.chatEnabled){this.addOfflineSystemReply();return}if(this.textState.value.sendBlockedReason==="bot_deleted")return;let{sdk:i}=this.settings;if(!n&&!this._bot.handle.value){this.handleError(Error("Bot handle required for chat"));return}let r=this.textState.value.isThinking,o=this.sharedMessages.value.length;this.addMessage(e,"user",t);let a=this.sharedMessages.value.length>o?this.sharedMessages.value[this.sharedMessages.value.length-1]?.id:void 0,s=this.turnEpoch,l=++this.nextStreamToken;r&&a?this.queuedMessageIdSet.value=new Set(this.queuedMessageIdSet.value).add(a):(this.runningStreamToken=l,this.resetWorkJournalTiming(),this.updateState(this.textState,{isThinking:!0,workingDescription:void 0,toolActivities:[],transientIssue:void 0,turnOutcome:void 0}));let u=`stream-${Date.now()}-${l}`,d=!1,p=!1,m=()=>s===this.turnEpoch&&!this.suppressedStreamTokens.has(l),f=U=>{if(s!==this.turnEpoch||!a)return;let J=this.sharedMessages.value;if(this.sharedMessages.value=J.some(W=>W.id===U.id)?J.filter(W=>W.id!==a||W.id===U.id):J.map(W=>W.id===a?U:W),this.queuedMessageIdSet.value.has(a)){let W=new Set(this.queuedMessageIdSet.value);W.delete(a),W.add(U.id),this.queuedMessageIdSet.value=W}a=U.id},h=()=>{this.runningStreamToken!==l&&(this.runningStreamToken=l,this.consumeQueuedThrough(a),this.resetWorkJournalTiming(),this.updateState(this.textState,{isThinking:!0,workingDescription:void 0,toolActivities:[],transientIssue:void 0,turnOutcome:void 0}))},v=(U,J="assistant")=>{if(!m())return;h(),this.updateState(this.textState,{workingDescription:void 0}),J==="assistant"&&(this.lastVisibleProgressAtMs.value=Date.now()),d||(d=!0,this.liveStreamMessageId.value=u,this.sharedMessages.value=[...this.sharedMessages.value,{id:u,text:"",sender:J==="system"?"system":"bot",timestamp:new Date().toISOString()}]);let W=this.liveSegments.value,ce=W[W.length-1];this.liveSegments.value=ce?.kind==="text"?[...W.slice(0,-1),{kind:"text",content:ce.content+U}]:[...W,{kind:"text",content:U}];let se=this.sharedMessages.value,pe=se[se.length-1];pe?.id===u&&(pe.text+=U,this.sharedMessages.value=[...se])},k=U=>{if(!m())return;if(h(),p=!0,U.sender==="bot"&&vp(U.text)){this.liveSegments.value=[],this.liveStreamMessageId.value=void 0,this.sharedMessages.value=this.sharedMessages.value.filter(F=>F.id!==u);return}d=!0;let J=U.sender==="system"||U.turnOutcome==="failed"?"failed":"completed";this.finishToolActivities(J);let W=this.textState.value.toolActivities,ce=U.toolActivities?.length||!W?.length?U:{...U,toolActivities:W};this.liveSegments.value=[],this.liveStreamMessageId.value=void 0,this.updateState(this.textState,{workingDescription:void 0,toolActivities:[],turnOutcome:void 0});let se=this.sharedMessages.value.filter(F=>F.id!==u),pe=se.findIndex(F=>F.id===ce.id);pe>=0?this.sharedMessages.value=[...se.slice(0,pe),ce,...se.slice(pe+1)]:this.sharedMessages.value=[...se,ce],ce.sender==="system"&&ce.issue?.bucket==="account"?this.updateState(this.textState,{sendBlockedReason:"account"}):ce.sender==="system"&&ce.issue?.code==="BOT_DELETED"&&this.updateState(this.textState,{sendBlockedReason:"bot_deleted"})},T=U=>{if(!m())return;if(!d&&!p){S(ln("no-reply","Assistant returned no content"));return}this.finishToolActivities("completed");let J=this.sharedMessages.value,W=J[J.length-1];W?.id===u&&W.sender==="bot"&&vp(W.text)&&(this.sharedMessages.value=J.slice(0,-1)),U&&(this.conversationId=U),this.updateState(this.textState,{isThinking:!1,workingDescription:void 0,transientIssue:void 0}),this.settings.onTurnCompleted?.(U)},S=U=>{if(!m())return;if(this.runningStreamToken!==l){this.consumeQueuedThrough(a),this.sharedMessages.value=this.sharedMessages.value.filter(Re=>Re.id!==a),this.composerState.value.text||(this.composerState.value={...this.composerState.value,text:e,pendingAttachments:t??[]});return}this.updateState(this.textState,{workingDescription:void 0,turnOutcome:"failed"}),this.finishToolActivities("failed");let J=this.sharedMessages.value,W=J[J.length-1];W?.id===u&&!W.text&&(this.sharedMessages.value=J.slice(0,-1)),this.logger.warn("Chat turn failed:",U);let{code:ce,bucket:se,message:pe,actionLabel:F,actionUrl:ue,help:Je}=U,ct={...F?{actionLabel:F}:{},...ue?{actionUrl:ue}:{},...Je?{help:Je}:{}},ft=se==="account"?"account":ce==="BOT_DELETED"?"bot_deleted":void 0;ft?(this.addMessage(pe,"system",void 0,{issue:{code:ce,bucket:se,...ct}}),this.updateState(this.textState,{isThinking:!1,sendBlockedReason:ft})):this.updateState(this.textState,{isThinking:!1,transientIssue:{code:ce,message:pe,...ct}})},z=U=>{if(!m())return;h();let J=U.trim();this.updateState(this.textState,{workingDescription:J||void 0})},j=U=>{if(m()){if(h(),this.lastVisibleProgressAtMs.value=Date.now(),U.status==="started"){let J=this.liveSegments.value,W=J[J.length-1];W?.kind==="work"?W.activityIds.includes(U.activityId)||(this.liveSegments.value=[...J.slice(0,-1),{kind:"work",activityIds:[...W.activityIds,U.activityId]}]):this.liveSegments.value=[...J,{kind:"work",activityIds:[U.activityId]}]}this.updateToolActivity(U)}},O=()=>{m()&&this.updateState(this.textState,{workingDescription:void 0})};try{this.settings.onTurnStarted?.(),await(n?n({message:e,attachments:t,conversationId:this.conversationId,history:this.buildHistory(),onDelta:v,onMessage:k,onUserMessage:f,onDone:T,onError:S,onStatus:z,onToolActivity:j,onWorkingEnd:O}):i.chat.chatStreamPublic({handle:this._bot.handle.value,message:e,attachments:t,anonymousId:i.user.generateAnonId(),context:this.getDynamicSettings().context||void 0,onDelta:v,onMessage:k,onDone:T,onError:S,onStatus:z,onToolActivity:j,onWorkingEnd:O}))}catch(U){S(ln("api",U instanceof Error?U.message:"Chat failed","NETWORK_ERROR"))}finally{this.runningStreamToken===l&&(this.runningStreamToken=void 0)}}async stopChatTurn(){if(this.textState.value.isThinking){this.runningStreamToken!==void 0&&this.suppressedStreamTokens.add(this.runningStreamToken),this.runningStreamToken=void 0,this.updateState(this.textState,{isThinking:!1,turnOutcome:"stopped",workingDescription:void 0,transientIssue:void 0});try{await this.settings.cancelChatTurnFn?.({conversationId:this.conversationId})}catch(e){this.logger.warn("stopChatTurn: cancel failed",{conversationId:this.conversationId,error:e instanceof Error?e.message:String(e)})}}}buildHistory(){return this.sharedMessages.value.filter(e=>e.sender==="user"||e.sender==="bot").slice(-20).map(e=>({role:e.sender==="user"?"user":"assistant",content:e.text,...e.attachments?.length?{attachments:e.attachments}:{}})).filter(e=>e.content.length>0||e.attachments&&e.attachments.length>0)}loadMessages(e){this.conversationId=e.conversationId;let t=this.sharedMessages.value,n=e.messages.filter(d=>d.sender!=="bot"||!vp(d.text)),i=new Set(n.map(d=>d.id)),r=t.filter(d=>!i.has(d.id)),o=n[0]?.sequence,a=d=>!!o&&!!d.sequence&&d.sequence<o;if(this.sharedMessages.value=[...r.filter(a),...n,...r.filter(d=>!a(d))],this.runningStreamToken!==void 0)return;let s=new Set(this.sharedMessages.value.flatMap(d=>d.toolActivities?.map(p=>p.turnId)??[])),l=new Set(this.textState.value.turnOutcome==="stopped"?this.textState.value.toolActivities?.map(d=>d.turnId):[]),u=(e.activeToolActivities??[]).filter(d=>!s.has(d.turnId)&&!l.has(d.turnId));u.length?(u.forEach(d=>this.rememberToolActivity(d)),this.updateState(this.textState,{isThinking:!0,workingDescription:void 0,toolActivities:u,transientIssue:void 0,turnOutcome:void 0})):this.textState.value.toolActivities?.some(d=>s.has(d.turnId))&&this.updateState(this.textState,{isThinking:!1,workingDescription:void 0,toolActivities:[],turnOutcome:void 0})}async destroy(){this.clearBoundaryTimer(),this.voiceRecorder.teardown(),await this.endConversation()}};w5={key:0,class:"absolute inset-0 flex items-center justify-center"},Xa=Pe({__name:"ElBotButton",props:{theme:{default:"primary"},size:{default:"lg"},loading:{type:Boolean,default:!1},icon:{},iconAfter:{}},setup(e){let t=R(()=>({primary:"bg-primary-600 border-primary-400 hover:border-primary-300 hover:bg-primary-500",green:"bg-green-600 border-green-400 hover:border-green-300 hover:bg-green-500",red:"bg-red-600 border-red-400 hover:border-red-300 hover:bg-red-500",default:"bg-white/10 border-white/20 hover:border-white/40 hover:bg-white/20",dark:"bg-theme-900 border-transparent hover:bg-theme-800"})[e.theme]),n=R(()=>({sm:"px-4 py-2 text-sm",md:"px-6 py-3 text-base",lg:"px-8 py-4 text-base"})[e.size]),i=R(()=>({sm:"size-4",md:"size-4",lg:"size-5"})[e.size]);return(r,o)=>(w(),$("button",{class:V(["relative inline-flex items-center justify-center gap-2 font-medium rounded-full backdrop-blur-sm border-2 text-white transition-all duration-200 focus:outline-none active:opacity-80 disabled:opacity-50 disabled:cursor-not-allowed cursor-pointer",[t.value,n.value]])},[e.loading?(w(),$("div",w5,[...o[0]||(o[0]=[b("i",{class:"i-svg-spinners-90-ring-with-bg size-5"},null,-1)])])):te("",!0),b("span",{class:V(["flex items-center gap-2 transition-opacity duration-200",e.loading?"opacity-0":"opacity-100"])},[e.icon?(w(),$("i",{key:0,class:V([e.icon,i.value])},null,2)):te("",!0),zt(r.$slots,"default"),e.iconAfter?(w(),$("i",{key:1,class:V([e.iconAfter,i.value])},null,2)):te("",!0)],2)],2))}}),k5=["value"],jp=Pe({__name:"BotInputEmail",props:{modelValue:{default:""}},emits:["update:modelValue"],setup(e,{emit:t}){let n=t;return(i,r)=>(w(),$("input",{name:"username",type:"email",inputmode:"email",autocomplete:"username",autocapitalize:"off",autocorrect:"off",spellcheck:"false",placeholder:"Enter your email",value:e.modelValue,class:"w-full px-6 py-3 text-theme-900 placeholder-theme-500 bg-white border border-white rounded-full focus:outline-none transition-colors",style:{"font-size":"16px"},onInput:r[0]||(r[0]=o=>n("update:modelValue",o.target.value))},null,40,k5))}}),x5=["placeholder","value"],Mp=Pe({__name:"BotInputOneTimeCode",props:{modelValue:{},length:{},focusFirst:{type:Boolean}},emits:["update:modelValue","autoSubmit"],setup(e,{emit:t}){let n=e,i=t,r=Q(null),o=R(()=>"0".repeat(n.length));Ut(()=>{n.focusFirst&&!("ontouchstart"in window)&&r.value?.focus()});function a(s){let l=s.target.value.replace(/\D/g,"").slice(0,n.length);i("update:modelValue",l),l.length===n.length&&i("autoSubmit",l)}return(s,l)=>(w(),$("input",{ref_key:"input",ref:r,name:"one-time-code",type:"text",inputmode:"numeric",autocomplete:"one-time-code",autocapitalize:"off",autocorrect:"off",spellcheck:"false",enterkeyhint:"done",placeholder:o.value,value:e.modelValue,class:"w-full px-6 py-3 text-center font-mono tracking-[0.35em] text-theme-900 placeholder-theme-500 bg-white border border-white rounded-full focus:outline-none transition-colors",style:{"font-size":"16px"},onInput:a},null,40,x5))}}),_5={class:"relative flex-shrink-0"},$5=["src","alt"],S5={class:"absolute top-1 right-1"},I5={key:1,class:"size-3 bg-theme-400 rounded-full ring-2 ring-white"},E5={class:"min-w-0"},Lp=Pe({__name:"ElModeHeader",props:{bot:{},size:{default:"md"},isOnline:{type:Boolean,default:!1},layout:{default:"centered"}},setup(e){return(t,n)=>(w(),$("div",{class:V(["flex gap-4",[e.layout==="centered"?"flex-col items-center text-center":"flex-row items-center justify-center"]])},[b("div",_5,[b("div",{class:V(["rounded-full overflow-hidden border-white",e.size==="lg"?"w-20 h-20 sm:w-24 sm:h-24 border-4":"w-16 sm:size-16 border-2"])},[b("img",{src:e.bot.avatarUrl.value,alt:e.bot.displayName.value,class:"w-full h-full object-cover",onError:n[0]||(n[0]=(...i)=>Ae(ac)&&Ae(ac)(...i))},null,40,$5)],2),b("div",S5,[e.isOnline?(w(),$(ge,{key:0},[n[1]||(n[1]=b("div",{class:"size-3 bg-green-500 rounded-full ring-2 ring-white absolute animate-ping",style:{"animation-duration":"3s"}},null,-1)),n[2]||(n[2]=b("div",{class:"size-3 bg-green-500 rounded-full ring-2 ring-white"},null,-1))],64)):(w(),$("div",I5))])]),b("div",E5,[b("h1",{class:V(["font-light text-white mb-1 truncate",[e.size==="lg"?"text-3xl mb-2":"text-xl sm:text-2xl tracking-wide leading-tight",e.layout==="horizontal"?"text-white/95":""]])},de(e.bot.displayName.value),3),b("p",{class:V(["font-light line-clamp-1",[e.size==="lg"?"text-base text-white/60":"text-sm sm:text-base",e.layout==="horizontal"?"text-white/70 truncate":"text-white/60"]])},de(e.layout==="horizontal"?e.bot.title.value||"Assistant":e.bot.title.value),3)])],2))}});N5={class:"relative shrink-0 rounded-full"},C5=["src","alt"],z5=["src","alt"],A5=["aria-label"],xy=Pe({__name:"BotAvatar",props:{bot:{},showStatus:{type:Boolean,default:!0},showOwnerMark:{type:Boolean,default:!0},isLight:{type:Boolean,default:!0}},setup(e){let t={green:"bg-green-500",amber:"bg-amber-500",red:"bg-red-500",grey:"bg-theme-300"},n=R(()=>{let o=e.bot.state.value;return e.showStatus&&o.lifecycle!=="unknown"?t[o.color]:null}),i={width:"clamp(7px, 14%, 14px)",height:"clamp(7px, 14%, 14px)",top:"calc(14.6% - clamp(3.5px, 7%, 7px))",right:"calc(14.6% - clamp(3.5px, 7%, 7px))"},r=R(()=>e.isLight?"ring-white":"ring-theme-900");return(o,a)=>(w(),$("div",N5,[b("img",{src:e.bot.avatarUrl.value,alt:e.bot.displayName.value,class:V(["size-full rounded-full object-cover ring-1",e.isLight?"ring-black/5":"ring-white/10"])},null,10,C5),e.showOwnerMark&&e.bot.ownerMarkUrl.value?(w(),$("img",{key:0,src:e.bot.ownerMarkUrl.value,alt:e.bot.owner.value?.fullName?`Owned by ${e.bot.owner.value.fullName}`:"Owner",class:V(["absolute z-10 size-[36%] -bottom-[3%] -left-[3%] rounded-full object-cover ring-2",r.value])},null,10,z5)):te("",!0),n.value?(w(),$("span",{key:1,role:"status","aria-label":e.bot.state.value.tooltip,class:V(["absolute z-10 rounded-full ring-2",[n.value,r.value]]),style:i},null,10,A5)):te("",!0),n.value&&e.bot.state.value.lifecycle==="running"?(w(),$("span",{key:2,"aria-hidden":"true",class:V(["pointer-events-none absolute rounded-full animate-ping opacity-50 [animation-duration:3s]",n.value]),style:i},null,2)):te("",!0)]))}}),O5={key:0,class:"sr-only",role:"status","aria-live":"polite"},D5=["aria-expanded","disabled"],P5=["aria-expanded"],R5={class:"flex w-5 shrink-0 justify-center self-stretch","aria-hidden":"true"},U5=["data-journal-row"],j5={class:"flex w-5 shrink-0 flex-col items-center self-stretch","aria-hidden":"true"},M5={class:"flex h-[17px] shrink-0 items-center"},L5={key:0,class:"sr-only"},sy=Pe({__name:"BotToolActivityGroup",props:{model:{},isLight:{type:Boolean}},setup(e){let t=e,n=We(!1);function i(){n.value=!n.value}let r=R(()=>t.model.outcome==="completed"),o=R(()=>t.model.hiddenRows.length),a=R(()=>t.model.hint??(t.model.terminal?.tone==="active"?t.model.terminal.label:void 0)),s=R(()=>{let d=t.model;return r.value?n.value?d.hiddenRows:[]:[...n.value?d.hiddenRows:[],...d.visibleRows,...d.terminal?[d.terminal]:[]]}),l=R(()=>t.isLight?{spine:"bg-theme-200",dashed:"border-theme-300",doneMark:"text-theme-400",failedMark:"text-theme-400",activeLine:"text-theme-700",stoppedSquare:"bg-theme-400",muted:"text-theme-400",ring:"focus-visible:ring-theme-900"}:{spine:"bg-white/15",dashed:"border-white/25",doneMark:"text-white/45",failedMark:"text-white/55",activeLine:"text-white/85",stoppedSquare:"bg-white/50",muted:"text-white/50",ring:"focus-visible:ring-white"}),u=R(()=>{let d=t.isLight;return{done:{statusWord:"completed",label:d?"text-[12px] text-theme-400":"text-[12px] text-white/50",station:{tag:"i",class:`i-tabler-check size-3 ${l.value.doneMark}`}},active:{statusWord:"in progress",label:d?"text-[12px] font-medium text-theme-700":"text-[12px] font-medium text-white/85",station:{tag:"span",class:`chat-pulse-dot size-1.5 rounded-full bg-current ${l.value.activeLine}`}},failed:{statusWord:"failed",label:d?"text-[12px] font-medium text-theme-600":"text-[12px] font-medium text-white/70",station:{tag:"i",class:`i-tabler-alert-circle size-3.5 ${l.value.failedMark}`}},stopped:{label:d?"text-[12px] font-medium text-theme-600":"text-[12px] font-medium text-white/70",station:{tag:"span",class:`size-[9px] rounded-[2px] ${l.value.stoppedSquare}`}},completed:{label:d?"text-[12px] text-theme-400":"text-[12px] text-white/50",station:{tag:"i",class:"i-tabler-circle-check size-3.5 text-green-600"}}}});return(d,p)=>(w(),$("div",{class:V(["w-full py-0.5",l.value.muted])},[a.value?(w(),$("span",O5,de(a.value),1)):te("",!0),r.value?(w(),$("button",{key:1,type:"button","data-test":"messaging-tool-activity-summary","data-journal-disclosure":"","aria-expanded":n.value,disabled:o.value===0,class:V(["flex min-h-11 items-center gap-x-2 text-left focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-offset-2 disabled:cursor-default",l.value.ring]),onClick:i},[p[0]||(p[0]=b("i",{"data-journal-station":"completed",class:"i-tabler-circle-check size-3.5 shrink-0 text-green-600","aria-hidden":"true"},null,-1)),b("span",{class:V(["text-[12px] font-medium leading-none",l.value.muted])},de(e.model.terminal?.label),3),o.value?(w(),$("i",{key:0,class:V(["size-[13px] shrink-0",[n.value?"i-tabler-chevron-down":"i-tabler-chevron-right",l.value.muted]]),"aria-hidden":"true"},null,2)):te("",!0)],10,D5)):o.value?(w(),$("button",{key:2,type:"button","data-test":"messaging-tool-activity-summary","data-journal-disclosure":"","aria-expanded":n.value,class:V(["flex min-h-11 w-full gap-x-2.5 text-left focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-offset-2",l.value.ring]),onClick:i},[b("span",R5,[b("span",{"data-journal-spine":"dashed",class:V(["w-0 border-l border-dashed",l.value.dashed])},null,2)]),b("span",{class:V(["flex min-h-[20px] items-center gap-0.5 pb-2 text-[12px] leading-none",l.value.muted])},[xt(de(o.value)+" earlier updates ",1),b("i",{class:V(["size-3 shrink-0",n.value?"i-tabler-chevron-down":"i-tabler-chevron-right"]),"aria-hidden":"true"},null,2)],2)],10,P5)):te("",!0),(w(!0),$(ge,null,st(s.value,(m,f)=>(w(),$("div",{key:m.id,"data-test":"messaging-tool-activity-row","data-journal-row":m.tone,class:V([r.value?"pl-[22px]":"","flex gap-x-2.5"])},[b("div",j5,[b("span",M5,[(w(),Fe(SS(u.value[m.tone].station.tag),{"data-journal-station":m.tone,class:V(u.value[m.tone].station.class)},null,8,["data-journal-station","class"]))]),f===s.value.length-1?te("",!0):(w(),$("span",{key:0,class:V(["w-px flex-1",l.value.spine])},null,2))]),b("div",{class:V(["min-w-0 flex-1",f===s.value.length-1?"":"pb-2"])},[b("span",{class:V(["relative block leading-snug",u.value[m.tone].label])},[xt(de(m.label),1),u.value[m.tone].statusWord?(w(),$("span",L5,", "+de(u.value[m.tone].statusWord),1)):te("",!0)],2),m.note?(w(),$("p",{key:0,class:V(["pt-0.5 text-[12px] leading-snug",l.value.muted])},de(m.note),3)):te("",!0)],2)],10,U5))),128)),!r.value&&e.model.hint?(w(),$("p",{key:3,"data-test":"messaging-tool-activity-hint",class:V(["pl-[30px] pt-2.5 text-[12px] leading-snug",l.value.muted])},de(e.model.hint),3)):te("",!0)],2))}});$p.prototype[typeof Symbol=="function"&&Symbol.asyncIterator||"@@asyncIterator"]=function(){return this},$p.prototype.next=function(e){return this._invoke("next",e)},$p.prototype.throw=function(e){return this._invoke("throw",e)},$p.prototype.return=function(e){return this._invoke("return",e)};mE=Object.entries,UI=Object.setPrototypeOf,W5=Object.isFrozen,fE=Object.getPrototypeOf,hE=Object.getOwnPropertyDescriptor,Zt=Object.freeze,Qt=Object.seal,Ha=Object.create,gE=typeof Reflect<"u"&&Reflect,_y=gE.apply,$y=gE.construct;Zt||(Zt=function(t){return t}),Qt||(Qt=function(t){return t}),_y||(_y=function(t,n){var i=[...arguments].slice(2);return t.apply(n,i)}),$y||($y=function(t){return new t(...[...arguments].slice(1))});ei=_t(Array.prototype.forEach);Array.prototype.indexOf;q5=_t(Array.prototype.lastIndexOf),jI=_t(Array.prototype.pop),Xl=_t(Array.prototype.push),G5=_t(Array.prototype.slice),J5=_t(Array.prototype.splice),Ga=Array.isArray,ly=vE(Set),cy=_t(Set.prototype.add),Ql=_t(Set.prototype.has),ho=_t(String.prototype.toLowerCase),uy=_t(String.prototype.toString),MI=_t(String.prototype.match),ec=_t(String.prototype.replace),LI=_t(String.prototype.indexOf),Y5=_t(String.prototype.trim),X5=_t(Number.prototype.toString),Q5=_t(Boolean.prototype.toString),VI=typeof BigInt>"u"?null:_t(BigInt.prototype.toString),FI=typeof Symbol>"u"?null:_t(Symbol.prototype.toString),Ir=_t(Object.prototype.hasOwnProperty),tc=_t(Object.prototype.toString),Xt=_t(RegExp.prototype.test),ti=vE(TypeError);BI=Zt("a.abbr.acronym.address.area.article.aside.audio.b.bdi.bdo.big.blink.blockquote.body.br.button.canvas.caption.center.cite.code.col.colgroup.content.data.datalist.dd.decorator.del.details.dfn.dialog.dir.div.dl.dt.element.em.fieldset.figcaption.figure.font.footer.form.h1.h2.h3.h4.h5.h6.head.header.hgroup.hr.html.i.img.input.ins.kbd.label.legend.li.main.map.mark.marquee.menu.menuitem.meter.nav.nobr.ol.optgroup.option.output.p.picture.pre.progress.q.rp.rt.ruby.s.samp.search.section.select.shadow.slot.small.source.spacer.span.strike.strong.style.sub.summary.sup.table.tbody.td.template.textarea.tfoot.th.thead.time.tr.track.tt.u.ul.var.video.wbr".split(".")),dy=Zt("svg.a.altglyph.altglyphdef.altglyphitem.animatecolor.animatemotion.animatetransform.circle.clippath.defs.desc.ellipse.enterkeyhint.exportparts.filter.font.g.glyph.glyphref.hkern.image.inputmode.line.lineargradient.marker.mask.metadata.mpath.part.path.pattern.polygon.polyline.radialgradient.rect.stop.style.switch.symbol.text.textpath.title.tref.tspan.view.vkern".split(".")),py=Zt(["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"]),iP=Zt(["animate","color-profile","cursor","discard","font-face","font-face-format","font-face-name","font-face-src","font-face-uri","foreignobject","hatch","hatchpath","mesh","meshgradient","meshpatch","meshrow","missing-glyph","script","set","solidcolor","unknown","use"]),my=Zt("math.menclose.merror.mfenced.mfrac.mglyph.mi.mlabeledtr.mmultiscripts.mn.mo.mover.mpadded.mphantom.mroot.mrow.ms.mspace.msqrt.mstyle.msub.msup.msubsup.mtable.mtd.mtext.mtr.munder.munderover.mprescripts".split(".")),oP=Zt(["maction","maligngroup","malignmark","mlongdiv","mscarries","mscarry","msgroup","mstack","msline","msrow","semantics","annotation","annotation-xml","mprescripts","none"]),ZI=Zt(["#text"]),HI=Zt("accept.action.align.alt.autocapitalize.autocomplete.autopictureinpicture.autoplay.background.bgcolor.border.capture.cellpadding.cellspacing.checked.cite.class.clear.color.cols.colspan.command.commandfor.controls.controlslist.coords.crossorigin.datetime.decoding.default.dir.disabled.disablepictureinpicture.disableremoteplayback.download.draggable.enctype.enterkeyhint.exportparts.face.for.headers.height.hidden.high.href.hreflang.id.inert.inputmode.integrity.ismap.kind.label.lang.list.loading.loop.low.max.maxlength.media.method.min.minlength.multiple.muted.name.nonce.noshade.novalidate.nowrap.open.optimum.part.pattern.placeholder.playsinline.popover.popovertarget.popovertargetaction.poster.preload.pubdate.radiogroup.readonly.rel.required.rev.reversed.role.rows.rowspan.spellcheck.scope.selected.shape.size.sizes.slot.span.srclang.start.src.srcset.step.style.summary.tabindex.title.translate.type.usemap.valign.value.width.wrap.xmlns".split(".")),fy=Zt("accent-height.accumulate.additive.alignment-baseline.amplitude.ascent.attributename.attributetype.azimuth.basefrequency.baseline-shift.begin.bias.by.class.clip.clippathunits.clip-path.clip-rule.color.color-interpolation.color-interpolation-filters.color-profile.color-rendering.cx.cy.d.dx.dy.diffuseconstant.direction.display.divisor.dominant-baseline.dur.edgemode.elevation.end.exponent.fill.fill-opacity.fill-rule.filter.filterunits.flood-color.flood-opacity.font-family.font-size.font-size-adjust.font-stretch.font-style.font-variant.font-weight.fx.fy.g1.g2.glyph-name.glyphref.gradientunits.gradienttransform.height.href.id.image-rendering.in.in2.intercept.k.k1.k2.k3.k4.kerning.keypoints.keysplines.keytimes.lang.lengthadjust.letter-spacing.kernelmatrix.kernelunitlength.lighting-color.local.marker-end.marker-mid.marker-start.markerheight.markerunits.markerwidth.maskcontentunits.maskunits.max.mask.mask-type.media.method.mode.min.name.numoctaves.offset.operator.opacity.order.orient.orientation.origin.overflow.paint-order.path.pathlength.patterncontentunits.patterntransform.patternunits.pointer-events.points.preservealpha.preserveaspectratio.primitiveunits.r.rx.ry.radius.refx.refy.repeatcount.repeatdur.restart.result.rotate.scale.seed.shape-rendering.slope.specularconstant.specularexponent.spreadmethod.startoffset.stddeviation.stitchtiles.stop-color.stop-opacity.stroke-dasharray.stroke-dashoffset.stroke-linecap.stroke-linejoin.stroke-miterlimit.stroke-opacity.stroke.stroke-width.style.surfacescale.systemlanguage.tabindex.tablevalues.targetx.targety.transform.transform-origin.text-anchor.text-decoration.text-orientation.text-rendering.textlength.type.u1.u2.unicode.values.vector-effect.viewbox.visibility.version.vert-adv-y.vert-origin-x.vert-origin-y.width.word-spacing.wrap.writing-mode.xchannelselector.ychannelselector.x.x1.x2.xmlns.y.y1.y2.z.zoomandpan".split(".")),KI=Zt("accent.accentunder.align.bevelled.close.columnalign.columnlines.columnspacing.columnspan.denomalign.depth.dir.display.displaystyle.encoding.fence.frame.height.href.id.largeop.length.linethickness.lquote.lspace.mathbackground.mathcolor.mathsize.mathvariant.maxsize.minsize.movablelimits.notation.numalign.open.rowalign.rowlines.rowspacing.rowspan.rspace.rquote.scriptlevel.scriptminsize.scriptsizemultiplier.selection.separator.separators.stretchy.subscriptshift.supscriptshift.symmetric.voffset.width.xmlns".split(".")),Sp=Zt(["xlink:href","xml:id","xlink:title","xml:space","xmlns:xlink"]),aP=Qt(/{{[\w\W]*|^[\w\W]*}}/g),sP=Qt(/<%[\w\W]*|^[\w\W]*%>/g),lP=Qt(/\${[\w\W]*/g),cP=Qt(/^data-[\-\w.\u00B7-\uFFFF]+$/),uP=Qt(/^aria-[\-\w]+$/),WI=Qt(/^(?:(?:(?:f|ht)tps?|mailto|tel|callto|sms|cid|xmpp|matrix):|[^a-z]|[a-z+.\-]+(?:[^a-z+.\-:]|$))/i),dP=Qt(/^(?:\w+script|data):/i),pP=Qt(/[\u0000-\u0020\u00A0\u1680\u180E\u2000-\u2029\u205F\u3000]/g),mP=Qt(/^html$/i),fP=Qt(/^[a-z][.\w]*(-[.\w]+)+$/i),hy=Qt(/<[/\w!]/g),qI=Qt(/<[/\w]/g),hP=Qt(/<\/no(script|embed|frames)/i),GI=Qt(/\/>/i),At={element:1,attribute:2,text:3,cdataSection:4,entityReference:5,entityNode:6,processingInstruction:7,comment:8,document:9,documentType:10,documentFragment:11,notation:12},gP=Zt(Ge({},["style","script","xmp","iframe","noembed","noframes","plaintext","noscript"])),vP=function(){return typeof window>"u"?null:window},bP=function(t,n){if(typeof t!="object"||typeof t.createPolicy!="function")return null;let i=null,r="data-tt-policy-suffix";n&&n.hasAttribute(r)&&(i=n.getAttribute(r));let o="dompurify"+(i?"#"+i:"");try{return t.createPolicy(o,{createHTML(a){return a},createScriptURL(a){return a}})}catch{return console.warn("TrustedTypes policy "+o+" could not be created."),null}},JI=function(){return{afterSanitizeAttributes:[],afterSanitizeElements:[],afterSanitizeShadowDOM:[],beforeSanitizeAttributes:[],beforeSanitizeElements:[],beforeSanitizeShadowDOM:[],uponSanitizeAttribute:[],uponSanitizeElement:[],uponSanitizeShadowNode:[]}},Ni=function(t,n,i,r){return Ir(t,n)&&Ga(t[n])?Ge(r.base?Rr(r.base):{},t[n],r.transform):i},gy=function(t,n,i){let r=Ir(t,n)?t[n]:void 0;return r&&typeof r=="object"?Rr(r):i()};yE=bE();bo=Ny();go={exec:()=>null};kE=((e="")=>{try{return!!RegExp("(?<=1)(?<!1)"+e)}catch{return!1}})(),jt={codeRemoveIndent:/^(?: {0,3}\t| {1,4})/gm,outputLinkReplace:/\\([\[\]])/g,indentCodeCompensation:/^(\s+)(?:```)/,beginningSpace:/^\s+/,endingHash:/#$/,startingSpaceChar:/^ /,endingSpaceChar:/ $/,endingSpaceTabChar:/[ \t]$/,nonSpaceChar:/[^ ]/,newLineCharGlobal:/\n/g,tabCharGlobal:/\t/g,leadingSpaceTab:/^[ \t]+/,multipleSpaceGlobal:/\s+/g,blankLine:/^[ \t]*$/,doubleBlankLine:/\n[ \t]*\n[ \t]*$/,blockquoteStart:/^ {0,3}>/,blockquoteSetextReplace:/\n {0,3}((?:=+|-+)[ \t]*)(?=\n|$)/g,blockquoteSetextReplace2:/^ {0,3}>[ \t]?/gm,blockquoteMarkerWhitespace:/^( {0,3}>)([ \t]+)/gm,listReplaceNesting:/^ {1,4}(?=( {4})*[^ ])/g,listIsTask:/^\[[ xX]\][ \t]+\S/,listReplaceTask:/^\[[ xX]\][ \t]+/,listTaskCheckbox:/\[[ xX]\]/,anyLine:/\n.*\n/,hrefBrackets:/^<(.*)>$/,tableDelimiter:/[:|]/,tableAlignChars:/^\||\| *$/g,tableRowBlankLine:/\n[ \t]*$/,tableAlignRight:/^ *-+: *$/,tableAlignCenter:/^ *:-+: *$/,tableAlignLeft:/^ *:-+ *$/,startATag:/^<a /i,endATag:/^<\/a>/i,startPreScriptTag:/^<(pre|code|kbd|script)(\s|>)/i,endPreScriptTag:/^<\/(pre|code|kbd|script)(\s|>)/i,startAngleBracket:/^</,endAngleBracket:/>$/,pedanticHrefTitle:/^([^'"]*[^\s])\s+(['"])(.*)\2/,unicodeAlphaNumeric:/[\p{L}\p{N}]/u,numericCharacterReference:/&#(?:(\d{1,7})|[Xx]([A-Fa-f0-9]{1,6}));/,numericCharacterReferenceOrAmpersand:/&#(?:(\d{1,7})|[Xx]([A-Fa-f0-9]{1,6}));|&(?!(#\d{1,7}|#[Xx][a-fA-F0-9]{1,6}|\w+);)/g,escapeTest:/[&<>"']/,escapeReplace:/[&<>"']/g,escapeTestNoEncode:/[<>"']|&(?!(#\d{1,7}|#[Xx][a-fA-F0-9]{1,6}|\w+);)/,escapeReplaceNoEncode:/[<>"']|&(?!(#\d{1,7}|#[Xx][a-fA-F0-9]{1,6}|\w+);)/g,caret:/(^|[^\[])\^/g,percentDecode:/%25/g,findPipe:/\|/g,splitPipe:/ \|/,slashPipe:/\\\|/g,carriageReturn:/\r\n|\r/g,spaceLine:/^ +$/gm,notSpaceStart:/^\S*/,endingNewline:/\n$/,listItemRegex:e=>RegExp(`^( {0,3}${e})((?:[ ][^\\n]*)?(?:\\n|$))`),nextBulletRegex:mo(e=>RegExp(`^ {0,${e}}(?:[*+-]|\\d{1,9}[.)])((?:[ ][^\\n]*)?(?:\\n|$))`)),hrRegex:mo(e=>RegExp(`^ {0,${e}}((?:-[ ]*){3,}|(?:_[ ]*){3,}|(?:\\*[ ]*){3,})(?:\\n+|$)`)),fencesBeginRegex:mo(e=>RegExp(`^ {0,${e}}(?:\`\`\`|~~~)`)),headingBeginRegex:mo(e=>RegExp(`^ {0,${e}}#{1,6}(?:\\s|$)`)),pedanticHeadingBeginRegex:mo(e=>RegExp(`^ {0,${e}}#`)),htmlBeginRegex:mo(e=>RegExp(`^ {0,${e}}(?:</?(?:${cc})(?: +|$|/?>)|<(?:(?:script|pre|style|textarea)(?:[\\s>]|$)|!--)|<\\?|<![A-Za-z]|<!\\[CDATA\\[)`,"i")),blockquoteBeginRegex:mo(e=>RegExp(`^ {0,${e}}>`))},kP=/^(?:[ \t]*(?:\n|$))+/,xP=/^((?: {4}| {0,3}\t)[^\n]+(?:\n(?:[ \t]*(?:\n|$))*)?)+/,_P=/^ {0,3}(`{3,}(?=[^`\n]*(?:\n|$))|~{3,})([^\n]*)(?:\n|$)(?:|([\s\S]*?)(?:\n|$))(?: {0,3}(?:(?=`)\1`*|(?=~)\1~*) *(?=\n|$)|$)/,lc=/^ {0,3}((?:-[\t ]*){3,}|(?:_[ \t]*){3,}|(?:\*[ \t]*){3,})(?:\n+|$)/,$P=/^ {0,3}(#{1,6})(?=\s|$)(.*)(?:\n+|$)/,Cy=/ {0,3}(?:[*+-]|\d{1,9}[.)])/,xE=/^(?!bull |blockCode|fences|blockquote|heading|html|table)((?:.|\n(?!\s*?\n|bull |fences|blockquote|heading|hr|html|table))+?)\n {0,3}(=+|-+)[ \t]*(?:\n+|$)/,_E=Oe(xE).replace(/bull/g,Cy).replace(/blockCode/g,/(?: {4}| {0,3}\t)/).replace(/fences/g,/ {0,3}(?:`{3,}|~{3,})/).replace(/blockquote/g,/ {0,3}>/).replace(/heading/g,/ {0,3}#{1,6}(?:\s|$)/).replace(/hr/g,/ {0,3}(?:(?:-[\t ]*){3,}|(?:_[ \t]*){3,}|(?:\*[ \t]*){3,})(?:\n+|$)/).replace(/html/g,/ {0,3}<[^\n>]+>\n/).replace(/\|table/g,"").getRegex(),SP=Oe(xE).replace(/bull/g,Cy).replace(/blockCode/g,/(?: {4}| {0,3}\t)/).replace(/fences/g,/ {0,3}(?:`{3,}|~{3,})/).replace(/blockquote/g,/ {0,3}>/).replace(/heading/g,/ {0,3}#{1,6}(?:\s|$)/).replace(/hr/g,/ {0,3}(?:(?:-[\t ]*){3,}|(?:_[ \t]*){3,}|(?:\*[ \t]*){3,})(?:\n+|$)/).replace(/html/g,/ {0,3}<[^\n>]+>\n/).replace(/table/g,/ {0,3}\|?(?:[:\- ]*\|)+[\:\- ]*\n/).getRegex(),zy=/^([^\n]+(?:\n(?!hr|heading|lheading|blockquote|fences|list|html|table|[ \t]+\n)[^\n]+)*)/,IP=/^[^\n]+/,Ay=/(?!\s*\])(?:\\[\s\S]|[^\[\]\\\n]|\n(?![ \t]*\n))+/,EP=Oe(/^ {0,3}\[(label)\]: *(?:\n[ \t]*)?([^<\s][^\s]*|<.*?>)(?:(?: +(?:\n[ \t]*)?| *\n[ \t]*)(title))? *(?:\n+|$)/).replace("label",Ay).replace("title",/(?:"(?:\\[\s\S]|[^"\\])*"|'(?:\\[\s\S]|[^'\\\n]|\n(?!\n))*'|\((?:\\[\s\S]|[^()\\])*\))/).getRegex(),TP=Oe(/^(bull)([ \t][^\n]*?)?(?:\n|$)/).replace(/bull/g,Cy).getRegex(),cc="address|article|aside|base|basefont|blockquote|body|caption|center|col|colgroup|dd|details|dialog|dir|div|dl|dt|fieldset|figcaption|figure|footer|form|frame|frameset|h[1-6]|head|header|hr|html|iframe|legend|li|link|main|menu|menuitem|meta|nav|noframes|ol|optgroup|option|p|param|search|section|summary|table|tbody|td|tfoot|th|thead|title|tr|track|ul",Oy=/<!--(?:-?>|[\s\S]*?(?:-->|$))/,NP=Oe("^ {0,3}(?:<(script|pre|style|textarea)[\\s>][\\s\\S]*?(?:</\\1>[^\\n]*\\n*|$)|comment[^\\n]*(\\n+|$)|<\\?[\\s\\S]*?(?:\\?>[^\\n]*\\n*|$)|<![A-Z][\\s\\S]*?(?:>[^\\n]*\\n*|$)|<!\\[CDATA\\[[\\s\\S]*?(?:\\]\\]>[^\\n]*\\n*|$)|</?(tag)(?:[ \\t]+|\\n|/?>|$)[\\s\\S]*?(?:(?:\\n[ ]*)+\\n|$)|<(?!(?:script|pre|style|textarea)(?![a-z0-9-]))([a-z][a-z0-9-]*)(?:attribute)*? */?>(?=[ \\t]*(?:\\n|$))[\\s\\S]*?(?:(?:\\n[ ]*)+\\n|$)|</[a-z][a-z0-9-]*\\s*>(?=[ \\t]*(?:\\n|$))[\\s\\S]*?(?:(?:\\n[ ]*)+\\n|$))","i").replace("comment",Oy).replace("tag",cc).replace("attribute",/ +[a-zA-Z:_][\w.:-]*(?: *= *"[^"\n]*"| *= *'[^'\n]*'| *= *[^\s"'=<>`]+)?/).getRegex(),$E=e=>Oe(zy).replace("hr",lc).replace("heading"," {0,3}#{1,6}(?:\\s|$)").replace("|lheading","").replace("|table","").replace("blockquote"," {0,3}>").replace("fences"," {0,3}(?:`{3,}(?=[^`\\n]*(?:\\n|$))|~~~)[^\\n]*(?:\\n|$)").replace("list",e).replace("html"," {0,3}(?:</?(?:tag)(?: +|\\n|/?>)|<(?:(?:script|pre|style|textarea)(?:[\\s>]|$)|!--)|<\\?|<![A-Za-z]|<!\\[CDATA\\[)").replace("tag",cc).getRegex(),CP=$E(/ {0,3}(?:[*+-]|1[.)])[ \t]+[^ \t\n]/),zP=$E(/ {0,3}(?:[*+-]|\d{1,9}[.)])(?:[ \t]|\n|$)/),Dy={blockquote:Oe(/^( {0,3}> ?(?:(?![ \t]*(?:\n|$))(paragraph)|[^\n]*)(?:\n|$))+/).replace("paragraph",zP).getRegex(),code:xP,def:EP,fences:_P,heading:$P,hr:lc,html:NP,lheading:_E,list:TP,newline:kP,paragraph:CP,table:go,text:IP},YI=Oe("^ *([^\\n ].*)\\n {0,3}((?:\\| *)?:?-+:? *(?:\\| *:?-+:? *)*(?:\\| *)?)(?:\\n((?:(?! *\\n|hr|heading|blockquote|code|fences|list|html).*(?:\\n|$))*)\\n*|$)").replace("hr",lc).replace("heading"," {0,3}#{1,6}(?:\\s|$)").replace("blockquote"," {0,3}>").replace("code","(?: {4}| {0,3} )[^\\n]").replace("fences"," {0,3}(?:`{3,}(?=[^`\\n]*(?:\\n|$))|~~~)[^\\n]*(?:\\n|$)").replace("list"," {0,3}(?:[*+-]|1[.)])[ \\t]").replace("html"," {0,3}(?:</?(?:tag)(?: +|\\n|/?>)|<(?:(?:script|pre|style|textarea)(?:[\\s>]|$)|!--)|<\\?|<![A-Za-z]|<!\\[CDATA\\[)").replace("tag",cc).getRegex(),AP={...Dy,lheading:SP,table:YI,paragraph:Oe(zy).replace("hr",lc).replace("heading"," {0,3}#{1,6}(?:\\s|$)").replace("|lheading","").replace("table",YI).replace("blockquote"," {0,3}>").replace("fences"," {0,3}(?:`{3,}(?=[^`\\n]*(?:\\n|$))|~~~)[^\\n]*(?:\\n|$)").replace("list"," {0,3}(?:[*+-]|1[.)])[ \\t]+[^ \\t\\n]").replace("html"," {0,3}(?:</?(?:tag)(?: +|\\n|/?>)|<(?:(?:script|pre|style|textarea)(?:[\\s>]|$)|!--)|<\\?|<![A-Za-z]|<!\\[CDATA\\[)").replace("tag",cc).getRegex()},OP={...Dy,html:Oe(`^ *(?:comment(?: *\\n|\\s*$)|<(tag)[\\s\\S]+?</\\1>(?: *\\n{2,}|\\s*$)|<tag(?:"[^"]*"|'[^']*'|\\s[^'"/>\\s]*)*?/?>(?: *\\n{2,}|\\s*$))`).replace("comment",Oy).replace(/tag/g,"(?!(?:a|em|strong|small|s|cite|q|dfn|abbr|data|time|code|var|samp|kbd|sub|sup|i|b|u|mark|ruby|rt|rp|bdi|bdo|span|br|wbr|ins|del|img)\\b)\\w+(?!:|[^\\w\\s@]*@)\\b").getRegex(),def:/^ *\[([^\]]+)\]: *<?([^\s>]+)>?(?: +(["(][^\n]+[")]))? *(?:\n+|$)/,heading:/^(#{1,6})(.*)(?:\n+|$)/,fences:go,lheading:/^(.+?)\n {0,3}(=+|-+) *(?:\n+|$)/,paragraph:Oe(zy).replace("hr",lc).replace("heading",` *#{1,6} *[^
|
|
103
|
+
]`).replace("lheading",_E).replace("|table","").replace("blockquote"," {0,3}>").replace("|fences","").replace("|list","").replace("|html","").replace("|tag","").getRegex()},DP=/^\\([!"#$%&'()*+,\-./:;<=>?@\[\]\\^_`{|}~])/,PP=/^(`+)([^`]|[^`][\s\S]*?[^`])\1(?!`)/,SE=/^( {2,}|\\)\n(?!\s*$)[ \t]*/,RP=/^(`+|[^`])(?:(?= {2,}\n)|[\s\S]*?(?:(?=[\\<!\[`*_]|\b_|$)|[^ ](?= {2,}\n)))/,Cn=/[\p{P}\p{S}]/u,Qa=/[\s\p{P}\p{S}]/u,uc=/[^\s\p{P}\p{S}]/u,UP=Oe(/^((?![*_])punctSpace)/,"u").replace(/punctSpace/g,Qa).getRegex(),jP=/[\p{Pi}\p{Ps}"']/u,IE=/(?!~)[\p{P}\p{S}]/u,MP=/(?!~)[\s\p{P}\p{S}]/u,LP=/(?:[^\s\p{P}\p{S}]|~)/u,VP=Oe(/link|precode-code|html/,"g").replace("link",/\[(?:[^\[\]`]|(?<a>`+)[^`]+\k<a>(?!`))*?\]\((?:\\[\s\S]|[^\\\(\)]|\((?:\\[\s\S]|[^\\\(\)])*\))*\)/).replace("precode-",kE?"(?<!`)()":"(^^|[^`])").replace("code",/(?<b>`+)[^`]+\k<b>(?!`)/).replace("html",/<(?! )[^<>]*?>/).getRegex(),EE=/^(?:\*+(?:((?!\*)punct)|([^\s*]))?)|^_+(?:((?!_)punct)|([^\s_]))?/,FP=Oe(EE,"u").replace(/punct/g,Cn).getRegex(),BP=Oe(EE,"u").replace(/punct/g,IE).getRegex(),ZP=Oe(/^(?:\*+(?:((?!\*)(?!openQuote)punct)|([^\s*]))?)|^_+(?:((?!_)(?!openQuote)punct)|([^\s_]))?/,"u").replace(/openQuote/g,jP).replace(/punct/g,Cn).getRegex(),TE="^[^_*]*?__[^_*]*?\\*[^_*]*?(?=__)|[^*]+(?=[^*])|(?!\\*)punct(\\*+)(?=[\\s]|$)|notPunctSpace(\\*+)(?!\\*)(?=punctSpace|$)|(?!\\*)punctSpace(\\*+)(?=notPunctSpace)|[\\s](\\*+)(?!\\*)(?=punct)|(?!\\*)punct(\\*+)(?!\\*)(?=punct)|notPunctSpace(\\*+)(?=notPunctSpace)",HP=Oe(TE,"gu").replace(/notPunctSpace/g,uc).replace(/punctSpace/g,Qa).replace(/punct/g,Cn).getRegex(),KP=Oe(TE,"gu").replace(/notPunctSpace/g,LP).replace(/punctSpace/g,MP).replace(/punct/g,IE).getRegex(),WP=Oe("^[^_*]*?__[^_*]*?\\*[^_*]*?(?=__)|[^*]+(?=[^*])|(?!\\*)punct(\\*+)(?=[\\s]|$)|notPunctSpace(\\*+)(?!\\*)(?=punctSpace|$)|(?!\\*)[\\s](\\*+)(?=notPunctSpace)|[\\s](\\*+)(?!\\*)(?=punct)|(?!\\*)punct(\\*+)(?!\\*)(?=punct)|(?:(?!\\*)punct|notPunctSpace)(\\*+)(?!\\*)(?=notPunctSpace)","gu").replace(/notPunctSpace/g,uc).replace(/punctSpace/g,Qa).replace(/punct/g,Cn).getRegex(),qP=Oe("^[^_*]*?\\*\\*[^_*]*?_[^_*]*?(?=\\*\\*)|[^_]+(?=[^_])|(?!_)punct(_+)(?=[\\s]|$)|notPunctSpace(_+)(?!_)(?=punctSpace|$)|(?!_)punctSpace(_+)(?=notPunctSpace)|[\\s](_+)(?!_)(?=punct)|(?!_)punct(_+)(?!_)(?=punct)","gu").replace(/notPunctSpace/g,uc).replace(/punctSpace/g,Qa).replace(/punct/g,Cn).getRegex(),GP=Oe("^[^_*]*?\\*\\*[^_*]*?_[^_*]*?(?=\\*\\*)|[^_]+(?=[^_])|(?!_)punct(_+)(?=[\\s]|$)|notPunctSpace(_+)(?!_)(?=punctSpace|$)|(?!_)[\\s](_+)(?=notPunctSpace)|[\\s](_+)(?!_)(?=punct)|(?!_)punct(_+)(?!_)(?=punct)|(?:(?!_)punct|notPunctSpace)(_+)(?!_)(?=notPunctSpace)","gu").replace(/notPunctSpace/g,uc).replace(/punctSpace/g,Qa).replace(/punct/g,Cn).getRegex(),JP=Oe(/^~~?(?:((?!~)punct)|[^\s~])/,"u").replace(/punct/g,Cn).getRegex(),YP=Oe("^[^~]+(?=[^~])|(?!~)punct(~~?)(?=[\\s]|$)|notPunctSpace(~~?)(?!~)(?=punctSpace|$)|(?!~)punctSpace(~~?)(?=notPunctSpace)|[\\s](~~?)(?!~)(?=punct)|(?!~)punct(~~?)(?!~)(?=punct)|notPunctSpace(~~?)(?=notPunctSpace)","gu").replace(/notPunctSpace/g,uc).replace(/punctSpace/g,Qa).replace(/punct/g,Cn).getRegex(),XP=Oe(/\\(punct)/,"gu").replace(/punct/g,Cn).getRegex(),QP=Oe(/(`+)(?:[^`]|[^`][\s\S]*?[^`])\1(?!`)|`+|\\(punct)/,"gu").replace(/punct/g,Cn).getRegex(),eR=Oe(/^<(scheme:[^\s\x00-\x1f<>]*|email)>/).replace("scheme",/[a-zA-Z][a-zA-Z0-9+.-]{1,31}/).replace("email",/[a-zA-Z0-9.!#$%&'*+/=?^_`{|}~-]+(@)[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?(?:\.[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?)+(?![-_])/).getRegex(),tR=Oe(Oy).replace("(?:-->|$)","-->").getRegex(),rR=Oe("^comment|^</[a-zA-Z][a-zA-Z0-9-]*\\s*>|^<[a-zA-Z][a-zA-Z0-9-]*(?:attribute)*?\\s*/?>|^<\\?[\\s\\S]*?\\?>|^<![a-zA-Z]+\\s[\\s\\S]*?>|^<!\\[CDATA\\[[\\s\\S]*?\\]\\]>").replace("comment",tR).replace("attribute",/\s+[a-zA-Z:_][\w.:-]*(?:\s*=\s*"[^"]*"|\s*=\s*'[^']*'|\s*=\s*[^\s"'=<>`]+)?/).getRegex(),NE=/\[(?:\\[\s\S]|[^\[\]\\])*\]/,Op=Oe(/(?:\[(?:brackets|\\[\s\S]|[^\[\]\\])*\]|\\[\s\S]|`+(?!`)[^`]*?`+(?!`)|``+(?=\])|[^\[\]\\`])*?/).replace("brackets",NE).getRegex(),nR=Oe(/^!?\[(label)\]\([ \t\n]*(href)(?:(?:[ \t]+(?:\n[ \t]*)?|\n[ \t]*)(title))?[ \t\n]*\)/).replace("label",Op).replace("href",/<(?:\\.|[^\n<>\\])+>|[^ \t\n\x00-\x1f]+|(?=\))/).replace("title",/"(?:\\[\s\S]|[^"\\])*"|'(?:\\[\s\S]|[^'\\])*'|\((?:\\[\s\S]|[^)\\])*\)/).getRegex(),iR=Oe(/^!?\[(label)\]\[(ref)\]/).replace("label",Op).replace("ref",Ay).getRegex(),oR=Oe(/^!?\[(ref)\](?:\[\])?/).replace("ref",Ay).getRegex(),XI=/(?!\s*\])(?:\\[\s\S]|[^\[\]\\]){1,999}/,aR=Oe(/(?:[^\[\]\\`]*(?:\[(?:brackets|\\[\s\S]|[^\[\]\\])*\]|\\[\s\S]|`+(?!`)[^`]*?`+(?!`)|``+(?=\]))){0,999}?[^\[\]\\`]*?/).replace("brackets",NE).getRegex(),sR=Oe("reflink|nolink(?!\\()","g").replace("reflink",Oe(/^!?\[(label)\]\[(ref)\]/).replace("label",aR).replace("ref",XI).getRegex()).replace("nolink",Oe(/^!?\[(ref)\](?:\[\])?/).replace("ref",XI).getRegex()).getRegex(),QI=/[hH][tT][tT][pP][sS]?|[fF][tT][pP]/,lR=Oe(/(?:mailto:email|xmpp:email(?:\/[A-Za-z0-9@.]+)?)/).replace(/email/g,/[A-Za-z0-9._+-]+@[a-zA-Z0-9-_]+(?:\.[a-zA-Z0-9-_]*[a-zA-Z0-9])+(?![\w-])/).getRegex(),Py={_backpedal:go,anyPunctuation:XP,anyPunctuationOutsideCode:QP,autolink:eR,blockSkip:VP,br:SE,code:PP,del:go,delLDelim:go,delRDelim:go,emStrongLDelim:FP,emStrongRDelimAst:HP,emStrongRDelimUnd:qP,escape:DP,link:nR,nolink:oR,punctuation:UP,reflink:iR,reflinkSearch:sR,tag:rR,text:RP,url:go},cR={...Py,emStrongLDelim:ZP,emStrongRDelimAst:WP,emStrongRDelimUnd:GP,link:Oe(/^!?\[(label)\]\((.*?)\)/).replace("label",Op).getRegex(),reflink:Oe(/^!?\[(label)\]\s*\[([^\]]*)\]/).replace("label",Op).getRegex()},Iy={...Py,emStrongRDelimAst:KP,emStrongLDelim:BP,delLDelim:JP,delRDelim:YP,url:Oe(/^emailProtocol|^((?:protocol):\/\/|www\.)(?:[a-zA-Z0-9\-]+\.?)+[^\s<]*|^email/).replace("emailProtocol",lR).replace("protocol",QI).replace("email",/[A-Za-z0-9._+-]+(@)[a-zA-Z0-9-_]+(?:\.[a-zA-Z0-9-_]*[a-zA-Z0-9])+(?![\w-])/).getRegex(),_backpedal:/(?:[^?!.,:;*_'"~()&]+|\([^)]*\)|&(?![a-zA-Z0-9]+;$)|[?!.,:;*_'"~)]+(?!$))+/,del:/^(~~?)(?=[^\s~])((?:\\[\s\S]|[^\\])*?(?:\\[\s\S]|[^\s~\\]))\1(?=[^~]|$)/,text:Oe(/^(?:[^a-zA-Z0-9](?=emailProtocol)|(`+|~+|[^`~])(?:(?=[`~])|(?= {2,}\n)|(?=[a-zA-Z0-9.!#$%&'*+\/=?_`{\|}~-]+@)|[\s\S]*?(?:(?=[\\<!\[`*~_]|\b_|protocol:\/\/|wwwStart|$)|[^ ](?= {2,}\n)|[^a-zA-Z0-9](?=emailProtocol)|[^a-zA-Z0-9.!#$%&'*+\/=?_`{\|}~-](?=[a-zA-Z0-9.!#$%&'*+\/=?_`{\|}~-]+@))))/).replace("protocol",QI).replace(/emailProtocol/g,/(?:mailto|xmpp):/).replace("wwwStart",kE?"(?<![^\\s*_~(])www\\.":"www\\.").getRegex()},uR={...Iy,br:Oe(SE).replace("{2,}","*").getRegex(),text:Oe(Iy.text).replace("\\b_","\\b_| {2,}\\n").replace(/\{2,\}/g,"*").getRegex()},Ep={normal:Dy,gfm:AP,pedantic:OP},rc={normal:Py,gfm:Iy,breaks:uR,pedantic:cR},dR={"&":"&","<":"<",">":">",'"':""","'":"'"},eE=e=>dR[e];Ja=new WeakMap;Ya=class{constructor(e){G(this,"options",void 0),G(this,"rules",void 0),G(this,"lexer",void 0),this.options=e||bo}space(e){let t=this.rules.block.newline.exec(e);if(t&&t[0].length>0)return{type:"space",raw:t[0]}}code(e){let t=this.rules.block.code.exec(e);if(t){let n=this.options.pedantic?t[0]:nE(t[0]);return{type:"code",raw:n,codeBlockStyle:"indented",text:n.replace(this.rules.other.codeRemoveIndent,"")}}}fences(e){let t=this.rules.block.fences.exec(e);if(t){let n=t[0],i=vR(n,t[3]||"",this.rules);return{type:"code",raw:n,lang:t[2]?t[2].trim().replace(this.rules.inline.anyPunctuation,"$1"):t[2],text:i}}}heading(e){let t=this.rules.block.heading.exec(e);if(t){let n=t[2].trim();if(this.rules.other.endingHash.test(n)){let i=ri(n,"#");(this.options.pedantic||!i||this.rules.other.endingSpaceTabChar.test(i))&&(n=i.trim())}return{type:"heading",raw:ri(t[0],`
|
|
104
104
|
`),depth:t[1].length,text:n,tokens:this.lexer.inline(n)}}}hr(e){let t=this.rules.block.hr.exec(e);if(t)return{type:"hr",raw:ri(t[0],`
|
|
105
105
|
`)}}blockquote(e){let t=this.rules.block.blockquote.exec(e);if(t){let n=ri(t[0],`
|
|
106
106
|
`).split(`
|
|
@@ -130,7 +130,7 @@ ${k}`)?` ${pe.replace(/^ {0,3}/,"")}`:k;p+=`
|
|
|
130
130
|
`):[],o={type:"table",raw:ri(t[0],`
|
|
131
131
|
`),header:[],align:[],rows:[]};if(n.length===i.length){for(let a of i)this.rules.other.tableAlignRight.test(a)?o.align.push("right"):this.rules.other.tableAlignCenter.test(a)?o.align.push("center"):this.rules.other.tableAlignLeft.test(a)?o.align.push("left"):o.align.push(null);for(let a=0;a<n.length;a++)o.header.push({text:n[a],tokens:this.lexer.inline(n[a]),header:!0,align:o.align[a]});for(let a of r)o.rows.push(rE(a,o.header.length).map((s,l)=>({text:s,tokens:this.lexer.inline(s),header:!1,align:o.align[l]})));return o}}lheading(e){let t=this.rules.block.lheading.exec(e);if(t){let n=t[1].trim();return{type:"heading",raw:ri(t[0],`
|
|
132
132
|
`),depth:t[2].charAt(0)==="="?1:2,text:n,tokens:this.lexer.inline(n)}}}paragraph(e){let t=this.rules.block.paragraph.exec(e);if(t){let n=t[1].charAt(t[1].length-1)===`
|
|
133
|
-
`?t[1].slice(0,-1):t[1];return{type:"paragraph",raw:t[0],text:n,tokens:this.lexer.inline(n)}}}text(e){let t=this.rules.block.text.exec(e);if(t)return{type:"text",raw:t[0],text:t[0],tokens:this.lexer.inline(t[0])}}escape(e){let t=this.rules.inline.escape.exec(e);if(t)return{type:"escape",raw:t[0],text:t[1]}}tag(e){let t=this.rules.inline.tag.exec(e);if(t)return!this.lexer.state.inLink&&this.rules.other.startATag.test(t[0])?this.lexer.state.inLink=!0:this.lexer.state.inLink&&this.rules.other.endATag.test(t[0])&&(this.lexer.state.inLink=!1),!this.lexer.state.inRawBlock&&this.rules.other.startPreScriptTag.test(t[0])?this.lexer.state.inRawBlock=!0:this.lexer.state.inRawBlock&&this.rules.other.endPreScriptTag.test(t[0])&&(this.lexer.state.inRawBlock=!1),{type:"html",raw:t[0],inLink:this.lexer.state.inLink,inRawBlock:this.lexer.state.inRawBlock,block:!1,text:t[0]}}link(e){if(this.lexer.state.linkParenPossible===!1)return;let t=this.rules.inline.link.exec(e);if(t){let n=t[0].charAt(0)==="!"?2:1;if(!this.options.pedantic&&aE(e,t[1],n,this.rules))return;let i=t[2].trim();if(!this.options.pedantic&&this.rules.other.startAngleBracket.test(i)){if(!this.rules.other.endAngleBracket.test(i))return;let s=ri(i.slice(0,-1),"\\");if((i.length-s.length)%2==0)return}else{let s=iE(t[2],"()");if(s===-2)return;if(s>-1){let l=(t[0].indexOf("!")===0?5:4)+t[1].length+s;t[2]=t[2].substring(0,s),t[0]=t[0].substring(0,l).trim(),t[3]=""}}let r=ri(t[0].slice(0,-1),"\\");if((t[0].length-r.length)%2==0)return;let o=t[2],a="";if(this.options.pedantic){let s=this.rules.other.pedanticHrefTitle.exec(o);s&&(o=s[1],a=s[3])}else a=t[3]?t[3].slice(1,-1):"";return o=o.trim(),this.rules.other.startAngleBracket.test(o)&&(o=this.options.pedantic&&!this.rules.other.endAngleBracket.test(i)?o.slice(1):o.slice(1,-1)),oE(t,{href:o&&o.replace(this.rules.inline.anyPunctuation,"$1"),title:a&&a.replace(this.rules.inline.anyPunctuation,"$1")},t[0],this.lexer,this.rules)}}reflink(e,t){let n;if((n=this.rules.inline.reflink.exec(e))||(n=this.rules.inline.nolink.exec(e))){let i=n[0].charAt(0)==="!"?2:1;if(!this.options.pedantic&&aE(e,n[1],i,this.rules))return;let r=t[Dp(n[2]||n[1])];if(!r){let o=n[0].charAt(0);return{type:"text",raw:o,text:o}}return oE(n,r,n[0],this.lexer,this.rules)}}emStrong(e,t,n=""){let i=this.rules.inline.emStrongLDelim.exec(e);if(!i||!i[1]&&!i[2]&&!i[3]&&!i[4])return;let r=i[0][0],o=n===r,a=t.length-e.length,s=a;for(;!this.options.pedantic&&s>0&&t[s-1]===r;)s--;let l=[...t.slice(Math.max(0,s-2),s)].at(-1)??"",u=l==="*"||l==="_"||!!this.rules.inline.punctuation.exec(l);s<a&&(n=l);let d=s<a?u:!!this.rules.inline.punctuation.exec(n);if(i[4]&&n.match(this.rules.other.unicodeAlphaNumeric))return;let p=i[1]||i[3]||"";if(!p||!n||d){let m=[...i[0]].length-1,f,h,v=m,k=0,T=a-s+m,S=!this.options.pedantic&&!!l.trim()&&(!!p||r==="*"&&!u);if(r!=="*"&&r!=="_")return;let z=r==="*"?this.rules.inline.emStrongRDelimAst:this.rules.inline.emStrongRDelimUnd,j=
|
|
133
|
+
`?t[1].slice(0,-1):t[1];return{type:"paragraph",raw:t[0],text:n,tokens:this.lexer.inline(n)}}}text(e){let t=this.rules.block.text.exec(e);if(t)return{type:"text",raw:t[0],text:t[0],tokens:this.lexer.inline(t[0])}}escape(e){let t=this.rules.inline.escape.exec(e);if(t)return{type:"escape",raw:t[0],text:t[1]}}tag(e){let t=this.rules.inline.tag.exec(e);if(t)return!this.lexer.state.inLink&&this.rules.other.startATag.test(t[0])?this.lexer.state.inLink=!0:this.lexer.state.inLink&&this.rules.other.endATag.test(t[0])&&(this.lexer.state.inLink=!1),!this.lexer.state.inRawBlock&&this.rules.other.startPreScriptTag.test(t[0])?this.lexer.state.inRawBlock=!0:this.lexer.state.inRawBlock&&this.rules.other.endPreScriptTag.test(t[0])&&(this.lexer.state.inRawBlock=!1),{type:"html",raw:t[0],inLink:this.lexer.state.inLink,inRawBlock:this.lexer.state.inRawBlock,block:!1,text:t[0]}}link(e){if(this.lexer.state.linkParenPossible===!1)return;let t=this.rules.inline.link.exec(e);if(t){let n=t[0].charAt(0)==="!"?2:1;if(!this.options.pedantic&&aE(e,t[1],n,this.rules))return;let i=t[2].trim();if(!this.options.pedantic&&this.rules.other.startAngleBracket.test(i)){if(!this.rules.other.endAngleBracket.test(i))return;let s=ri(i.slice(0,-1),"\\");if((i.length-s.length)%2==0)return}else{let s=iE(t[2],"()");if(s===-2)return;if(s>-1){let l=(t[0].indexOf("!")===0?5:4)+t[1].length+s;t[2]=t[2].substring(0,s),t[0]=t[0].substring(0,l).trim(),t[3]=""}}let r=ri(t[0].slice(0,-1),"\\");if((t[0].length-r.length)%2==0)return;let o=t[2],a="";if(this.options.pedantic){let s=this.rules.other.pedanticHrefTitle.exec(o);s&&(o=s[1],a=s[3])}else a=t[3]?t[3].slice(1,-1):"";return o=o.trim(),this.rules.other.startAngleBracket.test(o)&&(o=this.options.pedantic&&!this.rules.other.endAngleBracket.test(i)?o.slice(1):o.slice(1,-1)),oE(t,{href:o&&o.replace(this.rules.inline.anyPunctuation,"$1"),title:a&&a.replace(this.rules.inline.anyPunctuation,"$1")},t[0],this.lexer,this.rules)}}reflink(e,t){let n;if((n=this.rules.inline.reflink.exec(e))||(n=this.rules.inline.nolink.exec(e))){let i=n[0].charAt(0)==="!"?2:1;if(!this.options.pedantic&&aE(e,n[1],i,this.rules))return;let r=t[Dp(n[2]||n[1])];if(!r){let o=n[0].charAt(0);return{type:"text",raw:o,text:o}}return oE(n,r,n[0],this.lexer,this.rules)}}emStrong(e,t,n=""){let i=this.rules.inline.emStrongLDelim.exec(e);if(!i||!i[1]&&!i[2]&&!i[3]&&!i[4])return;let r=i[0][0],o=n===r,a=t.length-e.length,s=a;for(;!this.options.pedantic&&s>0&&t[s-1]===r;)s--;let l=[...t.slice(Math.max(0,s-2),s)].at(-1)??"",u=l==="*"||l==="_"||!!this.rules.inline.punctuation.exec(l);s<a&&(n=l);let d=s<a?u:!!this.rules.inline.punctuation.exec(n);if(i[4]&&n.match(this.rules.other.unicodeAlphaNumeric))return;let p=i[1]||i[3]||"";if(!p||!n||d){let m=[...i[0]].length-1,f,h,v=m,k=0,T=a-s+m,S=!this.options.pedantic&&!!l.trim()&&(!!p||r==="*"&&!u);if(r!=="*"&&r!=="_")return;let z=r==="*"?this.rules.inline.emStrongRDelimAst:this.rules.inline.emStrongRDelimUnd,j=hR(this,t,r),O=t.length-e.length+m;if(j<O)return;t=t.slice(-1*e.length+m);let U=j-O;for(z.lastIndex=0;(i=z.exec(t))!==null&&!(i.index>U);){if(f=i[1]||i[2]||i[3]||i[4]||i[5]||i[6],!f)continue;if(h=[...f].length,i[3]||i[4]){v+=h;continue}if(i[5]||i[6]||S){if(o&&(i[5]||i[6]))break;if(T%3&&!((T+h)%3)){k+=h;continue}}if(v-=h,v>0)continue;h=Math.min(h,h+v+k);let J=[...i[0]][0].length,W=e.slice(0,m+i.index+J+h);if(Math.min(m,h)%2){let se=W.slice(1,-1);return{type:"em",raw:W,text:se,tokens:this.lexer.inlineTokens(se)}}let ce=W.slice(2,-2);return{type:"strong",raw:W,text:ce,tokens:this.lexer.inlineTokens(ce)}}}}codespan(e){let t=this.rules.inline.code.exec(e);if(t){let n=t[2].replace(this.rules.other.newLineCharGlobal," "),i=this.rules.other.nonSpaceChar.test(n),r=this.rules.other.startingSpaceChar.test(n)&&this.rules.other.endingSpaceChar.test(n);return i&&r&&(n=n.substring(1,n.length-1)),{type:"codespan",raw:t[0],text:n}}}br(e){let t=this.rules.inline.br.exec(e);if(t)return{type:"br",raw:t[0]}}del(e,t,n=""){let i=this.rules.inline.delLDelim.exec(e);if(i&&(!i[1]||!n||this.rules.inline.punctuation.exec(n))){let r=[...i[0]].length-1,o,a,s=r,l=this.rules.inline.delRDelim,u=gR(this,t),d=t.length-e.length+r;if(u<d)return;t=t.slice(-1*e.length+r);let p=u-d;for(l.lastIndex=0;(i=l.exec(t))!==null&&!(i.index>p);){if(o=i[1]||i[2]||i[3]||i[4]||i[5]||i[6],!o||(a=[...o].length,a!==r))continue;if(i[3]||i[4]){s+=a;continue}if(s-=a,s>0)continue;a=Math.min(a,a+s);let m=[...i[0]][0].length,f=e.slice(0,r+i.index+m+a),h=f.slice(r,-r);return{type:"del",raw:f,text:h,tokens:this.lexer.inlineTokens(h)}}}}autolink(e){let t=this.rules.inline.autolink.exec(e);if(t){let n,i;return t[2]==="@"?(n=t[1],i="mailto:"+n):(n=t[1],i=n),{type:"link",raw:t[0],text:n,href:i,autolink:!0,tokens:[{type:"text",raw:n,text:n}]}}}url(e){let t;if(t=this.rules.inline.url.exec(e)){let n,i;if(t[2]==="@")n=t[0],i="mailto:"+n;else{let r;do r=t[0],t[0]=this.rules.inline._backpedal.exec(t[0])?.[0]??"";while(r!==t[0]);n=t[0],i=t[1]==="www."?"http://"+t[0]:t[0]}return{type:"link",raw:t[0],text:n,href:i,autolink:!0,tokens:[{type:"text",raw:n,text:n}]}}}inlineText(e){let t=this.rules.inline.text.exec(e);if(t){let n=this.lexer.state.inRawBlock;return{type:"text",raw:t[0],text:n?t[0]:pR(t[0]),escaped:n}}}},cn=(oc=new WeakSet,class Ey{constructor(t){wP(this,oc),G(this,"tokens",void 0),G(this,"options",void 0),G(this,"state",void 0),G(this,"inlineQueue",void 0),G(this,"tokenizer",void 0),this.tokens=[],this.tokens.links=Object.create(null),this.options=t||bo,this.options.tokenizer=this.options.tokenizer||new Ya,this.tokenizer=this.options.tokenizer,this.tokenizer.options=this.options,this.tokenizer.lexer=this,this.inlineQueue=[],this.state={inLink:!1,inRawBlock:!1,linkEmitted:!1,linkParenPossible:!0,top:!0};let n={other:jt,block:Ep.normal,inline:rc.normal};this.options.pedantic?(n.block=Ep.pedantic,n.inline=rc.pedantic):this.options.gfm&&(n.block=Ep.gfm,n.inline=this.options.breaks?rc.breaks:rc.gfm),this.tokenizer.rules=n}static get rules(){return{block:Ep,inline:rc}}static lex(t,n){return new Ey(n).lex(t)}static lexInline(t,n){return new Ey(n).inlineTokens(t)}lex(t){t=t.replace(jt.carriageReturn,`
|
|
134
134
|
`),this.blockTokens(t,this.tokens);for(let n=0;n<this.inlineQueue.length;n++){let i=this.inlineQueue[n];this.state.inRawBlock=!1,this.inlineTokens(i.src,i.tokens)}return this.inlineQueue=[],this.tokens}blockTokens(t,n=[],i=!1){this.tokenizer.lexer=this,this.options.pedantic&&(t=t.replace(jt.tabCharGlobal," ").replace(jt.spaceLine,""));let r=1/0;for(;t;){if(t.length<r)r=t.length;else{this.infiniteLoopError(t.charCodeAt(0));break}let o;if(this.options.extensions?.block?.some(s=>(o=s.call({lexer:this},t,n))?(t=t.substring(o.raw.length),n.push(o),!0):!1))continue;if(o=this.tokenizer.space(t)){t=t.substring(o.raw.length);let s=n.at(-1);o.raw.length===1&&s!==void 0?s.raw+=`
|
|
135
135
|
`:n.push(o);continue}if(o=this.tokenizer.code(t)){t=t.substring(o.raw.length);let s=n.at(-1);s?.type==="paragraph"||s?.type==="text"?(s.raw+=(s.raw.endsWith(`
|
|
136
136
|
`)?"":`
|
|
@@ -144,7 +144,7 @@ ${k}`)?` ${pe.replace(/^ {0,3}/,"")}`:k;p+=`
|
|
|
144
144
|
`+o.text,this.inlineQueue.pop(),this.inlineQueue.at(-1).src=s.text):n.push(o),i=a.length!==t.length,t=t.substring(o.raw.length)}else if(o=this.tokenizer.text(t)){t=t.substring(o.raw.length);let s=n.at(-1);s?.type==="text"?(s.raw+=(s.raw.endsWith(`
|
|
145
145
|
`)?"":`
|
|
146
146
|
`)+o.raw,s.text+=`
|
|
147
|
-
`+o.text,this.inlineQueue.pop(),this.inlineQueue.at(-1).src=s.text):n.push(o)}else if(t){this.infiniteLoopError(t.charCodeAt(0));break}}return this.state.top=!0,n}inline(t,n=[]){return this.inlineQueue.push({src:t,tokens:n}),n}linkInText(t){if(!t.includes("["))return!1;let n=this.tokenizer.rules.inline.link;for(let i of t.matchAll(this.tokenizer.rules.inline.blockSkip))if(n.test(i[0])&&t.charAt(i.index-1)!=="!")return!0;for(let i of t.matchAll(this.tokenizer.rules.inline.reflinkSearch)){let r=i[0],o=r.lastIndexOf("[");if(r.charAt(0)!=="!"&&Object.hasOwn(this.tokens.links,Dp(r.slice(o+1,-1)))&&!(o>1&&this.linkInText(r.slice(1,o-1))))return!0}return!1}inlineTokens(t,n=[]){this.tokenizer.lexer=this;let i=this.state.linkParenPossible;this.state.linkParenPossible=i&&t.includes(")");try{return Sy(oc,this,
|
|
147
|
+
`+o.text,this.inlineQueue.pop(),this.inlineQueue.at(-1).src=s.text):n.push(o)}else if(t){this.infiniteLoopError(t.charCodeAt(0));break}}return this.state.top=!0,n}inline(t,n=[]){return this.inlineQueue.push({src:t,tokens:n}),n}linkInText(t){if(!t.includes("["))return!1;let n=this.tokenizer.rules.inline.link;for(let i of t.matchAll(this.tokenizer.rules.inline.blockSkip))if(n.test(i[0])&&t.charAt(i.index-1)!=="!")return!0;for(let i of t.matchAll(this.tokenizer.rules.inline.reflinkSearch)){let r=i[0],o=r.lastIndexOf("[");if(r.charAt(0)!=="!"&&Object.hasOwn(this.tokens.links,Dp(r.slice(o+1,-1)))&&!(o>1&&this.linkInText(r.slice(1,o-1))))return!0}return!1}inlineTokens(t,n=[]){this.tokenizer.lexer=this;let i=this.state.linkParenPossible;this.state.linkParenPossible=i&&t.includes(")");try{return Sy(oc,this,bR).call(this,t,n)}finally{this.state.linkParenPossible=i}}infiniteLoopError(t){let n="Infinite loop on byte: "+t;if(this.options.silent)console.error(n);else throw Error(n)}});Pp=class{constructor(e){G(this,"options",void 0),G(this,"parser",void 0),this.options=e||bo}space(e){return""}code({text:e,lang:t,escaped:n}){let i=(t||"").match(jt.notSpaceStart)?.[0],r=e?e.replace(jt.endingNewline,"")+`
|
|
148
148
|
`:"";return i?'<pre><code class="language-'+Pr(i)+'">'+(n?r:Pr(r,!0))+`</code></pre>
|
|
149
149
|
`:"<pre><code>"+(n?r:Pr(r,!0))+`</code></pre>
|
|
150
150
|
`}blockquote({tokens:e}){return`<blockquote>
|
|
@@ -162,11 +162,11 @@ ${this.parser.parse(e)}</blockquote>
|
|
|
162
162
|
`}tablerow({text:e}){return`<tr>
|
|
163
163
|
${e}</tr>
|
|
164
164
|
`}tablecell(e){let t=this.parser.parseInline(e.tokens),n=e.header?"th":"td";return(e.align?`<${n} align="${e.align}">`:`<${n}>`)+t+`</${n}>
|
|
165
|
-
`}strong({tokens:e}){return`<strong>${this.parser.parseInline(e)}</strong>`}em({tokens:e}){return`<em>${this.parser.parseInline(e)}</em>`}codespan({text:e}){return`<code>${Pr(e,!0)}</code>`}br(e){return"<br>"}del({tokens:e}){return`<del>${this.parser.parseInline(e)}</del>`}link({href:e,title:t,text:n,tokens:i,autolink:r}){let o=r?Pr(n,!0):this.parser.parseInline(i),a=tE(e);if(a===null)return o;e=Pr(a,r);let s='<a href="'+e+'"';return t&&(s+=' title="'+Pr(t)+'"'),s+=">"+o+"</a>",s}image({href:e,title:t,text:n,tokens:i}){i&&(n=this.parser.parseInline(i,this.parser.textRenderer));let r=tE(e);if(r===null)return Pr(n);e=r;let o=`<img src="${Pr(e)}" alt="${Pr(n)}"`;return t&&(o+=` title="${Pr(t)}"`),o+=">",o}text(e){return"tokens"in e&&e.tokens?this.parser.parseInline(e.tokens):"escaped"in e&&e.escaped?e.text:Pr(e.text)}},Uy=class{constructor(){G(this,"parser",void 0)}strong({text:e,tokens:t}){return t?this.parser.parseInline(t,this):e}em({text:e,tokens:t}){return t?this.parser.parseInline(t,this):e}codespan({text:e}){return e}del({text:e,tokens:t}){return t?this.parser.parseInline(t,this):e}html({text:e}){return e}text({text:e}){return e}link({text:e,tokens:t}){return t?this.parser.parseInline(t,this):e}image({text:e,tokens:t}){return t?this.parser.parseInline(t,this):e}br(){return""}checkbox({raw:e}){return e}},un=class Ty{constructor(t){G(this,"options",void 0),G(this,"renderer",void 0),G(this,"textRenderer",void 0),this.options=t||bo,this.options.renderer=this.options.renderer||new Pp,this.renderer=this.options.renderer,this.renderer.options=this.options,this.renderer.parser=this,this.textRenderer=new Uy,this.textRenderer.parser=this}static parse(t,n){return new Ty(n).parse(t)}static parseInline(t,n){return new Ty(n).parseInline(t)}parse(t){this.renderer.parser=this;let n="";for(let i=0;i<t.length;i++){let r=t[i];if(this.options.extensions?.renderers?.[r.type]){let a=r,s=this.options.extensions.renderers[a.type].call({parser:this},a);if(s!==!1||!["space","hr","heading","code","table","blockquote","list","checkbox","html","def","paragraph","text"].includes(a.type)){n+=s||"";continue}}let o=r;switch(o.type){case"space":n+=this.renderer.space(o);break;case"hr":n+=this.renderer.hr(o);break;case"heading":n+=this.renderer.heading(o);break;case"code":n+=this.renderer.code(o);break;case"table":n+=this.renderer.table(o);break;case"blockquote":n+=this.renderer.blockquote(o);break;case"list":n+=this.renderer.list(o);break;case"checkbox":n+=this.renderer.checkbox(o);break;case"html":n+=this.renderer.html(o);break;case"def":n+=this.renderer.def(o);break;case"paragraph":n+=this.renderer.paragraph(o);break;case"text":n+=this.renderer.text(o);break;default:{let a='Token with "'+o.type+'" type was not found.';if(this.options.silent)return console.error(a),"";throw Error(a)}}}return n}parseInline(t,n=this.renderer){this.renderer.parser=this;let i="";for(let r=0;r<t.length;r++){let o=t[r];if(this.options.extensions?.renderers?.[o.type]){let s=this.options.extensions.renderers[o.type].call({parser:this},o);if(s!==!1||!["escape","html","link","image","checkbox","strong","em","codespan","br","del","text"].includes(o.type)){i+=s||"";continue}}let a=o;switch(a.type){case"escape":i+=n.text(a);break;case"html":i+=n.html(a);break;case"link":i+=n.link(a);break;case"image":i+=n.image(a);break;case"checkbox":i+=n.checkbox(a);break;case"strong":i+=n.strong(a);break;case"em":i+=n.em(a);break;case"codespan":i+=n.codespan(a);break;case"br":i+=n.br(a);break;case"del":i+=n.del(a);break;case"text":i+=n.text(a);break;default:{let s='Token with "'+a.type+'" type was not found.';if(this.options.silent)return console.error(s),"";throw Error(s)}}}return i}},ic=(Ip=class{constructor(e){G(this,"options",void 0),G(this,"block",void 0),this.options=e||bo}preprocess(e){return e}postprocess(e){return e}processAllTokens(e){return e}emStrongMask(e){return e}provideLexer(e=this.block){return e?cn.lex:cn.lexInline}provideParser(e=this.block){return e?un.parse:un.parseInline}},G(Ip,"passThroughHooks",new Set(["preprocess","postprocess","processAllTokens","emStrongMask"])),G(Ip,"passThroughHooksRespectAsync",new Set(["preprocess","postprocess","processAllTokens"])),Ip);
|
|
166
|
-
Please report this to https://github.com/markedjs/marked.`,e){let i="<p>An error occurred:</p><pre>"+Pr(n.message+"",!0)+"</pre>";return t?Promise.resolve(i):i}if(t)return Promise.reject(n);throw n}}},vo=new yR;et.options=et.setOptions=function(e){return vo.setOptions(e),et.defaults=vo.defaults,wE(et.defaults),et},et.getDefaults=Ny,et.defaults=bo;et.use=wR,et.walkTokens=function(e,t){return vo.walkTokens(e,t)},et.parseInline=vo.parseInline,et.Parser=un,et.parser=un.parse,et.Renderer=Pp,et.TextRenderer=Uy,et.Lexer=cn,et.lexer=cn.lex,et.Tokenizer=Ya,et.Hooks=ic,et.parse=et,et.options,et.setOptions,et.walkTokens,et.parseInline,un.parse,cn.lex;kR=["aria-label"],xR={class:"px-4 pb-2 pt-4"},_R=["innerHTML"],$R=["onClick"],SR=Pe({__name:"ChatCardBlock",props:{spec:{},inverted:{type:Boolean}},emits:["action"],setup(e,{emit:t}){let n=e,i=t,r=R(()=>{if(!n.spec.body)return"";let m=et.parse(n.spec.body,{async:!1});return yE.sanitize(m,{ADD_ATTR:["target"]})}),o=R(()=>n.inverted?"rgba(255, 255, 255, 0.22)":"rgba(0, 0, 0, 0.16)"),a=R(()=>n.inverted?"rgba(255, 255, 255, 0.12)":"color-mix(in oklch, var(--color-theme-200) 80%, transparent)"),s=R(()=>n.inverted?"rgba(255, 255, 255, 0.95)":"var(--color-theme-900)"),l=R(()=>n.inverted?"rgba(255, 255, 255, 0.8)":"var(--color-theme-800)"),u=R(()=>n.inverted?`inset 0 0 0 1px ${o.value}`:`inset 0 0 0 1px ${o.value}, 0 4px 16px rgba(15, 23, 42, 0.05)`),d=R(()=>n.inverted?"transparent":"var(--color-theme-0)");function p(m){return m==="primary"||m==="destructive"?{background:n.inverted?"rgba(255, 255, 255, 0.92)":"var(--color-theme-900)",color:n.inverted?"var(--color-theme-900)":"#fff"}:{background:"var(--color-theme-100)",color:s.value}}return(m,f)=>(w(),$("div",{"data-test":"chat-card",class:"my-6 w-full self-start overflow-hidden rounded-2xl",style:Se({background:d.value,boxShadow:u.value}),"aria-label":e.spec.title},[b("div",xR,[b("div",{class:"text-[14px] font-semibold leading-tight",style:Se({color:s.value})},de(e.spec.title),5)]),r.value?(w(),$("div",{key:0,class:"chat-msg-prose px-4 pb-4 pt-2 text-[14px] leading-relaxed",style:Se({color:l.value}),innerHTML:r.value},null,12,_R)):te("",!0),e.spec.actions?.length?(w(),$("div",{key:1,class:"flex flex-wrap items-center gap-2 px-3 py-2.5",style:Se({borderTop:`1px solid ${a.value}`})},[(w(!0),$(ge,null,st(e.spec.actions,h=>(w(),$("button",{key:h.label,type:"button","data-test":"chat-card-action",class:"inline-flex h-10 items-center justify-center rounded-full px-5 text-[14px] font-semibold transition-colors duration-150 active:opacity-80",style:Se(p(h.style)),onClick:v=>i("action",h.reply)},de(h.label),13,$R))),128))],4)):te("",!0)],12,kR))}}),sE=112,vy=52,Np=14,Ka=54,lE=34,IR=260;OR=5.4,DR=10,PR=15,RR=16;jR=["data-visual-type","data-chart-type","data-stacking","data-diagram-type","aria-label"],MR={class:"mb-2.5"},LR=["aria-label"],VR={key:0,"data-test":"chat-visual-horizontal-bars",class:"grid gap-3"},FR={class:"mb-1 flex items-start justify-between gap-3 text-[12px]"},BR=["viewBox"],ZR=["x1","x2","y1","y2"],HR=["x","y"],KR=["data-row-index","data-series-index","data-data-key","x","y","width","height"],WR=["data-trend-key","d"],qR=["d"],GR=["cx","cy"],JR=["cx","cy"],YR=["x","y","text-anchor","transform"],XR={key:2,class:"mt-2.5 flex flex-wrap items-center gap-x-4 gap-y-1.5"},QR={key:1,class:"grid gap-3"},eU={class:"mb-1 flex items-baseline justify-between gap-3 text-[12px]"},tU={class:"shrink-0 tabular-nums"},rU={key:2,class:"overflow-x-auto"},nU=["viewBox","aria-label"],iU=["data-from","data-to","x1","y1","x2","y2"],oU=["cx","cy"],aU=["x","y"],sU=["data-node-id","data-node-kind","transform"],lU=["points"],cU=["width","height"],uU=["width","height"],dU={xmlns:"http://www.w3.org/1999/xhtml",class:"flex h-full min-w-0 flex-col items-center justify-center text-center"},pU=Pe({__name:"ChatVisualBlock",props:{result:{},inverted:{type:Boolean}},setup(e){let t=e,n=Q(),i=We(360),r;Ut(()=>{typeof ResizeObserver<"u"&&n.value&&(r=new ResizeObserver(_=>{let D=_[0]?.contentRect.width;D&&(i.value=Math.round(D))}),r.observe(n.value))}),Da(()=>r?.disconnect());let o=R(()=>Math.min(720,Math.max(280,i.value))),a=R(()=>t.result.ok?t.result.spec:null),s=R(()=>a.value?.visualType==="chart"?a.value:null),l=R(()=>a.value?.visualType==="diagram"?a.value:null);function u(_){return _?.chartType==="bar"||_?.chartType==="line"||_?.chartType==="scatter"}function d(_){return _?.chartType==="pie"}let p=R(()=>s.value?.data??[]),m=R(()=>u(s.value)?s.value:null),f=R(()=>m.value?.series??[]),h=R(()=>d(s.value)?s.value:null),v=R(()=>m.value?.chartType==="bar"&&m.value.stacking==="stacked");function k(_){return typeof _=="number"&&Number.isFinite(_)?_:null}function T(_,D){return String(_[D]??"").trim()}function S(_,D){let y=_.map(Y=>T(Y,D)).filter(Boolean);if(!y.length)return!1;let P=Math.max(...y.map(Y=>Y.length)),E=y.reduce((Y,ie)=>Y+ie.length,0)/y.length;return P>=16||y.length>5&&E>=10}function z(_,D){return _.data.map((y,P)=>{let E=k(y[D]);return E===null?null:{index:P,value:E}}).filter(y=>y!==null)}function j(_){if(_.length<2)return null;let D=_.length,y=_.reduce((ve,we)=>ve+we.index,0),P=_.reduce((ve,we)=>ve+we.value,0),E=_.reduce((ve,we)=>ve+we.index*we.index,0),Y=_.reduce((ve,we)=>ve+we.index*we.value,0),ie=D*E-y*y;if(ie===0)return null;let fe=(D*Y-y*P)/ie;return{slope:fe,intercept:(P-fe*y)/D}}let O=R(()=>{let _=[],D=m.value;if(!D)return _;if(D.chartType==="bar"&&D.stacking==="stacked")for(let y of D.data){let P=0,E=0;for(let Y of D.series){let ie=k(y[Y.dataKey]);ie!==null&&(ie>=0?P+=ie:E+=ie)}_.push(P,E)}else for(let y of D.data)for(let P of D.series){let E=k(y[P.dataKey]);E!==null&&_.push(E)}if(D.trendLine&&(D.chartType==="line"||D.chartType==="scatter")){let y=z(D,D.trendLine.dataKey);_.push(...y.map(E=>E.value));let P=j(y);if(P&&y.length){let E=y[0].index,Y=y[y.length-1].index;_.push(P.intercept+P.slope*E,P.intercept+P.slope*Y)}}return _});function U(_,D){let y=_>0?_:1,P=Math.floor(Math.log10(y)),E=y/10**P,Y;return Y=D?E<1.5?1:E<3?2:E<7?5:10:E<=1?1:E<=2?2:E<=5?5:10,Y*10**P}let J=R(()=>{let _=O.value,D=_.length?Math.max(0,..._):1,y=_.length?Math.min(0,..._):0;if(y===D)return{min:0,max:D||1,ticks:[0,D||1]};let P=U(U(D-y,!1)/3,!0),E=Math.floor(y/P)*P,Y=Math.ceil(D/P)*P,ie=[];for(let fe=E;fe<=Y+P*.5;fe+=P)ie.push(Number(fe.toFixed(6)));return{min:E,max:Y,ticks:ie}}),W=R(()=>zR({series:f.value})),ce=R(()=>{let _=m.value;if(!_)return{mode:"horizontal",entries:[]};let D=_.xKey;return UR({labels:_.data.map(y=>String(y?.[D]??"")),plotWidth:Math.max(200,o.value-42)})}),se=R(()=>{let _=W.value?.valueFormat,D=!!(W.value&&(_==="currency"||_==="percent"||W.value.valuePrefix||W.value.valueSuffix)),y=_==="duration"?46:D?38:30,P=ce.value.mode==="angled";return{width:o.value,height:168+(P?36:0),left:y,right:12,top:10,bottom:24+(P?36:0)}});function pe(_,D){let y=m.value,P=se.value;if(y?.chartType==="bar"){let E=P.width-P.left-P.right;return P.left+(_+.5)*(E/Math.max(D,1))}return F(_,D)}function F(_,D){let y=se.value,P=y.width-y.left-y.right;return D<=1?y.left+P/2:y.left+P*_/(D-1)}function ue(_){let{min:D,max:y}=J.value,P=se.value,E=P.height-P.top-P.bottom;return P.top+(y-_)/(y-D||1)*E}function Je(_){let D=m.value;return D?D.data.map((y,P)=>{let E=k(y[_])??0;return`${P===0?"M":"L"} ${F(P,D.data.length).toFixed(1)} ${ue(E).toFixed(1)}`}).join(" "):""}let ct=R(()=>{let _=m.value;if(!_?.trendLine||_.chartType!=="line"&&_.chartType!=="scatter")return null;let D=z(_,_.trendLine.dataKey),y=j(D);if(!y||!D.length)return null;let P=D[0].index,E=D[D.length-1].index,Y=y.intercept+y.slope*P,ie=y.intercept+y.slope*E,fe=Math.max(0,_.series.findIndex(ve=>ve.dataKey===_.trendLine?.dataKey));return{path:`M ${F(P,_.data.length).toFixed(1)} ${ue(Y).toFixed(1)} L ${F(E,_.data.length).toFixed(1)} ${ue(ie).toFixed(1)}`,dataKey:_.trendLine.dataKey,seriesIndex:fe}}),ft=R(()=>{let _=m.value;if(!_||_.chartType!=="bar")return[];let D=se.value,y=(D.width-D.left-D.right)/Math.max(_.data.length,1),P=ue(0);if(v.value){let ve=Math.max(4,Math.min(24,y*.42));return _.data.flatMap((we,ye)=>{let Ne=0,Me=0,Xe=D.left+ye*y+(y-ve)/2;return _.series.map((wt,$t)=>{let St=k(we[wt.dataKey])??0,Kt=St>=0?Ne:Me,vt=Kt+St,Nt=ue(Kt),Gr=ue(vt);return St>=0?Ne=vt:Me=vt,{key:`${ye}-${wt.dataKey}`,x:Xe,y:Math.min(Nt,Gr),width:ve,height:Math.max(1.5,Math.abs(Nt-Gr)),seriesIndex:$t,rowIndex:ye,dataKey:wt.dataKey}})})}let E=Math.max(_.series.length,1),Y=E>1?2:0,ie=Math.max(3,Math.min(20,(y*.62-Y*(E-1))/E)),fe=ie*E+Y*(E-1);return _.data.flatMap((ve,we)=>_.series.map((ye,Ne)=>{let Me=ue(k(ve[ye.dataKey])??0),Xe=D.left+we*y+(y-fe)/2+Ne*(ie+Y);return{key:`${we}-${ye.dataKey}`,x:Xe,y:Math.min(Me,P),width:ie,height:Math.max(1.5,Math.abs(P-Me)),seriesIndex:Ne,rowIndex:we,dataKey:ye.dataKey}}))}),Re=R(()=>{let _=m.value;if(!_)return[];let D=_.data;if(!D.length)return[];let y=D.length-1,P=ce.value,E=P.mode==="angled";return P.entries.map(({index:Y,text:ie})=>({key:`${Y}`,label:ie,x:pe(Y,D.length),anchor:E?"end":Y===0?"start":Y===y?"end":"middle",angled:E})).filter(Y=>Y.label)}),Be=R(()=>{let _=m.value;if(!_||_.chartType!=="bar"||_.series.length!==1||v.value)return[];let D=_.series[0],y=_.data.map((E,Y)=>{let ie=T(E,_.xKey),fe=k(E[D.dataKey]);return!ie||fe===null?null:{key:`${Y}-${ie}`,label:ie,rawValue:fe}}).filter(E=>E!==null);if(!y.length||y.some(E=>E.rawValue<0)||!(_.layout==="horizontal"||S(_.data,_.xKey)))return[];let P=Math.max(...y.map(E=>E.rawValue),1);return y.map(E=>({key:E.key,label:E.label,value:by({value:E.rawValue,series:D}),width:E.rawValue<=0?0:Math.max(2,E.rawValue/P*100),seriesIndex:0}))}),Mt=R(()=>{let _=m.value;if(!_?.data.length)return[];let D=_.data[_.data.length-1];return _.series.map((y,P)=>{let E=k(D?.[y.dataKey]);return{key:y.dataKey,label:y.label||y.dataKey,value:E===null?"\u2014":by({value:E,series:y}),seriesIndex:P}})}),Er=R(()=>{let _=m.value;if(!_?.data.length||_.chartType!=="line")return[];let D=_.data.length-1,y=_.data[D];return _.series.map((P,E)=>{let Y=k(y?.[P.dataKey]);return Y===null?null:{key:P.dataKey,cx:F(D,_.data.length),cy:ue(Y),seriesIndex:E}}).filter(P=>P!==null)}),mr=R(()=>{let _=h.value;if(!_)return[];let D=_.data.map(E=>({name:String(E[_.nameKey]??""),value:k(E[_.valueKey])??0})).filter(E=>E.name&&E.value>=0).sort((E,Y)=>Y.value-E.value),y=D.reduce((E,Y)=>E+Y.value,0)||1,P=_.series?.[0];return D.map((E,Y)=>({...E,key:`${Y}-${E.name}`,percent:E.value/y,display:by({value:E.value,series:P})}))}),gt=R(()=>l.value?CR(l.value,{maxWidth:i.value}):null),yt=["var(--color-theme-900)","var(--color-primary-500)","color-mix(in oklch, var(--color-primary-500) 55%, var(--color-theme-500))"],Wr=["rgba(255, 255, 255, 0.92)","color-mix(in oklch, white 30%, var(--color-primary-500))","rgba(255, 255, 255, 0.55)"];function Tt(_){let D=t.inverted?Wr:yt;return D[_%D.length]}function Ye(_){return t.inverted?_==="decision"?"rgba(255, 255, 255, 0.1)":"rgba(255, 255, 255, 0.06)":_==="decision"?"color-mix(in oklch, var(--color-primary-500) 6%, var(--color-theme-0))":_==="output"?"color-mix(in oklch, var(--color-theme-900) 5%, var(--color-theme-0))":"var(--color-theme-0)"}function Ht(_){return t.inverted?"rgba(255, 255, 255, 0.22)":x.value}let er=R(()=>t.inverted?"rgba(255, 255, 255, 0.95)":"var(--color-theme-900)"),Tr=R(()=>t.inverted?"rgba(255, 255, 255, 0.6)":"var(--color-theme-500)"),fr=R(()=>t.inverted?"rgba(255, 255, 255, 0.45)":"color-mix(in oklch, var(--color-theme-900) 42%, transparent)"),qr=R(()=>t.inverted?"rgba(255, 255, 255, 0.1)":"color-mix(in oklch, var(--color-theme-900) 8%, transparent)"),hr=R(()=>t.inverted?"rgba(255, 255, 255, 0.24)":"color-mix(in oklch, var(--color-theme-900) 18%, transparent)"),x=R(()=>t.inverted?"rgba(255, 255, 255, 0.16)":"color-mix(in oklch, var(--color-theme-300) 55%, transparent)"),I=R(()=>t.inverted?"rgba(255, 255, 255, 0.14)":"color-mix(in oklch, var(--color-theme-900) 10%, transparent)"),M=R(()=>t.inverted?"transparent":"var(--color-theme-0)"),B=R(()=>t.inverted?"rgba(255, 255, 255, 0.18)":"color-mix(in oklch, var(--color-theme-900) 16%, transparent)"),X=R(()=>t.inverted?"rgba(255, 255, 255, 0.12)":"color-mix(in oklch, var(--color-theme-900) 9%, transparent)");return(_,D)=>a.value?(w(),$("section",{key:0,"data-test":"chat-visual","data-visual-type":a.value.visualType,"data-chart-type":s.value?.chartType,"data-stacking":v.value?"stacked":void 0,"data-diagram-type":l.value?.diagramType,class:"my-6 w-full rounded-[20px] px-4 pb-3.5 pt-4",style:Se({background:M.value,boxShadow:`inset 0 0 0 1px ${I.value}`}),"aria-label":a.value.meta.title},[b("header",MR,[b("h4",{class:"text-[13px] font-semibold leading-tight",style:Se({color:er.value})},de(a.value.meta.title),5),a.value.meta.description?(w(),$("p",{key:0,class:"mt-0.5 text-[12px] leading-snug",style:Se({color:Tr.value})},de(a.value.meta.description),5)):te("",!0)]),b("div",{ref_key:"bodyEl",ref:n},[m.value?(w(),$("div",{key:0,role:"img","aria-label":a.value.meta.title},[Be.value.length?(w(),$("div",VR,[(w(!0),$(ge,null,st(Be.value,y=>(w(),$("div",{key:y.key,"data-test":"chat-visual-horizontal-bar",class:"min-w-0"},[b("div",FR,[b("span",{class:"line-clamp-2 min-w-0 font-medium leading-snug",style:Se({color:er.value})},de(y.label),5),b("span",{class:"shrink-0 font-semibold tabular-nums",style:Se({color:er.value})},de(y.value),5)]),b("div",{class:"h-2 w-full overflow-hidden rounded-full",style:Se({background:X.value})},[b("div",{class:"h-full rounded-full",style:Se({width:`${y.width}%`,background:Tt(y.seriesIndex)})},null,4)],4)]))),128))])):(w(),$("svg",{key:1,class:"block h-auto w-full overflow-visible",viewBox:`0 0 ${se.value.width} ${se.value.height}`,style:Se({aspectRatio:`${se.value.width} / ${se.value.height}`}),preserveAspectRatio:"xMidYMid meet","aria-hidden":"true"},[(w(!0),$(ge,null,st(J.value.ticks,y=>(w(),$("line",{key:`grid-${y}`,x1:se.value.left,x2:se.value.width-se.value.right,y1:ue(y),y2:ue(y),"stroke-width":"1","vector-effect":"non-scaling-stroke",style:Se({stroke:y===0?hr.value:qr.value})},null,12,ZR))),128)),b("g",null,[(w(!0),$(ge,null,st(J.value.ticks,y=>(w(),$("text",{key:`y-${y}`,x:se.value.left-7,y:ue(y)+3,"text-anchor":"end","font-size":"9.5",style:Se({fill:fr.value})},de(Ae(AR)({value:y,shared:W.value})),13,HR))),128))]),m.value.chartType==="bar"?(w(!0),$(ge,{key:0},st(ft.value,y=>(w(),$("rect",{key:y.key,"data-test":"chat-visual-bar","data-row-index":y.rowIndex,"data-series-index":y.seriesIndex,"data-data-key":y.dataKey,x:y.x,y:y.y,width:y.width,height:y.height,rx:"2.5",style:Se({fill:Tt(y.seriesIndex)})},null,12,KR))),128)):(w(),$(ge,{key:1},[ct.value?(w(),$("path",{key:0,"data-test":"chat-visual-trend-line","data-trend-key":ct.value.dataKey,d:ct.value.path,fill:"none","stroke-width":"1.4","stroke-linecap":"round","stroke-linejoin":"round","stroke-dasharray":"4 3","vector-effect":"non-scaling-stroke",style:Se({stroke:Tt(ct.value.seriesIndex)})},null,12,WR)):te("",!0),(w(!0),$(ge,null,st(f.value,(y,P)=>(w(),$("g",{key:y.dataKey},[m.value.chartType==="line"?(w(),$("path",{key:0,d:Je(y.dataKey),fill:"none","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round","vector-effect":"non-scaling-stroke",style:Se({stroke:Tt(P)})},null,12,qR)):te("",!0),(w(!0),$(ge,null,st(p.value,(E,Y)=>(w(),$(ge,{key:`${y.dataKey}-${Y}`},[m.value.chartType==="scatter"?(w(),$("circle",{key:0,cx:F(Y,p.value.length),cy:ue(k(E[y.dataKey])??0),r:"2.6",style:Se({fill:Tt(P)})},null,12,GR)):te("",!0)],64))),128))]))),128)),(w(!0),$(ge,null,st(Er.value,y=>(w(),$("circle",{key:`marker-${y.key}`,cx:y.cx,cy:y.cy,r:"3",style:Se({fill:Tt(y.seriesIndex)})},null,12,JR))),128))],64)),(w(!0),$(ge,null,st(Re.value,y=>(w(),$("text",{key:y.key,x:y.x,y:y.angled?se.value.height-se.value.bottom+12:se.value.height-6,"text-anchor":y.anchor,"font-size":"9.5",transform:y.angled?`rotate(${Ae(-40)} ${y.x} ${se.value.height-se.value.bottom+12})`:void 0,style:Se({fill:fr.value})},de(y.label),13,YR))),128))],12,BR)),Mt.value.length>1||m.value.chartType!=="bar"?(w(),$("div",XR,[(w(!0),$(ge,null,st(Mt.value,y=>(w(),$("div",{key:y.key,class:"inline-flex items-center gap-1.5 text-[11.5px] leading-none"},[b("span",{class:"size-2.5 shrink-0 rounded-full",style:Se({background:Tt(y.seriesIndex)})},null,4),b("span",{style:Se({color:Tr.value})},de(y.label),5),b("span",{class:"font-semibold tabular-nums",style:Se({color:er.value})},de(y.value),5)]))),128))])):te("",!0)],8,LR)):h.value?(w(),$("div",QR,[(w(!0),$(ge,null,st(mr.value,(y,P)=>(w(),$("div",{key:y.key},[b("div",eU,[b("span",{class:"truncate font-medium",style:Se({color:er.value})},de(y.name),5),b("span",tU,[b("span",{class:"font-semibold",style:Se({color:er.value})},de(y.display),5),b("span",{class:"ml-1.5",style:Se({color:Tr.value})},de(Math.round(y.percent*100))+"%",5)])]),b("div",{class:"h-1.5 w-full overflow-hidden rounded-full",style:Se({background:X.value})},[b("div",{class:"h-full rounded-full",style:Se({width:`${Math.max(2,y.percent*100)}%`,background:Tt(P)})},null,4)],4)]))),128))])):l.value&>.value?(w(),$("div",rU,[(w(),$("svg",{"data-test":"chat-visual-diagram-svg",class:"block h-auto overflow-visible",viewBox:`0 0 ${gt.value.width} ${gt.value.height}`,style:Se({width:`${gt.value.width}px`,aspectRatio:`${gt.value.width} / ${gt.value.height}`}),role:"img","aria-label":a.value.meta.title},[(w(!0),$(ge,null,st(gt.value.edges,y=>(w(),$("line",{key:y.key,"data-test":"chat-visual-diagram-edge","data-from":y.from,"data-to":y.to,x1:y.x1,y1:y.y1,x2:y.x2,y2:y.y2,"stroke-width":"1.4","stroke-linecap":"round","vector-effect":"non-scaling-stroke",style:Se({stroke:B.value})},null,12,iU))),128)),(w(!0),$(ge,null,st(gt.value.edges,y=>(w(),$("circle",{key:`${y.key}-dot`,cx:y.x2,cy:y.y2,r:"2.4",style:Se({fill:B.value})},null,12,oU))),128)),(w(!0),$(ge,null,st(gt.value.edges.filter(y=>y.label),y=>(w(),$("foreignObject",{key:`${y.key}-label`,x:y.labelX-55,y:y.labelY-12,width:"110",height:"24"},[b("div",{xmlns:"http://www.w3.org/1999/xhtml",class:"flex h-full items-center justify-center px-1 text-center text-[10.5px] font-medium leading-none",style:Se({color:Tr.value,background:t.inverted?"var(--color-theme-900)":"var(--color-theme-0)"})},de(y.label),5)],8,aU))),128)),(w(!0),$(ge,null,st(gt.value.nodes,y=>(w(),$("g",{key:y.id,"data-test":"chat-visual-diagram-node","data-node-id":y.id,"data-node-kind":y.kind,transform:`translate(${y.x} ${y.y})`},[y.kind==="decision"?(w(),$("polygon",{key:0,points:`${y.width/2},0 ${y.width},${y.height/2} ${y.width/2},${y.height} 0,${y.height/2}`,"stroke-width":"1","vector-effect":"non-scaling-stroke",style:Se({fill:Ye(y.kind),stroke:Ht(y.kind)})},null,12,lU)):(w(),$("rect",{key:1,width:y.width,height:y.height,rx:"9","stroke-width":"1","vector-effect":"non-scaling-stroke",style:Se({fill:Ye(y.kind),stroke:Ht(y.kind)})},null,12,cU)),(w(),$("foreignObject",{x:"8",y:"5",width:y.width-16,height:y.height-10},[b("div",dU,[b("div",{class:"line-clamp-2 text-[13px] font-medium leading-snug",style:Se({color:er.value})},de(y.label),5),y.detail?(w(),$("div",{key:0,class:"mt-0.5 line-clamp-1 text-[10.5px] leading-none",style:Se({color:Tr.value})},de(y.detail),5)):te("",!0)])],8,uU))],8,sU))),128))],12,nU))])):te("",!0)],512),a.value.meta.footer?(w(),$("footer",{key:0,class:"mt-3 text-[11px] leading-snug",style:Se({color:fr.value})},de(a.value.meta.footer),5)):te("",!0)],12,jR)):te("",!0)}}),mU="text-[14px] leading-[1.55] tracking-[-0.006em] text-pretty @sm/chat:text-[15px] @lg/chat:text-[15.5px]",fU=["innerHTML"],Wa=Pe({__name:"ChatRichText",props:{text:{},inverted:{type:Boolean},streaming:{type:Boolean}},emits:["action"],setup(e,{emit:t}){let n=e,i=t,r=We(n.text),o;mt([()=>n.text,()=>n.streaming],([v,k])=>{k?o===void 0&&(o=requestAnimationFrame(()=>{o=void 0,r.value=n.text})):(o!==void 0&&(cancelAnimationFrame(o),o=void 0),r.value=v)}),Da(()=>{o!==void 0&&cancelAnimationFrame(o)});let a=new et.Renderer;a.link=({href:v,text:k})=>{let T=v.trim();if(!T||T==="#")return k;let S=!1;if(typeof window<"u")try{S=new URL(v,window.location.href).origin===window.location.origin}catch{S=!1}return S?`<a href="${v}">${k}</a>`:`<a href="${v}" target="_blank" rel="noopener noreferrer">${k}</a>`},et.setOptions({breaks:!0,gfm:!0,renderer:a});function s(v){if(!v)return"";let k=et.parse(v,{async:!1});return yE.sanitize(k,{ADD_ATTR:["target"],ADD_DATA_URI_TAGS:["img"]})}function l(v){if(typeof v!="string")return null;let k=v.trim();return k?k.slice(0,80):null}function u(v){try{let k=JSON.parse(v);if(!k||typeof k!="object"||Array.isArray(k))return{topLevelKeys:[],declaredVisualType:null,declaredChartType:null,declaredDiagramType:null,inputType:null};let T=k;return{topLevelKeys:Object.keys(T).sort().slice(0,24),declaredVisualType:l(T.visualType),declaredChartType:l(T.chartType),declaredDiagramType:l(T.diagramType),inputType:l(T.type)}}catch{return{topLevelKeys:[],declaredVisualType:null,declaredChartType:null,declaredDiagramType:null,inputType:null}}}function d(v){if(typeof window>"u")return null;try{return new URL(v.currentSrc||v.src,window.location.href).host||null}catch{return null}}function p(v){typeof HTMLImageElement<"u"&&v.target instanceof HTMLImageElement&&typeof console<"u"&&console.warn("[chat-image] load_failed",{host:d(v.target),altPresent:!!v.target.alt?.trim(),width:v.target.naturalWidth||null,height:v.target.naturalHeight||null})}let m=/```(?:pl-visual|pl-platform-visual|pl-card)[ \t]*(?:\r?\n|$)/;function f(v){let{text:k,streaming:T}=v,S=[],z=/```(pl-visual|pl-platform-visual|pl-card)[ \t]*\r?\n([\s\S]*?)```/g,j=0,O=0,U=z.exec(k);for(;U!==null;){let se=s(k.slice(j,U.index));se&&S.push({kind:"markdown",key:`md-${O}`,html:se});let pe=U[1],F=U[2].trim();if(pe==="pl-card"){let ue=wI(F);ue.ok?S.push({kind:"card",key:`card-${O}`,spec:ue.spec}):(typeof console<"u"&&console.warn("[pl-card] parse_failed",{reason:ue.reason,message:ue.message,payloadChars:F.length}),S.push({kind:"markdown",key:`card-${O}`,html:s(`\`\`\`
|
|
165
|
+
`}strong({tokens:e}){return`<strong>${this.parser.parseInline(e)}</strong>`}em({tokens:e}){return`<em>${this.parser.parseInline(e)}</em>`}codespan({text:e}){return`<code>${Pr(e,!0)}</code>`}br(e){return"<br>"}del({tokens:e}){return`<del>${this.parser.parseInline(e)}</del>`}link({href:e,title:t,text:n,tokens:i,autolink:r}){let o=r?Pr(n,!0):this.parser.parseInline(i),a=tE(e);if(a===null)return o;e=Pr(a,r);let s='<a href="'+e+'"';return t&&(s+=' title="'+Pr(t)+'"'),s+=">"+o+"</a>",s}image({href:e,title:t,text:n,tokens:i}){i&&(n=this.parser.parseInline(i,this.parser.textRenderer));let r=tE(e);if(r===null)return Pr(n);e=r;let o=`<img src="${Pr(e)}" alt="${Pr(n)}"`;return t&&(o+=` title="${Pr(t)}"`),o+=">",o}text(e){return"tokens"in e&&e.tokens?this.parser.parseInline(e.tokens):"escaped"in e&&e.escaped?e.text:Pr(e.text)}},Uy=class{constructor(){G(this,"parser",void 0)}strong({text:e,tokens:t}){return t?this.parser.parseInline(t,this):e}em({text:e,tokens:t}){return t?this.parser.parseInline(t,this):e}codespan({text:e}){return e}del({text:e,tokens:t}){return t?this.parser.parseInline(t,this):e}html({text:e}){return e}text({text:e}){return e}link({text:e,tokens:t}){return t?this.parser.parseInline(t,this):e}image({text:e,tokens:t}){return t?this.parser.parseInline(t,this):e}br(){return""}checkbox({raw:e}){return e}},un=class Ty{constructor(t){G(this,"options",void 0),G(this,"renderer",void 0),G(this,"textRenderer",void 0),this.options=t||bo,this.options.renderer=this.options.renderer||new Pp,this.renderer=this.options.renderer,this.renderer.options=this.options,this.renderer.parser=this,this.textRenderer=new Uy,this.textRenderer.parser=this}static parse(t,n){return new Ty(n).parse(t)}static parseInline(t,n){return new Ty(n).parseInline(t)}parse(t){this.renderer.parser=this;let n="";for(let i=0;i<t.length;i++){let r=t[i];if(this.options.extensions?.renderers?.[r.type]){let a=r,s=this.options.extensions.renderers[a.type].call({parser:this},a);if(s!==!1||!["space","hr","heading","code","table","blockquote","list","checkbox","html","def","paragraph","text"].includes(a.type)){n+=s||"";continue}}let o=r;switch(o.type){case"space":n+=this.renderer.space(o);break;case"hr":n+=this.renderer.hr(o);break;case"heading":n+=this.renderer.heading(o);break;case"code":n+=this.renderer.code(o);break;case"table":n+=this.renderer.table(o);break;case"blockquote":n+=this.renderer.blockquote(o);break;case"list":n+=this.renderer.list(o);break;case"checkbox":n+=this.renderer.checkbox(o);break;case"html":n+=this.renderer.html(o);break;case"def":n+=this.renderer.def(o);break;case"paragraph":n+=this.renderer.paragraph(o);break;case"text":n+=this.renderer.text(o);break;default:{let a='Token with "'+o.type+'" type was not found.';if(this.options.silent)return console.error(a),"";throw Error(a)}}}return n}parseInline(t,n=this.renderer){this.renderer.parser=this;let i="";for(let r=0;r<t.length;r++){let o=t[r];if(this.options.extensions?.renderers?.[o.type]){let s=this.options.extensions.renderers[o.type].call({parser:this},o);if(s!==!1||!["escape","html","link","image","checkbox","strong","em","codespan","br","del","text"].includes(o.type)){i+=s||"";continue}}let a=o;switch(a.type){case"escape":i+=n.text(a);break;case"html":i+=n.html(a);break;case"link":i+=n.link(a);break;case"image":i+=n.image(a);break;case"checkbox":i+=n.checkbox(a);break;case"strong":i+=n.strong(a);break;case"em":i+=n.em(a);break;case"codespan":i+=n.codespan(a);break;case"br":i+=n.br(a);break;case"del":i+=n.del(a);break;case"text":i+=n.text(a);break;default:{let s='Token with "'+a.type+'" type was not found.';if(this.options.silent)return console.error(s),"";throw Error(s)}}}return i}},ic=(Ip=class{constructor(e){G(this,"options",void 0),G(this,"block",void 0),this.options=e||bo}preprocess(e){return e}postprocess(e){return e}processAllTokens(e){return e}emStrongMask(e){return e}provideLexer(e=this.block){return e?cn.lex:cn.lexInline}provideParser(e=this.block){return e?un.parse:un.parseInline}},G(Ip,"passThroughHooks",new Set(["preprocess","postprocess","processAllTokens","emStrongMask"])),G(Ip,"passThroughHooksRespectAsync",new Set(["preprocess","postprocess","processAllTokens"])),Ip);kR=class{constructor(...e){G(this,"defaults",Ny()),G(this,"options",this.setOptions),G(this,"parse",this.parseMarkdown(!0)),G(this,"parseInline",this.parseMarkdown(!1)),G(this,"Parser",un),G(this,"Renderer",Pp),G(this,"TextRenderer",Uy),G(this,"Lexer",cn),G(this,"Tokenizer",Ya),G(this,"Hooks",ic),this.use(...e)}walkTokens(e,t){let n=[];for(let i of e)switch(Ci(n,t.call(this,i)),i.type){case"table":{let r=i;for(let o of r.header)Ci(n,this.walkTokens(o.tokens,t));for(let o of r.rows)for(let a of o)Ci(n,this.walkTokens(a.tokens,t));break}case"list":{let r=i;Ci(n,this.walkTokens(r.items,t));break}default:{let r=i;this.defaults.extensions?.childTokens?.[r.type]?this.defaults.extensions.childTokens[r.type].forEach(o=>{let a=r[o].flat(1/0);Ci(n,this.walkTokens(a,t))}):r.tokens&&Ci(n,this.walkTokens(r.tokens,t))}}return n}use(...e){let t=this.defaults.extensions||{renderers:Object.create(null),childTokens:Object.create(null)};return e.forEach(n=>{let i={...n};if(i.async=this.defaults.async||i.async||!1,n.extensions&&(n.extensions.forEach(r=>{if(!r.name)throw Error("extension name required");if("renderer"in r){let o=t.renderers[r.name];o?t.renderers[r.name]=function(...a){let s=r.renderer.apply(this,a);return s===!1&&(s=o.apply(this,a)),s}:t.renderers[r.name]=r.renderer}if("tokenizer"in r){if(!r.level||r.level!=="block"&&r.level!=="inline")throw Error("extension level must be 'block' or 'inline'");let o=t[r.level];o?o.unshift(r.tokenizer):t[r.level]=[r.tokenizer],r.start&&(r.level==="block"?t.startBlock?t.startBlock.push(r.start):t.startBlock=[r.start]:r.level==="inline"&&(t.startInline?t.startInline.push(r.start):t.startInline=[r.start]))}"childTokens"in r&&r.childTokens&&(t.childTokens[r.name]=r.childTokens)}),i.extensions=t),n.renderer){let r=this.defaults.renderer||new Pp(this.defaults);for(let o in n.renderer){if(!(o in r))throw Error(`renderer '${o}' does not exist`);if(["options","parser"].includes(o))continue;let a=o,s=n.renderer[a],l=r[a];r[a]=(...u)=>{let d=s.apply(r,u);return d===!1&&(d=l.apply(r,u)),d===!1?"":d??""}}i.renderer=r}if(n.tokenizer){let r=this.defaults.tokenizer||new Ya(this.defaults);for(let o in n.tokenizer){if(!(o in r))throw Error(`tokenizer '${o}' does not exist`);if(["options","rules","lexer"].includes(o))continue;let a=o,s=n.tokenizer[a],l=r[a];r[a]=(...u)=>{let d=s.apply(r,u);return d===!1&&(d=l.apply(r,u)),d}}i.tokenizer=r}if(n.hooks){let r=this.defaults.hooks||new ic;for(let o in n.hooks){if(!(o in r))throw Error(`hook '${o}' does not exist`);if(["options","block"].includes(o))continue;let a=o,s=n.hooks[a],l=r[a];r[a]=ic.passThroughHooks.has(o)?u=>{if(r.options.async&&ic.passThroughHooksRespectAsync.has(o))return(async()=>{let p=await s.call(r,u);return l.call(r,p)})();let d=s.call(r,u);return l.call(r,d)}:(...u)=>{if(r.options.async)return(async()=>{let p=await s.apply(r,u);return p===!1&&(p=await l.apply(r,u)),p})();let d=s.apply(r,u);return d===!1&&(d=l.apply(r,u)),d}}i.hooks=r}if(n.walkTokens){let r=this.defaults.walkTokens,o=n.walkTokens;i.walkTokens=function(a){let s=[];return Ci(s,o.call(this,a)),r&&Ci(s,r.call(this,a)),s}}this.defaults={...this.defaults,...i}}),this}setOptions(e){return this.defaults={...this.defaults,...e},this}lexer(e,t){return cn.lex(e,t??this.defaults)}parser(e,t){return un.parse(e,t??this.defaults)}parseMarkdown(e){return(t,n)=>{let i={...n},r={...this.defaults,...i},o=this.onError(!!r.silent,!!r.async);if(this.defaults.async===!0&&i.async===!1)return o(Error("marked(): The async option was set to true by an extension. Remove async: false from the parse options object to return a Promise."));if(typeof t>"u"||t===null)return o(Error("marked(): input parameter is undefined or null"));if(typeof t!="string")return o(Error("marked(): input parameter is of type "+Object.prototype.toString.call(t)+", string expected"));if(r.hooks&&(r.hooks.options=r,r.hooks.block=e),r.async)return(async()=>{let a=r.hooks?await r.hooks.preprocess(t):t,s=await(r.hooks?await r.hooks.provideLexer(e):e?cn.lex:cn.lexInline)(a,r),l=r.hooks?await r.hooks.processAllTokens(s):s;r.walkTokens&&await Promise.all(this.walkTokens(l,r.walkTokens));let u=await(r.hooks?await r.hooks.provideParser(e):e?un.parse:un.parseInline)(l,r);return r.hooks?await r.hooks.postprocess(u):u})().catch(o);try{r.hooks&&(t=r.hooks.preprocess(t));let a=(r.hooks?r.hooks.provideLexer(e):e?cn.lex:cn.lexInline)(t,r);r.hooks&&(a=r.hooks.processAllTokens(a)),r.walkTokens&&this.walkTokens(a,r.walkTokens);let s=(r.hooks?r.hooks.provideParser(e):e?un.parse:un.parseInline)(a,r);return r.hooks&&(s=r.hooks.postprocess(s)),s}catch(a){return o(a)}}}onError(e,t){return n=>{if(n.message+=`
|
|
166
|
+
Please report this to https://github.com/markedjs/marked.`,e){let i="<p>An error occurred:</p><pre>"+Pr(n.message+"",!0)+"</pre>";return t?Promise.resolve(i):i}if(t)return Promise.reject(n);throw n}}},vo=new kR;et.options=et.setOptions=function(e){return vo.setOptions(e),et.defaults=vo.defaults,wE(et.defaults),et},et.getDefaults=Ny,et.defaults=bo;et.use=xR,et.walkTokens=function(e,t){return vo.walkTokens(e,t)},et.parseInline=vo.parseInline,et.Parser=un,et.parser=un.parse,et.Renderer=Pp,et.TextRenderer=Uy,et.Lexer=cn,et.lexer=cn.lex,et.Tokenizer=Ya,et.Hooks=ic,et.parse=et,et.options,et.setOptions,et.walkTokens,et.parseInline,un.parse,cn.lex;_R=["aria-label"],$R={class:"px-4 pb-2 pt-4"},SR=["innerHTML"],IR=["onClick"],ER=Pe({__name:"ChatCardBlock",props:{spec:{},inverted:{type:Boolean}},emits:["action"],setup(e,{emit:t}){let n=e,i=t,r=R(()=>{if(!n.spec.body)return"";let m=et.parse(n.spec.body,{async:!1});return yE.sanitize(m,{ADD_ATTR:["target"]})}),o=R(()=>n.inverted?"rgba(255, 255, 255, 0.22)":"rgba(0, 0, 0, 0.16)"),a=R(()=>n.inverted?"rgba(255, 255, 255, 0.12)":"color-mix(in oklch, var(--color-theme-200) 80%, transparent)"),s=R(()=>n.inverted?"rgba(255, 255, 255, 0.95)":"var(--color-theme-900)"),l=R(()=>n.inverted?"rgba(255, 255, 255, 0.8)":"var(--color-theme-800)"),u=R(()=>n.inverted?`inset 0 0 0 1px ${o.value}`:`inset 0 0 0 1px ${o.value}, 0 4px 16px rgba(15, 23, 42, 0.05)`),d=R(()=>n.inverted?"transparent":"var(--color-theme-0)");function p(m){return m==="primary"||m==="destructive"?{background:n.inverted?"rgba(255, 255, 255, 0.92)":"var(--color-theme-900)",color:n.inverted?"var(--color-theme-900)":"#fff"}:{background:"var(--color-theme-100)",color:s.value}}return(m,f)=>(w(),$("div",{"data-test":"chat-card",class:"my-6 w-full self-start overflow-hidden rounded-2xl",style:Se({background:d.value,boxShadow:u.value}),"aria-label":e.spec.title},[b("div",$R,[b("div",{class:"text-[14px] font-semibold leading-tight",style:Se({color:s.value})},de(e.spec.title),5)]),r.value?(w(),$("div",{key:0,class:"chat-msg-prose px-4 pb-4 pt-2 text-[14px] leading-relaxed",style:Se({color:l.value}),innerHTML:r.value},null,12,SR)):te("",!0),e.spec.actions?.length?(w(),$("div",{key:1,class:"flex flex-wrap items-center gap-2 px-3 py-2.5",style:Se({borderTop:`1px solid ${a.value}`})},[(w(!0),$(ge,null,st(e.spec.actions,h=>(w(),$("button",{key:h.label,type:"button","data-test":"chat-card-action",class:"inline-flex h-10 items-center justify-center rounded-full px-5 text-[14px] font-semibold transition-colors duration-150 active:opacity-80",style:Se(p(h.style)),onClick:v=>i("action",h.reply)},de(h.label),13,IR))),128))],4)):te("",!0)],12,_R))}}),sE=112,vy=52,Np=14,Ka=54,lE=34,TR=260;PR=5.4,RR=10,UR=15,jR=16;LR=["data-visual-type","data-chart-type","data-stacking","data-diagram-type","aria-label"],VR={class:"mb-2.5"},FR=["aria-label"],BR={key:0,"data-test":"chat-visual-horizontal-bars",class:"grid gap-3"},ZR={class:"mb-1 flex items-start justify-between gap-3 text-[12px]"},HR=["viewBox"],KR=["x1","x2","y1","y2"],WR=["x","y"],qR=["data-row-index","data-series-index","data-data-key","x","y","width","height"],GR=["data-trend-key","d"],JR=["d"],YR=["cx","cy"],XR=["cx","cy"],QR=["x","y","text-anchor","transform"],eU={key:2,class:"mt-2.5 flex flex-wrap items-center gap-x-4 gap-y-1.5"},tU={key:1,class:"grid gap-3"},rU={class:"mb-1 flex items-baseline justify-between gap-3 text-[12px]"},nU={class:"shrink-0 tabular-nums"},iU={key:2,class:"overflow-x-auto"},oU=["viewBox","aria-label"],aU=["data-from","data-to","x1","y1","x2","y2"],sU=["cx","cy"],lU=["x","y"],cU=["data-node-id","data-node-kind","transform"],uU=["points"],dU=["width","height"],pU=["width","height"],mU={xmlns:"http://www.w3.org/1999/xhtml",class:"flex h-full min-w-0 flex-col items-center justify-center text-center"},fU=Pe({__name:"ChatVisualBlock",props:{result:{},inverted:{type:Boolean}},setup(e){let t=e,n=Q(),i=We(360),r;Ut(()=>{typeof ResizeObserver<"u"&&n.value&&(r=new ResizeObserver(_=>{let D=_[0]?.contentRect.width;D&&(i.value=Math.round(D))}),r.observe(n.value))}),Da(()=>r?.disconnect());let o=R(()=>Math.min(720,Math.max(280,i.value))),a=R(()=>t.result.ok?t.result.spec:null),s=R(()=>a.value?.visualType==="chart"?a.value:null),l=R(()=>a.value?.visualType==="diagram"?a.value:null);function u(_){return _?.chartType==="bar"||_?.chartType==="line"||_?.chartType==="scatter"}function d(_){return _?.chartType==="pie"}let p=R(()=>s.value?.data??[]),m=R(()=>u(s.value)?s.value:null),f=R(()=>m.value?.series??[]),h=R(()=>d(s.value)?s.value:null),v=R(()=>m.value?.chartType==="bar"&&m.value.stacking==="stacked");function k(_){return typeof _=="number"&&Number.isFinite(_)?_:null}function T(_,D){return String(_[D]??"").trim()}function S(_,D){let y=_.map(Y=>T(Y,D)).filter(Boolean);if(!y.length)return!1;let P=Math.max(...y.map(Y=>Y.length)),E=y.reduce((Y,ie)=>Y+ie.length,0)/y.length;return P>=16||y.length>5&&E>=10}function z(_,D){return _.data.map((y,P)=>{let E=k(y[D]);return E===null?null:{index:P,value:E}}).filter(y=>y!==null)}function j(_){if(_.length<2)return null;let D=_.length,y=_.reduce((ve,we)=>ve+we.index,0),P=_.reduce((ve,we)=>ve+we.value,0),E=_.reduce((ve,we)=>ve+we.index*we.index,0),Y=_.reduce((ve,we)=>ve+we.index*we.value,0),ie=D*E-y*y;if(ie===0)return null;let fe=(D*Y-y*P)/ie;return{slope:fe,intercept:(P-fe*y)/D}}let O=R(()=>{let _=[],D=m.value;if(!D)return _;if(D.chartType==="bar"&&D.stacking==="stacked")for(let y of D.data){let P=0,E=0;for(let Y of D.series){let ie=k(y[Y.dataKey]);ie!==null&&(ie>=0?P+=ie:E+=ie)}_.push(P,E)}else for(let y of D.data)for(let P of D.series){let E=k(y[P.dataKey]);E!==null&&_.push(E)}if(D.trendLine&&(D.chartType==="line"||D.chartType==="scatter")){let y=z(D,D.trendLine.dataKey);_.push(...y.map(E=>E.value));let P=j(y);if(P&&y.length){let E=y[0].index,Y=y[y.length-1].index;_.push(P.intercept+P.slope*E,P.intercept+P.slope*Y)}}return _});function U(_,D){let y=_>0?_:1,P=Math.floor(Math.log10(y)),E=y/10**P,Y;return Y=D?E<1.5?1:E<3?2:E<7?5:10:E<=1?1:E<=2?2:E<=5?5:10,Y*10**P}let J=R(()=>{let _=O.value,D=_.length?Math.max(0,..._):1,y=_.length?Math.min(0,..._):0;if(y===D)return{min:0,max:D||1,ticks:[0,D||1]};let P=U(U(D-y,!1)/3,!0),E=Math.floor(y/P)*P,Y=Math.ceil(D/P)*P,ie=[];for(let fe=E;fe<=Y+P*.5;fe+=P)ie.push(Number(fe.toFixed(6)));return{min:E,max:Y,ticks:ie}}),W=R(()=>OR({series:f.value})),ce=R(()=>{let _=m.value;if(!_)return{mode:"horizontal",entries:[]};let D=_.xKey;return MR({labels:_.data.map(y=>String(y?.[D]??"")),plotWidth:Math.max(200,o.value-42)})}),se=R(()=>{let _=W.value?.valueFormat,D=!!(W.value&&(_==="currency"||_==="percent"||W.value.valuePrefix||W.value.valueSuffix)),y=_==="duration"?46:D?38:30,P=ce.value.mode==="angled";return{width:o.value,height:168+(P?36:0),left:y,right:12,top:10,bottom:24+(P?36:0)}});function pe(_,D){let y=m.value,P=se.value;if(y?.chartType==="bar"){let E=P.width-P.left-P.right;return P.left+(_+.5)*(E/Math.max(D,1))}return F(_,D)}function F(_,D){let y=se.value,P=y.width-y.left-y.right;return D<=1?y.left+P/2:y.left+P*_/(D-1)}function ue(_){let{min:D,max:y}=J.value,P=se.value,E=P.height-P.top-P.bottom;return P.top+(y-_)/(y-D||1)*E}function Je(_){let D=m.value;return D?D.data.map((y,P)=>{let E=k(y[_])??0;return`${P===0?"M":"L"} ${F(P,D.data.length).toFixed(1)} ${ue(E).toFixed(1)}`}).join(" "):""}let ct=R(()=>{let _=m.value;if(!_?.trendLine||_.chartType!=="line"&&_.chartType!=="scatter")return null;let D=z(_,_.trendLine.dataKey),y=j(D);if(!y||!D.length)return null;let P=D[0].index,E=D[D.length-1].index,Y=y.intercept+y.slope*P,ie=y.intercept+y.slope*E,fe=Math.max(0,_.series.findIndex(ve=>ve.dataKey===_.trendLine?.dataKey));return{path:`M ${F(P,_.data.length).toFixed(1)} ${ue(Y).toFixed(1)} L ${F(E,_.data.length).toFixed(1)} ${ue(ie).toFixed(1)}`,dataKey:_.trendLine.dataKey,seriesIndex:fe}}),ft=R(()=>{let _=m.value;if(!_||_.chartType!=="bar")return[];let D=se.value,y=(D.width-D.left-D.right)/Math.max(_.data.length,1),P=ue(0);if(v.value){let ve=Math.max(4,Math.min(24,y*.42));return _.data.flatMap((we,ye)=>{let Ne=0,Me=0,Xe=D.left+ye*y+(y-ve)/2;return _.series.map((wt,$t)=>{let St=k(we[wt.dataKey])??0,Kt=St>=0?Ne:Me,vt=Kt+St,Nt=ue(Kt),Gr=ue(vt);return St>=0?Ne=vt:Me=vt,{key:`${ye}-${wt.dataKey}`,x:Xe,y:Math.min(Nt,Gr),width:ve,height:Math.max(1.5,Math.abs(Nt-Gr)),seriesIndex:$t,rowIndex:ye,dataKey:wt.dataKey}})})}let E=Math.max(_.series.length,1),Y=E>1?2:0,ie=Math.max(3,Math.min(20,(y*.62-Y*(E-1))/E)),fe=ie*E+Y*(E-1);return _.data.flatMap((ve,we)=>_.series.map((ye,Ne)=>{let Me=ue(k(ve[ye.dataKey])??0),Xe=D.left+we*y+(y-fe)/2+Ne*(ie+Y);return{key:`${we}-${ye.dataKey}`,x:Xe,y:Math.min(Me,P),width:ie,height:Math.max(1.5,Math.abs(P-Me)),seriesIndex:Ne,rowIndex:we,dataKey:ye.dataKey}}))}),Re=R(()=>{let _=m.value;if(!_)return[];let D=_.data;if(!D.length)return[];let y=D.length-1,P=ce.value,E=P.mode==="angled";return P.entries.map(({index:Y,text:ie})=>({key:`${Y}`,label:ie,x:pe(Y,D.length),anchor:E?"end":Y===0?"start":Y===y?"end":"middle",angled:E})).filter(Y=>Y.label)}),Be=R(()=>{let _=m.value;if(!_||_.chartType!=="bar"||_.series.length!==1||v.value)return[];let D=_.series[0],y=_.data.map((E,Y)=>{let ie=T(E,_.xKey),fe=k(E[D.dataKey]);return!ie||fe===null?null:{key:`${Y}-${ie}`,label:ie,rawValue:fe}}).filter(E=>E!==null);if(!y.length||y.some(E=>E.rawValue<0)||!(_.layout==="horizontal"||S(_.data,_.xKey)))return[];let P=Math.max(...y.map(E=>E.rawValue),1);return y.map(E=>({key:E.key,label:E.label,value:by({value:E.rawValue,series:D}),width:E.rawValue<=0?0:Math.max(2,E.rawValue/P*100),seriesIndex:0}))}),Mt=R(()=>{let _=m.value;if(!_?.data.length)return[];let D=_.data[_.data.length-1];return _.series.map((y,P)=>{let E=k(D?.[y.dataKey]);return{key:y.dataKey,label:y.label||y.dataKey,value:E===null?"\u2014":by({value:E,series:y}),seriesIndex:P}})}),Er=R(()=>{let _=m.value;if(!_?.data.length||_.chartType!=="line")return[];let D=_.data.length-1,y=_.data[D];return _.series.map((P,E)=>{let Y=k(y?.[P.dataKey]);return Y===null?null:{key:P.dataKey,cx:F(D,_.data.length),cy:ue(Y),seriesIndex:E}}).filter(P=>P!==null)}),mr=R(()=>{let _=h.value;if(!_)return[];let D=_.data.map(E=>({name:String(E[_.nameKey]??""),value:k(E[_.valueKey])??0})).filter(E=>E.name&&E.value>=0).sort((E,Y)=>Y.value-E.value),y=D.reduce((E,Y)=>E+Y.value,0)||1,P=_.series?.[0];return D.map((E,Y)=>({...E,key:`${Y}-${E.name}`,percent:E.value/y,display:by({value:E.value,series:P})}))}),gt=R(()=>l.value?AR(l.value,{maxWidth:i.value}):null),yt=["var(--color-theme-900)","var(--color-primary-500)","color-mix(in oklch, var(--color-primary-500) 55%, var(--color-theme-500))"],Wr=["rgba(255, 255, 255, 0.92)","color-mix(in oklch, white 30%, var(--color-primary-500))","rgba(255, 255, 255, 0.55)"];function Tt(_){let D=t.inverted?Wr:yt;return D[_%D.length]}function Ye(_){return t.inverted?_==="decision"?"rgba(255, 255, 255, 0.1)":"rgba(255, 255, 255, 0.06)":_==="decision"?"color-mix(in oklch, var(--color-primary-500) 6%, var(--color-theme-0))":_==="output"?"color-mix(in oklch, var(--color-theme-900) 5%, var(--color-theme-0))":"var(--color-theme-0)"}function Ht(_){return t.inverted?"rgba(255, 255, 255, 0.22)":x.value}let er=R(()=>t.inverted?"rgba(255, 255, 255, 0.95)":"var(--color-theme-900)"),Tr=R(()=>t.inverted?"rgba(255, 255, 255, 0.6)":"var(--color-theme-500)"),fr=R(()=>t.inverted?"rgba(255, 255, 255, 0.45)":"color-mix(in oklch, var(--color-theme-900) 42%, transparent)"),qr=R(()=>t.inverted?"rgba(255, 255, 255, 0.1)":"color-mix(in oklch, var(--color-theme-900) 8%, transparent)"),hr=R(()=>t.inverted?"rgba(255, 255, 255, 0.24)":"color-mix(in oklch, var(--color-theme-900) 18%, transparent)"),x=R(()=>t.inverted?"rgba(255, 255, 255, 0.16)":"color-mix(in oklch, var(--color-theme-300) 55%, transparent)"),I=R(()=>t.inverted?"rgba(255, 255, 255, 0.14)":"color-mix(in oklch, var(--color-theme-900) 10%, transparent)"),M=R(()=>t.inverted?"transparent":"var(--color-theme-0)"),B=R(()=>t.inverted?"rgba(255, 255, 255, 0.18)":"color-mix(in oklch, var(--color-theme-900) 16%, transparent)"),X=R(()=>t.inverted?"rgba(255, 255, 255, 0.12)":"color-mix(in oklch, var(--color-theme-900) 9%, transparent)");return(_,D)=>a.value?(w(),$("section",{key:0,"data-test":"chat-visual","data-visual-type":a.value.visualType,"data-chart-type":s.value?.chartType,"data-stacking":v.value?"stacked":void 0,"data-diagram-type":l.value?.diagramType,class:"my-6 w-full rounded-[20px] px-4 pb-3.5 pt-4",style:Se({background:M.value,boxShadow:`inset 0 0 0 1px ${I.value}`}),"aria-label":a.value.meta.title},[b("header",VR,[b("h4",{class:"text-[13px] font-semibold leading-tight",style:Se({color:er.value})},de(a.value.meta.title),5),a.value.meta.description?(w(),$("p",{key:0,class:"mt-0.5 text-[12px] leading-snug",style:Se({color:Tr.value})},de(a.value.meta.description),5)):te("",!0)]),b("div",{ref_key:"bodyEl",ref:n},[m.value?(w(),$("div",{key:0,role:"img","aria-label":a.value.meta.title},[Be.value.length?(w(),$("div",BR,[(w(!0),$(ge,null,st(Be.value,y=>(w(),$("div",{key:y.key,"data-test":"chat-visual-horizontal-bar",class:"min-w-0"},[b("div",ZR,[b("span",{class:"line-clamp-2 min-w-0 font-medium leading-snug",style:Se({color:er.value})},de(y.label),5),b("span",{class:"shrink-0 font-semibold tabular-nums",style:Se({color:er.value})},de(y.value),5)]),b("div",{class:"h-2 w-full overflow-hidden rounded-full",style:Se({background:X.value})},[b("div",{class:"h-full rounded-full",style:Se({width:`${y.width}%`,background:Tt(y.seriesIndex)})},null,4)],4)]))),128))])):(w(),$("svg",{key:1,class:"block h-auto w-full overflow-visible",viewBox:`0 0 ${se.value.width} ${se.value.height}`,style:Se({aspectRatio:`${se.value.width} / ${se.value.height}`}),preserveAspectRatio:"xMidYMid meet","aria-hidden":"true"},[(w(!0),$(ge,null,st(J.value.ticks,y=>(w(),$("line",{key:`grid-${y}`,x1:se.value.left,x2:se.value.width-se.value.right,y1:ue(y),y2:ue(y),"stroke-width":"1","vector-effect":"non-scaling-stroke",style:Se({stroke:y===0?hr.value:qr.value})},null,12,KR))),128)),b("g",null,[(w(!0),$(ge,null,st(J.value.ticks,y=>(w(),$("text",{key:`y-${y}`,x:se.value.left-7,y:ue(y)+3,"text-anchor":"end","font-size":"9.5",style:Se({fill:fr.value})},de(Ae(DR)({value:y,shared:W.value})),13,WR))),128))]),m.value.chartType==="bar"?(w(!0),$(ge,{key:0},st(ft.value,y=>(w(),$("rect",{key:y.key,"data-test":"chat-visual-bar","data-row-index":y.rowIndex,"data-series-index":y.seriesIndex,"data-data-key":y.dataKey,x:y.x,y:y.y,width:y.width,height:y.height,rx:"2.5",style:Se({fill:Tt(y.seriesIndex)})},null,12,qR))),128)):(w(),$(ge,{key:1},[ct.value?(w(),$("path",{key:0,"data-test":"chat-visual-trend-line","data-trend-key":ct.value.dataKey,d:ct.value.path,fill:"none","stroke-width":"1.4","stroke-linecap":"round","stroke-linejoin":"round","stroke-dasharray":"4 3","vector-effect":"non-scaling-stroke",style:Se({stroke:Tt(ct.value.seriesIndex)})},null,12,GR)):te("",!0),(w(!0),$(ge,null,st(f.value,(y,P)=>(w(),$("g",{key:y.dataKey},[m.value.chartType==="line"?(w(),$("path",{key:0,d:Je(y.dataKey),fill:"none","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round","vector-effect":"non-scaling-stroke",style:Se({stroke:Tt(P)})},null,12,JR)):te("",!0),(w(!0),$(ge,null,st(p.value,(E,Y)=>(w(),$(ge,{key:`${y.dataKey}-${Y}`},[m.value.chartType==="scatter"?(w(),$("circle",{key:0,cx:F(Y,p.value.length),cy:ue(k(E[y.dataKey])??0),r:"2.6",style:Se({fill:Tt(P)})},null,12,YR)):te("",!0)],64))),128))]))),128)),(w(!0),$(ge,null,st(Er.value,y=>(w(),$("circle",{key:`marker-${y.key}`,cx:y.cx,cy:y.cy,r:"3",style:Se({fill:Tt(y.seriesIndex)})},null,12,XR))),128))],64)),(w(!0),$(ge,null,st(Re.value,y=>(w(),$("text",{key:y.key,x:y.x,y:y.angled?se.value.height-se.value.bottom+12:se.value.height-6,"text-anchor":y.anchor,"font-size":"9.5",transform:y.angled?`rotate(${Ae(-40)} ${y.x} ${se.value.height-se.value.bottom+12})`:void 0,style:Se({fill:fr.value})},de(y.label),13,QR))),128))],12,HR)),Mt.value.length>1||m.value.chartType!=="bar"?(w(),$("div",eU,[(w(!0),$(ge,null,st(Mt.value,y=>(w(),$("div",{key:y.key,class:"inline-flex items-center gap-1.5 text-[11.5px] leading-none"},[b("span",{class:"size-2.5 shrink-0 rounded-full",style:Se({background:Tt(y.seriesIndex)})},null,4),b("span",{style:Se({color:Tr.value})},de(y.label),5),b("span",{class:"font-semibold tabular-nums",style:Se({color:er.value})},de(y.value),5)]))),128))])):te("",!0)],8,FR)):h.value?(w(),$("div",tU,[(w(!0),$(ge,null,st(mr.value,(y,P)=>(w(),$("div",{key:y.key},[b("div",rU,[b("span",{class:"truncate font-medium",style:Se({color:er.value})},de(y.name),5),b("span",nU,[b("span",{class:"font-semibold",style:Se({color:er.value})},de(y.display),5),b("span",{class:"ml-1.5",style:Se({color:Tr.value})},de(Math.round(y.percent*100))+"%",5)])]),b("div",{class:"h-1.5 w-full overflow-hidden rounded-full",style:Se({background:X.value})},[b("div",{class:"h-full rounded-full",style:Se({width:`${Math.max(2,y.percent*100)}%`,background:Tt(P)})},null,4)],4)]))),128))])):l.value&>.value?(w(),$("div",iU,[(w(),$("svg",{"data-test":"chat-visual-diagram-svg",class:"block h-auto overflow-visible",viewBox:`0 0 ${gt.value.width} ${gt.value.height}`,style:Se({width:`${gt.value.width}px`,aspectRatio:`${gt.value.width} / ${gt.value.height}`}),role:"img","aria-label":a.value.meta.title},[(w(!0),$(ge,null,st(gt.value.edges,y=>(w(),$("line",{key:y.key,"data-test":"chat-visual-diagram-edge","data-from":y.from,"data-to":y.to,x1:y.x1,y1:y.y1,x2:y.x2,y2:y.y2,"stroke-width":"1.4","stroke-linecap":"round","vector-effect":"non-scaling-stroke",style:Se({stroke:B.value})},null,12,aU))),128)),(w(!0),$(ge,null,st(gt.value.edges,y=>(w(),$("circle",{key:`${y.key}-dot`,cx:y.x2,cy:y.y2,r:"2.4",style:Se({fill:B.value})},null,12,sU))),128)),(w(!0),$(ge,null,st(gt.value.edges.filter(y=>y.label),y=>(w(),$("foreignObject",{key:`${y.key}-label`,x:y.labelX-55,y:y.labelY-12,width:"110",height:"24"},[b("div",{xmlns:"http://www.w3.org/1999/xhtml",class:"flex h-full items-center justify-center px-1 text-center text-[10.5px] font-medium leading-none",style:Se({color:Tr.value,background:t.inverted?"var(--color-theme-900)":"var(--color-theme-0)"})},de(y.label),5)],8,lU))),128)),(w(!0),$(ge,null,st(gt.value.nodes,y=>(w(),$("g",{key:y.id,"data-test":"chat-visual-diagram-node","data-node-id":y.id,"data-node-kind":y.kind,transform:`translate(${y.x} ${y.y})`},[y.kind==="decision"?(w(),$("polygon",{key:0,points:`${y.width/2},0 ${y.width},${y.height/2} ${y.width/2},${y.height} 0,${y.height/2}`,"stroke-width":"1","vector-effect":"non-scaling-stroke",style:Se({fill:Ye(y.kind),stroke:Ht(y.kind)})},null,12,uU)):(w(),$("rect",{key:1,width:y.width,height:y.height,rx:"9","stroke-width":"1","vector-effect":"non-scaling-stroke",style:Se({fill:Ye(y.kind),stroke:Ht(y.kind)})},null,12,dU)),(w(),$("foreignObject",{x:"8",y:"5",width:y.width-16,height:y.height-10},[b("div",mU,[b("div",{class:"line-clamp-2 text-[13px] font-medium leading-snug",style:Se({color:er.value})},de(y.label),5),y.detail?(w(),$("div",{key:0,class:"mt-0.5 line-clamp-1 text-[10.5px] leading-none",style:Se({color:Tr.value})},de(y.detail),5)):te("",!0)])],8,pU))],8,cU))),128))],12,oU))])):te("",!0)],512),a.value.meta.footer?(w(),$("footer",{key:0,class:"mt-3 text-[11px] leading-snug",style:Se({color:fr.value})},de(a.value.meta.footer),5)):te("",!0)],12,LR)):te("",!0)}}),hU="text-[14px] leading-[1.55] tracking-[-0.006em] text-pretty @sm/chat:text-[15px] @lg/chat:text-[15.5px]",gU=["innerHTML"],Wa=Pe({__name:"ChatRichText",props:{text:{},inverted:{type:Boolean},streaming:{type:Boolean}},emits:["action"],setup(e,{emit:t}){let n=e,i=t,r=We(n.text),o;mt([()=>n.text,()=>n.streaming],([v,k])=>{k?o===void 0&&(o=requestAnimationFrame(()=>{o=void 0,r.value=n.text})):(o!==void 0&&(cancelAnimationFrame(o),o=void 0),r.value=v)}),Da(()=>{o!==void 0&&cancelAnimationFrame(o)});let a=new et.Renderer;a.link=({href:v,text:k})=>{let T=v.trim();if(!T||T==="#")return k;let S=!1;if(typeof window<"u")try{S=new URL(v,window.location.href).origin===window.location.origin}catch{S=!1}return S?`<a href="${v}">${k}</a>`:`<a href="${v}" target="_blank" rel="noopener noreferrer">${k}</a>`},et.setOptions({breaks:!0,gfm:!0,renderer:a});function s(v){if(!v)return"";let k=et.parse(v,{async:!1});return yE.sanitize(k,{ADD_ATTR:["target"],ADD_DATA_URI_TAGS:["img"]})}function l(v){if(typeof v!="string")return null;let k=v.trim();return k?k.slice(0,80):null}function u(v){try{let k=JSON.parse(v);if(!k||typeof k!="object"||Array.isArray(k))return{topLevelKeys:[],declaredVisualType:null,declaredChartType:null,declaredDiagramType:null,inputType:null};let T=k;return{topLevelKeys:Object.keys(T).sort().slice(0,24),declaredVisualType:l(T.visualType),declaredChartType:l(T.chartType),declaredDiagramType:l(T.diagramType),inputType:l(T.type)}}catch{return{topLevelKeys:[],declaredVisualType:null,declaredChartType:null,declaredDiagramType:null,inputType:null}}}function d(v){if(typeof window>"u")return null;try{return new URL(v.currentSrc||v.src,window.location.href).host||null}catch{return null}}function p(v){typeof HTMLImageElement<"u"&&v.target instanceof HTMLImageElement&&typeof console<"u"&&console.warn("[chat-image] load_failed",{host:d(v.target),altPresent:!!v.target.alt?.trim(),width:v.target.naturalWidth||null,height:v.target.naturalHeight||null})}let m=/```(?:pl-visual|pl-platform-visual|pl-card)[ \t]*(?:\r?\n|$)/;function f(v){let{text:k,streaming:T}=v,S=[],z=/```(pl-visual|pl-platform-visual|pl-card)[ \t]*\r?\n([\s\S]*?)```/g,j=0,O=0,U=z.exec(k);for(;U!==null;){let se=s(k.slice(j,U.index));se&&S.push({kind:"markdown",key:`md-${O}`,html:se});let pe=U[1],F=U[2].trim();if(pe==="pl-card"){let ue=wI(F);ue.ok?S.push({kind:"card",key:`card-${O}`,spec:ue.spec}):(typeof console<"u"&&console.warn("[pl-card] parse_failed",{reason:ue.reason,message:ue.message,payloadChars:F.length}),S.push({kind:"markdown",key:`card-${O}`,html:s(`\`\`\`
|
|
167
167
|
${F}
|
|
168
|
-
\`\`\``)}))}else{let ue=SI(F);if(ue.ok)S.push({kind:"visual",key:`visual-${O}`,result:ue});else{typeof console<"u"&&console.warn("[pl-visual] parse_failed",{reason:ue.reason,message:ue.message,hasFallbackMarkdown:!!ue.fallbackMarkdown,payloadChars:F.length,...u(F)});let Je=ue.fallbackMarkdown?s(ue.fallbackMarkdown):"";Je&&S.push({kind:"markdown",key:`visual-${O}`,html:Je})}}j=U.index+U[0].length,O+=1,U=z.exec(k)}let J=k.slice(j),W=T?m.exec(J):null;if(W){let se=s(J.slice(0,W.index));return se&&S.push({kind:"markdown",key:`md-${O}`,html:se}),S.push({kind:"pending-visual",key:`pending-${O}`}),S}let ce=s(J);return ce&&S.push({kind:"markdown",key:`md-${O}`,html:ce}),S}let h=R(()=>{let v=r.value;return v?f({text:v,streaming:!!n.streaming}):[]});return(v,k)=>(w(),$("div",{class:V(["chat-msg-rich break-words",Ae(mU)]),onErrorCapture:p},[(w(!0),$(ge,null,st(h.value,T=>(w(),$(ge,{key:T.key},[T.kind==="markdown"?(w(),$("div",{key:0,class:V(["chat-msg-prose",e.inverted?"chat-msg-prose-invert":""]),innerHTML:T.html},null,10,fU)):T.kind==="visual"?(w(),Fe(pU,{key:1,result:T.result,inverted:e.inverted},null,8,["result","inverted"])):T.kind==="card"?(w(),Fe(SR,{key:2,spec:T.spec,inverted:e.inverted,onAction:k[0]||(k[0]=S=>i("action",S))},null,8,["spec","inverted"])):(w(),$("div",{key:3,"data-test":"chat-visual-pending",role:"status",class:"my-6 flex items-center gap-2.5 rounded-[20px] px-4 py-5 text-[12px] font-medium",style:Se({background:e.inverted?"transparent":"var(--color-theme-0)",boxShadow:`inset 0 0 0 1px ${e.inverted?"rgba(255, 255, 255, 0.14)":"color-mix(in oklch, var(--color-theme-900) 8%, transparent)"}`,color:e.inverted?"rgba(255, 255, 255, 0.6)":"var(--color-theme-500)"})},[...k[1]||(k[1]=[b("span",{class:"size-2 shrink-0 animate-pulse rounded-full",style:{background:"currentcolor"}},null,-1),xt(" Preparing chart\u2026 ",-1)])],4))],64))),128))],34))}}),hU=["data-composer-action"],gU=["placeholder","disabled","maxlength"],vU={class:"mt-2.5 flex items-center"},bU={class:"flex items-center gap-2"},yU=["data-composer-action","disabled","aria-label","title"],wU={key:0,class:"i-tabler-player-stop-filled size-3.5"},kU={key:1,class:"i-tabler-arrow-up size-[17px]"},xU={class:"sr-only"},_U=Pe({__name:"ChatComposer",props:C0({placeholder:{default:""},disabled:{type:Boolean,default:!1},maxlength:{},inverted:{type:Boolean,default:!1},showSend:{type:Boolean,default:!0},sendEnabled:{type:Boolean},sendLabel:{default:"Send"},action:{default:"send"}},{modelValue:{required:!0},modelModifiers:{}}),emits:C0(["submit","action"],["update:modelValue"]),setup(e,{expose:t,emit:n}){let i=n,r=NS(e,"modelValue"),o=Q();function a(u){u.isComposing||u.key==="Enter"&&!u.shiftKey&&(u.preventDefault(),i("submit"))}function s(u){e.disabled||u.target instanceof Element&&u.target.closest("button, a, textarea")||o.value?.focus()}mt(r,()=>oo(()=>{o.value&&(o.value.style.height="auto",o.value.style.height=`${Math.min(o.value.scrollHeight,150)}px`)}));function l(){let u=o.value;u&&(u.style.height="auto",window.matchMedia("(pointer: coarse)").matches?(u.blur(),requestAnimationFrame(()=>{let d=document.activeElement;d&&(d.tagName==="TEXTAREA"||d.tagName==="INPUT")&&d.blur()})):u.focus())}return t({focus:()=>o.value?.focus(),settleAfterSend:l}),(u,d)=>(w(),$("div",{"data-test":"messaging-composer","data-composer-action":e.action,class:V(["w-full cursor-text rounded-2xl px-4 pb-2.5 pt-4 transition-colors duration-200",e.inverted?"bg-white/10 backdrop-blur-xl ring-1 ring-white/15 hover:ring-white/25 focus-within:bg-white/15 focus-within:ring-white/25":"bg-white shadow-[0_1px_2px_rgba(15,23,42,0.04),0_12px_32px_rgba(15,23,42,0.07)] ring-1 ring-theme-950/20 hover:ring-theme-950/30 focus-within:ring-theme-950/30"]),onClick:s},[zt(u.$slots,"input",{},()=>[ep(b("textarea",{ref_key:"textarea",ref:o,"onUpdate:modelValue":d[0]||(d[0]=p=>r.value=p),"data-test":"messaging-input",rows:"1",enterkeyhint:"send",inputmode:"text",autocomplete:"off",autocapitalize:"sentences",autocorrect:"on",spellcheck:"true",placeholder:e.placeholder,disabled:e.disabled,maxlength:e.maxlength,style:{fontSize:"16px",resize:"none"},class:V(["block w-full bg-transparent leading-[1.5] focus:outline-none disabled:opacity-50 overflow-y-auto [scrollbar-width:none] [-ms-overflow-style:none] [&::-webkit-scrollbar]:hidden",e.inverted?"text-white placeholder-white/50":"text-theme-900 placeholder-theme-400"]),onKeydown:a},null,42,gU),[[dp,r.value]])]),b("div",vU,[zt(u.$slots,"leading"),d[2]||(d[2]=b("div",{class:"flex-1"},null,-1)),b("div",bU,[zt(u.$slots,"actions"),e.showSend?(w(),$("button",{key:0,"data-test":"messaging-send-btn","data-composer-action":e.action,class:V(["flex size-8 items-center justify-center rounded-full transition-colors duration-150 pointer-coarse:size-11",e.sendEnabled?e.inverted?"bg-theme-0 text-theme-950 hover:bg-theme-100 cursor-pointer":"bg-theme-900 text-theme-0 hover:bg-theme-800 cursor-pointer":e.inverted?"bg-white/10 text-white/30":"bg-theme-100 text-theme-400"]),disabled:!e.sendEnabled,"aria-label":e.sendLabel,title:e.sendLabel,onClick:d[1]||(d[1]=p=>i("action"))},[e.action==="stop"?(w(),$("i",wU)):(w(),$("i",kU)),b("span",xU,de(e.sendLabel),1)],10,yU)):te("",!0)])])],10,hU))}}),$U={class:"flex items-center gap-3 my-6 px-2"},SU=Pe({__name:"ChatDivider",props:{label:{},inverted:{type:Boolean,default:!1}},setup(e){return(t,n)=>(w(),$("div",$U,[b("div",{class:V(["flex-1 h-px",e.inverted?"bg-white/15":"bg-theme-200/70"])},null,2),b("span",{class:V(["text-[11px] font-medium shrink-0 tracking-[0.06em] uppercase",e.inverted?"text-white/50":"text-theme-400"])},de(e.label),3),b("div",{class:V(["flex-1 h-px",e.inverted?"bg-white/15":"bg-theme-200/70"])},null,2)]))}}),IU=80,EU=600,TU=Pe({__name:"ChatScroller",setup(e,{expose:t}){let n=Q(),i=Q(),r=Q(!0),o,a,s=0;function l(){let f=n.value;f&&(f.scrollTop=f.scrollHeight)}function u(){let f=n.value;f&&(r.value=f.scrollHeight-f.scrollTop-f.clientHeight<=IU)}function d(){s=Date.now()+EU}function p(){r.value&&Date.now()>s&&l()}function m(){r.value=!0,s=0,l(),requestAnimationFrame(()=>{l(),requestAnimationFrame(l)})}return t({pin:m}),Ut(()=>{requestAnimationFrame(()=>{l(),requestAnimationFrame(l)}),i.value&&(o=new ResizeObserver(p),o.observe(i.value),n.value&&o.observe(n.value),a=new MutationObserver(p),a.observe(i.value,{childList:!0,subtree:!0}))}),Da(()=>{o?.disconnect(),a?.disconnect()}),(f,h)=>(w(),$("div",{ref_key:"viewport",ref:n,class:V(["overflow-y-auto overscroll-contain overflow-x-hidden min-h-0 flex flex-col [scrollbar-width:none] [-ms-overflow-style:none] [&::-webkit-scrollbar]:hidden",r.value?"[overflow-anchor:none]":""]),onScrollPassive:u,onWheelPassive:d,onTouchstartPassive:d},[b("div",{ref_key:"content",ref:i,class:"flex-1 flex flex-col"},[zt(f.$slots,"default")],512)],34))}}),NU=["data-chat-turn"],CU=Pe({__name:"ChatTurn",props:{own:{type:Boolean},inverted:{type:Boolean,default:!1}},setup(e){return(t,n)=>(w(),$("div",{class:V(["group/msg flex items-end gap-2",e.own?"justify-end":"justify-start"]),"data-chat-turn":e.own?"own":"other"},[b("div",{"data-test":"messaging-message-body",class:V(e.own?"min-w-0 ml-3 @sm/chat:ml-[2em]":"w-full min-w-0 pr-3 @sm/chat:pr-[2em]")},[zt(t.$slots,"before"),t.$slots.default?(w(),$("div",{key:0,"data-test":"messaging-message-content",class:V(e.own?e.inverted?"rounded-[14px] px-4 py-2.5 bg-white/10 text-white":"rounded-[14px] px-4 py-2.5 bg-theme-50 text-theme-900":e.inverted?"text-white/95":"text-theme-900")},[zt(t.$slots,"default")],2)):te("",!0),zt(t.$slots,"after")],2)],10,NU))}}),zU=["aria-label"],AU={class:"absolute top-1/2 left-1/2 -translate-x-1/2 -translate-y-1/2 w-[28px] h-[28px] overflow-hidden"},OU=Pe({name:"FClose",__name:"FClose",props:{ariaLabel:{}},emits:["click"],setup(e){let t=Q(!1);return Ut(()=>{setTimeout(()=>{t.value=!0},100)}),(n,i)=>(w(),$("button",{type:"button","aria-label":e.ariaLabel||"Close",class:"close block cursor-pointer w-[60px] h-[60px] rounded-full transition-all duration-1000 ease-[cubic-bezier(0.25,1,0.33,1)] hover:scale-110 active:scale-90 hover:rotate-90",onClick:i[0]||(i[0]=r=>n.$emit("click",r))},[i[1]||(i[1]=b("span",{class:"absolute inset-0 rounded-full transition-all"},null,-1)),b("span",AU,[b("span",{class:V(["absolute h-full w-[3px] rounded-[5px] left-[13px] transition-all duration-[400ms] ease-[cubic-bezier(0.52,0.01,0.16,1)]",t.value?"translate-y-0 translate-x-0 rotate-45":"translate-y-[30px] -translate-x-[30px] rotate-0"]),style:{"background-color":"currentColor","transition-delay":"0.15s"}},null,2),b("span",{class:V(["absolute h-full w-[3px] rounded-[5px] left-[13px] transition-all duration-[400ms] ease-[cubic-bezier(0.52,0.01,0.16,1)]",t.value?"translate-y-0 translate-x-0 -rotate-45":"-translate-y-[30px] -translate-x-[30px] rotate-0"]),style:{"background-color":"currentColor","transition-delay":"0.45s"}},null,2)])],8,zU))}}),DU={class:"flex min-h-full items-center justify-center text-center p-4"},PU={key:0,class:"text-base p-4 font-semibold"},RU={key:1,class:"flex items-center gap-2 px-2"},jy=Pe({inheritAttrs:!1,name:"FModal",__name:"FModal",props:{vis:{type:Boolean,default:!1},modalClass:{},styleClass:{},fullScreen:{type:Boolean,default:!1},hasClose:{type:Boolean,default:!1},title:{default:""},transitionMode:{default:"modal"},teleportTo:{default:"body"},disableTeleport:{type:Boolean,default:!1}},emits:["update:vis","close","escape"],setup(e,{emit:t}){let n=t,i=Q(!1);function r(d){let{reason:p}=d;n("update:vis",!1),n("close",!0),p==="escape"&&n("escape",!0)}let o=R(()=>{let d=e.modalClass?[e.modalClass]:["max-w-screen-md p-24"],p=e.styleClass?[e.styleClass]:["bg-theme-0","shadow-xl"];return e.fullScreen?d.push("fixed inset-0"):d.push("rounded-2xl"),["relative","text-left","transform","transition-all","w-full","overflow-hidden",...d,...p]}),a=Q(!1),s=[];function l(d){d.key==="Escape"&&e.vis&&r({reason:"escape"})}Ut(async()=>{i.value=!0;let d=mt(()=>e.vis,p=>{p?setTimeout(()=>a.value=!0,300):a.value=!1},{immediate:!0});s.push(d),typeof document<"u"&&(document.addEventListener("keydown",l),s.push(()=>document.removeEventListener("keydown",l)))}),Wn(()=>{s.forEach(d=>d())});let u=R(()=>e.transitionMode==="slideUp"?{enterActiveClass:"ease-[cubic-bezier(0.25,1,0.33,1)] duration-500",enterFromClass:"opacity-0 translate-y-full scale-95",enterToClass:"opacity-100 translate-y-0 scale-100",leaveActiveClass:"ease-[cubic-bezier(0.25,1,0.33,1)] duration-500",leaveFromClass:"opacity-100 translate-y-0 scale-100",leaveToClass:"opacity-0 translate-y-full scale-95"}:{enterActiveClass:"ease-[cubic-bezier(0.25,1,0.33,1)] duration-500",enterFromClass:"opacity-0 scale-75",enterToClass:"opacity-100 translate-y-0 scale-100",leaveActiveClass:"ease-[cubic-bezier(0.25,1,0.33,1)] duration-500",leaveFromClass:"opacity-100 translate-y-0 scale-100",leaveToClass:"opacity-0 scale-75"});return(d,p)=>i.value?(w(),Fe(gS,{key:0,to:e.teleportTo,disabled:e.disableTeleport},[b("div",{class:V(["fixed inset-0 z-50",e.vis?"":"pointer-events-none"]),"aria-labelledby":"modal-title",role:"dialog","aria-modal":"true"},[be(so,{"enter-active-class":"ease-out duration-300","enter-from-class":"opacity-0","enter-to-class":"opacity-100","leave-active-class":"ease-in duration-200","leave-from-class":"opacity-100","leave-to-class":"opacity-0"},{default:ot(()=>[e.vis?(w(),$("div",{key:0,class:"fixed inset-0 bg-theme-800/60 active:bg-theme-800/80 cursor-pointer dark:bg-theme-600/90 backdrop-blur-sm transition-opacity",onClick:p[0]||(p[0]=m=>r({reason:"escape"}))})):te("",!0)]),_:1}),b("div",{class:"fixed inset-0 z-40 overflow-y-auto overscroll-contain no-scrollbar",onClick:p[3]||(p[3]=m=>r({reason:"escape"}))},[b("div",DU,[be(so,xa(Ra(u.value)),{default:ot(()=>[e.vis?(w(),$("div",{key:0,class:V([o.value,"w-full"]),onClick:p[2]||(p[2]=Et(()=>{},["stop"]))},[e.hasClose||e.title||d.$slots.actions?(w(),$("div",{key:0,class:V(!e.title&&(e.hasClose||d.$slots.actions)?"absolute top-0 right-0 z-10":"flex justify-between items-center")},[e.title?(w(),$("h2",PU,de(e.title),1)):te("",!0),e.hasClose||d.$slots.actions?(w(),$("div",RU,[zt(d.$slots,"actions"),e.hasClose?(w(),Fe(OU,{key:0,class:"relative","data-test-id":"close-modal",onClick:p[1]||(p[1]=Et(m=>r({reason:"escape"}),["stop"]))})):te("",!0)])):te("",!0)],2)):te("",!0),zt(d.$slots,"default")],2)):te("",!0)]),_:3},16)])])],2)],8,["to","disabled"])):te("",!0)}}),UU={"data-test":"share-reply-dialog",class:"flex flex-col"},jU={class:"flex h-[60px] shrink-0 items-center justify-between border-b border-theme-950/[0.06] px-5"},MU={class:"flex flex-col gap-4 p-5"},LU={class:"relative max-h-[300px] overflow-hidden rounded-2xl bg-theme-25 p-4 ring-1 ring-theme-950/[0.06]"},VU={class:"flex flex-col gap-3 text-[13px] leading-relaxed text-theme-800"},FU={key:0,class:"max-w-[85%] self-end whitespace-pre-wrap rounded-[14px] bg-theme-50 px-3 py-2"},BU={key:0,class:"flex h-11 items-center gap-2 rounded-xl bg-theme-50 px-3"},ZU=["value"],HU={key:1,class:"text-[13px] text-red-600"},KU={class:"flex items-center gap-3"},WU=["disabled"],qU=["disabled"],GU=Pe({__name:"ShareReplyDialog",props:{message:{},prompt:{},share:{}},emits:["close"],setup(e,{emit:t}){let n=t,i=Q(),r=Q(!1),o=Q(!1),a=Q(!1),s=Q(),l;mt(()=>e.message?.id,async p=>{if(i.value=void 0,s.value=void 0,a.value=!1,p){r.value=!0;try{i.value=(await e.share.get({messageId:p}))?.url}catch{s.value="Could not load this reply's link."}finally{r.value=!1}}},{immediate:!0});async function u(){if(e.message&&!o.value){o.value=!0,s.value=void 0;try{i.value??(i.value=(await e.share.create({messageId:e.message.id})).url)}catch{s.value="Could not create a link. Try again.",o.value=!1;return}try{await navigator.clipboard.writeText(i.value),a.value=!0,clearTimeout(l),l=setTimeout(()=>{a.value=!1},1500)}catch{s.value="Copy the link from the field above."}finally{o.value=!1}}}async function d(){if(e.message&&!o.value){o.value=!0,s.value=void 0;try{await e.share.remove({messageId:e.message.id}),i.value=void 0,a.value=!1}catch{s.value="Could not delete the link. Try again."}finally{o.value=!1}}}return(p,m)=>(w(),Fe(jy,{vis:!!e.message,"modal-class":"w-full max-w-[480px] p-0",onClose:m[2]||(m[2]=f=>n("close"))},{default:ot(()=>[b("div",UU,[b("div",jU,[m[4]||(m[4]=b("span",{class:"text-[15px] font-semibold text-theme-900"},"Share reply",-1)),b("button",{type:"button","aria-label":"Close",class:"grid size-9 cursor-pointer place-items-center rounded-full text-theme-500 transition-colors hover:bg-theme-950/5 hover:text-theme-900",onClick:m[0]||(m[0]=f=>n("close"))},[...m[3]||(m[3]=[b("i",{class:"i-tabler-x size-[17px]","aria-hidden":"true"},null,-1)])])]),b("div",MU,[b("div",LU,[b("div",VU,[e.prompt?(w(),$("div",FU,de(e.prompt),1)):te("",!0),e.message?(w(),Fe(Wa,{key:1,text:e.message.text},null,8,["text"])):te("",!0)]),m[5]||(m[5]=b("div",{class:"pointer-events-none absolute inset-x-0 bottom-0 h-16 bg-gradient-to-t from-theme-25 to-transparent"},null,-1))]),m[8]||(m[8]=b("p",{class:"text-[13px] leading-relaxed text-theme-500"}," Anyone with the link can see this message and reply. Messages after it stay private. ",-1)),i.value?(w(),$("div",BU,[m[6]||(m[6]=b("i",{class:"i-tabler-link size-[15px] shrink-0 text-theme-400","aria-hidden":"true"},null,-1)),b("input",{"data-test":"share-reply-url",value:i.value,readonly:"","aria-label":"Share link",class:"min-w-0 flex-1 truncate bg-transparent text-[14px] text-theme-800 outline-none",onFocus:m[1]||(m[1]=f=>f.target.select())},null,40,ZU)])):te("",!0),s.value?(w(),$("p",HU,de(s.value),1)):te("",!0),b("div",KU,[i.value?(w(),$("button",{key:0,type:"button","data-test":"share-reply-delete",disabled:o.value,class:"flex h-11 cursor-pointer items-center gap-1.5 px-1 text-[14px] font-medium text-theme-500 transition-colors hover:text-red-600 disabled:opacity-50",onClick:d},[...m[7]||(m[7]=[b("i",{class:"i-tabler-trash size-[15px]","aria-hidden":"true"},null,-1),xt(" Delete link ",-1)])],8,WU)):te("",!0),b("button",{type:"button","data-test":"share-reply-copy",disabled:r.value||o.value,class:"ml-auto h-11 cursor-pointer rounded-full bg-theme-900 px-5 text-[15px] font-semibold text-theme-0 transition-transform active:scale-[0.98] disabled:opacity-50",onClick:u},de(a.value?"Copied":"Copy link"),9,qU)])])])]),_:1},8,["vis"]))}}),JU={VOICE_MIC_UNAVAILABLE:"I couldn't reach your microphone. Check that this site is allowed to use it, then try again.",VOICE_BOT_UNAVAILABLE:"Your assistant didn't pick up. Give it a moment and start the call again.",VOICE_CONNECT_TIMEOUT:"The call took too long to connect. Try again in a moment.",VOICE_CONNECTION_LOST:"The call dropped. Start it again when you're ready.",VOICE_BUSY:"Your assistant is on another call. Try again in a moment, or keep going by typing.",VOICE_UNAVAILABLE:"Voice isn't available right now. You can keep going by typing.",VOICE_MINT_INVALID:"That call couldn't be started. Refresh the page and try again.",VOICE_PROVIDER_ERROR:"The call ended unexpectedly. Try again, or keep going by typing."},YU="The call ended unexpectedly. Try again, or keep going by typing.";Rp=[0,2,4,6,8],OE=5,QU=33,ej=.7,tj=.1,rj=60,nj=320,ij=.55,oj=.1,aj=.32,sj=.9,yy=Rp.map(()=>0),lj=Rp.map(()=>OE),cj=class{constructor(e=typeof window>"u"?void 0:window){G(this,"browser",void 0),G(this,"heights",We(lj)),G(this,"targetBars",yy),G(this,"displayBars",yy),G(this,"level",{source:"mic",level:0}),G(this,"isMuted",!1),G(this,"usesIdleWave",!1),G(this,"frameId",0),G(this,"lastFrameAt",0),G(this,"easeFrame",t=>{let n=this.browser;if(!n)return;this.frameId=0;let i=Math.min(64,Math.max(0,t-this.lastFrameAt));this.lastFrameAt=t;let r=this.usesIdleWave?Rp.map((a,s)=>{let l=t/1e3*ij*2*Math.PI-s*sj;return oj+aj*(Math.sin(l)+1)/2}):this.targetBars;this.displayBars=this.displayBars.map((a,s)=>{let l=r[s]??0,u=l>a?rj:nj;return a+(l-a)*(1-Math.exp(-i/u))}),this.publish();let o=this.displayBars.every((a,s)=>Math.abs((r[s]??0)-a)<=5e-4);(this.usesIdleWave||!o)&&(this.frameId=n.requestAnimationFrame(this.easeFrame))}),this.browser=e}updateLevel(e){this.level=e,this.updateTargets()}setMuted(e){this.isMuted=e,this.updateTargets()}setIdleWave(e){this.usesIdleWave!==e&&(this.usesIdleWave=e,this.start())}stop(){this.frameId&&this.browser?.cancelAnimationFrame(this.frameId),this.frameId=0}updateTargets(){let e=n=>Math.max(0,n-tj)/.9,t=this.isMuted&&this.level.source==="mic";this.targetBars=Rp.map(n=>t?0:e(Math.min(1,Math.max(0,this.level.bands?.[n]??this.level.level)))),this.start()}start(){!this.browser||this.browser.matchMedia("(prefers-reduced-motion: reduce)").matches?(this.displayBars=this.usesIdleWave?yy:this.targetBars,this.publish()):this.frameId||(this.lastFrameAt=this.browser.performance.now(),this.frameId=this.browser.requestAnimationFrame(this.easeFrame))}publish(){this.heights.value=this.displayBars.map(e=>Math.round((OE+Math.min(1,Math.max(0,e))**ej*QU)*10)/10)}},uj={connecting:{label:"Connecting",tone:"bg-amber-500",waits:!0},listening:{label:"Listening",tone:"bg-green-500",waits:!1},thinking:{label:"Thinking",tone:"bg-amber-500",waits:!0,visibleText:"Thinking"},working:{label:"Working",tone:"bg-primary-500",waits:!0},speaking:{label:"Speaking",tone:"bg-primary-500",waits:!1},error:{label:"Connection problem",tone:"bg-red-500",waits:!1,visibleText:"Connection lost"}};mj=["data-voice-state","data-voice-activity"],fj=["src"],hj={key:1,"data-test":"voice-background-fallback","aria-hidden":"true",class:"pointer-events-none absolute inset-0 bg-[#0A1522]"},gj={"data-test":"voice-stage",class:"relative z-10 flex flex-1 flex-col items-center px-8"},vj={"data-voice-assistant-avatar":""},bj={"data-test":"voice-lower-stage",class:"flex flex-1 flex-col items-center pt-10"},yj={"data-test":"voice-histogram","aria-hidden":"true",class:"flex h-[38px] items-center gap-[5px]"},wj={"data-test":"voice-presence-status",role:"status","aria-live":"polite",class:"sr-only"},kj=["data-taking-longer"],xj={class:"absolute inset-x-0 bottom-0 z-20 flex items-center justify-between px-14 pb-[max(3rem,env(safe-area-inset-bottom))] sm:px-12"},_j=["disabled","aria-label","aria-pressed","title"],$j=Pe({__name:"VoiceMode",props:{bot:{},chatController:{},isLight:{type:Boolean},backdropSrc:{}},emits:["end"],setup(e,{expose:t,emit:n}){let i=n,r=We(!1),o=We(),a=We(!1),s=We({user:!1,bot:!1}),l=We({active:!1}),u=We(!1),d=We(!1),p=We(),m=R(()=>p.value?.state.value??"idle"),f=R(()=>p.value?.isMuted.value??!1),h=new cj,v=h.heights,k=T0("endButton"),T=T0("muteButton"),S=!1,z,j,O,U=R(()=>pj({sessionState:m.value,hadError:r.value,providerThinking:a.value,speaking:s.value,work:l.value,isMuted:f.value,takingLonger:u.value})),J=R(()=>{if(U.value.activity==="thinking")return"thinking";if(U.value.activity==="working")return`working:${l.value.description??""}`});mt(()=>U.value.usesIdleWave,F=>h.setIdleWave(F),{immediate:!0}),mt(f,F=>h.setMuted(F),{immediate:!0}),mt(J,F=>{O&&clearTimeout(O),u.value=!1,F&&(O=setTimeout(()=>{O=void 0,u.value=!0},uE),O.unref?.())},{immediate:!0});async function W(){S=!0,await p.value?.end()}t({end:W});function ce(){S||(S=!0,i("end",z))}function se(F){F.shiftKey&&document.activeElement===k.value?(F.preventDefault(),T.value?.focus()):!F.shiftKey&&document.activeElement===T.value&&(F.preventDefault(),k.value?.focus())}async function pe(){let F=p.value;F&&!d.value&&(d.value=!0,await F.toggleMuted(),d.value=!1)}return Ut(async()=>{k.value?.focus({preventScroll:!0});let F=e.chatController?.createVoiceClient({onLevel:ue=>h.updateLevel(ue),onEnded:ue=>{z=ue},onStateChange:ue=>{ue==="ended"&&(r.value?j=setTimeout(ce,1600):ce())},onThinkingChange:ue=>{a.value=ue},onSpeakingChange:ue=>{s.value=ue},onWorkChange:ue=>{l.value=ue},onError:ue=>{r.value=!0,ue.code!=="VOICE_CONNECTION_LOST"&&(o.value=XU(ue.code)),e.chatController?.logger?.warn("voice.session.failed",{code:ue.code,providerMessage:ue.message})},onMetric:ue=>{e.chatController?.logger?.info(ue.name,{durationMs:ue.durationMs})}});F?(p.value=F,await F.start()):ce()}),Wn(()=>{S=!0,j&&clearTimeout(j),O&&clearTimeout(O),h.stop(),p.value?.end()}),(F,ue)=>(w(),$("div",{"data-test":"voice-mode","data-voice-state":m.value,"data-voice-activity":U.value.activity,class:"relative flex min-h-0 flex-1 flex-col overflow-hidden bg-[#0A1522] text-white",onKeydown:Gn(se,["tab"])},[e.backdropSrc?(w(),$("img",{key:0,"data-test":"voice-background-image",src:e.backdropSrc,alt:"","aria-hidden":"true",draggable:"false",class:"pointer-events-none absolute inset-0 size-full object-cover"},null,8,fj)):(w(),$("div",hj)),ue[2]||(ue[2]=b("div",{"data-test":"voice-background-overlay","aria-hidden":"true",class:"pointer-events-none absolute inset-0 bg-gradient-to-b from-[#050F19]/82 via-[#050F19]/90 to-[#050F19]/99"},null,-1)),b("div",gj,[ue[0]||(ue[0]=b("div",{"data-test":"voice-stage-spacer","aria-hidden":"true",class:"flex-1"},null,-1)),b("div",vj,[be(xy,{bot:e.bot,"show-status":!1,"show-owner-mark":!1,"is-light":!1,class:"size-32"},null,8,["bot"])]),b("div",bj,[b("div",yj,[(w(!0),$(ge,null,st(Ae(v),(Je,ct)=>(w(),$("span",{key:ct,"data-test":"voice-histogram-bar",class:V(["w-[5px] rounded-full transition-colors duration-150",U.value.tone]),style:Se({height:`${Je}px`})},null,6))),128))]),b("div",wj,de(o.value??U.value.label),1),b("p",{"data-test":"voice-visible-status","data-taking-longer":U.value.takingLonger||void 0,"aria-hidden":"true",class:"mt-5 min-h-5 text-center text-sm font-medium tracking-wide text-white/80"},de(o.value??U.value.visibleStatus),9,kj)])]),b("div",xj,[b("button",{ref_key:"endButton",ref:k,type:"button","data-test":"voice-end-btn",class:"flex size-16 cursor-pointer items-center justify-center rounded-full bg-white/10 text-white ring-1 ring-white/20 transition-colors hover:bg-white/15 active:bg-white/25","aria-label":"Hang up",title:"Hang up",onClick:ce},[...ue[1]||(ue[1]=[b("i",{class:"i-tabler-x size-[25px]","aria-hidden":"true"},null,-1)])],512),b("button",{ref_key:"muteButton",ref:T,type:"button","data-test":"voice-mute-btn",class:V(["flex size-16 items-center justify-center rounded-full ring-1 transition-colors active:opacity-70",[f.value?"bg-white text-[#050F19] ring-white":"bg-white/10 text-white ring-white/20",m.value==="live"&&!d.value?"cursor-pointer":"cursor-default opacity-50"]]),disabled:m.value!=="live"||d.value,"aria-label":f.value?"Unmute microphone":"Mute microphone","aria-pressed":f.value,title:f.value?"Unmute microphone":"Mute microphone",onClick:pe},[b("i",{class:V([f.value?"i-tabler-microphone-off":"i-tabler-microphone","size-[25px]"]),"aria-hidden":"true"},null,2)],10,_j)])],40,mj))}}),Sj={key:0,class:"pb-4"},Ij={key:1,"data-test":"messaging-sdk-header",class:"shrink-0 border-b border-theme-100 px-4 py-3"},Ej={class:"min-w-0 flex-1"},Tj={class:"truncate text-base font-semibold leading-tight text-theme-900"},Nj={class:"mt-1 truncate text-sm leading-tight text-theme-500"},Cj={key:0,class:"shrink-0 rounded-full bg-theme-50 px-2.5 py-1 font-mono text-[11px] font-medium text-theme-500"},zj=["aria-label"],Aj={key:0,"data-test":"messaging-empty-state",class:"flex flex-col items-center justify-center px-4"},Oj=["title"],Dj=["data-journal-outcome"],Pj=["data-message-id","data-message-sender","data-conversation-id","data-message-sequence","data-system-kind","data-issue-code","data-issue-bucket","data-issue-action-label","data-issue-action-url","data-streaming"],Rj={class:"flex items-center gap-3"},Uj=["href"],jj=["data-test","data-message-id","data-message-sender","data-conversation-id","data-message-sequence","data-system-kind","data-routine-run-id"],Mj=["data-message-id","data-message-sender","data-conversation-id","data-message-sequence","data-system-kind","data-issue-code","data-issue-bucket","data-streaming"],Lj=["data-routine-run-id"],Vj=["src","alt"],Fj=["src"],Bj=["href"],Zj={key:0,"data-test":"messaging-message-text-part"},Hj=["src","alt","data-attachment-placement"],Kj=["src","data-attachment-placement"],Wj=["href","data-attachment-placement"],qj=["data-actions-reveal"],Gj=["data-copied","title","aria-label","onClick"],Jj=["onClick"],Yj=["onClick"],Xj=["data-journal-outcome"],Qj=["data-journal-outcome"],eM=["data-test","data-working-description"],tM={key:0,class:"truncate"},rM={key:1,class:"sr-only"},nM=["data-issue-code"],iM={class:"min-w-0 flex-1"},oM={"data-test":"messaging-transient-issue-title",class:"font-medium"},aM={"data-test":"messaging-transient-issue-help"},sM=["href"],lM=["inert","aria-hidden"],cM=["data-seat-state"],uM=["src","alt"],dM={class:"max-w-20 truncate"},pM=["onClick"],mM={key:0,class:"shrink-0 flex items-center justify-center size-14"},fM={class:"font-mono text-sm tabular-nums"},hM=["disabled","aria-label","title"],gM={key:0,class:"i-svg-spinners-ring-resize size-5"},vM={key:1,class:"i-tabler-plus size-5"},bM={class:"sr-only"},yM=["aria-label","title"],wM={class:"sr-only"},kM=["disabled","aria-label","title"],xM={class:"flex h-4 items-center gap-[2px]","aria-hidden":"true"},_M={key:2,"data-test":"messaging-ai-notice",class:"mx-auto max-w-[640px] @5xl/chat:max-w-[720px] pt-3 text-center text-[11.5px] leading-none text-theme-300"},yo=Up(Pe({__name:"ElBotChat",props:{chatController:{},bot:{},variant:{default:"dark"},scope:{default:"private"},scopeName:{},setupHint:{},emptyStateMessage:{},showHeader:{type:Boolean,default:!1},headerMeta:{},centered:{type:Boolean,default:!1}},setup(e){let t={private:{icon:"i-tabler-lock",label:"Private",tooltip:"Only you can see this conversation"},org:{icon:"i-tabler-users",label:"Workspace",tooltip:"Visible to workspace members"},public:{icon:"i-tabler-globe",label:"Public",tooltip:"Anyone with the link can see this"}},n=R(()=>{let ee={...t[e.scope]};return e.scope==="org"&&e.scopeName&&(ee.label=e.scopeName,ee.tooltip=`Visible to ${e.scopeName} members`),ee}),i=Q(),r=Q(),o=Q();function a(ee){return ee?/\[[^\]]+\]\([^)]+\)/.test(ee):!1}function s(ee){return ee.sender==="system"&&(!!ee.issue||ee.id===pe.value)}function l(ee,L){let H=ee[L],Qe=ee[L+1];return!Qe||Qe.sender!==H.sender}let u=R(()=>e.chatController?.textState.value),d=R(()=>u.value?.isConnected??!1),p=R(()=>u.value?.isThinking??!1),m=R(()=>u.value?.connectionStatus!=="connected"&&!u.value?.error),f=R(()=>e.chatController?.liveTurnBlocks?.value??[]),h=R(()=>{for(let ee=f.value.length-1;ee>=0;ee--){let L=f.value[ee];if(L?.kind==="text")return L.id}}),v=R(()=>e.chatController?.liveStreamMessageId?.value),k=R(()=>{let ee=e.chatController?.sharedMessages.value??[];return f.value.length&&v.value?ee.filter(L=>L.id!==v.value):ee}),T=R(()=>{if(!e.chatController?.workJournal?.value)return u.value?.workingDescription?.trim()||void 0}),S=R(()=>e.chatController?.workJournal?.value),z=R(()=>{if(!S.value&&!f.value.length)return;let ee=k.value,L=ee[ee.length-1];if(L)return L.sender==="bot"||L.sender==="system"?ee.length>=2?ee[ee.length-2].id:void 0:L.id}),j=R(()=>{let ee={};for(let L of k.value){if(L.sender==="user"||!L.toolActivities?.length)continue;let H=e.chatController?.workJournalFor?.({activities:L.toolActivities,outcome:m5(L),includeFailureNote:L.sender!=="system"});H&&(ee[L.id]=H)}return ee});function O(ee){return j.value[ee.id]}function U(ee,L){return ee.placement?.kind!=="inline"||!Number.isFinite(ee.placement.offset)?null:Math.max(0,Math.min(L.length,Math.trunc(ee.placement.offset)))}function J(ee,L){return ee.mediaId||`${ee.src}:${L}`}function W(ee){return(ee.attachments??[]).map((L,H)=>({attachment:L,index:H})).filter(({attachment:L})=>U(L,ee.text)===null)}function ce(ee){let L=ee.text??"";if(ee.sender!=="bot")return L?[{kind:"text",key:`${ee.id}:text`,text:L}]:[];let H=(ee.attachments??[]).map((bt,ut)=>({attachment:bt,index:ut,offset:U(bt,L)})).filter(bt=>bt.offset!==null).sort((bt,ut)=>bt.offset-ut.offset||bt.index-ut.index);if(H.length===0)return L?[{kind:"text",key:`${ee.id}:text`,text:L}]:[];let Qe=[],ke=0;for(let bt of H)bt.offset>ke&&Qe.push({kind:"text",key:`${ee.id}:text:${ke}`,text:L.slice(ke,bt.offset)}),Qe.push({kind:"attachment",key:`${ee.id}:attachment:${J(bt.attachment,bt.index)}`,attachment:bt.attachment,placement:"inline"}),ke=bt.offset;return ke<L.length&&Qe.push({kind:"text",key:`${ee.id}:text:${ke}`,text:L.slice(ke)}),Qe}let se=R(()=>u.value?.transientIssue),pe=R(()=>{if(!p.value)return;let ee=k.value,L=ee[ee.length-1];return L?.sender==="bot"||L?.sender==="system"?L.id:void 0}),F=R(()=>!p.value||T.value||S.value||f.value.length?!1:pe.value===void 0),ue=R(()=>!!T.value||F.value),Je=R(()=>u.value?.sendBlockedReason),ct=R(()=>Je.value==="bot_deleted"),ft=R(()=>m.value?"Connecting...":Je.value==="bot_deleted"?"This assistant was deleted":"Send a message"),Re=R(()=>X2(e.bot.state.value)),Be=R(()=>{if(ye.value||!Re.value||Re.value==="awake")return;let ee=e.bot.displayName.value||e.bot.name.value||"Your assistant";return Re.value==="changing"?`${ee} will be right back\u2026`:Re.value==="stuck"?`${ee} needs attention.`:`${ee} is ${Y2[Re.value].toLowerCase()}.`}),Mt=R(()=>e.chatController?.composerState?.value??{text:"",pendingAttachments:[],isUploading:!1}),Er=R({get:()=>Mt.value.text,set:ee=>e.chatController?.setComposerText?.({text:ee})}),mr=R(()=>Mt.value.pendingAttachments),gt=R(()=>Mt.value.isUploading),yt=R(()=>e.chatController?.voiceRecorder),Wr=R(()=>yt.value?.isBusy.value??!1),Tt=R(()=>e.chatController?.canAttachFile?.value??!1),Ye=R(()=>e.chatController?.canRecordAudio?.value??!1),Ht=R(()=>e.chatController?.composerAction?.value??"idle"),er=R(()=>Ht.value!=="idle"),Tr=R(()=>e.chatController?.composerShowsSecondaryStop?.value??!1),fr=R(()=>e.chatController?.queuedMessageIds?.value);function qr(ee){return fr.value?.has(ee)??!1}let hr=Q(),x;function I(ee){return ee.sender==="bot"&&ee.id!==pe.value&&!!ee.text?.trim()}let M=R(()=>[...k.value].reverse().find(I)?.id);async function B(ee){try{await navigator.clipboard.writeText(ee.text),hr.value=ee.id,clearTimeout(x),x=setTimeout(()=>{hr.value=void 0},1500)}catch(L){console.warn("ElBotChat: copy to clipboard rejected",L),e.chatController?.notify?.("Could not copy that message.")}}Wn(()=>clearTimeout(x));let X=R(()=>e.chatController?.canReportMessages??!1),_=R(()=>e.chatController?.messageShare),D=Q(),y=R(()=>{let ee=D.value;if(!ee)return;let L=k.value,H=L.findIndex(Qe=>Qe.id===ee.id);return L.slice(0,Math.max(H,0)).reverse().find(Qe=>Qe.sender==="user")?.text}),P=R(()=>Ht.value==="stop"?"Stop reply":Tr.value?"Send \u2014 answered after current work":"Send message"),E=R(()=>Ye.value&&!Wr.value&&!!yt.value?.canUseBrowserRecording),Y=R(()=>yt.value?.isActive.value??!1),ie=R(()=>yt.value?.state.value.phase==="sending"),fe=R(()=>yt.value?.elapsedLabel.value??"0:00"),ve=R(()=>{let ee=yt.value?.state.value.phase;return ee==="preparing"||ee==="sending"?yt.value?.statusText.value??"Starting microphone":dn.value?"Release to send":"Click mic to send"}),we=R(()=>yt.value?.state.value.phase==="sending"?"Sending voice message":Y.value?dn.value?"Release to send voice message":"Stop and send voice message":"Record voice message"),ye=Q(!1),Ne=Q(),Me=Q(),Xe=Q(),wt=0,$t=R(()=>e.chatController?.canStartVoice?.value??!1);mt([()=>e.bot.avatar.value?.src,$t],([ee,L])=>{let H=++wt;if(Xe.value=void 0,!L||!ee||typeof Image>"u")return;let Qe=new Image;Qe.onload=()=>{H===wt&&(Xe.value=ee)},Qe.src=ee},{immediate:!0});let St=R(()=>$t.value&&!ye.value&&!Y.value&&Ht.value==="idle"),Kt=R(()=>!d.value),vt=R(()=>Kt.value?`Voice available when ${e.bot.displayName.value||e.bot.name.value||"the assistant"} is awake`:"Start voice conversation");function Nt(){St.value&&!Kt.value&&(Me.value=Xe.value,ye.value=!0)}async function Gr(ee){if(!ye.value)return;let L=Ne.value;ye.value=!1,Me.value=void 0,await oo(),await L?.end(),window.matchMedia("(pointer: coarse)").matches||r.value?.focus(),await e.chatController?.refreshMessages(),ee&&e.chatController?.notify(I5(ee,e.bot.displayName.value||e.bot.name.value||"Your assistant"),{systemKind:"voice_ended"})}let $e=R(()=>e.variant==="light"),rs=R(()=>$e.value?"bg-theme-200/70":"bg-white/15"),zi=R(()=>$e.value?"text-theme-300":"text-white/30");Ut(async()=>{e.chatController&&!d.value&&await e.chatController.startTextConversation()}),Wn(()=>{e.chatController?.voiceRecorder?.teardown()});async function xo(){e.chatController&&Ht.value==="send"&&(r.value?.settleAfterSend(),i.value?.pin(),await e.chatController.sendComposerMessage())}async function Jr(ee){e.chatController&&!ct.value&&(i.value?.pin(),await e.chatController.sendChatMessage(ee))}async function ni(){e.chatController&&(Ht.value==="send"?await xo():await e.chatController.handleComposerAction())}function On(){o.value?.click()}async function pc(ee){let L=ee.target,H=L.files?.[0];H&&e.chatController&&!Wr.value&&(await e.chatController.attachFile({file:H}),L.value="")}function mc(ee){e.chatController?.removeAttachment({index:ee})}function ns(){yt.value?.start()}function ii(ee){yt.value?.finish(ee)}let dn=We(!1),Dn=!1;function _o(ee){ee.pointerType==="touch"&&(Dn=!0,dn.value=!0,ee.currentTarget.setPointerCapture?.(ee.pointerId),ns())}function Ur(ee){ee.pointerType==="touch"&&dn.value&&(dn.value=!1,ii({cancelled:!1}))}function oi(ee){ee.pointerType==="touch"&&dn.value&&(dn.value=!1,Dn=!1,ii({cancelled:!0}))}function is(){Y.value?ii({cancelled:!1}):ns()}function os(){Dn?Dn=!1:is()}function fc(ee,L){if(L===0){let bt=ee[L];return bt?.timestamp?as(new Date(bt.timestamp)):null}let H=ee[L-1],Qe=ee[L];if(!H?.timestamp||!Qe?.timestamp)return null;let ke=new Date(H.timestamp).getTime();return new Date(Qe.timestamp).getTime()-ke>9e5?as(new Date(Qe.timestamp)):null}function as(ee){let L=new Date,H=ee.toDateString()===L.toDateString(),Qe=new Date(L);Qe.setDate(Qe.getDate()-1);let ke=ee.toDateString()===Qe.toDateString(),bt=ee.toLocaleTimeString("en-US",{hour:"numeric",minute:"2-digit"});if(H)return bt;if(ke)return`Yesterday, ${bt}`;let ut=ee.getFullYear()===L.getFullYear();return`${ee.toLocaleDateString("en-US",{weekday:"long",month:"short",day:"numeric",...ut?{}:{year:"numeric"}})}, ${bt}`}return(ee,L)=>(w(),$("div",{"data-test":"messaging-root",class:V(["@container/chat relative flex h-full flex-col",k.value.length===0?"min-h-0 [justify-content:safe_center] overflow-y-auto":""])},[e.showHeader&&!$e.value?(w(),$("div",Sj,[be(Lp,{bot:e.bot,"is-online":d.value},null,8,["bot","is-online"])])):e.showHeader?(w(),$("div",Ij,[b("div",{class:V(["flex items-center gap-3",e.centered?"max-w-[640px] @5xl/chat:max-w-[720px] mx-auto":""])},[be(xy,{bot:e.bot,"is-light":$e.value,class:"size-10"},null,8,["bot","is-light"]),b("div",Ej,[b("div",Tj,de(e.bot.displayName.value),1),b("div",Nj,de(e.bot.title.value||"Assistant"),1)]),e.headerMeta?(w(),$("span",Cj,de(e.headerMeta),1)):te("",!0)],2)])):te("",!0),be(so,{name:"voice-call"},{default:ot(()=>[ye.value?(w(),$("div",{key:0,"data-test":"voice-call-overlay",role:"dialog","aria-modal":"true","aria-label":`Voice conversation with ${e.bot.displayName.value}`,class:"fixed inset-0 z-[100] flex items-stretch justify-stretch bg-[#050F19] sm:items-center sm:justify-center sm:bg-[#050F19]/45 sm:p-6",onKeydown:L[0]||(L[0]=Gn(H=>Gr(),["esc"]))},[be($j,{ref_key:"voiceMode",ref:Ne,bot:e.bot,"chat-controller":e.chatController,"backdrop-src":Me.value,"is-light":!1,class:"voice-call-card h-full w-full sm:max-h-[620px] sm:max-w-[420px] sm:flex-none sm:rounded-[32px] sm:shadow-[0_32px_80px_rgba(5,15,25,0.45)]",onEnd:Gr},null,8,["bot","chat-controller","backdrop-src"])],40,zj)):te("",!0)]),_:1}),m.value?(w(),$("div",{key:2,class:V(["py-16 flex flex-col items-center justify-center gap-2 text-sm",$e.value?"text-theme-400":"text-theme-600"])},[be(zp,{class:"size-4"})],2)):e.setupHint?(w(),$("div",{key:3,class:V(["flex items-center justify-center gap-1.5 py-2 text-[11px]",zi.value])},[L[16]||(L[16]=b("i",{class:"i-tabler-tool size-3"},null,-1)),b("span",null,de(e.setupHint),1)],2)):te("",!0),be(TU,{ref_key:"chatScroller",ref:i,"data-test":"messaging-scroller",inert:ye.value,"aria-hidden":ye.value?"true":void 0,class:V([k.value.length===0?"flex-none":"flex-1",e.centered&&!e.showHeader&&k.value.length>0?"mt-16":""])},{default:ot(()=>[b("div",{class:V([k.value.length===0?"flex flex-col items-center justify-center px-3 py-4":e.centered?"pt-4 pb-5 px-3 @lg/chat:px-8 space-y-2":"pt-4 pb-[120px] px-3 @lg/chat:px-8 space-y-2",e.centered?k.value.length===0?"max-w-[900px] mx-auto w-full":"max-w-[640px] @5xl/chat:max-w-[720px] mx-auto w-full":""])},[k.value.length===0&&!m.value?(w(),$("div",Aj,[zt(ee.$slots,"empty-heading",{bot:e.bot,isLight:$e.value},()=>[be(xy,{bot:e.bot,"is-light":$e.value,class:"mb-4 size-20 @sm/chat:size-24"},null,8,["bot","is-light"]),b("div",{class:V(["text-base @sm/chat:text-lg font-semibold",$e.value?"text-theme-900":"text-white"])},de(e.bot.displayName.value),3)],!0),e.emptyStateMessage===""?te("",!0):(w(),$(ge,{key:0},[b("p",{class:V(["mt-1 text-center text-xs @sm/chat:text-sm",zi.value])},de(e.emptyStateMessage||"Type your message to get started."),3),b("div",{class:V(["inline-flex items-center gap-1.5 mt-5 px-2.5 py-1 rounded-full text-[11px]",$e.value?"bg-theme-50 border border-theme-100 text-theme-400":"bg-white/10 border border-white/20 text-white/40"]),title:n.value.tooltip},[b("i",{class:V([n.value.icon,"size-3"])},null,2),b("span",null,de(n.value.label),1)],10,Oj)],64))])):te("",!0),(w(!0),$(ge,null,st(k.value,(H,Qe)=>(w(),$(ge,{key:H.id},[fc(k.value,Qe)?(w(),Fe(SU,{key:0,"data-test":"messaging-time-divider",label:fc(k.value,Qe)||"",inverted:!$e.value},null,8,["label","inverted"])):te("",!0),O(H)?(w(),$("div",{key:1,"data-test":"messaging-message-tool-activity","data-journal-outcome":O(H)?.outcome,class:"mb-4 w-full"},[be(sy,{model:O(H),"is-light":$e.value},null,8,["model","is-light"])],8,Dj)):te("",!0),s(H)?(w(),$("section",{key:2,"data-test":"messaging-system-msg","data-message-id":H.id,"data-message-sender":H.sender,"data-conversation-id":H.conversationId,"data-message-sequence":H.sequence,"data-system-kind":H.systemKind,"data-issue-code":H.issue?.code,"data-issue-bucket":H.issue?.bucket,"data-issue-action-label":H.issue?.actionLabel,"data-issue-action-url":H.issue?.actionUrl,"data-streaming":H.id===pe.value?"true":void 0,class:"mb-6 w-full"},[b("div",{class:V(["mb-1.5 text-center text-[10.5px] font-medium",zi.value])},"System message",2),b("div",Rj,[b("span",{"data-test":"messaging-system-divider-line","aria-hidden":"true",class:V(["hidden h-px flex-1 opacity-60 @md/chat:block",rs.value])},null,2),b("div",{class:V(["w-[46ch] min-w-0 max-w-full rounded-2xl px-5 py-3.5 text-center text-[13px] ring-1 [&_.chat-msg-rich]:max-w-none [&_.chat-msg-rich]:text-[13px] [&_.chat-msg-rich]:italic [&_.chat-msg-rich]:leading-[1.6]",$e.value?"text-theme-700 ring-theme-200/50":"text-white/85 ring-white/10"])},[H.text?(w(),Fe(Wa,{key:0,text:H.text,inverted:!$e.value,streaming:H.id===pe.value,onClick:L[1]||(L[1]=Et(()=>{},["stop"])),onAction:Jr},null,8,["text","inverted","streaming"])):H.issue?.help?(w(),Fe(Wa,{key:1,text:H.issue.help,inverted:!$e.value},null,8,["text","inverted"])):te("",!0),H.issue?.actionUrl&&!a(H.text)?(w(),$("a",{key:2,href:H.issue.actionUrl,"data-test":"messaging-system-msg-action",class:V(["mt-2 text-[12px] font-medium inline-flex items-center gap-1",$e.value?"text-theme-900 hover:text-theme-700":"text-white hover:text-white/80"]),onClick:L[2]||(L[2]=Et(()=>{},["stop"]))},[xt(de(H.issue.actionLabel)+" ",1),L[17]||(L[17]=b("i",{class:"i-tabler-arrow-right size-3"},null,-1))],10,Uj)):te("",!0)],2),b("span",{"data-test":"messaging-system-divider-line","aria-hidden":"true",class:V(["hidden h-px flex-1 opacity-60 @md/chat:block",rs.value])},null,2)])],8,Pj)):H.sender==="system"&&(H.systemKind==="routine_completed"||H.systemKind==="voice_ended")?(w(),$("div",{key:3,"data-test":H.systemKind==="routine_completed"?"messaging-routine-receipt":"messaging-voice-receipt","data-message-id":H.id,"data-message-sender":H.sender,"data-conversation-id":H.conversationId,"data-message-sequence":H.sequence,"data-system-kind":H.systemKind,"data-routine-run-id":H.routine?.run.routineRunId,class:V(["mb-6 flex items-center justify-center gap-2 text-[12px] leading-relaxed",$e.value?"text-theme-400":"text-white/50"])},[b("i",{class:V(["size-3.5 shrink-0",H.systemKind==="voice_ended"?"i-tabler-phone-off":"i-tabler-clock"]),"aria-hidden":"true"},null,2),b("span",null,de(H.text),1)],10,jj)):H.sender==="system"?(w(),$("div",{key:4,"data-test":"messaging-system-status-msg","data-message-id":H.id,"data-message-sender":H.sender,"data-conversation-id":H.conversationId,"data-message-sequence":H.sequence,"data-system-kind":H.systemKind,"data-issue-code":H.issue?.code,"data-issue-bucket":H.issue?.bucket,"data-streaming":H.id===pe.value?"true":void 0,class:V(["mb-4 flex w-fit max-w-[85%] items-start gap-2 rounded-2xl px-3 py-2 text-[13px] leading-relaxed ring-1",$e.value?"bg-theme-100 text-theme-600 ring-theme-200":"bg-white/10 text-white/70 ring-white/10"])},[L[18]||(L[18]=b("i",{class:"i-tabler-info-circle size-4 mt-0.5 shrink-0","aria-hidden":"true"},null,-1)),be(Wa,{text:H.text,inverted:!$e.value,onClick:L[3]||(L[3]=Et(()=>{},["stop"]))},null,8,["text","inverted"])],10,Mj)):(w(),Fe(CU,{key:5,own:H.sender==="user",inverted:!$e.value,"data-test":H.sender==="bot"?"messaging-assistant-msg":H.sender==="user"?"messaging-user-msg":void 0,"data-message-id":H.id,"data-message-sender":H.sender,"data-conversation-id":H.conversationId,"data-message-sequence":H.sequence,"data-system-kind":H.systemKind,"data-streaming":H.id===pe.value?"true":void 0,"data-queued":qr(H.id)?"true":void 0,"aria-label":qr(H.id)?"Sent \u2014 will be answered after the current work finishes":void 0,class:V({"mb-4":l(k.value,Qe),"opacity-70":qr(H.id)})},Pa({before:ot(()=>[H.sender==="bot"&&H.routine?(w(),$("div",{key:0,"data-test":"messaging-routine-label","data-routine-run-id":H.routine.run.routineRunId,class:V(["mb-2 flex items-start gap-2 text-[12px] leading-relaxed",$e.value?"text-theme-400":"text-white/50"])},[L[19]||(L[19]=b("i",{class:"i-tabler-clock size-3.5 mt-0.5 shrink-0","aria-hidden":"true"},null,-1)),b("span",null,"Ran "+de(H.routine.run.name||H.routine.run.sourceLabel||"a routine"),1)],10,Lj)):te("",!0),W(H).length?(w(),$("div",{key:1,class:V(["mb-1 space-y-1",H.sender==="user"?"flex flex-col items-end":""])},[(w(!0),$(ge,null,st(W(H),({attachment:ke,index:bt})=>(w(),$(ge,{key:J(ke,bt)},[ke.type==="image"?(w(),$("img",{key:0,src:ke.src,alt:ke.filename,"data-test":"messaging-attachment","data-attachment-placement":"block",class:"rounded-xl object-cover max-h-48 max-w-[240px] @sm/chat:max-w-[320px]"},null,8,Vj)):ke.type==="audio"?(w(),$("audio",{key:1,src:ke.src,controls:"","data-test":"messaging-attachment","data-attachment-placement":"block",class:"max-w-full"},null,8,Fj)):(w(),$("a",{key:2,href:ke.src,target:"_blank",rel:"noopener","data-test":"messaging-attachment","data-attachment-placement":"block",class:V(["inline-flex items-center gap-1.5 px-3 py-1.5 rounded-lg text-xs",$e.value?"bg-theme-100 text-theme-600 hover:bg-theme-200":"bg-white/10 text-white/80 hover:bg-white/20"])},[L[20]||(L[20]=b("i",{class:"i-tabler-file size-3.5"},null,-1)),xt(" "+de(ke.filename),1)],10,Bj))],64))),128))],2)):te("",!0)]),after:ot(()=>[I(H)?(w(),$("div",{key:0,"data-test":"messaging-message-actions","data-actions-reveal":H.id===M.value?"always":"hover",class:V(["-ml-1 flex items-center gap-1 pt-1 transition-opacity",[$e.value?"text-theme-300":"text-white/35",H.id===M.value?"":"opacity-0 group-hover/msg:opacity-100 focus-within:opacity-100 pointer-coarse:opacity-100"]])},[b("button",{type:"button","data-test":"messaging-message-copy","data-copied":hr.value===H.id||void 0,title:hr.value===H.id?"Copied":"Copy","aria-label":hr.value===H.id?"Copied":"Copy",class:V(["grid size-6 cursor-pointer place-items-center transition-colors",$e.value?"hover:text-theme-800":"hover:text-white"]),onClick:Et(ke=>B(H),["stop"])},[b("i",{class:V(["size-3.5",hr.value===H.id?"i-tabler-check":"i-tabler-copy"]),"aria-hidden":"true"},null,2)],10,Gj),_.value?(w(),$("button",{key:0,type:"button","data-test":"messaging-message-share",title:"Share","aria-label":"Share",class:V(["grid size-6 cursor-pointer place-items-center transition-colors",$e.value?"hover:text-theme-800":"hover:text-white"]),onClick:Et(ke=>D.value=H,["stop"])},[...L[22]||(L[22]=[b("i",{class:"i-tabler-share-2 size-3.5","aria-hidden":"true"},null,-1)])],10,Jj)):te("",!0),X.value?(w(),$("button",{key:1,type:"button","data-test":"messaging-message-report",title:"Report","aria-label":"Report",class:V(["grid size-6 cursor-pointer place-items-center transition-colors",$e.value?"hover:text-theme-800":"hover:text-white"]),onClick:Et(ke=>e.chatController?.reportMessage(H.id),["stop"])},[...L[23]||(L[23]=[b("i",{class:"i-tabler-flag size-3.5","aria-hidden":"true"},null,-1)])],10,Yj)):te("",!0)],10,qj)):te("",!0)]),_:2},[ce(H).length?{name:"default",fn:ot(()=>[(w(!0),$(ge,null,st(ce(H),ke=>(w(),$(ge,{key:ke.key},[ke.kind==="text"&&ke.text?(w(),$("div",Zj,[be(Wa,{text:ke.text,inverted:!$e.value,streaming:H.id===pe.value,onClick:L[4]||(L[4]=Et(()=>{},["stop"])),onAction:Jr},null,8,["text","inverted","streaming"])])):ke.kind==="attachment"&&ke.attachment.type==="image"?(w(),$("img",{key:1,src:ke.attachment.src,alt:ke.attachment.filename,"data-test":"messaging-attachment","data-attachment-placement":ke.placement,class:"my-2 rounded-xl object-cover max-h-48 max-w-[240px] @sm/chat:max-w-[320px]"},null,8,Hj)):ke.kind==="attachment"&&ke.attachment.type==="audio"?(w(),$("audio",{key:2,src:ke.attachment.src,controls:"","data-test":"messaging-attachment","data-attachment-placement":ke.placement,class:"my-2 max-w-full"},null,8,Kj)):ke.kind==="attachment"?(w(),$("a",{key:3,href:ke.attachment.src,target:"_blank",rel:"noopener","data-test":"messaging-attachment","data-attachment-placement":ke.placement,class:V(["my-2 inline-flex items-center gap-1.5 px-3 py-1.5 rounded-lg text-xs",$e.value?"bg-theme-100 text-theme-600 hover:bg-theme-200":"bg-white/10 text-white/80 hover:bg-white/20"])},[L[21]||(L[21]=b("i",{class:"i-tabler-file size-3.5"},null,-1)),xt(" "+de(ke.attachment.filename),1)],10,Wj)):te("",!0)],64))),128))]),key:"0"}:void 0]),1032,["own","inverted","data-test","data-message-id","data-message-sender","data-conversation-id","data-message-sequence","data-system-kind","data-streaming","data-queued","aria-label","class"])),H.id===z.value?(w(),$(ge,{key:6},[f.value.length?(w(!0),$(ge,{key:0},st(f.value,ke=>(w(),$(ge,{key:ke.id},[ke.kind==="work"?(w(),$("div",{key:0,"data-test":"messaging-tool-activity","data-journal-outcome":ke.journal.outcome,class:"chat-live-enter mb-4 w-full"},[be(sy,{model:ke.journal,"is-light":$e.value},null,8,["model","is-light"])],8,Xj)):ke.kind==="text"&&ke.content?(w(),$("div",{key:1,"data-test":"messaging-live-text-block",class:V(["mb-4",$e.value?"text-theme-900":"text-white/95"])},[be(Wa,{text:ke.content,inverted:!$e.value,streaming:ke.id===h.value,onClick:L[5]||(L[5]=Et(()=>{},["stop"])),onAction:Jr},null,8,["text","inverted","streaming"])],2)):(w(),$("div",{key:2,"data-test":"messaging-tool-activity-tail","aria-label":"Assistant is still working",class:V(["chat-live-enter mb-4 grid h-[17px] w-5 place-items-center",$e.value?"text-theme-500":"text-white/70"])},[...L[24]||(L[24]=[b("span",{class:"chat-dots chat-dots--mini","aria-hidden":"true"},[b("span"),b("span"),b("span")],-1)])],2))],64))),128)):S.value?(w(),$("div",{key:1,"data-test":"messaging-tool-activity","data-journal-outcome":S.value.outcome,class:"chat-live-enter mb-4 w-full"},[be(sy,{model:S.value,"is-light":$e.value},null,8,["model","is-light"])],8,Qj)):te("",!0)],64)):te("",!0)],64))),128)),ue.value?(w(),$("div",{key:1,"data-test":T.value?"messaging-working-state":"messaging-thinking-indicator","data-working-description":T.value,role:"status","aria-live":"polite",class:V(["chat-live-enter relative mb-4 flex h-[17px] items-center gap-2.5 pl-0.5 text-[13.5px] leading-snug",$e.value?"text-theme-500":"text-white/50"])},[L[25]||(L[25]=b("span",{"data-test":"messaging-thinking-dots",class:"chat-dots shrink-0","aria-hidden":"true"},[b("span"),b("span"),b("span")],-1)),T.value?(w(),$("span",tM,de(T.value),1)):(w(),$("span",rM,"Thinking"))],10,eM)):te("",!0),se.value?(w(),$("div",{key:2,"data-test":"messaging-transient-issue","data-issue-code":se.value.code,role:"alert",class:V(["chat-live-enter mb-4 flex items-start gap-2 px-2 text-[13px] leading-snug",$e.value?"text-theme-600":"text-white/60"])},[L[27]||(L[27]=b("i",{class:"i-tabler-alert-circle size-3.5 shrink-0 text-red-500","aria-hidden":"true"},null,-1)),b("span",iM,[b("span",oM,[xt(de(se.value.message),1),se.value.help?(w(),$(ge,{key:0},[xt(":")],64)):te("",!0)]),se.value.help?(w(),$(ge,{key:0},[L[26]||(L[26]=xt(de(" "),-1)),b("span",aM,de(se.value.help),1)],64)):te("",!0)]),se.value.actionUrl&&se.value.actionLabel?(w(),$("a",{key:0,href:se.value.actionUrl,class:"shrink-0 underline underline-offset-2",onClick:L[6]||(L[6]=Et(()=>{},["stop"]))},de(se.value.actionLabel),9,sM)):te("",!0)],10,nM)):te("",!0)],2)]),_:3},8,["inert","aria-hidden","class"]),b("div",{"data-test":"messaging-composer-footer",inert:ye.value,"aria-hidden":ye.value?"true":void 0,class:V(["left-0 right-0 z-30 px-3 @lg/chat:px-8 pb-[max(env(safe-area-inset-bottom),1rem)]",[k.value.length===0||e.centered?"relative shrink-0":"absolute bottom-0",e.centered&&k.value.length>0?"pt-0 sm:pb-9":"pt-3",$e.value?e.centered?"bg-transparent":"bg-theme-0":"bg-gradient-to-t from-black/90 via-black/60 to-transparent"]])},[zt(ee.$slots,"composer",{},()=>[Be.value?(w(),$("div",{key:0,"data-test":"messaging-seat","data-seat-state":Re.value,role:"status","aria-live":"polite",class:V(["py-3 text-center text-[14px]",$e.value?"text-theme-500":"text-white/70"])},de(Be.value),11,cM)):(w(),$(ge,{key:1},[mr.value.length>0?(w(),$("div",{key:0,class:V(["flex items-center gap-2 px-2 pb-2 overflow-x-auto [scrollbar-width:none] [&::-webkit-scrollbar]:hidden",e.centered?"max-w-[640px] @5xl/chat:max-w-[720px] mx-auto":""])},[(w(!0),$(ge,null,st(mr.value,(H,Qe)=>(w(),$("div",{key:Qe,class:"relative shrink-0 group"},[H.type==="image"?(w(),$("img",{key:0,src:H.src,alt:H.filename,class:V(["size-14 rounded-xl object-cover border",$e.value?"border-black/10":"border-white/20"])},null,10,uM)):(w(),$("div",{key:1,class:V(["h-14 px-3 rounded-xl flex items-center gap-1.5 text-xs border",$e.value?"border-black/10 bg-theme-50 text-theme-600":"border-white/20 bg-white/10 text-white/70"])},[L[28]||(L[28]=b("i",{class:"i-tabler-file size-4"},null,-1)),b("span",dM,de(H.filename),1)],2)),b("button",{class:"absolute -top-1.5 -right-1.5 size-5 flex items-center justify-center rounded-full bg-theme-800 text-white text-xs scale-0 group-hover:scale-100 transition-transform duration-200 ease-[cubic-bezier(0.25,1,0.33,1)] cursor-pointer",onClick:ke=>mc(Qe)},[...L[29]||(L[29]=[b("i",{class:"i-tabler-x size-3"},null,-1)])],8,pM)]))),128)),gt.value?(w(),$("div",mM,[be(zp,{class:"size-5"})])):te("",!0)],2)):te("",!0),Tt.value?(w(),$("input",{key:1,ref_key:"fileInput",ref:o,type:"file",accept:"image/*,audio/*,video/*",class:"hidden",onChange:pc},null,544)):te("",!0),be(_U,{ref_key:"composer",ref:r,modelValue:Er.value,"onUpdate:modelValue":L[12]||(L[12]=H=>Er.value=H),placeholder:ft.value,disabled:ct.value,inverted:!$e.value,action:Ht.value,"send-enabled":er.value,"send-label":P.value,"show-send":!St.value&&!Y.value,class:V(e.centered?"mx-auto max-w-[640px] @5xl/chat:max-w-[740px] @5xl/chat:px-5 @5xl/chat:pt-3.5 @5xl/chat:pb-3":""),onSubmit:L[13]||(L[13]=H=>xo()),onAction:L[14]||(L[14]=H=>ni())},Pa({leading:ot(()=>[b("button",{class:V(["-ml-2 flex size-8 items-center justify-center transition-opacity hover:opacity-70 pointer-coarse:size-11",[Tt.value?"cursor-pointer":"cursor-default",$e.value?"text-theme-500":"text-white/50",gt.value||Wr.value?"opacity-50 pointer-events-none":""]]),disabled:ct.value||gt.value||Wr.value||!Tt.value,"aria-label":Tt.value?"Attach file":"File attachments unavailable",title:Tt.value?"Attach file":"File attachments unavailable",onClick:L[7]||(L[7]=H=>Tt.value&&On())},[gt.value?(w(),$("i",gM)):(w(),$("i",vM)),b("span",bM,de(Tt.value?"Attach file":"File attachments unavailable"),1)],10,hM)]),actions:ot(()=>[Y.value&&!ie.value&&!ye.value?(w(),$("button",{key:0,"data-test":"messaging-record-discard-btn",class:V(["flex size-8 cursor-pointer items-center justify-center transition-opacity hover:opacity-70 pointer-coarse:size-11",$e.value?"text-theme-400":"text-white/40"]),"aria-label":"Discard recording",title:"Discard recording",onClick:L[8]||(L[8]=H=>ii({cancelled:!0}))},[...L[31]||(L[31]=[b("i",{class:"i-tabler-x size-[18px]","aria-hidden":"true"},null,-1)])],2)):te("",!0),(E.value||Y.value)&&!ie.value&&!ye.value?(w(),$("button",{key:1,"data-test":"messaging-record-audio-btn",class:V(["flex size-8 cursor-pointer items-center justify-center transition-[opacity,transform] duration-200 ease-[cubic-bezier(0.25,1,0.33,1)] hover:opacity-70 pointer-coarse:size-11",Y.value?$e.value?"text-theme-900 scale-110":"text-white scale-110":$e.value?"text-theme-500":"text-white/60"]),"aria-label":we.value,title:we.value,onPointerdown:Et(_o,["prevent"]),onPointerup:Et(Ur,["prevent"]),onPointercancel:Et(oi,["prevent"]),onClick:os,onKeydown:L[9]||(L[9]=Gn(Et(H=>ii({cancelled:!0}),["prevent"]),["escape"]))},[b("i",{class:V([Y.value?"i-tabler-microphone-filled":"i-tabler-microphone","size-[18px]"])},null,2),b("span",wM,de(we.value),1)],42,yM)):te("",!0),St.value?(w(),$("button",{key:2,"data-test":"messaging-voice-start-btn",class:V(["flex size-8 items-center justify-center rounded-full transition-colors duration-150 pointer-coarse:size-11",[$e.value?"bg-theme-900 text-theme-0 hover:bg-theme-800":"bg-theme-0 text-theme-950 hover:bg-theme-100",Kt.value?"cursor-not-allowed opacity-40":"cursor-pointer"]]),disabled:Kt.value,"aria-label":vt.value,title:vt.value,onClick:L[10]||(L[10]=H=>Nt())},[b("span",xM,[(w(),$(ge,null,st([7,13,16,11,14],H=>b("span",{key:H,class:"w-[2px] rounded-full bg-current",style:Se({height:`${H}px`})},null,4)),64))]),L[32]||(L[32]=b("span",{class:"sr-only"},"Start voice conversation",-1))],10,kM)):te("",!0),Tr.value&&!St.value&&!Y.value?(w(),$("button",{key:3,"data-test":"messaging-secondary-stop-btn",class:V(["mr-2 flex size-8 cursor-pointer items-center justify-center rounded-full transition-colors duration-150 pointer-coarse:size-11",$e.value?"bg-theme-100 text-theme-700 hover:bg-theme-200":"bg-white/10 text-white/70 hover:bg-white/15"]),"aria-label":"Stop work",title:"Stop work",onClick:L[11]||(L[11]=H=>e.chatController?.stopChatTurn())},[...L[33]||(L[33]=[b("i",{class:"i-tabler-player-stop-filled size-3.5","aria-hidden":"true"},null,-1),b("span",{class:"sr-only"},"Stop work",-1)])],2)):te("",!0)]),_:2},[Y.value?{name:"input",fn:ot(()=>[b("div",{"data-test":"messaging-recording-state",class:V(["flex min-w-0 items-center gap-2 py-1",$e.value?"text-theme-700":"text-white/80"])},[L[30]||(L[30]=b("span",{class:"size-2.5 shrink-0 rounded-full bg-red-500"},null,-1)),b("span",fM,de(fe.value),1),b("span",{class:V(["min-w-0 truncate text-sm",$e.value?"text-theme-400":"text-white/45"])},de(ve.value),3)],2)]),key:"0"}:void 0]),1032,["modelValue","placeholder","disabled","inverted","action","send-enabled","send-label","show-send","class"]),e.centered&&k.value.length>0?(w(),$("p",_M,de(e.bot.displayName.value)+" is AI and can make mistakes. ",1)):te("",!0)],64))],!0)],10,lM),_.value?(w(),Fe(GU,{key:4,message:D.value,prompt:y.value,share:_.value,onClose:L[15]||(L[15]=H=>D.value=void 0)},null,8,["message","prompt","share"])):te("",!0)],2))}}),[["__scopeId","data-v-4b8f5776"]]),$M={class:"bot-wrap"},SM={key:0,class:"flex items-center justify-center h-full"},IM={key:2,class:"flex h-full flex-col items-center justify-center gap-4 px-6 text-center",role:"status","aria-live":"polite","data-test":"bot-unavailable"},Vp=Pe({__name:"BotWrap",props:{sdk:{},bot:{},handle:{},context:{},clientContext:{},firstMessage:{},buttonText:{},buttonIcon:{},hasClose:{type:Boolean},chatOnly:{type:Boolean},bare:{type:Boolean},apiBase:{}},setup(e){let t=co("BotWrap"),n=e,i=n.sdk||Yl.getInstance({isDev:typeof window<"u"?window.location.hostname==="localhost"||window.location.hostname.includes("127.0.0.1"):!1,...n.apiBase&&{apiBase:n.apiBase}}),r=We(!n.bot),o=We(n.bot),a=We();async function s(){if(n.bot)t.debug("Bot provided via props, skipping fetch",{botId:n.bot.botId.value,handle:n.bot.handle.value}),r.value=!1;else if(!n.handle)a.value="No handle or bot provided",t.warn("BotWrap mounted without handle or bot",{propsReceived:{handle:n.handle,bot:n.bot,context:n.clientContext??n.context,apiBase:n.apiBase},sdkState:{isDev:i.isDev,apiBase:i.apiBase}}),r.value=!1;else try{r.value=!0,a.value=void 0,t.debug("Fetching public bot",{handle:n.handle});let l=await i.user.getPublicBot({handle:n.handle});l?(o.value=l,t.debug("Successfully fetched public bot",{botId:l.botId.value,handle:l.handle.value}),l.botId.value&&i.user.track({event:"view_profile",botId:l.botId.value,properties:{viewSource:"widget"}})):(a.value=i.error.value||"Bot not found",t.error("Failed to fetch public bot - no data returned",{handle:n.handle,sdkError:i.error.value,sdkState:{isDev:i.isDev,apiBase:i.apiBase,loading:i.loading.value}}))}catch(l){a.value=l instanceof Error?l.message:"Failed to fetch bot",t.error("Exception while fetching public bot",{handle:n.handle,error:l instanceof Error?{message:l.message,stack:l.stack}:l,sdkState:{isDev:i.isDev,apiBase:i.apiBase,error:i.error.value}})}finally{r.value=!1,o.value||t.debug("BotWrap component will render unavailable state",{state:{loading:r.value,hasBot:!!o.value,error:a.value},props:{handle:n.handle,context:n.clientContext??n.context,apiBase:n.apiBase},sdkState:{isDev:i.isDev,apiBase:i.apiBase,error:i.error.value}})}}return Ut(s),(l,u)=>(w(),$("div",$M,[r.value?(w(),$("div",SM,[b("div",{class:V(["size-6 animate-spin rounded-full border-b-2",n.bare?"border-theme-400":"border-white"])},null,2)])):o.value?zt(l.$slots,"default",{sdk:Ae(i),bot:o.value,context:e.clientContext??e.context,firstMessage:e.firstMessage,buttonText:e.buttonText,buttonIcon:e.buttonIcon,loading:r.value},void 0,void 0,1):a.value?(w(),$("div",IM,[u[0]||(u[0]=b("p",{class:"text-sm font-medium text-theme-600"}," This assistant is unavailable right now. ",-1)),b("button",{type:"button",class:"min-h-11 rounded-full bg-theme-900 px-5 text-sm font-semibold text-theme-0 transition-colors hover:bg-theme-700","data-test":"bot-unavailable-retry",onClick:s}," Try again ")])):te("",!0)]))}})});function es(e){let t=We(e.bot),n=Q(e.context),i=Q(e.firstMessage),r=Q(e.buttonText),o=Q(e.buttonIcon);function a(s){s.bot!==void 0&&(t.value=s.bot),s.context!==void 0&&(n.value=s.context),s.firstMessage!==void 0&&(i.value=s.firstMessage),s.buttonText!==void 0&&(r.value=s.buttonText),s.buttonIcon!==void 0&&(o.value=s.buttonIcon)}return{currentBot:t,currentContext:n,currentFirstMessage:i,currentButtonText:r,currentButtonIcon:o,update:a}}var Bp=re(()=>{"use strict";Pn();En()});var wo,DE=re(()=>{"use strict";Pn();wo={linkedin:{label:"LinkedIn",icon:"i-simple-icons-linkedin",placeholder:"john-smith",getUrl:e=>`https://linkedin.com/in/${e}`},x:{label:"X",icon:"i-simple-icons-x",placeholder:"johnsmith",getUrl:e=>`https://x.com/${e}`},facebook:{label:"Facebook",icon:"i-simple-icons-facebook",placeholder:"johnsmith",getUrl:e=>`https://facebook.com/${e}`},tiktok:{label:"TikTok",icon:"i-simple-icons-tiktok",placeholder:"johnsmith",getUrl:e=>`https://tiktok.com/@${e}`},youtube:{label:"YouTube",icon:"i-tabler-brand-youtube",placeholder:"johnsmith",getUrl:e=>`https://youtube.com/@${e}`},github:{label:"GitHub",icon:"i-tabler-brand-github",placeholder:"johnsmith",getUrl:e=>`https://github.com/${e}`},instagram:{label:"Instagram",icon:"i-simple-icons-instagram",placeholder:"johnsmith",getUrl:e=>`https://instagram.com/${e}`},threads:{label:"Threads",icon:"i-simple-icons-threads",placeholder:"johnsmith",getUrl:e=>`https://threads.net/@${e}`},email:{label:"Email",icon:"i-tabler-mail",placeholder:"hello@example.com",getUrl:e=>`mailto:${e}`},phone:{label:"Phone",icon:"i-tabler-phone",placeholder:"+1-555-123-4567",getUrl:e=>`tel:${e.replace(/[^0-9+]/g,"")}`},website:{label:"Website",icon:"i-tabler-world",placeholder:"https://example.com",getUrl:e=>e},calendar:{label:"Calendar",icon:"i-tabler-calendar",placeholder:"https://cal.com/username",getUrl:e=>e}}});var RE,EM,TM,NM,CM,zM,AM,OM,DM,PE,PM,RM,UM,jM,MM,LM,VM,FM,BM,ZM,HM,KM,WM,qM,GM,JM,YM,XM,QM,eL,tL,rL,nL,iL,oL,aL,sL,lL,cL,uL,UE,dL,pL,mL,fL,hL,gL,vL,bL,yL,wL,kL,xL,_L,$L,SL,IL,EL,TL,NL,CL,zL,AL,OL,Zp,My=re(()=>{"use strict";Pn();DE();Fp();ql();En();RE=[{mode:"self",label:"Overview",icon:"i-tabler-user-square-rounded"},{mode:"talk",label:"Talk",icon:"i-tabler-phone"},{mode:"chat",label:"Chat",icon:"i-tabler-message-circle"},{mode:"info",label:"About",icon:"i-tabler-user-circle"}],EM=Pe({__name:"EffectTransitionList",props:{disabled:{type:Boolean,default:!1},mode:{default:"block"}},setup(e){return(t,n)=>(w(),Fe(H0,{name:e.disabled?"":"nlist"},{default:ot(()=>[zt(t.$slots,"default")]),_:3},8,["name"]))}}),TM=["data-test-mode"],NM={class:"w-full max-w-xs space-y-12"},CM={key:0,class:"text-xs text-theme-400 text-center"},zM={class:"text-base font-light text-white text-center"},AM={class:"space-y-6 relative"},OM={key:"email-field",class:"w-full"},DM={key:"code-field",class:"w-full"},PE=Pe({__name:"ElAuthGate",props:{sdk:{}},setup(e){let t=Q({email:"",code:""}),n=Q("email"),i=Q(!1),r={email:{title:"Enter Your Email",button:{label:"Continue",disabled:()=>!t.value.email||i.value},action:async()=>{if(!i.value){i.value=!0;try{await e.sdk.auth.requestAuthCode({email:t.value.email})&&(n.value="code")}finally{i.value=!1}}}},code:{title:"Enter Verification Code",button:{label:"Verify",disabled:()=>t.value.code.length!==6||i.value},action:async()=>{if(!i.value){i.value=!0;try{await e.sdk.auth.loginWithCode({email:t.value.email,code:t.value.code})}finally{i.value=!1}}}}},o=R(()=>r[n.value]);return mt(()=>e.sdk.activeUser.value,a=>{a&&n.value==="code"&&console.log("[ElAuthGate] Authentication successful",{email:a.email})}),(a,s)=>(w(),$("div",{"data-test":"auth-form","data-test-mode":n.value,class:"flex flex-col items-center justify-center h-full p-6"},[b("div",NM,[e.sdk.error.value?(w(),$("p",CM,de(e.sdk.error.value),1)):te("",!0),b("h3",zM,de(o.value.title),1),b("div",AM,[be(EM,null,{default:ot(()=>[n.value==="email"?(w(),$("div",OM,[be(jp,{modelValue:t.value.email,"onUpdate:modelValue":s[0]||(s[0]=l=>t.value.email=l),"data-test":"auth-email-input",onKeyup:Gn(o.value.action,["enter"])},null,8,["modelValue","onKeyup"])])):(w(),$("div",DM,[be(Mp,{modelValue:t.value.code,"onUpdate:modelValue":s[1]||(s[1]=l=>t.value.code=l),length:6,"focus-first":!0,"data-test":"auth-code-input",onAutoSubmit:o.value.action},null,8,["modelValue","onAutoSubmit"])])),(w(),$("div",{key:o.value.button.label,class:"space-y-4 w-full"},[be(Xa,{theme:"primary",size:"md",class:"w-full","data-test":"auth-submit",loading:e.sdk.loading.value,disabled:o.value.button.disabled()||e.sdk.loading.value,onClick:o.value.action},{default:ot(()=>[xt(de(o.value.button.label),1)]),_:1},8,["loading","disabled","onClick"]),n.value==="code"?(w(),$("button",{key:0,class:"w-full text-xs text-white/50 hover:text-white/70 transition-colors py-2",onClick:s[2]||(s[2]=l=>n.value="email")}," Change Email ")):te("",!0)]))]),_:1})])])],8,TM))}}),PM={class:"flex-1 flex flex-col min-h-0 py-6 space-y-6 h-full overflow-scroll [scrollbar-width:none] [-ms-overflow-style:none] [&::-webkit-scrollbar]:hidden relative"},RM={class:"flex-1 space-y-6 pb-12"},UM={key:0,class:"text-sm bg-white/10 backdrop-blur-sm rounded-2xl p-4 border border-white/20 space-y-3"},jM={class:"text-white/70 leading-relaxed whitespace-pre-wrap"},MM={key:1,class:"space-y-3"},LM=["href"],VM={key:2,class:"space-y-3"},FM={class:"grid grid-cols-2 gap-3"},BM=["href"],ZM=Pe({__name:"ElBotAbout",props:{bot:{},isOnline:{type:Boolean,default:!1}},setup(e){return(t,n)=>(w(),$("div",PM,[be(Lp,{bot:e.bot,"is-online":e.isOnline},null,8,["bot","is-online"]),b("div",RM,[e.bot.summary.value?(w(),$("div",UM,[n[0]||(n[0]=b("h3",{class:"font-medium text-white/50"}," About ",-1)),b("p",jM,de(e.bot.summary.value),1)])):te("",!0),e.bot.email.value?(w(),$("div",MM,[n[2]||(n[2]=b("h3",{class:"text-sm font-medium text-white/90"}," Contact ",-1)),b("a",{href:`mailto:${e.bot.email.value}`,target:"_blank",rel:"noopener noreferrer",class:"relative inline-flex items-center justify-center gap-2 rounded-full px-4 py-2 font-medium transition-colors duration-200 focus:outline-none active:opacity-80 cursor-pointer bg-white/5 hover:bg-white/10 border border-white/10 text-white/80 text-sm justify-start h-10 w-full"},[...n[1]||(n[1]=[b("span",{class:"i-heroicons-envelope flex items-center size-[1.1em] mt-[-.07em]"},null,-1),xt(" Email ",-1)])],8,LM)])):te("",!0),e.bot.accounts.value&&e.bot.accounts.value.length>0?(w(),$("div",VM,[n[3]||(n[3]=b("h3",{class:"text-sm font-medium text-white/90"}," Links ",-1)),b("div",FM,[(w(!0),$(ge,null,st(e.bot.accounts.value,i=>(w(),$("a",{key:`${i.platform}-${i.handle}`,href:Ae(wo)[i.platform].getUrl(i.handle),target:"_blank",rel:"noopener noreferrer",class:"relative inline-flex items-center justify-center gap-2 rounded-full px-4 py-2 font-medium transition-colors duration-200 focus:outline-none active:opacity-80 cursor-pointer bg-white/10 hover:bg-white/20 border border-white/20 text-white/80 text-sm"},[b("span",{class:V(["flex items-center size-[1.1em] mt-[-.07em]",Ae(wo)[i.platform].icon])},null,2),xt(" "+de(Ae(wo)[i.platform].label),1)],8,BM))),128))])])):te("",!0)])]))}}),HM={class:"flex flex-col items-center text-center gap-4"},KM={class:"relative flex-shrink-0"},WM={class:"w-20 h-20 sm:w-24 sm:h-24 rounded-full overflow-hidden border-4 border-white"},qM=["src","alt"],GM={class:"absolute top-1.5 right-1.5"},JM={key:1,class:"size-4 bg-theme-400 rounded-full ring-2 ring-white"},YM={class:"min-w-0"},XM={class:"text-3xl font-light text-white mb-2 truncate"},QM={class:"text-base font-light text-white/60 line-clamp-1"},eL=Pe({__name:"ElBotHeader",props:{bot:{},isOnline:{type:Boolean,default:!1}},setup(e){return(t,n)=>(w(),$("div",HM,[b("div",KM,[b("div",WM,[b("img",{src:e.bot.avatarUrl.value,alt:e.bot.displayName.value,class:"w-full h-full object-cover",onError:n[0]||(n[0]=(...i)=>Ae(ac)&&Ae(ac)(...i))},null,40,qM)]),b("div",GM,[e.isOnline?(w(),$(ge,{key:0},[n[1]||(n[1]=b("div",{class:"size-4 bg-green-500 rounded-full ring-2 ring-white absolute animate-ping",style:{"animation-duration":"3s"}},null,-1)),n[2]||(n[2]=b("div",{class:"size-4 bg-green-500 rounded-full ring-2 ring-white"},null,-1))],64)):(w(),$("div",JM))])]),b("div",YM,[b("h1",XM,de(e.bot.displayName.value),1),b("p",QM,de(e.bot.title.value),1)])]))}}),tL={class:"absolute top-1/2 left-1/2 -translate-x-1/2 -translate-y-1/2 w-[28px] h-[28px] overflow-hidden"},rL=Pe({name:"SelfSidebarClose",__name:"BotSidebarClose",emits:["click"],setup(e){let t=Q(!1);return Ut(()=>{setTimeout(()=>{t.value=!0},100)}),(n,i)=>(w(),$("a",{class:"close block cursor-pointer w-[60px] h-[60px] rounded-full transition-all duration-1000 ease-[cubic-bezier(0.25,1,0.33,1)] hover:scale-110 active:scale-90 hover:rotate-90",onClick:i[0]||(i[0]=r=>n.$emit("click",r))},[i[1]||(i[1]=b("span",{class:"absolute inset-0 rounded-full transition-all"},null,-1)),b("span",tL,[b("span",{class:V(["absolute h-full w-[3px] rounded-[5px] left-[13px] transition-all duration-[400ms] ease-[cubic-bezier(0.52,0.01,0.16,1)]",t.value?"translate-y-0 translate-x-0 rotate-45":"translate-y-[30px] -translate-x-[30px] rotate-0"]),style:{"background-color":"currentColor","transition-delay":"0.15s"}},null,2),b("span",{class:V(["absolute h-full w-[3px] rounded-[5px] left-[13px] transition-all duration-[400ms] ease-[cubic-bezier(0.52,0.01,0.16,1)]",t.value?"translate-y-0 translate-x-0 -rotate-45":"-translate-y-[30px] -translate-x-[30px] rotate-0"]),style:{"background-color":"currentColor","transition-delay":"0.45s"}},null,2)])]))}}),nL={key:0,class:"px-9 pt-12 pb-4"},iL={class:"text-base font-medium text-theme-400"},oL={key:1,class:"px-4 pb-8 border-b border-white/10"},aL=["disabled","onClick"],sL={class:"flex items-center gap-3"},lL={class:"flex-1"},cL={key:0,class:"text-xs text-white/50 mt-0.5"},uL={class:"p-6"},UE=Pe({name:"ElSidebar",inheritAttrs:!1,__name:"ElSidebar",props:{modelValue:{type:Boolean},items:{},position:{},title:{},widthClasses:{}},emits:["update:modelValue"],setup(e,{emit:t}){let n=e,i=t,r=n.position||"left",o=n.widthClasses||"w-[80%] max-w-[300px]",a=R({get:()=>n.modelValue,set:d=>i("update:modelValue",d)}),s=R(()=>n.items.filter(d=>!d.isHidden));function l(d){d.isDisabled||(d.onClick?d.onClick({item:d,event:new MouseEvent("click")}):d.href&&(d.href.includes("http")?window.open(d.href,d.target||"_self")?.focus():window.location.href=d.href),a.value=!1)}let u=R(()=>r==="left"?{enter:"-translate-x-full",leave:"-translate-x-full",position:"justify-start",closeButton:"-right-16"}:{enter:"translate-x-full",leave:"translate-x-full",position:"justify-end",closeButton:"-left-16"});return(d,p)=>(w(),$(ge,null,[be(so,{"enter-active-class":"transition-opacity duration-300 ease-out","leave-active-class":"transition-opacity duration-200 ease-in","enter-from-class":"opacity-0","enter-to-class":"opacity-100","leave-from-class":"opacity-100","leave-to-class":"opacity-0"},{default:ot(()=>[a.value?(w(),$("div",{key:0,class:"absolute inset-0 z-40 bg-black/50 backdrop-blur-sm",onClick:p[0]||(p[0]=m=>a.value=!1)})):te("",!0)]),_:1}),be(so,{"enter-active-class":"transition-all duration-500 ease-[cubic-bezier(0.25,1,0.33,1)]","leave-active-class":"transition-all duration-400 ease-[cubic-bezier(0.25,1,0.33,1)]","enter-from-class":u.value.enter,"enter-to-class":"translate-x-0","leave-from-class":"translate-x-0","leave-to-class":u.value.leave},{default:ot(()=>[a.value?(w(),$("div",{key:0,class:V(["absolute inset-0 z-50 flex",u.value.position]),onClick:p[3]||(p[3]=m=>a.value=!1)},[b("div",{class:V(["relative h-full shadow-2xl bg-black/30 backdrop-blur-xl flex flex-col justify-center",Ae(o)]),onClick:p[2]||(p[2]=Et(()=>{},["stop"]))},[be(rL,{class:V(["absolute top-4 z-10 text-white",u.value.closeButton]),onClick:p[1]||(p[1]=m=>a.value=!1)},null,8,["class"]),e.title?(w(),$("div",nL,[b("h3",iL,de(e.title),1)])):te("",!0),d.$slots.header?(w(),$("div",oL,[zt(d.$slots,"header")])):te("",!0),b("div",{class:V(["flex-1 p-6 space-y-2 overflow-y-auto",{"pt-6":!e.title&&!d.$slots.header,"pt-4":e.title||d.$slots.header}])},[be(H0,{"enter-active-class":"transition-all duration-400 ease-[cubic-bezier(0.25,1,0.33,1)]","leave-active-class":"transition-all duration-200 ease-[cubic-bezier(0.25,1,0.33,1)]","enter-from-class":Ae(r)==="left"?"-translate-x-4 opacity-0":"translate-x-4 opacity-0","enter-to-class":"translate-x-0 opacity-100","leave-from-class":"translate-x-0 opacity-100","leave-to-class":Ae(r)==="left"?"-translate-x-4 opacity-0":"translate-x-4 opacity-0"},{default:ot(()=>[(w(!0),$(ge,null,st(s.value,(m,f)=>(w(),$("button",{key:m.key||m.label||f,style:Se({transitionDelay:`${f*40}ms`}),class:V(["cursor-pointer w-full text-left p-3 rounded-xl transition-all duration-200 ease-[cubic-bezier(0.25,1,0.33,1)] group",[m.isActive?"bg-primary-500/20 border border-primary-500/40":"hover:bg-white/10",m.isDisabled&&"opacity-50 cursor-not-allowed"]]),disabled:m.isDisabled,onClick:h=>l(m)},[b("div",sL,[m.icon?.src?(w(),$("i",{key:0,class:V(["size-5 flex-shrink-0 transition-transform duration-200 ease-[cubic-bezier(0.25,1,0.33,1)] group-hover:scale-110",[m.icon.src,m.isActive?"text-primary-400":"text-white/70 group-hover:text-white"]])},null,2)):te("",!0),b("div",lL,[b("div",{class:V(["font-medium text-sm",m.isActive?"text-primary-300":"text-white"])},de(m.label),3),m.subLabel?(w(),$("div",cL,de(m.subLabel),1)):te("",!0)])])],14,aL))),128))]),_:1},8,["enter-from-class","leave-to-class"])],2),b("div",uL,[zt(d.$slots,"footer")])],2)],2)):te("",!0)]),_:3},8,["enter-from-class","leave-to-class"])],64))}}),dL=Pe({name:"BotModeSidebar",__name:"ElBotModeSidebar",props:{modelValue:{type:Boolean},chatController:{}},emits:["update:modelValue"],setup(e,{emit:t}){let n=e,i=t,r=R({get:()=>n.modelValue,set:s=>i("update:modelValue",s)}),o=R(()=>n.chatController?.botMode?.value??"self"),a=R(()=>RE.map(s=>({key:s.mode,icon:{src:s.icon},label:s.label,isActive:o.value===s.mode,onClick:()=>{n.chatController?.setMode(s.mode)}})));return(s,l)=>(w(),Fe(UE,{modelValue:r.value,"onUpdate:modelValue":l[0]||(l[0]=u=>r.value=u),items:a.value,position:"right",title:"Mode","width-classes":"w-[80%] max-w-[255px]"},null,8,["modelValue","items"]))}}),pL=Pe({name:"BotSidebar",__name:"ElBotSidebar",props:{modelValue:{type:Boolean},bot:{},sdk:{},title:{}},emits:["update:modelValue"],setup(e,{emit:t}){let n=e,i=t,r=R({get:()=>n.modelValue,set:a=>i("update:modelValue",a)}),o=R(()=>{let a=[{key:"share",icon:{src:"i-tabler-share"},label:"Share this assistant",onClick:()=>{let s=`${window.location.origin}/@${n.bot.handle.value||n.bot.botId.value}`;navigator.clipboard.writeText(s).catch(l=>{console.error("ElBotSidebar: clipboard.writeText rejected",l)})}},{key:"profile",icon:{src:"i-tabler-user"},label:"View full profile",onClick:()=>{window.open(`/@${n.bot.handle.value||n.bot.botId.value}`,"_blank")}},{key:"create",icon:{src:"i-tabler-sparkles"},label:"Create your own",onClick:()=>{window.open("/auth","_blank")}}];return n.sdk.activeUser.value&&a.push({key:"logout",icon:{src:"i-tabler-logout"},label:"Logout",onClick:async()=>{await n.sdk.auth.logout()}}),a});return(a,s)=>(w(),Fe(UE,{modelValue:r.value,"onUpdate:modelValue":s[0]||(s[0]=l=>r.value=l),items:o.value,position:"left",title:e.title||"Menu"},null,8,["modelValue","items","title"]))}}),mL={key:0,class:"absolute inset-0 flex items-center justify-center bg-gradient-to-br from-theme-800 to-theme-950 rounded-3xl z-10"},fL=["data-quality"],hL={key:0,class:"flex flex-1 items-center gap-3 pl-2"},gL=["src","alt"],vL={class:"text-sm font-medium text-white/90"},bL={key:1,class:"flex justify-end"},yL={class:"text-sm"},wL={key:0,class:"flex-1 basis-0 flex justify-end"},kL={key:0,class:"h-full pb-12 flex-1 flex flex-col relative z-20 min-h-0 px-4 @[480px]/bot:px-6 max-w-md mx-auto w-full"},xL={class:"flex-1 basis-0 flex flex-col justify-start pt-8 gap-7"},_L={key:0,class:"flex items-center justify-center gap-3"},$L=["href"],SL={key:1,class:"flex-1 flex flex-col relative z-20 min-h-0 w-full gap-4 px-4"},IL={class:"max-w-md mx-auto"},EL={key:2,class:"flex-1 flex flex-col relative z-20 min-h-0 w-full px-4 @[480px]/bot:px-6"},TL={class:"flex-1 min-h-0 max-w-md mx-auto w-full"},NL={key:2,class:"bg-gradient-to-br from-theme-800 to-theme-950 text-white flex items-center justify-center h-full p-8"},CL={class:"text-center max-w-md space-y-4"},zL={class:"text-sm text-white/70 leading-relaxed"},AL={key:3,class:"bg-white/10 backdrop-blur-sm text-white/70 flex items-center justify-center h-full"},OL=Pe({__name:"BotChat",props:{sdk:{},bot:{},context:{},firstMessage:{},buttonText:{},buttonIcon:{},hasClose:{type:Boolean,default:!1},isActive:{type:Boolean,default:!0},loading:{type:Boolean,default:!1},theme:{default:"green"},requireAuth:{type:Boolean,default:!1},chatOnly:{type:Boolean,default:!1},bare:{type:Boolean,default:!1},emptyStateMessage:{},createVoiceClientFn:{type:Function}},emits:["close","error","turnStarted","turnCompleted"],setup(e,{emit:t}){let n=t,i=We(),r=Q(!1),o=Q(!1),a=Q(),s=Q(),l=R(()=>i.value?.botMode?.value??"self"),u=R(()=>i.value?.textState.value.isConnected??!1),d=R(()=>e.sdk.activeUser.value!==void 0),p=R(()=>RE.find(z=>z.mode===l.value));function m(){i.value&&i.value.destroy();try{i.value=new sc({sdk:e.sdk,bot:e.bot,context:e.context,firstMessage:e.firstMessage,...e.createVoiceClientFn?{createVoiceClientFn:e.createVoiceClientFn}:{},onTurnStarted:()=>n("turnStarted"),onTurnCompleted:z=>n("turnCompleted",z)})}catch(z){throw console.error("BotChatController creation failed:",z),z}}try{m()}catch(z){let j=z instanceof Error?z.message:"Couldn't initialize your assistant";a.value=j,n("error",j)}function f(z){if(!s.value)return;let j=F2(z);Object.entries(j).forEach(([O,U])=>{s.value.style.setProperty(`--primary-${O}`,U)})}Ut(()=>{try{f(e.theme),e.chatOnly&&i.value&&i.value.setMode("chat")}catch(z){let j=z instanceof Error?z.message:"Couldn't initialize your assistant";a.value=j,n("error",j)}}),Wn(()=>{i.value&&i.value.destroy()}),mt(()=>e.theme,z=>{f(z)}),mt(()=>e.sdk.activeUser.value,(z,j)=>{j&&!z&&i.value&&i.value.setMode("self")});let h=R(()=>!!(e.bot.cover.value?.src&&e.bot.cover.value?.quality==="low")||!!(e.bot.avatar.value?.src&&e.bot.avatar.value?.quality==="low")),v=R(()=>{let z=[h.value?"backdrop-blur-sm":""];return h.value&&l.value==="self"?z.push("from-black/80 via-black/60 to-black/80"):l.value==="self"?z.push("from-black/70 via-black/50 to-black/80"):z.push("from-black/90 via-black/90 to-black/100"),z.join(" ")}),k={phone:"i-heroicons-phone",calendar:"i-heroicons-calendar",question:"i-heroicons-question-mark-circle",message:"i-heroicons-chat-bubble-left-right",sparkles:"i-heroicons-sparkles"},T=R(()=>pE({template:e.buttonText||"Talk to {name}",bot:e.bot.toData()})),S=R(()=>k[e.buttonIcon||"phone"]||k.phone);return(z,j)=>(w(),$("div",{ref_key:"rootElement",ref:s,key:e.bot.avatarUrl.value,class:"pagelines-sdk @container/bot pagelines-bot w-full h-full overflow-hidden relative","data-test":"bot-chat"},[e.loading?(w(),$("div",mL,[be(zp,{class:"text-white size-8"})])):e.bot&&!a.value?(w(),$("div",{key:1,class:V(["absolute inset-0",e.bare?"":"bg-cover bg-center bg-no-repeat"]),style:Se(e.bare?void 0:{backgroundImage:`url(${e.bot.avatarUrl.value})`}),"data-quality":e.bot.avatar.value?.quality||"none"},[e.bare?te("",!0):(w(),$("div",{key:0,class:V(["absolute inset-0 bg-gradient-to-br z-0",v.value])},null,2)),b("div",{class:V(["relative z-10 flex flex-col h-full transition-all duration-500 ease-[cubic-bezier(0.25,1,0.33,1)] will-change-transform",e.isActive?"opacity-100 translate-y-0":"opacity-0 translate-y-2"])},[!e.bare||e.hasClose?(w(),$("div",{key:0,class:V(["relative z-30 p-2",!e.bare&&l.value!=="self"?"backdrop-blur-lg":""])},[e.chatOnly?(w(),$("div",{key:0,class:V(["flex items-center",e.bare?"justify-end":""])},[e.bare?te("",!0):(w(),$("div",hL,[b("img",{src:e.bot.avatarUrl.value,alt:e.bot.displayName.value,class:"size-8 rounded-full object-cover"},null,8,gL),b("span",vL,de(e.bot.displayName.value),1)])),e.hasClose?(w(),$("div",bL,[b("button",{class:V(["flex cursor-pointer items-center rounded-2xl p-3 transition-colors",e.bare?"text-theme-500 hover:bg-theme-50":"text-white/70 hover:bg-white/10"]),onClick:j[0]||(j[0]=Et(O=>n("close","button"),["stop"]))},[...j[7]||(j[7]=[b("i",{class:"size-6 i-tabler-x"},null,-1)])],2)])):te("",!0)],2)):(w(),$("div",{key:1,class:V(["flex items-center",e.hasClose?"":"justify-between"])},[b("div",{class:V(e.hasClose?"flex-1 basis-0":"")},[b("button",{class:"cursor-pointer p-2 flex items-center gap-2 rounded-2xl text-white/70 hover:bg-white/10 transition-all duration-300 ease-[cubic-bezier(0.25,1,0.33,1)] hover:scale-105 active:scale-95",onClick:j[1]||(j[1]=O=>r.value=!0)},[...j[8]||(j[8]=[b("i",{class:"i-tabler-menu size-7"},null,-1)])])],2),b("button",{class:V(["flex items-center gap-2 px-3.5 py-3 rounded-2xl text-white/90 hover:bg-white/10 transition-all cursor-pointer flex-grow-0",{"bg-white/10":o.value}]),onClick:j[2]||(j[2]=O=>o.value=!0)},[b("i",{class:V([p.value?.icon,"size-4 opacity-60"])},null,2),b("span",yL,de(p.value?.label),1),j[9]||(j[9]=b("i",{class:"i-tabler-chevron-down size-4"},null,-1))],2),e.hasClose?(w(),$("div",wL,[b("button",{class:"cursor-pointer flex items-center p-3 rounded-2xl text-white/70 hover:bg-white/10 transition-colors",onClick:j[3]||(j[3]=Et(O=>n("close","button"),["stop"]))},[...j[10]||(j[10]=[b("i",{class:"size-6 i-tabler-x"},null,-1)])])])):te("",!0)],2))],2)):te("",!0),e.chatOnly?(w(),$("div",{key:1,class:V(["relative z-20 flex min-h-0 w-full flex-1 flex-col",e.bare?"":"px-4"])},[b("div",{class:V(["min-h-0 w-full flex-1",e.bare?"":"mx-auto max-w-md"])},[be(yo,{"chat-controller":i.value,bot:e.bot,scope:d.value?"private":"public","empty-state-message":e.emptyStateMessage,variant:e.bare?"light":"dark","show-header":!e.bare,centered:e.bare},Pa({_:2},[z.$slots["empty-heading"]?{name:"empty-heading",fn:ot(O=>[zt(z.$slots,"empty-heading",xa(Ra(O)))]),key:"0"}:void 0]),1032,["chat-controller","bot","scope","empty-state-message","variant","show-header","centered"])],2)],2)):(w(),$(ge,{key:2},[l.value==="self"?(w(),$("div",kL,[j[11]||(j[11]=b("div",{class:"flex-1 basis-0 mb-12"},null,-1)),be(eL,{bot:e.bot,"is-online":u.value},null,8,["bot","is-online"]),b("div",xL,[be(Xa,{theme:"primary",size:"lg",class:"w-full",icon:S.value,"data-test":"voice-button",onClick:j[4]||(j[4]=O=>i.value?.setMode("talk"))},{default:ot(()=>[xt(de(T.value),1)]),_:1},8,["icon"]),e.bot.accounts.value&&e.bot.accounts.value.length>0?(w(),$("div",_L,[(w(!0),$(ge,null,st((e.bot.accounts.value||[]).filter(O=>Ae(wo)[O.platform]),O=>(w(),$("a",{key:`${O.platform}-${O.handle}`,href:Ae(wo)[O.platform].getUrl(O.handle),target:"_blank",class:"size-12 rounded-full text-white/60 hover:text-white hover:bg-white/5 border border-white/0 hover:border-white/10 flex items-center justify-center transition-all duration-200 hover:scale-105"},[b("i",{class:V([Ae(wo)[O.platform].icon,"size-5"])},null,2)],8,$L))),128))])):te("",!0)])])):l.value==="talk"?(w(),$("div",SL,[e.requireAuth&&!d.value?(w(),Fe(PE,{key:0,sdk:e.sdk},null,8,["sdk"])):(w(),$(ge,{key:1},[b("div",null,[b("div",IL,[be(Lp,{bot:e.bot,"is-online":u.value},null,8,["bot","is-online"])])]),be(yo,{"chat-controller":i.value,bot:e.bot},null,8,["chat-controller","bot"])],64))])):(w(),$("div",EL,[b("div",TL,[l.value==="chat"?(w(),$(ge,{key:0},[e.requireAuth&&!d.value?(w(),Fe(PE,{key:0,sdk:e.sdk},null,8,["sdk"])):(w(),Fe(yo,{key:1,"chat-controller":i.value,bot:e.bot,"show-header":""},null,8,["chat-controller","bot"]))],64)):l.value==="info"?(w(),Fe(ZM,{key:1,bot:e.bot,"is-online":u.value},null,8,["bot","is-online"])):te("",!0)])]))],64))],2)],14,fL)):a.value?(w(),$("div",NL,[b("div",CL,[j[12]||(j[12]=b("div",{class:"flex justify-center"},[b("div",{class:"rounded-full bg-red-500/20 flex items-center justify-center size-10"},[b("i",{class:"i-tabler-alert-circle size-6 text-red-400"})])],-1)),j[13]||(j[13]=b("h3",{class:"text-lg font-medium"}," Bot Error ",-1)),b("p",zL,de(a.value),1)])])):(w(),$("div",AL," Couldn't load your assistant. Please try again later. ")),e.chatOnly?te("",!0):(w(),Fe(pL,{key:4,modelValue:r.value,"onUpdate:modelValue":j[5]||(j[5]=O=>r.value=O),bot:e.bot,sdk:e.sdk,title:e.bot.displayName.value,"data-test":"bot-sidebar"},null,8,["modelValue","bot","sdk","title"])),e.chatOnly?te("",!0):(w(),Fe(dL,{key:5,modelValue:o.value,"onUpdate:modelValue":j[6]||(j[6]=O=>o.value=O),"chat-controller":i.value,"data-test":"bot-mode-sidebar"},null,8,["modelValue","chat-controller"]))]))}}),Zp=Pe({__name:"BotProvider",props:{sdk:{},bot:{},handle:{},context:{},clientContext:{},firstMessage:{},buttonText:{},buttonIcon:{},hasClose:{type:Boolean},chatOnly:{type:Boolean},bare:{type:Boolean},apiBase:{},emptyStateMessage:{}},emits:["close","error","turnStarted","turnCompleted"],setup(e,{emit:t}){let n=e,i=t;return(r,o)=>(w(),Fe(Vp,R0(n,{class:"bot-provider size-full relative"}),{default:ot(a=>[be(OL,{sdk:a.sdk,bot:a.bot,context:a.context,"first-message":a.firstMessage,"button-text":n.buttonText,"button-icon":n.buttonIcon,"has-close":n.hasClose,"chat-only":n.chatOnly,bare:n.bare,"empty-state-message":n.emptyStateMessage,"is-active":!0,class:"size-full",onClose:o[0]||(o[0]=s=>i("close",s)),onError:o[1]||(o[1]=s=>i("error",s)),onTurnStarted:o[2]||(o[2]=s=>i("turnStarted")),onTurnCompleted:o[3]||(o[3]=s=>i("turnCompleted",s))},Pa({_:2},[r.$slots["empty-heading"]?{name:"empty-heading",fn:ot(s=>[zt(r.$slots,"empty-heading",xa(Ra(s)))]),key:"0"}:void 0]),1032,["sdk","bot","context","first-message","button-text","button-icon","has-close","chat-only","bare","empty-state-message"])]),_:3},16))}})});var jE={};Xr(jE,{default:()=>DL});var DL,ME=re(()=>{"use strict";Pn();My();Bp();En();DL=Pe({__name:"BotWidgetInline",props:{sdk:{},handle:{},bot:{},context:{},firstMessage:{},buttonText:{},buttonIcon:{},chatOnly:{type:Boolean}},setup(e,{expose:t}){let{currentBot:n,currentContext:i,currentFirstMessage:r,currentButtonText:o,currentButtonIcon:a,update:s}=es(e);return t({update:s}),(l,u)=>(w(),Fe(Zp,{sdk:e.sdk,handle:e.handle,bot:Ae(n),context:Ae(i),"first-message":Ae(r),"button-text":Ae(o),"button-icon":Ae(a),"chat-only":e.chatOnly},null,8,["sdk","handle","bot","context","first-message","button-text","button-icon","chat-only"]))}})});var LE={};Xr(LE,{default:()=>PL});var PL,VE=re(()=>{"use strict";Pn();Fp();My();Bp();En();PL=Pe({__name:"BotWidgetModal",props:{sdk:{},handle:{},bot:{},context:{},firstMessage:{},buttonText:{},buttonIcon:{},chatOnly:{type:Boolean},onClose:{type:Function}},setup(e,{expose:t}){let n=e,{currentBot:i,currentContext:r,currentFirstMessage:o,currentButtonText:a,currentButtonIcon:s,update:l}=es(n),u=Q(!1);Ut(async()=>{await oo(),setTimeout(()=>{u.value=!0},10)});function d(){u.value=!1,setTimeout(()=>{n.onClose&&n.onClose()},300)}function p(){u.value=!0}return t({update:l,close:d,open:p}),(m,f)=>(w(),Fe(jy,{vis:u.value,"disable-teleport":!0,"modal-class":"max-w-4xl h-[80vh] md:h-[600px]","has-close":!1,"onUpdate:vis":f[0]||(f[0]=h=>u.value=h),onClose:d},{default:ot(()=>[be(Zp,{sdk:e.sdk,handle:e.handle,bot:Ae(i),context:Ae(r),"first-message":Ae(o),"button-text":Ae(a),"button-icon":Ae(s),"chat-only":e.chatOnly,"has-close":!0,onClose:d},null,8,["sdk","handle","bot","context","first-message","button-text","button-icon","chat-only"])]),_:1},8,["vis"]))}})});Pn();oy();Fp();Bp();ql();En();var RL=`/*! tailwindcss v4.3.5 | MIT License | https://tailwindcss.com */
|
|
169
|
-
@layer properties{@supports (((-webkit-hyphens:none)) and (not (margin-trim:block))) or ((-moz-orient:inline) and (not (color:rgb(from red r g b)))){*,:before,:after{--tw-translate-x:0;--tw-translate-y:0;--tw-translate-z:0;--tw-scale-x:1;--tw-scale-y:1;--tw-scale-z:1;--tw-rotate-x:initial;--tw-rotate-y:initial;--tw-rotate-z:initial;--tw-skew-x:initial;--tw-skew-y:initial;--tw-space-y-reverse:0;--tw-border-style:solid;--tw-gradient-position:initial;--tw-gradient-from:#0000;--tw-gradient-via:#0000;--tw-gradient-to:#0000;--tw-gradient-stops:initial;--tw-gradient-via-stops:initial;--tw-gradient-from-position:0%;--tw-gradient-via-position:50%;--tw-gradient-to-position:100%;--tw-leading:initial;--tw-font-weight:initial;--tw-tracking:initial;--tw-ordinal:initial;--tw-slashed-zero:initial;--tw-numeric-figure:initial;--tw-numeric-spacing:initial;--tw-numeric-fraction:initial;--tw-shadow:0 0 #0000;--tw-shadow-color:initial;--tw-shadow-alpha:100%;--tw-inset-shadow:0 0 #0000;--tw-inset-shadow-color:initial;--tw-inset-shadow-alpha:100%;--tw-ring-color:initial;--tw-ring-shadow:0 0 #0000;--tw-inset-ring-color:initial;--tw-inset-ring-shadow:0 0 #0000;--tw-ring-inset:initial;--tw-ring-offset-width:0px;--tw-ring-offset-color:#fff;--tw-ring-offset-shadow:0 0 #0000;--tw-blur:initial;--tw-brightness:initial;--tw-contrast:initial;--tw-grayscale:initial;--tw-hue-rotate:initial;--tw-invert:initial;--tw-opacity:initial;--tw-saturate:initial;--tw-sepia:initial;--tw-drop-shadow:initial;--tw-drop-shadow-color:initial;--tw-drop-shadow-alpha:100%;--tw-drop-shadow-size:initial;--tw-backdrop-blur:initial;--tw-backdrop-brightness:initial;--tw-backdrop-contrast:initial;--tw-backdrop-grayscale:initial;--tw-backdrop-hue-rotate:initial;--tw-backdrop-invert:initial;--tw-backdrop-opacity:initial;--tw-backdrop-saturate:initial;--tw-backdrop-sepia:initial;--tw-duration:initial;--tw-ease:initial}::backdrop{--tw-translate-x:0;--tw-translate-y:0;--tw-translate-z:0;--tw-scale-x:1;--tw-scale-y:1;--tw-scale-z:1;--tw-rotate-x:initial;--tw-rotate-y:initial;--tw-rotate-z:initial;--tw-skew-x:initial;--tw-skew-y:initial;--tw-space-y-reverse:0;--tw-border-style:solid;--tw-gradient-position:initial;--tw-gradient-from:#0000;--tw-gradient-via:#0000;--tw-gradient-to:#0000;--tw-gradient-stops:initial;--tw-gradient-via-stops:initial;--tw-gradient-from-position:0%;--tw-gradient-via-position:50%;--tw-gradient-to-position:100%;--tw-leading:initial;--tw-font-weight:initial;--tw-tracking:initial;--tw-ordinal:initial;--tw-slashed-zero:initial;--tw-numeric-figure:initial;--tw-numeric-spacing:initial;--tw-numeric-fraction:initial;--tw-shadow:0 0 #0000;--tw-shadow-color:initial;--tw-shadow-alpha:100%;--tw-inset-shadow:0 0 #0000;--tw-inset-shadow-color:initial;--tw-inset-shadow-alpha:100%;--tw-ring-color:initial;--tw-ring-shadow:0 0 #0000;--tw-inset-ring-color:initial;--tw-inset-ring-shadow:0 0 #0000;--tw-ring-inset:initial;--tw-ring-offset-width:0px;--tw-ring-offset-color:#fff;--tw-ring-offset-shadow:0 0 #0000;--tw-blur:initial;--tw-brightness:initial;--tw-contrast:initial;--tw-grayscale:initial;--tw-hue-rotate:initial;--tw-invert:initial;--tw-opacity:initial;--tw-saturate:initial;--tw-sepia:initial;--tw-drop-shadow:initial;--tw-drop-shadow-color:initial;--tw-drop-shadow-alpha:100%;--tw-drop-shadow-size:initial;--tw-backdrop-blur:initial;--tw-backdrop-brightness:initial;--tw-backdrop-contrast:initial;--tw-backdrop-grayscale:initial;--tw-backdrop-hue-rotate:initial;--tw-backdrop-invert:initial;--tw-backdrop-opacity:initial;--tw-backdrop-saturate:initial;--tw-backdrop-sepia:initial;--tw-duration:initial;--tw-ease:initial}}}@layer theme{:root,:host{--font-sans:system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;--font-mono:"DM Mono", "SF Mono", SFMono-Regular, Consolas, "Liberation Mono", Menlo, Courier, monospace;--color-red-300:#ffa3a3;--color-red-400:#ff6568;--color-red-500:#fb2c36;--color-red-600:#e40014;--color-amber-500:#f99c00;--color-green-300:#7bf1a8;--color-green-400:#05df72;--color-green-500:#00c758;--color-green-600:#00a544;--color-slate-200:#e2e8f0;--color-slate-950:#020618;--color-black:#000;--color-white:#fff;--spacing:.25rem;--breakpoint-md:48rem;--container-xs:20rem;--container-sm:24rem;--container-md:28rem;--container-4xl:56rem;--text-xs:.75rem;--text-xs--line-height:calc(1 / .75);--text-sm:.875rem;--text-sm--line-height:calc(1.25 / .875);--text-base:1rem;--text-base--line-height:calc(1.5 / 1);--text-lg:1.125rem;--text-lg--line-height:calc(1.75 / 1.125);--text-xl:1.25rem;--text-xl--line-height:calc(1.75 / 1.25);--text-2xl:1.5rem;--text-2xl--line-height:calc(2 / 1.5);--text-3xl:1.875rem;--text-3xl--line-height:calc(2.25 / 1.875);--font-weight-light:300;--font-weight-medium:500;--font-weight-semibold:600;--tracking-wide:.025em;--tracking-widest:.1em;--leading-tight:1.25;--leading-snug:1.375;--leading-relaxed:1.625;--radius-lg:.5rem;--radius-xl:.75rem;--radius-2xl:1rem;--radius-3xl:1.5rem;--ease-in:cubic-bezier(.4, 0, 1, 1);--ease-out:cubic-bezier(0, 0, .2, 1);--ease-in-out:cubic-bezier(.4, 0, .2, 1);--animate-spin:spin 1s linear infinite;--animate-ping:ping 1s cubic-bezier(0, 0, .2, 1) infinite;--animate-pulse:pulse 2s cubic-bezier(.4, 0, .6, 1) infinite;--blur-sm:8px;--blur-lg:16px;--blur-xl:24px;--default-transition-duration:.15s;--default-transition-timing-function:cubic-bezier(.4, 0, .2, 1);--default-font-family:var(--font-sans);--default-mono-font-family:var(--font-mono);--color-theme-0:var(--theme-0,#fff);--color-theme-25:var(--theme-25,#f8fafc);--color-theme-50:var(--theme-50,#f3f4f6);--color-theme-100:var(--theme-100,#e5e7eb);--color-theme-200:var(--theme-200,#d1d5db);--color-theme-300:var(--theme-300,#9ca3af);--color-theme-400:var(--theme-400,#6b7280);--color-theme-500:var(--theme-500,#4b5563);--color-theme-600:var(--theme-600,#374151);--color-theme-700:var(--theme-700,#1f2a44);--color-theme-800:var(--theme-800,#111827);--color-theme-900:var(--theme-900,#0c0a13);--color-theme-950:var(--theme-950,#030712);--color-primary-300:var(--primary-300,#60a5fa);--color-primary-400:var(--primary-400,#3b82f6);--color-primary-500:var(--primary-500,#2563eb);--color-primary-600:var(--primary-600,#1d4ed8)}@supports (color:color(display-p3 0 0 0)){:root,:host{--color-red-300:color(display-p3 .956922 .651886 .645122);--color-red-400:color(display-p3 .933534 .431676 .423491);--color-red-500:color(display-p3 .903738 .262579 .253307);--color-red-600:color(display-p3 .830323 .140383 .133196);--color-amber-500:color(display-p3 .93994 .620584 .0585367);--color-green-300:color(display-p3 .600292 .935514 .68114);--color-green-400:color(display-p3 .399536 .862346 .49324);--color-green-500:color(display-p3 .308734 .774754 .374307);--color-green-600:color(display-p3 .243882 .640824 .294808);--color-slate-200:color(display-p3 .890322 .909405 .939294);--color-slate-950:color(display-p3 .0102437 .0227555 .0878731)}}@supports (color:lab(0% 0 0)){:root,:host{--color-red-300:lab(76.5514% 36.422 15.5335);--color-red-400:lab(63.7053% 60.745 31.3109);--color-red-500:lab(55.4814% 75.0732 48.8528);--color-red-600:lab(48.4493% 77.4328 61.5452);--color-amber-500:lab(72.7183% 31.8672 97.9407);--color-green-300:lab(86.9953% -47.2691 25.0054);--color-green-400:lab(78.503% -64.9265 39.7492);--color-green-500:lab(70.5521% -66.5147 45.8073);--color-green-600:lab(59.0978% -58.6621 41.2579);--color-slate-200:lab(91.7353% -.998765 -4.76968);--color-slate-950:lab(1.76974% 1.32743 -9.28855)}}}@layer base{*,:after,:before{box-sizing:border-box;border:0 solid;margin:0;padding:0}::backdrop{box-sizing:border-box;border:0 solid;margin:0;padding:0}::-webkit-file-upload-button{box-sizing:border-box;border:0 solid;margin:0;padding:0}::file-selector-button{box-sizing:border-box;border:0 solid;margin:0;padding:0}html,:host{-webkit-text-size-adjust:100%;-moz-tab-size:4;tab-size:4;line-height:1.5;font-family:var(--default-font-family,-apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", "Noto Sans", Arial, sans-serif, "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol", "Noto Color Emoji");font-feature-settings:var(--default-font-feature-settings,normal);font-variation-settings:var(--default-font-variation-settings,normal);-webkit-tap-highlight-color:transparent}hr{height:0;color:inherit;border-top-width:1px}abbr:where([title]){-webkit-text-decoration:underline dotted;text-decoration:underline dotted}h1,h2,h3,h4,h5,h6{font-size:inherit;font-weight:inherit}a{color:inherit;-webkit-text-decoration:inherit;-webkit-text-decoration:inherit;-webkit-text-decoration:inherit;-webkit-text-decoration:inherit;text-decoration:inherit}b,strong{font-weight:bolder}code,kbd,samp,pre{font-family:var(--default-mono-font-family,ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace);font-feature-settings:var(--default-mono-font-feature-settings,normal);font-variation-settings:var(--default-mono-font-variation-settings,normal);font-size:1em}small{font-size:80%}sub,sup{vertical-align:baseline;font-size:75%;line-height:0;position:relative}sub{bottom:-.25em}sup{top:-.5em}table{text-indent:0;border-color:inherit;border-collapse:collapse}:-moz-focusring:where(:not(iframe)){outline:auto}progress{vertical-align:baseline}summary{display:list-item}ol,ul,menu{list-style:none}img,svg,video,canvas,audio,iframe,embed,object{vertical-align:middle;display:block}img,video{max-width:100%;height:auto}button,input,select,optgroup,textarea{font:inherit;font-feature-settings:inherit;font-variation-settings:inherit;letter-spacing:inherit;color:inherit;opacity:1;background-color:#0000;border-radius:0}::-webkit-file-upload-button{font:inherit;font-feature-settings:inherit;font-variation-settings:inherit;letter-spacing:inherit;color:inherit;opacity:1;background-color:#0000;border-radius:0}::file-selector-button{font:inherit;font-feature-settings:inherit;font-variation-settings:inherit;letter-spacing:inherit;color:inherit;opacity:1;background-color:#0000;border-radius:0}:where(select:-webkit-any([multiple],[size])) optgroup{font-weight:bolder}:where(select:is([multiple],[size])) optgroup{font-weight:bolder}:where(select:-webkit-any([multiple],[size])) optgroup option{padding-inline-start:20px}:where(select:is([multiple],[size])) optgroup option{padding-inline-start:20px}::-webkit-file-upload-button{margin-inline-end:4px}::file-selector-button{margin-inline-end:4px}::placeholder{opacity:1}@supports (not ((-webkit-appearance:-apple-pay-button))) or (contain-intrinsic-size:1px){::placeholder{color:currentColor}@supports (color:color-mix(in lab, red, red)){::placeholder{color:color-mix(in oklab, currentcolor 50%, transparent)}}}textarea{resize:vertical}::-webkit-search-decoration{-webkit-appearance:none}::-webkit-date-and-time-value{min-height:1lh;text-align:inherit}::-webkit-datetime-edit{display:inline-flex}::-webkit-datetime-edit-fields-wrapper{padding:0}::-webkit-datetime-edit{padding-block-start:0;padding-block-end:0}::-webkit-datetime-edit-year-field{padding-block-start:0;padding-block-end:0}::-webkit-datetime-edit-month-field{padding-block-start:0;padding-block-end:0}::-webkit-datetime-edit-day-field{padding-block-start:0;padding-block-end:0}::-webkit-datetime-edit-hour-field{padding-block-start:0;padding-block-end:0}::-webkit-datetime-edit-minute-field{padding-block-start:0;padding-block-end:0}::-webkit-datetime-edit-second-field{padding-block-start:0;padding-block-end:0}::-webkit-datetime-edit-millisecond-field{padding-block-start:0;padding-block-end:0}::-webkit-datetime-edit-meridiem-field{padding-block-start:0;padding-block-end:0}::-webkit-calendar-picker-indicator{line-height:1}:-moz-ui-invalid{box-shadow:none}button{-webkit-appearance:button;appearance:button}input:where([type=button],[type=reset],[type=submit]){-webkit-appearance:button;appearance:button}::-webkit-file-upload-button{-webkit-appearance:button;appearance:button}::file-selector-button{-webkit-appearance:button;appearance:button}::-webkit-inner-spin-button{height:auto}::-webkit-outer-spin-button{height:auto}[hidden]:where(:not([hidden=until-found])){display:none!important}}@layer components;@layer utilities{.\\@container\\/bot{container:bot/inline-size}.\\@container\\/chat{container:chat/inline-size}.\\@container\\/chat-preview{container:chat-preview/inline-size}.\\@container{container-type:inline-size}.pointer-events-auto{pointer-events:auto}.pointer-events-none{pointer-events:none}.collapse{visibility:collapse}.invisible{visibility:hidden}.visible{visibility:visible}.sr-only{clip-path:inset(50%);white-space:nowrap;border-width:0;width:1px;height:1px;margin:-1px;padding:0;position:absolute;overflow:hidden}.absolute{position:absolute}.fixed{position:fixed}.relative{position:relative}.static{position:static}.inset-0{top:0;bottom:0;left:0;right:0}.inset-x-0{left:0;right:0}.-top-1\\.5{top:calc(var(--spacing) * -1.5)}.top-0{top:0}.top-0\\.5{top:calc(var(--spacing) * .5)}.top-1{top:var(--spacing)}.top-1\\.5{top:calc(var(--spacing) * 1.5)}.top-1\\/2{top:50%}.top-4{top:calc(var(--spacing) * 4)}.top-6{top:calc(var(--spacing) * 6)}.top-\\[5\\%\\]{top:5%}.-right-1\\.5{right:calc(var(--spacing) * -1.5)}.-right-16{right:calc(var(--spacing) * -16)}.right-0{right:0}.right-0\\.5{right:calc(var(--spacing) * .5)}.right-1{right:var(--spacing)}.right-1\\.5{right:calc(var(--spacing) * 1.5)}.right-4{right:calc(var(--spacing) * 4)}.right-6{right:calc(var(--spacing) * 6)}.right-\\[5\\%\\]{right:5%}.-bottom-\\[3\\%\\]{bottom:-3%}.bottom-0{bottom:0}.bottom-4{bottom:calc(var(--spacing) * 4)}.bottom-6{bottom:calc(var(--spacing) * 6)}.-left-16{left:calc(var(--spacing) * -16)}.-left-\\[3\\%\\]{left:-3%}.left-0{left:0}.left-1\\/2{left:50%}.left-4{left:calc(var(--spacing) * 4)}.left-6{left:calc(var(--spacing) * 6)}.left-\\[13px\\]{left:13px}.z-0{z-index:0}.z-10{z-index:10}.z-20{z-index:20}.z-30{z-index:30}.z-40{z-index:40}.z-50{z-index:50}.z-\\[100\\]{z-index:100}.z-\\[999999\\]{z-index:999999}.container{width:100%}@media (min-width:40rem){.container{max-width:40rem}}@media (min-width:48rem){.container{max-width:48rem}}@media (min-width:64rem){.container{max-width:64rem}}@media (min-width:80rem){.container{max-width:80rem}}@media (min-width:96rem){.container{max-width:96rem}}.mx-auto{margin-inline-start:auto;margin-inline-end:auto}.my-2{margin-block:calc(var(--spacing) * 2)}.my-6{margin-block:calc(var(--spacing) * 6)}.mt-0\\.5{margin-top:calc(var(--spacing) * .5)}.mt-1{margin-top:var(--spacing)}.mt-2{margin-top:calc(var(--spacing) * 2)}.mt-2\\.5{margin-top:calc(var(--spacing) * 2.5)}.mt-3{margin-top:calc(var(--spacing) * 3)}.mt-5{margin-top:calc(var(--spacing) * 5)}.mt-16{margin-top:calc(var(--spacing) * 16)}.mt-\\[-\\.07em\\]{margin-top:-.07em}.-mr-1{margin-right:calc(var(--spacing) * -1)}.mr-2{margin-right:calc(var(--spacing) * 2)}.mb-1{margin-bottom:var(--spacing)}.mb-1\\.5{margin-bottom:calc(var(--spacing) * 1.5)}.mb-2{margin-bottom:calc(var(--spacing) * 2)}.mb-2\\.5{margin-bottom:calc(var(--spacing) * 2.5)}.mb-4{margin-bottom:calc(var(--spacing) * 4)}.mb-6{margin-bottom:calc(var(--spacing) * 6)}.mb-10{margin-bottom:calc(var(--spacing) * 10)}.mb-12{margin-bottom:calc(var(--spacing) * 12)}.-ml-1{margin-left:calc(var(--spacing) * -1)}.-ml-2{margin-left:calc(var(--spacing) * -2)}.ml-1\\.5{margin-left:calc(var(--spacing) * 1.5)}.ml-3{margin-left:calc(var(--spacing) * 3)}.ml-auto{margin-left:auto}.i-heroicons-calendar{width:1em;height:1em;-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);mask-image:var(--svg);--svg:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' width='24' height='24'%3E%3Cpath fill='none' stroke='black' stroke-linecap='round' stroke-linejoin='round' stroke-width='1.5' d='M6.75 3v2.25M17.25 3v2.25M3 18.75V7.5a2.25 2.25 0 0 1 2.25-2.25h13.5A2.25 2.25 0 0 1 21 7.5v11.25m-18 0A2.25 2.25 0 0 0 5.25 21h13.5A2.25 2.25 0 0 0 21 18.75m-18 0v-7.5A2.25 2.25 0 0 1 5.25 9h13.5A2.25 2.25 0 0 1 21 11.25v7.5'/%3E%3C/svg%3E");background-color:currentColor;display:inline-block;-webkit-mask-size:100% 100%;mask-size:100% 100%;-webkit-mask-repeat:no-repeat;mask-repeat:no-repeat}.i-heroicons-chat-bubble-left-right{width:1em;height:1em;-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);mask-image:var(--svg);--svg:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' width='24' height='24'%3E%3Cpath fill='none' stroke='black' stroke-linecap='round' stroke-linejoin='round' stroke-width='1.5' d='M20.25 8.511c.884.284 1.5 1.128 1.5 2.097v4.286c0 1.136-.847 2.1-1.98 2.193q-.51.041-1.02.072v3.091l-3-3q-2.031 0-4.02-.163a2.1 2.1 0 0 1-.825-.242m9.345-8.334a2 2 0 0 0-.476-.095a48.6 48.6 0 0 0-8.048 0c-1.131.094-1.976 1.057-1.976 2.192v4.286c0 .837.46 1.58 1.155 1.951m9.345-8.334V6.637c0-1.621-1.152-3.026-2.76-3.235A48.5 48.5 0 0 0 11.25 3c-2.115 0-4.198.137-6.24.402c-1.608.209-2.76 1.614-2.76 3.235v6.226c0 1.621 1.152 3.026 2.76 3.235q.865.113 1.74.194V21l4.155-4.155'/%3E%3C/svg%3E");background-color:currentColor;display:inline-block;-webkit-mask-size:100% 100%;mask-size:100% 100%;-webkit-mask-repeat:no-repeat;mask-repeat:no-repeat}.i-heroicons-envelope{width:1em;height:1em;-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);mask-image:var(--svg);--svg:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' width='24' height='24'%3E%3Cpath fill='none' stroke='black' stroke-linecap='round' stroke-linejoin='round' stroke-width='1.5' d='M21.75 6.75v10.5a2.25 2.25 0 0 1-2.25 2.25h-15a2.25 2.25 0 0 1-2.25-2.25V6.75m19.5 0A2.25 2.25 0 0 0 19.5 4.5h-15a2.25 2.25 0 0 0-2.25 2.25m19.5 0v.243a2.25 2.25 0 0 1-1.07 1.916l-7.5 4.615a2.25 2.25 0 0 1-2.36 0L3.32 8.91a2.25 2.25 0 0 1-1.07-1.916V6.75'/%3E%3C/svg%3E");background-color:currentColor;display:inline-block;-webkit-mask-size:100% 100%;mask-size:100% 100%;-webkit-mask-repeat:no-repeat;mask-repeat:no-repeat}.i-heroicons-phone{width:1em;height:1em;-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);mask-image:var(--svg);--svg:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' width='24' height='24'%3E%3Cpath fill='none' stroke='black' stroke-linecap='round' stroke-linejoin='round' stroke-width='1.5' d='M2.25 6.75c0 8.284 6.716 15 15 15h2.25a2.25 2.25 0 0 0 2.25-2.25v-1.372c0-.516-.351-.966-.852-1.091l-4.423-1.106c-.44-.11-.902.055-1.173.417l-.97 1.293c-.282.376-.769.542-1.21.38a12.04 12.04 0 0 1-7.143-7.143c-.162-.441.004-.928.38-1.21l1.293-.97c.363-.271.527-.734.417-1.173L6.963 3.102a1.125 1.125 0 0 0-1.091-.852H4.5A2.25 2.25 0 0 0 2.25 4.5z'/%3E%3C/svg%3E");background-color:currentColor;display:inline-block;-webkit-mask-size:100% 100%;mask-size:100% 100%;-webkit-mask-repeat:no-repeat;mask-repeat:no-repeat}.i-heroicons-question-mark-circle{width:1em;height:1em;-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);mask-image:var(--svg);--svg:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' width='24' height='24'%3E%3Cpath fill='none' stroke='black' stroke-linecap='round' stroke-linejoin='round' stroke-width='1.5' d='M9.879 7.519c1.172-1.025 3.071-1.025 4.243 0c1.171 1.025 1.171 2.687 0 3.712q-.308.268-.67.442c-.746.361-1.452.999-1.452 1.827v.75M21 12a9 9 0 1 1-18 0a9 9 0 0 1 18 0m-9 5.25h.008v.008H12z'/%3E%3C/svg%3E");background-color:currentColor;display:inline-block;-webkit-mask-size:100% 100%;mask-size:100% 100%;-webkit-mask-repeat:no-repeat;mask-repeat:no-repeat}.i-heroicons-sparkles{width:1em;height:1em;-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);mask-image:var(--svg);--svg:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' width='24' height='24'%3E%3Cpath fill='none' stroke='black' stroke-linecap='round' stroke-linejoin='round' stroke-width='1.5' d='M9.813 15.904L9 18.75l-.813-2.846a4.5 4.5 0 0 0-3.09-3.09L2.25 12l2.846-.813a4.5 4.5 0 0 0 3.09-3.09L9 5.25l.813 2.846a4.5 4.5 0 0 0 3.09 3.09L15.75 12l-2.846.813a4.5 4.5 0 0 0-3.09 3.09m8.445-7.188L18 9.75l-.259-1.035a3.38 3.38 0 0 0-2.455-2.456L14.25 6l1.036-.259a3.38 3.38 0 0 0 2.455-2.456L18 2.25l.259 1.035a3.38 3.38 0 0 0 2.456 2.456L21.75 6l-1.035.259a3.38 3.38 0 0 0-2.456 2.456m-1.365 11.852L16.5 21.75l-.394-1.183a2.25 2.25 0 0 0-1.423-1.423L13.5 18.75l1.183-.394a2.25 2.25 0 0 0 1.423-1.423l.394-1.183l.394 1.183a2.25 2.25 0 0 0 1.423 1.423l1.183.394l-1.183.394a2.25 2.25 0 0 0-1.423 1.423'/%3E%3C/svg%3E");background-color:currentColor;display:inline-block;-webkit-mask-size:100% 100%;mask-size:100% 100%;-webkit-mask-repeat:no-repeat;mask-repeat:no-repeat}.i-simple-icons-facebook{width:1em;height:1em;-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);mask-image:var(--svg);--svg:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' width='24' height='24'%3E%3Cpath fill='black' d='M9.101 23.691v-7.98H6.627v-3.667h2.474v-1.58c0-4.085 1.848-5.978 5.858-5.978c.401 0 .955.042 1.468.103a9 9 0 0 1 1.141.195v3.325a9 9 0 0 0-.653-.036a27 27 0 0 0-.733-.009c-.707 0-1.259.096-1.675.309a1.7 1.7 0 0 0-.679.622c-.258.42-.374.995-.374 1.752v1.297h3.919l-.386 2.103l-.287 1.564h-3.246v8.245C19.396 23.238 24 18.179 24 12.044c0-6.627-5.373-12-12-12s-12 5.373-12 12c0 5.628 3.874 10.35 9.101 11.647'/%3E%3C/svg%3E");background-color:currentColor;display:inline-block;-webkit-mask-size:100% 100%;mask-size:100% 100%;-webkit-mask-repeat:no-repeat;mask-repeat:no-repeat}.i-simple-icons-instagram{width:1em;height:1em;-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);mask-image:var(--svg);--svg:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' width='24' height='24'%3E%3Cpath fill='black' d='M7.03.084c-1.277.06-2.149.264-2.91.563a5.9 5.9 0 0 0-2.124 1.388a5.9 5.9 0 0 0-1.38 2.127C.321 4.926.12 5.8.064 7.076s-.069 1.688-.063 4.947s.021 3.667.083 4.947c.061 1.277.264 2.149.563 2.911c.308.789.72 1.457 1.388 2.123a5.9 5.9 0 0 0 2.129 1.38c.763.295 1.636.496 2.913.552c1.278.056 1.689.069 4.947.063s3.668-.021 4.947-.082c1.28-.06 2.147-.265 2.91-.563a5.9 5.9 0 0 0 2.123-1.388a5.9 5.9 0 0 0 1.38-2.129c.295-.763.496-1.636.551-2.912c.056-1.28.07-1.69.063-4.948c-.006-3.258-.02-3.667-.081-4.947c-.06-1.28-.264-2.148-.564-2.911a5.9 5.9 0 0 0-1.387-2.123a5.9 5.9 0 0 0-2.128-1.38c-.764-.294-1.636-.496-2.914-.55C15.647.009 15.236-.006 11.977 0S8.31.021 7.03.084m.14 21.693c-1.17-.05-1.805-.245-2.228-.408a3.7 3.7 0 0 1-1.382-.895a3.7 3.7 0 0 1-.9-1.378c-.165-.423-.363-1.058-.417-2.228c-.06-1.264-.072-1.644-.08-4.848c-.006-3.204.006-3.583.061-4.848c.05-1.169.246-1.805.408-2.228c.216-.561.477-.96.895-1.382a3.7 3.7 0 0 1 1.379-.9c.423-.165 1.057-.361 2.227-.417c1.265-.06 1.644-.072 4.848-.08c3.203-.006 3.583.006 4.85.062c1.168.05 1.804.244 2.227.408c.56.216.96.475 1.382.895s.681.817.9 1.378c.165.422.362 1.056.417 2.227c.06 1.265.074 1.645.08 4.848c.005 3.203-.006 3.583-.061 4.848c-.051 1.17-.245 1.805-.408 2.23c-.216.56-.477.96-.896 1.38a3.7 3.7 0 0 1-1.378.9c-.422.165-1.058.362-2.226.418c-1.266.06-1.645.072-4.85.079s-3.582-.006-4.848-.06m9.783-16.192a1.44 1.44 0 1 0 1.437-1.442a1.44 1.44 0 0 0-1.437 1.442M5.839 12.012a6.161 6.161 0 1 0 12.323-.024a6.162 6.162 0 0 0-12.323.024M8 12.008A4 4 0 1 1 12.008 16A4 4 0 0 1 8 12.008'/%3E%3C/svg%3E");background-color:currentColor;display:inline-block;-webkit-mask-size:100% 100%;mask-size:100% 100%;-webkit-mask-repeat:no-repeat;mask-repeat:no-repeat}.i-simple-icons-linkedin{width:1em;height:1em;-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);mask-image:var(--svg);--svg:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' width='24' height='24'%3E%3Cpath fill='black' d='M20.447 20.452h-3.554v-5.569c0-1.328-.027-3.037-1.852-3.037c-1.853 0-2.136 1.445-2.136 2.939v5.667H9.351V9h3.414v1.561h.046c.477-.9 1.637-1.85 3.37-1.85c3.601 0 4.267 2.37 4.267 5.455v6.286zM5.337 7.433a2.06 2.06 0 0 1-2.063-2.065a2.064 2.064 0 1 1 2.063 2.065m1.782 13.019H3.555V9h3.564zM22.225 0H1.771C.792 0 0 .774 0 1.729v20.542C0 23.227.792 24 1.771 24h20.451C23.2 24 24 23.227 24 22.271V1.729C24 .774 23.2 0 22.222 0z'/%3E%3C/svg%3E");background-color:currentColor;display:inline-block;-webkit-mask-size:100% 100%;mask-size:100% 100%;-webkit-mask-repeat:no-repeat;mask-repeat:no-repeat}.i-simple-icons-threads{width:1em;height:1em;-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);mask-image:var(--svg);--svg:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' width='24' height='24'%3E%3Cpath fill='black' d='M18.263 11.097c-.03-3.486-1.92-5.586-5.111-5.586c-2.13 0-3.922.963-4.863 2.499l2.062 1.438c.535-.843 1.272-1.543 2.628-1.543c1.528 0 2.318.85 2.544 2.431a15 15 0 0 0-2.236-.173c-4.125 0-6.068 1.867-6.068 4.336s1.943 3.99 4.804 3.99c3.139 0 5.013-2.115 5.781-4.735c.798.361 1.348 1.204 1.348 2.47c0 3.387-3.907 5.232-7.22 5.232c-4.885 0-8.077-3.207-8.077-8.424c0-6.392 4.223-10.487 9.9-10.487c3.808 0 5.69 1.671 6.97 3.914l2.108-1.475C21.44 2.078 18.331 0 13.663 0C6.227 0 1.168 5.277 1.168 12.934c0 7 4.953 11.066 10.856 11.066c4.878 0 9.809-2.846 9.809-7.716c0-2.545-1.46-4.231-3.569-5.187m-6.33 4.855c-1.077 0-2.026-.512-2.026-1.453c0-1.483 1.822-1.934 3.606-1.934c.678 0 1.34.045 1.927.173c-.422 1.927-1.671 3.215-3.508 3.214Z'/%3E%3C/svg%3E");background-color:currentColor;display:inline-block;-webkit-mask-size:100% 100%;mask-size:100% 100%;-webkit-mask-repeat:no-repeat;mask-repeat:no-repeat}.i-simple-icons-tiktok{width:1em;height:1em;-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);mask-image:var(--svg);--svg:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' width='24' height='24'%3E%3Cpath fill='black' d='M12.525.02c1.31-.02 2.61-.01 3.91-.02c.08 1.53.63 3.09 1.75 4.17c1.12 1.11 2.7 1.62 4.24 1.79v4.03c-1.44-.05-2.89-.35-4.2-.97c-.57-.26-1.1-.59-1.62-.93c-.01 2.92.01 5.84-.02 8.75c-.08 1.4-.54 2.79-1.35 3.94c-1.31 1.92-3.58 3.17-5.91 3.21c-1.43.08-2.86-.31-4.08-1.03c-2.02-1.19-3.44-3.37-3.65-5.71c-.02-.5-.03-1-.01-1.49c.18-1.9 1.12-3.72 2.58-4.96c1.66-1.44 3.98-2.13 6.15-1.72c.02 1.48-.04 2.96-.04 4.44c-.99-.32-2.15-.23-3.02.37c-.63.41-1.11 1.04-1.36 1.75c-.21.51-.15 1.07-.14 1.61c.24 1.64 1.82 3.02 3.5 2.87c1.12-.01 2.19-.66 2.77-1.61c.19-.33.4-.67.41-1.06c.1-1.79.06-3.57.07-5.36c.01-4.03-.01-8.05.02-12.07'/%3E%3C/svg%3E");background-color:currentColor;display:inline-block;-webkit-mask-size:100% 100%;mask-size:100% 100%;-webkit-mask-repeat:no-repeat;mask-repeat:no-repeat}.i-simple-icons-x{width:1em;height:1em;-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);mask-image:var(--svg);--svg:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' width='24' height='24'%3E%3Cpath fill='black' d='M14.234 10.162L22.977 0h-2.072l-7.591 8.824L7.251 0H.258l9.168 13.343L.258 24H2.33l8.016-9.318L16.749 24h6.993zm-2.837 3.299l-.929-1.329L3.076 1.56h3.182l5.965 8.532l.929 1.329l7.754 11.09h-3.182z'/%3E%3C/svg%3E");background-color:currentColor;display:inline-block;-webkit-mask-size:100% 100%;mask-size:100% 100%;-webkit-mask-repeat:no-repeat;mask-repeat:no-repeat}.i-svg-spinners-90-ring-with-bg{width:1em;height:1em;-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);mask-image:var(--svg);--svg:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' width='24' height='24'%3E%3Cpath fill='black' d='M12,1A11,11,0,1,0,23,12,11,11,0,0,0,12,1Zm0,19a8,8,0,1,1,8-8A8,8,0,0,1,12,20Z' opacity='.25'/%3E%3Cpath fill='black' d='M10.14,1.16a11,11,0,0,0-9,8.92A1.59,1.59,0,0,0,2.46,12,1.52,1.52,0,0,0,4.11,10.7a8,8,0,0,1,6.66-6.61A1.42,1.42,0,0,0,12,2.69h0A1.57,1.57,0,0,0,10.14,1.16Z'%3E%3CanimateTransform attributeName='transform' dur='0.75s' repeatCount='indefinite' type='rotate' values='0 12 12;360 12 12'/%3E%3C/path%3E%3C/svg%3E");background-color:currentColor;display:inline-block;-webkit-mask-size:100% 100%;mask-size:100% 100%;-webkit-mask-repeat:no-repeat;mask-repeat:no-repeat}.i-svg-spinners-ring-resize{width:1em;height:1em;-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);mask-image:var(--svg);--svg:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' width='24' height='24'%3E%3Cg stroke='black'%3E%3Ccircle cx='12' cy='12' r='9.5' fill='none' stroke-linecap='round' stroke-width='3'%3E%3Canimate attributeName='stroke-dasharray' calcMode='spline' dur='1.5s' keySplines='0.42,0,0.58,1;0.42,0,0.58,1;0.42,0,0.58,1' keyTimes='0;0.475;0.95;1' repeatCount='indefinite' values='0 150;42 150;42 150;42 150'/%3E%3Canimate attributeName='stroke-dashoffset' calcMode='spline' dur='1.5s' keySplines='0.42,0,0.58,1;0.42,0,0.58,1;0.42,0,0.58,1' keyTimes='0;0.475;0.95;1' repeatCount='indefinite' values='0;-16;-59;-59'/%3E%3C/circle%3E%3CanimateTransform attributeName='transform' dur='2s' repeatCount='indefinite' type='rotate' values='0 12 12;360 12 12'/%3E%3C/g%3E%3C/svg%3E");background-color:currentColor;display:inline-block;-webkit-mask-size:100% 100%;mask-size:100% 100%;-webkit-mask-repeat:no-repeat;mask-repeat:no-repeat}.i-tabler-alert-circle{width:1em;height:1em;-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);mask-image:var(--svg);--svg:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' width='24' height='24'%3E%3Cpath fill='none' stroke='black' stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='M3 12a9 9 0 1 0 18 0a9 9 0 0 0-18 0m9-4v4m0 4h.01'/%3E%3C/svg%3E");background-color:currentColor;display:inline-block;-webkit-mask-size:100% 100%;mask-size:100% 100%;-webkit-mask-repeat:no-repeat;mask-repeat:no-repeat}.i-tabler-arrow-right{width:1em;height:1em;-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);mask-image:var(--svg);--svg:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' width='24' height='24'%3E%3Cpath fill='none' stroke='black' stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='M5 12h14m-6 6l6-6m-6-6l6 6'/%3E%3C/svg%3E");background-color:currentColor;display:inline-block;-webkit-mask-size:100% 100%;mask-size:100% 100%;-webkit-mask-repeat:no-repeat;mask-repeat:no-repeat}.i-tabler-arrow-up{width:1em;height:1em;-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);mask-image:var(--svg);--svg:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' width='24' height='24'%3E%3Cpath fill='none' stroke='black' stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='M12 5v14m6-8l-6-6m-6 6l6-6'/%3E%3C/svg%3E");background-color:currentColor;display:inline-block;-webkit-mask-size:100% 100%;mask-size:100% 100%;-webkit-mask-repeat:no-repeat;mask-repeat:no-repeat}.i-tabler-brand-github{width:1em;height:1em;-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);mask-image:var(--svg);--svg:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' width='24' height='24'%3E%3Cpath fill='none' stroke='black' stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='M9 19c-4.3 1.4-4.3-2.5-6-3m12 5v-3.5c0-1 .1-1.4-.5-2c2.8-.3 5.5-1.4 5.5-6a4.6 4.6 0 0 0-1.3-3.2a4.2 4.2 0 0 0-.1-3.2s-1.1-.3-3.5 1.3a12.3 12.3 0 0 0-6.2 0C6.5 2.8 5.4 3.1 5.4 3.1a4.2 4.2 0 0 0-.1 3.2A4.6 4.6 0 0 0 4 9.5c0 4.6 2.7 5.7 5.5 6c-.6.6-.6 1.2-.5 2V21'/%3E%3C/svg%3E");background-color:currentColor;display:inline-block;-webkit-mask-size:100% 100%;mask-size:100% 100%;-webkit-mask-repeat:no-repeat;mask-repeat:no-repeat}.i-tabler-brand-youtube{width:1em;height:1em;-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);mask-image:var(--svg);--svg:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' width='24' height='24'%3E%3Cg fill='none' stroke='black' stroke-linecap='round' stroke-linejoin='round' stroke-width='2'%3E%3Cpath d='M2 8a4 4 0 0 1 4-4h12a4 4 0 0 1 4 4v8a4 4 0 0 1-4 4H6a4 4 0 0 1-4-4z'/%3E%3Cpath d='m10 9l5 3l-5 3z'/%3E%3C/g%3E%3C/svg%3E");background-color:currentColor;display:inline-block;-webkit-mask-size:100% 100%;mask-size:100% 100%;-webkit-mask-repeat:no-repeat;mask-repeat:no-repeat}.i-tabler-calendar{width:1em;height:1em;-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);mask-image:var(--svg);--svg:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' width='24' height='24'%3E%3Cpath fill='none' stroke='black' stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='M4 7a2 2 0 0 1 2-2h12a2 2 0 0 1 2 2v12a2 2 0 0 1-2 2H6a2 2 0 0 1-2-2zm12-4v4M8 3v4m-4 4h16m-9 4h1m0 0v3'/%3E%3C/svg%3E");background-color:currentColor;display:inline-block;-webkit-mask-size:100% 100%;mask-size:100% 100%;-webkit-mask-repeat:no-repeat;mask-repeat:no-repeat}.i-tabler-check{width:1em;height:1em;-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);mask-image:var(--svg);--svg:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' width='24' height='24'%3E%3Cpath fill='none' stroke='black' stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='m5 12l5 5L20 7'/%3E%3C/svg%3E");background-color:currentColor;display:inline-block;-webkit-mask-size:100% 100%;mask-size:100% 100%;-webkit-mask-repeat:no-repeat;mask-repeat:no-repeat}.i-tabler-chevron-down{width:1em;height:1em;-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);mask-image:var(--svg);--svg:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' width='24' height='24'%3E%3Cpath fill='none' stroke='black' stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='m6 9l6 6l6-6'/%3E%3C/svg%3E");background-color:currentColor;display:inline-block;-webkit-mask-size:100% 100%;mask-size:100% 100%;-webkit-mask-repeat:no-repeat;mask-repeat:no-repeat}.i-tabler-chevron-right{width:1em;height:1em;-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);mask-image:var(--svg);--svg:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' width='24' height='24'%3E%3Cpath fill='none' stroke='black' stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='m9 6l6 6l-6 6'/%3E%3C/svg%3E");background-color:currentColor;display:inline-block;-webkit-mask-size:100% 100%;mask-size:100% 100%;-webkit-mask-repeat:no-repeat;mask-repeat:no-repeat}.i-tabler-circle-check{width:1em;height:1em;-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);mask-image:var(--svg);--svg:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' width='24' height='24'%3E%3Cg fill='none' stroke='black' stroke-linecap='round' stroke-linejoin='round' stroke-width='2'%3E%3Cpath d='M3 12a9 9 0 1 0 18 0a9 9 0 1 0-18 0'/%3E%3Cpath d='m9 12l2 2l4-4'/%3E%3C/g%3E%3C/svg%3E");background-color:currentColor;display:inline-block;-webkit-mask-size:100% 100%;mask-size:100% 100%;-webkit-mask-repeat:no-repeat;mask-repeat:no-repeat}.i-tabler-clock{width:1em;height:1em;-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);mask-image:var(--svg);--svg:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' width='24' height='24'%3E%3Cg fill='none' stroke='black' stroke-linecap='round' stroke-linejoin='round' stroke-width='2'%3E%3Cpath d='M3 12a9 9 0 1 0 18 0a9 9 0 0 0-18 0'/%3E%3Cpath d='M12 7v5l3 3'/%3E%3C/g%3E%3C/svg%3E");background-color:currentColor;display:inline-block;-webkit-mask-size:100% 100%;mask-size:100% 100%;-webkit-mask-repeat:no-repeat;mask-repeat:no-repeat}.i-tabler-copy{width:1em;height:1em;-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);mask-image:var(--svg);--svg:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' width='24' height='24'%3E%3Cg fill='none' stroke='black' stroke-linecap='round' stroke-linejoin='round' stroke-width='2'%3E%3Cpath d='M7 9.667A2.667 2.667 0 0 1 9.667 7h8.666A2.667 2.667 0 0 1 21 9.667v8.666A2.667 2.667 0 0 1 18.333 21H9.667A2.667 2.667 0 0 1 7 18.333z'/%3E%3Cpath d='M4.012 16.737A2 2 0 0 1 3 15V5c0-1.1.9-2 2-2h10c.75 0 1.158.385 1.5 1'/%3E%3C/g%3E%3C/svg%3E");background-color:currentColor;display:inline-block;-webkit-mask-size:100% 100%;mask-size:100% 100%;-webkit-mask-repeat:no-repeat;mask-repeat:no-repeat}.i-tabler-file{width:1em;height:1em;-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);mask-image:var(--svg);--svg:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' width='24' height='24'%3E%3Cg fill='none' stroke='black' stroke-linecap='round' stroke-linejoin='round' stroke-width='2'%3E%3Cpath d='M14 3v4a1 1 0 0 0 1 1h4'/%3E%3Cpath d='M17 21H7a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2h7l5 5v11a2 2 0 0 1-2 2'/%3E%3C/g%3E%3C/svg%3E");background-color:currentColor;display:inline-block;-webkit-mask-size:100% 100%;mask-size:100% 100%;-webkit-mask-repeat:no-repeat;mask-repeat:no-repeat}.i-tabler-flag{width:1em;height:1em;-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);mask-image:var(--svg);--svg:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' width='24' height='24'%3E%3Cpath fill='none' stroke='black' stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='M5 5a5 5 0 0 1 7 0a5 5 0 0 0 7 0v9a5 5 0 0 1-7 0a5 5 0 0 0-7 0zm0 16v-7'/%3E%3C/svg%3E");background-color:currentColor;display:inline-block;-webkit-mask-size:100% 100%;mask-size:100% 100%;-webkit-mask-repeat:no-repeat;mask-repeat:no-repeat}.i-tabler-globe{width:1em;height:1em;-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);mask-image:var(--svg);--svg:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' width='24' height='24'%3E%3Cg fill='none' stroke='black' stroke-linecap='round' stroke-linejoin='round' stroke-width='2'%3E%3Cpath d='M7 9a4 4 0 1 0 8 0a4 4 0 0 0-8 0'/%3E%3Cpath d='M5.75 15A8.015 8.015 0 1 0 15 2m-4 15v4m-4 0h8'/%3E%3C/g%3E%3C/svg%3E");background-color:currentColor;display:inline-block;-webkit-mask-size:100% 100%;mask-size:100% 100%;-webkit-mask-repeat:no-repeat;mask-repeat:no-repeat}.i-tabler-info-circle{width:1em;height:1em;-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);mask-image:var(--svg);--svg:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' width='24' height='24'%3E%3Cg fill='none' stroke='black' stroke-linecap='round' stroke-linejoin='round' stroke-width='2'%3E%3Cpath d='M3 12a9 9 0 1 0 18 0a9 9 0 0 0-18 0m9-3h.01'/%3E%3Cpath d='M11 12h1v4h1'/%3E%3C/g%3E%3C/svg%3E");background-color:currentColor;display:inline-block;-webkit-mask-size:100% 100%;mask-size:100% 100%;-webkit-mask-repeat:no-repeat;mask-repeat:no-repeat}.i-tabler-link{width:1em;height:1em;-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);mask-image:var(--svg);--svg:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' width='24' height='24'%3E%3Cpath fill='none' stroke='black' stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='m9 15l6-6m-4-3l.463-.536a5 5 0 0 1 7.071 7.072L18 13m-5 5l-.397.534a5.07 5.07 0 0 1-7.127 0a4.97 4.97 0 0 1 0-7.071L6 11'/%3E%3C/svg%3E");background-color:currentColor;display:inline-block;-webkit-mask-size:100% 100%;mask-size:100% 100%;-webkit-mask-repeat:no-repeat;mask-repeat:no-repeat}.i-tabler-lock{width:1em;height:1em;-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);mask-image:var(--svg);--svg:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' width='24' height='24'%3E%3Cg fill='none' stroke='black' stroke-linecap='round' stroke-linejoin='round' stroke-width='2'%3E%3Cpath d='M5 13a2 2 0 0 1 2-2h10a2 2 0 0 1 2 2v6a2 2 0 0 1-2 2H7a2 2 0 0 1-2-2z'/%3E%3Cpath d='M11 16a1 1 0 1 0 2 0a1 1 0 0 0-2 0m-3-5V7a4 4 0 1 1 8 0v4'/%3E%3C/g%3E%3C/svg%3E");background-color:currentColor;display:inline-block;-webkit-mask-size:100% 100%;mask-size:100% 100%;-webkit-mask-repeat:no-repeat;mask-repeat:no-repeat}.i-tabler-logout{width:1em;height:1em;-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);mask-image:var(--svg);--svg:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' width='24' height='24'%3E%3Cg fill='none' stroke='black' stroke-linecap='round' stroke-linejoin='round' stroke-width='2'%3E%3Cpath d='M14 8V6a2 2 0 0 0-2-2H5a2 2 0 0 0-2 2v12a2 2 0 0 0 2 2h7a2 2 0 0 0 2-2v-2'/%3E%3Cpath d='M9 12h12l-3-3m0 6l3-3'/%3E%3C/g%3E%3C/svg%3E");background-color:currentColor;display:inline-block;-webkit-mask-size:100% 100%;mask-size:100% 100%;-webkit-mask-repeat:no-repeat;mask-repeat:no-repeat}.i-tabler-mail{width:1em;height:1em;-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);mask-image:var(--svg);--svg:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' width='24' height='24'%3E%3Cg fill='none' stroke='black' stroke-linecap='round' stroke-linejoin='round' stroke-width='2'%3E%3Cpath d='M3 7a2 2 0 0 1 2-2h14a2 2 0 0 1 2 2v10a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2z'/%3E%3Cpath d='m3 7l9 6l9-6'/%3E%3C/g%3E%3C/svg%3E");background-color:currentColor;display:inline-block;-webkit-mask-size:100% 100%;mask-size:100% 100%;-webkit-mask-repeat:no-repeat;mask-repeat:no-repeat}.i-tabler-menu{width:1em;height:1em;-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);mask-image:var(--svg);--svg:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' width='24' height='24'%3E%3Cpath fill='none' stroke='black' stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='M4 8h16M4 16h16'/%3E%3C/svg%3E");background-color:currentColor;display:inline-block;-webkit-mask-size:100% 100%;mask-size:100% 100%;-webkit-mask-repeat:no-repeat;mask-repeat:no-repeat}.i-tabler-message-circle{width:1em;height:1em;-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);mask-image:var(--svg);--svg:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' width='24' height='24'%3E%3Cpath fill='none' stroke='black' stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='m3 20l1.3-3.9C1.976 12.663 2.874 8.228 6.4 5.726c3.526-2.501 8.59-2.296 11.845.48c3.255 2.777 3.695 7.266 1.029 10.501S11.659 20.922 7.7 19z'/%3E%3C/svg%3E");background-color:currentColor;display:inline-block;-webkit-mask-size:100% 100%;mask-size:100% 100%;-webkit-mask-repeat:no-repeat;mask-repeat:no-repeat}.i-tabler-microphone{width:1em;height:1em;-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);mask-image:var(--svg);--svg:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' width='24' height='24'%3E%3Cg fill='none' stroke='black' stroke-linecap='round' stroke-linejoin='round' stroke-width='2'%3E%3Cpath d='M9 5a3 3 0 0 1 3-3a3 3 0 0 1 3 3v5a3 3 0 0 1-3 3a3 3 0 0 1-3-3z'/%3E%3Cpath d='M5 10a7 7 0 0 0 14 0M8 21h8m-4-4v4'/%3E%3C/g%3E%3C/svg%3E");background-color:currentColor;display:inline-block;-webkit-mask-size:100% 100%;mask-size:100% 100%;-webkit-mask-repeat:no-repeat;mask-repeat:no-repeat}.i-tabler-microphone-filled{width:1em;height:1em;-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);mask-image:var(--svg);--svg:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' width='24' height='24'%3E%3Cpath fill='black' d='M19 9a1 1 0 0 1 1 1a8 8 0 0 1-6.999 7.938L13 20h3a1 1 0 0 1 0 2H8a1 1 0 0 1 0-2h3v-2.062A8 8 0 0 1 4 10a1 1 0 1 1 2 0a6 6 0 0 0 12 0a1 1 0 0 1 1-1m-7-8a4 4 0 0 1 4 4v5a4 4 0 1 1-8 0V5a4 4 0 0 1 4-4'/%3E%3C/svg%3E");background-color:currentColor;display:inline-block;-webkit-mask-size:100% 100%;mask-size:100% 100%;-webkit-mask-repeat:no-repeat;mask-repeat:no-repeat}.i-tabler-microphone-off{width:1em;height:1em;-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);mask-image:var(--svg);--svg:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' width='24' height='24'%3E%3Cg fill='none' stroke='black' stroke-linecap='round' stroke-linejoin='round' stroke-width='2'%3E%3Cpath d='m3 3l18 18M9 5a3 3 0 0 1 6 0v5a3 3 0 0 1-.13.874m-2 2A3 3 0 0 1 9 10.002v-1'/%3E%3Cpath d='M5 10a7 7 0 0 0 10.846 5.85m2-2A6.97 6.97 0 0 0 18.998 10M8 21h8m-4-4v4'/%3E%3C/g%3E%3C/svg%3E");background-color:currentColor;display:inline-block;-webkit-mask-size:100% 100%;mask-size:100% 100%;-webkit-mask-repeat:no-repeat;mask-repeat:no-repeat}.i-tabler-phone{width:1em;height:1em;-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);mask-image:var(--svg);--svg:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' width='24' height='24'%3E%3Cpath fill='none' stroke='black' stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='M5 4h4l2 5l-2.5 1.5a11 11 0 0 0 5 5L15 13l5 2v4a2 2 0 0 1-2 2A16 16 0 0 1 3 6a2 2 0 0 1 2-2'/%3E%3C/svg%3E");background-color:currentColor;display:inline-block;-webkit-mask-size:100% 100%;mask-size:100% 100%;-webkit-mask-repeat:no-repeat;mask-repeat:no-repeat}.i-tabler-phone-off{width:1em;height:1em;-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);mask-image:var(--svg);--svg:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' width='24' height='24'%3E%3Cpath fill='none' stroke='black' stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='M3 21L21 3M5.831 14.161A15.95 15.95 0 0 1 3 6a2 2 0 0 1 2-2h4l2 5l-2.5 1.5q.162.33.345.645m1.751 2.277A11 11 0 0 0 13.5 15.5L15 13l5 2v4a2 2 0 0 1-2 2a15.96 15.96 0 0 1-10.344-4.657'/%3E%3C/svg%3E");background-color:currentColor;display:inline-block;-webkit-mask-size:100% 100%;mask-size:100% 100%;-webkit-mask-repeat:no-repeat;mask-repeat:no-repeat}.i-tabler-player-stop-filled{width:1em;height:1em;-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);mask-image:var(--svg);--svg:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' width='24' height='24'%3E%3Cpath fill='black' d='M17 4H7a3 3 0 0 0-3 3v10a3 3 0 0 0 3 3h10a3 3 0 0 0 3-3V7a3 3 0 0 0-3-3'/%3E%3C/svg%3E");background-color:currentColor;display:inline-block;-webkit-mask-size:100% 100%;mask-size:100% 100%;-webkit-mask-repeat:no-repeat;mask-repeat:no-repeat}.i-tabler-plus{width:1em;height:1em;-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);mask-image:var(--svg);--svg:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' width='24' height='24'%3E%3Cpath fill='none' stroke='black' stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='M12 5v14m-7-7h14'/%3E%3C/svg%3E");background-color:currentColor;display:inline-block;-webkit-mask-size:100% 100%;mask-size:100% 100%;-webkit-mask-repeat:no-repeat;mask-repeat:no-repeat}.i-tabler-share{width:1em;height:1em;-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);mask-image:var(--svg);--svg:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' width='24' height='24'%3E%3Cpath fill='none' stroke='black' stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='M3 12a3 3 0 1 0 6 0a3 3 0 1 0-6 0m12-6a3 3 0 1 0 6 0a3 3 0 1 0-6 0m0 12a3 3 0 1 0 6 0a3 3 0 1 0-6 0m-6.3-7.3l6.6-3.4m-6.6 6l6.6 3.4'/%3E%3C/svg%3E");background-color:currentColor;display:inline-block;-webkit-mask-size:100% 100%;mask-size:100% 100%;-webkit-mask-repeat:no-repeat;mask-repeat:no-repeat}.i-tabler-share-2{width:1em;height:1em;-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);mask-image:var(--svg);--svg:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' width='24' height='24'%3E%3Cpath fill='none' stroke='black' stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='M8 9H7a2 2 0 0 0-2 2v8a2 2 0 0 0 2 2h10a2 2 0 0 0 2-2v-8a2 2 0 0 0-2-2h-1m-4 5V3M9 6l3-3l3 3'/%3E%3C/svg%3E");background-color:currentColor;display:inline-block;-webkit-mask-size:100% 100%;mask-size:100% 100%;-webkit-mask-repeat:no-repeat;mask-repeat:no-repeat}.i-tabler-sparkles{width:1em;height:1em;-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);mask-image:var(--svg);--svg:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' width='24' height='24'%3E%3Cpath fill='none' stroke='black' stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='M16 18a2 2 0 0 1 2 2a2 2 0 0 1 2-2a2 2 0 0 1-2-2a2 2 0 0 1-2 2m0-12a2 2 0 0 1 2 2a2 2 0 0 1 2-2a2 2 0 0 1-2-2a2 2 0 0 1-2 2M9 18a6 6 0 0 1 6-6a6 6 0 0 1-6-6a6 6 0 0 1-6 6a6 6 0 0 1 6 6'/%3E%3C/svg%3E");background-color:currentColor;display:inline-block;-webkit-mask-size:100% 100%;mask-size:100% 100%;-webkit-mask-repeat:no-repeat;mask-repeat:no-repeat}.i-tabler-tool{width:1em;height:1em;-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);mask-image:var(--svg);--svg:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' width='24' height='24'%3E%3Cpath fill='none' stroke='black' stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='M7 10h3V7L6.5 3.5a6 6 0 0 1 8 8l6 6a2 2 0 0 1-3 3l-6-6a6 6 0 0 1-8-8z'/%3E%3C/svg%3E");background-color:currentColor;display:inline-block;-webkit-mask-size:100% 100%;mask-size:100% 100%;-webkit-mask-repeat:no-repeat;mask-repeat:no-repeat}.i-tabler-trash{width:1em;height:1em;-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);mask-image:var(--svg);--svg:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' width='24' height='24'%3E%3Cpath fill='none' stroke='black' stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='M4 7h16m-10 4v6m4-6v6M5 7l1 12a2 2 0 0 0 2 2h8a2 2 0 0 0 2-2l1-12M9 7V4a1 1 0 0 1 1-1h4a1 1 0 0 1 1 1v3'/%3E%3C/svg%3E");background-color:currentColor;display:inline-block;-webkit-mask-size:100% 100%;mask-size:100% 100%;-webkit-mask-repeat:no-repeat;mask-repeat:no-repeat}.i-tabler-user{width:1em;height:1em;-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);mask-image:var(--svg);--svg:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' width='24' height='24'%3E%3Cpath fill='none' stroke='black' stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='M8 7a4 4 0 1 0 8 0a4 4 0 0 0-8 0M6 21v-2a4 4 0 0 1 4-4h4a4 4 0 0 1 4 4v2'/%3E%3C/svg%3E");background-color:currentColor;display:inline-block;-webkit-mask-size:100% 100%;mask-size:100% 100%;-webkit-mask-repeat:no-repeat;mask-repeat:no-repeat}.i-tabler-user-circle{width:1em;height:1em;-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);mask-image:var(--svg);--svg:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' width='24' height='24'%3E%3Cg fill='none' stroke='black' stroke-linecap='round' stroke-linejoin='round' stroke-width='2'%3E%3Cpath d='M3 12a9 9 0 1 0 18 0a9 9 0 1 0-18 0'/%3E%3Cpath d='M9 10a3 3 0 1 0 6 0a3 3 0 1 0-6 0m-2.832 8.849A4 4 0 0 1 10 16h4a4 4 0 0 1 3.834 2.855'/%3E%3C/g%3E%3C/svg%3E");background-color:currentColor;display:inline-block;-webkit-mask-size:100% 100%;mask-size:100% 100%;-webkit-mask-repeat:no-repeat;mask-repeat:no-repeat}.i-tabler-user-square-rounded{width:1em;height:1em;-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);mask-image:var(--svg);--svg:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' width='24' height='24'%3E%3Cg fill='none' stroke='black' stroke-linecap='round' stroke-linejoin='round' stroke-width='2'%3E%3Cpath d='M12 13a3 3 0 1 0 0-6a3 3 0 0 0 0 6'/%3E%3Cpath d='M12 3c7.2 0 9 1.8 9 9s-1.8 9-9 9s-9-1.8-9-9s1.8-9 9-9'/%3E%3Cpath d='M6 20.05V20a4 4 0 0 1 4-4h4a4 4 0 0 1 4 4v.05'/%3E%3C/g%3E%3C/svg%3E");background-color:currentColor;display:inline-block;-webkit-mask-size:100% 100%;mask-size:100% 100%;-webkit-mask-repeat:no-repeat;mask-repeat:no-repeat}.i-tabler-users{width:1em;height:1em;-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);mask-image:var(--svg);--svg:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' width='24' height='24'%3E%3Cpath fill='none' stroke='black' stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='M5 7a4 4 0 1 0 8 0a4 4 0 1 0-8 0M3 21v-2a4 4 0 0 1 4-4h4a4 4 0 0 1 4 4v2m1-17.87a4 4 0 0 1 0 7.75M21 21v-2a4 4 0 0 0-3-3.85'/%3E%3C/svg%3E");background-color:currentColor;display:inline-block;-webkit-mask-size:100% 100%;mask-size:100% 100%;-webkit-mask-repeat:no-repeat;mask-repeat:no-repeat}.i-tabler-world{width:1em;height:1em;-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);mask-image:var(--svg);--svg:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' width='24' height='24'%3E%3Cg fill='none' stroke='black' stroke-linecap='round' stroke-linejoin='round' stroke-width='2'%3E%3Cpath d='M3 12a9 9 0 1 0 18 0a9 9 0 0 0-18 0m.6-3h16.8M3.6 15h16.8'/%3E%3Cpath d='M11.5 3a17 17 0 0 0 0 18m1-18a17 17 0 0 1 0 18'/%3E%3C/g%3E%3C/svg%3E");background-color:currentColor;display:inline-block;-webkit-mask-size:100% 100%;mask-size:100% 100%;-webkit-mask-repeat:no-repeat;mask-repeat:no-repeat}.i-tabler-x{width:1em;height:1em;-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);mask-image:var(--svg);--svg:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' width='24' height='24'%3E%3Cpath fill='none' stroke='black' stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='M18 6L6 18M6 6l12 12'/%3E%3C/svg%3E");background-color:currentColor;display:inline-block;-webkit-mask-size:100% 100%;mask-size:100% 100%;-webkit-mask-repeat:no-repeat;mask-repeat:no-repeat}.line-clamp-1{-webkit-line-clamp:1;-webkit-box-orient:vertical;display:-webkit-box;overflow:hidden}.line-clamp-2{-webkit-line-clamp:2;-webkit-box-orient:vertical;display:-webkit-box;overflow:hidden}.block{display:block}.flex{display:flex}.grid{display:grid}.hidden{display:none}.inline{display:inline}.inline-flex{display:inline-flex}.table{display:table}.size-1\\.5{width:calc(var(--spacing) * 1.5);height:calc(var(--spacing) * 1.5)}.size-2{width:calc(var(--spacing) * 2);height:calc(var(--spacing) * 2)}.size-2\\.5{width:calc(var(--spacing) * 2.5);height:calc(var(--spacing) * 2.5)}.size-3{width:calc(var(--spacing) * 3);height:calc(var(--spacing) * 3)}.size-3\\.5{width:calc(var(--spacing) * 3.5);height:calc(var(--spacing) * 3.5)}.size-4{width:calc(var(--spacing) * 4);height:calc(var(--spacing) * 4)}.size-5{width:calc(var(--spacing) * 5);height:calc(var(--spacing) * 5)}.size-6{width:calc(var(--spacing) * 6);height:calc(var(--spacing) * 6)}.size-7{width:calc(var(--spacing) * 7);height:calc(var(--spacing) * 7)}.size-8{width:calc(var(--spacing) * 8);height:calc(var(--spacing) * 8)}.size-9{width:calc(var(--spacing) * 9);height:calc(var(--spacing) * 9)}.size-10{width:calc(var(--spacing) * 10);height:calc(var(--spacing) * 10)}.size-12{width:calc(var(--spacing) * 12);height:calc(var(--spacing) * 12)}.size-14{width:calc(var(--spacing) * 14);height:calc(var(--spacing) * 14)}.size-16{width:calc(var(--spacing) * 16);height:calc(var(--spacing) * 16)}.size-20{width:calc(var(--spacing) * 20);height:calc(var(--spacing) * 20)}.size-32{width:calc(var(--spacing) * 32);height:calc(var(--spacing) * 32)}.size-\\[1\\.1em\\]{width:1.1em;height:1.1em}.size-\\[9px\\]{width:9px;height:9px}.size-\\[13px\\]{width:13px;height:13px}.size-\\[15px\\]{width:15px;height:15px}.size-\\[17px\\]{width:17px;height:17px}.size-\\[18px\\]{width:18px;height:18px}.size-\\[25px\\]{width:25px;height:25px}.size-\\[36\\%\\]{width:36%;height:36%}.size-full{width:100%;height:100%}.h-1\\.5{height:calc(var(--spacing) * 1.5)}.h-2{height:calc(var(--spacing) * 2)}.h-4{height:calc(var(--spacing) * 4)}.h-10{height:calc(var(--spacing) * 10)}.h-11{height:calc(var(--spacing) * 11)}.h-14{height:calc(var(--spacing) * 14)}.h-16{height:calc(var(--spacing) * 16)}.h-20{height:calc(var(--spacing) * 20)}.h-\\[17px\\]{height:17px}.h-\\[28px\\]{height:28px}.h-\\[38px\\]{height:38px}.h-\\[60px\\]{height:60px}.h-\\[80px\\]{height:80px}.h-\\[80vh\\]{height:80vh}.h-\\[600px\\]{height:600px}.h-\\[min\\(600px\\,calc\\(100vh-4rem\\)\\)\\]{height:min(600px,100vh - 4rem)}.h-auto{height:auto}.h-dvh{height:100dvh}.h-full{height:100%}.h-px{height:1px}.max-h-48{max-height:calc(var(--spacing) * 48)}.max-h-\\[300px\\]{max-height:300px}.max-h-\\[calc\\(100vh-48px\\)\\]{max-height:calc(100vh - 48px)}.min-h-0{min-height:0}.min-h-5{min-height:calc(var(--spacing) * 5)}.min-h-11{min-height:calc(var(--spacing) * 11)}.min-h-\\[20px\\]{min-height:20px}.min-h-full{min-height:100%}.w-0{width:0}.w-5{width:calc(var(--spacing) * 5)}.w-16{width:calc(var(--spacing) * 16)}.w-20{width:calc(var(--spacing) * 20)}.w-96{width:calc(var(--spacing) * 96)}.w-\\[2px\\]{width:2px}.w-\\[3px\\]{width:3px}.w-\\[5px\\]{width:5px}.w-\\[28px\\]{width:28px}.w-\\[46ch\\]{width:46ch}.w-\\[60px\\]{width:60px}.w-\\[80\\%\\]{width:80%}.w-\\[80px\\]{width:80px}.w-\\[min\\(400px\\,calc\\(100vw-2rem\\)\\)\\]{width:min(400px,100vw - 2rem)}.w-fit{width:-moz-fit-content;width:fit-content}.w-full{width:100%}.w-px{width:1px}.max-w-4xl{max-width:var(--container-4xl)}.max-w-20{max-width:calc(var(--spacing) * 20)}.max-w-\\[85\\%\\]{max-width:85%}.max-w-\\[88\\%\\]{max-width:88%}.max-w-\\[240px\\]{max-width:240px}.max-w-\\[255px\\]{max-width:255px}.max-w-\\[260px\\]{max-width:260px}.max-w-\\[300px\\]{max-width:300px}.max-w-\\[480px\\]{max-width:480px}.max-w-\\[640px\\]{max-width:640px}.max-w-\\[900px\\]{max-width:900px}.max-w-\\[calc\\(100vw-48px\\)\\]{max-width:calc(100vw - 48px)}.max-w-full{max-width:100%}.max-w-md{max-width:var(--container-md)}.max-w-screen-md{max-width:var(--breakpoint-md)}.max-w-sm{max-width:var(--container-sm)}.max-w-xs{max-width:var(--container-xs)}.min-w-0{min-width:0}.flex-1{flex:1}.flex-none{flex:none}.flex-shrink-0,.shrink-0{flex-shrink:0}.flex-grow-0{flex-grow:0}.grow{flex-grow:1}.basis-0{flex-basis:0}.origin-center{transform-origin:50%}.-translate-x-1\\/2{--tw-translate-x:calc(calc(1 / 2 * 100%) * -1);translate:var(--tw-translate-x) var(--tw-translate-y)}.-translate-x-4{--tw-translate-x:calc(var(--spacing) * -4);translate:var(--tw-translate-x) var(--tw-translate-y)}.-translate-x-\\[30px\\]{--tw-translate-x:calc(30px * -1);translate:var(--tw-translate-x) var(--tw-translate-y)}.-translate-x-full{--tw-translate-x:-100%;translate:var(--tw-translate-x) var(--tw-translate-y)}.translate-x-0{--tw-translate-x:0px;translate:var(--tw-translate-x) var(--tw-translate-y)}.translate-x-4{--tw-translate-x:calc(var(--spacing) * 4);translate:var(--tw-translate-x) var(--tw-translate-y)}.translate-x-full{--tw-translate-x:100%;translate:var(--tw-translate-x) var(--tw-translate-y)}.-translate-y-1\\/2{--tw-translate-y:calc(calc(1 / 2 * 100%) * -1);translate:var(--tw-translate-x) var(--tw-translate-y)}.-translate-y-\\[30px\\]{--tw-translate-y:calc(30px * -1);translate:var(--tw-translate-x) var(--tw-translate-y)}.translate-y-0{--tw-translate-y:0px;translate:var(--tw-translate-x) var(--tw-translate-y)}.translate-y-2{--tw-translate-y:calc(var(--spacing) * 2);translate:var(--tw-translate-x) var(--tw-translate-y)}.translate-y-\\[30px\\]{--tw-translate-y:30px;translate:var(--tw-translate-x) var(--tw-translate-y)}.translate-y-full{--tw-translate-y:100%;translate:var(--tw-translate-x) var(--tw-translate-y)}.scale-0{--tw-scale-x:0%;--tw-scale-y:0%;--tw-scale-z:0%;scale:var(--tw-scale-x) var(--tw-scale-y)}.scale-75{--tw-scale-x:75%;--tw-scale-y:75%;--tw-scale-z:75%;scale:var(--tw-scale-x) var(--tw-scale-y)}.scale-95{--tw-scale-x:95%;--tw-scale-y:95%;--tw-scale-z:95%;scale:var(--tw-scale-x) var(--tw-scale-y)}.scale-100{--tw-scale-x:100%;--tw-scale-y:100%;--tw-scale-z:100%;scale:var(--tw-scale-x) var(--tw-scale-y)}.scale-110{--tw-scale-x:110%;--tw-scale-y:110%;--tw-scale-z:110%;scale:var(--tw-scale-x) var(--tw-scale-y)}.-rotate-45{rotate:-45deg}.rotate-0{rotate:0deg}.rotate-45{rotate:45deg}.transform{transform:var(--tw-rotate-x, ) var(--tw-rotate-y, ) var(--tw-rotate-z, ) var(--tw-skew-x, ) var(--tw-skew-y, )}.transform-gpu{transform:translateZ(0) var(--tw-rotate-x, ) var(--tw-rotate-y, ) var(--tw-rotate-z, ) var(--tw-skew-x, ) var(--tw-skew-y, )}.animate-ping{animation:var(--animate-ping)}.animate-pulse{animation:var(--animate-pulse)}.animate-spin{animation:var(--animate-spin)}.cursor-default{cursor:default}.cursor-not-allowed{cursor:not-allowed}.cursor-pointer{cursor:pointer}.cursor-text{cursor:text}.resize{resize:both}.\\[scrollbar-width\\:none\\]{scrollbar-width:none}.grid-cols-2{grid-template-columns:repeat(2,minmax(0,1fr))}.flex-col{flex-direction:column}.flex-row{flex-direction:row}.flex-wrap{flex-wrap:wrap}.place-items-center{place-items:center}.items-baseline{align-items:baseline}.items-center{align-items:center}.items-end{align-items:flex-end}.items-start{align-items:flex-start}.items-stretch{align-items:stretch}.\\[justify-content\\:safe_center\\]{justify-content:safe center}.justify-between{justify-content:space-between}.justify-center{justify-content:center}.justify-end{justify-content:flex-end}.justify-start{justify-content:flex-start}.justify-stretch{justify-content:stretch}.gap-0\\.5{gap:calc(var(--spacing) * .5)}.gap-1{gap:var(--spacing)}.gap-1\\.5{gap:calc(var(--spacing) * 1.5)}.gap-2{gap:calc(var(--spacing) * 2)}.gap-2\\.5{gap:calc(var(--spacing) * 2.5)}.gap-3{gap:calc(var(--spacing) * 3)}.gap-4{gap:calc(var(--spacing) * 4)}.gap-7{gap:calc(var(--spacing) * 7)}.gap-\\[2px\\]{gap:2px}.gap-\\[5px\\]{gap:5px}:where(.space-y-1>:not(:last-child)){--tw-space-y-reverse:0;margin-block-start:calc(var(--spacing) * var(--tw-space-y-reverse));margin-block-end:calc(var(--spacing) * calc(1 - var(--tw-space-y-reverse)))}:where(.space-y-2>:not(:last-child)){--tw-space-y-reverse:0;margin-block-start:calc(calc(var(--spacing) * 2) * var(--tw-space-y-reverse));margin-block-end:calc(calc(var(--spacing) * 2) * calc(1 - var(--tw-space-y-reverse)))}:where(.space-y-3>:not(:last-child)){--tw-space-y-reverse:0;margin-block-start:calc(calc(var(--spacing) * 3) * var(--tw-space-y-reverse));margin-block-end:calc(calc(var(--spacing) * 3) * calc(1 - var(--tw-space-y-reverse)))}:where(.space-y-4>:not(:last-child)){--tw-space-y-reverse:0;margin-block-start:calc(calc(var(--spacing) * 4) * var(--tw-space-y-reverse));margin-block-end:calc(calc(var(--spacing) * 4) * calc(1 - var(--tw-space-y-reverse)))}:where(.space-y-6>:not(:last-child)){--tw-space-y-reverse:0;margin-block-start:calc(calc(var(--spacing) * 6) * var(--tw-space-y-reverse));margin-block-end:calc(calc(var(--spacing) * 6) * calc(1 - var(--tw-space-y-reverse)))}:where(.space-y-12>:not(:last-child)){--tw-space-y-reverse:0;margin-block-start:calc(calc(var(--spacing) * 12) * var(--tw-space-y-reverse));margin-block-end:calc(calc(var(--spacing) * 12) * calc(1 - var(--tw-space-y-reverse)))}.gap-x-2{column-gap:calc(var(--spacing) * 2)}.gap-x-2\\.5{column-gap:calc(var(--spacing) * 2.5)}.gap-x-4{column-gap:calc(var(--spacing) * 4)}.gap-y-1\\.5{row-gap:calc(var(--spacing) * 1.5)}.self-end{align-self:flex-end}.self-start{align-self:flex-start}.self-stretch{align-self:stretch}.truncate{text-overflow:ellipsis;white-space:nowrap;overflow:hidden}.overflow-hidden{overflow:hidden}.overflow-scroll{overflow:scroll}.overflow-visible{overflow:visible}.overflow-x-auto{overflow-x:auto}.overflow-x-hidden{overflow-x:hidden}.overflow-y-auto{overflow-y:auto}.overscroll-contain{overscroll-behavior:contain}.rounded-2xl{border-radius:var(--radius-2xl)}.rounded-3xl{border-radius:var(--radius-3xl)}.rounded-\\[2px\\]{border-radius:2px}.rounded-\\[5px\\]{border-radius:5px}.rounded-\\[14px\\]{border-radius:14px}.rounded-\\[20px\\]{border-radius:20px}.rounded-full{border-radius:2147483647px}.rounded-lg{border-radius:var(--radius-lg)}.rounded-xl{border-radius:var(--radius-xl)}.border{border-style:var(--tw-border-style);border-width:1px}.border-2{border-style:var(--tw-border-style);border-width:2px}.border-4{border-style:var(--tw-border-style);border-width:4px}.border-t{border-top-style:var(--tw-border-style);border-top-width:1px}.border-b{border-bottom-style:var(--tw-border-style);border-bottom-width:1px}.border-b-2{border-bottom-style:var(--tw-border-style);border-bottom-width:2px}.border-l{border-left-style:var(--tw-border-style);border-left-width:1px}.border-dashed{--tw-border-style:dashed;border-style:dashed}.border-black\\/10{border-color:#0000001a}@supports (color:color-mix(in lab, red, red)){.border-black\\/10{border-color:color-mix(in oklab, var(--color-black) 10%, transparent)}}.border-green-400{border-color:var(--color-green-400)}.border-primary-400{border-color:var(--color-primary-400)}.border-primary-500\\/40{border-color:var(--color-primary-500)}@supports (color:color-mix(in lab, red, red)){.border-primary-500\\/40{border-color:color-mix(in oklab, var(--color-primary-500) 40%, transparent)}}.border-red-400{border-color:var(--color-red-400)}.border-slate-200{border-color:var(--color-slate-200)}.border-theme-100{border-color:var(--color-theme-100)}.border-theme-200{border-color:var(--color-theme-200)}.border-theme-300{border-color:var(--color-theme-300)}.border-theme-400{border-color:var(--color-theme-400)}.border-theme-950\\/\\[0\\.06\\]{border-color:var(--color-theme-950)}@supports (color:color-mix(in lab, red, red)){.border-theme-950\\/\\[0\\.06\\]{border-color:color-mix(in oklab, var(--color-theme-950) 6%, transparent)}}.border-transparent{border-color:#0000}.border-white{border-color:var(--color-white)}.border-white\\/0{border-color:#0000}@supports (color:color-mix(in lab, red, red)){.border-white\\/0{border-color:color-mix(in oklab, var(--color-white) 0%, transparent)}}.border-white\\/10{border-color:#ffffff1a}@supports (color:color-mix(in lab, red, red)){.border-white\\/10{border-color:color-mix(in oklab, var(--color-white) 10%, transparent)}}.border-white\\/20{border-color:#fff3}@supports (color:color-mix(in lab, red, red)){.border-white\\/20{border-color:color-mix(in oklab, var(--color-white) 20%, transparent)}}.border-white\\/25{border-color:#ffffff40}@supports (color:color-mix(in lab, red, red)){.border-white\\/25{border-color:color-mix(in oklab, var(--color-white) 25%, transparent)}}.border-t-primary-500{border-top-color:var(--color-primary-500)}.bg-\\[\\#0A1522\\]{background-color:#0a1522}.bg-\\[\\#050F19\\]{background-color:#050f19}.bg-amber-500{background-color:var(--color-amber-500)}.bg-black\\/30{background-color:#0000004d}@supports (color:color-mix(in lab, red, red)){.bg-black\\/30{background-color:color-mix(in oklab, var(--color-black) 30%, transparent)}}.bg-black\\/50{background-color:#00000080}@supports (color:color-mix(in lab, red, red)){.bg-black\\/50{background-color:color-mix(in oklab, var(--color-black) 50%, transparent)}}.bg-current{background-color:currentColor}.bg-green-500{background-color:var(--color-green-500)}.bg-green-600{background-color:var(--color-green-600)}.bg-primary-500,.bg-primary-500\\/20{background-color:var(--color-primary-500)}@supports (color:color-mix(in lab, red, red)){.bg-primary-500\\/20{background-color:color-mix(in oklab, var(--color-primary-500) 20%, transparent)}}.bg-primary-600{background-color:var(--color-primary-600)}.bg-red-500{background-color:var(--color-red-500)}.bg-red-500\\/20{background-color:#fb2c3633}@supports (color:color-mix(in lab, red, red)){.bg-red-500\\/20{background-color:color-mix(in oklab, var(--color-red-500) 20%, transparent)}}.bg-red-600{background-color:var(--color-red-600)}.bg-slate-950{background-color:var(--color-slate-950)}.bg-theme-0{background-color:var(--color-theme-0)}.bg-theme-25{background-color:var(--color-theme-25)}.bg-theme-50{background-color:var(--color-theme-50)}.bg-theme-100{background-color:var(--color-theme-100)}.bg-theme-200,.bg-theme-200\\/70{background-color:var(--color-theme-200)}@supports (color:color-mix(in lab, red, red)){.bg-theme-200\\/70{background-color:color-mix(in oklab, var(--color-theme-200) 70%, transparent)}}.bg-theme-300{background-color:var(--color-theme-300)}.bg-theme-400{background-color:var(--color-theme-400)}.bg-theme-800,.bg-theme-800\\/60{background-color:var(--color-theme-800)}@supports (color:color-mix(in lab, red, red)){.bg-theme-800\\/60{background-color:color-mix(in oklab, var(--color-theme-800) 60%, transparent)}}.bg-theme-900{background-color:var(--color-theme-900)}.bg-transparent{background-color:#0000}.bg-white{background-color:var(--color-white)}.bg-white\\/5{background-color:#ffffff0d}@supports (color:color-mix(in lab, red, red)){.bg-white\\/5{background-color:color-mix(in oklab, var(--color-white) 5%, transparent)}}.bg-white\\/10{background-color:#ffffff1a}@supports (color:color-mix(in lab, red, red)){.bg-white\\/10{background-color:color-mix(in oklab, var(--color-white) 10%, transparent)}}.bg-white\\/15{background-color:#ffffff26}@supports (color:color-mix(in lab, red, red)){.bg-white\\/15{background-color:color-mix(in oklab, var(--color-white) 15%, transparent)}}.bg-white\\/50{background-color:#ffffff80}@supports (color:color-mix(in lab, red, red)){.bg-white\\/50{background-color:color-mix(in oklab, var(--color-white) 50%, transparent)}}.bg-gradient-to-b{--tw-gradient-position:to bottom in oklab;background-image:linear-gradient(var(--tw-gradient-stops))}.bg-gradient-to-br{--tw-gradient-position:to bottom right in oklab;background-image:linear-gradient(var(--tw-gradient-stops))}.bg-gradient-to-t{--tw-gradient-position:to top in oklab;background-image:linear-gradient(var(--tw-gradient-stops))}.from-\\[\\#050F19\\]\\/82{--tw-gradient-from:#050f19d1;--tw-gradient-stops:var(--tw-gradient-via-stops,var(--tw-gradient-position), var(--tw-gradient-from) var(--tw-gradient-from-position), var(--tw-gradient-to) var(--tw-gradient-to-position))}@supports (color:color(display-p3 0 0 0)){.from-\\[\\#050F19\\]\\/82{--tw-gradient-from:color(display-p3 .0270841 .0577423 .0947219/.82)}}@supports (color:lab(0% 0 0)){.from-\\[\\#050F19\\]\\/82{--tw-gradient-from:lab(3.9307% -1.22581 -7.24003/.82)}}.from-black\\/70{--tw-gradient-from:#000000b3}@supports (color:color-mix(in lab, red, red)){.from-black\\/70{--tw-gradient-from:color-mix(in oklab, var(--color-black) 70%, transparent)}}.from-black\\/70{--tw-gradient-stops:var(--tw-gradient-via-stops,var(--tw-gradient-position), var(--tw-gradient-from) var(--tw-gradient-from-position), var(--tw-gradient-to) var(--tw-gradient-to-position))}.from-black\\/80{--tw-gradient-from:#000c}@supports (color:color-mix(in lab, red, red)){.from-black\\/80{--tw-gradient-from:color-mix(in oklab, var(--color-black) 80%, transparent)}}.from-black\\/80{--tw-gradient-stops:var(--tw-gradient-via-stops,var(--tw-gradient-position), var(--tw-gradient-from) var(--tw-gradient-from-position), var(--tw-gradient-to) var(--tw-gradient-to-position))}.from-black\\/90{--tw-gradient-from:#000000e6}@supports (color:color-mix(in lab, red, red)){.from-black\\/90{--tw-gradient-from:color-mix(in oklab, var(--color-black) 90%, transparent)}}.from-black\\/90{--tw-gradient-stops:var(--tw-gradient-via-stops,var(--tw-gradient-position), var(--tw-gradient-from) var(--tw-gradient-from-position), var(--tw-gradient-to) var(--tw-gradient-to-position))}.from-theme-25{--tw-gradient-from:var(--color-theme-25);--tw-gradient-stops:var(--tw-gradient-via-stops,var(--tw-gradient-position), var(--tw-gradient-from) var(--tw-gradient-from-position), var(--tw-gradient-to) var(--tw-gradient-to-position))}.from-theme-800{--tw-gradient-from:var(--color-theme-800);--tw-gradient-stops:var(--tw-gradient-via-stops,var(--tw-gradient-position), var(--tw-gradient-from) var(--tw-gradient-from-position), var(--tw-gradient-to) var(--tw-gradient-to-position))}.from-transparent{--tw-gradient-from:transparent;--tw-gradient-stops:var(--tw-gradient-via-stops,var(--tw-gradient-position), var(--tw-gradient-from) var(--tw-gradient-from-position), var(--tw-gradient-to) var(--tw-gradient-to-position))}.via-\\[\\#050F19\\]\\/90{--tw-gradient-via:#050f19e6;--tw-gradient-via-stops:var(--tw-gradient-position), var(--tw-gradient-from) var(--tw-gradient-from-position), var(--tw-gradient-via) var(--tw-gradient-via-position), var(--tw-gradient-to) var(--tw-gradient-to-position);--tw-gradient-stops:var(--tw-gradient-via-stops)}@supports (color:color(display-p3 0 0 0)){.via-\\[\\#050F19\\]\\/90{--tw-gradient-via:color(display-p3 .0270841 .0577423 .0947219/.9)}}@supports (color:lab(0% 0 0)){.via-\\[\\#050F19\\]\\/90{--tw-gradient-via:lab(3.9307% -1.22581 -7.24003/.9)}}.via-black\\/10{--tw-gradient-via:#0000001a}@supports (color:color-mix(in lab, red, red)){.via-black\\/10{--tw-gradient-via:color-mix(in oklab, var(--color-black) 10%, transparent)}}.via-black\\/10{--tw-gradient-via-stops:var(--tw-gradient-position), var(--tw-gradient-from) var(--tw-gradient-from-position), var(--tw-gradient-via) var(--tw-gradient-via-position), var(--tw-gradient-to) var(--tw-gradient-to-position);--tw-gradient-stops:var(--tw-gradient-via-stops)}.via-black\\/50{--tw-gradient-via:#00000080}@supports (color:color-mix(in lab, red, red)){.via-black\\/50{--tw-gradient-via:color-mix(in oklab, var(--color-black) 50%, transparent)}}.via-black\\/50{--tw-gradient-via-stops:var(--tw-gradient-position), var(--tw-gradient-from) var(--tw-gradient-from-position), var(--tw-gradient-via) var(--tw-gradient-via-position), var(--tw-gradient-to) var(--tw-gradient-to-position);--tw-gradient-stops:var(--tw-gradient-via-stops)}.via-black\\/60{--tw-gradient-via:#0009}@supports (color:color-mix(in lab, red, red)){.via-black\\/60{--tw-gradient-via:color-mix(in oklab, var(--color-black) 60%, transparent)}}.via-black\\/60{--tw-gradient-via-stops:var(--tw-gradient-position), var(--tw-gradient-from) var(--tw-gradient-from-position), var(--tw-gradient-via) var(--tw-gradient-via-position), var(--tw-gradient-to) var(--tw-gradient-to-position);--tw-gradient-stops:var(--tw-gradient-via-stops)}.via-black\\/90{--tw-gradient-via:#000000e6}@supports (color:color-mix(in lab, red, red)){.via-black\\/90{--tw-gradient-via:color-mix(in oklab, var(--color-black) 90%, transparent)}}.via-black\\/90{--tw-gradient-via-stops:var(--tw-gradient-position), var(--tw-gradient-from) var(--tw-gradient-from-position), var(--tw-gradient-via) var(--tw-gradient-via-position), var(--tw-gradient-to) var(--tw-gradient-to-position);--tw-gradient-stops:var(--tw-gradient-via-stops)}.to-\\[\\#050F19\\]\\/99{--tw-gradient-to:#050f19fc;--tw-gradient-stops:var(--tw-gradient-via-stops,var(--tw-gradient-position), var(--tw-gradient-from) var(--tw-gradient-from-position), var(--tw-gradient-to) var(--tw-gradient-to-position))}@supports (color:color(display-p3 0 0 0)){.to-\\[\\#050F19\\]\\/99{--tw-gradient-to:color(display-p3 .0270841 .0577423 .0947219/.99)}}@supports (color:lab(0% 0 0)){.to-\\[\\#050F19\\]\\/99{--tw-gradient-to:lab(3.9307% -1.22581 -7.24003/.99)}}.to-black\\/40{--tw-gradient-to:#0006}@supports (color:color-mix(in lab, red, red)){.to-black\\/40{--tw-gradient-to:color-mix(in oklab, var(--color-black) 40%, transparent)}}.to-black\\/40{--tw-gradient-stops:var(--tw-gradient-via-stops,var(--tw-gradient-position), var(--tw-gradient-from) var(--tw-gradient-from-position), var(--tw-gradient-to) var(--tw-gradient-to-position))}.to-black\\/80{--tw-gradient-to:#000c}@supports (color:color-mix(in lab, red, red)){.to-black\\/80{--tw-gradient-to:color-mix(in oklab, var(--color-black) 80%, transparent)}}.to-black\\/80{--tw-gradient-stops:var(--tw-gradient-via-stops,var(--tw-gradient-position), var(--tw-gradient-from) var(--tw-gradient-from-position), var(--tw-gradient-to) var(--tw-gradient-to-position))}.to-black\\/100{--tw-gradient-to:var(--color-black);--tw-gradient-stops:var(--tw-gradient-via-stops,var(--tw-gradient-position), var(--tw-gradient-from) var(--tw-gradient-from-position), var(--tw-gradient-to) var(--tw-gradient-to-position))}.to-theme-950{--tw-gradient-to:var(--color-theme-950);--tw-gradient-stops:var(--tw-gradient-via-stops,var(--tw-gradient-position), var(--tw-gradient-from) var(--tw-gradient-from-position), var(--tw-gradient-to) var(--tw-gradient-to-position))}.to-transparent{--tw-gradient-to:transparent;--tw-gradient-stops:var(--tw-gradient-via-stops,var(--tw-gradient-position), var(--tw-gradient-from) var(--tw-gradient-from-position), var(--tw-gradient-to) var(--tw-gradient-to-position))}.bg-cover{background-size:cover}.bg-center{background-position:50%}.bg-no-repeat{background-repeat:no-repeat}.object-cover{object-fit:cover}.p-0{padding:0}.p-2{padding:calc(var(--spacing) * 2)}.p-3{padding:calc(var(--spacing) * 3)}.p-4{padding:calc(var(--spacing) * 4)}.p-5{padding:calc(var(--spacing) * 5)}.p-6{padding:calc(var(--spacing) * 6)}.p-8{padding:calc(var(--spacing) * 8)}.p-24{padding:calc(var(--spacing) * 24)}.px-1{padding-inline:var(--spacing)}.px-2{padding-inline:calc(var(--spacing) * 2)}.px-2\\.5{padding-inline:calc(var(--spacing) * 2.5)}.px-3{padding-inline:calc(var(--spacing) * 3)}.px-3\\.5{padding-inline:calc(var(--spacing) * 3.5)}.px-4{padding-inline:calc(var(--spacing) * 4)}.px-5{padding-inline:calc(var(--spacing) * 5)}.px-6{padding-inline:calc(var(--spacing) * 6)}.px-8{padding-inline:calc(var(--spacing) * 8)}.px-9{padding-inline:calc(var(--spacing) * 9)}.px-14{padding-inline:calc(var(--spacing) * 14)}.py-0\\.5{padding-block:calc(var(--spacing) * .5)}.py-1{padding-block:var(--spacing)}.py-1\\.5{padding-block:calc(var(--spacing) * 1.5)}.py-2{padding-block:calc(var(--spacing) * 2)}.py-2\\.5{padding-block:calc(var(--spacing) * 2.5)}.py-3{padding-block:calc(var(--spacing) * 3)}.py-3\\.5{padding-block:calc(var(--spacing) * 3.5)}.py-4{padding-block:calc(var(--spacing) * 4)}.py-5{padding-block:calc(var(--spacing) * 5)}.py-6{padding-block:calc(var(--spacing) * 6)}.py-16{padding-block:calc(var(--spacing) * 16)}.pt-0{padding-top:0}.pt-0\\.5{padding-top:calc(var(--spacing) * .5)}.pt-1{padding-top:var(--spacing)}.pt-2{padding-top:calc(var(--spacing) * 2)}.pt-2\\.5{padding-top:calc(var(--spacing) * 2.5)}.pt-3{padding-top:calc(var(--spacing) * 3)}.pt-4{padding-top:calc(var(--spacing) * 4)}.pt-6{padding-top:calc(var(--spacing) * 6)}.pt-8{padding-top:calc(var(--spacing) * 8)}.pt-10{padding-top:calc(var(--spacing) * 10)}.pt-12{padding-top:calc(var(--spacing) * 12)}.pr-3{padding-right:calc(var(--spacing) * 3)}.pb-2{padding-bottom:calc(var(--spacing) * 2)}.pb-2\\.5{padding-bottom:calc(var(--spacing) * 2.5)}.pb-3\\.5{padding-bottom:calc(var(--spacing) * 3.5)}.pb-4{padding-bottom:calc(var(--spacing) * 4)}.pb-5{padding-bottom:calc(var(--spacing) * 5)}.pb-8{padding-bottom:calc(var(--spacing) * 8)}.pb-12{padding-bottom:calc(var(--spacing) * 12)}.pb-\\[120px\\]{padding-bottom:120px}.pb-\\[max\\(3rem\\,env\\(safe-area-inset-bottom\\)\\)\\]{padding-bottom:max(3rem, env(safe-area-inset-bottom))}.pb-\\[max\\(env\\(safe-area-inset-bottom\\)\\,1rem\\)\\]{padding-bottom:max(env(safe-area-inset-bottom), 1rem)}.pl-0\\.5{padding-left:calc(var(--spacing) * .5)}.pl-2{padding-left:calc(var(--spacing) * 2)}.pl-\\[22px\\]{padding-left:22px}.pl-\\[30px\\]{padding-left:30px}.text-center{text-align:center}.text-left{text-align:left}.font-mono{font-family:var(--font-mono)}.text-2xl{font-size:var(--text-2xl);line-height:var(--tw-leading,var(--text-2xl--line-height))}.text-3xl{font-size:var(--text-3xl);line-height:var(--tw-leading,var(--text-3xl--line-height))}.text-base{font-size:var(--text-base);line-height:var(--tw-leading,var(--text-base--line-height))}.text-lg{font-size:var(--text-lg);line-height:var(--tw-leading,var(--text-lg--line-height))}.text-sm{font-size:var(--text-sm);line-height:var(--tw-leading,var(--text-sm--line-height))}.text-xl{font-size:var(--text-xl);line-height:var(--tw-leading,var(--text-xl--line-height))}.text-xs{font-size:var(--text-xs);line-height:var(--tw-leading,var(--text-xs--line-height))}.text-\\[10\\.5px\\]{font-size:10.5px}.text-\\[10px\\]{font-size:10px}.text-\\[11\\.5px\\]{font-size:11.5px}.text-\\[11px\\]{font-size:11px}.text-\\[12px\\]{font-size:12px}.text-\\[13\\.5px\\]{font-size:13.5px}.text-\\[13px\\]{font-size:13px}.text-\\[14px\\]{font-size:14px}.text-\\[15px\\]{font-size:15px}.leading-\\[1\\.5\\]{--tw-leading:1.5;line-height:1.5}.leading-\\[1\\.55\\]{--tw-leading:1.55;line-height:1.55}.leading-none{--tw-leading:1;line-height:1}.leading-relaxed{--tw-leading:var(--leading-relaxed);line-height:var(--leading-relaxed)}.leading-snug{--tw-leading:var(--leading-snug);line-height:var(--leading-snug)}.leading-tight{--tw-leading:var(--leading-tight);line-height:var(--leading-tight)}.font-light{--tw-font-weight:var(--font-weight-light);font-weight:var(--font-weight-light)}.font-medium{--tw-font-weight:var(--font-weight-medium);font-weight:var(--font-weight-medium)}.font-semibold{--tw-font-weight:var(--font-weight-semibold);font-weight:var(--font-weight-semibold)}.tracking-\\[-0\\.006em\\]{--tw-tracking:-.006em;letter-spacing:-.006em}.tracking-\\[0\\.06em\\]{--tw-tracking:.06em;letter-spacing:.06em}.tracking-\\[0\\.35em\\]{--tw-tracking:.35em;letter-spacing:.35em}.tracking-wide{--tw-tracking:var(--tracking-wide);letter-spacing:var(--tracking-wide)}.tracking-widest{--tw-tracking:var(--tracking-widest);letter-spacing:var(--tracking-widest)}.text-pretty{text-wrap:pretty}.break-words{overflow-wrap:break-word}.whitespace-pre-wrap{white-space:pre-wrap}.text-\\[\\#050F19\\]{color:#050f19}.text-green-500{color:var(--color-green-500)}.text-green-600{color:var(--color-green-600)}.text-primary-300{color:var(--color-primary-300)}.text-primary-400{color:var(--color-primary-400)}.text-red-400{color:var(--color-red-400)}.text-red-500{color:var(--color-red-500)}.text-red-600{color:var(--color-red-600)}.text-slate-950{color:var(--color-slate-950)}.text-theme-0{color:var(--color-theme-0)}.text-theme-300{color:var(--color-theme-300)}.text-theme-400{color:var(--color-theme-400)}.text-theme-500{color:var(--color-theme-500)}.text-theme-600{color:var(--color-theme-600)}.text-theme-700{color:var(--color-theme-700)}.text-theme-800{color:var(--color-theme-800)}.text-theme-900{color:var(--color-theme-900)}.text-theme-950{color:var(--color-theme-950)}.text-white{color:var(--color-white)}.text-white\\/30{color:#ffffff4d}@supports (color:color-mix(in lab, red, red)){.text-white\\/30{color:color-mix(in oklab, var(--color-white) 30%, transparent)}}.text-white\\/35{color:#ffffff59}@supports (color:color-mix(in lab, red, red)){.text-white\\/35{color:color-mix(in oklab, var(--color-white) 35%, transparent)}}.text-white\\/40{color:#fff6}@supports (color:color-mix(in lab, red, red)){.text-white\\/40{color:color-mix(in oklab, var(--color-white) 40%, transparent)}}.text-white\\/45{color:#ffffff73}@supports (color:color-mix(in lab, red, red)){.text-white\\/45{color:color-mix(in oklab, var(--color-white) 45%, transparent)}}.text-white\\/50{color:#ffffff80}@supports (color:color-mix(in lab, red, red)){.text-white\\/50{color:color-mix(in oklab, var(--color-white) 50%, transparent)}}.text-white\\/55{color:#ffffff8c}@supports (color:color-mix(in lab, red, red)){.text-white\\/55{color:color-mix(in oklab, var(--color-white) 55%, transparent)}}.text-white\\/60{color:#fff9}@supports (color:color-mix(in lab, red, red)){.text-white\\/60{color:color-mix(in oklab, var(--color-white) 60%, transparent)}}.text-white\\/70{color:#ffffffb3}@supports (color:color-mix(in lab, red, red)){.text-white\\/70{color:color-mix(in oklab, var(--color-white) 70%, transparent)}}.text-white\\/80{color:#fffc}@supports (color:color-mix(in lab, red, red)){.text-white\\/80{color:color-mix(in oklab, var(--color-white) 80%, transparent)}}.text-white\\/85{color:#ffffffd9}@supports (color:color-mix(in lab, red, red)){.text-white\\/85{color:color-mix(in oklab, var(--color-white) 85%, transparent)}}.text-white\\/90{color:#ffffffe6}@supports (color:color-mix(in lab, red, red)){.text-white\\/90{color:color-mix(in oklab, var(--color-white) 90%, transparent)}}.text-white\\/95{color:#fffffff2}@supports (color:color-mix(in lab, red, red)){.text-white\\/95{color:color-mix(in oklab, var(--color-white) 95%, transparent)}}.uppercase{text-transform:uppercase}.tabular-nums{--tw-numeric-spacing:tabular-nums;font-variant-numeric:var(--tw-ordinal, ) var(--tw-slashed-zero, ) var(--tw-numeric-figure, ) var(--tw-numeric-spacing, ) var(--tw-numeric-fraction, )}.underline{text-decoration-line:underline}.underline-offset-2{text-underline-offset:2px}.placeholder-theme-300::placeholder{color:var(--color-theme-300)}.placeholder-theme-400::placeholder{color:var(--color-theme-400)}.placeholder-theme-500::placeholder{color:var(--color-theme-500)}.placeholder-white\\/50::placeholder{color:#ffffff80}@supports (color:color-mix(in lab, red, red)){.placeholder-white\\/50::placeholder{color:color-mix(in oklab, var(--color-white) 50%, transparent)}}.opacity-0{opacity:0}.opacity-40{opacity:.4}.opacity-50{opacity:.5}.opacity-60{opacity:.6}.opacity-70{opacity:.7}.opacity-100{opacity:1}.shadow{--tw-shadow:0 1px 3px 0 var(--tw-shadow-color,#0000001a), 0 1px 2px -1px var(--tw-shadow-color,#0000001a);box-shadow:var(--tw-inset-shadow), var(--tw-inset-ring-shadow), var(--tw-ring-offset-shadow), var(--tw-ring-shadow), var(--tw-shadow)}.shadow-2xl{--tw-shadow:0 25px 50px -12px var(--tw-shadow-color,#00000040);box-shadow:var(--tw-inset-shadow), var(--tw-inset-ring-shadow), var(--tw-ring-offset-shadow), var(--tw-ring-shadow), var(--tw-shadow)}.shadow-\\[0_1px_2px_rgba\\(15\\,23\\,42\\,0\\.04\\)\\,0_12px_32px_rgba\\(15\\,23\\,42\\,0\\.07\\)\\]{--tw-shadow:0 1px 2px var(--tw-shadow-color,#0f172a0a), 0 12px 32px var(--tw-shadow-color,#0f172a12);box-shadow:var(--tw-inset-shadow), var(--tw-inset-ring-shadow), var(--tw-ring-offset-shadow), var(--tw-ring-shadow), var(--tw-shadow)}.shadow-\\[0_8px_32px_-4px_rgba\\(0\\,0\\,0\\,0\\.15\\)\\]{--tw-shadow:0 8px 32px -4px var(--tw-shadow-color,#00000026);box-shadow:var(--tw-inset-shadow), var(--tw-inset-ring-shadow), var(--tw-ring-offset-shadow), var(--tw-ring-shadow), var(--tw-shadow)}.shadow-\\[0_24px_80px_-12px_rgba\\(0\\,0\\,0\\,0\\.2\\)\\,0_8px_24px_-8px_rgba\\(0\\,0\\,0\\,0\\.08\\)\\]{--tw-shadow:0 24px 80px -12px var(--tw-shadow-color,#0003), 0 8px 24px -8px var(--tw-shadow-color,#00000014);box-shadow:var(--tw-inset-shadow), var(--tw-inset-ring-shadow), var(--tw-ring-offset-shadow), var(--tw-ring-shadow), var(--tw-shadow)}.shadow-lg{--tw-shadow:0 10px 15px -3px var(--tw-shadow-color,#0000001a), 0 4px 6px -4px var(--tw-shadow-color,#0000001a);box-shadow:var(--tw-inset-shadow), var(--tw-inset-ring-shadow), var(--tw-ring-offset-shadow), var(--tw-ring-shadow), var(--tw-shadow)}.shadow-sm{--tw-shadow:0 1px 3px 0 var(--tw-shadow-color,#0000001a), 0 1px 2px -1px var(--tw-shadow-color,#0000001a);box-shadow:var(--tw-inset-shadow), var(--tw-inset-ring-shadow), var(--tw-ring-offset-shadow), var(--tw-ring-shadow), var(--tw-shadow)}.shadow-xl{--tw-shadow:0 20px 25px -5px var(--tw-shadow-color,#0000001a), 0 8px 10px -6px var(--tw-shadow-color,#0000001a);box-shadow:var(--tw-inset-shadow), var(--tw-inset-ring-shadow), var(--tw-ring-offset-shadow), var(--tw-ring-shadow), var(--tw-shadow)}.ring,.ring-1{--tw-ring-shadow:var(--tw-ring-inset, ) 0 0 0 calc(1px + var(--tw-ring-offset-width)) var(--tw-ring-color,currentcolor);box-shadow:var(--tw-inset-shadow), var(--tw-inset-ring-shadow), var(--tw-ring-offset-shadow), var(--tw-ring-shadow), var(--tw-shadow)}.ring-2{--tw-ring-shadow:var(--tw-ring-inset, ) 0 0 0 calc(2px + var(--tw-ring-offset-width)) var(--tw-ring-color,currentcolor);box-shadow:var(--tw-inset-shadow), var(--tw-inset-ring-shadow), var(--tw-ring-offset-shadow), var(--tw-ring-shadow), var(--tw-shadow)}.ring-black\\/5{--tw-ring-color:#0000000d}@supports (color:color-mix(in lab, red, red)){.ring-black\\/5{--tw-ring-color:color-mix(in oklab, var(--color-black) 5%, transparent)}}.ring-theme-200,.ring-theme-200\\/50{--tw-ring-color:var(--color-theme-200)}@supports (color:color-mix(in lab, red, red)){.ring-theme-200\\/50{--tw-ring-color:color-mix(in oklab, var(--color-theme-200) 50%, transparent)}}.ring-theme-900{--tw-ring-color:var(--color-theme-900)}.ring-theme-950\\/20{--tw-ring-color:var(--color-theme-950)}@supports (color:color-mix(in lab, red, red)){.ring-theme-950\\/20{--tw-ring-color:color-mix(in oklab, var(--color-theme-950) 20%, transparent)}}.ring-theme-950\\/\\[0\\.06\\]{--tw-ring-color:var(--color-theme-950)}@supports (color:color-mix(in lab, red, red)){.ring-theme-950\\/\\[0\\.06\\]{--tw-ring-color:color-mix(in oklab, var(--color-theme-950) 6%, transparent)}}.ring-white{--tw-ring-color:var(--color-white)}.ring-white\\/10{--tw-ring-color:#ffffff1a}@supports (color:color-mix(in lab, red, red)){.ring-white\\/10{--tw-ring-color:color-mix(in oklab, var(--color-white) 10%, transparent)}}.ring-white\\/15{--tw-ring-color:#ffffff26}@supports (color:color-mix(in lab, red, red)){.ring-white\\/15{--tw-ring-color:color-mix(in oklab, var(--color-white) 15%, transparent)}}.ring-white\\/20{--tw-ring-color:#fff3}@supports (color:color-mix(in lab, red, red)){.ring-white\\/20{--tw-ring-color:color-mix(in oklab, var(--color-white) 20%, transparent)}}.blur{--tw-blur:blur(8px);filter:var(--tw-blur, ) var(--tw-brightness, ) var(--tw-contrast, ) var(--tw-grayscale, ) var(--tw-hue-rotate, ) var(--tw-invert, ) var(--tw-saturate, ) var(--tw-sepia, ) var(--tw-drop-shadow, )}.backdrop-blur-lg{--tw-backdrop-blur:blur(var(--blur-lg));-webkit-backdrop-filter:var(--tw-backdrop-blur, ) var(--tw-backdrop-brightness, ) var(--tw-backdrop-contrast, ) var(--tw-backdrop-grayscale, ) var(--tw-backdrop-hue-rotate, ) var(--tw-backdrop-invert, ) var(--tw-backdrop-opacity, ) var(--tw-backdrop-saturate, ) var(--tw-backdrop-sepia, );backdrop-filter:var(--tw-backdrop-blur, ) var(--tw-backdrop-brightness, ) var(--tw-backdrop-contrast, ) var(--tw-backdrop-grayscale, ) var(--tw-backdrop-hue-rotate, ) var(--tw-backdrop-invert, ) var(--tw-backdrop-opacity, ) var(--tw-backdrop-saturate, ) var(--tw-backdrop-sepia, )}.backdrop-blur-sm{--tw-backdrop-blur:blur(var(--blur-sm));-webkit-backdrop-filter:var(--tw-backdrop-blur, ) var(--tw-backdrop-brightness, ) var(--tw-backdrop-contrast, ) var(--tw-backdrop-grayscale, ) var(--tw-backdrop-hue-rotate, ) var(--tw-backdrop-invert, ) var(--tw-backdrop-opacity, ) var(--tw-backdrop-saturate, ) var(--tw-backdrop-sepia, );backdrop-filter:var(--tw-backdrop-blur, ) var(--tw-backdrop-brightness, ) var(--tw-backdrop-contrast, ) var(--tw-backdrop-grayscale, ) var(--tw-backdrop-hue-rotate, ) var(--tw-backdrop-invert, ) var(--tw-backdrop-opacity, ) var(--tw-backdrop-saturate, ) var(--tw-backdrop-sepia, )}.backdrop-blur-xl{--tw-backdrop-blur:blur(var(--blur-xl));-webkit-backdrop-filter:var(--tw-backdrop-blur, ) var(--tw-backdrop-brightness, ) var(--tw-backdrop-contrast, ) var(--tw-backdrop-grayscale, ) var(--tw-backdrop-hue-rotate, ) var(--tw-backdrop-invert, ) var(--tw-backdrop-opacity, ) var(--tw-backdrop-saturate, ) var(--tw-backdrop-sepia, );backdrop-filter:var(--tw-backdrop-blur, ) var(--tw-backdrop-brightness, ) var(--tw-backdrop-contrast, ) var(--tw-backdrop-grayscale, ) var(--tw-backdrop-hue-rotate, ) var(--tw-backdrop-invert, ) var(--tw-backdrop-opacity, ) var(--tw-backdrop-saturate, ) var(--tw-backdrop-sepia, )}.transition{transition-property:color,background-color,border-color,outline-color,text-decoration-color,fill,stroke,--tw-gradient-from,--tw-gradient-via,--tw-gradient-to,opacity,box-shadow,transform,translate,scale,rotate,filter,-webkit-backdrop-filter,backdrop-filter,display,content-visibility,overlay,pointer-events;transition-timing-function:var(--tw-ease,var(--default-transition-timing-function));transition-duration:var(--tw-duration,var(--default-transition-duration))}.transition-\\[opacity\\,transform\\]{transition-property:opacity,transform;transition-timing-function:var(--tw-ease,var(--default-transition-timing-function));transition-duration:var(--tw-duration,var(--default-transition-duration))}.transition-all{transition-property:all;transition-timing-function:var(--tw-ease,var(--default-transition-timing-function));transition-duration:var(--tw-duration,var(--default-transition-duration))}.transition-colors{transition-property:color,background-color,border-color,outline-color,text-decoration-color,fill,stroke,--tw-gradient-from,--tw-gradient-via,--tw-gradient-to;transition-timing-function:var(--tw-ease,var(--default-transition-timing-function));transition-duration:var(--tw-duration,var(--default-transition-duration))}.transition-opacity{transition-property:opacity;transition-timing-function:var(--tw-ease,var(--default-transition-timing-function));transition-duration:var(--tw-duration,var(--default-transition-duration))}.transition-transform{transition-property:transform,translate,scale,rotate;transition-timing-function:var(--tw-ease,var(--default-transition-timing-function));transition-duration:var(--tw-duration,var(--default-transition-duration))}.duration-150{--tw-duration:.15s;transition-duration:.15s}.duration-200{--tw-duration:.2s;transition-duration:.2s}.duration-250{--tw-duration:.25s;transition-duration:.25s}.duration-300{--tw-duration:.3s;transition-duration:.3s}.duration-400{--tw-duration:.4s;transition-duration:.4s}.duration-500{--tw-duration:.5s;transition-duration:.5s}.duration-1000{--tw-duration:1s;transition-duration:1s}.duration-\\[400ms\\]{--tw-duration:.4s;transition-duration:.4s}.ease-\\[cubic-bezier\\(0\\.25\\,1\\,0\\.33\\,1\\)\\]{--tw-ease:cubic-bezier(.25,1,.33,1);transition-timing-function:cubic-bezier(.25,1,.33,1)}.ease-\\[cubic-bezier\\(0\\.52\\,0\\.01\\,0\\.16\\,1\\)\\]{--tw-ease:cubic-bezier(.52,.01,.16,1);transition-timing-function:cubic-bezier(.52,.01,.16,1)}.ease-in{--tw-ease:var(--ease-in);transition-timing-function:var(--ease-in)}.ease-in-out{--tw-ease:var(--ease-in-out);transition-timing-function:var(--ease-in-out)}.ease-out{--tw-ease:var(--ease-out);transition-timing-function:var(--ease-out)}.will-change-transform{will-change:transform}.outline-none{--tw-outline-style:none;outline-style:none}.\\[-ms-overflow-style\\:none\\]{-ms-overflow-style:none}.\\[animation-duration\\:3s\\]{animation-duration:3s}.\\[overflow-anchor\\:none\\]{overflow-anchor:none}@media (hover:hover){:is(:where(.group):hover .group-hover\\:scale-100){--tw-scale-x:100%;--tw-scale-y:100%;--tw-scale-z:100%;scale:var(--tw-scale-x) var(--tw-scale-y)}:is(:where(.group):hover .group-hover\\:scale-110){--tw-scale-x:110%;--tw-scale-y:110%;--tw-scale-z:110%;scale:var(--tw-scale-x) var(--tw-scale-y)}:is(:where(.group):hover .group-hover\\:text-white){color:var(--color-white)}:is(:where(.group):hover .group-hover\\:opacity-40){opacity:.4}:is(:where(.group\\/msg):hover .group-hover\\/msg\\:opacity-100){opacity:1}}.focus-within\\:bg-white\\/15:focus-within{background-color:#ffffff26}@supports (color:color-mix(in lab, red, red)){.focus-within\\:bg-white\\/15:focus-within{background-color:color-mix(in oklab, var(--color-white) 15%, transparent)}}.focus-within\\:opacity-100:focus-within{opacity:1}.focus-within\\:ring-theme-950\\/30:focus-within{--tw-ring-color:var(--color-theme-950)}@supports (color:color-mix(in lab, red, red)){.focus-within\\:ring-theme-950\\/30:focus-within{--tw-ring-color:color-mix(in oklab, var(--color-theme-950) 30%, transparent)}}.focus-within\\:ring-white\\/25:focus-within{--tw-ring-color:#ffffff40}@supports (color:color-mix(in lab, red, red)){.focus-within\\:ring-white\\/25:focus-within{--tw-ring-color:color-mix(in oklab, var(--color-white) 25%, transparent)}}@media (hover:hover){.hover\\:translate-y-\\[-1px\\]:hover{--tw-translate-y:-1px;translate:var(--tw-translate-x) var(--tw-translate-y)}.hover\\:scale-105:hover{--tw-scale-x:105%;--tw-scale-y:105%;--tw-scale-z:105%;scale:var(--tw-scale-x) var(--tw-scale-y)}.hover\\:scale-110:hover{--tw-scale-x:110%;--tw-scale-y:110%;--tw-scale-z:110%;scale:var(--tw-scale-x) var(--tw-scale-y)}.hover\\:rotate-90:hover{rotate:90deg}.hover\\:border-green-300:hover{border-color:var(--color-green-300)}.hover\\:border-primary-300:hover{border-color:var(--color-primary-300)}.hover\\:border-red-300:hover{border-color:var(--color-red-300)}.hover\\:border-theme-200:hover{border-color:var(--color-theme-200)}.hover\\:border-theme-300:hover{border-color:var(--color-theme-300)}.hover\\:border-white\\/10:hover{border-color:#ffffff1a}@supports (color:color-mix(in lab, red, red)){.hover\\:border-white\\/10:hover{border-color:color-mix(in oklab, var(--color-white) 10%, transparent)}}.hover\\:border-white\\/40:hover{border-color:#fff6}@supports (color:color-mix(in lab, red, red)){.hover\\:border-white\\/40:hover{border-color:color-mix(in oklab, var(--color-white) 40%, transparent)}}.hover\\:bg-green-500:hover{background-color:var(--color-green-500)}.hover\\:bg-primary-500:hover{background-color:var(--color-primary-500)}.hover\\:bg-red-500:hover{background-color:var(--color-red-500)}.hover\\:bg-theme-25:hover{background-color:var(--color-theme-25)}.hover\\:bg-theme-50:hover{background-color:var(--color-theme-50)}.hover\\:bg-theme-100:hover{background-color:var(--color-theme-100)}.hover\\:bg-theme-200:hover{background-color:var(--color-theme-200)}.hover\\:bg-theme-700:hover{background-color:var(--color-theme-700)}.hover\\:bg-theme-800:hover{background-color:var(--color-theme-800)}.hover\\:bg-theme-950\\/5:hover{background-color:var(--color-theme-950)}@supports (color:color-mix(in lab, red, red)){.hover\\:bg-theme-950\\/5:hover{background-color:color-mix(in oklab, var(--color-theme-950) 5%, transparent)}}.hover\\:bg-white\\/5:hover{background-color:#ffffff0d}@supports (color:color-mix(in lab, red, red)){.hover\\:bg-white\\/5:hover{background-color:color-mix(in oklab, var(--color-white) 5%, transparent)}}.hover\\:bg-white\\/10:hover{background-color:#ffffff1a}@supports (color:color-mix(in lab, red, red)){.hover\\:bg-white\\/10:hover{background-color:color-mix(in oklab, var(--color-white) 10%, transparent)}}.hover\\:bg-white\\/15:hover{background-color:#ffffff26}@supports (color:color-mix(in lab, red, red)){.hover\\:bg-white\\/15:hover{background-color:color-mix(in oklab, var(--color-white) 15%, transparent)}}.hover\\:bg-white\\/20:hover{background-color:#fff3}@supports (color:color-mix(in lab, red, red)){.hover\\:bg-white\\/20:hover{background-color:color-mix(in oklab, var(--color-white) 20%, transparent)}}.hover\\:text-primary-600:hover{color:var(--color-primary-600)}.hover\\:text-red-600:hover{color:var(--color-red-600)}.hover\\:text-theme-400:hover{color:var(--color-theme-400)}.hover\\:text-theme-500:hover{color:var(--color-theme-500)}.hover\\:text-theme-600:hover{color:var(--color-theme-600)}.hover\\:text-theme-700:hover{color:var(--color-theme-700)}.hover\\:text-theme-800:hover{color:var(--color-theme-800)}.hover\\:text-theme-900:hover{color:var(--color-theme-900)}.hover\\:text-white:hover{color:var(--color-white)}.hover\\:text-white\\/70:hover{color:#ffffffb3}@supports (color:color-mix(in lab, red, red)){.hover\\:text-white\\/70:hover{color:color-mix(in oklab, var(--color-white) 70%, transparent)}}.hover\\:text-white\\/80:hover{color:#fffc}@supports (color:color-mix(in lab, red, red)){.hover\\:text-white\\/80:hover{color:color-mix(in oklab, var(--color-white) 80%, transparent)}}.hover\\:opacity-70:hover{opacity:.7}.hover\\:shadow-2xl:hover{--tw-shadow:0 25px 50px -12px var(--tw-shadow-color,#00000040);box-shadow:var(--tw-inset-shadow), var(--tw-inset-ring-shadow), var(--tw-ring-offset-shadow), var(--tw-ring-shadow), var(--tw-shadow)}.hover\\:ring-theme-950\\/30:hover{--tw-ring-color:var(--color-theme-950)}@supports (color:color-mix(in lab, red, red)){.hover\\:ring-theme-950\\/30:hover{--tw-ring-color:color-mix(in oklab, var(--color-theme-950) 30%, transparent)}}.hover\\:ring-white\\/25:hover{--tw-ring-color:#ffffff40}@supports (color:color-mix(in lab, red, red)){.hover\\:ring-white\\/25:hover{--tw-ring-color:color-mix(in oklab, var(--color-white) 25%, transparent)}}.hover\\:brightness-110:hover{--tw-brightness:brightness(110%);filter:var(--tw-blur, ) var(--tw-brightness, ) var(--tw-contrast, ) var(--tw-grayscale, ) var(--tw-hue-rotate, ) var(--tw-invert, ) var(--tw-saturate, ) var(--tw-sepia, ) var(--tw-drop-shadow, )}}.focus\\:border-theme-900:focus{border-color:var(--color-theme-900)}.focus\\:outline-none:focus{--tw-outline-style:none;outline-style:none}.focus-visible\\:ring-2:focus-visible{--tw-ring-shadow:var(--tw-ring-inset, ) 0 0 0 calc(2px + var(--tw-ring-offset-width)) var(--tw-ring-color,currentcolor);box-shadow:var(--tw-inset-shadow), var(--tw-inset-ring-shadow), var(--tw-ring-offset-shadow), var(--tw-ring-shadow), var(--tw-shadow)}.focus-visible\\:ring-theme-900:focus-visible{--tw-ring-color:var(--color-theme-900)}.focus-visible\\:ring-white:focus-visible{--tw-ring-color:var(--color-white)}.focus-visible\\:ring-offset-2:focus-visible{--tw-ring-offset-width:2px;--tw-ring-offset-shadow:var(--tw-ring-inset, ) 0 0 0 var(--tw-ring-offset-width) var(--tw-ring-offset-color)}.focus-visible\\:outline-none:focus-visible{--tw-outline-style:none;outline-style:none}.active\\:-translate-y-0\\.5:active{--tw-translate-y:calc(var(--spacing) * -.5);translate:var(--tw-translate-x) var(--tw-translate-y)}.active\\:scale-90:active{--tw-scale-x:90%;--tw-scale-y:90%;--tw-scale-z:90%;scale:var(--tw-scale-x) var(--tw-scale-y)}.active\\:scale-95:active{--tw-scale-x:95%;--tw-scale-y:95%;--tw-scale-z:95%;scale:var(--tw-scale-x) var(--tw-scale-y)}.active\\:scale-\\[0\\.98\\]:active{scale:.98}.active\\:scale-\\[1\\.06\\]:active{scale:1.06}.active\\:bg-theme-800\\/80:active{background-color:var(--color-theme-800)}@supports (color:color-mix(in lab, red, red)){.active\\:bg-theme-800\\/80:active{background-color:color-mix(in oklab, var(--color-theme-800) 80%, transparent)}}.active\\:bg-white\\/25:active{background-color:#ffffff40}@supports (color:color-mix(in lab, red, red)){.active\\:bg-white\\/25:active{background-color:color-mix(in oklab, var(--color-white) 25%, transparent)}}.active\\:opacity-70:active{opacity:.7}.active\\:opacity-80:active{opacity:.8}.active\\:duration-100:active{--tw-duration:.1s;transition-duration:.1s}.disabled\\:cursor-default:disabled{cursor:default}.disabled\\:cursor-not-allowed:disabled{cursor:not-allowed}.disabled\\:opacity-50:disabled{opacity:.5}@media (min-width:40rem){.sm\\:top-6{top:calc(var(--spacing) * 6)}.sm\\:right-6{right:calc(var(--spacing) * 6)}.sm\\:bottom-6{bottom:calc(var(--spacing) * 6)}.sm\\:left-6{left:calc(var(--spacing) * 6)}.sm\\:size-16{width:calc(var(--spacing) * 16);height:calc(var(--spacing) * 16)}.sm\\:h-24{height:calc(var(--spacing) * 24)}.sm\\:max-h-\\[620px\\]{max-height:620px}.sm\\:w-24{width:calc(var(--spacing) * 24)}.sm\\:max-w-\\[420px\\]{max-width:420px}.sm\\:flex-none{flex:none}.sm\\:items-center{align-items:center}.sm\\:justify-center{justify-content:center}.sm\\:rounded-\\[32px\\]{border-radius:32px}.sm\\:bg-\\[\\#050F19\\]\\/45{background-color:#050f1973;background-color:color(display-p3 .0270841 .0577423 .0947219/.45);background-color:lab(3.9307% -1.22581 -7.24003/.45)}.sm\\:p-6{padding:calc(var(--spacing) * 6)}.sm\\:px-12{padding-inline:calc(var(--spacing) * 12)}.sm\\:pb-9{padding-bottom:calc(var(--spacing) * 9)}.sm\\:text-2xl{font-size:var(--text-2xl);line-height:var(--tw-leading,var(--text-2xl--line-height))}.sm\\:text-base{font-size:var(--text-base);line-height:var(--tw-leading,var(--text-base--line-height))}.sm\\:shadow-\\[0_32px_80px_rgba\\(5\\,15\\,25\\,0\\.45\\)\\]{--tw-shadow:0 32px 80px var(--tw-shadow-color,#050f1973);box-shadow:var(--tw-inset-shadow), var(--tw-inset-ring-shadow), var(--tw-ring-offset-shadow), var(--tw-ring-shadow), var(--tw-shadow)}}@media (min-width:48rem){.md\\:h-\\[600px\\]{height:600px}}@container bot (width>=480px){.\\@\\[480px\\]\\/bot\\:px-6{padding-inline:calc(var(--spacing) * 6)}}@container chat (width>=24rem){.\\@sm\\/chat\\:ml-\\[2em\\]{margin-left:2em}.\\@sm\\/chat\\:size-24{width:calc(var(--spacing) * 24);height:calc(var(--spacing) * 24)}}@container chat-preview (width>=24rem){.\\@sm\\/chat-preview\\:max-w-\\[78\\%\\]{max-width:78%}}@container chat (width>=24rem){.\\@sm\\/chat\\:max-w-\\[320px\\]{max-width:320px}.\\@sm\\/chat\\:pr-\\[2em\\]{padding-right:2em}.\\@sm\\/chat\\:text-lg{font-size:var(--text-lg);line-height:var(--tw-leading,var(--text-lg--line-height))}.\\@sm\\/chat\\:text-sm{font-size:var(--text-sm);line-height:var(--tw-leading,var(--text-sm--line-height))}.\\@sm\\/chat\\:text-\\[15px\\]{font-size:15px}}@container chat (width>=28rem){.\\@md\\/chat\\:block{display:block}}@container chat (width>=32rem){.\\@lg\\/chat\\:px-8{padding-inline:calc(var(--spacing) * 8)}.\\@lg\\/chat\\:text-\\[15\\.5px\\]{font-size:15.5px}}@container chat (width>=64rem){.\\@5xl\\/chat\\:max-w-\\[720px\\]{max-width:720px}.\\@5xl\\/chat\\:max-w-\\[740px\\]{max-width:740px}.\\@5xl\\/chat\\:px-5{padding-inline:calc(var(--spacing) * 5)}.\\@5xl\\/chat\\:pt-3\\.5{padding-top:calc(var(--spacing) * 3.5)}.\\@5xl\\/chat\\:pb-3{padding-bottom:calc(var(--spacing) * 3)}}@media (prefers-color-scheme:dark){.dark\\:bg-theme-600\\/90{background-color:var(--color-theme-600)}@supports (color:color-mix(in lab, red, red)){.dark\\:bg-theme-600\\/90{background-color:color-mix(in oklab, var(--color-theme-600) 90%, transparent)}}}@media (pointer:coarse){.pointer-coarse\\:size-11{width:calc(var(--spacing) * 11);height:calc(var(--spacing) * 11)}.pointer-coarse\\:opacity-100{opacity:1}}.\\[\\&_\\.chat-msg-rich\\]\\:max-w-none .chat-msg-rich{max-width:none}.\\[\\&_\\.chat-msg-rich\\]\\:text-\\[13px\\] .chat-msg-rich{font-size:13px}.\\[\\&_\\.chat-msg-rich\\]\\:leading-\\[1\\.6\\] .chat-msg-rich{--tw-leading:1.6;line-height:1.6}.\\[\\&_\\.chat-msg-rich\\]\\:italic .chat-msg-rich{font-style:italic}.\\[\\&\\:\\:-webkit-scrollbar\\]\\:hidden::-webkit-scrollbar{display:none}}.chat-dots{align-items:center;gap:3px;display:inline-flex}.chat-dots>span{background:currentColor;border-radius:9999px;width:5px;height:5px;animation:1.4s cubic-bezier(.25,1,.33,1) infinite chat-dot}.chat-dots>span:nth-child(2){animation-delay:.16s}.chat-dots>span:nth-child(3){animation-delay:.32s}@keyframes chat-dot{0%,52%,to{opacity:.25;transform:translateY(0)}22%{opacity:1;transform:translateY(-1.5px)}}.chat-dots--mini{gap:2.5px}.chat-dots--mini>span{width:3.5px;height:3.5px}.chat-pulse-dot{animation:1.4s cubic-bezier(.25,1,.33,1) infinite chat-pulse-dot}@keyframes chat-pulse-dot{0%,to{opacity:.35;transform:scale(.7)}35%{opacity:1;transform:scale(1)}}.chat-live-enter{animation:.28s cubic-bezier(.25,1,.33,1) both chat-live-enter}@keyframes chat-live-enter{0%{opacity:0;transform:translateY(3px)}to{opacity:1;transform:translateY(0)}}@media (prefers-reduced-motion:reduce){.chat-dots>span,.chat-pulse-dot{opacity:.55;animation:none}.chat-live-enter{animation:none}}.chat-msg-prose :first-child{margin-top:0}.chat-msg-prose :last-child{margin-bottom:0}.chat-msg-prose+.chat-msg-prose{margin-top:1em}.chat-msg-prose strong{font-weight:600}.chat-msg-prose em{font-style:italic}.chat-msg-prose a{color:var(--color-primary-500);text-underline-offset:3px;text-decoration:underline;-webkit-text-decoration-color:var(--color-primary-500);-webkit-text-decoration-color:var(--color-primary-500);-webkit-text-decoration-color:var(--color-primary-500);text-decoration-color:var(--color-primary-500)}@supports (color:color-mix(in lab, red, red)){.chat-msg-prose a{-webkit-text-decoration-color:color-mix(in oklch, var(--color-primary-500) 40%, transparent);-webkit-text-decoration-color:color-mix(in oklch, var(--color-primary-500) 40%, transparent);-webkit-text-decoration-color:color-mix(in oklch, var(--color-primary-500) 40%, transparent);text-decoration-color:color-mix(in oklch, var(--color-primary-500) 40%, transparent)}}.chat-msg-prose a{font-weight:500;transition:text-decoration-color .15s}.chat-msg-prose a:hover{-webkit-text-decoration-color:var(--color-primary-500);-webkit-text-decoration-color:var(--color-primary-500);-webkit-text-decoration-color:var(--color-primary-500);text-decoration-color:var(--color-primary-500)}.chat-msg-prose.chat-msg-prose-invert a{color:#fff;text-decoration-color:#ffffff73}.chat-msg-prose.chat-msg-prose-invert a:hover{text-decoration-color:#fff}.chat-msg-prose.chat-msg-prose-invert pre,.chat-msg-prose.chat-msg-prose-invert table{background:#ffffff14;border-color:#ffffff2e}.chat-msg-prose.chat-msg-prose-invert td{border-top-color:#ffffff1f}.chat-msg-prose.chat-msg-prose-invert :not(pre)>code{background:#ffffff24}.chat-msg-prose.chat-msg-prose-invert hr{border-top-color:#ffffff38}.chat-msg-prose p{margin:1em 0;line-height:1.55}.chat-msg-prose :-webkit-any(p,ul,ol,blockquote,h1,h2,h3,h4,h5,h6){max-width:34em}.chat-msg-prose :is(p,ul,ol,blockquote,h1,h2,h3,h4,h5,h6){max-width:34em}.chat-msg-prose h1{letter-spacing:-.012em;margin:1.1em 0 .5em;font-size:1.25em;font-weight:600;line-height:1.3}.chat-msg-prose h2{letter-spacing:-.01em;margin:1.1em 0 .45em;font-size:1.15em;font-weight:600;line-height:1.3}.chat-msg-prose h3{letter-spacing:-.008em;margin:1em 0 .4em;font-size:1.05em;font-weight:600;line-height:1.35}.chat-msg-prose h4,.chat-msg-prose h5,.chat-msg-prose h6{margin:.9em 0 .35em;font-size:1em;font-weight:600;line-height:1.4}.chat-msg-prose ul,.chat-msg-prose ol{margin:.7em 0 .9em;padding-left:1.4em;line-height:1.55}.chat-msg-prose ul{list-style-type:disc}.chat-msg-prose ol{list-style-type:decimal}.chat-msg-prose li{margin-bottom:.35em}.chat-msg-prose li p{margin:0}.chat-msg-prose li::marker{color:currentColor;opacity:.4}.chat-msg-prose li:has(>input[type=checkbox]){margin-left:-1.4em;list-style:none}.chat-msg-prose li>input[type=checkbox]{-webkit-appearance:none;appearance:none;vertical-align:-.06em;border:1px solid var(--color-theme-300);background:0 0;border-radius:.22em;width:.82em;height:.82em;margin:0 .5em 0 .1em}.chat-msg-prose li>input[type=checkbox]:checked{border-color:var(--color-theme-900);background:var(--color-theme-900) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 10 8'%3E%3Cpath d='M1 4.2 3.8 6.8 9 1.2' fill='none' stroke='white' stroke-width='1.6' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") center / .55em no-repeat}.chat-msg-prose.chat-msg-prose-invert li>input[type=checkbox]{border-color:#fff6}.chat-msg-prose.chat-msg-prose-invert li>input[type=checkbox]:checked{background-color:#fff;background-image:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 10 8'%3E%3Cpath d='M1 4.2 3.8 6.8 9 1.2' fill='none' stroke='%230c0a13' stroke-width='1.6' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");border-color:#fff}.chat-msg-prose pre{background:var(--color-theme-25);border:1px solid var(--color-theme-200);border-radius:.625rem;margin:1.4em 0;padding:.85em 1em;font-family:SF Mono,SFMono-Regular,Consolas,Liberation Mono,Menlo,monospace;font-size:.82em;line-height:1.5;overflow-x:auto}.chat-msg-prose pre code{font-size:inherit;background:0 0;padding:0;font-family:inherit}.chat-msg-prose :not(pre)>code{background:var(--color-theme-200);border-radius:.3rem;padding:.15em .4em;font-size:.85em}@supports (color:color-mix(in lab, red, red)){.chat-msg-prose :not(pre)>code{background:color-mix(in oklch, var(--color-theme-200) 45%, transparent)}}.chat-msg-prose :not(pre)>code{font-family:SF Mono,SFMono-Regular,Consolas,Liberation Mono,Menlo,monospace}.chat-msg-prose blockquote{opacity:.8;margin:1.3em 0;padding:0 0 0 1.1em;font-style:italic}.chat-msg-prose blockquote p{margin:.15em 0}.chat-msg-prose table{background:var(--color-theme-0);border-collapse:separate;border-spacing:0;border:1px solid var(--color-theme-200);border-radius:.625rem;width:100%;margin:1.4em 0;font-size:.9em;line-height:1.45;overflow:hidden}.chat-msg-prose th,.chat-msg-prose td{text-align:left;padding:.65em .8em}.chat-msg-prose th{font-weight:600}.chat-msg-prose td{border-top:1px solid var(--color-theme-200)}@supports (color:color-mix(in lab, red, red)){.chat-msg-prose td{border-top:1px solid color-mix(in oklch, var(--color-theme-200) 45%, transparent)}}.chat-msg-prose td{color:currentColor}@supports (color:color-mix(in lab, red, red)){.chat-msg-prose td{color:color-mix(in oklch, currentColor 75%, transparent)}}.chat-msg-prose td:first-child{color:inherit}.chat-msg-prose [align=center]{text-align:center}.chat-msg-prose [align=right]{text-align:right}.chat-msg-prose [align=left]{text-align:left}.chat-msg-prose hr{border:none;border-top:1px solid var(--color-theme-200)}@supports (color:color-mix(in lab, red, red)){.chat-msg-prose hr{border-top:1px solid color-mix(in oklch, var(--color-theme-200) 42%, transparent)}}.chat-msg-prose hr{margin:1.2em 0}.chat-msg-prose img{border-radius:.5rem;max-width:100%;height:auto;margin:.6em 0}.chat-msg-prose p+p{margin-top:.65em}.chat-msg-prose p+ul,.chat-msg-prose p+ol{margin-top:.4em}.chat-msg-prose h1+p,.chat-msg-prose h2+p,.chat-msg-prose h3+p{margin-top:.2em}@property --tw-translate-x{syntax:"*";inherits:false;initial-value:0}@property --tw-translate-y{syntax:"*";inherits:false;initial-value:0}@property --tw-translate-z{syntax:"*";inherits:false;initial-value:0}@property --tw-scale-x{syntax:"*";inherits:false;initial-value:1}@property --tw-scale-y{syntax:"*";inherits:false;initial-value:1}@property --tw-scale-z{syntax:"*";inherits:false;initial-value:1}@property --tw-rotate-x{syntax:"*";inherits:false}@property --tw-rotate-y{syntax:"*";inherits:false}@property --tw-rotate-z{syntax:"*";inherits:false}@property --tw-skew-x{syntax:"*";inherits:false}@property --tw-skew-y{syntax:"*";inherits:false}@property --tw-space-y-reverse{syntax:"*";inherits:false;initial-value:0}@property --tw-border-style{syntax:"*";inherits:false;initial-value:solid}@property --tw-gradient-position{syntax:"*";inherits:false}@property --tw-gradient-from{syntax:"<color>";inherits:false;initial-value:#0000}@property --tw-gradient-via{syntax:"<color>";inherits:false;initial-value:#0000}@property --tw-gradient-to{syntax:"<color>";inherits:false;initial-value:#0000}@property --tw-gradient-stops{syntax:"*";inherits:false}@property --tw-gradient-via-stops{syntax:"*";inherits:false}@property --tw-gradient-from-position{syntax:"<length-percentage>";inherits:false;initial-value:0%}@property --tw-gradient-via-position{syntax:"<length-percentage>";inherits:false;initial-value:50%}@property --tw-gradient-to-position{syntax:"<length-percentage>";inherits:false;initial-value:100%}@property --tw-leading{syntax:"*";inherits:false}@property --tw-font-weight{syntax:"*";inherits:false}@property --tw-tracking{syntax:"*";inherits:false}@property --tw-ordinal{syntax:"*";inherits:false}@property --tw-slashed-zero{syntax:"*";inherits:false}@property --tw-numeric-figure{syntax:"*";inherits:false}@property --tw-numeric-spacing{syntax:"*";inherits:false}@property --tw-numeric-fraction{syntax:"*";inherits:false}@property --tw-shadow{syntax:"*";inherits:false;initial-value:0 0 #0000}@property --tw-shadow-color{syntax:"*";inherits:false}@property --tw-shadow-alpha{syntax:"<percentage>";inherits:false;initial-value:100%}@property --tw-inset-shadow{syntax:"*";inherits:false;initial-value:0 0 #0000}@property --tw-inset-shadow-color{syntax:"*";inherits:false}@property --tw-inset-shadow-alpha{syntax:"<percentage>";inherits:false;initial-value:100%}@property --tw-ring-color{syntax:"*";inherits:false}@property --tw-ring-shadow{syntax:"*";inherits:false;initial-value:0 0 #0000}@property --tw-inset-ring-color{syntax:"*";inherits:false}@property --tw-inset-ring-shadow{syntax:"*";inherits:false;initial-value:0 0 #0000}@property --tw-ring-inset{syntax:"*";inherits:false}@property --tw-ring-offset-width{syntax:"<length>";inherits:false;initial-value:0}@property --tw-ring-offset-color{syntax:"*";inherits:false;initial-value:#fff}@property --tw-ring-offset-shadow{syntax:"*";inherits:false;initial-value:0 0 #0000}@property --tw-blur{syntax:"*";inherits:false}@property --tw-brightness{syntax:"*";inherits:false}@property --tw-contrast{syntax:"*";inherits:false}@property --tw-grayscale{syntax:"*";inherits:false}@property --tw-hue-rotate{syntax:"*";inherits:false}@property --tw-invert{syntax:"*";inherits:false}@property --tw-opacity{syntax:"*";inherits:false}@property --tw-saturate{syntax:"*";inherits:false}@property --tw-sepia{syntax:"*";inherits:false}@property --tw-drop-shadow{syntax:"*";inherits:false}@property --tw-drop-shadow-color{syntax:"*";inherits:false}@property --tw-drop-shadow-alpha{syntax:"<percentage>";inherits:false;initial-value:100%}@property --tw-drop-shadow-size{syntax:"*";inherits:false}@property --tw-backdrop-blur{syntax:"*";inherits:false}@property --tw-backdrop-brightness{syntax:"*";inherits:false}@property --tw-backdrop-contrast{syntax:"*";inherits:false}@property --tw-backdrop-grayscale{syntax:"*";inherits:false}@property --tw-backdrop-hue-rotate{syntax:"*";inherits:false}@property --tw-backdrop-invert{syntax:"*";inherits:false}@property --tw-backdrop-opacity{syntax:"*";inherits:false}@property --tw-backdrop-saturate{syntax:"*";inherits:false}@property --tw-backdrop-sepia{syntax:"*";inherits:false}@property --tw-duration{syntax:"*";inherits:false}@property --tw-ease{syntax:"*";inherits:false}@keyframes spin{to{transform:rotate(360deg)}}@keyframes ping{75%,to{opacity:0;transform:scale(2)}}@keyframes pulse{50%{opacity:.5}}`,UL={"data-test":"auth-panel",class:"flex flex-col justify-end h-full px-5 pb-8 pt-6"},jL={class:"flex-1 flex flex-col justify-center"},ML={key:0,class:"text-xs text-red-500 mb-4"},LL={class:"space-y-3"},VL={key:0},FL={key:1,class:"space-y-3"},BL={key:2,class:"space-y-3"},ZL={class:"text-xs text-theme-400"},HL=Pe({__name:"ElAuthPanel",props:{sdk:{}},setup(e){let t=Q(!1),n=Q("email"),i=Q({email:"",code:""}),r=Q(!1);function o(){e.sdk.error.value=null,e.sdk.auth.loginWithGoogle({onError:l=>{e.sdk.error.value=l}})}async function a(){if(!r.value){r.value=!0,e.sdk.error.value=null;try{await e.sdk.auth.requestAuthCode({email:i.value.email})&&(n.value="code")}finally{r.value=!1}}}async function s(){if(!r.value){r.value=!0,e.sdk.error.value=null;try{await e.sdk.auth.loginWithCode({email:i.value.email,code:i.value.code})}finally{r.value=!1}}}return(l,u)=>(w(),$("div",UL,[b("div",jL,[u[4]||(u[4]=b("div",{class:"space-y-3 mb-10"},[b("h3",{class:"text-2xl font-light text-theme-900 leading-snug"},[xt(" Your AI assistant,"),b("br"),xt("ready in two minutes. ")]),b("p",{class:"text-sm text-theme-400 leading-relaxed max-w-[260px]"}," Sign in to create and deploy a personal AI that works for you. ")],-1)),e.sdk.error.value?(w(),$("p",ML,de(e.sdk.error.value),1)):te("",!0)]),b("div",LL,[b("button",{"data-test":"google-auth-btn",class:"w-full flex items-center justify-center gap-3 px-5 py-3.5 rounded-xl border border-theme-200 bg-theme-0 text-theme-800 font-medium text-sm transition-all duration-150 hover:border-theme-300 hover:bg-theme-25 active:scale-[0.98] cursor-pointer",onClick:o},[...u[5]||(u[5]=[WS('<svg class="size-[18px]" viewBox="0 0 24 24"><path d="M22.56 12.25c0-.78-.07-1.53-.2-2.25H12v4.26h5.92a5.06 5.06 0 0 1-2.2 3.32v2.77h3.57c2.08-1.92 3.28-4.74 3.28-8.1z" fill="#4285F4"></path><path d="M12 23c2.97 0 5.46-.98 7.28-2.66l-3.57-2.77c-.98.66-2.23 1.06-3.71 1.06-2.86 0-5.29-1.93-6.16-4.53H2.18v2.84C3.99 20.53 7.7 23 12 23z" fill="#34A853"></path><path d="M5.84 14.09c-.22-.66-.35-1.36-.35-2.09s.13-1.43.35-2.09V7.07H2.18C1.43 8.55 1 10.22 1 12s.43 3.45 1.18 4.93l2.85-2.22.81-.62z" fill="#FBBC05"></path><path d="M12 5.38c1.62 0 3.06.56 4.21 1.64l3.15-3.15C17.45 2.09 14.97 1 12 1 7.7 1 3.99 3.47 2.18 7.07l3.66 2.84c.87-2.6 3.3-4.53 6.16-4.53z" fill="#EA4335"></path></svg> Continue with Google ',2)])]),u[8]||(u[8]=b("div",{class:"flex items-center gap-3 py-1"},[b("div",{class:"flex-1 h-px bg-theme-100"}),b("span",{class:"text-[11px] text-theme-300 uppercase tracking-widest"},"or"),b("div",{class:"flex-1 h-px bg-theme-100"})],-1)),t.value?te("",!0):(w(),$("div",VL,[b("button",{"data-test":"email-auth-link",class:"w-full px-5 py-3 rounded-xl border border-theme-100 text-sm text-theme-500 transition-all duration-150 hover:border-theme-200 hover:text-theme-700 cursor-pointer",onClick:u[0]||(u[0]=d=>t.value=!0)}," Use email instead ")])),t.value&&n.value==="email"?(w(),$("div",FL,[be(jp,{modelValue:i.value.email,"onUpdate:modelValue":u[1]||(u[1]=d=>i.value.email=d),"data-test":"auth-email-input",onKeyup:Gn(a,["enter"])},null,8,["modelValue"]),be(Xa,{"data-test":"auth-send-code",theme:"dark",size:"md",class:"w-full",loading:r.value,disabled:!i.value.email||r.value,onClick:a},{default:ot(()=>[...u[6]||(u[6]=[xt(" Send verification code ",-1)])]),_:1},8,["loading","disabled"])])):te("",!0),t.value&&n.value==="code"?(w(),$("div",BL,[b("p",ZL," Code sent to "+de(i.value.email),1),be(Mp,{modelValue:i.value.code,"onUpdate:modelValue":u[2]||(u[2]=d=>i.value.code=d),length:6,"focus-first":!0,"data-test":"auth-code-input",onAutoSubmit:s},null,8,["modelValue"]),be(Xa,{"data-test":"auth-verify-code",theme:"dark",size:"md",class:"w-full",loading:r.value,disabled:i.value.code.length!==6||r.value,onClick:s},{default:ot(()=>[...u[7]||(u[7]=[xt(" Verify ",-1)])]),_:1},8,["loading","disabled"]),b("button",{class:"w-full text-xs text-theme-300 hover:text-theme-500 transition-colors py-1 cursor-pointer",onClick:u[3]||(u[3]=d=>n.value="email")}," Use a different email ")])):te("",!0)])]))}}),KL={"data-test":"create-panel",class:"flex flex-col justify-end h-full px-5 pb-8 pt-6"},WL={class:"flex-1 flex flex-col justify-center"},qL={key:0,class:"text-xs text-red-500 mb-4"},GL={class:"space-y-3"},JL=["disabled"],YL=Pe({__name:"ElCreateBot",props:{sdk:{}},emits:["created"],setup(e,{emit:t}){let n=t,i=Q(""),r=Q(!1),o=Q(null);async function a(){if(!r.value&&i.value.trim()){r.value=!0,o.value=null;try{let s=e.sdk.currentOrg.value?.orgId??e.sdk.activeUser.value?.orgs?.[0]?.orgId;if(!s)throw Error("No workspace found. Please sign in again.");let l=await e.sdk.computer.create({orgId:s,primaryBot:{name:i.value.trim()}});n("created",l)}catch(s){o.value=s instanceof Error?s.message:"Failed to create bot"}finally{r.value=!1}}}return(s,l)=>(w(),$("div",KL,[b("div",WL,[l[1]||(l[1]=b("div",{class:"space-y-3 mb-10"},[b("h3",{class:"text-2xl font-light text-theme-900 leading-snug"},[xt(" What should we call"),b("br"),xt("your assistant? ")]),b("p",{class:"text-sm text-theme-400 leading-relaxed max-w-[260px]"}," Pick a name. You can change it later. ")],-1)),o.value?(w(),$("p",qL,de(o.value),1)):te("",!0)]),b("div",GL,[ep(b("input",{"onUpdate:modelValue":l[0]||(l[0]=u=>i.value=u),"data-test":"bot-name-input",type:"text",placeholder:"e.g. Alex, Casey, Jordan",class:"w-full px-4 py-3 text-theme-900 placeholder-theme-300 bg-theme-0 border border-theme-200 rounded-xl focus:outline-none focus:border-theme-900 transition-colors",style:{"font-size":"16px"},onKeyup:Gn(a,["enter"])},null,544),[[dp,i.value]]),b("button",{"data-test":"bot-create-btn",class:"w-full px-5 py-3.5 rounded-xl bg-primary-600 text-white text-sm font-medium transition-all duration-150 hover:bg-primary-500 active:scale-[0.98] disabled:opacity-50 disabled:cursor-not-allowed cursor-pointer",disabled:!i.value.trim()||r.value,onClick:a},de(r.value?"Creating...":"Create assistant"),9,JL)])]))}}),XL={"data-test":"provisioning-panel",class:"flex flex-col items-center justify-center h-full p-6"},QL={class:"w-full max-w-xs space-y-6 text-center"},eV={class:"text-sm text-theme-500"},tV={class:"text-sm text-red-500"},rV=Pe({__name:"ElProvisioningStatus",props:{sdk:{},computerId:{}},emits:["ready","error"],setup(e,{emit:t}){let n=e,i=t,r=Q("Setting up your assistant\u2026"),o=Q(!1),a=Q(""),s={starting:"Starting your assistant\u2026",running:"Ready!",stopped:"Setting up your assistant\u2026"};async function l(){o.value=!1,a.value="";try{await n.sdk.computer.waitUntilReady({computerId:n.computerId,onStatus:u=>{r.value=s[u]??"Setting up your assistant\u2026"}}),i("ready")}catch(u){o.value=!0,a.value=u instanceof Error?u.message:"Something went wrong",i("error",a.value)}}return Ut(()=>{l()}),(u,d)=>(w(),$("div",XL,[b("div",QL,[o.value?(w(),$(ge,{key:1},[b("p",tV,de(a.value),1),b("button",{"data-test":"provision-retry-btn",class:"px-6 py-2.5 rounded-lg bg-primary-600 text-white text-sm font-medium hover:bg-primary-500 transition-colors cursor-pointer",onClick:l}," Try again ")],64)):(w(),$(ge,{key:0},[d[0]||(d[0]=b("div",{class:"flex justify-center"},[b("div",{class:"animate-spin rounded-full size-6 border-2 border-theme-200 border-t-primary-500"})],-1)),b("p",eV,de(r.value),1)],64))])]))}});function nV(e){return e.hasToken?e.hasBot?e.isNewBot?e.provisionError?"error":e.botReady?"chat":"provisioning":"chat":"create":"auth"}var iV=["data-test-state"],oV={class:"flex items-center justify-between px-4 py-3 border-b border-theme-100"},aV={class:"text-sm font-medium text-theme-800"},sV={class:"flex-1 overflow-hidden"},lV={key:4,class:"flex flex-col items-center justify-center h-full p-6"},cV={class:"w-full max-w-xs space-y-6 text-center"},uV={class:"text-sm text-red-500"},dV={key:0,class:"border-t border-theme-100 px-4 py-2 text-center"},pV=["href"],mV=Pe({__name:"BotWidgetOnboard",props:{sdk:{},onClose:{type:Function}},setup(e){let t=e,n=t.sdk||Yl.getInstance({isDev:typeof window<"u"?window.location.hostname==="localhost"||window.location.hostname.includes("127.0.0.1"):!1}),i=We(),r=Q(!1),o=Q(),a=Q(!1),s=R(()=>i.value??n.currentBot.value),l=We(),u=We();mt(()=>s.value?.botId.value,k=>{if(!k||!s.value){l.value=void 0,u.value=void 0;return}let T=s.value;l.value=T,u.value=new sc({sdk:n,bot:T,chatStreamFn:async S=>{await n.chat.chatStreamAuthenticated({botId:k,orgId:T.computer.orgId.value,message:S.message,attachments:S.attachments?.map(z=>Y0.parse(z)),conversationId:S.conversationId,history:S.history,onDelta:S.onDelta,onDone:S.onDone,onError:S.onError,onStatus:S.onStatus,onToolActivity:S.onToolActivity,onWorkingEnd:S.onWorkingEnd})}})},{immediate:!0});let d=R(()=>nV({hasToken:!!n.token.value,hasBot:!!s.value,isNewBot:a.value,botReady:r.value,provisionError:o.value})),p=R(()=>`${Qn(n.apiBase,n.isDev)}/`);function m(k){i.value=k,o.value=void 0,r.value=!1,a.value=!0}function f(){r.value=!0}function h(k){o.value=k}function v(){o.value=void 0,r.value=!1}return(k,T)=>(w(),$("div",{class:"size-full flex flex-col bg-theme-0","data-test":"onboard-widget","data-test-state":d.value},[b("div",oV,[b("span",aV,de(s.value?.name.value||"PageLines"),1),t.onClose?(w(),$("button",{key:0,class:"text-theme-400 hover:text-theme-600 transition-colors cursor-pointer",onClick:T[0]||(T[0]=S=>t.onClose?.())},[...T[1]||(T[1]=[b("svg",{xmlns:"http://www.w3.org/2000/svg",class:"size-5",viewBox:"0 0 20 20",fill:"currentColor"},[b("path",{"fill-rule":"evenodd",d:"M4.293 4.293a1 1 0 011.414 0L10 8.586l4.293-4.293a1 1 0 111.414 1.414L11.414 10l4.293 4.293a1 1 0 01-1.414 1.414L10 11.414l-4.293 4.293a1 1 0 01-1.414-1.414L8.586 10 4.293 5.707a1 1 0 010-1.414z","clip-rule":"evenodd"})],-1)])])):te("",!0)]),b("div",sV,[d.value==="auth"?(w(),Fe(HL,{key:0,sdk:Ae(n)},null,8,["sdk"])):te("",!0),d.value==="create"?(w(),Fe(YL,{key:1,sdk:Ae(n),onCreated:m},null,8,["sdk"])):te("",!0),d.value==="provisioning"&&s.value?(w(),Fe(rV,{key:2,sdk:Ae(n),"computer-id":s.value.computerId.value,onReady:f,onError:h},null,8,["sdk","computer-id"])):te("",!0),d.value==="chat"&&l.value&&u.value?(w(),Fe(yo,{key:3,"chat-controller":u.value,bot:l.value,variant:"light",class:"size-full"},null,8,["chat-controller","bot"])):te("",!0),d.value==="error"?(w(),$("div",lV,[b("div",cV,[b("p",uV,de(o.value),1),b("button",{class:"px-6 py-2.5 rounded-lg bg-primary-600 text-white text-sm font-medium hover:bg-primary-500 transition-colors cursor-pointer",onClick:v}," Try again ")])])):te("",!0)]),d.value==="chat"?(w(),$("div",dV,[b("a",{href:p.value,target:"_blank",class:"text-xs text-theme-400 hover:text-primary-600 transition-colors"}," Go to Dashboard \u2192 ",8,pV)])):te("",!0)],8,iV))}}),fV={class:"relative size-16 rounded-full overflow-hidden"},hV=["src","alt"],gV={class:"flex items-center shrink-0 border-b border-theme-100 px-4 py-3"},vV={class:"flex items-center gap-3 flex-1 min-w-0"},bV=["src","alt"],yV={class:"min-w-0"},wV={class:"text-sm font-medium text-theme-900 truncate"},kV={class:"flex-1 overflow-hidden"},xV={class:"shrink-0 flex items-center justify-center border-t border-theme-100 py-1.5"},_V=["href"],$V=Up(Pe({__name:"BotWidgetPopup",props:{sdk:{},handle:{},bot:{},context:{},firstMessage:{},position:{},chatController:{}},setup(e,{expose:t}){let n=e,i=Q(!1),r=Q(!1),o=We(),{currentBot:a,currentContext:s,currentFirstMessage:l,update:u}=es(n),d=R(()=>({"bottom-left":"bottom-4 left-4 sm:bottom-6 sm:left-6","top-right":"top-4 right-4 sm:top-6 sm:right-6","top-left":"top-4 left-4 sm:top-6 sm:left-6","bottom-right":"bottom-4 right-4 sm:bottom-6 sm:right-6"})[n.position||"bottom-right"]),p=R(()=>({"bottom-left":"bottom left","top-right":"top right","top-left":"top left","bottom-right":"bottom right"})[n.position||"bottom-right"]),m=R(()=>({"bottom-left":"bottom-0 left-0","top-right":"top-0 right-0","top-left":"top-0 left-0","bottom-right":"bottom-0 right-0"})[n.position||"bottom-right"]);function f(T,S){n.chatController||o.value||(o.value=new sc({sdk:S,bot:T,context:s.value,firstMessage:l.value}))}mt(i,async T=>{if(!T||r.value)return;r.value=!0;let S=n.chatController||o.value;if(S)try{await S.startTextConversation()}catch(z){console.error("BotWidgetPopup: startTextConversation failed",z)}});function h(){i.value=!i.value}function v(){i.value=!0}function k(){i.value=!1}return t({toggle:h,open:v,close:k,update:u}),(T,S)=>(w(),Fe(Vp,{sdk:e.sdk,handle:e.handle,bot:Ae(a),context:Ae(s),"first-message":Ae(l)},{default:ot(({bot:z,sdk:j})=>[z?(w(),$("div",{key:0,ref:()=>f(z,j),class:V(["fixed z-[999999] pointer-events-auto",d.value])},[b("div",{class:V(["widget-container transform-gpu overflow-hidden",i.value?"w-[min(400px,calc(100vw-2rem))] h-[min(600px,calc(100vh-4rem))] shadow-[0_24px_80px_-12px_rgba(0,0,0,0.2),0_8px_24px_-8px_rgba(0,0,0,0.08)]":"w-16 h-16 shadow-[0_8px_32px_-4px_rgba(0,0,0,0.15)] cursor-pointer"]),style:Se({"border-radius":i.value?"16px":"32px","transform-origin":p.value}),onClick:S[0]||(S[0]=O=>i.value?void 0:h())},[b("div",{class:V(["absolute size-16 transition-opacity duration-200",[m.value,i.value?"opacity-0 pointer-events-none":"opacity-100"]])},[b("div",fV,[b("img",{src:Ae(dE)(z.toData()),alt:`${z.name.value} bot`,class:"h-full w-full object-cover pointer-events-none",width:"64",height:"64"},null,8,hV),S[1]||(S[1]=b("div",{class:"absolute inset-0 pointer-events-none bg-gradient-to-br from-transparent via-black/10 to-black/40 opacity-60"},null,-1))])],2),b("div",{class:V(["absolute inset-0 flex flex-col bg-white transition-opacity duration-250",i.value?"opacity-100":"opacity-0 pointer-events-none"])},[b("div",gV,[b("div",vV,[b("img",{src:z.avatarUrl.value,alt:z.name.value,class:"size-8 rounded-full object-cover shrink-0"},null,8,bV),b("div",yV,[b("div",wV,de(z.displayName.value),1),b("div",{class:V(["text-[11px]",z.desiredStatus.value==="active"?"text-green-500":"text-theme-400"])},de(z.desiredStatus.value==="active"?"Online":"Offline"),3)])]),b("button",{class:"cursor-pointer flex items-center justify-center p-2 -mr-1 rounded-xl text-theme-400 hover:text-theme-600 hover:bg-theme-50 transition-colors",onClick:Et(k,["stop"])},[...S[2]||(S[2]=[b("i",{class:"size-5 i-tabler-x"},null,-1)])])]),b("div",kV,[r.value?(w(),Fe(yo,{key:0,"chat-controller":e.chatController||o.value,bot:z,variant:"light","setup-hint":"","empty-state-message":"Send a message to get started"},null,8,["chat-controller","bot"])):te("",!0)]),b("div",xV,[b("a",{href:Ae(Hl).urls.app,target:"_blank",rel:"noopener",class:"text-[10px] text-theme-300 hover:text-theme-400 transition-colors"}," Learning Bot\u2122 by PageLines ",8,_V)])],2)],6),z.desiredStatus.value==="active"?(w(),$("div",{key:0,class:V(["absolute top-[5%] right-[5%] transition-opacity duration-200 pointer-events-none",i.value?"opacity-0":"opacity-100"])},[...S[3]||(S[3]=[b("div",{class:"size-3 bg-green-500 rounded-full ring-2 ring-white absolute animate-ping",style:{"animation-duration":"5s"}},null,-1),b("div",{class:"size-3 bg-green-500 rounded-full ring-2 ring-white"},null,-1)])],2)):te("",!0)],2)):te("",!0)]),_:1},8,["sdk","handle","bot","context","first-message"]))}}),[["__scopeId","data-v-5674cae2"]]),zn=co("PLWidget"),dc=class ko{static create(t){return new ko(t)}static collectPageContext(){if(typeof window>"u"||typeof document>"u")return"";let t=[],n=window.location.href;n&&t.push(`Page URL: ${n}`);let i=document.title;i&&t.push(`Page title: ${i}`);let r=document.querySelector('meta[name="description"]')?.getAttribute("content");r&&t.push(`Page description: ${r}`);let o=document.querySelector('meta[property="og:title"]')?.getAttribute("content");o&&o!==i&&t.push(`OG title: ${o}`);let a=document.referrer;a&&t.push(`Referrer: ${a}`);let s=window.location.pathname;return s&&s!=="/"&&t.push(`Path: ${s}`),t.join(`
|
|
168
|
+
\`\`\``)}))}else{let ue=SI(F);if(ue.ok)S.push({kind:"visual",key:`visual-${O}`,result:ue});else{typeof console<"u"&&console.warn("[pl-visual] parse_failed",{reason:ue.reason,message:ue.message,hasFallbackMarkdown:!!ue.fallbackMarkdown,payloadChars:F.length,...u(F)});let Je=ue.fallbackMarkdown?s(ue.fallbackMarkdown):"";Je&&S.push({kind:"markdown",key:`visual-${O}`,html:Je})}}j=U.index+U[0].length,O+=1,U=z.exec(k)}let J=k.slice(j),W=T?m.exec(J):null;if(W){let se=s(J.slice(0,W.index));return se&&S.push({kind:"markdown",key:`md-${O}`,html:se}),S.push({kind:"pending-visual",key:`pending-${O}`}),S}let ce=s(J);return ce&&S.push({kind:"markdown",key:`md-${O}`,html:ce}),S}let h=R(()=>{let v=r.value;return v?f({text:v,streaming:!!n.streaming}):[]});return(v,k)=>(w(),$("div",{class:V(["chat-msg-rich break-words",Ae(hU)]),onErrorCapture:p},[(w(!0),$(ge,null,st(h.value,T=>(w(),$(ge,{key:T.key},[T.kind==="markdown"?(w(),$("div",{key:0,class:V(["chat-msg-prose",e.inverted?"chat-msg-prose-invert":""]),innerHTML:T.html},null,10,gU)):T.kind==="visual"?(w(),Fe(fU,{key:1,result:T.result,inverted:e.inverted},null,8,["result","inverted"])):T.kind==="card"?(w(),Fe(ER,{key:2,spec:T.spec,inverted:e.inverted,onAction:k[0]||(k[0]=S=>i("action",S))},null,8,["spec","inverted"])):(w(),$("div",{key:3,"data-test":"chat-visual-pending",role:"status",class:"my-6 flex items-center gap-2.5 rounded-[20px] px-4 py-5 text-[12px] font-medium",style:Se({background:e.inverted?"transparent":"var(--color-theme-0)",boxShadow:`inset 0 0 0 1px ${e.inverted?"rgba(255, 255, 255, 0.14)":"color-mix(in oklch, var(--color-theme-900) 8%, transparent)"}`,color:e.inverted?"rgba(255, 255, 255, 0.6)":"var(--color-theme-500)"})},[...k[1]||(k[1]=[b("span",{class:"size-2 shrink-0 animate-pulse rounded-full",style:{background:"currentcolor"}},null,-1),xt(" Preparing chart\u2026 ",-1)])],4))],64))),128))],34))}}),vU=["data-composer-action"],bU=["placeholder","disabled","maxlength"],yU={class:"mt-2.5 flex items-center"},wU={class:"flex items-center gap-2"},kU=["data-composer-action","disabled","aria-label","title"],xU={key:0,class:"i-tabler-player-stop-filled size-3.5"},_U={key:1,class:"i-tabler-arrow-up size-[17px]"},$U={class:"sr-only"},SU=Pe({__name:"ChatComposer",props:C0({placeholder:{default:""},disabled:{type:Boolean,default:!1},maxlength:{},inverted:{type:Boolean,default:!1},showSend:{type:Boolean,default:!0},sendEnabled:{type:Boolean},sendLabel:{default:"Send"},action:{default:"send"}},{modelValue:{required:!0},modelModifiers:{}}),emits:C0(["submit","action"],["update:modelValue"]),setup(e,{expose:t,emit:n}){let i=n,r=NS(e,"modelValue"),o=Q();function a(u){u.isComposing||u.key==="Enter"&&!u.shiftKey&&(u.preventDefault(),i("submit"))}function s(u){e.disabled||u.target instanceof Element&&u.target.closest("button, a, textarea")||o.value?.focus()}mt(r,()=>oo(()=>{o.value&&(o.value.style.height="auto",o.value.style.height=`${Math.min(o.value.scrollHeight,150)}px`)}));function l(){let u=o.value;u&&(u.style.height="auto",window.matchMedia("(pointer: coarse)").matches?(u.blur(),requestAnimationFrame(()=>{let d=document.activeElement;d&&(d.tagName==="TEXTAREA"||d.tagName==="INPUT")&&d.blur()})):u.focus())}return t({focus:()=>o.value?.focus(),settleAfterSend:l}),(u,d)=>(w(),$("div",{"data-test":"messaging-composer","data-composer-action":e.action,class:V(["w-full cursor-text rounded-2xl px-4 pb-2.5 pt-4 transition-colors duration-200",e.inverted?"bg-white/10 backdrop-blur-xl ring-1 ring-white/15 hover:ring-white/25 focus-within:bg-white/15 focus-within:ring-white/25":"bg-white shadow-[0_1px_2px_rgba(15,23,42,0.04),0_12px_32px_rgba(15,23,42,0.07)] ring-1 ring-theme-950/20 hover:ring-theme-950/30 focus-within:ring-theme-950/30"]),onClick:s},[zt(u.$slots,"input",{},()=>[ep(b("textarea",{ref_key:"textarea",ref:o,"onUpdate:modelValue":d[0]||(d[0]=p=>r.value=p),"data-test":"messaging-input",rows:"1",enterkeyhint:"send",inputmode:"text",autocomplete:"off",autocapitalize:"sentences",autocorrect:"on",spellcheck:"true",placeholder:e.placeholder,disabled:e.disabled,maxlength:e.maxlength,style:{fontSize:"16px",resize:"none"},class:V(["block w-full bg-transparent leading-[1.5] focus:outline-none disabled:opacity-50 overflow-y-auto [scrollbar-width:none] [-ms-overflow-style:none] [&::-webkit-scrollbar]:hidden",e.inverted?"text-white placeholder-white/50":"text-theme-900 placeholder-theme-400"]),onKeydown:a},null,42,bU),[[dp,r.value]])]),b("div",yU,[zt(u.$slots,"leading"),d[2]||(d[2]=b("div",{class:"flex-1"},null,-1)),b("div",wU,[zt(u.$slots,"actions"),e.showSend?(w(),$("button",{key:0,"data-test":"messaging-send-btn","data-composer-action":e.action,class:V(["flex size-8 items-center justify-center rounded-full transition-colors duration-150 pointer-coarse:size-11",e.sendEnabled?e.inverted?"bg-theme-0 text-theme-950 hover:bg-theme-100 cursor-pointer":"bg-theme-900 text-theme-0 hover:bg-theme-800 cursor-pointer":e.inverted?"bg-white/10 text-white/30":"bg-theme-100 text-theme-400"]),disabled:!e.sendEnabled,"aria-label":e.sendLabel,title:e.sendLabel,onClick:d[1]||(d[1]=p=>i("action"))},[e.action==="stop"?(w(),$("i",xU)):(w(),$("i",_U)),b("span",$U,de(e.sendLabel),1)],10,kU)):te("",!0)])])],10,vU))}}),IU={class:"flex items-center gap-3 my-6 px-2"},EU=Pe({__name:"ChatDivider",props:{label:{},inverted:{type:Boolean,default:!1}},setup(e){return(t,n)=>(w(),$("div",IU,[b("div",{class:V(["flex-1 h-px",e.inverted?"bg-white/15":"bg-theme-200/70"])},null,2),b("span",{class:V(["text-[11px] font-medium shrink-0 tracking-[0.06em] uppercase",e.inverted?"text-white/50":"text-theme-400"])},de(e.label),3),b("div",{class:V(["flex-1 h-px",e.inverted?"bg-white/15":"bg-theme-200/70"])},null,2)]))}}),TU=80,NU=600,CU=Pe({__name:"ChatScroller",setup(e,{expose:t}){let n=Q(),i=Q(),r=Q(!0),o,a,s=0;function l(){let f=n.value;f&&(f.scrollTop=f.scrollHeight)}function u(){let f=n.value;f&&(r.value=f.scrollHeight-f.scrollTop-f.clientHeight<=TU)}function d(){s=Date.now()+NU}function p(){r.value&&Date.now()>s&&l()}function m(){r.value=!0,s=0,l(),requestAnimationFrame(()=>{l(),requestAnimationFrame(l)})}return t({pin:m}),Ut(()=>{requestAnimationFrame(()=>{l(),requestAnimationFrame(l)}),i.value&&(o=new ResizeObserver(p),o.observe(i.value),n.value&&o.observe(n.value),a=new MutationObserver(p),a.observe(i.value,{childList:!0,subtree:!0}))}),Da(()=>{o?.disconnect(),a?.disconnect()}),(f,h)=>(w(),$("div",{ref_key:"viewport",ref:n,class:V(["overflow-y-auto overscroll-contain overflow-x-hidden min-h-0 flex flex-col [scrollbar-width:none] [-ms-overflow-style:none] [&::-webkit-scrollbar]:hidden",r.value?"[overflow-anchor:none]":""]),onScrollPassive:u,onWheelPassive:d,onTouchstartPassive:d},[b("div",{ref_key:"content",ref:i,class:"flex-1 flex flex-col"},[zt(f.$slots,"default")],512)],34))}}),zU=["data-chat-turn"],AU=Pe({__name:"ChatTurn",props:{own:{type:Boolean},inverted:{type:Boolean,default:!1}},setup(e){return(t,n)=>(w(),$("div",{class:V(["group/msg flex items-end gap-2",e.own?"justify-end":"justify-start"]),"data-chat-turn":e.own?"own":"other"},[b("div",{"data-test":"messaging-message-body",class:V(e.own?"min-w-0 ml-3 @sm/chat:ml-[2em]":"w-full min-w-0 pr-3 @sm/chat:pr-[2em]")},[zt(t.$slots,"before"),t.$slots.default?(w(),$("div",{key:0,"data-test":"messaging-message-content",class:V(e.own?e.inverted?"rounded-[14px] px-4 py-2.5 bg-white/10 text-white":"rounded-[14px] px-4 py-2.5 bg-theme-50 text-theme-900":e.inverted?"text-white/95":"text-theme-900")},[zt(t.$slots,"default")],2)):te("",!0),zt(t.$slots,"after")],2)],10,zU))}}),OU=["aria-label"],DU={class:"absolute top-1/2 left-1/2 -translate-x-1/2 -translate-y-1/2 w-[28px] h-[28px] overflow-hidden"},PU=Pe({name:"FClose",__name:"FClose",props:{ariaLabel:{}},emits:["click"],setup(e){let t=Q(!1);return Ut(()=>{setTimeout(()=>{t.value=!0},100)}),(n,i)=>(w(),$("button",{type:"button","aria-label":e.ariaLabel||"Close",class:"close block cursor-pointer w-[60px] h-[60px] rounded-full transition-all duration-1000 ease-[cubic-bezier(0.25,1,0.33,1)] hover:scale-110 active:scale-90 hover:rotate-90",onClick:i[0]||(i[0]=r=>n.$emit("click",r))},[i[1]||(i[1]=b("span",{class:"absolute inset-0 rounded-full transition-all"},null,-1)),b("span",DU,[b("span",{class:V(["absolute h-full w-[3px] rounded-[5px] left-[13px] transition-all duration-[400ms] ease-[cubic-bezier(0.52,0.01,0.16,1)]",t.value?"translate-y-0 translate-x-0 rotate-45":"translate-y-[30px] -translate-x-[30px] rotate-0"]),style:{"background-color":"currentColor","transition-delay":"0.15s"}},null,2),b("span",{class:V(["absolute h-full w-[3px] rounded-[5px] left-[13px] transition-all duration-[400ms] ease-[cubic-bezier(0.52,0.01,0.16,1)]",t.value?"translate-y-0 translate-x-0 -rotate-45":"-translate-y-[30px] -translate-x-[30px] rotate-0"]),style:{"background-color":"currentColor","transition-delay":"0.45s"}},null,2)])],8,OU))}}),RU={class:"flex min-h-full items-center justify-center text-center p-4"},UU={key:0,class:"text-base p-4 font-semibold"},jU={key:1,class:"flex items-center gap-2 px-2"},jy=Pe({inheritAttrs:!1,name:"FModal",__name:"FModal",props:{vis:{type:Boolean,default:!1},modalClass:{},styleClass:{},fullScreen:{type:Boolean,default:!1},hasClose:{type:Boolean,default:!1},title:{default:""},transitionMode:{default:"modal"},teleportTo:{default:"body"},disableTeleport:{type:Boolean,default:!1}},emits:["update:vis","close","escape"],setup(e,{emit:t}){let n=t,i=Q(!1);function r(d){let{reason:p}=d;n("update:vis",!1),n("close",!0),p==="escape"&&n("escape",!0)}let o=R(()=>{let d=e.modalClass?[e.modalClass]:["max-w-screen-md p-24"],p=e.styleClass?[e.styleClass]:["bg-theme-0","shadow-xl"];return e.fullScreen?d.push("fixed inset-0"):d.push("rounded-2xl"),["relative","text-left","transform","transition-all","w-full","overflow-hidden",...d,...p]}),a=Q(!1),s=[];function l(d){d.key==="Escape"&&e.vis&&r({reason:"escape"})}Ut(async()=>{i.value=!0;let d=mt(()=>e.vis,p=>{p?setTimeout(()=>a.value=!0,300):a.value=!1},{immediate:!0});s.push(d),typeof document<"u"&&(document.addEventListener("keydown",l),s.push(()=>document.removeEventListener("keydown",l)))}),Wn(()=>{s.forEach(d=>d())});let u=R(()=>e.transitionMode==="slideUp"?{enterActiveClass:"ease-[cubic-bezier(0.25,1,0.33,1)] duration-500",enterFromClass:"opacity-0 translate-y-full scale-95",enterToClass:"opacity-100 translate-y-0 scale-100",leaveActiveClass:"ease-[cubic-bezier(0.25,1,0.33,1)] duration-500",leaveFromClass:"opacity-100 translate-y-0 scale-100",leaveToClass:"opacity-0 translate-y-full scale-95"}:{enterActiveClass:"ease-[cubic-bezier(0.25,1,0.33,1)] duration-500",enterFromClass:"opacity-0 scale-75",enterToClass:"opacity-100 translate-y-0 scale-100",leaveActiveClass:"ease-[cubic-bezier(0.25,1,0.33,1)] duration-500",leaveFromClass:"opacity-100 translate-y-0 scale-100",leaveToClass:"opacity-0 scale-75"});return(d,p)=>i.value?(w(),Fe(gS,{key:0,to:e.teleportTo,disabled:e.disableTeleport},[b("div",{class:V(["fixed inset-0 z-50",e.vis?"":"pointer-events-none"]),"aria-labelledby":"modal-title",role:"dialog","aria-modal":"true"},[be(so,{"enter-active-class":"ease-out duration-300","enter-from-class":"opacity-0","enter-to-class":"opacity-100","leave-active-class":"ease-in duration-200","leave-from-class":"opacity-100","leave-to-class":"opacity-0"},{default:ot(()=>[e.vis?(w(),$("div",{key:0,class:"fixed inset-0 bg-theme-800/60 active:bg-theme-800/80 cursor-pointer dark:bg-theme-600/90 backdrop-blur-sm transition-opacity",onClick:p[0]||(p[0]=m=>r({reason:"escape"}))})):te("",!0)]),_:1}),b("div",{class:"fixed inset-0 z-40 overflow-y-auto overscroll-contain no-scrollbar",onClick:p[3]||(p[3]=m=>r({reason:"escape"}))},[b("div",RU,[be(so,xa(Ra(u.value)),{default:ot(()=>[e.vis?(w(),$("div",{key:0,class:V([o.value,"w-full"]),onClick:p[2]||(p[2]=Et(()=>{},["stop"]))},[e.hasClose||e.title||d.$slots.actions?(w(),$("div",{key:0,class:V(!e.title&&(e.hasClose||d.$slots.actions)?"absolute top-0 right-0 z-10":"flex justify-between items-center")},[e.title?(w(),$("h2",UU,de(e.title),1)):te("",!0),e.hasClose||d.$slots.actions?(w(),$("div",jU,[zt(d.$slots,"actions"),e.hasClose?(w(),Fe(PU,{key:0,class:"relative","data-test-id":"close-modal",onClick:p[1]||(p[1]=Et(m=>r({reason:"escape"}),["stop"]))})):te("",!0)])):te("",!0)],2)):te("",!0),zt(d.$slots,"default")],2)):te("",!0)]),_:3},16)])])],2)],8,["to","disabled"])):te("",!0)}}),MU={"data-test":"share-reply-dialog",class:"flex flex-col"},LU={class:"flex h-[60px] shrink-0 items-center justify-between border-b border-theme-950/[0.06] px-5"},VU={class:"flex flex-col gap-4 p-5"},FU={class:"relative max-h-[300px] overflow-hidden rounded-2xl bg-theme-25 p-4 ring-1 ring-theme-950/[0.06]"},BU={class:"flex flex-col gap-3 text-[13px] leading-relaxed text-theme-800"},ZU={key:0,class:"max-w-[85%] self-end whitespace-pre-wrap rounded-[14px] bg-theme-50 px-3 py-2"},HU={key:0,class:"flex h-11 items-center gap-2 rounded-xl bg-theme-50 px-3"},KU=["value"],WU={key:1,class:"text-[13px] text-red-600"},qU={class:"flex items-center gap-3"},GU=["disabled"],JU=["disabled"],YU=Pe({__name:"ShareReplyDialog",props:{message:{},prompt:{},share:{}},emits:["close"],setup(e,{emit:t}){let n=t,i=Q(),r=Q(!1),o=Q(!1),a=Q(!1),s=Q(),l;mt(()=>e.message?.id,async p=>{if(i.value=void 0,s.value=void 0,a.value=!1,p){r.value=!0;try{i.value=(await e.share.get({messageId:p}))?.url}catch{s.value="Could not load this reply's link."}finally{r.value=!1}}},{immediate:!0});async function u(){if(e.message&&!o.value){o.value=!0,s.value=void 0;try{i.value??(i.value=(await e.share.create({messageId:e.message.id})).url)}catch{s.value="Could not create a link. Try again.",o.value=!1;return}try{await navigator.clipboard.writeText(i.value),a.value=!0,clearTimeout(l),l=setTimeout(()=>{a.value=!1},1500)}catch{s.value="Copy the link from the field above."}finally{o.value=!1}}}async function d(){if(e.message&&!o.value){o.value=!0,s.value=void 0;try{await e.share.remove({messageId:e.message.id}),i.value=void 0,a.value=!1}catch{s.value="Could not delete the link. Try again."}finally{o.value=!1}}}return(p,m)=>(w(),Fe(jy,{vis:!!e.message,"modal-class":"w-full max-w-[480px] p-0",onClose:m[2]||(m[2]=f=>n("close"))},{default:ot(()=>[b("div",MU,[b("div",LU,[m[4]||(m[4]=b("span",{class:"text-[15px] font-semibold text-theme-900"},"Share reply",-1)),b("button",{type:"button","aria-label":"Close",class:"grid size-9 cursor-pointer place-items-center rounded-full text-theme-500 transition-colors hover:bg-theme-950/5 hover:text-theme-900",onClick:m[0]||(m[0]=f=>n("close"))},[...m[3]||(m[3]=[b("i",{class:"i-tabler-x size-[17px]","aria-hidden":"true"},null,-1)])])]),b("div",VU,[b("div",FU,[b("div",BU,[e.prompt?(w(),$("div",ZU,de(e.prompt),1)):te("",!0),e.message?(w(),Fe(Wa,{key:1,text:e.message.text},null,8,["text"])):te("",!0)]),m[5]||(m[5]=b("div",{class:"pointer-events-none absolute inset-x-0 bottom-0 h-16 bg-gradient-to-t from-theme-25 to-transparent"},null,-1))]),m[8]||(m[8]=b("p",{class:"text-[13px] leading-relaxed text-theme-500"}," Anyone with the link can see this message and reply. Messages after it stay private. ",-1)),i.value?(w(),$("div",HU,[m[6]||(m[6]=b("i",{class:"i-tabler-link size-[15px] shrink-0 text-theme-400","aria-hidden":"true"},null,-1)),b("input",{"data-test":"share-reply-url",value:i.value,readonly:"","aria-label":"Share link",class:"min-w-0 flex-1 truncate bg-transparent text-[14px] text-theme-800 outline-none",onFocus:m[1]||(m[1]=f=>f.target.select())},null,40,KU)])):te("",!0),s.value?(w(),$("p",WU,de(s.value),1)):te("",!0),b("div",qU,[i.value?(w(),$("button",{key:0,type:"button","data-test":"share-reply-delete",disabled:o.value,class:"flex h-11 cursor-pointer items-center gap-1.5 px-1 text-[14px] font-medium text-theme-500 transition-colors hover:text-red-600 disabled:opacity-50",onClick:d},[...m[7]||(m[7]=[b("i",{class:"i-tabler-trash size-[15px]","aria-hidden":"true"},null,-1),xt(" Delete link ",-1)])],8,GU)):te("",!0),b("button",{type:"button","data-test":"share-reply-copy",disabled:r.value||o.value,class:"ml-auto h-11 cursor-pointer rounded-full bg-theme-900 px-5 text-[15px] font-semibold text-theme-0 transition-transform active:scale-[0.98] disabled:opacity-50",onClick:u},de(a.value?"Copied":"Copy link"),9,JU)])])])]),_:1},8,["vis"]))}}),XU={VOICE_MIC_UNAVAILABLE:"I couldn't reach your microphone. Check that this site is allowed to use it, then try again.",VOICE_BOT_UNAVAILABLE:"Your assistant didn't pick up. Give it a moment and start the call again.",VOICE_CONNECT_TIMEOUT:"The call took too long to connect. Try again in a moment.",VOICE_CONNECTION_LOST:"The call dropped. Start it again when you're ready.",VOICE_BUSY:"Your assistant is on another call. Try again in a moment, or keep going by typing.",VOICE_UNAVAILABLE:"Voice isn't available right now. You can keep going by typing.",VOICE_MINT_INVALID:"That call couldn't be started. Refresh the page and try again.",VOICE_PROVIDER_ERROR:"The call ended unexpectedly. Try again, or keep going by typing."},QU="The call ended unexpectedly. Try again, or keep going by typing.";Rp=[0,2,4,6,8],OE=5,tj=33,rj=.7,nj=.1,ij=60,oj=320,aj=.55,sj=.1,lj=.32,cj=.9,yy=Rp.map(()=>0),uj=Rp.map(()=>OE),dj=class{constructor(e=typeof window>"u"?void 0:window){G(this,"browser",void 0),G(this,"heights",We(uj)),G(this,"targetBars",yy),G(this,"displayBars",yy),G(this,"level",{source:"mic",level:0}),G(this,"isMuted",!1),G(this,"usesIdleWave",!1),G(this,"frameId",0),G(this,"lastFrameAt",0),G(this,"easeFrame",t=>{let n=this.browser;if(!n)return;this.frameId=0;let i=Math.min(64,Math.max(0,t-this.lastFrameAt));this.lastFrameAt=t;let r=this.usesIdleWave?Rp.map((a,s)=>{let l=t/1e3*aj*2*Math.PI-s*cj;return sj+lj*(Math.sin(l)+1)/2}):this.targetBars;this.displayBars=this.displayBars.map((a,s)=>{let l=r[s]??0,u=l>a?ij:oj;return a+(l-a)*(1-Math.exp(-i/u))}),this.publish();let o=this.displayBars.every((a,s)=>Math.abs((r[s]??0)-a)<=5e-4);(this.usesIdleWave||!o)&&(this.frameId=n.requestAnimationFrame(this.easeFrame))}),this.browser=e}updateLevel(e){this.level=e,this.updateTargets()}setMuted(e){this.isMuted=e,this.updateTargets()}setIdleWave(e){this.usesIdleWave!==e&&(this.usesIdleWave=e,this.start())}stop(){this.frameId&&this.browser?.cancelAnimationFrame(this.frameId),this.frameId=0}updateTargets(){let e=n=>Math.max(0,n-nj)/.9,t=this.isMuted&&this.level.source==="mic";this.targetBars=Rp.map(n=>t?0:e(Math.min(1,Math.max(0,this.level.bands?.[n]??this.level.level)))),this.start()}start(){!this.browser||this.browser.matchMedia("(prefers-reduced-motion: reduce)").matches?(this.displayBars=this.usesIdleWave?yy:this.targetBars,this.publish()):this.frameId||(this.lastFrameAt=this.browser.performance.now(),this.frameId=this.browser.requestAnimationFrame(this.easeFrame))}publish(){this.heights.value=this.displayBars.map(e=>Math.round((OE+Math.min(1,Math.max(0,e))**rj*tj)*10)/10)}},pj={connecting:{label:"Connecting",tone:"bg-amber-500",waits:!0},listening:{label:"Listening",tone:"bg-green-500",waits:!1},thinking:{label:"Thinking",tone:"bg-amber-500",waits:!0,visibleText:"Thinking"},working:{label:"Working",tone:"bg-primary-500",waits:!0},speaking:{label:"Speaking",tone:"bg-primary-500",waits:!1},error:{label:"Connection problem",tone:"bg-red-500",waits:!1,visibleText:"Connection lost"}};hj=["data-voice-state","data-voice-activity"],gj=["src"],vj={key:1,"data-test":"voice-background-fallback","aria-hidden":"true",class:"pointer-events-none absolute inset-0 bg-[#0A1522]"},bj={"data-test":"voice-stage",class:"relative z-10 flex flex-1 flex-col items-center px-8"},yj={"data-voice-assistant-avatar":""},wj={"data-test":"voice-lower-stage",class:"flex flex-1 flex-col items-center pt-10"},kj={"data-test":"voice-histogram","aria-hidden":"true",class:"flex h-[38px] items-center gap-[5px]"},xj={"data-test":"voice-presence-status",role:"status","aria-live":"polite",class:"sr-only"},_j=["data-taking-longer"],$j={class:"absolute inset-x-0 bottom-0 z-20 flex items-center justify-between px-14 pb-[max(3rem,env(safe-area-inset-bottom))] sm:px-12"},Sj=["disabled","aria-label","aria-pressed","title"],Ij=Pe({__name:"VoiceMode",props:{bot:{},chatController:{},isLight:{type:Boolean},backdropSrc:{}},emits:["end"],setup(e,{expose:t,emit:n}){let i=n,r=We(!1),o=We(),a=We(!1),s=We({user:!1,bot:!1}),l=We({active:!1}),u=We(!1),d=We(!1),p=We(),m=R(()=>p.value?.state.value??"idle"),f=R(()=>p.value?.isMuted.value??!1),h=new dj,v=h.heights,k=T0("endButton"),T=T0("muteButton"),S=!1,z,j,O,U=R(()=>fj({sessionState:m.value,hadError:r.value,providerThinking:a.value,speaking:s.value,work:l.value,isMuted:f.value,takingLonger:u.value})),J=R(()=>{if(U.value.activity==="thinking")return"thinking";if(U.value.activity==="working")return`working:${l.value.description??""}`});mt(()=>U.value.usesIdleWave,F=>h.setIdleWave(F),{immediate:!0}),mt(f,F=>h.setMuted(F),{immediate:!0}),mt(J,F=>{O&&clearTimeout(O),u.value=!1,F&&(O=setTimeout(()=>{O=void 0,u.value=!0},uE),O.unref?.())},{immediate:!0});async function W(){S=!0,await p.value?.end()}t({end:W});function ce(){S||(S=!0,i("end",z))}function se(F){F.shiftKey&&document.activeElement===k.value?(F.preventDefault(),T.value?.focus()):!F.shiftKey&&document.activeElement===T.value&&(F.preventDefault(),k.value?.focus())}async function pe(){let F=p.value;F&&!d.value&&(d.value=!0,await F.toggleMuted(),d.value=!1)}return Ut(async()=>{k.value?.focus({preventScroll:!0});let F=e.chatController?.createVoiceClient({onLevel:ue=>h.updateLevel(ue),onEnded:ue=>{z=ue},onStateChange:ue=>{ue==="ended"&&(r.value?j=setTimeout(ce,1600):ce())},onThinkingChange:ue=>{a.value=ue},onSpeakingChange:ue=>{s.value=ue},onWorkChange:ue=>{l.value=ue},onError:ue=>{r.value=!0,ue.code!=="VOICE_CONNECTION_LOST"&&(o.value=ej(ue.code)),e.chatController?.logger?.warn("voice.session.failed",{code:ue.code,providerMessage:ue.message})},onMetric:ue=>{e.chatController?.logger?.info(ue.name,{durationMs:ue.durationMs})}});F?(p.value=F,await F.start()):ce()}),Wn(()=>{S=!0,j&&clearTimeout(j),O&&clearTimeout(O),h.stop(),p.value?.end()}),(F,ue)=>(w(),$("div",{"data-test":"voice-mode","data-voice-state":m.value,"data-voice-activity":U.value.activity,class:"relative flex min-h-0 flex-1 flex-col overflow-hidden bg-[#0A1522] text-white",onKeydown:Gn(se,["tab"])},[e.backdropSrc?(w(),$("img",{key:0,"data-test":"voice-background-image",src:e.backdropSrc,alt:"","aria-hidden":"true",draggable:"false",class:"pointer-events-none absolute inset-0 size-full object-cover"},null,8,gj)):(w(),$("div",vj)),ue[2]||(ue[2]=b("div",{"data-test":"voice-background-overlay","aria-hidden":"true",class:"pointer-events-none absolute inset-0 bg-gradient-to-b from-[#050F19]/82 via-[#050F19]/90 to-[#050F19]/99"},null,-1)),b("div",bj,[ue[0]||(ue[0]=b("div",{"data-test":"voice-stage-spacer","aria-hidden":"true",class:"flex-1"},null,-1)),b("div",yj,[be(xy,{bot:e.bot,"show-status":!1,"show-owner-mark":!1,"is-light":!1,class:"size-32"},null,8,["bot"])]),b("div",wj,[b("div",kj,[(w(!0),$(ge,null,st(Ae(v),(Je,ct)=>(w(),$("span",{key:ct,"data-test":"voice-histogram-bar",class:V(["w-[5px] rounded-full transition-colors duration-150",U.value.tone]),style:Se({height:`${Je}px`})},null,6))),128))]),b("div",xj,de(o.value??U.value.label),1),b("p",{"data-test":"voice-visible-status","data-taking-longer":U.value.takingLonger||void 0,"aria-hidden":"true",class:"mt-5 min-h-5 text-center text-sm font-medium tracking-wide text-white/80"},de(o.value??U.value.visibleStatus),9,_j)])]),b("div",$j,[b("button",{ref_key:"endButton",ref:k,type:"button","data-test":"voice-end-btn",class:"flex size-16 cursor-pointer items-center justify-center rounded-full bg-white/10 text-white ring-1 ring-white/20 transition-colors hover:bg-white/15 active:bg-white/25","aria-label":"Hang up",title:"Hang up",onClick:ce},[...ue[1]||(ue[1]=[b("i",{class:"i-tabler-x size-[25px]","aria-hidden":"true"},null,-1)])],512),b("button",{ref_key:"muteButton",ref:T,type:"button","data-test":"voice-mute-btn",class:V(["flex size-16 items-center justify-center rounded-full ring-1 transition-colors active:opacity-70",[f.value?"bg-white text-[#050F19] ring-white":"bg-white/10 text-white ring-white/20",m.value==="live"&&!d.value?"cursor-pointer":"cursor-default opacity-50"]]),disabled:m.value!=="live"||d.value,"aria-label":f.value?"Unmute microphone":"Mute microphone","aria-pressed":f.value,title:f.value?"Unmute microphone":"Mute microphone",onClick:pe},[b("i",{class:V([f.value?"i-tabler-microphone-off":"i-tabler-microphone","size-[25px]"]),"aria-hidden":"true"},null,2)],10,Sj)])],40,hj))}}),Ej={key:0,class:"pb-4"},Tj={key:1,"data-test":"messaging-sdk-header",class:"shrink-0 border-b border-theme-100 px-4 py-3"},Nj={class:"min-w-0 flex-1"},Cj={class:"truncate text-base font-semibold leading-tight text-theme-900"},zj={class:"mt-1 truncate text-sm leading-tight text-theme-500"},Aj={key:0,class:"shrink-0 rounded-full bg-theme-50 px-2.5 py-1 font-mono text-[11px] font-medium text-theme-500"},Oj=["aria-label"],Dj={key:0,"data-test":"messaging-empty-state",class:"flex flex-col items-center justify-center px-4"},Pj=["title"],Rj=["data-journal-outcome"],Uj=["data-message-id","data-message-sender","data-conversation-id","data-message-sequence","data-system-kind","data-issue-code","data-issue-bucket","data-issue-action-label","data-issue-action-url","data-streaming"],jj={class:"flex items-center gap-3"},Mj=["href"],Lj=["data-test","data-message-id","data-message-sender","data-conversation-id","data-message-sequence","data-system-kind","data-routine-run-id"],Vj=["data-message-id","data-message-sender","data-conversation-id","data-message-sequence","data-system-kind","data-issue-code","data-issue-bucket","data-streaming"],Fj=["data-routine-run-id"],Bj=["src","alt"],Zj=["src"],Hj=["href"],Kj={key:0,"data-test":"messaging-message-text-part"},Wj=["src","alt","data-attachment-placement"],qj=["src","data-attachment-placement"],Gj=["href","data-attachment-placement"],Jj=["data-actions-reveal"],Yj=["data-copied","title","aria-label","onClick"],Xj=["onClick"],Qj=["onClick"],eM=["data-journal-outcome"],tM=["data-journal-outcome"],rM=["data-test","data-working-description"],nM={key:0,class:"truncate"},iM={key:1,class:"sr-only"},oM=["data-issue-code"],aM={class:"min-w-0 flex-1"},sM={"data-test":"messaging-transient-issue-title",class:"font-medium"},lM={"data-test":"messaging-transient-issue-help"},cM=["href"],uM=["inert","aria-hidden"],dM=["data-seat-state"],pM=["src","alt"],mM={class:"max-w-20 truncate"},fM=["onClick"],hM={key:0,class:"shrink-0 flex items-center justify-center size-14"},gM={class:"font-mono text-sm tabular-nums"},vM=["disabled","aria-label","title"],bM={key:0,class:"i-svg-spinners-ring-resize size-5"},yM={key:1,class:"i-tabler-plus size-5"},wM={class:"sr-only"},kM=["aria-label","title"],xM={class:"sr-only"},_M=["disabled","aria-label","title"],$M={class:"flex h-4 items-center gap-[2px]","aria-hidden":"true"},SM={key:2,"data-test":"messaging-ai-notice",class:"mx-auto max-w-[640px] @5xl/chat:max-w-[720px] pt-3 text-center text-[11.5px] leading-none text-theme-300"},yo=Up(Pe({__name:"ElBotChat",props:{chatController:{},bot:{},variant:{default:"dark"},scope:{default:"private"},scopeName:{},setupHint:{},emptyStateMessage:{},showHeader:{type:Boolean,default:!1},headerMeta:{},centered:{type:Boolean,default:!1}},setup(e){let t={private:{icon:"i-tabler-lock",label:"Private",tooltip:"Only you can see this conversation"},org:{icon:"i-tabler-users",label:"Workspace",tooltip:"Visible to workspace members"},public:{icon:"i-tabler-globe",label:"Public",tooltip:"Anyone with the link can see this"}},n=R(()=>{let ee={...t[e.scope]};return e.scope==="org"&&e.scopeName&&(ee.label=e.scopeName,ee.tooltip=`Visible to ${e.scopeName} members`),ee}),i=Q(),r=Q(),o=Q();function a(ee){return ee?/\[[^\]]+\]\([^)]+\)/.test(ee):!1}function s(ee){return ee.sender==="system"&&(!!ee.issue||ee.id===pe.value)}function l(ee,L){let H=ee[L],Qe=ee[L+1];return!Qe||Qe.sender!==H.sender}let u=R(()=>e.chatController?.textState.value),d=R(()=>u.value?.isConnected??!1),p=R(()=>u.value?.isThinking??!1),m=R(()=>u.value?.connectionStatus!=="connected"&&!u.value?.error),f=R(()=>e.chatController?.liveTurnBlocks?.value??[]),h=R(()=>{for(let ee=f.value.length-1;ee>=0;ee--){let L=f.value[ee];if(L?.kind==="text")return L.id}}),v=R(()=>e.chatController?.liveStreamMessageId?.value),k=R(()=>{let ee=e.chatController?.sharedMessages.value??[];return f.value.length&&v.value?ee.filter(L=>L.id!==v.value):ee}),T=R(()=>{if(!e.chatController?.workJournal?.value)return u.value?.workingDescription?.trim()||void 0}),S=R(()=>e.chatController?.workJournal?.value),z=R(()=>{if(!S.value&&!f.value.length)return;let ee=k.value,L=ee[ee.length-1];if(L)return L.sender==="bot"||L.sender==="system"?ee.length>=2?ee[ee.length-2].id:void 0:L.id}),j=R(()=>{let ee={};for(let L of k.value){if(L.sender==="user"||!L.toolActivities?.length)continue;let H=e.chatController?.workJournalFor?.({activities:L.toolActivities,outcome:h5(L),includeFailureNote:L.sender!=="system"});H&&(ee[L.id]=H)}return ee});function O(ee){return j.value[ee.id]}function U(ee,L){return ee.placement?.kind!=="inline"||!Number.isFinite(ee.placement.offset)?null:Math.max(0,Math.min(L.length,Math.trunc(ee.placement.offset)))}function J(ee,L){return ee.mediaId||`${ee.src}:${L}`}function W(ee){return(ee.attachments??[]).map((L,H)=>({attachment:L,index:H})).filter(({attachment:L})=>U(L,ee.text)===null)}function ce(ee){let L=ee.text??"";if(ee.sender!=="bot")return L?[{kind:"text",key:`${ee.id}:text`,text:L}]:[];let H=(ee.attachments??[]).map((bt,ut)=>({attachment:bt,index:ut,offset:U(bt,L)})).filter(bt=>bt.offset!==null).sort((bt,ut)=>bt.offset-ut.offset||bt.index-ut.index);if(H.length===0)return L?[{kind:"text",key:`${ee.id}:text`,text:L}]:[];let Qe=[],ke=0;for(let bt of H)bt.offset>ke&&Qe.push({kind:"text",key:`${ee.id}:text:${ke}`,text:L.slice(ke,bt.offset)}),Qe.push({kind:"attachment",key:`${ee.id}:attachment:${J(bt.attachment,bt.index)}`,attachment:bt.attachment,placement:"inline"}),ke=bt.offset;return ke<L.length&&Qe.push({kind:"text",key:`${ee.id}:text:${ke}`,text:L.slice(ke)}),Qe}let se=R(()=>u.value?.transientIssue),pe=R(()=>{if(!p.value)return;let ee=k.value,L=ee[ee.length-1];return L?.sender==="bot"||L?.sender==="system"?L.id:void 0}),F=R(()=>!p.value||T.value||S.value||f.value.length?!1:pe.value===void 0),ue=R(()=>!!T.value||F.value),Je=R(()=>u.value?.sendBlockedReason),ct=R(()=>Je.value==="bot_deleted"),ft=R(()=>m.value?"Connecting...":Je.value==="bot_deleted"?"This assistant was deleted":"Send a message"),Re=R(()=>X2(e.bot.state.value)),Be=R(()=>{if(ye.value||!Re.value||Re.value==="awake")return;let ee=e.bot.displayName.value||e.bot.name.value||"Your assistant";return Re.value==="changing"?`${ee} will be right back\u2026`:Re.value==="stuck"?`${ee} needs attention.`:`${ee} is ${Y2[Re.value].toLowerCase()}.`}),Mt=R(()=>e.chatController?.composerState?.value??{text:"",pendingAttachments:[],isUploading:!1}),Er=R({get:()=>Mt.value.text,set:ee=>e.chatController?.setComposerText?.({text:ee})}),mr=R(()=>Mt.value.pendingAttachments),gt=R(()=>Mt.value.isUploading),yt=R(()=>e.chatController?.voiceRecorder),Wr=R(()=>yt.value?.isBusy.value??!1),Tt=R(()=>e.chatController?.canAttachFile?.value??!1),Ye=R(()=>e.chatController?.canRecordAudio?.value??!1),Ht=R(()=>e.chatController?.composerAction?.value??"idle"),er=R(()=>Ht.value!=="idle"),Tr=R(()=>e.chatController?.composerShowsSecondaryStop?.value??!1),fr=R(()=>e.chatController?.queuedMessageIds?.value);function qr(ee){return fr.value?.has(ee)??!1}let hr=Q(),x;function I(ee){return ee.sender==="bot"&&ee.id!==pe.value&&!!ee.text?.trim()}let M=R(()=>[...k.value].reverse().find(I)?.id);async function B(ee){try{await navigator.clipboard.writeText(ee.text),hr.value=ee.id,clearTimeout(x),x=setTimeout(()=>{hr.value=void 0},1500)}catch(L){console.warn("ElBotChat: copy to clipboard rejected",L),e.chatController?.notify?.("Could not copy that message.")}}Wn(()=>clearTimeout(x));let X=R(()=>e.chatController?.canReportMessages??!1),_=R(()=>e.chatController?.messageShare),D=Q(),y=R(()=>{let ee=D.value;if(!ee)return;let L=k.value,H=L.findIndex(Qe=>Qe.id===ee.id);return L.slice(0,Math.max(H,0)).reverse().find(Qe=>Qe.sender==="user")?.text}),P=R(()=>Ht.value==="stop"?"Stop reply":Tr.value?"Send \u2014 answered after current work":"Send message"),E=R(()=>Ye.value&&!Wr.value&&!!yt.value?.canUseBrowserRecording),Y=R(()=>yt.value?.isActive.value??!1),ie=R(()=>yt.value?.state.value.phase==="sending"),fe=R(()=>yt.value?.elapsedLabel.value??"0:00"),ve=R(()=>{let ee=yt.value?.state.value.phase;return ee==="preparing"||ee==="sending"?yt.value?.statusText.value??"Starting microphone":dn.value?"Release to send":"Click mic to send"}),we=R(()=>yt.value?.state.value.phase==="sending"?"Sending voice message":Y.value?dn.value?"Release to send voice message":"Stop and send voice message":"Record voice message"),ye=Q(!1),Ne=Q(),Me=Q(),Xe=Q(),wt=0,$t=R(()=>e.chatController?.canStartVoice?.value??!1);mt([()=>e.bot.avatar.value?.src,$t],([ee,L])=>{let H=++wt;if(Xe.value=void 0,!L||!ee||typeof Image>"u")return;let Qe=new Image;Qe.onload=()=>{H===wt&&(Xe.value=ee)},Qe.src=ee},{immediate:!0});let St=R(()=>$t.value&&!ye.value&&!Y.value&&Ht.value==="idle"),Kt=R(()=>!d.value),vt=R(()=>Kt.value?`Voice available when ${e.bot.displayName.value||e.bot.name.value||"the assistant"} is awake`:"Start voice conversation");function Nt(){St.value&&!Kt.value&&(Me.value=Xe.value,ye.value=!0)}async function Gr(ee){if(!ye.value)return;let L=Ne.value;ye.value=!1,Me.value=void 0,await oo(),await L?.end(),window.matchMedia("(pointer: coarse)").matches||r.value?.focus(),await e.chatController?.refreshMessages(),ee&&e.chatController?.notify(T5(ee,e.bot.displayName.value||e.bot.name.value||"Your assistant"),{systemKind:"voice_ended"})}let $e=R(()=>e.variant==="light"),rs=R(()=>$e.value?"bg-theme-200/70":"bg-white/15"),zi=R(()=>$e.value?"text-theme-300":"text-white/30");Ut(async()=>{e.chatController&&!d.value&&await e.chatController.startTextConversation()}),Wn(()=>{e.chatController?.voiceRecorder?.teardown()});async function xo(){e.chatController&&Ht.value==="send"&&(r.value?.settleAfterSend(),i.value?.pin(),await e.chatController.sendComposerMessage())}async function Jr(ee){e.chatController&&!ct.value&&(i.value?.pin(),await e.chatController.sendChatMessage(ee))}async function ni(){e.chatController&&(Ht.value==="send"?await xo():await e.chatController.handleComposerAction())}function On(){o.value?.click()}async function pc(ee){let L=ee.target,H=L.files?.[0];H&&e.chatController&&!Wr.value&&(await e.chatController.attachFile({file:H}),L.value="")}function mc(ee){e.chatController?.removeAttachment({index:ee})}function ns(){yt.value?.start()}function ii(ee){yt.value?.finish(ee)}let dn=We(!1),Dn=!1;function _o(ee){ee.pointerType==="touch"&&(Dn=!0,dn.value=!0,ee.currentTarget.setPointerCapture?.(ee.pointerId),ns())}function Ur(ee){ee.pointerType==="touch"&&dn.value&&(dn.value=!1,ii({cancelled:!1}))}function oi(ee){ee.pointerType==="touch"&&dn.value&&(dn.value=!1,Dn=!1,ii({cancelled:!0}))}function is(){Y.value?ii({cancelled:!1}):ns()}function os(){Dn?Dn=!1:is()}function fc(ee,L){if(L===0){let bt=ee[L];return bt?.timestamp?as(new Date(bt.timestamp)):null}let H=ee[L-1],Qe=ee[L];if(!H?.timestamp||!Qe?.timestamp)return null;let ke=new Date(H.timestamp).getTime();return new Date(Qe.timestamp).getTime()-ke>9e5?as(new Date(Qe.timestamp)):null}function as(ee){let L=new Date,H=ee.toDateString()===L.toDateString(),Qe=new Date(L);Qe.setDate(Qe.getDate()-1);let ke=ee.toDateString()===Qe.toDateString(),bt=ee.toLocaleTimeString("en-US",{hour:"numeric",minute:"2-digit"});if(H)return bt;if(ke)return`Yesterday, ${bt}`;let ut=ee.getFullYear()===L.getFullYear();return`${ee.toLocaleDateString("en-US",{weekday:"long",month:"short",day:"numeric",...ut?{}:{year:"numeric"}})}, ${bt}`}return(ee,L)=>(w(),$("div",{"data-test":"messaging-root",class:V(["@container/chat relative flex h-full flex-col",k.value.length===0?"min-h-0 [justify-content:safe_center] overflow-y-auto":""])},[e.showHeader&&!$e.value?(w(),$("div",Ej,[be(Lp,{bot:e.bot,"is-online":d.value},null,8,["bot","is-online"])])):e.showHeader?(w(),$("div",Tj,[b("div",{class:V(["flex items-center gap-3",e.centered?"max-w-[640px] @5xl/chat:max-w-[720px] mx-auto":""])},[be(xy,{bot:e.bot,"is-light":$e.value,class:"size-10"},null,8,["bot","is-light"]),b("div",Nj,[b("div",Cj,de(e.bot.displayName.value),1),b("div",zj,de(e.bot.title.value||"Assistant"),1)]),e.headerMeta?(w(),$("span",Aj,de(e.headerMeta),1)):te("",!0)],2)])):te("",!0),be(so,{name:"voice-call"},{default:ot(()=>[ye.value?(w(),$("div",{key:0,"data-test":"voice-call-overlay",role:"dialog","aria-modal":"true","aria-label":`Voice conversation with ${e.bot.displayName.value}`,class:"fixed inset-0 z-[100] flex items-stretch justify-stretch bg-[#050F19] sm:items-center sm:justify-center sm:bg-[#050F19]/45 sm:p-6",onKeydown:L[0]||(L[0]=Gn(H=>Gr(),["esc"]))},[be(Ij,{ref_key:"voiceMode",ref:Ne,bot:e.bot,"chat-controller":e.chatController,"backdrop-src":Me.value,"is-light":!1,class:"voice-call-card h-full w-full sm:max-h-[620px] sm:max-w-[420px] sm:flex-none sm:rounded-[32px] sm:shadow-[0_32px_80px_rgba(5,15,25,0.45)]",onEnd:Gr},null,8,["bot","chat-controller","backdrop-src"])],40,Oj)):te("",!0)]),_:1}),m.value?(w(),$("div",{key:2,class:V(["py-16 flex flex-col items-center justify-center gap-2 text-sm",$e.value?"text-theme-400":"text-theme-600"])},[be(zp,{class:"size-4"})],2)):e.setupHint?(w(),$("div",{key:3,class:V(["flex items-center justify-center gap-1.5 py-2 text-[11px]",zi.value])},[L[16]||(L[16]=b("i",{class:"i-tabler-tool size-3"},null,-1)),b("span",null,de(e.setupHint),1)],2)):te("",!0),be(CU,{ref_key:"chatScroller",ref:i,"data-test":"messaging-scroller",inert:ye.value,"aria-hidden":ye.value?"true":void 0,class:V([k.value.length===0?"flex-none":"flex-1",e.centered&&!e.showHeader&&k.value.length>0?"mt-16":""])},{default:ot(()=>[b("div",{class:V([k.value.length===0?"flex flex-col items-center justify-center px-3 py-4":e.centered?"pt-4 pb-5 px-3 @lg/chat:px-8 space-y-2":"pt-4 pb-[120px] px-3 @lg/chat:px-8 space-y-2",e.centered?k.value.length===0?"max-w-[900px] mx-auto w-full":"max-w-[640px] @5xl/chat:max-w-[720px] mx-auto w-full":""])},[k.value.length===0&&!m.value?(w(),$("div",Dj,[zt(ee.$slots,"empty-heading",{bot:e.bot,isLight:$e.value},()=>[be(xy,{bot:e.bot,"is-light":$e.value,class:"mb-4 size-20 @sm/chat:size-24"},null,8,["bot","is-light"]),b("div",{class:V(["text-base @sm/chat:text-lg font-semibold",$e.value?"text-theme-900":"text-white"])},de(e.bot.displayName.value),3)],!0),e.emptyStateMessage===""?te("",!0):(w(),$(ge,{key:0},[b("p",{class:V(["mt-1 text-center text-xs @sm/chat:text-sm",zi.value])},de(e.emptyStateMessage||"Type your message to get started."),3),b("div",{class:V(["inline-flex items-center gap-1.5 mt-5 px-2.5 py-1 rounded-full text-[11px]",$e.value?"bg-theme-50 border border-theme-100 text-theme-400":"bg-white/10 border border-white/20 text-white/40"]),title:n.value.tooltip},[b("i",{class:V([n.value.icon,"size-3"])},null,2),b("span",null,de(n.value.label),1)],10,Pj)],64))])):te("",!0),(w(!0),$(ge,null,st(k.value,(H,Qe)=>(w(),$(ge,{key:H.id},[fc(k.value,Qe)?(w(),Fe(EU,{key:0,"data-test":"messaging-time-divider",label:fc(k.value,Qe)||"",inverted:!$e.value},null,8,["label","inverted"])):te("",!0),O(H)?(w(),$("div",{key:1,"data-test":"messaging-message-tool-activity","data-journal-outcome":O(H)?.outcome,class:"mb-4 w-full"},[be(sy,{model:O(H),"is-light":$e.value},null,8,["model","is-light"])],8,Rj)):te("",!0),s(H)?(w(),$("section",{key:2,"data-test":"messaging-system-msg","data-message-id":H.id,"data-message-sender":H.sender,"data-conversation-id":H.conversationId,"data-message-sequence":H.sequence,"data-system-kind":H.systemKind,"data-issue-code":H.issue?.code,"data-issue-bucket":H.issue?.bucket,"data-issue-action-label":H.issue?.actionLabel,"data-issue-action-url":H.issue?.actionUrl,"data-streaming":H.id===pe.value?"true":void 0,class:"mb-6 w-full"},[b("div",{class:V(["mb-1.5 text-center text-[10.5px] font-medium",zi.value])},"System message",2),b("div",jj,[b("span",{"data-test":"messaging-system-divider-line","aria-hidden":"true",class:V(["hidden h-px flex-1 opacity-60 @md/chat:block",rs.value])},null,2),b("div",{class:V(["w-[46ch] min-w-0 max-w-full rounded-2xl px-5 py-3.5 text-center text-[13px] ring-1 [&_.chat-msg-rich]:max-w-none [&_.chat-msg-rich]:text-[13px] [&_.chat-msg-rich]:italic [&_.chat-msg-rich]:leading-[1.6]",$e.value?"text-theme-700 ring-theme-200/50":"text-white/85 ring-white/10"])},[H.text?(w(),Fe(Wa,{key:0,text:H.text,inverted:!$e.value,streaming:H.id===pe.value,onClick:L[1]||(L[1]=Et(()=>{},["stop"])),onAction:Jr},null,8,["text","inverted","streaming"])):H.issue?.help?(w(),Fe(Wa,{key:1,text:H.issue.help,inverted:!$e.value},null,8,["text","inverted"])):te("",!0),H.issue?.actionUrl&&!a(H.text)?(w(),$("a",{key:2,href:H.issue.actionUrl,"data-test":"messaging-system-msg-action",class:V(["mt-2 text-[12px] font-medium inline-flex items-center gap-1",$e.value?"text-theme-900 hover:text-theme-700":"text-white hover:text-white/80"]),onClick:L[2]||(L[2]=Et(()=>{},["stop"]))},[xt(de(H.issue.actionLabel)+" ",1),L[17]||(L[17]=b("i",{class:"i-tabler-arrow-right size-3"},null,-1))],10,Mj)):te("",!0)],2),b("span",{"data-test":"messaging-system-divider-line","aria-hidden":"true",class:V(["hidden h-px flex-1 opacity-60 @md/chat:block",rs.value])},null,2)])],8,Uj)):H.sender==="system"&&(H.systemKind==="routine_completed"||H.systemKind==="voice_ended")?(w(),$("div",{key:3,"data-test":H.systemKind==="routine_completed"?"messaging-routine-receipt":"messaging-voice-receipt","data-message-id":H.id,"data-message-sender":H.sender,"data-conversation-id":H.conversationId,"data-message-sequence":H.sequence,"data-system-kind":H.systemKind,"data-routine-run-id":H.routine?.run.routineRunId,class:V(["mb-6 flex items-center justify-center gap-2 text-[12px] leading-relaxed",$e.value?"text-theme-400":"text-white/50"])},[b("i",{class:V(["size-3.5 shrink-0",H.systemKind==="voice_ended"?"i-tabler-phone-off":"i-tabler-clock"]),"aria-hidden":"true"},null,2),b("span",null,de(H.text),1)],10,Lj)):H.sender==="system"?(w(),$("div",{key:4,"data-test":"messaging-system-status-msg","data-message-id":H.id,"data-message-sender":H.sender,"data-conversation-id":H.conversationId,"data-message-sequence":H.sequence,"data-system-kind":H.systemKind,"data-issue-code":H.issue?.code,"data-issue-bucket":H.issue?.bucket,"data-streaming":H.id===pe.value?"true":void 0,class:V(["mb-4 flex w-fit max-w-[85%] items-start gap-2 rounded-2xl px-3 py-2 text-[13px] leading-relaxed ring-1",$e.value?"bg-theme-100 text-theme-600 ring-theme-200":"bg-white/10 text-white/70 ring-white/10"])},[L[18]||(L[18]=b("i",{class:"i-tabler-info-circle size-4 mt-0.5 shrink-0","aria-hidden":"true"},null,-1)),be(Wa,{text:H.text,inverted:!$e.value,onClick:L[3]||(L[3]=Et(()=>{},["stop"]))},null,8,["text","inverted"])],10,Vj)):(w(),Fe(AU,{key:5,own:H.sender==="user",inverted:!$e.value,"data-test":H.sender==="bot"?"messaging-assistant-msg":H.sender==="user"?"messaging-user-msg":void 0,"data-message-id":H.id,"data-message-sender":H.sender,"data-conversation-id":H.conversationId,"data-message-sequence":H.sequence,"data-system-kind":H.systemKind,"data-streaming":H.id===pe.value?"true":void 0,"data-queued":qr(H.id)?"true":void 0,"aria-label":qr(H.id)?"Sent \u2014 will be answered after the current work finishes":void 0,class:V({"mb-4":l(k.value,Qe),"opacity-70":qr(H.id)})},Pa({before:ot(()=>[H.sender==="bot"&&H.routine?(w(),$("div",{key:0,"data-test":"messaging-routine-label","data-routine-run-id":H.routine.run.routineRunId,class:V(["mb-2 flex items-start gap-2 text-[12px] leading-relaxed",$e.value?"text-theme-400":"text-white/50"])},[L[19]||(L[19]=b("i",{class:"i-tabler-clock size-3.5 mt-0.5 shrink-0","aria-hidden":"true"},null,-1)),b("span",null,"Ran "+de(H.routine.run.name||H.routine.run.sourceLabel||"a routine"),1)],10,Fj)):te("",!0),W(H).length?(w(),$("div",{key:1,class:V(["mb-1 space-y-1",H.sender==="user"?"flex flex-col items-end":""])},[(w(!0),$(ge,null,st(W(H),({attachment:ke,index:bt})=>(w(),$(ge,{key:J(ke,bt)},[ke.type==="image"?(w(),$("img",{key:0,src:ke.src,alt:ke.filename,"data-test":"messaging-attachment","data-attachment-placement":"block",class:"rounded-xl object-cover max-h-48 max-w-[240px] @sm/chat:max-w-[320px]"},null,8,Bj)):ke.type==="audio"?(w(),$("audio",{key:1,src:ke.src,controls:"","data-test":"messaging-attachment","data-attachment-placement":"block",class:"max-w-full"},null,8,Zj)):(w(),$("a",{key:2,href:ke.src,target:"_blank",rel:"noopener","data-test":"messaging-attachment","data-attachment-placement":"block",class:V(["inline-flex items-center gap-1.5 px-3 py-1.5 rounded-lg text-xs",$e.value?"bg-theme-100 text-theme-600 hover:bg-theme-200":"bg-white/10 text-white/80 hover:bg-white/20"])},[L[20]||(L[20]=b("i",{class:"i-tabler-file size-3.5"},null,-1)),xt(" "+de(ke.filename),1)],10,Hj))],64))),128))],2)):te("",!0)]),after:ot(()=>[I(H)?(w(),$("div",{key:0,"data-test":"messaging-message-actions","data-actions-reveal":H.id===M.value?"always":"hover",class:V(["-ml-1 flex items-center gap-1 pt-1 transition-opacity",[$e.value?"text-theme-300":"text-white/35",H.id===M.value?"":"opacity-0 group-hover/msg:opacity-100 focus-within:opacity-100 pointer-coarse:opacity-100"]])},[b("button",{type:"button","data-test":"messaging-message-copy","data-copied":hr.value===H.id||void 0,title:hr.value===H.id?"Copied":"Copy","aria-label":hr.value===H.id?"Copied":"Copy",class:V(["grid size-6 cursor-pointer place-items-center transition-colors",$e.value?"hover:text-theme-800":"hover:text-white"]),onClick:Et(ke=>B(H),["stop"])},[b("i",{class:V(["size-3.5",hr.value===H.id?"i-tabler-check":"i-tabler-copy"]),"aria-hidden":"true"},null,2)],10,Yj),_.value?(w(),$("button",{key:0,type:"button","data-test":"messaging-message-share",title:"Share","aria-label":"Share",class:V(["grid size-6 cursor-pointer place-items-center transition-colors",$e.value?"hover:text-theme-800":"hover:text-white"]),onClick:Et(ke=>D.value=H,["stop"])},[...L[22]||(L[22]=[b("i",{class:"i-tabler-share-2 size-3.5","aria-hidden":"true"},null,-1)])],10,Xj)):te("",!0),X.value?(w(),$("button",{key:1,type:"button","data-test":"messaging-message-report",title:"Report","aria-label":"Report",class:V(["grid size-6 cursor-pointer place-items-center transition-colors",$e.value?"hover:text-theme-800":"hover:text-white"]),onClick:Et(ke=>e.chatController?.reportMessage(H.id),["stop"])},[...L[23]||(L[23]=[b("i",{class:"i-tabler-flag size-3.5","aria-hidden":"true"},null,-1)])],10,Qj)):te("",!0)],10,Jj)):te("",!0)]),_:2},[ce(H).length?{name:"default",fn:ot(()=>[(w(!0),$(ge,null,st(ce(H),ke=>(w(),$(ge,{key:ke.key},[ke.kind==="text"&&ke.text?(w(),$("div",Kj,[be(Wa,{text:ke.text,inverted:!$e.value,streaming:H.id===pe.value,onClick:L[4]||(L[4]=Et(()=>{},["stop"])),onAction:Jr},null,8,["text","inverted","streaming"])])):ke.kind==="attachment"&&ke.attachment.type==="image"?(w(),$("img",{key:1,src:ke.attachment.src,alt:ke.attachment.filename,"data-test":"messaging-attachment","data-attachment-placement":ke.placement,class:"my-2 rounded-xl object-cover max-h-48 max-w-[240px] @sm/chat:max-w-[320px]"},null,8,Wj)):ke.kind==="attachment"&&ke.attachment.type==="audio"?(w(),$("audio",{key:2,src:ke.attachment.src,controls:"","data-test":"messaging-attachment","data-attachment-placement":ke.placement,class:"my-2 max-w-full"},null,8,qj)):ke.kind==="attachment"?(w(),$("a",{key:3,href:ke.attachment.src,target:"_blank",rel:"noopener","data-test":"messaging-attachment","data-attachment-placement":ke.placement,class:V(["my-2 inline-flex items-center gap-1.5 px-3 py-1.5 rounded-lg text-xs",$e.value?"bg-theme-100 text-theme-600 hover:bg-theme-200":"bg-white/10 text-white/80 hover:bg-white/20"])},[L[21]||(L[21]=b("i",{class:"i-tabler-file size-3.5"},null,-1)),xt(" "+de(ke.attachment.filename),1)],10,Gj)):te("",!0)],64))),128))]),key:"0"}:void 0]),1032,["own","inverted","data-test","data-message-id","data-message-sender","data-conversation-id","data-message-sequence","data-system-kind","data-streaming","data-queued","aria-label","class"])),H.id===z.value?(w(),$(ge,{key:6},[f.value.length?(w(!0),$(ge,{key:0},st(f.value,ke=>(w(),$(ge,{key:ke.id},[ke.kind==="work"?(w(),$("div",{key:0,"data-test":"messaging-tool-activity","data-journal-outcome":ke.journal.outcome,class:"chat-live-enter mb-4 w-full"},[be(sy,{model:ke.journal,"is-light":$e.value},null,8,["model","is-light"])],8,eM)):ke.kind==="text"&&ke.content?(w(),$("div",{key:1,"data-test":"messaging-live-text-block",class:V(["mb-4",$e.value?"text-theme-900":"text-white/95"])},[be(Wa,{text:ke.content,inverted:!$e.value,streaming:ke.id===h.value,onClick:L[5]||(L[5]=Et(()=>{},["stop"])),onAction:Jr},null,8,["text","inverted","streaming"])],2)):(w(),$("div",{key:2,"data-test":"messaging-tool-activity-tail","aria-label":"Assistant is still working",class:V(["chat-live-enter mb-4 grid h-[17px] w-5 place-items-center",$e.value?"text-theme-500":"text-white/70"])},[...L[24]||(L[24]=[b("span",{class:"chat-dots chat-dots--mini","aria-hidden":"true"},[b("span"),b("span"),b("span")],-1)])],2))],64))),128)):S.value?(w(),$("div",{key:1,"data-test":"messaging-tool-activity","data-journal-outcome":S.value.outcome,class:"chat-live-enter mb-4 w-full"},[be(sy,{model:S.value,"is-light":$e.value},null,8,["model","is-light"])],8,tM)):te("",!0)],64)):te("",!0)],64))),128)),ue.value?(w(),$("div",{key:1,"data-test":T.value?"messaging-working-state":"messaging-thinking-indicator","data-working-description":T.value,role:"status","aria-live":"polite",class:V(["chat-live-enter relative mb-4 flex h-[17px] items-center gap-2.5 pl-0.5 text-[13.5px] leading-snug",$e.value?"text-theme-500":"text-white/50"])},[L[25]||(L[25]=b("span",{"data-test":"messaging-thinking-dots",class:"chat-dots shrink-0","aria-hidden":"true"},[b("span"),b("span"),b("span")],-1)),T.value?(w(),$("span",nM,de(T.value),1)):(w(),$("span",iM,"Thinking"))],10,rM)):te("",!0),se.value?(w(),$("div",{key:2,"data-test":"messaging-transient-issue","data-issue-code":se.value.code,role:"alert",class:V(["chat-live-enter mb-4 flex items-start gap-2 px-2 text-[13px] leading-snug",$e.value?"text-theme-600":"text-white/60"])},[L[27]||(L[27]=b("i",{class:"i-tabler-alert-circle size-3.5 shrink-0 text-red-500","aria-hidden":"true"},null,-1)),b("span",aM,[b("span",sM,[xt(de(se.value.message),1),se.value.help?(w(),$(ge,{key:0},[xt(":")],64)):te("",!0)]),se.value.help?(w(),$(ge,{key:0},[L[26]||(L[26]=xt(de(" "),-1)),b("span",lM,de(se.value.help),1)],64)):te("",!0)]),se.value.actionUrl&&se.value.actionLabel?(w(),$("a",{key:0,href:se.value.actionUrl,class:"shrink-0 underline underline-offset-2",onClick:L[6]||(L[6]=Et(()=>{},["stop"]))},de(se.value.actionLabel),9,cM)):te("",!0)],10,oM)):te("",!0)],2)]),_:3},8,["inert","aria-hidden","class"]),b("div",{"data-test":"messaging-composer-footer",inert:ye.value,"aria-hidden":ye.value?"true":void 0,class:V(["left-0 right-0 z-30 px-3 @lg/chat:px-8 pb-[max(env(safe-area-inset-bottom),1rem)]",[k.value.length===0||e.centered?"relative shrink-0":"absolute bottom-0",e.centered&&k.value.length>0?"pt-0 sm:pb-9":"pt-3",$e.value?e.centered?"bg-transparent":"bg-theme-0":"bg-gradient-to-t from-black/90 via-black/60 to-transparent"]])},[zt(ee.$slots,"composer",{},()=>[Be.value?(w(),$("div",{key:0,"data-test":"messaging-seat","data-seat-state":Re.value,role:"status","aria-live":"polite",class:V(["py-3 text-center text-[14px]",$e.value?"text-theme-500":"text-white/70"])},de(Be.value),11,dM)):(w(),$(ge,{key:1},[mr.value.length>0?(w(),$("div",{key:0,class:V(["flex items-center gap-2 px-2 pb-2 overflow-x-auto [scrollbar-width:none] [&::-webkit-scrollbar]:hidden",e.centered?"max-w-[640px] @5xl/chat:max-w-[720px] mx-auto":""])},[(w(!0),$(ge,null,st(mr.value,(H,Qe)=>(w(),$("div",{key:Qe,class:"relative shrink-0 group"},[H.type==="image"?(w(),$("img",{key:0,src:H.src,alt:H.filename,class:V(["size-14 rounded-xl object-cover border",$e.value?"border-black/10":"border-white/20"])},null,10,pM)):(w(),$("div",{key:1,class:V(["h-14 px-3 rounded-xl flex items-center gap-1.5 text-xs border",$e.value?"border-black/10 bg-theme-50 text-theme-600":"border-white/20 bg-white/10 text-white/70"])},[L[28]||(L[28]=b("i",{class:"i-tabler-file size-4"},null,-1)),b("span",mM,de(H.filename),1)],2)),b("button",{class:"absolute -top-1.5 -right-1.5 size-5 flex items-center justify-center rounded-full bg-theme-800 text-white text-xs scale-0 group-hover:scale-100 transition-transform duration-200 ease-[cubic-bezier(0.25,1,0.33,1)] cursor-pointer",onClick:ke=>mc(Qe)},[...L[29]||(L[29]=[b("i",{class:"i-tabler-x size-3"},null,-1)])],8,fM)]))),128)),gt.value?(w(),$("div",hM,[be(zp,{class:"size-5"})])):te("",!0)],2)):te("",!0),Tt.value?(w(),$("input",{key:1,ref_key:"fileInput",ref:o,type:"file",accept:"image/*,audio/*,video/*",class:"hidden",onChange:pc},null,544)):te("",!0),be(SU,{ref_key:"composer",ref:r,modelValue:Er.value,"onUpdate:modelValue":L[12]||(L[12]=H=>Er.value=H),placeholder:ft.value,disabled:ct.value,inverted:!$e.value,action:Ht.value,"send-enabled":er.value,"send-label":P.value,"show-send":!St.value&&!Y.value,class:V(e.centered?"mx-auto max-w-[640px] @5xl/chat:max-w-[740px] @5xl/chat:px-5 @5xl/chat:pt-3.5 @5xl/chat:pb-3":""),onSubmit:L[13]||(L[13]=H=>xo()),onAction:L[14]||(L[14]=H=>ni())},Pa({leading:ot(()=>[b("button",{class:V(["-ml-2 flex size-8 items-center justify-center transition-opacity hover:opacity-70 pointer-coarse:size-11",[Tt.value?"cursor-pointer":"cursor-default",$e.value?"text-theme-500":"text-white/50",gt.value||Wr.value?"opacity-50 pointer-events-none":""]]),disabled:ct.value||gt.value||Wr.value||!Tt.value,"aria-label":Tt.value?"Attach file":"File attachments unavailable",title:Tt.value?"Attach file":"File attachments unavailable",onClick:L[7]||(L[7]=H=>Tt.value&&On())},[gt.value?(w(),$("i",bM)):(w(),$("i",yM)),b("span",wM,de(Tt.value?"Attach file":"File attachments unavailable"),1)],10,vM)]),actions:ot(()=>[Y.value&&!ie.value&&!ye.value?(w(),$("button",{key:0,"data-test":"messaging-record-discard-btn",class:V(["flex size-8 cursor-pointer items-center justify-center transition-opacity hover:opacity-70 pointer-coarse:size-11",$e.value?"text-theme-400":"text-white/40"]),"aria-label":"Discard recording",title:"Discard recording",onClick:L[8]||(L[8]=H=>ii({cancelled:!0}))},[...L[31]||(L[31]=[b("i",{class:"i-tabler-x size-[18px]","aria-hidden":"true"},null,-1)])],2)):te("",!0),(E.value||Y.value)&&!ie.value&&!ye.value?(w(),$("button",{key:1,"data-test":"messaging-record-audio-btn",class:V(["flex size-8 cursor-pointer items-center justify-center transition-[opacity,transform] duration-200 ease-[cubic-bezier(0.25,1,0.33,1)] hover:opacity-70 pointer-coarse:size-11",Y.value?$e.value?"text-theme-900 scale-110":"text-white scale-110":$e.value?"text-theme-500":"text-white/60"]),"aria-label":we.value,title:we.value,onPointerdown:Et(_o,["prevent"]),onPointerup:Et(Ur,["prevent"]),onPointercancel:Et(oi,["prevent"]),onClick:os,onKeydown:L[9]||(L[9]=Gn(Et(H=>ii({cancelled:!0}),["prevent"]),["escape"]))},[b("i",{class:V([Y.value?"i-tabler-microphone-filled":"i-tabler-microphone","size-[18px]"])},null,2),b("span",xM,de(we.value),1)],42,kM)):te("",!0),St.value?(w(),$("button",{key:2,"data-test":"messaging-voice-start-btn",class:V(["flex size-8 items-center justify-center rounded-full transition-colors duration-150 pointer-coarse:size-11",[$e.value?"bg-theme-900 text-theme-0 hover:bg-theme-800":"bg-theme-0 text-theme-950 hover:bg-theme-100",Kt.value?"cursor-not-allowed opacity-40":"cursor-pointer"]]),disabled:Kt.value,"aria-label":vt.value,title:vt.value,onClick:L[10]||(L[10]=H=>Nt())},[b("span",$M,[(w(),$(ge,null,st([7,13,16,11,14],H=>b("span",{key:H,class:"w-[2px] rounded-full bg-current",style:Se({height:`${H}px`})},null,4)),64))]),L[32]||(L[32]=b("span",{class:"sr-only"},"Start voice conversation",-1))],10,_M)):te("",!0),Tr.value&&!St.value&&!Y.value?(w(),$("button",{key:3,"data-test":"messaging-secondary-stop-btn",class:V(["mr-2 flex size-8 cursor-pointer items-center justify-center rounded-full transition-colors duration-150 pointer-coarse:size-11",$e.value?"bg-theme-100 text-theme-700 hover:bg-theme-200":"bg-white/10 text-white/70 hover:bg-white/15"]),"aria-label":"Stop work",title:"Stop work",onClick:L[11]||(L[11]=H=>e.chatController?.stopChatTurn())},[...L[33]||(L[33]=[b("i",{class:"i-tabler-player-stop-filled size-3.5","aria-hidden":"true"},null,-1),b("span",{class:"sr-only"},"Stop work",-1)])],2)):te("",!0)]),_:2},[Y.value?{name:"input",fn:ot(()=>[b("div",{"data-test":"messaging-recording-state",class:V(["flex min-w-0 items-center gap-2 py-1",$e.value?"text-theme-700":"text-white/80"])},[L[30]||(L[30]=b("span",{class:"size-2.5 shrink-0 rounded-full bg-red-500"},null,-1)),b("span",gM,de(fe.value),1),b("span",{class:V(["min-w-0 truncate text-sm",$e.value?"text-theme-400":"text-white/45"])},de(ve.value),3)],2)]),key:"0"}:void 0]),1032,["modelValue","placeholder","disabled","inverted","action","send-enabled","send-label","show-send","class"]),e.centered&&k.value.length>0?(w(),$("p",SM,de(e.bot.displayName.value)+" is AI and can make mistakes. ",1)):te("",!0)],64))],!0)],10,uM),_.value?(w(),Fe(YU,{key:4,message:D.value,prompt:y.value,share:_.value,onClose:L[15]||(L[15]=H=>D.value=void 0)},null,8,["message","prompt","share"])):te("",!0)],2))}}),[["__scopeId","data-v-4b8f5776"]]),IM={class:"bot-wrap"},EM={key:0,class:"flex items-center justify-center h-full"},TM={key:2,class:"flex h-full flex-col items-center justify-center gap-4 px-6 text-center",role:"status","aria-live":"polite","data-test":"bot-unavailable"},Vp=Pe({__name:"BotWrap",props:{sdk:{},bot:{},handle:{},context:{},clientContext:{},firstMessage:{},buttonText:{},buttonIcon:{},hasClose:{type:Boolean},chatOnly:{type:Boolean},bare:{type:Boolean},apiBase:{}},setup(e){let t=co("BotWrap"),n=e,i=n.sdk||Yl.getInstance({isDev:typeof window<"u"?window.location.hostname==="localhost"||window.location.hostname.includes("127.0.0.1"):!1,...n.apiBase&&{apiBase:n.apiBase}}),r=We(!n.bot),o=We(n.bot),a=We();async function s(){if(n.bot)t.debug("Bot provided via props, skipping fetch",{botId:n.bot.botId.value,handle:n.bot.handle.value}),r.value=!1;else if(!n.handle)a.value="No handle or bot provided",t.warn("BotWrap mounted without handle or bot",{propsReceived:{handle:n.handle,bot:n.bot,context:n.clientContext??n.context,apiBase:n.apiBase},sdkState:{isDev:i.isDev,apiBase:i.apiBase}}),r.value=!1;else try{r.value=!0,a.value=void 0,t.debug("Fetching public bot",{handle:n.handle});let l=await i.user.getPublicBot({handle:n.handle});l?(o.value=l,t.debug("Successfully fetched public bot",{botId:l.botId.value,handle:l.handle.value}),l.botId.value&&i.user.track({event:"view_profile",botId:l.botId.value,properties:{viewSource:"widget"}})):(a.value=i.error.value||"Bot not found",t.error("Failed to fetch public bot - no data returned",{handle:n.handle,sdkError:i.error.value,sdkState:{isDev:i.isDev,apiBase:i.apiBase,loading:i.loading.value}}))}catch(l){a.value=l instanceof Error?l.message:"Failed to fetch bot",t.error("Exception while fetching public bot",{handle:n.handle,error:l instanceof Error?{message:l.message,stack:l.stack}:l,sdkState:{isDev:i.isDev,apiBase:i.apiBase,error:i.error.value}})}finally{r.value=!1,o.value||t.debug("BotWrap component will render unavailable state",{state:{loading:r.value,hasBot:!!o.value,error:a.value},props:{handle:n.handle,context:n.clientContext??n.context,apiBase:n.apiBase},sdkState:{isDev:i.isDev,apiBase:i.apiBase,error:i.error.value}})}}return Ut(s),(l,u)=>(w(),$("div",IM,[r.value?(w(),$("div",EM,[b("div",{class:V(["size-6 animate-spin rounded-full border-b-2",n.bare?"border-theme-400":"border-white"])},null,2)])):o.value?zt(l.$slots,"default",{sdk:Ae(i),bot:o.value,context:e.clientContext??e.context,firstMessage:e.firstMessage,buttonText:e.buttonText,buttonIcon:e.buttonIcon,loading:r.value},void 0,void 0,1):a.value?(w(),$("div",TM,[u[0]||(u[0]=b("p",{class:"text-sm font-medium text-theme-600"}," This assistant is unavailable right now. ",-1)),b("button",{type:"button",class:"min-h-11 rounded-full bg-theme-900 px-5 text-sm font-semibold text-theme-0 transition-colors hover:bg-theme-700","data-test":"bot-unavailable-retry",onClick:s}," Try again ")])):te("",!0)]))}})});function es(e){let t=We(e.bot),n=Q(e.context),i=Q(e.firstMessage),r=Q(e.buttonText),o=Q(e.buttonIcon);function a(s){s.bot!==void 0&&(t.value=s.bot),s.context!==void 0&&(n.value=s.context),s.firstMessage!==void 0&&(i.value=s.firstMessage),s.buttonText!==void 0&&(r.value=s.buttonText),s.buttonIcon!==void 0&&(o.value=s.buttonIcon)}return{currentBot:t,currentContext:n,currentFirstMessage:i,currentButtonText:r,currentButtonIcon:o,update:a}}var Bp=re(()=>{"use strict";Pn();En()});var wo,DE=re(()=>{"use strict";Pn();wo={linkedin:{label:"LinkedIn",icon:"i-simple-icons-linkedin",placeholder:"john-smith",getUrl:e=>`https://linkedin.com/in/${e}`},x:{label:"X",icon:"i-simple-icons-x",placeholder:"johnsmith",getUrl:e=>`https://x.com/${e}`},facebook:{label:"Facebook",icon:"i-simple-icons-facebook",placeholder:"johnsmith",getUrl:e=>`https://facebook.com/${e}`},tiktok:{label:"TikTok",icon:"i-simple-icons-tiktok",placeholder:"johnsmith",getUrl:e=>`https://tiktok.com/@${e}`},youtube:{label:"YouTube",icon:"i-tabler-brand-youtube",placeholder:"johnsmith",getUrl:e=>`https://youtube.com/@${e}`},github:{label:"GitHub",icon:"i-tabler-brand-github",placeholder:"johnsmith",getUrl:e=>`https://github.com/${e}`},instagram:{label:"Instagram",icon:"i-simple-icons-instagram",placeholder:"johnsmith",getUrl:e=>`https://instagram.com/${e}`},threads:{label:"Threads",icon:"i-simple-icons-threads",placeholder:"johnsmith",getUrl:e=>`https://threads.net/@${e}`},email:{label:"Email",icon:"i-tabler-mail",placeholder:"hello@example.com",getUrl:e=>`mailto:${e}`},phone:{label:"Phone",icon:"i-tabler-phone",placeholder:"+1-555-123-4567",getUrl:e=>`tel:${e.replace(/[^0-9+]/g,"")}`},website:{label:"Website",icon:"i-tabler-world",placeholder:"https://example.com",getUrl:e=>e},calendar:{label:"Calendar",icon:"i-tabler-calendar",placeholder:"https://cal.com/username",getUrl:e=>e}}});var RE,NM,CM,zM,AM,OM,DM,PM,RM,PE,UM,jM,MM,LM,VM,FM,BM,ZM,HM,KM,WM,qM,GM,JM,YM,XM,QM,eL,tL,rL,nL,iL,oL,aL,sL,lL,cL,uL,dL,pL,UE,mL,fL,hL,gL,vL,bL,yL,wL,kL,xL,_L,$L,SL,IL,EL,TL,NL,CL,zL,AL,OL,DL,PL,Zp,My=re(()=>{"use strict";Pn();DE();Fp();ql();En();RE=[{mode:"self",label:"Overview",icon:"i-tabler-user-square-rounded"},{mode:"talk",label:"Talk",icon:"i-tabler-phone"},{mode:"chat",label:"Chat",icon:"i-tabler-message-circle"},{mode:"info",label:"About",icon:"i-tabler-user-circle"}],NM=Pe({__name:"EffectTransitionList",props:{disabled:{type:Boolean,default:!1},mode:{default:"block"}},setup(e){return(t,n)=>(w(),Fe(H0,{name:e.disabled?"":"nlist"},{default:ot(()=>[zt(t.$slots,"default")]),_:3},8,["name"]))}}),CM=["data-test-mode"],zM={class:"w-full max-w-xs space-y-12"},AM={key:0,class:"text-xs text-theme-400 text-center"},OM={class:"text-base font-light text-white text-center"},DM={class:"space-y-6 relative"},PM={key:"email-field",class:"w-full"},RM={key:"code-field",class:"w-full"},PE=Pe({__name:"ElAuthGate",props:{sdk:{}},setup(e){let t=Q({email:"",code:""}),n=Q("email"),i=Q(!1),r={email:{title:"Enter Your Email",button:{label:"Continue",disabled:()=>!t.value.email||i.value},action:async()=>{if(!i.value){i.value=!0;try{await e.sdk.auth.requestAuthCode({email:t.value.email})&&(n.value="code")}finally{i.value=!1}}}},code:{title:"Enter Verification Code",button:{label:"Verify",disabled:()=>t.value.code.length!==6||i.value},action:async()=>{if(!i.value){i.value=!0;try{await e.sdk.auth.loginWithCode({email:t.value.email,code:t.value.code})}finally{i.value=!1}}}}},o=R(()=>r[n.value]);return mt(()=>e.sdk.activeUser.value,a=>{a&&n.value==="code"&&console.log("[ElAuthGate] Authentication successful",{email:a.email})}),(a,s)=>(w(),$("div",{"data-test":"auth-form","data-test-mode":n.value,class:"flex flex-col items-center justify-center h-full p-6"},[b("div",zM,[e.sdk.error.value?(w(),$("p",AM,de(e.sdk.error.value),1)):te("",!0),b("h3",OM,de(o.value.title),1),b("div",DM,[be(NM,null,{default:ot(()=>[n.value==="email"?(w(),$("div",PM,[be(jp,{modelValue:t.value.email,"onUpdate:modelValue":s[0]||(s[0]=l=>t.value.email=l),"data-test":"auth-email-input",onKeyup:Gn(o.value.action,["enter"])},null,8,["modelValue","onKeyup"])])):(w(),$("div",RM,[be(Mp,{modelValue:t.value.code,"onUpdate:modelValue":s[1]||(s[1]=l=>t.value.code=l),length:6,"focus-first":!0,"data-test":"auth-code-input",onAutoSubmit:o.value.action},null,8,["modelValue","onAutoSubmit"])])),(w(),$("div",{key:o.value.button.label,class:"space-y-4 w-full"},[be(Xa,{theme:"primary",size:"md",class:"w-full","data-test":"auth-submit",loading:e.sdk.loading.value,disabled:o.value.button.disabled()||e.sdk.loading.value,onClick:o.value.action},{default:ot(()=>[xt(de(o.value.button.label),1)]),_:1},8,["loading","disabled","onClick"]),n.value==="code"?(w(),$("button",{key:0,class:"w-full text-xs text-white/50 hover:text-white/70 transition-colors py-2",onClick:s[2]||(s[2]=l=>n.value="email")}," Change Email ")):te("",!0)]))]),_:1})])])],8,CM))}}),UM={class:"flex-1 flex flex-col min-h-0 py-6 space-y-6 h-full overflow-scroll [scrollbar-width:none] [-ms-overflow-style:none] [&::-webkit-scrollbar]:hidden relative"},jM={class:"flex-1 space-y-6 pb-12"},MM={key:0,class:"text-sm bg-white/10 backdrop-blur-sm rounded-2xl p-4 border border-white/20 space-y-3"},LM={class:"text-white/70 leading-relaxed whitespace-pre-wrap"},VM={key:1,class:"space-y-3"},FM=["href"],BM={key:2,class:"space-y-3"},ZM={class:"grid grid-cols-2 gap-3"},HM=["href"],KM=Pe({__name:"ElBotAbout",props:{bot:{},isOnline:{type:Boolean,default:!1}},setup(e){return(t,n)=>(w(),$("div",UM,[be(Lp,{bot:e.bot,"is-online":e.isOnline},null,8,["bot","is-online"]),b("div",jM,[e.bot.summary.value?(w(),$("div",MM,[n[0]||(n[0]=b("h3",{class:"font-medium text-white/50"}," About ",-1)),b("p",LM,de(e.bot.summary.value),1)])):te("",!0),e.bot.email.value?(w(),$("div",VM,[n[2]||(n[2]=b("h3",{class:"text-sm font-medium text-white/90"}," Contact ",-1)),b("a",{href:`mailto:${e.bot.email.value}`,target:"_blank",rel:"noopener noreferrer",class:"relative inline-flex items-center justify-center gap-2 rounded-full px-4 py-2 font-medium transition-colors duration-200 focus:outline-none active:opacity-80 cursor-pointer bg-white/5 hover:bg-white/10 border border-white/10 text-white/80 text-sm justify-start h-10 w-full"},[...n[1]||(n[1]=[b("span",{class:"i-heroicons-envelope flex items-center size-[1.1em] mt-[-.07em]"},null,-1),xt(" Email ",-1)])],8,FM)])):te("",!0),e.bot.accounts.value&&e.bot.accounts.value.length>0?(w(),$("div",BM,[n[3]||(n[3]=b("h3",{class:"text-sm font-medium text-white/90"}," Links ",-1)),b("div",ZM,[(w(!0),$(ge,null,st(e.bot.accounts.value,i=>(w(),$("a",{key:`${i.platform}-${i.handle}`,href:Ae(wo)[i.platform].getUrl(i.handle),target:"_blank",rel:"noopener noreferrer",class:"relative inline-flex items-center justify-center gap-2 rounded-full px-4 py-2 font-medium transition-colors duration-200 focus:outline-none active:opacity-80 cursor-pointer bg-white/10 hover:bg-white/20 border border-white/20 text-white/80 text-sm"},[b("span",{class:V(["flex items-center size-[1.1em] mt-[-.07em]",Ae(wo)[i.platform].icon])},null,2),xt(" "+de(Ae(wo)[i.platform].label),1)],8,HM))),128))])])):te("",!0)])]))}}),WM={class:"flex flex-col items-center text-center gap-4"},qM={class:"relative flex-shrink-0"},GM={class:"w-20 h-20 sm:w-24 sm:h-24 rounded-full overflow-hidden border-4 border-white"},JM=["src","alt"],YM={class:"absolute top-1.5 right-1.5"},XM={key:1,class:"size-4 bg-theme-400 rounded-full ring-2 ring-white"},QM={class:"min-w-0"},eL={class:"text-3xl font-light text-white mb-2 truncate"},tL={class:"text-base font-light text-white/60 line-clamp-1"},rL=Pe({__name:"ElBotHeader",props:{bot:{},isOnline:{type:Boolean,default:!1}},setup(e){return(t,n)=>(w(),$("div",WM,[b("div",qM,[b("div",GM,[b("img",{src:e.bot.avatarUrl.value,alt:e.bot.displayName.value,class:"w-full h-full object-cover",onError:n[0]||(n[0]=(...i)=>Ae(ac)&&Ae(ac)(...i))},null,40,JM)]),b("div",YM,[e.isOnline?(w(),$(ge,{key:0},[n[1]||(n[1]=b("div",{class:"size-4 bg-green-500 rounded-full ring-2 ring-white absolute animate-ping",style:{"animation-duration":"3s"}},null,-1)),n[2]||(n[2]=b("div",{class:"size-4 bg-green-500 rounded-full ring-2 ring-white"},null,-1))],64)):(w(),$("div",XM))])]),b("div",QM,[b("h1",eL,de(e.bot.displayName.value),1),b("p",tL,de(e.bot.title.value),1)])]))}}),nL={class:"absolute top-1/2 left-1/2 -translate-x-1/2 -translate-y-1/2 w-[28px] h-[28px] overflow-hidden"},iL=Pe({name:"SelfSidebarClose",__name:"BotSidebarClose",emits:["click"],setup(e){let t=Q(!1);return Ut(()=>{setTimeout(()=>{t.value=!0},100)}),(n,i)=>(w(),$("a",{class:"close block cursor-pointer w-[60px] h-[60px] rounded-full transition-all duration-1000 ease-[cubic-bezier(0.25,1,0.33,1)] hover:scale-110 active:scale-90 hover:rotate-90",onClick:i[0]||(i[0]=r=>n.$emit("click",r))},[i[1]||(i[1]=b("span",{class:"absolute inset-0 rounded-full transition-all"},null,-1)),b("span",nL,[b("span",{class:V(["absolute h-full w-[3px] rounded-[5px] left-[13px] transition-all duration-[400ms] ease-[cubic-bezier(0.52,0.01,0.16,1)]",t.value?"translate-y-0 translate-x-0 rotate-45":"translate-y-[30px] -translate-x-[30px] rotate-0"]),style:{"background-color":"currentColor","transition-delay":"0.15s"}},null,2),b("span",{class:V(["absolute h-full w-[3px] rounded-[5px] left-[13px] transition-all duration-[400ms] ease-[cubic-bezier(0.52,0.01,0.16,1)]",t.value?"translate-y-0 translate-x-0 -rotate-45":"-translate-y-[30px] -translate-x-[30px] rotate-0"]),style:{"background-color":"currentColor","transition-delay":"0.45s"}},null,2)])]))}}),oL={key:0,class:"px-9 pt-12 pb-4"},aL={class:"text-base font-medium text-theme-400"},sL={key:1,class:"px-4 pb-8 border-b border-white/10"},lL=["disabled","onClick"],cL={class:"flex items-center gap-3"},uL={class:"flex-1"},dL={key:0,class:"text-xs text-white/50 mt-0.5"},pL={class:"p-6"},UE=Pe({name:"ElSidebar",inheritAttrs:!1,__name:"ElSidebar",props:{modelValue:{type:Boolean},items:{},position:{},title:{},widthClasses:{}},emits:["update:modelValue"],setup(e,{emit:t}){let n=e,i=t,r=n.position||"left",o=n.widthClasses||"w-[80%] max-w-[300px]",a=R({get:()=>n.modelValue,set:d=>i("update:modelValue",d)}),s=R(()=>n.items.filter(d=>!d.isHidden));function l(d){d.isDisabled||(d.onClick?d.onClick({item:d,event:new MouseEvent("click")}):d.href&&(d.href.includes("http")?window.open(d.href,d.target||"_self")?.focus():window.location.href=d.href),a.value=!1)}let u=R(()=>r==="left"?{enter:"-translate-x-full",leave:"-translate-x-full",position:"justify-start",closeButton:"-right-16"}:{enter:"translate-x-full",leave:"translate-x-full",position:"justify-end",closeButton:"-left-16"});return(d,p)=>(w(),$(ge,null,[be(so,{"enter-active-class":"transition-opacity duration-300 ease-out","leave-active-class":"transition-opacity duration-200 ease-in","enter-from-class":"opacity-0","enter-to-class":"opacity-100","leave-from-class":"opacity-100","leave-to-class":"opacity-0"},{default:ot(()=>[a.value?(w(),$("div",{key:0,class:"absolute inset-0 z-40 bg-black/50 backdrop-blur-sm",onClick:p[0]||(p[0]=m=>a.value=!1)})):te("",!0)]),_:1}),be(so,{"enter-active-class":"transition-all duration-500 ease-[cubic-bezier(0.25,1,0.33,1)]","leave-active-class":"transition-all duration-400 ease-[cubic-bezier(0.25,1,0.33,1)]","enter-from-class":u.value.enter,"enter-to-class":"translate-x-0","leave-from-class":"translate-x-0","leave-to-class":u.value.leave},{default:ot(()=>[a.value?(w(),$("div",{key:0,class:V(["absolute inset-0 z-50 flex",u.value.position]),onClick:p[3]||(p[3]=m=>a.value=!1)},[b("div",{class:V(["relative h-full shadow-2xl bg-black/30 backdrop-blur-xl flex flex-col justify-center",Ae(o)]),onClick:p[2]||(p[2]=Et(()=>{},["stop"]))},[be(iL,{class:V(["absolute top-4 z-10 text-white",u.value.closeButton]),onClick:p[1]||(p[1]=m=>a.value=!1)},null,8,["class"]),e.title?(w(),$("div",oL,[b("h3",aL,de(e.title),1)])):te("",!0),d.$slots.header?(w(),$("div",sL,[zt(d.$slots,"header")])):te("",!0),b("div",{class:V(["flex-1 p-6 space-y-2 overflow-y-auto",{"pt-6":!e.title&&!d.$slots.header,"pt-4":e.title||d.$slots.header}])},[be(H0,{"enter-active-class":"transition-all duration-400 ease-[cubic-bezier(0.25,1,0.33,1)]","leave-active-class":"transition-all duration-200 ease-[cubic-bezier(0.25,1,0.33,1)]","enter-from-class":Ae(r)==="left"?"-translate-x-4 opacity-0":"translate-x-4 opacity-0","enter-to-class":"translate-x-0 opacity-100","leave-from-class":"translate-x-0 opacity-100","leave-to-class":Ae(r)==="left"?"-translate-x-4 opacity-0":"translate-x-4 opacity-0"},{default:ot(()=>[(w(!0),$(ge,null,st(s.value,(m,f)=>(w(),$("button",{key:m.key||m.label||f,style:Se({transitionDelay:`${f*40}ms`}),class:V(["cursor-pointer w-full text-left p-3 rounded-xl transition-all duration-200 ease-[cubic-bezier(0.25,1,0.33,1)] group",[m.isActive?"bg-primary-500/20 border border-primary-500/40":"hover:bg-white/10",m.isDisabled&&"opacity-50 cursor-not-allowed"]]),disabled:m.isDisabled,onClick:h=>l(m)},[b("div",cL,[m.icon?.src?(w(),$("i",{key:0,class:V(["size-5 flex-shrink-0 transition-transform duration-200 ease-[cubic-bezier(0.25,1,0.33,1)] group-hover:scale-110",[m.icon.src,m.isActive?"text-primary-400":"text-white/70 group-hover:text-white"]])},null,2)):te("",!0),b("div",uL,[b("div",{class:V(["font-medium text-sm",m.isActive?"text-primary-300":"text-white"])},de(m.label),3),m.subLabel?(w(),$("div",dL,de(m.subLabel),1)):te("",!0)])])],14,lL))),128))]),_:1},8,["enter-from-class","leave-to-class"])],2),b("div",pL,[zt(d.$slots,"footer")])],2)],2)):te("",!0)]),_:3},8,["enter-from-class","leave-to-class"])],64))}}),mL=Pe({name:"BotModeSidebar",__name:"ElBotModeSidebar",props:{modelValue:{type:Boolean},chatController:{}},emits:["update:modelValue"],setup(e,{emit:t}){let n=e,i=t,r=R({get:()=>n.modelValue,set:s=>i("update:modelValue",s)}),o=R(()=>n.chatController?.botMode?.value??"self"),a=R(()=>RE.map(s=>({key:s.mode,icon:{src:s.icon},label:s.label,isActive:o.value===s.mode,onClick:()=>{n.chatController?.setMode(s.mode)}})));return(s,l)=>(w(),Fe(UE,{modelValue:r.value,"onUpdate:modelValue":l[0]||(l[0]=u=>r.value=u),items:a.value,position:"right",title:"Mode","width-classes":"w-[80%] max-w-[255px]"},null,8,["modelValue","items"]))}}),fL=Pe({name:"BotSidebar",__name:"ElBotSidebar",props:{modelValue:{type:Boolean},bot:{},sdk:{},title:{}},emits:["update:modelValue"],setup(e,{emit:t}){let n=e,i=t,r=R({get:()=>n.modelValue,set:a=>i("update:modelValue",a)}),o=R(()=>{let a=[{key:"share",icon:{src:"i-tabler-share"},label:"Share this assistant",onClick:()=>{let s=`${window.location.origin}/@${n.bot.handle.value||n.bot.botId.value}`;navigator.clipboard.writeText(s).catch(l=>{console.error("ElBotSidebar: clipboard.writeText rejected",l)})}},{key:"profile",icon:{src:"i-tabler-user"},label:"View full profile",onClick:()=>{window.open(`/@${n.bot.handle.value||n.bot.botId.value}`,"_blank")}},{key:"create",icon:{src:"i-tabler-sparkles"},label:"Create your own",onClick:()=>{window.open("/auth","_blank")}}];return n.sdk.activeUser.value&&a.push({key:"logout",icon:{src:"i-tabler-logout"},label:"Logout",onClick:async()=>{await n.sdk.auth.logout()}}),a});return(a,s)=>(w(),Fe(UE,{modelValue:r.value,"onUpdate:modelValue":s[0]||(s[0]=l=>r.value=l),items:o.value,position:"left",title:e.title||"Menu"},null,8,["modelValue","items","title"]))}}),hL={key:0,class:"absolute inset-0 flex items-center justify-center bg-gradient-to-br from-theme-800 to-theme-950 rounded-3xl z-10"},gL=["data-quality"],vL={key:0,class:"flex flex-1 items-center gap-3 pl-2"},bL=["src","alt"],yL={class:"text-sm font-medium text-white/90"},wL={key:1,class:"flex justify-end"},kL={class:"text-sm"},xL={key:0,class:"flex-1 basis-0 flex justify-end"},_L={key:0,class:"h-full pb-12 flex-1 flex flex-col relative z-20 min-h-0 px-4 @[480px]/bot:px-6 max-w-md mx-auto w-full"},$L={class:"flex-1 basis-0 flex flex-col justify-start pt-8 gap-7"},SL={key:0,class:"flex items-center justify-center gap-3"},IL=["href"],EL={key:1,class:"flex-1 flex flex-col relative z-20 min-h-0 w-full gap-4 px-4"},TL={class:"max-w-md mx-auto"},NL={key:2,class:"flex-1 flex flex-col relative z-20 min-h-0 w-full px-4 @[480px]/bot:px-6"},CL={class:"flex-1 min-h-0 max-w-md mx-auto w-full"},zL={key:2,class:"bg-gradient-to-br from-theme-800 to-theme-950 text-white flex items-center justify-center h-full p-8"},AL={class:"text-center max-w-md space-y-4"},OL={class:"text-sm text-white/70 leading-relaxed"},DL={key:3,class:"bg-white/10 backdrop-blur-sm text-white/70 flex items-center justify-center h-full"},PL=Pe({__name:"BotChat",props:{sdk:{},bot:{},context:{},firstMessage:{},buttonText:{},buttonIcon:{},hasClose:{type:Boolean,default:!1},isActive:{type:Boolean,default:!0},loading:{type:Boolean,default:!1},theme:{default:"green"},requireAuth:{type:Boolean,default:!1},chatOnly:{type:Boolean,default:!1},bare:{type:Boolean,default:!1},emptyStateMessage:{},createVoiceClientFn:{type:Function}},emits:["close","error","turnStarted","turnCompleted"],setup(e,{emit:t}){let n=t,i=We(),r=Q(!1),o=Q(!1),a=Q(),s=Q(),l=R(()=>i.value?.botMode?.value??"self"),u=R(()=>i.value?.textState.value.isConnected??!1),d=R(()=>e.sdk.activeUser.value!==void 0),p=R(()=>RE.find(z=>z.mode===l.value));function m(){i.value&&i.value.destroy();try{i.value=new sc({sdk:e.sdk,bot:e.bot,context:e.context,firstMessage:e.firstMessage,...e.createVoiceClientFn?{createVoiceClientFn:e.createVoiceClientFn}:{},onTurnStarted:()=>n("turnStarted"),onTurnCompleted:z=>n("turnCompleted",z)})}catch(z){throw console.error("BotChatController creation failed:",z),z}}try{m()}catch(z){let j=z instanceof Error?z.message:"Couldn't initialize your assistant";a.value=j,n("error",j)}function f(z){if(!s.value)return;let j=F2(z);Object.entries(j).forEach(([O,U])=>{s.value.style.setProperty(`--primary-${O}`,U)})}Ut(()=>{try{f(e.theme),e.chatOnly&&i.value&&i.value.setMode("chat")}catch(z){let j=z instanceof Error?z.message:"Couldn't initialize your assistant";a.value=j,n("error",j)}}),Wn(()=>{i.value&&i.value.destroy()}),mt(()=>e.theme,z=>{f(z)}),mt(()=>e.sdk.activeUser.value,(z,j)=>{j&&!z&&i.value&&i.value.setMode("self")});let h=R(()=>!!(e.bot.cover.value?.src&&e.bot.cover.value?.quality==="low")||!!(e.bot.avatar.value?.src&&e.bot.avatar.value?.quality==="low")),v=R(()=>{let z=[h.value?"backdrop-blur-sm":""];return h.value&&l.value==="self"?z.push("from-black/80 via-black/60 to-black/80"):l.value==="self"?z.push("from-black/70 via-black/50 to-black/80"):z.push("from-black/90 via-black/90 to-black/100"),z.join(" ")}),k={phone:"i-heroicons-phone",calendar:"i-heroicons-calendar",question:"i-heroicons-question-mark-circle",message:"i-heroicons-chat-bubble-left-right",sparkles:"i-heroicons-sparkles"},T=R(()=>pE({template:e.buttonText||"Talk to {name}",bot:e.bot.toData()})),S=R(()=>k[e.buttonIcon||"phone"]||k.phone);return(z,j)=>(w(),$("div",{ref_key:"rootElement",ref:s,key:e.bot.avatarUrl.value,class:"pagelines-sdk @container/bot pagelines-bot w-full h-full overflow-hidden relative","data-test":"bot-chat"},[e.loading?(w(),$("div",hL,[be(zp,{class:"text-white size-8"})])):e.bot&&!a.value?(w(),$("div",{key:1,class:V(["absolute inset-0",e.bare?"":"bg-cover bg-center bg-no-repeat"]),style:Se(e.bare?void 0:{backgroundImage:`url(${e.bot.avatarUrl.value})`}),"data-quality":e.bot.avatar.value?.quality||"none"},[e.bare?te("",!0):(w(),$("div",{key:0,class:V(["absolute inset-0 bg-gradient-to-br z-0",v.value])},null,2)),b("div",{class:V(["relative z-10 flex flex-col h-full transition-all duration-500 ease-[cubic-bezier(0.25,1,0.33,1)] will-change-transform",e.isActive?"opacity-100 translate-y-0":"opacity-0 translate-y-2"])},[!e.bare||e.hasClose?(w(),$("div",{key:0,class:V(["relative z-30 p-2",!e.bare&&l.value!=="self"?"backdrop-blur-lg":""])},[e.chatOnly?(w(),$("div",{key:0,class:V(["flex items-center",e.bare?"justify-end":""])},[e.bare?te("",!0):(w(),$("div",vL,[b("img",{src:e.bot.avatarUrl.value,alt:e.bot.displayName.value,class:"size-8 rounded-full object-cover"},null,8,bL),b("span",yL,de(e.bot.displayName.value),1)])),e.hasClose?(w(),$("div",wL,[b("button",{class:V(["flex cursor-pointer items-center rounded-2xl p-3 transition-colors",e.bare?"text-theme-500 hover:bg-theme-50":"text-white/70 hover:bg-white/10"]),onClick:j[0]||(j[0]=Et(O=>n("close","button"),["stop"]))},[...j[7]||(j[7]=[b("i",{class:"size-6 i-tabler-x"},null,-1)])],2)])):te("",!0)],2)):(w(),$("div",{key:1,class:V(["flex items-center",e.hasClose?"":"justify-between"])},[b("div",{class:V(e.hasClose?"flex-1 basis-0":"")},[b("button",{class:"cursor-pointer p-2 flex items-center gap-2 rounded-2xl text-white/70 hover:bg-white/10 transition-all duration-300 ease-[cubic-bezier(0.25,1,0.33,1)] hover:scale-105 active:scale-95",onClick:j[1]||(j[1]=O=>r.value=!0)},[...j[8]||(j[8]=[b("i",{class:"i-tabler-menu size-7"},null,-1)])])],2),b("button",{class:V(["flex items-center gap-2 px-3.5 py-3 rounded-2xl text-white/90 hover:bg-white/10 transition-all cursor-pointer flex-grow-0",{"bg-white/10":o.value}]),onClick:j[2]||(j[2]=O=>o.value=!0)},[b("i",{class:V([p.value?.icon,"size-4 opacity-60"])},null,2),b("span",kL,de(p.value?.label),1),j[9]||(j[9]=b("i",{class:"i-tabler-chevron-down size-4"},null,-1))],2),e.hasClose?(w(),$("div",xL,[b("button",{class:"cursor-pointer flex items-center p-3 rounded-2xl text-white/70 hover:bg-white/10 transition-colors",onClick:j[3]||(j[3]=Et(O=>n("close","button"),["stop"]))},[...j[10]||(j[10]=[b("i",{class:"size-6 i-tabler-x"},null,-1)])])])):te("",!0)],2))],2)):te("",!0),e.chatOnly?(w(),$("div",{key:1,class:V(["relative z-20 flex min-h-0 w-full flex-1 flex-col",e.bare?"":"px-4"])},[b("div",{class:V(["min-h-0 w-full flex-1",e.bare?"":"mx-auto max-w-md"])},[be(yo,{"chat-controller":i.value,bot:e.bot,scope:d.value?"private":"public","empty-state-message":e.emptyStateMessage,variant:e.bare?"light":"dark","show-header":!e.bare,centered:e.bare},Pa({_:2},[z.$slots["empty-heading"]?{name:"empty-heading",fn:ot(O=>[zt(z.$slots,"empty-heading",xa(Ra(O)))]),key:"0"}:void 0]),1032,["chat-controller","bot","scope","empty-state-message","variant","show-header","centered"])],2)],2)):(w(),$(ge,{key:2},[l.value==="self"?(w(),$("div",_L,[j[11]||(j[11]=b("div",{class:"flex-1 basis-0 mb-12"},null,-1)),be(rL,{bot:e.bot,"is-online":u.value},null,8,["bot","is-online"]),b("div",$L,[be(Xa,{theme:"primary",size:"lg",class:"w-full",icon:S.value,"data-test":"voice-button",onClick:j[4]||(j[4]=O=>i.value?.setMode("talk"))},{default:ot(()=>[xt(de(T.value),1)]),_:1},8,["icon"]),e.bot.accounts.value&&e.bot.accounts.value.length>0?(w(),$("div",SL,[(w(!0),$(ge,null,st((e.bot.accounts.value||[]).filter(O=>Ae(wo)[O.platform]),O=>(w(),$("a",{key:`${O.platform}-${O.handle}`,href:Ae(wo)[O.platform].getUrl(O.handle),target:"_blank",class:"size-12 rounded-full text-white/60 hover:text-white hover:bg-white/5 border border-white/0 hover:border-white/10 flex items-center justify-center transition-all duration-200 hover:scale-105"},[b("i",{class:V([Ae(wo)[O.platform].icon,"size-5"])},null,2)],8,IL))),128))])):te("",!0)])])):l.value==="talk"?(w(),$("div",EL,[e.requireAuth&&!d.value?(w(),Fe(PE,{key:0,sdk:e.sdk},null,8,["sdk"])):(w(),$(ge,{key:1},[b("div",null,[b("div",TL,[be(Lp,{bot:e.bot,"is-online":u.value},null,8,["bot","is-online"])])]),be(yo,{"chat-controller":i.value,bot:e.bot},null,8,["chat-controller","bot"])],64))])):(w(),$("div",NL,[b("div",CL,[l.value==="chat"?(w(),$(ge,{key:0},[e.requireAuth&&!d.value?(w(),Fe(PE,{key:0,sdk:e.sdk},null,8,["sdk"])):(w(),Fe(yo,{key:1,"chat-controller":i.value,bot:e.bot,"show-header":""},null,8,["chat-controller","bot"]))],64)):l.value==="info"?(w(),Fe(KM,{key:1,bot:e.bot,"is-online":u.value},null,8,["bot","is-online"])):te("",!0)])]))],64))],2)],14,gL)):a.value?(w(),$("div",zL,[b("div",AL,[j[12]||(j[12]=b("div",{class:"flex justify-center"},[b("div",{class:"rounded-full bg-red-500/20 flex items-center justify-center size-10"},[b("i",{class:"i-tabler-alert-circle size-6 text-red-400"})])],-1)),j[13]||(j[13]=b("h3",{class:"text-lg font-medium"}," Bot Error ",-1)),b("p",OL,de(a.value),1)])])):(w(),$("div",DL," Couldn't load your assistant. Please try again later. ")),e.chatOnly?te("",!0):(w(),Fe(fL,{key:4,modelValue:r.value,"onUpdate:modelValue":j[5]||(j[5]=O=>r.value=O),bot:e.bot,sdk:e.sdk,title:e.bot.displayName.value,"data-test":"bot-sidebar"},null,8,["modelValue","bot","sdk","title"])),e.chatOnly?te("",!0):(w(),Fe(mL,{key:5,modelValue:o.value,"onUpdate:modelValue":j[6]||(j[6]=O=>o.value=O),"chat-controller":i.value,"data-test":"bot-mode-sidebar"},null,8,["modelValue","chat-controller"]))]))}}),Zp=Pe({__name:"BotProvider",props:{sdk:{},bot:{},handle:{},context:{},clientContext:{},firstMessage:{},buttonText:{},buttonIcon:{},hasClose:{type:Boolean},chatOnly:{type:Boolean},bare:{type:Boolean},apiBase:{},emptyStateMessage:{}},emits:["close","error","turnStarted","turnCompleted"],setup(e,{emit:t}){let n=e,i=t;return(r,o)=>(w(),Fe(Vp,R0(n,{class:"bot-provider size-full relative"}),{default:ot(a=>[be(PL,{sdk:a.sdk,bot:a.bot,context:a.context,"first-message":a.firstMessage,"button-text":n.buttonText,"button-icon":n.buttonIcon,"has-close":n.hasClose,"chat-only":n.chatOnly,bare:n.bare,"empty-state-message":n.emptyStateMessage,"is-active":!0,class:"size-full",onClose:o[0]||(o[0]=s=>i("close",s)),onError:o[1]||(o[1]=s=>i("error",s)),onTurnStarted:o[2]||(o[2]=s=>i("turnStarted")),onTurnCompleted:o[3]||(o[3]=s=>i("turnCompleted",s))},Pa({_:2},[r.$slots["empty-heading"]?{name:"empty-heading",fn:ot(s=>[zt(r.$slots,"empty-heading",xa(Ra(s)))]),key:"0"}:void 0]),1032,["sdk","bot","context","first-message","button-text","button-icon","has-close","chat-only","bare","empty-state-message"])]),_:3},16))}})});var jE={};Xr(jE,{default:()=>RL});var RL,ME=re(()=>{"use strict";Pn();My();Bp();En();RL=Pe({__name:"BotWidgetInline",props:{sdk:{},handle:{},bot:{},context:{},firstMessage:{},buttonText:{},buttonIcon:{},chatOnly:{type:Boolean}},setup(e,{expose:t}){let{currentBot:n,currentContext:i,currentFirstMessage:r,currentButtonText:o,currentButtonIcon:a,update:s}=es(e);return t({update:s}),(l,u)=>(w(),Fe(Zp,{sdk:e.sdk,handle:e.handle,bot:Ae(n),context:Ae(i),"first-message":Ae(r),"button-text":Ae(o),"button-icon":Ae(a),"chat-only":e.chatOnly},null,8,["sdk","handle","bot","context","first-message","button-text","button-icon","chat-only"]))}})});var LE={};Xr(LE,{default:()=>UL});var UL,VE=re(()=>{"use strict";Pn();Fp();My();Bp();En();UL=Pe({__name:"BotWidgetModal",props:{sdk:{},handle:{},bot:{},context:{},firstMessage:{},buttonText:{},buttonIcon:{},chatOnly:{type:Boolean},onClose:{type:Function}},setup(e,{expose:t}){let n=e,{currentBot:i,currentContext:r,currentFirstMessage:o,currentButtonText:a,currentButtonIcon:s,update:l}=es(n),u=Q(!1);Ut(async()=>{await oo(),setTimeout(()=>{u.value=!0},10)});function d(){u.value=!1,setTimeout(()=>{n.onClose&&n.onClose()},300)}function p(){u.value=!0}return t({update:l,close:d,open:p}),(m,f)=>(w(),Fe(jy,{vis:u.value,"disable-teleport":!0,"modal-class":"max-w-4xl h-[80vh] md:h-[600px]","has-close":!1,"onUpdate:vis":f[0]||(f[0]=h=>u.value=h),onClose:d},{default:ot(()=>[be(Zp,{sdk:e.sdk,handle:e.handle,bot:Ae(i),context:Ae(r),"first-message":Ae(o),"button-text":Ae(a),"button-icon":Ae(s),"chat-only":e.chatOnly,"has-close":!0,onClose:d},null,8,["sdk","handle","bot","context","first-message","button-text","button-icon","chat-only"])]),_:1},8,["vis"]))}})});Pn();oy();Fp();Bp();ql();En();var jL=`/*! tailwindcss v4.3.5 | MIT License | https://tailwindcss.com */
|
|
169
|
+
@layer properties{@supports (((-webkit-hyphens:none)) and (not (margin-trim:block))) or ((-moz-orient:inline) and (not (color:rgb(from red r g b)))){*,:before,:after{--tw-translate-x:0;--tw-translate-y:0;--tw-translate-z:0;--tw-scale-x:1;--tw-scale-y:1;--tw-scale-z:1;--tw-rotate-x:initial;--tw-rotate-y:initial;--tw-rotate-z:initial;--tw-skew-x:initial;--tw-skew-y:initial;--tw-space-y-reverse:0;--tw-border-style:solid;--tw-gradient-position:initial;--tw-gradient-from:#0000;--tw-gradient-via:#0000;--tw-gradient-to:#0000;--tw-gradient-stops:initial;--tw-gradient-via-stops:initial;--tw-gradient-from-position:0%;--tw-gradient-via-position:50%;--tw-gradient-to-position:100%;--tw-leading:initial;--tw-font-weight:initial;--tw-tracking:initial;--tw-ordinal:initial;--tw-slashed-zero:initial;--tw-numeric-figure:initial;--tw-numeric-spacing:initial;--tw-numeric-fraction:initial;--tw-shadow:0 0 #0000;--tw-shadow-color:initial;--tw-shadow-alpha:100%;--tw-inset-shadow:0 0 #0000;--tw-inset-shadow-color:initial;--tw-inset-shadow-alpha:100%;--tw-ring-color:initial;--tw-ring-shadow:0 0 #0000;--tw-inset-ring-color:initial;--tw-inset-ring-shadow:0 0 #0000;--tw-ring-inset:initial;--tw-ring-offset-width:0px;--tw-ring-offset-color:#fff;--tw-ring-offset-shadow:0 0 #0000;--tw-blur:initial;--tw-brightness:initial;--tw-contrast:initial;--tw-grayscale:initial;--tw-hue-rotate:initial;--tw-invert:initial;--tw-opacity:initial;--tw-saturate:initial;--tw-sepia:initial;--tw-drop-shadow:initial;--tw-drop-shadow-color:initial;--tw-drop-shadow-alpha:100%;--tw-drop-shadow-size:initial;--tw-backdrop-blur:initial;--tw-backdrop-brightness:initial;--tw-backdrop-contrast:initial;--tw-backdrop-grayscale:initial;--tw-backdrop-hue-rotate:initial;--tw-backdrop-invert:initial;--tw-backdrop-opacity:initial;--tw-backdrop-saturate:initial;--tw-backdrop-sepia:initial;--tw-duration:initial;--tw-ease:initial}::backdrop{--tw-translate-x:0;--tw-translate-y:0;--tw-translate-z:0;--tw-scale-x:1;--tw-scale-y:1;--tw-scale-z:1;--tw-rotate-x:initial;--tw-rotate-y:initial;--tw-rotate-z:initial;--tw-skew-x:initial;--tw-skew-y:initial;--tw-space-y-reverse:0;--tw-border-style:solid;--tw-gradient-position:initial;--tw-gradient-from:#0000;--tw-gradient-via:#0000;--tw-gradient-to:#0000;--tw-gradient-stops:initial;--tw-gradient-via-stops:initial;--tw-gradient-from-position:0%;--tw-gradient-via-position:50%;--tw-gradient-to-position:100%;--tw-leading:initial;--tw-font-weight:initial;--tw-tracking:initial;--tw-ordinal:initial;--tw-slashed-zero:initial;--tw-numeric-figure:initial;--tw-numeric-spacing:initial;--tw-numeric-fraction:initial;--tw-shadow:0 0 #0000;--tw-shadow-color:initial;--tw-shadow-alpha:100%;--tw-inset-shadow:0 0 #0000;--tw-inset-shadow-color:initial;--tw-inset-shadow-alpha:100%;--tw-ring-color:initial;--tw-ring-shadow:0 0 #0000;--tw-inset-ring-color:initial;--tw-inset-ring-shadow:0 0 #0000;--tw-ring-inset:initial;--tw-ring-offset-width:0px;--tw-ring-offset-color:#fff;--tw-ring-offset-shadow:0 0 #0000;--tw-blur:initial;--tw-brightness:initial;--tw-contrast:initial;--tw-grayscale:initial;--tw-hue-rotate:initial;--tw-invert:initial;--tw-opacity:initial;--tw-saturate:initial;--tw-sepia:initial;--tw-drop-shadow:initial;--tw-drop-shadow-color:initial;--tw-drop-shadow-alpha:100%;--tw-drop-shadow-size:initial;--tw-backdrop-blur:initial;--tw-backdrop-brightness:initial;--tw-backdrop-contrast:initial;--tw-backdrop-grayscale:initial;--tw-backdrop-hue-rotate:initial;--tw-backdrop-invert:initial;--tw-backdrop-opacity:initial;--tw-backdrop-saturate:initial;--tw-backdrop-sepia:initial;--tw-duration:initial;--tw-ease:initial}}}@layer theme{:root,:host{--font-sans:system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;--font-mono:"DM Mono", "SF Mono", SFMono-Regular, Consolas, "Liberation Mono", Menlo, Courier, monospace;--color-red-300:#ffa3a3;--color-red-400:#ff6568;--color-red-500:#fb2c36;--color-red-600:#e40014;--color-amber-500:#f99c00;--color-green-300:#7bf1a8;--color-green-400:#05df72;--color-green-500:#00c758;--color-green-600:#00a544;--color-slate-200:#e2e8f0;--color-slate-950:#020618;--color-black:#000;--color-white:#fff;--spacing:.25rem;--breakpoint-md:48rem;--container-xs:20rem;--container-sm:24rem;--container-md:28rem;--container-4xl:56rem;--text-xs:.75rem;--text-xs--line-height:calc(1 / .75);--text-sm:.875rem;--text-sm--line-height:calc(1.25 / .875);--text-base:1rem;--text-base--line-height:calc(1.5 / 1);--text-lg:1.125rem;--text-lg--line-height:calc(1.75 / 1.125);--text-xl:1.25rem;--text-xl--line-height:calc(1.75 / 1.25);--text-2xl:1.5rem;--text-2xl--line-height:calc(2 / 1.5);--text-3xl:1.875rem;--text-3xl--line-height:calc(2.25 / 1.875);--font-weight-light:300;--font-weight-medium:500;--font-weight-semibold:600;--tracking-wide:.025em;--tracking-widest:.1em;--leading-tight:1.25;--leading-snug:1.375;--leading-relaxed:1.625;--radius-lg:.5rem;--radius-xl:.75rem;--radius-2xl:1rem;--radius-3xl:1.5rem;--ease-in:cubic-bezier(.4, 0, 1, 1);--ease-out:cubic-bezier(0, 0, .2, 1);--ease-in-out:cubic-bezier(.4, 0, .2, 1);--animate-spin:spin 1s linear infinite;--animate-ping:ping 1s cubic-bezier(0, 0, .2, 1) infinite;--animate-pulse:pulse 2s cubic-bezier(.4, 0, .6, 1) infinite;--blur-sm:8px;--blur-lg:16px;--blur-xl:24px;--default-transition-duration:.15s;--default-transition-timing-function:cubic-bezier(.4, 0, .2, 1);--default-font-family:var(--font-sans);--default-mono-font-family:var(--font-mono);--color-theme-0:var(--theme-0,#fff);--color-theme-25:var(--theme-25,#f8fafc);--color-theme-50:var(--theme-50,#f3f4f6);--color-theme-100:var(--theme-100,#e5e7eb);--color-theme-200:var(--theme-200,#d1d5db);--color-theme-300:var(--theme-300,#9ca3af);--color-theme-400:var(--theme-400,#6b7280);--color-theme-500:var(--theme-500,#4b5563);--color-theme-600:var(--theme-600,#374151);--color-theme-700:var(--theme-700,#1f2a44);--color-theme-800:var(--theme-800,#111827);--color-theme-900:var(--theme-900,#0c0a13);--color-theme-950:var(--theme-950,#030712);--color-primary-300:var(--primary-300,#60a5fa);--color-primary-400:var(--primary-400,#3b82f6);--color-primary-500:var(--primary-500,#2563eb);--color-primary-600:var(--primary-600,#1d4ed8)}@supports (color:color(display-p3 0 0 0)){:root,:host{--color-red-300:color(display-p3 .956922 .651886 .645122);--color-red-400:color(display-p3 .933534 .431676 .423491);--color-red-500:color(display-p3 .903738 .262579 .253307);--color-red-600:color(display-p3 .830323 .140383 .133196);--color-amber-500:color(display-p3 .93994 .620584 .0585367);--color-green-300:color(display-p3 .600292 .935514 .68114);--color-green-400:color(display-p3 .399536 .862346 .49324);--color-green-500:color(display-p3 .308734 .774754 .374307);--color-green-600:color(display-p3 .243882 .640824 .294808);--color-slate-200:color(display-p3 .890322 .909405 .939294);--color-slate-950:color(display-p3 .0102437 .0227555 .0878731)}}@supports (color:lab(0% 0 0)){:root,:host{--color-red-300:lab(76.5514% 36.422 15.5335);--color-red-400:lab(63.7053% 60.745 31.3109);--color-red-500:lab(55.4814% 75.0732 48.8528);--color-red-600:lab(48.4493% 77.4328 61.5452);--color-amber-500:lab(72.7183% 31.8672 97.9407);--color-green-300:lab(86.9953% -47.2691 25.0054);--color-green-400:lab(78.503% -64.9265 39.7492);--color-green-500:lab(70.5521% -66.5147 45.8073);--color-green-600:lab(59.0978% -58.6621 41.2579);--color-slate-200:lab(91.7353% -.998765 -4.76968);--color-slate-950:lab(1.76974% 1.32743 -9.28855)}}}@layer base{*,:after,:before{box-sizing:border-box;border:0 solid;margin:0;padding:0}::backdrop{box-sizing:border-box;border:0 solid;margin:0;padding:0}::-webkit-file-upload-button{box-sizing:border-box;border:0 solid;margin:0;padding:0}::file-selector-button{box-sizing:border-box;border:0 solid;margin:0;padding:0}html,:host{-webkit-text-size-adjust:100%;-moz-tab-size:4;tab-size:4;line-height:1.5;font-family:var(--default-font-family,-apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", "Noto Sans", Arial, sans-serif, "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol", "Noto Color Emoji");font-feature-settings:var(--default-font-feature-settings,normal);font-variation-settings:var(--default-font-variation-settings,normal);-webkit-tap-highlight-color:transparent}hr{height:0;color:inherit;border-top-width:1px}abbr:where([title]){-webkit-text-decoration:underline dotted;text-decoration:underline dotted}h1,h2,h3,h4,h5,h6{font-size:inherit;font-weight:inherit}a{color:inherit;-webkit-text-decoration:inherit;-webkit-text-decoration:inherit;-webkit-text-decoration:inherit;-webkit-text-decoration:inherit;text-decoration:inherit}b,strong{font-weight:bolder}code,kbd,samp,pre{font-family:var(--default-mono-font-family,ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace);font-feature-settings:var(--default-mono-font-feature-settings,normal);font-variation-settings:var(--default-mono-font-variation-settings,normal);font-size:1em}small{font-size:80%}sub,sup{vertical-align:baseline;font-size:75%;line-height:0;position:relative}sub{bottom:-.25em}sup{top:-.5em}table{text-indent:0;border-color:inherit;border-collapse:collapse}:-moz-focusring:where(:not(iframe)){outline:auto}progress{vertical-align:baseline}summary{display:list-item}ol,ul,menu{list-style:none}img,svg,video,canvas,audio,iframe,embed,object{vertical-align:middle;display:block}img,video{max-width:100%;height:auto}button,input,select,optgroup,textarea{font:inherit;font-feature-settings:inherit;font-variation-settings:inherit;letter-spacing:inherit;color:inherit;opacity:1;background-color:#0000;border-radius:0}::-webkit-file-upload-button{font:inherit;font-feature-settings:inherit;font-variation-settings:inherit;letter-spacing:inherit;color:inherit;opacity:1;background-color:#0000;border-radius:0}::file-selector-button{font:inherit;font-feature-settings:inherit;font-variation-settings:inherit;letter-spacing:inherit;color:inherit;opacity:1;background-color:#0000;border-radius:0}:where(select:-webkit-any([multiple],[size])) optgroup{font-weight:bolder}:where(select:is([multiple],[size])) optgroup{font-weight:bolder}:where(select:-webkit-any([multiple],[size])) optgroup option{padding-inline-start:20px}:where(select:is([multiple],[size])) optgroup option{padding-inline-start:20px}::-webkit-file-upload-button{margin-inline-end:4px}::file-selector-button{margin-inline-end:4px}::placeholder{opacity:1}@supports (not ((-webkit-appearance:-apple-pay-button))) or (contain-intrinsic-size:1px){::placeholder{color:currentColor}@supports (color:color-mix(in lab, red, red)){::placeholder{color:color-mix(in oklab, currentcolor 50%, transparent)}}}textarea{resize:vertical}::-webkit-search-decoration{-webkit-appearance:none}::-webkit-date-and-time-value{min-height:1lh;text-align:inherit}::-webkit-datetime-edit{display:inline-flex}::-webkit-datetime-edit-fields-wrapper{padding:0}::-webkit-datetime-edit{padding-block-start:0;padding-block-end:0}::-webkit-datetime-edit-year-field{padding-block-start:0;padding-block-end:0}::-webkit-datetime-edit-month-field{padding-block-start:0;padding-block-end:0}::-webkit-datetime-edit-day-field{padding-block-start:0;padding-block-end:0}::-webkit-datetime-edit-hour-field{padding-block-start:0;padding-block-end:0}::-webkit-datetime-edit-minute-field{padding-block-start:0;padding-block-end:0}::-webkit-datetime-edit-second-field{padding-block-start:0;padding-block-end:0}::-webkit-datetime-edit-millisecond-field{padding-block-start:0;padding-block-end:0}::-webkit-datetime-edit-meridiem-field{padding-block-start:0;padding-block-end:0}::-webkit-calendar-picker-indicator{line-height:1}:-moz-ui-invalid{box-shadow:none}button{-webkit-appearance:button;appearance:button}input:where([type=button],[type=reset],[type=submit]){-webkit-appearance:button;appearance:button}::-webkit-file-upload-button{-webkit-appearance:button;appearance:button}::file-selector-button{-webkit-appearance:button;appearance:button}::-webkit-inner-spin-button{height:auto}::-webkit-outer-spin-button{height:auto}[hidden]:where(:not([hidden=until-found])){display:none!important}}@layer components;@layer utilities{.\\@container\\/bot{container:bot/inline-size}.\\@container\\/chat{container:chat/inline-size}.\\@container\\/chat-preview{container:chat-preview/inline-size}.\\@container{container-type:inline-size}.pointer-events-auto{pointer-events:auto}.pointer-events-none{pointer-events:none}.collapse{visibility:collapse}.invisible{visibility:hidden}.visible{visibility:visible}.sr-only{clip-path:inset(50%);white-space:nowrap;border-width:0;width:1px;height:1px;margin:-1px;padding:0;position:absolute;overflow:hidden}.absolute{position:absolute}.fixed{position:fixed}.relative{position:relative}.static{position:static}.inset-0{top:0;bottom:0;left:0;right:0}.inset-x-0{left:0;right:0}.-top-1\\.5{top:calc(var(--spacing) * -1.5)}.top-0{top:0}.top-0\\.5{top:calc(var(--spacing) * .5)}.top-1{top:var(--spacing)}.top-1\\.5{top:calc(var(--spacing) * 1.5)}.top-1\\/2{top:50%}.top-4{top:calc(var(--spacing) * 4)}.top-6{top:calc(var(--spacing) * 6)}.top-\\[5\\%\\]{top:5%}.-right-1\\.5{right:calc(var(--spacing) * -1.5)}.-right-16{right:calc(var(--spacing) * -16)}.right-0{right:0}.right-0\\.5{right:calc(var(--spacing) * .5)}.right-1{right:var(--spacing)}.right-1\\.5{right:calc(var(--spacing) * 1.5)}.right-4{right:calc(var(--spacing) * 4)}.right-6{right:calc(var(--spacing) * 6)}.right-\\[5\\%\\]{right:5%}.-bottom-\\[3\\%\\]{bottom:-3%}.bottom-0{bottom:0}.bottom-4{bottom:calc(var(--spacing) * 4)}.bottom-6{bottom:calc(var(--spacing) * 6)}.-left-16{left:calc(var(--spacing) * -16)}.-left-\\[3\\%\\]{left:-3%}.left-0{left:0}.left-1\\/2{left:50%}.left-4{left:calc(var(--spacing) * 4)}.left-6{left:calc(var(--spacing) * 6)}.left-\\[13px\\]{left:13px}.z-0{z-index:0}.z-10{z-index:10}.z-20{z-index:20}.z-30{z-index:30}.z-40{z-index:40}.z-50{z-index:50}.z-\\[100\\]{z-index:100}.z-\\[999999\\]{z-index:999999}.container{width:100%}@media (min-width:40rem){.container{max-width:40rem}}@media (min-width:48rem){.container{max-width:48rem}}@media (min-width:64rem){.container{max-width:64rem}}@media (min-width:80rem){.container{max-width:80rem}}@media (min-width:96rem){.container{max-width:96rem}}.mx-auto{margin-inline-start:auto;margin-inline-end:auto}.my-2{margin-block:calc(var(--spacing) * 2)}.my-6{margin-block:calc(var(--spacing) * 6)}.mt-0\\.5{margin-top:calc(var(--spacing) * .5)}.mt-1{margin-top:var(--spacing)}.mt-2{margin-top:calc(var(--spacing) * 2)}.mt-2\\.5{margin-top:calc(var(--spacing) * 2.5)}.mt-3{margin-top:calc(var(--spacing) * 3)}.mt-5{margin-top:calc(var(--spacing) * 5)}.mt-16{margin-top:calc(var(--spacing) * 16)}.mt-\\[-\\.07em\\]{margin-top:-.07em}.-mr-1{margin-right:calc(var(--spacing) * -1)}.mr-2{margin-right:calc(var(--spacing) * 2)}.mb-1{margin-bottom:var(--spacing)}.mb-1\\.5{margin-bottom:calc(var(--spacing) * 1.5)}.mb-2{margin-bottom:calc(var(--spacing) * 2)}.mb-2\\.5{margin-bottom:calc(var(--spacing) * 2.5)}.mb-4{margin-bottom:calc(var(--spacing) * 4)}.mb-6{margin-bottom:calc(var(--spacing) * 6)}.mb-10{margin-bottom:calc(var(--spacing) * 10)}.mb-12{margin-bottom:calc(var(--spacing) * 12)}.-ml-1{margin-left:calc(var(--spacing) * -1)}.-ml-2{margin-left:calc(var(--spacing) * -2)}.ml-1\\.5{margin-left:calc(var(--spacing) * 1.5)}.ml-3{margin-left:calc(var(--spacing) * 3)}.ml-auto{margin-left:auto}.i-heroicons-calendar{width:1em;height:1em;-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);mask-image:var(--svg);--svg:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' width='24' height='24'%3E%3Cpath fill='none' stroke='black' stroke-linecap='round' stroke-linejoin='round' stroke-width='1.5' d='M6.75 3v2.25M17.25 3v2.25M3 18.75V7.5a2.25 2.25 0 0 1 2.25-2.25h13.5A2.25 2.25 0 0 1 21 7.5v11.25m-18 0A2.25 2.25 0 0 0 5.25 21h13.5A2.25 2.25 0 0 0 21 18.75m-18 0v-7.5A2.25 2.25 0 0 1 5.25 9h13.5A2.25 2.25 0 0 1 21 11.25v7.5'/%3E%3C/svg%3E");background-color:currentColor;display:inline-block;-webkit-mask-size:100% 100%;mask-size:100% 100%;-webkit-mask-repeat:no-repeat;mask-repeat:no-repeat}.i-heroicons-chat-bubble-left-right{width:1em;height:1em;-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);mask-image:var(--svg);--svg:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' width='24' height='24'%3E%3Cpath fill='none' stroke='black' stroke-linecap='round' stroke-linejoin='round' stroke-width='1.5' d='M20.25 8.511c.884.284 1.5 1.128 1.5 2.097v4.286c0 1.136-.847 2.1-1.98 2.193q-.51.041-1.02.072v3.091l-3-3q-2.031 0-4.02-.163a2.1 2.1 0 0 1-.825-.242m9.345-8.334a2 2 0 0 0-.476-.095a48.6 48.6 0 0 0-8.048 0c-1.131.094-1.976 1.057-1.976 2.192v4.286c0 .837.46 1.58 1.155 1.951m9.345-8.334V6.637c0-1.621-1.152-3.026-2.76-3.235A48.5 48.5 0 0 0 11.25 3c-2.115 0-4.198.137-6.24.402c-1.608.209-2.76 1.614-2.76 3.235v6.226c0 1.621 1.152 3.026 2.76 3.235q.865.113 1.74.194V21l4.155-4.155'/%3E%3C/svg%3E");background-color:currentColor;display:inline-block;-webkit-mask-size:100% 100%;mask-size:100% 100%;-webkit-mask-repeat:no-repeat;mask-repeat:no-repeat}.i-heroicons-envelope{width:1em;height:1em;-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);mask-image:var(--svg);--svg:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' width='24' height='24'%3E%3Cpath fill='none' stroke='black' stroke-linecap='round' stroke-linejoin='round' stroke-width='1.5' d='M21.75 6.75v10.5a2.25 2.25 0 0 1-2.25 2.25h-15a2.25 2.25 0 0 1-2.25-2.25V6.75m19.5 0A2.25 2.25 0 0 0 19.5 4.5h-15a2.25 2.25 0 0 0-2.25 2.25m19.5 0v.243a2.25 2.25 0 0 1-1.07 1.916l-7.5 4.615a2.25 2.25 0 0 1-2.36 0L3.32 8.91a2.25 2.25 0 0 1-1.07-1.916V6.75'/%3E%3C/svg%3E");background-color:currentColor;display:inline-block;-webkit-mask-size:100% 100%;mask-size:100% 100%;-webkit-mask-repeat:no-repeat;mask-repeat:no-repeat}.i-heroicons-phone{width:1em;height:1em;-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);mask-image:var(--svg);--svg:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' width='24' height='24'%3E%3Cpath fill='none' stroke='black' stroke-linecap='round' stroke-linejoin='round' stroke-width='1.5' d='M2.25 6.75c0 8.284 6.716 15 15 15h2.25a2.25 2.25 0 0 0 2.25-2.25v-1.372c0-.516-.351-.966-.852-1.091l-4.423-1.106c-.44-.11-.902.055-1.173.417l-.97 1.293c-.282.376-.769.542-1.21.38a12.04 12.04 0 0 1-7.143-7.143c-.162-.441.004-.928.38-1.21l1.293-.97c.363-.271.527-.734.417-1.173L6.963 3.102a1.125 1.125 0 0 0-1.091-.852H4.5A2.25 2.25 0 0 0 2.25 4.5z'/%3E%3C/svg%3E");background-color:currentColor;display:inline-block;-webkit-mask-size:100% 100%;mask-size:100% 100%;-webkit-mask-repeat:no-repeat;mask-repeat:no-repeat}.i-heroicons-question-mark-circle{width:1em;height:1em;-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);mask-image:var(--svg);--svg:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' width='24' height='24'%3E%3Cpath fill='none' stroke='black' stroke-linecap='round' stroke-linejoin='round' stroke-width='1.5' d='M9.879 7.519c1.172-1.025 3.071-1.025 4.243 0c1.171 1.025 1.171 2.687 0 3.712q-.308.268-.67.442c-.746.361-1.452.999-1.452 1.827v.75M21 12a9 9 0 1 1-18 0a9 9 0 0 1 18 0m-9 5.25h.008v.008H12z'/%3E%3C/svg%3E");background-color:currentColor;display:inline-block;-webkit-mask-size:100% 100%;mask-size:100% 100%;-webkit-mask-repeat:no-repeat;mask-repeat:no-repeat}.i-heroicons-sparkles{width:1em;height:1em;-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);mask-image:var(--svg);--svg:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' width='24' height='24'%3E%3Cpath fill='none' stroke='black' stroke-linecap='round' stroke-linejoin='round' stroke-width='1.5' d='M9.813 15.904L9 18.75l-.813-2.846a4.5 4.5 0 0 0-3.09-3.09L2.25 12l2.846-.813a4.5 4.5 0 0 0 3.09-3.09L9 5.25l.813 2.846a4.5 4.5 0 0 0 3.09 3.09L15.75 12l-2.846.813a4.5 4.5 0 0 0-3.09 3.09m8.445-7.188L18 9.75l-.259-1.035a3.38 3.38 0 0 0-2.455-2.456L14.25 6l1.036-.259a3.38 3.38 0 0 0 2.455-2.456L18 2.25l.259 1.035a3.38 3.38 0 0 0 2.456 2.456L21.75 6l-1.035.259a3.38 3.38 0 0 0-2.456 2.456m-1.365 11.852L16.5 21.75l-.394-1.183a2.25 2.25 0 0 0-1.423-1.423L13.5 18.75l1.183-.394a2.25 2.25 0 0 0 1.423-1.423l.394-1.183l.394 1.183a2.25 2.25 0 0 0 1.423 1.423l1.183.394l-1.183.394a2.25 2.25 0 0 0-1.423 1.423'/%3E%3C/svg%3E");background-color:currentColor;display:inline-block;-webkit-mask-size:100% 100%;mask-size:100% 100%;-webkit-mask-repeat:no-repeat;mask-repeat:no-repeat}.i-simple-icons-facebook{width:1em;height:1em;-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);mask-image:var(--svg);--svg:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' width='24' height='24'%3E%3Cpath fill='black' d='M9.101 23.691v-7.98H6.627v-3.667h2.474v-1.58c0-4.085 1.848-5.978 5.858-5.978c.401 0 .955.042 1.468.103a9 9 0 0 1 1.141.195v3.325a9 9 0 0 0-.653-.036a27 27 0 0 0-.733-.009c-.707 0-1.259.096-1.675.309a1.7 1.7 0 0 0-.679.622c-.258.42-.374.995-.374 1.752v1.297h3.919l-.386 2.103l-.287 1.564h-3.246v8.245C19.396 23.238 24 18.179 24 12.044c0-6.627-5.373-12-12-12s-12 5.373-12 12c0 5.628 3.874 10.35 9.101 11.647'/%3E%3C/svg%3E");background-color:currentColor;display:inline-block;-webkit-mask-size:100% 100%;mask-size:100% 100%;-webkit-mask-repeat:no-repeat;mask-repeat:no-repeat}.i-simple-icons-instagram{width:1em;height:1em;-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);mask-image:var(--svg);--svg:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' width='24' height='24'%3E%3Cpath fill='black' d='M7.03.084c-1.277.06-2.149.264-2.91.563a5.9 5.9 0 0 0-2.124 1.388a5.9 5.9 0 0 0-1.38 2.127C.321 4.926.12 5.8.064 7.076s-.069 1.688-.063 4.947s.021 3.667.083 4.947c.061 1.277.264 2.149.563 2.911c.308.789.72 1.457 1.388 2.123a5.9 5.9 0 0 0 2.129 1.38c.763.295 1.636.496 2.913.552c1.278.056 1.689.069 4.947.063s3.668-.021 4.947-.082c1.28-.06 2.147-.265 2.91-.563a5.9 5.9 0 0 0 2.123-1.388a5.9 5.9 0 0 0 1.38-2.129c.295-.763.496-1.636.551-2.912c.056-1.28.07-1.69.063-4.948c-.006-3.258-.02-3.667-.081-4.947c-.06-1.28-.264-2.148-.564-2.911a5.9 5.9 0 0 0-1.387-2.123a5.9 5.9 0 0 0-2.128-1.38c-.764-.294-1.636-.496-2.914-.55C15.647.009 15.236-.006 11.977 0S8.31.021 7.03.084m.14 21.693c-1.17-.05-1.805-.245-2.228-.408a3.7 3.7 0 0 1-1.382-.895a3.7 3.7 0 0 1-.9-1.378c-.165-.423-.363-1.058-.417-2.228c-.06-1.264-.072-1.644-.08-4.848c-.006-3.204.006-3.583.061-4.848c.05-1.169.246-1.805.408-2.228c.216-.561.477-.96.895-1.382a3.7 3.7 0 0 1 1.379-.9c.423-.165 1.057-.361 2.227-.417c1.265-.06 1.644-.072 4.848-.08c3.203-.006 3.583.006 4.85.062c1.168.05 1.804.244 2.227.408c.56.216.96.475 1.382.895s.681.817.9 1.378c.165.422.362 1.056.417 2.227c.06 1.265.074 1.645.08 4.848c.005 3.203-.006 3.583-.061 4.848c-.051 1.17-.245 1.805-.408 2.23c-.216.56-.477.96-.896 1.38a3.7 3.7 0 0 1-1.378.9c-.422.165-1.058.362-2.226.418c-1.266.06-1.645.072-4.85.079s-3.582-.006-4.848-.06m9.783-16.192a1.44 1.44 0 1 0 1.437-1.442a1.44 1.44 0 0 0-1.437 1.442M5.839 12.012a6.161 6.161 0 1 0 12.323-.024a6.162 6.162 0 0 0-12.323.024M8 12.008A4 4 0 1 1 12.008 16A4 4 0 0 1 8 12.008'/%3E%3C/svg%3E");background-color:currentColor;display:inline-block;-webkit-mask-size:100% 100%;mask-size:100% 100%;-webkit-mask-repeat:no-repeat;mask-repeat:no-repeat}.i-simple-icons-linkedin{width:1em;height:1em;-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);mask-image:var(--svg);--svg:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' width='24' height='24'%3E%3Cpath fill='black' d='M20.447 20.452h-3.554v-5.569c0-1.328-.027-3.037-1.852-3.037c-1.853 0-2.136 1.445-2.136 2.939v5.667H9.351V9h3.414v1.561h.046c.477-.9 1.637-1.85 3.37-1.85c3.601 0 4.267 2.37 4.267 5.455v6.286zM5.337 7.433a2.06 2.06 0 0 1-2.063-2.065a2.064 2.064 0 1 1 2.063 2.065m1.782 13.019H3.555V9h3.564zM22.225 0H1.771C.792 0 0 .774 0 1.729v20.542C0 23.227.792 24 1.771 24h20.451C23.2 24 24 23.227 24 22.271V1.729C24 .774 23.2 0 22.222 0z'/%3E%3C/svg%3E");background-color:currentColor;display:inline-block;-webkit-mask-size:100% 100%;mask-size:100% 100%;-webkit-mask-repeat:no-repeat;mask-repeat:no-repeat}.i-simple-icons-threads{width:1em;height:1em;-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);mask-image:var(--svg);--svg:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' width='24' height='24'%3E%3Cpath fill='black' d='M18.263 11.097c-.03-3.486-1.92-5.586-5.111-5.586c-2.13 0-3.922.963-4.863 2.499l2.062 1.438c.535-.843 1.272-1.543 2.628-1.543c1.528 0 2.318.85 2.544 2.431a15 15 0 0 0-2.236-.173c-4.125 0-6.068 1.867-6.068 4.336s1.943 3.99 4.804 3.99c3.139 0 5.013-2.115 5.781-4.735c.798.361 1.348 1.204 1.348 2.47c0 3.387-3.907 5.232-7.22 5.232c-4.885 0-8.077-3.207-8.077-8.424c0-6.392 4.223-10.487 9.9-10.487c3.808 0 5.69 1.671 6.97 3.914l2.108-1.475C21.44 2.078 18.331 0 13.663 0C6.227 0 1.168 5.277 1.168 12.934c0 7 4.953 11.066 10.856 11.066c4.878 0 9.809-2.846 9.809-7.716c0-2.545-1.46-4.231-3.569-5.187m-6.33 4.855c-1.077 0-2.026-.512-2.026-1.453c0-1.483 1.822-1.934 3.606-1.934c.678 0 1.34.045 1.927.173c-.422 1.927-1.671 3.215-3.508 3.214Z'/%3E%3C/svg%3E");background-color:currentColor;display:inline-block;-webkit-mask-size:100% 100%;mask-size:100% 100%;-webkit-mask-repeat:no-repeat;mask-repeat:no-repeat}.i-simple-icons-tiktok{width:1em;height:1em;-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);mask-image:var(--svg);--svg:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' width='24' height='24'%3E%3Cpath fill='black' d='M12.525.02c1.31-.02 2.61-.01 3.91-.02c.08 1.53.63 3.09 1.75 4.17c1.12 1.11 2.7 1.62 4.24 1.79v4.03c-1.44-.05-2.89-.35-4.2-.97c-.57-.26-1.1-.59-1.62-.93c-.01 2.92.01 5.84-.02 8.75c-.08 1.4-.54 2.79-1.35 3.94c-1.31 1.92-3.58 3.17-5.91 3.21c-1.43.08-2.86-.31-4.08-1.03c-2.02-1.19-3.44-3.37-3.65-5.71c-.02-.5-.03-1-.01-1.49c.18-1.9 1.12-3.72 2.58-4.96c1.66-1.44 3.98-2.13 6.15-1.72c.02 1.48-.04 2.96-.04 4.44c-.99-.32-2.15-.23-3.02.37c-.63.41-1.11 1.04-1.36 1.75c-.21.51-.15 1.07-.14 1.61c.24 1.64 1.82 3.02 3.5 2.87c1.12-.01 2.19-.66 2.77-1.61c.19-.33.4-.67.41-1.06c.1-1.79.06-3.57.07-5.36c.01-4.03-.01-8.05.02-12.07'/%3E%3C/svg%3E");background-color:currentColor;display:inline-block;-webkit-mask-size:100% 100%;mask-size:100% 100%;-webkit-mask-repeat:no-repeat;mask-repeat:no-repeat}.i-simple-icons-x{width:1em;height:1em;-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);mask-image:var(--svg);--svg:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' width='24' height='24'%3E%3Cpath fill='black' d='M14.234 10.162L22.977 0h-2.072l-7.591 8.824L7.251 0H.258l9.168 13.343L.258 24H2.33l8.016-9.318L16.749 24h6.993zm-2.837 3.299l-.929-1.329L3.076 1.56h3.182l5.965 8.532l.929 1.329l7.754 11.09h-3.182z'/%3E%3C/svg%3E");background-color:currentColor;display:inline-block;-webkit-mask-size:100% 100%;mask-size:100% 100%;-webkit-mask-repeat:no-repeat;mask-repeat:no-repeat}.i-svg-spinners-90-ring-with-bg{width:1em;height:1em;-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);mask-image:var(--svg);--svg:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' width='24' height='24'%3E%3Cpath fill='black' d='M12,1A11,11,0,1,0,23,12,11,11,0,0,0,12,1Zm0,19a8,8,0,1,1,8-8A8,8,0,0,1,12,20Z' opacity='.25'/%3E%3Cpath fill='black' d='M10.14,1.16a11,11,0,0,0-9,8.92A1.59,1.59,0,0,0,2.46,12,1.52,1.52,0,0,0,4.11,10.7a8,8,0,0,1,6.66-6.61A1.42,1.42,0,0,0,12,2.69h0A1.57,1.57,0,0,0,10.14,1.16Z'%3E%3CanimateTransform attributeName='transform' dur='0.75s' repeatCount='indefinite' type='rotate' values='0 12 12;360 12 12'/%3E%3C/path%3E%3C/svg%3E");background-color:currentColor;display:inline-block;-webkit-mask-size:100% 100%;mask-size:100% 100%;-webkit-mask-repeat:no-repeat;mask-repeat:no-repeat}.i-svg-spinners-ring-resize{width:1em;height:1em;-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);mask-image:var(--svg);--svg:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' width='24' height='24'%3E%3Cg stroke='black'%3E%3Ccircle cx='12' cy='12' r='9.5' fill='none' stroke-linecap='round' stroke-width='3'%3E%3Canimate attributeName='stroke-dasharray' calcMode='spline' dur='1.5s' keySplines='0.42,0,0.58,1;0.42,0,0.58,1;0.42,0,0.58,1' keyTimes='0;0.475;0.95;1' repeatCount='indefinite' values='0 150;42 150;42 150;42 150'/%3E%3Canimate attributeName='stroke-dashoffset' calcMode='spline' dur='1.5s' keySplines='0.42,0,0.58,1;0.42,0,0.58,1;0.42,0,0.58,1' keyTimes='0;0.475;0.95;1' repeatCount='indefinite' values='0;-16;-59;-59'/%3E%3C/circle%3E%3CanimateTransform attributeName='transform' dur='2s' repeatCount='indefinite' type='rotate' values='0 12 12;360 12 12'/%3E%3C/g%3E%3C/svg%3E");background-color:currentColor;display:inline-block;-webkit-mask-size:100% 100%;mask-size:100% 100%;-webkit-mask-repeat:no-repeat;mask-repeat:no-repeat}.i-tabler-alert-circle{width:1em;height:1em;-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);mask-image:var(--svg);--svg:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' width='24' height='24'%3E%3Cpath fill='none' stroke='black' stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='M3 12a9 9 0 1 0 18 0a9 9 0 0 0-18 0m9-4v4m0 4h.01'/%3E%3C/svg%3E");background-color:currentColor;display:inline-block;-webkit-mask-size:100% 100%;mask-size:100% 100%;-webkit-mask-repeat:no-repeat;mask-repeat:no-repeat}.i-tabler-arrow-right{width:1em;height:1em;-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);mask-image:var(--svg);--svg:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' width='24' height='24'%3E%3Cpath fill='none' stroke='black' stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='M5 12h14m-6 6l6-6m-6-6l6 6'/%3E%3C/svg%3E");background-color:currentColor;display:inline-block;-webkit-mask-size:100% 100%;mask-size:100% 100%;-webkit-mask-repeat:no-repeat;mask-repeat:no-repeat}.i-tabler-arrow-up{width:1em;height:1em;-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);mask-image:var(--svg);--svg:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' width='24' height='24'%3E%3Cpath fill='none' stroke='black' stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='M12 5v14m6-8l-6-6m-6 6l6-6'/%3E%3C/svg%3E");background-color:currentColor;display:inline-block;-webkit-mask-size:100% 100%;mask-size:100% 100%;-webkit-mask-repeat:no-repeat;mask-repeat:no-repeat}.i-tabler-brand-github{width:1em;height:1em;-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);mask-image:var(--svg);--svg:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' width='24' height='24'%3E%3Cpath fill='none' stroke='black' stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='M9 19c-4.3 1.4-4.3-2.5-6-3m12 5v-3.5c0-1 .1-1.4-.5-2c2.8-.3 5.5-1.4 5.5-6a4.6 4.6 0 0 0-1.3-3.2a4.2 4.2 0 0 0-.1-3.2s-1.1-.3-3.5 1.3a12.3 12.3 0 0 0-6.2 0C6.5 2.8 5.4 3.1 5.4 3.1a4.2 4.2 0 0 0-.1 3.2A4.6 4.6 0 0 0 4 9.5c0 4.6 2.7 5.7 5.5 6c-.6.6-.6 1.2-.5 2V21'/%3E%3C/svg%3E");background-color:currentColor;display:inline-block;-webkit-mask-size:100% 100%;mask-size:100% 100%;-webkit-mask-repeat:no-repeat;mask-repeat:no-repeat}.i-tabler-brand-youtube{width:1em;height:1em;-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);mask-image:var(--svg);--svg:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' width='24' height='24'%3E%3Cg fill='none' stroke='black' stroke-linecap='round' stroke-linejoin='round' stroke-width='2'%3E%3Cpath d='M2 8a4 4 0 0 1 4-4h12a4 4 0 0 1 4 4v8a4 4 0 0 1-4 4H6a4 4 0 0 1-4-4z'/%3E%3Cpath d='m10 9l5 3l-5 3z'/%3E%3C/g%3E%3C/svg%3E");background-color:currentColor;display:inline-block;-webkit-mask-size:100% 100%;mask-size:100% 100%;-webkit-mask-repeat:no-repeat;mask-repeat:no-repeat}.i-tabler-calendar{width:1em;height:1em;-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);mask-image:var(--svg);--svg:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' width='24' height='24'%3E%3Cpath fill='none' stroke='black' stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='M4 7a2 2 0 0 1 2-2h12a2 2 0 0 1 2 2v12a2 2 0 0 1-2 2H6a2 2 0 0 1-2-2zm12-4v4M8 3v4m-4 4h16m-9 4h1m0 0v3'/%3E%3C/svg%3E");background-color:currentColor;display:inline-block;-webkit-mask-size:100% 100%;mask-size:100% 100%;-webkit-mask-repeat:no-repeat;mask-repeat:no-repeat}.i-tabler-check{width:1em;height:1em;-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);mask-image:var(--svg);--svg:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' width='24' height='24'%3E%3Cpath fill='none' stroke='black' stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='m5 12l5 5L20 7'/%3E%3C/svg%3E");background-color:currentColor;display:inline-block;-webkit-mask-size:100% 100%;mask-size:100% 100%;-webkit-mask-repeat:no-repeat;mask-repeat:no-repeat}.i-tabler-chevron-down{width:1em;height:1em;-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);mask-image:var(--svg);--svg:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' width='24' height='24'%3E%3Cpath fill='none' stroke='black' stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='m6 9l6 6l6-6'/%3E%3C/svg%3E");background-color:currentColor;display:inline-block;-webkit-mask-size:100% 100%;mask-size:100% 100%;-webkit-mask-repeat:no-repeat;mask-repeat:no-repeat}.i-tabler-chevron-right{width:1em;height:1em;-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);mask-image:var(--svg);--svg:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' width='24' height='24'%3E%3Cpath fill='none' stroke='black' stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='m9 6l6 6l-6 6'/%3E%3C/svg%3E");background-color:currentColor;display:inline-block;-webkit-mask-size:100% 100%;mask-size:100% 100%;-webkit-mask-repeat:no-repeat;mask-repeat:no-repeat}.i-tabler-circle-check{width:1em;height:1em;-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);mask-image:var(--svg);--svg:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' width='24' height='24'%3E%3Cg fill='none' stroke='black' stroke-linecap='round' stroke-linejoin='round' stroke-width='2'%3E%3Cpath d='M3 12a9 9 0 1 0 18 0a9 9 0 1 0-18 0'/%3E%3Cpath d='m9 12l2 2l4-4'/%3E%3C/g%3E%3C/svg%3E");background-color:currentColor;display:inline-block;-webkit-mask-size:100% 100%;mask-size:100% 100%;-webkit-mask-repeat:no-repeat;mask-repeat:no-repeat}.i-tabler-clock{width:1em;height:1em;-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);mask-image:var(--svg);--svg:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' width='24' height='24'%3E%3Cg fill='none' stroke='black' stroke-linecap='round' stroke-linejoin='round' stroke-width='2'%3E%3Cpath d='M3 12a9 9 0 1 0 18 0a9 9 0 0 0-18 0'/%3E%3Cpath d='M12 7v5l3 3'/%3E%3C/g%3E%3C/svg%3E");background-color:currentColor;display:inline-block;-webkit-mask-size:100% 100%;mask-size:100% 100%;-webkit-mask-repeat:no-repeat;mask-repeat:no-repeat}.i-tabler-copy{width:1em;height:1em;-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);mask-image:var(--svg);--svg:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' width='24' height='24'%3E%3Cg fill='none' stroke='black' stroke-linecap='round' stroke-linejoin='round' stroke-width='2'%3E%3Cpath d='M7 9.667A2.667 2.667 0 0 1 9.667 7h8.666A2.667 2.667 0 0 1 21 9.667v8.666A2.667 2.667 0 0 1 18.333 21H9.667A2.667 2.667 0 0 1 7 18.333z'/%3E%3Cpath d='M4.012 16.737A2 2 0 0 1 3 15V5c0-1.1.9-2 2-2h10c.75 0 1.158.385 1.5 1'/%3E%3C/g%3E%3C/svg%3E");background-color:currentColor;display:inline-block;-webkit-mask-size:100% 100%;mask-size:100% 100%;-webkit-mask-repeat:no-repeat;mask-repeat:no-repeat}.i-tabler-file{width:1em;height:1em;-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);mask-image:var(--svg);--svg:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' width='24' height='24'%3E%3Cg fill='none' stroke='black' stroke-linecap='round' stroke-linejoin='round' stroke-width='2'%3E%3Cpath d='M14 3v4a1 1 0 0 0 1 1h4'/%3E%3Cpath d='M17 21H7a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2h7l5 5v11a2 2 0 0 1-2 2'/%3E%3C/g%3E%3C/svg%3E");background-color:currentColor;display:inline-block;-webkit-mask-size:100% 100%;mask-size:100% 100%;-webkit-mask-repeat:no-repeat;mask-repeat:no-repeat}.i-tabler-flag{width:1em;height:1em;-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);mask-image:var(--svg);--svg:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' width='24' height='24'%3E%3Cpath fill='none' stroke='black' stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='M5 5a5 5 0 0 1 7 0a5 5 0 0 0 7 0v9a5 5 0 0 1-7 0a5 5 0 0 0-7 0zm0 16v-7'/%3E%3C/svg%3E");background-color:currentColor;display:inline-block;-webkit-mask-size:100% 100%;mask-size:100% 100%;-webkit-mask-repeat:no-repeat;mask-repeat:no-repeat}.i-tabler-globe{width:1em;height:1em;-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);mask-image:var(--svg);--svg:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' width='24' height='24'%3E%3Cg fill='none' stroke='black' stroke-linecap='round' stroke-linejoin='round' stroke-width='2'%3E%3Cpath d='M7 9a4 4 0 1 0 8 0a4 4 0 0 0-8 0'/%3E%3Cpath d='M5.75 15A8.015 8.015 0 1 0 15 2m-4 15v4m-4 0h8'/%3E%3C/g%3E%3C/svg%3E");background-color:currentColor;display:inline-block;-webkit-mask-size:100% 100%;mask-size:100% 100%;-webkit-mask-repeat:no-repeat;mask-repeat:no-repeat}.i-tabler-info-circle{width:1em;height:1em;-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);mask-image:var(--svg);--svg:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' width='24' height='24'%3E%3Cg fill='none' stroke='black' stroke-linecap='round' stroke-linejoin='round' stroke-width='2'%3E%3Cpath d='M3 12a9 9 0 1 0 18 0a9 9 0 0 0-18 0m9-3h.01'/%3E%3Cpath d='M11 12h1v4h1'/%3E%3C/g%3E%3C/svg%3E");background-color:currentColor;display:inline-block;-webkit-mask-size:100% 100%;mask-size:100% 100%;-webkit-mask-repeat:no-repeat;mask-repeat:no-repeat}.i-tabler-link{width:1em;height:1em;-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);mask-image:var(--svg);--svg:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' width='24' height='24'%3E%3Cpath fill='none' stroke='black' stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='m9 15l6-6m-4-3l.463-.536a5 5 0 0 1 7.071 7.072L18 13m-5 5l-.397.534a5.07 5.07 0 0 1-7.127 0a4.97 4.97 0 0 1 0-7.071L6 11'/%3E%3C/svg%3E");background-color:currentColor;display:inline-block;-webkit-mask-size:100% 100%;mask-size:100% 100%;-webkit-mask-repeat:no-repeat;mask-repeat:no-repeat}.i-tabler-lock{width:1em;height:1em;-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);mask-image:var(--svg);--svg:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' width='24' height='24'%3E%3Cg fill='none' stroke='black' stroke-linecap='round' stroke-linejoin='round' stroke-width='2'%3E%3Cpath d='M5 13a2 2 0 0 1 2-2h10a2 2 0 0 1 2 2v6a2 2 0 0 1-2 2H7a2 2 0 0 1-2-2z'/%3E%3Cpath d='M11 16a1 1 0 1 0 2 0a1 1 0 0 0-2 0m-3-5V7a4 4 0 1 1 8 0v4'/%3E%3C/g%3E%3C/svg%3E");background-color:currentColor;display:inline-block;-webkit-mask-size:100% 100%;mask-size:100% 100%;-webkit-mask-repeat:no-repeat;mask-repeat:no-repeat}.i-tabler-logout{width:1em;height:1em;-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);mask-image:var(--svg);--svg:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' width='24' height='24'%3E%3Cg fill='none' stroke='black' stroke-linecap='round' stroke-linejoin='round' stroke-width='2'%3E%3Cpath d='M14 8V6a2 2 0 0 0-2-2H5a2 2 0 0 0-2 2v12a2 2 0 0 0 2 2h7a2 2 0 0 0 2-2v-2'/%3E%3Cpath d='M9 12h12l-3-3m0 6l3-3'/%3E%3C/g%3E%3C/svg%3E");background-color:currentColor;display:inline-block;-webkit-mask-size:100% 100%;mask-size:100% 100%;-webkit-mask-repeat:no-repeat;mask-repeat:no-repeat}.i-tabler-mail{width:1em;height:1em;-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);mask-image:var(--svg);--svg:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' width='24' height='24'%3E%3Cg fill='none' stroke='black' stroke-linecap='round' stroke-linejoin='round' stroke-width='2'%3E%3Cpath d='M3 7a2 2 0 0 1 2-2h14a2 2 0 0 1 2 2v10a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2z'/%3E%3Cpath d='m3 7l9 6l9-6'/%3E%3C/g%3E%3C/svg%3E");background-color:currentColor;display:inline-block;-webkit-mask-size:100% 100%;mask-size:100% 100%;-webkit-mask-repeat:no-repeat;mask-repeat:no-repeat}.i-tabler-menu{width:1em;height:1em;-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);mask-image:var(--svg);--svg:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' width='24' height='24'%3E%3Cpath fill='none' stroke='black' stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='M4 8h16M4 16h16'/%3E%3C/svg%3E");background-color:currentColor;display:inline-block;-webkit-mask-size:100% 100%;mask-size:100% 100%;-webkit-mask-repeat:no-repeat;mask-repeat:no-repeat}.i-tabler-message-circle{width:1em;height:1em;-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);mask-image:var(--svg);--svg:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' width='24' height='24'%3E%3Cpath fill='none' stroke='black' stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='m3 20l1.3-3.9C1.976 12.663 2.874 8.228 6.4 5.726c3.526-2.501 8.59-2.296 11.845.48c3.255 2.777 3.695 7.266 1.029 10.501S11.659 20.922 7.7 19z'/%3E%3C/svg%3E");background-color:currentColor;display:inline-block;-webkit-mask-size:100% 100%;mask-size:100% 100%;-webkit-mask-repeat:no-repeat;mask-repeat:no-repeat}.i-tabler-microphone{width:1em;height:1em;-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);mask-image:var(--svg);--svg:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' width='24' height='24'%3E%3Cg fill='none' stroke='black' stroke-linecap='round' stroke-linejoin='round' stroke-width='2'%3E%3Cpath d='M9 5a3 3 0 0 1 3-3a3 3 0 0 1 3 3v5a3 3 0 0 1-3 3a3 3 0 0 1-3-3z'/%3E%3Cpath d='M5 10a7 7 0 0 0 14 0M8 21h8m-4-4v4'/%3E%3C/g%3E%3C/svg%3E");background-color:currentColor;display:inline-block;-webkit-mask-size:100% 100%;mask-size:100% 100%;-webkit-mask-repeat:no-repeat;mask-repeat:no-repeat}.i-tabler-microphone-filled{width:1em;height:1em;-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);mask-image:var(--svg);--svg:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' width='24' height='24'%3E%3Cpath fill='black' d='M19 9a1 1 0 0 1 1 1a8 8 0 0 1-6.999 7.938L13 20h3a1 1 0 0 1 0 2H8a1 1 0 0 1 0-2h3v-2.062A8 8 0 0 1 4 10a1 1 0 1 1 2 0a6 6 0 0 0 12 0a1 1 0 0 1 1-1m-7-8a4 4 0 0 1 4 4v5a4 4 0 1 1-8 0V5a4 4 0 0 1 4-4'/%3E%3C/svg%3E");background-color:currentColor;display:inline-block;-webkit-mask-size:100% 100%;mask-size:100% 100%;-webkit-mask-repeat:no-repeat;mask-repeat:no-repeat}.i-tabler-microphone-off{width:1em;height:1em;-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);mask-image:var(--svg);--svg:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' width='24' height='24'%3E%3Cg fill='none' stroke='black' stroke-linecap='round' stroke-linejoin='round' stroke-width='2'%3E%3Cpath d='m3 3l18 18M9 5a3 3 0 0 1 6 0v5a3 3 0 0 1-.13.874m-2 2A3 3 0 0 1 9 10.002v-1'/%3E%3Cpath d='M5 10a7 7 0 0 0 10.846 5.85m2-2A6.97 6.97 0 0 0 18.998 10M8 21h8m-4-4v4'/%3E%3C/g%3E%3C/svg%3E");background-color:currentColor;display:inline-block;-webkit-mask-size:100% 100%;mask-size:100% 100%;-webkit-mask-repeat:no-repeat;mask-repeat:no-repeat}.i-tabler-phone{width:1em;height:1em;-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);mask-image:var(--svg);--svg:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' width='24' height='24'%3E%3Cpath fill='none' stroke='black' stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='M5 4h4l2 5l-2.5 1.5a11 11 0 0 0 5 5L15 13l5 2v4a2 2 0 0 1-2 2A16 16 0 0 1 3 6a2 2 0 0 1 2-2'/%3E%3C/svg%3E");background-color:currentColor;display:inline-block;-webkit-mask-size:100% 100%;mask-size:100% 100%;-webkit-mask-repeat:no-repeat;mask-repeat:no-repeat}.i-tabler-phone-off{width:1em;height:1em;-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);mask-image:var(--svg);--svg:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' width='24' height='24'%3E%3Cpath fill='none' stroke='black' stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='M3 21L21 3M5.831 14.161A15.95 15.95 0 0 1 3 6a2 2 0 0 1 2-2h4l2 5l-2.5 1.5q.162.33.345.645m1.751 2.277A11 11 0 0 0 13.5 15.5L15 13l5 2v4a2 2 0 0 1-2 2a15.96 15.96 0 0 1-10.344-4.657'/%3E%3C/svg%3E");background-color:currentColor;display:inline-block;-webkit-mask-size:100% 100%;mask-size:100% 100%;-webkit-mask-repeat:no-repeat;mask-repeat:no-repeat}.i-tabler-player-stop-filled{width:1em;height:1em;-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);mask-image:var(--svg);--svg:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' width='24' height='24'%3E%3Cpath fill='black' d='M17 4H7a3 3 0 0 0-3 3v10a3 3 0 0 0 3 3h10a3 3 0 0 0 3-3V7a3 3 0 0 0-3-3'/%3E%3C/svg%3E");background-color:currentColor;display:inline-block;-webkit-mask-size:100% 100%;mask-size:100% 100%;-webkit-mask-repeat:no-repeat;mask-repeat:no-repeat}.i-tabler-plus{width:1em;height:1em;-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);mask-image:var(--svg);--svg:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' width='24' height='24'%3E%3Cpath fill='none' stroke='black' stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='M12 5v14m-7-7h14'/%3E%3C/svg%3E");background-color:currentColor;display:inline-block;-webkit-mask-size:100% 100%;mask-size:100% 100%;-webkit-mask-repeat:no-repeat;mask-repeat:no-repeat}.i-tabler-share{width:1em;height:1em;-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);mask-image:var(--svg);--svg:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' width='24' height='24'%3E%3Cpath fill='none' stroke='black' stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='M3 12a3 3 0 1 0 6 0a3 3 0 1 0-6 0m12-6a3 3 0 1 0 6 0a3 3 0 1 0-6 0m0 12a3 3 0 1 0 6 0a3 3 0 1 0-6 0m-6.3-7.3l6.6-3.4m-6.6 6l6.6 3.4'/%3E%3C/svg%3E");background-color:currentColor;display:inline-block;-webkit-mask-size:100% 100%;mask-size:100% 100%;-webkit-mask-repeat:no-repeat;mask-repeat:no-repeat}.i-tabler-share-2{width:1em;height:1em;-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);mask-image:var(--svg);--svg:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' width='24' height='24'%3E%3Cpath fill='none' stroke='black' stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='M8 9H7a2 2 0 0 0-2 2v8a2 2 0 0 0 2 2h10a2 2 0 0 0 2-2v-8a2 2 0 0 0-2-2h-1m-4 5V3M9 6l3-3l3 3'/%3E%3C/svg%3E");background-color:currentColor;display:inline-block;-webkit-mask-size:100% 100%;mask-size:100% 100%;-webkit-mask-repeat:no-repeat;mask-repeat:no-repeat}.i-tabler-sparkles{width:1em;height:1em;-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);mask-image:var(--svg);--svg:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' width='24' height='24'%3E%3Cpath fill='none' stroke='black' stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='M16 18a2 2 0 0 1 2 2a2 2 0 0 1 2-2a2 2 0 0 1-2-2a2 2 0 0 1-2 2m0-12a2 2 0 0 1 2 2a2 2 0 0 1 2-2a2 2 0 0 1-2-2a2 2 0 0 1-2 2M9 18a6 6 0 0 1 6-6a6 6 0 0 1-6-6a6 6 0 0 1-6 6a6 6 0 0 1 6 6'/%3E%3C/svg%3E");background-color:currentColor;display:inline-block;-webkit-mask-size:100% 100%;mask-size:100% 100%;-webkit-mask-repeat:no-repeat;mask-repeat:no-repeat}.i-tabler-tool{width:1em;height:1em;-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);mask-image:var(--svg);--svg:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' width='24' height='24'%3E%3Cpath fill='none' stroke='black' stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='M7 10h3V7L6.5 3.5a6 6 0 0 1 8 8l6 6a2 2 0 0 1-3 3l-6-6a6 6 0 0 1-8-8z'/%3E%3C/svg%3E");background-color:currentColor;display:inline-block;-webkit-mask-size:100% 100%;mask-size:100% 100%;-webkit-mask-repeat:no-repeat;mask-repeat:no-repeat}.i-tabler-trash{width:1em;height:1em;-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);mask-image:var(--svg);--svg:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' width='24' height='24'%3E%3Cpath fill='none' stroke='black' stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='M4 7h16m-10 4v6m4-6v6M5 7l1 12a2 2 0 0 0 2 2h8a2 2 0 0 0 2-2l1-12M9 7V4a1 1 0 0 1 1-1h4a1 1 0 0 1 1 1v3'/%3E%3C/svg%3E");background-color:currentColor;display:inline-block;-webkit-mask-size:100% 100%;mask-size:100% 100%;-webkit-mask-repeat:no-repeat;mask-repeat:no-repeat}.i-tabler-user{width:1em;height:1em;-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);mask-image:var(--svg);--svg:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' width='24' height='24'%3E%3Cpath fill='none' stroke='black' stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='M8 7a4 4 0 1 0 8 0a4 4 0 0 0-8 0M6 21v-2a4 4 0 0 1 4-4h4a4 4 0 0 1 4 4v2'/%3E%3C/svg%3E");background-color:currentColor;display:inline-block;-webkit-mask-size:100% 100%;mask-size:100% 100%;-webkit-mask-repeat:no-repeat;mask-repeat:no-repeat}.i-tabler-user-circle{width:1em;height:1em;-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);mask-image:var(--svg);--svg:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' width='24' height='24'%3E%3Cg fill='none' stroke='black' stroke-linecap='round' stroke-linejoin='round' stroke-width='2'%3E%3Cpath d='M3 12a9 9 0 1 0 18 0a9 9 0 1 0-18 0'/%3E%3Cpath d='M9 10a3 3 0 1 0 6 0a3 3 0 1 0-6 0m-2.832 8.849A4 4 0 0 1 10 16h4a4 4 0 0 1 3.834 2.855'/%3E%3C/g%3E%3C/svg%3E");background-color:currentColor;display:inline-block;-webkit-mask-size:100% 100%;mask-size:100% 100%;-webkit-mask-repeat:no-repeat;mask-repeat:no-repeat}.i-tabler-user-square-rounded{width:1em;height:1em;-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);mask-image:var(--svg);--svg:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' width='24' height='24'%3E%3Cg fill='none' stroke='black' stroke-linecap='round' stroke-linejoin='round' stroke-width='2'%3E%3Cpath d='M12 13a3 3 0 1 0 0-6a3 3 0 0 0 0 6'/%3E%3Cpath d='M12 3c7.2 0 9 1.8 9 9s-1.8 9-9 9s-9-1.8-9-9s1.8-9 9-9'/%3E%3Cpath d='M6 20.05V20a4 4 0 0 1 4-4h4a4 4 0 0 1 4 4v.05'/%3E%3C/g%3E%3C/svg%3E");background-color:currentColor;display:inline-block;-webkit-mask-size:100% 100%;mask-size:100% 100%;-webkit-mask-repeat:no-repeat;mask-repeat:no-repeat}.i-tabler-users{width:1em;height:1em;-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);mask-image:var(--svg);--svg:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' width='24' height='24'%3E%3Cpath fill='none' stroke='black' stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='M5 7a4 4 0 1 0 8 0a4 4 0 1 0-8 0M3 21v-2a4 4 0 0 1 4-4h4a4 4 0 0 1 4 4v2m1-17.87a4 4 0 0 1 0 7.75M21 21v-2a4 4 0 0 0-3-3.85'/%3E%3C/svg%3E");background-color:currentColor;display:inline-block;-webkit-mask-size:100% 100%;mask-size:100% 100%;-webkit-mask-repeat:no-repeat;mask-repeat:no-repeat}.i-tabler-world{width:1em;height:1em;-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);mask-image:var(--svg);--svg:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' width='24' height='24'%3E%3Cg fill='none' stroke='black' stroke-linecap='round' stroke-linejoin='round' stroke-width='2'%3E%3Cpath d='M3 12a9 9 0 1 0 18 0a9 9 0 0 0-18 0m.6-3h16.8M3.6 15h16.8'/%3E%3Cpath d='M11.5 3a17 17 0 0 0 0 18m1-18a17 17 0 0 1 0 18'/%3E%3C/g%3E%3C/svg%3E");background-color:currentColor;display:inline-block;-webkit-mask-size:100% 100%;mask-size:100% 100%;-webkit-mask-repeat:no-repeat;mask-repeat:no-repeat}.i-tabler-x{width:1em;height:1em;-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);-webkit-mask-image:var(--svg);mask-image:var(--svg);--svg:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' width='24' height='24'%3E%3Cpath fill='none' stroke='black' stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='M18 6L6 18M6 6l12 12'/%3E%3C/svg%3E");background-color:currentColor;display:inline-block;-webkit-mask-size:100% 100%;mask-size:100% 100%;-webkit-mask-repeat:no-repeat;mask-repeat:no-repeat}.line-clamp-1{-webkit-line-clamp:1;-webkit-box-orient:vertical;display:-webkit-box;overflow:hidden}.line-clamp-2{-webkit-line-clamp:2;-webkit-box-orient:vertical;display:-webkit-box;overflow:hidden}.block{display:block}.flex{display:flex}.grid{display:grid}.hidden{display:none}.inline{display:inline}.inline-flex{display:inline-flex}.table{display:table}.size-1\\.5{width:calc(var(--spacing) * 1.5);height:calc(var(--spacing) * 1.5)}.size-2{width:calc(var(--spacing) * 2);height:calc(var(--spacing) * 2)}.size-2\\.5{width:calc(var(--spacing) * 2.5);height:calc(var(--spacing) * 2.5)}.size-3{width:calc(var(--spacing) * 3);height:calc(var(--spacing) * 3)}.size-3\\.5{width:calc(var(--spacing) * 3.5);height:calc(var(--spacing) * 3.5)}.size-4{width:calc(var(--spacing) * 4);height:calc(var(--spacing) * 4)}.size-5{width:calc(var(--spacing) * 5);height:calc(var(--spacing) * 5)}.size-6{width:calc(var(--spacing) * 6);height:calc(var(--spacing) * 6)}.size-7{width:calc(var(--spacing) * 7);height:calc(var(--spacing) * 7)}.size-8{width:calc(var(--spacing) * 8);height:calc(var(--spacing) * 8)}.size-9{width:calc(var(--spacing) * 9);height:calc(var(--spacing) * 9)}.size-10{width:calc(var(--spacing) * 10);height:calc(var(--spacing) * 10)}.size-12{width:calc(var(--spacing) * 12);height:calc(var(--spacing) * 12)}.size-14{width:calc(var(--spacing) * 14);height:calc(var(--spacing) * 14)}.size-16{width:calc(var(--spacing) * 16);height:calc(var(--spacing) * 16)}.size-20{width:calc(var(--spacing) * 20);height:calc(var(--spacing) * 20)}.size-32{width:calc(var(--spacing) * 32);height:calc(var(--spacing) * 32)}.size-\\[1\\.1em\\]{width:1.1em;height:1.1em}.size-\\[9px\\]{width:9px;height:9px}.size-\\[13px\\]{width:13px;height:13px}.size-\\[15px\\]{width:15px;height:15px}.size-\\[17px\\]{width:17px;height:17px}.size-\\[18px\\]{width:18px;height:18px}.size-\\[25px\\]{width:25px;height:25px}.size-\\[36\\%\\]{width:36%;height:36%}.size-full{width:100%;height:100%}.h-1\\.5{height:calc(var(--spacing) * 1.5)}.h-2{height:calc(var(--spacing) * 2)}.h-4{height:calc(var(--spacing) * 4)}.h-10{height:calc(var(--spacing) * 10)}.h-11{height:calc(var(--spacing) * 11)}.h-14{height:calc(var(--spacing) * 14)}.h-16{height:calc(var(--spacing) * 16)}.h-20{height:calc(var(--spacing) * 20)}.h-\\[17px\\]{height:17px}.h-\\[28px\\]{height:28px}.h-\\[38px\\]{height:38px}.h-\\[60px\\]{height:60px}.h-\\[80px\\]{height:80px}.h-\\[80vh\\]{height:80vh}.h-\\[600px\\]{height:600px}.h-\\[min\\(600px\\,calc\\(100vh-4rem\\)\\)\\]{height:min(600px,100vh - 4rem)}.h-auto{height:auto}.h-dvh{height:100dvh}.h-full{height:100%}.h-px{height:1px}.max-h-48{max-height:calc(var(--spacing) * 48)}.max-h-\\[300px\\]{max-height:300px}.max-h-\\[calc\\(100vh-48px\\)\\]{max-height:calc(100vh - 48px)}.min-h-0{min-height:0}.min-h-5{min-height:calc(var(--spacing) * 5)}.min-h-11{min-height:calc(var(--spacing) * 11)}.min-h-\\[20px\\]{min-height:20px}.min-h-full{min-height:100%}.w-0{width:0}.w-5{width:calc(var(--spacing) * 5)}.w-16{width:calc(var(--spacing) * 16)}.w-20{width:calc(var(--spacing) * 20)}.w-96{width:calc(var(--spacing) * 96)}.w-\\[2px\\]{width:2px}.w-\\[3px\\]{width:3px}.w-\\[5px\\]{width:5px}.w-\\[28px\\]{width:28px}.w-\\[46ch\\]{width:46ch}.w-\\[60px\\]{width:60px}.w-\\[80\\%\\]{width:80%}.w-\\[80px\\]{width:80px}.w-\\[min\\(400px\\,calc\\(100vw-2rem\\)\\)\\]{width:min(400px,100vw - 2rem)}.w-fit{width:-moz-fit-content;width:fit-content}.w-full{width:100%}.w-px{width:1px}.max-w-4xl{max-width:var(--container-4xl)}.max-w-20{max-width:calc(var(--spacing) * 20)}.max-w-\\[85\\%\\]{max-width:85%}.max-w-\\[88\\%\\]{max-width:88%}.max-w-\\[240px\\]{max-width:240px}.max-w-\\[255px\\]{max-width:255px}.max-w-\\[260px\\]{max-width:260px}.max-w-\\[300px\\]{max-width:300px}.max-w-\\[480px\\]{max-width:480px}.max-w-\\[640px\\]{max-width:640px}.max-w-\\[900px\\]{max-width:900px}.max-w-\\[calc\\(100vw-48px\\)\\]{max-width:calc(100vw - 48px)}.max-w-full{max-width:100%}.max-w-md{max-width:var(--container-md)}.max-w-screen-md{max-width:var(--breakpoint-md)}.max-w-sm{max-width:var(--container-sm)}.max-w-xs{max-width:var(--container-xs)}.min-w-0{min-width:0}.flex-1{flex:1}.flex-none{flex:none}.flex-shrink-0,.shrink-0{flex-shrink:0}.flex-grow-0{flex-grow:0}.grow{flex-grow:1}.basis-0{flex-basis:0}.origin-center{transform-origin:50%}.-translate-x-1\\/2{--tw-translate-x:calc(calc(1 / 2 * 100%) * -1);translate:var(--tw-translate-x) var(--tw-translate-y)}.-translate-x-4{--tw-translate-x:calc(var(--spacing) * -4);translate:var(--tw-translate-x) var(--tw-translate-y)}.-translate-x-\\[30px\\]{--tw-translate-x:calc(30px * -1);translate:var(--tw-translate-x) var(--tw-translate-y)}.-translate-x-full{--tw-translate-x:-100%;translate:var(--tw-translate-x) var(--tw-translate-y)}.translate-x-0{--tw-translate-x:0px;translate:var(--tw-translate-x) var(--tw-translate-y)}.translate-x-4{--tw-translate-x:calc(var(--spacing) * 4);translate:var(--tw-translate-x) var(--tw-translate-y)}.translate-x-full{--tw-translate-x:100%;translate:var(--tw-translate-x) var(--tw-translate-y)}.-translate-y-1\\/2{--tw-translate-y:calc(calc(1 / 2 * 100%) * -1);translate:var(--tw-translate-x) var(--tw-translate-y)}.-translate-y-\\[30px\\]{--tw-translate-y:calc(30px * -1);translate:var(--tw-translate-x) var(--tw-translate-y)}.translate-y-0{--tw-translate-y:0px;translate:var(--tw-translate-x) var(--tw-translate-y)}.translate-y-2{--tw-translate-y:calc(var(--spacing) * 2);translate:var(--tw-translate-x) var(--tw-translate-y)}.translate-y-\\[30px\\]{--tw-translate-y:30px;translate:var(--tw-translate-x) var(--tw-translate-y)}.translate-y-full{--tw-translate-y:100%;translate:var(--tw-translate-x) var(--tw-translate-y)}.scale-0{--tw-scale-x:0%;--tw-scale-y:0%;--tw-scale-z:0%;scale:var(--tw-scale-x) var(--tw-scale-y)}.scale-75{--tw-scale-x:75%;--tw-scale-y:75%;--tw-scale-z:75%;scale:var(--tw-scale-x) var(--tw-scale-y)}.scale-95{--tw-scale-x:95%;--tw-scale-y:95%;--tw-scale-z:95%;scale:var(--tw-scale-x) var(--tw-scale-y)}.scale-100{--tw-scale-x:100%;--tw-scale-y:100%;--tw-scale-z:100%;scale:var(--tw-scale-x) var(--tw-scale-y)}.scale-110{--tw-scale-x:110%;--tw-scale-y:110%;--tw-scale-z:110%;scale:var(--tw-scale-x) var(--tw-scale-y)}.-rotate-45{rotate:-45deg}.rotate-0{rotate:0deg}.rotate-45{rotate:45deg}.transform{transform:var(--tw-rotate-x, ) var(--tw-rotate-y, ) var(--tw-rotate-z, ) var(--tw-skew-x, ) var(--tw-skew-y, )}.transform-gpu{transform:translateZ(0) var(--tw-rotate-x, ) var(--tw-rotate-y, ) var(--tw-rotate-z, ) var(--tw-skew-x, ) var(--tw-skew-y, )}.animate-ping{animation:var(--animate-ping)}.animate-pulse{animation:var(--animate-pulse)}.animate-spin{animation:var(--animate-spin)}.cursor-default{cursor:default}.cursor-not-allowed{cursor:not-allowed}.cursor-pointer{cursor:pointer}.cursor-text{cursor:text}.resize{resize:both}.\\[scrollbar-width\\:none\\]{scrollbar-width:none}.grid-cols-2{grid-template-columns:repeat(2,minmax(0,1fr))}.flex-col{flex-direction:column}.flex-row{flex-direction:row}.flex-wrap{flex-wrap:wrap}.place-items-center{place-items:center}.items-baseline{align-items:baseline}.items-center{align-items:center}.items-end{align-items:flex-end}.items-start{align-items:flex-start}.items-stretch{align-items:stretch}.\\[justify-content\\:safe_center\\]{justify-content:safe center}.justify-between{justify-content:space-between}.justify-center{justify-content:center}.justify-end{justify-content:flex-end}.justify-start{justify-content:flex-start}.justify-stretch{justify-content:stretch}.gap-0\\.5{gap:calc(var(--spacing) * .5)}.gap-1{gap:var(--spacing)}.gap-1\\.5{gap:calc(var(--spacing) * 1.5)}.gap-2{gap:calc(var(--spacing) * 2)}.gap-2\\.5{gap:calc(var(--spacing) * 2.5)}.gap-3{gap:calc(var(--spacing) * 3)}.gap-4{gap:calc(var(--spacing) * 4)}.gap-7{gap:calc(var(--spacing) * 7)}.gap-\\[2px\\]{gap:2px}.gap-\\[5px\\]{gap:5px}:where(.space-y-1>:not(:last-child)){--tw-space-y-reverse:0;margin-block-start:calc(var(--spacing) * var(--tw-space-y-reverse));margin-block-end:calc(var(--spacing) * calc(1 - var(--tw-space-y-reverse)))}:where(.space-y-2>:not(:last-child)){--tw-space-y-reverse:0;margin-block-start:calc(calc(var(--spacing) * 2) * var(--tw-space-y-reverse));margin-block-end:calc(calc(var(--spacing) * 2) * calc(1 - var(--tw-space-y-reverse)))}:where(.space-y-3>:not(:last-child)){--tw-space-y-reverse:0;margin-block-start:calc(calc(var(--spacing) * 3) * var(--tw-space-y-reverse));margin-block-end:calc(calc(var(--spacing) * 3) * calc(1 - var(--tw-space-y-reverse)))}:where(.space-y-4>:not(:last-child)){--tw-space-y-reverse:0;margin-block-start:calc(calc(var(--spacing) * 4) * var(--tw-space-y-reverse));margin-block-end:calc(calc(var(--spacing) * 4) * calc(1 - var(--tw-space-y-reverse)))}:where(.space-y-6>:not(:last-child)){--tw-space-y-reverse:0;margin-block-start:calc(calc(var(--spacing) * 6) * var(--tw-space-y-reverse));margin-block-end:calc(calc(var(--spacing) * 6) * calc(1 - var(--tw-space-y-reverse)))}:where(.space-y-12>:not(:last-child)){--tw-space-y-reverse:0;margin-block-start:calc(calc(var(--spacing) * 12) * var(--tw-space-y-reverse));margin-block-end:calc(calc(var(--spacing) * 12) * calc(1 - var(--tw-space-y-reverse)))}.gap-x-2{column-gap:calc(var(--spacing) * 2)}.gap-x-2\\.5{column-gap:calc(var(--spacing) * 2.5)}.gap-x-4{column-gap:calc(var(--spacing) * 4)}.gap-y-1\\.5{row-gap:calc(var(--spacing) * 1.5)}.self-end{align-self:flex-end}.self-start{align-self:flex-start}.self-stretch{align-self:stretch}.truncate{text-overflow:ellipsis;white-space:nowrap;overflow:hidden}.overflow-hidden{overflow:hidden}.overflow-scroll{overflow:scroll}.overflow-visible{overflow:visible}.overflow-x-auto{overflow-x:auto}.overflow-x-hidden{overflow-x:hidden}.overflow-y-auto{overflow-y:auto}.overscroll-contain{overscroll-behavior:contain}.rounded-2xl{border-radius:var(--radius-2xl)}.rounded-3xl{border-radius:var(--radius-3xl)}.rounded-\\[2px\\]{border-radius:2px}.rounded-\\[5px\\]{border-radius:5px}.rounded-\\[14px\\]{border-radius:14px}.rounded-\\[20px\\]{border-radius:20px}.rounded-full{border-radius:2147483647px}.rounded-lg{border-radius:var(--radius-lg)}.rounded-xl{border-radius:var(--radius-xl)}.border{border-style:var(--tw-border-style);border-width:1px}.border-2{border-style:var(--tw-border-style);border-width:2px}.border-4{border-style:var(--tw-border-style);border-width:4px}.border-t{border-top-style:var(--tw-border-style);border-top-width:1px}.border-b{border-bottom-style:var(--tw-border-style);border-bottom-width:1px}.border-b-2{border-bottom-style:var(--tw-border-style);border-bottom-width:2px}.border-l{border-left-style:var(--tw-border-style);border-left-width:1px}.border-dashed{--tw-border-style:dashed;border-style:dashed}.border-black\\/10{border-color:#0000001a}@supports (color:color-mix(in lab, red, red)){.border-black\\/10{border-color:color-mix(in oklab, var(--color-black) 10%, transparent)}}.border-green-400{border-color:var(--color-green-400)}.border-primary-400{border-color:var(--color-primary-400)}.border-primary-500\\/40{border-color:var(--color-primary-500)}@supports (color:color-mix(in lab, red, red)){.border-primary-500\\/40{border-color:color-mix(in oklab, var(--color-primary-500) 40%, transparent)}}.border-red-400{border-color:var(--color-red-400)}.border-slate-200{border-color:var(--color-slate-200)}.border-theme-100{border-color:var(--color-theme-100)}.border-theme-200{border-color:var(--color-theme-200)}.border-theme-300{border-color:var(--color-theme-300)}.border-theme-400{border-color:var(--color-theme-400)}.border-theme-950\\/\\[0\\.06\\]{border-color:var(--color-theme-950)}@supports (color:color-mix(in lab, red, red)){.border-theme-950\\/\\[0\\.06\\]{border-color:color-mix(in oklab, var(--color-theme-950) 6%, transparent)}}.border-transparent{border-color:#0000}.border-white{border-color:var(--color-white)}.border-white\\/0{border-color:#0000}@supports (color:color-mix(in lab, red, red)){.border-white\\/0{border-color:color-mix(in oklab, var(--color-white) 0%, transparent)}}.border-white\\/10{border-color:#ffffff1a}@supports (color:color-mix(in lab, red, red)){.border-white\\/10{border-color:color-mix(in oklab, var(--color-white) 10%, transparent)}}.border-white\\/20{border-color:#fff3}@supports (color:color-mix(in lab, red, red)){.border-white\\/20{border-color:color-mix(in oklab, var(--color-white) 20%, transparent)}}.border-white\\/25{border-color:#ffffff40}@supports (color:color-mix(in lab, red, red)){.border-white\\/25{border-color:color-mix(in oklab, var(--color-white) 25%, transparent)}}.border-t-primary-500{border-top-color:var(--color-primary-500)}.bg-\\[\\#0A1522\\]{background-color:#0a1522}.bg-\\[\\#050F19\\]{background-color:#050f19}.bg-amber-500{background-color:var(--color-amber-500)}.bg-black\\/30{background-color:#0000004d}@supports (color:color-mix(in lab, red, red)){.bg-black\\/30{background-color:color-mix(in oklab, var(--color-black) 30%, transparent)}}.bg-black\\/50{background-color:#00000080}@supports (color:color-mix(in lab, red, red)){.bg-black\\/50{background-color:color-mix(in oklab, var(--color-black) 50%, transparent)}}.bg-current{background-color:currentColor}.bg-green-500{background-color:var(--color-green-500)}.bg-green-600{background-color:var(--color-green-600)}.bg-primary-500,.bg-primary-500\\/20{background-color:var(--color-primary-500)}@supports (color:color-mix(in lab, red, red)){.bg-primary-500\\/20{background-color:color-mix(in oklab, var(--color-primary-500) 20%, transparent)}}.bg-primary-600{background-color:var(--color-primary-600)}.bg-red-500{background-color:var(--color-red-500)}.bg-red-500\\/20{background-color:#fb2c3633}@supports (color:color-mix(in lab, red, red)){.bg-red-500\\/20{background-color:color-mix(in oklab, var(--color-red-500) 20%, transparent)}}.bg-red-600{background-color:var(--color-red-600)}.bg-slate-950{background-color:var(--color-slate-950)}.bg-theme-0{background-color:var(--color-theme-0)}.bg-theme-25{background-color:var(--color-theme-25)}.bg-theme-50{background-color:var(--color-theme-50)}.bg-theme-100{background-color:var(--color-theme-100)}.bg-theme-200,.bg-theme-200\\/70{background-color:var(--color-theme-200)}@supports (color:color-mix(in lab, red, red)){.bg-theme-200\\/70{background-color:color-mix(in oklab, var(--color-theme-200) 70%, transparent)}}.bg-theme-300{background-color:var(--color-theme-300)}.bg-theme-400{background-color:var(--color-theme-400)}.bg-theme-800,.bg-theme-800\\/60{background-color:var(--color-theme-800)}@supports (color:color-mix(in lab, red, red)){.bg-theme-800\\/60{background-color:color-mix(in oklab, var(--color-theme-800) 60%, transparent)}}.bg-theme-900{background-color:var(--color-theme-900)}.bg-transparent{background-color:#0000}.bg-white{background-color:var(--color-white)}.bg-white\\/5{background-color:#ffffff0d}@supports (color:color-mix(in lab, red, red)){.bg-white\\/5{background-color:color-mix(in oklab, var(--color-white) 5%, transparent)}}.bg-white\\/10{background-color:#ffffff1a}@supports (color:color-mix(in lab, red, red)){.bg-white\\/10{background-color:color-mix(in oklab, var(--color-white) 10%, transparent)}}.bg-white\\/15{background-color:#ffffff26}@supports (color:color-mix(in lab, red, red)){.bg-white\\/15{background-color:color-mix(in oklab, var(--color-white) 15%, transparent)}}.bg-white\\/50{background-color:#ffffff80}@supports (color:color-mix(in lab, red, red)){.bg-white\\/50{background-color:color-mix(in oklab, var(--color-white) 50%, transparent)}}.bg-gradient-to-b{--tw-gradient-position:to bottom in oklab;background-image:linear-gradient(var(--tw-gradient-stops))}.bg-gradient-to-br{--tw-gradient-position:to bottom right in oklab;background-image:linear-gradient(var(--tw-gradient-stops))}.bg-gradient-to-t{--tw-gradient-position:to top in oklab;background-image:linear-gradient(var(--tw-gradient-stops))}.from-\\[\\#050F19\\]\\/82{--tw-gradient-from:#050f19d1;--tw-gradient-stops:var(--tw-gradient-via-stops,var(--tw-gradient-position), var(--tw-gradient-from) var(--tw-gradient-from-position), var(--tw-gradient-to) var(--tw-gradient-to-position))}@supports (color:color(display-p3 0 0 0)){.from-\\[\\#050F19\\]\\/82{--tw-gradient-from:color(display-p3 .0270841 .0577423 .0947219/.82)}}@supports (color:lab(0% 0 0)){.from-\\[\\#050F19\\]\\/82{--tw-gradient-from:lab(3.9307% -1.22581 -7.24003/.82)}}.from-black\\/70{--tw-gradient-from:#000000b3}@supports (color:color-mix(in lab, red, red)){.from-black\\/70{--tw-gradient-from:color-mix(in oklab, var(--color-black) 70%, transparent)}}.from-black\\/70{--tw-gradient-stops:var(--tw-gradient-via-stops,var(--tw-gradient-position), var(--tw-gradient-from) var(--tw-gradient-from-position), var(--tw-gradient-to) var(--tw-gradient-to-position))}.from-black\\/80{--tw-gradient-from:#000c}@supports (color:color-mix(in lab, red, red)){.from-black\\/80{--tw-gradient-from:color-mix(in oklab, var(--color-black) 80%, transparent)}}.from-black\\/80{--tw-gradient-stops:var(--tw-gradient-via-stops,var(--tw-gradient-position), var(--tw-gradient-from) var(--tw-gradient-from-position), var(--tw-gradient-to) var(--tw-gradient-to-position))}.from-black\\/90{--tw-gradient-from:#000000e6}@supports (color:color-mix(in lab, red, red)){.from-black\\/90{--tw-gradient-from:color-mix(in oklab, var(--color-black) 90%, transparent)}}.from-black\\/90{--tw-gradient-stops:var(--tw-gradient-via-stops,var(--tw-gradient-position), var(--tw-gradient-from) var(--tw-gradient-from-position), var(--tw-gradient-to) var(--tw-gradient-to-position))}.from-theme-25{--tw-gradient-from:var(--color-theme-25);--tw-gradient-stops:var(--tw-gradient-via-stops,var(--tw-gradient-position), var(--tw-gradient-from) var(--tw-gradient-from-position), var(--tw-gradient-to) var(--tw-gradient-to-position))}.from-theme-800{--tw-gradient-from:var(--color-theme-800);--tw-gradient-stops:var(--tw-gradient-via-stops,var(--tw-gradient-position), var(--tw-gradient-from) var(--tw-gradient-from-position), var(--tw-gradient-to) var(--tw-gradient-to-position))}.from-transparent{--tw-gradient-from:transparent;--tw-gradient-stops:var(--tw-gradient-via-stops,var(--tw-gradient-position), var(--tw-gradient-from) var(--tw-gradient-from-position), var(--tw-gradient-to) var(--tw-gradient-to-position))}.via-\\[\\#050F19\\]\\/90{--tw-gradient-via:#050f19e6;--tw-gradient-via-stops:var(--tw-gradient-position), var(--tw-gradient-from) var(--tw-gradient-from-position), var(--tw-gradient-via) var(--tw-gradient-via-position), var(--tw-gradient-to) var(--tw-gradient-to-position);--tw-gradient-stops:var(--tw-gradient-via-stops)}@supports (color:color(display-p3 0 0 0)){.via-\\[\\#050F19\\]\\/90{--tw-gradient-via:color(display-p3 .0270841 .0577423 .0947219/.9)}}@supports (color:lab(0% 0 0)){.via-\\[\\#050F19\\]\\/90{--tw-gradient-via:lab(3.9307% -1.22581 -7.24003/.9)}}.via-black\\/10{--tw-gradient-via:#0000001a}@supports (color:color-mix(in lab, red, red)){.via-black\\/10{--tw-gradient-via:color-mix(in oklab, var(--color-black) 10%, transparent)}}.via-black\\/10{--tw-gradient-via-stops:var(--tw-gradient-position), var(--tw-gradient-from) var(--tw-gradient-from-position), var(--tw-gradient-via) var(--tw-gradient-via-position), var(--tw-gradient-to) var(--tw-gradient-to-position);--tw-gradient-stops:var(--tw-gradient-via-stops)}.via-black\\/50{--tw-gradient-via:#00000080}@supports (color:color-mix(in lab, red, red)){.via-black\\/50{--tw-gradient-via:color-mix(in oklab, var(--color-black) 50%, transparent)}}.via-black\\/50{--tw-gradient-via-stops:var(--tw-gradient-position), var(--tw-gradient-from) var(--tw-gradient-from-position), var(--tw-gradient-via) var(--tw-gradient-via-position), var(--tw-gradient-to) var(--tw-gradient-to-position);--tw-gradient-stops:var(--tw-gradient-via-stops)}.via-black\\/60{--tw-gradient-via:#0009}@supports (color:color-mix(in lab, red, red)){.via-black\\/60{--tw-gradient-via:color-mix(in oklab, var(--color-black) 60%, transparent)}}.via-black\\/60{--tw-gradient-via-stops:var(--tw-gradient-position), var(--tw-gradient-from) var(--tw-gradient-from-position), var(--tw-gradient-via) var(--tw-gradient-via-position), var(--tw-gradient-to) var(--tw-gradient-to-position);--tw-gradient-stops:var(--tw-gradient-via-stops)}.via-black\\/90{--tw-gradient-via:#000000e6}@supports (color:color-mix(in lab, red, red)){.via-black\\/90{--tw-gradient-via:color-mix(in oklab, var(--color-black) 90%, transparent)}}.via-black\\/90{--tw-gradient-via-stops:var(--tw-gradient-position), var(--tw-gradient-from) var(--tw-gradient-from-position), var(--tw-gradient-via) var(--tw-gradient-via-position), var(--tw-gradient-to) var(--tw-gradient-to-position);--tw-gradient-stops:var(--tw-gradient-via-stops)}.to-\\[\\#050F19\\]\\/99{--tw-gradient-to:#050f19fc;--tw-gradient-stops:var(--tw-gradient-via-stops,var(--tw-gradient-position), var(--tw-gradient-from) var(--tw-gradient-from-position), var(--tw-gradient-to) var(--tw-gradient-to-position))}@supports (color:color(display-p3 0 0 0)){.to-\\[\\#050F19\\]\\/99{--tw-gradient-to:color(display-p3 .0270841 .0577423 .0947219/.99)}}@supports (color:lab(0% 0 0)){.to-\\[\\#050F19\\]\\/99{--tw-gradient-to:lab(3.9307% -1.22581 -7.24003/.99)}}.to-black\\/40{--tw-gradient-to:#0006}@supports (color:color-mix(in lab, red, red)){.to-black\\/40{--tw-gradient-to:color-mix(in oklab, var(--color-black) 40%, transparent)}}.to-black\\/40{--tw-gradient-stops:var(--tw-gradient-via-stops,var(--tw-gradient-position), var(--tw-gradient-from) var(--tw-gradient-from-position), var(--tw-gradient-to) var(--tw-gradient-to-position))}.to-black\\/80{--tw-gradient-to:#000c}@supports (color:color-mix(in lab, red, red)){.to-black\\/80{--tw-gradient-to:color-mix(in oklab, var(--color-black) 80%, transparent)}}.to-black\\/80{--tw-gradient-stops:var(--tw-gradient-via-stops,var(--tw-gradient-position), var(--tw-gradient-from) var(--tw-gradient-from-position), var(--tw-gradient-to) var(--tw-gradient-to-position))}.to-black\\/100{--tw-gradient-to:var(--color-black);--tw-gradient-stops:var(--tw-gradient-via-stops,var(--tw-gradient-position), var(--tw-gradient-from) var(--tw-gradient-from-position), var(--tw-gradient-to) var(--tw-gradient-to-position))}.to-theme-950{--tw-gradient-to:var(--color-theme-950);--tw-gradient-stops:var(--tw-gradient-via-stops,var(--tw-gradient-position), var(--tw-gradient-from) var(--tw-gradient-from-position), var(--tw-gradient-to) var(--tw-gradient-to-position))}.to-transparent{--tw-gradient-to:transparent;--tw-gradient-stops:var(--tw-gradient-via-stops,var(--tw-gradient-position), var(--tw-gradient-from) var(--tw-gradient-from-position), var(--tw-gradient-to) var(--tw-gradient-to-position))}.bg-cover{background-size:cover}.bg-center{background-position:50%}.bg-no-repeat{background-repeat:no-repeat}.object-cover{object-fit:cover}.p-0{padding:0}.p-2{padding:calc(var(--spacing) * 2)}.p-3{padding:calc(var(--spacing) * 3)}.p-4{padding:calc(var(--spacing) * 4)}.p-5{padding:calc(var(--spacing) * 5)}.p-6{padding:calc(var(--spacing) * 6)}.p-8{padding:calc(var(--spacing) * 8)}.p-24{padding:calc(var(--spacing) * 24)}.px-1{padding-inline:var(--spacing)}.px-2{padding-inline:calc(var(--spacing) * 2)}.px-2\\.5{padding-inline:calc(var(--spacing) * 2.5)}.px-3{padding-inline:calc(var(--spacing) * 3)}.px-3\\.5{padding-inline:calc(var(--spacing) * 3.5)}.px-4{padding-inline:calc(var(--spacing) * 4)}.px-5{padding-inline:calc(var(--spacing) * 5)}.px-6{padding-inline:calc(var(--spacing) * 6)}.px-8{padding-inline:calc(var(--spacing) * 8)}.px-9{padding-inline:calc(var(--spacing) * 9)}.px-14{padding-inline:calc(var(--spacing) * 14)}.py-0\\.5{padding-block:calc(var(--spacing) * .5)}.py-1{padding-block:var(--spacing)}.py-1\\.5{padding-block:calc(var(--spacing) * 1.5)}.py-2{padding-block:calc(var(--spacing) * 2)}.py-2\\.5{padding-block:calc(var(--spacing) * 2.5)}.py-3{padding-block:calc(var(--spacing) * 3)}.py-3\\.5{padding-block:calc(var(--spacing) * 3.5)}.py-4{padding-block:calc(var(--spacing) * 4)}.py-5{padding-block:calc(var(--spacing) * 5)}.py-6{padding-block:calc(var(--spacing) * 6)}.py-16{padding-block:calc(var(--spacing) * 16)}.pt-0{padding-top:0}.pt-0\\.5{padding-top:calc(var(--spacing) * .5)}.pt-1{padding-top:var(--spacing)}.pt-2{padding-top:calc(var(--spacing) * 2)}.pt-2\\.5{padding-top:calc(var(--spacing) * 2.5)}.pt-3{padding-top:calc(var(--spacing) * 3)}.pt-4{padding-top:calc(var(--spacing) * 4)}.pt-6{padding-top:calc(var(--spacing) * 6)}.pt-8{padding-top:calc(var(--spacing) * 8)}.pt-10{padding-top:calc(var(--spacing) * 10)}.pt-12{padding-top:calc(var(--spacing) * 12)}.pr-3{padding-right:calc(var(--spacing) * 3)}.pb-2{padding-bottom:calc(var(--spacing) * 2)}.pb-2\\.5{padding-bottom:calc(var(--spacing) * 2.5)}.pb-3\\.5{padding-bottom:calc(var(--spacing) * 3.5)}.pb-4{padding-bottom:calc(var(--spacing) * 4)}.pb-5{padding-bottom:calc(var(--spacing) * 5)}.pb-8{padding-bottom:calc(var(--spacing) * 8)}.pb-12{padding-bottom:calc(var(--spacing) * 12)}.pb-\\[120px\\]{padding-bottom:120px}.pb-\\[max\\(3rem\\,env\\(safe-area-inset-bottom\\)\\)\\]{padding-bottom:max(3rem, env(safe-area-inset-bottom))}.pb-\\[max\\(env\\(safe-area-inset-bottom\\)\\,1rem\\)\\]{padding-bottom:max(env(safe-area-inset-bottom), 1rem)}.pl-0\\.5{padding-left:calc(var(--spacing) * .5)}.pl-2{padding-left:calc(var(--spacing) * 2)}.pl-\\[22px\\]{padding-left:22px}.pl-\\[30px\\]{padding-left:30px}.text-center{text-align:center}.text-left{text-align:left}.font-mono{font-family:var(--font-mono)}.text-2xl{font-size:var(--text-2xl);line-height:var(--tw-leading,var(--text-2xl--line-height))}.text-3xl{font-size:var(--text-3xl);line-height:var(--tw-leading,var(--text-3xl--line-height))}.text-base{font-size:var(--text-base);line-height:var(--tw-leading,var(--text-base--line-height))}.text-lg{font-size:var(--text-lg);line-height:var(--tw-leading,var(--text-lg--line-height))}.text-sm{font-size:var(--text-sm);line-height:var(--tw-leading,var(--text-sm--line-height))}.text-xl{font-size:var(--text-xl);line-height:var(--tw-leading,var(--text-xl--line-height))}.text-xs{font-size:var(--text-xs);line-height:var(--tw-leading,var(--text-xs--line-height))}.text-\\[10\\.5px\\]{font-size:10.5px}.text-\\[10px\\]{font-size:10px}.text-\\[11\\.5px\\]{font-size:11.5px}.text-\\[11px\\]{font-size:11px}.text-\\[12px\\]{font-size:12px}.text-\\[13\\.5px\\]{font-size:13.5px}.text-\\[13px\\]{font-size:13px}.text-\\[14px\\]{font-size:14px}.text-\\[15px\\]{font-size:15px}.leading-\\[1\\.5\\]{--tw-leading:1.5;line-height:1.5}.leading-\\[1\\.55\\]{--tw-leading:1.55;line-height:1.55}.leading-none{--tw-leading:1;line-height:1}.leading-relaxed{--tw-leading:var(--leading-relaxed);line-height:var(--leading-relaxed)}.leading-snug{--tw-leading:var(--leading-snug);line-height:var(--leading-snug)}.leading-tight{--tw-leading:var(--leading-tight);line-height:var(--leading-tight)}.font-light{--tw-font-weight:var(--font-weight-light);font-weight:var(--font-weight-light)}.font-medium{--tw-font-weight:var(--font-weight-medium);font-weight:var(--font-weight-medium)}.font-semibold{--tw-font-weight:var(--font-weight-semibold);font-weight:var(--font-weight-semibold)}.tracking-\\[-0\\.006em\\]{--tw-tracking:-.006em;letter-spacing:-.006em}.tracking-\\[0\\.06em\\]{--tw-tracking:.06em;letter-spacing:.06em}.tracking-\\[0\\.35em\\]{--tw-tracking:.35em;letter-spacing:.35em}.tracking-wide{--tw-tracking:var(--tracking-wide);letter-spacing:var(--tracking-wide)}.tracking-widest{--tw-tracking:var(--tracking-widest);letter-spacing:var(--tracking-widest)}.text-pretty{text-wrap:pretty}.break-words{overflow-wrap:break-word}.whitespace-pre-wrap{white-space:pre-wrap}.text-\\[\\#050F19\\]{color:#050f19}.text-green-500{color:var(--color-green-500)}.text-green-600{color:var(--color-green-600)}.text-primary-300{color:var(--color-primary-300)}.text-primary-400{color:var(--color-primary-400)}.text-red-400{color:var(--color-red-400)}.text-red-500{color:var(--color-red-500)}.text-red-600{color:var(--color-red-600)}.text-slate-950{color:var(--color-slate-950)}.text-theme-0{color:var(--color-theme-0)}.text-theme-300{color:var(--color-theme-300)}.text-theme-400{color:var(--color-theme-400)}.text-theme-500{color:var(--color-theme-500)}.text-theme-600{color:var(--color-theme-600)}.text-theme-700{color:var(--color-theme-700)}.text-theme-800{color:var(--color-theme-800)}.text-theme-900{color:var(--color-theme-900)}.text-theme-950{color:var(--color-theme-950)}.text-white{color:var(--color-white)}.text-white\\/30{color:#ffffff4d}@supports (color:color-mix(in lab, red, red)){.text-white\\/30{color:color-mix(in oklab, var(--color-white) 30%, transparent)}}.text-white\\/35{color:#ffffff59}@supports (color:color-mix(in lab, red, red)){.text-white\\/35{color:color-mix(in oklab, var(--color-white) 35%, transparent)}}.text-white\\/40{color:#fff6}@supports (color:color-mix(in lab, red, red)){.text-white\\/40{color:color-mix(in oklab, var(--color-white) 40%, transparent)}}.text-white\\/45{color:#ffffff73}@supports (color:color-mix(in lab, red, red)){.text-white\\/45{color:color-mix(in oklab, var(--color-white) 45%, transparent)}}.text-white\\/50{color:#ffffff80}@supports (color:color-mix(in lab, red, red)){.text-white\\/50{color:color-mix(in oklab, var(--color-white) 50%, transparent)}}.text-white\\/55{color:#ffffff8c}@supports (color:color-mix(in lab, red, red)){.text-white\\/55{color:color-mix(in oklab, var(--color-white) 55%, transparent)}}.text-white\\/60{color:#fff9}@supports (color:color-mix(in lab, red, red)){.text-white\\/60{color:color-mix(in oklab, var(--color-white) 60%, transparent)}}.text-white\\/70{color:#ffffffb3}@supports (color:color-mix(in lab, red, red)){.text-white\\/70{color:color-mix(in oklab, var(--color-white) 70%, transparent)}}.text-white\\/80{color:#fffc}@supports (color:color-mix(in lab, red, red)){.text-white\\/80{color:color-mix(in oklab, var(--color-white) 80%, transparent)}}.text-white\\/85{color:#ffffffd9}@supports (color:color-mix(in lab, red, red)){.text-white\\/85{color:color-mix(in oklab, var(--color-white) 85%, transparent)}}.text-white\\/90{color:#ffffffe6}@supports (color:color-mix(in lab, red, red)){.text-white\\/90{color:color-mix(in oklab, var(--color-white) 90%, transparent)}}.text-white\\/95{color:#fffffff2}@supports (color:color-mix(in lab, red, red)){.text-white\\/95{color:color-mix(in oklab, var(--color-white) 95%, transparent)}}.uppercase{text-transform:uppercase}.tabular-nums{--tw-numeric-spacing:tabular-nums;font-variant-numeric:var(--tw-ordinal, ) var(--tw-slashed-zero, ) var(--tw-numeric-figure, ) var(--tw-numeric-spacing, ) var(--tw-numeric-fraction, )}.underline{text-decoration-line:underline}.underline-offset-2{text-underline-offset:2px}.placeholder-theme-300::placeholder{color:var(--color-theme-300)}.placeholder-theme-400::placeholder{color:var(--color-theme-400)}.placeholder-theme-500::placeholder{color:var(--color-theme-500)}.placeholder-white\\/50::placeholder{color:#ffffff80}@supports (color:color-mix(in lab, red, red)){.placeholder-white\\/50::placeholder{color:color-mix(in oklab, var(--color-white) 50%, transparent)}}.opacity-0{opacity:0}.opacity-40{opacity:.4}.opacity-50{opacity:.5}.opacity-60{opacity:.6}.opacity-70{opacity:.7}.opacity-100{opacity:1}.shadow{--tw-shadow:0 1px 3px 0 var(--tw-shadow-color,#0000001a), 0 1px 2px -1px var(--tw-shadow-color,#0000001a);box-shadow:var(--tw-inset-shadow), var(--tw-inset-ring-shadow), var(--tw-ring-offset-shadow), var(--tw-ring-shadow), var(--tw-shadow)}.shadow-2xl{--tw-shadow:0 25px 50px -12px var(--tw-shadow-color,#00000040);box-shadow:var(--tw-inset-shadow), var(--tw-inset-ring-shadow), var(--tw-ring-offset-shadow), var(--tw-ring-shadow), var(--tw-shadow)}.shadow-\\[0_1px_2px_rgba\\(15\\,23\\,42\\,0\\.04\\)\\,0_12px_32px_rgba\\(15\\,23\\,42\\,0\\.07\\)\\]{--tw-shadow:0 1px 2px var(--tw-shadow-color,#0f172a0a), 0 12px 32px var(--tw-shadow-color,#0f172a12);box-shadow:var(--tw-inset-shadow), var(--tw-inset-ring-shadow), var(--tw-ring-offset-shadow), var(--tw-ring-shadow), var(--tw-shadow)}.shadow-\\[0_8px_32px_-4px_rgba\\(0\\,0\\,0\\,0\\.15\\)\\]{--tw-shadow:0 8px 32px -4px var(--tw-shadow-color,#00000026);box-shadow:var(--tw-inset-shadow), var(--tw-inset-ring-shadow), var(--tw-ring-offset-shadow), var(--tw-ring-shadow), var(--tw-shadow)}.shadow-\\[0_24px_80px_-12px_rgba\\(0\\,0\\,0\\,0\\.2\\)\\,0_8px_24px_-8px_rgba\\(0\\,0\\,0\\,0\\.08\\)\\]{--tw-shadow:0 24px 80px -12px var(--tw-shadow-color,#0003), 0 8px 24px -8px var(--tw-shadow-color,#00000014);box-shadow:var(--tw-inset-shadow), var(--tw-inset-ring-shadow), var(--tw-ring-offset-shadow), var(--tw-ring-shadow), var(--tw-shadow)}.shadow-lg{--tw-shadow:0 10px 15px -3px var(--tw-shadow-color,#0000001a), 0 4px 6px -4px var(--tw-shadow-color,#0000001a);box-shadow:var(--tw-inset-shadow), var(--tw-inset-ring-shadow), var(--tw-ring-offset-shadow), var(--tw-ring-shadow), var(--tw-shadow)}.shadow-sm{--tw-shadow:0 1px 3px 0 var(--tw-shadow-color,#0000001a), 0 1px 2px -1px var(--tw-shadow-color,#0000001a);box-shadow:var(--tw-inset-shadow), var(--tw-inset-ring-shadow), var(--tw-ring-offset-shadow), var(--tw-ring-shadow), var(--tw-shadow)}.shadow-xl{--tw-shadow:0 20px 25px -5px var(--tw-shadow-color,#0000001a), 0 8px 10px -6px var(--tw-shadow-color,#0000001a);box-shadow:var(--tw-inset-shadow), var(--tw-inset-ring-shadow), var(--tw-ring-offset-shadow), var(--tw-ring-shadow), var(--tw-shadow)}.ring,.ring-1{--tw-ring-shadow:var(--tw-ring-inset, ) 0 0 0 calc(1px + var(--tw-ring-offset-width)) var(--tw-ring-color,currentcolor);box-shadow:var(--tw-inset-shadow), var(--tw-inset-ring-shadow), var(--tw-ring-offset-shadow), var(--tw-ring-shadow), var(--tw-shadow)}.ring-2{--tw-ring-shadow:var(--tw-ring-inset, ) 0 0 0 calc(2px + var(--tw-ring-offset-width)) var(--tw-ring-color,currentcolor);box-shadow:var(--tw-inset-shadow), var(--tw-inset-ring-shadow), var(--tw-ring-offset-shadow), var(--tw-ring-shadow), var(--tw-shadow)}.ring-black\\/5{--tw-ring-color:#0000000d}@supports (color:color-mix(in lab, red, red)){.ring-black\\/5{--tw-ring-color:color-mix(in oklab, var(--color-black) 5%, transparent)}}.ring-theme-200,.ring-theme-200\\/50{--tw-ring-color:var(--color-theme-200)}@supports (color:color-mix(in lab, red, red)){.ring-theme-200\\/50{--tw-ring-color:color-mix(in oklab, var(--color-theme-200) 50%, transparent)}}.ring-theme-900{--tw-ring-color:var(--color-theme-900)}.ring-theme-950\\/20{--tw-ring-color:var(--color-theme-950)}@supports (color:color-mix(in lab, red, red)){.ring-theme-950\\/20{--tw-ring-color:color-mix(in oklab, var(--color-theme-950) 20%, transparent)}}.ring-theme-950\\/\\[0\\.06\\]{--tw-ring-color:var(--color-theme-950)}@supports (color:color-mix(in lab, red, red)){.ring-theme-950\\/\\[0\\.06\\]{--tw-ring-color:color-mix(in oklab, var(--color-theme-950) 6%, transparent)}}.ring-white{--tw-ring-color:var(--color-white)}.ring-white\\/10{--tw-ring-color:#ffffff1a}@supports (color:color-mix(in lab, red, red)){.ring-white\\/10{--tw-ring-color:color-mix(in oklab, var(--color-white) 10%, transparent)}}.ring-white\\/15{--tw-ring-color:#ffffff26}@supports (color:color-mix(in lab, red, red)){.ring-white\\/15{--tw-ring-color:color-mix(in oklab, var(--color-white) 15%, transparent)}}.ring-white\\/20{--tw-ring-color:#fff3}@supports (color:color-mix(in lab, red, red)){.ring-white\\/20{--tw-ring-color:color-mix(in oklab, var(--color-white) 20%, transparent)}}.blur{--tw-blur:blur(8px);filter:var(--tw-blur, ) var(--tw-brightness, ) var(--tw-contrast, ) var(--tw-grayscale, ) var(--tw-hue-rotate, ) var(--tw-invert, ) var(--tw-saturate, ) var(--tw-sepia, ) var(--tw-drop-shadow, )}.backdrop-blur-lg{--tw-backdrop-blur:blur(var(--blur-lg));-webkit-backdrop-filter:var(--tw-backdrop-blur, ) var(--tw-backdrop-brightness, ) var(--tw-backdrop-contrast, ) var(--tw-backdrop-grayscale, ) var(--tw-backdrop-hue-rotate, ) var(--tw-backdrop-invert, ) var(--tw-backdrop-opacity, ) var(--tw-backdrop-saturate, ) var(--tw-backdrop-sepia, );backdrop-filter:var(--tw-backdrop-blur, ) var(--tw-backdrop-brightness, ) var(--tw-backdrop-contrast, ) var(--tw-backdrop-grayscale, ) var(--tw-backdrop-hue-rotate, ) var(--tw-backdrop-invert, ) var(--tw-backdrop-opacity, ) var(--tw-backdrop-saturate, ) var(--tw-backdrop-sepia, )}.backdrop-blur-sm{--tw-backdrop-blur:blur(var(--blur-sm));-webkit-backdrop-filter:var(--tw-backdrop-blur, ) var(--tw-backdrop-brightness, ) var(--tw-backdrop-contrast, ) var(--tw-backdrop-grayscale, ) var(--tw-backdrop-hue-rotate, ) var(--tw-backdrop-invert, ) var(--tw-backdrop-opacity, ) var(--tw-backdrop-saturate, ) var(--tw-backdrop-sepia, );backdrop-filter:var(--tw-backdrop-blur, ) var(--tw-backdrop-brightness, ) var(--tw-backdrop-contrast, ) var(--tw-backdrop-grayscale, ) var(--tw-backdrop-hue-rotate, ) var(--tw-backdrop-invert, ) var(--tw-backdrop-opacity, ) var(--tw-backdrop-saturate, ) var(--tw-backdrop-sepia, )}.backdrop-blur-xl{--tw-backdrop-blur:blur(var(--blur-xl));-webkit-backdrop-filter:var(--tw-backdrop-blur, ) var(--tw-backdrop-brightness, ) var(--tw-backdrop-contrast, ) var(--tw-backdrop-grayscale, ) var(--tw-backdrop-hue-rotate, ) var(--tw-backdrop-invert, ) var(--tw-backdrop-opacity, ) var(--tw-backdrop-saturate, ) var(--tw-backdrop-sepia, );backdrop-filter:var(--tw-backdrop-blur, ) var(--tw-backdrop-brightness, ) var(--tw-backdrop-contrast, ) var(--tw-backdrop-grayscale, ) var(--tw-backdrop-hue-rotate, ) var(--tw-backdrop-invert, ) var(--tw-backdrop-opacity, ) var(--tw-backdrop-saturate, ) var(--tw-backdrop-sepia, )}.transition{transition-property:color,background-color,border-color,outline-color,text-decoration-color,fill,stroke,--tw-gradient-from,--tw-gradient-via,--tw-gradient-to,opacity,box-shadow,transform,translate,scale,rotate,filter,-webkit-backdrop-filter,backdrop-filter,display,content-visibility,overlay,pointer-events;transition-timing-function:var(--tw-ease,var(--default-transition-timing-function));transition-duration:var(--tw-duration,var(--default-transition-duration))}.transition-\\[opacity\\,transform\\]{transition-property:opacity,transform;transition-timing-function:var(--tw-ease,var(--default-transition-timing-function));transition-duration:var(--tw-duration,var(--default-transition-duration))}.transition-all{transition-property:all;transition-timing-function:var(--tw-ease,var(--default-transition-timing-function));transition-duration:var(--tw-duration,var(--default-transition-duration))}.transition-colors{transition-property:color,background-color,border-color,outline-color,text-decoration-color,fill,stroke,--tw-gradient-from,--tw-gradient-via,--tw-gradient-to;transition-timing-function:var(--tw-ease,var(--default-transition-timing-function));transition-duration:var(--tw-duration,var(--default-transition-duration))}.transition-opacity{transition-property:opacity;transition-timing-function:var(--tw-ease,var(--default-transition-timing-function));transition-duration:var(--tw-duration,var(--default-transition-duration))}.transition-transform{transition-property:transform,translate,scale,rotate;transition-timing-function:var(--tw-ease,var(--default-transition-timing-function));transition-duration:var(--tw-duration,var(--default-transition-duration))}.duration-150{--tw-duration:.15s;transition-duration:.15s}.duration-200{--tw-duration:.2s;transition-duration:.2s}.duration-250{--tw-duration:.25s;transition-duration:.25s}.duration-300{--tw-duration:.3s;transition-duration:.3s}.duration-400{--tw-duration:.4s;transition-duration:.4s}.duration-500{--tw-duration:.5s;transition-duration:.5s}.duration-1000{--tw-duration:1s;transition-duration:1s}.duration-\\[400ms\\]{--tw-duration:.4s;transition-duration:.4s}.ease-\\[cubic-bezier\\(0\\.25\\,1\\,0\\.33\\,1\\)\\]{--tw-ease:cubic-bezier(.25,1,.33,1);transition-timing-function:cubic-bezier(.25,1,.33,1)}.ease-\\[cubic-bezier\\(0\\.52\\,0\\.01\\,0\\.16\\,1\\)\\]{--tw-ease:cubic-bezier(.52,.01,.16,1);transition-timing-function:cubic-bezier(.52,.01,.16,1)}.ease-in{--tw-ease:var(--ease-in);transition-timing-function:var(--ease-in)}.ease-in-out{--tw-ease:var(--ease-in-out);transition-timing-function:var(--ease-in-out)}.ease-out{--tw-ease:var(--ease-out);transition-timing-function:var(--ease-out)}.will-change-transform{will-change:transform}.outline-none{--tw-outline-style:none;outline-style:none}.\\[-ms-overflow-style\\:none\\]{-ms-overflow-style:none}.\\[animation-duration\\:3s\\]{animation-duration:3s}.\\[overflow-anchor\\:none\\]{overflow-anchor:none}@media (hover:hover){:is(:where(.group):hover .group-hover\\:scale-100){--tw-scale-x:100%;--tw-scale-y:100%;--tw-scale-z:100%;scale:var(--tw-scale-x) var(--tw-scale-y)}:is(:where(.group):hover .group-hover\\:scale-110){--tw-scale-x:110%;--tw-scale-y:110%;--tw-scale-z:110%;scale:var(--tw-scale-x) var(--tw-scale-y)}:is(:where(.group):hover .group-hover\\:text-white){color:var(--color-white)}:is(:where(.group):hover .group-hover\\:opacity-40){opacity:.4}:is(:where(.group\\/msg):hover .group-hover\\/msg\\:opacity-100){opacity:1}}.focus-within\\:bg-white\\/15:focus-within{background-color:#ffffff26}@supports (color:color-mix(in lab, red, red)){.focus-within\\:bg-white\\/15:focus-within{background-color:color-mix(in oklab, var(--color-white) 15%, transparent)}}.focus-within\\:opacity-100:focus-within{opacity:1}.focus-within\\:ring-theme-950\\/30:focus-within{--tw-ring-color:var(--color-theme-950)}@supports (color:color-mix(in lab, red, red)){.focus-within\\:ring-theme-950\\/30:focus-within{--tw-ring-color:color-mix(in oklab, var(--color-theme-950) 30%, transparent)}}.focus-within\\:ring-white\\/25:focus-within{--tw-ring-color:#ffffff40}@supports (color:color-mix(in lab, red, red)){.focus-within\\:ring-white\\/25:focus-within{--tw-ring-color:color-mix(in oklab, var(--color-white) 25%, transparent)}}@media (hover:hover){.hover\\:translate-y-\\[-1px\\]:hover{--tw-translate-y:-1px;translate:var(--tw-translate-x) var(--tw-translate-y)}.hover\\:scale-105:hover{--tw-scale-x:105%;--tw-scale-y:105%;--tw-scale-z:105%;scale:var(--tw-scale-x) var(--tw-scale-y)}.hover\\:scale-110:hover{--tw-scale-x:110%;--tw-scale-y:110%;--tw-scale-z:110%;scale:var(--tw-scale-x) var(--tw-scale-y)}.hover\\:rotate-90:hover{rotate:90deg}.hover\\:border-green-300:hover{border-color:var(--color-green-300)}.hover\\:border-primary-300:hover{border-color:var(--color-primary-300)}.hover\\:border-red-300:hover{border-color:var(--color-red-300)}.hover\\:border-theme-200:hover{border-color:var(--color-theme-200)}.hover\\:border-theme-300:hover{border-color:var(--color-theme-300)}.hover\\:border-white\\/10:hover{border-color:#ffffff1a}@supports (color:color-mix(in lab, red, red)){.hover\\:border-white\\/10:hover{border-color:color-mix(in oklab, var(--color-white) 10%, transparent)}}.hover\\:border-white\\/40:hover{border-color:#fff6}@supports (color:color-mix(in lab, red, red)){.hover\\:border-white\\/40:hover{border-color:color-mix(in oklab, var(--color-white) 40%, transparent)}}.hover\\:bg-green-500:hover{background-color:var(--color-green-500)}.hover\\:bg-primary-500:hover{background-color:var(--color-primary-500)}.hover\\:bg-red-500:hover{background-color:var(--color-red-500)}.hover\\:bg-theme-25:hover{background-color:var(--color-theme-25)}.hover\\:bg-theme-50:hover{background-color:var(--color-theme-50)}.hover\\:bg-theme-100:hover{background-color:var(--color-theme-100)}.hover\\:bg-theme-200:hover{background-color:var(--color-theme-200)}.hover\\:bg-theme-700:hover{background-color:var(--color-theme-700)}.hover\\:bg-theme-800:hover{background-color:var(--color-theme-800)}.hover\\:bg-theme-950\\/5:hover{background-color:var(--color-theme-950)}@supports (color:color-mix(in lab, red, red)){.hover\\:bg-theme-950\\/5:hover{background-color:color-mix(in oklab, var(--color-theme-950) 5%, transparent)}}.hover\\:bg-white\\/5:hover{background-color:#ffffff0d}@supports (color:color-mix(in lab, red, red)){.hover\\:bg-white\\/5:hover{background-color:color-mix(in oklab, var(--color-white) 5%, transparent)}}.hover\\:bg-white\\/10:hover{background-color:#ffffff1a}@supports (color:color-mix(in lab, red, red)){.hover\\:bg-white\\/10:hover{background-color:color-mix(in oklab, var(--color-white) 10%, transparent)}}.hover\\:bg-white\\/15:hover{background-color:#ffffff26}@supports (color:color-mix(in lab, red, red)){.hover\\:bg-white\\/15:hover{background-color:color-mix(in oklab, var(--color-white) 15%, transparent)}}.hover\\:bg-white\\/20:hover{background-color:#fff3}@supports (color:color-mix(in lab, red, red)){.hover\\:bg-white\\/20:hover{background-color:color-mix(in oklab, var(--color-white) 20%, transparent)}}.hover\\:text-primary-600:hover{color:var(--color-primary-600)}.hover\\:text-red-600:hover{color:var(--color-red-600)}.hover\\:text-theme-400:hover{color:var(--color-theme-400)}.hover\\:text-theme-500:hover{color:var(--color-theme-500)}.hover\\:text-theme-600:hover{color:var(--color-theme-600)}.hover\\:text-theme-700:hover{color:var(--color-theme-700)}.hover\\:text-theme-800:hover{color:var(--color-theme-800)}.hover\\:text-theme-900:hover{color:var(--color-theme-900)}.hover\\:text-white:hover{color:var(--color-white)}.hover\\:text-white\\/70:hover{color:#ffffffb3}@supports (color:color-mix(in lab, red, red)){.hover\\:text-white\\/70:hover{color:color-mix(in oklab, var(--color-white) 70%, transparent)}}.hover\\:text-white\\/80:hover{color:#fffc}@supports (color:color-mix(in lab, red, red)){.hover\\:text-white\\/80:hover{color:color-mix(in oklab, var(--color-white) 80%, transparent)}}.hover\\:opacity-70:hover{opacity:.7}.hover\\:shadow-2xl:hover{--tw-shadow:0 25px 50px -12px var(--tw-shadow-color,#00000040);box-shadow:var(--tw-inset-shadow), var(--tw-inset-ring-shadow), var(--tw-ring-offset-shadow), var(--tw-ring-shadow), var(--tw-shadow)}.hover\\:ring-theme-950\\/30:hover{--tw-ring-color:var(--color-theme-950)}@supports (color:color-mix(in lab, red, red)){.hover\\:ring-theme-950\\/30:hover{--tw-ring-color:color-mix(in oklab, var(--color-theme-950) 30%, transparent)}}.hover\\:ring-white\\/25:hover{--tw-ring-color:#ffffff40}@supports (color:color-mix(in lab, red, red)){.hover\\:ring-white\\/25:hover{--tw-ring-color:color-mix(in oklab, var(--color-white) 25%, transparent)}}.hover\\:brightness-110:hover{--tw-brightness:brightness(110%);filter:var(--tw-blur, ) var(--tw-brightness, ) var(--tw-contrast, ) var(--tw-grayscale, ) var(--tw-hue-rotate, ) var(--tw-invert, ) var(--tw-saturate, ) var(--tw-sepia, ) var(--tw-drop-shadow, )}}.focus\\:border-theme-900:focus{border-color:var(--color-theme-900)}.focus\\:outline-none:focus{--tw-outline-style:none;outline-style:none}.focus-visible\\:ring-2:focus-visible{--tw-ring-shadow:var(--tw-ring-inset, ) 0 0 0 calc(2px + var(--tw-ring-offset-width)) var(--tw-ring-color,currentcolor);box-shadow:var(--tw-inset-shadow), var(--tw-inset-ring-shadow), var(--tw-ring-offset-shadow), var(--tw-ring-shadow), var(--tw-shadow)}.focus-visible\\:ring-theme-900:focus-visible{--tw-ring-color:var(--color-theme-900)}.focus-visible\\:ring-white:focus-visible{--tw-ring-color:var(--color-white)}.focus-visible\\:ring-offset-2:focus-visible{--tw-ring-offset-width:2px;--tw-ring-offset-shadow:var(--tw-ring-inset, ) 0 0 0 var(--tw-ring-offset-width) var(--tw-ring-offset-color)}.focus-visible\\:outline-none:focus-visible{--tw-outline-style:none;outline-style:none}.active\\:-translate-y-0\\.5:active{--tw-translate-y:calc(var(--spacing) * -.5);translate:var(--tw-translate-x) var(--tw-translate-y)}.active\\:scale-90:active{--tw-scale-x:90%;--tw-scale-y:90%;--tw-scale-z:90%;scale:var(--tw-scale-x) var(--tw-scale-y)}.active\\:scale-95:active{--tw-scale-x:95%;--tw-scale-y:95%;--tw-scale-z:95%;scale:var(--tw-scale-x) var(--tw-scale-y)}.active\\:scale-\\[0\\.98\\]:active{scale:.98}.active\\:scale-\\[1\\.06\\]:active{scale:1.06}.active\\:bg-theme-800\\/80:active{background-color:var(--color-theme-800)}@supports (color:color-mix(in lab, red, red)){.active\\:bg-theme-800\\/80:active{background-color:color-mix(in oklab, var(--color-theme-800) 80%, transparent)}}.active\\:bg-white\\/25:active{background-color:#ffffff40}@supports (color:color-mix(in lab, red, red)){.active\\:bg-white\\/25:active{background-color:color-mix(in oklab, var(--color-white) 25%, transparent)}}.active\\:opacity-70:active{opacity:.7}.active\\:opacity-80:active{opacity:.8}.active\\:duration-100:active{--tw-duration:.1s;transition-duration:.1s}.disabled\\:cursor-default:disabled{cursor:default}.disabled\\:cursor-not-allowed:disabled{cursor:not-allowed}.disabled\\:opacity-50:disabled{opacity:.5}@media (min-width:40rem){.sm\\:top-6{top:calc(var(--spacing) * 6)}.sm\\:right-6{right:calc(var(--spacing) * 6)}.sm\\:bottom-6{bottom:calc(var(--spacing) * 6)}.sm\\:left-6{left:calc(var(--spacing) * 6)}.sm\\:size-16{width:calc(var(--spacing) * 16);height:calc(var(--spacing) * 16)}.sm\\:h-24{height:calc(var(--spacing) * 24)}.sm\\:max-h-\\[620px\\]{max-height:620px}.sm\\:w-24{width:calc(var(--spacing) * 24)}.sm\\:max-w-\\[420px\\]{max-width:420px}.sm\\:flex-none{flex:none}.sm\\:items-center{align-items:center}.sm\\:justify-center{justify-content:center}.sm\\:rounded-\\[32px\\]{border-radius:32px}.sm\\:bg-\\[\\#050F19\\]\\/45{background-color:#050f1973;background-color:color(display-p3 .0270841 .0577423 .0947219/.45);background-color:lab(3.9307% -1.22581 -7.24003/.45)}.sm\\:p-6{padding:calc(var(--spacing) * 6)}.sm\\:px-12{padding-inline:calc(var(--spacing) * 12)}.sm\\:pb-9{padding-bottom:calc(var(--spacing) * 9)}.sm\\:text-2xl{font-size:var(--text-2xl);line-height:var(--tw-leading,var(--text-2xl--line-height))}.sm\\:text-base{font-size:var(--text-base);line-height:var(--tw-leading,var(--text-base--line-height))}.sm\\:shadow-\\[0_32px_80px_rgba\\(5\\,15\\,25\\,0\\.45\\)\\]{--tw-shadow:0 32px 80px var(--tw-shadow-color,#050f1973);box-shadow:var(--tw-inset-shadow), var(--tw-inset-ring-shadow), var(--tw-ring-offset-shadow), var(--tw-ring-shadow), var(--tw-shadow)}}@media (min-width:48rem){.md\\:h-\\[600px\\]{height:600px}}@container bot (width>=480px){.\\@\\[480px\\]\\/bot\\:px-6{padding-inline:calc(var(--spacing) * 6)}}@container chat (width>=24rem){.\\@sm\\/chat\\:ml-\\[2em\\]{margin-left:2em}.\\@sm\\/chat\\:size-24{width:calc(var(--spacing) * 24);height:calc(var(--spacing) * 24)}}@container chat-preview (width>=24rem){.\\@sm\\/chat-preview\\:max-w-\\[78\\%\\]{max-width:78%}}@container chat (width>=24rem){.\\@sm\\/chat\\:max-w-\\[320px\\]{max-width:320px}.\\@sm\\/chat\\:pr-\\[2em\\]{padding-right:2em}.\\@sm\\/chat\\:text-lg{font-size:var(--text-lg);line-height:var(--tw-leading,var(--text-lg--line-height))}.\\@sm\\/chat\\:text-sm{font-size:var(--text-sm);line-height:var(--tw-leading,var(--text-sm--line-height))}.\\@sm\\/chat\\:text-\\[15px\\]{font-size:15px}}@container chat (width>=28rem){.\\@md\\/chat\\:block{display:block}}@container chat (width>=32rem){.\\@lg\\/chat\\:px-8{padding-inline:calc(var(--spacing) * 8)}.\\@lg\\/chat\\:text-\\[15\\.5px\\]{font-size:15.5px}}@container chat (width>=64rem){.\\@5xl\\/chat\\:max-w-\\[720px\\]{max-width:720px}.\\@5xl\\/chat\\:max-w-\\[740px\\]{max-width:740px}.\\@5xl\\/chat\\:px-5{padding-inline:calc(var(--spacing) * 5)}.\\@5xl\\/chat\\:pt-3\\.5{padding-top:calc(var(--spacing) * 3.5)}.\\@5xl\\/chat\\:pb-3{padding-bottom:calc(var(--spacing) * 3)}}@media (prefers-color-scheme:dark){.dark\\:bg-theme-600\\/90{background-color:var(--color-theme-600)}@supports (color:color-mix(in lab, red, red)){.dark\\:bg-theme-600\\/90{background-color:color-mix(in oklab, var(--color-theme-600) 90%, transparent)}}}@media (pointer:coarse){.pointer-coarse\\:size-11{width:calc(var(--spacing) * 11);height:calc(var(--spacing) * 11)}.pointer-coarse\\:opacity-100{opacity:1}}.\\[\\&_\\.chat-msg-rich\\]\\:max-w-none .chat-msg-rich{max-width:none}.\\[\\&_\\.chat-msg-rich\\]\\:text-\\[13px\\] .chat-msg-rich{font-size:13px}.\\[\\&_\\.chat-msg-rich\\]\\:leading-\\[1\\.6\\] .chat-msg-rich{--tw-leading:1.6;line-height:1.6}.\\[\\&_\\.chat-msg-rich\\]\\:italic .chat-msg-rich{font-style:italic}.\\[\\&\\:\\:-webkit-scrollbar\\]\\:hidden::-webkit-scrollbar{display:none}}.chat-dots{align-items:center;gap:3px;display:inline-flex}.chat-dots>span{background:currentColor;border-radius:9999px;width:5px;height:5px;animation:1.4s cubic-bezier(.25,1,.33,1) infinite chat-dot}.chat-dots>span:nth-child(2){animation-delay:.16s}.chat-dots>span:nth-child(3){animation-delay:.32s}@keyframes chat-dot{0%,52%,to{opacity:.25;transform:translateY(0)}22%{opacity:1;transform:translateY(-1.5px)}}.chat-dots--mini{gap:2.5px}.chat-dots--mini>span{width:3.5px;height:3.5px}.chat-pulse-dot{animation:1.4s cubic-bezier(.25,1,.33,1) infinite chat-pulse-dot}@keyframes chat-pulse-dot{0%,to{opacity:.35;transform:scale(.7)}35%{opacity:1;transform:scale(1)}}.chat-live-enter{animation:.28s cubic-bezier(.25,1,.33,1) both chat-live-enter}@keyframes chat-live-enter{0%{opacity:0;transform:translateY(3px)}to{opacity:1;transform:translateY(0)}}@media (prefers-reduced-motion:reduce){.chat-dots>span,.chat-pulse-dot{opacity:.55;animation:none}.chat-live-enter{animation:none}}.chat-msg-prose :first-child{margin-top:0}.chat-msg-prose :last-child{margin-bottom:0}.chat-msg-prose+.chat-msg-prose{margin-top:1em}.chat-msg-prose strong{font-weight:600}.chat-msg-prose em{font-style:italic}.chat-msg-prose a{color:var(--color-primary-500);text-underline-offset:3px;text-decoration:underline;-webkit-text-decoration-color:var(--color-primary-500);-webkit-text-decoration-color:var(--color-primary-500);-webkit-text-decoration-color:var(--color-primary-500);text-decoration-color:var(--color-primary-500)}@supports (color:color-mix(in lab, red, red)){.chat-msg-prose a{-webkit-text-decoration-color:color-mix(in oklch, var(--color-primary-500) 40%, transparent);-webkit-text-decoration-color:color-mix(in oklch, var(--color-primary-500) 40%, transparent);-webkit-text-decoration-color:color-mix(in oklch, var(--color-primary-500) 40%, transparent);text-decoration-color:color-mix(in oklch, var(--color-primary-500) 40%, transparent)}}.chat-msg-prose a{font-weight:500;transition:text-decoration-color .15s}.chat-msg-prose a:hover{-webkit-text-decoration-color:var(--color-primary-500);-webkit-text-decoration-color:var(--color-primary-500);-webkit-text-decoration-color:var(--color-primary-500);text-decoration-color:var(--color-primary-500)}.chat-msg-prose.chat-msg-prose-invert a{color:#fff;text-decoration-color:#ffffff73}.chat-msg-prose.chat-msg-prose-invert a:hover{text-decoration-color:#fff}.chat-msg-prose.chat-msg-prose-invert pre,.chat-msg-prose.chat-msg-prose-invert table{background:#ffffff14;border-color:#ffffff2e}.chat-msg-prose.chat-msg-prose-invert td{border-top-color:#ffffff1f}.chat-msg-prose.chat-msg-prose-invert :not(pre)>code{background:#ffffff24}.chat-msg-prose.chat-msg-prose-invert hr{border-top-color:#ffffff38}.chat-msg-prose p{margin:1em 0;line-height:1.55}.chat-msg-prose :-webkit-any(p,ul,ol,blockquote,h1,h2,h3,h4,h5,h6){max-width:34em}.chat-msg-prose :is(p,ul,ol,blockquote,h1,h2,h3,h4,h5,h6){max-width:34em}.chat-msg-prose h1{letter-spacing:-.012em;margin:1.1em 0 .5em;font-size:1.25em;font-weight:600;line-height:1.3}.chat-msg-prose h2{letter-spacing:-.01em;margin:1.1em 0 .45em;font-size:1.15em;font-weight:600;line-height:1.3}.chat-msg-prose h3{letter-spacing:-.008em;margin:1em 0 .4em;font-size:1.05em;font-weight:600;line-height:1.35}.chat-msg-prose h4,.chat-msg-prose h5,.chat-msg-prose h6{margin:.9em 0 .35em;font-size:1em;font-weight:600;line-height:1.4}.chat-msg-prose ul,.chat-msg-prose ol{margin:.7em 0 .9em;padding-left:1.4em;line-height:1.55}.chat-msg-prose ul{list-style-type:disc}.chat-msg-prose ol{list-style-type:decimal}.chat-msg-prose li{margin-bottom:.35em}.chat-msg-prose li p{margin:0}.chat-msg-prose li::marker{color:currentColor;opacity:.4}.chat-msg-prose li:has(>input[type=checkbox]){margin-left:-1.4em;list-style:none}.chat-msg-prose li>input[type=checkbox]{-webkit-appearance:none;appearance:none;vertical-align:-.06em;border:1px solid var(--color-theme-300);background:0 0;border-radius:.22em;width:.82em;height:.82em;margin:0 .5em 0 .1em}.chat-msg-prose li>input[type=checkbox]:checked{border-color:var(--color-theme-900);background:var(--color-theme-900) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 10 8'%3E%3Cpath d='M1 4.2 3.8 6.8 9 1.2' fill='none' stroke='white' stroke-width='1.6' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") center / .55em no-repeat}.chat-msg-prose.chat-msg-prose-invert li>input[type=checkbox]{border-color:#fff6}.chat-msg-prose.chat-msg-prose-invert li>input[type=checkbox]:checked{background-color:#fff;background-image:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 10 8'%3E%3Cpath d='M1 4.2 3.8 6.8 9 1.2' fill='none' stroke='%230c0a13' stroke-width='1.6' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");border-color:#fff}.chat-msg-prose pre{background:var(--color-theme-25);border:1px solid var(--color-theme-200);border-radius:.625rem;margin:1.4em 0;padding:.85em 1em;font-family:SF Mono,SFMono-Regular,Consolas,Liberation Mono,Menlo,monospace;font-size:.82em;line-height:1.5;overflow-x:auto}.chat-msg-prose pre code{font-size:inherit;background:0 0;padding:0;font-family:inherit}.chat-msg-prose :not(pre)>code{background:var(--color-theme-200);border-radius:.3rem;padding:.15em .4em;font-size:.85em}@supports (color:color-mix(in lab, red, red)){.chat-msg-prose :not(pre)>code{background:color-mix(in oklch, var(--color-theme-200) 45%, transparent)}}.chat-msg-prose :not(pre)>code{font-family:SF Mono,SFMono-Regular,Consolas,Liberation Mono,Menlo,monospace}.chat-msg-prose blockquote{opacity:.8;margin:1.3em 0;padding:0 0 0 1.1em;font-style:italic}.chat-msg-prose blockquote p{margin:.15em 0}.chat-msg-prose table{background:var(--color-theme-0);border-collapse:separate;border-spacing:0;border:1px solid var(--color-theme-200);border-radius:.625rem;width:100%;margin:1.4em 0;font-size:.9em;line-height:1.45;overflow:hidden}.chat-msg-prose th,.chat-msg-prose td{text-align:left;padding:.65em .8em}.chat-msg-prose th{font-weight:600}.chat-msg-prose td{border-top:1px solid var(--color-theme-200)}@supports (color:color-mix(in lab, red, red)){.chat-msg-prose td{border-top:1px solid color-mix(in oklch, var(--color-theme-200) 45%, transparent)}}.chat-msg-prose td{color:currentColor}@supports (color:color-mix(in lab, red, red)){.chat-msg-prose td{color:color-mix(in oklch, currentColor 75%, transparent)}}.chat-msg-prose td:first-child{color:inherit}.chat-msg-prose [align=center]{text-align:center}.chat-msg-prose [align=right]{text-align:right}.chat-msg-prose [align=left]{text-align:left}.chat-msg-prose hr{border:none;border-top:1px solid var(--color-theme-200)}@supports (color:color-mix(in lab, red, red)){.chat-msg-prose hr{border-top:1px solid color-mix(in oklch, var(--color-theme-200) 42%, transparent)}}.chat-msg-prose hr{margin:1.2em 0}.chat-msg-prose img{border-radius:.5rem;max-width:100%;height:auto;margin:.6em 0}.chat-msg-prose p+p{margin-top:.65em}.chat-msg-prose p+ul,.chat-msg-prose p+ol{margin-top:.4em}.chat-msg-prose h1+p,.chat-msg-prose h2+p,.chat-msg-prose h3+p{margin-top:.2em}@property --tw-translate-x{syntax:"*";inherits:false;initial-value:0}@property --tw-translate-y{syntax:"*";inherits:false;initial-value:0}@property --tw-translate-z{syntax:"*";inherits:false;initial-value:0}@property --tw-scale-x{syntax:"*";inherits:false;initial-value:1}@property --tw-scale-y{syntax:"*";inherits:false;initial-value:1}@property --tw-scale-z{syntax:"*";inherits:false;initial-value:1}@property --tw-rotate-x{syntax:"*";inherits:false}@property --tw-rotate-y{syntax:"*";inherits:false}@property --tw-rotate-z{syntax:"*";inherits:false}@property --tw-skew-x{syntax:"*";inherits:false}@property --tw-skew-y{syntax:"*";inherits:false}@property --tw-space-y-reverse{syntax:"*";inherits:false;initial-value:0}@property --tw-border-style{syntax:"*";inherits:false;initial-value:solid}@property --tw-gradient-position{syntax:"*";inherits:false}@property --tw-gradient-from{syntax:"<color>";inherits:false;initial-value:#0000}@property --tw-gradient-via{syntax:"<color>";inherits:false;initial-value:#0000}@property --tw-gradient-to{syntax:"<color>";inherits:false;initial-value:#0000}@property --tw-gradient-stops{syntax:"*";inherits:false}@property --tw-gradient-via-stops{syntax:"*";inherits:false}@property --tw-gradient-from-position{syntax:"<length-percentage>";inherits:false;initial-value:0%}@property --tw-gradient-via-position{syntax:"<length-percentage>";inherits:false;initial-value:50%}@property --tw-gradient-to-position{syntax:"<length-percentage>";inherits:false;initial-value:100%}@property --tw-leading{syntax:"*";inherits:false}@property --tw-font-weight{syntax:"*";inherits:false}@property --tw-tracking{syntax:"*";inherits:false}@property --tw-ordinal{syntax:"*";inherits:false}@property --tw-slashed-zero{syntax:"*";inherits:false}@property --tw-numeric-figure{syntax:"*";inherits:false}@property --tw-numeric-spacing{syntax:"*";inherits:false}@property --tw-numeric-fraction{syntax:"*";inherits:false}@property --tw-shadow{syntax:"*";inherits:false;initial-value:0 0 #0000}@property --tw-shadow-color{syntax:"*";inherits:false}@property --tw-shadow-alpha{syntax:"<percentage>";inherits:false;initial-value:100%}@property --tw-inset-shadow{syntax:"*";inherits:false;initial-value:0 0 #0000}@property --tw-inset-shadow-color{syntax:"*";inherits:false}@property --tw-inset-shadow-alpha{syntax:"<percentage>";inherits:false;initial-value:100%}@property --tw-ring-color{syntax:"*";inherits:false}@property --tw-ring-shadow{syntax:"*";inherits:false;initial-value:0 0 #0000}@property --tw-inset-ring-color{syntax:"*";inherits:false}@property --tw-inset-ring-shadow{syntax:"*";inherits:false;initial-value:0 0 #0000}@property --tw-ring-inset{syntax:"*";inherits:false}@property --tw-ring-offset-width{syntax:"<length>";inherits:false;initial-value:0}@property --tw-ring-offset-color{syntax:"*";inherits:false;initial-value:#fff}@property --tw-ring-offset-shadow{syntax:"*";inherits:false;initial-value:0 0 #0000}@property --tw-blur{syntax:"*";inherits:false}@property --tw-brightness{syntax:"*";inherits:false}@property --tw-contrast{syntax:"*";inherits:false}@property --tw-grayscale{syntax:"*";inherits:false}@property --tw-hue-rotate{syntax:"*";inherits:false}@property --tw-invert{syntax:"*";inherits:false}@property --tw-opacity{syntax:"*";inherits:false}@property --tw-saturate{syntax:"*";inherits:false}@property --tw-sepia{syntax:"*";inherits:false}@property --tw-drop-shadow{syntax:"*";inherits:false}@property --tw-drop-shadow-color{syntax:"*";inherits:false}@property --tw-drop-shadow-alpha{syntax:"<percentage>";inherits:false;initial-value:100%}@property --tw-drop-shadow-size{syntax:"*";inherits:false}@property --tw-backdrop-blur{syntax:"*";inherits:false}@property --tw-backdrop-brightness{syntax:"*";inherits:false}@property --tw-backdrop-contrast{syntax:"*";inherits:false}@property --tw-backdrop-grayscale{syntax:"*";inherits:false}@property --tw-backdrop-hue-rotate{syntax:"*";inherits:false}@property --tw-backdrop-invert{syntax:"*";inherits:false}@property --tw-backdrop-opacity{syntax:"*";inherits:false}@property --tw-backdrop-saturate{syntax:"*";inherits:false}@property --tw-backdrop-sepia{syntax:"*";inherits:false}@property --tw-duration{syntax:"*";inherits:false}@property --tw-ease{syntax:"*";inherits:false}@keyframes spin{to{transform:rotate(360deg)}}@keyframes ping{75%,to{opacity:0;transform:scale(2)}}@keyframes pulse{50%{opacity:.5}}`,ML={"data-test":"auth-panel",class:"flex flex-col justify-end h-full px-5 pb-8 pt-6"},LL={class:"flex-1 flex flex-col justify-center"},VL={key:0,class:"text-xs text-red-500 mb-4"},FL={class:"space-y-3"},BL={key:0},ZL={key:1,class:"space-y-3"},HL={key:2,class:"space-y-3"},KL={class:"text-xs text-theme-400"},WL=Pe({__name:"ElAuthPanel",props:{sdk:{}},setup(e){let t=Q(!1),n=Q("email"),i=Q({email:"",code:""}),r=Q(!1);function o(){e.sdk.error.value=null,e.sdk.auth.loginWithGoogle({onError:l=>{e.sdk.error.value=l}})}async function a(){if(!r.value){r.value=!0,e.sdk.error.value=null;try{await e.sdk.auth.requestAuthCode({email:i.value.email})&&(n.value="code")}finally{r.value=!1}}}async function s(){if(!r.value){r.value=!0,e.sdk.error.value=null;try{await e.sdk.auth.loginWithCode({email:i.value.email,code:i.value.code})}finally{r.value=!1}}}return(l,u)=>(w(),$("div",ML,[b("div",LL,[u[4]||(u[4]=b("div",{class:"space-y-3 mb-10"},[b("h3",{class:"text-2xl font-light text-theme-900 leading-snug"},[xt(" Your AI assistant,"),b("br"),xt("ready in two minutes. ")]),b("p",{class:"text-sm text-theme-400 leading-relaxed max-w-[260px]"}," Sign in to create and deploy a personal AI that works for you. ")],-1)),e.sdk.error.value?(w(),$("p",VL,de(e.sdk.error.value),1)):te("",!0)]),b("div",FL,[b("button",{"data-test":"google-auth-btn",class:"w-full flex items-center justify-center gap-3 px-5 py-3.5 rounded-xl border border-theme-200 bg-theme-0 text-theme-800 font-medium text-sm transition-all duration-150 hover:border-theme-300 hover:bg-theme-25 active:scale-[0.98] cursor-pointer",onClick:o},[...u[5]||(u[5]=[WS('<svg class="size-[18px]" viewBox="0 0 24 24"><path d="M22.56 12.25c0-.78-.07-1.53-.2-2.25H12v4.26h5.92a5.06 5.06 0 0 1-2.2 3.32v2.77h3.57c2.08-1.92 3.28-4.74 3.28-8.1z" fill="#4285F4"></path><path d="M12 23c2.97 0 5.46-.98 7.28-2.66l-3.57-2.77c-.98.66-2.23 1.06-3.71 1.06-2.86 0-5.29-1.93-6.16-4.53H2.18v2.84C3.99 20.53 7.7 23 12 23z" fill="#34A853"></path><path d="M5.84 14.09c-.22-.66-.35-1.36-.35-2.09s.13-1.43.35-2.09V7.07H2.18C1.43 8.55 1 10.22 1 12s.43 3.45 1.18 4.93l2.85-2.22.81-.62z" fill="#FBBC05"></path><path d="M12 5.38c1.62 0 3.06.56 4.21 1.64l3.15-3.15C17.45 2.09 14.97 1 12 1 7.7 1 3.99 3.47 2.18 7.07l3.66 2.84c.87-2.6 3.3-4.53 6.16-4.53z" fill="#EA4335"></path></svg> Continue with Google ',2)])]),u[8]||(u[8]=b("div",{class:"flex items-center gap-3 py-1"},[b("div",{class:"flex-1 h-px bg-theme-100"}),b("span",{class:"text-[11px] text-theme-300 uppercase tracking-widest"},"or"),b("div",{class:"flex-1 h-px bg-theme-100"})],-1)),t.value?te("",!0):(w(),$("div",BL,[b("button",{"data-test":"email-auth-link",class:"w-full px-5 py-3 rounded-xl border border-theme-100 text-sm text-theme-500 transition-all duration-150 hover:border-theme-200 hover:text-theme-700 cursor-pointer",onClick:u[0]||(u[0]=d=>t.value=!0)}," Use email instead ")])),t.value&&n.value==="email"?(w(),$("div",ZL,[be(jp,{modelValue:i.value.email,"onUpdate:modelValue":u[1]||(u[1]=d=>i.value.email=d),"data-test":"auth-email-input",onKeyup:Gn(a,["enter"])},null,8,["modelValue"]),be(Xa,{"data-test":"auth-send-code",theme:"dark",size:"md",class:"w-full",loading:r.value,disabled:!i.value.email||r.value,onClick:a},{default:ot(()=>[...u[6]||(u[6]=[xt(" Send verification code ",-1)])]),_:1},8,["loading","disabled"])])):te("",!0),t.value&&n.value==="code"?(w(),$("div",HL,[b("p",KL," Code sent to "+de(i.value.email),1),be(Mp,{modelValue:i.value.code,"onUpdate:modelValue":u[2]||(u[2]=d=>i.value.code=d),length:6,"focus-first":!0,"data-test":"auth-code-input",onAutoSubmit:s},null,8,["modelValue"]),be(Xa,{"data-test":"auth-verify-code",theme:"dark",size:"md",class:"w-full",loading:r.value,disabled:i.value.code.length!==6||r.value,onClick:s},{default:ot(()=>[...u[7]||(u[7]=[xt(" Verify ",-1)])]),_:1},8,["loading","disabled"]),b("button",{class:"w-full text-xs text-theme-300 hover:text-theme-500 transition-colors py-1 cursor-pointer",onClick:u[3]||(u[3]=d=>n.value="email")}," Use a different email ")])):te("",!0)])]))}}),qL={"data-test":"create-panel",class:"flex flex-col justify-end h-full px-5 pb-8 pt-6"},GL={class:"flex-1 flex flex-col justify-center"},JL={key:0,class:"text-xs text-red-500 mb-4"},YL={class:"space-y-3"},XL=["disabled"],QL=Pe({__name:"ElCreateBot",props:{sdk:{}},emits:["created"],setup(e,{emit:t}){let n=t,i=Q(""),r=Q(!1),o=Q(null);async function a(){if(!r.value&&i.value.trim()){r.value=!0,o.value=null;try{let s=e.sdk.currentOrg.value?.orgId??e.sdk.activeUser.value?.orgs?.[0]?.orgId;if(!s)throw Error("No workspace found. Please sign in again.");let l=await e.sdk.computer.create({orgId:s,primaryBot:{name:i.value.trim()}});n("created",l)}catch(s){o.value=s instanceof Error?s.message:"Failed to create bot"}finally{r.value=!1}}}return(s,l)=>(w(),$("div",qL,[b("div",GL,[l[1]||(l[1]=b("div",{class:"space-y-3 mb-10"},[b("h3",{class:"text-2xl font-light text-theme-900 leading-snug"},[xt(" What should we call"),b("br"),xt("your assistant? ")]),b("p",{class:"text-sm text-theme-400 leading-relaxed max-w-[260px]"}," Pick a name. You can change it later. ")],-1)),o.value?(w(),$("p",JL,de(o.value),1)):te("",!0)]),b("div",YL,[ep(b("input",{"onUpdate:modelValue":l[0]||(l[0]=u=>i.value=u),"data-test":"bot-name-input",type:"text",placeholder:"e.g. Alex, Casey, Jordan",class:"w-full px-4 py-3 text-theme-900 placeholder-theme-300 bg-theme-0 border border-theme-200 rounded-xl focus:outline-none focus:border-theme-900 transition-colors",style:{"font-size":"16px"},onKeyup:Gn(a,["enter"])},null,544),[[dp,i.value]]),b("button",{"data-test":"bot-create-btn",class:"w-full px-5 py-3.5 rounded-xl bg-primary-600 text-white text-sm font-medium transition-all duration-150 hover:bg-primary-500 active:scale-[0.98] disabled:opacity-50 disabled:cursor-not-allowed cursor-pointer",disabled:!i.value.trim()||r.value,onClick:a},de(r.value?"Creating...":"Create assistant"),9,XL)])]))}}),eV={"data-test":"provisioning-panel",class:"flex flex-col items-center justify-center h-full p-6"},tV={class:"w-full max-w-xs space-y-6 text-center"},rV={class:"text-sm text-theme-500"},nV={class:"text-sm text-red-500"},iV=Pe({__name:"ElProvisioningStatus",props:{sdk:{},computerId:{}},emits:["ready","error"],setup(e,{emit:t}){let n=e,i=t,r=Q("Setting up your assistant\u2026"),o=Q(!1),a=Q(""),s={starting:"Starting your assistant\u2026",running:"Ready!",stopped:"Setting up your assistant\u2026"};async function l(){o.value=!1,a.value="";try{await n.sdk.computer.waitUntilReady({computerId:n.computerId,onStatus:u=>{r.value=s[u]??"Setting up your assistant\u2026"}}),i("ready")}catch(u){o.value=!0,a.value=u instanceof Error?u.message:"Something went wrong",i("error",a.value)}}return Ut(()=>{l()}),(u,d)=>(w(),$("div",eV,[b("div",tV,[o.value?(w(),$(ge,{key:1},[b("p",nV,de(a.value),1),b("button",{"data-test":"provision-retry-btn",class:"px-6 py-2.5 rounded-lg bg-primary-600 text-white text-sm font-medium hover:bg-primary-500 transition-colors cursor-pointer",onClick:l}," Try again ")],64)):(w(),$(ge,{key:0},[d[0]||(d[0]=b("div",{class:"flex justify-center"},[b("div",{class:"animate-spin rounded-full size-6 border-2 border-theme-200 border-t-primary-500"})],-1)),b("p",rV,de(r.value),1)],64))])]))}});function oV(e){return e.hasToken?e.hasBot?e.isNewBot?e.provisionError?"error":e.botReady?"chat":"provisioning":"chat":"create":"auth"}var aV=["data-test-state"],sV={class:"flex items-center justify-between px-4 py-3 border-b border-theme-100"},lV={class:"text-sm font-medium text-theme-800"},cV={class:"flex-1 overflow-hidden"},uV={key:4,class:"flex flex-col items-center justify-center h-full p-6"},dV={class:"w-full max-w-xs space-y-6 text-center"},pV={class:"text-sm text-red-500"},mV={key:0,class:"border-t border-theme-100 px-4 py-2 text-center"},fV=["href"],hV=Pe({__name:"BotWidgetOnboard",props:{sdk:{},onClose:{type:Function}},setup(e){let t=e,n=t.sdk||Yl.getInstance({isDev:typeof window<"u"?window.location.hostname==="localhost"||window.location.hostname.includes("127.0.0.1"):!1}),i=We(),r=Q(!1),o=Q(),a=Q(!1),s=R(()=>i.value??n.currentBot.value),l=We(),u=We();mt(()=>s.value?.botId.value,k=>{if(!k||!s.value){l.value=void 0,u.value=void 0;return}let T=s.value;l.value=T,u.value=new sc({sdk:n,bot:T,chatStreamFn:async S=>{await n.chat.chatStreamAuthenticated({botId:k,orgId:T.computer.orgId.value,message:S.message,attachments:S.attachments?.map(z=>Y0.parse(z)),conversationId:S.conversationId,history:S.history,onDelta:S.onDelta,onDone:S.onDone,onError:S.onError,onStatus:S.onStatus,onToolActivity:S.onToolActivity,onWorkingEnd:S.onWorkingEnd})}})},{immediate:!0});let d=R(()=>oV({hasToken:!!n.token.value,hasBot:!!s.value,isNewBot:a.value,botReady:r.value,provisionError:o.value})),p=R(()=>`${Qn(n.apiBase,n.isDev)}/`);function m(k){i.value=k,o.value=void 0,r.value=!1,a.value=!0}function f(){r.value=!0}function h(k){o.value=k}function v(){o.value=void 0,r.value=!1}return(k,T)=>(w(),$("div",{class:"size-full flex flex-col bg-theme-0","data-test":"onboard-widget","data-test-state":d.value},[b("div",sV,[b("span",lV,de(s.value?.name.value||"PageLines"),1),t.onClose?(w(),$("button",{key:0,class:"text-theme-400 hover:text-theme-600 transition-colors cursor-pointer",onClick:T[0]||(T[0]=S=>t.onClose?.())},[...T[1]||(T[1]=[b("svg",{xmlns:"http://www.w3.org/2000/svg",class:"size-5",viewBox:"0 0 20 20",fill:"currentColor"},[b("path",{"fill-rule":"evenodd",d:"M4.293 4.293a1 1 0 011.414 0L10 8.586l4.293-4.293a1 1 0 111.414 1.414L11.414 10l4.293 4.293a1 1 0 01-1.414 1.414L10 11.414l-4.293 4.293a1 1 0 01-1.414-1.414L8.586 10 4.293 5.707a1 1 0 010-1.414z","clip-rule":"evenodd"})],-1)])])):te("",!0)]),b("div",cV,[d.value==="auth"?(w(),Fe(WL,{key:0,sdk:Ae(n)},null,8,["sdk"])):te("",!0),d.value==="create"?(w(),Fe(QL,{key:1,sdk:Ae(n),onCreated:m},null,8,["sdk"])):te("",!0),d.value==="provisioning"&&s.value?(w(),Fe(iV,{key:2,sdk:Ae(n),"computer-id":s.value.computerId.value,onReady:f,onError:h},null,8,["sdk","computer-id"])):te("",!0),d.value==="chat"&&l.value&&u.value?(w(),Fe(yo,{key:3,"chat-controller":u.value,bot:l.value,variant:"light",class:"size-full"},null,8,["chat-controller","bot"])):te("",!0),d.value==="error"?(w(),$("div",uV,[b("div",dV,[b("p",pV,de(o.value),1),b("button",{class:"px-6 py-2.5 rounded-lg bg-primary-600 text-white text-sm font-medium hover:bg-primary-500 transition-colors cursor-pointer",onClick:v}," Try again ")])])):te("",!0)]),d.value==="chat"?(w(),$("div",mV,[b("a",{href:p.value,target:"_blank",class:"text-xs text-theme-400 hover:text-primary-600 transition-colors"}," Go to Dashboard \u2192 ",8,fV)])):te("",!0)],8,aV))}}),gV={class:"relative size-16 rounded-full overflow-hidden"},vV=["src","alt"],bV={class:"flex items-center shrink-0 border-b border-theme-100 px-4 py-3"},yV={class:"flex items-center gap-3 flex-1 min-w-0"},wV=["src","alt"],kV={class:"min-w-0"},xV={class:"text-sm font-medium text-theme-900 truncate"},_V={class:"flex-1 overflow-hidden"},$V={class:"shrink-0 flex items-center justify-center border-t border-theme-100 py-1.5"},SV=["href"],IV=Up(Pe({__name:"BotWidgetPopup",props:{sdk:{},handle:{},bot:{},context:{},firstMessage:{},position:{},chatController:{}},setup(e,{expose:t}){let n=e,i=Q(!1),r=Q(!1),o=We(),{currentBot:a,currentContext:s,currentFirstMessage:l,update:u}=es(n),d=R(()=>({"bottom-left":"bottom-4 left-4 sm:bottom-6 sm:left-6","top-right":"top-4 right-4 sm:top-6 sm:right-6","top-left":"top-4 left-4 sm:top-6 sm:left-6","bottom-right":"bottom-4 right-4 sm:bottom-6 sm:right-6"})[n.position||"bottom-right"]),p=R(()=>({"bottom-left":"bottom left","top-right":"top right","top-left":"top left","bottom-right":"bottom right"})[n.position||"bottom-right"]),m=R(()=>({"bottom-left":"bottom-0 left-0","top-right":"top-0 right-0","top-left":"top-0 left-0","bottom-right":"bottom-0 right-0"})[n.position||"bottom-right"]);function f(T,S){n.chatController||o.value||(o.value=new sc({sdk:S,bot:T,context:s.value,firstMessage:l.value}))}mt(i,async T=>{if(!T||r.value)return;r.value=!0;let S=n.chatController||o.value;if(S)try{await S.startTextConversation()}catch(z){console.error("BotWidgetPopup: startTextConversation failed",z)}});function h(){i.value=!i.value}function v(){i.value=!0}function k(){i.value=!1}return t({toggle:h,open:v,close:k,update:u}),(T,S)=>(w(),Fe(Vp,{sdk:e.sdk,handle:e.handle,bot:Ae(a),context:Ae(s),"first-message":Ae(l)},{default:ot(({bot:z,sdk:j})=>[z?(w(),$("div",{key:0,ref:()=>f(z,j),class:V(["fixed z-[999999] pointer-events-auto",d.value])},[b("div",{class:V(["widget-container transform-gpu overflow-hidden",i.value?"w-[min(400px,calc(100vw-2rem))] h-[min(600px,calc(100vh-4rem))] shadow-[0_24px_80px_-12px_rgba(0,0,0,0.2),0_8px_24px_-8px_rgba(0,0,0,0.08)]":"w-16 h-16 shadow-[0_8px_32px_-4px_rgba(0,0,0,0.15)] cursor-pointer"]),style:Se({"border-radius":i.value?"16px":"32px","transform-origin":p.value}),onClick:S[0]||(S[0]=O=>i.value?void 0:h())},[b("div",{class:V(["absolute size-16 transition-opacity duration-200",[m.value,i.value?"opacity-0 pointer-events-none":"opacity-100"]])},[b("div",gV,[b("img",{src:Ae(dE)(z.toData()),alt:`${z.name.value} bot`,class:"h-full w-full object-cover pointer-events-none",width:"64",height:"64"},null,8,vV),S[1]||(S[1]=b("div",{class:"absolute inset-0 pointer-events-none bg-gradient-to-br from-transparent via-black/10 to-black/40 opacity-60"},null,-1))])],2),b("div",{class:V(["absolute inset-0 flex flex-col bg-white transition-opacity duration-250",i.value?"opacity-100":"opacity-0 pointer-events-none"])},[b("div",bV,[b("div",yV,[b("img",{src:z.avatarUrl.value,alt:z.name.value,class:"size-8 rounded-full object-cover shrink-0"},null,8,wV),b("div",kV,[b("div",xV,de(z.displayName.value),1),b("div",{class:V(["text-[11px]",z.desiredStatus.value==="active"?"text-green-500":"text-theme-400"])},de(z.desiredStatus.value==="active"?"Online":"Offline"),3)])]),b("button",{class:"cursor-pointer flex items-center justify-center p-2 -mr-1 rounded-xl text-theme-400 hover:text-theme-600 hover:bg-theme-50 transition-colors",onClick:Et(k,["stop"])},[...S[2]||(S[2]=[b("i",{class:"size-5 i-tabler-x"},null,-1)])])]),b("div",_V,[r.value?(w(),Fe(yo,{key:0,"chat-controller":e.chatController||o.value,bot:z,variant:"light","setup-hint":"","empty-state-message":"Send a message to get started"},null,8,["chat-controller","bot"])):te("",!0)]),b("div",$V,[b("a",{href:Ae(Hl).urls.app,target:"_blank",rel:"noopener",class:"text-[10px] text-theme-300 hover:text-theme-400 transition-colors"}," Learning Bot\u2122 by PageLines ",8,SV)])],2)],6),z.desiredStatus.value==="active"?(w(),$("div",{key:0,class:V(["absolute top-[5%] right-[5%] transition-opacity duration-200 pointer-events-none",i.value?"opacity-0":"opacity-100"])},[...S[3]||(S[3]=[b("div",{class:"size-3 bg-green-500 rounded-full ring-2 ring-white absolute animate-ping",style:{"animation-duration":"5s"}},null,-1),b("div",{class:"size-3 bg-green-500 rounded-full ring-2 ring-white"},null,-1)])],2)):te("",!0)],2)):te("",!0)]),_:1},8,["sdk","handle","bot","context","first-message"]))}}),[["__scopeId","data-v-5674cae2"]]),zn=co("PLWidget"),dc=class ko{static create(t){return new ko(t)}static collectPageContext(){if(typeof window>"u"||typeof document>"u")return"";let t=[],n=window.location.href;n&&t.push(`Page URL: ${n}`);let i=document.title;i&&t.push(`Page title: ${i}`);let r=document.querySelector('meta[name="description"]')?.getAttribute("content");r&&t.push(`Page description: ${r}`);let o=document.querySelector('meta[property="og:title"]')?.getAttribute("content");o&&o!==i&&t.push(`OG title: ${o}`);let a=document.referrer;a&&t.push(`Referrer: ${a}`);let s=window.location.pathname;return s&&s!=="/"&&t.push(`Path: ${s}`),t.join(`
|
|
170
170
|
`)}constructor(t){G(this,"app",null),G(this,"shadowRoot",null),G(this,"widgetInstance",null),G(this,"config",void 0),G(this,"sdk",void 0),G(this,"container",null);let n=[ko.collectPageContext(),t.context||""].filter(Boolean).join(`
|
|
171
171
|
|
|
172
|
-
`);if(this.config={...t,context:n||void 0},!t.mode)throw Error("PLWidget: mode is required");if(!t.handle&&!t.bot&&t.mode!=="onboard")throw Error("PLWidget: either handle or bot is required");if(t.mode!=="modal"&&t.mode!=="button"&&t.mode!=="onboard"&&!t.el)throw Error(`PLWidget: el (HTMLElement) is required for ${t.mode} mode`);if(t.mode==="modal"||t.mode==="onboard"){let r=t.handle||t.bot?.botId.value||"default",o=ko.modalInstances.get(r);o&&(zn.warn(`Destroying existing modal widget for: ${r}`),o.destroy()),ko.modalInstances.set(r,this)}let i=typeof window<"u"?window.location.hostname==="localhost"||window.location.hostname.includes("127.0.0.1"):!1;this.sdk=Yl.getInstance({isDev:i,...t.apiBase&&{apiBase:t.apiBase}}),zn.info(`Initializing ${t.mode} mode for @${t.handle||t.bot?.handle} (isDev: ${i})`),this.init().catch(r=>{zn.error("PLWidget init failed",{error:r})})}async init(){if(this.config.mode==="button"){await this.mountMode(this.config.el);return}this.config.mode==="modal"||this.config.mode==="onboard"?(this.container=document.createElement("div"),this.container.id=`pagelines-modal-${this.config.handle||this.config.bot?.botId.value||"widget"}`,this.container.style.cssText="position: fixed; inset: 0; z-index: 9999;",document.body.appendChild(this.container),this.shadowRoot=this.container.attachShadow({mode:"open"})):this.shadowRoot=this.config.el.attachShadow({mode:"open"});let t=document.createElement("style");t.textContent=
|
|
172
|
+
`);if(this.config={...t,context:n||void 0},!t.mode)throw Error("PLWidget: mode is required");if(!t.handle&&!t.bot&&t.mode!=="onboard")throw Error("PLWidget: either handle or bot is required");if(t.mode!=="modal"&&t.mode!=="button"&&t.mode!=="onboard"&&!t.el)throw Error(`PLWidget: el (HTMLElement) is required for ${t.mode} mode`);if(t.mode==="modal"||t.mode==="onboard"){let r=t.handle||t.bot?.botId.value||"default",o=ko.modalInstances.get(r);o&&(zn.warn(`Destroying existing modal widget for: ${r}`),o.destroy()),ko.modalInstances.set(r,this)}let i=typeof window<"u"?window.location.hostname==="localhost"||window.location.hostname.includes("127.0.0.1"):!1;this.sdk=Yl.getInstance({isDev:i,...t.apiBase&&{apiBase:t.apiBase}}),zn.info(`Initializing ${t.mode} mode for @${t.handle||t.bot?.handle} (isDev: ${i})`),this.init().catch(r=>{zn.error("PLWidget init failed",{error:r})})}async init(){if(this.config.mode==="button"){await this.mountMode(this.config.el);return}this.config.mode==="modal"||this.config.mode==="onboard"?(this.container=document.createElement("div"),this.container.id=`pagelines-modal-${this.config.handle||this.config.bot?.botId.value||"widget"}`,this.container.style.cssText="position: fixed; inset: 0; z-index: 9999;",document.body.appendChild(this.container),this.shadowRoot=this.container.attachShadow({mode:"open"})):this.shadowRoot=this.config.el.attachShadow({mode:"open"});let t=document.createElement("style");t.textContent=jL,this.shadowRoot.appendChild(t);let n=document.createElement("div");n.id="pagelines-widget-root",n.style.cssText="width: 100%; height: 100%;",this.shadowRoot.appendChild(n),await this.mountMode(n)}async mountMode(t){let{mode:n}=this.config;if(n==="inline"){let{default:i}=await Promise.resolve().then(()=>(ME(),jE));this.app=Bl(i,{sdk:this.sdk,handle:this.config.handle,bot:this.config.bot,context:this.config.context,firstMessage:this.config.firstMessage,buttonText:this.config.buttonText,buttonIcon:this.config.buttonIcon,chatOnly:this.config.chatOnly}),this.widgetInstance=this.app.mount(t)}else if(n==="button"){if(!this.config.el)throw Error("PLWidget: el is required for button mode");let i=this.config.el;i.style.cursor="pointer";let r=()=>{ko.create({mode:"modal",handle:this.config.handle,bot:this.config.bot,context:this.config.context,firstMessage:this.config.firstMessage,buttonText:this.config.buttonText,buttonIcon:this.config.buttonIcon,chatOnly:this.config.chatOnly,onClose:this.config.onClose})};i.addEventListener("click",r),this.destroy=()=>{i.removeEventListener("click",r),zn.info(`Button mode widget destroyed for handle: ${this.config.handle}`)}}else if(n==="popup")this.app=Bl(IV,{sdk:this.sdk,handle:this.config.handle,bot:this.config.bot,context:this.config.context,firstMessage:this.config.firstMessage,buttonText:this.config.buttonText,buttonIcon:this.config.buttonIcon,position:this.config.position||"bottom-right",chatOnly:this.config.chatOnly,chatController:this.config.chatController}),this.widgetInstance=this.app.mount(t);else if(n==="modal"){let{default:i}=await Promise.resolve().then(()=>(VE(),LE));this.app=Bl(i,{sdk:this.sdk,handle:this.config.handle,bot:this.config.bot,context:this.config.context,firstMessage:this.config.firstMessage,buttonText:this.config.buttonText,buttonIcon:this.config.buttonIcon,chatOnly:this.config.chatOnly,onClose:()=>{this.config.onClose&&this.config.onClose(),this.destroy()}}),this.widgetInstance=this.app.mount(t)}else if(n==="onboard")this.app=Bl(hV,{sdk:this.sdk,onClose:()=>{this.config.onClose&&this.config.onClose(),this.destroy()}}),this.widgetInstance=this.app.mount(t);else throw Error("PLWidget: unsupported mode")}update(t){this.widgetInstance?.update?(this.widgetInstance.update(t),zn.info(`Widget updated: ${Object.keys(t).join(", ")}`)):zn.warn("Widget instance does not support update()")}toggle(){this.widgetInstance?.toggle?this.widgetInstance.toggle():zn.warn("Widget mode does not support toggle()")}open(){this.widgetInstance?.open?this.widgetInstance.open():zn.warn("Widget mode does not support open()")}close(){this.widgetInstance?.close?this.widgetInstance.close():zn.warn("Widget mode does not support close()")}destroy(){if(this.app&&(this.app.unmount(),this.app=null),this.shadowRoot&&(this.shadowRoot.innerHTML="",this.shadowRoot=null),this.config.mode==="modal"||this.config.mode==="onboard"){this.container&&(this.container.remove(),this.container=null);let t=this.config.handle||this.config.bot?.botId.value||"default";ko.modalInstances.delete(t)}this.widgetInstance=null,zn.info(`Widget destroyed for handle: ${this.config.handle||this.config.bot?.handle}`)}};G(dc,"modalInstances",new Map);var Kr={info:(...e)=>console.log("[PLWidget]",...e),error:(...e)=>console.error("[PLWidget]",...e)},An=new Map,BE=!0,ts=null;function Hp(e){if(An.has(e))return An.get(e)||null;let t=e.getAttribute("data-pagelines-bot"),n=e.getAttribute("data-mode");if(!t)return Kr.error("data-pagelines-bot requires a bot handle as its value"),null;if(!n||!["inline","button","popup","modal"].includes(n))return Kr.error("Invalid or missing data-mode. Must be: inline|button|popup|modal"),null;try{let i={el:e,mode:n,handle:t,context:e.getAttribute("data-context")||void 0,firstMessage:e.getAttribute("data-first-message")||void 0,buttonText:e.getAttribute("data-button-text")||void 0,buttonIcon:e.getAttribute("data-button-icon")||void 0,position:e.getAttribute("data-position")||"bottom-right",chatOnly:e.hasAttribute("data-chat-only"),apiBase:e.getAttribute("data-api-base")||void 0},r=new dc(i);return An.set(e,r),Kr.info(` \u2713 Initialized ${n} widget for @${t}`),r}catch(i){return Kr.error(`Failed to initialize widget: ${i instanceof Error?i.message:String(i)}`),null}}function EV(){let e=document.querySelectorAll("[data-pagelines-bot]");e.length!==0&&(Kr.info(`Found ${e.length} data-pagelines-bot element(s)`),e.forEach(t=>{Hp(t)}))}function TV(e,t){let n=An.get(e);if(n){if(t==="data-pagelines-bot"){Kr.info("Handle changed, reinitializing widget"),n.destroy(),An.delete(e),Hp(e);return}if(t==="data-context"||t==="data-first-message"||t==="data-button-text"||t==="data-button-icon"){let i=e.getAttribute("data-context")||void 0,r=e.getAttribute("data-first-message")||void 0,o=e.getAttribute("data-button-text")||void 0,a=e.getAttribute("data-button-icon")||void 0;n.update({context:i,firstMessage:r,buttonText:o,buttonIcon:a}),Kr.info(`Updated widget: ${t}`)}}}function NV(){!BE||ts||(ts=new MutationObserver(e=>{e.forEach(t=>{if(t.type==="childList"&&(t.addedNodes.forEach(n=>{if(n.nodeType===Node.ELEMENT_NODE){let i=n;i.hasAttribute("data-pagelines-bot")&&Hp(i),i.querySelectorAll("[data-pagelines-bot]").forEach(o=>{Hp(o)})}}),t.removedNodes.forEach(n=>{if(n.nodeType===Node.ELEMENT_NODE){let i=n;An.has(i)&&(An.get(i)?.destroy(),An.delete(i),Kr.info("Widget removed from DOM, destroyed")),i.querySelectorAll("[data-pagelines-bot]").forEach(o=>{let a=An.get(o);a&&(a.destroy(),An.delete(o),Kr.info("Widget removed from DOM, destroyed"))})}})),t.type==="attributes"&&t.target.nodeType===Node.ELEMENT_NODE){let n=t.target;n.hasAttribute("data-pagelines-bot")&&t.attributeName&&TV(n,t.attributeName)}})}),ts.observe(document.body,{childList:!0,subtree:!0,attributes:!0,attributeFilter:["data-pagelines-bot","data-context","data-first-message","data-button-text","data-button-icon"]}),Kr.info("MutationObserver enabled for dynamic widget detection"))}function FE(){BE=!1,ts&&(ts.disconnect(),ts=null,Kr.info("Auto-detection disabled"))}if(typeof window<"u"){window.PLWidget=dc,window.PLWidgetAPI={disableAutoDetect:FE};let e=()=>{if(document.querySelector('script[src*="@pagelines/widget"]')?.getAttribute("data-pagelines-auto-detect")==="false"){FE(),Kr.info("Auto-detection disabled via script tag attribute");return}EV(),NV()};document.readyState==="loading"?document.addEventListener("DOMContentLoaded",e):e()}var EK=dc;})();
|