MESSENGER-3710 Layout and text fixes

This commit is contained in:
Frank Rotermund
2022-12-08 11:47:21 +01:00
parent 99ada32313
commit 0ab0ae13dd
5 changed files with 18 additions and 31 deletions

View File

@@ -510,10 +510,11 @@
// MARK: - Onboarding
"onboarding_splash_login_button_title" = "Loslegen";
"authentication_server_selection_server_url" = "Serveradresse";
// MARK: - Login Protection
"bwi_login_protection_error_message" = "Der angegebene Server ist nicht für die Nutzung mit dem %@ vorgesehen";
"bwi_login_protection_info_message" = "Dein Server ist leider noch nicht für den %@ eingerichtet. Wenn du aus der Öffentlichen Verwaltung bist und Fragen hast, wie Du den %@ nutzen kannst, besuche unserer Website.";
"bwi_login_protection_info_message" = "Dein Server ist leider noch nicht für den %@ eingerichtet. Wenn du aus der Öffentlichen Verwaltung bist und Fragen hast, wie Du den %@ nutzen kannst, besuche unsere Website.";
"bwi_login_protection_info_button" = "Website";
// MARK: - Polls
@@ -548,3 +549,4 @@
"authentication_login_description" = "Mit deinem Konto anmelden";
"authentication_dataprivacy_text" = "Hinweise zur Verarbeitung Ihrer Daten und Ihrer Rechte erhalten Sie in unseren ";
"authentication_dataprivacy_link" = "Datenschutzhinweisen";
"authentication_server_selection_server_url" = "Homeserver URL";

View File

@@ -47,6 +47,10 @@ public class BWIL10n: NSObject {
public static var authenticationServerSelectionLoginTitle: String {
return BWIL10n.tr("Bwi", "authentication_server_selection_login_title")
}
/// Homeserver URL
public static var authenticationServerSelectionServerUrl: String {
return BWIL10n.tr("Bwi", "authentication_server_selection_server_url")
}
/// PIN eingeben
public static var biometricsModeCantUnlockButtonTitle: String {
return BWIL10n.tr("Bwi", "biometrics_mode_cant_unlock_button_title")
@@ -179,7 +183,7 @@ public class BWIL10n: NSObject {
public static var bwiLoginProtectionInfoButton: String {
return BWIL10n.tr("Bwi", "bwi_login_protection_info_button")
}
/// Dein Server ist leider noch nicht für den %@ eingerichtet. Wenn du aus der Öffentlichen Verwaltung bist und Fragen hast, wie Du den %@ nutzen kannst, besuche unserer Website.
/// Dein Server ist leider noch nicht für den %@ eingerichtet. Wenn du aus der Öffentlichen Verwaltung bist und Fragen hast, wie Du den %@ nutzen kannst, besuche unsere Website.
public static func bwiLoginProtectionInfoMessage(_ p1: String, _ p2: String) -> String {
return BWIL10n.tr("Bwi", "bwi_login_protection_info_message", p1, p2)
}

View File

@@ -30,7 +30,12 @@ class AuthenticationServerSelectionViewModel: AuthenticationServerSelectionViewM
// MARK: - Setup
init(homeserverAddress: String, flow: AuthenticationFlow, hasModalPresentation: Bool) {
let bindings = AuthenticationServerSelectionBindings(homeserverAddress: homeserverAddress)
var bindings = AuthenticationServerSelectionBindings(homeserverAddress: homeserverAddress)
if BWIBuildSettings.shared.bumLoginFlowLayout {
bindings.homeserverAddress = ""
}
super.init(initialViewState: AuthenticationServerSelectionViewState(bindings: bindings,
flow: flow,
hasModalPresentation: hasModalPresentation))

View File

@@ -110,7 +110,7 @@ struct AuthenticationServerSelectionScreen: View {
/// The text field, extracted for iOS 15 modifiers to be applied.
var textField: some View {
TextField(VectorL10n.authenticationServerSelectionServerUrl, text: $viewModel.homeserverAddress) {
TextField(BWIL10n.authenticationServerSelectionServerUrl, text: $viewModel.homeserverAddress) {
isEditingTextField = $0
}
.keyboardType(.URL)

View File

@@ -15,32 +15,6 @@
* limitations under the License.
*/
/*
struct OnboardingIconImage: View {
@Environment(\.theme) private var theme
let image: ImageAsset
var body: some View {
Image(image.name)
.resizable()
.renderingMode(.template)
.foregroundColor(theme.colors.accent)
.frame(width: OnboardingMetrics.iconSize, height: OnboardingMetrics.iconSize)
.background(Circle().foregroundColor(.white).padding(2))
.accessibilityHidden(true)
}
}
// MARK: - Previews
struct OnboardingIconImage_Previews: PreviewProvider {
static var previews: some View {
OnboardingIconImage(image: Asset.Images.authenticationEmailIcon)
}
}
*/
import SwiftUI
struct ServerIcon: View {
@@ -53,7 +27,9 @@ struct ServerIcon: View {
Image(image.name)
.resizable()
.frame(width: size, height: size * 1.3)
.background(Circle().foregroundColor(.white).padding(2))
.padding()
.background(Color(.white))
.cornerRadius(20)
.accessibilityHidden(true)
}
}