Update "Learn more" link (#4686)
* Update target link for "Learn more". * Rename VerifySelfSession* to OutgoingVerification* * Optimize import * Refactor to avoid long line * Update screenshots --------- Co-authored-by: ElementBot <android@element.io>
This commit is contained in:
parent
8f484c322f
commit
3391e7cc55
48 changed files with 194 additions and 196 deletions
|
|
@ -1,5 +1,4 @@
|
|||
import extension.setupAnvil
|
||||
import org.gradle.kotlin.dsl.test
|
||||
|
||||
/*
|
||||
* Copyright 2023, 2024 New Vector Ltd.
|
||||
|
|
|
|||
|
|
@ -26,7 +26,7 @@ import io.element.android.anvilannotations.ContributesNode
|
|||
import io.element.android.appconfig.LearnMoreConfig
|
||||
import io.element.android.features.ftue.impl.sessionverification.choosemode.ChooseSelfVerificationModeNode
|
||||
import io.element.android.features.securebackup.api.SecureBackupEntryPoint
|
||||
import io.element.android.features.verifysession.api.VerifySessionEntryPoint
|
||||
import io.element.android.features.verifysession.api.OutgoingVerificationEntryPoint
|
||||
import io.element.android.libraries.architecture.BackstackView
|
||||
import io.element.android.libraries.architecture.BaseFlowNode
|
||||
import io.element.android.libraries.architecture.createNode
|
||||
|
|
@ -40,7 +40,7 @@ import kotlinx.parcelize.Parcelize
|
|||
class FtueSessionVerificationFlowNode @AssistedInject constructor(
|
||||
@Assisted buildContext: BuildContext,
|
||||
@Assisted plugins: List<Plugin>,
|
||||
private val verifySessionEntryPoint: VerifySessionEntryPoint,
|
||||
private val outgoingVerificationEntryPoint: OutgoingVerificationEntryPoint,
|
||||
private val secureBackupEntryPoint: SecureBackupEntryPoint,
|
||||
) : BaseFlowNode<FtueSessionVerificationFlowNode.NavTarget>(
|
||||
backstack = BackStack(
|
||||
|
|
@ -94,19 +94,19 @@ class FtueSessionVerificationFlowNode @AssistedInject constructor(
|
|||
}
|
||||
|
||||
override fun onLearnMoreAboutEncryption() {
|
||||
learnMoreUrl.value = LearnMoreConfig.ENCRYPTION_URL
|
||||
learnMoreUrl.value = LearnMoreConfig.DEVICE_VERIFICATION_URL
|
||||
}
|
||||
}
|
||||
|
||||
createNode<ChooseSelfVerificationModeNode>(buildContext, plugins = listOf(callback))
|
||||
}
|
||||
is NavTarget.UseAnotherDevice -> {
|
||||
verifySessionEntryPoint.nodeBuilder(this, buildContext)
|
||||
.params(VerifySessionEntryPoint.Params(
|
||||
outgoingVerificationEntryPoint.nodeBuilder(this, buildContext)
|
||||
.params(OutgoingVerificationEntryPoint.Params(
|
||||
showDeviceVerifiedScreen = true,
|
||||
verificationRequest = VerificationRequest.Outgoing.CurrentSession,
|
||||
))
|
||||
.callback(object : VerifySessionEntryPoint.Callback {
|
||||
.callback(object : OutgoingVerificationEntryPoint.Callback {
|
||||
override fun onDone() {
|
||||
plugins<Callback>().forEach { it.onDone() }
|
||||
}
|
||||
|
|
@ -116,7 +116,8 @@ class FtueSessionVerificationFlowNode @AssistedInject constructor(
|
|||
}
|
||||
|
||||
override fun onLearnMoreAboutEncryption() {
|
||||
learnMoreUrl.value = LearnMoreConfig.ENCRYPTION_URL
|
||||
// Note that this callback is never called. The "Learn more" link is not displayed
|
||||
// for the self session interactive verification.
|
||||
}
|
||||
})
|
||||
.build()
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue