Skip to content

Commit

Permalink
fix(renderAvatar): allow null values to be passed
Browse files Browse the repository at this point in the history
Fixes null type for renderAvatar prop
  • Loading branch information
Johan-dutoit authored Jun 12, 2023
2 parents f7d1c44 + 1fca709 commit b66f373
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/GiftedChat.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -156,7 +156,7 @@ export interface GiftedChatProps<TMessage extends IMessage = IMessage> {
/* Custom "Load earlier messages" button */
renderLoadEarlier?(props: LoadEarlierProps): React.ReactNode
/* Custom message avatar; set to null to not render any avatar for the message */
renderAvatar?(props: AvatarProps<TMessage>): React.ReactNode | null
renderAvatar?: null | ((props: AvatarProps<TMessage>) => React.ReactNode)
/* Custom message bubble */
renderBubble?(props: Bubble<TMessage>['props']): React.ReactNode
/*Custom system message */
Expand Down

0 comments on commit b66f373

Please sign in to comment.