Files
site-profile/src/components/sections/RecentPostsSection.astro
Alex Lebens b3c377f62d
All checks were successful
renovate / renovate (push) Successful in 1m32s
test-build / build (push) Successful in 3m22s
test-build / guarddog (push) Successful in 4m3s
feat: adjustment pass on spacing between sections
2026-02-19 18:14:44 -06:00

30 lines
772 B
Plaintext

---
import type { Post } from '@lib/directusTypes';
import BlogCard from '@components/cards/BlogCard.astro';
interface Props {
posts: Post[];
title: string;
subTitle?: string;
}
const { posts, title, subTitle } = Astro.props;
---
<section class="max-w-340 2xl:max-w-full px-4 sm:px-6 lg:px-8 py-10 lg:py-14 mx-auto mb-2 md:mb-8">
<div class="text-center max-w-2xl mx-auto mb-10 lg:mb-14">
<h1 class="smooth-reveal card-text-header block">
{title}
</h1>
<div class="smooth-reveal mx-auto mt-5 max-w-3xl text-center">
<span class="card-text-header-description">
{subTitle}
</span>
</div>
</div>
<div class="grid gap-6 sm:grid-cols-2 lg:grid-cols-3">
{posts.map((b) => <BlogCard post={b} />)}
</div>
</section>