// Module ID: 9998 // Function ID: 9999 // Name: NotificationSettingsMessageUnreadGuildActionSheet // Dependencies: [19, 4589, 676, 4590, 685, 21, 9987, 9999, 1236, 5368, 9982, 5363, 2] // Exports: default // Module 9998 (NotificationSettingsMessageUnreadGuildActionSheet) import noopAll from "noop" /* 19 */; import NotificationSettingsMessageUnreadActionSheetDefault from "NotificationSettingsMessageUnreadActionSheet" /* 9999 */; import closure_3 from "updateUserGuildSettingsInternal" /* 4589 */; import { UserNotificationSettings } from "ME" /* 676 */; import { UnreadSetting } from "ReadStateTypes" /* 4590 */; import { GuildNotificationSettingsFlags as closure_6 } from "MAX_FAVORITES" /* 685 */; import { jsx } from "jsxProd" /* 21 */; const require = arg1; noopAll; let result = require("set").fileFinishedImporting("modules/notifications/settings/native/NotificationSettingsMessageUnreadGuildActionSheet.tsx"); export default function NotificationSettingsMessageUnreadGuildActionSheet(guildId) { const _require = guildId; let obj = _require(9987); const guildPresetSettings = obj.useGuildPresetSettings(guildId.guildId); ({ unread, notification } = guildPresetSettings); let stringResult; if (notification === UserNotificationSettings.ALL_MESSAGES) { const intl = tmp(1236).intl; stringResult = intl.string(tmp(1236).t.eP8yWU); } obj = { disabledMentionOnlyWithReason: stringResult, value: unread, onChange(ONLY_MENTIONS) { const guildFlags = closure_1_3.getGuildFlags(guildId.guildId); let obj = closure_1_1(closure_1_2[9]); if (ONLY_MENTIONS === closure_1_5.ALL_MESSAGES) { let UNREADS_ONLY_MENTIONS = closure_1_6.UNREADS_ALL_MESSAGES; } else { UNREADS_ONLY_MENTIONS = closure_1_6.UNREADS_ONLY_MENTIONS; } obj = { flags: guildId(closure_1_2[10]).withGuildUnreadFlags(guildFlags, UNREADS_ONLY_MENTIONS) }; const NotificationLabel = guildId(closure_1_2[11]).NotificationLabel; const result = obj.updateGuildNotificationSettings(guildId.guildId, obj, NotificationLabel.unreads(ONLY_MENTIONS)); } }; return jsx(NotificationSettingsMessageUnreadActionSheetDefault, { disabledMentionOnlyWithReason: stringResult, value: unread, onChange(ONLY_MENTIONS) { const guildFlags = closure_1_3.getGuildFlags(guildId.guildId); let obj = closure_1_1(closure_1_2[9]); if (ONLY_MENTIONS === closure_1_5.ALL_MESSAGES) { let UNREADS_ONLY_MENTIONS = closure_1_6.UNREADS_ALL_MESSAGES; } else { UNREADS_ONLY_MENTIONS = closure_1_6.UNREADS_ONLY_MENTIONS; } obj = { flags: guildId(closure_1_2[10]).withGuildUnreadFlags(guildFlags, UNREADS_ONLY_MENTIONS) }; const NotificationLabel = guildId(closure_1_2[11]).NotificationLabel; const result = obj.updateGuildNotificationSettings(guildId.guildId, obj, NotificationLabel.unreads(ONLY_MENTIONS)); } }); };