From 00387cb1eb6e85317bc6985e6774a948e1113ac3 Mon Sep 17 00:00:00 2001 From: CJ <38697367+imisshtml@users.noreply.github.com> Date: Thu, 31 Oct 2019 11:49:18 -0400 Subject: [PATCH] Cherrypick of 3466 for release 1.25 (#3504) --- .../attachment_image/__snapshots__/index.test.js.snap | 1 - .../message_attachments/attachment_image/index.js | 1 - app/components/progressive_image/progressive_image.js | 8 +++++++- 3 files changed, 7 insertions(+), 3 deletions(-) diff --git a/app/components/message_attachments/attachment_image/__snapshots__/index.test.js.snap b/app/components/message_attachments/attachment_image/__snapshots__/index.test.js.snap index 75cf22a00..c941946d9 100644 --- a/app/components/message_attachments/attachment_image/__snapshots__/index.test.js.snap +++ b/app/components/message_attachments/attachment_image/__snapshots__/index.test.js.snap @@ -23,7 +23,6 @@ exports[`AttachmentImage it matches snapshot 1`] = ` "borderRadius": 2, "borderWidth": 1, "flex": 1, - "padding": 5, }, Object { "height": 28, diff --git a/app/components/message_attachments/attachment_image/index.js b/app/components/message_attachments/attachment_image/index.js index 6948c3206..f102584f7 100644 --- a/app/components/message_attachments/attachment_image/index.js +++ b/app/components/message_attachments/attachment_image/index.js @@ -169,7 +169,6 @@ const getStyleSheet = makeStyleSheetFromTheme((theme) => { borderWidth: 1, borderRadius: 2, flex: 1, - padding: 5, }, }; }); diff --git a/app/components/progressive_image/progressive_image.js b/app/components/progressive_image/progressive_image.js index 6bc2a40a1..6c6d3976b 100644 --- a/app/components/progressive_image/progressive_image.js +++ b/app/components/progressive_image/progressive_image.js @@ -171,7 +171,7 @@ export default class ProgressiveImage extends PureComponent { resizeMethod={resizeMethod} onError={onError} source={{uri}} - style={this.computedStyle} + style={[this.computedStyle, styles.attachmentMargin]} > {this.props.children} @@ -193,4 +193,10 @@ const styles = StyleSheet.create({ alignItems: 'center', justifyContent: 'center', }, + attachmentMargin: { + marginTop: 2.5, + marginLeft: 2.5, + marginBottom: 5, + marginRight: 5, + }, });