asiaint-lowcode 3.0.1 → 3.0.2
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/asiaint-lowcode.js +1 -1
- package/dist/asiaint-lowcode.umd.cjs +54 -54
- package/dist/index.d.ts +21 -2
- package/dist/lazy/{Card-Dsd1ydt8.js → Card-CgInTORA.js} +1 -1
- package/dist/lazy/{Cascader-D8pYveJW.js → Cascader-Ccrs8-ka.js} +1 -1
- package/dist/lazy/{Checkbox-DmNO76gt.js → Checkbox-CWWOw1FI.js} +2 -2
- package/dist/lazy/{Collapse-DahOWaTk.js → Collapse-ckoNfqa8.js} +1 -1
- package/dist/lazy/{Component-DQcpUpZd.js → Component-DjRLGRhq.js} +1 -1
- package/dist/lazy/{Component-C1EGoisS.js → Component-EKiCae99.js} +1 -1
- package/dist/lazy/{Component-D08n0RnK.js → Component-JcjpPNlK.js} +1 -1
- package/dist/lazy/{Component-DvJBRtpM.js → Component-QDqteMg2.js} +1 -1
- package/dist/lazy/{Component-DT5ozzlx.js → Component-ms58oJYi.js} +1 -1
- package/dist/lazy/{Custom-BVgwtYPa.js → Custom-agCeCFgq.js} +1 -1
- package/dist/lazy/{DatePicker-Ll1tF6zR.js → DatePicker-2RgUNM5p.js} +1 -1
- package/dist/lazy/{FormList-DPko3piR.js → FormList-DLFUVPXo.js} +1 -1
- package/dist/lazy/{Grid-C1DCBRVh.js → Grid-CEKhkcz0.js} +1 -1
- package/dist/lazy/{Inline-C_WTGbGy.js → Inline-D_8y_g96.js} +1 -1
- package/dist/lazy/{JsonEdit-C79HaljB.js → JsonEdit-BeSmvWhK.js} +1 -1
- package/dist/lazy/{ObjGroup-B8XE-sZH.js → ObjGroup-Boc4ftOK.js} +1 -1
- package/dist/lazy/{Radio-W5d4ZrBI.js → Radio-B8y5htdt.js} +2 -2
- package/dist/lazy/{SearchSelect-BsBXbAx_.js → SearchSelect-BHyhol4D.js} +2 -2
- package/dist/lazy/Select-qvIWMCjT.js +64 -0
- package/dist/lazy/{Tabs-CT8toQRa.js → Tabs-Dcwprp8J.js} +1 -1
- package/dist/lazy/{TextArea-N0w87ek_.js → TextArea-C5FB32gt.js} +1 -1
- package/dist/lazy/{index-DuQxCd3z.js → index-DfCg75rA.js} +2548 -2539
- package/dist/lazy/useSelect-CwRNgHGU.js +58 -0
- package/dist/style.css +1 -1
- package/package.json +2 -2
- package/dist/lazy/Select-COqlMsmt.js +0 -68
- package/dist/lazy/useSelect-DdH13YK3.js +0 -55
package/package.json
CHANGED
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "asiaint-lowcode",
|
|
3
|
-
"version": "3.0.
|
|
3
|
+
"version": "3.0.2",
|
|
4
4
|
"private": false,
|
|
5
5
|
"type": "module",
|
|
6
6
|
"scripts": {
|
|
7
7
|
"build": "vite build",
|
|
8
8
|
"v": "npm version patch",
|
|
9
|
-
"release": "vite build &&
|
|
9
|
+
"release": "vite build && npm publish"
|
|
10
10
|
},
|
|
11
11
|
"peerDependencies": {
|
|
12
12
|
"vue": "^3.2.0",
|
|
@@ -1,68 +0,0 @@
|
|
|
1
|
-
import { defineComponent as _, mergeModels as B, useModel as S, inject as g, resolveComponent as K, resolveDirective as A, unref as i, openBlock as o, createElementBlock as p, toDisplayString as f, withDirectives as F, createBlock as h, mergeProps as j, withCtx as M, Fragment as w, renderList as I, createTextVNode as N } from "vue";
|
|
2
|
-
import { u as P } from "./index-DuQxCd3z.js";
|
|
3
|
-
import { u as E } from "./useSelect-DdH13YK3.js";
|
|
4
|
-
const L = { key: 0 }, O = { key: 0 }, T = { key: 1 }, z = /* @__PURE__ */ _({
|
|
5
|
-
__name: "Select",
|
|
6
|
-
props: /* @__PURE__ */ B({
|
|
7
|
-
options: { default: () => [] },
|
|
8
|
-
multiple: { type: Boolean, default: !1 },
|
|
9
|
-
mode: { default: "static" },
|
|
10
|
-
labelKey: { default: "label" },
|
|
11
|
-
valueKey: { default: "value" },
|
|
12
|
-
disabledKey: { default: "disabled" },
|
|
13
|
-
apiParams: {},
|
|
14
|
-
dependentFields: {},
|
|
15
|
-
name: { default: "" },
|
|
16
|
-
onChange: {}
|
|
17
|
-
}, {
|
|
18
|
-
modelValue: { type: [String, Number, Boolean, Array] },
|
|
19
|
-
modelModifiers: {}
|
|
20
|
-
}),
|
|
21
|
-
emits: ["update:modelValue"],
|
|
22
|
-
setup(v) {
|
|
23
|
-
const s = v, n = S(v, "modelValue"), m = P(), y = g("ruleModule", void 0), k = g("pageMethodMap", {}), C = (e) => {
|
|
24
|
-
const { valueKey: d = "value", multiple: c, name: r } = s;
|
|
25
|
-
let a = {};
|
|
26
|
-
c && Array.isArray(e) ? a = u.value.filter((t) => e.includes(t[d])) : a = u.value.find((t) => t[d] === e) || {}, m.selectData && r && m.updateSelectData(r, a), s.onChange && y && y[s.onChange](k, e, a);
|
|
27
|
-
}, { currentOptions: u, loading: V } = E(s);
|
|
28
|
-
return (e, d) => {
|
|
29
|
-
var t;
|
|
30
|
-
const c = K("el-option"), r = K("el-select"), a = A("loading");
|
|
31
|
-
return i(m).read ? (o(), p("div", L, [
|
|
32
|
-
e.multiple ? (o(), p("div", O, f(n.value && n.value.map((l) => {
|
|
33
|
-
var b;
|
|
34
|
-
return (b = i(u).find((D) => D[e.valueKey] === l)) == null ? void 0 : b[e.labelKey];
|
|
35
|
-
}).join("、")), 1)) : (o(), p("div", T, f((t = i(u).find((l) => l[e.valueKey] === n.value)) == null ? void 0 : t[e.labelKey]), 1))
|
|
36
|
-
])) : F((o(), h(r, j({
|
|
37
|
-
key: 1,
|
|
38
|
-
modelValue: n.value,
|
|
39
|
-
"onUpdate:modelValue": d[0] || (d[0] = (l) => n.value = l)
|
|
40
|
-
}, e.$attrs, {
|
|
41
|
-
onChange: C,
|
|
42
|
-
multiple: e.multiple,
|
|
43
|
-
clearable: "",
|
|
44
|
-
filterable: ""
|
|
45
|
-
}), {
|
|
46
|
-
default: M(() => [
|
|
47
|
-
(o(!0), p(w, null, I(i(u), (l) => (o(), h(c, {
|
|
48
|
-
key: l[e.valueKey],
|
|
49
|
-
label: l[e.labelKey],
|
|
50
|
-
value: l[e.valueKey],
|
|
51
|
-
disabled: l[e.disabledKey]
|
|
52
|
-
}, {
|
|
53
|
-
default: M(() => [
|
|
54
|
-
N(f(l[e.labelKey]), 1)
|
|
55
|
-
]),
|
|
56
|
-
_: 2
|
|
57
|
-
}, 1032, ["label", "value", "disabled"]))), 128))
|
|
58
|
-
]),
|
|
59
|
-
_: 1
|
|
60
|
-
}, 16, ["modelValue", "multiple"])), [
|
|
61
|
-
[a, i(V)]
|
|
62
|
-
]);
|
|
63
|
-
};
|
|
64
|
-
}
|
|
65
|
-
});
|
|
66
|
-
export {
|
|
67
|
-
z as default
|
|
68
|
-
};
|
|
@@ -1,55 +0,0 @@
|
|
|
1
|
-
import { inject as A, ref as v, onMounted as D, watch as o } from "vue";
|
|
2
|
-
import { $ as g, u as q, l as y } from "./index-DuQxCd3z.js";
|
|
3
|
-
import "element-plus";
|
|
4
|
-
const F = () => {
|
|
5
|
-
const { fetchOptionsFn: t } = A(g);
|
|
6
|
-
return t;
|
|
7
|
-
}, E = (t) => {
|
|
8
|
-
const i = q(), c = F(), a = v([]), l = v(!1), s = y.debounce(async () => {
|
|
9
|
-
if (!c || !t.apiParams) return;
|
|
10
|
-
const { apiParams: e } = t;
|
|
11
|
-
l.value = !0;
|
|
12
|
-
try {
|
|
13
|
-
const n = await c(e);
|
|
14
|
-
a.value = [...a.value, ...n];
|
|
15
|
-
} finally {
|
|
16
|
-
l.value = !1;
|
|
17
|
-
}
|
|
18
|
-
}, 300);
|
|
19
|
-
D(() => {
|
|
20
|
-
const { mode: e, options: n = [] } = t;
|
|
21
|
-
e === "static" && (a.value = n), e === "remote" && s();
|
|
22
|
-
}), o(
|
|
23
|
-
() => t.apiParams,
|
|
24
|
-
(e, n) => {
|
|
25
|
-
y.isEqual(e, n) || (a.value = [], s());
|
|
26
|
-
}
|
|
27
|
-
), o(
|
|
28
|
-
() => t.options,
|
|
29
|
-
(e = []) => {
|
|
30
|
-
t.mode === "static" && (a.value = e);
|
|
31
|
-
}
|
|
32
|
-
), o(
|
|
33
|
-
() => t.mode,
|
|
34
|
-
(e) => {
|
|
35
|
-
e === "static" && (a.value = t.options || []), e === "remote" && (a.value = [], s());
|
|
36
|
-
}
|
|
37
|
-
);
|
|
38
|
-
const { mode: h, dependentFields: f } = t;
|
|
39
|
-
if (h === "remote" && Array.isArray(f))
|
|
40
|
-
for (const e of f)
|
|
41
|
-
o(
|
|
42
|
-
() => i.formValues[e],
|
|
43
|
-
(n, m) => {
|
|
44
|
-
s();
|
|
45
|
-
}
|
|
46
|
-
);
|
|
47
|
-
return { selectChange: (e) => {
|
|
48
|
-
const { valueKey: n = "value", multiple: m, name: d } = t;
|
|
49
|
-
let u = {};
|
|
50
|
-
m && Array.isArray(e) ? u = a.value.filter((r) => e.includes(r[n])) : u = a.value.find((r) => r[n] === e) || {}, i.selectData && d && i.updateSelectData(d, u);
|
|
51
|
-
}, currentOptions: a, loading: l, fetchData: s };
|
|
52
|
-
};
|
|
53
|
-
export {
|
|
54
|
-
E as u
|
|
55
|
-
};
|