decord/source/modules/guilds_bar/native/GuildsBarGeoRestrictedGuild.tsx

83 lines
4.1 KiB
TypeScript
Raw Normal View History

2026-09-01 10:26:29 +00:00
// Module ID: 15937
// Function ID: 15938
2026-07-29 08:29:29 +00:00
// Name: items
2026-09-01 10:26:29 +00:00
// Dependencies: [19, 15876, 21, 4478, 712, 15888, 15885, 1431, 6004, 4857, 1236, 9728, 15938, 15907, 5493, 2]
2026-07-20 16:05:17 +00:00
2026-09-01 10:26:29 +00:00
// Module 15937 (items)
2026-08-24 06:08:38 +00:00
import ThemesDefault from "Themes" /* 712 */;
2026-08-31 15:47:37 +00:00
import getAvatarURLDefault from "getAvatarURL" /* 1431 */;
2026-09-01 10:26:29 +00:00
import UnreadIndicatorDefault from "UnreadIndicator" /* 15885 */;
import computeGuildsBarCutoutDefault from "computeGuildsBarCutout" /* 15888 */;
import GuildRowWrapperDefault from "GuildRowWrapper" /* 15907 */;
import _modDef15938 from "module_15938" /* 15938 */;
2026-08-24 06:08:38 +00:00
import importAllResult from "noop" /* 19 */;
2026-09-01 10:26:29 +00:00
import { GUILD_ITEM_BADGE_SIZE } from "GUILD_ITEM_SIZE" /* 15876 */;
2026-08-24 06:08:38 +00:00
import { jsx } from "jsxProd" /* 21 */;
2026-09-01 10:26:29 +00:00
import createCacheKey from "createCacheKey" /* 4478 */;
2026-07-23 10:11:24 +00:00
const require = arg1;
2026-07-29 08:29:29 +00:00
let c3 = importAllResult;
let obj = { guildIcon: null, geoRestrictedBadge: null };
2026-08-24 06:08:38 +00:00
obj = { width: ThemesDefault.modules.mobile.GUILD_BAR_ITEM_SIZE, height: ThemesDefault.modules.mobile.GUILD_BAR_ITEM_SIZE };
2026-07-29 08:29:29 +00:00
obj[0] = obj;
obj[1] = { borderColor: "transparent", width: GUILD_ITEM_BADGE_SIZE, height: GUILD_ITEM_BADGE_SIZE, bottom: 4, right: 12 };
let closure_5 = createCacheKey.createStyles(obj);
2026-08-24 06:08:38 +00:00
let items = [computeGuildsBarCutoutDefault({ position: "bottom-right" })];
2026-07-20 16:05:17 +00:00
const memoResult = importAllResult.memo(function GuildsBarGeoRestrictedGuild(restrictedGuild) {
restrictedGuild = restrictedGuild.restrictedGuild;
2026-08-31 15:47:37 +00:00
const tmp = callback();
2026-09-01 10:26:29 +00:00
let obj = restrictedGuild(15885);
2026-07-20 16:05:17 +00:00
let animatableSourceWithFallback = null;
if (null != restrictedGuild.icon) {
2026-08-31 15:47:37 +00:00
obj1 = getAvatarURLDefault;
animatableSourceWithFallback = obj1.getAnimatableSourceWithFallback(false, (canAnimate) => {
let obj = closure_1_1(closure_1_2[7]);
obj = { id: restrictedGuild.id, size: restrictedGuild(closure_1_2[8]).ImageSizes[restrictedGuild(undefined, closure_1_2[8]).GuildIconSizes.LARGE], icon: restrictedGuild.icon, canAnimate };
2026-07-20 16:05:17 +00:00
return obj.getGuildIconSource(obj);
});
}
2026-08-24 06:08:38 +00:00
items = [, ];
2026-07-20 16:05:17 +00:00
({ id: arr[0], name: arr[1] } = restrictedGuild);
const memo = importAllResult.useMemo(() => ({
onPress() {
2026-08-31 15:47:37 +00:00
let obj = closure_1_1(closure_1_2[9]);
2026-07-29 08:29:29 +00:00
obj = { title: null, body: null, cancelText: null, onCancel: null };
2026-08-31 15:47:37 +00:00
const intl = closure_1_0(closure_1_2[10]).intl;
obj[0] = intl.string(closure_1_0(closure_1_2[10]).t.aCAiGl);
const intl2 = closure_1_0(closure_1_2[10]).intl;
2026-07-29 08:29:29 +00:00
obj = { serverName: name.name };
2026-08-31 15:47:37 +00:00
obj[1] = intl2.format(closure_1_0(closure_1_2[10]).t["4cJV9S"], obj);
const intl3 = closure_1_0(closure_1_2[10]).intl;
obj[2] = intl3.string(closure_1_0(closure_1_2[10]).t.J2TBi3);
2026-07-29 08:29:29 +00:00
obj[3] = function onCancel() {
2026-08-31 15:47:37 +00:00
closure_1_1(closure_1_2[11]).leaveGuild(id.id);
2026-07-20 16:05:17 +00:00
};
obj.show(obj);
}
}), items);
2026-09-01 10:26:29 +00:00
obj = { selected: false, unread: false, circle: false, styles: obj.useGuildsBarAnimatedWrapperStyles({ disableSelectedColor: true, disableBGColor: true }), label: restrictedGuild.name, isDragTarget: false, config: memo, cutouts: items, overState: "a", externalChildren: 8, expandedChildren: 12, children: 8 };
2026-08-31 15:47:37 +00:00
const guildsBarAnimatedWrapperStyles = obj.useGuildsBarAnimatedWrapperStyles({ disableSelectedColor: true, disableBGColor: true });
const tmp2 = restrictedGuild;
obj = { style: tmp.geoRestrictedBadge };
2026-09-01 10:26:29 +00:00
obj[9] = jsx(_modDef15938, { style: tmp.geoRestrictedBadge });
2026-08-31 15:47:37 +00:00
obj1 = { guildId: restrictedGuild.id };
2026-08-24 06:08:38 +00:00
obj[10] = jsx(GuildRowWrapperDefault, { guildId: restrictedGuild.id });
2026-07-20 16:05:17 +00:00
if (null != animatableSourceWithFallback) {
2026-07-29 08:29:29 +00:00
const obj2 = { source: null, style: null, fadeDuration: 0 };
obj2[0] = animatableSourceWithFallback;
2026-08-31 15:47:37 +00:00
obj2[1] = tmp.guildIcon;
2026-09-01 10:26:29 +00:00
let tmp8Result = tmp8(tmp9(5493), obj2);
2026-07-20 16:05:17 +00:00
} else {
2026-07-29 08:29:29 +00:00
const obj3 = { value: null, selected: false, animate: false, size: null };
obj3[0] = restrictedGuild.name;
2026-09-01 10:26:29 +00:00
obj3[3] = tmp2(6004).GuildIconSizes.LARGE;
tmp8Result = tmp8(tmp9(6004), obj3);
const tmp9Result = tmp9(6004);
2026-07-20 16:05:17 +00:00
}
2026-08-31 15:47:37 +00:00
obj[11] = tmp8Result;
return jsx(UnreadIndicatorDefault, { style: tmp.geoRestrictedBadge });
2026-07-20 16:05:17 +00:00
});
2026-08-24 06:08:38 +00:00
const result = require("set").fileFinishedImporting("modules/guilds_bar/native/GuildsBarGeoRestrictedGuild.tsx");
2026-07-20 16:05:17 +00:00
export default memoResult;