import React from 'react';
import { View, Text } from 'react-native';
/**
* Component used on dashboard to label date, volume and product with color.
* @param {properties} props Component properties.
*
* @component
* @memberof module:Components
* @example
* <ColoredLabel
* containerStyle={styles.containerStyle}
* textStyle={styles.textStyle}
* labelText={'Example text'}
* />
*
* const styles = StyleSheet.create({
* containerStyle : {
width: 82,
backgroundColor: 'blue',
justifyContent: 'center',
alignItems: 'center',
padding: 5,
borderRadius: 5
},
textStyle = {
textAlign: 'center',
fontFamily: 'MuseoSansRounded-700'
}
* })
*/
const ColoredLabel = props => {
const { containerStyle, textStyle, labelText } = props;
return (
<View style={containerStyle}>
<Text style={textStyle}>{labelText}</Text>
</View>
);
};
export default ColoredLabel;