Use custom slug for work links when available

This commit is contained in:
Michael Winter 2026-04-26 10:49:19 +02:00
parent d34ea209f7
commit 15012d8beb
2 changed files with 3 additions and 3 deletions

View file

@ -10,7 +10,7 @@
<div class="flex items-start gap-2">
<NuxtLink
v-if="hasItems(work)"
:to="'/works/' + slugify(work.title)"
:to="'/works/' + (work.slug || slugify(work.title))"
class="italic hover:underline"
>
<span v-html="work.title"></span>

View file

@ -8,7 +8,7 @@
<div>
<NuxtLink
v-if="hasItems(work)"
:to="'/works/' + slugify(work.title)"
:to="'/works/' + (work.slug || slugify(work.title))"
class="text-base italic hover:underline"
>
<span v-html="work.title"></span>
@ -43,7 +43,7 @@
<NuxtLink
v-for="work in worksWithImages"
:key="work.title"
:to="'/works/' + slugify(work.title)"
:to="'/works/' + (work.slug || slugify(work.title))"
class="block group relative overflow-hidden"
>
<nuxt-img