From e891339907b58787f153e76184768dfdd2eb4ad1 Mon Sep 17 00:00:00 2001 From: ighmaz <44942623+ighmaZ@users.noreply.github.com> Date: Fri, 16 Sep 2022 06:28:12 +0530 Subject: [PATCH] feat: [for #18] limited message to 1000 (#23) --- src/components/MessageForm/MessageForm.tsx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/components/MessageForm/MessageForm.tsx b/src/components/MessageForm/MessageForm.tsx index 26b605f..506d8b4 100644 --- a/src/components/MessageForm/MessageForm.tsx +++ b/src/components/MessageForm/MessageForm.tsx @@ -31,7 +31,7 @@ export const MessageForm = ({ }, [textFieldRef]) const canMessageBeSent = () => { - return textMessage.trim().length > 0 && !isMessageSending + return textMessage.trim().length > 0 && textMessage.trim().length < 1000 && !isMessageSending } const handleMessageChange = (event: React.ChangeEvent) => {