cleek 2.3.46 → 2.3.47
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.
- package/dist/cleek.es.js +17 -13
- package/dist/cleek.umd.js +8 -8
- package/dist/style.css +1 -1
- package/package.json +1 -1
package/dist/cleek.es.js
CHANGED
|
@@ -19000,13 +19000,15 @@ const _sfc_main$4 = /* @__PURE__ */ defineComponent({
|
|
|
19000
19000
|
props: {
|
|
19001
19001
|
modelValue: { default: null, type: [Boolean, Number, Object, Array, String] },
|
|
19002
19002
|
prop: { type: String, default: void 0 },
|
|
19003
|
-
|
|
19003
|
+
reduceValueProp: { type: String, default: "id" },
|
|
19004
|
+
reduceNameProp: { type: String, default: "name" },
|
|
19004
19005
|
autofocus: { type: Boolean, default: false },
|
|
19005
19006
|
noDataText: { type: String, default: "No se encontr\xF3 nada" },
|
|
19006
19007
|
notReduce: { type: Boolean, default: false },
|
|
19008
|
+
notReduceValue: { type: Boolean, default: false },
|
|
19007
19009
|
options: { type: Array, default: () => [] },
|
|
19008
|
-
reduceNameFunction: { type: Function, default:
|
|
19009
|
-
|
|
19010
|
+
reduceNameFunction: { type: Function, default: void 0 },
|
|
19011
|
+
reduceValueFunction: { type: Function, default: void 0 },
|
|
19010
19012
|
notClearable: { type: Boolean, default: false },
|
|
19011
19013
|
clearValue: { type: [Boolean, String], default: "auto" },
|
|
19012
19014
|
searchable: { type: [Boolean, String], default: "auto" },
|
|
@@ -19099,7 +19101,7 @@ const _sfc_main$4 = /* @__PURE__ */ defineComponent({
|
|
|
19099
19101
|
if (!props.modelValue)
|
|
19100
19102
|
return null;
|
|
19101
19103
|
if (props.modelValue.constructor === Array) {
|
|
19102
|
-
return props.modelValue.length
|
|
19104
|
+
return props.modelValue.length === 0;
|
|
19103
19105
|
}
|
|
19104
19106
|
return Object.keys(props.modelValue).length === 0;
|
|
19105
19107
|
default:
|
|
@@ -19112,17 +19114,19 @@ const _sfc_main$4 = /* @__PURE__ */ defineComponent({
|
|
|
19112
19114
|
function onChange2(event) {
|
|
19113
19115
|
emits("change", event);
|
|
19114
19116
|
}
|
|
19115
|
-
function
|
|
19116
|
-
if (
|
|
19117
|
-
props.
|
|
19118
|
-
|
|
19117
|
+
function getOptionValue(option) {
|
|
19118
|
+
if (props.reduceValueFunction)
|
|
19119
|
+
return props.reduceValueFunction(option);
|
|
19120
|
+
if (props.notReduceValue || props.notReduce)
|
|
19121
|
+
return option;
|
|
19122
|
+
return option[props.reduceValueProp];
|
|
19119
19123
|
}
|
|
19120
19124
|
function getOptionName(option) {
|
|
19121
|
-
if (props.prop || props.reduceKeyProp)
|
|
19122
|
-
return option[props.prop || props.reduceKeyProp];
|
|
19123
19125
|
if (props.reduceNameFunction)
|
|
19124
19126
|
return props.reduceNameFunction(option);
|
|
19125
|
-
|
|
19127
|
+
if (props.notReduce)
|
|
19128
|
+
return option;
|
|
19129
|
+
return option[props.prop || props.reduceNameProp];
|
|
19126
19130
|
}
|
|
19127
19131
|
function setFocus() {
|
|
19128
19132
|
}
|
|
@@ -19149,7 +19153,7 @@ const _sfc_main$4 = /* @__PURE__ */ defineComponent({
|
|
|
19149
19153
|
}, [
|
|
19150
19154
|
(openBlock(true), createElementBlock(Fragment, null, renderList(unref$1(filteredOptions), (option) => {
|
|
19151
19155
|
return openBlock(), createElementBlock("option", {
|
|
19152
|
-
value:
|
|
19156
|
+
value: getOptionValue(option),
|
|
19153
19157
|
key: option
|
|
19154
19158
|
}, toDisplayString(getOptionName(option)), 9, _hoisted_1$4);
|
|
19155
19159
|
}), 128))
|
|
@@ -19160,7 +19164,7 @@ const _sfc_main$4 = /* @__PURE__ */ defineComponent({
|
|
|
19160
19164
|
};
|
|
19161
19165
|
}
|
|
19162
19166
|
});
|
|
19163
|
-
var ckSelect = /* @__PURE__ */ _export_sfc(_sfc_main$4, [["__scopeId", "data-v-
|
|
19167
|
+
var ckSelect = /* @__PURE__ */ _export_sfc(_sfc_main$4, [["__scopeId", "data-v-0a65ade3"]]);
|
|
19164
19168
|
var ckSwitch_vue_vue_type_style_index_0_scoped_true_lang = "";
|
|
19165
19169
|
const _withScopeId = (n) => (pushScopeId("data-v-7e2f20c4"), n = n(), popScopeId(), n);
|
|
19166
19170
|
const _hoisted_1$3 = ["disabled"];
|