@v-c/select 1.0.6 → 1.0.7
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -110,7 +110,7 @@ var MultipleContent = /* @__PURE__ */ (0, vue.defineComponent)((props, { expose
|
|
|
110
110
|
};
|
|
111
111
|
return () => {
|
|
112
112
|
const { inputProps } = props;
|
|
113
|
-
const prefixNode = !displayValues.value.length &&
|
|
113
|
+
const prefixNode = !displayValues.value.length && !inputValue.value ? () => (0, vue.createVNode)(require_Placeholder.default, null, null) : null;
|
|
114
114
|
const suffixNode = () => (0, vue.createVNode)(require_Input.default, (0, vue.mergeProps)({
|
|
115
115
|
"ref": inputRef,
|
|
116
116
|
"disabled": disabled.value,
|
|
@@ -104,7 +104,7 @@ var MultipleContent_default = /* @__PURE__ */ defineComponent((props, { expose }
|
|
|
104
104
|
};
|
|
105
105
|
return () => {
|
|
106
106
|
const { inputProps } = props;
|
|
107
|
-
const prefixNode = !displayValues.value.length &&
|
|
107
|
+
const prefixNode = !displayValues.value.length && !inputValue.value ? () => createVNode(Placeholder_default, null, null) : null;
|
|
108
108
|
const suffixNode = () => createVNode(Input_default, mergeProps({
|
|
109
109
|
"ref": inputRef,
|
|
110
110
|
"disabled": disabled.value,
|
|
@@ -10,7 +10,7 @@ function useSearchConfig(showSearch, props, mode) {
|
|
|
10
10
|
return typeof showSearch.value === "object" || mode.value === "combobox" || mode.value === "tags" || mode.value === "multiple" && showSearch.value === void 0 ? true : showSearch.value;
|
|
11
11
|
}), (0, vue.computed)(() => {
|
|
12
12
|
const isObject = typeof showSearch.value === "object";
|
|
13
|
-
|
|
13
|
+
const config = {
|
|
14
14
|
filterOption: filterOption?.value,
|
|
15
15
|
searchValue: searchValue?.value,
|
|
16
16
|
optionFilterProp: optionFilterProp?.value,
|
|
@@ -19,6 +19,8 @@ function useSearchConfig(showSearch, props, mode) {
|
|
|
19
19
|
autoClearSearchValue: autoClearSearchValue?.value,
|
|
20
20
|
...isObject ? showSearch.value : {}
|
|
21
21
|
};
|
|
22
|
+
if (config.autoClearSearchValue === void 0) config.autoClearSearchValue = true;
|
|
23
|
+
return config;
|
|
22
24
|
})];
|
|
23
25
|
}
|
|
24
26
|
exports.default = useSearchConfig;
|
|
@@ -5,7 +5,7 @@ function useSearchConfig(showSearch, props, mode) {
|
|
|
5
5
|
return typeof showSearch.value === "object" || mode.value === "combobox" || mode.value === "tags" || mode.value === "multiple" && showSearch.value === void 0 ? true : showSearch.value;
|
|
6
6
|
}), computed(() => {
|
|
7
7
|
const isObject = typeof showSearch.value === "object";
|
|
8
|
-
|
|
8
|
+
const config = {
|
|
9
9
|
filterOption: filterOption?.value,
|
|
10
10
|
searchValue: searchValue?.value,
|
|
11
11
|
optionFilterProp: optionFilterProp?.value,
|
|
@@ -14,6 +14,8 @@ function useSearchConfig(showSearch, props, mode) {
|
|
|
14
14
|
autoClearSearchValue: autoClearSearchValue?.value,
|
|
15
15
|
...isObject ? showSearch.value : {}
|
|
16
16
|
};
|
|
17
|
+
if (config.autoClearSearchValue === void 0) config.autoClearSearchValue = true;
|
|
18
|
+
return config;
|
|
17
19
|
})];
|
|
18
20
|
}
|
|
19
21
|
export { useSearchConfig as default };
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@v-c/select",
|
|
3
3
|
"type": "module",
|
|
4
|
-
"version": "1.0.
|
|
4
|
+
"version": "1.0.7",
|
|
5
5
|
"description": "",
|
|
6
6
|
"author": "",
|
|
7
7
|
"license": "MIT",
|
|
@@ -31,8 +31,8 @@
|
|
|
31
31
|
"dependencies": {
|
|
32
32
|
"@v-c/overflow": "^1.0.1",
|
|
33
33
|
"@v-c/trigger": "^1.0.5",
|
|
34
|
-
"@v-c/
|
|
35
|
-
"@v-c/
|
|
34
|
+
"@v-c/virtual-list": "^1.0.4",
|
|
35
|
+
"@v-c/util": "^1.0.8"
|
|
36
36
|
},
|
|
37
37
|
"scripts": {
|
|
38
38
|
"build": "vite build",
|