1
0

ISSUE-2 #3

Merged
stuzer05 merged 1 commits from ISSUE-2 into master 2022-12-30 13:23:48 +02:00
Showing only changes of commit a573f91fcd - Show all commits

View File

@ -668,13 +668,17 @@ require(['vs/editor/editor.main'], function () {
// On preview
let el_btn_preview = document.querySelector('#wpPreview');
el_btn_preview.addEventListener('click', event => {
el_stock_editor.value = window.monaco_editor.getValue();
});
if (el_btn_preview) {
el_btn_preview.addEventListener('click', event => {
el_stock_editor.value = window.monaco_editor.getValue();
});
}
// On save
let el_btn_save = document.querySelector('#wpSave');
el_btn_save.addEventListener('click', event => {
el_stock_editor.value = window.monaco_editor.getValue();
});
if (el_btn_save) {
el_btn_save.addEventListener('click', event => {
el_stock_editor.value = window.monaco_editor.getValue();
});
}
});