document other chat functionality

This commit is contained in:
Iuri Matias 2021-05-21 08:59:11 -04:00
parent 1387ba3157
commit 068e2cfcd7
6 changed files with 285 additions and 23 deletions

View File

@ -12,9 +12,87 @@ menu:
toc: true
---
## Join or start a public chat
key source file: [`ui/app/AppLayouts/Chat/ContactsColumn/AddChat.qml`](https://github.com/status-im/status-desktop/blob/65a0cfbcd30eb7bde4e24cdb1680b3e03d8b1992/ui/app/AppLayouts/Chat/ContactsColumn/AddChat.qml#L52)
key source file: [`ui/app/AppLayouts/Chat/ContactsColumn.qml`](https://github.com/status-im/status-desktop/blob/65a0cfbcd30eb7bde4e24cdb1680b3e03d8b1992/ui/app/AppLayouts/Chat/ContactsColumn.qml#L32)
key source file: [`ui/app/AppLayouts/Chat/components/PublicChatPopup.qml`](https://github.com/status-im/status-desktop/blob/65a0cfbcd30eb7bde4e24cdb1680b3e03d8b1992/ui/app/AppLayouts/Chat/components/PublicChatPopup.qml#L31)
key source file: [`src/app/chat/view.nim`](https://github.com/status-im/status-desktop/blob/65a0cfbcd30eb7bde4e24cdb1680b3e03d8b1992/src/app/chat/view.nim#L588)
key source file: [`src/status/chat.nim`](https://github.com/status-im/status-desktop/blob/65a0cfbcd30eb7bde4e24cdb1680b3e03d8b1992/src/status/chat.nim#L131)
key source file: [`src/status/libstatus/chat.nim`](https://github.com/status-im/status-desktop/blob/65a0cfbcd30eb7bde4e24cdb1680b3e03d8b1992/src/status/libstatus/chat.nim#L21)
The public channel is joined by calling `chatsModel.joinChat(channelName.text, Constants.chatTypePublic)`
On the backend, the join action calls `status_chat.saveChat`, and adds a mailserver optic, it also emits a `channelJoined` event which will cause the UI to display that new channel
## Search for a Chat
key source file: [`ui/app/AppLayouts/Chat/ContactsColumn/AddChat.qml`](https://github.com/status-im/status-desktop/blob/65a0cfbcd30eb7bde4e24cdb1680b3e03d8b1992/ui/app/AppLayouts/Chat/ContactsColumn.qml#L93)
key source file: [`ui/app/AppLayouts/Chat/ContactsColumn/ChannelList.qml`](https://github.com/status-im/status-desktop/blob/65a0cfbcd30eb7bde4e24cdb1680b3e03d8b1992/ui/app/AppLayouts/Chat/ContactsColumn/ChannelList.qml#L41)
key source file: [`ui/app/AppLayouts/Chat/ContactsColumn/Channel.qml`](https://github.com/status-im/status-desktop/blob/65a0cfbcd30eb7bde4e24cdb1680b3e03d8b1992/ui/app/AppLayouts/Chat/ContactsColumn/Channel.qml#L44)
The searchbox is aliased to as `searchStr`
```
property alias searchStr: searchBox.text
```
The ChannelList receives this as a paramter to the chat list and this is then passed to each member of the channel list
```
ChannelList {
id: channelList
searchStr: contactsColumn.searchStr.toLowerCase()
channelModel: chatsModel.chats
}
```
The filtering works by checking the search string against the channel name and using this to set the item as visible or invisible
```
property bool isVisible: searchStr === "" || name.includes(searchStr)
```
## Suggested Channels
key source file: [`ui/app/AppLayouts/Chat/data/channelList.js`](https://github.com/status-im/status-desktop/blob/65a0cfbcd30eb7bde4e24cdb1680b3e03d8b1992/ui/app/AppLayouts/Chat/data/channelList.js#L1)
key source file: [`ui/app/AppLayouts/Chat/ContactsColumn/EmptyView.qml`](https://github.com/status-im/status-desktop/blob/65a0cfbcd30eb7bde4e24cdb1680b3e03d8b1992/ui/app/AppLayouts/Chat/ContactsColumn/EmptyView.qml#L120)
key source file: [`ui/app/AppLayouts/Chat/components/SuggestedChannels.qml`](https://github.com/status-im/status-desktop/blob/65a0cfbcd30eb7bde4e24cdb1680b3e03d8b1992/ui/app/AppLayouts/Chat/components/SuggestedChannels.qml#L9)
key source file: [`ui/app/AppLayouts/Chat/components/SuggestedChannel.qml`](https://github.com/status-im/status-desktop/blob/65a0cfbcd30eb7bde4e24cdb1680b3e03d8b1992/ui/app/AppLayouts/Chat/components/SuggestedChannel.qml#L5)
## Badges
key source file: [`ui/app/AppLayouts/Chat/ContactsColumn/Channel.qml`](https://github.com/status-im/status-desktop/blob/65a0cfbcd30eb7bde4e24cdb1680b3e03d8b1992/ui/app/AppLayouts/Chat/ContactsColumn/Channel.qml#L167)
### unread message counter
key source file: [`ui/app/AppLayouts/Chat/ContactsColumn/ChannelList.qml#`](https://github.com/status-im/status-desktop/blob/65a0cfbcd30eb7bde4e24cdb1680b3e03d8b1992/ui/app/AppLayouts/Chat/ContactsColumn/ChannelList.qml#L38)
key source file: [`src/status/chat/chat.nim`](https://github.com/status-im/status-desktop/blob/65a0cfbcd30eb7bde4e24cdb1680b3e03d8b1992/src/status/chat/chat.nim#L72)
This information comes from the property `unviewedMessagesCount` which is defined for each channel on the `channelListContent.channelModel`
### mentions @
key source file: [`ui/app/AppLayouts/Chat/ContactsColumn/ChannelList.qml#`](https://github.com/status-im/status-desktop/blob/65a0cfbcd30eb7bde4e24cdb1680b3e03d8b1992/ui/app/AppLayouts/Chat/ContactsColumn/ChannelList.qml#L39)
key source file: [`src/status/chat/chat.nim`](https://github.com/status-im/status-desktop/blob/65a0cfbcd30eb7bde4e24cdb1680b3e03d8b1992/src/status/chat/chat.nim#L76)
This information comes from the property `hasMentions` which is defined for each channel on the `channelListContent.channelModel`
## Context menu
key source file: [`ui/app/AppLayouts/Chat/ContactsColumn/Channel.qml`](https://github.com/status-im/status-desktop/blob/65a0cfbcd30eb7bde4e24cdb1680b3e03d8b1992/ui/app/AppLayouts/Chat/ContactsColumn/Channel.qml#L188)
key source file: [`ui/app/AppLayouts/Chat/ContactsColumn/ChannelList.qml`](https://github.com/status-im/status-desktop/blob/65a0cfbcd30eb7bde4e24cdb1680b3e03d8b1992/ui/app/AppLayouts/Chat/ContactsColumn/ChannelList.qml#L76)
key source file: [`ui/app/AppLayouts/Chat/components/ChannelContextMenu.qml`](https://github.com/status-im/status-desktop/blob/65a0cfbcd30eb7bde4e24cdb1680b3e03d8b1992/ui/app/AppLayouts/Chat/components/ChannelContextMenu.qml#L8)

View File

@ -12,9 +12,33 @@ menu:
toc: true
---
#### Choosing an emoji
#### Searching for an Emojis
#### Categories
#### See also
## Choosing an emoji
key source file: [`ui/shared/status/emojiList.js`](https://github.com/status-im/status-desktop/blob/65a0cfbcd30eb7bde4e24cdb1680b3e03d8b1992/ui/shared/status/emojiList.js#L1)
key source file: [`ui/shared/status/StatusEmojiPopup.qml`](https://github.com/status-im/status-desktop/blob/65a0cfbcd30eb7bde4e24cdb1680b3e03d8b1992/ui/shared/status/StatusEmojiPopup.qml#L10)
key source file: [`ui/shared/status/StatusChatInput.qml`](https://github.com/status-im/status-desktop/blob/65a0cfbcd30eb7bde4e24cdb1680b3e03d8b1992/ui/shared/status/StatusChatInput.qml#L656)
// TODO: emoji selection and how it gets inserted into the text input
## Searching for an Emojis
key source file: [`ui/shared/status/StatusEmojiSection.qml`](https://github.com/status-im/status-desktop/blob/65a0cfbcd30eb7bde4e24cdb1680b3e03d8b1992/ui/shared/status/StatusEmojiSection.qml#L44)
key source file: [`ui/shared/status/StatusEmojiPopup.qml`](https://github.com/status-im/status-desktop/blob/65a0cfbcd30eb7bde4e24cdb1680b3e03d8b1992/ui/shared/status/StatusEmojiPopup.qml#L205)
Searching for an emoji filters the data source `modelData` and replaces the emojis array with the new filtered array.
## Categories
key source file: [`ui/shared/status/emojiList.js`](https://github.com/status-im/status-desktop/blob/65a0cfbcd30eb7bde4e24cdb1680b3e03d8b1992/ui/shared/status/emojiList.js#L1)
key source file: [`ui/shared/status/StatusEmojiCategoryButton.qml`](https://github.com/status-im/status-desktop/blob/65a0cfbcd30eb7bde4e24cdb1680b3e03d8b1992/ui/shared/status/StatusEmojiCategoryButton.qml#L6)
key source file: [`ui/shared/status/StatusEmojiPopup.qml`](https://github.com/status-im/status-desktop/blob/65a0cfbcd30eb7bde4e24cdb1680b3e03d8b1992/ui/shared/status/StatusEmojiPopup.qml#L221)
## See also
Text Input Box

View File

@ -12,9 +12,124 @@ menu:
toc: true
---
#### Starting a group chat
#### Group Information
#### Adding Members
#### Removing Members
#### Make other members admin
#### Renaming Group
## Starting a group chat
### Opening new group chat modal
key source file: [`ui/app/AppLayouts/Chat/ContactsColumn/AddChat.qml`](https://github.com/status-im/status-desktop/blob/65a0cfbcd30eb7bde4e24cdb1680b3e03d8b1992/ui/app/AppLayouts/Chat/ContactsColumn/AddChat.qml#L44)
key source file: [`ui/app/AppLayouts/Chat/ContactsColumn.qml`](https://github.com/status-im/status-desktop/blob/65a0cfbcd30eb7bde4e24cdb1680b3e03d8b1992/ui/app/AppLayouts/Chat/ContactsColumn.qml#L41)
key source file: [`ui/app/AppLayouts/Chat/components/GroupChatPopup.qml`](https://github.com/status-im/status-desktop/blob/65a0cfbcd30eb7bde4e24cdb1680b3e03d8b1992/ui/app/AppLayouts/Chat/components/GroupChatPopup.qml#L10)
### Choosing Members
key source file: [`ui/app/AppLayouts/Chat/components/GroupChatPopup.qml`](https://github.com/status-im/status-desktop/blob/65a0cfbcd30eb7bde4e24cdb1680b3e03d8b1992/ui/app/AppLayouts/Chat/components/GroupChatPopup.qml#L126)
key source file: [`ui/app/AppLayouts/Chat/components/ContactList.qml`](https://github.com/status-im/status-desktop/blob/65a0cfbcd30eb7bde4e24cdb1680b3e03d8b1992/ui/app/AppLayouts/Chat/components/ContactList.qml#L6)
// TODO: unclear where the member list is coming from
// TODO: unclear how it switches to the next screen
### Setting Group Name
key source file: [`ui/app/AppLayouts/Chat/components/GroupChatPopup.qml`](https://github.com/status-im/status-desktop/blob/65a0cfbcd30eb7bde4e24cdb1680b3e03d8b1992/ui/app/AppLayouts/Chat/components/GroupChatPopup.qml#L107)
### Creating the group chat
key source file: [`ui/app/AppLayouts/Chat/components/GroupChatPopup.qml`](https://github.com/status-im/status-desktop/blob/65a0cfbcd30eb7bde4e24cdb1680b3e03d8b1992/ui/app/AppLayouts/Chat/components/GroupChatPopup.qml#L67)
key source file: [`src/app/chat/view.nim`](https://github.com/status-im/status-desktop/blob/65a0cfbcd30eb7bde4e24cdb1680b3e03d8b1992/src/app/chat/view.nim#L153)
key source file: [`src/app/chat/views/groups.nim`](https://github.com/status-im/status-desktop/blob/65a0cfbcd30eb7bde4e24cdb1680b3e03d8b1992/src/app/chat/views/groups.nim#L36)
key source file: [`src/status/chat.nim`](https://github.com/status-im/status-desktop/blob/65a0cfbcd30eb7bde4e24cdb1680b3e03d8b1992/src/status/chat.nim#L403)
key source file: [`src/status/libstatus/chat.nim`](https://github.com/status-im/status-desktop/blob/65a0cfbcd30eb7bde4e24cdb1680b3e03d8b1992/src/status/libstatus/chat.nim#L217)
## Context menu
key source file: [`ui/app/AppLayouts/Chat/ChatColumn/TopBar.qml`](https://github.com/status-im/status-desktop/blob/65a0cfbcd30eb7bde4e24cdb1680b3e03d8b1992/ui/app/AppLayouts/Chat/ChatColumn/TopBar.qml#L67)
### Group Information
key source file: [`ui/app/AppLayouts/Chat/ChatColumn/TopBar.qml`](https://github.com/status-im/status-desktop/blob/65a0cfbcd30eb7bde4e24cdb1680b3e03d8b1992/ui/app/AppLayouts/Chat/ChatColumn/TopBar.qml#L107)
see [Group Information](#group-information-1)
### Clear History
key source file: [`ui/app/AppLayouts/Chat/ChatColumn/TopBar.qml`](https://github.com/status-im/status-desktop/blob/65a0cfbcd30eb7bde4e24cdb1680b3e03d8b1992/ui/app/AppLayouts/Chat/ChatColumn/TopBar.qml#L115)
key source file: [`src/app/chat/view.nim`](https://github.com/status-im/status-desktop/blob/65a0cfbcd30eb7bde4e24cdb1680b3e03d8b1992/src/app/chat/view.nim#L749)
key source file: [`src/status/chat.nim`](https://github.com/status-im/status-desktop/blob/65a0cfbcd30eb7bde4e24cdb1680b3e03d8b1992/src/status/chat.nim#L263)
key source file: [`src/status/libstatus/chat.nim`](https://github.com/status-im/status-desktop/blob/65a0cfbcd30eb7bde4e24cdb1680b3e03d8b1992/src/status/libstatus/chat.nim#L211)
### Leave group
key source file: [`ui/app/AppLayouts/Chat/ChatColumn/TopBar.qml`](https://github.com/status-im/status-desktop/blob/65a0cfbcd30eb7bde4e24cdb1680b3e03d8b1992/ui/app/AppLayouts/Chat/ChatColumn/TopBar.qml#L123)
key source file: [`src/app/chat/view.nim`](https://github.com/status-im/status-desktop/blob/65a0cfbcd30eb7bde4e24cdb1680b3e03d8b1992/src/app/chat/view.nim#L719)
key source file: [`src/status/chat.nim`](https://github.com/status-im/status-desktop/blob/65a0cfbcd30eb7bde4e24cdb1680b3e03d8b1992/src/status/chat.nim#L248)
key source file: [`src/status/libstatus/chat.nim`](https://github.com/status-im/status-desktop/blob/65a0cfbcd30eb7bde4e24cdb1680b3e03d8b1992/src/status/libstatus/chat.nim#L208)
// TODO: unclear worker code https://github.com/status-im/status-desktop/blob/65a0cfbcd30eb7bde4e24cdb1680b3e03d8b1992/src/app/chat/view.nim#L719
// TODO: unclear reason deactivateChat https://github.com/status-im/status-desktop/blob/65a0cfbcd30eb7bde4e24cdb1680b3e03d8b1992/src/status/chat.nim#L248
## Group Information
key source file: [`ui/app/AppLayouts/Chat/ChatLayout.qml`](https://github.com/status-im/status-desktop/blob/65a0cfbcd30eb7bde4e24cdb1680b3e03d8b1992/ui/app/AppLayouts/Chat/ChatLayout.qml#L48)
key source file: [`ui/app/AppLayouts/Chat/components/GroupInfoPopup.qml`](https://github.com/status-im/status-desktop/blob/65a0cfbcd30eb7bde4e24cdb1680b3e03d8b1992/ui/app/AppLayouts/Chat/components/GroupInfoPopup.qml#L9)
## Adding Members
key source file: [`ui/app/AppLayouts/Chat/components/GroupInfoPopup.qml`](https://github.com/status-im/status-desktop/blob/65a0cfbcd30eb7bde4e24cdb1680b3e03d8b1992/ui/app/AppLayouts/Chat/components/GroupInfoPopup.qml#L49)
key source file: [`src/app/chat/view.nim`](https://github.com/status-im/status-desktop/blob/65a0cfbcd30eb7bde4e24cdb1680b3e03d8b1992/src/app/chat/view.nim#L153)
key source file: [`src/app/chat/views/groups.nim`](https://github.com/status-im/status-desktop/blob/65a0cfbcd30eb7bde4e24cdb1680b3e03d8b1992/src/app/chat/views/groups.nim#L40)
key source file: [`src/status/chat.nim`](https://github.com/status-im/status-desktop/blob/65a0cfbcd30eb7bde4e24cdb1680b3e03d8b1992/src/status/chat.nim#L411)
key source file: [`src/status/libstatus/chat.nim`](https://github.com/status-im/status-desktop/blob/65a0cfbcd30eb7bde4e24cdb1680b3e03d8b1992/src/status/libstatus/chat.nim#L220)
## Removing Members
key source file: [`ui/app/AppLayouts/Chat/components/GroupInfoPopup.qml`](https://github.com/status-im/status-desktop/blob/65a0cfbcd30eb7bde4e24cdb1680b3e03d8b1992/ui/app/AppLayouts/Chat/components/GroupInfoPopup.qml#L299)
key source file: [`src/app/chat/view.nim`](https://github.com/status-im/status-desktop/blob/65a0cfbcd30eb7bde4e24cdb1680b3e03d8b1992/src/app/chat/view.nim#L153)
key source file: [`src/app/chat/views/groups.nim`](https://github.com/status-im/status-desktop/blob/65a0cfbcd30eb7bde4e24cdb1680b3e03d8b1992/src/app/chat/views/groups.nim#L44)
key source file: [`src/status/chat.nim`](https://github.com/status-im/status-desktop/blob/65a0cfbcd30eb7bde4e24cdb1680b3e03d8b1992/src/status/chat.nim#L415)
key source file: [`src/status/libstatus/chat.nim`](https://github.com/status-im/status-desktop/blob/65a0cfbcd30eb7bde4e24cdb1680b3e03d8b1992/src/status/libstatus/chat.nim#L223)
## Make other members admin
key source file: [`ui/app/AppLayouts/Chat/components/GroupInfoPopup.qml`](https://github.com/status-im/status-desktop/blob/65a0cfbcd30eb7bde4e24cdb1680b3e03d8b1992/ui/app/AppLayouts/Chat/components/GroupInfoPopup.qml#L290)
key source file: [`src/app/chat/view.nim`](https://github.com/status-im/status-desktop/blob/65a0cfbcd30eb7bde4e24cdb1680b3e03d8b1992/src/app/chat/view.nim#L153)
key source file: [`src/app/chat/views/groups.nim`](https://github.com/status-im/status-desktop/blob/65a0cfbcd30eb7bde4e24cdb1680b3e03d8b1992/src/app/chat/views/groups.nim#L47)
key source file: [`src/status/chat.nim`](https://github.com/status-im/status-desktop/blob/65a0cfbcd30eb7bde4e24cdb1680b3e03d8b1992/src/status/chat.nim#L419)
key source file: [`src/status/libstatus/chat.nim`](https://github.com/status-im/status-desktop/blob/65a0cfbcd30eb7bde4e24cdb1680b3e03d8b1992/src/status/libstatus/chat.nim#L226)
## Renaming Group
key source file: [`ui/app/AppLayouts/Chat/components/GroupInfoPopup.qml`](https://github.com/status-im/status-desktop/blob/65a0cfbcd30eb7bde4e24cdb1680b3e03d8b1992/ui/app/AppLayouts/Chat/components/GroupInfoPopup.qml#L134)
key source file: [`ui/app/AppLayouts/Chat/components/RenameGroupPopup.qml`](https://github.com/status-im/status-desktop/blob/65a0cfbcd30eb7bde4e24cdb1680b3e03d8b1992/ui/app/AppLayouts/Chat/components/RenameGroupPopup.qml#L11)
key source file: [`src/app/chat/views/groups.nim`](https://github.com/status-im/status-desktop/blob/65a0cfbcd30eb7bde4e24cdb1680b3e03d8b1992/src/app/chat/views/groups.nim#L33)
key source file: [`src/status/chat.nim`](https://github.com/status-im/status-desktop/blob/65a0cfbcd30eb7bde4e24cdb1680b3e03d8b1992/src/status/chat.nim#L393)
key source file: [`src/status/libstatus/chat.nim`](https://github.com/status-im/status-desktop/blob/65a0cfbcd30eb7bde4e24cdb1680b3e03d8b1992/src/status/libstatus/chat.nim#L214)

View File

@ -12,14 +12,32 @@ menu:
toc: true
---
## Normal Messages
## Stickers
## Images
## URL Unfurling
### Enable Unfurling
## Reactions
## Replying to messages
## profile options
### view profile
### send message
## Receiving messages
key source file: [`src/nim_status_client.nim`](https://github.com/status-im/status-desktop/blob/65a0cfbcd30eb7bde4e24cdb1680b3e03d8b1992/src/nim_status_client.nim#L210)
key source file: [`src/status/signals/core.nim`](https://github.com/status-im/status-desktop/blob/65a0cfbcd30eb7bde4e24cdb1680b3e03d8b1992/src/status/signals/core.nim#L50)
key source file: [`src/status/signals/messages.nim`](https://github.com/status-im/status-desktop/blob/65a0cfbcd30eb7bde4e24cdb1680b3e03d8b1992/src/status/signals/messages.nim#L26)
// TODO: process that adds new messages to the UI
## Normal Messages
## Stickers
## Images
## URL Unfurling
### Enable Unfurling
## Reactions
## Replying to messages
## profile options
### view profile
### send message

View File

@ -13,4 +13,5 @@ toc: true
---
## notification types
## notification settings

View File

@ -12,8 +12,34 @@ menu:
toc: true
---
## Choosing a Sticker
### Recently used Stickers
### Sticker collections
## Toggling sticker popover
key source file: [`ui/shared/status/StatusChatInput.qml`](https://github.com/status-im/status-desktop/blob/65a0cfbcd30eb7bde4e24cdb1680b3e03d8b1992/ui/shared/status/StatusChatInput.qml#L672)
key source file: [`ui/app/AppLayouts/Chat/ChatColumn.qml`](https://github.com/status-im/status-desktop/blob/1387ba315775a21a8f783978f8a9e049f918266b/ui/app/AppLayouts/Chat/ChatColumn.qml#L352)
// TODO unclear how popup gets open
## Display stickers
key source file: [`ui/shared/status/StatusStickersPopup.qml`](https://github.com/status-im/status-desktop/blob/65a0cfbcd30eb7bde4e24cdb1680b3e03d8b1992/ui/shared/status/StatusStickersPopup.qml#L226)
key source file: [`ui/shared/status/StatusStickerPackIconWithIndicator.qml`](https://github.com/status-im/status-desktop/blob/65a0cfbcd30eb7bde4e24cdb1680b3e03d8b1992/ui/shared/status/StatusStickerPackIconWithIndicator.qml#L6)
key source file: [`src/app/chat/view.nim`](https://github.com/status-im/status-desktop/blob/65a0cfbcd30eb7bde4e24cdb1680b3e03d8b1992/src/app/chat/view.nim#L152)
key source file: [`src/app/chat/views/stickers.nim`](https://github.com/status-im/status-desktop/blob/65a0cfbcd30eb7bde4e24cdb1680b3e03d8b1992/src/app/chat/views/stickers.nim#L82)
key source file: [`src/app/chat/views/sticker_pack_list.nim`](https://github.com/status-im/status-desktop/blob/65a0cfbcd30eb7bde4e24cdb1680b3e03d8b1992/src/app/chat/views/sticker_pack_list.nim#L21)
## Getting free Stickers
## Buying a sticker pack
## Choosing a Sticker
### Recently used Stickers
key source file: [`ui/shared/status/StatusStickersPopup.qml`](https://github.com/status-im/status-desktop/blob/65a0cfbcd30eb7bde4e24cdb1680b3e03d8b1992/ui/shared/status/StatusStickersPopup.qml#L146)
### Sticker collections