mirror of
https://gitee.com/ant-design/ant-design.git
synced 2024-12-02 03:59:01 +08:00
fix FormItem help and extra render
This commit is contained in:
parent
1d72c8abcc
commit
0858413691
@ -40,16 +40,16 @@ class FormItem extends React.Component {
|
||||
const props = this.props;
|
||||
const prefixCls = props.prefixCls;
|
||||
const help = this.getHelpMsg();
|
||||
return (
|
||||
<div className={!!help ? prefixClsFn(prefixCls, 'explain') : ''} key="help">
|
||||
{ help }
|
||||
return help ? (
|
||||
<div className={prefixClsFn(prefixCls, 'explain')} key="help">
|
||||
{help}
|
||||
</div>
|
||||
);
|
||||
) : null;
|
||||
}
|
||||
|
||||
renderExtra() {
|
||||
const { prefixCls, extra } = this.props;
|
||||
return <div className={prefixClsFn(prefixCls, 'extra')}>{extra}</div>;
|
||||
return <span className={prefixClsFn(prefixCls, 'extra')}>{extra}</span>;
|
||||
}
|
||||
|
||||
getValidateStatus() {
|
||||
|
Loading…
Reference in New Issue
Block a user