Skip to content

Commit

Permalink
Vertical align avatar at middle (#20302)
Browse files Browse the repository at this point in the history
- Currently the avatar in the navbar is being vertically aligned to the
top, this caused that the icon besides it isn't being at the middle of
the avatar. Use the `vm` helper class to force the `vertical-align` to
be `middle`.
- Resolves #20292
  • Loading branch information
Gusted authored Jul 10, 2022
1 parent e24b0fc commit 2399b59
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion modules/templates/helper.go
Original file line number Diff line number Diff line change
Expand Up @@ -628,7 +628,7 @@ func SVG(icon string, others ...interface{}) template.HTML {

// Avatar renders user avatars. args: user, size (int), class (string)
func Avatar(item interface{}, others ...interface{}) template.HTML {
size, class := parseOthers(avatars.DefaultAvatarPixelSize, "ui avatar image", others...)
size, class := parseOthers(avatars.DefaultAvatarPixelSize, "ui avatar image vm", others...)

switch t := item.(type) {
case *user_model.User:
Expand Down

0 comments on commit 2399b59

Please sign in to comment.