content: import React from 'react';
  import { connect } from 'react-redux';
  import { bindActionCreators } from 'redux';
  
  import * as hqActionCreators from '../actions/hqActionCreators';
  
  import Section from '../components/Section';
  import VerifyEmailCodeForm from '../components/forms/VerifyEmailCodeForm';
  
  let AdminChangeEmail = React.createClass({
    handleSubmit({ code }) {
      this.props.hqActions.verifyAdminEmail({ code: code });
    },
  
    render() {
      let { adminEmail } = this.props;
      return (
        <div>
          <h1>Verify admin email</h1>
  
          <Section>
            <p>Enter the code emailed to {adminEmail}.</p>
  
            <a href='/setup/email/reset'>Change email</a>
            <a>Resend code</a>
  
            <VerifyEmailCodeForm onSubmit={this.handleSubmit}/>
          </Section>
        </div>
      );
    }
  })
  
  function mapStateToProps(state) {
    return {
      adminEmail: state.hq.currentHQ.status.adminEmail
    };
  }
  
  function mapDispatchToProps(dispatch) {
    return {
      hqActions: bindActionCreators(hqActionCreators, dispatch)
    };
  }
  
  export default connect(mapStateToProps, mapDispatchToProps)(AdminChangeEmail);
  