import { useMemo as p } from "react";
import { u as g } from "./useDiscoveryConfigs-cf63cd60.mjs";
import { A as m } from "./FetchConfigsUtils-476a602b.mjs";
import { u as L } from "./useAppConfigs-0fb5df89.mjs";
function A(c, s) {
  const {
    state: { discoveryConfigData: a }
  } = g(), {
    state: { playerPortalConfigData: t, launcherData: n, twitchDropData: e }
  } = L();
  return {
    companyLogo: p(() => {
      var u;
      let r = null;
      switch (c) {
        case m.LAUNCHER: {
          const o = n == null ? void 0 : n.logoVariant.data;
          r = o ? o[s] : null;
          break;
        }
        case m.PP: {
          const o = t == null ? void 0 : t.logoVariant.data;
          r = o ? o[s] : null;
          break;
        }
        case m.TWITCHDROP: {
          const o = e == null ? void 0 : e.logoVariant.data;
          r = o ? o[s] : null;
          break;
        }
      }
      const l = r ?? (a == null ? void 0 : a.companyLogo.data.defaultIndex) ?? 0;
      return ((u = a == null ? void 0 : a.companyLogo.data.images[l]) == null ? void 0 : u.url) || "";
    }, [a, t, n, e])
  };
}
export {
  A as u
};
