fix(components): [el-tree-v2] empty-text supports empty string & virtual list width become no required (#4144)

This commit is contained in:
msidolphin 2021-11-01 15:05:04 +08:00 committed by GitHub
parent fb8fc98c63
commit 974e9d563f
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
3 changed files with 3 additions and 3 deletions

View File

@ -80,7 +80,7 @@ export default defineComponent({
})
const icon = computed(() => {
return tree?.props.icon ? tree.props.icon : DEFAULT_ICON
return tree?.props.icon ?? DEFAULT_ICON
})
const handleClick = () => {

View File

@ -35,7 +35,7 @@
</fixed-size-list>
<div v-else class="el-tree__empty-block">
<span class="el-tree__empty-text">{{
emptyText || t('el.tree.emptyText')
emptyText ?? t('el.tree.emptyText')
}}</span>
</div>
</div>

View File

@ -88,7 +88,7 @@ export const virtualizedProps = buildProps({
width: {
type: [Number, String],
required: true,
required: false,
},
perfMode: {