@adecore/agents-react 0.44.4 → 0.45.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/dist/chat/logic/timeline.d.ts +2 -0
- package/dist/chat/logic/timeline.js +16 -6
- package/dist/chat/ui/Composer.js +345 -327
- package/dist/chat/ui/SubagentTimeline.js +4 -1
- package/dist/chat/ui/Timeline.js +5 -3
- package/dist/chat/ui/rows/Rows.js +58 -56
- package/dist/chat/ui/rows/SubagentRow.js +88 -68
- package/dist/chat/ui/rows/WorkRows.d.ts +2 -1
- package/dist/chat/ui/rows/WorkRows.js +116 -83
- package/dist/host-hooks.d.ts +1 -0
- package/dist/host-hooks.js +3 -0
- package/dist/host.d.ts +8 -0
- package/dist/host.js +1 -0
- package/dist/index.d.ts +1 -1
- package/package.json +8 -8
- package/src/chat/logic/timeline.ts +21 -7
- package/src/chat/ui/Composer.tsx +1 -0
- package/src/chat/ui/SubagentTimeline.tsx +5 -1
- package/src/chat/ui/Timeline.tsx +6 -3
- package/src/chat/ui/rows/Rows.tsx +10 -1
- package/src/chat/ui/rows/SubagentRow.tsx +12 -3
- package/src/chat/ui/rows/WorkRows.tsx +22 -11
- package/src/host-hooks.ts +4 -0
- package/src/host.ts +14 -0
- package/src/index.ts +1 -0
package/src/host.ts
CHANGED
|
@@ -172,6 +172,15 @@ export interface ComposerSlotProps {
|
|
|
172
172
|
insert(text: string): void;
|
|
173
173
|
}
|
|
174
174
|
|
|
175
|
+
/* What an app's own bar over the composer gets: the chat it stands on, which may be one the bar has nothing for. */
|
|
176
|
+
export interface ComposerHeaderSlotProps {
|
|
177
|
+
scopeId: string;
|
|
178
|
+
chatId: string;
|
|
179
|
+
disabled: boolean;
|
|
180
|
+
/* Whether this composer has the focus; a bar keeps its controls out of the tab order while it does not, as the editor does. */
|
|
181
|
+
focused: boolean;
|
|
182
|
+
}
|
|
183
|
+
|
|
175
184
|
/* What a send action of the app's gets: the message as it stands when a person picks the action. */
|
|
176
185
|
export interface ComposerSendDraft {
|
|
177
186
|
scopeId: string;
|
|
@@ -402,6 +411,8 @@ export interface ChatHost {
|
|
|
402
411
|
useStreaming(): 'words' | 'blocks' | 'whole';
|
|
403
412
|
/* How Send handles a running turn; Option or Alt selects the other behavior. */
|
|
404
413
|
useSendDelivery(): 'queue' | 'steer';
|
|
414
|
+
/* Whether a thread leaves out its tool lines; a settled turn still says how long it worked. */
|
|
415
|
+
useHidesToolCalls(scopeId: string, chatId: string): boolean;
|
|
405
416
|
/* Paths in an answer as links; null leaves them text. */
|
|
406
417
|
fileLinks: {
|
|
407
418
|
/* The reference a piece of text names, where the folder it counts from lets it be opened. */
|
|
@@ -479,6 +490,8 @@ export interface ChatHost {
|
|
|
479
490
|
useComposerPlaceholder(scopeId: string, chatId: string): string | null;
|
|
480
491
|
/* The app's own control in the composer's row, after the pickers; null draws none. */
|
|
481
492
|
ComposerSlot: ComponentType<ComposerSlotProps> | null;
|
|
493
|
+
/* The app's own bar at the top of the composer, inside its card, such as a switch between chats of one thing; left out, or a slot that renders nothing, draws none. */
|
|
494
|
+
ComposerHeaderSlot?: ComponentType<ComposerHeaderSlotProps> | null;
|
|
482
495
|
/* Actions of the app's own behind a chevron on the send button, in the order given; left out, or none, Send stands alone. */
|
|
483
496
|
useComposerSendActions?(scopeId: string, chatId: string): readonly ComposerSendAction[];
|
|
484
497
|
/* The app's own chips for a chat's sub-agents over the composer; null draws the one flyout. */
|
|
@@ -514,6 +527,7 @@ const DEFAULT_HOST: ChatHost = {
|
|
|
514
527
|
code: { useMode: () => 'light', useThemes: () => ({ light: 'github-light', dark: 'github-dark' }), custom: [] },
|
|
515
528
|
useStreaming: () => 'words',
|
|
516
529
|
useSendDelivery: () => 'queue',
|
|
530
|
+
useHidesToolCalls: () => false,
|
|
517
531
|
fileLinks: null,
|
|
518
532
|
useTimelineFind: () => NO_FIND,
|
|
519
533
|
dictation: { Textarea: PlainTextarea, composer: null },
|