diff --git a/apps/android/app/src/main/java/chat/simplex/app/views/chat/ContactPreferences.kt b/apps/android/app/src/main/java/chat/simplex/app/views/chat/ContactPreferences.kt index da832679a6..8e9520d04e 100644 --- a/apps/android/app/src/main/java/chat/simplex/app/views/chat/ContactPreferences.kt +++ b/apps/android/app/src/main/java/chat/simplex/app/views/chat/ContactPreferences.kt @@ -95,11 +95,11 @@ private fun ContactPreferencesLayout( applyPrefs(featuresAllowed.copy(fullDelete = it)) } SectionDividerSpaced(true, maxBottomPadding = false) -// val allowReactions: MutableState = remember(featuresAllowed) { mutableStateOf(featuresAllowed.reactions) } -// FeatureSection(ChatFeature.Reactions, user.fullPreferences.reactions.allow, contact.mergedPreferences.reactions, allowReactions) { -// applyPrefs(featuresAllowed.copy(reactions = it)) -// } -// SectionDividerSpaced(true, maxBottomPadding = false) + val allowReactions: MutableState = remember(featuresAllowed) { mutableStateOf(featuresAllowed.reactions) } + FeatureSection(ChatFeature.Reactions, user.fullPreferences.reactions.allow, contact.mergedPreferences.reactions, allowReactions) { + applyPrefs(featuresAllowed.copy(reactions = it)) + } + SectionDividerSpaced(true, maxBottomPadding = false) val allowVoice: MutableState = remember(featuresAllowed) { mutableStateOf(featuresAllowed.voice) } FeatureSection(ChatFeature.Voice, user.fullPreferences.voice.allow, contact.mergedPreferences.voice, allowVoice) { applyPrefs(featuresAllowed.copy(voice = it)) diff --git a/apps/android/app/src/main/java/chat/simplex/app/views/chat/group/GroupPreferences.kt b/apps/android/app/src/main/java/chat/simplex/app/views/chat/group/GroupPreferences.kt index 06692e41b5..baf62fd56f 100644 --- a/apps/android/app/src/main/java/chat/simplex/app/views/chat/group/GroupPreferences.kt +++ b/apps/android/app/src/main/java/chat/simplex/app/views/chat/group/GroupPreferences.kt @@ -94,11 +94,11 @@ private fun GroupPreferencesLayout( applyPrefs(preferences.copy(fullDelete = GroupPreference(enable = it))) } SectionDividerSpaced(true, maxBottomPadding = false) -// val allowReactions = remember(preferences) { mutableStateOf(preferences.reactions.enable) } -// FeatureSection(GroupFeature.Reactions, allowReactions, groupInfo, preferences, onTTLUpdated) { -// applyPrefs(preferences.copy(reactions = GroupPreference(enable = it))) -// } -// SectionDividerSpaced(true, maxBottomPadding = false) + val allowReactions = remember(preferences) { mutableStateOf(preferences.reactions.enable) } + FeatureSection(GroupFeature.Reactions, allowReactions, groupInfo, preferences, onTTLUpdated) { + applyPrefs(preferences.copy(reactions = GroupPreference(enable = it))) + } + SectionDividerSpaced(true, maxBottomPadding = false) val allowVoice = remember(preferences) { mutableStateOf(preferences.voice.enable) } FeatureSection(GroupFeature.Voice, allowVoice, groupInfo, preferences, onTTLUpdated) { applyPrefs(preferences.copy(voice = GroupPreference(enable = it))) diff --git a/apps/android/app/src/main/java/chat/simplex/app/views/usersettings/Preferences.kt b/apps/android/app/src/main/java/chat/simplex/app/views/usersettings/Preferences.kt index d7af17673a..b967806652 100644 --- a/apps/android/app/src/main/java/chat/simplex/app/views/usersettings/Preferences.kt +++ b/apps/android/app/src/main/java/chat/simplex/app/views/usersettings/Preferences.kt @@ -71,11 +71,11 @@ private fun PreferencesLayout( applyPrefs(preferences.copy(fullDelete = SimpleChatPreference(allow = it))) } SectionDividerSpaced(true, maxBottomPadding = false) -// val allowReactions = remember(preferences) { mutableStateOf(preferences.reactions.allow) } -// FeatureSection(ChatFeature.Reactions, allowReactions) { -// applyPrefs(preferences.copy(reactions = SimpleChatPreference(allow = it))) -// } -// SectionDividerSpaced(true, maxBottomPadding = false) + val allowReactions = remember(preferences) { mutableStateOf(preferences.reactions.allow) } + FeatureSection(ChatFeature.Reactions, allowReactions) { + applyPrefs(preferences.copy(reactions = SimpleChatPreference(allow = it))) + } + SectionDividerSpaced(true, maxBottomPadding = false) val allowVoice = remember(preferences) { mutableStateOf(preferences.voice.allow) } FeatureSection(ChatFeature.Voice, allowVoice) { applyPrefs(preferences.copy(voice = SimpleChatPreference(allow = it))) diff --git a/apps/ios/Shared/Views/Chat/ContactPreferencesView.swift b/apps/ios/Shared/Views/Chat/ContactPreferencesView.swift index 9bee25f585..ff1892d996 100644 --- a/apps/ios/Shared/Views/Chat/ContactPreferencesView.swift +++ b/apps/ios/Shared/Views/Chat/ContactPreferencesView.swift @@ -24,7 +24,7 @@ struct ContactPreferencesView: View { List { timedMessagesFeatureSection() featureSection(.fullDelete, user.fullPreferences.fullDelete.allow, contact.mergedPreferences.fullDelete, $featuresAllowed.fullDelete) - // featureSection(.reactions, user.fullPreferences.reactions.allow, contact.mergedPreferences.reactions, $featuresAllowed.reactions) + featureSection(.reactions, user.fullPreferences.reactions.allow, contact.mergedPreferences.reactions, $featuresAllowed.reactions) featureSection(.voice, user.fullPreferences.voice.allow, contact.mergedPreferences.voice, $featuresAllowed.voice) featureSection(.calls, user.fullPreferences.calls.allow, contact.mergedPreferences.calls, $featuresAllowed.calls) diff --git a/apps/ios/Shared/Views/Chat/Group/GroupPreferencesView.swift b/apps/ios/Shared/Views/Chat/Group/GroupPreferencesView.swift index 92d3710c1d..c3db8cba15 100644 --- a/apps/ios/Shared/Views/Chat/Group/GroupPreferencesView.swift +++ b/apps/ios/Shared/Views/Chat/Group/GroupPreferencesView.swift @@ -25,7 +25,7 @@ struct GroupPreferencesView: View { featureSection(.timedMessages, $preferences.timedMessages.enable) featureSection(.fullDelete, $preferences.fullDelete.enable) featureSection(.directMessages, $preferences.directMessages.enable) - // featureSection(.reactions, $preferences.reactions.enable) + featureSection(.reactions, $preferences.reactions.enable) featureSection(.voice, $preferences.voice.enable) if groupInfo.canEdit { diff --git a/apps/ios/Shared/Views/UserSettings/PreferencesView.swift b/apps/ios/Shared/Views/UserSettings/PreferencesView.swift index 3be84718f5..cf8978498b 100644 --- a/apps/ios/Shared/Views/UserSettings/PreferencesView.swift +++ b/apps/ios/Shared/Views/UserSettings/PreferencesView.swift @@ -20,7 +20,7 @@ struct PreferencesView: View { List { timedMessagesFeatureSection($preferences.timedMessages.allow) featureSection(.fullDelete, $preferences.fullDelete.allow) - // featureSection(.reactions, $preferences.reactions.allow) + featureSection(.reactions, $preferences.reactions.allow) featureSection(.voice, $preferences.voice.allow) featureSection(.calls, $preferences.calls.allow)