Always open credit link in new tab
This commit is contained in:
@@ -177,7 +177,7 @@ There is a single parameter object with sensible defaults that can be overridden
|
||||
color = "#0d6efd" # Bootstrap primary color and theme color for Safari and Windows
|
||||
color_scheme = "auto" # Must be "auto", "dark", or "light"
|
||||
copyright = "" # Appears below the page, above the site credit, if set. Defaults to the site copyright.
|
||||
credit = '<a class="link-secondary text-decoration-none" href="https://github.com/willfaught/paige">Paige Theme</a>'
|
||||
credit = '<a class="link-secondary text-decoration-none" href="https://github.com/willfaught/paige" target="_blank">Paige Theme</a>'
|
||||
date_format = ":date_long" # Hugo date format
|
||||
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".
|
||||
|
@@ -6,20 +6,11 @@
|
||||
{{ $last := templates.Exists "partials/paige/footer-last.html" }}
|
||||
{{ $license := $page.Param "paige.license" | markdownify | and ($page.Param "paige.site.disable_license" | not) }}
|
||||
{{ $microdata := $page.Params.paige.page.microdata }}
|
||||
{{ $theme := "https://github.com/willfaught/paige" }}
|
||||
|
||||
{{ $target := partial "paige/func-target.html" (dict "page" $page "url" $theme) }}
|
||||
|
||||
{{ if eq $credit nil }}
|
||||
{{ $targetString := "" }}
|
||||
|
||||
{{ with $target }}
|
||||
{{ $targetString = printf ` target="%s"` . }}
|
||||
{{ end }}
|
||||
|
||||
{{ $credit = printf `<a class="link-secondary text-decoration-none" href="%s"%s>Paige Theme</a>` $theme $targetString | safeHTML }}
|
||||
{{ else }}
|
||||
{{ if $credit }}
|
||||
{{ $credit = markdownify $credit }}
|
||||
{{ else }}
|
||||
{{ $credit = `<a class="link-secondary text-decoration-none" href="https://github.com/willfaught/paige" target="_blank">Paige Theme</a>` | safeHTML }}
|
||||
{{ end }}
|
||||
|
||||
{{ $credit = $credit | and ($page.Param "paige.site.disable_credit" | not) }}
|
||||
|
Reference in New Issue
Block a user