fix: remove confirm phrase stage if change step
This commit is contained in:
parent
042b0fd0cb
commit
f4af9dab4a
|
@ -33,11 +33,12 @@ const ValidatorOnboarding = () => {
|
|||
const changeActiveStep = (step: number) => {
|
||||
setActiveStep(step)
|
||||
removeCopyPastePhraseInfoBox()
|
||||
removeConfirmPhraseStage()
|
||||
}
|
||||
|
||||
const continueHandler = () => {
|
||||
if (activeStep === 4 && isConfirmPhraseStage === false) {
|
||||
setIsConfirmPhraseStage(true)
|
||||
return setIsConfirmPhraseStage(true)
|
||||
} else if (activeStep === 3 && subStepValidatorSetup < 3) {
|
||||
setSubStepValidatorSetup(subStepValidatorSetup + 1)
|
||||
} else if (activeStep < 5) {
|
||||
|
@ -49,6 +50,7 @@ const ValidatorOnboarding = () => {
|
|||
navigate('/')
|
||||
}
|
||||
removeCopyPastePhraseInfoBox()
|
||||
removeConfirmPhraseStage()
|
||||
}
|
||||
|
||||
const removeCopyPastePhraseInfoBox = () => {
|
||||
|
@ -57,6 +59,12 @@ const ValidatorOnboarding = () => {
|
|||
}
|
||||
}
|
||||
|
||||
const removeConfirmPhraseStage = () => {
|
||||
if (isConfirmPhraseStage) {
|
||||
setIsConfirmPhraseStage(false)
|
||||
}
|
||||
}
|
||||
|
||||
return (
|
||||
<div className="gradient-wrapper">
|
||||
<YStack
|
||||
|
|
Loading…
Reference in New Issue