Updated on 2026-08-14
This commit is contained in:
commit
8c749c38c6
6 changed files with 32 additions and 1 deletions
|
|
@ -3,6 +3,7 @@ package com.tangem.tap.common.redux.legacy
|
|||
import com.tangem.domain.redux.LegacyAction
|
||||
import com.tangem.tap.common.feedback.RateCanBeBetterEmail
|
||||
import com.tangem.tap.common.redux.AppState
|
||||
import com.tangem.tap.common.redux.global.GlobalAction
|
||||
import com.tangem.tap.store
|
||||
import org.rekotlin.Middleware
|
||||
|
||||
|
|
@ -14,6 +15,11 @@ internal object LegacyMiddleware {
|
|||
is LegacyAction.SendEmailRateCanBeBetter -> {
|
||||
store.state.globalState.feedbackManager?.sendEmail(RateCanBeBetterEmail())
|
||||
}
|
||||
is LegacyAction.StartOnboardingProcess -> {
|
||||
store.dispatch(
|
||||
GlobalAction.Onboarding.Start(action.scanResponse, canSkipBackup = action.canSkipBackup),
|
||||
)
|
||||
}
|
||||
}
|
||||
next(action)
|
||||
}
|
||||
|
|
|
|||
|
|
@ -45,6 +45,7 @@ fun getActiveIconRes(blockchainId: String): Int {
|
|||
"aleph-zero", "aleph-zero/test" -> R.drawable.img_azero_22
|
||||
"octaspace", "octaspace/test" -> R.drawable.img_octaspace_22
|
||||
"chia", "chia/test" -> R.drawable.img_chia_22
|
||||
"NEAR", "NEAR/test" -> R.drawable.img_near_22
|
||||
"decimal", "decimal/testnet" -> R.drawable.img_decimal_22
|
||||
else -> R.drawable.ic_alert_24
|
||||
}
|
||||
|
|
@ -135,6 +136,7 @@ fun getGreyedOutIconRes(blockchainId: String): Int {
|
|||
"aleph-zero", "aleph-zero/test" -> R.drawable.ic_azero_22
|
||||
"octaspace", "octaspace/test" -> R.drawable.ic_octaspace_22
|
||||
"chia", "chia/test" -> R.drawable.ic_chia_22
|
||||
"NEAR", "NEAR/test" -> R.drawable.ic_near_22
|
||||
"decimal", "decimal/test" -> R.drawable.ic_decimal_22
|
||||
else -> R.drawable.ic_alert_24
|
||||
}
|
||||
|
|
|
|||
9
core/ui/src/main/res/drawable/ic_near_22.xml
Normal file
9
core/ui/src/main/res/drawable/ic_near_22.xml
Normal file
|
|
@ -0,0 +1,9 @@
|
|||
<vector xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:width="22dp"
|
||||
android:height="22dp"
|
||||
android:viewportWidth="22"
|
||||
android:viewportHeight="22">
|
||||
<path
|
||||
android:pathData="M15.721,5C15.277,5 14.864,5.23 14.632,5.609L12.123,9.333C12.042,9.456 12.075,9.622 12.197,9.703C12.297,9.77 12.429,9.761 12.519,9.683L14.988,7.542C15.029,7.505 15.092,7.509 15.129,7.55C15.146,7.569 15.155,7.593 15.155,7.618V14.323C15.155,14.378 15.11,14.423 15.055,14.423C15.025,14.423 14.997,14.41 14.978,14.387L7.515,5.453C7.272,5.166 6.915,5 6.539,5H6.278C5.572,5 5,5.572 5,6.278V15.722C5,16.428 5.572,17 6.278,17C6.723,17 7.135,16.77 7.368,16.391L9.876,12.667C9.958,12.544 9.925,12.378 9.802,12.297C9.703,12.23 9.571,12.239 9.481,12.317L7.012,14.458C6.971,14.495 6.907,14.491 6.87,14.45C6.854,14.432 6.845,14.407 6.845,14.382V7.676C6.845,7.62 6.89,7.576 6.945,7.576C6.975,7.576 7.003,7.589 7.022,7.612L14.484,16.547C14.727,16.834 15.084,17 15.46,17H15.721C16.427,17 16.999,16.428 17,15.722V6.278C17,5.572 16.428,5 15.722,5H15.721Z"
|
||||
android:fillColor="#000000" />
|
||||
</vector>
|
||||
|
|
@ -1,8 +1,16 @@
|
|||
package com.tangem.domain.redux
|
||||
|
||||
import com.tangem.domain.models.scan.ScanResponse
|
||||
import org.rekotlin.Action
|
||||
|
||||
sealed interface LegacyAction : Action {
|
||||
|
||||
object SendEmailRateCanBeBetter : LegacyAction
|
||||
|
||||
/**
|
||||
* Initiate an onboarding process.
|
||||
* For resuming unfinished backup of standard Wallet see
|
||||
* BackupAction.CheckForUnfinishedBackup, GlobalAction.Onboarding.StartForUnfinishedBackup
|
||||
*/
|
||||
data class StartOnboardingProcess(val scanResponse: ScanResponse, val canSkipBackup: Boolean = true) : LegacyAction
|
||||
}
|
||||
|
|
@ -431,6 +431,12 @@ internal class WalletViewModel @Inject constructor(
|
|||
|
||||
override fun onBackupCardClick() {
|
||||
analyticsEventsHandler.send(WalletScreenAnalyticsEvent.MainScreen.NoticeBackupYourWalletTapped)
|
||||
reduxStateHolder.dispatch(
|
||||
LegacyAction.StartOnboardingProcess(
|
||||
scanResponse = getSelectedWallet().scanResponse,
|
||||
canSkipBackup = false,
|
||||
),
|
||||
)
|
||||
router.openOnboardingScreen()
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -88,7 +88,7 @@ spr-client = "3.6.2"
|
|||
# endregion Other libraries
|
||||
|
||||
# region Tangem
|
||||
tangemBlockchainSdk = "release-app_5.2-389"
|
||||
tangemBlockchainSdk = "release-app_5.2-391"
|
||||
#tangemBlockchainSdk = "0.0.1" # Keep it! - used for local builds
|
||||
tangemCardSdk = "release-app_5.2-311"
|
||||
#tangemCardSdk = "0.0.1" # Keep it! - used for local builds
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue