import React from 'react'; import { Icon } from 'antd'; import classNames from 'classnames'; import './index.less'; import { createGetClassName } from '../../util/util'; const getClassName = createGetClassName('footer'); export interface FooterLink { title: string; blankTarget?: boolean; href: string; } export interface FooterProps { className?: string; links?: FooterLink[]; copyright?: React.ReactNode; } export default class Footer extends React.Component { static defaultProps = { links: [], copyright: '2018 东方星空', }; render() { const { className, links, copyright } = this.props; const clsString = classNames(getClassName(), className); return (
{ links && (
{links.map(link => ( {link.title} ))}
) } {copyright && (
Copyright {copyright}
)}
); } }