mirror of
https://gitee.com/vant-contrib/vant-weapp.git
synced 2025-04-06 03:58:05 +08:00
[improvement] Dialog: centered in screen (#1782)
This commit is contained in:
parent
4586446e83
commit
cbaa83a416
@ -46,6 +46,7 @@
|
|||||||
</van-button>
|
</van-button>
|
||||||
<van-dialog
|
<van-dialog
|
||||||
use-slot
|
use-slot
|
||||||
|
title="标题"
|
||||||
show="{{ show }}"
|
show="{{ show }}"
|
||||||
show-cancel-button
|
show-cancel-button
|
||||||
bind:close="onClose"
|
bind:close="onClose"
|
||||||
|
@ -84,6 +84,7 @@ Dialog.confirm({
|
|||||||
```html
|
```html
|
||||||
<van-dialog
|
<van-dialog
|
||||||
use-slot
|
use-slot
|
||||||
|
title="标题"
|
||||||
show="{{ show }}"
|
show="{{ show }}"
|
||||||
show-cancel-button
|
show-cancel-button
|
||||||
confirm-button-open-type="getUserInfo"
|
confirm-button-open-type="getUserInfo"
|
||||||
|
@ -1,6 +1,7 @@
|
|||||||
@import '../common/style/var.less';
|
@import '../common/style/var.less';
|
||||||
|
|
||||||
.van-dialog {
|
.van-dialog {
|
||||||
|
top: 45% !important;
|
||||||
width: 85%;
|
width: 85%;
|
||||||
overflow: hidden;
|
overflow: hidden;
|
||||||
font-size: 16px;
|
font-size: 16px;
|
||||||
@ -10,6 +11,7 @@
|
|||||||
&__header {
|
&__header {
|
||||||
padding-top: 25px;
|
padding-top: 25px;
|
||||||
font-weight: 500;
|
font-weight: 500;
|
||||||
|
line-height: 24px;
|
||||||
text-align: center;
|
text-align: center;
|
||||||
|
|
||||||
&--isolated {
|
&--isolated {
|
||||||
@ -22,7 +24,7 @@
|
|||||||
padding: 25px;
|
padding: 25px;
|
||||||
overflow-y: auto;
|
overflow-y: auto;
|
||||||
font-size: 14px;
|
font-size: 14px;
|
||||||
line-height: 1.5;
|
line-height: 20px;
|
||||||
text-align: center;
|
text-align: center;
|
||||||
-webkit-overflow-scrolling: touch;
|
-webkit-overflow-scrolling: touch;
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user