Typo: WriteComment to CreateComment

This commit is contained in:
2024-06-22 07:58:04 +04:00
parent 06879763bc
commit 6cd2a0c438
3 changed files with 6 additions and 6 deletions
@@ -2,7 +2,7 @@
import CreateForm from '../forms/create-form.js'
export default function WriteComment(props) {
export default function CreateComment(props) {
return (
<CreateForm
{...props}
@@ -1,7 +1,7 @@
'use client'
import PropTypes from 'prop-types'
import WriteComment from './write-comment.js'
import CreateComment from './create-comment.js'
import ReadComments from './read-comments.js'
export default function HandleComments({
@@ -15,9 +15,9 @@ export default function HandleComments({
setIsSuccessAlertOpen,
operation
}) {
if (operation === 'write') {
if (operation === 'create') {
return (
<WriteComment
<CreateComment
session={session}
selectedTitre={selectedTitre}
isOpen={isOpen}
@@ -55,5 +55,5 @@ HandleComments.propTypes = {
setSuccess: PropTypes.func.isRequired,
setIsErrorAlertOpen: PropTypes.func.isRequired,
setIsSuccessAlertOpen: PropTypes.func.isRequired,
operation: PropTypes.oneOf(['write', 'read']).isRequired
operation: PropTypes.oneOf(['create', 'read']).isRequired
}
+1 -1
View File
@@ -74,7 +74,7 @@ export default function Konstitisyon({session, titres, articles}) {
</IconButton>
</Box>
<Box>
<IconButton size='large' aria-label='commenter' onClick={() => handleCommentsDialog(titreId, titre, 'write')}>
<IconButton size='large' aria-label='commenter' onClick={() => handleCommentsDialog(titreId, titre, 'create')}>
<LightTooltip title='Commenter'>
<AddCommentIcon color='warning' fontSize='inherit' />
</LightTooltip>