diff --git a/android/app/build.gradle b/android/app/build.gradle index 2de5375ff417..fd2e008b9207 100644 --- a/android/app/build.gradle +++ b/android/app/build.gradle @@ -148,8 +148,8 @@ android { minSdkVersion rootProject.ext.minSdkVersion targetSdkVersion rootProject.ext.targetSdkVersion multiDexEnabled rootProject.ext.multiDexEnabled - versionCode 1001005203 - versionName "1.0.52-3" + versionCode 1001005204 + versionName "1.0.52-4" } splits { abi { diff --git a/ios/ExpensifyCash/Info.plist b/ios/ExpensifyCash/Info.plist index 8c2a77a3ce52..44876fea8d3e 100644 --- a/ios/ExpensifyCash/Info.plist +++ b/ios/ExpensifyCash/Info.plist @@ -30,7 +30,7 @@ CFBundleVersion - 1.0.52.3 + 1.0.52.4 ITSAppUsesNonExemptEncryption LSApplicationQueriesSchemes diff --git a/ios/ExpensifyCashTests/Info.plist b/ios/ExpensifyCashTests/Info.plist index 868555e91380..6a06351bbe58 100644 --- a/ios/ExpensifyCashTests/Info.plist +++ b/ios/ExpensifyCashTests/Info.plist @@ -19,6 +19,6 @@ CFBundleSignature ???? CFBundleVersion - 1.0.52.3 + 1.0.52.4 diff --git a/package-lock.json b/package-lock.json index 33403ea2c20b..3e42849cc7e7 100644 --- a/package-lock.json +++ b/package-lock.json @@ -1,6 +1,6 @@ { "name": "expensify.cash", - "version": "1.0.52-3", + "version": "1.0.52-4", "lockfileVersion": 1, "requires": true, "dependencies": { diff --git a/package.json b/package.json index 10dd13e91951..b00b6d02fe3e 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "expensify.cash", - "version": "1.0.52-3", + "version": "1.0.52-4", "author": "Expensify, Inc.", "homepage": "https://expensify.cash", "description": "Expensify.cash is the next generation of Expensify: a reimagination of payments based atop a foundation of chat.", diff --git a/src/components/RenderHTML.js b/src/components/RenderHTML.js index 38214a6582d7..47285b543814 100755 --- a/src/components/RenderHTML.js +++ b/src/components/RenderHTML.js @@ -1,4 +1,5 @@ /* eslint-disable react/prop-types */ +import _ from 'underscore'; import React from 'react'; import PropTypes from 'prop-types'; import {useWindowDimensions, TouchableOpacity} from 'react-native'; @@ -14,6 +15,9 @@ import AnchorForCommentsOnly from './AnchorForCommentsOnly'; import InlineCodeBlock from './InlineCodeBlock'; import AttachmentModal from './AttachmentModal'; import ThumbnailImage from './ThumbnailImage'; +import variables from '../styles/variables'; +import themeColors from '../styles/themes/default'; +import Text from './Text'; const MAX_IMG_DIMENSIONS = 512; @@ -96,6 +100,22 @@ function CodeRenderer({ ); } +function EditedRenderer(props) { + const defaultRendererProps = _.omit(props, ['TDefaultRenderer', 'style', 'tnode']); + return ( + + {/* Native devices do not support margin between nested text */} + {' '} + (edited) + + ); +} + function ImgRenderer({tnode}) { const htmlAttribs = tnode.attributes; @@ -158,12 +178,14 @@ function ImgRenderer({tnode}) { AnchorRenderer.model = defaultHTMLElementModels.a; CodeRenderer.model = defaultHTMLElementModels.code; ImgRenderer.model = defaultHTMLElementModels.img; +EditedRenderer.model = defaultHTMLElementModels.span; // Define the custom render methods const renderers = { a: AnchorRenderer, code: CodeRenderer, img: ImgRenderer, + edited: EditedRenderer, }; const propTypes = { diff --git a/src/libs/actions/Report.js b/src/libs/actions/Report.js index 3fb0c7f4f48c..d1ac76807193 100644 --- a/src/libs/actions/Report.js +++ b/src/libs/actions/Report.js @@ -488,6 +488,13 @@ function updateReportActionMessage(reportID, sequenceNumber, message) { const actionToMerge = {}; actionToMerge[sequenceNumber] = {message: [message]}; Onyx.merge(`${ONYXKEYS.COLLECTION.REPORT_ACTIONS}${reportID}`, actionToMerge); + + // If this is the most recent message, update the lastMessageText in the report object as well + if (sequenceNumber === reportMaxSequenceNumbers[reportID]) { + Onyx.merge(`${ONYXKEYS.COLLECTION.REPORT}${reportID}`, { + lastMessageText: message.html, + }); + } } /** diff --git a/src/pages/home/report/ReportActionItemFragment.js b/src/pages/home/report/ReportActionItemFragment.js index 3763ddefcceb..165b4b649e61 100644 --- a/src/pages/home/report/ReportActionItemFragment.js +++ b/src/pages/home/report/ReportActionItemFragment.js @@ -49,24 +49,27 @@ class ReportActionItemFragment extends React.PureComponent { } // Only render HTML if we have html in the fragment - return ( - - {fragment.html !== fragment.text ? ( - - ) : ( - {Str.htmlDecode(fragment.text)} - )} - {fragment.isEdited && ( + return fragment.html !== fragment.text + ? ( + ' : '')} + debug={false} + /> + ) : ( + + {Str.htmlDecode(fragment.text)} + {fragment.isEdited && ( + {/* Native devices do not support margin between nested text */} + {' '} (edited) - )} - - ); + )} + + ); case 'TEXT': return ( diff --git a/src/styles/utilities/sizing.js b/src/styles/utilities/sizing.js index 67bba032ecc3..169aba760e03 100644 --- a/src/styles/utilities/sizing.js +++ b/src/styles/utilities/sizing.js @@ -19,4 +19,8 @@ export default { mwn: { maxWidth: 'auto', }, + + w1: { + width: 4, + }, };