initial commit

This commit is contained in:
Jan Wolff 2022-11-05 20:00:03 +01:00
commit f6b4208301
116 changed files with 1156 additions and 0 deletions

20
themes/janw/LICENSE Normal file
View file

@ -0,0 +1,20 @@
The MIT License (MIT)
Copyright (c) 2022 YOUR_NAME_HERE
Permission is hereby granted, free of charge, to any person obtaining a copy of
this software and associated documentation files (the "Software"), to deal in
the Software without restriction, including without limitation the rights to
use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of
the Software, and to permit persons to whom the Software is furnished to do so,
subject to the following conditions:
The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS
FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR
COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER
IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.

View file

@ -0,0 +1,2 @@
+++
+++

View file

View file

@ -0,0 +1,9 @@
<!DOCTYPE html>
<html lang="en">
{{- partial "head.html" . -}}
<body>
{{- partial "header.html" . -}}
{{- block "main" . }}{{- end }}
{{- partial "footer.html" . -}}
</body>
</html>

View file

@ -0,0 +1,21 @@
{{ define "main" }}
<main class="big-container">
<article>
<header>
<h1>{{.Title}}</h1>
</header>
{{.Content}}
</article>
<ul class="blogtoc">
{{ range .Pages }}
<li>
<a class="sub-container" href="{{.Permalink}}">
<span>{{.Date.Format "02. January 2006"}}</span><br>
<span>{{.Title}}</span>
</a>
</li>
{{ end }}
</ul>
</main>
{{ end }}

View file

@ -0,0 +1,36 @@
{{ define "main" }}
<section id="main" class="big-container">
<h1 id="title">{{ .Title }} ({{ .Date.Format "2. January 2006" }})</h1>
<div>
<article id="content">
{{ .Content }}
</article>
</div>
</section>
<aside id="meta" class="big-container">
<div>
{{ with .Params.topics }}
<ul id="topics">
{{ range . }}
<li><a href="{{ "topics" | absURL}}{{ . | urlize }}">{{ . }}</a> </li>
{{ end }}
</ul>
{{ end }}
{{ with .Params.tags }}
<ul id="tags">
{{ range . }}
<li> <a href="{{ "tags" | absURL }}{{ . | urlize }}">{{ . }}</a> </li>
{{ end }}
</ul>
{{ end }}
</div>
<div>
{{ with .NextInSection }}
<p>Next: <a class="next" href="{{.Permalink}}"> {{.Title}}</a></p>
{{ end }}
{{ with .PrevInSection }}
<p>Previous: <a class="previous" href="{{.Permalink}}"> {{.Title}}</a></p>
{{ end }}
</div>
</aside>
{{ end }}

View file

@ -0,0 +1,19 @@
{{ define "main" }}
<main class="big-container">
<header>
<h1>{{.Title}}</h1>
{{ with .Params.subtitle }}
<span class="subtitle">{{.}}</span>
{{ end }}
</header>
<div class="content">
<!-- Note that the content for index.html, as a sort of list page, will pull from content/_index.md -->
{{.Content}}
</div>
<div>
{{ range first 10 .Site.RegularPages }}
{{ .Render "summary"}}
{{ end }}
</div>
</main>
{{ end }}

View file

View file

@ -0,0 +1,8 @@
<head>
<title>{{ .Title }} | janw.name</title>
<meta name="generator" content="Hugo {{ hugo.Version }}">
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0, user-scalable=yes">
<link rel="stylesheet" type="text/css" href="/css/style.css">
<link href="data:," rel="icon">
</head>

View file

@ -0,0 +1,35 @@
<header>
<a class="title" href="{{ .Site.BaseURL }}">{{ .Site.Title }}</a>
<span class="subtitle">{{ .Site.Params.subtitle }}</span>
<nav class="nav-container">
<ul>
{{ $currentPage := . }}
{{ range .Site.Menus.main }}
{{ if .HasChildren }}
<li class="{{ if $currentPage.HasMenuCurrent "main" . }}active{{ end }}">
<a href="#">
{{ .Pre }}
<span>{{ .Name }}</span>
</a>
</li>
<ul class="sub-menu">
{{ range .Children }}
<li class="{{ if $currentPage.IsMenuCurrent "main" . }}active{{ end }}">
<a href="{{ .URL }}">{{ .Name }}</a>
</li>
{{ end }}
</ul>
{{ else }}
{{ $menu_item_url := .URL | relLangURL }}
{{ $page_url:= $currentPage.RelPermalink | relLangURL }}
<li class="{{ if eq $menu_item_url $page_url }}active{{ end }}">
<a href="{{ .URL }}">
{{ .Pre }}
<span>{{ .Name }}</span>
</a>
</li>
{{ end }}
{{ end }}
</ul>
</nav>
</header>

View file

@ -0,0 +1,26 @@
{{ define "main" }}
<main class="big-container">
<article>
<header>
<h1>{{.Title}}</h1>
</header>
{{.Content}}
</article>
<ul class="projecttoc">
{{ range .Pages }}
<li>
<a class="sub-container" href="{{.Permalink}}">
{{if .Params.teaser}}
<div class="img-container">
<div class="img-container-child" style="background-image: url({{.Params.teaser}})">
</div>
</div>
{{end}}
<span>{{.Title}}</span>
</a>
</li>
{{ end }}
</ul>
</main>
{{ end }}

View file

@ -0,0 +1,28 @@
{{ define "main" }}
<section id="main" class="big-container">
<h1 id="title">{{ .Title }}</h1>
<div>
<article id="content">
{{ .Content }}
</article>
</div>
</section>
<aside id="meta" class="big-container">
<div>
{{ with .Params.topics }}
<ul id="topics">
{{ range . }}
<li><a href="{{ "topics" | absURL}}{{ . | urlize }}">{{ . }}</a> </li>
{{ end }}
</ul>
{{ end }}
{{ with .Params.tags }}
<ul id="tags">
{{ range . }}
<li> <a href="{{ "tags" | absURL }}{{ . | urlize }}">{{ . }}</a> </li>
{{ end }}
</ul>
{{ end }}
</div>
</aside>
{{ end }}

View file

@ -0,0 +1,192 @@
@font-face {
font-family: Catamaran;
src: url(/fonts/catamaran.ttf);
}
html {
overflow-y: scroll;
}
body {
background: white;
background-size: cover;
background-attachment: fixed;
font-family: Catamaran, sans-serif;
max-width: 60em;
margin: auto;
padding: 1.5em;
hyphens: auto;
cursor: default;
}
header {
text-align: center;
}
header .title {
display: block;
font-size: 2em;
}
header .subtitle {
display: block;
font-size: 1.1em;
}
.nav-container {
display: block;
background: #ffffffb3;
backdrop-filter: blur(32px);
padding: 1rem;
margin: 2rem;
border-style: solid;
border-width: 1px;
border-color: #b1b1b1;
border-radius: 0.5rem;
box-shadow: rgba(0, 0, 0, 0.5) 0 0.25rem 0.2rem;
}
.big-container {
display: block;
padding: 1rem;
margin: 2rem;
}
.sub-container {
display: block;
background: rgb(251, 255, 252);
padding: 0.75rem;
margin: 1rem;
border-radius: 0.5rem;
box-shadow: rgba(0, 0, 0, 0.45) 0 0.25rem 0.2rem;
transition: color 0.2s, box-shadow 0.2s;
}
.sub-container:hover {
box-shadow: rgba(0, 0, 0, 0.2) 0 0.5rem 0.5rem;
}
.sub-container .img-container {
border-radius: 0.5rem;
width: 100%;
height: 14rem;
overflow: hidden;
}
.img-container .img-container-child {
width: 100%;
height: 100%;
background-size: cover;
background-position: center;
transition: transform 0.5s;
}
.sub-container:hover .img-container-child {
transform: scale(1.1);
}
hr {
border-width: 0 0 1px 0;
}
p {
text-align: justify;
}
nav ul {
list-style-type: none;
margin: 0;
padding: 0;
}
nav li {
display: inline-block;
padding: 0 0 0 1em;
}
nav a {
text-decoration: none;
}
nav li.active a {
text-decoration: underline;
}
ul.blogtoc, ul.projecttoc {
list-style-type: none;
padding: 0;
}
ul.blogtoc li {
margin: 1em 0;
}
.projecttoc {
display: flex;
flex-wrap: wrap;
}
ul.projecttoc li {
flex: 1 0 50%;
}
pre {
border-style: ridge;
border-color: #e0e0e0;
margin: 1em;
padding: 0.5em;
max-width: 100%;
overflow-x: scroll;
}
footer {
margin-top: 4em;
font-size: 0.8em;
transition: opacity 0.2s;
}
@media (max-width: 30em) {
nav ul {
float: none;
}
nav li {
display: block;
padding: 0;
margin: 0.2em 0;
}
}
a {
color: #108f10;
transition: color 0.2s;
}
a:hover {
color: #59aa59;
}
::selection {
color: #ffffff;
background: #108f10;
}
@media (prefers-color-scheme: -dark) {
a {
color: #5fe35f;
}
body {
background: #0d0d0d;
color: #ebebeb;
}
::selection {
color: #0d0d0d;
background: #5fe35f;
}
pre {
border-color: #5f5f5f;
}
}

Binary file not shown.

View file

@ -0,0 +1,139 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<!-- Created with Inkscape (http://www.inkscape.org/) -->
<svg
width="1920"
height="1080"
viewBox="0 0 507.99999 285.75"
version="1.1"
id="svg5"
inkscape:export-filename="bitmap.png"
inkscape:export-xdpi="96"
inkscape:export-ydpi="96"
inkscape:version="1.2.1 (9c6d41e410, 2022-07-14)"
sodipodi:docname="bliss_v2.svg"
xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
xmlns:xlink="http://www.w3.org/1999/xlink"
xmlns="http://www.w3.org/2000/svg"
xmlns:svg="http://www.w3.org/2000/svg">
<sodipodi:namedview
id="namedview7"
pagecolor="#ffffff"
bordercolor="#000000"
borderopacity="0.25"
inkscape:showpageshadow="2"
inkscape:pageopacity="0.0"
inkscape:pagecheckerboard="0"
inkscape:deskcolor="#d1d1d1"
inkscape:document-units="mm"
showgrid="false"
inkscape:zoom="0.52850974"
inkscape:cx="1051.0686"
inkscape:cy="488.16508"
inkscape:window-width="1920"
inkscape:window-height="1011"
inkscape:window-x="0"
inkscape:window-y="32"
inkscape:window-maximized="1"
inkscape:current-layer="layer1" />
<defs
id="defs2">
<linearGradient
inkscape:collect="always"
id="linearGradient1759">
<stop
style="stop-color:#488650;stop-opacity:1;"
offset="0"
id="stop1753" />
<stop
style="stop-color:#6cc553;stop-opacity:1;"
offset="0.99588585"
id="stop1755" />
<stop
style="stop-color:#609f4f;stop-opacity:1;"
offset="1"
id="stop1757" />
</linearGradient>
<linearGradient
inkscape:collect="always"
id="linearGradient1089">
<stop
style="stop-color:#5ffff8;stop-opacity:1;"
offset="0"
id="stop1085" />
<stop
style="stop-color:#3bc8ff;stop-opacity:1;"
offset="1"
id="stop1087" />
</linearGradient>
<linearGradient
inkscape:collect="always"
id="linearGradient981">
<stop
style="stop-color:#488650;stop-opacity:1;"
offset="0"
id="stop977" />
<stop
style="stop-color:#6cc553;stop-opacity:1;"
offset="0.41906768"
id="stop979" />
<stop
style="stop-color:#609f4f;stop-opacity:1;"
offset="1"
id="stop1083" />
</linearGradient>
<linearGradient
inkscape:collect="always"
xlink:href="#linearGradient981"
id="linearGradient983"
x1="408.03757"
y1="344.96191"
x2="399.67575"
y2="-67.29834"
gradientUnits="userSpaceOnUse"
gradientTransform="matrix(1,0,0,0.76089584,2.4372298,78.75124)" />
<linearGradient
inkscape:collect="always"
xlink:href="#linearGradient1089"
id="linearGradient1091"
x1="244.25633"
y1="-42.323292"
x2="246.98541"
y2="280.41006"
gradientUnits="userSpaceOnUse" />
<radialGradient
inkscape:collect="always"
xlink:href="#linearGradient1759"
id="radialGradient878"
cx="219.91843"
cy="253.72072"
fx="219.91843"
fy="253.72072"
r="301.68893"
gradientTransform="matrix(1.5629957,-0.16194789,0.03553191,0.34292654,-123.3472,176.92581)"
gradientUnits="userSpaceOnUse" />
</defs>
<g
inkscape:label="Layer 1"
inkscape:groupmode="layer"
id="layer1">
<rect
style="fill:url(#linearGradient1091);stroke-width:2;fill-opacity:1"
id="rect290"
width="542.92847"
height="348.60181"
x="-25.979242"
y="-18.289528" />
<path
style="fill:url(#radialGradient878);fill-opacity:1;stroke-width:1.93033"
d="m -45.271612,204.48708 c 0,0 120.50742,-85.3169 297.587472,-70.37337 199.11297,16.80286 277.74146,20.4529 277.74146,20.4529 l 11.45796,135.875 c 0,0 -603.930805,-8.61974 -603.37747,-10.94919 0.553334,-2.32945 16.590578,-75.00534 16.590578,-75.00534 z"
id="path236-5"
sodipodi:nodetypes="csccsc" />
<path
style="fill:url(#linearGradient983);fill-opacity:1;stroke-width:1.74459"
d="m -14.852338,204.4164 c 0,0 59.498122,20.02135 197.333818,-16.74074 177.93107,-47.4559 351.67522,-8.8604 351.67522,-8.8604 l 2.77836,137.56279 c 0,0 -558.320143,-7.61591 -557.808598,-9.67407 0.511545,-2.05817 6.0212,-102.28758 6.0212,-102.28758 z"
id="path236"
sodipodi:nodetypes="csccsc" />
</g>
</svg>

After

Width:  |  Height:  |  Size: 4.5 KiB

21
themes/janw/theme.toml Normal file
View file

@ -0,0 +1,21 @@
# theme.toml template for a Hugo theme
# See https://github.com/gohugoio/hugoThemes#themetoml for an example
name = "Janw"
license = "MIT"
licenselink = "https://github.com/yourname/yourtheme/blob/master/LICENSE"
description = ""
homepage = "http://example.com/"
tags = []
features = []
min_version = "0.41.0"
[author]
name = ""
homepage = ""
# If porting an existing theme
[original]
name = ""
homepage = ""
repo = ""