I'm using the calendar
component of Primefaces
, but I'm having trouble overwriting CSS
of it.
Here is my code in xhtml
:
<h:panelGrid columns="2" columnClasses="col one, col one">
<h:outputLabel value="Data Início:"
styleClass="label" style="width: 50% !important" />
<h:outputLabel value="Data Fim:"
styleClass="label" style="width: 50% !important" />
<p:calendar pattern="dd/MM/yyyy" mode="popup" required="true"
showOn="button" popupIconOnly="true"
value="#{bean.entidade.dataIni}" locale="pt_BR"
showButtonPanel="false" readonlyInput="true"
maxlength="10" />
<p:calendar pattern="dd/MM/yyyy" mode="popup" required="true"
showOn="button" popupIconOnly="true"
value="#{bean.entidade.dataFim}" locale="pt_BR"
showButtonPanel="false" readonlyInput="true"
maxlength="10" />
</h:panelGrid>
My problem is that I am setting a style="width: 50% !important"
style that is not applied, and the two calendar
components are one below the other.
Note: CSS
col one is following:
.col.one,.col.one * {
width: 900px;
}