Skip to main content
Version: v4

MessagePinnedHeader

Component to render the pinned message label (user) of a message within the MessageList.

Basic Usage

You can customize the MessagePinnedHeader component and provide it back to the SDK via the MessagePinnedHeader prop on Channel if desired.

import {Channel, MessageAvatar} from 'stream-chat-react-native';

const MessagePinnedHeaderComponent = () => <MessagePinnedHeader />

<Channel MessagePinnedHeader={MessagePinnedHeaderComponent} />

Props

This component uses default values for all the following props, from MessageContext

overrides the value from MessageContext
alignment

Sets if the message should be aligned to right or left side of list.

TypeDefault
enum('right', 'left')'right'

overrides the value from MessageContext
message

Message object

Type
object

Did you find this page helpful?