Skip to content

Commit 4c0c3fe

Browse files
authored
feat(chat): group chat contract and service layer (#1468)
* chore(deps): pin flipcash2-client-protocol to 0.7.0 * feat(chat): add the GroupChats feature flag * feat(chat): add error models for the group feed, join and leave * feat(chat): call the group feed, join and leave RPCs * feat(chat): map group feed, join and leave results to typed errors * feat(chat): expose the group feed, join and leave through the controller * feat(chat): carry roster changes on the chat update stream * feat(chat): store a group's title, picture, roster and rules * feat(chat): map a group's identity, roster and rules to and from the row
1 parent b932158 commit 4c0c3fe

22 files changed

Lines changed: 1838 additions & 33 deletions

File tree

‎apps/flipcash/shared/featureflags/src/main/kotlin/com/flipcash/app/featureflags/FeatureFlag.kt‎

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -117,6 +117,15 @@ sealed interface FeatureFlag<T: Any> {
117117
override val persistLogOut: Boolean = false
118118
}
119119

120+
@FeatureFlagMarker
121+
data object GroupChats: FeatureFlag<Boolean> {
122+
override val key: String = "group_chats_enabled"
123+
override val default: Boolean = false
124+
override val launched: Boolean = false
125+
override val visible: Boolean = true
126+
override val persistLogOut: Boolean = false
127+
}
128+
120129
companion object {
121130
val entries: List<FeatureFlag<*>>
122131
get() = FeatureFlagEntries.entries
@@ -139,6 +148,7 @@ val FeatureFlag<*>.title: String
139148
FeatureFlag.ContactPickerMode -> "Contact Picker Mode"
140149
FeatureFlag.ShowNetworkState -> "Network Offline Indicator"
141150
FeatureFlag.FrostedTipCard -> "Frosted Tip Card"
151+
FeatureFlag.GroupChats -> "Group Chats"
142152
}
143153

144154
val FeatureFlag<*>.message: String
@@ -152,6 +162,7 @@ val FeatureFlag<*>.message: String
152162
FeatureFlag.ContactPickerMode -> "When enabled, contacts will be accessed via the system contact picker instead of requesting full READ_CONTACTS permission"
153163
FeatureFlag.ShowNetworkState -> "When enabled, you'll gain the ability to see the network state on the Scanner when offline"
154164
FeatureFlag.FrostedTipCard -> "When enabled, the tip card in the scanner renders as frosted glass over a blurred snapshot of the camera instead of a solid card"
165+
FeatureFlag.GroupChats -> "When enabled, group chats appear in your chat list alongside your direct messages"
155166
}
156167

157168

0 commit comments

Comments
 (0)