From 08c1ed2895e0eccad46d64ec96a39460ba82816d Mon Sep 17 00:00:00 2001 From: "aitor c. urrutia aranburu" Date: Fri, 6 Nov 2026 12:44:00 +0100 Subject: [PATCH] feat: hasierako post-ek zabalera osoa hartzen dute --- src/components/Container.astro | 16 ++++++ src/components/HomePosts.astro | 2 +- src/components/PostGrid.astro | 2 +- src/layouts/BlogPost.astro | 89 +++++++++++++++++----------------- src/pages/404.astro | 23 +++++---- src/pages/index.astro | 37 ++++++++------ src/pages/post/index.astro | 23 +++++---- src/pages/tag/[tag].astro | 80 +++++++++++++++--------------- src/style/global.css | 1 - 9 files changed, 153 insertions(+), 120 deletions(-) create mode 100644 src/components/Container.astro diff --git a/src/components/Container.astro b/src/components/Container.astro new file mode 100644 index 0000000..aa748a3 --- /dev/null +++ b/src/components/Container.astro @@ -0,0 +1,16 @@ +
+
+ +
+
+ + diff --git a/src/components/HomePosts.astro b/src/components/HomePosts.astro index 859d8c7..3e5b829 100644 --- a/src/components/HomePosts.astro +++ b/src/components/HomePosts.astro @@ -17,7 +17,7 @@ let posts = allPosts new Date(b.data.updated || b.data.added).valueOf() - new Date(a.data.updated || a.data.added).valueOf(), ) - .slice(0, 6); + .slice(0, 8); --- diff --git a/src/components/PostGrid.astro b/src/components/PostGrid.astro index 845f00f..ebcb12c 100644 --- a/src/components/PostGrid.astro +++ b/src/components/PostGrid.astro @@ -47,7 +47,7 @@ function getTiltDegrees() { gap: 1em; @media (min-width: 1024px) { - grid-template-columns: repeat(2, 1fr); + grid-template-columns: repeat(4, 1fr); } } diff --git a/src/layouts/BlogPost.astro b/src/layouts/BlogPost.astro index 0c3ade2..0751099 100644 --- a/src/layouts/BlogPost.astro +++ b/src/layouts/BlogPost.astro @@ -4,62 +4,63 @@ import Header from "../components/Header.astro"; import Footer from "../components/Footer.astro"; import ColorScript from "../components/ColorScript.astro"; import Tags from "../components/Tags.astro"; +import Container from "../components/Container.astro"; let { - content: { title, description, added, updated, tags, heroImage }, + content: { title, description, added, updated, tags, heroImage }, } = Astro.props; -added = new Date(added).toLocaleDateString( - "eu", - { - year: "numeric", - month: "short", - day: "numeric", - } -); +added = new Date(added).toLocaleDateString("eu", { + year: "numeric", + month: "short", + day: "numeric", +}); if (updated) { - updated = new Date(updated).toLocaleDateString( - "eu", - { - year: "numeric", - month: "short", - day: "numeric", - } - ); + updated = new Date(updated).toLocaleDateString("eu", { + year: "numeric", + month: "short", + day: "numeric", + }); } --- - + - -
-
-
- {heroImage && } -

{title}

- {updated ? - - : - - } - -
-
- -
-
-
-