Skip to content

Commit 2ba69b0

Browse files
author
Rodgers Gitau
committed
feat: blog container queries
1 parent 01f1ff1 commit 2ba69b0

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

src/layouts/BlogPost.astro

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -34,8 +34,8 @@ const { title, description, pubDate, updatedDate, heroImage } = Astro.props;
3434

3535
<Layout>
3636
<article>
37-
<div class="container mx-auto">
38-
<div class="relative w-full">
37+
<div class="container mx-auto @container flex flex-col-reverse w-1/4">
38+
<div class="relative w-full @md:w-1/2 @3xl:w-1/4">
3939
{
4040
heroImage && (
4141
<img

src/pages/blog/index.astro

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ const posts = (await getCollection("blog")).sort(
1111

1212
<Layout>
1313
<section class="mx-auto py-10">
14-
<ul class="grid grid-cols-1 lg:grid-cols-2 gap-10">
14+
<ul class="flex flex-col gap-8">
1515
{
1616
posts.map((post) => (
1717
<li class="w-full mx-auto">

0 commit comments

Comments
 (0)