diff --git a/packages/card/en-US.md b/packages/card/en-US.md index 69743dbf6..90a879e10 100644 --- a/packages/card/en-US.md +++ b/packages/card/en-US.md @@ -52,7 +52,6 @@ Use `slot` to custom content. | num | Number | `String | Number` | - | | price | Price | `String | Number` | - | | origin-price | Origin price | `String | Number` | - | -| centered | Whether content vertical centered | `String` | `false` | | currency | Currency symbol | `String` | `¥` | | thumb-link | Thumb link URL | `String` | - | | lazy-load | Whether to enable thumb lazy load,should register [Lazyload](#/en-US/lazyload) component | `Boolean` | `false` | diff --git a/packages/card/index.less b/packages/card/index.less index 60e3207df..dc4a1eeac 100644 --- a/packages/card/index.less +++ b/packages/card/index.less @@ -2,14 +2,12 @@ @import '../style/mixins/ellipsis'; .van-card { - color: @text-color; - display: flex; - font-size: 12px; position: relative; - box-sizing: border-box; + color: @text-color; + font-size: 12px; padding: 5px 15px; + box-sizing: border-box; background-color: @background-color-light; - flex-wrap: wrap; &:not(:first-child) { margin-top: 10px; @@ -21,6 +19,10 @@ justify-content: center; } + &__header { + display: flex; + } + &__thumb { position: relative; width: 90px; @@ -44,12 +46,12 @@ &__title, &__desc { - line-height: 17px; word-break: break-all; } &__title { - max-height: 34px; + line-height: 16px; + max-height: 32px; font-weight: bold; .multi-ellipsis(2); @@ -57,7 +59,8 @@ &__desc { color: @gray-darker; - max-height: 17px; + max-height: 20px; + line-height: 20px; } &__bottom { @@ -65,7 +68,7 @@ bottom: 0; left: 0; width: 100%; - line-height: 17px; + line-height: 18px; } &__price { @@ -93,7 +96,6 @@ } &__footer { - width: 100%; text-align: right; flex: none; diff --git a/packages/card/index.vue b/packages/card/index.vue index 1e0fc3203..75049fada 100644 --- a/packages/card/index.vue +++ b/packages/card/index.vue @@ -1,67 +1,69 @@