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

Input Style

Themes

PrimeUIX
Aura Light Emerald Aura Light Emerald
Aura Dark Emerald Aura Dark Emerald
PrimeOne
Saga Blue Saga Blue
Vela Blue Vela Blue
Arya Blue Arya Blue
Bootstrap
Bootstrap Blue Light Bootstrap Blue Light
Bootstrap Purple Light Bootstrap Purple Light
Bootstrap Blue Dark Bootstrap Blue Dark
Bootstrap Purple Dark Bootstrap Purple Dark
Material Design
Material Indigo Light Material Indigo Light
Material Deep Purple Light Material Deep Purple Light
Material Indigo Dark Material Indigo Dark
Material Deep Purple Dark Material Deep Purple Dark
Material Design Compact
Material Compact Indigo Light Material Compact Indigo Light
Material Compact Deep Purple Light Material Compact Deep Purple Light
Material Compact Indigo Dark Material Compact Indigo Dark
Material Compact Deep Purple Dark Material Compact Deep Purple Dark
Legacy
Nova Light Nova Light
Nova Dark Nova Dark
Nova Colored Nova Colored
Luna Amber Luna Amber
Luna Blue Luna Blue
Luna Green Luna Green
Luna Pink Luna Pink

ContextMenu Basic

ContextMenu is an overlay menu display mainly displayed using right-click.

ContextMenu Tag Documentation

ContextMenu provides an overlay menu displayed on mouse right-click event.

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.
appendTo String false @(body) Search expression for the element to which the menu overlay is appended.
autoDisplay boolean false true Defines whether the first level of submenus will be displayed on mouseover or click event.
beforeShow String false Client side callback to execute before showing.
dir String false ltr Defines text direction, valid values are ltr and rtl.
disabled boolean false false If true, prevents menu from being shown
event String false Event to bind contextMenu display, default is contextmenu aka right click.
for String false Id of the component to attach to
hideDelay int false 0 Delay in milliseconds before hiding the submenu, if 0 not hidden until document.click().
model MenuModel false Menu model instance to create menu programmatically.
nodeType String false Specific type of tree nodes to attach to.
selectionMode String false multiple Defines the selection behavior, e.g., "single" or "multiple".
showDelay int false 0 Delay in milliseconds before displaying the submenu. Default is 0 meaning immediate.
style String false Inline style of the component.
styleClass String false Style class of the component.
tabindex String false 0 Position of the element in the tabbing order.
targetFilter String false Selector to filter the elements to attach the menu.
toggleEvent String false Event to toggle the submenus, valid values are "hover" and "click".
touchable Boolean false Enable touch if supported by device. NULL uses global default or primefaces.TOUCHABLE. Default: globally enabled.
Loading...
Tag DocumentationNew DocumentationNew Documentation JSDoc Basic Tiered Target DataTable Tree TreeTable
Right click to view the menu options.

Usage


<div class="card">
    Right click to view the menu options.

    <h:form>
        <p:growl id="messages" showDetail="true"/>

        <p:contextMenu>
            <p:menuitem value="Save" action="#{menuView.save}" update="messages" icon="pi pi-save"/>
            <p:menuitem value="Update" action="#{menuView.update}" update="messages" icon="pi pi-refresh"/>
            <p:menuitem value="Delete" action="#{menuView.delete}" ajax="false" icon="pi pi-times"/>
            <p:menuitem value="Homepage" url="https://www.primefaces.org" icon="pi pi-home"/>
        </p:contextMenu>
    </h:form>
</div>