teodor-new-chat-ui 4.3.18 → 4.3.21
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/context/providers/chat-session/payloadCache.d.ts +10 -0
- package/dist/context/providers/chat-session/snapshots.d.ts +6 -0
- package/dist/context/providers/chat-session/storage.d.ts +6 -0
- package/dist/context/providers/chat-session/threadCache.d.ts +16 -0
- package/dist/index.esm.js +5004 -4997
- package/dist/index.umd.js +49 -49
- package/dist/types/api.d.ts +6 -13
- package/package.json +1 -1
package/dist/types/api.d.ts
CHANGED
|
@@ -269,6 +269,7 @@ export interface SendOptions {
|
|
|
269
269
|
config?: Record<string, unknown>;
|
|
270
270
|
payloadExtras?: Record<string, unknown>;
|
|
271
271
|
attachments?: File[];
|
|
272
|
+
command?: StreamCommand | null;
|
|
272
273
|
}
|
|
273
274
|
export interface ApiContextValue {
|
|
274
275
|
token: string | null;
|
|
@@ -333,20 +334,12 @@ export interface StreamSubmitPayload {
|
|
|
333
334
|
export interface StreamContextValue {
|
|
334
335
|
isStreaming: boolean;
|
|
335
336
|
error: string | null;
|
|
336
|
-
send: (request: Omit<ChatRequest, "payload"> & {
|
|
337
|
-
payload?: Record<string, unknown>;
|
|
338
|
-
}, callbacks?: {
|
|
339
|
-
onOpen?: (info: {
|
|
340
|
-
threadId: string | null;
|
|
341
|
-
created: boolean;
|
|
342
|
-
}) => void;
|
|
343
|
-
onError?: (error: unknown) => void;
|
|
344
|
-
onGap?: (gap: {
|
|
345
|
-
from: number;
|
|
346
|
-
to: number;
|
|
347
|
-
}) => void;
|
|
348
|
-
}) => Promise<void>;
|
|
349
337
|
submit: (payload: StreamSubmitPayload, options?: SendOptions) => Promise<void>;
|
|
338
|
+
/**
|
|
339
|
+
* @deprecated Prefer `submit`; retained for backwards compatibility while
|
|
340
|
+
* hosts migrate to the unified helper.
|
|
341
|
+
*/
|
|
342
|
+
send?: (payload: StreamSubmitPayload, options?: SendOptions) => Promise<void>;
|
|
350
343
|
stop: () => void;
|
|
351
344
|
setAuthToken: (token: string | null) => void;
|
|
352
345
|
}
|
package/package.json
CHANGED