From fc1da5499c84ef9206b35b45e5acffdf8f820fcb Mon Sep 17 00:00:00 2001 From: mudkipdev Date: Fri, 24 May 2024 14:27:32 -0600 Subject: [PATCH] card stuff --- src/components/{ => cards}/Card.astro | 4 ++-- src/components/{ => cards}/Cards.astro | 0 src/components/{ => cards}/Post.astro | 2 +- src/pages/blog.astro | 4 ++-- src/pages/projects.astro | 8 ++++---- 5 files changed, 9 insertions(+), 9 deletions(-) rename src/components/{ => cards}/Card.astro (89%) rename src/components/{ => cards}/Cards.astro (100%) rename src/components/{ => cards}/Post.astro (91%) diff --git a/src/components/Card.astro b/src/components/cards/Card.astro similarity index 89% rename from src/components/Card.astro rename to src/components/cards/Card.astro index 89ccaa4..8f579f1 100644 --- a/src/components/Card.astro +++ b/src/components/cards/Card.astro @@ -5,15 +5,15 @@ interface Props { url?: string; } -const { title, description, url } = Astro.props +const { title, description, url } = Astro.props; ---
+

{ url == null ? title : {title} }

-

{description}

diff --git a/src/components/Cards.astro b/src/components/cards/Cards.astro similarity index 100% rename from src/components/Cards.astro rename to src/components/cards/Cards.astro diff --git a/src/components/Post.astro b/src/components/cards/Post.astro similarity index 91% rename from src/components/Post.astro rename to src/components/cards/Post.astro index 62cbbda..292afaa 100644 --- a/src/components/Post.astro +++ b/src/components/cards/Post.astro @@ -1,5 +1,5 @@ --- -import Card from "@components/Card.astro"; +import Card from "@components/cards/Card.astro"; import Date from "@components/Date.astro"; import { remark } from 'remark' diff --git a/src/pages/blog.astro b/src/pages/blog.astro index df6a8f4..e85f7d0 100644 --- a/src/pages/blog.astro +++ b/src/pages/blog.astro @@ -1,7 +1,7 @@ --- import Page from "@layouts/Page.astro"; -import Post from "@components/Post.astro"; -import Cards from "@components/Cards.astro"; +import Post from "@components/cards/Post.astro"; +import Cards from "@components/cards/Cards.astro"; import { getCollection } from "astro:content"; const posts = await getCollection("blog"); diff --git a/src/pages/projects.astro b/src/pages/projects.astro index e475747..9fab1a8 100644 --- a/src/pages/projects.astro +++ b/src/pages/projects.astro @@ -1,20 +1,20 @@ --- import Page from "@layouts/Page.astro"; -import Card from "@components/Card.astro"; -import Cards from "@components/Cards.astro"; +import Card from "@components/cards/Card.astro"; +import Cards from "@components/cards/Cards.astro"; --- \ No newline at end of file