@opentiny/tiny-robot 0.5.2-beta.0 → 0.5.2-rc.0
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/anchor/index.js +32 -32
- package/dist/container/index.js +15 -16
- package/dist/dropdown-menu/index.js +97 -141
- package/dist/index.d.ts +122 -695
- package/dist/index.js +89 -103
- package/dist/index4.js +2 -2
- package/dist/index6.js +399 -408
- package/dist/index7.js +180 -271
- package/dist/index8.js +102 -87
- package/dist/layout/index.js +1 -1
- package/dist/sender/index.js +2138 -1219
- package/dist/style.css +1 -1
- package/dist/suggestion-pills/index.js +1 -1
- package/dist/suggestion-popover/index.js +36 -37
- package/dist/useSlotRefs.js +1 -1
- package/dist/utils.js +1 -1
- package/package.json +4 -4
- package/dist/extension-manager/index.js +0 -1006
- package/dist/floating-ui.dom.js +0 -970
- package/dist/model-selector/index.js +0 -1003
- package/dist/useTeleportTarget.js +0 -25
package/dist/index7.js
CHANGED
|
@@ -1,53 +1,53 @@
|
|
|
1
|
-
import { onMounted as
|
|
2
|
-
import { IconEmptySearch as
|
|
3
|
-
import { _ as
|
|
4
|
-
import { o as
|
|
5
|
-
import { t as
|
|
6
|
-
const
|
|
7
|
-
let
|
|
8
|
-
function
|
|
9
|
-
const
|
|
10
|
-
|
|
1
|
+
import { onMounted as ne, onBeforeUnmount as oe, ref as y, defineComponent as P, openBlock as l, createElementBlock as u, createElementVNode as w, createVNode as T, unref as n, toDisplayString as B, useModel as W, computed as I, normalizeStyle as ie, Fragment as S, renderList as V, createBlock as H, resolveDynamicComponent as Y, mergeModels as j, nextTick as se, normalizeClass as U, createCommentVNode as G, renderSlot as q, withDirectives as A, withKeys as F, isRef as re, withModifiers as J, vModelText as le, vShow as ue } from "vue";
|
|
2
|
+
import { IconEmptySearch as ae, IconEditPen as ce, IconDelete as de, IconCheck as me, IconClose as fe, IconMore as pe } from "@opentiny/tiny-robot-svgs";
|
|
3
|
+
import { _ as z } from "./_plugin-vue_export-helper.js";
|
|
4
|
+
import { o as Z, d as ve, c as ge, b as _e } from "./index4.js";
|
|
5
|
+
import { t as O } from "./utils.js";
|
|
6
|
+
const D = y(!1);
|
|
7
|
+
let b = 0, $;
|
|
8
|
+
function ye() {
|
|
9
|
+
const s = window.matchMedia("(hover: none) and (pointer: coarse)"), m = () => {
|
|
10
|
+
D.value = s.matches;
|
|
11
11
|
};
|
|
12
|
-
|
|
13
|
-
const
|
|
14
|
-
|
|
12
|
+
m(), s.addEventListener("change", m);
|
|
13
|
+
const t = (c) => {
|
|
14
|
+
D.value = c.pointerType !== "mouse";
|
|
15
15
|
};
|
|
16
|
-
return window.addEventListener("pointerdown",
|
|
17
|
-
|
|
16
|
+
return window.addEventListener("pointerdown", t, !0), () => {
|
|
17
|
+
s.removeEventListener("change", m), window.removeEventListener("pointerdown", t, !0);
|
|
18
18
|
};
|
|
19
19
|
}
|
|
20
|
-
function
|
|
21
|
-
|
|
20
|
+
function he() {
|
|
21
|
+
$ == null || $(), $ = void 0;
|
|
22
22
|
}
|
|
23
|
-
function
|
|
23
|
+
function Ce() {
|
|
24
24
|
return typeof window > "u" ? {
|
|
25
|
-
isTouchDevice:
|
|
26
|
-
} : (
|
|
27
|
-
|
|
28
|
-
}),
|
|
29
|
-
|
|
25
|
+
isTouchDevice: D
|
|
26
|
+
} : (ne(() => {
|
|
27
|
+
b++, b === 1 && ($ = ye());
|
|
28
|
+
}), oe(() => {
|
|
29
|
+
b = Math.max(0, b - 1), b === 0 && he();
|
|
30
30
|
}), {
|
|
31
|
-
isTouchDevice:
|
|
31
|
+
isTouchDevice: D
|
|
32
32
|
});
|
|
33
33
|
}
|
|
34
|
-
const
|
|
34
|
+
const ke = { class: "tr-history__empty" }, Le = { class: "tr-history__empty-icon" }, Ee = { class: "tr-history__empty-text" }, we = /* @__PURE__ */ P({
|
|
35
35
|
__name: "Empty",
|
|
36
36
|
props: {
|
|
37
37
|
text: { default: "暂无内容" }
|
|
38
38
|
},
|
|
39
|
-
setup(
|
|
40
|
-
const
|
|
41
|
-
return (
|
|
42
|
-
|
|
43
|
-
|
|
39
|
+
setup(s) {
|
|
40
|
+
const m = s;
|
|
41
|
+
return (t, c) => (l(), u("div", ke, [
|
|
42
|
+
w("span", Le, [
|
|
43
|
+
T(n(ae))
|
|
44
44
|
]),
|
|
45
|
-
|
|
45
|
+
w("span", Ee, B(m.text), 1)
|
|
46
46
|
]));
|
|
47
47
|
}
|
|
48
|
-
}),
|
|
48
|
+
}), Re = /* @__PURE__ */ z(we, [["__scopeId", "data-v-d0340c39"]]), Ie = ["onClick"], Q = 4, xe = /* @__PURE__ */ P({
|
|
49
49
|
__name: "MenuList",
|
|
50
|
-
props: /* @__PURE__ */
|
|
50
|
+
props: /* @__PURE__ */ j({
|
|
51
51
|
items: {},
|
|
52
52
|
menuListGap: { default: 8 }
|
|
53
53
|
}, {
|
|
@@ -56,132 +56,85 @@ const De = { class: "tr-history__empty" }, $e = { class: "tr-history__empty-icon
|
|
|
56
56
|
data: { default: null },
|
|
57
57
|
dataModifiers: {}
|
|
58
58
|
}),
|
|
59
|
-
emits: /* @__PURE__ */
|
|
60
|
-
setup(
|
|
61
|
-
const
|
|
62
|
-
|
|
63
|
-
|
|
59
|
+
emits: /* @__PURE__ */ j(["item-click"], ["update:trigger", "update:data"]),
|
|
60
|
+
setup(s, { emit: m }) {
|
|
61
|
+
const t = W(s, "trigger"), c = W(s, "data"), h = s, C = m, E = y(null);
|
|
62
|
+
Z(
|
|
63
|
+
E,
|
|
64
64
|
() => {
|
|
65
|
-
|
|
65
|
+
t.value = null, c.value = null;
|
|
66
66
|
},
|
|
67
67
|
{
|
|
68
|
-
ignore: [
|
|
68
|
+
ignore: [t]
|
|
69
69
|
}
|
|
70
70
|
);
|
|
71
|
-
const { top:
|
|
72
|
-
const
|
|
73
|
-
left: `min(${
|
|
74
|
-
},
|
|
75
|
-
return
|
|
76
|
-
}),
|
|
77
|
-
|
|
78
|
-
}, f = () => {
|
|
79
|
-
var n;
|
|
80
|
-
return Array.from(((n = C.value) == null ? void 0 : n.querySelectorAll('[role="menuitem"]')) || []);
|
|
81
|
-
}, W = () => {
|
|
82
|
-
var n;
|
|
83
|
-
return (n = f()[0]) == null ? void 0 : n.focus();
|
|
84
|
-
}, g = () => {
|
|
85
|
-
var n;
|
|
86
|
-
return (n = f().at(-1)) == null ? void 0 : n.focus();
|
|
87
|
-
}, S = () => {
|
|
88
|
-
const n = r.value;
|
|
89
|
-
r.value = null, k.value = null, F(() => n == null ? void 0 : n.focus());
|
|
90
|
-
}, m = (n) => {
|
|
91
|
-
var $, K;
|
|
92
|
-
if (n.key === "Tab") {
|
|
93
|
-
r.value = null, k.value = null;
|
|
94
|
-
return;
|
|
95
|
-
}
|
|
96
|
-
const p = f(), y = p.indexOf(document.activeElement);
|
|
97
|
-
if (n.key === "Escape") {
|
|
98
|
-
n.preventDefault(), S();
|
|
99
|
-
return;
|
|
100
|
-
}
|
|
101
|
-
if (n.key === "Enter" || n.key === " ") {
|
|
102
|
-
n.preventDefault(), ($ = p[y]) == null || $.click();
|
|
103
|
-
return;
|
|
104
|
-
}
|
|
105
|
-
if (!["ArrowDown", "ArrowUp", "Home", "End"].includes(n.key) || p.length === 0) return;
|
|
106
|
-
n.preventDefault();
|
|
107
|
-
let L = y;
|
|
108
|
-
n.key === "Home" && (L = 0), n.key === "End" && (L = p.length - 1), n.key === "ArrowDown" && (L = y < p.length - 1 ? y + 1 : 0), n.key === "ArrowUp" && (L = y > 0 ? y - 1 : p.length - 1), (K = p[L]) == null || K.focus();
|
|
71
|
+
const { top: p, bottom: x, left: _ } = ve(t), { width: M, height: k } = ge(E, void 0, { box: "border-box" }), { height: R } = _e(), o = I(() => {
|
|
72
|
+
const L = {
|
|
73
|
+
left: `min(${O(_.value)}, calc(100% - ${O(M.value + Q)}))`
|
|
74
|
+
}, g = x.value + h.menuListGap;
|
|
75
|
+
return g + k.value + Q > R.value ? L.bottom = `calc(100% - ${O(p.value - h.menuListGap)})` : L.top = O(g), L;
|
|
76
|
+
}), v = (L) => {
|
|
77
|
+
C("item-click", L), t.value = null, c.value = null;
|
|
109
78
|
};
|
|
110
|
-
return
|
|
79
|
+
return (L, g) => (l(), u("ul", {
|
|
111
80
|
class: "tr-history__menu-list",
|
|
112
81
|
ref_key: "menuRef",
|
|
113
|
-
ref:
|
|
114
|
-
style:
|
|
115
|
-
role: "menu",
|
|
116
|
-
onKeydown: m
|
|
82
|
+
ref: E,
|
|
83
|
+
style: ie(o.value)
|
|
117
84
|
}, [
|
|
118
|
-
(
|
|
85
|
+
(l(!0), u(S, null, V(h.items, (a) => (l(), u("li", {
|
|
119
86
|
class: "tr-history__menu-list__item",
|
|
120
|
-
key:
|
|
121
|
-
|
|
122
|
-
tabindex: "-1",
|
|
123
|
-
onClick: (L) => o(y)
|
|
87
|
+
key: a.id,
|
|
88
|
+
onClick: (K) => v(a)
|
|
124
89
|
}, [
|
|
125
|
-
(
|
|
126
|
-
|
|
127
|
-
], 8,
|
|
128
|
-
],
|
|
90
|
+
(l(), H(Y(a.icon))),
|
|
91
|
+
w("span", null, B(a.text), 1)
|
|
92
|
+
], 8, Ie))), 128))
|
|
93
|
+
], 4));
|
|
129
94
|
}
|
|
130
|
-
}),
|
|
131
|
-
renameControlOnClickOutside:
|
|
132
|
-
onItemTitleChange:
|
|
133
|
-
resolveItem: c
|
|
95
|
+
}), Me = /* @__PURE__ */ z(xe, [["__scopeId", "data-v-89fdb41c"]]), be = ({
|
|
96
|
+
renameControlOnClickOutside: s,
|
|
97
|
+
onItemTitleChange: m
|
|
134
98
|
}) => {
|
|
135
|
-
const
|
|
136
|
-
const o = r.value;
|
|
137
|
-
if (o)
|
|
138
|
-
return c ? c(o) : o;
|
|
139
|
-
}), _ = R(null), b = E(() => {
|
|
99
|
+
const t = y(void 0), c = y(null), h = I(() => {
|
|
140
100
|
var o;
|
|
141
|
-
return (o =
|
|
142
|
-
}), C =
|
|
101
|
+
return (o = c.value) == null ? void 0 : o.at(0);
|
|
102
|
+
}), C = y(null), E = I(() => {
|
|
143
103
|
var o;
|
|
144
104
|
return (o = C.value) == null ? void 0 : o.at(0);
|
|
145
|
-
}),
|
|
105
|
+
}), p = y(null), x = I(() => {
|
|
146
106
|
var o;
|
|
147
|
-
return (o =
|
|
148
|
-
}),
|
|
149
|
-
|
|
150
|
-
const
|
|
151
|
-
|
|
107
|
+
return (o = p.value) == null ? void 0 : o.at(0);
|
|
108
|
+
}), _ = y(""), M = (o) => {
|
|
109
|
+
t.value = o, _.value = o.title, se(() => {
|
|
110
|
+
const v = h.value;
|
|
111
|
+
v && (v.focus(), v.select());
|
|
152
112
|
});
|
|
153
|
-
},
|
|
154
|
-
|
|
155
|
-
},
|
|
156
|
-
|
|
157
|
-
o && h(x.value, o), I();
|
|
113
|
+
}, k = () => {
|
|
114
|
+
t.value = void 0, _.value = "";
|
|
115
|
+
}, R = () => {
|
|
116
|
+
t.value && m(_.value, t.value), t.value = void 0, _.value = "";
|
|
158
117
|
};
|
|
159
|
-
return
|
|
160
|
-
|
|
161
|
-
(o, f) => {
|
|
162
|
-
f && !o && I();
|
|
163
|
-
},
|
|
164
|
-
{ flush: "sync" }
|
|
165
|
-
), (u === "confirm" || u === "cancel") && ce(
|
|
166
|
-
b,
|
|
118
|
+
return (s === "confirm" || s === "cancel") && Z(
|
|
119
|
+
h,
|
|
167
120
|
() => {
|
|
168
|
-
|
|
121
|
+
s === "confirm" ? R() : k();
|
|
169
122
|
},
|
|
170
|
-
{ ignore: [
|
|
123
|
+
{ ignore: [E, x] }
|
|
171
124
|
), {
|
|
172
|
-
editingItem:
|
|
173
|
-
editorRefList:
|
|
125
|
+
editingItem: t,
|
|
126
|
+
editorRefList: c,
|
|
174
127
|
editorConfirmRefList: C,
|
|
175
|
-
editorCancelRefList:
|
|
176
|
-
editorValue:
|
|
177
|
-
handleEdit:
|
|
178
|
-
handleEditCancel:
|
|
179
|
-
handleEditConfirm:
|
|
128
|
+
editorCancelRefList: p,
|
|
129
|
+
editorValue: _,
|
|
130
|
+
handleEdit: M,
|
|
131
|
+
handleEditCancel: k,
|
|
132
|
+
handleEditConfirm: R
|
|
180
133
|
};
|
|
181
|
-
},
|
|
134
|
+
}, X = Symbol("NO_GROUP"), Te = {
|
|
182
135
|
key: 0,
|
|
183
136
|
class: "tr-history__group-title"
|
|
184
|
-
},
|
|
137
|
+
}, $e = { class: "tr-history__group-items" }, Ge = ["onClick"], Oe = ["title"], Se = ["onClick"], Be = /* @__PURE__ */ P({
|
|
185
138
|
__name: "index",
|
|
186
139
|
props: {
|
|
187
140
|
data: {},
|
|
@@ -189,201 +142,157 @@ const De = { class: "tr-history__empty" }, $e = { class: "tr-history__empty-icon
|
|
|
189
142
|
showRenameControls: { type: Boolean, default: !1 },
|
|
190
143
|
renameControlOnClickOutside: { default: "confirm" },
|
|
191
144
|
menuItems: { default: () => [
|
|
192
|
-
{ id: "rename", text: "重命名", icon:
|
|
193
|
-
{ id: "delete", text: "删除", icon:
|
|
145
|
+
{ id: "rename", text: "重命名", icon: ce },
|
|
146
|
+
{ id: "delete", text: "删除", icon: de }
|
|
194
147
|
] },
|
|
195
148
|
menuListGap: { default: 8 }
|
|
196
149
|
},
|
|
197
150
|
emits: ["item-click", "item-title-change", "item-action"],
|
|
198
|
-
setup(
|
|
199
|
-
const
|
|
200
|
-
var
|
|
201
|
-
const
|
|
202
|
-
return
|
|
203
|
-
},
|
|
204
|
-
const
|
|
205
|
-
return
|
|
206
|
-
}),
|
|
207
|
-
editingItem:
|
|
208
|
-
editorRefList:
|
|
209
|
-
editorConfirmRefList:
|
|
210
|
-
editorCancelRefList:
|
|
211
|
-
editorValue:
|
|
212
|
-
handleEdit:
|
|
151
|
+
setup(s, { emit: m }) {
|
|
152
|
+
const t = s, c = m, h = (i) => {
|
|
153
|
+
var f;
|
|
154
|
+
const e = typeof ((f = i[0]) == null ? void 0 : f.group);
|
|
155
|
+
return e === "string" || e === "symbol";
|
|
156
|
+
}, C = I(() => {
|
|
157
|
+
const i = t.data;
|
|
158
|
+
return h(i) ? i : [{ group: X, items: i }];
|
|
159
|
+
}), E = I(() => C.value.length === 0 || C.value.every((i) => i.items.length === 0)), {
|
|
160
|
+
editingItem: p,
|
|
161
|
+
editorRefList: x,
|
|
162
|
+
editorConfirmRefList: _,
|
|
163
|
+
editorCancelRefList: M,
|
|
164
|
+
editorValue: k,
|
|
165
|
+
handleEdit: R,
|
|
213
166
|
handleEditCancel: o,
|
|
214
|
-
handleEditConfirm:
|
|
215
|
-
} =
|
|
216
|
-
renameControlOnClickOutside:
|
|
217
|
-
onItemTitleChange: (
|
|
218
|
-
|
|
219
|
-
},
|
|
220
|
-
resolveItem: M
|
|
221
|
-
}), { isTouchDevice: W } = Me(), g = R(null), S = ue(null), m = E({
|
|
222
|
-
get: () => {
|
|
223
|
-
const e = S.value;
|
|
224
|
-
return e ? M(e) ?? null : null;
|
|
225
|
-
},
|
|
226
|
-
set: (e) => {
|
|
227
|
-
S.value = e;
|
|
167
|
+
handleEditConfirm: v
|
|
168
|
+
} = be({
|
|
169
|
+
renameControlOnClickOutside: t.renameControlOnClickOutside,
|
|
170
|
+
onItemTitleChange: (i, e) => {
|
|
171
|
+
c("item-title-change", i, e);
|
|
228
172
|
}
|
|
229
|
-
}),
|
|
230
|
-
|
|
231
|
-
|
|
232
|
-
|
|
233
|
-
});
|
|
234
|
-
}, y = (e, t) => {
|
|
235
|
-
if (e.currentTarget instanceof HTMLButtonElement) {
|
|
236
|
-
if (m.value === t) {
|
|
237
|
-
g.value = null, m.value = null;
|
|
173
|
+
}), { isTouchDevice: L } = Ce(), g = y(null), a = y(null), K = (i, e) => {
|
|
174
|
+
if (i.currentTarget instanceof HTMLButtonElement) {
|
|
175
|
+
if (a.value === e) {
|
|
176
|
+
g.value = null, a.value = null;
|
|
238
177
|
return;
|
|
239
178
|
}
|
|
240
|
-
g.value =
|
|
179
|
+
g.value = i.currentTarget, a.value = e;
|
|
241
180
|
} else
|
|
242
|
-
g.value = null,
|
|
243
|
-
},
|
|
244
|
-
|
|
245
|
-
|
|
246
|
-
g.value = null, m.value = null;
|
|
247
|
-
};
|
|
248
|
-
ae(
|
|
249
|
-
m,
|
|
250
|
-
(e) => {
|
|
251
|
-
!e && S.value && $();
|
|
252
|
-
},
|
|
253
|
-
{ flush: "sync" }
|
|
254
|
-
);
|
|
255
|
-
const K = (e) => {
|
|
256
|
-
g.value && (e.preventDefault(), e.stopPropagation(), $());
|
|
257
|
-
}, de = (e) => {
|
|
258
|
-
const t = m.value, l = g.value;
|
|
259
|
-
t && (e.id === "rename" ? D(t) : F(() => l == null ? void 0 : l.focus()), r("item-action", e, t));
|
|
181
|
+
g.value = null, a.value = null;
|
|
182
|
+
}, ee = (i) => {
|
|
183
|
+
const e = a.value;
|
|
184
|
+
e && (i.id === "rename" && R(e), c("item-action", i, e));
|
|
260
185
|
};
|
|
261
|
-
return (
|
|
262
|
-
class:
|
|
186
|
+
return (i, e) => (l(), u("div", {
|
|
187
|
+
class: U(["tr-history", { "touch-device": n(L) }])
|
|
263
188
|
}, [
|
|
264
|
-
|
|
265
|
-
(
|
|
189
|
+
E.value ? (l(), H(Re, { key: 1 })) : (l(), u(S, { key: 0 }, [
|
|
190
|
+
(l(!0), u(S, null, V(C.value, (f) => (l(), u("div", {
|
|
266
191
|
class: "tr-history__group",
|
|
267
|
-
key:
|
|
192
|
+
key: f.group
|
|
268
193
|
}, [
|
|
269
|
-
|
|
270
|
-
|
|
271
|
-
(
|
|
272
|
-
class:
|
|
273
|
-
selected:
|
|
274
|
-
editing:
|
|
275
|
-
active:
|
|
194
|
+
f.group !== n(X) ? (l(), u("div", Te, B(f.group), 1)) : G("", !0),
|
|
195
|
+
w("div", $e, [
|
|
196
|
+
(l(!0), u(S, null, V(f.items, (r, te) => (l(), u("div", {
|
|
197
|
+
class: U(["tr-history__item", {
|
|
198
|
+
selected: r.id && r.id === t.selected,
|
|
199
|
+
editing: n(p) === r,
|
|
200
|
+
active: a.value === r
|
|
276
201
|
}]),
|
|
277
|
-
key:
|
|
278
|
-
onClick: (d) =>
|
|
202
|
+
key: r.id || te,
|
|
203
|
+
onClick: (d) => c("item-click", r)
|
|
279
204
|
}, [
|
|
280
|
-
|
|
281
|
-
|
|
282
|
-
|
|
205
|
+
q(i.$slots, "item-prefix", { item: r }, void 0, !0),
|
|
206
|
+
r.icon ? (l(), H(Y(r.icon), { key: 0 })) : G("", !0),
|
|
207
|
+
n(p) === r ? A((l(), u("input", {
|
|
283
208
|
key: 1,
|
|
284
209
|
class: "tr-history__item-editor",
|
|
285
210
|
type: "text",
|
|
286
|
-
onClick:
|
|
211
|
+
onClick: e[0] || (e[0] = J(() => {
|
|
287
212
|
}, ["stop"])),
|
|
288
213
|
ref_for: !0,
|
|
289
214
|
ref_key: "editorRefList",
|
|
290
|
-
ref:
|
|
291
|
-
"onUpdate:modelValue":
|
|
215
|
+
ref: x,
|
|
216
|
+
"onUpdate:modelValue": e[1] || (e[1] = (d) => re(k) ? k.value = d : null),
|
|
292
217
|
onKeydown: [
|
|
293
|
-
|
|
218
|
+
e[2] || (e[2] = F(
|
|
294
219
|
//@ts-ignore
|
|
295
|
-
(...d) =>
|
|
220
|
+
(...d) => n(v) && n(v)(...d),
|
|
296
221
|
["enter"]
|
|
297
222
|
)),
|
|
298
|
-
|
|
223
|
+
e[3] || (e[3] = F(
|
|
299
224
|
//@ts-ignore
|
|
300
|
-
(...d) =>
|
|
225
|
+
(...d) => n(o) && n(o)(...d),
|
|
301
226
|
["escape"]
|
|
302
227
|
))
|
|
303
228
|
]
|
|
304
229
|
}, null, 544)), [
|
|
305
|
-
[
|
|
306
|
-
]) :
|
|
307
|
-
|
|
230
|
+
[le, n(k)]
|
|
231
|
+
]) : q(i.$slots, "item-title", { item: r }, () => [
|
|
232
|
+
w("span", {
|
|
308
233
|
class: "text",
|
|
309
|
-
title:
|
|
310
|
-
},
|
|
234
|
+
title: r.title
|
|
235
|
+
}, B(r.title), 9, Oe)
|
|
311
236
|
], !0, 2),
|
|
312
|
-
|
|
237
|
+
w("span", {
|
|
313
238
|
class: "tr-history__item-actions",
|
|
314
|
-
onClick:
|
|
239
|
+
onClick: e[6] || (e[6] = J(() => {
|
|
315
240
|
}, ["stop"]))
|
|
316
241
|
}, [
|
|
317
|
-
|
|
242
|
+
t.showRenameControls && n(p) === r ? (l(), u("button", {
|
|
318
243
|
key: 0,
|
|
319
244
|
class: "editor-confirm",
|
|
320
245
|
ref_for: !0,
|
|
321
246
|
ref_key: "editorConfirmRefList",
|
|
322
|
-
ref:
|
|
323
|
-
|
|
324
|
-
|
|
325
|
-
onClick: t[4] || (t[4] = //@ts-ignore
|
|
326
|
-
(...d) => i(f) && i(f)(...d))
|
|
247
|
+
ref: _,
|
|
248
|
+
onClick: e[4] || (e[4] = //@ts-ignore
|
|
249
|
+
(...d) => n(v) && n(v)(...d))
|
|
327
250
|
}, [
|
|
328
|
-
|
|
329
|
-
], 512)) :
|
|
330
|
-
|
|
251
|
+
T(n(me))
|
|
252
|
+
], 512)) : G("", !0),
|
|
253
|
+
t.showRenameControls && n(p) === r ? (l(), u("button", {
|
|
331
254
|
key: 1,
|
|
332
255
|
class: "editor-cancel",
|
|
333
256
|
ref_for: !0,
|
|
334
257
|
ref_key: "editorCancelRefList",
|
|
335
|
-
ref:
|
|
336
|
-
|
|
337
|
-
|
|
338
|
-
onClick: t[5] || (t[5] = //@ts-ignore
|
|
339
|
-
(...d) => i(o) && i(o)(...d))
|
|
258
|
+
ref: M,
|
|
259
|
+
onClick: e[5] || (e[5] = //@ts-ignore
|
|
260
|
+
(...d) => n(o) && n(o)(...d))
|
|
340
261
|
}, [
|
|
341
|
-
|
|
342
|
-
], 512)) :
|
|
343
|
-
|
|
344
|
-
class:
|
|
345
|
-
|
|
346
|
-
"aria-label": `${s.title} 更多操作`,
|
|
347
|
-
"aria-haspopup": "menu",
|
|
348
|
-
"aria-expanded": m.value === s,
|
|
349
|
-
onClick: (d) => y(d, s),
|
|
350
|
-
onKeydown: [
|
|
351
|
-
O((d) => L(d, s, "first"), ["down"]),
|
|
352
|
-
O((d) => L(d, s, "last"), ["up"]),
|
|
353
|
-
O(K, ["escape"]),
|
|
354
|
-
O($, ["tab"])
|
|
355
|
-
]
|
|
262
|
+
T(n(fe))
|
|
263
|
+
], 512)) : G("", !0),
|
|
264
|
+
w("button", {
|
|
265
|
+
class: U(["menu", { hidden: n(p) === r }]),
|
|
266
|
+
onClick: (d) => K(d, r)
|
|
356
267
|
}, [
|
|
357
|
-
|
|
358
|
-
],
|
|
268
|
+
T(n(pe))
|
|
269
|
+
], 10, Se)
|
|
359
270
|
])
|
|
360
|
-
], 10,
|
|
271
|
+
], 10, Ge))), 128))
|
|
361
272
|
])
|
|
362
273
|
]))), 128)),
|
|
363
|
-
|
|
364
|
-
ref_key: "menuListRef",
|
|
365
|
-
ref: n,
|
|
274
|
+
A(T(Me, {
|
|
366
275
|
trigger: g.value,
|
|
367
|
-
"onUpdate:trigger":
|
|
368
|
-
data:
|
|
369
|
-
"onUpdate:data":
|
|
370
|
-
items:
|
|
371
|
-
"menu-list-gap":
|
|
372
|
-
onItemClick:
|
|
276
|
+
"onUpdate:trigger": e[7] || (e[7] = (f) => g.value = f),
|
|
277
|
+
data: a.value,
|
|
278
|
+
"onUpdate:data": e[8] || (e[8] = (f) => a.value = f),
|
|
279
|
+
items: t.menuItems,
|
|
280
|
+
"menu-list-gap": t.menuListGap,
|
|
281
|
+
onItemClick: ee
|
|
373
282
|
}, null, 8, ["trigger", "data", "items", "menu-list-gap"]), [
|
|
374
|
-
[
|
|
283
|
+
[ue, g.value]
|
|
375
284
|
])
|
|
376
285
|
], 64))
|
|
377
286
|
], 2));
|
|
378
287
|
}
|
|
379
|
-
}),
|
|
380
|
-
|
|
288
|
+
}), N = /* @__PURE__ */ z(Be, [["__scopeId", "data-v-125148d2"]]), De = function(s) {
|
|
289
|
+
s.component(N.name, N);
|
|
381
290
|
};
|
|
382
|
-
Object.assign(
|
|
291
|
+
Object.assign(N, {
|
|
383
292
|
name: "TrHistory",
|
|
384
|
-
install:
|
|
293
|
+
install: De
|
|
385
294
|
});
|
|
386
295
|
export {
|
|
387
|
-
|
|
388
|
-
|
|
296
|
+
N as H,
|
|
297
|
+
Ce as u
|
|
389
298
|
};
|