Merge branch 'refactor-folders' of https://github.com/SVG-Edit/svgedit into refactor-folders
This commit is contained in:
@@ -1,4 +1,3 @@
|
|||||||
/* eslint-disable jsdoc/check-examples */
|
|
||||||
import assertionWrapper from './assertion-wrapper.js';
|
import assertionWrapper from './assertion-wrapper.js';
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|||||||
@@ -20866,14 +20866,10 @@
|
|||||||
* @returns {void}
|
* @returns {void}
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
if (elem.children) elem.children.forEach(child => checkIDs(child));
|
||||||
|
}
|
||||||
|
|
||||||
this.pasteElements = function (type, x, y) {
|
clipb.forEach(elem => checkIDs(elem)); // Give extensions like the connector extension a chance to reflect new IDs and remove invalid elements
|
||||||
var clipb = JSON.parse(sessionStorage.getItem(CLIPBOARD_ID));
|
|
||||||
if (!clipb) return;
|
|
||||||
var len = clipb.length;
|
|
||||||
if (!len) return;
|
|
||||||
var pasted = [];
|
|
||||||
var batchCmd = new BatchCommand$1('Paste elements'); // const drawing = getCurrentDrawing();
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @typedef {PlainObject<string, string>} module:svgcanvas.ChangedIDs
|
* @typedef {PlainObject<string, string>} module:svgcanvas.ChangedIDs
|
||||||
|
|||||||
2
src/external/dom-polyfill/dom-polyfill.js
vendored
2
src/external/dom-polyfill/dom-polyfill.js
vendored
@@ -42,6 +42,7 @@ function convertNodesIntoANode (nodes) {
|
|||||||
}
|
}
|
||||||
const node = document.createDocumentFragment();
|
const node = document.createDocumentFragment();
|
||||||
nodes.forEach((n) => {
|
nodes.forEach((n) => {
|
||||||
|
// // eslint-disable-next-line unicorn/prefer-node-append
|
||||||
node.appendChild(n);
|
node.appendChild(n);
|
||||||
});
|
});
|
||||||
return node;
|
return node;
|
||||||
@@ -54,6 +55,7 @@ const ParentNode = {
|
|||||||
},
|
},
|
||||||
append (...nodes) {
|
append (...nodes) {
|
||||||
nodes = convertNodesIntoANode(nodes);
|
nodes = convertNodesIntoANode(nodes);
|
||||||
|
// // eslint-disable-next-line unicorn/prefer-node-append
|
||||||
this.appendChild(nodes);
|
this.appendChild(nodes);
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|||||||
@@ -6443,9 +6443,9 @@ this.pasteElements = function (type, x, y) {
|
|||||||
changedIDs[elem.attr.id] = getNextId();
|
changedIDs[elem.attr.id] = getNextId();
|
||||||
elem.attr.id = changedIDs[elem.attr.id];
|
elem.attr.id = changedIDs[elem.attr.id];
|
||||||
}
|
}
|
||||||
if (elem.children) elem.children.forEach(checkIDs);
|
if (elem.children) elem.children.forEach((child) => checkIDs(child));
|
||||||
}
|
}
|
||||||
clipb.forEach(checkIDs);
|
clipb.forEach((elem) => checkIDs(elem));
|
||||||
|
|
||||||
// Give extensions like the connector extension a chance to reflect new IDs and remove invalid elements
|
// Give extensions like the connector extension a chance to reflect new IDs and remove invalid elements
|
||||||
/**
|
/**
|
||||||
|
|||||||
33426
svgedit-config-iife.js
33426
svgedit-config-iife.js
File diff suppressed because one or more lines are too long
Reference in New Issue
Block a user