jiti-meet/react/features/toolbox/functions.native.js

18 lines
474 B
JavaScript
Raw Normal View History

2019-01-30 17:19:40 +00:00
// @flow
2019-03-12 17:45:53 +00:00
import { toState } from '../base/redux';
/**
* Returns true if the toolbox is visible.
*
* @param {Object | Function} stateful - A function or object that can be
* resolved to Redux state by the function {@code toState}.
* @returns {boolean}
*/
export function isToolboxVisible(stateful: Object | Function) {
const { alwaysVisible, enabled, visible }
= toState(stateful)['features/toolbox'];
return enabled && (alwaysVisible || visible);
}