All checks were successful
Build and deploy static pages / build-and-push (push) Successful in 14s
28 lines
916 B
HTML
28 lines
916 B
HTML
{{- define "main" }}
|
|
<header class="page-header">
|
|
{{- partial "breadcrumbs.html" . }}
|
|
<h1>{{ .Title }}</h1>
|
|
</header>
|
|
|
|
{{- /* Event urls are stored root-relative; strip the leading slash so relURL
|
|
prepends the baseURL subpath, keeping event clicks working when the site
|
|
is served from a subdirectory. */ -}}
|
|
{{- $events := slice }}
|
|
{{- range .Params.events }}
|
|
{{- $e := . }}
|
|
{{- with .url }}{{ $e = merge $e (dict "url" (strings.TrimPrefix "/" . | relURL)) }}{{ end }}
|
|
{{- $events = $events | append $e }}
|
|
{{- end }}
|
|
<div id="pa-calendar" data-events="{{ $events | jsonify }}"></div>
|
|
|
|
{{- if .Content }}
|
|
<div class="md-content">
|
|
{{- partial "anchored_headings.html" .Content }}
|
|
</div>
|
|
{{- end }}
|
|
|
|
{{- $opts := dict "minify" true "target" "es2017" }}
|
|
{{- $js := resources.Get "js/calendar.js" | js.Build $opts | fingerprint }}
|
|
<script src="{{ $js.RelPermalink }}" defer></script>
|
|
{{- end }}
|