Skip to content

Backport various styling fixes #11619

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 5 commits into from
May 26, 2020
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion integrations/pull_merge_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -194,7 +194,7 @@ func TestCantMergeWorkInProgress(t *testing.T) {
req := NewRequest(t, "GET", resp.Header().Get("Location"))
resp = session.MakeRequest(t, req, http.StatusOK)
htmlDoc := NewHTMLParser(t, resp.Body)
text := strings.TrimSpace(htmlDoc.doc.Find(".attached.header > .text.grey").Last().Text())
text := strings.TrimSpace(htmlDoc.doc.Find(".attached.merge-section.no-header > .text.grey").Last().Text())
assert.NotEmpty(t, text, "Can't find WIP text")

// remove <strong /> from lang
Expand Down
2 changes: 1 addition & 1 deletion templates/repo/issue/view_content/pull.tmpl
Original file line number Diff line number Diff line change
Expand Up @@ -75,7 +75,7 @@
{{- else}}red{{end}}">{{svg "octicon-git-merge" 32}}</a>
<div class="content">
{{template "repo/pulls/status" .}}
<div class="ui {{if not $.LatestCommitStatus}}top attached header{{else}}attached merge-section segment{{end}}">
<div class="ui attached merge-section segment {{if not $.LatestCommitStatus}}no-header{{end}}">
{{if .Issue.PullRequest.HasMerged}}
<div class="item text purple">
{{if .Issue.PullRequest.MergedCommitID}}
Expand Down
7 changes: 6 additions & 1 deletion web_src/less/_base.less
Original file line number Diff line number Diff line change
Expand Up @@ -576,7 +576,12 @@ code,
font-weight: normal;
}

.avatar.image {
.avatar.image,
.avatar.image img,
.avatar.image svg,
.avatar.images .image,
.avatar.images img,
.avatar.images svg {
border-radius: 3px;
}

Expand Down
22 changes: 21 additions & 1 deletion web_src/less/_repository.less
Original file line number Diff line number Diff line change
Expand Up @@ -898,8 +898,20 @@
}

> .merge-section {
border-top: 1px solid #d4d4d5;
background-color: #f7f7f7;

.item + .item {
padding-top: .5rem;
}

.divider {
margin-left: -1rem;
margin-right: -1rem;
}

&.no-header {
#avatar-arrow;
}
}

.markdown {
Expand Down Expand Up @@ -1234,6 +1246,14 @@
}
}
}

.pullrequest-form {
margin-bottom: 1.5rem;
}

.markdown {
font-size: 14px;
}
}

.filter.dropdown .menu {
Expand Down
5 changes: 4 additions & 1 deletion web_src/less/_review.less
Original file line number Diff line number Diff line change
Expand Up @@ -19,8 +19,11 @@

.add-comment-left.add-comment-right .ui.attached.header {
border: 1px solid #d4d4d5;
margin-bottom: .5em;
margin-top: .5em;

&:not(.top) {
margin-bottom: .5em;
}
}

.focus-lines-new .ui.button.add-code-comment.add-code-comment-right,
Expand Down