mirror of
https://gitlab.nic.cz/turris/reforis/foris-js.git
synced 2024-12-25 00:11:36 +01:00
Merge branch 'radioset-element-children' into 'dev'
Allow RadioSet accept elements as children. See merge request turris/reforis/foris-js!98
This commit is contained in:
commit
1ee41f4f14
|
@ -17,7 +17,12 @@ RadioSet.propTypes = {
|
||||||
/** Choices . */
|
/** Choices . */
|
||||||
choices: PropTypes.arrayOf(PropTypes.shape({
|
choices: PropTypes.arrayOf(PropTypes.shape({
|
||||||
/** Choice lable . */
|
/** Choice lable . */
|
||||||
label: PropTypes.string.isRequired,
|
label: PropTypes.oneOfType([
|
||||||
|
PropTypes.string,
|
||||||
|
PropTypes.element,
|
||||||
|
PropTypes.node,
|
||||||
|
PropTypes.arrayOf(PropTypes.node),
|
||||||
|
]).isRequired,
|
||||||
/** Choice value . */
|
/** Choice value . */
|
||||||
value: PropTypes.oneOfType([PropTypes.string, PropTypes.number]).isRequired,
|
value: PropTypes.oneOfType([PropTypes.string, PropTypes.number]).isRequired,
|
||||||
})).isRequired,
|
})).isRequired,
|
||||||
|
@ -58,7 +63,12 @@ export function RadioSet({
|
||||||
}
|
}
|
||||||
|
|
||||||
Radio.propTypes = {
|
Radio.propTypes = {
|
||||||
label: PropTypes.string.isRequired,
|
label: PropTypes.oneOfType([
|
||||||
|
PropTypes.string,
|
||||||
|
PropTypes.element,
|
||||||
|
PropTypes.node,
|
||||||
|
PropTypes.arrayOf(PropTypes.node),
|
||||||
|
]).isRequired,
|
||||||
id: PropTypes.string.isRequired,
|
id: PropTypes.string.isRequired,
|
||||||
helpText: PropTypes.string,
|
helpText: PropTypes.string,
|
||||||
};
|
};
|
||||||
|
|
Loading…
Reference in New Issue
Block a user