@zohodesk/components 1.6.14 → 1.6.16

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 (53) hide show
  1. package/README.md +12 -0
  2. package/es/Avatar/Avatar.js +1 -2
  3. package/es/Button/css/cssJSLogic.js +4 -5
  4. package/es/DateTime/DateTime.js +3 -6
  5. package/es/DateTime/DateWidget.js +34 -11
  6. package/es/DateTime/YearView.js +5 -6
  7. package/es/DateTime/common.js +2 -9
  8. package/es/DateTime/dateFormatUtils/dateFormat.js +55 -76
  9. package/es/DateTime/dateFormatUtils/index.js +7 -12
  10. package/es/DateTime/dateFormatUtils/timeChange.js +3 -4
  11. package/es/DateTime/dateFormatUtils/yearChange.js +3 -4
  12. package/es/DropBox/DropBoxElement/css/cssJSLogic.js +5 -6
  13. package/es/Layout/utils.js +1 -2
  14. package/es/ListItem/ListContainer.js +4 -5
  15. package/es/Modal/Portal/Portal.js +4 -5
  16. package/es/MultiSelect/AdvancedGroupMultiSelect.js +91 -103
  17. package/es/MultiSelect/AdvancedMultiSelect.js +74 -80
  18. package/es/MultiSelect/MultiSelect.js +4 -13
  19. package/es/MultiSelect/Suggestions.js +14 -17
  20. package/es/Popup/Popup.js +1 -4
  21. package/es/Provider/IdProvider.js +4 -5
  22. package/es/Provider/LibraryContext.js +11 -12
  23. package/es/Provider/NumberGenerator/NumberGenerator.js +15 -17
  24. package/es/Provider/ZindexProvider.js +4 -5
  25. package/es/Responsive/CustomResponsive.js +8 -11
  26. package/es/Responsive/ResizeComponent.js +1 -3
  27. package/es/Responsive/Responsive.js +9 -12
  28. package/es/Responsive/sizeObservers.js +1 -5
  29. package/es/ResponsiveDropBox/ResponsiveDropBox.js +10 -14
  30. package/es/Select/GroupSelect.js +98 -103
  31. package/es/Select/Select.js +110 -114
  32. package/es/Select/SelectWithAvatar.js +91 -95
  33. package/es/Select/SelectWithIcon.js +104 -109
  34. package/es/Select/__tests__/Select.spec.js +6 -9
  35. package/es/Tab/Tab.js +29 -30
  36. package/es/Tab/TabContent.js +16 -19
  37. package/es/Tab/TabContentWrapper.js +19 -22
  38. package/es/Tab/TabWrapper.js +15 -16
  39. package/es/Tab/Tabs.js +80 -87
  40. package/es/Typography/css/cssJSLogic.js +4 -5
  41. package/es/VelocityAnimation/VelocityAnimationGroup/VelocityAnimationGroup.js +1 -2
  42. package/es/utils/Common.js +10 -31
  43. package/es/utils/datetime/common.js +12 -9
  44. package/es/utils/dropDownUtils.js +7 -11
  45. package/es/utils/getInitial.js +1 -3
  46. package/es/v1/Button/css/cssJSLogic.js +4 -8
  47. package/es/v1/Label/css/cssJSLogic.js +4 -5
  48. package/es/v1/Switch/css/cssJSLogic.js +4 -5
  49. package/es/v1/helpers/colorHelpers/colorHelper.js +28 -39
  50. package/lib/DateTime/DateWidget.js +33 -6
  51. package/lib/Select/Select.js +3 -1
  52. package/lib/utils/datetime/common.js +10 -2
  53. package/package.json +2 -2
@@ -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: dateFormat.monthNames[m],
73
- MMMM: dateFormat.monthNames[m + 12],
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.6.14",
3
+ "version": "1.6.16",
4
4
  "main": "es/index.js",
5
5
  "module": "es/index.js",
6
6
  "private": false,
@@ -91,7 +91,7 @@
91
91
  "react-sortable-hoc": "^0.8.3",
92
92
  "velocity-react": "1.4.3",
93
93
  "@zohodesk/react-cli": "1.1.27",
94
- "@zohodesk/client_build_tool": "0.0.20",
94
+ "@zohodesk/client_build_tool": "0.0.23",
95
95
  "color": "4.2.3",
96
96
  "@dot-system/css-utility": "0.1.1"
97
97
  },