From bf730528cadc4727eab8844934b6a0716d327243 Mon Sep 17 00:00:00 2001 From: silverwind Date: Wed, 15 Mar 2023 03:19:27 +0100 Subject: [PATCH] Fix 'View File' button in code search (#23478) - Right-align 'View File' button - Add 'role' attribute to button link Before: Screenshot 2023-03-14 at 22 02 16 After: Screenshot 2023-03-14 at 22 02 33 Co-authored-by: Lunny Xiao --- templates/code/searchresults.tmpl | 6 +++--- templates/repo/search.tmpl | 6 +++--- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/templates/code/searchresults.tmpl b/templates/code/searchresults.tmpl index 74721a5a6..684e2860b 100644 --- a/templates/code/searchresults.tmpl +++ b/templates/code/searchresults.tmpl @@ -11,15 +11,15 @@ {{range $result := .SearchResults}} {{$repo := (index $.RepoMaps .RepoID)}}
-

- +

+ {{$repo.FullName}} {{if $repo.IsArchived}} {{$.locale.Tr "repo.desc.archived"}} {{end}} - {{.Filename}} - {{$.locale.Tr "repo.diff.view_file"}} + {{$.locale.Tr "repo.diff.view_file"}}

diff --git a/templates/repo/search.tmpl b/templates/repo/search.tmpl index 21f758e4a..ff4e218e2 100644 --- a/templates/repo/search.tmpl +++ b/templates/repo/search.tmpl @@ -39,9 +39,9 @@