@innovastudio/contentbuilder 1.2.17 → 1.2.20

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@innovastudio/contentbuilder",
3
- "version": "1.2.17",
3
+ "version": "1.2.20",
4
4
  "type": "module",
5
5
  "description": "",
6
6
  "main": "public/contentbuilder/contentbuilder.esm.js",
@@ -4108,7 +4108,7 @@ class Util {
4108
4108
  let html = '';
4109
4109
  html = `<div class="is-modal is-confirm" tabindex="-1" role="dialog" aria-modal="true" aria-hidden="true">
4110
4110
  <div class="is-modal-content" style="padding-bottom:20px;">
4111
- <p>${message}</p>
4111
+ <div style="margin: 20px 0 30px;font-size: 14px;">${message}</div>
4112
4112
  <button title="${this.out('Delete')}" class="input-ok classic focus-warning">${this.out('Delete')}</button>
4113
4113
  </div>
4114
4114
  </div>`;
@@ -4116,7 +4116,7 @@ class Util {
4116
4116
  if (yesno) {
4117
4117
  html = `<div class="is-modal is-confirm" tabindex="-1" role="dialog" aria-modal="true" aria-hidden="true">
4118
4118
  <div class="is-modal-content" style="padding-bottom:20px;">
4119
- <p>${message}</p>
4119
+ <div style="margin: 20px 0 30px;font-size: 14px;">${message}</div>
4120
4120
  <button title="${this.out('Cancel')}" class="input-cancel classic-secondary">${this.out('Cancel')}</button>
4121
4121
  <button title="${yestext}" class="input-ok classic-primary">${yestext}</button>
4122
4122
  </div>
@@ -4204,8 +4204,16 @@ class Util {
4204
4204
  }
4205
4205
 
4206
4206
  showPop(pop, cancelCallback, btn) {
4207
- const dom = this.dom;
4208
- if (pop.style.display === 'flex') return; // important
4207
+ const dom = this.dom; // Hide other pops
4208
+
4209
+ let elms = this.builder.doc.querySelectorAll('.is-pop.active');
4210
+ Array.prototype.forEach.call(elms, elm => {
4211
+ if (elm !== pop) {
4212
+ elm.style.display = '';
4213
+ dom.removeClass(elm, 'active');
4214
+ elm.setAttribute('aria-hidden', true);
4215
+ }
4216
+ }); // if(pop.style.display === 'flex') return;
4209
4217
 
4210
4218
  this.clearAllEventListener(pop); // for safety of uncleared events as a result of closing without hidePop()
4211
4219
 
@@ -5163,11 +5171,13 @@ class Util {
5163
5171
  rtepop.style.display = '';
5164
5172
  dom.removeClass(rtepop, 'active');
5165
5173
  dom.removeClass(rtepop, 'deactive'); // dom.addClass(rtepop, 'deactive');
5166
- }); // let pops = builderStuff.querySelectorAll('.is-pop');
5167
- // Array.prototype.forEach.call(pops, (pop) => {
5168
- // pop.style.display = '';
5169
- // });
5170
-
5174
+ });
5175
+ let pops = builderStuff.querySelectorAll('.is-pop');
5176
+ Array.prototype.forEach.call(pops, pop => {
5177
+ pop.style.display = '';
5178
+ dom.removeClass(pop, 'active');
5179
+ pop.setAttribute('aria-hidden', true);
5180
+ });
5171
5181
  this.builder.colTool.lockIndicator.style.display = ''; // Clear resizable images
5172
5182
  // this.builder.element.image.clearImageResizer();
5173
5183
  } // source: http://stackoverflow.com/questions/1349404/generate-a-string-of-5-random-characters-in-javascript
@@ -17898,7 +17908,7 @@ class ColumnTool$1 {
17898
17908
  setTimeout(() => {
17899
17909
  dom$G.removeClass(this.columnMore, 'transition1');
17900
17910
  }, 300);
17901
- }, 300);
17911
+ }, 30);
17902
17912
  }
17903
17913
 
17904
17914
  hide() {
@@ -52649,13 +52659,11 @@ class RowTool {
52649
52659
  rowMore = builderStuff.querySelector('.rowmore');
52650
52660
  let elm = rowMore.querySelector('.row-up');
52651
52661
  if (elm) dom$p.addEventListener(elm, 'click', () => {
52652
- this.grid.moveRowUp();
52653
- util.clearControls();
52662
+ this.grid.moveRowUp(); // util.clearControls();
52654
52663
  });
52655
52664
  elm = rowMore.querySelector('.row-down');
52656
52665
  if (elm) dom$p.addEventListener(elm, 'click', () => {
52657
- this.grid.moveRowDown();
52658
- util.clearControls();
52666
+ this.grid.moveRowDown(); // util.clearControls();
52659
52667
  });
52660
52668
  elm = rowMore.querySelector('.row-duplicate');
52661
52669
  if (elm) dom$p.addEventListener(elm, 'click', () => {
@@ -52925,7 +52933,7 @@ class Modal {
52925
52933
  confirm(message, callback, animated) {
52926
52934
  let html = `<div class="is-modal is-confirm" tabindex="-1" role="dialog" aria-modal="true" aria-hidden="true">
52927
52935
  <div class="is-modal-content" style="padding-bottom:20px;">
52928
- <p>${message}</p>
52936
+ <div style="margin: 20px 0 30px;font-size: 14px;">${message}</div>
52929
52937
  <button title="${this.out('Delete')}" class="input-ok classic">${this.out('Delete')}</button>
52930
52938
  </div>
52931
52939
  </div>`;
@@ -55095,14 +55103,12 @@ class ColumnTool {
55095
55103
 
55096
55104
  elm = columnMore.querySelector('.cell-prev');
55097
55105
  dom$n.addEventListener(elm, 'click', () => {
55098
- this.grid.moveColumnPrevious();
55099
- util.clearControls();
55106
+ this.grid.moveColumnPrevious(); // util.clearControls();
55100
55107
  }); // Move Next
55101
55108
 
55102
55109
  elm = columnMore.querySelector('.cell-next');
55103
55110
  dom$n.addEventListener(elm, 'click', () => {
55104
- this.grid.moveColumnNext();
55105
- util.clearControls();
55111
+ this.grid.moveColumnNext(); // util.clearControls();
55106
55112
  }); // Move Up
55107
55113
 
55108
55114
  elm = columnMore.querySelector('.cell-up');
@@ -70166,8 +70172,8 @@ class ContentBuilder {
70166
70172
  col.addEventListener('keydown', this.handleCellKeydown.bind(this, col)); // ON KEYUP
70167
70173
 
70168
70174
  col.addEventListener('keyup', this.handleCellKeyup.bind(this, col)); // ON FOCUS
70169
-
70170
- col.addEventListener('focus', this.handleCellFocus.bind(this, col)); // ON PASTE
70175
+ // col.addEventListener('focus', this.handleCellFocus.bind(this, col));
70176
+ // ON PASTE
70171
70177
 
70172
70178
  col.addEventListener('paste', this.handleCellPaste.bind(this));
70173
70179
  col.setAttribute('data-click', true);