Skip to content

Commit 5d182fa

Browse files
committed
more cleanups and fixes
1 parent f2e72d4 commit 5d182fa

File tree

4 files changed

+9
-40
lines changed

4 files changed

+9
-40
lines changed

templates/repo/commits_list_small.tmpl

+2-2
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@
1515

1616
{{$commitLink:= printf "%s/commit/%s" $.comment.Issue.PullRequest.BaseRepo.Link (PathEscape .ID.String)}}
1717

18-
<span class="ui float right shabox">
18+
<span class="ui float right shabox gt-df gt-ac">
1919
{{template "repo/commit_statuses" dict "Status" .Status "Statuses" .Statuses "root" $.root}}
2020
{{$class := "ui sha label"}}
2121
{{if .Signature}}
@@ -32,7 +32,7 @@
3232
{{$class = (printf "%s%s" $class " isWarning")}}
3333
{{end}}
3434
{{end}}
35-
<a href="{{$commitLink}}" rel="nofollow" class="{{$class}}">
35+
<a href="{{$commitLink}}" rel="nofollow" class="gt-ml-3 {{$class}}">
3636
<span class="shortsha">{{ShortSha .ID.String}}</span>
3737
{{if .Signature}}
3838
{{template "repo/shabox_badge" dict "root" $.root "verification" .Verification}}

templates/repo/issue/view_content/comments.tmpl

+2-2
Original file line numberDiff line numberDiff line change
@@ -484,7 +484,7 @@
484484
{{range $filename, $lines := .Review.CodeComments}}
485485
{{range $line, $comms := $lines}}
486486
<div class="ui segments">
487-
<div class="ui segment gt-py-3 gt-df gt-ac gt-sb">
487+
<div class="ui segment collapsible-comment-box gt-py-3 gt-df gt-ac gt-sb">
488488
{{$invalid := (index $comms 0).Invalidated}}
489489
{{$resolved := (index $comms 0).IsResolved}}
490490
{{$resolveDoer := (index $comms 0).ResolveDoer}}
@@ -543,7 +543,7 @@
543543
<div class="comment-header-left gt-df gt-ac">
544544
{{if not .OriginalAuthor}}
545545
<a class="avatar">
546-
{{avatar $.Context .Poster}}
546+
{{avatar $.Context .Poster 20}}
547547
</a>
548548
{{end}}
549549
<span class="text grey muted-links">

web_src/css/modules/comment.css

+1-13
Original file line numberDiff line numberDiff line change
@@ -47,20 +47,8 @@
4747
}
4848

4949
.ui.comments .comment .avatar {
50-
display: block;
51-
width: 2.5em;
52-
height: auto;
5350
float: left;
54-
margin: 0.2em 0 0;
55-
}
56-
57-
.ui.comments .comment img.avatar,
58-
.ui.comments .comment .avatar img {
59-
display: block;
60-
margin: 0 auto;
61-
width: 100%;
62-
height: 100%;
63-
border-radius: 0.25rem;
51+
width: 2.5em;
6452
}
6553

6654
.ui.comments .comment > .content {

web_src/css/repository.css

+4-23
Original file line numberDiff line numberDiff line change
@@ -793,14 +793,6 @@
793793
display: none;
794794
}
795795

796-
/* size adjustment is necessary until fomantic comment module removal */
797-
.repository.view.issue .comment-list .timeline-item .comment-code-cloud img.avatar,
798-
.repository.view.issue .comment-list .timeline-item .comment-code-cloud .avatar img {
799-
width: 20px;
800-
height: 20px;
801-
vertical-align: middle;
802-
}
803-
804796
.repository.view.issue .comment-list .timeline-item:first-child:not(.commit) {
805797
padding-top: 0 !important;
806798
}
@@ -1059,12 +1051,12 @@
10591051

10601052
.repository.view.issue .comment-list .code-comment {
10611053
border: 1px solid transparent;
1062-
padding: 0.25rem 0.5rem;
10631054
margin: 0;
10641055
}
10651056

1066-
.repository.view.issue .comment-list .code-comment .content {
1067-
border: none !important;
1057+
/* fix fomantic's border-radius via :first-child with hidden elements */
1058+
.collapsible-comment-box:has(.gt-hidden) {
1059+
border-radius: var(--border-radius) !important;
10681060
}
10691061

10701062
.repository.view.issue .comment-list .code-comment .comment-header {
@@ -1087,14 +1079,7 @@
10871079
}
10881080

10891081
.repository.view.issue .comment-list .comment > .avatar ~ .content {
1090-
margin-left: 3em;
1091-
}
1092-
1093-
/* size adjustment is necessary until fomantic comment module removal */
1094-
.repository.view.issue .comment-code-cloud .comment-list .code-comment img.avatar,
1095-
.repository.view.issue .comment-code-cloud .comment-list .comment img.avatar {
1096-
width: 28px;
1097-
height: 28px;
1082+
margin-left: 42px;
10981083
}
10991084

11001085
.repository.view.issue .comment-list .comment-code-cloud .segment.reactions {
@@ -1147,10 +1132,6 @@
11471132
text-decoration: line-through;
11481133
}
11491134

1150-
.ui.comments .comment .avatar {
1151-
margin: 0;
1152-
}
1153-
11541135
.repository .comment.form .ui.comments {
11551136
margin-top: -12px;
11561137
max-width: 100%;

0 commit comments

Comments
 (0)