This week's book giveaway is in the Kotlin forum.
We're giving away four copies of Kotlin in Action and have Dmitry Jemerov & Svetlana Isakova on-line!
See this thread for details.
Win a copy of Kotlin in Action this week in the Kotlin forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic

Primefaces problem with theme  RSS feed

 
nikos karanikos
Greenhorn
Posts: 22
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hello i bought a theme from themeforest but the primefaces conflicts with the js of the theme. Is there any way to fix this conflict without changing all the js?
 
Tim Holloway
Bartender
Posts: 18709
71
Android Eclipse IDE Linux
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Packages such as PrimeFaces contain an extensive set of vendor-specific style definitions that support their "skinning" framework and the names of those style classes are very specific to PrimeFaces. A generic non-Primefaces them won't even begin to fit.

Another thing that the PrimeFaces skins do is separate the look from the function. It's perfectly legal to blend in your own JavaScript (or jQuery), but you have to do so in a way that doesn't interfere with the basic functionality of the controls. So for example, javascript that turns a textbox outline bright yellow when the control receives focus is probably OK, but javascript that attempts to meddle with the dropdown/edit mechanism of a combobox won't be - Primefaces will add additional "on" event attributes to the stock set when stuff like that needs to be customized without breaking the control's basic functionality.

So in brief, you probably aren't going to be able to apply a theme designed for an HTML-only product like WordPress to the JSF PrimeFaces environment without extensively rewriting it.
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!