Skip to content

Commit 88a652f

Browse files
zeripathwxiaoguang
andauthored
Improve commit graph page UI alignment (#23751) (#23754)
Backport #23751 Fix the UI alignment by the way (adding some `gt-mr-xx`) Before: ![image](https://user-images.githubusercontent.com/2114189/228034794-7a6ac8d6-01fa-4dd2-97d4-0df0368f8ee0.png) After: ![image](https://user-images.githubusercontent.com/2114189/228034938-64edeadf-7c99-4e74-b658-0ca62b72d596.png) Co-authored-by: wxiaoguang <wxiaoguang@gmail.com>
1 parent 35039b8 commit 88a652f

File tree

1 file changed

+6
-6
lines changed

1 file changed

+6
-6
lines changed

templates/repo/graph/commits.tmpl

+6-6
Original file line numberDiff line numberDiff line change
@@ -28,10 +28,10 @@
2828
{{- end -}}
2929
</a>
3030
</span>
31-
<span class="message gt-dib gt-ellipsis gt-mr-2">
31+
<span class="message gt-dib gt-ellipsis gt-mr-3">
3232
<span>{{RenderCommitMessage $.Context $commit.Subject $.RepoLink $.Repository.ComposeMetas}}</span>
3333
</span>
34-
<span class="tags gt-df gt-ac">
34+
<span class="tags gt-df gt-ac gt-mr-2">
3535
{{range $commit.Refs}}
3636
{{$refGroup := .RefGroup}}
3737
{{if eq $refGroup "pull"}}
@@ -54,20 +54,20 @@
5454
{{svg "octicon-git-branch" 16 "gt-mr-2"}}{{.ShortName}}
5555
</a>
5656
{{else}}
57-
<!-- Unknown ref type {{.Name}} -->
57+
<!-- Unknown ref type .Name -->
5858
{{end}}
5959
{{end}}
6060
</span>
61-
<span class="author gt-df gt-ac gt-mr-2">
61+
<span class="author gt-df gt-ac gt-mr-3">
6262
{{$userName := $commit.Commit.Author.Name}}
6363
{{if $commit.User}}
6464
{{if $commit.User.FullName}}
6565
{{$userName = $commit.User.FullName}}
6666
{{end}}
67-
{{avatar $.Context $commit.User}}
67+
<span class="gt-mr-2">{{avatar $.Context $commit.User}}</span>
6868
<a href="{{$commit.User.HomeLink}}">{{$userName}}</a>
6969
{{else}}
70-
{{avatarByEmail $.Context $commit.Commit.Author.Email $userName}}
70+
<span class="gt-mr-2">{{avatarByEmail $.Context $commit.Commit.Author.Email $userName}}</span>
7171
{{$userName}}
7272
{{end}}
7373
</span>

0 commit comments

Comments
 (0)