@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/index.js
CHANGED
|
@@ -1,34 +1,32 @@
|
|
|
1
1
|
import S from "./attachments/index.js";
|
|
2
|
-
import { B, a as
|
|
3
|
-
import { c as
|
|
4
|
-
import
|
|
2
|
+
import { B as F, a as b, b as x } from "./index6.js";
|
|
3
|
+
import { c as Pe, d as Ae, u as Oe, e as Me, f as Re, g as je, h as He, i as We, j as $e, k as we } from "./index6.js";
|
|
4
|
+
import E from "./container/index.js";
|
|
5
5
|
import C from "./anchor/index.js";
|
|
6
6
|
import z from "./conversations/index.js";
|
|
7
7
|
import y from "./drag-overlay/index.js";
|
|
8
8
|
import L from "./dropdown-menu/index.js";
|
|
9
9
|
import P from "./feedback/index.js";
|
|
10
10
|
import { H as A } from "./index7.js";
|
|
11
|
-
import { u as
|
|
12
|
-
import
|
|
13
|
-
import { Layout as
|
|
14
|
-
import H from "./
|
|
15
|
-
import
|
|
16
|
-
import w from "./sender/index.js";
|
|
17
|
-
import k from "./
|
|
18
|
-
import
|
|
19
|
-
import G from "./suggestion-popover/index.js";
|
|
11
|
+
import { u as Ne } from "./index7.js";
|
|
12
|
+
import O from "./icon-button/index.js";
|
|
13
|
+
import { Layout as M, LayoutProxyScrollbar as R, LayoutAsideToggle as j } from "./layout/index.js";
|
|
14
|
+
import { Prompt as H, Prompts as W } from "./prompts/index.js";
|
|
15
|
+
import $ from "./sender/index.js";
|
|
16
|
+
import w from "./sender-compat/index.js";
|
|
17
|
+
import k, { SuggestionPillButton as N } from "./suggestion-pills/index.js";
|
|
18
|
+
import V from "./suggestion-popover/index.js";
|
|
20
19
|
import I from "./theme-provider/index.js";
|
|
21
|
-
import { useTheme as
|
|
20
|
+
import { useTheme as Ie } from "./theme-provider/index.js";
|
|
22
21
|
import U from "./welcome/index.js";
|
|
23
22
|
import K from "./mcp-server-picker/index.js";
|
|
24
23
|
import X from "./mcp-add-form/index.js";
|
|
25
|
-
import {
|
|
26
|
-
import {
|
|
27
|
-
import {
|
|
28
|
-
import {
|
|
29
|
-
import { _ as te, V as ae } from "./index3.js";
|
|
24
|
+
import { u as Ke } from "./useSenderContentRegistration.js";
|
|
25
|
+
import { A as Y, S as q, _ as G, W as J, D as Q } from "./index2.js";
|
|
26
|
+
import { a as Ye, u as qe } from "./index2.js";
|
|
27
|
+
import { _ as Z, V as ee } from "./index3.js";
|
|
30
28
|
var u = /* @__PURE__ */ ((e) => (e.FileTypeNotAllowed = "file-type-not-allowed", e.FileSizeExceeded = "file-size-exceeded", e.FileCountExceeded = "file-count-exceeded", e))(u || {});
|
|
31
|
-
function
|
|
29
|
+
function re(e, r) {
|
|
32
30
|
if (!r) return !0;
|
|
33
31
|
const t = r.split(",").map((o) => o.trim());
|
|
34
32
|
return t.includes("*") ? !0 : t.some((o) => {
|
|
@@ -44,12 +42,12 @@ function ne(e, r) {
|
|
|
44
42
|
function v(e, r) {
|
|
45
43
|
return e.size <= r;
|
|
46
44
|
}
|
|
47
|
-
function
|
|
45
|
+
function oe(e, r) {
|
|
48
46
|
return e.length <= r;
|
|
49
47
|
}
|
|
50
|
-
function
|
|
48
|
+
function te(e, r) {
|
|
51
49
|
const { accept: t, multiple: o, maxSize: n, maxFiles: l } = r, a = [], s = [];
|
|
52
|
-
if (!
|
|
50
|
+
if (!oe(e, l))
|
|
53
51
|
return {
|
|
54
52
|
acceptedFiles: a,
|
|
55
53
|
rejectedFiles: Array.from(e),
|
|
@@ -59,7 +57,7 @@ function ie(e, r) {
|
|
|
59
57
|
}
|
|
60
58
|
};
|
|
61
59
|
if (e.forEach((i) => {
|
|
62
|
-
|
|
60
|
+
re(i, t) && v(i, n) ? a.push(i) : s.push(i);
|
|
63
61
|
}), !o && a.length > 1)
|
|
64
62
|
return {
|
|
65
63
|
acceptedFiles: [],
|
|
@@ -90,7 +88,7 @@ function T(e) {
|
|
|
90
88
|
disabled: e.disabled || !1
|
|
91
89
|
};
|
|
92
90
|
}
|
|
93
|
-
const
|
|
91
|
+
const Ce = {
|
|
94
92
|
/**
|
|
95
93
|
* 挂载指令
|
|
96
94
|
* @param el 元素
|
|
@@ -130,13 +128,13 @@ const Me = {
|
|
|
130
128
|
a.preventDefault(), t = 0, n(!1, null);
|
|
131
129
|
const s = (p = a.dataTransfer) == null ? void 0 : p.files, { onDrop: i, onError: d, accept: m, multiple: c, maxSize: g, maxFiles: D } = e.__vDropzoneOptions__;
|
|
132
130
|
if (s && s.length > 0) {
|
|
133
|
-
const h = Array.from(s), { acceptedFiles: f, rejectedFiles:
|
|
131
|
+
const h = Array.from(s), { acceptedFiles: f, rejectedFiles: B, rejectionReason: _ } = te(h, {
|
|
134
132
|
accept: m,
|
|
135
133
|
multiple: c,
|
|
136
134
|
maxSize: g,
|
|
137
135
|
maxFiles: D
|
|
138
136
|
});
|
|
139
|
-
_ && d({ files:
|
|
137
|
+
_ && d({ files: B, ..._ }), f.length > 0 && i(f);
|
|
140
138
|
}
|
|
141
139
|
}
|
|
142
140
|
};
|
|
@@ -152,142 +150,130 @@ const Me = {
|
|
|
152
150
|
unmounted(e) {
|
|
153
151
|
e.__vDropzoneHandlers__ && (e.removeEventListener("dragenter", e.__vDropzoneHandlers__.handleDragEnter), e.removeEventListener("dragover", e.__vDropzoneHandlers__.handleDragOver), e.removeEventListener("dragleave", e.__vDropzoneHandlers__.handleDragLeave), e.removeEventListener("drop", e.__vDropzoneHandlers__.handleDrop), delete e.__vDropzoneHandlers__), delete e.__vDropzoneOptions__;
|
|
154
152
|
}
|
|
155
|
-
},
|
|
153
|
+
}, ae = [
|
|
156
154
|
S,
|
|
157
|
-
B,
|
|
158
|
-
E,
|
|
159
155
|
F,
|
|
160
156
|
b,
|
|
157
|
+
x,
|
|
158
|
+
E,
|
|
161
159
|
C,
|
|
162
160
|
z,
|
|
163
161
|
y,
|
|
164
162
|
L,
|
|
165
163
|
P,
|
|
166
164
|
A,
|
|
167
|
-
M,
|
|
168
165
|
O,
|
|
166
|
+
M,
|
|
169
167
|
R,
|
|
170
168
|
j,
|
|
171
169
|
H,
|
|
172
|
-
$,
|
|
173
170
|
W,
|
|
171
|
+
$,
|
|
174
172
|
w,
|
|
175
173
|
k,
|
|
176
174
|
N,
|
|
177
175
|
V,
|
|
178
|
-
G,
|
|
179
176
|
I,
|
|
180
177
|
U,
|
|
181
178
|
K,
|
|
182
179
|
X,
|
|
183
180
|
Y,
|
|
184
181
|
q,
|
|
185
|
-
|
|
186
|
-
Q,
|
|
182
|
+
G,
|
|
187
183
|
Z,
|
|
188
184
|
ee,
|
|
189
|
-
|
|
190
|
-
|
|
191
|
-
|
|
192
|
-
oe
|
|
193
|
-
], Oe = {
|
|
185
|
+
J,
|
|
186
|
+
Q
|
|
187
|
+
], ze = {
|
|
194
188
|
install(e) {
|
|
195
|
-
|
|
189
|
+
ae.forEach((r) => {
|
|
196
190
|
const t = r.name.replace(/^Tiny/, "").replace(/^Tr/, "");
|
|
197
191
|
e.component(`Tr${t}`, r);
|
|
198
192
|
});
|
|
199
193
|
}
|
|
200
194
|
};
|
|
201
195
|
export {
|
|
202
|
-
|
|
196
|
+
Y as ActionButton,
|
|
203
197
|
C as Anchor,
|
|
204
198
|
S as Attachments,
|
|
205
|
-
|
|
206
|
-
|
|
207
|
-
|
|
208
|
-
|
|
209
|
-
|
|
210
|
-
|
|
211
|
-
|
|
199
|
+
F as Bubble,
|
|
200
|
+
b as BubbleList,
|
|
201
|
+
x as BubbleProvider,
|
|
202
|
+
Pe as BubbleRendererMatchPriority,
|
|
203
|
+
Ae as BubbleRenderers,
|
|
204
|
+
G as ClearButton,
|
|
205
|
+
E as Container,
|
|
212
206
|
z as Conversations,
|
|
213
|
-
|
|
207
|
+
Q as DefaultActionButtons,
|
|
214
208
|
y as DragOverlay,
|
|
215
209
|
L as DropdownMenu,
|
|
216
|
-
q as ExtensionCard,
|
|
217
|
-
J as ExtensionCardGrid,
|
|
218
|
-
Y as ExtensionManager,
|
|
219
210
|
P as Feedback,
|
|
220
211
|
A as History,
|
|
221
|
-
|
|
222
|
-
|
|
212
|
+
O as IconButton,
|
|
213
|
+
M as Layout,
|
|
223
214
|
j as LayoutAsideToggle,
|
|
224
215
|
R as LayoutProxyScrollbar,
|
|
225
216
|
X as McpAddForm,
|
|
226
217
|
K as McpServerPicker,
|
|
227
|
-
H as
|
|
228
|
-
$ as Prompt,
|
|
218
|
+
H as Prompt,
|
|
229
219
|
W as Prompts,
|
|
230
|
-
|
|
231
|
-
|
|
232
|
-
|
|
233
|
-
|
|
234
|
-
|
|
235
|
-
|
|
236
|
-
|
|
220
|
+
Ye as SENDER_CONTEXT_KEY,
|
|
221
|
+
$ as Sender,
|
|
222
|
+
w as SenderCompat,
|
|
223
|
+
q as SubmitButton,
|
|
224
|
+
N as SuggestionPillButton,
|
|
225
|
+
k as SuggestionPills,
|
|
226
|
+
V as SuggestionPopover,
|
|
237
227
|
I as ThemeProvider,
|
|
238
|
-
|
|
228
|
+
Y as TrActionButton,
|
|
239
229
|
C as TrAnchor,
|
|
240
230
|
S as TrAttachments,
|
|
241
|
-
|
|
242
|
-
|
|
243
|
-
|
|
244
|
-
|
|
245
|
-
|
|
231
|
+
F as TrBubble,
|
|
232
|
+
b as TrBubbleList,
|
|
233
|
+
x as TrBubbleProvider,
|
|
234
|
+
G as TrClearButton,
|
|
235
|
+
E as TrContainer,
|
|
246
236
|
z as TrConversations,
|
|
247
|
-
|
|
237
|
+
Q as TrDefaultActionButtons,
|
|
248
238
|
y as TrDragOverlay,
|
|
249
239
|
L as TrDropdownMenu,
|
|
250
|
-
q as TrExtensionCard,
|
|
251
|
-
J as TrExtensionCardGrid,
|
|
252
|
-
Y as TrExtensionManager,
|
|
253
240
|
P as TrFeedback,
|
|
254
241
|
A as TrHistory,
|
|
255
|
-
|
|
256
|
-
|
|
242
|
+
O as TrIconButton,
|
|
243
|
+
M as TrLayout,
|
|
257
244
|
j as TrLayoutAsideToggle,
|
|
258
245
|
R as TrLayoutProxyScrollbar,
|
|
259
246
|
X as TrMcpAddForm,
|
|
260
247
|
K as TrMcpServerPicker,
|
|
261
|
-
H as
|
|
262
|
-
$ as TrPrompt,
|
|
248
|
+
H as TrPrompt,
|
|
263
249
|
W as TrPrompts,
|
|
264
|
-
|
|
265
|
-
|
|
266
|
-
|
|
267
|
-
|
|
268
|
-
|
|
269
|
-
|
|
250
|
+
$ as TrSender,
|
|
251
|
+
w as TrSenderCompat,
|
|
252
|
+
q as TrSubmitButton,
|
|
253
|
+
N as TrSuggestionPillButton,
|
|
254
|
+
k as TrSuggestionPills,
|
|
255
|
+
V as TrSuggestionPopover,
|
|
270
256
|
I as TrThemeProvider,
|
|
271
|
-
|
|
272
|
-
|
|
257
|
+
Z as TrUploadButton,
|
|
258
|
+
ee as TrVoiceButton,
|
|
273
259
|
U as TrWelcome,
|
|
274
|
-
|
|
275
|
-
|
|
276
|
-
|
|
260
|
+
J as TrWordCounter,
|
|
261
|
+
Z as UploadButton,
|
|
262
|
+
ee as VoiceButton,
|
|
277
263
|
U as Welcome,
|
|
278
|
-
|
|
279
|
-
|
|
280
|
-
|
|
281
|
-
|
|
282
|
-
|
|
283
|
-
|
|
284
|
-
|
|
285
|
-
|
|
286
|
-
|
|
287
|
-
|
|
288
|
-
|
|
289
|
-
|
|
290
|
-
|
|
291
|
-
|
|
292
|
-
|
|
264
|
+
J as WordCounter,
|
|
265
|
+
ze as default,
|
|
266
|
+
Oe as useAutoScroll,
|
|
267
|
+
Me as useBubbleBoxRenderer,
|
|
268
|
+
Re as useBubbleContentRenderer,
|
|
269
|
+
je as useBubbleEventFn,
|
|
270
|
+
He as useBubbleStateChangeFn,
|
|
271
|
+
We as useMessageContent,
|
|
272
|
+
$e as useOmitMessageFields,
|
|
273
|
+
Ke as useSenderContentRegistration,
|
|
274
|
+
qe as useSenderContext,
|
|
275
|
+
Ie as useTheme,
|
|
276
|
+
we as useToolCall,
|
|
277
|
+
Ne as useTouchDevice,
|
|
278
|
+
Ce as vDropzone
|
|
293
279
|
};
|
package/dist/index4.js
CHANGED
|
@@ -814,7 +814,7 @@ function lt(e = {}) {
|
|
|
814
814
|
return { width: r, height: s };
|
|
815
815
|
}
|
|
816
816
|
export {
|
|
817
|
-
|
|
817
|
+
x as a,
|
|
818
818
|
lt as b,
|
|
819
819
|
tt as c,
|
|
820
820
|
et as d,
|
|
@@ -831,6 +831,6 @@ export {
|
|
|
831
831
|
Je as o,
|
|
832
832
|
Ke as p,
|
|
833
833
|
B as t,
|
|
834
|
-
|
|
834
|
+
rt as u,
|
|
835
835
|
qe as w
|
|
836
836
|
};
|