fix(CouponCell): incorrect value class

This commit is contained in:
chenjiahan
2020-08-17 22:38:18 +08:00
parent fc8009b6bf
commit 980f472259
4 changed files with 6 additions and 6 deletions
+1 -1
View File
@@ -1,7 +1,7 @@
@import '../style/var';
.van-coupon-cell {
&--selected {
&__value--selected {
color: @coupon-cell-selected-text-color;
}
}
+2 -2
View File
@@ -39,7 +39,7 @@ function CouponCell(
slots: DefaultSlots,
ctx: RenderContext<CouponCellProps>
) {
const valueClass = props.coupons[+props.chosenCoupon] ? bem('selected') : '';
const selected = props.coupons[+props.chosenCoupon];
const value = formatValue(props);
return (
@@ -49,7 +49,7 @@ function CouponCell(
title={props.title || t('title')}
border={props.border}
isLink={props.editable}
valueClass={valueClass}
valueClass={bem('value', { selected })}
{...inherit(ctx, true)}
/>
);