From 8d831af216f09fac9cec72d0a10c91991e0fd0ab Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sergio=20Mart=C3=ADnez=20Portela?= Date: Mon, 25 Jul 2022 12:19:10 +0200 Subject: [PATCH] Add blog/post header. --- static/article.tmpl.html | 27 ++++++++++++++++++++++---- static/style.css | 41 +++++++++++++++++++++++++++++++++++++++- 2 files changed, 63 insertions(+), 5 deletions(-) diff --git a/static/article.tmpl.html b/static/article.tmpl.html index 7f11585..144132b 100644 --- a/static/article.tmpl.html +++ b/static/article.tmpl.html @@ -9,9 +9,28 @@ -
-

{{ title }}

- {{ content | safe }} -
+ +
+
+

{{ title }}

+ {{ content | safe }} +
+
diff --git a/static/style.css b/static/style.css index 191a919..47d189e 100644 --- a/static/style.css +++ b/static/style.css @@ -1,4 +1,9 @@ /* Default theme */ +html, body { + margin: 0; + padding: 0; +} + /* Node styling */ .node { max-width: min(650px, 100ex); @@ -87,10 +92,33 @@ code { font-size: 85%; } +.content { + margin: 1ex; +} + article.post { max-width: min(650px, 100ex); margin: 0 auto; } +/* Header */ +.site-header { + background-color: #F7F7FF; + border-bottom: rgba(0,0,0,0.1) 1px solid; + text-align: center; + padding: 1ex; +} +.site-header h1 { + margin-top: 0; + font-size: 200%; +} +.site-header .site-links .fancy-link { + border-right: 1px solid #000; + padding-left: 0.75ex; +} +.site-header .site-links .fancy-link:last-child { + border: none; +} + /* Dark mode. */ @media (prefers-color-scheme: dark) { @@ -108,6 +136,18 @@ article.post { margin-top: 0; color: #f7da4a; } + /* Header */ + .site-header { + background-color: #303330; + border-bottom: rgba(0,0,0,0.1) 1px solid; + } + .site-header h1 { + color: #fff; + } + .site-header .site-links .fancy-link { + border-right: 1px solid #fff; + } + /* Code blocks */ pre { padding: 0.5ex; @@ -127,6 +167,5 @@ article.post { color: #FFF; font-family: Menlo, Monaco, "Courier New", monospace; font-size: 85%; - } }