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';
|
2017-05-16 23:37:17 +08:00
|
|
|
import SettingsDropdown from './component';
|
2019-01-15 05:39:03 +08:00
|
|
|
import { toggleFullScreen } from './service';
|
2017-05-16 23:37:17 +08:00
|
|
|
|
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 result = browser();
|
|
|
|
const isAndroid = (result && result.os) ? result.os.includes('Android') : false;
|
|
|
|
return {
|
|
|
|
amIModerator: props.amIModerator,
|
|
|
|
handleToggleFullscreen,
|
|
|
|
isAndroid,
|
|
|
|
isFullScreen,
|
|
|
|
};
|
|
|
|
})(SettingsDropdownContainer);
|