webconfig js: resolve a comment

This commit is contained in:
Johannes Altmanninger
2025-11-27 06:23:44 +01:00
parent 7f1b53a9f1
commit f503dcb92d

View File

@@ -12,8 +12,7 @@ document.addEventListener("alpine:init", () => {
changeSelectedColorScheme(newScheme) {
console.log(newScheme);
// TODO find out if angular.copy is deep copy
this.selectedColorScheme = { ...newScheme };
this.selectedColorScheme = newScheme;
if (this.selectedColorScheme.preferred_background) {
this.terminalBackgroundColor = this.selectedColorScheme.preferred_background;
}
@@ -211,7 +210,7 @@ document.addEventListener("alpine:init", () => {
}
this.colorSchemes.push(currentScheme);
}
this.changeSelectedColorScheme(this.colorSchemes[0]);
this.changeSelectedColorScheme(JSON.parse(JSON.stringify(this.colorSchemes[0])));
},
}));