Skip to content
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

ui fixes - compare view and archieved repo issues #7345

Merged
merged 7 commits into from Jul 8, 2019
Merged
Show file tree
Hide file tree
Changes from 2 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
18 changes: 15 additions & 3 deletions templates/repo/diff/compare.tmpl
Expand Up @@ -5,8 +5,12 @@

{{if .PageIsComparePull}}
<h2 class="ui header">
{{.i18n.Tr "repo.pulls.compare_changes"}}
<div class="sub header">{{.i18n.Tr "repo.pulls.compare_changes_desc"}}</div>
{{if not .Repository.IsArchived}}
{{.i18n.Tr "repo.pulls.compare_changes"}}
<div class="sub header">{{.i18n.Tr "repo.pulls.compare_changes_desc"}}</div>
{{ else }}
{{.i18n.Tr "action.compare_commits_general"}}
{{ end }}
</h2>
<div class="ui segment choose branch">
<span class="octicon octicon-git-compare"></span>
Expand Down Expand Up @@ -60,7 +64,15 @@
<div class="ui info message show-form-container">
<button class="ui button green show-form">{{.i18n.Tr "repo.pulls.new"}}</button>
</div>
{{end}}
{{ else }}
<div class="ui warning message">
{{if .Issue.IsPull}}
{{.i18n.Tr "repo.archive.title"}}
{{else}}
{{.i18n.Tr "repo.archive.title"}}
Cherrg marked this conversation as resolved.
Show resolved Hide resolved
{{end}}
</div>
{{ end }}
<div class="pullrequest-form" style="display: none">
{{template "repo/issue/new_form" .}}
</div>
Expand Down
6 changes: 2 additions & 4 deletions templates/repo/header.tmpl
Expand Up @@ -46,7 +46,7 @@
</div><!-- end grid -->
</div><!-- end container -->
{{end}}
{{if not .IsDiffCompare}}
zeripath marked this conversation as resolved.
Show resolved Hide resolved

<div class="ui tabs container">
<div class="ui tabular stackable menu navbar">
{{if .Permission.CanRead $.UnitTypeCode}}
Expand Down Expand Up @@ -103,7 +103,5 @@
</div>
</div>
<div class="ui tabs divider"></div>
{{else}}
<div class="ui divider"></div>
{{end}}

</div>
8 changes: 8 additions & 0 deletions templates/repo/issue/view_content.tmpl
Expand Up @@ -99,6 +99,14 @@
</form>
</div>
</div>
{{ else if .Repository.IsArchived }}
<div class="ui warning message">
{{if .Issue.IsPull}}
{{.i18n.Tr "repo.archive.pull.nocomment"}}
{{else}}
{{.i18n.Tr "repo.archive.issue.nocomment"}}
{{end}}
</div>
{{ end }}
{{else}}
{{if .Repository.IsArchived}}
Expand Down