Rename file_history_url config to history
This commit is contained in:
@@ -181,7 +181,7 @@ date_format = ":date_long" # Hugo date format
|
|||||||
description = "" # Site description. Appears above the menu, below the site title, if set.
|
description = "" # Site description. Appears above the menu, below the site title, if set.
|
||||||
edit = "" # File edit URL. Example: "https://github.com/account/project/edit/master/content/%s".
|
edit = "" # File edit URL. Example: "https://github.com/account/project/edit/master/content/%s".
|
||||||
external_link_new_tab = false # Open external links in new tabs
|
external_link_new_tab = false # Open external links in new tabs
|
||||||
file_history_url = "" # Example: "https://github.com/account/project/commits/master/content/%s"
|
history = "" # File history URL. Example: "https://github.com/account/project/commits/master/content/%s".
|
||||||
keyword_style = "text" # Must be "text" or "pills"
|
keyword_style = "text" # Must be "text" or "pills"
|
||||||
license = "" # Example: "CC BY 4.0 License", "CC BY-NC 4.0 License", "MIT License"
|
license = "" # Example: "CC BY 4.0 License", "CC BY-NC 4.0 License", "MIT License"
|
||||||
math = false # Enable math typesetting
|
math = false # Enable math typesetting
|
||||||
|
@@ -8,7 +8,7 @@ title = "Customizations"
|
|||||||
[paige]
|
[paige]
|
||||||
credit = "Paige Theme"
|
credit = "Paige Theme"
|
||||||
edit = "https://github.com/willfaught/paige/edit/master/exampleSite/content/%s"
|
edit = "https://github.com/willfaught/paige/edit/master/exampleSite/content/%s"
|
||||||
file_history_url = "https://github.com/willfaught/paige/commits/master/exampleSite/content/%s"
|
history = "https://github.com/willfaught/paige/commits/master/exampleSite/content/%s"
|
||||||
license = "MIT License"
|
license = "MIT License"
|
||||||
[paige.list_page]
|
[paige.list_page]
|
||||||
hide_authors = false
|
hide_authors = false
|
||||||
@@ -44,7 +44,7 @@ This page has the following parameters:
|
|||||||
[paige]
|
[paige]
|
||||||
credit = "Paige Theme"
|
credit = "Paige Theme"
|
||||||
edit = "https://github.com/willfaught/paige/edit/master/exampleSite/content/%s"
|
edit = "https://github.com/willfaught/paige/edit/master/exampleSite/content/%s"
|
||||||
file_history_url = "https://github.com/willfaught/paige/commits/master/exampleSite/content/%s"
|
history = "https://github.com/willfaught/paige/commits/master/exampleSite/content/%s"
|
||||||
license = "MIT License"
|
license = "MIT License"
|
||||||
[paige.list_page]
|
[paige.list_page]
|
||||||
hide_authors = false
|
hide_authors = false
|
||||||
|
@@ -9,7 +9,7 @@ title = "Show Data"
|
|||||||
[paige]
|
[paige]
|
||||||
credit = "Paige Theme"
|
credit = "Paige Theme"
|
||||||
edit = "https://github.com/willfaught/paige/edit/master/exampleSite/content/%s"
|
edit = "https://github.com/willfaught/paige/edit/master/exampleSite/content/%s"
|
||||||
file_history_url = "https://github.com/willfaught/paige/commits/master/exampleSite/content/%s"
|
history = "https://github.com/willfaught/paige/commits/master/exampleSite/content/%s"
|
||||||
license = "MIT License"
|
license = "MIT License"
|
||||||
[paige.list_page]
|
[paige.list_page]
|
||||||
hide_authors = false
|
hide_authors = false
|
||||||
@@ -45,7 +45,7 @@ This page has the following parameters:
|
|||||||
[paige]
|
[paige]
|
||||||
credit = "Paige Theme"
|
credit = "Paige Theme"
|
||||||
edit = "https://github.com/willfaught/paige/edit/master/exampleSite/content/%s"
|
edit = "https://github.com/willfaught/paige/edit/master/exampleSite/content/%s"
|
||||||
file_history_url = "https://github.com/willfaught/paige/commits/master/exampleSite/content/%s"
|
history = "https://github.com/willfaught/paige/commits/master/exampleSite/content/%s"
|
||||||
license = "MIT License"
|
license = "MIT License"
|
||||||
[paige.list_page]
|
[paige.list_page]
|
||||||
hide_authors = false
|
hide_authors = false
|
||||||
|
@@ -9,7 +9,7 @@ title = "Style Data"
|
|||||||
[paige]
|
[paige]
|
||||||
credit = "Paige Theme"
|
credit = "Paige Theme"
|
||||||
edit = "https://github.com/willfaught/paige/edit/master/exampleSite/content/%s"
|
edit = "https://github.com/willfaught/paige/edit/master/exampleSite/content/%s"
|
||||||
file_history_url = "https://github.com/willfaught/paige/commits/master/exampleSite/content/%s"
|
history = "https://github.com/willfaught/paige/commits/master/exampleSite/content/%s"
|
||||||
license = "MIT License"
|
license = "MIT License"
|
||||||
style = """
|
style = """
|
||||||
#paige-authors,
|
#paige-authors,
|
||||||
@@ -68,7 +68,7 @@ This page has the following parameters:
|
|||||||
[paige]
|
[paige]
|
||||||
credit = "Paige Theme"
|
credit = "Paige Theme"
|
||||||
edit = "https://github.com/willfaught/paige/edit/master/exampleSite/content/%s"
|
edit = "https://github.com/willfaught/paige/edit/master/exampleSite/content/%s"
|
||||||
file_history_url = "https://github.com/willfaught/paige/commits/master/exampleSite/content/%s"
|
history = "https://github.com/willfaught/paige/commits/master/exampleSite/content/%s"
|
||||||
license = "MIT License"
|
license = "MIT License"
|
||||||
style = """
|
style = """
|
||||||
#paige-authors,
|
#paige-authors,
|
||||||
|
@@ -1,8 +1,8 @@
|
|||||||
{{ $page := . }}
|
{{ $page := . }}
|
||||||
|
|
||||||
{{ $edit := $page.Param "paige.edit" | and ($page.Param "paige.page.hide_edit" | not) }}
|
{{ $edit := $page.Param "paige.edit" | and ($page.Param "paige.page.hide_edit" | not) }}
|
||||||
{{ $filehistoryurl := $page.Param "paige.file_history_url" | and ($page.Param "paige.page.hide_history" | not) }}
|
|
||||||
{{ $first := templates.Exists "partials/paige/page-footer-first.html" }}
|
{{ $first := templates.Exists "partials/paige/page-footer-first.html" }}
|
||||||
|
{{ $history := $page.Param "paige.history" | and ($page.Param "paige.page.hide_history" | not) }}
|
||||||
{{ $last := templates.Exists "partials/paige/page-footer-last.html" }}
|
{{ $last := templates.Exists "partials/paige/page-footer-last.html" }}
|
||||||
{{ $next := $page.NextInSection | and ($page.Param "paige.page.hide_next" | not) }}
|
{{ $next := $page.NextInSection | and ($page.Param "paige.page.hide_next" | not) }}
|
||||||
{{ $prev := $page.PrevInSection | and ($page.Param "paige.page.hide_prev" | not) }}
|
{{ $prev := $page.PrevInSection | and ($page.Param "paige.page.hide_prev" | not) }}
|
||||||
@@ -12,18 +12,18 @@
|
|||||||
{{ $edit = printf $edit $page.File.Path }}
|
{{ $edit = printf $edit $page.File.Path }}
|
||||||
{{ end }}
|
{{ end }}
|
||||||
|
|
||||||
{{ if $filehistoryurl }}
|
{{ if $history }}
|
||||||
{{ $filehistoryurl = printf $filehistoryurl $page.File.Path }}
|
{{ $history = printf $history $page.File.Path }}
|
||||||
{{ end }}
|
{{ end }}
|
||||||
{{ end }}
|
{{ end }}
|
||||||
|
|
||||||
{{ if or $edit $filehistoryurl $first $last $next $prev }}
|
{{ if or $edit $history $first $last $next $prev }}
|
||||||
<footer class="mw-100" id="paige-page-footer">
|
<footer class="mw-100" id="paige-page-footer">
|
||||||
{{ if $first }}
|
{{ if $first }}
|
||||||
{{ partial "paige/page-footer-first.html" . }}
|
{{ partial "paige/page-footer-first.html" . }}
|
||||||
{{ end }}
|
{{ end }}
|
||||||
|
|
||||||
{{ if or $edit $filehistoryurl }}
|
{{ if or $edit $history }}
|
||||||
<div id="paige-file">
|
<div id="paige-file">
|
||||||
{{ if $edit }}
|
{{ if $edit }}
|
||||||
<div class="paige-row-narrow text-center text-secondary" id="paige-edit">
|
<div class="paige-row-narrow text-center text-secondary" id="paige-edit">
|
||||||
@@ -31,9 +31,9 @@
|
|||||||
</div>
|
</div>
|
||||||
{{ end }}
|
{{ end }}
|
||||||
|
|
||||||
{{ if $filehistoryurl }}
|
{{ if $history }}
|
||||||
<div class="paige-row-narrow text-center text-secondary" id="paige-history">
|
<div class="paige-row-narrow text-center text-secondary" id="paige-history">
|
||||||
<a class="link-secondary" href="{{ $filehistoryurl | safeURL }}">{{ i18n "paige_edit_history" }}</a>
|
<a class="link-secondary" href="{{ $history | safeURL }}">{{ i18n "paige_edit_history" }}</a>
|
||||||
</div>
|
</div>
|
||||||
{{ end }}
|
{{ end }}
|
||||||
</div>
|
</div>
|
||||||
|
Reference in New Issue
Block a user