@aloudata/aloudata-design 2.17.1 → 2.17.2
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.
|
@@ -26,6 +26,9 @@ var Avatar = function Avatar(props) {
|
|
|
26
26
|
return AVATAR_SIZE_MAP[size] || 32;
|
|
27
27
|
}, [size]);
|
|
28
28
|
var getChildren = useCallback(function () {
|
|
29
|
+
if (_.isEmpty(children)) {
|
|
30
|
+
return null;
|
|
31
|
+
}
|
|
29
32
|
if (typeof children === 'string') {
|
|
30
33
|
return children[ZERO].toLocaleUpperCase();
|
|
31
34
|
}
|
|
@@ -47,7 +50,7 @@ var Avatar = function Avatar(props) {
|
|
|
47
50
|
if (icon) {
|
|
48
51
|
return icon;
|
|
49
52
|
}
|
|
50
|
-
if (!_.
|
|
53
|
+
if (!_.isEmpty(children)) {
|
|
51
54
|
return /*#__PURE__*/React.createElement("div", {
|
|
52
55
|
style: {
|
|
53
56
|
backgroundColor: bgColor,
|