Jitsi Meet - Secure, Simple and Scalable Video Conferences that you use as a standalone app or embed in your web application.
TypeScript debiandeep-videojitsijitsi-meetscalable-video-conferencessfuvideovideo-communicationvideo-conferencingwebrtc
ref(TS) Improve TS (#13370)
Robert Pintiliiae281e9935d8
diff --git a/react/features/base/config/configType.ts b/react/features/base/config/configType.tsindex 80ad10c5fa..3f69119453 100644--- a/react/features/base/config/configType.ts+++ b/react/features/base/config/configType.ts@@ -142,6 +142,7 @@ export interface IConfig {rtcstatsEndpoint?: string;rtcstatsPollInterval?: number;rtcstatsSendSdp?: boolean;+ rtcstatsStoreLogs?: boolean;rtcstatsUseLegacy?: boolean;scriptURLs?: Array<string>;whiteListedEvents?: string[];diff --git a/react/features/base/connection/reducer.ts b/react/features/base/connection/reducer.tsindex 712e9f48a8..cf5e5443f5 100644--- a/react/features/base/connection/reducer.ts+++ b/react/features/base/connection/reducer.ts@@ -21,6 +21,7 @@ export interface IConnectionState {getJid: () => string;getLogs: () => Object;initJitsiConference: Function;+ removeFeature: Function;};error?: ConnectionFailedError;locationURL?: URL;diff --git a/react/features/base/devices/functions.web.ts b/react/features/base/devices/functions.web.tsindex b3d355e95c..65e5085f5f 100644--- a/react/features/base/devices/functions.web.ts+++ b/react/features/base/devices/functions.web.ts@@ -1,4 +1,4 @@-import { IReduxState } from '../../app/types';+import { IReduxState, IStore } from '../../app/types';import JitsiMeetJS from '../lib-jitsi-meet';import { updateSettings } from '../settings/actions';import { ISettingsState } from '../settings/reducer';@@ -251,7 +251,7 @@ export function getVideoDeviceIds(state: IReduxState) {*/export function setAudioOutputDeviceId(newId = 'default',- dispatch: Function,+ dispatch: IStore['dispatch'],userSelection = false,newLabel?: string): Promise<any> {diff --git a/react/features/base/dialog/components/native/BottomSheet.tsx b/react/features/base/dialog/components/native/BottomSheet.tsxindex f4d15ef07d..cf36af0653 100644--- a/react/features/base/dialog/components/native/BottomSheet.tsx+++ b/react/features/base/dialog/components/native/BottomSheet.tsx@@ -2,6 +2,7 @@ import React, { PureComponent, ReactNode } from 'react';import { SafeAreaView, ScrollView, View, ViewStyle } from 'react-native';import { connect } from 'react-redux';+import { IStore } from '../../../../app/types';import SlidingView from '../../../react/components/native/SlidingView';import { hideSheet } from '../../actions';@@ -25,7 +26,7 @@ type Props = {/*** Redux Dispatch function.*/- dispatch: Function;+ dispatch: IStore['dispatch'];/*** Handler for the cancel event, which happens when the user dismissesdiff --git a/react/features/base/logging/JitsiMeetLogStorage.ts b/react/features/base/logging/JitsiMeetLogStorage.tsindex 511d7ec340..7ab9b51c9f 100644--- a/react/features/base/logging/JitsiMeetLogStorage.ts+++ b/react/features/base/logging/JitsiMeetLogStorage.ts@@ -1,3 +1,4 @@+import { IStore } from '../../app/types';import RTCStats from '../../rtcstats/RTCStats';import { canSendRtcstatsData } from '../../rtcstats/functions';import { getCurrentConference } from '../conference/functions';@@ -8,14 +9,14 @@ import { getCurrentConference } from '../conference/functions';*/export default class JitsiMeetLogStorage {counter: number;- getState: Function;+ getState: IStore['getState'];/*** Creates new <tt>JitsiMeetLogStorage</tt>.** @param {Function} getState - The Redux store's {@code getState} method.*/- constructor(getState: Function) {+ constructor(getState: IStore['getState']) {/*** Counts each log entry, increases on every batch log entry stored.*diff --git a/react/features/base/media/reducer.ts b/react/features/base/media/reducer.tsindex 010d8535f5..8d29e4e021 100644--- a/react/features/base/media/reducer.ts+++ b/react/features/base/media/reducer.ts@@ -1,4 +1,4 @@-import { combineReducers } from 'redux';+import { AnyAction, combineReducers } from 'redux';import { CONFERENCE_FAILED, CONFERENCE_LEFT } from '../conference/actionTypes';import ReducerRegistry from '../redux/ReducerRegistry';@@ -49,7 +49,7 @@ export const _AUDIO_INITIAL_MEDIA_STATE = {* @private* @returns {AudioMediaState}*/-function _audio(state: IAudioState = _AUDIO_INITIAL_MEDIA_STATE, action: any) {+function _audio(state: IAudioState = _AUDIO_INITIAL_MEDIA_STATE, action: AnyAction) {switch (action.type) {case SET_AUDIO_AVAILABLE:return {@@ -103,7 +103,7 @@ export const _SCREENSHARE_INITIAL_MEDIA_STATE = {* @private* @returns {ScreenshareMediaState}*/-function _screenshare(state: IScreenshareState = _SCREENSHARE_INITIAL_MEDIA_STATE, action: any) {+function _screenshare(state: IScreenshareState = _SCREENSHARE_INITIAL_MEDIA_STATE, action: AnyAction) {switch (action.type) {case SET_SCREENSHARE_MUTED:return {diff --git a/react/features/base/participants/functions.ts b/react/features/base/participants/functions.tsindex ae2cf14489..d8546cec35 100644--- a/react/features/base/participants/functions.ts+++ b/react/features/base/participants/functions.ts@@ -733,7 +733,7 @@ export const addPeopleFeatureControl = (stateful: IStateful) => {* @param {Function} dispatch - The Redux dispatch function.* @returns {Function}*/-export const setShareDialogVisiblity = (addPeopleFeatureEnabled: boolean, dispatch: Function) => {+export const setShareDialogVisiblity = (addPeopleFeatureEnabled: boolean, dispatch: IStore['dispatch']) => {if (addPeopleFeatureEnabled) {dispatch(toggleShareDialog(false));} else {diff --git a/react/features/base/participants/reducer.ts b/react/features/base/participants/reducer.tsindex a122d14497..d08cba0b6b 100644--- a/react/features/base/participants/reducer.ts+++ b/react/features/base/participants/reducer.ts@@ -1,3 +1,5 @@+import { AnyAction } from 'redux';+import { MEDIA_TYPE } from '../media/constants';import ReducerRegistry from '../redux/ReducerRegistry';import { set } from '../redux/functions';@@ -512,7 +514,7 @@ function _getDisplayName(state: Object, name?: string): string {* @returns {IParticipant}*/function _participant(state: IParticipant | ILocalParticipant = { id: '' },- action: any): IParticipant | ILocalParticipant {+ action: AnyAction): IParticipant | ILocalParticipant {switch (action.type) {case SET_LOADABLE_AVATAR_URL:case PARTICIPANT_UPDATED: {diff --git a/react/features/base/sounds/actions.ts b/react/features/base/sounds/actions.tsindex 9a7a98bff9..c0ca1fa098 100644--- a/react/features/base/sounds/actions.ts+++ b/react/features/base/sounds/actions.ts@@ -1,3 +1,4 @@+import { IStore } from '../../app/types';import { Sounds } from '../config/configType';import { AudioElement } from '../media/components/AbstractAudio';@@ -66,7 +67,7 @@ export function _removeAudioElement(soundId: string) {* @returns {Function}*/export function playSound(soundId: string) {- return (dispatch: Function, getState: Function) => {+ return (dispatch: IStore['dispatch'], getState: IStore['getState']) => {const disabledSounds = getDisabledSounds(getState());if (!disabledSounds.includes(soundId as Sounds) && !disabledSounds.find(id => soundId.startsWith(id))) {diff --git a/react/features/base/sounds/reducer.ts b/react/features/base/sounds/reducer.tsindex 3acaac362a..54080c2788 100644--- a/react/features/base/sounds/reducer.ts+++ b/react/features/base/sounds/reducer.ts@@ -1,3 +1,5 @@+import { AnyAction } from 'redux';+import { AudioElement } from '../media/components/AbstractAudio';import ReducerRegistry from '../redux/ReducerRegistry';import { assign } from '../redux/functions';@@ -77,7 +79,7 @@ ReducerRegistry.register<ISoundsState>(* @private* @returns {Map<string, Sound>}*/-function _addOrRemoveAudioElement(state: ISoundsState, action: any) {+function _addOrRemoveAudioElement(state: ISoundsState, action: AnyAction) {const isAddAction = action.type === _ADD_AUDIO_ELEMENT;const nextState = new Map(state);const { soundId } = action;@@ -112,7 +114,7 @@ function _addOrRemoveAudioElement(state: ISoundsState, action: any) {* @private* @returns {Map<string, Sound>}*/-function _registerSound(state: ISoundsState, action: any) {+function _registerSound(state: ISoundsState, action: AnyAction) {const nextState = new Map(state);nextState.set(action.soundId, {@@ -133,7 +135,7 @@ function _registerSound(state: ISoundsState, action: any) {* @private* @returns {Map<string, Sound>}*/-function _unregisterSound(state: ISoundsState, action: any) {+function _unregisterSound(state: ISoundsState, action: AnyAction) {const nextState = new Map(state);nextState.delete(action.soundId);diff --git a/react/features/base/testing/reducer.ts b/react/features/base/testing/reducer.tsindex eb7ac3e643..8ecac948ee 100644--- a/react/features/base/testing/reducer.ts+++ b/react/features/base/testing/reducer.ts@@ -1,3 +1,5 @@+import { AnyAction } from 'redux';+import ReducerRegistry from '../redux/ReducerRegistry';import { assign } from '../redux/functions';@@ -40,6 +42,6 @@ ReducerRegistry.register<ITestingState>(* @returns {Object} The new state of the feature testing after the* reduction of the specified action.*/-function _setConnectionState(state: ITestingState, action: any) {+function _setConnectionState(state: ITestingState, action: AnyAction) {return assign(state, { connectionState: action.connectionState });}diff --git a/react/features/base/tracks/actions.native.ts b/react/features/base/tracks/actions.native.tsindex 5202624115..8a34955e80 100644--- a/react/features/base/tracks/actions.native.ts+++ b/react/features/base/tracks/actions.native.ts@@ -48,7 +48,7 @@ export function toggleScreensharing(enabled: boolean, _ignore1?: boolean, _ignor* @param {Object} state - The redux state.* @returns {void}*/-async function _startScreenSharing(dispatch: Function, state: IReduxState) {+async function _startScreenSharing(dispatch: IStore['dispatch'], state: IReduxState) {setPictureInPictureEnabled(false);try {diff --git a/react/features/base/tracks/middleware.any.ts b/react/features/base/tracks/middleware.any.tsindex 715e2bb108..657bcc4404 100644--- a/react/features/base/tracks/middleware.any.ts+++ b/react/features/base/tracks/middleware.any.ts@@ -164,7 +164,7 @@ StateListenerRegistry.register(* {@code mediaType} in the specified {@code store}.*/function _getLocalTrack(- { getState }: { getState: Function; },+ { getState }: { getState: IStore['getState']; },mediaType: MediaType,includePending = false) {return (diff --git a/react/features/base/tracks/middleware.web.ts b/react/features/base/tracks/middleware.web.tsindex d5fa60ca22..cd6b2884ee 100644--- a/react/features/base/tracks/middleware.web.ts+++ b/react/features/base/tracks/middleware.web.ts@@ -1,3 +1,5 @@+import { AnyAction } from 'redux';+import { IStore } from '../../app/types';import { hideNotification } from '../../notifications/actions';import { isPrejoinPageVisible } from '../../prejoin/functions';@@ -133,7 +135,7 @@ MiddlewareRegistry.register(store => next => action => {* @private* @returns {void}*/-function _handleNoDataFromSourceErrors(store: IStore, action: any) {+function _handleNoDataFromSourceErrors(store: IStore, action: AnyAction) {const { getState, dispatch } = store;const track = getTrackByJitsiTrack(getState()['features/base/tracks'], action.track.jitsiTrack);diff --git a/react/features/base/tracks/reducer.ts b/react/features/base/tracks/reducer.tsindex a616d3470d..bb0c8b6a7f 100644--- a/react/features/base/tracks/reducer.ts+++ b/react/features/base/tracks/reducer.ts@@ -1,3 +1,5 @@+import { AnyAction } from 'redux';+import { PARTICIPANT_ID_CHANGED } from '../participants/actionTypes';import ReducerRegistry from '../redux/ReducerRegistry';import { set } from '../redux/functions';@@ -30,7 +32,7 @@ import { ITrack } from './types';* @param {Participant} action.participant - Information about participant.* @returns {Track|undefined}*/-function track(state: ITrack, action: any) {+function track(state: ITrack, action: AnyAction) {switch (action.type) {case PARTICIPANT_ID_CHANGED:if (state.participantId === action.oldValue) {diff --git a/react/features/base/user-interaction/middleware.ts b/react/features/base/user-interaction/middleware.tsindex c4ddb9c41f..74e9a70b9a 100644--- a/react/features/base/user-interaction/middleware.ts+++ b/react/features/base/user-interaction/middleware.ts@@ -1,3 +1,4 @@+import { IStore } from '../../app/types';import { APP_WILL_MOUNT, APP_WILL_UNMOUNT } from '../app/actionTypes';import MiddlewareRegistry from '../redux/MiddlewareRegistry';@@ -39,7 +40,7 @@ MiddlewareRegistry.register(store => next => action => {* @private* @returns {void}*/-function _onUserInteractionReceived(dispatch: Function, event: any) {+function _onUserInteractionReceived(dispatch: IStore['dispatch'], event: any) {if (event.isTrusted) {dispatch({type: USER_INTERACTION_RECEIVED@@ -56,7 +57,7 @@ function _onUserInteractionReceived(dispatch: Function, event: any) {* @private* @returns {void}*/-function _startListeningForUserInteraction({ dispatch }: { dispatch: Function; }) {+function _startListeningForUserInteraction({ dispatch }: { dispatch: IStore['dispatch']; }) {_stopListeningForUserInteraction();userInteractionListener = _onUserInteractionReceived.bind(null, dispatch);diff --git a/react/features/calendar-sync/components/CalendarList.web.tsx b/react/features/calendar-sync/components/CalendarList.web.tsxindex eaad42ddfe..84f5af9aa5 100644--- a/react/features/calendar-sync/components/CalendarList.web.tsx+++ b/react/features/calendar-sync/components/CalendarList.web.tsx@@ -4,7 +4,7 @@ import { connect } from 'react-redux';import { createCalendarClickedEvent } from '../../analytics/AnalyticsEvents';import { sendAnalytics } from '../../analytics/functions';-import { IReduxState } from '../../app/types';+import { IReduxState, IStore } from '../../app/types';import { translate } from '../../base/i18n/functions';import Icon from '../../base/icons/components/Icon';import { IconCalendar } from '../../base/icons/svg';@@ -46,7 +46,7 @@ interface IProps extends WithTranslation {/*** The Redux dispatch function.*/- dispatch: Function;+ dispatch: IStore['dispatch'];}/**diff --git a/react/features/calendar-sync/components/CalendarListContent.native.tsx b/react/features/calendar-sync/components/CalendarListContent.native.tsxindex a942c09b1a..970847048c 100644--- a/react/features/calendar-sync/components/CalendarListContent.native.tsx+++ b/react/features/calendar-sync/components/CalendarListContent.native.tsx@@ -5,7 +5,7 @@ import { connect } from 'react-redux';import { createCalendarClickedEvent, createCalendarSelectedEvent } from '../../analytics/AnalyticsEvents';import { sendAnalytics } from '../../analytics/functions';import { appNavigate } from '../../app/actions.native';-import { IReduxState } from '../../app/types';+import { IReduxState, IStore } from '../../app/types';import { getLocalizedDateFormatter } from '../../base/i18n/dateUtil';import { translate } from '../../base/i18n/functions';import NavigateSectionList from '../../base/react/components/native/NavigateSectionList';@@ -31,7 +31,7 @@ interface IProps extends WithTranslation {/*** The Redux dispatch function.*/- dispatch: Function;+ dispatch: IStore['dispatch'];/***diff --git a/react/features/calendar-sync/components/CalendarListContent.web.tsx b/react/features/calendar-sync/components/CalendarListContent.web.tsxindex 9ab7b746cc..23c9807b21 100644--- a/react/features/calendar-sync/components/CalendarListContent.web.tsx+++ b/react/features/calendar-sync/components/CalendarListContent.web.tsx@@ -4,7 +4,7 @@ import { connect } from 'react-redux';import { createCalendarClickedEvent, createCalendarSelectedEvent } from '../../analytics/AnalyticsEvents';import { sendAnalytics } from '../../analytics/functions';import { appNavigate } from '../../app/actions.web';-import { IReduxState } from '../../app/types';+import { IReduxState, IStore } from '../../app/types';import MeetingsList from '../../base/react/components/web/MeetingsList';import AddMeetingUrlButton from './AddMeetingUrlButton.web';@@ -29,7 +29,7 @@ interface IProps {/*** The Redux dispatch function.*/- dispatch: Function;+ dispatch: IStore['dispatch'];/***diff --git a/react/features/chat/components/AbstractMessageRecipient.ts b/react/features/chat/components/AbstractMessageRecipient.tsindex 633927f1ad..4924b1e79e 100644--- a/react/features/chat/components/AbstractMessageRecipient.ts+++ b/react/features/chat/components/AbstractMessageRecipient.ts@@ -1,7 +1,7 @@import { PureComponent } from 'react';import { WithTranslation } from 'react-i18next';-import { IReduxState } from '../../app/types';+import { IReduxState, IStore } from '../../app/types';import { getParticipantDisplayName, isLocalParticipantModerator } from '../../base/participants/functions';import { setLobbyChatActiveState } from '../actions.any';import { setPrivateMessageRecipient } from '../actions.web';@@ -52,7 +52,7 @@ export default class AbstractMessageRecipient<P extends IProps> extends PureComp* @param {Function} dispatch - The Redux dispatch function.* @returns {IProps}*/-export function _mapDispatchToProps(dispatch: Function) {+export function _mapDispatchToProps(dispatch: IStore['dispatch']) {return {_onRemovePrivateMessageRecipient: () => {dispatch(setPrivateMessageRecipient());diff --git a/react/features/conference/components/native/Conference.tsx b/react/features/conference/components/native/Conference.tsxindex 7c3faea377..910e45dc88 100644--- a/react/features/conference/components/native/Conference.tsx+++ b/react/features/conference/components/native/Conference.tsx@@ -13,7 +13,7 @@ import { EdgeInsets, withSafeAreaInsets } from 'react-native-safe-area-context';import { connect } from 'react-redux';import { appNavigate } from '../../../app/actions';-import { IReduxState } from '../../../app/types';+import { IReduxState, IStore } from '../../../app/types';import { FULLSCREEN_ENABLED, PIP_ENABLED } from '../../../base/flags/constants';import { getFeatureFlag } from '../../../base/flags/functions';import { getParticipantCount } from '../../../base/participants/functions';@@ -158,7 +158,7 @@ interface IProps extends AbstractProps {/*** The redux {@code dispatch} function.*/- dispatch: Function;+ dispatch: IStore['dispatch'];/*** Object containing the safe area insets.diff --git a/react/features/conference/components/native/LonelyMeetingExperience.tsx b/react/features/conference/components/native/LonelyMeetingExperience.tsxindex 232ade5b6a..2036827627 100644--- a/react/features/conference/components/native/LonelyMeetingExperience.tsx+++ b/react/features/conference/components/native/LonelyMeetingExperience.tsx@@ -3,7 +3,7 @@ import { WithTranslation } from 'react-i18next';import { Text, View, ViewStyle } from 'react-native';import { connect } from 'react-redux';-import { IReduxState } from '../../../app/types';+import { IReduxState, IStore } from '../../../app/types';import { INVITE_ENABLED } from '../../../base/flags/constants';import { getFeatureFlag } from '../../../base/flags/functions';import { translate } from '../../../base/i18n/functions';@@ -56,7 +56,7 @@ interface IProps extends WithTranslation {/*** The Redux Dispatch function.*/- dispatch: Function;+ dispatch: IStore['dispatch'];}/**diff --git a/react/features/connection-indicator/components/native/ConnectionIndicator.tsx b/react/features/connection-indicator/components/native/ConnectionIndicator.tsxindex 0cb3f6b972..c4a08acb42 100644--- a/react/features/connection-indicator/components/native/ConnectionIndicator.tsx+++ b/react/features/connection-indicator/components/native/ConnectionIndicator.tsx@@ -2,7 +2,7 @@ import React from 'react';import { StyleProp, View, ViewStyle } from 'react-native';import { connect } from 'react-redux';-import { IReduxState } from '../../../app/types';+import { IReduxState, IStore } from '../../../app/types';import { IconConnection } from '../../../base/icons/svg';import { MEDIA_TYPE } from '../../../base/media/constants';import {@@ -61,7 +61,7 @@ type IProps = AbstractProps & {/*** Redux dispatch function.*/- dispatch: Function;+ dispatch: IStore['dispatch'];/*** Icon style override.diff --git a/react/features/deep-linking/actions.ts b/react/features/deep-linking/actions.tsindex f686e8270c..47a8b13fe0 100644--- a/react/features/deep-linking/actions.ts+++ b/react/features/deep-linking/actions.ts@@ -1,6 +1,5 @@-import type { Dispatch } from 'redux';-import { appNavigate } from '../app/actions';+import { IStore } from '../app/types';import { OPEN_DESKTOP_APP, OPEN_WEB_APP } from './actionTypes';@@ -10,7 +9,7 @@ import { OPEN_DESKTOP_APP, OPEN_WEB_APP } from './actionTypes';* @returns {Function}*/export function openWebApp() {- return (dispatch: Dispatch<any>) => {+ return (dispatch: IStore['dispatch']) => {// In order to go to the web app we need to skip the deep linking// interceptor. OPEN_WEB_APP action should set launchInWeb to true in// the redux store. After this when appNavigate() is called thediff --git a/react/features/dropbox/actions.ts b/react/features/dropbox/actions.tsindex 1f1acfbfec..f700e3a3f0 100644--- a/react/features/dropbox/actions.ts+++ b/react/features/dropbox/actions.ts@@ -1,3 +1,5 @@+import { IStore } from '../app/types';+import { UPDATE_DROPBOX_TOKEN } from './actionTypes';import { _authorizeDropbox } from './functions';import logger from './logger';@@ -8,10 +10,11 @@ import logger from './logger';* @returns {Function}*/export function authorizeDropbox() {- return (dispatch: Function, getState: Function) => {+ return (dispatch: IStore['dispatch'], getState: IStore['getState']) => {const state = getState();const { locationURL } = state['features/base/connection'];- const { dropbox = {} } = state['features/base/config'];+ const { dropbox = { appKey: '',+ redirectURI: undefined } } = state['features/base/config'];// By default we use the static page on the main domain for redirection.// So we need to setup only one redirect URI in dropbox app@@ -19,7 +22,7 @@ export function authorizeDropbox() {// In case deployment is running in subfolder dropbox.redirectURI// can be configured.const redirectURI- = dropbox.redirectURI || `${locationURL.origin}/static/oauth.html`;+ = dropbox.redirectURI || `${locationURL?.origin}/static/oauth.html`;_authorizeDropbox(dropbox.appKey, redirectURI).then(diff --git a/react/features/dynamic-branding/actions.any.ts b/react/features/dynamic-branding/actions.any.tsindex 6aa66ed853..79fedcd208 100644--- a/react/features/dynamic-branding/actions.any.ts+++ b/react/features/dynamic-branding/actions.any.ts@@ -1,3 +1,4 @@+import { IStore } from '../app/types';import { doGetJSON } from '../base/util/httpUtils';import {@@ -17,7 +18,7 @@ import logger from './logger';* @returns {Function}*/export function fetchCustomBrandingData() {- return async function(dispatch: Function, getState: Function) {+ return async function(dispatch: IStore['dispatch'], getState: IStore['getState']) {const state = getState();const { customizationReady } = state['features/dynamic-branding'];diff --git a/react/features/face-landmarks/middleware.ts b/react/features/face-landmarks/middleware.tsindex 72e8f8b8d8..74e0d2ef68 100644--- a/react/features/face-landmarks/middleware.ts+++ b/react/features/face-landmarks/middleware.ts@@ -1,3 +1,5 @@+import { AnyAction } from 'redux';+import { IStore } from '../app/types';import {CONFERENCE_JOINED,@@ -16,7 +18,7 @@ import { FACE_BOX_EVENT_TYPE } from './constants';import { sendFaceBoxToParticipants, sendFaceExpressionToParticipants, sendFaceExpressionToServer } from './functions';-MiddlewareRegistry.register((store: IStore) => (next: Function) => (action: any) => {+MiddlewareRegistry.register((store: IStore) => (next: Function) => (action: AnyAction) => {const { dispatch, getState } = store;const { faceLandmarks: faceLandmarksConfig } = getState()['features/base/config'];const isEnabled = faceLandmarksConfig?.enableFaceCentering || faceLandmarksConfig?.enableFaceExpressionsDetection;diff --git a/react/features/filmstrip/actions.native.ts b/react/features/filmstrip/actions.native.tsindex 971fb78198..4d7cb58a37 100644--- a/react/features/filmstrip/actions.native.ts+++ b/react/features/filmstrip/actions.native.ts@@ -1,3 +1,4 @@+import { IStore } from '../app/types';import conferenceStyles from '../conference/components/native/styles';import { SET_TILE_VIEW_DIMENSIONS } from './actionTypes';@@ -15,10 +16,15 @@ export * from './actions.any';* @returns {Function}*/export function setTileViewDimensions() {- return (dispatch: Function, getState: Function) => {+ return (dispatch: IStore['dispatch'], getState: IStore['getState']) => {const state = getState();const participantCount = getTileViewParticipantCount(state);- const { clientHeight: height, clientWidth: width, safeAreaInsets = {} } = state['features/base/responsive-ui'];+ const { clientHeight: height, clientWidth: width, safeAreaInsets = {+ left: undefined,+ right: undefined,+ top: undefined,+ bottom: undefined+ } } = state['features/base/responsive-ui'];const { left = 0, right = 0, top = 0, bottom = 0 } = safeAreaInsets;const columns = getColumnCount(state);const rows = Math.ceil(participantCount / columns); // @ts-ignorediff --git a/react/features/filmstrip/components/web/Thumbnail.tsx b/react/features/filmstrip/components/web/Thumbnail.tsxindex 42ccd85723..1b1d907ad9 100644--- a/react/features/filmstrip/components/web/Thumbnail.tsx+++ b/react/features/filmstrip/components/web/Thumbnail.tsx@@ -8,7 +8,7 @@ import { connect } from 'react-redux';import { createScreenSharingIssueEvent } from '../../../analytics/AnalyticsEvents';import { sendAnalytics } from '../../../analytics/functions';-import { IReduxState } from '../../../app/types';+import { IReduxState, IStore } from '../../../app/types';import Avatar from '../../../base/avatar/components/Avatar';import { isMobileBrowser } from '../../../base/environment/utils';import { translate } from '../../../base/i18n/functions';@@ -232,7 +232,7 @@ export interface IProps extends WithTranslation {/*** The redux dispatch function.*/- dispatch: Function;+ dispatch: IStore['dispatch'];/*** The type of filmstrip the tile is displayed in.diff --git a/react/features/invite/actions.any.ts b/react/features/invite/actions.any.tsindex d4d71dbf58..315c79bc43 100644--- a/react/features/invite/actions.any.ts+++ b/react/features/invite/actions.any.ts@@ -66,7 +66,7 @@ export function invite(showCalleeInfo = false) {return (dispatch: IStore['dispatch'],- getState: IStore['getState']): Promise<Array<Object>> => {+ getState: IStore['getState']): Promise<IInvitee[]> => {const state = getState();const participantsCount = getParticipantCount(state);const { calleeInfoVisible } = state['features/invite'];diff --git a/react/features/invite/components/add-people-dialog/AbstractAddPeopleDialog.tsx b/react/features/invite/components/add-people-dialog/AbstractAddPeopleDialog.tsxindex 54b82ba99c..9548f0113a 100644--- a/react/features/invite/components/add-people-dialog/AbstractAddPeopleDialog.tsx+++ b/react/features/invite/components/add-people-dialog/AbstractAddPeopleDialog.tsx@@ -2,7 +2,7 @@ import { Component } from 'react';import { createInviteDialogEvent } from '../../../analytics/AnalyticsEvents';import { sendAnalytics } from '../../../analytics/functions';-import { IReduxState } from '../../../app/types';+import { IReduxState, IStore } from '../../../app/types';import { showErrorNotification, showNotification } from '../../../notifications/actions';import { NOTIFICATION_TIMEOUT_TYPE } from '../../../notifications/constants';import { INotificationProps } from '../../../notifications/types';@@ -50,17 +50,17 @@ export interface IProps {*/_dialOutRegionUrl: string;- /**+ /*** The JWT token.*/_jwt: string;- /**+ /*** The query types used when searching people.*/_peopleSearchQueryTypes: Array<string>;- /**+ /*** The URL pointing to the service allowing for people search.*/_peopleSearchUrl: string;@@ -73,7 +73,7 @@ export interface IProps {/*** The Redux dispatch function.*/- dispatch: Function;+ dispatch: IStore['dispatch'];}export interface IState {diff --git a/react/features/keyboard-shortcuts/middleware.ts b/react/features/keyboard-shortcuts/middleware.tsindex 7deed0ba84..1c397315d7 100644--- a/react/features/keyboard-shortcuts/middleware.ts+++ b/react/features/keyboard-shortcuts/middleware.ts@@ -1,3 +1,5 @@+import { AnyAction } from 'redux';+import { IStore } from '../app/types';import { SET_CONFIG } from '../base/config/actionTypes';import MiddlewareRegistry from '../base/redux/MiddlewareRegistry';@@ -5,7 +7,7 @@ import { CAPTURE_EVENTS } from '../remote-control/actionTypes';import { disableKeyboardShortcuts, enableKeyboardShortcuts } from './actions';-MiddlewareRegistry.register((store: IStore) => (next: Function) => (action: any) => {+MiddlewareRegistry.register((store: IStore) => (next: Function) => (action: AnyAction) => {const { dispatch } = store;switch (action.type) {diff --git a/react/features/large-video/components/LargeVideo.web.tsx b/react/features/large-video/components/LargeVideo.web.tsxindex 9ba269a6f1..a97217d3cf 100644--- a/react/features/large-video/components/LargeVideo.web.tsx+++ b/react/features/large-video/components/LargeVideo.web.tsx@@ -3,7 +3,7 @@ import { connect } from 'react-redux';// @ts-expect-errorimport VideoLayout from '../../../../modules/UI/videolayout/VideoLayout';-import { IReduxState } from '../../app/types';+import { IReduxState, IStore } from '../../app/types';import { VIDEO_TYPE } from '../../base/media/constants';import { getLocalParticipant } from '../../base/participants/functions';import Watermarks from '../../base/react/components/web/Watermarks';@@ -117,7 +117,7 @@ interface IProps {/*** The Redux dispatch function.*/- dispatch: Function;+ dispatch: IStore['dispatch'];}/** .diff --git a/react/features/lobby/components/AbstractLobbyScreen.tsx b/react/features/lobby/components/AbstractLobbyScreen.tsxindex fd0e7d4744..a31f0b2337 100644--- a/react/features/lobby/components/AbstractLobbyScreen.tsx+++ b/react/features/lobby/components/AbstractLobbyScreen.tsx@@ -1,6 +1,6 @@import React, { PureComponent } from 'react';-import { IReduxState } from '../../app/types';+import { IReduxState, IStore } from '../../app/types';import { conferenceWillJoin } from '../../base/conference/actions';import { getConferenceName } from '../../base/conference/functions';import { IJitsiConference } from '../../base/conference/reducer';@@ -85,7 +85,7 @@ export interface IProps {/*** The Redux dispatch function.*/- dispatch: Function;+ dispatch: IStore['dispatch'];/*** Indicates whether the copy url button should be shown.diff --git a/react/features/lobby/components/web/LobbySection.tsx b/react/features/lobby/components/web/LobbySection.tsxindex 2f680cfcc2..080955f06f 100644--- a/react/features/lobby/components/web/LobbySection.tsx+++ b/react/features/lobby/components/web/LobbySection.tsx@@ -2,7 +2,7 @@ import React, { PureComponent } from 'react';import { WithTranslation } from 'react-i18next';import { connect } from 'react-redux';-import { IReduxState } from '../../../app/types';+import { IReduxState, IStore } from '../../../app/types';import { getSecurityUiConfig } from '../../../base/config/functions.any';import { translate } from '../../../base/i18n/functions';import { isLocalParticipantModerator } from '../../../base/participants/functions';@@ -25,7 +25,7 @@ interface IProps extends WithTranslation {/*** The Redux Dispatch function.*/- dispatch: Function;+ dispatch: IStore['dispatch'];}interface IState {diff --git a/react/features/mobile/audio-mode/components/AudioRoutePickerDialog.tsx b/react/features/mobile/audio-mode/components/AudioRoutePickerDialog.tsxindex c9a1e731a0..bb2078c1ef 100644--- a/react/features/mobile/audio-mode/components/AudioRoutePickerDialog.tsx+++ b/react/features/mobile/audio-mode/components/AudioRoutePickerDialog.tsx@@ -3,7 +3,7 @@ import React, { Component } from 'react';import { NativeModules, Text, TextStyle, TouchableHighlight, View, ViewStyle } from 'react-native';import { connect } from 'react-redux';-import { IReduxState } from '../../../app/types';+import { IReduxState, IStore } from '../../../app/types';import { hideSheet } from '../../../base/dialog/actions';import BottomSheet from '../../../base/dialog/components/native/BottomSheet';import { bottomSheetStyles } from '../../../base/dialog/components/native/styles';@@ -94,7 +94,7 @@ interface IProps {/*** Used for hiding the dialog when the selection was completed.*/- dispatch: Function;+ dispatch: IStore['dispatch'];/*** Invoked to obtain translated strings.diff --git a/react/features/mobile/navigation/components/RootNavigationContainer.tsx b/react/features/mobile/navigation/components/RootNavigationContainer.tsxindex 0439b3a620..0fc7fc87c1 100644--- a/react/features/mobile/navigation/components/RootNavigationContainer.tsx+++ b/react/features/mobile/navigation/components/RootNavigationContainer.tsx@@ -4,7 +4,7 @@ import React, { useCallback } from 'react';import { StatusBar } from 'react-native';import { connect } from 'react-redux';-import { IReduxState } from '../../../app/types';+import { IReduxState, IStore } from '../../../app/types';import DialInSummary from '../../../invite/components/dial-in-summary/native/DialInSummary';import Prejoin from '../../../prejoin/components/native/Prejoin';import UnsafeRoomWarning from '../../../prejoin/components/native/UnsafeRoomWarning';@@ -37,7 +37,7 @@ interface IProps {/*** Redux dispatch function.*/- dispatch: Function;+ dispatch: IStore['dispatch'];/*** Is welcome page available?diff --git a/react/features/noise-suppression/functions.ts b/react/features/noise-suppression/functions.tsindex bcd6c5ede0..1b85c7521f 100644--- a/react/features/noise-suppression/functions.ts+++ b/react/features/noise-suppression/functions.ts@@ -1,4 +1,4 @@-import { IReduxState } from '../app/types';+import { IReduxState, IStore } from '../app/types';import { showWarningNotification } from '../notifications/actions';import { NOTIFICATION_TIMEOUT_TYPE } from '../notifications/constants';import { isScreenAudioShared } from '../screen-share/functions';@@ -21,7 +21,7 @@ export function isNoiseSuppressionEnabled(state: IReduxState): boolean {* @param {*} localAudio - Current local audio track.* @returns {boolean}*/-export function canEnableNoiseSuppression(state: IReduxState, dispatch: Function, localAudio: any): boolean {+export function canEnableNoiseSuppression(state: IReduxState, dispatch: IStore['dispatch'], localAudio: any): boolean {if (!localAudio) {dispatch(showWarningNotification({titleKey: 'notify.noiseSuppressionFailedTitle',diff --git a/react/features/notifications/components/native/NotificationsContainer.tsx b/react/features/notifications/components/native/NotificationsContainer.tsxindex 5d0091c34f..265219c4cc 100644--- a/react/features/notifications/components/native/NotificationsContainer.tsx+++ b/react/features/notifications/components/native/NotificationsContainer.tsx@@ -4,7 +4,7 @@ import { Platform } from 'react-native';import { Edge, SafeAreaView } from 'react-native-safe-area-context';import { connect } from 'react-redux';-import { IReduxState } from '../../../app/types';+import { IReduxState, IStore } from '../../../app/types';import { hideNotification } from '../../actions';import { areThereNotifications } from '../../functions';import NotificationsTransition from '../NotificationsTransition';@@ -24,7 +24,7 @@ interface IProps extends WithTranslation {/*** Invoked to update the redux store in order to remove notifications.*/- dispatch: Function;+ dispatch: IStore['dispatch'];/*** Whether or not the layout should change to support tile view mode.diff --git a/react/features/notifications/components/web/NotificationsContainer.tsx b/react/features/notifications/components/web/NotificationsContainer.tsxindex 2aa05d1756..622ec8f06c 100644--- a/react/features/notifications/components/web/NotificationsContainer.tsx+++ b/react/features/notifications/components/web/NotificationsContainer.tsx@@ -2,7 +2,7 @@ import React, { useCallback } from 'react';import { connect } from 'react-redux';import { makeStyles } from 'tss-react/mui';-import { IReduxState } from '../../../app/types';+import { IReduxState, IStore } from '../../../app/types';import { hideNotification } from '../../actions';import { areThereNotifications } from '../../functions';import { INotificationProps } from '../../types';@@ -33,7 +33,7 @@ interface IProps {/*** Invoked to update the redux store in order to remove notifications.*/- dispatch: Function;+ dispatch: IStore['dispatch'];/*** Whether or not the notifications are displayed in a portal.diff --git a/react/features/participants-pane/components/native/MeetingParticipantItem.tsx b/react/features/participants-pane/components/native/MeetingParticipantItem.tsxindex 8b4fbf1252..350388bee3 100644--- a/react/features/participants-pane/components/native/MeetingParticipantItem.tsx+++ b/react/features/participants-pane/components/native/MeetingParticipantItem.tsx@@ -1,7 +1,7 @@import React, { PureComponent } from 'react';import { connect } from 'react-redux';-import { IReduxState } from '../../../app/types';+import { IReduxState, IStore } from '../../../app/types';import { translate } from '../../../base/i18n/functions';import {getLocalParticipant,@@ -76,7 +76,7 @@ interface IProps {/*** The redux dispatch function.*/- dispatch: Function;+ dispatch: IStore['dispatch'];/*** The participant.diff --git a/react/features/participants-pane/components/native/MeetingParticipantList.tsx b/react/features/participants-pane/components/native/MeetingParticipantList.tsxindex 11585a2ca8..1cf3cd92c3 100644--- a/react/features/participants-pane/components/native/MeetingParticipantList.tsx+++ b/react/features/participants-pane/components/native/MeetingParticipantList.tsx@@ -3,7 +3,7 @@ import { WithTranslation } from 'react-i18next';import { FlatList, Text } from 'react-native';import { connect } from 'react-redux';-import { IReduxState } from '../../../app/types';+import { IReduxState, IStore } from '../../../app/types';import { translate } from '../../../base/i18n/functions';import Icon from '../../../base/icons/components/Icon';import { IconAddUser } from '../../../base/icons/svg';@@ -88,7 +88,7 @@ interface IProps extends WithTranslation {/*** The redux dispatch function.*/- dispatch: Function;+ dispatch: IStore['dispatch'];/*** Is the local participant moderator?diff --git a/react/features/participants-pane/components/native/RoomParticipantMenu.tsx b/react/features/participants-pane/components/native/RoomParticipantMenu.tsxindex 20a176bdb6..c7eb501fe8 100644--- a/react/features/participants-pane/components/native/RoomParticipantMenu.tsx+++ b/react/features/participants-pane/components/native/RoomParticipantMenu.tsx@@ -3,7 +3,7 @@ import { WithTranslation } from 'react-i18next';import { Text, TextStyle, View, ViewStyle } from 'react-native';import { connect } from 'react-redux';-import { IReduxState } from '../../../app/types';+import { IReduxState, IStore } from '../../../app/types';import Avatar from '../../../base/avatar/components/Avatar';import { hideSheet } from '../../../base/dialog/actions';import BottomSheet from '../../../base/dialog/components/native/BottomSheet';@@ -30,7 +30,7 @@ interface IProps extends WithTranslation {/*** The Redux dispatch function.*/- dispatch: Function;+ dispatch: IStore['dispatch'];/*** The jid of the selected participant.diff --git a/react/features/participants-pane/middleware.ts b/react/features/participants-pane/middleware.tsindex d3c5ca9b89..0607c1794f 100644--- a/react/features/participants-pane/middleware.ts+++ b/react/features/participants-pane/middleware.ts@@ -1,3 +1,5 @@+import { AnyAction } from 'redux';+import MiddlewareRegistry from '../base/redux/MiddlewareRegistry';import { PARTICIPANTS_PANE_CLOSE, PARTICIPANTS_PANE_OPEN } from './actionTypes';@@ -8,7 +10,7 @@ import { PARTICIPANTS_PANE_CLOSE, PARTICIPANTS_PANE_OPEN } from './actionTypes';* @param {IStore} store - The redux store.* @returns {Function}*/-MiddlewareRegistry.register(() => (next: Function) => (action: any) => {+MiddlewareRegistry.register(() => (next: Function) => (action: AnyAction) => {switch (action.type) {case PARTICIPANTS_PANE_OPEN:if (typeof APP !== 'undefined') {diff --git a/react/features/prejoin/actions.web.ts b/react/features/prejoin/actions.web.tsindex 22f78fa721..b7f92227f7 100644--- a/react/features/prejoin/actions.web.ts+++ b/react/features/prejoin/actions.web.ts@@ -310,7 +310,7 @@ export function joinConferenceWithoutAudio() {* @returns {Function}*/export function makePrecallTest(conferenceOptions: Object) {- return async function(dispatch: Function) {+ return async function(dispatch: IStore['dispatch']) {try {await JitsiMeetJS.precallTest.init(conferenceOptions);const results = await JitsiMeetJS.precallTest.execute();diff --git a/react/features/reactions/actions.any.ts b/react/features/reactions/actions.any.tsindex d21e64d8ad..dbd91a6f07 100644--- a/react/features/reactions/actions.any.ts+++ b/react/features/reactions/actions.any.ts@@ -1,3 +1,5 @@+import { IStore } from '../app/types';+import {ADD_REACTION_BUFFER,ADD_REACTION_MESSAGE,@@ -31,7 +33,7 @@ export function setReactionQueue(queue: Array<IReactionEmojiProps>): IReactionsA* @returns {Function}*/export function removeReaction(uid: string): any {- return (dispatch: Function, getState: Function) => {+ return (dispatch: IStore['dispatch'], getState: IStore['getState']) => {const queue = getState()['features/reactions'].queue;dispatch(setReactionQueue(queue.filter((reaction: IReactionEmojiProps) => reaction.uid !== uid)));diff --git a/react/features/reactions/components/web/ReactionsMenuButton.tsx b/react/features/reactions/components/web/ReactionsMenuButton.tsxindex 7e8d803735..cff3e076f9 100644--- a/react/features/reactions/components/web/ReactionsMenuButton.tsx+++ b/react/features/reactions/components/web/ReactionsMenuButton.tsx@@ -2,7 +2,7 @@ import React, { ReactElement, useCallback } from 'react';import { WithTranslation } from 'react-i18next';import { connect } from 'react-redux';-import { IReduxState } from '../../../app/types';+import { IReduxState, IStore } from '../../../app/types';import { isMobileBrowser } from '../../../base/environment/utils';import { translate } from '../../../base/i18n/functions';import { IconArrowUp, IconFaceSmile } from '../../../base/icons/svg';@@ -38,7 +38,7 @@ interface IProps extends WithTranslation {/*** Redux dispatch function.*/- dispatch: Function;+ dispatch: IStore['dispatch'];/*** Click handler for raise hand functionality.diff --git a/react/features/reactions/middleware.ts b/react/features/reactions/middleware.tsindex a72140e094..ce753e2740 100644--- a/react/features/reactions/middleware.ts+++ b/react/features/reactions/middleware.ts@@ -1,4 +1,5 @@import { batch } from 'react-redux';+import { AnyAction } from 'redux';import { createReactionSoundsDisabledEvent } from '../analytics/AnalyticsEvents';import { sendAnalytics } from '../analytics/functions';@@ -59,7 +60,7 @@ import { RAISE_HAND_SOUND_FILE } from './sounds';* @param {IStore} store - The redux store.* @returns {Function}*/-MiddlewareRegistry.register((store: IStore) => (next: Function) => (action: any) => {+MiddlewareRegistry.register((store: IStore) => (next: Function) => (action: AnyAction) => {const { dispatch, getState } = store;switch (action.type) {diff --git a/react/features/recording/actions.any.ts b/react/features/recording/actions.any.tsindex 5558deb5de..1ee7243183 100644--- a/react/features/recording/actions.any.ts+++ b/react/features/recording/actions.any.ts@@ -134,7 +134,7 @@ export function showPendingRecordingNotification(streamType: string) {* @returns {Function}*/export function highlightMeetingMoment() {- return async (dispatch: Function, getState: Function) => {+ return async (dispatch: IStore['dispatch'], getState: IStore['getState']) => {dispatch(setHighlightMomentButtonState(true));const success = await sendMeetingHighlight(getState());@@ -209,7 +209,7 @@ export function showStartedRecordingNotification(mode: string,initiator: { getId: Function; } | string,sessionId: string) {- return async (dispatch: Function, getState: Function) => {+ return async (dispatch: IStore['dispatch'], getState: IStore['getState']) => {const state = getState();const initiatorId = getResourceId(initiator);const participantName = getParticipantDisplayName(state, initiatorId);diff --git a/react/features/recording/components/LiveStream/AbstractStartLiveStreamDialog.ts b/react/features/recording/components/LiveStream/AbstractStartLiveStreamDialog.tsindex a8fd14e8a9..8ffc92f787 100644--- a/react/features/recording/components/LiveStream/AbstractStartLiveStreamDialog.ts+++ b/react/features/recording/components/LiveStream/AbstractStartLiveStreamDialog.ts@@ -3,7 +3,7 @@ import { WithTranslation } from 'react-i18next';import { createLiveStreamingDialogEvent } from '../../../analytics/AnalyticsEvents';import { sendAnalytics } from '../../../analytics/functions';-import { IReduxState } from '../../../app/types';+import { IReduxState, IStore } from '../../../app/types';import { IJitsiConference } from '../../../base/conference/reducer';import { JitsiRecordingConstants } from '../../../base/lib-jitsi-meet';@@ -38,7 +38,7 @@ export interface IProps extends WithTranslation {/*** The Redux dispatch function.*/- dispatch: Function;+ dispatch: IStore['dispatch'];navigation?: any;}diff --git a/react/features/recording/components/LiveStream/native/GoogleSigninForm.tsx b/react/features/recording/components/LiveStream/native/GoogleSigninForm.tsxindex fa92e0b711..e5095767d5 100644--- a/react/features/recording/components/LiveStream/native/GoogleSigninForm.tsx+++ b/react/features/recording/components/LiveStream/native/GoogleSigninForm.tsx@@ -3,7 +3,7 @@ import { WithTranslation } from 'react-i18next';import { Text, View, ViewStyle } from 'react-native';import { connect } from 'react-redux';-import { IReduxState } from '../../../../app/types';+import { IReduxState, IStore } from '../../../../app/types';import { _abstractMapStateToProps } from '../../../../base/dialog/functions';import { translate } from '../../../../base/i18n/functions';import { setGoogleAPIState } from '../../../../google-api/actions';@@ -32,7 +32,7 @@ interface IProps extends WithTranslation {/*** The Redux dispatch Function.*/- dispatch: Function;+ dispatch: IStore['dispatch'];/*** The current state of the Google api as defined in {@code constants.js}.diff --git a/react/features/recording/components/Recording/AbstractStartRecordingDialogContent.tsx b/react/features/recording/components/Recording/AbstractStartRecordingDialogContent.tsxindex ea685d5cfe..c072f1fa90 100644--- a/react/features/recording/components/Recording/AbstractStartRecordingDialogContent.tsx+++ b/react/features/recording/components/Recording/AbstractStartRecordingDialogContent.tsx@@ -3,7 +3,7 @@ import { WithTranslation } from 'react-i18next';import { createRecordingDialogEvent } from '../../../analytics/AnalyticsEvents';import { sendAnalytics } from '../../../analytics/functions';-import { IReduxState } from '../../../app/types';+import { IReduxState, IStore } from '../../../app/types';import ColorSchemeRegistry from '../../../base/color-scheme/ColorSchemeRegistry';import { _abstractMapStateToProps } from '../../../base/dialog/functions';import { isLocalParticipantModerator } from '../../../base/participants/functions';@@ -61,7 +61,7 @@ export interface IProps extends WithTranslation {/*** The redux dispatch function.*/- dispatch: Function;+ dispatch: IStore['dispatch'];/*** Whether to show file recordings service, even if integrationsdiff --git a/react/features/recording/components/Recording/AbstractStopRecordingDialog.ts b/react/features/recording/components/Recording/AbstractStopRecordingDialog.tsindex 08b7f71e77..e66551f760 100644--- a/react/features/recording/components/Recording/AbstractStopRecordingDialog.ts+++ b/react/features/recording/components/Recording/AbstractStopRecordingDialog.ts@@ -3,7 +3,7 @@ import { WithTranslation } from 'react-i18next';import { createRecordingDialogEvent } from '../../../analytics/AnalyticsEvents';import { sendAnalytics } from '../../../analytics/functions';-import { IReduxState } from '../../../app/types';+import { IReduxState, IStore } from '../../../app/types';import { IJitsiConference } from '../../../base/conference/reducer';import { JitsiRecordingConstants } from '../../../base/lib-jitsi-meet';import { setVideoMuted } from '../../../base/media/actions';@@ -37,7 +37,7 @@ export interface IProps extends WithTranslation {/*** The redux dispatch function.*/- dispatch: Function;+ dispatch: IStore['dispatch'];/*** The user trying to stop the video while local recording is running.diff --git a/react/features/remote-control/actions.ts b/react/features/remote-control/actions.tsindex fc3eb3732c..a03b733a9d 100644--- a/react/features/remote-control/actions.ts+++ b/react/features/remote-control/actions.ts@@ -229,7 +229,7 @@ export function processPermissionRequestReply(participantId: string, event: any)* @returns {void}*/export function handleRemoteControlStoppedEvent(participantId: Object, event: { name: string; type: string; }) {- return (dispatch: Function, getState: Function) => {+ return (dispatch: IStore['dispatch'], getState: IStore['getState']) => {const state = getState();const { name, type } = event;const { controlled } = state['features/remote-control'].controller;@@ -365,7 +365,7 @@ export function enableReceiver() {* @returns {Function}*/export function disableReceiver() {- return (dispatch: Function, getState: Function) => {+ return (dispatch: IStore['dispatch'], getState: IStore['getState']) => {const state = getState();const { enabled } = state['features/remote-control'].receiver;@@ -405,7 +405,7 @@ export function disableReceiver() {* @returns {Function}*/export function stopReceiver(dontNotifyLocalParty = false, dontNotifyRemoteParty = false) {- return (dispatch: Function, getState: Function) => {+ return (dispatch: IStore['dispatch'], getState: IStore['getState']) => {const state = getState();const { receiver } = state['features/remote-control'];const { controller, transport } = receiver;@@ -427,7 +427,7 @@ export function stopReceiver(dontNotifyLocalParty = false, dontNotifyRemotePartycontroller: undefined});- transport.sendEvent({+ transport?.sendEvent({name: REMOTE_CONTROL_MESSAGE_NAME,type: EVENTS.stop});diff --git a/react/features/remote-control/components/RemoteControlAuthorizationDialog.tsx b/react/features/remote-control/components/RemoteControlAuthorizationDialog.tsxindex c8e73e2bf7..debcf54d1f 100644--- a/react/features/remote-control/components/RemoteControlAuthorizationDialog.tsx+++ b/react/features/remote-control/components/RemoteControlAuthorizationDialog.tsx@@ -1,7 +1,7 @@import React, { Component } from 'react';import { connect } from 'react-redux';-import { IReduxState } from '../../app/types';+import { IReduxState, IStore } from '../../app/types';import { translate } from '../../base/i18n/functions';import { getParticipantById } from '../../base/participants/functions';import { getLocalVideoTrack } from '../../base/tracks/functions.any';@@ -26,7 +26,7 @@ interface IProps {/*** Used to show/hide the dialog on cancel.*/- dispatch: Function;+ dispatch: IStore['dispatch'];/*** The ID of the participant who is requesting authorization for remotediff --git a/react/features/settings/components/native/SettingsView.tsx b/react/features/settings/components/native/SettingsView.tsxindex abdc5d7631..5c0072689f 100644--- a/react/features/settings/components/native/SettingsView.tsx+++ b/react/features/settings/components/native/SettingsView.tsx@@ -15,7 +15,7 @@ import { Divider } from 'react-native-paper';import { connect } from 'react-redux';import { getDefaultURL } from '../../../app/functions.native';-import { IReduxState } from '../../../app/types';+import { IReduxState, IStore } from '../../../app/types';import Avatar from '../../../base/avatar/components/Avatar';import { getLegalUrls } from '../../../base/config/functions.native';import { translate } from '../../../base/i18n/functions';@@ -156,7 +156,7 @@ interface IProps extends WithTranslation {/*** Redux store dispatch function.*/- dispatch: Function;+ dispatch: IStore['dispatch'];/*** Default prop for navigating between screen components(React Navigation).diff --git a/react/features/settings/components/web/CalendarTab.tsx b/react/features/settings/components/web/CalendarTab.tsxindex 5a4f8a0384..fe013ca7cc 100644--- a/react/features/settings/components/web/CalendarTab.tsx+++ b/react/features/settings/components/web/CalendarTab.tsx@@ -4,7 +4,7 @@ import React, { Component } from 'react';import { WithTranslation } from 'react-i18next';import { connect } from 'react-redux';-import { IReduxState } from '../../../app/types';+import { IReduxState, IStore } from '../../../app/types';import { translate } from '../../../base/i18n/functions';import { withPixelLineHeight } from '../../../base/styles/functions.web';import Button from '../../../base/ui/components/web/Button';@@ -54,7 +54,7 @@ interface IProps extends WithTranslation {/*** Invoked to change the configured calendar integration.*/- dispatch: Function;+ dispatch: IStore['dispatch'];}/**diff --git a/react/features/settings/components/web/SettingsDialog.tsx b/react/features/settings/components/web/SettingsDialog.tsxindex ab829c2047..6bcf12251f 100644--- a/react/features/settings/components/web/SettingsDialog.tsx+++ b/react/features/settings/components/web/SettingsDialog.tsx@@ -2,7 +2,7 @@ import React from 'react';import { connect } from 'react-redux';import { makeStyles } from 'tss-react/mui';-import { IReduxState } from '../../../app/types';+import { IReduxState, IStore } from '../../../app/types';import {IconBell,IconCalendar,@@ -72,7 +72,7 @@ interface IProps {/*** Invoked to save changed settings.*/- dispatch: Function;+ dispatch: IStore['dispatch'];/*** Indicates whether the device selection dialog is displayed on thediff --git a/react/features/shared-video/components/web/AbstractVideoManager.ts b/react/features/shared-video/components/web/AbstractVideoManager.tsindex 50db313e74..5406d6c4d6 100644--- a/react/features/shared-video/components/web/AbstractVideoManager.ts+++ b/react/features/shared-video/components/web/AbstractVideoManager.ts@@ -5,7 +5,7 @@ import { PureComponent } from 'react';import { createSharedVideoEvent as createEvent } from '../../../analytics/AnalyticsEvents';import { sendAnalytics } from '../../../analytics/functions';-import { IReduxState } from '../../../app/types';+import { IReduxState, IStore } from '../../../app/types';import { getCurrentConference } from '../../../base/conference/functions';import { IJitsiConference } from '../../../base/conference/reducer';import { MEDIA_TYPE } from '../../../base/media/constants';@@ -464,7 +464,7 @@ export function _mapStateToProps(state: IReduxState) {* @param {Function} dispatch - The Redux dispatch function.* @returns {IProps}*/-export function _mapDispatchToProps(dispatch: Function) {+export function _mapDispatchToProps(dispatch: IStore['dispatch']) {return {_displayWarning: () => {dispatch(showWarningNotification({diff --git a/react/features/subtitles/components/AbstractLanguageSelectorDialog.tsx b/react/features/subtitles/components/AbstractLanguageSelectorDialog.tsxindex b376f7629e..b7c9e574df 100644--- a/react/features/subtitles/components/AbstractLanguageSelectorDialog.tsx+++ b/react/features/subtitles/components/AbstractLanguageSelectorDialog.tsx@@ -2,7 +2,7 @@ import React, { ComponentType, useCallback, useEffect, useState } from 'react';import { useTranslation } from 'react-i18next';import { useDispatch, useSelector } from 'react-redux';-import { IReduxState } from '../../app/types';+import { IReduxState, IStore } from '../../app/types';import {TRANSLATION_LANGUAGES,TRANSLATION_LANGUAGES_HEAD@@ -11,7 +11,7 @@ import { setRequestingSubtitles, updateTranslationLanguage } from '../actions.anexport interface IAbstractLanguageSelectorDialogProps {- dispatch: Function;+ dispatch: IStore['dispatch'];language: string;listItems: Array<any>;onLanguageSelected: (e: string) => void;diff --git a/react/features/toolbox/actions.web.ts b/react/features/toolbox/actions.web.tsindex f41975cc18..2d30a2a30c 100644--- a/react/features/toolbox/actions.web.ts+++ b/react/features/toolbox/actions.web.ts@@ -196,7 +196,7 @@ export function clearToolboxTimeout() {* visible: boolean* }}*/-export function setHangupMenuVisible(visible: boolean): Object {+export function setHangupMenuVisible(visible: boolean) {return {type: SET_HANGUP_MENU_VISIBLE,visible@@ -228,7 +228,7 @@ export function setOverflowMenuVisible(visible: boolean) {* hovered: boolean* }}*/-export function setToolbarHovered(hovered: boolean): Object {+export function setToolbarHovered(hovered: boolean) {return {type: SET_TOOLBAR_HOVERED,hovereddiff --git a/react/features/toolbox/components/web/Toolbox.tsx b/react/features/toolbox/components/web/Toolbox.tsxindex 988b4a6ed9..27f84f830c 100644--- a/react/features/toolbox/components/web/Toolbox.tsx+++ b/react/features/toolbox/components/web/Toolbox.tsx@@ -6,7 +6,7 @@ import { batch, connect } from 'react-redux';import { isSpeakerStatsDisabled } from '../../../../features/speaker-stats/functions';import { ACTION_SHORTCUT_TRIGGERED, createShortcutEvent, createToolbarEvent } from '../../../analytics/AnalyticsEvents';import { sendAnalytics } from '../../../analytics/functions';-import { IReduxState } from '../../../app/types';+import { IReduxState, IStore } from '../../../app/types';import { IJitsiConference } from '../../../base/conference/reducer';import { VISITORS_MODE_BUTTONS } from '../../../base/config/constants';import {@@ -331,7 +331,7 @@ interface IProps extends WithTranslation {/*** Invoked to active other features of the app.*/- dispatch: Function;+ dispatch: IStore['dispatch'];/*** Explicitly passed array with the buttons which this Toolbox should display.diff --git a/react/features/video-menu/components/AbstractMuteRemoteParticipantDialog.ts b/react/features/video-menu/components/AbstractMuteRemoteParticipantDialog.tsindex e42fea9400..a138d181a8 100644--- a/react/features/video-menu/components/AbstractMuteRemoteParticipantDialog.ts+++ b/react/features/video-menu/components/AbstractMuteRemoteParticipantDialog.ts@@ -1,6 +1,7 @@import { Component } from 'react';import { WithTranslation } from 'react-i18next';+import { IStore } from '../../app/types';import { MEDIA_TYPE } from '../../base/media/constants';import { muteRemote } from '../actions';@@ -13,7 +14,7 @@ export interface IProps extends WithTranslation {/*** The Redux dispatch function.*/- dispatch: Function;+ dispatch: IStore['dispatch'];/*** The ID of the remote participant to be muted.diff --git a/react/features/video-menu/components/AbstractMuteRemoteParticipantsVideoDialog.ts b/react/features/video-menu/components/AbstractMuteRemoteParticipantsVideoDialog.tsindex b70e49d362..695ae89759 100644--- a/react/features/video-menu/components/AbstractMuteRemoteParticipantsVideoDialog.ts+++ b/react/features/video-menu/components/AbstractMuteRemoteParticipantsVideoDialog.ts@@ -1,7 +1,7 @@import { Component } from 'react';import { WithTranslation } from 'react-i18next';-import { IReduxState } from '../../app/types';+import { IReduxState, IStore } from '../../app/types';import { rejectParticipantVideo } from '../../av-moderation/actions';import { isEnabledFromState } from '../../av-moderation/functions';import { MEDIA_TYPE } from '../../base/media/constants';@@ -16,7 +16,7 @@ export interface IProps extends WithTranslation {/*** The Redux dispatch function.*/- dispatch: Function;+ dispatch: IStore['dispatch'];/*** Whether or not video moderation is on.diff --git a/react/features/video-menu/components/native/ConnectionStatusComponent.tsx b/react/features/video-menu/components/native/ConnectionStatusComponent.tsxindex 5cbb812a4a..0a7b4519ff 100644--- a/react/features/video-menu/components/native/ConnectionStatusComponent.tsx+++ b/react/features/video-menu/components/native/ConnectionStatusComponent.tsx@@ -4,7 +4,7 @@ import { Text, TextStyle, View, ViewStyle } from 'react-native';import { withTheme } from 'react-native-paper';import { connect } from 'react-redux';-import { IReduxState } from '../../../app/types';+import { IReduxState, IStore } from '../../../app/types';import Avatar from '../../../base/avatar/components/Avatar';import { hideSheet } from '../../../base/dialog/actions';import BottomSheet from '../../../base/dialog/components/native/BottomSheet';@@ -76,7 +76,7 @@ interface IProps extends WithTranslation {/*** The Redux dispatch function.*/- dispatch: Function;+ dispatch: IStore['dispatch'];/*** The ID of the participant that this button is supposed to pin.diff --git a/react/features/video-menu/components/native/RemoteVideoMenu.tsx b/react/features/video-menu/components/native/RemoteVideoMenu.tsxindex 37c9c9ee15..9326812cfe 100644--- a/react/features/video-menu/components/native/RemoteVideoMenu.tsx+++ b/react/features/video-menu/components/native/RemoteVideoMenu.tsx@@ -5,7 +5,7 @@ import { Text, TextStyle, View, ViewStyle } from 'react-native';import { Divider } from 'react-native-paper';import { connect } from 'react-redux';-import { IReduxState } from '../../../app/types';+import { IReduxState, IStore } from '../../../app/types';import Avatar from '../../../base/avatar/components/Avatar';import { hideSheet } from '../../../base/dialog/actions';import BottomSheet from '../../../base/dialog/components/native/BottomSheet';@@ -90,7 +90,7 @@ interface IProps {/*** The Redux dispatch function.*/- dispatch: Function;+ dispatch: IStore['dispatch'];/*** The ID of the participant for which this menu opened for.diff --git a/react/features/virtual-background/components/VirtualBackgroundPreview.tsx b/react/features/virtual-background/components/VirtualBackgroundPreview.tsxindex a008ac6be6..315757bc70 100644--- a/react/features/virtual-background/components/VirtualBackgroundPreview.tsx+++ b/react/features/virtual-background/components/VirtualBackgroundPreview.tsx@@ -4,6 +4,7 @@ import React, { PureComponent } from 'react';import { WithTranslation } from 'react-i18next';import { connect } from 'react-redux';+import { IStore } from '../../app/types';import { hideDialog } from '../../base/dialog/actions';import { translate } from '../../base/i18n/functions';import { Video } from '../../base/media/components/index';@@ -28,7 +29,7 @@ export interface IProps extends WithTranslation {/*** The redux {@code dispatch} function.*/- dispatch: Function;+ dispatch: IStore['dispatch'];/*** Dialog callback that indicates if the background preview was loaded.diff --git a/react/features/virtual-background/components/VirtualBackgrounds.tsx b/react/features/virtual-background/components/VirtualBackgrounds.tsxindex f18311e17e..2b38e72142 100644--- a/react/features/virtual-background/components/VirtualBackgrounds.tsx+++ b/react/features/virtual-background/components/VirtualBackgrounds.tsx@@ -8,7 +8,7 @@ import { WithTranslation } from 'react-i18next';import { connect } from 'react-redux';import { makeStyles } from 'tss-react/mui';-import { IReduxState } from '../../app/types';+import { IReduxState, IStore } from '../../app/types';import { getMultipleVideoSendingSupportFeatureFlag } from '../../base/config/functions.any';import { translate } from '../../base/i18n/functions';import Icon from '../../base/icons/components/Icon';@@ -54,7 +54,7 @@ interface IProps extends WithTranslation {/*** The redux {@code dispatch} function.*/- dispatch: Function;+ dispatch: IStore['dispatch'];/*** The initial options copied in the state for the {@code VirtualBackground} component.diff --git a/react/features/web-hid/functions.ts b/react/features/web-hid/functions.tsindex 3320e621e5..25bdaf3ac5 100644--- a/react/features/web-hid/functions.ts+++ b/react/features/web-hid/functions.ts@@ -1,4 +1,4 @@-import { IReduxState } from '../app/types';+import { IReduxState, IStore } from '../app/types';import { MEDIA_TYPE } from '../base/media/constants';import { muteLocal } from '../video-menu/actions.any';@@ -77,7 +77,7 @@ export function getDeviceInfo(state: IReduxState): IDeviceInfo {* @returns {void}*/export function handleUpdateHidDevice(- dispatch: Function,+ dispatch: IStore['dispatch'],customEventData: CustomEvent<{ actionResult?: { eventName: string; }; deviceInfo: IDeviceInfo; }>) {dispatch(updateDeviceInfo(customEventData.detail.deviceInfo));diff --git a/react/features/whiteboard/middleware.ts b/react/features/whiteboard/middleware.tsindex 86b6c316b9..78ed363619 100644--- a/react/features/whiteboard/middleware.ts+++ b/react/features/whiteboard/middleware.ts@@ -1,4 +1,5 @@import { generateCollaborationLinkData } from '@jitsi/excalidraw';+import { AnyAction } from 'redux';import { IStore } from '../app/types';import { getCurrentConference } from '../base/conference/functions';@@ -45,7 +46,7 @@ const focusWhiteboard = (store: IStore) => {* @param {Store} store - The redux store.* @returns {Function}*/-MiddlewareRegistry.register((store: IStore) => (next: Function) => async (action: any) => {+MiddlewareRegistry.register((store: IStore) => (next: Function) => async (action: AnyAction) => {const { dispatch, getState } = store;const state = getState();const conference = getCurrentConference(state);