diff options
author | Claire <claire.github-309c@sitedethib.com> | 2022-07-24 20:01:30 +0200 |
---|---|---|
committer | Claire <claire.github-309c@sitedethib.com> | 2022-07-25 11:57:09 +0200 |
commit | 18346f40443f1c01b45d94be1b0edce20b2c27be (patch) | |
tree | b78b33927842f5dfd374fa5fb9509a809849e358 /app/javascript/flavours/glitch/containers | |
parent | eacde1a130a5764686a284d610890ba0f60b193e (diff) |
Add option to share CW toggle state across instances of a post
Diffstat (limited to 'app/javascript/flavours/glitch/containers')
-rw-r--r-- | app/javascript/flavours/glitch/containers/status_container.js | 17 |
1 files changed, 16 insertions, 1 deletions
diff --git a/app/javascript/flavours/glitch/containers/status_container.js b/app/javascript/flavours/glitch/containers/status_container.js index 358b89ab9..6c8f261e4 100644 --- a/app/javascript/flavours/glitch/containers/status_container.js +++ b/app/javascript/flavours/glitch/containers/status_container.js @@ -17,7 +17,14 @@ import { pin, unpin, } from 'flavours/glitch/actions/interactions'; -import { muteStatus, unmuteStatus, deleteStatus, editStatus } from 'flavours/glitch/actions/statuses'; +import { + muteStatus, + unmuteStatus, + deleteStatus, + hideStatus, + revealStatus, + editStatus +} from 'flavours/glitch/actions/statuses'; import { initMuteModal } from 'flavours/glitch/actions/mutes'; import { initBlockModal } from 'flavours/glitch/actions/blocks'; import { initReport } from 'flavours/glitch/actions/reports'; @@ -252,6 +259,14 @@ const mapDispatchToProps = (dispatch, { intl, contextType }) => ({ } }, + onToggleHidden (status) { + if (status.get('hidden')) { + dispatch(revealStatus(status.get('id'))); + } else { + dispatch(hideStatus(status.get('id'))); + } + }, + deployPictureInPicture (status, type, mediaProps) { dispatch((_, getState) => { if (getState().getIn(['local_settings', 'media', 'pop_in_player'])) { |