Updated on 2026-08-14
This commit is contained in:
parent
b96d11cea7
commit
cdce065712
51 changed files with 135 additions and 96 deletions
3
.gitignore
vendored
3
.gitignore
vendored
|
|
@ -33,3 +33,6 @@ local.properties
|
||||||
**/fastlane/Preview.html
|
**/fastlane/Preview.html
|
||||||
**/fastlane/screenshots
|
**/fastlane/screenshots
|
||||||
**/fastlane/test_output
|
**/fastlane/test_output
|
||||||
|
|
||||||
|
# Kotlin Plugin
|
||||||
|
.kotlin/
|
||||||
|
|
|
||||||
|
|
@ -10,6 +10,7 @@ plugins {
|
||||||
alias(deps.plugins.hilt.android)
|
alias(deps.plugins.hilt.android)
|
||||||
alias(deps.plugins.firebase.crashlytics)
|
alias(deps.plugins.firebase.crashlytics)
|
||||||
alias(deps.plugins.firebase.perf)
|
alias(deps.plugins.firebase.perf)
|
||||||
|
alias(deps.plugins.ksp)
|
||||||
id("configuration")
|
id("configuration")
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -30,6 +31,7 @@ android {
|
||||||
resources.excludes.add("META-INF/FastDoubleParser-LICENSE")
|
resources.excludes.add("META-INF/FastDoubleParser-LICENSE")
|
||||||
resources.excludes.add("META-INF/io.netty.versions.properties")
|
resources.excludes.add("META-INF/io.netty.versions.properties")
|
||||||
resources.excludes.add("META-INF/INDEX.LIST")
|
resources.excludes.add("META-INF/INDEX.LIST")
|
||||||
|
resources.excludes.add("META-INF/versions/9/OSGI-INF/MANIFEST.MF")
|
||||||
}
|
}
|
||||||
androidResources {
|
androidResources {
|
||||||
generateLocaleConfig = true
|
generateLocaleConfig = true
|
||||||
|
|
@ -268,7 +270,7 @@ dependencies {
|
||||||
implementation(deps.moshi.adapters)
|
implementation(deps.moshi.adapters)
|
||||||
|
|
||||||
implementation(deps.moshi.kotlin)
|
implementation(deps.moshi.kotlin)
|
||||||
kaptForObfuscatingVariants(deps.moshi.kotlin.codegen)
|
ksp(deps.moshi.kotlin.codegen)
|
||||||
kaptForObfuscatingVariants(deps.retrofit.response.type.keeper)
|
kaptForObfuscatingVariants(deps.retrofit.response.type.keeper)
|
||||||
|
|
||||||
/** Testing libraries */
|
/** Testing libraries */
|
||||||
|
|
|
||||||
|
|
@ -28,7 +28,7 @@ import androidx.lifecycle.flowWithLifecycle
|
||||||
import androidx.lifecycle.lifecycleScope
|
import androidx.lifecycle.lifecycleScope
|
||||||
import arrow.core.getOrElse
|
import arrow.core.getOrElse
|
||||||
import by.kirich1409.viewbindingdelegate.viewBinding
|
import by.kirich1409.viewbindingdelegate.viewBinding
|
||||||
import com.arkivanov.decompose.value.observe
|
import com.arkivanov.decompose.value.subscribe
|
||||||
import com.arkivanov.essenty.lifecycle.asEssentyLifecycle
|
import com.arkivanov.essenty.lifecycle.asEssentyLifecycle
|
||||||
import com.google.android.material.snackbar.BaseTransientBottomBar
|
import com.google.android.material.snackbar.BaseTransientBottomBar
|
||||||
import com.google.android.material.snackbar.Snackbar
|
import com.google.android.material.snackbar.Snackbar
|
||||||
|
|
@ -316,12 +316,12 @@ class MainActivity : AppCompatActivity(), SnackbarHandler, ActivityResultCallbac
|
||||||
appRouterConfig.componentRouter = routingComponent.router
|
appRouterConfig.componentRouter = routingComponent.router
|
||||||
appRouterConfig.snackbarHandler = this
|
appRouterConfig.snackbarHandler = this
|
||||||
|
|
||||||
routingComponent.stack.observe(lifecycle.asEssentyLifecycle()) { childStack ->
|
routingComponent.stack.subscribe(lifecycle.asEssentyLifecycle()) { childStack ->
|
||||||
val stack = childStack.backStack
|
val stack = childStack.backStack
|
||||||
.plus(childStack.active)
|
.plus(childStack.active)
|
||||||
.map { it.configuration }
|
.map { it.configuration }
|
||||||
|
|
||||||
if (stack == appRouterConfig.stack) return@observe
|
if (stack == appRouterConfig.stack) return@subscribe
|
||||||
|
|
||||||
appRouterConfig.stack = stack
|
appRouterConfig.stack = stack
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -10,7 +10,7 @@ import androidx.compose.ui.Modifier
|
||||||
import androidx.compose.ui.platform.LocalContext
|
import androidx.compose.ui.platform.LocalContext
|
||||||
import androidx.compose.ui.unit.dp
|
import androidx.compose.ui.unit.dp
|
||||||
import androidx.core.content.ContextCompat.startActivity
|
import androidx.core.content.ContextCompat.startActivity
|
||||||
import com.arkivanov.decompose.extensions.compose.jetpack.stack.Children
|
import com.arkivanov.decompose.extensions.compose.stack.Children
|
||||||
import com.arkivanov.decompose.router.stack.ChildStack
|
import com.arkivanov.decompose.router.stack.ChildStack
|
||||||
import com.tangem.common.routing.AppRoute
|
import com.tangem.common.routing.AppRoute
|
||||||
import com.tangem.core.ui.UiDependencies
|
import com.tangem.core.ui.UiDependencies
|
||||||
|
|
|
||||||
|
|
@ -4,11 +4,11 @@ import androidx.compose.runtime.Composable
|
||||||
import androidx.compose.runtime.getValue
|
import androidx.compose.runtime.getValue
|
||||||
import androidx.compose.ui.Modifier
|
import androidx.compose.ui.Modifier
|
||||||
import com.arkivanov.decompose.ComponentContext
|
import com.arkivanov.decompose.ComponentContext
|
||||||
import com.arkivanov.decompose.extensions.compose.jetpack.subscribeAsState
|
import com.arkivanov.decompose.extensions.compose.subscribeAsState
|
||||||
import com.arkivanov.decompose.router.stack.ChildStack
|
import com.arkivanov.decompose.router.stack.ChildStack
|
||||||
import com.arkivanov.decompose.router.stack.childStack
|
import com.arkivanov.decompose.router.stack.childStack
|
||||||
import com.arkivanov.decompose.value.Value
|
import com.arkivanov.decompose.value.Value
|
||||||
import com.arkivanov.decompose.value.observe
|
import com.arkivanov.decompose.value.subscribe
|
||||||
import com.arkivanov.essenty.backhandler.BackCallback
|
import com.arkivanov.essenty.backhandler.BackCallback
|
||||||
import com.arkivanov.essenty.lifecycle.doOnDestroy
|
import com.arkivanov.essenty.lifecycle.doOnDestroy
|
||||||
import com.google.android.material.snackbar.Snackbar
|
import com.google.android.material.snackbar.Snackbar
|
||||||
|
|
@ -64,7 +64,7 @@ internal class DefaultRoutingComponent @AssistedInject constructor(
|
||||||
appRouterConfig.componentRouter = router
|
appRouterConfig.componentRouter = router
|
||||||
appRouterConfig.snackbarHandler = this
|
appRouterConfig.snackbarHandler = this
|
||||||
|
|
||||||
stack.observe(lifecycle) { stack ->
|
stack.subscribe(lifecycle) { stack ->
|
||||||
val stackItems = stack.items.map { it.configuration }
|
val stackItems = stack.items.map { it.configuration }
|
||||||
|
|
||||||
if (appRouterConfig.stack != stackItems) {
|
if (appRouterConfig.stack != stackItems) {
|
||||||
|
|
|
||||||
|
|
@ -12,6 +12,8 @@ plugins {
|
||||||
alias(deps.plugins.firebase.crashlytics) apply false
|
alias(deps.plugins.firebase.crashlytics) apply false
|
||||||
alias(deps.plugins.firebase.perf) apply false
|
alias(deps.plugins.firebase.perf) apply false
|
||||||
alias(deps.plugins.room) apply false
|
alias(deps.plugins.room) apply false
|
||||||
|
alias(deps.plugins.kotlin.compose.compiler) apply false
|
||||||
|
alias(deps.plugins.ksp) apply false
|
||||||
}
|
}
|
||||||
|
|
||||||
val clean by tasks.registering {
|
val clean by tasks.registering {
|
||||||
|
|
|
||||||
|
|
@ -5,6 +5,7 @@ plugins {
|
||||||
alias(deps.plugins.kotlin.android)
|
alias(deps.plugins.kotlin.android)
|
||||||
alias(deps.plugins.kotlin.kapt)
|
alias(deps.plugins.kotlin.kapt)
|
||||||
alias(deps.plugins.hilt.android)
|
alias(deps.plugins.hilt.android)
|
||||||
|
alias(deps.plugins.ksp)
|
||||||
id("configuration")
|
id("configuration")
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -24,7 +25,7 @@ dependencies {
|
||||||
implementation(deps.moshi)
|
implementation(deps.moshi)
|
||||||
implementation(deps.moshi.kotlin)
|
implementation(deps.moshi.kotlin)
|
||||||
implementation(deps.timber)
|
implementation(deps.timber)
|
||||||
kaptForObfuscatingVariants(deps.moshi.kotlin.codegen)
|
ksp(deps.moshi.kotlin.codegen)
|
||||||
|
|
||||||
/** Core modules */
|
/** Core modules */
|
||||||
implementation(projects.core.datasource)
|
implementation(projects.core.datasource)
|
||||||
|
|
|
||||||
|
|
@ -6,6 +6,7 @@ plugins {
|
||||||
alias(deps.plugins.kotlin.kapt)
|
alias(deps.plugins.kotlin.kapt)
|
||||||
alias(deps.plugins.hilt.android)
|
alias(deps.plugins.hilt.android)
|
||||||
alias(deps.plugins.room)
|
alias(deps.plugins.room)
|
||||||
|
alias(deps.plugins.ksp)
|
||||||
id("configuration")
|
id("configuration")
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -57,7 +58,7 @@ dependencies {
|
||||||
implementation(deps.okHttp.prettyLogging)
|
implementation(deps.okHttp.prettyLogging)
|
||||||
implementation(deps.retrofit)
|
implementation(deps.retrofit)
|
||||||
implementation(deps.retrofit.moshi)
|
implementation(deps.retrofit.moshi)
|
||||||
kaptForObfuscatingVariants(deps.moshi.kotlin.codegen)
|
ksp(deps.moshi.kotlin.codegen)
|
||||||
kaptForObfuscatingVariants(deps.retrofit.response.type.keeper)
|
kaptForObfuscatingVariants(deps.retrofit.response.type.keeper)
|
||||||
|
|
||||||
/** Time */
|
/** Time */
|
||||||
|
|
@ -78,7 +79,7 @@ dependencies {
|
||||||
implementation(deps.androidx.datastore)
|
implementation(deps.androidx.datastore)
|
||||||
implementation(deps.room.runtime)
|
implementation(deps.room.runtime)
|
||||||
implementation(deps.room.ktx)
|
implementation(deps.room.ktx)
|
||||||
kapt(deps.room.compiler)
|
ksp(deps.room.compiler)
|
||||||
|
|
||||||
testImplementation(deps.test.coroutine)
|
testImplementation(deps.test.coroutine)
|
||||||
testImplementation(deps.test.junit)
|
testImplementation(deps.test.junit)
|
||||||
|
|
|
||||||
|
|
@ -4,6 +4,7 @@ plugins {
|
||||||
alias(deps.plugins.android.library)
|
alias(deps.plugins.android.library)
|
||||||
alias(deps.plugins.kotlin.android)
|
alias(deps.plugins.kotlin.android)
|
||||||
alias(deps.plugins.kotlin.kapt)
|
alias(deps.plugins.kotlin.kapt)
|
||||||
|
alias(deps.plugins.ksp)
|
||||||
id("configuration")
|
id("configuration")
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -46,6 +47,6 @@ dependencies {
|
||||||
/** Other */
|
/** Other */
|
||||||
implementation(deps.moshi.kotlin)
|
implementation(deps.moshi.kotlin)
|
||||||
implementation(deps.timber)
|
implementation(deps.timber)
|
||||||
kaptForObfuscatingVariants(deps.moshi.kotlin.codegen)
|
ksp(deps.moshi.kotlin.codegen)
|
||||||
kaptForObfuscatingVariants(deps.retrofit.response.type.keeper)
|
kaptForObfuscatingVariants(deps.retrofit.response.type.keeper)
|
||||||
}
|
}
|
||||||
|
|
@ -5,6 +5,7 @@ plugins {
|
||||||
alias(deps.plugins.kotlin.android)
|
alias(deps.plugins.kotlin.android)
|
||||||
alias(deps.plugins.kotlin.kapt)
|
alias(deps.plugins.kotlin.kapt)
|
||||||
alias(deps.plugins.hilt.android)
|
alias(deps.plugins.hilt.android)
|
||||||
|
alias(deps.plugins.ksp)
|
||||||
id("configuration")
|
id("configuration")
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -42,7 +43,7 @@ dependencies {
|
||||||
implementation(deps.moshi.kotlin)
|
implementation(deps.moshi.kotlin)
|
||||||
implementation(deps.timber)
|
implementation(deps.timber)
|
||||||
implementation(tangemDeps.blockchain)
|
implementation(tangemDeps.blockchain)
|
||||||
kaptForObfuscatingVariants(deps.moshi.kotlin.codegen)
|
ksp(deps.moshi.kotlin.codegen)
|
||||||
kaptForObfuscatingVariants(deps.retrofit.response.type.keeper)
|
kaptForObfuscatingVariants(deps.retrofit.response.type.keeper)
|
||||||
// endregion
|
// endregion
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -5,6 +5,7 @@ plugins {
|
||||||
alias(deps.plugins.kotlin.android)
|
alias(deps.plugins.kotlin.android)
|
||||||
alias(deps.plugins.kotlin.kapt)
|
alias(deps.plugins.kotlin.kapt)
|
||||||
alias(deps.plugins.hilt.android)
|
alias(deps.plugins.hilt.android)
|
||||||
|
alias(deps.plugins.ksp)
|
||||||
id("configuration")
|
id("configuration")
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -44,7 +45,7 @@ dependencies {
|
||||||
implementation(deps.moshi)
|
implementation(deps.moshi)
|
||||||
implementation(deps.moshi.kotlin)
|
implementation(deps.moshi.kotlin)
|
||||||
implementation(deps.timber)
|
implementation(deps.timber)
|
||||||
kaptForObfuscatingVariants(deps.moshi.kotlin.codegen)
|
ksp(deps.moshi.kotlin.codegen)
|
||||||
kaptForObfuscatingVariants(deps.retrofit.response.type.keeper)
|
kaptForObfuscatingVariants(deps.retrofit.response.type.keeper)
|
||||||
implementation(deps.kotlin.serialization)
|
implementation(deps.kotlin.serialization)
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -5,6 +5,7 @@ plugins {
|
||||||
alias(deps.plugins.kotlin.android)
|
alias(deps.plugins.kotlin.android)
|
||||||
alias(deps.plugins.kotlin.kapt)
|
alias(deps.plugins.kotlin.kapt)
|
||||||
alias(deps.plugins.hilt.android)
|
alias(deps.plugins.hilt.android)
|
||||||
|
alias(deps.plugins.ksp)
|
||||||
id("configuration")
|
id("configuration")
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -33,7 +34,7 @@ dependencies {
|
||||||
implementation(deps.moshi)
|
implementation(deps.moshi)
|
||||||
implementation(deps.moshi.kotlin)
|
implementation(deps.moshi.kotlin)
|
||||||
implementation(deps.timber)
|
implementation(deps.timber)
|
||||||
kaptForObfuscatingVariants(deps.moshi.kotlin.codegen)
|
ksp(deps.moshi.kotlin.codegen)
|
||||||
kaptForObfuscatingVariants(deps.retrofit.response.type.keeper)
|
kaptForObfuscatingVariants(deps.retrofit.response.type.keeper)
|
||||||
// endregion
|
// endregion
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -5,6 +5,7 @@ plugins {
|
||||||
alias(deps.plugins.kotlin.android)
|
alias(deps.plugins.kotlin.android)
|
||||||
alias(deps.plugins.kotlin.kapt)
|
alias(deps.plugins.kotlin.kapt)
|
||||||
alias(deps.plugins.hilt.android)
|
alias(deps.plugins.hilt.android)
|
||||||
|
alias(deps.plugins.ksp)
|
||||||
id("configuration")
|
id("configuration")
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -48,7 +49,7 @@ dependencies {
|
||||||
implementation(deps.moshi)
|
implementation(deps.moshi)
|
||||||
implementation(deps.moshi.kotlin)
|
implementation(deps.moshi.kotlin)
|
||||||
implementation(deps.timber)
|
implementation(deps.timber)
|
||||||
kaptForObfuscatingVariants(deps.moshi.kotlin.codegen)
|
ksp(deps.moshi.kotlin.codegen)
|
||||||
kaptForObfuscatingVariants(deps.retrofit.response.type.keeper)
|
kaptForObfuscatingVariants(deps.retrofit.response.type.keeper)
|
||||||
|
|
||||||
implementation(projects.libs.blockchainSdk)
|
implementation(projects.libs.blockchainSdk)
|
||||||
|
|
|
||||||
|
|
@ -4,6 +4,7 @@ plugins {
|
||||||
alias(deps.plugins.android.library)
|
alias(deps.plugins.android.library)
|
||||||
alias(deps.plugins.kotlin.android)
|
alias(deps.plugins.kotlin.android)
|
||||||
alias(deps.plugins.kotlin.kapt)
|
alias(deps.plugins.kotlin.kapt)
|
||||||
|
alias(deps.plugins.ksp)
|
||||||
id("configuration")
|
id("configuration")
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -50,6 +51,6 @@ dependencies {
|
||||||
implementation(deps.timber)
|
implementation(deps.timber)
|
||||||
implementation(deps.retrofit) // For HttpException
|
implementation(deps.retrofit) // For HttpException
|
||||||
implementation(deps.androidx.paging.runtime)
|
implementation(deps.androidx.paging.runtime)
|
||||||
kaptForObfuscatingVariants(deps.moshi.kotlin.codegen)
|
ksp(deps.moshi.kotlin.codegen)
|
||||||
kaptForObfuscatingVariants(deps.retrofit.response.type.keeper)
|
kaptForObfuscatingVariants(deps.retrofit.response.type.keeper)
|
||||||
}
|
}
|
||||||
|
|
@ -4,6 +4,7 @@ plugins {
|
||||||
alias(deps.plugins.android.library)
|
alias(deps.plugins.android.library)
|
||||||
alias(deps.plugins.kotlin.android)
|
alias(deps.plugins.kotlin.android)
|
||||||
alias(deps.plugins.kotlin.kapt)
|
alias(deps.plugins.kotlin.kapt)
|
||||||
|
alias(deps.plugins.ksp)
|
||||||
id("configuration")
|
id("configuration")
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -39,7 +40,7 @@ dependencies {
|
||||||
implementation(deps.timber)
|
implementation(deps.timber)
|
||||||
implementation(deps.androidx.paging.runtime)
|
implementation(deps.androidx.paging.runtime)
|
||||||
implementation(deps.moshi.kotlin)
|
implementation(deps.moshi.kotlin)
|
||||||
kaptForObfuscatingVariants(deps.moshi.kotlin.codegen)
|
ksp(deps.moshi.kotlin.codegen)
|
||||||
kaptForObfuscatingVariants(deps.retrofit.response.type.keeper)
|
kaptForObfuscatingVariants(deps.retrofit.response.type.keeper)
|
||||||
|
|
||||||
/** Libs - Tangem */
|
/** Libs - Tangem */
|
||||||
|
|
|
||||||
|
|
@ -1,6 +1,7 @@
|
||||||
plugins {
|
plugins {
|
||||||
alias(deps.plugins.kotlin.jvm)
|
alias(deps.plugins.kotlin.jvm)
|
||||||
alias(deps.plugins.kotlin.kapt)
|
alias(deps.plugins.kotlin.kapt)
|
||||||
|
alias(deps.plugins.ksp)
|
||||||
id("configuration")
|
id("configuration")
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -11,5 +12,7 @@ dependencies {
|
||||||
implementation(projects.domain.core)
|
implementation(projects.domain.core)
|
||||||
implementation(projects.domain.wallets.models)
|
implementation(projects.domain.wallets.models)
|
||||||
implementation(deps.moshi.kotlin)
|
implementation(deps.moshi.kotlin)
|
||||||
kapt(deps.moshi.kotlin.codegen)
|
implementation(deps.arrow.core)
|
||||||
|
implementation(deps.arrow.fx)
|
||||||
|
ksp(deps.moshi.kotlin.codegen)
|
||||||
}
|
}
|
||||||
|
|
@ -1,9 +1,7 @@
|
||||||
import com.tangem.plugin.configuration.configurations.extension.kaptForObfuscatingVariants
|
|
||||||
|
|
||||||
plugins {
|
plugins {
|
||||||
alias(deps.plugins.android.library)
|
alias(deps.plugins.android.library)
|
||||||
alias(deps.plugins.kotlin.android)
|
alias(deps.plugins.kotlin.android)
|
||||||
alias(deps.plugins.kotlin.kapt)
|
alias(deps.plugins.ksp)
|
||||||
id("configuration")
|
id("configuration")
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -41,7 +39,7 @@ dependencies {
|
||||||
implementation(deps.moshi.kotlin)
|
implementation(deps.moshi.kotlin)
|
||||||
implementation(deps.reKotlin)
|
implementation(deps.reKotlin)
|
||||||
implementation(deps.timber)
|
implementation(deps.timber)
|
||||||
kaptForObfuscatingVariants(deps.moshi.kotlin.codegen)
|
ksp(deps.moshi.kotlin.codegen)
|
||||||
|
|
||||||
/** Testing libraries */
|
/** Testing libraries */
|
||||||
testImplementation(deps.test.junit)
|
testImplementation(deps.test.junit)
|
||||||
|
|
|
||||||
|
|
@ -3,7 +3,7 @@ import com.tangem.plugin.configuration.configurations.extension.kaptForObfuscati
|
||||||
plugins {
|
plugins {
|
||||||
alias(deps.plugins.kotlin.jvm)
|
alias(deps.plugins.kotlin.jvm)
|
||||||
alias(deps.plugins.kotlin.serialization)
|
alias(deps.plugins.kotlin.serialization)
|
||||||
alias(deps.plugins.kotlin.kapt)
|
alias(deps.plugins.ksp)
|
||||||
id("configuration")
|
id("configuration")
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -14,5 +14,5 @@ dependencies {
|
||||||
implementation(deps.moshi.kotlin)
|
implementation(deps.moshi.kotlin)
|
||||||
implementation(deps.moshi.adapters)
|
implementation(deps.moshi.adapters)
|
||||||
implementation(deps.kotlin.serialization)
|
implementation(deps.kotlin.serialization)
|
||||||
kapt(deps.moshi.kotlin.codegen)
|
ksp(deps.moshi.kotlin.codegen)
|
||||||
}
|
}
|
||||||
|
|
@ -1,7 +1,7 @@
|
||||||
plugins {
|
plugins {
|
||||||
alias(deps.plugins.kotlin.jvm)
|
alias(deps.plugins.kotlin.jvm)
|
||||||
alias(deps.plugins.kotlin.serialization)
|
alias(deps.plugins.kotlin.serialization)
|
||||||
alias(deps.plugins.kotlin.kapt)
|
alias(deps.plugins.ksp)
|
||||||
id("configuration")
|
id("configuration")
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -11,7 +11,7 @@ dependencies {
|
||||||
implementation(projects.domain.wallets.models)
|
implementation(projects.domain.wallets.models)
|
||||||
|
|
||||||
implementation(deps.moshi.kotlin)
|
implementation(deps.moshi.kotlin)
|
||||||
kapt(deps.moshi.kotlin.codegen)
|
ksp(deps.moshi.kotlin.codegen)
|
||||||
implementation(deps.kotlin.serialization)
|
implementation(deps.kotlin.serialization)
|
||||||
implementation(deps.jodatime)
|
implementation(deps.jodatime)
|
||||||
}
|
}
|
||||||
|
|
@ -3,7 +3,7 @@ import com.tangem.plugin.configuration.configurations.extension.kaptForObfuscati
|
||||||
plugins {
|
plugins {
|
||||||
alias(deps.plugins.kotlin.jvm)
|
alias(deps.plugins.kotlin.jvm)
|
||||||
alias(deps.plugins.kotlin.serialization)
|
alias(deps.plugins.kotlin.serialization)
|
||||||
alias(deps.plugins.kotlin.kapt)
|
alias(deps.plugins.ksp)
|
||||||
id("configuration")
|
id("configuration")
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -15,5 +15,5 @@ dependencies {
|
||||||
implementation(deps.jodatime)
|
implementation(deps.jodatime)
|
||||||
|
|
||||||
implementation(deps.moshi)
|
implementation(deps.moshi)
|
||||||
kaptForObfuscatingVariants(deps.moshi.kotlin.codegen)
|
ksp(deps.moshi.kotlin.codegen)
|
||||||
}
|
}
|
||||||
|
|
@ -1,6 +1,7 @@
|
||||||
plugins {
|
plugins {
|
||||||
alias(deps.plugins.android.library)
|
alias(deps.plugins.android.library)
|
||||||
alias(deps.plugins.kotlin.android)
|
alias(deps.plugins.kotlin.android)
|
||||||
|
alias(deps.plugins.ksp)
|
||||||
id("configuration")
|
id("configuration")
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -24,4 +25,5 @@ dependencies {
|
||||||
implementation(deps.androidx.paging.runtime)
|
implementation(deps.androidx.paging.runtime)
|
||||||
implementation(deps.moshi)
|
implementation(deps.moshi)
|
||||||
implementation(deps.moshi.kotlin)
|
implementation(deps.moshi.kotlin)
|
||||||
|
ksp(deps.moshi.kotlin.codegen)
|
||||||
}
|
}
|
||||||
|
|
@ -1,11 +1,13 @@
|
||||||
plugins {
|
plugins {
|
||||||
alias(deps.plugins.kotlin.jvm)
|
alias(deps.plugins.kotlin.jvm)
|
||||||
alias(deps.plugins.kotlin.serialization)
|
alias(deps.plugins.kotlin.serialization)
|
||||||
|
alias(deps.plugins.ksp)
|
||||||
id("configuration")
|
id("configuration")
|
||||||
}
|
}
|
||||||
|
|
||||||
dependencies {
|
dependencies {
|
||||||
implementation(deps.moshi.kotlin)
|
implementation(deps.moshi.kotlin)
|
||||||
|
ksp(deps.moshi.kotlin.codegen)
|
||||||
implementation(deps.moshi.adapters)
|
implementation(deps.moshi.adapters)
|
||||||
implementation(deps.kotlin.serialization)
|
implementation(deps.kotlin.serialization)
|
||||||
}
|
}
|
||||||
|
|
@ -1,7 +1,7 @@
|
||||||
plugins {
|
plugins {
|
||||||
alias(deps.plugins.kotlin.jvm)
|
alias(deps.plugins.kotlin.jvm)
|
||||||
alias(deps.plugins.kotlin.serialization)
|
alias(deps.plugins.kotlin.serialization)
|
||||||
alias(deps.plugins.kotlin.kapt)
|
alias(deps.plugins.ksp)
|
||||||
id("configuration")
|
id("configuration")
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -18,6 +18,6 @@ dependencies {
|
||||||
implementation(deps.kotlin.serialization)
|
implementation(deps.kotlin.serialization)
|
||||||
implementation(deps.moshi.kotlin)
|
implementation(deps.moshi.kotlin)
|
||||||
implementation(deps.timber)
|
implementation(deps.timber)
|
||||||
kapt(deps.moshi.kotlin.codegen)
|
ksp(deps.moshi.kotlin.codegen)
|
||||||
// endregion
|
// endregion
|
||||||
}
|
}
|
||||||
|
|
@ -70,4 +70,6 @@ dependencies {
|
||||||
implementation(deps.kotlin.immutable.collections)
|
implementation(deps.kotlin.immutable.collections)
|
||||||
implementation(deps.reKotlin)
|
implementation(deps.reKotlin)
|
||||||
implementation(deps.timber)
|
implementation(deps.timber)
|
||||||
|
implementation(deps.arrow.core)
|
||||||
|
implementation(deps.arrow.fx)
|
||||||
}
|
}
|
||||||
|
|
@ -4,9 +4,9 @@ import androidx.compose.runtime.Composable
|
||||||
import androidx.compose.runtime.getValue
|
import androidx.compose.runtime.getValue
|
||||||
import androidx.compose.runtime.remember
|
import androidx.compose.runtime.remember
|
||||||
import com.arkivanov.decompose.ComponentContext
|
import com.arkivanov.decompose.ComponentContext
|
||||||
import com.arkivanov.decompose.extensions.compose.jetpack.stack.Children
|
import com.arkivanov.decompose.extensions.compose.stack.Children
|
||||||
import com.arkivanov.decompose.extensions.compose.jetpack.stack.animation.stackAnimation
|
import com.arkivanov.decompose.extensions.compose.stack.animation.stackAnimation
|
||||||
import com.arkivanov.decompose.extensions.compose.jetpack.subscribeAsState
|
import com.arkivanov.decompose.extensions.compose.subscribeAsState
|
||||||
import com.arkivanov.decompose.router.stack.*
|
import com.arkivanov.decompose.router.stack.*
|
||||||
import com.tangem.core.analytics.api.AnalyticsEventHandler
|
import com.tangem.core.analytics.api.AnalyticsEventHandler
|
||||||
import com.tangem.core.decompose.context.AppComponentContext
|
import com.tangem.core.decompose.context.AppComponentContext
|
||||||
|
|
|
||||||
|
|
@ -5,7 +5,7 @@ import androidx.compose.runtime.getValue
|
||||||
import androidx.compose.ui.Modifier
|
import androidx.compose.ui.Modifier
|
||||||
import androidx.lifecycle.compose.collectAsStateWithLifecycle
|
import androidx.lifecycle.compose.collectAsStateWithLifecycle
|
||||||
import com.arkivanov.decompose.ComponentContext
|
import com.arkivanov.decompose.ComponentContext
|
||||||
import com.arkivanov.decompose.extensions.compose.jetpack.subscribeAsState
|
import com.arkivanov.decompose.extensions.compose.subscribeAsState
|
||||||
import com.arkivanov.decompose.router.slot.childSlot
|
import com.arkivanov.decompose.router.slot.childSlot
|
||||||
import com.arkivanov.decompose.router.slot.dismiss
|
import com.arkivanov.decompose.router.slot.dismiss
|
||||||
import com.tangem.core.decompose.context.AppComponentContext
|
import com.tangem.core.decompose.context.AppComponentContext
|
||||||
|
|
|
||||||
|
|
@ -6,7 +6,7 @@ import androidx.compose.runtime.getValue
|
||||||
import androidx.compose.ui.Modifier
|
import androidx.compose.ui.Modifier
|
||||||
import androidx.lifecycle.compose.collectAsStateWithLifecycle
|
import androidx.lifecycle.compose.collectAsStateWithLifecycle
|
||||||
import com.arkivanov.decompose.ComponentContext
|
import com.arkivanov.decompose.ComponentContext
|
||||||
import com.arkivanov.decompose.extensions.compose.jetpack.subscribeAsState
|
import com.arkivanov.decompose.extensions.compose.subscribeAsState
|
||||||
import com.arkivanov.decompose.router.slot.childSlot
|
import com.arkivanov.decompose.router.slot.childSlot
|
||||||
import com.arkivanov.decompose.router.slot.dismiss
|
import com.arkivanov.decompose.router.slot.dismiss
|
||||||
import com.tangem.core.decompose.context.AppComponentContext
|
import com.tangem.core.decompose.context.AppComponentContext
|
||||||
|
|
|
||||||
|
|
@ -6,7 +6,7 @@ import androidx.compose.runtime.State
|
||||||
import androidx.compose.ui.Modifier
|
import androidx.compose.ui.Modifier
|
||||||
import androidx.compose.ui.unit.Dp
|
import androidx.compose.ui.unit.Dp
|
||||||
import com.arkivanov.decompose.ExperimentalDecomposeApi
|
import com.arkivanov.decompose.ExperimentalDecomposeApi
|
||||||
import com.arkivanov.decompose.extensions.compose.jetpack.subscribeAsState
|
import com.arkivanov.decompose.extensions.compose.subscribeAsState
|
||||||
import com.arkivanov.decompose.router.stack.ChildStack
|
import com.arkivanov.decompose.router.stack.ChildStack
|
||||||
import com.arkivanov.decompose.router.stack.StackNavigation
|
import com.arkivanov.decompose.router.stack.StackNavigation
|
||||||
import com.arkivanov.decompose.router.stack.childStack
|
import com.arkivanov.decompose.router.stack.childStack
|
||||||
|
|
|
||||||
|
|
@ -11,9 +11,9 @@ import androidx.compose.runtime.remember
|
||||||
import androidx.compose.ui.Modifier
|
import androidx.compose.ui.Modifier
|
||||||
import androidx.compose.ui.graphics.Color
|
import androidx.compose.ui.graphics.Color
|
||||||
import androidx.compose.ui.unit.Dp
|
import androidx.compose.ui.unit.Dp
|
||||||
import com.arkivanov.decompose.extensions.compose.jetpack.stack.Children
|
import com.arkivanov.decompose.extensions.compose.stack.Children
|
||||||
import com.arkivanov.decompose.extensions.compose.jetpack.stack.animation.slide
|
import com.arkivanov.decompose.extensions.compose.stack.animation.slide
|
||||||
import com.arkivanov.decompose.extensions.compose.jetpack.stack.animation.stackAnimation
|
import com.arkivanov.decompose.extensions.compose.stack.animation.stackAnimation
|
||||||
import com.arkivanov.decompose.router.stack.ChildStack
|
import com.arkivanov.decompose.router.stack.ChildStack
|
||||||
import com.tangem.core.ui.res.LocalMainBottomSheetColor
|
import com.tangem.core.ui.res.LocalMainBottomSheetColor
|
||||||
import com.tangem.core.ui.res.TangemTheme
|
import com.tangem.core.ui.res.TangemTheme
|
||||||
|
|
|
||||||
|
|
@ -4,9 +4,11 @@ import androidx.activity.compose.BackHandler
|
||||||
import androidx.compose.runtime.Composable
|
import androidx.compose.runtime.Composable
|
||||||
import androidx.compose.runtime.getValue
|
import androidx.compose.runtime.getValue
|
||||||
import androidx.compose.ui.Modifier
|
import androidx.compose.ui.Modifier
|
||||||
import com.arkivanov.decompose.extensions.compose.jetpack.subscribeAsState
|
import com.arkivanov.decompose.extensions.compose.subscribeAsState
|
||||||
import com.arkivanov.decompose.router.stack.*
|
import com.arkivanov.decompose.router.stack.*
|
||||||
|
import com.arkivanov.decompose.value.ObserveLifecycleMode
|
||||||
import com.arkivanov.decompose.value.Value
|
import com.arkivanov.decompose.value.Value
|
||||||
|
import com.arkivanov.decompose.value.subscribe
|
||||||
import com.tangem.core.decompose.context.AppComponentContext
|
import com.tangem.core.decompose.context.AppComponentContext
|
||||||
import com.tangem.core.decompose.context.child
|
import com.tangem.core.decompose.context.child
|
||||||
import com.tangem.core.decompose.context.childByContext
|
import com.tangem.core.decompose.context.childByContext
|
||||||
|
|
@ -87,7 +89,10 @@ internal class DefaultOnboardingEntryComponent @AssistedInject constructor(
|
||||||
@Suppress("MagicNumber")
|
@Suppress("MagicNumber")
|
||||||
private fun linkToInnerNavigation() {
|
private fun linkToInnerNavigation() {
|
||||||
// stepper linking
|
// stepper linking
|
||||||
innerStack.observe { stack ->
|
innerStack.subscribe(
|
||||||
|
lifecycle = lifecycle,
|
||||||
|
mode = ObserveLifecycleMode.CREATE_DESTROY,
|
||||||
|
) { stack ->
|
||||||
val activeChild = stack.active.instance
|
val activeChild = stack.active.instance
|
||||||
if (activeChild is InnerNavigationHolder) {
|
if (activeChild is InnerNavigationHolder) {
|
||||||
componentScope.launch {
|
componentScope.launch {
|
||||||
|
|
|
||||||
|
|
@ -4,9 +4,9 @@ import androidx.compose.foundation.background
|
||||||
import androidx.compose.foundation.layout.*
|
import androidx.compose.foundation.layout.*
|
||||||
import androidx.compose.runtime.Composable
|
import androidx.compose.runtime.Composable
|
||||||
import androidx.compose.ui.Modifier
|
import androidx.compose.ui.Modifier
|
||||||
import com.arkivanov.decompose.extensions.compose.jetpack.stack.Children
|
import com.arkivanov.decompose.extensions.compose.stack.Children
|
||||||
import com.arkivanov.decompose.extensions.compose.jetpack.stack.animation.slide
|
import com.arkivanov.decompose.extensions.compose.stack.animation.slide
|
||||||
import com.arkivanov.decompose.extensions.compose.jetpack.stack.animation.stackAnimation
|
import com.arkivanov.decompose.extensions.compose.stack.animation.stackAnimation
|
||||||
import com.arkivanov.decompose.router.stack.ChildStack
|
import com.arkivanov.decompose.router.stack.ChildStack
|
||||||
import com.tangem.core.ui.decompose.ComposableContentComponent
|
import com.tangem.core.ui.decompose.ComposableContentComponent
|
||||||
import com.tangem.core.ui.res.TangemTheme
|
import com.tangem.core.ui.res.TangemTheme
|
||||||
|
|
|
||||||
|
|
@ -6,11 +6,11 @@ import androidx.compose.runtime.getValue
|
||||||
import androidx.compose.ui.Modifier
|
import androidx.compose.ui.Modifier
|
||||||
import androidx.lifecycle.compose.collectAsStateWithLifecycle
|
import androidx.lifecycle.compose.collectAsStateWithLifecycle
|
||||||
import com.arkivanov.decompose.FaultyDecomposeApi
|
import com.arkivanov.decompose.FaultyDecomposeApi
|
||||||
import com.arkivanov.decompose.extensions.compose.jetpack.stack.Children
|
import com.arkivanov.decompose.extensions.compose.stack.Children
|
||||||
import com.arkivanov.decompose.extensions.compose.jetpack.stack.animation.fade
|
import com.arkivanov.decompose.extensions.compose.stack.animation.fade
|
||||||
import com.arkivanov.decompose.extensions.compose.jetpack.stack.animation.slide
|
import com.arkivanov.decompose.extensions.compose.stack.animation.slide
|
||||||
import com.arkivanov.decompose.extensions.compose.jetpack.stack.animation.stackAnimation
|
import com.arkivanov.decompose.extensions.compose.stack.animation.stackAnimation
|
||||||
import com.arkivanov.decompose.extensions.compose.jetpack.subscribeAsState
|
import com.arkivanov.decompose.extensions.compose.subscribeAsState
|
||||||
import com.arkivanov.decompose.router.slot.SlotNavigation
|
import com.arkivanov.decompose.router.slot.SlotNavigation
|
||||||
import com.arkivanov.decompose.router.slot.childSlot
|
import com.arkivanov.decompose.router.slot.childSlot
|
||||||
import com.arkivanov.decompose.router.slot.dismiss
|
import com.arkivanov.decompose.router.slot.dismiss
|
||||||
|
|
|
||||||
|
|
@ -3,13 +3,13 @@ package com.tangem.features.onboarding.v2.visa.impl
|
||||||
import androidx.compose.runtime.Composable
|
import androidx.compose.runtime.Composable
|
||||||
import androidx.compose.runtime.getValue
|
import androidx.compose.runtime.getValue
|
||||||
import androidx.compose.ui.Modifier
|
import androidx.compose.ui.Modifier
|
||||||
import com.arkivanov.decompose.extensions.compose.jetpack.stack.Children
|
import com.arkivanov.decompose.extensions.compose.stack.Children
|
||||||
import com.arkivanov.decompose.extensions.compose.jetpack.stack.animation.slide
|
import com.arkivanov.decompose.extensions.compose.stack.animation.slide
|
||||||
import com.arkivanov.decompose.extensions.compose.jetpack.stack.animation.stackAnimation
|
import com.arkivanov.decompose.extensions.compose.stack.animation.stackAnimation
|
||||||
import com.arkivanov.decompose.extensions.compose.jetpack.subscribeAsState
|
import com.arkivanov.decompose.extensions.compose.subscribeAsState
|
||||||
import com.arkivanov.decompose.router.stack.*
|
import com.arkivanov.decompose.router.stack.*
|
||||||
import com.arkivanov.decompose.value.Value
|
import com.arkivanov.decompose.value.Value
|
||||||
import com.arkivanov.decompose.value.observe
|
import com.arkivanov.decompose.value.subscribe
|
||||||
import com.arkivanov.essenty.instancekeeper.getOrCreateSimple
|
import com.arkivanov.essenty.instancekeeper.getOrCreateSimple
|
||||||
import com.tangem.core.decompose.context.AppComponentContext
|
import com.tangem.core.decompose.context.AppComponentContext
|
||||||
import com.tangem.core.decompose.context.childByContext
|
import com.tangem.core.decompose.context.childByContext
|
||||||
|
|
@ -85,7 +85,7 @@ internal class DefaultOnboardingVisaComponent @AssistedInject constructor(
|
||||||
}
|
}
|
||||||
|
|
||||||
// sets title and stepper value
|
// sets title and stepper value
|
||||||
childStack.observe(lifecycle) { stack ->
|
childStack.subscribe(lifecycle) { stack ->
|
||||||
val currentRoute = stack.active.configuration
|
val currentRoute = stack.active.configuration
|
||||||
params.titleProvider.changeTitle(currentRoute.screenTitle())
|
params.titleProvider.changeTitle(currentRoute.screenTitle())
|
||||||
model.updateStepForNewRoute(currentRoute)
|
model.updateStepForNewRoute(currentRoute)
|
||||||
|
|
|
||||||
|
|
@ -5,7 +5,7 @@ import androidx.compose.runtime.getValue
|
||||||
import androidx.compose.runtime.remember
|
import androidx.compose.runtime.remember
|
||||||
import androidx.lifecycle.compose.collectAsStateWithLifecycle
|
import androidx.lifecycle.compose.collectAsStateWithLifecycle
|
||||||
import com.arkivanov.decompose.ComponentContext
|
import com.arkivanov.decompose.ComponentContext
|
||||||
import com.arkivanov.decompose.extensions.compose.jetpack.subscribeAsState
|
import com.arkivanov.decompose.extensions.compose.subscribeAsState
|
||||||
import com.arkivanov.decompose.router.slot.childSlot
|
import com.arkivanov.decompose.router.slot.childSlot
|
||||||
import com.arkivanov.decompose.router.slot.dismiss
|
import com.arkivanov.decompose.router.slot.dismiss
|
||||||
import com.tangem.core.decompose.context.AppComponentContext
|
import com.tangem.core.decompose.context.AppComponentContext
|
||||||
|
|
|
||||||
|
|
@ -5,7 +5,7 @@ import androidx.compose.runtime.getValue
|
||||||
import androidx.compose.ui.Modifier
|
import androidx.compose.ui.Modifier
|
||||||
import androidx.lifecycle.compose.collectAsStateWithLifecycle
|
import androidx.lifecycle.compose.collectAsStateWithLifecycle
|
||||||
import com.arkivanov.decompose.ComponentContext
|
import com.arkivanov.decompose.ComponentContext
|
||||||
import com.arkivanov.decompose.extensions.compose.jetpack.subscribeAsState
|
import com.arkivanov.decompose.extensions.compose.subscribeAsState
|
||||||
import com.arkivanov.decompose.router.slot.childSlot
|
import com.arkivanov.decompose.router.slot.childSlot
|
||||||
import com.arkivanov.decompose.router.slot.dismiss
|
import com.arkivanov.decompose.router.slot.dismiss
|
||||||
import com.tangem.core.decompose.context.AppComponentContext
|
import com.tangem.core.decompose.context.AppComponentContext
|
||||||
|
|
|
||||||
|
|
@ -5,7 +5,7 @@ import androidx.compose.runtime.collectAsState
|
||||||
import androidx.compose.runtime.getValue
|
import androidx.compose.runtime.getValue
|
||||||
import androidx.compose.ui.Modifier
|
import androidx.compose.ui.Modifier
|
||||||
import com.arkivanov.decompose.ComponentContext
|
import com.arkivanov.decompose.ComponentContext
|
||||||
import com.arkivanov.decompose.extensions.compose.jetpack.subscribeAsState
|
import com.arkivanov.decompose.extensions.compose.subscribeAsState
|
||||||
import com.arkivanov.decompose.router.slot.childSlot
|
import com.arkivanov.decompose.router.slot.childSlot
|
||||||
import com.arkivanov.decompose.router.slot.dismiss
|
import com.arkivanov.decompose.router.slot.dismiss
|
||||||
import com.tangem.core.decompose.context.AppComponentContext
|
import com.tangem.core.decompose.context.AppComponentContext
|
||||||
|
|
|
||||||
|
|
@ -8,7 +8,7 @@ import androidx.compose.runtime.remember
|
||||||
import androidx.compose.ui.Modifier
|
import androidx.compose.ui.Modifier
|
||||||
import androidx.lifecycle.compose.collectAsStateWithLifecycle
|
import androidx.lifecycle.compose.collectAsStateWithLifecycle
|
||||||
import com.arkivanov.decompose.ComponentContext
|
import com.arkivanov.decompose.ComponentContext
|
||||||
import com.arkivanov.decompose.extensions.compose.jetpack.subscribeAsState
|
import com.arkivanov.decompose.extensions.compose.subscribeAsState
|
||||||
import com.arkivanov.decompose.router.slot.childSlot
|
import com.arkivanov.decompose.router.slot.childSlot
|
||||||
import com.arkivanov.decompose.router.slot.dismiss
|
import com.arkivanov.decompose.router.slot.dismiss
|
||||||
import com.tangem.core.decompose.context.AppComponentContext
|
import com.tangem.core.decompose.context.AppComponentContext
|
||||||
|
|
|
||||||
|
|
@ -5,9 +5,9 @@ import androidx.compose.runtime.Composable
|
||||||
import androidx.compose.runtime.getValue
|
import androidx.compose.runtime.getValue
|
||||||
import androidx.compose.ui.Modifier
|
import androidx.compose.ui.Modifier
|
||||||
import com.arkivanov.decompose.ComponentContext
|
import com.arkivanov.decompose.ComponentContext
|
||||||
import com.arkivanov.decompose.extensions.compose.jetpack.stack.Children
|
import com.arkivanov.decompose.extensions.compose.stack.Children
|
||||||
import com.arkivanov.decompose.extensions.compose.jetpack.stack.animation.stackAnimation
|
import com.arkivanov.decompose.extensions.compose.stack.animation.stackAnimation
|
||||||
import com.arkivanov.decompose.extensions.compose.jetpack.subscribeAsState
|
import com.arkivanov.decompose.extensions.compose.subscribeAsState
|
||||||
import com.arkivanov.decompose.router.stack.StackNavigation
|
import com.arkivanov.decompose.router.stack.StackNavigation
|
||||||
import com.arkivanov.decompose.router.stack.childStack
|
import com.arkivanov.decompose.router.stack.childStack
|
||||||
import com.arkivanov.decompose.router.stack.pop
|
import com.arkivanov.decompose.router.stack.pop
|
||||||
|
|
|
||||||
|
|
@ -6,7 +6,7 @@ import androidx.compose.runtime.getValue
|
||||||
import androidx.compose.ui.Modifier
|
import androidx.compose.ui.Modifier
|
||||||
import androidx.lifecycle.compose.collectAsStateWithLifecycle
|
import androidx.lifecycle.compose.collectAsStateWithLifecycle
|
||||||
import com.arkivanov.decompose.ComponentContext
|
import com.arkivanov.decompose.ComponentContext
|
||||||
import com.arkivanov.decompose.extensions.compose.jetpack.subscribeAsState
|
import com.arkivanov.decompose.extensions.compose.subscribeAsState
|
||||||
import com.arkivanov.decompose.router.slot.childSlot
|
import com.arkivanov.decompose.router.slot.childSlot
|
||||||
import com.arkivanov.decompose.router.slot.dismiss
|
import com.arkivanov.decompose.router.slot.dismiss
|
||||||
import com.tangem.core.decompose.context.AppComponentContext
|
import com.tangem.core.decompose.context.AppComponentContext
|
||||||
|
|
|
||||||
|
|
@ -248,7 +248,7 @@ internal class StakingTransactionSender @AssistedInject constructor(
|
||||||
val txUrl = getExplorerTransactionUrlUseCase(
|
val txUrl = getExplorerTransactionUrlUseCase(
|
||||||
txHash = transactionHashes.last(),
|
txHash = transactionHashes.last(),
|
||||||
networkId = cryptoCurrencyStatus.currency.network.id,
|
networkId = cryptoCurrencyStatus.currency.network.id,
|
||||||
).getOrElse { "" }
|
).getOrNull() ?: ""
|
||||||
|
|
||||||
balanceUpdater.fullUpdate()
|
balanceUpdater.fullUpdate()
|
||||||
onSendSuccess(txUrl)
|
onSendSuccess(txUrl)
|
||||||
|
|
|
||||||
|
|
@ -5,6 +5,7 @@ plugins {
|
||||||
alias(deps.plugins.kotlin.android)
|
alias(deps.plugins.kotlin.android)
|
||||||
alias(deps.plugins.kotlin.kapt)
|
alias(deps.plugins.kotlin.kapt)
|
||||||
alias(deps.plugins.hilt.android)
|
alias(deps.plugins.hilt.android)
|
||||||
|
alias(deps.plugins.ksp)
|
||||||
id("configuration")
|
id("configuration")
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -29,7 +30,7 @@ dependencies {
|
||||||
implementation(deps.moshi)
|
implementation(deps.moshi)
|
||||||
implementation(deps.moshi.kotlin)
|
implementation(deps.moshi.kotlin)
|
||||||
implementation(deps.arrow.core)
|
implementation(deps.arrow.core)
|
||||||
kaptForObfuscatingVariants(deps.moshi.kotlin.codegen)
|
ksp(deps.moshi.kotlin.codegen)
|
||||||
kaptForObfuscatingVariants(deps.retrofit.response.type.keeper)
|
kaptForObfuscatingVariants(deps.retrofit.response.type.keeper)
|
||||||
|
|
||||||
/** Domain */
|
/** Domain */
|
||||||
|
|
|
||||||
|
|
@ -5,6 +5,7 @@ plugins {
|
||||||
alias(deps.plugins.kotlin.android)
|
alias(deps.plugins.kotlin.android)
|
||||||
alias(deps.plugins.kotlin.kapt)
|
alias(deps.plugins.kotlin.kapt)
|
||||||
alias(deps.plugins.kotlin.serialization)
|
alias(deps.plugins.kotlin.serialization)
|
||||||
|
alias(deps.plugins.ksp)
|
||||||
id("configuration")
|
id("configuration")
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -54,5 +55,5 @@ dependencies {
|
||||||
implementation(tangemDeps.blockchain)
|
implementation(tangemDeps.blockchain)
|
||||||
implementation(tangemDeps.card.core)
|
implementation(tangemDeps.card.core)
|
||||||
implementation(deps.moshi)
|
implementation(deps.moshi)
|
||||||
kaptForObfuscatingVariants(deps.moshi.kotlin.codegen)
|
ksp(deps.moshi.kotlin.codegen)
|
||||||
}
|
}
|
||||||
|
|
@ -1,9 +1,7 @@
|
||||||
import com.tangem.plugin.configuration.configurations.extension.kaptForObfuscatingVariants
|
|
||||||
|
|
||||||
plugins {
|
plugins {
|
||||||
alias(deps.plugins.android.library)
|
alias(deps.plugins.android.library)
|
||||||
alias(deps.plugins.kotlin.android)
|
alias(deps.plugins.kotlin.android)
|
||||||
alias(deps.plugins.kotlin.kapt)
|
alias(deps.plugins.ksp)
|
||||||
id("configuration")
|
id("configuration")
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -24,6 +22,6 @@ dependencies {
|
||||||
implementation(deps.kotlin.serialization)
|
implementation(deps.kotlin.serialization)
|
||||||
implementation(deps.arrow.core)
|
implementation(deps.arrow.core)
|
||||||
implementation(deps.moshi.kotlin)
|
implementation(deps.moshi.kotlin)
|
||||||
kaptForObfuscatingVariants(deps.moshi.kotlin.codegen)
|
ksp(deps.moshi.kotlin.codegen)
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
@ -5,7 +5,7 @@ import androidx.compose.runtime.getValue
|
||||||
import androidx.compose.ui.Modifier
|
import androidx.compose.ui.Modifier
|
||||||
import androidx.lifecycle.compose.collectAsStateWithLifecycle
|
import androidx.lifecycle.compose.collectAsStateWithLifecycle
|
||||||
import com.arkivanov.decompose.ComponentContext
|
import com.arkivanov.decompose.ComponentContext
|
||||||
import com.arkivanov.decompose.extensions.compose.jetpack.subscribeAsState
|
import com.arkivanov.decompose.extensions.compose.subscribeAsState
|
||||||
import com.arkivanov.decompose.router.slot.childSlot
|
import com.arkivanov.decompose.router.slot.childSlot
|
||||||
import com.arkivanov.decompose.router.slot.dismiss
|
import com.arkivanov.decompose.router.slot.dismiss
|
||||||
import com.tangem.core.decompose.context.AppComponentContext
|
import com.tangem.core.decompose.context.AppComponentContext
|
||||||
|
|
|
||||||
|
|
@ -2,13 +2,15 @@ package com.tangem.feature.wallet
|
||||||
|
|
||||||
import androidx.compose.runtime.Composable
|
import androidx.compose.runtime.Composable
|
||||||
import androidx.compose.ui.Modifier
|
import androidx.compose.ui.Modifier
|
||||||
import com.arkivanov.decompose.extensions.compose.jetpack.stack.Children
|
import com.arkivanov.decompose.extensions.compose.stack.Children
|
||||||
import com.arkivanov.decompose.extensions.compose.jetpack.stack.animation.fade
|
import com.arkivanov.decompose.extensions.compose.stack.animation.fade
|
||||||
import com.arkivanov.decompose.extensions.compose.jetpack.stack.animation.stackAnimation
|
import com.arkivanov.decompose.extensions.compose.stack.animation.stackAnimation
|
||||||
|
import com.arkivanov.decompose.router.stack.ChildStack
|
||||||
import com.arkivanov.decompose.router.stack.StackNavigation
|
import com.arkivanov.decompose.router.stack.StackNavigation
|
||||||
import com.arkivanov.decompose.router.stack.childStack
|
import com.arkivanov.decompose.router.stack.childStack
|
||||||
import com.arkivanov.decompose.router.stack.pop
|
import com.arkivanov.decompose.router.stack.pop
|
||||||
import com.arkivanov.decompose.router.stack.pushNew
|
import com.arkivanov.decompose.router.stack.pushNew
|
||||||
|
import com.arkivanov.decompose.value.Value
|
||||||
import com.tangem.core.decompose.context.AppComponentContext
|
import com.tangem.core.decompose.context.AppComponentContext
|
||||||
import com.tangem.core.decompose.context.childByContext
|
import com.tangem.core.decompose.context.childByContext
|
||||||
import com.tangem.core.ui.decompose.ComposableContentComponent
|
import com.tangem.core.ui.decompose.ComposableContentComponent
|
||||||
|
|
@ -28,7 +30,7 @@ internal class DefaultWalletEntryComponent @AssistedInject constructor(
|
||||||
|
|
||||||
private val navigation = StackNavigation<WalletRoute>()
|
private val navigation = StackNavigation<WalletRoute>()
|
||||||
|
|
||||||
private val stack = childStack<WalletRoute, ComposableContentComponent>(
|
private val stack: Value<ChildStack<WalletRoute, ComposableContentComponent>> = childStack(
|
||||||
source = navigation,
|
source = navigation,
|
||||||
serializer = WalletRoute.serializer(),
|
serializer = WalletRoute.serializer(),
|
||||||
initialConfiguration = WalletRoute.Wallet,
|
initialConfiguration = WalletRoute.Wallet,
|
||||||
|
|
|
||||||
|
|
@ -6,7 +6,7 @@ import androidx.compose.runtime.getValue
|
||||||
import androidx.compose.ui.Modifier
|
import androidx.compose.ui.Modifier
|
||||||
import androidx.compose.ui.platform.LocalContext
|
import androidx.compose.ui.platform.LocalContext
|
||||||
import androidx.lifecycle.compose.collectAsStateWithLifecycle
|
import androidx.lifecycle.compose.collectAsStateWithLifecycle
|
||||||
import com.arkivanov.decompose.extensions.compose.jetpack.subscribeAsState
|
import com.arkivanov.decompose.extensions.compose.subscribeAsState
|
||||||
import com.arkivanov.decompose.router.slot.childSlot
|
import com.arkivanov.decompose.router.slot.childSlot
|
||||||
import com.arkivanov.decompose.router.slot.dismiss
|
import com.arkivanov.decompose.router.slot.dismiss
|
||||||
import com.tangem.core.decompose.context.AppComponentContext
|
import com.tangem.core.decompose.context.AppComponentContext
|
||||||
|
|
|
||||||
|
|
@ -6,7 +6,8 @@
|
||||||
androidGradlePlugin = "8.2.2"
|
androidGradlePlugin = "8.2.2"
|
||||||
firebaseCrashlytics = "3.0.1"
|
firebaseCrashlytics = "3.0.1"
|
||||||
googleServices = "4.4.1"
|
googleServices = "4.4.1"
|
||||||
kotlin = "1.9.22"
|
kotlin = "2.1.10"
|
||||||
|
ksp = "2.1.10-1.0.30"
|
||||||
firebasePerf = "1.4.2"
|
firebasePerf = "1.4.2"
|
||||||
# endregion Classpath
|
# endregion Classpath
|
||||||
|
|
||||||
|
|
@ -26,11 +27,10 @@ androidxWindowManager = "1.3.0"
|
||||||
# endregion AndroidX
|
# endregion AndroidX
|
||||||
|
|
||||||
# region Compose
|
# region Compose
|
||||||
compose-compiler = "1.5.9"
|
compose-runtime = "1.7.8"
|
||||||
compose-runtime = "1.7.1"
|
compose-foundation = "1.7.8"
|
||||||
compose-foundation = "1.7.1"
|
compose-material = "1.7.8"
|
||||||
compose-material = "1.7.1"
|
compose-material3 = "1.3.1"
|
||||||
compose-material3 = "1.3.0"
|
|
||||||
compose-constraint = "1.0.1"
|
compose-constraint = "1.0.1"
|
||||||
compose-navigation = "2.7.7"
|
compose-navigation = "2.7.7"
|
||||||
compose-accompanist = "0.30.1"
|
compose-accompanist = "0.30.1"
|
||||||
|
|
@ -44,14 +44,14 @@ amplitude = "2.36.1"
|
||||||
armadillo = "0.9.0"
|
armadillo = "0.9.0"
|
||||||
coil = "2.1.0"
|
coil = "2.1.0"
|
||||||
compose-shimmer = "1.0.3"
|
compose-shimmer = "1.0.3"
|
||||||
coroutine = "1.7.2"
|
coroutine = "1.7.2" # 1.8+ is not compatible with tangem-sdk
|
||||||
desugarJdkLibs = "1.1.5"
|
desugarJdkLibs = "1.1.5"
|
||||||
firebase = "33.7.0"
|
firebase = "33.7.0"
|
||||||
googleMaterialComponent = "1.6.1"
|
googleMaterialComponent = "1.6.1"
|
||||||
googlePlayReview = "2.0.1"
|
googlePlayReview = "2.0.1"
|
||||||
googlePlayReviewKtx = "2.0.1"
|
googlePlayReviewKtx = "2.0.1"
|
||||||
googlePlayServicesWallet = "19.1.0"
|
googlePlayServicesWallet = "19.1.0"
|
||||||
hilt = "2.46"
|
hilt = "2.55"
|
||||||
hilt-navigation = "1.0.0"
|
hilt-navigation = "1.0.0"
|
||||||
jodatime = "2.12.1"
|
jodatime = "2.12.1"
|
||||||
kotlin-immutable-collections = "0.3.5"
|
kotlin-immutable-collections = "0.3.5"
|
||||||
|
|
@ -69,9 +69,8 @@ timber = "4.7.1"
|
||||||
viewBindingDelegate = "1.5.9"
|
viewBindingDelegate = "1.5.9"
|
||||||
xmlShimmer = "1.1.3"
|
xmlShimmer = "1.1.3"
|
||||||
zxingQrCode = "3.5.1"
|
zxingQrCode = "3.5.1"
|
||||||
mviCore = "1.3.1"
|
kotlinSerialization = "1.8.0"
|
||||||
kotlinSerialization = "1.4.1"
|
arrow = "1.2.4" # 2.0.1 breaks the build
|
||||||
arrow = "1.2.3"
|
|
||||||
reownCore = "1.1.2"
|
reownCore = "1.1.2"
|
||||||
reownWeb3 = "1.1.2"
|
reownWeb3 = "1.1.2"
|
||||||
prettyLogger = "2.2.0"
|
prettyLogger = "2.2.0"
|
||||||
|
|
@ -83,7 +82,7 @@ listenableFuture = "1.0"
|
||||||
swipeRefreshLayout = "1.1.0"
|
swipeRefreshLayout = "1.1.0"
|
||||||
web3j = "4.12.3-SNAPSHOT"
|
web3j = "4.12.3-SNAPSHOT"
|
||||||
leakcanary = "2.13"
|
leakcanary = "2.13"
|
||||||
decompose = "2.2.2"
|
decompose = "3.3.0"
|
||||||
room = "2.6.1"
|
room = "2.6.1"
|
||||||
markdown = "0.7.2"
|
markdown = "0.7.2"
|
||||||
markdownComposeView = "0.5.4"
|
markdownComposeView = "0.5.4"
|
||||||
|
|
@ -121,6 +120,8 @@ google-services = { id = "com.google.gms.google-services", version.ref = "google
|
||||||
hilt-android = { id = "com.google.dagger.hilt.android", version.ref = "hilt" }
|
hilt-android = { id = "com.google.dagger.hilt.android", version.ref = "hilt" }
|
||||||
detekt = { id = "io.gitlab.arturbosch.detekt", version.ref = "detekt" }
|
detekt = { id = "io.gitlab.arturbosch.detekt", version.ref = "detekt" }
|
||||||
room = { id = "androidx.room", version.ref = "room" }
|
room = { id = "androidx.room", version.ref = "room" }
|
||||||
|
kotlin-compose-compiler = { id = "org.jetbrains.kotlin.plugin.compose", version.ref = "kotlin" }
|
||||||
|
ksp = { id = "com.google.devtools.ksp", version.ref = "ksp" }
|
||||||
|
|
||||||
[libraries]
|
[libraries]
|
||||||
# region Classpath
|
# region Classpath
|
||||||
|
|
@ -254,7 +255,7 @@ camera-view = { module = "androidx.camera:camera-view", version.ref = "androidXC
|
||||||
web3j-core = { module = "org.web3j:core", version.ref = "web3j" }
|
web3j-core = { module = "org.web3j:core", version.ref = "web3j" }
|
||||||
leakcanary = { module = "com.squareup.leakcanary:leakcanary-android", version.ref = "leakcanary" }
|
leakcanary = { module = "com.squareup.leakcanary:leakcanary-android", version.ref = "leakcanary" }
|
||||||
decompose = { module = "com.arkivanov.decompose:decompose", version.ref = "decompose" }
|
decompose = { module = "com.arkivanov.decompose:decompose", version.ref = "decompose" }
|
||||||
decompose-ext-compose = { module = "com.arkivanov.decompose:extensions-compose-jetpack", version.ref = "decompose" }
|
decompose-ext-compose = { module = "com.arkivanov.decompose:extensions-compose", version.ref = "decompose" }
|
||||||
room-runtime = { module = "androidx.room:room-runtime", version.ref = "room" }
|
room-runtime = { module = "androidx.room:room-runtime", version.ref = "room" }
|
||||||
room-compiler = { module = "androidx.room:room-compiler", version.ref = "room" }
|
room-compiler = { module = "androidx.room:room-compiler", version.ref = "room" }
|
||||||
room-ktx = { module = "androidx.room:room-ktx", version.ref = "room" }
|
room-ktx = { module = "androidx.room:room-ktx", version.ref = "room" }
|
||||||
|
|
|
||||||
|
|
@ -5,6 +5,7 @@ plugins {
|
||||||
alias(deps.plugins.kotlin.android)
|
alias(deps.plugins.kotlin.android)
|
||||||
alias(deps.plugins.kotlin.kapt)
|
alias(deps.plugins.kotlin.kapt)
|
||||||
alias(deps.plugins.hilt.android)
|
alias(deps.plugins.hilt.android)
|
||||||
|
alias(deps.plugins.ksp)
|
||||||
id("configuration")
|
id("configuration")
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -34,7 +35,7 @@ dependencies {
|
||||||
implementation(deps.moshi)
|
implementation(deps.moshi)
|
||||||
implementation(deps.moshi.kotlin)
|
implementation(deps.moshi.kotlin)
|
||||||
implementation(deps.timber)
|
implementation(deps.timber)
|
||||||
kaptForObfuscatingVariants(deps.moshi.kotlin.codegen)
|
ksp(deps.moshi.kotlin.codegen)
|
||||||
kaptForObfuscatingVariants(deps.retrofit.response.type.keeper)
|
kaptForObfuscatingVariants(deps.retrofit.response.type.keeper)
|
||||||
// endregion
|
// endregion
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -4,6 +4,7 @@ plugins {
|
||||||
alias(deps.plugins.android.library)
|
alias(deps.plugins.android.library)
|
||||||
alias(deps.plugins.kotlin.android)
|
alias(deps.plugins.kotlin.android)
|
||||||
alias(deps.plugins.kotlin.kapt)
|
alias(deps.plugins.kotlin.kapt)
|
||||||
|
alias(deps.plugins.ksp)
|
||||||
id("configuration")
|
id("configuration")
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -30,7 +31,7 @@ dependencies {
|
||||||
implementation(deps.okHttp.prettyLogging)
|
implementation(deps.okHttp.prettyLogging)
|
||||||
implementation(deps.retrofit)
|
implementation(deps.retrofit)
|
||||||
implementation(deps.retrofit.moshi)
|
implementation(deps.retrofit.moshi)
|
||||||
kaptForObfuscatingVariants(deps.moshi.kotlin.codegen)
|
ksp(deps.moshi.kotlin.codegen)
|
||||||
kaptForObfuscatingVariants(deps.retrofit.response.type.keeper)
|
kaptForObfuscatingVariants(deps.retrofit.response.type.keeper)
|
||||||
|
|
||||||
/** Libs - Other */
|
/** Libs - Other */
|
||||||
|
|
|
||||||
|
|
@ -1,7 +1,12 @@
|
||||||
package com.tangem.plugin.configuration.configurations
|
package com.tangem.plugin.configuration.configurations
|
||||||
|
|
||||||
import org.gradle.api.Project
|
import org.gradle.api.Project
|
||||||
|
import org.gradle.kotlin.dsl.getByType
|
||||||
import org.gradle.kotlin.dsl.withType
|
import org.gradle.kotlin.dsl.withType
|
||||||
|
import org.jetbrains.kotlin.gradle.dsl.JvmTarget
|
||||||
|
import org.jetbrains.kotlin.gradle.dsl.KotlinAndroidProjectExtension
|
||||||
|
import org.jetbrains.kotlin.gradle.dsl.KotlinJvmProjectExtension
|
||||||
|
import org.jetbrains.kotlin.gradle.model.KotlinAndroidExtension
|
||||||
import org.jetbrains.kotlin.gradle.tasks.KotlinCompile
|
import org.jetbrains.kotlin.gradle.tasks.KotlinCompile
|
||||||
|
|
||||||
internal fun Project.configureKotlinCompilerOptions() {
|
internal fun Project.configureKotlinCompilerOptions() {
|
||||||
|
|
|
||||||
|
|
@ -2,9 +2,12 @@ package com.tangem.plugin.configuration.configurations.extension
|
||||||
|
|
||||||
import com.android.build.gradle.BaseExtension
|
import com.android.build.gradle.BaseExtension
|
||||||
import com.tangem.plugin.configuration.model.AppConfig
|
import com.tangem.plugin.configuration.model.AppConfig
|
||||||
|
import com.tangem.plugin.configuration.utils.findPlugin
|
||||||
import com.tangem.plugin.configuration.utils.findVersion
|
import com.tangem.plugin.configuration.utils.findVersion
|
||||||
import org.gradle.api.JavaVersion
|
import org.gradle.api.JavaVersion
|
||||||
import org.gradle.api.Project
|
import org.gradle.api.Project
|
||||||
|
import org.gradle.kotlin.dsl.apply
|
||||||
|
import org.gradle.kotlin.dsl.plugins
|
||||||
|
|
||||||
internal fun BaseExtension.configureCompileSdk() {
|
internal fun BaseExtension.configureCompileSdk() {
|
||||||
compileSdkVersion(AppConfig.compileSdkVersion)
|
compileSdkVersion(AppConfig.compileSdkVersion)
|
||||||
|
|
@ -32,8 +35,6 @@ internal fun BaseExtension.configureCompose(project: Project) {
|
||||||
buildFeatures.compose = useCompose
|
buildFeatures.compose = useCompose
|
||||||
|
|
||||||
if (useCompose) {
|
if (useCompose) {
|
||||||
composeOptions {
|
project.plugins.apply(project.findPlugin("kotlin-compose-compiler").pluginId)
|
||||||
kotlinCompilerExtensionVersion = project.findVersion(alias = "compose-compiler").requiredVersion
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
Loading…
Add table
Add a link
Reference in a new issue