<template>
|
<!-- <MessageTimestamp
|
:currTime="prevTime === 0 ? 0 : dayjs(prevTime).toDate().getTime()"
|
:prevTime="dayjs(creationTime).toDate().getTime()"
|
></MessageTimestamp> -->
|
<div class="bl-message-timestamp">
|
{{ dayjs(creationTime).format('YYYY-MM-DD') }}
|
</div>
|
<Card class="system-message-card-wrapper-v2">
|
{{ messageContent }}
|
<!-- <div class="system-message-card-inner">
|
<Avatar :size="30" :src="IconSystemAvatar" class="system-message-card-avatar" />
|
<div class="system-message-card-content">
|
<div class="system-message-card-content-top">
|
<div class="system-message-card-title">系统消息</div>
|
<div class="system-message-card-time">{{ dayjs(creationTime).format('YYYY-MM-DD') }}</div>
|
</div>
|
<div class="system-message-card-content-bottom">
|
{{ messageContent }}
|
</div>
|
</div>
|
</div> -->
|
</Card>
|
</template>
|
|
<script setup lang="ts">
|
import Card from './Card.vue';
|
import { Avatar } from '@12333/components';
|
import dayjs from 'dayjs';
|
import IconSystemAvatar from '@/assets/message/icon-system-avatar.png';
|
import MessageTimestamp from '../message/message-timestamp.vue';
|
|
defineOptions({
|
name: 'SystemMessageCard',
|
});
|
|
type Props = {
|
id?: string;
|
messageContent?: string;
|
creationTime?: string;
|
prevTime?: string | number;
|
type?: number;
|
};
|
|
const props = withDefaults(defineProps<Props>(), {});
|
</script>
|
|
<style lang="scss">
|
@import '@/styles/common.scss';
|
|
.system-message-card-wrapper {
|
border-radius: 0;
|
padding: 0 boleGetCssVar('size', 'body-padding-h');
|
margin-bottom: 0;
|
|
&:last-child {
|
.system-message-card-inner {
|
border-bottom: none;
|
}
|
}
|
|
.system-message-card-inner {
|
border-bottom: 2px solid #f6f6f6;
|
padding: 32px 0;
|
display: flex;
|
|
.system-message-card-avatar {
|
margin-right: 20px;
|
}
|
|
.system-message-card-content {
|
flex: 1;
|
min-width: 0;
|
|
.system-message-card-content-top {
|
display: flex;
|
align-items: center;
|
margin-bottom: 8px;
|
|
.system-message-card-title {
|
font-weight: 600;
|
font-size: 28px;
|
color: #555555;
|
line-height: 40px;
|
@include ellipsis;
|
flex: 1;
|
min-width: 0;
|
}
|
|
.system-message-card-time {
|
font-weight: 400;
|
font-size: 22px;
|
color: boleGetCssVar('text-color', 'regular');
|
line-height: 32px;
|
}
|
}
|
|
.system-message-card-content-bottom {
|
font-weight: 400;
|
font-size: 24px;
|
color: boleGetCssVar('text-color', 'regular');
|
line-height: 34px;
|
@include ellipsis;
|
}
|
}
|
}
|
}
|
|
.system-message-card-wrapper-v2 {
|
padding: 32px boleGetCssVar('size', 'body-padding-h');
|
font-weight: 400;
|
font-size: 28px;
|
color: boleGetCssVar('text-color', 'primary');
|
line-height: 44px;
|
}
|
</style>
|