@datalayer/primer-rjsf
Version:
React JSON Schema Form (RJSF) for Primer
14 lines (13 loc) • 463 B
JavaScript
import { jsx as _jsx } from "react/jsx-runtime";
import { Text } from "@primer/react";
/** The `DescriptionField` is the template to use to render the description of a field
*
* @param props - The `DescriptionFieldProps` for this component
*/
export default function DescriptionField(props) {
const { id, description } = props;
if (description) {
return (_jsx(Text, { id: id, as: "p", mt: 1, children: description }));
}
return null;
}