Last Post

This is my last post on this blog, I’ll writing about PrimeFaces at the official blog from now on.

http://blog.primefaces.org

New Infrastructure for PrimeFaces.org

Prime Teknoloji is making further investments in PrimeFaces.

Last week I’ve moved primefaces.org to it’s new home which hosts a much powerful hardware. Hopefully there won’t be outages anymore. To compare old host has 300mb of ram with 16gb hdd on a crappy processor with limited traffic, on the other new hardware is Intel i7 Quad Core, 8 GB DDR3 Ram with 1.5 TB hdd with unlimited traffic.

I can feel the how fast showcase performs, difference is significant.

Dialog Enhancements

Dialog component has received major update for M3 and reimplemented as a native PrimeFaces widget. Old Dialog was based on jQuery UI’s dialog which was giving us and users some problems since it’s can’t be updated with ajax, uses a fixed 300px default width and more. New Dialog keeps all the features to be backward compatible and adds more;

  • Draggable
  • Resizable
  • Modal
  • Easy Positioning
  • Effects
  • Callbacks and Listeners
  • Minimizable – New!
  • Maximizable – New!
  • Lazy Content – New!
  • Header-Footer Facet – New!
  • Auto Width – New!
  • Can be updated with ajax – New!

Minimize/Maximize mimics the window options in a desktop environment and new dynamic mode is very useful to speed up page load time since dialog contents are loaded lazy before being shown for the first time.

See PrimeFaces Labs for the Beta Demos.

Next stop regarding new features is the new treeTable and then we’ll start with the maintenance/bug-fixes for M3 which is due end of August.

TabView Enhancements

PrimeFaces TabView receives an update for 3.0.M3, there were two popular requests from PrimeFaces Community;

Dynamic number of tabs

There are cases where you can’t know the number of tabs to display, suppose you have a collection and you need a tab for each data. ui:repeat and c:forEach can’t help much here so we’ve added this as a built-in feature.

Demo of Dynamic Tabs

Closable Tabs

Just like browser tabs, a PrimeFaces tab can be closed, you just need to set closable option to true. There is also an optional tabClose ajax behavior provided as a callback similar to tabChange.

Demo of Closable Tabs

DataTable Column Resize Callback

PrimeFaces is built around the following principle. “A good UI component should hide complexity and provide flexibility”. When complexity is hidden, it is easy to lose the flexibility since you as page author not in control. Callbacks are a great to provide flexibility, a case in point is column resizing.

Hide the Complexity

Just set resizableColumns attribute to true and voila! your columns are resizable.

Provide Flexibility

There is an optional ajax behavior called colResize that is triggered when a column is resized, this can be used to invoke a method with ColumnResizeEvent, update other components on page and more. Mainly to keep user’s preferences so next time they open the page, their column widths are restored. Note that a cookie is used by default to keep/restore column widths on page refresh but using colResize you can keep the widths wherever you want.

See the Labs Showcase to see this case in action.

PrimeFaces 3.0.M3 Trailer

Enjoy!

PrimeFaces Brings Excel to JSF

New Component of PrimeFaces called Sheet brings excel to JavaServer Faces, it is a component that mimics the core functionality of spreadsheet desktop applications like excel and openoffice. Notable features are;

  • Incell editing
  • Multiple selection support via meta/shift keys
  • Bulk Updating
  • Frozen headers
  • Vertical/Horizontal Scrolling
  • Global editor
  • Resizable Columns
  • Ajax Sorting
  • Keyboard navigation
  • Theme Aware
Beta Demos are available at PrimeFaces Labs. Note that sheet is designed to be a lightweight component, although we have plans to add new features like fx support, excel-odp export, a feature like multisheet is out of scope since it can be implemented by placing sheets inside tabview.

Always bet on PrimeFaces!

Follow

Get every new post delivered to your Inbox.

Join 110 other followers