decord/source/components_native/channel_settings/ChannelSettingsOverview.tsx

1878 lines
79 KiB
TypeScript
Raw Normal View History

2026-08-25 06:04:03 +00:00
// Module ID: 16158
// Function ID: 16159
2026-07-29 08:29:29 +00:00
// Name: PinImage
2026-08-25 06:04:03 +00:00
// Dependencies: [5, 19, 17, 4027, 1395, 1434, 8168, 1391, 1982, 1910, 4025, 4395, 16159, 4034, 1922, 16160, 676, 1398, 6031, 1235, 505, 21, 4380, 712, 589, 9874, 4108, 12, 16161, 4588, 1236, 5376, 8539, 8167, 4098, 10028, 8510, 4566, 4038, 1403, 1363, 16162, 9146, 4745, 4376, 9168, 4574, 4833, 4235, 4278, 16163, 7935, 8127, 500, 5873, 5874, 4619, 5482, 13635, 16164, 8511, 8136, 8135, 1400, 1402, 1995, 5480, 5996, 9153, 9284, 10348, 4323, 1401, 16165, 8591, 9836, 14409, 9872, 7368, 4343, 4333, 4925, 9876, 4321, 4338, 4813, 10345, 7896, 9578, 4949, 15511, 8118, 1500, 2]
2026-07-20 16:05:17 +00:00
// Exports: default
2026-08-25 06:04:03 +00:00
// Module 16158 (PinImage)
2026-08-24 06:08:38 +00:00
import applyDefault from "apply" /* 12 */;
import set2 from "set" /* 500 */;
import ThemesDefault from "Themes" /* 712 */;
import getSystemLocale from "getSystemLocale" /* 1236 */;
import set3 from "set" /* 1400 */;
import set4 from "set" /* 1402 */;
2026-08-25 06:04:03 +00:00
import combinedDefault from "combined" /* 1995 */;
import parseRawEmojiObjectDefault from "parseRawEmojiObject" /* 4038 */;
import Text from "Text" /* 4376 */;
import allowChannelAccess from "allowChannelAccess" /* 4566 */;
import computeChannelName from "computeChannelName" /* 4574 */;
import collectGuildAnalyticsMetadataDefault from "collectGuildAnalyticsMetadata" /* 4588 */;
import Stack from "Stack" /* 4813 */;
import PressableCard from "PressableCard" /* 5482 */;
import TableRowGroupTitle from "TableRowGroupTitle" /* 5873 */;
import TableSwitchRow from "TableSwitchRow" /* 5874 */;
import useCanUnarchiveThread from "useCanUnarchiveThread" /* 5996 */;
import Form from "Form" /* 8118 */;
import TableRadioRow from "TableRadioRow" /* 8135 */;
import context from "context" /* 8136 */;
import getAutoArchiveOptions from "getAutoArchiveOptions" /* 8511 */;
import Slider from "Slider" /* 13635 */;
import _modDef16161 from "module_16161" /* 16161 */;
import getSecondsSliderLabel from "getSecondsSliderLabel" /* 16162 */;
import getIsChannelNameSettingEditable from "getIsChannelNameSettingEditable" /* 16163 */;
import AutoArchiveDurationOptions from "AutoArchiveDurationOptions" /* 16164 */;
2026-08-24 06:08:38 +00:00
import closure_3 from "asyncGeneratorStep" /* 5 */;
import importAllResult from "noop" /* 19 */;
import { View } from "get ActivityIndicator" /* 17 */;
2026-08-25 06:04:03 +00:00
import closure_6 from "storeThread" /* 4027 */;
2026-08-24 06:08:38 +00:00
import createChannelRecord from "createChannelRecord" /* 1395 */;
import { isGuildNSFW } from "GuildNSFWContentLevel" /* 1434 */;
2026-08-25 06:04:03 +00:00
import closure_12 from "normalizeChannelPropertyForCompare" /* 8168 */;
2026-08-24 06:08:38 +00:00
import closure_13 from "ensureGuildLoaded" /* 1391 */;
2026-08-25 06:04:03 +00:00
import closure_14 from "comparator" /* 1982 */;
2026-08-24 06:08:38 +00:00
import closure_15 from "createGuildRecordFromRust" /* 1910 */;
2026-08-25 06:04:03 +00:00
import closure_16 from "getUncachedChannelPermissions" /* 4025 */;
import closure_17 from "generateOldThreadCutoff" /* 4395 */;
import closure_18 from "initialize" /* 16159 */;
import closure_19 from "markAllUserIdListsStale" /* 4034 */;
2026-08-24 06:08:38 +00:00
import closure_20 from "mergeGuildAvatar" /* 1922 */;
2026-08-25 06:04:03 +00:00
import { ChannelSettingsAutoFocusElement as closure_21 } from "ChannelSettingsAutoFocusElement" /* 16160 */;
2026-08-24 06:08:38 +00:00
import ME from "ME" /* 676 */;
import set from "set" /* 1398 */;
2026-08-25 06:04:03 +00:00
import { MAX_FORUM_TAGS } from "FORUM_GUIDELINES_ACTION_SHEET" /* 6031 */;
2026-08-24 06:08:38 +00:00
import { DEFAULT_AUTO_ARCHIVE_DURATION as closure_42 } from "AbortCodes" /* 1235 */;
import jsxProd from "jsxProd" /* 21 */;
2026-08-25 06:04:03 +00:00
import createCacheKey from "createCacheKey" /* 4380 */;
2026-07-23 10:11:24 +00:00
2026-08-24 06:08:38 +00:00
require = arg1;
2026-07-20 16:05:17 +00:00
class PinImage {
constructor(arg0) {
2026-07-23 10:11:24 +00:00
channelId = global.channelId;
2026-08-24 06:08:38 +00:00
tmp = closure_46();
2026-07-29 08:29:29 +00:00
tmp2 = channelId;
tmp3 = closure_2;
2026-07-23 10:11:24 +00:00
obj = require("initialize");
2026-07-20 16:05:17 +00:00
items = [];
2026-08-24 06:08:38 +00:00
items[0] = closure_17;
2026-07-29 08:29:29 +00:00
tmp4 = undefined;
2026-08-24 06:08:38 +00:00
if (obj.useStateFromStores(items, () => closure_1_17.hasUnreadPins(channelId))) {
2026-07-20 16:05:17 +00:00
tmp5 = jsx;
tmp6 = View;
2026-07-29 08:29:29 +00:00
obj = { style: null, children: null };
obj[0] = tmp.outer;
obj1 = { style: null };
obj1[0] = tmp.badge;
obj[1] = jsx(View, obj1);
tmp4 = jsx(View, obj);
2026-07-20 16:05:17 +00:00
}
2026-07-29 08:29:29 +00:00
obj2 = { style: global.style, children: null };
2026-07-20 16:05:17 +00:00
items1 = [, ];
2026-07-23 10:11:24 +00:00
items1[0] = jsx(require("PinIcon").PinIcon, {});
2026-07-29 08:29:29 +00:00
items1[1] = tmp4;
obj2[1] = items1;
2026-07-20 16:05:17 +00:00
return jsxs(View, obj2);
}
}
2026-07-29 08:29:29 +00:00
let c4 = importAllResult;
2026-08-24 06:08:38 +00:00
({ EDITABLE_VOICE_SETTINGS_TYPES: error, isGuildTextChannelType: closure_8, THREADED_CHANNEL_TYPES: c9, THREAD_CHANNEL_TYPES: c10 } = createChannelRecord);
2026-07-29 08:29:29 +00:00
({ AnalyticEvents: closure_22, BITRATE_DEFAULT: closure_23, BITRATE_MIN: closure_24, ChannelSettingsSections: closure_25, ChannelTypes: closure_26, ChannelTypesSets: closure_27, GuildFeatures: closure_28, GuildSettingsSections: closure_29, HelpdeskArticles: closure_30, MAX_CHANNEL_NAME_LENGTH: closure_31, MAX_VOICE_USER_LIMIT: closure_32, MAX_STAGE_VOICE_USER_LIMIT: closure_33, Permissions: closure_34, SettingsPaneTypes: closure_35, SLOWMODE_VALUES: closure_36, VideoQualityMode: closure_37 } = ME);
({ ChannelFlags: closure_38, MAX_CHANNEL_TOPIC_LENGTH: closure_39, MAX_FORUM_CHANNEL_TOPIC_LENGTH: closure_40 } = set);
({ jsx: closure_43, jsxs: closure_44, Fragment: closure_45 } = jsxProd);
createCacheKey = { outer: null, badge: null };
2026-08-24 06:08:38 +00:00
createCacheKey = { position: "absolute", top: 2, right: -4, width: 12, height: 12, borderRadius: ThemesDefault.radii.md, justifyContent: "center", alignItems: "center", backgroundColor: ThemesDefault.colors.BACKGROUND_SURFACE_HIGH };
2026-07-29 08:29:29 +00:00
createCacheKey[0] = createCacheKey;
2026-08-24 06:08:38 +00:00
createCacheKey[1] = { backgroundColor: ThemesDefault.unsafe_rawColors.RED_400, width: 8, height: 8, borderRadius: ThemesDefault.radii.xs };
let closure_46 = createCacheKey.createStyles(createCacheKey);
2026-07-29 08:29:29 +00:00
let obj2 = { screenContainer: null, slider: null, stackPadding: null, alertText: null, tagsWrapper: null, addTagIconButtonWrapper: null, createTagButton: null, createTagButtonText: null };
2026-08-24 06:08:38 +00:00
let obj1 = { backgroundColor: ThemesDefault.unsafe_rawColors.RED_400, width: 8, height: 8, borderRadius: ThemesDefault.radii.xs };
obj2[0] = { flex: 1, backgroundColor: ThemesDefault.colors.MOBILE_ACTIONSHEET_BACKGROUND, paddingTop: ThemesDefault.space.PX_16 };
2026-07-29 08:29:29 +00:00
obj2[1] = { marginHorizontal: 15 };
2026-08-24 06:08:38 +00:00
createCacheKey = { paddingHorizontal: ThemesDefault.modules.mobile.TABLE_ROW_PADDING };
2026-07-29 08:29:29 +00:00
obj2[2] = createCacheKey;
obj2[3] = { marginTop: 16 };
obj2[4] = { display: "flex", flexDirection: "row", flexWrap: "wrap" };
2026-08-24 06:08:38 +00:00
let obj3 = { flex: 1, backgroundColor: ThemesDefault.colors.MOBILE_ACTIONSHEET_BACKGROUND, paddingTop: ThemesDefault.space.PX_16 };
obj2[5] = { justifyContent: "center", margin: ThemesDefault.space.PX_4 };
let obj5 = { justifyContent: "center", margin: ThemesDefault.space.PX_4 };
obj2[6] = { backgroundColor: "transparent", paddingHorizontal: 0, marginTop: ThemesDefault.space.PX_4 };
2026-07-29 08:29:29 +00:00
obj2[7] = { fontFamily: require("sum").Fonts.PRIMARY_SEMIBOLD, fontSize: 14 };
let closure_48 = createCacheKey.createLegacyClassComponentStyles(obj2);
const PureComponent = importAllResult.PureComponent;
class ChannelSettingsOverview extends PureComponent {
constructor(arg0) {
tmp = new tmp(global, tmp4, tmp3, tmp2);
// ThrowIfThisInitialized (0x7c)
closure_0 = tmp;
obj = require("apply");
2026-08-24 06:08:38 +00:00
tmp._cooldown = obj.findIndex(SLOWMODE_VALUES, (arg0) => arg0 >= store.props.channel.rateLimitPerUser);
2026-07-29 08:29:29 +00:00
tmp.state = { hasChanges: false };
tmp.pushScreen = function pushScreen(INSTANT_INVITES, arg1) {
const items = [...arguments];
2026-08-24 06:08:38 +00:00
const navigation = store.props.navigation;
2026-07-29 08:29:29 +00:00
const items1 = [...items];
navigation.push.apply(items1);
2026-08-24 06:08:38 +00:00
if (items[0] !== closure_1_25.PERMISSIONS) {
let obj = closure_1_1(closure_1_2[29]);
2026-07-29 08:29:29 +00:00
obj = { settings_type: "channel", origin_pane: null, destination_pane: null };
2026-08-24 06:08:38 +00:00
obj[1] = closure_1_35.CHANNEL_SETTINGS;
2026-07-29 08:29:29 +00:00
obj[2] = items[0];
2026-08-24 06:08:38 +00:00
obj.trackWithMetadata(closure_1_22.SETTINGS_PANE_VIEWED, obj);
2026-07-20 16:05:17 +00:00
}
2026-07-29 08:29:29 +00:00
};
tmp.handleSave = function handleSave() {
let obj = channel;
if (channel.state.hasChanges) {
channel = obj.props.channel;
obj = { name: null, type: null, topic: null, position: null, bitrate: null, userLimit: null, defaultAutoArchiveDuration: null, nsfw: null, rateLimitPerUser: null, videoQualityMode: null, autoArchiveDuration: null, locked: null, invitable: null, flags: null, defaultSortOrder: null, defaultForumLayout: null, defaultTagSetting: null, iconEmoji: null, themeColor: null };
({ name: obj3[0], type: obj3[1], topic: obj3[2], position: obj3[3], bitrate: obj3[4], userLimit: obj3[5], defaultAutoArchiveDuration: obj3[6], nsfw: obj3[7], rateLimitPerUser: obj3[8], videoQualityMode: obj3[9], threadMetadata } = channel);
let autoArchiveDuration;
if (threadMetadata != null) {
autoArchiveDuration = threadMetadata.autoArchiveDuration;
2026-07-20 16:05:17 +00:00
}
2026-07-29 08:29:29 +00:00
obj[10] = autoArchiveDuration;
const threadMetadata2 = channel.threadMetadata;
let locked;
if (threadMetadata2 != null) {
locked = threadMetadata2.locked;
2026-07-20 16:05:17 +00:00
}
2026-07-29 08:29:29 +00:00
obj[11] = locked;
const threadMetadata3 = channel.threadMetadata;
let invitable;
if (threadMetadata3 != null) {
invitable = threadMetadata3.invitable;
2026-07-20 16:05:17 +00:00
}
2026-07-29 08:29:29 +00:00
obj[12] = invitable;
obj[13] = channel.flags;
obj[14] = channel.getDefaultSortOrder();
obj[15] = channel.defaultForumLayout;
obj[16] = channel.getDefaultTagSetting();
({ iconEmoji: obj3[17], themeColor: obj3[18] } = channel);
2026-08-24 06:08:38 +00:00
const obj2 = closure_1_1(closure_1_2[33]);
closure_1_1(closure_1_2[33]).saveChannel(channel.id, obj).then((status) => {
2026-07-29 08:29:29 +00:00
if (200 === status.status) {
2026-08-24 06:08:38 +00:00
let navigation = closure_2_1(closure_2_2[34]).open;
2026-07-29 08:29:29 +00:00
let goBackResult = { key: "THREAD_SETTINGS_UPDATED", icon: null, content: null };
2026-08-24 06:08:38 +00:00
goBackResult[1] = closure_2_1(closure_2_2[35]);
const tmp6 = closure_2_1(closure_2_2[34]);
const intl = channel(closure_2_2[30]).intl;
2026-07-29 08:29:29 +00:00
const string = intl.string;
2026-08-24 06:08:38 +00:00
let n2Y84J = channel(closure_2_2[30]).t;
2026-07-29 08:29:29 +00:00
if (isThreadResult) {
n2Y84J = n2Y84J.n2Y84J;
let stringResult = string(n2Y84J);
} else {
stringResult = string(n2Y84J["FE/ohq"]);
}
goBackResult[2] = stringResult;
navigation(goBackResult);
navigation = channel.props.navigation;
goBackResult = navigation.goBack();
isThreadResult = channel.isThread();
2026-07-20 16:05:17 +00:00
}
2026-07-29 08:29:29 +00:00
});
obj.setState({ hasChanges: false });
2026-08-24 06:08:38 +00:00
const saveChannelResult = closure_1_1(closure_1_2[33]).saveChannel(channel.id, obj);
2026-07-20 16:05:17 +00:00
}
2026-07-29 08:29:29 +00:00
};
tmp.handleChangeName = function handleChangeName(arg0) {
2026-08-24 06:08:38 +00:00
const channel = store.props.channel;
2026-07-29 08:29:29 +00:00
if (channel.isThread()) {
2026-08-24 06:08:38 +00:00
let result = closure_1_1(closure_1_2[36])(arg0, false);
2026-07-20 16:05:17 +00:00
} else {
2026-08-24 06:08:38 +00:00
const LIMITED_CHANNEL_NAME = closure_1_27.LIMITED_CHANNEL_NAME;
2026-07-29 08:29:29 +00:00
result = arg0;
if (LIMITED_CHANNEL_NAME.has(channel.type)) {
2026-08-24 06:08:38 +00:00
result = store(closure_1_2[37]).sanitizeGuildTextChannelName(arg0);
const obj2 = store(closure_1_2[37]);
2026-07-20 16:05:17 +00:00
}
}
2026-08-24 06:08:38 +00:00
closure_1_1(closure_1_2[33]).updateChannel({ name: result });
store.setState({ hasChanges: true });
2026-07-29 08:29:29 +00:00
};
tmp.handleBlurName = function handleBlurName() {
2026-08-24 06:08:38 +00:00
let obj = store;
const channel = store.props.channel;
2026-07-29 08:29:29 +00:00
if (channel.isThread()) {
2026-08-24 06:08:38 +00:00
const tmp3 = closure_1_1(closure_1_2[36])(channel.name, true);
2026-07-29 08:29:29 +00:00
if (tmp3 !== channel.name) {
obj = { name: null };
obj[0] = tmp3;
tmp(tmp2[33]).updateChannel(obj);
obj.setState({ hasChanges: true });
const tmpResult = tmp(tmp2[33]);
}
2026-08-24 06:08:38 +00:00
tmp = closure_1_1;
tmp2 = closure_1_2;
2026-07-20 16:05:17 +00:00
}
2026-07-29 08:29:29 +00:00
};
tmp.handleChangeTopic = function handleChangeTopic(emojiName) {
2026-08-24 06:08:38 +00:00
let obj = closure_1_1(closure_1_2[33]);
obj = { topic: closure_1_1(closure_1_2[38]).translateInlineEmojiToSurrogates(emojiName) };
2026-07-29 08:29:29 +00:00
obj.updateChannel(obj);
2026-08-24 06:08:38 +00:00
store.setState({ hasChanges: true });
2026-07-29 08:29:29 +00:00
};
tmp.handleBitRateChange = function handleBitRateChange(arg0) {
2026-08-24 06:08:38 +00:00
let obj = closure_1_1(closure_1_2[33]);
2026-07-29 08:29:29 +00:00
obj = { bitrate: Math.round(arg0) };
obj.updateChannel(obj);
2026-08-24 06:08:38 +00:00
store.setState({ hasChanges: true });
2026-07-29 08:29:29 +00:00
};
tmp.handleVideoQualityModeChange = function handleVideoQualityModeChange(videoQualityMode) {
2026-08-24 06:08:38 +00:00
let obj = closure_1_1(closure_1_2[33]);
2026-07-29 08:29:29 +00:00
obj = { videoQualityMode };
obj.updateChannel(obj);
2026-08-24 06:08:38 +00:00
store.setState({ hasChanges: true });
2026-07-29 08:29:29 +00:00
};
tmp.handleNsfwChange = function handleNsfwChange(nsfw) {
2026-08-24 06:08:38 +00:00
let obj = closure_1_1(closure_1_2[33]);
2026-07-29 08:29:29 +00:00
obj = { nsfw };
obj.updateChannel(obj);
2026-08-24 06:08:38 +00:00
store.setState({ hasChanges: true });
2026-07-29 08:29:29 +00:00
};
tmp.handleThreadSpoilerChange = function handleThreadSpoilerChange(arg0) {
2026-08-24 06:08:38 +00:00
const obj = store(closure_1_2[39]);
const setFlagResult = store(closure_1_2[39]).setFlag(store.props.channel.flags, closure_1_38.IS_SPOILER_CHANNEL, arg0);
closure_1_1(closure_1_2[33]).updateChannel({ flags: setFlagResult });
store.setState({ hasChanges: true });
2026-07-29 08:29:29 +00:00
};
tmp.handleSlowmodeChange = function handleSlowmodeChange(arg0) {
2026-08-24 06:08:38 +00:00
let hasChanges = store.state.hasChanges;
const tmp2 = closure_1_36[Math.round(Math, arg0)];
closure_1_1(closure_1_2[33]).updateChannel({ rateLimitPerUser: tmp2 });
const AccessibilityAnnouncer = store(closure_1_2[40]).AccessibilityAnnouncer;
const obj = closure_1_1(closure_1_2[33]);
const intl = store(closure_1_2[30]).intl;
AccessibilityAnnouncer.announce(store(closure_1_2[41]).getSecondsSliderLabel(tmp2, false, intl.string(store(closure_1_2[30]).t.zvDu4h)));
2026-07-29 08:29:29 +00:00
if (!hasChanges) {
2026-08-24 06:08:38 +00:00
hasChanges = store.props.channel.rateLimitPerUser !== tmp2;
2026-07-20 16:05:17 +00:00
}
2026-08-24 06:08:38 +00:00
store.setState({ hasChanges });
2026-07-29 08:29:29 +00:00
};
tmp.handleDefaultAutoArchiveDurationChange = function handleDefaultAutoArchiveDurationChange(defaultAutoArchiveDuration) {
2026-08-24 06:08:38 +00:00
let obj = closure_1_1(closure_1_2[33]);
2026-07-29 08:29:29 +00:00
obj = { defaultAutoArchiveDuration };
obj.updateChannel(obj);
2026-08-24 06:08:38 +00:00
store.setState({ hasChanges: true });
2026-07-29 08:29:29 +00:00
};
tmp.handleAutoArchiveDurationChange = function handleAutoArchiveDurationChange(autoArchiveDuration) {
2026-08-24 06:08:38 +00:00
let obj = closure_1_1(closure_1_2[33]);
2026-07-29 08:29:29 +00:00
obj = { autoArchiveDuration };
obj.updateChannel(obj);
2026-08-24 06:08:38 +00:00
store.setState({ hasChanges: true });
2026-07-29 08:29:29 +00:00
};
tmp.handleDefaultSortOrderChange = function handleDefaultSortOrderChange(defaultSortOrder) {
2026-08-24 06:08:38 +00:00
let obj = closure_1_1(closure_1_2[33]);
2026-07-29 08:29:29 +00:00
obj = { defaultSortOrder };
obj.updateChannel(obj);
2026-08-24 06:08:38 +00:00
store.setState({ hasChanges: true });
2026-07-29 08:29:29 +00:00
};
tmp.handleDefaultTagSettingChange = function handleDefaultTagSettingChange(defaultTagSetting) {
2026-08-24 06:08:38 +00:00
let obj = closure_1_1(closure_1_2[33]);
2026-07-29 08:29:29 +00:00
obj = { defaultTagSetting };
obj.updateChannel(obj);
2026-08-24 06:08:38 +00:00
store.setState({ hasChanges: true });
2026-07-29 08:29:29 +00:00
};
tmp.handleInvitableChange = function handleInvitableChange(invitable) {
2026-08-24 06:08:38 +00:00
let obj = closure_1_1(closure_1_2[33]);
2026-07-29 08:29:29 +00:00
obj = { invitable };
obj.updateChannel(obj);
2026-08-24 06:08:38 +00:00
store.setState({ hasChanges: true });
2026-07-29 08:29:29 +00:00
};
tmp.handleAnnouncementChange = function handleAnnouncementChange(arg0) {
2026-08-24 06:08:38 +00:00
let obj = closure_1_1(closure_1_2[33]);
2026-07-29 08:29:29 +00:00
obj = { type: arg0 ? tmp.GUILD_TEXT : tmp.GUILD_ANNOUNCEMENT };
obj.updateChannel(obj);
2026-08-24 06:08:38 +00:00
store.setState({ hasChanges: true });
2026-07-29 08:29:29 +00:00
};
tmp.handleActiveChannelsRemovedChange = function handleActiveChannelsRemovedChange(arg0) {
2026-08-24 06:08:38 +00:00
const obj = store(closure_1_2[39]);
const setFlagResult = store(closure_1_2[39]).setFlag(store.props.channel.flags, closure_1_38.ACTIVE_CHANNELS_REMOVED, !arg0);
closure_1_1(closure_1_2[33]).updateChannel({ flags: setFlagResult });
store.setState({ hasChanges: true });
2026-07-29 08:29:29 +00:00
};
tmp.handleUserLimitChange = function handleUserLimitChange(arg0) {
2026-08-24 06:08:38 +00:00
let obj = closure_1_1(closure_1_2[33]);
2026-07-29 08:29:29 +00:00
obj = { userLimit: Math.round(arg0) };
obj.updateChannel(obj);
2026-08-24 06:08:38 +00:00
store.setState({ hasChanges: true });
2026-07-29 08:29:29 +00:00
};
closure_0 = tmp;
2026-08-24 06:08:38 +00:00
tmp.handleDeleteChannel = closure_3(function*() {
2026-07-29 08:29:29 +00:00
if (c3 === 2) {
c3 = 3;
let throwTypeErrorResult = HermesBuiltin.throwTypeError();
2026-07-20 16:05:17 +00:00
} else {
2026-07-29 08:29:29 +00:00
throwTypeErrorResult = arg1;
throwTypeErrorResult = arg0;
throwTypeErrorResult = tmp3;
if (tmp4 === 3) {
if (arg0 === 1) {
throw arg1;
} else if (arg0 === 2) {
let obj = { value: null, done: true };
obj[0] = arg1;
return obj;
} else {
2026-08-25 06:04:03 +00:00
return { value: "HermesInternal", done: "HermesInternal" };
2026-07-29 08:29:29 +00:00
}
2026-07-20 16:05:17 +00:00
} else {
2026-07-29 08:29:29 +00:00
try {
c3 = 2;
if (0 === guild) {
if (arg0 === 1) {
c3 = 3;
throw arg1;
} else if (arg0 === 2) {
c3 = 3;
obj = { value: null, done: true };
obj[0] = arg1;
return obj;
} else {
let channel = tmp5;
2026-08-24 06:08:38 +00:00
closure_0 = tmp2;
2026-07-29 08:29:29 +00:00
closure_0 = undefined;
channel = undefined;
guild = undefined;
c3 = undefined;
2026-08-24 06:08:38 +00:00
closure_4 = undefined;
c5 = undefined;
throwTypeErrorResult = closure_1_48;
throwTypeErrorResult = closure_1_0;
closure_0 = closure_1_48(closure_1_0.context);
throwTypeErrorResult = closure_1_0;
channel = closure_1_0.props.channel;
throwTypeErrorResult = closure_1_15;
guild = closure_1_15.getGuild(channel.getGuildId());
throwTypeErrorResult = closure_1_0;
2026-07-29 08:29:29 +00:00
throwTypeErrorResult = guild;
guild = 1;
c3 = 1;
2026-08-24 06:08:38 +00:00
obj1 = { value: null, done: false };
obj1[0] = closure_1_0(guild[42]).isDefaultChannelThresholdMetAfterDelete(channel.getGuildId(), channel.id);
2026-07-29 08:29:29 +00:00
return obj1;
}
} else if (arg0 === 1) {
c3 = 3;
throw arg1;
} else if (arg0 === 2) {
c3 = 3;
let obj2 = { value: null, done: true };
obj2[0] = arg1;
return obj2;
} else {
throwTypeErrorResult = closure_0;
c3 = arg1;
throwTypeErrorResult = guild;
if (null != guild) {
throwTypeErrorResult = closure_0;
throwTypeErrorResult = channel;
throwTypeErrorResult = guild;
const features = guild.features;
2026-08-24 06:08:38 +00:00
throwTypeErrorResult = closure_1_28;
if (features.has(closure_1_28.COMMUNITY)) {
if (guild.rulesChannelId === closure_1_1.id) {
if (guild.rulesChannelId === closure_1_1.id) {
const intl2 = closure_1_0(guild[30]).intl;
let stringResult = intl2.string(closure_1_0(guild[30]).t.yjrZPl);
2026-07-29 08:29:29 +00:00
} else {
2026-08-24 06:08:38 +00:00
const intl = closure_1_0(guild[30]).intl;
stringResult = intl.string(closure_1_0(guild[30]).t["1B1/NB"]);
2026-07-29 08:29:29 +00:00
}
c5 = stringResult;
2026-08-24 06:08:38 +00:00
obj = closure_1_1(guild[43]);
2026-07-29 08:29:29 +00:00
const obj3 = { title: null, confirmText: null, children: null };
2026-08-24 06:08:38 +00:00
const intl3 = closure_1_0(guild[30]).intl;
obj3[0] = intl3.string(closure_1_0(guild[30]).t["TY/V+H"]);
const intl4 = closure_1_0(guild[30]).intl;
obj3[1] = intl4.string(closure_1_0(guild[30]).t.BddRzS);
2026-07-29 08:29:29 +00:00
const obj4 = { children: null };
const obj5 = { style: null, variant: "text-md/medium", children: null };
obj5[0] = closure_0.alertText;
obj5[2] = c5;
2026-08-24 06:08:38 +00:00
const items = [closure_1_43(closure_1_0(guild[44]).Text, obj5), ];
2026-07-29 08:29:29 +00:00
let obj6 = { style: null, variant: "text-md/medium", children: null };
obj6[0] = closure_0.alertText;
2026-08-24 06:08:38 +00:00
const intl5 = closure_1_0(guild[30]).intl;
2026-07-29 08:29:29 +00:00
const obj7 = { onClick: null };
obj7[0] = function onClick() {
channel(user[43]).close();
const obj = channel(user[43]);
channel(user[33]).close();
const obj2 = channel(user[33]);
2026-08-24 06:08:38 +00:00
channel(user[45]).open(user.id, closure_1_29.COMMUNITY);
2026-07-29 08:29:29 +00:00
};
2026-08-24 06:08:38 +00:00
obj6[2] = intl5.format(closure_1_0(guild[30]).t.LAJbDm, obj7);
items[1] = closure_1_43(closure_1_0(guild[44]).Text, obj6);
2026-07-29 08:29:29 +00:00
obj4[0] = items;
2026-08-24 06:08:38 +00:00
obj3[2] = closure_1_44(closure_1_45, obj4);
2026-07-29 08:29:29 +00:00
obj.show(obj3);
c3 = 3;
}
}
}
if (null != guild) {
throwTypeErrorResult = closure_0;
throwTypeErrorResult = c3;
if (!c3) {
2026-08-24 06:08:38 +00:00
obj6 = closure_1_1(guild[43]);
2026-07-29 08:29:29 +00:00
const obj8 = { title: null, confirmText: null, children: null };
2026-08-24 06:08:38 +00:00
const intl6 = closure_1_0(guild[30]).intl;
obj8[0] = intl6.string(closure_1_0(guild[30]).t["TY/V+H"]);
const intl7 = closure_1_0(guild[30]).intl;
obj8[1] = intl7.string(closure_1_0(guild[30]).t.BddRzS);
2026-07-29 08:29:29 +00:00
const obj9 = { children: null };
const obj10 = { style: null, variant: "text-md/medium", children: null };
obj10[0] = closure_0.alertText;
2026-08-24 06:08:38 +00:00
const intl8 = closure_1_0(guild[30]).intl;
obj10[2] = intl8.string(closure_1_0(guild[30]).t.iWlB6h);
const items1 = [closure_1_43(closure_1_0(guild[44]).Text, obj10), ];
2026-07-29 08:29:29 +00:00
const obj11 = { style: null, variant: "text-md/medium", children: null };
obj11[0] = closure_0.alertText;
2026-08-24 06:08:38 +00:00
const intl9 = closure_1_0(guild[30]).intl;
2026-07-29 08:29:29 +00:00
let obj12 = { onClick: null };
obj12[0] = function onClick() {
channel(user[43]).close();
const obj = channel(user[43]);
channel(user[33]).close();
const obj2 = channel(user[33]);
2026-08-24 06:08:38 +00:00
channel(user[45]).open(user.id, closure_1_29.ONBOARDING);
2026-07-29 08:29:29 +00:00
};
2026-08-24 06:08:38 +00:00
obj11[2] = intl9.format(closure_1_0(guild[30]).t.ajiBwB, obj12);
items1[1] = closure_1_43(closure_1_0(guild[44]).Text, obj11);
2026-07-29 08:29:29 +00:00
obj9[0] = items1;
2026-08-24 06:08:38 +00:00
obj8[2] = closure_1_44(closure_1_45, obj9);
2026-07-29 08:29:29 +00:00
obj6.show(obj8);
}
}
2026-08-24 06:08:38 +00:00
obj12 = closure_1_0(guild[46]);
closure_4 = obj12.computeChannelName(channel, closure_1_20, closure_1_19, true);
let obj13 = closure_1_1(guild[43]);
if (closure_1_0.props.isForumPost) {
throwTypeErrorResult = closure_1_0;
2026-07-29 08:29:29 +00:00
throwTypeErrorResult = guild;
2026-08-24 06:08:38 +00:00
const intl11 = closure_1_0(guild[30]).intl;
throwTypeErrorResult = closure_1_0;
2026-07-29 08:29:29 +00:00
throwTypeErrorResult = guild;
2026-08-24 06:08:38 +00:00
throwTypeErrorResult = intl11.string(closure_1_0(guild[30]).t.nEOg1N);
2026-07-29 08:29:29 +00:00
} else {
throwTypeErrorResult = channel;
2026-08-24 06:08:38 +00:00
throwTypeErrorResult = closure_1_0;
2026-07-29 08:29:29 +00:00
throwTypeErrorResult = guild;
2026-08-24 06:08:38 +00:00
const intl10 = closure_1_0(guild[30]).intl;
2026-07-29 08:29:29 +00:00
const string = intl10.string;
2026-08-24 06:08:38 +00:00
throwTypeErrorResult = closure_1_0;
2026-07-29 08:29:29 +00:00
throwTypeErrorResult = guild;
2026-08-24 06:08:38 +00:00
const t = closure_1_0(guild[30]).t;
if (closure_1_0.props.isThread) {
2026-07-29 08:29:29 +00:00
throwTypeErrorResult = string(t.H7vTe2);
} else {
throwTypeErrorResult = string(t["8D8Rsb"]);
}
}
obj13 = { title: null, body: null, cancelText: null, confirmText: null, onConfirm: null, confirmColor: null };
throwTypeErrorResult = closure_0;
throwTypeErrorResult = channel;
obj13[0] = throwTypeErrorResult;
2026-08-24 06:08:38 +00:00
throwTypeErrorResult = closure_1_0;
2026-07-29 08:29:29 +00:00
throwTypeErrorResult = guild;
2026-08-24 06:08:38 +00:00
const intl12 = closure_1_0(guild[30]).intl;
throwTypeErrorResult = closure_1_0;
2026-07-29 08:29:29 +00:00
throwTypeErrorResult = guild;
const obj14 = { channelName: null };
throwTypeErrorResult = closure_4;
obj14[0] = closure_4;
2026-08-24 06:08:38 +00:00
obj13[1] = intl12.format(closure_1_0(guild[30]).t.a6Gz9J, obj14);
throwTypeErrorResult = closure_1_0;
2026-07-29 08:29:29 +00:00
throwTypeErrorResult = guild;
2026-08-24 06:08:38 +00:00
const intl13 = closure_1_0(guild[30]).intl;
throwTypeErrorResult = closure_1_0;
2026-07-29 08:29:29 +00:00
throwTypeErrorResult = guild;
2026-08-24 06:08:38 +00:00
obj13[2] = intl13.string(closure_1_0(guild[30]).t.gm1Vej);
throwTypeErrorResult = closure_1_0;
2026-07-29 08:29:29 +00:00
throwTypeErrorResult = guild;
2026-08-24 06:08:38 +00:00
const intl14 = closure_1_0(guild[30]).intl;
throwTypeErrorResult = closure_1_0;
2026-07-29 08:29:29 +00:00
throwTypeErrorResult = guild;
2026-08-24 06:08:38 +00:00
obj13[3] = intl14.string(closure_1_0(guild[30]).t.p89ACt);
throwTypeErrorResult = closure_1_0;
obj13[4] = closure_1_0.handleConfirmDeleteChannel;
throwTypeErrorResult = closure_1_1;
2026-07-29 08:29:29 +00:00
throwTypeErrorResult = guild;
2026-08-24 06:08:38 +00:00
obj13[5] = closure_1_1(guild[47]).Colors.RED;
2026-07-29 08:29:29 +00:00
throwTypeErrorResult = obj13.show(obj13);
2026-07-20 16:05:17 +00:00
}
2026-07-29 08:29:29 +00:00
} catch (throwTypeErrorResult) {
c3 = throwTypeErrorResult;
throw throwTypeErrorResult;
2026-07-20 16:05:17 +00:00
}
}
}
2026-07-29 08:29:29 +00:00
});
closure_0 = tmp;
2026-08-24 06:08:38 +00:00
tmp.handleConfirmDeleteChannel = closure_3(function*() {
closure_2 = tmp3;
c4 = 1;
yield closure_1_1(closure_1_2[33]).deleteChannel(closure_1_0.props.channel.id);
2026-08-04 21:03:28 +00:00
if (1 === tmp7) {
c4 = 0;
2026-08-24 06:08:38 +00:00
closure_2 = closure_3;
const aPIError = new closure_1_0(closure_1_2[49]).APIError(closure_2);
2026-08-04 21:03:28 +00:00
const anyErrorMessage = aPIError.getAnyErrorMessage();
let navigation = anyErrorMessage;
if (anyErrorMessage == null) {
2026-08-24 06:08:38 +00:00
const intl = closure_1_0(closure_1_2[30]).intl;
navigation = intl.string(closure_1_0(closure_1_2[30]).t.CKsXk3);
2026-08-04 21:03:28 +00:00
}
const obj2 = { key: "CHANNEL_SETTINGS_DELETE_CHANNEL_ERROR", content: null };
obj2[1] = navigation;
2026-08-24 06:08:38 +00:00
closure_1_1(closure_1_2[34]).open(obj2);
c6 = 3;
const obj5 = closure_1_1(closure_1_2[34]);
2026-08-04 21:03:28 +00:00
} else if (arg0 === 1) {
2026-07-29 08:29:29 +00:00
c6 = 3;
2026-08-04 21:03:28 +00:00
throw arg1;
} else if (arg0 !== 2) {
2026-08-24 06:08:38 +00:00
const obj = closure_1_0(closure_1_2[48]);
2026-08-04 21:03:28 +00:00
navigation = obj.getRootNavigationRef();
2026-08-24 06:08:38 +00:00
obj1 = navigation;
2026-08-04 21:03:28 +00:00
let isReadyResult;
if (navigation != null) {
isReadyResult = obj1.isReady();
2026-07-20 16:05:17 +00:00
}
2026-08-04 21:03:28 +00:00
if (isReadyResult) {
navigation.goBack();
2026-07-20 16:05:17 +00:00
}
2026-08-04 21:03:28 +00:00
c4 = 0;
2026-07-20 16:05:17 +00:00
}
2026-08-04 21:03:28 +00:00
c4 = 0;
return arg1;
2026-07-29 08:29:29 +00:00
});
tmp.handlePressTag = function handlePressTag(tag) {
2026-08-24 06:08:38 +00:00
store.pushScreen(closure_1_25.EDIT_FORUM_TAG, { tag });
2026-07-29 08:29:29 +00:00
};
tmp.handleToggleRequireTag = function handleToggleRequireTag() {
2026-08-24 06:08:38 +00:00
let obj = store;
if (store.props.canManageChannels) {
2026-07-29 08:29:29 +00:00
const channel = obj.props.channel;
2026-08-24 06:08:38 +00:00
const hasFlagResult = channel.hasFlag(closure_1_38.REQUIRE_TAG);
const obj2 = store(closure_1_2[39]);
const setFlagResult = store(closure_1_2[39]).setFlag(obj.props.channel.flags, closure_1_38.REQUIRE_TAG, !hasFlagResult);
2026-07-29 08:29:29 +00:00
obj = { flags: null };
obj[0] = setFlagResult;
2026-08-24 06:08:38 +00:00
closure_1_1(closure_1_2[33]).updateChannel(obj);
2026-07-29 08:29:29 +00:00
obj.setState({ hasChanges: true });
2026-08-24 06:08:38 +00:00
const obj3 = closure_1_1(closure_1_2[33]);
2026-07-20 16:05:17 +00:00
}
2026-07-29 08:29:29 +00:00
};
tmp.handleToggleShowMediaDownloadOptions = function handleToggleShowMediaDownloadOptions() {
2026-08-24 06:08:38 +00:00
let obj = store;
if (store.props.canManageChannels) {
2026-07-29 08:29:29 +00:00
const channel = obj.props.channel;
2026-08-24 06:08:38 +00:00
const hasFlagResult = channel.hasFlag(closure_1_38.HIDE_MEDIA_DOWNLOAD_OPTIONS);
const obj2 = store(closure_1_2[39]);
const setFlagResult = store(closure_1_2[39]).setFlag(obj.props.channel.flags, closure_1_38.HIDE_MEDIA_DOWNLOAD_OPTIONS, !hasFlagResult);
2026-07-29 08:29:29 +00:00
obj = { flags: null };
obj[0] = setFlagResult;
2026-08-24 06:08:38 +00:00
closure_1_1(closure_1_2[33]).updateChannel(obj);
2026-07-29 08:29:29 +00:00
obj.setState({ hasChanges: true });
2026-08-24 06:08:38 +00:00
const obj3 = closure_1_1(closure_1_2[33]);
2026-07-29 08:29:29 +00:00
}
};
tmp.getError = function getError(arg0) {
2026-08-24 06:08:38 +00:00
const errors = store.props.errors;
let tmp;
2026-07-29 08:29:29 +00:00
if (errors != null) {
tmp = errors[arg0];
2026-07-20 16:05:17 +00:00
}
return tmp;
2026-07-29 08:29:29 +00:00
};
2026-08-24 06:08:38 +00:00
tmp.state.hasChanges = closure_12.hasChanges();
2026-07-29 08:29:29 +00:00
return tmp;
}
}
const prototype = ChannelSettingsOverview.prototype;
prototype["componentDidMount"] = function componentDidMount() {
const self = this;
this.updateNavigation(undefined, this.state);
if (tmp2) {
2026-08-25 06:04:03 +00:00
let obj = _modDef16161;
2026-07-29 08:29:29 +00:00
const regions = obj.fetchRegions(self.props.guild.id);
}
obj = { settings_type: "channel", destination_pane: constants6.CHANNEL_SETTINGS };
2026-08-24 06:08:38 +00:00
collectGuildAnalyticsMetadataDefault.trackWithMetadata(constants.SETTINGS_PANE_VIEWED, obj);
2026-07-29 08:29:29 +00:00
};
prototype["componentDidUpdate"] = function componentDidUpdate(arg0, arg1) {
this.updateNavigation(arg0, arg1);
};
prototype["updateNavigation"] = function updateNavigation(submitting, hasChanges) {
const self = this;
const props = this.props;
({ navigation, submitting, isThread } = props);
const type = props.channel.type;
hasChanges = this.state.hasChanges;
if (isThread) {
const intl3 = hasChanges(1236).intl;
const string = intl3.string;
let BsJrhj = hasChanges(1236).t;
if (props.isForumPost) {
BsJrhj = BsJrhj.BsJrhj;
let stringResult = string(BsJrhj);
let tmp11 = tmp9;
let tmp12 = tmp8;
} else {
stringResult = string(BsJrhj.d4n5Q1);
tmp11 = tmp9;
tmp12 = tmp8;
2026-07-20 16:05:17 +00:00
}
2026-07-29 08:29:29 +00:00
} else {
if (type === constants2.GUILD_CATEGORY) {
const intl2 = hasChanges(1236).intl;
let stringResult1 = intl2.string(hasChanges(1236).t["/uELTj"]);
let tmp3 = hasChanges;
} else {
tmp3 = hasChanges;
let intl = hasChanges(1236).intl;
stringResult1 = intl.string(hasChanges(1236).t.XPDhcc);
2026-07-20 16:05:17 +00:00
}
2026-07-29 08:29:29 +00:00
if (submitting) {
2026-08-25 06:04:03 +00:00
let fn = tmp3(5376).HeaderSubmittingIndicator;
2026-07-29 08:29:29 +00:00
} else {
fn = (arg0) => {
const obj = {};
const merged = Object.assign(arg0);
obj.onPress = self.handleSave;
2026-08-24 06:08:38 +00:00
const intl = hasChanges(closure_1_2[30]).intl;
obj.label = intl.string(hasChanges(closure_1_2[30]).t["R3BPH+"]);
2026-07-29 08:29:29 +00:00
obj.disabled = !hasChanges;
2026-08-24 06:08:38 +00:00
return closure_1_43(hasChanges(closure_1_2[32]).HeaderTextButton, obj);
2026-07-29 08:29:29 +00:00
};
2026-07-20 16:05:17 +00:00
}
2026-07-29 08:29:29 +00:00
let obj = { headerRight: null, title: null };
obj[0] = fn;
obj[1] = stringResult1;
navigation.setOptions(obj);
}
};
prototype["renderChannelInfo"] = function renderChannelInfo() {
const self = this;
const props = this.props;
({ channel, canManageChannels, isThread } = props);
({ canManageThread, canSendMessages, isChannelOwner, isForumPost } = props);
let hasItem = callback2(channel.type) && !isThread;
if (!hasItem) {
const GUILD_THREADS_ONLY = constants3.GUILD_THREADS_ONLY;
hasItem = GUILD_THREADS_ONLY.has(channel.type);
}
2026-08-24 06:08:38 +00:00
let obj = getIsChannelNameSettingEditable;
2026-07-29 08:29:29 +00:00
const isChannelNameSettingEditable = obj.getIsChannelNameSettingEditable({ canManageThread, canManageChannels, canSendMessages, isForumPost, isThread, isChannelOwner });
if (channel.isForumPost()) {
const intl4 = tmp3(1236).intl;
let stringResult = intl4.string(tmp3(1236).t.uyVrTN);
} else if (isThread) {
const intl3 = tmp3(1236).intl;
stringResult = intl3.string(tmp3(1236).t.j3XWjD);
} else if (channel.type === constants2.GUILD_CATEGORY) {
const intl2 = tmp3(1236).intl;
stringResult = intl2.string(tmp3(1236).t.OCAkGP);
} else {
const intl = tmp3(1236).intl;
stringResult = intl.string(tmp3(1236).t.PVbHDl);
}
obj = { ref: self.props.channelNameRef, label: stringResult, accessibilityLabel: stringResult, value: null, onChange: null, onBlur: null, isDisabled: null, maxLength: null, errorMessage: null, enableAndroidSanitizedInputWorkaround: true };
2026-08-25 06:04:03 +00:00
const TextInput = tmp3(7935).TextInput;
2026-08-24 06:08:38 +00:00
obj[3] = computeChannelName.computeChannelName(channel, closure_20, closure_19);
2026-07-29 08:29:29 +00:00
({ handleChangeName: obj2[4], handleBlurName: obj2[5] } = self);
obj[6] = !isChannelNameSettingEditable;
obj[7] = closure_31;
obj[8] = self.getError("name");
if (!hasItem) {
obj = { children: null };
const items = [tmp9, undefined];
obj[0] = items;
return callback4(closure_45, obj);
} else {
const intl5 = tmp3(1236).intl;
const string = intl5.string;
const t = tmp3(1236).t;
if (isForumLikeChannelResult) {
let stringResult1 = string(t.yR6HwZ);
} else {
stringResult1 = string(t.X8jMDh);
}
2026-08-24 06:08:38 +00:00
obj1 = { label: null, accessibilityLabel: null, value: null, onChange: null, isDisabled: null, autoCorrect: true, maxLength: null, errorMessage: null };
2026-07-29 08:29:29 +00:00
obj1[0] = stringResult1;
obj1[1] = stringResult1;
isForumLikeChannelResult = channel.isForumLikeChannel();
2026-08-24 06:08:38 +00:00
obj1[2] = parseRawEmojiObjectDefault.translateSurrogatesToInlineEmoji(channel.topic);
2026-07-29 08:29:29 +00:00
obj1[3] = self.handleChangeTopic;
obj1[4] = !canManageChannels;
obj1[6] = channel.isForumLikeChannel() ? closure_40 : closure_39;
obj1[7] = self.getError("topic");
2026-08-25 06:04:03 +00:00
closure_43(tmp3(8127).TextArea, obj1);
2026-08-24 06:08:38 +00:00
const obj5 = parseRawEmojiObjectDefault;
2026-07-29 08:29:29 +00:00
}
};
prototype["renderNsfwConfig"] = function renderNsfwConfig() {
const channel = this.props.channel;
let tmp7Result = null;
if (channel.type === constants2.GUILD_TEXT) {
tmp7Result = null;
if (tmp2) {
2026-08-24 06:08:38 +00:00
let obj = set2;
2026-07-29 08:29:29 +00:00
tmp7Result = null;
if (!obj.isIOS()) {
obj = { helperText: null, hasIcons: false, children: null };
const intl = tmp5(1236).intl;
obj[0] = intl.string(tmp5(1236).t["9eUgwR"]);
obj = { label: null, value: null, onValueChange: null, disabled: null, subLabel: null };
const intl2 = tmp5(1236).intl;
obj[0] = intl2.string(tmp5(1236).t.Es25Yf);
2026-08-25 06:04:03 +00:00
obj[1] = tmp5(4619).isChannelOrGuildNSFW(channel);
2026-07-29 08:29:29 +00:00
obj[2] = tmp.handleNsfwChange;
obj[3] = tmp3;
let stringResult;
if (null != channel.linkedLobby) {
const intl3 = tmp5(1236).intl;
stringResult = intl3.string(tmp5(1236).t.l6uSVa);
2026-07-20 16:05:17 +00:00
}
2026-07-29 08:29:29 +00:00
obj[4] = stringResult;
2026-08-25 06:04:03 +00:00
obj[2] = closure_43(tmp5(5874).TableSwitchRow, obj);
tmp7Result = tmp7(tmp5(5873).TableRowGroup, obj, "nsfw-section");
const tmp5Result = tmp5(4619);
2026-07-20 16:05:17 +00:00
}
}
2026-07-29 08:29:29 +00:00
}
return tmp7Result;
};
prototype["renderThreadSpoiler"] = function renderThreadSpoiler() {
const props = this.props;
const channel = props.channel;
let tmp = null;
if (channel.isThread()) {
let obj = { helperText: null, hasIcons: false, children: null };
2026-08-24 06:08:38 +00:00
const intl = getSystemLocale.intl;
obj[0] = intl.string(getSystemLocale.t.ddWXHa);
2026-07-29 08:29:29 +00:00
obj = { label: null, value: null, onValueChange: null, disabled: null };
2026-08-24 06:08:38 +00:00
const intl2 = getSystemLocale.intl;
obj[0] = intl2.string(getSystemLocale.t.TvUHTb);
2026-07-29 08:29:29 +00:00
obj[1] = channel.isSpoilerChannel();
obj[2] = this.handleThreadSpoilerChange;
obj[3] = !props.canManageThread;
2026-08-24 06:08:38 +00:00
obj[2] = callback3(TableSwitchRow.TableSwitchRow, obj);
tmp = callback3(TableRowGroupTitle.TableRowGroup, obj, "thread-spoiler-section");
2026-07-29 08:29:29 +00:00
}
return tmp;
};
prototype["renderSlowmode"] = function renderSlowmode() {
const self = this;
const channel = this.props.channel;
if (channel.type !== constants2.GUILD_TEXT) {
return null;
}
2026-08-24 06:08:38 +00:00
let obj = getSecondsSliderLabel;
const intl = getSystemLocale.intl;
const secondsSliderLabel = obj.getSecondsSliderLabel(channel.rateLimitPerUser, false, intl.string(getSystemLocale.t.zvDu4h));
2026-07-29 08:29:29 +00:00
if (channel.isForumLikeChannel()) {
const intl3 = tmp5(1236).intl;
let stringResult = intl3.string(tmp5(1236).t["a+1pdO"]);
} else {
const intl2 = tmp5(1236).intl;
const string = intl2.string;
const t = tmp5(1236).t;
if (isThreadResult) {
stringResult = string(t.OMmNCv);
} else {
stringResult = string(t["HEA/DU"]);
}
isThreadResult = channel.isThread();
}
const items = [];
obj = { helperText: stringResult, hasIcons: false, children: null };
obj = { border: "none", children: null };
2026-08-24 06:08:38 +00:00
obj1 = { style: { flexDirection: "row", justifyContent: "space-between", alignItems: "center", flexWrap: "wrap" }, children: null };
2026-07-29 08:29:29 +00:00
const obj2 = { variant: "text-md/semibold", color: "mobile-text-heading-primary", style: { flexShrink: 1 }, children: null };
const intl4 = tmp5(1236).intl;
2026-08-24 06:08:38 +00:00
obj2[3] = intl4.string(getSystemLocale.t.piZgKF);
const items1 = [callback3(Text.Text, obj2), callback3(Text.Text, { variant: "text-md/medium", color: "text-muted", children: secondsSliderLabel })];
2026-07-29 08:29:29 +00:00
obj1[1] = items1;
const items2 = [callback4(View, obj1), ];
const obj3 = { style: items3, value: self._cooldown, minimumValue: 0, maximumValue: length.length - 1, onValueChange: self.handleSlowmodeChange, accessibilityLabel: null, accessibilityValue: null };
2026-08-24 06:08:38 +00:00
items3 = [callback6(this.context).slider, { marginStart: -4, marginTop: 8 }];
2026-07-29 08:29:29 +00:00
const intl5 = tmp5(1236).intl;
2026-08-24 06:08:38 +00:00
obj3[5] = intl5.string(getSystemLocale.t.piZgKF);
2026-07-29 08:29:29 +00:00
obj3[6] = { text: secondsSliderLabel };
2026-08-24 06:08:38 +00:00
items2[1] = callback3(Slider.Slider, obj3);
2026-07-29 08:29:29 +00:00
obj[1] = items2;
2026-08-24 06:08:38 +00:00
obj[2] = callback4(PressableCard.Card, obj);
items.push(callback3(TableRowGroupTitle.TableRowGroup, obj, "slowmode-section"));
2026-07-29 08:29:29 +00:00
return items;
};
prototype["renderAutoArchiveDuration"] = function renderAutoArchiveDuration() {
const props = this.props;
const channel = props.channel;
({ canManageThread, isForumPost } = props);
if (channel.isThread()) {
if (canManageThread) {
2026-08-24 06:08:38 +00:00
const intl = getSystemLocale.intl;
2026-07-29 08:29:29 +00:00
const string = intl.string;
2026-08-24 06:08:38 +00:00
const t = getSystemLocale.t;
2026-07-29 08:29:29 +00:00
if (isForumPost) {
let stringResult = string(t["3aJN9M"]);
let tmp5 = tmp;
} else {
stringResult = string(t.YUXr4Z);
tmp5 = tmp;
}
const obj = { title: null, description: null, selected: null, channel: null, onSelectDuration: null };
const intl2 = tmp5(1236).intl;
obj[0] = intl2.string(tmp5(1236).t.FGjMZS);
obj[1] = stringResult;
const threadMetadata = channel.threadMetadata;
let autoArchiveDuration;
if (threadMetadata != null) {
autoArchiveDuration = threadMetadata.autoArchiveDuration;
}
if (autoArchiveDuration == null) {
autoArchiveDuration = closure_42;
2026-07-20 16:05:17 +00:00
}
2026-07-29 08:29:29 +00:00
obj[2] = autoArchiveDuration;
obj[3] = channel;
obj[4] = this.handleAutoArchiveDurationChange;
2026-08-25 06:04:03 +00:00
return closure_43(tmp5(16164).AutoArchiveDurationOptions, obj);
2026-07-20 16:05:17 +00:00
}
2026-07-29 08:29:29 +00:00
}
return null;
};
prototype["renderInvitable"] = function renderInvitable() {
const channel = this.props.channel;
let tmp3 = null;
if (null != channel.threadMetadata) {
tmp3 = null;
if (channel.type === constants2.PRIVATE_THREAD) {
let obj = { description: null, hasIcons: false, children: null };
2026-08-24 06:08:38 +00:00
const intl = getSystemLocale.intl;
obj[0] = intl.string(getSystemLocale.t.cSyXJk);
2026-07-29 08:29:29 +00:00
obj = { disabled: null, label: null, value: null, onValueChange: null };
obj[0] = !tmp2;
2026-08-24 06:08:38 +00:00
const intl2 = getSystemLocale.intl;
obj[1] = intl2.string(getSystemLocale.t.s2rpNf);
2026-07-29 08:29:29 +00:00
obj[2] = channel.threadMetadata.invitable;
obj[3] = tmp.handleInvitableChange;
2026-08-24 06:08:38 +00:00
obj[2] = callback3(TableSwitchRow.TableSwitchRow, obj);
tmp3 = callback3(TableRowGroupTitle.TableRowGroup, obj, "thread-invitable-section");
2026-07-29 08:29:29 +00:00
}
}
return tmp3;
};
prototype["renderDefaultAutoArchiveDuration"] = function renderDefaultAutoArchiveDuration() {
const props = this.props;
const channel = props.channel;
let tmp = null;
if (set2.has(channel.type)) {
tmp = null;
if (props.canManageChannels) {
const obj = { title: null, selected: null, channel: null, onSelectDuration: null, description: null };
2026-08-24 06:08:38 +00:00
const intl = getSystemLocale.intl;
obj[0] = intl.string(getSystemLocale.t.FGjMZS);
obj[1] = getAutoArchiveOptions.getAutoArchiveDuration(channel, null);
2026-07-29 08:29:29 +00:00
obj[2] = channel;
obj[3] = this.handleDefaultAutoArchiveDurationChange;
2026-08-24 06:08:38 +00:00
const obj2 = getAutoArchiveOptions;
2026-07-29 08:29:29 +00:00
const tmp2 = closure_43;
2026-08-24 06:08:38 +00:00
const intl2 = getSystemLocale.intl;
2026-07-29 08:29:29 +00:00
const string = intl2.string;
2026-08-24 06:08:38 +00:00
let fyXclY = getSystemLocale.t;
2026-07-29 08:29:29 +00:00
if (isForumLikeChannelResult) {
fyXclY = fyXclY.fyXclY;
let stringResult = string(fyXclY);
} else {
stringResult = string(fyXclY.W3Noi9);
2026-07-20 16:05:17 +00:00
}
2026-07-29 08:29:29 +00:00
obj[4] = stringResult;
2026-08-24 06:08:38 +00:00
tmp2(AutoArchiveDurationOptions.AutoArchiveDurationOptions, obj);
2026-07-29 08:29:29 +00:00
isForumLikeChannelResult = channel.isForumLikeChannel();
2026-07-20 16:05:17 +00:00
}
2026-07-29 08:29:29 +00:00
}
return tmp;
};
prototype["renderDefaultSortOrder"] = function renderDefaultSortOrder() {
const props = this.props;
const channel = props.channel;
if (channel.isForumLikeChannel()) {
if (props.canManageChannels) {
const defaultSortOrder = channel.getDefaultSortOrder();
let obj = { title: null, description: null, value: null, onChange: null, hasIcons: false, children: null };
2026-08-24 06:08:38 +00:00
const intl = getSystemLocale.intl;
obj[0] = intl.string(getSystemLocale.t.gePre2);
const intl2 = getSystemLocale.intl;
obj[1] = intl2.string(getSystemLocale.t["165cVX"]);
2026-07-29 08:29:29 +00:00
obj[2] = defaultSortOrder;
obj[3] = this.handleDefaultSortOrderChange;
obj = { label: null, value: null };
2026-08-24 06:08:38 +00:00
const intl3 = getSystemLocale.intl;
obj[0] = intl3.string(getSystemLocale.t.ElZtzj);
obj[1] = set3.ThreadSortOrder.LATEST_ACTIVITY;
const items = [callback3(TableRadioRow.TableRadioRow, obj), ];
2026-07-29 08:29:29 +00:00
obj = { label: null, value: null };
2026-08-24 06:08:38 +00:00
const intl4 = getSystemLocale.intl;
obj[0] = intl4.string(getSystemLocale.t.w28f3F);
obj[1] = set3.ThreadSortOrder.CREATION_DATE;
items[1] = callback3(TableRadioRow.TableRadioRow, obj);
2026-07-29 08:29:29 +00:00
obj[5] = items;
2026-08-24 06:08:38 +00:00
return callback4(context.TableRadioGroup, obj);
2026-07-29 08:29:29 +00:00
}
}
return null;
};
prototype["renderDefaultTagSetting"] = function renderDefaultTagSetting() {
const props = this.props;
const channel = props.channel;
if (channel.isForumLikeChannel()) {
if (props.canManageChannels) {
const defaultTagSetting = channel.getDefaultTagSetting();
let obj = { title: null, description: null, value: null, onChange: null, hasIcons: false, children: null };
2026-08-24 06:08:38 +00:00
const intl = getSystemLocale.intl;
obj[0] = intl.string(getSystemLocale.t.Paxaug);
const intl2 = getSystemLocale.intl;
obj[1] = intl2.string(getSystemLocale.t.DqOl8J);
2026-07-29 08:29:29 +00:00
obj[2] = defaultTagSetting;
obj[3] = this.handleDefaultTagSettingChange;
obj = { label: null, value: null };
2026-08-24 06:08:38 +00:00
const intl3 = getSystemLocale.intl;
obj[0] = intl3.string(getSystemLocale.t.rQ0ctQ);
obj[1] = set4.ThreadSearchTagSetting.MATCH_SOME;
const items = [callback3(TableRadioRow.TableRadioRow, obj), ];
2026-07-29 08:29:29 +00:00
obj = { label: null, value: null };
2026-08-24 06:08:38 +00:00
const intl4 = getSystemLocale.intl;
obj[0] = intl4.string(getSystemLocale.t.FCXUu0);
obj[1] = set4.ThreadSearchTagSetting.MATCH_ALL;
items[1] = callback3(TableRadioRow.TableRadioRow, obj);
2026-07-29 08:29:29 +00:00
obj[5] = items;
2026-08-24 06:08:38 +00:00
return callback4(context.TableRadioGroup, obj);
2026-07-29 08:29:29 +00:00
}
}
return null;
};
prototype["renderAnnouncement"] = function renderAnnouncement() {
const self = this;
const props = this.props;
({ channel, guild } = props);
if (callback2(channel.type)) {
if (null != guild) {
const features = guild.features;
if (features.has(constants4.NEWS)) {
let rulesChannelId;
if (guild != null) {
rulesChannelId = guild.rulesChannelId;
}
if (channel.id !== rulesChannelId) {
let prop;
if (guild != null) {
prop = guild.publicUpdatesChannelId;
2026-07-20 16:05:17 +00:00
}
2026-07-29 08:29:29 +00:00
if (channel.id !== prop) {
const items = [];
let obj = { description: null, hasIcons: false, children: null };
obj = { children: null };
2026-08-24 06:08:38 +00:00
const intl = getSystemLocale.intl;
2026-07-29 08:29:29 +00:00
obj = { documentationLink: null };
2026-08-24 06:08:38 +00:00
obj[0] = combinedDefault.getArticleURL(constants5.ANNOUNCEMENT_CHANNELS);
const items1 = [intl.format(getSystemLocale.t.tI7KNX, obj), "\n\n", ];
const intl2 = getSystemLocale.intl;
items1[2] = intl2.string(getSystemLocale.t["2Ab4Id"]);
2026-07-29 08:29:29 +00:00
obj[0] = items1;
obj[0] = callback4(closure_45, obj);
2026-08-24 06:08:38 +00:00
obj1 = { disabled: null, label: null, value: null, onValueChange: null };
2026-07-29 08:29:29 +00:00
obj1[0] = !props.canManageChannels;
2026-08-24 06:08:38 +00:00
const intl3 = getSystemLocale.intl;
obj1[1] = intl3.string(getSystemLocale.t.Au2b7m);
2026-07-29 08:29:29 +00:00
obj1[2] = channel.type === constants2.GUILD_ANNOUNCEMENT;
const handleAnnouncementChange = self.handleAnnouncementChange;
obj1[3] = handleAnnouncementChange.bind(self, channel.type === constants2.GUILD_ANNOUNCEMENT);
2026-08-24 06:08:38 +00:00
obj[2] = callback3(TableSwitchRow.TableSwitchRow, obj1);
items.push(callback3(TableRowGroupTitle.TableRowGroup, obj, "announcement-section"));
2026-07-29 08:29:29 +00:00
return items;
2026-07-20 16:05:17 +00:00
}
}
}
}
2026-07-29 08:29:29 +00:00
}
return null;
};
prototype["renderBitrateSettings"] = function renderBitrateSettings() {
const props = this.props;
const channel = props.channel;
({ canManageChannels, guild } = props);
if (this.showVoiceSettings()) {
if (canManageChannels) {
const items = [];
2026-08-24 06:08:38 +00:00
let obj = allowChannelAccess;
2026-07-29 08:29:29 +00:00
const bitrateLimit = obj.getBitrateLimit(guild, channel);
obj = { description: null, hasIcons: false, children: null };
2026-08-24 06:08:38 +00:00
const intl = getSystemLocale.intl;
2026-07-29 08:29:29 +00:00
obj = { bitrate: null };
obj[0] = closure_23 / 1000;
2026-08-24 06:08:38 +00:00
obj[0] = intl.format(getSystemLocale.t.SbQJk5, obj);
obj1 = { children: null };
2026-07-29 08:29:29 +00:00
const obj2 = { style: null, children: null };
obj2[0] = { flexDirection: "row", justifyContent: "space-between", alignItems: "center", flexWrap: "wrap" };
const obj3 = { variant: "text-md/semibold", color: "mobile-text-heading-primary", style: null, children: null };
obj3[2] = { flexShrink: 1 };
2026-08-24 06:08:38 +00:00
const intl2 = getSystemLocale.intl;
obj3[3] = intl2.string(getSystemLocale.t.w2d0vU);
const items1 = [callback3(Text.Text, obj3), ];
2026-07-29 08:29:29 +00:00
const obj4 = { variant: "text-md/medium", color: "text-muted", children: null };
const _Math = Math;
const _HermesInternal = HermesInternal;
obj4[2] = "" + Math.round(channel.bitrate / 1000) + "kbps";
2026-08-24 06:08:38 +00:00
items1[1] = callback3(Text.Text, obj4);
2026-07-29 08:29:29 +00:00
obj2[1] = items1;
const items2 = [callback4(View, obj2), ];
const obj5 = { style: null, value: null, minimumValue: null, maximumValue: null, onValueChange: null };
obj5[0] = tmp.slider;
const _Math2 = Math;
obj5[1] = Math.min(channel.bitrate, bitrateLimit);
obj5[2] = closure_24;
obj5[3] = bitrateLimit;
obj5[4] = this.handleBitRateChange;
2026-08-24 06:08:38 +00:00
items2[1] = callback3(Slider.Slider, obj5);
2026-07-29 08:29:29 +00:00
obj1[0] = items2;
2026-08-24 06:08:38 +00:00
obj[2] = callback4(PressableCard.Card, obj1);
items.push(callback3(TableRowGroupTitle.TableRowGroup, obj, "bitrate-section"));
2026-07-29 08:29:29 +00:00
return items;
2026-07-20 16:05:17 +00:00
}
2026-07-29 08:29:29 +00:00
}
return null;
};
prototype["renderVideoQualityModeSettings"] = function renderVideoQualityModeSettings() {
({ channel, canManageChannels } = this.props);
if (this.showVoiceSettings()) {
if (canManageChannels) {
const items = [];
let obj = { title: null, description: null, value: null, onChange: null, hasIcons: false, children: null };
2026-08-24 06:08:38 +00:00
const intl = getSystemLocale.intl;
obj[0] = intl.string(getSystemLocale.t.jhJEJs);
const intl2 = getSystemLocale.intl;
obj[1] = intl2.format(getSystemLocale.t.c5W7Ss, {});
2026-07-29 08:29:29 +00:00
let AUTO = channel.videoQualityMode;
if (AUTO == null) {
AUTO = constants7.AUTO;
2026-07-20 16:05:17 +00:00
}
2026-07-29 08:29:29 +00:00
obj[2] = AUTO;
obj[3] = this.handleVideoQualityModeChange;
obj = { label: null, value: null };
const intl3 = tmp2(1236).intl;
2026-08-24 06:08:38 +00:00
obj[0] = intl3.string(getSystemLocale.t.jjKYpu);
2026-07-29 08:29:29 +00:00
obj[1] = constants7.AUTO;
2026-08-24 06:08:38 +00:00
const items1 = [callback3(TableRadioRow.TableRadioRow, obj), ];
2026-07-29 08:29:29 +00:00
obj = { label: null, value: null };
const intl4 = tmp2(1236).intl;
2026-08-24 06:08:38 +00:00
obj[0] = intl4.string(getSystemLocale.t["7jOoJE"]);
2026-07-29 08:29:29 +00:00
obj[1] = constants7.FULL;
2026-08-24 06:08:38 +00:00
items1[1] = callback3(TableRadioRow.TableRadioRow, obj);
2026-07-29 08:29:29 +00:00
obj[5] = items1;
2026-08-24 06:08:38 +00:00
items.push(closure_44(context.TableRadioGroup, obj, "video-quality-section"));
2026-07-29 08:29:29 +00:00
return items;
2026-07-20 16:05:17 +00:00
}
2026-07-29 08:29:29 +00:00
}
return null;
};
prototype["renderUserLimitSettings"] = function renderUserLimitSettings() {
const props = this.props;
const channel = props.channel;
if (this.showVoiceSettings()) {
if (props.canManageChannels) {
const _Math = Math;
const rounded = Math.round(channel.userLimit);
if (0 === rounded) {
2026-08-24 06:08:38 +00:00
const intl2 = getSystemLocale.intl;
let stringResult = intl2.string(getSystemLocale.t.XX5ciX);
2026-07-29 08:29:29 +00:00
let tmp7 = require;
2026-07-20 16:05:17 +00:00
} else {
2026-08-24 06:08:38 +00:00
const intl = getSystemLocale.intl;
2026-07-29 08:29:29 +00:00
let obj = { num: null };
obj[0] = rounded;
2026-08-24 06:08:38 +00:00
stringResult = intl.formatToPlainString(getSystemLocale.t["3uHFUR"], obj);
2026-07-29 08:29:29 +00:00
tmp7 = require;
2026-07-20 16:05:17 +00:00
}
2026-07-29 08:29:29 +00:00
const tmp10 = channel.isGuildStageVoice() ? closure_33 : closure_32;
const items = [];
const intl3 = tmp7(1236).intl;
const format = intl3.format;
const t = tmp7(1236).t;
if (isGuildStageVoiceResult) {
let formatResult = format(t.OqZI8D, {});
} else {
formatResult = format(t["8yb3JT"], {});
2026-07-20 16:05:17 +00:00
}
2026-07-29 08:29:29 +00:00
obj = { description: null, hasIcons: false, children: null };
obj[0] = formatResult;
obj = { children: null };
2026-08-24 06:08:38 +00:00
obj1 = { style: null, children: null };
2026-07-29 08:29:29 +00:00
obj1[0] = { flexDirection: "row", justifyContent: "space-between", alignItems: "center", flexWrap: "wrap" };
const obj2 = { variant: "text-md/semibold", color: "mobile-text-heading-primary", style: null, children: null };
obj2[2] = { flexShrink: 1 };
const intl4 = tmp7(1236).intl;
obj2[3] = intl4.string(tmp7(1236).t["/AoSGN"]);
2026-08-25 06:04:03 +00:00
const items1 = [closure_43(tmp7(4376).Text, obj2), ];
2026-07-29 08:29:29 +00:00
const obj3 = { variant: "text-md/medium", color: "text-muted", children: null };
obj3[2] = stringResult;
2026-08-25 06:04:03 +00:00
items1[1] = closure_43(tmp7(4376).Text, obj3);
2026-07-29 08:29:29 +00:00
obj1[1] = items1;
const items2 = [callback4(View, obj1), ];
const obj4 = { style: null, value: null, minimumValue: 0, maximumValue: null, onValueChange: null };
obj4[0] = tmp.slider;
const _Math2 = Math;
obj4[1] = Math.min(channel.userLimit, tmp10);
obj4[3] = tmp10;
obj4[4] = this.handleUserLimitChange;
2026-08-25 06:04:03 +00:00
items2[1] = closure_43(tmp7(13635).Slider, obj4);
2026-07-29 08:29:29 +00:00
obj[0] = items2;
2026-08-25 06:04:03 +00:00
obj[2] = callback4(tmp7(5482).Card, obj);
items.push(closure_43(tmp7(5873).TableRowGroup, obj, "channel-user-limit"));
2026-07-29 08:29:29 +00:00
return items;
2026-07-20 16:05:17 +00:00
}
2026-07-29 08:29:29 +00:00
}
return null;
};
prototype["renderRegionOverride"] = function renderRegionOverride() {
let self = this;
self = this;
const props = this.props;
({ regions, channel } = props);
if (null == props.guild) {
return null;
} else {
if (self.showVoiceSettings()) {
2026-07-20 16:05:17 +00:00
if (tmp) {
2026-07-29 08:29:29 +00:00
if (!channel.isGuildStageVoice()) {
let tmp2 = null == regions;
if (!tmp2) {
tmp2 = 0 === regions.length;
}
let found = null;
if (null != regions) {
found = regions.find((id) => id.id === channel.rtcRegion);
}
if (null != found) {
let name = found.name;
2026-07-20 16:05:17 +00:00
} else {
2026-07-29 08:29:29 +00:00
const intl = channel(1236).intl;
name = intl.string(channel(1236).t.JEmsap);
2026-07-20 16:05:17 +00:00
}
2026-07-29 08:29:29 +00:00
const items = [];
let obj = { title: null, description: null, hasIcons: false, children: null };
const intl2 = channel(1236).intl;
obj[0] = intl2.string(channel(1236).t["Ms8bX+"]);
const intl3 = channel(1236).intl;
obj[1] = intl3.string(channel(1236).t["dbTs+z"]);
obj = { label: null, trailing: null, arrow: true, disabled: null, onPress: null };
const intl4 = channel(1236).intl;
obj[0] = intl4.string(channel(1236).t["Ms8bX+"]);
obj = { text: null };
obj[0] = name;
2026-08-25 06:04:03 +00:00
obj[1] = callback3(channel(5480).TableRow.TrailingText, obj);
2026-07-29 08:29:29 +00:00
obj[3] = tmp2;
obj[4] = function onPress() {
2026-08-24 06:08:38 +00:00
return self.pushScreen(closure_1_25.CHANGE_RTC_REGION);
2026-07-29 08:29:29 +00:00
};
2026-08-25 06:04:03 +00:00
obj[3] = callback3(channel(5480).TableRow, obj);
items.push(callback3(channel(5873).TableRowGroup, obj, "channel-region-override"));
2026-07-29 08:29:29 +00:00
return items;
}
2026-07-20 16:05:17 +00:00
}
}
2026-07-29 08:29:29 +00:00
return null;
}
};
prototype["showVoiceSettings"] = function showVoiceSettings() {
const channel = this.props.channel;
let hasItem = null != channel && null != channel.guild_id;
if (hasItem) {
hasItem = set.has(channel.type);
}
if (hasItem) {
let enabled = channel.isGuildVocal();
if (!enabled) {
2026-08-24 06:08:38 +00:00
const VoiceInThreadsExperiment = useCanUnarchiveThread.VoiceInThreadsExperiment;
2026-07-29 08:29:29 +00:00
const obj = { guildId: null, location: "9b50bd_1" };
obj[0] = channel.guild_id;
enabled = VoiceInThreadsExperiment.getCurrentConfig(obj).enabled;
}
hasItem = enabled;
}
return hasItem;
};
prototype["renderPermissions"] = function renderPermissions() {
const self = this;
if (!this.props.canManageRoles) {
return null;
} else {
let ShieldUserIcon = self;
let tmp2Result = dependencyMap;
let obj = { helperText: null, hasIcons: true, children: null };
const intl = self(1236).intl;
obj[0] = intl.string(self(1236).t.UAoMCL);
if (tmp.type === constants2.GUILD_CATEGORY) {
const intl3 = ShieldUserIcon(1236).intl;
let stringResult = intl3.string(ShieldUserIcon(1236).t.PgkvDf);
} else {
const intl2 = ShieldUserIcon(1236).intl;
stringResult = intl2.string(ShieldUserIcon(1236).t.BAZMBn);
}
obj = { label: null, arrow: true, icon: null, onPress: null };
obj[0] = stringResult;
2026-08-25 06:04:03 +00:00
ShieldUserIcon = ShieldUserIcon(9153).ShieldUserIcon;
2026-07-29 08:29:29 +00:00
tmp2Result = tmp2(ShieldUserIcon, {});
obj[2] = tmp2Result;
obj[3] = function onPress() {
2026-08-24 06:08:38 +00:00
return self.pushScreen(closure_1_25.PERMISSIONS, { origin: closure_1_25.OVERVIEW });
2026-07-29 08:29:29 +00:00
};
2026-08-25 06:04:03 +00:00
obj[2] = closure_43(self(5480).TableRow, obj);
tmp2Result = tmp2(self(5873).TableRowGroup, obj);
2026-07-29 08:29:29 +00:00
}
};
prototype["renderSettingsSection"] = function renderSettingsSection(items) {
let tmp = null;
if (items.length > 0) {
const obj = { hasIcons: true, children: null };
obj[1] = items;
2026-08-24 06:08:38 +00:00
tmp = callback3(TableRowGroupTitle.TableRowGroup, obj);
2026-07-29 08:29:29 +00:00
}
return tmp;
};
prototype["renderCommonSettingsSection"] = function renderCommonSettingsSection() {
let self = this;
self = this;
const props = this.props;
const channel = props.channel;
let canManageChannels = props.canManageChannels;
const items = [];
if (tmp2) {
let obj = { label: null, arrow: true, icon: null, onPress: null };
const intl = channel(1236).intl;
obj[0] = intl.string(channel(1236).t.h850Ss);
2026-08-25 06:04:03 +00:00
obj[2] = callback3(channel(9284).BellIcon, {});
2026-07-29 08:29:29 +00:00
obj[3] = function onPress() {
if (channel.isThread()) {
2026-08-24 06:08:38 +00:00
let result = channel(closure_1_2[70]).showThreadNotificationsBottomSheet(channel);
const obj = channel(closure_1_2[70]);
2026-07-20 16:05:17 +00:00
} else {
2026-08-24 06:08:38 +00:00
result = self.pushScreen(closure_1_25.NOTIFICATIONS);
2026-07-29 08:29:29 +00:00
}
return result;
};
2026-08-25 06:04:03 +00:00
items.push(callback3(channel(5480).TableRow, obj, "rowNotifications"));
2026-07-29 08:29:29 +00:00
}
if (callback2(channel.type)) {
obj = { label: null, arrow: true, icon: null, onPress: null, disabled: null };
const intl2 = channel(1236).intl;
obj[0] = intl2.string(channel(1236).t["mp1N/2"]);
obj = { channelId: null };
obj[0] = channel.id;
obj[2] = callback3(PinImage, obj);
obj[3] = function onPress() {
2026-08-24 06:08:38 +00:00
return self.pushScreen(closure_1_25.PINNED_MESSAGES);
2026-07-29 08:29:29 +00:00
};
obj[4] = self.props.pinDisabled;
2026-08-25 06:04:03 +00:00
items.push(callback3(channel(5480).TableRow, obj, "rowPinnedMessages"));
2026-07-29 08:29:29 +00:00
}
if (canManageChannels) {
canManageChannels = channel.type !== constants2.GUILD_CATEGORY;
}
if (canManageChannels) {
canManageChannels = !channel.isThread();
}
if (canManageChannels) {
2026-08-24 06:08:38 +00:00
obj1 = { label: null, arrow: true, icon: null, onPress: null };
2026-07-29 08:29:29 +00:00
const intl3 = channel(1236).intl;
obj1[0] = intl3.string(channel(1236).t.ngRFjZ);
2026-08-25 06:04:03 +00:00
obj1[2] = callback3(channel(4323).LinkIcon, {});
2026-07-29 08:29:29 +00:00
obj1[3] = function onPress() {
2026-08-24 06:08:38 +00:00
return self.pushScreen(closure_1_25.INSTANT_INVITES);
2026-07-29 08:29:29 +00:00
};
2026-08-25 06:04:03 +00:00
items.push(callback3(channel(5480).TableRow, obj1, "rowInstantInvites"));
2026-07-29 08:29:29 +00:00
}
return self.renderSettingsSection(items);
};
prototype["renderDefaultForumLayout"] = function renderDefaultForumLayout() {
const self = this;
const channel = this.props.channel;
if (!channel.isForumChannel()) {
return null;
} else {
let GridSquareIcon = self;
let obj = dependencyMap;
obj = { description: null, hasIcons: true, children: null };
const intl = self(1236).intl;
obj[0] = intl.string(self(1236).t.mOSViT);
obj = { label: null, trailing: null, arrow: true, icon: null, onPress: null };
const intl2 = self(1236).intl;
obj[0] = intl2.string(self(1236).t["kQvoC/"]);
2026-08-11 06:20:06 +00:00
if (channel.defaultForumLayout === self(1401).ForumLayout.GRID) {
2026-07-29 08:29:29 +00:00
const intl4 = GridSquareIcon(1236).intl;
let stringResult = intl4.string(GridSquareIcon(1236).t["8RswJG"]);
} else {
const intl3 = GridSquareIcon(1236).intl;
stringResult = intl3.string(GridSquareIcon(1236).t["4HXEZG"]);
}
2026-08-24 06:08:38 +00:00
obj1 = { text: null };
2026-07-29 08:29:29 +00:00
obj1[0] = stringResult;
2026-08-25 06:04:03 +00:00
obj[1] = closure_43(self(5480).TableRow.TrailingText, obj1);
2026-08-11 06:20:06 +00:00
if (channel.defaultForumLayout === GridSquareIcon(1401).ForumLayout.GRID) {
2026-08-25 06:04:03 +00:00
GridSquareIcon = GridSquareIcon(16165).GridSquareIcon;
2026-07-29 08:29:29 +00:00
obj = {};
let tmpResult = tmp(GridSquareIcon, obj);
} else {
2026-08-25 06:04:03 +00:00
tmpResult = tmp(GridSquareIcon(8591).ListViewIcon, {});
2026-07-29 08:29:29 +00:00
}
obj[3] = tmpResult;
obj[4] = function onPress() {
2026-08-24 06:08:38 +00:00
return self.pushScreen(closure_1_25.DEFAULT_FORUM_LAYOUT);
2026-07-29 08:29:29 +00:00
};
2026-08-25 06:04:03 +00:00
obj[2] = closure_43(self(5480).TableRow, obj, "forumDefaultLayout");
tmpResult = tmp(self(5873).TableRowGroup, obj, "default-forum-layout");
2026-07-29 08:29:29 +00:00
}
};
prototype["renderUncommonSettingsSection"] = function renderUncommonSettingsSection() {
let self = this;
self = this;
const props = this.props;
const canManageWebhooks = props.canManageWebhooks;
let tmp = undefined !== canManageWebhooks && canManageWebhooks;
2026-08-24 06:08:38 +00:00
closure_1 = tmp;
2026-07-29 08:29:29 +00:00
let obj = require(self[75]);
const result = obj.canUnlinkLobbyChannel(props.channel);
require = result;
if (!tmp) {
tmp = result;
}
const items = [];
if (tmp) {
obj = { label: null, arrow: true, icon: null, onPress: null };
const intl = tmp2(tmp3[30]).intl;
obj[0] = intl.string(tmp2(tmp3[30]).t.CIsNZw);
obj[2] = callback3(tmp2(tmp3[76]).PuzzlePieceIcon, {});
obj[3] = function onPress() {
2026-08-24 06:08:38 +00:00
return self.pushScreen(closure_1_25.INTEGRATIONS, { canManageWebhooks: closure_1, canUnlinkLobby: closure_0 });
2026-07-29 08:29:29 +00:00
};
items.push(callback3(tmp2(tmp3[66]).TableRow, obj, "rowIntegrations"));
}
return self.renderSettingsSection(items);
};
prototype["renderThreadManagementActions"] = function renderThreadManagementActions() {
const props = this.props;
({ channel: require, isThreadModerator, isLockedThread, isArchivedThread, isForumPost } = props);
({ canManageThread, canUnarchiveThread, hasJoinedThread } = props);
if (hasJoinedThread) {
const items = [null, , , , , ];
let tmp8 = null;
if (isArchivedThread) {
tmp8 = null;
if (canUnarchiveThread) {
let obj = { icon: null, label: null, onPress: null };
2026-08-25 06:04:03 +00:00
obj[0] = callback3(tmp2(4343).ClockIcon, {});
2026-07-29 08:29:29 +00:00
const intl2 = tmp2(1236).intl;
const string2 = intl2.string;
let cnRubV = tmp2(1236).t;
if (isForumPost) {
cnRubV = cnRubV.cnRubV;
let string2Result = string2(cnRubV);
2026-07-20 16:05:17 +00:00
} else {
2026-07-29 08:29:29 +00:00
string2Result = string2(cnRubV.S9E4G7);
2026-07-20 16:05:17 +00:00
}
2026-07-29 08:29:29 +00:00
obj[1] = string2Result;
obj[2] = function onPress() {
2026-08-24 06:08:38 +00:00
return closure_1_1(closure_1_2[78]).unarchiveThread(closure_0, false);
2026-07-20 16:05:17 +00:00
};
2026-08-25 06:04:03 +00:00
callback3(tmp2(5480).TableRow, obj);
2026-07-29 08:29:29 +00:00
const tmp9 = callback3;
2026-07-20 16:05:17 +00:00
}
}
2026-07-29 08:29:29 +00:00
items[1] = tmp8;
let tmp12 = null;
if (!isArchivedThread) {
tmp12 = null;
if (canManageThread) {
obj = { icon: null, label: null, onPress: null };
2026-08-25 06:04:03 +00:00
obj[0] = callback3(tmp2(4333).XLargeIcon, {});
2026-07-29 08:29:29 +00:00
const intl3 = tmp2(1236).intl;
const string3 = intl3.string;
let BTs4Kb = tmp2(1236).t;
if (isForumPost) {
BTs4Kb = BTs4Kb.BTs4Kb;
let string3Result = string3(BTs4Kb);
} else {
string3Result = string3(BTs4Kb.wiIevd);
}
obj[1] = string3Result;
obj[2] = function onPress() {
2026-08-24 06:08:38 +00:00
return closure_1_1(closure_1_2[78]).archiveThread(closure_0, false);
2026-07-20 16:05:17 +00:00
};
2026-08-25 06:04:03 +00:00
callback3(tmp2(5480).TableRow, obj);
2026-07-29 08:29:29 +00:00
const tmp13 = callback3;
2026-07-20 16:05:17 +00:00
}
}
2026-07-29 08:29:29 +00:00
items[2] = tmp12;
let tmp16 = null;
if (isThreadModerator) {
tmp16 = null;
if (isLockedThread) {
2026-08-24 06:08:38 +00:00
obj1 = { icon: null, label: null, onPress: null };
2026-08-25 06:04:03 +00:00
obj1[0] = callback3(tmp2(4925).LockIcon, {});
2026-07-29 08:29:29 +00:00
const intl4 = tmp2(1236).intl;
const string4 = intl4.string;
_OKSxp = tmp2(1236).t;
2026-07-20 16:05:17 +00:00
if (isForumPost) {
2026-07-29 08:29:29 +00:00
_OKSxp = _OKSxp["/OKSxp"];
let string4Result = string4(_OKSxp);
2026-07-20 16:05:17 +00:00
} else {
2026-07-29 08:29:29 +00:00
string4Result = string4(_OKSxp["jeyb/W"]);
2026-07-20 16:05:17 +00:00
}
2026-07-29 08:29:29 +00:00
obj1[1] = string4Result;
obj1[2] = function onPress() {
2026-08-24 06:08:38 +00:00
return closure_1_1(closure_1_2[78]).unlockThread(closure_0);
2026-07-20 16:05:17 +00:00
};
2026-08-25 06:04:03 +00:00
callback3(tmp2(5480).TableRow, obj1);
2026-07-29 08:29:29 +00:00
const tmp17 = callback3;
2026-07-20 16:05:17 +00:00
}
}
2026-07-29 08:29:29 +00:00
items[3] = tmp16;
let tmp20 = null;
if (isThreadModerator) {
tmp20 = null;
if (!isLockedThread) {
const obj2 = { icon: null, label: null, onPress: null };
2026-08-25 06:04:03 +00:00
obj2[0] = callback3(tmp2(4925).LockIcon, {});
2026-07-29 08:29:29 +00:00
const intl5 = tmp2(1236).intl;
const string5 = intl5.string;
Ur_0Na = tmp2(1236).t;
if (isForumPost) {
Ur_0Na = Ur_0Na["Ur/0Na"];
let string5Result = string5(Ur_0Na);
2026-07-20 16:05:17 +00:00
} else {
2026-07-29 08:29:29 +00:00
string5Result = string5(Ur_0Na.HoCqm8);
2026-07-20 16:05:17 +00:00
}
2026-07-29 08:29:29 +00:00
obj2[1] = string5Result;
obj2[2] = function onPress() {
2026-08-24 06:08:38 +00:00
return closure_1_1(closure_1_2[78]).lockThread(closure_0);
2026-07-29 08:29:29 +00:00
};
2026-08-25 06:04:03 +00:00
callback3(tmp2(5480).TableRow, obj2);
2026-07-29 08:29:29 +00:00
const tmp21 = callback3;
2026-07-20 16:05:17 +00:00
}
}
2026-07-29 08:29:29 +00:00
const obj3 = { hasIcons: true, children: null };
items[4] = tmp20;
const obj4 = { icon: null, label: null, onPress: null };
2026-08-25 06:04:03 +00:00
obj4[0] = callback3(tmp2(4323).LinkIcon, {});
2026-07-29 08:29:29 +00:00
const intl6 = tmp2(1236).intl;
obj4[1] = intl6.string(tmp2(1236).t.WqhZss);
obj4[2] = function onPress() {
2026-08-24 06:08:38 +00:00
return closure_1_0(closure_1_2[82]).copyGuildChannelOrThreadLink(closure_0.guild_id, closure_0.id);
2026-07-29 08:29:29 +00:00
};
2026-08-25 06:04:03 +00:00
items[5] = callback3(tmp2(5480).TableRow, obj4);
2026-07-29 08:29:29 +00:00
obj3[1] = items;
return closure_44(tmp4, obj3);
} else {
obj = { icon: null, label: null, onPress: null };
2026-08-25 06:04:03 +00:00
obj[0] = callback3(tmp2(9872).GroupPlusIcon, {});
2026-07-29 08:29:29 +00:00
const intl = tmp2(1236).intl;
const string = intl.string;
let ihLPiO = tmp2(1236).t;
if (isForumPost) {
ihLPiO = ihLPiO.ihLPiO;
let stringResult = string(ihLPiO);
} else {
stringResult = string(ihLPiO["10kukS"]);
}
obj[1] = stringResult;
obj[2] = function onPress() {
2026-08-24 06:08:38 +00:00
return closure_1_1(closure_1_2[78]).joinThread(closure_0, "Context Menu");
2026-07-29 08:29:29 +00:00
};
2026-08-25 06:04:03 +00:00
callback3(tmp2(5480).TableRow, obj);
2026-07-29 08:29:29 +00:00
const tmp5 = callback3;
}
};
prototype["renderDeleteButton"] = function renderDeleteButton() {
const props = this.props;
const channel = props.channel;
({ canManageChannels, isForumPost } = props);
({ isThreadModerator, hasJoinedThread } = props);
if (channel.isThread()) {
canManageChannels = isThreadModerator;
}
let tmp = null;
if (canManageChannels) {
if (channel.type === constants2.GUILD_CATEGORY) {
const intl3 = channel(1236).intl;
let stringResult = intl3.string(channel(1236).t.ifbXnL);
let tmp8 = channel;
} else if (isForumPost) {
const intl2 = channel(1236).intl;
stringResult = intl2.string(channel(1236).t.nEOg1N);
tmp8 = channel;
} else {
const intl = channel(1236).intl;
const string = intl.string;
const t = channel(1236).t;
if (isThreadResult) {
stringResult = string(t.H7vTe2);
tmp8 = tmp4;
2026-07-20 16:05:17 +00:00
} else {
2026-07-29 08:29:29 +00:00
stringResult = string(t["8D8Rsb"]);
tmp8 = tmp4;
2026-07-20 16:05:17 +00:00
}
2026-07-29 08:29:29 +00:00
isThreadResult = channel.isThread();
2026-07-20 16:05:17 +00:00
}
2026-07-29 08:29:29 +00:00
if (!hasJoinedThread) {
let obj = { hasIcons: true, children: null };
const items = [null, ];
obj = { variant: "danger", icon: null, label: null, onPress: null };
2026-08-25 06:04:03 +00:00
obj[1] = callback3(tmp8(4338).TrashIcon, { color: "text-feedback-critical" });
2026-07-29 08:29:29 +00:00
obj[2] = stringResult;
obj[3] = this.handleDeleteChannel;
2026-08-25 06:04:03 +00:00
items[1] = callback3(tmp8(5480).TableRow, obj);
2026-07-29 08:29:29 +00:00
obj[1] = items;
tmp = tmp13(tmp14, obj);
} else {
obj = { variant: "danger", icon: null, label: null, onPress: null };
2026-08-25 06:04:03 +00:00
obj[1] = callback3(tmp8(4321).UserMinusIcon, { color: "text-feedback-critical" });
2026-07-29 08:29:29 +00:00
const intl4 = tmp8(1236).intl;
const string2 = intl4.string;
if (isForumPost) {
let string2Result = string2(_2LsZdT);
} else {
string2Result = string2(_2LsZdT["fa/84m"]);
2026-07-20 16:05:17 +00:00
}
2026-07-29 08:29:29 +00:00
obj[2] = string2Result;
obj[3] = function onPress() {
2026-08-24 06:08:38 +00:00
return closure_1_1(closure_1_2[78]).leaveThread(channel, "Context Menu");
2026-07-29 08:29:29 +00:00
};
2026-08-25 06:04:03 +00:00
callback3(tmp8(5480).TableRow, obj);
2026-07-29 08:29:29 +00:00
const tmp17 = callback3;
2026-07-20 16:05:17 +00:00
}
2026-07-29 08:29:29 +00:00
tmp13 = closure_44;
}
return tmp;
};
prototype["renderForumTags"] = function renderForumTags() {
let self = this;
self = this;
2026-08-24 06:08:38 +00:00
const tmp = callback6(this.context);
2026-07-29 08:29:29 +00:00
({ channel, canManageChannels } = this.props);
if (channel.isForumLikeChannel()) {
let availableTags = channel.availableTags;
if (availableTags != null) {
const everyResult = availableTags.every((moderated) => moderated.moderated);
}
let tmp3 = canManageChannels;
if (canManageChannels) {
tmp3 = channel.availableTags.length < MAX_FORUM_TAGS;
}
2026-08-24 06:08:38 +00:00
error = self.getError("available_tags");
2026-07-29 08:29:29 +00:00
let obj = { spacing: null, children: null };
obj[0] = self(712).space.PX_12;
obj = { title: null, description: null, hasIcons: false, children: null };
const intl = canManageChannels(1236).intl;
obj[0] = intl.string(canManageChannels(1236).t["P/y+sj"]);
let stringResult;
if (channel.availableTags.length <= 0) {
const intl2 = tmp7(1236).intl;
stringResult = intl2.string(tmp7(1236).t["3v8kZH"]);
}
obj[1] = stringResult;
obj = { style: null, children: null };
obj[0] = tmp.tagsWrapper;
let tmp6Result = null;
if (channel.availableTags.length > 0) {
availableTags = channel.availableTags;
2026-08-24 06:08:38 +00:00
const items = [availableTags.map((id) => closure_1_43(self(closure_1_2[86]), { tag: id, onPress: self.handlePressTag, disabled: !canManageChannels }, id.id)), ];
2026-07-29 08:29:29 +00:00
let tmp10Result = null;
if (tmp3) {
2026-08-24 06:08:38 +00:00
obj1 = { style: null, children: null };
2026-07-29 08:29:29 +00:00
obj1[0] = tmp.addTagIconButtonWrapper;
const obj2 = { icon: null, size: "sm", onPress: null, accessibilityLabel: null };
const obj3 = { size: "sm", color: null };
obj3[1] = self(712).colors.WHITE;
2026-08-25 06:04:03 +00:00
obj2[0] = tmp10(tmp7(9578).PlusSmallIcon, obj3);
2026-07-29 08:29:29 +00:00
obj2[2] = function onPress() {
return self.handlePressTag();
};
const intl3 = tmp7(1236).intl;
obj2[3] = intl3.string(tmp7(1236).t["/jubeD"]);
2026-08-25 06:04:03 +00:00
obj1[1] = tmp10(tmp7(7896).IconButton, obj2);
2026-07-29 08:29:29 +00:00
tmp10Result = tmp10(tmp12, obj1);
2026-07-20 16:05:17 +00:00
}
2026-07-29 08:29:29 +00:00
const obj4 = { children: null };
items[1] = tmp10Result;
obj4[0] = items;
tmp6Result = tmp6(closure_45, obj4);
const tmp14 = closure_45;
}
obj[1] = tmp6Result;
obj[3] = closure_43(View, obj);
2026-08-25 06:04:03 +00:00
const items1 = [closure_43(canManageChannels(5873).TableRowGroup, obj), , , ];
2026-07-29 08:29:29 +00:00
tmp10Result = null;
if (channel.availableTags.length <= 0) {
const obj5 = { disabled: null, onPress: null, style: null, accessibilityRole: "button", children: null };
obj5[0] = !canManageChannels;
obj5[1] = function onPress() {
return self.handlePressTag();
};
obj5[2] = tmp.createTagButton;
const obj6 = { variant: "text-sm/semibold", color: "text-brand", style: null, children: null };
obj6[2] = tmp.createTagButtonText;
const intl4 = tmp7(1236).intl;
obj6[3] = intl4.string(tmp7(1236).t.F4is7L);
2026-08-25 06:04:03 +00:00
obj5[4] = tmp10(tmp7(4376).Text, obj6);
tmp10Result = tmp10(tmp7(4949).PressableOpacity, obj5);
2026-07-20 16:05:17 +00:00
}
2026-07-29 08:29:29 +00:00
items1[1] = tmp10Result;
let tmp10Result1 = null != error && error.length > 0;
if (tmp10Result1) {
const obj7 = { variant: "text-sm/normal", color: "text-feedback-critical", children: null };
obj7[2] = error;
2026-08-25 06:04:03 +00:00
tmp10Result1 = tmp10(tmp7(4376).Text, obj7);
2026-07-20 16:05:17 +00:00
}
2026-07-29 08:29:29 +00:00
items1[2] = tmp10Result1;
let tmp18 = !canManageChannels;
if (canManageChannels) {
tmp18 = everyResult;
2026-07-20 16:05:17 +00:00
}
2026-07-29 08:29:29 +00:00
const obj8 = { hasIcons: false, children: null };
const obj9 = { disabled: null, label: null, value: null, onValueChange: null };
obj9[0] = tmp18;
const intl5 = tmp7(1236).intl;
obj9[1] = intl5.string(canManageChannels(1236).t.yX24uI);
obj9[2] = channel.hasFlag(constants8.REQUIRE_TAG);
obj9[3] = self.handleToggleRequireTag;
2026-08-25 06:04:03 +00:00
obj8[1] = closure_43(canManageChannels(5874).TableSwitchRow, obj9);
items1[3] = closure_43(canManageChannels(5873).TableRowGroup, obj8);
2026-07-29 08:29:29 +00:00
obj[1] = items1;
2026-08-25 06:04:03 +00:00
return closure_44(canManageChannels(4813).Stack, obj);
2026-07-29 08:29:29 +00:00
} else {
return null;
}
};
prototype["renderShowMediaDownloadOptions"] = function renderShowMediaDownloadOptions() {
const props = this.props;
const channel = props.channel;
let tmp = null;
if (channel.isMediaChannel()) {
let obj = { hasIcons: false, children: null };
obj = { disabled: null, label: null, subLabel: null, value: null, onValueChange: null };
obj[0] = !props.canManageChannels;
2026-08-24 06:08:38 +00:00
const intl = getSystemLocale.intl;
obj[1] = intl.string(getSystemLocale.t.u8LZOt);
const intl2 = getSystemLocale.intl;
obj[2] = intl2.string(getSystemLocale.t.J4wCc7);
2026-07-29 08:29:29 +00:00
obj[3] = !channel.hasFlag(constants8.HIDE_MEDIA_DOWNLOAD_OPTIONS);
obj[4] = this.handleToggleShowMediaDownloadOptions;
2026-08-24 06:08:38 +00:00
obj[1] = callback3(TableSwitchRow.TableSwitchRow, obj);
tmp = callback3(TableRowGroupTitle.TableRowGroup, obj);
2026-07-29 08:29:29 +00:00
}
return tmp;
};
prototype["renderCategory"] = function renderCategory() {
const self = this;
const props = this.props;
({ category, canManageParent } = props);
if (props.hasCategories) {
if (props.channel.type !== constants2.GUILD_CATEGORY) {
if (null == category) {
const intl = self(1236).intl;
let stringResult = intl.string(self(1236).t.GSfOoo);
let tmp7 = self;
2026-07-20 16:05:17 +00:00
} else {
2026-08-25 06:04:03 +00:00
let obj = self(4574);
2026-08-24 06:08:38 +00:00
stringResult = obj.computeChannelName(category, closure_20, closure_19);
2026-07-29 08:29:29 +00:00
tmp7 = self;
}
obj = { icon: null, label: null, trailing: null, arrow: null, onPress: null };
2026-08-25 06:04:03 +00:00
obj[0] = callback3(tmp7(15511).FolderPlusIcon, {});
2026-07-29 08:29:29 +00:00
const intl2 = tmp7(1236).intl;
obj[1] = intl2.string(tmp7(1236).t.vHCZwr);
obj = { text: null };
obj[0] = stringResult;
2026-08-25 06:04:03 +00:00
obj[2] = callback3(tmp7(5480).TableRow.TrailingText, obj);
2026-07-29 08:29:29 +00:00
obj[3] = canManageParent;
let fn;
if (canManageParent) {
2026-08-24 06:08:38 +00:00
fn = () => self.pushScreen(closure_1_25.CHANGE_CATEGORY);
2026-07-20 16:05:17 +00:00
}
2026-08-24 06:08:38 +00:00
obj1 = { hasIcons: true, children: null };
2026-07-29 08:29:29 +00:00
obj[4] = fn;
2026-08-25 06:04:03 +00:00
obj1[1] = callback3(tmp7(5480).TableRow, obj);
return callback3(tmp7(5873).TableRowGroup, obj1);
2026-07-20 16:05:17 +00:00
}
2026-07-29 08:29:29 +00:00
}
return null;
};
prototype["renderThreadSettings"] = function renderThreadSettings() {
let obj = { children: null };
2026-08-24 06:08:38 +00:00
obj = { spacing: ThemesDefault.space.PX_24, style: callback6(this.context).stackPadding, children: null };
2026-07-29 08:29:29 +00:00
const items = [this.renderChannelInfo(), this.renderCommonSettingsSection(), this.renderThreadManagementActions(), this.renderThreadSpoiler(), this.renderSlowmode(), this.renderAutoArchiveDuration(), this.renderInvitable(), this.renderDeleteButton()];
obj[2] = items;
2026-08-24 06:08:38 +00:00
obj[0] = callback4(Stack.Stack, obj);
return callback3(Form.Form, obj);
2026-07-29 08:29:29 +00:00
};
prototype["renderChannelSettings"] = function renderChannelSettings() {
let obj = { children: null };
2026-08-24 06:08:38 +00:00
obj = { spacing: ThemesDefault.space.PX_24, style: callback6(this.context).stackPadding, children: null };
2026-07-29 08:29:29 +00:00
const items = [this.renderChannelInfo(), this.renderForumTags(), this.renderCategory(), this.renderPermissions(), this.renderCommonSettingsSection(), this.renderDefaultForumLayout(), this.renderDefaultSortOrder(), this.renderDefaultTagSetting(), this.renderAnnouncement(), this.renderNsfwConfig(), this.renderSlowmode(), this.renderDefaultAutoArchiveDuration(), this.renderBitrateSettings(), this.renderVideoQualityModeSettings(), this.renderUserLimitSettings(), this.renderRegionOverride(), this.renderUncommonSettingsSection(), this.renderShowMediaDownloadOptions(), this.renderDeleteButton()];
obj[2] = items;
2026-08-24 06:08:38 +00:00
obj[0] = callback4(Stack.Stack, obj);
return callback3(Form.Form, obj);
2026-07-29 08:29:29 +00:00
};
prototype["render"] = function render() {
const self = this;
if (this.props.isThread) {
let renderThreadSettingsResult = self.renderThreadSettings();
} else {
renderThreadSettingsResult = self.renderChannelSettings();
}
2026-08-24 06:08:38 +00:00
const tmp = callback6(this.context);
return callback3(View, { style: callback6(this.context).screenContainer, children: renderThreadSettingsResult });
2026-07-29 08:29:29 +00:00
};
ChannelSettingsOverview.contextType = require("ManaContext").ThemeContext;
2026-07-23 10:11:24 +00:00
let result = set.fileFinishedImporting("components_native/channel_settings/ChannelSettingsOverview.tsx");
2026-07-20 16:05:17 +00:00
export default function ConnectedChannelSettingsOverview(arg0) {
2026-07-23 10:11:24 +00:00
({ channelId: require, autoFocusElement } = arg0);
2026-07-29 08:29:29 +00:00
let navigation;
let stateFromStores;
let shouldHideChannelContent;
let ref;
let obj = require(navigation[92]);
2026-07-23 10:11:24 +00:00
navigation = obj.useNavigation();
2026-08-24 06:08:38 +00:00
const items = [closure_13];
stateFromStores = require(navigation[24]).useStateFromStores(items, () => closure_1_13.getChannel(closure_0));
2026-07-29 08:29:29 +00:00
let obj2 = require(navigation[24]);
2026-08-24 06:08:38 +00:00
const items1 = [closure_12];
2026-07-29 08:29:29 +00:00
const stateFromStores1 = require(navigation[24]).useStateFromStores(items1, () => channel.getChannel());
const obj4 = require(navigation[24]);
const isThreadModerator = require(navigation[67]).useIsThreadModerator(stateFromStores);
const obj5 = require(navigation[67]);
2026-08-24 06:08:38 +00:00
const items2 = [closure_6];
2026-07-29 08:29:29 +00:00
const stateFromStoresObject = require(navigation[24]).useStateFromStoresObject(items2, () => {
2026-07-20 16:05:17 +00:00
let isMutedResult;
if (null != stateFromStores) {
2026-08-24 06:08:38 +00:00
isMutedResult = closure_1_6.isMuted(tmp.id);
2026-07-20 16:05:17 +00:00
}
2026-07-29 08:29:29 +00:00
const obj = { isMutedThread: isMutedResult, hasJoinedThread: null };
2026-07-20 16:05:17 +00:00
let hasJoinedResult;
if (null != stateFromStores) {
2026-08-24 06:08:38 +00:00
hasJoinedResult = closure_1_6.hasJoined(tmp.id);
2026-07-20 16:05:17 +00:00
}
2026-07-29 08:29:29 +00:00
obj[1] = hasJoinedResult;
2026-07-20 16:05:17 +00:00
return obj;
});
({ isMutedThread, hasJoinedThread } = stateFromStoresObject);
2026-07-29 08:29:29 +00:00
const obj6 = require(navigation[24]);
const canManageThread = require(navigation[67]).useCanManageThread(stateFromStores);
const obj7 = require(navigation[67]);
shouldHideChannelContent = require(navigation[56]).useShouldHideChannelContent(stateFromStores);
const obj8 = require(navigation[56]);
2026-08-24 06:08:38 +00:00
const items3 = [closure_12, closure_15, closure_13, closure_20, closure_18, closure_14, closure_16];
2026-07-20 16:05:17 +00:00
const items4 = [stateFromStores, shouldHideChannelContent];
2026-07-29 08:29:29 +00:00
const stateFromStoresObject1 = require(navigation[24]).useStateFromStoresObject(items3, () => {
2026-08-24 06:08:38 +00:00
const props = closure_1_12.getProps();
2026-07-20 16:05:17 +00:00
({ submitting, errors } = props);
2026-07-29 08:29:29 +00:00
let obj = stateFromStores;
2026-07-20 16:05:17 +00:00
if (null == stateFromStores) {
2026-07-29 08:29:29 +00:00
obj = { isThread: false, submitting: null, errors: null };
obj[1] = submitting;
obj[2] = errors;
2026-07-20 16:05:17 +00:00
return obj;
} else {
2026-08-24 06:08:38 +00:00
const guild = closure_1_15.getGuild(obj.getGuildId());
const channel = closure_1_13.getChannel(obj.parent_id);
const currentUser = closure_1_20.getCurrentUser();
const hasItem = closure_1_10.has(obj.type);
2026-07-29 08:29:29 +00:00
obj = { isThread: null, guild: null, category: null, hasCategories: null, pinDisabled: null, canManageChannels: null, isChannelOwner: null, canManageParent: null, canManageRoles: null, canSendMessages: null, canManageWebhooks: null, canUnarchiveThread: null, regions: null, submitting: null, errors: null, isNSFWDisabled: null };
obj[0] = hasItem;
obj[1] = guild;
obj[2] = channel;
2026-08-24 06:08:38 +00:00
const regions = closure_1_18.getRegions(obj.getGuildId());
obj[3] = closure_1_14.hasCategories(obj.guild_id);
2026-07-29 08:29:29 +00:00
obj[4] = shouldHideChannelContent;
2026-08-24 06:08:38 +00:00
obj[5] = closure_1_16.can(closure_1_34.MANAGE_CHANNELS, obj);
2026-07-29 08:29:29 +00:00
obj[6] = null != currentUser && obj.ownerId === currentUser.id;
2026-07-20 16:05:17 +00:00
if (null != channel) {
2026-07-29 08:29:29 +00:00
let canResult = obj5.can(tmp21.MANAGE_CHANNELS, channel);
2026-07-20 16:05:17 +00:00
} else {
2026-07-29 08:29:29 +00:00
canResult = obj5.can(tmp21.MANAGE_CHANNELS, guild);
2026-07-20 16:05:17 +00:00
}
2026-07-29 08:29:29 +00:00
obj[7] = canResult;
2026-08-24 06:08:38 +00:00
obj[8] = closure_1_16.can(closure_1_34.MANAGE_ROLES, obj);
obj[9] = closure_1_16.can(closure_1_34.SEND_MESSAGES, obj);
obj[10] = closure_1_8(obj.type) && closure_1_16.can(closure_1_34.MANAGE_WEBHOOKS, obj);
const tmp4 = closure_1_8(obj.type) && closure_1_16.can(closure_1_34.MANAGE_WEBHOOKS, obj);
obj[11] = closure_1_0(navigation[67]).canUnarchiveThread(obj);
2026-07-29 08:29:29 +00:00
obj[12] = regions;
obj[13] = submitting;
obj[14] = errors;
2026-08-24 06:08:38 +00:00
const obj2 = closure_1_0(navigation[67]);
obj[15] = closure_1_11(guild) || null != obj.linkedLobby;
2026-07-20 16:05:17 +00:00
return obj;
}
}, items4);
2026-07-29 08:29:29 +00:00
ref = shouldHideChannelContent.useRef(null);
2026-07-20 16:05:17 +00:00
const items5 = [autoFocusElement, navigation];
2026-07-29 08:29:29 +00:00
const effect = shouldHideChannelContent.useEffect(() => navigation.addListener("transitionEnd", (data) => {
2026-07-20 16:05:17 +00:00
if (!data.data.closing) {
2026-08-24 06:08:38 +00:00
if (closure_1 === closure_1_21.CHANNEL_NAME) {
2026-07-29 08:29:29 +00:00
const current = ref.current;
2026-07-20 16:05:17 +00:00
let focusResult;
2026-07-29 08:29:29 +00:00
if (current != null) {
2026-07-20 16:05:17 +00:00
focusResult = current.focus();
}
return focusResult;
}
}
}), items5);
let tmp11Result = null;
if (null != stateFromStores1) {
obj = {};
const merged = Object.assign(stateFromStoresObject1);
2026-07-29 08:29:29 +00:00
obj.channel = stateFromStores1;
obj.navigation = navigation;
obj.isThreadModerator = isThreadModerator;
2026-07-20 16:05:17 +00:00
let isLockedThreadResult;
2026-07-29 08:29:29 +00:00
if (stateFromStores != null) {
2026-07-20 16:05:17 +00:00
isLockedThreadResult = stateFromStores.isLockedThread();
}
2026-07-29 08:29:29 +00:00
obj.isLockedThread = isLockedThreadResult;
2026-07-20 16:05:17 +00:00
let isArchivedThreadResult;
2026-07-29 08:29:29 +00:00
if (stateFromStores != null) {
2026-07-20 16:05:17 +00:00
isArchivedThreadResult = stateFromStores.isArchivedThread();
}
2026-07-29 08:29:29 +00:00
obj.isArchivedThread = isArchivedThreadResult;
obj.canManageThread = canManageThread;
obj.canUnarchiveThread = stateFromStoresObject1.canUnarchiveThread;
obj.isMutedThread = isMutedThread;
obj.hasJoinedThread = hasJoinedThread;
2026-07-20 16:05:17 +00:00
let isForumPostResult;
2026-07-29 08:29:29 +00:00
if (stateFromStores != null) {
2026-07-20 16:05:17 +00:00
isForumPostResult = stateFromStores.isForumPost();
}
2026-07-29 08:29:29 +00:00
obj.isForumPost = isForumPostResult;
obj.channelNameRef = ref;
tmp11Result = closure_43(ChannelSettingsOverview, obj);
const tmp11 = closure_43;
const tmp12 = ChannelSettingsOverview;
2026-07-20 16:05:17 +00:00
}
return tmp11Result;
};
export { PinImage };