@mathews_cometchat/bubble-builder 1.0.0-alpha24 → 1.0.0-alpha26
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.
|
@@ -14,6 +14,10 @@ export interface NotificationConfig {
|
|
|
14
14
|
appName?: string;
|
|
15
15
|
/** App icon URL shown in the notification preview */
|
|
16
16
|
appIcon?: string;
|
|
17
|
+
/** Show the Data key-value editor in the notification tab */
|
|
18
|
+
enableData?: boolean;
|
|
19
|
+
/** Called when notification data changes */
|
|
20
|
+
onNotificationDataChange?: (data: Record<string, string>) => void;
|
|
17
21
|
}
|
|
18
22
|
/** Which channels the builder supports */
|
|
19
23
|
export type BuilderChannels = 'inapp' | 'push' | 'both';
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import type { BubbleElement, BubbleSettings, BubbleMessage, Template, ElementType } from '../types/schema';
|
|
2
2
|
import type { ComponentTemplateName } from '../config/component-templates';
|
|
3
|
-
import type
|
|
3
|
+
import { type BubbleVariable } from '../config/builder-config';
|
|
4
4
|
export interface BuilderState {
|
|
5
5
|
templateId: string | null;
|
|
6
6
|
templateName: string;
|
|
@@ -10,6 +10,10 @@ export interface BuilderState {
|
|
|
10
10
|
fallbackText: string;
|
|
11
11
|
notificationTitle: string;
|
|
12
12
|
notificationBody: string;
|
|
13
|
+
notificationData: Array<{
|
|
14
|
+
key: string;
|
|
15
|
+
value: string;
|
|
16
|
+
}>;
|
|
13
17
|
notificationEnabled: boolean;
|
|
14
18
|
/** Which view the canvas shows: bubble editor or notification preview */
|
|
15
19
|
canvasView: 'bubble' | 'notification';
|
|
@@ -56,6 +60,10 @@ export interface BuilderState {
|
|
|
56
60
|
setFallbackText: (text: string) => void;
|
|
57
61
|
setNotificationTitle: (text: string) => void;
|
|
58
62
|
setNotificationBody: (text: string) => void;
|
|
63
|
+
setNotificationData: (data: Array<{
|
|
64
|
+
key: string;
|
|
65
|
+
value: string;
|
|
66
|
+
}>) => void;
|
|
59
67
|
setNotificationEnabled: (enabled: boolean) => void;
|
|
60
68
|
setCanvasView: (view: 'bubble' | 'notification') => void;
|
|
61
69
|
setChannels: (channels: 'inapp' | 'push' | 'both') => void;
|