新增了主题
This commit is contained in:
parent
73b24c5941
commit
6d6082b844
@ -82,34 +82,74 @@ layui.define(['laytpl', 'layer', 'element', 'util'], function (exports) {
|
||||
}, {
|
||||
logo: '#226A62'
|
||||
, header: '#2F9688'
|
||||
, headerCite: '#fff' // 头字体颜色
|
||||
, headerHover: '#fff' // 头移入颜色
|
||||
, alias: 'green-header' //墨绿头
|
||||
}, {
|
||||
main: '#344058'
|
||||
, logo: '#0085E8'
|
||||
, selected: '#1E9FFF'
|
||||
, header: '#1E9FFF'
|
||||
, headerCite: '#fff' // 头字体颜色
|
||||
, headerHover: '#fff' // 头移入颜色
|
||||
, alias: 'ocean-header' //海洋头
|
||||
}, {
|
||||
header: '#393D49'
|
||||
, headerCite: 'rgba(255, 255, 255, .8)' // 头字体颜色
|
||||
, headerHover: 'rgb(255, 255, 255)' // 头移入颜色
|
||||
, alias: 'classic-black-header' //经典黑头
|
||||
}, {
|
||||
main: '#50314F'
|
||||
, logo: '#50314F'
|
||||
, selected: '#7A4D7B'
|
||||
, header: '#50314F'
|
||||
, headerCite: 'rgba(255, 255, 255, .8)' // 头字体颜色
|
||||
, headerHover: 'rgb(255, 255, 255)' // 头移入颜色
|
||||
, alias: 'purple-red-header' //紫红头
|
||||
}, {
|
||||
main: '#28333E'
|
||||
, logo: '#28333E'
|
||||
, selected: '#AA3130'
|
||||
, header: '#AA3130'
|
||||
, headerCite: 'rgba(255, 255, 255, .8)' // 头字体颜色
|
||||
, headerHover: 'rgb(255, 255, 255)' // 头移入颜色
|
||||
, alias: 'fashion-red-header' //时尚红头
|
||||
}, {
|
||||
main: '#28333E'
|
||||
, logo: '#009688'
|
||||
, selected: '#009688'
|
||||
, header: '#009688'
|
||||
, headerCite: 'rgba(255, 255, 255, .8)' // 头字体颜色
|
||||
, headerHover: 'rgb(255, 255, 255)' // 头移入颜色
|
||||
, alias: 'green-header' //墨绿头
|
||||
}, {
|
||||
main: '#1E9FFF'
|
||||
, header: '#1E9FFF'
|
||||
, headerCite: 'rgba(255, 255, 255, .8)' // 头字体颜色
|
||||
, headerHover: 'rgb(255, 255, 255)' // 头移入颜色
|
||||
, alias: 'blue-header-menu' //蓝头蓝菜单
|
||||
}, {
|
||||
main: '#ededed' // 菜单背景颜色
|
||||
, mainFont: 'rgba(0, 0, 0, .8)' // 菜单字体颜色
|
||||
, mainSelected: '#1E9FFF' // 菜单选择背景颜色
|
||||
, mainSelectedFont: 'rgba(255, 255, 255, .8)' // 菜单选择背景字体颜色
|
||||
, logo: '#1E9FFF' // logo背景颜色
|
||||
, logoFont: 'rgba(255, 255, 255, .8)' // logo字体
|
||||
, header: '#1E9FFF' // 头背景颜色
|
||||
, selected: 'rgba(0, 0, 0, 1)' // 选中色
|
||||
, headerCite: 'rgba(255, 255, 255, .8)' // 头字体颜色
|
||||
, headerHover: 'rgb(255, 255, 255)' // 头移入颜色
|
||||
, alias: 'blue-header-grey-menu' //蓝头灰菜单
|
||||
}, {
|
||||
main: '#ffffff' // 菜单背景颜色
|
||||
, mainFont: 'rgba(0, 0, 0, .8)' // 菜单字体颜色
|
||||
, mainSelected: 'rgba(227,227,227,0.8)' // 菜单选择背景颜色
|
||||
, header: '#ffffff' // 头背景颜色
|
||||
, selected: 'rgba(217,217,217,0.8)' // 选中色
|
||||
, logoFont: 'rgba(0, 0, 0, .8)' // logo字体
|
||||
, headerCite: 'rgba(0, 0, 0, .8)' // 头字体颜色
|
||||
, headerHover: 'rgb(0, 0, 0)' // 头移入颜色
|
||||
, alias: 'white-header-menu' //蓝头灰菜单
|
||||
}]
|
||||
|
||||
//初始的颜色索引,对应上面的配色方案数组索引
|
||||
|
@ -200,9 +200,15 @@ layui.define('view', function (exports) {
|
||||
, '.layadmin-pagetabs .layui-tab-title li.layui-this:after,'
|
||||
, '.layui-layer-admin .layui-layer-title,'
|
||||
, '.layadmin-side-shrink .layui-side-menu .layui-nav>.layui-nav-item>.layui-nav-child'
|
||||
, '{background-color:{{d.color.main}} !important;}'
|
||||
, '{background-color:{{d.color.main}} !important; color:{{d.color.mainFont}} !important}'
|
||||
, '.layui-layer-admin i[close]{color:{{d.color.mainFont}} !important}'
|
||||
|
||||
//选中色
|
||||
, '.layui-nav-tree .layui-nav-item a{color:{{d.color.mainFont}} !important;}'
|
||||
, '.layui-nav-tree .layui-nav-item .layui-nav-more{border-color:{{d.color.mainFont}} transparent transparent !important;}'
|
||||
, '.layui-nav-tree .layui-nav-itemed>a .layui-nav-more{border-color:transparent transparent {{d.color.mainFont}} !important;}'
|
||||
, '.layui-nav-tree .layui-nav-itemed .layui-nav-child{background-color:{{d.color.mainSelected}} !important}'
|
||||
, '.layui-nav-tree .layui-nav-itemed .layui-nav-child a{color:{{d.color.mainSelectedFont}} !important}'
|
||||
, '.layui-nav-tree .layui-this,'
|
||||
, '.layui-nav-tree .layui-this>a,'
|
||||
, '.layui-nav-tree .layui-nav-child dd.layui-this,'
|
||||
@ -214,10 +220,11 @@ layui.define('view', function (exports) {
|
||||
|
||||
//头部色
|
||||
, '{{# if(d.color.header){ }}'
|
||||
, '.layui-layout-admin .layui-logo{color:{{ d.color.logoFont }};}'
|
||||
, '.layui-layout-admin .layui-header{background-color:{{ d.color.header }};}'
|
||||
, '.layui-layout-admin .layui-header a,'
|
||||
, '.layui-layout-admin .layui-header a cite{color: #f8f8f8;}'
|
||||
, '.layui-layout-admin .layui-header a:hover{color: #fff;}'
|
||||
, '.layui-layout-admin .layui-header a cite{color:{{d.color.headerCite}};}'
|
||||
, '.layui-layout-admin .layui-header a:hover{color:{{d.color.headerHover}};}'
|
||||
, '.layui-layout-admin .layui-header .layui-nav .layui-nav-more{border-top-color: #fbfbfb;}'
|
||||
, '.layui-layout-admin .layui-header .layui-nav .layui-nav-mored{border-color: transparent; border-bottom-color: #fbfbfb;}'
|
||||
, '.layui-layout-admin .layui-header .layui-nav .layui-this:after, .layui-layout-admin .layui-header .layui-nav-bar{background-color: #fff; background-color: rgba(255,255,255,.5);}'
|
||||
@ -225,7 +232,6 @@ layui.define('view', function (exports) {
|
||||
, '{{# } }}'
|
||||
].join('')).render(options = $.extend({}, local.theme, options))
|
||||
, styleElem = document.getElementById(id);
|
||||
|
||||
//添加主题样式
|
||||
if ('styleSheet' in style) {
|
||||
style.setAttribute('type', 'text/css');
|
||||
|
Loading…
Reference in New Issue
Block a user