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
20 changes: 20 additions & 0 deletions assets/l10n/app_en.arb
Original file line number Diff line number Diff line change
Expand Up @@ -1661,6 +1661,26 @@
"@markReadOnScrollSettingConversationsDescription": {
"description": "Description for a value of setting controlling which message-list views should mark read on scroll."
},
"notificationSettingsPageTitle": "Notifications",
"@notificationSettingsPageTitle": {
"description": "Title of settings page for notifications."
},
"offlineNotificationsSettingTitle": "Notifications when offline",
"@offlineNotificationsSettingTitle": {
"description": "Label for toggling mobile notifications for direct messages and mentions received while offline."
},
"onlineNotificationsSettingTitle": "Notifications when online",
"@onlineNotificationsSettingTitle": {
"description": "Label for toggling mobile notifications for direct messages and mentions received while online."
},
"channelNotificationsSettingTitle": "Channel notifications",
"@channelNotificationsSettingTitle": {
"description": "Label for toggling mobile notifications for channel messages."
},
"notificationSettingUpdateFailedTitle": "Failed to update notification setting",
"@notificationSettingUpdateFailedTitle": {
"description": "Error title when changing a notification setting failed."
},
"experimentalFeatureSettingsPageTitle": "Experimental features",
"@experimentalFeatureSettingsPageTitle": {
"description": "Title of settings page for experimental, in-development features"
Expand Down
3 changes: 3 additions & 0 deletions lib/api/model/events.dart
Original file line number Diff line number Diff line change
Expand Up @@ -269,6 +269,9 @@ class UserSettingsUpdateEvent extends Event {
case UserSettingName.emojiset:
return Emojiset.fromRawString(value as String);
case UserSettingName.webInboxShowChannelFolders:
case UserSettingName.enableChannelPushNotifications:
case UserSettingName.enableOfflinePushNotifications:
case UserSettingName.enableOnlinePushNotifications:
case UserSettingName.presenceEnabled:
return value as bool;
case null:
Expand Down
6 changes: 6 additions & 0 deletions lib/api/model/events.g.dart

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

7 changes: 7 additions & 0 deletions lib/api/model/initial_snapshot.dart
Original file line number Diff line number Diff line change
Expand Up @@ -385,6 +385,10 @@ class UserSettings {
Emojiset emojiset;
@JsonKey(defaultValue: true)
bool webInboxShowChannelFolders; // TODO(server-12) remove default value
@JsonKey(name: 'enable_stream_push_notifications')
bool enableChannelPushNotifications;
bool enableOfflinePushNotifications;
bool enableOnlinePushNotifications;
bool presenceEnabled;

// TODO more, as needed. When adding a setting here, please also:
Expand All @@ -399,6 +403,9 @@ class UserSettings {
required this.displayEmojiReactionUsers,
required this.emojiset,
required this.webInboxShowChannelFolders,
required this.enableChannelPushNotifications,
required this.enableOfflinePushNotifications,
required this.enableOnlinePushNotifications,
required this.presenceEnabled,
});

Expand Down
35 changes: 24 additions & 11 deletions lib/api/model/initial_snapshot.g.dart

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 4 additions & 0 deletions lib/api/model/model.dart
Original file line number Diff line number Diff line change
Expand Up @@ -340,6 +340,10 @@ enum UserSettingName {
displayEmojiReactionUsers,
emojiset,
webInboxShowChannelFolders,
@JsonValue('enable_stream_push_notifications')
enableChannelPushNotifications,
enableOfflinePushNotifications,
enableOnlinePushNotifications,
presenceEnabled,
;

Expand Down
6 changes: 6 additions & 0 deletions lib/api/model/model.g.dart

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

3 changes: 3 additions & 0 deletions lib/api/route/settings.dart
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,9 @@ Future<void> updateSettings(ApiConnection connection, {
case UserSettingName.emojiset:
value = RawParameter((valueRaw as Emojiset).toJson());
case UserSettingName.webInboxShowChannelFolders:
case UserSettingName.enableChannelPushNotifications:
case UserSettingName.enableOfflinePushNotifications:
case UserSettingName.enableOnlinePushNotifications:
case UserSettingName.presenceEnabled:
value = valueRaw as bool;
}
Expand Down
30 changes: 30 additions & 0 deletions lib/generated/l10n/zulip_localizations.dart
Original file line number Diff line number Diff line change
Expand Up @@ -2412,6 +2412,36 @@ abstract class ZulipLocalizations {
/// **'Messages will be automatically marked as read only when viewing a single topic or direct message conversation.'**
String get markReadOnScrollSettingConversationsDescription;

/// Title of settings page for notifications.
///
/// In en, this message translates to:
/// **'Notifications'**
String get notificationSettingsPageTitle;

/// Label for toggling mobile notifications for direct messages and mentions received while offline.
///
/// In en, this message translates to:
/// **'Notifications when offline'**
String get offlineNotificationsSettingTitle;

/// Label for toggling mobile notifications for direct messages and mentions received while online.
///
/// In en, this message translates to:
/// **'Notifications when online'**
String get onlineNotificationsSettingTitle;

/// Label for toggling mobile notifications for channel messages.
///
/// In en, this message translates to:
/// **'Channel notifications'**
String get channelNotificationsSettingTitle;

/// Error title when changing a notification setting failed.
///
/// In en, this message translates to:
/// **'Failed to update notification setting'**
String get notificationSettingUpdateFailedTitle;

/// Title of settings page for experimental, in-development features
///
/// In en, this message translates to:
Expand Down
16 changes: 16 additions & 0 deletions lib/generated/l10n/zulip_localizations_ar.dart
Original file line number Diff line number Diff line change
Expand Up @@ -1384,6 +1384,22 @@ class ZulipLocalizationsAr extends ZulipLocalizations {
String get markReadOnScrollSettingConversationsDescription =>
'Messages will be automatically marked as read only when viewing a single topic or direct message conversation.';

@override
String get notificationSettingsPageTitle => 'Notifications';

@override
String get offlineNotificationsSettingTitle => 'Notifications when offline';

@override
String get onlineNotificationsSettingTitle => 'Notifications when online';

@override
String get channelNotificationsSettingTitle => 'Channel notifications';

@override
String get notificationSettingUpdateFailedTitle =>
'Failed to update notification setting';

@override
String get experimentalFeatureSettingsPageTitle => 'Experimental features';

Expand Down
16 changes: 16 additions & 0 deletions lib/generated/l10n/zulip_localizations_de.dart
Original file line number Diff line number Diff line change
Expand Up @@ -1419,6 +1419,22 @@ class ZulipLocalizationsDe extends ZulipLocalizations {
String get markReadOnScrollSettingConversationsDescription =>
'Nachrichten werden nur beim Ansehen einzelner Themen oder Direktnachrichten automatisch als gelesen markiert.';

@override
String get notificationSettingsPageTitle => 'Notifications';

@override
String get offlineNotificationsSettingTitle => 'Notifications when offline';

@override
String get onlineNotificationsSettingTitle => 'Notifications when online';

@override
String get channelNotificationsSettingTitle => 'Channel notifications';

@override
String get notificationSettingUpdateFailedTitle =>
'Failed to update notification setting';

@override
String get experimentalFeatureSettingsPageTitle =>
'Experimentelle Funktionen';
Expand Down
16 changes: 16 additions & 0 deletions lib/generated/l10n/zulip_localizations_el.dart
Original file line number Diff line number Diff line change
Expand Up @@ -1385,6 +1385,22 @@ class ZulipLocalizationsEl extends ZulipLocalizations {
String get markReadOnScrollSettingConversationsDescription =>
'Messages will be automatically marked as read only when viewing a single topic or direct message conversation.';

@override
String get notificationSettingsPageTitle => 'Notifications';

@override
String get offlineNotificationsSettingTitle => 'Notifications when offline';

@override
String get onlineNotificationsSettingTitle => 'Notifications when online';

@override
String get channelNotificationsSettingTitle => 'Channel notifications';

@override
String get notificationSettingUpdateFailedTitle =>
'Failed to update notification setting';

@override
String get experimentalFeatureSettingsPageTitle => 'Experimental features';

Expand Down
16 changes: 16 additions & 0 deletions lib/generated/l10n/zulip_localizations_en.dart
Original file line number Diff line number Diff line change
Expand Up @@ -1384,6 +1384,22 @@ class ZulipLocalizationsEn extends ZulipLocalizations {
String get markReadOnScrollSettingConversationsDescription =>
'Messages will be automatically marked as read only when viewing a single topic or direct message conversation.';

@override
String get notificationSettingsPageTitle => 'Notifications';

@override
String get offlineNotificationsSettingTitle => 'Notifications when offline';

@override
String get onlineNotificationsSettingTitle => 'Notifications when online';

@override
String get channelNotificationsSettingTitle => 'Channel notifications';

@override
String get notificationSettingUpdateFailedTitle =>
'Failed to update notification setting';

@override
String get experimentalFeatureSettingsPageTitle => 'Experimental features';

Expand Down
16 changes: 16 additions & 0 deletions lib/generated/l10n/zulip_localizations_es.dart
Original file line number Diff line number Diff line change
Expand Up @@ -1407,6 +1407,22 @@ class ZulipLocalizationsEs extends ZulipLocalizations {
String get markReadOnScrollSettingConversationsDescription =>
'Los mensajes se marcarán automáticamente como solo lectura al ver un solo tema o una conversación por mensaje directo.';

@override
String get notificationSettingsPageTitle => 'Notifications';

@override
String get offlineNotificationsSettingTitle => 'Notifications when offline';

@override
String get onlineNotificationsSettingTitle => 'Notifications when online';

@override
String get channelNotificationsSettingTitle => 'Channel notifications';

@override
String get notificationSettingUpdateFailedTitle =>
'Failed to update notification setting';

@override
String get experimentalFeatureSettingsPageTitle =>
'Funcionalidades experimentales';
Expand Down
16 changes: 16 additions & 0 deletions lib/generated/l10n/zulip_localizations_et.dart
Original file line number Diff line number Diff line change
Expand Up @@ -1400,6 +1400,22 @@ class ZulipLocalizationsEt extends ZulipLocalizations {
String get markReadOnScrollSettingConversationsDescription =>
'Messages will be automatically marked as read only when viewing a single topic or direct message conversation.';

@override
String get notificationSettingsPageTitle => 'Notifications';

@override
String get offlineNotificationsSettingTitle => 'Notifications when offline';

@override
String get onlineNotificationsSettingTitle => 'Notifications when online';

@override
String get channelNotificationsSettingTitle => 'Channel notifications';

@override
String get notificationSettingUpdateFailedTitle =>
'Failed to update notification setting';

@override
String get experimentalFeatureSettingsPageTitle => 'Katselised seadistused';

Expand Down
16 changes: 16 additions & 0 deletions lib/generated/l10n/zulip_localizations_fr.dart
Original file line number Diff line number Diff line change
Expand Up @@ -1426,6 +1426,22 @@ class ZulipLocalizationsFr extends ZulipLocalizations {
String get markReadOnScrollSettingConversationsDescription =>
'Les messages ne seront automatiquement marqués comme lus que si une seule conversation est affichée.';

@override
String get notificationSettingsPageTitle => 'Notifications';

@override
String get offlineNotificationsSettingTitle => 'Notifications when offline';

@override
String get onlineNotificationsSettingTitle => 'Notifications when online';

@override
String get channelNotificationsSettingTitle => 'Channel notifications';

@override
String get notificationSettingUpdateFailedTitle =>
'Failed to update notification setting';

@override
String get experimentalFeatureSettingsPageTitle =>
'Fonctionnalités expérimentales';
Expand Down
16 changes: 16 additions & 0 deletions lib/generated/l10n/zulip_localizations_he.dart
Original file line number Diff line number Diff line change
Expand Up @@ -1384,6 +1384,22 @@ class ZulipLocalizationsHe extends ZulipLocalizations {
String get markReadOnScrollSettingConversationsDescription =>
'Messages will be automatically marked as read only when viewing a single topic or direct message conversation.';

@override
String get notificationSettingsPageTitle => 'Notifications';

@override
String get offlineNotificationsSettingTitle => 'Notifications when offline';

@override
String get onlineNotificationsSettingTitle => 'Notifications when online';

@override
String get channelNotificationsSettingTitle => 'Channel notifications';

@override
String get notificationSettingUpdateFailedTitle =>
'Failed to update notification setting';

@override
String get experimentalFeatureSettingsPageTitle => 'Experimental features';

Expand Down
Loading
Loading