Add ProjectCard image class parameter

This commit is contained in:
2024-08-17 15:54:59 +02:00
parent b0b6b565e6
commit 9b6917e066
2 changed files with 3 additions and 2 deletions

View File

@ -14,7 +14,7 @@
<p class="w-full text-lg whitespace-pre-wrap mb-2 text-gray-500 dark:text-gray-400"> <p class="w-full text-lg whitespace-pre-wrap mb-2 text-gray-500 dark:text-gray-400">
<slot></slot> <slot></slot>
</p> </p>
<img v-if="props.image" :src="props.image" alt="" class="max-w-full max-h-96 mx-auto"> <img v-if="props.image" :src="props.image" alt="" :class="`max-w-full max-h-96 mx-auto ${image_classes}`">
</div> </div>
</div> </div>
</div> </div>
@ -29,6 +29,7 @@
subtitle: { type: String, required: false }, subtitle: { type: String, required: false },
links: Object as PropType<{ label: string, url: string }[]>, links: Object as PropType<{ label: string, url: string }[]>,
image: String, image: String,
image_classes: { type: String, required: false, default: "" },
wip: { type: Boolean, required: false } wip: { type: Boolean, required: false }
}); });
</script> </script>

View File

@ -1,6 +1,6 @@
<template> <template>
<ProjectCard <ProjectCard
title="WaveMap" :image="image" title="WaveMap" :image="image" image_classes="!max-h-[32rem]"
:links="[ :links="[
{ label: 'Repository', url: 'https://github.com/NotXia/wave-map' }, { label: 'Repository', url: 'https://github.com/NotXia/wave-map' },
]"> ]">