Move Labels to Conference

This commit is contained in:
Bettenbuk Zoltan 2019-02-05 11:10:15 +01:00 committed by Saúl Ibarra Corretgé
parent 8065cc0348
commit 46713cab3b
9 changed files with 45 additions and 60 deletions

View File

@ -28,6 +28,7 @@ import { setToolboxVisible, Toolbox } from '../../../toolbox';
import { shouldDisplayTileView } from '../../../video-layout'; import { shouldDisplayTileView } from '../../../video-layout';
import DisplayNameLabel from './DisplayNameLabel'; import DisplayNameLabel from './DisplayNameLabel';
import Labels from './Labels';
import styles from './styles'; import styles from './styles';
/** /**
@ -282,6 +283,8 @@ class Conference extends Component<Props> {
pointerEvents = 'box-none' pointerEvents = 'box-none'
style = { styles.toolboxAndFilmstripContainer }> style = { styles.toolboxAndFilmstripContainer }>
<Labels />
<Captions onPress = { this._onClick } /> <Captions onPress = { this._onClick } />
<DisplayNameLabel /> <DisplayNameLabel />

View File

@ -4,21 +4,21 @@ import React from 'react';
import { TouchableOpacity, View } from 'react-native'; import { TouchableOpacity, View } from 'react-native';
import { connect } from 'react-redux'; import { connect } from 'react-redux';
import { JitsiRecordingConstants } from '../../base/lib-jitsi-meet'; import { JitsiRecordingConstants } from '../../../base/lib-jitsi-meet';
import {
RecordingExpandedLabel
} from '../../recording';
import { import {
isNarrowAspectRatio, isNarrowAspectRatio,
makeAspectRatioAware makeAspectRatioAware
} from '../../base/responsive-ui'; } from '../../../base/responsive-ui';
import { TranscribingExpandedLabel } from '../../transcribing'; import {
import { VideoQualityExpandedLabel } from '../../video-quality'; RecordingExpandedLabel
} from '../../../recording';
import { TranscribingExpandedLabel } from '../../../transcribing';
import { VideoQualityExpandedLabel } from '../../../video-quality';
import AbstractLabels, { import AbstractLabels, {
_abstractMapStateToProps, _abstractMapStateToProps,
type Props as AbstractLabelsProps type Props as AbstractLabelsProps
} from './AbstractLabels'; } from '../AbstractLabels';
import styles from './styles'; import styles from './styles';
/** /**

View File

@ -5,6 +5,8 @@ import {
fixAndroidViewClipping fixAndroidViewClipping
} from '../../../base/styles'; } from '../../../base/styles';
import { FILMSTRIP_SIZE } from '../../../filmstrip';
/** /**
* The styles of the feature conference. * The styles of the feature conference.
*/ */
@ -32,6 +34,30 @@ export default createStyleSheet({
fontSize: 14 fontSize: 14
}, },
/**
* View that contains the indicators.
*/
indicatorContainer: {
flex: 1,
flexDirection: 'row',
justifyContent: 'flex-end',
margin: BoxModel.margin
},
/**
* Indicator container for wide aspect ratio.
*/
indicatorContainerWide: {
marginRight: FILMSTRIP_SIZE + BoxModel.margin
},
labelWrapper: {
flexDirection: 'column',
position: 'absolute',
right: 0,
top: 0
},
/** /**
* The style of the {@link View} which expands over the whole * The style of the {@link View} which expands over the whole
* {@link Conference} area and splits it between the {@link Filmstrip} and * {@link Conference} area and splits it between the {@link Filmstrip} and

View File

@ -29,6 +29,7 @@ import {
import { maybeShowSuboptimalExperienceNotification } from '../../functions'; import { maybeShowSuboptimalExperienceNotification } from '../../functions';
import Labels from './Labels';
import { default as Notice } from './Notice'; import { default as Notice } from './Notice';
declare var APP: Object; declare var APP: Object;
@ -217,8 +218,9 @@ class Conference extends Component<Props> {
onMouseMove = { this._onShowToolbar }> onMouseMove = { this._onShowToolbar }>
<Notice /> <Notice />
<div id = 'videospace'> <div id = 'videospace'>
<LargeVideo <LargeVideo />
hideVideoQualityLabel = { hideVideoQualityLabel } /> { hideVideoQualityLabel
|| <Labels /> }
<Filmstrip filmstripOnly = { filmstripOnly } /> <Filmstrip filmstripOnly = { filmstripOnly } />
</div> </div>

View File

@ -3,12 +3,12 @@
import React from 'react'; import React from 'react';
import { connect } from 'react-redux'; import { connect } from 'react-redux';
import { JitsiRecordingConstants } from '../../base/lib-jitsi-meet'; import { JitsiRecordingConstants } from '../../../base/lib-jitsi-meet';
import AbstractLabels, { import AbstractLabels, {
_abstractMapStateToProps as _mapStateToProps, _abstractMapStateToProps as _mapStateToProps,
type Props type Props
} from './AbstractLabels'; } from '../AbstractLabels';
/** /**
* The type of the React {@code Component} state of {@link Labels}. * The type of the React {@code Component} state of {@link Labels}.

View File

@ -6,7 +6,6 @@ import { connect } from 'react-redux';
import { ParticipantView } from '../../base/participants'; import { ParticipantView } from '../../base/participants';
import { DimensionsDetector } from '../../base/responsive-ui'; import { DimensionsDetector } from '../../base/responsive-ui';
import Labels from './Labels';
import styles, { AVATAR_SIZE } from './styles'; import styles, { AVATAR_SIZE } from './styles';
/** /**
@ -130,7 +129,6 @@ class LargeVideo extends Component<Props, State> {
useConnectivityInfoLabel = { useConnectivityInfoLabel } useConnectivityInfoLabel = { useConnectivityInfoLabel }
zOrder = { 0 } zOrder = { 0 }
zoomEnabled = { true } /> zoomEnabled = { true } />
<Labels />
</DimensionsDetector> </DimensionsDetector>
); );
} }

View File

@ -5,28 +5,15 @@ import React, { Component } from 'react';
import { Watermarks } from '../../base/react'; import { Watermarks } from '../../base/react';
import { Captions } from '../../subtitles/'; import { Captions } from '../../subtitles/';
import Labels from './Labels';
declare var interfaceConfig: Object; declare var interfaceConfig: Object;
/**
* The type of the React {@code Component} props of {@link LargeVideo}.
*/
type Props = {
/**
* True if the {@code VideoQualityLabel} should not be displayed.
*/
hideVideoQualityLabel: boolean
};
/** /**
* Implements a React {@link Component} which represents the large video (a.k.a. * Implements a React {@link Component} which represents the large video (a.k.a.
* the conference participant who is on the local stage) on Web/React. * the conference participant who is on the local stage) on Web/React.
* *
* @extends Component * @extends Component
*/ */
export default class LargeVideo extends Component<Props> { export default class LargeVideo extends Component<{}> {
/** /**
* Implements React's {@link Component#render()}. * Implements React's {@link Component#render()}.
* *
@ -74,8 +61,6 @@ export default class LargeVideo extends Component<Props> {
{ interfaceConfig.DISABLE_TRANSCRIPTION_SUBTITLES { interfaceConfig.DISABLE_TRANSCRIPTION_SUBTITLES
|| <Captions /> } || <Captions /> }
<span id = 'localConnectionMessage' /> <span id = 'localConnectionMessage' />
{ this.props.hideVideoQualityLabel
|| <Labels /> }
</div> </div>
); );
} }

View File

@ -1,7 +1,6 @@
import { StyleSheet } from 'react-native'; import { StyleSheet } from 'react-native';
import { BoxModel, ColorPalette, createStyleSheet } from '../../base/styles'; import { ColorPalette, createStyleSheet } from '../../base/styles';
import { FILMSTRIP_SIZE } from '../../filmstrip';
/** /**
* Size for the Avatar. * Size for the Avatar.
@ -10,34 +9,6 @@ export const AVATAR_SIZE = 200;
export default createStyleSheet({ export default createStyleSheet({
/**
* View that contains the indicators.
*/
indicatorContainer: {
flex: 1,
flexDirection: 'row',
justifyContent: 'flex-end',
margin: BoxModel.margin
},
/**
* Indicator container for wide aspect ratio.
*/
indicatorContainerWide: {
marginRight: FILMSTRIP_SIZE + BoxModel.margin
},
labelWrapper: {
flexDirection: 'column',
position: 'absolute',
right: 0,
// Both on Android and iOS there is the status bar which may be visible.
// On iPhone X there is the notch. In the two cases BoxModel.margin is
// not enough.
top: BoxModel.margin * 3
},
/** /**
* Large video container style. * Large video container style.
*/ */