refactor(系统布局): 布局样式优化,去除滑出延时动画

This commit is contained in:
fit2-zhao 2022-06-30 11:16:51 +08:00 committed by f2c-ci-robot[bot]
parent 1416f16959
commit 9ca3c0ba75
11 changed files with 25 additions and 21 deletions

View File

@ -116,7 +116,7 @@ export default {
return arr; return arr;
}, },
getUserPermissionProjectIds(){ getUserPermissionProjectIds(){
this.$get('/project/getOwnerProjectIds/', res => { this.$get('/project/getOwnerProjectIds', res => {
this.permissionProjectIds = res.data; this.permissionProjectIds = res.data;
}) })
}, },

View File

@ -1,6 +1,6 @@
<template> <template>
<el-dropdown size="medium" @command="handleCommand" class="align-right"> <el-dropdown size="medium" @command="handleCommand" class="align-right">
<span class="dropdown-link global"> <span class="dropdown-link">
{{ currentUser.name }}<i class="el-icon-caret-bottom el-icon--right"/> {{ currentUser.name }}<i class="el-icon-caret-bottom el-icon--right"/>
</span> </span>
<template v-slot:dropdown> <template v-slot:dropdown>
@ -105,7 +105,6 @@ export default {
.dropdown-link { .dropdown-link {
cursor: pointer; cursor: pointer;
font-size: 12px; font-size: 12px;
color: rgb(245, 245, 245);
line-height: 40px; line-height: 40px;
} }
@ -113,10 +112,6 @@ export default {
float: right; float: right;
margin-right: 20px; margin-right: 20px;
} }
.global {
color: var(--color);
}
</style> </style>

View File

@ -4,7 +4,7 @@
'PROJECT_API_DEFINITION:READ','PROJECT_API_SCENARIO:READ','PROJECT_API_REPORT:READ', 'PROJECT_API_DEFINITION:READ','PROJECT_API_SCENARIO:READ','PROJECT_API_REPORT:READ',
'PROJECT_USER:READ', 'PROJECT_ENVIRONMENT:READ', 'PROJECT_FILE:READ+JAR', 'PROJECT_FILE:READ+FILE', 'PROJECT_OPERATING_LOG:READ', 'PROJECT_CUSTOM_CODE:READ', 'PROJECT_USER:READ', 'PROJECT_ENVIRONMENT:READ', 'PROJECT_FILE:READ+JAR', 'PROJECT_FILE:READ+FILE', 'PROJECT_OPERATING_LOG:READ', 'PROJECT_CUSTOM_CODE:READ',
'PROJECT_PERFORMANCE_TEST:READ','PROJECT_PERFORMANCE_REPORT:READ','WORKSPACE_USER:READ']" > 'PROJECT_PERFORMANCE_TEST:READ','PROJECT_PERFORMANCE_REPORT:READ','WORKSPACE_USER:READ']" >
<span class="dropdown-link global"> <span class="dropdown-link">
{{ currentWorkspaceName }} {{ currentWorkspaceName }}
<i class="el-icon-caret-bottom el-icon--right"/> <i class="el-icon-caret-bottom el-icon--right"/>
</span> </span>
@ -180,7 +180,6 @@ export default {
.dropdown-link { .dropdown-link {
cursor: pointer; cursor: pointer;
font-size: 12px; font-size: 12px;
color: rgb(245, 245, 245);
line-height: 40px; line-height: 40px;
padding-right: 10px; padding-right: 10px;
padding-left: 5px; padding-left: 5px;

View File

@ -1,6 +1,6 @@
<template> <template>
<el-dropdown size="medium" @command="changeLanguage" class="align-right"> <el-dropdown size="medium" @command="changeLanguage" class="align-right">
<span class="dropdown-link global"> <span class="dropdown-link">
<font-awesome-icon :icon="['fas', 'language']" size="lg"/> <font-awesome-icon :icon="['fas', 'language']" size="lg"/>
</span> </span>
<template v-slot:dropdown> <template v-slot:dropdown>
@ -83,7 +83,6 @@ export default {
.dropdown-link { .dropdown-link {
cursor: pointer; cursor: pointer;
font-size: 12px; font-size: 12px;
color: rgb(245, 245, 245);
line-height: 40px; line-height: 40px;
padding-right: 20px; padding-right: 20px;
} }

View File

@ -1,11 +1,11 @@
<template> <template>
<el-menu <el-menu
class="ms-menu-vertical ms-menu" class="ms-menu-vertical ms-menu horizontal-collapse-transition"
:collapse="isCollapse"
:background-color="color"
text-color="#F2F2F2" text-color="#F2F2F2"
active-text-color="#fff" active-text-color="#fff"
:key="menuKey" :key="menuKey"
:collapse="isCollapse"
:background-color="color"
router> router>
<el-menu-item> <el-menu-item>
<div> <div>
@ -30,7 +30,7 @@ export default {
}, },
computed: { computed: {
title() { title() {
return localStorage.getItem("title") || "MeterSphere"; return localStorage.getItem("sysTitle") || "MeterSphere";
} }
}, },
props: { props: {
@ -65,7 +65,7 @@ export default {
text-overflow: ellipsis; text-overflow: ellipsis;
vertical-align: middle; vertical-align: middle;
white-space: nowrap; white-space: nowrap;
width: 98px; width: 105px;
} }
/deep/ .el-menu-item { /deep/ .el-menu-item {
@ -89,4 +89,8 @@ export default {
background-repeat: no-repeat; background-repeat: no-repeat;
background-position: 50% center; background-position: 50% center;
} }
.horizontal-collapse-transition {
transition: 0s width ease-in-out, 0s padding-left ease-in-out, 0s padding-right ease-in-out;
}
</style> </style>

View File

@ -1,12 +1,13 @@
<template> <template>
<el-menu menu-trigger="click" <el-menu menu-trigger="click"
class="ms-menu-vertical ms-menu ms-menu-title" :collapse="isCollapse" class="ms-menu-vertical ms-menu ms-menu-title horizontal-collapse-transition"
:background-color="color"
text-color="#F2F2F2" text-color="#F2F2F2"
active-text-color="#fff" active-text-color="#fff"
:collapse="isCollapse"
:background-color="color"
:default-active="activeIndex" :default-active="activeIndex"
@select="handleSelect"
:key="menuKey" :key="menuKey"
@select="handleSelect"
router> router>
<el-menu-item index="/workstation" v-xpack v-if="check('workstation')"> <el-menu-item index="/workstation" v-xpack v-if="check('workstation')">
<div> <div>
@ -212,4 +213,7 @@ export default {
color: #fff !important; color: #fff !important;
} }
.horizontal-collapse-transition {
transition: 0s width ease-in-out, 0s padding-left ease-in-out, 0s padding-right ease-in-out;
}
</style> </style>

View File

@ -219,7 +219,7 @@ export default {
} }
.global { .global {
color: var(--color); color: rgb(146, 147, 150);
} }
.header-top-menu { .header-top-menu {

View File

@ -484,7 +484,7 @@ export default {
} }
.global { .global {
color: var(--color); color: rgb(96,98,102);
} }
.header-top-menu { .header-top-menu {

View File

@ -517,6 +517,7 @@ export default {
loginImage: 'Picture on the right side of the login page', loginImage: 'Picture on the right side of the login page',
loginTitle: 'Login page prompt information', loginTitle: 'Login page prompt information',
pageTitle: 'Page Title', pageTitle: 'Page Title',
sysTitle: 'System Name',
}, },
system_config: { system_config: {
base_config: 'Base Config', base_config: 'Base Config',

View File

@ -522,6 +522,7 @@ export default {
loginImage: '登陆页面右侧图片', loginImage: '登陆页面右侧图片',
loginTitle: '登陆页面提示信息', loginTitle: '登陆页面提示信息',
pageTitle: '页面 Title', pageTitle: '页面 Title',
sysTitle: '系统名称',
}, },
system_config: { system_config: {
base_config: '基本配置', base_config: '基本配置',

View File

@ -519,6 +519,7 @@ export default {
loginImage: '登陸頁面右側圖片', loginImage: '登陸頁面右側圖片',
loginTitle: '登陸頁面提示信息', loginTitle: '登陸頁面提示信息',
pageTitle: '頁面 Title', pageTitle: '頁面 Title',
sysTitle: '系統名稱',
}, },
system_config: { system_config: {
base_config: '基本配置', base_config: '基本配置',