diff --git a/Riot/Assets/en.lproj/Vector.strings b/Riot/Assets/en.lproj/Vector.strings index 363d3bb6d..b891f901c 100644 --- a/Riot/Assets/en.lproj/Vector.strings +++ b/Riot/Assets/en.lproj/Vector.strings @@ -2792,7 +2792,7 @@ To enable access, tap Settings> Location and select Always"; // Tchap // Settings "settings" = "Settings"; -"settings_enable_inapp_notifications" = "Enable in-app notifications"; +"settings_enable_inapp_notifications" = "Enable in-app notifications for this account"; // Tchap "settings_enable_push_notifications" = "Enable push notifications"; "settings_enter_validation_token_for" = "Enter validation token for %@:"; diff --git a/Riot/Assets/fr.lproj/Vector.strings b/Riot/Assets/fr.lproj/Vector.strings index dee684fb4..056297ce6 100644 --- a/Riot/Assets/fr.lproj/Vector.strings +++ b/Riot/Assets/fr.lproj/Vector.strings @@ -1814,7 +1814,7 @@ "room_displayname_two_members" = "%@ et %@"; // Settings "settings" = "Paramètres"; -"settings_enable_inapp_notifications" = "Activer les notifications dans l’application"; +"settings_enable_inapp_notifications" = "Activer les notifications pour ce compte"; // Tchap "settings_enable_push_notifications" = "Activer les notifications push"; "settings_enter_validation_token_for" = "Saisir le jeton de validation pour %@ :"; "notification_settings_room_rule_title" = "Salon : « %@ »"; diff --git a/Riot/Modules/Settings/SettingsViewController.m b/Riot/Modules/Settings/SettingsViewController.m index 05198da50..29a4e4de3 100644 --- a/Riot/Modules/Settings/SettingsViewController.m +++ b/Riot/Modules/Settings/SettingsViewController.m @@ -2211,7 +2211,18 @@ - (UITableViewCell *)tableView:(UITableView *)tableView cellForRowAtIndexPath:(N { MXKTableViewCellWithLabelAndSwitch* labelAndSwitchCell = [self getLabelAndSwitchCell:tableView forIndexPath:indexPath]; - labelAndSwitchCell.mxkLabel.text = VectorL10n.settingsEnableInappNotifications; + // Tchap: add explanation to "enable notifications by email" +// labelAndSwitchCell.mxkLabel.text = VectorL10n.settingsEnableInappNotifications; + + NSMutableAttributedString *attributedText = [[NSMutableAttributedString alloc] initWithString: VectorL10n.settingsEnableInappNotifications + attributes:@{NSForegroundColorAttributeName : ThemeService.shared.theme.textPrimaryColor, + NSFontAttributeName: [UIFont systemFontOfSize:17.0]}]; + [attributedText appendAttributedString:[[NSAttributedString alloc] initWithString:@"\n\n" attributes:@{NSFontAttributeName: [UIFont systemFontOfSize:4]}]]; + [attributedText appendAttributedString:[[NSMutableAttributedString alloc] initWithString: TchapL10n.settingsEnableInappNotificationsDescription + attributes:@{NSForegroundColorAttributeName : ThemeService.shared.theme.textSecondaryColor, + NSFontAttributeName: [UIFont systemFontOfSize:14.0]}]]; + labelAndSwitchCell.mxkLabel.attributedText = attributedText; + labelAndSwitchCell.mxkSwitch.on = RiotSettings.shared.showInAppNotifications; labelAndSwitchCell.mxkSwitch.onTintColor = ThemeService.shared.theme.tintColor; labelAndSwitchCell.mxkSwitch.enabled = account.pushNotificationServiceIsActive; @@ -2237,7 +2248,7 @@ - (UITableViewCell *)tableView:(UITableView *)tableView cellForRowAtIndexPath:(N - // Tchap: add explanation to "enable notiofications by email" + // Tchap: add explanation to "enable notifications by email" // labelAndSwitchCell.mxkLabel.text = TchapL10n.settingsNotificationEmail; NSMutableAttributedString *attributedText = [[NSMutableAttributedString alloc] initWithString: TchapL10n.settingsNotificationEmail diff --git a/Tchap/Assets/Localizations/fr.lproj/Tchap.strings b/Tchap/Assets/Localizations/fr.lproj/Tchap.strings index ebeabc736..0899d155d 100644 --- a/Tchap/Assets/Localizations/fr.lproj/Tchap.strings +++ b/Tchap/Assets/Localizations/fr.lproj/Tchap.strings @@ -355,3 +355,4 @@ "settings_enable_push_notif_text" = "Sans cette autorisation, les appels entrants ne seront pas notifiés."; "settings_enable_email_notif_text" = "Recevez un e-mail si au moins un message récent non lu pendant 72h."; "settings_enable_email_notif_link" = "En savoir plus."; +"settings_enable_inapp_notifications_description" = "Le compte correspond à tous vos appareils connectés à Tchap."; diff --git a/changelog.d/1103.change b/changelog.d/1103.change new file mode 100644 index 000000000..d4f093c1e --- /dev/null +++ b/changelog.d/1103.change @@ -0,0 +1 @@ +Ajout d'un label sous le bouton "Activer les notifs dans l'application" \ No newline at end of file