Files
discord-decomp/sources/modules/keyboard/native/PortalKeyboardRendererComponent.tsx
T
2026-07-28 01:06:53 +03:00

60 lines
4.4 KiB
TypeScript

/* Metro module 15144; source: modules/keyboard/native/PortalKeyboardRendererComponent.tsx; dependencies: [31, 1379, 33, 5225, 1583, 11575, 8048, 15145, 15152, 2] */
import ChannelStore from '../../../stores/ChannelStore.tsx'; /* Metro dependency 1379 */
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 */
function _fun115474(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#115474, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15341:6, offset: 0x02461bef, size: 168 bytes, params: 8, frame: 19
const env0_0 = require;
const Object = global.Object;
Object.defineProperty(exports, '__esModule', {value: true});
let value = ReactModule;
value = value.memo(PortalKeyboardRendererComponent);
(FileImportTrackerModule).fileFinishedImporting('modules/keyboard/native/PortalKeyboardRendererComponent.tsx');
exports.default = value;
function PortalKeyboardRendererComponent({item, state, cleanUp}) { // fn#115475, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15341:144, offset: 0x02461c97, size: 445 bytes, params: 2, frame: 21
const channelId = item.channelId;
const chatInputRef = item.chatInputRef;
const type = item.type;
const channel = ChannelStore.getChannel(channelId);
const binding = env0_3;
const value3 = binding.useMemo(_fun115476, [channel, channelId]);
const value4 = binding.useMemo(_fun115477, [value3]);
if (value3 != null) {
if (value4 === undefined) {
return null;
}
var KeyboardTypes = (require(1583) /* metro dependency 1583: KeyboardTypes */).KeyboardTypes;
var APP_LAUNCHER = KeyboardTypes.APP_LAUNCHER;
if (APP_LAUNCHER === type) {
return ((Component) => <Component context={value4} chatInputRef={chatInputRef} onClose={cleanUp} transitionState={state} entrypoint={(require(8048) /* metro dependency 8048: AppLauncherTypes */).AppLauncherEntrypoint.TEXT} />)(importDefault(11575) /* metro dependency 11575: AppLauncherKeyboard */);
}
KeyboardTypes = (require(1583) /* metro dependency 1583: KeyboardTypes */).KeyboardTypes;
var MEDIA = KeyboardTypes.MEDIA;
if (MEDIA === type) {
return ((Component) => <Component channel={value3} chatInputRef={chatInputRef} onClose={cleanUp} transitionState={state} />)(importDefault(15145) /* metro dependency 15145: MediaKeyboard */);
}
KeyboardTypes = (require(1583) /* metro dependency 1583: KeyboardTypes */).KeyboardTypes;
var EXPRESSION = KeyboardTypes.EXPRESSION;
if (EXPRESSION === type) {
return ((Component) => <Component channel={value3} chatInputRef={chatInputRef} onClose={cleanUp} transitionState={state} />)(importDefault(15152) /* metro dependency 15152: ExpressionPickerKeyboard */);
}
}
return null;
function _fun115476() { // fn#115476, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15341:282, offset: 0x02461e54, size: 73 bytes, params: 1, frame: 15
const channelIdBinding = channelId;
const FAKE_PLACEHOLDER_PRIVATE_CHANNEL_ID = (require(5225) /* metro dependency 5225: FakePlaceholderPrivateChannel */).FAKE_PLACEHOLDER_PRIVATE_CHANNEL_ID;
return channelIdBinding !== FAKE_PLACEHOLDER_PRIVATE_CHANNEL_ID ? env0_1 : (require(5225) /* metro dependency 5225: FakePlaceholderPrivateChannel */).FAKE_PLACEHOLDER_PRIVATE_CHANNEL;
}
function _fun115477() { // fn#115477, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15341:398, offset: 0x02461e9d, size: 41 bytes, params: 1, frame: 3
return env0_2 != null ? {channel: env0_2, type: 'channel'} : undefined;
}
}
}
global.__d(_fun115474, 15144, [31, 1379, 33, 5225, 1583, 11575, 8048, 15145, 15152,
2]) /* metro module 15144, dependencies: [31, 1379, 33, 5225, 1583, 11575, 8048, 15145, 15152, 2] */;