arya-blue
luna-amber
luna-blue
luna-green
luna-pink
nova-dark
nova-light
saga-blue
vela-blue
FluidGrid
FluidGrid allows to set up a nice tight grid with items that have variable heights and widths. FluidGrid is a responsive grid. That means, the grid will reflow as the window size changes. Items can have any content: text, images, links, input fields, etc. They can be defined in a static or in a dynamic way as in data iteration components.

This example demonstrates how to design a responsive dynamic grid with input fields. This is similar to the DynaForm component in PrimeFaces Extensions, but the grid is not a fixed table in this case. It is responsive! Try to resize the browser window. Tip: You will achieve a consistent alignment across all field blocks if you place the labels above the input fields.

The attribute type of pe:fluidGridItem should match the corresponding type property of FluidGridItem.
Source

                <p:growl id="growl" showDetail="true" showSummary="true">
                <p:autoUpdate/>
            </p:growl>

            <pe:fluidGrid id="fluidGrid" value="#{fluidGridDynaFormController.items}" var="data"
                          resizeBound="false" hGutter="20" widgetVar="fluidGridWdgt" style="width:600px">
                <pe:fluidGridItem type="input">
                    <div class="dynaFormLabel">
                        <p:outputLabel for="txt" value="#{data.label}"/>
                    </div>
                    <p:inputText id="txt" value="#{data.value}" required="#{data.required}"/>
                </pe:fluidGridItem>
                <pe:fluidGridItem type="select" styleClass="select">
                    <div class="dynaFormLabel">
                        <p:outputLabel for="menu" value="#{data.label}"/>
                    </div>
                    <p:selectOneMenu id="menu" value="#{data.value}" required="#{data.required}">
                        <f:selectItems value="#{data.selectItems}"/>
                    </p:selectOneMenu>
                </pe:fluidGridItem>
                <pe:fluidGridItem type="calendar" styleClass="calendar">
                    <div class="dynaFormLabel">
                        <p:outputLabel for="cal" value="#{data.label}"/>
                    </div>
                    <p:calendar id="cal" value="#{data.value}" required="#{data.required}" showOn="button"/>
                </pe:fluidGridItem>
            </pe:fluidGrid>

            <p:commandButton value="Submit" style="margin-top: 10px;"
                             process="fluidGrid" update=":mainForm:fluidGrid :mainForm:inputValues"
                             oncomplete="if(!args.validationFailed) {PF('inputValuesWidget').show();}"/>

            <p:dialog header="Input values" widgetVar="inputValuesWidget">
                <p:dataList id="inputValues" value="#{fluidGridDynaFormController.items}" var="item"
                            style="margin:10px;">
                    <h:outputText value="#{item.data.label} : #{item.data.value}" style="margin-right:15px;"/>
                </p:dataList>
            </p:dialog>

            <h:outputStylesheet id="fluidGridCSS">
                .pe-fluidgrid-item {
                    width: 160px;
                    height: 60px;
                }

                .pe-fluidgrid-item input {
                    width: 150px;
                }

                .pe-fluidgrid-item.calendar input {
                    width: 120px;
                }

                .pe-fluidgrid-item.select .ui-selectonemenu {
                    width: 134px !important;
                }

                .dynaFormLabel {
                    font-weight: bold;
                    margin-bottom: 7px;
                }
            </h:outputStylesheet>
            
Components and more
Documentation
Attributes (move mouse over the names to see data types)
Name Description
No attributes available for this component.
PrimeFaces Extensions Showcase - © 2011-2025,PrimeFaces: 15.0.13,PrimeFaces Extensions: 15.0.14-SNAPSHOT,JSF: Apache MyFaces JSF-2.3 Core Impl 2.3.10,Server: Apache Tomcat (TomEE)/9.0.82 (8.0.16),Build time: 2026-02-23 00:32