"use strict";
Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
const jsxRuntime = require("react/jsx-runtime");
const utilities = require("@contember/utilities");
const md5 = require("blueimp-md5");
const Avatar = (props) => {
  const { size = 1, shape = "Circle" } = props;
  const email = props.email || "";
  return /* @__PURE__ */ jsxRuntime.jsx("div", { className: utilities.listClassName(["avatar", `avatar-size${size}`, `avatar-shape${shape}`]), children: /* @__PURE__ */ jsxRuntime.jsx(
    "img",
    {
      className: "avatar-image",
      src: `https://s.gravatar.com/avatar/${md5(email.trim().toLowerCase())}?s=${size * 40}&d=mp`,
      alt: email.substring(0, 1).toUpperCase()
    }
  ) });
};
exports.Avatar = Avatar;
//# sourceMappingURL=Avatar.cjs.map
