@bze/bze-ui-kit 0.4.2 → 0.4.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.mjs CHANGED
@@ -1394,19 +1394,34 @@ var EXCLUDED_MARKETS = {
1394
1394
  // src/constants/ecosystem.ts
1395
1395
  import { LuGlobe, LuCoins, LuChartColumn, LuFlame, LuFactory } from "react-icons/lu";
1396
1396
  var ECOSYSTEM_MENU_LABEL = "Other";
1397
- var ALL_APPS = [
1398
- { name: "Website", href: "https://getbze.com", disabled: false, icon: LuGlobe },
1399
- { name: "Staking", href: "https://staking.getbze.com", disabled: false, icon: LuCoins },
1400
- { name: "DEX", href: "https://dex.getbze.com", disabled: false, icon: LuChartColumn },
1401
- { name: "Burner", href: "https://burner.getbze.com", disabled: false, icon: LuFlame },
1402
- { name: "Factory", href: "#", disabled: true, icon: LuFactory }
1397
+ var DEFAULT_APPS = [
1398
+ { key: "website", name: "Website", href: "https://getbze.com", disabled: false, icon: LuGlobe },
1399
+ { key: "staking", name: "Staking", href: "https://staking.getbze.com", disabled: false, icon: LuCoins },
1400
+ { key: "dex", name: "DEX", href: "https://dex.getbze.com", disabled: false, icon: LuChartColumn },
1401
+ { key: "burner", name: "Burner", href: "https://burner.getbze.com", disabled: false, icon: LuFlame },
1402
+ { key: "factory", name: "Factory", href: "#", disabled: true, icon: LuFactory }
1403
1403
  ];
1404
- var getEcosystemApps = () => {
1405
- const currentHost = process.env.NEXT_PUBLIC_SITE_URL || "";
1406
- if (!currentHost) {
1407
- return ALL_APPS;
1404
+ var getExcludedKeys = () => {
1405
+ const raw = process.env.NEXT_PUBLIC_ECOSYSTEM_EXCLUDED || "";
1406
+ if (!raw.trim()) {
1407
+ return /* @__PURE__ */ new Set();
1408
1408
  }
1409
- return ALL_APPS.filter((app) => app.href !== currentHost);
1409
+ return new Set(raw.split(",").map((k) => k.trim().toLowerCase()).filter(Boolean));
1410
+ };
1411
+ var getEcosystemApps = () => {
1412
+ const excluded = getExcludedKeys();
1413
+ return DEFAULT_APPS.filter((app) => !excluded.has(app.key)).map((app) => {
1414
+ const envKey = app.key.toUpperCase();
1415
+ const linkOverride = process.env[`NEXT_PUBLIC_ECOSYSTEM_LINK_${envKey}`];
1416
+ const labelOverride = process.env[`NEXT_PUBLIC_ECOSYSTEM_LABEL_${envKey}`];
1417
+ return {
1418
+ key: app.key,
1419
+ name: labelOverride || app.name,
1420
+ href: linkOverride || app.href,
1421
+ disabled: linkOverride ? false : app.disabled,
1422
+ icon: app.icon
1423
+ };
1424
+ });
1410
1425
  };
1411
1426
 
1412
1427
  // src/constants/keplr.ts