This repository has been archived on 2025-09-14. You can view files and clone it, but cannot push or open issues or pull requests.
Files
handingkang-ohmyweb/src/layout/components/Hamburger/index.vue

33 lines
533 B
Vue
Raw Normal View History

<!-- 折叠边栏按钮 -->
<template>
<div @click="toggleClick">
<el-icon :size="20" class="icon">
<fold v-if="isActive" />
<expand v-else />
</el-icon>
</div>
</template>
<script lang="ts" setup>
import { Expand, Fold } from '@element-plus/icons-vue'
defineProps({
isActive: {
type: Boolean,
default: false
}
})
const emit = defineEmits(['toggle-click'])
const toggleClick = () => {
emit('toggle-click')
}
</script>
<style lang="scss" scoped>
.icon {
vertical-align: middle;
}
</style>