Cleanup and moved some site specific stuff to site

This commit is contained in:
Nox Sluijtman 2022-09-28 14:15:41 +02:00
parent d941df36e7
commit 4de188c7d9
14 changed files with 60 additions and 73 deletions

View file

@ -1,53 +1,43 @@
{{ define "main" }}
{{ if eq .Type $.Site.Params.contentTypeName }}
<div class="post-meta">
{{ if .Params.Date }}
<span class="post-date">
{{ .Date.Format "2006-01-02" }}
</span>
{{ end }}
{{ if eq .Type $.Site.Params.contentTypeName }}
<div class="post-meta">
{{ if .Params.Date }} <span class="post-date"> {{ .Date.Format "2006-01-02" }} </span> {{ end }}
{{ with .Params.Author }} <span> - </span> <span class="post-author">{{ . }}</span> {{ end }}
<span class="post-reading-time">- {{ .ReadingTime }} min read ({{ .WordCount }} words)</span>
</span>
{{ with .Params.Author }}
<span> - </span>
<span class="post-author">{{ . }}</span>
{{ end }}
{{ if and (.Param "readingTime") (eq (.Param "readingTime") true) }}
<span class="post-reading-time">- {{ .ReadingTime }} min read ({{ .WordCount }} words)</span>
{{ end }}
</span>
{{ if .Params.tags }}
<span class="post-tags">
{{ range .Params.tags }}
#<a href="{{ (urlize (printf "tags/%s/" .)) | absLangURL }}">{{ . }}</a>&nbsp;
{{ end }}
</span>
{{ end }}
</div>
{{ end }}
{{ if .Params.tags }}
<span class="post-tags">
{{ range .Params.tags }}
#<a href="{{ (urlize (printf "tags/%s/" .)) | absLangURL }}">{{ . }}</a>&nbsp;
{{ end }}
</span>
{{ end }}
</div>
{{ end }}
{{ if (.Params.Toc | default .Site.Params.Toc) }}
<div class="table-of-contents">
<h2>
{{ (.Params.TocTitle | default .Site.Params.TocTitle) | default "Table of Contents" }}
</h2>
{{ .TableOfContents }}
</div>
{{ end }}
{{ if (.Params.Toc | default .Site.Params.Toc) }}
<div class="table-of-contents">
<h2>
{{ (.Params.TocTitle | default .Site.Params.TocTitle) | default "Table of Contents" }}
</h2>
{{ .TableOfContents }}
</div>
{{ end }}
{{ if eq .Type $.Site.Params.contentTypeName }}
<div class="post-content">
{{- with .Content -}}
{{ . | replaceRE "(<h[1-9] id=\"([^\"]+)\".+)(</h[1-9]+>)" `${1} <a href="#${2}" class="anchor" ariaLabel="Anchor">#</a> ${3}` | safeHTML }}
{{- end -}}
</div>
{{ else }}
{{ .Content }}
{{ end }}
{{ if eq .Type $.Site.Params.contentTypeName }}
<div class="post-content">
{{- with .Content -}}
{{ . | replaceRE "(<h[1-9] id=\"([^\"]+)\".+)(</h[1-9]+>)" `${1} <a href="#${2}" class="anchor" ariaLabel="Anchor">#</a> ${3}` | safeHTML }}
{{- end -}}
</div>
{{ else }}
{{ .Content }}
{{ end }}
{{ if eq .Type $.Site.Params.contentTypeName }}
{{ partial "posts_pagination.html" . }}
{{ end }}
{{ if eq .Type $.Site.Params.contentTypeName }}
{{ partial "posts_pagination.html" . }}
{{ end }}
</div>
{{ end }}

View file

@ -1,6 +1,6 @@
<footer>
<div class="mirror">
<a rel="rss" href="/index.xml">[rss]</a>
[<a rel="rss" href="/index.xml">rss</a>]
[<a href="http://fxawfamgojpoxxgzmmjiro4wx4eycempujmryk6miz4a64ljl6sz7dqd.onion">onion</a>|<a href="http://lmwr2pugnmv4pkkxlneeepi4oysfly33zfuj7x25s6hfydysnpfq.b32.i2p">i2p</a>|<a href="http://[201:e2aa:7c70:666b:9a28:6406:be7f:bf0d]">yggdrasil</a>]
<a rel="lisence" href="http://creativecommons.org/licenses/by-sa/4.0/"><img alt="CC BY-SA 4.0" src="/stickers/cc4.png"></a>
</div>

View file

@ -1,14 +1,14 @@
<nav class="menu">
<a href="/">home </a>
<menu>
<a href="/">home<br/></a>
{{ range $.Site.Menus.main }}
{{ if not .HasChildren }}
<a href="{{ .URL }}">{{ .Name }} </a>
<a href="{{ .URL }}">{{ .Name }}<br/></a>
{{ end }}
{{ end }}
<hr />
{{ range $.Site.Menus.services }}
{{ if not .HasChildren }}
<a href="{{ .URL }}">{{ .Name }} </a>
<a href="{{ .URL }}">{{ .Name }}<br/></a>
{{ end }}
{{ end }}
</nav>
</menu>

View file

@ -1,8 +0,0 @@
<div class="stickers">
<a target="_blank" href="https://blackgnu.net/on-blockchain.html" ><img alt="Web 3 is a scam" src="/stickers/notoweb3.gif" /></a>
<a target="_blank" href="https://gemini.circumlunar.space/" ><img alt="Fuck Chromium" src="/stickers/same-shit-different-asshole_banner.gif" /></a>
<a target="_blank" href="https://www.vim.org" ><img alt="I ♡ vim" src="/stickers/edited-with-vim_banner.gif" /></a>
<a target="_blank" href="https://yewtu.be/watch?v=TdkdR92a7dU"><img alt="Nazi punks, fuck off!" src="/stickers/nonazis.png"></a>
<a target="_blank" href="https://wiby.me"><img alt="Wiby is great" src="/stickers/wiby.gif"></a>
<a target="_blank" href="https://anybrowser.org/campaign/"><img alt="Viewable in any browser" src="/stickers/4nobody.gif"></a>
</div>

View file

@ -1 +0,0 @@
<?xml version="1.0" encoding="iso-8859-1"?><!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd"><svg version="1.1" id="Capa_1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" x="0px" y="0px" viewBox="0 0 455.731 455.731" style="enable-background:new 0 0 455.731 455.731;" xml:space="preserve"><g><rect x="0" y="0" style="fill:#F78422;" width="455.731" height="455.731"/><g><path style="fill:#FFFFFF;" d="M296.208,159.16C234.445,97.397,152.266,63.382,64.81,63.382v64.348 c70.268,0,136.288,27.321,185.898,76.931c49.609,49.61,76.931,115.63,76.931,185.898h64.348 C391.986,303.103,357.971,220.923,296.208,159.16z"/><path style="fill:#FFFFFF;" d="M64.143,172.273v64.348c84.881,0,153.938,69.056,153.938,153.939h64.348 C282.429,270.196,184.507,172.273,64.143,172.273z"/><circle style="fill:#FFFFFF;" cx="109.833" cy="346.26" r="46.088"/></g></g></svg>

Before

Width:  |  Height:  |  Size: 920 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 2.9 KiB

View file

@ -1,7 +0,0 @@
<html>
<head><title>301 Moved Permanently</title></head>
<body bgcolor="white">
<center><h1>301 Moved Permanently</h1></center>
<hr><center>nginx</center>
</body>
</html>

Binary file not shown.

Before

Width:  |  Height:  |  Size: 446 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.3 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 2.2 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 2.5 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 16 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 2.1 KiB

View file

@ -24,10 +24,23 @@ main{ margin-left: 12em; margin-right: 1em; padding: 1em; border:1pt solid; mar
main h1{border-bottom: 1pt solid;}
main a h1 {border-bottom: transparent 0pt solid;}
li::marker{color: var(--ansi05);}
nav{height: 100%;padding: 0.5em; float:left; background: var(--ansi00-soft); border-right:solid 1pt; border-bottom: solid 1pt; width: 10em;}
nav li{list-style: none; list-style-position:outside;}
nav a{ display: block;}
nav{text-transform: capitalize;}
menu{
height: 100%;
padding: 0.5em;
float:left;
background: var(--ansi00-soft);
border-right:solid 1pt;
border-bottom: solid 1pt;
width: 10em;
text-transform: capitalize;
margin-top:0;
}
menu li{list-style: none; list-style-position:outside;}
menu a{ display: block;}
nav{
border-bottom: 1pt solid;
margin-bottom: .5em;
}
summary{cursor:pointer;}
summary:hover{ color: var(--ansi00-hard); background-color: var(--ansi11); }
footer{text-align:center; border-top:1pt solid; margin-top: 1em;}
@ -62,8 +75,8 @@ header{text-transform: capitalize; text-align:center;border-bottom:2pt solid; fo
}
@media (max-width: 800px){
main{max-width:100%; margin: 1em;}
nav{padding:0; width: 100%; border-right:solid 0pt;}
nav a{ padding-left: 1em;}
menu{padding:0; width: 100%; border-right:solid 0pt;}
menu a{ padding-left: 1em;}
}
.stickers{ text-align:center; }
.gay{