mirror of
https://github.com/astuto/astuto.git
synced 2025-12-16 19:57:52 +01:00
33 lines
760 B
TypeScript
33 lines
760 B
TypeScript
|
|
import * as React from 'react';
|
||
|
|
import { MutedText } from '../shared/CustomTexts';
|
||
|
|
|
||
|
|
interface Props {
|
||
|
|
postUpdateFlagValue: boolean;
|
||
|
|
handlePostUpdateFlag(): void;
|
||
|
|
}
|
||
|
|
|
||
|
|
const NewCommentUpdateSection = ({
|
||
|
|
postUpdateFlagValue,
|
||
|
|
handlePostUpdateFlag,
|
||
|
|
}: Props) => (
|
||
|
|
<div className="commentIsUpdateForm">
|
||
|
|
<div>
|
||
|
|
<input
|
||
|
|
id="isPostUpdateFlag"
|
||
|
|
type="checkbox"
|
||
|
|
onChange={handlePostUpdateFlag}
|
||
|
|
checked={postUpdateFlagValue || false}
|
||
|
|
/>
|
||
|
|
|
||
|
|
<label htmlFor="isPostUpdateFlag">Mark as post update</label>
|
||
|
|
</div>
|
||
|
|
{
|
||
|
|
postUpdateFlagValue ?
|
||
|
|
<MutedText>Users that follow this post will be notified</MutedText>
|
||
|
|
:
|
||
|
|
null
|
||
|
|
}
|
||
|
|
</div>
|
||
|
|
);
|
||
|
|
|
||
|
|
export default NewCommentUpdateSection;
|