mirror of
https://gitee.com/vant-contrib/vant.git
synced 2025-04-06 03:57:59 +08:00
Merge pull request #131 from chenjiahan/dev
Button: fix disabled color wrong when has bottomAction prop
This commit is contained in:
commit
2d765e6937
@ -74,7 +74,8 @@ Vue.component(Button.name, Button);
|
|||||||
|
|
||||||
:::demo 加载状态
|
:::demo 加载状态
|
||||||
```html
|
```html
|
||||||
<van-button loading />
|
<van-button loading></van-button>
|
||||||
|
<van-button loading type="primary"></van-button>
|
||||||
```
|
```
|
||||||
:::
|
:::
|
||||||
|
|
||||||
|
@ -3,8 +3,8 @@
|
|||||||
<van-cell-group>
|
<van-cell-group>
|
||||||
<van-cell :title="title" :isLink="editable" @click="$emit('click')">
|
<van-cell :title="title" :isLink="editable" @click="$emit('click')">
|
||||||
<div v-if="coupons[chosenCoupon]">
|
<div v-if="coupons[chosenCoupon]">
|
||||||
<h2>{{ amount }}</h2>
|
<div>{{ amount }}</div>
|
||||||
<span>{{ coupons[chosenCoupon].condition }}</span>
|
<div>{{ coupons[chosenCoupon].condition }}</div>
|
||||||
</div>
|
</div>
|
||||||
<template v-else>{{ guide }}</template>
|
<template v-else>{{ guide }}</template>
|
||||||
</van-cell>
|
</van-cell>
|
||||||
|
@ -36,10 +36,6 @@
|
|||||||
color: $button-default-color;
|
color: $button-default-color;
|
||||||
background-color: $button-default-background-color;
|
background-color: $button-default-background-color;
|
||||||
border: 1px solid $button-default-border-color;
|
border: 1px solid $button-default-border-color;
|
||||||
|
|
||||||
&:active {
|
|
||||||
color: $gray-dark;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
&--primary {
|
&--primary {
|
||||||
@ -91,12 +87,6 @@
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
&--disabled {
|
|
||||||
color: $button-disabled-color;
|
|
||||||
background-color: $button-disabled-background-color;
|
|
||||||
border: 1px solid $button-disabled-border-color;
|
|
||||||
}
|
|
||||||
|
|
||||||
&--block {
|
&--block {
|
||||||
width: 100%;
|
width: 100%;
|
||||||
display: block;
|
display: block;
|
||||||
@ -112,13 +102,14 @@
|
|||||||
color: $bottom-action-button-default-color;
|
color: $bottom-action-button-default-color;
|
||||||
background-color: $bottom-action-button-default-background-color;
|
background-color: $bottom-action-button-default-background-color;
|
||||||
|
|
||||||
&:active {
|
|
||||||
color: $white;
|
|
||||||
}
|
|
||||||
|
|
||||||
&.van-button--primary {
|
&.van-button--primary {
|
||||||
color: $bottom-action-button-primary-color;
|
|
||||||
background-color: $bottom-action-button-primary-background-color;
|
background-color: $bottom-action-button-primary-background-color;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
&--disabled {
|
||||||
|
color: $button-disabled-color;
|
||||||
|
background-color: $button-disabled-background-color;
|
||||||
|
border: 1px solid $button-disabled-border-color;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
@ -32,8 +32,12 @@
|
|||||||
width: 100%;
|
width: 100%;
|
||||||
height: 14px;
|
height: 14px;
|
||||||
font-size: 14px;
|
font-size: 14px;
|
||||||
color: $gray-dark;
|
color: $gray-darker;
|
||||||
border: none;
|
border: none;
|
||||||
|
|
||||||
|
&::placeholder {
|
||||||
|
color: $gray-dark;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
&__cancel {
|
&__cancel {
|
||||||
|
@ -82,8 +82,7 @@ describe('CouponCell', () => {
|
|||||||
|
|
||||||
DOMChecker(wrapper, {
|
DOMChecker(wrapper, {
|
||||||
text: {
|
text: {
|
||||||
'.van-cell__value--link h2': '新手专用优惠券 省¥1.50',
|
'.van-cell__value--link div div': '新手专用优惠券 省¥1.50'
|
||||||
'.van-cell__value--link span': '下单立减 1.50 元'
|
|
||||||
},
|
},
|
||||||
count: {
|
count: {
|
||||||
'.van-cell__right-icon': 1
|
'.van-cell__right-icon': 1
|
||||||
@ -102,8 +101,7 @@ describe('CouponCell', () => {
|
|||||||
|
|
||||||
DOMChecker(wrapper, {
|
DOMChecker(wrapper, {
|
||||||
text: {
|
text: {
|
||||||
'.van-cell__value h2': '新手专用优惠券 省¥1.50',
|
'.van-cell__value div div': '新手专用优惠券 省¥1.50'
|
||||||
'.van-cell__value span': '下单立减 1.50 元'
|
|
||||||
},
|
},
|
||||||
count: {
|
count: {
|
||||||
'.van-cell__right-icon': 0
|
'.van-cell__right-icon': 0
|
||||||
|
Loading…
x
Reference in New Issue
Block a user