@hybridcore/ui 1.4.36 → 1.4.38
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/{DialogContent-B0_-g7B0.js → DialogContent-CtA2aNum.js} +1 -1
- package/dist/{Modal-CJn-Bqyo.js → Modal-DzZo-vlm.js} +1 -0
- package/dist/{Select-DwAJxKTN.js → Select-ush_fSWy.js} +1 -1
- package/dist/{TextField-BAXUnwnR.js → TextField-BjFXx91l.js} +1 -1
- package/dist/components/confirm/dialog.js +2 -2
- package/dist/components/confirm/index.js +1 -1
- package/dist/components/context-menu/index.js +118 -118
- package/dist/components/instance-form/components/composite-list/index.js +1 -1
- package/dist/components/instance-form/components/variable/index.js +3 -3
- package/dist/components/instance-form/components/variables/index.js +1 -1
- package/dist/components/property-mapping/index.js +1 -1
- package/dist/components/range-selector/components/composite-list-range/index.js +1 -1
- package/dist/components/range-selector/components/date-range/index.js +1 -1
- package/dist/components/range-selector/index.js +1 -1
- package/dist/components/template-filters/components/filter/index.js +27 -23
- package/dist/components/template-form/components/property-list/index.js +3 -3
- package/dist/components/template-form/components/property-list/property-list-form.js +3 -3
- package/dist/components/template-form/components/recognition-property-list/index.js +2 -2
- package/dist/components/template-form/components/recognition-property-list/recognition-property-list-form.js +2 -2
- package/dist/components/template-form/index.js +2 -2
- package/dist/components/template-property-filters/property.js +1 -1
- package/dist/components/tree-select/index.js +51 -48
- package/dist/components/treeview-filter/index.js +55 -591
- package/dist/components/treeview-filter/item/index.js +30 -34
- package/dist/components/treeview-filter/item/styled.js +14 -13
- package/dist/components/treeview-filter/item-label/index.js +1 -1
- package/dist/{dialog-DPGR2gik.js → dialog-DrVArHYg.js} +1 -1
- package/dist/{index-RfDWDd66.js → index-CAaDu0NI.js} +1979 -2071
- package/dist/{index-B_GNCJdV.js → index-D2tF2-ya.js} +2 -2
- package/dist/main.d.ts +6 -1
- package/dist/main.js +1 -1
- package/dist/{property-list-form-DgmTiBvu.js → property-list-form-CLSTkOmv.js} +2 -2
- package/package.json +2 -2
|
@@ -1,70 +1,73 @@
|
|
|
1
|
-
import { jsxs as
|
|
2
|
-
import
|
|
3
|
-
import { TreeViewFilter as
|
|
4
|
-
import
|
|
5
|
-
import { flattenNestedTemplates as
|
|
6
|
-
import { F as
|
|
7
|
-
import { S as j } from "../../Select-
|
|
1
|
+
import { jsxs as h, Fragment as W, jsx as o } from "react/jsx-runtime";
|
|
2
|
+
import u from "react";
|
|
3
|
+
import { TreeViewFilter as _ } from "../treeview-filter/index.js";
|
|
4
|
+
import s from "lodash";
|
|
5
|
+
import { flattenNestedTemplates as b } from "../../utils/ontology.js";
|
|
6
|
+
import { F as A, I as M } from "../../InputLabel-ClDXuWBr.js";
|
|
7
|
+
import { S as j } from "../../Select-ush_fSWy.js";
|
|
8
8
|
import { M as B } from "../../MenuItem-Lcjh1XlV.js";
|
|
9
|
-
import { D as k, a as w, b as L } from "../../DialogContent-
|
|
9
|
+
import { D as k, a as w, b as L } from "../../DialogContent-CtA2aNum.js";
|
|
10
10
|
import { B as N } from "../../Button-jy67CcTH.js";
|
|
11
11
|
const U = ({
|
|
12
12
|
data: m,
|
|
13
|
-
label:
|
|
14
|
-
selected:
|
|
15
|
-
disabled:
|
|
16
|
-
idKey:
|
|
17
|
-
variant:
|
|
18
|
-
onChange:
|
|
13
|
+
label: c,
|
|
14
|
+
selected: r,
|
|
15
|
+
disabled: S,
|
|
16
|
+
idKey: i = "id",
|
|
17
|
+
variant: g = "outlined",
|
|
18
|
+
onChange: D
|
|
19
19
|
}) => {
|
|
20
|
-
const [
|
|
21
|
-
(
|
|
22
|
-
) : [], [
|
|
23
|
-
|
|
24
|
-
},
|
|
25
|
-
|
|
26
|
-
},
|
|
27
|
-
|
|
28
|
-
},
|
|
29
|
-
|
|
20
|
+
const [v, x] = u.useState(!1), [E, d] = u.useState([]), f = b(m), p = u.useMemo(() => s.isArray(r) ? r.map(
|
|
21
|
+
(n) => f.find((e) => String(s.get(e, i)) === n)
|
|
22
|
+
) : [], [r, f]), T = (n, e) => {
|
|
23
|
+
D(n, e);
|
|
24
|
+
}, F = () => {
|
|
25
|
+
x(!0), O();
|
|
26
|
+
}, C = () => {
|
|
27
|
+
x(!1);
|
|
28
|
+
}, I = (n, e, l) => {
|
|
29
|
+
d(l ? (a) => [
|
|
30
|
+
...a.filter((t) => t !== e),
|
|
31
|
+
e
|
|
32
|
+
] : (a) => a.filter((t) => t !== e));
|
|
30
33
|
}, O = () => {
|
|
31
|
-
const
|
|
32
|
-
|
|
33
|
-
const
|
|
34
|
-
|
|
35
|
-
}),
|
|
34
|
+
const n = [];
|
|
35
|
+
p.length > 0 && p.forEach((e) => {
|
|
36
|
+
const l = e == null ? void 0 : e.parentKeys, a = f.filter((t) => l == null ? void 0 : l.includes(t.templateKey)).map((t) => String(s.get(t, i)));
|
|
37
|
+
n.push(...a);
|
|
38
|
+
}), d(n);
|
|
36
39
|
};
|
|
37
|
-
return /* @__PURE__ */
|
|
38
|
-
/* @__PURE__ */
|
|
39
|
-
|
|
40
|
-
/* @__PURE__ */
|
|
40
|
+
return /* @__PURE__ */ h(W, { children: [
|
|
41
|
+
/* @__PURE__ */ h(A, { variant: g, fullWidth: !0, children: [
|
|
42
|
+
c !== void 0 && /* @__PURE__ */ o(M, { id: "select-label", children: c }),
|
|
43
|
+
/* @__PURE__ */ o(
|
|
41
44
|
j,
|
|
42
45
|
{
|
|
43
|
-
label:
|
|
44
|
-
variant:
|
|
46
|
+
label: c,
|
|
47
|
+
variant: g,
|
|
45
48
|
id: "select",
|
|
46
49
|
labelId: "select-label",
|
|
47
|
-
value:
|
|
50
|
+
value: r,
|
|
48
51
|
open: !1,
|
|
49
|
-
onOpen:
|
|
50
|
-
children:
|
|
52
|
+
onOpen: F,
|
|
53
|
+
children: p.length > 0 && p.map((n, e) => /* @__PURE__ */ o(B, { value: s.get(n, i) ?? "", children: n == null ? void 0 : n.name }, e))
|
|
51
54
|
}
|
|
52
55
|
)
|
|
53
56
|
] }),
|
|
54
|
-
/* @__PURE__ */
|
|
55
|
-
/* @__PURE__ */
|
|
56
|
-
|
|
57
|
+
/* @__PURE__ */ h(k, { open: v, onClose: C, fullWidth: !0, maxWidth: "sm", children: [
|
|
58
|
+
/* @__PURE__ */ o(w, { sx: { p: 1, pt: 2 }, children: /* @__PURE__ */ o(
|
|
59
|
+
_,
|
|
57
60
|
{
|
|
58
61
|
data: m,
|
|
59
|
-
selected:
|
|
60
|
-
disabled:
|
|
61
|
-
expanded:
|
|
62
|
-
idKey:
|
|
63
|
-
|
|
64
|
-
onChange:
|
|
62
|
+
selected: s.isArray(r) ? r : void 0,
|
|
63
|
+
disabled: S,
|
|
64
|
+
expanded: E,
|
|
65
|
+
idKey: i,
|
|
66
|
+
onExpansionToggle: I,
|
|
67
|
+
onChange: T
|
|
65
68
|
}
|
|
66
69
|
) }),
|
|
67
|
-
/* @__PURE__ */
|
|
70
|
+
/* @__PURE__ */ o(L, { children: /* @__PURE__ */ o(N, { onClick: C, variant: "contained", fullWidth: !0, children: "OK" }) })
|
|
68
71
|
] })
|
|
69
72
|
] });
|
|
70
73
|
};
|