mirror of
https://github.com/alex-shpak/hugo-book.git
synced 2024-11-25 12:46:44 +00:00
parent
0f58a77354
commit
b88d5f6b12
@ -73,8 +73,8 @@ enableGitInfo = true
|
||||
|
||||
# Enable "Edit this page" links for 'doc' page type.
|
||||
# Disabled by default. Uncomment to enable. Requires 'BookRepo' param.
|
||||
# Path must point to 'content' directory of repo.
|
||||
BookEditPath = 'edit/master/exampleSite/content'
|
||||
# Edit path must point to root directory of repo.
|
||||
BookEditPath = 'edit/master/exampleSite'
|
||||
|
||||
# Configure the date format used on the pages
|
||||
# - In git information
|
||||
|
@ -69,8 +69,8 @@ params:
|
||||
|
||||
# Enable "Edit this page" links for 'doc' page type.
|
||||
# Disabled by default. Uncomment to enable. Requires 'BookRepo' param.
|
||||
# Path must point to 'content' directory of repo.
|
||||
BookEditPath: edit/master/exampleSite/content
|
||||
# Edit path must point to root directory of repo.
|
||||
BookEditPath: edit/master/exampleSite
|
||||
|
||||
# Configure the date format used on the pages
|
||||
# - In git information
|
||||
|
@ -15,7 +15,7 @@
|
||||
|
||||
{{ if and .File .Site.Params.BookRepo .Site.Params.BookEditPath }}
|
||||
<div>
|
||||
<a class="flex align-center" href="{{ .Site.Params.BookRepo }}/{{ .Site.Params.BookEditPath }}/{{ replace .File.Path "\\" "/" }}" target="_blank" rel="noopener">
|
||||
<a class="flex align-center" href="{{ .Site.Params.BookRepo }}/{{ .Site.Params.BookEditPath }}/{{ .Site.Params.contentDir }}/{{ replace .File.Path "\\" "/" }}" target="_blank" rel="noopener">
|
||||
<img src="{{ "svg/edit.svg" | relURL }}" class="book-icon" alt="Edit" />
|
||||
<span>{{ i18n "Edit this page" }}</span>
|
||||
</a>
|
||||
|
Loading…
Reference in New Issue
Block a user