import { useMemo as a } from "../external/.pnpm/preact@10.28.2/node_modules/preact/hooks/dist/hooks.module.js";
import g from "../core/Context/preact/useCoreContext.js";
import { EMPTY_OBJECT as p } from "../utils/value/constants.js";
const u = "https://cdf6519016.cdn.adyen.com/checkoutshopper/", C = ({
  name: e,
  resourceContext: o,
  imageFolder: t = "logos/",
  parentFolder: r = "",
  extension: s = "svg",
  size: c = "",
  subFolder: n = ""
}) => {
  const m = `/images/${t}/${n}/${r}/${e}${c}.${s}`.replace(/\/+/g, "/");
  return `${o}${m}`;
}, d = ({ options: e = p, name: o }) => {
  const { loadingContext: t } = g();
  return a(
    () => C({
      resourceContext: u,
      name: o,
      ...e
    }),
    [t, o, e]
  );
};
export {
  d as useImageUrl
};
