Switch theme to Doks
This commit is contained in:
0
layouts/_default/_markup/.gitkeep
Normal file
0
layouts/_default/_markup/.gitkeep
Normal file
30
layouts/_default/baseof.html
Normal file
30
layouts/_default/baseof.html
Normal file
@@ -0,0 +1,30 @@
|
||||
<!doctype html>
|
||||
<html lang="{{ .Site.LanguageCode | default "en" }}">
|
||||
{{ partial "head/head.html" . }}
|
||||
{{ if eq .Kind "home" -}}
|
||||
{{ .Scratch.Set "class" "home" -}}
|
||||
{{ else if eq .Kind "404" -}}
|
||||
{{ .Scratch.Set "class" "error404" -}}
|
||||
{{ else if eq .Kind "page" -}}
|
||||
{{ .Scratch.Set "class" .Type -}}
|
||||
{{ .Scratch.Add "class" " single" -}}
|
||||
{{ else -}}
|
||||
{{ .Scratch.Set "class" .Type -}}
|
||||
{{ .Scratch.Add "class" " list" -}}
|
||||
{{ end -}}
|
||||
<body class="{{ .Scratch.Get "class" }}">
|
||||
{{ partial "header/header.html" . }}
|
||||
<div class="wrap container" role="document">
|
||||
<div class="content">
|
||||
{{ block "main" . }}{{ end }}
|
||||
</div>
|
||||
</div>
|
||||
{{ block "sidebar-prefooter" . }}{{ end }}
|
||||
{{ block "sidebar-footer" . }}{{ end }}
|
||||
{{ partial "footer/footer.html" . }}
|
||||
{{ if and .IsHome .Site.Params.alert }}
|
||||
{{ partial "footer/alert.html" . }}
|
||||
{{ end }}
|
||||
{{ partial "footer/script-footer.html" . }}
|
||||
</body>
|
||||
</html>
|
||||
10
layouts/_default/index.js
Normal file
10
layouts/_default/index.js
Normal file
@@ -0,0 +1,10 @@
|
||||
var docs = [
|
||||
{{ range $index, $page := (where .Site.Pages "Section" "docs") -}}
|
||||
{
|
||||
id: {{ $index }},
|
||||
title: "{{ .Title }}",
|
||||
description: "{{ .Params.description }}",
|
||||
href: "{{ .URL | absURL }}"
|
||||
},
|
||||
{{ end -}}
|
||||
];
|
||||
5
layouts/_default/index.json
Normal file
5
layouts/_default/index.json
Normal file
@@ -0,0 +1,5 @@
|
||||
{{- $.Scratch.Add "index" slice -}}
|
||||
{{- range .Site.RegularPages -}}
|
||||
{{- $.Scratch.Add "index" (dict "title" .Title "description" .Params.description "contents" .Plain "permalink" .Permalink) -}}
|
||||
{{- end -}}
|
||||
{{- $.Scratch.Get "index" | jsonify -}}
|
||||
13
layouts/_default/list.html
Normal file
13
layouts/_default/list.html
Normal file
@@ -0,0 +1,13 @@
|
||||
{{ define "main" }}
|
||||
<div class="row justify-content-center">
|
||||
<div class="col-md-12 col-lg-10 col-xl-8">
|
||||
{{ range .Paginator.Pages }}
|
||||
<article>
|
||||
<h2><a href="{{ .Permalink }}">{{ .Title }}</a></h2>
|
||||
{{ .Description }}
|
||||
</article>
|
||||
{{ end }}
|
||||
{{ template "_internal/pagination.html" . }}
|
||||
</div>
|
||||
</div>
|
||||
{{ end }}
|
||||
46
layouts/_default/section.sitemap.xml
Normal file
46
layouts/_default/section.sitemap.xml
Normal file
@@ -0,0 +1,46 @@
|
||||
{{ printf "<?xml version=\"1.0\" encoding=\"utf-8\" standalone=\"yes\" ?>" | safeHTML -}}
|
||||
<urlset xmlns="http://www.sitemaps.org/schemas/sitemap/0.9"
|
||||
xmlns:xhtml="http://www.w3.org/1999/xhtml">
|
||||
{{ range $i, $e := .Data.Pages -}}
|
||||
{{ if ne .Params.sitemap_exclude true }}
|
||||
<url>
|
||||
<loc>{{ .Permalink }}</loc>{{ if not .Lastmod.IsZero }}
|
||||
<lastmod>{{ safeHTML ( .Lastmod.Format "2006-01-02T15:04:05-07:00" ) }}</lastmod>{{ end }}{{ with .Sitemap.ChangeFreq }}
|
||||
<changefreq>{{ . }}</changefreq>{{ end }}{{ if ge .Sitemap.Priority 0.0 }}
|
||||
<priority>{{ .Sitemap.Priority }}</priority>{{ end }}{{ if .IsTranslated }}{{ range .Translations }}
|
||||
<xhtml:link
|
||||
rel="alternate"
|
||||
hreflang="{{ .Lang }}"
|
||||
href="{{ .Permalink }}"
|
||||
/>{{ end }}
|
||||
<xhtml:link
|
||||
rel="alternate"
|
||||
hreflang="{{ .Lang }}"
|
||||
href="{{ .Permalink }}"
|
||||
/>{{ end }}
|
||||
</url>
|
||||
{{ end -}}
|
||||
{{ end -}}
|
||||
{{ range .Sections -}}
|
||||
{{ range $i, $e := .Data.Pages -}}
|
||||
{{ if ne .Params.sitemap_exclude true -}}
|
||||
<url>
|
||||
<loc>{{ .Permalink }}</loc>{{ if not .Lastmod.IsZero }}
|
||||
<lastmod>{{ safeHTML ( .Lastmod.Format "2006-01-02T15:04:05-07:00" ) }}</lastmod>{{ end }}{{ with .Sitemap.ChangeFreq }}
|
||||
<changefreq>{{ . }}</changefreq>{{ end }}{{ if ge .Sitemap.Priority 0.0 }}
|
||||
<priority>{{ .Sitemap.Priority }}</priority>{{ end }}{{ if .IsTranslated }}{{ range .Translations }}
|
||||
<xhtml:link
|
||||
rel="alternate"
|
||||
hreflang="{{ .Lang }}"
|
||||
href="{{ .Permalink }}"
|
||||
/>{{ end }}
|
||||
<xhtml:link
|
||||
rel="alternate"
|
||||
hreflang="{{ .Lang }}"
|
||||
href="{{ .Permalink }}"
|
||||
/>{{ end }}
|
||||
</url>
|
||||
{{ end -}}
|
||||
{{ end -}}
|
||||
{{ end -}}
|
||||
</urlset>
|
||||
10
layouts/_default/single.html
Normal file
10
layouts/_default/single.html
Normal file
@@ -0,0 +1,10 @@
|
||||
{{ define "main" }}
|
||||
<div class="row justify-content-center">
|
||||
<div class="col-md-12 col-lg-10 col-xl-8">
|
||||
<article>
|
||||
<h1>{{ .Title }}</h1>
|
||||
{{ .Content }}
|
||||
</article>
|
||||
</div>
|
||||
</div>
|
||||
{{ end }}
|
||||
Reference in New Issue
Block a user