CometChatBadge is the custom component which is used to display the unread message count. It can be used in places like CometChatListItem, etc.
Properties
Badge Style
Usage
- HTML
- JavaScript
Documentation Index
Fetch the complete documentation index at: /llms.txt
Use this file to discover all available pages before exploring further.
CometChatBadge is the custom component which is used to display the unread message count. It can be used in places like CometChatListItem, etc.
| Name | Type | Description |
|---|---|---|
| count | number | The numeric value to be displayed |
| badgeStyle | BadgeStyle | Styling properties of the element |
| Name | Description |
|---|---|
| textFont | Sets all the different properties of font for the badge text. Reference link |
| textColor | Sets the foreground color of the text displayed on the badge. |
<!--use the element-->
<cometchat-badge
[badgeStyle]="badgeStyle"
[count]="'10'"
></cometchat-badge>
import { BadgeStyle } from '@cometchat/chat-uikit-angular'; //import the style class.
//create style object
badgeStyle:BadgeStyle = new BadgeStyle({
width:"36px",
height:"36px",
textFont:"400 13px Inter",
textColor:"black"
})
Was this page helpful?