@dxc-technology/halstack-react 0.0.0-a25956f → 0.0.0-a3f5d07

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 (258) hide show
  1. package/{dist/BackgroundColorContext.js → BackgroundColorContext.js} +0 -0
  2. package/ThemeContext.js +250 -0
  3. package/{dist/select/Select.js → V3Select/V3Select.js} +193 -189
  4. package/V3Select/index.d.ts +27 -0
  5. package/{dist/textarea/Textarea.js → V3Textarea/V3Textarea.js} +30 -26
  6. package/V3Textarea/index.d.ts +27 -0
  7. package/{dist/accordion → accordion}/Accordion.js +72 -59
  8. package/accordion/index.d.ts +28 -0
  9. package/{dist/accordion-group → accordion-group}/AccordionGroup.js +1 -3
  10. package/accordion-group/index.d.ts +16 -0
  11. package/{dist/alert → alert}/Alert.js +126 -111
  12. package/alert/index.d.ts +51 -0
  13. package/{dist/badge → badge}/Badge.js +0 -0
  14. package/{dist/box → box}/Box.js +1 -9
  15. package/box/index.d.ts +25 -0
  16. package/button/Button.js +238 -0
  17. package/button/Button.stories.js +27 -0
  18. package/button/index.d.ts +24 -0
  19. package/{dist/card → card}/Card.js +0 -0
  20. package/card/index.d.ts +22 -0
  21. package/{dist/checkbox → checkbox}/Checkbox.js +33 -25
  22. package/checkbox/index.d.ts +24 -0
  23. package/{dist/chip → chip}/Chip.js +21 -25
  24. package/chip/index.d.ts +22 -0
  25. package/{dist/common → common}/OpenSans.css +0 -0
  26. package/{dist/common → common}/RequiredComponent.js +0 -0
  27. package/{dist/common → common}/fonts/OpenSans-Bold.ttf +0 -0
  28. package/{dist/common → common}/fonts/OpenSans-BoldItalic.ttf +0 -0
  29. package/{dist/common → common}/fonts/OpenSans-ExtraBold.ttf +0 -0
  30. package/{dist/common → common}/fonts/OpenSans-ExtraBoldItalic.ttf +0 -0
  31. package/{dist/common → common}/fonts/OpenSans-Italic.ttf +0 -0
  32. package/{dist/common → common}/fonts/OpenSans-Light.ttf +0 -0
  33. package/{dist/common → common}/fonts/OpenSans-LightItalic.ttf +0 -0
  34. package/{dist/common → common}/fonts/OpenSans-Regular.ttf +0 -0
  35. package/{dist/common → common}/fonts/OpenSans-SemiBold.ttf +0 -0
  36. package/{dist/common → common}/fonts/OpenSans-SemiBoldItalic.ttf +0 -0
  37. package/{dist/common → common}/utils.js +0 -0
  38. package/common/variables.js +1567 -0
  39. package/{dist/date → date}/Date.js +17 -29
  40. package/date/index.d.ts +27 -0
  41. package/date-input/DateInput.js +400 -0
  42. package/date-input/index.d.ts +95 -0
  43. package/{dist/dialog → dialog}/Dialog.js +21 -39
  44. package/dialog/index.d.ts +18 -0
  45. package/{dist/dropdown → dropdown}/Dropdown.js +123 -71
  46. package/dropdown/index.d.ts +26 -0
  47. package/file-input/FileInput.js +644 -0
  48. package/file-input/FileItem.js +287 -0
  49. package/file-input/index.d.ts +81 -0
  50. package/{dist/footer → footer}/Footer.js +69 -53
  51. package/footer/Icons.js +77 -0
  52. package/footer/index.d.ts +25 -0
  53. package/{dist/header → header}/Header.js +123 -84
  54. package/header/Icons.js +59 -0
  55. package/header/index.d.ts +25 -0
  56. package/{dist/heading → heading}/Heading.js +13 -5
  57. package/heading/index.d.ts +17 -0
  58. package/input-text/Icons.js +22 -0
  59. package/{dist/input-text → input-text}/InputText.js +97 -61
  60. package/input-text/index.d.ts +36 -0
  61. package/{dist/layout → layout}/ApplicationLayout.js +5 -9
  62. package/layout/Icons.js +55 -0
  63. package/{dist/link → link}/Link.js +23 -26
  64. package/link/index.d.ts +23 -0
  65. package/main.d.ts +40 -0
  66. package/{dist/main.js → main.js} +62 -14
  67. package/number-input/NumberInput.js +136 -0
  68. package/number-input/NumberInputContext.js +16 -0
  69. package/number-input/index.d.ts +113 -0
  70. package/package.json +23 -17
  71. package/paginator/Icons.js +66 -0
  72. package/{dist/paginator → paginator}/Paginator.js +60 -38
  73. package/paginator/index.d.ts +20 -0
  74. package/password-input/PasswordInput.js +203 -0
  75. package/password-input/index.d.ts +94 -0
  76. package/{dist/progress-bar → progress-bar}/ProgressBar.js +63 -27
  77. package/progress-bar/index.d.ts +18 -0
  78. package/{dist/radio → radio}/Radio.js +0 -0
  79. package/radio/index.d.ts +23 -0
  80. package/{dist/resultsetTable → resultsetTable}/ResultsetTable.js +5 -22
  81. package/resultsetTable/index.d.ts +19 -0
  82. package/select/Select.js +1138 -0
  83. package/select/index.d.ts +131 -0
  84. package/{dist/sidenav → sidenav}/Sidenav.js +11 -15
  85. package/sidenav/index.d.ts +13 -0
  86. package/{dist/slider → slider}/Slider.js +155 -66
  87. package/slider/index.d.ts +29 -0
  88. package/spinner/Spinner.js +381 -0
  89. package/spinner/index.d.ts +17 -0
  90. package/{dist/switch → switch}/Switch.js +0 -0
  91. package/switch/index.d.ts +24 -0
  92. package/{dist/table → table}/Table.js +6 -2
  93. package/table/index.d.ts +13 -0
  94. package/{dist/tabs → tabs}/Tabs.js +0 -0
  95. package/tabs/index.d.ts +19 -0
  96. package/{dist/tag → tag}/Tag.js +38 -36
  97. package/tag/index.d.ts +24 -0
  98. package/text-input/TextInput.js +992 -0
  99. package/text-input/index.d.ts +135 -0
  100. package/textarea/Textarea.js +369 -0
  101. package/textarea/index.d.ts +117 -0
  102. package/{dist/toggle → toggle}/Toggle.js +0 -0
  103. package/toggle/index.d.ts +21 -0
  104. package/toggle-group/ToggleGroup.js +327 -0
  105. package/toggle-group/index.d.ts +21 -0
  106. package/{dist/upload → upload}/Upload.js +0 -0
  107. package/{dist/upload → upload}/buttons-upload/ButtonsUpload.js +13 -13
  108. package/upload/buttons-upload/Icons.js +40 -0
  109. package/{dist/upload → upload}/dragAndDropArea/DragAndDropArea.js +27 -23
  110. package/upload/dragAndDropArea/Icons.js +39 -0
  111. package/{dist/upload → upload}/file-upload/FileToUpload.js +29 -24
  112. package/upload/file-upload/Icons.js +66 -0
  113. package/{dist/upload → upload}/files-upload/FilesToUpload.js +0 -0
  114. package/upload/index.d.ts +15 -0
  115. package/upload/transaction/Icons.js +160 -0
  116. package/{dist/upload → upload}/transaction/Transaction.js +19 -42
  117. package/{dist/upload → upload}/transactions/Transactions.js +11 -11
  118. package/{dist/useTheme.js → useTheme.js} +0 -0
  119. package/wizard/Icons.js +65 -0
  120. package/{dist/wizard → wizard}/Wizard.js +85 -63
  121. package/wizard/index.d.ts +18 -0
  122. package/README.md +0 -66
  123. package/babel.config.js +0 -8
  124. package/dist/ThemeContext.js +0 -216
  125. package/dist/accordion/Accordion.stories.js +0 -207
  126. package/dist/accordion/readme.md +0 -96
  127. package/dist/accordion-group/AccordionGroup.stories.js +0 -207
  128. package/dist/accordion-group/readme.md +0 -70
  129. package/dist/alert/Alert.stories.js +0 -158
  130. package/dist/alert/close.svg +0 -4
  131. package/dist/alert/error.svg +0 -4
  132. package/dist/alert/info.svg +0 -4
  133. package/dist/alert/readme.md +0 -43
  134. package/dist/alert/success.svg +0 -4
  135. package/dist/alert/warning.svg +0 -4
  136. package/dist/button/Button.js +0 -228
  137. package/dist/button/Button.stories.js +0 -224
  138. package/dist/button/readme.md +0 -93
  139. package/dist/checkbox/Checkbox.stories.js +0 -144
  140. package/dist/checkbox/readme.md +0 -116
  141. package/dist/common/variables.js +0 -1160
  142. package/dist/date/Date.stories.js +0 -205
  143. package/dist/date/calendar.svg +0 -1
  144. package/dist/date/calendar_dark.svg +0 -1
  145. package/dist/date/readme.md +0 -73
  146. package/dist/dialog/Dialog.stories.js +0 -217
  147. package/dist/dialog/readme.md +0 -32
  148. package/dist/dropdown/Dropdown.stories.js +0 -249
  149. package/dist/dropdown/baseline-arrow_drop_down.svg +0 -1
  150. package/dist/dropdown/baseline-arrow_drop_down_wh.svg +0 -4
  151. package/dist/dropdown/baseline-arrow_drop_up.svg +0 -1
  152. package/dist/dropdown/baseline-arrow_drop_up_wh.svg +0 -4
  153. package/dist/dropdown/readme.md +0 -69
  154. package/dist/footer/Footer.stories.js +0 -94
  155. package/dist/footer/dxc_logo_wht.png +0 -0
  156. package/dist/footer/readme.md +0 -41
  157. package/dist/header/Header.stories.js +0 -176
  158. package/dist/header/close_icon.svg +0 -1
  159. package/dist/header/dxc_logo_black.png +0 -0
  160. package/dist/header/dxc_logo_blk_rgb.svg +0 -6
  161. package/dist/header/dxc_logo_white.png +0 -0
  162. package/dist/header/hamb_menu_black.svg +0 -1
  163. package/dist/header/hamb_menu_white.svg +0 -1
  164. package/dist/header/readme.md +0 -33
  165. package/dist/input-text/InputText.stories.js +0 -209
  166. package/dist/input-text/error.svg +0 -1
  167. package/dist/input-text/readme.md +0 -91
  168. package/dist/layout/facebook.svg +0 -45
  169. package/dist/layout/linkedin.svg +0 -50
  170. package/dist/layout/twitter.svg +0 -53
  171. package/dist/link/readme.md +0 -51
  172. package/dist/paginator/images/next.svg +0 -3
  173. package/dist/paginator/images/nextPage.svg +0 -3
  174. package/dist/paginator/images/previous.svg +0 -3
  175. package/dist/paginator/images/previousPage.svg +0 -3
  176. package/dist/paginator/readme.md +0 -50
  177. package/dist/progress-bar/ProgressBar.stories.js +0 -280
  178. package/dist/progress-bar/readme.md +0 -63
  179. package/dist/radio/Radio.stories.js +0 -166
  180. package/dist/radio/readme.md +0 -70
  181. package/dist/resultsetTable/arrow_downward-24px_wht.svg +0 -1
  182. package/dist/resultsetTable/arrow_upward-24px_wht.svg +0 -1
  183. package/dist/resultsetTable/unfold_more-24px_wht.svg +0 -1
  184. package/dist/select/Select.stories.js +0 -235
  185. package/dist/select/readme.md +0 -72
  186. package/dist/slider/Slider.stories.js +0 -241
  187. package/dist/slider/readme.md +0 -64
  188. package/dist/spinner/Spinner.js +0 -214
  189. package/dist/spinner/Spinner.stories.js +0 -183
  190. package/dist/spinner/readme.md +0 -65
  191. package/dist/switch/Switch.stories.js +0 -134
  192. package/dist/switch/readme.md +0 -133
  193. package/dist/tabs/Tabs.stories.js +0 -130
  194. package/dist/tabs/readme.md +0 -78
  195. package/dist/tabs-for-sections/TabsForSections.js +0 -92
  196. package/dist/tabs-for-sections/readme.md +0 -78
  197. package/dist/toggle/Toggle.stories.js +0 -297
  198. package/dist/toggle/readme.md +0 -80
  199. package/dist/toggle-group/ToggleGroup.js +0 -241
  200. package/dist/toggle-group/readme.md +0 -82
  201. package/dist/upload/Upload.stories.js +0 -72
  202. package/dist/upload/buttons-upload/drag-drop-icon.svg +0 -4
  203. package/dist/upload/buttons-upload/upload-button.svg +0 -1
  204. package/dist/upload/dragAndDropArea/upload_drop.svg +0 -4
  205. package/dist/upload/dragAndDropArea/upload_file.svg +0 -4
  206. package/dist/upload/file-upload/audio-icon.svg +0 -4
  207. package/dist/upload/file-upload/close.svg +0 -4
  208. package/dist/upload/file-upload/file-icon.svg +0 -4
  209. package/dist/upload/file-upload/video-icon.svg +0 -4
  210. package/dist/upload/readme.md +0 -37
  211. package/dist/upload/transaction/audio-icon-err.svg +0 -4
  212. package/dist/upload/transaction/audio-icon.svg +0 -4
  213. package/dist/upload/transaction/error-icon.svg +0 -4
  214. package/dist/upload/transaction/file-icon-err.svg +0 -4
  215. package/dist/upload/transaction/file-icon.svg +0 -4
  216. package/dist/upload/transaction/image-icon-err.svg +0 -4
  217. package/dist/upload/transaction/image-icon.svg +0 -4
  218. package/dist/upload/transaction/success-icon.svg +0 -4
  219. package/dist/upload/transaction/video-icon-err.svg +0 -4
  220. package/dist/upload/transaction/video-icon.svg +0 -4
  221. package/dist/wizard/invalid_icon.svg +0 -6
  222. package/dist/wizard/valid_icon.svg +0 -6
  223. package/dist/wizard/validation-wrong.svg +0 -6
  224. package/test/Accordion.test.js +0 -33
  225. package/test/AccordionGroup.test.js +0 -125
  226. package/test/Alert.test.js +0 -53
  227. package/test/Box.test.js +0 -10
  228. package/test/Button.test.js +0 -18
  229. package/test/Card.test.js +0 -30
  230. package/test/Checkbox.test.js +0 -45
  231. package/test/Chip.test.js +0 -25
  232. package/test/Date.test.js +0 -393
  233. package/test/Dialog.test.js +0 -23
  234. package/test/Dropdown.test.js +0 -130
  235. package/test/Footer.test.js +0 -99
  236. package/test/Header.test.js +0 -39
  237. package/test/Heading.test.js +0 -35
  238. package/test/InputText.test.js +0 -240
  239. package/test/Link.test.js +0 -43
  240. package/test/Paginator.test.js +0 -177
  241. package/test/ProgressBar.test.js +0 -35
  242. package/test/Radio.test.js +0 -37
  243. package/test/ResultsetTable.test.js +0 -330
  244. package/test/Select.test.js +0 -192
  245. package/test/Sidenav.test.js +0 -45
  246. package/test/Slider.test.js +0 -82
  247. package/test/Spinner.test.js +0 -27
  248. package/test/Switch.test.js +0 -45
  249. package/test/Table.test.js +0 -36
  250. package/test/Tabs.test.js +0 -109
  251. package/test/TabsForSections.test.js +0 -34
  252. package/test/Tag.test.js +0 -32
  253. package/test/TextArea.test.js +0 -52
  254. package/test/ToggleGroup.test.js +0 -81
  255. package/test/Upload.test.js +0 -60
  256. package/test/Wizard.test.js +0 -130
  257. package/test/mocks/pngMock.js +0 -1
  258. package/test/mocks/svgMock.js +0 -1
@@ -0,0 +1,94 @@
1
+ type Size = "small" | "medium" | "large" | "fillParent";
2
+ type Space = "xxsmall" | "xsmall" | "small" | "medium" | "large" | "xlarge" | "xxlarge";
3
+ type Margin = {
4
+ top?: Space;
5
+ bottom?: Space;
6
+ left?: Space;
7
+ right?: Space;
8
+ };
9
+
10
+ type Props = {
11
+ /**
12
+ * Text to be placed above the password.
13
+ */
14
+ label?: string;
15
+ /**
16
+ * Name attribute of the input element.
17
+ */
18
+ name?: string;
19
+ /**
20
+ * Value of the input element. If undefined, the component will be uncontrolled and the value will be managed internally by the component.
21
+ */
22
+ value?: string;
23
+ /**
24
+ * Helper text to be placed above the password.
25
+ */
26
+ helperText?: string;
27
+ /**
28
+ * If true, the password input will have an action to clear the entered value.
29
+ */
30
+ clearable?: boolean;
31
+ /**
32
+ * This function will be called when the user types within the input
33
+ * element of the component. An object including the current value and
34
+ * the error (if the value entered is not valid) will be passed to this
35
+ * function. If there is no error, error will be null.
36
+ * */
37
+ onChange?: (val: { value: string; error: string }) => void;
38
+ /**
39
+ * This function will be called when the input element loses the focus.
40
+ * An object including the input value and the error (if the value entered is
41
+ * not valid) will be passed to this function. If there is no error, error will be null.
42
+ */
43
+ onBlur?: (val: { value: string; error: string }) => void;
44
+ /**
45
+ * If it is defined, the component will change its appearance, showing
46
+ * the error below the password input component. If it is not defined, the
47
+ * error messages will be managed internally, but never displayed on its own.
48
+ */
49
+ error?: string;
50
+ /**
51
+ * Regular expression that defines the valid format allowed by the
52
+ * password input. This will be checked both when the input element loses the
53
+ * focus and while typing within it. If the string entered does not match
54
+ * the pattern, the onBlur and onChange functions will be called with the
55
+ * current value and an internal error informing that this value does not
56
+ * match the pattern. If the pattern is met, the error parameter of both
57
+ * events will be null.
58
+ */
59
+ pattern?: string;
60
+ /**
61
+ * Specifies the minimun and maximum length allowed by the password input.
62
+ * This will be checked both when the input element loses the
63
+ * focus and while typing within it. If the string entered does not
64
+ * comply the length, the onBlur and onChange functions will be called
65
+ * with the current value and an internal error informing that the value
66
+ * length does not comply the specified range. If a valid length is
67
+ * reached, the error parameter of both events will be null.
68
+ */
69
+ length?: { min?: number; max?: number };
70
+ /**
71
+ * HTML autocomplete attribute. Lets the user specify if any permission the user agent has to provide automated assistance in filling out the input value.
72
+ * Its value must be one of all the possible values of the HTML autocomplete attribute: 'on', 'off', 'email', 'username', 'new-password', ...
73
+ */
74
+ autocomplete?: string;
75
+ /**
76
+ * Size of the margin to be applied to the component ('xxsmall' | 'xsmall' | 'small' | 'medium' | 'large' | 'xlarge' | 'xxlarge').
77
+ * You can pass an object with 'top', 'bottom', 'left' and 'right' properties in order to specify different margin sizes.
78
+ */
79
+ margin?: Space | Margin;
80
+ /**
81
+ * Size of the component ('small' | 'medium' | 'large' | 'fillParent').
82
+ */
83
+ size?: Size;
84
+ /**
85
+ * Value of the tabindex attribute.
86
+ */
87
+ tabIndex?: number;
88
+ /**
89
+ * Reference to the component.
90
+ */
91
+ ref?: React.RefObject<HTMLDivElement>;
92
+ };
93
+
94
+ export default function DxcPasswordInput(props: Props): JSX.Element;
@@ -9,13 +9,13 @@ Object.defineProperty(exports, "__esModule", {
9
9
  });
10
10
  exports["default"] = void 0;
11
11
 
12
+ var _toConsumableArray2 = _interopRequireDefault(require("@babel/runtime/helpers/toConsumableArray"));
13
+
12
14
  var _typeof2 = _interopRequireDefault(require("@babel/runtime/helpers/typeof"));
13
15
 
14
16
  var _taggedTemplateLiteral2 = _interopRequireDefault(require("@babel/runtime/helpers/taggedTemplateLiteral"));
15
17
 
16
- var _toConsumableArray2 = _interopRequireDefault(require("@babel/runtime/helpers/toConsumableArray"));
17
-
18
- var _react = _interopRequireDefault(require("react"));
18
+ var _react = _interopRequireWildcard(require("react"));
19
19
 
20
20
  var _styledComponents = _interopRequireWildcard(require("styled-components"));
21
21
 
@@ -27,6 +27,18 @@ var _variables = require("../common/variables.js");
27
27
 
28
28
  var _useTheme = _interopRequireDefault(require("../useTheme.js"));
29
29
 
30
+ var _BackgroundColorContext = _interopRequireDefault(require("../BackgroundColorContext.js"));
31
+
32
+ function _templateObject6() {
33
+ var data = (0, _taggedTemplateLiteral2["default"])(["\n color: ", ";\n font-family: ", ";\n font-size: ", ";\n font-style: ", ";\n font-weight: ", ";\n line-height: 1.5em;\n"]);
34
+
35
+ _templateObject6 = function _templateObject6() {
36
+ return data;
37
+ };
38
+
39
+ return data;
40
+ }
41
+
30
42
  function _templateObject5() {
31
43
  var data = (0, _taggedTemplateLiteral2["default"])(["\n font-family: ", ";\n font-style: ", ";\n font-size: ", ";\n font-weight: ", ";\n text-transform: ", ";\n color: ", ";\n display: ", ";\n flex-shrink: 0;\n"]);
32
44
 
@@ -58,7 +70,7 @@ function _templateObject3() {
58
70
  }
59
71
 
60
72
  function _templateObject2() {
61
- var data = (0, _taggedTemplateLiteral2["default"])(["\n z-index: ", ";\n width: ", ";\n .MuiLinearProgress-root {\n height: ", ";\n background-color: ", ";\n border-radius: ", ";\n }\n .MuiLinearProgress-bar {\n background-color: ", ";\n }\n margin: ", ";\n margin-top: ", ";\n margin-right: ", ";\n margin-bottom: ", ";\n margin-left: ", ";\n"]);
73
+ var data = (0, _taggedTemplateLiteral2["default"])(["\n z-index: ", ";\n width: ", ";\n .MuiLinearProgress-root {\n height: ", ";\n background-color: ", ";\n border-radius: ", ";\n margin-bottom: ", ";\n }\n .MuiLinearProgress-bar {\n background-color: ", ";\n }\n margin: ", ";\n margin-top: ", ";\n margin-right: ", ";\n margin-bottom: ", ";\n margin-left: ", ";\n"]);
62
74
 
63
75
  _templateObject2 = function _templateObject2() {
64
76
  return data;
@@ -68,7 +80,7 @@ function _templateObject2() {
68
80
  }
69
81
 
70
82
  function _templateObject() {
71
- var data = (0, _taggedTemplateLiteral2["default"])(["\n background-color: ", ";\n opacity: ", ";\n width: ", ";\n display: flex;\n flex-wrap: wrap;\n justify-content: ", ";\n height: ", ";\n align-items: ", ";\n min-width: 685px;\n max-width: ", ";\n position: ", ";\n top: ", ";\n bottom: ", ";\n left: ", ";\n right: ", ";\n z-index: ", ";\n"]);
83
+ var data = (0, _taggedTemplateLiteral2["default"])(["\n background-color: ", ";\n opacity: ", ";\n width: ", ";\n display: flex;\n flex-wrap: wrap;\n justify-content: ", ";\n height: ", ";\n align-items: ", ";\n min-width: 100px;\n max-width: ", ";\n position: ", ";\n top: ", ";\n bottom: ", ";\n left: ", ";\n right: ", ";\n z-index: ", ";\n width: 100%;\n"]);
72
84
 
73
85
  _templateObject = function _templateObject() {
74
86
  return data;
@@ -80,6 +92,8 @@ function _templateObject() {
80
92
  var DxcProgressBar = function DxcProgressBar(_ref) {
81
93
  var _ref$label = _ref.label,
82
94
  label = _ref$label === void 0 ? "" : _ref$label,
95
+ _ref$helperText = _ref.helperText,
96
+ helperText = _ref$helperText === void 0 ? "" : _ref$helperText,
83
97
  _ref$overlay = _ref.overlay,
84
98
  overlay = _ref$overlay === void 0 ? true : _ref$overlay,
85
99
  value = _ref.value,
@@ -87,35 +101,30 @@ var DxcProgressBar = function DxcProgressBar(_ref) {
87
101
  showValue = _ref$showValue === void 0 ? false : _ref$showValue,
88
102
  margin = _ref.margin;
89
103
  var colorsTheme = (0, _useTheme["default"])();
104
+ var backgroundType = (0, _react.useContext)(_BackgroundColorContext["default"]);
90
105
  return _react["default"].createElement(_styledComponents.ThemeProvider, {
91
106
  theme: colorsTheme.progressBar
92
107
  }, _react["default"].createElement(BackgroundProgressBar, {
93
108
  overlay: overlay
94
109
  }, _react["default"].createElement(DXCProgressBar, {
95
110
  overlay: overlay,
96
- margin: margin
111
+ margin: margin,
112
+ backgroundType: backgroundType
97
113
  }, _react["default"].createElement(InfoProgressBar, null, _react["default"].createElement(ProgressBarLabel, {
98
- overlay: overlay
114
+ overlay: overlay,
115
+ backgroundType: backgroundType
99
116
  }, label), _react["default"].createElement(ProgressBarProgress, {
100
117
  overlay: overlay,
101
- showValue: showValue
118
+ showValue: showValue,
119
+ backgroundType: backgroundType
102
120
  }, value === "" ? 0 : value >= 0 && value <= 100 ? value : value < 0 ? 0 : 100, " %")), _react["default"].createElement(_LinearProgress["default"], {
103
121
  variant: showValue ? "determinate" : "indeterminate",
104
- value: value === "" ? 0 : value >= 0 && value <= 100 ? value : value < 0 ? 0 : 100
105
- }))));
106
- };
107
-
108
- DxcProgressBar.propTypes = {
109
- label: _propTypes["default"].string,
110
- overlay: _propTypes["default"].bool,
111
- value: _propTypes["default"].number,
112
- showValue: _propTypes["default"].bool,
113
- margin: _propTypes["default"].oneOfType([_propTypes["default"].shape({
114
- top: _propTypes["default"].oneOf(Object.keys(_variables.spaces)),
115
- bottom: _propTypes["default"].oneOf(Object.keys(_variables.spaces)),
116
- left: _propTypes["default"].oneOf(Object.keys(_variables.spaces)),
117
- right: _propTypes["default"].oneOf(Object.keys(_variables.spaces))
118
- }), _propTypes["default"].oneOf((0, _toConsumableArray2["default"])(Object.keys(_variables.spaces)))])
122
+ value: value === "" ? 0 : value >= 0 && value <= 100 ? value : value < 0 ? 0 : 100,
123
+ helperText: helperText
124
+ }), helperText && _react["default"].createElement(HelperText, {
125
+ overlay: overlay,
126
+ backgroundType: backgroundType
127
+ }, helperText))));
119
128
  };
120
129
 
121
130
  var BackgroundProgressBar = _styledComponents["default"].div(_templateObject(), function (props) {
@@ -143,7 +152,7 @@ var BackgroundProgressBar = _styledComponents["default"].div(_templateObject(),
143
152
  }, function (props) {
144
153
  return props.overlay === true ? "0" : "";
145
154
  }, function (props) {
146
- return props.overlay ? 1000 : "";
155
+ return props.overlay ? 1300 : "";
147
156
  });
148
157
 
149
158
  var DXCProgressBar = _styledComponents["default"].div(_templateObject2(), function (props) {
@@ -157,7 +166,9 @@ var DXCProgressBar = _styledComponents["default"].div(_templateObject2(), functi
157
166
  }, function (props) {
158
167
  return props.theme.borderRadius;
159
168
  }, function (props) {
160
- return props.theme.trackLineColor;
169
+ return props.helperText !== "" && "8px";
170
+ }, function (props) {
171
+ return props.backgroundType === "dark" ? props.theme.trackLineColorOnDark : props.theme.trackLineColor;
161
172
  }, function (props) {
162
173
  return props.margin && (0, _typeof2["default"])(props.margin) !== "object" ? _variables.spaces[props.margin] : "0px";
163
174
  }, function (props) {
@@ -183,7 +194,7 @@ var ProgressBarLabel = _styledComponents["default"].div(_templateObject4(), func
183
194
  }, function (props) {
184
195
  return props.theme.labelFontTextTransform;
185
196
  }, function (props) {
186
- return props.overlay === true ? "#FFFFFF" : props.theme.labelFontColor;
197
+ return props.backgroundType === "dark" ? props.theme.labelFontColorOnDark : props.overlay === true ? "#FFFFFF" : props.theme.labelFontColor;
187
198
  });
188
199
 
189
200
  var ProgressBarProgress = _styledComponents["default"].div(_templateObject5(), function (props) {
@@ -197,10 +208,35 @@ var ProgressBarProgress = _styledComponents["default"].div(_templateObject5(), f
197
208
  }, function (props) {
198
209
  return props.theme.valueFontTextTransform;
199
210
  }, function (props) {
200
- return props.overlay === true ? "#FFFFFF" : props.theme.valueFontColor;
211
+ return props.backgroundType === "dark" ? props.theme.valueFontColorOnDark : props.overlay === true ? "#FFFFFF" : props.theme.valueFontColor;
201
212
  }, function (props) {
202
213
  return props.value !== "" && props.showValue === true && "block" || "none";
203
214
  });
204
215
 
216
+ var HelperText = _styledComponents["default"].span(_templateObject6(), function (props) {
217
+ return props.backgroundType === "dark" ? props.theme.helperTextFontColorOnDark : props.overlay === true ? "#FFFFFF" : props.theme.helperTextFontColor;
218
+ }, function (props) {
219
+ return props.theme.fontFamily;
220
+ }, function (props) {
221
+ return props.theme.helperTextFontSize;
222
+ }, function (props) {
223
+ return props.theme.helperTextFontStyle;
224
+ }, function (props) {
225
+ return props.theme.helperTextFontWeight;
226
+ });
227
+
228
+ DxcProgressBar.propTypes = {
229
+ label: _propTypes["default"].string,
230
+ helperText: _propTypes["default"].string,
231
+ overlay: _propTypes["default"].bool,
232
+ value: _propTypes["default"].number,
233
+ showValue: _propTypes["default"].bool,
234
+ margin: _propTypes["default"].oneOfType([_propTypes["default"].shape({
235
+ top: _propTypes["default"].oneOf(Object.keys(_variables.spaces)),
236
+ bottom: _propTypes["default"].oneOf(Object.keys(_variables.spaces)),
237
+ left: _propTypes["default"].oneOf(Object.keys(_variables.spaces)),
238
+ right: _propTypes["default"].oneOf(Object.keys(_variables.spaces))
239
+ }), _propTypes["default"].oneOf((0, _toConsumableArray2["default"])(Object.keys(_variables.spaces)))])
240
+ };
205
241
  var _default = DxcProgressBar;
206
242
  exports["default"] = _default;
@@ -0,0 +1,18 @@
1
+ type Space = "xxsmall" | "xsmall" | "small" | "medium" | "large" | "xlarge" | "xxlarge";
2
+ type Margin = {
3
+ top?: Space;
4
+ bottom?: Space;
5
+ left?: Space;
6
+ right?: Space;
7
+ };
8
+
9
+ type Props = {
10
+ label?: string;
11
+ helperText?: string;
12
+ overlay?: boolean;
13
+ value?: number;
14
+ showValue?: boolean,
15
+ margin?: Space | Margin;
16
+ };
17
+
18
+ export default function DxcProgressBar(props: Props): JSX.Element;
File without changes
@@ -0,0 +1,23 @@
1
+ type Size = "small" | "medium" | "large" | "fillParent" | "fitContent";
2
+ type Space = "xxsmall" | "xsmall" | "small" | "medium" | "large" | "xlarge" | "xxlarge";
3
+ type Margin = {
4
+ top?: Space;
5
+ bottom?: Space;
6
+ left?: Space;
7
+ right?: Space;
8
+ };
9
+
10
+ type Props = {
11
+ checked?: boolean;
12
+ value?: any;
13
+ label?: string;
14
+ labelPosition?: "before" | "after";
15
+ name?: string,
16
+ disabled?: boolean;
17
+ onClick?: void;
18
+ required?: boolean;
19
+ margin?: Space | Margin;
20
+ size?: Size;
21
+ };
22
+
23
+ export default function DxcRadio(props: Props): JSX.Element;
@@ -32,7 +32,7 @@ var _Paginator = _interopRequireDefault(require("../paginator/Paginator"));
32
32
  var _useTheme = _interopRequireDefault(require("../useTheme.js"));
33
33
 
34
34
  function _templateObject9() {
35
- var data = (0, _taggedTemplateLiteral2["default"])(["\n font-size: ", ";\n overflow-y: hidden;\n overflow-x: auto;\n margin: ", ";\n margin-top: ", ";\n margin-right: ", ";\n margin-bottom: ", ";\n margin-left: ", ";\n\n &::-webkit-scrollbar {\n height: 6px;\n }\n\n &::-webkit-scrollbar-thumb {\n background-color: ", ";\n border-radius: 6px;\n }\n\n &::-webkit-scrollbar-track {\n background-color: ", ";\n border-radius: 6px;\n }\n"]);
35
+ var data = (0, _taggedTemplateLiteral2["default"])(["\n font-size: ", ";\n margin: ", ";\n margin-top: ", ";\n margin-right: ", ";\n margin-bottom: ", ";\n margin-left: ", ";\n"]);
36
36
 
37
37
  _templateObject9 = function _templateObject9() {
38
38
  return data;
@@ -102,7 +102,7 @@ function _templateObject3() {
102
102
  }
103
103
 
104
104
  function _templateObject2() {
105
- var data = (0, _taggedTemplateLiteral2["default"])(["\n margin-left: ", ";\n margin-right: ", ";\n"]);
105
+ var data = (0, _taggedTemplateLiteral2["default"])([""]);
106
106
 
107
107
  _templateObject2 = function _templateObject2() {
108
108
  return data;
@@ -263,14 +263,7 @@ var DxcResultsetTable = function DxcResultsetTable(_ref) {
263
263
  theme: colorsTheme.table
264
264
  }, _react["default"].createElement(DxcResultsetTableContainer, {
265
265
  margin: margin
266
- }, _react["default"].createElement(TableContainer, null, _react["default"].createElement(_Table["default"], {
267
- margin: {
268
- top: margin,
269
- right: margin,
270
- bottom: "0px",
271
- left: margin
272
- }
273
- }, _react["default"].createElement(HeaderRow, null, _react["default"].createElement("tr", null, columns.map(function (column, index) {
266
+ }, _react["default"].createElement(TableContainer, null, _react["default"].createElement(_Table["default"], null, _react["default"].createElement(HeaderRow, null, _react["default"].createElement("tr", null, columns.map(function (column, index) {
274
267
  return _react["default"].createElement(TableHeader, {
275
268
  key: "tableHeader_".concat(index)
276
269
  }, _react["default"].createElement(HeaderContainer, {
@@ -290,9 +283,7 @@ var DxcResultsetTable = function DxcResultsetTable(_ref) {
290
283
  key: "resultSetTableCellContent_".concat(index)
291
284
  }, cellContent.displayValue);
292
285
  }));
293
- })))), _react["default"].createElement(PaginatorContainer, {
294
- margin: margin
295
- }, _react["default"].createElement(_Paginator["default"], {
286
+ })))), _react["default"].createElement(PaginatorContainer, null, _react["default"].createElement(_Paginator["default"], {
296
287
  totalItems: rows.length,
297
288
  itemsPerPage: itemsPerPage,
298
289
  itemsPerPageOptions: itemsPerPageOptions,
@@ -306,11 +297,7 @@ var DxcResultsetTable = function DxcResultsetTable(_ref) {
306
297
 
307
298
  var TableContainer = _styledComponents["default"].div(_templateObject());
308
299
 
309
- var PaginatorContainer = _styledComponents["default"].div(_templateObject2(), function (props) {
310
- return props.margin && (0, _typeof2["default"])(props.margin) !== "object" ? _variables.spaces[props.margin] : "0px";
311
- }, function (props) {
312
- return props.margin && (0, _typeof2["default"])(props.margin) !== "object" ? _variables.spaces[props.margin] : "0px";
313
- });
300
+ var PaginatorContainer = _styledComponents["default"].div(_templateObject2());
314
301
 
315
302
  var TableRowGroup = _styledComponents["default"].tbody(_templateObject3(), function (props) {
316
303
  return props.theme.rowHeight || "70px";
@@ -344,10 +331,6 @@ var DxcResultsetTableContainer = _styledComponents["default"].div(_templateObjec
344
331
  return props.margin && (0, _typeof2["default"])(props.margin) === "object" && props.margin.bottom ? _variables.spaces[props.margin.bottom] : "";
345
332
  }, function (props) {
346
333
  return props.margin && (0, _typeof2["default"])(props.margin) === "object" && props.margin.left ? _variables.spaces[props.margin.left] : "";
347
- }, function (props) {
348
- return props.theme.scrollBarThumbColor;
349
- }, function (props) {
350
- return props.theme.scrollBarTrackColor;
351
334
  });
352
335
 
353
336
  DxcResultsetTable.propTypes = {
@@ -0,0 +1,19 @@
1
+ type Space = "xxsmall" | "xsmall" | "small" | "medium" | "large" | "xlarge" | "xxlarge";
2
+ type Margin = {
3
+ top?: Space;
4
+ bottom?: Space;
5
+ left?: Space;
6
+ right?: Space;
7
+ };
8
+
9
+ type Props = {
10
+ columns?: any;
11
+ rows?: any;
12
+ itemsPerPage?: number;
13
+ itemsPerPageOptions?: number[];
14
+ itemsPerPageFunction?: void,
15
+ margin?: Space | Margin;
16
+ tabIndex?: number;
17
+ };
18
+
19
+ export default function DxcResultsetTable(props: Props): JSX.Element;