use partial for referenced <link>
s
This commit is contained in:
parent
fd6fc99ab0
commit
54a41716c6
3 changed files with 108 additions and 77 deletions
54
layouts/partials/head/references.html
Normal file
54
layouts/partials/head/references.html
Normal file
|
@ -0,0 +1,54 @@
|
|||
{{- /*
|
||||
Displays comments for an item
|
||||
|
||||
@params pc Page context
|
||||
@params sc Site context
|
||||
*/
|
||||
-}}
|
||||
|
||||
<!-- Validation -->
|
||||
|
||||
{{- if ( not ( isset . "sc" ) ) -}}
|
||||
{{- errorf "No site context received" -}}
|
||||
{{- end -}}
|
||||
|
||||
{{- if ( not ( isset . "pc" ) ) -}}
|
||||
{{- errorf "No page context received (%q)" .sc.Page.File.Dir -}}
|
||||
{{- end -}}
|
||||
|
||||
<!-- Rendering -->
|
||||
|
||||
<link
|
||||
rel="license"
|
||||
href="{{- partialCached "util/get_licence_link.html" ( dict "licences_data" .sc.Site.Data.licences "licence" .sc.Site.Params.licence "licence_link" .sc.Site.Params.licence_link ) -}}"
|
||||
/>
|
||||
<link
|
||||
class="u-url u-uid"
|
||||
rel="me"
|
||||
href="{{- .sc.Site.Home.Permalink -}}"
|
||||
/>
|
||||
<link
|
||||
class="u-email"
|
||||
rel="me"
|
||||
href="mailto:{{- .sc.Site.Params.author.email -}}"
|
||||
/>
|
||||
{{- range .sc.Site.Params.meLinks -}}
|
||||
<link
|
||||
class="u-url"
|
||||
rel="me"
|
||||
href="{{ . }}"
|
||||
/>
|
||||
{{- end -}}
|
||||
<link
|
||||
class="u-logo"
|
||||
rel="icon"
|
||||
sizes="192x192"
|
||||
href="/images/icon.png"
|
||||
/>
|
||||
{{- with .sc.Site.Params.keyfile -}}
|
||||
<link
|
||||
class="u-key"
|
||||
rel="author"
|
||||
href="{{- . -}}"
|
||||
/>
|
||||
{{- end -}}
|
Loading…
Add table
Add a link
Reference in a new issue