Skip to content

Commit 14c445b

Browse files
feat. alert user when changing editor theme (Acode-Foundation#1383)
* feat. alert user when changing editor theme * format
1 parent a1a79e2 commit 14c445b

File tree

1 file changed

+6
-1
lines changed

1 file changed

+6
-1
lines changed

src/pages/themeSetting/themeSetting.js

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -193,7 +193,12 @@ console.log(message);`);
193193
* @param {string} param0.theme
194194
*/
195195
function setEditorTheme({ caption, theme }) {
196-
editorManager.editor.setTheme(theme); // main editor
196+
if (appSettings.value.appTheme.toLowerCase() === "system") {
197+
alert(
198+
"App theme is set to 'System'. Changing the editor theme will not affect the editor appearance.",
199+
);
200+
}
201+
editorManager.editor.setTheme(theme);
197202
editor.setTheme(theme); // preview
198203
appSettings.update(
199204
{

0 commit comments

Comments
 (0)