I'm having a DefaultMenuModel inside a tab from an accordion panel.
Now the menu is behind the tab of an acccordion panel and I like to change the z-index of the menu, that it will be in front of the tab.
It looks like:
I tried the following:
<?xml version="1.0" encoding="UTF-8"?>
<ui:composition xmlns="http://www.w3.org/1999/xhtml" xmlns:ui="http://java.sun.com/jsf/facelets" xmlns:f="http://java.sun.com/jsf/core" xmlns:h="http://java.sun.com/jsf/html" xmlns:p="http://primefaces.org/ui" template="/templates/template.xhtml">
<ui:define name="window_title"/>
<ui:define name="content">
<h:form id="exportForm" style="height:100%">
<p:growl id="growl" showDetail="true" />
<p:accordionPanel id="memberPanel" multiple="true" activeIndex="1" styleClass="test1">
<p:tab title="#{messages['member_filter']}">
<table>
<tr valign="top">
<td>#{messages['export_filter']} <br></br>
<p:tieredMenu styleClass="test2" id="type" model="#{dynamicFilterMenuExport.menu}" />
</td>
<td><p:spacer width="10" /></td>
<td>#{messages['export_filter_select']}<br></br>
<br></br> <!-- more Code-->
</tr>
</table>
</p:tab>
<p:tab title="#{messages['menu_Members']}" >
<!-- datatable etc. -->
</p:tab>
</p:accordionPanel>
</h:form>
</ui:define>
</ui:composition>
My css looks like:
.test1 {
position: relative;
z-index: 1000 !important;
}
.test2 {
position: relative;
z-index: 2000 !important;
overflow:visible !important;
}
Does anyone have an idea how I can fix it?
After hours of searching I found out the answer be adjusting the css. Now it's working perfectly with the code below:
.ui-accordion-content {
overflow:visible !important;
}
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.