Do not display empty room list state before the loading one (#2402)

* Do not display empty room list state before the loading one
This commit is contained in:
Jorge Martin Espinosa 2024-02-21 12:16:00 +01:00 committed by GitHub
parent 7532f96c4f
commit 598bf96208
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
10 changed files with 41 additions and 39 deletions

View file

@ -17,6 +17,7 @@
package io.element.android.libraries.matrix.api.roomlist
import kotlinx.coroutines.TimeoutCancellationException
import kotlinx.coroutines.flow.SharedFlow
import kotlinx.coroutines.flow.StateFlow
import kotlinx.coroutines.flow.firstOrNull
import kotlinx.coroutines.withTimeout
@ -51,7 +52,7 @@ interface RoomList {
/**
* The list of room summaries as a flow.
*/
val summaries: StateFlow<List<RoomSummary>>
val summaries: SharedFlow<List<RoomSummary>>
/**
* The loading state of the room list as a flow.