/* Metro module 13577; source: modules/quests/native/QuestDock/QuestDockContextMenuActionSheet.tsx; dependencies: [5, 31, 661, 33, 7114, 9483, 9505, 6805, 6807, 10638, 7972, 9520, 6531, 7120, 4080, 4060, 1244, 13578, 9519, 9517, 9518, 7121, 7110, 9480, 10139, 13580, 5312, 9484, 13583, 8653, 13584, 13586, 13588, 8999, 7007, 6797, 2] */ import Module00005 from '../../../../by-id/module-00005.js'; /* Metro dependency 5 */ import ActionSheetActionCreators from '../../../action_sheet/native/ActionSheetActionCreators.tsx'; /* Metro dependency 4080 */ import QuestDisclosureModalActionCreators from '../QuestDisclosureModal/QuestDisclosureModalActionCreators.tsx'; /* Metro dependency 13580 */ import * as FileImportTrackerModule from '../../../../by-id/module-00002-FileImportTracker.js'; /* Metro dependency 2 */ import * as ReactModule from '../../../../by-id/module-00031-React.js'; /* Metro dependency 31 */ import * as JsxRuntimeModule from '../../../../by-id/module-00033-JsxRuntime.js'; /* Metro dependency 33 */ import * as ConstantsModule from '../../../../Constants.tsx'; /* Metro dependency 661 */ import * as XSmallIconModule from '../../../../design/components/Icon/native/redesign/generated/XSmallIcon.tsx'; /* Metro dependency 5312 */ import * as QuestTypesModule from '../../QuestTypes.tsx'; /* Metro dependency 6531 */ import * as ClipboardUtilsNativeModule from '../../../../utils/ClipboardUtils.native.tsx'; /* Metro dependency 6797 */ import * as ActionSheetNativeModule from '../../../../design/components/Sheet/native/ActionSheet.native.tsx'; /* Metro dependency 6805 */ import * as OpenUserSettingsModule from '../../../user_settings/core/native/openUserSettings.tsx'; /* Metro dependency 7007 */ import * as QuestUtilsModule from '../../utils/QuestUtils.tsx'; /* Metro dependency 7114 */ import * as AnalyticsTypesModule from '../../lib/analytics/AnalyticsTypes.tsx'; /* Metro dependency 7120 */ import * as AdCreativeTypeModule from '../../../../external/discord_common/js/shared/shared-constants/AdCreativeType.tsx'; /* Metro dependency 7121 */ import * as NativeModule from '../../../../design/void/Form/native/index.tsx'; /* Metro dependency 7972 */ import * as EyeIconModule from '../../../../design/components/Icon/native/redesign/generated/EyeIcon.tsx'; /* Metro dependency 8999 */ import * as QuestUtilsNativeModule from '../QuestUtils.native.tsx'; /* Metro dependency 9480 */ import * as QuestHooksModule from '../../hooks/QuestHooks.tsx'; /* Metro dependency 9483 */ import * as QuestActionCreatorsModule from '../../QuestActionCreators.tsx'; /* Metro dependency 9484 */ import * as QuestCopyUtilsModule from '../../utils/QuestCopyUtils.tsx'; /* Metro dependency 9505 */ import * as AdAnalyticsInterfaceExperimentModule from '../../experiments/AdAnalyticsInterfaceExperiment.tsx'; /* Metro dependency 9519 */ import * as QuestPlatformUtilsModule from '../../utils/QuestPlatformUtils.tsx'; /* Metro dependency 9520 */ import * as CircleQuestionIconModule from '../../../../design/components/Icon/native/redesign/generated/CircleQuestionIcon.tsx'; /* Metro dependency 10139 */ import * as LinkExternalMediumIconModule from '../../../../design/components/Icon/native/redesign/generated/LinkExternalMediumIcon.tsx'; /* Metro dependency 10638 */ function _fun103202(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#103202, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:13767:6, offset: 0x0225bf63, size: 185 bytes, params: 8, frame: 19 const env0_0 = require; const Object = global.Object; Object.defineProperty(exports, '__esModule', {value: true}); ReactModule; (FileImportTrackerModule).fileFinishedImporting('modules/quests/native/QuestDock/QuestDockContextMenuActionSheet.tsx'); exports.default = QuestDockContextMenuActionSheet; function QuestDockContextMenuActionSheet({quest}) { // fn#103203, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:13767:180, offset: 0x0225c01c, size: 2479 bytes, params: 2, frame: 35 var r8; var r5; const intl = (require(1244) /* metro dependency 1244: indexNative */).intl; const t = (require(1244) /* metro dependency 1244: indexNative */).t; var object; var object3; var items4; var object10; var object13; var object16; var object17; const EyeIcon = (EyeIconModule).EyeIcon; var object18; var object19; var value; const isShareableQuest2 = QuestUtilsModule.isShareableQuest(quest.config); const value2 = (QuestHooksModule).useQuestPreviewActions(quest.id); const env0_1 = value2.handleComplete; const env0_2 = value2.handleProgress; const handleResetDismissibilityClick = value2.handleResetDismissibilityClick; const env0_4 = value2.handleResetStatusClick; const externalCtaLabel = (QuestCopyUtilsModule).getExternalCtaLabel(quest); const ActionSheet = (ActionSheetNativeModule).ActionSheet; const ActionSheetRow = (require(6807) /* metro dependency 6807: ActionSheetRowNative */).ActionSheetRow; let Group = ActionSheetRow.Group; const object20 = {}; const ActionSheetRow2 = (require(6807) /* metro dependency 6807: ActionSheetRowNative */).ActionSheetRow; let Icon = ActionSheetRow2.Icon; const LinkExternalMediumIcon = (LinkExternalMediumIconModule).LinkExternalMediumIcon; object20.icon = ; const FormLabel = (NativeModule).FormLabel; object20.label = ; object20.onPress = onPress_103204; const actionSheetRow = ; if (isShareableQuest2) { r8 = ( )((require(6807) /* metro dependency 6807: ActionSheetRowNative */).ActionSheetRow.Icon)} label={} onPress={onPress_103205} /> ); } else { r8 = isShareableQuest2; } const items2 = [ {actionSheetRow} {r8} , ]; Group = ActionSheetRow.Group; const object21 = {}; const ActionSheetRow4 = (require(6807) /* metro dependency 6807: ActionSheetRowNative */).ActionSheetRow; Icon = ActionSheetRow4.Icon; object21.icon = ; let string = intl.string; const LLLLPD = (require(1244) /* metro dependency 1244: indexNative */).t.LLLLPD; object21.label = ; object21.onPress = onPress_103206; const items3 = [ , ]; const object22 = {}; const ActionSheetRow5 = (require(6807) /* metro dependency 6807: ActionSheetRowNative */).ActionSheetRow; Icon = ActionSheetRow5.Icon; const CircleQuestionIcon = (CircleQuestionIconModule).CircleQuestionIcon; object22.icon = ; string = intl.string; const GcsZKJ = (require(1244) /* metro dependency 1244: indexNative */).t.GcsZKJ; object22.label = ; object22.onPress = onPress_103207; items3[1] = ; const object23 = {}; const ActionSheetRow6 = (require(6807) /* metro dependency 6807: ActionSheetRowNative */).ActionSheetRow; Icon = ActionSheetRow6.Icon; const XSmallIcon = (XSmallIconModule).XSmallIcon; object23.icon = ; string = intl.string; const NN79E9 = (require(1244) /* metro dependency 1244: indexNative */).t.NN79E9; object23.label = ; string = intl.string; const V6htN5 = (require(1244) /* metro dependency 1244: indexNative */).t.V6htN5; object23.subLabel = Reflect.apply(string, intl, [V6htN5]); object23.onPress = handleResetDismissibilityClick(_fun103209); items3[2] = ; items2[1] = ( {items3} ); const preview = quest.preview; if (preview) { Group = ActionSheetRow.Group; var groupProps = {title: intl.string(t['Ape+mm']), hasIcons: true}; object3 = {}; Icon = (require(6807) /* metro dependency 6807: ActionSheetRowNative */).ActionSheetRow.Icon; object3.icon = ; string = intl.string; object3.label = ; object3.onPress = onPress_103210; value = ; items4 = [value]; object10 = {}; Icon = (require(6807) /* metro dependency 6807: ActionSheetRowNative */).ActionSheetRow.Icon; object10.icon = ; string = intl.string; object10.label = ; object10.onPress = onPress_103211; items4[1] = ; object13 = {}; Icon = (require(6807) /* metro dependency 6807: ActionSheetRowNative */).ActionSheetRow.Icon; object13.icon = ; string = intl.string; object13.label = ; object13.onPress = onPress_103212; items4[2] = ; object16 = {}; Icon = (require(6807) /* metro dependency 6807: ActionSheetRowNative */).ActionSheetRow.Icon; object16.icon = ; string = intl.string; object16.label = ; object16.onPress = onPress_103213; items4[3] = ; object17 = {}; Icon = (require(6807) /* metro dependency 6807: ActionSheetRowNative */).ActionSheetRow.Icon; object17.icon = ; string = intl.string; object17.label = ; object17.onPress = onPress_103214; items4[4] = ; object18 = {}; Icon = (require(6807) /* metro dependency 6807: ActionSheetRowNative */).ActionSheetRow.Icon; object18.icon = ; string = intl.string; object18.label = ; object18.onPress = onPress_103215; items4[5] = ; object19 = {}; Icon = (require(6807) /* metro dependency 6807: ActionSheetRowNative */).ActionSheetRow.Icon; object19.icon = ; string = intl.string; object19.label = ; object19.onPress = onPress_103216; items4[6] = ; value = ( {items4} ); r5 = value; } else { r5 = preview; } items2[2] = r5; return ( {items2} ); function QuestDockContextMenuActionSheetOnPress() { // fn#103204, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:13767:693, owner: QuestDockContextMenuActionSheet.onPress, offset: 0x0225c9cb, size: 157 bytes, params: 1, frame: 19 const value = environment.__proto__; const openGameLinkDirectly = QuestPlatformUtilsModule.openGameLinkDirectly; const questBinding = quest; const object = {}; const QuestContent = (QuestTypesModule).QuestContent; let QUEST_BAR_MOBILE = QuestContent.QUEST_BAR_MOBILE; object.content = QUEST_BAR_MOBILE; const QuestContentCTA = (AnalyticsTypesModule).QuestContentCTA; const CONTEXT_MENU_OPEN_GAME_LINK = QuestContentCTA.CONTEXT_MENU_OPEN_GAME_LINK; object.ctaContent = CONTEXT_MENU_OPEN_GAME_LINK; QUEST_BAR_MOBILE = QuestContent.QUEST_BAR_MOBILE; object.sourceQuestContent = QUEST_BAR_MOBILE; Reflect.apply(openGameLinkDirectly, QuestPlatformUtilsModule, [questBinding, object]); (ActionSheetActionCreators).hideActionSheet(); } function QuestDockContextMenuActionSheetOnPress_103205() { // fn#103205, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:13767:1114, owner: QuestDockContextMenuActionSheet.onPress, offset: 0x0225ca68, size: 162 bytes, params: 1, frame: 19 const value = environment.__proto__; const copyShareLink = QuestCopyUtilsModule.copyShareLink; const id = quest.id; const object = {}; const QuestContent = (QuestTypesModule).QuestContent; let QUEST_BAR_MOBILE = QuestContent.QUEST_BAR_MOBILE; object.content = QUEST_BAR_MOBILE; const QuestContentCTA = (AnalyticsTypesModule).QuestContentCTA; const CONTEXT_MENU_COPY_LINK = QuestContentCTA.CONTEXT_MENU_COPY_LINK; object.ctaContent = CONTEXT_MENU_COPY_LINK; QUEST_BAR_MOBILE = QuestContent.QUEST_BAR_MOBILE; object.sourceQuestContent = QUEST_BAR_MOBILE; Reflect.apply(copyShareLink, QuestCopyUtilsModule, [id, object]); (ActionSheetActionCreators).hideActionSheet(); } function QuestDockContextMenuActionSheetOnPress_103206() { // fn#103206, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:13767:1570, owner: QuestDockContextMenuActionSheet.onPress, offset: 0x0225cb0a, size: 499 bytes, params: 1, frame: 18 var moduleValue2; var trackQuestContentClicked; var object; const QuestContent = (QuestTypesModule).QuestContent; var QUEST_BAR_MOBILE; const QuestContentCTA = (AnalyticsTypesModule).QuestContentCTA; var moduleValue3; var captureAdUserAction; const value = environment.__proto__; const shouldMigrateToAdAnalyticsInterface = AdAnalyticsInterfaceExperimentModule.shouldMigrateToAdAnalyticsInterface; const AdAnalyticsInterfaceExperimentStep = AdAnalyticsInterfaceExperimentModule.AdAnalyticsInterfaceExperimentStep; const STEP_2_CLICKED_INTERNAL = AdAnalyticsInterfaceExperimentStep.STEP_2_CLICKED_INTERNAL; if (Reflect.apply(shouldMigrateToAdAnalyticsInterface, AdAnalyticsInterfaceExperimentModule, [STEP_2_CLICKED_INTERNAL, 'quest_dock_context_menu'])) { moduleValue3 = require(9517) /* metro dependency 9517: captureAdUserAction */; captureAdUserAction = moduleValue3.captureAdUserAction; object = {}; object.type = (require(9518) /* metro dependency 9518: captureAdUserActionTypes */).AdUserActionType.CLICK_INTERNAL; object.adCreativeType = (require(7121) /* metro dependency 7121: AdCreativeType */).AdCreativeType.QUEST; object.adCreativeId = quest.id; object.questContentCTA = QuestContentCTA.CONTEXT_MENU_LEARN_MORE; QUEST_BAR_MOBILE = QuestContent.QUEST_BAR_MOBILE; object.surfaceId = QUEST_BAR_MOBILE; QUEST_BAR_MOBILE = QuestContent.QUEST_BAR_MOBILE; object.sourceQuestContent = QUEST_BAR_MOBILE; Reflect.apply(captureAdUserAction, moduleValue3, [object]); } else { moduleValue2 = require(7110) /* metro dependency 7110: AnalyticsActions */; trackQuestContentClicked = moduleValue2.trackQuestContentClicked; object = {}; object.questId = quest.id; QUEST_BAR_MOBILE = QuestContent.QUEST_BAR_MOBILE; object.questContent = QUEST_BAR_MOBILE; object.questContentCTA = QuestContentCTA.CONTEXT_MENU_LEARN_MORE; QUEST_BAR_MOBILE = QuestContent.QUEST_BAR_MOBILE; object.sourceQuestContent = QUEST_BAR_MOBILE; Reflect.apply(trackQuestContentClicked, moduleValue2, [object]); } const openQuestHome = QuestUtilsNativeModule.openQuestHome; QUEST_BAR_MOBILE = QuestContent.QUEST_BAR_MOBILE; Reflect.apply(openQuestHome, QuestUtilsNativeModule, [{scrollToQuestId: quest.id, fromContent: QUEST_BAR_MOBILE}]); (ActionSheetActionCreators).hideActionSheet(); } function QuestDockContextMenuActionSheetOnPress_103207() { // fn#103207, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:13767:2570, owner: QuestDockContextMenuActionSheet.onPress, offset: 0x0225ccfd, size: 175 bytes, params: 1, frame: 18 const value = environment.__proto__; const defaultImport = QuestDisclosureModalActionCreators; const showModal = defaultImport.showModal; const object = {}; object.quest = quest; object.isTargetedDisclosure = true; const object2 = {}; const QuestContent = (QuestTypesModule).QuestContent; let QUEST_BAR_MOBILE = QuestContent.QUEST_BAR_MOBILE; object2.content = QUEST_BAR_MOBILE; const QuestContentCTA = (AnalyticsTypesModule).QuestContentCTA; const CONTEXT_MENU_OPEN_DISCLOSURE = QuestContentCTA.CONTEXT_MENU_OPEN_DISCLOSURE; object2.ctaContent = CONTEXT_MENU_OPEN_DISCLOSURE; QUEST_BAR_MOBILE = QuestContent.QUEST_BAR_MOBILE; object2.sourceQuestContent = QUEST_BAR_MOBILE; object.trackingCtx = object2; Reflect.apply(showModal, defaultImport, [object]); (ActionSheetActionCreators).hideActionSheet(); } function* _fun103209() { // fn#103209, original name: ?anon_0_, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:13767:3076, offset: 0x0225cdb7, size: 525 bytes, params: 1, frame: 21 var value8; var trackQuestContentClicked; var object; var value9; var captureAdUserAction; if (true) { value = environment.__proto__.__proto__; var binding = env2_0; var binding2 = env2_2; var value3 = binding(binding2[27]); var dismissQuestContent = value3.dismissQuestContent; var id = require.id; var QuestContent = binding(binding2[12]).QuestContent; var QUEST_BAR_MOBILE = QuestContent.QUEST_BAR_MOBILE; var value5 = Reflect.apply(dismissQuestContent, value3, [id, QUEST_BAR_MOBILE]); env2_1(binding2[14]).hideActionSheet(); var value7 = binding(binding2[18]); var shouldMigrateToAdAnalyticsInterface = value7.shouldMigrateToAdAnalyticsInterface; var AdAnalyticsInterfaceExperimentStep = binding(binding2[18]).AdAnalyticsInterfaceExperimentStep; var STEP_2_CLICKED_INTERNAL = AdAnalyticsInterfaceExperimentStep.STEP_2_CLICKED_INTERNAL; var shouldMigrateToAdAnalyticsInterface2 = Reflect.apply(shouldMigrateToAdAnalyticsInterface, value7, [STEP_2_CLICKED_INTERNAL, 'quest_dock_context_menu']); binding = env2_0; var binding4 = env2_2; if (shouldMigrateToAdAnalyticsInterface2) { value9 = binding(binding4[19]); captureAdUserAction = value9.captureAdUserAction; object = {}; object.type = binding(binding4[20]).AdUserActionType.CLICK_INTERNAL; object.adCreativeType = binding(binding4[21]).AdCreativeType.QUEST; object.adCreativeId = require.id; object.questContentCTA = binding(binding4[13]).QuestContentCTA.CONTEXT_MENU_HIDE_CONTENT; QuestContent = binding(binding4[12]).QuestContent; QUEST_BAR_MOBILE = QuestContent.QUEST_BAR_MOBILE; object.surfaceId = QUEST_BAR_MOBILE; QuestContent = binding(binding4[12]).QuestContent; QUEST_BAR_MOBILE = QuestContent.QUEST_BAR_MOBILE; object.sourceQuestContent = QUEST_BAR_MOBILE; Reflect.apply(captureAdUserAction, value9, [object]); } else { value8 = binding(binding4[22]); trackQuestContentClicked = value8.trackQuestContentClicked; object = {}; object.questId = require.id; QuestContent = binding(binding4[12]).QuestContent; QUEST_BAR_MOBILE = QuestContent.QUEST_BAR_MOBILE; object.questContent = QUEST_BAR_MOBILE; object.questContentCTA = binding(binding4[13]).QuestContentCTA.CONTEXT_MENU_HIDE_CONTENT; QuestContent = binding(binding4[12]).QuestContent; QUEST_BAR_MOBILE = QuestContent.QUEST_BAR_MOBILE; object.sourceQuestContent = QUEST_BAR_MOBILE; Reflect.apply(trackQuestContentClicked, value8, [object]); } yield value5; if (false) { return undefined; } env2_0(env2_2[28]).displayQuestDismissalToast(); } } function QuestDockContextMenuActionSheetOnPress_103210() { // fn#103210, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:13767:4226, owner: QuestDockContextMenuActionSheet.onPress, offset: 0x0225cfc4, size: 48 bytes, params: 1, frame: 12 handleComplete(); const value = environment.__proto__; (ActionSheetActionCreators).hideActionSheet(); } function QuestDockContextMenuActionSheetOnPress_103211() { // fn#103211, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:13767:4444, owner: QuestDockContextMenuActionSheet.onPress, offset: 0x0225cff4, size: 95 bytes, params: 1, frame: 12 const handleProgressBinding = handleProgress; const Math = global.Math; handleProgressBinding(0.9 * Math.random() + 0.03); const value = environment.__proto__; (ActionSheetActionCreators).hideActionSheet(); } function QuestDockContextMenuActionSheetOnPress_103212() { // fn#103212, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:13767:4682, owner: QuestDockContextMenuActionSheet.onPress, offset: 0x0225d053, size: 48 bytes, params: 1, frame: 12 handleResetStatusClick(); const value = environment.__proto__; (ActionSheetActionCreators).hideActionSheet(); } function QuestDockContextMenuActionSheetOnPress_103213() { // fn#103213, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:13767:4902, owner: QuestDockContextMenuActionSheet.onPress, offset: 0x0225d083, size: 48 bytes, params: 1, frame: 12 handleResetDismissibilityClick(); const value = environment.__proto__; (ActionSheetActionCreators).hideActionSheet(); } function QuestDockContextMenuActionSheetOnPress_103214() { // fn#103214, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:13767:5122, owner: QuestDockContextMenuActionSheet.onPress, offset: 0x0225d0b3, size: 109 bytes, params: 1, frame: 17 const value = environment.__proto__; const markAdContentUnseen = QuestActionCreatorsModule.markAdContentUnseen; const AdCreativeType = (AdCreativeTypeModule).AdCreativeType; const QUEST = AdCreativeType.QUEST; Reflect.apply(markAdContentUnseen, QuestActionCreatorsModule, [QUEST, [quest.id]]); (ActionSheetActionCreators).hideActionSheet(); } function QuestDockContextMenuActionSheetOnPress_103215() { // fn#103215, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:13767:5402, owner: QuestDockContextMenuActionSheet.onPress, offset: 0x0225d120, size: 105 bytes, params: 1, frame: 16 const value = environment.__proto__; const openUserSettings = OpenUserSettingsModule.openUserSettings; const QUEST_PREVIEW_TOOL_2 = UserSettingsSections.QUEST_PREVIEW_TOOL_2; Reflect.apply(openUserSettings, OpenUserSettingsModule, [{screen: QUEST_PREVIEW_TOOL_2, params: {questId: quest.id}}]); (ActionSheetActionCreators).hideActionSheet(); } function QuestDockContextMenuActionSheetOnPress_103216() { // fn#103216, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:13767:5697, owner: QuestDockContextMenuActionSheet.onPress, offset: 0x0225d189, size: 76 bytes, params: 1, frame: 14 const value = environment.__proto__; ClipboardUtilsNativeModule.copy(quest.id); (ActionSheetActionCreators).hideActionSheet(); } } } global.__d(_fun103202, 13577, [5, 31, 661, 33, 7114, 9483, 9505, 6805, 6807, 10638, 7972, 9520, 6531, 7120, 4080, 4060, 1244, 13578, 9519, 9517, 9518, 7121, 7110, 9480, 10139, 13580, 5312, 9484, 13583, 8653, 13584, 13586, 13588, 8999, 7007, 6797, 2]) /* metro module 13577, dependencies: [5, 31, 661, 33, 7114, 9483, 9505, 6805, 6807, 10638, 7972, 9520, 6531, 7120, 4080, 4060, 1244, 13578, 9519, 9517, 9518, 7121, 7110, 9480, 10139, 13580, 5312, 9484, 13583, 8653, 13584, 13586, 13588, 8999, 7007, 6797, 2] */;