We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 5546405 commit b48b3d2Copy full SHA for b48b3d2
src/components/containers.js
@@ -32,7 +32,9 @@ export function FormRow(props) {
32
33
34
export function FormGroup(props) {
35
- let innerClassName = props.level === 0 && !React.Children.count(props.children)
+ let hasChildren = React.Children.count(props.children);
36
+
37
+ let innerClassName = props.level === 0 && !hasChildren
38
? ""
39
: "rjf-form-group-inner";
40
@@ -48,7 +50,7 @@ export function FormGroup(props) {
48
50
onClick={(e) => props.onAdd()}
49
51
title="Add new"
52
>
- Add more
53
+ {hasChildren ? 'Add more' : 'Add'}
54
</Button>
55
}
56
</div>
0 commit comments