@m4l/components 0.1.15 → 0.1.17

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 (139) hide show
  1. package/assets/Logo/index.228dcb5a.js +86 -0
  2. package/commonjs.565e6834.js +12 -0
  3. package/components/CommonActions/components/ActionCancel/index.62a3aacc.js +17 -0
  4. package/components/CommonActions/components/ActionFormCancel/index.66469642.js +49 -0
  5. package/components/CommonActions/components/ActionFormIntro/index.ca4d2674.js +31 -0
  6. package/components/CommonActions/components/ActionIntro/index.8872533f.js +18 -0
  7. package/components/CommonActions/components/Actions/index.4ba034cb.js +743 -0
  8. package/components/CompanyLogo/{index.js → index.f81c179c.js} +42 -48
  9. package/components/DataGrid/index.5ba34dbc.js +894 -0
  10. package/components/DynamicFilter/index.e354ae5a.js +1158 -0
  11. package/components/ErrorLabel/index.c8615f16.js +19 -0
  12. package/components/Icon/index.cbca79b0.js +70 -0
  13. package/components/Image/index.e790b50b.js +122 -0
  14. package/components/LanguagePopover/index.df601ffe.js +87 -0
  15. package/components/Loadable/index.f5518558.js +15 -0
  16. package/components/ModalDialog/index.8788743f.js +168 -0
  17. package/components/NoItemSelected/{index.js → index.12f0ca67.js} +43 -50
  18. package/components/ObjectLogs/index.c5a9747b.js +266 -0
  19. package/components/Page/index.6d69977e.js +35 -0
  20. package/components/PaperForm/index.d7c74064.js +105 -0
  21. package/components/Period/index.342dc416.js +160 -0
  22. package/components/PropertyValue/index.ab3dd7e9.js +116 -0
  23. package/components/Resizeable/{index.js → index.45995d2b.js} +21 -19
  24. package/components/ScrollBar/index.39eeb2de.js +49 -0
  25. package/components/ScrollToTop/index.e06f98f6.js +11 -0
  26. package/components/SplitLayout/{index.js → index.4032673d.js} +35 -35
  27. package/components/animate/LoadingScreen/{index.js → index.f1cec7db.js} +29 -27
  28. package/components/animate/MotionContainer/index.8d9f9d80.js +30 -0
  29. package/components/animate/MotionLazyContainer/index.572dd012.js +15 -0
  30. package/components/animate/features.0fbf41e1.js +5 -0
  31. package/components/animate/variants/{bounce.js → bounce.784aaaaa.js} +15 -16
  32. package/components/animate/variants/container.11f82b76.js +20 -0
  33. package/components/animate/variants/fade.b561c0fc.js +59 -0
  34. package/components/animate/variants/{index.js → index.7a912140.js} +0 -0
  35. package/components/animate/variants/transition.bd46b9ce.js +15 -0
  36. package/components/formatters/BooleanFormatter/index.cca53b7f.js +42 -0
  37. package/components/formatters/DateFormatter/index.ad8d9b8e.js +57 -0
  38. package/components/formatters/index.a563fe5d.js +106 -0
  39. package/components/hook-form/FormProvider/index.4c9289e1.js +55 -0
  40. package/components/hook-form/RHFAutocomplete/index.6ed76d4c.js +122 -0
  41. package/components/hook-form/RHFAutocompleteAsync/index.8f2c97ea.js +153 -0
  42. package/components/hook-form/RHFCheckbox/index.f9ce6c39.js +59 -0
  43. package/components/hook-form/RHFDateTime/index.fc5cbafe.js +68 -0
  44. package/components/hook-form/RHFMultiCheckbox/index.2680b3b6.js +34 -0
  45. package/components/hook-form/RHFPeriod/index.fe3f3681.js +45 -0
  46. package/components/hook-form/RHFRadioGroup/index.b3335e13.js +43 -0
  47. package/components/hook-form/RHFSelect/index.b6ca8bb2.js +36 -0
  48. package/components/hook-form/RHFTextField/index.4c455f75.js +77 -0
  49. package/components/hook-form/RHFUpload/index.ed3d739f.js +244 -0
  50. package/components/mui_extended/Accordion/index.2116e423.js +103 -0
  51. package/components/mui_extended/Avatar/index.0a2a4523.js +32 -0
  52. package/components/mui_extended/BoxIcon/index.e638ecc8.js +22 -0
  53. package/components/mui_extended/Breadcrumbs/index.5e37d903.js +89 -0
  54. package/components/mui_extended/Button/index.42f24e7d.js +110 -0
  55. package/components/mui_extended/IconButton/index.88f3aadb.js +98 -0
  56. package/components/mui_extended/LinkWithRoute/index.d4b263de.js +28 -0
  57. package/components/mui_extended/MenuPopover/index.488fc536.js +131 -0
  58. package/components/mui_extended/Pager/index.171ce39d.js +126 -0
  59. package/components/mui_extended/Tab/index.e0653a0a.js +28 -0
  60. package/components/mui_extended/Typography/index.0c4604b3.js +22 -0
  61. package/contexts/ModalContext/index.7113cfd8.js +150 -0
  62. package/hooks/useFormAddEdit/index.d4845f1a.js +26 -0
  63. package/hooks/useModal/index.ab22798b.js +6 -0
  64. package/index.js +163 -71
  65. package/lodash.e09401f0.js +32 -0
  66. package/node_modules.168cb897.js +55 -0
  67. package/package.json +1 -1
  68. package/react-data-grid.d46d625e.js +2115 -0
  69. package/react-draggable.20e95c61.js +714 -0
  70. package/react-json-view.f56a7f8e.js +2762 -0
  71. package/react-lazy-load-image-component.45b56650.js +784 -0
  72. package/react-resizable.5277deaf.js +371 -0
  73. package/react-splitter-layout.7810ac1b.js +165 -0
  74. package/utils/index.214d9542.js +435 -0
  75. package/assets/Logo/index.js +0 -91
  76. package/commonjs.js +0 -9
  77. package/components/CommonActions/components/ActionCancel/index.js +0 -15
  78. package/components/CommonActions/components/ActionFormCancel/index.js +0 -62
  79. package/components/CommonActions/components/ActionFormIntro/index.js +0 -35
  80. package/components/CommonActions/components/ActionIntro/index.js +0 -16
  81. package/components/CommonActions/components/Actions/index.js +0 -859
  82. package/components/DataGrid/index.js +0 -1067
  83. package/components/DynamicFilter/index.js +0 -1573
  84. package/components/ErrorLabel/index.js +0 -18
  85. package/components/Icon/index.js +0 -80
  86. package/components/Image/index.js +0 -128
  87. package/components/LanguagePopover/index.js +0 -93
  88. package/components/Loadable/index.js +0 -13
  89. package/components/ModalDialog/index.js +0 -180
  90. package/components/ObjectLogs/index.js +0 -284
  91. package/components/Page/index.js +0 -36
  92. package/components/PaperForm/index.js +0 -110
  93. package/components/Period/index.js +0 -230
  94. package/components/PropertyValue/index.js +0 -142
  95. package/components/ScrollBar/index.js +0 -52
  96. package/components/ScrollToTop/index.js +0 -10
  97. package/components/animate/MotionContainer/index.js +0 -31
  98. package/components/animate/MotionLazyContainer/index.js +0 -13
  99. package/components/animate/features.js +0 -2
  100. package/components/animate/variants/container.js +0 -20
  101. package/components/animate/variants/fade.js +0 -61
  102. package/components/animate/variants/transition.js +0 -16
  103. package/components/formatters/BooleanFormatter/index.js +0 -52
  104. package/components/formatters/DateFormatter/index.js +0 -66
  105. package/components/formatters/index.js +0 -112
  106. package/components/hook-form/FormProvider/index.js +0 -61
  107. package/components/hook-form/RHFAutocomplete/index.js +0 -144
  108. package/components/hook-form/RHFAutocompleteAsync/index.js +0 -191
  109. package/components/hook-form/RHFCheckbox/index.js +0 -65
  110. package/components/hook-form/RHFDateTime/index.js +0 -79
  111. package/components/hook-form/RHFMultiCheckbox/index.js +0 -32
  112. package/components/hook-form/RHFPeriod/index.js +0 -47
  113. package/components/hook-form/RHFRadioGroup/index.js +0 -41
  114. package/components/hook-form/RHFSelect/index.js +0 -34
  115. package/components/hook-form/RHFTextField/index.js +0 -87
  116. package/components/hook-form/RHFUpload/index.js +0 -255
  117. package/components/mui_extended/Accordion/index.js +0 -105
  118. package/components/mui_extended/Avatar/index.js +0 -33
  119. package/components/mui_extended/BoxIcon/index.js +0 -20
  120. package/components/mui_extended/Breadcrumbs/index.js +0 -92
  121. package/components/mui_extended/Button/index.js +0 -131
  122. package/components/mui_extended/IconButton/index.js +0 -108
  123. package/components/mui_extended/LinkWithRoute/index.js +0 -30
  124. package/components/mui_extended/MenuPopover/index.js +0 -135
  125. package/components/mui_extended/Pager/index.js +0 -137
  126. package/components/mui_extended/Tab/index.js +0 -30
  127. package/components/mui_extended/Typography/index.js +0 -21
  128. package/contexts/ModalContext/index.js +0 -165
  129. package/hooks/useFormAddEdit/index.js +0 -42
  130. package/hooks/useModal/index.js +0 -4
  131. package/lodash.js +0 -62
  132. package/node_modules.js +0 -54
  133. package/react-data-grid.js +0 -2652
  134. package/react-draggable.js +0 -960
  135. package/react-json-view.js +0 -2764
  136. package/react-lazy-load-image-component.js +0 -792
  137. package/react-resizable.js +0 -541
  138. package/react-splitter-layout.js +0 -165
  139. package/utils/index.js +0 -572
@@ -0,0 +1,43 @@
1
+ import { useFormContext as s, Controller as u } from "react-hook-form";
2
+ import { RadioGroup as c, FormControlLabel as x, Radio as p, FormHelperText as f } from "@mui/material";
3
+ import { jsx as r, jsxs as R } from "react/jsx-runtime";
4
+ function j({
5
+ name: l,
6
+ options: m,
7
+ getOptionLabel: e,
8
+ ...n
9
+ }) {
10
+ const {
11
+ control: a
12
+ } = s();
13
+ return /* @__PURE__ */ r(u, {
14
+ name: l,
15
+ control: a,
16
+ render: ({
17
+ field: d,
18
+ fieldState: {
19
+ error: t
20
+ }
21
+ }) => /* @__PURE__ */ R("div", {
22
+ children: [/* @__PURE__ */ r(c, {
23
+ ...d,
24
+ row: !0,
25
+ ...n,
26
+ children: m.map((o, i) => /* @__PURE__ */ r(x, {
27
+ value: o,
28
+ control: /* @__PURE__ */ r(p, {}),
29
+ label: e?.length ? e[i] : o
30
+ }, o))
31
+ }), !!t && /* @__PURE__ */ r(f, {
32
+ error: !0,
33
+ sx: {
34
+ px: 2
35
+ },
36
+ children: t.message
37
+ })]
38
+ })
39
+ });
40
+ }
41
+ export {
42
+ j as R
43
+ };
@@ -0,0 +1,36 @@
1
+ import { useFormContext as m, Controller as s } from "react-hook-form";
2
+ import { TextField as u } from "@mui/material";
3
+ import { jsx as t } from "react/jsx-runtime";
4
+ function x({
5
+ name: r,
6
+ children: o,
7
+ ...l
8
+ }) {
9
+ const {
10
+ control: n
11
+ } = m();
12
+ return /* @__PURE__ */ t(s, {
13
+ name: r,
14
+ control: n,
15
+ render: ({
16
+ field: i,
17
+ fieldState: {
18
+ error: e
19
+ }
20
+ }) => /* @__PURE__ */ t(u, {
21
+ ...i,
22
+ select: !0,
23
+ fullWidth: !0,
24
+ SelectProps: {
25
+ native: !0
26
+ },
27
+ error: !!e,
28
+ helperText: e?.message,
29
+ ...l,
30
+ children: o
31
+ })
32
+ });
33
+ }
34
+ export {
35
+ x as R
36
+ };
@@ -0,0 +1,77 @@
1
+ import { useFormContext as R, Controller as T } from "react-hook-form";
2
+ import { Skeleton as k, TextField as C } from "@mui/material";
3
+ import { styled as S } from "@mui/material/styles";
4
+ import { forwardRef as b } from "react";
5
+ import { useModuleSkeleton as y } from "@m4l/core";
6
+ import { jsx as t } from "react/jsx-runtime";
7
+ const H = S("div")(({
8
+ theme: e
9
+ }) => ({
10
+ display: "flex",
11
+ width: "100%",
12
+ alignItems: "center",
13
+ border: `1px solid ${e.palette.divider}`,
14
+ padding: "12px 14px",
15
+ borderRadius: e.spacing(1)
16
+ })), v = b((e, l) => {
17
+ const {
18
+ name: a,
19
+ autoComplete: d = "off",
20
+ skeletonProps: s = {},
21
+ type: o,
22
+ ...p
23
+ } = e, {
24
+ width: m = "100%",
25
+ height: f = 14
26
+ } = s, u = y(), {
27
+ control: x
28
+ } = R();
29
+ return u ? /* @__PURE__ */ t(H, {
30
+ children: /* @__PURE__ */ t(k, {
31
+ variant: "text",
32
+ width: m,
33
+ height: f
34
+ })
35
+ }) : /* @__PURE__ */ t(T, {
36
+ name: a,
37
+ control: x,
38
+ render: ({
39
+ field: {
40
+ onChange: n,
41
+ onBlur: c,
42
+ value: g,
43
+ name: h,
44
+ ref: F
45
+ },
46
+ fieldState: {
47
+ error: i
48
+ }
49
+ }) => /* @__PURE__ */ t(
50
+ C,
51
+ {
52
+ inputRef: l,
53
+ autoComplete: d,
54
+ onChange: (r) => {
55
+ if (o === "number" && r.target.value) {
56
+ n(Number(r.target.value));
57
+ return;
58
+ }
59
+ n(r);
60
+ },
61
+ onBlur: c,
62
+ value: g,
63
+ name: h,
64
+ ref: F,
65
+ fullWidth: !0,
66
+ error: !!i,
67
+ helperText: i?.message,
68
+ type: o,
69
+ ...p
70
+ }
71
+ )
72
+ });
73
+ });
74
+ v.displayName = "RHFTextField";
75
+ export {
76
+ v as R
77
+ };
@@ -0,0 +1,244 @@
1
+ import { styled as y, FormHelperText as f } from "@mui/material";
2
+ import { useCallback as x } from "react";
3
+ import { useFormContext as v, Controller as C } from "react-hook-form";
4
+ import { i as b } from "../../../lodash.e09401f0.js";
5
+ import { useDropzone as w } from "react-dropzone";
6
+ import { styled as o, alpha as I } from "@mui/material/styles";
7
+ import { I as h } from "../../Image/index.e790b50b.js";
8
+ import { useEnvironment as _, useModuleDictionary as R } from "@m4l/core";
9
+ import { jsxs as a, Fragment as j, jsx as e } from "react/jsx-runtime";
10
+ import "../../../react-lazy-load-image-component.45b56650.js";
11
+ const D = o("div")(({
12
+ theme: t
13
+ }) => ({
14
+ width: "inherit",
15
+ height: "100%",
16
+ minWidth: t.spacing(20),
17
+ margin: "auto",
18
+ borderRadius: t.spacing(1),
19
+ padding: t.spacing(1),
20
+ border: `1px dashed ${t.palette.grey[50032]}`
21
+ })), S = o("div")(({
22
+ theme: t
23
+ }) => ({
24
+ zIndex: 0,
25
+ width: "100%",
26
+ height: "100%",
27
+ outline: "none",
28
+ display: "flex",
29
+ overflow: "hidden",
30
+ borderRadius: t.spacing(1),
31
+ position: "relative",
32
+ alignItems: "center",
33
+ justifyContent: "center",
34
+ "& > *": {
35
+ width: "100%",
36
+ height: "100%"
37
+ },
38
+ "&:hover": {
39
+ cursor: "pointer",
40
+ "& .placeholder": {
41
+ zIndex: 9
42
+ }
43
+ }
44
+ })), U = o("div")(({
45
+ theme: t
46
+ }) => ({
47
+ "&:hover": {
48
+ opacity: 1
49
+ },
50
+ display: "flex",
51
+ justifyContent: "center",
52
+ position: "absolute",
53
+ zIndex: "2",
54
+ inset: "0",
55
+ transition: t.transitions.create("opacity", {
56
+ easing: t.transitions.easing.easeInOut,
57
+ duration: t.transitions.duration.shorter
58
+ }),
59
+ overflow: "auto"
60
+ })), W = o("div")(({
61
+ theme: t
62
+ }) => ({
63
+ padding: t.spacing(3, 5),
64
+ display: "flex",
65
+ flexWrap: "wrap",
66
+ justifyContent: "center",
67
+ width: "100%",
68
+ height: "100%",
69
+ gap: t.spacing(3)
70
+ })), z = o("div")(({
71
+ theme: t
72
+ }) => ({
73
+ display: "flex",
74
+ justifyContent: "center",
75
+ flexDirection: "column",
76
+ gap: t.spacing(3)
77
+ })), F = o("span")(({
78
+ theme: t
79
+ }) => ({
80
+ ...t.typography.subtitle2,
81
+ width: "fit-content"
82
+ })), P = o("span")(({
83
+ theme: t
84
+ }) => ({
85
+ ...t.typography.body2,
86
+ minWidth: t.spacing(20)
87
+ })), $ = o("span")(({
88
+ theme: t
89
+ }) => ({
90
+ ...t.typography.caption,
91
+ width: "fit-content"
92
+ })), H = o("div")(({
93
+ theme: t
94
+ }) => ({
95
+ display: "flex",
96
+ alignItems: "center",
97
+ maxWidth: t.spacing(20)
98
+ }));
99
+ o("div")(() => ({
100
+ width: "100%",
101
+ height: "100%",
102
+ position: "absolute",
103
+ inset: "0",
104
+ display: "flex",
105
+ justifyContent: "center",
106
+ alignItems: "center"
107
+ }));
108
+ function L({
109
+ error: t,
110
+ file: i,
111
+ helperText: s,
112
+ sx: l,
113
+ ...c
114
+ }) {
115
+ const {
116
+ getRootProps: r,
117
+ getInputProps: n,
118
+ isDragActive: d,
119
+ isDragReject: g
120
+ } = w({
121
+ multiple: !1,
122
+ ...c
123
+ }), {
124
+ host_static_assets: m,
125
+ environment_assets: u
126
+ } = _(), {
127
+ getLabel: p
128
+ } = R();
129
+ return /* @__PURE__ */ a(j, {
130
+ children: [/* @__PURE__ */ e(D, {
131
+ id: "RootStyle",
132
+ sx: {
133
+ ...(g || t) && {
134
+ borderColor: "error.light"
135
+ },
136
+ ...l
137
+ },
138
+ children: /* @__PURE__ */ a(S, {
139
+ id: "DropZoneStyle",
140
+ ...r(),
141
+ sx: {
142
+ ...d && {
143
+ opacity: 0.72
144
+ }
145
+ },
146
+ children: [/* @__PURE__ */ e("input", {
147
+ ...n()
148
+ }), i && /* @__PURE__ */ e(h, {
149
+ alt: "avatar",
150
+ src: b(i) ? i : i.preview,
151
+ sx: {
152
+ zIndex: 8
153
+ }
154
+ }), /* @__PURE__ */ e(U, {
155
+ id: "PlaceholderStyle",
156
+ className: "placeholder",
157
+ sx: {
158
+ ...i ? {
159
+ bgcolor: I("#161C24", 0.72),
160
+ color: "common.white",
161
+ opacity: 0
162
+ } : {
163
+ opacity: 1
164
+ },
165
+ ...(g || t) && {
166
+ bgcolor: "error.lighter",
167
+ borderColor: "error.light",
168
+ color: "error.main"
169
+ }
170
+ },
171
+ children: /* @__PURE__ */ a(W, {
172
+ className: "ContainerUploadBody",
173
+ children: [/* @__PURE__ */ e(H, {
174
+ children: /* @__PURE__ */ e(h, {
175
+ src: `${m}/${u}/frontend/components/upload_image/assets/img/upload_image_illustration.svg`,
176
+ effect: "opacity",
177
+ width: "100%",
178
+ height: "auto",
179
+ mb: 1
180
+ })
181
+ }), /* @__PURE__ */ a(z, {
182
+ children: [/* @__PURE__ */ e(F, {
183
+ children: p(i ? "upload_image.title_update" : "upload_image.title_upload")
184
+ }), /* @__PURE__ */ e(P, {
185
+ children: p("upload_image.description")
186
+ }), /* @__PURE__ */ e($, {
187
+ children: p("upload_image.conditions")
188
+ })]
189
+ })]
190
+ })
191
+ })]
192
+ })
193
+ }), s && s]
194
+ });
195
+ }
196
+ const O = y("div")(() => ({
197
+ width: "inherit",
198
+ height: "inherit",
199
+ padding: "1px"
200
+ }));
201
+ function G({
202
+ name: t,
203
+ ...i
204
+ }) {
205
+ const {
206
+ control: s,
207
+ setValue: l
208
+ } = v(), c = x((r) => {
209
+ const n = r[0];
210
+ n && l(t, Object.assign(n, {
211
+ preview: URL.createObjectURL(n)
212
+ }));
213
+ }, [l]);
214
+ return /* @__PURE__ */ e(C, {
215
+ name: t,
216
+ control: s,
217
+ render: ({
218
+ field: r,
219
+ fieldState: {
220
+ error: n
221
+ }
222
+ }) => {
223
+ const d = !!n && !r.value;
224
+ return /* @__PURE__ */ a(O, {
225
+ children: [/* @__PURE__ */ e(L, {
226
+ onDrop: c,
227
+ error: d,
228
+ ...i,
229
+ file: r.value
230
+ }), d && /* @__PURE__ */ e(f, {
231
+ error: !0,
232
+ sx: {
233
+ px: 2,
234
+ textAlign: "center"
235
+ },
236
+ children: n.message
237
+ })]
238
+ });
239
+ }
240
+ });
241
+ }
242
+ export {
243
+ G as R
244
+ };
@@ -0,0 +1,103 @@
1
+ import { Skeleton as d, Accordion as f, AccordionSummary as x, AccordionDetails as b } from "@mui/material";
2
+ import { I as v } from "../IconButton/index.88f3aadb.js";
3
+ import { useEnvironment as y, useModuleSkeleton as I } from "@m4l/core";
4
+ import { I as S } from "../../Icon/index.cbca79b0.js";
5
+ import { styled as c } from "@mui/material/styles";
6
+ import { jsx as t, jsxs as s } from "react/jsx-runtime";
7
+ c("div")(({
8
+ theme: n
9
+ }) => ({
10
+ display: "flex",
11
+ justifyContent: "space-between",
12
+ alignItems: "center",
13
+ borderRadius: n.spacing(0.5),
14
+ height: n.spacing(4.5),
15
+ minHeight: n.spacing(4.5),
16
+ backgroundColor: n.palette.background.header,
17
+ paddingLeft: n.spacing(2),
18
+ paddingRight: n.spacing(2),
19
+ marginBottom: "0px"
20
+ }));
21
+ const l = c("div")(({
22
+ theme: n
23
+ }) => ({
24
+ display: "flex",
25
+ justifyContent: "flex-start",
26
+ alignItems: "center",
27
+ gap: n.spacing(2)
28
+ })), A = c("span")(({
29
+ theme: n
30
+ }) => ({
31
+ ...n.typography.subtitle2
32
+ })), k = (n) => {
33
+ const {
34
+ isSkeleton: e,
35
+ label: i,
36
+ SKTWidht: r,
37
+ SKTHeight: a,
38
+ labelIcon: o
39
+ } = n;
40
+ return /* @__PURE__ */ t("div", {
41
+ children: e ? /* @__PURE__ */ s(l, {
42
+ children: [o && /* @__PURE__ */ t(d, {
43
+ variant: "circular",
44
+ width: "16px",
45
+ height: "16px"
46
+ }), /* @__PURE__ */ t(d, {
47
+ variant: "text",
48
+ width: r,
49
+ height: a
50
+ })]
51
+ }) : /* @__PURE__ */ s(l, {
52
+ children: [o && /* @__PURE__ */ t(S, {
53
+ src: o
54
+ }), /* @__PURE__ */ t(A, {
55
+ children: i
56
+ })]
57
+ })
58
+ });
59
+ };
60
+ function E(n) {
61
+ const {
62
+ label: e,
63
+ SKTWidht: i,
64
+ SKTHeight: r,
65
+ children: a,
66
+ accordionProps: o,
67
+ summaryProps: p,
68
+ labelIcon: u
69
+ } = n, {
70
+ host_static_assets: g,
71
+ environment_assets: h
72
+ } = y(), m = I();
73
+ return /* @__PURE__ */ s(f, {
74
+ variant: "outlined",
75
+ square: !0,
76
+ TransitionProps: {
77
+ unmountOnExit: !0
78
+ },
79
+ defaultExpanded: !0,
80
+ ...o,
81
+ children: [/* @__PURE__ */ t(x, {
82
+ "aria-controls": "expanded-content",
83
+ disableTouchRipple: !1,
84
+ expandIcon: /* @__PURE__ */ t(v, {
85
+ "aria-label": "settings",
86
+ src: `${g}/${h}/frontend/components/accordion/assets/icons/expanded.svg`
87
+ }),
88
+ ...p,
89
+ children: /* @__PURE__ */ t(k, {
90
+ isSkeleton: m,
91
+ label: e,
92
+ SKTWidht: i,
93
+ SKTHeight: r,
94
+ labelIcon: u
95
+ })
96
+ }), /* @__PURE__ */ t(b, {
97
+ children: a
98
+ })]
99
+ });
100
+ }
101
+ export {
102
+ E as A
103
+ };
@@ -0,0 +1,32 @@
1
+ import { forwardRef as i } from "react";
2
+ import { useTheme as n } from "@mui/material/styles";
3
+ import { Avatar as f } from "@mui/material";
4
+ import { jsx as p } from "react/jsx-runtime";
5
+ const s = i(({
6
+ color: t = "default",
7
+ children: r,
8
+ sx: e,
9
+ ...o
10
+ }, m) => {
11
+ const a = n();
12
+ return t === "default" ? /* @__PURE__ */ p(f, {
13
+ ref: m,
14
+ sx: e,
15
+ ...o,
16
+ children: r
17
+ }) : /* @__PURE__ */ p(f, {
18
+ ref: m,
19
+ sx: {
20
+ fontWeight: a.typography.fontWeightMedium,
21
+ color: a.palette[t].contrastText,
22
+ backgroundColor: a.palette[t].main,
23
+ ...e
24
+ },
25
+ ...o,
26
+ children: r
27
+ });
28
+ });
29
+ s.displayName = "Avatar";
30
+ export {
31
+ s as A
32
+ };
@@ -0,0 +1,22 @@
1
+ import { Box as r } from "@mui/material";
2
+ import { jsx as t } from "react/jsx-runtime";
3
+ function a({
4
+ src: o,
5
+ sx: n
6
+ }) {
7
+ return /* @__PURE__ */ t(r, {
8
+ component: "span",
9
+ sx: {
10
+ width: 20,
11
+ height: 20,
12
+ display: "inline-block",
13
+ bgcolor: "currentColor",
14
+ mask: `url(${o}) no-repeat center / contain`,
15
+ WebkitMask: `url(${o}) no-repeat center / contain`,
16
+ ...n
17
+ }
18
+ });
19
+ }
20
+ export {
21
+ a as B
22
+ };
@@ -0,0 +1,89 @@
1
+ import { useMemo as c } from "react";
2
+ import { useModuleDictionary as m } from "@m4l/core";
3
+ import { Link as u, Box as l, Typography as x, Breadcrumbs as f } from "@mui/material";
4
+ import { Link as b } from "react-router-dom";
5
+ import { jsxs as g, jsx as i } from "react/jsx-runtime";
6
+ function d({
7
+ link: s
8
+ }) {
9
+ const {
10
+ href: e,
11
+ name: n,
12
+ icon: a,
13
+ dictionaryField: o
14
+ } = s, {
15
+ getLabel: r
16
+ } = m();
17
+ return /* @__PURE__ */ g(u, {
18
+ variant: "body2",
19
+ component: b,
20
+ to: e || "#",
21
+ sx: {
22
+ lineHeight: 2,
23
+ display: "flex",
24
+ alignItems: "center",
25
+ color: "text.primary",
26
+ "& > div": {
27
+ display: "inherit"
28
+ }
29
+ },
30
+ children: [a && /* @__PURE__ */ i(l, {
31
+ sx: {
32
+ mr: 1,
33
+ "& svg": {
34
+ width: 20,
35
+ height: 20
36
+ }
37
+ },
38
+ children: a
39
+ }), o !== void 0 && r ? r(o) : n]
40
+ }, n);
41
+ }
42
+ function D(s) {
43
+ const {
44
+ links: e,
45
+ activeLast: n = !1,
46
+ ...a
47
+ } = s, {
48
+ getLabel: o
49
+ } = m(), r = c(() => {
50
+ if (e.length === 0)
51
+ return "";
52
+ const {
53
+ dictionaryField: t
54
+ } = e[e.length - 1];
55
+ return o(t);
56
+ }, [o, e]), p = c(() => e.map((t) => /* @__PURE__ */ i(d, {
57
+ link: t
58
+ }, t.name)), [e]), h = c(() => e.map((t) => t.name !== r ? /* @__PURE__ */ i(d, {
59
+ link: t
60
+ }, t.name) : /* @__PURE__ */ i(x, {
61
+ variant: "body2",
62
+ sx: {
63
+ maxWidth: 260,
64
+ overflow: "hidden",
65
+ whiteSpace: "nowrap",
66
+ color: "text.disabled",
67
+ textOverflow: "ellipsis"
68
+ },
69
+ children: r
70
+ }, t.name)), [r, e]);
71
+ return /* @__PURE__ */ i(f, {
72
+ id: "MUIBreadcrumbs",
73
+ separator: /* @__PURE__ */ i(l, {
74
+ component: "span",
75
+ sx: {
76
+ width: 4,
77
+ height: 4,
78
+ mx: 0.5,
79
+ borderRadius: "50%",
80
+ bgcolor: "text.disabled"
81
+ }
82
+ }),
83
+ ...a,
84
+ children: n ? p : h
85
+ });
86
+ }
87
+ export {
88
+ D as B
89
+ };