Move quick reactions and sender

Work on issue #122.
This commit is contained in:
N-Pex 2021-07-18 10:40:59 +02:00
parent 1b6671a6a7
commit cf634ae483
3 changed files with 26 additions and 26 deletions

View file

@ -1,13 +1,18 @@
<template>
<!-- BASE CLASS FOR INCOMING MESSAGE -->
<div :class="messageClasses">
<div v-if="showSenderAndTime" class="senderAndTime">
<div class="sender">{{ messageEventDisplayName(event) }}</div>
<div class="time">
{{ formatTime(event.event.origin_server_ts) }}
</div>
</div>
<v-avatar class="avatar" ref="avatar" size="32" color="#ededed" @click.stop="otherAvatarClicked($refs.avatar.$el)">
<img v-if="messageEventAvatar(event)" :src="messageEventAvatar(event)" />
<span v-else class="white--text headline">{{
messageEventDisplayName(event).substring(0, 1).toUpperCase()
}}</span>
</v-avatar>
<QuickReactions :event="event" :reactions="reactions" />
<!-- SLOT FOR CONTENT -->
<slot></slot>
<div class="op-button" ref="opbutton">
@ -15,12 +20,7 @@
><v-icon>more_vert</v-icon></v-btn
>
</div>
<div v-if="showSenderAndTime" class="senderAndTime">
<div class="sender">{{ messageEventDisplayName(event) }}</div>
<div class="time">
{{ formatTime(event.event.origin_server_ts) }}
</div>
</div>
<QuickReactions :event="event" :reactions="reactions" />
</div>
</template>

View file

@ -1,12 +1,19 @@
<template>
<!-- BASE CLASS FOR OUTGOING MESSAGE -->
<div class="messageOut">
<div class="senderAndTime">
<div class="time">
{{ formatTime(event.event.origin_server_ts) }}
</div>
<div class="status">{{ event.status }}</div>
</div>
<QuickReactions :event="event" :reactions="reactions" />
<div class="op-button" ref="opbutton">
<v-btn icon @click.stop="showContextMenu($refs.opbutton)"
><v-icon>more_vert</v-icon></v-btn
>
</div>
<QuickReactions :event="event" :reactions="reactions" />
<!-- SLOT FOR CONTENT -->
<slot></slot>
<v-avatar
@ -18,13 +25,6 @@
<img v-if="userAvatar" :src="userAvatar" />
<span v-else class="white--text headline">{{ userAvatarLetter }}</span>
</v-avatar>
<!-- <div class="sender">{{ $t('message.you') }}</div> -->
<div class="senderAndTime">
<div class="time">
{{ formatTime(event.event.origin_server_ts) }}
</div>
<div class="status">{{ event.status }}</div>
</div>
</div>
</template>