1
0
Fork 0
mirror of https://github.com/muerwre/vault-frontend.git synced 2025-04-25 04:46:40 +07:00

fix file uploads on comments

This commit is contained in:
Fedor Katurov 2023-10-30 17:23:30 +06:00
parent 8abf6177b5
commit 8e40cf9885
3 changed files with 35 additions and 26 deletions

View file

@ -1,5 +1,7 @@
import { FC, useCallback } from 'react';
import { observer } from 'mobx-react-lite';
import { CommentForm } from '~/components/comment/CommentForm';
import { CommentWrapper } from '~/components/containers/CommentWrapper';
import { UploadDropzone } from '~/components/upload/UploadDropzone';
@ -16,7 +18,7 @@ export interface Props {
saveComment: (comment: IComment) => Promise<IComment | undefined>;
}
const NodeCommentForm: FC<Props> = ({ saveComment }) => {
const NodeCommentForm: FC<Props> = observer(({ saveComment }) => {
const { user, isUser } = useAuth();
const showLoginDialog = useShowModal(Dialog.Login);
@ -42,6 +44,6 @@ const NodeCommentForm: FC<Props> = ({ saveComment }) => {
</UploaderContextProvider>
</UploadDropzone>
);
};
});
export { NodeCommentForm };