@innovaccer/design-system 2.3.0 → 2.4.0-0

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 (87) hide show
  1. package/CHANGELOG.md +35 -0
  2. package/core/components/atoms/backdrop/Backdrop.tsx +11 -1
  3. package/core/components/atoms/button/Button.tsx +60 -44
  4. package/core/components/atoms/button/__stories__/IconButtonGroup.story.tsx +4 -4
  5. package/core/components/atoms/button/__stories__/IconButtonSecondary.story.tsx +1 -1
  6. package/core/components/atoms/button/__tests__/Button.test.tsx +36 -1
  7. package/core/components/atoms/dropdown/DropdownList.tsx +1 -0
  8. package/core/components/atoms/dropdown/Loading.tsx +9 -9
  9. package/core/components/atoms/dropdown/__stories__/Options.tsx +2 -0
  10. package/core/components/atoms/dropdown/__tests__/Dropdown.test.tsx +12 -1
  11. package/core/components/atoms/dropdown/__tests__/Loading.test.tsx +66 -0
  12. package/core/components/atoms/dropdown/__tests__/Option.test.tsx +204 -0
  13. package/core/components/atoms/dropdown/option/CheckboxOption.tsx +1 -0
  14. package/core/components/atoms/dropdown/option/IconOption.tsx +3 -1
  15. package/core/components/atoms/dropdown/option/IconWithMetaOption.tsx +3 -1
  16. package/core/components/atoms/dropdown/option/index.tsx +7 -1
  17. package/core/components/molecules/dialog/__tests__/__snapshots__/Dialog.test.tsx.snap +13 -0
  18. package/core/components/molecules/emptyState/__stories__/assets/pageNotLoaded.png +0 -0
  19. package/core/components/molecules/emptyState/__stories__/variants/noContentAvailable.story.tsx +26 -0
  20. package/core/components/molecules/emptyState/__stories__/variants/{smallSizeWithButton.story.tsx → noSearchResults.story.tsx} +2 -2
  21. package/core/components/molecules/emptyState/__stories__/variants/{largeSize.story.tsx → pageNotLoaded.story.tsx} +3 -3
  22. package/core/components/molecules/fileList/FileIcon.tsx +10 -2
  23. package/core/components/molecules/fileList/FileListItem.tsx +7 -3
  24. package/core/components/molecules/fileList/__stories__/__common__/fileListExample.tsx +1 -0
  25. package/core/components/molecules/fileList/__tests__/FileList.test.tsx +115 -0
  26. package/core/components/molecules/fileList/__tests__/__snapshots__/FileList.test.tsx.snap +232 -0
  27. package/core/components/molecules/inputMask/InputMask.tsx +2 -5
  28. package/core/components/molecules/inputMask/__tests__/InputMask.test.tsx +128 -0
  29. package/core/components/molecules/inputMask/__tests__/__snapshots__/InputMask.test.tsx.snap +39 -0
  30. package/core/components/molecules/modal/Modal.tsx +7 -5
  31. package/core/components/molecules/modal/__tests__/__snapshots__/Modal.test.tsx.snap +18 -0
  32. package/core/components/molecules/sidesheet/Sidesheet.tsx +5 -3
  33. package/core/components/molecules/sidesheet/__tests__/__snapshots__/Sidesheet.test.tsx.snap +2 -0
  34. package/core/components/organisms/calendar/Calendar.tsx +66 -22
  35. package/core/components/organisms/calendar/__stories__/variants/withEvents.story.tsx +45 -0
  36. package/core/components/organisms/calendar/__tests__/Calendar.test.tsx +10 -0
  37. package/core/components/organisms/calendar/__tests__/__snapshots__/Calendar.test.tsx.snap +1096 -1096
  38. package/core/components/organisms/calendar/config.ts +2 -2
  39. package/core/components/organisms/calendar/types.ts +1 -0
  40. package/core/components/organisms/datePicker/DatePicker.tsx +23 -9
  41. package/core/components/organisms/datePicker/__tests__/{DatePicker.tsx → DatePicker.test.tsx} +16 -1
  42. package/core/components/organisms/datePicker/__tests__/__snapshots__/DatePicker.test.tsx.snap +2257 -0
  43. package/core/components/organisms/dateRangePicker/__tests__/__snapshots__/DateRangePicker.test.tsx.snap +2552 -2550
  44. package/core/components/organisms/inlineMessage/InlineMessage.tsx +75 -0
  45. package/core/components/organisms/inlineMessage/__stories__/Default.story.tsx +18 -0
  46. package/core/components/organisms/inlineMessage/__stories__/Error.story.tsx +19 -0
  47. package/core/components/organisms/inlineMessage/__stories__/Info.story.tsx +19 -0
  48. package/core/components/organisms/inlineMessage/__stories__/Success.story.tsx +19 -0
  49. package/core/components/organisms/inlineMessage/__stories__/Warning.story.tsx +18 -0
  50. package/core/components/organisms/inlineMessage/__stories__/variants/InlineMessageWithinTable.story.tsx +139 -0
  51. package/core/components/organisms/inlineMessage/__tests__/InlineMessage.test.tsx +91 -0
  52. package/core/components/organisms/inlineMessage/__tests__/__snapshots__/InlineMessage.test.tsx.snap +139 -0
  53. package/core/components/organisms/inlineMessage/index.tsx +1 -0
  54. package/core/components/organisms/timePicker/__tests__/__snapshots__/TimePicker.test.tsx.snap +8 -0
  55. package/core/index.tsx +2 -0
  56. package/core/index.type.tsx +1 -0
  57. package/core/utils/__tests__/__snapshots__/TS.test.tsx.snap +485 -466
  58. package/css/dist/index.css +72 -8
  59. package/css/dist/index.css.map +1 -1
  60. package/css/src/components/calendar.css +37 -5
  61. package/css/src/components/card.css +1 -1
  62. package/css/src/components/chipInput.css +2 -2
  63. package/css/src/components/editableChipInput.css +2 -1
  64. package/css/src/components/inlineMessage.css +29 -0
  65. package/dist/core/components/atoms/backdrop/Backdrop.d.ts +1 -0
  66. package/dist/core/components/atoms/button/Button.d.ts +1 -0
  67. package/dist/core/components/atoms/popperWrapper/PopperWrapper.d.ts +28 -27
  68. package/dist/core/components/organisms/calendar/Calendar.d.ts +6 -1
  69. package/dist/core/components/organisms/calendar/types.d.ts +3 -0
  70. package/dist/core/components/organisms/inlineMessage/InlineMessage.d.ts +15 -0
  71. package/dist/core/components/organisms/inlineMessage/index.d.ts +1 -0
  72. package/dist/core/index.d.ts +1 -0
  73. package/dist/core/index.type.d.ts +1 -0
  74. package/dist/index.esm.js +189 -66
  75. package/dist/index.js +201 -80
  76. package/dist/index.js.map +1 -1
  77. package/dist/index.umd.js +1 -1
  78. package/dist/index.umd.js.br +0 -0
  79. package/dist/index.umd.js.gz +0 -0
  80. package/dts.config.js +13 -0
  81. package/package.json +4 -2
  82. package/types/innovaccer-design-system/index.d.ts +39 -0
  83. package/types/innovaccer-design-system/innovaccer-design-system-tests.ts +0 -0
  84. package/types/innovaccer-design-system/tsconfig.json +23 -0
  85. package/types/innovaccer-design-system/tslint.json +1 -0
  86. package/core/components/molecules/emptyState/__stories__/variants/smallSizeWithoutButton.story.tsx +0 -21
  87. package/core/components/organisms/datePicker/__tests__/__snapshots__/DatePicker.tsx.snap +0 -2164
package/dist/index.js CHANGED
@@ -1,8 +1,8 @@
1
1
 
2
2
  /**
3
- * Generated on: 1631263425585
3
+ * Generated on: 1631955616857
4
4
  * Package: @innovaccer/design-system
5
- * Version: v2.3.0
5
+ * Version: v2.4.0-0
6
6
  * License: MIT
7
7
  * Docs: https://innovaccer.github.io/design-system
8
8
  */
@@ -652,7 +652,10 @@
652
652
  "data-test": "DesignSystem-Backdrop",
653
653
  "data-layer": true
654
654
  }, baseProps, {
655
- className: classes
655
+ className: classes,
656
+ style: {
657
+ zIndex: props.zIndex
658
+ }
656
659
  })), document.body);
657
660
  return BackdropElement;
658
661
  };
@@ -1148,7 +1151,8 @@
1148
1151
  checked: selected,
1149
1152
  onChange: onChangeHandler,
1150
1153
  tabIndex: -1,
1151
- className: "OptionCheckbox"
1154
+ className: "OptionCheckbox",
1155
+ "data-test": dataTest + "--Checkbox"
1152
1156
  }));
1153
1157
  };
1154
1158
 
@@ -1224,6 +1228,7 @@
1224
1228
  "data-disabled": disabled
1225
1229
  }, icon && /*#__PURE__*/React__namespace.createElement(Icon, {
1226
1230
  className: "Option-icon mr-4",
1231
+ "data-test": dataTest + "--Icon",
1227
1232
  name: icon,
1228
1233
  appearance: appearance
1229
1234
  }), /*#__PURE__*/React__namespace.createElement("div", {
@@ -1257,6 +1262,7 @@
1257
1262
  "data-test": dataTest,
1258
1263
  "data-disabled": disabled
1259
1264
  }, icon && /*#__PURE__*/React__namespace.createElement(Icon, {
1265
+ "data-test": dataTest + "--Icon",
1260
1266
  className: "Option-icon mr-4",
1261
1267
  name: icon,
1262
1268
  appearance: appearance
@@ -1310,6 +1316,7 @@
1310
1316
 
1311
1317
  if (props.optionRenderer) {
1312
1318
  return /*#__PURE__*/React__namespace.createElement("div", __assign({
1319
+ "data-test": "DesignSystem-DropdownOption--Custom",
1313
1320
  className: customOptionClass,
1314
1321
  "data-disabled": disabled,
1315
1322
  onMouseEnter: onUpdateActiveOption
@@ -1330,6 +1337,7 @@
1330
1337
 
1331
1338
  if (typeof subInfo === 'string') {
1332
1339
  return /*#__PURE__*/React__namespace.createElement(Text, {
1340
+ "data-test": "DesignSystem-DropdownOption--WITH_META--Meta",
1333
1341
  appearance: labelAppearance
1334
1342
  }, subInfo);
1335
1343
  }
@@ -1342,7 +1350,8 @@
1342
1350
  seperator: seperator,
1343
1351
  iconAppearance: iconAppearance,
1344
1352
  labelAppearance: labelAppearance,
1345
- seperatorAppearance: iconAppearance
1353
+ seperatorAppearance: iconAppearance,
1354
+ "data-test": "DesignSystem-DropdownOption--WITH_META--MetaList"
1346
1355
  });
1347
1356
  };
1348
1357
 
@@ -1448,30 +1457,36 @@
1448
1457
  switch (loadingType) {
1449
1458
  case 'DEFAULT':
1450
1459
  return /*#__PURE__*/React__default['default'].createElement(PlaceholderParagraph, {
1451
- length: 'large'
1460
+ length: 'large',
1461
+ "data-test": "DesignSystem-Dropdown--PlaceholderParagraph"
1452
1462
  });
1453
1463
 
1454
1464
  case 'WITH_ICON':
1455
1465
  return /*#__PURE__*/React__default['default'].createElement(Placeholder, {
1456
1466
  withImage: true,
1457
- round: true
1467
+ round: true,
1468
+ "data-test": "DesignSystem-Dropdown--Placeholder"
1458
1469
  }, /*#__PURE__*/React__default['default'].createElement(PlaceholderParagraph, {
1459
1470
  length: "large"
1460
1471
  }));
1461
1472
 
1462
1473
  case 'WITH_META':
1463
1474
  return /*#__PURE__*/React__default['default'].createElement(Placeholder, {
1464
- withImage: false
1475
+ withImage: false,
1476
+ "data-test": "DesignSystem-Dropdown--Placeholder"
1465
1477
  }, /*#__PURE__*/React__default['default'].createElement(PlaceholderParagraph, {
1466
- length: "large"
1478
+ length: "large",
1479
+ "data-test": "DesignSystem-Dropdown--PlaceholderParagraph"
1467
1480
  }), /*#__PURE__*/React__default['default'].createElement(PlaceholderParagraph, {
1468
1481
  length: "medium",
1469
- size: "xxs"
1482
+ size: "xxs",
1483
+ "data-test": "DesignSystem-Dropdown--PlaceholderParagraph"
1470
1484
  }));
1471
1485
 
1472
1486
  case 'WITH_CHECKBOX':
1473
1487
  return /*#__PURE__*/React__default['default'].createElement(Placeholder, {
1474
- withImage: true
1488
+ withImage: true,
1489
+ "data-test": "DesignSystem-Dropdown--Placeholder"
1475
1490
  }, /*#__PURE__*/React__default['default'].createElement(PlaceholderParagraph, {
1476
1491
  length: "large"
1477
1492
  }));
@@ -1480,12 +1495,15 @@
1480
1495
  return /*#__PURE__*/React__default['default'].createElement(Placeholder, {
1481
1496
  withImage: true,
1482
1497
  round: true,
1483
- imageSize: 'medium'
1498
+ imageSize: 'medium',
1499
+ "data-test": "DesignSystem-Dropdown--Placeholder"
1484
1500
  }, /*#__PURE__*/React__default['default'].createElement(PlaceholderParagraph, {
1485
- length: "large"
1501
+ length: "large",
1502
+ "data-test": "DesignSystem-Dropdown--PlaceholderParagraph"
1486
1503
  }), /*#__PURE__*/React__default['default'].createElement(PlaceholderParagraph, {
1487
1504
  length: "medium",
1488
- size: "xxs"
1505
+ size: "xxs",
1506
+ "data-test": "DesignSystem-Dropdown--PlaceholderParagraph"
1489
1507
  }));
1490
1508
  }
1491
1509
 
@@ -1937,7 +1955,9 @@
1937
1955
  open: dropdownOpen,
1938
1956
  customStyle: popoverStyle,
1939
1957
  position: alignmentMapping[align]
1940
- }, popoverOptions), (withSearch || props.async) && renderSearch(), renderDropdownSection(), showApplyButton && withCheckbox && renderApplyButton()));
1958
+ }, popoverOptions, {
1959
+ "data-test": "DesignSystem-Dropdown--Popover"
1960
+ }), (withSearch || props.async) && renderSearch(), renderDropdownSection(), showApplyButton && withCheckbox && renderApplyButton()));
1941
1961
  };
1942
1962
 
1943
1963
  DropdownList.displayName = 'DropdownList';
@@ -2673,35 +2693,59 @@
2673
2693
  loading = props.loading,
2674
2694
  disabled = props.disabled,
2675
2695
  className = props.className,
2676
- rest = __rest(props, ["size", "appearance", "iconAlign", "tabIndex", "largeIcon", "type", "children", "icon", "expanded", "selected", "loading", "disabled", "className"]);
2696
+ tooltip = props.tooltip,
2697
+ rest = __rest(props, ["size", "appearance", "iconAlign", "tabIndex", "largeIcon", "type", "children", "icon", "expanded", "selected", "loading", "disabled", "className", "tooltip"]);
2677
2698
 
2678
2699
  var buttonClass = classNames__default['default']((_a = {}, _a['Button'] = true, _a['Button--expanded'] = expanded, _a["Button--" + size] = size, _a["Button--" + size + "Square"] = !children, _a["Button--" + appearance] = appearance, _a['Button--selected'] = selected && (appearance === 'basic' || appearance === 'transparent'), _a["Button--iconAlign-" + iconAlign] = children && iconAlign, _a["" + className] = className, _a));
2679
2700
  var iconClass = classNames__default['default']((_b = {}, _b['Button-icon'] = true, _b["Button-icon--" + iconAlign] = children && iconAlign, _b));
2680
- return /*#__PURE__*/React__namespace.createElement("button", __assign({
2681
- "data-test": "DesignSystem-Button",
2682
- ref: ref,
2683
- type: type,
2684
- className: buttonClass,
2685
- disabled: disabled || loading,
2686
- tabIndex: tabIndex
2687
- }, rest), loading ? /*#__PURE__*/React__namespace.createElement(React__namespace.Fragment, null, /*#__PURE__*/React__namespace.createElement(Spinner, {
2688
- size: "small",
2689
- appearance: appearance === 'basic' || appearance === 'transparent' ? 'secondary' : 'white',
2690
- "data-test": "DesignSystem-Button--Spinner",
2691
- className: "Button-spinner"
2692
- }), /*#__PURE__*/React__namespace.createElement(Text, {
2693
- className: "Button-text Button-text--hidden"
2694
- }, children || '')) : /*#__PURE__*/React__namespace.createElement(React__namespace.Fragment, null, icon && /*#__PURE__*/React__namespace.createElement("div", {
2695
- className: iconClass
2696
- }, /*#__PURE__*/React__namespace.createElement(Icon, {
2697
- "data-test": "DesignSystem-Button--Icon",
2698
- name: icon,
2699
- appearance: disabled ? 'disabled' : appearance === 'basic' || appearance === 'transparent' ? selected ? 'info' : 'default' : 'white',
2700
- size: largeIcon && !children ? sizeMapping$2[size] + 4 : sizeMapping$2[size]
2701
- })), children));
2701
+
2702
+ var ButtonElement = function ButtonElement() {
2703
+ return /*#__PURE__*/React__namespace.createElement("button", __assign({
2704
+ "data-test": "DesignSystem-Button",
2705
+ ref: ref,
2706
+ type: type,
2707
+ className: buttonClass,
2708
+ disabled: disabled || loading,
2709
+ tabIndex: tabIndex
2710
+ }, rest), loading ? /*#__PURE__*/React__namespace.createElement(React__namespace.Fragment, null, /*#__PURE__*/React__namespace.createElement(Spinner, {
2711
+ size: "small",
2712
+ appearance: appearance === 'basic' || appearance === 'transparent' ? 'secondary' : 'white',
2713
+ "data-test": "DesignSystem-Button--Spinner",
2714
+ className: "Button-spinner"
2715
+ }), /*#__PURE__*/React__namespace.createElement(Text, {
2716
+ className: "Button-text Button-text--hidden"
2717
+ }, children || '')) : /*#__PURE__*/React__namespace.createElement(React__namespace.Fragment, null, icon && /*#__PURE__*/React__namespace.createElement("div", {
2718
+ className: iconClass
2719
+ }, /*#__PURE__*/React__namespace.createElement(Icon, {
2720
+ "data-test": "DesignSystem-Button--Icon",
2721
+ name: icon,
2722
+ appearance: disabled ? 'disabled' : appearance === 'basic' || appearance === 'transparent' ? selected ? 'info' : 'default' : 'white',
2723
+ size: largeIcon && !children ? sizeMapping$2[size] + 4 : sizeMapping$2[size]
2724
+ })), children));
2725
+ };
2726
+
2727
+ return icon && tooltip && !children ? /*#__PURE__*/React__namespace.createElement(Tooltip, {
2728
+ tooltip: tooltip
2729
+ }, /*#__PURE__*/React__namespace.createElement(ButtonElement, null)) : /*#__PURE__*/React__namespace.createElement(ButtonElement, null);
2702
2730
  });
2703
2731
  Button.displayName = 'Button';
2704
2732
 
2733
+ function _typeof(obj) {
2734
+ "@babel/helpers - typeof";
2735
+
2736
+ if (typeof Symbol === "function" && typeof Symbol.iterator === "symbol") {
2737
+ _typeof = function (obj) {
2738
+ return typeof obj;
2739
+ };
2740
+ } else {
2741
+ _typeof = function (obj) {
2742
+ return obj && typeof Symbol === "function" && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj;
2743
+ };
2744
+ }
2745
+
2746
+ return _typeof(obj);
2747
+ }
2748
+
2705
2749
  var config = {
2706
2750
  yearBlockRange: 12,
2707
2751
  yearsInRow: 3,
@@ -2710,8 +2754,8 @@
2710
2754
  daysInRow: 7,
2711
2755
  months: ['Jan', 'Feb', 'Mar', 'Apr', 'May', 'Jun', 'Jul', 'Aug', 'Sep', 'Oct', 'Nov', 'Dec'],
2712
2756
  days: {
2713
- small: ['S', 'M', 'T', 'W', 'T', 'F', 'S'],
2714
- large: ['Sun', 'Mon', 'Tue', 'Wed', 'Thu', 'Fri', 'Sat']
2757
+ small: ['Su', 'Mo', 'Tu', 'We', 'Th', 'Fr', 'Sa'],
2758
+ large: ['Su', 'Mo', 'Tu', 'We', 'Th', 'Fr', 'Sa']
2715
2759
  }
2716
2760
  };
2717
2761
 
@@ -3128,7 +3172,7 @@
3128
3172
  return /*#__PURE__*/React__namespace.createElement(Button, {
3129
3173
  type: "button",
3130
3174
  className: headerIconClass,
3131
- appearance: "transparent",
3175
+ appearance: "basic",
3132
3176
  icon: "arrow_" + (type === 'next' ? 'forward' : 'back'),
3133
3177
  disabled: disabled,
3134
3178
  onClick: _this.onNavIconClickHandler(type)
@@ -3311,6 +3355,7 @@
3311
3355
  var _a = _this.props,
3312
3356
  size = _a.size,
3313
3357
  firstDayOfWeek = _a.firstDayOfWeek;
3358
+ var textSize = size === 'large' ? 'regular' : 'small';
3314
3359
  return /*#__PURE__*/React__namespace.createElement(React__namespace.Fragment, null, /*#__PURE__*/React__namespace.createElement("div", {
3315
3360
  className: "Calendar-dayValues"
3316
3361
  }, Array.from({
@@ -3320,10 +3365,12 @@
3320
3365
  'Calendar-valueWrapper': true
3321
3366
  });
3322
3367
  var dayValue = (day + daysInRow + getIndexOfDay(firstDayOfWeek)) % daysInRow;
3323
- return /*#__PURE__*/React__namespace.createElement(Subheading, {
3368
+ return /*#__PURE__*/React__namespace.createElement(Text, {
3324
3369
  key: day,
3325
3370
  className: valueClass,
3326
- appearance: "disabled"
3371
+ appearance: "default",
3372
+ weight: "strong",
3373
+ size: textSize
3327
3374
  }, days[size][dayValue]);
3328
3375
  })), /*#__PURE__*/React__namespace.createElement("div", {
3329
3376
  className: "Calendar-dateValues",
@@ -3345,7 +3392,10 @@
3345
3392
  hoverDate = _b.hoverDate,
3346
3393
  yearState = _b.year,
3347
3394
  monthState = _b.month,
3348
- dateState = _b.date;
3395
+ dateState = _b.date,
3396
+ currMonth = _b.currMonth,
3397
+ currYear = _b.currYear,
3398
+ todayDate = _b.todayDate;
3349
3399
 
3350
3400
  var _c = _this.getNavDateInfo(index),
3351
3401
  yearNavVal = _c.year,
@@ -3358,6 +3408,8 @@
3358
3408
 
3359
3409
  var inRangeError = _this.getInRangeError();
3360
3410
 
3411
+ var events = _this.props.events;
3412
+
3361
3413
  var onClickHandler = function onClickHandler(date) {
3362
3414
  return function () {
3363
3415
  if (rangePicker) {
@@ -3401,6 +3453,7 @@
3401
3453
  var dummy = date <= 0 || date > dayRange;
3402
3454
  var disabled = !dummy && (compareDate(disabledBefore, 'more', yearNavVal, monthNavVal, date) || compareDate(disabledAfter, 'less', yearNavVal, monthNavVal, date));
3403
3455
  var active = !disabled && yearState === yearNavVal && monthState === monthNavVal && dateState === date;
3456
+ var today = !rangePicker && !disabled && currYear === yearNavVal && currMonth === monthNavVal && todayDate === date;
3404
3457
  var startActive = false;
3405
3458
  var endActive = false;
3406
3459
  var inRange = false;
@@ -3434,6 +3487,11 @@
3434
3487
  var isStart = startActive || endDate && inRangeLast && compareDate(hoverDate, 'less', eYear, eMonth, eDate);
3435
3488
  var isEnd = endActive || startDate && inRangeLast && compareDate(hoverDate, 'more', sYear, sMonth, sDate);
3436
3489
  var isRangeError = inRange && inRangeError;
3490
+ var monthInString = "" + (monthNavVal + 1 > 9 ? monthNavVal + 1 : "0" + (monthNavVal + 1));
3491
+ var dateInString = "" + (date > 9 ? date : "0" + date);
3492
+ var yearInString = "" + yearNavVal;
3493
+ var completeDateString = monthInString + "/" + dateInString + "/" + yearInString;
3494
+ var isEventExist = events && _typeof(events) === 'object' && events.hasOwnProperty(completeDateString);
3437
3495
  var wrapperClass = classNames__default['default']({
3438
3496
  'Calendar-valueWrapper': true,
3439
3497
  'Calendar-valueWrapper--inRange': inRange || rangePicker && active,
@@ -3454,19 +3512,19 @@
3454
3512
  'Calendar-value--dummy': dummy || disabled,
3455
3513
  'Calendar-value--disabled': disabled,
3456
3514
  'Calendar-dateValue': true
3457
- }, _a["Calendar-dateValue--" + size] = size, _a));
3515
+ }, _a["Calendar-dateValue--" + size] = size, _a['Calendar-value--currentDate'] = today, _a));
3458
3516
  return /*#__PURE__*/React__namespace.createElement("div", {
3459
3517
  key: row + "-" + col,
3460
3518
  className: wrapperClass,
3461
3519
  "data-test": "designSystem-Calendar-WrapperClass"
3462
- }, !dummy && /*#__PURE__*/React__namespace.createElement(Text, {
3463
- appearance: active ? 'white' : disabled ? 'disabled' : 'default',
3520
+ }, !dummy && /*#__PURE__*/React__namespace.createElement(React__namespace.Fragment, null, /*#__PURE__*/React__namespace.createElement(Text, {
3521
+ appearance: active ? 'white' : disabled ? 'disabled' : today ? 'link' : 'default',
3464
3522
  size: size === 'small' ? 'small' : 'regular',
3465
3523
  "data-test": "DesignSystem-Calendar--dateValue",
3466
3524
  className: valueClass,
3467
3525
  onClick: onClickHandler(date),
3468
3526
  onMouseOver: onMouseOverHandler(date)
3469
- }, date));
3527
+ }, date), isEventExist && _this.renderEventsIndicator(size, active)));
3470
3528
  }));
3471
3529
  });
3472
3530
  };
@@ -3511,6 +3569,7 @@
3511
3569
  month = _b.month,
3512
3570
  date = _b.date;
3513
3571
 
3572
+ var todayCompleteDate = getDateInfo(new Date());
3514
3573
  _this.state = {
3515
3574
  currDate: currDate,
3516
3575
  startDate: startDate,
@@ -3520,6 +3579,9 @@
3520
3579
  year: year,
3521
3580
  month: month,
3522
3581
  date: date,
3582
+ todayDate: todayCompleteDate.date,
3583
+ currMonth: todayCompleteDate.month,
3584
+ currYear: todayCompleteDate.year,
3523
3585
  view: monthsInView > 1 ? 'date' : view,
3524
3586
  yearBlockNav: getYearBlock(yearNav)
3525
3587
  };
@@ -3678,6 +3740,18 @@
3678
3740
  }
3679
3741
  };
3680
3742
 
3743
+ Calendar.prototype.renderEventsIndicator = function (size, active) {
3744
+ var _a;
3745
+
3746
+ var eventsIndicatorClass = classNames__default['default']((_a = {
3747
+ 'Calendar-eventsIndicator': true
3748
+ }, _a["Calendar-eventsIndicator--" + size] = true, _a['Calendar-eventsIndicator--active'] = active, _a));
3749
+ return /*#__PURE__*/React__namespace.createElement("span", {
3750
+ "data-test": "DesignSystem-Calendar-Event-Indicator",
3751
+ className: eventsIndicatorClass
3752
+ });
3753
+ };
3754
+
3681
3755
  Calendar.prototype.render = function () {
3682
3756
  var _this = this;
3683
3757
 
@@ -4151,6 +4225,8 @@
4151
4225
  };
4152
4226
 
4153
4227
  DatePicker.prototype.renderCalendar = function () {
4228
+ var _this = this;
4229
+
4154
4230
  var _a = this.props;
4155
4231
  _a.date;
4156
4232
  _a.open;
@@ -4164,15 +4240,29 @@
4164
4240
  disabledAfter = _a.disabledAfter;
4165
4241
  _a.onDateChange;
4166
4242
  _a.closeOnSelect;
4167
- var rest = __rest(_a, ["date", "open", "position", "inputFormat", "outputFormat", "inputOptions", "validators", "withInput", "disabledBefore", "disabledAfter", "onDateChange", "closeOnSelect"]);
4243
+ _a.size;
4244
+ var rest = __rest(_a, ["date", "open", "position", "inputFormat", "outputFormat", "inputOptions", "validators", "withInput", "disabledBefore", "disabledAfter", "onDateChange", "closeOnSelect", "size"]);
4168
4245
 
4169
4246
  var date = this.state.date;
4170
- return /*#__PURE__*/React__namespace.createElement(Calendar, __assign({}, rest, {
4247
+ var months = config.months;
4248
+ var monthIndex = new Date().getMonth();
4249
+ var todayMonthAndDate = months[monthIndex] + " " + new Date().getDate();
4250
+ return /*#__PURE__*/React__namespace.createElement("div", null, /*#__PURE__*/React__namespace.createElement(Calendar, __assign({}, rest, {
4171
4251
  date: convertToDate(date, inputFormat, validators),
4172
4252
  disabledBefore: convertToDate(disabledBefore, inputFormat, validators),
4173
4253
  disabledAfter: convertToDate(disabledAfter, inputFormat, validators),
4174
4254
  onDateChange: this.onDateChangeHandler
4175
- }));
4255
+ })), /*#__PURE__*/React__namespace.createElement("div", {
4256
+ className: "d-flex justify-content-center pb-6 pt-3",
4257
+ "data-test": "DesignSystem-Select--TodaysDate-wrapper"
4258
+ }, /*#__PURE__*/React__namespace.createElement(Chip, {
4259
+ label: "Today, " + todayMonthAndDate,
4260
+ name: "chip",
4261
+ type: "action",
4262
+ onClick: function onClick() {
4263
+ return _this.onDateChangeHandler(new Date());
4264
+ }
4265
+ })));
4176
4266
  };
4177
4267
 
4178
4268
  DatePicker.prototype.render = function () {
@@ -4633,22 +4723,6 @@
4633
4723
  });
4634
4724
  MetricInput.displayName = 'MetricInput';
4635
4725
 
4636
- function _typeof(obj) {
4637
- "@babel/helpers - typeof";
4638
-
4639
- if (typeof Symbol === "function" && typeof Symbol.iterator === "symbol") {
4640
- _typeof = function (obj) {
4641
- return typeof obj;
4642
- };
4643
- } else {
4644
- _typeof = function (obj) {
4645
- return obj && typeof Symbol === "function" && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj;
4646
- };
4647
- }
4648
-
4649
- return _typeof(obj);
4650
- }
4651
-
4652
4726
  var isEditable = function isEditable(mask, pos) {
4653
4727
  return _typeof(mask[pos]) === 'object';
4654
4728
  };
@@ -4908,7 +4982,8 @@
4908
4982
  'd-flex flex-column flex-grow-1': true
4909
4983
  }, className);
4910
4984
  return /*#__PURE__*/React__namespace.createElement("div", {
4911
- className: classes
4985
+ className: classes,
4986
+ "data-test": "DesignSystem-InputMask--Wrapper"
4912
4987
  }, /*#__PURE__*/React__namespace.createElement(Input, __assign({}, rest, {
4913
4988
  value: value,
4914
4989
  error: error,
@@ -5202,7 +5277,7 @@
5202
5277
  disabled: false
5203
5278
  };
5204
5279
 
5205
- var IconMapping$1 = {
5280
+ var IconMapping$2 = {
5206
5281
  success: 'check_circle',
5207
5282
  info: 'info',
5208
5283
  warning: 'warning',
@@ -5245,7 +5320,7 @@
5245
5320
  className: MessageClass
5246
5321
  }), appearance !== 'default' && /*#__PURE__*/React__namespace.createElement(Icon, {
5247
5322
  "data-test": "DesignSystem-Message--Icon",
5248
- name: IconMapping$1[appearance],
5323
+ name: IconMapping$2[appearance],
5249
5324
  appearance: appearance,
5250
5325
  className: IconClass
5251
5326
  }), /*#__PURE__*/React__namespace.createElement("div", null, title && /*#__PURE__*/React__namespace.createElement(Heading, {
@@ -7723,6 +7798,7 @@
7723
7798
  seperator = _f.seperator,
7724
7799
  footer = _f.footer,
7725
7800
  onClose = _f.onClose;
7801
+ var BackdropZIndex = zIndex ? zIndex - 1 : 1000;
7726
7802
  var classes = classNames__default['default']({
7727
7803
  Modal: true,
7728
7804
  'Modal--open': open,
@@ -7795,7 +7871,8 @@
7795
7871
  }, ModalContainer) : ModalContainer;
7796
7872
  var WrapperElement = /*#__PURE__*/ReactDOM__namespace.createPortal(ModalWrapper, this.element);
7797
7873
  return /*#__PURE__*/React__namespace.createElement(React__namespace.Fragment, null, WrapperElement, /*#__PURE__*/React__namespace.createElement(Backdrop, {
7798
- open: this.state.animate
7874
+ open: this.state.animate,
7875
+ zIndex: BackdropZIndex
7799
7876
  }));
7800
7877
  };
7801
7878
 
@@ -8144,6 +8221,7 @@
8144
8221
  footerOptions = _f.footerOptions,
8145
8222
  header = _f.header,
8146
8223
  onClose = _f.onClose;
8224
+ var BackdropZIndex = zIndex ? zIndex - 1 : 1000;
8147
8225
  var classes = classNames__default['default']({
8148
8226
  Sidesheet: true,
8149
8227
  'Sidesheet--open': open,
@@ -8196,7 +8274,8 @@
8196
8274
  }, SidesheetContainer) : SidesheetContainer;
8197
8275
  var WrapperElement = /*#__PURE__*/ReactDOM__namespace.createPortal(SidesheetWrapper, this.element);
8198
8276
  return /*#__PURE__*/React__namespace.createElement(React__namespace.Fragment, null, WrapperElement, /*#__PURE__*/React__namespace.createElement(Backdrop, {
8199
- open: this.state.animate
8277
+ open: this.state.animate,
8278
+ zIndex: BackdropZIndex
8200
8279
  }));
8201
8280
  };
8202
8281
 
@@ -13874,7 +13953,7 @@
13874
13953
 
13875
13954
  var useEffect = React__namespace.useEffect,
13876
13955
  useState = React__namespace.useState;
13877
- var IconMapping = {
13956
+ var IconMapping$1 = {
13878
13957
  audio: 'audiotrack',
13879
13958
  image: 'image',
13880
13959
  video: 'movie',
@@ -13893,7 +13972,7 @@
13893
13972
  setAnimate = _c[1];
13894
13973
 
13895
13974
  var type = file.type.split('/')[0] || 'others';
13896
- var fileType = IconMapping[type] ? type : 'others';
13975
+ var fileType = IconMapping$1[type] ? type : 'others';
13897
13976
  var iconClass = classNames__default['default']((_a = {}, _a['FileIcon'] = true, _a['FileIcon--animate'] = animate, _a["FileIcon--" + fileType] = true, _a));
13898
13977
  var uploadingIconClass = classNames__default['default']((_b = {}, _b['FileIcon'] = true, _b['FileIcon--uploading'] = true, _b));
13899
13978
  useEffect(function () {
@@ -13908,13 +13987,15 @@
13908
13987
  return /*#__PURE__*/React__namespace.createElement(ProgressRing, {
13909
13988
  size: "small",
13910
13989
  value: progress || 0,
13911
- className: uploadingIconClass
13990
+ className: uploadingIconClass,
13991
+ "data-test": "DesignSystem-FileListItem--ProgressRing"
13912
13992
  });
13913
13993
  }
13914
13994
 
13915
13995
  return /*#__PURE__*/React__namespace.createElement(Icon, {
13916
- name: IconMapping[fileType],
13917
- className: iconClass
13996
+ name: IconMapping$1[fileType],
13997
+ className: iconClass,
13998
+ "data-test": "DesignSystem-FileListItem--Icon"
13918
13999
  });
13919
14000
  };
13920
14001
  FileIcon.displayName = 'FileIcon';
@@ -13947,7 +14028,8 @@
13947
14028
 
13948
14029
  return /*#__PURE__*/React__namespace.createElement("div", __assign({}, baseProps, {
13949
14030
  className: FileItemClass,
13950
- onClick: onClickHandler
14031
+ onClick: onClickHandler,
14032
+ "data-test": "DesignSystem-FileListItem"
13951
14033
  }), /*#__PURE__*/React__namespace.createElement("div", {
13952
14034
  className: "FileItem-file"
13953
14035
  }, /*#__PURE__*/React__namespace.createElement("div", {
@@ -13957,13 +14039,15 @@
13957
14039
  status: status,
13958
14040
  progress: progress
13959
14041
  }), /*#__PURE__*/React__namespace.createElement(Text, {
14042
+ "data-test": "DesignSystem-FileListItem--Name",
13960
14043
  className: "FileItem-text",
13961
14044
  appearance: status === 'completed' ? 'default' : 'subtle'
13962
14045
  }, name)), /*#__PURE__*/React__namespace.createElement("div", {
13963
14046
  className: "FileItem-actions"
13964
14047
  }, /*#__PURE__*/React__namespace.createElement(Text, {
13965
14048
  className: "FileItem-size",
13966
- appearance: 'subtle'
14049
+ appearance: 'subtle',
14050
+ "data-test": "DesignSystem-FileListItem--Size"
13967
14051
  }, fileSize || file.size), !!actions && actions)), status === 'error' && /*#__PURE__*/React__namespace.createElement(Caption, {
13968
14052
  className: 'FileItem-error',
13969
14053
  error: true
@@ -14207,7 +14291,43 @@
14207
14291
 
14208
14292
  VerificationCodeInput.displayName = 'VerificationCodeInput';
14209
14293
 
14210
- var version = "2.3.0";
14294
+ var IconMapping = {
14295
+ success: 'check_circle',
14296
+ info: 'info',
14297
+ warning: 'warning',
14298
+ alert: 'error'
14299
+ };
14300
+ var InlineMessage = function InlineMessage(props) {
14301
+ var _a, _b, _c;
14302
+
14303
+ var appearance = props.appearance,
14304
+ className = props.className,
14305
+ description = props.description;
14306
+ var baseProps = extractBaseProps(props);
14307
+ var InlineMessageClass = classNames__default['default']((_a = {}, _a['InlineMessage'] = true, _a), className);
14308
+ var IconClass = classNames__default['default']((_b = {}, _b['InlineMessage-icon'] = true, _b['InlineMessage-icon--warning'] = appearance === 'warning', _b));
14309
+ var DescriptionClass = classNames__default['default']((_c = {}, _c["InlineMessage-text--" + appearance] = appearance, _c));
14310
+ return /*#__PURE__*/React__namespace.createElement("div", __assign({
14311
+ "data-test": "DesignSystem-InlineMessage"
14312
+ }, baseProps, {
14313
+ className: InlineMessageClass
14314
+ }), appearance !== 'default' && /*#__PURE__*/React__namespace.createElement(Icon, {
14315
+ "data-test": "DesignSystem-InlineMessage--Icon",
14316
+ name: IconMapping[appearance],
14317
+ appearance: appearance,
14318
+ className: IconClass
14319
+ }), /*#__PURE__*/React__namespace.createElement("div", null, /*#__PURE__*/React__namespace.createElement(Text, {
14320
+ "data-test": "DesignSystem-InlineMessage--Description",
14321
+ className: DescriptionClass
14322
+ }, description)));
14323
+ };
14324
+ InlineMessage.displayName = 'InlineMessage';
14325
+ InlineMessage.defaultProps = {
14326
+ appearance: 'default',
14327
+ description: ''
14328
+ };
14329
+
14330
+ var version = "2.4.0-0";
14211
14331
 
14212
14332
  exports.Avatar = Avatar;
14213
14333
  exports.AvatarGroup = AvatarGroup;
@@ -14247,6 +14367,7 @@
14247
14367
  exports.Heading = Heading;
14248
14368
  exports.HorizontalNav = HorizontalNav;
14249
14369
  exports.Icon = Icon;
14370
+ exports.InlineMessage = InlineMessage;
14250
14371
  exports.Input = Input;
14251
14372
  exports.InputMask = InputMask;
14252
14373
  exports.Label = Label;