@m6d/cortex-angular 1.9.0 → 1.10.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.
|
@@ -4462,7 +4462,7 @@ class MessageComponent {
|
|
|
4462
4462
|
isAborted = computed(() => Boolean(this.metadata()?.isAborted), ...ngDevMode ? [{ debugName: "isAborted" }] : []);
|
|
4463
4463
|
tokenUsage = computed(() => this.metadata()?.tokenUsage, ...ngDevMode ? [{ debugName: "tokenUsage" }] : []);
|
|
4464
4464
|
modelId = computed(() => this.metadata()?.modelId, ...ngDevMode ? [{ debugName: "modelId" }] : []);
|
|
4465
|
-
attachments = computed(() => this.
|
|
4465
|
+
attachments = computed(() => this.metadata()?.attachments ?? [], ...ngDevMode ? [{ debugName: "attachments" }] : []);
|
|
4466
4466
|
showsDebugZone = computed(() => {
|
|
4467
4467
|
if (!this.debugMode() || this.isStreaming())
|
|
4468
4468
|
return false;
|
|
@@ -4480,7 +4480,7 @@ class MessageComponent {
|
|
|
4480
4480
|
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.2.3", type: MessageComponent, isStandalone: true, selector: "cortex-message", inputs: { message: { classPropertyName: "message", publicName: "message", isSignal: true, isRequired: true, transformFunction: null }, debugMode: { classPropertyName: "debugMode", publicName: "debugMode", isSignal: true, isRequired: false, transformFunction: null }, animate: { classPropertyName: "animate", publicName: "animate", isSignal: true, isRequired: false, transformFunction: null } }, host: { classAttribute: "cortex-message" }, ngImport: i0, template: `<!-- fallow-ignore-file complexity -- the message template branches once per envelope kind, trigger included -->
|
|
4481
4481
|
@if (trigger(); as firing) {
|
|
4482
4482
|
<cortex-trigger-block [firing]="firing" [debugMode]="debugMode()" />
|
|
4483
|
-
} @else if (visibleParts().length) {
|
|
4483
|
+
} @else if (visibleParts().length || attachments().length) {
|
|
4484
4484
|
<div class="cortex-message-parts">
|
|
4485
4485
|
@for (part of visibleParts(); track $index) {
|
|
4486
4486
|
<cortex-message-part
|
|
@@ -4527,7 +4527,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.3", ngImpor
|
|
|
4527
4527
|
], host: { class: "cortex-message" }, template: `<!-- fallow-ignore-file complexity -- the message template branches once per envelope kind, trigger included -->
|
|
4528
4528
|
@if (trigger(); as firing) {
|
|
4529
4529
|
<cortex-trigger-block [firing]="firing" [debugMode]="debugMode()" />
|
|
4530
|
-
} @else if (visibleParts().length) {
|
|
4530
|
+
} @else if (visibleParts().length || attachments().length) {
|
|
4531
4531
|
<div class="cortex-message-parts">
|
|
4532
4532
|
@for (part of visibleParts(); track $index) {
|
|
4533
4533
|
<cortex-message-part
|
package/package.json
CHANGED
|
@@ -12,13 +12,19 @@ declare const ATTACHMENT_STATUSES: readonly [
|
|
|
12
12
|
"failed",
|
|
13
13
|
"skipped"
|
|
14
14
|
];
|
|
15
|
+
declare const ATTACHMENT_ORIGINS: readonly [
|
|
16
|
+
"upload",
|
|
17
|
+
"tool"
|
|
18
|
+
];
|
|
15
19
|
export type AttachmentStatus = (typeof ATTACHMENT_STATUSES)[number];
|
|
20
|
+
export type AttachmentOrigin = (typeof ATTACHMENT_ORIGINS)[number];
|
|
16
21
|
export type AttachmentSummary = {
|
|
17
22
|
id: string;
|
|
18
23
|
filename: string;
|
|
19
24
|
contentType: string;
|
|
20
25
|
sizeBytes: number;
|
|
21
26
|
status: AttachmentStatus;
|
|
27
|
+
origin: AttachmentOrigin;
|
|
22
28
|
description?: string;
|
|
23
29
|
};
|
|
24
30
|
export type ThreadSummary = {
|
|
@@ -55,6 +61,8 @@ export type ClientToolBinding = {
|
|
|
55
61
|
toolId: string;
|
|
56
62
|
surface: "inline" | "modal";
|
|
57
63
|
embedOrigin: string;
|
|
64
|
+
/** Variables the initiate call's input reads. */
|
|
65
|
+
variables: string[];
|
|
58
66
|
};
|
|
59
67
|
/**
|
|
60
68
|
* What the server offers this agent's clients, fetched once at widget startup.
|
|
@@ -175,13 +183,19 @@ declare const ATTACHMENT_STATUSES$1: readonly [
|
|
|
175
183
|
"failed",
|
|
176
184
|
"skipped"
|
|
177
185
|
];
|
|
186
|
+
declare const ATTACHMENT_ORIGINS$1: readonly [
|
|
187
|
+
"upload",
|
|
188
|
+
"tool"
|
|
189
|
+
];
|
|
178
190
|
type AttachmentStatus$1 = (typeof ATTACHMENT_STATUSES$1)[number];
|
|
191
|
+
type AttachmentOrigin$1 = (typeof ATTACHMENT_ORIGINS$1)[number];
|
|
179
192
|
type AttachmentSummary$1 = {
|
|
180
193
|
id: string;
|
|
181
194
|
filename: string;
|
|
182
195
|
contentType: string;
|
|
183
196
|
sizeBytes: number;
|
|
184
197
|
status: AttachmentStatus$1;
|
|
198
|
+
origin: AttachmentOrigin$1;
|
|
185
199
|
description?: string;
|
|
186
200
|
};
|
|
187
201
|
declare class AttachmentQueueService {
|