fix: schema 完整性检测添加 THEME_TEMPLATE 字段

旧设备上持久化的 schema.json 不含 THEME_TEMPLATE 项,
导致设置页的换装分组不显示主题模板选择器。
在 needReset 检测中补充该字段,触发旧 schema 自动重置。
This commit is contained in:
7015725
2026-05-15 01:56:58 +08:00
parent d8a25aced9
commit d2abbcca9f
3 changed files with 5 additions and 5 deletions

View File

@@ -874,7 +874,7 @@ var ConfigManager = {
var needReset = false;
if (s) {
var sStr = JSON.stringify(s);
if (sStr.indexOf("ENABLE_SNAP_TO_EDGE") < 0 || sStr.indexOf("ENABLE_ANIMATIONS") < 0 || sStr.indexOf("BALL_IDLE_ALPHA") < 0 || sStr.indexOf("PANEL_POS_GRAVITY") < 0 || sStr.indexOf("single_choice") < 0 || sStr.indexOf("ball_shortx_icon") < 0 || sStr.indexOf("ball_color") < 0) {
if (sStr.indexOf("ENABLE_SNAP_TO_EDGE") < 0 || sStr.indexOf("ENABLE_ANIMATIONS") < 0 || sStr.indexOf("BALL_IDLE_ALPHA") < 0 || sStr.indexOf("PANEL_POS_GRAVITY") < 0 || sStr.indexOf("single_choice") < 0 || sStr.indexOf("ball_shortx_icon") < 0 || sStr.indexOf("ball_color") < 0 || sStr.indexOf("THEME_TEMPLATE") < 0) {
needReset = true;
}
} else {