@zauru-sdk/components 1.0.54 → 1.0.60

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 (94) hide show
  1. package/CHANGELOG.md +48 -0
  2. package/LICENCE.md +11 -11
  3. package/package.json +7 -7
  4. package/src/Alerts/ErrorBoundaryAlert/ErrorBoundaryAlert.tsx +66 -66
  5. package/src/Alerts/StaticAlert.tsx +121 -121
  6. package/src/Alerts/index.ts +2 -2
  7. package/src/BlockUI/BlockUI.tsx +50 -50
  8. package/src/BlockUI/index.tsx +1 -1
  9. package/src/Buttons/Button.tsx +90 -90
  10. package/src/Buttons/index.ts +1 -1
  11. package/src/Card/Card.tsx +24 -24
  12. package/src/Card/index.ts +1 -1
  13. package/src/Chat/ChatLayout.tsx +131 -131
  14. package/src/Chat/ChatMessageHistory.tsx +142 -142
  15. package/src/Chat/index.ts +2 -2
  16. package/src/ConnectionState/ConnectionState.tsx +27 -27
  17. package/src/ConnectionState/index.tsx +1 -1
  18. package/src/Containers/BodyContainer.tsx +14 -14
  19. package/src/Containers/ButtonSectionContainer.tsx +21 -21
  20. package/src/Containers/Container.tsx +39 -39
  21. package/src/Containers/DoubleContainer.tsx +48 -48
  22. package/src/Containers/MainContainer.tsx +17 -17
  23. package/src/Containers/OutletContainer.tsx +14 -14
  24. package/src/Containers/SubContainer.tsx +37 -37
  25. package/src/Containers/index.ts +7 -7
  26. package/src/DynamicTable/BasicPrintDynamicTable.tsx +73 -73
  27. package/src/DynamicTable/DynamicPrintTable.tsx +288 -288
  28. package/src/DynamicTable/DynamicTable.tsx +405 -405
  29. package/src/DynamicTable/GenericDynamicTable.tsx +456 -456
  30. package/src/DynamicTable/index.tsx +4 -4
  31. package/src/Footer/Footer.tsx +50 -50
  32. package/src/Footer/index.tsx +1 -1
  33. package/src/Form/Checkbox/index.tsx +96 -96
  34. package/src/Form/Checklist/index.tsx +35 -35
  35. package/src/Form/DatePicker/index.tsx +132 -132
  36. package/src/Form/DynamicBaculoForm/index.tsx +361 -361
  37. package/src/Form/FieldContainer/DoubleFieldContainer.tsx +35 -35
  38. package/src/Form/FieldContainer/QuadrupleFieldContainer.tsx +36 -36
  39. package/src/Form/FieldContainer/TripleFieldContainer.tsx +35 -35
  40. package/src/Form/FieldContainer/index.ts +3 -3
  41. package/src/Form/FileUpload/index.tsx +184 -184
  42. package/src/Form/FormButtons/index.tsx +78 -78
  43. package/src/Form/FormLayout/index.tsx +37 -37
  44. package/src/Form/SelectField/index.tsx +237 -237
  45. package/src/Form/TextArea/index.tsx +125 -125
  46. package/src/Form/TextField/index.tsx +194 -194
  47. package/src/Form/TimePicker/index.tsx +127 -127
  48. package/src/Form/YesNo/index.tsx +77 -77
  49. package/src/Form/index.ts +13 -13
  50. package/src/Labels/InfoLabel/index.tsx +21 -21
  51. package/src/Labels/index.tsx +1 -1
  52. package/src/Layouts/homeLayout/index.tsx +34 -34
  53. package/src/Layouts/index.ts +1 -1
  54. package/src/LineSeparator/LineSeparator.tsx +3 -3
  55. package/src/LineSeparator/index.tsx +1 -1
  56. package/src/Modal/Modal.tsx +104 -104
  57. package/src/Modal/index.tsx +1 -1
  58. package/src/NavBar/NavBar.tsx +223 -223
  59. package/src/NavBar/NavBar.types.ts +64 -64
  60. package/src/NavBar/NavBar.utils.ts +58 -58
  61. package/src/NavBar/index.tsx +5 -5
  62. package/src/ProgressBar/ProgressBar.tsx +25 -25
  63. package/src/ProgressBar/ProgressCircle.tsx +75 -75
  64. package/src/ProgressBar/index.tsx +2 -2
  65. package/src/Skeletons/LoadingInputSkeleton.tsx +12 -12
  66. package/src/Skeletons/index.ts +1 -1
  67. package/src/Tab/Tab.tsx +63 -63
  68. package/src/Tab/index.ts +1 -1
  69. package/src/Table/ZauruTable.tsx +265 -265
  70. package/src/Table/index.tsx +1 -1
  71. package/src/TaskList/TaskList.tsx +88 -88
  72. package/src/TaskList/index.ts +1 -1
  73. package/src/Titles/LabelArray.tsx +17 -17
  74. package/src/Titles/TableColumnTitle.tsx +9 -9
  75. package/src/Titles/TitleH1.tsx +10 -10
  76. package/src/Titles/TitleH2.tsx +10 -10
  77. package/src/Titles/TitleH3.tsx +10 -10
  78. package/src/Titles/index.ts +5 -5
  79. package/src/Tooltip/Tooltip.tsx +42 -42
  80. package/src/Tooltip/index.ts +1 -1
  81. package/src/WithTooltip/WithTooltip.tsx +21 -21
  82. package/src/WithTooltip/index.tsx +1 -1
  83. package/src/Wizards/StepWizard.tsx +88 -88
  84. package/src/Wizards/index.ts +1 -1
  85. package/src/Zendesk/Chat.tsx +83 -83
  86. package/src/Zendesk/index.ts +2 -2
  87. package/src/Zendesk/zendesk.config.ts +40 -40
  88. package/src/index.ts +24 -24
  89. package/src/postcss.config.mjs +5 -5
  90. package/src/tailwind.config.ts +10 -10
  91. package/src/tailwind.css +3 -3
  92. package/tsconfig.cjs.json +8 -8
  93. package/tsconfig.esm.json +11 -11
  94. package/tsconfig.json +17 -17
@@ -1,37 +1,37 @@
1
- import React from "react";
2
-
3
- type Props = {
4
- title?: string;
5
- description?: string;
6
- children: React.ReactNode;
7
- className?: string;
8
- rightContent?: React.ReactNode;
9
- };
10
-
11
- export const SubContainer = (props: Props) => {
12
- const { title, description, children, className = "", rightContent } = props;
13
-
14
- const titleInfo = (
15
- <>
16
- {title && (
17
- <h3 className="text-xl font-bold leading-8 text-gray-900">{title}</h3>
18
- )}
19
- {description && (
20
- <p className="mt-1 text-md text-gray-600">{description}</p>
21
- )}
22
- </>
23
- );
24
-
25
- return (
26
- <div className={`${className}`}>
27
- {rightContent && (
28
- <div className="flex justify-between items-center">
29
- <div>{titleInfo}</div>
30
- <div>{rightContent}</div>
31
- </div>
32
- )}
33
- {!rightContent && titleInfo}
34
- <div className="mt-5 space-y-3">{children}</div>
35
- </div>
36
- );
37
- };
1
+ import React from "react";
2
+
3
+ type Props = {
4
+ title?: string;
5
+ description?: string;
6
+ children: React.ReactNode;
7
+ className?: string;
8
+ rightContent?: React.ReactNode;
9
+ };
10
+
11
+ export const SubContainer = (props: Props) => {
12
+ const { title, description, children, className = "", rightContent } = props;
13
+
14
+ const titleInfo = (
15
+ <>
16
+ {title && (
17
+ <h3 className="text-xl font-bold leading-8 text-gray-900">{title}</h3>
18
+ )}
19
+ {description && (
20
+ <p className="mt-1 text-md text-gray-600">{description}</p>
21
+ )}
22
+ </>
23
+ );
24
+
25
+ return (
26
+ <div className={`${className}`}>
27
+ {rightContent && (
28
+ <div className="flex justify-between items-center">
29
+ <div>{titleInfo}</div>
30
+ <div>{rightContent}</div>
31
+ </div>
32
+ )}
33
+ {!rightContent && titleInfo}
34
+ <div className="mt-5 space-y-3">{children}</div>
35
+ </div>
36
+ );
37
+ };
@@ -1,7 +1,7 @@
1
- export * from "./BodyContainer.js";
2
- export * from "./ButtonSectionContainer.js";
3
- export * from "./Container.js";
4
- export * from "./DoubleContainer.js";
5
- export * from "./MainContainer.js";
6
- export * from "./OutletContainer.js";
7
- export * from "./SubContainer.js";
1
+ export * from "./BodyContainer.js";
2
+ export * from "./ButtonSectionContainer.js";
3
+ export * from "./Container.js";
4
+ export * from "./DoubleContainer.js";
5
+ export * from "./MainContainer.js";
6
+ export * from "./OutletContainer.js";
7
+ export * from "./SubContainer.js";
@@ -1,73 +1,73 @@
1
- import { isNumeric } from "@zauru-sdk/common";
2
- import { GenericDynamicTableColumn } from "@zauru-sdk/types";
3
-
4
- //TABLA PARA LA IMPRESION:
5
- export const BasicTableHTML = (props: {
6
- data: { [key: string]: string }[];
7
- headers: GenericDynamicTableColumn[];
8
- footer: { [key: string]: string };
9
- }) => {
10
- const { data, footer, headers } = props;
11
- return (
12
- <table style={{ borderCollapse: "collapse", width: "100%" }}>
13
- <thead>
14
- <tr>
15
- {headers?.map((titulo, index) => (
16
- <th
17
- key={index}
18
- style={{
19
- border: "1px solid black",
20
- padding: "10px",
21
- textAlign: "center",
22
- whiteSpace: "normal",
23
- }}
24
- >
25
- {titulo.label}
26
- </th>
27
- ))}
28
- </tr>
29
- </thead>
30
- <tbody>
31
- {data?.map((fila, index) => (
32
- <tr key={index}>
33
- {headers?.map((titulo, index) => (
34
- <td
35
- key={index}
36
- style={{
37
- border: "1px solid black",
38
- padding: "1px",
39
- textAlign: "center",
40
- whiteSpace: "normal",
41
- fontSize: isNumeric((fila as any)[titulo.name])
42
- ? "2em"
43
- : "1em",
44
- }}
45
- >
46
- {(fila as any)[titulo.name]}
47
- </td>
48
- ))}
49
- </tr>
50
- ))}
51
- </tbody>
52
- <tfoot>
53
- <tr>
54
- {headers?.map((titulo, index) => (
55
- <td
56
- key={index}
57
- style={{
58
- padding: "10px",
59
- textAlign: "center",
60
- whiteSpace: "normal",
61
- fontSize: isNumeric((footer as any)[titulo.name])
62
- ? "2em"
63
- : "1em",
64
- }}
65
- >
66
- {(footer as any)[titulo.name]}
67
- </td>
68
- ))}
69
- </tr>
70
- </tfoot>
71
- </table>
72
- );
73
- };
1
+ import { isNumeric } from "@zauru-sdk/common";
2
+ import { GenericDynamicTableColumn } from "@zauru-sdk/types";
3
+
4
+ //TABLA PARA LA IMPRESION:
5
+ export const BasicTableHTML = (props: {
6
+ data: { [key: string]: string }[];
7
+ headers: GenericDynamicTableColumn[];
8
+ footer: { [key: string]: string };
9
+ }) => {
10
+ const { data, footer, headers } = props;
11
+ return (
12
+ <table style={{ borderCollapse: "collapse", width: "100%" }}>
13
+ <thead>
14
+ <tr>
15
+ {headers?.map((titulo, index) => (
16
+ <th
17
+ key={index}
18
+ style={{
19
+ border: "1px solid black",
20
+ padding: "10px",
21
+ textAlign: "center",
22
+ whiteSpace: "normal",
23
+ }}
24
+ >
25
+ {titulo.label}
26
+ </th>
27
+ ))}
28
+ </tr>
29
+ </thead>
30
+ <tbody>
31
+ {data?.map((fila, index) => (
32
+ <tr key={index}>
33
+ {headers?.map((titulo, index) => (
34
+ <td
35
+ key={index}
36
+ style={{
37
+ border: "1px solid black",
38
+ padding: "1px",
39
+ textAlign: "center",
40
+ whiteSpace: "normal",
41
+ fontSize: isNumeric((fila as any)[titulo.name])
42
+ ? "2em"
43
+ : "1em",
44
+ }}
45
+ >
46
+ {(fila as any)[titulo.name]}
47
+ </td>
48
+ ))}
49
+ </tr>
50
+ ))}
51
+ </tbody>
52
+ <tfoot>
53
+ <tr>
54
+ {headers?.map((titulo, index) => (
55
+ <td
56
+ key={index}
57
+ style={{
58
+ padding: "10px",
59
+ textAlign: "center",
60
+ whiteSpace: "normal",
61
+ fontSize: isNumeric((footer as any)[titulo.name])
62
+ ? "2em"
63
+ : "1em",
64
+ }}
65
+ >
66
+ {(footer as any)[titulo.name]}
67
+ </td>
68
+ ))}
69
+ </tr>
70
+ </tfoot>
71
+ </table>
72
+ );
73
+ };