import { CurrencyType as p } from "./accelbyte-widgets185.mjs";
import { RegionDataItemHelper as l } from "./accelbyte-widgets388.mjs";
import n from "classnames";
import e from "react";
import { Trans as E } from "react-i18next";
import "./accelbyte-widgets546.mjs";
const P = ({ className: o, paymentOptions: c }) => {
  const m = l.isFree(c.map((t) => t.regionData));
  return /* @__PURE__ */ e.createElement("div", { className: n(o, "priceList") }, m && /* @__PURE__ */ e.createElement("div", null, /* @__PURE__ */ e.createElement(E, { i18nKey: "CatalogPurchaseWidget.freeItem" }, "FREE")), !m && c.map(({ regionData: t, currencySymbol: s, finalPrice: r, currencyType: u, originalPrice: a }, d) => {
    const i = l.calculateDiscountPercentage(t);
    return /* @__PURE__ */ e.createElement("div", { className: "price", key: `${t.currencyCode}-${d}` }, /* @__PURE__ */ e.createElement("div", { className: n("payablePrice ", u === p.enum.VIRTUAL && "virtual") }, /* @__PURE__ */ e.createElement("div", null, `${s} ${r}`), r !== a && i > 0 && /* @__PURE__ */ e.createElement("div", { className: "discountPercentage" }, "-", i, "%")), r !== a && /* @__PURE__ */ e.createElement("s", { className: "originalPriceStrikethrough" }, /* @__PURE__ */ e.createElement("div", { className: "originalPrice" }, `${s} ${a}`)));
  }));
};
export {
  P as PriceList
};
