diff --git a/app/javascript/dashboard/components/widgets/conversation/ReplyBox.vue b/app/javascript/dashboard/components/widgets/conversation/ReplyBox.vue index dd2e7a607..ef6fa03d6 100644 --- a/app/javascript/dashboard/components/widgets/conversation/ReplyBox.vue +++ b/app/javascript/dashboard/components/widgets/conversation/ReplyBox.vue @@ -253,6 +253,9 @@ export default { if (this.isAnInstagramChannel) { return MESSAGE_MAX_LENGTH.INSTAGRAM; } + if (this.isATelegramChannel) { + return MESSAGE_MAX_LENGTH.TELEGRAM; + } if (this.isATiktokChannel) { return MESSAGE_MAX_LENGTH.TIKTOK; } @@ -545,7 +548,10 @@ export default { }, setCopilotAcceptedMessage(message, replyType = this.replyType) { const key = this.getDraftKey(this.conversationIdByRoute, replyType); - this.copilotAcceptedMessages[key] = trimContent(message || ''); + this.copilotAcceptedMessages[key] = trimContent( + message || '', + this.maxLength + ); }, clearCopilotAcceptedMessage(replyType = this.replyType) { const key = this.getDraftKey(this.conversationIdByRoute, replyType); @@ -603,7 +609,7 @@ export default { saveDraft(conversationId, replyType) { if (this.message || this.message === '') { const key = this.getDraftKey(conversationId, replyType); - const draftToSave = trimContent(this.message || ''); + const draftToSave = trimContent(this.message || '', this.maxLength); this.$store.dispatch('draftMessages/set', { key,