@nabeh/chat-widget 0.1.1 → 0.1.3

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 CHANGED
@@ -1,4 +1,5 @@
1
1
  type WidgetPosition = "bottom-right" | "bottom-left";
2
+ type ChatWidgetDisplayMode = "widget" | "embedded";
2
3
  type ChatWidgetTheme = {
3
4
  accent: string;
4
5
  accentSoft: string;
@@ -70,6 +71,7 @@ type ChatWidgetConfig = {
70
71
  deleteLastQa?: string;
71
72
  };
72
73
  mount?: HTMLElement;
74
+ displayMode?: ChatWidgetDisplayMode;
73
75
  position?: WidgetPosition;
74
76
  title?: string;
75
77
  subtitle?: string;
@@ -88,6 +90,11 @@ type ChatWidgetConfig = {
88
90
  onOpen?: () => void;
89
91
  onClose?: () => void;
90
92
  onError?: (error: Error) => void;
93
+ onOpenAssistantPage?: () => Promise<void> | void;
94
+ assistantPageUrl?: string;
95
+ embedded?: {
96
+ showHeader?: boolean;
97
+ };
91
98
  };
92
99
  type ChatWidgetInstance = {
93
100
  open: () => void;
@@ -108,4 +115,4 @@ type BrowserGlobal = {
108
115
 
109
116
  declare function createChatWidget(config: ChatWidgetConfig): ChatWidgetInstance;
110
117
 
111
- export { type BrowserGlobal, type ChatListItem, type ChatWidgetConfig, type ChatWidgetInstance, type ChatWidgetTheme, type SendMessageRequest, type SendMessageResponse, type UserContext, type WidgetPosition, createChatWidget };
118
+ export { type BrowserGlobal, type ChatListItem, type ChatWidgetConfig, type ChatWidgetDisplayMode, type ChatWidgetInstance, type ChatWidgetTheme, type SendMessageRequest, type SendMessageResponse, type UserContext, type WidgetPosition, createChatWidget };
package/dist/index.d.ts CHANGED
@@ -1,4 +1,5 @@
1
1
  type WidgetPosition = "bottom-right" | "bottom-left";
2
+ type ChatWidgetDisplayMode = "widget" | "embedded";
2
3
  type ChatWidgetTheme = {
3
4
  accent: string;
4
5
  accentSoft: string;
@@ -70,6 +71,7 @@ type ChatWidgetConfig = {
70
71
  deleteLastQa?: string;
71
72
  };
72
73
  mount?: HTMLElement;
74
+ displayMode?: ChatWidgetDisplayMode;
73
75
  position?: WidgetPosition;
74
76
  title?: string;
75
77
  subtitle?: string;
@@ -88,6 +90,11 @@ type ChatWidgetConfig = {
88
90
  onOpen?: () => void;
89
91
  onClose?: () => void;
90
92
  onError?: (error: Error) => void;
93
+ onOpenAssistantPage?: () => Promise<void> | void;
94
+ assistantPageUrl?: string;
95
+ embedded?: {
96
+ showHeader?: boolean;
97
+ };
91
98
  };
92
99
  type ChatWidgetInstance = {
93
100
  open: () => void;
@@ -108,4 +115,4 @@ type BrowserGlobal = {
108
115
 
109
116
  declare function createChatWidget(config: ChatWidgetConfig): ChatWidgetInstance;
110
117
 
111
- export { type BrowserGlobal, type ChatListItem, type ChatWidgetConfig, type ChatWidgetInstance, type ChatWidgetTheme, type SendMessageRequest, type SendMessageResponse, type UserContext, type WidgetPosition, createChatWidget };
118
+ export { type BrowserGlobal, type ChatListItem, type ChatWidgetConfig, type ChatWidgetDisplayMode, type ChatWidgetInstance, type ChatWidgetTheme, type SendMessageRequest, type SendMessageResponse, type UserContext, type WidgetPosition, createChatWidget };