Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Sweep through UI strings to internationalize #1148

Draft
wants to merge 6 commits into
base: main
Choose a base branch
from
Draft
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
32 changes: 30 additions & 2 deletions assets/l10n/app_en.arb
Original file line number Diff line number Diff line change
Expand Up @@ -56,6 +56,10 @@
"@profileButtonSendDirectMessage": {
"description": "Label for button in profile screen to navigate to DMs with the shown user."
},
"errorShowUserProfile": "Could not show user profile.",
"@errorShowUserProfile": {
"description": "Message that appears on the user profile page when the profile cannot be shown."
},
"permissionsNeededTitle": "Permissions needed",
"@permissionsNeededTitle": {
"description": "Title for dialog asking the user to grant additional permissions."
Expand Down Expand Up @@ -321,8 +325,8 @@
"@composeBoxSendTooltip": {
"description": "Tooltip for send button in compose box."
},
"composeBoxUnknownChannelName": "(unknown channel)",
"@composeBoxUnknownChannelName": {
"unknownChannelName": "(unknown channel)",
"@unknownChannelName": {
"description": "Replacement name for channel when it cannot be found in the store."
},
"composeBoxTopicHintText": "Topic",
Expand All @@ -340,6 +344,10 @@
"@unknownUserName": {
"description": "Name placeholder to use for a user when we don't know their name."
},
"messageListYouWithYourselfTitle": "DMs with yourself",
"@messageListYouWithYourselfTitle": {
"description": "Message list page title for a DM group that only includes yourself."
},
"messageListGroupYouAndOthers": "You and {others}",
"@messageListGroupYouAndOthers": {
"description": "Message list recipient header for a DM group with others.",
Expand Down Expand Up @@ -610,6 +618,14 @@
"@channelFeedButtonTooltip": {
"description": "Tooltip for button to navigate to a given channel's feed"
},
"notifChannelConversationLabel": "#{channel} > {topic}",
"@notifChannelConversationLabel": {
"description": "Label for a channel conversation notification.",
"placeholders": {
"channel": {"type": "String", "example": "channel name"},
"topic": {"type": "String", "example": "topic name"}
}
},
"notifGroupDmConversationLabel": "{senderFullName} to you and {numOthers, plural, =1{1 other} other{{numOthers} others}}",
"@notifGroupDmConversationLabel": {
"description": "Label for a group DM conversation notification.",
Expand All @@ -618,6 +634,18 @@
"numOthers": {"type": "int", "example": "4"}
}
},
"pinnedSubscriptionsLabel": "Pinned",
"@pinnedSubscriptionsLabel": {
"description": "Label for the list of pinned subscribed channels."
},
"unpinnedSubscriptionsLabel": "Unpinned",
"@unpinnedSubscriptionsLabel": {
"description": "Label for the list of unpinned subscribed channels."
},
"noSubscriptions": "No channels found",
"@noSubscriptions": {
"description": "Text to display when there are no subscribed channels."
},
"notifSelfUser": "You",
"@notifSelfUser": {
"description": "Display name for the user themself, to show after replying in an Android notification"
Expand Down
38 changes: 37 additions & 1 deletion lib/generated/l10n/zulip_localizations.dart
Original file line number Diff line number Diff line change
Expand Up @@ -187,6 +187,12 @@ abstract class ZulipLocalizations {
/// **'Send direct message'**
String get profileButtonSendDirectMessage;

/// Message that appears on the user profile page when the profile cannot be shown.
///
/// In en, this message translates to:
/// **'Could not show user profile.'**
String get errorShowUserProfile;

/// Title for dialog asking the user to grant additional permissions.
///
/// In en, this message translates to:
Expand Down Expand Up @@ -533,7 +539,7 @@ abstract class ZulipLocalizations {
///
/// In en, this message translates to:
/// **'(unknown channel)'**
String get composeBoxUnknownChannelName;
String get unknownChannelName;

/// Hint text for topic input widget in compose box.
///
Expand All @@ -553,6 +559,12 @@ abstract class ZulipLocalizations {
/// **'(unknown user)'**
String get unknownUserName;

/// Message list page title for a DM group that only includes yourself.
///
/// In en, this message translates to:
/// **'DMs with yourself'**
String get messageListYouWithYourselfTitle;

/// Message list recipient header for a DM group with others.
///
/// In en, this message translates to:
Expand Down Expand Up @@ -925,12 +937,36 @@ abstract class ZulipLocalizations {
/// **'Channel feed'**
String get channelFeedButtonTooltip;

/// Label for a channel conversation notification.
///
/// In en, this message translates to:
/// **'#{channel} > {topic}'**
String notifChannelConversationLabel(String channel, String topic);

/// Label for a group DM conversation notification.
///
/// In en, this message translates to:
/// **'{senderFullName} to you and {numOthers, plural, =1{1 other} other{{numOthers} others}}'**
String notifGroupDmConversationLabel(String senderFullName, int numOthers);

/// Label for the list of pinned subscribed channels.
///
/// In en, this message translates to:
/// **'Pinned'**
String get pinnedSubscriptionsLabel;

/// Label for the list of unpinned subscribed channels.
///
/// In en, this message translates to:
/// **'Unpinned'**
String get unpinnedSubscriptionsLabel;

/// Text to display when there are no subscribed channels.
///
/// In en, this message translates to:
/// **'No channels found'**
String get noSubscriptions;

/// Display name for the user themself, to show after replying in an Android notification
///
/// In en, this message translates to:
Expand Down
22 changes: 21 additions & 1 deletion lib/generated/l10n/zulip_localizations_ar.dart
Original file line number Diff line number Diff line change
Expand Up @@ -52,6 +52,9 @@ class ZulipLocalizationsAr extends ZulipLocalizations {
@override
String get profileButtonSendDirectMessage => 'Send direct message';

@override
String get errorShowUserProfile => 'Could not show user profile.';

@override
String get permissionsNeededTitle => 'Permissions needed';

Expand Down Expand Up @@ -256,7 +259,7 @@ class ZulipLocalizationsAr extends ZulipLocalizations {
String get composeBoxSendTooltip => 'Send';

@override
String get composeBoxUnknownChannelName => '(unknown channel)';
String get unknownChannelName => '(unknown channel)';

@override
String get composeBoxTopicHintText => 'Topic';
Expand All @@ -269,6 +272,9 @@ class ZulipLocalizationsAr extends ZulipLocalizations {
@override
String get unknownUserName => '(unknown user)';

@override
String get messageListYouWithYourselfTitle => 'DMs with yourself';

@override
String messageListGroupYouAndOthers(String others) {
return 'You and $others';
Expand Down Expand Up @@ -481,6 +487,11 @@ class ZulipLocalizationsAr extends ZulipLocalizations {
@override
String get channelFeedButtonTooltip => 'Channel feed';

@override
String notifChannelConversationLabel(String channel, String topic) {
return '#$channel > $topic';
}

@override
String notifGroupDmConversationLabel(String senderFullName, int numOthers) {
String _temp0 = intl.Intl.pluralLogic(
Expand All @@ -492,6 +503,15 @@ class ZulipLocalizationsAr extends ZulipLocalizations {
return '$senderFullName to you and $_temp0';
}

@override
String get pinnedSubscriptionsLabel => 'Pinned';

@override
String get unpinnedSubscriptionsLabel => 'Unpinned';

@override
String get noSubscriptions => 'No channels found';

@override
String get notifSelfUser => 'You';

Expand Down
22 changes: 21 additions & 1 deletion lib/generated/l10n/zulip_localizations_en.dart
Original file line number Diff line number Diff line change
Expand Up @@ -52,6 +52,9 @@ class ZulipLocalizationsEn extends ZulipLocalizations {
@override
String get profileButtonSendDirectMessage => 'Send direct message';

@override
String get errorShowUserProfile => 'Could not show user profile.';

@override
String get permissionsNeededTitle => 'Permissions needed';

Expand Down Expand Up @@ -256,7 +259,7 @@ class ZulipLocalizationsEn extends ZulipLocalizations {
String get composeBoxSendTooltip => 'Send';

@override
String get composeBoxUnknownChannelName => '(unknown channel)';
String get unknownChannelName => '(unknown channel)';

@override
String get composeBoxTopicHintText => 'Topic';
Expand All @@ -269,6 +272,9 @@ class ZulipLocalizationsEn extends ZulipLocalizations {
@override
String get unknownUserName => '(unknown user)';

@override
String get messageListYouWithYourselfTitle => 'DMs with yourself';

@override
String messageListGroupYouAndOthers(String others) {
return 'You and $others';
Expand Down Expand Up @@ -481,6 +487,11 @@ class ZulipLocalizationsEn extends ZulipLocalizations {
@override
String get channelFeedButtonTooltip => 'Channel feed';

@override
String notifChannelConversationLabel(String channel, String topic) {
return '#$channel > $topic';
}

@override
String notifGroupDmConversationLabel(String senderFullName, int numOthers) {
String _temp0 = intl.Intl.pluralLogic(
Expand All @@ -492,6 +503,15 @@ class ZulipLocalizationsEn extends ZulipLocalizations {
return '$senderFullName to you and $_temp0';
}

@override
String get pinnedSubscriptionsLabel => 'Pinned';

@override
String get unpinnedSubscriptionsLabel => 'Unpinned';

@override
String get noSubscriptions => 'No channels found';

@override
String get notifSelfUser => 'You';

Expand Down
22 changes: 21 additions & 1 deletion lib/generated/l10n/zulip_localizations_fr.dart
Original file line number Diff line number Diff line change
Expand Up @@ -52,6 +52,9 @@ class ZulipLocalizationsFr extends ZulipLocalizations {
@override
String get profileButtonSendDirectMessage => 'Send direct message';

@override
String get errorShowUserProfile => 'Could not show user profile.';

@override
String get permissionsNeededTitle => 'Permissions needed';

Expand Down Expand Up @@ -256,7 +259,7 @@ class ZulipLocalizationsFr extends ZulipLocalizations {
String get composeBoxSendTooltip => 'Send';

@override
String get composeBoxUnknownChannelName => '(unknown channel)';
String get unknownChannelName => '(unknown channel)';

@override
String get composeBoxTopicHintText => 'Topic';
Expand All @@ -269,6 +272,9 @@ class ZulipLocalizationsFr extends ZulipLocalizations {
@override
String get unknownUserName => '(unknown user)';

@override
String get messageListYouWithYourselfTitle => 'DMs with yourself';

@override
String messageListGroupYouAndOthers(String others) {
return 'You and $others';
Expand Down Expand Up @@ -481,6 +487,11 @@ class ZulipLocalizationsFr extends ZulipLocalizations {
@override
String get channelFeedButtonTooltip => 'Channel feed';

@override
String notifChannelConversationLabel(String channel, String topic) {
return '#$channel > $topic';
}

@override
String notifGroupDmConversationLabel(String senderFullName, int numOthers) {
String _temp0 = intl.Intl.pluralLogic(
Expand All @@ -492,6 +503,15 @@ class ZulipLocalizationsFr extends ZulipLocalizations {
return '$senderFullName to you and $_temp0';
}

@override
String get pinnedSubscriptionsLabel => 'Pinned';

@override
String get unpinnedSubscriptionsLabel => 'Unpinned';

@override
String get noSubscriptions => 'No channels found';

@override
String get notifSelfUser => 'You';

Expand Down
22 changes: 21 additions & 1 deletion lib/generated/l10n/zulip_localizations_ja.dart
Original file line number Diff line number Diff line change
Expand Up @@ -52,6 +52,9 @@ class ZulipLocalizationsJa extends ZulipLocalizations {
@override
String get profileButtonSendDirectMessage => 'ダイレクトメッセージを送信';

@override
String get errorShowUserProfile => 'Could not show user profile.';

@override
String get permissionsNeededTitle => 'Permissions needed';

Expand Down Expand Up @@ -256,7 +259,7 @@ class ZulipLocalizationsJa extends ZulipLocalizations {
String get composeBoxSendTooltip => 'Send';

@override
String get composeBoxUnknownChannelName => '(unknown channel)';
String get unknownChannelName => '(unknown channel)';

@override
String get composeBoxTopicHintText => 'Topic';
Expand All @@ -269,6 +272,9 @@ class ZulipLocalizationsJa extends ZulipLocalizations {
@override
String get unknownUserName => '(unknown user)';

@override
String get messageListYouWithYourselfTitle => 'DMs with yourself';

@override
String messageListGroupYouAndOthers(String others) {
return 'You and $others';
Expand Down Expand Up @@ -481,6 +487,11 @@ class ZulipLocalizationsJa extends ZulipLocalizations {
@override
String get channelFeedButtonTooltip => 'Channel feed';

@override
String notifChannelConversationLabel(String channel, String topic) {
return '#$channel > $topic';
}

@override
String notifGroupDmConversationLabel(String senderFullName, int numOthers) {
String _temp0 = intl.Intl.pluralLogic(
Expand All @@ -492,6 +503,15 @@ class ZulipLocalizationsJa extends ZulipLocalizations {
return '$senderFullName to you and $_temp0';
}

@override
String get pinnedSubscriptionsLabel => 'Pinned';

@override
String get unpinnedSubscriptionsLabel => 'Unpinned';

@override
String get noSubscriptions => 'No channels found';

@override
String get notifSelfUser => 'You';

Expand Down
Loading