[improvement] Card: add tag prop (#1878)

This commit is contained in:
neverland
2018-09-30 15:46:05 +08:00
committed by GitHub
parent 69151078cc
commit 6c983929c6
6 changed files with 28 additions and 6 deletions
+10 -1
View File
@@ -4,6 +4,14 @@
<slot name="thumb">
<img :src="thumb" :class="b('img')" >
</slot>
<van-tag
v-if="tag"
mark
type="danger"
:class="b('tag')"
>
{{ tag }}
</van-tag>
</div>
<div :class="b('content')">
<slot name="title">
@@ -33,9 +41,10 @@ export default create({
name: 'card',
props: {
tag: String,
desc: String,
thumb: String,
title: String,
desc: String,
centered: Boolean,
num: [Number, String],
price: [Number, String],