From d9c6cb71e16145ac8f3d9f94f59d3b15ad873631 Mon Sep 17 00:00:00 2001 From: gempir Date: Thu, 16 Feb 2023 20:25:00 +0100 Subject: [PATCH] Always go full width in PR view (#22844) This is an alternative solution to #22824 and would also close #22781 This makes the PR diff view always full width. It makes sense to make use of that screen real estate. If you want a more narrow view you can always resize your browser. It also avoids cluttering the UI with another button + the database with another column for the setting. This is also how github and gitlab do it. --- templates/repo/commit_page.tmpl | 2 +- templates/repo/diff/compare.tmpl | 2 +- templates/repo/pulls/files.tmpl | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/templates/repo/commit_page.tmpl b/templates/repo/commit_page.tmpl index a0cd12674..0ecbf2916 100644 --- a/templates/repo/commit_page.tmpl +++ b/templates/repo/commit_page.tmpl @@ -1,7 +1,7 @@ {{template "base/head" .}}
{{template "repo/header" .}} -
+
{{$class := ""}} {{if .Commit.Signature}} {{$class = (printf "%s%s" $class " isSigned")}} diff --git a/templates/repo/diff/compare.tmpl b/templates/repo/diff/compare.tmpl index 97ef7c2da..16749bacb 100644 --- a/templates/repo/diff/compare.tmpl +++ b/templates/repo/diff/compare.tmpl @@ -1,7 +1,7 @@ {{template "base/head" .}}
{{template "repo/header" .}} -
+

{{if and $.PageIsComparePull $.IsSigned (not .Repository.IsArchived)}} diff --git a/templates/repo/pulls/files.tmpl b/templates/repo/pulls/files.tmpl index e5e91bf5c..c3e32325d 100644 --- a/templates/repo/pulls/files.tmpl +++ b/templates/repo/pulls/files.tmpl @@ -5,7 +5,7 @@
{{template "repo/header" .}} -
+