Rocket.Chat.ReactNative/app/containers/message/Components/RightIcons/Translated.tsx

24 lines
578 B
TypeScript

import React, { memo } from 'react';
import { View } from 'react-native';
import { CustomIcon } from '../../../CustomIcon';
import { useTheme } from '../../../../theme';
import { themes } from '../../../../lib/constants';
import styles from '../../styles';
const Translated = memo(({ isTranslated }: { isTranslated: boolean }) => {
const { theme } = useTheme();
if (!isTranslated) {
return null;
}
return (
<View style={styles.rightIcons}>
<CustomIcon name='language' size={16} color={themes[theme].auxiliaryText} />
</View>
);
});
export default Translated;