diff options
author | Marc Stibane <marc@taler.net> | 2024-02-08 16:56:16 +0100 |
---|---|---|
committer | Marc Stibane <marc@taler.net> | 2024-02-08 17:05:36 +0100 |
commit | 8aa2eb2ab76c06e702a57d00f1afa6d53ad8c241 (patch) | |
tree | 1555af8faa6e11f73ef2f458bb5f7b4b537401d1 | |
parent | d2f60e6328d41501184cdd7c6ab6e3d91d30afd7 (diff) | |
download | taler-ios-8aa2eb2ab76c06e702a57d00f1afa6d53ad8c241.tar.gz taler-ios-8aa2eb2ab76c06e702a57d00f1afa6d53ad8c241.tar.bz2 taler-ios-8aa2eb2ab76c06e702a57d00f1afa6d53ad8c241.zip |
minimalistic
-rw-r--r-- | TalerWallet1/Views/Balances/BalanceRowView.swift | 10 | ||||
-rw-r--r-- | TalerWallet1/Views/Balances/BalancesSectionView.swift | 8 | ||||
-rw-r--r-- | TalerWallet1/Views/Balances/PendingRowView.swift | 6 | ||||
-rw-r--r-- | TalerWallet1/Views/Banking/ExchangeRowView.swift | 8 | ||||
-rw-r--r-- | TalerWallet1/Views/Banking/ExchangeSectionView.swift | 4 | ||||
-rw-r--r-- | TalerWallet1/Views/Banking/ManualWithdraw.swift | 4 | ||||
-rw-r--r-- | TalerWallet1/Views/HelperViews/ToSButtonView.swift | 8 | ||||
-rw-r--r-- | TalerWallet1/Views/Main/MainView.swift | 10 | ||||
-rw-r--r-- | TalerWallet1/Views/Peer2peer/P2PSubjectV.swift | 6 | ||||
-rw-r--r-- | TalerWallet1/Views/Peer2peer/RequestPayment.swift | 4 | ||||
-rw-r--r-- | TalerWallet1/Views/Peer2peer/SendAmount.swift | 4 | ||||
-rw-r--r-- | TalerWallet1/Views/Settings/AboutView.swift | 4 | ||||
-rw-r--r-- | TalerWallet1/Views/Settings/SettingsView.swift | 8 | ||||
-rw-r--r-- | TalerWallet1/Views/Transactions/ManualDetailsV.swift | 30 | ||||
-rw-r--r-- | TalerWallet1/Views/Transactions/ThreeAmountsV.swift | 14 | ||||
-rw-r--r-- | TalerWallet1/Views/Transactions/TransactionSummaryV.swift | 8 |
16 files changed, 68 insertions, 68 deletions
diff --git a/TalerWallet1/Views/Balances/BalanceRowView.swift b/TalerWallet1/Views/Balances/BalanceRowView.swift index 130c379..a96f07c 100644 --- a/TalerWallet1/Views/Balances/BalanceRowView.swift +++ b/TalerWallet1/Views/Balances/BalanceRowView.swift @@ -12,7 +12,7 @@ struct BalanceCell: View { let balanceDest: LazyView<TransactionsListView>? @Environment(\.colorSchemeContrast) private var colorSchemeContrast - @AppStorage("iconOnly") var iconOnly: Bool = false + @AppStorage("minimalistic") var minimalistic: Bool = false /// Renders the Balance button. "Balance" leading, amountStr trailing. If it doesn't fit in one row then /// amount (trailing) goes underneath "Balance" (leading). @@ -24,7 +24,7 @@ struct BalanceCell: View { amountV } let balanceCell = Group { - if iconOnly { + if minimalistic { hLayout } else { let balanceText = Text("Balance:", comment: "Main view") @@ -69,7 +69,7 @@ struct BalanceRowView: View { @Environment(\.sizeCategory) var sizeCategory @EnvironmentObject private var controller: Controller - @AppStorage("iconOnly") var iconOnly: Bool = false + @AppStorage("minimalistic") var minimalistic: Bool = false @AppStorage("myListStyle") var myListStyle: MyListStyle = .automatic let sendTitle0 = String(localized: "SendButton_Short", defaultValue: "Send", @@ -89,8 +89,8 @@ struct BalanceRowView: View { balanceDest: balanceDest) // .border(.red) - let sendTitle = iconOnly ? sendTitle0 : sendTitle1 - let requTitle = iconOnly ? requestTitle0 : requestTitle1 + let sendTitle = minimalistic ? sendTitle0 : sendTitle1 + let requTitle = minimalistic ? requestTitle0 : requestTitle1 let twoRowButtons = TwoRowButtons(sendTitle: sendTitle, recvTitle: requTitle, fitsSideBySide: false, diff --git a/TalerWallet1/Views/Balances/BalancesSectionView.swift b/TalerWallet1/Views/Balances/BalancesSectionView.swift index 8a38aac..aaa9f12 100644 --- a/TalerWallet1/Views/Balances/BalancesSectionView.swift +++ b/TalerWallet1/Views/Balances/BalancesSectionView.swift @@ -25,7 +25,7 @@ struct BalancesSectionView { @EnvironmentObject private var model: WalletModel @EnvironmentObject private var controller: Controller - @AppStorage("iconOnly") var iconOnly: Bool = false + @AppStorage("minimalistic") var minimalistic: Bool = false @State private var showSpendingHint = true @State private var isShowingDetailView = false @@ -65,8 +65,8 @@ extension BalancesSectionView: View { Section { let showSpendingButton = "KUDOS" == currency && !balance.available.isZero if showSpendingButton { - if !iconOnly && showSpendingHint { - Text("You can spend these \(currencyInfo?.scope.currency ?? currency) in the Demo Shop, or send them to another wallet.") + if !minimalistic && showSpendingHint { + Text("You can spend these \(currencyInfo?.scope.currency ?? currency) in the Demo shop, or send them to another wallet.") .accessibilityFont(.body) .multilineTextAlignment(.leading) .listRowSeparator(.hidden) @@ -130,7 +130,7 @@ extension BalancesSectionView: View { reloadOneAction: reloadOneAction) .padding(.leading, ICONLEADING) } header: { - if !iconOnly { + if !minimalistic { let count = transactionCount > MAXRECENT ? MAXRECENT : transactionCount Text(count > 1 ? "Recent \(count) transactions" : "Recent transaction") diff --git a/TalerWallet1/Views/Balances/PendingRowView.swift b/TalerWallet1/Views/Balances/PendingRowView.swift index 65bf5d6..7be6011 100644 --- a/TalerWallet1/Views/Balances/PendingRowView.swift +++ b/TalerWallet1/Views/Balances/PendingRowView.swift @@ -13,7 +13,7 @@ struct PendingRowView: View { let needsKYC: Bool // @Environment(\.sizeCategory) var sizeCategory - @AppStorage("iconOnly") var iconOnly: Bool = false + @AppStorage("minimalistic") var minimalistic: Bool = false let inTitle0 = String(localized: "TitleIncoming_Short", defaultValue: "Incoming", comment: "Abbreviation of `Pending incoming´ in Balances") @@ -29,8 +29,8 @@ struct PendingRowView: View { let pendingColor = WalletColors().pendingColor(incoming) let iconBadge = IconBadge(foreColor: pendingColor, done: false, incoming: incoming, shouldConfirm: shouldConfirm, needsKYC: needsKYC) - let inTitle = iconOnly ? inTitle0 : inTitle1 - let outTitle = iconOnly ? outTitle0 : outTitle1 + let inTitle = minimalistic ? inTitle0 : inTitle1 + let outTitle = minimalistic ? outTitle0 : outTitle1 let pendingTitle = incoming ? inTitle : outTitle let amountText = AmountV(amount) diff --git a/TalerWallet1/Views/Banking/ExchangeRowView.swift b/TalerWallet1/Views/Banking/ExchangeRowView.swift index a16e6ad..ce09e40 100644 --- a/TalerWallet1/Views/Banking/ExchangeRowView.swift +++ b/TalerWallet1/Views/Banking/ExchangeRowView.swift @@ -16,7 +16,7 @@ struct ExchangeRowView: View { @Environment(\.sizeCategory) var sizeCategory @EnvironmentObject private var controller: Controller @EnvironmentObject private var model: WalletModel - @AppStorage("iconOnly") var iconOnly: Bool = false + @AppStorage("minimalistic") var minimalistic: Bool = false @State private var buttonSelected: Int? = nil func selectAndUpdate(_ button: Int) { @@ -65,8 +65,8 @@ struct ExchangeRowView: View { viewID: VIEW_WITHDRAW_TOS, acceptAction: nil) // pop back to here } - let twoRowButtons = TwoRowButtons(sendTitle: iconOnly ? depositTitle0 : depositTitle1, - recvTitle: iconOnly ? withdrawTitle0 : withdrawTitle1, + let twoRowButtons = TwoRowButtons(sendTitle: minimalistic ? depositTitle0 : depositTitle1, + recvTitle: minimalistic ? withdrawTitle0 : withdrawTitle1, fitsSideBySide: false, lineLimit: 5, sendDisabled: true, // TODO: availableAmount.isZero @@ -77,7 +77,7 @@ struct ExchangeRowView: View { VStack(alignment: .leading) { Text(baseURL.trimURL()) .accessibilityFont(.headline) - if !iconOnly { + if !minimalistic { Text("Terms of Service") // VIEW_WITHDRAW_TOS .accessibilityFont(.body) } diff --git a/TalerWallet1/Views/Banking/ExchangeSectionView.swift b/TalerWallet1/Views/Banking/ExchangeSectionView.swift index ffdbe49..0b6c49e 100644 --- a/TalerWallet1/Views/Banking/ExchangeSectionView.swift +++ b/TalerWallet1/Views/Banking/ExchangeSectionView.swift @@ -14,7 +14,7 @@ struct ExchangeSectionView: View { let exchanges: [Exchange] @Binding var amountToTransfer: Amount // does still have the wrong currency @EnvironmentObject private var controller: Controller - @AppStorage("iconOnly") var iconOnly: Bool = false + @AppStorage("minimalistic") var minimalistic: Bool = false @State private var shouldReloadBalances: Int = 0 var body: some View { @@ -36,7 +36,7 @@ struct ExchangeSectionView: View { let bankingHint = String(localized: "Since the demo bank supports the Taler integration, you can start a withdrawal directly on the") let linkTitle = String(localized: "LinkTitle_DEMOBANK", defaultValue: "Demo Bank Website") VStack { - if !iconOnly { + if !minimalistic { Text(bankingHint) } Link(linkTitle, destination: URL(string: DEMOBANK)!) diff --git a/TalerWallet1/Views/Banking/ManualWithdraw.swift b/TalerWallet1/Views/Banking/ManualWithdraw.swift index b60815a..8c0ec5c 100644 --- a/TalerWallet1/Views/Banking/ManualWithdraw.swift +++ b/TalerWallet1/Views/Banking/ManualWithdraw.swift @@ -16,7 +16,7 @@ struct ManualWithdraw: View { @EnvironmentObject private var controller: Controller @EnvironmentObject private var model: WalletModel - @AppStorage("iconOnly") var iconOnly: Bool = false + @AppStorage("minimalistic") var minimalistic: Bool = false @State private var withdrawalAmountDetails: WithdrawalAmountDetails? = nil @State private var exchange: Exchange? = nil @@ -56,7 +56,7 @@ struct ManualWithdraw: View { if tosAccepted { CurrencyInputView(amount: $amountToTransfer, available: nil, - title: iconOnly ? String(localized: "Amount:") + title: minimalistic ? String(localized: "Amount:") : String(localized: "Amount to withdraw:"), shortcutAction: nil) .padding(.top) diff --git a/TalerWallet1/Views/HelperViews/ToSButtonView.swift b/TalerWallet1/Views/HelperViews/ToSButtonView.swift index 87ce635..c0cdcab 100644 --- a/TalerWallet1/Views/HelperViews/ToSButtonView.swift +++ b/TalerWallet1/Views/HelperViews/ToSButtonView.swift @@ -14,12 +14,12 @@ struct ToSButtonView: View { let viewID: Int // either VIEW_WITHDRAW_TOS or SHEET_WITHDRAW_TOS let p2p: Bool - @AppStorage("iconOnly") var iconOnly: Bool = false + @AppStorage("minimalistic") var minimalistic: Bool = false var body: some View { - let hint = iconOnly ? String(localized: "You must accept the Exchange's Terms of Service first.") - : p2p ? String(localized: "You must accept the Exchange's Terms of Service first before you can receive electronic cash in your wallet.", comment: "P2P Receive") - : String(localized: "You must accept the Exchange's Terms of Service first before you can use it to withdraw electronic cash to your wallet.") + let hint = minimalistic ? String(localized: "You must accept the Payment Service's Terms of Service first.") + : p2p ? String(localized: "You must accept the Payment Service Provider's Terms of Service first before you can receive electronic cash in your wallet.", comment: "P2P Receive") + : String(localized: "You must accept the Payment Service Provider's Terms of Service first before you can use it to withdraw electronic cash to your wallet.") Text(hint) .accessibilityFont(.body) .multilineTextAlignment(.leading) diff --git a/TalerWallet1/Views/Main/MainView.swift b/TalerWallet1/Views/Main/MainView.swift index ce54497..e4e13e9 100644 --- a/TalerWallet1/Views/Main/MainView.swift +++ b/TalerWallet1/Views/Main/MainView.swift @@ -85,7 +85,7 @@ extension MainView { @State private var shouldReloadBalances = 0 @State private var balances: [Balance] = [] @Binding var talerFont: Int - @AppStorage("iconOnly") var iconOnly: Bool = false + @AppStorage("minimalistic") var minimalistic: Bool = false @EnvironmentObject private var controller: Controller @EnvironmentObject private var model: WalletModel @EnvironmentObject private var viewState: ViewState // popToRootView() @@ -145,7 +145,7 @@ extension MainView { let delay: UInt = 0 // no delay for release builds #endif Group { -// let labelStyle = iconOnly ? IconOnlyLabelStyle() : TitleAndIconLabelStyle() // labelStyle doesn't work +// let labelStyle = minimalistic ? IconOnlyLabelStyle() : TitleAndIconLabelStyle() // labelStyle doesn't work TabView(selection: tabSelection()) { NavigationView { BalancesListView(stack: stack.push(balancesTitle), @@ -157,7 +157,7 @@ extension MainView { .tabItem { Image(systemName: "chart.bar.xaxis") // iOS will automatically use filled variant .accessibilityLabel(balancesTitle) - if !iconOnly { Text(balancesTitle) } + if !minimalistic { Text(balancesTitle) } } .tag(Tab.balances) .badge(0) // TODO: set badge if transaction finished in background @@ -170,7 +170,7 @@ extension MainView { .tabItem { Image(systemName: "building.columns") // "arrow.triangle.2.circlepath") .accessibilityLabel(exchangesTitle) - if !iconOnly { Text(exchangesTitle) } + if !minimalistic { Text(exchangesTitle) } } .tag(Tab.exchanges) @@ -180,7 +180,7 @@ extension MainView { .tabItem { Image(systemName: "gear") // system will automatically use filled variant .accessibilityLabel(settingsTitle) - if !iconOnly { Text(settingsTitle) } + if !minimalistic { Text(settingsTitle) } } .tag(Tab.settings) } diff --git a/TalerWallet1/Views/Peer2peer/P2PSubjectV.swift b/TalerWallet1/Views/Peer2peer/P2PSubjectV.swift index ecc5116..57e2261 100644 --- a/TalerWallet1/Views/Peer2peer/P2PSubjectV.swift +++ b/TalerWallet1/Views/Peer2peer/P2PSubjectV.swift @@ -26,7 +26,7 @@ struct P2PSubjectV: View { @Binding var expireDays: UInt @EnvironmentObject private var model: WalletModel - @AppStorage("iconOnly") var iconOnly: Bool = false + @AppStorage("minimalistic") var minimalistic: Bool = false @State private var myFeeLabel: String = EMPTYSTRING @State private var transactionStarted: Bool = false @@ -65,7 +65,7 @@ struct P2PSubjectV: View { .accessibilityFont(.body) } } - if !iconOnly { + if !minimalistic { Text("Enter subject:") // Purpose .accessibilityFont(.title3) .accessibilityAddTraits(.isHeader) @@ -73,7 +73,7 @@ struct P2PSubjectV: View { .padding(.top) } Group { if #available(iOS 16.0, *) { - TextField(iconOnly ? "Subject" : EMPTYSTRING, text: $summary, axis: .vertical) + TextField(minimalistic ? "Subject" : EMPTYSTRING, text: $summary, axis: .vertical) .focused($isFocused) .lineLimit(2...) } else { diff --git a/TalerWallet1/Views/Peer2peer/RequestPayment.swift b/TalerWallet1/Views/Peer2peer/RequestPayment.swift index 5a4cc72..a282f08 100644 --- a/TalerWallet1/Views/Peer2peer/RequestPayment.swift +++ b/TalerWallet1/Views/Peer2peer/RequestPayment.swift @@ -16,7 +16,7 @@ struct RequestPayment: View { @EnvironmentObject private var controller: Controller @EnvironmentObject private var model: WalletModel - @AppStorage("iconOnly") var iconOnly: Bool = false + @AppStorage("minimalistic") var minimalistic: Bool = false @State private var peerPullCheck: CheckPeerPullCreditResponse? = nil @State private var expireDays: UInt = 0 @@ -63,7 +63,7 @@ struct RequestPayment: View { ScrollView { VStack(alignment: .trailing) { CurrencyInputView(amount: $amountToTransfer, available: nil, - title: iconOnly ? String(localized: "Amount:") + title: minimalistic ? String(localized: "Amount:") : String(localized: "Amount to request:"), shortcutAction: shortcutAction) .padding(.top) diff --git a/TalerWallet1/Views/Peer2peer/SendAmount.swift b/TalerWallet1/Views/Peer2peer/SendAmount.swift index a3bc7df..8261ab2 100644 --- a/TalerWallet1/Views/Peer2peer/SendAmount.swift +++ b/TalerWallet1/Views/Peer2peer/SendAmount.swift @@ -17,7 +17,7 @@ struct SendAmount: View { @EnvironmentObject private var controller: Controller @EnvironmentObject private var model: WalletModel - @AppStorage("iconOnly") var iconOnly: Bool = false + @AppStorage("minimalistic") var minimalistic: Bool = false @State var peerPushCheck: CheckPeerPushDebitResponse? = nil @State private var expireDays = SEVENDAYS @@ -87,7 +87,7 @@ struct SendAmount: View { .padding(.bottom, 2) CurrencyInputView(amount: $amountToTransfer, available: amountAvailable, - title: iconOnly ? String(localized: "Amount:") + title: minimalistic ? String(localized: "Amount:") : String(localized: "Amount to send:"), shortcutAction: shortcutAction) Text(insufficient ? insufficientLabel diff --git a/TalerWallet1/Views/Settings/AboutView.swift b/TalerWallet1/Views/Settings/AboutView.swift index eb7d8a7..5997dff 100644 --- a/TalerWallet1/Views/Settings/AboutView.swift +++ b/TalerWallet1/Views/Settings/AboutView.swift @@ -18,7 +18,7 @@ struct AboutView: View { @AppStorage("developerMode") var developerMode: Bool = false #endif @AppStorage("myListStyle") var myListStyle: MyListStyle = .automatic - @AppStorage("iconOnly") var iconOnly: Bool = false + @AppStorage("minimalistic") var minimalistic: Bool = false @State private var rotationEnabled = false @State private var showGitHash = false @@ -39,7 +39,7 @@ struct AboutView: View { Spacer() } SettingsItem(name: "Visit the taler.net website", id1: "web", - description: iconOnly ? nil : String(localized: "More info about Gnu Taler in general...")) { } + description: minimalistic ? nil : String(localized: "More info about Gnu Taler in general...")) { } .accessibilityAddTraits(.isLink) .accessibilityRemoveTraits(.isStaticText) .onTapGesture() { diff --git a/TalerWallet1/Views/Settings/SettingsView.swift b/TalerWallet1/Views/Settings/SettingsView.swift index cb38f38..ccc3260 100644 --- a/TalerWallet1/Views/Settings/SettingsView.swift +++ b/TalerWallet1/Views/Settings/SettingsView.swift @@ -36,7 +36,7 @@ struct SettingsView: View { @AppStorage("talerFont") var talerFont: Int = 0 @AppStorage("developDelay") var developDelay: Bool = false @AppStorage("myListStyle") var myListStyle: MyListStyle = .automatic - @AppStorage("iconOnly") var iconOnly: Bool = false + @AppStorage("minimalistic") var minimalistic: Bool = false @State private var checkDisabled = false @State private var withDrawDisabled = false @@ -135,9 +135,9 @@ struct SettingsView: View { // .id("font") SettingsStyle(title: String(localized: "Liststyle:"), myListStyle: $myListStyle) .id("liststyle") - SettingsToggle(name: String(localized: "Minimalistic"), value: $iconOnly, id1: "minimal", + SettingsToggle(name: String(localized: "Minimalistic"), value: $minimalistic, id1: "minimal", description: hideDescriptions ? nil : String(localized: "Omit text where possible")) { - hideDescriptions = iconOnly //withAnimation { hideDescriptions = iconOnly } + hideDescriptions = minimalistic //withAnimation { hideDescriptions = minimalistic } } if diagnosticModeEnabled { SettingsToggle(name: String("Developer Mode"), value: $developerMode, id1: "devMode", @@ -310,7 +310,7 @@ struct SettingsView: View { .navigationTitle(navTitle) .onAppear() { showDevelopItems = developerMode - hideDescriptions = iconOnly + hideDescriptions = minimalistic DebugViewC.shared.setViewID(VIEW_SETTINGS, stack: stack.push()) } .onDisappear() { diff --git a/TalerWallet1/Views/Transactions/ManualDetailsV.swift b/TalerWallet1/Views/Transactions/ManualDetailsV.swift index 8be8ae5..a6c4771 100644 --- a/TalerWallet1/Views/Transactions/ManualDetailsV.swift +++ b/TalerWallet1/Views/Transactions/ManualDetailsV.swift @@ -40,14 +40,14 @@ struct TransferRestrictionsV: View { let obtainStr: String let restrictions: [AccountRestriction]? - @AppStorage("iconOnly") var iconOnly: Bool = false + @AppStorage("minimalistic") var minimalistic: Bool = false @State private var selectedLanguage = Locale.preferredLanguageCode var body: some View { VStack(alignment: .leading) { - Text(iconOnly ? "Transfer \(amountStr) to the Exchange." - : "You need to transfer \(amountStr) from your regular bank account to the Exchange to receive \(obtainStr) as electronic cash in this wallet.") + Text(minimalistic ? "Transfer \(amountStr) to the Payment Service." + : "You need to transfer \(amountStr) from your regular bank account to the Payment Service Provider to receive \(obtainStr) as electronic cash in this wallet.") .multilineTextAlignment(.leading) if let restrictions { ForEach(restrictions) { restriction in @@ -73,7 +73,7 @@ struct ManualDetailsV: View { var common : TransactionCommon var details : WithdrawalDetails - @AppStorage("iconOnly") var iconOnly: Bool = false + @AppStorage("minimalistic") var minimalistic: Bool = false @State private var accountID = 0 @State private var listID = UUID() @@ -86,8 +86,8 @@ struct ManualDetailsV: View { var body: some View { if let accountDetails = details.exchangeCreditAccountDetails { - if !iconOnly { - Text("The Exchange is waiting for your wire-transfer.") + if !minimalistic { + Text("The Payment Service Provider is waiting for your wire-transfer.") .bold() .multilineTextAlignment(.leading) .listRowSeparator(.hidden) @@ -121,19 +121,19 @@ struct ManualDetailsV: View { } .padding(.leading) .padding(.top, -8) - let step1 = Text(iconOnly ? "**Step 1:** Copy+Paste this subject:" - : "**Step 1:** Copy this code and paste it into the subject/purpose field in your banking app or bank website:") + let step1 = Text(minimalistic ? "**Step 1:** Copy+Paste this subject:" + : "**Step 1:** Copy this code and paste it into the subject/purpose field in your banking app or bank website:") .multilineTextAlignment(.leading) let mandatory = Text("This is mandatory, otherwise your money will not arrive in this wallet.") .bold() .multilineTextAlignment(.leading) .listRowSeparator(.hidden) - let step2 = Text(iconOnly ? "**Step 2:** Copy+Paste this IBAN:" - : "**Step 2:** If you don't already have it in your banking favourites list, then copy and paste this IBAN into the receiver IBAN field in your banking app or website (and save it as favourite for the next time):") + let step2 = Text(minimalistic ? "**Step 2:** Copy+Paste this IBAN:" + : "**Step 2:** If you don't already have it in your banking favourites list, then copy and paste this IBAN into the receiver IBAN field in your banking app or website (and save it as favourite for the next time):") .multilineTextAlignment(.leading) .padding(.top) - let step3 = Text(iconOnly ? "**Step 3:** Transfer \(amountStr)." - : "**Step 3:** Finish the wire transfer of \(amountStr) in your banking app or website, then this withdrawal will proceed automatically.") + let step3 = Text(minimalistic ? "**Step 3:** Transfer \(amountStr)." + : "**Step 3:** Finish the wire transfer of \(amountStr) in your banking app or website, then this withdrawal will proceed automatically.") .multilineTextAlignment(.leading) .padding(.top) Group { @@ -142,15 +142,15 @@ struct ManualDetailsV: View { restrictions: account.creditRestrictions) .listRowSeparator(.visible) step1.listRowSeparator(.hidden) - if !iconOnly { + if !minimalistic { mandatory } cryptocode.listRowSeparator(.hidden) step2.listRowSeparator(.hidden) ibanCode.listRowSeparator(.hidden) step3.listRowSeparator(.visible) - Text(iconOnly ? "**Alternative:** Use this PayTo-Link:" - : "**Alternative:** If your bank already supports PayTo, you can use this PayTo-Link instead:") + Text(minimalistic ? "**Alternative:** Use this PayTo-Link:" + : "**Alternative:** If your bank already supports PayTo, you can use this PayTo-Link instead:") .multilineTextAlignment(.leading) .padding(.top) .listRowSeparator(.hidden) diff --git a/TalerWallet1/Views/Transactions/ThreeAmountsV.swift b/TalerWallet1/Views/Transactions/ThreeAmountsV.swift index b7b0b17..31b7d07 100644 --- a/TalerWallet1/Views/Transactions/ThreeAmountsV.swift +++ b/TalerWallet1/Views/Transactions/ThreeAmountsV.swift @@ -61,8 +61,8 @@ struct ThreeAmountsV: View { let summary: String? let merchant: String? - @AppStorage("iconOnly") var iconOnly: Bool = false - + @AppStorage("minimalistic") var minimalistic: Bool = false + var body: some View { let labelColor = Color(UIColor.label) let foreColor = pending ? WalletColors().pendingColor(incoming) @@ -80,14 +80,14 @@ struct ThreeAmountsV: View { .lineLimit(4) .padding(.bottom) } - AmountRowV(title: iconOnly ? topAbbrev : topTitle, + AmountRowV(title: minimalistic ? topAbbrev : topTitle, amount: topAmount, color: labelColor, large: false) .padding(.bottom, 4) .accessibilityElement(children: .combine) if let fee { - AmountRowV(title: iconOnly ? String(localized: "Fee (short):", defaultValue:"Fee:", comment:"short version") + AmountRowV(title: minimalistic ? String(localized: "Fee (short):", defaultValue:"Fee:", comment:"short version") : String(localized: "Fee (long):", defaultValue:"Fee:", comment:"long version"), amount: fee, color: labelColor, @@ -96,7 +96,7 @@ struct ThreeAmountsV: View { .accessibilityElement(children: .combine) } if let bottomAmount { - AmountRowV(title: iconOnly ? bottomAbbrev : bottomTitle, + AmountRowV(title: minimalistic ? bottomAbbrev : bottomTitle, amount: bottomAmount, color: foreColor, large: large) @@ -104,7 +104,7 @@ struct ThreeAmountsV: View { } if let baseURL { VStack(alignment: .leading) { - Text(iconOnly ? "Payment Provider:" : "Using Payment Provider:") + Text(minimalistic ? "Payment provider:" : "Using payment service provider:") .multilineTextAlignment(.leading) .accessibilityFont(.body) HStack { @@ -122,7 +122,7 @@ struct ThreeAmountsV: View { .accessibilityElement(children: .combine) } } header: { - if !iconOnly { + if !minimalistic { Text("Summary") .accessibilityFont(.title3) } diff --git a/TalerWallet1/Views/Transactions/TransactionSummaryV.swift b/TalerWallet1/Views/Transactions/TransactionSummaryV.swift index 153d55e..aa1e548 100644 --- a/TalerWallet1/Views/Transactions/TransactionSummaryV.swift +++ b/TalerWallet1/Views/Transactions/TransactionSummaryV.swift @@ -201,11 +201,11 @@ struct TransactionSummaryV: View { //extension TransactionSummaryV { struct KycButton: View { let destination: URL - @AppStorage("iconOnly") var iconOnly: Bool = false + @AppStorage("minimalistic") var minimalistic: Bool = false var body: some View { VStack(alignment: .leading) { // Show Hint that User must pass KYC on website - if !iconOnly { + if !minimalistic { Text("You need to pass a KYC procedure") .fixedSize(horizontal: false, vertical: true) // wrap in scrollview .multilineTextAlignment(.leading) // otherwise @@ -220,11 +220,11 @@ struct TransactionSummaryV: View { struct ConfirmationButton: View { let destination: URL - @AppStorage("iconOnly") var iconOnly: Bool = false + @AppStorage("minimalistic") var minimalistic: Bool = false var body: some View { VStack(alignment: .leading) { // Show Hint that User should Confirm on bank website - if !iconOnly { + if !minimalistic { Text("The bank is waiting for your confirmation.") // .fixedSize(horizontal: false, vertical: true) // wrap in scrollview .multilineTextAlignment(.leading) // otherwise |