@dxc-technology/halstack-react 0.0.0-d4fec82 → 0.0.0-d53aaf7

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 (297) hide show
  1. package/BackgroundColorContext.d.ts +10 -0
  2. package/BackgroundColorContext.js +1 -4
  3. package/ThemeContext.d.ts +10 -0
  4. package/ThemeContext.js +26 -29
  5. package/accordion/Accordion.d.ts +1 -1
  6. package/accordion/Accordion.js +13 -23
  7. package/accordion/Accordion.stories.tsx +307 -0
  8. package/accordion/Accordion.test.js +72 -0
  9. package/accordion/types.d.ts +8 -8
  10. package/accordion-group/AccordionGroup.js +2 -2
  11. package/accordion-group/AccordionGroup.stories.tsx +225 -0
  12. package/accordion-group/AccordionGroup.test.js +133 -0
  13. package/accordion-group/types.d.ts +4 -8
  14. package/alert/Alert.js +2 -2
  15. package/alert/Alert.stories.tsx +170 -0
  16. package/alert/Alert.test.js +92 -0
  17. package/alert/types.d.ts +1 -1
  18. package/badge/Badge.d.ts +4 -0
  19. package/badge/Badge.js +1 -1
  20. package/badge/types.d.ts +4 -0
  21. package/badge/types.js +5 -0
  22. package/bleed/Bleed.d.ts +3 -0
  23. package/bleed/Bleed.js +84 -0
  24. package/bleed/Bleed.stories.tsx +342 -0
  25. package/bleed/types.d.ts +37 -0
  26. package/bleed/types.js +5 -0
  27. package/box/Box.d.ts +4 -0
  28. package/box/Box.js +6 -32
  29. package/box/{Box.stories.jsx → Box.stories.tsx} +0 -0
  30. package/box/Box.test.js +18 -0
  31. package/box/types.d.ts +43 -0
  32. package/box/types.js +5 -0
  33. package/button/Button.d.ts +1 -1
  34. package/button/Button.js +15 -26
  35. package/button/Button.stories.tsx +223 -242
  36. package/button/Button.test.js +35 -0
  37. package/button/types.d.ts +9 -13
  38. package/card/Card.js +5 -6
  39. package/card/Card.stories.tsx +201 -0
  40. package/card/Card.test.js +50 -0
  41. package/card/ice-cream.jpg +0 -0
  42. package/card/types.d.ts +4 -6
  43. package/checkbox/Checkbox.d.ts +1 -1
  44. package/checkbox/Checkbox.js +9 -15
  45. package/checkbox/Checkbox.stories.tsx +192 -0
  46. package/checkbox/Checkbox.test.js +78 -0
  47. package/checkbox/types.d.ts +6 -2
  48. package/chip/Chip.d.ts +4 -0
  49. package/chip/Chip.js +16 -76
  50. package/chip/Chip.stories.tsx +119 -0
  51. package/chip/Chip.test.js +56 -0
  52. package/chip/types.d.ts +45 -0
  53. package/chip/types.js +5 -0
  54. package/common/variables.js +85 -281
  55. package/date-input/DateInput.js +26 -33
  56. package/date-input/DateInput.stories.tsx +138 -0
  57. package/date-input/DateInput.test.js +492 -0
  58. package/date-input/types.d.ts +4 -0
  59. package/dialog/Dialog.d.ts +4 -0
  60. package/dialog/Dialog.js +8 -26
  61. package/dialog/Dialog.stories.tsx +212 -0
  62. package/dialog/Dialog.test.js +40 -0
  63. package/dialog/types.d.ts +43 -0
  64. package/dialog/types.js +5 -0
  65. package/dropdown/Dropdown.d.ts +1 -1
  66. package/dropdown/Dropdown.js +13 -35
  67. package/dropdown/Dropdown.stories.tsx +249 -0
  68. package/dropdown/Dropdown.test.js +189 -0
  69. package/dropdown/types.d.ts +6 -15
  70. package/file-input/FileInput.d.ts +4 -0
  71. package/file-input/FileInput.js +167 -109
  72. package/file-input/FileInput.stories.tsx +507 -0
  73. package/file-input/FileInput.test.js +457 -0
  74. package/file-input/FileItem.d.ts +14 -0
  75. package/file-input/FileItem.js +12 -21
  76. package/file-input/types.d.ts +112 -0
  77. package/file-input/types.js +5 -0
  78. package/footer/Footer.d.ts +1 -1
  79. package/footer/Footer.js +28 -36
  80. package/footer/Footer.stories.tsx +130 -0
  81. package/footer/Footer.test.js +109 -0
  82. package/footer/Icons.d.ts +2 -0
  83. package/footer/Icons.js +3 -3
  84. package/footer/types.d.ts +22 -18
  85. package/header/Header.d.ts +7 -0
  86. package/header/Header.js +28 -30
  87. package/header/Header.stories.tsx +162 -0
  88. package/header/Header.test.js +63 -0
  89. package/header/Icons.d.ts +2 -0
  90. package/header/Icons.js +2 -27
  91. package/header/types.d.ts +47 -0
  92. package/header/types.js +5 -0
  93. package/heading/Heading.d.ts +4 -0
  94. package/heading/Heading.js +7 -24
  95. package/heading/Heading.stories.tsx +54 -0
  96. package/heading/Heading.test.js +186 -0
  97. package/heading/types.d.ts +33 -0
  98. package/heading/types.js +5 -0
  99. package/inset/Inset.d.ts +3 -0
  100. package/inset/Inset.js +84 -0
  101. package/inset/Inset.stories.tsx +229 -0
  102. package/inset/types.d.ts +37 -0
  103. package/inset/types.js +5 -0
  104. package/layout/ApplicationLayout.d.ts +10 -0
  105. package/layout/ApplicationLayout.js +17 -21
  106. package/layout/ApplicationLayout.stories.tsx +171 -0
  107. package/layout/types.d.ts +57 -0
  108. package/layout/types.js +5 -0
  109. package/link/Link.d.ts +3 -0
  110. package/link/Link.js +10 -40
  111. package/link/Link.stories.tsx +151 -0
  112. package/link/Link.test.js +91 -0
  113. package/link/types.d.ts +70 -0
  114. package/link/types.js +5 -0
  115. package/list/List.d.ts +4 -0
  116. package/list/List.js +47 -0
  117. package/list/List.stories.tsx +95 -0
  118. package/list/types.d.ts +7 -0
  119. package/list/types.js +5 -0
  120. package/main.d.ts +11 -8
  121. package/main.js +62 -38
  122. package/number-input/NumberInput.d.ts +4 -0
  123. package/number-input/NumberInput.js +16 -68
  124. package/number-input/{NumberInput.stories.jsx → NumberInput.stories.tsx} +5 -5
  125. package/number-input/NumberInput.test.js +508 -0
  126. package/number-input/NumberInputContext.d.ts +4 -0
  127. package/number-input/NumberInputContext.js +5 -2
  128. package/number-input/numberInputContextTypes.d.ts +19 -0
  129. package/number-input/numberInputContextTypes.js +5 -0
  130. package/number-input/types.d.ts +121 -0
  131. package/number-input/types.js +5 -0
  132. package/package.json +5 -2
  133. package/paginator/Paginator.js +2 -8
  134. package/paginator/Paginator.stories.tsx +63 -0
  135. package/paginator/Paginator.test.js +266 -0
  136. package/password-input/PasswordInput.d.ts +4 -0
  137. package/password-input/PasswordInput.js +19 -55
  138. package/password-input/{PasswordInput.stories.jsx → PasswordInput.stories.tsx} +4 -4
  139. package/password-input/PasswordInput.test.js +183 -0
  140. package/password-input/types.d.ts +107 -0
  141. package/password-input/types.js +5 -0
  142. package/progress-bar/ProgressBar.js +5 -5
  143. package/progress-bar/ProgressBar.stories.jsx +58 -0
  144. package/progress-bar/ProgressBar.test.js +65 -0
  145. package/quick-nav/QuickNav.d.ts +4 -0
  146. package/quick-nav/QuickNav.js +66 -0
  147. package/quick-nav/QuickNav.stories.tsx +237 -0
  148. package/quick-nav/types.d.ts +21 -0
  149. package/quick-nav/types.js +5 -0
  150. package/radio/Radio.js +2 -2
  151. package/radio/Radio.stories.tsx +192 -0
  152. package/radio/Radio.test.js +71 -0
  153. package/radio/types.d.ts +2 -2
  154. package/radio-group/Radio.d.ts +4 -0
  155. package/radio-group/Radio.js +141 -0
  156. package/radio-group/RadioGroup.d.ts +4 -0
  157. package/radio-group/RadioGroup.js +280 -0
  158. package/radio-group/RadioGroup.stories.tsx +100 -0
  159. package/radio-group/RadioGroup.test.js +695 -0
  160. package/radio-group/types.d.ts +114 -0
  161. package/radio-group/types.js +5 -0
  162. package/resultsetTable/ResultsetTable.d.ts +4 -0
  163. package/resultsetTable/ResultsetTable.js +9 -29
  164. package/resultsetTable/ResultsetTable.stories.tsx +275 -0
  165. package/resultsetTable/ResultsetTable.test.js +306 -0
  166. package/resultsetTable/types.d.ts +67 -0
  167. package/resultsetTable/types.js +5 -0
  168. package/row/Row.d.ts +3 -0
  169. package/row/Row.js +127 -0
  170. package/row/Row.stories.tsx +237 -0
  171. package/row/types.d.ts +28 -0
  172. package/row/types.js +5 -0
  173. package/select/Icons.d.ts +10 -0
  174. package/select/Icons.js +93 -0
  175. package/select/Option.d.ts +4 -0
  176. package/select/Option.js +110 -0
  177. package/select/Select.d.ts +4 -0
  178. package/select/Select.js +116 -249
  179. package/select/Select.stories.tsx +582 -0
  180. package/select/Select.test.js +2057 -0
  181. package/select/types.d.ts +194 -0
  182. package/select/types.js +5 -0
  183. package/sidenav/Sidenav.d.ts +9 -0
  184. package/sidenav/Sidenav.js +6 -15
  185. package/sidenav/Sidenav.stories.tsx +182 -0
  186. package/sidenav/Sidenav.test.js +56 -0
  187. package/sidenav/types.d.ts +50 -0
  188. package/sidenav/types.js +5 -0
  189. package/slider/Slider.d.ts +1 -1
  190. package/slider/Slider.js +45 -33
  191. package/slider/Slider.stories.tsx +177 -0
  192. package/slider/Slider.test.js +150 -0
  193. package/slider/types.d.ts +6 -7
  194. package/spinner/Spinner.d.ts +4 -0
  195. package/spinner/Spinner.js +8 -25
  196. package/spinner/Spinner.stories.jsx +103 -0
  197. package/spinner/Spinner.test.js +64 -0
  198. package/spinner/types.d.ts +32 -0
  199. package/spinner/types.js +5 -0
  200. package/stack/Stack.d.ts +3 -0
  201. package/stack/Stack.js +97 -0
  202. package/stack/Stack.stories.tsx +164 -0
  203. package/stack/types.d.ts +24 -0
  204. package/stack/types.js +5 -0
  205. package/switch/Switch.d.ts +1 -1
  206. package/switch/Switch.js +22 -9
  207. package/switch/Switch.stories.tsx +160 -0
  208. package/switch/Switch.test.js +98 -0
  209. package/switch/types.d.ts +4 -0
  210. package/table/Table.d.ts +4 -0
  211. package/table/Table.js +3 -3
  212. package/table/Table.stories.jsx +277 -0
  213. package/table/Table.test.js +26 -0
  214. package/table/types.d.ts +21 -0
  215. package/table/types.js +5 -0
  216. package/tabs/Tabs.js +11 -9
  217. package/tabs/Tabs.stories.tsx +120 -0
  218. package/tabs/Tabs.test.js +123 -0
  219. package/tabs/types.d.ts +25 -18
  220. package/tag/Tag.d.ts +4 -0
  221. package/tag/Tag.js +34 -56
  222. package/tag/Tag.stories.tsx +142 -0
  223. package/tag/Tag.test.js +60 -0
  224. package/tag/types.d.ts +69 -0
  225. package/tag/types.js +5 -0
  226. package/text/Text.d.ts +7 -0
  227. package/text/Text.js +30 -0
  228. package/text/Text.stories.tsx +19 -0
  229. package/text-input/TextInput.d.ts +4 -0
  230. package/text-input/TextInput.js +62 -89
  231. package/text-input/TextInput.stories.tsx +474 -0
  232. package/text-input/TextInput.test.js +1725 -0
  233. package/text-input/types.d.ts +163 -0
  234. package/text-input/types.js +5 -0
  235. package/textarea/Textarea.d.ts +4 -0
  236. package/textarea/Textarea.js +37 -68
  237. package/textarea/Textarea.stories.jsx +37 -15
  238. package/textarea/Textarea.test.js +437 -0
  239. package/textarea/types.d.ts +134 -0
  240. package/textarea/types.js +5 -0
  241. package/toggle-group/ToggleGroup.d.ts +4 -0
  242. package/toggle-group/ToggleGroup.js +18 -46
  243. package/toggle-group/ToggleGroup.stories.tsx +173 -0
  244. package/toggle-group/ToggleGroup.test.js +156 -0
  245. package/toggle-group/types.d.ts +105 -0
  246. package/toggle-group/types.js +5 -0
  247. package/useTheme.d.ts +2 -0
  248. package/useTheme.js +1 -1
  249. package/wizard/Wizard.d.ts +4 -0
  250. package/wizard/Wizard.js +81 -66
  251. package/wizard/Wizard.stories.tsx +214 -0
  252. package/wizard/Wizard.test.js +141 -0
  253. package/wizard/types.d.ts +64 -0
  254. package/wizard/types.js +5 -0
  255. package/V3Select/V3Select.js +0 -455
  256. package/V3Select/index.d.ts +0 -27
  257. package/V3Textarea/V3Textarea.js +0 -260
  258. package/V3Textarea/index.d.ts +0 -27
  259. package/box/index.d.ts +0 -25
  260. package/chip/index.d.ts +0 -22
  261. package/date/Date.js +0 -373
  262. package/date/index.d.ts +0 -27
  263. package/dialog/index.d.ts +0 -18
  264. package/file-input/index.d.ts +0 -81
  265. package/header/index.d.ts +0 -25
  266. package/heading/index.d.ts +0 -17
  267. package/input-text/Icons.js +0 -22
  268. package/input-text/InputText.js +0 -611
  269. package/input-text/index.d.ts +0 -36
  270. package/link/index.d.ts +0 -23
  271. package/number-input/index.d.ts +0 -113
  272. package/password-input/index.d.ts +0 -94
  273. package/resultsetTable/index.d.ts +0 -19
  274. package/select/index.d.ts +0 -131
  275. package/sidenav/index.d.ts +0 -13
  276. package/spinner/index.d.ts +0 -17
  277. package/table/index.d.ts +0 -13
  278. package/tag/index.d.ts +0 -24
  279. package/text-input/index.d.ts +0 -135
  280. package/textarea/index.d.ts +0 -117
  281. package/toggle/Toggle.js +0 -186
  282. package/toggle/index.d.ts +0 -21
  283. package/toggle-group/index.d.ts +0 -21
  284. package/upload/Upload.js +0 -201
  285. package/upload/buttons-upload/ButtonsUpload.js +0 -111
  286. package/upload/buttons-upload/Icons.js +0 -40
  287. package/upload/dragAndDropArea/DragAndDropArea.js +0 -225
  288. package/upload/dragAndDropArea/Icons.js +0 -39
  289. package/upload/file-upload/FileToUpload.js +0 -115
  290. package/upload/file-upload/Icons.js +0 -66
  291. package/upload/files-upload/FilesToUpload.js +0 -109
  292. package/upload/index.d.ts +0 -15
  293. package/upload/transaction/Icons.js +0 -160
  294. package/upload/transaction/Transaction.js +0 -104
  295. package/upload/transactions/Transactions.js +0 -94
  296. package/wizard/Icons.js +0 -65
  297. package/wizard/index.d.ts +0 -18
@@ -0,0 +1,64 @@
1
+ /// <reference types="react" />
2
+ declare type Space = "xxsmall" | "xsmall" | "small" | "medium" | "large" | "xlarge" | "xxlarge";
3
+ declare type Margin = {
4
+ top?: Space;
5
+ bottom?: Space;
6
+ left?: Space;
7
+ right?: Space;
8
+ };
9
+ declare type SVG = React.SVGProps<SVGSVGElement>;
10
+ declare type Step = {
11
+ /**
12
+ * Step label.
13
+ */
14
+ label: string;
15
+ /**
16
+ * Description that will be placed next to the step.
17
+ */
18
+ description?: string;
19
+ /**
20
+ * Element or path used as the icon displayed in the step.
21
+ */
22
+ icon?: string | SVG;
23
+ /**
24
+ * Whether the step is disabled or not.
25
+ */
26
+ disabled?: boolean;
27
+ /**
28
+ * Whether the step is valid or not.
29
+ */
30
+ valid?: boolean;
31
+ };
32
+ declare type Props = {
33
+ /**
34
+ * The wizard can be showed in horizontal or vertical.
35
+ */
36
+ mode?: "horizontal" | "vertical";
37
+ /**
38
+ * Initially selected step, only when it is uncontrolled.
39
+ */
40
+ defaultCurrentStep?: number;
41
+ /**
42
+ * Defines which step is marked as the current. The numeration starts at 0.
43
+ */
44
+ currentStep?: number;
45
+ /**
46
+ * This function will be called when the user clicks a step. The step
47
+ * number will be passed as a parameter.
48
+ */
49
+ onStepClick?: (newCurrentStep: number) => void;
50
+ /**
51
+ * An array of objects representing the steps.
52
+ */
53
+ steps: Step[];
54
+ /**
55
+ * Size of the margin to be applied to the component ('xxsmall' | 'xsmall' | 'small' | 'medium' | 'large' | 'xlarge' | 'xxlarge').
56
+ * You can pass an object with 'top', 'bottom', 'left' and 'right' properties in order to specify different margin sizes.
57
+ */
58
+ margin?: Space | Margin;
59
+ /**
60
+ * Value of the tabindex attribute that is given to all the steps.
61
+ */
62
+ tabIndex?: number;
63
+ };
64
+ export default Props;
@@ -0,0 +1,5 @@
1
+ "use strict";
2
+
3
+ Object.defineProperty(exports, "__esModule", {
4
+ value: true
5
+ });
@@ -1,455 +0,0 @@
1
- "use strict";
2
-
3
- var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault");
4
-
5
- var _typeof3 = require("@babel/runtime/helpers/typeof");
6
-
7
- Object.defineProperty(exports, "__esModule", {
8
- value: true
9
- });
10
- exports["default"] = void 0;
11
-
12
- var _toConsumableArray2 = _interopRequireDefault(require("@babel/runtime/helpers/toConsumableArray"));
13
-
14
- var _taggedTemplateLiteral2 = _interopRequireDefault(require("@babel/runtime/helpers/taggedTemplateLiteral"));
15
-
16
- var _typeof2 = _interopRequireDefault(require("@babel/runtime/helpers/typeof"));
17
-
18
- var _slicedToArray2 = _interopRequireDefault(require("@babel/runtime/helpers/slicedToArray"));
19
-
20
- var _react = _interopRequireWildcard(require("react"));
21
-
22
- var _Select = _interopRequireDefault(require("@material-ui/core/Select"));
23
-
24
- var _InputLabel = _interopRequireDefault(require("@material-ui/core/InputLabel"));
25
-
26
- var _FormControl = _interopRequireDefault(require("@material-ui/core/FormControl"));
27
-
28
- var _FormHelperText = _interopRequireDefault(require("@material-ui/core/FormHelperText"));
29
-
30
- var _styledComponents = _interopRequireWildcard(require("styled-components"));
31
-
32
- var _MenuItem = _interopRequireDefault(require("@material-ui/core/MenuItem"));
33
-
34
- var _propTypes = _interopRequireDefault(require("prop-types"));
35
-
36
- var _Checkbox = _interopRequireDefault(require("../checkbox/Checkbox"));
37
-
38
- var _variables = require("../common/variables.js");
39
-
40
- var _utils = require("../common/utils.js");
41
-
42
- var _useTheme = _interopRequireDefault(require("../useTheme.js"));
43
-
44
- var _RequiredComponent = _interopRequireDefault(require("../common/RequiredComponent"));
45
-
46
- var _BackgroundColorContext = _interopRequireWildcard(require("../BackgroundColorContext.js"));
47
-
48
- var _templateObject, _templateObject2, _templateObject3, _templateObject4, _templateObject5, _templateObject6, _templateObject7, _templateObject8, _templateObject9, _templateObject10;
49
-
50
- function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "function") return null; var cacheBabelInterop = new WeakMap(); var cacheNodeInterop = new WeakMap(); return (_getRequireWildcardCache = function _getRequireWildcardCache(nodeInterop) { return nodeInterop ? cacheNodeInterop : cacheBabelInterop; })(nodeInterop); }
51
-
52
- function _interopRequireWildcard(obj, nodeInterop) { if (!nodeInterop && obj && obj.__esModule) { return obj; } if (obj === null || _typeof3(obj) !== "object" && typeof obj !== "function") { return { "default": obj }; } var cache = _getRequireWildcardCache(nodeInterop); if (cache && cache.has(obj)) { return cache.get(obj); } var newObj = {}; var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var key in obj) { if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) { var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null; if (desc && (desc.get || desc.set)) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } newObj["default"] = obj; if (cache) { cache.set(obj, newObj); } return newObj; }
53
-
54
- var V3DxcSelect = function V3DxcSelect(_ref) {
55
- var value = _ref.value,
56
- name = _ref.name,
57
- onChange = _ref.onChange,
58
- label = _ref.label,
59
- assistiveText = _ref.assistiveText,
60
- _ref$required = _ref.required,
61
- required = _ref$required === void 0 ? false : _ref$required,
62
- _ref$disabled = _ref.disabled,
63
- disabled = _ref$disabled === void 0 ? false : _ref$disabled,
64
- _ref$invalid = _ref.invalid,
65
- invalid = _ref$invalid === void 0 ? false : _ref$invalid,
66
- _ref$options = _ref.options,
67
- options = _ref$options === void 0 ? [] : _ref$options,
68
- _ref$iconPosition = _ref.iconPosition,
69
- iconPosition = _ref$iconPosition === void 0 ? "before" : _ref$iconPosition,
70
- _ref$multiple = _ref.multiple,
71
- multiple = _ref$multiple === void 0 ? false : _ref$multiple,
72
- margin = _ref.margin,
73
- _ref$size = _ref.size,
74
- size = _ref$size === void 0 ? "medium" : _ref$size,
75
- _ref$tabIndex = _ref.tabIndex,
76
- tabIndex = _ref$tabIndex === void 0 ? 0 : _ref$tabIndex;
77
- var colorsTheme = (0, _useTheme["default"])();
78
- var backgroundType = (0, _react.useContext)(_BackgroundColorContext["default"]);
79
-
80
- var _useState = (0, _react.useState)(multiple && [] || ""),
81
- _useState2 = (0, _slicedToArray2["default"])(_useState, 2),
82
- selectedValue = _useState2[0],
83
- setSelectedValue = _useState2[1];
84
-
85
- var handleSelectChange = function handleSelectChange(selectedOption) {
86
- if (multiple) {
87
- setSelectedValue(selectedOption.target.value);
88
-
89
- if (typeof onChange === "function") {
90
- onChange(selectedOption.target.value);
91
- }
92
- } else {
93
- setSelectedValue(selectedOption.target.value);
94
-
95
- if (typeof onChange === "function") {
96
- onChange(selectedOption.target.value);
97
- }
98
- }
99
- };
100
-
101
- var getLabelForSingleSelect = function getLabelForSingleSelect(selected) {
102
- var selectedItem = options.filter(function (option) {
103
- return option.value === selected;
104
- })[0];
105
- return /*#__PURE__*/_react["default"].createElement(SelectedOptionContainer, {
106
- iconPosition: iconPosition,
107
- multiple: multiple,
108
- label: selectedItem && selectedItem.label,
109
- key: selectedItem && selectedItem.label
110
- }, selectedItem && selectedItem.icon ? /*#__PURE__*/_react["default"].createElement(SelectedOptionIconContainer, {
111
- backgroundType: backgroundType,
112
- disabled: disabled,
113
- label: selectedItem.label,
114
- iconPosition: iconPosition
115
- }, (0, _typeof2["default"])(selectedItem.icon) === "object" ? selectedItem.icon : /*#__PURE__*/_react["default"].createElement(selectedItem.icon)) : selectedItem && selectedItem.iconSrc && /*#__PURE__*/_react["default"].createElement(SelectedOptionIcon, {
116
- src: selectedItem && selectedItem.iconSrc,
117
- label: selectedItem.label,
118
- iconPosition: iconPosition
119
- }), selectedItem && selectedItem.label && /*#__PURE__*/_react["default"].createElement(SelectedOptionLabelContainer, {
120
- iconSrc: selectedItem && selectedItem.iconSrc && selectedItem.icon,
121
- iconPosition: iconPosition,
122
- disabled: disabled
123
- }, selectedItem && selectedItem.label));
124
- };
125
-
126
- var getSelectedValuesWithLabel = function getSelectedValuesWithLabel(optionsList, selected) {
127
- return /*#__PURE__*/_react["default"].createElement(MultipleLabelSelected, null, optionsList.filter(function (x) {
128
- return selected.includes(x.value);
129
- }).map(function (optionToRender) {
130
- return optionToRender.label;
131
- }).join(", "));
132
- };
133
-
134
- var getSelectedValuesWithIcons = function getSelectedValuesWithIcons(optionsList, selected) {
135
- return optionsList.filter(function (x) {
136
- return selected.includes(x.value);
137
- }).map(function (optionToRender) {
138
- return getLabelForSingleSelect(optionToRender.value);
139
- });
140
- };
141
-
142
- var labelForMultipleSelect = function labelForMultipleSelect(selected) {
143
- return options.findIndex(function (option) {
144
- return !option.label;
145
- }) !== -1 ? getSelectedValuesWithIcons(options, selected) : getSelectedValuesWithLabel(options, selected);
146
- };
147
-
148
- var getRenderValue = function getRenderValue(selected) {
149
- return multiple && labelForMultipleSelect(selected) || getLabelForSingleSelect(selected);
150
- };
151
-
152
- var isChecked = function isChecked(checkedValue, value, option) {
153
- if (value !== undefined) {
154
- var result = false;
155
- value.map(function (val) {
156
- if (val === option.value) {
157
- result = true;
158
- }
159
- });
160
- return result;
161
- } else if (checkedValue) {
162
- return checkedValue.findIndex(function (element) {
163
- return element === option.value;
164
- }) !== -1 || false;
165
- }
166
- };
167
-
168
- var ThemedOption = function ThemedOption(_ref2) {
169
- var option = _ref2.option;
170
- var backgroundType = (0, _react.useContext)(_BackgroundColorContext["default"]);
171
- return /*#__PURE__*/_react["default"].createElement(_react["default"].Fragment, null, multiple && /*#__PURE__*/_react["default"].createElement(_Checkbox["default"], {
172
- size: "fitContent",
173
- checked: isChecked(selectedValue, value, option)
174
- }), /*#__PURE__*/_react["default"].createElement(OptionListContainer, {
175
- iconPosition: iconPosition,
176
- multiple: multiple
177
- }, option.icon ? /*#__PURE__*/_react["default"].createElement(OptionListIconContainer, {
178
- backgroundType: backgroundType,
179
- disabled: disabled,
180
- label: option.label,
181
- iconPosition: iconPosition
182
- }, (0, _typeof2["default"])(option.icon) === "object" ? option.icon : /*#__PURE__*/_react["default"].createElement(option.icon)) : option.iconSrc && /*#__PURE__*/_react["default"].createElement(OptionListIcon, {
183
- src: option.iconSrc,
184
- label: option.label,
185
- iconPosition: iconPosition
186
- }), " ", /*#__PURE__*/_react["default"].createElement(OptionListLabelContainer, {
187
- backgroundType: backgroundType
188
- }, option.label)));
189
- };
190
-
191
- return /*#__PURE__*/_react["default"].createElement(_styledComponents.ThemeProvider, {
192
- theme: colorsTheme.V3Select
193
- }, /*#__PURE__*/_react["default"].createElement(SelectContainer, {
194
- margin: margin,
195
- size: size,
196
- invalid: invalid,
197
- disabled: disabled,
198
- backgroundType: backgroundType
199
- }, /*#__PURE__*/_react["default"].createElement(_FormControl["default"], null, /*#__PURE__*/_react["default"].createElement(_InputLabel["default"], {
200
- disabled: disabled
201
- }, required && /*#__PURE__*/_react["default"].createElement(_RequiredComponent["default"], null), label), /*#__PURE__*/_react["default"].createElement(_Select["default"], {
202
- name: name,
203
- multiple: multiple,
204
- renderValue: getRenderValue,
205
- onChange: handleSelectChange,
206
- value: value !== undefined ? value : selectedValue,
207
- disabled: disabled,
208
- MenuProps: {
209
- getContentAnchorEl: null,
210
- anchorOrigin: {
211
- vertical: "bottom",
212
- horizontal: "left"
213
- },
214
- disablePortal: true
215
- },
216
- inputProps: {
217
- tabIndex: disabled ? -1 : tabIndex
218
- }
219
- }, options.map(function (option) {
220
- return /*#__PURE__*/_react["default"].createElement(_MenuItem["default"], {
221
- id: option.value,
222
- value: option.value,
223
- disableRipple: true,
224
- key: option.value
225
- }, /*#__PURE__*/_react["default"].createElement(_BackgroundColorContext.BackgroundColorProvider, {
226
- color: colorsTheme.V3Select.optionBackgroundColor
227
- }, /*#__PURE__*/_react["default"].createElement(ThemedOption, {
228
- option: option
229
- })));
230
- })), assistiveText && /*#__PURE__*/_react["default"].createElement(_FormHelperText["default"], {
231
- disabled: disabled
232
- }, assistiveText))));
233
- };
234
-
235
- var sizes = {
236
- small: "60px",
237
- medium: "240px",
238
- large: "480px",
239
- fillParent: "100%"
240
- };
241
-
242
- var calculateWidth = function calculateWidth(margin, size) {
243
- return size === "fillParent" ? "calc(".concat(sizes[size], " - ").concat((0, _utils.getMargin)(margin, "left"), " - ").concat((0, _utils.getMargin)(margin, "right"), ")") : sizes[size];
244
- };
245
-
246
- var MultipleLabelSelected = _styledComponents["default"].div(_templateObject || (_templateObject = (0, _taggedTemplateLiteral2["default"])(["\n width: calc(100% - 24px);\n overflow: hidden;\n text-overflow: ellipsis;\n"])));
247
-
248
- var OptionListContainer = _styledComponents["default"].div(_templateObject2 || (_templateObject2 = (0, _taggedTemplateLiteral2["default"])(["\n font-family: ", ";\n display: flex;\n align-items: center;\n flex-direction: ", ";\n overflow: hidden;\n text-overflow: ellipsis;\n ", "\n"])), function (props) {
249
- return props.theme.fontFamily;
250
- }, function (props) {
251
- return props.iconPosition === "before" && "row" || "row-reverse";
252
- }, function (props) {
253
- return props.multiple && "margin-left: ".concat(props.theme.optionCheckboxSpacing, ";");
254
- });
255
-
256
- var OptionListIconContainer = _styledComponents["default"].div(_templateObject3 || (_templateObject3 = (0, _taggedTemplateLiteral2["default"])(["\n color: ", ";\n width: ", ";\n height: ", ";\n margin-left: ", ";\n margin-right: ", ";\n overflow: hidden;\n\n img,\n svg {\n height: 100%;\n width: 100%;\n }\n"])), function (props) {
257
- return props.disabled ? props.backgroundType === "dark" ? props.theme.disabledColorOnDark : props.theme.disabledColor : props.backgroundType === "dark" ? props.theme.optionIconColorOnDark : props.theme.optionIconColor;
258
- }, function (props) {
259
- return props.theme.optionIconSize;
260
- }, function (props) {
261
- return props.theme.optionIconSize;
262
- }, function (props) {
263
- return props.iconPosition === "after" && props.label && props.theme.optionIconSpacing || "0px";
264
- }, function (props) {
265
- return props.iconPosition === "before" && props.label && props.theme.optionIconSpacing || "0px";
266
- });
267
-
268
- var OptionListIcon = _styledComponents["default"].img(_templateObject4 || (_templateObject4 = (0, _taggedTemplateLiteral2["default"])(["\n width: ", ";\n height: ", ";\n margin-left: ", ";\n margin-right: ", ";\n"])), function (props) {
269
- return props.theme.optionIconSize;
270
- }, function (props) {
271
- return props.theme.optionIconSize;
272
- }, function (props) {
273
- return props.iconPosition === "after" && props.label !== "" && props.theme.optionIconSpacing || "0px";
274
- }, function (props) {
275
- return props.iconPosition === "before" && props.label !== "" && props.theme.optionIconSpacing || "0px";
276
- });
277
-
278
- var OptionListLabelContainer = _styledComponents["default"].span(_templateObject5 || (_templateObject5 = (0, _taggedTemplateLiteral2["default"])(["\n overflow: hidden;\n text-overflow: ellipsis;\n font-size: ", ";\n font-style: ", ";\n font-weight: ", ";\n color: ", ";\n"])), function (props) {
279
- return props.theme.optionFontSize;
280
- }, function (props) {
281
- return props.theme.optionFontStyle;
282
- }, function (props) {
283
- return props.theme.optionFontWeight;
284
- }, function (props) {
285
- return props.backgroundType === "dark" ? props.theme.optionFontColorOnDark : props.theme.optionFontColor;
286
- });
287
-
288
- var SelectedOptionContainer = _styledComponents["default"].div(_templateObject6 || (_templateObject6 = (0, _taggedTemplateLiteral2["default"])(["\n display: flex;\n flex-direction: ", ";\n justify-content: ", ";\n margin-right: ", ";\n overflow: hidden;\n text-overflow: ellipsis;\n width: ", ";\n\n &::before {\n margin: 0 4px;\n ", ";\n }\n &::after {\n margin: 0 4px;\n ", ";\n }\n"])), function (props) {
289
- return props.iconPosition === "before" && "row" || "row-reverse";
290
- }, function (props) {
291
- return props.iconPosition === "before" && "flex-start" || "flex-end";
292
- }, function (props) {
293
- return props.multiple && props.label && "15px" || "0px";
294
- }, function (props) {
295
- return !props.multiple && "calc(100% - 24px)" || "auto";
296
- }, function (props) {
297
- return props.iconPosition === "after" && (props.label !== "" || props.label === undefined) && "content:','";
298
- }, function (props) {
299
- return props.iconPosition === "before" && (props.label !== "" || props.label === undefined) && "content:','";
300
- });
301
-
302
- var SelectedOptionLabelContainer = _styledComponents["default"].span(_templateObject7 || (_templateObject7 = (0, _taggedTemplateLiteral2["default"])(["\n font-family: ", ";\n overflow: hidden;\n text-overflow: ellipsis;\n"])), function (props) {
303
- return props.theme.fontFamily;
304
- });
305
-
306
- var SelectedOptionIcon = _styledComponents["default"].img(_templateObject8 || (_templateObject8 = (0, _taggedTemplateLiteral2["default"])(["\n width: ", ";\n height: ", ";\n margin-left: ", ";\n margin-right: ", ";\n"])), function (props) {
307
- return props.theme.valueIconSize;
308
- }, function (props) {
309
- return props.theme.valueIconSize;
310
- }, function (props) {
311
- return props.iconPosition === "after" && props.label !== "" && props.theme.valueIconSpacing || "0px";
312
- }, function (props) {
313
- return props.iconPosition === "before" && props.label !== "" && props.theme.valueIconSpacing || "0px";
314
- });
315
-
316
- var SelectedOptionIconContainer = _styledComponents["default"].div(_templateObject9 || (_templateObject9 = (0, _taggedTemplateLiteral2["default"])(["\n color: ", ";\n width: ", ";\n height: ", ";\n margin-left: ", ";\n margin-right: ", ";\n overflow: hidden;\n\n img,\n svg {\n height: 100%;\n width: 100%;\n }\n"])), function (props) {
317
- return props.disabled ? props.backgroundType === "dark" ? props.theme.disabledColorOnDark : props.theme.disabledColor : props.backgroundType === "dark" ? props.theme.valueIconColorOnDark : props.theme.valueIconColor;
318
- }, function (props) {
319
- return props.theme.valueIconSize;
320
- }, function (props) {
321
- return props.theme.valueIconSize;
322
- }, function (props) {
323
- return props.iconPosition === "after" && props.label !== "" && props.theme.valueIconSpacing || "0px";
324
- }, function (props) {
325
- return props.iconPosition === "before" && props.label !== "" && props.theme.valueIconSpacing || "0px";
326
- });
327
-
328
- var SelectContainer = _styledComponents["default"].div(_templateObject10 || (_templateObject10 = (0, _taggedTemplateLiteral2["default"])(["\n width: ", ";\n margin: ", ";\n margin-top: ", ";\n margin-right: ", ";\n margin-bottom: ", ";\n margin-left: ", ";\n display: inline-block;\n\n .MuiFormControl-root {\n width: 100%;\n }\n\n .MuiFormHelperText-root {\n font-family: ", ";\n font-size: ", ";\n font-style: ", ";\n font-weight: ", ";\n color: ", ";\n margin-top: 6px;\n\n &.Mui-disabled {\n color: ", ";\n cursor: not-allowed;\n }\n }\n\n .MuiFormLabel-root {\n font-family: ", ";\n font-size: ", ";\n font-style: ", ";\n font-weight: ", ";\n color: ", ";\n margin-top: -3px;\n text-overflow: ellipsis;\n overflow: hidden;\n white-space: nowrap;\n height: 22px;\n display: flex;\n align-items: center;\n\n &.Mui-disabled {\n color: ", ";\n }\n &.Mui-focused {\n font-size: ", ";\n font-style: ", ";\n font-weight: ", ";\n color: ", ";\n }\n }\n\n .MuiSelect-select.MuiSelect-select {\n padding-right: unset;\n }\n\n .MuiSelect-select {\n width: 100%;\n height: 20px;\n display: flex;\n padding-right: 10px;\n align-items: center;\n\n :focus {\n background-color: transparent;\n outline: ", "\n auto 2px;\n }\n & > *:last-child::after {\n content: unset;\n }\n & > *:last-child::before {\n content: unset;\n }\n &.Mui-disabled {\n color: ", ";\n cursor: not-allowed;\n &:focus {\n outline: none;\n }\n }\n }\n .MuiInputBase-input {\n font-size: ", ";\n font-style: ", ";\n font-weight: ", ";\n color: ", ";\n }\n .MuiInput-underline {\n &.Mui-focused {\n border-bottom-width: ", ";\n border-bottom-color: ", ";\n }\n &.Mui-disabled:before {\n border-bottom-style: solid;\n }\n }\n .MuiInput-underline:hover:not(.Mui-disabled):before {\n border-bottom: ", " solid;\n border-bottom-color: ", ";\n }\n .MuiInput-underline:after {\n border-bottom: ", " solid;\n border-bottom-color: ", ";\n }\n .MuiInput-underline:before {\n border-bottom: ", " solid;\n border-bottom-color: ", ";\n }\n .MuiSelect-icon {\n color: ", " !important;\n }\n & label {\n text-overflow: ellipsis;\n overflow: hidden;\n width: calc(100% - 24px);\n }\n\n .MuiMenu-paper {\n background-color: ", ";\n box-shadow: 0px 2px 10px 0px rgba(0, 0, 0, 0.3);\n min-width: auto;\n width: auto;\n max-height: 250px;\n border-color: ", ";\n border-width: ", ";\n border-style: ", ";\n\n &::-webkit-scrollbar {\n width: 3px;\n margin: 5px;\n }\n &::-webkit-scrollbar-track {\n border-radius: 3px;\n background-color: ", ";\n }\n &::-webkit-scrollbar-thumb {\n border-radius: 3px;\n background-color: ", ";\n }\n }\n .MuiList-root {\n width: auto !important;\n padding-right: 0 !important;\n }\n .MuiList-padding {\n padding-bottom: 0px;\n padding-top: 0px;\n }\n .MuiMenuItem-root {\n padding-bottom: ", ";\n padding-top: ", ";\n\n &:hover {\n background-color: ", ";\n }\n &:active {\n background-color: ", ";\n }\n &:focus {\n outline: ", "\n auto 2px;\n outline-offset: -1px;\n }\n &.MuiListItem-root.Mui-selected {\n background-color: ", ";\n }\n & span.MuiButtonBase-root {\n // multiple checkbox\n padding: 0px;\n margin: 5px 0px;\n }\n }\n"])), function (props) {
329
- return calculateWidth(props.margin, props.size);
330
- }, function (props) {
331
- return props.margin && (0, _typeof2["default"])(props.margin) !== "object" ? _variables.spaces[props.margin] : "0px";
332
- }, function (props) {
333
- return props.margin && (0, _typeof2["default"])(props.margin) === "object" && props.margin.top ? _variables.spaces[props.margin.top] : "";
334
- }, function (props) {
335
- return props.margin && (0, _typeof2["default"])(props.margin) === "object" && props.margin.right ? _variables.spaces[props.margin.right] : "";
336
- }, function (props) {
337
- return props.margin && (0, _typeof2["default"])(props.margin) === "object" && props.margin.bottom ? _variables.spaces[props.margin.bottom] : "";
338
- }, function (props) {
339
- return props.margin && (0, _typeof2["default"])(props.margin) === "object" && props.margin.left ? _variables.spaces[props.margin.left] : "";
340
- }, function (props) {
341
- return props.theme.fontFamily;
342
- }, function (props) {
343
- return props.theme.assistiveTextFontSize;
344
- }, function (props) {
345
- return props.theme.assistiveTextFontStyle;
346
- }, function (props) {
347
- return props.theme.assistiveTextFontWeight;
348
- }, function (props) {
349
- return props.backgroundType === "dark" ? props.invalid === true ? props.theme.errorColorOnDark : props.theme.assistiveTextFontColorOnDark : props.invalid === true ? props.theme.errorColor : props.theme.assistiveTextFontColor;
350
- }, function (props) {
351
- return props.backgroundType === "dark" ? props.theme.disabledColorOnDark : props.theme.disabledColor;
352
- }, function (props) {
353
- return props.theme.fontFamily;
354
- }, function (props) {
355
- return props.theme.labelFontSize;
356
- }, function (props) {
357
- return props.theme.labelFontStyle;
358
- }, function (props) {
359
- return props.theme.labelFontWeight;
360
- }, function (props) {
361
- return props.backgroundType === "dark" ? props.invalid === true ? props.theme.errorColorOnDark : props.theme.labelFontColorOnDark : props.invalid === true ? props.theme.errorColor : props.theme.labelFontColor;
362
- }, function (props) {
363
- return props.backgroundType === "dark" ? props.theme.disabledColorOnDark : props.theme.disabledColor;
364
- }, function (props) {
365
- return props.theme.labelFontSize;
366
- }, function (props) {
367
- return props.theme.labelFontStyle;
368
- }, function (props) {
369
- return props.theme.labelFontWeight;
370
- }, function (props) {
371
- return props.backgroundType === "dark" ? props.invalid === true ? props.theme.errorColorOnDark : props.theme.labelFontColorOnDark : props.invalid === true ? props.theme.errorColor : props.theme.labelFontColor;
372
- }, function (props) {
373
- return props.backgroundType === "dark" ? props.theme.focusColorOnDark : props.theme.focusColor;
374
- }, function (props) {
375
- return props.backgroundType === "dark" ? props.theme.disabledColorOnDark : props.theme.disabledColor;
376
- }, function (props) {
377
- return props.theme.valueFontSize;
378
- }, function (props) {
379
- return props.theme.valueFontStyle;
380
- }, function (props) {
381
- return props.theme.valueFontWeight;
382
- }, function (props) {
383
- return props.backgroundType === "dark" ? props.theme.valueFontColorOnDark : props.theme.valueFontColor;
384
- }, function (props) {
385
- return props.theme.underlineThickness;
386
- }, function (props) {
387
- return props.backgroundType === "dark" ? props.invalid === true && props.theme.errorColorOnDark || props.disabled && props.theme.disabledColorOnDark || props.theme.underlineFocusColorOnDark : props.invalid === true && props.theme.errorColor || props.disabled && props.theme.disabledColor || props.theme.underlineFocusColor;
388
- }, function (props) {
389
- return props.theme.underlineThickness;
390
- }, function (props) {
391
- return props.backgroundType === "dark" ? props.invalid === true && props.theme.errorColorOnDark || props.disabled && props.theme.disabledColorOnDark || props.theme.underlineColorOnDark : props.invalid === true && props.theme.errorColor || props.disabled && props.theme.disabledColor || props.theme.underlineColor;
392
- }, function (props) {
393
- return props.theme.underlineThickness;
394
- }, function (props) {
395
- return props.backgroundType === "dark" ? props.invalid === true ? props.theme.errorColorOnDark : props.theme.underlineFocusColorOnDark : props.invalid === true ? props.theme.errorColor : props.theme.underlineFocusColor;
396
- }, function (props) {
397
- return props.theme.underlineThickness;
398
- }, function (props) {
399
- return props.backgroundType === "dark" ? props.invalid === true && props.theme.errorColorOnDark || props.disabled && props.theme.disabledColorOnDark || props.theme.underlineColorOnDark : props.invalid === true && props.theme.errorColor || props.disabled && props.theme.disabledColor || props.theme.underlineColor;
400
- }, function (props) {
401
- return props.backgroundType === "dark" ? props.disabled && props.theme.disabledColorOnDark || props.theme.arrowColorOnDark : props.disabled && props.theme.disabledColor || props.theme.arrowColor;
402
- }, function (props) {
403
- return props.theme.optionBackgroundColor;
404
- }, function (props) {
405
- return props.theme.optionBorderColor;
406
- }, function (props) {
407
- return props.theme.optionBorderThickness;
408
- }, function (props) {
409
- return props.theme.optionBorderStyle;
410
- }, function (props) {
411
- return props.theme.scrollBarTrackColor;
412
- }, function (props) {
413
- return props.theme.scrollBarThumbColor;
414
- }, function (props) {
415
- return props.theme.optionPaddingBottom;
416
- }, function (props) {
417
- return props.theme.optionPaddingTop;
418
- }, function (props) {
419
- return props.backgroundType === "dark" ? props.theme.hoverOptionBackgroundColorOnDark : props.theme.hoverOptionBackgroundColor;
420
- }, function (props) {
421
- return props.backgroundType === "dark" ? props.theme.activeOptionBackgroundColorOnDark : props.theme.activeOptionBackgroundColor;
422
- }, function (props) {
423
- return props.backgroundType === "dark" ? props.theme.focusColorOnDark : props.theme.focusColor;
424
- }, function (props) {
425
- return props.backgroundType === "dark" ? props.theme.selectedOptionBackgroundColorOnDark : props.theme.selectedOptionBackgroundColor;
426
- });
427
-
428
- V3DxcSelect.propTypes = {
429
- size: _propTypes["default"].oneOf((0, _toConsumableArray2["default"])(Object.keys(sizes))),
430
- label: _propTypes["default"].string,
431
- assistiveText: _propTypes["default"].string,
432
- name: _propTypes["default"].string,
433
- value: _propTypes["default"].oneOfType([_propTypes["default"].string, _propTypes["default"].number, _propTypes["default"].arrayOf(_propTypes["default"].oneOfType([_propTypes["default"].string, _propTypes["default"].number]))]),
434
- disabled: _propTypes["default"].bool,
435
- required: _propTypes["default"].bool,
436
- invalid: _propTypes["default"].bool,
437
- iconPosition: _propTypes["default"].oneOf(["after", "before"]),
438
- onChange: _propTypes["default"].func,
439
- options: _propTypes["default"].arrayOf(_propTypes["default"].shape({
440
- value: _propTypes["default"].any.isRequired,
441
- label: _propTypes["default"].string,
442
- icon: _propTypes["default"].oneOfType([_propTypes["default"].element, _propTypes["default"].func]),
443
- iconSrc: _propTypes["default"].string
444
- })),
445
- multiple: _propTypes["default"].bool,
446
- margin: _propTypes["default"].oneOfType([_propTypes["default"].shape({
447
- top: _propTypes["default"].oneOf(Object.keys(_variables.spaces)),
448
- bottom: _propTypes["default"].oneOf(Object.keys(_variables.spaces)),
449
- left: _propTypes["default"].oneOf(Object.keys(_variables.spaces)),
450
- right: _propTypes["default"].oneOf(Object.keys(_variables.spaces))
451
- }), _propTypes["default"].oneOf((0, _toConsumableArray2["default"])(Object.keys(_variables.spaces)))]),
452
- tabIndex: _propTypes["default"].number
453
- };
454
- var _default = V3DxcSelect;
455
- exports["default"] = _default;
@@ -1,27 +0,0 @@
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
- value?: any;
12
- name?: string;
13
- onChange?: void;
14
- label?: string,
15
- assistiveText?: string;
16
- required?: boolean;
17
- disabled?: boolean;
18
- invalid?: boolean;
19
- options?: any;
20
- iconPosition?: "before" | "after";
21
- multiple?: boolean;
22
- margin?: Space | Margin;
23
- size?: Size;
24
- tabIndex?: number;
25
- };
26
-
27
- export default function V3DxcSelect(props: Props): JSX.Element;