Commit cbe69c2

HPCesia <me@hpcesia.com>
2026-03-05 10:22:47
Move template to `tybios` namespace
1 parent 47e1468
Changed files (5)
src/contents/_lib/lib.typ
@@ -1,18 +1,4 @@
 #import "mathyml/src/lib.typ" as mathyml
-
-#import mathyml: to-mathml
 #import mathyml.prelude: *
 
-#import "./templates/raw.typ": raw-template
-#import "./templates/heading.typ": heading-template
-#import "./templates/footnote.typ": footnote-template
-
-#let post-template(body) = {
-  show math.equation: to-mathml
-
-  show: heading-template
-  show: footnote-template
-  show: raw-template
-
-  body
-}
+#import "./tybios.typ" as tybios
src/contents/_lib/tybios.typ
@@ -0,0 +1,15 @@
+#let post-template(body) = {
+  import "./mathyml/src/lib.typ": to-mathml
+
+  import "./templates/raw.typ": raw-template
+  import "./templates/heading.typ": heading-template
+  import "./templates/footnote.typ": footnote-template
+
+  show math.equation: to-mathml
+
+  show: heading-template
+  show: footnote-template
+  show: raw-template
+
+  body
+}
src/contents/posts/test.typ
@@ -1,5 +1,5 @@
-#import "../_lib/lib.typ":*
-#show: post-template
+#import "../_lib/lib.typ": *
+#show: tybios.post-template
 
 #metadata(
   (
src/contents/about.typ
@@ -1,5 +1,5 @@
 #import "./_lib/lib.typ": *
-#show: post-template
+#show: tybios.post-template
 
 #lorem(50)
 
src/contents/home.typ
@@ -1,5 +1,5 @@
 #import "./_lib/lib.typ": *
-#show: post-template
+#show: tybios.post-template
 
 #lorem(50)