diff --git a/frontend/src/layout/components/Sidebar/components/Collapse.vue b/frontend/src/layout/components/Sidebar/components/Collapse.vue
index 453dddaf7..98d6ca068 100644
--- a/frontend/src/layout/components/Sidebar/components/Collapse.vue
+++ b/frontend/src/layout/components/Sidebar/components/Collapse.vue
@@ -2,7 +2,7 @@
{
display: flex;
align-items: center;
box-sizing: border-box;
- border-bottom: 1px solid var(--panel-footer-border);
+ border-top: 1px solid var(--panel-footer-border);
height: 48px;
.icon {
margin-left: 25px;
diff --git a/frontend/src/layout/components/Sidebar/index.vue b/frontend/src/layout/components/Sidebar/index.vue
index 5d3ebefd6..b1f4685dc 100644
--- a/frontend/src/layout/components/Sidebar/index.vue
+++ b/frontend/src/layout/components/Sidebar/index.vue
@@ -10,14 +10,6 @@
-
-
-
+
+
-
- {{ currentUser.name }}
-
-
-
-
-
+
+
+
+
+
+
@@ -90,15 +84,6 @@ const { currentNode, isAdmin, menuAccordion, permissions } = useGlobalStore();
const version = ref();
const nodeSelectorRef = ref>();
const currentUser = ref();
-const userMenuVisible = ref(false);
-
-const handleUserCommand = (command: string) => {
- if (command === 'userCenter') {
- nodeSelectorRef.value?.openUserInfo();
- } else if (command === 'logout') {
- nodeSelectorRef.value?.logout();
- }
-};
const activeMenu = computed(() => {
const { meta, path } = route;
@@ -397,22 +382,18 @@ watch(
height: 20px !important;
}
-.user-dropdown {
+.user-actions {
+ display: flex;
flex-shrink: 0;
- width: 100%;
-}
+ border-top: 1px solid var(--panel-footer-border);
-.user-menu {
- min-width: 160px;
-
- :deep(.el-dropdown-menu__item) {
- gap: 8px;
- padding: 10px 16px;
+ &.is-collapsed .user-entry {
+ justify-content: center;
+ padding: 0;
}
- .user-menu-icon {
- flex-shrink: 0;
- font-size: 8px;
+ &.is-collapsed .logout-entry {
+ flex: 1;
}
}
@@ -420,13 +401,13 @@ watch(
display: flex;
align-items: center;
gap: 7px;
- flex-shrink: 0;
+ flex: 1;
+ min-width: 0;
position: relative;
- width: 100%;
height: 48px;
- padding: 0 25px;
+ padding: 0 0 0 25px;
border: 0;
- border-top: 1px solid var(--panel-footer-border);
+ border-radius: 0;
background: transparent;
color: var(--panel-main-bg-color-1);
font-family: inherit;
@@ -448,10 +429,28 @@ watch(
}
&:hover,
- &:focus-visible,
- &.is-active {
+ &:focus-visible {
color: var(--el-color-primary);
background: var(--el-menu-item-bg-color);
}
}
+.logout-entry {
+ flex: 0 0 42px;
+ justify-content: center;
+ padding: 0;
+ border-left: 1px solid var(--panel-footer-border);
+}
+
+
+