From e67ed9e063a3cdf30ed4a4598970f87c20f8370c Mon Sep 17 00:00:00 2001 From: TZGyn Date: Sun, 11 Oct 2026 19:22:21 +0800 Subject: [PATCH] Show Monero accounts as their own section below the wallet card --- apps/ios/Koins/Views/RootView.swift | 51 +++++++++++++++-------------- 1 file changed, 26 insertions(+), 25 deletions(-) diff --git a/apps/ios/Koins/Views/RootView.swift b/apps/ios/Koins/Views/RootView.swift index 4bee2cf..a08b8ed 100644 --- a/apps/ios/Koins/Views/RootView.swift +++ b/apps/ios/Koins/Views/RootView.swift @@ -177,38 +177,39 @@ struct HomeView: View { Spacer() } - if model.chain == .xmr, !model.moneroAccounts.isEmpty { - // Cake Wallet style: a deck of account cards, drag the front card - // away to bring the next one up. - AccountStack(accounts: model.moneroAccounts, - fiat: { model.fiatValue(of: $0, chain: .xmr) }, - onQR: { qrAddress = AddressQR(title: $0.title, address: $0.address) }) - } else { - VStack(alignment: .leading, spacing: 4) { - Text("Balance") - .font(.system(size: 11, weight: .medium)) + VStack(alignment: .leading, spacing: 4) { + Text("Balance") + .font(.system(size: 11, weight: .medium)) + .foregroundStyle(Theme.muted) + Text("\(model.balance.total) \(model.symbol)") + .font(.system(size: 30, weight: .bold, design: .rounded)) + .foregroundStyle(Theme.text) + if let fiat = model.fiatBalance { + Text("\(fiat)") + .font(.system(size: 13, weight: .medium)) + .foregroundStyle(Theme.muted) + } + if model.chain == .xmr, model.balance.unlocked != model.balance.total { + Text("\(model.balance.unlocked) \(model.symbol) unlocked") + .font(.system(size: 11)) .foregroundStyle(Theme.muted) - Text("\(model.balance.total) \(model.symbol)") - .font(.system(size: 30, weight: .bold, design: .rounded)) - .foregroundStyle(Theme.text) - if let fiat = model.fiatBalance { - Text("\(fiat)") - .font(.system(size: 13, weight: .medium)) - .foregroundStyle(Theme.muted) - } - if model.chain == .xmr, model.balance.unlocked != model.balance.total { - Text("\(model.balance.unlocked) \(model.symbol) unlocked") - .font(.system(size: 11)) - .foregroundStyle(Theme.muted) - } } - - AddressRow(address: model.displayAddress) } + if model.chain == .xrp { + AddressRow(address: model.displayAddress) + } } } + if model.chain == .xmr, !model.moneroAccounts.isEmpty { + // Cake Wallet style: a deck of account cards as its own section, drag + // the front card away to bring the next one up. + AccountStack(accounts: model.moneroAccounts, + fiat: { model.fiatValue(of: $0, chain: .xmr) }, + onQR: { qrAddress = AddressQR(title: $0.title, address: $0.address) }) + } + if model.chain == .xmr { SyncCard() }