Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 4 additions & 4 deletions Authorization/Authorization/SwiftGen/Strings.swift
Original file line number Diff line number Diff line change
Expand Up @@ -91,14 +91,14 @@ public enum AuthLocalization {
}
/// Create account
public static let createAccountBtn = AuthLocalization.tr("Localizable", "SIGN_UP.CREATE_ACCOUNT_BTN", fallback: "Create account")
/// Hide optional Fields
public static let hideFields = AuthLocalization.tr("Localizable", "SIGN_UP.HIDE_FIELDS", fallback: "Hide optional Fields")
/// Hide optional fields
public static let hideFields = AuthLocalization.tr("Localizable", "SIGN_UP.HIDE_FIELDS", fallback: "Hide optional fields")
/// I agree that %@ may send me marketing messages.
public static func marketingEmailTitle(_ p1: Any) -> String {
return AuthLocalization.tr("Localizable", "SIGN_UP.MARKETING_EMAIL_TITLE", String(describing: p1), fallback: "I agree that %@ may send me marketing messages.")
}
/// Show optional Fields
public static let showFields = AuthLocalization.tr("Localizable", "SIGN_UP.SHOW_FIELDS", fallback: "Show optional Fields")
/// Show optional fields
public static let showFields = AuthLocalization.tr("Localizable", "SIGN_UP.SHOW_FIELDS", fallback: "Show optional fields")
/// Create an account to start learning today!
public static let subtitle = AuthLocalization.tr("Localizable", "SIGN_UP.SUBTITLE", fallback: "Create an account to start learning today!")
/// You've successfully signed in.
Expand Down
4 changes: 2 additions & 2 deletions Authorization/Authorization/en.lproj/Localizable.strings
Original file line number Diff line number Diff line change
Expand Up @@ -27,8 +27,8 @@ accordance with the [Privacy Policy.](%@)";

"SIGN_UP.SUBTITLE" = "Create an account to start learning today!";
"SIGN_UP.CREATE_ACCOUNT_BTN" = "Create account";
"SIGN_UP.HIDE_FIELDS" = "Hide optional Fields";
"SIGN_UP.SHOW_FIELDS" = "Show optional Fields";
"SIGN_UP.HIDE_FIELDS" = "Hide optional fields";
"SIGN_UP.SHOW_FIELDS" = "Show optional fields";
"SIGN_UP.SUCCESS_SIGNIN_LABEL" = "You've successfully signed in.";
"SIGN_UP.SUCCESS_SIGNIN_SUBLABEL" = "We just need a little more information before you start learning.";
"SIGN_UP.AGREEMENT" = "By creating an account, you agree to the [%@ End User License Agreement](%@) and [%@ Terms of Service and Honor Code](%@) and you acknowledge that %@ and each Member process your personal data inaccordance with the [Privacy Policy.](%@)";
Expand Down
5 changes: 4 additions & 1 deletion Core/Core/View/Base/PickerView.swift
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,10 @@ public struct PickerView: View {
}
}
}, label: {
Text(config.selectedItem?.value ?? "")
Text(config.selectedItem?.value ?? config.field.label)
.foregroundColor(config.selectedItem == nil
? Theme.Colors.textInputPlaceholderColor
: Theme.Colors.textInputTextColor)
Spacer()
Image(systemName: "chevron.down")
})
Expand Down
5 changes: 2 additions & 3 deletions Core/Core/View/Base/RegistrationTextField.swift
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,6 @@ import Theme

public struct RegistrationTextField: View {

@State public var placeholder: String = ""
public var keyboardType: UIKeyboardType
public var textContentType: UITextContentType
private var isTextArea: Bool
Expand Down Expand Up @@ -65,7 +64,7 @@ public struct RegistrationTextField: View {
.accessibilityIdentifier("\(config.field.name)_textarea")
} else {
if textContentType == .password {
SecureInputView($config.text)
SecureInputView($config.text, placeholder: config.field.label)
.keyboardType(keyboardType)
.textContentType(textContentType)
.autocapitalization(.none)
Expand All @@ -87,7 +86,7 @@ public struct RegistrationTextField: View {
.shake($config.shake)
.accessibilityIdentifier("\(config.field.name)_textfield")
} else {
TextField(placeholder, text: $config.text)
TextField(config.field.label, text: $config.text)
.font(Theme.Fonts.bodyLarge)
.foregroundColor(Theme.Colors.textInputTextColor)
.keyboardType(keyboardType)
Expand Down
8 changes: 5 additions & 3 deletions Core/Core/View/Base/SecureInputView.swift
Original file line number Diff line number Diff line change
Expand Up @@ -12,18 +12,20 @@ public struct SecureInputView: View {

@Binding private var text: String
@State private var isSecured: Bool = true
private let placeholder: String

public init(_ text: Binding<String>) {
public init(_ text: Binding<String>, placeholder: String = "") {
self._text = text
self.placeholder = placeholder
}

public var body: some View {
ZStack(alignment: .trailing) {
Group {
if isSecured {
SecureField("", text: $text)
SecureField(placeholder, text: $text)
} else {
TextField("", text: $text)
TextField(placeholder, text: $text)
.autocapitalization(.none)
}
}.padding(.trailing, 32)
Expand Down
Loading