Add series links

This commit is contained in:
Nathan McCarty 2025-02-09 02:43:22 -05:00
parent d170a2fccf
commit 4793d660e2
6 changed files with 54 additions and 10 deletions

View file

@ -11,14 +11,15 @@ use DB::Post;
unit class Config;
# TODO: Support GFM admonitions
method generate-post(Post:D $post, BlogMeta:D $meta) {
method generate-post(Int:D $id, Post:D $post, $db) {
my $meta = $db.meta;
my $content = $post.render-html;
my $head = generate-head($meta, $post.title, $post.description);
my $body =
body [
site-header $meta;
article :class<post>, [
post-header $post;
post-header $id, $post, $db;
div :class<post-body>, [
$content;
]
@ -46,7 +47,7 @@ method generate-blurb(Int:D $id, $db) {
h2 $post.title;
];
];
post-info $post;
post-info $id, $post, $db;
if $desc ~~ Str:D {
div :class<post-blurb-description>, [
p $post.description;
@ -117,7 +118,7 @@ method generate-tag-blurb($db, $tag, $limit?) {
a :href($link), span [
h3 $post.title;
];
post-info $post;
post-info $id, $post, $db;
if $desc ~~ Str:D {
div :class<tag-blurb-post-description>, [
p $post.description;