@8wave/ai-elements 0.121.0-beta.46 → 0.121.0-beta.48
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/_chunks/{Agent-BuPgJIt4.js → Agent-jMXkLts9.js} +36 -36
- package/dist/_chunks/Agent-jMXkLts9.js.map +1 -0
- package/dist/_chunks/{PkStreamingMarkdown-BlTH2AJX.js → PkStreamingMarkdown-C43RVcRW.js} +16 -10
- package/dist/_chunks/PkStreamingMarkdown-C43RVcRW.js.map +1 -0
- package/dist/_chunks/PkToolEditedFile-BZUXx8ZG.js +51 -0
- package/dist/_chunks/PkToolEditedFile-BZUXx8ZG.js.map +1 -0
- package/dist/_chunks/{PkToolRequestGeolocation-CxMAoAv6.js → PkToolRequestGeolocation-BJc2Ki0-.js} +2 -2
- package/dist/_chunks/{PkToolRequestGeolocation-CxMAoAv6.js.map → PkToolRequestGeolocation-BJc2Ki0-.js.map} +1 -1
- package/dist/_chunks/{PkToolRequestOAuthConnection-DU1Y2odZ.js → PkToolRequestOAuthConnection-OU56LTl0.js} +2 -2
- package/dist/_chunks/{PkToolRequestOAuthConnection-DU1Y2odZ.js.map → PkToolRequestOAuthConnection-OU56LTl0.js.map} +1 -1
- package/dist/_chunks/{PkToolShowArtifact-jQeIv65U.js → PkToolShowArtifact-yP7FXi0H.js} +2 -2
- package/dist/_chunks/{PkToolShowArtifact-jQeIv65U.js.map → PkToolShowArtifact-yP7FXi0H.js.map} +1 -1
- package/dist/_chunks/{PkToolShowContactForm-D7wg3Jlu.js → PkToolShowContactForm-w6aLTe1i.js} +2 -2
- package/dist/_chunks/{PkToolShowContactForm-D7wg3Jlu.js.map → PkToolShowContactForm-w6aLTe1i.js.map} +1 -1
- package/dist/_chunks/{PkToolShowForm-BMVgXxzl.js → PkToolShowForm-ChhVlxqc.js} +3 -3
- package/dist/_chunks/{PkToolShowForm-BMVgXxzl.js.map → PkToolShowForm-ChhVlxqc.js.map} +1 -1
- package/dist/_chunks/{PkToolShowImageGallery-Ba0CfKt6.js → PkToolShowImageGallery-D88a9a0P.js} +2 -2
- package/dist/_chunks/{PkToolShowImageGallery-Ba0CfKt6.js.map → PkToolShowImageGallery-D88a9a0P.js.map} +1 -1
- package/dist/_chunks/{PkToolShowProductList-DbZfUUWe.js → PkToolShowProductList-Jff9j3eQ.js} +2 -2
- package/dist/_chunks/{PkToolShowProductList-DbZfUUWe.js.map → PkToolShowProductList-Jff9j3eQ.js.map} +1 -1
- package/dist/_chunks/{PkToolShowSources-Dkt4IId2.js → PkToolShowSources-lWRoFGvC.js} +3 -3
- package/dist/_chunks/{PkToolShowSources-Dkt4IId2.js.map → PkToolShowSources-lWRoFGvC.js.map} +1 -1
- package/dist/_chunks/{PkToolShowSuggestedReply-BF2sT3B1.js → PkToolShowSuggestedReply-Ds0Yf31m.js} +2 -2
- package/dist/_chunks/{PkToolShowSuggestedReply-BF2sT3B1.js.map → PkToolShowSuggestedReply-Ds0Yf31m.js.map} +1 -1
- package/dist/_chunks/{PkToolShowVideo-l8JoSKCj.js → PkToolShowVideo-fNFvCi1_.js} +2 -2
- package/dist/_chunks/{PkToolShowVideo-l8JoSKCj.js.map → PkToolShowVideo-fNFvCi1_.js.map} +1 -1
- package/dist/_chunks/{PkToolShowWebPages-DtcEmrYt.js → PkToolShowWebPages-Bah-YhpM.js} +2 -2
- package/dist/_chunks/{PkToolShowWebPages-DtcEmrYt.js.map → PkToolShowWebPages-Bah-YhpM.js.map} +1 -1
- package/dist/_chunks/{chatImagePolicy-CQYTWTkP.js → chatImagePolicy-BvKnRHdM.js} +2 -2
- package/dist/_chunks/{chatImagePolicy-CQYTWTkP.js.map → chatImagePolicy-BvKnRHdM.js.map} +1 -1
- package/dist/_chunks/{markdown-Br9ROCBT.js → markdown-B1y2QQAa.js} +13 -13
- package/dist/_chunks/{markdown-Br9ROCBT.js.map → markdown-B1y2QQAa.js.map} +1 -1
- package/dist/ai-elements.es.js +1595 -1574
- package/dist/ai-elements.es.js.map +1 -1
- package/dist-vue/PkChatbot.js +1 -1
- package/dist-vue/PkChatbotEmptyState.js +1 -1
- package/dist-vue/PkChatbotInput.js +1 -1
- package/dist-vue/PkChatbotMessages.js +1 -1
- package/dist-vue/PkChatbotStepPayload.js +1 -1
- package/dist-vue/PkChatbotStepToolDetail.js +1 -1
- package/dist-vue/PkChatbotSteps.js +1 -1
- package/dist-vue/PkChatbotViewChat.js +1 -1
- package/dist-vue/PkChatbotViewConversations.js +1 -1
- package/dist-vue/PkChatbotViewFiles.js +1 -1
- package/dist-vue/PkChatbotViewProfile.js +1 -1
- package/dist-vue/_chunks/{Agent-DZb775Ak.js → Agent-BYwOk7Tt.js} +102 -102
- package/dist-vue/_chunks/Agent-BYwOk7Tt.js.map +1 -0
- package/dist-vue/_chunks/{Document-E72l_VU6.js → Document-CQdYPyrv.js} +2 -2
- package/dist-vue/_chunks/{Document-E72l_VU6.js.map → Document-CQdYPyrv.js.map} +1 -1
- package/dist-vue/_chunks/{PkChatbot-CObEhs2T.js → PkChatbot-DonyiJn3.js} +8 -8
- package/dist-vue/_chunks/{PkChatbot-CObEhs2T.js.map → PkChatbot-DonyiJn3.js.map} +1 -1
- package/dist-vue/_chunks/{PkChatbotEmptyState-Dh7ETVnf.js → PkChatbotEmptyState-CaNM6c77.js} +2 -2
- package/dist-vue/_chunks/{PkChatbotEmptyState-Dh7ETVnf.js.map → PkChatbotEmptyState-CaNM6c77.js.map} +1 -1
- package/dist-vue/_chunks/{PkChatbotInput-CuEoeb_M.js → PkChatbotInput-Bt02PGbZ.js} +2 -2
- package/dist-vue/_chunks/{PkChatbotInput-CuEoeb_M.js.map → PkChatbotInput-Bt02PGbZ.js.map} +1 -1
- package/dist-vue/_chunks/{PkChatbotMessages-DMSActW1.js → PkChatbotMessages-DIeAiZ7I.js} +25 -24
- package/dist-vue/_chunks/PkChatbotMessages-DIeAiZ7I.js.map +1 -0
- package/dist-vue/_chunks/{PkChatbotStepPayload-CXdsUMrw.js → PkChatbotStepPayload-D1_JG-M8.js} +2 -2
- package/dist-vue/_chunks/{PkChatbotStepPayload-CXdsUMrw.js.map → PkChatbotStepPayload-D1_JG-M8.js.map} +1 -1
- package/dist-vue/_chunks/{PkChatbotStepToolDetail-DbpXR7jh.js → PkChatbotStepToolDetail-DKJ3qg98.js} +3 -3
- package/dist-vue/_chunks/{PkChatbotStepToolDetail-DbpXR7jh.js.map → PkChatbotStepToolDetail-DKJ3qg98.js.map} +1 -1
- package/dist-vue/_chunks/{PkChatbotSteps-QFFZ0DjH.js → PkChatbotSteps-DgaJc9Pv.js} +5 -5
- package/dist-vue/_chunks/{PkChatbotSteps-QFFZ0DjH.js.map → PkChatbotSteps-DgaJc9Pv.js.map} +1 -1
- package/dist-vue/_chunks/{PkChatbotViewChat-BZb-U7Ju.js → PkChatbotViewChat-10NIwiUP.js} +172 -162
- package/dist-vue/_chunks/PkChatbotViewChat-10NIwiUP.js.map +1 -0
- package/dist-vue/_chunks/{PkChatbotViewConversations-CCPRWCKs.js → PkChatbotViewConversations-hsboinns.js} +3 -3
- package/dist-vue/_chunks/{PkChatbotViewConversations-CCPRWCKs.js.map → PkChatbotViewConversations-hsboinns.js.map} +1 -1
- package/dist-vue/_chunks/{PkChatbotViewFiles-BgqksCn0.js → PkChatbotViewFiles-DDO_L8UB.js} +9 -9
- package/dist-vue/_chunks/PkChatbotViewFiles-DDO_L8UB.js.map +1 -0
- package/dist-vue/_chunks/{PkChatbotViewProfile-B6tHWrqn.js → PkChatbotViewProfile-BC7Ok94X.js} +2 -2
- package/dist-vue/_chunks/{PkChatbotViewProfile-B6tHWrqn.js.map → PkChatbotViewProfile-BC7Ok94X.js.map} +1 -1
- package/dist-vue/_chunks/{PkStreamingMarkdown-DwDs-cGP.js → PkStreamingMarkdown-0jN60Rku.js} +3 -3
- package/dist-vue/_chunks/{PkStreamingMarkdown-DwDs-cGP.js.map → PkStreamingMarkdown-0jN60Rku.js.map} +1 -1
- package/dist-vue/_chunks/PkToolEditedFile-DsiNIHAR.js +50 -0
- package/dist-vue/_chunks/PkToolEditedFile-DsiNIHAR.js.map +1 -0
- package/dist-vue/_chunks/{PkToolRequestGeolocation-DC8hSH0j.js → PkToolRequestGeolocation-jkEuN6_1.js} +2 -2
- package/dist-vue/_chunks/{PkToolRequestGeolocation-DC8hSH0j.js.map → PkToolRequestGeolocation-jkEuN6_1.js.map} +1 -1
- package/dist-vue/_chunks/{PkToolRequestOAuthConnection-BH_-drvw.js → PkToolRequestOAuthConnection-BTNd8Urz.js} +2 -2
- package/dist-vue/_chunks/{PkToolRequestOAuthConnection-BH_-drvw.js.map → PkToolRequestOAuthConnection-BTNd8Urz.js.map} +1 -1
- package/dist-vue/_chunks/{PkToolShowArtifact-CjVN96wJ.js → PkToolShowArtifact-BitKlzvt.js} +2 -2
- package/dist-vue/_chunks/{PkToolShowArtifact-CjVN96wJ.js.map → PkToolShowArtifact-BitKlzvt.js.map} +1 -1
- package/dist-vue/_chunks/{PkToolShowContactForm-CmBLigw8.js → PkToolShowContactForm-DKkapC2s.js} +2 -2
- package/dist-vue/_chunks/{PkToolShowContactForm-CmBLigw8.js.map → PkToolShowContactForm-DKkapC2s.js.map} +1 -1
- package/dist-vue/_chunks/{PkToolShowDiagram-dKUU5_6F.js → PkToolShowDiagram-BI-fI2vG.js} +2 -2
- package/dist-vue/_chunks/{PkToolShowDiagram-dKUU5_6F.js.map → PkToolShowDiagram-BI-fI2vG.js.map} +1 -1
- package/dist-vue/_chunks/{PkToolShowForm-B6ESvq-5.js → PkToolShowForm-LR8mW4SY.js} +4 -4
- package/dist-vue/_chunks/{PkToolShowForm-B6ESvq-5.js.map → PkToolShowForm-LR8mW4SY.js.map} +1 -1
- package/dist-vue/_chunks/{PkToolShowImageGallery-Daq0IwTH.js → PkToolShowImageGallery-DuJ_cbcf.js} +2 -2
- package/dist-vue/_chunks/{PkToolShowImageGallery-Daq0IwTH.js.map → PkToolShowImageGallery-DuJ_cbcf.js.map} +1 -1
- package/dist-vue/_chunks/{PkToolShowProductList-Bc3Gzyxy.js → PkToolShowProductList-D7Tw7_NR.js} +2 -2
- package/dist-vue/_chunks/{PkToolShowProductList-Bc3Gzyxy.js.map → PkToolShowProductList-D7Tw7_NR.js.map} +1 -1
- package/dist-vue/_chunks/{PkToolShowSources-BDvRbenn.js → PkToolShowSources-DeplEks2.js} +3 -3
- package/dist-vue/_chunks/{PkToolShowSources-BDvRbenn.js.map → PkToolShowSources-DeplEks2.js.map} +1 -1
- package/dist-vue/_chunks/{PkToolShowSuggestedReply-Cd6VkzvJ.js → PkToolShowSuggestedReply-Dw-yePEO.js} +2 -2
- package/dist-vue/_chunks/{PkToolShowSuggestedReply-Cd6VkzvJ.js.map → PkToolShowSuggestedReply-Dw-yePEO.js.map} +1 -1
- package/dist-vue/_chunks/{PkToolShowVideo-Bo1gsD97.js → PkToolShowVideo-CAJhU52k.js} +2 -2
- package/dist-vue/_chunks/{PkToolShowVideo-Bo1gsD97.js.map → PkToolShowVideo-CAJhU52k.js.map} +1 -1
- package/dist-vue/_chunks/{PkToolShowWebPages-DI3sZiqh.js → PkToolShowWebPages-Be6dKCsO.js} +2 -2
- package/dist-vue/_chunks/{PkToolShowWebPages-DI3sZiqh.js.map → PkToolShowWebPages-Be6dKCsO.js.map} +1 -1
- package/dist-vue/_chunks/{createChatbotApiClient-hcFAulTq.js → createChatbotApiClient-huxzfST2.js} +16 -16
- package/dist-vue/_chunks/{createChatbotApiClient-hcFAulTq.js.map → createChatbotApiClient-huxzfST2.js.map} +1 -1
- package/dist-vue/_chunks/{useChatbotStore-Ct7G-voO.js → useChatbotStore-8tG3oA_R.js} +20 -20
- package/dist-vue/_chunks/{useChatbotStore-Ct7G-voO.js.map → useChatbotStore-8tG3oA_R.js.map} +1 -1
- package/dist-vue/_chunks/{utils-EPX3V3VI.js → utils-_H2BDYuj.js} +16 -10
- package/dist-vue/_chunks/utils-_H2BDYuj.js.map +1 -0
- package/dist-vue/api.js +1 -1
- package/dist-vue/composables.js +28 -18
- package/dist-vue/composables.js.map +1 -1
- package/dist-vue/index.js +5211 -5194
- package/dist-vue/index.js.map +1 -1
- package/dist-vue/locales.js +10 -0
- package/dist-vue/packages/components/src/chat/PkAgentSettingsPanel.d.ts +2 -2
- package/dist-vue/packages/components/src/chat/{PkToolEditSpreadsheet.d.ts → PkToolEditedFile.d.ts} +4 -3
- package/dist-vue/packages/components/src/chat/useWakeupWatch.d.ts +5 -1
- package/dist-vue/packages/composable/src/chatbot/api/createChatbotApiClient.d.ts +5 -5
- package/dist-vue/packages/composable/src/chatbot/useChatbotStore.d.ts +7 -7
- package/dist-vue/packages/composable/src/useFileRow.d.ts +7 -6
- package/dist-vue/packages/models/src/schema/Agent.d.ts +42 -0
- package/package.json +1 -1
- package/dist/_chunks/Agent-BuPgJIt4.js.map +0 -1
- package/dist/_chunks/PkStreamingMarkdown-BlTH2AJX.js.map +0 -1
- package/dist/_chunks/PkToolEditSpreadsheet-CDxglslA.js +0 -41
- package/dist/_chunks/PkToolEditSpreadsheet-CDxglslA.js.map +0 -1
- package/dist-vue/_chunks/Agent-DZb775Ak.js.map +0 -1
- package/dist-vue/_chunks/PkChatbotMessages-DMSActW1.js.map +0 -1
- package/dist-vue/_chunks/PkChatbotViewChat-BZb-U7Ju.js.map +0 -1
- package/dist-vue/_chunks/PkChatbotViewFiles-BgqksCn0.js.map +0 -1
- package/dist-vue/_chunks/PkToolEditSpreadsheet-B61LtERY.js +0 -40
- package/dist-vue/_chunks/PkToolEditSpreadsheet-B61LtERY.js.map +0 -1
- package/dist-vue/_chunks/utils-EPX3V3VI.js.map +0 -1
|
@@ -1,13 +1,13 @@
|
|
|
1
|
-
import { t as e } from "./PkChatbotMessages-
|
|
1
|
+
import { t as e } from "./PkChatbotMessages-DIeAiZ7I.js";
|
|
2
2
|
import { o as t } from "./Media-D-UGzdcW.js";
|
|
3
|
-
import { a as n, n as r, t as i } from "./useChatbotStore-
|
|
3
|
+
import { a as n, n as r, t as i } from "./useChatbotStore-8tG3oA_R.js";
|
|
4
4
|
import { n as a } from "./src-BZRiAJsH.js";
|
|
5
|
-
import { c as o, h as s, n as c } from "./utils-
|
|
5
|
+
import { c as o, h as s, n as c } from "./utils-_H2BDYuj.js";
|
|
6
6
|
import { t as l } from "./useLocalizedString-PfaKjIQY.js";
|
|
7
7
|
import { t as u } from "./PkAvatar-BTqu8tn9.js";
|
|
8
|
-
import { n as d, t as f } from "./PkChatbotInput-
|
|
8
|
+
import { n as d, t as f } from "./PkChatbotInput-Bt02PGbZ.js";
|
|
9
9
|
import { t as p } from "./PkChatbotQueuedMessages-DlydYgwC.js";
|
|
10
|
-
import { t as m } from "./PkChatbotEmptyState-
|
|
10
|
+
import { t as m } from "./PkChatbotEmptyState-CaNM6c77.js";
|
|
11
11
|
import { t as h } from "./PkChatbotWakeupBar-Cjgarxnw.js";
|
|
12
12
|
import { VvIcon as g } from "@volverjs/ui-vue/components";
|
|
13
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 O, onMounted as ie, onScopeDispose as ae, onUnmounted as oe, openBlock as k, provide as se, ref as A, renderList as ce, shallowRef as le, toDisplayString as j, toValue as ue, unref as M, useTemplateRef as de, watch as N, withCtx as P } from "vue";
|
|
@@ -160,14 +160,14 @@ var ge = {
|
|
|
160
160
|
key: 0,
|
|
161
161
|
class: "pk-voice-session__badge",
|
|
162
162
|
"aria-hidden": "true"
|
|
163
|
-
},
|
|
163
|
+
}, Se = {
|
|
164
164
|
class: "pk-voice-session__status",
|
|
165
165
|
role: "status"
|
|
166
|
-
},
|
|
166
|
+
}, z = {
|
|
167
167
|
key: 0,
|
|
168
168
|
class: "pk-voice-session__live-dot",
|
|
169
169
|
"aria-hidden": "true"
|
|
170
|
-
},
|
|
170
|
+
}, Ce = ["title"], we = ["title"], Te = { class: "pk-voice-session__actions" }, Ee = /* @__PURE__ */ E({
|
|
171
171
|
__name: "PkVoiceSession",
|
|
172
172
|
props: {
|
|
173
173
|
state: {},
|
|
@@ -206,18 +206,18 @@ var ge = {
|
|
|
206
206
|
"sample",
|
|
207
207
|
"spectrum"
|
|
208
208
|
])),
|
|
209
|
-
C("div",
|
|
209
|
+
C("div", Se, [C("span", { class: D(["pk-voice-session__state", l.value && `pk-voice-session__state--${l.value}`]) }, [c.value ? (k(), S("span", z)) : x("", !0), te(" " + j(a.value), 1)], 2), e.error ? (k(), S("p", {
|
|
210
210
|
key: 0,
|
|
211
211
|
class: "pk-voice-session__detail",
|
|
212
212
|
title: e.rawError ?? e.error
|
|
213
|
-
}, j(e.error), 9,
|
|
213
|
+
}, j(e.error), 9, Ce)) : x("", !0)]),
|
|
214
214
|
o.value ? (k(), S("span", {
|
|
215
215
|
key: 2,
|
|
216
216
|
class: D(["pk-voice-session__timer", { "pk-voice-session__timer--warning": s.value }]),
|
|
217
217
|
title: M(i)("hint.voiceRemaining"),
|
|
218
218
|
"aria-hidden": "true"
|
|
219
|
-
}, j(o.value), 11,
|
|
220
|
-
C("div",
|
|
219
|
+
}, j(o.value), 11, we)) : x("", !0),
|
|
220
|
+
C("div", Te, [e.error ? (k(), S(_, { key: 0 }, [w(d, {
|
|
221
221
|
icon: "ri:refresh-line",
|
|
222
222
|
label: M(i)("action.retry"),
|
|
223
223
|
onClick: n[0] ||= (e) => r("retry")
|
|
@@ -254,7 +254,7 @@ var ge = {
|
|
|
254
254
|
], 2);
|
|
255
255
|
};
|
|
256
256
|
}
|
|
257
|
-
}),
|
|
257
|
+
}), De = (e) => {
|
|
258
258
|
let t = le(), n = A("disconnected"), r = A("listening"), i = A(), o = A([]), s = A(), c = A(), l, u, d = 0, f = !1, p = () => {
|
|
259
259
|
u &&= (clearInterval(u), void 0), s.value = void 0;
|
|
260
260
|
}, m = (e) => {
|
|
@@ -378,12 +378,12 @@ var ge = {
|
|
|
378
378
|
readLevel: S,
|
|
379
379
|
readSpectrum: C
|
|
380
380
|
};
|
|
381
|
-
},
|
|
381
|
+
}, Oe = 4e3, ke = [
|
|
382
382
|
3e3,
|
|
383
383
|
5e3,
|
|
384
384
|
1e4
|
|
385
|
-
],
|
|
386
|
-
function
|
|
385
|
+
], Ae = 12e4, je = 3e4;
|
|
386
|
+
function Me(e) {
|
|
387
387
|
let t = A(null), n = A(!1), r, i = !1, a = () => {
|
|
388
388
|
clearTimeout(r), r = void 0;
|
|
389
389
|
}, o = (e, t) => {
|
|
@@ -401,12 +401,12 @@ function je(e) {
|
|
|
401
401
|
}
|
|
402
402
|
let r = t.value;
|
|
403
403
|
if (r) {
|
|
404
|
-
let e = Date.parse(r.dueAt) - Date.now() +
|
|
405
|
-
o(Math.max(
|
|
404
|
+
let e = Date.parse(r.dueAt) - Date.now() + Oe;
|
|
405
|
+
o(Math.max(Oe, 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 >=
|
|
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)));
|
|
410
410
|
}
|
|
411
411
|
async function u() {
|
|
412
412
|
n.value = !0;
|
|
@@ -420,15 +420,23 @@ function je(e) {
|
|
|
420
420
|
function d() {
|
|
421
421
|
a(), t.value = null;
|
|
422
422
|
}
|
|
423
|
-
let f;
|
|
424
|
-
|
|
423
|
+
let f = y(() => e.messages().some((e) => e.role === "user"));
|
|
424
|
+
N([e.chatId, f], ([, t]) => {
|
|
425
|
+
d();
|
|
426
|
+
let n = e.status();
|
|
427
|
+
t && n !== "submitted" && n !== "streaming" && c();
|
|
428
|
+
}, { immediate: !0 }), N(e.status, (e, t) => {
|
|
429
|
+
e === "ready" && t !== "ready" && f.value && c();
|
|
430
|
+
});
|
|
431
|
+
let p;
|
|
432
|
+
function m() {
|
|
425
433
|
t.value && document.visibilityState === "visible" && e.apiClient().markChatWakeupPresence(e.agentId(), e.chatId()).catch(() => void 0);
|
|
426
434
|
}
|
|
427
|
-
let
|
|
428
|
-
return document.addEventListener("visibilitychange",
|
|
429
|
-
clearInterval(
|
|
435
|
+
let h = () => m();
|
|
436
|
+
return document.addEventListener("visibilitychange", h), N(() => t.value?.wakeId, (e) => {
|
|
437
|
+
clearInterval(p), p = void 0, e && !i && (m(), p = setInterval(m, je));
|
|
430
438
|
}), O(() => {
|
|
431
|
-
i = !0, a(), clearInterval(
|
|
439
|
+
i = !0, a(), clearInterval(p), document.removeEventListener("visibilitychange", h);
|
|
432
440
|
}), {
|
|
433
441
|
pendingWakeup: t,
|
|
434
442
|
isStopping: n,
|
|
@@ -439,16 +447,16 @@ function je(e) {
|
|
|
439
447
|
}
|
|
440
448
|
//#endregion
|
|
441
449
|
//#region ../../packages/components/src/chat/PkChatbotViewChat.vue?vue&type=script&setup=true&lang.ts
|
|
442
|
-
var
|
|
450
|
+
var Ne = { class: "pk-chatbot-view-chat__input-stage" }, Pe = {
|
|
443
451
|
key: 1,
|
|
444
452
|
class: "p-md border-t border-surface-3 text-center text-12 text-danger bg-surface-danger"
|
|
445
|
-
},
|
|
453
|
+
}, Fe = { class: "pk-chatbot-view-chat__agent-chip" }, Ie = {
|
|
446
454
|
key: 0,
|
|
447
455
|
class: "pk-chatbot-view-chat__agent-chip-name"
|
|
448
|
-
},
|
|
456
|
+
}, Le = {
|
|
449
457
|
key: 0,
|
|
450
458
|
class: "pk-chatbot-view-chat__drop-overlay"
|
|
451
|
-
},
|
|
459
|
+
}, Re = 3e3, ze = 6e4, Be = 3e5, Ve = 6e5, He = /* @__PURE__ */ E({
|
|
452
460
|
__name: "PkChatbotViewChat",
|
|
453
461
|
props: {
|
|
454
462
|
agentId: {},
|
|
@@ -457,121 +465,121 @@ var Me = { class: "pk-chatbot-view-chat__input-stage" }, Ne = {
|
|
|
457
465
|
},
|
|
458
466
|
emits: ["show-info", "revise"],
|
|
459
467
|
setup(a, { emit: d }) {
|
|
460
|
-
let _ = T(() => import("./PkToolShowForm-
|
|
461
|
-
se(c,
|
|
462
|
-
let
|
|
463
|
-
let e =
|
|
464
|
-
if (e) return e.reason === "per-chat" ?
|
|
465
|
-
}),
|
|
468
|
+
let _ = T(() => import("./PkToolShowForm-LR8mW4SY.js").then((e) => e.n)), te = T(() => import("./PkToolShowContactForm-DKkapC2s.js").then((e) => e.n)), E = T(() => import("./PkToolShowSuggestedReply-Dw-yePEO.js").then((e) => e.n)), re = T(() => import("./PkToolShowSources-DeplEks2.js").then((e) => e.n)), ie = T(() => import("./PkToolRequestGeolocation-jkEuN6_1.js")), ae = T(() => import("./PkToolRequestOAuthConnection-BTNd8Urz.js")), oe = T(() => import("./PkToolShowLocation-BipZrvw7.js").then((e) => e.n)), ce = T(() => import("./PkToolShowDiagram-BI-fI2vG.js")), le = T(() => import("./PkToolEditedFile-DsiNIHAR.js")), ue = T(() => import("./PkToolShareDocument-C8sPmh0k.js").then((e) => e.n)), F = a, ge = d, I = r(F.agentId), { agentInterface: L, agentFileUpload: _e, agentType: R, agentVoice: ye, actions: be, revisedAnswers: xe, messages: Se, chat: z, messageFeedbacks: Ce, feedbackDialogMessage: we, isFeedbackSubmitting: Te, isFeedbackSubmitted: Oe, feedbackSubmitError: ke, isLeadSubmitted: Ae, isLoadingSubmitLead: je, submitLeadError: He, input: Ue, inputMessagePlaceholder: We, isConversationBlocked: Ge, baseUrl: Ke, pendingAttachments: qe, isAttachmentLimitReached: Je, fileLimitError: Ye, apiClient: B, isDark: Xe, hostToolsPending: Ze, pageNoticeLevel: Qe, hostConfirmation: $e, agentPageAccess: et, hostStepTitles: tt, canQueue: nt, queuedMessages: rt, backgroundAnswers: it } = me(I);
|
|
469
|
+
se(c, tt);
|
|
470
|
+
let V = y(() => R.value === "reasoning" ? void 0 : _e.value), at = (e) => B.value.getMediaDownloadUrl(F.agentId, I.localChatId, e), { handleSubmit: ot, stopGeneration: st, regenerate: ct, onUpvote: lt, onDownvote: ut, onFeedback: dt, onFeedbackSubmit: ft, onLeadSubmit: pt, startNewChat: mt, addToolOutput: H, addToolApprovalResponse: ht, handleFileSelect: gt, clearFileLimitError: _t, refreshMessages: vt, appendMessage: yt, closePageNotice: bt, respondHostConfirmation: xt, editQueuedMessage: St, removeQueuedMessage: Ct, openBackgroundAnswer: wt, dismissBackgroundAnswer: Tt } = I, { t: U } = fe({ useScope: "global" }), Et = y(() => Ze.value > 0), Dt = y(() => Et.value && z.value.status === "ready" ? "streaming" : z.value.status), Ot = l(() => et.value?.notice), kt = y(() => Qe.value ? Ot.value || U(`message.pageAccessNotice.${Qe.value}`) : void 0), At = y(() => {
|
|
471
|
+
let e = Ye.value;
|
|
472
|
+
if (e) return e.reason === "per-chat" ? U("message.fileLimitPerChat", { max: e.max }) : U("message.fileLimitPerMessage", { max: e.max });
|
|
473
|
+
}), jt = y(() => it.value.map(({ chatId: e, title: t }) => ({
|
|
466
474
|
id: e,
|
|
467
|
-
text: t ?
|
|
468
|
-
}))),
|
|
469
|
-
let t = await
|
|
475
|
+
text: t ? U("message.backgroundAnswerReady", { title: t }) : U("message.backgroundAnswerReadyUntitled")
|
|
476
|
+
}))), Mt = l(() => L.value?.dismissableNotice), Nt = y(() => Se.value.some((e) => e.role === "user")), Pt = y(() => F.modifier === "fullscreen" && !Nt.value), Ft = he(L, () => F.userName), It = de("chatViewEl"), Lt = async (e) => (await B.value.expandSourceContext(F.agentId, e.documentId, e.chunkIndex)).content, Rt = async (e) => {
|
|
477
|
+
let t = await B.value.downloadSourceDocument(F.agentId, e);
|
|
470
478
|
window.open(t.downloadUrl, "_blank");
|
|
471
|
-
}, { isOverDropZone:
|
|
472
|
-
dataTypes: (e) => t(e,
|
|
479
|
+
}, { isOverDropZone: zt } = pe(It, {
|
|
480
|
+
dataTypes: (e) => t(e, V.value?.allowedMimeTypes ?? []),
|
|
473
481
|
onDrop: (e) => {
|
|
474
|
-
if (
|
|
482
|
+
if (V.value?.enabled && e) for (let t of e) gt(t);
|
|
475
483
|
}
|
|
476
|
-
}),
|
|
484
|
+
}), W = A(!1), G = !1, K = A(!1), Bt = [
|
|
477
485
|
3e3,
|
|
478
486
|
5e3,
|
|
479
487
|
1e4
|
|
480
|
-
], J, Y
|
|
488
|
+
], q, J, Y = !1, X = 0, Vt = !1;
|
|
481
489
|
function Ht() {
|
|
482
|
-
clearTimeout(
|
|
490
|
+
clearTimeout(q), q = void 0, J = void 0, Y = !1, X = 0, K.value = !1;
|
|
483
491
|
}
|
|
484
492
|
function Ut(e) {
|
|
485
|
-
|
|
493
|
+
G || (clearTimeout(q), q = setTimeout(() => {
|
|
486
494
|
Wt();
|
|
487
495
|
}, e));
|
|
488
496
|
}
|
|
489
497
|
async function Wt() {
|
|
490
|
-
if (
|
|
498
|
+
if (G || Vt) return;
|
|
491
499
|
Vt = !0;
|
|
492
500
|
let e;
|
|
493
501
|
try {
|
|
494
|
-
e = await
|
|
502
|
+
e = await vt();
|
|
495
503
|
} finally {
|
|
496
504
|
Vt = !1;
|
|
497
505
|
}
|
|
498
|
-
if (
|
|
499
|
-
if (e === "caught-up" && (
|
|
500
|
-
|
|
506
|
+
if (G) return;
|
|
507
|
+
if (e === "caught-up" && (K.value = !1), Z.isActive.value) {
|
|
508
|
+
J = void 0, Y = !1, X = 0, Ut(Re);
|
|
501
509
|
return;
|
|
502
510
|
}
|
|
503
|
-
|
|
504
|
-
let t = Date.now() -
|
|
505
|
-
if (e === "caught-up" && t >= (
|
|
511
|
+
J === void 0 && (J = Date.now(), Y = !!Z.error.value);
|
|
512
|
+
let t = Date.now() - J;
|
|
513
|
+
if (e === "caught-up" && t >= (Y ? Be : ze) || t >= Ve) {
|
|
506
514
|
Ht();
|
|
507
515
|
return;
|
|
508
516
|
}
|
|
509
|
-
let n =
|
|
510
|
-
|
|
517
|
+
let n = Bt[Math.min(X, Bt.length - 1)];
|
|
518
|
+
X += 1, Ut(n);
|
|
511
519
|
}
|
|
512
520
|
let Gt = (e = 1200) => {
|
|
513
521
|
Ut(e);
|
|
514
|
-
}, Z =
|
|
522
|
+
}, Z = De({
|
|
515
523
|
fetchGrant: async () => {
|
|
516
|
-
let e = await
|
|
524
|
+
let e = await B.value.createVoiceSession(F.agentId, I.localChatId, {
|
|
517
525
|
deviceContext: I.buildDeviceContext(),
|
|
518
526
|
externalContext: I.externalContext
|
|
519
527
|
});
|
|
520
528
|
return e.chatId !== I.localChatId && (I.localChatId = e.chatId), e;
|
|
521
529
|
},
|
|
522
|
-
closeGrant: (e) =>
|
|
530
|
+
closeGrant: (e) => B.value.closeVoiceSession(F.agentId, e),
|
|
523
531
|
onTranscript: (e) => {
|
|
524
|
-
e.role === "user" ? (
|
|
532
|
+
e.role === "user" ? (K.value = !0, yt({
|
|
525
533
|
id: `${i}user-${n()}`,
|
|
526
534
|
role: "user",
|
|
527
535
|
parts: [{
|
|
528
536
|
type: "text",
|
|
529
537
|
text: e.text
|
|
530
538
|
}]
|
|
531
|
-
})) :
|
|
539
|
+
})) : K.value = !1;
|
|
532
540
|
},
|
|
533
541
|
onTurnEnd: () => {
|
|
534
542
|
Gt();
|
|
535
543
|
}
|
|
536
544
|
});
|
|
537
545
|
N(() => Z.error.value, (e) => {
|
|
538
|
-
e && (
|
|
546
|
+
e && (K.value = !1);
|
|
539
547
|
});
|
|
540
548
|
let Kt = y(() => ye.value?.enabled === !0), qt = y(() => Z.error.value ? "error" : Z.isConnecting.value ? "connecting" : Z.isSpeaking.value ? "speaking" : Z.isActive.value ? "listening" : "idle"), Jt = y(() => {
|
|
541
549
|
let e = Z.error.value;
|
|
542
|
-
if (e) return /took too long/i.test(e) ?
|
|
550
|
+
if (e) return /took too long/i.test(e) ? U("message.voiceTookTooLong") : /cascade|no response|custom_llm_error/i.test(e) ? U("message.voiceNoAnswer") : U("message.voiceInterrupted");
|
|
543
551
|
}), Yt = y(() => Z.isSpeaking.value ? "output" : "input"), Xt = () => Z.readLevel(Yt.value), Zt = () => Z.readSpectrum(Yt.value), Qt = async () => {
|
|
544
|
-
|
|
552
|
+
W.value = !1, await Z.start(), Z.isActive.value && (Ht(), Ut(Re));
|
|
545
553
|
}, $t = async () => {
|
|
546
|
-
|
|
554
|
+
K.value = !1, await Z.stop(), !G && Gt(0);
|
|
547
555
|
}, en = () => {
|
|
548
556
|
Z.dismissError();
|
|
549
557
|
}, tn = async () => {
|
|
550
558
|
Z.dismissError(), await Z.stop(), await Qt();
|
|
551
559
|
}, Q = (e) => e?.toolCallId ?? "", nn = A(/* @__PURE__ */ new Set()), rn = (e) => nn.value.has(Q(e)), an = A(/* @__PURE__ */ new Map()), $ = (e, t) => Z.isActive.value ? (Z.sendUserMessage(t) && (nn.value = new Set(nn.value).add(Q(e)), Gt()), !0) : !1, on = (e, t, n) => {
|
|
552
|
-
$(t, o(t, n)) ||
|
|
560
|
+
$(t, o(t, n)) || H({
|
|
553
561
|
tool: e,
|
|
554
562
|
toolCallId: Q(t),
|
|
555
563
|
output: n
|
|
556
564
|
});
|
|
557
565
|
}, sn = (e) => {
|
|
558
|
-
let t = e.confirmed ?
|
|
559
|
-
$({ toolCallId: e.toolCallId }, t) ? nn.value.has(e.toolCallId) && (an.value = new Map(an.value).set(e.toolCallId, e.confirmed)) :
|
|
566
|
+
let t = e.confirmed ? U("message.voiceConfirmed") : U("message.voiceCancelled");
|
|
567
|
+
$({ toolCallId: e.toolCallId }, t) ? nn.value.has(e.toolCallId) && (an.value = new Map(an.value).set(e.toolCallId, e.confirmed)) : H({
|
|
560
568
|
tool: "requestConfirm",
|
|
561
569
|
toolCallId: e.toolCallId,
|
|
562
570
|
output: e.confirmed ? "confirmed" : "cancelled"
|
|
563
571
|
});
|
|
564
572
|
}, cn = (e, t) => {
|
|
565
|
-
$(e, t) || (
|
|
573
|
+
$(e, t) || (Ue.value = t, ot());
|
|
566
574
|
}, ln = (e, t) => {
|
|
567
|
-
let n = t.error ?
|
|
568
|
-
$(e, n) ||
|
|
575
|
+
let n = t.error ? U("message.voiceLocationRefused") : U("message.voiceLocationShared", { place: t.displayName ?? `${t.latitude}, ${t.longitude}` });
|
|
576
|
+
$(e, n) || H({
|
|
569
577
|
tool: "requestGeolocation",
|
|
570
578
|
toolCallId: Q(e),
|
|
571
579
|
output: t
|
|
572
580
|
});
|
|
573
581
|
}, un = (e, t) => {
|
|
574
|
-
$(e,
|
|
582
|
+
$(e, U("message.voiceConnectionDone")) || H({
|
|
575
583
|
tool: "requestOAuthConnection",
|
|
576
584
|
toolCallId: Q(e),
|
|
577
585
|
output: {
|
|
@@ -580,39 +588,36 @@ var Me = { class: "pk-chatbot-view-chat__input-stage" }, Ne = {
|
|
|
580
588
|
}
|
|
581
589
|
});
|
|
582
590
|
}, dn = () => {
|
|
583
|
-
|
|
591
|
+
W.value = !W.value, Z.setMuted(W.value);
|
|
584
592
|
};
|
|
585
593
|
O(() => {
|
|
586
|
-
|
|
594
|
+
G = !0, Ht();
|
|
587
595
|
});
|
|
588
|
-
let { pendingWakeup: fn, isStopping: pn,
|
|
596
|
+
let { pendingWakeup: fn, isStopping: pn, stop: mn } = Me({
|
|
589
597
|
agentId: () => F.agentId,
|
|
590
598
|
chatId: () => I.localChatId,
|
|
591
|
-
apiClient: () =>
|
|
592
|
-
messages: () =>
|
|
593
|
-
refreshMessages:
|
|
599
|
+
apiClient: () => B.value,
|
|
600
|
+
messages: () => Se.value,
|
|
601
|
+
refreshMessages: vt,
|
|
602
|
+
status: () => z.value.status
|
|
594
603
|
});
|
|
595
|
-
return
|
|
596
|
-
hn(), e && mn();
|
|
597
|
-
}, { immediate: !0 }), N(() => B.value.status, (e, t) => {
|
|
598
|
-
e === "ready" && t !== "ready" && Mt.value && mn();
|
|
599
|
-
}), (t, n) => {
|
|
604
|
+
return (t, n) => {
|
|
600
605
|
let r = g;
|
|
601
606
|
return k(), S("div", {
|
|
602
607
|
ref_key: "chatViewEl",
|
|
603
|
-
ref:
|
|
608
|
+
ref: It,
|
|
604
609
|
class: D(["pk-chatbot-view-chat", {
|
|
605
|
-
"pk-chatbot-view-chat--dragover": M(
|
|
606
|
-
"pk-chatbot-view-chat--empty":
|
|
610
|
+
"pk-chatbot-view-chat--dragover": M(zt) && V.value?.enabled,
|
|
611
|
+
"pk-chatbot-view-chat--empty": Pt.value
|
|
607
612
|
}])
|
|
608
613
|
}, [
|
|
609
614
|
w(v, {
|
|
610
615
|
name: "pk-chatbot-view-chat-fade",
|
|
611
616
|
mode: "out-in"
|
|
612
617
|
}, {
|
|
613
|
-
default: P(() => [
|
|
618
|
+
default: P(() => [Pt.value ? (k(), b(m, {
|
|
614
619
|
key: 0,
|
|
615
|
-
greeting: M(
|
|
620
|
+
greeting: M(Ft),
|
|
616
621
|
logo: M(L)?.logo,
|
|
617
622
|
name: M(I).name
|
|
618
623
|
}, null, 8, [
|
|
@@ -623,47 +628,47 @@ var Me = { class: "pk-chatbot-view-chat__input-stage" }, Ne = {
|
|
|
623
628
|
key: 1,
|
|
624
629
|
class: "flex flex-col flex-1 min-h-0 p-md overflow-y-auto",
|
|
625
630
|
interactive: "",
|
|
626
|
-
messages: M(
|
|
631
|
+
messages: M(Se),
|
|
627
632
|
"confirm-verdicts-on-call": an.value,
|
|
628
|
-
status: M(
|
|
629
|
-
error: M(
|
|
633
|
+
status: M(z).status,
|
|
634
|
+
error: M(z).error,
|
|
630
635
|
"main-color": M(L)?.mainColor,
|
|
631
636
|
"text-color": M(L)?.textColor,
|
|
632
637
|
"revised-answers": M(xe),
|
|
633
638
|
actions: M(be),
|
|
634
|
-
"message-feedbacks": M(
|
|
635
|
-
"feedback-message-id": M(
|
|
636
|
-
"feedback-loading": M(
|
|
637
|
-
"feedback-submitted": M(
|
|
638
|
-
"feedback-error": M(
|
|
639
|
+
"message-feedbacks": M(Ce),
|
|
640
|
+
"feedback-message-id": M(we)?.id,
|
|
641
|
+
"feedback-loading": M(Te),
|
|
642
|
+
"feedback-submitted": M(Oe),
|
|
643
|
+
"feedback-error": M(ke),
|
|
639
644
|
"show-extended-steps": M(L)?.showExtendedSteps,
|
|
640
|
-
"awaiting-spoken-answer":
|
|
641
|
-
"host-working":
|
|
642
|
-
"host-confirmation": M(
|
|
643
|
-
"is-dark": M(
|
|
645
|
+
"awaiting-spoken-answer": K.value,
|
|
646
|
+
"host-working": Et.value,
|
|
647
|
+
"host-confirmation": M($e),
|
|
648
|
+
"is-dark": M(Xe),
|
|
644
649
|
"show-scroll-to-bottom": a.modifier === "fullscreen",
|
|
645
|
-
onFeedbackSubmit: n[0] ||= (e) => M(
|
|
646
|
-
onFeedbackClose: n[1] ||= (e) =>
|
|
647
|
-
onRegenerate: M(
|
|
648
|
-
onAutoRetry: M(
|
|
649
|
-
onResetChat: M(
|
|
650
|
+
onFeedbackSubmit: n[0] ||= (e) => M(ft)(e),
|
|
651
|
+
onFeedbackClose: n[1] ||= (e) => we.value = void 0,
|
|
652
|
+
onRegenerate: M(ct),
|
|
653
|
+
onAutoRetry: M(ct),
|
|
654
|
+
onResetChat: M(mt),
|
|
650
655
|
onShowInfo: n[2] ||= (e) => ge("show-info", e),
|
|
651
656
|
onRevise: n[3] ||= (e) => ge("revise", e),
|
|
652
|
-
onUpvote: M(
|
|
653
|
-
onDownvote: M(
|
|
654
|
-
onFeedback: M(
|
|
655
|
-
onApprovalRespond: M(
|
|
657
|
+
onUpvote: M(lt),
|
|
658
|
+
onDownvote: M(ut),
|
|
659
|
+
onFeedback: M(dt),
|
|
660
|
+
onApprovalRespond: M(ht),
|
|
656
661
|
onConfirmRespond: sn,
|
|
657
|
-
onHostConfirmRespond: M(
|
|
662
|
+
onHostConfirmRespond: M(xt)
|
|
658
663
|
}, {
|
|
659
664
|
"tool-showContactForm": P(({ part: e }) => [w(M(te), {
|
|
660
665
|
part: e,
|
|
661
|
-
readonly: !M(
|
|
662
|
-
submitted: M(
|
|
663
|
-
loading: M(
|
|
664
|
-
error: M(
|
|
666
|
+
readonly: !M(Ke),
|
|
667
|
+
submitted: M(Ae),
|
|
668
|
+
loading: M(je),
|
|
669
|
+
error: M(He),
|
|
665
670
|
"privacy-policy-notice": M(L)?.privacyPolicyNotice,
|
|
666
|
-
onSubmit: M(
|
|
671
|
+
onSubmit: M(pt)
|
|
667
672
|
}, null, 8, [
|
|
668
673
|
"part",
|
|
669
674
|
"readonly",
|
|
@@ -679,8 +684,8 @@ var Me = { class: "pk-chatbot-view-chat__input-stage" }, Ne = {
|
|
|
679
684
|
}, null, 8, ["part", "onSelect"])]),
|
|
680
685
|
"tool-showSources": P(({ part: e }) => [w(M(re), {
|
|
681
686
|
part: e,
|
|
682
|
-
"on-expand-context":
|
|
683
|
-
"on-download":
|
|
687
|
+
"on-expand-context": Lt,
|
|
688
|
+
"on-download": Rt
|
|
684
689
|
}, null, 8, ["part"])]),
|
|
685
690
|
"tool-showForm": P(({ part: e }) => [w(v, { mode: "out-in" }, {
|
|
686
691
|
default: P(() => [w(M(_), {
|
|
@@ -709,9 +714,9 @@ var Me = { class: "pk-chatbot-view-chat__input-stage" }, Ne = {
|
|
|
709
714
|
}, 1024)]),
|
|
710
715
|
"tool-requestOAuthConnection": P(({ part: e }) => [w(M(ae), {
|
|
711
716
|
part: e,
|
|
712
|
-
"backend-url": M(
|
|
713
|
-
"resolve-connection": (e) => M(
|
|
714
|
-
"check-connection": (e) => M(
|
|
717
|
+
"backend-url": M(Ke),
|
|
718
|
+
"resolve-connection": (e) => M(B).getOAuthAuthorizeUrl(F.agentId, e),
|
|
719
|
+
"check-connection": (e) => M(B).getOAuthConnectionStatus(F.agentId, e),
|
|
715
720
|
onConnected: (t) => un(e, t)
|
|
716
721
|
}, null, 8, [
|
|
717
722
|
"part",
|
|
@@ -723,7 +728,7 @@ var Me = { class: "pk-chatbot-view-chat__input-stage" }, Ne = {
|
|
|
723
728
|
"tool-requestGeolocation": P(({ part: e }) => [w(M(ie), {
|
|
724
729
|
part: e,
|
|
725
730
|
"call-live": M(Z).isActive.value,
|
|
726
|
-
"reverse-geocode": (e, t) => M(
|
|
731
|
+
"reverse-geocode": (e, t) => M(B).reverseGeocode(e, t),
|
|
727
732
|
onResult: (t) => ln(e, t)
|
|
728
733
|
}, null, 8, [
|
|
729
734
|
"part",
|
|
@@ -733,9 +738,9 @@ var Me = { class: "pk-chatbot-view-chat__input-stage" }, Ne = {
|
|
|
733
738
|
])]),
|
|
734
739
|
"tool-showLocation": P(({ part: e }) => [w(M(oe), {
|
|
735
740
|
part: e,
|
|
736
|
-
"is-dark": M(
|
|
741
|
+
"is-dark": M(Xe),
|
|
737
742
|
"main-color": M(L)?.mainColor,
|
|
738
|
-
"forward-geocode": (e, t) => M(
|
|
743
|
+
"forward-geocode": (e, t) => M(B).forwardGeocode(e, t)
|
|
739
744
|
}, null, 8, [
|
|
740
745
|
"part",
|
|
741
746
|
"is-dark",
|
|
@@ -744,84 +749,89 @@ var Me = { class: "pk-chatbot-view-chat__input-stage" }, Ne = {
|
|
|
744
749
|
])]),
|
|
745
750
|
"tool-showDiagram": P(({ part: e }) => [w(M(ce), {
|
|
746
751
|
part: e,
|
|
747
|
-
"is-dark": M(
|
|
752
|
+
"is-dark": M(Xe)
|
|
748
753
|
}, null, 8, ["part", "is-dark"])]),
|
|
749
754
|
"tool-editSpreadsheet": P(({ part: e }) => [(k(), b(M(le), {
|
|
750
755
|
key: M(s)(e),
|
|
751
756
|
part: e,
|
|
752
|
-
"file-url":
|
|
757
|
+
"file-url": at
|
|
758
|
+
}, null, 8, ["part"]))]),
|
|
759
|
+
"tool-editWordDocument": P(({ part: e }) => [(k(), b(M(le), {
|
|
760
|
+
key: M(s)(e),
|
|
761
|
+
part: e,
|
|
762
|
+
"file-url": at
|
|
753
763
|
}, null, 8, ["part"]))]),
|
|
754
764
|
"tool-shareDocument": P(({ part: e }) => [(k(), b(M(ue), {
|
|
755
765
|
key: M(s)(e),
|
|
756
766
|
part: e,
|
|
757
|
-
"on-download":
|
|
767
|
+
"on-download": Rt
|
|
758
768
|
}, null, 8, ["part"]))]),
|
|
759
769
|
_: 1
|
|
760
770
|
}, 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.awaiting-spoken-answer.host-working.host-confirmation.is-dark.show-scroll-to-bottom.onRegenerate.onAutoRetry.onResetChat.onUpvote.onDownvote.onFeedback.onApprovalRespond.onHostConfirmRespond".split(".")))]),
|
|
761
771
|
_: 1
|
|
762
772
|
}),
|
|
763
|
-
M(
|
|
773
|
+
M(rt).length ? (k(), b(p, {
|
|
764
774
|
key: 0,
|
|
765
|
-
messages: M(
|
|
766
|
-
onEdit: M(
|
|
767
|
-
onRemove: M(
|
|
775
|
+
messages: M(rt),
|
|
776
|
+
onEdit: M(St),
|
|
777
|
+
onRemove: M(Ct)
|
|
768
778
|
}, null, 8, [
|
|
769
779
|
"messages",
|
|
770
780
|
"onEdit",
|
|
771
781
|
"onRemove"
|
|
772
782
|
])) : x("", !0),
|
|
773
|
-
C("div",
|
|
783
|
+
C("div", Ne, [
|
|
774
784
|
w(v, { name: "pk-chatbot-view-chat-fade" }, {
|
|
775
|
-
default: P(() => [
|
|
785
|
+
default: P(() => [Pt.value ? (k(), b(ve, {
|
|
776
786
|
key: 0,
|
|
777
787
|
class: "pk-chatbot-view-chat__aurora",
|
|
778
788
|
"source-selector": ".pk-chatbot-input__form"
|
|
779
789
|
})) : x("", !0)]),
|
|
780
790
|
_: 1
|
|
781
791
|
}),
|
|
782
|
-
M(fn) && !M(
|
|
792
|
+
M(fn) && !M(Ge) ? (k(), b(h, {
|
|
783
793
|
key: 0,
|
|
784
794
|
pending: M(fn),
|
|
785
795
|
stopping: M(pn),
|
|
786
|
-
onStop: M(
|
|
796
|
+
onStop: M(mn)
|
|
787
797
|
}, null, 8, [
|
|
788
798
|
"pending",
|
|
789
799
|
"stopping",
|
|
790
800
|
"onStop"
|
|
791
801
|
])) : x("", !0),
|
|
792
|
-
M(
|
|
802
|
+
M(Ge) ? (k(), S("div", Pe, j(M(U)("message.chatErrorConversationBlocked")), 1)) : qt.value === "idle" ? (k(), b(f, {
|
|
793
803
|
key: 3,
|
|
794
|
-
modelValue: M(
|
|
795
|
-
"onUpdate:modelValue": n[4] ||= (e) => ne(
|
|
796
|
-
"pending-attachments": M(
|
|
797
|
-
"onUpdate:pendingAttachments": n[5] ||= (e) => ne(
|
|
798
|
-
placeholder: M(
|
|
799
|
-
"dismissable-notice": M(
|
|
800
|
-
"page-notice":
|
|
801
|
-
status:
|
|
804
|
+
modelValue: M(Ue),
|
|
805
|
+
"onUpdate:modelValue": n[4] ||= (e) => ne(Ue) ? Ue.value = e : null,
|
|
806
|
+
"pending-attachments": M(qe),
|
|
807
|
+
"onUpdate:pendingAttachments": n[5] ||= (e) => ne(qe) ? qe.value = e : null,
|
|
808
|
+
placeholder: M(We),
|
|
809
|
+
"dismissable-notice": M(Mt) && M(z).messages.length <= 1 ? M(Mt) : void 0,
|
|
810
|
+
"page-notice": kt.value,
|
|
811
|
+
status: Dt.value,
|
|
802
812
|
"max-message-length": M(L)?.maxMessageLength,
|
|
803
|
-
"file-upload":
|
|
804
|
-
"attachment-limit-reached": M(
|
|
805
|
-
"attachment-notice":
|
|
813
|
+
"file-upload": V.value,
|
|
814
|
+
"attachment-limit-reached": M(Je),
|
|
815
|
+
"attachment-notice": At.value,
|
|
806
816
|
"voice-enabled": Kt.value,
|
|
807
|
-
"queue-enabled": M(
|
|
808
|
-
"answer-notices":
|
|
809
|
-
onStopGeneration: M(
|
|
810
|
-
onSubmit: M(
|
|
811
|
-
onFileSelect: M(
|
|
812
|
-
onDismissAttachmentNotice: M(
|
|
813
|
-
onDismissPageNotice: M(
|
|
814
|
-
onOpenAnswerNotice: M(
|
|
815
|
-
onDismissAnswerNotice: M(
|
|
817
|
+
"queue-enabled": M(nt),
|
|
818
|
+
"answer-notices": jt.value,
|
|
819
|
+
onStopGeneration: M(st),
|
|
820
|
+
onSubmit: M(ot),
|
|
821
|
+
onFileSelect: M(gt),
|
|
822
|
+
onDismissAttachmentNotice: M(_t),
|
|
823
|
+
onDismissPageNotice: M(bt),
|
|
824
|
+
onOpenAnswerNotice: M(wt),
|
|
825
|
+
onDismissAnswerNotice: M(Tt),
|
|
816
826
|
onVoiceStart: Qt
|
|
817
827
|
}, ee({ _: 2 }, [a.modifier === "fullscreen" ? {
|
|
818
828
|
name: "prepend",
|
|
819
|
-
fn: P(() => [C("span",
|
|
829
|
+
fn: P(() => [C("span", Fe, [w(u, {
|
|
820
830
|
modifiers: "surface",
|
|
821
831
|
class: "pk-chatbot-view-chat__agent-chip-avatar",
|
|
822
832
|
"img-src": M(L)?.logo,
|
|
823
833
|
name: M(I).name
|
|
824
|
-
}, null, 8, ["img-src", "name"]), M(I).name ? (k(), S("strong",
|
|
834
|
+
}, null, 8, ["img-src", "name"]), M(I).name ? (k(), S("strong", Ie, j(M(I).name), 1)) : x("", !0)])]),
|
|
825
835
|
key: "0"
|
|
826
836
|
} : void 0]), 1032, [
|
|
827
837
|
"modelValue",
|
|
@@ -844,13 +854,13 @@ var Me = { class: "pk-chatbot-view-chat__input-stage" }, Ne = {
|
|
|
844
854
|
"onDismissPageNotice",
|
|
845
855
|
"onOpenAnswerNotice",
|
|
846
856
|
"onDismissAnswerNotice"
|
|
847
|
-
])) : (k(), b(
|
|
857
|
+
])) : (k(), b(Ee, {
|
|
848
858
|
key: 2,
|
|
849
859
|
state: qt.value,
|
|
850
860
|
sample: Xt,
|
|
851
861
|
spectrum: Zt,
|
|
852
862
|
"remaining-seconds": M(Z).remainingSeconds.value,
|
|
853
|
-
muted:
|
|
863
|
+
muted: W.value,
|
|
854
864
|
error: Jt.value,
|
|
855
865
|
"raw-error": M(Z).error.value,
|
|
856
866
|
live: M(Z).isActive.value,
|
|
@@ -869,10 +879,10 @@ var Me = { class: "pk-chatbot-view-chat__input-stage" }, Ne = {
|
|
|
869
879
|
]))
|
|
870
880
|
]),
|
|
871
881
|
w(v, null, {
|
|
872
|
-
default: P(() => [M(
|
|
882
|
+
default: P(() => [M(zt) && V.value?.enabled ? (k(), S("div", Le, [w(r, {
|
|
873
883
|
name: "ri:upload-cloud-2-line",
|
|
874
884
|
class: "pk-chatbot-view-chat__drop-overlay-icon"
|
|
875
|
-
}), C("span", null, j(M(
|
|
885
|
+
}), C("span", null, j(M(U)("action.dropFile")), 1)])) : x("", !0)]),
|
|
876
886
|
_: 1
|
|
877
887
|
})
|
|
878
888
|
], 2);
|
|
@@ -880,6 +890,6 @@ var Me = { class: "pk-chatbot-view-chat__input-stage" }, Ne = {
|
|
|
880
890
|
}
|
|
881
891
|
});
|
|
882
892
|
//#endregion
|
|
883
|
-
export { ve as i,
|
|
893
|
+
export { ve as i, Ee as n, be as r, He as t };
|
|
884
894
|
|
|
885
|
-
//# sourceMappingURL=PkChatbotViewChat-
|
|
895
|
+
//# sourceMappingURL=PkChatbotViewChat-10NIwiUP.js.map
|