zcash-grant-system/frontend/client/components/Comments/index.tsx

19 lines
452 B
TypeScript

import React from 'react';
import { Proposal, ProposalComments } from 'types';
import Comment from 'components/Comment';
interface Props {
comments: ProposalComments['comments'];
proposalId: Proposal['proposalId'];
}
const Comments = ({ comments, proposalId }: Props) => (
<React.Fragment>
{comments.map(c => (
<Comment key={c.commentId} comment={c} proposalId={proposalId} />
))}
</React.Fragment>
);
export default Comments;