@airpower/web 1.5.2 → 1.5.5
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/main.js +4 -9
- package/package.json +1 -1
package/dist/main.js
CHANGED
|
@@ -14039,7 +14039,6 @@ const _sfc_main$j = /* @__PURE__ */ defineComponent({
|
|
|
14039
14039
|
const formConfig = ref(void 0);
|
|
14040
14040
|
const fieldConfig = ref(void 0);
|
|
14041
14041
|
const fieldName = ref("");
|
|
14042
|
-
const dictionary = ref(void 0);
|
|
14043
14042
|
function onPropsValueUpdated(newProps) {
|
|
14044
14043
|
if (newProps) {
|
|
14045
14044
|
if (newProps.disabled) {
|
|
@@ -14068,6 +14067,9 @@ const _sfc_main$j = /* @__PURE__ */ defineComponent({
|
|
|
14068
14067
|
}
|
|
14069
14068
|
return DateTimeFormatter.FULL_DATE_TIME;
|
|
14070
14069
|
});
|
|
14070
|
+
const dictionary = computed(() => {
|
|
14071
|
+
return props.list ? props.list : formConfig.value && fieldConfig.value?.dictionary ? fieldConfig.value.dictionary.toArray() : void 0;
|
|
14072
|
+
});
|
|
14071
14073
|
function getSwitchColor(status) {
|
|
14072
14074
|
return dictionary.value?.find((item) => !!item.key === status)?.color || "";
|
|
14073
14075
|
}
|
|
@@ -14147,13 +14149,6 @@ const _sfc_main$j = /* @__PURE__ */ defineComponent({
|
|
|
14147
14149
|
emitValue();
|
|
14148
14150
|
emitBlur();
|
|
14149
14151
|
}
|
|
14150
|
-
watch([props.list, props.tree], () => {
|
|
14151
|
-
console.warn("list changed");
|
|
14152
|
-
init();
|
|
14153
|
-
}, {
|
|
14154
|
-
deep: true,
|
|
14155
|
-
immediate: true
|
|
14156
|
-
});
|
|
14157
14152
|
watch(value, () => {
|
|
14158
14153
|
emitValue();
|
|
14159
14154
|
});
|
|
@@ -14241,7 +14236,7 @@ const _sfc_main$j = /* @__PURE__ */ defineComponent({
|
|
|
14241
14236
|
onFocus: emitFocus,
|
|
14242
14237
|
onKeydown: onKeyDown
|
|
14243
14238
|
}, null, 8, ["modelValue", "clearable", "disabled", "format", "placeholder", "prefix-icon", "readonly", "suffix-icon", "value-format"]))
|
|
14244
|
-
], 64)) :
|
|
14239
|
+
], 64)) : dictionary.value ? (openBlock(), createElementBlock(Fragment, { key: 1 }, [
|
|
14245
14240
|
formConfig.value?.switch ? (openBlock(), createBlock(_component_el_switch, {
|
|
14246
14241
|
key: 0,
|
|
14247
14242
|
modelValue: value.value,
|