peertube-plugin-livechat/shared/lib/types.ts

25 lines
470 B
TypeScript
Raw Normal View History

type ChatType = 'disabled' | 'builtin-prosody' | 'builtin-converse' | 'external-uri'
2021-06-11 23:16:57 +00:00
interface ProsodyListRoomsResultError {
ok: false
error: string
}
interface ProsodyListRoomsResultSuccess {
ok: true
rooms: Array<{
2021-06-12 01:52:45 +00:00
jid: string
localpart: string
2021-06-11 23:16:57 +00:00
name: string
2021-06-12 01:52:45 +00:00
lang: string
description: string
2021-06-11 23:16:57 +00:00
}>
}
type ProsodyListRoomsResult = ProsodyListRoomsResultError | ProsodyListRoomsResultSuccess
export {
2021-06-11 23:16:57 +00:00
ChatType,
ProsodyListRoomsResult
}