From 9341d63914555d1702e3174bcc89b3afafba9c81 Mon Sep 17 00:00:00 2001 From: fit2cloud-chenyw Date: Fri, 8 Oct 2021 18:31:19 +0800 Subject: [PATCH] =?UTF-8?q?perf:=20=E4=BC=98=E5=8C=96=E6=95=B0=E5=AD=97?= =?UTF-8?q?=E8=BE=93=E5=85=A5=E6=A1=86=E6=A0=B7=E5=BC=8F?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- frontend/src/layout/components/Topbar.vue | 8 ++++++++ frontend/src/styles/index.scss | 18 +++++++++++++++++- 2 files changed, 25 insertions(+), 1 deletion(-) diff --git a/frontend/src/layout/components/Topbar.vue b/frontend/src/layout/components/Topbar.vue index 26e432fa7a..3592055604 100644 --- a/frontend/src/layout/components/Topbar.vue +++ b/frontend/src/layout/components/Topbar.vue @@ -257,6 +257,14 @@ export default { value: val }) } + + if (this.uiInfo['ui.themeStr'] && this.uiInfo['ui.themeStr'].paramValue) { + if (this.uiInfo['ui.themeStr'].paramValue === 'dark') { + document.body.className = 'blackTheme' + } else if (this.uiInfo['ui.themeStr'].paramValue === 'light') { + document.body.className = '' + } + } this.axiosFinished = true }) }, diff --git a/frontend/src/styles/index.scss b/frontend/src/styles/index.scss index 23126c2d41..61c0eb804d 100644 --- a/frontend/src/styles/index.scss +++ b/frontend/src/styles/index.scss @@ -386,15 +386,31 @@ div:focus { } } +.blackTheme .el-textarea__inner { + background-color: var(--MainBG) !important; +} +.blackTheme .el-textarea__inner:not(:focus) { + + border-color: var(--border-color-input) !important; +} + .blackTheme .el-input__inner { background-color: var(--MainBG) !important; } .blackTheme .el-input__inner:not(:focus) { - // border: none !important; border-color: var(--border-color-input) !important; } +.blackTheme .el-input-number__decrease { + background-color: var(--MainBG) !important; + border: none !important; +} +.blackTheme .el-input-number__increase { + background-color: var(--MainBG) !important; + border: none !important; +} + .el-pagination { button:disabled {