Updated on 2026-08-14

This commit is contained in:
Tangem 2026-05-20 11:27:43 -07:00
parent 5b516f2c9b
commit a82d8cdbba
43 changed files with 829 additions and 89 deletions

View file

@ -102,6 +102,7 @@ sealed class AnalyticsParam {
Portfolio("Portfolio"),
Staking("Staking"),
Earn("Earn"),
TangemPayHotWalletOnboarding("TangemPayHotWalletOnboarding"),
}
sealed class TxSentFrom(val value: String) {

View file

@ -82,5 +82,9 @@
{
"name": "AND_15009_SWAP_PROVIDER_FILTER_ENABLED",
"version": "undefined"
},
{
"name": "AND_15101_TANGEM_PAY_HOT_WALLET_ONBOARDING",
"version": "undefined"
}
]

View file

@ -13,4 +13,19 @@ interface AppsFlyerStore {
suspend fun storeIfAbsent(value: AppsFlyerConversionData)
suspend fun storeUIDIfAbsent(value: String)
suspend fun getDeeplink(source: AppsFlyerDeeplinkSource): String?
suspend fun storeDeeplink(source: AppsFlyerDeeplinkSource, deeplink: String)
suspend fun clearDeeplink(source: AppsFlyerDeeplinkSource)
}
enum class AppsFlyerDeeplinkSource {
TangemPayHotWalletOnboarding,
;
fun toStoreKey() = when (this) {
TangemPayHotWalletOnboarding -> "tangem_pay_hot_wallet_onboarding"
}
}

View file

@ -56,8 +56,22 @@ internal class DefaultAppsFlyerStore(
}
}
private companion object {
override suspend fun getDeeplink(source: AppsFlyerDeeplinkSource): String? =
appPreferencesStore.getSyncOrNull(stringPreferencesKey(source.toStoreKey()))
override suspend fun storeDeeplink(source: AppsFlyerDeeplinkSource, deeplink: String) {
appPreferencesStore.editData { preferences ->
preferences[stringPreferencesKey(source.toStoreKey())] = deeplink
}
}
override suspend fun clearDeeplink(source: AppsFlyerDeeplinkSource) {
appPreferencesStore.editData { preferences ->
preferences.remove(stringPreferencesKey(source.toStoreKey()))
}
}
private companion object {
val UID_KEY = stringPreferencesKey("APPS_FLYER_UID")
val CONVERSION_DATA_KEY = stringPreferencesKey("APPS_FLYER_CONVERSION_DATA")
}

Binary file not shown.

After

Width:  |  Height:  |  Size: 32 KiB