@hoddy-ui/core 2.5.45 → 2.5.47

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.
@@ -54,6 +54,7 @@ interface AvatarProps {
54
54
  source?: any;
55
55
  size?: number;
56
56
  style?: ViewStyle;
57
+ icon?: ReactNode;
57
58
  }
58
59
  interface ButtonProps {
59
60
  color?: colorTypes;
@@ -54,6 +54,7 @@ interface AvatarProps {
54
54
  source?: any;
55
55
  size?: number;
56
56
  style?: ViewStyle;
57
+ icon?: ReactNode;
57
58
  }
58
59
  interface ButtonProps {
59
60
  color?: colorTypes;
@@ -703,7 +703,8 @@ var Avatar = ({
703
703
  variant = "contained",
704
704
  source,
705
705
  size = 48,
706
- style = {}
706
+ style = {},
707
+ icon
707
708
  }) => {
708
709
  const colors2 = useColors();
709
710
  const [imageError, setImageError] = (0, import_react7.useState)(false);
@@ -733,7 +734,7 @@ var Avatar = ({
733
734
  source,
734
735
  onError: () => setImageError(true)
735
736
  }
736
- ) : label ? /* @__PURE__ */ import_react7.default.createElement(Typography_default, { style: { color: colors2[color].text } }, label[0]) : /* @__PURE__ */ import_react7.default.createElement(import_vector_icons2.AntDesign, { name: "user", color: "#fff", size: Math.round(size / 1.5) }));
737
+ ) : label ? /* @__PURE__ */ import_react7.default.createElement(Typography_default, { style: { color: colors2[color].text } }, label[0]) : icon ? icon : /* @__PURE__ */ import_react7.default.createElement(import_vector_icons2.Ionicons, { name: "person", color: "#fff", size: Math.round(size / 1.5) }));
737
738
  };
738
739
  var Avatar_default = Avatar;
739
740