47 lines
1.8 KiB
TypeScript
47 lines
1.8 KiB
TypeScript
// Metro module 8465 (f8466).
|
|
import { BadgeCategory, getBadgeCategory } from "../BadgeCategory";
|
|
import Module8466 from "../../../_bundle/Module8466";
|
|
import Module8467 from "../../../_bundle/Module8467";
|
|
import Module8468 from "../../../_bundle/Module8468";
|
|
import Module8469 from "../../../_bundle/Module8469";
|
|
import Module8470 from "../../../_bundle/Module8470";
|
|
import Module8471 from "../../../_bundle/Module8471";
|
|
import Module8472 from "../../../_bundle/Module8472";
|
|
import Module8473 from "../../../_bundle/Module8473";
|
|
import { isThemeLight } from "../../../design/shared";
|
|
import { getGuildTraits } from "../GuildTraits";
|
|
const r12 = {};
|
|
r12[BadgeCategory.STAFF] = {
|
|
imageSource: Module8466
|
|
};
|
|
r12[BadgeCategory.PARTNERED] = {
|
|
imageSource: Module8467
|
|
};
|
|
r12[BadgeCategory.VERIFIED] = {
|
|
imageSource: Module8466
|
|
};
|
|
r12[BadgeCategory.COMMUNITY] = {
|
|
imageSource: Module8468,
|
|
imageSourceLight: Module8469,
|
|
premiumImageSource: Module8470
|
|
};
|
|
r12[BadgeCategory.DISCOVERABLE] = {
|
|
imageSource: Module8471,
|
|
imageSourceLight: Module8472,
|
|
premiumImageSource: Module8473
|
|
};
|
|
r12[BadgeCategory.VERIFIED_AND_PARTNERED] = {
|
|
imageSource: Module8466
|
|
};
|
|
r12[BadgeCategory.NONE] = {};
|
|
let c5424_2 = r12;
|
|
export { c5424_2 as badgeVariants };
|
|
export function resolveImageSource(a0, a1, a2) {
|
|
return a1.premium && a0.premiumImageSource != null ? a0.premiumImageSource : isThemeLight(a2) && a0.imageSourceLight != null ? a0.imageSourceLight : a0.imageSource;
|
|
}
|
|
export function getGuildBadgeImageSource(a0, a1) {
|
|
const guildTraits = getGuildTraits(a0);
|
|
const r16 = c5424_2[getBadgeCategory(guildTraits)];
|
|
return r16 == null ? null : guildTraits.premium && r16.premiumImageSource != null ? r16.premiumImageSource : isThemeLight(a1) && r16.imageSourceLight != null ? r16.imageSourceLight : r16.imageSource;
|
|
}
|