mirror of
https://gitee.com/vant-contrib/vant.git
synced 2025-04-24 10:20:19 +08:00
[improvement] Dialog: centered in screen (#3905)
This commit is contained in:
parent
32fca2756d
commit
7d9c8a810f
@ -33,10 +33,7 @@
|
|||||||
</van-button>
|
</van-button>
|
||||||
</demo-block>
|
</demo-block>
|
||||||
|
|
||||||
<demo-block
|
<demo-block :title="$t('componentCall')">
|
||||||
v-if="!$attrs.weapp"
|
|
||||||
:title="$t('componentCall')"
|
|
||||||
>
|
|
||||||
<van-button
|
<van-button
|
||||||
type="primary"
|
type="primary"
|
||||||
@click="show = true"
|
@click="show = true"
|
||||||
|
@ -2,7 +2,7 @@
|
|||||||
|
|
||||||
.van-dialog {
|
.van-dialog {
|
||||||
position: fixed;
|
position: fixed;
|
||||||
top: 50%;
|
top: 45%;
|
||||||
left: 50%;
|
left: 50%;
|
||||||
width: @dialog-width;
|
width: @dialog-width;
|
||||||
overflow: hidden;
|
overflow: hidden;
|
||||||
@ -16,6 +16,7 @@
|
|||||||
&__header {
|
&__header {
|
||||||
padding-top: @dialog-header-padding-top;
|
padding-top: @dialog-header-padding-top;
|
||||||
font-weight: @dialog-header-font-weight;
|
font-weight: @dialog-header-font-weight;
|
||||||
|
line-height: @dialog-header-line-height;
|
||||||
text-align: center;
|
text-align: center;
|
||||||
|
|
||||||
&--isolated {
|
&--isolated {
|
||||||
|
@ -208,11 +208,12 @@
|
|||||||
@dialog-border-radius: 4px;
|
@dialog-border-radius: 4px;
|
||||||
@dialog-background-color: @white;
|
@dialog-background-color: @white;
|
||||||
@dialog-header-font-weight: 500;
|
@dialog-header-font-weight: 500;
|
||||||
|
@dialog-header-line-height: 24px;
|
||||||
@dialog-header-padding-top: 25px;
|
@dialog-header-padding-top: 25px;
|
||||||
@dialog-header-isolated-padding: 25px 0;
|
@dialog-header-isolated-padding: 25px 0;
|
||||||
@dialog-message-padding: 25px;
|
@dialog-message-padding: 25px;
|
||||||
@dialog-message-font-size: 14px;
|
@dialog-message-font-size: 14px;
|
||||||
@dialog-message-line-height: 1.5;
|
@dialog-message-line-height: 20px;
|
||||||
@dialog-message-max-height: 60vh;
|
@dialog-message-max-height: 60vh;
|
||||||
@dialog-has-title-message-text-color: @gray-darker;
|
@dialog-has-title-message-text-color: @gray-darker;
|
||||||
@dialog-has-title-message-padding-top: 12px;
|
@dialog-has-title-message-padding-top: 12px;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user