@pagelines/sdk 1.0.196 → 1.0.198
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/{AgentProvider.vue_vue_type_script_setup_true_lang-DI7Om6xQ.js → AgentProvider.vue_vue_type_script_setup_true_lang-BZ-MIv99.js} +2 -2
- package/dist/{AgentProvider.vue_vue_type_script_setup_true_lang-DI7Om6xQ.js.map → AgentProvider.vue_vue_type_script_setup_true_lang-BZ-MIv99.js.map} +1 -1
- package/dist/{AgentWidgetInline-06-ZR6qD.js → AgentWidgetInline-B5nBU6mX.js} +2 -2
- package/dist/{AgentWidgetInline-06-ZR6qD.js.map → AgentWidgetInline-B5nBU6mX.js.map} +1 -1
- package/dist/{AgentWidgetModal-Bc1Ssg-J.js → AgentWidgetModal-U1idLUgu.js} +2 -2
- package/dist/{AgentWidgetModal-Bc1Ssg-J.js.map → AgentWidgetModal-U1idLUgu.js.map} +1 -1
- package/dist/AgentWidgetPopup-XShPN4PJ.js +122 -0
- package/dist/{AgentWidgetPopup-K3S9LD_r.js.map → AgentWidgetPopup-XShPN4PJ.js.map} +1 -1
- package/dist/{AgentWrap.vue_vue_type_script_setup_true_lang-ClZyzb6C.js → AgentWrap.vue_vue_type_script_setup_true_lang-BMHuXzhh.js} +945 -923
- package/dist/AgentWrap.vue_vue_type_script_setup_true_lang-BMHuXzhh.js.map +1 -0
- package/dist/agent/ui/AgentWrap.vue.d.ts +2 -0
- package/dist/agent/ui/ElAgentAbout.vue.d.ts +1 -0
- package/dist/agent/ui/ElAgentHeader.vue.d.ts +1 -0
- package/dist/agent/ui/ElModeHeader.vue.d.ts +1 -1
- package/dist/agent.js +66 -63
- package/dist/agent.js.map +1 -1
- package/dist/demo/index.d.ts +2 -0
- package/dist/sdk.css +1 -1
- package/dist/sdkClient.d.ts +6 -0
- package/dist/widget.js +4 -4
- package/dist/widget.js.map +1 -1
- package/package.json +2 -2
- package/dist/AgentWidgetPopup-K3S9LD_r.js +0 -119
- package/dist/AgentWrap.vue_vue_type_script_setup_true_lang-ClZyzb6C.js.map +0 -1
|
@@ -1,119 +0,0 @@
|
|
|
1
|
-
var B = Object.defineProperty;
|
|
2
|
-
var s = (a, c) => B(a, "name", { value: c, configurable: !0 });
|
|
3
|
-
import { defineComponent as _, ref as n, watch as I, nextTick as M, createBlock as w, openBlock as u, withCtx as $, createElementBlock as y, createCommentVNode as h, normalizeClass as k, createElementVNode as i, normalizeStyle as O, unref as j } from "vue";
|
|
4
|
-
import { _ as E, g as N, a as V } from "./AgentWrap.vue_vue_type_script_setup_true_lang-ClZyzb6C.js";
|
|
5
|
-
const F = {
|
|
6
|
-
key: 0,
|
|
7
|
-
class: "relative h-full w-full"
|
|
8
|
-
}, P = { class: "group relative h-full w-full rounded-3xl overflow-hidden shadow-lg transition-all duration-300 ease-[cubic-bezier(0.25,1,0.33,1)] hover:shadow-2xl hover:translate-y-[-1px] hover:brightness-110 active:scale-[1.06] active:-translate-y-0.5 active:duration-100" }, S = ["src", "alt"], G = /* @__PURE__ */ _({
|
|
9
|
-
__name: "AgentWidgetPopup",
|
|
10
|
-
props: {
|
|
11
|
-
sdk: {},
|
|
12
|
-
handle: {},
|
|
13
|
-
agent: {},
|
|
14
|
-
context: {},
|
|
15
|
-
firstMessage: {},
|
|
16
|
-
buttonText: {},
|
|
17
|
-
buttonIcon: {},
|
|
18
|
-
position: {},
|
|
19
|
-
chatOnly: { type: Boolean }
|
|
20
|
-
},
|
|
21
|
-
setup(a, { expose: c }) {
|
|
22
|
-
const e = a, o = n(!1), v = n(!1), p = n(e.agent), d = n(e.context), f = n(e.firstMessage), g = n(e.buttonText), b = n(e.buttonIcon);
|
|
23
|
-
function x() {
|
|
24
|
-
o.value = !o.value;
|
|
25
|
-
}
|
|
26
|
-
s(x, "toggle"), I(o, async (t) => {
|
|
27
|
-
t ? (await M(), setTimeout(() => {
|
|
28
|
-
v.value = !0;
|
|
29
|
-
}, 400)) : v.value = !1;
|
|
30
|
-
});
|
|
31
|
-
function C() {
|
|
32
|
-
o.value = !0;
|
|
33
|
-
}
|
|
34
|
-
s(C, "open");
|
|
35
|
-
function m() {
|
|
36
|
-
o.value = !1;
|
|
37
|
-
}
|
|
38
|
-
s(m, "close");
|
|
39
|
-
function z() {
|
|
40
|
-
m();
|
|
41
|
-
}
|
|
42
|
-
s(z, "handleClose");
|
|
43
|
-
function T(t) {
|
|
44
|
-
t.agent !== void 0 && (p.value = t.agent), t.context !== void 0 && (d.value = t.context), t.firstMessage !== void 0 && (f.value = t.firstMessage), t.buttonText !== void 0 && (g.value = t.buttonText), t.buttonIcon !== void 0 && (b.value = t.buttonIcon);
|
|
45
|
-
}
|
|
46
|
-
return s(T, "update"), c({
|
|
47
|
-
toggle: x,
|
|
48
|
-
open: C,
|
|
49
|
-
close: m,
|
|
50
|
-
update: T
|
|
51
|
-
}), (t, l) => (u(), w(E, {
|
|
52
|
-
sdk: a.sdk,
|
|
53
|
-
handle: a.handle,
|
|
54
|
-
agent: p.value,
|
|
55
|
-
context: d.value,
|
|
56
|
-
"first-message": f.value,
|
|
57
|
-
"button-text": g.value,
|
|
58
|
-
"button-icon": b.value
|
|
59
|
-
}, {
|
|
60
|
-
default: $(({ agent: r, sdk: A }) => [
|
|
61
|
-
r ? (u(), y("div", {
|
|
62
|
-
key: 0,
|
|
63
|
-
class: k(["fixed z-[999999] pointer-events-auto", [
|
|
64
|
-
e.position === "bottom-left" ? "bottom-6 left-6" : e.position === "top-right" ? "top-6 right-6" : e.position === "top-left" ? "top-6 left-6" : "bottom-6 right-6"
|
|
65
|
-
]])
|
|
66
|
-
}, [
|
|
67
|
-
i("div", {
|
|
68
|
-
class: k(["transition-all duration-500 ease-[cubic-bezier(0.25,1,0.33,1)] transform-gpu", [
|
|
69
|
-
o.value ? "widget-expanded w-96 h-[600px] max-w-[calc(100vw-48px)] max-h-[calc(100vh-48px)] rounded-3xl opacity-100 scale-100" : "widget-button w-[80px] h-[80px] opacity-100 scale-100 flex items-center justify-center cursor-pointer"
|
|
70
|
-
]]),
|
|
71
|
-
style: O({
|
|
72
|
-
"transform-origin": e.position === "bottom-left" ? "bottom left" : e.position === "top-right" ? "top right" : e.position === "top-left" ? "top left" : "bottom right"
|
|
73
|
-
}),
|
|
74
|
-
onClick: l[0] || (l[0] = (U) => o.value ? void 0 : x())
|
|
75
|
-
}, [
|
|
76
|
-
o.value ? h("", !0) : (u(), y("div", F, [
|
|
77
|
-
i("div", P, [
|
|
78
|
-
i("img", {
|
|
79
|
-
src: j(N)(r),
|
|
80
|
-
alt: `${r.name} digital agent`,
|
|
81
|
-
class: "h-full w-full object-cover pointer-events-none",
|
|
82
|
-
width: "80",
|
|
83
|
-
height: "80"
|
|
84
|
-
}, null, 8, S),
|
|
85
|
-
l[1] || (l[1] = i("div", { class: "absolute inset-0 pointer-events-none bg-gradient-to-br from-transparent via-black/10 to-black/40 opacity-60 transition-opacity duration-300 group-hover:opacity-40" }, null, -1))
|
|
86
|
-
]),
|
|
87
|
-
l[2] || (l[2] = i("div", { class: "absolute top-0.5 right-0.5" }, [
|
|
88
|
-
i("div", {
|
|
89
|
-
class: "size-3 bg-green-500 rounded-full ring-2 ring-white absolute animate-ping",
|
|
90
|
-
style: { "animation-duration": "3s" }
|
|
91
|
-
}),
|
|
92
|
-
i("div", { class: "size-3 bg-green-500 rounded-full ring-2 ring-white" })
|
|
93
|
-
], -1))
|
|
94
|
-
])),
|
|
95
|
-
o.value && r ? (u(), w(V, {
|
|
96
|
-
key: 1,
|
|
97
|
-
class: "rounded-3xl shadow-2xl border border-white/10",
|
|
98
|
-
sdk: A,
|
|
99
|
-
agent: r,
|
|
100
|
-
context: d.value,
|
|
101
|
-
"first-message": f.value,
|
|
102
|
-
"button-text": g.value,
|
|
103
|
-
"button-icon": b.value,
|
|
104
|
-
"has-close": !0,
|
|
105
|
-
"is-active": v.value,
|
|
106
|
-
"chat-only": a.chatOnly,
|
|
107
|
-
onClose: z
|
|
108
|
-
}, null, 8, ["sdk", "agent", "context", "first-message", "button-text", "button-icon", "is-active", "chat-only"])) : h("", !0)
|
|
109
|
-
], 6)
|
|
110
|
-
], 2)) : h("", !0)
|
|
111
|
-
]),
|
|
112
|
-
_: 1
|
|
113
|
-
}, 8, ["sdk", "handle", "agent", "context", "first-message", "button-text", "button-icon"]));
|
|
114
|
-
}
|
|
115
|
-
});
|
|
116
|
-
export {
|
|
117
|
-
G as default
|
|
118
|
-
};
|
|
119
|
-
//# sourceMappingURL=AgentWidgetPopup-K3S9LD_r.js.map
|