So one way to do it could be:
- Add some javascript to attach a custom redirect to the submit button that includes all the values of the step 1 fields as the URL parameters. So it would look like
/simulation-portage-salarial?name=[Name]&email=[Email]...
- Then have another script that run on page load (
DOMContentLoaded
) that readswindow.location.search
to get the parameters, pass them to the form inputs, then use JS to remove the hide class from step 2.
If you don’t want the fields to be in the URL, you could also save them to sessionStorage
& read them that way. Hopefully that make sense & helps point in the right direction!