"use strict";Object.defineProperty(exports, "__esModule", {value: true});// tmp-babel/profiles/web/profile-popover/CurrentProfile/index.js
var _authentication = require('@baseapp-frontend/authentication');
var _avatars = require('@baseapp-frontend/design-system/components/web/avatars');
var _material = require('@mui/material');
var _jsxruntime = require('react/jsx-runtime');
var CurrentProfile = function CurrentProfile2() {
  var _profile$image, _profile$urlPath;
  var _useCurrentProfile = _authentication.useCurrentProfile.call(void 0, ), profile = _useCurrentProfile.currentProfile;
  if (!profile) return null;
  return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _material.Box, {
    sx: {
      m: 1.5,
      mb: 0,
      px: 1,
      py: 0.75,
      gap: 1.5
    },
    display: "flex",
    alignItems: "center",
    children: [/* @__PURE__ */ _jsxruntime.jsx.call(void 0, _avatars.AvatarWithPlaceholder, {
      width: 40,
      height: 40,
      src: (_profile$image = profile === null || profile === void 0 ? void 0 : profile.image) !== null && _profile$image !== void 0 ? _profile$image : "",
      alt: "Current profile avatar",
      color: "secondary"
    }), /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _material.Box, {
      display: "flex",
      flexDirection: "column",
      flexGrow: 1,
      overflow: "hidden",
      children: [/* @__PURE__ */ _jsxruntime.jsx.call(void 0, _material.Typography, {
        component: "p",
        variant: "subtitle2",
        noWrap: true,
        children: profile.name
      }), (profile === null || profile === void 0 ? void 0 : profile.urlPath) && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _material.Typography, {
        variant: "body2",
        sx: {
          color: "text.secondary"
        },
        noWrap: true,
        children: profile === null || profile === void 0 || (_profile$urlPath = profile.urlPath) === null || _profile$urlPath === void 0 ? void 0 : _profile$urlPath.replace("/", "")
      })]
    })]
  });
};
var CurrentProfile_default = CurrentProfile;



exports.CurrentProfile_default = CurrentProfile_default;
//# sourceMappingURL=chunk-FA4CYO2O.js.map