Confine message selector cache to component

This commit is contained in:
Fedor Indutny
2023-01-19 11:56:02 -08:00
committed by GitHub
parent 7f0ed2599d
commit ef13eb06fc
11 changed files with 395 additions and 311 deletions

View File

@@ -55,6 +55,8 @@ import { ToastType } from '../../types/Toast';
import type { ShowToastActionType } from './toast';
import { singleProtoJobQueue } from '../../jobs/singleProtoJobQueue';
import MessageSender from '../../textsecure/SendMessage';
import type { BoundActionCreatorsMapObject } from '../../hooks/useBoundActions';
import { useBoundActions } from '../../hooks/useBoundActions';
// State
@@ -1566,6 +1568,10 @@ export const actions = {
toggleSpeakerView,
};
export const useCallingActions = (): BoundActionCreatorsMapObject<
typeof actions
> => useBoundActions(actions);
export type ActionsType = ReadonlyDeep<typeof actions>;
// Reducer