Newer
Older
<template>
<div class="orange card">
<div class="content">
<div class="center aligned header">
Derniers commentaires
</div>
<div class="center aligned description">
<div
:class="{ active: loading }"
class="ui inverted dimmer"
>
<div class="ui text loader">
Récupération des commentaires en cours...
</div>
</div>
<div class="ui relaxed list">
<div
v-for="(item, index) in last_comments"
:key="'comment ' + index"
class="item"
>
<div class="content">
<div>
<router-link
:to="{
name: 'details-signalement',
params: {
slug: $route.params.slug,
slug_type_signal: item.related_feature.feature_type_slug,
slug_signal: item.related_feature.feature_id,
}
}"
>
"{{ item.comment }}"
</router-link>
</div>
<div class="description">
}}<span
v-if="user && item.display_author"
>, par {{ item.display_author }}
</span>
</div>
</div>
</div>
</div>
</template>
<script>
import { mapState } from 'vuex';
export default {
name: 'ProjectsLastComments',
props: {
loading: {
type: Boolean,
default: false
}
},
computed: {
...mapState([
'user'
]),
...mapState('projects', [