Skip to content

Commit

Permalink
docs(Form,FormFeedback,FormGroup,FormText): add props section (reacts…
Browse files Browse the repository at this point in the history
  • Loading branch information
gergely-nagy authored Sep 9, 2018
1 parent 5f33a1a commit 6e83cad
Showing 1 changed file with 50 additions and 4 deletions.
54 changes: 50 additions & 4 deletions docs/lib/Components/FormPage.js
Original file line number Diff line number Diff line change
Expand Up @@ -68,15 +68,16 @@ export default class FormPage extends React.Component {
addon: PropTypes.bool,
className: PropTypes.string,
cssModule: PropTypes.object,
};`}
{`CustomInput.propTypes = {
};
CustomInput.propTypes = {
className: PropTypes.string,
id: PropTypes.oneOfType([PropTypes.string, PropTypes.number]).isRequired,
type: PropTypes.string.isRequired, // radio, checkbox, select, range.
label: PropTypes.string, // used for checkbox and radios
inline: PropTypes.bool,
valid: PropTypes.bool, // applied the is-invalid class when true, does nothing when false
invalid: PropTypes.bool, // applied the is-valid class when true, does nothing when false
valid: PropTypes.bool, // applied the is-valid class when true, does nothing when false
invalid: PropTypes.bool, // applied the is-invalid class when true, does nothing when false
bsSize: PropTypes.string,
cssModule: PropTypes.object,
children: PropTypes.oneOfType([PropTypes.node, PropTypes.array, PropTypes.func]), // for type="select"
Expand All @@ -86,6 +87,51 @@ export default class FormPage extends React.Component {
PropTypes.string,
PropTypes.func,
])
};
Form.propTypes = {
children: PropTypes.node,
inline: PropTypes.bool,
// Pass in a Component to override default element
tag: PropTypes.oneOfType([PropTypes.func, PropTypes.string]), // default: 'form'
innerRef: PropTypes.oneOfType([PropTypes.object, PropTypes.func, PropTypes.string]),
className: PropTypes.string,
cssModule: PropTypes.object,
};
FormFeedback.propTypes = {
children: PropTypes.node,
// Pass in a Component to override default element
tag: PropTypes.string, // default: 'div'
className: PropTypes.string,
cssModule: PropTypes.object,
valid: PropTypes.bool, // default: undefined
tooltip: PropTypes.bool
};
FormGroup.propTypes = {
children: PropTypes.node,
// Applied the row class when true, does nothing when false
row: PropTypes.bool,
// Applied the form-check class when true, form-group when false
check: PropTypes.bool,
inline: PropTypes.bool,
// Applied the disabled class when the check and disabled props are true, does nothing when false
disabled: PropTypes.bool,
// Pass in a Component to override default element
tag: PropTypes.string, // default: 'div'
className: PropTypes.string,
cssModule: PropTypes.object,
};
FormText.propTypes = {
children: PropTypes.node,
inline: PropTypes.bool,
// Pass in a Component to override default element
tag: PropTypes.oneOfType([PropTypes.func, PropTypes.string]), // default: 'small'
color: PropTypes.string, // default: 'muted'
className: PropTypes.string,
cssModule: PropTypes.object,
};`}
</PrismCode>
</pre>
Expand Down

0 comments on commit 6e83cad

Please sign in to comment.