fix wizard next

This commit is contained in:
Thomas Ruoff
2020-07-21 00:24:36 +02:00
parent 809f69a3bd
commit 279210599b

View File

@@ -31,14 +31,12 @@ function WizardInternal() {
console.log(key, value)
}
console.log(state)
return
if (!isLastStep) {
dispatch({ type: ACTIONS.NEXT_STEP })
return
}
throw Error('Submit not implemented yet')
dispatch({ type: ACTIONS.SUBMIT })
}}
>
@@ -54,7 +52,7 @@ function WizardInternal() {
</Button>
)}
{!isLastStep && <Button type="submit">Weiter</Button>}
{isLastStep && <Button>Absenden</Button>}
{isLastStep && <Button type="submit">Absenden</Button>}
</Form>
)
}