@8wave/ai-elements 0.125.0-beta.14 → 0.125.0-beta.16

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.
Files changed (25) hide show
  1. package/dist/_chunks/{PkFilePreview-rAHDDtGS.js → PkFilePreview-8nVPKv8k.js} +348 -320
  2. package/dist/_chunks/PkFilePreview-8nVPKv8k.js.map +1 -0
  3. package/dist/_chunks/{PkFilePreviewDialog-BBFrC_rn.js → PkFilePreviewDialog-BHPcGlnF.js} +6 -3
  4. package/dist/_chunks/PkFilePreviewDialog-BHPcGlnF.js.map +1 -0
  5. package/dist/ai-elements.es.js +115 -115
  6. package/dist/ai-elements.es.js.map +1 -1
  7. package/dist-vue/PkChatbot.js +1 -1
  8. package/dist-vue/PkChatbotViewChat.js +1 -1
  9. package/dist-vue/_chunks/{PkChatbot-D48q-ulR.js → PkChatbot-Bpo22_yE.js} +2 -2
  10. package/dist-vue/_chunks/{PkChatbot-D48q-ulR.js.map → PkChatbot-Bpo22_yE.js.map} +1 -1
  11. package/dist-vue/_chunks/{PkChatbotViewChat-lLX_msKI.js → PkChatbotViewChat-Drp0At_n.js} +284 -284
  12. package/dist-vue/_chunks/PkChatbotViewChat-Drp0At_n.js.map +1 -0
  13. package/dist-vue/_chunks/{PkFilePreview-Ac_8QIBX.js → PkFilePreview-z7JcRtjP.js} +527 -499
  14. package/dist-vue/_chunks/PkFilePreview-z7JcRtjP.js.map +1 -0
  15. package/dist-vue/_chunks/{PkFilePreviewDialog-DGBaeZ8y.js → PkFilePreviewDialog-zVon3aPY.js} +6 -3
  16. package/dist-vue/_chunks/PkFilePreviewDialog-zVon3aPY.js.map +1 -0
  17. package/dist-vue/index.js +3 -3
  18. package/dist-vue/packages/components/src/chat/PkFilePreviewDialog.d.ts +2 -2
  19. package/dist-vue/style.css +1 -1
  20. package/package.json +1 -1
  21. package/dist/_chunks/PkFilePreview-rAHDDtGS.js.map +0 -1
  22. package/dist/_chunks/PkFilePreviewDialog-BBFrC_rn.js.map +0 -1
  23. package/dist-vue/_chunks/PkChatbotViewChat-lLX_msKI.js.map +0 -1
  24. package/dist-vue/_chunks/PkFilePreview-Ac_8QIBX.js.map +0 -1
  25. package/dist-vue/_chunks/PkFilePreviewDialog-DGBaeZ8y.js.map +0 -1
@@ -11,14 +11,14 @@ import { t as v } from "./PkChatbotQueuedMessages-CIJFAvE2.js";
11
11
  import { t as ee } from "./PkChatbotEmptyState-CQ_Qdkge.js";
12
12
  import { t as te } from "./PkChatbotWakeupBar-DEP-d-Fp.js";
13
13
  import { VvIcon as ne } from "@volverjs/ui-vue/components";
14
- import { Fragment as y, Teleport as b, Transition as x, computed as S, createBlock as C, createCommentVNode as w, createElementBlock as T, createElementVNode as E, createSlots as re, createTextVNode as ie, createVNode as D, defineAsyncComponent as O, defineComponent as ae, inject as oe, isRef as se, nextTick as ce, normalizeClass as k, normalizeStyle as le, onBeforeUnmount as ue, onMounted as de, onScopeDispose as fe, onUnmounted as pe, openBlock as A, provide as me, ref as j, renderList as he, shallowRef as ge, toDisplayString as M, toValue as N, unref as P, useTemplateRef as F, watch as I, withCtx as L } from "vue";
14
+ import { Fragment as y, Teleport as b, Transition as x, computed as S, createBlock as C, createCommentVNode as w, createElementBlock as T, createElementVNode as E, createSlots as re, createTextVNode as ie, createVNode as D, defineAsyncComponent as O, defineComponent as k, inject as ae, isRef as oe, nextTick as se, normalizeClass as A, normalizeStyle as ce, onBeforeUnmount as le, onMounted as ue, onScopeDispose as de, onUnmounted as fe, openBlock as j, provide as pe, ref as M, renderList as me, shallowRef as he, toDisplayString as N, toValue as P, unref as F, useTemplateRef as ge, watch as I, withCtx as L } from "vue";
15
15
  import { useI18n as _e } from "vue-i18n";
16
16
  import { useDropZone as ve, useResizeObserver as ye } from "@vueuse/core";
17
17
  import { storeToRefs as be } from "pinia";
18
18
  // ../../packages/composable/src/chatbot/useGreeting.ts
19
19
  function xe(e, t) {
20
20
  let { locale: n, t: r, te: i } = _e({ useScope: "global" });
21
- return S(() => Se(N(e)?.greeting?.[0]?.[n.value] ?? "", N(t)) || (i("message.defaultAgentWelcome") ? r("message.defaultAgentWelcome") : ""));
21
+ return S(() => Se(P(e)?.greeting?.[0]?.[n.value] ?? "", P(t)) || (i("message.defaultAgentWelcome") ? r("message.defaultAgentWelcome") : ""));
22
22
  }
23
23
  function Se(e, t) {
24
24
  return (t ? e.replace(/\{name\}/g, t) : e.replace(/[,\s]*\{name\}[!?]?/g, "")).trim();
@@ -27,7 +27,7 @@ function Se(e, t) {
27
27
  var R = {
28
28
  key: 1,
29
29
  class: "pk-aurora__fallback"
30
- }, z = "\nattribute vec2 a_position;\nvoid main() {\n gl_Position = vec4(a_position, 0.0, 1.0);\n}", Ce = "\nprecision mediump float;\nuniform vec2 u_resolution;\nuniform float u_time;\nuniform vec3 u_color;\nuniform vec3 u_color2;\nuniform float u_duo;\nuniform vec2 u_center;\nuniform vec2 u_half;\nuniform float u_spread;\n\nvec3 permute(vec3 x) { return mod(((x * 34.0) + 1.0) * x, 289.0); }\n\nfloat snoise(vec2 v) {\n const vec4 C = vec4(0.211324865405187, 0.366025403784439,\n -0.577350269189626, 0.024390243902439);\n vec2 i = floor(v + dot(v, C.yy));\n vec2 x0 = v - i + dot(i, C.xx);\n vec2 i1 = (x0.x > x0.y) ? vec2(1.0, 0.0) : vec2(0.0, 1.0);\n vec4 x12 = x0.xyxy + C.xxzz;\n x12.xy -= i1;\n i = mod(i, 289.0);\n vec3 p = permute(permute(i.y + vec3(0.0, i1.y, 1.0))\n + i.x + vec3(0.0, i1.x, 1.0));\n vec3 m = max(0.5 - vec3(dot(x0, x0), dot(x12.xy, x12.xy),\n dot(x12.zw, x12.zw)), 0.0);\n m = m * m;\n m = m * m;\n vec3 x = 2.0 * fract(p * C.www) - 1.0;\n vec3 h = abs(x) - 0.5;\n vec3 ox = floor(x + 0.5);\n vec3 a0 = x - ox;\n m *= 1.79284291400159 - 0.85373472095314 * (a0 * a0 + h * h);\n vec3 g;\n g.x = a0.x * x0.x + h.x * x0.y;\n g.yz = a0.yz * x12.xz + h.yz * x12.yw;\n return 130.0 * dot(m, g);\n}\n\nvoid main() {\n vec2 px = gl_FragCoord.xy;\n vec2 rel = px - u_center;\n\n // Ignition: the ellipse lights up expanding from the center on mount\n float intro = smoothstep(0.0, 1.4, u_time);\n\n // Breathing: size and brightness oscillate gently but visibly\n float breath = 1.0\n + 0.12 * sin(u_time * 0.55)\n + 0.06 * snoise(vec2(u_time * 0.1, 3.7));\n float pulse = 1.0 + 0.2 * sin(u_time * 0.55 + 1.3);\n\n // Keep it simple (Gemini-style): one huge soft elliptical glow\n // centered on the pill\n vec2 radii = vec2(u_half.x * 0.95, u_half.y * 6.5)\n * u_spread\n * breath\n * mix(0.15, 1.0, intro);\n float r = length(rel / max(radii, vec2(1.0)));\n float glow = exp(-r * r * 2.2);\n\n // Never cut hard against the canvas bounds\n vec2 m = min(px, u_resolution - px);\n glow *= smoothstep(0.0, 32.0, min(m.x, m.y));\n\n // Dither: breaks the 8-bit banding rings of the very soft gradient\n // (no CSS blur on the canvas, the noise must fully mask the bands)\n glow = max(glow + (snoise(px * 0.9) - 0.5) * 0.03, 0.0);\n\n float alpha = glow * 0.2 * pulse * intro;\n\n // Two tones: left to right the glow passes from the first to the\n // second, along a border a slow noise field keeps bending\n vec2 q = rel / max(radii, vec2(1.0));\n float bands = q.x * 0.9\n + 0.7 * snoise(q * 0.8 + vec2(u_time * 0.07, -u_time * 0.05));\n vec3 color = mix(u_color, u_color2, u_duo * smoothstep(-0.6, 0.6, bands));\n\n // Premultiplied alpha (default canvas compositing)\n gl_FragColor = vec4(color * alpha, alpha);\n}", we = /* @__PURE__ */ ae({
30
+ }, z = "\nattribute vec2 a_position;\nvoid main() {\n gl_Position = vec4(a_position, 0.0, 1.0);\n}", Ce = "\nprecision mediump float;\nuniform vec2 u_resolution;\nuniform float u_time;\nuniform vec3 u_color;\nuniform vec3 u_color2;\nuniform float u_duo;\nuniform vec2 u_center;\nuniform vec2 u_half;\nuniform float u_spread;\n\nvec3 permute(vec3 x) { return mod(((x * 34.0) + 1.0) * x, 289.0); }\n\nfloat snoise(vec2 v) {\n const vec4 C = vec4(0.211324865405187, 0.366025403784439,\n -0.577350269189626, 0.024390243902439);\n vec2 i = floor(v + dot(v, C.yy));\n vec2 x0 = v - i + dot(i, C.xx);\n vec2 i1 = (x0.x > x0.y) ? vec2(1.0, 0.0) : vec2(0.0, 1.0);\n vec4 x12 = x0.xyxy + C.xxzz;\n x12.xy -= i1;\n i = mod(i, 289.0);\n vec3 p = permute(permute(i.y + vec3(0.0, i1.y, 1.0))\n + i.x + vec3(0.0, i1.x, 1.0));\n vec3 m = max(0.5 - vec3(dot(x0, x0), dot(x12.xy, x12.xy),\n dot(x12.zw, x12.zw)), 0.0);\n m = m * m;\n m = m * m;\n vec3 x = 2.0 * fract(p * C.www) - 1.0;\n vec3 h = abs(x) - 0.5;\n vec3 ox = floor(x + 0.5);\n vec3 a0 = x - ox;\n m *= 1.79284291400159 - 0.85373472095314 * (a0 * a0 + h * h);\n vec3 g;\n g.x = a0.x * x0.x + h.x * x0.y;\n g.yz = a0.yz * x12.xz + h.yz * x12.yw;\n return 130.0 * dot(m, g);\n}\n\nvoid main() {\n vec2 px = gl_FragCoord.xy;\n vec2 rel = px - u_center;\n\n // Ignition: the ellipse lights up expanding from the center on mount\n float intro = smoothstep(0.0, 1.4, u_time);\n\n // Breathing: size and brightness oscillate gently but visibly\n float breath = 1.0\n + 0.12 * sin(u_time * 0.55)\n + 0.06 * snoise(vec2(u_time * 0.1, 3.7));\n float pulse = 1.0 + 0.2 * sin(u_time * 0.55 + 1.3);\n\n // Keep it simple (Gemini-style): one huge soft elliptical glow\n // centered on the pill\n vec2 radii = vec2(u_half.x * 0.95, u_half.y * 6.5)\n * u_spread\n * breath\n * mix(0.15, 1.0, intro);\n float r = length(rel / max(radii, vec2(1.0)));\n float glow = exp(-r * r * 2.2);\n\n // Never cut hard against the canvas bounds\n vec2 m = min(px, u_resolution - px);\n glow *= smoothstep(0.0, 32.0, min(m.x, m.y));\n\n // Dither: breaks the 8-bit banding rings of the very soft gradient\n // (no CSS blur on the canvas, the noise must fully mask the bands)\n glow = max(glow + (snoise(px * 0.9) - 0.5) * 0.03, 0.0);\n\n float alpha = glow * 0.2 * pulse * intro;\n\n // Two tones: left to right the glow passes from the first to the\n // second, along a border a slow noise field keeps bending\n vec2 q = rel / max(radii, vec2(1.0));\n float bands = q.x * 0.9\n + 0.7 * snoise(q * 0.8 + vec2(u_time * 0.07, -u_time * 0.05));\n vec3 color = mix(u_color, u_color2, u_duo * smoothstep(-0.6, 0.6, bands));\n\n // Premultiplied alpha (default canvas compositing)\n gl_FragColor = vec4(color * alpha, alpha);\n}", we = /* @__PURE__ */ k({
31
31
  __name: "PkAuroraCanvas",
32
32
  props: {
33
33
  sourceSelector: {},
@@ -36,7 +36,7 @@ var R = {
36
36
  secondColor: {}
37
37
  },
38
38
  setup(e) {
39
- let t = e, n = F("rootEl"), r = F("canvasEl"), i = j(!1), a = j(null), o = S(() => a.value ? {
39
+ let t = e, n = ge("rootEl"), r = ge("canvasEl"), i = M(!1), a = M(null), o = S(() => a.value ? {
40
40
  "--pk-aurora-tint": `rgb(${a.value.first.join(" ")})`,
41
41
  "--pk-aurora-tint-2": `rgb(${(a.value.duo ? a.value.second : a.value.first).join(" ")})`
42
42
  } : void 0), s = null, l = 0, u = null, d = null, f = null, p = null, m = null, h = null, g = null, _ = null, v = null, ee = performance.now(), te = (e, t) => {
@@ -72,7 +72,7 @@ var R = {
72
72
  }, w = () => {
73
73
  C(), l = requestAnimationFrame(w);
74
74
  };
75
- return de(() => {
75
+ return ue(() => {
76
76
  let e = r.value;
77
77
  if (y(), s = e?.getContext("webgl", { alpha: !0 }) ?? null, !e || !s || !a.value) {
78
78
  i.value = !0;
@@ -96,28 +96,28 @@ var R = {
96
96
  1
97
97
  ]), s.STATIC_DRAW);
98
98
  let l = s.getAttribLocation(o, "a_position");
99
- s.enableVertexAttribArray(l), s.vertexAttribPointer(l, 2, s.FLOAT, !1, 0, 0), d = s.getUniformLocation(o, "u_time"), f = s.getUniformLocation(o, "u_resolution"), p = s.getUniformLocation(o, "u_center"), m = s.getUniformLocation(o, "u_half"), h = s.getUniformLocation(o, "u_spread"), g = s.getUniformLocation(o, "u_color"), _ = s.getUniformLocation(o, "u_color2"), v = s.getUniformLocation(o, "u_duo"), y(), u = new ResizeObserver(b), u.observe(e), b(), ce(b), x() ? C(10) : w();
100
- }), ue(() => {
99
+ s.enableVertexAttribArray(l), s.vertexAttribPointer(l, 2, s.FLOAT, !1, 0, 0), d = s.getUniformLocation(o, "u_time"), f = s.getUniformLocation(o, "u_resolution"), p = s.getUniformLocation(o, "u_center"), m = s.getUniformLocation(o, "u_half"), h = s.getUniformLocation(o, "u_spread"), g = s.getUniformLocation(o, "u_color"), _ = s.getUniformLocation(o, "u_color2"), v = s.getUniformLocation(o, "u_duo"), y(), u = new ResizeObserver(b), u.observe(e), b(), se(b), x() ? C(10) : w();
100
+ }), le(() => {
101
101
  cancelAnimationFrame(l), u?.disconnect();
102
- }), pe(() => {
102
+ }), fe(() => {
103
103
  let e = s;
104
104
  s = null, setTimeout(() => {
105
105
  e?.getExtension("WEBGL_lose_context")?.loseContext();
106
106
  }, 150);
107
- }), (e, t) => (A(), T("div", {
107
+ }), (e, t) => (j(), T("div", {
108
108
  ref_key: "rootEl",
109
109
  ref: n,
110
110
  class: "pk-aurora",
111
111
  "aria-hidden": "true",
112
- style: le(o.value)
113
- }, [i.value ? (A(), T("div", R)) : (A(), T("canvas", {
112
+ style: ce(o.value)
113
+ }, [i.value ? (j(), T("div", R)) : (j(), T("canvas", {
114
114
  key: 0,
115
115
  ref_key: "canvasEl",
116
116
  ref: r,
117
117
  class: "pk-aurora__canvas"
118
118
  }, null, 512))], 4));
119
119
  }
120
- }), B = .18, Te = .35, Ee = /* @__PURE__ */ ae({
120
+ }), B = .18, Te = .35, Ee = /* @__PURE__ */ k({
121
121
  __name: "PkVoiceOrb",
122
122
  props: {
123
123
  sample: {},
@@ -129,7 +129,7 @@ var R = {
129
129
  bars: { default: 5 }
130
130
  },
131
131
  setup(e) {
132
- let t = e, n = F("barsEl"), r = Array.from({ length: t.bars }, () => B), i, a = () => typeof window < "u" && window.matchMedia?.("(prefers-reduced-motion: reduce)").matches === !0, o = () => {
132
+ let t = e, n = ge("barsEl"), r = Array.from({ length: t.bars }, () => B), i, a = () => typeof window < "u" && window.matchMedia?.("(prefers-reduced-motion: reduce)").matches === !0, o = () => {
133
133
  let e = Math.min(1, Math.max(0, t.sample())), n = t.spectrum?.(), i = r.length;
134
134
  if (!n?.length) {
135
135
  let t = Date.now() / 260;
@@ -156,15 +156,15 @@ var R = {
156
156
  i !== void 0 && (cancelAnimationFrame(i), i = void 0);
157
157
  };
158
158
  return I(() => t.state, async (e) => {
159
- e !== "listening" && e !== "speaking" || a() ? (l(), r = r.map(() => B * 1.6), await ce(), s()) : i === void 0 && (i = requestAnimationFrame(c));
160
- }, { immediate: !0 }), ue(l), (t, r) => (A(), T("div", {
161
- class: k(["pk-voice-orb", `pk-voice-orb--${e.state}`]),
159
+ e !== "listening" && e !== "speaking" || a() ? (l(), r = r.map(() => B * 1.6), await se(), s()) : i === void 0 && (i = requestAnimationFrame(c));
160
+ }, { immediate: !0 }), le(l), (t, r) => (j(), T("div", {
161
+ class: A(["pk-voice-orb", `pk-voice-orb--${e.state}`]),
162
162
  "aria-hidden": "true"
163
163
  }, [E("div", {
164
164
  ref_key: "barsEl",
165
165
  ref: n,
166
166
  class: "pk-voice-orb__bars"
167
- }, [(A(!0), T(y, null, he(e.bars, (e) => (A(), T("span", {
167
+ }, [(j(!0), T(y, null, me(e.bars, (e) => (j(), T("span", {
168
168
  key: e,
169
169
  class: "pk-voice-orb__bar"
170
170
  }))), 128))], 512)], 2));
@@ -180,7 +180,7 @@ var R = {
180
180
  key: 0,
181
181
  class: "pk-voice-session__live-dot",
182
182
  "aria-hidden": "true"
183
- }, Oe = ["title"], ke = ["title"], Ae = { class: "pk-voice-session__actions" }, je = /* @__PURE__ */ ae({
183
+ }, Oe = ["title"], ke = ["title"], Ae = { class: "pk-voice-session__actions" }, je = /* @__PURE__ */ k({
184
184
  __name: "PkVoiceSession",
185
185
  props: {
186
186
  state: {},
@@ -208,8 +208,8 @@ var R = {
208
208
  });
209
209
  return (t, n) => {
210
210
  let u = ne;
211
- return A(), T("div", { class: k(["pk-voice-session", { "pk-voice-session--failed": !!e.error }]) }, [
212
- e.error ? (A(), T("span", De, [D(u, { name: "ri:error-warning-line" })])) : (A(), C(Ee, {
211
+ return j(), T("div", { class: A(["pk-voice-session", { "pk-voice-session--failed": !!e.error }]) }, [
212
+ e.error ? (j(), T("span", De, [D(u, { name: "ri:error-warning-line" })])) : (j(), C(Ee, {
213
213
  key: 1,
214
214
  state: e.state,
215
215
  sample: e.sample,
@@ -219,37 +219,37 @@ var R = {
219
219
  "sample",
220
220
  "spectrum"
221
221
  ])),
222
- E("div", V, [E("span", { class: k(["pk-voice-session__state", l.value && `pk-voice-session__state--${l.value}`]) }, [c.value ? (A(), T("span", H)) : w("", !0), ie(" " + M(a.value), 1)], 2), e.error ? (A(), T("p", {
222
+ E("div", V, [E("span", { class: A(["pk-voice-session__state", l.value && `pk-voice-session__state--${l.value}`]) }, [c.value ? (j(), T("span", H)) : w("", !0), ie(" " + N(a.value), 1)], 2), e.error ? (j(), T("p", {
223
223
  key: 0,
224
224
  class: "pk-voice-session__detail",
225
225
  title: e.rawError ?? e.error
226
- }, M(e.error), 9, Oe)) : w("", !0)]),
227
- o.value ? (A(), T("span", {
226
+ }, N(e.error), 9, Oe)) : w("", !0)]),
227
+ o.value ? (j(), T("span", {
228
228
  key: 2,
229
- class: k(["pk-voice-session__timer", { "pk-voice-session__timer--warning": s.value }]),
230
- title: P(i)("hint.voiceRemaining"),
229
+ class: A(["pk-voice-session__timer", { "pk-voice-session__timer--warning": s.value }]),
230
+ title: F(i)("hint.voiceRemaining"),
231
231
  "aria-hidden": "true"
232
- }, M(o.value), 11, ke)) : w("", !0),
233
- E("div", Ae, [e.error ? (A(), T(y, { key: 0 }, [D(g, {
232
+ }, N(o.value), 11, ke)) : w("", !0),
233
+ E("div", Ae, [e.error ? (j(), T(y, { key: 0 }, [D(g, {
234
234
  icon: "ri:refresh-line",
235
- label: P(i)("action.retry"),
235
+ label: F(i)("action.retry"),
236
236
  onClick: n[0] ||= (e) => r("retry")
237
- }, null, 8, ["label"]), e.live ? (A(), C(g, {
237
+ }, null, 8, ["label"]), e.live ? (j(), C(g, {
238
238
  key: 0,
239
239
  icon: "ri:stop-circle-line",
240
240
  modifiers: "danger",
241
- title: P(i)("action.hangUp"),
242
- "aria-label": P(i)("action.hangUp"),
241
+ title: F(i)("action.hangUp"),
242
+ "aria-label": F(i)("action.hangUp"),
243
243
  onClick: n[1] ||= (e) => r("hang-up")
244
- }, null, 8, ["title", "aria-label"])) : (A(), C(g, {
244
+ }, null, 8, ["title", "aria-label"])) : (j(), C(g, {
245
245
  key: 1,
246
246
  icon: "ri:close-line",
247
- label: P(i)("action.close"),
247
+ label: F(i)("action.close"),
248
248
  onClick: n[2] ||= (e) => r("dismiss")
249
- }, null, 8, ["label"]))], 64)) : (A(), T(y, { key: 1 }, [D(g, {
249
+ }, null, 8, ["label"]))], 64)) : (j(), T(y, { key: 1 }, [D(g, {
250
250
  icon: e.muted ? "ri:mic-off-line" : "ri:mic-line",
251
- title: e.muted ? P(i)("action.unmute") : P(i)("action.mute"),
252
- "aria-label": e.muted ? P(i)("action.unmute") : P(i)("action.mute"),
251
+ title: e.muted ? F(i)("action.unmute") : F(i)("action.mute"),
252
+ "aria-label": e.muted ? F(i)("action.unmute") : F(i)("action.mute"),
253
253
  "aria-pressed": e.muted,
254
254
  onClick: n[3] ||= (e) => r("toggle-mute")
255
255
  }, null, 8, [
@@ -260,15 +260,15 @@ var R = {
260
260
  ]), D(g, {
261
261
  icon: "ri:stop-circle-line",
262
262
  modifiers: "danger",
263
- title: P(i)("action.hangUp"),
264
- "aria-label": P(i)("action.hangUp"),
263
+ title: F(i)("action.hangUp"),
264
+ "aria-label": F(i)("action.hangUp"),
265
265
  onClick: n[4] ||= (e) => r("hang-up")
266
266
  }, null, 8, ["title", "aria-label"])], 64))])
267
267
  ], 2);
268
268
  };
269
269
  }
270
270
  }), Me = (e) => {
271
- let t = ge(), n = j("disconnected"), r = j("listening"), i = j(), o = j([]), s = j(), c = j(), l, u, d = 0, f = !1, p = () => {
271
+ let t = he(), n = M("disconnected"), r = M("listening"), i = M(), o = M([]), s = M(), c = M(), l, u, d = 0, f = !1, p = () => {
272
272
  u &&= (clearInterval(u), void 0), s.value = void 0;
273
273
  }, m = (e) => {
274
274
  let t = Date.now() + e * 1e3, n = () => {
@@ -371,7 +371,7 @@ var R = {
371
371
  let r = t.value;
372
372
  t.value = void 0, r?.endSession().catch(() => void 0), n.value = "disconnected";
373
373
  };
374
- return typeof window < "u" && window.addEventListener("pagehide", b), fe(() => {
374
+ return typeof window < "u" && window.addEventListener("pagehide", b), de(() => {
375
375
  f = !0, typeof window < "u" && window.removeEventListener("pagehide", b), g();
376
376
  }), {
377
377
  status: n,
@@ -394,10 +394,10 @@ var R = {
394
394
  };
395
395
  }, Ne = Symbol("ChatFilePreviewDock");
396
396
  function Pe(e) {
397
- me(Ne, e);
397
+ pe(Ne, e);
398
398
  }
399
399
  function Fe() {
400
- return oe(Ne, void 0);
400
+ return ae(Ne, void 0);
401
401
  }
402
402
  // ../../packages/components/src/chat/useWakeupWatch.ts
403
403
  var Ie = 4e3, Le = [
@@ -406,7 +406,7 @@ var Ie = 4e3, Le = [
406
406
  1e4
407
407
  ], Re = 12e4, U = 3e4;
408
408
  function ze(e) {
409
- let t = j(null), n = j(!1), r, i = !1, a = () => {
409
+ let t = M(null), n = M(!1), r, i = !1, a = () => {
410
410
  clearTimeout(r), r = void 0;
411
411
  }, o = (e, t) => {
412
412
  a(), i || (r = setTimeout(() => void t(), e));
@@ -467,7 +467,7 @@ function ze(e) {
467
467
  let ee = () => v();
468
468
  return document.addEventListener("visibilitychange", ee), I(() => t.value?.wakeId, (e) => {
469
469
  clearInterval(_), _ = void 0, e && !i && (v(), _ = setInterval(v, U));
470
- }), ue(() => {
470
+ }), le(() => {
471
471
  i = !0, a(), clearInterval(_), document.removeEventListener("visibilitychange", ee);
472
472
  }), {
473
473
  pendingWakeup: t,
@@ -482,7 +482,7 @@ function ze(e) {
482
482
  }
483
483
  // ../../packages/components/src/chat/useChatFilePreview.ts
484
484
  function Be(e) {
485
- let t = j(), n = j(), r = j(!1), i = j(!1), a = /* @__PURE__ */ new Map(), o = 0, s = 0, c = async (c) => {
485
+ let t = M(), n = M(), r = M(!1), i = M(!1), a = /* @__PURE__ */ new Map(), o = 0, s = 0, c = async (c) => {
486
486
  let l = ++o, u = s;
487
487
  t.value = c, i.value = !1;
488
488
  let d = a.get(c.storedFileName);
@@ -522,7 +522,7 @@ var Ve = { class: "pk-chatbot-view-chat__input-stage" }, He = {
522
522
  }, Ge = {
523
523
  key: 0,
524
524
  class: "pk-chatbot-view-chat__drop-overlay"
525
- }, Ke = 1e3, qe = 3e3, Je = 6e4, Ye = 3e5, Xe = 6e5, Ze = /* @__PURE__ */ ae({
525
+ }, Ke = 1e3, qe = 3e3, Je = 6e4, Ye = 3e5, Xe = 6e5, Ze = /* @__PURE__ */ k({
526
526
  __name: "PkChatbotViewChat",
527
527
  props: {
528
528
  agentId: {},
@@ -535,9 +535,9 @@ var Ve = { class: "pk-chatbot-view-chat__input-stage" }, He = {
535
535
  "selection-action"
536
536
  ],
537
537
  setup(a, { emit: c }) {
538
- let g = O(() => import("./PkToolShowForm-BXol1WE3.js").then((e) => e.n)), y = O(() => import("./PkToolShowContactForm-DzttQBG6.js").then((e) => e.n)), ie = O(() => import("./PkToolShowSuggestedReply-DHCqxA1P.js").then((e) => e.n)), ae = O(() => import("./PkToolShowSources-BHRNGn4s.js").then((e) => e.n)), oe = O(() => import("./PkToolRequestGeolocation-BnV7A6SW.js").then((e) => e.n)), ce = O(() => import("./PkToolRequestOAuthConnection-QCbQ7bnl.js")), le = O(() => import("./PkToolShowLocation-DCPaDtBI.js").then((e) => e.n)), de = O(() => import("./PkToolShowDiagram-BNa89wcw.js")), fe = O(() => import("./PkToolChatFile-DqLGwJxp.js").then((e) => e.n)), pe = O(() => import("./PkToolShareDocument-BIZkgcJ3.js").then((e) => e.n)), he = O(() => import("./PkFilePreview-Ac_8QIBX.js").then((e) => e.n)), ge = O(() => import("./PkFilePreviewDialog-DGBaeZ8y.js").then((e) => e.n)), N = a, Se = c, R = r(N.agentId), { agentInterface: z, agentFileUpload: Ce, agentType: B, agentVoice: Te, actions: Ee, revisedAnswers: De, messages: V, chat: H, messageFeedbacks: Oe, feedbackDialogMessage: ke, isFeedbackSubmitting: Ae, isFeedbackSubmitted: Ne, feedbackSubmitError: Pe, isLeadSubmitted: Ie, isLoadingSubmitLead: Le, submitLeadError: Re, input: U, inputMessagePlaceholder: Ze, isConversationBlocked: Qe, baseUrl: $e, pendingAttachments: et, isAttachmentLimitReached: tt, fileLimitError: nt, apiClient: W, isDark: rt, hostToolsPending: it, pageNoticeLevel: at, hostConfirmation: ot, agentPageAccess: st, hostStepTitles: ct, hostStepChanges: lt, confirmationMode: ut, canQueue: dt, queuedMessages: ft, backgroundAnswers: pt, inputFocusRequest: mt, pagePointer: G, pagePointerAvailable: ht, pagePointing: gt, agentSelectionActions: _t } = be(R);
539
- me(f, ct), me(d, lt);
540
- let vt = F("inputEl");
538
+ let g = O(() => import("./PkToolShowForm-BXol1WE3.js").then((e) => e.n)), y = O(() => import("./PkToolShowContactForm-DzttQBG6.js").then((e) => e.n)), ie = O(() => import("./PkToolShowSuggestedReply-DHCqxA1P.js").then((e) => e.n)), k = O(() => import("./PkToolShowSources-BHRNGn4s.js").then((e) => e.n)), ae = O(() => import("./PkToolRequestGeolocation-BnV7A6SW.js").then((e) => e.n)), se = O(() => import("./PkToolRequestOAuthConnection-QCbQ7bnl.js")), ce = O(() => import("./PkToolShowLocation-DCPaDtBI.js").then((e) => e.n)), ue = O(() => import("./PkToolShowDiagram-BNa89wcw.js")), de = O(() => import("./PkToolChatFile-DqLGwJxp.js").then((e) => e.n)), fe = O(() => import("./PkToolShareDocument-BIZkgcJ3.js").then((e) => e.n)), me = O(() => import("./PkFilePreview-z7JcRtjP.js").then((e) => e.n)), he = O(() => import("./PkFilePreviewDialog-zVon3aPY.js").then((e) => e.n)), P = a, Se = c, R = r(P.agentId), { agentInterface: z, agentFileUpload: Ce, agentType: B, agentVoice: Te, actions: Ee, revisedAnswers: De, messages: V, chat: H, messageFeedbacks: Oe, feedbackDialogMessage: ke, isFeedbackSubmitting: Ae, isFeedbackSubmitted: Ne, feedbackSubmitError: Pe, isLeadSubmitted: Ie, isLoadingSubmitLead: Le, submitLeadError: Re, input: U, inputMessagePlaceholder: Ze, isConversationBlocked: Qe, baseUrl: $e, pendingAttachments: et, isAttachmentLimitReached: tt, fileLimitError: nt, apiClient: W, isDark: rt, hostToolsPending: it, pageNoticeLevel: at, hostConfirmation: ot, agentPageAccess: st, hostStepTitles: ct, hostStepChanges: lt, confirmationMode: ut, canQueue: dt, queuedMessages: ft, backgroundAnswers: pt, inputFocusRequest: mt, pagePointer: G, pagePointerAvailable: ht, pagePointing: gt, agentSelectionActions: _t } = be(R);
539
+ pe(f, ct), pe(d, lt);
540
+ let vt = ge("inputEl");
541
541
  I(mt, () => {
542
542
  vt.value?.focus();
543
543
  }), I(G, (e) => {
@@ -546,46 +546,51 @@ var Ve = { class: "pk-chatbot-view-chat__input-stage" }, He = {
546
546
  let yt = S(() => G.value ? {
547
547
  kind: G.value.kind,
548
548
  label: G.value.label
549
- } : void 0), K = S(() => B.value === "reasoning" ? void 0 : Ce.value), q = (e) => W.value.getMediaDownloadUrl(N.agentId, R.localChatId, e), { handleSubmit: bt, stopGeneration: xt, regenerate: St, onUpvote: Ct, onDownvote: wt, onFeedback: Tt, onFeedbackSubmit: Et, onLeadSubmit: Dt, startNewChat: Ot, addToolOutput: kt, addToolApprovalResponse: At, handleFileSelect: jt, clearFileLimitError: Mt, refreshMessages: Nt, appendMessage: Pt, closePageNotice: Ft, respondHostConfirmation: It, editQueuedMessage: Lt, removeQueuedMessage: Rt, openBackgroundAnswer: zt, dismissBackgroundAnswer: Bt } = R, { t: J } = _e({ useScope: "global" }), Vt = S(() => it.value > 0), Ht = S(() => Vt.value && H.value.status === "ready" ? "streaming" : H.value.status), Ut = m(() => st.value?.notice), Wt = S(() => at.value ? Ut.value || J(`message.pageAccessNotice.${at.value}`) : void 0), Gt = S(() => {
549
+ } : void 0), K = S(() => B.value === "reasoning" ? void 0 : Ce.value), q = (e) => W.value.getMediaDownloadUrl(P.agentId, R.localChatId, e), { handleSubmit: bt, stopGeneration: xt, regenerate: St, onUpvote: Ct, onDownvote: wt, onFeedback: Tt, onFeedbackSubmit: Et, onLeadSubmit: Dt, startNewChat: Ot, addToolOutput: kt, addToolApprovalResponse: At, handleFileSelect: jt, clearFileLimitError: Mt, refreshMessages: Nt, appendMessage: Pt, closePageNotice: Ft, respondHostConfirmation: It, editQueuedMessage: Lt, removeQueuedMessage: Rt, openBackgroundAnswer: zt, dismissBackgroundAnswer: Bt } = R, { t: J } = _e({ useScope: "global" }), Vt = S(() => it.value > 0), Ht = S(() => Vt.value && H.value.status === "ready" ? "streaming" : H.value.status), Ut = m(() => st.value?.notice), Wt = S(() => at.value ? Ut.value || J(`message.pageAccessNotice.${at.value}`) : void 0), Gt = S(() => {
550
550
  let e = nt.value;
551
551
  if (e) return e.reason === "per-chat" ? J("message.fileLimitPerChat", { max: e.max }) : J("message.fileLimitPerMessage", { max: e.max });
552
552
  }), Kt = S(() => pt.value.map(({ chatId: e, title: t }) => ({
553
553
  id: e,
554
554
  text: t ? J("message.backgroundAnswerReady", { title: t }) : J("message.backgroundAnswerReadyUntitled")
555
- }))), qt = m(() => z.value?.dismissableNotice), Jt = S(() => V.value.some((e) => e.role === "user")), Yt = S(() => N.modifier === "fullscreen" && !Jt.value), Xt = xe(z, () => N.userName), Zt = F("chatViewEl"), Qt = Fe(), $t = S(() => !!Qt?.value), en = S(() => Qt?.value ?? "body"), tn = j(0), nn = j(0);
555
+ }))), qt = m(() => z.value?.dismissableNotice), Jt = S(() => V.value.some((e) => e.role === "user")), Yt = S(() => P.modifier === "fullscreen" && !Jt.value), Xt = xe(z, () => P.userName), Zt = ge("chatViewEl"), Qt = Fe(), $t = S(() => !!Qt?.value), en = S(() => Qt?.value ?? "body"), tn = M(0), nn = M(0);
556
556
  ye([Zt, S(() => Qt?.value ?? void 0)], (e) => {
557
557
  for (let t of e) {
558
558
  let e = t.borderBoxSize?.[0]?.inlineSize ?? t.contentRect.width;
559
559
  t.target === Zt.value ? tn.value = e : nn.value = e;
560
560
  }
561
561
  }, { box: "border-box" });
562
- let rn = S(() => tn.value + ($t.value ? nn.value : 0) >= Ke), an = S(() => tn.value > 0 && tn.value < 576), { target: Y, preview: on, loading: sn, error: cn, open: ln, close: un, reset: dn } = Be((e) => W.value.getChatFilePreview(N.agentId, R.localChatId, e)), X = j({}), fn = (e) => {
562
+ let rn = S(() => tn.value + ($t.value ? nn.value : 0) >= Ke), an = S(() => tn.value > 0 && tn.value < 576), { target: Y, preview: on, loading: sn, error: cn, open: ln, close: un, reset: dn } = Be((e) => W.value.getChatFilePreview(P.agentId, R.localChatId, e)), X = M({}), fn = (e) => {
563
563
  let t = (e) => e?.fileId ?? e?.storedFileName;
564
564
  return t(e) !== t(Y.value) && (X.value = {}), ln(e);
565
- }, pn = j(!1), mn = S(() => !!Y.value && rn.value && !pn.value), hn = () => {
565
+ }, pn = M(!1), mn = S(() => !!Y.value && rn.value && !pn.value), hn = () => {
566
566
  un(), pn.value = !1;
567
- }, gn = S(() => {
567
+ }, gn = /* @__PURE__ */ new Set([
568
+ "tool-editSpreadsheet",
569
+ "tool-editWordDocument",
570
+ "tool-createSpreadsheet",
571
+ "tool-createWordDocument"
572
+ ]), _n = S(() => {
568
573
  let e = /* @__PURE__ */ new Map();
569
574
  for (let t of V.value) for (let n of t.parts) {
570
575
  let { type: t, state: r, output: i } = n;
571
- if (nr.has(t) && r === "output-available" && i?.fileId && i.version && i.storedFileName) {
576
+ if (gn.has(t) && r === "output-available" && i?.fileId && i.version && i.storedFileName) {
572
577
  let t = e.get(i.fileId) ?? /* @__PURE__ */ new Map();
573
578
  t.set(i.version, i.storedFileName), e.set(i.fileId, t);
574
579
  }
575
580
  }
576
581
  for (let [t, n] of e) n.has(1) || n.set(1, t);
577
582
  return e;
578
- }), _n = S(() => [...gn.value.get(Y.value?.fileId ?? "")?.keys() ?? []].sort((e, t) => e - t)), vn = (e) => {
579
- let t = Y.value, n = gn.value.get(t?.fileId ?? "")?.get(e);
583
+ }), vn = S(() => [..._n.value.get(Y.value?.fileId ?? "")?.keys() ?? []].sort((e, t) => e - t)), yn = (e) => {
584
+ let t = Y.value, n = _n.value.get(t?.fileId ?? "")?.get(e);
580
585
  t && n && fn({
581
586
  ...t,
582
587
  version: e,
583
588
  storedFileName: n
584
589
  });
585
- }, yn = S(() => {
586
- let e = Y.value, t = _n.value;
590
+ }, bn = S(() => {
591
+ let e = Y.value, t = vn.value;
587
592
  return !!$.value && !!e?.fileId && !!e.version && t.length > 0 && e.version < t[t.length - 1];
588
- }), bn = () => {
593
+ }), xn = () => {
589
594
  let e = Y.value;
590
595
  e?.fileId && e.version && ($.value?.({
591
596
  fileId: e.fileId,
@@ -593,81 +598,81 @@ var Ve = { class: "pk-chatbot-view-chat__input-stage" }, He = {
593
598
  filename: e.filename
594
599
  }), hn());
595
600
  };
596
- I(() => R.localChatId, dn), I(gn, (e, t) => {
601
+ I(() => R.localChatId, dn), I(_n, (e, t) => {
597
602
  let n = Y.value, r = n?.fileId;
598
603
  if (!r || !n.version) return;
599
604
  let i = (e) => Math.max(0, ...e?.get(r)?.keys() ?? []), a = i(e);
600
- a > i(t) && n.version === i(t) && vn(a);
605
+ a > i(t) && n.version === i(t) && yn(a);
601
606
  });
602
- let xn = S(() => {
607
+ let Sn = S(() => {
603
608
  let e = H.value?.status;
604
609
  if (!(Qe.value || e === "submitted" || e === "streaming")) return Y.value?.kind === "word" ? _t.value?.word : _t.value?.excel;
605
- }), Sn = (e, t, n) => {
610
+ }), Cn = (e, t, n) => {
606
611
  R.sendSelection(e, { filePointer: t }) && Se("selection-action", {
607
612
  surface: t.format === "docx" ? "word" : "excel",
608
613
  action: n.id,
609
614
  state: "chat",
610
615
  size: String(n.size)
611
616
  });
612
- }, Cn = async (e) => (await W.value.expandSourceContext(N.agentId, e.documentId, e.chunkIndex)).content, wn = async (e) => {
613
- let t = await W.value.downloadSourceDocument(N.agentId, e);
617
+ }, wn = async (e) => (await W.value.expandSourceContext(P.agentId, e.documentId, e.chunkIndex)).content, Tn = async (e) => {
618
+ let t = await W.value.downloadSourceDocument(P.agentId, e);
614
619
  window.open(t.downloadUrl, "_blank");
615
- }, { isOverDropZone: Tn } = ve(Zt, {
620
+ }, { isOverDropZone: En } = ve(Zt, {
616
621
  dataTypes: (e) => t(e, K.value?.allowedMimeTypes ?? []),
617
622
  onDrop: (e) => {
618
623
  if (K.value?.enabled && e) for (let t of e) jt(t);
619
624
  }
620
- }), En = j(!1), Dn = !1, Z = j(!1), On = [
625
+ }), Dn = M(!1), On = !1, Z = M(!1), kn = [
621
626
  3e3,
622
627
  5e3,
623
628
  1e4
624
- ], kn, An, jn = !1, Mn = 0, Nn = !1;
625
- function Pn() {
626
- clearTimeout(kn), kn = void 0, An = void 0, jn = !1, Mn = 0, Z.value = !1;
629
+ ], An, jn, Mn = !1, Nn = 0, Pn = !1;
630
+ function Fn() {
631
+ clearTimeout(An), An = void 0, jn = void 0, Mn = !1, Nn = 0, Z.value = !1;
627
632
  }
628
- function Fn(e) {
629
- Dn || (clearTimeout(kn), kn = setTimeout(() => {
630
- In();
633
+ function In(e) {
634
+ On || (clearTimeout(An), An = setTimeout(() => {
635
+ Ln();
631
636
  }, e));
632
637
  }
633
- async function In() {
634
- if (Dn || Nn) return;
635
- Nn = !0;
638
+ async function Ln() {
639
+ if (On || Pn) return;
640
+ Pn = !0;
636
641
  let e;
637
642
  try {
638
643
  e = await Nt();
639
644
  } finally {
640
- Nn = !1;
645
+ Pn = !1;
641
646
  }
642
- if (Dn) return;
647
+ if (On) return;
643
648
  if (e === "caught-up" && (Z.value = !1, pr()), Q.isActive.value) {
644
- An = void 0, jn = !1, Mn = 0, Fn(qe);
649
+ jn = void 0, Mn = !1, Nn = 0, In(qe);
645
650
  return;
646
651
  }
647
- An === void 0 && (An = Date.now(), jn = !!Q.error.value);
648
- let t = Date.now() - An;
649
- if (e === "caught-up" && t >= (jn ? Ye : Je) || t >= Xe) {
650
- Pn(), mr();
652
+ jn === void 0 && (jn = Date.now(), Mn = !!Q.error.value);
653
+ let t = Date.now() - jn;
654
+ if (e === "caught-up" && t >= (Mn ? Ye : Je) || t >= Xe) {
655
+ Fn(), mr();
651
656
  return;
652
657
  }
653
- let n = On[Math.min(Mn, On.length - 1)];
654
- Mn += 1, Fn(n);
658
+ let n = kn[Math.min(Nn, kn.length - 1)];
659
+ Nn += 1, In(n);
655
660
  }
656
- let Ln = (e = 1200) => {
657
- Fn(e);
658
- }, Rn, Q = Me({
661
+ let Rn = (e = 1200) => {
662
+ In(e);
663
+ }, zn, Q = Me({
659
664
  fetchGrant: async () => {
660
- Rn = R.voicePageTools();
661
- let e = await W.value.createVoiceSession(N.agentId, R.localChatId, {
665
+ zn = R.voicePageTools();
666
+ let e = await W.value.createVoiceSession(P.agentId, R.localChatId, {
662
667
  deviceContext: R.buildDeviceContext(),
663
668
  externalContext: R.externalContext,
664
- pageTools: Rn?.declaration,
669
+ pageTools: zn?.declaration,
665
670
  ...R.confirmationMode === "automatic" && { confirmations: "automatic" }
666
671
  });
667
672
  return e.chatId !== R.localChatId && (R.localChatId = e.chatId), e;
668
673
  },
669
- closeGrant: (e) => W.value.closeVoiceSession(N.agentId, e),
670
- clientTools: () => Rn?.clientTools,
674
+ closeGrant: (e) => W.value.closeVoiceSession(P.agentId, e),
675
+ clientTools: () => zn?.clientTools,
671
676
  onTranscript: (e) => {
672
677
  e.role === "user" ? (Z.value = !0, fr(), Pt({
673
678
  id: `${i}user-${n()}`,
@@ -679,7 +684,7 @@ var Ve = { class: "pk-chatbot-view-chat__input-stage" }, He = {
679
684
  })) : Z.value = !1;
680
685
  },
681
686
  onTurnEnd: () => {
682
- Ln();
687
+ Rn();
683
688
  }
684
689
  });
685
690
  I(() => Q.isActive.value, (e) => {
@@ -687,40 +692,35 @@ var Ve = { class: "pk-chatbot-view-chat__input-stage" }, He = {
687
692
  }), I(() => Q.error.value, (e) => {
688
693
  e && (Z.value = !1);
689
694
  });
690
- let zn = S(() => Te.value?.enabled === !0), Bn = S(() => Q.error.value ? "error" : Q.isConnecting.value ? "connecting" : Q.isSpeaking.value ? "speaking" : Q.isActive.value ? "listening" : "idle"), Vn = S(() => {
695
+ let Bn = S(() => Te.value?.enabled === !0), Vn = S(() => Q.error.value ? "error" : Q.isConnecting.value ? "connecting" : Q.isSpeaking.value ? "speaking" : Q.isActive.value ? "listening" : "idle"), Hn = S(() => {
691
696
  let e = Q.error.value;
692
697
  if (e) return /took too long/i.test(e) ? J("message.voiceTookTooLong") : /cascade|no response|custom_llm_error/i.test(e) ? J("message.voiceNoAnswer") : J("message.voiceInterrupted");
693
- }), Hn = S(() => Q.isSpeaking.value ? "output" : "input"), Un = () => Q.readLevel(Hn.value), Wn = () => Q.readSpectrum(Hn.value), Gn = async () => {
694
- En.value = !1, await Q.start(), Q.isActive.value && (Pn(), Fn(qe));
695
- }, Kn = async () => {
696
- Z.value = !1, await Q.stop(), !Dn && Ln(0);
697
- }, qn = () => {
698
+ }), Un = S(() => Q.isSpeaking.value ? "output" : "input"), Wn = () => Q.readLevel(Un.value), Gn = () => Q.readSpectrum(Un.value), Kn = async () => {
699
+ Dn.value = !1, await Q.start(), Q.isActive.value && (Fn(), In(qe));
700
+ }, qn = async () => {
701
+ Z.value = !1, await Q.stop(), !On && Rn(0);
702
+ }, Jn = () => {
698
703
  Q.dismissError();
699
- }, Jn = async () => {
700
- Q.dismissError(), await Q.stop(), await Gn();
701
- }, Yn = (e) => e?.toolCallId ?? "", Xn = j(/* @__PURE__ */ new Set()), Zn = (e) => Xn.value.has(Yn(e)), Qn = j(/* @__PURE__ */ new Map()), $n = (e, t) => Q.isActive.value ? (Q.sendUserMessage(t) && (Xn.value = new Set(Xn.value).add(Yn(e)), Ln()), !0) : !1, er = (e, t, n) => {
702
- $n(t, l(t, n)) || kt({
704
+ }, Yn = async () => {
705
+ Q.dismissError(), await Q.stop(), await Kn();
706
+ }, Xn = (e) => e?.toolCallId ?? "", Zn = M(/* @__PURE__ */ new Set()), Qn = (e) => Zn.value.has(Xn(e)), $n = M(/* @__PURE__ */ new Map()), er = (e, t) => Q.isActive.value ? (Q.sendUserMessage(t) && (Zn.value = new Set(Zn.value).add(Xn(e)), Rn()), !0) : !1, tr = (e, t, n) => {
707
+ er(t, l(t, n)) || kt({
703
708
  tool: e,
704
- toolCallId: Yn(t),
709
+ toolCallId: Xn(t),
705
710
  output: n
706
711
  });
707
- }, tr = (e) => {
712
+ }, nr = (e) => {
708
713
  let t = e.confirmed ? J("message.voiceConfirmed") : J("message.voiceCancelled");
709
- $n({ toolCallId: e.toolCallId }, t) ? Xn.value.has(e.toolCallId) && (Qn.value = new Map(Qn.value).set(e.toolCallId, e.confirmed)) : kt({
714
+ er({ toolCallId: e.toolCallId }, t) ? Zn.value.has(e.toolCallId) && ($n.value = new Map($n.value).set(e.toolCallId, e.confirmed)) : kt({
710
715
  tool: "requestConfirm",
711
716
  toolCallId: e.toolCallId,
712
717
  output: e.confirmed ? "confirmed" : "cancelled"
713
718
  });
714
- }, nr = /* @__PURE__ */ new Set([
715
- "tool-editSpreadsheet",
716
- "tool-editWordDocument",
717
- "tool-createSpreadsheet",
718
- "tool-createWordDocument"
719
- ]), rr = S(() => {
719
+ }, rr = S(() => {
720
720
  let e = /* @__PURE__ */ new Map();
721
721
  for (let t of V.value) for (let n of t.parts) {
722
722
  let { type: t, state: r, output: i } = n;
723
- nr.has(t) && r === "output-available" && i?.fileId && i.version && e.set(i.fileId, Math.max(e.get(i.fileId) ?? 0, i.version));
723
+ gn.has(t) && r === "output-available" && i?.fileId && i.version && e.set(i.fileId, Math.max(e.get(i.fileId) ?? 0, i.version));
724
724
  }
725
725
  return e;
726
726
  }), ir = S(() => {
@@ -736,38 +736,38 @@ var Ve = { class: "pk-chatbot-view-chat__input-stage" }, He = {
736
736
  continue;
737
737
  }
738
738
  let { type: e, state: r, output: i } = n;
739
- nr.has(e) && r === "output-available" && i?.filename && t(u(i.filename, i.version), i.fileId);
739
+ gn.has(e) && r === "output-available" && i?.filename && t(u(i.filename, i.version), i.fileId);
740
740
  }
741
741
  return e;
742
742
  }), $ = S(() => Qe.value ? void 0 : (e) => {
743
743
  let t = (ir.value.get(e.filename.toLowerCase())?.size ?? 0) > 1;
744
744
  U.value = J(t ? "messagePart.chatFileRestoreRequestById" : "messagePart.chatFileRestoreRequest", e), bt();
745
745
  }), ar = (e, t) => {
746
- $n(e, t) || (U.value = t, bt());
746
+ er(e, t) || (U.value = t, bt());
747
747
  }, or = (e, t) => {
748
748
  let n = t.error ? J("message.voiceLocationRefused") : J("message.voiceLocationShared", { place: t.displayName ?? `${t.latitude}, ${t.longitude}` });
749
- $n(e, n) || kt({
749
+ er(e, n) || kt({
750
750
  tool: "requestGeolocation",
751
- toolCallId: Yn(e),
751
+ toolCallId: Xn(e),
752
752
  output: t
753
753
  });
754
754
  }, sr = (e, t) => {
755
- $n(e, J("message.voiceConnectionDone")) || kt({
755
+ er(e, J("message.voiceConnectionDone")) || kt({
756
756
  tool: "requestOAuthConnection",
757
- toolCallId: Yn(e),
757
+ toolCallId: Xn(e),
758
758
  output: {
759
759
  connected: !0,
760
760
  mcpServerId: t
761
761
  }
762
762
  });
763
763
  }, cr = () => {
764
- En.value = !En.value, Q.setMuted(En.value);
764
+ Dn.value = !Dn.value, Q.setMuted(Dn.value);
765
765
  };
766
- ue(() => {
767
- Dn = !0, Pn();
766
+ le(() => {
767
+ On = !0, Fn();
768
768
  });
769
769
  let { pendingWakeup: lr, isStopping: ur, stop: dr, spokenTurnStarted: fr, spokenTurnsWritten: pr, forgetSpokenTurns: mr } = ze({
770
- agentId: () => N.agentId,
770
+ agentId: () => P.agentId,
771
771
  chatId: () => R.localChatId,
772
772
  apiClient: () => W.value,
773
773
  messages: () => V.value,
@@ -776,11 +776,11 @@ var Ve = { class: "pk-chatbot-view-chat__input-stage" }, He = {
776
776
  });
777
777
  return (t, n) => {
778
778
  let r = ne;
779
- return A(), T("div", {
779
+ return j(), T("div", {
780
780
  ref_key: "chatViewEl",
781
781
  ref: Zt,
782
- class: k(["pk-chatbot-view-chat", {
783
- "pk-chatbot-view-chat--dragover": P(Tn) && K.value?.enabled,
782
+ class: A(["pk-chatbot-view-chat", {
783
+ "pk-chatbot-view-chat--dragover": F(En) && K.value?.enabled,
784
784
  "pk-chatbot-view-chat--empty": Yt.value,
785
785
  "pk-chatbot-view-chat--with-preview": mn.value && !$t.value
786
786
  }])
@@ -789,61 +789,61 @@ var Ve = { class: "pk-chatbot-view-chat__input-stage" }, He = {
789
789
  name: "pk-chatbot-view-chat-fade",
790
790
  mode: "out-in"
791
791
  }, {
792
- default: L(() => [Yt.value ? (A(), C(ee, {
792
+ default: L(() => [Yt.value ? (j(), C(ee, {
793
793
  key: 0,
794
- greeting: P(Xt),
795
- logo: P(z)?.logo,
796
- name: P(R).name
794
+ greeting: F(Xt),
795
+ logo: F(z)?.logo,
796
+ name: F(R).name
797
797
  }, null, 8, [
798
798
  "greeting",
799
799
  "logo",
800
800
  "name"
801
- ])) : (A(), C(e, {
801
+ ])) : (j(), C(e, {
802
802
  key: 1,
803
803
  class: "flex flex-col flex-1 min-h-0 p-md overflow-y-auto",
804
804
  interactive: "",
805
- messages: P(V),
806
- "confirm-verdicts-on-call": Qn.value,
807
- status: P(H).status,
808
- error: P(H).error,
809
- "main-color": P(z)?.mainColor,
810
- "text-color": P(z)?.textColor,
811
- "revised-answers": P(De),
812
- actions: P(Ee),
813
- "message-feedbacks": P(Oe),
814
- "feedback-message-id": P(ke)?.id,
815
- "feedback-loading": P(Ae),
816
- "feedback-submitted": P(Ne),
817
- "feedback-error": P(Pe),
818
- "show-extended-steps": P(z)?.showExtendedSteps,
819
- "hide-reasoning": P(z)?.showReasoning === !1,
805
+ messages: F(V),
806
+ "confirm-verdicts-on-call": $n.value,
807
+ status: F(H).status,
808
+ error: F(H).error,
809
+ "main-color": F(z)?.mainColor,
810
+ "text-color": F(z)?.textColor,
811
+ "revised-answers": F(De),
812
+ actions: F(Ee),
813
+ "message-feedbacks": F(Oe),
814
+ "feedback-message-id": F(ke)?.id,
815
+ "feedback-loading": F(Ae),
816
+ "feedback-submitted": F(Ne),
817
+ "feedback-error": F(Pe),
818
+ "show-extended-steps": F(z)?.showExtendedSteps,
819
+ "hide-reasoning": F(z)?.showReasoning === !1,
820
820
  "awaiting-spoken-answer": Z.value,
821
821
  "host-working": Vt.value,
822
- "host-confirmation": P(ot),
823
- "is-dark": P(rt),
822
+ "host-confirmation": F(ot),
823
+ "is-dark": F(rt),
824
824
  "show-scroll-to-bottom": a.modifier === "fullscreen",
825
- onFeedbackSubmit: n[0] ||= (e) => P(Et)(e),
825
+ onFeedbackSubmit: n[0] ||= (e) => F(Et)(e),
826
826
  onFeedbackClose: n[1] ||= (e) => ke.value = void 0,
827
- onRegenerate: P(St),
828
- onAutoRetry: P(St),
829
- onResetChat: P(Ot),
827
+ onRegenerate: F(St),
828
+ onAutoRetry: F(St),
829
+ onResetChat: F(Ot),
830
830
  onShowInfo: n[2] ||= (e) => Se("show-info", e),
831
831
  onRevise: n[3] ||= (e) => Se("revise", e),
832
- onUpvote: P(Ct),
833
- onDownvote: P(wt),
834
- onFeedback: P(Tt),
835
- onApprovalRespond: P(At),
836
- onConfirmRespond: tr,
837
- onHostConfirmRespond: P(It)
832
+ onUpvote: F(Ct),
833
+ onDownvote: F(wt),
834
+ onFeedback: F(Tt),
835
+ onApprovalRespond: F(At),
836
+ onConfirmRespond: nr,
837
+ onHostConfirmRespond: F(It)
838
838
  }, {
839
- "tool-showContactForm": L(({ part: e }) => [D(P(y), {
839
+ "tool-showContactForm": L(({ part: e }) => [D(F(y), {
840
840
  part: e,
841
- readonly: !P($e),
842
- submitted: P(Ie),
843
- loading: P(Le),
844
- error: P(Re),
845
- "privacy-policy-notice": P(z)?.privacyPolicyNotice,
846
- onSubmit: P(Dt)
841
+ readonly: !F($e),
842
+ submitted: F(Ie),
843
+ loading: F(Le),
844
+ error: F(Re),
845
+ "privacy-policy-notice": F(z)?.privacyPolicyNotice,
846
+ onSubmit: F(Dt)
847
847
  }, null, 8, [
848
848
  "part",
849
849
  "readonly",
@@ -853,20 +853,20 @@ var Ve = { class: "pk-chatbot-view-chat__input-stage" }, He = {
853
853
  "privacy-policy-notice",
854
854
  "onSubmit"
855
855
  ])]),
856
- "tool-showSuggestedReply": L(({ part: e }) => [D(P(ie), {
856
+ "tool-showSuggestedReply": L(({ part: e }) => [D(F(ie), {
857
857
  part: e,
858
858
  onSelect: (t) => ar(e, t)
859
859
  }, null, 8, ["part", "onSelect"])]),
860
- "tool-showSources": L(({ part: e }) => [D(P(ae), {
860
+ "tool-showSources": L(({ part: e }) => [D(F(k), {
861
861
  part: e,
862
- "on-expand-context": Cn,
863
- "on-download": wn
862
+ "on-expand-context": wn,
863
+ "on-download": Tn
864
864
  }, null, 8, ["part"])]),
865
865
  "tool-showForm": L(({ part: e }) => [D(x, { mode: "out-in" }, {
866
- default: L(() => [D(P(g), {
866
+ default: L(() => [D(F(g), {
867
867
  part: e,
868
- answered: Zn(e),
869
- onSelect: (t) => er("showForm", e, t)
868
+ answered: Qn(e),
869
+ onSelect: (t) => tr("showForm", e, t)
870
870
  }, null, 8, [
871
871
  "part",
872
872
  "answered",
@@ -875,11 +875,11 @@ var Ve = { class: "pk-chatbot-view-chat__input-stage" }, He = {
875
875
  _: 2
876
876
  }, 1024)]),
877
877
  "tool-showMultipleChoice": L(({ part: e }) => [D(x, { mode: "out-in" }, {
878
- default: L(() => [D(P(g), {
878
+ default: L(() => [D(F(g), {
879
879
  part: e,
880
880
  "allow-custom-answer": "",
881
- answered: Zn(e),
882
- onSelect: (t) => er("showMultipleChoice", e, t)
881
+ answered: Qn(e),
882
+ onSelect: (t) => tr("showMultipleChoice", e, t)
883
883
  }, null, 8, [
884
884
  "part",
885
885
  "answered",
@@ -887,11 +887,11 @@ var Ve = { class: "pk-chatbot-view-chat__input-stage" }, He = {
887
887
  ])]),
888
888
  _: 2
889
889
  }, 1024)]),
890
- "tool-requestOAuthConnection": L(({ part: e }) => [D(P(ce), {
890
+ "tool-requestOAuthConnection": L(({ part: e }) => [D(F(se), {
891
891
  part: e,
892
- "backend-url": P($e),
893
- "resolve-connection": (e) => P(W).getOAuthAuthorizeUrl(N.agentId, e),
894
- "check-connection": (e) => P(W).getOAuthConnectionStatus(N.agentId, e),
892
+ "backend-url": F($e),
893
+ "resolve-connection": (e) => F(W).getOAuthAuthorizeUrl(P.agentId, e),
894
+ "check-connection": (e) => F(W).getOAuthConnectionStatus(P.agentId, e),
895
895
  onConnected: (t) => sr(e, t)
896
896
  }, null, 8, [
897
897
  "part",
@@ -900,10 +900,10 @@ var Ve = { class: "pk-chatbot-view-chat__input-stage" }, He = {
900
900
  "check-connection",
901
901
  "onConnected"
902
902
  ])]),
903
- "tool-requestGeolocation": L(({ part: e }) => [D(P(oe), {
903
+ "tool-requestGeolocation": L(({ part: e }) => [D(F(ae), {
904
904
  part: e,
905
- "call-live": P(Q).isActive.value,
906
- "reverse-geocode": (e, t) => P(W).reverseGeocode(e, t),
905
+ "call-live": F(Q).isActive.value,
906
+ "reverse-geocode": (e, t) => F(W).reverseGeocode(e, t),
907
907
  onResult: (t) => or(e, t)
908
908
  }, null, 8, [
909
909
  "part",
@@ -911,23 +911,23 @@ var Ve = { class: "pk-chatbot-view-chat__input-stage" }, He = {
911
911
  "reverse-geocode",
912
912
  "onResult"
913
913
  ])]),
914
- "tool-showLocation": L(({ part: e }) => [D(P(le), {
914
+ "tool-showLocation": L(({ part: e }) => [D(F(ce), {
915
915
  part: e,
916
- "is-dark": P(rt),
917
- "main-color": P(z)?.mainColor,
918
- "forward-geocode": (e, t) => P(W).forwardGeocode(e, t)
916
+ "is-dark": F(rt),
917
+ "main-color": F(z)?.mainColor,
918
+ "forward-geocode": (e, t) => F(W).forwardGeocode(e, t)
919
919
  }, null, 8, [
920
920
  "part",
921
921
  "is-dark",
922
922
  "main-color",
923
923
  "forward-geocode"
924
924
  ])]),
925
- "tool-showDiagram": L(({ part: e }) => [D(P(de), {
925
+ "tool-showDiagram": L(({ part: e }) => [D(F(ue), {
926
926
  part: e,
927
- "is-dark": P(rt)
927
+ "is-dark": F(rt)
928
928
  }, null, 8, ["part", "is-dark"])]),
929
- "tool-editSpreadsheet": L(({ part: e }) => [(A(), C(P(fe), {
930
- key: P(p)(e),
929
+ "tool-editSpreadsheet": L(({ part: e }) => [(j(), C(F(de), {
930
+ key: F(p)(e),
931
931
  part: e,
932
932
  "file-url": q,
933
933
  preview: fn,
@@ -938,8 +938,8 @@ var Ve = { class: "pk-chatbot-view-chat__input-stage" }, He = {
938
938
  "latest-versions",
939
939
  "restore"
940
940
  ]))]),
941
- "tool-editWordDocument": L(({ part: e }) => [(A(), C(P(fe), {
942
- key: P(p)(e),
941
+ "tool-editWordDocument": L(({ part: e }) => [(j(), C(F(de), {
942
+ key: F(p)(e),
943
943
  part: e,
944
944
  "file-url": q,
945
945
  preview: fn,
@@ -950,8 +950,8 @@ var Ve = { class: "pk-chatbot-view-chat__input-stage" }, He = {
950
950
  "latest-versions",
951
951
  "restore"
952
952
  ]))]),
953
- "tool-createSpreadsheet": L(({ part: e }) => [(A(), C(P(fe), {
954
- key: P(p)(e),
953
+ "tool-createSpreadsheet": L(({ part: e }) => [(j(), C(F(de), {
954
+ key: F(p)(e),
955
955
  part: e,
956
956
  "file-url": q,
957
957
  preview: fn,
@@ -962,8 +962,8 @@ var Ve = { class: "pk-chatbot-view-chat__input-stage" }, He = {
962
962
  "latest-versions",
963
963
  "restore"
964
964
  ]))]),
965
- "tool-createWordDocument": L(({ part: e }) => [(A(), C(P(fe), {
966
- key: P(p)(e),
965
+ "tool-createWordDocument": L(({ part: e }) => [(j(), C(F(de), {
966
+ key: F(p)(e),
967
967
  part: e,
968
968
  "file-url": q,
969
969
  preview: fn,
@@ -974,20 +974,20 @@ var Ve = { class: "pk-chatbot-view-chat__input-stage" }, He = {
974
974
  "latest-versions",
975
975
  "restore"
976
976
  ]))]),
977
- "tool-shareDocument": L(({ part: e }) => [(A(), C(P(pe), {
978
- key: P(p)(e),
977
+ "tool-shareDocument": L(({ part: e }) => [(j(), C(F(fe), {
978
+ key: F(p)(e),
979
979
  part: e,
980
- "on-download": wn
980
+ "on-download": Tn
981
981
  }, null, 8, ["part"]))]),
982
982
  _: 1
983
983
  }, 8, /* @__PURE__ */ "messages.confirm-verdicts-on-call.status.error.main-color.text-color.revised-answers.actions.message-feedbacks.feedback-message-id.feedback-loading.feedback-submitted.feedback-error.show-extended-steps.hide-reasoning.awaiting-spoken-answer.host-working.host-confirmation.is-dark.show-scroll-to-bottom.onRegenerate.onAutoRetry.onResetChat.onUpvote.onDownvote.onFeedback.onApprovalRespond.onHostConfirmRespond".split(".")))]),
984
984
  _: 1
985
985
  }),
986
- P(ft).length ? (A(), C(v, {
986
+ F(ft).length ? (j(), C(v, {
987
987
  key: 0,
988
- messages: P(ft),
989
- onEdit: P(Lt),
990
- onRemove: P(Rt)
988
+ messages: F(ft),
989
+ onEdit: F(Lt),
990
+ onRemove: F(Rt)
991
991
  }, null, 8, [
992
992
  "messages",
993
993
  "onEdit",
@@ -995,13 +995,13 @@ var Ve = { class: "pk-chatbot-view-chat__input-stage" }, He = {
995
995
  ])) : w("", !0),
996
996
  E("div", Ve, [
997
997
  D(x, { name: "pk-chatbot-view-chat-fade" }, {
998
- default: L(() => [Yt.value ? (A(), C(we, {
998
+ default: L(() => [Yt.value ? (j(), C(we, {
999
999
  key: 0,
1000
1000
  class: "pk-chatbot-view-chat__aurora",
1001
1001
  "source-selector": ".pk-chatbot-input__form",
1002
- "main-color": P(z)?.mainColor,
1003
- tones: P(z)?.glowTones,
1004
- "second-color": P(z)?.glowSecondColor
1002
+ "main-color": F(z)?.mainColor,
1003
+ tones: F(z)?.glowTones,
1004
+ "second-color": F(z)?.glowSecondColor
1005
1005
  }, null, 8, [
1006
1006
  "main-color",
1007
1007
  "tones",
@@ -1009,57 +1009,57 @@ var Ve = { class: "pk-chatbot-view-chat__input-stage" }, He = {
1009
1009
  ])) : w("", !0)]),
1010
1010
  _: 1
1011
1011
  }),
1012
- P(lr) && !P(Qe) ? (A(), C(te, {
1012
+ F(lr) && !F(Qe) ? (j(), C(te, {
1013
1013
  key: 0,
1014
- pending: P(lr),
1015
- stopping: P(ur),
1016
- onStop: P(dr)
1014
+ pending: F(lr),
1015
+ stopping: F(ur),
1016
+ onStop: F(dr)
1017
1017
  }, null, 8, [
1018
1018
  "pending",
1019
1019
  "stopping",
1020
1020
  "onStop"
1021
1021
  ])) : w("", !0),
1022
- P(Qe) ? (A(), T("div", He, M(P(J)("message.chatErrorConversationBlocked")), 1)) : Bn.value === "idle" ? (A(), C(_, {
1022
+ F(Qe) ? (j(), T("div", He, N(F(J)("message.chatErrorConversationBlocked")), 1)) : Vn.value === "idle" ? (j(), C(_, {
1023
1023
  key: 3,
1024
1024
  ref_key: "inputEl",
1025
1025
  ref: vt,
1026
- modelValue: P(U),
1027
- "onUpdate:modelValue": n[4] ||= (e) => se(U) ? U.value = e : null,
1028
- "pending-attachments": P(et),
1029
- "onUpdate:pendingAttachments": n[5] ||= (e) => se(et) ? et.value = e : null,
1030
- placeholder: P(Ze),
1031
- "dismissable-notice": P(qt) && P(H).messages.length <= 1 ? P(qt) : void 0,
1026
+ modelValue: F(U),
1027
+ "onUpdate:modelValue": n[4] ||= (e) => oe(U) ? U.value = e : null,
1028
+ "pending-attachments": F(et),
1029
+ "onUpdate:pendingAttachments": n[5] ||= (e) => oe(et) ? et.value = e : null,
1030
+ placeholder: F(Ze),
1031
+ "dismissable-notice": F(qt) && F(H).messages.length <= 1 ? F(qt) : void 0,
1032
1032
  "page-notice": Wt.value,
1033
1033
  status: Ht.value,
1034
- "max-message-length": P(z)?.maxMessageLength,
1034
+ "max-message-length": F(z)?.maxMessageLength,
1035
1035
  "file-upload": K.value,
1036
- "attachment-limit-reached": P(tt),
1036
+ "attachment-limit-reached": F(tt),
1037
1037
  "attachment-notice": Gt.value,
1038
- "voice-enabled": zn.value,
1039
- "queue-enabled": P(dt),
1038
+ "voice-enabled": Bn.value,
1039
+ "queue-enabled": F(dt),
1040
1040
  "answer-notices": Kt.value,
1041
- "pointer-available": P(ht),
1042
- pointing: P(gt),
1041
+ "pointer-available": F(ht),
1042
+ pointing: F(gt),
1043
1043
  pointer: yt.value,
1044
- "automatic-confirmations": P(ut) === "automatic",
1045
- onPoint: n[6] ||= (e) => P(R).pagePointerStart?.(),
1044
+ "automatic-confirmations": F(ut) === "automatic",
1045
+ onPoint: n[6] ||= (e) => F(R).pagePointerStart?.(),
1046
1046
  onRemovePointer: n[7] ||= (e) => G.value = void 0,
1047
- onManualConfirmations: n[8] ||= (e) => P(R).setConfirmationMode("manual"),
1048
- onStopGeneration: P(xt),
1049
- onSubmit: P(bt),
1050
- onFileSelect: P(jt),
1051
- onDismissAttachmentNotice: P(Mt),
1052
- onDismissPageNotice: P(Ft),
1053
- onOpenAnswerNotice: P(zt),
1054
- onDismissAnswerNotice: P(Bt),
1055
- onVoiceStart: Gn
1047
+ onManualConfirmations: n[8] ||= (e) => F(R).setConfirmationMode("manual"),
1048
+ onStopGeneration: F(xt),
1049
+ onSubmit: F(bt),
1050
+ onFileSelect: F(jt),
1051
+ onDismissAttachmentNotice: F(Mt),
1052
+ onDismissPageNotice: F(Ft),
1053
+ onOpenAnswerNotice: F(zt),
1054
+ onDismissAnswerNotice: F(Bt),
1055
+ onVoiceStart: Kn
1056
1056
  }, re({ _: 2 }, [a.modifier === "fullscreen" ? {
1057
1057
  name: "prepend",
1058
1058
  fn: L(() => [E("span", Ue, [D(h, {
1059
1059
  class: "pk-chatbot-view-chat__agent-chip-avatar",
1060
- "img-src": P(z)?.logo,
1061
- name: P(R).name
1062
- }, null, 8, ["img-src", "name"]), P(R).name ? (A(), T("strong", We, M(P(R).name), 1)) : w("", !0)])]),
1060
+ "img-src": F(z)?.logo,
1061
+ name: F(R).name
1062
+ }, null, 8, ["img-src", "name"]), F(R).name ? (j(), T("strong", We, N(F(R).name), 1)) : w("", !0)])]),
1063
1063
  key: "0"
1064
1064
  } : void 0]), 1032, [
1065
1065
  "modelValue",
@@ -1086,21 +1086,21 @@ var Ve = { class: "pk-chatbot-view-chat__input-stage" }, He = {
1086
1086
  "onDismissPageNotice",
1087
1087
  "onOpenAnswerNotice",
1088
1088
  "onDismissAnswerNotice"
1089
- ])) : (A(), C(je, {
1089
+ ])) : (j(), C(je, {
1090
1090
  key: 2,
1091
- state: Bn.value,
1092
- sample: Un,
1093
- spectrum: Wn,
1094
- "remaining-seconds": P(Q).remainingSeconds.value,
1095
- muted: En.value,
1096
- error: Vn.value,
1097
- "raw-error": P(Q).error.value,
1098
- live: P(Q).isActive.value,
1091
+ state: Vn.value,
1092
+ sample: Wn,
1093
+ spectrum: Gn,
1094
+ "remaining-seconds": F(Q).remainingSeconds.value,
1095
+ muted: Dn.value,
1096
+ error: Hn.value,
1097
+ "raw-error": F(Q).error.value,
1098
+ live: F(Q).isActive.value,
1099
1099
  class: "pk-chatbot-view-chat__voice",
1100
1100
  onToggleMute: cr,
1101
- onHangUp: Kn,
1102
- onRetry: Jn,
1103
- onDismiss: qn
1101
+ onHangUp: qn,
1102
+ onRetry: Yn,
1103
+ onDismiss: Jn
1104
1104
  }, null, 8, [
1105
1105
  "state",
1106
1106
  "remaining-seconds",
@@ -1111,17 +1111,17 @@ var Ve = { class: "pk-chatbot-view-chat__input-stage" }, He = {
1111
1111
  ]))
1112
1112
  ]),
1113
1113
  D(x, null, {
1114
- default: L(() => [P(Tn) && K.value?.enabled ? (A(), T("div", Ge, [D(r, {
1114
+ default: L(() => [F(En) && K.value?.enabled ? (j(), T("div", Ge, [D(r, {
1115
1115
  name: "ri:upload-cloud-2-line",
1116
1116
  class: "pk-chatbot-view-chat__drop-overlay-icon"
1117
- }), E("span", null, M(P(J)("action.dropFile")), 1)])) : w("", !0)]),
1117
+ }), E("span", null, N(F(J)("action.dropFile")), 1)])) : w("", !0)]),
1118
1118
  _: 1
1119
1119
  }),
1120
- mn.value ? (A(), C(b, {
1120
+ mn.value ? (j(), C(b, {
1121
1121
  key: 1,
1122
1122
  to: en.value,
1123
1123
  disabled: !$t.value
1124
- }, [E("aside", { class: k(["pk-chatbot-view-chat__preview", { "pk-chatbot-view-chat__preview--docked": $t.value }]) }, [P(Y) ? (A(), C(P(he), {
1124
+ }, [E("aside", { class: A(["pk-chatbot-view-chat__preview", { "pk-chatbot-view-chat__preview--docked": $t.value }]) }, [F(Y) ? (j(), C(F(me), {
1125
1125
  key: 0,
1126
1126
  mode: X.value.mode,
1127
1127
  "onUpdate:mode": n[9] ||= (e) => X.value.mode = e,
@@ -1131,23 +1131,23 @@ var Ve = { class: "pk-chatbot-view-chat__input-stage" }, He = {
1131
1131
  "onUpdate:zoom": n[11] ||= (e) => X.value.zoom = e,
1132
1132
  fit: X.value.fit,
1133
1133
  "onUpdate:fit": n[12] ||= (e) => X.value.fit = e,
1134
- kind: P(Y).kind,
1135
- filename: P(Y).filename,
1136
- version: P(Y).version,
1137
- versions: _n.value,
1138
- "download-url": q(P(Y).storedFileName),
1139
- preview: P(on),
1140
- loading: P(sn),
1141
- error: P(cn),
1142
- restorable: yn.value,
1134
+ kind: F(Y).kind,
1135
+ filename: F(Y).filename,
1136
+ version: F(Y).version,
1137
+ versions: vn.value,
1138
+ "download-url": q(F(Y).storedFileName),
1139
+ preview: F(on),
1140
+ loading: F(sn),
1141
+ error: F(cn),
1142
+ restorable: bn.value,
1143
1143
  resize: "expand",
1144
- "file-id": P(Y).fileId,
1145
- "stored-file-name": P(Y).storedFileName,
1146
- "selection-actions": xn.value,
1147
- onVersion: vn,
1148
- onRestore: bn,
1144
+ "file-id": F(Y).fileId,
1145
+ "stored-file-name": F(Y).storedFileName,
1146
+ "selection-actions": Sn.value,
1147
+ onVersion: yn,
1148
+ onRestore: xn,
1149
1149
  onResize: n[13] ||= (e) => pn.value = !0,
1150
- onSelectionSend: Sn,
1150
+ onSelectionSend: Cn,
1151
1151
  onClose: hn
1152
1152
  }, null, 8, [
1153
1153
  "mode",
@@ -1167,7 +1167,7 @@ var Ve = { class: "pk-chatbot-view-chat__input-stage" }, He = {
1167
1167
  "stored-file-name",
1168
1168
  "selection-actions"
1169
1169
  ])) : w("", !0)], 2)], 8, ["to", "disabled"])) : w("", !0),
1170
- P(Y) && !mn.value ? (A(), C(P(ge), {
1170
+ F(Y) && !mn.value ? (j(), C(F(he), {
1171
1171
  key: 2,
1172
1172
  mode: X.value.mode,
1173
1173
  "onUpdate:mode": n[14] ||= (e) => X.value.mode = e,
@@ -1177,20 +1177,20 @@ var Ve = { class: "pk-chatbot-view-chat__input-stage" }, He = {
1177
1177
  "onUpdate:zoom": n[16] ||= (e) => X.value.zoom = e,
1178
1178
  fit: X.value.fit,
1179
1179
  "onUpdate:fit": n[17] ||= (e) => X.value.fit = e,
1180
- target: P(Y),
1181
- versions: _n.value,
1182
- "download-url": q(P(Y).storedFileName),
1183
- preview: P(on),
1184
- loading: P(sn),
1185
- error: P(cn),
1186
- restorable: yn.value,
1180
+ target: F(Y),
1181
+ versions: vn.value,
1182
+ "download-url": q(F(Y).storedFileName),
1183
+ preview: F(on),
1184
+ loading: F(sn),
1185
+ error: F(cn),
1186
+ restorable: bn.value,
1187
1187
  resize: rn.value ? "shrink" : void 0,
1188
1188
  fullscreen: an.value,
1189
- "selection-actions": xn.value,
1190
- onVersion: vn,
1191
- onRestore: bn,
1189
+ "selection-actions": Sn.value,
1190
+ onVersion: yn,
1191
+ onRestore: xn,
1192
1192
  onResize: n[18] ||= (e) => pn.value = !1,
1193
- onSelectionSend: Sn,
1193
+ onSelectionSend: Cn,
1194
1194
  onClose: hn
1195
1195
  }, null, 8, [
1196
1196
  "mode",
@@ -1214,4 +1214,4 @@ var Ve = { class: "pk-chatbot-view-chat__input-stage" }, He = {
1214
1214
  });
1215
1215
  export { Ee as a, je as i, Be as n, we as o, Pe as r, Ze as t };
1216
1216
 
1217
- //# sourceMappingURL=PkChatbotViewChat-lLX_msKI.js.map
1217
+ //# sourceMappingURL=PkChatbotViewChat-Drp0At_n.js.map