Initial commit
This commit is contained in:
commit
af3b49f756
16065 files changed
+2938410
No files matched your search
@@ -0,0 +1,153 @@
|
||||
/* Metro module 10485; source: modules/user_profile/native/UserProfileIncomingFriendRequest.tsx; dependencies: [31, 27, 33, 4501, 697, 8496, 8514, 6771, 10486, 4617, 6777, 4573, 1244, 1305, 1423, 10487, 4578, 2] */
|
||||
function _fun81139(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#81139, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:10671:6, offset: 0x01e9b237, size: 289 bytes, params: 8, frame: 22
|
||||
const env0_0 = require;
|
||||
const Object = global.Object;
|
||||
Object.defineProperty(exports, '__esModule', {value: true});
|
||||
const env0_3 = importAll(31) /* metro dependency 31 */;
|
||||
const env0_4 = (require(27) /* metro dependency 27 */).View;
|
||||
let value = require(33) /* metro dependency 33 */;
|
||||
const env0_5 = value.jsx;
|
||||
const env0_6 = value.jsxs;
|
||||
value = require(4501) /* metro dependency 4501: createStyles */;
|
||||
const createStyles = value.createStyles;
|
||||
const BORDER_STRONG = (importDefault(697) /* metro dependency 697: native */).colors.BORDER_STRONG;
|
||||
const env0_7 = Reflect.apply(createStyles, value, [{container: {'rowGap': 16, 'flexDirection': 'column'},
|
||||
buttons: {'flexDirection': 'row', 'columnGap': 12}, gameIcon: {paddingTop: 2},
|
||||
friendRequestNote: {borderWidth: 1, borderColor: BORDER_STRONG}}]);
|
||||
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/user_profile/native/UserProfileIncomingFriendRequest.tsx');
|
||||
exports.default = UserProfileIncomingFriendRequest;
|
||||
}
|
||||
|
||||
function UserProfileIncomingFriendRequest({user, channelId, guildId, isGameRelationship, applicationId, style, showUserProfile}) { // fn#81140, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:10671:470, offset: 0x01e9b358, size: 968 bytes, params: 2, frame: 34
|
||||
var r0;
|
||||
const Text = (require(4573) /* metro dependency 4573: Text */).Text;
|
||||
var object3;
|
||||
const intl = (require(1244) /* metro dependency 1244: indexNative */).intl;
|
||||
var format;
|
||||
const t = (require(1244) /* metro dependency 1244: indexNative */).t;
|
||||
var items2;
|
||||
const Button = (require(4578) /* metro dependency 4578: ButtonNative */).Button;
|
||||
var string;
|
||||
var items3;
|
||||
let value = undefined;
|
||||
isGameRelationship = !(isGameRelationship === value) && isGameRelationship;
|
||||
const styles = useStyles();
|
||||
const value4 = (importDefault(8496) /* metro dependency 8496: UserProfileSharedStyles */)();
|
||||
const userProfileAnalyticsContextModule = require(8514) /* metro dependency 8514: UserProfileAnalyticsContext */;
|
||||
const useUserProfileAnalyticsContext = userProfileAnalyticsContextModule.useUserProfileAnalyticsContext;
|
||||
const trackUserProfileAction = Reflect.apply(useUserProfileAnalyticsContext, userProfileAnalyticsContextModule,
|
||||
[]).trackUserProfileAction;
|
||||
const newestAnalyticsLocation = (importDefault(6771) /* metro dependency 6771: useAnalyticsLocations */)().newestAnalyticsLocation;
|
||||
const useFriendRequestActionsModule = require(10486) /* metro dependency 10486: useFriendRequestActions */;
|
||||
const useFriendRequestActions = useFriendRequestActionsModule.useFriendRequestActions;
|
||||
const object4 = {};
|
||||
object4.userId = user.id;
|
||||
object4.applicationId = applicationId;
|
||||
object4.isGameRelationship = isGameRelationship;
|
||||
object4.location = newestAnalyticsLocation;
|
||||
object4.onConfirm = showUserProfile;
|
||||
object4.onCancel = showUserProfile;
|
||||
const value5 = Reflect.apply(useFriendRequestActions, useFriendRequestActionsModule, [object4]);
|
||||
const acceptFriendRequest = value5.acceptFriendRequest;
|
||||
const env0_3 = acceptFriendRequest;
|
||||
const cancelFriendRequest = value5.cancelFriendRequest;
|
||||
const value6 = (importDefault(4617) /* metro dependency 4617: NicknameUtils */).useName(guildId, channelId, user);
|
||||
const binding = env0_3;
|
||||
const value7 = binding.useCallback(_fun81141, [acceptFriendRequest, isGameRelationship, trackUserProfileAction]);
|
||||
const value8 = binding.useCallback(_fun81142, [cancelFriendRequest, isGameRelationship, trackUserProfileAction]);
|
||||
const value10 = applicationId != null;
|
||||
const value11 = (require(6777) /* metro dependency 6777: useGetOrFetchApplications */).useGetOrFetchApplication(applicationId);
|
||||
if (value10) {
|
||||
if (value11 == null) {
|
||||
r0 = null;
|
||||
} else {
|
||||
var viewProps = {style: [styles.container, value4.card, style]};
|
||||
object3 = {'variant': 'text-sm/semibold', 'color': 'text-default'};
|
||||
format = intl.format;
|
||||
if (value10) {
|
||||
object3.children = Reflect.apply(format, intl, [isGameRelationship ? t.syHjLL : t.V15uUI,
|
||||
{username: value6,
|
||||
applicationName: value11 == null ? value : value11.name, applicationIcon: applicationIcon}]);
|
||||
} else {
|
||||
object3.children = Reflect.apply(format, intl,
|
||||
[(require(1244) /* metro dependency 1244: indexNative */).t.uIomXw,
|
||||
{username: value6}]);
|
||||
}
|
||||
items2 = [<Text {...object3} />];
|
||||
items2[1] = ((Component) => <Component userId={user.id} styles={styles.friendRequestNote} analyticsLocation="User Profile" />)(importDefault(10487) /* metro dependency 10487: FriendRequestNote */);
|
||||
var viewBinding2Props = {style: styles.buttons};
|
||||
string = intl.string;
|
||||
items3 = [<Button size="sm" variant="primary" text={Reflect.apply(string, intl,
|
||||
[t.Zcibdf])} onPress={value7} />];
|
||||
string = intl.string;
|
||||
items3[1] = <Button size="sm" variant="secondary" text={Reflect.apply(string, intl,
|
||||
[t.xuio0C])} onPress={value8} />;
|
||||
items2[2] = <View {...viewBinding2Props}>{items3}</View>;
|
||||
value = <View {...viewProps}>{items2}</View>;
|
||||
r0 = value;
|
||||
}
|
||||
} else {
|
||||
var viewProps = {style: [styles.container, value4.card, style]};
|
||||
object3 = {'variant': 'text-sm/semibold', 'color': 'text-default'};
|
||||
format = intl.format;
|
||||
if (value10) {
|
||||
object3.children = Reflect.apply(format, intl, [isGameRelationship ? t.syHjLL : t.V15uUI, {username: value6,
|
||||
applicationName: value11 == null ? value : value11.name, applicationIcon: applicationIcon}]);
|
||||
} else {
|
||||
object3.children = Reflect.apply(format, intl,
|
||||
[(require(1244) /* metro dependency 1244: indexNative */).t.uIomXw,
|
||||
{username: value6}]);
|
||||
}
|
||||
items2 = [<Text {...object3} />];
|
||||
items2[1] = ((Component) => <Component userId={user.id} styles={styles.friendRequestNote} analyticsLocation="User Profile" />)(importDefault(10487) /* metro dependency 10487: FriendRequestNote */);
|
||||
var viewBinding2Props = {style: styles.buttons};
|
||||
string = intl.string;
|
||||
items3 = [<Button size="sm" variant="primary" text={Reflect.apply(string, intl,
|
||||
[t.Zcibdf])} onPress={value7} />];
|
||||
string = intl.string;
|
||||
items3[1] = <Button size="sm" variant="secondary" text={Reflect.apply(string, intl,
|
||||
[t.xuio0C])} onPress={value8} />;
|
||||
items2[2] = <View {...viewBinding2Props}>{items3}</View>;
|
||||
value = <View {...viewProps}>{items2}</View>;
|
||||
r0 = value;
|
||||
}
|
||||
return r0;
|
||||
}
|
||||
|
||||
function _fun81141() { // fn#81141, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:10671:944, offset: 0x01e9b720, size: 49 bytes, params: 1, frame: 13
|
||||
acceptFriendRequest();
|
||||
trackUserProfileAction({action: isGameRelationship ? 'ACCEPT_GAME_FRIEND_REQUEST' : 'ACCEPT_FRIEND_REQUEST'});
|
||||
}
|
||||
|
||||
function _fun81142() { // fn#81142, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:10671:1048, offset: 0x01e9b751, size: 49 bytes, params: 1, frame: 13
|
||||
cancelFriendRequest();
|
||||
trackUserProfileAction({action: isGameRelationship ? 'IGNORE_GAME_FRIEND_REQUEST' : 'IGNORE_FRIEND_REQUEST'});
|
||||
}
|
||||
|
||||
function applicationIcon() { // fn#81143, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:10671:1452, owner: UserProfileIncomingFriendRequest.applicationIcon, offset: 0x01e9b782, size: 172 bytes, params: 1, frame: 23
|
||||
var r0;
|
||||
var value3;
|
||||
var Avatar;
|
||||
var object2;
|
||||
var defaultImport;
|
||||
var getApplicationIconSource;
|
||||
var id;
|
||||
const value2 = null;
|
||||
if (value2 == env0_5) {
|
||||
r0 = value2;
|
||||
} else {
|
||||
value3 = environment.__proto__;
|
||||
Avatar = (require(1305) /* metro dependency 1305: native */).Avatar;
|
||||
object2 = {};
|
||||
defaultImport = importDefault(1423) /* metro dependency 1423: AvatarUtils */;
|
||||
getApplicationIconSource = defaultImport.getApplicationIconSource;
|
||||
id = env0_5.id;
|
||||
object2.source = Reflect.apply(getApplicationIconSource, defaultImport, [{id: id, icon: env0_5.icon}]);
|
||||
object2.size = (require(1305) /* metro dependency 1305: native */).AvatarSizes.XXSMALL;
|
||||
object2.style = styles.gameIcon;
|
||||
id = env0_5.id;
|
||||
r0 = <Avatar {...object2} key={id} />;
|
||||
}
|
||||
return r0;
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user