/* Metro module 15146; source: modules/app_launcher/native/AppLauncherActionSheet.tsx; dependencies: [57, 31, 1483, 33, 4017, 8774, 8048, 8775, 6275, 11622, 11732, 6513, 2] */
function _fun115506(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#115506, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15343:6, offset: 0x02463094, size: 191 bytes, params: 8, frame: 19
const env0_0 = require;
const Object = global.Object;
Object.defineProperty(exports, '__esModule', {value: true});
const env0_3 = importDefault(57) /* metro dependency 57 */;
const env0_4 = importAll(31) /* metro dependency 31 */;
const env0_5 = (require(1483) /* metro dependency 1483: AppLauncherNativeConstants */).AppLauncherRouteName;
const env0_6 = (require(33) /* metro dependency 33 */).jsx;
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/app_launcher/native/AppLauncherActionSheet.tsx');
exports.useAppLauncherActionSheet = useAppLauncherActionSheet;
}
function AppLauncherActionSheet({chatInputRef, channel}) { // fn#115507, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15343:161, offset: 0x02463153, size: 476 bytes, params: 2, frame: 29
let binding = env0_4;
let useRef = binding.useRef;
const value2 = Reflect.apply(useRef, binding, [null]);
const value4 = (require(4017) /* metro dependency 4017: ReanimatedRexport */).useSharedValue(-1);
const value5 = (require(4017) /* metro dependency 4017: ReanimatedRexport */).useSharedValue(0);
const value6 = env0_4.useRef(undefined);
binding = env0_4;
useRef = binding.useRef;
const AppLauncherKeyboardCloseReason = (require(8774) /* metro dependency 8774: AppLauncherContext */).AppLauncherKeyboardCloseReason;
const DISMISSED = AppLauncherKeyboardCloseReason.DISMISSED;
const value7 = Reflect.apply(useRef, binding, [DISMISSED]);
const AppLauncherEntrypoint = (require(8048) /* metro dependency 8048: AppLauncherTypes */).AppLauncherEntrypoint;
const TEXT = AppLauncherEntrypoint.TEXT;
const value8 = (require(8775) /* metro dependency 8775: useDefaultAppLauncherWidth */).useDefaultAppLauncherWidth(TEXT);
const value9 = env0_4.useMemo(function() {
return {channel: channel, type: 'channel'};
}, [channel]);
const value10 = env0_4.useRef({getApplicationCommandManager: getApplicationCommandManager,
closeCustomKeyboard: closeCustomKeyboard_115510, openCustomKeyboard: openCustomKeyboard_115511});
const BottomSheet = (require(6275) /* metro dependency 6275: BottomSheetNative */).BottomSheet;
const AppLauncherNavigator = importDefault(11622) /* metro dependency 11622: AppLauncherNavigator */;
const object = {};
const HOME = AppLauncherRouteName.HOME;
object.initialRouteName = HOME;
let value = require(11732) /* metro dependency 11732: getAppDMApplication */;
value = value.getAppDMApplication(channel);
object.initialSearchQuery = value?.name;
return (
);
}
function useAppLauncherActionSheet(a0) { // fn#115512, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15343:1261, offset: 0x02463389, size: 114 bytes, params: 2, frame: 17
const env0_0 = a0;
let binding = env0_4;
const [property, property2] = env0_3(binding.useState(false), 2);
binding = env0_4;
const useMemo = binding.useMemo;
return {appLauncherActionSheet: Reflect.apply(useMemo, binding, [_fun115513, [property, a0]]),
setAppLauncherActionSheetEnabled: property2};
}
function AppLauncherActionSheetGetApplicationCommandManager() { // fn#115509, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15343:551, owner: AppLauncherActionSheet.getApplicationCommandManager, offset: 0x02463346, size: 35 bytes, params: 1, frame: 10
return chatInputRef.current?.getApplicationCommandManager();
}
function AppLauncherActionSheetOpenCustomKeyboard() { // fn#115511, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15343:723, owner: AppLauncherActionSheet.openCustomKeyboard, offset: 0x02463369, size: 32 bytes, params: 1, frame: 9
const current = env0_2.current;
if (current != null) {
current.expandActionSheet();
}
}
function _fun115513() { // fn#115513, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15343:1384, offset: 0x024633fb, size: 144 bytes, params: 1, frame: 19
if (env0_1) {
const Provider = (importDefault(6513) /* metro dependency 6513: ActionSheetContext */).Provider;
return (
);
} else {
return null;
}
}