Fix image path

This commit is contained in:
2025-09-07 03:56:53 +02:00
parent 31508e74da
commit 04bdcfca88
2 changed files with 7 additions and 2 deletions
+6 -1
View File
@@ -12,7 +12,12 @@ const details = computed(() => (props.car ? trams.find((t) => t.id === props.car
<template>
<div class="grid grid-cols-2 gap-2">
<p>Lackierung</p>
<img v-if="details?.img" class="h-[30px]" :src="`/${details?.img}`" :alt="car?.type" />
<img
v-if="details?.img"
class="h-[30px]"
:src="`${import.meta.env.BASE || '/'}${details?.img}`"
:alt="car?.type"
/>
<span v-else class="h-[30px]"></span>
<p>Fahrzeug-Nr.</p>
<p>{{ car?.id }}</p>