|
|
@@ -110,25 +110,6 @@ const PageComment:FC<Props> = memo((props:Props):JSX.Element => {
|
|
|
}
|
|
|
}, [commentToBeDeleted, onDeleteCommentAfterOperation]);
|
|
|
|
|
|
- const generateCommentInnerElement = (comment: ICommentHasId) => (
|
|
|
- <Comment
|
|
|
- rendererOptions={rendererOptions}
|
|
|
- deleteBtnClicked={onClickDeleteButton}
|
|
|
- comment={comment}
|
|
|
- onComment={mutate}
|
|
|
- isReadOnly={isReadOnly}
|
|
|
- />
|
|
|
- );
|
|
|
-
|
|
|
- const generateAllRepliesElement = (replyComments: ICommentHasIdList) => (
|
|
|
- <ReplayComments
|
|
|
- replyList={replyComments}
|
|
|
- deleteBtnClicked={onClickDeleteButton}
|
|
|
- rendererOptions={rendererOptions}
|
|
|
- isReadOnly={isReadOnly}
|
|
|
- />
|
|
|
- );
|
|
|
-
|
|
|
const removeShowEditorId = useCallback((commentId: string) => {
|
|
|
setShowEditorIds((previousState) => {
|
|
|
const previousShowEditorIds = new Set(...previousState);
|
|
|
@@ -148,6 +129,26 @@ const PageComment:FC<Props> = memo((props:Props):JSX.Element => {
|
|
|
return <></>;
|
|
|
}
|
|
|
|
|
|
+ const generateCommentInnerElement = (comment: ICommentHasId) => (
|
|
|
+ <Comment
|
|
|
+ rendererOptions={rendererOptions}
|
|
|
+ deleteBtnClicked={onClickDeleteButton}
|
|
|
+ comment={comment}
|
|
|
+ onComment={mutate}
|
|
|
+ isReadOnly={isReadOnly}
|
|
|
+ />
|
|
|
+ );
|
|
|
+
|
|
|
+ const generateAllRepliesElement = (replyComments: ICommentHasIdList) => (
|
|
|
+ <ReplayComments
|
|
|
+ replyList={replyComments}
|
|
|
+ deleteBtnClicked={onClickDeleteButton}
|
|
|
+ rendererOptions={rendererOptions}
|
|
|
+ isReadOnly={isReadOnly}
|
|
|
+ onComment={mutate}
|
|
|
+ />
|
|
|
+ );
|
|
|
+
|
|
|
let commentTitleClasses = 'border-bottom py-3 mb-3';
|
|
|
commentTitleClasses = titleAlign != null ? `${commentTitleClasses} text-${titleAlign}` : `${commentTitleClasses} text-center`;
|
|
|
|