some changes to themes

This commit is contained in:
fzorb 2025-01-16 11:26:30 +02:00
parent 26c526e433
commit 8237b6aa19
51 changed files with 852 additions and 12 deletions

View file

@ -0,0 +1,5 @@
{{ partial "header.html" . }}
404 NOT FOUND
{{ partial "footer.html" . }}

View file

@ -0,0 +1,7 @@
!{{ .Title }}
{{ .RawContent }}
{{ range .Pages.ByPublishDate.Reverse }}
0{{ .Title }} {{ with .OutputFormats.Get "gopher" -}}{{ .RelPermalink }} {{ $.Site.Params.hostname}} 70 {{ end }}
{{ end }}

View file

@ -0,0 +1,21 @@
{{ partial "header.html" . }}
{{if not .IsHome }}
<h1>{{ .Title | markdownify }}</h1>
{{ end }}
{{ .Content }}
{{ $pages := .Pages }}
{{ if .IsHome }}{{ $pages = .Site.RegularPages }}{{ end }}
{{ range $index, $page := (where $pages "Section" "!=" "") }}
<div class="post">
<h3><a href="{{ .RelPermalink }}">{{ .Title | markdownify }}</a></h3>
<span class="date">Written on {{ .Date.Format "2006/01/02" }}</span>
<p>{{ .Summary }}</p>
</div>
{{ if not (eq $index (sub (len $pages) 1)) }}
<hr>
{{ end }}
{{ end }}
{{ partial "footer.html" . }}

View file

@ -0,0 +1,8 @@
# {{ .Title }}
{{ .Date.Format (.Site.Params.dateform | default "N/A") }}
{{ if .Params.tags }}
Posted in: {{ range .Params.tags }}{{ . }} {{ end }}
{{ end }}
{{ .RawContent }}

View file

@ -0,0 +1,12 @@
{{ partial "header.html" . }}
<div class="article-meta">
<h1><span class="title">{{ .Title | markdownify }}</span></h1>
{{ with .Params.author }}<h2 class="author">{{ . }}</h2>{{ end }}
{{ if (gt .Params.date 0) }}<h2 class="date">{{ .Date.Format "2006/01/02" }}</h2>{{ end }}
</div>
<main>
{{ .Content }}
</main>
{{ partial "footer.html" . }}

View file

@ -0,0 +1,13 @@
{{ partial "header.html" . }}
<h1>{{ .Title }}</h1>
<ul class="terms">
{{ range .Data.Terms }}
<li>
<a href="{{ .Page.RelPermalink }}">{{ .Page.Title }}</a> ({{ .Count }})
</li>
{{ end }}
</ul>
{{ partial "footer.html" . }}

View file

@ -0,0 +1,13 @@
!{{ .Title }}
{{ .RawContent }}
Site sections:
{{ range .Site.Menus.main }}
1{{ .Name }} {{ .Identifier }} {{ $.Site.Params.hostname }} 70
{{ end }}
Most recent articles
{{ range first 3 .Pages.ByPublishDate.Reverse }}
0{{ .Title }} {{ with .OutputFormats.Get "gopher" -}}{{ .RelPermalink }} {{ $.Site.Params.hostname }} 70 {{ end }}
{{ end }}

View file

@ -0,0 +1,6 @@
<div>
<select id="themes">
</select>
<button onclick="changetheme()">Change theme</button>
</div>
<div id="aaa"></div>

View file

@ -0,0 +1,9 @@
<footer>
{{ partial "foot_custom.html" . }}
{{ with .Site.Params.footer }}
<hr/>
{{ replace . "{Year}" now.Year | markdownify}}
{{ end }}
</footer>
</body>
</html>

View file

@ -0,0 +1,2 @@
<script defer src="/js/themes.js"></script>
<link rel="stylesheet" href="/css/themes/default.css">

View file

@ -0,0 +1,21 @@
<!DOCTYPE html>
<html lang="{{ .Site.LanguageCode }}">
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
<title>{{ .Title }} | {{ .Site.Title }}</title>
<link rel="stylesheet" href="{{ "css/style.css" | relURL }}" />
<link rel="stylesheet" href="{{ "css/fonts.css" | relURL }}" />
{{ partial "head_custom.html" . }}
</head>
<body>
<nav>
<ul class="menu">
<h1>{{ .Site.Title }}</h1>
{{ range .Site.Menus.main }}
<li><a href="{{ .URL | relURL }}">{{ .Name }}</a></li>
{{ end }}
</ul>
<hr/>
</nav>