Initial commit

This commit is contained in:
janisslsm committed 2026-07-27 16:20:00 +03:00
commit af3b49f756
16065 files changed
+2938410

No files matched your search

@@ -0,0 +1,51 @@
/* Metro module 15432; source: modules/voice_panel/native/utils/PanelSizeUtils.tsx; dependencies: [11795, 2] */
function _fun118054(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#118054, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15629:6, offset: 0x024ca76e, size: 162 bytes, params: 8, frame: 18
const Object = global.Object;
Object.defineProperty(exports, '__esModule', {value: true});
const env0_0 = (require(11795) /* metro dependency 11795: VoicePanelConstants */).VOICE_PANEL_DRAWER_MAX_WIDTH;
object = {code: 'function getMaxPanelWidth_PanelSizeUtilsTsx1({windowWidth:windowWidth,connected:connected,safeAreaLeft:safeAreaLeft,safeAreaRight:safeAreaRight}){const{VOICE_PANEL_DRAWER_MAX_WIDTH}=this.__closure;return Math.min(windowWidth,connected?windowWidth:Math.min(VOICE_PANEL_DRAWER_MAX_WIDTH,windowWidth-safeAreaLeft-safeAreaRight));}'};
const value = _fun118055();
object = {code: 'function getPanelX_PanelSizeUtilsTsx2(windowWidth,width){return(windowWidth-width)/2;}'};
const value2 = _fun118057();
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/voice_panel/native/utils/PanelSizeUtils.tsx');
exports.getMaxPanelWidth = value;
exports.getPanelX = value2;
}
function _fun118055() { // fn#118055, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15629:476, offset: 0x024ca810, size: 57 bytes, params: 1, frame: 4
const closure = getMaxPanelWidth;
closure.__closure = {VOICE_PANEL_DRAWER_MAX_WIDTH: VOICE_PANEL_DRAWER_MAX_WIDTH};
closure.__workletHash = 6813992446153;
closure.__initData = env0_1;
return closure;
}
function _fun118057() { // fn#118057, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15629:881, offset: 0x024ca89f, size: 48 bytes, params: 1, frame: 2
const closure = function(a0, a1) {
return (a0 - a1) / 2;
};
closure.__closure = {};
closure.__workletHash = 6050807520832;
closure.__initData = env0_2;
return closure;
}
function getMaxPanelWidth({windowWidth, connected, safeAreaLeft, safeAreaRight}) { // fn#118056, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15629:508, offset: 0x024ca849, size: 86 bytes, params: 2, frame: 18
var r0;
var Math2;
var min2;
var value;
const Math = global.Math;
const min = Math.min;
if (connected) {
r0 = windowWidth;
} else {
Math2 = global.Math;
min2 = Math2.min;
value = environment.__proto__;
value = Reflect.apply(min2, Math2, [VOICE_PANEL_DRAWER_MAX_WIDTH, windowWidth - safeAreaLeft - safeAreaRight]);
r0 = value;
}
return Reflect.apply(min, Math, [windowWidth, r0]);
}
@@ -0,0 +1,42 @@
/* Metro module 11801; source: modules/voice_panel/native/utils/VoicePanelControlsUtils.tsx; dependencies: [11795, 11798, 11793, 2] */
function _fun90390(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#90390, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:11987:6, offset: 0x0203775b, size: 206 bytes, params: 8, frame: 18
const Object = global.Object;
Object.defineProperty(exports, '__esModule', {value: true});
const env0_0 = (require(11795) /* metro dependency 11795: VoicePanelConstants */).VOICE_PANEL_DRAWER_MAX_WIDTH;
const env0_1 = (require(11798) /* metro dependency 11798: VoicePanelCardConstants */).EDGE_GUTTER;
const env0_2 = (require(11793) /* metro dependency 11793: VoicePanelControlsConstants */).CONTROLS_MAX_WIDTH;
object = {code: 'function getControlsDefaultWidth_VoicePanelControlsUtilsTsx1(windowWidth,safeAreaLeft,safeAreaRight){const{EDGE_GUTTER,CONTROLS_MAX_WIDTH}=this.__closure;safeAreaLeft=Math.max(safeAreaLeft,EDGE_GUTTER);safeAreaRight=Math.max(safeAreaRight,EDGE_GUTTER);return Math.min(windowWidth-safeAreaLeft-safeAreaRight,CONTROLS_MAX_WIDTH);}'};
const value = _fun90391();
object = {code: 'function getControlsDrawerOpenWidth_VoicePanelControlsUtilsTsx2(windowWidth,safeAreaLeft,safeAreaRight){const{VOICE_PANEL_DRAWER_MAX_WIDTH}=this.__closure;return Math.min(windowWidth-safeAreaLeft-safeAreaRight,VOICE_PANEL_DRAWER_MAX_WIDTH);}'};
const value2 = _fun90393();
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/voice_panel/native/utils/VoicePanelControlsUtils.tsx');
exports.getControlsDefaultWidth = value;
exports.getControlsDrawerOpenWidth = value2;
}
function _fun90391() { // fn#90391, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:11987:528, offset: 0x02037829, size: 66 bytes, params: 1, frame: 4
const closure = function(a0, a1, a2) {
var Math = global.Math;
var value2 = Math.max(a1, EDGE_GUTTER);
Math = global.Math;
var value3 = Math.max(a2, EDGE_GUTTER);
Math = global.Math;
return Math.min(a0 - value2 - value3, CONTROLS_MAX_WIDTH);
};
closure.__closure = {EDGE_GUTTER: EDGE_GUTTER, CONTROLS_MAX_WIDTH: CONTROLS_MAX_WIDTH};
closure.__workletHash = 5986385407902;
closure.__initData = env0_3;
return closure;
}
function _fun90393() { // fn#90393, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:11987:1090, offset: 0x020378be, size: 57 bytes, params: 1, frame: 4
const closure = function(a0, a1, a2) {
var Math = global.Math;
return Math.min(a0 - a1 - a2, VOICE_PANEL_DRAWER_MAX_WIDTH);
};
closure.__closure = {VOICE_PANEL_DRAWER_MAX_WIDTH: VOICE_PANEL_DRAWER_MAX_WIDTH};
closure.__workletHash = 10795739180192;
closure.__initData = env0_4;
return closure;
}
@@ -0,0 +1,112 @@
/* Metro module 9245; source: modules/voice_panel/native/utils/VoiceStateIconUtils.tsx; dependencies: [4259, 4297, 628, 566, 2] */
function _fun72280(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#72280, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:9430:6, offset: 0x01d416e5, size: 338 bytes, params: 8, frame: 24
var object3;
let env0_0 = require;
const closure = function(a0, a1) {
var env0_0 = a0;
var env0_1 = a1;
return require(dependencyMap[3]).useStateFromStores([MediaEngineStore, VoiceStateStore], _fun72283, [a0, a1],
isStableVoiceStateEqual);
};
const closure2 = function(a0, a1) {
var env0_0 = a0;
var env0_1 = a1;
return require(dependencyMap[3]).useStateFromStoresObject([MediaEngineStore, VoiceStateStore], _fun72285, [a1,
a0]);
};
const Object = global.Object;
Object.defineProperty(exports, '__esModule', {value: true});
const mediaEngineStore = importDefault(4259) /* metro dependency 4259: MediaEngineStore */;
const voiceStateStore = importDefault(4297) /* metro dependency 4297: VoiceStateStore */;
object3 = {DEAFENED_SERVER: 0};
object3[0] = 'DEAFENED_SERVER';
object3.DEAFENED = 1;
object3[1] = 'DEAFENED';
object3.MUTED_SERVER = 2;
object3[2] = 'MUTED_SERVER';
object3.MUTED_LOCAL = 3;
object3[3] = 'MUTED_LOCAL';
object3.MUTED = 4;
object3[4] = 'MUTED';
const object4 = {VIDEO_DISABLED_LOCAL_AUTO: 0};
object4[0] = 'VIDEO_DISABLED_LOCAL_AUTO';
object4.VIDEO_DISABLED_LOCAL = 1;
object4[1] = 'VIDEO_DISABLED_LOCAL';
object4.VIDEO_ACTIVE = 2;
object4[2] = 'VIDEO_ACTIVE';
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/voice_panel/native/utils/VoiceStateIconUtils.tsx');
exports.MuteDeafenIconState = object3;
exports.VideoIconState = object4;
exports.useStableVoiceParticipant = closure;
exports.useMuteDeafenIconState = useMuteDeafenIconState;
exports.useStableVideoState = closure2;
exports.useVideoIconState = useVideoIconState;
}
function isStableVoiceStateEqual(a0, a1) { // fn#72281, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:9430:476, offset: 0x01d41837, size: 65 bytes, params: 3, frame: 16
var r1;
var r0;
const value = a0 === a1;
if (value) {
r0 = value;
} else {
r1 = a0 != null && a1 != null;
r1 = r1 && (importDefault(628) /* metro dependency 628: shallowEqual */)(a0, a1);
r0 = r1;
}
return r0;
}
function useStableVoiceParticipant(a0, a1) { // fn#72282, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:9430:559, offset: 0x01d41878, size: 104 bytes, params: 3, frame: 19
const env0_0 = a0;
const env0_1 = a1;
return (require(566) /* metro dependency 566: flux */).useStateFromStores([MediaEngineStore, VoiceStateStore],
_fun72283, [a0, a1], isStableVoiceStateEqual);
}
function useStableVideoState(a0, a1) { // fn#72284, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:9430:837, offset: 0x01d41959, size: 95 bytes, params: 3, frame: 18
const env0_0 = a0;
const env0_1 = a1;
return (require(566) /* metro dependency 566: flux */).useStateFromStoresObject([MediaEngineStore, VoiceStateStore],
_fun72285, [a1, a0]);
}
function useMuteDeafenIconState(a0, a1) { // fn#72286, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:9430:1409, offset: 0x01d41a53, size: 142 bytes, params: 3, frame: 14
const value2 = useStableVoiceParticipant(a0, a1);
const value3 = null;
return value3 == value2 ? value3 : value2.deaf ? env0_5.DEAFENED_SERVER : value2.selfDeaf ? env0_5.DEAFENED : value2.mute ? env0_5.MUTED_SERVER : value2.isLocalMute ? env0_5.MUTED_LOCAL : value2.selfMute ? env0_5.MUTED : value3;
}
function useVideoIconState(a0, a1) { // fn#72287, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:9430:1687, offset: 0x01d41ae1, size: 113 bytes, params: 3, frame: 15
const value2 = useStableVideoState(a0, a1);
const value3 = null;
return value3 == value2 ? value3 : value2.selfVideo ? value2.localVideoDisabledState === 'auto' ? env0_6.VIDEO_DISABLED_LOCAL_AUTO : value2.localVideoDisabledState === 'manual' ? env0_6.VIDEO_DISABLED_LOCAL : env0_6.VIDEO_ACTIVE : value3;
}
function _fun72283() { // fn#72283, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:9430:640, offset: 0x01d418e0, size: 121 bytes, params: 1, frame: 15
var voiceState;
if (env0_0 != null) {
voiceState = VoiceStateStore.getVoiceState(require, env0_0);
if (voiceState != null) {
return {deaf: voiceState.deaf, selfDeaf: voiceState.selfDeaf, mute: voiceState.mute,
isLocalMute: MediaEngineStore.isLocalMute(voiceState.userId), selfMute: voiceState.selfMute};
}
}
}
function _fun72285() { // fn#72285, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:9430:918, offset: 0x01d419b8, size: 155 bytes, params: 1, frame: 16
const value2 = null;
const r2 = value2 != env0_0 ? VoiceStateStore.getVoiceState(require, env0_0) : undefined;
if (value2 == env0_0) {
return {'selfVideo': false, 'localVideoDisabledState': null};
}
if (value2 == r2) {
return {'selfVideo': false, 'localVideoDisabledState': null};
}
const value = environment.__proto__;
const isLocalVideoDisabled = MediaEngineStore.isLocalVideoDisabled;
const userId = r2.userId;
return {selfVideo: r2.selfVideo, localVideoDisabledState: Reflect.apply(isLocalVideoDisabled, MediaEngineStore,
[userId]) ? MediaEngineStore.isLocalVideoAutoDisabled(r2.userId) ? 'auto' : 'manual' : value2};
}
@@ -0,0 +1,35 @@
/* Metro module 15489; source: modules/voice_panel/native/utils/calculateContentCenterOffset.tsx; dependencies: [11798, 11624, 2] */
function _fun118616(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#118616, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15686:6, offset: 0x024e4d19, size: 184 bytes, params: 8, frame: 19
const Object = global.Object;
Object.defineProperty(exports, '__esModule', {value: true});
const EDGE_GUTTER = (require(11798) /* metro dependency 11798: VoicePanelCardConstants */).EDGE_GUTTER;
const closure = t_118617;
closure.__closure = {EDGE_GUTTER: EDGE_GUTTER,
roundToNearestPixel: importDefault(11624) /* metro dependency 11624: roundToNearestPixel */};
closure.__workletHash = 9988657249690;
closure.__initData = {code: 'function calculateContentCenterOffset_calculateContentCenterOffsetTsx1({contentHeight:contentHeight,windowHeight:windowHeight,safeArea:safeArea}){const{EDGE_GUTTER,roundToNearestPixel}=this.__closure;const safeAreaTop=Math.max(safeArea.top,EDGE_GUTTER);const safeAreaBottom=Math.max(safeArea.bottom,EDGE_GUTTER);if(windowHeight<=contentHeight){return safeAreaTop;}return Math.max(safeAreaTop,safeAreaTop+roundToNearestPixel((windowHeight-safeAreaTop-safeAreaBottom-contentHeight)/2));}'};
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/voice_panel/native/utils/calculateContentCenterOffset.tsx');
exports.default = closure;
}
function t_118617({contentHeight, windowHeight, safeArea}) { // fn#118617, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15686:623, offset: 0x024e4dd1, size: 150 bytes, params: 2, frame: 19
var r0;
let Math = global.Math;
let max = Math.max;
const top = safeArea.top;
var value;
const value2 = Reflect.apply(max, Math, [top, EDGE_GUTTER]);
Math = global.Math;
if (windowHeight <= contentHeight) {
r0 = value2;
} else {
Math = global.Math;
max = Math.max;
value = importDefault(11624) /* metro dependency 11624: roundToNearestPixel */;
value = Reflect.apply(max, Math, [value2, value2 + value((windowHeight - value2 - Math.max(safeArea.bottom,
EDGE_GUTTER) - contentHeight) / 2)]);
r0 = value;
}
return r0;
}
@@ -0,0 +1,45 @@
/* Metro module 15438; source: modules/voice_panel/native/utils/calculatePIPState.tsx; dependencies: [4606, 4492, 11795, 4299, 4285, 15439, 2] */
function _fun118123(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#118123, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15635:6, offset: 0x024cc6aa, size: 174 bytes, params: 8, frame: 19
const env0_0 = require;
const Object = global.Object;
Object.defineProperty(exports, '__esModule', {value: true});
const channelRTCStore = importDefault(4606) /* metro dependency 4606: ChannelRTCStore */;
const applicationStreamingStore = importDefault(4492) /* metro dependency 4492: ApplicationStreamingStore */;
const env0_4 = (require(11795) /* metro dependency 11795: VoicePanelConstants */).VoicePanelModes;
const env0_5 = (require(4299) /* metro dependency 4299: CallConstants */).ParticipantTypes;
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/voice_panel/native/utils/calculatePIPState.tsx');
exports.default = calculatePIPState;
}
function calculatePIPState(a0, a1, a2, a3, a4) { // fn#118124, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15635:267, offset: 0x024cc758, size: 534 bytes, params: 6, frame: 26
var add;
var moduleValue;
const r7 = a4.focusedId != null && ChannelRTCStore.getParticipant(a0,
a4.focusedId)?.type === ParticipantTypes.ACTIVITY;
const Set = global.Set;
let set = new Set();
const currentUserActiveStream = ApplicationStreamingStore.getCurrentUserActiveStream();
if (currentUserActiveStream != null) {
add = set.add;
moduleValue = require(4285) /* metro dependency 4285: StreamKeyUtils */;
Reflect.apply(add, set, [moduleValue.encodeStreamKey(currentUserActiveStream)]);
}
const mode = a4.mode;
const PANEL = VoicePanelModes.PANEL;
const value6 = mode === PANEL;
if (a4.focusedId != null && value6) {
set.add(a4.focusedId);
}
const value8 = undefined;
set = (require(15439) /* metro dependency 15439: VoicePanelPIPUtils */).computePIPParticipantToShow({channelId: a0,
lastParticipantId: a2, speakingUserId: a3, focusedParticipantId: a4.focusedId, blockList: set,
panelMode: a4.mode, showSecondaryPIP: a4.showSecondaryPIP});
const type = set == null ? value8 : set.type;
const STREAM = ParticipantTypes.STREAM;
const r5 = type !== STREAM && (set == null ? value8 : set.type) !== ParticipantTypes.ACTIVITY && (a4.focusedId == null || (set == null ? value8 : set.id) !== a4.focusedId);
const voicePanelPIPUtilsModule = require(15439) /* metro dependency 15439: VoicePanelPIPUtils */;
return {participant: set,
dimensions: voicePanelPIPUtilsModule.computePIPSize(a1.getTargetDimensions(set == null ? value8 : set.id) ?? voicePanelPIPUtilsModule.SquarePIPReferenceDimensions,
r5, value6 && r7, a4.showSecondaryPIP)};
}
@@ -0,0 +1,13 @@
/* Metro module 8088; source: modules/voice_panel/native/utils/closeVoicePanels.tsx; dependencies: [661, 1239, 2] */
function _fun64826(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#64826, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:8273:6, offset: 0x01bb6591, size: 115 bytes, params: 8, frame: 18
const env0_0 = require;
const Object = global.Object;
Object.defineProperty(exports, '__esModule', {value: true});
const env0_2 = (require(661) /* metro dependency 661: Constants */).ComponentActions;
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/voice_panel/native/utils/closeVoicePanels.tsx');
exports.default = function() {
var ComponentDispatch = require(dependencyMap[1]).ComponentDispatch;
ComponentDispatch.dispatch(ComponentActions.VOICE_PANEL_CLOSE);
};
}
@@ -0,0 +1,28 @@
/* Metro module 15488; source: modules/voice_panel/native/utils/computeCardBorderRadius.tsx; dependencies: [11795, 2] */
function _fun118614(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#118614, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15685:6, offset: 0x024e4c0e, size: 171 bytes, params: 8, frame: 19
const Object = global.Object;
Object.defineProperty(exports, '__esModule', {value: true});
const {VoicePanelModes,
DEFAULT_BORDER_RADIUS_PIP} = require(11795) /* metro dependency 11795: VoicePanelConstants */;
const closure = function({id, mode, focused, isSelf, defaultBorderRadius}) {
if (mode === VoicePanelModes.PANEL) {
if (focused == null) {
return defaultBorderRadius;
}
if (focused === id) {
return 0;
}
if (isSelf) {
return DEFAULT_BORDER_RADIUS_PIP;
}
return defaultBorderRadius;
}
return mode !== VoicePanelModes.PIP ? defaultBorderRadius : DEFAULT_BORDER_RADIUS_PIP;
};
closure.__closure = {VoicePanelModes: VoicePanelModes, DEFAULT_BORDER_RADIUS_PIP: DEFAULT_BORDER_RADIUS_PIP};
closure.__workletHash = 10593808953118;
closure.__initData = {code: 'function computeCardBorderRadius_computeCardBorderRadiusTsx1({id:id,mode:mode,focused:focused,isSelf:isSelf,defaultBorderRadius:defaultBorderRadius}){const{VoicePanelModes,DEFAULT_BORDER_RADIUS_PIP}=this.__closure;if(mode===VoicePanelModes.PANEL){if(focused!=null){if(focused===id){return 0;}else if(isSelf){return DEFAULT_BORDER_RADIUS_PIP;}}return defaultBorderRadius;}if(mode===VoicePanelModes.PIP){return DEFAULT_BORDER_RADIUS_PIP;}return defaultBorderRadius;}'};
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/voice_panel/native/utils/computeCardBorderRadius.tsx');
exports.default = closure;
}
@@ -0,0 +1,296 @@
/* Metro module 11800; source: modules/voice_panel/native/utils/fitCardsInGrid.tsx; dependencies: [2] */
function _fun90387(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#90387, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:11986:6, offset: 0x020373c7, size: 98 bytes, params: 8, frame: 16
const Object = global.Object;
Object.defineProperty(exports, '__esModule', {value: true});
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/voice_panel/native/utils/fitCardsInGrid.tsx');
exports.default = fitCardsInGrid;
}
function isNewLayoutBetter(a0, a1) { // fn#90388, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:11986:43, offset: 0x02037429, size: 377 bytes, params: 3, frame: 17
var Math;
var abs;
var value;
var value2;
var max;
var value3;
var min;
var rows;
var columns;
var value5;
var value6;
let unusedSpace = a1.unusedSpace;
if (unusedSpace === 0) {
return false;
}
if (a0.unusedSpace === a1.unusedSpace) {
return false;
}
if (a0.unusedSpace === 0) {
return true;
}
if (a1.unusedSpace === Infinity) {
return true;
}
unusedSpace = a1.unusedSpace;
if (unusedSpace > 0) {
unusedSpace = a0.unusedSpace;
if (unusedSpace < 0) {
return false;
}
unusedSpace = a0.unusedSpace;
if (unusedSpace > 0) {
unusedSpace = a1.unusedSpace;
if (unusedSpace < 0) {
return true;
}
Math = global.Math;
abs = Math.abs;
unusedSpace = a1.unusedSpace;
value = Reflect.apply(abs, Math, [unusedSpace]);
Math = global.Math;
abs = Math.abs;
unusedSpace = a0.unusedSpace;
value2 = Reflect.apply(abs, Math, [unusedSpace]);
Math = global.Math;
value3 = Math.max(value, value2);
Math = global.Math;
min = Math.min;
if (value3 - Reflect.apply(min, Math, [value, value2]) < 5000) {
Math = global.Math;
max = Math.max;
rows = a0.rows;
columns = a0.columns;
value = Reflect.apply(max, Math, [rows, columns]);
Math = global.Math;
min = Math.min;
rows = a0.rows;
columns = a0.columns;
value -= Reflect.apply(min, Math, [rows, columns]);
Math = global.Math;
max = Math.max;
rows = a1.rows;
columns = a1.columns;
value5 = Reflect.apply(max, Math, [rows, columns]);
Math = global.Math;
min = Math.min;
rows = a1.rows;
columns = a1.columns;
value6 = value5 - Reflect.apply(min, Math, [rows, columns]);
return value6 !== value && value < value6;
}
return value2 < value;
}
Math = global.Math;
abs = Math.abs;
unusedSpace = a1.unusedSpace;
value = Reflect.apply(abs, Math, [unusedSpace]);
Math = global.Math;
abs = Math.abs;
unusedSpace = a0.unusedSpace;
value2 = Reflect.apply(abs, Math, [unusedSpace]);
Math = global.Math;
value3 = Math.max(value, value2);
Math = global.Math;
min = Math.min;
if (value3 - Reflect.apply(min, Math, [value, value2]) < 5000) {
Math = global.Math;
max = Math.max;
rows = a0.rows;
columns = a0.columns;
value = Reflect.apply(max, Math, [rows, columns]);
Math = global.Math;
min = Math.min;
rows = a0.rows;
columns = a0.columns;
value -= Reflect.apply(min, Math, [rows, columns]);
Math = global.Math;
max = Math.max;
rows = a1.rows;
columns = a1.columns;
value5 = Reflect.apply(max, Math, [rows, columns]);
Math = global.Math;
min = Math.min;
rows = a1.rows;
columns = a1.columns;
value6 = value5 - Reflect.apply(min, Math, [rows, columns]);
return value6 !== value && value < value6;
}
} else {
unusedSpace = a0.unusedSpace;
if (unusedSpace > 0) {
unusedSpace = a1.unusedSpace;
if (unusedSpace < 0) {
return true;
}
Math = global.Math;
abs = Math.abs;
unusedSpace = a1.unusedSpace;
value = Reflect.apply(abs, Math, [unusedSpace]);
Math = global.Math;
abs = Math.abs;
unusedSpace = a0.unusedSpace;
value2 = Reflect.apply(abs, Math, [unusedSpace]);
Math = global.Math;
value3 = Math.max(value, value2);
Math = global.Math;
min = Math.min;
if (value3 - Reflect.apply(min, Math, [value, value2]) < 5000) {
Math = global.Math;
max = Math.max;
rows = a0.rows;
columns = a0.columns;
value = Reflect.apply(max, Math, [rows, columns]);
Math = global.Math;
min = Math.min;
rows = a0.rows;
columns = a0.columns;
value -= Reflect.apply(min, Math, [rows, columns]);
Math = global.Math;
max = Math.max;
rows = a1.rows;
columns = a1.columns;
value5 = Reflect.apply(max, Math, [rows, columns]);
Math = global.Math;
min = Math.min;
rows = a1.rows;
columns = a1.columns;
value6 = value5 - Reflect.apply(min, Math, [rows, columns]);
return value6 !== value && value < value6;
}
return value2 < value;
}
Math = global.Math;
value = Math.abs(a1.unusedSpace);
Math = global.Math;
value2 = Math.abs(a0.unusedSpace);
Math = global.Math;
value3 = Math.max(value, value2);
Math = global.Math;
if (value3 - Math.min(value, value2) < 5000) {
Math = global.Math;
max = Math.max;
rows = a0.rows;
columns = a0.columns;
value = Reflect.apply(max, Math, [rows, columns]);
Math = global.Math;
min = Math.min;
rows = a0.rows;
columns = a0.columns;
value -= Reflect.apply(min, Math, [rows, columns]);
Math = global.Math;
max = Math.max;
rows = a1.rows;
columns = a1.columns;
value5 = Reflect.apply(max, Math, [rows, columns]);
Math = global.Math;
min = Math.min;
rows = a1.rows;
columns = a1.columns;
value6 = value5 - Reflect.apply(min, Math, [rows, columns]);
return value6 !== value && value < value6;
}
}
return value2 < value;
}
function fitCardsInGrid({cardCount, gutterSize, availableWidth, availableHeight}) { // fn#90389, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:11986:658, offset: 0x020375a2, size: 441 bytes, params: 2, frame: 33
var r2;
var r3;
var r17;
var r19;
var r16;
var r1;
var value4;
var value5;
var Math;
var value6;
var value7;
var value8;
var value9;
var value10;
var value11;
var value12;
var overscroll;
var rows;
var value13;
var value14;
var value15;
var value16;
var object3;
var columns;
var value17;
var value18;
var value19;
var value20;
let object4 = {'columns': 1, 'rows': 0, 'cardSize': 0, 'overscroll': 0, 'unusedSpace': Infinity};
if (1 <= cardCount) {
r2 = 1;
r3 = object4;
while (true) {
value4 = (availableWidth - (r2 - 1) * gutterSize) / r2;
value5 = cardCount % r2;
Math = global.Math;
value6 = Math.floor(cardCount / r2);
r17 = value5 > 0 ? 1 : 0;
value7 = value6 + r17;
object4 = {};
value8 = value4 * r2;
value9 = availableWidth * availableHeight;
value10 = (r2 - 1) * gutterSize;
value11 = (value7 - 1) * gutterSize;
value12 = value4 * value7 + value11;
object4.unusedSpace = value9 - (value8 + value10) * value12;
object4.columns = r2;
object4.overscroll = availableHeight - value12;
object4.rows = value7;
object4.cardSize = value4;
if (isNewLayoutBetter(object4, r3)) {
r19 = object4;
continue;
}
r19 = r3;
continue;
overscroll = object4.overscroll;
if (overscroll < 0) {
rows = object4.rows;
value13 = availableHeight - (rows - 1) * gutterSize;
rows = object4.rows;
value14 = value13 / rows;
rows = object4.rows;
value15 = value14 * rows;
rows = object4.rows;
value16 = value15 + (rows - 1) * gutterSize;
object3 = {};
copyDataProperties(object3, object4, value11);
columns = object4.columns;
value17 = value14 * columns;
columns = object4.columns;
value18 = (columns - 1) * gutterSize;
value19 = availableWidth * availableHeight;
object3['unusedSpace'] = value19 - (value17 + value18) * value16;
object3['overscroll'] = availableHeight - value16;
object3['cardSize'] = value14;
if (isNewLayoutBetter(object3, r19)) {
r16 = object3;
continue;
}
r16 = r19;
continue;
}
r16 = r19;
continue;
value20 = typeof r2 === 'bigint' ? r2 + 1n : +r2 + 1;
if (value20 <= cardCount) {
r2 = value20;
r3 = r16;
continue;
}
r1 = r16;
break;
}
} else {
r1 = object4;
}
return {columns: r1.columns, cardSize: r1.cardSize};
}
@@ -0,0 +1,43 @@
/* Metro module 15464; source: modules/voice_panel/native/utils/getChannelInfoSubtitle.tsx; dependencies: [4617, 1244, 2] */
function _fun118380(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#118380, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15661:6, offset: 0x024d9a8e, size: 103 bytes, params: 8, frame: 18
const env0_0 = require;
const Object = global.Object;
Object.defineProperty(exports, '__esModule', {value: true});
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/voice_panel/native/utils/getChannelInfoSubtitle.tsx');
exports.default = getChannelInfoSubtitle;
}
function getChannelInfoSubtitle(a0, a1, a2) { // fn#118381, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15661:195, offset: 0x024d9af5, size: 371 bytes, params: 4, frame: 27
const intl = (require(1244) /* metro dependency 1244: indexNative */).intl;
var formatToPlainString;
const t = (require(1244) /* metro dependency 1244: indexNative */).t;
var object2;
var property;
let value = a3;
const r11 = value !== undefined ? value : 0;
const length = a2.length;
if (length === 0) {
return null;
}
if (length === 1) {
return (importDefault(4617) /* metro dependency 4617: NicknameUtils */).getName(a0, a1, a2[0]);
}
if (length === 2) {
formatToPlainString = intl.formatToPlainString;
property = t['lRD/ru'];
object2 = {};
value = importDefault(4617) /* metro dependency 4617: NicknameUtils */;
object2.user1 = value.getName(a0, a1, a2[0]);
value = importDefault(4617) /* metro dependency 4617: NicknameUtils */;
object2.user2 = value.getName(a0, a1, a2[1]);
return Reflect.apply(formatToPlainString, intl, [property, object2]);
}
formatToPlainString = intl.formatToPlainString;
const RFCI3S = t.RFCI3S;
object2 = {};
object2.user1 = (importDefault(4617) /* metro dependency 4617: NicknameUtils */).getName(a0, a1, a2[0]);
object2.user2 = (importDefault(4617) /* metro dependency 4617: NicknameUtils */).getName(a0, a1, a2[1]);
object2.numPeople = a2.length - 2 + r11;
return Reflect.apply(formatToPlainString, intl, [RFCI3S, object2]);
}
@@ -0,0 +1,15 @@
/* Metro module 15492; source: modules/voice_panel/native/utils/getRandomNumberInRange.tsx; dependencies: [2] */
function _fun118630(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#118630, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15689:6, offset: 0x024e5509, size: 129 bytes, params: 8, frame: 16
const Object = global.Object;
Object.defineProperty(exports, '__esModule', {value: true});
const closure = function(a0, a1) {
var Math = global.Math;
return Math.random() * (a1 - a0) + a0;
};
closure.__closure = {};
closure.__workletHash = 3489295446061;
closure.__initData = {code: 'function getRandomNumberInRange_getRandomNumberInRangeTsx1(min,max){return Math.random()*(max-min)+min;}'};
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/voice_panel/native/utils/getRandomNumberInRange.tsx');
exports.default = closure;
}
@@ -0,0 +1,21 @@
/* Metro module 11624; source: modules/voice_panel/native/utils/roundToNearestPixel.tsx; dependencies: [27, 2] */
function _fun89185(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#89185, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:11810:6, offset: 0x0200324a, size: 165 bytes, params: 8, frame: 18
const Object = global.Object;
Object.defineProperty(exports, '__esModule', {value: true});
const PixelRatio = (require(27) /* metro dependency 27 */).PixelRatio;
const value = PixelRatio.get();
const closure = t_89186;
closure.__closure = {PIXEL_DENSITY: value};
closure.__workletHash = 8009828326153;
closure.__initData = {code: 'function roundToNearestPixel_roundToNearestPixelTsx1(position){const{PIXEL_DENSITY}=this.__closure;return Math.round(position*PIXEL_DENSITY)/PIXEL_DENSITY;}'};
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/voice_panel/native/utils/roundToNearestPixel.tsx');
exports.default = closure;
}
function t_89186(a0) { // fn#89186, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:11810:299, offset: 0x020032ef, size: 38 bytes, params: 2, frame: 12
const Math = global.Math;
const round = Math.round;
const binding = env0_0;
return Reflect.apply(round, Math, [a0 * binding]) / binding;
}
@@ -0,0 +1,10 @@
/* Metro module 15446; source: modules/voice_panel/native/utils/triggerIOSHaptic.tsx; dependencies: [11795, 4081, 2] */
function _fun118233(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#118233, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15643:6, offset: 0x024d26ea, size: 117 bytes, params: 8, frame: 18
const env0_0 = require;
const Object = global.Object;
Object.defineProperty(exports, '__esModule', {value: true});
const env0_2 = (require(11795) /* metro dependency 11795: VoicePanelConstants */).IS_IOS;
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/voice_panel/native/utils/triggerIOSHaptic.tsx');
exports.default = triggerIOSHaptic_118234;
}
@@ -0,0 +1,74 @@
/* Metro module 15433; source: modules/voice_panel/native/utils/useIsVoicePanelParticipantFocusable.tsx; dependencies: [1378, 4606, 4492, 4259, 4299, 10692, 1360, 566, 2] */
function _fun118059(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#118059, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15630:6, offset: 0x024ca8e2, size: 221 bytes, params: 8, frame: 20
let env0_0 = require;
const closure = isVoicePanelParticipantFocusable;
const Object = global.Object;
Object.defineProperty(exports, '__esModule', {value: true});
const embeddedActivitiesStore = importDefault(1378) /* metro dependency 1378: EmbeddedActivitiesStore */;
const channelRTCStore = importDefault(4606) /* metro dependency 4606: ChannelRTCStore */;
const applicationStreamingStore = importDefault(4492) /* metro dependency 4492: ApplicationStreamingStore */;
const mediaEngineStore = importDefault(4259) /* metro dependency 4259: MediaEngineStore */;
const callConstantsModule = require(4299) /* metro dependency 4299: CallConstants */;
const env0_6 = callConstantsModule.isActivityParticipant;
const env0_7 = callConstantsModule.isStreamParticipant;
const env0_8 = callConstantsModule.isUserParticipant;
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/voice_panel/native/utils/useIsVoicePanelParticipantFocusable.tsx');
exports.default = function(a0, a1, a2) {
var env0_0 = a0;
var env0_1 = a1;
var env0_2 = a2;
return require(dependencyMap[7]).useStateFromStores([ChannelRTCStore, MediaEngineStore, EmbeddedActivitiesStore,
ApplicationStreamingStore], _fun118062);
};
exports.isVoicePanelParticipantFocusable = closure;
}
function isVoicePanelParticipantFocusable(a0, a1, a2) { // fn#118060, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15630:218, offset: 0x024ca9bf, size: 278 bytes, params: 4, frame: 19
var r1;
var currentEmbeddedActivity;
let value = a3;
const value2 = a4;
const value3 = a5;
const value4 = a6;
const value5 = undefined;
const r5 = value !== value5 ? value : ChannelRTCStore;
const r7 = value2 !== value5 ? value2 : MediaEngineStore;
const r4 = value3 !== value5 ? value3 : EmbeddedActivitiesStore;
const r8 = value4 !== value5 ? value4 : ApplicationStreamingStore;
if (a2 == null) {
return false;
}
value = r5.getParticipant(a1, a2);
if (value == null) {
return false;
}
if (isActivityParticipant(value)) {
currentEmbeddedActivity = r4.getCurrentEmbeddedActivity();
return (currentEmbeddedActivity == null ? value5 : currentEmbeddedActivity.applicationId) != null && value.applicationId === currentEmbeddedActivity.applicationId;
}
if (isStreamParticipant(value)) {
value = r8.getActiveStreamForUser(value.user.id, a0) != null;
r1 = value;
} else if (isUserParticipant(value)) {
value = (require(10692) /* metro dependency 10692: participantHasVideo */).canRenderParticipantVideo(value, r7);
r1 = value;
} else {
(require(1360) /* metro dependency 1360: GlobalUtils */).assertNever(value);
r1 = value5;
}
return r1;
}
function useIsVoicePanelParticipantFocusable(a0, a1, a2) { // fn#118061, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15630:722, offset: 0x024caad5, size: 104 bytes, params: 4, frame: 15
const env0_0 = a0;
const env0_1 = a1;
const env0_2 = a2;
return (require(566) /* metro dependency 566: flux */).useStateFromStores([ChannelRTCStore, MediaEngineStore,
EmbeddedActivitiesStore, ApplicationStreamingStore], _fun118062);
}
function _fun118062() { // fn#118062, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15630:819, offset: 0x024cab3d, size: 46 bytes, params: 1, frame: 23
return isVoicePanelParticipantFocusable(env0_0, require, importDefault, ChannelRTCStore, MediaEngineStore,
EmbeddedActivitiesStore, ApplicationStreamingStore);
}
@@ -0,0 +1,33 @@
/* Metro module 15437; source: modules/voice_panel/native/utils/useSelfHasVideo.tsx; dependencies: [4606, 1226, 4259, 566, 10692, 2] */
function _fun118120(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#118120, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15634:6, offset: 0x024cc56a, size: 146 bytes, params: 8, frame: 19
let env0_0 = require;
const Object = global.Object;
Object.defineProperty(exports, '__esModule', {value: true});
const channelRTCStore = importDefault(4606) /* metro dependency 4606: ChannelRTCStore */;
const authenticationStore = importDefault(1226) /* metro dependency 1226: AuthenticationStore */;
const mediaEngineStore = importDefault(4259) /* metro dependency 4259: MediaEngineStore */;
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/voice_panel/native/utils/useSelfHasVideo.tsx');
exports.default = function(a0) {
var env0_0 = a0;
return require(dependencyMap[3]).useStateFromStores([ChannelRTCStore, AuthenticationStore, MediaEngineStore],
_fun118122);
};
}
function useSelfHasVideo(a0) { // fn#118121, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15634:222, offset: 0x024cc5fc, size: 82 bytes, params: 2, frame: 15
const env0_0 = a0;
return (require(566) /* metro dependency 566: flux */).useStateFromStores([ChannelRTCStore, AuthenticationStore,
MediaEngineStore], _fun118122);
}
function _fun118122() { // fn#118122, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15634:293, offset: 0x024cc64e, size: 92 bytes, params: 1, frame: 18
const value2 = undefined;
const participantHasVideoModule = require(10692) /* metro dependency 10692: participantHasVideo */;
const canRenderParticipantVideo = participantHasVideoModule.canRenderParticipantVideo;
const getParticipant = ChannelRTCStore.getParticipant;
const binding = env0_0;
const getId = AuthenticationStore.getId;
return Reflect.apply(canRenderParticipantVideo, participantHasVideoModule, [Reflect.apply(getParticipant,
ChannelRTCStore, [binding, Reflect.apply(getId, AuthenticationStore, [])]) ?? value2, MediaEngineStore]);
}
@@ -0,0 +1,174 @@
/* Metro module 15456; source: modules/voice_panel/native/utils/useStableParticipant.tsx; dependencies: [4606, 1226, 4259, 1878, 4299, 628, 566, 4617, 4618, 10692, 2] */
function _fun118302(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#118302, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15653:6, offset: 0x024d5b34, size: 276 bytes, params: 8, frame: 22
const env0_0 = require;
const closure = function(a0) {
var Boolean = global.Boolean;
var value = undefined;
return Boolean((a0 == null ? value : a0.type) === ParticipantTypes.STREAM || (a0 == null ? value : a0.type) === ParticipantTypes.HIDDEN_STREAM);
};
const closure2 = function(a0) {
var Boolean = global.Boolean;
return Boolean(a0?.type === ParticipantTypes.USER);
};
const closure3 = function(a0) {
var Boolean = global.Boolean;
return Boolean(a0?.type === ParticipantTypes.ACTIVITY);
};
const Object = global.Object;
Object.defineProperty(exports, '__esModule', {value: true});
const channelRTCStore = importDefault(4606) /* metro dependency 4606: ChannelRTCStore */;
const authenticationStore = importDefault(1226) /* metro dependency 1226: AuthenticationStore */;
const mediaEngineStore = importDefault(4259) /* metro dependency 4259: MediaEngineStore */;
const userStore = importDefault(1878) /* metro dependency 1878: UserStore */;
const env0_7 = (require(4299) /* metro dependency 4299: CallConstants */).ParticipantTypes;
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/voice_panel/native/utils/useStableParticipant.tsx');
exports.default = useStableParticipant;
exports.isStableStreamParticipant = closure;
exports.isStableUserParticipant = closure2;
exports.isStableActivityParticipant = closure3;
exports.isStableParticipantWithUser = isStableParticipantWithUser;
exports.stableParticipantHasVideo = stableParticipantHasVideo;
}
function areStableParticipantsEqual(a0, a1) { // fn#118306, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15653:473, offset: 0x024d5d06, size: 65 bytes, params: 3, frame: 16
var r1;
var r0;
const value = a0 === a1;
if (value) {
r0 = value;
} else {
r1 = a0 != null && a1 != null;
r1 = r1 && (importDefault(628) /* metro dependency 628: shallowEqual */)(a0, a1);
r0 = r1;
}
return r0;
}
function useStableParticipant(a0, a1, a2) { // fn#118307, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15653:661, offset: 0x024d5d47, size: 131 bytes, params: 4, frame: 20
const env0_0 = a0;
const env0_1 = a1;
const env0_2 = a2;
return (require(566) /* metro dependency 566: flux */).useStateFromStores([ChannelRTCStore, UserStore,
AuthenticationStore, MediaEngineStore], _fun118308, [a0, a1, a2], areStableParticipantsEqual);
}
function isStableParticipantWithUser(a0) { // fn#118309, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15653:1993, offset: 0x024d6090, size: 31 bytes, params: 2, frame: 13
return isStableStreamParticipant(a0) || isStableUserParticipant(a0);
}
function stableParticipantHasVideo(a0) { // fn#118310, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15653:2126, offset: 0x024d60af, size: 60 bytes, params: 2, frame: 13
return !isStableActivityParticipant(a0) && (isStableStreamParticipant(a0) ? a0.streamId != null : a0.selfVideo);
}
function _fun118308() { // fn#118308, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15653:743, offset: 0x024d5dca, size: 710 bytes, params: 1, frame: 23
var selfVideo;
var r9;
var user;
var id;
var id2;
var object2;
var voiceState;
var id3;
var user2;
var id4;
if (env0_0 != null) {
var participant = ChannelRTCStore.getParticipant(require, env0_0);
var value4 = undefined;
var r3 = participant ?? value4;
if (r3 == null) {
user2 = UserStore.getUser(env0_0);
if (user2 == null) {
return value4;
}
id = user2.id;
id4 = AuthenticationStore.getId();
object2 = {};
object2.type = ParticipantTypes.USER;
object2.id = env0_0;
object2.user = user2;
object2.selfVideo = false;
object2.canRenderVideo = false;
object2.userNick = (require(4617) /* metro dependency 4617: NicknameUtils */).getName(importDefault,
require,
user2);
object2.userAvatarDecoration = (require(4618) /* metro dependency 4618: useAvatarDecoration */).getAvatarDecoration(user2,
importDefault);
object2.streamId = value4;
object2.ringing = false;
object2.hasVideo = false;
object2.isSelf = id === id4;
return object2;
}
var value5 = (importDefault(10692) /* metro dependency 10692: participantHasVideo */)(r3);
var type = r3.type;
var ACTIVITY = ParticipantTypes.ACTIVITY;
if (ACTIVITY === type) {
return {type: r3.type, id: env0_0, applicationId: r3.applicationId};
}
var STREAM = ParticipantTypes.STREAM;
if (STREAM === type) {
user = r3.user;
id = user.id;
id3 = AuthenticationStore.getId();
object2 = {};
object2.type = r3.type;
object2.id = env0_0;
user = r3.user;
object2.user = user;
object2.userNick = r3.userNick;
r9 = r3.streamId ?? value4;
object2.streamId = r9;
r9 = r3.stream.guildId ?? value4;
object2.streamGuildId = r9;
object2.hasVideo = value5;
object2.isSelf = id === id3;
return object2;
}
var HIDDEN_STREAM = ParticipantTypes.HIDDEN_STREAM;
if (HIDDEN_STREAM === type) {
user = r3.user;
id = user.id;
id3 = AuthenticationStore.getId();
object2 = {};
object2.type = r3.type;
object2.id = env0_0;
user = r3.user;
object2.user = user;
object2.userNick = r3.userNick;
r9 = r3.streamId ?? value4;
object2.streamId = r9;
r9 = r3.stream.guildId ?? value4;
object2.streamGuildId = r9;
object2.hasVideo = value5;
object2.isSelf = id === id3;
return object2;
}
if (ParticipantTypes.USER === type) {
user = r3.user;
id = user.id;
id2 = AuthenticationStore.getId();
object2 = {};
object2.type = r3.type;
object2.id = env0_0;
user = r3.user;
object2.user = user;
voiceState = r3.voiceState;
selfVideo = voiceState == null ? value4 : voiceState.selfVideo;
r9 = selfVideo != null && selfVideo;
object2.selfVideo = r9;
object2.userNick = r3.userNick;
object2.userAvatarDecoration = r3.userAvatarDecoration;
r9 = r3.streamId ?? value4;
object2.streamId = r9;
object2.ringing = r3.ringing;
object2.hasVideo = value5;
r9 = value5 && !MediaEngineStore.isLocalVideoDisabled(r3.user.id);
object2.canRenderVideo = r9;
object2.isSelf = id === id2;
return object2;
}
}
}