Commit d7e9ad3

HPCesia <me@hpcesia.com>
2026-03-13 08:58:24
Document metadata in PDF archive
1 parent 82fc9b0
Changed files (2)
src
contents
pages
posts
src/contents/_lib/tybios.typ
@@ -19,5 +19,15 @@
   show: heading-template
   show: raw-template
 
+  context {
+    let frontmatter = query(<frontmatter>).first(default: (value: (title: "", date: auto))).value
+    set document(
+      title: frontmatter.title,
+      date: frontmatter.date,
+      description: frontmatter.at("desc", default: none),
+    )
+    if frontmatter.title != "" { title() }
+  }
+
   body
 }
src/pages/posts/[slug]/index.astro
@@ -28,7 +28,6 @@ const { Content } = await render(entry);
   isArticle={true}
 >
   <article>
-    <h1>{data.title}</h1>
     <Content />
   </article>
   <footer class="mt-8 article-anchor">