@dxc-technology/halstack-react 0.0.0-d30020b → 0.0.0-d3ac293

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 (290) hide show
  1. package/BackgroundColorContext.d.ts +2 -2
  2. package/BackgroundColorContext.js +1 -1
  3. package/HalstackContext.d.ts +1336 -0
  4. package/HalstackContext.js +335 -0
  5. package/accordion/Accordion.d.ts +1 -1
  6. package/accordion/Accordion.js +118 -126
  7. package/accordion/Accordion.stories.tsx +115 -27
  8. package/accordion/Accordion.test.js +71 -0
  9. package/accordion/types.d.ts +9 -4
  10. package/accordion-group/AccordionGroup.d.ts +1 -1
  11. package/accordion-group/AccordionGroup.js +17 -38
  12. package/accordion-group/AccordionGroup.stories.tsx +28 -2
  13. package/accordion-group/AccordionGroup.test.js +126 -0
  14. package/accordion-group/types.d.ts +14 -3
  15. package/alert/Alert.js +7 -4
  16. package/alert/Alert.stories.tsx +28 -0
  17. package/alert/Alert.test.js +92 -0
  18. package/badge/Badge.d.ts +4 -0
  19. package/badge/Badge.js +5 -3
  20. package/badge/types.d.ts +5 -0
  21. package/bleed/Bleed.js +1 -34
  22. package/bleed/Bleed.stories.tsx +94 -95
  23. package/bleed/types.d.ts +25 -1
  24. package/box/Box.js +25 -37
  25. package/box/Box.stories.tsx +15 -0
  26. package/box/Box.test.js +18 -0
  27. package/box/types.d.ts +1 -0
  28. package/bulleted-list/BulletedList.d.ts +7 -0
  29. package/bulleted-list/BulletedList.js +123 -0
  30. package/bulleted-list/BulletedList.stories.tsx +200 -0
  31. package/bulleted-list/types.d.ts +11 -0
  32. package/button/Button.js +52 -69
  33. package/button/Button.stories.tsx +159 -8
  34. package/button/Button.test.js +35 -0
  35. package/button/types.d.ts +7 -7
  36. package/card/Card.js +25 -28
  37. package/card/Card.test.js +50 -0
  38. package/card/types.d.ts +1 -0
  39. package/checkbox/Checkbox.d.ts +2 -2
  40. package/checkbox/Checkbox.js +107 -110
  41. package/checkbox/Checkbox.stories.tsx +198 -130
  42. package/checkbox/Checkbox.test.js +155 -0
  43. package/checkbox/types.d.ts +13 -5
  44. package/chip/Chip.js +18 -24
  45. package/chip/Chip.stories.tsx +96 -9
  46. package/chip/Chip.test.js +54 -0
  47. package/chip/types.d.ts +1 -1
  48. package/common/utils.d.ts +1 -0
  49. package/common/utils.js +4 -4
  50. package/common/variables.d.ts +1625 -0
  51. package/common/variables.js +476 -583
  52. package/date-input/Calendar.d.ts +4 -0
  53. package/date-input/Calendar.js +258 -0
  54. package/date-input/DateInput.js +169 -258
  55. package/date-input/DateInput.stories.tsx +199 -33
  56. package/date-input/DateInput.test.js +835 -0
  57. package/date-input/DatePicker.d.ts +4 -0
  58. package/date-input/DatePicker.js +146 -0
  59. package/date-input/Icons.d.ts +6 -0
  60. package/date-input/Icons.js +75 -0
  61. package/date-input/YearPicker.d.ts +4 -0
  62. package/date-input/YearPicker.js +126 -0
  63. package/date-input/types.d.ts +67 -9
  64. package/dialog/Dialog.js +76 -93
  65. package/dialog/Dialog.stories.tsx +230 -123
  66. package/dialog/Dialog.test.js +369 -0
  67. package/dialog/types.d.ts +3 -2
  68. package/dropdown/Dropdown.d.ts +1 -1
  69. package/dropdown/Dropdown.js +246 -253
  70. package/dropdown/Dropdown.stories.tsx +245 -56
  71. package/dropdown/Dropdown.test.js +586 -0
  72. package/dropdown/DropdownMenu.d.ts +4 -0
  73. package/dropdown/DropdownMenu.js +70 -0
  74. package/dropdown/DropdownMenuItem.d.ts +4 -0
  75. package/dropdown/DropdownMenuItem.js +81 -0
  76. package/dropdown/types.d.ts +25 -5
  77. package/file-input/FileInput.d.ts +2 -2
  78. package/file-input/FileInput.js +181 -223
  79. package/file-input/FileInput.stories.tsx +122 -11
  80. package/file-input/FileInput.test.js +457 -0
  81. package/file-input/FileItem.d.ts +4 -14
  82. package/file-input/FileItem.js +44 -66
  83. package/file-input/types.d.ts +17 -0
  84. package/flex/Flex.d.ts +4 -0
  85. package/flex/Flex.js +69 -0
  86. package/flex/Flex.stories.tsx +103 -0
  87. package/flex/types.d.ts +32 -0
  88. package/footer/Footer.js +16 -89
  89. package/footer/Footer.stories.tsx +99 -1
  90. package/footer/Footer.test.js +97 -0
  91. package/footer/Icons.js +1 -1
  92. package/footer/types.d.ts +2 -1
  93. package/header/Header.js +108 -129
  94. package/header/Header.stories.tsx +189 -36
  95. package/header/Header.test.js +79 -0
  96. package/header/Icons.js +2 -2
  97. package/header/types.d.ts +3 -2
  98. package/heading/Heading.js +1 -1
  99. package/heading/Heading.test.js +186 -0
  100. package/inset/Inset.js +1 -34
  101. package/inset/Inset.stories.tsx +36 -36
  102. package/inset/types.d.ts +25 -1
  103. package/layout/ApplicationLayout.d.ts +16 -6
  104. package/layout/ApplicationLayout.js +72 -132
  105. package/layout/ApplicationLayout.stories.tsx +84 -93
  106. package/layout/Icons.d.ts +5 -0
  107. package/layout/Icons.js +13 -2
  108. package/layout/SidenavContext.d.ts +5 -0
  109. package/layout/SidenavContext.js +19 -0
  110. package/layout/types.d.ts +18 -33
  111. package/link/Link.d.ts +3 -2
  112. package/link/Link.js +59 -76
  113. package/link/Link.stories.tsx +155 -53
  114. package/link/Link.test.js +81 -0
  115. package/link/types.d.ts +7 -23
  116. package/main.d.ts +10 -15
  117. package/main.js +48 -82
  118. package/nav-tabs/NavTabs.d.ts +8 -0
  119. package/nav-tabs/NavTabs.js +125 -0
  120. package/nav-tabs/NavTabs.stories.tsx +260 -0
  121. package/nav-tabs/NavTabs.test.js +82 -0
  122. package/nav-tabs/Tab.d.ts +4 -0
  123. package/nav-tabs/Tab.js +150 -0
  124. package/nav-tabs/types.d.ts +53 -0
  125. package/number-input/NumberInput.js +11 -18
  126. package/number-input/NumberInput.stories.tsx +5 -5
  127. package/number-input/NumberInput.test.js +542 -0
  128. package/number-input/types.d.ts +17 -10
  129. package/package.json +20 -23
  130. package/paginator/Icons.d.ts +5 -0
  131. package/paginator/Icons.js +16 -28
  132. package/paginator/Paginator.js +19 -46
  133. package/paginator/Paginator.stories.tsx +24 -0
  134. package/paginator/Paginator.test.js +305 -0
  135. package/paragraph/Paragraph.d.ts +6 -0
  136. package/paragraph/Paragraph.js +38 -0
  137. package/paragraph/Paragraph.stories.tsx +44 -0
  138. package/password-input/PasswordInput.js +7 -4
  139. package/password-input/PasswordInput.test.js +181 -0
  140. package/password-input/types.d.ts +14 -11
  141. package/progress-bar/ProgressBar.d.ts +2 -2
  142. package/progress-bar/ProgressBar.js +61 -55
  143. package/progress-bar/ProgressBar.stories.jsx +47 -12
  144. package/progress-bar/ProgressBar.test.js +110 -0
  145. package/progress-bar/types.d.ts +3 -4
  146. package/quick-nav/QuickNav.d.ts +4 -0
  147. package/quick-nav/QuickNav.js +117 -0
  148. package/quick-nav/QuickNav.stories.tsx +356 -0
  149. package/quick-nav/types.d.ts +21 -0
  150. package/quick-nav/types.js +5 -0
  151. package/radio-group/Radio.d.ts +1 -1
  152. package/radio-group/Radio.js +53 -37
  153. package/radio-group/RadioGroup.js +67 -57
  154. package/radio-group/RadioGroup.stories.tsx +171 -36
  155. package/radio-group/RadioGroup.test.js +563 -89
  156. package/radio-group/types.d.ts +82 -4
  157. package/resultsetTable/Icons.d.ts +7 -0
  158. package/resultsetTable/Icons.js +51 -0
  159. package/resultsetTable/ResultsetTable.js +49 -108
  160. package/resultsetTable/ResultsetTable.stories.tsx +50 -25
  161. package/resultsetTable/ResultsetTable.test.js +325 -0
  162. package/resultsetTable/types.d.ts +2 -2
  163. package/select/Icons.d.ts +10 -0
  164. package/select/Icons.js +93 -0
  165. package/select/Listbox.d.ts +4 -0
  166. package/select/Listbox.js +169 -0
  167. package/select/Option.d.ts +4 -0
  168. package/select/Option.js +97 -0
  169. package/select/Select.js +185 -384
  170. package/select/Select.stories.tsx +600 -201
  171. package/select/Select.test.js +2228 -0
  172. package/select/types.d.ts +53 -13
  173. package/sidenav/Sidenav.d.ts +6 -5
  174. package/sidenav/Sidenav.js +183 -53
  175. package/sidenav/Sidenav.stories.tsx +249 -149
  176. package/sidenav/Sidenav.test.js +44 -0
  177. package/sidenav/types.d.ts +50 -27
  178. package/slider/Slider.d.ts +2 -2
  179. package/slider/Slider.js +124 -98
  180. package/slider/Slider.stories.tsx +72 -9
  181. package/slider/Slider.test.js +250 -0
  182. package/slider/types.d.ts +10 -2
  183. package/spinner/Spinner.js +4 -4
  184. package/spinner/Spinner.stories.jsx +27 -1
  185. package/spinner/Spinner.test.js +64 -0
  186. package/switch/Switch.d.ts +2 -2
  187. package/switch/Switch.js +152 -69
  188. package/switch/Switch.stories.tsx +53 -42
  189. package/switch/Switch.test.js +225 -0
  190. package/switch/types.d.ts +12 -4
  191. package/table/Table.js +3 -3
  192. package/table/Table.stories.jsx +80 -1
  193. package/table/Table.test.js +26 -0
  194. package/tabs/Tab.d.ts +4 -0
  195. package/tabs/Tab.js +133 -0
  196. package/tabs/Tabs.d.ts +1 -1
  197. package/tabs/Tabs.js +363 -109
  198. package/tabs/Tabs.stories.tsx +119 -13
  199. package/tabs/Tabs.test.js +350 -0
  200. package/tabs/types.d.ts +19 -5
  201. package/tag/Tag.js +17 -22
  202. package/tag/Tag.stories.tsx +25 -8
  203. package/tag/Tag.test.js +60 -0
  204. package/tag/types.d.ts +1 -1
  205. package/text-input/Icons.d.ts +8 -0
  206. package/text-input/Icons.js +60 -0
  207. package/text-input/Suggestion.d.ts +4 -0
  208. package/text-input/Suggestion.js +84 -0
  209. package/text-input/Suggestions.d.ts +4 -0
  210. package/text-input/Suggestions.js +134 -0
  211. package/text-input/TextInput.js +224 -345
  212. package/text-input/TextInput.stories.tsx +310 -197
  213. package/text-input/TextInput.test.js +1723 -0
  214. package/text-input/types.d.ts +50 -12
  215. package/textarea/Textarea.js +22 -29
  216. package/textarea/Textarea.stories.jsx +93 -13
  217. package/textarea/Textarea.test.js +437 -0
  218. package/textarea/types.d.ts +18 -11
  219. package/toggle-group/ToggleGroup.d.ts +1 -1
  220. package/toggle-group/ToggleGroup.js +6 -5
  221. package/toggle-group/ToggleGroup.stories.tsx +46 -4
  222. package/toggle-group/ToggleGroup.test.js +156 -0
  223. package/toggle-group/types.d.ts +9 -1
  224. package/typography/Typography.d.ts +4 -0
  225. package/typography/Typography.js +32 -0
  226. package/typography/Typography.stories.tsx +198 -0
  227. package/typography/types.d.ts +18 -0
  228. package/typography/types.js +5 -0
  229. package/useTheme.d.ts +1234 -1
  230. package/useTheme.js +3 -3
  231. package/useTranslatedLabels.d.ts +85 -0
  232. package/useTranslatedLabels.js +20 -0
  233. package/utils/BaseTypography.d.ts +21 -0
  234. package/utils/BaseTypography.js +108 -0
  235. package/utils/FocusLock.d.ts +13 -0
  236. package/utils/FocusLock.js +139 -0
  237. package/wizard/Wizard.d.ts +1 -1
  238. package/wizard/Wizard.js +59 -55
  239. package/wizard/Wizard.stories.tsx +48 -19
  240. package/wizard/Wizard.test.js +141 -0
  241. package/wizard/types.d.ts +10 -5
  242. package/ThemeContext.d.ts +0 -15
  243. package/ThemeContext.js +0 -243
  244. package/V3Select/V3Select.js +0 -455
  245. package/V3Select/index.d.ts +0 -27
  246. package/V3Textarea/V3Textarea.js +0 -260
  247. package/V3Textarea/index.d.ts +0 -27
  248. package/common/RequiredComponent.js +0 -32
  249. package/date/Date.js +0 -373
  250. package/date/index.d.ts +0 -27
  251. package/input-text/Icons.js +0 -22
  252. package/input-text/InputText.js +0 -611
  253. package/input-text/index.d.ts +0 -36
  254. package/list/List.d.ts +0 -4
  255. package/list/List.js +0 -47
  256. package/list/List.stories.tsx +0 -95
  257. package/list/types.d.ts +0 -7
  258. package/radio/Radio.d.ts +0 -4
  259. package/radio/Radio.js +0 -174
  260. package/radio/Radio.stories.tsx +0 -192
  261. package/radio/types.d.ts +0 -54
  262. package/row/Row.d.ts +0 -3
  263. package/row/Row.js +0 -127
  264. package/row/Row.stories.tsx +0 -237
  265. package/row/types.d.ts +0 -10
  266. package/stack/Stack.d.ts +0 -3
  267. package/stack/Stack.js +0 -97
  268. package/stack/Stack.stories.tsx +0 -164
  269. package/stack/types.d.ts +0 -9
  270. package/text/Text.d.ts +0 -7
  271. package/text/Text.js +0 -30
  272. package/text/Text.stories.tsx +0 -19
  273. package/toggle/Toggle.js +0 -186
  274. package/toggle/index.d.ts +0 -21
  275. package/upload/Upload.js +0 -201
  276. package/upload/buttons-upload/ButtonsUpload.js +0 -111
  277. package/upload/buttons-upload/Icons.js +0 -40
  278. package/upload/dragAndDropArea/DragAndDropArea.js +0 -225
  279. package/upload/dragAndDropArea/Icons.js +0 -39
  280. package/upload/file-upload/FileToUpload.js +0 -115
  281. package/upload/file-upload/Icons.js +0 -66
  282. package/upload/files-upload/FilesToUpload.js +0 -109
  283. package/upload/index.d.ts +0 -15
  284. package/upload/transaction/Icons.js +0 -160
  285. package/upload/transaction/Transaction.js +0 -104
  286. package/upload/transactions/Transactions.js +0 -94
  287. /package/{list → badge}/types.js +0 -0
  288. /package/{radio → bulleted-list}/types.js +0 -0
  289. /package/{row → flex}/types.js +0 -0
  290. /package/{stack → nav-tabs}/types.js +0 -0
@@ -0,0 +1,356 @@
1
+ import React from "react";
2
+ import styled from "styled-components";
3
+ import DxcQuickNav from "./QuickNav";
4
+ import DxcHeading from "../heading/Heading";
5
+ import DxcParagraph from "../paragraph/Paragraph";
6
+ import Title from "../../.storybook/components/Title";
7
+ import ExampleContainer from "../../.storybook/components/ExampleContainer";
8
+ import { HalstackProvider } from "../HalstackContext";
9
+
10
+ export default {
11
+ title: "QuickNav",
12
+ component: DxcQuickNav,
13
+ };
14
+
15
+ const opinionatedTheme = {
16
+ quickNav: {
17
+ fontColor: "#666666",
18
+ accentColor: "#9a6bb2",
19
+ },
20
+ };
21
+
22
+ const defaultLinks = [
23
+ {
24
+ label: "Overview",
25
+ },
26
+ {
27
+ label: "Principles",
28
+ links: [{ label: "Color" }, { label: "Spacing" }, { label: "Typography" }],
29
+ },
30
+ {
31
+ label: "Components",
32
+ links: [
33
+ {
34
+ label: "Accordion",
35
+ },
36
+ {
37
+ label: "Button",
38
+ },
39
+ ],
40
+ },
41
+ ];
42
+
43
+ const links = [
44
+ {
45
+ label: "Overview",
46
+ links: [
47
+ {
48
+ label: "Introduction",
49
+ },
50
+ ],
51
+ },
52
+ {
53
+ label: "Components",
54
+ links: [
55
+ {
56
+ label: "Introduction",
57
+ },
58
+ {
59
+ label: "Accordion",
60
+ },
61
+ ],
62
+ },
63
+ {
64
+ label: "Principles very very very very very very very very long",
65
+ links: [
66
+ { label: "Color very very very very very very very very long" },
67
+ { label: "Spacingveryveryveryveryveryveryveryverylong" },
68
+ { label: "Typography" },
69
+ ],
70
+ },
71
+ {
72
+ label: "Componentsveryveryveryveryveryveryveryverylong",
73
+ links: [
74
+ {
75
+ label: "Accordion",
76
+ },
77
+ ],
78
+ },
79
+ ];
80
+
81
+ export const Chromatic = () => (
82
+ <>
83
+ <ExampleContainer>
84
+ <Title title="Default" level={4} />
85
+ <QuickNavContainer>
86
+ <DxcQuickNav links={defaultLinks} />
87
+ </QuickNavContainer>
88
+ </ExampleContainer>
89
+ <ExampleContainer>
90
+ <Title title="Text overflow" level={4} />
91
+ <QuickNavContainer>
92
+ <DxcQuickNav links={links} />
93
+ </QuickNavContainer>
94
+ </ExampleContainer>
95
+ <ExampleContainer pseudoState="pseudo-hover">
96
+ <Title title="Link hovered" level={4} />
97
+ <QuickNavContainer>
98
+ <DxcQuickNav links={links} />
99
+ </QuickNavContainer>
100
+ </ExampleContainer>
101
+ <ExampleContainer pseudoState="pseudo-focus">
102
+ <Title title="Link focus" level={4} />
103
+ <QuickNavContainer>
104
+ <DxcQuickNav links={links} />
105
+ </QuickNavContainer>
106
+ </ExampleContainer>
107
+ <ExampleContainer>
108
+ <Title title="QuickNav with content" level={4} />
109
+ <Container>
110
+ <ContentContainer>
111
+ <Content id="overview">
112
+ <DxcHeading level={1} text="Overview" margin={{ bottom: "small" }} />
113
+ <DxcParagraph>
114
+ Halstack is the DXC Technology's open source design system for insurance products and digital experiences.
115
+ Our system provides all the tools and resources needed to create superior, beautiful but above all,
116
+ functional user experiences. Halstack is the DXC Technology's open source design system for insurance
117
+ products and digital experiences. Our system provides all the tools and resources needed to create
118
+ superior, beautiful but above all, functional user experiences.Halstack is the DXC Technology's open
119
+ source design system for insurance products and digital experiences. Our system provides all the tools and
120
+ resources needed to create superior, beautiful but above all, functional user experiences.Halstack is the
121
+ DXC Technology's open source design system for insurance products and digital experiences. Our system
122
+ provides all the tools and resources needed to create superior, beautiful but above all, functional user
123
+ experiences.Halstack is the DXC Technology's open source design system for insurance products and digital
124
+ experiences. Our system provides all the tools and resources needed to create superior, beautiful but
125
+ above all, functional user experiences.Halstack is the DXC Technology's open source design system for
126
+ insurance products and digital experiences. Our system provides all the tools and resources needed to
127
+ create superior, beautiful but above all, functional user experiences.Halstack is the DXC Technology's
128
+ open source design system for insurance products and digital experiences. Our system provides all the
129
+ tools and resources needed to create superior, beautiful but above all, functional user experiences.
130
+ </DxcParagraph>
131
+ <Content id="overview-introduction">
132
+ <DxcHeading level={2} text="Introduction" margin={{ top: "xsmall", bottom: "xsmall" }} />
133
+ <DxcParagraph>
134
+ Design principles Halstack design principles are the fundamental part of DXC Technology's approach to
135
+ provide guidance for development teams in order to deliver delightful and consistent user experiences to
136
+ our customers: Balance Consistency Visual hierarchy All our components, design tokens, accessibility
137
+ guidelines, responsive design techniques, and layout proposals have been carefully curated by DXC design
138
+ and engineering teams with the objective of creating a unique visual language and ecosystem for our
139
+ applications. This is the DXC way of creating User Experiences. Open Source Halstack is an open source
140
+ design system, this means that we work towards DXC Technology bussines needs, but it is open for anyone
141
+ to use and contribute back to. We are charmed to receive external contributions to help us find bugs,
142
+ design new features, or help us improve the project documentation. If you're interested, definitely
143
+ check out our contribution guidelines.Design principles Halstack design principles are the fundamental
144
+ part of DXC Technology's approach to provide guidance for development teams in order to deliver
145
+ delightful and consistent user experiences to our customers: Balance Consistency Visual hierarchy All
146
+ our components, design tokens, accessibility guidelines, responsive design techniques, and layout
147
+ proposals have been carefully curated by DXC design and engineering teams with the objective of creating
148
+ a unique visual language and ecosystem for our applications. This is the DXC way of creating User
149
+ Experiences. Open Source Halstack is an open source design system, this means that we work towards DXC
150
+ Technology bussines needs, but it is open for anyone to use and contribute back to. We are charmed to
151
+ receive external contributions to help us find bugs, design new features, or help us improve the project
152
+ documentation. If you're interested, definitely check out our contribution guidelines.Design principles
153
+ Halstack design principles are the fundamental part of DXC Technology's approach to provide guidance for
154
+ development teams in order to deliver delightful and consistent user experiences to our customers:
155
+ Balance Consistency Visual hierarchy All our components, design tokens, accessibility guidelines,
156
+ responsive design techniques, and layout proposals have been carefully curated by DXC design and
157
+ engineering teams with the objective of creating a unique visual language and ecosystem for our
158
+ applications. This is the DXC way of creating User Experiences. Open Source Halstack is an open source
159
+ design system, this means that we work towards DXC Technology bussines needs, but it is open for anyone
160
+ to use and contribute back to. We are charmed to receive external contributions to help us find bugs,
161
+ design new features, or help us improve the project documentation. If you're interested, definitely
162
+ check out our contribution guidelines.
163
+ </DxcParagraph>
164
+ </Content>
165
+ </Content>
166
+ <Content id="components">
167
+ <DxcHeading level={1} text="Components" margin={{ top: "small", bottom: "xsmall" }} />
168
+ <Content id="components-introduction">
169
+ <DxcHeading level={2} text="Introduction" margin={{ top: "xsmall", bottom: "xsmall" }} />
170
+ <DxcParagraph>
171
+ Design principles Halstack design principles are the fundamental part of DXC Technology's approach to
172
+ provide guidance for development teams in order to deliver delightful and consistent user experiences to
173
+ our customers: Balance Consistency Visual hierarchy All our components, design tokens, accessibility
174
+ guidelines, responsive design techniques, and layout proposals have been carefully curated by DXC design
175
+ and engineering teams with the objective of creating a unique visual language and ecosystem for our
176
+ applications. This is the DXC way of creating User Experiences. Open Source Halstack is an open source
177
+ design system, this means that we work towards DXC Technology bussines needs, but it is open for anyone
178
+ to use and contribute back to. We are charmed to receive external contributions to help us find bugs,
179
+ design new features, or help us improve the project documentation. If you're interested, definitely
180
+ check out our contribution guidelines.Design principles Halstack design principles are the fundamental
181
+ part of DXC Technology's approach to provide guidance for development teams in order to deliver
182
+ delightful and consistent user experiences to our customers: Balance Consistency Visual hierarchy All
183
+ our components, design tokens, accessibility guidelines, responsive design techniques, and layout
184
+ proposals have been carefully curated by DXC design and engineering teams with the objective of creating
185
+ a unique visual language and ecosystem for our applications. This is the DXC way of creating User
186
+ Experiences. Open Source Halstack is an open source design system, this means that we work towards DXC
187
+ Technology bussines needs, but it is open for anyone to use and contribute back to. We are charmed to
188
+ receive external contributions to help us find bugs, design new features, or help us improve the project
189
+ documentation. If you're interested, definitely check out our contribution guidelines.Design principles
190
+ Halstack design principles are the fundamental part of DXC Technology's approach to provide guidance for
191
+ development teams in order to deliver delightful and consistent user experiences to our customers:
192
+ Balance Consistency Visual hierarchy All our components, design tokens, accessibility guidelines,
193
+ responsive design techniques, and layout proposals have been carefully curated by DXC design and
194
+ engineering teams with the objective of creating a unique visual language and ecosystem for our
195
+ applications. This is the DXC way of creating User Experiences. Open Source Halstack is an open source
196
+ design system, this means that we work towards DXC Technology bussines needs, but it is open for anyone
197
+ to use and contribute back to. We are charmed to receive external contributions to help us find bugs,
198
+ design new features, or help us improve the project documentation. If you're interested, definitely
199
+ check out our contribution guidelines.
200
+ </DxcParagraph>
201
+ </Content>
202
+ <Content id="components-accordion">
203
+ <DxcHeading level={2} text="Accordion" margin={{ top: "xsmall", bottom: "xsmall" }} />
204
+ <DxcParagraph>
205
+ Accordions are used to group similar content and hide or show it depending on user needs or preferences.
206
+ Accordions give users more granular control over the interface and help digest content in stages, rather
207
+ than all at once.
208
+ </DxcParagraph>
209
+ </Content>
210
+ </Content>
211
+ <Content id="principles-very-very-very-very-very-very-very-very-long">
212
+ <DxcHeading level={1} text="Principles" margin={{ top: "small", bottom: "xsmall" }} />
213
+ <Content id="principles-very-very-very-very-very-very-very-very-long-color-very-very-very-very-very-very-very-very-long">
214
+ <DxcHeading level={2} text="Color" margin={{ top: "xsmall", bottom: "xsmall" }} />
215
+ <DxcParagraph>
216
+ The color palette is an essential asset as a communication resource of our design system. Halstack color
217
+ palette brings a unified consistency and helps in guiding the user's perception order. Our color palette
218
+ is based in the HSL model . All our color families are calculated using the lightness value of the
219
+ standard DXC palette colors. Color Tokens Halstack uses tokens to manage color. Appart from a
220
+ multi-purpose greyscale family, purple and blue are the core color families used in our set of
221
+ components. Additional families as red, green and yellow help as feedback role-based color palettes and
222
+ must not be used outside this context.The color palette is an essential asset as a communication
223
+ resource of our design system. Halstack color palette brings a unified consistency and helps in guiding
224
+ the user's perception order. Our color palette is based in the HSL model . All our color families are
225
+ calculated using the lightness value of the standard DXC palette colors. Color Tokens Halstack uses
226
+ tokens to manage color. Appart from a multi-purpose greyscale family, purple and blue are the core color
227
+ families used in our set of components. Additional families as red, green and yellow help as feedback
228
+ role-based color palettes and must not be used outside this context.The color palette is an essential
229
+ asset as a communication resource of our design system. Halstack color palette brings a unified
230
+ consistency and helps in guiding the user's perception order. Our color palette is based in the HSL
231
+ model . All our color families are calculated using the lightness value of the standard DXC palette
232
+ colors. Color Tokens Halstack uses tokens to manage color. Appart from a multi-purpose greyscale family,
233
+ purple and blue are the core color families used in our set of components. Additional families as red,
234
+ green and yellow help as feedback role-based color palettes and must not be used outside this
235
+ context.The color palette is an essential asset as a communication resource of our design system.
236
+ Halstack color palette brings a unified consistency and helps in guiding the user's perception order.
237
+ Our color palette is based in the HSL model . All our color families are calculated using the lightness
238
+ value of the standard DXC palette colors. Color Tokens Halstack uses tokens to manage color. Appart from
239
+ a multi-purpose greyscale family, purple and blue are the core color families used in our set of
240
+ components. Additional families as red, green and yellow help as feedback role-based color palettes and
241
+ must not be used outside this context.The color palette is an essential asset as a communication
242
+ resource of our design system. Halstack color palette brings a unified consistency and helps in guiding
243
+ the user's perception order. Our color palette is based in the HSL model . All our color families are
244
+ calculated using the lightness value of the standard DXC palette colors. Color Tokens Halstack uses
245
+ tokens to manage color. Appart from a multi-purpose greyscale family, purple and blue are the core color
246
+ families used in our set of components. Additional families as red, green and yellow help as feedback
247
+ role-based color palettes and must not be used outside this context.
248
+ </DxcParagraph>
249
+ </Content>
250
+ <Content id="principles-very-very-very-very-very-very-very-very-long-spacingveryveryveryveryveryveryveryverylong">
251
+ <DxcHeading level={2} text="Spacing" margin={{ top: "xsmall", bottom: "xsmall" }} />
252
+ <DxcParagraph>
253
+ In the search of consistent alignment between the elements we provide a spacing scale based on a root
254
+ values of 8px and 4px. The numbers 4 and 8 are easily multiplied, they provide flexible and consistent,
255
+ yet distinct enough, steps between them.In the search of consistent alignment between the elements we
256
+ provide a spacing scale based on a root values of 8px and 4px. The numbers 4 and 8 are easily
257
+ multiplied, they provide flexible and consistent, yet distinct enough, steps between them.In the search
258
+ of consistent alignment between the elements we provide a spacing scale based on a root values of 8px
259
+ and 4px. The numbers 4 and 8 are easily multiplied, they provide flexible and consistent, yet distinct
260
+ enough, steps between them.In the search of consistent alignment between the elements we provide a
261
+ spacing scale based on a root values of 8px and 4px. The numbers 4 and 8 are easily multiplied, they
262
+ provide flexible and consistent, yet distinct enough, steps between them.In the search of consistent
263
+ alignment between the elements we provide a spacing scale based on a root values of 8px and 4px. The
264
+ numbers 4 and 8 are easily multiplied, they provide flexible and consistent, yet distinct enough, steps
265
+ between them.In the search of consistent alignment between the elements we provide a spacing scale based
266
+ on a root values of 8px and 4px. The numbers 4 and 8 are easily multiplied, they provide flexible and
267
+ consistent, yet distinct enough, steps between them.In the search of consistent alignment between the
268
+ elements we provide a spacing scale based on a root values of 8px and 4px. The numbers 4 and 8 are
269
+ easily multiplied, they provide flexible and consistent, yet distinct enough, steps between them.
270
+ </DxcParagraph>
271
+ </Content>
272
+ <Content id="principles-very-very-very-very-very-very-very-very-long-typography">
273
+ <DxcHeading level={2} text="Typography" margin={{ top: "xsmall", bottom: "xsmall" }} />
274
+ <DxcParagraph>
275
+ Our selected typography helps in structuring our user's experience based on the visual impact that it
276
+ has on the user interface content. It defines what is the first noticeable piece of information or data
277
+ based on the font shape, size, color, or type and it highlights some pieces of text over the rest. Some
278
+ typographic elements used in Halstack Design System include headers, body, taglines, captions, and
279
+ labels. Make sure you include all the different typographic variants in order to enhance the
280
+ application's content structure, including the Heading component which defines different levels of page
281
+ and section titles.Our selected typography helps in structuring our user's experience based on the
282
+ visual impact that it has on the user interface content. It defines what is the first noticeable piece
283
+ of information or data based on the font shape, size, color, or type and it highlights some pieces of
284
+ text over the rest. Some typographic elements used in Halstack Design System include headers, body,
285
+ taglines, captions, and labels. Make sure you include all the different typographic variants in order to
286
+ enhance the application's content structure, including the Heading component which defines different
287
+ levels of page and section titles.Our selected typography helps in structuring our user's experience
288
+ based on the visual impact that it has on the user interface content. It defines what is the first
289
+ noticeable piece of information or data based on the font shape, size, color, or type and it highlights
290
+ some pieces of text over the rest. Some typographic elements used in Halstack Design System include
291
+ headers, body, taglines, captions, and labels. Make sure you include all the different typographic
292
+ variants in order to enhance the application's content structure, including the Heading component which
293
+ defines different levels of page and section titles.Our selected typography helps in structuring our
294
+ user's experience based on the visual impact that it has on the user interface content. It defines what
295
+ is the first noticeable piece of information or data based on the font shape, size, color, or type and
296
+ it highlights some pieces of text over the rest. Some typographic elements used in Halstack Design
297
+ System include headers, body, taglines, captions, and labels. Make sure you include all the different
298
+ typographic variants in order to enhance the application's content structure, including the Heading
299
+ component which defines different levels of page and section titles.Our selected typography helps in
300
+ structuring our user's experience based on the visual impact that it has on the user interface content.
301
+ It defines what is the first noticeable piece of information or data based on the font shape, size,
302
+ color, or type and it highlights some pieces of text over the rest. Some typographic elements used in
303
+ Halstack Design System include headers, body, taglines, captions, and labels. Make sure you include all
304
+ the different typographic variants in order to enhance the application's content structure, including
305
+ the Heading component which defines different levels of page and section titles.
306
+ </DxcParagraph>
307
+ </Content>
308
+ </Content>
309
+ <Content id="componentsveryveryveryveryveryveryveryverylong">
310
+ <DxcHeading level={1} text="Components" margin={{ top: "small", bottom: "xsmall" }} />
311
+ <Content id="componentsveryveryveryveryveryveryveryverylong-accordion">
312
+ <DxcHeading level={2} text="Accordion" margin={{ top: "xsmall", bottom: "xsmall" }} />
313
+ <DxcParagraph>
314
+ Accordions are used to group similar content and hide or show it depending on user needs or preferences.
315
+ Accordions give users more granular control over the interface and help digest content in stages, rather
316
+ than all at once.
317
+ </DxcParagraph>
318
+ </Content>
319
+ </Content>
320
+ </ContentContainer>
321
+ <QuickNavContainer>
322
+ <DxcQuickNav title="Sections" links={links} />
323
+ </QuickNavContainer>
324
+ </Container>
325
+ </ExampleContainer>
326
+ <Title title="Opinionated theme" level={2} />
327
+ <ExampleContainer>
328
+ <HalstackProvider theme={opinionatedTheme}>
329
+ <DxcQuickNav links={defaultLinks} />
330
+ </HalstackProvider>
331
+ </ExampleContainer>
332
+ </>
333
+ );
334
+
335
+ const Container = styled.div`
336
+ display: flex;
337
+ flex-direction: row;
338
+ width: 100%;
339
+ `;
340
+
341
+ const ContentContainer = styled.div`
342
+ display: flex;
343
+ flex-direction: column;
344
+ padding: 60px;
345
+ margin: 0 auto;
346
+ width: 800px;
347
+ `;
348
+
349
+ const Content = styled.div``;
350
+
351
+ const QuickNavContainer = styled.div`
352
+ max-height: calc(100vh - 100px);
353
+ position: sticky;
354
+ top: 100px;
355
+ width: 300px;
356
+ `;
@@ -0,0 +1,21 @@
1
+ declare type Props = {
2
+ /**
3
+ * Title of the quick nav component.
4
+ */
5
+ title?: string;
6
+ /**
7
+ * Links to be shown inside the quick nav component.
8
+ */
9
+ links: LinkType[];
10
+ };
11
+ declare type LinkType = {
12
+ /**
13
+ * Label to be shown in the link.
14
+ */
15
+ label: string;
16
+ /**
17
+ * Sublinks of the link.
18
+ */
19
+ links?: LinkType[];
20
+ };
21
+ export default Props;
@@ -0,0 +1,5 @@
1
+ "use strict";
2
+
3
+ Object.defineProperty(exports, "__esModule", {
4
+ value: true
5
+ });
@@ -1,4 +1,4 @@
1
1
  import React from "react";
2
2
  import { RadioProps } from "./types";
3
- declare const _default: React.MemoExoticComponent<({ option, currentValue, onClick, onFocus, error, disabled, focused, readonly, }: RadioProps) => JSX.Element>;
3
+ declare const _default: React.MemoExoticComponent<({ label, checked, onClick, error, disabled, focused, readonly, tabIndex, }: RadioProps) => JSX.Element>;
4
4
  export default _default;
@@ -28,14 +28,14 @@ function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "functio
28
28
  function _interopRequireWildcard(obj, nodeInterop) { if (!nodeInterop && obj && obj.__esModule) { return obj; } if (obj === null || _typeof(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; }
29
29
 
30
30
  var DxcRadio = function DxcRadio(_ref) {
31
- var option = _ref.option,
32
- currentValue = _ref.currentValue,
33
- _onClick = _ref.onClick,
34
- onFocus = _ref.onFocus,
31
+ var label = _ref.label,
32
+ checked = _ref.checked,
33
+ onClick = _ref.onClick,
35
34
  error = _ref.error,
36
35
  disabled = _ref.disabled,
37
36
  focused = _ref.focused,
38
- readonly = _ref.readonly;
37
+ readonly = _ref.readonly,
38
+ tabIndex = _ref.tabIndex;
39
39
 
40
40
  var _useState = (0, _react.useState)("radio-".concat((0, _uuid.v4)())),
41
41
  _useState2 = (0, _slicedToArray2["default"])(_useState, 1),
@@ -43,7 +43,13 @@ var DxcRadio = function DxcRadio(_ref) {
43
43
 
44
44
  var ref = (0, _react.useRef)(null);
45
45
  var colorsTheme = (0, _useTheme["default"])();
46
- var checked = option.value === currentValue;
46
+
47
+ var handleOnClick = function handleOnClick() {
48
+ var _ref$current;
49
+
50
+ onClick();
51
+ document.activeElement !== (ref === null || ref === void 0 ? void 0 : ref.current) && (ref === null || ref === void 0 ? void 0 : (_ref$current = ref.current) === null || _ref$current === void 0 ? void 0 : _ref$current.focus());
52
+ };
47
53
 
48
54
  var _useState3 = (0, _react.useState)(true),
49
55
  _useState4 = (0, _slicedToArray2["default"])(_useState3, 2),
@@ -51,7 +57,7 @@ var DxcRadio = function DxcRadio(_ref) {
51
57
  setFirstUpdate = _useState4[1];
52
58
 
53
59
  (0, _react.useLayoutEffect)(function () {
54
- var _ref$current;
60
+ var _ref$current2;
55
61
 
56
62
  // Don't apply in the first render
57
63
  if (firstUpdate) {
@@ -59,7 +65,7 @@ var DxcRadio = function DxcRadio(_ref) {
59
65
  return;
60
66
  }
61
67
 
62
- focused && (ref === null || ref === void 0 ? void 0 : (_ref$current = ref.current) === null || _ref$current === void 0 ? void 0 : _ref$current.focus());
68
+ focused && (ref === null || ref === void 0 ? void 0 : (_ref$current2 = ref.current) === null || _ref$current2 === void 0 ? void 0 : _ref$current2.focus());
63
69
  }, [focused]);
64
70
  return /*#__PURE__*/_react["default"].createElement(_styledComponents.ThemeProvider, {
65
71
  theme: colorsTheme.radioGroup
@@ -67,27 +73,16 @@ var DxcRadio = function DxcRadio(_ref) {
67
73
  error: error,
68
74
  disabled: disabled,
69
75
  readonly: readonly,
70
- onMouseDown: function onMouseDown(event) {
71
- // Prevents div's onclick from stealing the radio button's focus
72
- event.preventDefault();
73
- },
74
- onClick: function onClick() {
75
- var _ref$current2;
76
-
77
- ref === null || ref === void 0 ? void 0 : (_ref$current2 = ref.current) === null || _ref$current2 === void 0 ? void 0 : _ref$current2.focus();
78
-
79
- _onClick();
80
- }
76
+ onClick: disabled ? undefined : handleOnClick
81
77
  }, /*#__PURE__*/_react["default"].createElement(RadioInputContainer, null, /*#__PURE__*/_react["default"].createElement(RadioInput, {
82
78
  error: error,
83
79
  disabled: disabled,
84
80
  readonly: readonly,
85
- onFocus: onFocus,
86
81
  role: "radio",
87
82
  "aria-checked": checked,
88
- "aria-disabled": option.disabled,
83
+ "aria-disabled": disabled,
89
84
  "aria-labelledby": radioLabelId,
90
- tabIndex: disabled ? -1 : focused ? 0 : -1,
85
+ tabIndex: disabled ? -1 : focused ? tabIndex : -1,
91
86
  ref: ref
92
87
  }, checked && /*#__PURE__*/_react["default"].createElement(Dot, {
93
88
  disabled: disabled,
@@ -96,30 +91,39 @@ var DxcRadio = function DxcRadio(_ref) {
96
91
  }))), /*#__PURE__*/_react["default"].createElement(Label, {
97
92
  id: radioLabelId,
98
93
  disabled: disabled
99
- }, option.label))));
94
+ }, label))));
100
95
  };
101
96
 
102
- var RadioMainContainer = _styledComponents["default"].div(_templateObject || (_templateObject = (0, _taggedTemplateLiteral2["default"])(["\n display: flex;\n"])));
97
+ var getRadioInputStateColor = function getRadioInputStateColor(props, state) {
98
+ switch (state) {
99
+ case "enabled":
100
+ return props.disabled ? props.theme.disabledRadioInputColor : props.error ? props.theme.errorRadioInputColor : props.readonly ? props.theme.readonlyRadioInputColor : props.theme.radioInputColor;
103
101
 
104
- var RadioContainer = _styledComponents["default"].span(_templateObject2 || (_templateObject2 = (0, _taggedTemplateLiteral2["default"])(["\n display: inline-flex;\n align-items: center;\n cursor: ", ";\n \n ", "\n"])), function (props) {
105
- return props.disabled ? "not-allowed" : props.readonly ? "default" : "pointer";
106
- }, function (props) {
107
- return !props.disabled && "\n &:hover {\n & > div > div { \n border-color: ".concat(props.error ? props.theme.hoverErrorRadioInputColor : props.readonly ? props.theme.hoverReadonlyRadioInputColor : props.theme.hoverRadioInputColor, ";\n & > span {\n background-color: ").concat(props.error ? props.theme.hoverErrorRadioInputColor : props.readonly ? props.theme.hoverReadonlyRadioInputColor : props.theme.hoverRadioInputColor, ";\n }\n };\n }\n &:active {\n & > div > div {\n border-color: ").concat(props.error ? props.theme.activeErrorRadioInputColor : props.readonly ? props.theme.activeReadonlyRadioInputColor : props.theme.activeRadioInputColor, ";\n & > span {\n background-color: ").concat(props.error ? props.theme.activeErrorRadioInputColor : props.readonly ? props.theme.activeReadonlyRadioInputColor : props.theme.activeRadioInputColor, ";\n }\n }\n }\n ");
108
- });
102
+ case "hover":
103
+ return props.error ? props.theme.hoverErrorRadioInputColor : props.readonly ? props.theme.hoverReadonlyRadioInputColor : props.theme.hoverRadioInputColor;
104
+
105
+ case "active":
106
+ return props.error ? props.theme.activeErrorRadioInputColor : props.readonly ? props.theme.activeReadonlyRadioInputColor : props.theme.activeRadioInputColor;
107
+ }
108
+ };
109
+
110
+ var RadioMainContainer = _styledComponents["default"].div(_templateObject || (_templateObject = (0, _taggedTemplateLiteral2["default"])(["\n display: flex;\n"])));
109
111
 
110
- var RadioInputContainer = _styledComponents["default"].div(_templateObject3 || (_templateObject3 = (0, _taggedTemplateLiteral2["default"])(["\n display: flex;\n align-items: center;\n justify-content: center;\n height: 24px;\n width: 24px;\n"])));
112
+ var RadioInputContainer = _styledComponents["default"].span(_templateObject2 || (_templateObject2 = (0, _taggedTemplateLiteral2["default"])(["\n display: flex;\n align-items: center;\n justify-content: center;\n height: 24px;\n width: 24px;\n"])));
111
113
 
112
- var RadioInput = _styledComponents["default"].div(_templateObject4 || (_templateObject4 = (0, _taggedTemplateLiteral2["default"])(["\n display: flex;\n align-items: center;\n justify-content: center;\n box-sizing: border-box;\n width: 18px;\n height: 18px;\n border: 2px solid\n ", ";\n border-radius: 50%;\n box-shadow: 0 0 0 2px transparent;\n\n ", "\n"])), function (props) {
113
- if (props.disabled) return props.theme.disabledRadioInputColor;else if (props.error) return props.theme.errorRadioInputColor;else if (props.readonly) return props.theme.readonlyRadioInputColor;else return props.theme.radioInputColor;
114
+ var RadioInput = _styledComponents["default"].span(_templateObject3 || (_templateObject3 = (0, _taggedTemplateLiteral2["default"])(["\n box-sizing: border-box;\n display: flex;\n align-items: center;\n justify-content: center;\n width: 18px;\n height: 18px;\n border: 2px solid ", ";\n border-radius: 50%;\n\n &:focus {\n outline: 2px solid ", ";\n outline-offset: 1px;\n }\n ", "\n"])), function (props) {
115
+ return getRadioInputStateColor(props, "enabled");
114
116
  }, function (props) {
115
- return !props.disabled ? "&:focus {\n outline: 2px solid ".concat(props.theme.focusBorderColor, ";\n outline-offset: 1px;\n }\n &:focus-visible {\n outline: 2px solid ").concat(props.theme.focusBorderColor, ";\n outline-offset: 1px;\n }\n ") : "\n pointer-events: none;\n :focus-visible {\n outline: none;\n }\n ";
117
+ return props.theme.focusBorderColor;
118
+ }, function (props) {
119
+ return props.disabled && "pointer-events: none;";
116
120
  });
117
121
 
118
- var Dot = _styledComponents["default"].span(_templateObject5 || (_templateObject5 = (0, _taggedTemplateLiteral2["default"])(["\n height: 10px;\n width: 10px;\n border-radius: 50%;\n background-color: ", ";\n"])), function (props) {
119
- if (props.disabled) return props.theme.disabledRadioInputColor;else if (props.error) return props.theme.errorRadioInputColor;else if (props.readonly) return props.theme.readonlyRadioInputColor;else return props.theme.radioInputColor;
122
+ var Dot = _styledComponents["default"].span(_templateObject4 || (_templateObject4 = (0, _taggedTemplateLiteral2["default"])(["\n height: 10px;\n width: 10px;\n border-radius: 50%;\n background-color: ", ";\n"])), function (props) {
123
+ return getRadioInputStateColor(props, "enabled");
120
124
  });
121
125
 
122
- var Label = _styledComponents["default"].span(_templateObject6 || (_templateObject6 = (0, _taggedTemplateLiteral2["default"])(["\n margin-left: ", ";\n font-family: ", ";\n font-size: ", ";\n font-style: ", ";\n font-weight: ", ";\n line-height: ", ";\n ", "\n"])), function (props) {
126
+ var Label = _styledComponents["default"].span(_templateObject5 || (_templateObject5 = (0, _taggedTemplateLiteral2["default"])(["\n margin-left: ", ";\n font-family: ", ";\n font-size: ", ";\n font-style: ", ";\n font-weight: ", ";\n line-height: ", ";\n ", "\n"])), function (props) {
123
127
  return props.theme.radioInputLabelMargin;
124
128
  }, function (props) {
125
129
  return props.theme.fontFamily;
@@ -132,7 +136,19 @@ var Label = _styledComponents["default"].span(_templateObject6 || (_templateObje
132
136
  }, function (props) {
133
137
  return props.theme.radioInputLabelLineHeight;
134
138
  }, function (props) {
135
- return props.disabled && "color: ".concat(props.theme.disabledRadioInputLabelFontColor, "; pointer-events: none;");
139
+ return props.disabled ? "color: ".concat(props.theme.disabledRadioInputLabelFontColor, ";") : "color: ".concat(props.theme.radioInputLabelFontColor);
140
+ });
141
+
142
+ var RadioContainer = _styledComponents["default"].span(_templateObject6 || (_templateObject6 = (0, _taggedTemplateLiteral2["default"])(["\n display: inline-flex;\n align-items: center;\n cursor: ", ";\n\n &:hover {\n ", " {\n border-color: ", ";\n }\n ", " {\n background-color: ", ";\n }\n }\n &:active {\n ", " {\n border-color: ", ";\n }\n ", " {\n background-color: ", ";\n }\n }\n"])), function (props) {
143
+ return props.disabled ? "not-allowed" : props.readonly ? "default" : "pointer";
144
+ }, RadioInput, function (props) {
145
+ return !props.disabled && getRadioInputStateColor(props, "hover");
146
+ }, Dot, function (props) {
147
+ return !props.disabled && getRadioInputStateColor(props, "hover");
148
+ }, RadioInput, function (props) {
149
+ return !props.disabled && getRadioInputStateColor(props, "active");
150
+ }, Dot, function (props) {
151
+ return !props.disabled && getRadioInputStateColor(props, "active");
136
152
  });
137
153
 
138
154
  var _default = /*#__PURE__*/_react["default"].memo(DxcRadio);