Fix bugs and errors
This commit is contained in:
parent
2336656ab8
commit
55a497fe02
3 changed files with 3 additions and 3 deletions
|
@ -49,7 +49,7 @@ for file in restia.utils.files(params.input, "^./posts/.*%.md$") do
|
|||
post.head.tags = string.split(post.head.tags, "[%a-]+")
|
||||
end
|
||||
|
||||
for key, tag in ipairs(post.head.tags) do
|
||||
for key, tag in ipairs(post.head.tags or {}) do
|
||||
post.head.tags[key] = string.lower(tag)
|
||||
end
|
||||
|
||||
|
|
|
@ -23,7 +23,7 @@ slots.head
|
|||
slots.head script type: 'module', src: "/javascript/LocalDate.js"
|
||||
slots.head script type: 'module', src: "/javascript/BlogPost.js"
|
||||
|
||||
return div
|
||||
return main
|
||||
class: "content-width"
|
||||
* h1 "Blog Posts"
|
||||
* [blogPost post p for p in *posts]
|
||||
|
|
|
@ -29,7 +29,7 @@ positions = (input, character) ->
|
|||
|
||||
breadcrumb = (href) -> li a :href, href\match('[^/]+$'), tabindex: 0
|
||||
|
||||
if src = post.head.cover_image
|
||||
if src := post.head.cover_image
|
||||
slots.top pageHero cover: 60
|
||||
* img :src, style: 'opacity: .4'
|
||||
* h1(post.head.title, style: "view-transition-name: #{post.head.slug}")
|
||||
|
|
Loading…
Reference in a new issue