UNPKG

@assistant-ui/react

Version:

React components for AI chat.

61 lines (54 loc) 1.31 kB
export type ThreadListRuntimePath = { ref: string; }; export type ThreadListItemRuntimePath = { ref: string; threadSelector: | { type: "main" } | { type: "index"; index: number } | { type: "archiveIndex"; index: number } | { type: "threadId"; threadId: string }; }; export type ThreadRuntimePath = { ref: string; threadSelector: { type: "main" }; }; export type MessageRuntimePath = ThreadRuntimePath & { messageSelector: | { type: "messageId"; messageId: string } | { type: "index"; index: number }; }; export type ContentPartRuntimePath = MessageRuntimePath & { contentPartSelector: | { type: "index"; index: number } | { type: "toolCallId"; toolCallId: string }; }; export type AttachmentRuntimePath = ( | (MessageRuntimePath & { attachmentSource: "message" | "edit-composer"; }) | (ThreadRuntimePath & { attachmentSource: "thread-composer"; }) ) & { attachmentSelector: | { type: "index"; index: number; } | { type: "index"; index: number; } | { type: "index"; index: number; }; }; export type ComposerRuntimePath = | (ThreadRuntimePath & { composerSource: "thread"; }) | (MessageRuntimePath & { composerSource: "edit"; });