feat: Vite + vue 3 💚 (#10047)
Fixes https://github.com/chatwoot/chatwoot/issues/8436 Fixes https://github.com/chatwoot/chatwoot/issues/9767 Fixes https://github.com/chatwoot/chatwoot/issues/10156 Fixes https://github.com/chatwoot/chatwoot/issues/6031 Fixes https://github.com/chatwoot/chatwoot/issues/5696 Fixes https://github.com/chatwoot/chatwoot/issues/9250 Fixes https://github.com/chatwoot/chatwoot/issues/9762 --------- Co-authored-by: Pranav <pranavrajs@gmail.com> Co-authored-by: Sivin Varghese <64252451+iamsivin@users.noreply.github.com>
This commit is contained in:
@@ -7,6 +7,8 @@ import {
|
||||
ON_CAMPAIGN_MESSAGE_CLICK,
|
||||
ON_UNREAD_MESSAGE_CLICK,
|
||||
} from '../constants/widgetBusEvents';
|
||||
import { emitter } from 'shared/helpers/mitt';
|
||||
|
||||
import { useDarkMode } from 'widget/composables/useDarkMode';
|
||||
export default {
|
||||
name: 'UnreadMessage',
|
||||
@@ -50,10 +52,9 @@ export default {
|
||||
},
|
||||
avatarUrl() {
|
||||
// eslint-disable-next-line
|
||||
const BotImage = require('dashboard/assets/images/chatwoot_bot.png');
|
||||
const displayImage = this.useInboxAvatarForBot
|
||||
? this.inboxAvatarUrl
|
||||
: BotImage;
|
||||
: '/assets/images/chatwoot_bot.png';
|
||||
if (this.isSenderExist(this.sender)) {
|
||||
const { avatar_url: avatarUrl } = this.sender;
|
||||
return avatarUrl;
|
||||
@@ -84,9 +85,9 @@ export default {
|
||||
},
|
||||
onClickMessage() {
|
||||
if (this.campaignId) {
|
||||
this.$emitter.emit(ON_CAMPAIGN_MESSAGE_CLICK, this.campaignId);
|
||||
emitter.emit(ON_CAMPAIGN_MESSAGE_CLICK, this.campaignId);
|
||||
} else {
|
||||
this.$emitter.emit(ON_UNREAD_MESSAGE_CLICK);
|
||||
emitter.emit(ON_UNREAD_MESSAGE_CLICK);
|
||||
}
|
||||
},
|
||||
},
|
||||
@@ -119,7 +120,8 @@ export default {
|
||||
</template>
|
||||
|
||||
<style lang="scss" scoped>
|
||||
@import '~widget/assets/scss/variables.scss';
|
||||
@import 'widget/assets/scss/variables.scss';
|
||||
|
||||
.chat-bubble {
|
||||
max-width: 85%;
|
||||
padding: $space-normal;
|
||||
@@ -132,10 +134,12 @@ export default {
|
||||
text-align: left;
|
||||
padding-bottom: $space-small;
|
||||
font-size: $font-size-small;
|
||||
|
||||
.agent--name {
|
||||
font-weight: $font-weight-medium;
|
||||
margin-left: $space-smaller;
|
||||
}
|
||||
|
||||
.company--name {
|
||||
color: $color-light-gray;
|
||||
margin-left: $space-smaller;
|
||||
|
||||
Reference in New Issue
Block a user