dark
This commit is contained in:
parent
2efae40ff3
commit
1c91237e1d
|
@ -14,7 +14,8 @@
|
|||
</head>
|
||||
|
||||
<body>
|
||||
<div id="app" class="hidden" element-loading-background="rgba(0, 0, 0, 0.3)">
|
||||
<div id="app" class="hidden"
|
||||
:element-loading-background="themeInfo.name=='black' ? 'rgba(0, 0, 0, 0.6)' : 'rgba(0, 0, 0, 0.3)'">
|
||||
<div class="page-layout" :class="{ collapse: menuCollapse }">
|
||||
<!-- 遮罩层 -->
|
||||
<div class="page-layout__mask" @click="collapseMenu(true)"></div>
|
||||
|
@ -221,7 +222,8 @@
|
|||
</div>
|
||||
|
||||
<!-- 页面视图 -->
|
||||
<div class="page-layout__container" v-loading="iframeLoading">
|
||||
<div class="page-layout__container" v-loading="iframeLoading"
|
||||
:element-loading-background="themeInfo.name=='black' ? 'rgba(0, 0, 0, 0.6)' : 'rgba(0, 0, 0, 0.3)'">
|
||||
<div class="page-layout__view">
|
||||
<iframe @load="iframeLoading=false" :ref="`iframe-${item.id}`" :class="{ hidden: activeTabId != item.id}"
|
||||
v-for="(item, index) in processList" :key="index" :name="'iframe'+index" width="100%" height="100%"
|
||||
|
@ -409,6 +411,17 @@
|
|||
localStorage.setItem('index_theme', JSON.stringify(that.themeInfo));
|
||||
// 设置 css 变量
|
||||
document.getElementsByTagName("body")[0].style.setProperty("--color-primary", color);
|
||||
|
||||
var isDark = name == 'black' ? 'dark' : 'default';
|
||||
localStorage.setItem('site_theme', isDark);
|
||||
$('body').attr('data-theme', isDark);
|
||||
for (var i in this.processList) {
|
||||
var item = this.processList[i];
|
||||
var el = this.$refs[`iframe-${item.id}`][0];
|
||||
if (el) {
|
||||
$(el).contents().find('body').attr('data-theme', isDark);
|
||||
}
|
||||
}
|
||||
},
|
||||
/*tab操作*/
|
||||
activeItem(item, index) {
|
||||
|
|
|
@ -62,6 +62,35 @@ input:-webkit-autofill {
|
|||
clear: both;
|
||||
}
|
||||
|
||||
body[data-theme=dark] {
|
||||
background-color: #1c1e2f;
|
||||
color: #8c909a;
|
||||
}
|
||||
|
||||
[data-theme=dark] .page-layout__process,
|
||||
[data-theme=dark] .app-process__left,
|
||||
[data-theme=dark] .app-process__right,
|
||||
[data-theme=dark] .app-process__item {
|
||||
background-color: #292B3D;
|
||||
color: #8c909a;
|
||||
}
|
||||
|
||||
[data-theme=dark] .app-process__item,
|
||||
[data-theme=dark] .page-layout__process {
|
||||
border-color: #8c909a;
|
||||
}
|
||||
|
||||
[data-theme=dark] .app-process__item.active span,
|
||||
[data-theme=dark] .app-process__item .el-icon-close {
|
||||
color: #ddd;
|
||||
}
|
||||
|
||||
[data-theme=dark] .el-dropdown-menu {
|
||||
background-color: #1c1e2f;
|
||||
color: #8c909a;
|
||||
border-color: #8c909a;
|
||||
}
|
||||
|
||||
.page-layout {
|
||||
display: flex;
|
||||
background-color: #f7f7f7;
|
||||
|
|
|
@ -1 +1 @@
|
|||
{"version":3,"sourceRoot":"","sources":["index.scss"],"names":[],"mappings":";AAAA;AAEA;EACI;EACA;EACA;EACA;;;AAIJ;EACI;EACA;;;AAGJ;EACI;;;AAGJ;EACI;;;AAGJ;AAAA;EAGI;EACA;;;AAGJ;EACI;EACA;EACA;;;AAGJ;EACI;EACA;;;AAGJ;AAAA;EAEI;;;AAGJ;EACI;;;AAiBJ;EACI,cAfM;EAgBN,cAbY;EAcZ,aAbW;EAcX,WAbS;EAcT,cAbY;;;AAkBhB;EACI;;;AAGJ;EACI;;;AAGJ;EACI;EACA;EACA;EACA;EACA;;AAEA;EACI;EACA;EACA;EACA;;AAGJ;EACI;EACA;EACA;EACA;;AAGJ;EACI;;AAGJ;EACI;EACA;;AAGJ;EACI;EACA;EACA;EACA;;AAGJ;EACI;EACA;EACA;EACA;EACA;EACA;EACA;;AAGJ;EACI;EACA;EACA;EACA;EACA;;AAEA;EACI;EACA;EACA;EACA;;AAIR;EACI;IACI;IACA;IACA;IACA;;EAIJ;IACI;;EAIA;IACI;;EAGJ;IACI;;;AAKZ;EAEI;AAAA;IAEI;;EAGJ;IACI;;EAIA;IACI;;EAGJ;IACI;;;;AAMhB;EACI;EACA;EACA;;AAEA;EACI;EACA;EACA;EACA;EACA;;AAEA;EACI;EACA;;AAGJ;EACI;EACA;;AAGJ;EACI;EACA;EACA;EACA;EACA;EACA;;AAIR;EACI;;;AAIR;EACI;;;AAGJ;EACI;EACA;EACA;EACA;EACA;;AAEA;EACI;EACA;EACA;EACA;EACA;EACA;EACA;;AAEA;EACI;EACA;;AAIR;EACI;;AAGJ;EACI;EACA;;AAEA;EACI;EACA;EACA;EACA;EACA;EACA;EACA;;AAEA;EACI;;AAEA;EACI;;AAMhB;EACI;EACA;;AAEA;EACI;EACA;;AAGJ;EACI;EACA;EACA;;AAGJ;EACI;EACA;;AAGJ;EACI;;;AAMZ;EACI;;AAEA;EACI;EACA;EACA;;AAEA;EACI;EACA;EACA;EACA;EACA;EACA;;AAEA;EACI;EACA;EACA;;AAGJ;EACI,OAvRA;EAwRA;;AAGJ;EACI;;;AAQR;EACI;;AAGJ;EACI;;AAIR;EACI;EACA;;AAEA;EACI;;AAGJ;EACI;EACA;;AAIR;EACI;EACA;EACA;;AAEA;EACI;EACA;EACA;;AAKJ;EACI;;AAEA;EACI;EACA;EACA;EACA;EACA;;AAEA;EACI;;AAOZ;EACI;EACA;EACA;;AAEA;EACI;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;;AAEA;EACI;;AAMhB;EACI;EACA;;AAEA;EACI;;AAIR;EACI;;AAEA;EACI;;AAGJ;EACI;EACA;;;AAKZ;AAAA;AAAA;AAAA;EAII;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;;;AAGJ;EACI;EACA;EACA;EACA;;AAEA;EAEI;EACA;EACA;EACA;EACA;EACA;;AAEA;EACI;;AAIR;EACI;;AAGJ;EACI;;AAGJ;EACI;EACA;EACA;EACA;EACA;;AAEA;EACI;;AAIR;EACI;EACA;EACA;EACA;EACA;;AAGJ;EACI;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;;AAEA;EACI;;AAGJ;EACI;EACA;EACA;EACA;EACA;EACA;EACA;;AAEA;EACI,OAheD;;AAqeH;EACI;;AAKJ;EACI,OA9eA;;AAifJ;EACI,kBAlfA;;AAsfR;EACI;;;AAKZ;EACI;EACA;;AAEA;EACI;EACA;;AAGJ;EACI;;AAKI;EAEI;EACA;;AAIR;EAGI;EACA;EACA;EACA;;AAEA;EACI;EACA;;AAGJ;EACI;EACA;EACA;;AAMA;EACI;EACA;;;AAOpB;EACI;;AAKY;EACI;EACA;;AAEA;EACI;EACA;;AAKZ;EACI;EACA;;AAEA;EACI;EACA;;;AAOpB;EACI;;AAGI;EACI;EACA;EACA;EACA;;AAIR;EACI;EACA;EACA;;;AAIR;EACI;;;AAGJ;EACI","file":"index.css"}
|
||||
{"version":3,"sourceRoot":"","sources":["index.scss"],"names":[],"mappings":";AAAA;AAEA;EACI;EACA;EACA;EACA;;;AAIJ;EACI;EACA;;;AAGJ;EACI;;;AAGJ;EACI;;;AAGJ;AAAA;EAEI;EACA;;;AAGJ;EACI;EACA;EACA;;;AAGJ;EACI;EACA;;;AAGJ;AAAA;EAEI;;;AAGJ;EACI;;;AAiBJ;EACI,cAfM;EAgBN,cAbY;EAcZ,aAbW;EAcX,WAbS;EAcT,cAbY;;;AAkBhB;EACI;;;AAGJ;EACI;;;AAGJ;EACI;EACA;;;AAGJ;AAAA;AAAA;AAAA;EAII;EACA;;;AAGJ;AAAA;EAEI;;;AAGJ;AAAA;EAEI;;;AAGJ;EACI;EACA;EACA;;;AAGJ;EACI;EACA;EACA;EACA;EACA;;AAEA;EACI;EACA;EACA;EACA;;AAGJ;EACI;EACA;EACA;EACA;;AAGJ;EACI;;AAGJ;EACI;EACA;EACA;;AAGJ;EACI;EACA;EACA;EACA;;AAGJ;EACI;EACA;EACA;EACA;EACA;EACA;EACA;;AAGJ;EACI;EACA;EACA;EACA;EACA;;AAEA;EACI;EACA;EACA;EACA;;AAIR;EACI;IACI;IACA;IACA;IACA;;EAIJ;IACI;;EAIA;IACI;;EAGJ;IACI;;;AAKZ;EAEI;AAAA;IAEI;;EAGJ;IACI;;EAIA;IACI;;EAGJ;IACI;;;;AAMhB;EACI;EACA;EACA;;AAEA;EACI;EACA;EACA;EACA;EACA;;AAEA;EACI;EACA;;AAGJ;EACI;EACA;;AAGJ;EACI;EACA;EACA;EACA;EACA;EACA;;AAIR;EACI;;;AAIR;EACI;;;AAGJ;EACI;EACA;EACA;EACA;EACA;;AAEA;EACI;EACA;EACA;EACA;EACA;EACA;EACA;;AAEA;EACI;EACA;;AAIR;EACI;;AAGJ;EACI;EACA;;AAEA;EACI;EACA;EACA;EACA;EACA;EACA;EACA;;AAEA;EACI;;AAEA;EACI;;AAMhB;EACI;EACA;;AAEA;EACI;EACA;;AAGJ;EACI;EACA;EACA;;AAGJ;EACI;EACA;;AAGJ;EACI;;;AAMZ;EACI;;AAEA;EACI;EACA;EACA;;AAEA;EACI;EACA;EACA;EACA;EACA;EACA;;AAEA;EACI;EACA;EACA;;AAGJ;EACI,OArTA;EAsTA;;AAGJ;EACI;;;AAQR;EACI;;AAGJ;EACI;;AAIR;EACI;EACA;;AAEA;EACI;;AAGJ;EACI;EACA;;AAIR;EACI;EACA;EACA;;AAEA;EACI;EACA;EACA;;AAKJ;EACI;;AAEA;EACI;EACA;EACA;EACA;EACA;;AAEA;EACI;;AAOZ;EACI;EACA;EACA;;AAEA;EACI;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;;AAEA;EACI;;AAMhB;EACI;EACA;;AAEA;EACI;;AAIR;EACI;;AAEA;EACI;;AAGJ;EACI;EACA;;;AAKZ;AAAA;AAAA;AAAA;EAII;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;;;AAGJ;EACI;EACA;EACA;EACA;;AAEA;EAEI;EACA;EACA;EACA;EACA;EACA;;AAEA;EACI;;AAIR;EACI;;AAGJ;EACI;;AAGJ;EACI;EACA;EACA;EACA;EACA;;AAEA;EACI;;AAIR;EACI;EACA;EACA;EACA;EACA;;AAGJ;EACI;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;;AAEA;EACI;;AAGJ;EACI;EACA;EACA;EACA;EACA;EACA;EACA;;AAEA;EACI,OA/fD;;AAogBH;EACI;;AAKJ;EACI,OA7gBA;;AAghBJ;EACI,kBAjhBA;;AAqhBR;EACI;;;AAKZ;EACI;EACA;;AAEA;EACI;EACA;;AAGJ;EACI;;AAKI;EAEI;EACA;;AAIR;EAGI;EACA;EACA;EACA;;AAEA;EACI;EACA;;AAGJ;EACI;EACA;EACA;;AAMA;EACI;EACA;;;AAOpB;EACI;;AAKY;EACI;EACA;;AAEA;EACI;EACA;;AAKZ;EACI;EACA;;AAEA;EACI;EACA;;;AAOpB;EACI;;AAGI;EACI;EACA;EACA;EACA;;AAIR;EACI;EACA;EACA;;;AAIR;EACI;;;AAGJ;EACI","file":"index.css"}
|
|
@ -22,8 +22,7 @@
|
|||
}
|
||||
|
||||
html,
|
||||
body
|
||||
{
|
||||
body {
|
||||
height: 100%;
|
||||
width: 100%;
|
||||
}
|
||||
|
@ -80,6 +79,35 @@ $--font-path: "../lib/theme-chalk/fonts";
|
|||
clear: both
|
||||
}
|
||||
|
||||
body[data-theme='dark'] {
|
||||
background-color: #1c1e2f;
|
||||
color: #8c909a;
|
||||
}
|
||||
|
||||
[data-theme=dark] .page-layout__process,
|
||||
[data-theme=dark] .app-process__left,
|
||||
[data-theme=dark] .app-process__right,
|
||||
[data-theme=dark] .app-process__item {
|
||||
background-color: #292B3D;
|
||||
color: #8c909a;
|
||||
}
|
||||
|
||||
[data-theme=dark] .app-process__item,
|
||||
[data-theme=dark] .page-layout__process {
|
||||
border-color: #8c909a;
|
||||
}
|
||||
|
||||
[data-theme=dark] .app-process__item.active span,
|
||||
[data-theme=dark] .app-process__item .el-icon-close {
|
||||
color: #ddd;
|
||||
}
|
||||
|
||||
[data-theme=dark] .el-dropdown-menu {
|
||||
background-color: #1c1e2f;
|
||||
color: #8c909a;
|
||||
border-color: #8c909a;
|
||||
}
|
||||
|
||||
.page-layout {
|
||||
display: flex;
|
||||
background-color: #f7f7f7;
|
||||
|
|
Loading…
Reference in New Issue