@social-mail/social-mail-client 1.2.640 → 1.2.641

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.
@@ -49497,6 +49497,29 @@ System.register(["tslib", "@web-atoms/core/dist/core/Bind", "@web-atoms/core/dis
49497
49497
  InstallDragDropHelper(this);
49498
49498
  setTimeout(() => {
49499
49499
  this.undoRedo = new UndoRedo(this.htmlDocument, this);
49500
+ const clone = this.htmlDocument;
49501
+ if (clone.querySelector(`[styler-layout="component"]`)) {
49502
+ let componentScript = clone.querySelector("[styler-component-script]");
49503
+ if (!componentScript) {
49504
+ componentScript = this.htmlDocument.createElement("script");
49505
+ componentScript.setAttribute("styler-component-script", "component-script");
49506
+ const head = clone.querySelector("head");
49507
+ head.appendChild(componentScript);
49508
+ const scripts = clone.querySelectorAll("script[src]");
49509
+ for (let index = 0; index < scripts.length; index++) {
49510
+ const script = scripts[index];
49511
+ const srcScript = script.getAttribute("src");
49512
+ if (srcScript.includes("@social-mail/social-mail-client/") || srcScript.includes("/component.js")) {
49513
+ script.remove();
49514
+ break;
49515
+ }
49516
+ }
49517
+ }
49518
+ const src = UMD.resolvePath("@social-mail/social-mail-client/component.js");
49519
+ if (componentScript.getAttribute("src") !== src) {
49520
+ componentScript.setAttribute("src", src);
49521
+ }
49522
+ }
49500
49523
  }, 10);
49501
49524
  });
49502
49525
  }