71
RichFaces <rich:notifyMessage>
It is used to display FacesMessages. This component is built on the top of <rich:notify>.
Style classes and skin parameters
Note – that<rich:notifyMessage> shares common classes with <rich:notify>. since there is exactly one notification rendered for each JSF message.
The following table contains the style classes and corresponding skin parameters for the notifyMessage.
Class | Function | Skin Parameters | Mapped CSS properties |
---|---|---|---|
.rf-ntf-inf | This class defines styles for an informative message. | generalTextColor | color |
.rf-ntf-wrn | This class defines styles for a warning notifications. | No skin parameters. | |
.rf-ntf-err | This class defines styles for a error notifications. | No skin parameters. | |
.rf-ntf-ftl | This class defines styles for a fatal notifications. | No skin parameters. | |
.rf-ntf-inf .rf-ntf-ico, .rf-ntf-wrn .rf-ntf-ico, .rf-ntf-err .rf-ntf-ico, .rf-ntf-ftl .rf-ntf-ico | These classes define style for notification icon based on severity of notification message. | No skin parameters. |
Example
Here, in the following example, we are implementing <rich:notifyMessage> component. This example contains the following files.
JSF Page
// rich-notify-message.xhtml
Managed Bean
// User.java
Output:
Next TopicRichFaces <rich:notifystack>