1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
|
import * as React from 'react';
import {Alert, StyleSheet, View} from 'react-native';
import {Text} from 'react-native-animatable';
import {TouchableOpacity} from 'react-native-gesture-handler';
import {normalize} from '../../utils';
type MessagesHeaderProps = {};
const MessagesHeader: React.FC<MessagesHeaderProps> = () => {
return (
<View style={styles.header}>
<Text style={styles.headerText}>Messages</Text>
<Text style={styles.unreadText}>2 unread</Text>
<View style={styles.flex} />
<TouchableOpacity
style={styles.compose}
onPress={() => {
Alert.alert('hi');
}}>
<Text>Compose</Text>
</TouchableOpacity>
</View>
);
};
const styles = StyleSheet.create({
flex: {
flex: 1,
},
header: {
marginHorizontal: '8%',
marginTop: '5%',
alignItems: 'center',
flexDirection: 'row',
},
headerText: {
fontWeight: '700',
fontSize: normalize(18),
lineHeight: normalize(21),
},
unreadText: {
color: '#8F01FF',
marginLeft: 10,
fontWeight: '700',
lineHeight: normalize(17),
fontSize: normalize(14),
},
compose: {},
});
export default MessagesHeader;
|