@sparrowengg/integrations-templates-frontend 1.9.84-beta.1 → 1.9.84-beta.11

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.
Files changed (99) hide show
  1. package/dist/cjs/_virtual/index10.js +2 -2
  2. package/dist/cjs/_virtual/index9.js +2 -2
  3. package/dist/cjs/authentication/constants/index.js +115 -1
  4. package/dist/cjs/authentication/constants/index.js.map +1 -1
  5. package/dist/cjs/authentication/index.js +36 -32
  6. package/dist/cjs/authentication/index.js.map +1 -1
  7. package/dist/cjs/commons/components/NamingModal.js +82 -0
  8. package/dist/cjs/commons/components/NamingModal.js.map +1 -0
  9. package/dist/cjs/commons/constants/enhanced.js +12 -0
  10. package/dist/cjs/commons/constants/enhanced.js.map +1 -0
  11. package/dist/cjs/commons/constants/index.js +7 -1
  12. package/dist/cjs/commons/constants/index.js.map +1 -1
  13. package/dist/cjs/contact-import/components/contact-import-configure.js.map +1 -1
  14. package/dist/cjs/contact-import/components/contact-import-mapping.js +10 -7
  15. package/dist/cjs/contact-import/components/contact-import-mapping.js.map +1 -1
  16. package/dist/cjs/contact-import/index.js +6 -9
  17. package/dist/cjs/contact-import/index.js.map +1 -1
  18. package/dist/cjs/integration-template/components/dashboard.js +225 -179
  19. package/dist/cjs/integration-template/components/dashboard.js.map +1 -1
  20. package/dist/cjs/integration-template/index.js +33 -14
  21. package/dist/cjs/integration-template/index.js.map +1 -1
  22. package/dist/cjs/mapping/components/custom-date-menu.js +3 -2
  23. package/dist/cjs/mapping/components/custom-date-menu.js.map +1 -1
  24. package/dist/cjs/mapping/components/custom-menu.js.map +1 -1
  25. package/dist/cjs/mapping/components/field.js +14 -6
  26. package/dist/cjs/mapping/components/field.js.map +1 -1
  27. package/dist/cjs/mapping/components/mapping.js +29 -21
  28. package/dist/cjs/mapping/components/mapping.js.map +1 -1
  29. package/dist/cjs/mapping/constants/index.js +32 -0
  30. package/dist/cjs/mapping/constants/index.js.map +1 -0
  31. package/dist/cjs/mapping/index.js +453 -24
  32. package/dist/cjs/mapping/index.js.map +1 -1
  33. package/dist/cjs/mapping/services/index.js.map +1 -1
  34. package/dist/cjs/node_modules/@internationalized/date/dist/utils.js +2 -1
  35. package/dist/cjs/node_modules/@internationalized/date/dist/utils.js.map +1 -1
  36. package/dist/cjs/node_modules/hoist-non-react-statics/node_modules/react-is/index.js +1 -1
  37. package/dist/cjs/node_modules/html-dom-parser/node_modules/domutils/lib/index.js +1 -1
  38. package/dist/cjs/node_modules/html-dom-parser/node_modules/htmlparser2/lib/index.js +1 -1
  39. package/dist/cjs/single-mapping/components/mapping.js +28 -14
  40. package/dist/cjs/single-mapping/components/mapping.js.map +1 -1
  41. package/dist/cjs/single-mapping/index.js +25 -28
  42. package/dist/cjs/single-mapping/index.js.map +1 -1
  43. package/dist/cjs/triggers/components/trigger.js +14 -18
  44. package/dist/cjs/triggers/components/trigger.js.map +1 -1
  45. package/dist/cjs/triggers/constants/index.js +5 -11
  46. package/dist/cjs/triggers/constants/index.js.map +1 -1
  47. package/dist/cjs/triggers/index.js +16 -21
  48. package/dist/cjs/triggers/index.js.map +1 -1
  49. package/dist/es/_virtual/index10.js +2 -2
  50. package/dist/es/_virtual/index9.js +2 -2
  51. package/dist/es/authentication/constants/index.js +114 -2
  52. package/dist/es/authentication/constants/index.js.map +1 -1
  53. package/dist/es/authentication/index.js +35 -31
  54. package/dist/es/authentication/index.js.map +1 -1
  55. package/dist/es/commons/components/NamingModal.js +78 -0
  56. package/dist/es/commons/components/NamingModal.js.map +1 -0
  57. package/dist/es/commons/constants/enhanced.js +10 -0
  58. package/dist/es/commons/constants/enhanced.js.map +1 -0
  59. package/dist/es/commons/constants/index.js +5 -2
  60. package/dist/es/commons/constants/index.js.map +1 -1
  61. package/dist/es/contact-import/components/contact-import-configure.js.map +1 -1
  62. package/dist/es/contact-import/components/contact-import-mapping.js +10 -7
  63. package/dist/es/contact-import/components/contact-import-mapping.js.map +1 -1
  64. package/dist/es/contact-import/index.js +4 -7
  65. package/dist/es/contact-import/index.js.map +1 -1
  66. package/dist/es/integration-template/components/dashboard.js +225 -179
  67. package/dist/es/integration-template/components/dashboard.js.map +1 -1
  68. package/dist/es/integration-template/index.js +33 -14
  69. package/dist/es/integration-template/index.js.map +1 -1
  70. package/dist/es/mapping/components/custom-date-menu.js +3 -2
  71. package/dist/es/mapping/components/custom-date-menu.js.map +1 -1
  72. package/dist/es/mapping/components/custom-menu.js.map +1 -1
  73. package/dist/es/mapping/components/field.js +14 -6
  74. package/dist/es/mapping/components/field.js.map +1 -1
  75. package/dist/es/mapping/components/mapping.js +30 -22
  76. package/dist/es/mapping/components/mapping.js.map +1 -1
  77. package/dist/es/mapping/constants/index.js +28 -0
  78. package/dist/es/mapping/constants/index.js.map +1 -0
  79. package/dist/es/mapping/index.js +453 -24
  80. package/dist/es/mapping/index.js.map +1 -1
  81. package/dist/es/mapping/services/index.js.map +1 -1
  82. package/dist/es/node_modules/@internationalized/date/dist/utils.js +2 -1
  83. package/dist/es/node_modules/@internationalized/date/dist/utils.js.map +1 -1
  84. package/dist/es/node_modules/@sparrowengg/twigs-react/dist/es/dialog/dialog.js +1 -1
  85. package/dist/es/node_modules/hoist-non-react-statics/node_modules/react-is/index.js +1 -1
  86. package/dist/es/node_modules/html-dom-parser/node_modules/domutils/lib/index.js +1 -1
  87. package/dist/es/node_modules/html-dom-parser/node_modules/htmlparser2/lib/index.js +1 -1
  88. package/dist/es/single-mapping/components/mapping.js +28 -14
  89. package/dist/es/single-mapping/components/mapping.js.map +1 -1
  90. package/dist/es/single-mapping/index.js +25 -28
  91. package/dist/es/single-mapping/index.js.map +1 -1
  92. package/dist/es/triggers/components/trigger.js +14 -18
  93. package/dist/es/triggers/components/trigger.js.map +1 -1
  94. package/dist/es/triggers/constants/index.js +5 -11
  95. package/dist/es/triggers/constants/index.js.map +1 -1
  96. package/dist/es/triggers/index.js +16 -21
  97. package/dist/es/triggers/index.js.map +1 -1
  98. package/dist/index.d.ts +269 -90
  99. package/package.json +2 -1
@@ -59,7 +59,17 @@ const Dashboard = ({
59
59
  alignItems: "center"
60
60
  },
61
61
  /* @__PURE__ */ React__default.createElement(Flex, { flexDirection: "column", gap: "$2" }, /* @__PURE__ */ React__default.createElement(Heading, { size: "h5" }, integrationName), /* @__PURE__ */ React__default.createElement(Text, { size: "sm", css: { color: "$neutral700" } }, dashboardDescription)),
62
- /* @__PURE__ */ React__default.createElement(Flex, { alignItems: "center", gap: "$4" }, hasMultiAccounts && /* @__PURE__ */ React__default.createElement(Button, { size: "lg", color: "default", leftIcon: /* @__PURE__ */ React__default.createElement(PlusIcon, null) }, "Add Account"), hasDropdownComponents.mapping && !hasDropdownComponents.trigger ? /* @__PURE__ */ React__default.createElement(Button, { size: "lg", color: "primary", disabled: !mappingEnabled, leftIcon: /* @__PURE__ */ React__default.createElement(PlusIcon, null), onClick: () => handleConfigurationType("MAPPING") }, "New Mapping") : null, hasDropdownComponents.trigger && hasDropdownComponents.mapping ? /* @__PURE__ */ React__default.createElement(DropdownMenu, null, /* @__PURE__ */ React__default.createElement(
62
+ /* @__PURE__ */ React__default.createElement(Flex, { alignItems: "center", gap: "$4" }, hasMultiAccounts && /* @__PURE__ */ React__default.createElement(Button, { size: "lg", color: "default", leftIcon: /* @__PURE__ */ React__default.createElement(PlusIcon, null) }, "Add Account"), hasDropdownComponents.mapping && !hasDropdownComponents.trigger ? /* @__PURE__ */ React__default.createElement(
63
+ Button,
64
+ {
65
+ size: "lg",
66
+ color: "primary",
67
+ disabled: !mappingEnabled,
68
+ leftIcon: /* @__PURE__ */ React__default.createElement(PlusIcon, null),
69
+ onClick: () => handleConfigurationType("MAPPING")
70
+ },
71
+ "New Mapping"
72
+ ) : null, hasDropdownComponents.trigger && hasDropdownComponents.mapping ? /* @__PURE__ */ React__default.createElement(DropdownMenu, null, /* @__PURE__ */ React__default.createElement(
63
73
  Tooltip,
64
74
  {
65
75
  content: !triggerEnabled && !mappingEnabled ? "You have reached the maximum limit for creating triggers/mappings" : ""
@@ -186,17 +196,17 @@ const MultiAccountDashboard = ({
186
196
  css: { paddingBlock: "$12", paddingInline: 0 }
187
197
  },
188
198
  /* @__PURE__ */ React__default.createElement(Flex, { flexDirection: "column", gap: "$8" }, !!(triggerFields == null ? void 0 : triggerFields.length) ? /* @__PURE__ */ React__default.createElement(React__default.Fragment, null, triggerFields == null ? void 0 : triggerFields.map((field) => {
189
- var _a2, _b2, _c2;
199
+ var _a2, _b2, _c2, _d2, _e;
190
200
  return /* @__PURE__ */ React__default.createElement(
191
201
  DashboardItem,
192
202
  {
193
203
  key: field.id,
194
- isDraft: field == null ? void 0 : field.isDraft,
204
+ isDraft: (_a2 = field == null ? void 0 : field.isDraft) != null ? _a2 : false,
195
205
  onMappingEditHandler,
196
206
  icon: /* @__PURE__ */ React__default.createElement(CursorIcon, { size: 32, color: "#56B0BB" }),
197
- heading: (_a2 = field.domain) != null ? _a2 : field.email,
207
+ heading: (_c2 = (_b2 = field.domain) != null ? _b2 : field.email) != null ? _c2 : "Field",
198
208
  id: field.id,
199
- description: `Trigger survey when an ${(_b2 = field == null ? void 0 : field.object) == null ? void 0 : _b2.toLowerCase()} is ${(_c2 = field == null ? void 0 : field.action) == null ? void 0 : _c2.toLowerCase()} in ${integrationName}`,
209
+ description: `Trigger survey when an ${(_d2 = field == null ? void 0 : field.object) == null ? void 0 : _d2.toLowerCase()} is ${(_e = field == null ? void 0 : field.action) == null ? void 0 : _e.toLowerCase()} in ${integrationName}`,
200
210
  fields: field.fields,
201
211
  isEnabled: field.isEnabled,
202
212
  integrationName,
@@ -207,43 +217,45 @@ const MultiAccountDashboard = ({
207
217
  deleteFieldHandler
208
218
  }
209
219
  );
210
- })) : null, !!((_a = mappingFields == null ? void 0 : mappingFields.fields) == null ? void 0 : _a.length) ? /* @__PURE__ */ React__default.createElement(React__default.Fragment, null, (_b = mappingFields == null ? void 0 : mappingFields.fields) == null ? void 0 : _b.map((field) => {
211
- var _a2, _b2, _c2, _d2, _e, _f, _g;
212
- return /* @__PURE__ */ React__default.createElement(React__default.Fragment, null, mappingFields.type === "MULTI_MAPPING" ? /* @__PURE__ */ React__default.createElement(
213
- DashboardItem,
214
- {
215
- key: field.id,
216
- isDraft: field == null ? void 0 : field.isDraft,
217
- onMappingEditHandler,
218
- icon: /* @__PURE__ */ React__default.createElement(MappingIcon, { size: 32, color: "#56B0BB" }),
219
- heading: (_a2 = field.domain) != null ? _a2 : field.email,
220
- id: field.id,
221
- description: `Sync survey responses to ${integrationName} when ${(_d2 = (_c2 = (_b2 = field == null ? void 0 : field.mappingConfiguration) == null ? void 0 : _b2.events) == null ? void 0 : _c2.label) == null ? void 0 : _d2.toLowerCase()} is ${trasformToPastTense(`${(_g = (_f = (_e = field == null ? void 0 : field.mappingConfiguration) == null ? void 0 : _e.action) == null ? void 0 : _f.label) == null ? void 0 : _g.toLowerCase()}`)}`,
222
- fields: field.fields,
223
- isEnabled: field.isEnabled,
224
- integrationName,
225
- handleDashboardPage,
226
- handleEditField,
227
- type: "MAPPING",
228
- toggleDashboardField,
229
- deleteFieldHandler
230
- }
231
- ) : /* @__PURE__ */ React__default.createElement(
232
- SingleMappingDashboardItem,
233
- {
234
- key: field.id,
235
- field,
236
- integrationName,
237
- syncMapping,
238
- icon: /* @__PURE__ */ React__default.createElement(MappingIcon, { size: 32, color: "#56B0BB" }),
239
- handleEditField,
240
- handleDashboardPage,
241
- toggleDashboardField,
242
- deleteFieldHandler,
243
- onMappingEditHandler
244
- }
245
- ));
246
- })) : null)
220
+ })) : null, !!((_a = mappingFields == null ? void 0 : mappingFields.fields) == null ? void 0 : _a.length) ? /* @__PURE__ */ React__default.createElement(React__default.Fragment, null, (_b = mappingFields == null ? void 0 : mappingFields.fields) == null ? void 0 : _b.map(
221
+ (field) => {
222
+ var _a2, _b2, _c2, _d2, _e, _f, _g, _h, _i;
223
+ return /* @__PURE__ */ React__default.createElement(React__default.Fragment, null, (mappingFields == null ? void 0 : mappingFields.type) === "MULTI_MAPPING" ? /* @__PURE__ */ React__default.createElement(
224
+ DashboardItem,
225
+ {
226
+ key: field.id,
227
+ isDraft: (_a2 = field == null ? void 0 : field.isDraft) != null ? _a2 : false,
228
+ onMappingEditHandler,
229
+ icon: /* @__PURE__ */ React__default.createElement(MappingIcon, { size: 32, color: "#56B0BB" }),
230
+ heading: (_c2 = (_b2 = field.domain) != null ? _b2 : field.email) != null ? _c2 : "Field",
231
+ id: field.id,
232
+ description: (field == null ? void 0 : field.mappingDescription) || `Sync survey responses to ${integrationName} when ${(_f = (_e = (_d2 = field == null ? void 0 : field.mappingConfiguration) == null ? void 0 : _d2.events) == null ? void 0 : _e.label) == null ? void 0 : _f.toLowerCase()} is ${trasformToPastTense(`${(_i = (_h = (_g = field == null ? void 0 : field.mappingConfiguration) == null ? void 0 : _g.action) == null ? void 0 : _h.label) == null ? void 0 : _i.toLowerCase()}`)}`,
233
+ fields: field.fields,
234
+ isEnabled: field.isEnabled,
235
+ integrationName,
236
+ handleDashboardPage,
237
+ handleEditField,
238
+ type: "MAPPING",
239
+ toggleDashboardField,
240
+ deleteFieldHandler
241
+ }
242
+ ) : /* @__PURE__ */ React__default.createElement(
243
+ SingleMappingDashboardItem,
244
+ {
245
+ key: field.id,
246
+ field,
247
+ integrationName,
248
+ syncMapping,
249
+ icon: /* @__PURE__ */ React__default.createElement(MappingIcon, { size: 32, color: "#56B0BB" }),
250
+ handleEditField,
251
+ handleDashboardPage,
252
+ toggleDashboardField,
253
+ deleteFieldHandler,
254
+ onMappingEditHandler
255
+ }
256
+ ));
257
+ }
258
+ )) : null)
247
259
  ), /* @__PURE__ */ React__default.createElement(
248
260
  TabsContent,
249
261
  {
@@ -251,17 +263,17 @@ const MultiAccountDashboard = ({
251
263
  css: { paddingBlock: "$12", paddingInline: 0 }
252
264
  },
253
265
  !!(triggerFields == null ? void 0 : triggerFields.length) ? /* @__PURE__ */ React__default.createElement(Flex, { flexDirection: "column", gap: "$8" }, triggerFields == null ? void 0 : triggerFields.map((field) => {
254
- var _a2, _b2;
266
+ var _a2, _b2, _c2;
255
267
  return /* @__PURE__ */ React__default.createElement(
256
268
  DashboardItem,
257
269
  {
258
270
  key: field.id,
259
- isDraft: field == null ? void 0 : field.isDraft,
271
+ isDraft: (_a2 = field == null ? void 0 : field.isDraft) != null ? _a2 : false,
260
272
  onMappingEditHandler,
261
273
  icon: /* @__PURE__ */ React__default.createElement(CursorIcon, { size: 32, color: "#56B0BB" }),
262
274
  heading: "Trigger",
263
275
  id: field.id,
264
- description: `Trigger survey when an ${(_a2 = field == null ? void 0 : field.object) == null ? void 0 : _a2.toLowerCase()} is ${(_b2 = field == null ? void 0 : field.action) == null ? void 0 : _b2.toLowerCase()} in ${integrationName}`,
276
+ description: `Trigger survey when an ${(_b2 = field == null ? void 0 : field.object) == null ? void 0 : _b2.toLowerCase()} is ${(_c2 = field == null ? void 0 : field.action) == null ? void 0 : _c2.toLowerCase()} in ${integrationName}`,
265
277
  fields: field.fields,
266
278
  isEnabled: field.isEnabled,
267
279
  integrationName,
@@ -285,43 +297,45 @@ const MultiAccountDashboard = ({
285
297
  value: "MAPPING",
286
298
  css: { paddingBlock: "$12", paddingInline: 0 }
287
299
  },
288
- !!((_c = mappingFields == null ? void 0 : mappingFields.fields) == null ? void 0 : _c.length) ? /* @__PURE__ */ React__default.createElement(React__default.Fragment, null, /* @__PURE__ */ React__default.createElement(Flex, { flexDirection: "column", gap: "$8" }, (_d = mappingFields == null ? void 0 : mappingFields.fields) == null ? void 0 : _d.map((field) => {
289
- var _a2, _b2, _c2, _d2, _e, _f;
290
- return /* @__PURE__ */ React__default.createElement(React__default.Fragment, null, mappingFields.type === "MULTI_MAPPING" ? /* @__PURE__ */ React__default.createElement(
291
- DashboardItem,
292
- {
293
- key: field.id,
294
- isDraft: field == null ? void 0 : field.isDraft,
295
- onMappingEditHandler,
296
- icon: /* @__PURE__ */ React__default.createElement(MappingIcon, { size: 32, color: "#56B0BB" }),
297
- heading: "Mapping",
298
- id: field.id,
299
- description: `Sync survey responses to ${integrationName} when ${(_c2 = (_b2 = (_a2 = field == null ? void 0 : field.mappingConfiguration) == null ? void 0 : _a2.events) == null ? void 0 : _b2.label) == null ? void 0 : _c2.toLowerCase()} is ${trasformToPastTense(`${(_f = (_e = (_d2 = field == null ? void 0 : field.mappingConfiguration) == null ? void 0 : _d2.action) == null ? void 0 : _e.label) == null ? void 0 : _f.toLowerCase()}`)}`,
300
- fields: field.fields,
301
- isEnabled: field.isEnabled,
302
- integrationName,
303
- handleDashboardPage,
304
- handleEditField,
305
- type: "MAPPING",
306
- toggleDashboardField,
307
- deleteFieldHandler
308
- }
309
- ) : /* @__PURE__ */ React__default.createElement(
310
- SingleMappingDashboardItem,
311
- {
312
- key: field.id,
313
- field,
314
- integrationName,
315
- syncMapping,
316
- icon: /* @__PURE__ */ React__default.createElement(MappingIcon, { size: 32, color: "#56B0BB" }),
317
- handleEditField,
318
- handleDashboardPage,
319
- toggleDashboardField,
320
- deleteFieldHandler,
321
- onMappingEditHandler
322
- }
323
- ));
324
- }))) : /* @__PURE__ */ React__default.createElement(
300
+ !!((_c = mappingFields == null ? void 0 : mappingFields.fields) == null ? void 0 : _c.length) ? /* @__PURE__ */ React__default.createElement(React__default.Fragment, null, /* @__PURE__ */ React__default.createElement(Flex, { flexDirection: "column", gap: "$8" }, (_d = mappingFields == null ? void 0 : mappingFields.fields) == null ? void 0 : _d.map(
301
+ (field) => {
302
+ var _a2, _b2, _c2, _d2, _e, _f, _g;
303
+ return /* @__PURE__ */ React__default.createElement(React__default.Fragment, null, (mappingFields == null ? void 0 : mappingFields.type) === "MULTI_MAPPING" ? /* @__PURE__ */ React__default.createElement(
304
+ DashboardItem,
305
+ {
306
+ key: field.id,
307
+ isDraft: (_a2 = field == null ? void 0 : field.isDraft) != null ? _a2 : false,
308
+ onMappingEditHandler,
309
+ icon: /* @__PURE__ */ React__default.createElement(MappingIcon, { size: 32, color: "#56B0BB" }),
310
+ heading: (field == null ? void 0 : field.mappingName) || "Mapping",
311
+ id: field.id,
312
+ description: (field == null ? void 0 : field.mappingDescription) || `Sync survey responses to ${integrationName} when ${(_d2 = (_c2 = (_b2 = field == null ? void 0 : field.mappingConfiguration) == null ? void 0 : _b2.events) == null ? void 0 : _c2.label) == null ? void 0 : _d2.toLowerCase()} is ${trasformToPastTense(`${(_g = (_f = (_e = field == null ? void 0 : field.mappingConfiguration) == null ? void 0 : _e.action) == null ? void 0 : _f.label) == null ? void 0 : _g.toLowerCase()}`)}`,
313
+ fields: field.fields,
314
+ isEnabled: field.isEnabled,
315
+ integrationName,
316
+ handleDashboardPage,
317
+ handleEditField,
318
+ type: "MAPPING",
319
+ toggleDashboardField,
320
+ deleteFieldHandler
321
+ }
322
+ ) : /* @__PURE__ */ React__default.createElement(
323
+ SingleMappingDashboardItem,
324
+ {
325
+ key: field.id,
326
+ field,
327
+ integrationName,
328
+ syncMapping,
329
+ icon: /* @__PURE__ */ React__default.createElement(MappingIcon, { size: 32, color: "#56B0BB" }),
330
+ handleEditField,
331
+ handleDashboardPage,
332
+ toggleDashboardField,
333
+ deleteFieldHandler,
334
+ onMappingEditHandler
335
+ }
336
+ ));
337
+ }
338
+ ))) : /* @__PURE__ */ React__default.createElement(
325
339
  MultiAccountFallback,
326
340
  {
327
341
  title: "Mapping",
@@ -382,16 +396,16 @@ const SingleAccountDashboard = ({
382
396
  toggleDashboardField,
383
397
  deleteFieldHandler
384
398
  }) => {
385
- var _a, _b, _c, _d, _e, _f, _g;
399
+ var _a, _b, _c, _d, _e, _f, _g, _h, _i;
386
400
  return /* @__PURE__ */ React__default.createElement(React__default.Fragment, null, !!(triggerFields == null ? void 0 : triggerFields.length) ? /* @__PURE__ */ React__default.createElement(Box, { css: { marginTop: "$20" } }, triggerFields == null ? void 0 : triggerFields.map((field) => {
387
- var _a2, _b2;
401
+ var _a2, _b2, _c2, _d2;
388
402
  return /* @__PURE__ */ React__default.createElement(
389
403
  TriggerDasboardItem,
390
404
  {
391
- isDraft: field == null ? void 0 : field.isDraft,
405
+ isDraft: (_a2 = field == null ? void 0 : field.isDraft) != null ? _a2 : false,
392
406
  fieldOptions,
393
407
  field,
394
- description: `Trigger survey when ${/^[aeiouAEIOU]$/.test(field == null ? void 0 : field.object[0]) ? "an" : "a"} ${(_a2 = field == null ? void 0 : field.object) == null ? void 0 : _a2.toLowerCase()} is ${(_b2 = field == null ? void 0 : field.action) == null ? void 0 : _b2.toLowerCase()} in ${integrationName}`,
408
+ description: `Trigger survey when ${/^[aeiouAEIOU]$/.test(((_b2 = field == null ? void 0 : field.object) == null ? void 0 : _b2[0]) || "") ? "an" : "a"} ${(_c2 = field == null ? void 0 : field.object) == null ? void 0 : _c2.toLowerCase()} is ${(_d2 = field == null ? void 0 : field.action) == null ? void 0 : _d2.toLowerCase()} in ${integrationName}`,
395
409
  key: field.id,
396
410
  integrationName,
397
411
  icon: /* @__PURE__ */ React__default.createElement(CursorIcon, { size: 32, color: "#56B0BB" }),
@@ -401,28 +415,71 @@ const SingleAccountDashboard = ({
401
415
  deleteFieldHandler
402
416
  }
403
417
  );
404
- })) : null, !!((_a = mappingFields == null ? void 0 : mappingFields.fields) == null ? void 0 : _a.length) && (mappingFields == null ? void 0 : mappingFields.type) === "MULTI_MAPPING" ? /* @__PURE__ */ React__default.createElement(Box, { css: { marginTop: !(triggerFields == null ? void 0 : triggerFields.length) ? "$20" : "$8" } }, (_b = mappingFields == null ? void 0 : mappingFields.fields) == null ? void 0 : _b.map((field) => {
405
- var _a2, _b2, _c2, _d2, _e2, _f2;
406
- return /* @__PURE__ */ React__default.createElement(
407
- DashboardItem,
408
- {
409
- isDraft: field == null ? void 0 : field.isDraft,
410
- onMappingEditHandler,
411
- icon: /* @__PURE__ */ React__default.createElement(MappingIcon, { size: 32, color: "#56B0BB" }),
412
- heading: "Mapping",
413
- id: field.id,
414
- description: `Sync survey responses to ${integrationName} when ${(_c2 = (_b2 = (_a2 = field == null ? void 0 : field.mappingConfiguration) == null ? void 0 : _a2.events) == null ? void 0 : _b2.label) == null ? void 0 : _c2.toLowerCase()} is ${trasformToPastTense(`${(_f2 = (_e2 = (_d2 = field == null ? void 0 : field.mappingConfiguration) == null ? void 0 : _d2.action) == null ? void 0 : _e2.label) == null ? void 0 : _f2.toLowerCase()}`)}`,
415
- fields: field.fields,
416
- isEnabled: field.isEnabled,
417
- integrationName,
418
- handleDashboardPage,
419
- handleEditField,
420
- type: "MAPPING",
421
- toggleDashboardField,
422
- deleteFieldHandler
418
+ })) : null, (mappingFields == null ? void 0 : mappingFields.type) === "DYNAMIC_MAPPING" ? /* @__PURE__ */ React__default.createElement(React__default.Fragment, null, !!((_a = mappingFields == null ? void 0 : mappingFields.fields) == null ? void 0 : _a.length) ? /* @__PURE__ */ React__default.createElement(Box, { css: { marginTop: !(triggerFields == null ? void 0 : triggerFields.length) ? "$20" : "$8" } }, (_b = mappingFields == null ? void 0 : mappingFields.fields) == null ? void 0 : _b.map(
419
+ (field) => {
420
+ var _a2, _b2, _c2, _d2, _e2, _f2, _g2;
421
+ if ((field == null ? void 0 : field.type) === "MULTI_MAPPING") {
422
+ return /* @__PURE__ */ React__default.createElement(
423
+ DashboardItem,
424
+ {
425
+ isDraft: (_a2 = field == null ? void 0 : field.isDraft) != null ? _a2 : false,
426
+ onMappingEditHandler,
427
+ icon: /* @__PURE__ */ React__default.createElement(MappingIcon, { size: 32, color: "#56B0BB" }),
428
+ heading: (field == null ? void 0 : field.mappingName) || "Mapping",
429
+ id: field.id,
430
+ description: (field == null ? void 0 : field.mappingDescription) || `Sync survey responses to ${integrationName} when ${(_d2 = (_c2 = (_b2 = field == null ? void 0 : field.mappingConfiguration) == null ? void 0 : _b2.events) == null ? void 0 : _c2.label) == null ? void 0 : _d2.toLowerCase()} is ${trasformToPastTense(`${(_g2 = (_f2 = (_e2 = field == null ? void 0 : field.mappingConfiguration) == null ? void 0 : _e2.action) == null ? void 0 : _f2.label) == null ? void 0 : _g2.toLowerCase()}`)}`,
431
+ fields: field.fields,
432
+ isEnabled: field.isEnabled,
433
+ integrationName,
434
+ handleDashboardPage,
435
+ handleEditField,
436
+ type: "MAPPING",
437
+ toggleDashboardField,
438
+ deleteFieldHandler
439
+ }
440
+ );
441
+ } else {
442
+ return /* @__PURE__ */ React__default.createElement(
443
+ SingleMappingDashboardItem,
444
+ {
445
+ onMappingEditHandler,
446
+ syncMapping,
447
+ field,
448
+ key: field == null ? void 0 : field.id,
449
+ integrationName,
450
+ icon: /* @__PURE__ */ React__default.createElement(MappingIcon, { size: 32, color: "#56B0BB" }),
451
+ handleEditField,
452
+ handleDashboardPage,
453
+ toggleDashboardField,
454
+ deleteFieldHandler
455
+ }
456
+ );
423
457
  }
424
- );
425
- })) : null, ((_c = mappingFields == null ? void 0 : mappingFields.mappedFields) == null ? void 0 : _c.type) === "SINGLE_MAPPING" && !!((_e = (_d = mappingFields == null ? void 0 : mappingFields.mappedFields) == null ? void 0 : _d.fields) == null ? void 0 : _e.length) ? /* @__PURE__ */ React__default.createElement(Box, { css: { marginTop: !(triggerFields == null ? void 0 : triggerFields.length) ? "$20" : "$8" } }, (_g = (_f = mappingFields == null ? void 0 : mappingFields.mappedFields) == null ? void 0 : _f.fields) == null ? void 0 : _g.map(
458
+ }
459
+ )) : null) : /* @__PURE__ */ React__default.createElement(React__default.Fragment, null, !!((_c = mappingFields == null ? void 0 : mappingFields.fields) == null ? void 0 : _c.length) && (mappingFields == null ? void 0 : mappingFields.type) === "MULTI_MAPPING" ? /* @__PURE__ */ React__default.createElement(Box, { css: { marginTop: !(triggerFields == null ? void 0 : triggerFields.length) ? "$20" : "$8" } }, (_d = mappingFields == null ? void 0 : mappingFields.fields) == null ? void 0 : _d.map(
460
+ (field) => {
461
+ var _a2, _b2, _c2, _d2, _e2, _f2, _g2;
462
+ return /* @__PURE__ */ React__default.createElement(
463
+ DashboardItem,
464
+ {
465
+ isDraft: (_a2 = field == null ? void 0 : field.isDraft) != null ? _a2 : false,
466
+ onMappingEditHandler,
467
+ icon: /* @__PURE__ */ React__default.createElement(MappingIcon, { size: 32, color: "#56B0BB" }),
468
+ heading: (field == null ? void 0 : field.mappingName) || "Mapping",
469
+ id: field.id,
470
+ description: (field == null ? void 0 : field.mappingDescription) || `Sync survey responses to ${integrationName} when ${(_d2 = (_c2 = (_b2 = field == null ? void 0 : field.mappingConfiguration) == null ? void 0 : _b2.events) == null ? void 0 : _c2.label) == null ? void 0 : _d2.toLowerCase()} is ${trasformToPastTense(`${(_g2 = (_f2 = (_e2 = field == null ? void 0 : field.mappingConfiguration) == null ? void 0 : _e2.action) == null ? void 0 : _f2.label) == null ? void 0 : _g2.toLowerCase()}`)}`,
471
+ fields: field.fields,
472
+ isEnabled: field.isEnabled,
473
+ integrationName,
474
+ handleDashboardPage,
475
+ handleEditField,
476
+ type: "MAPPING",
477
+ toggleDashboardField,
478
+ deleteFieldHandler
479
+ }
480
+ );
481
+ }
482
+ )) : null, console.log(mappingFields, "mappingFields"), ((_e = mappingFields == null ? void 0 : mappingFields.mappedFields) == null ? void 0 : _e.type) === "SINGLE_MAPPING" && !!((_g = (_f = mappingFields == null ? void 0 : mappingFields.mappedFields) == null ? void 0 : _f.fields) == null ? void 0 : _g.length) ? /* @__PURE__ */ React__default.createElement(Box, { css: { marginTop: !(triggerFields == null ? void 0 : triggerFields.length) ? "$20" : "$8" } }, (_i = (_h = mappingFields == null ? void 0 : mappingFields.mappedFields) == null ? void 0 : _h.fields) == null ? void 0 : _i.map(
426
483
  (field, index) => {
427
484
  return /* @__PURE__ */ React__default.createElement(
428
485
  SingleMappingDashboardItem,
@@ -440,7 +497,7 @@ const SingleAccountDashboard = ({
440
497
  }
441
498
  );
442
499
  }
443
- )) : null);
500
+ )) : null));
444
501
  };
445
502
  const TriggerDasboardItem = ({
446
503
  isDraft,
@@ -454,7 +511,7 @@ const TriggerDasboardItem = ({
454
511
  toggleDashboardField,
455
512
  deleteFieldHandler
456
513
  }) => {
457
- var _a, _b, _c, _d, _e, _f, _g, _h, _i, _j, _k, _l, _m, _n, _o, _p, _q, _r, _s;
514
+ var _a, _b, _c, _d, _e, _f, _g, _h, _i, _j, _k, _l, _m, _n, _o, _p, _q, _r, _s, _t, _u;
458
515
  const [isMappingDisplayed, setIsMappingDisplayed] = useState(false);
459
516
  const [isDeleteModalOpen, setIsDeleteModalOpen] = useState(false);
460
517
  const transformDataToString = (data) => {
@@ -615,7 +672,7 @@ const TriggerDasboardItem = ({
615
672
  }
616
673
  },
617
674
  /* @__PURE__ */ React__default.createElement(SingleMappingEventWrapper, { isTrigger: true, field }),
618
- ((_c = (_b = field == null ? void 0 : field.fields) == null ? void 0 : _b.filters) == null ? void 0 : _c.length) ? /* @__PURE__ */ React__default.createElement(React__default.Fragment, null, /* @__PURE__ */ React__default.createElement(
675
+ ((_c = (_b = field.fields) == null ? void 0 : _b.filters) == null ? void 0 : _c.length) ? /* @__PURE__ */ React__default.createElement(React__default.Fragment, null, /* @__PURE__ */ React__default.createElement(
619
676
  Flex,
620
677
  {
621
678
  flexDirection: "column",
@@ -642,12 +699,10 @@ const TriggerDasboardItem = ({
642
699
  }
643
700
  }
644
701
  )) : null,
645
- ((_e = (_d = field == null ? void 0 : field.triggerDetails) == null ? void 0 : _d.variables) == null ? void 0 : _e.filter(
646
- (variable) => variable.isEnabled
647
- ).length) ? /* @__PURE__ */ React__default.createElement(
702
+ ((_g = (_f = (_e = (_d = field == null ? void 0 : field.triggerDetails) == null ? void 0 : _d.variables) == null ? void 0 : _e.filter) == null ? void 0 : _f.call(_e, (variable) => variable.isEnabled)) == null ? void 0 : _g.length) ? /* @__PURE__ */ React__default.createElement(
648
703
  SingleMappingChipWrapper,
649
704
  {
650
- heading: ((_g = (_f = field == null ? void 0 : field.triggerDetails) == null ? void 0 : _f.variables) == null ? void 0 : _g.length) > 1 ? "PASSING VARIABLES TO SURVEY" : "PASSING VARIABLE TO SURVEY",
705
+ heading: ((_i = (_h = field == null ? void 0 : field.triggerDetails) == null ? void 0 : _h.variables) == null ? void 0 : _i.length) > 1 ? "PASSING VARIABLES TO SURVEY" : "PASSING VARIABLE TO SURVEY",
651
706
  fields: field.triggerDetails.variables,
652
707
  backgroundColor: "$positive100"
653
708
  }
@@ -660,25 +715,25 @@ const TriggerDasboardItem = ({
660
715
  css: { paddingBlock: "$8" }
661
716
  },
662
717
  /* @__PURE__ */ React__default.createElement(Text, { size: "sm", weight: "bold" }, "SEND SURVEY"),
663
- /* @__PURE__ */ React__default.createElement(Flex, { alignItems: "center" }, ((_i = (_h = field == null ? void 0 : field.triggerDetails) == null ? void 0 : _h.shareType) == null ? void 0 : _i.value) ? /* @__PURE__ */ React__default.createElement(
718
+ /* @__PURE__ */ React__default.createElement(Flex, { alignItems: "center" }, ((_k = (_j = field == null ? void 0 : field.triggerDetails) == null ? void 0 : _j.shareType) == null ? void 0 : _k.value) ? /* @__PURE__ */ React__default.createElement(
664
719
  EventComponent,
665
720
  {
666
721
  heading: "Share Type:",
667
- description: (_k = (_j = field == null ? void 0 : field.triggerDetails) == null ? void 0 : _j.shareType) == null ? void 0 : _k.label
722
+ description: (_m = (_l = field == null ? void 0 : field.triggerDetails) == null ? void 0 : _l.shareType) == null ? void 0 : _m.label
668
723
  }
669
- ) : null, ((_m = (_l = field == null ? void 0 : field.triggerDetails) == null ? void 0 : _l.shareRecipient) == null ? void 0 : _m.value) ? /* @__PURE__ */ React__default.createElement(
724
+ ) : null, ((_o = (_n = field == null ? void 0 : field.triggerDetails) == null ? void 0 : _n.shareRecipient) == null ? void 0 : _o.value) ? /* @__PURE__ */ React__default.createElement(
670
725
  EventComponent,
671
726
  {
672
727
  heading: "Recipient:",
673
728
  hasBorder: true,
674
- description: (_o = (_n = field == null ? void 0 : field.triggerDetails) == null ? void 0 : _n.shareRecipient) == null ? void 0 : _o.label
729
+ description: (_q = (_p = field == null ? void 0 : field.triggerDetails) == null ? void 0 : _p.shareRecipient) == null ? void 0 : _q.label
675
730
  }
676
- ) : null, ((_q = (_p = field == null ? void 0 : field.triggerDetails) == null ? void 0 : _p.shareChannel) == null ? void 0 : _q.value) ? /* @__PURE__ */ React__default.createElement(
731
+ ) : null, ((_s = (_r = field == null ? void 0 : field.triggerDetails) == null ? void 0 : _r.shareChannel) == null ? void 0 : _s.value) ? /* @__PURE__ */ React__default.createElement(
677
732
  EventComponent,
678
733
  {
679
734
  hasBorder: true,
680
735
  heading: "Share Channel:",
681
- description: (_s = (_r = field == null ? void 0 : field.triggerDetails) == null ? void 0 : _r.shareChannel) == null ? void 0 : _s.label
736
+ description: (_u = (_t = field == null ? void 0 : field.triggerDetails) == null ? void 0 : _t.shareChannel) == null ? void 0 : _u.label
682
737
  }
683
738
  ) : null)
684
739
  ))
@@ -735,7 +790,7 @@ const SingleMappingDashboardItem = ({
735
790
  integrationName,
736
791
  onMappingEditHandler
737
792
  }) => {
738
- var _a, _b, _c, _d, _e, _f, _g, _h, _i, _j, _k, _l, _m, _n, _o, _p, _q, _r, _s, _t, _u, _v, _w, _x, _y, _z, _A, _B, _C, _D, _E, _F, _G, _H, _I;
793
+ var _a, _b, _c, _d, _e, _f, _g, _h, _i, _j, _k, _l, _m, _n, _o, _p, _q, _r, _s, _t, _u, _v, _w, _x, _y, _z, _A, _B, _C, _D, _E, _F, _G, _H, _I, _J, _K, _L, _M, _N, _O, _P, _Q, _R, _S, _T, _U, _V, _W, _X, _Y, _Z, __;
739
794
  const [isMappingDisplayed, setIsMappingDisplayed] = useState(false);
740
795
  const [isDeleteModalOpen, setIsDeleteModalOpen] = useState(false);
741
796
  const [isSyncing, setIsSyncing] = useState(null);
@@ -790,26 +845,35 @@ const SingleMappingDashboardItem = ({
790
845
  typeof ((_f = field == null ? void 0 : field.configurationFields) == null ? void 0 : _f.spreadsheet) === "object" ? (_i = (_h = (_g = field == null ? void 0 : field.configurationFields) == null ? void 0 : _g.spreadsheet) == null ? void 0 : _h.value) == null ? void 0 : _i.label : (_k = (_j = field == null ? void 0 : field.configurationFields) == null ? void 0 : _j.spreadsheet) == null ? void 0 : _k.value
791
846
  )) : null))
792
847
  ),
793
- /* @__PURE__ */ React__default.createElement(Flex, { alignItems: "center", gap: "$12" }, /* @__PURE__ */ React__default.createElement(Tooltip, { content: "Sync", className: "dm-sans" }, /* @__PURE__ */ React__default.createElement(Button, { variant: "ghost", size: "lg", color: "default", css: {
794
- width: "40px !important",
795
- height: "40px !important",
796
- marginInlineEnd: "$3"
797
- } }, /* @__PURE__ */ React__default.createElement(
798
- Flex,
848
+ /* @__PURE__ */ React__default.createElement(Flex, { alignItems: "center", gap: "$12" }, /* @__PURE__ */ React__default.createElement(Tooltip, { content: "Sync", className: "dm-sans" }, /* @__PURE__ */ React__default.createElement(
849
+ Button,
799
850
  {
800
- className: `rotating-div ${isSyncing === field.id ? "rotate" : ""}`,
801
- justifyContent: "center",
802
- alignItems: "center",
803
- onClick: async () => {
804
- setIsSyncing(field.id);
805
- setTimeout(async () => {
806
- await (syncMapping == null ? void 0 : syncMapping(field.id));
807
- setIsSyncing(null);
808
- }, 2e3);
851
+ variant: "ghost",
852
+ size: "lg",
853
+ color: "default",
854
+ css: {
855
+ width: "40px !important",
856
+ height: "40px !important",
857
+ marginInlineEnd: "$3"
809
858
  }
810
859
  },
811
- /* @__PURE__ */ React__default.createElement(Sync, null)
812
- ))), (() => (field == null ? void 0 : field.isEnabled) !== null && (field == null ? void 0 : field.isEnabled) !== void 0)() ? /* @__PURE__ */ React__default.createElement(
860
+ /* @__PURE__ */ React__default.createElement(
861
+ Flex,
862
+ {
863
+ className: `rotating-div ${isSyncing === field.id ? "rotate" : ""}`,
864
+ justifyContent: "center",
865
+ alignItems: "center",
866
+ onClick: async () => {
867
+ setIsSyncing(field.id);
868
+ setTimeout(async () => {
869
+ await (syncMapping == null ? void 0 : syncMapping(field.id));
870
+ setIsSyncing(null);
871
+ }, 2e3);
872
+ }
873
+ },
874
+ /* @__PURE__ */ React__default.createElement(Sync, null)
875
+ )
876
+ )), (() => (field == null ? void 0 : field.isEnabled) !== null && (field == null ? void 0 : field.isEnabled) !== void 0)() ? /* @__PURE__ */ React__default.createElement(
813
877
  Box,
814
878
  {
815
879
  css: {
@@ -891,76 +955,58 @@ const SingleMappingDashboardItem = ({
891
955
  }
892
956
  },
893
957
  /* @__PURE__ */ React__default.createElement(SingleMappingEventWrapper, { field }),
894
- !!((_m = (_l = field == null ? void 0 : field.mappedFields) == null ? void 0 : _l.questions) == null ? void 0 : _m.filter(
895
- (question) => question.isEnabled
896
- ).length) ? /* @__PURE__ */ React__default.createElement(
958
+ !!((_o = (_n = (_m = (_l = field == null ? void 0 : field.mappedFields) == null ? void 0 : _l.questions) == null ? void 0 : _m.filter) == null ? void 0 : _n.call(_m, (question) => question.isEnabled)) == null ? void 0 : _o.length) ? /* @__PURE__ */ React__default.createElement(
897
959
  SingleMappingChipWrapper,
898
960
  {
899
961
  heading: "Questions",
900
- fields: (_o = (_n = field == null ? void 0 : field.mappedFields) == null ? void 0 : _n.questions) == null ? void 0 : _o.filter(
901
- (question) => question.isEnabled
902
- ),
962
+ fields: (_r = (_q = (_p = field == null ? void 0 : field.mappedFields) == null ? void 0 : _p.questions) == null ? void 0 : _q.filter) == null ? void 0 : _r.call(_q, (question) => question.isEnabled),
903
963
  backgroundColor: "#E5F2FF"
904
964
  }
905
965
  ) : null,
906
- !!((_q = (_p = field == null ? void 0 : field.mappedFields) == null ? void 0 : _p.derivedQuestions) == null ? void 0 : _q.filter(
966
+ !!((_v = (_u = (_t = (_s = field == null ? void 0 : field.mappedFields) == null ? void 0 : _s.derivedQuestions) == null ? void 0 : _t.filter) == null ? void 0 : _u.call(
967
+ _t,
907
968
  (derivedQuestion) => derivedQuestion.isEnabled
908
- ).length) ? /* @__PURE__ */ React__default.createElement(
969
+ )) == null ? void 0 : _v.length) ? /* @__PURE__ */ React__default.createElement(
909
970
  SingleMappingChipWrapper,
910
971
  {
911
- heading: "Derived Questions",
912
- fields: (_s = (_r = field == null ? void 0 : field.mappedFields) == null ? void 0 : _r.derivedQuestions) == null ? void 0 : _s.filter(
972
+ heading: "Enriched Columns",
973
+ fields: (_y = (_x = (_w = field == null ? void 0 : field.mappedFields) == null ? void 0 : _w.derivedQuestions) == null ? void 0 : _x.filter) == null ? void 0 : _y.call(
974
+ _x,
913
975
  (derivedQuestion) => derivedQuestion.isEnabled
914
976
  ),
915
977
  backgroundColor: "#E5F2FF"
916
978
  }
917
979
  ) : null,
918
- !!((_u = (_t = field == null ? void 0 : field.mappedFields) == null ? void 0 : _t.variables) == null ? void 0 : _u.filter(
919
- (variable) => variable.isEnabled
920
- ).length) ? /* @__PURE__ */ React__default.createElement(
980
+ !!((_C = (_B = (_A = (_z = field == null ? void 0 : field.mappedFields) == null ? void 0 : _z.variables) == null ? void 0 : _A.filter) == null ? void 0 : _B.call(_A, (variable) => variable.isEnabled)) == null ? void 0 : _C.length) ? /* @__PURE__ */ React__default.createElement(
921
981
  SingleMappingChipWrapper,
922
982
  {
923
983
  heading: "Variables",
924
- fields: (_w = (_v = field == null ? void 0 : field.mappedFields) == null ? void 0 : _v.variables) == null ? void 0 : _w.filter(
925
- (variable) => variable.isEnabled
926
- ),
984
+ fields: (_F = (_E = (_D = field == null ? void 0 : field.mappedFields) == null ? void 0 : _D.variables) == null ? void 0 : _E.filter) == null ? void 0 : _F.call(_E, (variable) => variable.isEnabled),
927
985
  backgroundColor: "$positive100"
928
986
  }
929
987
  ) : null,
930
- !!((_y = (_x = field == null ? void 0 : field.mappedFields) == null ? void 0 : _x.contactProperties) == null ? void 0 : _y.filter(
931
- (property) => property.isEnabled
932
- ).length) ? /* @__PURE__ */ React__default.createElement(
988
+ !!((_J = (_I = (_H = (_G = field == null ? void 0 : field.mappedFields) == null ? void 0 : _G.contactProperties) == null ? void 0 : _H.filter) == null ? void 0 : _I.call(_H, (property) => property.isEnabled)) == null ? void 0 : _J.length) ? /* @__PURE__ */ React__default.createElement(
933
989
  SingleMappingChipWrapper,
934
990
  {
935
991
  heading: "Contacts",
936
- fields: (_A = (_z = field == null ? void 0 : field.mappedFields) == null ? void 0 : _z.contactProperties) == null ? void 0 : _A.filter(
937
- (property) => property.isEnabled
938
- ),
992
+ fields: (_M = (_L = (_K = field == null ? void 0 : field.mappedFields) == null ? void 0 : _K.contactProperties) == null ? void 0 : _L.filter) == null ? void 0 : _M.call(_L, (property) => property.isEnabled),
939
993
  backgroundColor: "$negative100"
940
994
  }
941
995
  ) : null,
942
- !!((_C = (_B = field == null ? void 0 : field.mappedFields) == null ? void 0 : _B.expressions) == null ? void 0 : _C.filter(
943
- (expression) => expression.isEnabled
944
- ).length) ? /* @__PURE__ */ React__default.createElement(
996
+ !!((_Q = (_P = (_O = (_N = field == null ? void 0 : field.mappedFields) == null ? void 0 : _N.expressions) == null ? void 0 : _O.filter) == null ? void 0 : _P.call(_O, (expression) => expression.isEnabled)) == null ? void 0 : _Q.length) ? /* @__PURE__ */ React__default.createElement(
945
997
  SingleMappingChipWrapper,
946
998
  {
947
999
  heading: "Expression",
948
1000
  backgroundColor: "$neutral100",
949
- fields: (_E = (_D = field == null ? void 0 : field.mappedFields) == null ? void 0 : _D.expressions) == null ? void 0 : _E.filter(
950
- (expression) => expression.isEnabled
951
- )
1001
+ fields: (_T = (_S = (_R = field == null ? void 0 : field.mappedFields) == null ? void 0 : _R.expressions) == null ? void 0 : _S.filter) == null ? void 0 : _T.call(_S, (expression) => expression.isEnabled)
952
1002
  }
953
1003
  ) : null,
954
- !!((_G = (_F = field == null ? void 0 : field.mappedFields) == null ? void 0 : _F.property) == null ? void 0 : _G.filter(
955
- (property) => property.isEnabled
956
- ).length) ? /* @__PURE__ */ React__default.createElement(
1004
+ !!((_X = (_W = (_V = (_U = field == null ? void 0 : field.mappedFields) == null ? void 0 : _U.property) == null ? void 0 : _V.filter) == null ? void 0 : _W.call(_V, (property) => property.isEnabled)) == null ? void 0 : _X.length) ? /* @__PURE__ */ React__default.createElement(
957
1005
  SingleMappingChipWrapper,
958
1006
  {
959
1007
  heading: "Property",
960
1008
  hideBorder: true,
961
- fields: (_I = (_H = field == null ? void 0 : field.mappedFields) == null ? void 0 : _H.property) == null ? void 0 : _I.filter(
962
- (property) => property.isEnabled
963
- ),
1009
+ fields: (__ = (_Z = (_Y = field == null ? void 0 : field.mappedFields) == null ? void 0 : _Y.property) == null ? void 0 : _Z.filter) == null ? void 0 : __.call(_Z, (property) => property.isEnabled),
964
1010
  backgroundColor: "rgba(74, 156, 166, 0.15)"
965
1011
  }
966
1012
  ) : null
@@ -1055,10 +1101,7 @@ const SingleMappingEventWrapper = ({
1055
1101
  EventComponent,
1056
1102
  {
1057
1103
  heading: "Object:",
1058
- description: (_p = (_o = (_n = (_m = field == null ? void 0 : field.configurationFields) == null ? void 0 : _m.object) == null ? void 0 : _n.value) == null ? void 0 : _o.label) == null ? void 0 : _p.replace(
1059
- /^./,
1060
- (char) => char == null ? void 0 : char.toUpperCase()
1061
- )
1104
+ description: (_p = (_o = (_n = (_m = field == null ? void 0 : field.configurationFields) == null ? void 0 : _m.object) == null ? void 0 : _n.value) == null ? void 0 : _o.label) == null ? void 0 : _p.replace(/^./, (char) => char == null ? void 0 : char.toUpperCase())
1062
1105
  }
1063
1106
  ) : null, !!((_r = (_q = field == null ? void 0 : field.configurationFields) == null ? void 0 : _q.action) == null ? void 0 : _r.hasAction) ? /* @__PURE__ */ React__default.createElement(
1064
1107
  EventComponent,
@@ -1093,7 +1136,7 @@ const SingleMappingChipWrapper = ({
1093
1136
  placeholder,
1094
1137
  backgroundColor
1095
1138
  }) => {
1096
- const modifiedFields = Object.values(fields).filter(
1139
+ const modifiedFields = fields.filter(
1097
1140
  (field) => field.id !== "ALL"
1098
1141
  );
1099
1142
  return /* @__PURE__ */ React__default.createElement(React__default.Fragment, null, /* @__PURE__ */ React__default.createElement(Flex, { flexDirection: "column", gap: "$6", css: { paddingBlock: "$8" } }, /* @__PURE__ */ React__default.createElement(Text, { size: "sm", weight: "bold", css: { textTransform: "uppercase" } }, heading), /* @__PURE__ */ React__default.createElement(
@@ -1103,7 +1146,10 @@ const SingleMappingChipWrapper = ({
1103
1146
  css: {
1104
1147
  columnGap: "$2",
1105
1148
  rowGap: "$4",
1106
- "& > * ": { fontFamily: "'Roboto Mono', monospace !important", fontWeight: "$4 !important" }
1149
+ "& > * ": {
1150
+ fontFamily: "'Roboto Mono', monospace !important",
1151
+ fontWeight: "$4 !important"
1152
+ }
1107
1153
  }
1108
1154
  },
1109
1155
  modifiedFields.map((field) => {
@@ -1183,7 +1229,7 @@ const DashboardItem = ({
1183
1229
  break;
1184
1230
  }
1185
1231
  default: {
1186
- field = (_a = defaultValue == null ? void 0 : defaultValue.value) == null ? void 0 : _a.label;
1232
+ field = ((_a = defaultValue == null ? void 0 : defaultValue.value) == null ? void 0 : _a.label) || "--";
1187
1233
  break;
1188
1234
  }
1189
1235
  }