Skip to content

Commit 0b778cc

Browse files
committed
Fix styling for PR merge section when no checks (go-gitea#11609)
Makes styling consistent between two cases. Also removed unnecessary double border.
1 parent 30feee2 commit 0b778cc

File tree

3 files changed

+15
-3
lines changed

3 files changed

+15
-3
lines changed

integrations/pull_merge_test.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -194,7 +194,7 @@ func TestCantMergeWorkInProgress(t *testing.T) {
194194
req := NewRequest(t, "GET", resp.Header().Get("Location"))
195195
resp = session.MakeRequest(t, req, http.StatusOK)
196196
htmlDoc := NewHTMLParser(t, resp.Body)
197-
text := strings.TrimSpace(htmlDoc.doc.Find(".attached.header > .text.grey").Last().Text())
197+
text := strings.TrimSpace(htmlDoc.doc.Find(".attached.merge-section.no-header > .text.grey").Last().Text())
198198
assert.NotEmpty(t, text, "Can't find WIP text")
199199

200200
// remove <strong /> from lang

templates/repo/issue/view_content/pull.tmpl

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -75,7 +75,7 @@
7575
{{- else}}red{{end}}">{{svg "octicon-git-merge" 32}}</a>
7676
<div class="content">
7777
{{template "repo/pulls/status" .}}
78-
<div class="ui {{if not $.LatestCommitStatus}}top attached header{{else}}attached merge-section segment{{end}}">
78+
<div class="ui attached merge-section segment {{if not $.LatestCommitStatus}}no-header{{end}}">
7979
{{if .Issue.PullRequest.HasMerged}}
8080
<div class="item text purple">
8181
{{if .Issue.PullRequest.MergedCommitID}}

web_src/less/_repository.less

Lines changed: 13 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -898,8 +898,20 @@
898898
}
899899

900900
> .merge-section {
901-
border-top: 1px solid #d4d4d5;
902901
background-color: #f7f7f7;
902+
903+
.item + .item {
904+
padding-top: .5rem;
905+
}
906+
907+
.divider {
908+
margin-left: -1rem;
909+
margin-right: -1rem;
910+
}
911+
912+
&.no-header {
913+
#avatar-arrow;
914+
}
903915
}
904916

905917
.markdown {

0 commit comments

Comments
 (0)