@galaxycore/ai-chat 0.7.0 → 0.9.0

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.
@@ -0,0 +1,20 @@
1
+
2
+ import { ComponentType, ReactNode } from "react";
3
+ import { LucideProps } from "lucide-react";
4
+ //#region src/icons.d.ts
5
+ type ChatIconName = 'send' | 'stop' | 'plus' | 'close' | 'copy' | 'check' | 'refresh' | 'down' | 'file' | 'sparkle' | 'more' | 'edit' | 'chevron' | 'chevronLeft' | 'undo' | 'branch' | 'link' | 'tool' | 'thinking' | 'warning' | 'blocked' | 'loader' | 'mic' | 'audio' | 'text' | 'table' | 'chart' | 'page' | 'target' | 'external' | 'search' | 'compass' | 'scan' | 'paperclip' | 'layers' | 'at' | 'sliders' | 'zap';
6
+ type ChatIconProps = Omit<LucideProps, 'ref'>;
7
+ type ChatIconOverrides = Partial<Record<ChatIconName, ComponentType<ChatIconProps>>>;
8
+ interface ChatAppearanceProviderProps {
9
+ /** Replace just the icons your product needs. Overrides inherit through nested providers. */
10
+ icons?: ChatIconOverrides;
11
+ children: ReactNode;
12
+ }
13
+ /** A DOM-free, instance-scoped provider. Works with ChatPanel and standalone primitives. */
14
+ declare function ChatAppearanceProvider({ icons, children }: ChatAppearanceProviderProps): import("react").JSX.Element;
15
+ declare function Icon({ name, ...props }: ChatIconProps & {
16
+ name: ChatIconName;
17
+ }): import("react").JSX.Element;
18
+ //#endregion
19
+ export { ChatIconProps as a, ChatIconOverrides as i, ChatAppearanceProviderProps as n, Icon as o, ChatIconName as r, ChatAppearanceProvider as t };
20
+ //# sourceMappingURL=icons-CZZENm5N.d.ts.map
package/dist/index.d.ts CHANGED
@@ -1,8 +1,9 @@
1
1
 
2
- import { a as ChatIconName, c as Icon, i as ChatAppearanceProviderProps, n as ChatIconButtonProps, o as ChatIconOverrides, r as ChatAppearanceProvider, s as ChatIconProps, t as ChatIconButton } from "./appearance-BUtKwRL5.js";
2
+ import { a as ChatIconProps, i as ChatIconOverrides, n as ChatAppearanceProviderProps, o as Icon, r as ChatIconName, t as ChatAppearanceProvider } from "./icons-CZZENm5N.js";
3
+ import { n as ChatIconButtonProps, t as ChatIconButton } from "./appearance-CCOHF5L-.js";
3
4
  import { ChatContextAdapter, ChatContextController, ChatContextItem, ChatContextOptions, ChatContextValue, ChatRequestContext, ContextTray, ContextTrayLabels, ContextTrayProps, SelectedChatContextItem, TextSelectionAdapterOptions, createTextSelectionAdapter, useChatContext } from "./context.js";
4
5
  import { SpeechInputAdapter, SpeechInputController, SpeechInputError, SpeechInputErrorCode, SpeechInputLabels, SpeechInputOptions, SpeechInputResult, SpeechInputSession, SpeechInputStartOptions, SpeechInputState, SpeechInputSupport, UseSpeechInputOptions, createBrowserSpeechAdapter, defaultSpeechInputLabels, useSpeechInput } from "./voice.js";
5
- import { C as ToolPresentationResolver, S as ToolPresentation, _ as ChatSuggestedAction, b as TextRenderer, c as AiChatOptions, d as ChatComposerProps, f as ChatLabels, g as ChatScrollHandle, h as ChatPanelProps, i as getMessageText, l as AiChatProps, m as ChatMessagesProps, n as zhCN, o as useAiChat, p as ChatMessageActionContext, s as AiChatController, t as enUS, u as AttachmentOptions, v as PartRendererProps, w as ToolRenderers, x as ToolPart, y as PartRenderers } from "./labels-a_-_yLBi.js";
6
+ import { A as ToolPresentationResolver, B as detectComposerTrigger, C as ChatScrollHandle, D as TextRenderer, E as PartRenderers, F as ComposerTriggerController, G as slugifySkillName, H as filterSkills, I as ComposerTriggerKind, K as useComposerTrigger, L as ComposerTriggerMatch, M as ChatComposerMenuAction, N as ChatMentionItem, O as ToolPart, P as ChatSkillItem, R as ParsedSkillMarkdown, S as ChatPanelProps, T as PartRendererProps, U as parseSkillMarkdown, V as filterMentions, W as replaceComposerTrigger, _ as ChatBranchInfo, a as projectChatBranches, b as ChatMessageActionContext, c as zhCN, f as useAiChat, g as AttachmentOptions, h as AiChatProps, i as ProjectChatBranchesOptions, j as ToolRenderers, k as ToolPresentation, m as AiChatOptions, n as ChatBranchesController, o as useChatBranches, p as AiChatController, r as ChatBranchesState, s as enUS, t as ChatBranchProjection, u as getMessageText, v as ChatComposerProps, w as ChatSuggestedAction, x as ChatMessagesProps, y as ChatLabels, z as UseComposerTriggerOptions } from "./branches-Dvdv5ug7.js";
6
7
  import { ActiveMarquee, ChatTargetHit, ChatTargetKind, ChatTargetRect, ChatTargetingController, ChatTargetingLabels, ChatTargetingOverlay, ChatTargetingOverlayProps, PendingChatTarget, UseChatTargetingOptions, enUSTargetingLabels, toChatContextItem, useChatTargeting, zhCNTargetingLabels } from "./targeting.js";
7
8
  import { HTMLAttributes, ReactNode } from "react";
8
9
  import { UIMessage } from "ai";
@@ -60,5 +61,56 @@ export declare function ChatHistoryMenu({ conversations, currentId, onSelect, on
60
61
  /** Drafts and upload requests are isolated by conversation id. */
61
62
  export declare function ChatComposer<M extends UIMessage = UIMessage>(props: ChatComposerProps<M>): import("react").JSX.Element;
62
63
  //#endregion
63
- export { type ActiveMarquee, type AiChatController, type AiChatOptions, type AiChatProps, type AttachmentOptions, ChatAppearanceProvider, type ChatAppearanceProviderProps, type ChatComposerProps, type ChatContextAdapter, type ChatContextController, type ChatContextItem, type ChatContextOptions, type ChatContextValue, type ChatHistoryItem, type ChatHistoryLabels, type ChatHistoryMenuProps, Icon as ChatIcon, ChatIconButton, type ChatIconButtonProps, type ChatIconName, type ChatIconOverrides, type ChatIconProps, type ChatLabels, type ChatMessageActionContext, type ChatMessagesProps, type ChatPanelProps, type ChatRequestContext, type ChatScrollHandle, type ChatSuggestedAction, type ChatTargetHit, type ChatTargetKind, type ChatTargetRect, type ChatTargetingController, type ChatTargetingLabels, ChatTargetingOverlay, type ChatTargetingOverlayProps, ContextTray, type ContextTrayLabels, type ContextTrayProps, type PartRendererProps, type PartRenderers, type PendingChatTarget, type SelectedChatContextItem, type SpeechInputAdapter, type SpeechInputController, SpeechInputError, type SpeechInputErrorCode, type SpeechInputLabels, type SpeechInputOptions, type SpeechInputResult, type SpeechInputSession, type SpeechInputStartOptions, type SpeechInputState, type SpeechInputSupport, type TextRenderer, type TextSelectionAdapterOptions, type ToolPart, type ToolPresentation, type ToolPresentationResolver, type ToolRenderers, type UseChatTargetingOptions, type UseSpeechInputOptions, createBrowserSpeechAdapter, createTextSelectionAdapter, defaultSpeechInputLabels, enUS, enUSTargetingLabels, getMessageText, toChatContextItem, useAiChat, useChatContext, useChatTargeting, useSpeechInput, zhCN, zhCNTargetingLabels };
64
+ //#region src/branch-switcher.d.ts
65
+ interface ChatBranchSwitcherProps {
66
+ branch: ChatBranchInfo;
67
+ onSelect: (messageId: string) => void;
68
+ disabled?: boolean;
69
+ labels?: Partial<ChatLabels>;
70
+ className?: string;
71
+ }
72
+ /** Compact `< 2 / 3 >` sibling-branch navigation control. */
73
+ export declare function ChatBranchSwitcher({ branch, onSelect, disabled, labels: overrides, className }: ChatBranchSwitcherProps): import("react").JSX.Element | null;
74
+ interface ChatCheckpointBannerProps {
75
+ message?: ReactNode;
76
+ onRestore?: () => void;
77
+ restoreLabel?: string;
78
+ disabled?: boolean;
79
+ labels?: Partial<ChatLabels>;
80
+ className?: string;
81
+ }
82
+ /** Cursor-style checkpoint status bar shown when reverted before a message, with one-click Restore. */
83
+ export declare function ChatCheckpointBanner({ message, onRestore, restoreLabel, disabled, labels: overrides, className }: ChatCheckpointBannerProps): import("react").JSX.Element;
84
+ //#endregion
85
+ //#region src/composer-popovers.d.ts
86
+ interface ChatSlashMenuProps {
87
+ skills: readonly ChatSkillItem[];
88
+ activeIndex: number;
89
+ onHighlight?: (index: number) => void;
90
+ onSelect: (skill: ChatSkillItem) => void;
91
+ onAddSkill?: () => void;
92
+ onBrowseSkills?: () => void;
93
+ labels?: Partial<ChatLabels>;
94
+ className?: string;
95
+ }
96
+ export declare function ChatSlashMenu({ skills, activeIndex, onHighlight, onSelect, onAddSkill, onBrowseSkills, labels: overrides, className }: ChatSlashMenuProps): import("react").JSX.Element;
97
+ interface ChatMentionMenuProps {
98
+ items: readonly ChatMentionItem[];
99
+ activeIndex: number;
100
+ onHighlight?: (index: number) => void;
101
+ onSelect: (item: ChatMentionItem) => void;
102
+ labels?: Partial<ChatLabels>;
103
+ className?: string;
104
+ }
105
+ export declare function ChatMentionMenu({ items, activeIndex, onHighlight, onSelect, labels: overrides, className }: ChatMentionMenuProps): import("react").JSX.Element;
106
+ interface ChatPlusMenuProps {
107
+ open: boolean;
108
+ onClose: () => void;
109
+ actions: readonly ChatComposerMenuAction[];
110
+ labels?: Partial<ChatLabels>;
111
+ className?: string;
112
+ }
113
+ export declare function ChatPlusMenu({ open, onClose, actions, labels: overrides, className }: ChatPlusMenuProps): import("react").JSX.Element | null;
114
+ //#endregion
115
+ export { type ActiveMarquee, type AiChatController, type AiChatOptions, type AiChatProps, type AttachmentOptions, ChatAppearanceProvider, type ChatAppearanceProviderProps, type ChatBranchInfo, type ChatBranchProjection, type ChatBranchSwitcherProps, type ChatBranchesController, type ChatBranchesState, type ChatCheckpointBannerProps, type ChatComposerMenuAction, type ChatComposerProps, type ChatContextAdapter, type ChatContextController, type ChatContextItem, type ChatContextOptions, type ChatContextValue, type ChatHistoryItem, type ChatHistoryLabels, type ChatHistoryMenuProps, Icon as ChatIcon, ChatIconButton, type ChatIconButtonProps, type ChatIconName, type ChatIconOverrides, type ChatIconProps, type ChatLabels, type ChatMentionItem, type ChatMentionMenuProps, type ChatMessageActionContext, type ChatMessagesProps, type ChatPanelProps, type ChatPlusMenuProps, type ChatRequestContext, type ChatScrollHandle, type ChatSkillItem, type ChatSlashMenuProps, type ChatSuggestedAction, type ChatTargetHit, type ChatTargetKind, type ChatTargetRect, type ChatTargetingController, type ChatTargetingLabels, ChatTargetingOverlay, type ChatTargetingOverlayProps, type ComposerTriggerController, type ComposerTriggerKind, type ComposerTriggerMatch, ContextTray, type ContextTrayLabels, type ContextTrayProps, type ParsedSkillMarkdown, type PartRendererProps, type PartRenderers, type PendingChatTarget, type ProjectChatBranchesOptions, type SelectedChatContextItem, type SpeechInputAdapter, type SpeechInputController, SpeechInputError, type SpeechInputErrorCode, type SpeechInputLabels, type SpeechInputOptions, type SpeechInputResult, type SpeechInputSession, type SpeechInputStartOptions, type SpeechInputState, type SpeechInputSupport, type TextRenderer, type TextSelectionAdapterOptions, type ToolPart, type ToolPresentation, type ToolPresentationResolver, type ToolRenderers, type UseChatTargetingOptions, type UseComposerTriggerOptions, type UseSpeechInputOptions, createBrowserSpeechAdapter, createTextSelectionAdapter, defaultSpeechInputLabels, detectComposerTrigger, enUS, enUSTargetingLabels, filterMentions, filterSkills, getMessageText, parseSkillMarkdown, projectChatBranches, replaceComposerTrigger, slugifySkillName, toChatContextItem, useAiChat, useChatBranches, useChatContext, useChatTargeting, useComposerTrigger, useSpeechInput, zhCN, zhCNTargetingLabels };
64
116
  //# sourceMappingURL=index.d.ts.map