From e2d91ea24877bbe1ff5469725509d08ed1c6fcca Mon Sep 17 00:00:00 2001 From: JFH <20402845+jfhenon@users.noreply.github.com> Date: Sun, 29 Aug 2021 12:53:46 +0200 Subject: [PATCH] fix bug with layers transformation --- src/svgcanvas/utilities.js | 16 +--------------- 1 file changed, 1 insertion(+), 15 deletions(-) diff --git a/src/svgcanvas/utilities.js b/src/svgcanvas/utilities.js index cdd2e045..a482daff 100644 --- a/src/svgcanvas/utilities.js +++ b/src/svgcanvas/utilities.js @@ -122,20 +122,6 @@ export const toXml = function (str) { .replace(/'/g, '''); // Note: `'` is XML only }; -/** -* Converts XML entities in a string to single characters. -* @function module:utilities.fromXml -* @example `&` becomes `&` -* @param {string} str - The string to be converted -* @returns {string} The converted string -*/ -export function fromXml(str) { - const p = document.createElement('p'); - // eslint-disable-next-line no-unsanitized/property - p.innerHTML = str; - return p.textContent; -} - // This code was written by Tyler Akins and has been placed in the // public domain. It would be nice if you left this header intact. // Base64 code from Tyler Akins -- http://rumkin.com @@ -1127,7 +1113,7 @@ export const getStrokedBBox = function (elems, addSVGElementFromJson, pathAction export const getVisibleElements = function (parentElement) { if (!parentElement) { const svgcontent = editorContext_.getSVGContent(); - parentElement = svgcontent.children; // Prevent layers from being included + parentElement = svgcontent.children[0]; // Prevent layers from being included } const contentElems = [];