Closed floydchenchen closed 6 years ago
<Form>
<Form action="/" onSubmit={(submitObject) => {console.log(submitObject)}}> <div className="ONLY-CHILD"> <div style={{ width: "250px", paddingRight: "10px", display: "inline-block"}}> <TextField name="firstName" style={{width: "200px"}} label="First Name: " required/> <TextField name="lastName" style={{width: "200px"}} label="Last Name: " required/> </div> <Button primary type="submit">Submit</Button> </div> </Form>
<Form action="/" onSubmit={(submitObject) => {console.log(submitObject)}}> <div className="FIRST-CHILD"> <div style={{ width: "250px", paddingRight: "10px", display: "inline-block"}}> <TextField name="firstName" style={{width: "200px"}} label="First Name: " required/> <TextField name="lastName" style={{width: "200px"}} label="Last Name: " required/> </div> <Button primary type="submit">Submit</Button> </div> <div className="SECOND-CHILD"></div> </Form>
This has been fixed in the Form PR #953. Thanks for testing.
to reproduce:
when there is only one child inside
<Form>
, an error will come up in the consolehaving at least two children will solve this issue