• Settings
    • Locale
    • Change the locale of the datepicker, schedule and client side validation messages.

      Language
      English
      English
      English
      French
      German
      German
      German
      Italian
      Korean
      Spanish
      Catalan
      Dutch
      Portuguese
      Portuguese
      Arabic
      Arabic
      Bulgarian
      Bangla
      Bosnian
      Czech
      Greek
      Estonian
      Persian
      Finnish
      Danish
      Hindi
      Indonesian
      Icelandic
      Croatian
      Japanese
      Hungarian
      Hebrew
      Georgian
      Central Kurdish
      Khmer
      Kyrgyz
      Kazakh
      Lithuanian
      Latvian
      Malay
      Norwegian
      Polish
      Romanian
      Russian
      Slovak
      Slovenian
      Serbian
      Serbian
      Swedish
      Thai
      Turkish
      Ukrainian
      Uzbek
      Vietnamese
      Chinese
      Chinese
  • Resources

Sticky

Sticky component positions the target component as fixed so that the component stays in window viewport during scrolling. Scroll down to see the sticky toolbar.

Sticky Tag Documentation

ticky component positions other components as fixed so that these components stay in window viewport during scrolling.

NameTypeRequiredDefaultDescription
id String false generated Unique identifier of the component in a namingContainer.
rendered boolean false true Boolean value to specify the rendering of the component, when set to false component will not be rendered.
binding UIComponent false generated An EL expression referring to a server side UIComponent instance in a backing bean.
widgetVar String false generated ('widget_' + componentClientId) Name of the client side widget.
margin int false 0 Margin to the top of the page during fixed scrolling.
stickyTopAt String false Selector for elements fixed at the top of the page whose height should be considered when positioning the sticky element.
target String true Identifier of the component(s) to make sticky.
Loading...
Tag DocumentationNew DocumentationNew Documentation JSDoc

Usage


<div class="card">
    <p:toolbar id="tb">
        <f:facet name="left">
            <p:commandButton type="button" value="New" icon="pi pi-file" styleClass="mr-2" />
            <p:commandButton type="button" value="Open" icon="pi pi-folder-open" styleClass="ui-button-success" />
        </f:facet>
        <f:facet name="right">
            <p:commandButton type="button" title="Save" icon="pi pi-save" styleClass="warn-button mr-2" />
            <p:commandButton type="button" title="Delete" icon="pi pi-trash" styleClass="ui-button-danger mr-2" />
            <p:commandButton type="button" title="Print" icon="pi pi-print" styleClass="ui-button-help" />
        </f:facet>
    </p:toolbar>

    <div style="height:800px"></div>

    <p:sticky target="tb" stickyTopAt=".layout-topbar"/>
</div>