@zohodesk/components 1.0.0-temp-190.2 → 1.0.0-temp-191

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 (248) hide show
  1. package/.cli/PropLessFiles.html +1 -1
  2. package/.cli/propValidation_report.html +1 -1
  3. package/README.md +12 -5
  4. package/assets/Appearance/dark/mode/Component_DarkMode.module.css +2 -29
  5. package/assets/Appearance/light/mode/Component_LightMode.module.css +2 -29
  6. package/assets/Appearance/pureDark/mode/Component_PureDarkMode.module.css +2 -29
  7. package/es/AppContainer/AppContainer.js +10 -9
  8. package/es/AppContainer/AppContainer.module.css +2 -2
  9. package/es/Avatar/Avatar.js +4 -5
  10. package/es/Avatar/Avatar.module.css +22 -52
  11. package/es/AvatarTeam/AvatarTeam.js +7 -7
  12. package/es/AvatarTeam/AvatarTeam.module.css +74 -66
  13. package/es/Button/Button.js +5 -6
  14. package/es/Button/css/Button.module.css +100 -162
  15. package/es/Buttongroup/Buttongroup.module.css +17 -52
  16. package/es/CheckBox/CheckBox.js +18 -8
  17. package/es/CheckBox/CheckBox.module.css +60 -37
  18. package/es/CheckBox/props/propTypes.js +1 -0
  19. package/es/DateTime/DateTime.module.css +57 -86
  20. package/es/DateTime/DateWidget.module.css +7 -11
  21. package/es/DateTime/YearView.module.css +21 -34
  22. package/es/DropBox/DropBox.js +10 -11
  23. package/es/DropBox/DropBoxElement/css/DropBoxElement.module.css +79 -105
  24. package/es/DropBox/css/DropBox.module.css +6 -24
  25. package/es/DropDown/DropDown.js +2 -1
  26. package/es/DropDown/DropDown.module.css +2 -2
  27. package/es/DropDown/DropDownHeading.module.css +13 -19
  28. package/es/DropDown/DropDownItem.module.css +22 -43
  29. package/es/DropDown/DropDownSearch.module.css +3 -3
  30. package/es/DropDown/DropDownSeparator.module.css +2 -2
  31. package/es/Heading/Heading.module.css +2 -2
  32. package/es/Label/Label.module.css +23 -12
  33. package/es/Label/LabelColors.module.css +7 -1
  34. package/es/Layout/Layout.module.css +15 -15
  35. package/es/ListItem/ListContainer.js +6 -5
  36. package/es/ListItem/ListItem.js +4 -5
  37. package/es/ListItem/ListItem.module.css +87 -90
  38. package/es/ListItem/ListItemWithAvatar.js +4 -5
  39. package/es/ListItem/ListItemWithCheckBox.js +4 -5
  40. package/es/ListItem/ListItemWithIcon.js +4 -5
  41. package/es/ListItem/ListItemWithRadio.js +4 -5
  42. package/es/Modal/Modal.js +4 -5
  43. package/es/MultiSelect/AdvancedMultiSelect.js +8 -9
  44. package/es/MultiSelect/MobileHeader/MobileHeader.module.css +19 -16
  45. package/es/MultiSelect/MultiSelect.module.css +69 -55
  46. package/es/MultiSelect/MultiSelectWithAvatar.js +4 -5
  47. package/es/MultiSelect/SelectedOptions.js +6 -8
  48. package/es/MultiSelect/SelectedOptions.module.css +5 -11
  49. package/es/MultiSelect/Suggestions.js +6 -8
  50. package/es/PopOver/PopOver.module.css +4 -4
  51. package/es/Popup/Popup.js +3 -4
  52. package/es/Radio/Radio.js +25 -6
  53. package/es/Radio/Radio.module.css +40 -23
  54. package/es/Radio/__tests__/__snapshots__/Radio.spec.js.snap +3 -3
  55. package/es/Radio/props/defaultProps.js +1 -0
  56. package/es/Radio/props/propTypes.js +7 -0
  57. package/es/ResponsiveDropBox/ResponsiveDropBox.js +2 -4
  58. package/es/ResponsiveDropBox/ResponsiveDropBox.module.css +2 -2
  59. package/es/Ribbon/Ribbon.module.css +64 -147
  60. package/es/RippleEffect/RippleEffect.module.css +27 -9
  61. package/es/Select/Select.js +4 -5
  62. package/es/Select/Select.module.css +22 -33
  63. package/es/Stencils/Stencils.module.css +14 -32
  64. package/es/Switch/Switch.js +8 -8
  65. package/es/Switch/Switch.module.css +35 -32
  66. package/es/Tab/Tab.js +4 -5
  67. package/es/Tab/Tab.module.css +39 -28
  68. package/es/Tab/TabContentWrapper.js +4 -5
  69. package/es/Tab/TabWrapper.js +2 -4
  70. package/es/Tab/Tabs.js +16 -16
  71. package/es/Tab/Tabs.module.css +29 -51
  72. package/es/Tag/Tag.module.css +91 -66
  73. package/es/TextBox/TextBox.js +5 -5
  74. package/es/TextBox/TextBox.module.css +20 -36
  75. package/es/TextBoxIcon/TextBoxIcon.js +2 -4
  76. package/es/TextBoxIcon/TextBoxIcon.module.css +6 -18
  77. package/es/Textarea/Textarea.js +4 -6
  78. package/es/Textarea/Textarea.module.css +60 -36
  79. package/es/Tooltip/Tooltip.module.css +13 -12
  80. package/es/VelocityAnimation/VelocityAnimationGroup/VelocityAnimationGroup.js +4 -5
  81. package/es/common/animation.module.css +29 -227
  82. package/es/common/avatarsizes.module.css +16 -16
  83. package/es/common/basicReset.module.css +15 -5
  84. package/es/common/common.module.css +36 -82
  85. package/es/common/customscroll.module.css +32 -29
  86. package/es/common/transition.module.css +10 -50
  87. package/es/deprecated/PortalLayer/PortalLayer.js +8 -6
  88. package/es/semantic/Button/semanticButton.module.css +3 -3
  89. package/es/v1/Animation/Animation.js +1 -1
  90. package/es/v1/AppContainer/AppContainer.js +10 -9
  91. package/es/v1/Avatar/Avatar.js +4 -5
  92. package/es/v1/AvatarTeam/AvatarTeam.js +7 -7
  93. package/es/v1/Button/Button.js +5 -6
  94. package/es/v1/Card/Card.js +1 -1
  95. package/es/v1/CheckBox/CheckBox.js +15 -9
  96. package/es/v1/CheckBox/props/propTypes.js +1 -0
  97. package/es/v1/DropBox/DropBox.js +10 -11
  98. package/es/v1/DropBox/utils/isMobilePopover.js +1 -1
  99. package/es/v1/DropDown/DropDown.js +2 -1
  100. package/es/v1/ListItem/ListContainer.js +7 -6
  101. package/es/v1/ListItem/ListItem.js +4 -5
  102. package/es/v1/ListItem/ListItemWithAvatar.js +4 -5
  103. package/es/v1/ListItem/ListItemWithCheckBox.js +4 -5
  104. package/es/v1/ListItem/ListItemWithIcon.js +4 -5
  105. package/es/v1/ListItem/ListItemWithRadio.js +4 -5
  106. package/es/v1/Modal/Modal.js +4 -5
  107. package/es/v1/MultiSelect/AdvancedGroupMultiSelect.js +1 -1
  108. package/es/v1/MultiSelect/AdvancedMultiSelect.js +9 -10
  109. package/es/v1/MultiSelect/MultiSelectWithAvatar.js +5 -6
  110. package/es/v1/MultiSelect/SelectedOptions.js +6 -8
  111. package/es/v1/MultiSelect/Suggestions.js +6 -8
  112. package/es/v1/MultiSelect/props/defaultProps.js +1 -1
  113. package/es/v1/Popup/Popup.js +3 -4
  114. package/es/v1/Radio/Radio.js +21 -6
  115. package/es/v1/Radio/props/defaultProps.js +1 -0
  116. package/es/v1/Radio/props/propTypes.js +7 -0
  117. package/es/v1/ResponsiveDropBox/ResponsiveDropBox.js +3 -5
  118. package/es/v1/Select/GroupSelect.js +1 -1
  119. package/es/v1/Select/Select.js +5 -6
  120. package/es/v1/Select/SelectWithAvatar.js +5 -7
  121. package/es/v1/Select/SelectWithIcon.js +1 -1
  122. package/es/v1/Select/props/defaultProps.js +1 -1
  123. package/es/v1/Select/props/propTypes.js +1 -3
  124. package/es/v1/Switch/Switch.js +8 -8
  125. package/es/v1/Tab/Tab.js +4 -5
  126. package/es/v1/Tab/TabContentWrapper.js +4 -5
  127. package/es/v1/Tab/TabWrapper.js +2 -4
  128. package/es/v1/Tab/Tabs.js +18 -18
  129. package/es/v1/Tab/v1Tab.module.css +39 -28
  130. package/es/v1/Tab/v1Tabs.module.css +29 -51
  131. package/es/v1/TextBox/TextBox.js +5 -5
  132. package/es/v1/TextBoxIcon/TextBoxIcon.js +2 -4
  133. package/es/v1/Textarea/Textarea.js +4 -6
  134. package/es/v1/Tooltip/Tooltip.js +1 -1
  135. package/es/v1/Typography/css/Typography.module.css +33 -39
  136. package/es/v1/VelocityAnimation/VelocityAnimationGroup/VelocityAnimationGroup.js +4 -5
  137. package/lib/AppContainer/AppContainer.module.css +2 -2
  138. package/lib/Avatar/Avatar.module.css +22 -52
  139. package/lib/AvatarTeam/AvatarTeam.module.css +74 -66
  140. package/lib/Button/css/Button.module.css +100 -162
  141. package/lib/Buttongroup/Buttongroup.module.css +17 -52
  142. package/lib/CheckBox/CheckBox.js +34 -24
  143. package/lib/CheckBox/CheckBox.module.css +60 -37
  144. package/lib/CheckBox/props/propTypes.js +1 -0
  145. package/lib/DateTime/DateTime.module.css +57 -86
  146. package/lib/DateTime/DateWidget.module.css +7 -11
  147. package/lib/DateTime/YearView.module.css +21 -34
  148. package/lib/DropBox/DropBoxElement/css/DropBoxElement.module.css +79 -105
  149. package/lib/DropBox/css/DropBox.module.css +6 -24
  150. package/lib/DropDown/DropDown.module.css +2 -2
  151. package/lib/DropDown/DropDownHeading.module.css +13 -19
  152. package/lib/DropDown/DropDownItem.module.css +22 -43
  153. package/lib/DropDown/DropDownSearch.module.css +3 -3
  154. package/lib/DropDown/DropDownSeparator.module.css +2 -2
  155. package/lib/Heading/Heading.module.css +2 -2
  156. package/lib/Label/Label.module.css +23 -12
  157. package/lib/Label/LabelColors.module.css +7 -1
  158. package/lib/Layout/Layout.module.css +15 -15
  159. package/lib/ListItem/ListItem.module.css +87 -90
  160. package/lib/MultiSelect/MobileHeader/MobileHeader.module.css +19 -16
  161. package/lib/MultiSelect/MultiSelect.module.css +69 -55
  162. package/lib/MultiSelect/SelectedOptions.module.css +5 -11
  163. package/lib/PopOver/PopOver.module.css +4 -4
  164. package/lib/Radio/Radio.js +45 -26
  165. package/lib/Radio/Radio.module.css +40 -23
  166. package/lib/Radio/__tests__/__snapshots__/Radio.spec.js.snap +3 -3
  167. package/lib/Radio/props/defaultProps.js +1 -0
  168. package/lib/Radio/props/propTypes.js +7 -0
  169. package/lib/ResponsiveDropBox/ResponsiveDropBox.module.css +2 -2
  170. package/lib/Ribbon/Ribbon.module.css +64 -147
  171. package/lib/RippleEffect/RippleEffect.module.css +27 -9
  172. package/lib/Select/Select.module.css +22 -33
  173. package/lib/Stencils/Stencils.module.css +14 -32
  174. package/lib/Switch/Switch.module.css +35 -32
  175. package/lib/Tab/Tab.module.css +39 -28
  176. package/lib/Tab/Tabs.module.css +29 -51
  177. package/lib/Tag/Tag.module.css +91 -66
  178. package/lib/TextBox/TextBox.module.css +20 -36
  179. package/lib/TextBoxIcon/TextBoxIcon.module.css +6 -18
  180. package/lib/Textarea/Textarea.module.css +60 -36
  181. package/lib/Tooltip/Tooltip.module.css +13 -12
  182. package/lib/common/animation.module.css +29 -227
  183. package/lib/common/avatarsizes.module.css +16 -16
  184. package/lib/common/basicReset.module.css +15 -5
  185. package/lib/common/common.module.css +36 -82
  186. package/lib/common/customscroll.module.css +32 -29
  187. package/lib/common/transition.module.css +10 -50
  188. package/lib/semantic/Button/semanticButton.module.css +3 -3
  189. package/lib/v1/Animation/Animation.js +1 -1
  190. package/lib/v1/Card/Card.js +1 -1
  191. package/lib/v1/CheckBox/CheckBox.js +7 -1
  192. package/lib/v1/CheckBox/props/propTypes.js +1 -0
  193. package/lib/v1/DropBox/utils/isMobilePopover.js +1 -1
  194. package/lib/v1/ListItem/ListContainer.js +1 -1
  195. package/lib/v1/MultiSelect/AdvancedGroupMultiSelect.js +1 -1
  196. package/lib/v1/MultiSelect/AdvancedMultiSelect.js +1 -1
  197. package/lib/v1/MultiSelect/props/defaultProps.js +1 -1
  198. package/lib/v1/Radio/Radio.js +22 -7
  199. package/lib/v1/Radio/props/defaultProps.js +1 -0
  200. package/lib/v1/Radio/props/propTypes.js +7 -0
  201. package/lib/v1/ResponsiveDropBox/ResponsiveDropBox.js +1 -1
  202. package/lib/v1/Select/GroupSelect.js +1 -1
  203. package/lib/v1/Select/Select.js +1 -1
  204. package/lib/v1/Select/SelectWithAvatar.js +4 -6
  205. package/lib/v1/Select/SelectWithIcon.js +1 -1
  206. package/lib/v1/Select/props/defaultProps.js +1 -1
  207. package/lib/v1/Select/props/propTypes.js +1 -3
  208. package/lib/v1/Tab/Tabs.js +2 -2
  209. package/lib/v1/Tab/v1Tab.module.css +39 -28
  210. package/lib/v1/Tab/v1Tabs.module.css +29 -51
  211. package/lib/v1/Tooltip/Tooltip.js +1 -1
  212. package/lib/v1/Typography/css/Typography.module.css +33 -39
  213. package/package.json +10 -10
  214. package/es/v1/Provider/AvatarSize.js +0 -13
  215. package/es/v1/Provider/Config.js +0 -18
  216. package/es/v1/Provider/CssProvider.js +0 -16
  217. package/es/v1/Provider/IdProvider.js +0 -66
  218. package/es/v1/Provider/LibraryContext.js +0 -37
  219. package/es/v1/Provider/LibraryContextInit.js +0 -3
  220. package/es/v1/Provider/NumberGenerator/NumberGenerator.js +0 -136
  221. package/es/v1/Provider/ZindexProvider.js +0 -57
  222. package/es/v1/Provider/index.js +0 -4
  223. package/es/v1/Responsive/CustomResponsive.js +0 -195
  224. package/es/v1/Responsive/RefWrapper.js +0 -39
  225. package/es/v1/Responsive/ResizeComponent.js +0 -197
  226. package/es/v1/Responsive/ResizeObserver.js +0 -140
  227. package/es/v1/Responsive/Responsive.js +0 -194
  228. package/es/v1/Responsive/index.js +0 -9
  229. package/es/v1/Responsive/props/defaultProps.js +0 -13
  230. package/es/v1/Responsive/props/propTypes.js +0 -25
  231. package/lib/v1/Provider/AvatarSize.js +0 -24
  232. package/lib/v1/Provider/Config.js +0 -27
  233. package/lib/v1/Provider/CssProvider.js +0 -27
  234. package/lib/v1/Provider/IdProvider.js +0 -79
  235. package/lib/v1/Provider/LibraryContext.js +0 -76
  236. package/lib/v1/Provider/LibraryContextInit.js +0 -15
  237. package/lib/v1/Provider/NumberGenerator/NumberGenerator.js +0 -174
  238. package/lib/v1/Provider/ZindexProvider.js +0 -69
  239. package/lib/v1/Provider/index.js +0 -81
  240. package/lib/v1/Responsive/CustomResponsive.js +0 -242
  241. package/lib/v1/Responsive/RefWrapper.js +0 -57
  242. package/lib/v1/Responsive/ResizeComponent.js +0 -268
  243. package/lib/v1/Responsive/ResizeObserver.js +0 -168
  244. package/lib/v1/Responsive/Responsive.js +0 -274
  245. package/lib/v1/Responsive/index.js +0 -55
  246. package/lib/v1/Responsive/props/defaultProps.js +0 -23
  247. package/lib/v1/Responsive/props/propTypes.js +0 -39
  248. package/result.json +0 -1
@@ -3,29 +3,29 @@
3
3
  }
4
4
 
5
5
  .small {
6
- max-height: var(--zd_size200) ;
6
+ max-height: 200px;
7
7
  }
8
8
 
9
9
  .medium {
10
- max-height: var(--zd_size350) ;
10
+ max-height: 350px;
11
11
  }
12
12
 
13
13
  .large {
14
- max-height: var(--zd_size400) ;
14
+ max-height: 400px;
15
15
  }
16
16
 
17
17
  .emptyState {
18
- font-size: var(--zd_font_size14) ;
18
+ font-size: 14px;
19
19
  color: var(--zdt_select_emptystate_text);
20
20
  composes: semibold from '../common/common.module.css';
21
21
  }
22
22
 
23
23
  .box_small .emptyState {
24
- padding: var(--zd_size12) var(--zd_size6) ;
24
+ padding: 12px 6px;
25
25
  }
26
26
 
27
27
  .box_medium .emptyState {
28
- padding: var(--zd_size12) var(--zd_size15) ;
28
+ padding: 12px 15px;
29
29
  }
30
30
 
31
31
  .hide {
@@ -37,32 +37,32 @@
37
37
  }
38
38
  /* css:lineheight-validation:ignore */
39
39
  .arrowIcon {
40
- height: var(--zd_size8) ;
40
+ height: 8px;
41
41
  line-height: var(--zd_size8);
42
42
  }
43
43
 
44
44
  .small.search {
45
- padding: 0 var(--zd_size5) ;
45
+ padding: 0 5px;
46
46
  }
47
47
 
48
48
  .medium.search {
49
- padding: var(--zd_size3) var(--zd_size20) 0 ;
49
+ padding: 3px 20px 0;
50
50
  }
51
51
 
52
52
  .title {
53
- margin-bottom: var(--zd_size6) ;
53
+ margin-bottom: 6px;
54
54
  }
55
55
 
56
56
  .groupTitle {
57
- margin: var(--zd_size6) 0 ;
57
+ margin: 6px 0;
58
58
  }
59
59
 
60
60
  .listItemContainer {
61
- padding: var(--zd_size10) 0 ;
61
+ padding: 10px 0;
62
62
  }
63
63
 
64
64
  .responsivelistItemContainer {
65
- padding: var(--zd_size10) 0 0 ;
65
+ padding: 10px 0 0;
66
66
  }
67
67
 
68
68
  .readonly {
@@ -85,33 +85,22 @@
85
85
 
86
86
  .leftIcon {
87
87
  position: absolute;
88
- top: 0 ;
89
- bottom: 0 ;
90
- width: var(--zd_size30) ;
88
+ top: 0;
89
+ bottom: 0;
90
+ left: 0;
91
+ width: 30px;
91
92
  }
92
93
 
93
- [dir=ltr] .leftIcon {
94
- left: 0 ;
95
- }
96
-
97
- [dir=rtl] .leftIcon {
98
- right: 0 ;
99
- }
100
-
101
- [dir=ltr] .iconSelect {
102
- padding-left: var(--zd_size30) ;
103
- }
104
-
105
- [dir=rtl] .iconSelect {
106
- padding-right: var(--zd_size30) ;
94
+ .iconSelect {
95
+ padding-left: 30px;
107
96
  }
108
97
 
109
98
  .dropBoxList {
110
- padding: var(--zd_size10) 0 ;
99
+ padding: 10px 0;
111
100
  }
112
101
 
113
102
  .responsivedropBoxList {
114
- padding: var(--zd_size10) 0 0 0 ;
103
+ padding: 10px 0 0 0;
115
104
  }
116
105
 
117
106
  .rotate {
@@ -131,5 +120,5 @@
131
120
  }
132
121
 
133
122
  .loader {
134
- padding: var(--zd_size10) ;
123
+ padding: 10px;
135
124
  }
@@ -1,6 +1,6 @@
1
1
  .varClass {
2
2
  /* stencils default variables */
3
- --stencil_height: var(--zd_size9);
3
+ --stencil_height: 9px;
4
4
  --stencil_width: 100%;
5
5
  --stencil_border_radius: 5px;
6
6
  }
@@ -11,23 +11,14 @@
11
11
  border-radius: var(--stencil_border_radius);
12
12
  }
13
13
  .stencil {
14
- background-size: 800px 1px;
15
- }
16
- [dir=ltr] .stencil {
17
- animation-name: placeHolderShimmer-ltr ;
18
- animation-fill-mode: forwards;
19
- animation-iteration-count: infinite;
20
- animation-duration: var(--zd_transition10);
21
- animation-timing-function: linear;
22
- }
23
- [dir=rtl] .stencil {
24
- animation-name: placeHolderShimmer-rtl ;
14
+ animation-name: placeHolderShimmer;
25
15
  animation-fill-mode: forwards;
26
16
  animation-iteration-count: infinite;
27
17
  animation-duration: var(--zd_transition10);
28
18
  animation-timing-function: linear;
19
+ background-size: 800px 1px;
29
20
  }
30
- @keyframes placeHolderShimmer-ltr {
21
+ @keyframes placeHolderShimmer {
31
22
  0% {
32
23
  background-position: calc(var(--zd_size468) * -1) 0;
33
24
  }
@@ -36,19 +27,10 @@
36
27
  background-position: var(--zd_size468) 0;
37
28
  }
38
29
  }
39
- @keyframes placeHolderShimmer-rtl {
40
- 0% {
41
- background-position: calc(100% - (var(--zd_size468) * -1)) 0;
42
- }
43
-
44
- 100% {
45
- background-position: var(--zd_size468) 100%;
46
- }
47
- }
48
30
 
49
31
  .rectangular {
50
32
  composes: stencil;
51
- --stencil_height: var(--zd_size9);
33
+ --stencil_height: 9px;
52
34
  --stencil_border_radius: 5px;
53
35
  }
54
36
  .primary {
@@ -65,16 +47,16 @@
65
47
  }
66
48
 
67
49
  .small {
68
- --stencil_width: var(--zd_size110);
50
+ --stencil_width: 110px;
69
51
  }
70
52
  .default {
71
53
  --stencil_width: 100%;
72
54
  }
73
55
  .medium {
74
- --stencil_width: var(--zd_size170);
56
+ --stencil_width: 170px;
75
57
  }
76
58
  .large {
77
- --stencil_width: var(--zd_size220);
59
+ --stencil_width: 220px;
78
60
  }
79
61
 
80
62
  .circle {
@@ -82,15 +64,15 @@
82
64
  --stencil_border_radius: 50%;
83
65
  }
84
66
  .clarge {
85
- --stencil_width: var(--zd_size42);
86
- --stencil_height: var(--zd_size42);
67
+ --stencil_width: 42px;
68
+ --stencil_height: 42px;
87
69
  }
88
70
  .cmedium,
89
71
  .cdefault {
90
- --stencil_width: var(--zd_size30);
91
- --stencil_height: var(--zd_size30);
72
+ --stencil_width: 30px;
73
+ --stencil_height: 30px;
92
74
  }
93
75
  .csmall {
94
- --stencil_width: var(--zd_size20);
95
- --stencil_height: var(--zd_size20);
76
+ --stencil_width: 20px;
77
+ --stencil_height: 20px;
96
78
  }
@@ -1,5 +1,3 @@
1
- function _extends() { _extends = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
2
-
3
1
  import React from 'react';
4
2
  import { defaultProps } from './props/defaultProps';
5
3
  import { propTypes } from './props/propTypes';
@@ -50,7 +48,7 @@ export default class Switch extends React.Component {
50
48
  customLabel = ''
51
49
  } = customClass;
52
50
  size !== 'small' ? size = 'switch_medium' : size = 'switch_small';
53
- return /*#__PURE__*/React.createElement(Container, _extends({
51
+ return /*#__PURE__*/React.createElement(Container, {
54
52
  align: "vertical",
55
53
  isCover: false,
56
54
  alignBox: "row",
@@ -59,8 +57,9 @@ export default class Switch extends React.Component {
59
57
  "data-title": disabled ? disableTitle : title,
60
58
  "aria-checked": checked,
61
59
  role: "switch",
62
- dataSelectorId: dataSelectorId
63
- }, SwitchProps), /*#__PURE__*/React.createElement(Box, {
60
+ dataSelectorId: dataSelectorId,
61
+ ...SwitchProps
62
+ }, /*#__PURE__*/React.createElement(Box, {
64
63
  className: `${style[size]} ${customSwitchSize}`
65
64
  }, /*#__PURE__*/React.createElement("input", {
66
65
  type: "checkbox",
@@ -78,15 +77,16 @@ export default class Switch extends React.Component {
78
77
  "data-test-id": dataId,
79
78
  className: `${style.label} ${style[`${size}Label`]} ${customSwitch}`,
80
79
  tabIndex: isReadOnly || disabled ? '-1' : '0'
81
- })), text && /*#__PURE__*/React.createElement(Label, _extends({
80
+ })), text && /*#__PURE__*/React.createElement(Label, {
82
81
  text: text,
83
82
  palette: labelPalette,
84
83
  id: id,
85
84
  size: labelSize,
86
85
  type: "subtitle",
87
86
  onClick: !disabled || !isReadOnly ? this.onChange : null,
88
- customClass: customLabel
89
- }, LabelProps)));
87
+ customClass: customLabel,
88
+ ...LabelProps
89
+ }));
90
90
  }
91
91
 
92
92
  }
@@ -26,7 +26,6 @@
26
26
  display: inline-block;
27
27
  position: relative;
28
28
  transition: box-shadow var(--zd_transition3) ease-in-out;
29
- /* css:theme-validation:ignore */
30
29
  background-color: var(--switch_off_bg_color);
31
30
  border-radius: 20px;
32
31
  cursor: pointer;
@@ -38,14 +37,15 @@
38
37
  {
39
38
  --switch_off_bg_color: var(--zdt_switch_effect_off_bg);
40
39
  }
40
+
41
+ /*rtl:begin:ignore*/
41
42
  .label:after {
42
43
  content: '';
43
44
  display: block;
44
45
  position: absolute;
45
- right: 50% ;
46
+ right: 50%;
46
47
  transition: all var(--zd_transition2);
47
48
  box-shadow: var(--switch_cricle_box_shadow);
48
- /* css:theme-validation:ignore */
49
49
  background-color: var(--switch_circle_bg_color);
50
50
  border-radius: var(--switch_circle_border_radius);
51
51
  }
@@ -55,49 +55,59 @@
55
55
  }
56
56
 
57
57
  .checked+.label:after {
58
- right: calc( var(--zd_size1) * -1 ) ;
58
+ right: -1px;
59
59
  }
60
60
 
61
+ /*rtl:end:ignore*/
62
+
61
63
  .input {
62
64
  display: none;
63
65
  }
64
66
 
65
67
  .small {
66
- height: var(--zd_size14) ;
67
- width: var(--zd_size28) ;
68
+ height: 14px;
69
+ width: 28px;
68
70
  }
71
+
72
+ /*rtl:begin:ignore*/
69
73
  .switch_smallLabel {
70
- height: var(--zd_size9) ;
71
- width: var(--zd_size22) ;
72
- top: calc( var(--zd_size2) * -1 ) ;
73
- left: var(--zd_size2) ;
74
+ height: 9px;
75
+ width: 22px;
76
+ top: -2px;
77
+ left: 2px;
74
78
  }
79
+
80
+ /*rtl:end:ignore*/
75
81
  .switch_smallLabel:after {
76
- width: var(--zd_size12) ;
77
- height: var(--zd_size12) ;
78
- top: calc( var(--zd_size2) * -1 ) ;
82
+ width: 12px;
83
+ height: 12px;
84
+ top: -2px;
79
85
  }
80
86
 
81
87
  .medium {
82
- height: var(--zd_size18) ;
83
- width: var(--zd_size34) ;
88
+ height: 18px;
89
+ width: 34px;
84
90
  }
91
+
92
+ /*rtl:begin:ignore*/
85
93
  .switch_mediumLabel {
86
- height: var(--zd_size13) ;
87
- width: var(--zd_size31) ;
88
- top: var(--zd_size2) ;
89
- left: var(--zd_size2) ;
94
+ height: 13px;
95
+ width: 31px;
96
+ top: 2px;
97
+ left: 2px;
90
98
  }
99
+
100
+ /*rtl:end:ignore*/
91
101
  .switch_mediumLabel:after {
92
- width: var(--zd_size18) ;
93
- height: var(--zd_size18) ;
94
- top: calc( var(--zd_size3) * -1 ) ;
102
+ width: 18px;
103
+ height: 18px;
104
+ top: -3px;
95
105
  }
96
106
 
97
107
  .input:disabled+.label {
98
- opacity: 0.4;
99
108
  border-color: var(--zdt_switch_default_off_bg);
100
109
  cursor: not-allowed;
110
+ opacity: 0.4;
101
111
  }
102
112
 
103
113
  .switch {
@@ -118,13 +128,6 @@
118
128
 
119
129
  .switch+label {
120
130
  position: relative;
121
- top: calc( var(--zd_size1) * -1 ) ;
122
- }
123
-
124
- [dir=ltr] .switch+label {
125
- margin-left: var(--zd_size12) ;
126
- }
127
-
128
- [dir=rtl] .switch+label {
129
- margin-right: var(--zd_size12) ;
131
+ top: -1px;
132
+ margin-left: 12px;
130
133
  }
package/es/Tab/Tab.js CHANGED
@@ -1,5 +1,3 @@
1
- function _extends() { _extends = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
2
-
3
1
  /* eslint-disable react/forbid-component-props */
4
2
 
5
3
  /* eslint css-modules/no-unused-class: [2, { markAsUsed: ['text', 'tabAlpha', 'alphaActive', 'gammaActive', 'betaActive', 'deltaActive', 'tabGamma', 'tabBeta', 'tabDelta',', 'specialActive', 'tabSpecial', 'alphaActive_border', 'gammaActive_border', 'betaActive_border', 'deltaActive_border'] }] */
@@ -70,7 +68,7 @@ export default function Tab(_ref) {
70
68
  let activeClasses = cs([needAppearance && activeWithAppearance, activeClass]);
71
69
  let inActiveClasses = needAppearance && cs([styles[styleContent.tab], tabTypes[type] && styles[`${`${type}Hover`}`]]);
72
70
  let tabClass = cs([styles.tab, align === 'vertical' ? styles.vertical : styles.horizontal, isDisabled && styles.disabled, needBorder && !isAnimate && needAppearance && styles.border, isActive ? activeClasses : inActiveClasses, className]);
73
- return /*#__PURE__*/React.createElement(Box, _extends({
71
+ return /*#__PURE__*/React.createElement(Box, {
74
72
  tourId: tourId,
75
73
  tagName: isLink ? 'a' : 'div',
76
74
  className: tabClass,
@@ -88,8 +86,9 @@ export default function Tab(_ref) {
88
86
  "aria-selected": isActive ? true : false,
89
87
  tabIndex: isLink ? undefined : isActive && !isDisabled ? '0' : '0',
90
88
  "aria-label": text ? text : null,
91
- dataSelectorId: dataSelectorId
92
- }, customProps), /*#__PURE__*/React.createElement(Container, {
89
+ dataSelectorId: dataSelectorId,
90
+ ...customProps
91
+ }, /*#__PURE__*/React.createElement(Container, {
93
92
  alignBox: "row",
94
93
  align: "both",
95
94
  className: styles.textContainer
@@ -1,26 +1,32 @@
1
1
  .tab {
2
2
  text-transform: uppercase;
3
+ cursor: pointer;
3
4
  letter-spacing: 0.6px;
4
5
  text-decoration: none;
5
- cursor: pointer;
6
6
  }
7
+
7
8
  .vertical {
8
- height: 100% ;
9
+ height: 100%;
9
10
  }
11
+
10
12
  .horizontal {
11
- width: 100% ;
12
- max-width: 100% ;
13
+ width: 100%;
14
+ max-width: 100%;
13
15
  }
16
+
14
17
  .textContainer,
15
18
  .tabText {
16
- max-width: inherit ;
19
+ max-width: inherit;
17
20
  }
21
+
18
22
  .tabText {
19
23
  composes: dotted from '../common/common.module.css';
20
24
  }
25
+
21
26
  .disabled {
22
27
  cursor: not-allowed;
23
28
  }
29
+
24
30
  .border {
25
31
  border-bottom: 1px solid var(--zdt_tab_default_border);
26
32
  }
@@ -30,71 +36,76 @@
30
36
  .delta {
31
37
  transition: all var(--zd_transition2);
32
38
  }
39
+
33
40
  .alpha {
34
- font-size: var(--zd_font_size11) ;
41
+ padding: 0 18px;
42
+ font-size: 11px;
35
43
  line-height: 3;
36
- padding: 0 var(--zd_size18) ;
37
44
  }
45
+
38
46
  .tabAlpha {
39
47
  composes: alpha;
40
48
  color: var(--zdt_tab_alpha_text);
41
49
  }
50
+
42
51
  .alphaHover:hover {
43
- color: var(--zdt_tab_alpha_hover_text);
52
+ color: var(--zdt_base_color);
44
53
  background-color: var(--zdt_tab_alpha_hover_bg);
45
54
  }
55
+
46
56
  .alphaActive {
47
57
  composes: alpha;
48
58
  color: var(--zdt_tab_alpha_active_text);
49
59
  }
50
- .alphaActive_border, .betaActive_border {
60
+
61
+ .alphaActive_border,
62
+ .betaActive_border {
51
63
  border-color: var(--zdt_tab_alpha_active_border);
52
64
  }
65
+
53
66
  .deltaActive_border {
54
67
  border-color: var(--zdt_tab_delta_active_border);
55
68
  }
69
+
56
70
  .beta {
57
- font-size: var(--zd_font_size14) ;
71
+ padding: 0 4px;
72
+ font-size: 14px;
58
73
  line-height: 4.2857;
74
+ margin-right: 40px;
59
75
  text-transform: capitalize;
60
- padding: 0 var(--zd_size4) ;
61
- }
62
- [dir=ltr] .beta {
63
- margin-right: var(--zd_size40) ;
64
- }
65
- [dir=rtl] .beta {
66
- margin-left: var(--zd_size40) ;
67
76
  }
77
+
68
78
  .tabBeta {
69
79
  composes: beta;
70
80
  color: var(--zdt_tab_alpha_text);
71
81
  }
82
+
72
83
  .betaHover:hover {
73
- color: var(--zdt_tab_alpha_hover_text);
84
+ color: var(--zdt_base_color);
74
85
  }
86
+
75
87
  .betaActive {
76
88
  composes: beta;
77
- color: var(--zdt_tab_alpha_hover_text);
89
+ color: var(--zdt_base_color);
78
90
  }
91
+
79
92
  .delta {
80
- font-size: var(--zd_font_size11) ;
93
+ padding: 0 4px;
94
+ font-size: 11px;
81
95
  line-height: 3;
82
- padding: 0 var(--zd_size4) ;
83
- }
84
- [dir=ltr] .delta {
85
- margin-right: var(--zd_size10) ;
86
- }
87
- [dir=rtl] .delta {
88
- margin-left: var(--zd_size10) ;
96
+ margin-right: 10px;
89
97
  }
98
+
90
99
  .tabDelta {
91
100
  composes: delta;
92
101
  color: var(--zdt_tab_alpha_text);
93
102
  }
103
+
94
104
  .deltaHover:hover {
95
105
  color: var(--zdt_tab_alpha_active_text);
96
106
  }
107
+
97
108
  .deltaActive {
98
109
  composes: delta;
99
110
  color: var(--zdt_tab_alpha_active_text);
100
- }
111
+ }
@@ -1,5 +1,3 @@
1
- function _extends() { _extends = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
2
-
3
1
  import React from 'react';
4
2
  import { TabContentWrapper_defaultProps } from './props/defaultProps';
5
3
  import { TabContentWrapper_propTypes } from './props/propTypes';
@@ -18,15 +16,16 @@ const TabContentWrapper = _ref => {
18
16
  tagName,
19
17
  a11y
20
18
  } = _ref;
21
- return /*#__PURE__*/React.createElement(Box, _extends({
19
+ return /*#__PURE__*/React.createElement(Box, {
22
20
  flexible: true,
23
21
  style: style,
24
22
  dataId: dataId,
25
23
  className: className,
26
24
  onScroll: onScroll,
27
25
  dataSelectorId: dataSelectorId,
28
- tagName: tagName
29
- }, a11y), React.Children.map(children, child => /*#__PURE__*/React.isValidElement(child) && child.props.id === selectedTab ? child : null));
26
+ tagName: tagName,
27
+ ...a11y
28
+ }, React.Children.map(children, child => /*#__PURE__*/React.isValidElement(child) && child.props.id === selectedTab ? child : null));
30
29
  };
31
30
 
32
31
  TabContentWrapper.defaultProps = TabContentWrapper_defaultProps;
@@ -1,5 +1,3 @@
1
- function _extends() { _extends = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
2
-
3
1
  import React, { useState, useCallback } from 'react';
4
2
  import { TabWrapper_defaultProps } from './props/defaultProps';
5
3
  import { TabWrapper_propTypes } from './props/propTypes';
@@ -37,7 +35,7 @@ function TabWrapper(_ref) {
37
35
  let TabsChild = child.type;
38
36
  let selectedTab = hookToDisableInternalState ? defaultTab : selectedTabInternal;
39
37
  return /*#__PURE__*/React.createElement(TabsChild // eslint-disable-next-line react/no-array-index-key
40
- , _extends({}, child.props, {
38
+ , { ...child.props,
41
39
  selectedTab: selectedTab,
42
40
  onSelect: setSelectedTab,
43
41
  type: type,
@@ -48,7 +46,7 @@ function TabWrapper(_ref) {
48
46
  needAppearance: needAppearance,
49
47
  hookToDisableInternalState: hookToDisableInternalState,
50
48
  align: align
51
- }));
49
+ });
52
50
  }));
53
51
  }
54
52
 
package/es/Tab/Tabs.js CHANGED
@@ -1,5 +1,3 @@
1
- function _extends() { _extends = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
2
-
3
1
  /* eslint-disable react/forbid-component-props */
4
2
 
5
3
  /* eslint css-modules/no-unused-class: [2, {
@@ -459,7 +457,7 @@ class Tabs extends React.Component {
459
457
  classProps.className = itemClass;
460
458
  }
461
459
 
462
- return /*#__PURE__*/React.isValidElement(child) && /*#__PURE__*/React.createElement(MainTab, _extends({}, child.props, {
460
+ return /*#__PURE__*/React.isValidElement(child) && /*#__PURE__*/React.createElement(MainTab, { ...child.props,
463
461
  key: child.props.id,
464
462
  getTabRef: this.getTabRef,
465
463
  onSelect: onSelect,
@@ -470,22 +468,23 @@ class Tabs extends React.Component {
470
468
  needBorder: needTabBorder,
471
469
  needAppearance: needAppearance,
472
470
  align: align,
473
- isVirtual: isVirtual
474
- }, classProps));
471
+ isVirtual: isVirtual,
472
+ ...classProps
473
+ });
475
474
  }), React.Children.count(moreTabs) ? /*#__PURE__*/React.createElement(Box, {
476
475
  className: `${tabsStyle.menu} `,
477
476
  dataSelectorId: `${dataSelectorId}_moreIcon`
478
- }, /*#__PURE__*/React.createElement(Container, _extends({
477
+ }, /*#__PURE__*/React.createElement(Container, {
479
478
  className: `${btnstyle.buttonReset} ${moreButtonClass} ${isPopupOpen ? moreButtonActiveClass : ''}`,
480
479
  align: "both",
481
480
  onClick: this.togglePopup,
482
481
  dataId: "moreTabs",
483
- eleRef: getTargetRef
484
- }, MoreButtonProps, {
482
+ eleRef: getTargetRef,
483
+ ...MoreButtonProps,
485
484
  "aria-label": "MoreTabs",
486
485
  role: "link",
487
486
  tagName: "button"
488
- }), /*#__PURE__*/React.createElement(Icon, {
487
+ }, /*#__PURE__*/React.createElement(Icon, {
489
488
  name: iconName,
490
489
  size: iconSize
491
490
  })), isPopupOpen && /*#__PURE__*/React.createElement(ResponsiveReceiver, {
@@ -495,7 +494,7 @@ class Tabs extends React.Component {
495
494
  let {
496
495
  tabletMode
497
496
  } = _ref2;
498
- return /*#__PURE__*/React.createElement(ResponsiveDropBox, _extends({
497
+ return /*#__PURE__*/React.createElement(ResponsiveDropBox, {
499
498
  isActive: isPopupReady,
500
499
  isAnimate: true,
501
500
  size: "medium",
@@ -505,12 +504,12 @@ class Tabs extends React.Component {
505
504
  boxPosition: position,
506
505
  getRef: getContainerRef,
507
506
  isBoxPaddingNeed: true,
508
- isArrow: false
509
- }, DropBoxProps, {
507
+ isArrow: false,
508
+ ...DropBoxProps,
510
509
  isResponsivePadding: true,
511
510
  needFocusScope: true,
512
511
  onClose: this.togglePopup
513
- }), getCustomDropBoxHeaderPlaceHolder && getCustomDropBoxHeaderPlaceHolder(this.props), /*#__PURE__*/React.createElement(Box, {
512
+ }, getCustomDropBoxHeaderPlaceHolder && getCustomDropBoxHeaderPlaceHolder(this.props), /*#__PURE__*/React.createElement(Box, {
514
513
  flexible: true,
515
514
  shrink: true,
516
515
  scroll: "vertical",
@@ -531,7 +530,7 @@ class Tabs extends React.Component {
531
530
  dataId
532
531
  } = child.props;
533
532
  const value = text ? text : showTitleInMoreOptions ? title : null;
534
- return /*#__PURE__*/React.isValidElement(child) && /*#__PURE__*/React.createElement(ListItem, _extends({
533
+ return /*#__PURE__*/React.isValidElement(child) && /*#__PURE__*/React.createElement(ListItem, {
535
534
  key: id,
536
535
  value: value,
537
536
  onClick: this.moreTabSelect,
@@ -544,8 +543,9 @@ class Tabs extends React.Component {
544
543
  customListItem: menuItemClass
545
544
  },
546
545
  target: "self",
547
- dataId: `${dataId}_Tab`
548
- }, ListItemProps), !showTitleInMoreOptions ? children : null);
546
+ dataId: `${dataId}_Tab`,
547
+ ...ListItemProps
548
+ }, !showTitleInMoreOptions ? children : null);
549
549
  })));
550
550
  })) : null);
551
551
  }