Skip to content

Commit 0d6081f

Browse files
authored
Merge pull request #7658 from smeng9/formid
[Doc] Update <SaveButton/> prop in <Form/> example
2 parents 2478b75 + a29861d commit 0d6081f

File tree

3 files changed

+6
-6
lines changed

3 files changed

+6
-6
lines changed

docs/Form.md

+2-2
Original file line numberDiff line numberDiff line change
@@ -79,7 +79,7 @@ export const PostCreate = () => (
7979

8080
## `id`
8181

82-
Normally, a submit button only works when placed inside a `<form>` tag. However, you can place a submit button outside of the form if the submit button `form_id` matches the form `id`.
82+
Normally, a submit button only works when placed inside a `<form>` tag. However, you can place a submit button outside of the form if the submit button `form` matches the form `id`.
8383

8484
Set this form `id` via the `id` prop.
8585

@@ -93,7 +93,7 @@ export const PostCreate = () => (
9393
<NumberInput source="nb_views" />
9494
</Stack>
9595
</Form>
96-
<SaveButton formId="post_create_form" />
96+
<SaveButton form="post_create_form" />
9797
</Create>
9898
);
9999
```

docs/SimpleForm.md

+2-2
Original file line numberDiff line numberDiff line change
@@ -85,7 +85,7 @@ export const PostCreate = () => (
8585

8686
## `id`
8787

88-
Normally, a submit button only works when placed inside a `<form>` tag. However, you can place a submit button outside of the form if the submit button `form_id` matches the form `id`.
88+
Normally, a submit button only works when placed inside a `<form>` tag. However, you can place a submit button outside of the form if the submit button `form` matches the form `id`.
8989

9090
Set this form `id` via the `id` prop.
9191

@@ -97,7 +97,7 @@ export const PostCreate = () => (
9797
<RichTextInput source="body" />
9898
<NumberInput source="nb_views" />
9999
</SimpleForm>
100-
<SaveButton formId="post_create_form" />
100+
<SaveButton form="post_create_form" />
101101
</Create>
102102
);
103103
```

docs/TabbedForm.md

+2-2
Original file line numberDiff line numberDiff line change
@@ -122,7 +122,7 @@ export const PostCreate = () => (
122122

123123
## `id`
124124

125-
Normally, a submit button only works when placed inside a `<form>` tag. However, you can place a submit button outside of the form if the submit button `form_id` matches the form `id`.
125+
Normally, a submit button only works when placed inside a `<form>` tag. However, you can place a submit button outside of the form if the submit button `form` matches the form `id`.
126126

127127
Set this form `id` via the `id` prop.
128128

@@ -132,7 +132,7 @@ export const PostCreate = () => (
132132
<TabbedForm toolbar={false} id="post_create_form">
133133
...
134134
</TabbedForm>
135-
<SaveButton formId="post_create_form" />
135+
<SaveButton form="post_create_form" />
136136
</Create>
137137
);
138138
```

0 commit comments

Comments
 (0)