From 44280cbadca4ef47cc3fc78c6b0c6a886e5731db Mon Sep 17 00:00:00 2001 From: Ovi Trif Date: Thu, 12 Nov 2026 17:33:49 +0100 Subject: [PATCH 01/11] fix: transfer banner opens transfer progress --- Bitkit/Managers/SparkManager.swift | 7 ++++ Bitkit/ViewModels/SparkTransferFlow.swift | 8 +++++ .../Wallets/Activity/ActivityLatest.swift | 11 +++++++ BitkitTests/SparkTransferFlowTests.swift | 32 +++++++++++++++++++ .../transfer-banner-opens-progress.xml | 22 +++++++++++++ 5 files changed, 80 insertions(+) create mode 100644 journeys/transfer/transfer-banner-opens-progress.xml diff --git a/Bitkit/Managers/SparkManager.swift b/Bitkit/Managers/SparkManager.swift index bb0aeff7ad..67917d5a7a 100644 --- a/Bitkit/Managers/SparkManager.swift +++ b/Bitkit/Managers/SparkManager.swift @@ -1966,6 +1966,13 @@ struct SparkDeposit: Identifiable, Equatable { } } +extension [SparkDeposit] { + /// The deposit whose progress the transfer banner opens: the first one Spark has not claimed yet. + var inProgressTxid: String? { + first { !$0.isClaimed }?.txid + } +} + /// How a deposit into Spark can be claimed. The provider decides per deposit whether to credit it early, at 0 /// confirmations or 1-2, for a fee above the standard claim's at 3 confirmations. struct SparkClaimOffer: Equatable { diff --git a/Bitkit/ViewModels/SparkTransferFlow.swift b/Bitkit/ViewModels/SparkTransferFlow.swift index 7d8d1320f9..96ed05845d 100644 --- a/Bitkit/ViewModels/SparkTransferFlow.swift +++ b/Bitkit/ViewModels/SparkTransferFlow.swift @@ -362,6 +362,14 @@ final class SparkTransferFlow { onBroadcast(txid: txid, ceilingSats: approved.ceilingSats) } + /// Shows the progress of the deposit in `txid`, as when the transfer banner opens it. A deposit this flow doesn't + /// follow, as after a relaunch, is added by Spark at 3 confirmations. + func showDeposit(txid: String) { + guard self.txid?.caseInsensitiveCompare(txid) != .orderedSame else { return } + self.txid = txid + claimState = .later + } + /// Ends the transfer on screen once Spark lists its deposit as claimed, whatever the speed, so Later or Wait /// doesn't stay in progress after the deposit reached spending. func noteSettled(_ deposits: [SparkDeposit]) { diff --git a/Bitkit/Views/Wallets/Activity/ActivityLatest.swift b/Bitkit/Views/Wallets/Activity/ActivityLatest.swift index 9f6b91e169..a166df74dd 100644 --- a/Bitkit/Views/Wallets/Activity/ActivityLatest.swift +++ b/Bitkit/Views/Wallets/Activity/ActivityLatest.swift @@ -11,6 +11,7 @@ struct ActivityLatest: View { @EnvironmentObject private var wallet: WalletViewModel @Environment(UsdtWalletManager.self) private var usdt @Environment(HwWalletManager.self) private var hwWalletManager + @Environment(SparkTransferFlow.self) private var sparkTransfer private var shouldShowBanner: Bool { wallet.balanceInTransferToSavings > 0 || wallet.balanceInTransferToSpending > 0 @@ -57,10 +58,20 @@ struct ActivityLatest: View { return Array(items.prefix(maxActivityItemsOnHome)) } + /// Opens the progress of the transfer to spending the banner shows, at its current step. + private func openTransferProgress() { + guard bannerType == .spending, let txid = SparkManager.shared.deposits.inProgressTxid else { return } + sparkTransfer.showDeposit(txid: txid) + navigation.navigate(.settingUp) + } + var body: some View { VStack(spacing: 0) { if shouldShowBanner { ActivityBanner(type: bannerType, remainingDuration: remainingDuration) + .contentShape(Rectangle()) + .onTapGesture(perform: openTransferProgress) + .accessibilityIdentifier("ActivityBanner") .padding(.bottom, 16) .transition(.opacity) } diff --git a/BitkitTests/SparkTransferFlowTests.swift b/BitkitTests/SparkTransferFlowTests.swift index a816c1283c..dbc7a667c6 100644 --- a/BitkitTests/SparkTransferFlowTests.swift +++ b/BitkitTests/SparkTransferFlowTests.swift @@ -268,6 +268,38 @@ final class SparkTransferFlowTests: XCTestCase { XCTAssertEqual(flow.claimState, .added, "Later stayed in progress after the deposit reached spending") } + @MainActor + func testTheTransferBannerOpensTheFollowedDepositAtItsStep() async { + let flow = pollingFlow(offers: [choice(earlyFee: 800)], claims: [.submitted]) + flow.onBroadcast(txid: "txid") + await flow.waitForClaim() + + flow.showDeposit(txid: "TXID") + + XCTAssertEqual(flow.claimState, .adding, "The banner lost the followed transfer's step") + } + + @MainActor + func testTheTransferBannerOpensADepositNoClaimFollowsAsAddedAtMaturity() { + let flow = SparkTransferFlow() + + flow.showDeposit(txid: "txid") + XCTAssertEqual(flow.claimState, .later) + XCTAssertEqual(SettingUpView.currentStep(for: flow.claimState), 1) + + flow.noteSettled([SparkDeposit(txid: "txid", amountSats: 100_000, isClaimed: true)]) + XCTAssertEqual(flow.claimState, .added, "The opened deposit stayed in progress after Spark claimed it") + } + + func testTheTransferBannerPicksTheFirstUnclaimedDeposit() { + let deposits = [ + SparkDeposit(txid: "claimed", amountSats: 1, isClaimed: true), + SparkDeposit(txid: "pending", amountSats: 1, isClaimed: false), + ] + XCTAssertEqual(deposits.inProgressTxid, "pending") + XCTAssertNil([SparkDeposit(txid: "claimed", amountSats: 1, isClaimed: true)].inProgressTxid) + } + @MainActor func testARecoveredFundingClaimsEarlyOnlyUpToTheSwipedCeiling() async { let flow = pollingFlow(offers: [choice(earlyFee: 800)], claims: [.claimed]) diff --git a/journeys/transfer/transfer-banner-opens-progress.xml b/journeys/transfer/transfer-banner-opens-progress.xml new file mode 100644 index 0000000000..b04706a31c --- /dev/null +++ b/journeys/transfer/transfer-banner-opens-progress.xml @@ -0,0 +1,22 @@ + + + Verifies that tapping the "TRANSFER IN PROGRESS" banner on Home reopens the "Funds in transfer" screen of the + pending transfer to spending at its current step, also after a relaunch. A Later transfer keeps its deposit + pending until 3 confirmations, so the banner stays up while the journey taps it. + + Precondition: a Debug build with Spark connected on its regtest, launched against that regtest's Esplora (as + spark-transfer-to-spending.xml sets up), a wallet with a positive confirmed on-chain Savings balance, no pending + transfer, and at least one activity so Home shows its activity list. Start on the wallet home screen. + + + Tap the Savings balance card (id "ActivitySavings"), then "Transfer To Spending" (id "TransferToSpending"); tap "Get Started" (id "SpendingIntro-button") if the intro appears + Tap "25%" (id "SpendingAmountQuarter") and "Continue" (id "SpendingAmountContinue") + Tap "Later" (id "SpendingConfirmLater") and swipe the "Swipe To Transfer" handle (id "GRAB") fully to the right + Verify the "Funds in transfer" screen (id "LightningSettingUp") opens, then tap "Continue Using Bitkit" (id "TransferSuccess-button") + Verify Home shows the "TRANSFER IN PROGRESS" banner (id "ActivityBanner") + Tap the banner and verify "Funds in transfer" (id "LightningSettingUp") opens with "Payment Successful" as the current step and the speed (id "SettingUpSpeed") reading Later + Go back and verify the wallet home screen shows with the banner still visible + Relaunch the app, tap the banner and verify the same screen and step open again + Mine 3 blocks on the regtest and wait until the screen shows the transfer as done (id "TransferSuccess"); tap its button and verify Home no longer shows the banner + + From 1af737a5937e3ebf3e019e1e51b8489c8013dd3a Mon Sep 17 00:00:00 2001 From: Ovi Trif Date: Thu, 12 Nov 2026 17:48:38 +0100 Subject: [PATCH 02/11] fix: savings banner opens a running spark exit --- .../Views/Wallets/Activity/ActivityLatest.swift | 15 +++++++++++---- 1 file changed, 11 insertions(+), 4 deletions(-) diff --git a/Bitkit/Views/Wallets/Activity/ActivityLatest.swift b/Bitkit/Views/Wallets/Activity/ActivityLatest.swift index a166df74dd..db44d65cd1 100644 --- a/Bitkit/Views/Wallets/Activity/ActivityLatest.swift +++ b/Bitkit/Views/Wallets/Activity/ActivityLatest.swift @@ -58,11 +58,18 @@ struct ActivityLatest: View { return Array(items.prefix(maxActivityItemsOnHome)) } - /// Opens the progress of the transfer to spending the banner shows, at its current step. + /// Opens the progress of the transfer the banner shows, at its current step: a deposit into Spark, or Spark's + /// emergency exit to savings. private func openTransferProgress() { - guard bannerType == .spending, let txid = SparkManager.shared.deposits.inProgressTxid else { return } - sparkTransfer.showDeposit(txid: txid) - navigation.navigate(.settingUp) + switch bannerType { + case .spending: + guard let txid = SparkManager.shared.deposits.inProgressTxid else { return } + sparkTransfer.showDeposit(txid: txid) + navigation.navigate(.settingUp) + case .savings: + guard SparkExitManager.shared.isExiting else { return } + navigation.navigate(.sparkExitProgress) + } } var body: some View { From a2fcdbb66a6f0843092dcd21365b2e7e5385d5b0 Mon Sep 17 00:00:00 2001 From: Ovi Trif Date: Thu, 12 Nov 2026 18:15:54 +0100 Subject: [PATCH 03/11] feat: spark transfer status matches the funds in transfer designs Maps the deposit states onto the six Funds In Transfer (spark) frames: processing, payment successful, fast fee changed, fast transfer unavailable, adding to spending balance and transfer successful. Adds a journey and tests for the mapping. --- .../Localization/ar.lproj/Localizable.strings | 8 - .../Localization/ca.lproj/Localizable.strings | 8 - .../Localization/cs.lproj/Localizable.strings | 8 - .../Localization/de.lproj/Localizable.strings | 8 - .../Localization/el.lproj/Localizable.strings | 8 - .../Localization/en.lproj/Localizable.strings | 19 +- .../es-419.lproj/Localizable.strings | 8 - .../Localization/es.lproj/Localizable.strings | 8 - .../Localization/fr.lproj/Localizable.strings | 8 - .../Localization/it.lproj/Localizable.strings | 8 - .../Localization/nl.lproj/Localizable.strings | 8 - .../Localization/pl.lproj/Localizable.strings | 8 - .../pt-BR.lproj/Localizable.strings | 8 - .../Localization/pt.lproj/Localizable.strings | 8 - .../Localization/ru.lproj/Localizable.strings | 8 - Bitkit/Views/Transfer/SettingUpView.swift | 208 ++++++++++-------- BitkitTests/SparkFundingRecoveryTests.swift | 62 +++--- BitkitTests/SparkTransferFlowTests.swift | 2 +- journeys/transfer/spark-transfer-status.xml | 22 ++ 19 files changed, 179 insertions(+), 246 deletions(-) create mode 100644 journeys/transfer/spark-transfer-status.xml diff --git a/Bitkit/Resources/Localization/ar.lproj/Localizable.strings b/Bitkit/Resources/Localization/ar.lproj/Localizable.strings index 3c6736f856..00b3e68759 100644 --- a/Bitkit/Resources/Localization/ar.lproj/Localizable.strings +++ b/Bitkit/Resources/Localization/ar.lproj/Localizable.strings @@ -264,7 +264,6 @@ "lightning__setting_up_step1" = "جارٍ معالجة الدفع"; "lightning__setting_up_step2" = "نجح الدفع"; "lightning__setting_up_step_spark" = "Adding To Spending"; -"lightning__setting_up_speed" = "Speed: {speed}"; "lightning__setting_up_button" = "متابعة استخدام Bitkit"; "lightning__node_info" = "عقدة Lightning"; "lightning__connections" = "اتصالات Lightning"; @@ -298,21 +297,14 @@ "lightning__spark_deposit" = "إيداع"; "lightning__spark_deposit__choice" = "يمكن لـ Spark إضافته {when} مقابل رسوم أعلى، أو بعد {standard} تأكيدات، أي بعد نحو {minutes} دقيقة."; "lightning__spark_deposit__claim_early" = "استخدمه {when}"; -"lightning__spark_deposit__claimed" = "يضيفه Spark إلى رصيد الإنفاق."; "lightning__spark_deposit__early_fee" = "رسوم الاستخدام {when}"; "lightning__spark_deposit__later" = "بعد {count} تأكيدات"; "lightning__spark_deposit__later_one" = "بعد تأكيد واحد"; -"lightning__spark_deposit__looking" = "بانتظار أن يرى Spark تحويلك."; "lightning__spark_deposit__now" = "الآن"; -"lightning__spark_deposit__standard" = "يضيفه Spark إلى رصيد الإنفاق بعد {standard} تأكيدات، أي بعد نحو {minutes} دقيقة."; "lightning__spark_deposit__standard_fee" = "رسوم الانتظار"; "lightning__spark_deposit__wait_button" = "انتظر"; "lightning__spark_deposit__waiting" = "يضيفه Spark إلى رصيد الإنفاق {when}."; "lightning__spark_deposit__waiting_next" = "يضيفه Spark إلى رصيد الإنفاق بعد التأكيد التالي."; -"lightning__spark_deposit__repriced" = "Instant now costs {fee}. Pay it to add your transfer now, or wait for 3 confirmations, about 30 minutes."; -"lightning__spark_deposit__pay" = "Pay {fee}"; -"lightning__spark_deposit__instant_unavailable" = "Instant isn't available for this transfer. Spark adds it to your spending balance after 3 confirmations, about 30 minutes."; -"lightning__spark_deposit__not_seen" = "Spark hasn't seen your transfer yet. It's added after 3 confirmations; you can leave this screen."; "lightning__spark_deposits_claimed" = "إيداعات تمت المطالبة بها"; "lightning__spark_deposits_pending" = "إيداعات قيد التنفيذ"; "lightning__spark_provider" = "المزوّد"; diff --git a/Bitkit/Resources/Localization/ca.lproj/Localizable.strings b/Bitkit/Resources/Localization/ca.lproj/Localizable.strings index d0d4122cb1..841e72e812 100644 --- a/Bitkit/Resources/Localization/ca.lproj/Localizable.strings +++ b/Bitkit/Resources/Localization/ca.lproj/Localizable.strings @@ -293,7 +293,6 @@ "lightning__setting_up_step1" = "Processant pagament"; "lightning__setting_up_step2" = "Pagament realitzat amb èxit"; "lightning__setting_up_step_spark" = "Adding To Spending"; -"lightning__setting_up_speed" = "Speed: {speed}"; "lightning__setting_up_button" = "Continua utilitzant Bitkit"; "lightning__node_info" = "Node Lightning"; "lightning__node_id" = "ID de Node LDK"; @@ -335,21 +334,14 @@ "lightning__spark_deposit" = "Dipòsit"; "lightning__spark_deposit__choice" = "Spark pot afegir-ho {when} per una comissió més alta, o després de {standard} confirmacions, d'aquí a uns {minutes} minuts."; "lightning__spark_deposit__claim_early" = "Fes-ho servir {when}"; -"lightning__spark_deposit__claimed" = "Spark ho està afegint al teu saldo de despeses."; "lightning__spark_deposit__early_fee" = "Comissió per fer-ho servir {when}"; "lightning__spark_deposit__later" = "després de {count} confirmacions"; "lightning__spark_deposit__later_one" = "després d'1 confirmació"; -"lightning__spark_deposit__looking" = "Esperant que Spark vegi la teva transferència."; "lightning__spark_deposit__now" = "ara"; -"lightning__spark_deposit__standard" = "Spark ho afegeix al teu saldo de despeses després de {standard} confirmacions, d'aquí a uns {minutes} minuts."; "lightning__spark_deposit__standard_fee" = "Comissió per esperar"; "lightning__spark_deposit__wait_button" = "Espera"; "lightning__spark_deposit__waiting" = "Spark ho afegeix al teu saldo de despeses {when}."; "lightning__spark_deposit__waiting_next" = "Spark ho afegeix al teu saldo de despeses després de la confirmació següent."; -"lightning__spark_deposit__repriced" = "Instant now costs {fee}. Pay it to add your transfer now, or wait for 3 confirmations, about 30 minutes."; -"lightning__spark_deposit__pay" = "Pay {fee}"; -"lightning__spark_deposit__instant_unavailable" = "Instant isn't available for this transfer. Spark adds it to your spending balance after 3 confirmations, about 30 minutes."; -"lightning__spark_deposit__not_seen" = "Spark hasn't seen your transfer yet. It's added after 3 confirmations; you can leave this screen."; "lightning__spark_deposits_claimed" = "Dipòsits reclamats"; "lightning__spark_deposits_pending" = "Dipòsits en curs"; "lightning__spark_provider" = "Proveïdor"; diff --git a/Bitkit/Resources/Localization/cs.lproj/Localizable.strings b/Bitkit/Resources/Localization/cs.lproj/Localizable.strings index 0bdf79f47e..d3a550b904 100644 --- a/Bitkit/Resources/Localization/cs.lproj/Localizable.strings +++ b/Bitkit/Resources/Localization/cs.lproj/Localizable.strings @@ -303,7 +303,6 @@ "lightning__setting_up_step1" = "Zpracování platby"; "lightning__setting_up_step2" = "Platba úspěšně proběhla"; "lightning__setting_up_step_spark" = "Adding To Spending"; -"lightning__setting_up_speed" = "Speed: {speed}"; "lightning__setting_up_button" = "Pokračujte v používání Bitkit"; "lightning__node_info" = "Lightning uzel"; "lightning__node_id" = "ID uzlu LDK"; @@ -351,21 +350,14 @@ "lightning__spark_deposit" = "Vklad"; "lightning__spark_deposit__choice" = "Spark ji může připsat {when} za vyšší poplatek, nebo po {standard} potvrzeních, asi za {minutes} minut."; "lightning__spark_deposit__claim_early" = "Použít {when}"; -"lightning__spark_deposit__claimed" = "Spark ji připisuje na váš zůstatek k utrácení."; "lightning__spark_deposit__early_fee" = "Poplatek za použití {when}"; "lightning__spark_deposit__later" = "po {count} potvrzeních"; "lightning__spark_deposit__later_one" = "po 1 potvrzení"; -"lightning__spark_deposit__looking" = "Čekáme, až Spark uvidí váš převod."; "lightning__spark_deposit__now" = "hned"; -"lightning__spark_deposit__standard" = "Spark ji připíše na váš zůstatek k utrácení po {standard} potvrzeních, asi za {minutes} minut."; "lightning__spark_deposit__standard_fee" = "Poplatek za čekání"; "lightning__spark_deposit__wait_button" = "Počkat"; "lightning__spark_deposit__waiting" = "Spark ji připíše na váš zůstatek k utrácení {when}."; "lightning__spark_deposit__waiting_next" = "Spark ji připíše na váš zůstatek k utrácení po dalším potvrzení."; -"lightning__spark_deposit__repriced" = "Instant now costs {fee}. Pay it to add your transfer now, or wait for 3 confirmations, about 30 minutes."; -"lightning__spark_deposit__pay" = "Pay {fee}"; -"lightning__spark_deposit__instant_unavailable" = "Instant isn't available for this transfer. Spark adds it to your spending balance after 3 confirmations, about 30 minutes."; -"lightning__spark_deposit__not_seen" = "Spark hasn't seen your transfer yet. It's added after 3 confirmations; you can leave this screen."; "lightning__spark_deposits_claimed" = "Připsané vklady"; "lightning__spark_deposits_pending" = "Probíhající vklady"; "lightning__spark_provider" = "Poskytovatel"; diff --git a/Bitkit/Resources/Localization/de.lproj/Localizable.strings b/Bitkit/Resources/Localization/de.lproj/Localizable.strings index 703d383c72..306bd7e675 100644 --- a/Bitkit/Resources/Localization/de.lproj/Localizable.strings +++ b/Bitkit/Resources/Localization/de.lproj/Localizable.strings @@ -301,7 +301,6 @@ "lightning__setting_up_step1" = "Zahlung wird verarbeitet"; "lightning__setting_up_step2" = "Zahlung erfolgreich"; "lightning__setting_up_step_spark" = "Adding To Spending"; -"lightning__setting_up_speed" = "Speed: {speed}"; "lightning__setting_up_button" = "Bitkit weiter verwenden"; "lightning__node_info" = "Lightning Node"; "lightning__node_id" = "LDK Node ID"; @@ -349,21 +348,14 @@ "lightning__spark_deposit" = "Einzahlung"; "lightning__spark_deposit__choice" = "Spark kann es {when} gegen eine höhere Gebühr gutschreiben, oder nach {standard} Bestätigungen, in etwa {minutes} Minuten."; "lightning__spark_deposit__claim_early" = "{when} nutzen"; -"lightning__spark_deposit__claimed" = "Spark schreibt es deinem Ausgabenguthaben gut."; "lightning__spark_deposit__early_fee" = "Gebühr für {when}"; "lightning__spark_deposit__later" = "nach {count} Bestätigungen"; "lightning__spark_deposit__later_one" = "nach 1 Bestätigung"; -"lightning__spark_deposit__looking" = "Warte, bis Spark deine Überweisung sieht."; "lightning__spark_deposit__now" = "sofort"; -"lightning__spark_deposit__standard" = "Spark schreibt es deinem Ausgabenguthaben nach {standard} Bestätigungen gut, in etwa {minutes} Minuten."; "lightning__spark_deposit__standard_fee" = "Gebühr fürs Warten"; "lightning__spark_deposit__wait_button" = "Warten"; "lightning__spark_deposit__waiting" = "Spark schreibt es deinem Ausgabenguthaben {when} gut."; "lightning__spark_deposit__waiting_next" = "Spark schreibt es deinem Ausgabenguthaben nach der nächsten Bestätigung gut."; -"lightning__spark_deposit__repriced" = "Instant now costs {fee}. Pay it to add your transfer now, or wait for 3 confirmations, about 30 minutes."; -"lightning__spark_deposit__pay" = "Pay {fee}"; -"lightning__spark_deposit__instant_unavailable" = "Instant isn't available for this transfer. Spark adds it to your spending balance after 3 confirmations, about 30 minutes."; -"lightning__spark_deposit__not_seen" = "Spark hasn't seen your transfer yet. It's added after 3 confirmations; you can leave this screen."; "lightning__spark_deposits_claimed" = "Eingelöste Einzahlungen"; "lightning__spark_deposits_pending" = "Laufende Einzahlungen"; "lightning__spark_provider" = "Anbieter"; diff --git a/Bitkit/Resources/Localization/el.lproj/Localizable.strings b/Bitkit/Resources/Localization/el.lproj/Localizable.strings index 636fad0bcc..1b28d7f6bb 100644 --- a/Bitkit/Resources/Localization/el.lproj/Localizable.strings +++ b/Bitkit/Resources/Localization/el.lproj/Localizable.strings @@ -287,7 +287,6 @@ "lightning__setting_up_step1" = "Επεξεργασία Πληρωμής"; "lightning__setting_up_step2" = "Επιτυχής Πληρωμή"; "lightning__setting_up_step_spark" = "Adding To Spending"; -"lightning__setting_up_speed" = "Speed: {speed}"; "lightning__setting_up_button" = "Συνεχίστε να Χρησιμοποιείτε το Bitkit"; "lightning__node_info" = "Κόμβος Lightning"; "lightning__node_disconnected" = "αποσυνδεδεμένο"; @@ -322,21 +321,14 @@ "lightning__spark_deposit" = "Κατάθεση"; "lightning__spark_deposit__choice" = "Το Spark μπορεί να το προσθέσει {when} με υψηλότερη χρέωση, ή μετά από {standard} επιβεβαιώσεις, σε περίπου {minutes} λεπτά."; "lightning__spark_deposit__claim_early" = "Χρήση {when}"; -"lightning__spark_deposit__claimed" = "Το Spark το προσθέτει στο υπόλοιπο δαπανών σας."; "lightning__spark_deposit__early_fee" = "Χρέωση για χρήση {when}"; "lightning__spark_deposit__later" = "μετά από {count} επιβεβαιώσεις"; "lightning__spark_deposit__later_one" = "μετά από 1 επιβεβαίωση"; -"lightning__spark_deposit__looking" = "Αναμονή για να δει το Spark τη μεταφορά σας."; "lightning__spark_deposit__now" = "τώρα"; -"lightning__spark_deposit__standard" = "Το Spark το προσθέτει στο υπόλοιπο δαπανών σας μετά από {standard} επιβεβαιώσεις, σε περίπου {minutes} λεπτά."; "lightning__spark_deposit__standard_fee" = "Χρέωση αναμονής"; "lightning__spark_deposit__wait_button" = "Αναμονή"; "lightning__spark_deposit__waiting" = "Το Spark το προσθέτει στο υπόλοιπο δαπανών σας {when}."; "lightning__spark_deposit__waiting_next" = "Το Spark το προσθέτει στο υπόλοιπο δαπανών σας μετά την επόμενη επιβεβαίωση."; -"lightning__spark_deposit__repriced" = "Instant now costs {fee}. Pay it to add your transfer now, or wait for 3 confirmations, about 30 minutes."; -"lightning__spark_deposit__pay" = "Pay {fee}"; -"lightning__spark_deposit__instant_unavailable" = "Instant isn't available for this transfer. Spark adds it to your spending balance after 3 confirmations, about 30 minutes."; -"lightning__spark_deposit__not_seen" = "Spark hasn't seen your transfer yet. It's added after 3 confirmations; you can leave this screen."; "lightning__spark_deposits_claimed" = "Εξαργυρωμένες καταθέσεις"; "lightning__spark_deposits_pending" = "Καταθέσεις σε εξέλιξη"; "lightning__spark_provider" = "Πάροχος"; diff --git a/Bitkit/Resources/Localization/en.lproj/Localizable.strings b/Bitkit/Resources/Localization/en.lproj/Localizable.strings index 39207d68b0..0642c0fcf7 100644 --- a/Bitkit/Resources/Localization/en.lproj/Localizable.strings +++ b/Bitkit/Resources/Localization/en.lproj/Localizable.strings @@ -297,9 +297,17 @@ "lightning__setting_up_header" = "In transfer"; "lightning__setting_up_step1" = "Processing Payment"; "lightning__setting_up_step2" = "Payment Successful"; -"lightning__setting_up_step_spark" = "Adding To Spending"; -"lightning__setting_up_speed" = "Speed: {speed}"; +"lightning__setting_up_step_spark" = "Adding To Spending Balance"; "lightning__setting_up_button" = "Continue Using Bitkit"; +"lightning__setting_up__text_fast" = "Please wait, your funds transfer is in progress. This should take a few minutes."; +"lightning__setting_up__text_normal" = "Please wait, your funds transfer is in progress. This should take about 30 minutes."; +"lightning__setting_up__fee_changed_title" = "Fast transfer\nfee changed"; +"lightning__setting_up__fee_changed_text" = "The fast transfer fee is now {fee}. Approve to access your funds quickly, or wait ±30 min."; +"lightning__setting_up__unavailable_title" = "Fast transfer\nunavailable"; +"lightning__setting_up__step_fee_changed" = "Fast Transfer Fee Changed"; +"lightning__setting_up__step_normal_speed" = "Using Normal Transfer Speed"; +"lightning__setting_up__approve" = "Approve"; +"lightning__setting_up__success_button" = "Awesome!"; "lightning__node_info" = "Lightning Node"; "lightning__node_id" = "LDK Node ID"; "lightning__node_disconnected" = "disconnected"; @@ -369,21 +377,14 @@ "lightning__spark_deposit" = "Deposit"; "lightning__spark_deposit__choice" = "Spark can add it {when} for a higher fee, or after {standard} confirmations, about {minutes} minutes."; "lightning__spark_deposit__claim_early" = "Use {when}"; -"lightning__spark_deposit__claimed" = "Spark is adding it to your spending balance."; "lightning__spark_deposit__early_fee" = "Fee to use {when}"; "lightning__spark_deposit__later" = "after {count} confirmations"; "lightning__spark_deposit__later_one" = "after 1 confirmation"; -"lightning__spark_deposit__looking" = "Waiting for Spark to see your transfer."; "lightning__spark_deposit__now" = "now"; -"lightning__spark_deposit__standard" = "Spark adds it to your spending balance after {standard} confirmations, about {minutes} minutes."; "lightning__spark_deposit__standard_fee" = "Fee to wait"; "lightning__spark_deposit__wait_button" = "Wait"; "lightning__spark_deposit__waiting" = "Spark adds it to your spending balance {when}."; "lightning__spark_deposit__waiting_next" = "Spark adds it to your spending balance after the next confirmation."; -"lightning__spark_deposit__repriced" = "Instant now costs {fee}. Pay it to add your transfer now, or wait for 3 confirmations, about 30 minutes."; -"lightning__spark_deposit__pay" = "Pay {fee}"; -"lightning__spark_deposit__instant_unavailable" = "Instant isn't available for this transfer. Spark adds it to your spending balance after 3 confirmations, about 30 minutes."; -"lightning__spark_deposit__not_seen" = "Spark hasn't seen your transfer yet. It's added after 3 confirmations; you can leave this screen."; "lightning__spark_deposits_claimed" = "Claimed deposits"; "lightning__spark_deposits_pending" = "Deposits in progress"; "lightning__spark_provider" = "Provider"; diff --git a/Bitkit/Resources/Localization/es-419.lproj/Localizable.strings b/Bitkit/Resources/Localization/es-419.lproj/Localizable.strings index 3496976a69..215bc8e61c 100644 --- a/Bitkit/Resources/Localization/es-419.lproj/Localizable.strings +++ b/Bitkit/Resources/Localization/es-419.lproj/Localizable.strings @@ -304,7 +304,6 @@ "lightning__setting_up_step1" = "Procesando pago"; "lightning__setting_up_step2" = "Pago Efectuado"; "lightning__setting_up_step_spark" = "Adding To Spending"; -"lightning__setting_up_speed" = "Speed: {speed}"; "lightning__setting_up_button" = "Continuar Usando Bitkit"; "lightning__node_info" = "Nodo Lightning"; "lightning__node_id" = "ID del nodo LDK"; @@ -352,21 +351,14 @@ "lightning__spark_deposit" = "Depósito"; "lightning__spark_deposit__choice" = "Spark puede agregarlo {when} por una comisión más alta, o después de {standard} confirmaciones, en unos {minutes} minutos."; "lightning__spark_deposit__claim_early" = "Usar {when}"; -"lightning__spark_deposit__claimed" = "Spark lo está agregando a tu saldo de gastos."; "lightning__spark_deposit__early_fee" = "Comisión para usar {when}"; "lightning__spark_deposit__later" = "después de {count} confirmaciones"; "lightning__spark_deposit__later_one" = "después de 1 confirmación"; -"lightning__spark_deposit__looking" = "Esperando a que Spark vea tu transferencia."; "lightning__spark_deposit__now" = "ahora"; -"lightning__spark_deposit__standard" = "Spark lo agrega a tu saldo de gastos después de {standard} confirmaciones, en unos {minutes} minutos."; "lightning__spark_deposit__standard_fee" = "Comisión por esperar"; "lightning__spark_deposit__wait_button" = "Esperar"; "lightning__spark_deposit__waiting" = "Spark lo agrega a tu saldo de gastos {when}."; "lightning__spark_deposit__waiting_next" = "Spark lo agrega a tu saldo de gastos después de la próxima confirmación."; -"lightning__spark_deposit__repriced" = "Instant now costs {fee}. Pay it to add your transfer now, or wait for 3 confirmations, about 30 minutes."; -"lightning__spark_deposit__pay" = "Pay {fee}"; -"lightning__spark_deposit__instant_unavailable" = "Instant isn't available for this transfer. Spark adds it to your spending balance after 3 confirmations, about 30 minutes."; -"lightning__spark_deposit__not_seen" = "Spark hasn't seen your transfer yet. It's added after 3 confirmations; you can leave this screen."; "lightning__spark_deposits_claimed" = "Depósitos reclamados"; "lightning__spark_deposits_pending" = "Depósitos en curso"; "lightning__spark_provider" = "Proveedor"; diff --git a/Bitkit/Resources/Localization/es.lproj/Localizable.strings b/Bitkit/Resources/Localization/es.lproj/Localizable.strings index 84565f8f1c..ddb0f478f3 100644 --- a/Bitkit/Resources/Localization/es.lproj/Localizable.strings +++ b/Bitkit/Resources/Localization/es.lproj/Localizable.strings @@ -291,7 +291,6 @@ "lightning__setting_up_step1" = "Procesando Pago"; "lightning__setting_up_step2" = "Pago Exitoso"; "lightning__setting_up_step_spark" = "Adding To Spending"; -"lightning__setting_up_speed" = "Speed: {speed}"; "lightning__setting_up_button" = "Continuar Usando Bitkit"; "lightning__node_info" = "Nodo Lightning"; "lightning__node_id" = "ID del nodo LDK"; @@ -336,21 +335,14 @@ "lightning__spark_deposit" = "Depósito"; "lightning__spark_deposit__choice" = "Spark puede añadirlo {when} por una comisión más alta, o tras {standard} confirmaciones, en unos {minutes} minutos."; "lightning__spark_deposit__claim_early" = "Usar {when}"; -"lightning__spark_deposit__claimed" = "Spark lo está añadiendo a tu saldo de gastos."; "lightning__spark_deposit__early_fee" = "Comisión para usar {when}"; "lightning__spark_deposit__later" = "tras {count} confirmaciones"; "lightning__spark_deposit__later_one" = "tras 1 confirmación"; -"lightning__spark_deposit__looking" = "Esperando a que Spark vea tu transferencia."; "lightning__spark_deposit__now" = "ahora"; -"lightning__spark_deposit__standard" = "Spark lo añade a tu saldo de gastos tras {standard} confirmaciones, en unos {minutes} minutos."; "lightning__spark_deposit__standard_fee" = "Comisión por esperar"; "lightning__spark_deposit__wait_button" = "Esperar"; "lightning__spark_deposit__waiting" = "Spark lo añade a tu saldo de gastos {when}."; "lightning__spark_deposit__waiting_next" = "Spark lo añade a tu saldo de gastos tras la próxima confirmación."; -"lightning__spark_deposit__repriced" = "Instant now costs {fee}. Pay it to add your transfer now, or wait for 3 confirmations, about 30 minutes."; -"lightning__spark_deposit__pay" = "Pay {fee}"; -"lightning__spark_deposit__instant_unavailable" = "Instant isn't available for this transfer. Spark adds it to your spending balance after 3 confirmations, about 30 minutes."; -"lightning__spark_deposit__not_seen" = "Spark hasn't seen your transfer yet. It's added after 3 confirmations; you can leave this screen."; "lightning__spark_deposits_claimed" = "Depósitos reclamados"; "lightning__spark_deposits_pending" = "Depósitos en curso"; "lightning__spark_provider" = "Proveedor"; diff --git a/Bitkit/Resources/Localization/fr.lproj/Localizable.strings b/Bitkit/Resources/Localization/fr.lproj/Localizable.strings index 63a31e9456..66e21dd189 100644 --- a/Bitkit/Resources/Localization/fr.lproj/Localizable.strings +++ b/Bitkit/Resources/Localization/fr.lproj/Localizable.strings @@ -304,7 +304,6 @@ "lightning__setting_up_step1" = "Traitement des paiements"; "lightning__setting_up_step2" = "Paiement réussi"; "lightning__setting_up_step_spark" = "Adding To Spending"; -"lightning__setting_up_speed" = "Speed: {speed}"; "lightning__setting_up_button" = "Continuer à utiliser Bitkit"; "lightning__node_info" = "Nœud Lightning"; "lightning__node_id" = "ID du nœud LDK"; @@ -352,21 +351,14 @@ "lightning__spark_deposit" = "Dépôt"; "lightning__spark_deposit__choice" = "Spark peut l'ajouter {when} pour des frais plus élevés, ou après {standard} confirmations, dans environ {minutes} minutes."; "lightning__spark_deposit__claim_early" = "Utiliser {when}"; -"lightning__spark_deposit__claimed" = "Spark l'ajoute à votre solde de dépenses."; "lightning__spark_deposit__early_fee" = "Frais pour l'utiliser {when}"; "lightning__spark_deposit__later" = "après {count} confirmations"; "lightning__spark_deposit__later_one" = "après 1 confirmation"; -"lightning__spark_deposit__looking" = "En attente que Spark voie votre transfert."; "lightning__spark_deposit__now" = "maintenant"; -"lightning__spark_deposit__standard" = "Spark l'ajoute à votre solde de dépenses après {standard} confirmations, dans environ {minutes} minutes."; "lightning__spark_deposit__standard_fee" = "Frais d'attente"; "lightning__spark_deposit__wait_button" = "Attendre"; "lightning__spark_deposit__waiting" = "Spark l'ajoute à votre solde de dépenses {when}."; "lightning__spark_deposit__waiting_next" = "Spark l'ajoute à votre solde de dépenses après la prochaine confirmation."; -"lightning__spark_deposit__repriced" = "Instant now costs {fee}. Pay it to add your transfer now, or wait for 3 confirmations, about 30 minutes."; -"lightning__spark_deposit__pay" = "Pay {fee}"; -"lightning__spark_deposit__instant_unavailable" = "Instant isn't available for this transfer. Spark adds it to your spending balance after 3 confirmations, about 30 minutes."; -"lightning__spark_deposit__not_seen" = "Spark hasn't seen your transfer yet. It's added after 3 confirmations; you can leave this screen."; "lightning__spark_deposits_claimed" = "Dépôts réclamés"; "lightning__spark_deposits_pending" = "Dépôts en cours"; "lightning__spark_provider" = "Fournisseur"; diff --git a/Bitkit/Resources/Localization/it.lproj/Localizable.strings b/Bitkit/Resources/Localization/it.lproj/Localizable.strings index 15279da983..46849a3d11 100644 --- a/Bitkit/Resources/Localization/it.lproj/Localizable.strings +++ b/Bitkit/Resources/Localization/it.lproj/Localizable.strings @@ -298,7 +298,6 @@ "lightning__setting_up_step1" = "Elaborazione del pagamento"; "lightning__setting_up_step2" = "Pagamento Riuscito"; "lightning__setting_up_step_spark" = "Adding To Spending"; -"lightning__setting_up_speed" = "Speed: {speed}"; "lightning__setting_up_button" = "Continua ad utilizzare Bitkit"; "lightning__node_info" = "Nodo Lightning"; "lightning__node_id" = "ID Nodo LDK"; @@ -345,21 +344,14 @@ "lightning__spark_deposit" = "Deposito"; "lightning__spark_deposit__choice" = "Spark può aggiungerlo {when} con una commissione più alta, oppure dopo {standard} conferme, tra circa {minutes} minuti."; "lightning__spark_deposit__claim_early" = "Usa {when}"; -"lightning__spark_deposit__claimed" = "Spark lo sta aggiungendo al tuo saldo di spesa."; "lightning__spark_deposit__early_fee" = "Commissione per usarlo {when}"; "lightning__spark_deposit__later" = "dopo {count} conferme"; "lightning__spark_deposit__later_one" = "dopo 1 conferma"; -"lightning__spark_deposit__looking" = "In attesa che Spark veda il tuo trasferimento."; "lightning__spark_deposit__now" = "ora"; -"lightning__spark_deposit__standard" = "Spark lo aggiunge al tuo saldo di spesa dopo {standard} conferme, tra circa {minutes} minuti."; "lightning__spark_deposit__standard_fee" = "Commissione per l'attesa"; "lightning__spark_deposit__wait_button" = "Attendi"; "lightning__spark_deposit__waiting" = "Spark lo aggiunge al tuo saldo di spesa {when}."; "lightning__spark_deposit__waiting_next" = "Spark lo aggiunge al tuo saldo di spesa dopo la prossima conferma."; -"lightning__spark_deposit__repriced" = "Instant now costs {fee}. Pay it to add your transfer now, or wait for 3 confirmations, about 30 minutes."; -"lightning__spark_deposit__pay" = "Pay {fee}"; -"lightning__spark_deposit__instant_unavailable" = "Instant isn't available for this transfer. Spark adds it to your spending balance after 3 confirmations, about 30 minutes."; -"lightning__spark_deposit__not_seen" = "Spark hasn't seen your transfer yet. It's added after 3 confirmations; you can leave this screen."; "lightning__spark_deposits_claimed" = "Depositi riscattati"; "lightning__spark_deposits_pending" = "Depositi in corso"; "lightning__spark_provider" = "Fornitore"; diff --git a/Bitkit/Resources/Localization/nl.lproj/Localizable.strings b/Bitkit/Resources/Localization/nl.lproj/Localizable.strings index 818c1d9a02..f9e783a7c2 100644 --- a/Bitkit/Resources/Localization/nl.lproj/Localizable.strings +++ b/Bitkit/Resources/Localization/nl.lproj/Localizable.strings @@ -301,7 +301,6 @@ "lightning__setting_up_step1" = "Betaling Verwerken"; "lightning__setting_up_step2" = "Betaling Voltooid"; "lightning__setting_up_step_spark" = "Adding To Spending"; -"lightning__setting_up_speed" = "Speed: {speed}"; "lightning__setting_up_button" = "Ga Door Met Bitkit"; "lightning__node_info" = "Lightning Node"; "lightning__node_id" = "LDK Node ID"; @@ -349,21 +348,14 @@ "lightning__spark_deposit" = "Storting"; "lightning__spark_deposit__choice" = "Spark kan het {when} toevoegen voor een hogere vergoeding, of na {standard} bevestigingen, over ongeveer {minutes} minuten."; "lightning__spark_deposit__claim_early" = "{when} gebruiken"; -"lightning__spark_deposit__claimed" = "Spark voegt het toe aan je bestedingssaldo."; "lightning__spark_deposit__early_fee" = "Vergoeding om {when} te gebruiken"; "lightning__spark_deposit__later" = "na {count} bevestigingen"; "lightning__spark_deposit__later_one" = "na 1 bevestiging"; -"lightning__spark_deposit__looking" = "Wachten tot Spark je overboeking ziet."; "lightning__spark_deposit__now" = "nu"; -"lightning__spark_deposit__standard" = "Spark voegt het na {standard} bevestigingen toe aan je bestedingssaldo, over ongeveer {minutes} minuten."; "lightning__spark_deposit__standard_fee" = "Vergoeding om te wachten"; "lightning__spark_deposit__wait_button" = "Wachten"; "lightning__spark_deposit__waiting" = "Spark voegt het {when} toe aan je bestedingssaldo."; "lightning__spark_deposit__waiting_next" = "Spark voegt het na de volgende bevestiging toe aan je bestedingssaldo."; -"lightning__spark_deposit__repriced" = "Instant now costs {fee}. Pay it to add your transfer now, or wait for 3 confirmations, about 30 minutes."; -"lightning__spark_deposit__pay" = "Pay {fee}"; -"lightning__spark_deposit__instant_unavailable" = "Instant isn't available for this transfer. Spark adds it to your spending balance after 3 confirmations, about 30 minutes."; -"lightning__spark_deposit__not_seen" = "Spark hasn't seen your transfer yet. It's added after 3 confirmations; you can leave this screen."; "lightning__spark_deposits_claimed" = "Geclaimde stortingen"; "lightning__spark_deposits_pending" = "Lopende stortingen"; "lightning__spark_provider" = "Aanbieder"; diff --git a/Bitkit/Resources/Localization/pl.lproj/Localizable.strings b/Bitkit/Resources/Localization/pl.lproj/Localizable.strings index b0a449adc8..74e4b511b9 100644 --- a/Bitkit/Resources/Localization/pl.lproj/Localizable.strings +++ b/Bitkit/Resources/Localization/pl.lproj/Localizable.strings @@ -303,7 +303,6 @@ "lightning__setting_up_step1" = "Przetwarzanie płatności"; "lightning__setting_up_step2" = "Płatność powiodła się"; "lightning__setting_up_step_spark" = "Adding To Spending"; -"lightning__setting_up_speed" = "Speed: {speed}"; "lightning__setting_up_button" = "Kontunuuj korzystanie z Bitkit\'a"; "lightning__node_info" = "Węzeł Lightning"; "lightning__node_id" = "Identyfikator węzła LDK"; @@ -351,21 +350,14 @@ "lightning__spark_deposit" = "Wpłata"; "lightning__spark_deposit__choice" = "Spark może je dodać {when} za wyższą opłatą albo po {standard} potwierdzeniach, za około {minutes} minut."; "lightning__spark_deposit__claim_early" = "Użyj {when}"; -"lightning__spark_deposit__claimed" = "Spark dodaje je do Twojego salda wydatków."; "lightning__spark_deposit__early_fee" = "Opłata za użycie {when}"; "lightning__spark_deposit__later" = "po {count} potwierdzeniach"; "lightning__spark_deposit__later_one" = "po 1 potwierdzeniu"; -"lightning__spark_deposit__looking" = "Czekamy, aż Spark zobaczy Twój przelew."; "lightning__spark_deposit__now" = "teraz"; -"lightning__spark_deposit__standard" = "Spark doda je do Twojego salda wydatków po {standard} potwierdzeniach, za około {minutes} minut."; "lightning__spark_deposit__standard_fee" = "Opłata za czekanie"; "lightning__spark_deposit__wait_button" = "Czekaj"; "lightning__spark_deposit__waiting" = "Spark doda je do Twojego salda wydatków {when}."; "lightning__spark_deposit__waiting_next" = "Spark doda je do Twojego salda wydatków po następnym potwierdzeniu."; -"lightning__spark_deposit__repriced" = "Instant now costs {fee}. Pay it to add your transfer now, or wait for 3 confirmations, about 30 minutes."; -"lightning__spark_deposit__pay" = "Pay {fee}"; -"lightning__spark_deposit__instant_unavailable" = "Instant isn't available for this transfer. Spark adds it to your spending balance after 3 confirmations, about 30 minutes."; -"lightning__spark_deposit__not_seen" = "Spark hasn't seen your transfer yet. It's added after 3 confirmations; you can leave this screen."; "lightning__spark_deposits_claimed" = "Odebrane wpłaty"; "lightning__spark_deposits_pending" = "Wpłaty w toku"; "lightning__spark_provider" = "Dostawca"; diff --git a/Bitkit/Resources/Localization/pt-BR.lproj/Localizable.strings b/Bitkit/Resources/Localization/pt-BR.lproj/Localizable.strings index 5f26f8da9f..64a5758da0 100644 --- a/Bitkit/Resources/Localization/pt-BR.lproj/Localizable.strings +++ b/Bitkit/Resources/Localization/pt-BR.lproj/Localizable.strings @@ -303,7 +303,6 @@ "lightning__setting_up_step1" = "Processando Pagamento"; "lightning__setting_up_step2" = "Pagamento Realizado"; "lightning__setting_up_step_spark" = "Adding To Spending"; -"lightning__setting_up_speed" = "Speed: {speed}"; "lightning__setting_up_button" = "Continuar Usando o Bitkit"; "lightning__node_info" = "Nó Lightning"; "lightning__node_id" = "ID do LDK Node "; @@ -351,21 +350,14 @@ "lightning__spark_deposit" = "Depósito"; "lightning__spark_deposit__choice" = "A Spark pode adicionar {when} por uma taxa maior, ou após {standard} confirmações, em cerca de {minutes} minutos."; "lightning__spark_deposit__claim_early" = "Usar {when}"; -"lightning__spark_deposit__claimed" = "A Spark está adicionando ao seu saldo de gastos."; "lightning__spark_deposit__early_fee" = "Taxa para usar {when}"; "lightning__spark_deposit__later" = "após {count} confirmações"; "lightning__spark_deposit__later_one" = "após 1 confirmação"; -"lightning__spark_deposit__looking" = "Aguardando a Spark ver sua transferência."; "lightning__spark_deposit__now" = "agora"; -"lightning__spark_deposit__standard" = "A Spark adiciona ao seu saldo de gastos após {standard} confirmações, em cerca de {minutes} minutos."; "lightning__spark_deposit__standard_fee" = "Taxa para esperar"; "lightning__spark_deposit__wait_button" = "Esperar"; "lightning__spark_deposit__waiting" = "A Spark adiciona ao seu saldo de gastos {when}."; "lightning__spark_deposit__waiting_next" = "A Spark adiciona ao seu saldo de gastos após a próxima confirmação."; -"lightning__spark_deposit__repriced" = "Instant now costs {fee}. Pay it to add your transfer now, or wait for 3 confirmations, about 30 minutes."; -"lightning__spark_deposit__pay" = "Pay {fee}"; -"lightning__spark_deposit__instant_unavailable" = "Instant isn't available for this transfer. Spark adds it to your spending balance after 3 confirmations, about 30 minutes."; -"lightning__spark_deposit__not_seen" = "Spark hasn't seen your transfer yet. It's added after 3 confirmations; you can leave this screen."; "lightning__spark_deposits_claimed" = "Depósitos resgatados"; "lightning__spark_deposits_pending" = "Depósitos em andamento"; "lightning__spark_provider" = "Provedor"; diff --git a/Bitkit/Resources/Localization/pt.lproj/Localizable.strings b/Bitkit/Resources/Localization/pt.lproj/Localizable.strings index 7f3d955144..492d19e7cf 100644 --- a/Bitkit/Resources/Localization/pt.lproj/Localizable.strings +++ b/Bitkit/Resources/Localization/pt.lproj/Localizable.strings @@ -315,7 +315,6 @@ "lightning__setting_up_step1" = "Processando Pagamento"; "lightning__setting_up_step2" = "Pagamento Realizado"; "lightning__setting_up_step_spark" = "Adding To Spending"; -"lightning__setting_up_speed" = "Speed: {speed}"; "lightning__setting_up_button" = "Continuar Usando o Bitkit"; "lightning__node_info" = "Nó Lightning"; "lightning__connections" = "Conexões Lightning"; @@ -349,21 +348,14 @@ "lightning__spark_deposit" = "Depósito"; "lightning__spark_deposit__choice" = "A Spark pode adicioná-lo {when} por uma taxa mais alta, ou após {standard} confirmações, dentro de cerca de {minutes} minutos."; "lightning__spark_deposit__claim_early" = "Usar {when}"; -"lightning__spark_deposit__claimed" = "A Spark está a adicioná-lo ao seu saldo de gastos."; "lightning__spark_deposit__early_fee" = "Taxa para usar {when}"; "lightning__spark_deposit__later" = "após {count} confirmações"; "lightning__spark_deposit__later_one" = "após 1 confirmação"; -"lightning__spark_deposit__looking" = "A aguardar que a Spark veja a sua transferência."; "lightning__spark_deposit__now" = "agora"; -"lightning__spark_deposit__standard" = "A Spark adiciona-o ao seu saldo de gastos após {standard} confirmações, dentro de cerca de {minutes} minutos."; "lightning__spark_deposit__standard_fee" = "Taxa para esperar"; "lightning__spark_deposit__wait_button" = "Esperar"; "lightning__spark_deposit__waiting" = "A Spark adiciona-o ao seu saldo de gastos {when}."; "lightning__spark_deposit__waiting_next" = "A Spark adiciona-o ao seu saldo de gastos após a próxima confirmação."; -"lightning__spark_deposit__repriced" = "Instant now costs {fee}. Pay it to add your transfer now, or wait for 3 confirmations, about 30 minutes."; -"lightning__spark_deposit__pay" = "Pay {fee}"; -"lightning__spark_deposit__instant_unavailable" = "Instant isn't available for this transfer. Spark adds it to your spending balance after 3 confirmations, about 30 minutes."; -"lightning__spark_deposit__not_seen" = "Spark hasn't seen your transfer yet. It's added after 3 confirmations; you can leave this screen."; "lightning__spark_deposits_claimed" = "Depósitos resgatados"; "lightning__spark_deposits_pending" = "Depósitos em curso"; "lightning__spark_provider" = "Fornecedor"; diff --git a/Bitkit/Resources/Localization/ru.lproj/Localizable.strings b/Bitkit/Resources/Localization/ru.lproj/Localizable.strings index a6946a0a0f..df245a582b 100644 --- a/Bitkit/Resources/Localization/ru.lproj/Localizable.strings +++ b/Bitkit/Resources/Localization/ru.lproj/Localizable.strings @@ -299,7 +299,6 @@ "lightning__setting_up_step1" = "Обработка Платежа"; "lightning__setting_up_step2" = "Платеж Успешен"; "lightning__setting_up_step_spark" = "Adding To Spending"; -"lightning__setting_up_speed" = "Speed: {speed}"; "lightning__setting_up_button" = "Продолжить Использование Bitkit"; "lightning__node_info" = "Lightning Узел"; "lightning__node_id" = "ID Узла LDK"; @@ -346,21 +345,14 @@ "lightning__spark_deposit" = "Депозит"; "lightning__spark_deposit__choice" = "Spark может зачислить их {when} за более высокую комиссию или после {standard} подтверждений, примерно через {minutes} минут."; "lightning__spark_deposit__claim_early" = "Использовать {when}"; -"lightning__spark_deposit__claimed" = "Spark зачисляет их на ваш расходный баланс."; "lightning__spark_deposit__early_fee" = "Комиссия, чтобы использовать {when}"; "lightning__spark_deposit__later" = "после {count} подтверждений"; "lightning__spark_deposit__later_one" = "после 1 подтверждения"; -"lightning__spark_deposit__looking" = "Ждём, пока Spark увидит ваш перевод."; "lightning__spark_deposit__now" = "сейчас"; -"lightning__spark_deposit__standard" = "Spark зачислит их на ваш расходный баланс после {standard} подтверждений, примерно через {minutes} минут."; "lightning__spark_deposit__standard_fee" = "Комиссия за ожидание"; "lightning__spark_deposit__wait_button" = "Ждать"; "lightning__spark_deposit__waiting" = "Spark зачислит их на ваш расходный баланс {when}."; "lightning__spark_deposit__waiting_next" = "Spark зачислит их на ваш расходный баланс после следующего подтверждения."; -"lightning__spark_deposit__repriced" = "Instant now costs {fee}. Pay it to add your transfer now, or wait for 3 confirmations, about 30 minutes."; -"lightning__spark_deposit__pay" = "Pay {fee}"; -"lightning__spark_deposit__instant_unavailable" = "Instant isn't available for this transfer. Spark adds it to your spending balance after 3 confirmations, about 30 minutes."; -"lightning__spark_deposit__not_seen" = "Spark hasn't seen your transfer yet. It's added after 3 confirmations; you can leave this screen."; "lightning__spark_deposits_claimed" = "Зачисленные депозиты"; "lightning__spark_deposits_pending" = "Депозиты в обработке"; "lightning__spark_provider" = "Провайдер"; diff --git a/Bitkit/Views/Transfer/SettingUpView.swift b/Bitkit/Views/Transfer/SettingUpView.swift index 9b23da6ffe..6ee5a17703 100644 --- a/Bitkit/Views/Transfer/SettingUpView.swift +++ b/Bitkit/Views/Transfer/SettingUpView.swift @@ -1,83 +1,110 @@ import SwiftUI -struct SettingUpView: View { - @EnvironmentObject var currency: CurrencyViewModel - @EnvironmentObject var navigation: NavigationViewModel - @Environment(SparkTransferFlow.self) private var flow - - /// Keep in state so we don't get a new random text on each render - @State private var randomOkText: String = localizedRandom("common__ok_random") - - private var state: SparkClaimState { - flow.claimState +/// What the transfer status screen shows: one per frame of the Funds In Transfer (spark) design. +enum SettingUpStage: Equatable { + /// Spark has not seen the deposit yet; `normalSpeed` when it is added after 3 confirmations. + case processing(normalSpeed: Bool) + /// Spark has seen the deposit. + case received + /// The fast transfer fee rose above what the user approved. + case feeChanged(feeSats: UInt64) + /// No fast transfer for this deposit, so it is added at normal speed. + case fastUnavailable + /// Spark is adding the deposit to the spending balance; `normalSpeed` once the user chose to wait. + case adding(normalSpeed: Bool) + /// The deposit reached the spending balance. + case done + + /// `approvedFee` once the user approved a changed fee, so the claim that follows doesn't step back to Received. + init(state: SparkClaimState, speed: SparkTransferSpeed, approvedFee: Bool = false) { + self = switch state { + case .looking: .processing(normalSpeed: speed == .later) + case .notSeen: .processing(normalSpeed: true) + case .later: speed == .later ? .processing(normalSpeed: true) : .adding(normalSpeed: true) + case .claiming: approvedFee ? .adding(normalSpeed: false) : .received + case .adding: .adding(normalSpeed: false) + case let .repriced(feeSats): .feeChanged(feeSats: feeSats) + case .unavailable: .fastUnavailable + case .added: .done + } } - var isTransferring: Bool { - !state.isDone + /// The index of the step in progress. + var currentStep: Int { + switch self { + case .processing: 0 + case .received: 1 + case .feeChanged, .fastUnavailable, .adding, .done: 2 + } } - var navTitle: String { - isTransferring ? t("lightning__transfer__nav_title") : t("lightning__transfer_success__nav_title") + /// Processing Payment, Payment Successful, then what the last step is doing. + var steps: [String] { + let last = switch self { + case .feeChanged: t("lightning__setting_up__step_fee_changed") + case .fastUnavailable, .adding(normalSpeed: true): t("lightning__setting_up__step_normal_speed") + default: t("lightning__setting_up_step_spark") + } + return [t("lightning__setting_up_step1"), t("lightning__setting_up_step2"), last] } var title: String { - isTransferring ? t("lightning__savings_progress__title") : t("lightning__transfer_success__title_spending") + switch self { + case .feeChanged: t("lightning__setting_up__fee_changed_title") + case .fastUnavailable: t("lightning__setting_up__unavailable_title") + case .done: t("lightning__transfer_success__title_spending") + default: t("lightning__savings_progress__title") + } } - var text: String { - guard isTransferring else { return t("lightning__transfer_success__text_spending") } - return switch state { - case .looking: t("lightning__spark_deposit__looking") - case .claiming, .adding, .added: t("lightning__spark_deposit__claimed") - case let .repriced(feeSats): t("lightning__spark_deposit__repriced", variables: ["fee": currency.primaryAmountText(sats: feeSats)]) - case .unavailable: t("lightning__spark_deposit__instant_unavailable") - case .later: t("lightning__spark_deposit__standard", variables: [ - "standard": "\(SparkTransferFlow.matureConfirmations)", - "minutes": "\(SparkTransferFlow.matureMinutes)", - ]) - case .notSeen: t("lightning__spark_deposit__not_seen") + /// Whether the text says about 30 minutes rather than a few minutes. + var isNormalSpeed: Bool { + switch self { + case .processing(normalSpeed: true), .adding(normalSpeed: true), .fastUnavailable: true + default: false } } - /// The speed the user chose, or Later once they chose to wait. - var speedText: String { - t("lightning__setting_up_speed", variables: [ - "speed": Self.showsLater(speed: flow.speed, state: state) ? t("lightning__spending_confirm__later") : t("fee__instant__title"), - ]) + /// Coins while the fast transfer is in question, the transfer arrows otherwise. + var showsCoins: Bool { + switch self { + case .feeChanged, .fastUnavailable: true + default: false + } } +} - /// Later too whenever the text says the deposit waits for confirmations. - static func showsLater(speed: SparkTransferSpeed, state: SparkClaimState) -> Bool { - speed == .later || state == .later || state == .unavailable || state == .notSeen - } +struct SettingUpView: View { + @EnvironmentObject var currency: CurrencyViewModel + @EnvironmentObject var navigation: NavigationViewModel + @Environment(SparkTransferFlow.self) private var flow + + @State private var approvedFee = false - var buttonTitle: String { - isTransferring ? t("lightning__setting_up_button") : randomOkText + private var stage: SettingUpStage { + SettingUpStage(state: flow.claimState, speed: flow.speed, approvedFee: approvedFee) } - /// Sent, seen by Spark, added to spending. - let steps = [ - t("lightning__setting_up_step1"), - t("lightning__setting_up_step2"), - t("lightning__setting_up_step_spark"), - ] - - /// The index of the step in progress; every step is done once the deposit is added. - static func currentStep(for state: SparkClaimState) -> Int { - switch state { - case .looking, .notSeen, .later: 1 - case .claiming, .adding, .repriced, .unavailable: 2 - case .added: 3 + var text: String { + switch stage { + case .done: t("lightning__transfer_success__text_spending") + case let .feeChanged(feeSats): + t("lightning__setting_up__fee_changed_text", variables: ["fee": currency.primaryAmountText(sats: feeSats)]) + default: stage.isNormalSpeed ? t("lightning__setting_up__text_normal") : t("lightning__setting_up__text_fast") } } var body: some View { + let stage = stage VStack(spacing: 0) { - NavigationBar(title: navTitle, showBackButton: false) - .padding(.bottom, 16) + NavigationBar( + title: stage == .done ? t("lightning__transfer_success__nav_title") : t("lightning__transfer__nav_title"), + showBackButton: false + ) + .padding(.bottom, 16) VStack(alignment: .leading, spacing: 0) { - DisplayText(title, accentColor: .purpleAccent) + DisplayText(stage.title, accentColor: .purpleAccent) .padding(.bottom, 8) .layoutPriority(1) @@ -85,38 +112,34 @@ struct SettingUpView: View { .layoutPriority(1) .accessibilityIdentifier("SettingUpText") - if isTransferring { - CaptionMText(speedText) - .padding(.top, 8) - .accessibilityIdentifier("SettingUpSpeed") - } - - if isTransferring { - EllipseLoader(variant: .transfer) - .padding(.top, 32) - .padding(.horizontal, 16) - .accessibilityIdentifier("LightningSettingUp") - } else { + if stage == .done { Image("check") .resizable() .aspectRatio(contentMode: .fit) - .frame(width: 256, height: 256) - .padding() - .frame(maxWidth: .infinity, maxHeight: .infinity) + // Drawn as in the design: 274pt, centred in a 256pt box 44pt below the text. + .frame(width: 274, height: 274) + .padding(.top, 35) + .frame(maxWidth: .infinity) .accessibilityIdentifier("TransferSuccess") + } else { + EllipseLoader(variant: stage.showsCoins ? .quickpay : .transfer) + .id(stage.showsCoins) + .padding(.top, 32) + .padding(.horizontal, 16) + .accessibilityIdentifier("LightningSettingUp") } Spacer() - if isTransferring { - ProgressSteps(steps: steps, currentStep: Self.currentStep(for: state)) + if stage != .done { + ProgressSteps(steps: stage.steps, currentStep: stage.currentStep) .padding(.vertical, 16) } - if case let .repriced(feeSats) = state { - repricedButtons(feeSats: feeSats) + if case .feeChanged = stage { + feeChangedButtons } else { - CustomButton(title: buttonTitle) { + CustomButton(title: stage == .done ? t("lightning__setting_up__success_button") : t("lightning__setting_up_button")) { navigation.reset() } .accessibilityIdentifier("TransferSuccess-button") @@ -133,14 +156,15 @@ struct SettingUpView: View { } } - private func repricedButtons(feeSats: UInt64) -> some View { + private var feeChangedButtons: some View { HStack(spacing: 16) { CustomButton(title: t("lightning__spark_deposit__wait_button"), variant: .secondary) { flow.waitForConfirmations() } .accessibilityIdentifier("SparkDepositWait") - CustomButton(title: t("lightning__spark_deposit__pay", variables: ["fee": currency.primaryAmountText(sats: feeSats)])) { + CustomButton(title: t("lightning__setting_up__approve")) { + approvedFee = true flow.payRepriced() } .accessibilityIdentifier("SparkDepositPay") @@ -148,45 +172,41 @@ struct SettingUpView: View { } } -#Preview("Looking") { +#Preview("Processing") { settingUpPreview(.looking) } -#Preview("Claiming") { - settingUpPreview(.claiming) +#Preview("Processing normal") { + settingUpPreview(.later, speed: .later) } -#Preview("Adding") { - settingUpPreview(.adding) -} - -#Preview("Done") { - settingUpPreview(.added) +#Preview("Payment successful") { + settingUpPreview(.claiming) } -#Preview("Repriced") { - settingUpPreview(.repriced(feeSats: 2150)) +#Preview("Fee changed") { + settingUpPreview(.repriced(feeSats: 2134)) } -#Preview("Instant unavailable") { +#Preview("Fast unavailable") { settingUpPreview(.unavailable) } -#Preview("Later") { - settingUpPreview(.later) +#Preview("Adding") { + settingUpPreview(.adding) } -#Preview("Not seen") { - settingUpPreview(.notSeen) +#Preview("Done") { + settingUpPreview(.added) } @MainActor -private func settingUpPreview(_ state: SparkClaimState) -> some View { +private func settingUpPreview(_ state: SparkClaimState, speed: SparkTransferSpeed = .instant) -> some View { NavigationStack { SettingUpView() .environmentObject(CurrencyViewModel()) .environmentObject(NavigationViewModel()) - .environment(SparkTransferFlow(amountSats: 100_000, claimState: state)) + .environment(SparkTransferFlow(amountSats: 100_000, speed: speed, claimState: state)) } .preferredColorScheme(.dark) } diff --git a/BitkitTests/SparkFundingRecoveryTests.swift b/BitkitTests/SparkFundingRecoveryTests.swift index 745eddbdf9..48a9119c1c 100644 --- a/BitkitTests/SparkFundingRecoveryTests.swift +++ b/BitkitTests/SparkFundingRecoveryTests.swift @@ -56,40 +56,42 @@ final class SparkFundingRecoveryTests: XCTestCase { XCTAssertTrue(SparkFundingRecovery.pendingScreenGoesHome(confirmScreenOpen: false)) } - func testSettingUpShowsLaterWheneverTheTextSaysItWaitsForConfirmations() { - for state in [SparkClaimState.later, .unavailable, .notSeen] { - XCTAssertTrue(SettingUpView.showsLater(speed: .instant, state: state), "\(state)") - } - for state in [SparkClaimState.looking, .claiming, .adding, .added, .repriced(feeSats: 1)] { - XCTAssertFalse(SettingUpView.showsLater(speed: .instant, state: state), "\(state)") + /// Every deposit state shows one frame of the Funds In Transfer (spark) design, at the step that frame shows. + func testSettingUpShowsTheDesignFrameForEveryState() { + let expected: [(SparkClaimState, SparkTransferSpeed, SettingUpStage, Int)] = [ + (.looking, .instant, .processing(normalSpeed: false), 0), + (.later, .later, .processing(normalSpeed: true), 0), + (.notSeen, .instant, .processing(normalSpeed: true), 0), + (.claiming, .instant, .received, 1), + (.repriced(feeSats: 2134), .instant, .feeChanged(feeSats: 2134), 2), + (.unavailable, .instant, .fastUnavailable, 2), + (.later, .instant, .adding(normalSpeed: true), 2), + (.adding, .instant, .adding(normalSpeed: false), 2), + (.added, .instant, .done, 2), + ] + for (state, speed, stage, step) in expected { + let shown = SettingUpStage(state: state, speed: speed) + XCTAssertEqual(shown, stage, "\(state) at \(speed)") + XCTAssertEqual(shown.currentStep, step, "\(state) at \(speed)") + XCTAssertEqual(shown.steps.count, 3, "\(state) shows three steps") } - XCTAssertTrue(SettingUpView.showsLater(speed: .later, state: .looking)) } - func testSettingUpShowsAStepForEveryStateStillInProgress() { - let states: [SparkClaimState] = [.looking, .claiming, .adding, .repriced(feeSats: 1), .unavailable, .later, .notSeen] - for state in states { - XCTAssertFalse(state.isDone, "\(state)") - XCTAssertLessThan(SettingUpView.currentStep(for: state), 3, "\(state) points past the last step") - } - XCTAssertEqual(SettingUpView.currentStep(for: .adding), 2, "Adding is the last step, Spark adding it") + func testApprovingAChangedFeeNeverStepsBackToPaymentSuccessful() { + XCTAssertEqual(SettingUpStage(state: .claiming, speed: .instant, approvedFee: true), .adding(normalSpeed: false)) } - /// The same step as Android's `SettingUpScreen` for every state: a deposit Spark has not seen stays on - /// Payment Successful, whatever the speed. - func testSettingUpStepMatchesAndroidForEveryState() { - let expected: [(SparkClaimState, Int)] = [ - (.looking, 1), - (.notSeen, 1), - (.later, 1), - (.claiming, 2), - (.adding, 2), - (.repriced(feeSats: 1), 2), - (.unavailable, 2), - (.added, 3), - ] - for (state, step) in expected { - XCTAssertEqual(SettingUpView.currentStep(for: state), step, "\(state)") - } + func testSettingUpSaysAboutThirtyMinutesOnlyAtNormalSpeed() { + let normal: [SettingUpStage] = [.processing(normalSpeed: true), .fastUnavailable, .adding(normalSpeed: true)] + let fast: [SettingUpStage] = [.processing(normalSpeed: false), .received, .adding(normalSpeed: false)] + normal.forEach { XCTAssertTrue($0.isNormalSpeed, "\($0)") } + fast.forEach { XCTAssertFalse($0.isNormalSpeed, "\($0)") } + } + + func testSettingUpLabelsTheLastStepByWhatItIsDoing() { + XCTAssertEqual(SettingUpStage.feeChanged(feeSats: 1).steps.last, t("lightning__setting_up__step_fee_changed")) + XCTAssertEqual(SettingUpStage.fastUnavailable.steps.last, t("lightning__setting_up__step_normal_speed")) + XCTAssertEqual(SettingUpStage.adding(normalSpeed: true).steps.last, t("lightning__setting_up__step_normal_speed")) + XCTAssertEqual(SettingUpStage.adding(normalSpeed: false).steps.last, t("lightning__setting_up_step_spark")) } } diff --git a/BitkitTests/SparkTransferFlowTests.swift b/BitkitTests/SparkTransferFlowTests.swift index dbc7a667c6..a686fff023 100644 --- a/BitkitTests/SparkTransferFlowTests.swift +++ b/BitkitTests/SparkTransferFlowTests.swift @@ -285,7 +285,7 @@ final class SparkTransferFlowTests: XCTestCase { flow.showDeposit(txid: "txid") XCTAssertEqual(flow.claimState, .later) - XCTAssertEqual(SettingUpView.currentStep(for: flow.claimState), 1) + XCTAssertEqual(SettingUpStage(state: flow.claimState, speed: flow.speed), .adding(normalSpeed: true)) flow.noteSettled([SparkDeposit(txid: "txid", amountSats: 100_000, isClaimed: true)]) XCTAssertEqual(flow.claimState, .added, "The opened deposit stayed in progress after Spark claimed it") diff --git a/journeys/transfer/spark-transfer-status.xml b/journeys/transfer/spark-transfer-status.xml new file mode 100644 index 0000000000..cb5c916555 --- /dev/null +++ b/journeys/transfer/spark-transfer-status.xml @@ -0,0 +1,22 @@ + + + Verifies the transfer status screen after a transfer to spending through Spark, against the "Funds In Transfer + (spark)" Figma section: three steps (Processing Payment, Payment Successful, then what the last step is doing), + the transfer arrows in dashed rings while the transfer runs, coins while the fast transfer is in question, and a + check once the funds reach spending. + + Precondition: as in spark-transfer-to-spending.xml (a build whose Spark reads Bitkit's chain, a wallet with a + positive on-chain Savings balance and no channels). Start on the confirm screen (testTag "SpendingConfirm") of a + transfer to spending. Which of the fee-changed and fast-unavailable states shows depends on the provider's quote + after the broadcast; the unit tests in SparkFundingRecoveryTests cover every state's frame. + + + With "Instant" (testTag "SpendingConfirmInstant") selected, swipe to confirm and verify the nav title "Transfer Funds", the headline "Funds in transfer", the text (testTag "SettingUpText") "Please wait, your funds transfer is in progress. This should take a few minutes." and the transfer animation (testTag "LightningSettingUp") + Verify step 1 is active and the label under the steps reads "Processing Payment", with "Continue Using Bitkit" (testTag "TransferSuccess-button") at the bottom + Once Spark sees the deposit, verify step 1 shows a check and the label reads "Payment Successful"; then, while Spark adds it, steps 1 and 2 show checks and the label reads "Adding To Spending Balance" + If the fast transfer fee rose, verify the headline "Fast transfer fee changed", the text "The fast transfer fee is now ₿ …. Approve to access your funds quickly, or wait ±30 min.", the coins animation, the label "Fast Transfer Fee Changed" and the buttons "Wait" (testTag "SparkDepositWait") and "Approve" (testTag "SparkDepositPay") side by side + If the fast transfer is unavailable, verify the headline "Fast transfer unavailable", the text ending "about 30 minutes.", the coins animation and the label "Using Normal Transfer Speed" + Once the deposit reaches the spending balance, verify the nav title "Transfer Successful", the headline "Funds moved to spending", the text "Your funds have been transferred and your spending balance is ready to use.", the check (testTag "TransferSuccess") and the button "Awesome!" (testTag "TransferSuccess-button"); tap it and verify the wallet home shows + Start another transfer, select "Later" (testTag "SpendingConfirmLater"), swipe to confirm and verify the text ends "about 30 minutes." with step 1 active and the label "Processing Payment" + + From 7fd5c376b2287d4f44bde70011d430b89db92e5c Mon Sep 17 00:00:00 2001 From: Ovi Trif Date: Thu, 12 Nov 2026 18:21:56 +0100 Subject: [PATCH 04/11] fix: payment successful shows once spark lists the deposit Frame 2 follows Spark listing the deposit at either speed, and only Wait shows the normal speed on the last step, so a deposit the banner reopens shows its real step. --- Bitkit/Managers/SparkManager.swift | 4 +- Bitkit/Views/Transfer/SettingUpView.swift | 31 +++++++++----- BitkitTests/SparkFundingRecoveryTests.swift | 41 +++++++++++-------- BitkitTests/SparkTransferFlowTests.swift | 2 +- journeys/transfer/spark-transfer-status.xml | 4 +- .../transfer-banner-opens-progress.xml | 2 +- 6 files changed, 52 insertions(+), 32 deletions(-) diff --git a/Bitkit/Managers/SparkManager.swift b/Bitkit/Managers/SparkManager.swift index 67917d5a7a..c7684199ef 100644 --- a/Bitkit/Managers/SparkManager.swift +++ b/Bitkit/Managers/SparkManager.swift @@ -1490,7 +1490,7 @@ final class SparkManager: ChannelFreeLightningRail { let known = Set(deposits.map(\.txid)) let local = broadcastDeposits .filter { !known.contains($0.key) } - .map { SparkDeposit(txid: $0.key, amountSats: $0.value, isClaimed: false, confirmations: 0) } + .map { SparkDeposit(txid: $0.key, amountSats: $0.value, isClaimed: false, confirmations: 0, isListed: false) } guard !local.isEmpty else { return } deposits = local + deposits pendingDepositSats = deposits.filter { !$0.isClaimed }.reduce(0) { $0 + $1.amountSats } @@ -1960,6 +1960,8 @@ struct SparkDeposit: Identifiable, Equatable { var claimedAt: UInt64? /// On-chain confirmations, known for deposits this wallet sent. var confirmations: UInt32? + /// Whether Spark lists it, rather than only the app that just broadcast it. + var isListed = true var id: String { "\(txid)-\(isClaimed)" diff --git a/Bitkit/Views/Transfer/SettingUpView.swift b/Bitkit/Views/Transfer/SettingUpView.swift index 6ee5a17703..35a64ba99b 100644 --- a/Bitkit/Views/Transfer/SettingUpView.swift +++ b/Bitkit/Views/Transfer/SettingUpView.swift @@ -4,8 +4,8 @@ import SwiftUI enum SettingUpStage: Equatable { /// Spark has not seen the deposit yet; `normalSpeed` when it is added after 3 confirmations. case processing(normalSpeed: Bool) - /// Spark has seen the deposit. - case received + /// Spark has seen the deposit; `normalSpeed` when it is added after 3 confirmations. + case received(normalSpeed: Bool) /// The fast transfer fee rose above what the user approved. case feeChanged(feeSats: UInt64) /// No fast transfer for this deposit, so it is added at normal speed. @@ -15,13 +15,17 @@ enum SettingUpStage: Equatable { /// The deposit reached the spending balance. case done - /// `approvedFee` once the user approved a changed fee, so the claim that follows doesn't step back to Received. - init(state: SparkClaimState, speed: SparkTransferSpeed, approvedFee: Bool = false) { + /// `isSeen` once Spark lists the deposit. `approvedFee` once the user approved a changed fee, so the claim that + /// follows doesn't step back to Received, and `hasWaited` once the user chose Wait over it. + init(state: SparkClaimState, isSeen: Bool = false, approvedFee: Bool = false, hasWaited: Bool = false) { + func seenOrProcessing(normalSpeed: Bool) -> SettingUpStage { + isSeen ? .received(normalSpeed: normalSpeed) : .processing(normalSpeed: normalSpeed) + } self = switch state { - case .looking: .processing(normalSpeed: speed == .later) - case .notSeen: .processing(normalSpeed: true) - case .later: speed == .later ? .processing(normalSpeed: true) : .adding(normalSpeed: true) - case .claiming: approvedFee ? .adding(normalSpeed: false) : .received + case .looking: approvedFee ? .adding(normalSpeed: false) : seenOrProcessing(normalSpeed: false) + case .notSeen: seenOrProcessing(normalSpeed: true) + case .later: hasWaited ? .adding(normalSpeed: true) : seenOrProcessing(normalSpeed: true) + case .claiming: approvedFee ? .adding(normalSpeed: false) : .received(normalSpeed: false) case .adding: .adding(normalSpeed: false) case let .repriced(feeSats): .feeChanged(feeSats: feeSats) case .unavailable: .fastUnavailable @@ -60,7 +64,7 @@ enum SettingUpStage: Equatable { /// Whether the text says about 30 minutes rather than a few minutes. var isNormalSpeed: Bool { switch self { - case .processing(normalSpeed: true), .adding(normalSpeed: true), .fastUnavailable: true + case .processing(normalSpeed: true), .received(normalSpeed: true), .adding(normalSpeed: true), .fastUnavailable: true default: false } } @@ -80,9 +84,15 @@ struct SettingUpView: View { @Environment(SparkTransferFlow.self) private var flow @State private var approvedFee = false + @State private var hasWaited = false private var stage: SettingUpStage { - SettingUpStage(state: flow.claimState, speed: flow.speed, approvedFee: approvedFee) + SettingUpStage(state: flow.claimState, isSeen: isDepositSeen, approvedFee: approvedFee, hasWaited: hasWaited) + } + + private var isDepositSeen: Bool { + guard let txid = flow.txid else { return false } + return SparkManager.shared.deposits.contains { $0.isListed && $0.txid.caseInsensitiveCompare(txid) == .orderedSame } } var text: String { @@ -159,6 +169,7 @@ struct SettingUpView: View { private var feeChangedButtons: some View { HStack(spacing: 16) { CustomButton(title: t("lightning__spark_deposit__wait_button"), variant: .secondary) { + hasWaited = true flow.waitForConfirmations() } .accessibilityIdentifier("SparkDepositWait") diff --git a/BitkitTests/SparkFundingRecoveryTests.swift b/BitkitTests/SparkFundingRecoveryTests.swift index 48a9119c1c..c0f0bdbf84 100644 --- a/BitkitTests/SparkFundingRecoveryTests.swift +++ b/BitkitTests/SparkFundingRecoveryTests.swift @@ -58,32 +58,39 @@ final class SparkFundingRecoveryTests: XCTestCase { /// Every deposit state shows one frame of the Funds In Transfer (spark) design, at the step that frame shows. func testSettingUpShowsTheDesignFrameForEveryState() { - let expected: [(SparkClaimState, SparkTransferSpeed, SettingUpStage, Int)] = [ - (.looking, .instant, .processing(normalSpeed: false), 0), - (.later, .later, .processing(normalSpeed: true), 0), - (.notSeen, .instant, .processing(normalSpeed: true), 0), - (.claiming, .instant, .received, 1), - (.repriced(feeSats: 2134), .instant, .feeChanged(feeSats: 2134), 2), - (.unavailable, .instant, .fastUnavailable, 2), - (.later, .instant, .adding(normalSpeed: true), 2), - (.adding, .instant, .adding(normalSpeed: false), 2), - (.added, .instant, .done, 2), + let expected: [(SparkClaimState, Bool, SettingUpStage, Int)] = [ + (.looking, false, .processing(normalSpeed: false), 0), + (.looking, true, .received(normalSpeed: false), 1), + (.later, false, .processing(normalSpeed: true), 0), + (.later, true, .received(normalSpeed: true), 1), + (.notSeen, false, .processing(normalSpeed: true), 0), + (.claiming, false, .received(normalSpeed: false), 1), + (.repriced(feeSats: 2134), true, .feeChanged(feeSats: 2134), 2), + (.unavailable, true, .fastUnavailable, 2), + (.adding, true, .adding(normalSpeed: false), 2), + (.added, true, .done, 2), ] - for (state, speed, stage, step) in expected { - let shown = SettingUpStage(state: state, speed: speed) - XCTAssertEqual(shown, stage, "\(state) at \(speed)") - XCTAssertEqual(shown.currentStep, step, "\(state) at \(speed)") + for (state, isSeen, stage, step) in expected { + let shown = SettingUpStage(state: state, isSeen: isSeen) + XCTAssertEqual(shown, stage, "\(state), seen \(isSeen)") + XCTAssertEqual(shown.currentStep, step, "\(state), seen \(isSeen)") XCTAssertEqual(shown.steps.count, 3, "\(state) shows three steps") } } + func testWaitingOverAChangedFeeShowsTheNormalSpeedOnTheLastStep() { + XCTAssertEqual(SettingUpStage(state: .later, isSeen: true, hasWaited: true), .adding(normalSpeed: true)) + } + func testApprovingAChangedFeeNeverStepsBackToPaymentSuccessful() { - XCTAssertEqual(SettingUpStage(state: .claiming, speed: .instant, approvedFee: true), .adding(normalSpeed: false)) + XCTAssertEqual(SettingUpStage(state: .claiming, approvedFee: true), .adding(normalSpeed: false)) } func testSettingUpSaysAboutThirtyMinutesOnlyAtNormalSpeed() { - let normal: [SettingUpStage] = [.processing(normalSpeed: true), .fastUnavailable, .adding(normalSpeed: true)] - let fast: [SettingUpStage] = [.processing(normalSpeed: false), .received, .adding(normalSpeed: false)] + let normal: [SettingUpStage] = [ + .processing(normalSpeed: true), .received(normalSpeed: true), .fastUnavailable, .adding(normalSpeed: true), + ] + let fast: [SettingUpStage] = [.processing(normalSpeed: false), .received(normalSpeed: false), .adding(normalSpeed: false)] normal.forEach { XCTAssertTrue($0.isNormalSpeed, "\($0)") } fast.forEach { XCTAssertFalse($0.isNormalSpeed, "\($0)") } } diff --git a/BitkitTests/SparkTransferFlowTests.swift b/BitkitTests/SparkTransferFlowTests.swift index a686fff023..477127e8cd 100644 --- a/BitkitTests/SparkTransferFlowTests.swift +++ b/BitkitTests/SparkTransferFlowTests.swift @@ -285,7 +285,7 @@ final class SparkTransferFlowTests: XCTestCase { flow.showDeposit(txid: "txid") XCTAssertEqual(flow.claimState, .later) - XCTAssertEqual(SettingUpStage(state: flow.claimState, speed: flow.speed), .adding(normalSpeed: true)) + XCTAssertEqual(SettingUpStage(state: flow.claimState), .processing(normalSpeed: true)) flow.noteSettled([SparkDeposit(txid: "txid", amountSats: 100_000, isClaimed: true)]) XCTAssertEqual(flow.claimState, .added, "The opened deposit stayed in progress after Spark claimed it") diff --git a/journeys/transfer/spark-transfer-status.xml b/journeys/transfer/spark-transfer-status.xml index cb5c916555..fce511601f 100644 --- a/journeys/transfer/spark-transfer-status.xml +++ b/journeys/transfer/spark-transfer-status.xml @@ -14,9 +14,9 @@ With "Instant" (testTag "SpendingConfirmInstant") selected, swipe to confirm and verify the nav title "Transfer Funds", the headline "Funds in transfer", the text (testTag "SettingUpText") "Please wait, your funds transfer is in progress. This should take a few minutes." and the transfer animation (testTag "LightningSettingUp") Verify step 1 is active and the label under the steps reads "Processing Payment", with "Continue Using Bitkit" (testTag "TransferSuccess-button") at the bottom Once Spark sees the deposit, verify step 1 shows a check and the label reads "Payment Successful"; then, while Spark adds it, steps 1 and 2 show checks and the label reads "Adding To Spending Balance" - If the fast transfer fee rose, verify the headline "Fast transfer fee changed", the text "The fast transfer fee is now ₿ …. Approve to access your funds quickly, or wait ±30 min.", the coins animation, the label "Fast Transfer Fee Changed" and the buttons "Wait" (testTag "SparkDepositWait") and "Approve" (testTag "SparkDepositPay") side by side + If the fast transfer fee rose, verify the headline "Fast transfer fee changed", the text "The fast transfer fee is now ₿ …. Approve to access your funds quickly, or wait ±30 min.", the coins animation, the label "Fast Transfer Fee Changed" and the buttons "Wait" (testTag "SparkDepositWait") and "Approve" (testTag "SparkDepositPay") side by side; tap "Wait" and verify the headline "Funds in transfer", the text ending "about 30 minutes." and the label "Using Normal Transfer Speed" on step 3 If the fast transfer is unavailable, verify the headline "Fast transfer unavailable", the text ending "about 30 minutes.", the coins animation and the label "Using Normal Transfer Speed" Once the deposit reaches the spending balance, verify the nav title "Transfer Successful", the headline "Funds moved to spending", the text "Your funds have been transferred and your spending balance is ready to use.", the check (testTag "TransferSuccess") and the button "Awesome!" (testTag "TransferSuccess-button"); tap it and verify the wallet home shows - Start another transfer, select "Later" (testTag "SpendingConfirmLater"), swipe to confirm and verify the text ends "about 30 minutes." with step 1 active and the label "Processing Payment" + Start another transfer, select "Later" (testTag "SpendingConfirmLater"), swipe to confirm and verify the text ends "about 30 minutes." with step 1 active and the label "Processing Payment", then "Payment Successful" once Spark lists the deposit diff --git a/journeys/transfer/transfer-banner-opens-progress.xml b/journeys/transfer/transfer-banner-opens-progress.xml index b04706a31c..48f8237ff7 100644 --- a/journeys/transfer/transfer-banner-opens-progress.xml +++ b/journeys/transfer/transfer-banner-opens-progress.xml @@ -14,7 +14,7 @@ Tap "Later" (id "SpendingConfirmLater") and swipe the "Swipe To Transfer" handle (id "GRAB") fully to the right Verify the "Funds in transfer" screen (id "LightningSettingUp") opens, then tap "Continue Using Bitkit" (id "TransferSuccess-button") Verify Home shows the "TRANSFER IN PROGRESS" banner (id "ActivityBanner") - Tap the banner and verify "Funds in transfer" (id "LightningSettingUp") opens with "Payment Successful" as the current step and the speed (id "SettingUpSpeed") reading Later + Tap the banner and verify "Funds in transfer" (id "LightningSettingUp") opens at its current step: "Processing Payment", or "Payment Successful" once Spark lists the deposit, with "This should take about 30 minutes." (id "SettingUpText") Go back and verify the wallet home screen shows with the banner still visible Relaunch the app, tap the banner and verify the same screen and step open again Mine 3 blocks on the regtest and wait until the screen shows the transfer as done (id "TransferSuccess"); tap its button and verify Home no longer shows the banner From ff812aac0b58899707752618052d5ad8fb10772e Mon Sep 17 00:00:00 2001 From: Ovi Trif Date: Thu, 12 Nov 2026 18:44:43 +0100 Subject: [PATCH 05/11] fix: fee changed coins hold still The coins of the fee changed and fast transfer unavailable frames stay still, as in the design. --- Bitkit/Components/EllipseLoader.swift | 12 +++++++++--- Bitkit/Views/Transfer/SettingUpView.swift | 2 +- 2 files changed, 10 insertions(+), 4 deletions(-) diff --git a/Bitkit/Components/EllipseLoader.swift b/Bitkit/Components/EllipseLoader.swift index 4a67c7da5d..ac4f0bbb05 100644 --- a/Bitkit/Components/EllipseLoader.swift +++ b/Bitkit/Components/EllipseLoader.swift @@ -5,12 +5,14 @@ enum EllipseLoaderVariant { case sync case syncOnchain case quickpay + /// The quickpay coins, held still. + case coins case transfer case hardware var accentColor: String { switch self { - case .sync, .quickpay, .transfer: return "purple" + case .sync, .quickpay, .coins, .transfer: return "purple" case .syncOnchain: return "brand" case .hardware: return "blue" } @@ -20,7 +22,7 @@ enum EllipseLoaderVariant { switch self { case .sync, .transfer, .hardware: return 0.85 case .syncOnchain: return 0.82 - case .quickpay: return 1 + case .quickpay, .coins: return 1 } } @@ -28,7 +30,7 @@ enum EllipseLoaderVariant { switch self { case .sync, .syncOnchain: return Animation.easeOut(duration: 1.5).repeatForever(autoreverses: true) - case .quickpay: + case .quickpay, .coins: return Animation.easeOut(duration: 1.6).repeatForever(autoreverses: true) case .transfer: return Animation.easeInOut(duration: 3).repeatForever(autoreverses: true) @@ -125,6 +127,10 @@ struct EllipseLoader: View { .aspectRatio(contentMode: .fit) case .quickpay: AnimatedCoinStack() + case .coins: + Image("coin-stack-4") + .resizable() + .aspectRatio(contentMode: .fit) case .transfer: AnimatedTransferFigure() case .hardware: diff --git a/Bitkit/Views/Transfer/SettingUpView.swift b/Bitkit/Views/Transfer/SettingUpView.swift index 35a64ba99b..664d93bbd3 100644 --- a/Bitkit/Views/Transfer/SettingUpView.swift +++ b/Bitkit/Views/Transfer/SettingUpView.swift @@ -132,7 +132,7 @@ struct SettingUpView: View { .frame(maxWidth: .infinity) .accessibilityIdentifier("TransferSuccess") } else { - EllipseLoader(variant: stage.showsCoins ? .quickpay : .transfer) + EllipseLoader(variant: stage.showsCoins ? .coins : .transfer) .id(stage.showsCoins) .padding(.top, 32) .padding(.horizontal, 16) From 65c046e3ab33a90b21bd317356f1266767ada133 Mon Sep 17 00:00:00 2001 From: Ovi Trif Date: Thu, 12 Nov 2026 19:15:22 +0100 Subject: [PATCH 06/11] fix: reopened transfer status keeps its step --- Bitkit/ViewModels/SparkTransferFlow.swift | 12 ++++++++++++ Bitkit/Views/Transfer/SettingUpView.swift | 7 +------ BitkitTests/SparkTransferFlowTests.swift | 17 +++++++++++++++++ 3 files changed, 30 insertions(+), 6 deletions(-) diff --git a/Bitkit/ViewModels/SparkTransferFlow.swift b/Bitkit/ViewModels/SparkTransferFlow.swift index 96ed05845d..790ebc8245 100644 --- a/Bitkit/ViewModels/SparkTransferFlow.swift +++ b/Bitkit/ViewModels/SparkTransferFlow.swift @@ -174,6 +174,10 @@ final class SparkTransferFlow { private(set) var txid: String? var claimState: SparkClaimState = .looking + /// Whether the user approved the changed fast transfer fee, kept here so a reopened status screen keeps its step. + private(set) var isFeeApproved = false + /// Whether the user chose Wait over the changed fast transfer fee, kept here so a reopened status screen keeps its step. + private(set) var hasWaited = false /// Each broadcast deposit keeps its own claim: a later transfer neither stops an earlier one's early claim nor takes /// its results, which only the current transfer's screen shows. @ObservationIgnored private var offers: [String: SparkClaimOffer] = [:] @@ -309,6 +313,8 @@ final class SparkTransferFlow { ceilings[txid] = ceilingSats ?? quote?.claimFees.instantMaxSats ?? 0 offers[txid] = nil claimState = speed == .instant ? .looking : .later + isFeeApproved = false + hasWaited = false watchTasks[txid]?.cancel() watchTasks[txid] = nil if speed == .instant { @@ -368,6 +374,8 @@ final class SparkTransferFlow { guard self.txid?.caseInsensitiveCompare(txid) != .orderedSame else { return } self.txid = txid claimState = .later + isFeeApproved = false + hasWaited = false } /// Ends the transfer on screen once Spark lists its deposit as claimed, whatever the speed, so Later or Wait @@ -386,12 +394,16 @@ final class SparkTransferFlow { guard case let .repriced(feeSats) = claimState, let txid else { return } ceilings[txid] = feeSats claimState = .claiming + isFeeApproved = true watch(txid: txid) } /// Leaves the deposit to the claim after 3 confirmations, clearing the fee cap an early claim attempt left on it, so /// Spark doesn't still claim it early. func waitForConfirmations() { + if case .repriced = claimState { + hasWaited = true + } if let txid { watchTasks[txid]?.cancel() watchTasks[txid] = nil diff --git a/Bitkit/Views/Transfer/SettingUpView.swift b/Bitkit/Views/Transfer/SettingUpView.swift index 664d93bbd3..c978f80978 100644 --- a/Bitkit/Views/Transfer/SettingUpView.swift +++ b/Bitkit/Views/Transfer/SettingUpView.swift @@ -83,11 +83,8 @@ struct SettingUpView: View { @EnvironmentObject var navigation: NavigationViewModel @Environment(SparkTransferFlow.self) private var flow - @State private var approvedFee = false - @State private var hasWaited = false - private var stage: SettingUpStage { - SettingUpStage(state: flow.claimState, isSeen: isDepositSeen, approvedFee: approvedFee, hasWaited: hasWaited) + SettingUpStage(state: flow.claimState, isSeen: isDepositSeen, approvedFee: flow.isFeeApproved, hasWaited: flow.hasWaited) } private var isDepositSeen: Bool { @@ -169,13 +166,11 @@ struct SettingUpView: View { private var feeChangedButtons: some View { HStack(spacing: 16) { CustomButton(title: t("lightning__spark_deposit__wait_button"), variant: .secondary) { - hasWaited = true flow.waitForConfirmations() } .accessibilityIdentifier("SparkDepositWait") CustomButton(title: t("lightning__setting_up__approve")) { - approvedFee = true flow.payRepriced() } .accessibilityIdentifier("SparkDepositPay") diff --git a/BitkitTests/SparkTransferFlowTests.swift b/BitkitTests/SparkTransferFlowTests.swift index 477127e8cd..6f59f5d5fd 100644 --- a/BitkitTests/SparkTransferFlowTests.swift +++ b/BitkitTests/SparkTransferFlowTests.swift @@ -64,6 +64,7 @@ final class SparkTransferFlowTests: XCTestCase { let flow = SparkTransferFlow(amountSats: 100_000, claimState: .repriced(feeSats: 1500)) flow.waitForConfirmations() XCTAssertEqual(flow.claimState, .later) + XCTAssertTrue(flow.hasWaited) } @MainActor @@ -193,6 +194,7 @@ final class SparkTransferFlowTests: XCTestCase { flow.payRepriced() XCTAssertEqual(flow.claimState, .claiming) + XCTAssertTrue(flow.isFeeApproved) await flow.waitForClaim() XCTAssertEqual(flow.claimState, .added) } @@ -279,6 +281,21 @@ final class SparkTransferFlowTests: XCTestCase { XCTAssertEqual(flow.claimState, .adding, "The banner lost the followed transfer's step") } + @MainActor + func testTheTransferBannerReopensAWaitedDepositAtTheNormalSpeedOnTheLastStep() { + let flow = SparkTransferFlow(amountSats: 100_000, speed: .later, quote: quote) + flow.onBroadcast(txid: "txid") + flow.claimState = .repriced(feeSats: 1500) + flow.waitForConfirmations() + + flow.showDeposit(txid: "TXID") + + let stage = SettingUpStage( + state: flow.claimState, isSeen: true, approvedFee: flow.isFeeApproved, hasWaited: flow.hasWaited + ) + XCTAssertEqual(stage, .adding(normalSpeed: true), "The banner lost the Wait over the changed fee") + } + @MainActor func testTheTransferBannerOpensADepositNoClaimFollowsAsAddedAtMaturity() { let flow = SparkTransferFlow() From 793a90cb3d0d68fda6623e93a3b623d4da69ebc4 Mon Sep 17 00:00:00 2001 From: Ovi Trif Date: Thu, 12 Nov 2026 19:15:23 +0100 Subject: [PATCH 07/11] docs: transfer status journey matches android --- journeys/transfer/spark-transfer-status.xml | 38 +++++++++++++-------- 1 file changed, 23 insertions(+), 15 deletions(-) diff --git a/journeys/transfer/spark-transfer-status.xml b/journeys/transfer/spark-transfer-status.xml index fce511601f..9e5ca60714 100644 --- a/journeys/transfer/spark-transfer-status.xml +++ b/journeys/transfer/spark-transfer-status.xml @@ -1,22 +1,30 @@ - Verifies the transfer status screen after a transfer to spending through Spark, against the "Funds In Transfer - (spark)" Figma section: three steps (Processing Payment, Payment Successful, then what the last step is doing), - the transfer arrows in dashed rings while the transfer runs, coins while the fast transfer is in question, and a - check once the funds reach spending. + Verifies the transfer status screen after a transfer to spending through Spark, against the Figma section + "Funds In Transfer (spark)". Every in-progress frame shows the nav title "Transfer Funds" with the menu and no + back button, three steps, the active step's label under them and one bottom-pinned button; headlines show in + capitals. A fast (Instant) transfer moves through "Processing Payment" (step 1, Spark has not listed the + deposit), "Payment Successful" (step 1 done, Spark lists it) and "Adding To Spending Balance" (steps 1 and 2 + done), all with the transfer arrows in dashed rings, and ends on "Transfer Successful" with the check and + "Awesome!". A normal speed (Later) transfer shows the same steps with "This should take about 30 minutes.". - Precondition: as in spark-transfer-to-spending.xml (a build whose Spark reads Bitkit's chain, a wallet with a - positive on-chain Savings balance and no channels). Start on the confirm screen (testTag "SpendingConfirm") of a - transfer to spending. Which of the fee-changed and fast-unavailable states shows depends on the provider's quote - after the broadcast; the unit tests in SparkFundingRecoveryTests cover every state's frame. + Whether Spark reprices the fast transfer or offers none is the provider's call, so those two frames (coins in + place of the arrows) are conditional steps here; SparkFundingRecoveryTests cover every frame. Spark lists a deposit about a + minute after its broadcast, so each step shows for a few seconds at least. + + Precondition: as in spark-transfer-to-spending.xml: a dev build with Spark connected on its regtest and + reading Bitkit's chain, Savings funded on that chain (at least 20 000 sats, confirmed) and no channels. Start + on the wallet home screen. - With "Instant" (testTag "SpendingConfirmInstant") selected, swipe to confirm and verify the nav title "Transfer Funds", the headline "Funds in transfer", the text (testTag "SettingUpText") "Please wait, your funds transfer is in progress. This should take a few minutes." and the transfer animation (testTag "LightningSettingUp") - Verify step 1 is active and the label under the steps reads "Processing Payment", with "Continue Using Bitkit" (testTag "TransferSuccess-button") at the bottom - Once Spark sees the deposit, verify step 1 shows a check and the label reads "Payment Successful"; then, while Spark adds it, steps 1 and 2 show checks and the label reads "Adding To Spending Balance" - If the fast transfer fee rose, verify the headline "Fast transfer fee changed", the text "The fast transfer fee is now ₿ …. Approve to access your funds quickly, or wait ±30 min.", the coins animation, the label "Fast Transfer Fee Changed" and the buttons "Wait" (testTag "SparkDepositWait") and "Approve" (testTag "SparkDepositPay") side by side; tap "Wait" and verify the headline "Funds in transfer", the text ending "about 30 minutes." and the label "Using Normal Transfer Speed" on step 3 - If the fast transfer is unavailable, verify the headline "Fast transfer unavailable", the text ending "about 30 minutes.", the coins animation and the label "Using Normal Transfer Speed" - Once the deposit reaches the spending balance, verify the nav title "Transfer Successful", the headline "Funds moved to spending", the text "Your funds have been transferred and your spending balance is ready to use.", the check (testTag "TransferSuccess") and the button "Awesome!" (testTag "TransferSuccess-button"); tap it and verify the wallet home shows - Start another transfer, select "Later" (testTag "SpendingConfirmLater"), swipe to confirm and verify the text ends "about 30 minutes." with step 1 active and the label "Processing Payment", then "Payment Successful" once Spark lists the deposit + Tap the Savings balance card (id "ActivitySavings"), tap "Transfer To Spending" (id "TransferToSpending"), tap "25%" (id "SpendingAmountQuarter") and tap "Continue" (id "SpendingAmountContinue") + Verify "Instant" (id "SpendingConfirmInstant") is selected and swipe to confirm + Verify the status screen (id "LightningSettingUp") shows "Transfer Funds", the headline "Funds in transfer", the text (id "SettingUpText") "Please wait, your funds transfer is in progress. This should take a few minutes.", step 1 active with "Processing Payment", and "Continue Using Bitkit" (id "TransferSuccess-button") + Wait up to 3 minutes for "Payment Successful" with step 1 checked, then for "Adding To Spending Balance" with steps 1 and 2 checked; each keeps the same headline, text and button + If the fast transfer fee rose, verify the headline "Fast transfer fee changed", the text "The fast transfer fee is now ₿ …. Approve to access your funds quickly, or wait ±30 min.", the coins, the label "Fast Transfer Fee Changed" and "Wait" (id "SparkDepositWait") and "Approve" (id "SparkDepositPay") side by side; tap "Wait" and verify the headline "Funds in transfer", the text ending "about 30 minutes." and the label "Using Normal Transfer Speed" on step 3 + If the fast transfer is unavailable, verify the headline "Fast transfer unavailable", the text ending "about 30 minutes.", the coins and the label "Using Normal Transfer Speed" + Wait up to 3 minutes for "Transfer Successful" (id "TransferSuccess"): the headline "Funds moved to spending", "Your funds have been transferred and your spending balance is ready to use.", the check and "Awesome!" (id "TransferSuccess-button") + Tap "Awesome!" and verify the wallet home screen shows the higher Spending balance + Start another transfer the same way, tap "Later" (id "SpendingConfirmLater"), swipe to confirm and verify the text ends "about 30 minutes." with step 1 active and "Processing Payment", then "Payment Successful" once Spark lists the deposit From 18df7f90386e9ab5f968353238325fc4e3f6251a Mon Sep 17 00:00:00 2001 From: Ovi Trif Date: Thu, 12 Nov 2026 19:15:23 +0100 Subject: [PATCH 08/11] chore: add changelog fragment --- changelog.d/next/1318.fixed.md | 1 + 1 file changed, 1 insertion(+) create mode 100644 changelog.d/next/1318.fixed.md diff --git a/changelog.d/next/1318.fixed.md b/changelog.d/next/1318.fixed.md new file mode 100644 index 0000000000..789311290d --- /dev/null +++ b/changelog.d/next/1318.fixed.md @@ -0,0 +1 @@ +Funds in transfer to spending through Spark follows the new design, and the Home transfer and Savings banners open the transfer or emergency exit in progress. From 31171cfe1fa00f0cbfeb0a42fd67036a0c9d4f2b Mon Sep 17 00:00:00 2001 From: Ovi Trif Date: Thu, 12 Nov 2026 20:08:39 +0100 Subject: [PATCH 09/11] fix: banner reopens each transfer at its own step --- Bitkit/ViewModels/SparkTransferFlow.swift | 32 ++++++++++++++++--- BitkitTests/SparkTransferFlowTests.swift | 16 ++++++++++ journeys/transfer/spark-transfer-status.xml | 2 +- .../transfer-banner-opens-progress.xml | 2 +- 4 files changed, 46 insertions(+), 6 deletions(-) diff --git a/Bitkit/ViewModels/SparkTransferFlow.swift b/Bitkit/ViewModels/SparkTransferFlow.swift index 790ebc8245..009501544b 100644 --- a/Bitkit/ViewModels/SparkTransferFlow.swift +++ b/Bitkit/ViewModels/SparkTransferFlow.swift @@ -72,6 +72,12 @@ extension AppViewModel { } /// Where a transfer to spending stands once its deposit is broadcast. +private struct KeptClaim { + var state: SparkClaimState + var isFeeApproved: Bool + var hasWaited: Bool +} + enum SparkClaimState: Equatable { /// Instant was chosen and Spark has not listed the deposit yet. case looking @@ -187,6 +193,8 @@ final class SparkTransferFlow { @ObservationIgnored private var approved: (ceilingSats: UInt64, speed: SparkTransferSpeed)? @ObservationIgnored private var approvals: [UUID: (ceilingSats: UInt64, speed: SparkTransferSpeed)] = [:] @ObservationIgnored private var watchTasks: [String: Task] = [:] + /// The claim of each deposit not on screen, by lowercased txid, so the banner reopens it at its step and fee choice. + @ObservationIgnored private var keptClaims: [String: KeptClaim] = [:] @ObservationIgnored private var quoteRequestId = 0 /// The mining fee a refused fixed-amount funding needed, which this transfer's quotes show at least. @ObservationIgnored private(set) var fixedFeeFloorSats: UInt64? @@ -216,6 +224,7 @@ final class SparkTransferFlow { quote = nil fixedFeeFloorSats = nil // A funding followed for the earlier transfer never stands in for this one's swipe. + keepCurrentClaim() txid = nil } self.amountSats = amountSats @@ -227,6 +236,7 @@ final class SparkTransferFlow { /// A new transfer after a broadcast one starts from Instant with nothing priced; the earlier claim goes on. func beginIfBroadcast() { guard txid != nil else { return } + keepCurrentClaim() txid = nil amountSats = 0 isMaxAmount = false @@ -309,6 +319,9 @@ final class SparkTransferFlow { /// Records the broadcast deposit and starts its claim for the chosen speed. func onBroadcast(txid: String, ceilingSats: UInt64? = nil) { + if self.txid != txid { + keepCurrentClaim() + } self.txid = txid ceilings[txid] = ceilingSats ?? quote?.claimFees.instantMaxSats ?? 0 offers[txid] = nil @@ -372,10 +385,12 @@ final class SparkTransferFlow { /// follow, as after a relaunch, is added by Spark at 3 confirmations. func showDeposit(txid: String) { guard self.txid?.caseInsensitiveCompare(txid) != .orderedSame else { return } + keepCurrentClaim() + let kept = keptClaims.removeValue(forKey: txid.lowercased()) self.txid = txid - claimState = .later - isFeeApproved = false - hasWaited = false + claimState = kept?.state ?? .later + isFeeApproved = kept?.isFeeApproved ?? false + hasWaited = kept?.hasWaited ?? false } /// Ends the transfer on screen once Spark lists its deposit as claimed, whatever the speed, so Later or Wait @@ -444,10 +459,19 @@ final class SparkTransferFlow { /// Shows a claim's progress only while its deposit is the transfer on screen. private func setClaimState(_ state: SparkClaimState, for txid: String) { - guard !Task.isCancelled, self.txid == txid else { return } + guard !Task.isCancelled else { return } + guard self.txid == txid else { + keptClaims[txid.lowercased()]?.state = state + return + } claimState = state } + private func keepCurrentClaim() { + guard let txid else { return } + keptClaims[txid.lowercased()] = KeptClaim(state: claimState, isFeeApproved: isFeeApproved, hasWaited: hasWaited) + } + private func pollDeposit(txid: String) async { for _ in 0 ..< pollAttempts { if Task.isCancelled { diff --git a/BitkitTests/SparkTransferFlowTests.swift b/BitkitTests/SparkTransferFlowTests.swift index 6f59f5d5fd..fd917d0dd9 100644 --- a/BitkitTests/SparkTransferFlowTests.swift +++ b/BitkitTests/SparkTransferFlowTests.swift @@ -281,6 +281,22 @@ final class SparkTransferFlowTests: XCTestCase { XCTAssertEqual(flow.claimState, .adding, "The banner lost the followed transfer's step") } + @MainActor + func testTheTransferBannerReopensARepricedDepositAfterAnotherTransferBegan() async { + let flow = pollingFlow(offers: [choice(earlyFee: 1500), choice(earlyFee: 1500)], claims: [.claimed]) + flow.onBroadcast(txid: "txid") + await flow.waitForClaim() + XCTAssertEqual(flow.claimState, .repriced(feeSats: 1500)) + + flow.beginIfBroadcast() + flow.showDeposit(txid: "txid") + + XCTAssertEqual(flow.claimState, .repriced(feeSats: 1500), "The banner lost the pending fee decision") + flow.payRepriced() + await flow.waitForClaim() + XCTAssertEqual(flow.claimState, .added) + } + @MainActor func testTheTransferBannerReopensAWaitedDepositAtTheNormalSpeedOnTheLastStep() { let flow = SparkTransferFlow(amountSats: 100_000, speed: .later, quote: quote) diff --git a/journeys/transfer/spark-transfer-status.xml b/journeys/transfer/spark-transfer-status.xml index 9e5ca60714..9ad20e7e2b 100644 --- a/journeys/transfer/spark-transfer-status.xml +++ b/journeys/transfer/spark-transfer-status.xml @@ -23,7 +23,7 @@ Wait up to 3 minutes for "Payment Successful" with step 1 checked, then for "Adding To Spending Balance" with steps 1 and 2 checked; each keeps the same headline, text and button If the fast transfer fee rose, verify the headline "Fast transfer fee changed", the text "The fast transfer fee is now ₿ …. Approve to access your funds quickly, or wait ±30 min.", the coins, the label "Fast Transfer Fee Changed" and "Wait" (id "SparkDepositWait") and "Approve" (id "SparkDepositPay") side by side; tap "Wait" and verify the headline "Funds in transfer", the text ending "about 30 minutes." and the label "Using Normal Transfer Speed" on step 3 If the fast transfer is unavailable, verify the headline "Fast transfer unavailable", the text ending "about 30 minutes.", the coins and the label "Using Normal Transfer Speed" - Wait up to 3 minutes for "Transfer Successful" (id "TransferSuccess"): the headline "Funds moved to spending", "Your funds have been transferred and your spending balance is ready to use.", the check and "Awesome!" (id "TransferSuccess-button") + Wait for "Transfer Successful" (id "TransferSuccess"), up to 3 minutes for a fast transfer; after Wait or an unavailable fast transfer, mine 3 blocks on the regtest first: the headline "Funds moved to spending", "Your funds have been transferred and your spending balance is ready to use.", the check and "Awesome!" (id "TransferSuccess-button") Tap "Awesome!" and verify the wallet home screen shows the higher Spending balance Start another transfer the same way, tap "Later" (id "SpendingConfirmLater"), swipe to confirm and verify the text ends "about 30 minutes." with step 1 active and "Processing Payment", then "Payment Successful" once Spark lists the deposit diff --git a/journeys/transfer/transfer-banner-opens-progress.xml b/journeys/transfer/transfer-banner-opens-progress.xml index 48f8237ff7..121cb50bb9 100644 --- a/journeys/transfer/transfer-banner-opens-progress.xml +++ b/journeys/transfer/transfer-banner-opens-progress.xml @@ -15,7 +15,7 @@ Verify the "Funds in transfer" screen (id "LightningSettingUp") opens, then tap "Continue Using Bitkit" (id "TransferSuccess-button") Verify Home shows the "TRANSFER IN PROGRESS" banner (id "ActivityBanner") Tap the banner and verify "Funds in transfer" (id "LightningSettingUp") opens at its current step: "Processing Payment", or "Payment Successful" once Spark lists the deposit, with "This should take about 30 minutes." (id "SettingUpText") - Go back and verify the wallet home screen shows with the banner still visible + Tap "Continue Using Bitkit" (id "TransferSuccess-button") and verify the wallet home screen shows with the banner still visible Relaunch the app, tap the banner and verify the same screen and step open again Mine 3 blocks on the regtest and wait until the screen shows the transfer as done (id "TransferSuccess"); tap its button and verify Home no longer shows the banner From 64b8350dfca1e572a55caa21f441ad7d17c543b9 Mon Sep 17 00:00:00 2001 From: Ovi Trif Date: Thu, 12 Nov 2026 20:41:07 +0100 Subject: [PATCH 10/11] docs: journeys wait for confirmations on spark's regtest --- journeys/transfer/spark-transfer-status.xml | 2 +- journeys/transfer/transfer-banner-opens-progress.xml | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/journeys/transfer/spark-transfer-status.xml b/journeys/transfer/spark-transfer-status.xml index 9ad20e7e2b..d3d5213399 100644 --- a/journeys/transfer/spark-transfer-status.xml +++ b/journeys/transfer/spark-transfer-status.xml @@ -23,7 +23,7 @@ Wait up to 3 minutes for "Payment Successful" with step 1 checked, then for "Adding To Spending Balance" with steps 1 and 2 checked; each keeps the same headline, text and button If the fast transfer fee rose, verify the headline "Fast transfer fee changed", the text "The fast transfer fee is now ₿ …. Approve to access your funds quickly, or wait ±30 min.", the coins, the label "Fast Transfer Fee Changed" and "Wait" (id "SparkDepositWait") and "Approve" (id "SparkDepositPay") side by side; tap "Wait" and verify the headline "Funds in transfer", the text ending "about 30 minutes." and the label "Using Normal Transfer Speed" on step 3 If the fast transfer is unavailable, verify the headline "Fast transfer unavailable", the text ending "about 30 minutes.", the coins and the label "Using Normal Transfer Speed" - Wait for "Transfer Successful" (id "TransferSuccess"), up to 3 minutes for a fast transfer; after Wait or an unavailable fast transfer, mine 3 blocks on the regtest first: the headline "Funds moved to spending", "Your funds have been transferred and your spending balance is ready to use.", the check and "Awesome!" (id "TransferSuccess-button") + Wait for "Transfer Successful" (id "TransferSuccess"), up to 3 minutes for a fast transfer; after Wait or an unavailable fast transfer, up to 10 minutes for the deposit's 3 confirmations (Spark's regtest mines about once a minute): the headline "Funds moved to spending", "Your funds have been transferred and your spending balance is ready to use.", the check and "Awesome!" (id "TransferSuccess-button") Tap "Awesome!" and verify the wallet home screen shows the higher Spending balance Start another transfer the same way, tap "Later" (id "SpendingConfirmLater"), swipe to confirm and verify the text ends "about 30 minutes." with step 1 active and "Processing Payment", then "Payment Successful" once Spark lists the deposit diff --git a/journeys/transfer/transfer-banner-opens-progress.xml b/journeys/transfer/transfer-banner-opens-progress.xml index 121cb50bb9..808c182852 100644 --- a/journeys/transfer/transfer-banner-opens-progress.xml +++ b/journeys/transfer/transfer-banner-opens-progress.xml @@ -17,6 +17,6 @@ Tap the banner and verify "Funds in transfer" (id "LightningSettingUp") opens at its current step: "Processing Payment", or "Payment Successful" once Spark lists the deposit, with "This should take about 30 minutes." (id "SettingUpText") Tap "Continue Using Bitkit" (id "TransferSuccess-button") and verify the wallet home screen shows with the banner still visible Relaunch the app, tap the banner and verify the same screen and step open again - Mine 3 blocks on the regtest and wait until the screen shows the transfer as done (id "TransferSuccess"); tap its button and verify Home no longer shows the banner + Wait up to 10 minutes for the deposit's 3 confirmations (Spark's regtest mines about once a minute) until the screen shows the transfer as done (id "TransferSuccess"); tap its button and verify Home no longer shows the banner From 5b9cdffe1acf20e71a234db11e68881f3cc36ce4 Mon Sep 17 00:00:00 2001 From: Ovi Trif Date: Fri, 13 Nov 2026 14:03:02 +0100 Subject: [PATCH 11/11] fix: transfer status never steps back while spark claims Spark drops a deposit from its list while claiming it, so the status screen went back to Processing Payment for a moment before Transfer Successful. A deposit once listed now stays seen. The journey treats Adding To Spending Balance as a step Spark's regtest may skip. --- Bitkit/ViewModels/SparkTransferFlow.swift | 11 +++++++++++ Bitkit/Views/Transfer/SettingUpView.swift | 3 +-- BitkitTests/SparkTransferFlowTests.swift | 13 +++++++++++++ journeys/transfer/spark-transfer-status.xml | 7 ++++--- 4 files changed, 29 insertions(+), 5 deletions(-) diff --git a/Bitkit/ViewModels/SparkTransferFlow.swift b/Bitkit/ViewModels/SparkTransferFlow.swift index 009501544b..9fc340632b 100644 --- a/Bitkit/ViewModels/SparkTransferFlow.swift +++ b/Bitkit/ViewModels/SparkTransferFlow.swift @@ -179,6 +179,8 @@ final class SparkTransferFlow { var quoteError: String? private(set) var txid: String? + /// The deposit Spark listed. Spark drops a deposit from its list while claiming it, so it stays seen. + private(set) var seenTxid: String? var claimState: SparkClaimState = .looking /// Whether the user approved the changed fast transfer fee, kept here so a reopened status screen keeps its step. private(set) var isFeeApproved = false @@ -395,7 +397,16 @@ final class SparkTransferFlow { /// Ends the transfer on screen once Spark lists its deposit as claimed, whatever the speed, so Later or Wait /// doesn't stay in progress after the deposit reached spending. + /// Whether Spark has listed this transfer's deposit, also once it drops it from its list to claim it. + func isDepositSeen(in deposits: [SparkDeposit]) -> Bool { + guard let txid else { return false } + return seenTxid == txid || deposits.contains { $0.isListed && $0.txid.caseInsensitiveCompare(txid) == .orderedSame } + } + func noteSettled(_ deposits: [SparkDeposit]) { + if let txid, deposits.contains(where: { $0.isListed && $0.txid.caseInsensitiveCompare(txid) == .orderedSame }) { + seenTxid = txid + } guard let txid, !claimState.isDone, deposits.contains(where: { $0.isClaimed && $0.txid.caseInsensitiveCompare(txid) == .orderedSame }) else { return } diff --git a/Bitkit/Views/Transfer/SettingUpView.swift b/Bitkit/Views/Transfer/SettingUpView.swift index c978f80978..ed167ee44c 100644 --- a/Bitkit/Views/Transfer/SettingUpView.swift +++ b/Bitkit/Views/Transfer/SettingUpView.swift @@ -88,8 +88,7 @@ struct SettingUpView: View { } private var isDepositSeen: Bool { - guard let txid = flow.txid else { return false } - return SparkManager.shared.deposits.contains { $0.isListed && $0.txid.caseInsensitiveCompare(txid) == .orderedSame } + flow.isDepositSeen(in: SparkManager.shared.deposits) } var text: String { diff --git a/BitkitTests/SparkTransferFlowTests.swift b/BitkitTests/SparkTransferFlowTests.swift index fd917d0dd9..ec112cda54 100644 --- a/BitkitTests/SparkTransferFlowTests.swift +++ b/BitkitTests/SparkTransferFlowTests.swift @@ -257,6 +257,19 @@ final class SparkTransferFlowTests: XCTestCase { XCTAssertTrue(flow.claimState.isDone) } + @MainActor + func testTheDepositStaysSeenWhileSparkDropsItFromItsListToClaimIt() { + let flow = SparkTransferFlow(amountSats: 100_000, speed: .later, quote: quote) + flow.onBroadcast(txid: "TXID") + let broadcast = [SparkDeposit(txid: "TXID", amountSats: 100_000, isClaimed: false, isListed: false)] + XCTAssertFalse(flow.isDepositSeen(in: broadcast)) + + let listed = [SparkDeposit(txid: "txid", amountSats: 100_000, isClaimed: false)] + XCTAssertTrue(flow.isDepositSeen(in: listed)) + flow.noteSettled(listed) + XCTAssertTrue(flow.isDepositSeen(in: broadcast), "Setting up went back to Processing Payment while Spark claimed it") + } + @MainActor func testALaterTransferEndsOnceSparkClaimsItsDeposit() { let flow = SparkTransferFlow(amountSats: 100_000, speed: .later, quote: quote) diff --git a/journeys/transfer/spark-transfer-status.xml b/journeys/transfer/spark-transfer-status.xml index d3d5213399..8dc7c66329 100644 --- a/journeys/transfer/spark-transfer-status.xml +++ b/journeys/transfer/spark-transfer-status.xml @@ -9,8 +9,9 @@ "Awesome!". A normal speed (Later) transfer shows the same steps with "This should take about 30 minutes.". Whether Spark reprices the fast transfer or offers none is the provider's call, so those two frames (coins in - place of the arrows) are conditional steps here; SparkFundingRecoveryTests cover every frame. Spark lists a deposit about a - minute after its broadcast, so each step shows for a few seconds at least. + place of the arrows) are conditional steps here; SparkFundingRecoveryTests cover every frame. On Spark's regtest a fast + transfer can finish within seconds, so "Processing Payment" may show only briefly and Spark may claim the + deposit before "Adding To Spending Balance" shows; a step once passed never comes back. Precondition: as in spark-transfer-to-spending.xml: a dev build with Spark connected on its regtest and reading Bitkit's chain, Savings funded on that chain (at least 20 000 sats, confirmed) and no channels. Start @@ -20,7 +21,7 @@ Tap the Savings balance card (id "ActivitySavings"), tap "Transfer To Spending" (id "TransferToSpending"), tap "25%" (id "SpendingAmountQuarter") and tap "Continue" (id "SpendingAmountContinue") Verify "Instant" (id "SpendingConfirmInstant") is selected and swipe to confirm Verify the status screen (id "LightningSettingUp") shows "Transfer Funds", the headline "Funds in transfer", the text (id "SettingUpText") "Please wait, your funds transfer is in progress. This should take a few minutes.", step 1 active with "Processing Payment", and "Continue Using Bitkit" (id "TransferSuccess-button") - Wait up to 3 minutes for "Payment Successful" with step 1 checked, then for "Adding To Spending Balance" with steps 1 and 2 checked; each keeps the same headline, text and button + Wait up to 3 minutes for "Payment Successful" with step 1 checked, then, if it shows before the transfer ends, "Adding To Spending Balance" with steps 1 and 2 checked; each keeps the same headline, text and button, and the label never goes back to an earlier step If the fast transfer fee rose, verify the headline "Fast transfer fee changed", the text "The fast transfer fee is now ₿ …. Approve to access your funds quickly, or wait ±30 min.", the coins, the label "Fast Transfer Fee Changed" and "Wait" (id "SparkDepositWait") and "Approve" (id "SparkDepositPay") side by side; tap "Wait" and verify the headline "Funds in transfer", the text ending "about 30 minutes." and the label "Using Normal Transfer Speed" on step 3 If the fast transfer is unavailable, verify the headline "Fast transfer unavailable", the text ending "about 30 minutes.", the coins and the label "Using Normal Transfer Speed" Wait for "Transfer Successful" (id "TransferSuccess"), up to 3 minutes for a fast transfer; after Wait or an unavailable fast transfer, up to 10 minutes for the deposit's 3 confirmations (Spark's regtest mines about once a minute): the headline "Funds moved to spending", "Your funds have been transferred and your spending balance is ready to use.", the check and "Awesome!" (id "TransferSuccess-button")