@botfabrik/engine-webclient 4.99.6 → 4.99.8

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.
@@ -13,7 +13,7 @@
13
13
  <meta name="theme-color" content="#000000" />
14
14
  <meta name="google" content="notranslate" />
15
15
  <title>Bubble Chat Client</title>
16
- <script type="module" crossorigin src="./assets/index-BN2TdcEf.js"></script>
16
+ <script type="module" crossorigin src="./assets/index-BJKe2if_.js"></script>
17
17
  <link rel="stylesheet" crossorigin href="./assets/index-nj7IqDC6.css">
18
18
  </head>
19
19
 
@@ -1,29 +1,29 @@
1
- (function(){"use strict";const at=!1;var st=Array.isArray,fn=Array.prototype.indexOf,un=Array.from,Ie=Object.defineProperty,te=Object.getOwnPropertyDescriptor,cn=Object.getOwnPropertyDescriptors,dn=Object.prototype,vn=Array.prototype,lt=Object.getPrototypeOf,ft=Object.isExtensible;function hn(){var e,t,n=new Promise((r,i)=>{e=r,t=i});return{promise:n,resolve:e,reject:t}}const S=2,Re=4,_n=8,ne=16,U=32,Y=64,ut=128,A=256,he=512,x=1024,I=2048,q=4096,W=8192,G=16384,Pe=32768,Ne=65536,ct=1<<17,dt=1<<18,ue=1<<19,pn=1<<20,Le=1<<21,De=1<<22,V=1<<23,_e=Symbol("$state"),bn=Symbol("legacy props"),wn=Symbol(""),Me=new class extends Error{name="StaleReactionError";message="The reaction that called `getAbortSignal()` was re-run or destroyed"};function mn(){throw new Error("https://svelte.dev/e/await_outside_boundary")}function gn(e){throw new Error("https://svelte.dev/e/lifecycle_outside_component")}function yn(){throw new Error("https://svelte.dev/e/async_derived_orphan")}function En(e){throw new Error("https://svelte.dev/e/effect_in_teardown")}function xn(){throw new Error("https://svelte.dev/e/effect_in_unowned_derived")}function kn(e){throw new Error("https://svelte.dev/e/effect_orphan")}function Sn(){throw new Error("https://svelte.dev/e/effect_update_depth_exceeded")}function Tn(e){throw new Error("https://svelte.dev/e/props_invalid_value")}function On(){throw new Error("https://svelte.dev/e/state_descriptors_fixed")}function Cn(){throw new Error("https://svelte.dev/e/state_prototype_fixed")}function An(){throw new Error("https://svelte.dev/e/state_unsafe_mutation")}const In=1,Rn=4,Pn=8,Nn=16,Ln=1,Dn=2,m=Symbol(),Mn="http://www.w3.org/1999/xhtml";function vt(e){return e===this.v}function Fn(e,t){return e!=e?t==t:e!==t||e!==null&&typeof e=="object"||typeof e=="function"}function Un(e){return!Fn(e,this.v)}let jn=!1,R=null;function pe(e){R=e}function be(e,t=!1,n){R={p:R,c:null,e:null,s:e,x:null,l:null}}function we(e){var t=R,n=t.e;if(n!==null){t.e=null;for(var r of n)At(r)}return R=t.p,{}}function ht(){return!0}const qn=new WeakMap;function Wn(e){var t=b;if(t===null)return p.f|=V,e;if((t.f&Pe)===0){if((t.f&ut)===0)throw!t.parent&&e instanceof Error&&_t(e),e;t.b.error(e)}else Fe(e,t)}function Fe(e,t){for(;t!==null;){if((t.f&ut)!==0)try{t.b.error(e);return}catch(n){e=n}t=t.parent}throw e instanceof Error&&_t(e),e}function _t(e){const t=qn.get(e);t&&(Ie(e,"message",{value:t.message}),Ie(e,"stack",{value:t.stack}))}function Bn(){for(var e=b.b;e!==null&&!e.has_pending_snippet();)e=e.parent;return e===null&&mn(),e}function Ue(e){var t=S|I,n=p!==null&&(p.f&S)!==0?p:null;return b===null||n!==null&&(n.f&A)!==0?t|=A:b.f|=ue,{ctx:R,deps:null,effects:null,equals:vt,f:t,fn:e,reactions:null,rv:0,v:m,wv:0,parent:n??b,ac:null}}function Hn(e,t){let n=b;n===null&&yn();var r=n.b,i=void 0,a=Et(m),o=null,l=!p;return or(()=>{try{var s=e();o&&Promise.resolve(s).catch(()=>{})}catch(c){s=Promise.reject(c)}var f=()=>s;i=o?.then(f,f)??Promise.resolve(s),o=i;var u=E,d=r.pending;l&&(r.update_pending_count(1),d||u.increment());const h=(c,v=void 0)=>{o=null,d||u.activate(),v?v!==Me&&(a.f|=V,He(a,v)):((a.f&V)!==0&&(a.f^=V),He(a,c)),l&&(r.update_pending_count(-1),d||u.decrement()),wt()};if(i.then(h,c=>h(null,c||"unknown")),u)return()=>{queueMicrotask(()=>u.neuter())}}),new Promise(s=>{function f(u){function d(){u===i?s(a):f(i)}u.then(d,d)}f(i)})}function zn(e){const t=Ue(e);return t.equals=Un,t}function pt(e){var t=e.effects;if(t!==null){e.effects=null;for(var n=0;n<t.length;n+=1)Q(t[n])}}function Yn(e){for(var t=e.parent;t!==null;){if((t.f&S)===0)return t;t=t.parent}return null}function je(e){var t,n=b;H(Yn(e));try{pt(e),t=Ht(e)}finally{H(n)}return t}function bt(e){var t=je(e);if(e.equals(t)||(e.v=t,e.wv=Wt()),!X){var n=(z||(e.f&A)!==0)&&e.deps!==null?q:x;C(e,n)}}function Gn(e,t,n){const r=Ue;if(t.length===0){n(e.map(r));return}var i=E,a=b,o=Vn(),l=Bn();Promise.all(t.map(s=>Hn(s))).then(s=>{i?.activate(),o();try{n([...e.map(r),...s])}catch(f){(a.f&G)===0&&Fe(f,a)}i?.deactivate(),wt()}).catch(s=>{l.error(s)})}function Vn(){var e=b,t=p,n=R,r=E;return function(){H(e),F(t),pe(n),r?.activate()}}function wt(){H(null),F(null),pe(null)}const qe=new Set;let E=null,mt=new Set,me=[];function gt(){const e=me.shift();me.length>0&&queueMicrotask(gt),e()}let ce=[],We=null,Be=!1;class re{current=new Map;#l=new Map;#i=new Set;#e=0;#f=null;#u=!1;#n=[];#o=[];#r=[];#t=[];#a=[];#c=[];#d=[];skipped_effects=new Set;process(t){ce=[];for(const i of t)this.#h(i);if(this.#n.length===0&&this.#e===0){this.#v();var n=this.#r,r=this.#t;this.#r=[],this.#t=[],this.#a=[],E=null,yt(n),yt(r),E===null?E=this:qe.delete(this),this.#f?.resolve()}else this.#s(this.#r),this.#s(this.#t),this.#s(this.#a);for(const i of this.#n)ae(i);for(const i of this.#o)ae(i);this.#n=[],this.#o=[]}#h(t){t.f^=x;for(var n=t.first;n!==null;){var r=n.f,i=(r&(U|Y))!==0,a=i&&(r&x)!==0,o=a||(r&W)!==0||this.skipped_effects.has(n);if(!o&&n.fn!==null){if(i)n.f^=x;else if((r&Re)!==0)this.#t.push(n);else if((r&x)===0)if((r&De)!==0){var l=n.b?.pending?this.#o:this.#n;l.push(n)}else xe(n)&&((n.f&ne)!==0&&this.#a.push(n),ae(n));var s=n.first;if(s!==null){n=s;continue}}var f=n.parent;for(n=n.next;n===null&&f!==null;)n=f.next,f=f.parent}}#s(t){for(const n of t)((n.f&I)!==0?this.#c:this.#d).push(n),C(n,x);t.length=0}capture(t,n){this.#l.has(t)||this.#l.set(t,n),this.current.set(t,t.v)}activate(){E=this}deactivate(){E=null;for(const t of mt)if(mt.delete(t),t(),E!==null)break}neuter(){this.#u=!0}flush(){ce.length>0?Kn():this.#v(),E===this&&(this.#e===0&&qe.delete(this),this.deactivate())}#v(){if(!this.#u)for(const t of this.#i)t();this.#i.clear()}increment(){this.#e+=1}decrement(){if(this.#e-=1,this.#e===0){for(const t of this.#c)C(t,I),ie(t);for(const t of this.#d)C(t,q),ie(t);this.#r=[],this.#t=[],this.flush()}else this.deactivate()}add_callback(t){this.#i.add(t)}settled(){return(this.#f??=hn()).promise}static ensure(){if(E===null){const t=E=new re;qe.add(E),re.enqueue(()=>{E===t&&t.flush()})}return E}static enqueue(t){me.length===0&&queueMicrotask(gt),me.unshift(t)}}function Kn(){var e=oe;Be=!0;try{var t=0;for(Ft(!0);ce.length>0;){var n=re.ensure();if(t++>1e3){var r,i;Zn()}n.process(ce),B.clear()}}finally{Be=!1,Ft(e),We=null}}function Zn(){try{Sn()}catch(e){Fe(e,We)}}let K=null;function yt(e){var t=e.length;if(t!==0){for(var n=0;n<t;){var r=e[n++];if((r.f&(G|W))===0&&xe(r)&&(K=[],ae(r),r.deps===null&&r.first===null&&r.nodes_start===null&&(r.teardown===null&&r.ac===null?Nt(r):r.fn=null),K?.length>0)){B.clear();for(const i of K)ae(i);K=[]}}K=null}}function ie(e){for(var t=We=e;t.parent!==null;){t=t.parent;var n=t.f;if(Be&&t===b&&(n&ne)!==0)return;if((n&(Y|U))!==0){if((n&x)===0)return;t.f^=x}}ce.push(t)}const B=new Map;function Et(e,t){var n={f:0,v:e,reactions:null,equals:vt,rv:0,wv:0};return n}function L(e,t){const n=Et(e);return ur(n),n}function D(e,t,n=!1){p!==null&&(!M||(p.f&ct)!==0)&&ht()&&(p.f&(S|ne|De|ct))!==0&&!j?.includes(e)&&An();let r=n?Z(t):t;return He(e,r)}function He(e,t){if(!e.equals(t)){var n=e.v;X?B.set(e,t):B.set(e,n),e.v=t;var r=re.ensure();r.capture(e,n),(e.f&S)!==0&&((e.f&I)!==0&&je(e),C(e,(e.f&A)===0?x:q)),e.wv=Wt(),xt(e,I),b!==null&&(b.f&x)!==0&&(b.f&(U|Y))===0&&(P===null?cr([e]):P.push(e))}return t}function ze(e){D(e,e.v+1)}function xt(e,t){var n=e.reactions;if(n!==null)for(var r=n.length,i=0;i<r;i++){var a=n[i],o=a.f,l=(o&I)===0;l&&C(a,t),(o&S)!==0?xt(a,q):l&&((o&ne)!==0&&K!==null&&K.push(a),ie(a))}}function Z(e){if(typeof e!="object"||e===null||_e in e)return e;const t=lt(e);if(t!==dn&&t!==vn)return e;var n=new Map,r=st(e),i=L(0),a=$,o=l=>{if($===a)return l();var s=p,f=$;F(null),qt(a);var u=l();return F(s),qt(f),u};return r&&n.set("length",L(e.length)),new Proxy(e,{defineProperty(l,s,f){(!("value"in f)||f.configurable===!1||f.enumerable===!1||f.writable===!1)&&On();var u=n.get(s);return u===void 0?u=o(()=>{var d=L(f.value);return n.set(s,d),d}):D(u,f.value,!0),!0},deleteProperty(l,s){var f=n.get(s);if(f===void 0){if(s in l){const u=o(()=>L(m));n.set(s,u),ze(i)}}else D(f,m),ze(i);return!0},get(l,s,f){if(s===_e)return e;var u=n.get(s),d=s in l;if(u===void 0&&(!d||te(l,s)?.writable)&&(u=o(()=>{var c=Z(d?l[s]:m),v=L(c);return v}),n.set(s,u)),u!==void 0){var h=O(u);return h===m?void 0:h}return Reflect.get(l,s,f)},getOwnPropertyDescriptor(l,s){var f=Reflect.getOwnPropertyDescriptor(l,s);if(f&&"value"in f){var u=n.get(s);u&&(f.value=O(u))}else if(f===void 0){var d=n.get(s),h=d?.v;if(d!==void 0&&h!==m)return{enumerable:!0,configurable:!0,value:h,writable:!0}}return f},has(l,s){if(s===_e)return!0;var f=n.get(s),u=f!==void 0&&f.v!==m||Reflect.has(l,s);if(f!==void 0||b!==null&&(!u||te(l,s)?.writable)){f===void 0&&(f=o(()=>{var h=u?Z(l[s]):m,c=L(h);return c}),n.set(s,f));var d=O(f);if(d===m)return!1}return u},set(l,s,f,u){var d=n.get(s),h=s in l;if(r&&s==="length")for(var c=f;c<d.v;c+=1){var v=n.get(c+"");v!==void 0?D(v,m):c in l&&(v=o(()=>L(m)),n.set(c+"",v))}if(d===void 0)(!h||te(l,s)?.writable)&&(d=o(()=>L(void 0)),D(d,Z(f)),n.set(s,d));else{h=d.v!==m;var w=o(()=>Z(f));D(d,w)}var g=Reflect.getOwnPropertyDescriptor(l,s);if(g?.set&&g.set.call(u,f),!h){if(r&&typeof s=="string"){var N=n.get("length"),_=Number(s);Number.isInteger(_)&&_>=N.v&&D(N,_+1)}ze(i)}return!0},ownKeys(l){O(i);var s=Reflect.ownKeys(l).filter(d=>{var h=n.get(d);return h===void 0||h.v!==m});for(var[f,u]of n)u.v!==m&&!(f in l)&&s.push(f);return s},setPrototypeOf(){Cn()}})}var kt,St,Tt,Ot;function Jn(){if(kt===void 0){kt=window,St=/Firefox/.test(navigator.userAgent);var e=Element.prototype,t=Node.prototype,n=Text.prototype;Tt=te(t,"firstChild").get,Ot=te(t,"nextSibling").get,ft(e)&&(e.__click=void 0,e.__className=void 0,e.__attributes=null,e.__style=void 0,e.__e=void 0),ft(n)&&(n.__t=void 0)}}function ge(e=""){return document.createTextNode(e)}function ye(e){return Tt.call(e)}function Ye(e){return Ot.call(e)}function Ge(e,t){return ye(e)}function Qn(e,t){{var n=ye(e);return n instanceof Comment&&n.data===""?Ye(n):n}}function Xn(e,t=1,n=!1){let r=e;for(;t--;)r=Ye(r);return r}function $n(){return!1}function Ct(e){var t=p,n=b;F(null),H(null);try{return e()}finally{F(t),H(n)}}function er(e){b===null&&p===null&&kn(),p!==null&&(p.f&A)!==0&&b===null&&xn(),X&&En()}function tr(e,t){var n=t.last;n===null?t.last=t.first=e:(n.next=e,e.prev=n,t.last=e)}function J(e,t,n,r=!0){var i=b;i!==null&&(i.f&W)!==0&&(e|=W);var a={ctx:R,deps:null,nodes_start:null,nodes_end:null,f:e|I,first:null,fn:t,last:null,next:null,parent:i,b:i&&i.b,prev:null,teardown:null,transitions:null,wv:0,ac:null};if(n)try{ae(a),a.f|=Pe}catch(s){throw Q(a),s}else t!==null&&ie(a);if(r){var o=a;if(n&&o.deps===null&&o.teardown===null&&o.nodes_start===null&&o.first===o.last&&(o.f&ue)===0&&(o=o.first),o!==null&&(o.parent=i,i!==null&&tr(o,i),p!==null&&(p.f&S)!==0&&(e&Y)===0)){var l=p;(l.effects??=[]).push(o)}}return a}function nr(e){er();var t=b.f,n=!p&&(t&U)!==0&&(t&Pe)===0;if(n){var r=R;(r.e??=[]).push(e)}else return At(e)}function At(e){return J(Re|pn,e,!1)}function rr(e){re.ensure();const t=J(Y|ue,e,!0);return(n={})=>new Promise(r=>{n.outro?Lt(t,()=>{Q(t),r(void 0)}):(Q(t),r(void 0))})}function ir(e){return J(Re,e,!1)}function or(e){return J(De|ue,e,!0)}function Ee(e,t=[],n=[]){Gn(t,n,r=>{J(_n,()=>e(...r.map(O)),!0)})}function It(e,t=0){var n=J(ne|t,e,!0);return n}function Ve(e,t=!0){return J(U|ue,e,!0,t)}function Rt(e){var t=e.teardown;if(t!==null){const n=X,r=p;Ut(!0),F(null);try{t.call(null)}finally{Ut(n),F(r)}}}function Pt(e,t=!1){var n=e.first;for(e.first=e.last=null;n!==null;){const i=n.ac;i!==null&&Ct(()=>{i.abort(Me)});var r=n.next;(n.f&Y)!==0?n.parent=null:Q(n,t),n=r}}function ar(e){for(var t=e.first;t!==null;){var n=t.next;(t.f&U)===0&&Q(t),t=n}}function Q(e,t=!0){var n=!1;(t||(e.f&dt)!==0)&&e.nodes_start!==null&&e.nodes_end!==null&&(sr(e.nodes_start,e.nodes_end),n=!0),Pt(e,t&&!n),ke(e,0),C(e,G);var r=e.transitions;if(r!==null)for(const a of r)a.stop();Rt(e);var i=e.parent;i!==null&&i.first!==null&&Nt(e),e.next=e.prev=e.teardown=e.ctx=e.deps=e.fn=e.nodes_start=e.nodes_end=e.ac=null}function sr(e,t){for(;e!==null;){var n=e===t?null:Ye(e);e.remove(),e=n}}function Nt(e){var t=e.parent,n=e.prev,r=e.next;n!==null&&(n.next=r),r!==null&&(r.prev=n),t!==null&&(t.first===e&&(t.first=r),t.last===e&&(t.last=n))}function Lt(e,t){var n=[];Dt(e,n,!0),lr(n,()=>{Q(e),t&&t()})}function lr(e,t){var n=e.length;if(n>0){var r=()=>--n||t();for(var i of e)i.out(r)}else t()}function Dt(e,t,n){if((e.f&W)===0){if(e.f^=W,e.transitions!==null)for(const o of e.transitions)(o.is_global||n)&&t.push(o);for(var r=e.first;r!==null;){var i=r.next,a=(r.f&Ne)!==0||(r.f&U)!==0;Dt(r,t,a?n:!1),r=i}}}function fr(e){Mt(e,!0)}function Mt(e,t){if((e.f&W)!==0){e.f^=W,(e.f&x)===0&&(C(e,I),ie(e));for(var n=e.first;n!==null;){var r=n.next,i=(n.f&Ne)!==0||(n.f&U)!==0;Mt(n,i?t:!1),n=r}if(e.transitions!==null)for(const a of e.transitions)(a.is_global||t)&&a.in()}}let oe=!1;function Ft(e){oe=e}let X=!1;function Ut(e){X=e}let p=null,M=!1;function F(e){p=e}let b=null;function H(e){b=e}let j=null;function ur(e){p!==null&&(j===null?j=[e]:j.push(e))}let k=null,T=0,P=null;function cr(e){P=e}let jt=1,de=0,$=de;function qt(e){$=e}let z=!1;function Wt(){return++jt}function xe(e){var t=e.f;if((t&I)!==0)return!0;if((t&q)!==0){var n=e.deps,r=(t&A)!==0;if(n!==null){var i,a,o=(t&he)!==0,l=r&&b!==null&&!z,s=n.length;if((o||l)&&(b===null||(b.f&G)===0)){var f=e,u=f.parent;for(i=0;i<s;i++)a=n[i],(o||!a?.reactions?.includes(f))&&(a.reactions??=[]).push(f);o&&(f.f^=he),l&&u!==null&&(u.f&A)===0&&(f.f^=A)}for(i=0;i<s;i++)if(a=n[i],xe(a)&&bt(a),a.wv>e.wv)return!0}(!r||b!==null&&!z)&&C(e,x)}return!1}function Bt(e,t,n=!0){var r=e.reactions;if(r!==null&&!j?.includes(e))for(var i=0;i<r.length;i++){var a=r[i];(a.f&S)!==0?Bt(a,t,!1):t===a&&(n?C(a,I):(a.f&x)!==0&&C(a,q),ie(a))}}function Ht(e){var t=k,n=T,r=P,i=p,a=z,o=j,l=R,s=M,f=$,u=e.f;k=null,T=0,P=null,z=(u&A)!==0&&(M||!oe||p===null),p=(u&(U|Y))===0?e:null,j=null,pe(e.ctx),M=!1,$=++de,e.ac!==null&&(Ct(()=>{e.ac.abort(Me)}),e.ac=null);try{e.f|=Le;var d=e.fn,h=d(),c=e.deps;if(k!==null){var v;if(ke(e,T),c!==null&&T>0)for(c.length=T+k.length,v=0;v<k.length;v++)c[T+v]=k[v];else e.deps=c=k;if(!z||(u&S)!==0&&e.reactions!==null)for(v=T;v<c.length;v++)(c[v].reactions??=[]).push(e)}else c!==null&&T<c.length&&(ke(e,T),c.length=T);if(ht()&&P!==null&&!M&&c!==null&&(e.f&(S|q|I))===0)for(v=0;v<P.length;v++)Bt(P[v],e);return i!==null&&i!==e&&(de++,P!==null&&(r===null?r=P:r.push(...P))),(e.f&V)!==0&&(e.f^=V),h}catch(w){return Wn(w)}finally{e.f^=Le,k=t,T=n,P=r,p=i,z=a,j=o,pe(l),M=s,$=f}}function dr(e,t){let n=t.reactions;if(n!==null){var r=fn.call(n,e);if(r!==-1){var i=n.length-1;i===0?n=t.reactions=null:(n[r]=n[i],n.pop())}}n===null&&(t.f&S)!==0&&(k===null||!k.includes(t))&&(C(t,q),(t.f&(A|he))===0&&(t.f^=he),pt(t),ke(t,0))}function ke(e,t){var n=e.deps;if(n!==null)for(var r=t;r<n.length;r++)dr(e,n[r])}function ae(e){var t=e.f;if((t&G)===0){C(e,x);var n=b,r=oe;b=e,oe=!0;try{(t&ne)!==0?ar(e):Pt(e),Rt(e);var i=Ht(e);e.teardown=typeof i=="function"?i:null,e.wv=jt;var a;at&&jn&&(e.f&I)!==0&&e.deps}finally{oe=r,b=n}}}function O(e){var t=e.f,n=(t&S)!==0;if(p!==null&&!M){var r=b!==null&&(b.f&G)!==0;if(!r&&!j?.includes(e)){var i=p.deps;if((p.f&Le)!==0)e.rv<de&&(e.rv=de,k===null&&i!==null&&i[T]===e?T++:k===null?k=[e]:(!z||!k.includes(e))&&k.push(e));else{(p.deps??=[]).push(e);var a=e.reactions;a===null?e.reactions=[p]:a.includes(p)||a.push(p)}}}else if(n&&e.deps===null&&e.effects===null){var o=e,l=o.parent;l!==null&&(l.f&A)===0&&(o.f^=A)}if(X){if(B.has(e))return B.get(e);if(n){o=e;var s=o.v;return((o.f&x)===0&&o.reactions!==null||zt(o))&&(s=je(o)),B.set(o,s),s}}else n&&(o=e,xe(o)&&bt(o));if((e.f&V)!==0)throw e.v;return e.v}function zt(e){if(e.v===m)return!0;if(e.deps===null)return!1;for(const t of e.deps)if(B.has(t)||(t.f&S)!==0&&zt(t))return!0;return!1}function Yt(e){var t=M;try{return M=!0,e()}finally{M=t}}const vr=-7169;function C(e,t){e.f=e.f&vr|t}const hr=["touchstart","touchmove"];function _r(e){return hr.includes(e)}const Gt=new Set,Ke=new Set;function pr(e){for(var t=0;t<e.length;t++)Gt.add(e[t]);for(var n of Ke)n(e)}let Vt=null;function Se(e){var t=this,n=t.ownerDocument,r=e.type,i=e.composedPath?.()||[],a=i[0]||e.target;Vt=e;var o=0,l=Vt===e&&e.__root;if(l){var s=i.indexOf(l);if(s!==-1&&(t===document||t===window)){e.__root=t;return}var f=i.indexOf(t);if(f===-1)return;s<=f&&(o=s)}if(a=i[o]||e.target,a!==t){Ie(e,"currentTarget",{configurable:!0,get(){return a||n}});var u=p,d=b;F(null),H(null);try{for(var h,c=[];a!==null;){var v=a.assignedSlot||a.parentNode||a.host||null;try{var w=a["__"+r];if(w!=null&&(!a.disabled||e.target===a))if(st(w)){var[g,...N]=w;g.apply(a,[e,...N])}else w.call(a,e)}catch(_){h?c.push(_):h=_}if(e.cancelBubble||v===t||v===null)break;a=v}if(h){for(let _ of c)queueMicrotask(()=>{throw _});throw h}}finally{e.__root=t,delete e.currentTarget,F(u),H(d)}}}function br(e){var t;t=document.head.appendChild(ge());try{It(()=>e(t),dt)}finally{}}function wr(e){var t=document.createElement("template");return t.innerHTML=e.replaceAll("<!>","<!---->"),t.content}function Ze(e,t){var n=b;n.nodes_start===null&&(n.nodes_start=e,n.nodes_end=t)}function ve(e,t){var n=(t&Ln)!==0,r=(t&Dn)!==0,i,a=!e.startsWith("<!>");return()=>{i===void 0&&(i=wr(a?e:"<!>"+e),n||(i=ye(i)));var o=r||St?document.importNode(i,!0):i.cloneNode(!0);if(n){var l=ye(o),s=o.lastChild;Ze(l,s)}else Ze(o,o);return o}}function mr(){var e=document.createDocumentFragment(),t=document.createComment(""),n=ge();return e.append(t,n),Ze(t,n),e}function se(e,t){e!==null&&e.before(t)}function gr(e,t){return yr(e,t)}const le=new Map;function yr(e,{target:t,anchor:n,props:r={},events:i,context:a,intro:o=!0}){Jn();var l=new Set,s=d=>{for(var h=0;h<d.length;h++){var c=d[h];if(!l.has(c)){l.add(c);var v=_r(c);t.addEventListener(c,Se,{passive:v});var w=le.get(c);w===void 0?(document.addEventListener(c,Se,{passive:v}),le.set(c,1)):le.set(c,w+1)}}};s(un(Gt)),Ke.add(s);var f=void 0,u=rr(()=>{var d=n??t.appendChild(ge());return Ve(()=>{if(a){be({});var h=R;h.c=a}i&&(r.$$events=i),f=e(d,r)||{},a&&we()}),()=>{for(var h of l){t.removeEventListener(h,Se);var c=le.get(h);--c===0?(document.removeEventListener(h,Se),le.delete(h)):le.set(h,c)}Ke.delete(s),d!==n&&d.parentNode?.removeChild(d)}});return Er.set(f,u),f}let Er=new WeakMap;function xr(e,t,n=!1){var r=e,i=null,a=null,o=m,l=n?Ne:0,s=!1;const f=(c,v=!0)=>{s=!0,h(v,c)};var u=null;function d(){u!==null&&(u.lastChild.remove(),r.before(u),u=null);var c=o?i:a,v=o?a:i;c&&fr(c),v&&Lt(v,()=>{o?a=null:i=null})}const h=(c,v)=>{if(o!==(o=c)){var w=$n(),g=r;if(w&&(u=document.createDocumentFragment(),u.append(g=ge())),o?i??=v&&Ve(()=>v(g)):a??=v&&Ve(()=>v(g)),w){var N=E,_=o?i:a,y=o?a:i;_&&N.skipped_effects.delete(_),y&&N.skipped_effects.add(y),N.add_callback(d)}else d()}};It(()=>{s=!1,t(f),s||h(null,null)},l)}function Je(e,t){ir(()=>{var n=e.getRootNode(),r=n.host?n:n.head??n.ownerDocument.head;if(!r.querySelector("#"+t.hash)){const i=document.createElement("style");i.id=t.hash,i.textContent=t.code,r.appendChild(i)}})}const Kt=[...`
2
- \r\f \v\uFEFF`];function kr(e,t,n){var r=e==null?"":""+e;if(t&&(r=r?r+" "+t:t),n){for(var i in n)if(n[i])r=r?r+" "+i:i;else if(r.length)for(var a=i.length,o=0;(o=r.indexOf(i,o))>=0;){var l=o+a;(o===0||Kt.includes(r[o-1]))&&(l===r.length||Kt.includes(r[l]))?r=(o===0?"":r.substring(0,o))+r.substring(l+1):o=l}}return r===""?null:r}function Zt(e,t,n,r,i,a){var o=e.__className;if(o!==n||o===void 0){var l=kr(n,r,a);l==null?e.removeAttribute("class"):e.className=l,e.__className=n}else if(a&&i!==a)for(var s in a){var f=!!a[s];(i==null||f!==!!i[s])&&e.classList.toggle(s,f)}return a}const Sr=Symbol("is custom element"),Tr=Symbol("is html");function fe(e,t,n,r){var i=Or(e);i[t]!==(i[t]=n)&&(t==="loading"&&(e[wn]=n),n==null?e.removeAttribute(t):typeof n!="string"&&Cr(e).includes(t)?e[t]=n:e.setAttribute(t,n))}function Or(e){return e.__attributes??={[Sr]:e.nodeName.includes("-"),[Tr]:e.namespaceURI===Mn}}var Jt=new Map;function Cr(e){var t=e.getAttribute("is")||e.nodeName,n=Jt.get(t);if(n)return n;Jt.set(t,n=[]);for(var r,i=e,a=Element.prototype;a!==i;){r=cn(i);for(var o in r)r[o].set&&n.push(o);i=lt(i)}return n}let Te=!1;function Ar(e){var t=Te;try{return Te=!1,[e(),Te]}finally{Te=t}}function Qe(e,t,n,r){var i=(n&Pn)!==0,a=(n&Nn)!==0,o=r,l=!0,s=()=>(l&&(l=!1,o=a?Yt(r):r),o),f;if(i){var u=_e in e||bn in e;f=te(e,t)?.set??(u&&t in e?_=>e[t]=_:void 0)}var d,h=!1;i?[d,h]=Ar(()=>e[t]):d=e[t],d===void 0&&r!==void 0&&(d=s(),f&&(Tn(),f(d)));var c;if(c=()=>{var _=e[t];return _===void 0?s():(l=!0,_)},(n&Rn)===0)return c;if(f){var v=e.$$legacy;return(function(_,y){return arguments.length>0?((!y||v||h)&&f(y?c():_),_):c()})}var w=!1,g=((n&In)!==0?Ue:zn)(()=>(w=!1,c()));i&&O(g);var N=b;return(function(_,y){if(arguments.length>0){const ee=y?O(g):i?Z(_):_;return D(g,ee),w=!0,o!==void 0&&(o=ee),_}return X&&w||(N.f&G)!==0?g.v:O(g)})}function Qt(e){R===null&&gn(),nr(()=>{const t=Yt(e);if(typeof t=="function")return t})}const Ir="5";typeof window<"u"&&((window.__svelte??={}).v??=new Set).add(Ir);var Rr=ve('<div><iframe id="chat-frame" title="Chat" class="bot svelte-b4a27v" frameborder="0" allow="microphone; clipboard-write" allowfullscreen=""></iframe></div>'),Pr=ve(`<p class="svelte-b4a27v">Please make sure that the script tag has 'id="chatbot"' and the attribute
3
- 'data-server' with the full qualified URL to the chatbot-server.</p> <pre class="svelte-b4a27v">
4
- <code class="svelte-b4a27v">
1
+ (function(){"use strict";const at=!1;var st=Array.isArray,ln=Array.prototype.indexOf,fn=Array.from,Ie=Object.defineProperty,te=Object.getOwnPropertyDescriptor,un=Object.getOwnPropertyDescriptors,cn=Object.prototype,dn=Array.prototype,lt=Object.getPrototypeOf,ft=Object.isExtensible;function vn(e){for(var t=0;t<e.length;t++)e[t]()}function hn(){var e,t,n=new Promise((r,i)=>{e=r,t=i});return{promise:n,resolve:e,reject:t}}const S=2,Re=4,_n=8,ne=16,U=32,Y=64,ut=128,A=256,_e=512,k=1024,I=2048,q=4096,j=8192,G=16384,Pe=32768,Ne=65536,ct=1<<17,dt=1<<18,ce=1<<19,pn=1<<20,Le=1<<21,De=1<<22,V=1<<23,pe=Symbol("$state"),mn=Symbol("legacy props"),wn=Symbol(""),Me=new class extends Error{name="StaleReactionError";message="The reaction that called `getAbortSignal()` was re-run or destroyed"};function bn(){throw new Error("https://svelte.dev/e/await_outside_boundary")}function gn(e){throw new Error("https://svelte.dev/e/lifecycle_outside_component")}function yn(){throw new Error("https://svelte.dev/e/async_derived_orphan")}function En(e){throw new Error("https://svelte.dev/e/effect_in_teardown")}function kn(){throw new Error("https://svelte.dev/e/effect_in_unowned_derived")}function xn(e){throw new Error("https://svelte.dev/e/effect_orphan")}function Sn(){throw new Error("https://svelte.dev/e/effect_update_depth_exceeded")}function Tn(e){throw new Error("https://svelte.dev/e/props_invalid_value")}function On(){throw new Error("https://svelte.dev/e/state_descriptors_fixed")}function Cn(){throw new Error("https://svelte.dev/e/state_prototype_fixed")}function An(){throw new Error("https://svelte.dev/e/state_unsafe_mutation")}const In=1,Rn=4,Pn=8,Nn=16,Ln=1,Dn=2,b=Symbol(),Mn="http://www.w3.org/1999/xhtml";function vt(e){return e===this.v}function Fn(e,t){return e!=e?t==t:e!==t||e!==null&&typeof e=="object"||typeof e=="function"}function Un(e){return!Fn(e,this.v)}let zn=!1,R=null;function me(e){R=e}function we(e,t=!1,n){R={p:R,c:null,e:null,s:e,x:null,l:null}}function be(e){var t=R,n=t.e;if(n!==null){t.e=null;for(var r of n)Ct(r)}return R=t.p,{}}function ht(){return!0}const qn=new WeakMap;function jn(e){var t=m;if(t===null)return p.f|=V,e;if((t.f&Pe)===0){if((t.f&ut)===0)throw!t.parent&&e instanceof Error&&_t(e),e;t.b.error(e)}else Fe(e,t)}function Fe(e,t){for(;t!==null;){if((t.f&ut)!==0)try{t.b.error(e);return}catch(n){e=n}t=t.parent}throw e instanceof Error&&_t(e),e}function _t(e){const t=qn.get(e);t&&(Ie(e,"message",{value:t.message}),Ie(e,"stack",{value:t.stack}))}let re=[];function Wn(){var e=re;re=[],vn(e)}function Bn(e){if(re.length===0){var t=re;queueMicrotask(()=>{t===re&&Wn()})}re.push(e)}function Hn(){const e=m.b;return e===null&&bn(),e}function Ue(e){var t=S|I,n=p!==null&&(p.f&S)!==0?p:null;return m===null||n!==null&&(n.f&A)!==0?t|=A:m.f|=ce,{ctx:R,deps:null,effects:null,equals:vt,f:t,fn:e,reactions:null,rv:0,v:b,wv:0,parent:n??m,ac:null}}function Yn(e,t){let n=m;n===null&&yn();var r=n.b,i=void 0,a=yt(b),o=null,l=!p;return sr(()=>{try{var s=e();o&&Promise.resolve(s).catch(()=>{})}catch(c){s=Promise.reject(c)}var f=()=>s;i=o?.then(f,f)??Promise.resolve(s),o=i;var u=E,d=r.is_pending();l&&(r.update_pending_count(1),d||u.increment());const h=(c,v=void 0)=>{o=null,d||u.activate(),v?v!==Me&&(a.f|=V,Be(a,v)):((a.f&V)!==0&&(a.f^=V),Be(a,c)),l&&(r.update_pending_count(-1),d||u.decrement()),wt()};if(i.then(h,c=>h(null,c||"unknown")),u)return()=>{queueMicrotask(()=>u.neuter())}}),new Promise(s=>{function f(u){function d(){u===i?s(a):f(i)}u.then(d,d)}f(i)})}function Gn(e){const t=Ue(e);return t.equals=Un,t}function pt(e){var t=e.effects;if(t!==null){e.effects=null;for(var n=0;n<t.length;n+=1)Q(t[n])}}function Vn(e){for(var t=e.parent;t!==null;){if((t.f&S)===0)return t;t=t.parent}return null}function ze(e){var t,n=m;B(Vn(e));try{pt(e),t=Wt(e)}finally{B(n)}return t}function mt(e){var t=ze(e);if(e.equals(t)||(e.v=t,e.wv=qt()),!X){var n=(H||(e.f&A)!==0)&&e.deps!==null?q:k;C(e,n)}}function Kn(e,t,n){const r=Ue;if(t.length===0){n(e.map(r));return}var i=E,a=m,o=Zn(),l=Hn();Promise.all(t.map(s=>Yn(s))).then(s=>{i?.activate(),o();try{n([...e.map(r),...s])}catch(f){(a.f&G)===0&&Fe(f,a)}i?.deactivate(),wt()}).catch(s=>{l.error(s)})}function Zn(){var e=m,t=p,n=R,r=E;return function(){B(e),F(t),me(n),r?.activate()}}function wt(){B(null),F(null),me(null)}const qe=new Set;let E=null,bt=new Set,de=[],je=null,We=!1;class ie{current=new Map;#l=new Map;#i=new Set;#e=0;#f=null;#u=!1;#n=[];#o=[];#r=[];#t=[];#a=[];#c=[];#d=[];skipped_effects=new Set;process(t){de=[];for(const i of t)this.#h(i);if(this.#n.length===0&&this.#e===0){this.#v();var n=this.#r,r=this.#t;this.#r=[],this.#t=[],this.#a=[],E=null,gt(n),gt(r),E===null?E=this:qe.delete(this),this.#f?.resolve()}else this.#s(this.#r),this.#s(this.#t),this.#s(this.#a);for(const i of this.#n)se(i);for(const i of this.#o)se(i);this.#n=[],this.#o=[]}#h(t){t.f^=k;for(var n=t.first;n!==null;){var r=n.f,i=(r&(U|Y))!==0,a=i&&(r&k)!==0,o=a||(r&j)!==0||this.skipped_effects.has(n);if(!o&&n.fn!==null){if(i)n.f^=k;else if((r&Re)!==0)this.#t.push(n);else if((r&k)===0)if((r&De)!==0){var l=n.b?.is_pending()?this.#o:this.#n;l.push(n)}else ke(n)&&((n.f&ne)!==0&&this.#a.push(n),se(n));var s=n.first;if(s!==null){n=s;continue}}var f=n.parent;for(n=n.next;n===null&&f!==null;)n=f.next,f=f.parent}}#s(t){for(const n of t)((n.f&I)!==0?this.#c:this.#d).push(n),C(n,k);t.length=0}capture(t,n){this.#l.has(t)||this.#l.set(t,n),this.current.set(t,t.v)}activate(){E=this}deactivate(){E=null;for(const t of bt)if(bt.delete(t),t(),E!==null)break}neuter(){this.#u=!0}flush(){de.length>0?Jn():this.#v(),E===this&&(this.#e===0&&qe.delete(this),this.deactivate())}#v(){if(!this.#u)for(const t of this.#i)t();this.#i.clear()}increment(){this.#e+=1}decrement(){if(this.#e-=1,this.#e===0){for(const t of this.#c)C(t,I),oe(t);for(const t of this.#d)C(t,q),oe(t);this.#r=[],this.#t=[],this.flush()}else this.deactivate()}add_callback(t){this.#i.add(t)}settled(){return(this.#f??=hn()).promise}static ensure(){if(E===null){const t=E=new ie;qe.add(E),ie.enqueue(()=>{E===t&&t.flush()})}return E}static enqueue(t){Bn(t)}}function Jn(){var e=ae;We=!0;try{var t=0;for(Mt(!0);de.length>0;){var n=ie.ensure();if(t++>1e3){var r,i;Qn()}n.process(de),W.clear()}}finally{We=!1,Mt(e),je=null}}function Qn(){try{Sn()}catch(e){Fe(e,je)}}let K=null;function gt(e){var t=e.length;if(t!==0){for(var n=0;n<t;){var r=e[n++];if((r.f&(G|j))===0&&ke(r)&&(K=[],se(r),r.deps===null&&r.first===null&&r.nodes_start===null&&(r.teardown===null&&r.ac===null?Pt(r):r.fn=null),K?.length>0)){W.clear();for(const i of K)se(i);K=[]}}K=null}}function oe(e){for(var t=je=e;t.parent!==null;){t=t.parent;var n=t.f;if(We&&t===m&&(n&ne)!==0)return;if((n&(Y|U))!==0){if((n&k)===0)return;t.f^=k}}de.push(t)}const W=new Map;function yt(e,t){var n={f:0,v:e,reactions:null,equals:vt,rv:0,wv:0};return n}function L(e,t){const n=yt(e);return dr(n),n}function D(e,t,n=!1){p!==null&&(!M||(p.f&ct)!==0)&&ht()&&(p.f&(S|ne|De|ct))!==0&&!z?.includes(e)&&An();let r=n?Z(t):t;return Be(e,r)}function Be(e,t){if(!e.equals(t)){var n=e.v;X?W.set(e,t):W.set(e,n),e.v=t;var r=ie.ensure();r.capture(e,n),(e.f&S)!==0&&((e.f&I)!==0&&ze(e),C(e,(e.f&A)===0?k:q)),e.wv=qt(),Et(e,I),m!==null&&(m.f&k)!==0&&(m.f&(U|Y))===0&&(P===null?vr([e]):P.push(e))}return t}function He(e){D(e,e.v+1)}function Et(e,t){var n=e.reactions;if(n!==null)for(var r=n.length,i=0;i<r;i++){var a=n[i],o=a.f,l=(o&I)===0;l&&C(a,t),(o&S)!==0?Et(a,q):l&&((o&ne)!==0&&K!==null&&K.push(a),oe(a))}}function Z(e){if(typeof e!="object"||e===null||pe in e)return e;const t=lt(e);if(t!==cn&&t!==dn)return e;var n=new Map,r=st(e),i=L(0),a=$,o=l=>{if($===a)return l();var s=p,f=$;F(null),zt(a);var u=l();return F(s),zt(f),u};return r&&n.set("length",L(e.length)),new Proxy(e,{defineProperty(l,s,f){(!("value"in f)||f.configurable===!1||f.enumerable===!1||f.writable===!1)&&On();var u=n.get(s);return u===void 0?u=o(()=>{var d=L(f.value);return n.set(s,d),d}):D(u,f.value,!0),!0},deleteProperty(l,s){var f=n.get(s);if(f===void 0){if(s in l){const u=o(()=>L(b));n.set(s,u),He(i)}}else D(f,b),He(i);return!0},get(l,s,f){if(s===pe)return e;var u=n.get(s),d=s in l;if(u===void 0&&(!d||te(l,s)?.writable)&&(u=o(()=>{var c=Z(d?l[s]:b),v=L(c);return v}),n.set(s,u)),u!==void 0){var h=O(u);return h===b?void 0:h}return Reflect.get(l,s,f)},getOwnPropertyDescriptor(l,s){var f=Reflect.getOwnPropertyDescriptor(l,s);if(f&&"value"in f){var u=n.get(s);u&&(f.value=O(u))}else if(f===void 0){var d=n.get(s),h=d?.v;if(d!==void 0&&h!==b)return{enumerable:!0,configurable:!0,value:h,writable:!0}}return f},has(l,s){if(s===pe)return!0;var f=n.get(s),u=f!==void 0&&f.v!==b||Reflect.has(l,s);if(f!==void 0||m!==null&&(!u||te(l,s)?.writable)){f===void 0&&(f=o(()=>{var h=u?Z(l[s]):b,c=L(h);return c}),n.set(s,f));var d=O(f);if(d===b)return!1}return u},set(l,s,f,u){var d=n.get(s),h=s in l;if(r&&s==="length")for(var c=f;c<d.v;c+=1){var v=n.get(c+"");v!==void 0?D(v,b):c in l&&(v=o(()=>L(b)),n.set(c+"",v))}if(d===void 0)(!h||te(l,s)?.writable)&&(d=o(()=>L(void 0)),D(d,Z(f)),n.set(s,d));else{h=d.v!==b;var w=o(()=>Z(f));D(d,w)}var g=Reflect.getOwnPropertyDescriptor(l,s);if(g?.set&&g.set.call(u,f),!h){if(r&&typeof s=="string"){var N=n.get("length"),_=Number(s);Number.isInteger(_)&&_>=N.v&&D(N,_+1)}He(i)}return!0},ownKeys(l){O(i);var s=Reflect.ownKeys(l).filter(d=>{var h=n.get(d);return h===void 0||h.v!==b});for(var[f,u]of n)u.v!==b&&!(f in l)&&s.push(f);return s},setPrototypeOf(){Cn()}})}var kt,xt,St,Tt;function Xn(){if(kt===void 0){kt=window,xt=/Firefox/.test(navigator.userAgent);var e=Element.prototype,t=Node.prototype,n=Text.prototype;St=te(t,"firstChild").get,Tt=te(t,"nextSibling").get,ft(e)&&(e.__click=void 0,e.__className=void 0,e.__attributes=null,e.__style=void 0,e.__e=void 0),ft(n)&&(n.__t=void 0)}}function ge(e=""){return document.createTextNode(e)}function ye(e){return St.call(e)}function Ye(e){return Tt.call(e)}function Ge(e,t){return ye(e)}function $n(e,t){{var n=ye(e);return n instanceof Comment&&n.data===""?Ye(n):n}}function er(e,t=1,n=!1){let r=e;for(;t--;)r=Ye(r);return r}function tr(){return!1}function Ot(e){var t=p,n=m;F(null),B(null);try{return e()}finally{F(t),B(n)}}function nr(e){m===null&&p===null&&xn(),p!==null&&(p.f&A)!==0&&m===null&&kn(),X&&En()}function rr(e,t){var n=t.last;n===null?t.last=t.first=e:(n.next=e,e.prev=n,t.last=e)}function J(e,t,n,r=!0){var i=m;i!==null&&(i.f&j)!==0&&(e|=j);var a={ctx:R,deps:null,nodes_start:null,nodes_end:null,f:e|I,first:null,fn:t,last:null,next:null,parent:i,b:i&&i.b,prev:null,teardown:null,transitions:null,wv:0,ac:null};if(n)try{se(a),a.f|=Pe}catch(s){throw Q(a),s}else t!==null&&oe(a);if(r){var o=a;if(n&&o.deps===null&&o.teardown===null&&o.nodes_start===null&&o.first===o.last&&(o.f&ce)===0&&(o=o.first),o!==null&&(o.parent=i,i!==null&&rr(o,i),p!==null&&(p.f&S)!==0&&(e&Y)===0)){var l=p;(l.effects??=[]).push(o)}}return a}function ir(e){nr();var t=m.f,n=!p&&(t&U)!==0&&(t&Pe)===0;if(n){var r=R;(r.e??=[]).push(e)}else return Ct(e)}function Ct(e){return J(Re|pn,e,!1)}function or(e){ie.ensure();const t=J(Y|ce,e,!0);return(n={})=>new Promise(r=>{n.outro?Nt(t,()=>{Q(t),r(void 0)}):(Q(t),r(void 0))})}function ar(e){return J(Re,e,!1)}function sr(e){return J(De|ce,e,!0)}function Ee(e,t=[],n=[]){Kn(t,n,r=>{J(_n,()=>e(...r.map(O)),!0)})}function At(e,t=0){var n=J(ne|t,e,!0);return n}function Ve(e,t=!0){return J(U|ce,e,!0,t)}function It(e){var t=e.teardown;if(t!==null){const n=X,r=p;Ft(!0),F(null);try{t.call(null)}finally{Ft(n),F(r)}}}function Rt(e,t=!1){var n=e.first;for(e.first=e.last=null;n!==null;){const i=n.ac;i!==null&&Ot(()=>{i.abort(Me)});var r=n.next;(n.f&Y)!==0?n.parent=null:Q(n,t),n=r}}function lr(e){for(var t=e.first;t!==null;){var n=t.next;(t.f&U)===0&&Q(t),t=n}}function Q(e,t=!0){var n=!1;(t||(e.f&dt)!==0)&&e.nodes_start!==null&&e.nodes_end!==null&&(fr(e.nodes_start,e.nodes_end),n=!0),Rt(e,t&&!n),xe(e,0),C(e,G);var r=e.transitions;if(r!==null)for(const a of r)a.stop();It(e);var i=e.parent;i!==null&&i.first!==null&&Pt(e),e.next=e.prev=e.teardown=e.ctx=e.deps=e.fn=e.nodes_start=e.nodes_end=e.ac=null}function fr(e,t){for(;e!==null;){var n=e===t?null:Ye(e);e.remove(),e=n}}function Pt(e){var t=e.parent,n=e.prev,r=e.next;n!==null&&(n.next=r),r!==null&&(r.prev=n),t!==null&&(t.first===e&&(t.first=r),t.last===e&&(t.last=n))}function Nt(e,t){var n=[];Lt(e,n,!0),ur(n,()=>{Q(e),t&&t()})}function ur(e,t){var n=e.length;if(n>0){var r=()=>--n||t();for(var i of e)i.out(r)}else t()}function Lt(e,t,n){if((e.f&j)===0){if(e.f^=j,e.transitions!==null)for(const o of e.transitions)(o.is_global||n)&&t.push(o);for(var r=e.first;r!==null;){var i=r.next,a=(r.f&Ne)!==0||(r.f&U)!==0;Lt(r,t,a?n:!1),r=i}}}function cr(e){Dt(e,!0)}function Dt(e,t){if((e.f&j)!==0){e.f^=j,(e.f&k)===0&&(C(e,I),oe(e));for(var n=e.first;n!==null;){var r=n.next,i=(n.f&Ne)!==0||(n.f&U)!==0;Dt(n,i?t:!1),n=r}if(e.transitions!==null)for(const a of e.transitions)(a.is_global||t)&&a.in()}}let ae=!1;function Mt(e){ae=e}let X=!1;function Ft(e){X=e}let p=null,M=!1;function F(e){p=e}let m=null;function B(e){m=e}let z=null;function dr(e){p!==null&&(z===null?z=[e]:z.push(e))}let x=null,T=0,P=null;function vr(e){P=e}let Ut=1,ve=0,$=ve;function zt(e){$=e}let H=!1;function qt(){return++Ut}function ke(e){var t=e.f;if((t&I)!==0)return!0;if((t&q)!==0){var n=e.deps,r=(t&A)!==0;if(n!==null){var i,a,o=(t&_e)!==0,l=r&&m!==null&&!H,s=n.length;if((o||l)&&(m===null||(m.f&G)===0)){var f=e,u=f.parent;for(i=0;i<s;i++)a=n[i],(o||!a?.reactions?.includes(f))&&(a.reactions??=[]).push(f);o&&(f.f^=_e),l&&u!==null&&(u.f&A)===0&&(f.f^=A)}for(i=0;i<s;i++)if(a=n[i],ke(a)&&mt(a),a.wv>e.wv)return!0}(!r||m!==null&&!H)&&C(e,k)}return!1}function jt(e,t,n=!0){var r=e.reactions;if(r!==null&&!z?.includes(e))for(var i=0;i<r.length;i++){var a=r[i];(a.f&S)!==0?jt(a,t,!1):t===a&&(n?C(a,I):(a.f&k)!==0&&C(a,q),oe(a))}}function Wt(e){var t=x,n=T,r=P,i=p,a=H,o=z,l=R,s=M,f=$,u=e.f;x=null,T=0,P=null,H=(u&A)!==0&&(M||!ae||p===null),p=(u&(U|Y))===0?e:null,z=null,me(e.ctx),M=!1,$=++ve,e.ac!==null&&(Ot(()=>{e.ac.abort(Me)}),e.ac=null);try{e.f|=Le;var d=e.fn,h=d(),c=e.deps;if(x!==null){var v;if(xe(e,T),c!==null&&T>0)for(c.length=T+x.length,v=0;v<x.length;v++)c[T+v]=x[v];else e.deps=c=x;if(!H||(u&S)!==0&&e.reactions!==null)for(v=T;v<c.length;v++)(c[v].reactions??=[]).push(e)}else c!==null&&T<c.length&&(xe(e,T),c.length=T);if(ht()&&P!==null&&!M&&c!==null&&(e.f&(S|q|I))===0)for(v=0;v<P.length;v++)jt(P[v],e);return i!==null&&i!==e&&(ve++,P!==null&&(r===null?r=P:r.push(...P))),(e.f&V)!==0&&(e.f^=V),h}catch(w){return jn(w)}finally{e.f^=Le,x=t,T=n,P=r,p=i,H=a,z=o,me(l),M=s,$=f}}function hr(e,t){let n=t.reactions;if(n!==null){var r=ln.call(n,e);if(r!==-1){var i=n.length-1;i===0?n=t.reactions=null:(n[r]=n[i],n.pop())}}n===null&&(t.f&S)!==0&&(x===null||!x.includes(t))&&(C(t,q),(t.f&(A|_e))===0&&(t.f^=_e),pt(t),xe(t,0))}function xe(e,t){var n=e.deps;if(n!==null)for(var r=t;r<n.length;r++)hr(e,n[r])}function se(e){var t=e.f;if((t&G)===0){C(e,k);var n=m,r=ae;m=e,ae=!0;try{(t&ne)!==0?lr(e):Rt(e),It(e);var i=Wt(e);e.teardown=typeof i=="function"?i:null,e.wv=Ut;var a;at&&zn&&(e.f&I)!==0&&e.deps}finally{ae=r,m=n}}}function O(e){var t=e.f,n=(t&S)!==0;if(p!==null&&!M){var r=m!==null&&(m.f&G)!==0;if(!r&&!z?.includes(e)){var i=p.deps;if((p.f&Le)!==0)e.rv<ve&&(e.rv=ve,x===null&&i!==null&&i[T]===e?T++:x===null?x=[e]:(!H||!x.includes(e))&&x.push(e));else{(p.deps??=[]).push(e);var a=e.reactions;a===null?e.reactions=[p]:a.includes(p)||a.push(p)}}}else if(n&&e.deps===null&&e.effects===null){var o=e,l=o.parent;l!==null&&(l.f&A)===0&&(o.f^=A)}if(X){if(W.has(e))return W.get(e);if(n){o=e;var s=o.v;return((o.f&k)===0&&o.reactions!==null||Bt(o))&&(s=ze(o)),W.set(o,s),s}}else n&&(o=e,ke(o)&&mt(o));if((e.f&V)!==0)throw e.v;return e.v}function Bt(e){if(e.v===b)return!0;if(e.deps===null)return!1;for(const t of e.deps)if(W.has(t)||(t.f&S)!==0&&Bt(t))return!0;return!1}function Ht(e){var t=M;try{return M=!0,e()}finally{M=t}}const _r=-7169;function C(e,t){e.f=e.f&_r|t}const pr=["touchstart","touchmove"];function mr(e){return pr.includes(e)}const Yt=new Set,Ke=new Set;function wr(e){for(var t=0;t<e.length;t++)Yt.add(e[t]);for(var n of Ke)n(e)}let Gt=null;function Se(e){var t=this,n=t.ownerDocument,r=e.type,i=e.composedPath?.()||[],a=i[0]||e.target;Gt=e;var o=0,l=Gt===e&&e.__root;if(l){var s=i.indexOf(l);if(s!==-1&&(t===document||t===window)){e.__root=t;return}var f=i.indexOf(t);if(f===-1)return;s<=f&&(o=s)}if(a=i[o]||e.target,a!==t){Ie(e,"currentTarget",{configurable:!0,get(){return a||n}});var u=p,d=m;F(null),B(null);try{for(var h,c=[];a!==null;){var v=a.assignedSlot||a.parentNode||a.host||null;try{var w=a["__"+r];if(w!=null&&(!a.disabled||e.target===a))if(st(w)){var[g,...N]=w;g.apply(a,[e,...N])}else w.call(a,e)}catch(_){h?c.push(_):h=_}if(e.cancelBubble||v===t||v===null)break;a=v}if(h){for(let _ of c)queueMicrotask(()=>{throw _});throw h}}finally{e.__root=t,delete e.currentTarget,F(u),B(d)}}}function br(e){var t;t=document.head.appendChild(ge());try{At(()=>e(t),dt)}finally{}}function gr(e){var t=document.createElement("template");return t.innerHTML=e.replaceAll("<!>","<!---->"),t.content}function Ze(e,t){var n=m;n.nodes_start===null&&(n.nodes_start=e,n.nodes_end=t)}function he(e,t){var n=(t&Ln)!==0,r=(t&Dn)!==0,i,a=!e.startsWith("<!>");return()=>{i===void 0&&(i=gr(a?e:"<!>"+e),n||(i=ye(i)));var o=r||xt?document.importNode(i,!0):i.cloneNode(!0);if(n){var l=ye(o),s=o.lastChild;Ze(l,s)}else Ze(o,o);return o}}function yr(){var e=document.createDocumentFragment(),t=document.createComment(""),n=ge();return e.append(t,n),Ze(t,n),e}function le(e,t){e!==null&&e.before(t)}function Er(e,t){return kr(e,t)}const fe=new Map;function kr(e,{target:t,anchor:n,props:r={},events:i,context:a,intro:o=!0}){Xn();var l=new Set,s=d=>{for(var h=0;h<d.length;h++){var c=d[h];if(!l.has(c)){l.add(c);var v=mr(c);t.addEventListener(c,Se,{passive:v});var w=fe.get(c);w===void 0?(document.addEventListener(c,Se,{passive:v}),fe.set(c,1)):fe.set(c,w+1)}}};s(fn(Yt)),Ke.add(s);var f=void 0,u=or(()=>{var d=n??t.appendChild(ge());return Ve(()=>{if(a){we({});var h=R;h.c=a}i&&(r.$$events=i),f=e(d,r)||{},a&&be()}),()=>{for(var h of l){t.removeEventListener(h,Se);var c=fe.get(h);--c===0?(document.removeEventListener(h,Se),fe.delete(h)):fe.set(h,c)}Ke.delete(s),d!==n&&d.parentNode?.removeChild(d)}});return xr.set(f,u),f}let xr=new WeakMap;function Sr(e,t,n=!1){var r=e,i=null,a=null,o=b,l=n?Ne:0,s=!1;const f=(c,v=!0)=>{s=!0,h(v,c)};var u=null;function d(){u!==null&&(u.lastChild.remove(),r.before(u),u=null);var c=o?i:a,v=o?a:i;c&&cr(c),v&&Nt(v,()=>{o?a=null:i=null})}const h=(c,v)=>{if(o!==(o=c)){var w=tr(),g=r;if(w&&(u=document.createDocumentFragment(),u.append(g=ge())),o?i??=v&&Ve(()=>v(g)):a??=v&&Ve(()=>v(g)),w){var N=E,_=o?i:a,y=o?a:i;_&&N.skipped_effects.delete(_),y&&N.skipped_effects.add(y),N.add_callback(d)}else d()}};At(()=>{s=!1,t(f),s||h(null,null)},l)}function Je(e,t){ar(()=>{var n=e.getRootNode(),r=n.host?n:n.head??n.ownerDocument.head;if(!r.querySelector("#"+t.hash)){const i=document.createElement("style");i.id=t.hash,i.textContent=t.code,r.appendChild(i)}})}const Vt=[...`
2
+ \r\f \v\uFEFF`];function Tr(e,t,n){var r=e==null?"":""+e;if(t&&(r=r?r+" "+t:t),n){for(var i in n)if(n[i])r=r?r+" "+i:i;else if(r.length)for(var a=i.length,o=0;(o=r.indexOf(i,o))>=0;){var l=o+a;(o===0||Vt.includes(r[o-1]))&&(l===r.length||Vt.includes(r[l]))?r=(o===0?"":r.substring(0,o))+r.substring(l+1):o=l}}return r===""?null:r}function Kt(e,t,n,r,i,a){var o=e.__className;if(o!==n||o===void 0){var l=Tr(n,r,a);l==null?e.removeAttribute("class"):e.className=l,e.__className=n}else if(a&&i!==a)for(var s in a){var f=!!a[s];(i==null||f!==!!i[s])&&e.classList.toggle(s,f)}return a}const Or=Symbol("is custom element"),Cr=Symbol("is html");function ue(e,t,n,r){var i=Ar(e);i[t]!==(i[t]=n)&&(t==="loading"&&(e[wn]=n),n==null?e.removeAttribute(t):typeof n!="string"&&Ir(e).includes(t)?e[t]=n:e.setAttribute(t,n))}function Ar(e){return e.__attributes??={[Or]:e.nodeName.includes("-"),[Cr]:e.namespaceURI===Mn}}var Zt=new Map;function Ir(e){var t=e.getAttribute("is")||e.nodeName,n=Zt.get(t);if(n)return n;Zt.set(t,n=[]);for(var r,i=e,a=Element.prototype;a!==i;){r=un(i);for(var o in r)r[o].set&&n.push(o);i=lt(i)}return n}let Te=!1;function Rr(e){var t=Te;try{return Te=!1,[e(),Te]}finally{Te=t}}function Qe(e,t,n,r){var i=(n&Pn)!==0,a=(n&Nn)!==0,o=r,l=!0,s=()=>(l&&(l=!1,o=a?Ht(r):r),o),f;if(i){var u=pe in e||mn in e;f=te(e,t)?.set??(u&&t in e?_=>e[t]=_:void 0)}var d,h=!1;i?[d,h]=Rr(()=>e[t]):d=e[t],d===void 0&&r!==void 0&&(d=s(),f&&(Tn(),f(d)));var c;if(c=()=>{var _=e[t];return _===void 0?s():(l=!0,_)},(n&Rn)===0)return c;if(f){var v=e.$$legacy;return(function(_,y){return arguments.length>0?((!y||v||h)&&f(y?c():_),_):c()})}var w=!1,g=((n&In)!==0?Ue:Gn)(()=>(w=!1,c()));i&&O(g);var N=m;return(function(_,y){if(arguments.length>0){const ee=y?O(g):i?Z(_):_;return D(g,ee),w=!0,o!==void 0&&(o=ee),_}return X&&w||(N.f&G)!==0?g.v:O(g)})}function Jt(e){R===null&&gn(),ir(()=>{const t=Ht(e);if(typeof t=="function")return t})}const Pr="5";typeof window<"u"&&((window.__svelte??={}).v??=new Set).add(Pr);var Nr=he('<div><iframe id="chat-frame" title="Chat" class="bot svelte-yhk8rr" frameborder="0" allow="microphone; clipboard-write" allowfullscreen=""></iframe></div>'),Lr=he(`<p class="svelte-yhk8rr">Please make sure that the script tag has 'id="chatbot"' and the attribute
3
+ 'data-server' with the full qualified URL to the chatbot-server.</p> <pre class="svelte-yhk8rr">
4
+ <code class="svelte-yhk8rr">
5
5
  &lt;script
6
- <br class="svelte-b4a27v"/>
6
+ <br class="svelte-yhk8rr"/>
7
7
  id="chatbot"
8
- <br class="svelte-b4a27v"/>
8
+ <br class="svelte-yhk8rr"/>
9
9
  data-server="https://server.com/webclient"
10
- <br class="svelte-b4a27v"/>
10
+ <br class="svelte-yhk8rr"/>
11
11
  defer
12
- <br class="svelte-b4a27v"/>
12
+ <br class="svelte-yhk8rr"/>
13
13
  src="https://server.com/webclient/embed/bundle.js"&gt; &lt;/script&gt;
14
14
  </code>
15
- </pre>`,1);const Nr={hash:"svelte-b4a27v",code:`.svelte-b4a27v,
16
- .svelte-b4a27v:before,
17
- .svelte-b4a27v:after {box-sizing:border-box;}.bot-border.svelte-b4a27v {position:fixed;display:flex;flex-direction:column;top:0;bottom:env(safe-area-inset-bottom);height:100%;max-height:100vh;width:100%;border-width:0;border-radius:var(--window-border-radius, 8px);box-shadow:rgba(0, 0, 0, 0.24) 0px 16px 40px;background:transparent;opacity:1;transition:transform 200ms,
15
+ </pre>`,1);const Dr={hash:"svelte-yhk8rr",code:`.svelte-yhk8rr,
16
+ .svelte-yhk8rr:before,
17
+ .svelte-yhk8rr:after {box-sizing:border-box;}.bot-border.svelte-yhk8rr {position:fixed;display:flex;flex-direction:column;top:0;bottom:env(safe-area-inset-bottom);height:100%;max-height:100vh;width:100%;border-width:0;border-radius:var(--window-border-radius, 8px);box-shadow:rgba(0, 0, 0, 0.24) 0px 16px 40px;background:transparent;opacity:1;transition:transform 200ms,
18
18
  opacity 100ms 100ms,
19
- all 150ms;z-index:2147483647;}.bot-border.closed.svelte-b4a27v {transform:translateY(100vh);opacity:0;}.bot.svelte-b4a27v {display:block;width:100%;flex:1 0 auto;margin:0;}#chat-frame.svelte-b4a27v {background-color:var(--body-background-color, white);}
19
+ all 150ms;z-index:2147483647;}.bot-border.closed.svelte-yhk8rr {transform:translateY(100vh);opacity:0;}.bot.svelte-yhk8rr {display:block;width:100%;flex:1 0 auto;margin:0;}#chat-frame.svelte-yhk8rr {background-color:var(--body-background-color, white);}
20
20
 
21
- @media screen and (min-width: 768px) {#chat-frame.svelte-b4a27v {border-radius:var(--window-border-radius, 8px);}.bot-border.svelte-b4a27v {height:var(--window-height, 43em);max-height:calc(100vh - 2em);width:var(--window-width, 25em);top:auto;right:1em;bottom:1em;left:auto;border-radius:var(--window-border-radius, 8px);}.bot-border.closed.svelte-b4a27v {transform:translateY(var(--window-height, 43em));opacity:0;}
22
- }p.svelte-b4a27v,
23
- pre.svelte-b4a27v {max-width:300px;}pre.svelte-b4a27v {font-size:0.6em;line-height:0.5;}`};function Lr(e,t){be(t,!0),Je(e,Nr),Qt(()=>{document.getElementById("chat-frame")?.addEventListener("load",t.onLoad)});var n=mr(),r=Qn(n);{var i=o=>{var l=Rr();let s;var f=Ge(l);Ee((u,d)=>{s=Zt(l,1,"bot-border svelte-b4a27v",null,s,u),fe(l,"aria-hidden",t.open?"false":"true"),fe(f,"src",d)},[()=>({closed:!t.open}),()=>`${t.server}${t.server.indexOf("?")===-1?"?":"&"}referrer=${encodeURIComponent(t.referrer??"")}`]),se(o,l)},a=o=>{var l=Pr();se(o,l)};xr(r,o=>{t.server?o(i):o(a,!1)})}se(e,n),we()}function Dr(e,t){const n=e.key;(n==="ArrowDown"||n==="ArrowRight"||n==="Enter"||n===" "||n==="Space")&&(e.stopPropagation(),t.onToggle())}var Mr=ve('<div class="chat-button-wrapper svelte-2hl2mw" tabindex="0" role="button" aria-label="Open chat window"><img class="chat-button svelte-2hl2mw" alt="Open chat window"/></div>');const Fr={hash:"svelte-2hl2mw",code:`.svelte-2hl2mw,
24
- .svelte-2hl2mw:before,
25
- .svelte-2hl2mw:after {box-sizing:border-box;}.chat-button-wrapper.svelte-2hl2mw {position:fixed;top:var(--fab-top-mobile, var(--fab-top, auto));right:var(--fab-right-mobile, var(--fab-right, 1.5em));bottom:var(--fab-bottom-mobile, var(--fab-bottom, 1.5em));left:var(--fab-left-mobile, var(--fab-left, auto));width:var(--fab-size-mobile, var(--fab-size, 5em));height:var(--fab-size-mobile, var(--fab-size, 5em));z-index:999;}
21
+ @media screen and (min-width: 768px) {#chat-frame.svelte-yhk8rr {border-radius:var(--window-border-radius, 8px);}.bot-border.svelte-yhk8rr {height:var(--window-height, 43em);max-height:calc(100vh - 2em);width:var(--window-width, 25em);top:auto;right:1em;bottom:1em;left:auto;border-radius:var(--window-border-radius, 8px);}.bot-border.closed.svelte-yhk8rr {transform:translateY(var(--window-height, 43em));opacity:0;}
22
+ }p.svelte-yhk8rr,
23
+ pre.svelte-yhk8rr {max-width:300px;}pre.svelte-yhk8rr {font-size:0.6em;line-height:0.5;}`};function Mr(e,t){we(t,!0),Je(e,Dr),Jt(()=>{document.getElementById("chat-frame")?.addEventListener("load",t.onLoad)});var n=yr(),r=$n(n);{var i=o=>{var l=Nr();let s;var f=Ge(l);Ee((u,d)=>{s=Kt(l,1,"bot-border svelte-yhk8rr",null,s,u),ue(l,"aria-hidden",t.open?"false":"true"),ue(f,"src",d)},[()=>({closed:!t.open}),()=>`${t.server}${t.server.indexOf("?")===-1?"?":"&"}referrer=${encodeURIComponent(t.referrer??"")}`]),le(o,l)},a=o=>{var l=Lr();le(o,l)};Sr(r,o=>{t.server?o(i):o(a,!1)})}le(e,n),be()}function Fr(e,t){const n=e.key;(n==="ArrowDown"||n==="ArrowRight"||n==="Enter"||n===" "||n==="Space")&&(e.stopPropagation(),t.onToggle())}var Ur=he('<div class="chat-button-wrapper svelte-1xi58vz" tabindex="0" role="button" aria-label="Open chat window"><img class="chat-button svelte-1xi58vz" alt="Open chat window"/></div>');const zr={hash:"svelte-1xi58vz",code:`.svelte-1xi58vz,
24
+ .svelte-1xi58vz:before,
25
+ .svelte-1xi58vz:after {box-sizing:border-box;}.chat-button-wrapper.svelte-1xi58vz {position:fixed;top:var(--fab-top-mobile, var(--fab-top, auto));right:var(--fab-right-mobile, var(--fab-right, 1.5em));bottom:var(--fab-bottom-mobile, var(--fab-bottom, 1.5em));left:var(--fab-left-mobile, var(--fab-left, auto));width:var(--fab-size-mobile, var(--fab-size, 5em));height:var(--fab-size-mobile, var(--fab-size, 5em));z-index:999;}
26
26
 
27
- @media screen and (min-width: 768px) {.chat-button-wrapper.svelte-2hl2mw {top:var(--fab-top, auto);right:var(--fab-right, 1.5em);bottom:var(--fab-bottom, 1.5em);left:var(--fab-left, auto);width:var(--fab-size, 6em);height:var(--fab-size, 6em);}
28
- }.chat-button.svelte-2hl2mw {display:block;height:100%;cursor:pointer;border-radius:50%;box-shadow:9px 9px 16px rgba(0, 0, 0, 0.25);transition:transform 100ms,
29
- box-shadow 100ms;}.chat-button.svelte-2hl2mw:hover {box-shadow:16px 16px 16px rgba(0, 0, 0, 0.2);transform:translateY(-2px);}`};function Ur(e,t){be(t,!0),Je(e,Fr);var n=Mr();n.__click=function(...i){t.onToggle?.apply(this,i)},n.__keydown=[Dr,t];var r=Ge(n);Ee(()=>{fe(n,"aria-expanded",t.open?"true":"false"),fe(r,"src",`${t.assetsUrl}/fab.svg`)}),se(e,n),we()}pr(["click","keydown"]);let Xt=!1;function jr(e){Xt=e}function qr(){return Xt}/*! js-cookie v3.0.5 | MIT */function Oe(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)e[r]=n[r]}return e}var Wr={read:function(e){return e[0]==='"'&&(e=e.slice(1,-1)),e.replace(/(%[\dA-F]{2})+/gi,decodeURIComponent)},write:function(e){return encodeURIComponent(e).replace(/%(2[346BF]|3[AC-F]|40|5[BDE]|60|7[BCD])/g,decodeURIComponent)}};function Xe(e,t){function n(i,a,o){if(!(typeof document>"u")){o=Oe({},t,o),typeof o.expires=="number"&&(o.expires=new Date(Date.now()+o.expires*864e5)),o.expires&&(o.expires=o.expires.toUTCString()),i=encodeURIComponent(i).replace(/%(2[346B]|5E|60|7C)/g,decodeURIComponent).replace(/[()]/g,escape);var l="";for(var s in o)o[s]&&(l+="; "+s,o[s]!==!0&&(l+="="+o[s].split(";")[0]));return document.cookie=i+"="+e.write(a,i)+l}}function r(i){if(!(typeof document>"u"||arguments.length&&!i)){for(var a=document.cookie?document.cookie.split("; "):[],o={},l=0;l<a.length;l++){var s=a[l].split("="),f=s.slice(1).join("=");try{var u=decodeURIComponent(s[0]);if(o[u]=e.read(f,u),i===u)break}catch{}}return i?o[i]:o}}return Object.create({set:n,get:r,remove:function(i,a){n(i,"",Oe({},a,{expires:-1}))},withAttributes:function(i){return Xe(this.converter,Oe({},this.attributes,i))},withConverter:function(i){return Xe(Oe({},this.converter,i),this.attributes)}},{attributes:{value:Object.freeze(t)},converter:{value:Object.freeze(e)}})}var $t=Xe(Wr,{path:"/"});const en="bubble-chat-window-state",tn=()=>{switch($t.get(en)){case"open":return!0;case"closed":return!1;default:return}},nn=e=>{const t=new Date(new Date().getTime()+288e5);$t.set(en,e,{expires:t})},$e=[];let et=tn();function tt(){et=!0,nn("open"),$e.forEach(function(e){e.call(window,!0)})}function Ce(){et=!1,nn("closed"),$e.forEach(function(e){e.call(window,!1)})}function rn(){et?Ce():tt()}function Br(){nt({type:"RESTART_CHAT"})}function Hr(e){nt({type:"CHAT_MESSAGE_FROM_GUEST",text:e})}function zr(e){nt({type:"TRIGGER_STORY",story:e})}function nt(e){document.getElementById("chat-frame")?.contentWindow?.postMessage(e,"*")}function on(e,t){switch(e){case"ON_CHAT_WINDOW_STATE_CHANGE":$e.push(t);break;default:throw new Error("Unsupported event "+e)}}const Yr=Object.freeze(Object.defineProperty({__proto__:null,closeChatWindow:Ce,enterGuestMessage:Hr,isChatbotLoaded:qr,openChatWindow:tt,restartChat:Br,subscribe:on,toggleChatWindow:rn,triggerStory:zr},Symbol.toStringTag,{value:"Module"}));function Gr(){return navigator.userAgent.match(/(iPad|iPhone|iPod)/g)}const Vr=()=>{Gr()&&document.querySelectorAll("html, body").forEach(e=>{e.classList.add("iOS-device")})},Kr=e=>{"gtag"in window&&typeof window.gtag=="function"?window.gtag("event","",e):"dataLayer"in window&&Array.isArray(window.dataLayer)&&window.dataLayer.push(e)},Zr=(e,t,n,r,i)=>{window.addEventListener("message",a=>{const o=a.data;switch(o.type){case"webclient.chat.started":e();break;case"webclient.chat.ended":t();break;case"webclient.window.expand":n(o.devices,o.initial);break;case"webclient.window.close":r();break;case"webclient.change.url":i(o.url);break;case"google.tag.event":Kr(o.payload);break}},!1)},Jr=e=>new Promise(t=>{const n=document.getElementById(e);n?(n.onload=()=>{t(!0)},n.onerror=()=>{console.error("Failed to load CSS file: custom.css"),t(!1)}):(console.error("No custom.css file found"),t(!1))});var Qr=ve('<link rel="stylesheet"/>'),Xr=ve("<div><!> <!></div>");const $r={hash:"svelte-4k2y00",code:".bubble-chat.svelte-4k2y00 {font-size:16px;visibility:hidden;opacity:0;}.bubble-chat.chatbot-ready.svelte-4k2y00 {visibility:visible;opacity:1;}"};function ei(e,t){be(t,!0),Je(e,$r);let n=Qe(t,"assetsUrl",19,()=>t.server?t.server.split("?")[0]:void 0),r=Qe(t,"linkHandling",3,"default"),i=Qe(t,"chatStarted",7,!1);const a="chatbot-style";let o=L(!1),l=L(!1);Vr();let s=L(Z(tn()));on("ON_CHAT_WINDOW_STATE_CHANGE",function(y){D(s,y,!0)});function f(){i(!0)}function u(){i(!1)}function d(_,y){const ee=window.innerWidth,it=_==null||_==="all",ot=_==="desktop"&&ee>=768,oi=_==="mobile"&&ee<768,ai=it||ot||oi;(y?O(s)!==!1:!0)&&ai&&tt()}function h(){Ce()}function c(_){const y=window.innerWidth,ee=window.location.hostname,it=new URL(_).hostname,ot=ee===it;y<768&&Ce(),r()==="new-tab"?window.open(_,"_blank"):r()==="existing-tab"||ot?document.location.href=_:window.open(_,"_blank")}function v(){D(l,!0)}Zr(f,u,d,h,c),Qt(async()=>{D(o,await Jr(a),!0)});var w=Xr();br(_=>{var y=Qr();fe(y,"id",a),Ee(()=>fe(y,"href",`${n()}/custom.css`)),se(_,y)});var g=Ge(w);Ur(g,{get assetsUrl(){return n()},get open(){return O(s)},get onToggle(){return rn}});var N=Xn(g,2);Lr(N,{get server(){return t.server},get referrer(){return t.referrer},get open(){return O(s)},onLoad:v}),Ee(()=>Zt(w,1,`bubble-chat ${O(o)&&O(l)?"chatbot-ready":""}`,"svelte-4k2y00")),se(e,w),we()}const ti=e=>e.replace(/\/embed\/bundle\.js/,""),ni=e=>e.dataset?.server,ri=e=>{if(e&&"src"in e&&typeof e.src=="string")return ni(e)||ti(e.src)},rt=document.querySelector("script#chatbot"),an=ri(rt),ii=rt?.getAttribute("link-handling")?rt.getAttribute("link-handling"):"default";window.chatbot=Yr;const sn=()=>{console.log("Chatbot is loading from",an),gr(ei,{target:document.body,props:{server:an,referrer:window.location.href,linkHandling:ii}}),jr(!0)},ln=(e=0)=>{e>=3||document.readyState==="complete"?setTimeout(sn,500):setTimeout(()=>{ln(e+1)},500)};ln();const Ae=document.getElementById("chatbot");Ae&&"src"in Ae&&typeof Ae.src=="string"&&Ae.src.indexOf("caller=bookmarklet")>0&&setTimeout(sn,500)})();
27
+ @media screen and (min-width: 768px) {.chat-button-wrapper.svelte-1xi58vz {top:var(--fab-top, auto);right:var(--fab-right, 1.5em);bottom:var(--fab-bottom, 1.5em);left:var(--fab-left, auto);width:var(--fab-size, 6em);height:var(--fab-size, 6em);}
28
+ }.chat-button.svelte-1xi58vz {display:block;height:100%;cursor:pointer;border-radius:50%;box-shadow:9px 9px 16px rgba(0, 0, 0, 0.25);transition:transform 100ms,
29
+ box-shadow 100ms;}.chat-button.svelte-1xi58vz:hover {box-shadow:16px 16px 16px rgba(0, 0, 0, 0.2);transform:translateY(-2px);}`};function qr(e,t){we(t,!0),Je(e,zr);var n=Ur();n.__click=function(...i){t.onToggle?.apply(this,i)},n.__keydown=[Fr,t];var r=Ge(n);Ee(()=>{ue(n,"aria-expanded",t.open?"true":"false"),ue(r,"src",`${t.assetsUrl}/fab.svg`)}),le(e,n),be()}wr(["click","keydown"]);let Qt=!1;function jr(e){Qt=e}function Wr(){return Qt}/*! js-cookie v3.0.5 | MIT */function Oe(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)e[r]=n[r]}return e}var Br={read:function(e){return e[0]==='"'&&(e=e.slice(1,-1)),e.replace(/(%[\dA-F]{2})+/gi,decodeURIComponent)},write:function(e){return encodeURIComponent(e).replace(/%(2[346BF]|3[AC-F]|40|5[BDE]|60|7[BCD])/g,decodeURIComponent)}};function Xe(e,t){function n(i,a,o){if(!(typeof document>"u")){o=Oe({},t,o),typeof o.expires=="number"&&(o.expires=new Date(Date.now()+o.expires*864e5)),o.expires&&(o.expires=o.expires.toUTCString()),i=encodeURIComponent(i).replace(/%(2[346B]|5E|60|7C)/g,decodeURIComponent).replace(/[()]/g,escape);var l="";for(var s in o)o[s]&&(l+="; "+s,o[s]!==!0&&(l+="="+o[s].split(";")[0]));return document.cookie=i+"="+e.write(a,i)+l}}function r(i){if(!(typeof document>"u"||arguments.length&&!i)){for(var a=document.cookie?document.cookie.split("; "):[],o={},l=0;l<a.length;l++){var s=a[l].split("="),f=s.slice(1).join("=");try{var u=decodeURIComponent(s[0]);if(o[u]=e.read(f,u),i===u)break}catch{}}return i?o[i]:o}}return Object.create({set:n,get:r,remove:function(i,a){n(i,"",Oe({},a,{expires:-1}))},withAttributes:function(i){return Xe(this.converter,Oe({},this.attributes,i))},withConverter:function(i){return Xe(Oe({},this.converter,i),this.attributes)}},{attributes:{value:Object.freeze(t)},converter:{value:Object.freeze(e)}})}var Xt=Xe(Br,{path:"/"});const $t="bubble-chat-window-state",en=()=>{switch(Xt.get($t)){case"open":return!0;case"closed":return!1;default:return}},tn=e=>{const t=new Date(new Date().getTime()+288e5);Xt.set($t,e,{expires:t})},$e=[];let et=en();function tt(){et=!0,tn("open"),$e.forEach(function(e){e.call(window,!0)})}function Ce(){et=!1,tn("closed"),$e.forEach(function(e){e.call(window,!1)})}function nn(){et?Ce():tt()}function Hr(){nt({type:"RESTART_CHAT"})}function Yr(e){nt({type:"CHAT_MESSAGE_FROM_GUEST",text:e})}function Gr(e){nt({type:"TRIGGER_STORY",story:e})}function nt(e){document.getElementById("chat-frame")?.contentWindow?.postMessage(e,"*")}function rn(e,t){switch(e){case"ON_CHAT_WINDOW_STATE_CHANGE":$e.push(t);break;default:throw new Error("Unsupported event "+e)}}const Vr=Object.freeze(Object.defineProperty({__proto__:null,closeChatWindow:Ce,enterGuestMessage:Yr,isChatbotLoaded:Wr,openChatWindow:tt,restartChat:Hr,subscribe:rn,toggleChatWindow:nn,triggerStory:Gr},Symbol.toStringTag,{value:"Module"}));function Kr(){return navigator.userAgent.match(/(iPad|iPhone|iPod)/g)}const Zr=()=>{Kr()&&document.querySelectorAll("html, body").forEach(e=>{e.classList.add("iOS-device")})},Jr=e=>{"gtag"in window&&typeof window.gtag=="function"?window.gtag("event","",e):"dataLayer"in window&&Array.isArray(window.dataLayer)&&window.dataLayer.push(e)},Qr=(e,t,n,r,i)=>{window.addEventListener("message",a=>{const o=a.data;switch(o.type){case"webclient.chat.started":e();break;case"webclient.chat.ended":t();break;case"webclient.window.expand":n(o.devices,o.initial);break;case"webclient.window.close":r();break;case"webclient.change.url":i(o.url);break;case"google.tag.event":Jr(o.payload);break}},!1)},Xr=e=>new Promise(t=>{const n=document.getElementById(e);n?(n.onload=()=>{t(!0)},n.onerror=()=>{console.error("Failed to load CSS file: custom.css"),t(!1)}):(console.error("No custom.css file found"),t(!1))});var $r=he('<link rel="stylesheet"/>'),ei=he("<div><!> <!></div>");const ti={hash:"svelte-1n46o8q",code:".bubble-chat.svelte-1n46o8q {font-size:16px;visibility:hidden;opacity:0;}.bubble-chat.chatbot-ready.svelte-1n46o8q {visibility:visible;opacity:1;}"};function ni(e,t){we(t,!0),Je(e,ti);let n=Qe(t,"assetsUrl",19,()=>t.server?t.server.split("?")[0]:void 0),r=Qe(t,"linkHandling",3,"default"),i=Qe(t,"chatStarted",7,!1);const a="chatbot-style";let o=L(!1),l=L(!1);Zr();let s=L(Z(en()));rn("ON_CHAT_WINDOW_STATE_CHANGE",function(y){D(s,y,!0)});function f(){i(!0)}function u(){i(!1)}function d(_,y){const ee=window.innerWidth,it=_==null||_==="all",ot=_==="desktop"&&ee>=768,si=_==="mobile"&&ee<768,li=it||ot||si;(y?O(s)!==!1:!0)&&li&&tt()}function h(){Ce()}function c(_){const y=window.innerWidth,ee=window.location.hostname,it=new URL(_).hostname,ot=ee===it;y<768&&Ce(),r()==="new-tab"?window.open(_,"_blank"):r()==="existing-tab"||ot?document.location.href=_:window.open(_,"_blank")}function v(){D(l,!0)}Qr(f,u,d,h,c),Jt(async()=>{D(o,await Xr(a),!0)});var w=ei();br(_=>{var y=$r();ue(y,"id",a),Ee(()=>ue(y,"href",`${n()}/custom.css`)),le(_,y)});var g=Ge(w);qr(g,{get assetsUrl(){return n()},get open(){return O(s)},get onToggle(){return nn}});var N=er(g,2);Mr(N,{get server(){return t.server},get referrer(){return t.referrer},get open(){return O(s)},onLoad:v}),Ee(()=>Kt(w,1,`bubble-chat ${O(o)&&O(l)?"chatbot-ready":""}`,"svelte-1n46o8q")),le(e,w),be()}const ri=e=>e.replace(/\/embed\/bundle\.js/,""),ii=e=>e.dataset?.server,oi=e=>{if(e&&"src"in e&&typeof e.src=="string")return ii(e)||ri(e.src)},rt=document.querySelector("script#chatbot"),on=oi(rt),ai=rt?.getAttribute("link-handling")?rt.getAttribute("link-handling"):"default";window.chatbot=Vr;const an=()=>{console.log("Chatbot is loading from",on),Er(ni,{target:document.body,props:{server:on,referrer:window.location.href,linkHandling:ai}}),jr(!0)},sn=(e=0)=>{e>=3||document.readyState==="complete"?setTimeout(an,500):setTimeout(()=>{sn(e+1)},500)};sn();const Ae=document.getElementById("chatbot");Ae&&"src"in Ae&&typeof Ae.src=="string"&&Ae.src.indexOf("caller=bookmarklet")>0&&setTimeout(an,500)})();
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@botfabrik/engine-webclient",
3
- "version": "4.99.6",
3
+ "version": "4.99.8",
4
4
  "description": "Webclient for Botfabriks Bot Engine",
5
5
  "main": "dist/index.js",
6
6
  "types": "dist/index.d.ts",
@@ -21,7 +21,7 @@
21
21
  },
22
22
  "dependencies": {
23
23
  "@botfabrik/engine-domain": "^4.98.4",
24
- "@botfabrik/engine-transcript-export": "^4.99.6",
24
+ "@botfabrik/engine-transcript-export": "^4.99.8",
25
25
  "@botfabrik/engine-utils": "^4.98.4",
26
26
  "@google-cloud/speech": "^7.2.0",
27
27
  "@node-saml/passport-saml": "^5.1.0",
@@ -29,8 +29,7 @@
29
29
  "express": "^5.1.0",
30
30
  "flat": "^6.0.1",
31
31
  "jsonwebtoken": "^9.0.2",
32
- "passport": "^0.7.0",
33
- "uuid": "^11.1.0"
32
+ "passport": "^0.7.0"
34
33
  },
35
34
  "devDependencies": {
36
35
  "@types/accept-language-parser": "^1.5.8",
@@ -44,5 +43,5 @@
44
43
  "tsx": "^4.20.5",
45
44
  "typescript": "5.9.2"
46
45
  },
47
- "gitHead": "32688c7f600d01f340bfc86f97e83ca5efe814b7"
46
+ "gitHead": "23681ee7234a49e3b6e99f2900fbea869a95f622"
48
47
  }