mirror of
https://github.com/anyproto/anytype-kotlin.git
synced 2025-06-08 05:47:05 +09:00
DROID-3662 Chats | Enhancement | Introduce system widget "Chat" + navigation changes (additions) (#2420)
This commit is contained in:
parent
5bddcd640c
commit
3654ffcadb
1 changed files with 24 additions and 13 deletions
|
@ -392,21 +392,32 @@ class SplashViewModel(
|
|||
if (view != null) {
|
||||
if (view.isActive || view.isLoading) {
|
||||
val chat = view.chatId
|
||||
if (chat.isNullOrEmpty() || !ChatConfig.isChatAllowed(space.id)) {
|
||||
commands.emit(
|
||||
Command.NavigateToWidgets(
|
||||
space = space.id,
|
||||
deeplink = deeplink
|
||||
when {
|
||||
chat.isNullOrEmpty() || !ChatConfig.isChatAllowed(space.id) -> {
|
||||
commands.emit(
|
||||
Command.NavigateToWidgets(
|
||||
space = space.id,
|
||||
deeplink = deeplink
|
||||
)
|
||||
)
|
||||
)
|
||||
} else if (view.spaceType == SpaceType.CHAT) {
|
||||
commands.emit(
|
||||
Command.NavigateToSpaceLevelChat(
|
||||
space = space.id,
|
||||
chat = chat,
|
||||
deeplink = deeplink
|
||||
}
|
||||
view.spaceType == SpaceType.CHAT -> {
|
||||
commands.emit(
|
||||
Command.NavigateToSpaceLevelChat(
|
||||
space = space.id,
|
||||
chat = chat,
|
||||
deeplink = deeplink
|
||||
)
|
||||
)
|
||||
)
|
||||
}
|
||||
else -> {
|
||||
commands.emit(
|
||||
Command.NavigateToWidgets(
|
||||
space = space.id,
|
||||
deeplink = deeplink
|
||||
)
|
||||
)
|
||||
}
|
||||
}
|
||||
} else {
|
||||
commands.emit(Command.NavigateToVault(deeplink))
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue