diff --git a/src/editor/EditorStartup.js b/src/editor/EditorStartup.js index 01db4886..de30d96f 100644 --- a/src/editor/EditorStartup.js +++ b/src/editor/EditorStartup.js @@ -220,8 +220,8 @@ class EditorStartup { } }); - $('#font_family').change((evt) => { - this.svgCanvas.setFontFamily(evt.currentTarget.value); + $('#tool_font_family').change((evt) => { + this.svgCanvas.setFontFamily(evt.originalEvent.detail.value); }); $('#seg_type').change((evt) => { diff --git a/src/editor/components/seList.js b/src/editor/components/seList.js index bd96d008..22cbaffb 100644 --- a/src/editor/components/seList.js +++ b/src/editor/components/seList.js @@ -83,11 +83,13 @@ export class SeList extends HTMLElement { * @returns {void} */ connectedCallback () { - this.$dropdown.addEventListener('change', (e) => { + const currentObj = this; + this.$dropdown.addEventListener('selectedindexchange', (e) => { e.preventDefault(); - const selectedItem = e?.detail?.closeResult; - if (selectedItem !== undefined && selectedItem?.id !== undefined) { - document.getElementById(selectedItem.id).click(); + if (e?.detail?.selectedIndex !== undefined) { + const value = this.$dropdown.selectedItem.getAttribute('value'); + const closeEvent = new CustomEvent('change', {detail: {value}}); + currentObj.dispatchEvent(closeEvent); } }); } diff --git a/src/editor/extensions/ext-imagelib/ext-imagelib.js b/src/editor/extensions/ext-imagelib/ext-imagelib.js index 99deaf88..5e48e1d0 100644 --- a/src/editor/extensions/ext-imagelib/ext-imagelib.js +++ b/src/editor/extensions/ext-imagelib/ext-imagelib.js @@ -1,3 +1,4 @@ +/* globals seConfirm */ /** * @file ext-imagelib.js * @@ -181,11 +182,11 @@ export default { const message = uiStrings.notification.retrieving.replace('%s', name); if (mode !== 'm') { - await $.process_cancel(message); + await seConfirm(message); transferStopped = true; // Should a message be sent back to the frame? - $('#dialog_box').hide(); + // $('#dialog_box').hide(); } else { entry = $('