accounts-frontend/src/components/auth/AppInfo.jsx

41 lines
1.2 KiB
React
Raw Normal View History

import React, { Component, PropTypes } from 'react';
import { FormattedMessage as Message } from 'react-intl';
import buttons from 'components/ui/buttons.scss';
2016-01-04 02:48:42 +05:30
import styles from './appInfo.scss';
import messages from './AppInfo.messages';
export default class AppInfo extends Component {
static displayName = 'AppInfo';
static propTypes = {
name: PropTypes.string.isRequired,
description: PropTypes.string.isRequired,
onGoToAuth: PropTypes.func.isRequired
};
2016-01-04 02:48:42 +05:30
render() {
var { name, description, onGoToAuth } = this.props;
2016-01-04 02:48:42 +05:30
return (
<div className={styles.appInfo}>
<div className={styles.logoContainer}>
2016-03-02 02:06:14 +05:30
<h2 className={styles.logo}>{name || 'Ely Accounts'}</h2>
2016-01-04 02:48:42 +05:30
</div>
<div className={styles.descriptionContainer}>
<p className={styles.description}>
{description}
2016-01-04 02:48:42 +05:30
</p>
</div>
<div className={styles.goToAuth}>
<button className={buttons.green} onClick={onGoToAuth}>
<Message {...messages.goToAuth} />
</button>
</div>
2016-01-04 02:48:42 +05:30
</div>
);
}
}