Move user status next to the current account header.

Also make the other account section collapsable
This commit is contained in:
Benoit Marty
2026-09-18 17:03:27 +02:00
parent 5cac4767f1
commit ae36cc3b1e
13 changed files with 287 additions and 31 deletions
@@ -21,6 +21,7 @@ import kotlinx.coroutines.flow.updateAndGet
class InMemoryAppPreferencesStore(
isDeveloperModeEnabled: Boolean = false,
isOtherAccountsExpanded: Boolean = true,
customElementCallBaseUrl: String? = null,
hideInviteAvatars: Boolean? = null,
timelineMediaPreviewValue: MediaPreviewValue? = null,
@@ -37,6 +38,7 @@ class InMemoryAppPreferencesStore(
callRingtoneDisplayName: String? = null,
) : AppPreferencesStore {
private val isDeveloperModeEnabled = MutableStateFlow(isDeveloperModeEnabled)
private val isOtherAccountsExpanded = MutableStateFlow(isOtherAccountsExpanded)
private val customElementCallBaseUrl = MutableStateFlow(customElementCallBaseUrl)
private val theme = MutableStateFlow(theme)
private val liveLocationMinimumDistanceUpdate = MutableStateFlow(liveLocationMinimumDistanceUpdate)
@@ -60,6 +62,14 @@ class InMemoryAppPreferencesStore(
return isDeveloperModeEnabled
}
override suspend fun setOtherAccountsExpanded(expanded: Boolean) {
isOtherAccountsExpanded.value = expanded
}
override fun isOtherAccountsExpandedFlow(): Flow<Boolean> {
return isOtherAccountsExpanded
}
override suspend fun setCustomElementCallBaseUrl(string: String?) {
customElementCallBaseUrl.tryEmit(string)
}