@innovastudio/contentbuilder 1.5.5 → 1.5.7

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,7 +1,7 @@
1
1
  {
2
2
  "name": "@innovastudio/contentbuilder",
3
3
  "type": "module",
4
- "version": "1.5.5",
4
+ "version": "1.5.7",
5
5
  "description": "",
6
6
  "main": "public/contentbuilder/contentbuilder.esm.js",
7
7
  "files": [
@@ -1455,11 +1455,13 @@ const renderQuickAdd = builder => {
1455
1455
  elm = quickadd.querySelector('.add-social');
1456
1456
  dom.addEventListener(elm, 'click', () => {
1457
1457
  const mode = quickadd.getAttribute('data-mode');
1458
- const html = `<div class="is-social" style="text-align: center;">
1459
- <a href="https://twitter.com/"><i class="icon ion-social-twitter" style="margin-right: 1em"></i></a>
1460
- <a href="https://www.facebook.com/"><i class="icon ion-social-facebook" style="margin-right: 1em"></i></a>
1461
- <a href="mailto:you@example.com"><i class="icon ion-android-drafts"></i></a>
1462
- </div>`;
1458
+ const html = `
1459
+ <div class="is-social text-left">
1460
+ <a href="https://twitter.com/"><i class="bi bi-twitter-x"></i></a>
1461
+ <a href="https://www.facebook.com/"><i class="bi bi-facebook"></i></a>
1462
+ <a href="https://www.instagram.com/" title=""><i class="icon bi bi-instagram"></i></a>
1463
+ </div>
1464
+ `;
1463
1465
  util.addContent(html, mode);
1464
1466
  });
1465
1467
  elm = quickadd.querySelector('.add-map');
@@ -71827,7 +71829,7 @@ class SaveImages {
71827
71829
  if (this.opts.onBase64Upload) {
71828
71830
  //Read image (base64 string)
71829
71831
  let image = src;
71830
- image = image.replace(/^data:image\/(png|jpeg);base64,/, '');
71832
+ image = image.replace(/^data:image\/(png|svg\+xml|jpeg);base64,/, '');
71831
71833
  let filename = img.getAttribute('data-filename');
71832
71834
  this.opts.onBase64Upload(img, image, filename); // target image, base64 string, filename
71833
71835
  } else {
@@ -71835,7 +71837,7 @@ class SaveImages {
71835
71837
 
71836
71838
  //Read image (base64 string)
71837
71839
  let image = src;
71838
- image = image.replace(/^data:image\/(png|jpeg);base64,/, '');
71840
+ image = image.replace(/^data:image\/(png|svg\+xml|jpeg);base64,/, '');
71839
71841
 
71840
71842
  //Prepare form to submit image
71841
71843
  if (!this.builderStuff.querySelector('#form-' + this.count)) {
@@ -89384,7 +89386,11 @@ Add an image for each feature.`, 'Create a new content showcasing a photo galler
89384
89386
  e.preventDefault();
89385
89387
  return;
89386
89388
  }
89389
+ if (this.activeImage) {
89390
+ this.util.hideControls(); //deleting an image should also clear the visible image tool (and resizer).
89391
+ }
89387
89392
  }
89393
+
89388
89394
  this.oriLen = col.textContent.length; // get character length
89389
89395
 
89390
89396
  // Cleanup unwanted span