mirror of
				https://github.com/pure-admin/vue-pure-admin.git
				synced 2025-11-03 13:44:47 +08:00 
			
		
		
		
	chore: update
This commit is contained in:
		
							parent
							
								
									1a39d0962e
								
							
						
					
					
						commit
						d5d7dd8e57
					
				@ -1,4 +1,5 @@
 | 
			
		||||
<script setup lang="ts">
 | 
			
		||||
import { ref } from "vue";
 | 
			
		||||
import { useNav } from "@/layout/hooks/useNav";
 | 
			
		||||
import MenuFold from "@iconify-icons/ri/menu-fold-fill";
 | 
			
		||||
import MenuUnfold from "@iconify-icons/ri/menu-unfold-fill";
 | 
			
		||||
@ -10,6 +11,8 @@ interface Props {
 | 
			
		||||
const props = withDefaults(defineProps<Props>(), {
 | 
			
		||||
  isActive: false
 | 
			
		||||
});
 | 
			
		||||
 | 
			
		||||
const visible = ref(false);
 | 
			
		||||
const { tooltipEffect } = useNav();
 | 
			
		||||
 | 
			
		||||
const emit = defineEmits<{
 | 
			
		||||
@ -25,6 +28,7 @@ const toggleClick = () => {
 | 
			
		||||
  <div class="container">
 | 
			
		||||
    <el-tooltip
 | 
			
		||||
      placement="right"
 | 
			
		||||
      :visible="visible"
 | 
			
		||||
      :effect="tooltipEffect"
 | 
			
		||||
      :content="props.isActive ? '点击折叠' : '点击展开'"
 | 
			
		||||
    >
 | 
			
		||||
@ -32,6 +36,8 @@ const toggleClick = () => {
 | 
			
		||||
        :icon="props.isActive ? MenuFold : MenuUnfold"
 | 
			
		||||
        class="cursor-pointer inline-block align-middle text-primary hover:text-primary dark:hover:!text-white w-[16px] h-[16px] ml-4 mb-1"
 | 
			
		||||
        @click="toggleClick"
 | 
			
		||||
        @mouseenter="visible = true"
 | 
			
		||||
        @mouseleave="visible = false"
 | 
			
		||||
      />
 | 
			
		||||
    </el-tooltip>
 | 
			
		||||
  </div>
 | 
			
		||||
 | 
			
		||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user