reviews (star ratings with the average, as a section or under a product, which then gets AggregateRating), glossary (A to Z with a letter row, each term linkable, DefinedTermSet), logo-wall (a still grid, muted logos become light outlines in dark mode, white tiles on request), videos (a library from your own files: page per video with captions and transcript, list, feed, Latest videos section, VideoObject), directory (entries grouped by category with a page each), link-in-bio (one page of big buttons, no menu), status-page (components from data/status.yaml, incidents with a feed), coming-soon (a holding page with a launch date and a form, no menu) and timeline (dates down a line). Template functions: sortBy, ratings and stars. formatDate takes a date with a time, as front matter's date: does, and now is in the site's timezone. A layout can leave out the site's menu by redefining nav, but only with a non-empty body: Go keeps the old template when the new one is empty.
18 lines
907 B
HTML
18 lines
907 B
HTML
{{/* A page of links, for a social profile: no menu, only the links. */}}
|
|
{{/* No banner or menu here. A template whose body is empty doesn't replace
|
|
the site's, so each holds an empty string. */}}
|
|
{{ define "banner" }}{{ "" }}{{ end }}
|
|
{{ define "nav" }}{{ "" }}{{ end }}
|
|
{{ define "main" }}
|
|
<link rel="stylesheet" href="{{ asset "packs/link-in-bio/link-in-bio.css" }}">
|
|
<div class="lib">
|
|
{{ with .Params.photo }}<img class="lib-photo" src="{{ . }}" alt="{{ $.Params.photo_alt }}" width="112" height="112">{{ end }}
|
|
<h1 class="lib-name">{{ .Title }}</h1>
|
|
{{ with .Content }}<div class="lib-bio">{{ . }}</div>{{ end }}
|
|
<ul class="lib-links">
|
|
{{ range .Params.links }}<li><a class="lib-link" href="{{ .url }}"><span>{{ .text }}</span>{{ with .note }}<small>{{ . }}</small>{{ end }}</a></li>{{ end }}
|
|
</ul>
|
|
<p class="lib-home"><a href="/">{{ .Site.Config.Name }}</a></p>
|
|
</div>
|
|
{{ end }}
|