@citron-systems/citron-ui 1.22.0 → 1.24.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.
- package/dist/index.d.cts +12 -6
- package/dist/index.d.ts +12 -6
- package/dist/index.js +3 -3
- package/dist/index.mjs +3 -3
- package/package.json +1 -1
package/dist/index.d.cts
CHANGED
|
@@ -26,9 +26,10 @@ interface GlobalAssistantChatProps {
|
|
|
26
26
|
isProcessing?: boolean;
|
|
27
27
|
placeholder?: string;
|
|
28
28
|
emptyStateMessage?: string;
|
|
29
|
+
onVoiceClick?: () => void;
|
|
29
30
|
className?: string;
|
|
30
31
|
}
|
|
31
|
-
declare function GlobalAssistantChat({ messages, onSend, isProcessing, placeholder, emptyStateMessage, className, }: GlobalAssistantChatProps): react_jsx_runtime.JSX.Element;
|
|
32
|
+
declare function GlobalAssistantChat({ messages, onSend, isProcessing, placeholder, emptyStateMessage, onVoiceClick, className, }: GlobalAssistantChatProps): react_jsx_runtime.JSX.Element;
|
|
32
33
|
|
|
33
34
|
interface AssistantPanelProps extends Omit<GlobalAssistantChatProps, 'className'> {
|
|
34
35
|
open: boolean;
|
|
@@ -67,10 +68,15 @@ interface CenteredAIChatComposePayload {
|
|
|
67
68
|
}
|
|
68
69
|
interface CenteredAIChatProps {
|
|
69
70
|
messages?: CenteredAIChatMessage[];
|
|
70
|
-
onSend?: (content: string) => void;
|
|
71
71
|
/**
|
|
72
|
-
*
|
|
73
|
-
|
|
72
|
+
* Same shape as `GlobalAssistantChat`: text and files in one callback.
|
|
73
|
+
*/
|
|
74
|
+
onSend?: (payload: {
|
|
75
|
+
text: string;
|
|
76
|
+
files: File[];
|
|
77
|
+
}) => void;
|
|
78
|
+
/**
|
|
79
|
+
* When set, used on submit instead of `onSend` (same payload shape).
|
|
74
80
|
*/
|
|
75
81
|
onComposeSubmit?: (payload: CenteredAIChatComposePayload) => void;
|
|
76
82
|
isProcessing?: boolean;
|
|
@@ -79,8 +85,8 @@ interface CenteredAIChatProps {
|
|
|
79
85
|
activeAgent?: string;
|
|
80
86
|
onAgentChange?: (agentId: string) => void;
|
|
81
87
|
/**
|
|
82
|
-
*
|
|
83
|
-
*
|
|
88
|
+
* Only if neither `onSend` nor `onComposeSubmit`: called with files on send (text has no handler).
|
|
89
|
+
* @deprecated Prefer `onSend` with `{ text, files }`.
|
|
84
90
|
*/
|
|
85
91
|
onFilesAttach?: (files: File[]) => void;
|
|
86
92
|
onVoiceClick?: () => void;
|
package/dist/index.d.ts
CHANGED
|
@@ -26,9 +26,10 @@ interface GlobalAssistantChatProps {
|
|
|
26
26
|
isProcessing?: boolean;
|
|
27
27
|
placeholder?: string;
|
|
28
28
|
emptyStateMessage?: string;
|
|
29
|
+
onVoiceClick?: () => void;
|
|
29
30
|
className?: string;
|
|
30
31
|
}
|
|
31
|
-
declare function GlobalAssistantChat({ messages, onSend, isProcessing, placeholder, emptyStateMessage, className, }: GlobalAssistantChatProps): react_jsx_runtime.JSX.Element;
|
|
32
|
+
declare function GlobalAssistantChat({ messages, onSend, isProcessing, placeholder, emptyStateMessage, onVoiceClick, className, }: GlobalAssistantChatProps): react_jsx_runtime.JSX.Element;
|
|
32
33
|
|
|
33
34
|
interface AssistantPanelProps extends Omit<GlobalAssistantChatProps, 'className'> {
|
|
34
35
|
open: boolean;
|
|
@@ -67,10 +68,15 @@ interface CenteredAIChatComposePayload {
|
|
|
67
68
|
}
|
|
68
69
|
interface CenteredAIChatProps {
|
|
69
70
|
messages?: CenteredAIChatMessage[];
|
|
70
|
-
onSend?: (content: string) => void;
|
|
71
71
|
/**
|
|
72
|
-
*
|
|
73
|
-
|
|
72
|
+
* Same shape as `GlobalAssistantChat`: text and files in one callback.
|
|
73
|
+
*/
|
|
74
|
+
onSend?: (payload: {
|
|
75
|
+
text: string;
|
|
76
|
+
files: File[];
|
|
77
|
+
}) => void;
|
|
78
|
+
/**
|
|
79
|
+
* When set, used on submit instead of `onSend` (same payload shape).
|
|
74
80
|
*/
|
|
75
81
|
onComposeSubmit?: (payload: CenteredAIChatComposePayload) => void;
|
|
76
82
|
isProcessing?: boolean;
|
|
@@ -79,8 +85,8 @@ interface CenteredAIChatProps {
|
|
|
79
85
|
activeAgent?: string;
|
|
80
86
|
onAgentChange?: (agentId: string) => void;
|
|
81
87
|
/**
|
|
82
|
-
*
|
|
83
|
-
*
|
|
88
|
+
* Only if neither `onSend` nor `onComposeSubmit`: called with files on send (text has no handler).
|
|
89
|
+
* @deprecated Prefer `onSend` with `{ text, files }`.
|
|
84
90
|
*/
|
|
85
91
|
onFilesAttach?: (files: File[]) => void;
|
|
86
92
|
onVoiceClick?: () => void;
|