mirror of
https://gitee.com/vant-contrib/vant.git
synced 2025-04-06 03:57:59 +08:00
[Improvement] Dialog: isolated title (#1270)
This commit is contained in:
parent
d6388a923c
commit
9431412906
@ -1,7 +1,7 @@
|
||||
<template>
|
||||
<transition name="van-dialog-bounce">
|
||||
<div v-show="value" :class="[b(), className]">
|
||||
<div v-if="title" v-text="title" :class="b('header')" />
|
||||
<div v-if="title" v-text="title" :class="b('header', { isolated: !message && !$slots.default })" />
|
||||
<div :class="b('content')" v-if="message || $slots.default">
|
||||
<slot>
|
||||
<div v-if="message" v-html="message" :class="b('message', { 'has-title': title })" />
|
||||
|
@ -15,6 +15,10 @@
|
||||
&__header {
|
||||
padding: 15px 0 0;
|
||||
text-align: center;
|
||||
|
||||
&--isolated {
|
||||
padding: 25px 0;
|
||||
}
|
||||
}
|
||||
|
||||
&__message {
|
||||
@ -40,10 +44,6 @@
|
||||
}
|
||||
}
|
||||
|
||||
&__header + &__footer {
|
||||
margin-top: 15px;
|
||||
}
|
||||
|
||||
.van-button {
|
||||
border: 0;
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user