Skip to content

Commit e89fa89

Browse files
authored
feat: configure ReactionList reaction theme (#2561)
1 parent af68328 commit e89fa89

File tree

2 files changed

+10
-1
lines changed

2 files changed

+10
-1
lines changed

package/src/components/Message/MessageSimple/ReactionList.tsx

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -117,6 +117,8 @@ const ReactionListWithContext = <
117117
middleIcon,
118118
radius: themeRadius,
119119
reactionBubble,
120+
reactionContainer,
121+
reactionCount,
120122
reactionSize: themeReactionSize,
121123
strokeSize: themeStrokeSize,
122124
},
@@ -246,6 +248,7 @@ const ReactionListWithContext = <
246248
{
247249
marginRight: index < reactions.length - 1 ? 5 : 0,
248250
},
251+
reactionContainer,
249252
]}
250253
>
251254
<Icon
@@ -256,7 +259,9 @@ const ReactionListWithContext = <
256259
supportedReactions={supportedReactions}
257260
type={reaction.type}
258261
/>
259-
<Text style={[styles.reactionCount, { color: black }]}>{reaction.count}</Text>
262+
<Text style={[styles.reactionCount, { color: black }, reactionCount]}>
263+
{reaction.count}
264+
</Text>
260265
</View>
261266
))}
262267
</TouchableOpacity>

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

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -533,6 +533,8 @@ export type Theme = {
533533
middleIcon: ViewStyle;
534534
radius: number;
535535
reactionBubble: ViewStyle;
536+
reactionContainer: ViewStyle;
537+
reactionCount: TextStyle;
536538
reactionSize: number;
537539
strokeSize: number;
538540
};
@@ -1119,6 +1121,8 @@ export const defaultTheme: Theme = {
11191121
middleIcon: {},
11201122
radius: 2, // not recommended to change this
11211123
reactionBubble: {},
1124+
reactionContainer: {},
1125+
reactionCount: {},
11221126
reactionSize: 24,
11231127
strokeSize: 1, // not recommended to change this
11241128
},

0 commit comments

Comments
 (0)