import React from 'react'; import classNames from 'classnames'; import styles from './index.less'; interface StandardFormRowProps { title?: string; last?: boolean; block?: boolean; grid?: boolean; style?: React.CSSProperties; } const StandardFormRow: React.SFC = ({ title, children, last, block, grid, ...rest }) => { const cls = classNames(styles.standardFormRow, { [styles.standardFormRowBlock]: block, [styles.standardFormRowLast]: last, [styles.standardFormRowGrid]: grid, }); return (
{title && (
{title}
)}
{children}
); }; export default StandardFormRow;