From 054cdefd40ac8963fac897e4fe98ffc1de4e0b69 Mon Sep 17 00:00:00 2001
From: inleft <inleft@qq.com>
Date: Wed, 17 Aug 2022 17:30:53 +0800
Subject: [PATCH] 重构消息盒子,优化表情组件

---
 src/components/group/tool.vue |   37 ++++++++++++++++++++++++++++++++++---
 1 files changed, 34 insertions(+), 3 deletions(-)

diff --git a/src/components/group/tool.vue b/src/components/group/tool.vue
index cb4ca7b..1e503fa 100644
--- a/src/components/group/tool.vue
+++ b/src/components/group/tool.vue
@@ -1,13 +1,20 @@
 <template>
 	<a-affix :offset-top="600">
 
-		<div style="padding-left:5px;">
+		<div style="padding-left:5px;" class="myButton">
 			<!-- <a-button @click="showDrawer1">
 				抽屉1
 			</a-button> -->
 			<!-- <a-button @click="showDrawer2">
 				抽屉2
 			</a-button> -->
+			
+			<a-button @click="showMessage">
+				<a-badge status="success">
+					消息
+				</a-badge>
+				<a-icon type="message" />
+			</a-button>
 			<a-button @click="showPreview">
 				预览
 				<a-icon type="youtube" />
@@ -22,6 +29,10 @@
 					<a-icon :type="iconType" />
 				</transition>
 			</a-button>
+			<a-button @click="addLink" v-if="showHidenButton">
+				加链
+				<a-icon type="smile" />
+			</a-button>
 
 			<!-- <a-button>
 				工具
@@ -32,15 +43,31 @@
 </template>
 
 <script>
+	import myConstant from "../../config/myConstant.js"
+
 	export default {
 		data() {
 			return {
 				iconType: "arrows-alt",
 				screen: false,
-				screenModel: "拉伸"
+				screenModel: "拉伸",
+				showHidenButton: false,
+			}
+		},
+		mounted() {
+			let tempVisitorData = localStorage.getItem(myConstant.visitorDataKey);
+			if (tempVisitorData != null && JSON.parse(tempVisitorData).nickName == myConstant.userName) {
+				//this.$message.info("认证成功..")
+				this.showHidenButton = true
 			}
 		},
 		methods: {
+			addLink() {
+				this.$emit('addLink')
+			},
+			showMessage() {
+				this.$emit('showMessage')
+			},
 			showModal() {
 				this.$emit('showModal')
 			},
@@ -63,5 +90,9 @@
 </script>
 
 <style lang="less">
-	
+	.myButton {
+		button {
+			min-width: 90px;
+		}
+	}
 </style>

--
Gitblit v1.9.1