Skin single p:panel

UI Components for JSF
Post Reply
macros14
Posts: 46
Joined: 26 Feb 2010, 19:44

06 Aug 2010, 19:03

Since updating to the new skinning, it seems I can no longer skin a single item. Say I have a component.

Code: Select all

<p:panel id="loanTermsPanel" >
</p:panel>
I use to be able to do css like

Code: Select all

#loanTermsPanel .ui-panel .ui-panel-content{
                padding-left: 0px;
                padding-right: 0px;
            }
To remove the padding from the content container only for that panel. How do I remove the padding from the ui-panel-content for a panel with id of loanTermsPanel?

cagatay.civici
Prime
Posts: 18616
Joined: 05 Jan 2009, 00:21
Location: Cybertron
Contact:

06 Aug 2010, 19:07

You should be able to use;

Code: Select all

#loanTermsPanel.ui-panel .ui-panel-content{
                padding-left: 0px !important;
                padding-right: 0px !important;
            }
or define your customs style class;

Code: Select all

<p:panel styleClass="zeroPadding">

Code: Select all

.zeroPadding .ui-panel-content {
    padding-left: 0px !important;
    padding-right: 0px !important;
}

macros14
Posts: 46
Joined: 26 Feb 2010, 19:44

06 Aug 2010, 19:29

Your first suggestion didn't work but the second suggestion works.

cagatay.civici
Prime
Posts: 18616
Joined: 05 Jan 2009, 00:21
Location: Cybertron
Contact:

06 Aug 2010, 19:47

Glad one of them worked :)

macros14
Posts: 46
Joined: 26 Feb 2010, 19:44

06 Aug 2010, 22:05

Me too, thanks for all your help!

Post Reply

Return to “PrimeFaces”

  • Information
  • Who is online

    Users browsing this forum: No registered users and 52 guests