impaktapps-ui-builder 0.0.963-copyElement.1017 → 0.0.963-copyElement.1019

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.
@@ -8431,8 +8431,9 @@ var Component = (store2, dynamicData2, submitHandler, service2) => {
8431
8431
  store2.updateDialog("popUpEventSection");
8432
8432
  },
8433
8433
  copyPasteElement: function(paramStore, setPage = this.setPage.bind(this)) {
8434
- const actionType = dynamicData2.tableButtonPath.split("_")[0];
8435
- const elementType = dynamicData2.tableButtonPath.split("_")[1];
8434
+ const path = dynamicData2.path.split(".")[2];
8435
+ const actionType = path.split("_")[0];
8436
+ const elementType = path.split("_")[1];
8436
8437
  if (actionType === "Copy") {
8437
8438
  this.CopyElement(paramStore, elementType);
8438
8439
  } else {
@@ -8471,15 +8472,15 @@ var Component = (store2, dynamicData2, submitHandler, service2) => {
8471
8472
  }
8472
8473
  const pastedElementParentPath = (_a = store2.searchParams) == null ? void 0 : _a.get("path");
8473
8474
  const formData = getFormdataFromSessionStorage(pastedElementParentPath);
8474
- const insertElementIndex = elementType === "component" ? formData.elements.length : formData.events.length;
8475
+ const insertElementIndex = elementType === "Component" ? formData.elements.length : formData.events.length;
8475
8476
  const pastedElementPath = this.elementPathHandler(pastedElementParentPath, insertElementIndex, elementType);
8476
8477
  const copiedConfig = JSON.parse(sessionStorage.getItem("copiedConfig"));
8477
- if (copiedConfig.Handler && elementType === "component") {
8478
+ if (copiedConfig.Handler && elementType === "Component") {
8478
8479
  store2.setNotify({
8479
8480
  FailMessage: "The pasted content is invalid; the event cannot be integrated into the component section.",
8480
8481
  Fail: true
8481
8482
  });
8482
- } else if (copiedConfig.elements && elementType === "event") {
8483
+ } else if (copiedConfig.elements && elementType === "Event") {
8483
8484
  store2.setNotify({
8484
8485
  FailMessage: "The pasted content is invalid; the component cannot be integrated into the event section.",
8485
8486
  Fail: true