mirror of
https://github.com/mastodon/mastodon-ios.git
synced 2025-02-03 10:47:35 +01:00
Add localization (IOS-37)
This commit is contained in:
parent
48a14bc63c
commit
49307a316f
@ -870,6 +870,12 @@
|
||||
"configuration_description": "Show latest followers.",
|
||||
"title": "Latest followers",
|
||||
"last_update": "Last update: %s"
|
||||
},
|
||||
"hashtag": {
|
||||
"configuration": {
|
||||
"display_name": "Hashtag",
|
||||
"description": "Shows a recent status with the selected hashtag."
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -1543,6 +1543,14 @@ public enum L10n {
|
||||
/// FOLLOWERS
|
||||
public static let title = L10n.tr("Localizable", "Widget.FollowersCount.Title", fallback: "FOLLOWERS")
|
||||
}
|
||||
public enum Hashtag {
|
||||
public enum Configuration {
|
||||
/// Shows a recent status with the selected hashtag
|
||||
public static let description = L10n.tr("Localizable", "Widget.Hashtag.Configuration.Description", fallback: "Shows a recent status with the selected hashtag")
|
||||
/// Hashtag
|
||||
public static let displayName = L10n.tr("Localizable", "Widget.Hashtag.Configuration.DisplayName", fallback: "Hashtag")
|
||||
}
|
||||
}
|
||||
public enum LatestFollowers {
|
||||
/// Show latest followers.
|
||||
public static let configurationDescription = L10n.tr("Localizable", "Widget.LatestFollowers.ConfigurationDescription", fallback: "Show latest followers.")
|
||||
|
@ -543,3 +543,5 @@ uploaded to Mastodon.";
|
||||
"Widget.MultipleFollowers.ConfigurationDisplayName" = "Multiple followers";
|
||||
"Widget.MultipleFollowers.MockUser.AccountName" = "another@follower.social";
|
||||
"Widget.MultipleFollowers.MockUser.DisplayName" = "Another follower";
|
||||
"Widget.Hashtag.Configuration.Description" = "Shows a recent status with the selected hashtag";
|
||||
"Widget.Hashtag.Configuration.DisplayName" = "Hashtag";
|
||||
|
@ -543,3 +543,5 @@ uploaded to Mastodon.";
|
||||
"Widget.MultipleFollowers.ConfigurationDisplayName" = "Multiple followers";
|
||||
"Widget.MultipleFollowers.MockUser.AccountName" = "another@follower.social";
|
||||
"Widget.MultipleFollowers.MockUser.DisplayName" = "Another follower";
|
||||
"Widget.Hashtag.Configuration.Description" = "Shows a recent status with the selected hashtag";
|
||||
"Widget.Hashtag.Configuration.DisplayName" = "Hashtag";
|
||||
|
@ -3,6 +3,7 @@
|
||||
import WidgetKit
|
||||
import SwiftUI
|
||||
import MastodonSDK
|
||||
import MastodonLocalization
|
||||
|
||||
struct HashtagWidgetProvider: IntentTimelineProvider {
|
||||
func placeholder(in context: Context) -> HashtagWidgetTimelineEntry {
|
||||
@ -145,9 +146,8 @@ struct HashtagWidget: Widget {
|
||||
IntentConfiguration(kind: "Hashtag", intent: HashtagIntent.self, provider: HashtagWidgetProvider()) { entry in
|
||||
HashtagWidgetView(entry: entry)
|
||||
}
|
||||
//TODO: @zeitschlag Add Localization
|
||||
.configurationDisplayName("Hashtag")
|
||||
.description("Show a Hashtag")
|
||||
.configurationDisplayName(L10n.Widget.Hashtag.Configuration.displayName)
|
||||
.description(L10n.Widget.Hashtag.Configuration.description)
|
||||
.supportedFamilies(availableFamilies)
|
||||
}
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user