@m4l/components 0.2.2 → 0.2.4

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 (141) hide show
  1. package/@types/export.d.ts +16 -4
  2. package/{commonjs.565e6834.js → commonjs.333e55c7.js} +5 -0
  3. package/components/AccountPopover/{index.37803642.js → index.2604c389.js} +2 -4
  4. package/components/AccountPopover/index.d.ts +1 -0
  5. package/components/AppBar/AppBar.d.ts +24 -0
  6. package/components/AppBar/classes/index.d.ts +2 -0
  7. package/components/AppBar/classes/types.d.ts +2 -0
  8. package/components/AppBar/{index.d17827eb.js → index.9522f237.js} +26 -5
  9. package/components/AppBar/types.d.ts +14 -0
  10. package/components/CommonActions/components/ActionCancel/{index.6aa59730.js → index.06539086.js} +2 -2
  11. package/components/CommonActions/components/ActionFormCancel/{index.e6ac3a19.js → index.33fc6c79.js} +5 -14
  12. package/components/CommonActions/components/ActionFormIntro/{index.ebadee33.js → index.5a719043.js} +2 -2
  13. package/components/CommonActions/components/ActionIntro/{index.33acdebb.js → index.3e8a2e60.js} +2 -2
  14. package/components/CommonActions/components/Actions/{index.f358ae72.js → index.2f6286eb.js} +1 -1
  15. package/components/DataGrid/formatters/columnPointsFormatter/{index.5e645334.js → index.a19b7b90.js} +1 -1
  16. package/components/DataGrid/{index.e93a1a31.js → index.8fbcf147.js} +8 -9
  17. package/components/DataGrid/subcomponents/Actions/{index.bcf7a8d7.js → index.bad681dc.js} +9 -9
  18. package/components/DraggableWindow/{index.ddc7327b.js → index.f9f067bd.js} +1 -1
  19. package/components/DynamicFilter/classes/index.d.ts +1 -1
  20. package/components/DynamicFilter/classes/types.d.ts +1 -0
  21. package/components/DynamicFilter/{index.6663cc83.js → index.cd7691e0.js} +17 -13
  22. package/components/GridLayout/{index.c26989d8.js → index.e8c04242.js} +2 -2
  23. package/components/GridLayout/subcomponents/Griditem/{index.da0a3c47.js → index.4d38f12e.js} +3 -3
  24. package/components/GridLayout/subcomponents/Responsive/{index.2e641db2.js → index.e25df1dc.js} +1 -1
  25. package/components/Icon/index.05984e7f.js +248 -0
  26. package/components/Icon/types.d.ts +1 -0
  27. package/components/Image/{index.2a2e0b27.js → index.bf37e923.js} +46 -4
  28. package/components/Image/types.d.ts +2 -2
  29. package/components/LanguagePopover/{index.ff7c862e.js → index.5ff37dbf.js} +2 -2
  30. package/components/LinearProgressIndeterminate/{index.7f4ed9b7.js → index.a0ad2d9e.js} +1 -1
  31. package/components/LoadingError/{index.0ac9e74d.js → index.fabad214.js} +3 -3
  32. package/components/MFLoader/{index.cd087354.js → index.7b4ee2a4.js} +1 -1
  33. package/components/ModalDialog/{index.8c4fde10.js → index.89e26413.js} +4 -4
  34. package/components/NoItemSelected/{index.afc12ed9.js → index.7db73e77.js} +1 -1
  35. package/components/ObjectLogs/{index.cb303905.js → index.9c353020.js} +7 -7
  36. package/components/PDFViewer/PDFViewer.d.ts +2 -0
  37. package/components/PDFViewer/classes/constants.d.ts +1 -0
  38. package/components/PDFViewer/classes/index.d.ts +7 -0
  39. package/components/PDFViewer/classes/types.d.ts +7 -0
  40. package/components/PDFViewer/index.5c2db67a.js +63 -0
  41. package/components/PDFViewer/index.d.ts +1 -0
  42. package/components/PDFViewer/types.d.ts +3 -0
  43. package/components/Page/{index.190e2356.js → index.710cb16f.js} +1 -1
  44. package/components/PaperForm/{index.7a206d69.js → index.7ea3883f.js} +1 -1
  45. package/components/Period/{index.906f1ce2.js → index.0aa8e507.js} +2 -2
  46. package/components/PrintingSystem/{index.bbf52442.js → index.ed3b22b7.js} +15 -43
  47. package/components/PrintingSystem/subcomponents/BodyNode/{index.ee81edc5.js → index.7acc6016.js} +1 -1
  48. package/components/PrintingSystem/subcomponents/ChartNode/{index.b56666cf.js → index.e4a23bdd.js} +4 -4
  49. package/components/PrintingSystem/subcomponents/DividerNode/{index.ca3332b1.js → index.16fff262.js} +1 -1
  50. package/components/PrintingSystem/subcomponents/FooterNode/{index.932c3e33.js → index.6c67dec0.js} +1 -1
  51. package/components/PrintingSystem/subcomponents/GridNode/{index.16748040.js → index.f466062b.js} +4 -4
  52. package/components/PrintingSystem/subcomponents/HeaderNode/{index.0ddbbbad.js → index.77d3d39a.js} +1 -1
  53. package/components/PrintingSystem/subcomponents/PaperNode/{index.efd9af2f.js → index.2a3d54a3.js} +4 -4
  54. package/components/PrintingSystem/subcomponents/PropertyValueNode/{index.75ed9752.js → index.e71ad971.js} +1 -1
  55. package/components/PrintingSystem/subcomponents/QRImageNode/index.d.ts +2 -0
  56. package/components/PrintingSystem/subcomponents/QRImageNode/types.d.ts +3 -0
  57. package/components/PrintingSystem/subcomponents/SectionNode/{index.68cac21a.js → index.ce4f6d16.js} +1 -1
  58. package/components/PrintingSystem/subcomponents/TextBoxNode/{index.91ba514f.js → index.850d20a1.js} +3 -3
  59. package/components/PrintingSystem/types.d.ts +10 -1
  60. package/components/PropertyValue/classes/index.d.ts +1 -1
  61. package/components/PropertyValue/classes/types.d.ts +4 -1
  62. package/components/PropertyValue/index.37d91d0c.js +206 -0
  63. package/components/PropertyValue/types.d.ts +5 -7
  64. package/components/Resizeable/{index.383eb1aa.js → index.6478d7d8.js} +1 -1
  65. package/components/ScrollBar/{index.65bb2930.js → index.010f1b9d.js} +5 -1
  66. package/components/SideBar/classes/index.d.ts +1 -1
  67. package/components/SideBar/{index.7e4a79a6.js → index.58d29b84.js} +12 -12
  68. package/components/SideBar/types.d.ts +3 -3
  69. package/components/SplitLayout/{index.9ef430f6.js → index.30fd5861.js} +1 -1
  70. package/components/ToastContainer/ToastContainer.d.ts +2 -0
  71. package/components/ToastContainer/classes/constants.d.ts +1 -0
  72. package/components/ToastContainer/classes/index.d.ts +8 -0
  73. package/components/ToastContainer/classes/types.d.ts +9 -0
  74. package/components/ToastContainer/index.d.ts +2 -0
  75. package/components/ToastContainer/index.ed440301.js +87 -0
  76. package/components/ToastContainer/subcomponents/ToastMessage/index.d.ts +2 -0
  77. package/components/ToastContainer/subcomponents/ToastMessage/types.d.ts +5 -0
  78. package/components/ToastContainer/types.d.ts +4 -0
  79. package/components/areas/components/AreasAdmin/{index.74532c2a.js → index.a14ba797.js} +12 -12
  80. package/components/areas/components/AreasViewer/{index.3cd1a452.js → index.c4545f2d.js} +15 -15
  81. package/components/areas/contexts/AreasContext/{index.55981647.js → index.54893ef7.js} +4 -4
  82. package/components/areas/hooks/useAreas/{index.5cbbe91c.js → index.a15b3d9c.js} +1 -1
  83. package/components/formatters/BooleanFormatter/{index.5379222a.js → index.4f3cbdce.js} +2 -2
  84. package/components/formatters/PointsFormatter/{index.80a4e414.js → index.5c94c5e8.js} +2 -2
  85. package/components/formatters/PointsFormatter/index.d.ts +1 -1
  86. package/components/formatters/{index.d0a0800d.js → index.4ca6946d.js} +1 -1
  87. package/components/hook-form/RHFAutocomplete/classes/types.d.ts +2 -0
  88. package/components/hook-form/RHFAutocomplete/{index.09ff3d84.js → index.0ce87ac3.js} +26 -35
  89. package/components/hook-form/RHFAutocomplete/subcomponents/RenderOption/index.d.ts +1 -1
  90. package/components/hook-form/RHFAutocomplete/subcomponents/Skeleton/types.d.ts +1 -2
  91. package/components/hook-form/RHFAutocomplete/types.d.ts +8 -3
  92. package/components/hook-form/RHFAutocompleteAsync/{index.54b4dca3.js → index.57789d3a.js} +1 -1
  93. package/components/hook-form/RHFColorPicker/classes/constants.d.ts +1 -0
  94. package/components/hook-form/RHFColorPicker/classes/index.d.ts +11 -0
  95. package/components/hook-form/RHFColorPicker/classes/types.d.ts +11 -0
  96. package/components/hook-form/RHFColorPicker/index.d.ts +6 -0
  97. package/components/hook-form/RHFColorPicker/index.d00a2b53.js +150 -0
  98. package/components/hook-form/RHFColorPicker/subcomponents/Skeleton/indext.d.ts +1 -0
  99. package/components/hook-form/RHFColorPicker/types.d.ts +5 -0
  100. package/components/hook-form/RHFDateTime/{index.2b76899e.js → index.ae5d3a39.js} +1 -1
  101. package/components/hook-form/RHFDateTime/types.d.ts +0 -1
  102. package/components/hook-form/RHFPeriod/{index.d6c8587a.js → index.ae9bcf41.js} +1 -1
  103. package/components/hook-form/RHFTextField/{index.f546c18a.js → index.80cc07e0.js} +2 -2
  104. package/components/hook-form/RHFUpload/{index.a5621247.js → index.587aac00.js} +4 -4
  105. package/components/index.d.ts +2 -0
  106. package/components/maps/{GpsTools.34a27c0a.js → components/GpsTools/index.889b0c39.js} +28 -27
  107. package/components/maps/{Map.9fc17398.js → components/Map/index.665e5c5d.js} +4 -4
  108. package/components/modal/{WindowBase.38d4b8e7.js → WindowBase.ea17cf20.js} +3 -3
  109. package/components/modal/{WindowConfirm.cd776fe5.js → WindowConfirm.19ddbd5d.js} +6 -6
  110. package/components/mui_extended/Accordion/{index.5b4b2075.js → index.b9b427d7.js} +3 -3
  111. package/components/mui_extended/Button/classes/types.d.ts +2 -0
  112. package/components/mui_extended/Button/{index.fc5132fa.js → index.570fd3a4.js} +3 -3
  113. package/components/mui_extended/IconButton/{index.df52ae90.js → index.26de70bd.js} +1 -1
  114. package/components/mui_extended/LoadingButton/classes/constants.d.ts +1 -1
  115. package/components/mui_extended/MenuActions/{index.04d87c36.js → index.8c02ff61.js} +2 -2
  116. package/components/mui_extended/Pager/{index.c6990cd4.js → index.5629e82b.js} +1 -1
  117. package/components/mui_extended/Tab/{index.53203047.js → index.724d5948.js} +1 -1
  118. package/components/mui_extended/ToggleButton/{index.4b7b7df0.js → index.21a1f8e5.js} +1 -1
  119. package/components/mui_extended/ToggleIconButton/{index.e430bed4.js → index.00f13c40.js} +1 -1
  120. package/contexts/ModalContext/{index.aa3bd23f.js → index.b39d303d.js} +1 -1
  121. package/hooks/useFormAddEdit/{index.59c74cbf.js → index.32aa4f64.js} +2 -2
  122. package/hooks/useModal/{index.b4b84d5d.js → index.abdc0962.js} +1 -1
  123. package/hooks/useTab/{index.6ab00d5a.js → index.991b13a7.js} +1 -1
  124. package/index.js +100 -86
  125. package/node_modules.8f15d11f.js +6921 -0
  126. package/package.json +5 -2
  127. package/{react-draggable.cdce362f.js → react-draggable.ee21cb7e.js} +4 -4
  128. package/{react-json-view.57125fcf.js → react-json-view.5636414a.js} +1 -1
  129. package/{react-resizable.806822ee.js → react-resizable.ee028152.js} +5 -5
  130. package/{react-splitter-layout.8b1655c8.js → react-splitter-layout.c5d98bf7.js} +3 -3
  131. package/utils/{index.b22c4c1a.js → index.de903261.js} +0 -32
  132. package/vendor.8f8b0ac9.js +112 -0
  133. package/components/Icon/index.6db034b5.js +0 -147
  134. package/components/PrintingSystem/utils/getEvalValue/index.d.ts +0 -1
  135. package/components/PropertyValue/index.a36c1223.js +0 -220
  136. package/components/PropertyValue/skeleton.d.ts +0 -2
  137. package/components/maps/index.7057e217.js +0 -1
  138. package/node_modules.f907e6dd.js +0 -4736
  139. package/vendor.caaaf054.js +0 -168
  140. /package/components/GridLayout/subcomponents/{Griditem → GridItem}/index.d.ts +0 -0
  141. /package/components/GridLayout/subcomponents/{Griditem → GridItem}/types.d.ts +0 -0
@@ -1,21 +1,20 @@
1
- import { getPropertyByString } from "@m4l/core";
2
1
  import { generateUtilityClasses } from "@mui/material";
3
2
  import { unstable_composeClasses } from "@mui/base";
4
- import { g as getComponentUtilityClass } from "../../utils/index.b22c4c1a.js";
3
+ import { g as getComponentUtilityClass } from "../../utils/index.de903261.js";
5
4
  import { styled, useTheme } from "@mui/material/styles";
6
5
  import clsx from "clsx";
7
- import { D as DividerNode } from "./subcomponents/DividerNode/index.ca3332b1.js";
8
- import { S as SectionNode } from "./subcomponents/SectionNode/index.68cac21a.js";
9
- import { T as TextBoxNode } from "./subcomponents/TextBoxNode/index.91ba514f.js";
10
- import { H as HeaderNode } from "./subcomponents/HeaderNode/index.0ddbbbad.js";
11
- import { a as ImageNode } from "../Image/index.2a2e0b27.js";
12
- import { B as BodyNode } from "./subcomponents/BodyNode/index.ee81edc5.js";
13
- import { F as FooterNode } from "./subcomponents/FooterNode/index.932c3e33.js";
14
- import { P as PaperNode } from "./subcomponents/PaperNode/index.efd9af2f.js";
15
- import { P as PropertyValueNode } from "./subcomponents/PropertyValueNode/index.75ed9752.js";
16
- import { G as GridNode } from "./subcomponents/GridNode/index.16748040.js";
17
- import { C as ChartNode } from "./subcomponents/ChartNode/index.b56666cf.js";
18
- import { P as PagerNode, a as PageRender } from "../Page/index.190e2356.js";
6
+ import { D as DividerNode } from "./subcomponents/DividerNode/index.16fff262.js";
7
+ import { S as SectionNode } from "./subcomponents/SectionNode/index.ce4f6d16.js";
8
+ import { T as TextBoxNode } from "./subcomponents/TextBoxNode/index.850d20a1.js";
9
+ import { H as HeaderNode } from "./subcomponents/HeaderNode/index.77d3d39a.js";
10
+ import { a as ImageNode, Q as QRImageNode } from "../Image/index.bf37e923.js";
11
+ import { B as BodyNode } from "./subcomponents/BodyNode/index.7acc6016.js";
12
+ import { F as FooterNode } from "./subcomponents/FooterNode/index.6c67dec0.js";
13
+ import { P as PaperNode } from "./subcomponents/PaperNode/index.2a3d54a3.js";
14
+ import { P as PropertyValueNode } from "./subcomponents/PropertyValueNode/index.e71ad971.js";
15
+ import { G as GridNode } from "./subcomponents/GridNode/index.f466062b.js";
16
+ import { C as ChartNode } from "./subcomponents/ChartNode/index.e4a23bdd.js";
17
+ import { P as PagerNode, a as PageRender } from "../Page/index.710cb16f.js";
19
18
  import { jsxs, jsx } from "react/jsx-runtime";
20
19
  import { forwardRef, useRef, useImperativeHandle } from "react";
21
20
  const componentName = "M4LPrintingSystem";
@@ -97,33 +96,6 @@ const getSize = (value, unitSize) => {
97
96
  return value;
98
97
  }
99
98
  };
100
- const getEvalValue = (sourceData, key) => {
101
- const regexPattern = /\${([^${}]+(?:\${[^{}]*}[^${}]*)*)}/g;
102
- if (regexPattern.test(key)) {
103
- const matches = [];
104
- let match;
105
- let localRegex = new RegExp(regexPattern);
106
- while ((match = localRegex.exec(key)) !== null) {
107
- matches.push(match[1]);
108
- }
109
- const finalValue = new Array();
110
- matches.map((findMatch) => {
111
- const nestedRegex = /\${([^${}]+(?:\${[^{}]*}[^${}]*)*)}/g;
112
- if (nestedRegex.test(findMatch)) {
113
- const regexKeyReady = /([^ ${]+)/;
114
- let matchKeyReady = regexKeyReady.exec(findMatch) || "";
115
- let nestedKey = findMatch.match(regexPattern) || "";
116
- finalValue.push(getPropertyByString(sourceData, matchKeyReady[1]));
117
- finalValue.push(getEvalValue(sourceData, nestedKey[0]));
118
- } else {
119
- finalValue.push(getPropertyByString(sourceData, findMatch));
120
- }
121
- });
122
- return finalValue.join(" ");
123
- } else {
124
- return key;
125
- }
126
- };
127
99
  const FactoryRender = (props) => {
128
100
  const {
129
101
  data: parent
@@ -145,6 +117,7 @@ const FactoryRender = (props) => {
145
117
  grid: GridNode,
146
118
  chart: ChartNode,
147
119
  pager: PagerNode,
120
+ qrImage: QRImageNode,
148
121
  __default__: () => {
149
122
  throw new Error("Type no defined");
150
123
  }
@@ -217,7 +190,6 @@ const PrintingSystem = forwardRef((props, ref) => {
217
190
  export {
218
191
  FactoryRender as F,
219
192
  PrintingSystem as P,
220
- getSize as a,
221
193
  classes as c,
222
- getEvalValue as g
194
+ getSize as g
223
195
  };
@@ -1,5 +1,5 @@
1
1
  import { useBase } from "@m4l/core";
2
- import { c as classes, a as getSize } from "../../index.bbf52442.js";
2
+ import { c as classes, g as getSize } from "../../index.ed3b22b7.js";
3
3
  import clsx from "clsx";
4
4
  import { jsx } from "react/jsx-runtime";
5
5
  const BodyNode = (props) => {
@@ -1,9 +1,9 @@
1
- import { g as getEvalValue, c as classes } from "../../index.bbf52442.js";
1
+ import { c as classes } from "../../index.ed3b22b7.js";
2
2
  import clsx from "clsx";
3
3
  import { createRef, useEffect } from "react";
4
4
  import { Chart, registerables } from "chart.js";
5
5
  import { ScatterWithErrorBarsController, LineWithErrorBarsChart, PointWithErrorBar } from "chartjs-chart-error-bars";
6
- import { useBase, getPropertyByString } from "@m4l/core";
6
+ import { useBase, getPropertyByString, evaluateWithContext } from "@m4l/core";
7
7
  import { jsx } from "react/jsx-runtime";
8
8
  Chart.register(ScatterWithErrorBarsController, LineWithErrorBarsChart, PointWithErrorBar, ...registerables);
9
9
  const ChartNode = (props) => {
@@ -61,13 +61,13 @@ const ChartNode = (props) => {
61
61
  x: {
62
62
  title: {
63
63
  display: true,
64
- text: getEvalValue(sourceData, messageX)
64
+ text: evaluateWithContext(sourceData, messageX)
65
65
  }
66
66
  },
67
67
  y: {
68
68
  title: {
69
69
  display: true,
70
- text: getEvalValue(sourceData, messageY)
70
+ text: evaluateWithContext(sourceData, messageY)
71
71
  }
72
72
  }
73
73
  }
@@ -1,4 +1,4 @@
1
- import { c as classes } from "../../index.bbf52442.js";
1
+ import { c as classes } from "../../index.ed3b22b7.js";
2
2
  import clsx from "clsx";
3
3
  import { jsx } from "react/jsx-runtime";
4
4
  const DividerNode = (props) => {
@@ -1,5 +1,5 @@
1
1
  import { useBase } from "@m4l/core";
2
- import { c as classes, a as getSize } from "../../index.bbf52442.js";
2
+ import { c as classes, g as getSize } from "../../index.ed3b22b7.js";
3
3
  import clsx from "clsx";
4
4
  import { jsx } from "react/jsx-runtime";
5
5
  const FooterNode = (props) => {
@@ -1,5 +1,5 @@
1
- import { useBase, getPropertyByString } from "@m4l/core";
2
- import { c as classes, a as getSize, g as getEvalValue } from "../../index.bbf52442.js";
1
+ import { useBase, getPropertyByString, evaluateWithContext } from "@m4l/core";
2
+ import { c as classes, g as getSize } from "../../index.ed3b22b7.js";
3
3
  import clsx from "clsx";
4
4
  import { jsxs, jsx } from "react/jsx-runtime";
5
5
  const GridNode = (props) => {
@@ -42,7 +42,7 @@ const GridNode = (props) => {
42
42
  maxWidth: column.width ? getSize(column.width, unitSize) : "auto",
43
43
  justifyContent: column.alignX ? column.alignX : "center"
44
44
  },
45
- children: getEvalValue(sourceData, column.title)
45
+ children: evaluateWithContext(sourceData, column.title)
46
46
  }, `th-${Math.random().toString(36).substring(7)}`);
47
47
  })
48
48
  }, `tr-${Math.random().toString(36).substring(7)}`)
@@ -58,7 +58,7 @@ const GridNode = (props) => {
58
58
  minWidth: getSize(dataColumns[id].width || "auto", unitSize),
59
59
  justifyContent: cell.alignX ? cell.alignX : "center"
60
60
  },
61
- children: isNested ? getPropertyByString(row, dataColumns[id].nestedValue || "") : row[dataColumns[id].key]
61
+ children: isNested ? evaluateWithContext(row, dataColumns[id].nestedValue || "") : row[dataColumns[id].key]
62
62
  }, `td-${Math.random().toString(36).substring(7)}`);
63
63
  })
64
64
  }, `tr-${Math.random().toString(36).substring(7)}`);
@@ -1,5 +1,5 @@
1
1
  import { useBase } from "@m4l/core";
2
- import { c as classes, a as getSize } from "../../index.bbf52442.js";
2
+ import { c as classes, g as getSize } from "../../index.ed3b22b7.js";
3
3
  import clsx from "clsx";
4
4
  import { jsx } from "react/jsx-runtime";
5
5
  const HeaderNode = (props) => {
@@ -1,5 +1,5 @@
1
- import { useBase } from "@m4l/core";
2
- import { g as getEvalValue, c as classes } from "../../index.bbf52442.js";
1
+ import { useBase, evaluateWithContext } from "@m4l/core";
2
+ import { c as classes } from "../../index.ed3b22b7.js";
3
3
  import clsx from "clsx";
4
4
  import { jsxs, jsx } from "react/jsx-runtime";
5
5
  const PaperNode = (props) => {
@@ -16,8 +16,8 @@ const PaperNode = (props) => {
16
16
  const {
17
17
  sourceData
18
18
  } = useBase();
19
- const titleFormated = getEvalValue(sourceData, title);
20
- const titleSecondaryFormated = getEvalValue(sourceData, titleSecondary || "");
19
+ const titleFormated = evaluateWithContext(sourceData, title);
20
+ const titleSecondaryFormated = evaluateWithContext(sourceData, titleSecondary || "");
21
21
  return /* @__PURE__ */ jsxs("div", {
22
22
  className: clsx(classes.paperNodeRoot, className),
23
23
  style: {
@@ -1,5 +1,5 @@
1
1
  import { useBase, evaluateWithContext } from "@m4l/core";
2
- import { c as classes, a as getSize } from "../../index.bbf52442.js";
2
+ import { c as classes, g as getSize } from "../../index.ed3b22b7.js";
3
3
  import clsx from "clsx";
4
4
  import { jsxs, jsx } from "react/jsx-runtime";
5
5
  const PropertyValueNode = (props) => {
@@ -0,0 +1,2 @@
1
+ import { QRImageNodeProps } from './types';
2
+ export declare const QRImageNode: (props: QRImageNodeProps) => import("react/jsx-runtime").JSX.Element;
@@ -0,0 +1,3 @@
1
+ import { QRImageNode } from "../../types";
2
+ export interface QRImageNodeProps extends QRImageNode {
3
+ }
@@ -1,5 +1,5 @@
1
1
  import { useBase } from "@m4l/core";
2
- import { c as classes, a as getSize } from "../../index.bbf52442.js";
2
+ import { c as classes, g as getSize } from "../../index.ed3b22b7.js";
3
3
  import clsx from "clsx";
4
4
  import { jsx } from "react/jsx-runtime";
5
5
  const SectionNode = (props) => {
@@ -1,5 +1,5 @@
1
- import { useBase } from "@m4l/core";
2
- import { g as getEvalValue, c as classes } from "../../index.bbf52442.js";
1
+ import { useBase, evaluateWithContext } from "@m4l/core";
2
+ import { c as classes } from "../../index.ed3b22b7.js";
3
3
  import clsx from "clsx";
4
4
  import { jsx } from "react/jsx-runtime";
5
5
  const TextBoxNode = (props) => {
@@ -13,7 +13,7 @@ const TextBoxNode = (props) => {
13
13
  const {
14
14
  sourceData
15
15
  } = useBase();
16
- const textFormated = getEvalValue(sourceData, children[1]);
16
+ const textFormated = evaluateWithContext(sourceData, children[1]);
17
17
  return /* @__PURE__ */ jsx("span", {
18
18
  className: clsx(classes.textBoxNodeRoot, className, `${classes.textBoxNodeVariant}-${variant}`),
19
19
  style: {
@@ -115,6 +115,15 @@ export interface ImageNode extends BaseNode {
115
115
  width?: number;
116
116
  height?: number;
117
117
  }
118
+ /**
119
+ * QReNode: Componente para visualizar una imagen qr.
120
+ */
121
+ export interface QRImageNode extends BaseNode {
122
+ type: 'qrImage';
123
+ url: string;
124
+ size?: number;
125
+ color?: string;
126
+ }
118
127
  /**
119
128
  * HeaderNode: Componente para visualizar la cabecera del documento.
120
129
  */
@@ -201,7 +210,7 @@ export interface ChartNode extends Omit<BaseNode, 'children'> {
201
210
  messageX: string;
202
211
  messageY: string;
203
212
  }
204
- export declare type NodePrint = SectionNode | TextBoxNode | ImageNode | HeaderNode | BodyNode | FooterNode | PaperNode | PropertyValue | DividerNode | GridNode | ChartNode | PagerNode;
213
+ export declare type NodePrint = SectionNode | TextBoxNode | ImageNode | HeaderNode | BodyNode | FooterNode | PaperNode | PropertyValue | DividerNode | GridNode | ChartNode | PagerNode | QRImageNode;
205
214
  export declare type NodePrintComponent = ((props: PageNodeProps) => React.JSX.Element) | ((props: SectionNodeProps) => React.JSX.Element) | ((props: HeaderNodeProps) => React.JSX.Element) | ((props: BodyNodeProps) => React.JSX.Element) | ((props: FooterNodeProps) => React.JSX.Element) | ((props: PaperNodeProps) => React.JSX.Element) | ((props: PropertyValueNodeProps) => React.JSX.Element) | ((props: GridNodeProps) => React.JSX.Element) | ((props: ChartNodeProps) => React.JSX.Element);
206
215
  export interface PrintingSystemProps {
207
216
  templateData: RootNode;
@@ -6,5 +6,5 @@ export declare const propertyValueUtilityClasses: (ownerState: OwnerState) => {
6
6
  value: string;
7
7
  root: string;
8
8
  property: string;
9
- skeletonProperty: string;
9
+ iconProperty: string;
10
10
  };
@@ -3,9 +3,12 @@ export interface PropertyValueClassesType {
3
3
  root: string;
4
4
  property: string;
5
5
  value: string;
6
- skeletonProperty: string;
6
+ iconProperty: string;
7
7
  isDisabled: string;
8
8
  isFocus: string;
9
+ variantIsForm: string;
10
+ isTabSelected: string;
11
+ isMobile: string;
9
12
  }
10
13
  export declare type PropertyValueClassesKey = keyof PropertyValueClassesType;
11
14
  export declare type Classes = ReturnType<typeof propertyValueUtilityClasses>;
@@ -0,0 +1,206 @@
1
+ import { styled } from "@mui/material/styles";
2
+ import { useResponsiveDesktop } from "@m4l/graphics";
3
+ import { generateUtilityClasses, generateUtilityClass } from "@mui/material";
4
+ import { unstable_composeClasses } from "@mui/base";
5
+ import clsx from "clsx";
6
+ import { T as TEST_PROP_ID } from "../../test/constants_no_mock.86c553a9.js";
7
+ import { g as getNameDataTestId } from "../../vendor.8f8b0ac9.js";
8
+ import { useState } from "react";
9
+ import { jsxs, jsx } from "react/jsx-runtime";
10
+ import { I as Icon } from "../Icon/index.05984e7f.js";
11
+ import { T as Typography } from "../mui_extended/Typography/index.379dd374.js";
12
+ const PropertyValueRoot = styled("div")(({
13
+ theme
14
+ }) => ({
15
+ ...theme.components?.M4LPropertyValue?.styleOverrides
16
+ }));
17
+ const componentName = "M4LPropertyValue";
18
+ generateUtilityClasses(componentName, [
19
+ "root",
20
+ "property",
21
+ "iconProperty",
22
+ "value",
23
+ "isDisabled",
24
+ "isFocus",
25
+ "variantIsForm",
26
+ "isTabSelected",
27
+ "isMobile"
28
+ ]);
29
+ function getPropertyValueUtilityClass(slot) {
30
+ return generateUtilityClass(componentName, slot);
31
+ }
32
+ const propertyValueUtilityClasses = (ownerState) => {
33
+ const slots = {
34
+ root: ["root", ownerState.disabled && "isDisabled", ownerState.isFocus && "isFocus", ownerState.isForm && "variantIsForm", ownerState.isTabSelected && "isTabSelected", ownerState.isMobile && "isMobile"],
35
+ property: ["property"],
36
+ iconProperty: ["iconProperty"],
37
+ value: ["value"]
38
+ };
39
+ const composedClasses = unstable_composeClasses(slots, getPropertyValueUtilityClass, {});
40
+ return {
41
+ ...composedClasses
42
+ };
43
+ };
44
+ const COMPONENT_PREFIX = "m4l-property-value";
45
+ const TEST_PROPS_DATA = `${COMPONENT_PREFIX}-data`;
46
+ function PropertyValue(props) {
47
+ const {
48
+ property,
49
+ iconProperty,
50
+ value,
51
+ propertyWidth = 200,
52
+ valueHeight = "auto",
53
+ valueWidth = "100",
54
+ valueWidthMobile,
55
+ isForm,
56
+ className,
57
+ dataTestId = "",
58
+ disabled = false
59
+ } = props;
60
+ const isDesktop = useResponsiveDesktop();
61
+ const [isFocus, setIsFocus] = useState(false);
62
+ const [isTabSelected, setIsTabSelected] = useState(false);
63
+ const getValueW = () => {
64
+ if (valueWidthMobile && !isDesktop) {
65
+ return valueWidthMobile;
66
+ }
67
+ if (valueWidth === 75 && isDesktop) {
68
+ return 75;
69
+ } else if (valueWidth === 75 && !isDesktop) {
70
+ return 100;
71
+ }
72
+ if (valueWidth === 50 && isDesktop) {
73
+ return 50;
74
+ } else if (valueWidth === 50 && !isDesktop) {
75
+ return 100;
76
+ }
77
+ if (valueWidth === 25 && isDesktop || valueWidth === 12.5 && isDesktop) {
78
+ return valueWidth;
79
+ }
80
+ if (valueWidth === 25 && !isDesktop) {
81
+ return 50;
82
+ }
83
+ if (valueWidth === 12.5 && !isDesktop) {
84
+ return 25;
85
+ }
86
+ return 100;
87
+ };
88
+ const handlerFocus = () => {
89
+ setIsFocus(true);
90
+ };
91
+ const handlerKeyUp = (event) => {
92
+ if (event.key === "Tab") {
93
+ console.log("handlerKeyDown condition ok");
94
+ setIsTabSelected(true);
95
+ }
96
+ };
97
+ const handlerOnBlur = () => {
98
+ setIsFocus(false);
99
+ setIsTabSelected(false);
100
+ };
101
+ const ownerState = {
102
+ disabled: isForm && disabled ? disabled : false,
103
+ isFocus: !disabled && isForm ? isFocus : false,
104
+ isTabSelected: !disabled && isForm ? isTabSelected : false,
105
+ isForm: isForm ? true : false,
106
+ isMobile: !isDesktop
107
+ };
108
+ const classes = propertyValueUtilityClasses(ownerState);
109
+ if (!isForm) {
110
+ return /* @__PURE__ */ jsxs(PropertyValueRoot, {
111
+ className: clsx(classes.root, className),
112
+ style: {
113
+ gridTemplateColumns: propertyWidth ? `${propertyWidth}px 1fr` : "150px 1fr"
114
+ },
115
+ ...process.env.NODE_ENV !== "production" ? {
116
+ [TEST_PROPS_DATA]: JSON.stringify([{
117
+ property: property ? true : false,
118
+ value: value ? true : false
119
+ }]),
120
+ [TEST_PROP_ID]: getNameDataTestId(COMPONENT_PREFIX, "root", dataTestId)
121
+ } : {},
122
+ children: [/* @__PURE__ */ jsxs("div", {
123
+ className: classes.property,
124
+ style: {
125
+ width: propertyWidth && isDesktop ? propertyWidth : "150px",
126
+ minWidth: propertyWidth && isDesktop ? propertyWidth : "150px"
127
+ },
128
+ ...process.env.NODE_ENV !== "production" ? {
129
+ [TEST_PROP_ID]: getNameDataTestId(COMPONENT_PREFIX, "property", dataTestId)
130
+ } : {},
131
+ children: [iconProperty ? /* @__PURE__ */ jsx(Icon, {
132
+ src: iconProperty,
133
+ className: classes.iconProperty
134
+ }) : null, /* @__PURE__ */ jsx(Typography, {
135
+ variant: "body",
136
+ skeletonWidth: "70px",
137
+ children: property
138
+ })]
139
+ }), /* @__PURE__ */ jsx("div", {
140
+ className: classes.value,
141
+ style: {
142
+ width: `${getValueW()}%`,
143
+ maxWidth: `${getValueW()}%`,
144
+ height: valueHeight
145
+ },
146
+ ...process.env.NODE_ENV !== "production" ? {
147
+ [TEST_PROP_ID]: getNameDataTestId(COMPONENT_PREFIX, "value", dataTestId)
148
+ } : {},
149
+ children: value
150
+ })]
151
+ });
152
+ }
153
+ return /* @__PURE__ */ jsxs(PropertyValueRoot, {
154
+ className: clsx(classes.root, className),
155
+ style: {
156
+ gridTemplateColumns: propertyWidth ? `${propertyWidth}px 1fr` : "150px 1fr"
157
+ },
158
+ role: "button",
159
+ tabIndex: 0,
160
+ onClick: handlerFocus,
161
+ onBlur: handlerOnBlur,
162
+ onKeyUp: handlerKeyUp,
163
+ ...process.env.NODE_ENV !== "production" ? {
164
+ [TEST_PROPS_DATA]: JSON.stringify([{
165
+ property: property ? true : false,
166
+ value: value ? true : false
167
+ }]),
168
+ [TEST_PROP_ID]: getNameDataTestId(COMPONENT_PREFIX, "root", dataTestId)
169
+ } : {},
170
+ children: [/* @__PURE__ */ jsxs("div", {
171
+ className: clsx(classes.root, className),
172
+ style: {
173
+ width: propertyWidth ? `${propertyWidth}px 1fr` : "150px 1fr"
174
+ },
175
+ ...process.env.NODE_ENV !== "production" ? {
176
+ [TEST_PROPS_DATA]: JSON.stringify([{
177
+ property: property ? true : false,
178
+ value: value ? true : false
179
+ }]),
180
+ [TEST_PROP_ID]: getNameDataTestId(COMPONENT_PREFIX, "root", dataTestId)
181
+ } : {},
182
+ children: [iconProperty ? /* @__PURE__ */ jsx(Icon, {
183
+ src: iconProperty,
184
+ className: classes.iconProperty
185
+ }) : null, /* @__PURE__ */ jsx(Typography, {
186
+ variant: "body",
187
+ skeletonWidth: "70px",
188
+ children: property
189
+ })]
190
+ }), /* @__PURE__ */ jsx("div", {
191
+ className: classes.value,
192
+ style: {
193
+ width: `${getValueW()}%`,
194
+ maxWidth: `${getValueW()}%`,
195
+ height: valueHeight
196
+ },
197
+ ...process.env.NODE_ENV !== "production" ? {
198
+ [TEST_PROP_ID]: getNameDataTestId(COMPONENT_PREFIX, "value", dataTestId)
199
+ } : {},
200
+ children: value
201
+ })]
202
+ });
203
+ }
204
+ export {
205
+ PropertyValue as P
206
+ };
@@ -1,6 +1,7 @@
1
1
  import type { ReactNode } from 'react';
2
2
  export interface PropertyProps {
3
3
  propertyWidth?: number;
4
+ iconProperty?: string;
4
5
  }
5
6
  export interface ValueProps {
6
7
  valueHeight?: number | string;
@@ -15,12 +16,9 @@ export interface PropertyValueProps extends PropertyProps, ValueProps {
15
16
  dataTestId?: string;
16
17
  disabled?: boolean;
17
18
  }
18
- export declare type WrapperProps = PropertyProps & Pick<PropertyValueProps, 'isForm'>;
19
- export declare type WrapperPropertyProps = WrapperProps;
20
- export declare type WrapperValueProps = Omit<ValueProps, 'valueWidthMobile'>;
21
- export interface SKTPropertyProps extends Pick<PropertyValueProps, 'dataTestId'> {
22
- className: string;
23
- }
24
19
  export interface OwnerState extends Pick<PropertyValueProps, 'disabled'> {
25
- focus: boolean;
20
+ isFocus: boolean;
21
+ isForm: boolean;
22
+ isTabSelected: boolean;
23
+ isMobile: boolean;
26
24
  }
@@ -1,5 +1,5 @@
1
1
  import { styled } from "@mui/material/styles";
2
- import { a as ResizableBox } from "../../react-resizable.806822ee.js";
2
+ import { a as ResizableBox } from "../../react-resizable.ee028152.js";
3
3
  import { jsx } from "react/jsx-runtime";
4
4
  const WrapperResizeable = styled(ResizableBox)(({
5
5
  theme
@@ -69,7 +69,11 @@ styled(SimpleBarReact)(({
69
69
  "& .simplebar-mask": {
70
70
  zIndex: "inherit"
71
71
  },
72
- "& .simplebar-content": {},
72
+ "& .simplebar-content": {
73
+ display: "flex",
74
+ flexDirection: "column",
75
+ height: "100%"
76
+ },
73
77
  '& .simplebar-content-wrapper[style*="overflow: hidden scroll;"] ': {
74
78
  "& .simplebar-content": {
75
79
  marginRight: "12px"
@@ -5,11 +5,11 @@ export declare const getSideBarClassesByState: (ownerState: SideBarState) => {
5
5
  root: string;
6
6
  drawer: string;
7
7
  popover: string;
8
+ containerLogo: string;
8
9
  containerSideBarLogo: string;
9
10
  contentDesktop: string;
10
11
  contentMobile: string;
11
12
  collapseButton: string;
12
- containerLogo: string;
13
13
  contentGroups: string;
14
14
  wrapperGroup: string;
15
15
  wrapperGroupTitle: string;
@@ -4,17 +4,17 @@ import { styled as styled$1, generateUtilityClasses, ListItemText, Tooltip, List
4
4
  import { useEnvironment, useBase, BaseProvider } from "@m4l/core";
5
5
  import { createContext, useContext, useState, useEffect } from "react";
6
6
  import { unstable_composeClasses } from "@mui/base";
7
- import { g as getComponentUtilityClass } from "../../utils/index.b22c4c1a.js";
7
+ import { g as getComponentUtilityClass } from "../../utils/index.de903261.js";
8
8
  import { jsx, jsxs, Fragment } from "react/jsx-runtime";
9
9
  import { T as TEST_PROP_ID } from "../../test/constants_no_mock.86c553a9.js";
10
- import { I as Image } from "../Image/index.2a2e0b27.js";
11
- import { I as IconButton } from "../mui_extended/IconButton/index.df52ae90.js";
12
- import { I as Icon, A as ArrowIcon } from "../Icon/index.6db034b5.js";
10
+ import { I as Image } from "../Image/index.bf37e923.js";
11
+ import { I as IconButton } from "../mui_extended/IconButton/index.26de70bd.js";
12
+ import { I as Icon, A as ArrowIcon } from "../Icon/index.05984e7f.js";
13
13
  import { T as Typography } from "../mui_extended/Typography/index.379dd374.js";
14
14
  import clsx from "clsx";
15
15
  import { useLocation } from "react-router-dom";
16
16
  import { P as Popover } from "../mui_extended/Popover/index.b3eca6b1.js";
17
- import { S as ScrollBar } from "../ScrollBar/index.65bb2930.js";
17
+ import { S as ScrollBar } from "../ScrollBar/index.010f1b9d.js";
18
18
  const SideBarRoot = styled("div")(({
19
19
  theme
20
20
  }) => ({
@@ -235,7 +235,7 @@ function CollapseButton(props) {
235
235
  children: /* @__PURE__ */ jsx(Image, {
236
236
  width: "100%",
237
237
  height: "100%",
238
- src: companyLogoNormalUrl,
238
+ src: companyLogoNormalUrl || "",
239
239
  alt: "logo"
240
240
  }, "Logo")
241
241
  }), /* @__PURE__ */ jsx("div", {
@@ -905,7 +905,7 @@ const ContentDesktop = () => {
905
905
  ...process.env.NODE_ENV !== "production" ? {
906
906
  [TEST_PROP_ID]: getNameDataTestId("contentDesktop")
907
907
  } : {},
908
- children: [/* @__PURE__ */ jsx("div", {
908
+ children: [companyLogoSmallUrl ? /* @__PURE__ */ jsx("div", {
909
909
  className: classes.containerSideBarLogo,
910
910
  ...process.env.NODE_ENV !== "production" ? {
911
911
  [TEST_PROP_ID]: getNameDataTestId("containerSideBarLogo")
@@ -920,16 +920,16 @@ const ContentDesktop = () => {
920
920
  height: "60px",
921
921
  src: companyLogoSmallUrl,
922
922
  alt: "logo"
923
- }, "Logo"), /* @__PURE__ */ jsx(Typography, {
923
+ }, "Logo"), companyName ? /* @__PURE__ */ jsx(Typography, {
924
924
  variant: "subtitleDens",
925
925
  skeletonWidth: "100px",
926
926
  style: {
927
927
  width: collapsed ? "0px" : "auto"
928
928
  },
929
929
  children: companyName
930
- })]
930
+ }) : null]
931
931
  })
932
- }), /* @__PURE__ */ jsx(ContentGroups, {}), /* @__PURE__ */ jsx(CollapseButton, {
932
+ }) : null, /* @__PURE__ */ jsx(ContentGroups, {}), /* @__PURE__ */ jsx(CollapseButton, {
933
933
  onToggleCollapse,
934
934
  collapsed
935
935
  })]
@@ -996,7 +996,7 @@ const ContentMobile = () => {
996
996
  ...process.env.NODE_ENV !== "production" ? {
997
997
  [TEST_PROP_ID]: getNameDataTestId("contentMobile")
998
998
  } : {},
999
- children: [/* @__PURE__ */ jsx("div", {
999
+ children: [companyLogoSmallUrl ? /* @__PURE__ */ jsx("div", {
1000
1000
  className: classes.containerSideBarLogo,
1001
1001
  ...process.env.NODE_ENV !== "production" ? {
1002
1002
  [TEST_PROP_ID]: getNameDataTestId("containerSideBarLogo")
@@ -1017,7 +1017,7 @@ const ContentMobile = () => {
1017
1017
  children: companyName
1018
1018
  })]
1019
1019
  })
1020
- }), /* @__PURE__ */ jsx(ContentGroups, {})]
1020
+ }) : null, /* @__PURE__ */ jsx(ContentGroups, {})]
1021
1021
  })]
1022
1022
  })
1023
1023
  });
@@ -21,11 +21,11 @@ export interface SideBarProps {
21
21
  onToggleVisible: VoidFunction;
22
22
  collapsed: boolean;
23
23
  visible: boolean;
24
- companyLogoSmallUrl: string;
25
- companyLogoNormalUrl: string;
24
+ companyLogoSmallUrl?: string;
25
+ companyLogoNormalUrl?: string;
26
26
  collapsedWidht?: string | number;
27
27
  unCollapsedWidht?: string | number;
28
- companyName: string;
28
+ companyName?: string;
29
29
  }
30
30
  export declare type Classes = ReturnType<typeof getSideBarClassesByState>;
31
31
  export declare type SideBarState = Pick<SideBarProps, 'collapsed' | 'visible'>;
@@ -3,7 +3,7 @@ import { generateUtilityClasses, generateUtilityClass } from "@mui/material";
3
3
  import { unstable_composeClasses } from "@mui/base";
4
4
  import clsx from "clsx";
5
5
  import { T as TEST_PROP_ID } from "../../test/constants_no_mock.86c553a9.js";
6
- import { S as SplitterLayout } from "../../react-splitter-layout.8b1655c8.js";
6
+ import { S as SplitterLayout } from "../../react-splitter-layout.c5d98bf7.js";
7
7
  import { jsx, jsxs } from "react/jsx-runtime";
8
8
  const SplitLayoutRoot = styled("div")(({
9
9
  theme