added new GalleryRow for main page links; added Gitea to main page links
This commit is contained in:
94
src/lib/lists/gallery-row.svelte
Normal file
94
src/lib/lists/gallery-row.svelte
Normal file
@@ -0,0 +1,94 @@
|
||||
<script lang="ts">
|
||||
export interface GalleryRowEntry {
|
||||
title: string;
|
||||
description: string;
|
||||
img: string;
|
||||
altText: string;
|
||||
link: string;
|
||||
}
|
||||
|
||||
let {
|
||||
entries,
|
||||
}: {
|
||||
entries: GalleryRowEntry[];
|
||||
} = $props();
|
||||
</script>
|
||||
|
||||
<div class="row-container">
|
||||
{#each entries as entry}
|
||||
<a class="row-entry" href="{entry.link}">
|
||||
<div class="row-img-container">
|
||||
<img class="row-img" src="{entry.img}" alt="{entry.altText}">
|
||||
</div>
|
||||
<div class="row-text-container">
|
||||
<p class="row-title">> {entry.title}</p>
|
||||
<p class="row-description">{@html entry.description}</p>
|
||||
</div>
|
||||
</a>
|
||||
{/each}
|
||||
</div>
|
||||
|
||||
<style>
|
||||
.row-container {
|
||||
display: flex;
|
||||
flex-direction: row;
|
||||
/* margin-bottom: 8px;
|
||||
gap: 8px; */
|
||||
}
|
||||
|
||||
.row-entry {
|
||||
flex: 1 1 0px;
|
||||
box-sizing: border-box;
|
||||
margin: 0;
|
||||
padding: 8px;
|
||||
text-decoration: none;
|
||||
transition: background-color 0.1s ease-out, outline-color 0.1s ease-out;
|
||||
border: 2px dashed transparent;
|
||||
}
|
||||
|
||||
.row-entry:hover {
|
||||
background-color: var(--color-background-highlight);
|
||||
border-color: var(--color-highlight);
|
||||
}
|
||||
|
||||
.row-entry:hover .row-img {
|
||||
scale: 1.06;
|
||||
}
|
||||
|
||||
.row-img-container {
|
||||
width: 100%;
|
||||
height: 160px;
|
||||
overflow: hidden;
|
||||
display: flex;
|
||||
justify-content: center;
|
||||
}
|
||||
|
||||
.row-img {
|
||||
width: 100%;
|
||||
object-fit: cover;
|
||||
transition: scale 0.1s ease-out;
|
||||
}
|
||||
|
||||
.row-text-container {
|
||||
margin-top: 8px;
|
||||
}
|
||||
|
||||
.row-title {
|
||||
font-family: var(--font-mono);
|
||||
font-weight: 700;
|
||||
color: var(--color-highlight);
|
||||
margin: 0;
|
||||
}
|
||||
|
||||
.row-description {
|
||||
font-size: 1.0rem;
|
||||
line-height: 1.3rem;
|
||||
margin: 0;
|
||||
}
|
||||
|
||||
@media screen and (max-width: 600px) {
|
||||
.row-container {
|
||||
flex-direction: column;
|
||||
}
|
||||
}
|
||||
</style>
|
||||
@@ -2,6 +2,7 @@
|
||||
import Content from "$lib/viewport/content.svelte";
|
||||
import GamedevWebring from "$lib/webrings/gamedev.svelte";
|
||||
import Gallery, { type GalleryEntry } from "$lib/lists/gallery.svelte";
|
||||
import GalleryRow, { type GalleryRowEntry } from "$lib/lists/gallery-row.svelte";
|
||||
|
||||
import { posts as devlogPosts } from "./projects/projectn5/devlog/posts";
|
||||
import { posts as blogPosts } from "./blog/posts";
|
||||
@@ -13,35 +14,45 @@
|
||||
|
||||
let changelogEntriesTrimmed = changelogEntries.slice(0, 4);
|
||||
|
||||
const galleryEntries: GalleryEntry[] = [
|
||||
const galleryTopRow: GalleryRowEntry[] = [
|
||||
{
|
||||
title: "Project N5 – devlog",
|
||||
subtitle: `my active Godot game project about finding yourself in an unfamiliar future. <i>latest update: ${latestDevlogDate}</i>`,
|
||||
description: `My active Godot game project about finding yourself in an unfamiliar future. <i>latest update: ${latestDevlogDate}</i>`,
|
||||
img: "projects/projectn5/devlog/2025/0523/birds_eye.webp",
|
||||
imgAlt: "Project N5 screenshot of Laura looking down at two cuboids",
|
||||
altText: "Project N5 screenshot of Laura looking down at two cuboids.",
|
||||
link: "projects/projectn5",
|
||||
},
|
||||
{
|
||||
title: "Projects",
|
||||
subtitle: "an overview of what I do and have done",
|
||||
img: "projects/project-mix.webp",
|
||||
imgAlt: "A collage of multiple projects: the Unity default third-person character and CJ from GTA San Andreas in the top left; purple protagonist from Project N5 holding a massive rocket launcher in the top right; two wizards in the bottom left; a breadboard with a microcontroller and input components in the bottom right",
|
||||
description: "An overview of what I do and have done",
|
||||
img: "main/3ds.webp",
|
||||
altText: "An upside-down New 3DS XL lying open on a desk. A small USB-C breakout board is attached to the 3DS, and a USB-C cable is plugged in. The 3DS is glowing to indicate that it is charging.",
|
||||
link: "projects",
|
||||
},
|
||||
];
|
||||
|
||||
const galleryBottomRow: GalleryRowEntry[] = [
|
||||
{
|
||||
title: "Blog",
|
||||
subtitle: `A place where I write about random things. <i>latest post: ${latestBlogDate}</i>`,
|
||||
description: `A place where I write about random things. <i>latest post: ${latestBlogDate}</i>`,
|
||||
img: "blog/robert.webp",
|
||||
imgAlt: "View at a tram bridge rising and then curving to the left.",
|
||||
altText: "View at a tram bridge rising and then curving to the left.",
|
||||
link: "blog",
|
||||
},
|
||||
{
|
||||
title: "Files",
|
||||
subtitle: "find things I've put for download on my copyparty instance",
|
||||
img: "common/hypertext.webp",
|
||||
imgAlt: "Screenshot of Hypertext Unity level. Crates are strewn across the floor, Waluigi is flying in front of the camera, and text such as 'COME AND TRY OUR ALL-NEW BLENDER' and 'omg! it's the brandenburg er tor!' is displayed",
|
||||
description: "Find things I've put for download on my Copyparty instance",
|
||||
img: "main/hypertext.webp",
|
||||
altText: "Screenshot of Hypertext Unity level. Crates are strewn across the floor, Waluigi is flying in front of the camera, and text such as 'COME AND TRY OUR ALL-NEW BLENDER' and 'omg! it's the brandenburg er tor!' is displayed.",
|
||||
link: "//files.denizk0461.dev/",
|
||||
},
|
||||
{
|
||||
title: "Gitea",
|
||||
description: "I now also self-host a Gitea instance where I am likely migrating all my projects to",
|
||||
img: "main/magic.webp",
|
||||
altText: "A 'magic' command written in Java. The command shuts down the computer when ran.",
|
||||
link: "//code.denizk0461.dev/",
|
||||
},
|
||||
];
|
||||
</script>
|
||||
|
||||
@@ -73,7 +84,8 @@
|
||||
<GamedevWebring />
|
||||
</div>
|
||||
|
||||
<Gallery entries={galleryEntries} />
|
||||
<GalleryRow entries={galleryTopRow} />
|
||||
<GalleryRow entries={galleryBottomRow} />
|
||||
</Content>
|
||||
|
||||
<style>
|
||||
|
||||
BIN
static/main/3ds.webp
Normal file
BIN
static/main/3ds.webp
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 116 KiB |
|
Before Width: | Height: | Size: 60 KiB After Width: | Height: | Size: 60 KiB |
BIN
static/main/magic.webp
Normal file
BIN
static/main/magic.webp
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 119 KiB |
Binary file not shown.
|
Before Width: | Height: | Size: 73 KiB |
Reference in New Issue
Block a user