Book Image

Primefaces Theme development

Book Image

Primefaces Theme development

Overview of this book

Developing stunning themes for web applications has never been easier! PrimeFaces delivers a powerful set of features that enables JSF developers to create and customize awesome themes on the web. It is very easy to use because it comes as a single JAR file and requires no mandatory XML configuration. With more than 30 out-of-the-box themes, jQuery integration, a mobile UI toolkit, Ajax Push technology, and much more, PrimeFaces takes JSF application development to a whole new level! This book is a hands-on example-rich guide to creating and customizing PrimeFaces themes using available tools. Beginning with creating a JSF project and integrating the PrimeFaces library, this book will introduce you to the features of theme components, how these are structured, and how PrimeFaces uses JQuery UI to apply a theme to your application. You will learn to examine and change the CSS rules and get creative by setting standard icons and adding new icons to them. You will use a combination of JavaScript and CSS to enhance your application with help of scheduler component and go on to adapt and package your custom theme so that it is compatible with the Resource Manager. Finally, you will explore PrimeFaces mobile apps, ensuring themes are compatible with your mobile applications best practices for theme design.
Table of Contents (18 chapters)
PrimeFaces Theme Development
Credits
About the Authors
About the Reviewers
www.PacktPub.com
Preface
Index

Examining the UI element using the browser developer tool


Modern browsers come with tools or extensions, which can be used by web developers to see under the hood of a page. As we want to examine the HTML that a JSF inputText component produces, or renders (in JSF terms), we use the developer tools to view the actual HTML produced in the page.

I used Google Chrome for this book, but those of you who use Firefox will have the same standard tools available. The good news for those of you who use Internet Explorer is that version 11 also has a set of developer tools similar to those available in Google Chrome and Firefox.

In order to view the code, we don't right-click on the page and click on View code source anymore. If you do so now, you will see a simple page containing the text version of the HTML that was rendered. This is hard to read and often not formatted for us to read easily. What we actually do is place the cursor of the mouse over an element on the page, which is the input text...