Added slim variant for the profilecardcomponent

This commit is contained in:
joschuatonn
2024-05-30 09:19:39 +02:00
parent b32599e6af
commit 6e2525da87

View File

@@ -1,23 +1,24 @@
<script setup lang="ts">
import {message, ptpTestUser} from 'src/models';
const props = defineProps({
user: Object,
selected: Boolean,
slim: Boolean,
})
</script>
<template>
<div class="profileCard" :class="selected ? 'selected' : ''">
<div class="profilePicture" :style="{'background-image' : 'url('+props.user!.profilePictureUrl+')' }"></div>
<div class="profilePicture" :style="{'background-image' : 'url('+props.user!.profilepicture+')' }"></div>
<div style="margin-left:10px;">
<p style="margin-bottom: 0;line-height: 25px;vertical-align: middle;height: 25px;display: table-cell;">
<span style="font-weight: bold;font-size: 1.2rem;">{{props.user!.firstName}} {{ props.user!.lastName }}</span>
@{{props.user!.username}}
<span v-if="!props.slim">@{{props.user!.username}}</span>
</p>
<p style="margin: 0;">{{ props.user!.status }}</p>
<p v-if="!props.slim" style="margin: 0;">{{ props.user!.status }}</p>
<p v-else style="margin: 0;">Hier steht die letzte Nachricht</p>
</div>
</div>
</template>