perf: add truthProp util (#8522)
* perf: add TruthyProp util * chore: rename * chore: upd
This commit is contained in:
@@ -1,5 +1,5 @@
|
||||
import { nextTick, PropType, reactive, watch, defineComponent } from 'vue';
|
||||
import { createNamespace, extend } from '../utils';
|
||||
import { createNamespace, truthProp, extend } from '../utils';
|
||||
|
||||
// Components
|
||||
import { Tab } from '../tab';
|
||||
@@ -32,6 +32,8 @@ export default defineComponent({
|
||||
|
||||
props: {
|
||||
title: String,
|
||||
closeable: truthProp,
|
||||
swipeable: truthProp,
|
||||
modelValue: [Number, String],
|
||||
fieldNames: Object as PropType<CascaderFieldNames>,
|
||||
placeholder: String,
|
||||
@@ -40,18 +42,10 @@ export default defineComponent({
|
||||
type: Array as PropType<CascaderOption[]>,
|
||||
default: () => [],
|
||||
},
|
||||
closeable: {
|
||||
type: Boolean,
|
||||
default: true,
|
||||
},
|
||||
closeIcon: {
|
||||
type: String,
|
||||
default: 'cross',
|
||||
},
|
||||
swipeable: {
|
||||
type: Boolean,
|
||||
default: true,
|
||||
},
|
||||
},
|
||||
|
||||
emits: ['close', 'change', 'finish', 'update:modelValue'],
|
||||
|
||||
Reference in New Issue
Block a user