@streamoji/avatar-widget 0.3.6 → 0.3.9
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/avatar-widget.cjs +7 -5
- package/dist/avatar-widget.js +908 -703
- package/dist/avatar-widget.umd.js +57 -55
- package/dist/avatar-widget.umd.js.map +1 -1
- package/dist/index.d.ts +14 -0
- package/package.json +1 -1
package/dist/index.d.ts
CHANGED
|
@@ -15,6 +15,20 @@ export interface AvatarWidgetProps {
|
|
|
15
15
|
avatarGender?: "male" | "female";
|
|
16
16
|
/** Optional user details to identify logged-in users and skip lead capture. */
|
|
17
17
|
presetUserDetails?: UserDetails;
|
|
18
|
+
/** Callback triggered when the avatar is ready, providing action functions. */
|
|
19
|
+
onAvatarReady?: (actions: {
|
|
20
|
+
avatarSpeak: (
|
|
21
|
+
text: string,
|
|
22
|
+
userQuery: string,
|
|
23
|
+
llmPrompt: string
|
|
24
|
+
) => Promise<void>;
|
|
25
|
+
avatarRespond: (
|
|
26
|
+
userQuery: string,
|
|
27
|
+
llmPrompt: string,
|
|
28
|
+
knowledge: string,
|
|
29
|
+
history: any[]
|
|
30
|
+
) => Promise<void>;
|
|
31
|
+
}) => void;
|
|
18
32
|
}
|
|
19
33
|
|
|
20
34
|
declare const AvatarWidget: (props: AvatarWidgetProps) => ReactElement;
|