index.js 1006 Bytes
Newer Older
jim's avatar
jim committed
1 2 3
import React, { PureComponent } from 'react';
import { Link } from 'dva/router';
import RightContent from '../GlobalHeader/RightContent';
Erwin Zhang's avatar
Erwin Zhang committed
4
import BaseMenu from '../SiderMenu/BaseMenu';
jim's avatar
jim committed
5 6 7 8 9
import styles from './index.less';

export default class TopNavHeader extends PureComponent {
  render() {
    return (
jim's avatar
jim committed
10 11
      <div className={`${styles.head} ${this.props.theme === 'light' ? styles.light : ''}`}>
        <div className={`${styles.main} ${this.props.grid === 'Wide' ? styles.wide : ''}`}>
jim's avatar
jim committed
12
          <div className={styles.left}>
13
            <div className={styles.logo} key="logo" id="logo">
jim's avatar
jim committed
14 15 16 17 18
              <Link to="/">
                <img src={this.props.logo} alt="logo" />
                <h1>Ant Design Pro</h1>
              </Link>
            </div>
qixian.cs@outlook.com's avatar
qixian.cs@outlook.com committed
19
            <BaseMenu {...this.props} style={{ paddingTop: '9px', border: 'none' }} />
jim's avatar
jim committed
20 21 22
          </div>
          <div className={styles.right}>
            <RightContent {...this.props} />
jim's avatar
jim committed
23 24 25 26 27 28
          </div>
        </div>
      </div>
    );
  }
}