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

29 lines
714 B
JavaScript
Raw Normal View History

// @flow
2019-01-30 17:19:40 +00:00
export * from './functions.any';
2017-04-01 05:52:40 +00:00
declare var interfaceConfig: Object;
/**
* Helper for getting the height of the toolbox.
*
* @returns {number} The height of the toolbox.
*/
export function getToolboxHeight() {
const toolbox = document.getElementById('new-toolbox');
return (toolbox && toolbox.clientHeight) || 0;
}
2017-07-26 20:52:41 +00:00
/**
* Indicates if a toolbar button is enabled.
*
* @param {string} name - The name of the setting section as defined in
* interface_config.js.
* @returns {boolean} - True to indicate that the given toolbar button
* is enabled, false - otherwise.
*/
export function isButtonEnabled(name: string) {
return interfaceConfig.TOOLBAR_BUTTONS.indexOf(name) !== -1;
2017-07-26 20:52:41 +00:00
}