Source code of a demo web application to the book. More details to the project on GitHub ...
What is this book about?
PrimeFaces Cookbook Second Edition covers over 100 effective recipes for PrimeFaces 5.x which this leading component suite offers you to boost JSF applications - from AJAX basics, theming, i18n support and input components to advanced usage of datatable, menus, drag-&-drop, charts, client-side validation, dialog framework, exception handling, responsive layout, and more.
Publisher, ISBN-10, ISBN-13
Packt Publishing, 1784393428, 978-1784393427
Authors
Mert Çalişkan, Oleg Varaksin
Table of contents
Chapter 1: Getting Started with PrimeFaces
- Setting up and configuring the PrimeFaces library
- AJAX basics with process and update
- PrimeFaces selectors
- Partial process and update with fragments
- Partial view submit
- Internationalization (i18n) and Localization (L10n)
- Improved resource ordering
Chapter 2: Theming Concept
- Understanding structural and skinning CSS
- Installing themes
- Customizing default theme styles
- Adjusting the font and size throughout the web application
- Simple ways to create a new theme
- Stateless and stateful theme switchers
- Integrating Font Awesome with PrimeFaces
Chapter 3: Enhanced Inputs and Selects
- Formatted input with inputMask
- Auto suggestion with autoComplete
- Usable features of inputTextArea
- Discovering selectBooleanCheckbox and selectManyCheckbox
- Choosing a single item with selectOneMenu
- Basic and advanced calendar scenarios
- Spinner – different ways to provide input
- Slider – different ways to provide input
- Rich text editing with the editor
- Advanced editing with an in-place editor
- Enhanced password input
- Star-based rating input
Chapter 4: Grouping Content with Panels
- Grouping content with a standard panel
- PanelGrid with colspan and rowspan support
- Vertical stacked panels with accordion
- Displaying overflowed content with scrollPanel
- Working with a tabbed panel
- Grouping of buttons and more with toolbar
- The multipurpose output panel
- Simulating the portal environment with dashboard
- Creating complex layouts
- Responsive layout with Grid CSS
Chapter 5: Data Iteration Components
- Selecting rows in dataTable
- Sorting and filtering data in dataTable
- In-cell editing with dataTable
- Resizing, reordering, and toggling columns in dataTable
- Making dataTable responsive
- Using subTable for grouping
- Handling tons of data – LazyDataModel
- Listing data with dataList
- Listing data with pickList
- Listing data with orderList
- Visualizing data with tree
- Visualizing data with treeTable
- Exporting data in various formats
- Managing events with schedule by leveraging lazy loading
- Visualizing data with dataScroller
Chapter 6: Endless Menu Variations
- Statically and dynamically positioned menus
- Creating programmatic menus
- The context menu with nested items
- Integrating the context menu
- Breadcrumb – providing contextual information about page hierarchy
- SlideMenu – menu in the iPod style
- TieredMenu – submenus in nested overlays
- MegaMenu – the multicolumn menu
- PanelMenu – hybrid of accordion and tree
- MenuButton – multiple items in a popup
- Accessing commands via menubar
- Displaying checkboxes in selectCheckboxMenu
Chapter 7: Working with Files, Images, and Multimedia
- Basic, automatic, drag and drop, and multiple file uploading
- Downloading files
- Cropping images
- Creating dynamic image streaming programmatically
- Displaying a collection of images with galleria
- Displaying a collection of images with imageSwitch
- Displaying a collection of images with contentFlow
- Embedding the multimedia content in JSF pages
- Capturing images with photoCam
Chapter 8: Drag Me, Drop Me
- Making a component draggable
- Restricting dragging by axis, grid, and containment
- Snapping to the edges of nearest elements
- Defining droppable targets
- Restricting dropping by tolerance and acceptance
- AJAX-enhanced drag and drop
- Integrating drag and drop with data iteration components
Chapter 9: Creating Charts and Maps
- Creating line, area, bar, and pie charts
- Creating combined charts
- Updating live data in charts with polling
- Interacting with charts via AJAX
- Basic mapping with GMaps
- Adding, selecting, and dragging markers in maps
- Creating rectangles, circles, polylines, and polygons in maps
- Enabling InfoWindow and streetView on maps
Chapter 10: Client-side Validation
- Configuring and getting started with CSV
- Instant validation with p:clientValidator
- Bean Validation and transformation
- Extending CSV with JSF
- Extending CSV with Bean Validation
Chapter 11: Miscellaneous Advanced Use Cases
- Programmatic updating and scrolling with RequestContext
- Two ways of triggering the JavaScript execution
- Adding AJAX callback parameters – validation within a dialog
- Opening external pages in dynamically generated dialogs
- Polling – sending periodical AJAX requests
- Blocking page pieces during long-running AJAX calls
- Controlling form submission using defaultCommand
- Clever focus management in forms
- Layout pitfalls of menus and dialogs
- Targetable messages with severity levels
- Conditional coloring in dataTable
- Sticking a component when scrolling
- Reducing page load time using content caching
- Possibilities for exception handling in PrimeFaces