/* Metro module 11335; source: modules/chat/native/useChatWidth.tsx; dependencies: [31, 4010, 4012, 11336, 11337, 2] */ import UseChatLayout from './useChatLayout.tsx'; /* Metro dependency 4010 */ import UseBaseAppContainerDimensions from '../../screen/native/useBaseAppContainerDimensions.tsx'; /* Metro dependency 4012 */ import ChatViewWidthContext from './ChatViewWidthContext.tsx'; /* Metro dependency 11337 */ 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 UseChatLayoutModule from './useChatLayout.tsx'; /* Metro dependency 4010 */ import * as UseBaseAppContainerDimensionsModule from '../../screen/native/useBaseAppContainerDimensions.tsx'; /* Metro dependency 4012 */ import * as UseDrawerWidthModule from '../../screen/native/drawer/useDrawerWidth.tsx'; /* Metro dependency 11336 */ function _fun86562(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#86562, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:11521:6, offset: 0x01f97c6d, size: 136 bytes, params: 8, frame: 18 const env0_0 = require; const Object = global.Object; Object.defineProperty(exports, '__esModule', {value: true}); (FileImportTrackerModule).fileFinishedImporting('modules/chat/native/useChatWidth.tsx'); exports.default = useChatWidth; exports.getChatWidth = getChatWidth; function useChatWidth(a0) { // fn#86563, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:11521:186, offset: 0x01f97cf5, size: 149 bytes, params: 2, frame: 16 const value2 = ReactModule.useContext(ChatViewWidthContext); const isChatLockedOpen = (UseChatLayout)().isChatLockedOpen; const width = (UseBaseAppContainerDimensions)().width; let value = UseDrawerWidthModule; value = value.useDrawerWidth(); return value2 ?? (a0 == null ? isChatLockedOpen ? width - value : width : a0 !== 0 ? width : isChatLockedOpen ? width - value : width); } function getChatWidth(a0) { // fn#86564, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:11521:371, offset: 0x01f97d8a, size: 131 bytes, params: 2, frame: 15 var r1; var r0; var value; const getChatLayout = UseChatLayoutModule.getChatLayout; const isChatLockedOpen = Reflect.apply(getChatLayout, UseChatLayoutModule, []).isChatLockedOpen; const getBaseAppContainerDimensions = UseBaseAppContainerDimensionsModule.getBaseAppContainerDimensions; const width = Reflect.apply(getBaseAppContainerDimensions, UseBaseAppContainerDimensionsModule, []).width; if (a0 == null) { if (isChatLockedOpen) { value = require(11336) /* metro dependency 11336: useDrawerWidth */; value = width - value.getDrawerWidth(); r1 = value; } else { r1 = width; } r0 = r1; } else if (a0 !== 0) { r0 = width; } else { if (isChatLockedOpen) { value = require(11336) /* metro dependency 11336: useDrawerWidth */; value = width - value.getDrawerWidth(); r1 = value; } else { r1 = width; } r0 = r1; } return r0; } } global.__d(_fun86562, 11335, [31, 4010, 4012, 11336, 11337, 2]) /* metro module 11335, dependencies: [31, 4010, 4012, 11336, 11337, 2] */;