2024-12-20 07:19:46 +01:00
|
|
|
<template>
|
|
|
|
|
<article class="card">
|
|
|
|
|
<hgroup class="order-last">
|
|
|
|
|
<h3 class="card__title | font-serif | text-lg">
|
2024-12-20 10:40:44 +01:00
|
|
|
<router-link :to="uri" class="link-full">{{ step.label }}</router-link>
|
2024-12-20 07:19:46 +01:00
|
|
|
</h3>
|
|
|
|
|
</hgroup>
|
|
|
|
|
<DateTime :date="step.modified" />
|
|
|
|
|
<figure
|
|
|
|
|
class="card__images"
|
|
|
|
|
:data-count="images.length"
|
|
|
|
|
:data-plus="images.length > 3 ? images.length - 3 : undefined"
|
|
|
|
|
>
|
|
|
|
|
<template v-for="image in images.slice(0, 3)" :key="image.uuid">
|
2024-12-20 10:55:33 +01:00
|
|
|
<img v-if="image.url" :src="image.url" :alt="image.alt" />
|
|
|
|
|
<div v-else class="card__images" data-icon="document"></div>
|
2024-12-20 07:19:46 +01:00
|
|
|
</template>
|
|
|
|
|
</figure>
|
|
|
|
|
<!-- <footer
|
|
|
|
|
v-if="images[0]?.comments?.length > 0"
|
|
|
|
|
class="order-last | text-sm text-primary font-medium"
|
|
|
|
|
>
|
|
|
|
|
{{ images[0].comments.length }} commentaire{{
|
|
|
|
|
images[0].comments.length > 1 ? "s" : ""
|
|
|
|
|
}}
|
|
|
|
|
</footer> -->
|
|
|
|
|
</article>
|
|
|
|
|
</template>
|
|
|
|
|
<script setup>
|
|
|
|
|
import DateTime from "./DateTime.vue";
|
|
|
|
|
import { usePageStore } from "../../../stores/page";
|
|
|
|
|
|
2024-12-20 10:40:44 +01:00
|
|
|
const { images, step, uri } = defineProps({
|
|
|
|
|
images: Array,
|
|
|
|
|
step: Object,
|
|
|
|
|
uri: String,
|
|
|
|
|
});
|
2024-12-20 07:19:46 +01:00
|
|
|
const { page } = usePageStore();
|
|
|
|
|
</script>
|