【发布时间】:2018-01-17 06:08:22
【问题描述】:
我在 IE 11 上的 z-index 有问题,弹出消息中的其他元素下会出现一个下拉菜单。让我给你看一张从页面上截取的小草图。
我重新搜索了很多可能的解决方案,但任何一个都不适合我。我也在使用带有 Angular 2 的 PrimeFaces。我发现 this solution 可以在 IE 中解决此类问题:
<div style="position: relative; z-index: 3000">
<div style="position: absolute; z-index: 1000">
[ ... ] <!-- The drop down menu will be here -->
</div>
</div>
我尝试在我的代码中使用这种方式,但不起作用。 :(
<p-dialog header="Assign claim {{ vm.request.id }}" [(visible)]="vm.isDisplayed" [width]="700" [modal]="true" >
<div class="ui-g form-group">
<div style="z-index: 3000">
<div class="ui-g-6">
<h4>Lorem ipsum</h4>
{{vm.request.responsible}}
</div>
<div class="ui-g-6">
<h4>et dolo</h4>
<div style="z-index: 1000"> <!-- This dropdown menu should to appear over the form, not behind :( -->
<p-dropdown class="popup-dropdown" [(ngModel)]="vm.id" [options]="vm.users" [autoWidth]="false" (onChange)="changeAssignedUserId($event.value)">
</p-dropdown>
</div>
</div>
<div class="ui-g ui-g-12"></div>
</div>
</div>
<!-- More awesome code! -->
谁能帮帮我?
提前感谢大家。 阿夏。
【问题讨论】:
标签: css internet-explorer-11 angular2-template