@embedreach/components 0.1.101 → 0.1.103

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.ts CHANGED
@@ -40,6 +40,24 @@ declare interface CreateAutomationModalProps {
40
40
  automationType?: AutomationTriggerType.ONE_TIME;
41
41
  }
42
42
 
43
+ /**
44
+ * dynamic merge field
45
+ */
46
+ declare type DynamicMergeField = ReachMergeFieldBase & {
47
+ type: ReachMergeFieldTypeEnum.DYNAMIC;
48
+ /**
49
+ * The merge fields to be used in the dynamic merge field
50
+ */
51
+ mergeFields: {
52
+ displayName: string;
53
+ templateName: string;
54
+ }[];
55
+ /**
56
+ * The url of the dynamic merge field (e.g. "https://acme.co/id/")
57
+ */
58
+ url: string;
59
+ };
60
+
43
61
  export declare const Engage: ({ iconDefinitions: mergedIconDefinitions, }: {
44
62
  iconDefinitions: IconDefinitionsType;
45
63
  }) => JSX_2.Element;
@@ -130,25 +148,22 @@ export declare interface ReachConfig {
130
148
  language?: LanguageConfig;
131
149
  }
132
150
 
133
- declare type ReachMergeField = StaticMergeField;
151
+ declare type ReachMergeField = StaticMergeField | DynamicMergeField;
134
152
 
135
153
  declare type ReachMergeFieldBase = {
136
- /**
137
- * The display name of the merge field.
138
- */
139
- displayName: string;
140
- /**
141
- * Merge field template to display in the editor (e.g. {{dogs owned}})
142
- */
143
- templateName: string;
144
154
  /**
145
155
  * The type of the merge field
146
156
  */
147
157
  type: ReachMergeFieldTypeEnum;
158
+ /**
159
+ * The id of the merge field. This will be used when updating merge field contents
160
+ */
161
+ id: string;
148
162
  };
149
163
 
150
164
  declare enum ReachMergeFieldTypeEnum {
151
- STATIC = "static"
165
+ STATIC = "static",
166
+ DYNAMIC = "dynamic"
152
167
  }
153
168
 
154
169
  export declare const ReachProvider: default_2.FC<ReachConfig & {
@@ -200,6 +215,14 @@ declare type StaticMergeField = ReachMergeFieldBase & {
200
215
  * The static value of the merge field (e.g. "BLACKFRIDAYSALE50")
201
216
  */
202
217
  staticValue: string;
218
+ /**
219
+ * The display name of the merge field (e.g. "Black Friday Sale 50% off")
220
+ */
221
+ displayName: string;
222
+ /**
223
+ * Merge field template to display in the editor (e.g. {{dogs owned}})
224
+ */
225
+ templateName: string;
203
226
  };
204
227
 
205
228
  /**
package/dist/index.es.js CHANGED
@@ -1,10 +1,10 @@
1
- import { W as e, Y as t, Z as i, _ as r, X as g, a0 as s, a1 as m } from "./chunks/index.js";
1
+ import { W, Y, Z, _, X, a0, a1 } from "./chunks/index.js";
2
2
  export {
3
- e as AutomationTriggerType,
4
- t as CreateAutomationDialog,
5
- i as CreateAutomationModal,
6
- r as Engage,
7
- g as ReachProvider,
8
- s as SegmentBuilderDialog,
9
- m as ViewAutomationModal
3
+ W as AutomationTriggerType,
4
+ Y as CreateAutomationDialog,
5
+ Z as CreateAutomationModal,
6
+ _ as Engage,
7
+ X as ReachProvider,
8
+ a0 as SegmentBuilderDialog,
9
+ a1 as ViewAutomationModal
10
10
  };