feat: 树

This commit is contained in:
wf 2024-07-03 13:02:39 +08:00
parent 63987a9441
commit d2ca32e1bf
4 changed files with 11 additions and 118 deletions

View File

@ -71,5 +71,9 @@
"vite": "^5.2.0",
"vite-plugin-svg-icons": "^2.0.1",
"vue-tsc": "^2.0.6"
},
"engines": {
"node": ">= 18.0.0",
"pnpm": ">=8.6.0"
}
}

View File

Before

Width:  |  Height:  |  Size: 667 B

After

Width:  |  Height:  |  Size: 667 B

View File

@ -5,7 +5,13 @@
<div class="left-box">
<a-scrollbar style="height: 100%; overflow: auto" outer-class="scrollbar">
<div class="left-tree-box">
<a-tree :data="treeData" :show-line="true"> </a-tree>
<a-tree :data="treeData" :show-line="true">
<template #icon="node">
<SvgIcon name="folder-close" :size="16" v-if="!node.isLeaf && !node.expanded"></SvgIcon>
<SvgIcon name="folder-open" :size="16" v-if="!node.isLeaf && node.expanded"></SvgIcon>
<SvgIcon name="txt" :size="16" v-if="node.isLeaf"></SvgIcon>
</template>
</a-tree>
</div>
</a-scrollbar>
</div>

File diff suppressed because one or more lines are too long