mirror of
https://github.com/DayuanJiang/next-ai-draw-io.git
synced 2026-01-06 08:12:30 +08:00
* refactor: extract ToolCallCard and ChatLobby components - Extract ToolCallCard.tsx (279 lines) for tool call UI rendering - Extract ChatLobby.tsx (272 lines) for empty state with session history - Reduce chat-message-display.tsx from 1760 to 1307 lines (-26%) * fix: address PR review feedback - Remove redundant key prop in ToolCallCard - Make onDeleteSession optional and conditionally render delete button - Extract shared types (DiagramOperation, ToolPartLike) to types.ts
17 lines
343 B
TypeScript
17 lines
343 B
TypeScript
export interface DiagramOperation {
|
|
operation: "update" | "add" | "delete"
|
|
cell_id: string
|
|
new_xml?: string
|
|
}
|
|
|
|
export interface ToolPartLike {
|
|
type: string
|
|
toolCallId: string
|
|
state?: string
|
|
input?: {
|
|
xml?: string
|
|
operations?: DiagramOperation[]
|
|
} & Record<string, unknown>
|
|
output?: string
|
|
}
|