SnippetNotifications
Interfaces
SnippetNotificationsProps
Extends
- CardProps
Indexable
[p: string]: any
Any other properties
Properties
| Property | Type | Description | Overrides | 
|---|---|---|---|
| className? | string | Overrides or extends the styles applied to the component. Default null | CardProps.className | 
| handleCustomNotification? | ( data) =>Element | Handle custom notification | - | 
| handleNotification? | ( type,data,content) =>Element | Handle single notification Override content | - | 
| id? | string | Id of the UserNotification Default notification_notificationObject.sid | CardProps.id | 
| key? | number | The obj key | CardProps.key | 
| onFetchNotifications? | ( data) =>void | Callback on fetch notifications Default null; | - | 
| onNotificationClick? | ( event,notification) =>void | Callback when click on single notification | - | 
| ScrollContainerProps? | Record<string,any> | Props to spread to ScrollContainer component This lib use 'react-custom-scrollbars' component to perform scrollbars For more info: https://github.com/malte-wessel/react-custom-scrollbars/blob/master/docs/API.md Default {} | - | 
| showMax? | number | The max n of results shown Default 20 | - | 
Functions
SnippetNotifications()
SnippetNotifications(
inProps):Element
API documentation for the Community-JS SnippetNotifications component. Learn about the available props and the CSS API.
This component renders the notification list. Take a look at our demo component here
Import
import {SnippetNotifications} from '@selfcommunity/react-ui';
Component Name
The name SCSnippetNotifications can be used when providing style overrides in the theme.
CSS
| Rule Name | Global class | Description | 
|---|---|---|
| root | .SCSnippetNotification-root | Styles applied to the root element. | 
| notificationsWrap | .SCSnippetNotification-notification-wrap | Styles applied to the notifications wrap. | 
| emptyBoxNotifications | .SCSnippetNotification-empty-box-notifications | Styles applied to the box indicating that there are no notifications. | 
| list | .SCSnippetNotification-list | Styles applied to the list of notifications. | 
| item | .SCSnippetNotification-item | Styles applied to the single notification. | 
| broadcastMessagesBanner | .SCSnippetNotification-broadcast-messages-banner | Styles applied to the broadcast message banner. | 
Parameters
| Parameter | Type | Description | 
|---|---|---|
| inProps | SnippetNotificationsProps | 
Returns
Element
SnippetNotificationsSkeleton()
SnippetNotificationsSkeleton(
props):Element
API documentation for the Community-JS Snippet Notification Skeleton component. Learn about the available props and the CSS API.
Import
import {SnippetNotificationsSkeleton} from '@selfcommunity/react-ui';
Component Name
The name SCSnippetNotification-skeleton-root can be used when providing style overrides in the theme.
CSS
| Rule Name | Global class | Description | 
|---|---|---|
| root | .SCSnippetNotification-skeleton-root | Styles applied to the root element. | 
| item | .SCSnippetNotification-item | Styles applied to the item element. | 
Parameters
| Parameter | Type | 
|---|---|
| props | any | 
Returns
Element