@botpress/webchat 3.1.1 → 3.2.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/.turbo/turbo-build.log +8 -8
- package/dist/index.d.ts +15 -4
- package/dist/index.js +8657 -9173
- package/dist/index.umd.cjs +105 -134
- package/dist/style.css +1 -1
- package/package.json +14 -2
package/.turbo/turbo-build.log
CHANGED
|
@@ -1,21 +1,21 @@
|
|
|
1
1
|
|
|
2
|
-
> @botpress/webchat@3.
|
|
2
|
+
> @botpress/webchat@3.2.2 build /home/runner/work/genisys/genisys/packages/webchat-components
|
|
3
3
|
> vite build
|
|
4
4
|
|
|
5
5
|
[36mvite v5.4.8 [32mbuilding for production...[36m[39m
|
|
6
6
|
transforming...
|
|
7
|
-
[32m✓[39m
|
|
7
|
+
[32m✓[39m 3180 modules transformed.
|
|
8
8
|
rendering chunks...
|
|
9
9
|
|
|
10
10
|
[vite:dts] Start generate declaration files...
|
|
11
11
|
computing gzip size...
|
|
12
|
-
[2mdist/[22m[35mstyle.css [39m[1m[2m 47.
|
|
13
|
-
[2mdist/[22m[36mindex.js [39m[1m[
|
|
12
|
+
[2mdist/[22m[35mstyle.css [39m[1m[2m 47.36 kB[22m[1m[22m[2m │ gzip: 8.71 kB[22m
|
|
13
|
+
[2mdist/[22m[36mindex.js [39m[1m[33m772.87 kB[39m[22m[2m │ gzip: 212.53 kB[22m
|
|
14
14
|
[vite:dts] Start rollup declaration files...
|
|
15
15
|
Analysis will use the bundled TypeScript version 5.4.2
|
|
16
16
|
*** The target project appears to use TypeScript 5.6.2 which is newer than the bundled compiler engine; consider upgrading API Extractor.
|
|
17
|
-
[vite:dts] Declaration files built in
|
|
17
|
+
[vite:dts] Declaration files built in 23216ms.
|
|
18
18
|
|
|
19
|
-
[2mdist/[22m[35mstyle.css [39m[1m[2m 47.
|
|
20
|
-
[2mdist/[22m[36mindex.umd.cjs [39m[1m[
|
|
21
|
-
[32m✓ built in
|
|
19
|
+
[2mdist/[22m[35mstyle.css [39m[1m[2m 47.36 kB[22m[1m[22m[2m │ gzip: 8.71 kB[22m
|
|
20
|
+
[2mdist/[22m[36mindex.umd.cjs [39m[1m[33m517.24 kB[39m[22m[2m │ gzip: 173.70 kB[22m
|
|
21
|
+
[32m✓ built in 31.52s[39m
|
package/dist/index.d.ts
CHANGED
|
@@ -128,7 +128,7 @@ export declare type CarouselBlock = {
|
|
|
128
128
|
blocks: GenericBlock[];
|
|
129
129
|
};
|
|
130
130
|
|
|
131
|
-
export declare const Chat: ({ connected, configuration, isTyping, messages, user, isLoading, renderers, isReadOnly, disableComposer, allowFileUpload, error, participants, closeWindow, sendMessage, uploadFile, addMessageFeedback, restartConversation, ...props }: Props) => JSX_3.Element;
|
|
131
|
+
export declare const Chat: ({ connected, configuration, isTyping, messages, user, isLoading, renderers, isReadOnly, disableComposer, allowFileUpload, error, participants, closeWindow, sendMessage, uploadFile, addMessageFeedback, restartConversation, storageKey, ...props }: Props) => JSX_3.Element;
|
|
132
132
|
|
|
133
133
|
export declare type ColumnBlock = {
|
|
134
134
|
type: 'column';
|
|
@@ -165,7 +165,7 @@ export declare const CONFIG_ACCESS_DENIED = "Access denied to configuration file
|
|
|
165
165
|
export { Configuration }
|
|
166
166
|
|
|
167
167
|
export declare const Container: {
|
|
168
|
-
({ children, className, connected, uploadFile, allowFileUpload, ...props }: Props_4): JSX_3.Element;
|
|
168
|
+
({ children, className, connected, uploadFile, allowFileUpload, storageKey, ...props }: Props_4): JSX_3.Element;
|
|
169
169
|
displayName: string;
|
|
170
170
|
};
|
|
171
171
|
|
|
@@ -211,9 +211,10 @@ export declare function enrichMessage(messages: BlockMessage[], participants: Us
|
|
|
211
211
|
declare type ErrorProps = {
|
|
212
212
|
error: WebchatError;
|
|
213
213
|
restartConversation?: () => void;
|
|
214
|
+
closeWindow?: () => void;
|
|
214
215
|
};
|
|
215
216
|
|
|
216
|
-
export declare function ErrorState({ error, restartConversation }: ErrorProps): JSX_3.Element;
|
|
217
|
+
export declare function ErrorState({ error, restartConversation, closeWindow }: ErrorProps): JSX_3.Element;
|
|
217
218
|
|
|
218
219
|
declare type EventError = Error & {
|
|
219
220
|
type: 'error';
|
|
@@ -243,6 +244,8 @@ export declare type FileType = (typeof fileTypes)[number];
|
|
|
243
244
|
|
|
244
245
|
export declare const fileTypes: readonly ["audio", "file", "image", "video"];
|
|
245
246
|
|
|
247
|
+
export declare function generateThemeOverride(theme: LatestWebchatTheme): Record<string, string>;
|
|
248
|
+
|
|
246
249
|
export declare function generateThemeStylesheet(theme: LatestWebchatTheme): string;
|
|
247
250
|
|
|
248
251
|
export declare type GenericBlock = AudioBlock | BubbleBlock | ButtonBlock | CarouselBlock | ColumnBlock | DropdownBlock | FileBlock | ImageBlock | LocationBlock | RowBlock | TextBlock | VideoBlock | CustomBlock;
|
|
@@ -412,9 +415,11 @@ export declare type Props = {
|
|
|
412
415
|
}>;
|
|
413
416
|
addMessageFeedback?: (messageId: string, feedback: Feedback) => void;
|
|
414
417
|
error?: WebchatError;
|
|
418
|
+
storageKey?: string;
|
|
415
419
|
};
|
|
416
420
|
|
|
417
421
|
declare type Props_2 = {
|
|
422
|
+
adminKey?: string;
|
|
418
423
|
user?: UserCredentials;
|
|
419
424
|
conversationId?: string;
|
|
420
425
|
clientId: string;
|
|
@@ -436,6 +441,7 @@ declare type Props_3 = ComponentProps<'div'> & {
|
|
|
436
441
|
name: string;
|
|
437
442
|
type: FileType;
|
|
438
443
|
}>;
|
|
444
|
+
storageKey?: string;
|
|
439
445
|
} & Pick<Configuration, 'composerPlaceholder' | 'footer'>;
|
|
440
446
|
|
|
441
447
|
declare type Props_4 = ComponentProps<'div'> & {
|
|
@@ -446,6 +452,7 @@ declare type Props_4 = ComponentProps<'div'> & {
|
|
|
446
452
|
type: FileType;
|
|
447
453
|
}>;
|
|
448
454
|
allowFileUpload?: boolean;
|
|
455
|
+
storageKey?: string;
|
|
449
456
|
};
|
|
450
457
|
|
|
451
458
|
declare type Props_5 = {
|
|
@@ -514,6 +521,10 @@ export declare type StyleOptions = {
|
|
|
514
521
|
style?: CSSProperties;
|
|
515
522
|
};
|
|
516
523
|
|
|
524
|
+
/**
|
|
525
|
+
* StylesheetProvider component that manages theme styles and font loading
|
|
526
|
+
* Handles both default fonts and custom Google Fonts
|
|
527
|
+
*/
|
|
517
528
|
export declare const StylesheetProvider: ({ color, fontFamily, radius, themeMode, variant, headerVariant }: Props_7) => JSX_3.Element;
|
|
518
529
|
|
|
519
530
|
export declare type TextBlock = {
|
|
@@ -539,7 +550,7 @@ declare type UserProfile = Omit<User, 'id' | 'createdAt' | 'updatedAt'>;
|
|
|
539
550
|
|
|
540
551
|
declare type UserResponse = Awaited<ReturnType<Client['getUser']>>['user'];
|
|
541
552
|
|
|
542
|
-
export declare function useWebchat({ apiUrl, clientId, storageKey, storageLocation, ...props }: Props_2): UseWebchatReturn;
|
|
553
|
+
export declare function useWebchat({ apiUrl, clientId, storageKey, storageLocation, adminKey, ...props }: Props_2): UseWebchatReturn;
|
|
543
554
|
|
|
544
555
|
declare type UseWebchatReturn = {
|
|
545
556
|
clientState: 'connected' | 'disconnected' | 'error';
|