diff --git a/templates/explore/code.tmpl b/templates/explore/code.tmpl index 0495645576..1c41dd843f 100644 --- a/templates/explore/code.tmpl +++ b/templates/explore/code.tmpl @@ -16,10 +16,10 @@

{{.i18n.Tr "explore.code_search_results" (.Keyword|Escape) | Str2html }}

-
+
{{range $term := .SearchResultLanguages}} - - + + {{$term.Language}}
{{$term.Count}}
@@ -31,7 +31,7 @@

{{$repo.FullName}} - {{.Filename}} - {{$.i18n.Tr "repo.diff.view_file"}} + {{$.i18n.Tr "repo.diff.view_file"}}

diff --git a/templates/explore/repo_list.tmpl b/templates/explore/repo_list.tmpl index bfec17ff29..91dc3d8bf4 100644 --- a/templates/explore/repo_list.tmpl +++ b/templates/explore/repo_list.tmpl @@ -38,12 +38,12 @@ {{end}}
-
+
{{if .PrimaryLanguage }} - {{ .PrimaryLanguage.Language }} + {{ .PrimaryLanguage.Language }} {{end}} - {{svg "octicon-star"}} {{.NumStars}} - {{svg "octicon-git-branch"}} {{.NumForks}} + {{svg "octicon-star" 16 "mr-3"}}{{.NumStars}} + {{svg "octicon-git-branch" 16 "mr-3"}}{{.NumForks}}
diff --git a/templates/repo/diff/box.tmpl b/templates/repo/diff/box.tmpl index 40e9d277b3..ef152fa58b 100644 --- a/templates/repo/diff/box.tmpl +++ b/templates/repo/diff/box.tmpl @@ -33,10 +33,10 @@ {{end}}
-
    +
      {{range .Diff.Files}}
    1. -
      +
      {{if not .IsBin}} {{template "repo/diff/stats" dict "file" . "root" $}} {{else}} @@ -45,7 +45,7 @@
        - {{.Name}} + {{.Name}}
    2. {{end}}
    @@ -53,23 +53,28 @@ {{if $file.IsIncomplete}}

    -
    + + {{svg "octicon-chevron-down" 18}} + +
    {{if not $file.IsRenamed}} {{template "repo/diff/stats" dict "file" . "root" $}} {{end}}
    - {{$file.Name}} -
    {{$.i18n.Tr "repo.diff.file_suppressed"}}
    - {{if $file.IsProtected}} - {{$.i18n.Tr "repo.diff.protected"}} - {{end}} - {{if and (not $file.IsSubmodule) (not $.PageIsWiki)}} - {{if $file.IsDeleted}} - {{$.i18n.Tr "repo.diff.view_file"}} - {{else}} - {{$.i18n.Tr "repo.diff.view_file"}} + {{$file.Name}} +
    +
    {{$.i18n.Tr "repo.diff.file_suppressed"}}
    + {{if $file.IsProtected}} + {{$.i18n.Tr "repo.diff.protected"}} {{end}} - {{end}} + {{if and (not $file.IsSubmodule) (not $.PageIsWiki)}} + {{if $file.IsDeleted}} + {{$.i18n.Tr "repo.diff.view_file"}} + {{else}} + {{$.i18n.Tr "repo.diff.view_file"}} + {{end}} + {{end}} +

    {{else}} @@ -82,21 +87,19 @@ {{else}} {{$isImage = (call $.IsImageFileInHead $file.Name)}} {{end}} - {{if or (not $file.IsBin) $isImage}} - + {{svg "octicon-chevron-down" 18}} - {{end}} -
    +
    {{if $file.IsBin}} {{$.i18n.Tr "repo.diff.bin"}} {{else if not $file.IsRenamed}} {{template "repo/diff/stats" dict "file" . "root" $}} {{end}}
    - {{if $file.IsRenamed}}{{$file.OldName}} → {{end}}{{$file.Name}}{{if .IsLFSFile}} ({{$.i18n.Tr "repo.stored_lfs"}}){{end}} + {{if $file.IsRenamed}}{{$file.OldName}} → {{end}}{{$file.Name}}{{if .IsLFSFile}} ({{$.i18n.Tr "repo.stored_lfs"}}){{end}}
    -
    +
    {{if $file.IsProtected}} {{$.i18n.Tr "repo.diff.protected"}} {{end}} @@ -111,8 +114,8 @@
    {{if ne $file.Type 4}} -
    - +
    +
    {{if $isImage}} {{template "repo/diff/image_diff" dict "file" . "root" $}} @@ -130,7 +133,6 @@ {{end}} -
    {{end}} {{if .Diff.IsIncomplete}} diff --git a/templates/repo/diff/image_diff.tmpl b/templates/repo/diff/image_diff.tmpl index 6afb985e9a..eda208d744 100644 --- a/templates/repo/diff/image_diff.tmpl +++ b/templates/repo/diff/image_diff.tmpl @@ -2,22 +2,22 @@ {{ $imagePathNew := printf "%s/%s" .root.RawPath (EscapePound .file.Name) }} - - - - - -
    + {{.root.i18n.Tr "repo.diff.file_before"}} + {{.root.i18n.Tr "repo.diff.file_after"}}
    + {{if or .file.IsDeleted (not .file.IsCreated)}} {{end}} + {{if or .file.IsCreated (not .file.IsDeleted)}} @@ -29,7 +29,7 @@ {{ $imageInfoHead := (call .root.ImageInfo .file.Name) }} {{if or $imageInfoBase $imageInfoHead }}
    + {{if $imageInfoBase }} {{ $classWidth := "" }} {{ $classHeight := "" }} @@ -52,7 +52,7 @@ {{.root.i18n.Tr "repo.diff.file_byte_size"}}: {{FileSize $imageInfoBase.ByteSize}} {{end}} + {{if $imageInfoHead }} {{ $classWidth := "" }} {{ $classHeight := "" }} diff --git a/templates/repo/diff/stats.tmpl b/templates/repo/diff/stats.tmpl index 97503f0ea5..1c9b2abd31 100644 --- a/templates/repo/diff/stats.tmpl +++ b/templates/repo/diff/stats.tmpl @@ -1,4 +1,4 @@ {{Add .file.Addition .file.Deletion}} - +
    diff --git a/templates/repo/search.tmpl b/templates/repo/search.tmpl index c2172ec787..b66391a5ac 100644 --- a/templates/repo/search.tmpl +++ b/templates/repo/search.tmpl @@ -16,10 +16,10 @@

    {{.i18n.Tr "repo.search.results" (.Keyword|Escape) .RepoLink .RepoName | Str2html }}

    -
    +
    {{range $term := .SearchResultLanguages}} - - + + {{$term.Language}}
    {{$term.Count}}
    @@ -30,7 +30,7 @@

    {{.Filename}} - {{$.i18n.Tr "repo.diff.view_file"}} + {{$.i18n.Tr "repo.diff.view_file"}}

    diff --git a/templates/repo/sub_menu.tmpl b/templates/repo/sub_menu.tmpl index 6c455a4d5d..5bb71ba49d 100644 --- a/templates/repo/sub_menu.tmpl +++ b/templates/repo/sub_menu.tmpl @@ -23,15 +23,16 @@