@zohodesk/components 1.0.0-temp-252.4 → 1.0.0-temp-256
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.
- package/README.md +20 -3
- package/assets/Appearance/dark/mode/Component_DarkMode.module.css +4 -4
- package/assets/Appearance/dark/themes/blue/blue_componentsCTA_DarkModifyCategory.module.css +14 -0
- package/assets/Appearance/dark/themes/green/green_componentsCTA_DarkModifyCategory.module.css +14 -0
- package/assets/Appearance/dark/themes/orange/orange_componentsCTA_DarkModifyCategory.module.css +14 -0
- package/assets/Appearance/dark/themes/red/red_componentsCTA_DarkModifyCategory.module.css +14 -0
- package/assets/Appearance/dark/themes/yellow/yellow_componentsCTA_DarkModifyCategory.module.css +14 -0
- package/assets/Appearance/light/mode/Component_LightMode.module.css +6 -6
- package/assets/Appearance/light/themes/blue/blue_componentsCTA_LightModifyCategory.module.css +14 -0
- package/assets/Appearance/light/themes/green/green_componentsCTA_LightModifyCategory.module.css +14 -0
- package/assets/Appearance/light/themes/orange/orange_componentsCTA_LightModifyCategory.module.css +14 -0
- package/assets/Appearance/light/themes/red/red_componentsCTA_LightModifyCategory.module.css +14 -0
- package/assets/Appearance/light/themes/yellow/yellow_componentsCTA_LightModifyCategory.module.css +14 -0
- package/assets/Appearance/pureDark/mode/Component_PureDarkMode.module.css +3 -3
- package/assets/Appearance/pureDark/themes/blue/blue_componentsCTA_PureDarkModifyCategory.module.css +14 -0
- package/assets/Appearance/pureDark/themes/green/green_componentsCTA_PureDarkModifyCategory.module.css +14 -0
- package/assets/Appearance/pureDark/themes/orange/orange_componentsCTA_PureDarkModifyCategory.module.css +14 -0
- package/assets/Appearance/pureDark/themes/red/red_componentsCTA_PureDarkModifyCategory.module.css +14 -0
- package/assets/Appearance/pureDark/themes/yellow/yellow_componentsCTA_PureDarkModifyCategory.module.css +14 -0
- package/cbt.config.js +12 -3
- package/es/Avatar/Avatar.js +1 -2
- package/es/Button/css/cssJSLogic.js +4 -5
- package/es/DateTime/DateTime.js +3 -6
- package/es/DateTime/DateWidget.js +34 -11
- package/es/DateTime/YearView.js +5 -6
- package/es/DateTime/common.js +2 -9
- package/es/DateTime/dateFormatUtils/dateFormat.js +55 -76
- package/es/DateTime/dateFormatUtils/index.js +7 -12
- package/es/DateTime/dateFormatUtils/timeChange.js +3 -4
- package/es/DateTime/dateFormatUtils/yearChange.js +3 -4
- package/es/DropBox/DropBoxElement/css/cssJSLogic.js +5 -6
- package/es/Layout/utils.js +1 -2
- package/es/ListItem/ListContainer.js +4 -5
- package/es/Modal/Portal/Portal.js +4 -5
- package/es/MultiSelect/AdvancedGroupMultiSelect.js +91 -103
- package/es/MultiSelect/AdvancedMultiSelect.js +74 -80
- package/es/MultiSelect/MultiSelect.js +4 -13
- package/es/MultiSelect/Suggestions.js +14 -17
- package/es/Popup/Popup.js +1 -4
- package/es/Provider/IdProvider.js +4 -5
- package/es/Provider/LibraryContext.js +15 -12
- package/es/Provider/NumberGenerator/NumberGenerator.js +15 -17
- package/es/Provider/ZindexProvider.js +4 -5
- package/es/Responsive/CustomResponsive.js +8 -11
- package/es/Responsive/ResizeComponent.js +1 -3
- package/es/Responsive/Responsive.js +9 -12
- package/es/Responsive/sizeObservers.js +1 -5
- package/es/ResponsiveDropBox/ResponsiveDropBox.js +10 -14
- package/es/Select/GroupSelect.js +98 -103
- package/es/Select/Select.js +110 -116
- package/es/Select/SelectWithAvatar.js +91 -95
- package/es/Select/SelectWithIcon.js +104 -109
- package/es/Select/__tests__/Select.spec.js +6 -9
- package/es/Tab/Tab.js +90 -40
- package/es/Tab/Tab.module.css +25 -0
- package/es/Tab/TabContent.js +16 -19
- package/es/Tab/TabContentWrapper.js +19 -22
- package/es/Tab/TabWrapper.js +15 -16
- package/es/Tab/Tabs.js +105 -81
- package/es/Tab/Tabs.module.css +48 -3
- package/es/Tab/__tests__/Tab.spec.js +112 -0
- package/es/Tab/__tests__/__snapshots__/Tab.spec.js.snap +316 -0
- package/es/Tab/props/defaultProps.js +3 -2
- package/es/Tab/props/propTypes.js +12 -3
- package/es/Tab/utils/tabConfigs.js +5 -0
- package/es/Typography/css/cssJSLogic.js +4 -5
- package/es/VelocityAnimation/VelocityAnimationGroup/VelocityAnimationGroup.js +1 -2
- package/es/utils/Common.js +10 -31
- package/es/utils/datetime/common.js +12 -9
- package/es/utils/dropDownUtils.js +7 -11
- package/es/utils/getInitial.js +1 -3
- package/es/v1/Button/css/cssJSLogic.js +4 -8
- package/es/v1/Label/css/cssJSLogic.js +4 -5
- package/es/v1/Switch/css/cssJSLogic.js +4 -5
- package/es/v1/helpers/colorHelpers/colorHelper.js +28 -39
- package/lib/DateTime/DateWidget.js +33 -6
- package/lib/Provider/LibraryContext.js +5 -1
- package/lib/Tab/Tab.js +62 -9
- package/lib/Tab/Tab.module.css +25 -0
- package/lib/Tab/Tabs.js +34 -3
- package/lib/Tab/Tabs.module.css +48 -3
- package/lib/Tab/__tests__/Tab.spec.js +115 -0
- package/lib/Tab/__tests__/__snapshots__/Tab.spec.js.snap +316 -0
- package/lib/Tab/props/defaultProps.js +3 -2
- package/lib/Tab/props/propTypes.js +14 -3
- package/lib/Tab/utils/tabConfigs.js +7 -1
- package/lib/utils/datetime/common.js +10 -2
- package/package.json +12 -11
|
@@ -1,5 +1,152 @@
|
|
|
1
1
|
// Jest Snapshot v1, https://goo.gl/fbAQLP
|
|
2
2
|
|
|
3
|
+
exports[`Tab renderBefore / renderAfter slots renderAfter renders a node to the right of the label 1`] = `
|
|
4
|
+
<DocumentFragment>
|
|
5
|
+
<div
|
|
6
|
+
aria-controls="t7"
|
|
7
|
+
aria-label="Home"
|
|
8
|
+
aria-selected="false"
|
|
9
|
+
class="tab horizontal basisAuto shrinkOff"
|
|
10
|
+
data-id="tabMenu_Tab"
|
|
11
|
+
data-key="t7"
|
|
12
|
+
data-selector-id="tab"
|
|
13
|
+
data-test-id="tabMenu_Tab"
|
|
14
|
+
role="link"
|
|
15
|
+
tabindex="0"
|
|
16
|
+
>
|
|
17
|
+
<div
|
|
18
|
+
class="textContainer flex cover rowdir both"
|
|
19
|
+
data-id="containerComponent"
|
|
20
|
+
data-selector-id="container"
|
|
21
|
+
data-test-id="containerComponent"
|
|
22
|
+
>
|
|
23
|
+
<div
|
|
24
|
+
class="tabText grow basisAuto shrinkOff"
|
|
25
|
+
data-id="boxComponent"
|
|
26
|
+
data-selector-id="box"
|
|
27
|
+
data-test-id="boxComponent"
|
|
28
|
+
>
|
|
29
|
+
Home
|
|
30
|
+
</div>
|
|
31
|
+
<span>
|
|
32
|
+
3
|
|
33
|
+
</span>
|
|
34
|
+
</div>
|
|
35
|
+
</div>
|
|
36
|
+
</DocumentFragment>
|
|
37
|
+
`;
|
|
38
|
+
|
|
39
|
+
exports[`Tab renderBefore / renderAfter slots renderBefore and renderAfter both render around the label 1`] = `
|
|
40
|
+
<DocumentFragment>
|
|
41
|
+
<div
|
|
42
|
+
aria-controls="t8"
|
|
43
|
+
aria-label="Home"
|
|
44
|
+
aria-selected="false"
|
|
45
|
+
class="tab horizontal basisAuto shrinkOff"
|
|
46
|
+
data-id="tabMenu_Tab"
|
|
47
|
+
data-key="t8"
|
|
48
|
+
data-selector-id="tab"
|
|
49
|
+
data-test-id="tabMenu_Tab"
|
|
50
|
+
role="link"
|
|
51
|
+
tabindex="0"
|
|
52
|
+
>
|
|
53
|
+
<div
|
|
54
|
+
class="textContainer flex cover rowdir both"
|
|
55
|
+
data-id="containerComponent"
|
|
56
|
+
data-selector-id="container"
|
|
57
|
+
data-test-id="containerComponent"
|
|
58
|
+
>
|
|
59
|
+
<span>
|
|
60
|
+
◀
|
|
61
|
+
</span>
|
|
62
|
+
<div
|
|
63
|
+
class="tabText grow basisAuto shrinkOff"
|
|
64
|
+
data-id="boxComponent"
|
|
65
|
+
data-selector-id="box"
|
|
66
|
+
data-test-id="boxComponent"
|
|
67
|
+
>
|
|
68
|
+
Home
|
|
69
|
+
</div>
|
|
70
|
+
<span>
|
|
71
|
+
▶
|
|
72
|
+
</span>
|
|
73
|
+
</div>
|
|
74
|
+
</div>
|
|
75
|
+
</DocumentFragment>
|
|
76
|
+
`;
|
|
77
|
+
|
|
78
|
+
exports[`Tab renderBefore / renderAfter slots renderBefore as function renders custom node 1`] = `
|
|
79
|
+
<DocumentFragment>
|
|
80
|
+
<div
|
|
81
|
+
aria-controls="t9"
|
|
82
|
+
aria-label="Home"
|
|
83
|
+
aria-selected="false"
|
|
84
|
+
class="tab horizontal basisAuto shrinkOff"
|
|
85
|
+
data-id="tabMenu_Tab"
|
|
86
|
+
data-key="t9"
|
|
87
|
+
data-selector-id="tab"
|
|
88
|
+
data-test-id="tabMenu_Tab"
|
|
89
|
+
role="link"
|
|
90
|
+
tabindex="0"
|
|
91
|
+
>
|
|
92
|
+
<div
|
|
93
|
+
class="textContainer flex cover rowdir both"
|
|
94
|
+
data-id="containerComponent"
|
|
95
|
+
data-selector-id="container"
|
|
96
|
+
data-test-id="containerComponent"
|
|
97
|
+
>
|
|
98
|
+
<span>
|
|
99
|
+
◀
|
|
100
|
+
</span>
|
|
101
|
+
<div
|
|
102
|
+
class="tabText grow basisAuto shrinkOff"
|
|
103
|
+
data-id="boxComponent"
|
|
104
|
+
data-selector-id="box"
|
|
105
|
+
data-test-id="boxComponent"
|
|
106
|
+
>
|
|
107
|
+
Home
|
|
108
|
+
</div>
|
|
109
|
+
</div>
|
|
110
|
+
</div>
|
|
111
|
+
</DocumentFragment>
|
|
112
|
+
`;
|
|
113
|
+
|
|
114
|
+
exports[`Tab renderBefore / renderAfter slots renderBefore renders a node to the left of the label 1`] = `
|
|
115
|
+
<DocumentFragment>
|
|
116
|
+
<div
|
|
117
|
+
aria-controls="t6"
|
|
118
|
+
aria-label="Home"
|
|
119
|
+
aria-selected="false"
|
|
120
|
+
class="tab horizontal basisAuto shrinkOff"
|
|
121
|
+
data-id="tabMenu_Tab"
|
|
122
|
+
data-key="t6"
|
|
123
|
+
data-selector-id="tab"
|
|
124
|
+
data-test-id="tabMenu_Tab"
|
|
125
|
+
role="link"
|
|
126
|
+
tabindex="0"
|
|
127
|
+
>
|
|
128
|
+
<div
|
|
129
|
+
class="textContainer flex cover rowdir both"
|
|
130
|
+
data-id="containerComponent"
|
|
131
|
+
data-selector-id="container"
|
|
132
|
+
data-test-id="containerComponent"
|
|
133
|
+
>
|
|
134
|
+
<span>
|
|
135
|
+
◀
|
|
136
|
+
</span>
|
|
137
|
+
<div
|
|
138
|
+
class="tabText grow basisAuto shrinkOff"
|
|
139
|
+
data-id="boxComponent"
|
|
140
|
+
data-selector-id="box"
|
|
141
|
+
data-test-id="boxComponent"
|
|
142
|
+
>
|
|
143
|
+
Home
|
|
144
|
+
</div>
|
|
145
|
+
</div>
|
|
146
|
+
</div>
|
|
147
|
+
</DocumentFragment>
|
|
148
|
+
`;
|
|
149
|
+
|
|
3
150
|
exports[`Tab rendering the defult props 1`] = `
|
|
4
151
|
<DocumentFragment>
|
|
5
152
|
<div
|
|
@@ -20,3 +167,172 @@ exports[`Tab rendering the defult props 1`] = `
|
|
|
20
167
|
</div>
|
|
21
168
|
</DocumentFragment>
|
|
22
169
|
`;
|
|
170
|
+
|
|
171
|
+
exports[`Tab variant-based label rendering renderIcon as function receives no args and renders custom node 1`] = `
|
|
172
|
+
<DocumentFragment>
|
|
173
|
+
<div
|
|
174
|
+
aria-controls="t5"
|
|
175
|
+
aria-label="Home"
|
|
176
|
+
aria-selected="false"
|
|
177
|
+
class="tab horizontal basisAuto shrinkOff"
|
|
178
|
+
data-id="tabMenu_Tab"
|
|
179
|
+
data-key="t5"
|
|
180
|
+
data-selector-id="tab"
|
|
181
|
+
data-test-id="tabMenu_Tab"
|
|
182
|
+
role="link"
|
|
183
|
+
tabindex="0"
|
|
184
|
+
>
|
|
185
|
+
<div
|
|
186
|
+
class="textContainer flex cover rowdir both"
|
|
187
|
+
data-id="containerComponent"
|
|
188
|
+
data-selector-id="container"
|
|
189
|
+
data-test-id="containerComponent"
|
|
190
|
+
>
|
|
191
|
+
<span>
|
|
192
|
+
★
|
|
193
|
+
</span>
|
|
194
|
+
</div>
|
|
195
|
+
</div>
|
|
196
|
+
</DocumentFragment>
|
|
197
|
+
`;
|
|
198
|
+
|
|
199
|
+
exports[`Tab variant-based label rendering renderIcon overrides iconName 1`] = `
|
|
200
|
+
<DocumentFragment>
|
|
201
|
+
<div
|
|
202
|
+
aria-controls="t4"
|
|
203
|
+
aria-label="Home"
|
|
204
|
+
aria-selected="false"
|
|
205
|
+
class="tab horizontal basisAuto shrinkOff"
|
|
206
|
+
data-id="tabMenu_Tab"
|
|
207
|
+
data-key="t4"
|
|
208
|
+
data-selector-id="tab"
|
|
209
|
+
data-test-id="tabMenu_Tab"
|
|
210
|
+
role="link"
|
|
211
|
+
tabindex="0"
|
|
212
|
+
>
|
|
213
|
+
<div
|
|
214
|
+
class="textContainer flex cover rowdir both"
|
|
215
|
+
data-id="containerComponent"
|
|
216
|
+
data-selector-id="container"
|
|
217
|
+
data-test-id="containerComponent"
|
|
218
|
+
>
|
|
219
|
+
<span>
|
|
220
|
+
★
|
|
221
|
+
</span>
|
|
222
|
+
<div
|
|
223
|
+
class="tabText grow basisAuto shrinkOff"
|
|
224
|
+
data-id="boxComponent"
|
|
225
|
+
data-selector-id="box"
|
|
226
|
+
data-test-id="boxComponent"
|
|
227
|
+
>
|
|
228
|
+
Home
|
|
229
|
+
</div>
|
|
230
|
+
</div>
|
|
231
|
+
</div>
|
|
232
|
+
</DocumentFragment>
|
|
233
|
+
`;
|
|
234
|
+
|
|
235
|
+
exports[`Tab variant-based label rendering variant="icon" renders icon and suppresses text label 1`] = `
|
|
236
|
+
<DocumentFragment>
|
|
237
|
+
<div
|
|
238
|
+
aria-controls="t2"
|
|
239
|
+
aria-label="Home"
|
|
240
|
+
aria-selected="false"
|
|
241
|
+
class="tab horizontal basisAuto shrinkOff"
|
|
242
|
+
data-id="tabMenu_Tab"
|
|
243
|
+
data-key="t2"
|
|
244
|
+
data-selector-id="tab"
|
|
245
|
+
data-test-id="tabMenu_Tab"
|
|
246
|
+
role="link"
|
|
247
|
+
tabindex="0"
|
|
248
|
+
>
|
|
249
|
+
<div
|
|
250
|
+
class="textContainer flex cover rowdir both"
|
|
251
|
+
data-id="containerComponent"
|
|
252
|
+
data-selector-id="container"
|
|
253
|
+
data-test-id="containerComponent"
|
|
254
|
+
>
|
|
255
|
+
<i
|
|
256
|
+
aria-hidden="true"
|
|
257
|
+
class="zd_font_icons basic icon-menu rtl "
|
|
258
|
+
data-id="fontIcon"
|
|
259
|
+
data-selector-id="fontIcon"
|
|
260
|
+
data-test-id="fontIcon"
|
|
261
|
+
/>
|
|
262
|
+
</div>
|
|
263
|
+
</div>
|
|
264
|
+
</DocumentFragment>
|
|
265
|
+
`;
|
|
266
|
+
|
|
267
|
+
exports[`Tab variant-based label rendering variant="iconWithText" renders icon followed by text 1`] = `
|
|
268
|
+
<DocumentFragment>
|
|
269
|
+
<div
|
|
270
|
+
aria-controls="t3"
|
|
271
|
+
aria-label="Home"
|
|
272
|
+
aria-selected="false"
|
|
273
|
+
class="tab horizontal basisAuto shrinkOff"
|
|
274
|
+
data-id="tabMenu_Tab"
|
|
275
|
+
data-key="t3"
|
|
276
|
+
data-selector-id="tab"
|
|
277
|
+
data-test-id="tabMenu_Tab"
|
|
278
|
+
role="link"
|
|
279
|
+
tabindex="0"
|
|
280
|
+
>
|
|
281
|
+
<div
|
|
282
|
+
class="textContainer flex cover rowdir both"
|
|
283
|
+
data-id="containerComponent"
|
|
284
|
+
data-selector-id="container"
|
|
285
|
+
data-test-id="containerComponent"
|
|
286
|
+
>
|
|
287
|
+
<i
|
|
288
|
+
aria-hidden="true"
|
|
289
|
+
class="zd_font_icons basic icon-menu rtl "
|
|
290
|
+
data-id="fontIcon"
|
|
291
|
+
data-selector-id="fontIcon"
|
|
292
|
+
data-test-id="fontIcon"
|
|
293
|
+
/>
|
|
294
|
+
<div
|
|
295
|
+
class="tabText grow basisAuto shrinkOff"
|
|
296
|
+
data-id="boxComponent"
|
|
297
|
+
data-selector-id="box"
|
|
298
|
+
data-test-id="boxComponent"
|
|
299
|
+
>
|
|
300
|
+
Home
|
|
301
|
+
</div>
|
|
302
|
+
</div>
|
|
303
|
+
</div>
|
|
304
|
+
</DocumentFragment>
|
|
305
|
+
`;
|
|
306
|
+
|
|
307
|
+
exports[`Tab variant-based label rendering variant="text" renders text only 1`] = `
|
|
308
|
+
<DocumentFragment>
|
|
309
|
+
<div
|
|
310
|
+
aria-controls="t1"
|
|
311
|
+
aria-label="Home"
|
|
312
|
+
aria-selected="false"
|
|
313
|
+
class="tab horizontal basisAuto shrinkOff"
|
|
314
|
+
data-id="tabMenu_Tab"
|
|
315
|
+
data-key="t1"
|
|
316
|
+
data-selector-id="tab"
|
|
317
|
+
data-test-id="tabMenu_Tab"
|
|
318
|
+
role="link"
|
|
319
|
+
tabindex="0"
|
|
320
|
+
>
|
|
321
|
+
<div
|
|
322
|
+
class="textContainer flex cover rowdir both"
|
|
323
|
+
data-id="containerComponent"
|
|
324
|
+
data-selector-id="container"
|
|
325
|
+
data-test-id="containerComponent"
|
|
326
|
+
>
|
|
327
|
+
<div
|
|
328
|
+
class="tabText grow basisAuto shrinkOff"
|
|
329
|
+
data-id="boxComponent"
|
|
330
|
+
data-selector-id="box"
|
|
331
|
+
data-test-id="boxComponent"
|
|
332
|
+
>
|
|
333
|
+
Home
|
|
334
|
+
</div>
|
|
335
|
+
</div>
|
|
336
|
+
</div>
|
|
337
|
+
</DocumentFragment>
|
|
338
|
+
`;
|
|
@@ -9,7 +9,8 @@ var Tab_defaultProps = {
|
|
|
9
9
|
contentAlign: 'both',
|
|
10
10
|
contentAlignBox: 'row',
|
|
11
11
|
customProps: {},
|
|
12
|
-
dataSelectorId: 'tab'
|
|
12
|
+
dataSelectorId: 'tab',
|
|
13
|
+
variant: 'text'
|
|
13
14
|
};
|
|
14
15
|
exports.Tab_defaultProps = Tab_defaultProps;
|
|
15
16
|
var TabContent_defaultProps = {
|
|
@@ -45,7 +46,7 @@ var Tabs_defaultProps = {
|
|
|
45
46
|
searchBoxSize: 'small',
|
|
46
47
|
searchErrorText: 'No results',
|
|
47
48
|
placeHolderText: 'Search',
|
|
48
|
-
isAbsolutePositioningNeeded:
|
|
49
|
+
isAbsolutePositioningNeeded: false,
|
|
49
50
|
isRestrictScroll: false,
|
|
50
51
|
moreContainerClass: ''
|
|
51
52
|
};
|
|
@@ -7,8 +7,12 @@ exports.Tabs_propTypes = exports.Tab_propTypes = exports.TabWrapper_propTypes =
|
|
|
7
7
|
|
|
8
8
|
var _propTypes = _interopRequireDefault(require("prop-types"));
|
|
9
9
|
|
|
10
|
+
var _tabConfigs = require("../utils/tabConfigs");
|
|
11
|
+
|
|
10
12
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
|
|
11
13
|
|
|
14
|
+
var renderSlotType = _propTypes["default"].oneOfType([_propTypes["default"].node, _propTypes["default"].func]);
|
|
15
|
+
|
|
12
16
|
var Tab_propTypes = {
|
|
13
17
|
activeClass: _propTypes["default"].string,
|
|
14
18
|
align: _propTypes["default"].oneOf(['vertical', 'horizontal']),
|
|
@@ -36,7 +40,14 @@ var Tab_propTypes = {
|
|
|
36
40
|
contentAlignBox: _propTypes["default"].oneOf(['row', 'column', 'row-reverse', 'column-reverse']),
|
|
37
41
|
customProps: _propTypes["default"].object,
|
|
38
42
|
isVirtual: _propTypes["default"].bool,
|
|
39
|
-
dataSelectorId: _propTypes["default"].string
|
|
43
|
+
dataSelectorId: _propTypes["default"].string,
|
|
44
|
+
variant: _propTypes["default"].oneOf(Object.values(_tabConfigs.VARIANT)),
|
|
45
|
+
iconPlacement: _propTypes["default"].string,
|
|
46
|
+
iconName: _propTypes["default"].string,
|
|
47
|
+
iconSize: _propTypes["default"].oneOfType([_propTypes["default"].string, _propTypes["default"].number]),
|
|
48
|
+
renderIcon: renderSlotType,
|
|
49
|
+
renderBefore: renderSlotType,
|
|
50
|
+
renderAfter: renderSlotType
|
|
40
51
|
};
|
|
41
52
|
exports.Tab_propTypes = Tab_propTypes;
|
|
42
53
|
var TabContent_propTypes = {
|
|
@@ -95,7 +106,7 @@ var Tabs_propTypes = {
|
|
|
95
106
|
showTitleInMoreOptions: _propTypes["default"].bool,
|
|
96
107
|
style: _propTypes["default"].object,
|
|
97
108
|
togglePopup: _propTypes["default"].func,
|
|
98
|
-
type: _propTypes["default"].oneOf(['alpha', 'beta', 'delta']),
|
|
109
|
+
type: _propTypes["default"].oneOf(['alpha', 'beta', 'delta', 'default']),
|
|
99
110
|
getTargetRef: _propTypes["default"].func,
|
|
100
111
|
containerClass: _propTypes["default"].string,
|
|
101
112
|
customProps: _propTypes["default"].shape({
|
|
@@ -128,7 +139,7 @@ var TabWrapper_propTypes = {
|
|
|
128
139
|
needPadding: _propTypes["default"].bool,
|
|
129
140
|
needTabBorder: _propTypes["default"].bool,
|
|
130
141
|
onSelect: _propTypes["default"].func,
|
|
131
|
-
type: _propTypes["default"].oneOf(['alpha', 'beta', 'delta']),
|
|
142
|
+
type: _propTypes["default"].oneOf(['alpha', 'beta', 'delta', 'default']),
|
|
132
143
|
dataSelectorId: _propTypes["default"].string
|
|
133
144
|
};
|
|
134
145
|
exports.TabWrapper_propTypes = TabWrapper_propTypes;
|
|
@@ -3,7 +3,13 @@
|
|
|
3
3
|
Object.defineProperty(exports, "__esModule", {
|
|
4
4
|
value: true
|
|
5
5
|
});
|
|
6
|
-
exports.TAB_POPUP_POSITION_MAPPING = exports.TAB_DIRECTION_MAPPING = exports.TAB_ALIGN_MAPPING = void 0;
|
|
6
|
+
exports.VARIANT = exports.TAB_POPUP_POSITION_MAPPING = exports.TAB_DIRECTION_MAPPING = exports.TAB_ALIGN_MAPPING = void 0;
|
|
7
|
+
var VARIANT = {
|
|
8
|
+
TEXT: 'text',
|
|
9
|
+
ICON: 'icon',
|
|
10
|
+
ICON_WITH_TEXT: 'iconWithText'
|
|
11
|
+
};
|
|
12
|
+
exports.VARIANT = VARIANT;
|
|
7
13
|
var TAB_ALIGN_MAPPING = {
|
|
8
14
|
vertical: 'column',
|
|
9
15
|
horizontal: 'row',
|
|
@@ -46,6 +46,10 @@ function getTimeOffset() {
|
|
|
46
46
|
}
|
|
47
47
|
|
|
48
48
|
function formatDate(dateMill, mask) {
|
|
49
|
+
var _ref = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : {},
|
|
50
|
+
i18nShortMonths = _ref.i18nShortMonths,
|
|
51
|
+
i18nMonths = _ref.i18nMonths;
|
|
52
|
+
|
|
49
53
|
var date = new Date(dateMill);
|
|
50
54
|
var O = getTimeOffset()[0];
|
|
51
55
|
var Z = getTimeOffset()[1];
|
|
@@ -57,6 +61,10 @@ function formatDate(dateMill, mask) {
|
|
|
57
61
|
var M = date.getMinutes();
|
|
58
62
|
var s = date.getSeconds();
|
|
59
63
|
var L = date.getMilliseconds();
|
|
64
|
+
var defaultShortMonths = dateFormat.monthNames.slice(0, 12);
|
|
65
|
+
var defaultMonths = dateFormat.monthNames.slice(12);
|
|
66
|
+
var resolvedShortMonths = Array.isArray(i18nShortMonths) ? i18nShortMonths : defaultShortMonths;
|
|
67
|
+
var resolvedMonths = Array.isArray(i18nMonths) ? i18nMonths : defaultMonths;
|
|
60
68
|
var flags = {
|
|
61
69
|
d: d,
|
|
62
70
|
O: O,
|
|
@@ -69,8 +77,8 @@ function formatDate(dateMill, mask) {
|
|
|
69
77
|
DDDD: dateFormat.dayNames[D + 7],
|
|
70
78
|
M: m + 1,
|
|
71
79
|
MM: pad(m + 1, 2),
|
|
72
|
-
MMM:
|
|
73
|
-
MMMM:
|
|
80
|
+
MMM: resolvedShortMonths[m],
|
|
81
|
+
MMMM: resolvedMonths[m],
|
|
74
82
|
yy: String(y).slice(2),
|
|
75
83
|
YY: String(y).slice(2),
|
|
76
84
|
yyyy: y,
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@zohodesk/components",
|
|
3
|
-
"version": "1.0.0-temp-
|
|
3
|
+
"version": "1.0.0-temp-256",
|
|
4
4
|
"main": "es/index.js",
|
|
5
5
|
"module": "es/index.js",
|
|
6
6
|
"private": false,
|
|
@@ -33,7 +33,7 @@
|
|
|
33
33
|
"build:watch": "npm run build:es:watch --module:mode=dev -- -w",
|
|
34
34
|
"coverage": "react-cli coverage",
|
|
35
35
|
"prepare": "npm run init && npm run css:build ",
|
|
36
|
-
"prepublishOnly": "node ../prePublish.js && npm run css:review && npm run review:props ",
|
|
36
|
+
"prepublishOnly": "node ../prePublish.js && npm run download_only && npm run css:review && npm run review:props ",
|
|
37
37
|
"postpublish": "node ../postPublish.js",
|
|
38
38
|
"report": "react-cli publish:report",
|
|
39
39
|
"test": "react-cli test",
|
|
@@ -74,7 +74,7 @@
|
|
|
74
74
|
"@testing-library/react-hooks": "^7.0.2",
|
|
75
75
|
"@testing-library/user-event": "^13.0.10",
|
|
76
76
|
"@dot-system/css-audit-tool": "1.0.0",
|
|
77
|
-
"@zohodesk-private/color-variable-preprocessor": "1.3.
|
|
77
|
+
"@zohodesk-private/color-variable-preprocessor": "1.3.3",
|
|
78
78
|
"@zohodesk-private/css-variable-migrator": "1.0.11",
|
|
79
79
|
"@zohodesk-private/node-plugins": "1.1.14",
|
|
80
80
|
"@zohodesk-private/react-prop-validator": "1.2.3",
|
|
@@ -82,17 +82,18 @@
|
|
|
82
82
|
"@zohodesk/docstool": "1.0.0-alpha-2",
|
|
83
83
|
"@zohodesk/dotkit": "1.0.9",
|
|
84
84
|
"@zohodesk/hooks": "2.0.8",
|
|
85
|
-
"@zohodesk/icons": "1.3.
|
|
86
|
-
"@zohodesk/layout": "3.
|
|
87
|
-
"@zohodesk/svg": "1.3.
|
|
85
|
+
"@zohodesk/icons": "1.3.5",
|
|
86
|
+
"@zohodesk/layout": "3.2.0",
|
|
87
|
+
"@zohodesk/svg": "1.3.8",
|
|
88
88
|
"@zohodesk/utils": "1.3.16",
|
|
89
|
-
"@zohodesk/variables": "1.3.
|
|
89
|
+
"@zohodesk/variables": "1.3.2",
|
|
90
90
|
"@zohodesk/virtualizer": "1.0.13",
|
|
91
91
|
"react-sortable-hoc": "^0.8.3",
|
|
92
92
|
"velocity-react": "1.4.3",
|
|
93
93
|
"@zohodesk/react-cli": "1.1.27",
|
|
94
94
|
"@zohodesk/client_build_tool": "0.0.23",
|
|
95
95
|
"color": "4.2.3",
|
|
96
|
+
"@zohodesk/jsx_attribute_wrapper": "1.0.0",
|
|
96
97
|
"@dot-system/css-utility": "0.1.1"
|
|
97
98
|
},
|
|
98
99
|
"dependencies": {
|
|
@@ -102,16 +103,16 @@
|
|
|
102
103
|
"selectn": "1.1.2"
|
|
103
104
|
},
|
|
104
105
|
"peerDependencies": {
|
|
105
|
-
"@zohodesk/icons": "1.3.
|
|
106
|
-
"@zohodesk/variables": "1.3.
|
|
107
|
-
"@zohodesk/svg": "1.3.
|
|
106
|
+
"@zohodesk/icons": "1.3.5",
|
|
107
|
+
"@zohodesk/variables": "1.3.2",
|
|
108
|
+
"@zohodesk/svg": "1.3.8",
|
|
108
109
|
"@zohodesk/virtualizer": "1.0.13",
|
|
109
110
|
"velocity-react": "1.4.3",
|
|
110
111
|
"react-sortable-hoc": "^0.8.3",
|
|
111
112
|
"@zohodesk/hooks": "2.0.8",
|
|
112
113
|
"@zohodesk/utils": "1.3.16",
|
|
113
114
|
"@zohodesk/a11y": "2.3.9",
|
|
114
|
-
"@zohodesk/layout": "3.
|
|
115
|
+
"@zohodesk/layout": "3.2.0",
|
|
115
116
|
"@zohodesk/dotkit": "1.0.9",
|
|
116
117
|
"color": "4.2.3",
|
|
117
118
|
"@dot-system/css-utility": "0.1.1"
|