teodor-new-chat-ui 4.3.387 → 4.3.389
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/api/chat-api.d.ts +1 -2
- package/dist/components/chat/ThreadManager.d.ts +5 -1
- package/dist/context/providers/ChatSessionProvider.d.ts +1 -4
- package/dist/hooks/useThreadsState.d.ts +1 -4
- package/dist/index.esm.js +5312 -5361
- package/dist/index.umd.js +41 -41
- package/dist/lib/historyUtils.d.ts +0 -16
- package/dist/lib/index.d.ts +1 -1
- package/dist/types/index.d.ts +0 -1
- package/dist/types/models.d.ts +11 -0
- package/package.json +1 -1
- package/dist/types/user.d.ts +0 -21
|
@@ -10,19 +10,3 @@ export type HistoryHydrationResult = {
|
|
|
10
10
|
};
|
|
11
11
|
export declare function buildSnapshotKey(checkpointId: string | null | undefined, checkpointNs: string | null | undefined): string;
|
|
12
12
|
export declare function hydrateHistorySnapshots(history: HistoryPayload | null | undefined): HistoryHydrationResult;
|
|
13
|
-
/**
|
|
14
|
-
* Finds the checkpoint preceding a given user message ID by looking for
|
|
15
|
-
* the last checkpoint that does NOT have the same last user message ID.
|
|
16
|
-
*
|
|
17
|
-
* This is used during edits to find the previous step in the conversation,
|
|
18
|
-
* ensuring we get a checkpoint from before the current attempt group.
|
|
19
|
-
*
|
|
20
|
-
* Matching user message IDs across checkpoints indicate a regeneration/retry
|
|
21
|
-
* (same user input, different assistant responses). This function finds the
|
|
22
|
-
* checkpoint that precedes this group.
|
|
23
|
-
*
|
|
24
|
-
* @param checkpoints - Array of HydratedCheckpointSnapshot objects (assumed sorted newest first)
|
|
25
|
-
* @param userMessageId - The ID of the current user message
|
|
26
|
-
* @returns The previous checkpoint (from a different attempt group), or null if none found
|
|
27
|
-
*/
|
|
28
|
-
export declare function findCheckpointBeforeUserMessage(checkpoints: HydratedCheckpointSnapshot[], userMessageId: string | null | undefined): HydratedCheckpointSnapshot | null;
|
package/dist/lib/index.d.ts
CHANGED
|
@@ -23,7 +23,7 @@ export type { ChatConfig } from "@/config/env";
|
|
|
23
23
|
export { del, get, getChatToken, onChatTokenChanged, post, put, setChatToken } from '../api/utils';
|
|
24
24
|
export { ChatSettings } from '@/components/settings/ChatSettings';
|
|
25
25
|
export type { ChatSettingsConfig } from '@/components/settings/ChatSettings';
|
|
26
|
-
export type { ChatMessage, ChatRequest, CheckpointSnapshot, HistoryPayload, HydratedCheckpointSnapshot, MessagePart, PregelTask, Role, StreamEvent, TextPart, ThreadInfo, ThreadSummary, ToolEndEvent } from '@/types';
|
|
26
|
+
export type { ChatMessage, ChatRequest, CheckpointSnapshot, HistoryPayload, HydratedCheckpointSnapshot, MessagePart, PregelTask, Role, StreamEvent, TextPart, ThreadInfo, ThreadShareTarget, ThreadSummary, ToolEndEvent } from '@/types';
|
|
27
27
|
export { buildMessagePreviewMap } from './messagePreviews';
|
|
28
28
|
export type { ChatAppProps, SimpleChatProps } from '../components/chat/ChatApp';
|
|
29
29
|
export type { ChatProvidersProps } from '../context/ChatProviders';
|
package/dist/types/index.d.ts
CHANGED
package/dist/types/models.d.ts
CHANGED
|
@@ -171,6 +171,17 @@ export interface ThreadShareResponse {
|
|
|
171
171
|
sharedWithUserId: string;
|
|
172
172
|
sharedAt: string;
|
|
173
173
|
}
|
|
174
|
+
/**
|
|
175
|
+
* Generic share target for thread sharing.
|
|
176
|
+
* Allows host applications to define their own user model and map it here.
|
|
177
|
+
* ThreadManager is agnostic to the user model structure.
|
|
178
|
+
*/
|
|
179
|
+
export interface ThreadShareTarget {
|
|
180
|
+
id: string;
|
|
181
|
+
label: string;
|
|
182
|
+
secondaryLabel?: string;
|
|
183
|
+
metadata?: Record<string, unknown>;
|
|
184
|
+
}
|
|
174
185
|
export interface ThreadInfo extends ThreadSummary {
|
|
175
186
|
lastMessage?: string | null;
|
|
176
187
|
}
|
package/package.json
CHANGED
package/dist/types/user.d.ts
DELETED
|
@@ -1,21 +0,0 @@
|
|
|
1
|
-
export interface SmartOrgUser {
|
|
2
|
-
id?: string;
|
|
3
|
-
user_id?: string;
|
|
4
|
-
username?: string;
|
|
5
|
-
email?: string;
|
|
6
|
-
name?: string;
|
|
7
|
-
organisation?: string;
|
|
8
|
-
created?: string;
|
|
9
|
-
description?: string;
|
|
10
|
-
locked?: boolean;
|
|
11
|
-
email_verified?: boolean;
|
|
12
|
-
phone1?: string;
|
|
13
|
-
admin?: {
|
|
14
|
-
force_password_change?: boolean;
|
|
15
|
-
};
|
|
16
|
-
passwordAttempts?: number;
|
|
17
|
-
active_key?: string;
|
|
18
|
-
active_expire?: string;
|
|
19
|
-
isFirstLogin?: boolean;
|
|
20
|
-
modified?: string;
|
|
21
|
-
}
|