diff --git a/app/containers/MessageBox/ReplyPreview.js b/app/containers/MessageBox/ReplyPreview.js index e1fcbcca79e..ebf2dc5d881 100644 --- a/app/containers/MessageBox/ReplyPreview.js +++ b/app/containers/MessageBox/ReplyPreview.js @@ -1,10 +1,11 @@ import React from 'react'; -import { View, Text, StyleSheet } from 'react-native'; +import { + View, Text, StyleSheet, Image +} from 'react-native'; import PropTypes from 'prop-types'; import moment from 'moment'; import { connect } from 'react-redux'; import isEqual from 'lodash/isEqual'; - import Markdown from '../markdown'; import { CustomIcon } from '../../lib/Icons'; import sharedStyles from '../../views/Styles'; @@ -32,13 +33,48 @@ const styles = StyleSheet.create({ }, time: { fontSize: 12, - lineHeight: 16, + lineHeight: 20, marginLeft: 6, ...sharedStyles.textRegular, fontWeight: '300' }, close: { marginRight: 10 + }, + thumbnail: { + marginLeft: 'auto', + width: 38, + height: 38 + }, + text: { + flex: 1, + flexDirection: 'column', + paddingRight: 5 + }, + details: { + flexDirection: 'row' + }, + buttonVideo: { + height: 38, + width: 38, + backgroundColor: '#1f2329', + alignItems: 'center', + justifyContent: 'center', + marginLeft: 'auto' + }, + buttonAudio: { + height: 38, + width: 38, + backgroundColor: '#f7f8fa', + alignItems: 'center', + justifyContent: 'center', + marginLeft: 'auto' + }, + playVideo: { + color: '#f7f8fa' + }, + playAudio: { + color: '#1D74F5' } }); @@ -48,8 +84,8 @@ const ReplyPreview = React.memo(({ if (!replying) { return null; } - const time = moment(message.ts).format(Message_TimeFormat); + const description = (message.msg === '') ? message.attachments[0].description : message.msg; return ( {time} + ); diff --git a/app/containers/message/Reply.js b/app/containers/message/Reply.js index fba4c0fbda8..e46e9aae13c 100644 --- a/app/containers/message/Reply.js +++ b/app/containers/message/Reply.js @@ -3,13 +3,13 @@ import { View, Text, StyleSheet } from 'react-native'; import PropTypes from 'prop-types'; import moment from 'moment'; import isEqual from 'deep-equal'; - import Touchable from './Touchable'; import Markdown from '../markdown'; import openLink from '../../utils/openLink'; import sharedStyles from '../../views/Styles'; import { themes } from '../../constants/colors'; import MessageContext from './Context'; +import Attachments from './Attachments'; const styles = StyleSheet.create({ button: { @@ -177,6 +177,10 @@ const Reply = React.memo(({ theme={theme} /> +