@innovastudio/contentbuilder 1.4.122 → 1.4.124

Sign up to get free protection for your applications and to get access to all the features.
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@innovastudio/contentbuilder",
3
3
  "type": "module",
4
- "version": "1.4.122",
4
+ "version": "1.4.124",
5
5
  "description": "",
6
6
  "main": "public/contentbuilder/contentbuilder.esm.js",
7
7
  "files": [
@@ -69300,7 +69300,11 @@ class SaveImages {
69300
69300
  });
69301
69301
  }
69302
69302
  if (finished) {
69303
- this.opts.onComplete();
69303
+ try {
69304
+ this.opts.onComplete();
69305
+ } catch (e) {
69306
+ // Do Nothing
69307
+ }
69304
69308
  window.clearInterval(int);
69305
69309
 
69306
69310
  // No need to remove hidden iframes
@@ -72705,7 +72709,11 @@ class LivePreview {
72705
72709
  if (this.modal.classList.contains('active')) {
72706
72710
  // let html = this.builder.html();
72707
72711
  // localStorage.setItem('preview-html', html);
72708
- if (this.builder.onPreviewOpen) this.builder.onPreviewOpen();
72712
+ try {
72713
+ if (this.builder.onPreviewOpen) this.builder.onPreviewOpen();
72714
+ } catch (e) {
72715
+ return;
72716
+ }
72709
72717
  const iframe = this.modal.querySelector('iframe');
72710
72718
  if (!this.builder.doc.querySelector('.is-wrapper')) {
72711
72719
  // ContentBuilder
@@ -72869,7 +72877,11 @@ class LivePreview {
72869
72877
  this.builder.livePreviewAlwaysReload = oriVal;
72870
72878
  }
72871
72879
  iframe.onload = () => {
72872
- if (this.builder.onPreviewContentLoad && !disableOnContentLoad) this.builder.onPreviewContentLoad();
72880
+ try {
72881
+ if (this.builder.onPreviewContentLoad && !disableOnContentLoad) this.builder.onPreviewContentLoad();
72882
+ } catch (e) {
72883
+ // Do Nothing
72884
+ }
72873
72885
  iframe.contentWindow.document.addEventListener('click', () => {
72874
72886
  iframe.focus();
72875
72887
  });
@@ -72879,7 +72891,8 @@ class LivePreview {
72879
72891
  openPreview() {
72880
72892
  // if(!this.builder.previewURL) return;
72881
72893
 
72882
- if (this.modal.classList.contains('active')) return;
72894
+ // if(this.modal.classList.contains('active')) return;
72895
+
72883
72896
  const util = this.util;
72884
72897
  const modal = this.modal;
72885
72898
  modal.classList.add('active');