mirror of
https://github.com/elyby/accounts-frontend.git
synced 2024-12-12 16:29:01 +05:30
48 lines
1.4 KiB
JavaScript
48 lines
1.4 KiB
JavaScript
import React, { Component, PropTypes } from 'react';
|
|
|
|
import { FormattedMessage as Message } from 'react-intl';
|
|
|
|
import { Button } from 'components/ui/form';
|
|
import { LangMenu } from 'components/langMenu';
|
|
|
|
import styles from './appInfo.scss';
|
|
import messages from './AppInfo.intl.json';
|
|
|
|
export default class AppInfo extends Component {
|
|
static displayName = 'AppInfo';
|
|
|
|
static propTypes = {
|
|
name: PropTypes.string,
|
|
description: PropTypes.string,
|
|
onGoToAuth: PropTypes.func.isRequired
|
|
};
|
|
|
|
render() {
|
|
const { name, description, onGoToAuth } = this.props;
|
|
|
|
return (
|
|
<div className={styles.appInfo}>
|
|
<div className={styles.logoContainer}>
|
|
<h2 className={styles.logo}>
|
|
{name ? name : (
|
|
<Message {...messages.appName} />
|
|
)}
|
|
</h2>
|
|
</div>
|
|
<div className={styles.descriptionContainer}>
|
|
<p className={styles.description}>
|
|
{description}
|
|
</p>
|
|
</div>
|
|
<div className={styles.goToAuth}>
|
|
<Button onClick={onGoToAuth} label={messages.goToAuth} />
|
|
</div>
|
|
|
|
<div className={styles.langMenu}>
|
|
<LangMenu />
|
|
</div>
|
|
</div>
|
|
);
|
|
}
|
|
}
|