Skip to content

Commit 7f66e63

Browse files
committed
fix: 修复 cr 问题
1 parent cd981cc commit 7f66e63

File tree

2 files changed

+2
-9
lines changed

2 files changed

+2
-9
lines changed

components/select/useCurrentValue.ts

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,8 @@ import type { SelectProps } from './props';
55
export function useCurrentValue(props: SelectProps, emit: (event: 'filter' | 'update:modelValue' | 'focus' | 'blur' | 'change' | 'clear' | 'search' | 'scroll' | 'removeTag' | 'visibleChange', ...args: any[]) => void) {
66
const currentValue = useVModel(props, 'modelValue', emit, {
77
passive: props.passive,
8+
deep: true,
9+
defaultValue: props.multiple ? [] : undefined,
810
});
911

1012
function updateCurrentValue(value: SelectValue | SelectValue[]): SelectValue | SelectValue[] {

docs/.vitepress/components/select/passive.vue

Lines changed: 0 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,5 @@
11
<template>
22
<FSpace vertical>
3-
<!-- <FSelect multiple :multipleLimit="2" :passive="false">
4-
<FOption
5-
v-for="(item, index) in optionList"
6-
:key="index"
7-
:value="item.value"
8-
:label="item.label"
9-
/>
10-
</FSelect> -->
11-
123
<FSelect :modelValue="singleSelect" :passive="false" @change="changeSingle">
134
<FOption
145
v-for="(item, index) in optionList"

0 commit comments

Comments
 (0)