mirror of
https://github.com/Novaloop-AG/element-x-android.git
synced 2026-11-02 12:07:28 +00:00
Reduce number of changes in preview.
This commit is contained in:
+4
-15
@@ -18,17 +18,16 @@ class SpaceRoomProvider : PreviewParameterProvider<SpaceRoom> {
|
||||
override val values: Sequence<SpaceRoom> = sequenceOf(
|
||||
aSpaceRoom(
|
||||
roomType = RoomType.Room,
|
||||
rawName = "Room name with topic",
|
||||
displayName = "Room name with topic",
|
||||
topic = "Room topic that is quite long and might be truncated"
|
||||
),
|
||||
aSpaceRoom(
|
||||
roomType = RoomType.Room,
|
||||
rawName = "Room name no topic",
|
||||
displayName = "Room name no topic",
|
||||
state = CurrentUserMembership.LEFT,
|
||||
),
|
||||
aSpaceRoom(
|
||||
roomType = RoomType.Room,
|
||||
rawName = null,
|
||||
isDirect = true,
|
||||
heroes = listOf(aMatrixUser(displayName = "Alice")),
|
||||
state = CurrentUserMembership.JOINED,
|
||||
@@ -36,13 +35,13 @@ class SpaceRoomProvider : PreviewParameterProvider<SpaceRoom> {
|
||||
),
|
||||
aSpaceRoom(
|
||||
roomType = RoomType.Room,
|
||||
rawName = "Room name with topic",
|
||||
displayName = "Room name with topic",
|
||||
topic = "Room topic that is quite long and might be truncated",
|
||||
state = CurrentUserMembership.INVITED,
|
||||
),
|
||||
aSpaceRoom(
|
||||
roomType = RoomType.Room,
|
||||
rawName = "Room name no topic",
|
||||
displayName = "Room name no topic",
|
||||
state = CurrentUserMembership.INVITED,
|
||||
),
|
||||
aSpaceRoom(
|
||||
@@ -60,7 +59,6 @@ class SpaceRoomProvider : PreviewParameterProvider<SpaceRoom> {
|
||||
state = CurrentUserMembership.LEFT,
|
||||
),
|
||||
aSpaceRoom(
|
||||
rawName = null,
|
||||
numJoinedMembers = 5,
|
||||
childrenCount = 10,
|
||||
worldReadable = true,
|
||||
@@ -68,14 +66,5 @@ class SpaceRoomProvider : PreviewParameterProvider<SpaceRoom> {
|
||||
roomId = RoomId("!spaceId2:example.com"),
|
||||
state = CurrentUserMembership.INVITED,
|
||||
),
|
||||
aSpaceRoom(
|
||||
rawName = null,
|
||||
numJoinedMembers = 5,
|
||||
childrenCount = 10,
|
||||
worldReadable = true,
|
||||
avatarUrl = "anUrl",
|
||||
roomId = RoomId("!spaceId3:example.com"),
|
||||
state = CurrentUserMembership.INVITED,
|
||||
),
|
||||
)
|
||||
}
|
||||
|
||||
+1
-1
@@ -16,7 +16,7 @@ import io.element.android.libraries.matrix.api.spaces.SpaceRoom
|
||||
import io.element.android.libraries.matrix.api.user.MatrixUser
|
||||
|
||||
fun aSpaceRoom(
|
||||
rawName: String? = "Space name",
|
||||
rawName: String? = null,
|
||||
displayName: String = "Space name",
|
||||
avatarUrl: String? = null,
|
||||
canonicalAlias: RoomAlias? = null,
|
||||
|
||||
Reference in New Issue
Block a user