// @flow import type { ElementConfig } from 'react'; import React from 'react'; import { connect } from 'react-redux'; import { create as createPopup } from 'components/ui/popup/actions'; import ContactForm from './ContactForm'; type OwnProps = $Exact>; type Props = { ...OwnProps, createContactPopup: () => void, }; function ContactLink({ createContactPopup, ...props }: Props) { return ( { event.preventDefault(); createContactPopup(); }} {...props} /> ); } export default connect( null, { createContactPopup: () => createPopup({ Popup: ContactForm }) } )(ContactLink);