chore: Add a different color for messages from bot (#2374)
Co-authored-by: Muhsin Keloth <muhsinkeramam@gmail.com> Co-authored-by: Pranav Raj S <pranav@chatwoot.com>
This commit is contained in:
parent
8a283a7783
commit
c028f30f82
1 changed files with 12 additions and 0 deletions
|
@ -197,11 +197,16 @@ export default {
|
|||
'is-private': this.data.private,
|
||||
'is-image': this.hasImageAttachment,
|
||||
'is-text': this.hasText,
|
||||
'is-from-bot': this.isSentByBot,
|
||||
};
|
||||
},
|
||||
isPending() {
|
||||
return this.data.status === MESSAGE_STATUS.PROGRESS;
|
||||
},
|
||||
isSentByBot() {
|
||||
if (this.isPending) return false;
|
||||
return !this.sender.type || this.sender.type === 'bot';
|
||||
},
|
||||
},
|
||||
};
|
||||
</script>
|
||||
|
@ -250,6 +255,13 @@ export default {
|
|||
color: var(--color-body);
|
||||
text-decoration: underline;
|
||||
}
|
||||
|
||||
&.is-from-bot {
|
||||
background: var(--v-400);
|
||||
.message-text--metadata .time {
|
||||
color: var(--v-50);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
&.is-pending {
|
||||
|
|
Loading…
Reference in a new issue