Ionic Modal 底部间距
Ionic Modal bottom spacing
我无法在我的模式和屏幕的底部限制之间设置底部间距!在我的 CSS 中,我将 "ion-modal-view" 元素 CSS 的高度和宽度设置为某个百分比,并相应地为左、右、上和下赋予值,一切都按预期工作,我的模态居中,但我无法将其从底部分离。
有什么帮助吗?
最后,我设法通过将 ion-modal-view
包装在 div
上并在 modal
[=23= 上应用 min-height: 0;
指令来让它工作], 这使我的自定义保证金有效。
<div class="adic-modal">
<ion-modal-view class="adic-popup">
<!--some content-->
</ion-modal-view>
</div>
这是CSS:
.adic-modal .modal {
min-height: 0 !important;
}
.adic-popup {
width: 90%;
height: 60%;
top: 20%;
bottom: 20%;
right: 5%;
left: 5%;
background-color: #ffffff;
}
我需要知道我的做法是否正确。
我无法在我的模式和屏幕的底部限制之间设置底部间距!在我的 CSS 中,我将 "ion-modal-view" 元素 CSS 的高度和宽度设置为某个百分比,并相应地为左、右、上和下赋予值,一切都按预期工作,我的模态居中,但我无法将其从底部分离。
有什么帮助吗?
最后,我设法通过将 ion-modal-view
包装在 div
上并在 modal
[=23= 上应用 min-height: 0;
指令来让它工作], 这使我的自定义保证金有效。
<div class="adic-modal">
<ion-modal-view class="adic-popup">
<!--some content-->
</ion-modal-view>
</div>
这是CSS:
.adic-modal .modal {
min-height: 0 !important;
}
.adic-popup {
width: 90%;
height: 60%;
top: 20%;
bottom: 20%;
right: 5%;
left: 5%;
background-color: #ffffff;
}
我需要知道我的做法是否正确。