| 
					
				 | 
			
			
				@@ -1,7 +1,6 @@ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				 <template> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				   <div :class="['tool-list', 'tool-' + direction]"> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-    <!-- <div class="tool-item text active">首页</div> --> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-    <div :class="['tool-item',{'text':item.name==='home'}]" v-for="(item,index) in list" :key="index" @click="handleActive(item,index)">{{item.title}}</div> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+    <div :class="['tool-item',{'text':item.name==='home'},{active:index===active}]" v-for="(item,index) in list" :key="index" @click="handleActive(item,index)">{{item.title}}</div> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				   </div> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				 </template> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				  
			 | 
		
	
	
		
			
				| 
					
				 | 
			
			
				@@ -10,7 +9,7 @@ import {ref} from 'vue' 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				 const props = defineProps({ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				   direction: { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				     type: String, 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-    defalut: "left", 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+    defalut: "", 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				   }, 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				   list: { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				     type: Array, 
			 | 
		
	
	
		
			
				| 
					
				 | 
			
			
				@@ -18,9 +17,9 @@ const props = defineProps({ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				   }, 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				 }); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				  
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-const active = ref('home') 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-const handleActive = (i,v) =>{ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-     
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+const active = ref(0) 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+const handleActive = (value,index) =>{ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+    active.value = index 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				 } 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				 </script> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				  
			 | 
		
	
	
		
			
				| 
					
				 | 
			
			
				@@ -30,7 +29,6 @@ const handleActive = (i,v) =>{ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				   height: 100%; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				   background: #232323; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				   border: 0.6px solid rgb(255, 255, 255, 0.4); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-  border-left: none; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				   box-sizing: border-box; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				   border-radius: 4px; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				   display: flex; 
			 | 
		
	
	
		
			
				| 
					
				 | 
			
			
				@@ -39,9 +37,11 @@ const handleActive = (i,v) =>{ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				   position: relative; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				   &.tool-left { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				     margin-right: 10px; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+    border-left: none; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				   } 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				   &.tool-right { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				     margin-left: 10px; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+    border-right: none; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				   } 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				   .tool-item { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				     font-size: 20px; 
			 | 
		
	
	
		
			
				| 
					
				 | 
			
			
				@@ -53,11 +53,16 @@ const handleActive = (i,v) =>{ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				     color: #B9B9B9; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				     font-family: "PangMenZhengDao"; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				     cursor: pointer; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+    height: 100%; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+    text-align: center; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+    &.tool-item:first-child{ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+        border-radius: 4px 4px 0 0; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+    } 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+    &.tool-item:last-child{ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+        border-radius: 0 0 4px 4px; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+    } 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				     &.text{ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				         writing-mode:horizontal-tb; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-        position: absolute; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-        top: 0; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-        border-radius: 4px 4px 0 0; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				         height: 40px; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				         line-height: 40px; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				         letter-spacing: 1px; 
			 |