#97 update from master svgedit

This commit is contained in:
Agriya Dev5
2021-05-18 16:44:50 +05:30
parent d759f28104
commit cdace46f6f
10 changed files with 31 additions and 87 deletions

View File

@@ -34,28 +34,6 @@ describe('select', function () {
return ret;
}
};
const dataStorage = {
_storage: new WeakMap(),
put: function (element, key, obj) {
if (!this._storage.has(element)) {
this._storage.set(element, new Map());
}
this._storage.get(element).set(key, obj);
},
get: function (element, key) {
return this._storage.get(element).get(key);
},
has: function (element, key) {
return this._storage.has(element) && this._storage.get(element).has(key);
},
remove: function (element, key) {
var ret = this._storage.get(element).delete(key);
if (!this._storage.get(element).size === 0) {
this._storage.delete(element);
}
return ret;
}
};
/**
* @implements {module:select.SVGFactory}

View File

@@ -34,6 +34,7 @@ describe('Basic Module', function () {
workarea.append(svgcanvas);
const toolsLeft = document.createElement('div');
toolsLeft.id = 'tools_left';
svgEditor.append(workarea, toolsLeft);
document.body.append(svgEditor);