@hybridcore/ui 1.3.4 → 1.3.6

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.
Files changed (55) hide show
  1. package/dist/{ButtonBase-DJz-TFGO.js → ButtonBase-D6qhsxB0.js} +7 -8
  2. package/dist/{CardContent-DZnCVGy9.js → CardContent-B8hqgH-I.js} +3 -3
  3. package/dist/{Checkbox-DzmWBCrt.js → Checkbox-BFWhj3s-.js} +6 -6
  4. package/dist/{Collapse-NqW0GIK_.js → Collapse-D_TjnyE5.js} +74 -67
  5. package/dist/DialogContent-BCYm_d1s.js +864 -0
  6. package/dist/{FormControl-aXQs42m6.js → FormControl-BMRUQKHh.js} +55 -55
  7. package/dist/{FormControlLabel-hDa-xf_q.js → FormControlLabel-DENNVXWL.js} +9 -9
  8. package/dist/{IconButton-SnBOFQ43.js → IconButton-D8bwME9t.js} +4 -4
  9. package/dist/{Input-CeVb6kjv.js → Input-Dxzguyp5.js} +5 -5
  10. package/dist/{InputAdornment-fM3loNyx.js → InputAdornment-B8ERE7Zv.js} +4 -4
  11. package/dist/{List-DLIiXc6r.js → List-DEWyK9IO.js} +5 -5
  12. package/dist/{MenuItem-BEW28T9O.js → MenuItem-DstAFfik.js} +12 -12
  13. package/dist/Modal-DNGEQJ1M.js +1267 -0
  14. package/dist/{OutlinedInput-DkzLHRTd.js → OutlinedInput-w2Cj9STF.js} +5 -5
  15. package/dist/{Paper-Dp3qO0cK.js → Paper-BseeergJ.js} +8 -8
  16. package/dist/{Select-Cdmu0dQ4.js → Select-NDq3WyLt.js} +51 -51
  17. package/dist/{Typography-CXe5ytr0.js → Typography-Dg-ROiTA.js} +3 -3
  18. package/dist/components/card/index.js +5 -5
  19. package/dist/components/card/styled.js +1 -1
  20. package/dist/components/collapsible-card/style.js +26 -26
  21. package/dist/components/confirm/dialog.js +5 -5
  22. package/dist/components/container/index.js +6 -6
  23. package/dist/components/context-menu/index.js +604 -191
  24. package/dist/components/data-management/instance-form/components/composite-list/index.js +1 -1
  25. package/dist/components/data-management/instance-form/components/variable/index.js +6 -6
  26. package/dist/components/data-management/instance-form/components/variables/index.js +1 -1
  27. package/dist/components/geometry-picker/index.js +3 -3
  28. package/dist/components/icon-button/index.js +1 -1
  29. package/dist/components/map/styled.js +1 -1
  30. package/dist/components/search-input/index.js +4 -4
  31. package/dist/components/template-property-filters/index.js +1 -1
  32. package/dist/components/template-property-filters/property.js +209 -10
  33. package/dist/components/tree-select/index.js +4 -4
  34. package/dist/components/treeview-filter/index.js +8 -8
  35. package/dist/components/treeview-filter/item/index.js +1 -1
  36. package/dist/components/treeview-filter/item-label/index.js +2 -2
  37. package/dist/{createStyled-liRRhQcN.js → createStyled-B96gjom1.js} +461 -484
  38. package/dist/createSvgIcon-B2WT0K4k.js +87 -0
  39. package/dist/{createSvgIcon-Cl8kMTkx.js → createSvgIcon-BNrb7rDY.js} +3 -3
  40. package/dist/{exactProp-CT2wqJXE.js → exactProp-CI_rjX83.js} +2 -2
  41. package/dist/{index-D9TdkXAs.js → index-B3Oj04nl.js} +5 -5
  42. package/dist/{index-DRy8nExS.js → index-CSfSVkKj.js} +5 -6
  43. package/dist/{listItemTextClasses-BrCbmCR1.js → listItemTextClasses-CFiI_U7B.js} +2 -2
  44. package/dist/main.js +150 -144
  45. package/dist/{styled-Dm8rXzIG.js → styled-cPJbqF0E.js} +24 -24
  46. package/dist/{useTheme-CTuK-wFF.js → useTheme-C-T6Qisa.js} +2 -2
  47. package/dist/{useThemeProps-BXn-nVhw.js → useThemeProps-DeftUmqJ.js} +14 -14
  48. package/dist/{utils-DY9Jk4Ah.js → utils-CCkxV0lZ.js} +15 -15
  49. package/package.json +1 -1
  50. package/dist/DialogContent-D51w7KVX.js +0 -2119
  51. package/dist/ListItem-BkxmqFI8.js +0 -428
  52. package/dist/createSvgIcon-B4TFefhd.js +0 -73
  53. package/dist/property-BsU8ijQF.js +0 -6857
  54. package/dist/requirePropFactory-BItwGLRQ.js +0 -18
  55. package/dist/unsupportedProp-BuVD30Gh.js +0 -9
@@ -3,7 +3,7 @@ import "@mui/material";
3
3
  import "./styled.js";
4
4
  import "@mui/icons-material";
5
5
  import "../../../../../hooks/useToggle.js";
6
- import { C as l } from "../../../../../index-D9TdkXAs.js";
6
+ import { C as l } from "../../../../../index-B3Oj04nl.js";
7
7
  import "react";
8
8
  import "lodash";
9
9
  import "dayjs";
@@ -1,17 +1,17 @@
1
1
  import "react/jsx-runtime";
2
2
  import "lodash";
3
3
  import "dayjs";
4
- import { V as b } from "../../../../../index-D9TdkXAs.js";
4
+ import { V as b } from "../../../../../index-B3Oj04nl.js";
5
5
  import "@mui/material";
6
6
  import "@mui/icons-material";
7
7
  import "../../../../geometry-picker/index.js";
8
8
  import "../../../../phone-input/index.js";
9
9
  import "../../../../date-time-picker/index.js";
10
- import "../../../../../FormControlLabel-hDa-xf_q.js";
11
- import "../../../../../Checkbox-DzmWBCrt.js";
12
- import "../../../../../FormControl-aXQs42m6.js";
13
- import "../../../../../Select-Cdmu0dQ4.js";
14
- import "../../../../../MenuItem-BEW28T9O.js";
10
+ import "../../../../../FormControlLabel-DENNVXWL.js";
11
+ import "../../../../../Checkbox-BFWhj3s-.js";
12
+ import "../../../../../FormControl-BMRUQKHh.js";
13
+ import "../../../../../Select-NDq3WyLt.js";
14
+ import "../../../../../MenuItem-DstAFfik.js";
15
15
  export {
16
16
  b as default
17
17
  };
@@ -1,6 +1,6 @@
1
1
  import { jsx as t, Fragment as i } from "react/jsx-runtime";
2
2
  import l from "react";
3
- import { V as m } from "../../../../../index-D9TdkXAs.js";
3
+ import { V as m } from "../../../../../index-B3Oj04nl.js";
4
4
  import d from "lodash";
5
5
  function h({
6
6
  template: o,
@@ -8,9 +8,9 @@ import y from "./geometry/index.js";
8
8
  import b from "./kml/index.js";
9
9
  import g from "./wkt/index.js";
10
10
  import { IconButton as s, Dialog as E, DialogTitle as W, DialogContent as K } from "@mui/material";
11
- import { F as L, I as z } from "../../FormControl-aXQs42m6.js";
12
- import { I as G } from "../../Input-CeVb6kjv.js";
13
- import { I as w } from "../../InputAdornment-fM3loNyx.js";
11
+ import { F as L, I as z } from "../../FormControl-BMRUQKHh.js";
12
+ import { I as G } from "../../Input-Dxzguyp5.js";
13
+ import { I as w } from "../../InputAdornment-B8ERE7Zv.js";
14
14
  const Q = ({
15
15
  label: c,
16
16
  mapboxAccessToken: r,
@@ -1,6 +1,6 @@
1
1
  import { jsx as t } from "react/jsx-runtime";
2
2
  import { VerticalButton as m, MiniButton as c } from "./styled.js";
3
- import { I as e } from "../../IconButton-SnBOFQ43.js";
3
+ import { I as e } from "../../IconButton-D8bwME9t.js";
4
4
  const a = ({
5
5
  variant: i = "default",
6
6
  startIcon: f,
@@ -1,5 +1,5 @@
1
1
  import { S as r, F as t, a as i, C as s, I as c, T as d } from "../../Text-D6oGbCdi.js";
2
- import { e as f } from "../../createStyled-liRRhQcN.js";
2
+ import { e as f } from "../../createStyled-B96gjom1.js";
3
3
  const g = f(), a = 0.4, w = g("div")(
4
4
  ({ theme: o, cssPosition: n = "absolute" }) => ({
5
5
  position: n,
@@ -2,10 +2,10 @@ import { jsxs as s, jsx as e } from "react/jsx-runtime";
2
2
  import k, { useState as O } from "react";
3
3
  import { Close as m, Search as u } from "@mui/icons-material";
4
4
  import { FilledInput as b, Input as R } from "@mui/material";
5
- import { F as _, I as j } from "../../FormControl-aXQs42m6.js";
6
- import { O as v } from "../../OutlinedInput-DkzLHRTd.js";
7
- import { I as g } from "../../InputAdornment-fM3loNyx.js";
8
- import { I as t } from "../../IconButton-SnBOFQ43.js";
5
+ import { F as _, I as j } from "../../FormControl-BMRUQKHh.js";
6
+ import { O as v } from "../../OutlinedInput-w2Cj9STF.js";
7
+ import { I as g } from "../../InputAdornment-B8ERE7Zv.js";
8
+ import { I as t } from "../../IconButton-D8bwME9t.js";
9
9
  const z = ({
10
10
  defaultValue: x = "",
11
11
  label: I = "Search",
@@ -1,7 +1,7 @@
1
1
  import { jsx as s, Fragment as c } from "react/jsx-runtime";
2
2
  import a from "lodash";
3
3
  import { CollapsibleCard as g } from "../collapsible-card/index.js";
4
- import { P as p } from "../../property-BsU8ijQF.js";
4
+ import p from "./property.js";
5
5
  const K = ({
6
6
  values: f,
7
7
  templates: d,
@@ -1,12 +1,211 @@
1
- import "react/jsx-runtime";
2
- import "react";
3
- import "dayjs";
4
- import "@mui/icons-material";
5
- import "@mui/material";
6
- import "../../FormControlLabel-hDa-xf_q.js";
7
- import "../../Checkbox-DzmWBCrt.js";
8
- import { P as l } from "../../property-BsU8ijQF.js";
9
- import "../../FormControl-aXQs42m6.js";
1
+ import { jsx as a, jsxs as r, Fragment as k } from "react/jsx-runtime";
2
+ import { useState as w } from "react";
3
+ import m from "dayjs";
4
+ import { RadioButtonUnchecked as F, CheckCircle as S, KeyboardArrowUp as Y, KeyboardArrowDown as y } from "@mui/icons-material";
5
+ import { Typography as p, FormLabel as D, FormGroup as L, Button as B } from "@mui/material";
6
+ import { DatePicker as I } from "@mui/x-date-pickers";
7
+ import { T as x, F as C } from "../../FormControlLabel-DENNVXWL.js";
8
+ import { B as f, C as V } from "../../Checkbox-BFWhj3s-.js";
9
+ import { F as T } from "../../FormControl-BMRUQKHh.js";
10
+ function R({
11
+ property: e,
12
+ value: t,
13
+ size: d = "medium",
14
+ onChange: h
15
+ }) {
16
+ var g;
17
+ const u = (o) => (n) => {
18
+ let l = { ...t };
19
+ const i = n.target.type === "checkbox" ? n.target.checked : n.target.value;
20
+ l[o] = String(i), h({
21
+ [n.target.name]: l
22
+ });
23
+ }, M = (o) => {
24
+ var c;
25
+ const n = { ...t }, { value: l, checked: i, name: s } = o.target;
26
+ i ? (n.list || (n.list = []), n.list.push(l)) : n.list = (c = n.list) == null ? void 0 : c.filter((P) => P !== l), h({
27
+ [s]: n
28
+ });
29
+ }, b = (o) => (n) => {
30
+ let l = { ...t };
31
+ l[o] = m(n).format("YYYY-MM-DD"), h({
32
+ [e.propertyId]: l
33
+ });
34
+ };
35
+ if (["string", "text", "list"].includes(e.type))
36
+ return /* @__PURE__ */ a(
37
+ x,
38
+ {
39
+ label: e.name,
40
+ name: e.propertyId,
41
+ value: t.exact ?? e.defaultValue ?? "",
42
+ size: d,
43
+ onChange: u("exact"),
44
+ variant: "standard",
45
+ type: "text",
46
+ multiline: e.type === "text",
47
+ disabled: !e.editable,
48
+ fullWidth: !0,
49
+ sx: { mb: 2 },
50
+ InputLabelProps: {
51
+ sx: { fontSize: 14 }
52
+ }
53
+ }
54
+ );
55
+ if (["integer", "double", "long", "byte"].includes(e.type))
56
+ return /* @__PURE__ */ r(f, { display: "flex", alignItems: "center", mb: 2, children: [
57
+ /* @__PURE__ */ a(
58
+ x,
59
+ {
60
+ label: `${e.name} (Min)`,
61
+ name: e.propertyId,
62
+ value: t.min ?? e.defaultValue ?? "",
63
+ size: d,
64
+ onChange: u("min"),
65
+ variant: "standard",
66
+ type: "number",
67
+ disabled: !e.editable,
68
+ fullWidth: !0,
69
+ InputLabelProps: {
70
+ sx: { fontSize: 14 }
71
+ }
72
+ }
73
+ ),
74
+ /* @__PURE__ */ a(p, { px: 1, children: "-" }),
75
+ /* @__PURE__ */ a(
76
+ x,
77
+ {
78
+ label: `${e.name} (Max)`,
79
+ name: e.propertyId,
80
+ value: t.max ?? e.defaultValue ?? "",
81
+ size: d,
82
+ onChange: u("max"),
83
+ variant: "standard",
84
+ type: "number",
85
+ disabled: !e.editable,
86
+ fullWidth: !0,
87
+ InputLabelProps: {
88
+ sx: { fontSize: 14 }
89
+ }
90
+ }
91
+ )
92
+ ] });
93
+ if (e.type === "date") {
94
+ const o = "DD/MM/YYYY", n = "YYYY-MM-DD", l = t.min && m(t.min, n, !0).isValid() ? m(t.min, n) : null, i = t.max && m(t.max, n, !0).isValid() ? m(t.max, n) : null;
95
+ return /* @__PURE__ */ r(f, { mb: 2, display: "flex", alignItems: "end", children: [
96
+ /* @__PURE__ */ a(
97
+ I,
98
+ {
99
+ label: `${e.name} (Min)`,
100
+ value: l,
101
+ format: o,
102
+ views: ["year", "month", "day"],
103
+ slotProps: {
104
+ textField: {
105
+ variant: "standard",
106
+ name: e.propertyId,
107
+ size: d,
108
+ fullWidth: !0,
109
+ InputLabelProps: { sx: { fontSize: 14 } },
110
+ inputProps: { sx: { fontSize: 14 } }
111
+ }
112
+ },
113
+ onChange: b("min")
114
+ }
115
+ ),
116
+ /* @__PURE__ */ a(p, { px: 1, children: "-" }),
117
+ /* @__PURE__ */ a(
118
+ I,
119
+ {
120
+ label: `${e.name} (Max)`,
121
+ value: i,
122
+ format: o,
123
+ minDate: l !== null ? l : void 0,
124
+ views: ["year", "month", "day"],
125
+ slotProps: {
126
+ textField: {
127
+ variant: "standard",
128
+ name: e.propertyId,
129
+ size: d,
130
+ fullWidth: !0,
131
+ InputLabelProps: { sx: { fontSize: 14 } },
132
+ inputProps: { sx: { fontSize: 14 } }
133
+ }
134
+ },
135
+ onChange: b("max")
136
+ }
137
+ )
138
+ ] });
139
+ }
140
+ if (e.type === "boolean")
141
+ return /* @__PURE__ */ a(f, { mb: 2, children: /* @__PURE__ */ a(
142
+ C,
143
+ {
144
+ label: e.name,
145
+ control: /* @__PURE__ */ a(
146
+ V,
147
+ {
148
+ size: d,
149
+ name: e.propertyId,
150
+ checked: !!t,
151
+ icon: /* @__PURE__ */ a(F, {}),
152
+ checkedIcon: /* @__PURE__ */ a(S, {}),
153
+ onChange: u("exact")
154
+ }
155
+ ),
156
+ slotProps: {
157
+ typography: {
158
+ fontSize: 14
159
+ }
160
+ }
161
+ }
162
+ ) });
163
+ if (e.type === "enum") {
164
+ const [o, n] = w(!1), l = 10;
165
+ let i = [];
166
+ return (g = e.dataTypeInfo) != null && g.enumValues && (i = e.dataTypeInfo.enumValues), /* @__PURE__ */ r(f, { mb: 2, children: [
167
+ /* @__PURE__ */ r(T, { fullWidth: !0, component: "fieldset", variant: "standard", children: [
168
+ /* @__PURE__ */ a(D, { component: "legend", sx: { mb: 1 }, children: e.name }),
169
+ /* @__PURE__ */ a(L, { children: i.slice(0, o ? 9999 : l).map((s, c) => /* @__PURE__ */ a(
170
+ C,
171
+ {
172
+ label: s,
173
+ control: /* @__PURE__ */ a(
174
+ V,
175
+ {
176
+ name: e.propertyId,
177
+ value: s,
178
+ size: "small",
179
+ checked: t.list ? t.list.includes(s) : !1,
180
+ onChange: M
181
+ }
182
+ ),
183
+ componentsProps: {
184
+ typography: {
185
+ variant: "body2"
186
+ }
187
+ }
188
+ },
189
+ c
190
+ )) })
191
+ ] }),
192
+ i.length > l && /* @__PURE__ */ r(
193
+ B,
194
+ {
195
+ size: "small",
196
+ sx: { p: 0, textTransform: "none" },
197
+ endIcon: o ? /* @__PURE__ */ a(Y, {}) : /* @__PURE__ */ a(y, {}),
198
+ onClick: () => n((s) => !s),
199
+ children: [
200
+ "Show ",
201
+ o ? "Less" : "More"
202
+ ]
203
+ }
204
+ )
205
+ ] });
206
+ }
207
+ return /* @__PURE__ */ a(k, {});
208
+ }
10
209
  export {
11
- l as default
210
+ R as default
12
211
  };
@@ -3,10 +3,10 @@ import f from "react";
3
3
  import { TreeViewFilter as _ } from "../treeview-filter/index.js";
4
4
  import r from "lodash";
5
5
  import { flattenNestedTemplates as b } from "../../utils/ontology.js";
6
- import { F as A, I as E } from "../../FormControl-aXQs42m6.js";
7
- import { S as M } from "../../Select-Cdmu0dQ4.js";
8
- import { M as j } from "../../MenuItem-BEW28T9O.js";
9
- import { D as B, a as k, b as w, B as L } from "../../DialogContent-D51w7KVX.js";
6
+ import { F as A, I as E } from "../../FormControl-BMRUQKHh.js";
7
+ import { S as M } from "../../Select-NDq3WyLt.js";
8
+ import { M as j } from "../../MenuItem-DstAFfik.js";
9
+ import { D as B, a as k, b as w, B as L } from "../../DialogContent-BCYm_d1s.js";
10
10
  const P = ({
11
11
  data: h,
12
12
  label: s,
@@ -1,19 +1,19 @@
1
1
  import Ne, { jsx as C, jsxs as it, Fragment as ut } from "react/jsx-runtime";
2
2
  import * as f from "react";
3
3
  import Se from "react";
4
- import { r as Oe, i as Te } from "../../createSvgIcon-B4TFefhd.js";
5
- import { T as dt, D as ft, I as pt } from "../../index-DRy8nExS.js";
4
+ import { r as Oe, i as Te } from "../../createSvgIcon-B2WT0K4k.js";
5
+ import { T as dt, D as ft, I as pt } from "../../index-CSfSVkKj.js";
6
6
  import we from "lodash";
7
7
  import { Box as ht } from "@mui/material";
8
8
  import { SearchInput as mt } from "../search-input/index.js";
9
9
  import { flattenNestedTemplates as xt } from "../../utils/ontology.js";
10
- import { g as gt, u as bt, c as St, a as wt } from "../../useThemeProps-BXn-nVhw.js";
11
- import { P as o } from "../../createStyled-liRRhQcN.js";
12
- import { g as yt, s as It } from "../../styled-Dm8rXzIG.js";
13
- import { u as Ct } from "../../useTheme-CTuK-wFF.js";
10
+ import { g as gt, u as bt, c as St, a as wt } from "../../useThemeProps-DeftUmqJ.js";
11
+ import { P as o } from "../../createStyled-B96gjom1.js";
12
+ import { g as yt, s as It } from "../../styled-cPJbqF0E.js";
13
+ import { u as Ct } from "../../useTheme-C-T6Qisa.js";
14
14
  import { u as Nt } from "../../useId-BHG98T5I.js";
15
- import { u as Ot } from "../../ButtonBase-DJz-TFGO.js";
16
- import { u as ye } from "../../createSvgIcon-Cl8kMTkx.js";
15
+ import { a as Ot } from "../../ButtonBase-D6qhsxB0.js";
16
+ import { u as ye } from "../../createSvgIcon-BNrb7rDY.js";
17
17
  import { o as Tt } from "../../ownerDocument-CUrv0DIK.js";
18
18
  function Rt(d) {
19
19
  return yt("MuiTreeView", d);
@@ -1,7 +1,7 @@
1
1
  import "react/jsx-runtime";
2
2
  import "../item-label/index.js";
3
3
  import "lodash";
4
- import { I as i } from "../../../index-DRy8nExS.js";
4
+ import { I as i } from "../../../index-CSfSVkKj.js";
5
5
  export {
6
6
  i as default
7
7
  };
@@ -1,7 +1,7 @@
1
1
  import { jsxs as c, jsx as a } from "react/jsx-runtime";
2
2
  import { RadioButtonUnchecked as l, CheckCircle as s } from "@mui/icons-material";
3
- import { B as p, C as h } from "../../../Checkbox-DzmWBCrt.js";
4
- import { T as d } from "../../../Typography-CXe5ytr0.js";
3
+ import { B as p, C as h } from "../../../Checkbox-BFWhj3s-.js";
4
+ import { T as d } from "../../../Typography-Dg-ROiTA.js";
5
5
  function k({
6
6
  id: t,
7
7
  name: n,