From 6374358357ee81b5f137f471f028a56974109155 Mon Sep 17 00:00:00 2001 From: Claire Date: Fri, 29 Dec 2023 17:34:13 +0100 Subject: [PATCH] Change media to be hidden/blurred by default in report modal (#28522) --- app/javascript/mastodon/components/media_attachments.jsx | 5 ++++- .../mastodon/features/report/components/status_check_box.jsx | 2 +- 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/app/javascript/mastodon/components/media_attachments.jsx b/app/javascript/mastodon/components/media_attachments.jsx index 7b945a0ea2..63fe3e67f9 100644 --- a/app/javascript/mastodon/components/media_attachments.jsx +++ b/app/javascript/mastodon/components/media_attachments.jsx @@ -15,6 +15,7 @@ export default class MediaAttachments extends ImmutablePureComponent { lang: PropTypes.string, height: PropTypes.number, width: PropTypes.number, + visible: PropTypes.bool, }; static defaultProps = { @@ -51,7 +52,7 @@ export default class MediaAttachments extends ImmutablePureComponent { }; render () { - const { status, width, height } = this.props; + const { status, width, height, visible } = this.props; const mediaAttachments = status.get('media_attachments'); const language = status.getIn(['language', 'translation']) || status.get('language') || this.props.lang; @@ -99,6 +100,7 @@ export default class MediaAttachments extends ImmutablePureComponent { height={height} inline sensitive={status.get('sensitive')} + visible={visible} onOpenVideo={noop} /> )} @@ -113,6 +115,7 @@ export default class MediaAttachments extends ImmutablePureComponent { lang={language} sensitive={status.get('sensitive')} defaultWidth={width} + visible={visible} height={height} onOpenMedia={noop} /> diff --git a/app/javascript/mastodon/features/report/components/status_check_box.jsx b/app/javascript/mastodon/features/report/components/status_check_box.jsx index 8bee76e591..481ee3e5ed 100644 --- a/app/javascript/mastodon/features/report/components/status_check_box.jsx +++ b/app/javascript/mastodon/features/report/components/status_check_box.jsx @@ -47,7 +47,7 @@ class StatusCheckBox extends PureComponent { - + );