@zohodesk/dot 1.3.0-temp-158 → 1.3.1

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 (92) hide show
  1. package/.cli/PropLessFiles.html +1 -1
  2. package/.cli/propValidation_report.html +1 -1
  3. package/README.md +3 -1
  4. package/coverage/ExternalLink/ExternalLink.js.html +1 -1
  5. package/coverage/ExternalLink/ExternalLink.module.css.html +1 -1
  6. package/coverage/ExternalLink/index.html +1 -1
  7. package/coverage/ExternalLink/props/defaultProps.js.html +1 -1
  8. package/coverage/ExternalLink/props/index.html +1 -1
  9. package/coverage/ExternalLink/props/propTypes.js.html +1 -1
  10. package/coverage/IconButton/IconButton.js.html +1 -1
  11. package/coverage/IconButton/IconButton.module.css.html +1 -1
  12. package/coverage/IconButton/index.html +1 -1
  13. package/coverage/IconButton/props/defaultProps.js.html +1 -1
  14. package/coverage/IconButton/props/index.html +1 -1
  15. package/coverage/IconButton/props/propTypes.js.html +1 -1
  16. package/coverage/Image/Image.js.html +1 -1
  17. package/coverage/Image/Image.module.css.html +1 -1
  18. package/coverage/Image/index.html +1 -1
  19. package/coverage/Image/props/defaultProps.js.html +1 -1
  20. package/coverage/Image/props/index.html +1 -1
  21. package/coverage/Image/props/propTypes.js.html +1 -1
  22. package/coverage/avatar/AvatarWithTeam/AvatarWithTeam.js.html +1 -1
  23. package/coverage/avatar/AvatarWithTeam/AvatarWithTeam.module.css.html +1 -1
  24. package/coverage/avatar/AvatarWithTeam/index.html +1 -1
  25. package/coverage/avatar/AvatarWithTeam/props/defaultProps.js.html +1 -1
  26. package/coverage/avatar/AvatarWithTeam/props/index.html +1 -1
  27. package/coverage/avatar/AvatarWithTeam/props/propTypes.js.html +1 -1
  28. package/coverage/coverage-final.json +16 -16
  29. package/coverage/coverage-summary.json +16 -16
  30. package/coverage/index.html +1 -1
  31. package/es/v1/ActionButton/ActionButton.js +2 -2
  32. package/es/v1/Message/Message.js +16 -42
  33. package/es/v1/PlusIcon/PlusIcon.js +25 -37
  34. package/es/v1/alert/AlertHeader/AlertHeader.js +5 -4
  35. package/es/v1/alert/AlertHeader/props/defaultProps.js +12 -0
  36. package/es/v1/alert/AlertHeader/props/propTypes.js +20 -0
  37. package/es/v1/alert/AlertLookup/AlertLookup.js +6 -4
  38. package/es/v1/alert/AlertLookup/props/defaultProps.js +13 -0
  39. package/es/v1/alert/AlertLookup/props/propTypes.js +36 -0
  40. package/es/v1/avatar/AvatarClose/AvatarClose.js +32 -43
  41. package/es/v1/avatar/AvatarCollision/AvatarCollision.js +41 -52
  42. package/es/v1/avatar/AvatarIcon/AvatarIcon.js +38 -43
  43. package/es/v1/avatar/AvatarStatus/AvatarStatus.js +52 -63
  44. package/es/v1/avatar/AvatarThread/AvatarThread.js +62 -69
  45. package/es/v1/avatar/AvatarUser/AvatarUser.js +93 -100
  46. package/es/v1/avatar/AvatarWithTeam/AvatarWithTeam.js +81 -88
  47. package/es/v1/list/SecondaryText/AccountName.js +61 -69
  48. package/es/v1/list/SecondaryText/ContactName.js +66 -74
  49. package/es/v1/list/SecondaryText/DepartmentText.js +15 -27
  50. package/es/v1/list/SecondaryText/Email.js +32 -40
  51. package/es/v1/list/SecondaryText/HappinessRating.js +17 -25
  52. package/es/v1/list/SecondaryText/PhoneNumber.js +36 -44
  53. package/es/v1/list/SecondaryText/PriorityText.js +16 -28
  54. package/es/v1/list/SecondaryText/SecondaryText.js +21 -33
  55. package/es/v1/list/SecondaryText/StatusText.js +17 -29
  56. package/es/v1/list/SecondaryText/TicketId.js +33 -45
  57. package/es/v1/list/SecondaryText/Website.js +22 -30
  58. package/es/v1/list/SecondryPanel/SecondryPanel.js +66 -83
  59. package/es/v1/list/SentimentStatus/SentimentStatus.js +18 -29
  60. package/es/v1/list/status/StatusDropdown/StatusDropdown.js +2 -2
  61. package/lib/v1/ActionButton/ActionButton.js +2 -2
  62. package/lib/v1/Message/Message.js +23 -80
  63. package/lib/v1/PlusIcon/PlusIcon.js +25 -71
  64. package/lib/v1/alert/AlertHeader/AlertHeader.js +5 -4
  65. package/lib/v1/alert/AlertHeader/props/defaultProps.js +19 -0
  66. package/lib/v1/alert/AlertHeader/props/propTypes.js +31 -0
  67. package/lib/v1/alert/AlertLookup/AlertLookup.js +6 -4
  68. package/lib/v1/alert/AlertLookup/props/defaultProps.js +20 -0
  69. package/lib/v1/alert/AlertLookup/props/propTypes.js +47 -0
  70. package/lib/v1/avatar/AvatarClose/AvatarClose.js +32 -77
  71. package/lib/v1/avatar/AvatarCollision/AvatarCollision.js +41 -86
  72. package/lib/v1/avatar/AvatarIcon/AvatarIcon.js +37 -80
  73. package/lib/v1/avatar/AvatarStatus/AvatarStatus.js +52 -97
  74. package/lib/v1/avatar/AvatarThread/AvatarThread.js +61 -106
  75. package/lib/v1/avatar/AvatarUser/AvatarUser.js +95 -140
  76. package/lib/v1/avatar/AvatarWithTeam/AvatarWithTeam.js +85 -130
  77. package/lib/v1/list/SecondaryText/AccountName.js +63 -113
  78. package/lib/v1/list/SecondaryText/ContactName.js +67 -117
  79. package/lib/v1/list/SecondaryText/DepartmentText.js +16 -66
  80. package/lib/v1/list/SecondaryText/Email.js +32 -82
  81. package/lib/v1/list/SecondaryText/HappinessRating.js +21 -68
  82. package/lib/v1/list/SecondaryText/PhoneNumber.js +36 -86
  83. package/lib/v1/list/SecondaryText/PriorityText.js +16 -66
  84. package/lib/v1/list/SecondaryText/SecondaryText.js +19 -69
  85. package/lib/v1/list/SecondaryText/StatusText.js +17 -67
  86. package/lib/v1/list/SecondaryText/TicketId.js +33 -83
  87. package/lib/v1/list/SecondaryText/Website.js +29 -72
  88. package/lib/v1/list/SecondryPanel/SecondryPanel.js +69 -168
  89. package/lib/v1/list/SentimentStatus/SentimentStatus.js +19 -64
  90. package/lib/v1/list/status/StatusDropdown/StatusDropdown.js +2 -2
  91. package/package.json +2 -2
  92. package/result.json +1 -1
@@ -1,11 +1,9 @@
1
1
  "use strict";
2
2
 
3
- function _typeof(obj) { "@babel/helpers - typeof"; return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (obj) { return typeof obj; } : function (obj) { return obj && "function" == typeof Symbol && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }, _typeof(obj); }
4
-
5
3
  Object.defineProperty(exports, "__esModule", {
6
4
  value: true
7
5
  });
8
- exports["default"] = void 0;
6
+ exports["default"] = AvatarUser;
9
7
 
10
8
  var _react = _interopRequireDefault(require("react"));
11
9
 
@@ -25,143 +23,100 @@ function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "d
25
23
 
26
24
  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); }
27
25
 
28
- function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } }
29
-
30
- function _defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } }
31
-
32
- function _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); Object.defineProperty(Constructor, "prototype", { writable: false }); return Constructor; }
33
-
34
- function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function"); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, writable: true, configurable: true } }); Object.defineProperty(subClass, "prototype", { writable: false }); if (superClass) _setPrototypeOf(subClass, superClass); }
35
-
36
- function _setPrototypeOf(o, p) { _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function _setPrototypeOf(o, p) { o.__proto__ = p; return o; }; return _setPrototypeOf(o, p); }
37
-
38
- function _createSuper(Derived) { var hasNativeReflectConstruct = _isNativeReflectConstruct(); return function _createSuperInternal() { var Super = _getPrototypeOf(Derived), result; if (hasNativeReflectConstruct) { var NewTarget = _getPrototypeOf(this).constructor; result = Reflect.construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return _possibleConstructorReturn(this, result); }; }
39
-
40
- function _possibleConstructorReturn(self, call) { if (call && (_typeof(call) === "object" || typeof call === "function")) { return call; } else if (call !== void 0) { throw new TypeError("Derived constructors may only return object or undefined"); } return _assertThisInitialized(self); }
41
-
42
- function _assertThisInitialized(self) { if (self === void 0) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return self; }
43
-
44
- function _isNativeReflectConstruct() { if (typeof Reflect === "undefined" || !Reflect.construct) return false; if (Reflect.construct.sham) return false; if (typeof Proxy === "function") return true; try { Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); return true; } catch (e) { return false; } }
45
-
46
- function _getPrototypeOf(o) { _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf.bind() : function _getPrototypeOf(o) { return o.__proto__ || Object.getPrototypeOf(o); }; return _getPrototypeOf(o); }
47
-
48
26
  /**** Methods ****/
49
- var AvatarUser = /*#__PURE__*/function (_React$Component) {
50
- _inherits(AvatarUser, _React$Component);
51
-
52
- var _super = _createSuper(AvatarUser);
53
-
54
- function AvatarUser() {
55
- _classCallCheck(this, AvatarUser);
27
+ function AvatarUser(props) {
28
+ var src = props.src,
29
+ alternateSrc = props.alternateSrc,
30
+ name = props.name,
31
+ size = props.size,
32
+ onClick = props.onClick,
33
+ onDelete = props.onDelete,
34
+ title = props.title,
35
+ isPaid = props.isPaid,
36
+ isPortal = props.isPortal,
37
+ isLocked = props.isLocked,
38
+ dataId = props.dataId,
39
+ dataSelectorId = props.dataSelectorId,
40
+ needTitle = props.needTitle,
41
+ needDelete = props.needDelete,
42
+ initial = props.initial,
43
+ palette = props.palette,
44
+ textPalette = props.textPalette,
45
+ customTextClass = props.customTextClass,
46
+ iconName = props.iconName,
47
+ iconSize = props.iconSize,
48
+ iconClass = props.iconClass,
49
+ iconColor = props.iconColor,
50
+ i18nKeys = props.i18nKeys,
51
+ customProps = props.customProps;
52
+ var _customProps$AvatarUs = customProps.AvatarUserProps,
53
+ AvatarUserProps = _customProps$AvatarUs === void 0 ? {} : _customProps$AvatarUs,
54
+ _customProps$AvatarIc = customProps.AvatarIconProps,
55
+ AvatarIconProps = _customProps$AvatarIc === void 0 ? {} : _customProps$AvatarIc,
56
+ _customProps$AvatarPr = customProps.AvatarProps,
57
+ AvatarProps = _customProps$AvatarPr === void 0 ? {} : _customProps$AvatarPr;
58
+ var _i18nKeys$paidTitle = i18nKeys.paidTitle,
59
+ paidTitle = _i18nKeys$paidTitle === void 0 ? 'Paid User' : _i18nKeys$paidTitle,
60
+ _i18nKeys$portalTitle = i18nKeys.portalTitle,
61
+ portalTitle = _i18nKeys$portalTitle === void 0 ? 'End User' : _i18nKeys$portalTitle,
62
+ _i18nKeys$lockTitle = i18nKeys.lockTitle,
63
+ lockTitle = _i18nKeys$lockTitle === void 0 ? 'Locked' : _i18nKeys$lockTitle;
64
+ return /*#__PURE__*/_react["default"].createElement("div", _extends({
65
+ className: "".concat(_AvatarUserModule["default"].container, " ").concat(_AvatarUserModule["default"][size]),
66
+ "data-id": dataId || name || iconName,
67
+ "data-test-id": dataId || name || iconName,
68
+ "data-selector-id": dataSelectorId
69
+ }, AvatarUserProps), iconName ? /*#__PURE__*/_react["default"].createElement(_AvatarIcon["default"], _extends({
70
+ name: iconName,
71
+ iconSize: iconSize,
72
+ size: size,
73
+ iconClass: iconClass,
74
+ dataId: iconName,
75
+ iconColor: iconColor,
76
+ title: title
77
+ }, AvatarIconProps)) : /*#__PURE__*/_react["default"].createElement(_Avatar["default"], _extends({
78
+ src: src,
79
+ name: name,
80
+ initial: initial,
81
+ title: title,
82
+ onClick: onClick,
83
+ size: size,
84
+ needTitle: needTitle,
85
+ palette: palette,
86
+ textPalette: textPalette,
87
+ customClass: customTextClass,
88
+ alternateSrc: alternateSrc
89
+ }, AvatarProps)), isPaid ? /*#__PURE__*/_react["default"].createElement("span", {
90
+ "data-title": paidTitle,
91
+ className: _AvatarUserModule["default"].paid,
92
+ "data-id": "paidUser",
93
+ "data-test-id": "paidUser"
94
+ }, /*#__PURE__*/_react["default"].createElement(_icons.Icon, {
95
+ name: "ZD-paiduser"
96
+ })) : null, isPortal ? /*#__PURE__*/_react["default"].createElement("span", {
97
+ "data-title": portalTitle,
98
+ className: _AvatarUserModule["default"].portal,
99
+ "data-id": "portalUser",
100
+ "data-test-id": "portalUser"
101
+ }, /*#__PURE__*/_react["default"].createElement(_icons.Icon, {
102
+ name: "ZD-globe1"
103
+ })) : null, isLocked ? /*#__PURE__*/_react["default"].createElement("span", {
104
+ "data-title": lockTitle,
105
+ className: _AvatarUserModule["default"].lock,
106
+ "data-id": "locked",
107
+ "data-test-id": "locked"
108
+ }, /*#__PURE__*/_react["default"].createElement(_icons.Icon, {
109
+ name: "ZD-lock01"
110
+ })) : null, needDelete ? /*#__PURE__*/_react["default"].createElement("span", {
111
+ className: _AvatarUserModule["default"]["delete"],
112
+ "data-id": "dltContactPhoto",
113
+ "data-test-id": "dltContactPhoto",
114
+ onClick: onDelete
115
+ }, /*#__PURE__*/_react["default"].createElement(_icons.Icon, {
116
+ name: "ZD-delete2",
117
+ size: "15"
118
+ })) : null);
119
+ }
56
120
 
57
- return _super.apply(this, arguments);
58
- }
59
-
60
- _createClass(AvatarUser, [{
61
- key: "render",
62
- value: function render() {
63
- var _this$props = this.props,
64
- src = _this$props.src,
65
- alternateSrc = _this$props.alternateSrc,
66
- name = _this$props.name,
67
- size = _this$props.size,
68
- onClick = _this$props.onClick,
69
- onDelete = _this$props.onDelete,
70
- title = _this$props.title,
71
- isPaid = _this$props.isPaid,
72
- isPortal = _this$props.isPortal,
73
- isLocked = _this$props.isLocked,
74
- dataId = _this$props.dataId,
75
- dataSelectorId = _this$props.dataSelectorId,
76
- needTitle = _this$props.needTitle,
77
- needDelete = _this$props.needDelete,
78
- initial = _this$props.initial,
79
- palette = _this$props.palette,
80
- textPalette = _this$props.textPalette,
81
- customTextClass = _this$props.customTextClass,
82
- iconName = _this$props.iconName,
83
- iconSize = _this$props.iconSize,
84
- iconClass = _this$props.iconClass,
85
- iconColor = _this$props.iconColor,
86
- i18nKeys = _this$props.i18nKeys,
87
- customProps = _this$props.customProps;
88
- var _customProps$AvatarUs = customProps.AvatarUserProps,
89
- AvatarUserProps = _customProps$AvatarUs === void 0 ? {} : _customProps$AvatarUs,
90
- _customProps$AvatarIc = customProps.AvatarIconProps,
91
- AvatarIconProps = _customProps$AvatarIc === void 0 ? {} : _customProps$AvatarIc,
92
- _customProps$AvatarPr = customProps.AvatarProps,
93
- AvatarProps = _customProps$AvatarPr === void 0 ? {} : _customProps$AvatarPr;
94
- var _i18nKeys$paidTitle = i18nKeys.paidTitle,
95
- paidTitle = _i18nKeys$paidTitle === void 0 ? 'Paid User' : _i18nKeys$paidTitle,
96
- _i18nKeys$portalTitle = i18nKeys.portalTitle,
97
- portalTitle = _i18nKeys$portalTitle === void 0 ? 'End User' : _i18nKeys$portalTitle,
98
- _i18nKeys$lockTitle = i18nKeys.lockTitle,
99
- lockTitle = _i18nKeys$lockTitle === void 0 ? 'Locked' : _i18nKeys$lockTitle;
100
- return /*#__PURE__*/_react["default"].createElement("div", _extends({
101
- className: "".concat(_AvatarUserModule["default"].container, " ").concat(_AvatarUserModule["default"][size]),
102
- "data-id": dataId || name || iconName,
103
- "data-test-id": dataId || name || iconName,
104
- "data-selector-id": dataSelectorId
105
- }, AvatarUserProps), iconName ? /*#__PURE__*/_react["default"].createElement(_AvatarIcon["default"], _extends({
106
- name: iconName,
107
- iconSize: iconSize,
108
- size: size,
109
- iconClass: iconClass,
110
- dataId: iconName,
111
- iconColor: iconColor,
112
- title: title
113
- }, AvatarIconProps)) : /*#__PURE__*/_react["default"].createElement(_Avatar["default"], _extends({
114
- src: src,
115
- name: name,
116
- initial: initial,
117
- title: title,
118
- onClick: onClick,
119
- size: size,
120
- needTitle: needTitle,
121
- palette: palette,
122
- textPalette: textPalette,
123
- customClass: customTextClass,
124
- alternateSrc: alternateSrc
125
- }, AvatarProps)), isPaid ? /*#__PURE__*/_react["default"].createElement("span", {
126
- "data-title": paidTitle,
127
- className: _AvatarUserModule["default"].paid,
128
- "data-id": "paidUser",
129
- "data-test-id": "paidUser"
130
- }, /*#__PURE__*/_react["default"].createElement(_icons.Icon, {
131
- name: "ZD-paiduser"
132
- })) : null, isPortal ? /*#__PURE__*/_react["default"].createElement("span", {
133
- "data-title": portalTitle,
134
- className: _AvatarUserModule["default"].portal,
135
- "data-id": "portalUser",
136
- "data-test-id": "portalUser"
137
- }, /*#__PURE__*/_react["default"].createElement(_icons.Icon, {
138
- name: "ZD-globe1"
139
- })) : null, isLocked ? /*#__PURE__*/_react["default"].createElement("span", {
140
- "data-title": lockTitle,
141
- className: _AvatarUserModule["default"].lock,
142
- "data-id": "locked",
143
- "data-test-id": "locked"
144
- }, /*#__PURE__*/_react["default"].createElement(_icons.Icon, {
145
- name: "ZD-lock01"
146
- })) : null, needDelete ? /*#__PURE__*/_react["default"].createElement("span", {
147
- className: _AvatarUserModule["default"]["delete"],
148
- "data-id": "dltContactPhoto",
149
- "data-test-id": "dltContactPhoto",
150
- onClick: onDelete
151
- }, /*#__PURE__*/_react["default"].createElement(_icons.Icon, {
152
- name: "ZD-delete2",
153
- size: "15"
154
- })) : null);
155
- }
156
- }]);
157
-
158
- return AvatarUser;
159
- }(_react["default"].Component);
160
-
161
- exports["default"] = AvatarUser;
162
121
  AvatarUser.propTypes = _propTypes.propTypes;
163
- AvatarUser.defaultProps = _defaultProps.defaultProps; // if (__DOCS__) {
164
- // AvatarUser.docs = {
165
- // componentGroup: 'Avatar Group'
166
- // };
167
- // }
122
+ AvatarUser.defaultProps = _defaultProps.defaultProps;
@@ -1,11 +1,9 @@
1
1
  "use strict";
2
2
 
3
- function _typeof(obj) { "@babel/helpers - typeof"; return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (obj) { return typeof obj; } : function (obj) { return obj && "function" == typeof Symbol && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }, _typeof(obj); }
4
-
5
3
  Object.defineProperty(exports, "__esModule", {
6
4
  value: true
7
5
  });
8
- exports["default"] = void 0;
6
+ exports["default"] = AvatarWithTeam;
9
7
 
10
8
  var _react = _interopRequireDefault(require("react"));
11
9
 
@@ -23,132 +21,89 @@ function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "d
23
21
 
24
22
  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); }
25
23
 
26
- function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } }
27
-
28
- function _defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } }
29
-
30
- function _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); Object.defineProperty(Constructor, "prototype", { writable: false }); return Constructor; }
31
-
32
- function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function"); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, writable: true, configurable: true } }); Object.defineProperty(subClass, "prototype", { writable: false }); if (superClass) _setPrototypeOf(subClass, superClass); }
33
-
34
- function _setPrototypeOf(o, p) { _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function _setPrototypeOf(o, p) { o.__proto__ = p; return o; }; return _setPrototypeOf(o, p); }
35
-
36
- function _createSuper(Derived) { var hasNativeReflectConstruct = _isNativeReflectConstruct(); return function _createSuperInternal() { var Super = _getPrototypeOf(Derived), result; if (hasNativeReflectConstruct) { var NewTarget = _getPrototypeOf(this).constructor; result = Reflect.construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return _possibleConstructorReturn(this, result); }; }
37
-
38
- function _possibleConstructorReturn(self, call) { if (call && (_typeof(call) === "object" || typeof call === "function")) { return call; } else if (call !== void 0) { throw new TypeError("Derived constructors may only return object or undefined"); } return _assertThisInitialized(self); }
39
-
40
- function _assertThisInitialized(self) { if (self === void 0) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return self; }
24
+ function AvatarWithTeam(props) {
25
+ var name = props.name,
26
+ size = props.size,
27
+ src = props.src,
28
+ teamName = props.teamName,
29
+ isTeam = props.isTeam,
30
+ _props$needTitle = props.needTitle,
31
+ needTitle = _props$needTitle === void 0 ? false : _props$needTitle,
32
+ initial = props.initial,
33
+ title = props.title,
34
+ palette = props.palette,
35
+ textPalette = props.textPalette,
36
+ customTextClass = props.customTextClass,
37
+ teamClassName = props.teamClassName,
38
+ borderOnActive = props.borderOnActive,
39
+ customProps = props.customProps,
40
+ dataSelectorId = props.dataSelectorId,
41
+ teamBorderActive = props.teamBorderActive;
42
+ var _customProps$AvatarWi = customProps.AvatarWithTeamProps,
43
+ AvatarWithTeamProps = _customProps$AvatarWi === void 0 ? {} : _customProps$AvatarWi,
44
+ _customProps$Avatar1P = customProps.Avatar1Props,
45
+ Avatar1Props = _customProps$Avatar1P === void 0 ? {} : _customProps$Avatar1P,
46
+ _customProps$AvatarTe = customProps.AvatarTeam1Props,
47
+ AvatarTeam1Props = _customProps$AvatarTe === void 0 ? {} : _customProps$AvatarTe,
48
+ _customProps$Avatar2P = customProps.Avatar2Props,
49
+ Avatar2Props = _customProps$Avatar2P === void 0 ? {} : _customProps$Avatar2P,
50
+ _customProps$AvatarTe2 = customProps.AvatarTeam2Props,
51
+ AvatarTeam2Props = _customProps$AvatarTe2 === void 0 ? {} : _customProps$AvatarTe2;
52
+ return /*#__PURE__*/_react["default"].createElement("span", _extends({
53
+ className: "".concat(_AvatarWithTeamModule["default"].container, " "),
54
+ "data-id": "avatarWithTeamId",
55
+ "data-test-id": "avatarWithTeamId",
56
+ "data-selector-id": dataSelectorId
57
+ }, AvatarWithTeamProps), isTeam && teamName ? /*#__PURE__*/_react["default"].createElement(_Avatar["default"], _extends({
58
+ name: name,
59
+ src: src,
60
+ size: size,
61
+ initial: initial,
62
+ needTitle: needTitle,
63
+ palette: palette,
64
+ textPalette: textPalette,
65
+ customClass: customTextClass,
66
+ borderOnActive: borderOnActive
67
+ }, Avatar1Props)) : isTeam ? /*#__PURE__*/_react["default"].createElement(_AvatarTeam["default"], _extends({
68
+ name: name,
69
+ src: src,
70
+ size: size,
71
+ needTitle: needTitle,
72
+ title: needTitle ? title : undefined,
73
+ palette: palette,
74
+ textPalette: textPalette,
75
+ customClass: {
76
+ customAvatar: customTextClass
77
+ },
78
+ borderOnActive: borderOnActive
79
+ }, AvatarTeam1Props)) : /*#__PURE__*/_react["default"].createElement(_Avatar["default"], _extends({
80
+ name: name,
81
+ src: src,
82
+ size: size,
83
+ initial: initial,
84
+ needTitle: needTitle,
85
+ palette: palette,
86
+ textPalette: textPalette,
87
+ customClass: customTextClass,
88
+ borderOnActive: borderOnActive
89
+ }, Avatar2Props)), teamName ? /*#__PURE__*/_react["default"].createElement("span", {
90
+ className: "".concat(_AvatarWithTeamModule["default"].teamAvatar, " ").concat(teamClassName, " "),
91
+ "data-id": "teamNameTestId",
92
+ "data-test-id": "teamNameTestId",
93
+ "data-title": needTitle ? title : undefined
94
+ }, /*#__PURE__*/_react["default"].createElement(_AvatarTeam["default"], _extends({
95
+ name: teamName,
96
+ size: "small",
97
+ palette: palette,
98
+ textPalette: textPalette,
99
+ isFilled: true,
100
+ needTitle: needTitle,
101
+ customClass: {
102
+ customAvatar: customTextClass
103
+ },
104
+ borderOnActive: teamBorderActive
105
+ }, AvatarTeam2Props))) : null);
106
+ }
41
107
 
42
- function _isNativeReflectConstruct() { if (typeof Reflect === "undefined" || !Reflect.construct) return false; if (Reflect.construct.sham) return false; if (typeof Proxy === "function") return true; try { Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); return true; } catch (e) { return false; } }
43
-
44
- function _getPrototypeOf(o) { _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf.bind() : function _getPrototypeOf(o) { return o.__proto__ || Object.getPrototypeOf(o); }; return _getPrototypeOf(o); }
45
-
46
- var AvatarWithTeam = /*#__PURE__*/function (_React$Component) {
47
- _inherits(AvatarWithTeam, _React$Component);
48
-
49
- var _super = _createSuper(AvatarWithTeam);
50
-
51
- function AvatarWithTeam() {
52
- _classCallCheck(this, AvatarWithTeam);
53
-
54
- return _super.apply(this, arguments);
55
- }
56
-
57
- _createClass(AvatarWithTeam, [{
58
- key: "render",
59
- value: function render() {
60
- var _this$props = this.props,
61
- name = _this$props.name,
62
- size = _this$props.size,
63
- src = _this$props.src,
64
- teamName = _this$props.teamName,
65
- isTeam = _this$props.isTeam,
66
- _this$props$needTitle = _this$props.needTitle,
67
- needTitle = _this$props$needTitle === void 0 ? false : _this$props$needTitle,
68
- initial = _this$props.initial,
69
- title = _this$props.title,
70
- palette = _this$props.palette,
71
- textPalette = _this$props.textPalette,
72
- customTextClass = _this$props.customTextClass,
73
- teamClassName = _this$props.teamClassName,
74
- borderOnActive = _this$props.borderOnActive,
75
- customProps = _this$props.customProps,
76
- dataSelectorId = _this$props.dataSelectorId,
77
- teamBorderActive = _this$props.teamBorderActive;
78
- var _customProps$AvatarWi = customProps.AvatarWithTeamProps,
79
- AvatarWithTeamProps = _customProps$AvatarWi === void 0 ? {} : _customProps$AvatarWi,
80
- _customProps$Avatar1P = customProps.Avatar1Props,
81
- Avatar1Props = _customProps$Avatar1P === void 0 ? {} : _customProps$Avatar1P,
82
- _customProps$AvatarTe = customProps.AvatarTeam1Props,
83
- AvatarTeam1Props = _customProps$AvatarTe === void 0 ? {} : _customProps$AvatarTe,
84
- _customProps$Avatar2P = customProps.Avatar2Props,
85
- Avatar2Props = _customProps$Avatar2P === void 0 ? {} : _customProps$Avatar2P,
86
- _customProps$AvatarTe2 = customProps.AvatarTeam2Props,
87
- AvatarTeam2Props = _customProps$AvatarTe2 === void 0 ? {} : _customProps$AvatarTe2;
88
- return /*#__PURE__*/_react["default"].createElement("span", _extends({
89
- className: "".concat(_AvatarWithTeamModule["default"].container, " "),
90
- "data-id": "avatarWithTeamId",
91
- "data-test-id": "avatarWithTeamId",
92
- "data-selector-id": dataSelectorId
93
- }, AvatarWithTeamProps), isTeam && teamName ? /*#__PURE__*/_react["default"].createElement(_Avatar["default"], _extends({
94
- name: name,
95
- src: src,
96
- size: size,
97
- initial: initial,
98
- needTitle: needTitle,
99
- palette: palette,
100
- textPalette: textPalette,
101
- customClass: customTextClass,
102
- borderOnActive: borderOnActive
103
- }, Avatar1Props)) : isTeam ? /*#__PURE__*/_react["default"].createElement(_AvatarTeam["default"], _extends({
104
- name: name,
105
- src: src,
106
- size: size,
107
- needTitle: needTitle,
108
- title: needTitle ? title : undefined,
109
- palette: palette,
110
- textPalette: textPalette,
111
- customClass: {
112
- customAvatar: customTextClass
113
- },
114
- borderOnActive: borderOnActive
115
- }, AvatarTeam1Props)) : /*#__PURE__*/_react["default"].createElement(_Avatar["default"], _extends({
116
- name: name,
117
- src: src,
118
- size: size,
119
- initial: initial,
120
- needTitle: needTitle,
121
- palette: palette,
122
- textPalette: textPalette,
123
- customClass: customTextClass,
124
- borderOnActive: borderOnActive
125
- }, Avatar2Props)), teamName ? /*#__PURE__*/_react["default"].createElement("span", {
126
- className: "".concat(_AvatarWithTeamModule["default"].teamAvatar, " ").concat(teamClassName, " "),
127
- "data-id": "teamNameTestId",
128
- "data-test-id": "teamNameTestId",
129
- "data-title": needTitle ? title : undefined
130
- }, /*#__PURE__*/_react["default"].createElement(_AvatarTeam["default"], _extends({
131
- name: teamName,
132
- size: "small",
133
- palette: palette,
134
- textPalette: textPalette,
135
- isFilled: true,
136
- needTitle: needTitle,
137
- customClass: {
138
- customAvatar: customTextClass
139
- },
140
- borderOnActive: teamBorderActive
141
- }, AvatarTeam2Props))) : null);
142
- }
143
- }]);
144
-
145
- return AvatarWithTeam;
146
- }(_react["default"].Component);
147
-
148
- exports["default"] = AvatarWithTeam;
149
108
  AvatarWithTeam.defaultProps = _defaultProps.defaultProps;
150
- AvatarWithTeam.propTypes = _propTypes.propTypes; // if (__DOCS__) {
151
- // AvatarWithTeam.docs = {
152
- // componentGroup: 'Avatar Group'
153
- // };
154
- // }
109
+ AvatarWithTeam.propTypes = _propTypes.propTypes;