From 082d9b64ad9bd5e45f0571b7bb042b30007189ac Mon Sep 17 00:00:00 2001
From: wujingjing <gersonwu@qq.com>
Date: 星期五, 14 三月 2025 17:33:43 +0800
Subject: [PATCH] cursor-default

---
 src/layout/component/sidebar/Sidebar.vue |   40 +++++++++++++++++++++++++++++-----------
 1 files changed, 29 insertions(+), 11 deletions(-)

diff --git a/src/layout/component/sidebar/Sidebar.vue b/src/layout/component/sidebar/Sidebar.vue
index 456a508..427bbe4 100644
--- a/src/layout/component/sidebar/Sidebar.vue
+++ b/src/layout/component/sidebar/Sidebar.vue
@@ -1,16 +1,17 @@
 <template>
-	<div class="pc-chat_aside flex-0" >
+	<div class="pc-chat_aside flex-0 relative" :style="`width: ${leftBox}px;transition: 0.7s ease-in;`">
 		<div class="aside_top">
 			<div class="logo flex-items-center justify-between">
 				<div class="flex items-center">
 					<img src="/static/images/logo/logoWithNoName.png" alt="logo" class="layout-logo-medium-img" />
-					<span class="font-extrabold text-xl text-white tracking-wide"> WI 姘村姟鏅鸿兘骞冲彴</span>
+					<span class="font-extrabold text-xl text-white tracking-wide"> WI 姘村姟鏅鸿兘鍔╂墜</span>
 				</div>
-				<el-tooltip content="鏀惰捣渚ф爮" placement="right" effect="dark">
-					<span class="ywifont ywicon-cebianlan text-gray-200 active:text-gray-300 !text-[20px] cursor-pointer" @click="toggleSidebar"></span>
-				</el-tooltip>
 			</div>
 		</div>
+		<div class="hide-sidebar" @click="toggleSidebar" v-if="!isSharePage">
+			<i class="text-[#fff] transition-all ywifont ywicon-zuoyoujiantou"></i>
+		</div>
+
 		<div class="aside_center">
 			<ChatRecord />
 		</div>
@@ -21,14 +22,16 @@
 </template>
 
 <script setup lang="ts">
+import { computed } from 'vue';
 import ChatRecord from './components/ChatRecord.vue';
 import MenuList from './components/MenuList.vue';
-const emit = defineEmits(['toggleSidebar'])
+import { isSharePage } from '/@/stores/chatRoom';
+const emit = defineEmits(['toggleSidebar']);
 
 const prop = defineProps(['isShow']);
-
+const leftBox = computed(() => (prop.isShow ? 252 : 198));
 const toggleSidebar = () => {
-	emit('toggleSidebar',false)
+	emit('toggleSidebar', false);
 };
 </script>
 
@@ -45,10 +48,10 @@
 	font-family: 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
 }
 .pc-chat_aside {
-	width: 252px !important;
+	// width: 252px !important;
 	height: 100%;
 	box-sizing: border-box;
-	background-color: #1b1d1c;
+	background-color: var(--color-bg-side);
 	overflow: visible;
 	-webkit-transition: width 0.1s ease-in;
 	-o-transition: width 0.1s ease-in;
@@ -56,6 +59,22 @@
 	position: relative;
 	display: flex;
 	flex-direction: column;
+}
+.hide-sidebar {
+	width: 20px;
+	height: 48px;
+	background: rgba(0, 0, 0, 0.2);
+	position: absolute;
+	top: 50%;
+	right: 0px;
+	transform: translate(100%, -50%);
+	z-index: 9;
+	cursor: pointer;
+	display: flex;
+	align-items: center;
+	justify-content: center;
+	padding: 0 3px;
+	border-radius: 0px 5px 5px;
 }
 .aside_top {
 	box-sizing: border-box;
@@ -87,5 +106,4 @@
 	-ms-flex-direction: column;
 	flex-direction: column;
 }
-
 </style>

--
Gitblit v1.9.3