@8wave/ai-elements 0.123.0-beta.11 → 0.123.0-beta.13

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 (146) hide show
  1. package/README.md +30 -3
  2. package/dist/_chunks/{Agent-C0JtGK2t.js → Agent-CsSvagZw.js} +13 -2
  3. package/dist/_chunks/Agent-CsSvagZw.js.map +1 -0
  4. package/dist/_chunks/{PkStreamingMarkdown-DGdyf4_3.js → PkStreamingMarkdown-ReRKQNAO.js} +3 -3
  5. package/dist/_chunks/{PkStreamingMarkdown-DGdyf4_3.js.map → PkStreamingMarkdown-ReRKQNAO.js.map} +1 -1
  6. package/dist/_chunks/{PkToolChatFile-NrOBCzk2.js → PkToolChatFile-QJi6bOuS.js} +2 -2
  7. package/dist/_chunks/{PkToolChatFile-NrOBCzk2.js.map → PkToolChatFile-QJi6bOuS.js.map} +1 -1
  8. package/dist/_chunks/{PkToolRequestGeolocation-BIfpxvX5.js → PkToolRequestGeolocation-CUjRsNs9.js} +2 -2
  9. package/dist/_chunks/{PkToolRequestGeolocation-BIfpxvX5.js.map → PkToolRequestGeolocation-CUjRsNs9.js.map} +1 -1
  10. package/dist/_chunks/{PkToolRequestOAuthConnection-CJgoiSgi.js → PkToolRequestOAuthConnection-CbxVIAPg.js} +2 -2
  11. package/dist/_chunks/{PkToolRequestOAuthConnection-CJgoiSgi.js.map → PkToolRequestOAuthConnection-CbxVIAPg.js.map} +1 -1
  12. package/dist/_chunks/{PkToolShareDocument-CFGH4rKt.js → PkToolShareDocument-B5EC6KQS.js} +2 -2
  13. package/dist/_chunks/PkToolShareDocument-B5EC6KQS.js.map +1 -0
  14. package/dist/_chunks/{PkToolShowArtifact-DmZEQMSm.js → PkToolShowArtifact-D0HZ_qWx.js} +2 -2
  15. package/dist/_chunks/{PkToolShowArtifact-DmZEQMSm.js.map → PkToolShowArtifact-D0HZ_qWx.js.map} +1 -1
  16. package/dist/_chunks/{PkToolShowContactForm-BaX3d5Yq.js → PkToolShowContactForm-DkJB0EO1.js} +2 -2
  17. package/dist/_chunks/{PkToolShowContactForm-BaX3d5Yq.js.map → PkToolShowContactForm-DkJB0EO1.js.map} +1 -1
  18. package/dist/_chunks/{PkToolShowForm-BKyZnpPB.js → PkToolShowForm-zAprG0yl.js} +3 -3
  19. package/dist/_chunks/{PkToolShowForm-BKyZnpPB.js.map → PkToolShowForm-zAprG0yl.js.map} +1 -1
  20. package/dist/_chunks/{PkToolShowImageGallery-GBaXxucK.js → PkToolShowImageGallery-o62SZ6tq.js} +2 -2
  21. package/dist/_chunks/{PkToolShowImageGallery-GBaXxucK.js.map → PkToolShowImageGallery-o62SZ6tq.js.map} +1 -1
  22. package/dist/_chunks/{PkToolShowProductList-DBVtBJXU.js → PkToolShowProductList-CWLxVreB.js} +2 -2
  23. package/dist/_chunks/{PkToolShowProductList-DBVtBJXU.js.map → PkToolShowProductList-CWLxVreB.js.map} +1 -1
  24. package/dist/_chunks/{PkToolShowSources-Ciuizdl3.js → PkToolShowSources-dJEqZn6T.js} +3 -3
  25. package/dist/_chunks/{PkToolShowSources-Ciuizdl3.js.map → PkToolShowSources-dJEqZn6T.js.map} +1 -1
  26. package/dist/_chunks/{PkToolShowSuggestedReply-Dbti20SV.js → PkToolShowSuggestedReply-BHAltyxH.js} +2 -2
  27. package/dist/_chunks/{PkToolShowSuggestedReply-Dbti20SV.js.map → PkToolShowSuggestedReply-BHAltyxH.js.map} +1 -1
  28. package/dist/_chunks/{PkToolShowVideo-DKDR3zmI.js → PkToolShowVideo-DtJ0nEJk.js} +2 -2
  29. package/dist/_chunks/{PkToolShowVideo-DKDR3zmI.js.map → PkToolShowVideo-DtJ0nEJk.js.map} +1 -1
  30. package/dist/_chunks/{PkToolShowWebPages-CuJ12tdE.js → PkToolShowWebPages-D-tG9JH8.js} +2 -2
  31. package/dist/_chunks/{PkToolShowWebPages-CuJ12tdE.js.map → PkToolShowWebPages-D-tG9JH8.js.map} +1 -1
  32. package/dist/_chunks/{chatImagePolicy-D3zIP7-i.js → chatImagePolicy-Dhxqcirq.js} +2 -2
  33. package/dist/_chunks/{chatImagePolicy-D3zIP7-i.js.map → chatImagePolicy-Dhxqcirq.js.map} +1 -1
  34. package/dist/_chunks/{markdown-BxOlM5SY.js → markdown-CUaXq5OY.js} +2 -2
  35. package/dist/_chunks/{markdown-BxOlM5SY.js.map → markdown-CUaXq5OY.js.map} +1 -1
  36. package/dist/ai-elements.es.js +2721 -2270
  37. package/dist/ai-elements.es.js.map +1 -1
  38. package/dist-vue/PkChatbot.js +1 -1
  39. package/dist-vue/PkChatbotEmptyState.js +1 -1
  40. package/dist-vue/PkChatbotInput.js +1 -1
  41. package/dist-vue/PkChatbotMessages.js +1 -1
  42. package/dist-vue/PkChatbotStepPayload.js +1 -1
  43. package/dist-vue/PkChatbotStepToolDetail.js +1 -1
  44. package/dist-vue/PkChatbotSteps.js +1 -1
  45. package/dist-vue/PkChatbotViewChat.js +1 -1
  46. package/dist-vue/PkChatbotViewConversations.js +1 -1
  47. package/dist-vue/PkChatbotViewFiles.js +1 -1
  48. package/dist-vue/PkChatbotViewProfile.js +1 -1
  49. package/dist-vue/_chunks/{Agent-Dsi_xGvV.js → Agent-D3US-D1x.js} +13 -2
  50. package/dist-vue/_chunks/Agent-D3US-D1x.js.map +1 -0
  51. package/dist-vue/_chunks/{Document-B5R1PJnc.js → Document-D5FVOcP9.js} +2 -2
  52. package/dist-vue/_chunks/{Document-B5R1PJnc.js.map → Document-D5FVOcP9.js.map} +1 -1
  53. package/dist-vue/_chunks/{PkChatbot-CBpViucq.js → PkChatbot-Bwzq2vRC.js} +8 -8
  54. package/dist-vue/_chunks/{PkChatbot-CBpViucq.js.map → PkChatbot-Bwzq2vRC.js.map} +1 -1
  55. package/dist-vue/_chunks/{PkChatbotEmptyState-DKrmLdVU.js → PkChatbotEmptyState-3VeE3lFA.js} +2 -2
  56. package/dist-vue/_chunks/{PkChatbotEmptyState-DKrmLdVU.js.map → PkChatbotEmptyState-3VeE3lFA.js.map} +1 -1
  57. package/dist-vue/_chunks/{PkChatbotInput-C1i14Ur_.js → PkChatbotInput-SWQVz3m7.js} +212 -175
  58. package/dist-vue/_chunks/PkChatbotInput-SWQVz3m7.js.map +1 -0
  59. package/dist-vue/_chunks/{PkChatbotMessages-Ce8h0QNX.js → PkChatbotMessages-3hraizdN.js} +123 -115
  60. package/dist-vue/_chunks/PkChatbotMessages-3hraizdN.js.map +1 -0
  61. package/dist-vue/_chunks/{PkChatbotStepPayload-Dp_akrQu.js → PkChatbotStepPayload-Di0FNaTC.js} +2 -2
  62. package/dist-vue/_chunks/{PkChatbotStepPayload-Dp_akrQu.js.map → PkChatbotStepPayload-Di0FNaTC.js.map} +1 -1
  63. package/dist-vue/_chunks/{PkChatbotStepToolDetail-CKxl4_lQ.js → PkChatbotStepToolDetail-Bne48uS8.js} +3 -3
  64. package/dist-vue/_chunks/{PkChatbotStepToolDetail-CKxl4_lQ.js.map → PkChatbotStepToolDetail-Bne48uS8.js.map} +1 -1
  65. package/dist-vue/_chunks/{PkChatbotSteps-ChaHkHjG.js → PkChatbotSteps-Cr9nwMQj.js} +5 -5
  66. package/dist-vue/_chunks/{PkChatbotSteps-ChaHkHjG.js.map → PkChatbotSteps-Cr9nwMQj.js.map} +1 -1
  67. package/dist-vue/_chunks/{PkChatbotViewChat-Bjw6x7VD.js → PkChatbotViewChat-BSRRz4ma.js} +417 -404
  68. package/dist-vue/_chunks/PkChatbotViewChat-BSRRz4ma.js.map +1 -0
  69. package/dist-vue/_chunks/{PkChatbotViewConversations-D-UK4paq.js → PkChatbotViewConversations-Bng-dyqd.js} +3 -3
  70. package/dist-vue/_chunks/{PkChatbotViewConversations-D-UK4paq.js.map → PkChatbotViewConversations-Bng-dyqd.js.map} +1 -1
  71. package/dist-vue/_chunks/{PkChatbotViewFiles-57kQRbZm.js → PkChatbotViewFiles-Ccti1JAS.js} +3 -3
  72. package/dist-vue/_chunks/{PkChatbotViewFiles-57kQRbZm.js.map → PkChatbotViewFiles-Ccti1JAS.js.map} +1 -1
  73. package/dist-vue/_chunks/{PkChatbotViewProfile-BZTify2Q.js → PkChatbotViewProfile-ChEItAHZ.js} +2 -2
  74. package/dist-vue/_chunks/{PkChatbotViewProfile-BZTify2Q.js.map → PkChatbotViewProfile-ChEItAHZ.js.map} +1 -1
  75. package/dist-vue/_chunks/{PkStreamingMarkdown-4Ez-DDFq.js → PkStreamingMarkdown-92GXUXrG.js} +3 -3
  76. package/dist-vue/_chunks/{PkStreamingMarkdown-4Ez-DDFq.js.map → PkStreamingMarkdown-92GXUXrG.js.map} +1 -1
  77. package/dist-vue/_chunks/{PkToolChatFile-DaivFIhK.js → PkToolChatFile-Ca45de6q.js} +2 -2
  78. package/dist-vue/_chunks/{PkToolChatFile-DaivFIhK.js.map → PkToolChatFile-Ca45de6q.js.map} +1 -1
  79. package/dist-vue/_chunks/{PkToolRequestGeolocation-B__wk6m3.js → PkToolRequestGeolocation-gEDbmudT.js} +2 -2
  80. package/dist-vue/_chunks/{PkToolRequestGeolocation-B__wk6m3.js.map → PkToolRequestGeolocation-gEDbmudT.js.map} +1 -1
  81. package/dist-vue/_chunks/{PkToolRequestOAuthConnection-BAttadSC.js → PkToolRequestOAuthConnection-Dy0GXNwC.js} +2 -2
  82. package/dist-vue/_chunks/{PkToolRequestOAuthConnection-BAttadSC.js.map → PkToolRequestOAuthConnection-Dy0GXNwC.js.map} +1 -1
  83. package/dist-vue/_chunks/{PkToolShareDocument-IreRCu-j.js → PkToolShareDocument-DeUo345m.js} +2 -2
  84. package/dist-vue/_chunks/PkToolShareDocument-DeUo345m.js.map +1 -0
  85. package/dist-vue/_chunks/{PkToolShowArtifact-CncSr7Z8.js → PkToolShowArtifact-B-BUIMju.js} +2 -2
  86. package/dist-vue/_chunks/{PkToolShowArtifact-CncSr7Z8.js.map → PkToolShowArtifact-B-BUIMju.js.map} +1 -1
  87. package/dist-vue/_chunks/{PkToolShowContactForm-Bi5N1fFe.js → PkToolShowContactForm-NRfvmPLV.js} +2 -2
  88. package/dist-vue/_chunks/{PkToolShowContactForm-Bi5N1fFe.js.map → PkToolShowContactForm-NRfvmPLV.js.map} +1 -1
  89. package/dist-vue/_chunks/{PkToolShowDiagram-D8NF9lZu.js → PkToolShowDiagram-VTi8vwcN.js} +2 -2
  90. package/dist-vue/_chunks/{PkToolShowDiagram-D8NF9lZu.js.map → PkToolShowDiagram-VTi8vwcN.js.map} +1 -1
  91. package/dist-vue/_chunks/{PkToolShowForm-Dmyn6cMU.js → PkToolShowForm-C4JnalBU.js} +4 -4
  92. package/dist-vue/_chunks/{PkToolShowForm-Dmyn6cMU.js.map → PkToolShowForm-C4JnalBU.js.map} +1 -1
  93. package/dist-vue/_chunks/{PkToolShowImageGallery-XZiRk6FK.js → PkToolShowImageGallery-ORfqyhhh.js} +2 -2
  94. package/dist-vue/_chunks/{PkToolShowImageGallery-XZiRk6FK.js.map → PkToolShowImageGallery-ORfqyhhh.js.map} +1 -1
  95. package/dist-vue/_chunks/{PkToolShowProductList-DzvPUdbo.js → PkToolShowProductList-C9kbfutK.js} +2 -2
  96. package/dist-vue/_chunks/{PkToolShowProductList-DzvPUdbo.js.map → PkToolShowProductList-C9kbfutK.js.map} +1 -1
  97. package/dist-vue/_chunks/{PkToolShowSources-NOSBkQCi.js → PkToolShowSources-BVfcp1iE.js} +3 -3
  98. package/dist-vue/_chunks/{PkToolShowSources-NOSBkQCi.js.map → PkToolShowSources-BVfcp1iE.js.map} +1 -1
  99. package/dist-vue/_chunks/{PkToolShowSuggestedReply-C7dUB3dz.js → PkToolShowSuggestedReply-Bb7Inxa4.js} +2 -2
  100. package/dist-vue/_chunks/{PkToolShowSuggestedReply-C7dUB3dz.js.map → PkToolShowSuggestedReply-Bb7Inxa4.js.map} +1 -1
  101. package/dist-vue/_chunks/{PkToolShowVideo-sSZyISJH.js → PkToolShowVideo-CUNITpHh.js} +2 -2
  102. package/dist-vue/_chunks/{PkToolShowVideo-sSZyISJH.js.map → PkToolShowVideo-CUNITpHh.js.map} +1 -1
  103. package/dist-vue/_chunks/{PkToolShowWebPages-B1c4X_cH.js → PkToolShowWebPages-C-yl2smm.js} +2 -2
  104. package/dist-vue/_chunks/{PkToolShowWebPages-B1c4X_cH.js.map → PkToolShowWebPages-C-yl2smm.js.map} +1 -1
  105. package/dist-vue/_chunks/{createChatbotApiClient-BmBo5IQR.js → createChatbotApiClient-CuqGJGHD.js} +2 -2
  106. package/dist-vue/_chunks/createChatbotApiClient-CuqGJGHD.js.map +1 -0
  107. package/dist-vue/_chunks/{useChatbotStore-D7ZMA7Tr.js → useChatbotStore-C1lW6qXE.js} +1143 -1134
  108. package/dist-vue/_chunks/useChatbotStore-C1lW6qXE.js.map +1 -0
  109. package/dist-vue/_chunks/{utils-CKsn0vxx.js → utils-CoLdYTZq.js} +2 -2
  110. package/dist-vue/_chunks/{utils-CKsn0vxx.js.map → utils-CoLdYTZq.js.map} +1 -1
  111. package/dist-vue/api.js +1 -1
  112. package/dist-vue/apps/web-component/src/components/EmbeddedChatWidget.ce.d.ts +4 -4
  113. package/dist-vue/apps/web-component/src/composables/useChatbotAgent.d.ts +2 -0
  114. package/dist-vue/apps/web-component/src/composables/useChatbotAuth.d.ts +3 -3
  115. package/dist-vue/apps/web-component/src/composables/usePagePointer.d.ts +50 -0
  116. package/dist-vue/apps/web-component/src/composables/usePageTools.d.ts +21 -0
  117. package/dist-vue/apps/web-component/src/pageTools/index.d.ts +8 -1
  118. package/dist-vue/apps/web-component/src/pageTools/pointing.d.ts +41 -0
  119. package/dist-vue/apps/web-component/src/pageTools/snapshot.d.ts +2 -0
  120. package/dist-vue/composables.js +24 -8
  121. package/dist-vue/composables.js.map +1 -1
  122. package/dist-vue/index.js +48 -31
  123. package/dist-vue/index.js.map +1 -1
  124. package/dist-vue/locales.js +20 -0
  125. package/dist-vue/packages/components/src/chat/PkAgentPageAccessSettings.d.ts +2 -0
  126. package/dist-vue/packages/components/src/chat/PkAgentSettingsPanel.d.ts +2 -0
  127. package/dist-vue/packages/components/src/chat/PkChatbotInput.d.ts +16 -3
  128. package/dist-vue/packages/components/src/chat/PkPagePointer.d.ts +41 -0
  129. package/dist-vue/packages/components/src/chat/PkToolShareDocument.d.ts +4 -3
  130. package/dist-vue/packages/composable/src/chatbot/useChatbotStore.d.ts +150 -6
  131. package/dist-vue/packages/models/src/schema/Agent.d.ts +7 -0
  132. package/dist-vue/packages/models/src/schema/Chat.d.ts +8 -0
  133. package/dist-vue/packages/models/src/schema/PageAccess.d.ts +29 -1
  134. package/dist-vue/packages/models/src/schema/ReasoningChat.d.ts +2 -0
  135. package/dist-vue/packages/models/src/schema/SubAgent.d.ts +2 -0
  136. package/dist-vue/style.css +1 -1
  137. package/package.json +1 -1
  138. package/dist/_chunks/Agent-C0JtGK2t.js.map +0 -1
  139. package/dist/_chunks/PkToolShareDocument-CFGH4rKt.js.map +0 -1
  140. package/dist-vue/_chunks/Agent-Dsi_xGvV.js.map +0 -1
  141. package/dist-vue/_chunks/PkChatbotInput-C1i14Ur_.js.map +0 -1
  142. package/dist-vue/_chunks/PkChatbotMessages-Ce8h0QNX.js.map +0 -1
  143. package/dist-vue/_chunks/PkChatbotViewChat-Bjw6x7VD.js.map +0 -1
  144. package/dist-vue/_chunks/PkToolShareDocument-IreRCu-j.js.map +0 -1
  145. package/dist-vue/_chunks/createChatbotApiClient-BmBo5IQR.js.map +0 -1
  146. package/dist-vue/_chunks/useChatbotStore-D7ZMA7Tr.js.map +0 -1
@@ -1,43 +1,43 @@
1
- import { t as e } from "./PkChatbotMessages-Ce8h0QNX.js";
1
+ import { t as e } from "./PkChatbotMessages-3hraizdN.js";
2
2
  import { o as t } from "./Media-DylqhvaF.js";
3
- import { a as n, n as r, t as i } from "./useChatbotStore-D7ZMA7Tr.js";
3
+ import { a as n, n as r, t as i } from "./useChatbotStore-C1lW6qXE.js";
4
4
  import { n as a } from "./src-j7iLdNe4.js";
5
- import { c as o, h as s, n as c } from "./utils-CKsn0vxx.js";
5
+ import { c as o, h as s, n as c } from "./utils-CoLdYTZq.js";
6
6
  import { t as l } from "./useLocalizedString-Dmn92nix.js";
7
7
  import { t as u } from "./PkAvatar-DwtZWSW4.js";
8
- import { n as d, t as f } from "./PkChatbotInput-C1i14Ur_.js";
8
+ import { n as d, t as f } from "./PkChatbotInput-SWQVz3m7.js";
9
9
  import { t as p } from "./PkChatbotQueuedMessages-CIJFAvE2.js";
10
- import { t as m } from "./PkChatbotEmptyState-DKrmLdVU.js";
11
- import { t as h } from "./PkChatbotWakeupBar-DEP-d-Fp.js";
12
- import { VvIcon as g } from "@volverjs/ui-vue/components";
13
- import { Fragment as _, Transition as v, computed as y, createBlock as b, createCommentVNode as x, createElementBlock as S, createElementVNode as C, createSlots as ee, createTextVNode as te, createVNode as w, defineAsyncComponent as T, defineComponent as E, isRef as ne, nextTick as re, normalizeClass as D, onBeforeUnmount as ie, onMounted as ae, onScopeDispose as oe, onUnmounted as se, openBlock as O, provide as ce, ref as k, renderList as le, shallowRef as A, toDisplayString as j, toValue as ue, unref as M, useTemplateRef as de, watch as N, withCtx as P } from "vue";
14
- import { useI18n as fe } from "vue-i18n";
15
- import { useDropZone as pe, useElementSize as me } from "@vueuse/core";
16
- import { storeToRefs as he } from "pinia";
10
+ import { t as ee } from "./PkChatbotEmptyState-3VeE3lFA.js";
11
+ import { t as m } from "./PkChatbotWakeupBar-DEP-d-Fp.js";
12
+ import { VvIcon as h } from "@volverjs/ui-vue/components";
13
+ import { Fragment as g, Transition as _, computed as v, createBlock as y, createCommentVNode as b, createElementBlock as x, createElementVNode as S, createSlots as te, createTextVNode as ne, createVNode as C, defineAsyncComponent as w, defineComponent as T, isRef as re, nextTick as ie, normalizeClass as E, onBeforeUnmount as ae, onMounted as oe, onScopeDispose as se, onUnmounted as ce, openBlock as D, provide as le, ref as O, renderList as ue, shallowRef as k, toDisplayString as A, toValue as de, unref as j, useTemplateRef as fe, watch as M, withCtx as N } from "vue";
14
+ import { useI18n as pe } from "vue-i18n";
15
+ import { useDropZone as me, useElementSize as he } from "@vueuse/core";
16
+ import { storeToRefs as ge } from "pinia";
17
17
  // ../../packages/composable/src/chatbot/useGreeting.ts
18
- function ge(e, t) {
19
- let { locale: n, t: r, te: i } = fe({ useScope: "global" });
20
- return y(() => _e(ue(e)?.greeting?.[0]?.[n.value] ?? "", ue(t)) || (i("message.defaultAgentWelcome") ? r("message.defaultAgentWelcome") : ""));
21
- }
22
18
  function _e(e, t) {
19
+ let { locale: n, t: r, te: i } = pe({ useScope: "global" });
20
+ return v(() => ve(de(e)?.greeting?.[0]?.[n.value] ?? "", de(t)) || (i("message.defaultAgentWelcome") ? r("message.defaultAgentWelcome") : ""));
21
+ }
22
+ function ve(e, t) {
23
23
  return (t ? e.replace(/\{name\}/g, t) : e.replace(/[,\s]*\{name\}[!?]?/g, "")).trim();
24
24
  }
25
25
  // ../../packages/components/src/chat/PkAuroraCanvas.vue?vue&type=script&setup=true&lang.ts
26
- var ve = {
26
+ var ye = {
27
27
  class: "pk-aurora",
28
28
  "aria-hidden": "true"
29
- }, F = {
29
+ }, P = {
30
30
  key: 1,
31
31
  class: "pk-aurora__fallback"
32
- }, ye = "\nattribute vec2 a_position;\nvoid main() {\n gl_Position = vec4(a_position, 0.0, 1.0);\n}", I = "\nprecision mediump float;\nuniform vec2 u_resolution;\nuniform float u_time;\nuniform vec3 u_color;\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 // Premultiplied alpha (default canvas compositing)\n gl_FragColor = vec4(u_color * alpha, alpha);\n}", be = /* @__PURE__ */ E({
32
+ }, be = "\nattribute vec2 a_position;\nvoid main() {\n gl_Position = vec4(a_position, 0.0, 1.0);\n}", F = "\nprecision mediump float;\nuniform vec2 u_resolution;\nuniform float u_time;\nuniform vec3 u_color;\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 // Premultiplied alpha (default canvas compositing)\n gl_FragColor = vec4(u_color * alpha, alpha);\n}", xe = /* @__PURE__ */ T({
33
33
  __name: "PkAuroraCanvas",
34
34
  props: { sourceSelector: {} },
35
35
  setup(e) {
36
- let t = e, n = de("canvasEl"), r = k(!1), i = null, a = 0, o = null, s = null, c = null, l = null, u = null, d = null, f = performance.now(), p = (e, t) => {
36
+ let t = e, n = fe("canvasEl"), r = O(!1), i = null, a = 0, o = null, s = null, c = null, l = null, u = null, d = null, f = performance.now(), p = (e, t) => {
37
37
  if (!i) return null;
38
38
  let n = i.createShader(e);
39
39
  return !n || (i.shaderSource(n, t), i.compileShader(n), !i.getShaderParameter(n, i.COMPILE_STATUS)) ? null : n;
40
- }, m = () => {
40
+ }, ee = () => {
41
41
  if (!n.value) return null;
42
42
  let e = getComputedStyle(n.value).color.match(/rgba?\(([\d.]+)[,\s]+([\d.]+)[,\s]+([\d.]+)/);
43
43
  return e ? [
@@ -45,7 +45,7 @@ var ve = {
45
45
  Number(e[2]) / 255,
46
46
  Number(e[3]) / 255
47
47
  ] : null;
48
- }, h = () => {
48
+ }, m = () => {
49
49
  if (!i || !n.value) return;
50
50
  let e = Math.min(window.devicePixelRatio || 1, 1.5), { clientWidth: r, clientHeight: a } = n.value;
51
51
  n.value.width = Math.max(1, Math.round(r * e)), n.value.height = Math.max(1, Math.round(a * e)), i.viewport(0, 0, n.value.width, n.value.height);
@@ -56,28 +56,28 @@ var ve = {
56
56
  let p = Number.parseFloat(getComputedStyle(n.value).getPropertyValue("--aurora-spread"));
57
57
  i.uniform1f(d, Number.isNaN(p) ? 1 : p);
58
58
  }
59
- _(g() ? 10 : void 0);
60
- }, g = () => window.matchMedia("(prefers-reduced-motion: reduce)").matches, _ = (e) => {
59
+ g(h() ? 10 : void 0);
60
+ }, h = () => window.matchMedia("(prefers-reduced-motion: reduce)").matches, g = (e) => {
61
61
  i && n.value && (i.uniform1f(s, e ?? (performance.now() - f) / 1e3), i.uniform2f(c, n.value.width, n.value.height), i.drawArrays(i.TRIANGLE_STRIP, 0, 4));
62
- }, v = () => {
63
- _(), a = requestAnimationFrame(v);
62
+ }, _ = () => {
63
+ g(), a = requestAnimationFrame(_);
64
64
  };
65
- return ae(() => {
65
+ return oe(() => {
66
66
  let e = n.value;
67
67
  i = e?.getContext("webgl", { alpha: !0 }) ?? null;
68
- let t = m();
68
+ let t = ee();
69
69
  if (!e || !i || !t) {
70
70
  r.value = !0;
71
71
  return;
72
72
  }
73
- let a = p(i.VERTEX_SHADER, ye), f = p(i.FRAGMENT_SHADER, I), y = i.createProgram();
74
- if (!a || !f || !y || (i.attachShader(y, a), i.attachShader(y, f), i.linkProgram(y), !i.getProgramParameter(y, i.LINK_STATUS))) {
73
+ let a = p(i.VERTEX_SHADER, be), f = p(i.FRAGMENT_SHADER, F), v = i.createProgram();
74
+ if (!a || !f || !v || (i.attachShader(v, a), i.attachShader(v, f), i.linkProgram(v), !i.getProgramParameter(v, i.LINK_STATUS))) {
75
75
  r.value = !0;
76
76
  return;
77
77
  }
78
- i.useProgram(y);
79
- let b = i.createBuffer();
80
- i.bindBuffer(i.ARRAY_BUFFER, b), i.bufferData(i.ARRAY_BUFFER, new Float32Array([
78
+ i.useProgram(v);
79
+ let y = i.createBuffer();
80
+ i.bindBuffer(i.ARRAY_BUFFER, y), i.bufferData(i.ARRAY_BUFFER, new Float32Array([
81
81
  -1,
82
82
  -1,
83
83
  1,
@@ -87,23 +87,23 @@ var ve = {
87
87
  1,
88
88
  1
89
89
  ]), i.STATIC_DRAW);
90
- let x = i.getAttribLocation(y, "a_position");
91
- i.enableVertexAttribArray(x), i.vertexAttribPointer(x, 2, i.FLOAT, !1, 0, 0), s = i.getUniformLocation(y, "u_time"), c = i.getUniformLocation(y, "u_resolution"), l = i.getUniformLocation(y, "u_center"), u = i.getUniformLocation(y, "u_half"), d = i.getUniformLocation(y, "u_spread"), i.uniform3f(i.getUniformLocation(y, "u_color"), ...t), o = new ResizeObserver(h), o.observe(e), h(), re(h), g() ? _(10) : v();
92
- }), ie(() => {
90
+ let b = i.getAttribLocation(v, "a_position");
91
+ i.enableVertexAttribArray(b), i.vertexAttribPointer(b, 2, i.FLOAT, !1, 0, 0), s = i.getUniformLocation(v, "u_time"), c = i.getUniformLocation(v, "u_resolution"), l = i.getUniformLocation(v, "u_center"), u = i.getUniformLocation(v, "u_half"), d = i.getUniformLocation(v, "u_spread"), i.uniform3f(i.getUniformLocation(v, "u_color"), ...t), o = new ResizeObserver(m), o.observe(e), m(), ie(m), h() ? g(10) : _();
92
+ }), ae(() => {
93
93
  cancelAnimationFrame(a), o?.disconnect();
94
- }), se(() => {
94
+ }), ce(() => {
95
95
  let e = i;
96
96
  i = null, setTimeout(() => {
97
97
  e?.getExtension("WEBGL_lose_context")?.loseContext();
98
98
  }, 150);
99
- }), (e, t) => (O(), S("div", ve, [r.value ? (O(), S("div", F)) : (O(), S("canvas", {
99
+ }), (e, t) => (D(), x("div", ye, [r.value ? (D(), x("div", P)) : (D(), x("canvas", {
100
100
  key: 0,
101
101
  ref_key: "canvasEl",
102
102
  ref: n,
103
103
  class: "pk-aurora__canvas"
104
104
  }, null, 512))]));
105
105
  }
106
- }), L = .18, xe = .35, Se = /* @__PURE__ */ E({
106
+ }), I = .18, Se = .35, Ce = /* @__PURE__ */ T({
107
107
  __name: "PkVoiceOrb",
108
108
  props: {
109
109
  sample: {},
@@ -115,20 +115,20 @@ var ve = {
115
115
  bars: { default: 5 }
116
116
  },
117
117
  setup(e) {
118
- let t = e, n = de("barsEl"), r = Array.from({ length: t.bars }, () => L), i, a = () => typeof window < "u" && window.matchMedia?.("(prefers-reduced-motion: reduce)").matches === !0, o = () => {
118
+ let t = e, n = fe("barsEl"), r = Array.from({ length: t.bars }, () => I), i, a = () => typeof window < "u" && window.matchMedia?.("(prefers-reduced-motion: reduce)").matches === !0, o = () => {
119
119
  let e = Math.min(1, Math.max(0, t.sample())), n = t.spectrum?.(), i = r.length;
120
120
  if (!n?.length) {
121
121
  let t = Date.now() / 260;
122
122
  return Array.from({ length: i }, (n, r) => {
123
123
  let i = .65 + .35 * Math.sin(t + r * .9);
124
- return L + e * 2.4 * i;
124
+ return I + e * 2.4 * i;
125
125
  });
126
126
  }
127
127
  let a = Math.max(1, Math.floor(n.length / 2)), o = Math.max(1, Math.floor(a / i));
128
128
  return Array.from({ length: i }, (e, t) => {
129
129
  let r = 0;
130
130
  for (let e = 0; e < o; e += 1) r += n[t * o + e] ?? 0;
131
- return L + r / o / 255 * 2.2;
131
+ return I + r / o / 255 * 2.2;
132
132
  });
133
133
  }, s = () => {
134
134
  let e = n.value?.children;
@@ -137,36 +137,36 @@ var ve = {
137
137
  });
138
138
  }, c = () => {
139
139
  let e = o();
140
- r = r.map((t, n) => t + (Math.min(1, Math.max(L, e[n] ?? L)) - t) * xe), s(), i = requestAnimationFrame(c);
140
+ r = r.map((t, n) => t + (Math.min(1, Math.max(I, e[n] ?? I)) - t) * Se), s(), i = requestAnimationFrame(c);
141
141
  }, l = () => {
142
142
  i !== void 0 && (cancelAnimationFrame(i), i = void 0);
143
143
  };
144
- return N(() => t.state, async (e) => {
145
- e !== "listening" && e !== "speaking" || a() ? (l(), r = r.map(() => L * 1.6), await re(), s()) : i === void 0 && (i = requestAnimationFrame(c));
146
- }, { immediate: !0 }), ie(l), (t, r) => (O(), S("div", {
147
- class: D(["pk-voice-orb", `pk-voice-orb--${e.state}`]),
144
+ return M(() => t.state, async (e) => {
145
+ e !== "listening" && e !== "speaking" || a() ? (l(), r = r.map(() => I * 1.6), await ie(), s()) : i === void 0 && (i = requestAnimationFrame(c));
146
+ }, { immediate: !0 }), ae(l), (t, r) => (D(), x("div", {
147
+ class: E(["pk-voice-orb", `pk-voice-orb--${e.state}`]),
148
148
  "aria-hidden": "true"
149
- }, [C("div", {
149
+ }, [S("div", {
150
150
  ref_key: "barsEl",
151
151
  ref: n,
152
152
  class: "pk-voice-orb__bars"
153
- }, [(O(!0), S(_, null, le(e.bars, (e) => (O(), S("span", {
153
+ }, [(D(!0), x(g, null, ue(e.bars, (e) => (D(), x("span", {
154
154
  key: e,
155
155
  class: "pk-voice-orb__bar"
156
156
  }))), 128))], 512)], 2));
157
157
  }
158
- }), Ce = {
158
+ }), we = {
159
159
  key: 0,
160
160
  class: "pk-voice-session__badge",
161
161
  "aria-hidden": "true"
162
- }, we = {
162
+ }, Te = {
163
163
  class: "pk-voice-session__status",
164
164
  role: "status"
165
- }, Te = {
165
+ }, Ee = {
166
166
  key: 0,
167
167
  class: "pk-voice-session__live-dot",
168
168
  "aria-hidden": "true"
169
- }, R = ["title"], z = ["title"], Ee = { class: "pk-voice-session__actions" }, De = /* @__PURE__ */ E({
169
+ }, L = ["title"], R = ["title"], De = { class: "pk-voice-session__actions" }, Oe = /* @__PURE__ */ T({
170
170
  __name: "PkVoiceSession",
171
171
  props: {
172
172
  state: {},
@@ -185,17 +185,17 @@ var ve = {
185
185
  "dismiss"
186
186
  ],
187
187
  setup(e, { emit: t }) {
188
- let n = e, r = t, { t: i } = fe({ useScope: "global" }), a = y(() => n.error ? i("message.voiceFailed") : n.state === "connecting" ? i("message.voiceConnecting") : n.state === "speaking" ? i("message.voiceSpeaking") : n.muted ? i("message.voiceMuted") : i("message.voiceListening")), o = y(() => {
188
+ let n = e, r = t, { t: i } = pe({ useScope: "global" }), a = v(() => n.error ? i("message.voiceFailed") : n.state === "connecting" ? i("message.voiceConnecting") : n.state === "speaking" ? i("message.voiceSpeaking") : n.muted ? i("message.voiceMuted") : i("message.voiceListening")), o = v(() => {
189
189
  if (n.remainingSeconds === void 0) return;
190
190
  let e = Math.floor(n.remainingSeconds / 60), t = n.remainingSeconds % 60;
191
191
  return `${e}:${String(t).padStart(2, "0")}`;
192
- }), s = y(() => n.remainingSeconds !== void 0 && n.remainingSeconds <= 30), c = y(() => !n.error && (n.state === "listening" || n.state === "speaking")), l = y(() => {
192
+ }), s = v(() => n.remainingSeconds !== void 0 && n.remainingSeconds <= 30), c = v(() => !n.error && (n.state === "listening" || n.state === "speaking")), l = v(() => {
193
193
  if (c.value) return n.state === "speaking" ? "speaking" : n.muted ? void 0 : "listening";
194
194
  });
195
195
  return (t, n) => {
196
- let u = g;
197
- return O(), S("div", { class: D(["pk-voice-session", { "pk-voice-session--failed": !!e.error }]) }, [
198
- e.error ? (O(), S("span", Ce, [w(u, { name: "ri:error-warning-line" })])) : (O(), b(Se, {
196
+ let u = h;
197
+ return D(), x("div", { class: E(["pk-voice-session", { "pk-voice-session--failed": !!e.error }]) }, [
198
+ e.error ? (D(), x("span", we, [C(u, { name: "ri:error-warning-line" })])) : (D(), y(Ce, {
199
199
  key: 1,
200
200
  state: e.state,
201
201
  sample: e.sample,
@@ -205,37 +205,37 @@ var ve = {
205
205
  "sample",
206
206
  "spectrum"
207
207
  ])),
208
- C("div", we, [C("span", { class: D(["pk-voice-session__state", l.value && `pk-voice-session__state--${l.value}`]) }, [c.value ? (O(), S("span", Te)) : x("", !0), te(" " + j(a.value), 1)], 2), e.error ? (O(), S("p", {
208
+ S("div", Te, [S("span", { class: E(["pk-voice-session__state", l.value && `pk-voice-session__state--${l.value}`]) }, [c.value ? (D(), x("span", Ee)) : b("", !0), ne(" " + A(a.value), 1)], 2), e.error ? (D(), x("p", {
209
209
  key: 0,
210
210
  class: "pk-voice-session__detail",
211
211
  title: e.rawError ?? e.error
212
- }, j(e.error), 9, R)) : x("", !0)]),
213
- o.value ? (O(), S("span", {
212
+ }, A(e.error), 9, L)) : b("", !0)]),
213
+ o.value ? (D(), x("span", {
214
214
  key: 2,
215
- class: D(["pk-voice-session__timer", { "pk-voice-session__timer--warning": s.value }]),
216
- title: M(i)("hint.voiceRemaining"),
215
+ class: E(["pk-voice-session__timer", { "pk-voice-session__timer--warning": s.value }]),
216
+ title: j(i)("hint.voiceRemaining"),
217
217
  "aria-hidden": "true"
218
- }, j(o.value), 11, z)) : x("", !0),
219
- C("div", Ee, [e.error ? (O(), S(_, { key: 0 }, [w(d, {
218
+ }, A(o.value), 11, R)) : b("", !0),
219
+ S("div", De, [e.error ? (D(), x(g, { key: 0 }, [C(d, {
220
220
  icon: "ri:refresh-line",
221
- label: M(i)("action.retry"),
221
+ label: j(i)("action.retry"),
222
222
  onClick: n[0] ||= (e) => r("retry")
223
- }, null, 8, ["label"]), e.live ? (O(), b(d, {
223
+ }, null, 8, ["label"]), e.live ? (D(), y(d, {
224
224
  key: 0,
225
225
  icon: "ri:stop-circle-line",
226
226
  modifiers: "danger",
227
- title: M(i)("action.hangUp"),
228
- "aria-label": M(i)("action.hangUp"),
227
+ title: j(i)("action.hangUp"),
228
+ "aria-label": j(i)("action.hangUp"),
229
229
  onClick: n[1] ||= (e) => r("hang-up")
230
- }, null, 8, ["title", "aria-label"])) : (O(), b(d, {
230
+ }, null, 8, ["title", "aria-label"])) : (D(), y(d, {
231
231
  key: 1,
232
232
  icon: "ri:close-line",
233
- label: M(i)("action.close"),
233
+ label: j(i)("action.close"),
234
234
  onClick: n[2] ||= (e) => r("dismiss")
235
- }, null, 8, ["label"]))], 64)) : (O(), S(_, { key: 1 }, [w(d, {
235
+ }, null, 8, ["label"]))], 64)) : (D(), x(g, { key: 1 }, [C(d, {
236
236
  icon: e.muted ? "ri:mic-off-line" : "ri:mic-line",
237
- title: e.muted ? M(i)("action.unmute") : M(i)("action.mute"),
238
- "aria-label": e.muted ? M(i)("action.unmute") : M(i)("action.mute"),
237
+ title: e.muted ? j(i)("action.unmute") : j(i)("action.mute"),
238
+ "aria-label": e.muted ? j(i)("action.unmute") : j(i)("action.mute"),
239
239
  "aria-pressed": e.muted,
240
240
  onClick: n[3] ||= (e) => r("toggle-mute")
241
241
  }, null, 8, [
@@ -243,34 +243,34 @@ var ve = {
243
243
  "title",
244
244
  "aria-label",
245
245
  "aria-pressed"
246
- ]), w(d, {
246
+ ]), C(d, {
247
247
  icon: "ri:stop-circle-line",
248
248
  modifiers: "danger",
249
- title: M(i)("action.hangUp"),
250
- "aria-label": M(i)("action.hangUp"),
249
+ title: j(i)("action.hangUp"),
250
+ "aria-label": j(i)("action.hangUp"),
251
251
  onClick: n[4] ||= (e) => r("hang-up")
252
252
  }, null, 8, ["title", "aria-label"])], 64))])
253
253
  ], 2);
254
254
  };
255
255
  }
256
- }), Oe = (e) => {
257
- let t = A(), n = k("disconnected"), r = k("listening"), i = k(), o = k([]), s = k(), c = k(), l, u, d = 0, f = !1, p = () => {
256
+ }), ke = (e) => {
257
+ let t = k(), n = O("disconnected"), r = O("listening"), i = O(), o = O([]), s = O(), c = O(), l, u, d = 0, f = !1, p = () => {
258
258
  u &&= (clearInterval(u), void 0), s.value = void 0;
259
- }, m = (e) => {
259
+ }, ee = (e) => {
260
260
  let t = Date.now() + e * 1e3, n = () => {
261
261
  let e = Math.max(0, Math.ceil((t - Date.now()) / 1e3));
262
- s.value = e, e === 0 && g();
262
+ s.value = e, e === 0 && h();
263
263
  };
264
264
  n(), u = setInterval(n, 1e3);
265
- }, h = async (t) => {
265
+ }, m = async (t) => {
266
266
  t && (l === t && (l = void 0), await e.closeGrant?.(t).catch(() => void 0));
267
- }, g = async () => {
267
+ }, h = async () => {
268
268
  d += 1, p();
269
269
  let e = l;
270
270
  l = void 0;
271
271
  let i = t.value;
272
- t.value = void 0, await i?.endSession().catch(() => void 0), await h(e), n.value = "disconnected", r.value = "listening";
273
- }, _ = async () => {
272
+ t.value = void 0, await i?.endSession().catch(() => void 0), await m(e), n.value = "disconnected", r.value = "listening";
273
+ }, g = async () => {
274
274
  if (f || t.value || n.value === "connecting") return;
275
275
  i.value = void 0, o.value = [], r.value = "listening", c.value = void 0, n.value = "connecting", d += 1;
276
276
  let a = d, s = () => a === d && !f, u;
@@ -285,10 +285,10 @@ var ve = {
285
285
  l = d.sessionId, u = d.sessionId, c.value = d.chatId;
286
286
  let { VoiceConversation: f } = await a;
287
287
  if (!s()) {
288
- await h(d.sessionId);
288
+ await m(d.sessionId);
289
289
  return;
290
290
  }
291
- let g = await f.startSession({
291
+ let h = await f.startSession({
292
292
  signedUrl: d.signedUrl,
293
293
  customLlmExtraBody: { voice_session_id: d.sessionId },
294
294
  clientTools: e.clientTools?.() ?? {},
@@ -312,23 +312,23 @@ var ve = {
312
312
  s() && (i.value = e);
313
313
  },
314
314
  onDisconnect: (a) => {
315
- s() && (p(), t.value = void 0, n.value = "disconnected", r.value = "listening", a.reason === "error" && (i.value = a.message), h(d.sessionId), e.onTurnEnd?.());
315
+ s() && (p(), t.value = void 0, n.value = "disconnected", r.value = "listening", a.reason === "error" && (i.value = a.message), m(d.sessionId), e.onTurnEnd?.());
316
316
  }
317
317
  });
318
318
  if (!s()) {
319
- await g.endSession().catch(() => void 0), await h(d.sessionId);
319
+ await h.endSession().catch(() => void 0), await m(d.sessionId);
320
320
  return;
321
321
  }
322
- t.value = g, m(d.maxSessionSeconds);
322
+ t.value = h, ee(d.maxSessionSeconds);
323
323
  } catch (e) {
324
- if (await h(u), !s()) return;
324
+ if (await m(u), !s()) return;
325
325
  t.value = void 0, p(), n.value = "disconnected", i.value = e instanceof Error ? e.message : String(e);
326
326
  }
327
- }, v = () => {
327
+ }, _ = () => {
328
328
  i.value = void 0;
329
- }, b = (e) => {
329
+ }, y = (e) => {
330
330
  t.value?.setMicMuted(e);
331
- }, x = (e) => {
331
+ }, b = (e) => {
332
332
  let n = t.value;
333
333
  if (!n || !e.trim()) return !1;
334
334
  try {
@@ -336,7 +336,7 @@ var ve = {
336
336
  } catch (e) {
337
337
  return a.warn("The spoken answer could not be sent", e), !1;
338
338
  }
339
- }, S = (e) => {
339
+ }, x = (e) => {
340
340
  let n = t.value;
341
341
  if (!n) return 0;
342
342
  try {
@@ -344,21 +344,21 @@ var ve = {
344
344
  } catch {
345
345
  return 0;
346
346
  }
347
- }, C = (e) => {
347
+ }, S = (e) => {
348
348
  let n = t.value;
349
349
  if (n) try {
350
350
  return e === "input" ? n.getInputByteFrequencyData() : n.getOutputByteFrequencyData();
351
351
  } catch {
352
352
  return;
353
353
  }
354
- }, ee = () => {
354
+ }, te = () => {
355
355
  let e = l;
356
- l = void 0, d += 1, p(), h(e);
356
+ l = void 0, d += 1, p(), m(e);
357
357
  let r = t.value;
358
358
  t.value = void 0, r?.endSession().catch(() => void 0), n.value = "disconnected";
359
359
  };
360
- return typeof window < "u" && window.addEventListener("pagehide", ee), oe(() => {
361
- f = !0, typeof window < "u" && window.removeEventListener("pagehide", ee), g();
360
+ return typeof window < "u" && window.addEventListener("pagehide", te), se(() => {
361
+ f = !0, typeof window < "u" && window.removeEventListener("pagehide", te), h();
362
362
  }), {
363
363
  status: n,
364
364
  mode: r,
@@ -366,25 +366,25 @@ var ve = {
366
366
  transcript: o,
367
367
  remainingSeconds: s,
368
368
  chatId: c,
369
- isActive: y(() => n.value === "connected" || n.value === "connecting"),
370
- isConnecting: y(() => n.value === "connecting"),
371
- isSpeaking: y(() => n.value === "connected" && r.value === "speaking"),
372
- isListening: y(() => n.value === "connected" && r.value === "listening"),
373
- start: _,
374
- stop: g,
375
- dismissError: v,
376
- setMuted: b,
377
- sendUserMessage: x,
378
- readLevel: S,
379
- readSpectrum: C
369
+ isActive: v(() => n.value === "connected" || n.value === "connecting"),
370
+ isConnecting: v(() => n.value === "connecting"),
371
+ isSpeaking: v(() => n.value === "connected" && r.value === "speaking"),
372
+ isListening: v(() => n.value === "connected" && r.value === "listening"),
373
+ start: g,
374
+ stop: h,
375
+ dismissError: _,
376
+ setMuted: y,
377
+ sendUserMessage: b,
378
+ readLevel: x,
379
+ readSpectrum: S
380
380
  };
381
- }, B = 4e3, ke = [
381
+ }, z = 4e3, Ae = [
382
382
  3e3,
383
383
  5e3,
384
384
  1e4
385
- ], Ae = 12e4, je = 3e4;
386
- function Me(e) {
387
- let t = k(null), n = k(!1), r, i = !1, a = () => {
385
+ ], je = 12e4, Me = 3e4;
386
+ function Ne(e) {
387
+ let t = O(null), n = O(!1), r, i = !1, a = () => {
388
388
  clearTimeout(r), r = void 0;
389
389
  }, o = (e, t) => {
390
390
  a(), i || (r = setTimeout(() => void t(), e));
@@ -401,12 +401,12 @@ function Me(e) {
401
401
  }
402
402
  let r = t.value;
403
403
  if (r) {
404
- let e = Date.parse(r.dueAt) - Date.now() + B;
405
- o(Math.max(B, e), () => l(r.wakeId, Date.now(), 0));
404
+ let e = Date.parse(r.dueAt) - Date.now() + z;
405
+ o(Math.max(z, e), () => l(r.wakeId, Date.now(), 0));
406
406
  }
407
407
  }
408
408
  async function l(t, n, r) {
409
- await e.refreshMessages(), !i && (s(t) || Date.now() - n >= Ae ? await c() : o(ke[Math.min(r, ke.length - 1)], () => l(t, n, r + 1)));
409
+ await e.refreshMessages(), !i && (s(t) || Date.now() - n >= je ? await c() : o(Ae[Math.min(r, Ae.length - 1)], () => l(t, n, r + 1)));
410
410
  }
411
411
  async function u() {
412
412
  n.value = !0;
@@ -424,29 +424,29 @@ function Me(e) {
424
424
  function p() {
425
425
  f = e.chatId();
426
426
  }
427
- function m() {
427
+ function ee() {
428
428
  f === e.chatId() && (f = void 0, c());
429
429
  }
430
- function h() {
430
+ function m() {
431
431
  f = void 0;
432
432
  }
433
- let g = y(() => e.messages().some((e) => e.role === "user"));
434
- N([e.chatId, g], ([, t]) => {
433
+ let h = v(() => e.messages().some((e) => e.role === "user"));
434
+ M([e.chatId, h], ([, t]) => {
435
435
  d();
436
436
  let n = e.status(), r = n === "submitted" || n === "streaming" || f === e.chatId();
437
437
  t && !r && c();
438
- }, { immediate: !0 }), N(e.status, (e, t) => {
439
- e === "ready" && t !== "ready" && g.value && c();
438
+ }, { immediate: !0 }), M(e.status, (e, t) => {
439
+ e === "ready" && t !== "ready" && h.value && c();
440
440
  });
441
- let _;
442
- function v() {
441
+ let g;
442
+ function _() {
443
443
  t.value && document.visibilityState === "visible" && e.apiClient().markChatWakeupPresence(e.agentId(), e.chatId()).catch(() => void 0);
444
444
  }
445
- let b = () => v();
446
- return document.addEventListener("visibilitychange", b), N(() => t.value?.wakeId, (e) => {
447
- clearInterval(_), _ = void 0, e && !i && (v(), _ = setInterval(v, je));
448
- }), ie(() => {
449
- i = !0, a(), clearInterval(_), document.removeEventListener("visibilitychange", b);
445
+ let y = () => _();
446
+ return document.addEventListener("visibilitychange", y), M(() => t.value?.wakeId, (e) => {
447
+ clearInterval(g), g = void 0, e && !i && (_(), g = setInterval(_, Me));
448
+ }), ae(() => {
449
+ i = !0, a(), clearInterval(g), document.removeEventListener("visibilitychange", y);
450
450
  }), {
451
451
  pendingWakeup: t,
452
452
  isStopping: n,
@@ -454,13 +454,13 @@ function Me(e) {
454
454
  reset: d,
455
455
  stop: u,
456
456
  spokenTurnStarted: p,
457
- spokenTurnsWritten: m,
458
- forgetSpokenTurns: h
457
+ spokenTurnsWritten: ee,
458
+ forgetSpokenTurns: m
459
459
  };
460
460
  }
461
461
  // ../../packages/components/src/chat/useChatFilePreview.ts
462
- function Ne(e) {
463
- let t = k(), n = k(), r = k(!1), i = k(!1), a = /* @__PURE__ */ new Map(), o = 0, s = 0, c = async (c) => {
462
+ function Pe(e) {
463
+ let t = O(), n = O(), r = O(!1), i = O(!1), a = /* @__PURE__ */ new Map(), o = 0, s = 0, c = async (c) => {
464
464
  let l = ++o, u = s;
465
465
  t.value = c, i.value = !1;
466
466
  let d = a.get(c.storedFileName);
@@ -491,19 +491,19 @@ function Ne(e) {
491
491
  };
492
492
  }
493
493
  // ../../packages/components/src/chat/PkChatbotViewChat.vue?vue&type=script&setup=true&lang.ts
494
- var Pe = { class: "pk-chatbot-view-chat__input-stage" }, Fe = {
494
+ var Fe = { class: "pk-chatbot-view-chat__input-stage" }, Ie = {
495
495
  key: 1,
496
496
  class: "p-md border-t border-surface-3 text-center text-12 text-danger bg-surface-danger"
497
- }, Ie = { class: "pk-chatbot-view-chat__agent-chip" }, Le = {
497
+ }, Le = { class: "pk-chatbot-view-chat__agent-chip" }, Re = {
498
498
  key: 0,
499
499
  class: "pk-chatbot-view-chat__agent-chip-name"
500
- }, Re = {
500
+ }, ze = {
501
501
  key: 0,
502
502
  class: "pk-chatbot-view-chat__drop-overlay"
503
- }, ze = {
503
+ }, Be = {
504
504
  key: 1,
505
505
  class: "pk-chatbot-view-chat__preview"
506
- }, Be = 1e3, Ve = 3e3, He = 6e4, Ue = 3e5, We = 6e5, Ge = /* @__PURE__ */ E({
506
+ }, Ve = 1e3, He = 3e3, Ue = 6e4, We = 3e5, Ge = 6e5, Ke = /* @__PURE__ */ T({
507
507
  __name: "PkChatbotViewChat",
508
508
  props: {
509
509
  agentId: {},
@@ -512,83 +512,88 @@ var Pe = { class: "pk-chatbot-view-chat__input-stage" }, Fe = {
512
512
  },
513
513
  emits: ["show-info", "revise"],
514
514
  setup(a, { emit: d }) {
515
- let _ = T(() => import("./PkToolShowForm-Dmyn6cMU.js").then((e) => e.n)), te = T(() => import("./PkToolShowContactForm-Bi5N1fFe.js").then((e) => e.n)), E = T(() => import("./PkToolShowSuggestedReply-C7dUB3dz.js").then((e) => e.n)), re = T(() => import("./PkToolShowSources-NOSBkQCi.js").then((e) => e.n)), ae = T(() => import("./PkToolRequestGeolocation-B__wk6m3.js").then((e) => e.n)), oe = T(() => import("./PkToolRequestOAuthConnection-BAttadSC.js")), se = T(() => import("./PkToolShowLocation-C7hBRwq8.js").then((e) => e.n)), le = T(() => import("./PkToolShowDiagram-D8NF9lZu.js")), A = T(() => import("./PkToolChatFile-DaivFIhK.js").then((e) => e.n)), ue = T(() => import("./PkToolShareDocument-IreRCu-j.js").then((e) => e.n)), _e = T(() => import("./PkFilePreview-ItDTJWaw.js").then((e) => e.n)), ve = T(() => import("./PkFilePreviewDialog-4YbxP5m2.js").then((e) => e.n)), F = a, ye = d, I = r(F.agentId), { agentInterface: L, agentFileUpload: xe, agentType: Se, agentVoice: Ce, actions: we, revisedAnswers: Te, messages: R, chat: z, messageFeedbacks: Ee, feedbackDialogMessage: B, isFeedbackSubmitting: ke, isFeedbackSubmitted: Ae, feedbackSubmitError: je, isLeadSubmitted: Ge, isLoadingSubmitLead: Ke, submitLeadError: qe, input: V, inputMessagePlaceholder: Je, isConversationBlocked: Ye, baseUrl: Xe, pendingAttachments: Ze, isAttachmentLimitReached: Qe, fileLimitError: $e, apiClient: H, isDark: et, hostToolsPending: tt, pageNoticeLevel: nt, hostConfirmation: rt, agentPageAccess: it, hostStepTitles: at, canQueue: ot, queuedMessages: st, backgroundAnswers: ct, inputFocusRequest: lt } = he(I);
516
- ce(c, at);
517
- let ut = de("inputEl");
518
- N(lt, () => {
519
- ut.value?.focus();
515
+ let g = w(() => import("./PkToolShowForm-C4JnalBU.js").then((e) => e.n)), ne = w(() => import("./PkToolShowContactForm-NRfvmPLV.js").then((e) => e.n)), T = w(() => import("./PkToolShowSuggestedReply-Bb7Inxa4.js").then((e) => e.n)), ie = w(() => import("./PkToolShowSources-BVfcp1iE.js").then((e) => e.n)), oe = w(() => import("./PkToolRequestGeolocation-gEDbmudT.js").then((e) => e.n)), se = w(() => import("./PkToolRequestOAuthConnection-Dy0GXNwC.js")), ce = w(() => import("./PkToolShowLocation-C7hBRwq8.js").then((e) => e.n)), ue = w(() => import("./PkToolShowDiagram-VTi8vwcN.js")), k = w(() => import("./PkToolChatFile-Ca45de6q.js").then((e) => e.n)), de = w(() => import("./PkToolShareDocument-DeUo345m.js").then((e) => e.n)), ve = w(() => import("./PkFilePreview-ItDTJWaw.js").then((e) => e.n)), ye = w(() => import("./PkFilePreviewDialog-4YbxP5m2.js").then((e) => e.n)), P = a, be = d, F = r(P.agentId), { agentInterface: I, agentFileUpload: Se, agentType: Ce, agentVoice: we, actions: Te, revisedAnswers: Ee, messages: L, chat: R, messageFeedbacks: De, feedbackDialogMessage: z, isFeedbackSubmitting: Ae, isFeedbackSubmitted: je, feedbackSubmitError: Me, isLeadSubmitted: Ke, isLoadingSubmitLead: qe, submitLeadError: Je, input: B, inputMessagePlaceholder: Ye, isConversationBlocked: Xe, baseUrl: Ze, pendingAttachments: Qe, isAttachmentLimitReached: $e, fileLimitError: et, apiClient: V, isDark: tt, hostToolsPending: nt, pageNoticeLevel: rt, hostConfirmation: it, agentPageAccess: at, hostStepTitles: ot, canQueue: st, queuedMessages: ct, backgroundAnswers: lt, inputFocusRequest: ut, pagePointer: H, pagePointerAvailable: dt, pagePointing: ft } = ge(F);
516
+ le(c, ot);
517
+ let pt = fe("inputEl");
518
+ M(ut, () => {
519
+ pt.value?.focus();
520
+ }), M(H, (e) => {
521
+ e && pt.value?.focus();
520
522
  });
521
- let U = y(() => Se.value === "reasoning" ? void 0 : xe.value), W = (e) => H.value.getMediaDownloadUrl(F.agentId, I.localChatId, e), { handleSubmit: dt, stopGeneration: ft, regenerate: pt, onUpvote: mt, onDownvote: ht, onFeedback: gt, onFeedbackSubmit: _t, onLeadSubmit: vt, startNewChat: yt, addToolOutput: bt, addToolApprovalResponse: xt, handleFileSelect: St, clearFileLimitError: Ct, refreshMessages: wt, appendMessage: Tt, closePageNotice: Et, respondHostConfirmation: Dt, editQueuedMessage: Ot, removeQueuedMessage: kt, openBackgroundAnswer: At, dismissBackgroundAnswer: jt } = I, { t: G } = fe({ useScope: "global" }), Mt = y(() => tt.value > 0), Nt = y(() => Mt.value && z.value.status === "ready" ? "streaming" : z.value.status), Pt = l(() => it.value?.notice), Ft = y(() => nt.value ? Pt.value || G(`message.pageAccessNotice.${nt.value}`) : void 0), It = y(() => {
522
- let e = $e.value;
523
+ let mt = v(() => H.value ? {
524
+ kind: H.value.kind,
525
+ label: H.value.label
526
+ } : void 0), U = v(() => Ce.value === "reasoning" ? void 0 : Se.value), W = (e) => V.value.getMediaDownloadUrl(P.agentId, F.localChatId, e), { handleSubmit: ht, stopGeneration: gt, regenerate: _t, onUpvote: vt, onDownvote: yt, onFeedback: bt, onFeedbackSubmit: xt, onLeadSubmit: St, startNewChat: Ct, addToolOutput: wt, addToolApprovalResponse: Tt, handleFileSelect: Et, clearFileLimitError: Dt, refreshMessages: Ot, appendMessage: kt, closePageNotice: At, respondHostConfirmation: jt, editQueuedMessage: Mt, removeQueuedMessage: Nt, openBackgroundAnswer: Pt, dismissBackgroundAnswer: Ft } = F, { t: G } = pe({ useScope: "global" }), It = v(() => nt.value > 0), Lt = v(() => It.value && R.value.status === "ready" ? "streaming" : R.value.status), Rt = l(() => at.value?.notice), zt = v(() => rt.value ? Rt.value || G(`message.pageAccessNotice.${rt.value}`) : void 0), Bt = v(() => {
527
+ let e = et.value;
523
528
  if (e) return e.reason === "per-chat" ? G("message.fileLimitPerChat", { max: e.max }) : G("message.fileLimitPerMessage", { max: e.max });
524
- }), Lt = y(() => ct.value.map(({ chatId: e, title: t }) => ({
529
+ }), Vt = v(() => lt.value.map(({ chatId: e, title: t }) => ({
525
530
  id: e,
526
531
  text: t ? G("message.backgroundAnswerReady", { title: t }) : G("message.backgroundAnswerReadyUntitled")
527
- }))), Rt = l(() => L.value?.dismissableNotice), zt = y(() => R.value.some((e) => e.role === "user")), Bt = y(() => F.modifier === "fullscreen" && !zt.value), Vt = ge(L, () => F.userName), Ht = de("chatViewEl"), { width: Ut } = me(Ht, {
532
+ }))), Ht = l(() => I.value?.dismissableNotice), Ut = v(() => L.value.some((e) => e.role === "user")), Wt = v(() => P.modifier === "fullscreen" && !Ut.value), Gt = _e(I, () => P.userName), Kt = fe("chatViewEl"), { width: qt } = he(Kt, {
528
533
  width: 0,
529
534
  height: 0
530
- }, { box: "border-box" }), Wt = y(() => Ut.value >= Be), Gt = y(() => Ut.value > 0 && Ut.value < 576), { target: K, preview: Kt, loading: qt, error: Jt, open: Yt, close: Xt, reset: Zt } = Ne((e) => H.value.getChatFilePreview(F.agentId, I.localChatId, e));
531
- N(() => I.localChatId, Zt);
532
- let Qt = async (e) => (await H.value.expandSourceContext(F.agentId, e.documentId, e.chunkIndex)).content, $t = async (e) => {
533
- let t = await H.value.downloadSourceDocument(F.agentId, e);
535
+ }, { box: "border-box" }), Jt = v(() => qt.value >= Ve), Yt = v(() => qt.value > 0 && qt.value < 576), { target: K, preview: Xt, loading: Zt, error: Qt, open: $t, close: en, reset: tn } = Pe((e) => V.value.getChatFilePreview(P.agentId, F.localChatId, e));
536
+ M(() => F.localChatId, tn);
537
+ let nn = async (e) => (await V.value.expandSourceContext(P.agentId, e.documentId, e.chunkIndex)).content, rn = async (e) => {
538
+ let t = await V.value.downloadSourceDocument(P.agentId, e);
534
539
  window.open(t.downloadUrl, "_blank");
535
- }, { isOverDropZone: en } = pe(Ht, {
540
+ }, { isOverDropZone: an } = me(Kt, {
536
541
  dataTypes: (e) => t(e, U.value?.allowedMimeTypes ?? []),
537
542
  onDrop: (e) => {
538
- if (U.value?.enabled && e) for (let t of e) St(t);
543
+ if (U.value?.enabled && e) for (let t of e) Et(t);
539
544
  }
540
- }), q = k(!1), J = !1, Y = k(!1), tn = [
545
+ }), q = O(!1), J = !1, Y = O(!1), on = [
541
546
  3e3,
542
547
  5e3,
543
548
  1e4
544
- ], nn, X, rn = !1, an = 0, on = !1;
545
- function sn() {
546
- clearTimeout(nn), nn = void 0, X = void 0, rn = !1, an = 0, Y.value = !1;
549
+ ], sn, X, cn = !1, ln = 0, un = !1;
550
+ function dn() {
551
+ clearTimeout(sn), sn = void 0, X = void 0, cn = !1, ln = 0, Y.value = !1;
547
552
  }
548
- function cn(e) {
549
- J || (clearTimeout(nn), nn = setTimeout(() => {
550
- ln();
553
+ function fn(e) {
554
+ J || (clearTimeout(sn), sn = setTimeout(() => {
555
+ pn();
551
556
  }, e));
552
557
  }
553
- async function ln() {
554
- if (J || on) return;
555
- on = !0;
558
+ async function pn() {
559
+ if (J || un) return;
560
+ un = !0;
556
561
  let e;
557
562
  try {
558
- e = await wt();
563
+ e = await Ot();
559
564
  } finally {
560
- on = !1;
565
+ un = !1;
561
566
  }
562
567
  if (J) return;
563
- if (e === "caught-up" && (Y.value = !1, Rn()), Z.isActive.value) {
564
- X = void 0, rn = !1, an = 0, cn(Ve);
568
+ if (e === "caught-up" && (Y.value = !1, Hn()), Z.isActive.value) {
569
+ X = void 0, cn = !1, ln = 0, fn(He);
565
570
  return;
566
571
  }
567
- X === void 0 && (X = Date.now(), rn = !!Z.error.value);
572
+ X === void 0 && (X = Date.now(), cn = !!Z.error.value);
568
573
  let t = Date.now() - X;
569
- if (e === "caught-up" && t >= (rn ? Ue : He) || t >= We) {
570
- sn(), zn();
574
+ if (e === "caught-up" && t >= (cn ? We : Ue) || t >= Ge) {
575
+ dn(), Un();
571
576
  return;
572
577
  }
573
- let n = tn[Math.min(an, tn.length - 1)];
574
- an += 1, cn(n);
578
+ let n = on[Math.min(ln, on.length - 1)];
579
+ ln += 1, fn(n);
575
580
  }
576
- let un = (e = 1200) => {
577
- cn(e);
578
- }, dn, Z = Oe({
581
+ let mn = (e = 1200) => {
582
+ fn(e);
583
+ }, hn, Z = ke({
579
584
  fetchGrant: async () => {
580
- dn = I.voicePageTools();
581
- let e = await H.value.createVoiceSession(F.agentId, I.localChatId, {
582
- deviceContext: I.buildDeviceContext(),
583
- externalContext: I.externalContext,
584
- pageTools: dn?.declaration
585
+ hn = F.voicePageTools();
586
+ let e = await V.value.createVoiceSession(P.agentId, F.localChatId, {
587
+ deviceContext: F.buildDeviceContext(),
588
+ externalContext: F.externalContext,
589
+ pageTools: hn?.declaration
585
590
  });
586
- return e.chatId !== I.localChatId && (I.localChatId = e.chatId), e;
591
+ return e.chatId !== F.localChatId && (F.localChatId = e.chatId), e;
587
592
  },
588
- closeGrant: (e) => H.value.closeVoiceSession(F.agentId, e),
589
- clientTools: () => dn?.clientTools,
593
+ closeGrant: (e) => V.value.closeVoiceSession(P.agentId, e),
594
+ clientTools: () => hn?.clientTools,
590
595
  onTranscript: (e) => {
591
- e.role === "user" ? (Y.value = !0, Ln(), Tt({
596
+ e.role === "user" ? (Y.value = !0, Vn(), kt({
592
597
  id: `${i}user-${n()}`,
593
598
  role: "user",
594
599
  parts: [{
@@ -598,63 +603,63 @@ var Pe = { class: "pk-chatbot-view-chat__input-stage" }, Fe = {
598
603
  })) : Y.value = !1;
599
604
  },
600
605
  onTurnEnd: () => {
601
- un();
606
+ mn();
602
607
  }
603
608
  });
604
- N(() => Z.isActive.value, (e) => {
605
- e || I.cancelVoicePageCalls();
606
- }), N(() => Z.error.value, (e) => {
609
+ M(() => Z.isActive.value, (e) => {
610
+ e || F.cancelVoicePageCalls();
611
+ }), M(() => Z.error.value, (e) => {
607
612
  e && (Y.value = !1);
608
613
  });
609
- let fn = y(() => Ce.value?.enabled === !0), pn = y(() => Z.error.value ? "error" : Z.isConnecting.value ? "connecting" : Z.isSpeaking.value ? "speaking" : Z.isActive.value ? "listening" : "idle"), mn = y(() => {
614
+ let gn = v(() => we.value?.enabled === !0), _n = v(() => Z.error.value ? "error" : Z.isConnecting.value ? "connecting" : Z.isSpeaking.value ? "speaking" : Z.isActive.value ? "listening" : "idle"), vn = v(() => {
610
615
  let e = Z.error.value;
611
616
  if (e) return /took too long/i.test(e) ? G("message.voiceTookTooLong") : /cascade|no response|custom_llm_error/i.test(e) ? G("message.voiceNoAnswer") : G("message.voiceInterrupted");
612
- }), hn = y(() => Z.isSpeaking.value ? "output" : "input"), gn = () => Z.readLevel(hn.value), _n = () => Z.readSpectrum(hn.value), vn = async () => {
613
- q.value = !1, await Z.start(), Z.isActive.value && (sn(), cn(Ve));
614
- }, yn = async () => {
615
- Y.value = !1, await Z.stop(), !J && un(0);
616
- }, bn = () => {
617
+ }), yn = v(() => Z.isSpeaking.value ? "output" : "input"), bn = () => Z.readLevel(yn.value), xn = () => Z.readSpectrum(yn.value), Sn = async () => {
618
+ q.value = !1, await Z.start(), Z.isActive.value && (dn(), fn(He));
619
+ }, Cn = async () => {
620
+ Y.value = !1, await Z.stop(), !J && mn(0);
621
+ }, wn = () => {
617
622
  Z.dismissError();
618
- }, xn = async () => {
619
- Z.dismissError(), await Z.stop(), await vn();
620
- }, Q = (e) => e?.toolCallId ?? "", Sn = k(/* @__PURE__ */ new Set()), Cn = (e) => Sn.value.has(Q(e)), wn = k(/* @__PURE__ */ new Map()), $ = (e, t) => Z.isActive.value ? (Z.sendUserMessage(t) && (Sn.value = new Set(Sn.value).add(Q(e)), un()), !0) : !1, Tn = (e, t, n) => {
621
- $(t, o(t, n)) || bt({
623
+ }, Tn = async () => {
624
+ Z.dismissError(), await Z.stop(), await Sn();
625
+ }, Q = (e) => e?.toolCallId ?? "", En = O(/* @__PURE__ */ new Set()), Dn = (e) => En.value.has(Q(e)), On = O(/* @__PURE__ */ new Map()), $ = (e, t) => Z.isActive.value ? (Z.sendUserMessage(t) && (En.value = new Set(En.value).add(Q(e)), mn()), !0) : !1, kn = (e, t, n) => {
626
+ $(t, o(t, n)) || wt({
622
627
  tool: e,
623
628
  toolCallId: Q(t),
624
629
  output: n
625
630
  });
626
- }, En = (e) => {
631
+ }, An = (e) => {
627
632
  let t = e.confirmed ? G("message.voiceConfirmed") : G("message.voiceCancelled");
628
- $({ toolCallId: e.toolCallId }, t) ? Sn.value.has(e.toolCallId) && (wn.value = new Map(wn.value).set(e.toolCallId, e.confirmed)) : bt({
633
+ $({ toolCallId: e.toolCallId }, t) ? En.value.has(e.toolCallId) && (On.value = new Map(On.value).set(e.toolCallId, e.confirmed)) : wt({
629
634
  tool: "requestConfirm",
630
635
  toolCallId: e.toolCallId,
631
636
  output: e.confirmed ? "confirmed" : "cancelled"
632
637
  });
633
- }, Dn = /* @__PURE__ */ new Set([
638
+ }, jn = /* @__PURE__ */ new Set([
634
639
  "tool-editSpreadsheet",
635
640
  "tool-editWordDocument",
636
641
  "tool-createSpreadsheet",
637
642
  "tool-createWordDocument"
638
- ]), On = y(() => {
643
+ ]), Mn = v(() => {
639
644
  let e = /* @__PURE__ */ new Map();
640
- for (let t of R.value) for (let n of t.parts) {
645
+ for (let t of L.value) for (let n of t.parts) {
641
646
  let { type: t, state: r, output: i } = n;
642
- Dn.has(t) && r === "output-available" && i?.fileId && i.version && e.set(i.fileId, Math.max(e.get(i.fileId) ?? 0, i.version));
647
+ jn.has(t) && r === "output-available" && i?.fileId && i.version && e.set(i.fileId, Math.max(e.get(i.fileId) ?? 0, i.version));
643
648
  }
644
649
  return e;
645
- }), kn = y(() => Ye.value ? void 0 : (e) => {
646
- V.value = G("messagePart.chatFileRestoreRequest", e), dt();
647
- }), An = (e, t) => {
648
- $(e, t) || (V.value = t, dt());
649
- }, jn = (e, t) => {
650
+ }), Nn = v(() => Xe.value ? void 0 : (e) => {
651
+ B.value = G("messagePart.chatFileRestoreRequest", e), ht();
652
+ }), Pn = (e, t) => {
653
+ $(e, t) || (B.value = t, ht());
654
+ }, Fn = (e, t) => {
650
655
  let n = t.error ? G("message.voiceLocationRefused") : G("message.voiceLocationShared", { place: t.displayName ?? `${t.latitude}, ${t.longitude}` });
651
- $(e, n) || bt({
656
+ $(e, n) || wt({
652
657
  tool: "requestGeolocation",
653
658
  toolCallId: Q(e),
654
659
  output: t
655
660
  });
656
- }, Mn = (e, t) => {
657
- $(e, G("message.voiceConnectionDone")) || bt({
661
+ }, In = (e, t) => {
662
+ $(e, G("message.voiceConnectionDone")) || wt({
658
663
  tool: "requestOAuthConnection",
659
664
  toolCallId: Q(e),
660
665
  output: {
@@ -662,90 +667,90 @@ var Pe = { class: "pk-chatbot-view-chat__input-stage" }, Fe = {
662
667
  mcpServerId: t
663
668
  }
664
669
  });
665
- }, Nn = () => {
670
+ }, Ln = () => {
666
671
  q.value = !q.value, Z.setMuted(q.value);
667
672
  };
668
- ie(() => {
669
- J = !0, sn();
673
+ ae(() => {
674
+ J = !0, dn();
670
675
  });
671
- let { pendingWakeup: Pn, isStopping: Fn, stop: In, spokenTurnStarted: Ln, spokenTurnsWritten: Rn, forgetSpokenTurns: zn } = Me({
672
- agentId: () => F.agentId,
673
- chatId: () => I.localChatId,
674
- apiClient: () => H.value,
675
- messages: () => R.value,
676
- refreshMessages: wt,
677
- status: () => z.value.status
676
+ let { pendingWakeup: Rn, isStopping: zn, stop: Bn, spokenTurnStarted: Vn, spokenTurnsWritten: Hn, forgetSpokenTurns: Un } = Ne({
677
+ agentId: () => P.agentId,
678
+ chatId: () => F.localChatId,
679
+ apiClient: () => V.value,
680
+ messages: () => L.value,
681
+ refreshMessages: Ot,
682
+ status: () => R.value.status
678
683
  });
679
684
  return (t, n) => {
680
- let r = g;
681
- return O(), S("div", {
685
+ let r = h;
686
+ return D(), x("div", {
682
687
  ref_key: "chatViewEl",
683
- ref: Ht,
684
- class: D(["pk-chatbot-view-chat", {
685
- "pk-chatbot-view-chat--dragover": M(en) && U.value?.enabled,
686
- "pk-chatbot-view-chat--empty": Bt.value,
687
- "pk-chatbot-view-chat--with-preview": !!M(K) && Wt.value
688
+ ref: Kt,
689
+ class: E(["pk-chatbot-view-chat", {
690
+ "pk-chatbot-view-chat--dragover": j(an) && U.value?.enabled,
691
+ "pk-chatbot-view-chat--empty": Wt.value,
692
+ "pk-chatbot-view-chat--with-preview": !!j(K) && Jt.value
688
693
  }])
689
694
  }, [
690
- w(v, {
695
+ C(_, {
691
696
  name: "pk-chatbot-view-chat-fade",
692
697
  mode: "out-in"
693
698
  }, {
694
- default: P(() => [Bt.value ? (O(), b(m, {
699
+ default: N(() => [Wt.value ? (D(), y(ee, {
695
700
  key: 0,
696
- greeting: M(Vt),
697
- logo: M(L)?.logo,
698
- name: M(I).name
701
+ greeting: j(Gt),
702
+ logo: j(I)?.logo,
703
+ name: j(F).name
699
704
  }, null, 8, [
700
705
  "greeting",
701
706
  "logo",
702
707
  "name"
703
- ])) : (O(), b(e, {
708
+ ])) : (D(), y(e, {
704
709
  key: 1,
705
710
  class: "flex flex-col flex-1 min-h-0 p-md overflow-y-auto",
706
711
  interactive: "",
707
- messages: M(R),
708
- "confirm-verdicts-on-call": wn.value,
709
- status: M(z).status,
710
- error: M(z).error,
711
- "main-color": M(L)?.mainColor,
712
- "text-color": M(L)?.textColor,
713
- "revised-answers": M(Te),
714
- actions: M(we),
715
- "message-feedbacks": M(Ee),
716
- "feedback-message-id": M(B)?.id,
717
- "feedback-loading": M(ke),
718
- "feedback-submitted": M(Ae),
719
- "feedback-error": M(je),
720
- "show-extended-steps": M(L)?.showExtendedSteps,
721
- "hide-reasoning": M(L)?.showReasoning === !1,
712
+ messages: j(L),
713
+ "confirm-verdicts-on-call": On.value,
714
+ status: j(R).status,
715
+ error: j(R).error,
716
+ "main-color": j(I)?.mainColor,
717
+ "text-color": j(I)?.textColor,
718
+ "revised-answers": j(Ee),
719
+ actions: j(Te),
720
+ "message-feedbacks": j(De),
721
+ "feedback-message-id": j(z)?.id,
722
+ "feedback-loading": j(Ae),
723
+ "feedback-submitted": j(je),
724
+ "feedback-error": j(Me),
725
+ "show-extended-steps": j(I)?.showExtendedSteps,
726
+ "hide-reasoning": j(I)?.showReasoning === !1,
722
727
  "awaiting-spoken-answer": Y.value,
723
- "host-working": Mt.value,
724
- "host-confirmation": M(rt),
725
- "is-dark": M(et),
728
+ "host-working": It.value,
729
+ "host-confirmation": j(it),
730
+ "is-dark": j(tt),
726
731
  "show-scroll-to-bottom": a.modifier === "fullscreen",
727
- onFeedbackSubmit: n[0] ||= (e) => M(_t)(e),
728
- onFeedbackClose: n[1] ||= (e) => B.value = void 0,
729
- onRegenerate: M(pt),
730
- onAutoRetry: M(pt),
731
- onResetChat: M(yt),
732
- onShowInfo: n[2] ||= (e) => ye("show-info", e),
733
- onRevise: n[3] ||= (e) => ye("revise", e),
734
- onUpvote: M(mt),
735
- onDownvote: M(ht),
736
- onFeedback: M(gt),
737
- onApprovalRespond: M(xt),
738
- onConfirmRespond: En,
739
- onHostConfirmRespond: M(Dt)
732
+ onFeedbackSubmit: n[0] ||= (e) => j(xt)(e),
733
+ onFeedbackClose: n[1] ||= (e) => z.value = void 0,
734
+ onRegenerate: j(_t),
735
+ onAutoRetry: j(_t),
736
+ onResetChat: j(Ct),
737
+ onShowInfo: n[2] ||= (e) => be("show-info", e),
738
+ onRevise: n[3] ||= (e) => be("revise", e),
739
+ onUpvote: j(vt),
740
+ onDownvote: j(yt),
741
+ onFeedback: j(bt),
742
+ onApprovalRespond: j(Tt),
743
+ onConfirmRespond: An,
744
+ onHostConfirmRespond: j(jt)
740
745
  }, {
741
- "tool-showContactForm": P(({ part: e }) => [w(M(te), {
746
+ "tool-showContactForm": N(({ part: e }) => [C(j(ne), {
742
747
  part: e,
743
- readonly: !M(Xe),
744
- submitted: M(Ge),
745
- loading: M(Ke),
746
- error: M(qe),
747
- "privacy-policy-notice": M(L)?.privacyPolicyNotice,
748
- onSubmit: M(vt)
748
+ readonly: !j(Ze),
749
+ submitted: j(Ke),
750
+ loading: j(qe),
751
+ error: j(Je),
752
+ "privacy-policy-notice": j(I)?.privacyPolicyNotice,
753
+ onSubmit: j(St)
749
754
  }, null, 8, [
750
755
  "part",
751
756
  "readonly",
@@ -755,20 +760,20 @@ var Pe = { class: "pk-chatbot-view-chat__input-stage" }, Fe = {
755
760
  "privacy-policy-notice",
756
761
  "onSubmit"
757
762
  ])]),
758
- "tool-showSuggestedReply": P(({ part: e }) => [w(M(E), {
763
+ "tool-showSuggestedReply": N(({ part: e }) => [C(j(T), {
759
764
  part: e,
760
- onSelect: (t) => An(e, t)
765
+ onSelect: (t) => Pn(e, t)
761
766
  }, null, 8, ["part", "onSelect"])]),
762
- "tool-showSources": P(({ part: e }) => [w(M(re), {
767
+ "tool-showSources": N(({ part: e }) => [C(j(ie), {
763
768
  part: e,
764
- "on-expand-context": Qt,
765
- "on-download": $t
769
+ "on-expand-context": nn,
770
+ "on-download": rn
766
771
  }, null, 8, ["part"])]),
767
- "tool-showForm": P(({ part: e }) => [w(v, { mode: "out-in" }, {
768
- default: P(() => [w(M(_), {
772
+ "tool-showForm": N(({ part: e }) => [C(_, { mode: "out-in" }, {
773
+ default: N(() => [C(j(g), {
769
774
  part: e,
770
- answered: Cn(e),
771
- onSelect: (t) => Tn("showForm", e, t)
775
+ answered: Dn(e),
776
+ onSelect: (t) => kn("showForm", e, t)
772
777
  }, null, 8, [
773
778
  "part",
774
779
  "answered",
@@ -776,12 +781,12 @@ var Pe = { class: "pk-chatbot-view-chat__input-stage" }, Fe = {
776
781
  ])]),
777
782
  _: 2
778
783
  }, 1024)]),
779
- "tool-showMultipleChoice": P(({ part: e }) => [w(v, { mode: "out-in" }, {
780
- default: P(() => [w(M(_), {
784
+ "tool-showMultipleChoice": N(({ part: e }) => [C(_, { mode: "out-in" }, {
785
+ default: N(() => [C(j(g), {
781
786
  part: e,
782
787
  "allow-custom-answer": "",
783
- answered: Cn(e),
784
- onSelect: (t) => Tn("showMultipleChoice", e, t)
788
+ answered: Dn(e),
789
+ onSelect: (t) => kn("showMultipleChoice", e, t)
785
790
  }, null, 8, [
786
791
  "part",
787
792
  "answered",
@@ -789,12 +794,12 @@ var Pe = { class: "pk-chatbot-view-chat__input-stage" }, Fe = {
789
794
  ])]),
790
795
  _: 2
791
796
  }, 1024)]),
792
- "tool-requestOAuthConnection": P(({ part: e }) => [w(M(oe), {
797
+ "tool-requestOAuthConnection": N(({ part: e }) => [C(j(se), {
793
798
  part: e,
794
- "backend-url": M(Xe),
795
- "resolve-connection": (e) => M(H).getOAuthAuthorizeUrl(F.agentId, e),
796
- "check-connection": (e) => M(H).getOAuthConnectionStatus(F.agentId, e),
797
- onConnected: (t) => Mn(e, t)
799
+ "backend-url": j(Ze),
800
+ "resolve-connection": (e) => j(V).getOAuthAuthorizeUrl(P.agentId, e),
801
+ "check-connection": (e) => j(V).getOAuthConnectionStatus(P.agentId, e),
802
+ onConnected: (t) => In(e, t)
798
803
  }, null, 8, [
799
804
  "part",
800
805
  "backend-url",
@@ -802,156 +807,161 @@ var Pe = { class: "pk-chatbot-view-chat__input-stage" }, Fe = {
802
807
  "check-connection",
803
808
  "onConnected"
804
809
  ])]),
805
- "tool-requestGeolocation": P(({ part: e }) => [w(M(ae), {
810
+ "tool-requestGeolocation": N(({ part: e }) => [C(j(oe), {
806
811
  part: e,
807
- "call-live": M(Z).isActive.value,
808
- "reverse-geocode": (e, t) => M(H).reverseGeocode(e, t),
809
- onResult: (t) => jn(e, t)
812
+ "call-live": j(Z).isActive.value,
813
+ "reverse-geocode": (e, t) => j(V).reverseGeocode(e, t),
814
+ onResult: (t) => Fn(e, t)
810
815
  }, null, 8, [
811
816
  "part",
812
817
  "call-live",
813
818
  "reverse-geocode",
814
819
  "onResult"
815
820
  ])]),
816
- "tool-showLocation": P(({ part: e }) => [w(M(se), {
821
+ "tool-showLocation": N(({ part: e }) => [C(j(ce), {
817
822
  part: e,
818
- "is-dark": M(et),
819
- "main-color": M(L)?.mainColor,
820
- "forward-geocode": (e, t) => M(H).forwardGeocode(e, t)
823
+ "is-dark": j(tt),
824
+ "main-color": j(I)?.mainColor,
825
+ "forward-geocode": (e, t) => j(V).forwardGeocode(e, t)
821
826
  }, null, 8, [
822
827
  "part",
823
828
  "is-dark",
824
829
  "main-color",
825
830
  "forward-geocode"
826
831
  ])]),
827
- "tool-showDiagram": P(({ part: e }) => [w(M(le), {
832
+ "tool-showDiagram": N(({ part: e }) => [C(j(ue), {
828
833
  part: e,
829
- "is-dark": M(et)
834
+ "is-dark": j(tt)
830
835
  }, null, 8, ["part", "is-dark"])]),
831
- "tool-editSpreadsheet": P(({ part: e }) => [(O(), b(M(A), {
832
- key: M(s)(e),
836
+ "tool-editSpreadsheet": N(({ part: e }) => [(D(), y(j(k), {
837
+ key: j(s)(e),
833
838
  part: e,
834
839
  "file-url": W,
835
- preview: M(Yt),
836
- "latest-versions": On.value,
837
- restore: kn.value
840
+ preview: j($t),
841
+ "latest-versions": Mn.value,
842
+ restore: Nn.value
838
843
  }, null, 8, [
839
844
  "part",
840
845
  "preview",
841
846
  "latest-versions",
842
847
  "restore"
843
848
  ]))]),
844
- "tool-editWordDocument": P(({ part: e }) => [(O(), b(M(A), {
845
- key: M(s)(e),
849
+ "tool-editWordDocument": N(({ part: e }) => [(D(), y(j(k), {
850
+ key: j(s)(e),
846
851
  part: e,
847
852
  "file-url": W,
848
- preview: M(Yt),
849
- "latest-versions": On.value,
850
- restore: kn.value
853
+ preview: j($t),
854
+ "latest-versions": Mn.value,
855
+ restore: Nn.value
851
856
  }, null, 8, [
852
857
  "part",
853
858
  "preview",
854
859
  "latest-versions",
855
860
  "restore"
856
861
  ]))]),
857
- "tool-createSpreadsheet": P(({ part: e }) => [(O(), b(M(A), {
858
- key: M(s)(e),
862
+ "tool-createSpreadsheet": N(({ part: e }) => [(D(), y(j(k), {
863
+ key: j(s)(e),
859
864
  part: e,
860
865
  "file-url": W,
861
- preview: M(Yt),
862
- "latest-versions": On.value,
863
- restore: kn.value
866
+ preview: j($t),
867
+ "latest-versions": Mn.value,
868
+ restore: Nn.value
864
869
  }, null, 8, [
865
870
  "part",
866
871
  "preview",
867
872
  "latest-versions",
868
873
  "restore"
869
874
  ]))]),
870
- "tool-createWordDocument": P(({ part: e }) => [(O(), b(M(A), {
871
- key: M(s)(e),
875
+ "tool-createWordDocument": N(({ part: e }) => [(D(), y(j(k), {
876
+ key: j(s)(e),
872
877
  part: e,
873
878
  "file-url": W,
874
- preview: M(Yt),
875
- "latest-versions": On.value,
876
- restore: kn.value
879
+ preview: j($t),
880
+ "latest-versions": Mn.value,
881
+ restore: Nn.value
877
882
  }, null, 8, [
878
883
  "part",
879
884
  "preview",
880
885
  "latest-versions",
881
886
  "restore"
882
887
  ]))]),
883
- "tool-shareDocument": P(({ part: e }) => [(O(), b(M(ue), {
884
- key: M(s)(e),
888
+ "tool-shareDocument": N(({ part: e }) => [(D(), y(j(de), {
889
+ key: j(s)(e),
885
890
  part: e,
886
- "on-download": $t
891
+ "on-download": rn
887
892
  }, null, 8, ["part"]))]),
888
893
  _: 1
889
894
  }, 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(".")))]),
890
895
  _: 1
891
896
  }),
892
- M(st).length ? (O(), b(p, {
897
+ j(ct).length ? (D(), y(p, {
893
898
  key: 0,
894
- messages: M(st),
895
- onEdit: M(Ot),
896
- onRemove: M(kt)
899
+ messages: j(ct),
900
+ onEdit: j(Mt),
901
+ onRemove: j(Nt)
897
902
  }, null, 8, [
898
903
  "messages",
899
904
  "onEdit",
900
905
  "onRemove"
901
- ])) : x("", !0),
902
- C("div", Pe, [
903
- w(v, { name: "pk-chatbot-view-chat-fade" }, {
904
- default: P(() => [Bt.value ? (O(), b(be, {
906
+ ])) : b("", !0),
907
+ S("div", Fe, [
908
+ C(_, { name: "pk-chatbot-view-chat-fade" }, {
909
+ default: N(() => [Wt.value ? (D(), y(xe, {
905
910
  key: 0,
906
911
  class: "pk-chatbot-view-chat__aurora",
907
912
  "source-selector": ".pk-chatbot-input__form"
908
- })) : x("", !0)]),
913
+ })) : b("", !0)]),
909
914
  _: 1
910
915
  }),
911
- M(Pn) && !M(Ye) ? (O(), b(h, {
916
+ j(Rn) && !j(Xe) ? (D(), y(m, {
912
917
  key: 0,
913
- pending: M(Pn),
914
- stopping: M(Fn),
915
- onStop: M(In)
918
+ pending: j(Rn),
919
+ stopping: j(zn),
920
+ onStop: j(Bn)
916
921
  }, null, 8, [
917
922
  "pending",
918
923
  "stopping",
919
924
  "onStop"
920
- ])) : x("", !0),
921
- M(Ye) ? (O(), S("div", Fe, j(M(G)("message.chatErrorConversationBlocked")), 1)) : pn.value === "idle" ? (O(), b(f, {
925
+ ])) : b("", !0),
926
+ j(Xe) ? (D(), x("div", Ie, A(j(G)("message.chatErrorConversationBlocked")), 1)) : _n.value === "idle" ? (D(), y(f, {
922
927
  key: 3,
923
928
  ref_key: "inputEl",
924
- ref: ut,
925
- modelValue: M(V),
926
- "onUpdate:modelValue": n[4] ||= (e) => ne(V) ? V.value = e : null,
927
- "pending-attachments": M(Ze),
928
- "onUpdate:pendingAttachments": n[5] ||= (e) => ne(Ze) ? Ze.value = e : null,
929
- placeholder: M(Je),
930
- "dismissable-notice": M(Rt) && M(z).messages.length <= 1 ? M(Rt) : void 0,
931
- "page-notice": Ft.value,
932
- status: Nt.value,
933
- "max-message-length": M(L)?.maxMessageLength,
929
+ ref: pt,
930
+ modelValue: j(B),
931
+ "onUpdate:modelValue": n[4] ||= (e) => re(B) ? B.value = e : null,
932
+ "pending-attachments": j(Qe),
933
+ "onUpdate:pendingAttachments": n[5] ||= (e) => re(Qe) ? Qe.value = e : null,
934
+ placeholder: j(Ye),
935
+ "dismissable-notice": j(Ht) && j(R).messages.length <= 1 ? j(Ht) : void 0,
936
+ "page-notice": zt.value,
937
+ status: Lt.value,
938
+ "max-message-length": j(I)?.maxMessageLength,
934
939
  "file-upload": U.value,
935
- "attachment-limit-reached": M(Qe),
936
- "attachment-notice": It.value,
937
- "voice-enabled": fn.value,
938
- "queue-enabled": M(ot),
939
- "answer-notices": Lt.value,
940
- onStopGeneration: M(ft),
941
- onSubmit: M(dt),
942
- onFileSelect: M(St),
943
- onDismissAttachmentNotice: M(Ct),
944
- onDismissPageNotice: M(Et),
945
- onOpenAnswerNotice: M(At),
946
- onDismissAnswerNotice: M(jt),
947
- onVoiceStart: vn
948
- }, ee({ _: 2 }, [a.modifier === "fullscreen" ? {
940
+ "attachment-limit-reached": j($e),
941
+ "attachment-notice": Bt.value,
942
+ "voice-enabled": gn.value,
943
+ "queue-enabled": j(st),
944
+ "answer-notices": Vt.value,
945
+ "pointer-available": j(dt),
946
+ pointing: j(ft),
947
+ pointer: mt.value,
948
+ onPoint: n[6] ||= (e) => j(F).pagePointerStart?.(),
949
+ onRemovePointer: n[7] ||= (e) => H.value = void 0,
950
+ onStopGeneration: j(gt),
951
+ onSubmit: j(ht),
952
+ onFileSelect: j(Et),
953
+ onDismissAttachmentNotice: j(Dt),
954
+ onDismissPageNotice: j(At),
955
+ onOpenAnswerNotice: j(Pt),
956
+ onDismissAnswerNotice: j(Ft),
957
+ onVoiceStart: Sn
958
+ }, te({ _: 2 }, [a.modifier === "fullscreen" ? {
949
959
  name: "prepend",
950
- fn: P(() => [C("span", Ie, [w(u, {
960
+ fn: N(() => [S("span", Le, [C(u, {
951
961
  class: "pk-chatbot-view-chat__agent-chip-avatar",
952
- "img-src": M(L)?.logo,
953
- name: M(I).name
954
- }, null, 8, ["img-src", "name"]), M(I).name ? (O(), S("strong", Le, j(M(I).name), 1)) : x("", !0)])]),
962
+ "img-src": j(I)?.logo,
963
+ name: j(F).name
964
+ }, null, 8, ["img-src", "name"]), j(F).name ? (D(), x("strong", Re, A(j(F).name), 1)) : b("", !0)])]),
955
965
  key: "0"
956
966
  } : void 0]), 1032, [
957
967
  "modelValue",
@@ -967,6 +977,9 @@ var Pe = { class: "pk-chatbot-view-chat__input-stage" }, Fe = {
967
977
  "voice-enabled",
968
978
  "queue-enabled",
969
979
  "answer-notices",
980
+ "pointer-available",
981
+ "pointing",
982
+ "pointer",
970
983
  "onStopGeneration",
971
984
  "onSubmit",
972
985
  "onFileSelect",
@@ -974,21 +987,21 @@ var Pe = { class: "pk-chatbot-view-chat__input-stage" }, Fe = {
974
987
  "onDismissPageNotice",
975
988
  "onOpenAnswerNotice",
976
989
  "onDismissAnswerNotice"
977
- ])) : (O(), b(De, {
990
+ ])) : (D(), y(Oe, {
978
991
  key: 2,
979
- state: pn.value,
980
- sample: gn,
981
- spectrum: _n,
982
- "remaining-seconds": M(Z).remainingSeconds.value,
992
+ state: _n.value,
993
+ sample: bn,
994
+ spectrum: xn,
995
+ "remaining-seconds": j(Z).remainingSeconds.value,
983
996
  muted: q.value,
984
- error: mn.value,
985
- "raw-error": M(Z).error.value,
986
- live: M(Z).isActive.value,
997
+ error: vn.value,
998
+ "raw-error": j(Z).error.value,
999
+ live: j(Z).isActive.value,
987
1000
  class: "pk-chatbot-view-chat__voice",
988
- onToggleMute: Nn,
989
- onHangUp: yn,
990
- onRetry: xn,
991
- onDismiss: bn
1001
+ onToggleMute: Ln,
1002
+ onHangUp: Cn,
1003
+ onRetry: Tn,
1004
+ onDismiss: wn
992
1005
  }, null, 8, [
993
1006
  "state",
994
1007
  "remaining-seconds",
@@ -998,23 +1011,23 @@ var Pe = { class: "pk-chatbot-view-chat__input-stage" }, Fe = {
998
1011
  "live"
999
1012
  ]))
1000
1013
  ]),
1001
- w(v, null, {
1002
- default: P(() => [M(en) && U.value?.enabled ? (O(), S("div", Re, [w(r, {
1014
+ C(_, null, {
1015
+ default: N(() => [j(an) && U.value?.enabled ? (D(), x("div", ze, [C(r, {
1003
1016
  name: "ri:upload-cloud-2-line",
1004
1017
  class: "pk-chatbot-view-chat__drop-overlay-icon"
1005
- }), C("span", null, j(M(G)("action.dropFile")), 1)])) : x("", !0)]),
1018
+ }), S("span", null, A(j(G)("action.dropFile")), 1)])) : b("", !0)]),
1006
1019
  _: 1
1007
1020
  }),
1008
- M(K) && Wt.value ? (O(), S("aside", ze, [w(M(_e), {
1021
+ j(K) && Jt.value ? (D(), x("aside", Be, [C(j(ve), {
1009
1022
  closable: "",
1010
- kind: M(K).kind,
1011
- filename: M(K).filename,
1012
- version: M(K).version,
1013
- "download-url": W(M(K).storedFileName),
1014
- preview: M(Kt),
1015
- loading: M(qt),
1016
- error: M(Jt),
1017
- onClose: M(Xt)
1023
+ kind: j(K).kind,
1024
+ filename: j(K).filename,
1025
+ version: j(K).version,
1026
+ "download-url": W(j(K).storedFileName),
1027
+ preview: j(Xt),
1028
+ loading: j(Zt),
1029
+ error: j(Qt),
1030
+ onClose: j(en)
1018
1031
  }, null, 8, [
1019
1032
  "kind",
1020
1033
  "filename",
@@ -1024,16 +1037,16 @@ var Pe = { class: "pk-chatbot-view-chat__input-stage" }, Fe = {
1024
1037
  "loading",
1025
1038
  "error",
1026
1039
  "onClose"
1027
- ])])) : x("", !0),
1028
- M(K) && !Wt.value ? (O(), b(M(ve), {
1040
+ ])])) : b("", !0),
1041
+ j(K) && !Jt.value ? (D(), y(j(ye), {
1029
1042
  key: 2,
1030
- target: M(K),
1031
- "download-url": W(M(K).storedFileName),
1032
- preview: M(Kt),
1033
- loading: M(qt),
1034
- error: M(Jt),
1035
- fullscreen: Gt.value,
1036
- onClose: M(Xt)
1043
+ target: j(K),
1044
+ "download-url": W(j(K).storedFileName),
1045
+ preview: j(Xt),
1046
+ loading: j(Zt),
1047
+ error: j(Qt),
1048
+ fullscreen: Yt.value,
1049
+ onClose: j(en)
1037
1050
  }, null, 8, [
1038
1051
  "target",
1039
1052
  "download-url",
@@ -1042,11 +1055,11 @@ var Pe = { class: "pk-chatbot-view-chat__input-stage" }, Fe = {
1042
1055
  "error",
1043
1056
  "fullscreen",
1044
1057
  "onClose"
1045
- ])) : x("", !0)
1058
+ ])) : b("", !0)
1046
1059
  ], 2);
1047
1060
  };
1048
1061
  }
1049
1062
  });
1050
- export { be as a, Se as i, Ne as n, De as r, Ge as t };
1063
+ export { xe as a, Ce as i, Pe as n, Oe as r, Ke as t };
1051
1064
 
1052
- //# sourceMappingURL=PkChatbotViewChat-Bjw6x7VD.js.map
1065
+ //# sourceMappingURL=PkChatbotViewChat-BSRRz4ma.js.map