perf: add truthProp util (#8522)
* perf: add TruthyProp util * chore: rename * chore: upd
This commit is contained in:
@@ -1,7 +1,7 @@
|
||||
import { PropType, defineComponent } from 'vue';
|
||||
|
||||
// Utils
|
||||
import { isDef, createNamespace } from '../utils';
|
||||
import { isDef, truthProp, createNamespace } from '../utils';
|
||||
|
||||
// Components
|
||||
import { Cell } from '../cell';
|
||||
@@ -38,6 +38,8 @@ export default defineComponent({
|
||||
|
||||
props: {
|
||||
title: String,
|
||||
border: truthProp,
|
||||
editable: truthProp,
|
||||
coupons: {
|
||||
type: Array as PropType<CouponInfo[]>,
|
||||
default: () => [],
|
||||
@@ -46,14 +48,6 @@ export default defineComponent({
|
||||
type: String,
|
||||
default: '¥',
|
||||
},
|
||||
border: {
|
||||
type: Boolean,
|
||||
default: true,
|
||||
},
|
||||
editable: {
|
||||
type: Boolean,
|
||||
default: true,
|
||||
},
|
||||
chosenCoupon: {
|
||||
type: [Number, String],
|
||||
default: -1,
|
||||
|
||||
Reference in New Issue
Block a user