1
0
mirror of https://github.com/tooot-app/app synced 2025-06-05 22:19:13 +02:00

Dimming images for dark mode

This commit is contained in:
xmflsct
2023-01-29 17:28:49 +01:00
parent e447a91cfb
commit 752d33d5b3
11 changed files with 23 additions and 13 deletions

View File

@ -83,11 +83,9 @@ const AttachmentAudio: React.FC<Props> = ({ total, index, sensitiveShown, audio
<>
{audio.preview_url ? (
<GracefullyImage
uri={{
original: audio.preview_url,
remote: audio.preview_remote_url
}}
uri={{ original: audio.preview_url, remote: audio.preview_remote_url }}
style={styles.background}
dim
/>
) : null}
<Button

View File

@ -39,6 +39,7 @@ const AttachmentImage = ({
blurhash={image.blurhash}
onPress={() => navigateToImagesViewer(image.id)}
style={{ aspectRatio: aspectRatio({ total, index, ...image.meta?.original }) }}
dim
/>
</View>
<AttachmentAltText sensitiveShown={sensitiveShown} text={image.description} />

View File

@ -31,8 +31,7 @@ const TimelineAvatar: React.FC<Props> = ({ account }) => {
})
})}
onPress={() =>
!disableOnPress &&
navigation.push('Tab-Shared-Account', { account: actualAccount })
!disableOnPress && navigation.push('Tab-Shared-Account', { account: actualAccount })
}
uri={{ original: actualAccount.avatar, static: actualAccount.avatar_static }}
dimension={
@ -51,6 +50,7 @@ const TimelineAvatar: React.FC<Props> = ({ account }) => {
overflow: 'hidden',
marginRight: StyleConstants.Spacing.S
}}
dim
/>
)
}

View File

@ -86,6 +86,7 @@ const TimelineCard: React.FC = () => {
blurhash={status.card.blurhash}
style={{ flexBasis: StyleConstants.Font.LineHeight.M * 5 }}
imageStyle={{ borderTopLeftRadius: 6, borderBottomLeftRadius: 6 }}
dim
/>
) : null}
<View style={{ flex: 1, padding: StyleConstants.Spacing.S }}>