Initial commit
This commit is contained in:
commit
af3b49f756
16065 files changed
+2938410
No files matched your search
File diff suppressed because it is too large.
Load diff
@@ -0,0 +1,130 @@
|
||||
/* Metro module 8421; source: modules/calls/native/VideoBackground.tsx; dependencies: [57, 31, 27, 661, 33, 4501, 22, 8422, 8423, 4000, 697, 1305, 2] */
|
||||
function _fun66879(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#66879, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:8606:6, offset: 0x01c0dbfc, size: 414 bytes, params: 8, frame: 26
|
||||
const env0_0 = require;
|
||||
const closure = useDominantRGBFromImage;
|
||||
const closure2 = useDominantColorFromImage;
|
||||
const closure3 = VideoBackground;
|
||||
const Object = global.Object;
|
||||
Object.defineProperty(exports, '__esModule', {value: true});
|
||||
const env0_3 = importDefault(57) /* metro dependency 57 */;
|
||||
let value = importAll(31) /* metro dependency 31 */;
|
||||
let value2 = require(27) /* metro dependency 27 */;
|
||||
const env0_5 = value2.View;
|
||||
const env0_6 = value2.NativeModules;
|
||||
const env0_7 = value2.Image;
|
||||
const env0_8 = (require(661) /* metro dependency 661: Constants */).NOOP;
|
||||
const value3 = require(33) /* metro dependency 33 */;
|
||||
const env0_9 = value3.jsx;
|
||||
const env0_10 = value3.jsxs;
|
||||
const env0_11 = (require(4501) /* metro dependency 4501: createStyles */).createStyles({videoBackground: {alignItems: 'center'},
|
||||
videoDetailsSpacer: {paddingTop: 12}});
|
||||
const value6 = (importDefault(22) /* metro dependency 22 */).memoize(function(a0) {
|
||||
var value = a0;
|
||||
var value2 = null;
|
||||
return value2 == value || value === '' ? value2 : typeof value === 'number' ? value : {uri: value};
|
||||
});
|
||||
const AvatarSizes = (require(1305) /* metro dependency 1305: native */).AvatarSizes;
|
||||
closure3.AvatarSizes = AvatarSizes;
|
||||
value = value.memo(closure3);
|
||||
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/calls/native/VideoBackground.tsx');
|
||||
exports.default = value;
|
||||
exports.AvatarSizes = AvatarSizes;
|
||||
exports.memoizedImageSource = value6;
|
||||
exports.useDominantRGBFromImage = closure;
|
||||
exports.useDominantColorFromImage = closure2;
|
||||
}
|
||||
|
||||
function useDominantRGBFromImage(a0, a1) { // fn#66880, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:8606:384, offset: 0x01c0dd9a, size: 273 bytes, params: 3, frame: 23
|
||||
var moduleValue;
|
||||
const value = a1;
|
||||
const env0_0 = a0;
|
||||
const Array = global.Array;
|
||||
const r7 = Array.isArray(value) ? value[0] : value;
|
||||
const value2 = undefined;
|
||||
const value3 = (importDefault(8422) /* metro dependency 8422: useGetIsMounted */)();
|
||||
const binding = env0_4;
|
||||
const useState = binding.useState;
|
||||
let r0 = a0 != null ? (importDefault(8423) /* metro dependency 8423: VideoBackgroundManager */).cachedDominantColors[a0] : value2;
|
||||
if (r0 == null) {
|
||||
moduleValue = require(4000) /* metro dependency 4000: ColorUtils */;
|
||||
r0 = moduleValue.hexToRgb((importDefault(697) /* metro dependency 697: native */).unsafe_rawColors.PRIMARY_800);
|
||||
}
|
||||
const value6 = env0_3(Reflect.apply(useState, binding, [r0]), 2);
|
||||
const property = value6[0];
|
||||
var env0_3 = value6[1];
|
||||
env0_4.useEffect(_fun66881, [r7, a0, value3]);
|
||||
return property;
|
||||
}
|
||||
|
||||
function useDominantColorFromImage(a0, a1) { // fn#66883, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:8606:1013, offset: 0x01c0e01f, size: 80 bytes, params: 3, frame: 20
|
||||
const value = useDominantRGBFromImage(a0, a1);
|
||||
return 'rgb(' + value.r + ', ' + value.g + ', ' + value.b + ')';
|
||||
}
|
||||
|
||||
function VideoBackground(a0) { // fn#66884, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:8606:1124, offset: 0x01c0e06f, size: 331 bytes, params: 2, frame: 26
|
||||
const style = a0.style;
|
||||
const url = a0.url;
|
||||
let isStageCall = a0.isStageCall;
|
||||
const value = undefined;
|
||||
isStageCall = !(isStageCall === value) && isStageCall;
|
||||
const avatarStyle = a0.avatarStyle;
|
||||
a0.user;
|
||||
a0.guildId;
|
||||
const renderVideoDetails = a0.renderVideoDetails;
|
||||
const object2 = {'style': 0, 'url': 0, 'isStageCall': 0, 'avatarStyle': 0, 'user': 0, 'guildId': 0,
|
||||
'renderVideoDetails': 0};
|
||||
const value3 = null;
|
||||
silentSetPrototypeOf(object2, value3, undefined);
|
||||
const value4 = copyDataProperties({}, a0, object2, undefined);
|
||||
const styles = useStyles();
|
||||
const value6 = env0_12(url);
|
||||
const value7 = useDominantColorFromImage(url, value6);
|
||||
if (value3 == value6) {
|
||||
return value3;
|
||||
}
|
||||
const r1 = value3 == renderVideoDetails ? value : renderVideoDetails();
|
||||
const r6 = value3 != r1 ? r1 : value3;
|
||||
const items2 = [style];
|
||||
items2[1] = styles.videoBackground;
|
||||
items2[2] = {backgroundColor: value7};
|
||||
items2[3] = value3 != r6 ? styles.videoDetailsSpacer : value3;
|
||||
const Avatar = (require(1305) /* metro dependency 1305: native */).Avatar;
|
||||
return (
|
||||
<View style={items2}>
|
||||
<Avatar
|
||||
source={value6}
|
||||
{...value4}
|
||||
{...{['avatarStyle']: [avatarStyle, isStageCall ? {backgroundColor: value7} : value3]}}
|
||||
{...{['isStageCall']: isStageCall}}
|
||||
/>
|
||||
{r6}
|
||||
</View>
|
||||
);
|
||||
}
|
||||
|
||||
function _fun66881() { // fn#66881, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:8606:644, offset: 0x01c0deab, size: 253 bytes, params: 1, frame: 15
|
||||
var environment;
|
||||
var value4;
|
||||
if (require != null && env0_0 != null) {
|
||||
value4 = environment.__proto__;
|
||||
if ((importDefault(8423) /* metro dependency 8423: VideoBackgroundManager */).cachedDominantColors[env0_0] == null) {
|
||||
(typeof require === 'number' ? NativeModules.ImageManager.getDominantColorsLocalAsset(Image.resolveAssetSource(require)) : NativeModules.ImageManager.getDominantColors(Image.resolveAssetSource(require))).then(_fun66882).catch(NOOP);
|
||||
} else {
|
||||
env0_3((importDefault(8423) /* metro dependency 8423: VideoBackgroundManager */).cachedDominantColors[env0_0]);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
function _fun66882(a0) { // fn#66882, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:8606:859, offset: 0x01c0dfa8, size: 119 bytes, params: 2, frame: 16
|
||||
var value2;
|
||||
var value3;
|
||||
var object2;
|
||||
if (env1_2()) {
|
||||
value2 = environment.__proto__.__proto__;
|
||||
value3 = env2_3(a0[0], 3);
|
||||
object2 = {r: value3[0], g: value3[1], b: value3[2]};
|
||||
env1_3(object2);
|
||||
(importDefault(8423) /* metro dependency 8423: VideoBackgroundManager */).cachedDominantColors[env1_0] = object2;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -0,0 +1,87 @@
|
||||
/* Metro module 8423; source: modules/calls/native/VideoBackgroundManager.tsx; dependencies: [7, 6, 15, 17, 18, 1934, 4860, 2] */
|
||||
function _fun66891(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#66891, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:8608:6, offset: 0x01c0e2bd, size: 234 bytes, params: 8, frame: 18
|
||||
const Object = global.Object;
|
||||
Object.defineProperty(exports, '__esModule', {value: true});
|
||||
const env0_0 = importDefault(7) /* metro dependency 7 */;
|
||||
const env0_1 = importDefault(6) /* metro dependency 6 */;
|
||||
const env0_2 = importDefault(15) /* metro dependency 15 */;
|
||||
const env0_3 = importDefault(17) /* metro dependency 17 */;
|
||||
const env0_4 = importDefault(18) /* metro dependency 18 */;
|
||||
const selectedChannelStore = importDefault(1934) /* metro dependency 1934: SelectedChannelStore */;
|
||||
let value = importDefault(4860) /* metro dependency 4860: AutomaticLifecycleManager */;
|
||||
value = _fun66895(value);
|
||||
value = new value();
|
||||
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/calls/native/VideoBackgroundManager.tsx');
|
||||
exports.default = value;
|
||||
}
|
||||
|
||||
function _isNativeReflectConstruct_66892() { // fn#66892, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:8608:158, offset: 0x01c0e3a7, size: 98 bytes, params: 1, frame: 18
|
||||
var Boolean;
|
||||
var prototype;
|
||||
var valueOf;
|
||||
var call;
|
||||
var Reflect;
|
||||
var construct;
|
||||
var closure;
|
||||
var value;
|
||||
var error;
|
||||
try {
|
||||
Boolean = global.Boolean;
|
||||
prototype = Boolean.prototype;
|
||||
valueOf = prototype.valueOf;
|
||||
call = valueOf.call;
|
||||
Reflect = global.Reflect;
|
||||
construct = Reflect.construct;
|
||||
Boolean = global.Boolean;
|
||||
closure = function() {
|
||||
};
|
||||
value = Reflect.apply(construct, Reflect, [Boolean, [], closure]);
|
||||
value = Reflect.apply(call, valueOf, [value]);
|
||||
var result = !value;
|
||||
} catch (error) {
|
||||
}
|
||||
return (_isNativeReflectConstruct_66892_isNativeReflectConstruct = function() {
|
||||
return !!result;
|
||||
})();
|
||||
}
|
||||
|
||||
function _fun66895(a0) { // fn#66895, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:8608:361, offset: 0x01c0e409, size: 42 bytes, params: 2, frame: 14
|
||||
const closure = VideoBackgroundManager;
|
||||
env0_4(closure, a0);
|
||||
return env0_0(closure);
|
||||
}
|
||||
|
||||
function VideoBackgroundManager(a0) { // fn#66896, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:8608:373, offset: 0x01c0e433, size: 192 bytes, params: 2, frame: 21
|
||||
var r0;
|
||||
var Reflect;
|
||||
let value = copyRestArgs(0, undefined);
|
||||
let binding = env1_1;
|
||||
binding(this, VideoBackgroundManager);
|
||||
const items = [];
|
||||
arraySpread(items, value, 0, items);
|
||||
value = env1_3(VideoBackgroundManager);
|
||||
binding = env1_2;
|
||||
if (_isNativeReflectConstruct_66892()) {
|
||||
Reflect = global.Reflect;
|
||||
value = Reflect.construct(value, items, env1_3(this).constructor);
|
||||
r0 = value;
|
||||
} else {
|
||||
value = value.apply(this, items);
|
||||
r0 = value;
|
||||
}
|
||||
value = binding(this, r0);
|
||||
value.previousSelectedVoiceChannelId = SelectedChannelStore.getVoiceChannelId();
|
||||
value.cachedDominantColors = {};
|
||||
value._handleSelectVoiceChannel = _handleSelectVoiceChannel;
|
||||
var _handleSelectVoiceChannel = value._handleSelectVoiceChannel;
|
||||
value.actions = {VOICE_CHANNEL_SELECT: _handleSelectVoiceChannel};
|
||||
return value;
|
||||
}
|
||||
|
||||
function _handleSelectVoiceChannel({channelId}) { // fn#66897, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:8608:734, owner: VideoBackgroundManager._handleSelectVoiceChannel, offset: 0x01c0e4f3, size: 51 bytes, params: 2, frame: 4
|
||||
if (env0_0.previousSelectedVoiceChannelId !== channelId) {
|
||||
env0_0.cachedDominantColors = {};
|
||||
}
|
||||
env0_0.previousSelectedVoiceChannelId = channelId;
|
||||
}
|
||||
|
||||
@@ -0,0 +1,76 @@
|
||||
/* Metro module 7708; source: modules/calls/native/getPrivateChannelCall.tsx; dependencies: [4297, 661, 7709, 8214, 1244, 9228, 2] */
|
||||
function _fun61566(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#61566, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:7886:6, offset: 0x01b4564d, size: 134 bytes, params: 8, frame: 18
|
||||
const env0_0 = require;
|
||||
const Object = global.Object;
|
||||
Object.defineProperty(exports, '__esModule', {value: true});
|
||||
const voiceStateStore = importDefault(4297) /* metro dependency 4297: VoiceStateStore */;
|
||||
const env0_3 = (require(661) /* metro dependency 661: Constants */).NOOP_NULL;
|
||||
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/calls/native/getPrivateChannelCall.tsx');
|
||||
exports.default = getPrivateChannelCall;
|
||||
}
|
||||
|
||||
function getPrivateChannelCall(a0) { // fn#61567, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:7886:216, offset: 0x01b456d3, size: 621 bytes, params: 2, frame: 23
|
||||
var r1;
|
||||
var r3;
|
||||
var r4;
|
||||
var r7;
|
||||
var r9;
|
||||
var handleJoinCall;
|
||||
const intl = (require(1244) /* metro dependency 1244: indexNative */).intl;
|
||||
var string;
|
||||
const t = (require(1244) /* metro dependency 1244: indexNative */).t;
|
||||
let value = a1;
|
||||
const value2 = a2;
|
||||
const value3 = a3;
|
||||
const env0_0 = a0;
|
||||
const value4 = undefined;
|
||||
const r8 = value !== value4 ? value : false;
|
||||
if (value2 !== value4) {
|
||||
r1 = value2;
|
||||
} else {
|
||||
r1 = (require(7709) /* metro dependency 7709: PrivateChannelCallUtils */).handleStartCall;
|
||||
}
|
||||
if (value3 === value4) {
|
||||
handleJoinCall = (require(7709) /* metro dependency 7709: PrivateChannelCallUtils */).handleJoinCall;
|
||||
}
|
||||
const isInChannel2 = VoiceStateStore.isInChannel(a0.id);
|
||||
const useIsCallActiveModule = require(8214) /* metro dependency 8214: useIsCallActive */;
|
||||
if (a0.isSystemDM()) {
|
||||
value = null;
|
||||
r1 = NOOP_NULL;
|
||||
r3 = value;
|
||||
r4 = value4;
|
||||
} else if (isInChannel2) {
|
||||
r7 = r8 ? null : intl.string(t['4ry6yi']);
|
||||
r1 = getPrivateChannelCallC;
|
||||
r3 = r7;
|
||||
r4 = value4;
|
||||
} else if (useIsCallActiveModule.checkIsCallActive(a0.id)) {
|
||||
r9 = r8 ? a0 != null && VoiceStateStore.hasVideo(a0.id) ? intl.string(t.W68MhH) : null : intl.string(t.fdEeb5);
|
||||
r1 = getPrivateChannelCallC_61569;
|
||||
r3 = r9;
|
||||
r4 = value4;
|
||||
} else {
|
||||
string = intl.string;
|
||||
r3 = r8 ? Reflect.apply(string, intl, [t['7AWk50']]) : Reflect.apply(string, intl, [t['EZgS+9']]);
|
||||
string = intl.string;
|
||||
r4 = r8 ? Reflect.apply(string, intl, [t.oCqlGG]) : Reflect.apply(string, intl, [t.focH1t]);
|
||||
r1 = getPrivateChannelCallC_61570;
|
||||
}
|
||||
const object2 = {text: r3};
|
||||
r3 = r4 ?? r3;
|
||||
object2.accessibilityHint = r3;
|
||||
object2.inCall = isInChannel2;
|
||||
object2.onPress = r1;
|
||||
return object2;
|
||||
}
|
||||
|
||||
function getPrivateChannelCallC() { // fn#61568, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:7886:462, owner: getPrivateChannelCall.C, offset: 0x01b45940, size: 45 bytes, params: 1, frame: 11
|
||||
const value = environment.__proto__;
|
||||
return (require(9228) /* metro dependency 9228: CallsUtils */).handleDisconnect(env0_0);
|
||||
}
|
||||
|
||||
function getPrivateChannelCallC_61569() { // fn#61569, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:7886:611, owner: getPrivateChannelCall.C, offset: 0x01b4596d, size: 25 bytes, params: 1, frame: 13
|
||||
return env0_3(env0_0, env0_1);
|
||||
}
|
||||
|
||||
@@ -0,0 +1,92 @@
|
||||
/* Metro module 10493; source: modules/calls/native/usePrivateChannelCall.tsx; dependencies: [5, 31, 1379, 566, 1244, 7708, 4603, 2] */
|
||||
function _fun81182(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#81182, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:10679:6, offset: 0x01e9d445, size: 153 bytes, params: 8, frame: 19
|
||||
const env0_0 = require;
|
||||
const Object = global.Object;
|
||||
Object.defineProperty(exports, '__esModule', {value: true});
|
||||
const env0_3 = importDefault(5) /* metro dependency 5 */;
|
||||
const env0_4 = importAll(31) /* metro dependency 31 */;
|
||||
const channelStore = importDefault(1379) /* metro dependency 1379: ChannelStore */;
|
||||
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/calls/native/usePrivateChannelCall.tsx');
|
||||
exports.default = usePrivateChannelCall;
|
||||
}
|
||||
|
||||
function usePrivateChannelCall(a0, a1, a2) { // fn#81183, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:10679:216, offset: 0x01e9d4de, size: 179 bytes, params: 4, frame: 21
|
||||
var object2;
|
||||
const env0_0 = a0;
|
||||
const env0_1 = a1;
|
||||
const env0_2 = a2;
|
||||
const value2 = (require(566) /* metro dependency 566: flux */).useStateFromStoresObject([ChannelStore], _fun81184,
|
||||
[a1, a0]);
|
||||
const text = value2.text;
|
||||
const accessibilityHint = value2.accessibilityHint;
|
||||
object2 = {text: text};
|
||||
object2.inCall = value2.inCall;
|
||||
object2.accessibilityHint = accessibilityHint;
|
||||
object2.handlePress = env0_4.useCallback(env0_3(_fun81186), [a0, a1, a2]);
|
||||
return object2;
|
||||
}
|
||||
|
||||
function _fun81184() { // fn#81184, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:10679:298, offset: 0x01e9d591, size: 290 bytes, params: 1, frame: 19
|
||||
const intl = (require(1244) /* metro dependency 1244: indexNative */).intl;
|
||||
const t = (require(1244) /* metro dependency 1244: indexNative */).t;
|
||||
let value = environment.__proto__;
|
||||
const getChannel = ChannelStore.getChannel;
|
||||
const getDMFromUserId = ChannelStore.getDMFromUserId;
|
||||
const value3 = Reflect.apply(getChannel, ChannelStore, [Reflect.apply(getDMFromUserId, ChannelStore, [env0_0])]);
|
||||
if (value3 != null) {
|
||||
if (value3.isPrivate()) {
|
||||
value = importDefault(7708) /* metro dependency 7708: getPrivateChannelCall */;
|
||||
value = value(value3, require);
|
||||
return {text: value.text, accessibilityHint: value.accessibilityHint, inCall: value.inCall};
|
||||
}
|
||||
}
|
||||
const object2 = {};
|
||||
let string = intl.string;
|
||||
object2.text = require ? Reflect.apply(string, intl, [t['7AWk50']]) : Reflect.apply(string, intl, [t['EZgS+9']]);
|
||||
string = intl.string;
|
||||
object2.accessibilityHint = require ? Reflect.apply(string, intl, [t.oCqlGG]) : Reflect.apply(string, intl,
|
||||
[t.focH1t]);
|
||||
object2.inCall = false;
|
||||
return object2;
|
||||
}
|
||||
|
||||
function* _fun81186() { // fn#81186, original name: ?anon_0_, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:10679:786, offset: 0x01e9d6be, size: 202 bytes, params: 1, frame: 17
|
||||
var r7;
|
||||
if (true) {
|
||||
value = environment.__proto__.__proto__;
|
||||
var binding = env2_5;
|
||||
var getChannel = binding.getChannel;
|
||||
var getDMFromUserId = binding.getDMFromUserId;
|
||||
var value4 = Reflect.apply(getChannel, binding, [Reflect.apply(getDMFromUserId, binding, [require])]);
|
||||
if (value4 != null) {
|
||||
r7 = value4;
|
||||
if (r7 != null && r7.isPrivate()) {
|
||||
value = env2_1(env2_2[5]);
|
||||
value = value(r7, importDefault);
|
||||
value.onPress();
|
||||
}
|
||||
if (dependencyMap != null) {
|
||||
dependencyMap();
|
||||
}
|
||||
} else {
|
||||
binding = env2_1;
|
||||
var value5 = binding(env2_2[6]);
|
||||
yield value5.ensurePrivateChannel(require);
|
||||
var value6 = undefined;
|
||||
if (false) {
|
||||
return value6;
|
||||
}
|
||||
binding = env2_5;
|
||||
r7 = binding.getChannel(value6);
|
||||
if (r7 != null && r7.isPrivate()) {
|
||||
value = env2_1(env2_2[5]);
|
||||
value = value(r7, importDefault);
|
||||
value.onPress();
|
||||
}
|
||||
if (dependencyMap != null) {
|
||||
dependencyMap();
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user