@iota-uz/sdk 0.3.0 → 0.3.2
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/README.MD +2 -0
- package/dist/applet/vite.cjs +231 -0
- package/dist/applet/vite.cjs.map +1 -0
- package/dist/applet/vite.d.cts +115 -0
- package/dist/applet/vite.d.ts +115 -0
- package/dist/applet/vite.mjs +214 -0
- package/dist/applet/vite.mjs.map +1 -0
- package/dist/bichat/index.cjs +8551 -2320
- package/dist/bichat/index.cjs.map +1 -1
- package/dist/bichat/index.css +145 -37
- package/dist/bichat/index.css.map +1 -1
- package/dist/bichat/index.d.cts +1256 -232
- package/dist/bichat/index.d.ts +1256 -232
- package/dist/bichat/index.mjs +8510 -2327
- package/dist/bichat/index.mjs.map +1 -1
- package/dist/bichat/styles.css +165 -49
- package/dist/bichat/tailwind.cjs +93 -0
- package/dist/bichat/tailwind.cjs.map +1 -0
- package/dist/bichat/tailwind.d.cts +21 -0
- package/dist/bichat/tailwind.d.ts +21 -0
- package/dist/bichat/tailwind.mjs +85 -0
- package/dist/bichat/tailwind.mjs.map +1 -0
- package/dist/index-B73-BCi-.d.cts +84 -0
- package/dist/index-B73-BCi-.d.ts +84 -0
- package/dist/index.cjs +347 -0
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +76 -81
- package/dist/index.d.ts +76 -81
- package/dist/index.mjs +343 -3
- package/dist/index.mjs.map +1 -1
- package/package.json +29 -2
- package/tailwind/compiled.css +1 -1
- package/tailwind/iota.css +7 -0
package/dist/bichat/index.d.ts
CHANGED
|
@@ -1,11 +1,13 @@
|
|
|
1
1
|
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
2
2
|
import * as react from 'react';
|
|
3
|
-
import react__default, { ReactNode, Component, ErrorInfo, HTMLAttributes, ReactElement, ImgHTMLAttributes, ButtonHTMLAttributes, RefObject } from 'react';
|
|
3
|
+
import react__default, { ReactNode, Component, ErrorInfo, FC, HTMLAttributes, ReactElement, ImgHTMLAttributes, ButtonHTMLAttributes, RefObject } from 'react';
|
|
4
|
+
import { I as InitialContext, A as AppConfig$1, L as LocaleContext$1, c as TenantContext$1, U as UserContext$1 } from '../index-B73-BCi-.js';
|
|
5
|
+
import { File as File$1 } from '@phosphor-icons/react';
|
|
4
6
|
|
|
5
7
|
/**
|
|
6
8
|
* Type definitions for BI-Chat UI components
|
|
7
9
|
*/
|
|
8
|
-
interface Session {
|
|
10
|
+
interface Session$1 {
|
|
9
11
|
id: string;
|
|
10
12
|
title: string;
|
|
11
13
|
status: 'active' | 'archived';
|
|
@@ -17,33 +19,36 @@ interface Session {
|
|
|
17
19
|
* A conversation turn groups a user message with its assistant response.
|
|
18
20
|
* This provides a cleaner mental model than flat message lists.
|
|
19
21
|
*/
|
|
20
|
-
interface ConversationTurn {
|
|
22
|
+
interface ConversationTurn$1 {
|
|
21
23
|
id: string;
|
|
22
24
|
sessionId: string;
|
|
23
|
-
userTurn: UserTurn;
|
|
24
|
-
assistantTurn?: AssistantTurn;
|
|
25
|
+
userTurn: UserTurn$1;
|
|
26
|
+
assistantTurn?: AssistantTurn$1;
|
|
25
27
|
createdAt: string;
|
|
26
28
|
}
|
|
27
29
|
/**
|
|
28
30
|
* Content of a user's message in a conversation turn
|
|
29
31
|
*/
|
|
30
|
-
interface UserTurn {
|
|
32
|
+
interface UserTurn$1 {
|
|
31
33
|
id: string;
|
|
32
34
|
content: string;
|
|
33
|
-
attachments: Attachment[];
|
|
35
|
+
attachments: Attachment$1[];
|
|
34
36
|
createdAt: string;
|
|
35
37
|
}
|
|
36
38
|
/**
|
|
37
39
|
* Content of an assistant's response in a conversation turn
|
|
38
40
|
*/
|
|
39
|
-
interface AssistantTurn {
|
|
41
|
+
interface AssistantTurn$1 {
|
|
40
42
|
id: string;
|
|
43
|
+
role?: MessageRole;
|
|
41
44
|
content: string;
|
|
42
45
|
explanation?: string;
|
|
43
|
-
citations: Citation[];
|
|
46
|
+
citations: Citation$1[];
|
|
47
|
+
toolCalls?: ToolCall$1[];
|
|
44
48
|
chartData?: ChartData;
|
|
45
|
-
artifacts: Artifact[];
|
|
46
|
-
codeOutputs: CodeOutput[];
|
|
49
|
+
artifacts: Artifact$1[];
|
|
50
|
+
codeOutputs: CodeOutput$1[];
|
|
51
|
+
debug?: DebugTrace$1;
|
|
47
52
|
createdAt: string;
|
|
48
53
|
}
|
|
49
54
|
/**
|
|
@@ -58,15 +63,18 @@ declare enum MessageRole {
|
|
|
58
63
|
/**
|
|
59
64
|
* A tool/function call made by the assistant
|
|
60
65
|
*/
|
|
61
|
-
interface ToolCall {
|
|
66
|
+
interface ToolCall$1 {
|
|
62
67
|
id: string;
|
|
63
68
|
name: string;
|
|
64
69
|
arguments: string;
|
|
70
|
+
result?: string;
|
|
71
|
+
error?: string;
|
|
72
|
+
durationMs?: number;
|
|
65
73
|
}
|
|
66
74
|
/**
|
|
67
75
|
* Citation with position information for inline replacement
|
|
68
76
|
*/
|
|
69
|
-
interface Citation {
|
|
77
|
+
interface Citation$1 {
|
|
70
78
|
id: string;
|
|
71
79
|
/** Type of citation (e.g., "url_citation") */
|
|
72
80
|
type: string;
|
|
@@ -83,24 +91,23 @@ interface Citation {
|
|
|
83
91
|
/** Legacy: source name (for backward compatibility) */
|
|
84
92
|
source?: string;
|
|
85
93
|
}
|
|
86
|
-
interface Attachment {
|
|
87
|
-
id
|
|
94
|
+
interface Attachment$1 {
|
|
95
|
+
id?: string;
|
|
88
96
|
filename: string;
|
|
89
97
|
mimeType: string;
|
|
90
98
|
sizeBytes: number;
|
|
91
99
|
base64Data?: string;
|
|
100
|
+
url?: string;
|
|
101
|
+
preview?: string;
|
|
92
102
|
}
|
|
93
|
-
|
|
94
|
-
filename: string;
|
|
95
|
-
mimeType: string;
|
|
96
|
-
sizeBytes: number;
|
|
103
|
+
type ImageAttachment = Attachment$1 & {
|
|
97
104
|
base64Data: string;
|
|
98
105
|
preview: string;
|
|
99
|
-
}
|
|
106
|
+
};
|
|
100
107
|
/**
|
|
101
108
|
* Output from code interpreter tool
|
|
102
109
|
*/
|
|
103
|
-
interface CodeOutput {
|
|
110
|
+
interface CodeOutput$1 {
|
|
104
111
|
type: 'image' | 'text' | 'error';
|
|
105
112
|
content: string;
|
|
106
113
|
/** File metadata for downloadable outputs */
|
|
@@ -113,7 +120,7 @@ interface CodeOutput {
|
|
|
113
120
|
*/
|
|
114
121
|
interface QueuedMessage {
|
|
115
122
|
content: string;
|
|
116
|
-
attachments:
|
|
123
|
+
attachments: Attachment$1[];
|
|
117
124
|
}
|
|
118
125
|
/**
|
|
119
126
|
* Chart visualization data for ApexCharts
|
|
@@ -141,7 +148,7 @@ interface ChartSeries {
|
|
|
141
148
|
/** Numeric data values */
|
|
142
149
|
data: number[];
|
|
143
150
|
}
|
|
144
|
-
interface Artifact {
|
|
151
|
+
interface Artifact$1 {
|
|
145
152
|
type: 'excel' | 'pdf';
|
|
146
153
|
filename: string;
|
|
147
154
|
url: string;
|
|
@@ -149,7 +156,20 @@ interface Artifact {
|
|
|
149
156
|
rowCount?: number;
|
|
150
157
|
description?: string;
|
|
151
158
|
}
|
|
152
|
-
interface
|
|
159
|
+
interface SessionArtifact {
|
|
160
|
+
id: string;
|
|
161
|
+
sessionId: string;
|
|
162
|
+
messageId?: string;
|
|
163
|
+
type: string;
|
|
164
|
+
name: string;
|
|
165
|
+
description?: string;
|
|
166
|
+
mimeType?: string;
|
|
167
|
+
url?: string;
|
|
168
|
+
sizeBytes: number;
|
|
169
|
+
metadata?: Record<string, unknown>;
|
|
170
|
+
createdAt: string;
|
|
171
|
+
}
|
|
172
|
+
interface PendingQuestion$1 {
|
|
153
173
|
id: string;
|
|
154
174
|
turnId: string;
|
|
155
175
|
questions: Question[];
|
|
@@ -184,68 +204,238 @@ interface QuestionAnswers {
|
|
|
184
204
|
[questionId: string]: QuestionAnswerData;
|
|
185
205
|
}
|
|
186
206
|
interface StreamChunk {
|
|
187
|
-
type: 'chunk' | '
|
|
207
|
+
type: 'chunk' | 'content' | 'tool_start' | 'tool_end' | 'usage' | 'done' | 'error' | 'user_message' | 'interrupt';
|
|
188
208
|
content?: string;
|
|
189
209
|
error?: string;
|
|
190
210
|
sessionId?: string;
|
|
211
|
+
usage?: DebugUsage$1;
|
|
212
|
+
tool?: StreamToolPayload;
|
|
213
|
+
interrupt?: StreamInterruptPayload;
|
|
214
|
+
generationMs?: number;
|
|
215
|
+
timestamp?: number;
|
|
216
|
+
}
|
|
217
|
+
interface StreamInterruptPayload {
|
|
218
|
+
checkpointId: string;
|
|
219
|
+
agentName?: string;
|
|
220
|
+
questions: StreamInterruptQuestion[];
|
|
221
|
+
}
|
|
222
|
+
interface StreamInterruptQuestion {
|
|
223
|
+
id: string;
|
|
224
|
+
text: string;
|
|
225
|
+
type: string;
|
|
226
|
+
options: Array<{
|
|
227
|
+
id: string;
|
|
228
|
+
label: string;
|
|
229
|
+
}>;
|
|
230
|
+
}
|
|
231
|
+
interface DebugUsage$1 {
|
|
232
|
+
promptTokens: number;
|
|
233
|
+
completionTokens: number;
|
|
234
|
+
totalTokens: number;
|
|
235
|
+
cachedTokens?: number;
|
|
236
|
+
cost?: number;
|
|
237
|
+
}
|
|
238
|
+
interface StreamToolPayload {
|
|
239
|
+
callId?: string;
|
|
240
|
+
name: string;
|
|
241
|
+
arguments?: string;
|
|
242
|
+
result?: string;
|
|
243
|
+
error?: string;
|
|
244
|
+
durationMs?: number;
|
|
245
|
+
}
|
|
246
|
+
interface DebugTrace$1 {
|
|
247
|
+
generationMs?: number;
|
|
248
|
+
usage?: DebugUsage$1;
|
|
249
|
+
tools: StreamToolPayload[];
|
|
250
|
+
}
|
|
251
|
+
interface DebugLimits {
|
|
252
|
+
policyMaxTokens: number;
|
|
253
|
+
modelMaxTokens: number;
|
|
254
|
+
effectiveMaxTokens: number;
|
|
255
|
+
completionReserveTokens: number;
|
|
256
|
+
}
|
|
257
|
+
interface SessionDebugUsage {
|
|
258
|
+
promptTokens: number;
|
|
259
|
+
completionTokens: number;
|
|
260
|
+
totalTokens: number;
|
|
261
|
+
turnsWithUsage: number;
|
|
262
|
+
latestPromptTokens: number;
|
|
263
|
+
latestCompletionTokens: number;
|
|
264
|
+
latestTotalTokens: number;
|
|
265
|
+
}
|
|
266
|
+
interface SendMessageOptions {
|
|
267
|
+
debugMode?: boolean;
|
|
268
|
+
replaceFromMessageID?: string;
|
|
269
|
+
}
|
|
270
|
+
interface SessionListResult$1 {
|
|
271
|
+
sessions: Session$1[];
|
|
272
|
+
total: number;
|
|
273
|
+
hasMore: boolean;
|
|
274
|
+
}
|
|
275
|
+
interface SessionUser {
|
|
276
|
+
id: string;
|
|
277
|
+
firstName: string;
|
|
278
|
+
lastName: string;
|
|
279
|
+
initials: string;
|
|
280
|
+
}
|
|
281
|
+
interface SessionGroup {
|
|
282
|
+
name: string;
|
|
283
|
+
sessions: Session$1[];
|
|
191
284
|
}
|
|
192
285
|
interface ChatDataSource {
|
|
193
|
-
createSession(): Promise<Session>;
|
|
286
|
+
createSession(): Promise<Session$1>;
|
|
194
287
|
fetchSession(id: string): Promise<{
|
|
195
|
-
session: Session;
|
|
196
|
-
turns: ConversationTurn[];
|
|
197
|
-
pendingQuestion?: PendingQuestion | null;
|
|
288
|
+
session: Session$1;
|
|
289
|
+
turns: ConversationTurn$1[];
|
|
290
|
+
pendingQuestion?: PendingQuestion$1 | null;
|
|
198
291
|
} | null>;
|
|
199
|
-
|
|
292
|
+
fetchSessionArtifacts?(sessionId: string, options?: {
|
|
293
|
+
limit?: number;
|
|
294
|
+
offset?: number;
|
|
295
|
+
}): Promise<{
|
|
296
|
+
artifacts: SessionArtifact[];
|
|
297
|
+
hasMore?: boolean;
|
|
298
|
+
nextOffset?: number;
|
|
299
|
+
}>;
|
|
300
|
+
uploadSessionArtifacts?(sessionId: string, files: File[]): Promise<{
|
|
301
|
+
artifacts: SessionArtifact[];
|
|
302
|
+
}>;
|
|
303
|
+
renameSessionArtifact?(artifactId: string, name: string, description?: string): Promise<SessionArtifact>;
|
|
304
|
+
deleteSessionArtifact?(artifactId: string): Promise<void>;
|
|
305
|
+
sendMessage(sessionId: string, content: string, attachments?: Attachment$1[], signal?: AbortSignal, options?: SendMessageOptions): AsyncGenerator<StreamChunk>;
|
|
306
|
+
clearSessionHistory(sessionId: string): Promise<{
|
|
307
|
+
success: boolean;
|
|
308
|
+
deletedMessages: number;
|
|
309
|
+
deletedArtifacts: number;
|
|
310
|
+
}>;
|
|
311
|
+
compactSessionHistory(sessionId: string): Promise<{
|
|
312
|
+
success: boolean;
|
|
313
|
+
summary: string;
|
|
314
|
+
deletedMessages: number;
|
|
315
|
+
deletedArtifacts: number;
|
|
316
|
+
}>;
|
|
200
317
|
submitQuestionAnswers(sessionId: string, questionId: string, answers: QuestionAnswers): Promise<{
|
|
201
318
|
success: boolean;
|
|
202
319
|
error?: string;
|
|
203
320
|
}>;
|
|
204
|
-
|
|
321
|
+
rejectPendingQuestion(sessionId: string): Promise<{
|
|
205
322
|
success: boolean;
|
|
206
323
|
error?: string;
|
|
207
324
|
}>;
|
|
208
325
|
navigateToSession?(sessionId: string): void;
|
|
326
|
+
listSessions(options?: {
|
|
327
|
+
limit?: number;
|
|
328
|
+
offset?: number;
|
|
329
|
+
includeArchived?: boolean;
|
|
330
|
+
}): Promise<SessionListResult$1>;
|
|
331
|
+
archiveSession(sessionId: string): Promise<Session$1>;
|
|
332
|
+
unarchiveSession(sessionId: string): Promise<Session$1>;
|
|
333
|
+
pinSession(sessionId: string): Promise<Session$1>;
|
|
334
|
+
unpinSession(sessionId: string): Promise<Session$1>;
|
|
335
|
+
deleteSession(sessionId: string): Promise<void>;
|
|
336
|
+
renameSession(sessionId: string, title: string): Promise<Session$1>;
|
|
337
|
+
regenerateSessionTitle(sessionId: string): Promise<Session$1>;
|
|
338
|
+
listUsers?(): Promise<SessionUser[]>;
|
|
339
|
+
listAllSessions?(options?: {
|
|
340
|
+
limit?: number;
|
|
341
|
+
offset?: number;
|
|
342
|
+
includeArchived?: boolean;
|
|
343
|
+
userId?: string | null;
|
|
344
|
+
}): Promise<{
|
|
345
|
+
sessions: Array<Session$1 & {
|
|
346
|
+
owner: SessionUser;
|
|
347
|
+
}>;
|
|
348
|
+
total: number;
|
|
349
|
+
hasMore: boolean;
|
|
350
|
+
}>;
|
|
209
351
|
}
|
|
210
|
-
interface
|
|
211
|
-
|
|
212
|
-
turns: ConversationTurn[];
|
|
213
|
-
loading: boolean;
|
|
214
|
-
error: string | null;
|
|
352
|
+
interface ChatSessionStateValue {
|
|
353
|
+
session: Session$1 | null;
|
|
215
354
|
currentSessionId?: string;
|
|
216
|
-
pendingQuestion: PendingQuestion | null;
|
|
217
|
-
session: Session | null;
|
|
218
355
|
fetching: boolean;
|
|
356
|
+
error: string | null;
|
|
357
|
+
debugMode: boolean;
|
|
358
|
+
sessionDebugUsage: SessionDebugUsage;
|
|
359
|
+
debugLimits: DebugLimits | null;
|
|
360
|
+
setError: (error: string | null) => void;
|
|
361
|
+
}
|
|
362
|
+
interface ChatMessagingStateValue {
|
|
363
|
+
turns: ConversationTurn$1[];
|
|
219
364
|
streamingContent: string;
|
|
220
365
|
isStreaming: boolean;
|
|
221
|
-
|
|
222
|
-
|
|
223
|
-
|
|
224
|
-
|
|
225
|
-
|
|
226
|
-
|
|
366
|
+
loading: boolean;
|
|
367
|
+
pendingQuestion: PendingQuestion$1 | null;
|
|
368
|
+
codeOutputs: CodeOutput$1[];
|
|
369
|
+
isCompacting: boolean;
|
|
370
|
+
compactionSummary: string | null;
|
|
371
|
+
/** Bumped when artifacts should be refetched (e.g. tool_end for artifact-producing tools). */
|
|
372
|
+
artifactsInvalidationTrigger: number;
|
|
373
|
+
sendMessage: (content: string, attachments?: Attachment$1[]) => Promise<void>;
|
|
227
374
|
handleRegenerate?: (turnId: string) => Promise<void>;
|
|
228
375
|
handleEdit?: (turnId: string, newContent: string) => Promise<void>;
|
|
229
376
|
handleCopy: (text: string) => Promise<void>;
|
|
230
377
|
handleSubmitQuestionAnswers: (answers: QuestionAnswers) => void;
|
|
231
|
-
|
|
232
|
-
|
|
378
|
+
handleRejectPendingQuestion: () => Promise<void>;
|
|
379
|
+
cancel: () => void;
|
|
380
|
+
setCodeOutputs: (outputs: CodeOutput$1[]) => void;
|
|
381
|
+
}
|
|
382
|
+
interface ChatInputStateValue {
|
|
383
|
+
message: string;
|
|
384
|
+
inputError: string | null;
|
|
385
|
+
messageQueue: QueuedMessage[];
|
|
386
|
+
setMessage: (message: string) => void;
|
|
387
|
+
setInputError: (error: string | null) => void;
|
|
388
|
+
handleSubmit: (e: React.FormEvent, attachments?: Attachment$1[]) => void;
|
|
233
389
|
handleUnqueue: () => {
|
|
234
390
|
content: string;
|
|
235
|
-
attachments:
|
|
391
|
+
attachments: Attachment$1[];
|
|
236
392
|
} | null;
|
|
237
|
-
|
|
238
|
-
|
|
393
|
+
}
|
|
394
|
+
interface ChatSessionContextValue extends ChatSessionStateValue, ChatMessagingStateValue, ChatInputStateValue {
|
|
395
|
+
handleRetry?: () => Promise<void>;
|
|
396
|
+
}
|
|
397
|
+
|
|
398
|
+
/**
|
|
399
|
+
* Per-session rate limiter
|
|
400
|
+
* Prevents excessive requests within a time window
|
|
401
|
+
*/
|
|
402
|
+
interface RateLimiterConfig {
|
|
403
|
+
maxRequests: number;
|
|
404
|
+
windowMs: number;
|
|
405
|
+
}
|
|
406
|
+
declare class RateLimiter {
|
|
407
|
+
private timestamps;
|
|
408
|
+
private maxRequests;
|
|
409
|
+
private windowMs;
|
|
410
|
+
constructor(config: RateLimiterConfig);
|
|
411
|
+
/**
|
|
412
|
+
* Check if a request can be made
|
|
413
|
+
* Updates internal state if request is allowed
|
|
414
|
+
*/
|
|
415
|
+
canMakeRequest(): boolean;
|
|
416
|
+
/**
|
|
417
|
+
* Get milliseconds until next request is allowed
|
|
418
|
+
* Returns 0 if request can be made immediately
|
|
419
|
+
*/
|
|
420
|
+
getTimeUntilNextRequest(): number;
|
|
421
|
+
/**
|
|
422
|
+
* Reset the rate limiter state
|
|
423
|
+
*/
|
|
424
|
+
reset(): void;
|
|
239
425
|
}
|
|
240
426
|
|
|
241
427
|
interface ChatSessionProps {
|
|
242
428
|
dataSource: ChatDataSource;
|
|
243
429
|
sessionId?: string;
|
|
430
|
+
/** Optional rate limiter to throttle sendMessage */
|
|
431
|
+
rateLimiter?: RateLimiter;
|
|
432
|
+
/** Alias for isReadOnly (preferred) */
|
|
433
|
+
readOnly?: boolean;
|
|
244
434
|
isReadOnly?: boolean;
|
|
245
435
|
/** Custom render function for user turns */
|
|
246
|
-
renderUserTurn?: (turn: ConversationTurn) => ReactNode;
|
|
436
|
+
renderUserTurn?: (turn: ConversationTurn$1) => ReactNode;
|
|
247
437
|
/** Custom render function for assistant turns */
|
|
248
|
-
renderAssistantTurn?: (turn: ConversationTurn) => ReactNode;
|
|
438
|
+
renderAssistantTurn?: (turn: ConversationTurn$1) => ReactNode;
|
|
249
439
|
className?: string;
|
|
250
440
|
/** Custom content to display as header */
|
|
251
441
|
headerSlot?: ReactNode;
|
|
@@ -257,26 +447,62 @@ interface ChatSessionProps {
|
|
|
257
447
|
actionsSlot?: ReactNode;
|
|
258
448
|
/** Callback when user navigates back */
|
|
259
449
|
onBack?: () => void;
|
|
450
|
+
/** Custom verbs for the typing indicator (e.g. ['Thinking', 'Analyzing', ...]) */
|
|
451
|
+
thinkingVerbs?: string[];
|
|
452
|
+
/** Enables the built-in right-side artifacts panel for persisted session artifacts */
|
|
453
|
+
showArtifactsPanel?: boolean;
|
|
454
|
+
/** Initial expanded state for artifacts panel when no persisted preference exists */
|
|
455
|
+
artifactsPanelDefaultExpanded?: boolean;
|
|
456
|
+
/** localStorage key for artifacts panel expanded/collapsed state */
|
|
457
|
+
artifactsPanelStorageKey?: string;
|
|
260
458
|
}
|
|
261
459
|
declare function ChatSession(props: ChatSessionProps): react_jsx_runtime.JSX.Element;
|
|
262
460
|
|
|
461
|
+
interface SessionArtifactsPanelProps {
|
|
462
|
+
dataSource: ChatDataSource;
|
|
463
|
+
sessionId: string;
|
|
464
|
+
isStreaming: boolean;
|
|
465
|
+
allowDrop?: boolean;
|
|
466
|
+
className?: string;
|
|
467
|
+
/** When provided, used instead of useChatMessaging().artifactsInvalidationTrigger (allows use outside SDK ChatSessionProvider). */
|
|
468
|
+
artifactsInvalidationTrigger?: number;
|
|
469
|
+
}
|
|
470
|
+
declare function SessionArtifactsPanel({ dataSource, sessionId, isStreaming, allowDrop, className, artifactsInvalidationTrigger: artifactsInvalidationTriggerProp, }: SessionArtifactsPanelProps): react_jsx_runtime.JSX.Element;
|
|
471
|
+
|
|
472
|
+
interface SessionArtifactListProps {
|
|
473
|
+
artifacts: SessionArtifact[];
|
|
474
|
+
selectedArtifactId?: string;
|
|
475
|
+
onSelect: (artifact: SessionArtifact) => void;
|
|
476
|
+
}
|
|
477
|
+
declare function SessionArtifactList({ artifacts, selectedArtifactId, onSelect, }: SessionArtifactListProps): react_jsx_runtime.JSX.Element;
|
|
478
|
+
|
|
479
|
+
interface SessionArtifactPreviewProps {
|
|
480
|
+
artifact: SessionArtifact;
|
|
481
|
+
}
|
|
482
|
+
declare function SessionArtifactPreview({ artifact }: SessionArtifactPreviewProps): react_jsx_runtime.JSX.Element;
|
|
483
|
+
|
|
263
484
|
interface ChatHeaderProps {
|
|
264
|
-
session: Session | null;
|
|
485
|
+
session: Session$1 | null;
|
|
265
486
|
onBack?: () => void;
|
|
487
|
+
readOnly?: boolean;
|
|
266
488
|
/** Custom logo component to display */
|
|
267
489
|
logoSlot?: ReactNode;
|
|
268
490
|
/** Custom action buttons */
|
|
269
491
|
actionsSlot?: ReactNode;
|
|
270
492
|
}
|
|
271
|
-
declare function ChatHeader({ session, onBack, logoSlot, actionsSlot }: ChatHeaderProps): react_jsx_runtime.JSX.Element;
|
|
493
|
+
declare function ChatHeader({ session, onBack, readOnly, logoSlot, actionsSlot }: ChatHeaderProps): react_jsx_runtime.JSX.Element;
|
|
272
494
|
|
|
273
495
|
interface MessageListProps {
|
|
274
496
|
/** Custom render function for user turns */
|
|
275
|
-
renderUserTurn?: (turn: ConversationTurn) => ReactNode;
|
|
497
|
+
renderUserTurn?: (turn: ConversationTurn$1) => ReactNode;
|
|
276
498
|
/** Custom render function for assistant turns */
|
|
277
|
-
renderAssistantTurn?: (turn: ConversationTurn) => ReactNode;
|
|
499
|
+
renderAssistantTurn?: (turn: ConversationTurn$1) => ReactNode;
|
|
500
|
+
/** Custom verbs for the typing indicator (e.g. ['Thinking', 'Analyzing', ...]) */
|
|
501
|
+
thinkingVerbs?: string[];
|
|
502
|
+
/** When true, hides edit/regenerate actions */
|
|
503
|
+
readOnly?: boolean;
|
|
278
504
|
}
|
|
279
|
-
declare function MessageList({ renderUserTurn, renderAssistantTurn }: MessageListProps): react_jsx_runtime.JSX.Element;
|
|
505
|
+
declare function MessageList({ renderUserTurn, renderAssistantTurn, thinkingVerbs, readOnly }: MessageListProps): react_jsx_runtime.JSX.Element;
|
|
280
506
|
|
|
281
507
|
interface UserMessageAvatarSlotProps {
|
|
282
508
|
/** Default initials */
|
|
@@ -287,8 +513,8 @@ interface UserMessageContentSlotProps {
|
|
|
287
513
|
content: string;
|
|
288
514
|
}
|
|
289
515
|
interface UserMessageAttachmentsSlotProps {
|
|
290
|
-
/**
|
|
291
|
-
attachments:
|
|
516
|
+
/** Message attachments */
|
|
517
|
+
attachments: Attachment$1[];
|
|
292
518
|
/** Handler to open image viewer */
|
|
293
519
|
onView: (index: number) => void;
|
|
294
520
|
}
|
|
@@ -336,7 +562,7 @@ interface UserMessageClassNames {
|
|
|
336
562
|
}
|
|
337
563
|
interface UserMessageProps {
|
|
338
564
|
/** User turn data */
|
|
339
|
-
turn: UserTurn;
|
|
565
|
+
turn: UserTurn$1;
|
|
340
566
|
/** Turn ID for edit operations */
|
|
341
567
|
turnId?: string;
|
|
342
568
|
/** User initials for avatar */
|
|
@@ -355,12 +581,14 @@ interface UserMessageProps {
|
|
|
355
581
|
hideActions?: boolean;
|
|
356
582
|
/** Hide timestamp */
|
|
357
583
|
hideTimestamp?: boolean;
|
|
584
|
+
/** Whether edit action should be available */
|
|
585
|
+
allowEdit?: boolean;
|
|
358
586
|
}
|
|
359
|
-
declare function UserMessage({ turn, turnId, initials, slots, classNames: classNameOverrides, onCopy, onEdit, hideAvatar, hideActions, hideTimestamp, }: UserMessageProps): react_jsx_runtime.JSX.Element;
|
|
587
|
+
declare function UserMessage({ turn, turnId, initials, slots, classNames: classNameOverrides, onCopy, onEdit, hideAvatar, hideActions, hideTimestamp, allowEdit, }: UserMessageProps): react_jsx_runtime.JSX.Element;
|
|
360
588
|
|
|
361
589
|
interface UserTurnViewProps {
|
|
362
590
|
/** The conversation turn containing the user message */
|
|
363
|
-
turn: ConversationTurn;
|
|
591
|
+
turn: ConversationTurn$1;
|
|
364
592
|
/** Slot overrides for customization */
|
|
365
593
|
slots?: UserMessageSlots;
|
|
366
594
|
/** Class name overrides */
|
|
@@ -373,8 +601,10 @@ interface UserTurnViewProps {
|
|
|
373
601
|
hideActions?: boolean;
|
|
374
602
|
/** Hide timestamp */
|
|
375
603
|
hideTimestamp?: boolean;
|
|
604
|
+
/** Whether edit action should be available */
|
|
605
|
+
allowEdit?: boolean;
|
|
376
606
|
}
|
|
377
|
-
declare function UserTurnView({ turn, slots, classNames, initials, hideAvatar, hideActions, hideTimestamp, }: UserTurnViewProps): react_jsx_runtime.JSX.Element;
|
|
607
|
+
declare function UserTurnView({ turn, slots, classNames, initials, hideAvatar, hideActions, hideTimestamp, allowEdit, }: UserTurnViewProps): react_jsx_runtime.JSX.Element;
|
|
378
608
|
|
|
379
609
|
interface AssistantMessageAvatarSlotProps {
|
|
380
610
|
/** Default text */
|
|
@@ -384,13 +614,13 @@ interface AssistantMessageContentSlotProps {
|
|
|
384
614
|
/** Message content (markdown) */
|
|
385
615
|
content: string;
|
|
386
616
|
/** Citations */
|
|
387
|
-
citations?: Citation[];
|
|
617
|
+
citations?: Citation$1[];
|
|
388
618
|
/** Whether streaming is active */
|
|
389
619
|
isStreaming: boolean;
|
|
390
620
|
}
|
|
391
621
|
interface AssistantMessageSourcesSlotProps {
|
|
392
622
|
/** Citations to display */
|
|
393
|
-
citations: Citation[];
|
|
623
|
+
citations: Citation$1[];
|
|
394
624
|
}
|
|
395
625
|
interface AssistantMessageChartsSlotProps {
|
|
396
626
|
/** Chart data */
|
|
@@ -398,11 +628,11 @@ interface AssistantMessageChartsSlotProps {
|
|
|
398
628
|
}
|
|
399
629
|
interface AssistantMessageCodeOutputsSlotProps {
|
|
400
630
|
/** Code execution outputs */
|
|
401
|
-
outputs: CodeOutput[];
|
|
631
|
+
outputs: CodeOutput$1[];
|
|
402
632
|
}
|
|
403
633
|
interface AssistantMessageArtifactsSlotProps {
|
|
404
634
|
/** Downloadable artifacts */
|
|
405
|
-
artifacts: Artifact[];
|
|
635
|
+
artifacts: Artifact$1[];
|
|
406
636
|
}
|
|
407
637
|
interface AssistantMessageActionsSlotProps {
|
|
408
638
|
/** Copy content to clipboard */
|
|
@@ -470,13 +700,15 @@ interface AssistantMessageClassNames {
|
|
|
470
700
|
}
|
|
471
701
|
interface AssistantMessageProps {
|
|
472
702
|
/** Assistant turn data */
|
|
473
|
-
turn: AssistantTurn;
|
|
703
|
+
turn: AssistantTurn$1;
|
|
474
704
|
/** Turn ID for regenerate operations */
|
|
475
705
|
turnId?: string;
|
|
706
|
+
/** When true, this is the last turn (Regenerate button shown only on last assistant message) */
|
|
707
|
+
isLastTurn?: boolean;
|
|
476
708
|
/** Whether response is being streamed */
|
|
477
709
|
isStreaming?: boolean;
|
|
478
710
|
/** Pending question for HITL */
|
|
479
|
-
pendingQuestion?: PendingQuestion | null;
|
|
711
|
+
pendingQuestion?: PendingQuestion$1 | null;
|
|
480
712
|
/** Slot overrides */
|
|
481
713
|
slots?: AssistantMessageSlots;
|
|
482
714
|
/** Class name overrides */
|
|
@@ -495,12 +727,16 @@ interface AssistantMessageProps {
|
|
|
495
727
|
hideActions?: boolean;
|
|
496
728
|
/** Hide timestamp */
|
|
497
729
|
hideTimestamp?: boolean;
|
|
730
|
+
/** Show debug panel */
|
|
731
|
+
showDebug?: boolean;
|
|
498
732
|
}
|
|
499
|
-
declare function AssistantMessage({ turn, turnId, isStreaming, pendingQuestion, slots, classNames: classNameOverrides, onCopy, onRegenerate, onSendMessage, sendDisabled, hideAvatar, hideActions, hideTimestamp, }: AssistantMessageProps): react_jsx_runtime.JSX.Element;
|
|
733
|
+
declare function AssistantMessage({ turn, turnId, isLastTurn, isStreaming, pendingQuestion, slots, classNames: classNameOverrides, onCopy, onRegenerate, onSendMessage, sendDisabled, hideAvatar, hideActions, hideTimestamp, showDebug, }: AssistantMessageProps): react_jsx_runtime.JSX.Element;
|
|
500
734
|
|
|
501
735
|
interface AssistantTurnViewProps {
|
|
502
736
|
/** The conversation turn containing the assistant response */
|
|
503
|
-
turn: ConversationTurn;
|
|
737
|
+
turn: ConversationTurn$1;
|
|
738
|
+
/** When true, this is the last turn in the list (Regenerate button shown only on last assistant message) */
|
|
739
|
+
isLastTurn?: boolean;
|
|
504
740
|
/** Whether the response is currently being streamed */
|
|
505
741
|
isStreaming?: boolean;
|
|
506
742
|
/** Slot overrides for customization */
|
|
@@ -514,7 +750,7 @@ interface AssistantTurnViewProps {
|
|
|
514
750
|
/** Hide timestamp */
|
|
515
751
|
hideTimestamp?: boolean;
|
|
516
752
|
}
|
|
517
|
-
declare function AssistantTurnView({ turn, isStreaming, slots, classNames, hideAvatar, hideActions, hideTimestamp, }: AssistantTurnViewProps): react_jsx_runtime.JSX.Element | null;
|
|
753
|
+
declare function AssistantTurnView({ turn, isLastTurn, isStreaming, slots, classNames, hideAvatar, hideActions, hideTimestamp, }: AssistantTurnViewProps): react_jsx_runtime.JSX.Element | null;
|
|
518
754
|
|
|
519
755
|
interface TurnBubbleClassNames {
|
|
520
756
|
/** Root container */
|
|
@@ -526,11 +762,13 @@ interface TurnBubbleClassNames {
|
|
|
526
762
|
}
|
|
527
763
|
interface TurnBubbleProps {
|
|
528
764
|
/** The conversation turn containing user and optional assistant content */
|
|
529
|
-
turn: ConversationTurn;
|
|
765
|
+
turn: ConversationTurn$1;
|
|
766
|
+
/** When true, this turn is the last in the list (e.g. Regenerate shows only on last assistant message) */
|
|
767
|
+
isLastTurn?: boolean;
|
|
530
768
|
/** Custom render function for user turn (full control) */
|
|
531
|
-
renderUserTurn?: (turn: ConversationTurn) => ReactNode;
|
|
769
|
+
renderUserTurn?: (turn: ConversationTurn$1) => ReactNode;
|
|
532
770
|
/** Custom render function for assistant turn (full control) */
|
|
533
|
-
renderAssistantTurn?: (turn: ConversationTurn) => ReactNode;
|
|
771
|
+
renderAssistantTurn?: (turn: ConversationTurn$1) => ReactNode;
|
|
534
772
|
/** Props passed to UserTurnView (when not using custom renderer) */
|
|
535
773
|
userTurnProps?: Omit<UserTurnViewProps, 'turn'>;
|
|
536
774
|
/** Props passed to AssistantTurnView (when not using custom renderer) */
|
|
@@ -548,13 +786,13 @@ interface TurnBubbleProps {
|
|
|
548
786
|
/** Whether assistant response is streaming */
|
|
549
787
|
isStreaming?: boolean;
|
|
550
788
|
}
|
|
551
|
-
declare function TurnBubble({ turn, renderUserTurn, renderAssistantTurn, userTurnProps, assistantTurnProps, userMessageSlots, assistantMessageSlots, userMessageClassNames, assistantMessageClassNames, classNames, isStreaming, }: TurnBubbleProps): react_jsx_runtime.JSX.Element;
|
|
789
|
+
declare function TurnBubble({ turn, isLastTurn, renderUserTurn, renderAssistantTurn, userTurnProps, assistantTurnProps, userMessageSlots, assistantMessageSlots, userMessageClassNames, assistantMessageClassNames, classNames, isStreaming, }: TurnBubbleProps): react_jsx_runtime.JSX.Element;
|
|
552
790
|
|
|
553
791
|
interface MarkdownRendererProps {
|
|
554
792
|
/** Markdown content to render */
|
|
555
793
|
content: string;
|
|
556
794
|
/** Optional citations to process and display */
|
|
557
|
-
citations?: Citation[] | null;
|
|
795
|
+
citations?: Citation$1[] | null;
|
|
558
796
|
/** Optional function to send messages (enables table export) */
|
|
559
797
|
sendMessage?: (content: string) => void;
|
|
560
798
|
/** Whether message sending is disabled */
|
|
@@ -574,30 +812,21 @@ interface ChartCardProps {
|
|
|
574
812
|
}
|
|
575
813
|
/**
|
|
576
814
|
* ChartCard renders a single chart visualization with optional PNG export.
|
|
577
|
-
*
|
|
578
|
-
* Chart types:
|
|
579
|
-
* - line: Line chart with multiple series
|
|
580
|
-
* - bar: Bar chart with multiple series
|
|
581
|
-
* - area: Area chart with multiple series (filled)
|
|
582
|
-
* - pie: Pie chart (single series)
|
|
583
|
-
* - donut: Donut chart (single series)
|
|
584
|
-
*
|
|
585
|
-
* @param chartData - Chart specification from GraphQL API
|
|
586
815
|
*/
|
|
587
816
|
declare function ChartCard({ chartData }: ChartCardProps): react_jsx_runtime.JSX.Element;
|
|
588
817
|
|
|
589
818
|
interface SourcesPanelProps {
|
|
590
|
-
citations: Citation[];
|
|
819
|
+
citations: Citation$1[];
|
|
591
820
|
}
|
|
592
821
|
declare function SourcesPanel({ citations }: SourcesPanelProps): react_jsx_runtime.JSX.Element | null;
|
|
593
822
|
|
|
594
823
|
interface DownloadCardProps {
|
|
595
|
-
artifact: Artifact;
|
|
824
|
+
artifact: Artifact$1;
|
|
596
825
|
}
|
|
597
826
|
declare function DownloadCard({ artifact }: DownloadCardProps): react_jsx_runtime.JSX.Element;
|
|
598
827
|
|
|
599
828
|
interface InlineQuestionFormProps {
|
|
600
|
-
pendingQuestion: PendingQuestion;
|
|
829
|
+
pendingQuestion: PendingQuestion$1;
|
|
601
830
|
}
|
|
602
831
|
declare function InlineQuestionForm({ pendingQuestion }: InlineQuestionFormProps): react_jsx_runtime.JSX.Element | null;
|
|
603
832
|
|
|
@@ -610,82 +839,51 @@ interface MessageInputProps {
|
|
|
610
839
|
loading: boolean;
|
|
611
840
|
fetching?: boolean;
|
|
612
841
|
disabled?: boolean;
|
|
842
|
+
commandError?: string | null;
|
|
843
|
+
debugMode?: boolean;
|
|
844
|
+
debugSessionUsage?: SessionDebugUsage;
|
|
845
|
+
debugLimits?: DebugLimits | null;
|
|
613
846
|
messageQueue?: QueuedMessage[];
|
|
847
|
+
onClearCommandError?: () => void;
|
|
614
848
|
onMessageChange: (value: string) => void;
|
|
615
|
-
onSubmit: (e: React.FormEvent, attachments:
|
|
849
|
+
onSubmit: (e: React.FormEvent, attachments: Attachment$1[]) => void;
|
|
616
850
|
onUnqueue?: () => {
|
|
617
851
|
content: string;
|
|
618
|
-
attachments:
|
|
852
|
+
attachments: Attachment$1[];
|
|
619
853
|
} | null;
|
|
620
854
|
placeholder?: string;
|
|
621
855
|
maxFiles?: number;
|
|
622
856
|
maxFileSize?: number;
|
|
623
857
|
containerClassName?: string;
|
|
858
|
+
formClassName?: string;
|
|
624
859
|
}
|
|
625
860
|
declare const MessageInput: react.ForwardRefExoticComponent<MessageInputProps & react.RefAttributes<MessageInputRef>>;
|
|
626
861
|
|
|
627
862
|
interface AttachmentGridProps {
|
|
628
|
-
|
|
629
|
-
attachments: ImageAttachment[];
|
|
630
|
-
/** Optional callback when remove button is clicked */
|
|
863
|
+
attachments: Attachment$1[];
|
|
631
864
|
onRemove?: (index: number) => void;
|
|
632
|
-
/** Optional callback when thumbnail is clicked for preview */
|
|
633
865
|
onView?: (index: number) => void;
|
|
634
|
-
/** Additional CSS class */
|
|
635
866
|
className?: string;
|
|
636
|
-
/** If true, disable all interactions */
|
|
637
867
|
readonly?: boolean;
|
|
638
|
-
/** Maximum number of attachments to display (default: all) */
|
|
639
868
|
maxDisplay?: number;
|
|
640
|
-
/** Maximum total capacity (for warning display, default: 10) */
|
|
641
869
|
maxCapacity?: number;
|
|
642
|
-
/** Empty state message */
|
|
643
870
|
emptyMessage?: string;
|
|
644
|
-
/** Show count label above grid */
|
|
645
871
|
showCount?: boolean;
|
|
872
|
+
/** Number of files currently being processed (shows shimmer placeholders) */
|
|
873
|
+
pendingCount?: number;
|
|
646
874
|
}
|
|
647
|
-
|
|
648
|
-
* Responsive grid component for displaying image attachments
|
|
649
|
-
*
|
|
650
|
-
* Layout:
|
|
651
|
-
* - Mobile: 2 columns (grid-cols-2)
|
|
652
|
-
* - Tablet: 3 columns (sm:grid-cols-3)
|
|
653
|
-
* - Desktop: 4 columns (md:grid-cols-4)
|
|
654
|
-
*/
|
|
655
|
-
declare function AttachmentGrid({ attachments, onRemove, onView, className, readonly, maxDisplay, maxCapacity, emptyMessage, showCount, }: AttachmentGridProps): react_jsx_runtime.JSX.Element | null;
|
|
875
|
+
declare function AttachmentGrid({ attachments, onRemove, onView, className, readonly, maxDisplay, maxCapacity, emptyMessage, showCount, pendingCount, }: AttachmentGridProps): react_jsx_runtime.JSX.Element | null;
|
|
656
876
|
declare const MemoizedAttachmentGrid: react__default.MemoExoticComponent<typeof AttachmentGrid>;
|
|
657
877
|
|
|
658
878
|
interface ImageModalProps {
|
|
659
|
-
/** Whether the modal is open */
|
|
660
879
|
isOpen: boolean;
|
|
661
|
-
/** Callback to close the modal */
|
|
662
880
|
onClose: () => void;
|
|
663
|
-
/** The current attachment to display */
|
|
664
881
|
attachment: ImageAttachment;
|
|
665
|
-
/** Optional: all attachments for navigation */
|
|
666
882
|
allAttachments?: ImageAttachment[];
|
|
667
|
-
/** Optional: current index for navigation state */
|
|
668
883
|
currentIndex?: number;
|
|
669
|
-
/** Optional: callback for navigation (prev/next) */
|
|
670
884
|
onNavigate?: (direction: 'prev' | 'next') => void;
|
|
671
885
|
}
|
|
672
|
-
|
|
673
|
-
* Full-screen image modal component for viewing attachments
|
|
674
|
-
*
|
|
675
|
-
* Features:
|
|
676
|
-
* - Full-screen overlay with dark backdrop (90% opacity)
|
|
677
|
-
* - Large image display centered on screen
|
|
678
|
-
* - Close button (X) in top-right corner
|
|
679
|
-
* - Image metadata: filename, file size, MIME type
|
|
680
|
-
* - Navigation arrows (left/right) for image carousel
|
|
681
|
-
* - Keyboard support: Escape to close, Arrow keys to navigate
|
|
682
|
-
* - Click backdrop to close
|
|
683
|
-
* - Focus trap within modal
|
|
684
|
-
* - Body scroll locked when open
|
|
685
|
-
* - Image loading state with spinner
|
|
686
|
-
* - Navigation disabled at boundaries (not circular)
|
|
687
|
-
*/
|
|
688
|
-
declare function ImageModal({ isOpen, onClose, attachment, allAttachments, currentIndex, onNavigate, }: ImageModalProps): react.ReactPortal | null;
|
|
886
|
+
declare function ImageModal({ isOpen, onClose, attachment, allAttachments, currentIndex, onNavigate, }: ImageModalProps): react_jsx_runtime.JSX.Element;
|
|
689
887
|
|
|
690
888
|
/**
|
|
691
889
|
* WelcomeContent Component
|
|
@@ -701,7 +899,7 @@ interface WelcomeContentProps {
|
|
|
701
899
|
declare function WelcomeContent({ onPromptSelect, title, description, disabled }: WelcomeContentProps): react_jsx_runtime.JSX.Element;
|
|
702
900
|
|
|
703
901
|
interface CodeOutputsPanelProps {
|
|
704
|
-
outputs: CodeOutput[];
|
|
902
|
+
outputs: CodeOutput$1[];
|
|
705
903
|
}
|
|
706
904
|
declare function CodeOutputsPanel({ outputs }: CodeOutputsPanelProps): react_jsx_runtime.JSX.Element | null;
|
|
707
905
|
|
|
@@ -719,8 +917,17 @@ interface ScrollToBottomButtonProps {
|
|
|
719
917
|
show: boolean;
|
|
720
918
|
onClick: () => void;
|
|
721
919
|
unreadCount?: number;
|
|
920
|
+
disabled?: boolean;
|
|
921
|
+
/** When set, renders a pill-style button with this label (e.g. "New messages") */
|
|
922
|
+
label?: string;
|
|
923
|
+
}
|
|
924
|
+
declare function ScrollToBottomButton({ show, onClick, unreadCount, disabled, label, }: ScrollToBottomButtonProps): react_jsx_runtime.JSX.Element;
|
|
925
|
+
|
|
926
|
+
interface CompactionDoodleProps {
|
|
927
|
+
title: string;
|
|
928
|
+
subtitle: string;
|
|
722
929
|
}
|
|
723
|
-
declare function
|
|
930
|
+
declare function CompactionDoodle({ title, subtitle }: CompactionDoodleProps): react_jsx_runtime.JSX.Element;
|
|
724
931
|
|
|
725
932
|
interface EmptyStateProps {
|
|
726
933
|
/** Optional icon to display */
|
|
@@ -983,7 +1190,9 @@ declare function ToastContainer({ toasts, onDismiss, dismissLabel }: ToastContai
|
|
|
983
1190
|
|
|
984
1191
|
/**
|
|
985
1192
|
* ConfirmModal Component
|
|
986
|
-
*
|
|
1193
|
+
* Polished confirmation dialog with contextual icon, refined typography,
|
|
1194
|
+
* and smooth micro-interactions.
|
|
1195
|
+
* Uses @headlessui/react Dialog for accessible modal behavior.
|
|
987
1196
|
*/
|
|
988
1197
|
interface ConfirmModalProps {
|
|
989
1198
|
/** Whether the modal is open */
|
|
@@ -1003,7 +1212,7 @@ interface ConfirmModalProps {
|
|
|
1003
1212
|
/** Whether this is a danger/destructive action (red confirm button) */
|
|
1004
1213
|
isDanger?: boolean;
|
|
1005
1214
|
}
|
|
1006
|
-
declare function ConfirmModalBase({ isOpen, title, message, onConfirm, onCancel, confirmText, cancelText, isDanger, }: ConfirmModalProps): react_jsx_runtime.JSX.Element
|
|
1215
|
+
declare function ConfirmModalBase({ isOpen, title, message, onConfirm, onCancel, confirmText, cancelText, isDanger, }: ConfirmModalProps): react_jsx_runtime.JSX.Element;
|
|
1007
1216
|
declare const ConfirmModal: react.MemoExoticComponent<typeof ConfirmModalBase>;
|
|
1008
1217
|
|
|
1009
1218
|
/**
|
|
@@ -1073,24 +1282,291 @@ declare class ErrorBoundary extends Component<ErrorBoundaryProps, ErrorBoundaryS
|
|
|
1073
1282
|
|
|
1074
1283
|
/**
|
|
1075
1284
|
* TypingIndicator Component
|
|
1076
|
-
* Displays
|
|
1285
|
+
* Displays rotating verbs with shimmer animation to show AI is thinking/processing.
|
|
1286
|
+
* Verbs are configurable via props.
|
|
1077
1287
|
*/
|
|
1078
|
-
type TypingIndicatorVariant = 'dots' | 'text' | 'pulse';
|
|
1079
1288
|
interface TypingIndicatorProps {
|
|
1080
|
-
/**
|
|
1081
|
-
|
|
1082
|
-
/**
|
|
1083
|
-
messages?: string[];
|
|
1084
|
-
/** Message rotation interval in ms (for text variant, defaults to 3000) */
|
|
1289
|
+
/** Custom thinking verbs to rotate through */
|
|
1290
|
+
verbs?: string[];
|
|
1291
|
+
/** Verb rotation interval in ms (defaults to 3000) */
|
|
1085
1292
|
rotationInterval?: number;
|
|
1086
|
-
/** Size */
|
|
1087
|
-
size?: 'sm' | 'md' | 'lg';
|
|
1088
1293
|
/** Additional CSS classes */
|
|
1089
1294
|
className?: string;
|
|
1090
1295
|
}
|
|
1091
|
-
declare function TypingIndicator({
|
|
1296
|
+
declare function TypingIndicator({ verbs, rotationInterval, className, }: TypingIndicatorProps): react_jsx_runtime.JSX.Element;
|
|
1092
1297
|
declare const MemoizedTypingIndicator: react.MemoExoticComponent<typeof TypingIndicator>;
|
|
1093
1298
|
|
|
1299
|
+
interface SidebarProps {
|
|
1300
|
+
dataSource: ChatDataSource;
|
|
1301
|
+
onSessionSelect: (sessionId: string) => void;
|
|
1302
|
+
onNewChat: () => void;
|
|
1303
|
+
onArchivedView?: () => void;
|
|
1304
|
+
activeSessionId?: string;
|
|
1305
|
+
creating?: boolean;
|
|
1306
|
+
showAllChatsTab?: boolean;
|
|
1307
|
+
isOpen?: boolean;
|
|
1308
|
+
onClose?: () => void;
|
|
1309
|
+
headerSlot?: react__default.ReactNode;
|
|
1310
|
+
footerSlot?: react__default.ReactNode;
|
|
1311
|
+
className?: string;
|
|
1312
|
+
}
|
|
1313
|
+
declare function Sidebar({ dataSource, onSessionSelect, onNewChat, onArchivedView, activeSessionId, creating, showAllChatsTab, isOpen: _isOpen, onClose, headerSlot, footerSlot, className, }: SidebarProps): react_jsx_runtime.JSX.Element;
|
|
1314
|
+
|
|
1315
|
+
/**
|
|
1316
|
+
* SessionItem Component
|
|
1317
|
+
* Individual chat session item in the sidebar with actions menu
|
|
1318
|
+
* Router-agnostic: uses onSelect callback instead of Link
|
|
1319
|
+
*/
|
|
1320
|
+
|
|
1321
|
+
interface SessionItemProps {
|
|
1322
|
+
session: Session$1;
|
|
1323
|
+
isActive: boolean;
|
|
1324
|
+
mode?: 'active' | 'archived';
|
|
1325
|
+
onSelect: (sessionId: string) => void;
|
|
1326
|
+
onArchive?: () => void;
|
|
1327
|
+
onRestore?: () => void;
|
|
1328
|
+
onPin?: () => void;
|
|
1329
|
+
onRename?: (newTitle: string) => void;
|
|
1330
|
+
onRegenerateTitle?: () => void;
|
|
1331
|
+
onDelete?: () => void;
|
|
1332
|
+
testIdPrefix?: string;
|
|
1333
|
+
className?: string;
|
|
1334
|
+
}
|
|
1335
|
+
declare const SessionItem: react__default.NamedExoticComponent<SessionItemProps>;
|
|
1336
|
+
|
|
1337
|
+
interface ArchivedChatListProps {
|
|
1338
|
+
dataSource: ChatDataSource;
|
|
1339
|
+
onBack: () => void;
|
|
1340
|
+
onSessionSelect: (sessionId: string) => void;
|
|
1341
|
+
activeSessionId?: string;
|
|
1342
|
+
className?: string;
|
|
1343
|
+
toast?: UseToastReturn;
|
|
1344
|
+
}
|
|
1345
|
+
declare function ArchivedChatList({ dataSource, onBack, onSessionSelect, activeSessionId, className, toast: toastFromProps, }: ArchivedChatListProps): react_jsx_runtime.JSX.Element;
|
|
1346
|
+
|
|
1347
|
+
interface AllChatsListProps {
|
|
1348
|
+
dataSource: ChatDataSource;
|
|
1349
|
+
onSessionSelect: (sessionId: string) => void;
|
|
1350
|
+
activeSessionId?: string;
|
|
1351
|
+
}
|
|
1352
|
+
declare function AllChatsList({ dataSource, onSessionSelect, activeSessionId }: AllChatsListProps): react_jsx_runtime.JSX.Element;
|
|
1353
|
+
|
|
1354
|
+
/**
|
|
1355
|
+
* TabBar Component
|
|
1356
|
+
* Horizontal tabs with animated indicator for switching between views
|
|
1357
|
+
* Generic: accepts any set of tabs via props
|
|
1358
|
+
*/
|
|
1359
|
+
interface TabBarProps {
|
|
1360
|
+
tabs: Array<{
|
|
1361
|
+
id: string;
|
|
1362
|
+
label: string;
|
|
1363
|
+
}>;
|
|
1364
|
+
activeTab: string;
|
|
1365
|
+
onTabChange: (tabId: string) => void;
|
|
1366
|
+
}
|
|
1367
|
+
declare function TabBar({ tabs, activeTab, onTabChange }: TabBarProps): react_jsx_runtime.JSX.Element | null;
|
|
1368
|
+
declare const MemoizedTabBar: react.MemoExoticComponent<typeof TabBar>;
|
|
1369
|
+
|
|
1370
|
+
interface UserFilterProps {
|
|
1371
|
+
users: SessionUser[];
|
|
1372
|
+
selectedUser: SessionUser | null;
|
|
1373
|
+
onUserChange: (user: SessionUser | null) => void;
|
|
1374
|
+
loading?: boolean;
|
|
1375
|
+
}
|
|
1376
|
+
declare function UserFilter({ users, selectedUser, onUserChange, loading }: UserFilterProps): react_jsx_runtime.JSX.Element;
|
|
1377
|
+
declare const MemoizedUserFilter: react.MemoExoticComponent<typeof UserFilter>;
|
|
1378
|
+
|
|
1379
|
+
interface DateGroupHeaderProps {
|
|
1380
|
+
groupName: string;
|
|
1381
|
+
count: number;
|
|
1382
|
+
}
|
|
1383
|
+
/**
|
|
1384
|
+
* Sticky header for date-based session groups
|
|
1385
|
+
* Displays group name and session count
|
|
1386
|
+
*/
|
|
1387
|
+
declare function DateGroupHeader({ groupName, count }: DateGroupHeaderProps): react_jsx_runtime.JSX.Element;
|
|
1388
|
+
|
|
1389
|
+
interface SessionSkeletonProps {
|
|
1390
|
+
count?: number;
|
|
1391
|
+
}
|
|
1392
|
+
declare function SessionSkeleton({ count }: SessionSkeletonProps): react_jsx_runtime.JSX.Element;
|
|
1393
|
+
|
|
1394
|
+
interface SystemMessageProps {
|
|
1395
|
+
content: string;
|
|
1396
|
+
createdAt: string;
|
|
1397
|
+
onCopy?: (content: string) => Promise<void> | void;
|
|
1398
|
+
hideActions?: boolean;
|
|
1399
|
+
hideTimestamp?: boolean;
|
|
1400
|
+
}
|
|
1401
|
+
declare function SystemMessage({ content, createdAt, onCopy, hideActions, hideTimestamp, }: SystemMessageProps): react_jsx_runtime.JSX.Element;
|
|
1402
|
+
|
|
1403
|
+
interface DebugPanelProps {
|
|
1404
|
+
trace?: DebugTrace$1;
|
|
1405
|
+
}
|
|
1406
|
+
declare function DebugPanel({ trace }: DebugPanelProps): react_jsx_runtime.JSX.Element;
|
|
1407
|
+
|
|
1408
|
+
/**
|
|
1409
|
+
* Alert Component
|
|
1410
|
+
* Standardized error/success/warning/info messages with retry capability
|
|
1411
|
+
*/
|
|
1412
|
+
type AlertVariant = 'error' | 'success' | 'warning' | 'info';
|
|
1413
|
+
interface AlertProps {
|
|
1414
|
+
variant?: AlertVariant;
|
|
1415
|
+
message: string;
|
|
1416
|
+
title?: string;
|
|
1417
|
+
onDismiss?: () => void;
|
|
1418
|
+
onRetry?: () => void;
|
|
1419
|
+
show?: boolean;
|
|
1420
|
+
dismissible?: boolean;
|
|
1421
|
+
}
|
|
1422
|
+
declare function Alert({ variant, message, title, onDismiss, onRetry, show, dismissible, }: AlertProps): react_jsx_runtime.JSX.Element;
|
|
1423
|
+
declare const _default$1: react.MemoExoticComponent<typeof Alert>;
|
|
1424
|
+
|
|
1425
|
+
/**
|
|
1426
|
+
* Archive Banner Component
|
|
1427
|
+
* Displays when a chat session is archived and provides a restore button
|
|
1428
|
+
*/
|
|
1429
|
+
interface ArchiveBannerProps {
|
|
1430
|
+
show?: boolean;
|
|
1431
|
+
onRestore?: () => Promise<void>;
|
|
1432
|
+
restoring?: boolean;
|
|
1433
|
+
onRestoreComplete?: () => void;
|
|
1434
|
+
}
|
|
1435
|
+
declare function ArchiveBanner({ show, onRestore, restoring, onRestoreComplete, }: ArchiveBannerProps): react_jsx_runtime.JSX.Element;
|
|
1436
|
+
declare const _default: react.MemoExoticComponent<typeof ArchiveBanner>;
|
|
1437
|
+
|
|
1438
|
+
/**
|
|
1439
|
+
* RetryActionArea Component
|
|
1440
|
+
* Displays a retry action area inline where the assistant message would appear
|
|
1441
|
+
* (typically after an interrupted request or connection loss)
|
|
1442
|
+
*
|
|
1443
|
+
* Styled to match assistant message positioning (left-aligned) so users see
|
|
1444
|
+
* the retry button contextually in the conversation flow.
|
|
1445
|
+
*/
|
|
1446
|
+
interface RetryActionAreaProps {
|
|
1447
|
+
/** Callback when retry button is clicked */
|
|
1448
|
+
onRetry: () => void;
|
|
1449
|
+
}
|
|
1450
|
+
declare const RetryActionArea: react.NamedExoticComponent<RetryActionAreaProps>;
|
|
1451
|
+
|
|
1452
|
+
/**
|
|
1453
|
+
* StreamError Component
|
|
1454
|
+
* Error recovery UI for streaming failures
|
|
1455
|
+
*/
|
|
1456
|
+
interface StreamErrorProps {
|
|
1457
|
+
/** Error message to display */
|
|
1458
|
+
error: string;
|
|
1459
|
+
/** Callback to retry the failed operation */
|
|
1460
|
+
onRetry?: () => void;
|
|
1461
|
+
/** Callback to regenerate the message */
|
|
1462
|
+
onRegenerate?: () => void;
|
|
1463
|
+
/** Whether to show compact mode (less padding) */
|
|
1464
|
+
compact?: boolean;
|
|
1465
|
+
}
|
|
1466
|
+
declare function StreamError({ error, onRetry, onRegenerate, compact, }: StreamErrorProps): react_jsx_runtime.JSX.Element;
|
|
1467
|
+
|
|
1468
|
+
interface ActionableMessage {
|
|
1469
|
+
id: string;
|
|
1470
|
+
role: MessageRole;
|
|
1471
|
+
content: string;
|
|
1472
|
+
}
|
|
1473
|
+
interface MessageActionsProps {
|
|
1474
|
+
message: ActionableMessage;
|
|
1475
|
+
onCopy: (text: string) => Promise<void>;
|
|
1476
|
+
onRegenerate?: (messageId: string) => Promise<void>;
|
|
1477
|
+
onEdit?: (message: ActionableMessage) => void;
|
|
1478
|
+
}
|
|
1479
|
+
declare function MessageActions({ message, onCopy, onRegenerate, onEdit, }: MessageActionsProps): react_jsx_runtime.JSX.Element;
|
|
1480
|
+
|
|
1481
|
+
interface AttachmentPreviewProps {
|
|
1482
|
+
/** The attachment to display */
|
|
1483
|
+
attachment: ImageAttachment;
|
|
1484
|
+
/** Optional callback when remove button is clicked */
|
|
1485
|
+
onRemove?: () => void;
|
|
1486
|
+
/** Optional callback when thumbnail is clicked (for enlargement) */
|
|
1487
|
+
onClick?: () => void;
|
|
1488
|
+
/** If true, hide remove button and disable click interactions */
|
|
1489
|
+
readonly?: boolean;
|
|
1490
|
+
}
|
|
1491
|
+
declare const AttachmentPreview: react.NamedExoticComponent<AttachmentPreviewProps>;
|
|
1492
|
+
|
|
1493
|
+
interface AttachmentUploadProps {
|
|
1494
|
+
/** Callback fired when files are successfully converted and validated */
|
|
1495
|
+
onAttachmentsSelected: (attachments: Attachment$1[]) => void;
|
|
1496
|
+
/** Maximum number of attachments allowed (default: 10) */
|
|
1497
|
+
maxAttachments?: number;
|
|
1498
|
+
/** Maximum file size in bytes (default: 20 MB) */
|
|
1499
|
+
maxSizeBytes?: number;
|
|
1500
|
+
/** Whether the component is disabled */
|
|
1501
|
+
disabled?: boolean;
|
|
1502
|
+
}
|
|
1503
|
+
declare const AttachmentUpload: react.NamedExoticComponent<AttachmentUploadProps>;
|
|
1504
|
+
|
|
1505
|
+
interface ScreenReaderAnnouncerProps {
|
|
1506
|
+
message: string;
|
|
1507
|
+
politeness?: 'polite' | 'assertive';
|
|
1508
|
+
clearAfter?: number;
|
|
1509
|
+
}
|
|
1510
|
+
/**
|
|
1511
|
+
* Screen reader announcer component for live region updates
|
|
1512
|
+
* Uses ARIA live regions to announce dynamic content changes
|
|
1513
|
+
*
|
|
1514
|
+
* @param message - The message to announce
|
|
1515
|
+
* @param politeness - 'polite' (wait for pause) or 'assertive' (immediate)
|
|
1516
|
+
* @param clearAfter - Optional milliseconds to clear message after announcement
|
|
1517
|
+
*
|
|
1518
|
+
* @example
|
|
1519
|
+
* <ScreenReaderAnnouncer
|
|
1520
|
+
* message="New message received"
|
|
1521
|
+
* politeness="polite"
|
|
1522
|
+
* />
|
|
1523
|
+
*/
|
|
1524
|
+
declare function ScreenReaderAnnouncer({ message, politeness, clearAfter, }: ScreenReaderAnnouncerProps): react_jsx_runtime.JSX.Element;
|
|
1525
|
+
|
|
1526
|
+
/**
|
|
1527
|
+
* Skip to main content link for keyboard navigation
|
|
1528
|
+
* Hidden by default, visible on keyboard focus
|
|
1529
|
+
* Allows users to skip navigation and go directly to main content
|
|
1530
|
+
*/
|
|
1531
|
+
declare function SkipLink(): react_jsx_runtime.JSX.Element;
|
|
1532
|
+
|
|
1533
|
+
interface ContextMenuItem {
|
|
1534
|
+
id: string;
|
|
1535
|
+
label: string;
|
|
1536
|
+
icon?: ReactNode;
|
|
1537
|
+
onClick: () => void;
|
|
1538
|
+
variant?: 'default' | 'danger';
|
|
1539
|
+
disabled?: boolean;
|
|
1540
|
+
}
|
|
1541
|
+
interface TouchContextMenuProps {
|
|
1542
|
+
items: ContextMenuItem[];
|
|
1543
|
+
isOpen: boolean;
|
|
1544
|
+
onClose: () => void;
|
|
1545
|
+
anchorRect: DOMRect | null;
|
|
1546
|
+
}
|
|
1547
|
+
declare const TouchContextMenu: FC<TouchContextMenuProps>;
|
|
1548
|
+
|
|
1549
|
+
interface QuestionFormProps {
|
|
1550
|
+
pendingQuestion: PendingQuestion$1;
|
|
1551
|
+
sessionId: string;
|
|
1552
|
+
onSubmit: (answers: QuestionAnswers) => Promise<void>;
|
|
1553
|
+
onCancel: () => void;
|
|
1554
|
+
}
|
|
1555
|
+
declare function QuestionForm({ pendingQuestion, onSubmit, onCancel, }: QuestionFormProps): react_jsx_runtime.JSX.Element;
|
|
1556
|
+
|
|
1557
|
+
interface QuestionStepProps {
|
|
1558
|
+
question: Question;
|
|
1559
|
+
selectedAnswers: QuestionAnswers;
|
|
1560
|
+
onAnswer: (answerData: QuestionAnswerData) => void;
|
|
1561
|
+
}
|
|
1562
|
+
declare function QuestionStep({ question, selectedAnswers, onAnswer, }: QuestionStepProps): react_jsx_runtime.JSX.Element;
|
|
1563
|
+
|
|
1564
|
+
interface ConfirmationStepProps {
|
|
1565
|
+
questions: Question[];
|
|
1566
|
+
answers: QuestionAnswers;
|
|
1567
|
+
}
|
|
1568
|
+
declare function ConfirmationStep({ questions, answers, }: ConfirmationStepProps): react_jsx_runtime.JSX.Element;
|
|
1569
|
+
|
|
1094
1570
|
interface SlotProps extends HTMLAttributes<HTMLElement> {
|
|
1095
1571
|
children?: ReactNode;
|
|
1096
1572
|
}
|
|
@@ -1501,22 +1977,22 @@ interface FileValidationError {
|
|
|
1501
1977
|
interface UseAttachmentsOptions {
|
|
1502
1978
|
/** Maximum number of files (default: 10) */
|
|
1503
1979
|
maxFiles?: number;
|
|
1504
|
-
/** Maximum file size in bytes (default:
|
|
1980
|
+
/** Maximum file size in bytes (default: 20MB) */
|
|
1505
1981
|
maxFileSize?: number;
|
|
1506
|
-
/** Allowed MIME types (default:
|
|
1982
|
+
/** Allowed MIME types (default: attachment allowlist) */
|
|
1507
1983
|
allowedTypes?: string[];
|
|
1508
1984
|
/** Custom validation function */
|
|
1509
1985
|
validate?: (file: File) => string | null;
|
|
1510
1986
|
/** Callback when files are added */
|
|
1511
|
-
onAdd?: (files: Attachment[]) => void;
|
|
1987
|
+
onAdd?: (files: Attachment$1[]) => void;
|
|
1512
1988
|
/** Callback when a file is removed */
|
|
1513
|
-
onRemove?: (file: Attachment) => void;
|
|
1989
|
+
onRemove?: (file: Attachment$1) => void;
|
|
1514
1990
|
/** Callback when validation fails */
|
|
1515
1991
|
onError?: (errors: FileValidationError[]) => void;
|
|
1516
1992
|
}
|
|
1517
1993
|
interface UseAttachmentsReturn {
|
|
1518
1994
|
/** Current attachments */
|
|
1519
|
-
files: Attachment[];
|
|
1995
|
+
files: Attachment$1[];
|
|
1520
1996
|
/** Validation errors from last operation */
|
|
1521
1997
|
errors: FileValidationError[];
|
|
1522
1998
|
/** Whether files are being processed */
|
|
@@ -1528,13 +2004,13 @@ interface UseAttachmentsReturn {
|
|
|
1528
2004
|
/** Add files (validates and processes) */
|
|
1529
2005
|
add: (files: FileList | File[]) => Promise<void>;
|
|
1530
2006
|
/** Remove a specific file */
|
|
1531
|
-
remove: (fileOrId: Attachment | string) => void;
|
|
2007
|
+
remove: (fileOrId: Attachment$1 | string) => void;
|
|
1532
2008
|
/** Clear all files */
|
|
1533
2009
|
clear: () => void;
|
|
1534
2010
|
/** Clear errors */
|
|
1535
2011
|
clearErrors: () => void;
|
|
1536
2012
|
/** Set files directly (for controlled mode) */
|
|
1537
|
-
setFiles: (files: Attachment[]) => void;
|
|
2013
|
+
setFiles: (files: Attachment$1[]) => void;
|
|
1538
2014
|
}
|
|
1539
2015
|
/**
|
|
1540
2016
|
* Hook for managing file attachments
|
|
@@ -1617,16 +2093,88 @@ interface UseMarkdownCopyReturn {
|
|
|
1617
2093
|
declare function useMarkdownCopy(options?: UseMarkdownCopyOptions): UseMarkdownCopyReturn;
|
|
1618
2094
|
|
|
1619
2095
|
/**
|
|
1620
|
-
*
|
|
1621
|
-
*
|
|
1622
|
-
*
|
|
2096
|
+
* useScrollToBottom Hook
|
|
2097
|
+
* Manages scroll-to-bottom functionality with smart auto-scroll
|
|
2098
|
+
* Only scrolls if user is near the bottom (within threshold)
|
|
1623
2099
|
*/
|
|
2100
|
+
interface UseScrollToBottomReturn {
|
|
2101
|
+
/**
|
|
2102
|
+
* Ref to attach to the messages container
|
|
2103
|
+
*/
|
|
2104
|
+
containerRef: React.RefObject<HTMLDivElement>;
|
|
2105
|
+
/**
|
|
2106
|
+
* Whether to show the scroll-to-bottom button
|
|
2107
|
+
*/
|
|
2108
|
+
showScrollButton: boolean;
|
|
2109
|
+
/**
|
|
2110
|
+
* Function to scroll to bottom
|
|
2111
|
+
*/
|
|
2112
|
+
scrollToBottom: () => void;
|
|
2113
|
+
}
|
|
1624
2114
|
/**
|
|
1625
|
-
*
|
|
2115
|
+
* Hook for managing scroll-to-bottom behavior
|
|
2116
|
+
* Automatically scrolls if user is near the bottom
|
|
2117
|
+
* Shows button only when scrolled up significantly
|
|
1626
2118
|
*/
|
|
1627
|
-
declare
|
|
1628
|
-
|
|
1629
|
-
|
|
2119
|
+
declare function useScrollToBottom(items: unknown[]): UseScrollToBottomReturn;
|
|
2120
|
+
|
|
2121
|
+
interface ShortcutConfig {
|
|
2122
|
+
key: string;
|
|
2123
|
+
ctrl?: boolean;
|
|
2124
|
+
shift?: boolean;
|
|
2125
|
+
alt?: boolean;
|
|
2126
|
+
meta?: boolean;
|
|
2127
|
+
callback: () => void;
|
|
2128
|
+
preventDefault?: boolean;
|
|
2129
|
+
description?: string;
|
|
2130
|
+
}
|
|
2131
|
+
/**
|
|
2132
|
+
* Hook for managing global keyboard shortcuts
|
|
2133
|
+
* Automatically handles modifier keys and input field exclusion
|
|
2134
|
+
*
|
|
2135
|
+
* @param shortcuts - Array of keyboard shortcut configurations
|
|
2136
|
+
*
|
|
2137
|
+
* @example
|
|
2138
|
+
* useKeyboardShortcuts([
|
|
2139
|
+
* { key: 'k', ctrl: true, callback: () => focusSearch(), description: 'Focus search' },
|
|
2140
|
+
* { key: '?', callback: () => setShowHelp(true), description: 'Show keyboard shortcuts' },
|
|
2141
|
+
* ])
|
|
2142
|
+
*/
|
|
2143
|
+
declare function useKeyboardShortcuts(shortcuts: ShortcutConfig[]): void;
|
|
2144
|
+
|
|
2145
|
+
interface LongPressOptions {
|
|
2146
|
+
delay?: number;
|
|
2147
|
+
onLongPress: (e: React.TouchEvent | React.MouseEvent) => void;
|
|
2148
|
+
onPressStart?: () => void;
|
|
2149
|
+
onPressCancel?: () => void;
|
|
2150
|
+
moveThreshold?: number;
|
|
2151
|
+
hapticFeedback?: boolean;
|
|
2152
|
+
}
|
|
2153
|
+
interface LongPressEventHandlers {
|
|
2154
|
+
onTouchStart: (e: React.TouchEvent) => void;
|
|
2155
|
+
onTouchEnd: (e: React.TouchEvent) => void;
|
|
2156
|
+
onTouchMove: (e: React.TouchEvent) => void;
|
|
2157
|
+
onMouseDown?: (e: React.MouseEvent) => void;
|
|
2158
|
+
onMouseUp?: (e: React.MouseEvent) => void;
|
|
2159
|
+
onMouseLeave?: (e: React.MouseEvent) => void;
|
|
2160
|
+
}
|
|
2161
|
+
interface LongPressResult {
|
|
2162
|
+
handlers: LongPressEventHandlers;
|
|
2163
|
+
isPressed: boolean;
|
|
2164
|
+
}
|
|
2165
|
+
declare function useLongPress(options: LongPressOptions): LongPressResult;
|
|
2166
|
+
|
|
2167
|
+
/**
|
|
2168
|
+
* Framer Motion animation variants for BiChat UI
|
|
2169
|
+
* Subtle, professional animations for enterprise applications
|
|
2170
|
+
* Respects prefers-reduced-motion for accessibility
|
|
2171
|
+
*/
|
|
2172
|
+
/**
|
|
2173
|
+
* Fade in animation
|
|
2174
|
+
*/
|
|
2175
|
+
declare const fadeInVariants: {
|
|
2176
|
+
initial: {
|
|
2177
|
+
opacity: number;
|
|
1630
2178
|
};
|
|
1631
2179
|
animate: {
|
|
1632
2180
|
opacity: number;
|
|
@@ -1808,6 +2356,31 @@ declare const typingDotVariants: {
|
|
|
1808
2356
|
};
|
|
1809
2357
|
};
|
|
1810
2358
|
};
|
|
2359
|
+
/**
|
|
2360
|
+
* Verb transition for typing indicator
|
|
2361
|
+
* Smooth slide-up animation for rotating text
|
|
2362
|
+
*/
|
|
2363
|
+
declare const verbTransitionVariants: {
|
|
2364
|
+
initial: {
|
|
2365
|
+
y: number;
|
|
2366
|
+
opacity: number;
|
|
2367
|
+
};
|
|
2368
|
+
animate: {
|
|
2369
|
+
y: number;
|
|
2370
|
+
opacity: number;
|
|
2371
|
+
transition: {
|
|
2372
|
+
duration: number;
|
|
2373
|
+
ease: string;
|
|
2374
|
+
};
|
|
2375
|
+
};
|
|
2376
|
+
exit: {
|
|
2377
|
+
y: number;
|
|
2378
|
+
opacity: number;
|
|
2379
|
+
transition: {
|
|
2380
|
+
duration: number;
|
|
2381
|
+
};
|
|
2382
|
+
};
|
|
2383
|
+
};
|
|
1811
2384
|
/**
|
|
1812
2385
|
* Floating button (scroll to bottom, etc.)
|
|
1813
2386
|
*/
|
|
@@ -1877,35 +2450,62 @@ declare const toastVariants: {
|
|
|
1877
2450
|
};
|
|
1878
2451
|
};
|
|
1879
2452
|
};
|
|
1880
|
-
|
|
1881
2453
|
/**
|
|
1882
|
-
*
|
|
1883
|
-
* Prevents excessive requests within a time window
|
|
2454
|
+
* Session item with subtle slide-right on hover
|
|
1884
2455
|
*/
|
|
1885
|
-
|
|
1886
|
-
|
|
1887
|
-
|
|
1888
|
-
|
|
1889
|
-
|
|
1890
|
-
|
|
1891
|
-
|
|
1892
|
-
|
|
1893
|
-
|
|
1894
|
-
|
|
1895
|
-
|
|
1896
|
-
|
|
1897
|
-
|
|
1898
|
-
|
|
1899
|
-
|
|
1900
|
-
|
|
1901
|
-
|
|
1902
|
-
|
|
1903
|
-
|
|
1904
|
-
|
|
1905
|
-
|
|
1906
|
-
|
|
1907
|
-
|
|
1908
|
-
}
|
|
2456
|
+
declare const sessionItemVariants: {
|
|
2457
|
+
initial: {
|
|
2458
|
+
opacity: number;
|
|
2459
|
+
x: number;
|
|
2460
|
+
};
|
|
2461
|
+
animate: {
|
|
2462
|
+
opacity: number;
|
|
2463
|
+
x: number;
|
|
2464
|
+
transition: {
|
|
2465
|
+
duration: number;
|
|
2466
|
+
};
|
|
2467
|
+
};
|
|
2468
|
+
hover: {
|
|
2469
|
+
x: number;
|
|
2470
|
+
transition: {
|
|
2471
|
+
duration: number;
|
|
2472
|
+
};
|
|
2473
|
+
};
|
|
2474
|
+
exit: {
|
|
2475
|
+
opacity: number;
|
|
2476
|
+
x: number;
|
|
2477
|
+
transition: {
|
|
2478
|
+
duration: number;
|
|
2479
|
+
};
|
|
2480
|
+
};
|
|
2481
|
+
};
|
|
2482
|
+
/**
|
|
2483
|
+
* Error/alert message slide-in
|
|
2484
|
+
*/
|
|
2485
|
+
declare const errorMessageVariants: {
|
|
2486
|
+
initial: {
|
|
2487
|
+
opacity: number;
|
|
2488
|
+
y: number;
|
|
2489
|
+
height: number;
|
|
2490
|
+
};
|
|
2491
|
+
animate: {
|
|
2492
|
+
opacity: number;
|
|
2493
|
+
y: number;
|
|
2494
|
+
height: string;
|
|
2495
|
+
transition: {
|
|
2496
|
+
duration: number;
|
|
2497
|
+
ease: number[];
|
|
2498
|
+
};
|
|
2499
|
+
};
|
|
2500
|
+
exit: {
|
|
2501
|
+
opacity: number;
|
|
2502
|
+
y: number;
|
|
2503
|
+
height: number;
|
|
2504
|
+
transition: {
|
|
2505
|
+
duration: number;
|
|
2506
|
+
};
|
|
2507
|
+
};
|
|
2508
|
+
};
|
|
1909
2509
|
|
|
1910
2510
|
interface ChatSessionProviderProps {
|
|
1911
2511
|
dataSource: ChatDataSource;
|
|
@@ -1914,30 +2514,26 @@ interface ChatSessionProviderProps {
|
|
|
1914
2514
|
children: ReactNode;
|
|
1915
2515
|
}
|
|
1916
2516
|
declare function ChatSessionProvider({ dataSource, sessionId, rateLimiter: externalRateLimiter, children }: ChatSessionProviderProps): react_jsx_runtime.JSX.Element;
|
|
2517
|
+
declare function useChatSession(): ChatSessionStateValue;
|
|
2518
|
+
declare function useChatMessaging(): ChatMessagingStateValue;
|
|
2519
|
+
/** Returns messaging context or null when outside ChatSessionProvider. Use when component can receive values via props (e.g. SessionArtifactsPanel with artifactsInvalidationTrigger prop). */
|
|
2520
|
+
declare function useOptionalChatMessaging(): ChatMessagingStateValue | null;
|
|
2521
|
+
declare function useChatInput(): ChatInputStateValue;
|
|
1917
2522
|
declare function useChat(): ChatSessionContextValue;
|
|
1918
2523
|
|
|
1919
2524
|
/**
|
|
1920
|
-
*
|
|
2525
|
+
* BiChat context types layered on top of canonical applet-core context contracts.
|
|
1921
2526
|
*/
|
|
1922
|
-
|
|
1923
|
-
|
|
1924
|
-
|
|
1925
|
-
|
|
1926
|
-
|
|
1927
|
-
permissions: string[];
|
|
1928
|
-
}
|
|
1929
|
-
interface TenantContext {
|
|
1930
|
-
id: string;
|
|
1931
|
-
name: string;
|
|
1932
|
-
}
|
|
1933
|
-
interface LocaleContext {
|
|
1934
|
-
language: string;
|
|
1935
|
-
translations: Record<string, string>;
|
|
1936
|
-
}
|
|
1937
|
-
interface AppConfig {
|
|
1938
|
-
graphQLEndpoint: string;
|
|
2527
|
+
|
|
2528
|
+
type UserContext = UserContext$1;
|
|
2529
|
+
type TenantContext = TenantContext$1;
|
|
2530
|
+
type LocaleContext = LocaleContext$1;
|
|
2531
|
+
type AppConfig = AppConfig$1 & {
|
|
1939
2532
|
streamEndpoint: string;
|
|
1940
|
-
|
|
2533
|
+
basePath: string;
|
|
2534
|
+
assetsBasePath: string;
|
|
2535
|
+
rpcUIEndpoint: string;
|
|
2536
|
+
};
|
|
1941
2537
|
interface Extensions {
|
|
1942
2538
|
branding?: {
|
|
1943
2539
|
appName?: string;
|
|
@@ -1972,14 +2568,23 @@ interface Extensions {
|
|
|
1972
2568
|
codeInterpreter?: boolean;
|
|
1973
2569
|
multiAgent?: boolean;
|
|
1974
2570
|
};
|
|
2571
|
+
llm?: {
|
|
2572
|
+
provider?: string;
|
|
2573
|
+
apiKeyConfigured?: boolean;
|
|
2574
|
+
};
|
|
2575
|
+
debug?: {
|
|
2576
|
+
limits?: {
|
|
2577
|
+
policyMaxTokens: number;
|
|
2578
|
+
modelMaxTokens: number;
|
|
2579
|
+
effectiveMaxTokens: number;
|
|
2580
|
+
completionReserveTokens: number;
|
|
2581
|
+
};
|
|
2582
|
+
};
|
|
1975
2583
|
}
|
|
1976
|
-
|
|
1977
|
-
user: UserContext;
|
|
1978
|
-
tenant: TenantContext;
|
|
1979
|
-
locale: LocaleContext;
|
|
2584
|
+
type IotaContext = Omit<InitialContext, 'config' | 'extensions'> & {
|
|
1980
2585
|
config: AppConfig;
|
|
1981
2586
|
extensions?: Extensions;
|
|
1982
|
-
}
|
|
2587
|
+
};
|
|
1983
2588
|
declare global {
|
|
1984
2589
|
interface Window {
|
|
1985
2590
|
__BICHAT_CONTEXT__: IotaContext;
|
|
@@ -2014,7 +2619,7 @@ interface BiChatConfig {
|
|
|
2014
2619
|
translations: Record<string, string>;
|
|
2015
2620
|
};
|
|
2016
2621
|
endpoints: {
|
|
2017
|
-
|
|
2622
|
+
rpc: string;
|
|
2018
2623
|
stream: string;
|
|
2019
2624
|
};
|
|
2020
2625
|
csrfToken?: string;
|
|
@@ -2131,23 +2736,25 @@ declare function createHeadersWithCSRF(init?: HeadersInit): Headers;
|
|
|
2131
2736
|
|
|
2132
2737
|
/**
|
|
2133
2738
|
* Built-in HTTP data source with SSE streaming and AbortController
|
|
2134
|
-
* Implements ChatDataSource interface with real HTTP/
|
|
2739
|
+
* Implements ChatDataSource interface with real HTTP/RPC calls
|
|
2135
2740
|
*
|
|
2136
2741
|
* Uses turn-based architecture - fetches ConversationTurns instead of flat messages.
|
|
2137
2742
|
*/
|
|
2138
2743
|
|
|
2139
2744
|
interface HttpDataSourceConfig {
|
|
2140
2745
|
baseUrl: string;
|
|
2141
|
-
|
|
2746
|
+
rpcEndpoint: string;
|
|
2142
2747
|
streamEndpoint?: string;
|
|
2143
2748
|
csrfToken?: string | (() => string);
|
|
2144
2749
|
headers?: Record<string, string>;
|
|
2145
2750
|
timeout?: number;
|
|
2751
|
+
/** Optional: called when a new session is created so the host app can navigate (e.g. SPA router) */
|
|
2752
|
+
navigateToSession?: (sessionId: string) => void;
|
|
2146
2753
|
}
|
|
2147
2754
|
interface SessionState {
|
|
2148
|
-
session: Session;
|
|
2149
|
-
turns: ConversationTurn[];
|
|
2150
|
-
pendingQuestion?: PendingQuestion | null;
|
|
2755
|
+
session: Session$1;
|
|
2756
|
+
turns: ConversationTurn$1[];
|
|
2757
|
+
pendingQuestion?: PendingQuestion$1 | null;
|
|
2151
2758
|
}
|
|
2152
2759
|
interface Result<T> {
|
|
2153
2760
|
success: boolean;
|
|
@@ -2157,6 +2764,7 @@ interface Result<T> {
|
|
|
2157
2764
|
declare class HttpDataSource implements ChatDataSource {
|
|
2158
2765
|
private config;
|
|
2159
2766
|
private abortController;
|
|
2767
|
+
private rpc;
|
|
2160
2768
|
constructor(config: HttpDataSourceConfig);
|
|
2161
2769
|
/**
|
|
2162
2770
|
* Get CSRF token from config
|
|
@@ -2166,57 +2774,383 @@ declare class HttpDataSource implements ChatDataSource {
|
|
|
2166
2774
|
* Create headers for HTTP requests
|
|
2167
2775
|
*/
|
|
2168
2776
|
private createHeaders;
|
|
2169
|
-
|
|
2170
|
-
* Execute GraphQL query
|
|
2171
|
-
*/
|
|
2172
|
-
private graphql;
|
|
2777
|
+
private callRPC;
|
|
2173
2778
|
/**
|
|
2174
2779
|
* Create a new chat session
|
|
2175
2780
|
*/
|
|
2176
|
-
createSession(): Promise<Session>;
|
|
2781
|
+
createSession(): Promise<Session$1>;
|
|
2177
2782
|
/**
|
|
2178
2783
|
* Fetch an existing session with turns (turn-based architecture)
|
|
2179
2784
|
*/
|
|
2180
2785
|
fetchSession(id: string): Promise<SessionState | null>;
|
|
2786
|
+
fetchSessionArtifacts(sessionId: string, options?: {
|
|
2787
|
+
limit?: number;
|
|
2788
|
+
offset?: number;
|
|
2789
|
+
}): Promise<{
|
|
2790
|
+
artifacts: SessionArtifact[];
|
|
2791
|
+
hasMore?: boolean;
|
|
2792
|
+
nextOffset?: number;
|
|
2793
|
+
}>;
|
|
2794
|
+
uploadSessionArtifacts(sessionId: string, files: File[]): Promise<{
|
|
2795
|
+
artifacts: SessionArtifact[];
|
|
2796
|
+
}>;
|
|
2797
|
+
renameSessionArtifact(artifactId: string, name: string, description?: string): Promise<SessionArtifact>;
|
|
2798
|
+
deleteSessionArtifact(artifactId: string): Promise<void>;
|
|
2181
2799
|
/**
|
|
2182
2800
|
* Send a message and stream the response using SSE
|
|
2183
2801
|
*/
|
|
2184
|
-
sendMessage(sessionId: string, content: string, attachments?: Attachment[], signal?: AbortSignal): AsyncGenerator<StreamChunk>;
|
|
2802
|
+
sendMessage(sessionId: string, content: string, attachments?: Attachment$1[], signal?: AbortSignal, options?: SendMessageOptions): AsyncGenerator<StreamChunk>;
|
|
2185
2803
|
/**
|
|
2186
2804
|
* Cancel ongoing stream
|
|
2187
2805
|
*/
|
|
2188
2806
|
cancelStream(): void;
|
|
2807
|
+
/**
|
|
2808
|
+
* Clear session history in-place.
|
|
2809
|
+
*/
|
|
2810
|
+
clearSessionHistory(sessionId: string): Promise<{
|
|
2811
|
+
success: boolean;
|
|
2812
|
+
deletedMessages: number;
|
|
2813
|
+
deletedArtifacts: number;
|
|
2814
|
+
}>;
|
|
2815
|
+
/**
|
|
2816
|
+
* Compact session history into summarized turn.
|
|
2817
|
+
*/
|
|
2818
|
+
compactSessionHistory(sessionId: string): Promise<{
|
|
2819
|
+
success: boolean;
|
|
2820
|
+
summary: string;
|
|
2821
|
+
deletedMessages: number;
|
|
2822
|
+
deletedArtifacts: number;
|
|
2823
|
+
}>;
|
|
2189
2824
|
/**
|
|
2190
2825
|
* Submit answers to a pending question
|
|
2191
2826
|
*/
|
|
2192
2827
|
submitQuestionAnswers(sessionId: string, questionId: string, answers: QuestionAnswers): Promise<Result<void>>;
|
|
2193
2828
|
/**
|
|
2194
|
-
*
|
|
2829
|
+
* Reject a pending question
|
|
2195
2830
|
*/
|
|
2196
|
-
|
|
2831
|
+
rejectPendingQuestion(sessionId: string): Promise<Result<void>>;
|
|
2197
2832
|
/**
|
|
2198
2833
|
* Navigate to a session (optional, for SPA routing)
|
|
2199
2834
|
*/
|
|
2200
2835
|
navigateToSession?(sessionId: string): void;
|
|
2836
|
+
listSessions(options?: {
|
|
2837
|
+
limit?: number;
|
|
2838
|
+
offset?: number;
|
|
2839
|
+
includeArchived?: boolean;
|
|
2840
|
+
}): Promise<SessionListResult$1>;
|
|
2841
|
+
archiveSession(sessionId: string): Promise<Session$1>;
|
|
2842
|
+
unarchiveSession(sessionId: string): Promise<Session$1>;
|
|
2843
|
+
pinSession(sessionId: string): Promise<Session$1>;
|
|
2844
|
+
unpinSession(sessionId: string): Promise<Session$1>;
|
|
2845
|
+
deleteSession(sessionId: string): Promise<void>;
|
|
2846
|
+
renameSession(sessionId: string, title: string): Promise<Session$1>;
|
|
2847
|
+
regenerateSessionTitle(sessionId: string): Promise<Session$1>;
|
|
2201
2848
|
}
|
|
2202
2849
|
/**
|
|
2203
2850
|
* Factory function to create HttpDataSource
|
|
2204
2851
|
*/
|
|
2205
2852
|
declare function createHttpDataSource(config: HttpDataSourceConfig): ChatDataSource;
|
|
2206
2853
|
|
|
2854
|
+
type BichatRPC = {
|
|
2855
|
+
"bichat.artifact.delete": {
|
|
2856
|
+
params: ArtifactIDParams;
|
|
2857
|
+
result: OkResult;
|
|
2858
|
+
};
|
|
2859
|
+
"bichat.artifact.update": {
|
|
2860
|
+
params: ArtifactUpdateParams;
|
|
2861
|
+
result: ArtifactResult;
|
|
2862
|
+
};
|
|
2863
|
+
"bichat.ping": {
|
|
2864
|
+
params: PingParams;
|
|
2865
|
+
result: PingResult;
|
|
2866
|
+
};
|
|
2867
|
+
"bichat.question.reject": {
|
|
2868
|
+
params: QuestionCancelParams;
|
|
2869
|
+
result: SessionGetResult;
|
|
2870
|
+
};
|
|
2871
|
+
"bichat.question.submit": {
|
|
2872
|
+
params: QuestionSubmitParams;
|
|
2873
|
+
result: SessionGetResult;
|
|
2874
|
+
};
|
|
2875
|
+
"bichat.session.archive": {
|
|
2876
|
+
params: SessionIDParams;
|
|
2877
|
+
result: SessionCreateResult;
|
|
2878
|
+
};
|
|
2879
|
+
"bichat.session.artifacts": {
|
|
2880
|
+
params: SessionArtifactsParams;
|
|
2881
|
+
result: SessionArtifactsResult;
|
|
2882
|
+
};
|
|
2883
|
+
"bichat.session.clear": {
|
|
2884
|
+
params: SessionIDParams;
|
|
2885
|
+
result: SessionClearResult;
|
|
2886
|
+
};
|
|
2887
|
+
"bichat.session.compact": {
|
|
2888
|
+
params: SessionIDParams;
|
|
2889
|
+
result: SessionCompactResult;
|
|
2890
|
+
};
|
|
2891
|
+
"bichat.session.create": {
|
|
2892
|
+
params: SessionCreateParams;
|
|
2893
|
+
result: SessionCreateResult;
|
|
2894
|
+
};
|
|
2895
|
+
"bichat.session.delete": {
|
|
2896
|
+
params: SessionIDParams;
|
|
2897
|
+
result: OkResult;
|
|
2898
|
+
};
|
|
2899
|
+
"bichat.session.get": {
|
|
2900
|
+
params: SessionGetParams;
|
|
2901
|
+
result: SessionGetResult;
|
|
2902
|
+
};
|
|
2903
|
+
"bichat.session.list": {
|
|
2904
|
+
params: SessionListParams;
|
|
2905
|
+
result: SessionListResult;
|
|
2906
|
+
};
|
|
2907
|
+
"bichat.session.pin": {
|
|
2908
|
+
params: SessionIDParams;
|
|
2909
|
+
result: SessionCreateResult;
|
|
2910
|
+
};
|
|
2911
|
+
"bichat.session.regenerateTitle": {
|
|
2912
|
+
params: SessionIDParams;
|
|
2913
|
+
result: SessionCreateResult;
|
|
2914
|
+
};
|
|
2915
|
+
"bichat.session.unarchive": {
|
|
2916
|
+
params: SessionIDParams;
|
|
2917
|
+
result: SessionCreateResult;
|
|
2918
|
+
};
|
|
2919
|
+
"bichat.session.unpin": {
|
|
2920
|
+
params: SessionIDParams;
|
|
2921
|
+
result: SessionCreateResult;
|
|
2922
|
+
};
|
|
2923
|
+
"bichat.session.updateTitle": {
|
|
2924
|
+
params: SessionUpdateTitleParams;
|
|
2925
|
+
result: SessionCreateResult;
|
|
2926
|
+
};
|
|
2927
|
+
"bichat.session.uploadArtifacts": {
|
|
2928
|
+
params: SessionUploadArtifactsParams;
|
|
2929
|
+
result: SessionUploadArtifactsResult;
|
|
2930
|
+
};
|
|
2931
|
+
};
|
|
2932
|
+
interface Artifact {
|
|
2933
|
+
id: string;
|
|
2934
|
+
sessionId: string;
|
|
2935
|
+
messageId?: string;
|
|
2936
|
+
type: string;
|
|
2937
|
+
name: string;
|
|
2938
|
+
description?: string;
|
|
2939
|
+
mimeType?: string;
|
|
2940
|
+
url?: string;
|
|
2941
|
+
sizeBytes: number;
|
|
2942
|
+
metadata?: Record<string, unknown>;
|
|
2943
|
+
createdAt: string;
|
|
2944
|
+
}
|
|
2945
|
+
interface ArtifactIDParams {
|
|
2946
|
+
id: string;
|
|
2947
|
+
}
|
|
2948
|
+
interface ArtifactResult {
|
|
2949
|
+
artifact: Artifact;
|
|
2950
|
+
}
|
|
2951
|
+
interface ArtifactUpdateParams {
|
|
2952
|
+
id: string;
|
|
2953
|
+
name: string;
|
|
2954
|
+
description?: string;
|
|
2955
|
+
}
|
|
2956
|
+
interface AssistantTurn {
|
|
2957
|
+
id: string;
|
|
2958
|
+
role?: string;
|
|
2959
|
+
content: string;
|
|
2960
|
+
explanation?: string;
|
|
2961
|
+
citations: Citation[];
|
|
2962
|
+
toolCalls?: ToolCall[];
|
|
2963
|
+
debug?: DebugTrace | null;
|
|
2964
|
+
artifacts: unknown[];
|
|
2965
|
+
codeOutputs: CodeOutput[];
|
|
2966
|
+
createdAt: string;
|
|
2967
|
+
}
|
|
2968
|
+
interface Attachment {
|
|
2969
|
+
id: string;
|
|
2970
|
+
filename: string;
|
|
2971
|
+
mimeType: string;
|
|
2972
|
+
sizeBytes: number;
|
|
2973
|
+
base64Data?: string;
|
|
2974
|
+
url?: string;
|
|
2975
|
+
}
|
|
2976
|
+
interface Citation {
|
|
2977
|
+
id: string;
|
|
2978
|
+
type: string;
|
|
2979
|
+
title: string;
|
|
2980
|
+
url: string;
|
|
2981
|
+
startIndex: number;
|
|
2982
|
+
endIndex: number;
|
|
2983
|
+
excerpt?: string;
|
|
2984
|
+
source?: string;
|
|
2985
|
+
}
|
|
2986
|
+
interface CodeOutput {
|
|
2987
|
+
type: string;
|
|
2988
|
+
content: string;
|
|
2989
|
+
filename?: string;
|
|
2990
|
+
mimeType?: string;
|
|
2991
|
+
sizeBytes?: number;
|
|
2992
|
+
}
|
|
2993
|
+
interface ConversationTurn {
|
|
2994
|
+
id: string;
|
|
2995
|
+
sessionId: string;
|
|
2996
|
+
userTurn: UserTurn;
|
|
2997
|
+
assistantTurn?: AssistantTurn | null;
|
|
2998
|
+
createdAt: string;
|
|
2999
|
+
}
|
|
3000
|
+
interface DebugToolCall {
|
|
3001
|
+
callId?: string;
|
|
3002
|
+
name?: string;
|
|
3003
|
+
arguments?: string;
|
|
3004
|
+
result?: string;
|
|
3005
|
+
error?: string;
|
|
3006
|
+
durationMs?: number;
|
|
3007
|
+
}
|
|
3008
|
+
interface DebugTrace {
|
|
3009
|
+
usage?: DebugUsage | null;
|
|
3010
|
+
generationMs?: number;
|
|
3011
|
+
tools?: DebugToolCall[];
|
|
3012
|
+
}
|
|
3013
|
+
interface DebugUsage {
|
|
3014
|
+
promptTokens: number;
|
|
3015
|
+
completionTokens: number;
|
|
3016
|
+
totalTokens: number;
|
|
3017
|
+
cachedTokens: number;
|
|
3018
|
+
cost: number;
|
|
3019
|
+
}
|
|
3020
|
+
interface OkResult {
|
|
3021
|
+
ok: boolean;
|
|
3022
|
+
}
|
|
3023
|
+
interface PendingQuestion {
|
|
3024
|
+
checkpointId: string;
|
|
3025
|
+
agentName?: string;
|
|
3026
|
+
turnId: string;
|
|
3027
|
+
questions: PendingQuestionItem[];
|
|
3028
|
+
}
|
|
3029
|
+
interface PendingQuestionItem {
|
|
3030
|
+
id: string;
|
|
3031
|
+
text: string;
|
|
3032
|
+
type: string;
|
|
3033
|
+
options: PendingQuestionOption[];
|
|
3034
|
+
}
|
|
3035
|
+
interface PendingQuestionOption {
|
|
3036
|
+
id: string;
|
|
3037
|
+
label: string;
|
|
3038
|
+
}
|
|
3039
|
+
type PingParams = Record<string, never>;
|
|
3040
|
+
interface PingResult {
|
|
3041
|
+
ok: boolean;
|
|
3042
|
+
tenantId: string;
|
|
3043
|
+
}
|
|
3044
|
+
interface QuestionCancelParams {
|
|
3045
|
+
sessionId: string;
|
|
3046
|
+
}
|
|
3047
|
+
interface QuestionSubmitParams {
|
|
3048
|
+
sessionId: string;
|
|
3049
|
+
checkpointId: string;
|
|
3050
|
+
answers: Record<string, string>;
|
|
3051
|
+
}
|
|
3052
|
+
interface Session {
|
|
3053
|
+
id: string;
|
|
3054
|
+
title: string;
|
|
3055
|
+
status: string;
|
|
3056
|
+
pinned: boolean;
|
|
3057
|
+
createdAt: string;
|
|
3058
|
+
updatedAt: string;
|
|
3059
|
+
}
|
|
3060
|
+
interface SessionArtifactsParams {
|
|
3061
|
+
sessionId: string;
|
|
3062
|
+
limit: number;
|
|
3063
|
+
offset: number;
|
|
3064
|
+
}
|
|
3065
|
+
interface SessionArtifactsResult {
|
|
3066
|
+
artifacts: Artifact[];
|
|
3067
|
+
hasMore: boolean;
|
|
3068
|
+
nextOffset: number;
|
|
3069
|
+
}
|
|
3070
|
+
interface SessionClearResult {
|
|
3071
|
+
success: boolean;
|
|
3072
|
+
deletedMessages: number;
|
|
3073
|
+
deletedArtifacts: number;
|
|
3074
|
+
}
|
|
3075
|
+
interface SessionCompactResult {
|
|
3076
|
+
success: boolean;
|
|
3077
|
+
summary: string;
|
|
3078
|
+
deletedMessages: number;
|
|
3079
|
+
deletedArtifacts: number;
|
|
3080
|
+
}
|
|
3081
|
+
interface SessionCreateParams {
|
|
3082
|
+
title: string;
|
|
3083
|
+
}
|
|
3084
|
+
interface SessionCreateResult {
|
|
3085
|
+
session: Session;
|
|
3086
|
+
}
|
|
3087
|
+
interface SessionGetParams {
|
|
3088
|
+
id: string;
|
|
3089
|
+
}
|
|
3090
|
+
interface SessionGetResult {
|
|
3091
|
+
session: Session;
|
|
3092
|
+
turns: ConversationTurn[];
|
|
3093
|
+
pendingQuestion?: PendingQuestion | null;
|
|
3094
|
+
}
|
|
3095
|
+
interface SessionIDParams {
|
|
3096
|
+
id: string;
|
|
3097
|
+
}
|
|
3098
|
+
interface SessionListParams {
|
|
3099
|
+
limit: number;
|
|
3100
|
+
offset: number;
|
|
3101
|
+
includeArchived: boolean;
|
|
3102
|
+
}
|
|
3103
|
+
interface SessionListResult {
|
|
3104
|
+
sessions: Session[];
|
|
3105
|
+
total?: number;
|
|
3106
|
+
hasMore: boolean;
|
|
3107
|
+
}
|
|
3108
|
+
interface SessionUpdateTitleParams {
|
|
3109
|
+
id: string;
|
|
3110
|
+
title: string;
|
|
3111
|
+
}
|
|
3112
|
+
interface SessionUploadArtifactsParams {
|
|
3113
|
+
sessionId: string;
|
|
3114
|
+
attachments: Attachment[];
|
|
3115
|
+
}
|
|
3116
|
+
interface SessionUploadArtifactsResult {
|
|
3117
|
+
artifacts: Artifact[];
|
|
3118
|
+
}
|
|
3119
|
+
interface ToolCall {
|
|
3120
|
+
id: string;
|
|
3121
|
+
name: string;
|
|
3122
|
+
arguments: string;
|
|
3123
|
+
result?: string;
|
|
3124
|
+
error?: string;
|
|
3125
|
+
durationMs?: number;
|
|
3126
|
+
}
|
|
3127
|
+
interface UserTurn {
|
|
3128
|
+
id: string;
|
|
3129
|
+
content: string;
|
|
3130
|
+
attachments: Attachment[];
|
|
3131
|
+
createdAt: string;
|
|
3132
|
+
}
|
|
3133
|
+
|
|
2207
3134
|
/**
|
|
2208
3135
|
* File Utilities
|
|
2209
3136
|
* Validation, conversion, and formatting for file attachments
|
|
2210
3137
|
*/
|
|
3138
|
+
declare const ATTACHMENT_ACCEPT_ATTRIBUTE: string;
|
|
3139
|
+
declare function isImageMimeType(mimeType: string): boolean;
|
|
2211
3140
|
/**
|
|
2212
|
-
* Validates
|
|
3141
|
+
* Validates a file against size and type constraints
|
|
2213
3142
|
* @throws Error if validation fails
|
|
2214
3143
|
*/
|
|
2215
|
-
declare function
|
|
3144
|
+
declare function validateAttachmentFile(file: File$1, maxSizeBytes?: number): void;
|
|
3145
|
+
/**
|
|
3146
|
+
* Backward-compatible image validator used by older components/stories.
|
|
3147
|
+
*/
|
|
3148
|
+
declare function validateImageFile(file: File$1, maxSizeBytes?: number): void;
|
|
2216
3149
|
/**
|
|
2217
|
-
* Converts a file to base64 string (without data URL prefix)
|
|
3150
|
+
* Converts a file to base64 string (without data URL prefix).
|
|
3151
|
+
* Prefers FileReader data URLs, then falls back to buffer-based encoding.
|
|
2218
3152
|
*/
|
|
2219
|
-
declare function convertToBase64(file: File): Promise<string>;
|
|
3153
|
+
declare function convertToBase64(file: File$1): Promise<string>;
|
|
2220
3154
|
/**
|
|
2221
3155
|
* Creates a data URL from base64 string and MIME type
|
|
2222
3156
|
*/
|
|
@@ -2231,6 +3165,25 @@ declare function formatFileSize(bytes: number): string;
|
|
|
2231
3165
|
*/
|
|
2232
3166
|
declare function validateFileCount(currentCount: number, newCount: number, maxCount?: number): void;
|
|
2233
3167
|
|
|
3168
|
+
interface FileVisual {
|
|
3169
|
+
/** Phosphor icon component */
|
|
3170
|
+
icon: typeof File$1;
|
|
3171
|
+
/** Tailwind text-color classes for the icon (light + dark) */
|
|
3172
|
+
iconColor: string;
|
|
3173
|
+
/** Tailwind background classes for the icon container (light + dark) */
|
|
3174
|
+
bgColor: string;
|
|
3175
|
+
/** Short label (PDF, CSV, XLS, etc.) */
|
|
3176
|
+
label: string;
|
|
3177
|
+
}
|
|
3178
|
+
/**
|
|
3179
|
+
* Resolves visual metadata (icon, colors, label) for a file based on
|
|
3180
|
+
* its MIME type and/or filename. Single source of truth used by
|
|
3181
|
+
* AttachmentGrid, SessionArtifactList, DownloadCard, etc.
|
|
3182
|
+
*/
|
|
3183
|
+
declare function getFileVisual(mimeType?: string, filename?: string): FileVisual;
|
|
3184
|
+
/** Chart-specific visual (not mime-based, used for artifact type = 'chart') */
|
|
3185
|
+
declare const CHART_VISUAL: FileVisual;
|
|
3186
|
+
|
|
2234
3187
|
/**
|
|
2235
3188
|
* Citation Processing Utility
|
|
2236
3189
|
*
|
|
@@ -2247,7 +3200,7 @@ interface ProcessedContent {
|
|
|
2247
3200
|
/** Content with citation markers replaced by [1], [2], etc. */
|
|
2248
3201
|
content: string;
|
|
2249
3202
|
/** Citations array with their display indices */
|
|
2250
|
-
citations: Array<Citation & {
|
|
3203
|
+
citations: Array<Citation$1 & {
|
|
2251
3204
|
displayIndex: number;
|
|
2252
3205
|
}>;
|
|
2253
3206
|
}
|
|
@@ -2268,6 +3221,77 @@ interface ProcessedContent {
|
|
|
2268
3221
|
* // result.citations = [{ ..., displayIndex: 1 }]
|
|
2269
3222
|
* ```
|
|
2270
3223
|
*/
|
|
2271
|
-
declare function processCitations(content: string, citations: Citation[] | null | undefined): ProcessedContent;
|
|
3224
|
+
declare function processCitations(content: string, citations: Citation$1[] | null | undefined): ProcessedContent;
|
|
3225
|
+
|
|
3226
|
+
/**
|
|
3227
|
+
* Normalizes partially-streamed markdown so that react-markdown
|
|
3228
|
+
* can render it without layout artifacts (e.g. an unclosed code fence
|
|
3229
|
+
* turning the rest of the message into a code block).
|
|
3230
|
+
*
|
|
3231
|
+
* Called on every streaming content update — kept intentionally cheap (O(lines)).
|
|
3232
|
+
*/
|
|
3233
|
+
declare function normalizeStreamingMarkdown(text: string): string;
|
|
3234
|
+
|
|
3235
|
+
/**
|
|
3236
|
+
* SSE stream parser for consuming Server-Sent Events.
|
|
3237
|
+
*/
|
|
3238
|
+
interface SSEEvent {
|
|
3239
|
+
type: string;
|
|
3240
|
+
content?: string;
|
|
3241
|
+
error?: string;
|
|
3242
|
+
sessionId?: string;
|
|
3243
|
+
toolName?: string;
|
|
3244
|
+
toolCallId?: string;
|
|
3245
|
+
durationMs?: number;
|
|
3246
|
+
success?: boolean;
|
|
3247
|
+
[key: string]: unknown;
|
|
3248
|
+
}
|
|
3249
|
+
/**
|
|
3250
|
+
* Parses an SSE stream and yields parsed JSON events.
|
|
3251
|
+
*/
|
|
3252
|
+
declare function parseSSEStream(reader: ReadableStreamDefaultReader<Uint8Array>): AsyncGenerator<SSEEvent, void, unknown>;
|
|
3253
|
+
|
|
3254
|
+
/**
|
|
3255
|
+
* Groups chat sessions by date relative to today
|
|
3256
|
+
* Categories: Today, Yesterday, Last 7 Days, Last 30 Days, Older
|
|
3257
|
+
* Sessions within each group are sorted by updatedAt (most recent first)
|
|
3258
|
+
*/
|
|
3259
|
+
declare function groupSessionsByDate(sessions: Session$1[], t?: (key: string) => string): SessionGroup[];
|
|
3260
|
+
|
|
3261
|
+
/**
|
|
3262
|
+
* Date formatting utilities using date-fns
|
|
3263
|
+
*/
|
|
3264
|
+
/**
|
|
3265
|
+
* Format a date as relative time (e.g., "5m ago", "2h ago")
|
|
3266
|
+
* Falls back to HH:mm format for dates older than 24 hours
|
|
3267
|
+
*
|
|
3268
|
+
* Accepts an optional `t` function for i18n. Translation keys used:
|
|
3269
|
+
* - relativeTime.justNow
|
|
3270
|
+
* - relativeTime.minutesAgo (receives `{count}`)
|
|
3271
|
+
* - relativeTime.hoursAgo (receives `{count}`)
|
|
3272
|
+
* - relativeTime.daysAgo (receives `{count}`)
|
|
3273
|
+
*
|
|
3274
|
+
* If no `t` function is provided, falls back to English defaults.
|
|
3275
|
+
*/
|
|
3276
|
+
declare function formatRelativeTime(date: string | Date, t?: (key: string, params?: Record<string, string | number>) => string): string;
|
|
3277
|
+
|
|
3278
|
+
/**
|
|
3279
|
+
* Shared validation utilities for QuestionForm components
|
|
3280
|
+
*/
|
|
3281
|
+
|
|
3282
|
+
/**
|
|
3283
|
+
* Checks if a question has been answered.
|
|
3284
|
+
* A question is answered if it has at least one selected option OR custom text.
|
|
3285
|
+
*/
|
|
3286
|
+
declare function isQuestionAnswered(data: QuestionAnswerData | undefined): boolean;
|
|
3287
|
+
/**
|
|
3288
|
+
* Validates that all questions are answered and custom text is valid.
|
|
3289
|
+
* Returns null if valid, or an error message string if invalid.
|
|
3290
|
+
*
|
|
3291
|
+
* @param questions - Array of questions to validate
|
|
3292
|
+
* @param answers - Map of question IDs to answer data
|
|
3293
|
+
* @param t - Optional translation function for error messages
|
|
3294
|
+
*/
|
|
3295
|
+
declare function validateAnswers(questions: Question[], answers: QuestionAnswers, t?: (key: string, params?: Record<string, any>) => string): string | null;
|
|
2272
3296
|
|
|
2273
|
-
export { ActionButton, type ActionButtonIconProps, type ActionButtonLabelProps, type ActionButtonRootProps, type ActionButtonTooltipProps, type AppConfig, type Artifact, type AsChildProps, AssistantMessage, type AssistantMessageActionsSlotProps, type AssistantMessageArtifactsSlotProps, type AssistantMessageAvatarSlotProps, type AssistantMessageChartsSlotProps, type AssistantMessageClassNames, type AssistantMessageCodeOutputsSlotProps, type AssistantMessageContentSlotProps, type AssistantMessageExplanationSlotProps, type AssistantMessageProps, type AssistantMessageSlots, type AssistantMessageSourcesSlotProps, type AssistantTurn, AssistantTurnView, type AssistantTurnViewProps, type Attachment, MemoizedAttachmentGrid as AttachmentGrid, Avatar, type AvatarFallbackProps, type AvatarImageProps, type AvatarRootProps, type BiChatConfig, Bubble, type BubbleContentProps, type BubbleFooterProps, type BubbleHeaderProps, type BubbleMetadataProps, type BubbleRootProps, type BubbleVariant, ChartCard, type ChartData, type ChartSeries, type ChatDataSource, ChatHeader, ChatSession, type ChatSessionContextValue, ChatSessionProvider, type Citation, MemoizedCodeBlock as CodeBlock, type CodeOutput, CodeOutputsPanel, ConfigProvider, ConfirmModal, type ConfirmModalProps, type ConversationTurn, DefaultErrorContent, DownloadCard, MemoizedEditableText as EditableText, type EditableTextProps, type EditableTextRef, MemoizedEmptyState as EmptyState, type EmptyStateProps, ErrorBoundary, type FileValidationError, HttpDataSource, type HttpDataSourceConfig, type ImageAttachment, type ImageLoadingStatus, ImageModal, InlineQuestionForm, type IotaContext, IotaContextProvider, ListItemSkeleton, MemoizedLoadingSpinner as LoadingSpinner, type LocaleContext, MemoizedMarkdownRenderer as MarkdownRenderer, MessageInput, type MessageInputProps, type MessageInputRef, MessageList, MessageRole, type PendingQuestion, PermissionGuard, type PermissionGuardProps, type ProcessedContent, type Question, type QuestionAnswerData, type QuestionAnswers, type QuestionOption, type QueuedMessage, RateLimiter, type RateLimiterConfig, ScrollToBottomButton, MemoizedSearchInput as SearchInput, type SearchInputProps, type Session, MemoizedSkeleton as Skeleton, SkeletonAvatar, SkeletonCard, SkeletonGroup, type SkeletonGroupProps, type SkeletonProps, SkeletonText, Slot, type SlotProps, SourcesPanel, type StreamChunk, StreamingCursor, TableExportButton, TableWithExport, type TenantContext, type Theme, type ThemeBorderRadius, type ThemeColors, ThemeProvider, type ThemeSpacing, Toast, ToastContainer, type ToastItem, type ToastProps, type ToastType, type ToolCall, Turn, type TurnActionsProps, type TurnAssistantProps, TurnBubble, type TurnBubbleClassNames, type TurnBubbleProps, type TurnRootProps, type TurnTimestampProps, type TurnUserProps, MemoizedTypingIndicator as TypingIndicator, type TypingIndicatorProps, type
|
|
3297
|
+
export { ATTACHMENT_ACCEPT_ATTRIBUTE, ActionButton, type ActionButtonIconProps, type ActionButtonLabelProps, type ActionButtonRootProps, type ActionButtonTooltipProps, _default$1 as Alert, AllChatsList, type AppConfig, _default as ArchiveBanner, ArchivedChatList, type Artifact$1 as Artifact, type AsChildProps, AssistantMessage, type AssistantMessageActionsSlotProps, type AssistantMessageArtifactsSlotProps, type AssistantMessageAvatarSlotProps, type AssistantMessageChartsSlotProps, type AssistantMessageClassNames, type AssistantMessageCodeOutputsSlotProps, type AssistantMessageContentSlotProps, type AssistantMessageExplanationSlotProps, type AssistantMessageProps, type AssistantMessageSlots, type AssistantMessageSourcesSlotProps, type AssistantTurn$1 as AssistantTurn, AssistantTurnView, type AssistantTurnViewProps, type Attachment$1 as Attachment, MemoizedAttachmentGrid as AttachmentGrid, AttachmentPreview, AttachmentUpload, Avatar, type AvatarFallbackProps, type AvatarImageProps, type AvatarRootProps, type BiChatConfig, type BichatRPC, Bubble, type BubbleContentProps, type BubbleFooterProps, type BubbleHeaderProps, type BubbleMetadataProps, type BubbleRootProps, type BubbleVariant, CHART_VISUAL, ChartCard, type ChartData, type ChartSeries, type ChatDataSource, ChatHeader, type ChatInputStateValue, type ChatMessagingStateValue, ChatSession, type ChatSessionContextValue, ChatSessionProvider, type ChatSessionStateValue, type Citation$1 as Citation, MemoizedCodeBlock as CodeBlock, type CodeOutput$1 as CodeOutput, CodeOutputsPanel, CompactionDoodle, ConfigProvider, ConfirmModal, type ConfirmModalProps, ConfirmationStep, type ConversationTurn$1 as ConversationTurn, DateGroupHeader, DebugPanel, type DebugPanelProps, DefaultErrorContent, DownloadCard, MemoizedEditableText as EditableText, type EditableTextProps, type EditableTextRef, MemoizedEmptyState as EmptyState, type EmptyStateProps, ErrorBoundary, type FileValidationError, type FileVisual, HttpDataSource, type HttpDataSourceConfig, type ImageAttachment, type ImageLoadingStatus, ImageModal, InlineQuestionForm, type IotaContext, IotaContextProvider, ListItemSkeleton, MemoizedLoadingSpinner as LoadingSpinner, type LocaleContext, MemoizedMarkdownRenderer as MarkdownRenderer, MessageActions, MessageInput, type MessageInputProps, type MessageInputRef, MessageList, MessageRole, type PendingQuestion$1 as PendingQuestion, PermissionGuard, type PermissionGuardProps, type ProcessedContent, type Question, type QuestionAnswerData, type QuestionAnswers, QuestionForm, type QuestionOption, QuestionStep, type QueuedMessage, RateLimiter, type RateLimiterConfig, RetryActionArea, type SSEEvent, ScreenReaderAnnouncer, ScrollToBottomButton, MemoizedSearchInput as SearchInput, type SearchInputProps, type Session$1 as Session, type SessionArtifact, SessionArtifactList, SessionArtifactPreview, SessionArtifactsPanel, type SessionGroup, SessionItem, type SessionListResult$1 as SessionListResult, SessionSkeleton, type SessionUser, type ShortcutConfig, Sidebar, MemoizedSkeleton as Skeleton, SkeletonAvatar, SkeletonCard, SkeletonGroup, type SkeletonGroupProps, type SkeletonProps, SkeletonText, SkipLink, Slot, type SlotProps, SourcesPanel, type StreamChunk, StreamError, StreamingCursor, SystemMessage, MemoizedTabBar as TabBar, TableExportButton, TableWithExport, type TenantContext, type Theme, type ThemeBorderRadius, type ThemeColors, ThemeProvider, type ThemeSpacing, Toast, ToastContainer, type ToastItem, type ToastProps, type ToastType, type ToolCall$1 as ToolCall, TouchContextMenu, Turn, type TurnActionsProps, type TurnAssistantProps, TurnBubble, type TurnBubbleClassNames, type TurnBubbleProps, type TurnRootProps, type TurnTimestampProps, type TurnUserProps, MemoizedTypingIndicator as TypingIndicator, type TypingIndicatorProps, type UseAttachmentsOptions, type UseAttachmentsReturn, type UseAutoScrollOptions, type UseAutoScrollReturn, type UseImageGalleryOptions, type UseImageGalleryReturn, type UseMarkdownCopyOptions, type UseMarkdownCopyReturn, type UseMessageActionsOptions, type UseMessageActionsReturn, type UseToastReturn, MemoizedUserAvatar as UserAvatar, type UserAvatarProps, type UserContext, MemoizedUserFilter as UserFilter, UserMessage, type UserMessageActionsSlotProps, type UserMessageAttachmentsSlotProps, type UserMessageAvatarSlotProps, type UserMessageClassNames, type UserMessageContentSlotProps, type UserMessageProps, type UserMessageSlots, type UserTurn$1 as UserTurn, UserTurnView, type UserTurnViewProps, WelcomeContent, addCSRFHeader, backdropVariants, buttonVariants, convertToBase64, createDataUrl, createHeadersWithCSRF, createHttpDataSource, darkTheme, dropdownVariants, errorMessageVariants, fadeInUpVariants, fadeInVariants, floatingButtonVariants, formatFileSize, formatRelativeTime, getCSRFToken, getFileVisual, getValidChildren, groupSessionsByDate, hasPermission as hasConfigPermission, hasPermission$1 as hasPermission, isImageMimeType, isQuestionAnswered, lightTheme, listItemVariants, messageContainerVariants, messageVariants, normalizeStreamingMarkdown, parseSSEStream, processCitations, scaleFadeVariants, sessionItemVariants, staggerContainerVariants, toastVariants, typingDotVariants, useActionButtonContext, useAttachments, useAutoScroll, useAvatarContext, useBubbleContext, useChat, useChatInput, useChatMessaging, useChatSession, useConfig, useFocusTrap, useImageGallery, useIotaContext, useKeyboardShortcuts, useLongPress, useMarkdownCopy, useMessageActions, useModalLock, useOptionalChatMessaging, useRequiredConfig, useScrollToBottom, useStreaming, useTheme, useToast, useTranslation, useTurnContext, validateAnswers, validateAttachmentFile, validateFileCount, validateImageFile, verbTransitionVariants };
|