docs: demo card (#6703)

This commit is contained in:
neverland
2020-07-04 20:38:16 +08:00
committed by GitHub
parent d515780460
commit 2f1e84abe4
13 changed files with 1534 additions and 903 deletions

View File

@@ -1,6 +1,6 @@
<template>
<div class="van-doc-demo-block">
<h2 class="van-doc-demo-block__title">{{ title }}</h2>
<h2 v-if="title" class="van-doc-demo-block__title">{{ title }}</h2>
<div v-if="card" class="van-doc-demo-block__card">
<slot />
</div>
@@ -33,11 +33,15 @@ export default {
}
&__card {
margin: 0 12px 0;
margin: 12px 12px 0;
overflow: hidden;
border-radius: 8px;
}
&__title + &__card {
margin-top: 0;
}
&:first-of-type {
.van-doc-demo-block__title {
padding-top: 20px;