Create theme 3

This commit is contained in:
2021-10-01 14:12:39 -05:00
parent 4706208211
commit c961682d04
5 changed files with 32 additions and 71 deletions

View File

@ -4,21 +4,12 @@
{{- partial "head.html" . -}}
<body>
{{ partial "navbar.html" . }}
{{ partial "header.html" . }}
<div class="page">
{{ if and .Params.Toc .IsPage }}
<div class="side">
<h3>Table of Contents</h3>
{{ .TableOfContents }}
</div>
{{ end }}
<div class="content">
{{- block "main" . }}
{{ .Content }}
{{- end }}
</div>
<div class="content">
{{- block "main" . }}
{{ .Content }}
{{- end }}
</div>
{{- partial "footer.html" . -}}

View File

@ -23,5 +23,12 @@
{{ end }}
</span>
{{ if .Params.Toc }}
<div id="table-of-contents">
<h3>Table of Contents</h3>
{{ .TableOfContents }}
</div>
{{ end }}
{{ .Content }}
{{ end }}

View File

@ -0,0 +1,10 @@
<h2 class="header">
<a href="{{ "/" | relURL }}">{{ .Site.Title | markdownify }}</a>
</h2>
<nav id="navbar">
<a class="navbar-item" href="{{ "/" | relURL }}">Home</a>
{{ range .Site.Menus.main }}
<a class="navbar-item" href="{{ .URL }}">{{ .Name }}</a>
{{ end }}
</nav>

View File

@ -1,11 +0,0 @@
<nav id="navbar">
<div class="navbar-title">
<a href="{{ "/" | relURL }}">{{ .Site.Title | markdownify }}</a>
</div>
<div class="navbar-items">
{{ range .Site.Menus.main }}
<a href="{{ .URL }}">{{ .Name }}</a>
{{ end }}
</div>
</nav>