From e58ea5a15534f180e40350b28e20e5806551a3fd Mon Sep 17 00:00:00 2001 From: Agriya Dev5 Date: Wed, 19 May 2021 14:46:40 +0530 Subject: [PATCH] #98 dialogs i18n translate changes --- src/editor/Editor.js | 10 +++++ src/editor/dialogs/cmenuDialog.js | 24 ++++++----- src/editor/dialogs/cmenuLayersDialog.js | 10 +++-- src/editor/dialogs/editorPreferencesDialog.js | 42 +++++++++---------- .../extensions/ext-storage/storageDialog.js | 2 +- src/editor/index.js | 1 - 6 files changed, 51 insertions(+), 38 deletions(-) diff --git a/src/editor/Editor.js b/src/editor/Editor.js index 45c7168c..2a87e055 100644 --- a/src/editor/Editor.js +++ b/src/editor/Editor.js @@ -111,6 +111,16 @@ class Editor extends EditorStartup { this.layersPanel = new LayersPanel(this); this.mainMenu = new MainMenu(this); window.svgEditor = this; + this.loadComponentAndDialog(); + } + /** + * @returns {void} + */ + async loadComponentAndDialog() { + // eslint-disable-next-line no-unsanitized/method + // await import(`./components/index.js`); + // eslint-disable-next-line no-unsanitized/method + await import(`./dialogs/index.js`); } /** * diff --git a/src/editor/dialogs/cmenuDialog.js b/src/editor/dialogs/cmenuDialog.js index 3673d88e..5f1a68c2 100644 --- a/src/editor/dialogs/cmenuDialog.js +++ b/src/editor/dialogs/cmenuDialog.js @@ -1,4 +1,6 @@ +/* globals svgEditor */ const template = document.createElement('template'); +// eslint-disable-next-line no-unsanitized/property template.innerHTML = ` `; /** diff --git a/src/editor/dialogs/editorPreferencesDialog.js b/src/editor/dialogs/editorPreferencesDialog.js index 9c83c7c3..48372353 100644 --- a/src/editor/dialogs/editorPreferencesDialog.js +++ b/src/editor/dialogs/editorPreferencesDialog.js @@ -1,6 +1,6 @@ - - +/* globals svgEditor */ const template = document.createElement('template'); +// eslint-disable-next-line no-unsanitized/property template.innerHTML = `