@telnyx/ai-chat-widget 4.0.3 → 4.1.2
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.cjs +291 -74
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.ts +21 -4
- package/dist/index.mjs +7095 -6835
- package/dist/index.mjs.map +1 -1
- package/dist/index.umd.js +291 -74
- package/dist/index.umd.js.map +1 -1
- package/package.json +1 -1
package/dist/index.d.ts
CHANGED
|
@@ -11,10 +11,11 @@ declare type BaseProps = {
|
|
|
11
11
|
*/
|
|
12
12
|
endpoint?: 'flow' | 'aida';
|
|
13
13
|
/**
|
|
14
|
-
* The base URL for AIDA (Heavy thinking mode)
|
|
15
|
-
*
|
|
14
|
+
* The base URL for AIDA (Heavy thinking mode).
|
|
15
|
+
* Optional — if omitted, defaults to the internal AIDA endpoint.
|
|
16
|
+
* When only flowAPIUrl is provided, the widget runs in flow-only mode.
|
|
16
17
|
*/
|
|
17
|
-
chatAPIUrl
|
|
18
|
+
chatAPIUrl?: string;
|
|
18
19
|
/**
|
|
19
20
|
* The base URL for Flow (Instant mode). If not provided, uses chatAPIUrl.
|
|
20
21
|
*/
|
|
@@ -56,9 +57,17 @@ declare type BaseProps = {
|
|
|
56
57
|
* The action to be performed when the user clicks the help button
|
|
57
58
|
*/
|
|
58
59
|
onHelpAction?: () => void;
|
|
60
|
+
/**
|
|
61
|
+
* The theme to use for the chat widget
|
|
62
|
+
* - 'light': Always use light theme
|
|
63
|
+
* - 'dark': Always use dark theme
|
|
64
|
+
* - 'system': Automatically detect system preference
|
|
65
|
+
* @default 'light'
|
|
66
|
+
*/
|
|
67
|
+
theme?: WidgetTheme;
|
|
59
68
|
};
|
|
60
69
|
|
|
61
|
-
export declare const ChatWidget: ({ chatAPIUrl, flowAPIUrl, flowApiKey, feedbackAPIUrl, user, onHelpAction, open, setOpen, placeholders, mountPosition, mountDirection, offsetX, offsetY, icon, }: ChatWidgetProps) => JSX.Element;
|
|
70
|
+
export declare const ChatWidget: ({ chatAPIUrl, flowAPIUrl, flowApiKey, feedbackAPIUrl, user, onHelpAction, open, setOpen, placeholders, mountPosition, mountDirection, offsetX, offsetY, icon, theme, }: ChatWidgetProps) => JSX.Element;
|
|
62
71
|
|
|
63
72
|
declare interface ChatWidgetNoMounting extends BaseProps {
|
|
64
73
|
open?: never;
|
|
@@ -175,8 +184,16 @@ declare const WIDGET_MOUNT_POSITIONS: {
|
|
|
175
184
|
readonly LEFT: "left";
|
|
176
185
|
};
|
|
177
186
|
|
|
187
|
+
declare const WIDGET_THEMES: {
|
|
188
|
+
readonly LIGHT: "light";
|
|
189
|
+
readonly DARK: "dark";
|
|
190
|
+
readonly SYSTEM: "system";
|
|
191
|
+
};
|
|
192
|
+
|
|
178
193
|
declare type WidgetMountDirection = (typeof WIDGET_MOUNT_DIRECTION)[keyof typeof WIDGET_MOUNT_DIRECTION];
|
|
179
194
|
|
|
180
195
|
declare type WidgetMountPosition = (typeof WIDGET_MOUNT_POSITIONS)[keyof typeof WIDGET_MOUNT_POSITIONS];
|
|
181
196
|
|
|
197
|
+
declare type WidgetTheme = (typeof WIDGET_THEMES)[keyof typeof WIDGET_THEMES];
|
|
198
|
+
|
|
182
199
|
export { }
|