import {useNavigation} from '@react-navigation/core'; import React from 'react'; import {StyleSheet, Text} from 'react-native'; import {TouchableOpacity} from 'react-native-gesture-handler'; import CommentsIcon from '../../assets/icons/moment-comment-icon.svg'; import {MomentPostType, ScreenType} from '../../types'; import {normalize} from '../../utils'; interface CommentsCountProps { moment: MomentPostType; screenType: ScreenType; } const CommentsCount: React.FC = ({moment, screenType}) => { const navigation = useNavigation(); return ( navigation.navigate('MomentCommentsScreen', { moment_id: moment.moment_id, screenType, }) }> {moment.comments_count} ); }; const styles = StyleSheet.create({ countContainer: { minWidth: 50, flexDirection: 'column', justifyContent: 'center', alignItems: 'center', }, count: { fontWeight: '500', fontSize: normalize(11), lineHeight: normalize(13), letterSpacing: normalize(0.05), textAlign: 'center', color: 'white', marginTop: normalize(5), }, }); export default CommentsCount;