"use strict";
var import_Message = require("../Message.css");
const jsxRuntime = require("react/jsx-runtime");
const kit_Icon = require("./Icon.cjs");
const kit_Theme_UI = require("./Theme/UI.cjs");
require("./Theme/themeUtils.cjs");
require("./Theme/themes.cjs");
const kit_Typography = require("../Typography-g8d4JFSj.cjs");
const base = "Message_base_5b975";
const description = "Message_description_5b975";
const css = {
  base,
  description
};
const Message = ({ action, description: description2, title, icon }) => {
  const {
    themeSettings: { className: themeClass }
  } = kit_Theme_UI.useTheme();
  const classes = [css.base, themeClass];
  const getIcon = (icon2) => {
    if (typeof icon2 === "string") {
      return /* @__PURE__ */ jsxRuntime.jsx(kit_Icon.default, { decorative: true, name: icon2, size: "jumbo" });
    } else {
      return icon2;
    }
  };
  return /* @__PURE__ */ jsxRuntime.jsxs("div", { className: classes.join(" "), children: [
    icon && getIcon(icon),
    title && /* @__PURE__ */ jsxRuntime.jsx(kit_Typography.Title, { children: title }),
    description2 && /* @__PURE__ */ jsxRuntime.jsx("span", { className: css.description, children: description2 }),
    action
  ] });
};
module.exports = Message;
