bigbluebutton-Github/bigbluebutton-html5/imports/ui/components/video-provider/container.jsx
Vitor Mateus De Almeida ae29ba58c1 Fixes
2020-07-20 16:17:40 -03:00

17 lines
629 B
JavaScript
Executable File

import React from 'react';
import { withTracker } from 'meteor/react-meteor-data';
import VideoProvider from './component';
import VideoService from './service';
import { withLayoutContext } from '/imports/ui/components/layout/context';
const VideoProviderContainer = ({ children, ...props }) => {
const { streams } = props;
return (!streams.length ? null : <VideoProvider {...props}>{children}</VideoProvider>);
};
export default withTracker(props => ({
swapLayout: props.swapLayout,
streams: VideoService.getVideoStreams(),
isUserLocked: VideoService.isUserLocked(),
}))(withLayoutContext(VideoProviderContainer));