From acf098c611a5fa08b2aa421140035c7b8c77a2a1 Mon Sep 17 00:00:00 2001 From: iliyangermanov Date: Tue, 5 Nov 2024 17:33:59 +0200 Subject: [PATCH] Add in-app card --- .../CustomerJourneyCardsProvider.kt | 23 +++++++++++++------ 1 file changed, 16 insertions(+), 7 deletions(-) diff --git a/screen/home/src/main/java/com/ivy/home/customerjourney/CustomerJourneyCardsProvider.kt b/screen/home/src/main/java/com/ivy/home/customerjourney/CustomerJourneyCardsProvider.kt index 9423453471..2af3ee817f 100644 --- a/screen/home/src/main/java/com/ivy/home/customerjourney/CustomerJourneyCardsProvider.kt +++ b/screen/home/src/main/java/com/ivy/home/customerjourney/CustomerJourneyCardsProvider.kt @@ -55,19 +55,28 @@ class CustomerJourneyCardsProvider @Inject constructor( companion object { val ACTIVE_CARDS = listOf( + shutdownCard(), adjustBalanceCard(), addPlannedPaymentCard(), didYouKnow_pinAddTransactionWidgetCard(), didYouKnow_expensesPieChart(), - rateUsCard(), - shareIvyWalletCard(), - joinIvyTelegramCard(), - rateUsCard_2(), - joinTelegram2(), - ivyWalletIsOpenSource(), - bugsApology(), ) + fun shutdownCard() = CustomerJourneyCardModel( + id = "shutdown", + condition = { _, _, _ -> true }, + title = "Important Notice: App No Longer Maintained", + description = "As of Nov 5th 2024, Ivy Wallet is no longer maintained by the original developers. You may continue to use the app, but it will no longer receive updates, bug fixes, or support, and it may stop functioning at some point.", + cta = "Learn More", + ctaIcon = R.drawable.github_logo, + background = Gradient.solid(Red), + hasDismiss = true, + onAction = { _, _, ivyActivity -> + ivyActivity.openUrlInBrowser(Constants.URL_IVY_WALLET_REPO) + } + ) + + fun adjustBalanceCard() = CustomerJourneyCardModel( id = "adjust_balance", condition = { trnCount, _, _ ->