bigbluebutton-Github/bigbluebutton-html5/imports/ui/components/nav-bar/settings-dropdown/container.jsx

24 lines
763 B
React
Raw Normal View History

2019-03-12 00:21:12 +08:00
import React from 'react';
import { withTracker } from 'meteor/react-meteor-data';
2018-06-22 00:19:42 +08:00
import browser from 'browser-detect';
import SettingsDropdown from './component';
import { toggleFullScreen } from './service';
2019-03-12 00:21:12 +08:00
const SettingsDropdownContainer = props => (
<SettingsDropdown {...props} />
);
export default withTracker((props) => {
const isFullscreen = Session.get('isFullscreen');
const handleToggleFullscreen = () => toggleFullScreen();
const BROWSER_RESULTS = browser();
const isSafari = BROWSER_RESULTS.name === 'safari';
const noIOSFullscreen = isSafari && BROWSER_RESULTS.versionNumber < 12;
2019-03-12 00:21:12 +08:00
return {
amIModerator: props.amIModerator,
handleToggleFullscreen,
isFullscreen,
noIOSFullscreen,
2019-03-12 00:21:12 +08:00
};
})(SettingsDropdownContainer);