From 0af506805d774907a117123dc7398240c5aebf82 Mon Sep 17 00:00:00 2001 From: Barrett Ruth Date: Tue, 11 Nov 2025 15:32:57 -0500 Subject: [PATCH 1/2] cleanup toc --- public/styles/posts.css | 9 ++++++++- src/components/TableOfContents.astro | 8 +++++--- 2 files changed, 13 insertions(+), 4 deletions(-) diff --git a/public/styles/posts.css b/public/styles/posts.css index d3c16ef..9b17119 100644 --- a/public/styles/posts.css +++ b/public/styles/posts.css @@ -9,7 +9,7 @@ li { .toc-column { position: absolute; - left: 2rem; + left: calc((100vw - min(65vw, 800px)) / 4 - 100px); top: 0; width: 200px; padding-top: 190px; @@ -78,6 +78,9 @@ article h3, .post-article h3 { font-weight: normal; position: relative; + display: flex; + justify-content: space-between; + align-items: baseline; } article h1, @@ -124,6 +127,10 @@ article h3::before, margin-right: 0.5em; } +.date { + font-size: 0.67em; +} + article img { display: block; margin: 2rem auto; diff --git a/src/components/TableOfContents.astro b/src/components/TableOfContents.astro index b2e97ee..b567f49 100644 --- a/src/components/TableOfContents.astro +++ b/src/components/TableOfContents.astro @@ -22,7 +22,7 @@ const tocHeadings = headings.filter((h) => h.depth <= 2); {tocHeadings.map((heading) => ( {heading.text} @@ -49,6 +49,8 @@ const tocHeadings = headings.filter((h) => h.depth <= 2); flex-direction: column; gap: 0.3rem; align-items: flex-start; + margin: 0; + padding: 0; } .toc-nav a { @@ -62,11 +64,11 @@ const tocHeadings = headings.filter((h) => h.depth <= 2); text-decoration: underline; } - .toc-nav a.main { + .toc-nav a.h1-link { padding-left: 0; } - .toc-nav a.sub { + .toc-nav a.h2-link { padding-left: 1.5rem; } From f08e7d335a9373911e9ce8550c9f414208201481 Mon Sep 17 00:00:00 2001 From: Barrett Ruth Date: Tue, 11 Nov 2025 15:35:28 -0500 Subject: [PATCH 2/2] fix: align dates --- public/styles/posts.css | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/public/styles/posts.css b/public/styles/posts.css index 9b17119..67f35ae 100644 --- a/public/styles/posts.css +++ b/public/styles/posts.css @@ -80,7 +80,7 @@ article h3, position: relative; display: flex; justify-content: space-between; - align-items: baseline; + align-items: center; } article h1,