2024-09-04 11:28:12 +02:00
|
|
|
<template>
|
2025-01-23 17:39:40 +01:00
|
|
|
<article
|
|
|
|
|
class="project-item | flex | rounded-2xl | px-32 py-32"
|
|
|
|
|
:data-dtl="project.isDTLEnabled ? 'true' : undefined"
|
|
|
|
|
>
|
2025-01-09 14:13:21 +01:00
|
|
|
<hgroup>
|
|
|
|
|
<h3>
|
|
|
|
|
<router-link
|
2025-01-23 17:39:40 +01:00
|
|
|
:to="
|
|
|
|
|
isEmptyBrief(project) ? project.uri + '/client-brief' : project.uri
|
|
|
|
|
"
|
2025-01-09 14:13:21 +01:00
|
|
|
class="link-full"
|
2024-11-21 11:27:14 +01:00
|
|
|
>
|
2025-01-23 17:39:40 +01:00
|
|
|
{{ project.title }}
|
2025-01-09 14:13:21 +01:00
|
|
|
</router-link>
|
|
|
|
|
</h3>
|
|
|
|
|
<p>
|
|
|
|
|
Dernière mise à jour le
|
2025-01-23 17:39:40 +01:00
|
|
|
<time :datetime="project.modified">{{ frenchFormattedModified }}</time>
|
2025-01-09 14:13:21 +01:00
|
|
|
</p>
|
|
|
|
|
</hgroup>
|
|
|
|
|
<img :src="project.logo" alt="Logo" class="project-logo | rounded-sm" />
|
|
|
|
|
<ol
|
|
|
|
|
class="project-steps"
|
|
|
|
|
:data-steps="project.steps.length"
|
|
|
|
|
:style="'--steps:' + project.steps.length"
|
|
|
|
|
>
|
|
|
|
|
<li
|
|
|
|
|
v-for="step in project.steps"
|
|
|
|
|
class="project-step"
|
|
|
|
|
:data-status="setStatus(project.steps, project.currentStep, step)"
|
|
|
|
|
>
|
|
|
|
|
<span class="pill" :data-icon="step.id">
|
|
|
|
|
<span>{{ step.label }}</span>
|
|
|
|
|
</span>
|
|
|
|
|
</li>
|
|
|
|
|
</ol>
|
|
|
|
|
</article>
|
2024-09-04 11:28:12 +02:00
|
|
|
</template>
|
|
|
|
|
|
|
|
|
|
<script setup>
|
2025-09-09 09:37:34 +02:00
|
|
|
import dayjs from 'dayjs';
|
|
|
|
|
import 'dayjs/locale/fr';
|
|
|
|
|
import { useProjectStore } from '../../stores/project';
|
2024-09-04 11:28:12 +02:00
|
|
|
|
2025-09-09 09:37:34 +02:00
|
|
|
dayjs.locale('fr');
|
2024-09-04 11:28:12 +02:00
|
|
|
|
2025-09-09 09:37:34 +02:00
|
|
|
const { project } = defineProps({ project: Object });
|
2024-11-05 14:26:23 +01:00
|
|
|
|
2024-09-04 11:28:12 +02:00
|
|
|
const frenchFormattedModified = dayjs(project.modified).format(
|
2025-09-09 09:37:34 +02:00
|
|
|
'dddd D MMMM YYYY'
|
2024-09-04 11:28:12 +02:00
|
|
|
);
|
2024-11-05 14:26:23 +01:00
|
|
|
|
2024-12-19 19:27:38 +01:00
|
|
|
const { stepsLabels, setStatus, isEmptyBrief } = useProjectStore();
|
2024-09-04 11:28:12 +02:00
|
|
|
</script>
|