|
@@ -32,6 +32,11 @@ export interface IProps extends WithTranslation {
|
32
|
32
|
*/
|
33
|
33
|
_conference?: IJitsiConference;
|
34
|
34
|
|
|
35
|
+ /**
|
|
36
|
+ * Whether subtitles should be displayed or not.
|
|
37
|
+ */
|
|
38
|
+ _displaySubtitles?: boolean;
|
|
39
|
+
|
35
|
40
|
/**
|
36
|
41
|
* Whether to show file recordings service, even if integrations
|
37
|
42
|
* are enabled.
|
|
@@ -69,6 +74,11 @@ export interface IProps extends WithTranslation {
|
69
|
74
|
*/
|
70
|
75
|
_screenshotCaptureEnabled: boolean;
|
71
|
76
|
|
|
77
|
+ /**
|
|
78
|
+ * The selected language for subtitles.
|
|
79
|
+ */
|
|
80
|
+ _subtitlesLanguage: string | null;
|
|
81
|
+
|
72
|
82
|
/**
|
73
|
83
|
* The dropbox access token.
|
74
|
84
|
*/
|
|
@@ -336,8 +346,10 @@ class AbstractStartRecordingDialog extends Component<IProps, IState> {
|
336
|
346
|
const {
|
337
|
347
|
_appKey,
|
338
|
348
|
_conference,
|
|
349
|
+ _displaySubtitles,
|
339
|
350
|
_isDropboxEnabled,
|
340
|
351
|
_rToken,
|
|
352
|
+ _subtitlesLanguage,
|
341
|
353
|
_token,
|
342
|
354
|
dispatch
|
343
|
355
|
} = this.props;
|
|
@@ -399,7 +411,7 @@ class AbstractStartRecordingDialog extends Component<IProps, IState> {
|
399
|
411
|
|
400
|
412
|
if (this.state.selectedRecordingService === RECORDING_TYPES.JITSI_REC_SERVICE
|
401
|
413
|
&& this.state.shouldRecordTranscription) {
|
402
|
|
- dispatch(setRequestingSubtitles(true, false, null));
|
|
414
|
+ dispatch(setRequestingSubtitles(true, _displaySubtitles, _subtitlesLanguage));
|
403
|
415
|
}
|
404
|
416
|
|
405
|
417
|
_conference?.getMetadataHandler().setMetadata(RECORDING_METADATA_ID, {
|
|
@@ -434,17 +446,7 @@ class AbstractStartRecordingDialog extends Component<IProps, IState> {
|
434
|
446
|
* @param {Object} state - The Redux state.
|
435
|
447
|
* @param {any} _ownProps - Component's own props.
|
436
|
448
|
* @private
|
437
|
|
- * @returns {{
|
438
|
|
- * _appKey: string,
|
439
|
|
- * _autoTranscribeOnRecord: boolean,
|
440
|
|
- * _conference: JitsiConference,
|
441
|
|
- * _fileRecordingsServiceEnabled: boolean,
|
442
|
|
- * _fileRecordingsServiceSharingEnabled: boolean,
|
443
|
|
- * _isDropboxEnabled: boolean,
|
444
|
|
- * _rToken:string,
|
445
|
|
- * _tokenExpireDate: number,
|
446
|
|
- * _token: string
|
447
|
|
- * }}
|
|
449
|
+ * @returns {IProps}
|
448
|
450
|
*/
|
449
|
451
|
export function mapStateToProps(state: IReduxState, _ownProps: any) {
|
450
|
452
|
const {
|
|
@@ -452,16 +454,22 @@ export function mapStateToProps(state: IReduxState, _ownProps: any) {
|
452
|
454
|
dropbox = { appKey: undefined },
|
453
|
455
|
localRecording
|
454
|
456
|
} = state['features/base/config'];
|
|
457
|
+ const {
|
|
458
|
+ _displaySubtitles,
|
|
459
|
+ _language: _subtitlesLanguage
|
|
460
|
+ } = state['features/subtitles'];
|
455
|
461
|
|
456
|
462
|
return {
|
457
|
463
|
_appKey: dropbox.appKey ?? '',
|
458
|
464
|
_autoTranscribeOnRecord: shouldAutoTranscribeOnRecord(state),
|
459
|
465
|
_conference: state['features/base/conference'].conference,
|
|
466
|
+ _displaySubtitles,
|
460
|
467
|
_fileRecordingsServiceEnabled: recordingService?.enabled ?? false,
|
461
|
468
|
_fileRecordingsServiceSharingEnabled: isRecordingSharingEnabled(state),
|
462
|
469
|
_isDropboxEnabled: isDropboxEnabled(state),
|
463
|
470
|
_localRecordingEnabled: !localRecording?.disable,
|
464
|
471
|
_rToken: state['features/dropbox'].rToken ?? '',
|
|
472
|
+ _subtitlesLanguage,
|
465
|
473
|
_tokenExpireDate: state['features/dropbox'].expireDate,
|
466
|
474
|
_token: state['features/dropbox'].token ?? ''
|
467
|
475
|
};
|