teodor-new-chat-ui 4.3.352 → 4.3.354
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/components/chat/message-components/StreamProgress.d.ts +7 -0
- package/dist/components/chat/message-components/ToolComponent.d.ts +2 -1
- package/dist/components/chat/message-components/index.d.ts +1 -1
- package/dist/context/reducers/MessageReducer.d.ts +17 -0
- package/dist/index.esm.js +3320 -3262
- package/dist/index.umd.js +43 -43
- package/package.json +1 -1
- package/dist/components/chat/message-components/StreamComponent.d.ts +0 -8
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import type { ChatMessage } from "@/types/api";
|
|
2
|
+
interface StreamProgressProps {
|
|
3
|
+
message: ChatMessage;
|
|
4
|
+
isStreaming?: boolean;
|
|
5
|
+
}
|
|
6
|
+
export declare function StreamProgress({ message, isStreaming }: StreamProgressProps): import("react/jsx-runtime").JSX.Element | null;
|
|
7
|
+
export {};
|
|
@@ -2,6 +2,7 @@ import type { ChatMessage } from "@/types/api";
|
|
|
2
2
|
interface ToolComponentProps {
|
|
3
3
|
message: ChatMessage;
|
|
4
4
|
viewMode: "preview" | "expanded";
|
|
5
|
+
isStreaming?: boolean;
|
|
5
6
|
}
|
|
6
|
-
export declare function ToolComponent({ message, viewMode }: ToolComponentProps): import("react/jsx-runtime").JSX.Element
|
|
7
|
+
export declare function ToolComponent({ message, viewMode, isStreaming }: ToolComponentProps): import("react/jsx-runtime").JSX.Element;
|
|
7
8
|
export {};
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
export { ArtifactPreviewItem } from "./ArtifactPreviewItem";
|
|
2
2
|
export { InterruptPartRenderer } from "./InterruptPartRenderer";
|
|
3
3
|
export { SimpleJsonView } from "./SimpleJsonView";
|
|
4
|
-
export {
|
|
4
|
+
export { StreamProgress } from "./StreamProgress";
|
|
5
5
|
export { ToolComponent } from "./ToolComponent";
|
|
6
6
|
export { useFilePreview } from "./useFilePreview";
|
|
7
7
|
export { UserTextContent } from "./UserTextContent";
|
|
@@ -11,6 +11,7 @@ export interface MessagesState {
|
|
|
11
11
|
type: "branch";
|
|
12
12
|
}> | null;
|
|
13
13
|
pendingInterrupt: PendingInterrupt;
|
|
14
|
+
toolTimelines: Record<string, ToolStreamEntry[]>;
|
|
14
15
|
messagesStreamMeta?: Record<string, {
|
|
15
16
|
lastSeq?: number | null;
|
|
16
17
|
lastText?: string;
|
|
@@ -73,4 +74,20 @@ export declare function useMessagesReducer(initial?: ChatMessage[]): {
|
|
|
73
74
|
readonly state: MessagesState;
|
|
74
75
|
readonly dispatch: import("react").Dispatch<MessagesAction>;
|
|
75
76
|
};
|
|
77
|
+
type ToolStreamEntryType = "tool.start" | "tool.call" | "progress" | "custom" | "tool.end";
|
|
78
|
+
interface ToolStreamEntry {
|
|
79
|
+
id: string;
|
|
80
|
+
idx: number;
|
|
81
|
+
type: ToolStreamEntryType;
|
|
82
|
+
toolId?: string;
|
|
83
|
+
toolName?: string;
|
|
84
|
+
step?: string | null;
|
|
85
|
+
title?: string | null;
|
|
86
|
+
content?: string | null;
|
|
87
|
+
factsFound?: number | null;
|
|
88
|
+
isSufficient?: boolean | null;
|
|
89
|
+
metadata?: Record<string, unknown>;
|
|
90
|
+
timestamp: string;
|
|
91
|
+
}
|
|
76
92
|
export declare function computeSuffix(existing: string, incoming: string): string;
|
|
93
|
+
export {};
|