@opentiny/tiny-robot 0.3.0-alpha.14 → 0.3.0-alpha.16
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/action-group/index.js +41 -44
- package/dist/bubble/index.js +1163 -1112
- package/dist/close.js +1 -1
- package/dist/container/index.js +30 -30
- package/dist/dropdown-menu/index.js +64 -151
- package/dist/feedback/index.js +52 -52
- package/dist/flow-layout-buttons/index.js +14 -17
- package/dist/history/index.js +49 -49
- package/dist/icon-button/index.js +19 -18
- package/dist/index.d.ts +911 -1152
- package/dist/index.js +77 -206
- package/dist/index2.js +530 -610
- package/dist/index3.js +297 -678
- package/dist/index4.js +622 -146
- package/dist/index5.js +2067 -227
- package/dist/index6.js +4653 -2256
- package/dist/question/index.js +35 -35
- package/dist/sender/index.js +1189 -1094
- package/dist/style.css +1 -1
- package/dist/suggestion/index.js +61 -61
- package/dist/suggestion-pills/index.js +155 -131
- package/dist/suggestion-popover/index.js +219 -250
- package/dist/tiny-robot-svgs.js +180 -679
- package/dist/utils.js +13 -8
- package/package.json +3 -10
- package/dist/attachments/index.js +0 -526
- package/dist/base-popper/index.js +0 -4
- package/dist/drag-overlay/index.js +0 -57
- package/dist/index7.js +0 -6654
- package/dist/mcp-server-picker/index.js +0 -29972
- package/dist/useSlotRefs.js +0 -36
package/dist/close.js
CHANGED
package/dist/container/index.js
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import { defineComponent as
|
|
2
|
-
import {
|
|
3
|
-
import
|
|
1
|
+
import { defineComponent as m, useCssVars as v, useModel as d, computed as _, createElementBlock as w, openBlock as g, createElementVNode as n, renderSlot as r, createVNode as c, unref as i } from "vue";
|
|
2
|
+
import { r as h, a as $, f as C } from "../tiny-robot-svgs.js";
|
|
3
|
+
import u from "../icon-button/index.js";
|
|
4
4
|
import { _ as b } from "../_plugin-vue_export-helper.js";
|
|
5
|
-
const z = { class: "tr-container" }, B = { class: "tr-container__header" }, k = { class: "tr-container__header-operations" },
|
|
5
|
+
const z = { class: "tr-container" }, B = { class: "tr-container__header" }, k = { class: "tr-container__header-operations" }, y = { class: "tr-container__footer" }, E = /* @__PURE__ */ m({
|
|
6
6
|
__name: "index",
|
|
7
7
|
props: {
|
|
8
8
|
show: { type: Boolean, required: !0 },
|
|
@@ -11,50 +11,50 @@ const z = { class: "tr-container" }, B = { class: "tr-container__header" }, k =
|
|
|
11
11
|
fullscreenModifiers: {}
|
|
12
12
|
},
|
|
13
13
|
emits: ["update:show", "update:fullscreen"],
|
|
14
|
-
setup(
|
|
15
|
-
|
|
16
|
-
"
|
|
17
|
-
|
|
18
|
-
"
|
|
19
|
-
"
|
|
14
|
+
setup(o) {
|
|
15
|
+
v((t) => ({
|
|
16
|
+
"1daf37f2": s.value ? "0" : "unset",
|
|
17
|
+
"0679141a": s.value ? "unset" : "var(--tr-container-width)",
|
|
18
|
+
"234493b2": l.value ? "var(--tr-z-index-fixed)" : "-1",
|
|
19
|
+
"0c2ba509": l.value ? "1" : "0"
|
|
20
20
|
}));
|
|
21
|
-
const l = d(
|
|
21
|
+
const l = d(o, "show"), s = d(o, "fullscreen"), f = _(() => s.value ? h : $);
|
|
22
22
|
return (t, e) => (g(), w("div", z, [
|
|
23
|
-
e[3] || (e[3] =
|
|
24
|
-
|
|
23
|
+
e[3] || (e[3] = n("div", { class: "tr-container__dragging-bar-wrapper" }, [
|
|
24
|
+
n("div", { class: "tr-container__dragging-bar" })
|
|
25
25
|
], -1)),
|
|
26
|
-
|
|
26
|
+
n("div", B, [
|
|
27
27
|
r(t.$slots, "title", {}, () => [
|
|
28
|
-
e[2] || (e[2] =
|
|
29
|
-
]
|
|
30
|
-
|
|
31
|
-
r(t.$slots, "operations"
|
|
32
|
-
|
|
28
|
+
e[2] || (e[2] = n("h3", { class: "tr-container__title" }, "OpenTiny NEXT", -1))
|
|
29
|
+
]),
|
|
30
|
+
n("div", k, [
|
|
31
|
+
r(t.$slots, "operations"),
|
|
32
|
+
c(i(u), {
|
|
33
33
|
size: "28",
|
|
34
34
|
"svg-size": "20",
|
|
35
35
|
icon: f.value,
|
|
36
36
|
onClick: e[0] || (e[0] = (p) => t.$emit("update:fullscreen", !s.value))
|
|
37
37
|
}, null, 8, ["icon"]),
|
|
38
|
-
|
|
38
|
+
c(i(u), {
|
|
39
39
|
size: "28",
|
|
40
40
|
"svg-size": "20",
|
|
41
|
-
icon:
|
|
41
|
+
icon: i(C),
|
|
42
42
|
onClick: e[1] || (e[1] = (p) => t.$emit("update:show", !1))
|
|
43
43
|
}, null, 8, ["icon"])
|
|
44
44
|
])
|
|
45
45
|
]),
|
|
46
|
-
r(t.$slots, "default"
|
|
47
|
-
|
|
48
|
-
r(t.$slots, "footer"
|
|
46
|
+
r(t.$slots, "default"),
|
|
47
|
+
n("div", y, [
|
|
48
|
+
r(t.$slots, "footer")
|
|
49
49
|
])
|
|
50
50
|
]));
|
|
51
51
|
}
|
|
52
|
-
}),
|
|
53
|
-
|
|
54
|
-
const
|
|
55
|
-
|
|
52
|
+
}), a = /* @__PURE__ */ b(E, [["__scopeId", "data-v-6a9b9126"]]);
|
|
53
|
+
a.name = "TrContainer";
|
|
54
|
+
const I = function(o) {
|
|
55
|
+
o.component(a.name, a);
|
|
56
56
|
};
|
|
57
|
-
|
|
57
|
+
a.install = I;
|
|
58
58
|
export {
|
|
59
|
-
|
|
59
|
+
a as default
|
|
60
60
|
};
|
|
@@ -1,159 +1,72 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import {
|
|
3
|
-
import {
|
|
4
|
-
import {
|
|
5
|
-
|
|
6
|
-
const P = (o, t) => o.x >= t.left && o.x <= t.right && o.y >= t.top && o.y <= t.bottom, N = (o, t, g = !1) => {
|
|
7
|
-
if (t.length < 3) return !1;
|
|
8
|
-
const l = o.x, d = o.y;
|
|
9
|
-
let f = !1;
|
|
10
|
-
const r = (s, c, a, n, i, e) => {
|
|
11
|
-
const m = (i - a) * (c - n) - (e - n) * (s - a);
|
|
12
|
-
if (Math.abs(m) > 1e-10) return !1;
|
|
13
|
-
const u = Math.min(a, i), h = Math.max(a, i), x = Math.min(n, e), B = Math.max(n, e);
|
|
14
|
-
return s >= u && s <= h && c >= x && c <= B;
|
|
15
|
-
};
|
|
16
|
-
for (let s = 0, c = t.length - 1; s < t.length; c = s++) {
|
|
17
|
-
const a = t[s].x, n = t[s].y, i = t[c].x, e = t[c].y;
|
|
18
|
-
if (g && r(l, d, a, n, i, e))
|
|
19
|
-
return !0;
|
|
20
|
-
if (n > d && e <= d || e > d && n <= d) {
|
|
21
|
-
const u = (i - a) * (d - n) / (e - n) + a;
|
|
22
|
-
l < u && (f = !f);
|
|
23
|
-
}
|
|
24
|
-
}
|
|
25
|
-
return f;
|
|
26
|
-
}, U = (o, t) => t.bottom < o.top ? [
|
|
27
|
-
{ x: o.left, y: o.top },
|
|
28
|
-
{ x: o.right, y: o.top },
|
|
29
|
-
{ x: t.right, y: t.bottom },
|
|
30
|
-
{ x: t.left, y: t.bottom }
|
|
31
|
-
] : t.top > o.bottom ? [
|
|
32
|
-
{ x: o.left, y: o.bottom },
|
|
33
|
-
{ x: o.right, y: o.bottom },
|
|
34
|
-
{ x: t.right, y: t.top },
|
|
35
|
-
{ x: t.left, y: t.top }
|
|
36
|
-
] : [], { x: V, y: q } = F(), z = (o, t, g) => {
|
|
37
|
-
const { delayEnter: l = 0, delayLeave: d = 0 } = g || {}, f = k(!1), r = k("outside");
|
|
38
|
-
let s = null;
|
|
39
|
-
const c = () => {
|
|
40
|
-
s && (clearTimeout(s), s = null);
|
|
41
|
-
};
|
|
42
|
-
T(() => {
|
|
43
|
-
c();
|
|
44
|
-
});
|
|
45
|
-
const a = (n) => {
|
|
46
|
-
const i = n ? l : d;
|
|
47
|
-
c(), i ? s = setTimeout(() => f.value = n, i) : f.value = n;
|
|
48
|
-
};
|
|
49
|
-
return C(
|
|
50
|
-
r,
|
|
51
|
-
(n) => {
|
|
52
|
-
["trigger", "popper", "polygon"].includes(n) ? a(!0) : a(!1);
|
|
53
|
-
},
|
|
54
|
-
{ immediate: !0 }
|
|
55
|
-
), S(
|
|
56
|
-
[V, q],
|
|
57
|
-
([n, i]) => {
|
|
58
|
-
const e = M(o), m = M(t), u = e == null ? void 0 : e.getBoundingClientRect(), h = m == null ? void 0 : m.getBoundingClientRect();
|
|
59
|
-
if (u && P({ x: n, y: i }, u)) {
|
|
60
|
-
r.value = "trigger";
|
|
61
|
-
return;
|
|
62
|
-
}
|
|
63
|
-
if (h && P({ x: n, y: i }, h)) {
|
|
64
|
-
r.value = "popper";
|
|
65
|
-
return;
|
|
66
|
-
}
|
|
67
|
-
if (!u || !h || u.width === 0 || u.height === 0 || h.width === 0 || h.height === 0) {
|
|
68
|
-
r.value = "outside";
|
|
69
|
-
return;
|
|
70
|
-
}
|
|
71
|
-
N({ x: n, y: i }, U(u, h), !0) ? r.value = "polygon" : r.value = "outside";
|
|
72
|
-
},
|
|
73
|
-
{ throttle: 10 }
|
|
74
|
-
), f;
|
|
75
|
-
}, J = { class: "tr-dropdown-menu__list" }, K = ["onClick"], Q = /* @__PURE__ */ E({
|
|
1
|
+
import { defineComponent as B, useCssVars as E, unref as f, useAttrs as N, computed as _, ref as m, watch as O, createElementBlock as o, openBlock as s, Fragment as w, createElementVNode as h, createVNode as W, normalizeStyle as v, normalizeClass as z, renderSlot as I, Transition as A, withCtx as F, createCommentVNode as H, renderList as L, toDisplayString as P } from "vue";
|
|
2
|
+
import { c as g, o as U } from "../index2.js";
|
|
3
|
+
import { t as n } from "../utils.js";
|
|
4
|
+
import { _ as b } from "../_plugin-vue_export-helper.js";
|
|
5
|
+
const j = { class: "tr-dropdown-menu__list" }, q = ["onClick"], G = /* @__PURE__ */ B({
|
|
76
6
|
__name: "index",
|
|
77
|
-
props:
|
|
78
|
-
appendTo: {},
|
|
7
|
+
props: {
|
|
79
8
|
items: {},
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
},
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
const l =
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
var e;
|
|
98
|
-
return (e = s.value) == null ? void 0 : e.popperRef;
|
|
9
|
+
minWidth: { default: 160 },
|
|
10
|
+
topOffset: { default: 0 }
|
|
11
|
+
},
|
|
12
|
+
emits: ["item-click"],
|
|
13
|
+
setup(l, { emit: k }) {
|
|
14
|
+
E((e) => ({
|
|
15
|
+
d82a8430: f(n)(a.minWidth)
|
|
16
|
+
}));
|
|
17
|
+
const a = l, p = N(), y = _(() => p.style), t = m(!1), C = k, i = m(null), d = m(null), { x, y: $, update: S } = g(i), { width: D, height: T } = g(d), M = _(() => ({
|
|
18
|
+
left: `min(${n(x.value)}, 100% - ${n(D.value)})`,
|
|
19
|
+
top: `max(${n($.value)} - ${n(T.value)} + ${n(a.topOffset)} - 8px, 0px)`
|
|
20
|
+
}));
|
|
21
|
+
U(d, (e) => {
|
|
22
|
+
var u;
|
|
23
|
+
(u = i.value) != null && u.contains(e.target) && e.stopPropagation(), t.value = !1;
|
|
24
|
+
}), O(t, (e) => {
|
|
25
|
+
e && S();
|
|
99
26
|
});
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
d("click-outside", e), r.value = !1;
|
|
105
|
-
},
|
|
106
|
-
{ ignore: [c] }
|
|
107
|
-
);
|
|
108
|
-
else if (l.trigger === "hover") {
|
|
109
|
-
const e = z(c, a, { delayEnter: 100, delayLeave: 100 });
|
|
110
|
-
C(e, (m) => {
|
|
111
|
-
r.value = m;
|
|
112
|
-
});
|
|
113
|
-
}
|
|
114
|
-
const n = () => {
|
|
115
|
-
l.trigger === "click" && (r.value = !r.value);
|
|
116
|
-
}, i = (e) => {
|
|
117
|
-
r.value = !1, d("item-click", e);
|
|
27
|
+
const R = () => {
|
|
28
|
+
t.value = !t.value;
|
|
29
|
+
}, V = (e) => {
|
|
30
|
+
t.value = !1, C("item-click", e);
|
|
118
31
|
};
|
|
119
|
-
return
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
(
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
])
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
|
|
32
|
+
return (e, u) => (s(), o(w, null, [
|
|
33
|
+
h("div", {
|
|
34
|
+
class: z(["tr-dropdown-menu__wrapper", f(p).class]),
|
|
35
|
+
style: v(y.value),
|
|
36
|
+
ref_key: "dropDownTriggerRef",
|
|
37
|
+
ref: i,
|
|
38
|
+
onClick: R
|
|
39
|
+
}, [
|
|
40
|
+
I(e.$slots, "default", {}, void 0, !0)
|
|
41
|
+
], 6),
|
|
42
|
+
W(A, { name: "tr-dropdown-menu" }, {
|
|
43
|
+
default: F(() => [
|
|
44
|
+
t.value ? (s(), o("div", {
|
|
45
|
+
key: 0,
|
|
46
|
+
class: "tr-dropdown-menu",
|
|
47
|
+
style: v(M.value),
|
|
48
|
+
ref_key: "dropdownMenuRef",
|
|
49
|
+
ref: d
|
|
50
|
+
}, [
|
|
51
|
+
h("ul", j, [
|
|
52
|
+
(s(!0), o(w, null, L(a.items, (c) => (s(), o("li", {
|
|
53
|
+
class: "tr-dropdown-menu__list-item",
|
|
54
|
+
key: c.id,
|
|
55
|
+
onClick: (K) => V(c)
|
|
56
|
+
}, P(c.text), 9, q))), 128))
|
|
57
|
+
])
|
|
58
|
+
], 4)) : H("", !0)
|
|
59
|
+
]),
|
|
60
|
+
_: 1
|
|
61
|
+
})
|
|
62
|
+
], 64));
|
|
150
63
|
}
|
|
151
|
-
}),
|
|
152
|
-
|
|
153
|
-
const
|
|
154
|
-
|
|
64
|
+
}), r = /* @__PURE__ */ b(G, [["__scopeId", "data-v-620f91f9"]]);
|
|
65
|
+
r.name = "TrDropdownMenu";
|
|
66
|
+
const J = function(l) {
|
|
67
|
+
l.component(r.name, r);
|
|
155
68
|
};
|
|
156
|
-
|
|
69
|
+
r.install = J;
|
|
157
70
|
export {
|
|
158
|
-
|
|
71
|
+
r as default
|
|
159
72
|
};
|
package/dist/feedback/index.js
CHANGED
|
@@ -1,29 +1,29 @@
|
|
|
1
|
-
import { defineComponent as
|
|
2
|
-
import {
|
|
3
|
-
import { B as R } from "../
|
|
4
|
-
import $, { ActionGroupItem as
|
|
1
|
+
import { defineComponent as X, ref as E, computed as z, onMounted as D, watch as O, createElementBlock as a, openBlock as t, createCommentVNode as k, Fragment as I, renderList as S, toDisplayString as y, createVNode as b, unref as l, nextTick as q, createElementVNode as _, createBlock as p, withCtx as f, createTextVNode as j, resolveDynamicComponent as C } from "vue";
|
|
2
|
+
import { l as T, n as N, c as H, h as J, y as K, d as Q } from "../tiny-robot-svgs.js";
|
|
3
|
+
import { B as R } from "../index3.js";
|
|
4
|
+
import $, { ActionGroupItem as V } from "../action-group/index.js";
|
|
5
5
|
import U from "../icon-button/index.js";
|
|
6
|
-
import { _ as
|
|
7
|
-
const W = { class: "tr-feedback__source-list" }, Y = ["href"], Z = /* @__PURE__ */
|
|
6
|
+
import { _ as P } from "../_plugin-vue_export-helper.js";
|
|
7
|
+
const W = { class: "tr-feedback__source-list" }, Y = ["href"], Z = /* @__PURE__ */ X({
|
|
8
8
|
__name: "SourceList",
|
|
9
9
|
props: {
|
|
10
10
|
sources: {},
|
|
11
11
|
linesLimit: { default: Number.MAX_SAFE_INTEGER }
|
|
12
12
|
},
|
|
13
|
-
setup(
|
|
14
|
-
const m =
|
|
15
|
-
|
|
16
|
-
const u =
|
|
13
|
+
setup(h) {
|
|
14
|
+
const m = h, e = E(!1), g = E([]), c = E(null), L = () => {
|
|
15
|
+
q(() => {
|
|
16
|
+
const u = g.value.slice(0, m.sources.length).map((o) => (o == null ? void 0 : o.offsetTop) || 0), n = Array.from(new Set(u));
|
|
17
17
|
if (n.length > m.linesLimit) {
|
|
18
18
|
const o = n[m.linesLimit - 1], s = u.lastIndexOf(o);
|
|
19
19
|
c.value = s;
|
|
20
20
|
} else
|
|
21
21
|
c.value = null;
|
|
22
22
|
});
|
|
23
|
-
}, A =
|
|
24
|
-
|
|
25
|
-
const
|
|
26
|
-
u && (
|
|
23
|
+
}, A = z(() => m.sources.length - (c.value || 0));
|
|
24
|
+
D(L), O(() => m.sources, L);
|
|
25
|
+
const d = (u, n) => {
|
|
26
|
+
u && (g.value[n] = u);
|
|
27
27
|
};
|
|
28
28
|
return (u, n) => (t(), a("div", W, [
|
|
29
29
|
(t(!0), a(I, null, S(m.sources, (o, s) => (t(), a(I, { key: s }, [
|
|
@@ -33,27 +33,27 @@ const W = { class: "tr-feedback__source-list" }, Y = ["href"], Z = /* @__PURE__
|
|
|
33
33
|
href: o.link,
|
|
34
34
|
target: "_blank",
|
|
35
35
|
ref_for: !0,
|
|
36
|
-
ref: (r) =>
|
|
37
|
-
},
|
|
36
|
+
ref: (r) => d(r, s)
|
|
37
|
+
}, y(o.label), 9, Y)) : k("", !0),
|
|
38
38
|
c.value && !e.value && s === c.value ? (t(), a("span", {
|
|
39
39
|
key: 1,
|
|
40
40
|
class: "pill",
|
|
41
41
|
onClick: n[0] || (n[0] = (r) => e.value = !0)
|
|
42
|
-
},
|
|
42
|
+
}, y(A.value) + "+ ", 1)) : k("", !0)
|
|
43
43
|
], 64))), 128)),
|
|
44
44
|
e.value ? (t(), a("span", {
|
|
45
45
|
key: 0,
|
|
46
46
|
class: "pill collapse-pill",
|
|
47
47
|
onClick: n[1] || (n[1] = (o) => e.value = !1)
|
|
48
48
|
}, [
|
|
49
|
-
|
|
49
|
+
b(l(T))
|
|
50
50
|
])) : k("", !0)
|
|
51
51
|
]));
|
|
52
52
|
}
|
|
53
|
-
}), ee = /* @__PURE__ */
|
|
53
|
+
}), ee = /* @__PURE__ */ P(Z, [["__scopeId", "data-v-c5fbb560"]]), te = { class: "tr-feedback" }, se = { class: "tr-feedback__operations" }, oe = { class: "tr-feedback__operations-left" }, ne = { key: 1 }, le = { class: "tr-feedback__operations-right" }, ae = {
|
|
54
54
|
key: 0,
|
|
55
55
|
class: "tr-feedback__footer"
|
|
56
|
-
}, re = { key: 0 }, ie = /* @__PURE__ */
|
|
56
|
+
}, re = { key: 0 }, ie = /* @__PURE__ */ X({
|
|
57
57
|
__name: "index",
|
|
58
58
|
props: {
|
|
59
59
|
operations: {},
|
|
@@ -64,27 +64,27 @@ const W = { class: "tr-feedback__source-list" }, Y = ["href"], Z = /* @__PURE__
|
|
|
64
64
|
sourcesLinesLimit: { default: Number.MAX_SAFE_INTEGER }
|
|
65
65
|
},
|
|
66
66
|
emits: ["operation", "action"],
|
|
67
|
-
setup(
|
|
68
|
-
const e =
|
|
67
|
+
setup(h, { emit: m }) {
|
|
68
|
+
const e = h, g = {
|
|
69
69
|
copy: Q,
|
|
70
70
|
refresh: K,
|
|
71
|
-
like:
|
|
72
|
-
dislike:
|
|
71
|
+
like: J,
|
|
72
|
+
dislike: H
|
|
73
73
|
}, c = m, L = (n) => {
|
|
74
74
|
var o, s, r;
|
|
75
75
|
(r = (s = (o = e.operations) == null ? void 0 : o.find((v) => v.name === n)) == null ? void 0 : s.onClick) == null || r.call(s), c("operation", n);
|
|
76
76
|
}, A = (n) => {
|
|
77
77
|
var o, s, r;
|
|
78
78
|
(r = (s = (o = e.actions) == null ? void 0 : o.find((v) => v.name === n)) == null ? void 0 : s.onClick) == null || r.call(s), c("action", n);
|
|
79
|
-
},
|
|
80
|
-
|
|
79
|
+
}, d = E(!1), u = () => {
|
|
80
|
+
d.value = !d.value;
|
|
81
81
|
};
|
|
82
82
|
return (n, o) => {
|
|
83
83
|
var s, r, v, w, B, F, M, G;
|
|
84
84
|
return t(), a("div", te, [
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
(s = e.operations) != null && s.length ? (t(),
|
|
85
|
+
_("div", se, [
|
|
86
|
+
_("div", oe, [
|
|
87
|
+
(s = e.operations) != null && s.length ? (t(), p(l($), {
|
|
88
88
|
key: 0,
|
|
89
89
|
"max-num": e.operationsLimit,
|
|
90
90
|
"drop-down-show-label-only": !0,
|
|
@@ -92,34 +92,34 @@ const W = { class: "tr-feedback__source-list" }, Y = ["href"], Z = /* @__PURE__
|
|
|
92
92
|
class: "tr-feedback__operations-left-action-group"
|
|
93
93
|
}, {
|
|
94
94
|
moreBtn: f(() => [
|
|
95
|
-
|
|
95
|
+
b(l(R), {
|
|
96
96
|
round: "",
|
|
97
97
|
size: "mini",
|
|
98
98
|
"reset-time": 0,
|
|
99
99
|
class: "tr-feedback__operations-more-btn"
|
|
100
100
|
}, {
|
|
101
101
|
default: f(() => [
|
|
102
|
-
o[0] || (o[0] =
|
|
103
|
-
|
|
102
|
+
o[0] || (o[0] = _("span", null, "更多", -1)),
|
|
103
|
+
b(l(N))
|
|
104
104
|
]),
|
|
105
105
|
_: 1,
|
|
106
106
|
__: [0]
|
|
107
107
|
})
|
|
108
108
|
]),
|
|
109
109
|
default: f(() => [
|
|
110
|
-
(t(!0), a(I, null, S(e.operations, (i) => (t(),
|
|
110
|
+
(t(!0), a(I, null, S(e.operations, (i) => (t(), p(l(V), {
|
|
111
111
|
key: i.name,
|
|
112
112
|
name: i.name,
|
|
113
113
|
label: i.label
|
|
114
114
|
}, {
|
|
115
115
|
default: f(() => [
|
|
116
|
-
|
|
116
|
+
b(l(R), {
|
|
117
117
|
round: "",
|
|
118
118
|
"reset-time": 0,
|
|
119
119
|
size: "mini"
|
|
120
120
|
}, {
|
|
121
121
|
default: f(() => [
|
|
122
|
-
|
|
122
|
+
j(y(i.label), 1)
|
|
123
123
|
]),
|
|
124
124
|
_: 2
|
|
125
125
|
}, 1024)
|
|
@@ -129,32 +129,32 @@ const W = { class: "tr-feedback__source-list" }, Y = ["href"], Z = /* @__PURE__
|
|
|
129
129
|
]),
|
|
130
130
|
_: 1
|
|
131
131
|
}, 8, ["max-num"])) : (r = e.sources) != null && r.length ? (t(), a("div", ne, [
|
|
132
|
-
|
|
132
|
+
_("span", {
|
|
133
133
|
class: "tr-feedback__source",
|
|
134
134
|
onClick: u
|
|
135
135
|
}, [
|
|
136
|
-
|
|
137
|
-
(t(),
|
|
136
|
+
_("span", null, y((v = e.sources) == null ? void 0 : v.length) + "条来源", 1),
|
|
137
|
+
(t(), p(C(d.value ? l(T) : l(N))))
|
|
138
138
|
])
|
|
139
139
|
])) : k("", !0)
|
|
140
140
|
]),
|
|
141
|
-
|
|
142
|
-
|
|
141
|
+
_("div", le, [
|
|
142
|
+
b(l($), {
|
|
143
143
|
"max-num": e.actionsLimit,
|
|
144
144
|
"show-tooltip": !0,
|
|
145
145
|
onItemClick: A
|
|
146
146
|
}, {
|
|
147
147
|
default: f(() => [
|
|
148
|
-
(t(!0), a(I, null, S(e.actions, (i) => (t(),
|
|
148
|
+
(t(!0), a(I, null, S(e.actions, (i) => (t(), p(l(V), {
|
|
149
149
|
key: i.name,
|
|
150
150
|
name: i.name,
|
|
151
151
|
label: i.label
|
|
152
152
|
}, {
|
|
153
153
|
default: f(() => [
|
|
154
|
-
typeof i.icon == "string" ? (t(),
|
|
154
|
+
typeof i.icon == "string" ? (t(), p(l(U), {
|
|
155
155
|
key: 0,
|
|
156
|
-
icon:
|
|
157
|
-
}, null, 8, ["icon"])) : (t(),
|
|
156
|
+
icon: g[i.icon]
|
|
157
|
+
}, null, 8, ["icon"])) : (t(), p(C(i.icon), { key: 1 }))
|
|
158
158
|
]),
|
|
159
159
|
_: 2
|
|
160
160
|
}, 1032, ["name", "label"]))), 128))
|
|
@@ -163,17 +163,17 @@ const W = { class: "tr-feedback__source-list" }, Y = ["href"], Z = /* @__PURE__
|
|
|
163
163
|
}, 8, ["max-num"])
|
|
164
164
|
])
|
|
165
165
|
]),
|
|
166
|
-
(w = e.operations) != null && w.length && ((B = e.sources) != null && B.length) ||
|
|
166
|
+
(w = e.operations) != null && w.length && ((B = e.sources) != null && B.length) || d.value && e.sources ? (t(), a("div", ae, [
|
|
167
167
|
(F = e.operations) != null && F.length && ((M = e.sources) != null && M.length) ? (t(), a("div", re, [
|
|
168
|
-
|
|
168
|
+
_("span", {
|
|
169
169
|
class: "tr-feedback__source",
|
|
170
170
|
onClick: u
|
|
171
171
|
}, [
|
|
172
|
-
|
|
173
|
-
(t(),
|
|
172
|
+
_("span", null, y((G = e.sources) == null ? void 0 : G.length) + "条来源", 1),
|
|
173
|
+
(t(), p(C(d.value ? l(T) : l(N))))
|
|
174
174
|
])
|
|
175
175
|
])) : k("", !0),
|
|
176
|
-
|
|
176
|
+
d.value && e.sources ? (t(), p(l(ee), {
|
|
177
177
|
key: 1,
|
|
178
178
|
sources: e.sources,
|
|
179
179
|
"lines-limit": e.sourcesLinesLimit
|
|
@@ -182,10 +182,10 @@ const W = { class: "tr-feedback__source-list" }, Y = ["href"], Z = /* @__PURE__
|
|
|
182
182
|
]);
|
|
183
183
|
};
|
|
184
184
|
}
|
|
185
|
-
}), x = /* @__PURE__ */
|
|
185
|
+
}), x = /* @__PURE__ */ P(ie, [["__scopeId", "data-v-cc6ef316"]]);
|
|
186
186
|
x.name = "TrFeedback";
|
|
187
|
-
const ce = function(
|
|
188
|
-
|
|
187
|
+
const ce = function(h) {
|
|
188
|
+
h.component(x.name, x);
|
|
189
189
|
};
|
|
190
190
|
x.install = ce;
|
|
191
191
|
export {
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { defineComponent as q, mergeModels as E, useModel as G, watch as g, ref as i, computed as $, createElementBlock as a, openBlock as l, createElementVNode as C, Fragment as I, renderList as S, createCommentVNode as _, normalizeClass as
|
|
2
|
-
import {
|
|
3
|
-
import {
|
|
1
|
+
import { defineComponent as q, mergeModels as E, useModel as G, watch as g, ref as i, computed as $, createElementBlock as a, openBlock as l, createElementVNode as C, Fragment as I, renderList as S, createCommentVNode as _, normalizeClass as b, createBlock as x, resolveDynamicComponent as B, toDisplayString as D, nextTick as H } from "vue";
|
|
2
|
+
import { n as X } from "../tiny-robot-svgs.js";
|
|
3
|
+
import { b as j, o as J } from "../index2.js";
|
|
4
4
|
import { _ as K } from "../_plugin-vue_export-helper.js";
|
|
5
5
|
const P = ["onClick"], Q = {
|
|
6
6
|
key: 0,
|
|
@@ -54,13 +54,10 @@ const P = ["onClick"], Q = {
|
|
|
54
54
|
}, v = (t) => {
|
|
55
55
|
n.showMoreTrigger === "hover" && (c.value = t);
|
|
56
56
|
};
|
|
57
|
-
return J(
|
|
58
|
-
|
|
59
|
-
()
|
|
60
|
-
|
|
61
|
-
},
|
|
62
|
-
{ ignore: [k, w] }
|
|
63
|
-
), (t, o) => (l(), a("div", {
|
|
57
|
+
return J(k, (t) => {
|
|
58
|
+
var o, e;
|
|
59
|
+
(o = k.value) != null && o.contains(t.target) || (e = w.value) != null && e.contains(t.target) || (c.value = !1);
|
|
60
|
+
}), (t, o) => (l(), a("div", {
|
|
64
61
|
class: "tr-flow-layout",
|
|
65
62
|
ref_key: "containerRef",
|
|
66
63
|
ref: y
|
|
@@ -70,26 +67,26 @@ const P = ["onClick"], Q = {
|
|
|
70
67
|
}, [
|
|
71
68
|
s.value === null || f < s.value ? (l(), a("button", {
|
|
72
69
|
key: 0,
|
|
73
|
-
class:
|
|
70
|
+
class: b(["tr-flow-layout__item", { "icon-only": !e.label }, { selected: e.id === u.value }]),
|
|
74
71
|
ref_for: !0,
|
|
75
72
|
ref: (r) => A(r, f),
|
|
76
73
|
onClick: (r) => R(e.id)
|
|
77
74
|
}, [
|
|
78
|
-
(l(), B(
|
|
75
|
+
(l(), x(B(e.icon), { class: "tr-flow-layout__item-icon" })),
|
|
79
76
|
e.label ? (l(), a("span", Q, D(e.label), 1)) : _("", !0)
|
|
80
77
|
], 10, P)) : _("", !0)
|
|
81
78
|
], 64))), 128)),
|
|
82
79
|
C("div", U, [
|
|
83
80
|
m.value ? _("", !0) : (l(), a("button", {
|
|
84
81
|
key: 0,
|
|
85
|
-
class:
|
|
82
|
+
class: b(["tr-flow-layout__item", "icon-only", { selected: O.value }]),
|
|
86
83
|
ref_key: "moreButtonRef",
|
|
87
84
|
ref: w,
|
|
88
85
|
onClick: V,
|
|
89
86
|
onMouseenter: o[0] || (o[0] = (e) => v(!0)),
|
|
90
87
|
onMouseleave: o[1] || (o[1] = (e) => v(!1))
|
|
91
88
|
}, [
|
|
92
|
-
(l(), B(
|
|
89
|
+
(l(), x(B(n.moreIcon), { class: "tr-flow-layout__item-icon" }))
|
|
93
90
|
], 34)),
|
|
94
91
|
C("div", {
|
|
95
92
|
class: "tr-flow-layout__dropdown-container",
|
|
@@ -103,11 +100,11 @@ const P = ["onClick"], Q = {
|
|
|
103
100
|
ref: k
|
|
104
101
|
}, [
|
|
105
102
|
(l(!0), a(I, null, S(z.value, (e) => (l(), a("button", {
|
|
106
|
-
class:
|
|
103
|
+
class: b(["tr-flow-layout__dropdown_item", { selected: e.id === u.value }]),
|
|
107
104
|
key: e.id,
|
|
108
105
|
onClick: (f) => R(e.id)
|
|
109
106
|
}, [
|
|
110
|
-
(l(), B(
|
|
107
|
+
(l(), x(B(e.icon), { class: "tr-flow-layout__item-icon" })),
|
|
111
108
|
C("span", Z, D(e.label), 1)
|
|
112
109
|
], 10, Y))), 128))
|
|
113
110
|
], 512)) : _("", !0)
|
|
@@ -115,7 +112,7 @@ const P = ["onClick"], Q = {
|
|
|
115
112
|
])
|
|
116
113
|
], 512));
|
|
117
114
|
}
|
|
118
|
-
}), p = /* @__PURE__ */ K(ee, [["__scopeId", "data-v-
|
|
115
|
+
}), p = /* @__PURE__ */ K(ee, [["__scopeId", "data-v-8d510691"]]);
|
|
119
116
|
p.name = "TrFlowLayout";
|
|
120
117
|
const te = function(d) {
|
|
121
118
|
d.component(p.name, p);
|