Define style for p: clock element in files

I'm trying to put a style in p:clock element

with a class attribute, but I get the following message:

java.lang.IllegalArgumentException: no setter found for property class.

What's another way to define a style for an element p:clock

?

XHTML:

<p:clock pattern="HH:mm" class="clock"/>

      

CSS

.clock
{
    border-radius: 0px !important;
}

      

+3


source to share


1 answer


Never use class

. For many components, you would styleClass

use this instead, but here you have to do it like this:

<p:clock pattern="HH:mm"/>

.ui-clock{
    border-radius: 0px !important;
}

      



This method of execution is described in the User's Guide in the section "Skinning".

+2


source







All Articles