diff --git a/app/stores/projects.ts b/app/stores/projects.ts index b73d35f..89f7c89 100644 --- a/app/stores/projects.ts +++ b/app/stores/projects.ts @@ -79,10 +79,12 @@ export const useProjectsStore = defineStore("projects", { this.projects = []; for (const project of projects.value) { + const parts = project.id.replace(".md", "").split("/"); + const id = parts[parts.length - 1]!; this.projects.push({ description: project.description, - thumbnail: project.thumbnail, - preview: createImage(project.preview), + thumbnail: `/images/projects/thumbnails/${id}.webp`, + preview: createImage(`/images/projects/previews/${id}.webp`), url: project.url, body: simplifyMarkdownAST(project.body), }); diff --git a/content.config.ts b/content.config.ts index 51704f0..43a3716 100644 --- a/content.config.ts +++ b/content.config.ts @@ -9,8 +9,6 @@ export default defineContentConfig({ schema: z.object({ description: z.string(), url: z.url().nullable(), - thumbnail: z.string(), - preview: z.string(), order: z.number(), }), }), diff --git a/content/projects/biobleud.md b/content/projects/biobleud.md index 5d693e4..eaba19e 100644 --- a/content/projects/biobleud.md +++ b/content/projects/biobleud.md @@ -1,7 +1,5 @@ --- description: Biobleud - Automated Excel imports\nfor an ERP system url: null -thumbnail: /images/projects/biobleud.webp -preview: /images/biobleud-game.png order: 100 --- diff --git a/content/projects/lbf-bot.md b/content/projects/lbf-bot.md index ec58029..35f1b0f 100644 --- a/content/projects/lbf-bot.md +++ b/content/projects/lbf-bot.md @@ -1,7 +1,5 @@ --- description: LBF Bot - Custom Discord bot for\na gaming group url: https://github.com/pihkaal/lbf-bot -thumbnail: /images/projects/lbf-bot.webp -preview: /images/lbf-bot-game.webp order: 50 --- diff --git a/content/projects/lilou-cat.md b/content/projects/lilou-cat.md index 8b95e87..baa43a6 100644 --- a/content/projects/lilou-cat.md +++ b/content/projects/lilou-cat.md @@ -1,7 +1,5 @@ --- description: lilou.cat - My cat's website url: https://lilou.cat -thumbnail: /images/projects/lilou-cat.webp -preview: /images/lilou-cat-game.webp order: 40 --- diff --git a/content/projects/pihkaal-me.md b/content/projects/pihkaal-me.md index 6a45a24..20fb4cb 100644 --- a/content/projects/pihkaal-me.md +++ b/content/projects/pihkaal-me.md @@ -1,8 +1,6 @@ --- description: pihkaal.me - my personal website url: https://pihkaal.me -thumbnail: /images/projects/pihkaal-me.webp -preview: /images/pihkaal-me-game.webp order: 10 --- diff --git a/content/projects/raylib-speedruns.md b/content/projects/raylib-speedruns.md index 7a96224..6c440ee 100644 --- a/content/projects/raylib-speedruns.md +++ b/content/projects/raylib-speedruns.md @@ -1,8 +1,6 @@ --- description: Raylib Speedruns - Collection of simple\nRaylib setups in multiple languages url: https://github.com/pihkaal/raylib-speedruns -thumbnail: /images/projects/raylib-speedruns.webp -preview: /images/raylib-speedruns-game.webp order: 60 --- diff --git a/content/projects/s3pweb.md b/content/projects/s3pweb.md index 1e51cfd..efb9574 100644 --- a/content/projects/s3pweb.md +++ b/content/projects/s3pweb.md @@ -1,7 +1,5 @@ --- description: S3PWeb - Intership and\napprenticeship url: null -thumbnail: /images/projects/s3pweb.webp -preview: /images/s3pweb-game.webp order: 80 --- diff --git a/content/projects/simple-qr.md b/content/projects/simple-qr.md index b3f261b..25a0418 100644 --- a/content/projects/simple-qr.md +++ b/content/projects/simple-qr.md @@ -1,7 +1,5 @@ --- description: Simple QR - Simple QR code generator\nwith straightforward API url: https://simple-qr.com -thumbnail: /images/projects/simple-qr.webp -preview: /images/simple-qr-game.webp order: 30 --- diff --git a/content/projects/tlock.md b/content/projects/tlock.md index 1702568..3e1b95e 100644 --- a/content/projects/tlock.md +++ b/content/projects/tlock.md @@ -1,7 +1,5 @@ --- description: tlock - fully customizable and cross-\nplatform terminal based clock url: https://github.com/pihkaal/tlock -thumbnail: /images/projects/tlock.webp -preview: /images/tlock-game.webp order: 20 --- diff --git a/public/images/biobleud-game.png b/public/images/biobleud-game.png deleted file mode 100644 index ba43472..0000000 Binary files a/public/images/biobleud-game.png and /dev/null differ diff --git a/public/images/projects/previews/biobleud.webp b/public/images/projects/previews/biobleud.webp new file mode 100644 index 0000000..b386f88 Binary files /dev/null and b/public/images/projects/previews/biobleud.webp differ diff --git a/public/images/lbf-bot-game.webp b/public/images/projects/previews/lbf-bot.webp similarity index 100% rename from public/images/lbf-bot-game.webp rename to public/images/projects/previews/lbf-bot.webp diff --git a/public/images/lilou-cat-game.webp b/public/images/projects/previews/lilou-cat.webp similarity index 100% rename from public/images/lilou-cat-game.webp rename to public/images/projects/previews/lilou-cat.webp diff --git a/public/images/pihkaal-me-game.webp b/public/images/projects/previews/pihkaal-me.webp similarity index 100% rename from public/images/pihkaal-me-game.webp rename to public/images/projects/previews/pihkaal-me.webp diff --git a/public/images/raylib-speedruns-game.webp b/public/images/projects/previews/raylib-speedruns.webp similarity index 100% rename from public/images/raylib-speedruns-game.webp rename to public/images/projects/previews/raylib-speedruns.webp diff --git a/public/images/s3pweb-game.webp b/public/images/projects/previews/s3pweb.webp similarity index 100% rename from public/images/s3pweb-game.webp rename to public/images/projects/previews/s3pweb.webp diff --git a/public/images/simple-qr-game.webp b/public/images/projects/previews/simple-qr.webp similarity index 100% rename from public/images/simple-qr-game.webp rename to public/images/projects/previews/simple-qr.webp diff --git a/public/images/tlock-game.webp b/public/images/projects/previews/tlock.webp similarity index 100% rename from public/images/tlock-game.webp rename to public/images/projects/previews/tlock.webp diff --git a/public/images/projects/biobleud.webp b/public/images/projects/thumbnails/biobleud.webp similarity index 100% rename from public/images/projects/biobleud.webp rename to public/images/projects/thumbnails/biobleud.webp diff --git a/public/images/projects/lbf-bot.webp b/public/images/projects/thumbnails/lbf-bot.webp similarity index 100% rename from public/images/projects/lbf-bot.webp rename to public/images/projects/thumbnails/lbf-bot.webp diff --git a/public/images/projects/lilou-cat.webp b/public/images/projects/thumbnails/lilou-cat.webp similarity index 100% rename from public/images/projects/lilou-cat.webp rename to public/images/projects/thumbnails/lilou-cat.webp diff --git a/public/images/projects/pihkaal-me.webp b/public/images/projects/thumbnails/pihkaal-me.webp similarity index 100% rename from public/images/projects/pihkaal-me.webp rename to public/images/projects/thumbnails/pihkaal-me.webp diff --git a/public/images/projects/raylib-speedruns.webp b/public/images/projects/thumbnails/raylib-speedruns.webp similarity index 100% rename from public/images/projects/raylib-speedruns.webp rename to public/images/projects/thumbnails/raylib-speedruns.webp diff --git a/public/images/projects/s3pweb.webp b/public/images/projects/thumbnails/s3pweb.webp similarity index 100% rename from public/images/projects/s3pweb.webp rename to public/images/projects/thumbnails/s3pweb.webp diff --git a/public/images/projects/simple-qr.webp b/public/images/projects/thumbnails/simple-qr.webp similarity index 100% rename from public/images/projects/simple-qr.webp rename to public/images/projects/thumbnails/simple-qr.webp diff --git a/public/images/projects/tlock.webp b/public/images/projects/thumbnails/tlock.webp similarity index 100% rename from public/images/projects/tlock.webp rename to public/images/projects/thumbnails/tlock.webp