-
Notifications
You must be signed in to change notification settings - Fork 1
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Reply message functionality #9
Conversation
…king the reply message preview
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Needs a few changes before merge.
src/fragments/ChatMessages.tsx
Outdated
) | ||
} | ||
/> | ||
<div key={message.id} id={message.id + ''}> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why the empty string concatenation?
src/fragments/FileInput.tsx
Outdated
const { sendFileMessage } = useContext(ChatAppContext); | ||
const [file, setFile] = useState<File>(); | ||
const { sendFileMessage, setFile } = useContext(ChatAppContext); | ||
const [file, setCurrentFile] = useState<File | null>(); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please follow the const [x, setX] = useState
naming convention
src/fragments/FileInput.tsx
Outdated
const { sendFileMessage } = useContext(ChatAppContext); | ||
const [file, setFile] = useState<File>(); | ||
const { sendFileMessage, setFile } = useContext(ChatAppContext); | ||
const [file, setCurrentFile] = useState<File | null>(); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Also, initialize the state value to null
src/providers/ChatAppProvider.tsx
Outdated
const test: any = message ; | ||
|
||
if(test.nestedLevel > 0){ | ||
console.log(test.nestedLevel) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please remove this console log statement
No description provided.