0
我想显示警报但在那里我无法添加离子选择,因此我创建了一个网格,并且需要在网页的中心显示网格,并且应禁用背景。显示类似于警报的网格
<ion-grid class="showmodal" *ngIf="showNews" style=" background:white; width:50%; height:60%">
<ion-row>
</ion-row>
</ion-grid>
我想可能的CSS,我能够获得电网,但它不会居中
.showmodal{
position: fixed;
top: 0;
height: 100%;
width: 100%;
background: rgba(23, 22, 22, 0.8);
z-index: 10;
left: 0px;
}
此网格应该始终即使屏幕尺寸不同的中心。