@vite-hub/ui 0.3.1 → 0.4.1
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/README.md +5 -5
- package/dist/{avatar-stack-DXmCQhxd.d.ts → avatar-stack-DPRFuezh.d.ts} +1 -1
- package/dist/{code-view-D0bqhogi.js → code-view-DsU-xzic.js} +4 -4
- package/dist/comment-attachments-C4yNbcx5.js +20 -0
- package/dist/{comment-composer-Cc8Jvu6u.d.ts → comment-composer-fINL5bxo.d.ts} +3 -3
- package/dist/{comment-layer-ClH4MLj4.d.ts → comment-layer-C_sbPIR5.d.ts} +18 -7
- package/dist/{comment-list-B8hphLfS.d.ts → comment-list-BcSaLngS.d.ts} +3 -3
- package/dist/{comment-panel-fcKSKwLC.d.ts → comment-panel-CfvdRUMX.d.ts} +16 -5
- package/dist/{comment-pin-CvwgRSDR.d.ts → comment-pin-DHOdRvUw.d.ts} +1 -1
- package/dist/{comment-row-Bbm9WwuF.js → comment-row-Bn3nr8l5.js} +1 -1
- package/dist/comment-selection-bar-CyVBNYl9.d.ts +42 -0
- package/dist/{comment-thread-CoTLrdal.d.ts → comment-thread-DKJjmWN0.d.ts} +23 -6
- package/dist/{comments-CkWc2Khc.js → comments-D0d26ghV.js} +65 -9
- package/dist/{comments-Bx2WRsYy.d.ts → comments-D8hulVPy.d.ts} +34 -6
- package/dist/format-orwcdZL_.js +39 -0
- package/dist/headless.d.ts +3 -3
- package/dist/headless.js +1 -1
- package/dist/{index-BD1e8vx5.d.ts → index-BYRFQfCd.d.ts} +6 -0
- package/dist/index.d.ts +13 -12
- package/dist/index.js +4 -3
- package/dist/{markdown-editor-DqdZfIEn.d.ts → markdown-editor-wQF0yD5o.d.ts} +1 -1
- package/dist/markdown-editor.d.ts +1 -1
- package/dist/{message-scroller-Bm1YWTeY.d.ts → message-scroller-jrYN9dG9.d.ts} +2 -2
- package/dist/nuxt.d.ts +1 -1
- package/dist/nuxt.js +8 -2
- package/dist/parts/components/attachment.d.ts +1 -1
- package/dist/parts/components/avatar-stack.d.ts +1 -1
- package/dist/parts/components/avatar-stack.js +1 -1
- package/dist/parts/components/bubble.d.ts +1 -1
- package/dist/parts/components/chat-session.d.ts +1 -1
- package/dist/parts/components/code-block.d.ts +1 -1
- package/dist/parts/components/code-view.js +1 -1
- package/dist/parts/components/comment-composer.d.ts +1 -1
- package/dist/parts/components/comment-layer.d.ts +1 -1
- package/dist/parts/components/comment-layer.js +32 -19
- package/dist/parts/components/comment-list.d.ts +1 -1
- package/dist/parts/components/comment-list.js +3 -2
- package/dist/parts/components/comment-panel.d.ts +1 -1
- package/dist/parts/components/comment-panel.js +24 -12
- package/dist/parts/components/comment-pin.d.ts +1 -1
- package/dist/parts/components/comment-pin.js +1 -1
- package/dist/parts/components/comment-selection-bar.d.ts +2 -0
- package/dist/parts/components/comment-selection-bar.js +116 -0
- package/dist/parts/components/comment-thread.d.ts +2 -2
- package/dist/parts/components/comment-thread.js +33 -6
- package/dist/parts/components/comments.d.ts +8 -7
- package/dist/parts/components/comments.js +3 -2
- package/dist/parts/components/copy-button.d.ts +1 -1
- package/dist/parts/components/device-frame.d.ts +2 -2
- package/dist/parts/components/markdown-editor.d.ts +1 -1
- package/dist/parts/components/marker.d.ts +1 -1
- package/dist/parts/components/prompt-input.d.ts +3 -3
- package/dist/parts/components/tool-list.d.ts +1 -1
- package/dist/parts/components/trace-run.d.ts +1 -1
- package/dist/parts/components/trace-run.js +1 -1
- package/dist/parts/components/trace.d.ts +1 -1
- package/dist/parts/headless/comments.d.ts +2 -2
- package/dist/parts/headless/comments.js +1 -1
- package/dist/parts/headless/message-scroller.d.ts +1 -1
- package/dist/parts/workspace/browser-support-notice.d.ts +1 -1
- package/dist/parts/workspace/connect-panel.d.ts +1 -1
- package/dist/parts/workspace/playground-container.d.ts +2 -2
- package/dist/parts/workspace/workspace-boot-status.js +1 -1
- package/dist/parts/workspace/workspace-shell.d.ts +1 -1
- package/dist/{pierre-code-view-xgBL6DO7.js → pierre-code-view-NE35tkmR.js} +37 -17
- package/dist/styles.css +119 -1
- package/dist/{types-Dyr6CfBW.d.ts → types-Dj7vp0lZ.d.ts} +1 -1
- package/dist/workspace.d.ts +1 -1
- package/dist/workspace.js +1 -1
- package/package.json +7 -7
- package/dist/format-Du58PlsG.js +0 -18
|
@@ -35,7 +35,7 @@ const CommentPin = defineComponent({
|
|
|
35
35
|
if (props.draft) return "New comment";
|
|
36
36
|
const by = props.author ? ` by ${displayName(props.author)}` : "";
|
|
37
37
|
const text = props.excerpt ? `: ${props.excerpt}` : "";
|
|
38
|
-
return `Comment ${props.n}${by}${text}${props.status === "resolved" ? ", resolved" : ""}`;
|
|
38
|
+
return `Comment${props.n === void 0 ? "" : ` ${props.n}`}${by}${text}${props.status === "resolved" ? ", resolved" : ""}`;
|
|
39
39
|
};
|
|
40
40
|
let pointed = false;
|
|
41
41
|
let focused = false;
|
|
@@ -0,0 +1,116 @@
|
|
|
1
|
+
import { n as useTooltipComponent, r as useUIComponent } from "../../nuxt-ui-DSQFzq3s.js";
|
|
2
|
+
import { a as useViteHubUIIcons } from "../../config-Dk67emQt.js";
|
|
3
|
+
import { defineComponent, h, onErrorCaptured, onMounted, ref } from "vue";
|
|
4
|
+
//#region src/components/comment-selection-bar.ts
|
|
5
|
+
const TooltipOrTitle = defineComponent({
|
|
6
|
+
name: "CommentSelectionBarTooltip",
|
|
7
|
+
props: {
|
|
8
|
+
tooltip: {
|
|
9
|
+
required: true,
|
|
10
|
+
type: [Object, Function]
|
|
11
|
+
},
|
|
12
|
+
side: {
|
|
13
|
+
required: true,
|
|
14
|
+
type: String
|
|
15
|
+
},
|
|
16
|
+
content: {
|
|
17
|
+
required: true,
|
|
18
|
+
type: Function
|
|
19
|
+
},
|
|
20
|
+
trigger: {
|
|
21
|
+
required: true,
|
|
22
|
+
type: Function
|
|
23
|
+
},
|
|
24
|
+
title: {
|
|
25
|
+
required: true,
|
|
26
|
+
type: String
|
|
27
|
+
}
|
|
28
|
+
},
|
|
29
|
+
setup(props) {
|
|
30
|
+
const failed = ref(false);
|
|
31
|
+
let mounted = false;
|
|
32
|
+
onMounted(() => mounted = true);
|
|
33
|
+
onErrorCaptured(() => {
|
|
34
|
+
if (mounted || failed.value) return;
|
|
35
|
+
failed.value = true;
|
|
36
|
+
return false;
|
|
37
|
+
});
|
|
38
|
+
return () => failed.value ? props.trigger(props.title) : h(props.tooltip, { content: {
|
|
39
|
+
side: props.side,
|
|
40
|
+
sideOffset: 8
|
|
41
|
+
} }, {
|
|
42
|
+
content: props.content,
|
|
43
|
+
default: () => props.trigger()
|
|
44
|
+
});
|
|
45
|
+
}
|
|
46
|
+
});
|
|
47
|
+
/**
|
|
48
|
+
* The bar over selected text: Comment, and Suggest when the page takes suggested changes. It is the dark surface on a
|
|
49
|
+
* light page and its light twin on a dark one, so it stands out from the text. The page places it and listens for the
|
|
50
|
+
* keys. A press on the bar keeps the selection on the page.
|
|
51
|
+
*/
|
|
52
|
+
const CommentSelectionBar = defineComponent({
|
|
53
|
+
name: "CommentSelectionBar",
|
|
54
|
+
props: {
|
|
55
|
+
/** Show Suggest (E), for a page that takes suggested changes. */
|
|
56
|
+
suggest: {
|
|
57
|
+
default: false,
|
|
58
|
+
type: Boolean
|
|
59
|
+
},
|
|
60
|
+
/** The side of the text that the bar is on. The bar grows from that side, and its tooltips open away from the text. */
|
|
61
|
+
side: {
|
|
62
|
+
default: "top",
|
|
63
|
+
type: String
|
|
64
|
+
}
|
|
65
|
+
},
|
|
66
|
+
emits: ["comment", "suggest"],
|
|
67
|
+
setup(props, { emit }) {
|
|
68
|
+
const UIcon = useUIComponent("UIcon");
|
|
69
|
+
const UTooltip = useTooltipComponent();
|
|
70
|
+
const icons = useViteHubUIIcons();
|
|
71
|
+
const actions = () => [{
|
|
72
|
+
name: "comment",
|
|
73
|
+
label: "Comment",
|
|
74
|
+
hint: "Comment on the selected text",
|
|
75
|
+
key: "C",
|
|
76
|
+
icon: icons.value.comment
|
|
77
|
+
}, ...props.suggest ? [{
|
|
78
|
+
name: "suggest",
|
|
79
|
+
label: "Suggest",
|
|
80
|
+
hint: "Suggest new words",
|
|
81
|
+
key: "E",
|
|
82
|
+
icon: icons.value.edit
|
|
83
|
+
}] : []];
|
|
84
|
+
const button = (action, title) => h("button", {
|
|
85
|
+
"aria-keyshortcuts": action.key,
|
|
86
|
+
"data-action": action.name,
|
|
87
|
+
"data-slot": "comment-selection-bar-action",
|
|
88
|
+
onClick: () => action.name === "comment" ? emit("comment") : emit("suggest"),
|
|
89
|
+
title,
|
|
90
|
+
type: "button"
|
|
91
|
+
}, [h(UIcon, {
|
|
92
|
+
"aria-hidden": "true",
|
|
93
|
+
name: action.icon
|
|
94
|
+
}), action.label]);
|
|
95
|
+
return () => h("div", {
|
|
96
|
+
"aria-label": "Selected text",
|
|
97
|
+
"data-side": props.side,
|
|
98
|
+
"data-slot": "comment-selection-bar",
|
|
99
|
+
onMousedown: (event) => event.preventDefault(),
|
|
100
|
+
role: "group"
|
|
101
|
+
}, actions().map((action) => {
|
|
102
|
+
const title = `${action.hint} (${action.key})`;
|
|
103
|
+
if (!UTooltip) return button(action, title);
|
|
104
|
+
return h(TooltipOrTitle, {
|
|
105
|
+
content: () => [action.hint, h("kbd", { "data-slot": "comment-selection-bar-kbd" }, action.key)],
|
|
106
|
+
key: action.name,
|
|
107
|
+
side: props.side,
|
|
108
|
+
title,
|
|
109
|
+
tooltip: UTooltip,
|
|
110
|
+
trigger: (fallback) => button(action, fallback)
|
|
111
|
+
});
|
|
112
|
+
}));
|
|
113
|
+
}
|
|
114
|
+
});
|
|
115
|
+
//#endregion
|
|
116
|
+
export { CommentSelectionBar };
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { a as CommentReplySlots, c as
|
|
2
|
-
export { CommentAttachmentLink, CommentAttachmentUrl, CommentReply, CommentReplySlotScope, CommentReplySlots, CommentThread, CommentThreadSlotScope, CommentThreadSlots, messagesSinceResolved, repliedSinceResolved };
|
|
1
|
+
import { a as CommentReplySlots, c as CommentThreadSlotScope, d as repliedSinceResolved, i as CommentReplySlotScope, l as CommentThreadSlots, n as CommentAttachmentUrl, o as CommentStatusSlotScope, r as CommentReply, s as CommentThread, t as CommentAttachmentLink, u as messagesSinceResolved } from "../../comment-thread-DKJjmWN0.js";
|
|
2
|
+
export { CommentAttachmentLink, CommentAttachmentUrl, CommentReply, CommentReplySlotScope, CommentReplySlots, CommentStatusSlotScope, CommentThread, CommentThreadSlotScope, CommentThreadSlots, messagesSinceResolved, repliedSinceResolved };
|
|
@@ -7,7 +7,7 @@ import { t as ImagePreview } from "../../image-preview-C9tdkmEj.js";
|
|
|
7
7
|
import { a as pathOf, c as swallowNextClick, l as useDocumentPointerDown, n as injectComments, o as shakeDirtyComposers, r as consumedPointerEvents } from "../../comments-context-C2lOZyQ5.js";
|
|
8
8
|
import { a as writerName, o as writerPerson, t as displayName } from "../../comment-person-CLPlW_SS.js";
|
|
9
9
|
import { n as mentionPlugin, r as mentionTag, t as CommentComposer } from "../../comment-composer-jYv2ULNP.js";
|
|
10
|
-
import {
|
|
10
|
+
import { c as messagesSinceResolved, l as repliedSinceResolved, o as commentTitle, s as deliveryAttributes, t as defaultCommentCan } from "../../comments-D0d26ghV.js";
|
|
11
11
|
import { t as RelativeTime } from "../../relative-time-BVmjOsYG.js";
|
|
12
12
|
import { Marker, MarkerContent } from "./marker.js";
|
|
13
13
|
import { computed, defineComponent, h, nextTick, ref } from "vue";
|
|
@@ -195,11 +195,28 @@ const CommentReply = defineComponent({
|
|
|
195
195
|
if (!props.onDelete) return;
|
|
196
196
|
if (await run(() => props.onDelete?.(props.message.id))) confirming.value = false;
|
|
197
197
|
}
|
|
198
|
+
const statusOf = (message, delivery) => {
|
|
199
|
+
if (!slots.status) return null;
|
|
200
|
+
const outbox = comments?.outbox;
|
|
201
|
+
const current = () => !props.compact && props.message.id === message.id && props.message.delivery !== void 0;
|
|
202
|
+
const mayEdit = () => current() && props.editable;
|
|
203
|
+
const mayDelete = () => current() && (props.deletable ?? props.editable);
|
|
204
|
+
return h("div", { "data-slot": "comment-reply-status" }, slots.status({
|
|
205
|
+
delivery,
|
|
206
|
+
dismiss: outbox?.enabled && mayDelete() ? async () => mayDelete() && await outbox.dismiss(message.id) : void 0,
|
|
207
|
+
edit: outbox?.enabled && mayEdit() ? async (body, mentions) => mayEdit() && await outbox.edit(message.id, body, mentions) : void 0,
|
|
208
|
+
message,
|
|
209
|
+
retry: outbox?.enabled && mayEdit() ? async () => {
|
|
210
|
+
if (mayEdit()) await outbox.retry(message.id);
|
|
211
|
+
} : void 0
|
|
212
|
+
}));
|
|
213
|
+
};
|
|
198
214
|
return () => {
|
|
199
215
|
const { message } = props;
|
|
200
216
|
return h("div", {
|
|
201
217
|
"data-compact": props.compact ? "true" : void 0,
|
|
202
218
|
"data-editing": editing.value ? "true" : void 0,
|
|
219
|
+
...deliveryAttributes(message.delivery),
|
|
203
220
|
"data-size": props.size,
|
|
204
221
|
"data-slot": "comment-reply"
|
|
205
222
|
}, [h("div", { "data-slot": "comment-reply-content" }, [
|
|
@@ -245,6 +262,7 @@ const CommentReply = defineComponent({
|
|
|
245
262
|
value: message.body
|
|
246
263
|
}),
|
|
247
264
|
editing.value || props.compact ? null : slots.attachments?.({ message }) ?? attachmentList(message, props.attachmentUrl, UIcon, icons.value.file),
|
|
265
|
+
!editing.value && message.delivery ? statusOf(message, message.delivery) : null,
|
|
248
266
|
confirming.value ? h("div", {
|
|
249
267
|
"aria-label": "Confirm delete",
|
|
250
268
|
"data-slot": "comment-reply-confirm",
|
|
@@ -288,11 +306,14 @@ const CommentReply = defineComponent({
|
|
|
288
306
|
};
|
|
289
307
|
}
|
|
290
308
|
});
|
|
291
|
-
/** "Resolved by Ana", as a line across the thread. */
|
|
309
|
+
/** "Resolved by Ana", or "Resolved by Claude (Ana)" when her agent did, as a line across the thread. */
|
|
292
310
|
const resolvedMarker = (thread) => h(Marker, {
|
|
293
311
|
key: "resolved",
|
|
294
312
|
variant: "separator"
|
|
295
|
-
}, () => h(MarkerContent, () => `Resolved${thread.resolvedBy ? ` by ${
|
|
313
|
+
}, () => h(MarkerContent, () => `Resolved${thread.resolvedBy ? ` by ${writerName({
|
|
314
|
+
author: thread.resolvedBy,
|
|
315
|
+
...thread.resolvedActor ? { actor: thread.resolvedActor } : {}
|
|
316
|
+
})}` : ""}`));
|
|
296
317
|
const CommentThread = defineComponent({
|
|
297
318
|
name: "CommentThread",
|
|
298
319
|
props: {
|
|
@@ -445,6 +466,7 @@ const CommentThread = defineComponent({
|
|
|
445
466
|
const replySlots = () => ({
|
|
446
467
|
...slots.body ? { body: slots.body } : {},
|
|
447
468
|
...slots.attachments ? { attachments: slots.attachments } : {},
|
|
469
|
+
...slots.status ? { status: slots.status } : {},
|
|
448
470
|
...slots["mention-item"] ? { "mention-item": slots["mention-item"] } : {},
|
|
449
471
|
...slots["mention-empty"] ? { "mention-empty": slots["mention-empty"] } : {}
|
|
450
472
|
});
|
|
@@ -463,6 +485,7 @@ const CommentThread = defineComponent({
|
|
|
463
485
|
if (props.preview) {
|
|
464
486
|
const replies = thread.messages.length - 1;
|
|
465
487
|
return h("div", {
|
|
488
|
+
...deliveryAttributes(thread.delivery),
|
|
466
489
|
"data-preview": "true",
|
|
467
490
|
"data-size": props.size,
|
|
468
491
|
"data-slot": "comment-thread",
|
|
@@ -473,12 +496,16 @@ const CommentThread = defineComponent({
|
|
|
473
496
|
people: people.value,
|
|
474
497
|
size: props.size,
|
|
475
498
|
user: user.value
|
|
476
|
-
},
|
|
499
|
+
}, {
|
|
500
|
+
...slots.body ? { body: slots.body } : {},
|
|
501
|
+
...slots.status ? { status: slots.status } : {}
|
|
502
|
+
}) : null, replies > 0 ? h("p", { "data-slot": "comment-thread-count" }, `${replies} ${replies === 1 ? "reply" : "replies"}`) : null]);
|
|
477
503
|
}
|
|
478
504
|
const back = props.navigation === "back";
|
|
479
505
|
const anchor = slots.anchor ? slots.anchor({ thread }) : quote ? h("blockquote", { "data-slot": "comment-thread-quote" }, quote) : null;
|
|
480
506
|
return h("section", {
|
|
481
|
-
"aria-label":
|
|
507
|
+
"aria-label": commentTitle(thread),
|
|
508
|
+
...deliveryAttributes(thread.delivery),
|
|
482
509
|
"data-size": props.size,
|
|
483
510
|
"data-slot": "comment-thread",
|
|
484
511
|
"data-status": thread.status,
|
|
@@ -495,7 +522,7 @@ const CommentThread = defineComponent({
|
|
|
495
522
|
size: "xs",
|
|
496
523
|
variant: "ghost"
|
|
497
524
|
}) : null,
|
|
498
|
-
h("span", { "data-slot": "comment-thread-title" },
|
|
525
|
+
h("span", { "data-slot": "comment-thread-title" }, commentTitle(thread)),
|
|
499
526
|
h("span", { "data-slot": "comment-thread-spacer" }),
|
|
500
527
|
slots.actions ? h("div", { "data-slot": "comment-thread-actions" }, slots.actions({ thread })) : null,
|
|
501
528
|
!allowed("resolve") ? null : h(UButton, {
|
|
@@ -1,7 +1,8 @@
|
|
|
1
|
-
import { a as CommentComposerSubmit, c as CommentMentionItemScope, i as CommentComposerSlots, n as CommentComposerFrame, o as CommentComposerVariant, r as CommentComposerSize, s as CommentMentionEmptyScope, t as CommentComposer } from "../../comment-composer-
|
|
2
|
-
import { a as CommentReplySlots, c as
|
|
3
|
-
import { a as CommentPanelVariant, c as CommentUpload, i as CommentPanelSlots, n as CommentGroupSlotScope, o as CommentRowSlotScope, r as CommentPanel, s as CommentRowSlots, t as CommentGroup } from "../../comment-panel-
|
|
4
|
-
import { n as CommentPlacement, t as CommentLayer } from "../../comment-layer-
|
|
5
|
-
import { n as CommentList, r as CommentToolbar, t as CommentFilters } from "../../comment-list-
|
|
6
|
-
import { t as CommentPin } from "../../comment-pin-
|
|
7
|
-
|
|
1
|
+
import { a as CommentComposerSubmit, c as CommentMentionItemScope, i as CommentComposerSlots, n as CommentComposerFrame, o as CommentComposerVariant, r as CommentComposerSize, s as CommentMentionEmptyScope, t as CommentComposer } from "../../comment-composer-fINL5bxo.js";
|
|
2
|
+
import { a as CommentReplySlots, c as CommentThreadSlotScope, d as repliedSinceResolved, i as CommentReplySlotScope, l as CommentThreadSlots, n as CommentAttachmentUrl, o as CommentStatusSlotScope, r as CommentReply, s as CommentThread, t as CommentAttachmentLink, u as messagesSinceResolved } from "../../comment-thread-DKJjmWN0.js";
|
|
3
|
+
import { a as CommentPanelVariant, c as CommentUpload, i as CommentPanelSlots, n as CommentGroupSlotScope, o as CommentRowSlotScope, r as CommentPanel, s as CommentRowSlots, t as CommentGroup } from "../../comment-panel-CfvdRUMX.js";
|
|
4
|
+
import { n as CommentPlacement, t as CommentLayer } from "../../comment-layer-C_sbPIR5.js";
|
|
5
|
+
import { n as CommentList, r as CommentToolbar, t as CommentFilters } from "../../comment-list-BcSaLngS.js";
|
|
6
|
+
import { t as CommentPin } from "../../comment-pin-DHOdRvUw.js";
|
|
7
|
+
import { n as CommentSelectionBarSide, t as CommentSelectionBar } from "../../comment-selection-bar-CyVBNYl9.js";
|
|
8
|
+
export { CommentAttachmentLink, CommentAttachmentUrl, CommentComposer, CommentComposerFrame, CommentComposerSize, CommentComposerSlots, CommentComposerSubmit, CommentComposerVariant, CommentFilters, CommentGroup, CommentGroupSlotScope, CommentLayer, CommentList, CommentMentionEmptyScope, CommentMentionItemScope, CommentPanel, CommentPanelSlots, CommentPanelVariant, CommentPin, CommentPlacement, CommentReply, CommentReplySlotScope, CommentReplySlots, CommentRowSlotScope, CommentRowSlots, CommentSelectionBar, CommentSelectionBarSide, CommentStatusSlotScope, CommentThread, CommentThreadSlotScope, CommentThreadSlots, CommentToolbar, CommentUpload, messagesSinceResolved, repliedSinceResolved };
|
|
@@ -1,8 +1,9 @@
|
|
|
1
1
|
import { t as CommentComposer } from "../../comment-composer-jYv2ULNP.js";
|
|
2
|
-
import {
|
|
2
|
+
import { c as messagesSinceResolved, l as repliedSinceResolved } from "../../comments-D0d26ghV.js";
|
|
3
3
|
import { CommentFilters, CommentList, CommentToolbar } from "./comment-list.js";
|
|
4
4
|
import { CommentPin } from "./comment-pin.js";
|
|
5
5
|
import { CommentReply, CommentThread } from "./comment-thread.js";
|
|
6
6
|
import { CommentLayer } from "./comment-layer.js";
|
|
7
7
|
import { CommentPanel } from "./comment-panel.js";
|
|
8
|
-
|
|
8
|
+
import { CommentSelectionBar } from "./comment-selection-bar.js";
|
|
9
|
+
export { CommentComposer, CommentFilters, CommentLayer, CommentList, CommentPanel, CommentPin, CommentReply, CommentSelectionBar, CommentThread, CommentToolbar, messagesSinceResolved, repliedSinceResolved };
|
|
@@ -109,9 +109,9 @@ export declare const CopyButton: import("vue").DefineComponent<import("vue").Ext
|
|
|
109
109
|
}>, {
|
|
110
110
|
label: string;
|
|
111
111
|
size: CopyButtonSize;
|
|
112
|
+
variant: CopyButtonVariant;
|
|
112
113
|
icon: string;
|
|
113
114
|
preload: boolean;
|
|
114
|
-
variant: CopyButtonVariant;
|
|
115
115
|
ariaLabel: string;
|
|
116
116
|
duration: number;
|
|
117
117
|
}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
|
|
@@ -118,11 +118,11 @@ export declare const DeviceFrame: import("vue").DefineComponent<import("vue").Ex
|
|
|
118
118
|
}>> & Readonly<{
|
|
119
119
|
"onUpdate:modelValue"?: ((_size: DeviceFrameSize) => any) | undefined;
|
|
120
120
|
}>, {
|
|
121
|
+
disabled: boolean;
|
|
122
|
+
modelValue: DeviceFrameSize;
|
|
121
123
|
storageKey: string;
|
|
122
124
|
toolbar: boolean;
|
|
123
|
-
disabled: boolean;
|
|
124
125
|
defaultValue: Partial<DeviceFrameSize>;
|
|
125
|
-
modelValue: DeviceFrameSize;
|
|
126
126
|
presets: readonly DeviceFramePreset[];
|
|
127
127
|
breakpoints: readonly DeviceFrameBreakpoint[];
|
|
128
128
|
insetBottom: number;
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { n as MarkdownEditorUpload, r as blobUpload, t as MarkdownEditor } from "../../markdown-editor-
|
|
1
|
+
import { n as MarkdownEditorUpload, r as blobUpload, t as MarkdownEditor } from "../../markdown-editor-wQF0yD5o.js";
|
|
2
2
|
export { MarkdownEditor, MarkdownEditorUpload, blobUpload };
|
|
@@ -22,8 +22,8 @@ export declare const Marker: import("vue").DefineComponent<import("vue").Extract
|
|
|
22
22
|
type: PropType<MarkerVariant>;
|
|
23
23
|
};
|
|
24
24
|
}>> & Readonly<{}>, {
|
|
25
|
-
as: string | import("vue").Component;
|
|
26
25
|
variant: MarkerVariant;
|
|
26
|
+
as: string | import("vue").Component;
|
|
27
27
|
}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
|
|
28
28
|
export declare const MarkerIcon: import("vue").DefineComponent<{}, () => import("vue").VNode<import("vue").RendererNode, import("vue").RendererElement, {
|
|
29
29
|
[key: string]: any;
|
|
@@ -123,13 +123,13 @@ export declare const PromptInput: import("vue").DefineComponent<import("vue").Ex
|
|
|
123
123
|
onStop?: ((...args: any[]) => any) | undefined;
|
|
124
124
|
onReload?: ((...args: any[]) => any) | undefined;
|
|
125
125
|
}>, {
|
|
126
|
-
multiple: boolean;
|
|
127
126
|
disabled: boolean;
|
|
128
127
|
modelValue: string;
|
|
129
|
-
readonly: boolean;
|
|
130
128
|
status: ChatStatus;
|
|
131
|
-
|
|
129
|
+
multiple: boolean;
|
|
130
|
+
readonly: boolean;
|
|
132
131
|
attachments: boolean;
|
|
132
|
+
files: readonly FileUIPart[];
|
|
133
133
|
attachVariant: "ghost" | "outline";
|
|
134
134
|
filesDisabled: boolean;
|
|
135
135
|
}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { n as AgentToolInspection } from "../../types-
|
|
1
|
+
import { n as AgentToolInspection } from "../../types-Dj7vp0lZ.js";
|
|
2
2
|
import { PropType } from "vue";
|
|
3
3
|
//#region src/components/tool-list.d.ts
|
|
4
4
|
export declare const ToolList: import("vue").DefineComponent<import("vue").ExtractPropTypes<{
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { n as TraceRunView } from "../../index-
|
|
1
|
+
import { n as TraceRunView } from "../../index-BYRFQfCd.js";
|
|
2
2
|
import { PropType } from "vue";
|
|
3
3
|
//#region src/components/trace-run.d.ts
|
|
4
4
|
export declare const TraceRun: import("vue").DefineComponent<import("vue").ExtractPropTypes<{
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { r as useUIComponent } from "../../nuxt-ui-DSQFzq3s.js";
|
|
2
|
-
import { t as formatDuration } from "../../format-
|
|
2
|
+
import { t as formatDuration } from "../../format-orwcdZL_.js";
|
|
3
3
|
import { CodeBlock, CodeBlockContent } from "./code-block.js";
|
|
4
4
|
import { t as payloadText } from "../../payload-text-sjkYAwvw.js";
|
|
5
5
|
import { Trace, TraceCollapsible, TraceCollapsibleContent, TraceCollapsibleTrigger, TraceDescription, TraceIcon, TraceLine, TraceTitle } from "./trace.js";
|
|
@@ -49,8 +49,8 @@ export declare const TraceCollapsible: import("vue").DefineComponent<import("vue
|
|
|
49
49
|
}>> & Readonly<{
|
|
50
50
|
"onUpdate:open"?: ((_open: boolean) => any) | undefined;
|
|
51
51
|
}>, {
|
|
52
|
-
open: boolean;
|
|
53
52
|
defaultOpen: boolean;
|
|
53
|
+
open: boolean;
|
|
54
54
|
}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
|
|
55
55
|
export declare const TraceCollapsibleTrigger: import("vue").DefineComponent<{}, () => import("vue").VNode<import("vue").RendererNode, import("vue").RendererElement, {
|
|
56
56
|
[key: string]: any;
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { a as CommentThreadAction, c as
|
|
2
|
-
export { CommentCan, CommentDraft, CommentFilterState, CommentScope, CommentThreadAction, CommentsState, UseCommentsOptions, defaultCommentCan, draftPositionKey, provideComments, useComments, useCommentsContext };
|
|
1
|
+
import { a as CommentThreadAction, c as UseCommentsOptions, d as provideComments, f as useComments, i as CommentScope, l as defaultCommentCan, n as CommentDraft, o as CommentsOutboxState, p as useCommentsContext, r as CommentFilterState, s as CommentsState, t as CommentCan, u as draftPositionKey } from "../../comments-D8hulVPy.js";
|
|
2
|
+
export { CommentCan, CommentDraft, CommentFilterState, CommentScope, CommentThreadAction, CommentsOutboxState, CommentsState, UseCommentsOptions, defaultCommentCan, draftPositionKey, provideComments, useComments, useCommentsContext };
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { a as useCommentsContext, i as useComments, n as draftPositionKey, r as provideComments, t as defaultCommentCan } from "../../comments-
|
|
1
|
+
import { a as useCommentsContext, i as useComments, n as draftPositionKey, r as provideComments, t as defaultCommentCan } from "../../comments-D0d26ghV.js";
|
|
2
2
|
export { defaultCommentCan, draftPositionKey, provideComments, useComments, useCommentsContext };
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { a as MessageScrollerContent, c as MessageScrollerViewport, i as MessageScrollerButton, l as calculatePrependScrollTop, n as MessageScrollPosition, o as MessageScrollerContext, r as MessageScroller, s as MessageScrollerItem, t as MessageScrollBehavior, u as useMessageScroller } from "../../message-scroller-
|
|
1
|
+
import { a as MessageScrollerContent, c as MessageScrollerViewport, i as MessageScrollerButton, l as calculatePrependScrollTop, n as MessageScrollPosition, o as MessageScrollerContext, r as MessageScroller, s as MessageScrollerItem, t as MessageScrollBehavior, u as useMessageScroller } from "../../message-scroller-jrYN9dG9.js";
|
|
2
2
|
export { MessageScrollBehavior, MessageScrollPosition, MessageScroller, MessageScrollerButton, MessageScrollerContent, MessageScrollerContext, MessageScrollerItem, MessageScrollerViewport, calculatePrependScrollTop, useMessageScroller };
|
|
@@ -68,9 +68,9 @@ export declare const BrowserSupportNotice: import("vue").DefineComponent<import(
|
|
|
68
68
|
onCopied?: ((url: string) => any) | undefined;
|
|
69
69
|
}>, {
|
|
70
70
|
url: string;
|
|
71
|
-
description: string;
|
|
72
71
|
supported: boolean | undefined;
|
|
73
72
|
reason: string;
|
|
74
73
|
browser: UnsupportedBrowser;
|
|
74
|
+
description: string;
|
|
75
75
|
}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
|
|
76
76
|
//#endregion
|
|
@@ -122,8 +122,8 @@ export declare const ConnectPanel: import("vue").DefineComponent<import("vue").E
|
|
|
122
122
|
"onCopy-command"?: ((command: string) => any) | undefined;
|
|
123
123
|
"onRemove-all"?: (() => any) | undefined;
|
|
124
124
|
}>, {
|
|
125
|
-
empty: string;
|
|
126
125
|
relayUrl: string;
|
|
127
126
|
states: Partial<Record<ConnectProviderName, ConnectProviderState>>;
|
|
127
|
+
empty: string;
|
|
128
128
|
}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
|
|
129
129
|
//#endregion
|
|
@@ -174,15 +174,15 @@ export declare const PlaygroundContainer: import("vue").DefineComponent<import("
|
|
|
174
174
|
};
|
|
175
175
|
}>> & Readonly<{
|
|
176
176
|
"onUpdate:open"?: ((open: boolean) => any) | undefined;
|
|
177
|
-
"onUpdate:selected"?: ((path: string) => any) | undefined;
|
|
178
177
|
onContext?: ((context: PlaygroundContext) => any) | undefined;
|
|
178
|
+
"onUpdate:selected"?: ((path: string) => any) | undefined;
|
|
179
179
|
"onUpdate:template"?: ((id: string) => any) | undefined;
|
|
180
180
|
}>, {
|
|
181
181
|
name: string;
|
|
182
182
|
label: string;
|
|
183
183
|
template: string;
|
|
184
|
-
layout: WorkspaceLayout;
|
|
185
184
|
open: boolean;
|
|
185
|
+
layout: WorkspaceLayout;
|
|
186
186
|
selected: string;
|
|
187
187
|
connect: Connect;
|
|
188
188
|
tabs: readonly WorkspaceTabItem[];
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { t as formatDuration } from "../../format-
|
|
1
|
+
import { t as formatDuration } from "../../format-orwcdZL_.js";
|
|
2
2
|
import { icon } from "./icons.js";
|
|
3
3
|
import { computed, defineComponent, h, onBeforeUnmount, ref, watch } from "vue";
|
|
4
4
|
//#region src/workspace/workspace-boot-status.ts
|
|
@@ -79,8 +79,8 @@ export declare const WorkspaceShell: import("vue").DefineComponent<import("vue")
|
|
|
79
79
|
}>> & Readonly<{
|
|
80
80
|
"onUpdate:tab"?: ((tab: WorkspaceTab) => any) | undefined;
|
|
81
81
|
}>, {
|
|
82
|
-
storageKey: string | false;
|
|
83
82
|
label: string;
|
|
83
|
+
storageKey: string | false;
|
|
84
84
|
layout: WorkspaceLayout;
|
|
85
85
|
tab: WorkspaceTab;
|
|
86
86
|
tabs: readonly WorkspaceTabItem[];
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { n as __exportAll } from "./rolldown-runtime-C9mWXvCC.js";
|
|
2
|
-
import { s as pierrePropTypes } from "./code-view-
|
|
2
|
+
import { s as pierrePropTypes } from "./code-view-DsU-xzic.js";
|
|
3
3
|
import { A as SPLIT_WITH_NEWLINES, C as DIFFS_SCROLLBAR_GUTTER_MEASURED_PROPERTY, D as HEADER_FILENAME_SUFFIX_SLOT_ID, E as EMPTY_RENDER_RANGE, M as UNSAFE_CSS_ATTRIBUTE, O as HEADER_METADATA_SLOT_ID, S as DIFFS_DEVELOPMENT_BUILD, T as DIFFS_TAG_NAME, _ as DEFAULT_RENDER_RANGE, b as DEFAULT_TOKENIZE_MAX_LENGTH, c as composeCacheKey, d as CODE_VIEW_FOOTER_ATTRIBUTE, f as CODE_VIEW_HEADER_ATTRIBUTE, g as DEFAULT_EXPANDED_REGION, h as DEFAULT_CODE_VIEW_LAYOUT, i as diffChars, j as THEME_CSS_ATTRIBUTE, k as HEADER_PREFIX_SLOT_ID, l as getHunkSideEndBoundary, m as DEFAULT_CODE_VIEW_FILE_METRICS, n as parseDiffFromFile, o as slideBlankBoundaryBlocksUp, p as CUSTOM_HEADER_SLOT_ID, r as diffWordsWithSpace, s as cleanLastNewline, t as getSingularPatch, u as getHunkSideStartBoundary, v as DEFAULT_SMOOTH_SCROLL_SETTINGS, w as DIFFS_SCROLLBAR_MEASURE_ATTRIBUTE, x as DEFAULT_VIRTUAL_FILE_METRICS, y as DEFAULT_THEMES } from "./getSingularPatch-Dsb8EgxR.js";
|
|
4
4
|
import { computed, defineComponent, h, onBeforeUnmount, toRaw, watchEffect } from "vue";
|
|
5
5
|
import { bundledLanguages, createHighlighter, createJavaScriptRegexEngine, createOnigurumaEngine } from "shiki";
|
|
@@ -19675,6 +19675,9 @@ function rangeKey(range) {
|
|
|
19675
19675
|
range.endSide
|
|
19676
19676
|
];
|
|
19677
19677
|
}
|
|
19678
|
+
function snapshotSelection(range) {
|
|
19679
|
+
return range === null ? null : { ...range };
|
|
19680
|
+
}
|
|
19678
19681
|
function controlledOptions(options, selectedLines) {
|
|
19679
19682
|
const rawOptions = trackShallow(options);
|
|
19680
19683
|
return selectedLines === void 0 ? rawOptions : {
|
|
@@ -19707,6 +19710,13 @@ function trackArrayItems(values) {
|
|
|
19707
19710
|
for (const value of values) trackShallow(value);
|
|
19708
19711
|
return toRaw(values);
|
|
19709
19712
|
}
|
|
19713
|
+
/**
|
|
19714
|
+
* The annotations to pass to Pierre. Pierre compares annotation lists by reference, so the list is a new array only
|
|
19715
|
+
* when the prop or one of its items changes, and the same array when the view renders for another reason.
|
|
19716
|
+
*/
|
|
19717
|
+
function useLineAnnotations(read) {
|
|
19718
|
+
return computed(() => [...trackArrayItems(read()) ?? []]);
|
|
19719
|
+
}
|
|
19710
19720
|
function copyFile(file) {
|
|
19711
19721
|
return file === null ? null : { ...file };
|
|
19712
19722
|
}
|
|
@@ -19734,28 +19744,34 @@ const PierreDiff = defineComponent({
|
|
|
19734
19744
|
let host = null;
|
|
19735
19745
|
let instance;
|
|
19736
19746
|
const selectionScroll = createSelectionScroll(() => host, () => instance?.isSourceRendered() ?? false);
|
|
19737
|
-
const
|
|
19738
|
-
|
|
19739
|
-
if (props.
|
|
19740
|
-
if (props.
|
|
19747
|
+
const lineAnnotations = useLineAnnotations(() => props.lineAnnotations);
|
|
19748
|
+
const diffInput = computed(() => {
|
|
19749
|
+
if (props.fileDiff) return { diff: trackShallow(props.fileDiff) };
|
|
19750
|
+
if (props.patch !== void 0) return { diff: getSingularPatch(props.patch) };
|
|
19751
|
+
if (props.oldFile !== void 0 && props.newFile !== void 0) return { diff: parseDiffFromFile(copyFile(props.oldFile), copyFile(props.newFile), copyParseDiffOptions(props.options?.parseDiffOptions)) };
|
|
19741
19752
|
});
|
|
19753
|
+
let renderedInput;
|
|
19742
19754
|
const render = () => {
|
|
19743
19755
|
if (!host) return;
|
|
19744
|
-
|
|
19756
|
+
const input = diffInput.value;
|
|
19757
|
+
if (!input) {
|
|
19745
19758
|
instance?.cleanUp();
|
|
19746
19759
|
instance = void 0;
|
|
19760
|
+
renderedInput = void 0;
|
|
19747
19761
|
return;
|
|
19748
19762
|
}
|
|
19749
|
-
const options = accessibleDiffOptions(props.options, props.selectedLines,
|
|
19763
|
+
const options = accessibleDiffOptions(props.options, props.selectedLines, input.diff);
|
|
19750
19764
|
if (!instance) instance = new SelectionDiffModel(options, void 0, true);
|
|
19765
|
+
const forceRender = renderedInput !== void 0 && renderedInput !== input || !areOptionsEqual(instance.options, options);
|
|
19751
19766
|
instance.setOptions(options);
|
|
19752
19767
|
instance.render({
|
|
19753
19768
|
fileContainer: host,
|
|
19754
|
-
fileDiff:
|
|
19755
|
-
forceRender
|
|
19756
|
-
lineAnnotations:
|
|
19769
|
+
fileDiff: input.diff,
|
|
19770
|
+
forceRender,
|
|
19771
|
+
lineAnnotations: lineAnnotations.value
|
|
19757
19772
|
});
|
|
19758
|
-
|
|
19773
|
+
renderedInput = input;
|
|
19774
|
+
if (props.selectedLines !== void 0) instance.setSelectedLines(snapshotSelection(props.selectedLines));
|
|
19759
19775
|
selectionScroll.sync(props.scrollToSelectedLines ? props.selectedLines : void 0, [
|
|
19760
19776
|
toRaw(props.fileDiff),
|
|
19761
19777
|
props.patch,
|
|
@@ -19794,6 +19810,7 @@ const PierreFile = defineComponent({
|
|
|
19794
19810
|
let host = null;
|
|
19795
19811
|
let instance;
|
|
19796
19812
|
const selectionScroll = createSelectionScroll(() => host, () => instance?.isSourceRendered() ?? false);
|
|
19813
|
+
const lineAnnotations = useLineAnnotations(() => props.lineAnnotations);
|
|
19797
19814
|
const file = computed(() => props.file ? copyFile(props.file) : void 0);
|
|
19798
19815
|
const render = () => {
|
|
19799
19816
|
if (!host) return;
|
|
@@ -19804,14 +19821,15 @@ const PierreFile = defineComponent({
|
|
|
19804
19821
|
}
|
|
19805
19822
|
const options = accessibleOptions(props.options, props.selectedLines);
|
|
19806
19823
|
if (!instance) instance = new SelectionFileModel(options, void 0, true);
|
|
19824
|
+
const forceRender = !areOptionsEqual(instance.options, options);
|
|
19807
19825
|
instance.setOptions(options);
|
|
19808
19826
|
instance.render({
|
|
19809
19827
|
file: file.value,
|
|
19810
19828
|
fileContainer: host,
|
|
19811
|
-
forceRender
|
|
19812
|
-
lineAnnotations:
|
|
19829
|
+
forceRender,
|
|
19830
|
+
lineAnnotations: lineAnnotations.value
|
|
19813
19831
|
});
|
|
19814
|
-
if (props.selectedLines !== void 0) instance.setSelectedLines(
|
|
19832
|
+
if (props.selectedLines !== void 0) instance.setSelectedLines(snapshotSelection(props.selectedLines));
|
|
19815
19833
|
selectionScroll.sync(props.scrollToSelectedLines ? props.selectedLines : void 0, [file.value.name, file.value.contents]);
|
|
19816
19834
|
};
|
|
19817
19835
|
const setHost = (node) => {
|
|
@@ -19844,6 +19862,7 @@ const PierreUnresolvedFile = defineComponent({
|
|
|
19844
19862
|
let instance;
|
|
19845
19863
|
const selectionScroll = createSelectionScroll(() => host, () => instance?.isSourceRendered() ?? false);
|
|
19846
19864
|
let renderedFile;
|
|
19865
|
+
const lineAnnotations = useLineAnnotations(() => props.lineAnnotations);
|
|
19847
19866
|
const file = computed(() => props.file ? copyFile(props.file) : void 0);
|
|
19848
19867
|
const render = () => {
|
|
19849
19868
|
if (!host) return;
|
|
@@ -19859,15 +19878,16 @@ const PierreUnresolvedFile = defineComponent({
|
|
|
19859
19878
|
}
|
|
19860
19879
|
const options = accessibleOptions(props.options, props.selectedLines);
|
|
19861
19880
|
if (!instance) instance = new SelectionUnresolvedFileModel(options, void 0, true);
|
|
19881
|
+
const forceRender = !areOptionsEqual(instance.options, options);
|
|
19862
19882
|
instance.setOptions(options);
|
|
19863
19883
|
instance.render({
|
|
19864
19884
|
file: file.value,
|
|
19865
19885
|
fileContainer: host,
|
|
19866
|
-
forceRender
|
|
19867
|
-
lineAnnotations:
|
|
19886
|
+
forceRender,
|
|
19887
|
+
lineAnnotations: lineAnnotations.value
|
|
19868
19888
|
});
|
|
19869
19889
|
renderedFile = file.value;
|
|
19870
|
-
if (props.selectedLines !== void 0) instance.setSelectedLines(
|
|
19890
|
+
if (props.selectedLines !== void 0) instance.setSelectedLines(snapshotSelection(props.selectedLines));
|
|
19871
19891
|
selectionScroll.sync(props.scrollToSelectedLines ? props.selectedLines : void 0, [file.value.name, file.value.contents]);
|
|
19872
19892
|
};
|
|
19873
19893
|
const setHost = (node) => {
|