import React from 'react'; import { v4 as uuid } from 'uuid'; import PropTypes from 'prop-types'; const propTypes = { children: PropTypes.node.isRequired, value: PropTypes.string.isRequired, onChange: PropTypes.func.isRequired, id: PropTypes.string, type: PropTypes.string, required: PropTypes.bool, }; export const HorizontalFormGroup = ({ children, value, onChange, id = uuid(), type = 'text', required = true }) => (
onChange(e.target.value)} />
); HorizontalFormGroup.propTypes = propTypes;