【fix ESLint】src/components/AvatarList

This commit is contained in:
danshihao
2023-03-03 10:10:10 +08:00
parent 159a262ac9
commit 2820d112d6
2 changed files with 2 additions and 3 deletions
+1 -1
View File
@@ -34,7 +34,7 @@ export default {
}, },
computed: { computed: {
avatarSize () { avatarSize () {
return this.size !== 'mini' && this.size || 20 return ((this.size !== 'mini') && this.size) || 20
} }
}, },
watch: { watch: {
+1 -2
View File
@@ -74,10 +74,9 @@ export default {
items = items.slice(0, this.maxLength) items = items.slice(0, this.maxLength)
items.push((<Avatar size={ this.size } style={ this.excessItemsStyle }>{`+${this.maxLength}`}</Avatar>)) items.push((<Avatar size={ this.size } style={ this.excessItemsStyle }>{`+${this.maxLength}`}</Avatar>))
} }
const itemList = items.map((item) => ( return items.map((item) => (
<li class={ classString }>{ item }</li> <li class={ classString }>{ item }</li>
)) ))
return itemList
} }
}, },
render () { render () {