This commit is contained in:
Philipinho
2023-11-24 18:06:32 +00:00
parent ca2881bd9b
commit 82b6a1b4bb
5 changed files with 9 additions and 9 deletions

View File

@ -4,7 +4,7 @@ import classes from './comment.module.css';
import { useAtomValue } from 'jotai';
import { timeAgo } from '@/lib/time';
import CommentEditor from '@/features/comment/components/comment-editor';
import { editorAtoms } from '@/features/editor/atoms/editor-atoms';
import { pageEditorAtom } from '@/features/editor/atoms/page-editor-atom';
import CommentActions from '@/features/comment/components/comment-actions';
import CommentMenu from '@/features/comment/components/comment-menu';
import { useHover } from '@mantine/hooks';
@ -22,7 +22,7 @@ function CommentListItem({ comment }: CommentListItemProps) {
const [isEditing, setIsEditing] = useState(false);
const [isLoading, setIsLoading] = useState(false);
const editor = useAtomValue(editorAtoms);
const editor = useAtomValue(pageEditorAtom);
const [content, setContent] = useState(comment.content);
const updateCommentMutation = useUpdateCommentMutation();
const deleteCommentMutation = useDeleteCommentMutation(comment.pageId);