[richfaces-planning-issues] [JBoss JIRA] Commented: (RFPL-1136) messages: document "layout" support

Ilya Shaikovsky (JIRA) jira-events at lists.jboss.org
Sat Mar 12 10:16:46 EST 2011


    [ https://issues.jboss.org/browse/RFPL-1136?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12587554#comment-12587554 ] 

Ilya Shaikovsky commented on RFPL-1136:
---------------------------------------

Common information. 

Layout attribute not supported for the component because in RichFaces 4 it's responsible not only for server side messages rendering but also for client updates on client validation fails. So rendering moved to the client side with just passign from server messages information. So we want to avoid complex code for so simple element updates just in order to support different presentations. Instead proposed to use rf-* predefined css classes in order to control look and feel for the component.

Default look for rich:messages are just vertical list of items like shown at screen msg-table. It's achieved by just setting display:block to every span which contains message.

If you want it to start look as list just add next css declaration:
.rf-msg-err, .rf-msgs-err, .rf-msg-ftl, .rf-msgs-ftl, .rf-msg-inf, .rf-msgs-inf, .rf-msg-wrn, .rf-msgs-wrn, .rf-msg-ok, .rf-msgs-ok {
   display: list-item;
   margin-left: 20px;
   padding-left: 0px;
}
and 
.rf-msg-err, .rf-msgs-err{
background-image:none;
}

the result shown at screen msg-list

And finally if you want the messages to be encoded in line just made next changes:
.rf-msg-err, .rf-msgs-err, .rf-msg-ftl, .rf-msgs-ftl, .rf-msg-inf, .rf-msgs-inf, .rf-msg-wrn, .rf-msgs-wrn, .rf-msg-ok, .rf-msgs-ok {
 display:inline;
}

And the result shown at screen msg-inline

> messages: document "layout" support
> -----------------------------------
>
>                 Key: RFPL-1136
>                 URL: https://issues.jboss.org/browse/RFPL-1136
>             Project: RichFaces Planning
>          Issue Type: Task
>      Security Level: Public(Everyone can see) 
>          Components: doc
>            Reporter: Ilya Shaikovsky
>            Assignee: Ilya Shaikovsky
>             Fix For: 4.0.0.Final
>
>         Attachments: msg-inline.png, msg-list.png, msg-table.png
>
>


--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira


More information about the richfaces-planning-issues mailing list