mirror of
https://github.com/System-End/site.git
synced 2026-04-19 20:55:09 +00:00
Add comment about rendering all form fields to DOM
This commit is contained in:
parent
39926188c5
commit
3bc355f347
1 changed files with 4 additions and 1 deletions
|
|
@ -9,7 +9,10 @@ export default function MultiStepForm({ children, submitButton }) {
|
|||
|
||||
return (
|
||||
<>
|
||||
{/* Render current step */}
|
||||
{/*
|
||||
We must render all form fields to DOM so that they can be submitted
|
||||
with the form. So, we simple hide all non-current steps.
|
||||
*/}
|
||||
{steps.map((stepComponent, index) => (
|
||||
<Box key={index} sx={step !== index ? { display: 'none' } : {}}>
|
||||
{stepComponent}
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue