UNPKG

@automattic/agenttic-ui

Version:

UI components for the Agenttic framework

41 lines 1.49 kB
import React from 'react'; import type { ComponentType } from 'react'; import type { ChatState, Message, NoticeConfig, Suggestion } from '../types'; export interface AgentUIContextValue { messages: Message[]; isProcessing: boolean; error?: string | null; inputValue: string; setInputValue: (value: string) => void; clearInput: () => void; textareaRef: React.RefObject<HTMLTextAreaElement>; handleKeyDown: (e: React.KeyboardEvent<HTMLTextAreaElement>) => void; onSubmit: (message: string) => void; handleSubmit: () => void; onStop?: () => void; variant: 'floating' | 'embedded'; placeholder?: string | string[]; emptyView?: React.ReactNode; messageRenderer?: ComponentType<{ children: string; }>; floatingChatState?: ChatState; triggerIcon?: React.ReactNode; onOpen?: () => void; onExpand?: () => void; onClose?: () => void; suggestions?: Suggestion[]; clearSuggestions?: () => void; handleSuggestionSubmit: (value: string) => void; notice?: NoticeConfig; focusOnMount?: boolean; fromCompact?: boolean; showExpandButton?: boolean; } export declare function useAgentUIContext(): AgentUIContextValue; export interface AgentUIProviderProps { children: React.ReactNode; value: AgentUIContextValue; } export declare function AgentUIProvider({ children, value }: AgentUIProviderProps): import("react/jsx-runtime").JSX.Element; //# sourceMappingURL=AgentUIContext.d.ts.map