From c33d86179790b4508f68ad9b51e62393f86fd717 Mon Sep 17 00:00:00 2001 From: btea <2356281422@qq.com> Date: Sun, 31 Oct 2021 07:11:16 -0500 Subject: [PATCH] fix(components): [el-tree-v2] indent can not set zero (#3881) * fix(components): [el-tree-v2] indent can not set zero * chore: simplify code --- packages/components/tree-v2/src/tree-node.vue | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/components/tree-v2/src/tree-node.vue b/packages/components/tree-v2/src/tree-node.vue index ece4a7feb6..aaefa7956e 100644 --- a/packages/components/tree-v2/src/tree-node.vue +++ b/packages/components/tree-v2/src/tree-node.vue @@ -76,7 +76,7 @@ export default defineComponent({ const tree = inject(ROOT_TREE_INJECTION_KEY) const indent = computed(() => { - return tree?.props.indent || 16 + return tree?.props.indent ?? 16 }) const icon = computed(() => {