Show sign out button only at initial step.

This commit is contained in:
Benoit Marty 2024-08-29 16:29:30 +02:00
parent f4beddef99
commit 9134d334bb

View file

@ -105,13 +105,15 @@ fun VerifySelfSessionView(
TopAppBar( TopAppBar(
title = {}, title = {},
actions = { actions = {
if (state.verificationFlowStep != FlowStep.Completed) { if (state.verificationFlowStep != FlowStep.Completed &&
if (state.displaySkipButton && LocalInspectionMode.current.not()) { state.displaySkipButton &&
TextButton( LocalInspectionMode.current.not()) {
text = stringResource(CommonStrings.action_skip), TextButton(
onClick = { state.eventSink(VerifySelfSessionViewEvents.SkipVerification) } text = stringResource(CommonStrings.action_skip),
) onClick = { state.eventSink(VerifySelfSessionViewEvents.SkipVerification) }
} )
}
if (state.verificationFlowStep is FlowStep.Initial) {
TextButton( TextButton(
text = stringResource(CommonStrings.action_signout), text = stringResource(CommonStrings.action_signout),
onClick = { state.eventSink(VerifySelfSessionViewEvents.SignOut) } onClick = { state.eventSink(VerifySelfSessionViewEvents.SignOut) }