import React from 'react'; import { FormattedMessage } from 'react-intl' import logo from './images/header-logo.png' class Header extends React.Component { constructor(props) { super(props); this.state = { type: props.type }; } render() { let signUpButton; let signInButton; let text; const pageType = this.state.type; if (pageType === 'only-signup') { text = ; signUpButton = ; } else if (pageType === 'only-signin') { text = ; signUpButton = ; } else { signUpButton = signInButton = ; } return ( {text} {signUpButton} {signInButton} ) }; } const SignInButton = (props) => { return ( ); } const SignUpButton = (props) => { return ( ); } export default Header;