From 7c15d60c5e763ac7942f9aa60febdd96bc269ff3 Mon Sep 17 00:00:00 2001 From: Tony Date: Tue, 9 Apr 2024 15:44:57 +0800 Subject: [PATCH] =?UTF-8?q?style:=20=E7=99=BB=E5=BD=95=E9=A1=B5=E9=BB=98?= =?UTF-8?q?=E8=AE=A4=E6=A0=B7=E5=BC=8F?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- tzipc-ui/src/views/login.vue | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/tzipc-ui/src/views/login.vue b/tzipc-ui/src/views/login.vue index cc9b4bb..32b9122 100644 --- a/tzipc-ui/src/views/login.vue +++ b/tzipc-ui/src/views/login.vue @@ -146,11 +146,12 @@ export default { created() { this.getCode(); this.getCookie(); - }, methods: { getTitleBg() { - const theme = localStorage.getItem("data-theme") || 'redTheme' + const theme = localStorage.getItem("data-theme") || 'default' + window.document.documentElement.setAttribute('data-theme', theme) + window.document.documentElement.setAttribute('class', 'light') if (theme === 'default') return '/theme/default/loginTitle.png' if (theme === 'redTheme') return '/theme/redTheme/loginTitle.png' return '/theme/default/loginTitle.png'