Fix badge logic and add notification when receiving files
parent
3404950069
commit
6042d305ac
|
|
@ -1166,9 +1166,13 @@ export default class RoomClient
|
|||
{
|
||||
accept();
|
||||
|
||||
const { file } = request.data;
|
||||
const payload = request.data.file;
|
||||
|
||||
this._dispatch(stateActions.addFile(file));
|
||||
this._dispatch(stateActions.addFile(payload));
|
||||
|
||||
this._dispatch(requestActions.notify({
|
||||
text: `${payload.name} shared a file`
|
||||
}));
|
||||
|
||||
break;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -14,8 +14,9 @@ const toolarea = (state = initialState, action) =>
|
|||
{
|
||||
const toolAreaOpen = !state.toolAreaOpen;
|
||||
const unreadMessages = toolAreaOpen && state.currentToolTab === 'chat' ? 0 : state.unreadMessages;
|
||||
const unreadFiles = toolAreaOpen && state.currentToolTab === 'files' ? 0 : state.unreadFiles;
|
||||
|
||||
return { ...state, toolAreaOpen, unreadMessages };
|
||||
return { ...state, toolAreaOpen, unreadMessages, unreadFiles };
|
||||
}
|
||||
|
||||
case 'SET_TOOL_TAB':
|
||||
|
|
|
|||
Loading…
Reference in New Issue