Updated on 2026-08-14
This commit is contained in:
commit
dcee3b8ba2
9 changed files with 112 additions and 0 deletions
|
|
@ -62,5 +62,9 @@
|
|||
{
|
||||
"name": "NEW_TOKEN_RECEIVE_ENABLED",
|
||||
"version": "5.28.0"
|
||||
},
|
||||
{
|
||||
"name": "YIELD_LENDING_FEATURE_ENABLED",
|
||||
"version": "undefined"
|
||||
}
|
||||
]
|
||||
|
|
|
|||
1
features/yield-lending/api/.gitignore
vendored
Normal file
1
features/yield-lending/api/.gitignore
vendored
Normal file
|
|
@ -0,0 +1 @@
|
|||
/build
|
||||
24
features/yield-lending/api/build.gradle.kts
Normal file
24
features/yield-lending/api/build.gradle.kts
Normal file
|
|
@ -0,0 +1,24 @@
|
|||
plugins {
|
||||
alias(deps.plugins.android.library)
|
||||
alias(deps.plugins.kotlin.android)
|
||||
id("configuration")
|
||||
}
|
||||
|
||||
android {
|
||||
namespace = "com.tangem.features.yieldlending.api"
|
||||
}
|
||||
|
||||
dependencies {
|
||||
/** Core */
|
||||
implementation(projects.core.decompose)
|
||||
implementation(projects.core.ui)
|
||||
|
||||
/** Domain */
|
||||
implementation(projects.domain.models)
|
||||
implementation(projects.domain.wallets.models)
|
||||
implementation(projects.domain.tokens.models)
|
||||
implementation(projects.domain.appCurrency.models)
|
||||
|
||||
/** Compose */
|
||||
implementation(deps.compose.runtime)
|
||||
}
|
||||
|
|
@ -0,0 +1,6 @@
|
|||
package com.tangem.features.yieldlending.api
|
||||
|
||||
interface YieldLendingFeatureToggles {
|
||||
|
||||
val isYieldLendingFeatureEnabled: Boolean
|
||||
}
|
||||
1
features/yield-lending/impl/.gitignore
vendored
Normal file
1
features/yield-lending/impl/.gitignore
vendored
Normal file
|
|
@ -0,0 +1 @@
|
|||
/build
|
||||
41
features/yield-lending/impl/build.gradle.kts
Normal file
41
features/yield-lending/impl/build.gradle.kts
Normal file
|
|
@ -0,0 +1,41 @@
|
|||
plugins {
|
||||
alias(deps.plugins.android.library)
|
||||
alias(deps.plugins.kotlin.android)
|
||||
alias(deps.plugins.kotlin.kapt)
|
||||
alias(deps.plugins.kotlin.serialization)
|
||||
alias(deps.plugins.hilt.android)
|
||||
id("configuration")
|
||||
}
|
||||
|
||||
android {
|
||||
namespace = "com.tangem.features.yieldlending.impl"
|
||||
}
|
||||
|
||||
dependencies {
|
||||
|
||||
/** Feature */
|
||||
implementation(projects.features.yieldLending.api)
|
||||
|
||||
/** Core */
|
||||
implementation(projects.core.configToggles)
|
||||
implementation(projects.core.decompose)
|
||||
implementation(projects.core.ui)
|
||||
|
||||
/** Domain */
|
||||
implementation(projects.domain.models)
|
||||
implementation(projects.domain.wallets.models)
|
||||
implementation(projects.domain.tokens.models)
|
||||
implementation(projects.domain.appCurrency.models)
|
||||
|
||||
/** Compose */
|
||||
implementation(deps.compose.foundation)
|
||||
implementation(deps.compose.runtime)
|
||||
implementation(deps.compose.material3)
|
||||
implementation(deps.compose.ui)
|
||||
implementation(deps.compose.ui.tooling)
|
||||
implementation(deps.androidx.activity.compose)
|
||||
|
||||
/** DI */
|
||||
implementation(deps.hilt.android)
|
||||
kapt(deps.hilt.kapt)
|
||||
}
|
||||
|
|
@ -0,0 +1,11 @@
|
|||
package com.tangem.features.yieldlending.impl
|
||||
|
||||
import com.tangem.core.configtoggle.feature.FeatureTogglesManager
|
||||
import com.tangem.features.yieldlending.api.YieldLendingFeatureToggles
|
||||
|
||||
internal class DefaultYieldLendingFeatureToggles(
|
||||
private val featureToggles: FeatureTogglesManager,
|
||||
) : YieldLendingFeatureToggles {
|
||||
override val isYieldLendingFeatureEnabled: Boolean
|
||||
get() = featureToggles.isFeatureEnabled("YIELD_LENDING_FEATURE_ENABLED")
|
||||
}
|
||||
|
|
@ -0,0 +1,21 @@
|
|||
package com.tangem.features.yieldlending.impl.di
|
||||
|
||||
import com.tangem.core.configtoggle.feature.FeatureTogglesManager
|
||||
import com.tangem.features.yieldlending.api.YieldLendingFeatureToggles
|
||||
import com.tangem.features.yieldlending.impl.DefaultYieldLendingFeatureToggles
|
||||
import dagger.Module
|
||||
import dagger.Provides
|
||||
import dagger.hilt.InstallIn
|
||||
import dagger.hilt.components.SingletonComponent
|
||||
import javax.inject.Singleton
|
||||
|
||||
@InstallIn(SingletonComponent::class)
|
||||
@Module
|
||||
internal object YieldLendingFeatureModule {
|
||||
|
||||
@Singleton
|
||||
@Provides
|
||||
fun provideYieldFeatureToggles(featureTogglesManager: FeatureTogglesManager): YieldLendingFeatureToggles {
|
||||
return DefaultYieldLendingFeatureToggles(featureTogglesManager)
|
||||
}
|
||||
}
|
||||
|
|
@ -281,6 +281,9 @@ include(":features:account:impl")
|
|||
|
||||
include(":features:token-recieve:api")
|
||||
include(":features:token-recieve:impl")
|
||||
|
||||
include(":features:yield-lending:api")
|
||||
include(":features:yield-lending:impl")
|
||||
// endregion Feature modules
|
||||
|
||||
// region Domain modules
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue