mirror of
https://github.com/reonokiy/blog.nokiy.net.git
synced 2025-06-17 20:01:33 +02:00
feat: add post description on desktop home page
This commit is contained in:
parent
5f3d9bc3c2
commit
f9c48b2c6f
9 changed files with 27 additions and 22 deletions
|
@ -40,7 +40,7 @@ const { Content } = aboutEntry ? await aboutEntry.render() : { Content: null }
|
|||
|
||||
<Layout>
|
||||
<div class="uno-decorative-line"></div>
|
||||
<div class="heti mt-4.375">
|
||||
<div class="heti">
|
||||
{Content && <Content />}
|
||||
</div>
|
||||
</Layout>
|
||||
|
|
|
@ -40,14 +40,14 @@ const postsByYear = await getPostsByYear(lang)
|
|||
<main>
|
||||
<!-- Pinned Posts -->
|
||||
{pinnedPosts.length > 0 && (
|
||||
<section class="mb-7.5">
|
||||
<section class="mb-7.5 lg:mb-9.5">
|
||||
<div class="uno-decorative-line"></div>
|
||||
<PostList posts={pinnedPosts} lang={lang} />
|
||||
</section>
|
||||
)}
|
||||
<!-- Regular Posts -->
|
||||
{[...postsByYear.entries()].map(([_year, posts]) => (
|
||||
<section class="mb-7.5">
|
||||
<section class="mb-7.5 lg:mb-9.5">
|
||||
<div class="uno-decorative-line"></div>
|
||||
<PostList posts={posts} lang={lang} />
|
||||
</section>
|
||||
|
|
|
@ -115,6 +115,8 @@ function getTagUrl(tagName: string): string {
|
|||
postSlug={post.slug}
|
||||
supportedLangs={supportedLangs}
|
||||
>
|
||||
|
||||
<!-- Title -->
|
||||
<article class="heti mb-12.6">
|
||||
<h1 class="post-title">
|
||||
<span
|
||||
|
@ -125,12 +127,12 @@ function getTagUrl(tagName: string): string {
|
|||
</span>
|
||||
</h1>
|
||||
|
||||
<!-- Date -->
|
||||
<div
|
||||
class="mb-17 block c-primary font-time"
|
||||
transition:name={`time-${post.data.abbrlink || post.slug}-${lang}`}
|
||||
data-disable-transition-on-theme
|
||||
>
|
||||
<!-- published and updated time -->
|
||||
<PostDate
|
||||
date={post.data.published}
|
||||
updatedDate={post.data.updated}
|
||||
|
|
|
@ -77,7 +77,7 @@ function getTagUrl(tagName: string): string {
|
|||
))}
|
||||
</div>
|
||||
|
||||
<div class="mt-10.625">
|
||||
<div class="mt-10.5">
|
||||
<PostList posts={posts} lang={lang} />
|
||||
</div>
|
||||
</Layout>
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue