diff options
author | silverwind <me@silverwind.io> | 2022-08-25 23:55:52 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-08-25 17:55:52 -0400 |
commit | 6c4688e1b1ddb68de192af7f83b06de27baae85e (patch) | |
tree | 554b4e7d97c843590031aab058ba1c66474c405f /templates/repo | |
parent | 27ac65a124f34ec3ed5f34aeb576f918ae1c70b1 (diff) | |
download | gitea-6c4688e1b1ddb68de192af7f83b06de27baae85e.tar.gz gitea-6c4688e1b1ddb68de192af7f83b06de27baae85e.zip |
Add whitespace removal inside template curly brackes (#20853)
Diffstat (limited to 'templates/repo')
-rw-r--r-- | templates/repo/activity.tmpl | 18 | ||||
-rw-r--r-- | templates/repo/commit_page.tmpl | 4 | ||||
-rw-r--r-- | templates/repo/commits_list.tmpl | 4 | ||||
-rw-r--r-- | templates/repo/commits_list_small.tmpl | 8 | ||||
-rw-r--r-- | templates/repo/commits_table.tmpl | 2 | ||||
-rw-r--r-- | templates/repo/forks.tmpl | 2 | ||||
-rw-r--r-- | templates/repo/graph.tmpl | 4 | ||||
-rw-r--r-- | templates/repo/header.tmpl | 14 | ||||
-rw-r--r-- | templates/repo/home.tmpl | 18 | ||||
-rw-r--r-- | templates/repo/search.tmpl | 12 | ||||
-rw-r--r-- | templates/repo/sub_menu.tmpl | 16 | ||||
-rw-r--r-- | templates/repo/user_cards.tmpl | 2 | ||||
-rw-r--r-- | templates/repo/view_file.tmpl | 2 | ||||
-rw-r--r-- | templates/repo/view_list.tmpl | 4 |
14 files changed, 55 insertions, 55 deletions
diff --git a/templates/repo/activity.tmpl b/templates/repo/activity.tmpl index 37cdf3ef02..c2f6c2d982 100644 --- a/templates/repo/activity.tmpl +++ b/templates/repo/activity.tmpl @@ -41,7 +41,7 @@ <a class="table-cell tiny background light grey"></a> </div> {{end}} - {{.locale.TrN .Activity.ActivePRCount "repo.activity.active_prs_count_1" "repo.activity.active_prs_count_n" .Activity.ActivePRCount | Safe }} + {{.locale.TrN .Activity.ActivePRCount "repo.activity.active_prs_count_1" "repo.activity.active_prs_count_n" .Activity.ActivePRCount | Safe}} </div> {{end}} {{if .Permission.CanRead $.UnitTypeIssues}} @@ -56,7 +56,7 @@ <a class="table-cell tiny background light grey"></a> </div> {{end}} - {{.locale.TrN .Activity.ActiveIssueCount "repo.activity.active_issues_count_1" "repo.activity.active_issues_count_n" .Activity.ActiveIssueCount | Safe }} + {{.locale.TrN .Activity.ActiveIssueCount "repo.activity.active_issues_count_1" "repo.activity.active_issues_count_n" .Activity.ActiveIssueCount | Safe}} </div> {{end}} </div> @@ -87,25 +87,25 @@ {{if .Permission.CanRead $.UnitTypeCode}} {{if eq .Activity.Code.CommitCountInAllBranches 0}} <div class="ui center aligned segment"> - <h4 class="ui header">{{.locale.Tr "repo.activity.no_git_activity" }}</h4> + <h4 class="ui header">{{.locale.Tr "repo.activity.no_git_activity"}}</h4> </div> {{end}} {{if gt .Activity.Code.CommitCountInAllBranches 0}} <div class="ui attached segment horizontal segments"> <div class="ui attached segment text"> - {{.locale.Tr "repo.activity.git_stats_exclude_merges" }} + {{.locale.Tr "repo.activity.git_stats_exclude_merges"}} <strong>{{.locale.TrN .Activity.Code.AuthorCount "repo.activity.git_stats_author_1" "repo.activity.git_stats_author_n" .Activity.Code.AuthorCount}}</strong> {{.locale.TrN .Activity.Code.AuthorCount "repo.activity.git_stats_pushed_1" "repo.activity.git_stats_pushed_n"}} <strong>{{.locale.TrN .Activity.Code.CommitCount "repo.activity.git_stats_commit_1" "repo.activity.git_stats_commit_n" .Activity.Code.CommitCount}}</strong> - {{.locale.Tr "repo.activity.git_stats_push_to_branch" .Repository.DefaultBranch }} + {{.locale.Tr "repo.activity.git_stats_push_to_branch" .Repository.DefaultBranch}} <strong>{{.locale.TrN .Activity.Code.CommitCountInAllBranches "repo.activity.git_stats_commit_1" "repo.activity.git_stats_commit_n" .Activity.Code.CommitCountInAllBranches}}</strong> - {{.locale.Tr "repo.activity.git_stats_push_to_all_branches" }} - {{.locale.Tr "repo.activity.git_stats_on_default_branch" .Repository.DefaultBranch }} + {{.locale.Tr "repo.activity.git_stats_push_to_all_branches"}} + {{.locale.Tr "repo.activity.git_stats_on_default_branch" .Repository.DefaultBranch}} <strong>{{.locale.TrN .Activity.Code.ChangedFiles "repo.activity.git_stats_file_1" "repo.activity.git_stats_file_n" .Activity.Code.ChangedFiles}}</strong> {{.locale.TrN .Activity.Code.ChangedFiles "repo.activity.git_stats_files_changed_1" "repo.activity.git_stats_files_changed_n"}} - {{.locale.Tr "repo.activity.git_stats_additions" }} + {{.locale.Tr "repo.activity.git_stats_additions"}} <strong class="text green">{{.locale.TrN .Activity.Code.Additions "repo.activity.git_stats_addition_1" "repo.activity.git_stats_addition_n" .Activity.Code.Additions}}</strong> - {{.locale.Tr "repo.activity.git_stats_and_deletions" }} + {{.locale.Tr "repo.activity.git_stats_and_deletions"}} <strong class="text red">{{.locale.TrN .Activity.Code.Deletions "repo.activity.git_stats_deletion_1" "repo.activity.git_stats_deletion_n" .Activity.Code.Deletions}}</strong>. </div> <div class="ui attached segment"> diff --git a/templates/repo/commit_page.tmpl b/templates/repo/commit_page.tmpl index 9e3fadee0c..8ece768832 100644 --- a/templates/repo/commit_page.tmpl +++ b/templates/repo/commit_page.tmpl @@ -87,7 +87,7 @@ {{.CsrfTokenHtml}} <div class="field"> <label> - {{.locale.Tr "repo.branch.new_branch_from" "<span class=\"text\" id=\"modal-create-branch-from-span\"></span>" | Safe }} + {{.locale.Tr "repo.branch.new_branch_from" "<span class=\"text\" id=\"modal-create-branch-from-span\"></span>" | Safe}} </label> </div> <div class="required field"> @@ -112,7 +112,7 @@ <input type="hidden" name="create_tag" value="true"> <div class="field"> <label> - {{.locale.Tr "repo.tag.create_tag_from" "<span class=\"text\" id=\"modal-create-tag-from-span\"></span>" | Safe }} + {{.locale.Tr "repo.tag.create_tag_from" "<span class=\"text\" id=\"modal-create-tag-from-span\"></span>" | Safe}} </label> </div> <div class="required field"> diff --git a/templates/repo/commits_list.tmpl b/templates/repo/commits_list.tmpl index 1003f2ee74..720067ce68 100644 --- a/templates/repo/commits_list.tmpl +++ b/templates/repo/commits_list.tmpl @@ -62,8 +62,8 @@ <span class="message-wrapper"> {{if $.PageIsWiki}} <span class="commit-summary {{if gt .ParentCount 1}} grey text{{end}}" title="{{.Summary}}">{{.Summary | RenderEmoji}}</span> - {{else }} - {{ $commitLink:= printf "%s/commit/%s" $commitRepoLink (PathEscape .ID.String) }} + {{else}} + {{$commitLink:= printf "%s/commit/%s" $commitRepoLink (PathEscape .ID.String)}} <span class="commit-summary {{if gt .ParentCount 1}} grey text{{end}}" title="{{.Summary}}">{{RenderCommitMessageLinkSubject $.Context .Message $commitRepoLink $commitLink $.Repository.ComposeMetas}}</span> {{end}} </span> diff --git a/templates/repo/commits_list_small.tmpl b/templates/repo/commits_list_small.tmpl index c1e1363187..f2f121c42c 100644 --- a/templates/repo/commits_list_small.tmpl +++ b/templates/repo/commits_list_small.tmpl @@ -1,8 +1,8 @@ -{{ $index := 0}} +{{$index := 0}} <div class="timeline-item commits-list"> {{range .comment.Commits}} - {{ $tag := printf "%s-%d" $.comment.HashTag $index }} - {{ $index = Add $index 1}} + {{$tag := printf "%s-%d" $.comment.HashTag $index}} + {{$index = Add $index 1}} <div class="singular-commit" id="{{$tag}}"> <span class="badge badge-commit">{{svg "octicon-git-commit"}}</span> {{if .User}} @@ -46,7 +46,7 @@ {{end}} </span> - {{ $commitLink:= printf "%s/commit/%s" $.comment.Issue.PullRequest.BaseRepo.Link (PathEscape .ID.String) }} + {{$commitLink:= printf "%s/commit/%s" $.comment.Issue.PullRequest.BaseRepo.Link (PathEscape .ID.String)}} <span class="mono commit-summary {{if gt .ParentCount 1}} grey text{{end}}" title="{{.Summary}}">{{RenderCommitMessageLinkSubject $.root.Context .Message ($.comment.Issue.PullRequest.BaseRepo.Link|Escape) $commitLink $.comment.Issue.PullRequest.BaseRepo.ComposeMetas}}</span> {{if IsMultilineCommitMessage .Message}} <button class="ui button ellipsis-button" aria-expanded="false">...</button> diff --git a/templates/repo/commits_table.tmpl b/templates/repo/commits_table.tmpl index a15f08da6d..ab54041b9d 100644 --- a/templates/repo/commits_table.tmpl +++ b/templates/repo/commits_table.tmpl @@ -3,7 +3,7 @@ {{if or .PageIsCommits (gt .CommitCount 0)}} {{.CommitCount}} {{.locale.Tr "repo.commits.commits"}} {{if .RefName}}({{.RefName}}){{end}} {{else if .IsNothingToCompare}} - {{.locale.Tr "repo.commits.nothing_to_compare" }} {{if .RefName}}({{.RefName}}){{end}} + {{.locale.Tr "repo.commits.nothing_to_compare"}} {{if .RefName}}({{.RefName}}){{end}} {{else}} {{.locale.Tr "repo.commits.no_commits" $.BaseBranch $.HeadBranch}} {{if .RefName}}({{.RefName}}){{end}} {{end}} diff --git a/templates/repo/forks.tmpl b/templates/repo/forks.tmpl index a303c9d9fb..56e60d4229 100644 --- a/templates/repo/forks.tmpl +++ b/templates/repo/forks.tmpl @@ -19,6 +19,6 @@ </div> </div> - {{ template "base/paginate" . }} + {{template "base/paginate" .}} </div> {{template "base/footer" .}} diff --git a/templates/repo/graph.tmpl b/templates/repo/graph.tmpl index 70985a5fa4..7efd6ec023 100644 --- a/templates/repo/graph.tmpl +++ b/templates/repo/graph.tmpl @@ -52,8 +52,8 @@ </h2> <div class="ui dividing"></div> <div class="ui segment loading hide" id="loading-indicator"></div> - {{ template "repo/graph/svgcontainer" .}} - {{ template "repo/graph/commits" .}} + {{template "repo/graph/svgcontainer" .}} + {{template "repo/graph/commits" .}} </div> </div> </div> diff --git a/templates/repo/header.tmpl b/templates/repo/header.tmpl index a08196f264..831784a623 100644 --- a/templates/repo/header.tmpl +++ b/templates/repo/header.tmpl @@ -66,7 +66,7 @@ {{end}} <form method="post" action="{{$.RepoLink}}/action/{{if $.IsWatchingRepo}}un{{end}}watch?redirect_to={{$.Link}}"> {{$.CsrfTokenHtml}} - <div class="ui labeled button{{if not $.IsSigned}} tooltip{{end}}" tabindex="0"{{if not $.IsSigned}} data-content="{{$.locale.Tr "repo.watch_guest_user" }}" data-position="top center"{{end}}> + <div class="ui labeled button{{if not $.IsSigned}} tooltip{{end}}" tabindex="0"{{if not $.IsSigned}} data-content="{{$.locale.Tr "repo.watch_guest_user"}}" data-position="top center"{{end}}> <button type="submit" class="ui compact small basic button"{{if not $.IsSigned}} disabled{{end}}> {{if $.IsWatchingRepo}}{{svg "octicon-eye-closed" 16}}{{$.locale.Tr "repo.unwatch"}}{{else}}{{svg "octicon-eye"}}{{$.locale.Tr "repo.watch"}}{{end}} </button> @@ -78,7 +78,7 @@ {{if not $.DisableStars}} <form method="post" action="{{$.RepoLink}}/action/{{if $.IsStaringRepo}}un{{end}}star?redirect_to={{$.Link}}"> {{$.CsrfTokenHtml}} - <div class="ui labeled button{{if not $.IsSigned}} tooltip{{end}}" tabindex="0"{{if not $.IsSigned}} data-content="{{$.locale.Tr "repo.star_guest_user" }}" data-position="top center"{{end}}> + <div class="ui labeled button{{if not $.IsSigned}} tooltip{{end}}" tabindex="0"{{if not $.IsSigned}} data-content="{{$.locale.Tr "repo.star_guest_user"}}" data-position="top center"{{end}}> <button type="submit" class="ui compact small basic button"{{if not $.IsSigned}} disabled{{end}}> {{if $.IsStaringRepo}}{{svg "octicon-star-fill"}}{{$.locale.Tr "repo.unstar"}}{{else}}{{svg "octicon-star"}}{{$.locale.Tr "repo.star"}}{{end}} </button> @@ -182,21 +182,21 @@ {{end}} {{if .Permission.CanRead $.UnitTypePackages}} - <a href="{{.RepoLink}}/packages" class="{{ if .IsPackagesPage }}active{{end}} item"> + <a href="{{.RepoLink}}/packages" class="{{if .IsPackagesPage}}active{{end}} item"> {{svg "octicon-package"}} {{.locale.Tr "packages.title"}} </a> {{end}} - {{ if and (not .UnitProjectsGlobalDisabled) (.Permission.CanRead $.UnitTypeProjects)}} - <a href="{{.RepoLink}}/projects" class="{{ if .IsProjectsPage }}active{{end}} item"> + {{if and (not .UnitProjectsGlobalDisabled) (.Permission.CanRead $.UnitTypeProjects)}} + <a href="{{.RepoLink}}/projects" class="{{if .IsProjectsPage}}active{{end}} item"> {{svg "octicon-project"}} {{.locale.Tr "repo.project_board"}} {{if .Repository.NumOpenProjects}} <span class="ui primary small label">{{CountFmt .Repository.NumOpenProjects}}</span> {{end}} </a> - {{ end }} + {{end}} - {{if and (.Permission.CanRead $.UnitTypeReleases) (not .IsEmptyRepo) }} + {{if and (.Permission.CanRead $.UnitTypeReleases) (not .IsEmptyRepo)}} <a class="{{if .PageIsReleaseList}}active{{end}} item" href="{{.RepoLink}}/releases"> {{svg "octicon-tag"}} {{.locale.Tr "repo.releases"}} {{if .NumReleases}} diff --git a/templates/repo/home.tmpl b/templates/repo/home.tmpl index 5c3eec8ab0..7b74c1cc76 100644 --- a/templates/repo/home.tmpl +++ b/templates/repo/home.tmpl @@ -5,7 +5,7 @@ {{template "base/alert" .}} <div class="ui repo-description"> <div id="repo-desc"> - {{ $description := .Repository.DescriptionHTML $.Context}} + {{$description := .Repository.DescriptionHTML $.Context}} {{if $description}}<span class="description">{{$description}}</span>{{else if .IsRepositoryAdmin}}<span class="no-description text-italic">{{.locale.Tr "repo.no_desc"}}</span>{{end}} <a class="link" href="{{.Repository.Website}}">{{.Repository.Website}}</a> </div> @@ -13,12 +13,12 @@ <div class="ui repo-search"> <form class="ui form ignore-dirty" action="{{.RepoLink}}/search" method="get"> <div class="field"> - <div class="ui action input{{if .CodeIndexerUnavailable }} disabled left icon tooltip{{end}}"{{if .CodeIndexerUnavailable }} data-content="{{.locale.Tr "repo.search.code_search_unavailable"}}"{{end}}> - <input name="q" value="{{.Keyword}}"{{if .CodeIndexerUnavailable }} disabled{{end}} placeholder="{{.locale.Tr "repo.search.search_repo"}}"> - {{if .CodeIndexerUnavailable }} + <div class="ui action input{{if .CodeIndexerUnavailable}} disabled left icon tooltip{{end}}"{{if .CodeIndexerUnavailable}} data-content="{{.locale.Tr "repo.search.code_search_unavailable"}}"{{end}}> + <input name="q" value="{{.Keyword}}"{{if .CodeIndexerUnavailable}} disabled{{end}} placeholder="{{.locale.Tr "repo.search.search_repo"}}"> + {{if .CodeIndexerUnavailable}} <i class="icon df ac jc">{{svg "octicon-alert"}}</i> {{end}} - <button class="ui icon button"{{if .CodeIndexerUnavailable }} disabled{{end}} type="submit"> + <button class="ui icon button"{{if .CodeIndexerUnavailable}} disabled{{end}} type="submit"> {{svg "octicon-search"}} </button> </div> @@ -63,8 +63,8 @@ <div class="repo-button-row df ac sb fw"> <div class="df ac"> {{template "repo/branch_dropdown" dict "root" .}} - {{ $n := len .TreeNames}} - {{ $l := Subtract $n 1}} + {{$n := len .TreeNames}} + {{$l := Subtract $n 1}} <!-- If home page, show new PR. If not, show breadcrumb --> {{if eq $n 0}} {{if and .CanCompareOrPull .IsViewBranch (not .Repository.IsArchived)}} @@ -99,7 +99,7 @@ </button> {{end}} {{else}} - <span class="ui breadcrumb repo-path"><a class="section" href="{{.RepoLink}}/src/{{.BranchNameSubURL}}" title="{{.Repository.Name}}">{{EllipsisString .Repository.Name 30}}</a>{{range $i, $v := .TreeNames}}<span class="divider">/</span>{{if eq $i $l}}<span class="active section" title="{{$v}}">{{EllipsisString $v 30}}</span>{{else}}{{ $p := index $.Paths $i}}<span class="section"><a href="{{$.BranchLink}}/{{PathEscapeSegments $p}}" title="{{$v}}">{{EllipsisString $v 30}}</a></span>{{end}}{{end}}</span> + <span class="ui breadcrumb repo-path"><a class="section" href="{{.RepoLink}}/src/{{.BranchNameSubURL}}" title="{{.Repository.Name}}">{{EllipsisString .Repository.Name 30}}</a>{{range $i, $v := .TreeNames}}<span class="divider">/</span>{{if eq $i $l}}<span class="active section" title="{{$v}}">{{EllipsisString $v 30}}</span>{{else}}{{$p := index $.Paths $i}}<span class="section"><a href="{{$.BranchLink}}/{{PathEscapeSegments $p}}" title="{{$v}}">{{EllipsisString $v 30}}</a></span>{{end}}{{end}}</span> {{end}} </div> <div class="df ac"> @@ -130,7 +130,7 @@ </button> </div> {{end}} - {{if and (ne $n 0) (not .IsViewFile) (not .IsBlame) }} + {{if and (ne $n 0) (not .IsViewFile) (not .IsBlame)}} <a class="ui button" href="{{.RepoLink}}/commits/{{.BranchNameSubURL}}/{{.TreePath | PathEscapeSegments}}"> {{svg "octicon-history" 16 "mr-3"}}{{.locale.Tr "repo.file_history"}} </a> diff --git a/templates/repo/search.tmpl b/templates/repo/search.tmpl index 5a02418a5a..9d8845443e 100644 --- a/templates/repo/search.tmpl +++ b/templates/repo/search.tmpl @@ -5,26 +5,26 @@ <div class="ui repo-search"> <form class="ui form ignore-dirty" method="get"> <div class="ui fluid action input"> - <input name="q" value="{{.Keyword}}"{{if .CodeIndexerUnavailable }} disabled{{end}} placeholder="{{.locale.Tr "repo.search.search_repo"}}"> - <div class="ui dropdown selection{{if .CodeIndexerUnavailable }} disabled{{end}}"> - <input name="t" type="hidden"{{if .CodeIndexerUnavailable }} disabled{{end}} value="{{.queryType}}">{{svg "octicon-triangle-down" 14 "dropdown icon"}} + <input name="q" value="{{.Keyword}}"{{if .CodeIndexerUnavailable}} disabled{{end}} placeholder="{{.locale.Tr "repo.search.search_repo"}}"> + <div class="ui dropdown selection{{if .CodeIndexerUnavailable}} disabled{{end}}"> + <input name="t" type="hidden"{{if .CodeIndexerUnavailable}} disabled{{end}} value="{{.queryType}}">{{svg "octicon-triangle-down" 14 "dropdown icon"}} <div class="text">{{.locale.Tr (printf "repo.search.%s" (or .queryType "fuzzy"))}}</div> <div class="menu transition hidden" tabindex="-1" style="display: block !important;"> <div class="item" data-value="">{{.locale.Tr "repo.search.fuzzy"}}</div> <div class="item" data-value="match">{{.locale.Tr "repo.search.match"}}</div> </div> </div> - <button class="ui icon button"{{if .CodeIndexerUnavailable }} disabled{{end}} type="submit">{{svg "octicon-search" 16}}</button> + <button class="ui icon button"{{if .CodeIndexerUnavailable}} disabled{{end}} type="submit">{{svg "octicon-search" 16}}</button> </div> </form> </div> - {{if .CodeIndexerUnavailable }} + {{if .CodeIndexerUnavailable}} <div class="ui error message"> <p>{{$.locale.Tr "repo.search.code_search_unavailable"}}</p> </div> {{else if .Keyword}} <h3> - {{.locale.Tr "repo.search.results" (.Keyword|Escape) (.RepoLink|Escape) (.RepoName|Escape) | Str2html }} + {{.locale.Tr "repo.search.results" (.Keyword|Escape) (.RepoLink|Escape) (.RepoName|Escape) | Str2html}} </h3> {{if .SearchResults}} <div class="df ac fw"> diff --git a/templates/repo/sub_menu.tmpl b/templates/repo/sub_menu.tmpl index 276bf05a4f..cf017caaff 100644 --- a/templates/repo/sub_menu.tmpl +++ b/templates/repo/sub_menu.tmpl @@ -1,4 +1,4 @@ -<div class="ui segments repository-summary{{if and (.Permission.CanRead $.UnitTypeCode) (not .IsEmptyRepo) .LanguageStats }} repository-summary-language-stats{{end}} mt-2 mb-0"> +<div class="ui segments repository-summary{{if and (.Permission.CanRead $.UnitTypeCode) (not .IsEmptyRepo) .LanguageStats}} repository-summary-language-stats{{end}} mt-2 mb-0"> <div class="ui segment sub-menu repository-menu"> <div class="ui two horizontal center link list"> {{if and (.Permission.CanRead $.UnitTypeCode) (not .IsEmptyRepo)}} @@ -19,27 +19,27 @@ {{end}} </div> </div> - {{if and (.Permission.CanRead $.UnitTypeCode) (not .IsEmptyRepo) .LanguageStats }} + {{if and (.Permission.CanRead $.UnitTypeCode) (not .IsEmptyRepo) .LanguageStats}} <div class="ui segment sub-menu language-stats-details" style="display: none"> <div class="ui horizontal center link list"> {{range .LanguageStats}} <div class="item df ac jc"> - <i class="color-icon mr-3" style="background-color: {{ .Color }}"></i> + <i class="color-icon mr-3" style="background-color: {{.Color}}"></i> <span class="bold mr-3"> - {{if eq .Language "other" }} - {{ $.locale.Tr "repo.language_other" }} + {{if eq .Language "other"}} + {{$.locale.Tr "repo.language_other"}} {{else}} - {{ .Language }} + {{.Language}} {{end}} </span> - {{ .Percentage }}% + {{.Percentage}}% </div> {{end}} </div> </div> <a class="ui segment language-stats"> {{range .LanguageStats}} - <div class="bar" style="width: {{ .Percentage }}%; background-color: {{ .Color }}"> </div> + <div class="bar" style="width: {{.Percentage}}%; background-color: {{.Color}}"> </div> {{end}} </a> {{end}} diff --git a/templates/repo/user_cards.tmpl b/templates/repo/user_cards.tmpl index 39d0021d0c..eec31d8b50 100644 --- a/templates/repo/user_cards.tmpl +++ b/templates/repo/user_cards.tmpl @@ -25,5 +25,5 @@ {{end}} </ul> - {{ template "base/paginate" . }} + {{template "base/paginate" .}} </div> diff --git a/templates/repo/view_file.tmpl b/templates/repo/view_file.tmpl index a76700a726..f06521046e 100644 --- a/templates/repo/view_file.tmpl +++ b/templates/repo/view_file.tmpl @@ -122,7 +122,7 @@ </table> <div class="code-line-menu ui vertical pointing menu tippy-target"> {{if $.Permission.CanRead $.UnitTypeIssues}} - <a class="item ref-in-new-issue" href="{{.RepoLink}}/issues/new?body={{.Repository.HTMLURL}}{{printf "/src/commit/" }}{{PathEscape .CommitID}}/{{PathEscapeSegments .TreePath}}" rel="nofollow noindex">{{.locale.Tr "repo.issues.context.reference_issue"}}</a> + <a class="item ref-in-new-issue" href="{{.RepoLink}}/issues/new?body={{.Repository.HTMLURL}}{{printf "/src/commit/"}}{{PathEscape .CommitID}}/{{PathEscapeSegments .TreePath}}" rel="nofollow noindex">{{.locale.Tr "repo.issues.context.reference_issue"}}</a> {{end}} <a class="item view_git_blame" href="{{.Repository.HTMLURL}}/blame/commit/{{PathEscape .CommitID}}/{{PathEscapeSegments .TreePath}}">{{.locale.Tr "repo.view_git_blame"}}</a> <a class="item copy-line-permalink" data-url="{{.Repository.HTMLURL}}/src/commit/{{PathEscape .CommitID}}/{{PathEscapeSegments .TreePath}}">{{.locale.Tr "repo.file_copy_permalink"}}</a> diff --git a/templates/repo/view_list.tmpl b/templates/repo/view_list.tmpl index bd26fac24c..b923a9e6c0 100644 --- a/templates/repo/view_list.tmpl +++ b/templates/repo/view_list.tmpl @@ -18,14 +18,14 @@ <strong>{{.LatestCommit.Author.Name}}</strong> {{end}} {{end}} - <a rel="nofollow" class="ui sha label {{if .LatestCommit.Signature}} isSigned {{if .LatestCommitVerification.Verified }} isVerified{{if eq .LatestCommitVerification.TrustStatus "trusted"}}{{else if eq .LatestCommitVerification.TrustStatus "untrusted"}}Untrusted{{else}}Unmatched{{end}}{{else if .LatestCommitVerification.Warning}} isWarning{{end}}{{end}}" href="{{.RepoLink}}/commit/{{PathEscape .LatestCommit.ID.String}}"> + <a rel="nofollow" class="ui sha label {{if .LatestCommit.Signature}} isSigned {{if .LatestCommitVerification.Verified}} isVerified{{if eq .LatestCommitVerification.TrustStatus "trusted"}}{{else if eq .LatestCommitVerification.TrustStatus "untrusted"}}Untrusted{{else}}Unmatched{{end}}{{else if .LatestCommitVerification.Warning}} isWarning{{end}}{{end}}" href="{{.RepoLink}}/commit/{{PathEscape .LatestCommit.ID.String}}"> <span class="shortsha">{{ShortSha .LatestCommit.ID.String}}</span> {{if .LatestCommit.Signature}} {{template "repo/shabox_badge" dict "root" $ "verification" .LatestCommitVerification}} {{end}} </a> {{template "repo/commit_statuses" dict "Status" .LatestCommitStatus "Statuses" .LatestCommitStatuses "root" $}} - {{ $commitLink:= printf "%s/commit/%s" .RepoLink (PathEscape .LatestCommit.ID.String) }} + {{$commitLink:= printf "%s/commit/%s" .RepoLink (PathEscape .LatestCommit.ID.String)}} <span class="grey commit-summary" title="{{.LatestCommit.Summary}}"><span class="message-wrapper">{{RenderCommitMessageLinkSubject $.Context .LatestCommit.Message $.RepoLink $commitLink $.Repository.ComposeMetas}}</span> {{if IsMultilineCommitMessage .LatestCommit.Message}} <button class="ui button ellipsis-button" aria-expanded="false">...</button> |