jiti-meet/react/features/toolbar/components/styles.js

145 lines
2.7 KiB
JavaScript
Raw Normal View History

2016-12-12 19:49:23 +00:00
import { BoxModel, ColorPalette, createStyleSheet } from '../../base/styles';
/**
2016-12-12 19:49:23 +00:00
* The base style for (toolbar) buttons.
*
* @type {Object}
*/
const button = {
borderRadius: 30,
borderWidth: 0,
2016-12-12 19:49:23 +00:00
flex: 0,
flexDirection: 'row',
height: 60,
justifyContent: 'center',
2016-12-12 19:49:23 +00:00
margin: BoxModel.margin,
width: 60
};
/**
* Small toolbar button.
*
* @type {{borderRadius: number, flex: number, flexDirection: string,
* height: number, justifyContent: string, margin: number, width: number}}
*/
const smallButton = {
borderRadius: 15,
flex: 0,
flexDirection: 'column',
height: 30,
justifyContent: 'center',
margin: BoxModel.margin / 2,
width: 30
};
/**
2016-12-12 19:49:23 +00:00
* The base style for icons.
*
* @type {Object}
*/
2016-12-12 19:49:23 +00:00
const icon = {
alignSelf: 'center',
color: ColorPalette.darkGrey,
fontSize: 24
};
/**
* Small toolbar button icon.
*
* @type {{fontSize: number}}
*/
const smallIcon = {
...icon,
fontSize: 16
};
/**
2016-12-12 19:49:23 +00:00
* The base style for toolbars.
*
* @type {Object}
*/
2016-12-12 19:49:23 +00:00
const toolbar = {
flex: 1,
position: 'absolute'
};
/**
* The (conference) toolbar related styles.
*/
export const styles = createStyleSheet({
/**
* The toolbar button icon style.
*/
2016-12-12 19:49:23 +00:00
icon,
/**
* The style of the toolbar which contains the primary buttons such as
* hangup, audio and video mute.
*/
primaryToolbar: {
2016-12-12 19:49:23 +00:00
...toolbar,
bottom: 3 * BoxModel.margin,
flexDirection: 'row',
justifyContent: 'center',
left: 0,
right: 0
},
/**
2016-12-12 19:49:23 +00:00
* The style of button in primaryToolbar.
*/
2016-12-12 19:49:23 +00:00
primaryToolbarButton: {
...button,
backgroundColor: ColorPalette.white,
opacity: 0.7
},
/**
2016-12-12 19:49:23 +00:00
* The style of the toolbar which contains the secondary buttons such as
* toggle camera facing mode.
*/
2016-12-12 19:49:23 +00:00
secondaryToolbar: {
...toolbar,
bottom: 0,
flexDirection: 'column',
right: BoxModel.margin,
top: BoxModel.margin * 2
},
/**
2016-12-12 19:49:23 +00:00
* The style of button in secondaryToolbar.
*/
2016-12-12 19:49:23 +00:00
secondaryToolbarButton: {
...smallButton,
backgroundColor: ColorPalette.darkGrey,
opacity: 0.7
},
/**
2016-12-12 19:49:23 +00:00
* The style of the root/top-level Container of Toolbar.
*/
toolbarContainer: {
bottom: 0,
2016-12-12 19:49:23 +00:00
left: 0,
position: 'absolute',
right: 0,
top: 0
},
/**
* The toolbar white button icon style.
*/
whiteIcon: {
...icon,
color: ColorPalette.white
},
/**
* The secondary toolbar icon style.
*/
secondaryToolbarIcon: {
...smallIcon,
color: ColorPalette.white
}
});