import { r as l, ai as s, j as e, aj as d, ak as u, aQ as c, al as m, am as B } from "./index-6wLGsgHc.js";
function p(i) {
  const {
    disabled: n,
    element: t,
    widgetMgr: r,
    fragmentId: o
  } = i;
  let a = s.SECONDARY;
  return t.type === "primary" ? a = s.PRIMARY : t.type === "tertiary" && (a = s.TERTIARY), /* @__PURE__ */ e.jsx(d, {
    className: "stButton",
    "data-testid": "stButton",
    children: /* @__PURE__ */ e.jsx(u, {
      help: t.help,
      containerWidth: !0,
      children: /* @__PURE__ */ e.jsx(c, {
        kind: a,
        size: m.SMALL,
        disabled: n,
        containerWidth: !0,
        onClick: () => r.setTriggerValue(t, {
          fromUi: !0
        }, o),
        children: /* @__PURE__ */ e.jsx(B, {
          icon: t.icon,
          label: t.label
        })
      })
    })
  });
}
const h = l.memo(p);
export {
  h as default
};
//# sourceMappingURL=index-C_q9gQa7-DTvt0WJo.js.map
