import { jsxs as c, jsx as e } from "react/jsx-runtime";
import { Button as f } from "./index-Button.js";
import { ComponentContainer as y } from "./index-ComponentContainer.js";
import { Icon as n, IconSize as l } from "./index-Icon.js";
import { IconNames as o } from "./index-IconNames.js";
import { Render as s } from "./index-Render.js";
import { Text as d, FontWeights as C, TextTypes as h } from "./index-Text.js";
import "react";
import a from "./index-ActionBarMessage.module.scss.js";
const N = (t) => {
  const {
    type: i,
    title: p,
    description: m,
    button: r
  } = t;
  return c(y, {
    testId: "ActionBarMessage_Container",
    className: a.container,
    children: [c("div", {
      className: a.infoBox,
      children: [e("div", {
        children: e(g, {
          type: i
        })
      }), c("div", {
        children: [e(s, {
          if: !!p,
          children: e(d, {
            type: h.text,
            fontWeight: C.medium,
            children: p
          })
        }), e(s, {
          if: !!m,
          children: e("div", {
            className: a.description,
            children: e(d, {
              type: h.textHelp,
              children: m
            })
          })
        })]
      })]
    }), e(s, {
      if: !!r,
      children: e(f, {
        iconRight: o.arrowRight,
        onClick: r == null ? void 0 : r.onClick,
        ...r == null ? void 0 : r.props,
        children: r == null ? void 0 : r.text
      })
    })]
  });
}, g = (t) => {
  const {
    type: i
  } = t;
  return i === "info" ? e(n, {
    type: l.small,
    hasCircle: !0,
    fillColor: "--p100",
    color: "--p500",
    children: o.info
  }) : i === "success" ? e(n, {
    type: l.small,
    hasCircle: !0,
    fillColor: "--s100",
    color: "--s500",
    children: o.check
  }) : i === "warning" ? e(n, {
    type: l.large,
    hasCircle: !1,
    fillColor: "--w100",
    color: "--w500",
    children: o.warning
  }) : i === "error" ? e(n, {
    type: l.small,
    hasCircle: !0,
    fillColor: "--e100",
    color: "--e500",
    children: o.exclamation
  }) : null;
};
export {
  N as ActionBarMessage
};
