@@@@@@
This commit is contained in:
32
library/components/VabFold/index.vue
Normal file
32
library/components/VabFold/index.vue
Normal file
@@ -0,0 +1,32 @@
|
||||
<template>
|
||||
<vab-icon class="fold-unfold" :icon="collapse ? unfold : fold" @click="toggleCollapse" />
|
||||
</template>
|
||||
|
||||
<script setup>
|
||||
import { useSettingsStore } from '/@/store/modules/settings'
|
||||
|
||||
defineOptions({
|
||||
name: 'VabFold',
|
||||
})
|
||||
|
||||
defineProps({
|
||||
unfold: {
|
||||
type: String,
|
||||
default: 'menu-unfold-line',
|
||||
},
|
||||
fold: {
|
||||
type: String,
|
||||
default: 'menu-fold-line',
|
||||
},
|
||||
})
|
||||
const settingsStore = useSettingsStore()
|
||||
const { collapse } = storeToRefs(settingsStore)
|
||||
const { toggleCollapse } = settingsStore
|
||||
</script>
|
||||
|
||||
<style lang="scss" scoped>
|
||||
.fold-unfold {
|
||||
color: var(--el-color-grey);
|
||||
cursor: pointer;
|
||||
}
|
||||
</style>
|
||||
Reference in New Issue
Block a user