feat: move all posts to bottom of recent section
This commit is contained in:
@@ -1,20 +0,0 @@
|
||||
---
|
||||
import { readSingleton } from '@directus/sdk';
|
||||
|
||||
import LargeLinkCard from '@components/cards/LargeLinkCard.astro';
|
||||
import directus from '@lib/directus';
|
||||
|
||||
const global = await directus.request(readSingleton('site_global'));
|
||||
---
|
||||
|
||||
<section class:list={['mx-auto px-4 pb-10 sm:px-6 lg:px-8 lg:pb-14 2xl:max-w-full', Astro.props.className]}>
|
||||
<div class="grid grid-cols-1">
|
||||
<LargeLinkCard
|
||||
title="All Posts"
|
||||
subTitle="Catch up on everything I've written so far here"
|
||||
url="/all"
|
||||
logoLight={global.all_logoLight}
|
||||
logoDark={global.all_logoDark}
|
||||
/>
|
||||
</div>
|
||||
</section>
|
||||
@@ -1,7 +1,11 @@
|
||||
---
|
||||
import { readSingleton } from '@directus/sdk';
|
||||
|
||||
import type { Post } from '@lib/directusTypes';
|
||||
|
||||
import BlogCard from '@components/cards/BlogCard.astro';
|
||||
import LargeLinkCard from '@components/cards/LargeLinkCard.astro';
|
||||
import directus from '@lib/directus';
|
||||
|
||||
interface Props {
|
||||
posts: Post[];
|
||||
@@ -9,6 +13,8 @@ interface Props {
|
||||
subTitle?: string;
|
||||
}
|
||||
|
||||
const global = await directus.request(readSingleton('site_global'));
|
||||
|
||||
const { posts, title, subTitle } = Astro.props;
|
||||
---
|
||||
|
||||
@@ -27,5 +33,14 @@ const { posts, title, subTitle } = Astro.props;
|
||||
{posts.map((b) =>
|
||||
<BlogCard post={b} />
|
||||
)}
|
||||
<div class="col-span-full">
|
||||
<LargeLinkCard
|
||||
title="All Posts"
|
||||
subTitle="Catch up on everything I've written"
|
||||
url="/all"
|
||||
logoLight={global.all_logoLight}
|
||||
logoDark={global.all_logoDark}
|
||||
/>
|
||||
</div>
|
||||
</div>
|
||||
</section>
|
||||
|
||||
@@ -6,7 +6,6 @@ import type { Post } from '@lib/directusTypes';
|
||||
import HeroSection from '@components/sections/HeroSection.astro';
|
||||
import SelectedPostsSection from '@components/sections/SelectedPostsSection.astro';
|
||||
import RecentPostsSection from '@components/sections/RecentPostsSection.astro';
|
||||
import AllPostsSection from '@components/sections/AllPostsSection.astro';
|
||||
import BaseLayout from '@layouts/BaseLayout.astro';
|
||||
import directus from '@lib/directus';
|
||||
|
||||
@@ -57,8 +56,6 @@ const recentPosts: Post[] = posts.filter(
|
||||
title="Recent Posts"
|
||||
/>
|
||||
|
||||
<AllPostsSection />
|
||||
|
||||
</BaseLayout>
|
||||
|
||||
<script>
|
||||
|
||||
@@ -7,7 +7,6 @@ import HeroSection from '@components/sections/HeroSection.astro';
|
||||
import FeatureSection from '@components/sections/FeatureSection.astro';
|
||||
import WeatherSection from '@components/sections/WeatherSection.astro';
|
||||
import RecentPostsSection from '@components/sections/RecentPostsSection.astro';
|
||||
import AllPostsSection from '@components/sections/AllPostsSection.astro';
|
||||
import GiteaSection from '@components/sections/GiteaSection.astro';
|
||||
import BaseLayout from '@layouts/BaseLayout.astro';
|
||||
import directus from '@lib/directus';
|
||||
@@ -70,8 +69,6 @@ const recentPosts = posts
|
||||
subTitle="Checkout my most recent thoughts here"
|
||||
/>
|
||||
|
||||
<AllPostsSection />
|
||||
|
||||
<GiteaSection
|
||||
title="Follow me on Gitea"
|
||||
subTitle="I love open source and have my code availabile on my Gitea server."
|
||||
|
||||
Reference in New Issue
Block a user