1
0
mirror of https://github.com/matrix-org/matrix-react-sdk.git synced 2025-11-07 10:46:24 +03:00

Only show download link below media if it's not in the timeline

This commit is contained in:
Travis Ralston
2021-07-16 11:05:04 -06:00
parent 7ba0adba77
commit 623f2e7613
5 changed files with 33 additions and 45 deletions

View File

@@ -415,7 +415,10 @@ export default class MImageBody extends React.Component<IBodyProps, IState> {
// Overidden by MStickerBody
protected getFileBody(): JSX.Element {
return <MFileBody {...this.props} decryptedBlob={this.state.decryptedBlob} showGenericPlaceholder={false} />;
// We only ever need the download bar if we're appearing outside of the timeline
if (this.props.tileShape) {
return <MFileBody {...this.props} showGenericPlaceholder={false} />;
}
}
render() {