@das-fed/upf-ui 6.4.0-dev.142 → 6.4.0-dev.143
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/package.json +5 -5
- package/packages/components/form/index.js +49 -42
- package/packages/components/form/index.js.gz +0 -0
- package/packages/components/form/style.css +1 -1
- package/packages/components/form-item/index.js +334 -333
- package/packages/components/form-item/index.js.gz +0 -0
- package/packages/components/form-item/style.css +1 -1
- package/packages/components/form-item/style.css.gz +0 -0
- package/packages/components/select/index.js +75 -75
- package/packages/components/select/index.js.gz +0 -0
- package/packages/components/select/style.css +1 -1
- package/packages/components/select/style.css.gz +0 -0
- package/packages/components/table/index.js +3594 -3543
- package/packages/components/table/index.js.gz +0 -0
- package/packages/components/table/src/table-column/index.vue.d.ts +14 -11
- package/packages/components/table/src/type.d.ts +3 -0
- package/packages/components/table/style.css +1 -1
- package/packages/components/table/style.css.gz +0 -0
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@das-fed/upf-ui",
|
|
3
|
-
"version": "6.4.0-dev.
|
|
3
|
+
"version": "6.4.0-dev.143",
|
|
4
4
|
"description": "",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"main": "./index.js",
|
|
@@ -26,7 +26,7 @@
|
|
|
26
26
|
"@antv/x6-plugin-snapline": "^2.1.7",
|
|
27
27
|
"@antv/x6-plugin-transform": "^2.1.8",
|
|
28
28
|
"@antv/x6-vue-shape": "^2.1.2",
|
|
29
|
-
"@das-fed/upf-ui": "6.4.0-dev.
|
|
29
|
+
"@das-fed/upf-ui": "6.4.0-dev.143",
|
|
30
30
|
"@element-plus/icons-vue": "^2.3.1",
|
|
31
31
|
"@types/lodash": "^4.14.194",
|
|
32
32
|
"@types/lodash-es": "^4.17.9",
|
|
@@ -56,9 +56,9 @@
|
|
|
56
56
|
"vue-tsc": "^2.0.29"
|
|
57
57
|
},
|
|
58
58
|
"dependencies": {
|
|
59
|
-
"@das-fed/upf-cli": "6.4.0-dev.
|
|
60
|
-
"@das-fed/upf-utils": "6.4.0-dev.
|
|
61
|
-
"@das-fed/upf-web": "6.4.0-dev.
|
|
59
|
+
"@das-fed/upf-cli": "6.4.0-dev.143",
|
|
60
|
+
"@das-fed/upf-utils": "6.4.0-dev.143",
|
|
61
|
+
"@das-fed/upf-web": "6.4.0-dev.143",
|
|
62
62
|
"@types/markdown-it": "^14.1.2",
|
|
63
63
|
"@wangeditor-next/editor": "5.6.31",
|
|
64
64
|
"@wangeditor-next/editor-for-vue": "5.1.14",
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import '@das-fed/upf-ui/packages/components/form/style.css';
|
|
2
|
-
import { defineComponent as
|
|
3
|
-
import { withInstall as
|
|
2
|
+
import { defineComponent as I, ref as f, reactive as d, computed as r, provide as R, createElementBlock as x, openBlock as S, normalizeStyle as M, normalizeClass as z, renderSlot as B } from "vue";
|
|
3
|
+
import { withInstall as $ } from "@das-fed/upf-utils/with-install/index";
|
|
4
4
|
import "@das-fed/upf-ui/packages/global/theme";
|
|
5
|
-
const
|
|
5
|
+
const k = /* @__PURE__ */ I({
|
|
6
6
|
__name: "Index",
|
|
7
7
|
props: {
|
|
8
8
|
labelLength: { default: 4 },
|
|
@@ -20,64 +20,71 @@ const $ = /* @__PURE__ */ y({
|
|
|
20
20
|
autoMarginRight: { type: Boolean, default: !1 },
|
|
21
21
|
size: { default: "default" }
|
|
22
22
|
},
|
|
23
|
-
setup(o, { expose:
|
|
24
|
-
const
|
|
25
|
-
let l = [];
|
|
26
|
-
|
|
23
|
+
setup(o, { expose: s }) {
|
|
24
|
+
const a = o, n = f();
|
|
25
|
+
let l = d([]);
|
|
26
|
+
const c = r(() => l.filter((e) => {
|
|
27
|
+
var t;
|
|
28
|
+
return (t = e.formItemProps) == null ? void 0 : t.required;
|
|
29
|
+
}).length > 0), m = r(() => l.filter((e) => {
|
|
30
|
+
var t;
|
|
31
|
+
return (t = e.formItemProps) == null ? void 0 : t.helpMessage;
|
|
32
|
+
}).length > 0);
|
|
33
|
+
R("DasForm", d({ props: a, addField: (e) => {
|
|
27
34
|
l.push(e);
|
|
28
35
|
}, removeField: (e) => {
|
|
29
|
-
l = l.filter((
|
|
30
|
-
} }));
|
|
31
|
-
const
|
|
32
|
-
const
|
|
33
|
-
e(
|
|
34
|
-
},
|
|
35
|
-
const
|
|
36
|
-
|
|
37
|
-
},
|
|
36
|
+
l = l.filter((t) => t.timeStamp !== e.timeStamp);
|
|
37
|
+
}, hasRequiredFormItem: c, hasHelpMessageFormItem: m }));
|
|
38
|
+
const u = async (e) => {
|
|
39
|
+
const t = await g();
|
|
40
|
+
e(t);
|
|
41
|
+
}, p = async (e, t) => {
|
|
42
|
+
const _ = await l.find((i) => i.propName === e && i.rules.length > 0).validate();
|
|
43
|
+
t(_);
|
|
44
|
+
}, g = async () => {
|
|
38
45
|
let e = !0;
|
|
39
|
-
for (const
|
|
40
|
-
|
|
46
|
+
for (const t of l)
|
|
47
|
+
t.propName && t.rules.length > 0 && (await t.validate() || (e = !1));
|
|
41
48
|
return e;
|
|
42
|
-
},
|
|
49
|
+
}, h = () => {
|
|
43
50
|
l.forEach((e) => {
|
|
44
51
|
e.resetError();
|
|
45
52
|
});
|
|
46
|
-
},
|
|
53
|
+
}, v = r(() => ({
|
|
47
54
|
display: "grid",
|
|
48
|
-
gridTemplateColumns: `repeat(${
|
|
49
|
-
gridColumnGap:
|
|
50
|
-
})),
|
|
51
|
-
alignItems:
|
|
52
|
-
...
|
|
55
|
+
gridTemplateColumns: `repeat(${a.cols}, ${a.contentWidth && a.contentWidth !== "auto" ? "min-content" : "1fr"})`,
|
|
56
|
+
gridColumnGap: a.cols && a.autoMarginRight ? a.marginRight : void 0
|
|
57
|
+
})), y = r(() => ({
|
|
58
|
+
alignItems: a.alignItems,
|
|
59
|
+
...a.cols && a.alignType === "vertical" ? v.value : {}
|
|
53
60
|
}));
|
|
54
|
-
return
|
|
55
|
-
validate:
|
|
56
|
-
validateField:
|
|
57
|
-
resetField:
|
|
58
|
-
}), (e,
|
|
61
|
+
return s({
|
|
62
|
+
validate: u,
|
|
63
|
+
validateField: p,
|
|
64
|
+
resetField: h
|
|
65
|
+
}), (e, t) => (S(), x(
|
|
59
66
|
"div",
|
|
60
67
|
{
|
|
61
|
-
class:
|
|
68
|
+
class: z(["das-ui-form", { horizontal: e.alignType === "horizontal" }]),
|
|
62
69
|
ref_key: "$formRef",
|
|
63
70
|
ref: n,
|
|
64
|
-
style:
|
|
71
|
+
style: M(y.value)
|
|
65
72
|
},
|
|
66
73
|
[
|
|
67
|
-
|
|
74
|
+
B(e.$slots, "default", {}, void 0, !0)
|
|
68
75
|
],
|
|
69
76
|
6
|
|
70
77
|
/* CLASS, STYLE */
|
|
71
78
|
));
|
|
72
79
|
}
|
|
73
|
-
}),
|
|
74
|
-
const
|
|
75
|
-
for (const [n, l] of
|
|
76
|
-
|
|
77
|
-
return
|
|
78
|
-
},
|
|
80
|
+
}), w = (o, s) => {
|
|
81
|
+
const a = o.__vccOpts || o;
|
|
82
|
+
for (const [n, l] of s)
|
|
83
|
+
a[n] = l;
|
|
84
|
+
return a;
|
|
85
|
+
}, C = /* @__PURE__ */ w(k, [["__scopeId", "data-v-e455d465"]]), W = $(C), q = () => f(null);
|
|
79
86
|
export {
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
87
|
+
W as DasForm,
|
|
88
|
+
q as DasFormRef,
|
|
89
|
+
W as default
|
|
83
90
|
};
|
|
Binary file
|
|
@@ -1 +1 @@
|
|
|
1
|
-
.das-ui-form[data-v-
|
|
1
|
+
.das-ui-form[data-v-e455d465]{display:flex;flex-direction:column;align-content:flex-start}.das-ui-form.horizontal[data-v-e455d465]{flex-direction:row;flex-wrap:wrap}.das-ui-form.grid[data-v-e455d465]{display:grid;grid-template-columns:repeat(var(--cols),var(--content-width, 1fr));column-gap:var(--gap)}
|