mirror of
https://github.com/ant-design/ant-design.git
synced 2024-11-27 12:39:49 +08:00
fix eslint
This commit is contained in:
parent
4ac775212f
commit
fc9eacbd7e
@ -34,6 +34,7 @@ const eslintrc = {
|
||||
'no-return-assign': 0,
|
||||
'max-len': 0,
|
||||
'consistent-return': 0,
|
||||
'no-redeclare': 0,
|
||||
}
|
||||
};
|
||||
|
||||
|
@ -46,7 +46,7 @@ export default class Tag extends React.Component {
|
||||
|
||||
render() {
|
||||
const { prefixCls, closable, color, className, children, ...otherProps } = this.props;
|
||||
const close = closable ? <Icon type="cross" onClick={this.close} /> : '';
|
||||
const closeIcon = closable ? <Icon type="cross" onClick={this.close} /> : '';
|
||||
const classString = classNames({
|
||||
[prefixCls]: true,
|
||||
[`${prefixCls}-${color}`]: !!color,
|
||||
@ -68,7 +68,7 @@ export default class Tag extends React.Component {
|
||||
{this.state.closed ? null : (
|
||||
<div data-show={!this.state.closing} {...divProps} className={classString}>
|
||||
<span className={`${prefixCls}-text`}>{children}</span>
|
||||
{close}
|
||||
{closeIcon}
|
||||
</div>
|
||||
)}
|
||||
</Animate>
|
||||
|
Loading…
Reference in New Issue
Block a user