MessageListCellHeader.js 1.03 KB
'use strict';

import React, {Component} from 'react';
import ReactNative, {
    View,
    Text,
    StyleSheet,
    Dimensions,
    Platform,
} from 'react-native';

export default class MessageListCellHeader extends Component {
    constructor(props) {
        super(props);
    }

    render(){
        return(
            <View style={styles.container}>
                <Text style={styles.textStyle}>
                    {this.props.timestamp}
                </Text>
                <View style={styles.separator}/>
            </View>
        )
    }
}

let {width,height} = Dimensions.get('window');

let styles = StyleSheet.create({
    container: {
        flexDirection: 'column',
        width,
        height: 40,
        backgroundColor: '#f2f2f2',
    },
    textStyle: {
        fontSize: 13,
        backgroundColor: 'transparent',
        color: '#b0b0b0',
        textAlign: 'center',
        marginTop: 13
    },
    separator: {
        marginTop: 10.5,
        backgroundColor: '#e0e0e0',
        width,
        height: 0.5,
    }
})