Skip to content

Commit df590e2

Browse files
committed
(UI) fixes
1 parent eb6d6f3 commit df590e2

File tree

2 files changed

+10
-2
lines changed

2 files changed

+10
-2
lines changed

src/ChatWindow/ChatMessage.vue

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -170,6 +170,9 @@
170170
:class="{
171171
'reaction-me': reaction.indexOf(currentUserId) !== -1
172172
}"
173+
:style="{
174+
float: message.sender_id === currentUserId ? 'right' : 'left'
175+
}"
173176
@click="sendMessageReaction({ name: key }, reaction)"
174177
>
175178
{{ getEmojiByName(key) }}<span>{{ reaction.length }}</span>
@@ -234,6 +237,9 @@ export default {
234237
this.newMessage = val.reduce((res, obj) =>
235238
obj.index < res.index ? obj : res
236239
)
240+
},
241+
emojiOpened(val) {
242+
if (val) this.closeOptions()
237243
}
238244
},
239245
@@ -354,7 +360,9 @@ export default {
354360
if (!this.optionsOpened) return
355361
356362
setTimeout(() => {
357-
if (!this.$refs.menuOptions || !this.roomFooterRef) return
363+
if (!this.roomFooterRef || !this.$refs.menuOptions || !this.actionIcon)
364+
return
365+
358366
const menuOptionsHeight = this.$refs.menuOptions.getBoundingClientRect()
359367
.height
360368

src/ChatWindow/MessagesList.vue

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -405,7 +405,7 @@ export default {
405405
},
406406
resizeTextarea(textarea) {
407407
textarea.style.height = 0
408-
textarea.style.height = textarea.scrollHeight + 2 + 'px'
408+
textarea.style.height = textarea.scrollHeight + 'px'
409409
},
410410
addEmoji(emoji) {
411411
this.message += emoji.icon

0 commit comments

Comments
 (0)