Fix: update live preview when the style is toggled/replaced (#662)

This commit is contained in:
eight 2019-02-04 03:00:13 +08:00 committed by narcolepticinsomniac
parent 0bd738b49f
commit dfb9db34c3

View File

@ -197,6 +197,7 @@ function createSectionsEditor({style, onTitleChanged}) {
dirty.modify('enabled', style.enabled, newValue);
style.enabled = newValue;
enabledEl.checked = newValue;
updateLivePreview();
}
function nextEditor(cm, cycle = true) {
@ -565,6 +566,7 @@ function createSectionsEditor({style, onTitleChanged}) {
$('#heading').textContent = t('editStyleHeading');
}
livePreview.show(Boolean(style.id));
updateLivePreview();
});
function reinit() {