mirror of
https://github.com/TeaOSLab/EdgeAdmin.git
synced 2025-11-03 20:40:26 +08:00
优化界面
This commit is contained in:
@@ -26,6 +26,7 @@ func (this *Tabbar) Add(name string, subName string, url string, icon string, ac
|
||||
"icon": icon,
|
||||
"active": active,
|
||||
"right": false,
|
||||
"isTitle": false,
|
||||
}
|
||||
this.items = append(this.items, m)
|
||||
return m
|
||||
|
||||
@@ -58,7 +58,11 @@ func (this *ClusterHelper) BeforeAction(actionPtr actions.ActionWrapper) (goNext
|
||||
}
|
||||
|
||||
var tabbar = actionutils.NewTabbar()
|
||||
tabbar.Add("集群列表", "", "/clusters", "left arrow", false)
|
||||
tabbar.Add("", "", "/clusters", "arrow left", false)
|
||||
{
|
||||
var item = tabbar.Add(cluster.Name, "", "/clusters/cluster?clusterId="+clusterIdString, "", true)
|
||||
item["isTitle"] = true
|
||||
}
|
||||
if teaconst.IsPlus {
|
||||
tabbar.Add("集群看板", "", "/clusters/cluster/boards?clusterId="+clusterIdString, "chart line area", selectedTabbar == "board")
|
||||
}
|
||||
|
||||
@@ -107,7 +107,11 @@ func (this *ServerHelper) createLeftMenu(action *actions.ActionObject) {
|
||||
// TABBAR
|
||||
selectedTabbar, _ := action.Data["mainTab"]
|
||||
var tabbar = actionutils.NewTabbar()
|
||||
tabbar.Add("网站列表", "", "/servers", "left arrow", false)
|
||||
tabbar.Add("", "", "/servers", "left arrow", false)
|
||||
if len(serverConfig.Name) > 0 {
|
||||
var item = tabbar.Add(serverConfig.Name, "", "/servers/server?serverId="+serverIdString, "", true)
|
||||
item["isTitle"] = true
|
||||
}
|
||||
|
||||
if teaconst.IsPlus {
|
||||
tabbar.Add("看板", "", "/servers/server/boards?serverId="+serverIdString, "dashboard", selectedTabbar == "board")
|
||||
|
||||
@@ -607,8 +607,19 @@ body.expanded .main {
|
||||
.main .tab-menu .item .icon {
|
||||
margin-left: 0.6em;
|
||||
}
|
||||
.main .tab-menu .item.active {
|
||||
.main .tab-menu .item.active.title {
|
||||
background: #f8f8f9 !important;
|
||||
font-weight: normal !important;
|
||||
margin-right: 1em !important;
|
||||
}
|
||||
.main .tab-menu .item.active:not(.title) {
|
||||
font-weight: normal !important;
|
||||
border: none;
|
||||
border-radius: 0 !important;
|
||||
color: #2185d0 !important;
|
||||
}
|
||||
.main .tab-menu .item.active.blue {
|
||||
font-weight: bold !important;
|
||||
}
|
||||
.main .tab-menu::-webkit-scrollbar {
|
||||
height: 4px;
|
||||
|
||||
File diff suppressed because one or more lines are too long
@@ -107,7 +107,7 @@
|
||||
<div class="main" :class="{'without-menu':teaSubMenus.menus == null || teaSubMenus.menus.length == 0 || (teaSubMenus.menus.length == 1 && teaSubMenus.menus[0].alwaysActive), 'without-secondary-menu':teaSubMenus.alwaysMenu == null || teaSubMenus.alwaysMenu.items.length <= 1, 'without-footer':!teaShowOpenSourceInfo}" v-cloak="">
|
||||
<!-- 操作菜单 -->
|
||||
<div class="ui top menu tabular tab-menu small" v-if="teaTabbar.length > 0">
|
||||
<a class="item" v-for="item in teaTabbar" :class="{'active':item.active,right:item.right}" :href="item.url">
|
||||
<a class="item" v-for="item in teaTabbar" :class="{'active':item.active, right:item.right, title: item.isTitle}" :href="item.url">
|
||||
<var>{{item.name}}<span v-if="item.subName.length > 0">({{item.subName}})</span><i class="icon small" :class="item.icon" v-if="item.icon != null && item.icon.length > 0"></i> </var>
|
||||
</a>
|
||||
</div>
|
||||
|
||||
@@ -600,8 +600,21 @@ body.expanded .main {
|
||||
}
|
||||
}
|
||||
|
||||
.item.active {
|
||||
.item.active.title {
|
||||
background: #f8f8f9 !important;
|
||||
font-weight: normal !important;
|
||||
margin-right: 1em !important;
|
||||
}
|
||||
|
||||
.item.active:not(.title) {
|
||||
font-weight: normal !important;
|
||||
border: none;
|
||||
border-radius: 0 !important;
|
||||
color: #2185d0 !important;
|
||||
}
|
||||
|
||||
.item.active.blue {
|
||||
font-weight: bold !important;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user