@personaliai/react-widget 0.1.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/LICENSE +21 -0
- package/README.md +97 -0
- package/dist/chunk-PR4QN5HX.js +43 -0
- package/dist/chunk-PR4QN5HX.js.map +1 -0
- package/dist/emoji-picker-react.esm-JCK7JWXK.js +26071 -0
- package/dist/emoji-picker-react.esm-JCK7JWXK.js.map +1 -0
- package/dist/index.cjs +98050 -0
- package/dist/index.cjs.map +1 -0
- package/dist/index.d.cts +28 -0
- package/dist/index.d.ts +28 -0
- package/dist/index.js +71952 -0
- package/dist/index.js.map +1 -0
- package/dist/styles.css +259 -0
- package/package.json +57 -0
- package/src/ChatWidgetCore.tsx +1919 -0
- package/src/attach-menu.tsx +60 -0
- package/src/color-contrast.ts +186 -0
- package/src/index.ts +1 -0
- package/src/quick-emoji-picker.tsx +75 -0
- package/src/safe-markdown-link.tsx +44 -0
- package/src/voice-call-widget.tsx +564 -0
- package/src/widget-presets.css +259 -0
- package/src/widget-style.ts +88 -0
package/dist/index.d.cts
ADDED
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
import * as react from 'react';
|
|
2
|
+
|
|
3
|
+
interface ChatWidgetCoreProps {
|
|
4
|
+
botId: string;
|
|
5
|
+
originToken: string | null;
|
|
6
|
+
isPreview?: boolean;
|
|
7
|
+
paramColor?: string | null;
|
|
8
|
+
paramStyle?: string | null;
|
|
9
|
+
paramName?: string | null;
|
|
10
|
+
paramWelcome?: string | null;
|
|
11
|
+
paramAvatarIcon?: string | null;
|
|
12
|
+
paramAvatarUrl?: string | null;
|
|
13
|
+
paramLogoUrl?: string | null;
|
|
14
|
+
paramLogoBgColor?: string | null;
|
|
15
|
+
paramShowSenderTag?: string | null;
|
|
16
|
+
paramCsatEnabled?: string | null;
|
|
17
|
+
paramColorScheme?: string | null;
|
|
18
|
+
onWidgetReady?: () => void;
|
|
19
|
+
onWidgetClose?: () => void;
|
|
20
|
+
onAssistantMessage?: () => void;
|
|
21
|
+
onRequestNotificationPermission?: (botName: string, avatarUrl?: string | null) => void;
|
|
22
|
+
onTriggerNotification?: (botName: string, bodyText: string, avatarUrl?: string | null) => void;
|
|
23
|
+
forceFullscreen?: boolean;
|
|
24
|
+
notificationGranted?: boolean;
|
|
25
|
+
}
|
|
26
|
+
declare function ChatWidgetCore({ botId, originToken, isPreview, paramColor, paramStyle, paramName, paramWelcome, paramAvatarIcon, paramAvatarUrl, paramLogoUrl, paramLogoBgColor, paramShowSenderTag, paramCsatEnabled, paramColorScheme, onWidgetReady, onWidgetClose, onAssistantMessage, onRequestNotificationPermission, onTriggerNotification, forceFullscreen, notificationGranted, }: ChatWidgetCoreProps): react.JSX.Element;
|
|
27
|
+
|
|
28
|
+
export { ChatWidgetCore as ChattyWidget, type ChatWidgetCoreProps as ChattyWidgetProps };
|
package/dist/index.d.ts
ADDED
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
import * as react from 'react';
|
|
2
|
+
|
|
3
|
+
interface ChatWidgetCoreProps {
|
|
4
|
+
botId: string;
|
|
5
|
+
originToken: string | null;
|
|
6
|
+
isPreview?: boolean;
|
|
7
|
+
paramColor?: string | null;
|
|
8
|
+
paramStyle?: string | null;
|
|
9
|
+
paramName?: string | null;
|
|
10
|
+
paramWelcome?: string | null;
|
|
11
|
+
paramAvatarIcon?: string | null;
|
|
12
|
+
paramAvatarUrl?: string | null;
|
|
13
|
+
paramLogoUrl?: string | null;
|
|
14
|
+
paramLogoBgColor?: string | null;
|
|
15
|
+
paramShowSenderTag?: string | null;
|
|
16
|
+
paramCsatEnabled?: string | null;
|
|
17
|
+
paramColorScheme?: string | null;
|
|
18
|
+
onWidgetReady?: () => void;
|
|
19
|
+
onWidgetClose?: () => void;
|
|
20
|
+
onAssistantMessage?: () => void;
|
|
21
|
+
onRequestNotificationPermission?: (botName: string, avatarUrl?: string | null) => void;
|
|
22
|
+
onTriggerNotification?: (botName: string, bodyText: string, avatarUrl?: string | null) => void;
|
|
23
|
+
forceFullscreen?: boolean;
|
|
24
|
+
notificationGranted?: boolean;
|
|
25
|
+
}
|
|
26
|
+
declare function ChatWidgetCore({ botId, originToken, isPreview, paramColor, paramStyle, paramName, paramWelcome, paramAvatarIcon, paramAvatarUrl, paramLogoUrl, paramLogoBgColor, paramShowSenderTag, paramCsatEnabled, paramColorScheme, onWidgetReady, onWidgetClose, onAssistantMessage, onRequestNotificationPermission, onTriggerNotification, forceFullscreen, notificationGranted, }: ChatWidgetCoreProps): react.JSX.Element;
|
|
27
|
+
|
|
28
|
+
export { ChatWidgetCore as ChattyWidget, type ChatWidgetCoreProps as ChattyWidgetProps };
|