@livechat/platform-workflows 0.0.92 → 0.0.93

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.js CHANGED
@@ -12646,7 +12646,7 @@ var getWorkflowTemplates = () => [
12646
12646
  var import_react14 = require("react");
12647
12647
  var import_react_router_dom4 = require("react-router-dom");
12648
12648
  var import_design_system_react_components4 = require("@livechat/design-system-react-components");
12649
- var import_developer_studio_api21 = require("@livechat/developer-studio-api");
12649
+ var import_developer_studio_api20 = require("@livechat/developer-studio-api");
12650
12650
  var import_developer_studio_ui_react7 = require("@livechat/developer-studio-ui-react");
12651
12651
 
12652
12652
  // src/utils/json.ts
@@ -13099,7 +13099,7 @@ var import_react12 = require("react");
13099
13099
  var import_react_router_dom3 = require("react-router-dom");
13100
13100
  var import_reactflow = require("reactflow");
13101
13101
  var import_lodash = __toESM(require("lodash.debounce"));
13102
- var import_developer_studio_api20 = require("@livechat/developer-studio-api");
13102
+ var import_developer_studio_api19 = require("@livechat/developer-studio-api");
13103
13103
  var import_developer_studio_ui_react5 = require("@livechat/developer-studio-ui-react");
13104
13104
 
13105
13105
  // src/views/Workflows/Common/One/contexts/OneMessagesContext.tsx
@@ -14250,8 +14250,35 @@ function useWorkflowState(workflow, options) {
14250
14250
  };
14251
14251
  }
14252
14252
 
14253
+ // ../../private/utils/src/misc/merge-deep.ts
14254
+ function isObject(item) {
14255
+ return item !== null && typeof item === "object" && !Array.isArray(item);
14256
+ }
14257
+ function mergeDeep(target, source) {
14258
+ if (!isObject(target) || !isObject(source)) {
14259
+ return source;
14260
+ }
14261
+ const output = __spreadValues({}, target);
14262
+ Object.keys(source).forEach((key) => {
14263
+ if (isObject(source[key])) {
14264
+ if (!(key in target)) {
14265
+ output[key] = source[key];
14266
+ } else {
14267
+ output[key] = mergeDeep(
14268
+ target[key],
14269
+ source[key]
14270
+ );
14271
+ }
14272
+ } else if (Array.isArray(source[key])) {
14273
+ output[key] = [...source[key]];
14274
+ } else {
14275
+ output[key] = source[key];
14276
+ }
14277
+ });
14278
+ return output;
14279
+ }
14280
+
14253
14281
  // src/views/Workflows/Creator/Provider/utils.ts
14254
- var import_developer_studio_api19 = require("@livechat/developer-studio-api");
14255
14282
  function recursiveTaskReducer(tasks, reducer) {
14256
14283
  return tasks.reduce(
14257
14284
  (result, task2, taskIndex, allTasks) => {
@@ -14290,7 +14317,7 @@ function recursiveTaskReducer(tasks, reducer) {
14290
14317
  }
14291
14318
  var applyChange = (workflow, change) => {
14292
14319
  var _a, _b;
14293
- let changed = (0, import_developer_studio_api19.mergeDeep)(workflow, change);
14320
+ let changed = mergeDeep(workflow, change);
14294
14321
  const inputParameters = Array.from(
14295
14322
  new Set(
14296
14323
  (_b = (_a = jsonUtils.getMatchesInText(JSON.stringify(changed))) == null ? void 0 : _a.filter((x) => x.includes("workflow.input.") && !x.includes("body")).map((x) => x.replace("workflow.input.", "")).filter((x) => x.length > 0)) != null ? _b : []
@@ -14367,8 +14394,8 @@ function WorkflowCreatorProviderBase({
14367
14394
  setTimeout(() => {
14368
14395
  setSelection(() => {
14369
14396
  const isNotEditable = (params == null ? void 0 : params.kind) === "task" && [
14370
- import_developer_studio_api20.WorkflowDefinitionTaskType.forkJoin,
14371
- import_developer_studio_api20.WorkflowDefinitionTaskType.join
14397
+ import_developer_studio_api19.WorkflowDefinitionTaskType.forkJoin,
14398
+ import_developer_studio_api19.WorkflowDefinitionTaskType.join
14372
14399
  ].includes(params.id) || (params == null ? void 0 : params.kind) === "add-trigger" || (params == null ? void 0 : params.kind) === "trigger" && params.id === "manual_only";
14373
14400
  return params ? __spreadProps(__spreadValues({}, params), {
14374
14401
  isEditable: !isNotEditable
@@ -14507,7 +14534,7 @@ function WorkflowCreatorProviderBase({
14507
14534
  if (newTasks[0].type === NodeNames.forkJoin) {
14508
14535
  const systemTasks = systemTaskTemplates();
14509
14536
  newTasks[0].forkTasks = [[], []];
14510
- newTasks.push(__spreadProps(__spreadValues({}, systemTasks[import_developer_studio_api20.WorkflowDefinitionTaskType.join]), {
14537
+ newTasks.push(__spreadProps(__spreadValues({}, systemTasks[import_developer_studio_api19.WorkflowDefinitionTaskType.join]), {
14511
14538
  taskReferenceName: `join_${task2.taskReferenceName}_${existingTaskIndex ? Number(existingTaskIndex[1]) + 1 : 1}`
14512
14539
  }));
14513
14540
  }
@@ -15011,12 +15038,12 @@ function AddWorkflowTaskModal({ basePath, onClose }) {
15011
15038
  // },
15012
15039
  {
15013
15040
  name: "livechat",
15014
- displayName: import_developer_studio_api21.IntegrationDisplayNames.LiveChat,
15041
+ displayName: import_developer_studio_api20.IntegrationDisplayNames.LiveChat,
15015
15042
  icon: /* @__PURE__ */ jsx4(
15016
15043
  ProductIcon_default,
15017
15044
  {
15018
15045
  height: 5,
15019
- product: import_developer_studio_api21.IntegrationNames.LiveChat,
15046
+ product: import_developer_studio_api20.IntegrationNames.LiveChat,
15020
15047
  width: 5
15021
15048
  }
15022
15049
  ),
@@ -15029,13 +15056,13 @@ function AddWorkflowTaskModal({ basePath, onClose }) {
15029
15056
  },
15030
15057
  {
15031
15058
  name: "helpdesk",
15032
- displayName: import_developer_studio_api21.IntegrationDisplayNames.HelpDesk,
15059
+ displayName: import_developer_studio_api20.IntegrationDisplayNames.HelpDesk,
15033
15060
  icon: /* @__PURE__ */ jsx4(
15034
15061
  ProductIcon_default,
15035
15062
  {
15036
15063
  center: true,
15037
15064
  height: 5,
15038
- product: import_developer_studio_api21.IntegrationNames.HelpDesk,
15065
+ product: import_developer_studio_api20.IntegrationNames.HelpDesk,
15039
15066
  width: 5
15040
15067
  }
15041
15068
  ),
@@ -15047,9 +15074,9 @@ function AddWorkflowTaskModal({ basePath, onClose }) {
15047
15074
  }))
15048
15075
  },
15049
15076
  {
15050
- name: import_developer_studio_api21.IntegrationNames.OpenAI,
15051
- displayName: import_developer_studio_api21.IntegrationDisplayNames.OpenAI,
15052
- icon: /* @__PURE__ */ jsx4(ProductIcon_default, { height: 5, product: import_developer_studio_api21.IntegrationNames.OpenAI, width: 5 }),
15077
+ name: import_developer_studio_api20.IntegrationNames.OpenAI,
15078
+ displayName: import_developer_studio_api20.IntegrationDisplayNames.OpenAI,
15079
+ icon: /* @__PURE__ */ jsx4(ProductIcon_default, { height: 5, product: import_developer_studio_api20.IntegrationNames.OpenAI, width: 5 }),
15053
15080
  values: Object.values(openAiTaskConfigs()).map((x) => ({
15054
15081
  key: x.key,
15055
15082
  name: x.customization.displayName,
@@ -15058,13 +15085,13 @@ function AddWorkflowTaskModal({ basePath, onClose }) {
15058
15085
  }))
15059
15086
  },
15060
15087
  {
15061
- name: import_developer_studio_api21.IntegrationNames.Mailchimp,
15062
- displayName: import_developer_studio_api21.IntegrationDisplayNames.Mailchimp,
15088
+ name: import_developer_studio_api20.IntegrationNames.Mailchimp,
15089
+ displayName: import_developer_studio_api20.IntegrationDisplayNames.Mailchimp,
15063
15090
  icon: /* @__PURE__ */ jsx4(
15064
15091
  ProductIcon_default,
15065
15092
  {
15066
15093
  height: 5,
15067
- product: import_developer_studio_api21.IntegrationNames.Mailchimp,
15094
+ product: import_developer_studio_api20.IntegrationNames.Mailchimp,
15068
15095
  width: 5
15069
15096
  }
15070
15097
  ),
@@ -15076,13 +15103,13 @@ function AddWorkflowTaskModal({ basePath, onClose }) {
15076
15103
  }))
15077
15104
  },
15078
15105
  {
15079
- name: import_developer_studio_api21.IntegrationNames.HubSpot,
15080
- displayName: import_developer_studio_api21.IntegrationDisplayNames.HubSpot,
15106
+ name: import_developer_studio_api20.IntegrationNames.HubSpot,
15107
+ displayName: import_developer_studio_api20.IntegrationDisplayNames.HubSpot,
15081
15108
  icon: /* @__PURE__ */ jsx4(
15082
15109
  ProductIcon_default,
15083
15110
  {
15084
15111
  height: 5,
15085
- product: import_developer_studio_api21.IntegrationNames.HubSpot,
15112
+ product: import_developer_studio_api20.IntegrationNames.HubSpot,
15086
15113
  width: 5
15087
15114
  }
15088
15115
  ),
@@ -15094,13 +15121,13 @@ function AddWorkflowTaskModal({ basePath, onClose }) {
15094
15121
  }))
15095
15122
  },
15096
15123
  {
15097
- name: import_developer_studio_api21.IntegrationNames.BigCommerce,
15098
- displayName: import_developer_studio_api21.IntegrationDisplayNames.BigCommerce,
15124
+ name: import_developer_studio_api20.IntegrationNames.BigCommerce,
15125
+ displayName: import_developer_studio_api20.IntegrationDisplayNames.BigCommerce,
15099
15126
  icon: /* @__PURE__ */ jsx4(
15100
15127
  ProductIcon_default,
15101
15128
  {
15102
15129
  height: 5,
15103
- product: import_developer_studio_api21.IntegrationNames.BigCommerce,
15130
+ product: import_developer_studio_api20.IntegrationNames.BigCommerce,
15104
15131
  width: 5
15105
15132
  }
15106
15133
  ),
@@ -15112,13 +15139,13 @@ function AddWorkflowTaskModal({ basePath, onClose }) {
15112
15139
  }))
15113
15140
  },
15114
15141
  {
15115
- name: import_developer_studio_api21.IntegrationNames.Shopify,
15116
- displayName: import_developer_studio_api21.IntegrationDisplayNames.Shopify,
15142
+ name: import_developer_studio_api20.IntegrationNames.Shopify,
15143
+ displayName: import_developer_studio_api20.IntegrationDisplayNames.Shopify,
15117
15144
  icon: /* @__PURE__ */ jsx4(
15118
15145
  ProductIcon_default,
15119
15146
  {
15120
15147
  height: 5,
15121
- product: import_developer_studio_api21.IntegrationNames.Shopify,
15148
+ product: import_developer_studio_api20.IntegrationNames.Shopify,
15122
15149
  width: 5
15123
15150
  }
15124
15151
  ),
@@ -15260,7 +15287,7 @@ function AddWorkflowTaskModal({ basePath, onClose }) {
15260
15287
  }
15261
15288
  ),
15262
15289
  config2.map(({ name, displayName, icon: icon2, values }) => {
15263
- const revertIconColor = getWorkflowsEnv("isHeadless") && (name === import_developer_studio_api21.IntegrationNames.OpenAI || name === import_developer_studio_api21.IntegrationNames.BigCommerce);
15290
+ const revertIconColor = getWorkflowsEnv("isHeadless") && (name === import_developer_studio_api20.IntegrationNames.OpenAI || name === import_developer_studio_api20.IntegrationNames.BigCommerce);
15264
15291
  if (search) {
15265
15292
  if (values.some(
15266
15293
  (el) => el.name.toLowerCase().includes(search.toLowerCase())
@@ -15381,7 +15408,7 @@ var Modal_default = AddWorkflowTaskModal;
15381
15408
  var import_react17 = require("react");
15382
15409
  var import_react_router_dom5 = require("react-router-dom");
15383
15410
  var import_design_system_react_components6 = require("@livechat/design-system-react-components");
15384
- var import_developer_studio_api22 = require("@livechat/developer-studio-api");
15411
+ var import_developer_studio_api21 = require("@livechat/developer-studio-api");
15385
15412
  var import_developer_studio_ui_react9 = require("@livechat/developer-studio-ui-react");
15386
15413
 
15387
15414
  // src/views/Workflows/Creator/Modals/AddTrigger/Options.tsx
@@ -15506,12 +15533,12 @@ function AddWorkflowTriggerModal({
15506
15533
  },
15507
15534
  {
15508
15535
  name: "livechat",
15509
- displayName: import_developer_studio_api22.IntegrationDisplayNames.LiveChat,
15536
+ displayName: import_developer_studio_api21.IntegrationDisplayNames.LiveChat,
15510
15537
  icon: /* @__PURE__ */ jsx4(
15511
15538
  ProductIcon_default,
15512
15539
  {
15513
15540
  height: 5,
15514
- product: import_developer_studio_api22.IntegrationNames.LiveChat,
15541
+ product: import_developer_studio_api21.IntegrationNames.LiveChat,
15515
15542
  width: 5
15516
15543
  }
15517
15544
  ),
@@ -15523,12 +15550,12 @@ function AddWorkflowTriggerModal({
15523
15550
  },
15524
15551
  {
15525
15552
  name: "helpdesk",
15526
- displayName: import_developer_studio_api22.IntegrationDisplayNames.HelpDesk,
15553
+ displayName: import_developer_studio_api21.IntegrationDisplayNames.HelpDesk,
15527
15554
  icon: /* @__PURE__ */ jsx4(
15528
15555
  ProductIcon_default,
15529
15556
  {
15530
15557
  height: 5,
15531
- product: import_developer_studio_api22.IntegrationNames.HelpDesk,
15558
+ product: import_developer_studio_api21.IntegrationNames.HelpDesk,
15532
15559
  width: 5
15533
15560
  }
15534
15561
  ),
@@ -15539,13 +15566,13 @@ function AddWorkflowTriggerModal({
15539
15566
  }))
15540
15567
  },
15541
15568
  {
15542
- name: import_developer_studio_api22.IntegrationNames.Mailchimp,
15543
- displayName: import_developer_studio_api22.IntegrationDisplayNames.Mailchimp,
15569
+ name: import_developer_studio_api21.IntegrationNames.Mailchimp,
15570
+ displayName: import_developer_studio_api21.IntegrationDisplayNames.Mailchimp,
15544
15571
  icon: /* @__PURE__ */ jsx4(
15545
15572
  ProductIcon_default,
15546
15573
  {
15547
15574
  height: 5,
15548
- product: import_developer_studio_api22.IntegrationNames.Mailchimp,
15575
+ product: import_developer_studio_api21.IntegrationNames.Mailchimp,
15549
15576
  width: 5
15550
15577
  }
15551
15578
  ),
@@ -15556,13 +15583,13 @@ function AddWorkflowTriggerModal({
15556
15583
  }))
15557
15584
  },
15558
15585
  {
15559
- name: import_developer_studio_api22.IntegrationNames.Shopify,
15560
- displayName: import_developer_studio_api22.IntegrationDisplayNames.Shopify,
15586
+ name: import_developer_studio_api21.IntegrationNames.Shopify,
15587
+ displayName: import_developer_studio_api21.IntegrationDisplayNames.Shopify,
15561
15588
  icon: /* @__PURE__ */ jsx4(
15562
15589
  ProductIcon_default,
15563
15590
  {
15564
15591
  height: 5,
15565
- product: import_developer_studio_api22.IntegrationNames.Shopify,
15592
+ product: import_developer_studio_api21.IntegrationNames.Shopify,
15566
15593
  width: 5
15567
15594
  }
15568
15595
  ),
@@ -15573,13 +15600,13 @@ function AddWorkflowTriggerModal({
15573
15600
  }))
15574
15601
  },
15575
15602
  {
15576
- name: import_developer_studio_api22.IntegrationNames.HubSpot,
15577
- displayName: import_developer_studio_api22.IntegrationDisplayNames.HubSpot,
15603
+ name: import_developer_studio_api21.IntegrationNames.HubSpot,
15604
+ displayName: import_developer_studio_api21.IntegrationDisplayNames.HubSpot,
15578
15605
  icon: /* @__PURE__ */ jsx4(
15579
15606
  ProductIcon_default,
15580
15607
  {
15581
15608
  height: 5,
15582
- product: import_developer_studio_api22.IntegrationNames.HubSpot,
15609
+ product: import_developer_studio_api21.IntegrationNames.HubSpot,
15583
15610
  width: 5
15584
15611
  }
15585
15612
  ),
@@ -15590,13 +15617,13 @@ function AddWorkflowTriggerModal({
15590
15617
  }))
15591
15618
  },
15592
15619
  {
15593
- name: import_developer_studio_api22.IntegrationNames.BigCommerce,
15594
- displayName: import_developer_studio_api22.IntegrationDisplayNames.BigCommerce,
15620
+ name: import_developer_studio_api21.IntegrationNames.BigCommerce,
15621
+ displayName: import_developer_studio_api21.IntegrationDisplayNames.BigCommerce,
15595
15622
  icon: /* @__PURE__ */ jsx4(
15596
15623
  ProductIcon_default,
15597
15624
  {
15598
15625
  height: 5,
15599
- product: import_developer_studio_api22.IntegrationNames.BigCommerce,
15626
+ product: import_developer_studio_api21.IntegrationNames.BigCommerce,
15600
15627
  width: 5
15601
15628
  }
15602
15629
  ),
@@ -15697,7 +15724,7 @@ function AddWorkflowTriggerModal({
15697
15724
  }
15698
15725
  ),
15699
15726
  config2.map(({ name, displayName, icon: icon2, values }) => {
15700
- const revertIconColor = getWorkflowsEnv("isHeadless") && (name === import_developer_studio_api22.IntegrationNames.OpenAI || name === import_developer_studio_api22.IntegrationNames.BigCommerce);
15727
+ const revertIconColor = getWorkflowsEnv("isHeadless") && (name === import_developer_studio_api21.IntegrationNames.OpenAI || name === import_developer_studio_api21.IntegrationNames.BigCommerce);
15701
15728
  if (search) {
15702
15729
  if (values.some(
15703
15730
  (el) => el.name.toLowerCase().includes(search.toLowerCase())
@@ -17944,10 +17971,10 @@ function CustomMoveDownButton(props) {
17944
17971
  }
17945
17972
 
17946
17973
  // src/views/Workflows/Creator/Builder/Forms/Schema/overrides/Templates/CustomArrayFieldTemplate.tsx
17947
- var import_utils16 = require("@rjsf/utils");
17974
+ var import_utils17 = require("@rjsf/utils");
17948
17975
 
17949
17976
  // src/views/Workflows/Creator/Builder/Forms/Schema/overrides/Templates/Other/CustomArrayFieldHeader.tsx
17950
- var import_utils15 = require("@rjsf/utils");
17977
+ var import_utils16 = require("@rjsf/utils");
17951
17978
  var import_design_system_react_components22 = require("@livechat/design-system-react-components");
17952
17979
  var import_developer_studio_ui_react17 = require("@livechat/developer-studio-ui-react");
17953
17980
  function CustomArrayFieldHeader(props) {
@@ -17961,9 +17988,9 @@ function CustomArrayFieldHeader(props) {
17961
17988
  uiSchema,
17962
17989
  hideOptionalBadge
17963
17990
  } = props;
17964
- const options = (0, import_utils15.getUiOptions)(uiSchema);
17965
- const ArrayFieldTitleTemplate = (0, import_utils15.getTemplate)("ArrayFieldTitleTemplate", registry, options);
17966
- const ArrayFieldDescriptionTemplate = (0, import_utils15.getTemplate)("ArrayFieldDescriptionTemplate", registry, options);
17991
+ const options = (0, import_utils16.getUiOptions)(uiSchema);
17992
+ const ArrayFieldTitleTemplate = (0, import_utils16.getTemplate)("ArrayFieldTitleTemplate", registry, options);
17993
+ const ArrayFieldDescriptionTemplate = (0, import_utils16.getTemplate)("ArrayFieldDescriptionTemplate", registry, options);
17967
17994
  return /* @__PURE__ */ jsx4(import_developer_studio_ui_react17.Row, { noWrap: true, notPadded: true, spaceBetween: true, children: /* @__PURE__ */ jsxs2(
17968
17995
  import_developer_studio_ui_react17.Row,
17969
17996
  {
@@ -18025,8 +18052,8 @@ function CustomArrayFieldTemplate(props) {
18025
18052
  schema,
18026
18053
  title
18027
18054
  } = props;
18028
- const uiOptions = (0, import_utils16.getUiOptions)(uiSchema);
18029
- const ArrayFieldItemTemplate = (0, import_utils16.getTemplate)(
18055
+ const uiOptions = (0, import_utils17.getUiOptions)(uiSchema);
18056
+ const ArrayFieldItemTemplate = (0, import_utils17.getTemplate)(
18030
18057
  "ArrayFieldItemTemplate",
18031
18058
  registry,
18032
18059
  uiOptions
@@ -18104,11 +18131,11 @@ function CustomDescriptionFieldTemplate(props) {
18104
18131
  }
18105
18132
 
18106
18133
  // src/views/Workflows/Creator/Builder/Forms/Schema/overrides/Templates/CustomField.tsx
18107
- var import_utils18 = require("@rjsf/utils");
18134
+ var import_utils19 = require("@rjsf/utils");
18108
18135
  var import_design_system_react_components25 = require("@livechat/design-system-react-components");
18109
18136
 
18110
18137
  // src/views/Workflows/Creator/Builder/Forms/Schema/overrides/Templates/Other/CustomFieldHeader.tsx
18111
- var import_utils17 = require("@rjsf/utils");
18138
+ var import_utils18 = require("@rjsf/utils");
18112
18139
  var import_design_system_react_components24 = require("@livechat/design-system-react-components");
18113
18140
  var import_developer_studio_ui_react18 = require("@livechat/developer-studio-ui-react");
18114
18141
  var OptionalWrapper = newStyled.div`
@@ -18128,13 +18155,13 @@ function CustomFieldHeader(props) {
18128
18155
  uiSchema,
18129
18156
  hideOptionalBadge
18130
18157
  } = props;
18131
- const options = (0, import_utils17.getUiOptions)(uiSchema);
18132
- const TitleFieldTemplate = (0, import_utils17.getTemplate)(
18158
+ const options = (0, import_utils18.getUiOptions)(uiSchema);
18159
+ const TitleFieldTemplate = (0, import_utils18.getTemplate)(
18133
18160
  "TitleFieldTemplate",
18134
18161
  registry,
18135
18162
  options
18136
18163
  );
18137
- const DescriptionFieldTemplate = (0, import_utils17.getTemplate)("DescriptionFieldTemplate", registry, options);
18164
+ const DescriptionFieldTemplate = (0, import_utils18.getTemplate)("DescriptionFieldTemplate", registry, options);
18138
18165
  return /* @__PURE__ */ jsxs2(import_developer_studio_ui_react18.Row, { noWrap: true, notPadded: true, spaceBetween: true, children: [
18139
18166
  /* @__PURE__ */ jsxs2(
18140
18167
  import_developer_studio_ui_react18.Row,
@@ -18146,7 +18173,7 @@ function CustomFieldHeader(props) {
18146
18173
  label ? /* @__PURE__ */ jsx4(
18147
18174
  TitleFieldTemplate,
18148
18175
  {
18149
- id: (0, import_utils17.titleId)(id),
18176
+ id: (0, import_utils18.titleId)(id),
18150
18177
  registry,
18151
18178
  required,
18152
18179
  schema,
@@ -18158,7 +18185,7 @@ function CustomFieldHeader(props) {
18158
18185
  DescriptionFieldTemplate,
18159
18186
  {
18160
18187
  description,
18161
- id: (0, import_utils17.descriptionId)(id),
18188
+ id: (0, import_utils18.descriptionId)(id),
18162
18189
  registry,
18163
18190
  schema,
18164
18191
  uiSchema
@@ -18208,9 +18235,9 @@ function CustomFieldTemplate(props) {
18208
18235
  "schema",
18209
18236
  "uiSchema"
18210
18237
  ]);
18211
- const options = (0, import_utils18.getUiOptions)(uiSchema);
18212
- const additional = import_utils18.ADDITIONAL_PROPERTY_FLAG in props.schema;
18213
- const WrapIfAdditionalTemplate = (0, import_utils18.getTemplate)(
18238
+ const options = (0, import_utils19.getUiOptions)(uiSchema);
18239
+ const additional = import_utils19.ADDITIONAL_PROPERTY_FLAG in props.schema;
18240
+ const WrapIfAdditionalTemplate = (0, import_utils19.getTemplate)(
18214
18241
  "WrapIfAdditionalTemplate",
18215
18242
  registry,
18216
18243
  options
@@ -18261,7 +18288,7 @@ function CustomFieldTemplate(props) {
18261
18288
  }
18262
18289
 
18263
18290
  // src/views/Workflows/Creator/Builder/Forms/Schema/overrides/Templates/CustomFieldWrapper.tsx
18264
- var import_utils19 = require("@rjsf/utils");
18291
+ var import_utils20 = require("@rjsf/utils");
18265
18292
  var import_design_system_react_components26 = require("@livechat/design-system-react-components");
18266
18293
  function CustomWrapIfAdditionalTemplate(props) {
18267
18294
  const {
@@ -18276,7 +18303,7 @@ function CustomWrapIfAdditionalTemplate(props) {
18276
18303
  classNames,
18277
18304
  style
18278
18305
  } = props;
18279
- const additional = import_utils19.ADDITIONAL_PROPERTY_FLAG in schema;
18306
+ const additional = import_utils20.ADDITIONAL_PROPERTY_FLAG in schema;
18280
18307
  if (!additional) {
18281
18308
  return /* @__PURE__ */ jsx4("div", { className: classNames, style, children });
18282
18309
  }
@@ -18308,7 +18335,7 @@ function CustomWrapIfAdditionalTemplate(props) {
18308
18335
 
18309
18336
  // src/views/Workflows/Creator/Builder/Forms/Schema/overrides/Templates/CustomObjectField.tsx
18310
18337
  var import_react43 = require("react");
18311
- var import_utils20 = require("@rjsf/utils");
18338
+ var import_utils21 = require("@rjsf/utils");
18312
18339
  var import_design_system_react_components27 = require("@livechat/design-system-react-components");
18313
18340
  function CustomObjectFieldTemplate(props) {
18314
18341
  const {
@@ -18332,7 +18359,7 @@ function CustomObjectFieldTemplate(props) {
18332
18359
  const [touched, setTouched] = (0, import_react43.useState)({});
18333
18360
  const newProperties = properties.map((prop) => {
18334
18361
  return __spreadProps(__spreadValues({}, prop), {
18335
- hidden: !(touched[prop.name] || prop.content.props.required || prop.content.props.schema.visible || import_utils20.ADDITIONAL_PROPERTY_FLAG in prop.content.props.schema || (Array.isArray(prop.content.props.formData) ? prop.content.props.formData.length > 0 : prop.content.props.formData)),
18362
+ hidden: !(touched[prop.name] || prop.content.props.required || prop.content.props.schema.visible || import_utils21.ADDITIONAL_PROPERTY_FLAG in prop.content.props.schema || (Array.isArray(prop.content.props.formData) ? prop.content.props.formData.length > 0 : prop.content.props.formData)),
18336
18363
  content: __spreadProps(__spreadValues({}, prop.content), {
18337
18364
  props: __spreadProps(__spreadValues({}, prop.content.props), {
18338
18365
  onChange: (value, newErrorSchema, id) => {
@@ -18388,7 +18415,7 @@ function CustomObjectFieldTemplate(props) {
18388
18415
  )
18389
18416
  }
18390
18417
  ) : null,
18391
- (0, import_utils20.canExpand)(schema, uiSchema, formData) && /* @__PURE__ */ jsx4(
18418
+ (0, import_utils21.canExpand)(schema, uiSchema, formData) && /* @__PURE__ */ jsx4(
18392
18419
  "div",
18393
18420
  {
18394
18421
  style: {
@@ -18794,7 +18821,7 @@ var Node_default = (0, import_react47.memo)(ForkJoinNode);
18794
18821
  // src/views/Workflows/Creator/Builder/Nodes/CustomNodes/HttpNode/Base.tsx
18795
18822
  var import_design_system_icons15 = require("@livechat/design-system-icons");
18796
18823
  var import_design_system_react_components34 = require("@livechat/design-system-react-components");
18797
- var import_developer_studio_api23 = require("@livechat/developer-studio-api");
18824
+ var import_developer_studio_api22 = require("@livechat/developer-studio-api");
18798
18825
  var import_developer_studio_ui_react19 = require("@livechat/developer-studio-ui-react");
18799
18826
  var Node2 = newStyled.div`
18800
18827
  color: var(${import_design_system_react_components34.DesignToken.ContentBasicPrimary});
@@ -18846,7 +18873,7 @@ function HttpNodeBase({
18846
18873
  } = useWorkflowCreator();
18847
18874
  const frame = frames.tasks[data.taskReferenceName];
18848
18875
  const customization = (_b = (_a = frame == null ? void 0 : frame.__meta) == null ? void 0 : _a.config) == null ? void 0 : _b.customization;
18849
- const revertIconColor = getWorkflowsEnv("isHeadless") && ((customization == null ? void 0 : customization.provider) === import_developer_studio_api23.IntegrationNames.OpenAI || (customization == null ? void 0 : customization.provider) === import_developer_studio_api23.IntegrationNames.BigCommerce);
18876
+ const revertIconColor = getWorkflowsEnv("isHeadless") && ((customization == null ? void 0 : customization.provider) === import_developer_studio_api22.IntegrationNames.OpenAI || (customization == null ? void 0 : customization.provider) === import_developer_studio_api22.IntegrationNames.BigCommerce);
18850
18877
  return /* @__PURE__ */ jsxs2(
18851
18878
  Node2,
18852
18879
  {
@@ -18922,7 +18949,7 @@ var Base_default2 = HttpNodeBase;
18922
18949
  var import_react50 = require("react");
18923
18950
  var import_design_system_icons16 = require("@livechat/design-system-icons");
18924
18951
  var import_design_system_react_components36 = require("@livechat/design-system-react-components");
18925
- var import_developer_studio_api24 = require("@livechat/developer-studio-api");
18952
+ var import_developer_studio_api23 = require("@livechat/developer-studio-api");
18926
18953
  var import_platform_integrations5 = require("@livechat/platform-integrations");
18927
18954
 
18928
18955
  // src/views/Workflows/Creator/Builder/Forms/Schema/integrations/Text/index.tsx
@@ -19005,13 +19032,13 @@ var Text_default = GlobalAccounts;
19005
19032
 
19006
19033
  // src/views/Workflows/Creator/Builder/Forms/Schema/Wrapper.tsx
19007
19034
  var componentsMap = {
19008
- [import_developer_studio_api24.IntegrationNames.HelpDesk]: ({ product }) => /* @__PURE__ */ jsx4(Text_default, { product }),
19009
- [import_developer_studio_api24.IntegrationNames.LiveChat]: ({ product }) => /* @__PURE__ */ jsx4(Text_default, { product }),
19010
- [import_developer_studio_api24.IntegrationNames.Shopify]: () => /* @__PURE__ */ jsx4(import_platform_integrations5.ShopifyStatus, {}),
19011
- [import_developer_studio_api24.IntegrationNames.Mailchimp]: () => /* @__PURE__ */ jsx4(import_platform_integrations5.MailchimpStatus, {}),
19012
- [import_developer_studio_api24.IntegrationNames.BigCommerce]: () => /* @__PURE__ */ jsx4(import_platform_integrations5.BigCommerceStatus, {}),
19013
- [import_developer_studio_api24.IntegrationNames.HubSpot]: () => /* @__PURE__ */ jsx4(import_platform_integrations5.HubSpotStatus, {}),
19014
- [import_developer_studio_api24.IntegrationNames.OpenAI]: () => /* @__PURE__ */ jsx4(import_platform_integrations5.OpenaiStatus, {})
19035
+ [import_developer_studio_api23.IntegrationNames.HelpDesk]: ({ product }) => /* @__PURE__ */ jsx4(Text_default, { product }),
19036
+ [import_developer_studio_api23.IntegrationNames.LiveChat]: ({ product }) => /* @__PURE__ */ jsx4(Text_default, { product }),
19037
+ [import_developer_studio_api23.IntegrationNames.Shopify]: () => /* @__PURE__ */ jsx4(import_platform_integrations5.ShopifyStatus, {}),
19038
+ [import_developer_studio_api23.IntegrationNames.Mailchimp]: () => /* @__PURE__ */ jsx4(import_platform_integrations5.MailchimpStatus, {}),
19039
+ [import_developer_studio_api23.IntegrationNames.BigCommerce]: () => /* @__PURE__ */ jsx4(import_platform_integrations5.BigCommerceStatus, {}),
19040
+ [import_developer_studio_api23.IntegrationNames.HubSpot]: () => /* @__PURE__ */ jsx4(import_platform_integrations5.HubSpotStatus, {}),
19041
+ [import_developer_studio_api23.IntegrationNames.OpenAI]: () => /* @__PURE__ */ jsx4(import_platform_integrations5.OpenaiStatus, {})
19015
19042
  };
19016
19043
  function CustomSchemaFormWrapper({
19017
19044
  data,
@@ -19815,7 +19842,7 @@ var Node_default5 = (0, import_react58.memo)(TerminateNode);
19815
19842
 
19816
19843
  // src/views/Workflows/Creator/Builder/Nodes/CustomNodes/TriggerNode/Base.tsx
19817
19844
  var import_design_system_react_components41 = require("@livechat/design-system-react-components");
19818
- var import_developer_studio_api25 = require("@livechat/developer-studio-api");
19845
+ var import_developer_studio_api24 = require("@livechat/developer-studio-api");
19819
19846
  var import_developer_studio_ui_react22 = require("@livechat/developer-studio-ui-react");
19820
19847
  var Node6 = newStyled.div`
19821
19848
  color: var(${import_design_system_react_components41.DesignToken.ContentBasicPrimary});
@@ -19866,7 +19893,7 @@ function TriggerNodeBase({
19866
19893
  } = useWorkflowCreator();
19867
19894
  const frame = frames.trigger;
19868
19895
  const customization = (_a = frame == null ? void 0 : frame.__meta) == null ? void 0 : _a.config.customization;
19869
- const revertIconColor = getWorkflowsEnv("isHeadless") && ((customization == null ? void 0 : customization.provider) === import_developer_studio_api25.IntegrationNames.OpenAI || (customization == null ? void 0 : customization.provider) === import_developer_studio_api25.IntegrationNames.BigCommerce);
19896
+ const revertIconColor = getWorkflowsEnv("isHeadless") && ((customization == null ? void 0 : customization.provider) === import_developer_studio_api24.IntegrationNames.OpenAI || (customization == null ? void 0 : customization.provider) === import_developer_studio_api24.IntegrationNames.BigCommerce);
19870
19897
  return /* @__PURE__ */ jsxs2(
19871
19898
  Node6,
19872
19899
  {
@@ -22051,7 +22078,7 @@ var Edges_default = CustomEdge_default;
22051
22078
  var import_reactflow15 = require("reactflow");
22052
22079
  var import_elkjs = __toESM(require("elkjs"));
22053
22080
  var import_design_system_react_components61 = require("@livechat/design-system-react-components");
22054
- var import_developer_studio_api26 = require("@livechat/developer-studio-api");
22081
+ var import_developer_studio_api25 = require("@livechat/developer-studio-api");
22055
22082
  var elk = new import_elkjs.default({
22056
22083
  defaultLayoutOptions: {
22057
22084
  "elk.algorithm": "layered",
@@ -22108,9 +22135,9 @@ var convertToNodes = (tasks) => {
22108
22135
  );
22109
22136
  const { parentSource, parentTargets } = sourceAndTargets != null ? sourceAndTargets : {};
22110
22137
  switch (task2.type) {
22111
- case import_developer_studio_api26.WorkflowDefinitionTaskType.terminate:
22112
- case import_developer_studio_api26.WorkflowDefinitionTaskType.http:
22113
- case import_developer_studio_api26.WorkflowDefinitionTaskType.join:
22138
+ case import_developer_studio_api25.WorkflowDefinitionTaskType.terminate:
22139
+ case import_developer_studio_api25.WorkflowDefinitionTaskType.http:
22140
+ case import_developer_studio_api25.WorkflowDefinitionTaskType.join:
22114
22141
  nodes.push(
22115
22142
  buildNode(
22116
22143
  {
@@ -22129,7 +22156,7 @@ var convertToNodes = (tasks) => {
22129
22156
  )
22130
22157
  );
22131
22158
  return nodes;
22132
- case import_developer_studio_api26.WorkflowDefinitionTaskType.switch:
22159
+ case import_developer_studio_api25.WorkflowDefinitionTaskType.switch:
22133
22160
  nodes.push(
22134
22161
  buildNode(
22135
22162
  {
@@ -22196,7 +22223,7 @@ var convertToNodes = (tasks) => {
22196
22223
  }
22197
22224
  );
22198
22225
  return nodes;
22199
- case import_developer_studio_api26.WorkflowDefinitionTaskType.forkJoin:
22226
+ case import_developer_studio_api25.WorkflowDefinitionTaskType.forkJoin:
22200
22227
  nodes.push(
22201
22228
  buildNode(
22202
22229
  {
@@ -22751,7 +22778,7 @@ var import_developer_studio_ui_react31 = require("@livechat/developer-studio-ui-
22751
22778
  // src/views/Workflows/Creator/Panels/Details/Executions/List.tsx
22752
22779
  var import_design_system_icons28 = require("@livechat/design-system-icons");
22753
22780
  var import_design_system_react_components65 = require("@livechat/design-system-react-components");
22754
- var import_developer_studio_api27 = require("@livechat/developer-studio-api");
22781
+ var import_developer_studio_api26 = require("@livechat/developer-studio-api");
22755
22782
  var import_developer_studio_ui_react29 = require("@livechat/developer-studio-ui-react");
22756
22783
  var tableCss = css`
22757
22784
  font-size: 13px;
@@ -22787,12 +22814,12 @@ function WorkflowExecutionList({
22787
22814
  /* @__PURE__ */ jsx4("td", { children: /* @__PURE__ */ jsx4(
22788
22815
  import_design_system_react_components65.Tag,
22789
22816
  {
22790
- kind: execution.status === import_developer_studio_api27.WorkflowExecutionStatus.Completed ? "success" : "error",
22817
+ kind: execution.status === import_developer_studio_api26.WorkflowExecutionStatus.Completed ? "success" : "error",
22791
22818
  leftNode: /* @__PURE__ */ jsx4(
22792
22819
  import_design_system_react_components65.Icon,
22793
22820
  {
22794
22821
  size: "small",
22795
- source: execution.status === import_developer_studio_api27.WorkflowExecutionStatus.Completed ? import_design_system_icons28.CheckCircle : import_design_system_icons28.CloseCircle
22822
+ source: execution.status === import_developer_studio_api26.WorkflowExecutionStatus.Completed ? import_design_system_icons28.CheckCircle : import_design_system_icons28.CloseCircle
22796
22823
  }
22797
22824
  ),
22798
22825
  size: "small",
@@ -23113,7 +23140,7 @@ var Panel_default2 = WorkflowEditorPanel;
23113
23140
  // src/views/Workflows/Creator/Panels/Element/Panel.tsx
23114
23141
  var import_design_system_icons31 = require("@livechat/design-system-icons");
23115
23142
  var import_design_system_react_components69 = require("@livechat/design-system-react-components");
23116
- var import_developer_studio_api28 = require("@livechat/developer-studio-api");
23143
+ var import_developer_studio_api27 = require("@livechat/developer-studio-api");
23117
23144
  var import_developer_studio_ui_react33 = require("@livechat/developer-studio-ui-react");
23118
23145
  var import_styles4 = require("react-js-cron/dist/styles.css");
23119
23146
  var formCss = () => css`
@@ -23271,7 +23298,7 @@ function WorkflowElementPanel() {
23271
23298
  default:
23272
23299
  }
23273
23300
  };
23274
- const revertIconColor = getWorkflowsEnv("isHeadless") && ((config2 == null ? void 0 : config2.customization.provider) === import_developer_studio_api28.IntegrationNames.OpenAI || (config2 == null ? void 0 : config2.customization.provider) === import_developer_studio_api28.IntegrationNames.BigCommerce);
23301
+ const revertIconColor = getWorkflowsEnv("isHeadless") && ((config2 == null ? void 0 : config2.customization.provider) === import_developer_studio_api27.IntegrationNames.OpenAI || (config2 == null ? void 0 : config2.customization.provider) === import_developer_studio_api27.IntegrationNames.BigCommerce);
23275
23302
  return /* @__PURE__ */ jsxs2(
23276
23303
  Wrapper4,
23277
23304
  {
@@ -23831,15 +23858,15 @@ var import_developer_studio_ui_react37 = require("@livechat/developer-studio-ui-
23831
23858
  // src/views/Workflows/Common/Icons/TemplateCategoryIcon.tsx
23832
23859
  var import_design_system_icons33 = require("@livechat/design-system-icons");
23833
23860
  var import_design_system_react_components72 = require("@livechat/design-system-react-components");
23834
- var import_developer_studio_api29 = require("@livechat/developer-studio-api");
23861
+ var import_developer_studio_api28 = require("@livechat/developer-studio-api");
23835
23862
  var import_developer_studio_ui_react36 = require("@livechat/developer-studio-ui-react");
23836
23863
  function WorkflowTemplateCategoryIcon(props) {
23837
23864
  const icons = {
23838
- [import_developer_studio_api29.WorkflowTemplateCategory.NotificationAndAlerts]: import_design_system_icons33.Notifications,
23839
- [import_developer_studio_api29.WorkflowTemplateCategory.SalesManagement]: import_design_system_icons33.CurrencyDollar,
23840
- [import_developer_studio_api29.WorkflowTemplateCategory.LeadCollection]: import_design_system_icons33.TargetArrow,
23841
- [import_developer_studio_api29.WorkflowTemplateCategory.ChatManagement]: import_design_system_icons33.ChatDots,
23842
- [import_developer_studio_api29.WorkflowTemplateCategory.CustomerExperience]: import_design_system_icons33.Smiles
23865
+ [import_developer_studio_api28.WorkflowTemplateCategory.NotificationAndAlerts]: import_design_system_icons33.Notifications,
23866
+ [import_developer_studio_api28.WorkflowTemplateCategory.SalesManagement]: import_design_system_icons33.CurrencyDollar,
23867
+ [import_developer_studio_api28.WorkflowTemplateCategory.LeadCollection]: import_design_system_icons33.TargetArrow,
23868
+ [import_developer_studio_api28.WorkflowTemplateCategory.ChatManagement]: import_design_system_icons33.ChatDots,
23869
+ [import_developer_studio_api28.WorkflowTemplateCategory.CustomerExperience]: import_design_system_icons33.Smiles
23843
23870
  };
23844
23871
  return /* @__PURE__ */ jsxs2(import_developer_studio_ui_react36.Row, { gap: `var(${import_design_system_react_components72.SpacingToken.Spacing1})`, noWrap: true, notPadded: true, children: [
23845
23872
  /* @__PURE__ */ jsx4(
@@ -24107,7 +24134,7 @@ var import_developer_studio_ui_react42 = require("@livechat/developer-studio-ui-
24107
24134
  var import_react99 = require("react");
24108
24135
  var import_design_system_icons35 = require("@livechat/design-system-icons");
24109
24136
  var import_design_system_react_components74 = require("@livechat/design-system-react-components");
24110
- var import_developer_studio_api30 = require("@livechat/developer-studio-api");
24137
+ var import_developer_studio_api29 = require("@livechat/developer-studio-api");
24111
24138
  var import_developer_studio_ui_react38 = require("@livechat/developer-studio-ui-react");
24112
24139
  function WorkflowTemplatesCategoryFilter({
24113
24140
  handleStatus,
@@ -24131,11 +24158,11 @@ function WorkflowTemplatesCategoryFilter({
24131
24158
  );
24132
24159
  const options = [
24133
24160
  getItem("0", "All"),
24134
- getItem("1", import_developer_studio_api30.WorkflowTemplateCategory.NotificationAndAlerts, import_design_system_icons35.Notifications),
24135
- getItem("2", import_developer_studio_api30.WorkflowTemplateCategory.SalesManagement, import_design_system_icons35.CurrencyDollar),
24136
- getItem("3", import_developer_studio_api30.WorkflowTemplateCategory.LeadCollection, import_design_system_icons35.TargetArrow),
24137
- getItem("4", import_developer_studio_api30.WorkflowTemplateCategory.ChatManagement, import_design_system_icons35.ChatDots),
24138
- getItem("5", import_developer_studio_api30.WorkflowTemplateCategory.CustomerExperience, import_design_system_icons35.Smiles)
24161
+ getItem("1", import_developer_studio_api29.WorkflowTemplateCategory.NotificationAndAlerts, import_design_system_icons35.Notifications),
24162
+ getItem("2", import_developer_studio_api29.WorkflowTemplateCategory.SalesManagement, import_design_system_icons35.CurrencyDollar),
24163
+ getItem("3", import_developer_studio_api29.WorkflowTemplateCategory.LeadCollection, import_design_system_icons35.TargetArrow),
24164
+ getItem("4", import_developer_studio_api29.WorkflowTemplateCategory.ChatManagement, import_design_system_icons35.ChatDots),
24165
+ getItem("5", import_developer_studio_api29.WorkflowTemplateCategory.CustomerExperience, import_design_system_icons35.Smiles)
24139
24166
  ];
24140
24167
  const selectedKey = (_a = options.find(
24141
24168
  (option) => option.element.props.children[1] === status
@@ -24173,7 +24200,7 @@ var Category_default = WorkflowTemplatesCategoryFilter;
24173
24200
  var import_react100 = require("react");
24174
24201
  var import_design_system_icons36 = require("@livechat/design-system-icons");
24175
24202
  var import_design_system_react_components75 = require("@livechat/design-system-react-components");
24176
- var import_developer_studio_api31 = require("@livechat/developer-studio-api");
24203
+ var import_developer_studio_api30 = require("@livechat/developer-studio-api");
24177
24204
  var import_developer_studio_ui_react39 = require("@livechat/developer-studio-ui-react");
24178
24205
  function WorkflowTemplatesProductFilter({
24179
24206
  handleStatus,
@@ -24197,11 +24224,11 @@ function WorkflowTemplatesProductFilter({
24197
24224
  );
24198
24225
  const options = [
24199
24226
  getItem("0", "All"),
24200
- getItem("1", import_developer_studio_api31.IntegrationDisplayNames.LiveChat, import_design_system_icons36.LiveChatColored),
24201
- getItem("2", import_developer_studio_api31.IntegrationDisplayNames.HelpDesk, import_design_system_icons36.HelpDeskColored),
24202
- getItem("3", import_developer_studio_api31.IntegrationDisplayNames.OpenAI, import_design_system_icons36.Chatgpt),
24203
- getItem("4", import_developer_studio_api31.IntegrationDisplayNames.Shopify, import_design_system_icons36.ShopifyColored),
24204
- getItem("5", import_developer_studio_api31.IntegrationDisplayNames.Mailchimp, import_design_system_icons36.Mailchimp)
24227
+ getItem("1", import_developer_studio_api30.IntegrationDisplayNames.LiveChat, import_design_system_icons36.LiveChatColored),
24228
+ getItem("2", import_developer_studio_api30.IntegrationDisplayNames.HelpDesk, import_design_system_icons36.HelpDeskColored),
24229
+ getItem("3", import_developer_studio_api30.IntegrationDisplayNames.OpenAI, import_design_system_icons36.Chatgpt),
24230
+ getItem("4", import_developer_studio_api30.IntegrationDisplayNames.Shopify, import_design_system_icons36.ShopifyColored),
24231
+ getItem("5", import_developer_studio_api30.IntegrationDisplayNames.Mailchimp, import_design_system_icons36.Mailchimp)
24205
24232
  // getItem('6', IntegrationDisplayNames.Stripe, Stripe),
24206
24233
  // getItem('7', IntegrationDisplayNames.GoogleSheets, GoogleSheets),
24207
24234
  ];
@@ -24481,7 +24508,6 @@ var Create_default = WorkflowCreate;
24481
24508
  var import_react110 = require("react");
24482
24509
  var import_react_router_dom27 = require("react-router-dom");
24483
24510
  var import_design_system_react_components84 = require("@livechat/design-system-react-components");
24484
- var import_developer_studio_api33 = require("@livechat/developer-studio-api");
24485
24511
  var import_developer_studio_ui_react45 = require("@livechat/developer-studio-ui-react");
24486
24512
 
24487
24513
  // src/views/Workflows/Creator/LiveChatNavbar.tsx
@@ -24610,7 +24636,7 @@ var StatusFilter_default = WorkflowStatusFilter;
24610
24636
  var import_react_router_dom26 = require("react-router-dom");
24611
24637
  var import_design_system_icons40 = require("@livechat/design-system-icons");
24612
24638
  var import_design_system_react_components82 = require("@livechat/design-system-react-components");
24613
- var import_developer_studio_api32 = require("@livechat/developer-studio-api");
24639
+ var import_developer_studio_api31 = require("@livechat/developer-studio-api");
24614
24640
  var import_developer_studio_ui_react43 = require("@livechat/developer-studio-ui-react");
24615
24641
  function WorkflowsTable({ workflowsQuery, state }) {
24616
24642
  var _a, _b, _c;
@@ -24675,7 +24701,7 @@ function WorkflowsTable({ workflowsQuery, state }) {
24675
24701
  ) : null
24676
24702
  ] }) }),
24677
24703
  /* @__PURE__ */ jsx4("td", { width: "40%", children: /* @__PURE__ */ jsx4(import_developer_studio_ui_react43.Row, { gap: 12, notPadded: true, children: (_d = workflow.tags) == null ? void 0 : _d.map((tag) => {
24678
- const revertIconColor = getWorkflowsEnv("isHeadless") && (tag.toLowerCase() === "openai" || tag.toLowerCase() === import_developer_studio_api32.IntegrationNames.BigCommerce.toLowerCase());
24704
+ const revertIconColor = getWorkflowsEnv("isHeadless") && (tag.toLowerCase() === "openai" || tag.toLowerCase() === import_developer_studio_api31.IntegrationNames.BigCommerce.toLowerCase());
24679
24705
  return /* @__PURE__ */ jsx4(
24680
24706
  ProductIcon_default,
24681
24707
  {
@@ -24920,7 +24946,7 @@ function WorkflowListView() {
24920
24946
  Grid_default,
24921
24947
  {
24922
24948
  onStateChange: (change) => {
24923
- setState((prevState) => (0, import_developer_studio_api33.mergeDeep)(prevState, change));
24949
+ setState((prevState) => mergeDeep(prevState, change));
24924
24950
  },
24925
24951
  state,
24926
24952
  workflowQuery: workflows
package/dist/index.mjs CHANGED
@@ -14213,8 +14213,35 @@ function useWorkflowState(workflow, options) {
14213
14213
  };
14214
14214
  }
14215
14215
 
14216
+ // ../../private/utils/src/misc/merge-deep.ts
14217
+ function isObject(item) {
14218
+ return item !== null && typeof item === "object" && !Array.isArray(item);
14219
+ }
14220
+ function mergeDeep(target, source) {
14221
+ if (!isObject(target) || !isObject(source)) {
14222
+ return source;
14223
+ }
14224
+ const output = __spreadValues({}, target);
14225
+ Object.keys(source).forEach((key) => {
14226
+ if (isObject(source[key])) {
14227
+ if (!(key in target)) {
14228
+ output[key] = source[key];
14229
+ } else {
14230
+ output[key] = mergeDeep(
14231
+ target[key],
14232
+ source[key]
14233
+ );
14234
+ }
14235
+ } else if (Array.isArray(source[key])) {
14236
+ output[key] = [...source[key]];
14237
+ } else {
14238
+ output[key] = source[key];
14239
+ }
14240
+ });
14241
+ return output;
14242
+ }
14243
+
14216
14244
  // src/views/Workflows/Creator/Provider/utils.ts
14217
- import { mergeDeep } from "@livechat/developer-studio-api";
14218
14245
  function recursiveTaskReducer(tasks, reducer) {
14219
14246
  return tasks.reduce(
14220
14247
  (result, task2, taskIndex, allTasks) => {
@@ -24812,7 +24839,6 @@ import {
24812
24839
  DesignToken as DesignToken46,
24813
24840
  SpacingToken as SpacingToken45
24814
24841
  } from "@livechat/design-system-react-components";
24815
- import { mergeDeep as mergeDeep2 } from "@livechat/developer-studio-api";
24816
24842
  import {
24817
24843
  Column as Column18,
24818
24844
  Intro as Intro4,
@@ -25290,7 +25316,7 @@ function WorkflowListView() {
25290
25316
  Grid_default,
25291
25317
  {
25292
25318
  onStateChange: (change) => {
25293
- setState((prevState) => mergeDeep2(prevState, change));
25319
+ setState((prevState) => mergeDeep(prevState, change));
25294
25320
  },
25295
25321
  state,
25296
25322
  workflowQuery: workflows
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@livechat/platform-workflows",
3
- "version": "0.0.92",
3
+ "version": "0.0.93",
4
4
  "description": "Text Platform | Workflows",
5
5
  "author": "Wojciech Dudek",
6
6
  "license": "MIT",
@@ -86,9 +86,10 @@
86
86
  "uuid": "^9.0.1",
87
87
  "validator": "^13.12.0",
88
88
  "web-worker": "^1.3.0",
89
- "@livechat/developer-studio-api": "3.4.17",
90
- "@livechat/developer-studio-ui-react": "1.1.8",
91
- "@livechat/platform-integrations": "0.0.55"
89
+ "@livechat/developer-studio-ui-react": "1.1.9",
90
+ "@livechat/developer-studio-api": "3.4.18",
91
+ "utils": "0.0.5",
92
+ "@livechat/platform-integrations": "0.0.56"
92
93
  },
93
94
  "peerDependencies": {
94
95
  "@tanstack/react-query": "4.36.1",