1 | import React, { Component } from 'react';
|
2 | import ReactDOM from 'react-dom';
|
3 | import PropTypes from 'prop-types';
|
4 |
|
5 | const propTypes = {
|
6 | prefixCls: PropTypes.string,
|
7 | };
|
8 | const defaultProps = {
|
9 | prefixCls:'u-form',
|
10 | };
|
11 | class FormItem extends Component {
|
12 | constructor(props) {
|
13 | super(props);
|
14 | }
|
15 | render() {
|
16 | const {children,className = '',prefixCls,style , ...others} = this.props;
|
17 | return (
|
18 | <div className={`${prefixCls}-item`+' '+className } style={style} {...others}>
|
19 | {children}
|
20 | </div>
|
21 | )
|
22 | }
|
23 | };
|
24 | FormItem.propTypes = propTypes;
|
25 | FormItem.defaultProps = defaultProps;
|
26 | export default FormItem; |
\ | No newline at end of file |