From e454f402e9ba758fcd139c142f5e43c3004f022c Mon Sep 17 00:00:00 2001 From: Alex Gleason Date: Thu, 14 Oct 2021 08:49:33 -0500 Subject: [PATCH] Status: conditional column title depending on visibility scope --- app/soapbox/features/status/index.js | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/app/soapbox/features/status/index.js b/app/soapbox/features/status/index.js index 8b42ad279..27049b79e 100644 --- a/app/soapbox/features/status/index.js +++ b/app/soapbox/features/status/index.js @@ -55,6 +55,7 @@ import { launchChat } from 'soapbox/actions/chats'; const messages = defineMessages({ title: { id: 'status.title', defaultMessage: 'Post' }, + titleDirect: { id: 'status.title_direct', defaultMessage: 'Direct message' }, deleteConfirm: { id: 'confirmations.delete.confirm', defaultMessage: 'Delete' }, deleteMessage: { id: 'confirmations.delete.message', defaultMessage: 'Are you sure you want to delete this post?' }, redraftConfirm: { id: 'confirmations.redraft.confirm', defaultMessage: 'Delete & redraft' }, @@ -596,9 +597,11 @@ class Status extends ImmutablePureComponent { react: this.handleHotkeyReact, }; + const titleMessage = status && status.get('visibility') === 'direct' ? messages.titleDirect : messages.title; + return ( - + {/* Eye icon to show/hide all CWs in a thread. I'm not convinced of the value of this. It needs a better design at the very least.