forceCommunity:notifications

The Notifications tool lets your members receive notifications wherever they are working, whether in their communities or in their apps. Members receive notifications on any screen—mobile, tablet, and desktop. All events that trigger notifications (@mentions and group posts) are supported. When a member clicks a notification, the originating detail page or other appropriate location is displayed for seamless collaboration across communities and apps.

A forceCommunity:notifications component represents a Notifications icon. Notifications alert users when key events occur, such as when they are mentioned in Chatter posts. This component is supported for Lightning Experience, Salesforce1 mobile app, and Lightning communities.

<aura:component>
   <forceCommunity:notifications/>
</aura:component>

Notifications let users receive notifications wherever they are working, whether in their communities, or in their apps. All events that trigger notifications (@mentions and group posts) are supported. Users can even trigger notifications on record feeds For example, an internal user can trigger a notification from the Salesforce org by @mentioning an external user on a lead or opportunity.

Here’s an example custom theme layout component that includes forceCommunity:notifications.

<aura:component implements="forceCommunity:themeLayout" access="global" description="Sample Custom Theme Layout">
    <aura:attribute name="search" type="Aura.Component[]" required="false"/>
    <aura:attribute name="profileMenu" type="Aura.Component[]" required="false"/>
    <aura:attribute name="navBar" type="Aura.Component[]" required="false"/>
    <aura:attribute name="newHeader" type="Aura.Component[]" required="false"/>
    <div>
        <div class="notifications">
               <forceCommunity:notifications/>
        </div>
        <div class="searchRegion">
            {!v.search}
        </div>
        <div class="profileMenuRegion">
            {!v.profileMenu}
        </div>
        <div class="navigation">
            {!v.navBar}
        </div>
        <div class="newHeader">
            {!v.newHeader}
        </div>
        <div class="mainContentArea">
            {!v.body}
        </div>
    </div>
</aura:component>

Attributes

Attribute Name Attribute Type Description Required?
body Component[] The body of the component. In markup, this is everything in the body of the tag.