diff options
author | Shohei Ueda <30958501+peaceiris@users.noreply.github.com> | 2021-05-07 21:04:42 +0300 |
---|---|---|
committer | GitHub <noreply@github.com> | 2021-05-07 21:04:42 +0300 |
commit | f4cf568c7666353c6b15ce40992ee6e51df4679e (patch) | |
tree | 2330745169e7d09e51ae0c0c83b42f82fd128116 /layouts | |
parent | 2018b4c9e0e27527c066d282215e34188198e1bb (diff) |
feat: Add view-on-github-button (#326)
Diffstat (limited to 'layouts')
-rw-r--r-- | layouts/partials/header.html | 1 | ||||
-rw-r--r-- | layouts/partials/view-on-github-button.html | 5 |
2 files changed, 6 insertions, 0 deletions
diff --git a/layouts/partials/header.html b/layouts/partials/header.html index 492b39b3..7abbe0dd 100644 --- a/layouts/partials/header.html +++ b/layouts/partials/header.html @@ -63,6 +63,7 @@ <div class="hero-foot columns is-desktop"> <div class="column is-8 is-offset-2"> {{ partial "lang-button" . }} + {{ partial "view-on-github-button" . }} {{ partial "edit-button" . }} {{ partial "check-tools" . }} </div> diff --git a/layouts/partials/view-on-github-button.html b/layouts/partials/view-on-github-button.html new file mode 100644 index 00000000..8383688f --- /dev/null +++ b/layouts/partials/view-on-github-button.html @@ -0,0 +1,5 @@ +{{ with $.Site.Params.repo }} + <a class="button is-pulled-right" href="{{ .URL }}/blob/{{ .branch }}/{{ .contentDir }}/{{ $.Lang }}/{{ $.File.Path }}"> + {{ i18n "view_on_github" }} + </a> +{{ end }} |