@afncdelacru/brady-chat 0.4.5 → 0.4.7
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.mts +9 -2
- package/dist/index.d.ts +9 -2
- package/dist/index.js +1427 -1389
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +1395 -1357
- package/dist/index.mjs.map +1 -1
- package/package.json +3 -3
- package/src/lib/BradyChatContext.tsx +1 -1
- package/src/lib/EnhancedBradyChat.tsx +0 -1
package/dist/index.d.mts
CHANGED
|
@@ -37,6 +37,9 @@ interface BradyChatContextType {
|
|
|
37
37
|
setIsHidden: React.Dispatch<React.SetStateAction<boolean>>;
|
|
38
38
|
hideBradyForModal: () => void;
|
|
39
39
|
restoreBradyAfterModal: () => void;
|
|
40
|
+
setUserText: (text: string) => void;
|
|
41
|
+
userTextToSend?: string;
|
|
42
|
+
setUserTextToSend?: (text: string | undefined) => void;
|
|
40
43
|
}
|
|
41
44
|
declare function BradyChatProvider({ children }: {
|
|
42
45
|
children: ReactNode;
|
|
@@ -55,8 +58,12 @@ interface EnhancedBradyChatProps {
|
|
|
55
58
|
* Typically you pass something like `/bradyIcon.png` from your app's public assets.
|
|
56
59
|
*/
|
|
57
60
|
avatarSrc: string;
|
|
61
|
+
/**
|
|
62
|
+
* If set, will immediately set the input value and send it as a user message.
|
|
63
|
+
*/
|
|
64
|
+
setUserText?: string;
|
|
58
65
|
}
|
|
59
|
-
declare function EnhancedBradyChat({ modeVariant, avatarSrc }: EnhancedBradyChatProps): react_jsx_runtime.JSX.Element;
|
|
66
|
+
declare function EnhancedBradyChat({ modeVariant, avatarSrc, setUserText }: EnhancedBradyChatProps): react_jsx_runtime.JSX.Element;
|
|
60
67
|
|
|
61
68
|
declare const DEFAULT_BRADY_API_KEY: string;
|
|
62
69
|
declare const API_URL: string;
|
|
@@ -79,4 +86,4 @@ interface BradyChatResponse {
|
|
|
79
86
|
declare function sendBradyPrompt(messages: BradyMessage[], apiKey?: string): Promise<BradyChatResponse>;
|
|
80
87
|
declare function checkBradyHealth(): Promise<boolean>;
|
|
81
88
|
|
|
82
|
-
export { API_URL, BradyChatProvider, type BradyChatRequest, type BradyChatResponse, type BradyMessage, type ChatMessage, type ChatWorkflowType, DEFAULT_BRADY_API_KEY, EnhancedBradyChat, type EnhancedBradyChatProps, type ModeStep, type ModeType, checkBradyHealth, sendBradyPrompt, useBradyChat };
|
|
89
|
+
export { API_URL, type BradyChatContextType, BradyChatProvider, type BradyChatRequest, type BradyChatResponse, type BradyMessage, type ChatMessage, type ChatWorkflowType, DEFAULT_BRADY_API_KEY, EnhancedBradyChat, type EnhancedBradyChatProps, type ModeStep, type ModeType, checkBradyHealth, sendBradyPrompt, useBradyChat };
|
package/dist/index.d.ts
CHANGED
|
@@ -37,6 +37,9 @@ interface BradyChatContextType {
|
|
|
37
37
|
setIsHidden: React.Dispatch<React.SetStateAction<boolean>>;
|
|
38
38
|
hideBradyForModal: () => void;
|
|
39
39
|
restoreBradyAfterModal: () => void;
|
|
40
|
+
setUserText: (text: string) => void;
|
|
41
|
+
userTextToSend?: string;
|
|
42
|
+
setUserTextToSend?: (text: string | undefined) => void;
|
|
40
43
|
}
|
|
41
44
|
declare function BradyChatProvider({ children }: {
|
|
42
45
|
children: ReactNode;
|
|
@@ -55,8 +58,12 @@ interface EnhancedBradyChatProps {
|
|
|
55
58
|
* Typically you pass something like `/bradyIcon.png` from your app's public assets.
|
|
56
59
|
*/
|
|
57
60
|
avatarSrc: string;
|
|
61
|
+
/**
|
|
62
|
+
* If set, will immediately set the input value and send it as a user message.
|
|
63
|
+
*/
|
|
64
|
+
setUserText?: string;
|
|
58
65
|
}
|
|
59
|
-
declare function EnhancedBradyChat({ modeVariant, avatarSrc }: EnhancedBradyChatProps): react_jsx_runtime.JSX.Element;
|
|
66
|
+
declare function EnhancedBradyChat({ modeVariant, avatarSrc, setUserText }: EnhancedBradyChatProps): react_jsx_runtime.JSX.Element;
|
|
60
67
|
|
|
61
68
|
declare const DEFAULT_BRADY_API_KEY: string;
|
|
62
69
|
declare const API_URL: string;
|
|
@@ -79,4 +86,4 @@ interface BradyChatResponse {
|
|
|
79
86
|
declare function sendBradyPrompt(messages: BradyMessage[], apiKey?: string): Promise<BradyChatResponse>;
|
|
80
87
|
declare function checkBradyHealth(): Promise<boolean>;
|
|
81
88
|
|
|
82
|
-
export { API_URL, BradyChatProvider, type BradyChatRequest, type BradyChatResponse, type BradyMessage, type ChatMessage, type ChatWorkflowType, DEFAULT_BRADY_API_KEY, EnhancedBradyChat, type EnhancedBradyChatProps, type ModeStep, type ModeType, checkBradyHealth, sendBradyPrompt, useBradyChat };
|
|
89
|
+
export { API_URL, type BradyChatContextType, BradyChatProvider, type BradyChatRequest, type BradyChatResponse, type BradyMessage, type ChatMessage, type ChatWorkflowType, DEFAULT_BRADY_API_KEY, EnhancedBradyChat, type EnhancedBradyChatProps, type ModeStep, type ModeType, checkBradyHealth, sendBradyPrompt, useBradyChat };
|