mirror of
https://codeberg.org/forgejo/forgejo.git
synced 2025-09-15 18:56:59 +00:00
[BUG] Disable 'View at this point in history' for wikis
- Don't show the 'View at this point in history' button for wikis as wikis don't have this feature. - Adds integration test - Resolves https://codeberg.org/forgejo/forgejo/issues/2995
This commit is contained in:
parent
7d35a76ebf
commit
8df9100994
2 changed files with 58 additions and 0 deletions
|
@ -78,12 +78,14 @@
|
|||
{{end}}
|
||||
<td class="text right aligned tw-py-0">
|
||||
<button class="btn interact-bg tw-p-2" data-tooltip-content="{{ctx.Locale.Tr "copy_hash"}}" data-clipboard-text="{{.ID}}">{{svg "octicon-copy"}}</button>
|
||||
{{if not $.PageIsWiki}}
|
||||
<a
|
||||
class="btn interact-bg tw-p-2"
|
||||
data-tooltip-content="{{ctx.Locale.Tr "repo.commits.view_path"}}"
|
||||
href="{{if $.FileName}}{{printf "%s/src/commit/%s/%s" $commitRepoLink (PathEscape .ID.String) (PathEscapeSegments $.FileName)}}{{else}}{{printf "%s/src/commit/%s" $commitRepoLink (PathEscape .ID.String)}}{{end}}">
|
||||
{{svg "octicon-file-code"}}
|
||||
</a>
|
||||
{{end}}
|
||||
</td>
|
||||
</tr>
|
||||
{{end}}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue