gnunet-svn
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[taler-taler-ios] 14/28: ToSButton


From: gnunet
Subject: [taler-taler-ios] 14/28: ToSButton
Date: Tue, 19 Sep 2023 03:44:33 +0200

This is an automated email from the git hooks/post-receive script.

marc-stibane pushed a commit to branch master
in repository taler-ios.

commit 42d0f2712016cafa7931f22bdc6fb9881fe79c94
Author: Marc Stibane <marc@taler.net>
AuthorDate: Sun Sep 10 13:30:21 2023 +0200

    ToSButton
---
 TalerWallet1/Views/HelperViews/ToSButtonView.swift | 20 ++++++++++++++++++--
 1 file changed, 18 insertions(+), 2 deletions(-)

diff --git a/TalerWallet1/Views/HelperViews/ToSButtonView.swift 
b/TalerWallet1/Views/HelperViews/ToSButtonView.swift
index fe3e4ff..9799c5d 100644
--- a/TalerWallet1/Views/HelperViews/ToSButtonView.swift
+++ b/TalerWallet1/Views/HelperViews/ToSButtonView.swift
@@ -9,11 +9,27 @@
 import SwiftUI
 
 struct ToSButtonView: View {
+    let exchangeBaseUrl: String?
+    let viewID: Int         // either VIEW_WITHDRAW_TOS or SHEET_WITHDRAW_TOS
+    let p2p: Bool
+
     var body: some View {
-        Text(/*@START_MENU_TOKEN@*/"Hello, World!"/*@END_MENU_TOKEN@*/)
+        let hint = 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.")
+        Text(hint)
+            .accessibilityFont(.body)
+            .multilineTextAlignment(.leading)
+            .padding()
+        NavigationLink(destination: LazyView {
+            WithdrawTOSView(exchangeBaseUrl: exchangeBaseUrl,
+                                     viewID: viewID,
+                               acceptAction: nil)         // pop back to here
+        }) {
+            Text("Terms of Service")  // VIEW_WITHDRAW_TOS
+        }.buttonStyle(TalerButtonStyle(type: .prominent))
     }
 }
 
 #Preview {
-    ToSButtonView()
+    ToSButtonView(exchangeBaseUrl: nil, viewID: 0, p2p: false)
 }

-- 
To stop receiving notification emails like this one, please contact
gnunet@gnunet.org.



reply via email to

[Prev in Thread] Current Thread [Next in Thread]