Skip to content
This repository was archived by the owner on Mar 9, 2023. It is now read-only.

Commit a823ce2

Browse files
authored
Merge branch 'master' into nested-layout
2 parents ecd3b90 + ca28742 commit a823ce2

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

src/NestField.tsx

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,7 @@ export type NestFieldProps = {
1010
fields?: any[];
1111
itemProps?: object;
1212
showInlineError?: boolean;
13+
disabled?: boolean;
1314
name: string;
1415
} & HTMLProps<HTMLDivElement>;
1516

@@ -22,6 +23,7 @@ const Nest = ({
2223
label,
2324
name,
2425
showInlineError,
26+
disabled,
2527
...props
2628
}: NestFieldProps) => {
2729

@@ -35,7 +37,7 @@ const Nest = ({
3537
? injectName(name, children)
3638
: fields?.map(key => (
3739
<>
38-
<AutoField key={key} isDisabled={props.disabled} name={joinName(name, key)} {...itemProps} />
40+
<AutoField key={key} disabled={disabled} name={joinName(name, key)} {...itemProps} />
3941
{/*
4042
Not ideal to use a <br> tag, but a layout workaround that
4143
won't impact further nested fields

0 commit comments

Comments
 (0)