import { jsxs as c, jsx as t, Fragment as a } from "react/jsx-runtime";
const x = (r) => {
  const { label: l, placeholder: o, selectedItem: d, options: i, showSelectedItemIcon: p, showUnselectedItemIcons: h } = r, m = (e, n) => {
    const I = e.filter((s) => !s.header).map((s) => /* @__PURE__ */ t(
      "span",
      {
        className: `${n && n.id === s.id ? "" : "inactiveIcon"}`,
        children: s.icon
      },
      s.id
    ));
    return /* @__PURE__ */ t(a, { children: I });
  };
  return /* @__PURE__ */ c("span", { className: "selected-option-text", children: [
    l && /* @__PURE__ */ c("span", { className: "selected-option-text-label", children: [
      l,
      ":"
    ] }),
    ((e, n) => h ? m(i, e) : e ? /* @__PURE__ */ c(a, { children: [
      e.icon && /* @__PURE__ */ t("span", { children: e.icon }),
      !p && e.label
    ] }) : n ? /* @__PURE__ */ t("span", { className: "placeholder", children: n }) : " ")(d, o)
  ] });
};
export {
  x as default
};
//# sourceMappingURL=SelectedOption.js.map
