Replace "View source" with "Edit history"

This commit is contained in:
2022-05-08 16:13:46 -05:00
parent 7dd01894da
commit 8d81f5e37c
8 changed files with 21 additions and 22 deletions

View File

@ -0,0 +1,8 @@
{{ if and .Site.Params.gitHistoryURL .File.Path }}
<span class="post-meta-item post-meta-edit-history" aria-label="{{ i18n "aria_post_meta_edit_history" }}">
{{ partial "icon.html" "history" }}
<a href="{{ printf "%s/content/%s" .Site.Params.gitHistoryURL .File.Path }}" target="_blank" rel="noopener">
{{- i18n "edit_history" -}}
</a>
</span>
{{ end }}

View File

@ -1,13 +0,0 @@
{{ if and .Site.Params.gitFileURL .File.Path }}
<span class="post-meta-item post-meta-view-source" aria-label="{{ i18n "aria_post_meta_view_source" }}">
{{ with .Site.Params.gitFileIcon }}
{{ partial "icon.html" . }}
{{ else }}
{{ partial "icon.html" "file" }}
{{ end }}
<a href="{{ printf "%s/content/%s" .Site.Params.gitFileURL .File.Path }}" target="_blank" rel="noopener">
View source
</a>
</span>
{{ end }}