diff --git a/Localization/app.json b/Localization/app.json index 8287a00a5..9f6cdecac 100644 --- a/Localization/app.json +++ b/Localization/app.json @@ -218,6 +218,13 @@ "get_started": "Get Started", "log_in": "Log In" }, + "login": { + "title": "", + "subtitle": "", + "server_search_field": { + "placeholder": "Search for your server" + } + } "server_picker": { "title": "Mastodon is made of users in different servers.", "subtitle": "Pick a server based on your region, interests, or a general purpose one. You can still chat with anyone on Mastodon, regardless of your servers.", diff --git a/Mastodon/Scene/Onboarding/Login/MastodonLoginView.swift b/Mastodon/Scene/Onboarding/Login/MastodonLoginView.swift index d59e30dd4..03c357fca 100644 --- a/Mastodon/Scene/Onboarding/Login/MastodonLoginView.swift +++ b/Mastodon/Scene/Onboarding/Login/MastodonLoginView.swift @@ -7,6 +7,7 @@ import UIKit import MastodonAsset +import MastodonLocalization class MastodonLoginView: UIView { @@ -26,13 +27,13 @@ class MastodonLoginView: UIView { titleLabel = UILabel() titleLabel.font = MastodonLoginViewController.largeTitleFont titleLabel.textColor = MastodonLoginViewController.largeTitleTextColor - titleLabel.text = "Welcome Back" //TODO: @zeitschlag localization + titleLabel.text = L10n.Scene.Login.title titleLabel.numberOfLines = 0 subtitleLabel = UILabel() subtitleLabel.font = MastodonLoginViewController.subTitleFont subtitleLabel.textColor = MastodonLoginViewController.subTitleTextColor - subtitleLabel.text = "Log you in with the server where you created your account" //TODO: @zeitschlag localization + subtitleLabel.text = L10n.Scene.Login.subtitle subtitleLabel.numberOfLines = 0 headerStackView = UIStackView(arrangedSubviews: [titleLabel, subtitleLabel]) @@ -43,7 +44,7 @@ class MastodonLoginView: UIView { searchTextField = UITextField() searchTextField.translatesAutoresizingMaskIntoConstraints = false searchTextField.backgroundColor = Asset.Scene.Onboarding.textFieldBackground.color - searchTextField.placeholder = "Search for your server" //TODO: @zeitschlag Localization + searchTextField.placeholder = L10n.Scene.Login.ServerSearchField.placeholder searchTextField.leftView = UIImageView(image: UIImage(systemName: "magnifyingglass")) searchTextField.leftViewMode = .always searchTextField.layer.cornerRadius = 10 diff --git a/MastodonSDK/Sources/MastodonLocalization/Generated/Strings.swift b/MastodonSDK/Sources/MastodonLocalization/Generated/Strings.swift index 1ad98b0ea..af0f4c628 100644 --- a/MastodonSDK/Sources/MastodonLocalization/Generated/Strings.swift +++ b/MastodonSDK/Sources/MastodonLocalization/Generated/Strings.swift @@ -665,6 +665,16 @@ public enum L10n { } } } + public enum Login { + /// Log you in with the server where you created your account + public static let subtitle = L10n.tr("Localizable", "Scene.Login.Subtitle") + /// Welcome Back! + public static let title = L10n.tr("Localizable", "Scene.Login.Title") + public enum ServerSearchField { + /// Search for your server + public static let placeholder = L10n.tr("Localizable", "Scene.Login.ServerSearchField.Placeholder") + } + } public enum Notification { public enum FollowRequest { /// Accept diff --git a/MastodonSDK/Sources/MastodonLocalization/Resources/en.lproj/Localizable.strings b/MastodonSDK/Sources/MastodonLocalization/Resources/en.lproj/Localizable.strings index 07ccd2c1b..0ede22a38 100644 --- a/MastodonSDK/Sources/MastodonLocalization/Resources/en.lproj/Localizable.strings +++ b/MastodonSDK/Sources/MastodonLocalization/Resources/en.lproj/Localizable.strings @@ -315,6 +315,9 @@ uploaded to Mastodon."; "Scene.Register.Input.Username.DuplicatePrompt" = "This username is taken."; "Scene.Register.Input.Username.Placeholder" = "username"; "Scene.Register.LetsGetYouSetUpOnDomain" = "Let’s get you set up on %@"; +"Scene.Login.Title" = "Welcome Back!"; +"Scene.Login.Subtitle" = "Log you in with the server where you created your account"; +"Scene.Login.ServerSearchField.Placeholder" = "Search for your server"; "Scene.Register.Title" = "Let’s get you set up on %@"; "Scene.Report.Content1" = "Are there any other posts you’d like to add to the report?"; "Scene.Report.Content2" = "Is there anything the moderators should know about this report?"; @@ -454,4 +457,4 @@ uploaded to Mastodon."; back in your hands."; "Scene.Wizard.AccessibilityHint" = "Double tap to dismiss this wizard"; "Scene.Wizard.MultipleAccountSwitchIntroDescription" = "Switch between multiple accounts by holding the profile button."; -"Scene.Wizard.NewInMastodon" = "New in Mastodon"; \ No newline at end of file +"Scene.Wizard.NewInMastodon" = "New in Mastodon";