import { jsx as o } from "../../../../../external/.pnpm/preact@10.28.2/node_modules/preact/jsx-runtime/dist/jsxRuntime.module.js";
import { Image as m } from "../../../../internal/Image/Image.js";
import { Tag as s } from "../../../../internal/Tag/Tag.js";
import { TagVariant as t } from "../../../../internal/Tag/types.js";
import { TypographyVariant as n } from "../../../../internal/Typography/types.js";
import T from "../../../../internal/Typography/Typography.js";
import { useResponsiveContainer as f, containerQueries as l } from "../../../../../hooks/useResponsiveContainer.js";
import { parsePaymentMethodType as p } from "../utils.js";
import { PAYMENT_METHOD_CLASS as c, PAYMENT_METHOD_LOGO_CONTAINER_CLASS as g, PAYMENT_METHOD_LOGO_CLASS as _ } from "./constants.js";
import N from "../../../../../core/Context/preact/useCoreContext.js";
import { Fragment as O } from "../../../../../external/.pnpm/preact@10.28.2/node_modules/preact/dist/preact.module.js";
const P = ({ paymentMethod: r, bankAccount: a }) => {
  const { i18n: i } = N(), e = f(l.down.xs);
  return /* @__PURE__ */ o("div", { className: c, children: r || a ? /* @__PURE__ */ o(O, { children: [
    /* @__PURE__ */ o("div", { className: g, children: /* @__PURE__ */ o(
      m,
      {
        name: r ? r.type : "bankTransfer",
        alt: r ? r.type : "bankTransfer",
        folder: "logos/",
        className: _
      }
    ) }),
    /* @__PURE__ */ o(T, { variant: n.BODY, stronger: e, children: r ? p(r) : a?.accountNumberLastFourDigits })
  ] }) : /* @__PURE__ */ o(s, { label: i.get("common.tags.noData"), variant: t.LIGHT_WITH_OUTLINE }) });
};
export {
  P as default
};
