Skip to content
This repository has been archived by the owner on Nov 6, 2020. It is now read-only.

Commit

Permalink
feat(field): add className prop
Browse files Browse the repository at this point in the history
  • Loading branch information
Mohammer5 authored and varl committed Nov 25, 2019
1 parent 1468e35 commit 7565d59
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions src/Field.js
Original file line number Diff line number Diff line change
Expand Up @@ -10,8 +10,8 @@ import { spacers } from './theme.js'
* @example import { Field } from @dhis2/ui-core
* @see Live demo: {@link /demo/?path=/story/field--default|Storybook}
*/
const Field = ({ children }) => (
<div>
const Field = ({ children, className }) => (
<div className={className}>
{children}
<style jsx>{`
div {
Expand All @@ -25,9 +25,11 @@ const Field = ({ children }) => (
* @typedef {Object} PropTypes
* @static
* @prop {Node} children
* @prop {string} [className]
*/
Field.propTypes = {
children: propTypes.node.isRequired,
className: propTypes.string,
}

export { Field }

0 comments on commit 7565d59

Please sign in to comment.