Room list: handle channel rooms.

This commit is contained in:
John Livingston
2021-08-05 18:25:27 +02:00
parent 855ed51251
commit e9d1e55084
4 changed files with 95 additions and 26 deletions

View File

@ -5,21 +5,29 @@ interface ProsodyListRoomsResultError {
error: string
}
interface ProsodyListRoomsResultRoom {
jid: string
localpart: string
name: string
lang: string
description: string
lasttimestamp?: number
channel?: {
id: number
name: string
displayName: string
}
}
interface ProsodyListRoomsResultSuccess {
ok: true
rooms: Array<{
jid: string
localpart: string
name: string
lang: string
description: string
lasttimestamp?: number
}>
rooms: ProsodyListRoomsResultRoom[]
}
type ProsodyListRoomsResult = ProsodyListRoomsResultError | ProsodyListRoomsResultSuccess
export {
ChatType,
ProsodyListRoomsResult
ProsodyListRoomsResult,
ProsodyListRoomsResultRoom
}