Updated on 2026-08-14
This commit is contained in:
commit
c2cd7e6b4c
675 changed files with 9577 additions and 4375 deletions
|
|
@ -68,7 +68,7 @@ internal class WcConnectionsModel @Inject constructor(
|
|||
val bottomSheetNavigation: SlotNavigation<WcConnectionsBottomSheetConfig> = SlotNavigation()
|
||||
|
||||
init {
|
||||
analytics.send(WcAnalyticEvents.ScreenOpened)
|
||||
analytics.send(WcAnalyticEvents.ScreenOpened())
|
||||
listenQrUpdates()
|
||||
if (accountsFeatureToggles.isFeatureEnabled) {
|
||||
listenWcSessions()
|
||||
|
|
|
|||
|
|
@ -31,6 +31,7 @@ import com.tangem.domain.models.wallet.UserWallet
|
|||
import com.tangem.domain.models.wallet.UserWalletId
|
||||
import com.tangem.domain.models.wallet.isLocked
|
||||
import com.tangem.domain.models.wallet.isMultiCurrency
|
||||
import com.tangem.domain.walletconnect.WcAnalyticAccountEvents
|
||||
import com.tangem.domain.walletconnect.WcAnalyticEvents
|
||||
import com.tangem.domain.walletconnect.model.WcPairError
|
||||
import com.tangem.domain.walletconnect.model.WcPairError.Unknown
|
||||
|
|
@ -118,7 +119,7 @@ internal class WcPairModel @Inject constructor(
|
|||
init {
|
||||
if (accountsFeatureToggles.isFeatureEnabled) {
|
||||
portfolioFetcher = portfolioFetcherFactory.create(
|
||||
mode = PortfolioFetcher.Mode.All(onlyMultiCurrency = true),
|
||||
mode = PortfolioFetcher.Mode.All(isOnlyMultiCurrency = true),
|
||||
scope = modelScope,
|
||||
)
|
||||
modelScope.launch {
|
||||
|
|
@ -319,6 +320,17 @@ internal class WcPairModel @Inject constructor(
|
|||
val selectedPortfolio = selectedPortfolio.replayCache.firstOrNull()
|
||||
val wallet = selectedPortfolio?.first ?: selectedUserWalletFlow.value
|
||||
val account = selectedPortfolio?.second?.account
|
||||
|
||||
modelScope.launch {
|
||||
if (selectorController.isAccountModeSync() && account != null) {
|
||||
val derivationIndex = when (account) {
|
||||
is Account.CryptoPortfolio -> account.derivationIndex.value
|
||||
}
|
||||
analytics.send(WcAnalyticAccountEvents.PairButtonConnect(derivationIndex))
|
||||
} else {
|
||||
analytics.send(WcAnalyticEvents.PairButtonConnect())
|
||||
}
|
||||
}
|
||||
wcPairUseCase.approve(
|
||||
WcSessionApprove(
|
||||
wallet = wallet,
|
||||
|
|
|
|||
|
|
@ -171,7 +171,7 @@ internal class WcSendTransactionModel @Inject constructor(
|
|||
feeReloadState.value = false
|
||||
modelScope.launch {
|
||||
feeSelectorReloadTrigger.triggerUpdate(
|
||||
FeeSelectorData(removeSuggestedFee = feeStateConfiguration !is FeeStateConfiguration.Suggestion),
|
||||
FeeSelectorData(isRemoveSuggestedFee = feeStateConfiguration !is FeeStateConfiguration.Suggestion),
|
||||
)
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue