Commit 8ed9f60af1

8ed9f60af1f1a3beca8f114db0175ce31f17822d

parent: 6e2e284468

Unsigned

cmc <hello@cleberg.net> · 2025-09-04 21:49 UTC

shift from monospace theme to a formalized serif theme

Layout: unified · split

build.py +5 −3
@@ -174,6 +174,7 @@ def get_recent_posts_html(content_dir="./content/blog", num_posts=3):
174174 if title and date_str and slug:
175175 try:
176176 date_obj = datetime.strptime(date_str, "%Y-%m-%d")
177 date_full = date_obj.strftime("%B %d, %Y")
177178 except ValueError:
178179 # Skip files with invalid date format
179180 continue
@@ -183,6 +184,7 @@ def get_recent_posts_html(content_dir="./content/blog", num_posts=3):
183184 "title": title,
184185 "date_str": date_str,
185186 "date_obj": date_obj,
187 "date_full": date_full,
186188 "slug": slug,
187189 "tags": tags,
188190 }
@@ -198,9 +200,6 @@ def get_recent_posts_html(content_dir="./content/blog", num_posts=3):
198200 lines = []
199201 for post in recent:
200202 lines.append('\t<div class="post">')
201 lines.append(
202 f'\t\t<time datetime="{post["date_str"]}">{post["date_str"]}</time>'
203 )
204203 lines.append('\t\t<div class="post-content">')
205204 lines.append(
206205 f'\t\t\t<a href="/blog/{post["slug"]}.html">{post["title"]}</a>'
@@ -211,6 +210,9 @@ def get_recent_posts_html(content_dir="./content/blog", num_posts=3):
211210 lines.append(f'\t\t\t\t<span class="tag">{tag}</span>')
212211 lines.append("\t\t\t</div>")
213212 lines.append("\t\t</div>")
213 lines.append(
214 f'\t\t<time datetime="{post["date_str"]}">{post["date_full"]}</time>'
215 )
214216 lines.append("\t</div>")
215217
216218 return "\n".join(lines)
theme/static/styles.css +15 −24
@@ -20,14 +20,8 @@ html{line-height:1.15;-webkit-text-size-adjust:100%}main{display:block}h1{font-s
2020body {
2121 background-color: var(--bg);
2222 color: var(--fg);
23 font-family:
24 Menlo,
25 Consolas,
26 Monaco,
27 Liberation Mono,
28 Lucida Console,
29 monospace;
30 font-size: 1rem;
23 font-family: Iowan Old Style, Apple Garamond, Baskerville, Times New Roman, Droid Serif, Times, Source Serif Pro, serif, Apple Color Emoji, Segoe UI Emoji, Segoe UI Symbol;
24 font-size: 1.25rem;
3125 line-height: 1.5;
3226 max-width: 50em;
3327 margin: 0 auto;
@@ -55,7 +49,7 @@ footer p {
5549}
5650
5751ul {
58 list-style-type: "- ";
52 list-style-type: "- ";
5953}
6054
6155.site-nav ul {
@@ -77,20 +71,20 @@ h4 {
7771}
7872
7973h1 {
80 font-size: 1.5rem;
74 font-size: 1.75rem;
8175 font-weight: bold;
8276 margin-top: 1rem;
8377 margin-bottom: 0.75rem;
8478}
8579
8680h2 {
87 font-size: 1.25rem;
81 font-size: 1.5rem;
8882 margin-top: 1rem;
8983 margin-bottom: 0.5rem;
9084}
9185
9286h3 {
93 font-size: 1rem;
87 font-size: 1.25rem;
9488 margin-top: 1rem;
9589 margin-bottom: 0.25rem;
9690}
@@ -123,13 +117,6 @@ table {
123117 border-collapse: collapse;
124118 color: var(--fg);
125119 border-color: var(--bg-bright);
126 font-family:
127 Menlo,
128 Consolas,
129 Monaco,
130 Liberation Mono,
131 Lucida Console,
132 monospace;
133120 font-size: inherit;
134121 width: 100%;
135122}
@@ -144,7 +131,6 @@ td {
144131
145132pre,
146133pre>code,
147time,
148134code {
149135 font-family:
150136 Menlo,
@@ -165,7 +151,6 @@ pre {
165151
166152:not(pre)>code {
167153 color: var(--code);
168 font-family: inherit;
169154}
170155
171156aside {
@@ -187,11 +172,14 @@ blockquote p {
187172.post,
188173.wiki-post {
189174 display: flex;
175 justify-content: space-between;
190176}
191177
192178.post time {
193179 flex-shrink: 0;
180 font-style: italic;
194181 margin-right: 0.5rem;
182 opacity: 0.8;
195183}
196184
197185.wiki-post {
@@ -220,6 +208,10 @@ blockquote p {
220208 margin: 0;
221209}
222210
211.post-metadata time {
212 font-style: italic;
213}
214
223215details {
224216 display: block;
225217 margin-top: 1rem;
@@ -273,15 +265,14 @@ span.tag::before {
273265}
274266
275267.post-tags {
276 font-size: 0.85rem;
277 color: #999;
268 font-size: 1rem;
278269 margin-top: 0.1rem;
279270}
280271
281272.tag {
282273 margin-right: 0.3rem;
283274 font-style: normal;
284 opacity: 0.8;
275 opacity: 0.5;
285276}
286277
287278.tag::before {
theme/templates/blog.html +3 −3
@@ -11,9 +11,6 @@ main %}
1111<br>
1212{% for post in posts %}
1313<div class="post">
14 <time datetime='{{ post.date | strftime("%Y-%m-%d") }}'
15 >{{ post.date|strftime("%Y-%m-%d") }}</time
16 >
1714 <div class="post-content">
1815 <a href='{{ url_for("blog", slug=post.slug) }}'>{{ post.title }}</a>
1916 {% if post.filetags %}
@@ -24,5 +21,8 @@ main %}
2421 </div>
2522 {% endif %}
2623 </div>
24 <time datetime='{{ post.date | strftime("%Y-%m-%d") }}'
25 >{{ post.date|strftime("%B %d, %Y") }}</time
26 >
2727</div>
2828{% endfor %} {% endblock %}
theme/templates/index.html +7 −5
@@ -1,10 +1,12 @@
11{% extends "base.html" %} {% block main %}
22<section>
3 <h1><i>~cmc</i></h1>
4 <pre>pub rsa4096 2022-11-16 [SC]
5 <a href="/gpg.txt">3917 973F B159 BBB8 6194 5385 6945 1A51 7AC0 CB37</a>
6uid [ultimate] Christian Cleberg &lt;hello@cleberg.net&gt;
7sub rsa4096 2022-11-16 [E]</pre>
3 <h1><i>Hi, I'm Christian.</i></h1>
4 <blockquote>
5 <b>shouganai</b>
6 <br>[sho-ga-n-eye] | しょうがない
7 <br><br>
8 <i>it is what it is</i>
9 </blockquote>
810</section>
911<section>
1012 <h2>Blog Posts</h2>
theme/templates/post.html +1 −1
@@ -12,7 +12,7 @@
1212 <h1>{{ post.title }}</h1>
1313 {% if post.date is defined %}
1414 <time datetime='{{ post.date|strftime("%Y-%m-%d") }}'
15 >&lt;{{ post.date|strftime("%Y-%m-%d %a %H:%M:%S") }}&gt;</time
15 >{{ post.date|strftime("%A, %B %d, %Y %H:%M:%S") }}</time
1616 >
1717 {% endif %} {% if post.filetags %}
1818 <p class="post-tags">
theme/templates/wiki.html +2 −2
@@ -4,9 +4,9 @@ main %}
44<p>Use <code>Ctrl + F</code> to search wiki pages for keywords.</p>
55{% for post in posts %}
66<div class="post">
7 <a href='{{ url_for("wiki", slug=post.slug) }}'>{{ post.title }}</a>
78 <time datetime='{{ post.date | strftime("%Y-%m-%d") }}'
8 >{{ post.date|strftime("%Y-%m-%d") }}</time
9 >{{ post.date|strftime("%B %d, %Y") }}</time
910 >
10 <a href='{{ url_for("wiki", slug=post.slug) }}'>{{ post.title }}</a>
1111</div>
1212{% endfor %} {% endblock %}