1
Fork 0
mirror of https://github.com/pds-nest/nest.git synced 2024-11-24 14:04:19 +00:00
pds-2021-g2-nest/nest_frontend/components/base/FormLabelled.js

19 lines
488 B
JavaScript
Raw Normal View History

2021-04-22 17:10:19 +00:00
import React from "react"
2021-04-26 16:36:41 +00:00
import Style from "./FormLabelled.module.css"
2021-04-22 17:10:19 +00:00
import classNames from "classnames"
/**
* A form with two columns: the leftmost one contains labels, while the rightmost one contains input elements.
*
* @returns {JSX.Element}
* @constructor
*/
2021-04-26 16:36:41 +00:00
export default function FormLabelled({ children, className, ...props }) {
2021-04-22 17:10:19 +00:00
return (
<form className={classNames(Style.LabelledForm, className)} {...props}>
{children}
</form>
)
}