diff --git a/licenseInfo.json b/licenseInfo.json index 9573bfe8..e71fa2f1 100644 --- a/licenseInfo.json +++ b/licenseInfo.json @@ -7,8 +7,7 @@ "stackblur-canvas", "regenerator-runtime", "core-js-bundle", - "underscore", - "deparam" + "underscore" ], "filesByLicense": { "(MIT OR GPL-2.0)": ["src/editor/jquerybbq/jquery.bbq.min.js"], diff --git a/package.json b/package.json index b39a795f..a30906e5 100644 --- a/package.json +++ b/package.json @@ -96,7 +96,6 @@ "@web/dev-server-rollup": "0.3.4", "canvg": "3.0.7", "core-js": "3.12.1", - "deparam": "1.0.5", "elix": "15.0.0", "i18next": "20.3.0", "jquery": "3.6.0", diff --git a/src/editor/ConfigObj.js b/src/editor/ConfigObj.js index 94c7c238..c29a5e34 100644 --- a/src/editor/ConfigObj.js +++ b/src/editor/ConfigObj.js @@ -1,5 +1,4 @@ // eslint-disable-next-line node/no-unpublished-import -import deparam from 'deparam'; import { mergeDeep } from './components/jgraduate/Util.js'; /** @@ -240,9 +239,12 @@ export default class ConfigObj { */ loadFromURL () { const { search, searchParams } = new URL(location); - if (search) { - this.urldata = deparam(searchParams.toString()); + this.urldata = {}; + const entries = searchParams.entries(); + for(const entry of entries) { + this.urldata[entry[0]] = entry[1]; + } [ 'initStroke', 'initFill' ].forEach((prop) => { if (searchParams.has(`${prop}[color]`)) {