MCPcopy Create free account
hub / github.com/experdot/pointer / ChatUIStore

Interface ChatUIStore

src/renderer/src/stores/chatUIStore.ts:31–51  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

29}
30
31interface ChatUIStore {
32 states: Map<string, ChatUIState>
33 getState: (pageId: string) => ChatUIState
34 setScrollTop: (pageId: string, scrollTop: number) => void
35 setInputContent: (pageId: string, content: string) => void
36 addPendingAttachment: (pageId: string, attachment: FileAttachment) => void
37 removePendingAttachment: (pageId: string, attachmentId: string) => void
38 clearPendingAttachments: (pageId: string) => void
39 clearState: (pageId: string) => void
40 // Search actions
41 setSearchOpen: (pageId: string, isOpen: boolean) => void
42 setSearchQuery: (pageId: string, query: string) => void
43 setSearchCurrentIndex: (pageId: string, index: number) => void
44 setSearchOptions: (
45 pageId: string,
46 options: Partial<Pick<SearchState, 'matchCase' | 'useRegex' | 'matchWholeWord'>>
47 ) => void
48 requestSearchFocus: (pageId: string) => void
49 clearSearch: (pageId: string) => void
50 reset: () => void
51}
52
53const defaultState: ChatUIState = {
54 scrollTop: -1, // -1 表示滚动到底部

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected