Skip to content

Commit a5db668

Browse files
fix: Awards adjust to smaller screens, add margin bottom to all pages.
1 parent da74fc4 commit a5db668

9 files changed

Lines changed: 22 additions & 12 deletions

File tree

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
{
22
"name": "mod-garden-website",
33
"type": "module",
4-
"version": "1.0.1",
4+
"version": "1.0.2",
55
"scripts": {
66
"dev": "astro dev --api real",
77
"dev_local": "astro dev --api local",

src/layouts/Layout.astro

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ description = description ? description : "Mod Garden: A longer term mod creatio
2222

2323
/>
2424
<meta name="viewport" content="width=device-width" />
25-
<link rel="icon" type="image/svg+xml" href="/favicon.svg" />
25+
<link rel="icon" type="image/png" href="/favicon.png" />
2626
<meta name="generator" content={Astro.generator} />
2727
<title>{title}</title>
2828
<script is:inline>

src/pages/blog/[post].astro

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ const { Content } = await render(post);
1919

2020
<Layout title={post.data.title} page="blog" description={post.data.description}>
2121
<div class="flex min-h-screen w-full flex-col items-center justify-center">
22-
<div class="mt-2 flex w-full max-w-4xl flex-col space-y-6 px-4">
22+
<div class="mt-2 mb-4 flex w-full max-w-4xl flex-col space-y-6 px-4">
2323
<div
2424
class="w-full rounded-lg border-0 border-b-4 border-leaf-200 bg-white p-6 text-black shadow-md dark:bg-zinc-800 dark:text-white"
2525
>

src/pages/blog/index.astro

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ import Layout from "../../layouts/Layout.astro";
55
const posts = await getCollection('blog');
66
---
77
<Layout title="Mod Garden Blog" page="blog" description="Blog posts from Mod Garden">
8-
<div class="mx-auto mt-3 mb-3 grid w-3/4 grid-flow-row contents-col-2 gap-2">
8+
<div class="mx-auto mt-4 mb-4 grid w-3/4 grid-flow-row contents-col-2 gap-2">
99
{
1010
posts.map((blogPost) => (
1111
<a

src/pages/events/[event].astro

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ const projects = await getEventProjects(eventData.id);
1919
---
2020

2121
<Layout title={eventData?.display_name}>
22-
<div class="mt-5 mb-5 flex items-center justify-center">
22+
<div class="mt-4 mb-4 flex items-center justify-center">
2323
<div class="flex max-w-4xl flex-col space-y-6">
2424
<div class="flex flex-row space-x-4">
2525
<div

src/pages/events/index.astro

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ const events = await getEvents();
66

77
<Layout title="Mod Garden Events" page="events">
88
{events.length == 0 &&
9-
<div class="mx-auto mt-3 w-3/4 rounded-lg bg-white p-6 text-black shadow-md dark:bg-zinc-800 dark:text-white">
9+
<div class="mx-auto mt-4 mb-4 w-3/4 rounded-lg bg-white p-6 text-black shadow-md dark:bg-zinc-800 dark:text-white">
1010
<h1 class="mb-4 border-0 border-b-4 border-leaf-200 text-xl font-bold text-black dark:text-white">
1111
Mod Garden Presents:
1212
</h1>
@@ -20,7 +20,7 @@ const events = await getEvents();
2020
}
2121

2222
<div
23-
class="mx-auto mt-3 mb-3 grid w-3/4 grid-flow-row contents-col-2 gap-2"
23+
class="mx-auto mt-4 mb-4 grid w-3/4 grid-flow-row contents-col-2 gap-2"
2424
>
2525
{
2626
events.map((modGardenEvent) => (

src/pages/index.astro

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ import Layout from "../layouts/Layout.astro";
33
---
44

55
<Layout title="Mod Garden" page="home">
6-
<div class="mt-5 flex items-center justify-center">
6+
<div class="mt-4 mb-4 flex items-center justify-center">
77
<div class="flex max-w-4xl flex-col space-y-6">
88
<div
99
class="rounded-lg bg-white p-6 text-black shadow-md dark:bg-zinc-800 dark:text-white"

src/pages/user/[user].astro

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -86,7 +86,7 @@ let bio =
8686
---
8787

8888
<Layout title={userData?.display_name}>
89-
<div class="mx-auto mt-5 w-4/5">
89+
<div class="mx-auto mt-4 w-4/5">
9090
<div
9191
class="rounded-lg bg-white p-6 text-black shadow-md dark:bg-zinc-800 dark:text-white"
9292
>
@@ -96,7 +96,7 @@ let bio =
9696
style=`background-image: url(${modrinthUserIcon});`
9797
>
9898
</span>
99-
<h1 class="mt-5 text-xl font-bold text-black dark:text-white">
99+
<h1 class="mt-4 text-xl font-bold text-black dark:text-white">
100100
{userData?.display_name}
101101
</h1>
102102
</div>
@@ -107,10 +107,10 @@ let bio =
107107
</div>
108108

109109
<div
110-
class="mx-auto mt-5 min-h-24 w-4/5 rounded-lg border-4 border-gray-100 bg-repeat dark:border-zinc-700"
110+
class="mx-auto mt-4 min-h-24 w-4/5 rounded-lg border-4 border-gray-100 bg-repeat dark:border-zinc-700"
111111
style="background-image: url('/images/soil.png');"
112112
>
113-
<div class="grid grid-cols-10 gap-2 p-4">
113+
<div class="grid awards-col gap-2 p-4">
114114
{awards.map((award) => <AwardPlant award={award} />)}
115115
</div>
116116
</div>

src/styles/global.css

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -66,4 +66,14 @@
6666
@media screen and (max-width: 800px) {
6767
grid-template-columns: repeat(1, minmax(0, 1fr));
6868
}
69+
}
70+
71+
@utility awards-col {
72+
grid-template-columns: repeat(16, minmax(0, 1fr));
73+
@media screen and (max-width: 1400px) {
74+
grid-template-columns: repeat(8, minmax(0, 1fr));
75+
}
76+
@media screen and (max-width: 800px) {
77+
grid-template-columns: repeat(4, minmax(0, 1fr));
78+
}
6979
}

0 commit comments

Comments
 (0)