Skip to content

Commit f420e08

Browse files
authored
chore: make imageContainerStyle theme compliant (#2950)
1 parent 3c3483a commit f420e08

File tree

2 files changed

+11
-2
lines changed

2 files changed

+11
-2
lines changed

package/src/components/Attachment/Gallery.tsx

Lines changed: 9 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -293,7 +293,14 @@ const GalleryThumbnail = <
293293
theme: {
294294
colors: { overlay },
295295
messageSimple: {
296-
gallery: { image, imageBorderRadius, imageContainer, moreImagesContainer, moreImagesText },
296+
gallery: {
297+
image,
298+
imageBorderRadius,
299+
imageContainer,
300+
imageContainerStyle,
301+
moreImagesContainer,
302+
moreImagesText,
303+
},
297304
},
298305
},
299306
} = useTheme();
@@ -383,7 +390,7 @@ const GalleryThumbnail = <
383390
thumb_url={thumbnail.thumb_url}
384391
/>
385392
) : (
386-
<View style={styles.imageContainerStyle}>
393+
<View style={[styles.imageContainerStyle, imageContainerStyle]}>
387394
<GalleryImageThumbnail
388395
borderRadius={imageBorderRadius ?? borderRadius}
389396
ImageLoadingFailedIndicator={ImageLoadingFailedIndicator}

package/src/contexts/themeContext/utils/theme.ts

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -571,6 +571,7 @@ export type Theme = {
571571
gridWidth: number;
572572
image: ImageStyle;
573573
imageContainer: ViewStyle;
574+
imageContainerStyle: ViewStyle;
574575
maxHeight: number;
575576
maxWidth: number;
576577
minHeight: number;
@@ -1354,6 +1355,7 @@ export const defaultTheme: Theme = {
13541355
image: {},
13551356
imageBorderRadius: undefined,
13561357
imageContainer: {},
1358+
imageContainerStyle: {},
13571359
maxHeight: 300,
13581360
maxWidth: 256,
13591361
minHeight: 100,

0 commit comments

Comments
 (0)