mirror of
https://gitcode.com/GitHub_Trending/ji/jitsi-meet.git
synced 2026-05-14 14:17:46 +00:00
* fix(subtitles): Handle errors to revert to default state. * fix(transcribing): Handle transcriber status changed. Drops potential transcribers and hidden participant actions and handling. Expect ljm to detect transcriptions on and off. * feat(transcriptions): Adds a notification if transcriber leaves abruptly. * squash: Renames action. * chore(deps) lib-jitsi-meet@latest https://github.com/jitsi/lib-jitsi-meet/compare/v1869.0.0+5671c5d6...v1872.0.0+8940b5c9
26 lines
746 B
TypeScript
26 lines
746 B
TypeScript
import MiddlewareRegistry from '../base/redux/MiddlewareRegistry';
|
|
import { showErrorNotification } from '../notifications/actions';
|
|
import { NOTIFICATION_TIMEOUT_TYPE } from '../notifications/constants';
|
|
|
|
import { TRANSCRIBER_LEFT } from './actionTypes';
|
|
|
|
/**
|
|
* Implements the middleware of the feature transcribing.
|
|
*
|
|
* @param {Store} store - The redux store.
|
|
* @returns {Function}
|
|
*/
|
|
MiddlewareRegistry.register(({ dispatch }) => next => action => {
|
|
switch (action.type) {
|
|
case TRANSCRIBER_LEFT:
|
|
if (action.abruptly) {
|
|
dispatch(showErrorNotification({
|
|
titleKey: 'transcribing.failed'
|
|
}, NOTIFICATION_TIMEOUT_TYPE.LONG));
|
|
}
|
|
break;
|
|
}
|
|
|
|
return next(action);
|
|
});
|