aboutsummaryrefslogtreecommitdiff
path: root/src/components/moments/CaptionScreenHeader.tsx
blob: 0638c1283b176a5bc1724a260f7dbaf9d26dedb8 (plain)
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
import React from 'react';
import {Text, View, StyleSheet, ViewProps} from 'react-native';
interface CaptionScreenHeaderProps extends ViewProps {
  title: string;
}
const CaptionScreenHeader: React.FC<CaptionScreenHeaderProps> = ({
  title,
  style,
}) => {
  return (
    <View style={[styles.container, style]}>
      <View style={styles.headerContainer}>
        <Text style={styles.header}>{title}</Text>
      </View>
    </View>
  );
};

const styles = StyleSheet.create({
  container: {
    flexDirection: 'row',
    justifyContent: 'center',
    alignItems: 'center',
  },
  headerContainer: {
    width: '90%',
  },
  header: {
    fontSize: 20,
    fontWeight: 'bold',
    color: 'white',
    textAlign: 'center',
  },
});
export default CaptionScreenHeader;