Updated on 2026-08-14

This commit is contained in:
Tangem 2025-01-20 10:12:18 +03:00
commit 780686645b
17 changed files with 70 additions and 35 deletions

View file

@ -1,6 +1,5 @@
package com.tangem.features.send.impl.presentation.ui.common
import androidx.compose.foundation.ExperimentalFoundationApi
import androidx.compose.foundation.layout.padding
import androidx.compose.foundation.lazy.LazyListScope
import androidx.compose.foundation.lazy.itemsIndexed
@ -10,7 +9,6 @@ import com.tangem.core.ui.components.notifications.Notification
import com.tangem.core.ui.res.TangemTheme
import kotlinx.collections.immutable.ImmutableList
@OptIn(ExperimentalFoundationApi::class)
internal fun LazyListScope.notifications(
notifications: ImmutableList<NotificationUM>,
modifier: Modifier = Modifier,
@ -31,7 +29,7 @@ internal fun LazyListScope.notifications(
config = item.config,
modifier = modifier
.padding(top = topPadding)
.animateItemPlacement(),
.animateItem(fadeInSpec = null, fadeOutSpec = null),
containerColor = when (item) {
is NotificationUM.Error.TokenExceedsBalance,
is NotificationUM.Warning.NetworkFeeUnreachable,

View file

@ -85,6 +85,12 @@ internal enum class Wallet2CobrandImage(
batchIds = setOf("AF32"),
),
GetsMine(
cards2ResId = R.drawable.ill_gets_mine_card2_120_106,
cards3ResId = R.drawable.ill_gets_mine_card3_120_106,
batchIds = setOf("BB000008"),
),
Grim(
cards2ResId = R.drawable.ill_grim_card2_120_106,
cards3ResId = R.drawable.ill_grim_card3_120_106,
@ -194,6 +200,12 @@ internal enum class Wallet2CobrandImage(
batchIds = setOf("AF07"),
),
USA(
cards2ResId = R.drawable.ill_usa_card2_120_106,
cards3ResId = R.drawable.ill_usa_card3_120_106,
batchIds = setOf("AF91"),
),
VeChain(
cards2ResId = R.drawable.ill_vechain_card2_120_106,
cards3ResId = R.drawable.ill_vechain_card3_120_106,
@ -218,4 +230,10 @@ internal enum class Wallet2CobrandImage(
cards3ResId = R.drawable.ill_white_card3_120_106,
batchIds = setOf("AF15"),
),
Winter(
cards2ResId = R.drawable.ill_winter_card2_120_106,
cards3ResId = R.drawable.ill_winter_card3_120_106,
batchIds = setOf("AF85", "AF86", "AF87", "AF990013", "AF990012", "AF990011"),
),
}

View file

@ -35,7 +35,7 @@ internal fun LazyListScope.lazyActions(
item(key = ACTIONS_CONTENT_TYPE + selectedWalletIndex, contentType = ACTIONS_CONTENT_TYPE) {
HorizontalActionChips(
buttons = actions.map(WalletManageButton::config).toImmutableList(),
modifier = modifier.animateItem(),
modifier = modifier.animateItem(fadeInSpec = null, fadeOutSpec = null),
contentPadding = PaddingValues(horizontal = TangemTheme.dimens.spacing16),
)
}
@ -62,7 +62,7 @@ internal fun LazyListScope.actions(
modifier = modifier
.padding(horizontal = 16.dp)
.fillMaxWidth()
.animateItem(),
.animateItem(fadeInSpec = null, fadeOutSpec = null),
horizontalArrangement = Arrangement.spacedBy(space = TangemTheme.dimens.spacing8),
verticalAlignment = Alignment.CenterVertically,
) {

View file

@ -30,25 +30,25 @@ internal fun LazyListScope.notifications(configs: ImmutableList<WalletNotificati
is WalletNotification.SwapPromo -> {
OkxPromoNotification(
config = it.config,
modifier = modifier.animateItem(),
modifier = modifier.animateItem(fadeInSpec = null, fadeOutSpec = null),
)
}
is WalletNotification.RingPromo -> {
RingPromoNotification(
config = it.config,
modifier = modifier.animateItem(),
modifier = modifier.animateItem(fadeInSpec = null, fadeOutSpec = null),
)
}
is WalletNotification.NoteMigration -> {
NoteMigrationNotification(
config = it.config,
modifier = modifier.animateItem(),
modifier = modifier.animateItem(fadeInSpec = null, fadeOutSpec = null),
)
}
else -> {
Notification(
config = it.config,
modifier = modifier.animateItem(),
modifier = modifier.animateItem(fadeInSpec = null, fadeOutSpec = null),
iconTint = when (it) {
is WalletNotification.Critical -> TangemTheme.colors.icon.warning
is WalletNotification.Informational -> TangemTheme.colors.icon.accent

View file

@ -78,7 +78,7 @@ private fun LazyListScope.nonContentItem(modifier: Modifier = Modifier) {
) {
Column(
modifier = modifier
.animateItem()
.animateItem(fadeInSpec = null, fadeOutSpec = null)
.padding(top = TangemTheme.dimens.spacing96),
verticalArrangement = Arrangement.spacedBy(space = TangemTheme.dimens.spacing16),
horizontalAlignment = Alignment.CenterHorizontally,

View file

@ -1,6 +1,5 @@
package com.tangem.feature.wallet.presentation.wallet.ui.components.singlecurrency
import androidx.compose.foundation.ExperimentalFoundationApi
import androidx.compose.foundation.lazy.LazyListScope
import androidx.compose.ui.Modifier
import com.tangem.core.ui.components.marketprice.MarketPriceBlock
@ -14,12 +13,11 @@ import com.tangem.core.ui.components.marketprice.MarketPriceBlockState
*
[REDACTED_AUTHOR]
*/
@OptIn(ExperimentalFoundationApi::class)
internal fun LazyListScope.marketPriceBlock(state: MarketPriceBlockState, modifier: Modifier = Modifier) {
item(
key = MarketPriceBlockState::class.java,
contentType = MarketPriceBlockState::class.java,
) {
MarketPriceBlock(state = state, modifier = modifier.animateItemPlacement())
MarketPriceBlock(state = state, modifier = modifier.animateItem(fadeInSpec = null, fadeOutSpec = null))
}
}

Binary file not shown.

After

Width:  |  Height:  |  Size: 26 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 35 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 30 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 34 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 28 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 37 KiB