user avatar cleanup
This commit is contained in:
parent
d4c0ccf659
commit
99886ac28c
2 changed files with 28 additions and 9 deletions
|
|
@ -14,12 +14,31 @@ library.add(
|
|||
)
|
||||
|
||||
const UserAvatar = {
|
||||
props: [
|
||||
'user',
|
||||
'compact',
|
||||
'showActorTypeIndicator',
|
||||
'url'
|
||||
],
|
||||
props: {
|
||||
// User object to show avatar of
|
||||
user: {
|
||||
required: true,
|
||||
type: Object
|
||||
},
|
||||
// Use less space and use alternative roundness
|
||||
compact: {
|
||||
required: false,
|
||||
type: Boolean,
|
||||
default: false
|
||||
},
|
||||
// Show small icon indicating if account is a bot or group
|
||||
showActorTypeIndicator : {
|
||||
required: false,
|
||||
type: Boolean,
|
||||
default: false
|
||||
},
|
||||
// Override avatar image URL, useful for profile editing
|
||||
url: {
|
||||
required: false,
|
||||
type: String,
|
||||
default: null
|
||||
}
|
||||
},
|
||||
data () {
|
||||
return {
|
||||
showPlaceholder: false,
|
||||
|
|
|
|||
|
|
@ -40,12 +40,12 @@
|
|||
|
||||
display: inline-block;
|
||||
position: relative;
|
||||
width: 48px;
|
||||
width: 3.5em;
|
||||
height: 48px;
|
||||
|
||||
&.-compact {
|
||||
width: 32px;
|
||||
height: 32px;
|
||||
width: 2.2em;
|
||||
height: 2.2em;
|
||||
border-radius: var(--roundness);
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue