@hitachivantara/uikit-react-lab 3.56.1 → 3.57.1

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 (163) hide show
  1. package/dist/Wizard/Wizard.d.ts +63 -0
  2. package/dist/Wizard/Wizard.js +238 -0
  3. package/dist/Wizard/Wizard.js.map +1 -0
  4. package/dist/Wizard/WizardActions/WizardActions.d.ts +61 -0
  5. package/dist/Wizard/WizardActions/WizardActions.js +259 -0
  6. package/dist/Wizard/WizardActions/WizardActions.js.map +1 -0
  7. package/dist/Wizard/WizardActions/index.d.ts +2 -0
  8. package/dist/Wizard/WizardActions/index.js +16 -0
  9. package/dist/Wizard/WizardActions/index.js.map +1 -0
  10. package/dist/Wizard/WizardActions/styles.js +30 -0
  11. package/dist/Wizard/WizardActions/styles.js.map +1 -0
  12. package/dist/Wizard/WizardContainer/WizardContainer.d.ts +28 -0
  13. package/dist/Wizard/WizardContainer/WizardContainer.js +94 -0
  14. package/dist/Wizard/WizardContainer/WizardContainer.js.map +1 -0
  15. package/dist/Wizard/WizardContainer/index.d.ts +2 -0
  16. package/dist/Wizard/WizardContainer/index.js +16 -0
  17. package/dist/Wizard/WizardContainer/index.js.map +1 -0
  18. package/dist/Wizard/WizardContainer/styles.js +23 -0
  19. package/dist/Wizard/WizardContainer/styles.js.map +1 -0
  20. package/dist/Wizard/WizardContent/LoadingContainer.js +74 -0
  21. package/dist/Wizard/WizardContent/LoadingContainer.js.map +1 -0
  22. package/dist/Wizard/WizardContent/WizardContent.d.ts +28 -0
  23. package/dist/Wizard/WizardContent/WizardContent.js +163 -0
  24. package/dist/Wizard/WizardContent/WizardContent.js.map +1 -0
  25. package/dist/Wizard/WizardContent/index.d.ts +2 -0
  26. package/dist/Wizard/WizardContent/index.js +16 -0
  27. package/dist/Wizard/WizardContent/index.js.map +1 -0
  28. package/dist/Wizard/WizardContent/styles.js +24 -0
  29. package/dist/Wizard/WizardContent/styles.js.map +1 -0
  30. package/dist/Wizard/WizardContext/WizardContext.d.ts +12 -0
  31. package/dist/Wizard/WizardContext/WizardContext.js +21 -0
  32. package/dist/Wizard/WizardContext/WizardContext.js.map +1 -0
  33. package/dist/Wizard/WizardContext/WizardContextProvider.d.ts +28 -0
  34. package/dist/Wizard/WizardContext/WizardContextProvider.js +47 -0
  35. package/dist/Wizard/WizardContext/WizardContextProvider.js.map +1 -0
  36. package/dist/Wizard/WizardContext/index.d.ts +5 -0
  37. package/dist/Wizard/WizardContext/index.js +24 -0
  38. package/dist/Wizard/WizardContext/index.js.map +1 -0
  39. package/dist/Wizard/WizardTitle/WizardTitle.d.ts +40 -0
  40. package/dist/Wizard/WizardTitle/WizardTitle.js +221 -0
  41. package/dist/Wizard/WizardTitle/WizardTitle.js.map +1 -0
  42. package/dist/Wizard/WizardTitle/index.d.ts +2 -0
  43. package/dist/Wizard/WizardTitle/index.js +16 -0
  44. package/dist/Wizard/WizardTitle/index.js.map +1 -0
  45. package/dist/Wizard/WizardTitle/styles.js +41 -0
  46. package/dist/Wizard/WizardTitle/styles.js.map +1 -0
  47. package/dist/Wizard/index.d.ts +17 -0
  48. package/dist/Wizard/index.js +64 -0
  49. package/dist/Wizard/index.js.map +1 -0
  50. package/dist/Wizard/styles.js +16 -0
  51. package/dist/Wizard/styles.js.map +1 -0
  52. package/dist/index.d.ts +3 -0
  53. package/dist/index.js +22 -1
  54. package/dist/index.js.map +1 -1
  55. package/dist/legacy/Wizard/Wizard.d.ts +63 -0
  56. package/dist/legacy/Wizard/Wizard.js +211 -0
  57. package/dist/legacy/Wizard/Wizard.js.map +1 -0
  58. package/dist/legacy/Wizard/WizardActions/WizardActions.d.ts +61 -0
  59. package/dist/legacy/Wizard/WizardActions/WizardActions.js +226 -0
  60. package/dist/legacy/Wizard/WizardActions/WizardActions.js.map +1 -0
  61. package/dist/legacy/Wizard/WizardActions/index.d.ts +2 -0
  62. package/dist/legacy/Wizard/WizardActions/index.js +2 -0
  63. package/dist/legacy/Wizard/WizardActions/index.js.map +1 -0
  64. package/dist/legacy/Wizard/WizardActions/styles.js +22 -0
  65. package/dist/legacy/Wizard/WizardActions/styles.js.map +1 -0
  66. package/dist/legacy/Wizard/WizardContainer/WizardContainer.d.ts +28 -0
  67. package/dist/legacy/Wizard/WizardContainer/WizardContainer.js +75 -0
  68. package/dist/legacy/Wizard/WizardContainer/WizardContainer.js.map +1 -0
  69. package/dist/legacy/Wizard/WizardContainer/index.d.ts +2 -0
  70. package/dist/legacy/Wizard/WizardContainer/index.js +2 -0
  71. package/dist/legacy/Wizard/WizardContainer/index.js.map +1 -0
  72. package/dist/legacy/Wizard/WizardContainer/styles.js +15 -0
  73. package/dist/legacy/Wizard/WizardContainer/styles.js.map +1 -0
  74. package/dist/legacy/Wizard/WizardContent/LoadingContainer.js +58 -0
  75. package/dist/legacy/Wizard/WizardContent/LoadingContainer.js.map +1 -0
  76. package/dist/legacy/Wizard/WizardContent/WizardContent.d.ts +28 -0
  77. package/dist/legacy/Wizard/WizardContent/WizardContent.js +129 -0
  78. package/dist/legacy/Wizard/WizardContent/WizardContent.js.map +1 -0
  79. package/dist/legacy/Wizard/WizardContent/index.d.ts +2 -0
  80. package/dist/legacy/Wizard/WizardContent/index.js +2 -0
  81. package/dist/legacy/Wizard/WizardContent/index.js.map +1 -0
  82. package/dist/legacy/Wizard/WizardContent/styles.js +16 -0
  83. package/dist/legacy/Wizard/WizardContent/styles.js.map +1 -0
  84. package/dist/legacy/Wizard/WizardContext/WizardContext.d.ts +12 -0
  85. package/dist/legacy/Wizard/WizardContext/WizardContext.js +12 -0
  86. package/dist/legacy/Wizard/WizardContext/WizardContext.js.map +1 -0
  87. package/dist/legacy/Wizard/WizardContext/WizardContextProvider.d.ts +28 -0
  88. package/dist/legacy/Wizard/WizardContext/WizardContextProvider.js +35 -0
  89. package/dist/legacy/Wizard/WizardContext/WizardContextProvider.js.map +1 -0
  90. package/dist/legacy/Wizard/WizardContext/index.d.ts +5 -0
  91. package/dist/legacy/Wizard/WizardContext/index.js +3 -0
  92. package/dist/legacy/Wizard/WizardContext/index.js.map +1 -0
  93. package/dist/legacy/Wizard/WizardTitle/WizardTitle.d.ts +40 -0
  94. package/dist/legacy/Wizard/WizardTitle/WizardTitle.js +198 -0
  95. package/dist/legacy/Wizard/WizardTitle/WizardTitle.js.map +1 -0
  96. package/dist/legacy/Wizard/WizardTitle/index.d.ts +2 -0
  97. package/dist/legacy/Wizard/WizardTitle/index.js +2 -0
  98. package/dist/legacy/Wizard/WizardTitle/index.js.map +1 -0
  99. package/dist/legacy/Wizard/WizardTitle/styles.js +33 -0
  100. package/dist/legacy/Wizard/WizardTitle/styles.js.map +1 -0
  101. package/dist/legacy/Wizard/index.d.ts +17 -0
  102. package/dist/legacy/Wizard/index.js +8 -0
  103. package/dist/legacy/Wizard/index.js.map +1 -0
  104. package/dist/legacy/Wizard/styles.js +8 -0
  105. package/dist/legacy/Wizard/styles.js.map +1 -0
  106. package/dist/legacy/index.d.ts +3 -0
  107. package/dist/legacy/index.js +2 -0
  108. package/dist/legacy/index.js.map +1 -1
  109. package/dist/modern/Wizard/Wizard.d.ts +63 -0
  110. package/dist/modern/Wizard/Wizard.js +198 -0
  111. package/dist/modern/Wizard/Wizard.js.map +1 -0
  112. package/dist/modern/Wizard/WizardActions/WizardActions.d.ts +61 -0
  113. package/dist/modern/Wizard/WizardActions/WizardActions.js +186 -0
  114. package/dist/modern/Wizard/WizardActions/WizardActions.js.map +1 -0
  115. package/dist/modern/Wizard/WizardActions/index.d.ts +2 -0
  116. package/dist/modern/Wizard/WizardActions/index.js +2 -0
  117. package/dist/modern/Wizard/WizardActions/index.js.map +1 -0
  118. package/dist/modern/Wizard/WizardActions/styles.js +20 -0
  119. package/dist/modern/Wizard/WizardActions/styles.js.map +1 -0
  120. package/dist/modern/Wizard/WizardContainer/WizardContainer.d.ts +28 -0
  121. package/dist/modern/Wizard/WizardContainer/WizardContainer.js +77 -0
  122. package/dist/modern/Wizard/WizardContainer/WizardContainer.js.map +1 -0
  123. package/dist/modern/Wizard/WizardContainer/index.d.ts +2 -0
  124. package/dist/modern/Wizard/WizardContainer/index.js +2 -0
  125. package/dist/modern/Wizard/WizardContainer/index.js.map +1 -0
  126. package/dist/modern/Wizard/WizardContainer/styles.js +13 -0
  127. package/dist/modern/Wizard/WizardContainer/styles.js.map +1 -0
  128. package/dist/modern/Wizard/WizardContent/LoadingContainer.js +58 -0
  129. package/dist/modern/Wizard/WizardContent/LoadingContainer.js.map +1 -0
  130. package/dist/modern/Wizard/WizardContent/WizardContent.d.ts +28 -0
  131. package/dist/modern/Wizard/WizardContent/WizardContent.js +119 -0
  132. package/dist/modern/Wizard/WizardContent/WizardContent.js.map +1 -0
  133. package/dist/modern/Wizard/WizardContent/index.d.ts +2 -0
  134. package/dist/modern/Wizard/WizardContent/index.js +2 -0
  135. package/dist/modern/Wizard/WizardContent/index.js.map +1 -0
  136. package/dist/modern/Wizard/WizardContent/styles.js +14 -0
  137. package/dist/modern/Wizard/WizardContent/styles.js.map +1 -0
  138. package/dist/modern/Wizard/WizardContext/WizardContext.d.ts +12 -0
  139. package/dist/modern/Wizard/WizardContext/WizardContext.js +12 -0
  140. package/dist/modern/Wizard/WizardContext/WizardContext.js.map +1 -0
  141. package/dist/modern/Wizard/WizardContext/WizardContextProvider.d.ts +28 -0
  142. package/dist/modern/Wizard/WizardContext/WizardContextProvider.js +36 -0
  143. package/dist/modern/Wizard/WizardContext/WizardContextProvider.js.map +1 -0
  144. package/dist/modern/Wizard/WizardContext/index.d.ts +5 -0
  145. package/dist/modern/Wizard/WizardContext/index.js +3 -0
  146. package/dist/modern/Wizard/WizardContext/index.js.map +1 -0
  147. package/dist/modern/Wizard/WizardTitle/WizardTitle.d.ts +40 -0
  148. package/dist/modern/Wizard/WizardTitle/WizardTitle.js +182 -0
  149. package/dist/modern/Wizard/WizardTitle/WizardTitle.js.map +1 -0
  150. package/dist/modern/Wizard/WizardTitle/index.d.ts +2 -0
  151. package/dist/modern/Wizard/WizardTitle/index.js +2 -0
  152. package/dist/modern/Wizard/WizardTitle/index.js.map +1 -0
  153. package/dist/modern/Wizard/WizardTitle/styles.js +31 -0
  154. package/dist/modern/Wizard/WizardTitle/styles.js.map +1 -0
  155. package/dist/modern/Wizard/index.d.ts +17 -0
  156. package/dist/modern/Wizard/index.js +8 -0
  157. package/dist/modern/Wizard/index.js.map +1 -0
  158. package/dist/modern/Wizard/styles.js +6 -0
  159. package/dist/modern/Wizard/styles.js.map +1 -0
  160. package/dist/modern/index.d.ts +3 -0
  161. package/dist/modern/index.js +2 -0
  162. package/dist/modern/index.js.map +1 -1
  163. package/package.json +3 -3
@@ -0,0 +1,119 @@
1
+ import _defineProperty from "@babel/runtime/helpers/esm/defineProperty";
2
+ import "core-js/modules/web.dom-collections.iterator.js";
3
+
4
+ function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); enumerableOnly && (symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
5
+
6
+ function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? ownKeys(Object(source), !0).forEach(function (key) { _defineProperty(target, key, source[key]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } return target; }
7
+
8
+ import React from "react";
9
+ import PropTypes from "prop-types";
10
+ import { withStyles } from "@material-ui/core";
11
+ import clsx from "clsx";
12
+ import { HvDialogContent } from "@hitachivantara/uikit-react-core";
13
+ import HvWizardContext from "../WizardContext";
14
+ import LoadingContainer from "./LoadingContainer";
15
+ import styles from "./styles";
16
+
17
+ const HvWizardContent = ({
18
+ classes,
19
+ fixedHeight = false,
20
+ loading = false,
21
+ children,
22
+ tab
23
+ }) => {
24
+ const arrayChildren = React.Children.toArray(children);
25
+ const initialContext = arrayChildren.reduce((acc, child, index) => {
26
+ const invalid = child.props.mustValidate === true ? false : null;
27
+ const valid = invalid !== null && invalid !== void 0 ? invalid : index === 0 || null;
28
+ return _objectSpread(_objectSpread({}, acc), {}, {
29
+ [index]: _objectSpread(_objectSpread({}, child.props), {}, {
30
+ form: {},
31
+ valid,
32
+ touched: index === 0
33
+ })
34
+ });
35
+ }, {});
36
+ const {
37
+ context,
38
+ setContext
39
+ } = React.useContext(HvWizardContext);
40
+ React.useEffect(() => {
41
+ setContext(initialContext);
42
+ }, []); // eslint-disable-line react-hooks/exhaustive-deps
43
+
44
+ React.useEffect(() => {
45
+ var _context$tab;
46
+
47
+ if (tab && !((_context$tab = context[tab]) !== null && _context$tab !== void 0 && _context$tab.touched)) {
48
+ const updatedContext = Object.entries(context).reduce((acc, [key, childState]) => {
49
+ var _childState$valid;
50
+
51
+ return _objectSpread(_objectSpread({}, acc), +key <= tab ? {
52
+ [key]: _objectSpread(_objectSpread({}, childState), {}, {
53
+ touched: true,
54
+ valid: (_childState$valid = childState.valid) !== null && _childState$valid !== void 0 ? _childState$valid : true
55
+ })
56
+ } : {
57
+ [key]: childState
58
+ });
59
+ }, {});
60
+ setContext(updatedContext);
61
+ }
62
+ }, [tab]); // eslint-disable-line react-hooks/exhaustive-deps
63
+
64
+ return /*#__PURE__*/React.createElement(HvDialogContent, {
65
+ className: clsx(classes.contentContainer, fixedHeight && classes.fixedHeight),
66
+ indentContent: true
67
+ }, /*#__PURE__*/React.createElement(LoadingContainer, {
68
+ hidden: !loading
69
+ }, React.Children.map(arrayChildren, (child, index) => {
70
+ if (index === tab) {
71
+ return /*#__PURE__*/React.cloneElement(child, {
72
+ tab
73
+ });
74
+ }
75
+
76
+ return null;
77
+ })));
78
+ };
79
+
80
+ process.env.NODE_ENV !== "production" ? HvWizardContent.propTypes = {
81
+ /**
82
+ * Current tab to show.
83
+ */
84
+ tab: PropTypes.number.isRequired,
85
+
86
+ /**
87
+ * Tabs to show on the Wizard.
88
+ */
89
+ children: PropTypes.node.isRequired,
90
+
91
+ /**
92
+ * A Jss Object used to override or extend the styles applied.
93
+ */
94
+ classes: PropTypes.shape({
95
+ /**
96
+ * Style applied to the Wizard content container
97
+ */
98
+ contentContainer: PropTypes.string,
99
+
100
+ /**
101
+ * Style applied to the Wizard to fix its height.
102
+ */
103
+ fixedHeight: PropTypes.string
104
+ }).isRequired,
105
+
106
+ /**
107
+ * Forces minimum height to the component.
108
+ */
109
+ fixedHeight: PropTypes.bool,
110
+
111
+ /**
112
+ * Whether the loading animation is shown.
113
+ */
114
+ loading: PropTypes.bool
115
+ } : void 0;
116
+ export default withStyles(styles, {
117
+ name: "HvWizardContent"
118
+ })(HvWizardContent);
119
+ //# sourceMappingURL=WizardContent.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"WizardContent.js","names":["React","PropTypes","withStyles","clsx","HvDialogContent","HvWizardContext","LoadingContainer","styles","HvWizardContent","classes","fixedHeight","loading","children","tab","arrayChildren","Children","toArray","initialContext","reduce","acc","child","index","invalid","props","mustValidate","valid","form","touched","context","setContext","useContext","useEffect","updatedContext","Object","entries","key","childState","contentContainer","map","cloneElement","propTypes","number","isRequired","node","shape","string","bool","name"],"sources":["../../../../src/Wizard/WizardContent/WizardContent.js"],"sourcesContent":["import React from \"react\";\nimport PropTypes from \"prop-types\";\nimport { withStyles } from \"@material-ui/core\";\nimport clsx from \"clsx\";\nimport { HvDialogContent } from \"@hitachivantara/uikit-react-core\";\nimport HvWizardContext from \"../WizardContext\";\nimport LoadingContainer from \"./LoadingContainer\";\n\nimport styles from \"./styles\";\n\nconst HvWizardContent = ({ classes, fixedHeight = false, loading = false, children, tab }) => {\n const arrayChildren = React.Children.toArray(children);\n const initialContext = arrayChildren.reduce((acc, child, index) => {\n const invalid = child.props.mustValidate === true ? false : null;\n const valid = invalid ?? (index === 0 || null);\n return {\n ...acc,\n [index]: { ...child.props, form: {}, valid, touched: index === 0 },\n };\n }, {});\n\n const { context, setContext } = React.useContext(HvWizardContext);\n\n React.useEffect(() => {\n setContext(initialContext);\n }, []); // eslint-disable-line react-hooks/exhaustive-deps\n\n React.useEffect(() => {\n if (tab && !context[tab]?.touched) {\n const updatedContext = Object.entries(context).reduce(\n (acc, [key, childState]) => ({\n ...acc,\n ...(+key <= tab\n ? { [key]: { ...childState, touched: true, valid: childState.valid ?? true } }\n : { [key]: childState }),\n }),\n {}\n );\n\n setContext(updatedContext);\n }\n }, [tab]); // eslint-disable-line react-hooks/exhaustive-deps\n\n return (\n <HvDialogContent\n className={clsx(classes.contentContainer, {\n [classes.fixedHeight]: fixedHeight,\n })}\n indentContent\n >\n <LoadingContainer hidden={!loading}>\n {React.Children.map(arrayChildren, (child, index) => {\n if (index === tab) {\n return React.cloneElement(child, { tab });\n }\n return null;\n })}\n </LoadingContainer>\n </HvDialogContent>\n );\n};\n\nHvWizardContent.propTypes = {\n /**\n * Current tab to show.\n */\n tab: PropTypes.number.isRequired,\n /**\n * Tabs to show on the Wizard.\n */\n children: PropTypes.node.isRequired,\n /**\n * A Jss Object used to override or extend the styles applied.\n */\n classes: PropTypes.shape({\n /**\n * Style applied to the Wizard content container\n */\n contentContainer: PropTypes.string,\n /**\n * Style applied to the Wizard to fix its height.\n */\n fixedHeight: PropTypes.string,\n }).isRequired,\n /**\n * Forces minimum height to the component.\n */\n fixedHeight: PropTypes.bool,\n /**\n * Whether the loading animation is shown.\n */\n loading: PropTypes.bool,\n};\n\nexport default withStyles(styles, { name: \"HvWizardContent\" })(HvWizardContent);\n"],"mappings":";;;;;;;AAAA,OAAOA,KAAP,MAAkB,OAAlB;AACA,OAAOC,SAAP,MAAsB,YAAtB;AACA,SAASC,UAAT,QAA2B,mBAA3B;AACA,OAAOC,IAAP,MAAiB,MAAjB;AACA,SAASC,eAAT,QAAgC,kCAAhC;AACA,OAAOC,eAAP,MAA4B,kBAA5B;AACA,OAAOC,gBAAP,MAA6B,oBAA7B;AAEA,OAAOC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,CAAC6C,IAzBG;;EA0B1B;AACF;AACA;EACEnC,OAAO,EAAEV,SAAS,CAAC6C;AA7BO,CAA5B;AAgCA,eAAe5C,UAAU,CAACK,MAAD,EAAS;EAAEwC,IAAI,EAAE;AAAR,CAAT,CAAV,CAAgDvC,eAAhD,CAAf"}
@@ -0,0 +1,2 @@
1
+ export { default } from "./WizardContent";
2
+ export * from "./WizardContent";
@@ -0,0 +1,2 @@
1
+ export { default } from "./WizardContent";
2
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.js","names":["default"],"sources":["../../../../src/Wizard/WizardContent/index.js"],"sourcesContent":["export { default } from \"./WizardContent\";\n"],"mappings":"AAAA,SAASA,OAAT,QAAwB,iBAAxB"}
@@ -0,0 +1,14 @@
1
+ const styles = () => ({
2
+ contentContainer: {
3
+ position: "relative",
4
+ padding: 20,
5
+ marginLeft: 0,
6
+ minHeight: 400
7
+ },
8
+ fixedHeight: {
9
+ minHeight: "calc(100vh - 387px)"
10
+ }
11
+ });
12
+
13
+ export default styles;
14
+ //# sourceMappingURL=styles.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"styles.js","names":["styles","contentContainer","position","padding","marginLeft","minHeight","fixedHeight"],"sources":["../../../../src/Wizard/WizardContent/styles.js"],"sourcesContent":["const styles = () => ({\n contentContainer: {\n position: \"relative\",\n padding: 20,\n marginLeft: 0,\n minHeight: 400,\n },\n fixedHeight: {\n minHeight: \"calc(100vh - 387px)\",\n },\n});\n\nexport default styles;\n"],"mappings":"AAAA,MAAMA,MAAM,GAAG,OAAO;EACpBC,gBAAgB,EAAE;IAChBC,QAAQ,EAAE,UADM;IAEhBC,OAAO,EAAE,EAFO;IAGhBC,UAAU,EAAE,CAHI;IAIhBC,SAAS,EAAE;EAJK,CADE;EAOpBC,WAAW,EAAE;IACXD,SAAS,EAAE;EADA;AAPO,CAAP,CAAf;;AAYA,eAAeL,MAAf"}
@@ -0,0 +1,12 @@
1
+ import React from "react";
2
+
3
+ export type HvWizardContextClassKey = "root";
4
+
5
+ export type HvWizardContextProps = {
6
+ context: any;
7
+ setContext: () => void;
8
+ };
9
+
10
+ export default function HvWizardContext(
11
+ props: HvWizardContextProps
12
+ ): React.Context<HvWizardContextProps>;
@@ -0,0 +1,12 @@
1
+ import { createContext } from "react";
2
+ const WizardContext = /*#__PURE__*/createContext({
3
+ context: {},
4
+ setContext: () => {}
5
+ });
6
+
7
+ if (process.env.NODE_ENV !== "production") {
8
+ WizardContext.displayName = "WizardContext";
9
+ }
10
+
11
+ export default WizardContext;
12
+ //# sourceMappingURL=WizardContext.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"WizardContext.js","names":["createContext","WizardContext","context","setContext","process","env","NODE_ENV","displayName"],"sources":["../../../../src/Wizard/WizardContext/WizardContext.js"],"sourcesContent":["import { createContext } from \"react\";\n\nconst WizardContext = createContext({\n context: {},\n setContext: () => {},\n});\n\nif (process.env.NODE_ENV !== \"production\") {\n WizardContext.displayName = \"WizardContext\";\n}\n\nexport default WizardContext;\n"],"mappings":"AAAA,SAASA,aAAT,QAA8B,OAA9B;AAEA,MAAMC,aAAa,gBAAGD,aAAa,CAAC;EAClCE,OAAO,EAAE,EADyB;EAElCC,UAAU,EAAE,MAAM,CAAE;AAFc,CAAD,CAAnC;;AAKA,IAAIC,OAAO,CAACC,GAAR,CAAYC,QAAZ,KAAyB,YAA7B,EAA2C;EACzCL,aAAa,CAACM,WAAd,GAA4B,eAA5B;AACD;;AAED,eAAeN,aAAf"}
@@ -0,0 +1,28 @@
1
+ import { StandardProps } from "@material-ui/core";
2
+
3
+ export type HvWizardContextProviderClassKey = "root";
4
+
5
+ export interface HvWizardContextProviderProps
6
+ extends StandardProps<React.HTMLAttributes<HTMLDivElement>, HvWizardContextProviderClassKey> {
7
+ /**
8
+ * Initial context value
9
+ */
10
+ value?: {
11
+ /**
12
+ * Initial context object
13
+ */
14
+ context: any;
15
+ /**
16
+ * Function to modify the context
17
+ */
18
+ setContext: React.Dispatch<React.SetStateAction<Record<string, unknown>>>;
19
+ };
20
+ /**
21
+ * Child components for the Wizard
22
+ */
23
+ children?: React.ReactNode;
24
+ }
25
+
26
+ export default function HvWizardContextProvider(
27
+ props: HvWizardContextProviderProps
28
+ ): JSX.Element | null;
@@ -0,0 +1,36 @@
1
+ import React from "react";
2
+ import PropTypes from "prop-types";
3
+ import HvWizardContext from "./WizardContext";
4
+
5
+ const WizardContextProvider = ({
6
+ value,
7
+ children
8
+ }) => {
9
+ return /*#__PURE__*/React.createElement(HvWizardContext.Provider, {
10
+ value: value
11
+ }, children);
12
+ };
13
+
14
+ process.env.NODE_ENV !== "production" ? WizardContextProvider.propTypes = {
15
+ /**
16
+ * Initial context value
17
+ */
18
+ value: PropTypes.shape({
19
+ /**
20
+ * Initial context object
21
+ */
22
+ context: PropTypes.shape({}),
23
+
24
+ /**
25
+ * Function to modify the context
26
+ */
27
+ setContext: PropTypes.func
28
+ }),
29
+
30
+ /**
31
+ * Child components for the Wizard
32
+ */
33
+ children: PropTypes.node.isRequired
34
+ } : void 0;
35
+ export default WizardContextProvider;
36
+ //# sourceMappingURL=WizardContextProvider.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"WizardContextProvider.js","names":["React","PropTypes","HvWizardContext","WizardContextProvider","value","children","propTypes","shape","context","setContext","func","node","isRequired"],"sources":["../../../../src/Wizard/WizardContext/WizardContextProvider.js"],"sourcesContent":["import React from \"react\";\nimport PropTypes from \"prop-types\";\nimport HvWizardContext from \"./WizardContext\";\n\nconst WizardContextProvider = ({ value, children }) => {\n return <HvWizardContext.Provider value={value}>{children}</HvWizardContext.Provider>;\n};\n\nWizardContextProvider.propTypes = {\n /**\n * Initial context value\n */\n value: PropTypes.shape({\n /**\n * Initial context object\n */\n context: PropTypes.shape({}),\n /**\n * Function to modify the context\n */\n setContext: PropTypes.func,\n }),\n /**\n * Child components for the Wizard\n */\n children: PropTypes.node.isRequired,\n};\n\nexport default WizardContextProvider;\n"],"mappings":"AAAA,OAAOA,KAAP,MAAkB,OAAlB;AACA,OAAOC,SAAP,MAAsB,YAAtB;AACA,OAAOC,eAAP,MAA4B,iBAA5B;;AAEA,MAAMC,qBAAqB,GAAG,CAAC;EAAEC,KAAF;EAASC;AAAT,CAAD,KAAyB;EACrD,oBAAO,oBAAC,eAAD,CAAiB,QAAjB;IAA0B,KAAK,EAAED;EAAjC,GAAyCC,QAAzC,CAAP;AACD,CAFD;;AAIA,wCAAAF,qBAAqB,CAACG,SAAtB,GAAkC;EAChC;AACF;AACA;EACEF,KAAK,EAAEH,SAAS,CAACM,KAAV,CAAgB;IACrB;AACJ;AACA;IACIC,OAAO,EAAEP,SAAS,CAACM,KAAV,CAAgB,EAAhB,CAJY;;IAKrB;AACJ;AACA;IACIE,UAAU,EAAER,SAAS,CAACS;EARD,CAAhB,CAJyB;;EAchC;AACF;AACA;EACEL,QAAQ,EAAEJ,SAAS,CAACU,IAAV,CAAeC;AAjBO,CAAlC;AAoBA,eAAeT,qBAAf"}
@@ -0,0 +1,5 @@
1
+ export { default } from "./WizardContext";
2
+ export * from "./WizardContext";
3
+
4
+ export { default as HvWizardContextProvider } from "./WizardContextProvider";
5
+ export * from "./WizardContextProvider";
@@ -0,0 +1,3 @@
1
+ export { default } from "./WizardContext";
2
+ export { default as HvWizardContextProvider } from "./WizardContextProvider";
3
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.js","names":["default","HvWizardContextProvider"],"sources":["../../../../src/Wizard/WizardContext/index.js"],"sourcesContent":["export { default } from \"./WizardContext\";\nexport { default as HvWizardContextProvider } from \"./WizardContextProvider\";\n"],"mappings":"AAAA,SAASA,OAAT,QAAwB,iBAAxB;AACA,SAASA,OAAO,IAAIC,uBAApB,QAAmD,yBAAnD"}
@@ -0,0 +1,40 @@
1
+ import * as React from "react";
2
+ import { StandardProps } from "@material-ui/core";
3
+ import { HvStepNavigationProps } from "../../StepNavigation";
4
+
5
+ export type HvWizardTitleClassKey = "root";
6
+
7
+ export interface HvWizardTitleProps
8
+ extends StandardProps<React.HTMLAttributes<HTMLDivElement>, HvWizardTitleClassKey> {
9
+ /**
10
+ * Title for the wizard.
11
+ */
12
+ title?: string;
13
+ /**
14
+ * Shows the summary button.
15
+ */
16
+ hasSummary?: boolean;
17
+ /**
18
+ * An object containing all the labels for the wizard header.
19
+ */
20
+ labels?: {
21
+ /**
22
+ * Summary button label.
23
+ */
24
+ summary: string;
25
+ };
26
+ /**
27
+ * Current tab to check if it's last page or first to disable previous button and swap between next and submit button.
28
+ */
29
+ tab: number;
30
+ /**
31
+ * Function to change the tab when pressing previous and next buttons.
32
+ */
33
+ changeTab: any;
34
+ /**
35
+ * Custom object to define type, size and width of the StepNavigation component
36
+ */
37
+ customStep?: Pick<HvStepNavigationProps, "type" | "stepSize" | "width">;
38
+ }
39
+
40
+ export default function HvWizardTitle(props: HvWizardTitleProps): JSX.Element | null;
@@ -0,0 +1,182 @@
1
+ var _Report;
2
+
3
+ import "core-js/modules/web.dom-collections.iterator.js";
4
+ import React from "react";
5
+ import PropTypes from "prop-types";
6
+ import { withStyles } from "@material-ui/core";
7
+ import { HvButton, HvDialogTitle, HvGrid, HvTypography } from "@hitachivantara/uikit-react-core";
8
+ import { Report } from "@hitachivantara/uikit-react-icons";
9
+ import { HvStepNavigation } from "@hitachivantara/uikit-react-lab";
10
+ import HvWizardContext from "../WizardContext";
11
+ import styles from "./styles";
12
+
13
+ const switchTabState = (state, currentTab, index) => {
14
+ if (index === currentTab) return "Current";
15
+ if (state.valid) return "Completed";
16
+ if (state.valid === null) return "Enabled";
17
+ if (state.touched && state.valid === false) return "Failed"; // "Disabled"
18
+ // "Pending"
19
+
20
+ return "Enabled";
21
+ };
22
+
23
+ const HvWizardTitle = ({
24
+ title,
25
+ hasSummary = false,
26
+ labels = {},
27
+ tab,
28
+ classes,
29
+ changeTab,
30
+ customStep = {}
31
+ }) => {
32
+ var _customStep$type, _customStep$stepSize, _customStep$width, _labels$summary;
33
+
34
+ const {
35
+ context
36
+ } = React.useContext(HvWizardContext);
37
+ const [steps, setSteps] = React.useState([]);
38
+ React.useEffect(() => {
39
+ const contextArray = Object.entries(context);
40
+
41
+ if (contextArray.length) {
42
+ const updatedSteps = contextArray.map(([, childState], index) => {
43
+ var _childState$name;
44
+
45
+ return {
46
+ title: (_childState$name = childState.name) !== null && _childState$name !== void 0 ? _childState$name : `${index + 1}`,
47
+ state: switchTabState(childState, tab, index),
48
+ onClick: () => changeTab(index)
49
+ };
50
+ });
51
+ setSteps(updatedSteps);
52
+ }
53
+ }, [context, tab, changeTab]);
54
+ return /*#__PURE__*/React.createElement(HvDialogTitle, {
55
+ className: classes.headerContainer,
56
+ classes: {
57
+ messageContainer: classes.messageContainer
58
+ }
59
+ }, /*#__PURE__*/React.createElement(HvGrid, {
60
+ container: true,
61
+ justifyContent: "space-between",
62
+ alignItems: "center",
63
+ className: classes.titleContainer
64
+ }, title && /*#__PURE__*/React.createElement(HvTypography, {
65
+ variant: "xsTitle",
66
+ component: "h3"
67
+ }, title), !!steps.length && /*#__PURE__*/React.createElement(HvStepNavigation, {
68
+ className: classes.stepContainer,
69
+ steps: steps,
70
+ type: (_customStep$type = customStep === null || customStep === void 0 ? void 0 : customStep.type) !== null && _customStep$type !== void 0 ? _customStep$type : "Default",
71
+ stepSize: (_customStep$stepSize = customStep === null || customStep === void 0 ? void 0 : customStep.stepSize) !== null && _customStep$stepSize !== void 0 ? _customStep$stepSize : "XS",
72
+ width: (_customStep$width = customStep === null || customStep === void 0 ? void 0 : customStep.width) !== null && _customStep$width !== void 0 ? _customStep$width : {
73
+ xs: 200,
74
+ sm: 350,
75
+ md: 600,
76
+ lg: 800
77
+ }
78
+ }), hasSummary && /*#__PURE__*/React.createElement(HvButton, {
79
+ category: "secondary",
80
+ className: classes.buttonWidth,
81
+ classes: {
82
+ root: classes.rootSummaryButton
83
+ }
84
+ }, _Report || (_Report = /*#__PURE__*/React.createElement(Report, null)), " ", `${(_labels$summary = labels.summary) !== null && _labels$summary !== void 0 ? _labels$summary : "Summary"}`)));
85
+ };
86
+
87
+ process.env.NODE_ENV !== "production" ? HvWizardTitle.propTypes = {
88
+ /**
89
+ * A Jss Object used to override or extend the styles applied.
90
+ */
91
+ classes: PropTypes.shape({
92
+ /**
93
+ * Styles applied to the header container.
94
+ */
95
+ headerContainer: PropTypes.string,
96
+
97
+ /**
98
+ * Styles applied to override the Dialog Title styles.
99
+ */
100
+ messageContainer: PropTypes.string,
101
+
102
+ /**
103
+ * Styles applied to the header content container.
104
+ */
105
+ titleContainer: PropTypes.string,
106
+
107
+ /**
108
+ * Styles applied to the Button component to override its width.
109
+ */
110
+ buttonWidth: PropTypes.string,
111
+
112
+ /**
113
+ * Styles applied to the Button component to override its right padding.
114
+ */
115
+ rootSummaryButton: PropTypes.string,
116
+
117
+ /**
118
+ *
119
+ */
120
+ stepContainer: PropTypes.string
121
+ }),
122
+
123
+ /**
124
+ * Title for the wizard.
125
+ */
126
+ title: PropTypes.string,
127
+
128
+ /**
129
+ * Shows the summary button.
130
+ */
131
+ hasSummary: PropTypes.bool,
132
+
133
+ /**
134
+ * An object containing all the labels for the wizard header.
135
+ */
136
+ labels: PropTypes.shape({
137
+ /**
138
+ * Summary button label.
139
+ */
140
+ summary: PropTypes.string
141
+ }),
142
+
143
+ /**
144
+ * Current tab to check if it's last page or first to disable previous button and swap between next and submit button.
145
+ */
146
+ tab: PropTypes.number.isRequired,
147
+
148
+ /**
149
+ * Function to change the tab when pressing previous and next buttons.
150
+ */
151
+ changeTab: PropTypes.func.isRequired,
152
+
153
+ /**
154
+ * Custom object to define type, size and width of the StepNavigation component
155
+ */
156
+ customStep: PropTypes.shape({
157
+ /**
158
+ * Type of step navigation. Values = {"Simple", "Default"}.
159
+ */
160
+ type: PropTypes.oneOf(["Simple", "Default"]),
161
+
162
+ /**
163
+ * Sets one of the standard sizes of the steps. Values = {"XS", "SM", "MD", "LG", "XL"}
164
+ */
165
+ stepSize: PropTypes.oneOf(["XS", "SM", "MD", "LG", "XL"]),
166
+
167
+ /**
168
+ * Width of the component element on each breakpoint screen resolution.
169
+ */
170
+ width: PropTypes.shape({
171
+ xs: PropTypes.number,
172
+ sm: PropTypes.number,
173
+ md: PropTypes.number,
174
+ lg: PropTypes.number,
175
+ xl: PropTypes.number
176
+ })
177
+ })
178
+ } : void 0;
179
+ export default withStyles(styles, {
180
+ name: "HvWizardTitle"
181
+ })(HvWizardTitle);
182
+ //# sourceMappingURL=WizardTitle.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"WizardTitle.js","names":["React","PropTypes","withStyles","HvButton","HvDialogTitle","HvGrid","HvTypography","Report","HvStepNavigation","HvWizardContext","styles","switchTabState","state","currentTab","index","valid","touched","HvWizardTitle","title","hasSummary","labels","tab","classes","changeTab","customStep","context","useContext","steps","setSteps","useState","useEffect","contextArray","Object","entries","length","updatedSteps","map","childState","name","onClick","headerContainer","messageContainer","titleContainer","stepContainer","type","stepSize","width","xs","sm","md","lg","buttonWidth","root","rootSummaryButton","summary","propTypes","shape","string","bool","number","isRequired","func","oneOf","xl"],"sources":["../../../../src/Wizard/WizardTitle/WizardTitle.js"],"sourcesContent":["import React from \"react\";\nimport PropTypes from \"prop-types\";\nimport { withStyles } from \"@material-ui/core\";\nimport { HvButton, HvDialogTitle, HvGrid, HvTypography } from \"@hitachivantara/uikit-react-core\";\nimport { Report } from \"@hitachivantara/uikit-react-icons\";\nimport { HvStepNavigation } from \"@hitachivantara/uikit-react-lab\";\nimport HvWizardContext from \"../WizardContext\";\n\nimport styles from \"./styles\";\n\nconst switchTabState = (state, currentTab, index) => {\n if (index === currentTab) return \"Current\";\n if (state.valid) return \"Completed\";\n if (state.valid === null) return \"Enabled\";\n if (state.touched && state.valid === false) return \"Failed\";\n // \"Disabled\"\n // \"Pending\"\n return \"Enabled\";\n};\n\nconst HvWizardTitle = ({\n title,\n hasSummary = false,\n labels = {},\n tab,\n classes,\n changeTab,\n customStep = {},\n}) => {\n const { context } = React.useContext(HvWizardContext);\n const [steps, setSteps] = React.useState([]);\n\n React.useEffect(() => {\n const contextArray = Object.entries(context);\n if (contextArray.length) {\n const updatedSteps = contextArray.map(([, childState], index) => ({\n title: childState.name ?? `${index + 1}`,\n state: switchTabState(childState, tab, index),\n onClick: () => changeTab(index),\n }));\n\n setSteps(updatedSteps);\n }\n }, [context, tab, changeTab]);\n\n return (\n <HvDialogTitle\n className={classes.headerContainer}\n classes={{ messageContainer: classes.messageContainer }}\n >\n <HvGrid\n container\n justifyContent=\"space-between\"\n alignItems=\"center\"\n className={classes.titleContainer}\n >\n {title && (\n <HvTypography variant=\"xsTitle\" component=\"h3\">\n {title}\n </HvTypography>\n )}\n {!!steps.length && (\n <HvStepNavigation\n className={classes.stepContainer}\n steps={steps}\n type={customStep?.type ?? \"Default\"}\n stepSize={customStep?.stepSize ?? \"XS\"}\n width={customStep?.width ?? { xs: 200, sm: 350, md: 600, lg: 800 }}\n />\n )}\n {hasSummary && (\n <HvButton\n category=\"secondary\"\n className={classes.buttonWidth}\n classes={{ root: classes.rootSummaryButton }}\n >\n <Report /> {`${labels.summary ?? \"Summary\"}`}\n </HvButton>\n )}\n </HvGrid>\n </HvDialogTitle>\n );\n};\n\nHvWizardTitle.propTypes = {\n /**\n * A Jss Object used to override or extend the styles applied.\n */\n classes: PropTypes.shape({\n /**\n * Styles applied to the header container.\n */\n headerContainer: PropTypes.string,\n /**\n * Styles applied to override the Dialog Title styles.\n */\n messageContainer: PropTypes.string,\n /**\n * Styles applied to the header content container.\n */\n titleContainer: PropTypes.string,\n /**\n * Styles applied to the Button component to override its width.\n */\n buttonWidth: PropTypes.string,\n /**\n * Styles applied to the Button component to override its right padding.\n */\n rootSummaryButton: PropTypes.string,\n /**\n *\n */\n stepContainer: PropTypes.string,\n }),\n /**\n * Title for the wizard.\n */\n title: PropTypes.string,\n /**\n * Shows the summary button.\n */\n hasSummary: PropTypes.bool,\n /**\n * An object containing all the labels for the wizard header.\n */\n labels: PropTypes.shape({\n /**\n * Summary button label.\n */\n summary: PropTypes.string,\n }),\n /**\n * Current tab to check if it's last page or first to disable previous button and swap between next and submit button.\n */\n tab: PropTypes.number.isRequired,\n /**\n * Function to change the tab when pressing previous and next buttons.\n */\n changeTab: PropTypes.func.isRequired,\n /**\n * Custom object to define type, size and width of the StepNavigation component\n */\n customStep: PropTypes.shape({\n /**\n * Type of step navigation. Values = {\"Simple\", \"Default\"}.\n */\n type: PropTypes.oneOf([\"Simple\", \"Default\"]),\n /**\n * Sets one of the standard sizes of the steps. Values = {\"XS\", \"SM\", \"MD\", \"LG\", \"XL\"}\n */\n stepSize: PropTypes.oneOf([\"XS\", \"SM\", \"MD\", \"LG\", \"XL\"]),\n /**\n * Width of the component element on each breakpoint screen resolution.\n */\n width: PropTypes.shape({\n xs: PropTypes.number,\n sm: PropTypes.number,\n md: PropTypes.number,\n lg: PropTypes.number,\n xl: PropTypes.number,\n }),\n }),\n};\n\nexport default withStyles(styles, { name: \"HvWizardTitle\" })(HvWizardTitle);\n"],"mappings":";;;AAAA,OAAOA,KAAP,MAAkB,OAAlB;AACA,OAAOC,SAAP,MAAsB,YAAtB;AACA,SAASC,UAAT,QAA2B,mBAA3B;AACA,SAASC,QAAT,EAAmBC,aAAnB,EAAkCC,MAAlC,EAA0CC,YAA1C,QAA8D,kCAA9D;AACA,SAASC,MAAT,QAAuB,mCAAvB;AACA,SAASC,gBAAT,QAAiC,iCAAjC;AACA,OAAOC,eAAP,MAA4B,kBAA5B;AAEA,OAAOC,MAAP,MAAmB,UAAnB;;AAEA,MAAMC,cAAc,GAAG,CAACC,KAAD,EAAQC,UAAR,EAAoBC,KAApB,KAA8B;EACnD,IAAIA,KAAK,KAAKD,UAAd,EAA0B,OAAO,SAAP;EAC1B,IAAID,KAAK,CAACG,KAAV,EAAiB,OAAO,WAAP;EACjB,IAAIH,KAAK,CAACG,KAAN,KAAgB,IAApB,EAA0B,OAAO,SAAP;EAC1B,IAAIH,KAAK,CAACI,OAAN,IAAiBJ,KAA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DY,CAA1B;AAgFA,eAAezD,UAAU,CAACQ,MAAD,EAAS;EAAE4B,IAAI,EAAE;AAAR,CAAT,CAAV,CAA8CrB,aAA9C,CAAf"}
@@ -0,0 +1,2 @@
1
+ export { default } from "./WizardTitle";
2
+ export * from "./WizardTitle";
@@ -0,0 +1,2 @@
1
+ export { default } from "./WizardTitle";
2
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.js","names":["default"],"sources":["../../../../src/Wizard/WizardTitle/index.js"],"sourcesContent":["export { default } from \"./WizardTitle\";\n"],"mappings":"AAAA,SAASA,OAAT,QAAwB,eAAxB"}
@@ -0,0 +1,31 @@
1
+ const styles = theme => ({
2
+ messageContainer: {
3
+ "& > div": {
4
+ width: "100%"
5
+ }
6
+ },
7
+ titleContainer: {
8
+ margin: 0,
9
+ width: "100%"
10
+ },
11
+ buttonWidth: {
12
+ width: 120
13
+ },
14
+ rootSummaryButton: {
15
+ paddingRight: 18
16
+ },
17
+ headerContainer: {
18
+ backgroundColor: theme.hv.palette.atmosphere.atmo2,
19
+ "& h6": {
20
+ fontSize: "16px",
21
+ fontWeight: "bold",
22
+ letterSpacing: 0
23
+ }
24
+ },
25
+ stepContainer: {
26
+ margin: "auto"
27
+ }
28
+ });
29
+
30
+ export default styles;
31
+ //# sourceMappingURL=styles.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"styles.js","names":["styles","theme","messageContainer","width","titleContainer","margin","buttonWidth","rootSummaryButton","paddingRight","headerContainer","backgroundColor","hv","palette","atmosphere","atmo2","fontSize","fontWeight","letterSpacing","stepContainer"],"sources":["../../../../src/Wizard/WizardTitle/styles.js"],"sourcesContent":["const styles = (theme) => ({\n messageContainer: {\n \"& > div\": {\n width: \"100%\",\n },\n },\n titleContainer: {\n margin: 0,\n width: \"100%\",\n },\n buttonWidth: {\n width: 120,\n },\n rootSummaryButton: {\n paddingRight: 18,\n },\n headerContainer: {\n backgroundColor: theme.hv.palette.atmosphere.atmo2,\n \"& h6\": {\n fontSize: \"16px\",\n fontWeight: \"bold\",\n letterSpacing: 0,\n },\n },\n stepContainer: {\n margin: \"auto\",\n },\n});\n\nexport default styles;\n"],"mappings":"AAAA,MAAMA,MAAM,GAAIC,KAAD,KAAY;EACzBC,gBAAgB,EAAE;IAChB,WAAW;MACTC,KAAK,EAAE;IADE;EADK,CADO;EAMzBC,cAAc,EAAE;IACdC,MAAM,EAAE,CADM;IAEdF,KAAK,EAAE;EAFO,CANS;EAUzBG,WAAW,EAAE;IACXH,KAAK,EAAE;EADI,CAVY;EAazBI,iBAAiB,EAAE;IACjBC,YAAY,EAAE;EADG,CAbM;EAgBzBC,eAAe,EAAE;IACfC,eAAe,EAAET,KAAK,CAACU,EAAN,CAASC,OAAT,CAAiBC,UAAjB,CAA4BC,KAD9B;IAEf,QAAQ;MACNC,QAAQ,EAAE,MADJ;MAENC,UAAU,EAAE,MAFN;MAGNC,aAAa,EAAE;IAHT;EAFO,CAhBQ;EAwBzBC,aAAa,EAAE;IACbb,MAAM,EAAE;EADK;AAxBU,CAAZ,CAAf;;AA6BA,eAAeL,MAAf"}
@@ -0,0 +1,17 @@
1
+ export { default } from "./Wizard";
2
+ export * from "./Wizard";
3
+
4
+ export { default as HvWizardContainer } from "./WizardContainer";
5
+ export * from "./WizardContainer";
6
+
7
+ export { default as HvWizardTitle } from "./WizardTitle";
8
+ export * from "./WizardTitle";
9
+
10
+ export { default as HvWizardContent } from "./WizardContent";
11
+ export * from "./WizardContent";
12
+
13
+ export { default as HvWizardActions } from "./WizardActions";
14
+ export * from "./WizardActions";
15
+
16
+ export { default as HvWizardContext } from "./WizardContext";
17
+ export * from "./WizardContext";
@@ -0,0 +1,8 @@
1
+ export { default } from "./Wizard";
2
+ export { default as HvWizardContainer } from "./WizardContainer";
3
+ export { default as HvWizardTitle } from "./WizardTitle";
4
+ export { default as HvWizardContent } from "./WizardContent";
5
+ export { default as HvWizardActions } from "./WizardActions";
6
+ export { default as HvWizardContext } from "./WizardContext";
7
+ export { default as HvWizardContextProvider } from "./WizardContext/WizardContextProvider";
8
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.js","names":["default","HvWizardContainer","HvWizardTitle","HvWizardContent","HvWizardActions","HvWizardContext","HvWizardContextProvider"],"sources":["../../../src/Wizard/index.js"],"sourcesContent":["export { default } from \"./Wizard\";\nexport { default as HvWizardContainer } from \"./WizardContainer\";\nexport { default as HvWizardTitle } from \"./WizardTitle\";\nexport { default as HvWizardContent } from \"./WizardContent\";\nexport { default as HvWizardActions } from \"./WizardActions\";\nexport { default as HvWizardContext } from \"./WizardContext\";\nexport { default as HvWizardContextProvider } from \"./WizardContext/WizardContextProvider\";\n"],"mappings":"AAAA,SAASA,OAAT,QAAwB,UAAxB;AACA,SAASA,OAAO,IAAIC,iBAApB,QAA6C,mBAA7C;AACA,SAASD,OAAO,IAAIE,aAApB,QAAyC,eAAzC;AACA,SAASF,OAAO,IAAIG,eAApB,QAA2C,iBAA3C;AACA,SAASH,OAAO,IAAII,eAApB,QAA2C,iBAA3C;AACA,SAASJ,OAAO,IAAIK,eAApB,QAA2C,iBAA3C;AACA,SAASL,OAAO,IAAIM,uBAApB,QAAmD,uCAAnD"}
@@ -0,0 +1,6 @@
1
+ const styles = () => ({
2
+ root: {}
3
+ });
4
+
5
+ export default styles;
6
+ //# sourceMappingURL=styles.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"styles.js","names":["styles","root"],"sources":["../../../src/Wizard/styles.js"],"sourcesContent":["const styles = () => ({\n root: {},\n});\n\nexport default styles;\n"],"mappings":"AAAA,MAAMA,MAAM,GAAG,OAAO;EACpBC,IAAI,EAAE;AADc,CAAP,CAAf;;AAIA,eAAeD,MAAf"}
@@ -51,3 +51,6 @@ export * from "./StepNavigation";
51
51
 
52
52
  export { default as HvImageCarousel } from "./ImageCarousel";
53
53
  export * from "./ImageCarousel";
54
+
55
+ export { default as HvWizard } from "./Wizard";
56
+ export * from "./Wizard";
@@ -22,4 +22,6 @@ export { default as HvProgressBar } from "./ProgressBar";
22
22
  export { default as HvDotPagination } from "./DotPagination";
23
23
  export { default as HvStepNavigation } from "./StepNavigation";
24
24
  export { default as HvImageCarousel } from "./ImageCarousel";
25
+ export { default as HvWizard } from "./Wizard";
26
+ export * from "./Wizard";
25
27
  //# sourceMappingURL=index.js.map