import React from 'react'; const name = 'coral-plugin-flags'; const FlagButton = ({flag, item_id, postAction, currentUser, addNotification}) => { const flagged = flag && flag.includes(currentUser); const onFlagClick = () => { postAction(item_id, 'flag', currentUser); addNotification('success', 'Thank you for reporting this comment. Our moderation team has been notified and will review it shortly.'); }; return
; }; export default FlagButton; const styles = { flaggedIcon: { color: '#F00' }, unflaggedIcon: { color: 'inherit' } };