Skip to main content
Version: v4

Image Bubble

CometChatImageBubble is the content view for a MediaMessage if the media sent is an image.

Properties

PropertiesTypeDescription
imageUrlImageTypeThe image to be displayed
placeholderImageImageTypethe path of the image from assets to display when the actual image is being fetched
styleImageBubbleStyleused to customize appearance of this widget
onPressFunctioncustom action on tapping the image

ImageBubbleStyle

ImageBubbleStyle is the class containing attributes to customize appearance of this widget.

PropertiesTypeDescription
heightstring | numberused to set height
widthstring | numberused to set width
backgroundColorstringused to set background colour
borderBorderStyleused to set border
borderRadiusnumberused to set border radius

Usage

<CometChatImageBubble
imageUrl={{uri: "https://data-us.cometchat.io/208434241880dc4d/media/1676951632_1179067617_0bb4ab5734e38db8b6fce07a5a912b84.jpg"}}
style={{borderRadius: 8}}
/>