mirror of
https://github.com/go-gitea/gitea
synced 2025-01-05 07:24:25 +00:00
Fix review code comment avatar alignment (#33031)
Fixes #33017 Avatar should only have offset if the `Comment` has `Content` or `Attachment` to align with the speech bubble. --------- Co-authored-by: wxiaoguang <wxiaoguang@gmail.com>
This commit is contained in:
parent
ff96873e3e
commit
a96776b3cb
@ -365,8 +365,9 @@
|
|||||||
{{if .Review}}{{$reviewType = .Review.Type}}{{end}}
|
{{if .Review}}{{$reviewType = .Review.Type}}{{end}}
|
||||||
{{if not .OriginalAuthor}}
|
{{if not .OriginalAuthor}}
|
||||||
{{/* Some timeline avatars need a offset to correctly align with their speech bubble.
|
{{/* Some timeline avatars need a offset to correctly align with their speech bubble.
|
||||||
The condition depends on whether the comment has contents/attachments or reviews */}}
|
The condition depends on whether the comment has contents/attachments,
|
||||||
<a class="timeline-avatar{{if or .Content .Attachments (and .Review .Review.CodeComments)}} timeline-avatar-offset{{end}}"{{if gt .Poster.ID 0}} href="{{.Poster.HomeLink}}"{{end}}>
|
review's comment is also controlled/rendered by issue comment's Content field */}}
|
||||||
|
<a class="timeline-avatar{{if or .Content .Attachments}} timeline-avatar-offset{{end}}"{{if gt .Poster.ID 0}} href="{{.Poster.HomeLink}}"{{end}}>
|
||||||
{{ctx.AvatarUtils.Avatar .Poster 40}}
|
{{ctx.AvatarUtils.Avatar .Poster 40}}
|
||||||
</a>
|
</a>
|
||||||
{{end}}
|
{{end}}
|
||||||
|
Loading…
Reference in New Issue
Block a user