From e4a8a804aa5353bcaa4403da291e02bd9fcd22db Mon Sep 17 00:00:00 2001 From: Friedrich Beckmann Date: Sat, 14 Jun 2025 13:48:40 +0200 Subject: initial version --- themes/fredo/assets/Iwona-Regular.otf | Bin 0 -> 151936 bytes themes/fredo/assets/favicon.png | Bin 0 -> 9927 bytes themes/fredo/assets/style.css | 190 +++++++++++++++++++++++++ themes/fredo/layouts/_markup/render-image.html | 12 ++ themes/fredo/layouts/_partials/nav.html | 20 +++ themes/fredo/layouts/_partials/post-short.html | 40 ++++++ themes/fredo/layouts/_shortcodes/audio.html | 10 ++ themes/fredo/layouts/_shortcodes/video.html | 6 + themes/fredo/layouts/baseof.html | 39 +++++ themes/fredo/layouts/list.html | 12 ++ themes/fredo/layouts/single.html | 30 ++++ 11 files changed, 359 insertions(+) create mode 100644 themes/fredo/assets/Iwona-Regular.otf create mode 100644 themes/fredo/assets/favicon.png create mode 100644 themes/fredo/assets/style.css create mode 100644 themes/fredo/layouts/_markup/render-image.html create mode 100644 themes/fredo/layouts/_partials/nav.html create mode 100644 themes/fredo/layouts/_partials/post-short.html create mode 100644 themes/fredo/layouts/_shortcodes/audio.html create mode 100644 themes/fredo/layouts/_shortcodes/video.html create mode 100644 themes/fredo/layouts/baseof.html create mode 100644 themes/fredo/layouts/list.html create mode 100644 themes/fredo/layouts/single.html (limited to 'themes') diff --git a/themes/fredo/assets/Iwona-Regular.otf b/themes/fredo/assets/Iwona-Regular.otf new file mode 100644 index 0000000..418a664 Binary files /dev/null and b/themes/fredo/assets/Iwona-Regular.otf differ diff --git a/themes/fredo/assets/favicon.png b/themes/fredo/assets/favicon.png new file mode 100644 index 0000000..c17b537 Binary files /dev/null and b/themes/fredo/assets/favicon.png differ diff --git a/themes/fredo/assets/style.css b/themes/fredo/assets/style.css new file mode 100644 index 0000000..2238f88 --- /dev/null +++ b/themes/fredo/assets/style.css @@ -0,0 +1,190 @@ +@font-face { + font-family: 'Iwona'; + font-style: normal; + font-weight: 300; + font-display: swap; + src: local('Iwona-Regular'), url('Iwona-Regular.otf'), format('opentype'); +} + +body { + height: 100%; + max-height: 100%; + font-family: "Iwona"; +/* letter-spacing: 0.01rem; + font-size: 1.8rem; + line-height: 1.75em; + margin: 0;*/ +} + +#logo { + float: left; +} + +#nav { + margin-left: 52px; + margin-top: 0.5rem; +} + +.navlink { + margin: 0.3rem; +} + +.navlink.active { + background-color: aquamarine; +} + + +#topbar { + display: inline-block; +} + + +/* Every post, on every page, gets this style on its
tag */ +.post { + /*position: relative;*/ + width: 95%; + max-width: 710px; + margin: 1rem; + margin-left:3rem; + padding-bottom: 1rem; + border-bottom: #000 2px solid; + word-wrap: break-word; + display: inline-block; +} + +.post-title a { + text-decoration: none; + font-size: 1.5rem; +} +.post-excerpt p { + font-size: 0.9em; + line-height: 1.7em; + margin-block-start: 0rem; + margin-block-end: 0rem; +} +.read-more { + text-decoration: none; +} +.post-meta { + display: block; + margin: 2rem 0 0 0; + font-size: 1.5rem; +} +.post-meta a { + text-decoration: none; +} +.post-date { + display: inline-block; + white-space: nowrap; + margin-block-start: 0rem; + margin-block-end: 0rem; +} + +.post-date p{ + margin-block-start: 0rem; + margin-block-end: 0rem; +} +.publish-meta { + position: absolute; + top: 0; + right: 0; + padding: 4.3rem 0 4rem 0; + text-align: right; +} +.publish-heading { + display: block; + font-weight: 700; +} +.publish-date { + display: block; + font-size: 1.4rem; + line-height: 1.5em; +} + +.thumb { + float: left; + width: 240px; +} + +.post-short { + margin-left: 250px; +} + +.post-header h2 { + font-size: 1.2rem; +} +.post-title { + margin-block-start: 0rem; + margin-block-end: 0rem; +} + +.post-excerpt { + margin-top: 0.5rem; + margin-block-start: 0rem; + margin-block-end: 0rem; +} + +.gallery-photo { + max-width: 100%; + object-fit: fill; +} + + +#content { + padding: 3em 4em; + position: relative; +} + +.full { + max-width: 50rem; +} +.full img { + width: 80%; +} + +.full video { + width: 80%; +} + + + +@media screen and (max-width: 600px) { +.thumb { + float: none; + width: 100%; + margin-left: 0rem; +} + +.post { + /*position: relative;*/ + width: 95%; + max-width: 710px; + margin: 1rem; + margin-left:0rem; + padding-bottom: 1rem; + border-bottom: #000 2px solid; + word-wrap: break-word; + display: inline-block; +} + +.post-short { + margin-left: 5px; +} + +#content { + padding: 0em; + position: relative; +} + +.full img { + width: 100%; +} + +.full video { + width: 100%; +} + +.small-figure { + margin: 0rem; +} +} \ No newline at end of file diff --git a/themes/fredo/layouts/_markup/render-image.html b/themes/fredo/layouts/_markup/render-image.html new file mode 100644 index 0000000..86891e7 --- /dev/null +++ b/themes/fredo/layouts/_markup/render-image.html @@ -0,0 +1,12 @@ +{{ $myimg := resources.Get .Destination }} +{{ if $myimg }} + {{ $myimg := $myimg.Resize "1024x" }} +
+ + {{ .PlainText }} + + +
+{{ else }} + {{ errorf "Can not find image: %s" .Destination }} +{{ end }} \ No newline at end of file diff --git a/themes/fredo/layouts/_partials/nav.html b/themes/fredo/layouts/_partials/nav.html new file mode 100644 index 0000000..583eefe --- /dev/null +++ b/themes/fredo/layouts/_partials/nav.html @@ -0,0 +1,20 @@ +
+ + +
diff --git a/themes/fredo/layouts/_partials/post-short.html b/themes/fredo/layouts/_partials/post-short.html new file mode 100644 index 0000000..808297d --- /dev/null +++ b/themes/fredo/layouts/_partials/post-short.html @@ -0,0 +1,40 @@ +
+
+ {{ if .Param "image" }} + {{ $imagename := .Param "image" }} + {{ $myimg := resources.Get $imagename }} + {{ if $myimg }} + {{ $myimg := $myimg.Resize "512x" }} + + + + {{ .Title }} + + + {{ else }} + {{ errorf "Can not find image: %s" $imagename }} + {{ end }} + {{ end }} +
+
+ +
+

+ {{ .Title }} +

+
+
+

{{ .Param "summary" }}

+
+
+
diff --git a/themes/fredo/layouts/_shortcodes/audio.html b/themes/fredo/layouts/_shortcodes/audio.html new file mode 100644 index 0000000..d44de40 --- /dev/null +++ b/themes/fredo/layouts/_shortcodes/audio.html @@ -0,0 +1,10 @@ + + + + + +
{{- .Get "caption" -}}: + +
diff --git a/themes/fredo/layouts/_shortcodes/video.html b/themes/fredo/layouts/_shortcodes/video.html new file mode 100644 index 0000000..debe1d4 --- /dev/null +++ b/themes/fredo/layouts/_shortcodes/video.html @@ -0,0 +1,6 @@ +
+ + +
\ No newline at end of file diff --git a/themes/fredo/layouts/baseof.html b/themes/fredo/layouts/baseof.html new file mode 100644 index 0000000..92c0ca3 --- /dev/null +++ b/themes/fredo/layouts/baseof.html @@ -0,0 +1,39 @@ + + + + + + + + + {{ if .Title }} + {{ site.Title }} | {{ .Title }} + {{ else }} + {{ site.Title }} + {{ end }} + {{ $favicon := resources.Get "favicon.png" }} + + + + + {{ $css := resources.Get "style.css" }} + + {{ $font := resources.Get "Iwona-Regular.otf" }} + + + + + + + + {{ partial "nav.html" . }} +
+
+ {{ block "main" . }}{{ end }} +
+
+ + + diff --git a/themes/fredo/layouts/list.html b/themes/fredo/layouts/list.html new file mode 100644 index 0000000..d041c58 --- /dev/null +++ b/themes/fredo/layouts/list.html @@ -0,0 +1,12 @@ +{{ define "main" }} + {{ $pagelist := .RegularPagesRecursive.ByDate.Reverse }} + {{ if .IsHome }} + {{ $pagelist = where .RegularPagesRecursive.ByDate.Reverse "Section" "posts"}} + {{ end }} + {{ range $pagelist }} + {{ partial "post-short.html" . }} + {{ end }} +
+ {{ .Content }} +
+{{ end }} \ No newline at end of file diff --git a/themes/fredo/layouts/single.html b/themes/fredo/layouts/single.html new file mode 100644 index 0000000..11efc31 --- /dev/null +++ b/themes/fredo/layouts/single.html @@ -0,0 +1,30 @@ +{{ define "main" }} +
+ {{ if eq .Type "posts" }} + + {{ end }} + {{ if .Param "Image" }} + {{ $imagename := .Param "image" }} + {{ $myimg := resources.Get $imagename }} + {{ if $myimg }} + {{ $myimg := $myimg.Resize "1024x" }} +
+ + + {{ .Title }} + + +
+ {{ else }} + {{ errorf "Can not find image: %s" $imagename }} + {{ end }} + {{ end }} + + +

{{ .Title }}

+ {{ .Content }} +
+ +{{ end }} \ No newline at end of file -- cgit v1.2.3