Updated on 2026-08-14
This commit is contained in:
commit
b1fe794f48
12 changed files with 33 additions and 8 deletions
|
|
@ -1 +1 @@
|
|||
Subproject commit af8b453fd25b29d949c05302ec282511dc2614b8
|
||||
Subproject commit 8e5de701e02a2d48a68e32cd4783549dde01983e
|
||||
|
|
@ -300,6 +300,7 @@ class MainActivity : AppCompatActivity(), SnackbarHandler, ActivityResultCallbac
|
|||
private fun setRootContent() {
|
||||
val routingComponent = routingComponentFactory.create(
|
||||
context = rootComponentContext,
|
||||
initialStack = null,
|
||||
)
|
||||
|
||||
setContent {
|
||||
|
|
@ -308,8 +309,12 @@ class MainActivity : AppCompatActivity(), SnackbarHandler, ActivityResultCallbac
|
|||
}
|
||||
|
||||
private fun installRouting() {
|
||||
// for now activity is singleTop and after going to ChromeCustomTab it calls onCreate but onDestroy
|
||||
// doesn't calls. It lead to issue that decompose nav stack is not saved in bundle and to restore it
|
||||
// we try to init component with previous stack
|
||||
val routingComponent = routingComponentFactory.create(
|
||||
context = rootComponentContext,
|
||||
initialStack = appRouterConfig.stack,
|
||||
)
|
||||
|
||||
appRouterConfig.routerScope = mainScope
|
||||
|
|
|
|||
|
|
@ -38,6 +38,6 @@ internal interface RoutingComponent : ComposableContentComponent {
|
|||
}
|
||||
|
||||
interface Factory {
|
||||
fun create(context: AppComponentContext): RoutingComponent
|
||||
fun create(context: AppComponentContext, initialStack: List<AppRoute>?): RoutingComponent
|
||||
}
|
||||
}
|
||||
|
|
@ -34,6 +34,7 @@ import dagger.assisted.AssistedInject
|
|||
@Suppress("LongParameterList")
|
||||
internal class DefaultRoutingComponent @AssistedInject constructor(
|
||||
@Assisted context: AppComponentContext,
|
||||
@Assisted val initialStack: List<AppRoute>?,
|
||||
private val childFactory: ChildFactory,
|
||||
private val appRouterConfig: AppRouterConfig,
|
||||
private val uiDependencies: UiDependencies,
|
||||
|
|
@ -46,8 +47,8 @@ internal class DefaultRoutingComponent @AssistedInject constructor(
|
|||
|
||||
override val stack: Value<ChildStack<AppRoute, Child>> = childStack(
|
||||
source = navigationProvider.getOrCreateTyped(),
|
||||
serializer = AppRoute.serializer(),
|
||||
initialConfiguration = getInitialRoute(),
|
||||
initialStack = { getInitialStackOrInit() },
|
||||
serializer = null, // AppRoute.serializer(), // Disabled until Nav refactoring completes
|
||||
handleBackButton = false,
|
||||
childFactory = ::child,
|
||||
)
|
||||
|
|
@ -115,7 +116,11 @@ internal class DefaultRoutingComponent @AssistedInject constructor(
|
|||
}
|
||||
|
||||
// TODO: Find correct initial route here: [REDACTED_JIRA]
|
||||
private fun getInitialRoute(): AppRoute = AppRoute.Initial
|
||||
private fun getInitialStackOrInit(): List<AppRoute> = if (initialStack.isNullOrEmpty()) {
|
||||
listOf(AppRoute.Initial)
|
||||
} else {
|
||||
initialStack
|
||||
}
|
||||
|
||||
private fun child(route: AppRoute, context: ComponentContext): Child {
|
||||
return childFactory.createChild(route) { childByContext(context) }
|
||||
|
|
@ -123,6 +128,6 @@ internal class DefaultRoutingComponent @AssistedInject constructor(
|
|||
|
||||
@AssistedFactory
|
||||
interface Factory : RoutingComponent.Factory {
|
||||
override fun create(context: AppComponentContext): DefaultRoutingComponent
|
||||
override fun create(context: AppComponentContext, initialStack: List<AppRoute>?): DefaultRoutingComponent
|
||||
}
|
||||
}
|
||||
|
|
@ -49,6 +49,7 @@ dependencies {
|
|||
implementation(deps.moshi)
|
||||
implementation(deps.moshi.kotlin)
|
||||
implementation(deps.timber)
|
||||
implementation(deps.firebase.crashlytics)
|
||||
ksp(deps.moshi.kotlin.codegen)
|
||||
kaptForObfuscatingVariants(deps.retrofit.response.type.keeper)
|
||||
|
||||
|
|
|
|||
|
|
@ -2,6 +2,7 @@ package com.tangem.data.staking
|
|||
|
||||
import android.util.Base64
|
||||
import arrow.core.getOrElse
|
||||
import com.google.firebase.crashlytics.FirebaseCrashlytics
|
||||
import com.squareup.moshi.Moshi
|
||||
import com.tangem.blockchain.common.Amount
|
||||
import com.tangem.blockchain.common.Blockchain
|
||||
|
|
@ -375,7 +376,8 @@ internal class DefaultStakingRepository(
|
|||
if (it != null) {
|
||||
send(it)
|
||||
} else {
|
||||
error("No yield balance available for currency ${cryptoCurrency.id.value}")
|
||||
FirebaseCrashlytics.getInstance()
|
||||
.log("No yield balance available for currency ${cryptoCurrency.id.value}")
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -230,12 +230,24 @@ internal enum class Wallet2CobrandImage(
|
|||
batchIds = setOf("BB000010"),
|
||||
),
|
||||
|
||||
SpringBloom(
|
||||
cards2ResId = R.drawable.ill_spring_bloom_card2_120_106,
|
||||
cards3ResId = R.drawable.ill_spring_bloom_card3_120_106,
|
||||
batchIds = setOf("AF990001", "AF990002", "AF990004"),
|
||||
),
|
||||
|
||||
StealthCard(
|
||||
cards2ResId = R.drawable.ill_stealth_cards2_120_106,
|
||||
cards3ResId = R.drawable.ill_stealth_cards3_120_106,
|
||||
batchIds = setOf("AF60", "AF74", "AF88"),
|
||||
),
|
||||
|
||||
SunDrop(
|
||||
cards2ResId = R.drawable.ill_sundrop_cards2_120_106,
|
||||
cards3ResId = R.drawable.ill_sundrop_cards3_120_106,
|
||||
batchIds = setOf("AF990005", "AF990003"),
|
||||
),
|
||||
|
||||
Trillant(
|
||||
cards2ResId = R.drawable.ill_trillant_card2_120_106,
|
||||
cards3ResId = R.drawable.ill_trillant_card3_120_106,
|
||||
|
|
|
|||
Binary file not shown.
|
After Width: | Height: | Size: 11 KiB |
Binary file not shown.
|
After Width: | Height: | Size: 13 KiB |
Binary file not shown.
|
After Width: | Height: | Size: 8.3 KiB |
Binary file not shown.
|
After Width: | Height: | Size: 11 KiB |
|
|
@ -1,5 +1,5 @@
|
|||
[versions]
|
||||
tangemBlockchainSdk = "develop-973"
|
||||
tangemBlockchainSdk = "develop-974"
|
||||
#tangemBlockchainSdk = "0.0.1" # Keep it! - used for local builds
|
||||
tangemCardSdk = "develop-437"
|
||||
#tangemCardSdk = "0.0.1" # Keep it! - used for local builds ^
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue