keystone
Version:
Web Application Framework and Admin GUI / Content Management System built on Express.js and Mongoose
27 lines (23 loc) • 588 B
JavaScript
import React from 'react';
import { FormField, FormLabel } from '../../admin/client/App/elemental';
import theme from '../../admin/client/theme';
function NestedFormField ({ children, className, label, ...props }) {
return (
<FormField {...props}>
<FormLabel cssStyles={classes.label}>
{label}
</FormLabel>
{children}
</FormField>
);
};
const classes = {
label: {
color: theme.color.gray40,
fontSize: theme.font.size.small,
[`@media (min-width: ${theme.breakpoint.tabletLandscapeMin})`]: {
paddingLeft: '1em',
},
},
};
module.exports = NestedFormField;