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,162 @@
|
||||
/* Metro module 9773; source: components_native/chat/ChatItem.tsx; dependencies: [57, 31, 27, 4502, 661, 8178, 33, 4020, 9774, 9775, 9776, 671, 5216, 4501, 697, 477, 8368, 3860, 674, 4589, 2] */
|
||||
function _fun76692(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#76692, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:9959:6, offset: 0x01de0e93, size: 503 bytes, params: 8, frame: 21
|
||||
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 */;
|
||||
let value = require(27) /* metro dependency 27 */;
|
||||
const requireNativeComponent = value.requireNativeComponent;
|
||||
const env0_5 = value.View;
|
||||
const accessibilityStore = importDefault(4502) /* metro dependency 4502: AccessibilityStore */;
|
||||
const env0_7 = (require(661) /* metro dependency 661: Constants */).MessageTypes;
|
||||
value = require(8178) /* metro dependency 8178: RowGeneratorConstants */;
|
||||
const env0_8 = value.RowType;
|
||||
const env0_9 = value.Changeset;
|
||||
value = require(33) /* metro dependency 33 */;
|
||||
const env0_10 = value.jsx;
|
||||
const env0_11 = value.jsxs;
|
||||
value = require(4020) /* metro dependency 4020: FabricUtils */;
|
||||
const r4 = value.isFabric() ? (require(9774) /* metro dependency 9774: MessageViewNativeComponent */).default : requireNativeComponent('DCDMessageView');
|
||||
value = require(4020) /* metro dependency 4020: FabricUtils */;
|
||||
const r3 = value.isFabric() ? (require(9775) /* metro dependency 9775: SystemMessageViewNativeComponent */).default : requireNativeComponent('DCDSystemMessageView');
|
||||
value = require(4020) /* metro dependency 4020: FabricUtils */;
|
||||
const r1 = value.isFabric() ? (require(9776) /* metro dependency 9776: AutoModerationSystemMessageViewNativeComponent */).default : requireNativeComponent('DCDAutoModerationSystemMessageView');
|
||||
const env0_15 = (require(4501) /* metro dependency 4501: createStyles */).createStyles(function(a0, a1) {
|
||||
return {container: {'position': 'relative', 'overflow': 'hidden'}, offset: {marginTop: -a1, marginLeft: -a0},
|
||||
gradient: {'position': 'absolute', 'bottom': 0, 'height': 24, 'width': '100%'},
|
||||
itemRow: {backgroundColor: 'transparent'}};
|
||||
});
|
||||
(require(2) /* metro dependency 2 */).fileFinishedImporting('components_native/chat/ChatItem.tsx');
|
||||
exports.default = _default_76695;
|
||||
exports.DCDMessageView = r4;
|
||||
exports.DCDSystemMessageView = r3;
|
||||
exports.DCDAutoModerationSystemMessageView = r1;
|
||||
}
|
||||
|
||||
function DCDChatItem(a0) { // fn#76693, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:9959:458, offset: 0x01de108a, size: 246 bytes, params: 2, frame: 18
|
||||
var r0;
|
||||
var AUTOMOD_INCIDENT_ACTIONS;
|
||||
const message = a0.message;
|
||||
const value = Object.create(null);
|
||||
value.message = 0;
|
||||
const value2 = copyDataProperties({}, a0, value, undefined);
|
||||
const type = message.type;
|
||||
const AUTO_MODERATION_ACTION = MessageTypes.AUTO_MODERATION_ACTION;
|
||||
if (type === AUTO_MODERATION_ACTION) {
|
||||
r0 = ((Component) => <Component {...value2} />)(env0_14);
|
||||
} else {
|
||||
AUTOMOD_INCIDENT_ACTIONS = (require(671) /* metro dependency 671: MessageTypes */).MessageTypesSets.AUTOMOD_INCIDENT_ACTIONS;
|
||||
r0 = AUTOMOD_INCIDENT_ACTIONS.has(message.type) ? ((Component) => <Component {...value2} />)(env0_12) : (importDefault(5216) /* metro dependency 5216: isSystemMessage */)(message) ? ((Component) => <Component {...value2} />)(env0_13) : ((Component) => <Component {...value2} />)(env0_12);
|
||||
}
|
||||
return r0;
|
||||
}
|
||||
|
||||
function _default_76695({rowGenerator, message, style, horizontalOffset, maxHeight, modifyRow, pointerEvents, onLayout, messageSizeCacheRef, backgroundColor = importDefault(dependencyMap[14]).colors.BACKGROUND_BASE_LOWER, gradientStyles}) { // fn#76695, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:9959:901, offset: 0x01de11d0, size: 745 bytes, params: 2, frame: 30
|
||||
horizontalOffset = horizontalOffset === undefined ? 8 : horizontalOffset;
|
||||
const env0_3 = onLayout;
|
||||
const env0_4 = messageSizeCacheRef;
|
||||
const binding = env0_4;
|
||||
let useState = binding.useState;
|
||||
const value5 = Reflect.apply(useState, binding, [0]);
|
||||
const binding2 = env0_3;
|
||||
const value6 = binding2(value5, 2);
|
||||
const property = value6[0];
|
||||
const env0_5 = value6[1];
|
||||
useState = binding.useState;
|
||||
const value7 = binding2(Reflect.apply(useState, binding, [undefined]), 2);
|
||||
const property2 = value7[0];
|
||||
const env0_7 = value7[1];
|
||||
const {row, rawRow} = binding.useMemo(_fun76696, [property2, AccessibilityStore.roleStyle, message, modifyRow,
|
||||
rowGenerator]);
|
||||
const value9 = binding.useMemo(_fun76697, [rawRow.contextType]);
|
||||
const styles = useStyles(horizontalOffset, value9);
|
||||
const value10 = binding.useCallback(_fun76698, [onLayout]);
|
||||
const value11 = binding.useCallback(_fun76699, [messageSizeCacheRef, message.id]);
|
||||
let r5 = maxHeight != null && property - value9 >= maxHeight;
|
||||
let r16 = messageSizeCacheRef == null || messageSizeCacheRef.current == null ? undefined : messageSizeCacheRef.current[message.id];
|
||||
r16 = r5 ? maxHeight : r16;
|
||||
const view = <View style={styles.offset} onLayout={value11}><DCDChatItem message={message} row={row} style={styles.itemRow} /></View>;
|
||||
const value16 = env0_4.useMemo(_fun76700,
|
||||
[(require(3860) /* metro dependency 3860: useToken */).useToken(backgroundColor)]);
|
||||
const items2 = [styles.container, style];
|
||||
items2[2] = {height: r16};
|
||||
const r7 = property2 != null && view;
|
||||
r5 = r5 && ((Component) => <Component colors={value16} style={[styles.gradient,
|
||||
gradientStyles]} />)(importDefault(4589) /* metro dependency 4589 */);
|
||||
return (
|
||||
<View
|
||||
style={items2}
|
||||
onLayout={value10}
|
||||
pointerEvents={pointerEvents}
|
||||
>
|
||||
{r7}
|
||||
{r5}
|
||||
</View>
|
||||
);
|
||||
}
|
||||
|
||||
function _fun76696() { // fn#76696, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:9959:1223, offset: 0x01de14b9, size: 221 bytes, params: 1, frame: 16
|
||||
var object4;
|
||||
var r1;
|
||||
var JSON;
|
||||
var stringify;
|
||||
var object3;
|
||||
const rowGeneratorBinding = rowGenerator;
|
||||
rowGeneratorBinding.setOptions({constrainedWidth: env0_6});
|
||||
const generate = rowGeneratorBinding.generate;
|
||||
const MESSAGE = RowType.MESSAGE;
|
||||
const NOOP = Changeset.NOOP;
|
||||
const value3 = Reflect.apply(generate, rowGeneratorBinding, [{roleStyle: roleStyle, rowType: MESSAGE,
|
||||
changeType: NOOP, message: message, isFirst: true, canShowImages: true, canAddNewReactions: false}]);
|
||||
if (modifyRow != null) {
|
||||
modifyRow(value3);
|
||||
}
|
||||
object4 = {rawRow: value3};
|
||||
const value = require(4020) /* metro dependency 4020: FabricUtils */;
|
||||
if (value.isFabric()) {
|
||||
JSON = global.JSON;
|
||||
stringify = JSON.stringify;
|
||||
object3 = {index: 0};
|
||||
copyDataProperties(object3, value3, 0);
|
||||
r1 = Reflect.apply(stringify, JSON, [object3]);
|
||||
} else {
|
||||
r1 = value3;
|
||||
}
|
||||
object4.row = r1;
|
||||
return object4;
|
||||
}
|
||||
|
||||
function _fun76697() { // fn#76697, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:9959:1526, offset: 0x01de1596, size: 97 bytes, params: 1, frame: 14
|
||||
const value = environment.__proto__;
|
||||
return (require(477) /* metro dependency 477: PlatformUtils */).isAndroid() ? 0 : rawRow.contextType !== (require(8368) /* metro dependency 8368: RowGeneratorTypes */).MessageContextType.SEARCH ? 16 : 12;
|
||||
}
|
||||
|
||||
function _fun76698(a0) { // fn#76698, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:9959:1654, offset: 0x01de15f7, size: 55 bytes, params: 2, frame: 13
|
||||
env0_7(a0.nativeEvent.layout.width);
|
||||
if (onLayout != null) {
|
||||
onLayout(a0);
|
||||
}
|
||||
}
|
||||
|
||||
function _fun76699({nativeEvent}) { // fn#76699, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:9959:1726, offset: 0x01de162e, size: 102 bytes, params: 2, frame: 12
|
||||
const height = nativeEvent.layout.height;
|
||||
if (height > 0) {
|
||||
if (messageSizeCacheRef != null) {
|
||||
if (messageSizeCacheRef.current[message.id] !== height) {
|
||||
messageSizeCacheRef.current[message.id] = height;
|
||||
}
|
||||
}
|
||||
env0_5(height);
|
||||
}
|
||||
}
|
||||
|
||||
function _fun76700() { // fn#76700, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:9959:2043, offset: 0x01de1694, size: 78 bytes, params: 1, frame: 12
|
||||
let value = environment.__proto__;
|
||||
value = importDefault(674) /* metro dependency 674 */;
|
||||
value = value(env0_10);
|
||||
value = value.alpha(0);
|
||||
value = value.hex();
|
||||
return [value, env0_10];
|
||||
}
|
||||
|
||||
@@ -0,0 +1,397 @@
|
||||
/* Metro module 11091; source: components_native/chat/ImageCarousel.tsx; dependencies: [31, 27, 4645, 4644, 11092, 33, 4501, 697, 4017, 4504, 1305, 4577, 44, 4650, 566, 11093, 11143, 11158, 8670, 4573, 1244, 9376, 8999, 5278, 8523, 1478, 7879, 11095, 2] */
|
||||
function _fun84913(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#84913, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:11277:6, offset: 0x01f5c00e, size: 1003 bytes, params: 8, frame: 29
|
||||
var object2;
|
||||
const env0_0 = require;
|
||||
const closure = useTileEntranceAnimatedStyle;
|
||||
const Object = global.Object;
|
||||
Object.defineProperty(exports, '__esModule', {value: true});
|
||||
let value = importAll(31) /* metro dependency 31 */;
|
||||
const value2 = require(27) /* metro dependency 27 */;
|
||||
const env0_4 = value2.View;
|
||||
const StyleSheet = value2.StyleSheet;
|
||||
const env0_5 = value2.ScrollView;
|
||||
const env0_6 = (require(4645) /* metro dependency 4645: DraftStore */).DraftType;
|
||||
const uploadAttachmentStore = importDefault(4644) /* metro dependency 4644: UploadAttachmentStore */;
|
||||
const imageCarouselConstantsModule = require(11092) /* metro dependency 11092: ImageCarouselConstants */;
|
||||
const IMAGE_CAROUSEL_EXPERIMENT_TILE_MARGIN = imageCarouselConstantsModule.IMAGE_CAROUSEL_EXPERIMENT_TILE_MARGIN;
|
||||
const IMAGE_CAROUSEL_TILE_CLOSE_BUTTON_PADDING = imageCarouselConstantsModule.IMAGE_CAROUSEL_TILE_CLOSE_BUTTON_PADDING;
|
||||
const env0_10 = imageCarouselConstantsModule.IMAGE_CAROUSEL_TILE_HEIGHT;
|
||||
const value4 = require(33) /* metro dependency 33 */;
|
||||
const env0_11 = value4.jsx;
|
||||
const env0_12 = value4.jsxs;
|
||||
const createStylesModule = require(4501) /* metro dependency 4501: createStyles */;
|
||||
const createStyles = createStylesModule.createStyles;
|
||||
object2 = {};
|
||||
object2.container = {width: '100%'};
|
||||
object2.pressableContainer = {marginHorizontal: 4};
|
||||
const object3 = {'position': 'relative', 'minWidth': 60, 'backgroundColor': null, 'overflow': 'hidden'};
|
||||
let BACKGROUND_SURFACE_HIGH = (importDefault(697) /* metro dependency 697: native */).colors.BACKGROUND_SURFACE_HIGH;
|
||||
object3.backgroundColor = BACKGROUND_SURFACE_HIGH;
|
||||
object3.borderRadius = (importDefault(697) /* metro dependency 697: native */).radii.md - 1;
|
||||
object2.tileContainer = object3;
|
||||
const object6 = {};
|
||||
copyDataProperties(object6, StyleSheet.absoluteFillObject, undefined);
|
||||
object6['flex'] = 1;
|
||||
object6['flexDirection'] = 'row';
|
||||
object6['justifyContent'] = 'space-between';
|
||||
object6['alignItems'] = 'flex-end';
|
||||
object6['padding'] = 4;
|
||||
object2.decorationsContainer = object6;
|
||||
const INTERACTIVE_TEXT_ACTIVE = (importDefault(697) /* metro dependency 697: native */).colors.INTERACTIVE_TEXT_ACTIVE;
|
||||
object2.highlightedTileContainer = {'borderColor': null, 'borderStyle': 'solid', 'borderWidth': 2,
|
||||
'borderRadius': 10, borderColor: INTERACTIVE_TEXT_ACTIVE};
|
||||
object2.closeButton = {'position': 'absolute', 'top': null, 'right': 2,
|
||||
top: -1 * IMAGE_CAROUSEL_EXPERIMENT_TILE_MARGIN};
|
||||
object2.scrollview = {paddingTop: IMAGE_CAROUSEL_TILE_CLOSE_BUTTON_PADDING};
|
||||
let BACKGROUND_SCRIM_LIGHTBOX = (importDefault(697) /* metro dependency 697: native */).colors.BACKGROUND_SCRIM_LIGHTBOX;
|
||||
object2.closeContainer = {'height': 20, 'width': 20, 'borderRadius': 20, 'alignItems': 'center',
|
||||
'justifyContent': 'center', backgroundColor: BACKGROUND_SCRIM_LIGHTBOX};
|
||||
const object7 = {};
|
||||
object7.borderRadius = (importDefault(697) /* metro dependency 697: native */).radii.lg;
|
||||
const BACKGROUND_BASE_LOWER = (importDefault(697) /* metro dependency 697: native */).colors.BACKGROUND_BASE_LOWER;
|
||||
object7.backgroundColor = BACKGROUND_BASE_LOWER;
|
||||
const INTERACTIVE_TEXT_DEFAULT = (importDefault(697) /* metro dependency 697: native */).colors.INTERACTIVE_TEXT_DEFAULT;
|
||||
object7.tintColor = INTERACTIVE_TEXT_DEFAULT;
|
||||
object2.closeButtonIcon = object7;
|
||||
const object8 = {};
|
||||
let PX_4 = (importDefault(697) /* metro dependency 697: native */).space.PX_4;
|
||||
object8.paddingHorizontal = PX_4;
|
||||
object8.lineHeight = 20;
|
||||
BACKGROUND_SCRIM_LIGHTBOX = (importDefault(697) /* metro dependency 697: native */).colors.BACKGROUND_SCRIM_LIGHTBOX;
|
||||
object8.backgroundColor = BACKGROUND_SCRIM_LIGHTBOX;
|
||||
object8.borderRadius = (importDefault(697) /* metro dependency 697: native */).radii.xs;
|
||||
object8.textTransform = 'uppercase';
|
||||
object2.altTagText = object8;
|
||||
const object9 = {};
|
||||
BACKGROUND_SCRIM_LIGHTBOX = (importDefault(697) /* metro dependency 697: native */).colors.BACKGROUND_SCRIM_LIGHTBOX;
|
||||
object9.backgroundColor = BACKGROUND_SCRIM_LIGHTBOX;
|
||||
object9.borderRadius = (importDefault(697) /* metro dependency 697: native */).radii.sm;
|
||||
PX_4 = (importDefault(697) /* metro dependency 697: native */).space.PX_4;
|
||||
object9.padding = PX_4;
|
||||
object2.iconContainer = object9;
|
||||
const object14 = {};
|
||||
copyDataProperties(object14, StyleSheet.absoluteFillObject, undefined);
|
||||
object2.spoilerOverlay = object14;
|
||||
BACKGROUND_SURFACE_HIGH = (importDefault(697) /* metro dependency 697: native */).colors.BACKGROUND_SURFACE_HIGH;
|
||||
object2.footerRightContainer = {'position': 'absolute', 'bottom': 4, 'right': 4, 'alignItems': 'center',
|
||||
'justifyContent': 'center', 'alignContent': 'center', 'backgroundColor': null, 'padding': 4, 'borderRadius': 20,
|
||||
'opacity': 0.85, backgroundColor: BACKGROUND_SURFACE_HIGH};
|
||||
const env0_13 = Reflect.apply(createStyles, createStylesModule, [object2]);
|
||||
object2 = {code: "function ImageCarouselTsx1(){const{withTiming,animatedStylePropValue,STANDARD_EASING,withSpring}=this.__closure;return{opacity:withTiming(animatedStylePropValue.get(),{duration:300,easing:STANDARD_EASING},'animate-always'),transform:[{scale:withSpring(animatedStylePropValue.get(),{stiffness:80,damping:6,mass:0.3},'animate-always')}]};}"};
|
||||
value = value.memo(_fun84928);
|
||||
(require(2) /* metro dependency 2 */).fileFinishedImporting('components_native/chat/ImageCarousel.tsx');
|
||||
exports.default = value;
|
||||
exports.useTileEntranceAnimatedStyle = closure;
|
||||
}
|
||||
|
||||
function useTileEntranceAnimatedStyle(a0) { // fn#84914, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:11277:2146, offset: 0x01f5c3f9, size: 216 bytes, params: 2, frame: 20
|
||||
var object2;
|
||||
const value2 = (require(4017) /* metro dependency 4017: ReanimatedRexport */).useSharedValue(0);
|
||||
env0_3.useEffect(_fun84915, [value2, a0]);
|
||||
const reanimatedRexportModule = require(4017) /* metro dependency 4017: ReanimatedRexport */;
|
||||
const useAnimatedStyle = reanimatedRexportModule.useAnimatedStyle;
|
||||
const closure = useTileEntranceAnimatedStyleL;
|
||||
object2 = {};
|
||||
object2.withTiming = (require(4504) /* metro dependency 4504: timing */).withTiming;
|
||||
object2.animatedStylePropValue = value2;
|
||||
const STANDARD_EASING = (require(1305) /* metro dependency 1305: native */).STANDARD_EASING;
|
||||
object2.STANDARD_EASING = STANDARD_EASING;
|
||||
object2.withSpring = (require(4577) /* metro dependency 4577: spring */).withSpring;
|
||||
closure.__closure = object2;
|
||||
closure.__workletHash = 9754366991991;
|
||||
closure.__initData = env0_14;
|
||||
return Reflect.apply(useAnimatedStyle, reanimatedRexportModule, [closure]);
|
||||
}
|
||||
|
||||
function Tile({onEdit, onRemove, channelId, highlightThumbnails, upload}) { // fn#84917, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:11277:2701, offset: 0x01f5c579, size: 1259 bytes, params: 2, frame: 40
|
||||
var object4;
|
||||
highlightThumbnails = !(highlightThumbnails === undefined) && highlightThumbnails;
|
||||
const env0_3 = upload;
|
||||
const styles = useStyles();
|
||||
const description = upload.description;
|
||||
const id = upload.id;
|
||||
const item = upload.item;
|
||||
const isVideo = upload.isVideo;
|
||||
const isImage = upload.isImage;
|
||||
const isThumbnail = upload.isThumbnail;
|
||||
const defaultImport = importDefault(44) /* metro dependency 44 */;
|
||||
const platform = item.platform;
|
||||
const UploadPlatform = (require(4650) /* metro dependency 4650: Upload */).UploadPlatform;
|
||||
const REACT_NATIVE = UploadPlatform.REACT_NATIVE;
|
||||
defaultImport(platform === REACT_NATIVE, 'Upload must be a React Native upload item.');
|
||||
let r15 = highlightThumbnails && isThumbnail === true;
|
||||
const value3 = (require(566) /* metro dependency 566: flux */).useStateFromStores([UploadAttachmentStore],
|
||||
_fun84918);
|
||||
let binding = env0_3;
|
||||
let useCallback = binding.useCallback;
|
||||
const value4 = Reflect.apply(useCallback, binding, [_fun84919, [isVideo, isImage, r15]]);
|
||||
const value5 = env0_3.useCallback(_fun84920, [onRemove, id]);
|
||||
const value6 = env0_3.useCallback(_fun84921, [channelId, onRemove, onEdit, upload, id]);
|
||||
const value7 = env0_3.useCallback(_fun84923, [value5]);
|
||||
const value8 = useTileEntranceAnimatedStyle(item.id ?? item.uri);
|
||||
binding = env0_3;
|
||||
useCallback = binding.useCallback;
|
||||
let filename = item.filename;
|
||||
const value9 = Reflect.apply(useCallback, binding, [_fun84924, [value4, value8, description, item.uri, filename,
|
||||
isImage, isThumbnail, isVideo, value3, styles]]);
|
||||
object4 = {name: 'remove'};
|
||||
const intl = (require(1244) /* metro dependency 1244: indexNative */).intl;
|
||||
let string = intl.string;
|
||||
object4.label = Reflect.apply(string, intl, [(require(1244) /* metro dependency 1244: indexNative */).t.kFwAsa]);
|
||||
const items2 = [object4];
|
||||
const PressableOpacity = (require(5278) /* metro dependency 5278: Pressables */).PressableOpacity;
|
||||
let formatToPlainString = intl.formatToPlainString;
|
||||
const MJHFt9 = (require(1244) /* metro dependency 1244: indexNative */).t.MJHFt9;
|
||||
filename = item.filename;
|
||||
const value10 = '';
|
||||
string = intl.string;
|
||||
const QtJ1c5 = (require(1244) /* metro dependency 1244: indexNative */).t.QtJ1c5;
|
||||
r15 = r15 && styles.highlightedTileContainer;
|
||||
const pressableOpacity = <PressableOpacity accessibilityRole="button" accessibilityLabel={Reflect.apply(formatToPlainString,
|
||||
intl, [MJHFt9, {name: filename ?? value10}])} accessibilityHint={Reflect.apply(string, intl,
|
||||
[QtJ1c5])} accessibilityActions={items2} onAccessibilityAction={value7} disabled={!isImage && !isVideo} onPress={value6} style={[styles.pressableContainer,
|
||||
r15]}>{value9()}</PressableOpacity>;
|
||||
formatToPlainString = intl.formatToPlainString;
|
||||
const FxKgb3 = (require(1244) /* metro dependency 1244: indexNative */).t.FxKgb3;
|
||||
const object2 = {};
|
||||
object2.name = item.filename ?? value10;
|
||||
const View2 = (importDefault(4017) /* metro dependency 4017: ReanimatedRexport */).View;
|
||||
const items4 = [styles.closeContainer, value8];
|
||||
const Icon = (require(1305) /* metro dependency 1305: native */).Icon;
|
||||
const object3 = {source: importDefault(8523) /* metro dependency 8523 */};
|
||||
const Icon2 = (require(1305) /* metro dependency 1305: native */).Icon;
|
||||
const Sizes = Icon2.Sizes;
|
||||
const MEDIUM = Sizes.MEDIUM;
|
||||
object3.size = MEDIUM;
|
||||
const PRIMARY_500 = (importDefault(697) /* metro dependency 697: native */).unsafe_rawColors.PRIMARY_500;
|
||||
object3.color = PRIMARY_500;
|
||||
object3.style = styles.closeButtonIcon;
|
||||
return (
|
||||
<View>
|
||||
{pressableOpacity}
|
||||
<PressableOpacity
|
||||
accessibilityRole="button"
|
||||
accessibilityLabel={Reflect.apply(formatToPlainString, intl, [FxKgb3, object2])}
|
||||
style={styles.closeButton}
|
||||
onPress={value5}
|
||||
hitSlop={{'top': 4, 'bottom': 4, 'left': 4, 'right': 4}}
|
||||
>
|
||||
<View2 style={items4}>
|
||||
<Icon {...object3} />
|
||||
</View2>
|
||||
</PressableOpacity>
|
||||
</View>
|
||||
);
|
||||
}
|
||||
|
||||
function CustomScrollView(a0) { // fn#84925, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:11277:5336, offset: 0x01f5cf0b, size: 207 bytes, params: 2, frame: 18
|
||||
const styles = useStyles();
|
||||
const env0_0 = env0_3.useRef(0);
|
||||
const env0_1 = env0_3.useRef(0);
|
||||
return (
|
||||
<ScrollView
|
||||
{...a0}
|
||||
{...{['ref']: env0_3.useRef(null)}}
|
||||
{...{['onContentSizeChange']: env0_3.useCallback(_fun84926, [])}}
|
||||
{...{['onScroll']: env0_3.useCallback(_fun84927, [])}}
|
||||
{...{['scrollEventThrottle']: 16}}
|
||||
{...{['contentContainerStyle']: styles.scrollview}}
|
||||
/>
|
||||
);
|
||||
}
|
||||
|
||||
function _fun84928({attachments, channelId, headerElement, highlightThumbnails}) { // fn#84928, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:11277:5774, offset: 0x01f5d079, size: 428 bytes, params: 2, frame: 25
|
||||
var r8;
|
||||
if (highlightThumbnails !== undefined) {
|
||||
}
|
||||
let env0_3 = undefined;
|
||||
var value;
|
||||
const styles = useStyles();
|
||||
let r11 = attachments != null && attachments.length > 0;
|
||||
r11 = !r11 ? headerElement != null : r11;
|
||||
env0_3 = env0_3.useCallback(_fun84930, [channelId, env0_3.useCallback(function(a0) {
|
||||
importDefault(dependencyMap[26]).remove(channelId, a0, DraftType.ChannelMessage);
|
||||
}, [channelId])]);
|
||||
const items2 = [styles.container];
|
||||
items2[1] = {height: r11 ? IMAGE_CAROUSEL_TILE_HEIGHT + IMAGE_CAROUSEL_TILE_CLOSE_BUTTON_PADDING : 0,
|
||||
marginTop: r11 ? -1 * (IMAGE_CAROUSEL_TILE_CLOSE_BUTTON_PADDING - IMAGE_CAROUSEL_EXPERIMENT_TILE_MARGIN) : 0,
|
||||
marginBottom: r11 ? 2 * IMAGE_CAROUSEL_EXPERIMENT_TILE_MARGIN : 0};
|
||||
const intl = (require(1244) /* metro dependency 1244: indexNative */).intl;
|
||||
const string = intl.string;
|
||||
const RhtzFe = (require(1244) /* metro dependency 1244: indexNative */).t.RhtzFe;
|
||||
if (attachments != null) {
|
||||
value = global.Object.values(attachments);
|
||||
value = value.map(_fun84931);
|
||||
r8 = value;
|
||||
} else {
|
||||
r8 = null;
|
||||
}
|
||||
return (
|
||||
<View style={items2}>
|
||||
<CustomScrollView
|
||||
horizontal
|
||||
keyboardShouldPersistTaps="always"
|
||||
showsHorizontalScrollIndicator={false}
|
||||
accessibilityRole="list"
|
||||
accessibilityLabel={Reflect.apply(string, intl, [RhtzFe])}
|
||||
>
|
||||
{headerElement}
|
||||
{r8}
|
||||
</CustomScrollView>
|
||||
</View>
|
||||
);
|
||||
}
|
||||
|
||||
function useTileEntranceAnimatedStyleL() { // fn#84916, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:11277:2293, owner: useTileEntranceAnimatedStyle.l, offset: 0x01f5c4d1, size: 168 bytes, params: 1, frame: 20
|
||||
const object2 = {};
|
||||
let value = environment.__proto__;
|
||||
value = require(4504) /* metro dependency 4504: timing */;
|
||||
const withTiming = value.withTiming;
|
||||
const binding = env0_0;
|
||||
const value3 = binding.get();
|
||||
const STANDARD_EASING = (require(1305) /* metro dependency 1305: native */).STANDARD_EASING;
|
||||
object2.opacity = Reflect.apply(withTiming, value, [value3, {duration: 300, easing: STANDARD_EASING},
|
||||
'animate-always']);
|
||||
const object4 = {};
|
||||
value = require(4577) /* metro dependency 4577: spring */;
|
||||
object4.scale = value.withSpring(binding.get(), {'stiffness': 80, 'damping': 6, 'mass': 0.3}, 'animate-always');
|
||||
object2.transform = [object4];
|
||||
return object2;
|
||||
}
|
||||
|
||||
function _fun84918() { // fn#84918, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:11277:3028, offset: 0x01f5ca64, size: 70 bytes, params: 1, frame: 15
|
||||
const value = environment.__proto__;
|
||||
const getUpload = UploadAttachmentStore.getUpload;
|
||||
const channelIdBinding = channelId;
|
||||
const idBinding = id;
|
||||
const ChannelMessage = DraftType.ChannelMessage;
|
||||
const spoiler = Reflect.apply(getUpload, UploadAttachmentStore, [channelIdBinding, idBinding,
|
||||
ChannelMessage])?.spoiler;
|
||||
return spoiler != null && spoiler;
|
||||
}
|
||||
|
||||
function _fun84919() { // fn#84919, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:11277:3140, offset: 0x01f5caaa, size: 65 bytes, params: 1, frame: 5
|
||||
var r1;
|
||||
var IMAGE_CAROUSEL_TILE_HEIGHT2;
|
||||
let value = environment.__proto__;
|
||||
const r2 = env0_11 ? IMAGE_CAROUSEL_TILE_HEIGHT - 4 : IMAGE_CAROUSEL_TILE_HEIGHT;
|
||||
const r4 = isVideo || isImage;
|
||||
value = undefined;
|
||||
if (r4) {
|
||||
r1 = value;
|
||||
IMAGE_CAROUSEL_TILE_HEIGHT2 = IMAGE_CAROUSEL_TILE_HEIGHT;
|
||||
} else {
|
||||
r1 = 192;
|
||||
IMAGE_CAROUSEL_TILE_HEIGHT2 = value;
|
||||
}
|
||||
return {width: IMAGE_CAROUSEL_TILE_HEIGHT2, height: r2, maxWidth: r1};
|
||||
}
|
||||
|
||||
function _fun84920() { // fn#84920, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:11277:3264, offset: 0x01f5caeb, size: 35 bytes, params: 1, frame: 12
|
||||
return onRemove?.(id);
|
||||
}
|
||||
|
||||
function _fun84921() { // fn#84921, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:11277:3313, offset: 0x01f5cb0e, size: 77 bytes, params: 1, frame: 13
|
||||
var environment;
|
||||
const value = environment.__proto__;
|
||||
(importDefault(11093) /* metro dependency 11093: showUploadPreviewActionSheet */)({channelId: channelId,
|
||||
onRemove: onRemove, onEdit: onEdit_84922, upload: upload});
|
||||
}
|
||||
|
||||
function _fun84923({nativeEvent}) { // fn#84923, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:11277:3426, offset: 0x01f5cb82, size: 40 bytes, params: 2, frame: 9
|
||||
if (nativeEvent.actionName === 'remove') {
|
||||
env0_14();
|
||||
}
|
||||
}
|
||||
|
||||
function _fun84924() { // fn#84924, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:11277:3552, offset: 0x01f5cbaa, size: 865 bytes, params: 1, frame: 33
|
||||
var r16;
|
||||
var Text;
|
||||
var intl;
|
||||
const value2 = undefined;
|
||||
const {width, height, maxWidth} = env0_13();
|
||||
const View2 = (importDefault(4017) /* metro dependency 4017: ReanimatedRexport */).View;
|
||||
const items2 = [styles.tileContainer];
|
||||
items2[1] = {width: width, height: height};
|
||||
items2[2] = env0_15;
|
||||
const value5 = ((Component) => <Component uri={item.uri} isImage={isImage} isVideo={isVideo} width={width} height={height} maxFileWidth={maxWidth} fileName={item.filename} borderRadius={(importDefault(697) /* metro dependency 697: native */).radii.md} />)(importDefault(11143) /* metro dependency 11143: AttachmentPreview */);
|
||||
const isThumbnailBinding = isThumbnail;
|
||||
const value6 = null;
|
||||
const r5 = isThumbnailBinding ? <View style={styles.footerRightContainer}>{((Icon) => <Icon source={importDefault(11158) /* metro dependency 11158 */} size={(require(1305) /* metro dependency 1305: native */).Icon.Sizes.SMALL_14} />)((require(1305) /* metro dependency 1305: native */).Icon)}</View> : value6;
|
||||
const items3 = [env0_12 ? ((Component) => <Component style={styles.spoilerOverlay} />)(importDefault(8670) /* metro dependency 8670: VisualEffectViewThemed */) : value6];
|
||||
if (value6 != description) {
|
||||
if ((value6 == description ? value2 : description.length) > 0) {
|
||||
Text = (require(4573) /* metro dependency 4573: Text */).Text;
|
||||
var textProps = {'variant': 'text-xs/medium', 'color': 'white', 'allowFontScaling': false,
|
||||
style: styles.altTagText};
|
||||
intl = (require(1244) /* metro dependency 1244: indexNative */).intl;
|
||||
r16 = <Text {...textProps}>{intl.string((require(1244) /* metro dependency 1244: indexNative */).t.QEW81z)}</Text>;
|
||||
} else {
|
||||
r16 = value6;
|
||||
}
|
||||
} else {
|
||||
r16 = value6;
|
||||
}
|
||||
const items4 = [r16];
|
||||
items4[1] = isVideo ? <View style={styles.iconContainer}>{((PlayIcon) => <PlayIcon size="xxs" color="white" />)((require(9376) /* metro dependency 9376: PlayIcon */).PlayIcon)}</View> : value6;
|
||||
items3[1] = <View>{items4}</View>;
|
||||
items3[2] = env0_12 ? <View style={styles.iconContainer}>{((EyeIcon) => <EyeIcon size="xxs" color="white" />)((require(8999) /* metro dependency 8999: EyeIcon */).EyeIcon)}</View> : value6;
|
||||
return (
|
||||
<View2 style={items2}>
|
||||
{value5}
|
||||
{r5}
|
||||
<View style={styles.decorationsContainer}>
|
||||
{items3}
|
||||
</View>
|
||||
</View2>
|
||||
);
|
||||
}
|
||||
|
||||
function _fun84926(a0) { // fn#84926, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:11277:5437, offset: 0x01f5cfda, size: 122 bytes, params: 2, frame: 15
|
||||
let current = env0_0.current;
|
||||
const current2 = env0_1.current;
|
||||
const useWindowDimensionsNativeModule = require(1478) /* metro dependency 1478: useWindowDimensionsNative */;
|
||||
const getWindowDimensions = useWindowDimensionsNativeModule.getWindowDimensions;
|
||||
if (a0 > current || current2 + Reflect.apply(getWindowDimensions, useWindowDimensionsNativeModule, []).width > a0) {
|
||||
current = env0_2.current;
|
||||
if (current != null) {
|
||||
current.scrollToEnd();
|
||||
}
|
||||
}
|
||||
env0_0.current = a0;
|
||||
}
|
||||
|
||||
function _fun84927({nativeEvent}) { // fn#84927, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:11277:5594, offset: 0x01f5d054, size: 37 bytes, params: 2, frame: 2
|
||||
env0_1.current = nativeEvent.contentOffset.x;
|
||||
}
|
||||
|
||||
function _fun84930(a0, a1) { // fn#84930, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:11277:5977, offset: 0x01f5d261, size: 106 bytes, params: 3, frame: 18
|
||||
if (env0_2 != null) {
|
||||
env0_2(a0);
|
||||
}
|
||||
const mediaKeyboardUtilsModule = require(11095) /* metro dependency 11095: MediaKeyboardUtils */;
|
||||
const addImagesFromPicker = mediaKeyboardUtilsModule.addImagesFromPicker;
|
||||
const channelIdBinding = channelId;
|
||||
const UploadOrigin = (require(4650) /* metro dependency 4650: Upload */).UploadOrigin;
|
||||
const IMAGE_EDITOR = UploadOrigin.IMAGE_EDITOR;
|
||||
Reflect.apply(addImagesFromPicker, mediaKeyboardUtilsModule, [channelIdBinding, [a1], IMAGE_EDITOR]);
|
||||
}
|
||||
|
||||
function _fun84931(a0) { // fn#84931, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:11277:6410, offset: 0x01f5d2cb, size: 76 bytes, params: 2, frame: 16
|
||||
return (
|
||||
<Tile
|
||||
channelId={channelId}
|
||||
highlightThumbnails={highlightThumbnails}
|
||||
onEdit={env0_3}
|
||||
onRemove={env0_2}
|
||||
upload={a0}
|
||||
key={a0.uniqueId}
|
||||
/>
|
||||
);
|
||||
}
|
||||
|
||||
function onEdit_84922(a0) { // fn#84922, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:11277:3358, offset: 0x01f5cb5b, size: 39 bytes, params: 2, frame: 14
|
||||
const value = environment.__proto__;
|
||||
return onEdit?.(id, a0);
|
||||
}
|
||||
|
||||
@@ -0,0 +1,72 @@
|
||||
/* Metro module 11790; source: components_native/chat/JumpToPresentButton.tsx; dependencies: [31, 27, 7729, 4257, 4814, 33, 4501, 697, 477, 566, 7713, 8341, 1244, 11791, 11792, 2] */
|
||||
function _fun90300(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#90300, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:11976:6, offset: 0x02033c5c, size: 364 bytes, params: 8, frame: 21
|
||||
const env0_0 = require;
|
||||
const Object = global.Object;
|
||||
Object.defineProperty(exports, '__esModule', {value: true});
|
||||
importAll(31) /* metro dependency 31 */;
|
||||
const env0_3 = (require(27) /* metro dependency 27 */).View;
|
||||
const useChatBottomManagerUIStore = importDefault(7729) /* metro dependency 7729: useChatBottomManagerUIStore */;
|
||||
const env0_5 = (require(7729) /* metro dependency 7729: useChatBottomManagerUIStore */).useChatInputContainerHeight;
|
||||
const gatewayConnectionStore = importDefault(4257) /* metro dependency 4257: GatewayConnectionStore */;
|
||||
const messageStore = importDefault(4814) /* metro dependency 4814: MessageStore */;
|
||||
const env0_8 = (require(33) /* metro dependency 33 */).jsx;
|
||||
let value = require(4501) /* metro dependency 4501: createStyles */;
|
||||
const createStyles = value.createStyles;
|
||||
const object = {'borderRadius': null, 'position': 'absolute', 'right': 12};
|
||||
object.borderRadius = (importDefault(697) /* metro dependency 697: native */).radii.round;
|
||||
const env0_9 = Reflect.apply(createStyles, value, [{container: object, containerIOS: {'bottom': '100%',
|
||||
'marginBottom': 12, 'pointerEvents': 'box-none'}}]);
|
||||
value = require(477) /* metro dependency 477: PlatformUtils */;
|
||||
const env0_10 = value.isIOS() ? function() {
|
||||
return null;
|
||||
} : _fun90302;
|
||||
(require(2) /* metro dependency 2 */).fileFinishedImporting('components_native/chat/JumpToPresentButton.tsx');
|
||||
exports.default = JumpToPresentButton;
|
||||
}
|
||||
|
||||
function _fun90302(a0) { // fn#90302, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:11976:398, offset: 0x02033dc8, size: 32 bytes, params: 2, frame: 12
|
||||
const object2 = {};
|
||||
object2.bottom = useChatInputContainerHeight(a0) + 12;
|
||||
return object2;
|
||||
}
|
||||
|
||||
function JumpToPresentButton({channelId, screenIndex, onJumpToPresent}) { // fn#90303, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:11976:511, offset: 0x02033de8, size: 469 bytes, params: 2, frame: 26
|
||||
const IconButton = (require(8341) /* metro dependency 8341: IconButtonNative */).IconButton;
|
||||
const intl = (require(1244) /* metro dependency 1244: indexNative */).intl;
|
||||
const t = (require(1244) /* metro dependency 1244: indexNative */).t;
|
||||
const styles = useStyles();
|
||||
const value2 = env0_10(screenIndex);
|
||||
const env0_2 = (require(566) /* metro dependency 566: flux */).useStateFromStores([GatewayConnectionStore],
|
||||
function() {
|
||||
return GatewayConnectionStore.isConnected();
|
||||
}, []);
|
||||
const value3 = useChatBottomManagerUIStore(_fun90305);
|
||||
const value4 = (require(7713) /* metro dependency 7713: VoicePanelUtilsNative */).useIsVoicePanelMounted(channelId);
|
||||
const value5 = (require(7713) /* metro dependency 7713: VoicePanelUtilsNative */).useIsVoicePanelOpen(channelId);
|
||||
const value6 = (require(566) /* metro dependency 566: flux */).useStateFromStores([MessageStore], function() {
|
||||
return MessageStore.getMessages(channelId).jumpReturnTargetId != null;
|
||||
});
|
||||
if (value3) {
|
||||
return (
|
||||
<View style={[styles.container, value2 ?? styles.containerIOS]}>
|
||||
{value3 ? <IconButton accessibilityLabel={value6 ? intl.string(t.dpjpOp) : intl.string(t.gpoQsB)} onPress={onJumpToPresent} icon={importDefault(11791) /* metro dependency 11791 */} variant="primary-overlay" /> : ((MemoedVoicePanelDismissChatButton) => <MemoedVoicePanelDismissChatButton />)((require(11792) /* metro dependency 11792: VoicePanelChatView */).MemoedVoicePanelDismissChatButton)}
|
||||
</View>
|
||||
);
|
||||
}
|
||||
if (value4) {
|
||||
if (value5) {
|
||||
return (
|
||||
<View style={[styles.container, value2 ?? styles.containerIOS]}>
|
||||
{value3 ? <IconButton accessibilityLabel={value6 ? intl.string(t.dpjpOp) : intl.string(t.gpoQsB)} onPress={onJumpToPresent} icon={importDefault(11791) /* metro dependency 11791 */} variant="primary-overlay" /> : ((MemoedVoicePanelDismissChatButton) => <MemoedVoicePanelDismissChatButton />)((require(11792) /* metro dependency 11792: VoicePanelChatView */).MemoedVoicePanelDismissChatButton)}
|
||||
</View>
|
||||
);
|
||||
}
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
||||
function _fun90305(a0) { // fn#90305, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:11976:668, offset: 0x02033fd0, size: 78 bytes, params: 2, frame: 14
|
||||
const binding = env0_2;
|
||||
return binding ? !a0.showingAutoComplete.get(screenIndex) && a0.showJumpToPresentButtonChannelId.get(screenIndex) === channelId : !!binding;
|
||||
}
|
||||
|
||||
@@ -0,0 +1,252 @@
|
||||
/* Metro module 11380; source: components_native/chat/contentHandlers.tsx; dependencies: [5, 9862, 9598, 8877, 3853, 9834, 8743, 6789, 4080, 11381, 1962, 21, 3829, 1244, 6797, 3856, 4647, 8623, 2] */
|
||||
function _fun87229(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#87229, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:11566:6, offset: 0x01fb48bd, size: 225 bytes, params: 8, frame: 19
|
||||
var object2;
|
||||
const env0_0 = require;
|
||||
const Object = global.Object;
|
||||
Object.defineProperty(exports, '__esModule', {value: true});
|
||||
const value = importDefault(5) /* metro dependency 5 */;
|
||||
object2 = {onLongPressLink: onLongPressLink};
|
||||
const env0_4 = value(_fun87232);
|
||||
object2.onTapAttachmentLink = onTapAttachmentLink;
|
||||
const env0_3 = value(_fun87235);
|
||||
object2.onLongPressAttachmentLink = onLongPressAttachmentLink;
|
||||
object2.onTapMention = onTapMention;
|
||||
object2.onTapTimestamp = onTapTimestamp;
|
||||
object2.onTapInlineCode = onTapInlineCode;
|
||||
object2.onTapEmoji = onTapEmoji;
|
||||
(require(2) /* metro dependency 2 */).fileFinishedImporting('components_native/chat/contentHandlers.tsx');
|
||||
exports.contentHandlers = object2;
|
||||
}
|
||||
|
||||
function onLongPressLink({nativeEvent}) { // fn#87230, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:11566:129, offset: 0x01fb499e, size: 75 bytes, params: 2, frame: 12
|
||||
const url = nativeEvent.url;
|
||||
if (url != null && url !== '') {
|
||||
(importDefault(9862) /* metro dependency 9862: showLongPressURLActionSheet */)({urlString: url});
|
||||
}
|
||||
}
|
||||
|
||||
async function _fun87232({nativeEvent}) { // fn#87232, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:11566:222, offset: 0x01fb49fd, size: 166 bytes, params: 2, frame: 16
|
||||
if (true) {
|
||||
var attachmentUrl = nativeEvent.data.attachmentUrl;
|
||||
await undefined;
|
||||
if (false) {
|
||||
return undefined;
|
||||
}
|
||||
if (attachmentUrl != null) {
|
||||
if (attachmentUrl === '') {
|
||||
return undefined;
|
||||
}
|
||||
value = environment.__proto__;
|
||||
var binding = env1_0;
|
||||
var value4 = binding(env1_2[2]);
|
||||
await value4.maybeRefreshAttachmentUrl(attachmentUrl);
|
||||
var value5 = undefined;
|
||||
if (false) {
|
||||
return value5;
|
||||
}
|
||||
binding = env1_1;
|
||||
var binding2 = env1_2;
|
||||
value = binding(binding2[3]);
|
||||
value.trackLinkClicked(value5);
|
||||
value = binding(binding2[4]);
|
||||
value.openURL(value5);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
async function _fun87235({nativeEvent}) { // fn#87235, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:11566:468, offset: 0x01fb4ab7, size: 144 bytes, params: 2, frame: 16
|
||||
if (true) {
|
||||
var attachmentUrl = nativeEvent.data.attachmentUrl;
|
||||
await undefined;
|
||||
if (false) {
|
||||
return undefined;
|
||||
}
|
||||
if (attachmentUrl != null) {
|
||||
if (attachmentUrl === '') {
|
||||
return undefined;
|
||||
}
|
||||
value = environment.__proto__;
|
||||
var binding = env1_0;
|
||||
var value4 = binding(env1_2[2]);
|
||||
await value4.maybeRefreshAttachmentUrl(attachmentUrl);
|
||||
var value5 = undefined;
|
||||
if (false) {
|
||||
return value5;
|
||||
}
|
||||
binding = env1_1;
|
||||
value = binding(env1_2[1]);
|
||||
value({urlString: value5});
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
function onTapMention(a0) { // fn#87237, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:11566:671, offset: 0x01fb4b47, size: 720 bytes, params: 2, frame: 26
|
||||
var r8;
|
||||
const DeveloperMode = require(dependencyMap[12]).DeveloperMode;
|
||||
var object2;
|
||||
const intl = require(dependencyMap[13]).intl;
|
||||
const t = require(dependencyMap[13]).t;
|
||||
var defaultImport;
|
||||
var show;
|
||||
var defaultImport2;
|
||||
var openLazy;
|
||||
var defaultImport4;
|
||||
var value;
|
||||
const {userId, channelId, roleName, parsedUserId, roleId,
|
||||
guildId} = require(dependencyMap[5]).getNativeSyntheticEventData(a0);
|
||||
if (userId != null) {
|
||||
value = importDefault(dependencyMap[6]);
|
||||
object2 = {userId: userId, channelId: channelId};
|
||||
object2.sourceAnalyticsLocations = [importDefault(dependencyMap[7]).USER_MENTION];
|
||||
value(object2);
|
||||
} else if (roleId == null) {
|
||||
if (roleName !== '@everyone') {
|
||||
if (roleName === null) {
|
||||
if (DeveloperMode.getSetting()) {
|
||||
if (parsedUserId != null) {
|
||||
object2 = {};
|
||||
object2.secondaryConfirmText = intl.string(t['/AXYnE']);
|
||||
object2.onConfirmSecondary = onConfirmSecondary;
|
||||
r8 = object2;
|
||||
} else {
|
||||
r8 = {};
|
||||
}
|
||||
} else {
|
||||
r8 = {};
|
||||
}
|
||||
defaultImport = importDefault(dependencyMap[16]);
|
||||
show = defaultImport.show;
|
||||
object2 = {};
|
||||
object2.title = intl.string(t.r0DLNm);
|
||||
object2.body = intl.string(t.Fqqbhg);
|
||||
object2.confirmText = intl.string(t.BddRzS);
|
||||
copyDataProperties(object2, r8, undefined);
|
||||
Reflect.apply(show, defaultImport, [object2]);
|
||||
}
|
||||
} else if (guildId != null) {
|
||||
defaultImport2 = importDefault(dependencyMap[8]);
|
||||
openLazy = defaultImport2.openLazy;
|
||||
value = require(dependencyMap[10]);
|
||||
value = value(dependencyMap[9], dependencyMap.paths);
|
||||
object2 = {guildId: guildId};
|
||||
object2.roleId = importDefault(dependencyMap[11]).castGuildIdAsEveryoneGuildRoleId(guildId);
|
||||
object2.channelId = channelId;
|
||||
Reflect.apply(openLazy, defaultImport2, [value, 'RoleMembersActionSheet', object2]);
|
||||
} else if (roleName === null) {
|
||||
if (DeveloperMode.getSetting()) {
|
||||
if (parsedUserId != null) {
|
||||
object2 = {};
|
||||
object2.secondaryConfirmText = intl.string(t['/AXYnE']);
|
||||
object2.onConfirmSecondary = onConfirmSecondary;
|
||||
r8 = object2;
|
||||
} else {
|
||||
r8 = {};
|
||||
}
|
||||
} else {
|
||||
r8 = {};
|
||||
}
|
||||
defaultImport = importDefault(dependencyMap[16]);
|
||||
show = defaultImport.show;
|
||||
object2 = {};
|
||||
object2.title = intl.string(t.r0DLNm);
|
||||
object2.body = intl.string(t.Fqqbhg);
|
||||
object2.confirmText = intl.string(t.BddRzS);
|
||||
copyDataProperties(object2, r8, undefined);
|
||||
Reflect.apply(show, defaultImport, [object2]);
|
||||
}
|
||||
} else if (guildId != null) {
|
||||
defaultImport4 = importDefault(dependencyMap[8]);
|
||||
openLazy = defaultImport4.openLazy;
|
||||
value = require(dependencyMap[10]);
|
||||
value = value(dependencyMap[9], dependencyMap.paths);
|
||||
Reflect.apply(openLazy, defaultImport4, [value, 'RoleMembersActionSheet', {guildId: guildId, roleId: roleId,
|
||||
channelId: channelId}]);
|
||||
} else if (roleName !== '@everyone') {
|
||||
if (roleName === null) {
|
||||
if (DeveloperMode.getSetting()) {
|
||||
if (parsedUserId != null) {
|
||||
object2 = {};
|
||||
object2.secondaryConfirmText = intl.string(t['/AXYnE']);
|
||||
object2.onConfirmSecondary = onConfirmSecondary;
|
||||
r8 = object2;
|
||||
} else {
|
||||
r8 = {};
|
||||
}
|
||||
} else {
|
||||
r8 = {};
|
||||
}
|
||||
defaultImport = importDefault(dependencyMap[16]);
|
||||
show = defaultImport.show;
|
||||
object2 = {};
|
||||
object2.title = intl.string(t.r0DLNm);
|
||||
object2.body = intl.string(t.Fqqbhg);
|
||||
object2.confirmText = intl.string(t.BddRzS);
|
||||
copyDataProperties(object2, r8, undefined);
|
||||
Reflect.apply(show, defaultImport, [object2]);
|
||||
}
|
||||
} else if (guildId != null) {
|
||||
defaultImport2 = importDefault(dependencyMap[8]);
|
||||
openLazy = defaultImport2.openLazy;
|
||||
value = require(dependencyMap[10]);
|
||||
value = value(dependencyMap[9], dependencyMap.paths);
|
||||
object2 = {guildId: guildId};
|
||||
object2.roleId = importDefault(dependencyMap[11]).castGuildIdAsEveryoneGuildRoleId(guildId);
|
||||
object2.channelId = channelId;
|
||||
Reflect.apply(openLazy, defaultImport2, [value, 'RoleMembersActionSheet', object2]);
|
||||
} else if (roleName === null) {
|
||||
if (DeveloperMode.getSetting()) {
|
||||
if (parsedUserId != null) {
|
||||
object2 = {};
|
||||
object2.secondaryConfirmText = intl.string(t['/AXYnE']);
|
||||
object2.onConfirmSecondary = onConfirmSecondary;
|
||||
r8 = object2;
|
||||
} else {
|
||||
r8 = {};
|
||||
}
|
||||
} else {
|
||||
r8 = {};
|
||||
}
|
||||
defaultImport = importDefault(dependencyMap[16]);
|
||||
show = defaultImport.show;
|
||||
object2 = {};
|
||||
object2.title = intl.string(t.r0DLNm);
|
||||
object2.body = intl.string(t.Fqqbhg);
|
||||
object2.confirmText = intl.string(t.BddRzS);
|
||||
copyDataProperties(object2, r8, undefined);
|
||||
Reflect.apply(show, defaultImport, [object2]);
|
||||
}
|
||||
}
|
||||
|
||||
function onTapTimestamp({nativeEvent}) { // fn#87239, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:11566:1586, offset: 0x01fb4e5a, size: 59 bytes, params: 2, frame: 12
|
||||
const node = nativeEvent.node;
|
||||
const toastUtilsModule = require(3856) /* metro dependency 3856: ToastUtils */;
|
||||
toastUtilsModule.presentTimestamp(node.full);
|
||||
}
|
||||
|
||||
function onTapInlineCode({nativeEvent}) { // fn#87240, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:11566:1664, offset: 0x01fb4e95, size: 115 bytes, params: 2, frame: 14
|
||||
const node = nativeEvent.node;
|
||||
let value = node.content != null;
|
||||
if (value && typeof node.content === 'string') {
|
||||
value = require(6797) /* metro dependency 6797: ClipboardUtilsNative */;
|
||||
value.copy(node.content);
|
||||
value = require(3856) /* metro dependency 3856: ToastUtils */;
|
||||
value.presentCopiedToClipboard();
|
||||
}
|
||||
}
|
||||
|
||||
function onTapEmoji({nativeEvent}) { // fn#87241, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:11566:1811, offset: 0x01fb4f08, size: 102 bytes, params: 2, frame: 17
|
||||
const node = nativeEvent.node;
|
||||
const defaultImport = importDefault(dependencyMap[8]);
|
||||
const openLazy = defaultImport.openLazy;
|
||||
let value = require(dependencyMap[10]);
|
||||
value = value(dependencyMap[17], dependencyMap.paths);
|
||||
Reflect.apply(openLazy, defaultImport, [value, 'MessageEmojiActionSheet', {emojiNode: node}]);
|
||||
}
|
||||
|
||||
function onConfirmSecondary() { // fn#87238, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:11566:1341, owner: onTapMention.onConfirmSecondary, offset: 0x01fb4e17, size: 67 bytes, params: 1, frame: 14
|
||||
let value = environment.__proto__;
|
||||
value = require(6797) /* metro dependency 6797: ClipboardUtilsNative */;
|
||||
value.copy(parsedUserId);
|
||||
(require(3856) /* metro dependency 3856: ToastUtils */).presentCopiedToClipboard();
|
||||
}
|
||||
|
||||
@@ -0,0 +1,476 @@
|
||||
/* Metro module 11333; source: components_native/chat/getMessageJumpData.tsx; dependencies: [57, 31, 1480, 1878, 477, 1851, 4044, 21, 2] */
|
||||
function _fun86553(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#86553, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:11519:6, offset: 0x01f97718, size: 182 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 subscribeToKeyboardUIStore = importDefault(1480) /* metro dependency 1480: subscribeToKeyboardUIStore */;
|
||||
const userStore = importDefault(1878) /* metro dependency 1878: UserStore */;
|
||||
(require(2) /* metro dependency 2 */).fileFinishedImporting('components_native/chat/getMessageJumpData.tsx');
|
||||
exports.default = getMessageJumpData;
|
||||
exports.useMessageJumpAndroidKeyboardHeight = useMessageJumpAndroidKeyboardHeight;
|
||||
}
|
||||
|
||||
function getMessageJumpData(a0, a1, a2) { // fn#86554, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:11519:225, offset: 0x01f977ce, size: 588 bytes, params: 4, frame: 27
|
||||
var r16;
|
||||
var r4;
|
||||
var id;
|
||||
var r12;
|
||||
var r11;
|
||||
var r5;
|
||||
var r7;
|
||||
var r8;
|
||||
var r9;
|
||||
var jumpSequenceId2;
|
||||
var jumpSequenceId3;
|
||||
var value7;
|
||||
var focusSequenceId;
|
||||
var focusSequenceId2;
|
||||
var value8;
|
||||
var isAtBottom;
|
||||
var hasPreviousMessages;
|
||||
var loadingMore;
|
||||
var author;
|
||||
var id2;
|
||||
var interaction;
|
||||
var user;
|
||||
var id3;
|
||||
var defaultImport;
|
||||
var compare;
|
||||
var id4;
|
||||
var value10;
|
||||
var jumpedToPresent;
|
||||
var isAndroid;
|
||||
var androidKeyboardHeight;
|
||||
var androidKeyboardHeight2;
|
||||
var replyingMessageId;
|
||||
var channelId;
|
||||
var first;
|
||||
var jumpType;
|
||||
const messages = a0.messages;
|
||||
let value = messages.last();
|
||||
const messages2 = a2.messages;
|
||||
const value2 = messages2.last();
|
||||
const currentUser = UserStore.getCurrentUser();
|
||||
const value5 = undefined;
|
||||
const JumpTypes = (require(4044) /* metro dependency 4044: Client */).JumpTypes;
|
||||
const ANIMATED = JumpTypes.ANIMATED;
|
||||
const jumpSequenceId = messages.jumpSequenceId;
|
||||
const focusTargetId = messages.focusTargetId;
|
||||
const value6 = messages.initialScrollSequenceId !== messages2.initialScrollSequenceId;
|
||||
reducibleJoin2: while (true) {
|
||||
if (value6) {
|
||||
r16 = value6;
|
||||
break reducibleJoin2;
|
||||
}
|
||||
jumpSequenceId2 = messages2.jumpSequenceId;
|
||||
jumpSequenceId3 = messages.jumpSequenceId;
|
||||
value7 = jumpSequenceId2 !== jumpSequenceId3;
|
||||
r16 = value7;
|
||||
break reducibleJoin2;
|
||||
}
|
||||
reducibleJoin4: while (true) {
|
||||
if (value6) {
|
||||
r4 = value6;
|
||||
break reducibleJoin4;
|
||||
}
|
||||
focusSequenceId = messages2.focusSequenceId;
|
||||
focusSequenceId2 = messages.focusSequenceId;
|
||||
value8 = focusSequenceId !== focusSequenceId2;
|
||||
r4 = value8;
|
||||
break reducibleJoin4;
|
||||
}
|
||||
let jumpTargetId = messages.jumpTargetId;
|
||||
const value9 = null;
|
||||
reducibleJoin34: while (true) {
|
||||
reducibleJoin27: while (true) {
|
||||
if (value9 == jumpTargetId) {
|
||||
if (!a1.isAtBottom) {
|
||||
hasPreviousMessages = a1.hasPreviousMessages;
|
||||
if (hasPreviousMessages) {
|
||||
if (!messages2.loadingMore) {
|
||||
if (value9 != value) {
|
||||
if (value9 != currentUser) {
|
||||
author = value.author;
|
||||
id = author.id;
|
||||
id2 = currentUser.id;
|
||||
if (id !== id2) {
|
||||
interaction = value.interaction;
|
||||
reducibleJoin14: while (true) {
|
||||
if (value9 == interaction) {
|
||||
id = value5;
|
||||
break reducibleJoin14;
|
||||
}
|
||||
user = interaction.user;
|
||||
id = user.id;
|
||||
break reducibleJoin14;
|
||||
}
|
||||
id3 = currentUser.id;
|
||||
if (id !== id3) {
|
||||
if (!messages.loadingMore) {
|
||||
jumpedToPresent = messages.jumpedToPresent;
|
||||
if (jumpedToPresent) {
|
||||
if (r16) {
|
||||
if (value9 != value) {
|
||||
id = value.id;
|
||||
value = false;
|
||||
r5 = value;
|
||||
r7 = ANIMATED;
|
||||
r8 = value9;
|
||||
r9 = id;
|
||||
break reducibleJoin34;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
value = require(477) /* metro dependency 477: PlatformUtils */;
|
||||
value = value.isAndroid();
|
||||
reducibleJoin25: while (true) {
|
||||
if (value) {
|
||||
androidKeyboardHeight = a2.androidKeyboardHeight;
|
||||
androidKeyboardHeight2 = a0.androidKeyboardHeight;
|
||||
value = androidKeyboardHeight < androidKeyboardHeight2;
|
||||
r12 = value;
|
||||
break reducibleJoin25;
|
||||
}
|
||||
r12 = value;
|
||||
break reducibleJoin25;
|
||||
}
|
||||
if (r12) {
|
||||
replyingMessageId = a0.replyingMessageId;
|
||||
value = value9 != replyingMessageId;
|
||||
r12 = value;
|
||||
break reducibleJoin27;
|
||||
}
|
||||
break reducibleJoin27;
|
||||
}
|
||||
}
|
||||
if (value9 != value2) {
|
||||
defaultImport = importDefault(21) /* metro dependency 21: SnowflakeUtils */;
|
||||
compare = defaultImport.compare;
|
||||
id = value2.id;
|
||||
id4 = value.id;
|
||||
value10 = Reflect.apply(compare, defaultImport, [id, id4]);
|
||||
if (!(value10 < 0)) {
|
||||
if (!messages.loadingMore) {
|
||||
jumpedToPresent = messages.jumpedToPresent;
|
||||
if (jumpedToPresent) {
|
||||
if (r16) {
|
||||
if (value9 != value) {
|
||||
id = value.id;
|
||||
value = false;
|
||||
r5 = value;
|
||||
r7 = ANIMATED;
|
||||
r8 = value9;
|
||||
r9 = id;
|
||||
break reducibleJoin34;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
value = require(477) /* metro dependency 477: PlatformUtils */;
|
||||
value = value.isAndroid();
|
||||
reducibleJoin25: while (true) {
|
||||
if (value) {
|
||||
androidKeyboardHeight = a2.androidKeyboardHeight;
|
||||
androidKeyboardHeight2 = a0.androidKeyboardHeight;
|
||||
value = androidKeyboardHeight < androidKeyboardHeight2;
|
||||
r12 = value;
|
||||
break reducibleJoin25;
|
||||
}
|
||||
r12 = value;
|
||||
break reducibleJoin25;
|
||||
}
|
||||
if (r12) {
|
||||
replyingMessageId = a0.replyingMessageId;
|
||||
value = value9 != replyingMessageId;
|
||||
r12 = value;
|
||||
break reducibleJoin27;
|
||||
}
|
||||
break reducibleJoin27;
|
||||
}
|
||||
}
|
||||
id = value.id;
|
||||
value = false;
|
||||
r5 = value;
|
||||
r7 = ANIMATED;
|
||||
r8 = value9;
|
||||
r9 = id;
|
||||
break reducibleJoin34;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
if (!messages.loadingMore) {
|
||||
jumpedToPresent = messages.jumpedToPresent;
|
||||
if (jumpedToPresent) {
|
||||
if (r16) {
|
||||
if (value9 != value) {
|
||||
id = value.id;
|
||||
value = false;
|
||||
r5 = value;
|
||||
r7 = ANIMATED;
|
||||
r8 = value9;
|
||||
r9 = id;
|
||||
break reducibleJoin34;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
value = require(477) /* metro dependency 477: PlatformUtils */;
|
||||
value = value.isAndroid();
|
||||
reducibleJoin25: while (true) {
|
||||
if (value) {
|
||||
androidKeyboardHeight = a2.androidKeyboardHeight;
|
||||
androidKeyboardHeight2 = a0.androidKeyboardHeight;
|
||||
value = androidKeyboardHeight < androidKeyboardHeight2;
|
||||
r12 = value;
|
||||
break reducibleJoin25;
|
||||
}
|
||||
r12 = value;
|
||||
break reducibleJoin25;
|
||||
}
|
||||
if (r12) {
|
||||
replyingMessageId = a0.replyingMessageId;
|
||||
value = value9 != replyingMessageId;
|
||||
r12 = value;
|
||||
break reducibleJoin27;
|
||||
}
|
||||
break reducibleJoin27;
|
||||
}
|
||||
if (r16) {
|
||||
channelId = messages.channelId;
|
||||
jumpTargetId = messages.jumpTargetId;
|
||||
first = messages.first;
|
||||
value = Reflect.apply(first, messages, []);
|
||||
reducibleJoin33: while (true) {
|
||||
reducibleJoin31: while (true) {
|
||||
if (channelId !== jumpTargetId) {
|
||||
break reducibleJoin31;
|
||||
}
|
||||
if (value9 != value) {
|
||||
id = value.id;
|
||||
r11 = id;
|
||||
break reducibleJoin33;
|
||||
}
|
||||
break reducibleJoin31;
|
||||
}
|
||||
jumpTargetId = messages.jumpTargetId;
|
||||
r11 = jumpTargetId;
|
||||
break reducibleJoin33;
|
||||
}
|
||||
jumpType = messages.jumpType;
|
||||
value = false;
|
||||
r5 = value;
|
||||
r7 = jumpType;
|
||||
r8 = r11;
|
||||
r9 = r11;
|
||||
break reducibleJoin34;
|
||||
}
|
||||
isAtBottom = a1.isAtBottom;
|
||||
if (!isAtBottom) {
|
||||
hasPreviousMessages = a1.hasPreviousMessages;
|
||||
if (hasPreviousMessages) {
|
||||
if (!messages2.loadingMore) {
|
||||
if (value9 != value) {
|
||||
if (value9 != currentUser) {
|
||||
author = value.author;
|
||||
id = author.id;
|
||||
id2 = currentUser.id;
|
||||
if (id !== id2) {
|
||||
interaction = value.interaction;
|
||||
reducibleJoin14: while (true) {
|
||||
if (value9 == interaction) {
|
||||
id = value5;
|
||||
break reducibleJoin14;
|
||||
}
|
||||
user = interaction.user;
|
||||
id = user.id;
|
||||
break reducibleJoin14;
|
||||
}
|
||||
id3 = currentUser.id;
|
||||
if (id !== id3) {
|
||||
if (!messages.loadingMore) {
|
||||
jumpedToPresent = messages.jumpedToPresent;
|
||||
if (jumpedToPresent) {
|
||||
if (r16) {
|
||||
if (value9 != value) {
|
||||
id = value.id;
|
||||
value = false;
|
||||
r5 = value;
|
||||
r7 = ANIMATED;
|
||||
r8 = value9;
|
||||
r9 = id;
|
||||
break reducibleJoin34;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
value = require(477) /* metro dependency 477: PlatformUtils */;
|
||||
value = value.isAndroid();
|
||||
reducibleJoin25: while (true) {
|
||||
if (value) {
|
||||
androidKeyboardHeight = a2.androidKeyboardHeight;
|
||||
androidKeyboardHeight2 = a0.androidKeyboardHeight;
|
||||
value = androidKeyboardHeight < androidKeyboardHeight2;
|
||||
r12 = value;
|
||||
break reducibleJoin25;
|
||||
}
|
||||
r12 = value;
|
||||
break reducibleJoin25;
|
||||
}
|
||||
if (r12) {
|
||||
replyingMessageId = a0.replyingMessageId;
|
||||
value = value9 != replyingMessageId;
|
||||
r12 = value;
|
||||
break reducibleJoin27;
|
||||
}
|
||||
break reducibleJoin27;
|
||||
}
|
||||
}
|
||||
if (value9 != value2) {
|
||||
defaultImport = importDefault(21) /* metro dependency 21: SnowflakeUtils */;
|
||||
compare = defaultImport.compare;
|
||||
id = value2.id;
|
||||
id4 = value.id;
|
||||
value10 = Reflect.apply(compare, defaultImport, [id, id4]);
|
||||
if (!(value10 < 0)) {
|
||||
if (!messages.loadingMore) {
|
||||
jumpedToPresent = messages.jumpedToPresent;
|
||||
if (jumpedToPresent) {
|
||||
if (r16) {
|
||||
if (value9 != value) {
|
||||
id = value.id;
|
||||
value = false;
|
||||
r5 = value;
|
||||
r7 = ANIMATED;
|
||||
r8 = value9;
|
||||
r9 = id;
|
||||
break reducibleJoin34;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
value = require(477) /* metro dependency 477: PlatformUtils */;
|
||||
value = value.isAndroid();
|
||||
reducibleJoin25: while (true) {
|
||||
if (value) {
|
||||
androidKeyboardHeight = a2.androidKeyboardHeight;
|
||||
androidKeyboardHeight2 = a0.androidKeyboardHeight;
|
||||
value = androidKeyboardHeight < androidKeyboardHeight2;
|
||||
r12 = value;
|
||||
break reducibleJoin25;
|
||||
}
|
||||
r12 = value;
|
||||
break reducibleJoin25;
|
||||
}
|
||||
if (r12) {
|
||||
replyingMessageId = a0.replyingMessageId;
|
||||
value = value9 != replyingMessageId;
|
||||
r12 = value;
|
||||
break reducibleJoin27;
|
||||
}
|
||||
break reducibleJoin27;
|
||||
}
|
||||
}
|
||||
id = value.id;
|
||||
value = false;
|
||||
r5 = value;
|
||||
r7 = ANIMATED;
|
||||
r8 = value9;
|
||||
r9 = id;
|
||||
break reducibleJoin34;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
loadingMore = messages.loadingMore;
|
||||
if (!loadingMore) {
|
||||
jumpedToPresent = messages.jumpedToPresent;
|
||||
if (jumpedToPresent) {
|
||||
if (r16) {
|
||||
if (value9 != value) {
|
||||
id = value.id;
|
||||
value = false;
|
||||
r5 = value;
|
||||
r7 = ANIMATED;
|
||||
r8 = value9;
|
||||
r9 = id;
|
||||
break reducibleJoin34;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
value = require(477) /* metro dependency 477: PlatformUtils */;
|
||||
isAndroid = value.isAndroid;
|
||||
value = Reflect.apply(isAndroid, value, []);
|
||||
reducibleJoin25: while (true) {
|
||||
if (value) {
|
||||
androidKeyboardHeight = a2.androidKeyboardHeight;
|
||||
androidKeyboardHeight2 = a0.androidKeyboardHeight;
|
||||
value = androidKeyboardHeight < androidKeyboardHeight2;
|
||||
r12 = value;
|
||||
break reducibleJoin25;
|
||||
}
|
||||
r12 = value;
|
||||
break reducibleJoin25;
|
||||
}
|
||||
if (r12) {
|
||||
replyingMessageId = a0.replyingMessageId;
|
||||
value = value9 != replyingMessageId;
|
||||
r12 = value;
|
||||
break reducibleJoin27;
|
||||
}
|
||||
break reducibleJoin27;
|
||||
}
|
||||
value = false;
|
||||
if (r12) {
|
||||
replyingMessageId = a0.replyingMessageId;
|
||||
value = true;
|
||||
r5 = value;
|
||||
r7 = ANIMATED;
|
||||
r8 = value9;
|
||||
r9 = replyingMessageId;
|
||||
break reducibleJoin34;
|
||||
}
|
||||
r5 = value;
|
||||
r7 = ANIMATED;
|
||||
r8 = value9;
|
||||
r9 = value9;
|
||||
break reducibleJoin34;
|
||||
}
|
||||
return {scrollToMessageId: r9, jumpTargetId: r8, jumpType: r7, jumpSequenceId: jumpSequenceId,
|
||||
minimizeScrolling: r5, focusTargetId: r4 ? focusTargetId : value9, shouldInitialScroll: value6};
|
||||
}
|
||||
|
||||
function useMessageJumpAndroidKeyboardHeight() { // fn#86555, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:11519:1238, offset: 0x01f97a1a, size: 144 bytes, params: 1, frame: 19
|
||||
const binding = env0_4;
|
||||
const useState = binding.useState;
|
||||
const isAndroid2 = (require(477) /* metro dependency 477: PlatformUtils */).isAndroid();
|
||||
const value2 = 0;
|
||||
const value5 = env0_3(Reflect.apply(useState, binding,
|
||||
[isAndroid2 ? (require(1851) /* metro dependency 1851: useSystemKeyboardHeightNative */).getSystemKeyboardHeight() : value2]),
|
||||
2);
|
||||
const property = value5[value2];
|
||||
const env0_0 = value5[1];
|
||||
env0_4.useEffect(function() {
|
||||
return subscribeToKeyboardUIStore(_fun86557);
|
||||
}, []);
|
||||
return property;
|
||||
}
|
||||
|
||||
function _fun86556() { // fn#86556, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:11519:1402, offset: 0x01f97aaa, size: 25 bytes, params: 1, frame: 11
|
||||
return subscribeToKeyboardUIStore(_fun86557);
|
||||
}
|
||||
|
||||
function _fun86557(a0) { // fn#86557, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:11519:1409, offset: 0x01f97ac3, size: 61 bytes, params: 2, frame: 11
|
||||
let __proto__ = environment.__proto__.__proto__;
|
||||
if (Reflect.apply((require(477) /* metro dependency 477: PlatformUtils */).isAndroid, __proto__, [])) {
|
||||
__proto__ = environment.__proto__;
|
||||
env1_0(a0.keyboardHeight);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -0,0 +1,28 @@
|
||||
/* Metro module 9877; source: components_native/chat/isAlertOrActionSheetOpen.tsx; dependencies: [3849, 9878, 4497, 2] */
|
||||
function _fun77463(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#77463, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:10063:6, offset: 0x01dfd912, size: 130 bytes, params: 8, frame: 19
|
||||
const env0_0 = require;
|
||||
const Object = global.Object;
|
||||
Object.defineProperty(exports, '__esModule', {value: true});
|
||||
const actionSheetStore = importDefault(3849) /* metro dependency 3849: ActionSheetStore */;
|
||||
const alertStore = importDefault(9878) /* metro dependency 9878: AlertStore */;
|
||||
(require(2) /* metro dependency 2 */).fileFinishedImporting('components_native/chat/isAlertOrActionSheetOpen.tsx');
|
||||
exports.isAlertOrActionSheetOpen = isAlertOrActionSheetOpen;
|
||||
}
|
||||
|
||||
function isAlertOrActionSheetOpen(a0) { // fn#77464, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:10063:228, offset: 0x01dfd994, size: 130 bytes, params: 2, frame: 14
|
||||
let value = a1;
|
||||
const value2 = a2;
|
||||
const r1 = value !== undefined ? value : ActionSheetStore;
|
||||
const r3 = value2 !== undefined ? value2 : AlertStore;
|
||||
value = r1.getContent();
|
||||
value = value != null;
|
||||
const getAlert = r3.getAlert;
|
||||
const value3 = Reflect.apply(getAlert, r3, []) != null;
|
||||
const useAlertStore = (require(4497) /* metro dependency 4497: useAlertStoreNative */).useAlertStore;
|
||||
const getState = useAlertStore.getState;
|
||||
const value5 = Reflect.apply(getState, useAlertStore, []).alerts.length > 0;
|
||||
let r0 = value || value3;
|
||||
r0 = !r0 ? value5 : r0;
|
||||
return r0;
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user