From 047c7da12fd10c4fcd8bacc1c9ecd7ac0f11853b Mon Sep 17 00:00:00 2001 From: Sebastian Webster Date: Fri, 23 Sep 2022 16:04:11 +1200 Subject: [PATCH] center edit text for image and text posts --- frontend/src/components/ImagePost.js | 2 +- frontend/src/components/TextPost.js | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/frontend/src/components/ImagePost.js b/frontend/src/components/ImagePost.js index f459e64..8fa523c 100644 --- a/frontend/src/components/ImagePost.js +++ b/frontend/src/components/ImagePost.js @@ -139,7 +139,7 @@ const ImagePost = ({title, body, datePosted, image, previewImage, liked, publicI

{profileName}

{(edited || typeof editNumber === 'number') &&
disableFunctionality ? null : navigate(`/historyviewer/${postId}/image`)}> -

{typeof editNumber === 'number' ? editNumber === 0 ? 'Original Post' : `Edit #${editNumber}` : `Edited ${timesEdited} ${timesEdited === 1 ? 'time' : 'times'}`}

+

{typeof editNumber === 'number' ? editNumber === 0 ? 'Original Post' : `Edit #${editNumber}` : `Edited ${timesEdited} ${timesEdited === 1 ? 'time' : 'times'}`}

} diff --git a/frontend/src/components/TextPost.js b/frontend/src/components/TextPost.js index ab90bb7..7bdbba7 100644 --- a/frontend/src/components/TextPost.js +++ b/frontend/src/components/TextPost.js @@ -142,7 +142,7 @@ const TextPost = ({title, body, datePosted, liked, publicId, postId, dispatch, u

{profileName}

{(edited || typeof editNumber === 'number') &&
disableFunctionality ? null : navigate(`/historyviewer/${postId}/text`)}> -

{typeof editNumber === 'number' ? editNumber === 0 ? 'Original Post' : `Edit #${editNumber}` : `Edited ${timesEdited} ${timesEdited === 1 ? 'time' : 'times'}`}

+

{typeof editNumber === 'number' ? editNumber === 0 ? 'Original Post' : `Edit #${editNumber}` : `Edited ${timesEdited} ${timesEdited === 1 ? 'time' : 'times'}`}

}