From e2c317f59c4cc5b19f70e4fd44d5939cc1636179 Mon Sep 17 00:00:00 2001 From: SiriusXT <1160925501@qq.com> Date: Sat, 8 Mar 2025 14:58:19 +0800 Subject: [PATCH] Add themes that can be base --- src/routes/index.ts | 2 +- src/views/desktop.ejs | 8 ++++++-- 2 files changed, 7 insertions(+), 3 deletions(-) diff --git a/src/routes/index.ts b/src/routes/index.ts index 966f71ab3..e7cd36228 100644 --- a/src/routes/index.ts +++ b/src/routes/index.ts @@ -37,7 +37,7 @@ function index(req: Request, res: Response) { device: view, csrfToken: csrfToken, themeCssUrl: getThemeCssUrl(theme, themeNote), - themeUseNextAsBase: themeNote?.getAttributeValue("label", "appThemeBase") === "next", + themeUseNextAsBase: themeNote?.getAttributeValue("label", "appThemeBase"), headingStyle: options.headingStyle, layoutOrientation: options.layoutOrientation, platform: process.platform, diff --git a/src/views/desktop.ejs b/src/views/desktop.ejs index 6896eeba8..40f369c85 100644 --- a/src/views/desktop.ejs +++ b/src/views/desktop.ejs @@ -53,8 +53,12 @@ <% } %> -<% if (themeUseNextAsBase) { %> - +<% if (themeUseNextAsBase === "next") { %> + +<% } else if (themeUseNextAsBase === "next-dark") { %> + +<% } else if (themeUseNextAsBase === "next-light") { %> + <% } %>