This commit is contained in:
janisslsm committed 2026-07-28 01:06:53 +03:00
1 parent af3b49f756
commit 1781d25a15
22448 files changed
+2731829 -2650550

No files matched your search

@@ -1,45 +1,60 @@
/* Metro module 12183; source: modules/premium/referral_program/native/ProgressWheel.tsx; dependencies: [27, 33, 4501, 3860, 697, 12175, 5475, 12184, 7744, 12185, 2] */
import Native from '../../../../external/discord_common/js/packages/tokens/native.tsx'; /* Metro dependency 697 */
import defaultImport2 from '../../../../by-id/module-07744.js'; /* Metro dependency 7744 */
import ReferralTrialPng from '../../../../external/discord_assets/assets/premium/referral_program/referralTrial.png.js'; /* Metro dependency 12185 */
import * as FileImportTrackerModule from '../../../../by-id/module-00002-FileImportTracker.js'; /* Metro dependency 2 */
import * as ReactNativeModule from '../../../../by-id/module-00027-ReactNative.js'; /* Metro dependency 27 */
import * as JsxRuntimeModule from '../../../../by-id/module-00033-JsxRuntime.js'; /* Metro dependency 33 */
import * as UseTokenModule from '../../../../design/tokens/native/useToken.tsx'; /* Metro dependency 3860 */
import * as CreateStylesModule from '../../../../design/components/Styles/native/createStyles.tsx'; /* Metro dependency 4501 */
import * as Module07744Module from '../../../../by-id/module-07744.js'; /* Metro dependency 7744 */
import * as UseReferralProgramBannerDetailsModule from '../hooks/useReferralProgramBannerDetails.tsx'; /* Metro dependency 12175 */
function _fun93363(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#93363, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12369:6, offset: 0x020b1013, size: 265 bytes, params: 8, frame: 19
const env0_0 = require;
const Object = global.Object;
Object.defineProperty(exports, '__esModule', {value: true});
const env0_3 = (require(27) /* metro dependency 27 */).View;
const value = require(33) /* metro dependency 33 */;
const env0_4 = value.jsx;
const env0_5 = value.jsxs;
const Math = global.Math;
const PI = Math.PI;
const env0_6 = 2 * PI * 77;
const env0_7 = (require(4501) /* metro dependency 4501: createStyles */).createStyles({progressCircleContainer: {'width': 160,
const env0_7 = (CreateStylesModule).createStyles({progressCircleContainer: {'width': 160,
'height': 160, 'alignItems': 'center', 'justifyContent': 'center', 'marginTop': 24},
progressCircleImage: {'position': 'absolute', 'width': 93, 'height': 93, 'borderRadius': 46.5},
glowImage: {'position': 'absolute', 'width': 180, 'height': 180}});
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/premium/referral_program/native/ProgressWheel.tsx');
(FileImportTrackerModule).fileFinishedImporting('modules/premium/referral_program/native/ProgressWheel.tsx');
exports.default = ProgressWheel;
function ProgressWheel({nReferralsSent}) { // fn#93364, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12369:519, offset: 0x020b111c, size: 500 bytes, params: 2, frame: 29
const styles = useStyles();
let useToken = UseTokenModule.useToken;
const BACKGROUND_MOD_STRONG = (Native).colors.BACKGROUND_MOD_STRONG;
const value2 = Reflect.apply(useToken, UseTokenModule, [BACKGROUND_MOD_STRONG]);
useToken = UseTokenModule.useToken;
const BACKGROUND_SURFACE_HIGH = (Native).colors.BACKGROUND_SURFACE_HIGH;
const value3 = Reflect.apply(useToken, UseTokenModule, [BACKGROUND_SURFACE_HIGH]);
const MAX_REFERRALS_SENT = (UseReferralProgramBannerDetailsModule).MAX_REFERRALS_SENT;
const r6 = nReferralsSent === MAX_REFERRALS_SENT && ((Component) => <Component source={importDefault(12184) /* metro dependency 12184 */} style={styles.glowImage} />)(importDefault(5475) /* metro dependency 5475: FastImage */);
const Circle = (Module07744Module).Circle;
const circle = (
<Circle
cx={80}
cy={80}
r={77}
stroke={value2}
strokeWidth={6}
fill={value3}
/>
);
const binding = env0_6;
return (
<View style={styles.progressCircleContainer}>
{r6}
{((Component) => <Component width={160} height={160}>{circle}<Circle cx={80} cy={80} r={77} stroke="#53ac66" strokeWidth={6} fill="transparent" strokeDasharray={binding} strokeDashoffset={binding * (1 - 33.3 * nReferralsSent / 100)} strokeLinecap="round" rotation={-90} origin="80, 80" /></Component>)(defaultImport2)}
{((Component) => <Component source={{uri: ReferralTrialPng}} style={styles.progressCircleImage} />)(importDefault(5475) /* metro dependency 5475: FastImage */)}
</View>
);
}
}
function ProgressWheel({nReferralsSent}) { // fn#93364, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12369:519, offset: 0x020b111c, size: 500 bytes, params: 2, frame: 29
const styles = useStyles();
const useTokenModule = require(3860) /* metro dependency 3860: useToken */;
let useToken = useTokenModule.useToken;
const BACKGROUND_MOD_STRONG = (importDefault(697) /* metro dependency 697: native */).colors.BACKGROUND_MOD_STRONG;
const value2 = Reflect.apply(useToken, useTokenModule, [BACKGROUND_MOD_STRONG]);
const moduleValue2 = useTokenModule;
useToken = moduleValue2.useToken;
const BACKGROUND_SURFACE_HIGH = (importDefault(697) /* metro dependency 697: native */).colors.BACKGROUND_SURFACE_HIGH;
const value3 = Reflect.apply(useToken, moduleValue2, [BACKGROUND_SURFACE_HIGH]);
const MAX_REFERRALS_SENT = (require(12175) /* metro dependency 12175: useReferralProgramBannerDetails */).MAX_REFERRALS_SENT;
const r6 = nReferralsSent === MAX_REFERRALS_SENT && ((Component) => <Component source={importDefault(12184) /* metro dependency 12184 */} style={styles.glowImage} />)(importDefault(5475) /* metro dependency 5475: FastImage */);
const defaultImport2 = importDefault(7744) /* metro dependency 7744 */;
const Circle = (require(7744) /* metro dependency 7744 */).Circle;
const circle = <Circle cx={80} cy={80} r={77} stroke={value2} strokeWidth={6} fill={value3} />;
const binding = env0_6;
return (
<View style={styles.progressCircleContainer}>
{r6}
{((Component) => <Component width={160} height={160}>{circle}<Circle cx={80} cy={80} r={77} stroke="#53ac66" strokeWidth={6} fill="transparent" strokeDasharray={binding} strokeDashoffset={binding * (1 - 33.3 * nReferralsSent / 100)} strokeLinecap="round" rotation={-90} origin="80, 80" /></Component>)(defaultImport2)}
{((Component) => <Component source={{uri: importDefault(12185) /* metro dependency 12185: referralTrialPng */}} style={styles.progressCircleImage} />)(importDefault(5475) /* metro dependency 5475: FastImage */)}
</View>
);
}
global.__d(_fun93363, 12183, [27, 33, 4501, 3860, 697, 12175, 5475, 12184, 7744, 12185,
2]) /* metro module 12183, dependencies: [27, 33, 4501, 3860, 697, 12175, 5475, 12184, 7744, 12185, 2] */;
@@ -1,13 +1,25 @@
/* Metro module 12174; source: modules/premium/referral_program/native/ReferralProgramPerkCard.tsx; dependencies: [31, 27, 7065, 661, 33, 4501, 697, 1305, 4573, 12175, 1244, 1948, 566, 6771, 6789, 7066, 683, 4080, 12176, 1962, 12183, 6766, 4578, 2] */
import UseAnalyticsLocations from '../../../app_analytics/useAnalyticsLocations.tsx'; /* Metro dependency 6771 */
import AnalyticsLocation from '../../../app_analytics/AnalyticsLocation.tsx'; /* Metro dependency 6789 */
import ReferralTrialStore from '../../ReferralTrialStore.tsx'; /* Metro dependency 7065 */
import ProgressWheel from './ProgressWheel.tsx'; /* Metro dependency 12183 */
import * as FileImportTrackerModule from '../../../../by-id/module-00002-FileImportTracker.js'; /* Metro dependency 2 */
import * as ReactNativeModule from '../../../../by-id/module-00027-ReactNative.js'; /* Metro dependency 27 */
import * as ReactModule from '../../../../by-id/module-00031-React.js'; /* Metro dependency 31 */
import * as FluxModule from '../../../../external/discord_common/js/packages/flux/index.tsx'; /* Metro dependency 566 */
import * as ConstantsModule from '../../../../Constants.tsx'; /* Metro dependency 661 */
import * as IndexNativeModule from '../../../../intl/index.native.tsx'; /* Metro dependency 1244 */
import * as NativeModule from '../../../../design/void/native.tsx'; /* Metro dependency 1305 */
import * as TextModule from '../../../../design/components/Text/native/Text.tsx'; /* Metro dependency 4573 */
import * as ButtonNativeModule from '../../../../design/components/Button/native/Button.native.tsx'; /* Metro dependency 4578 */
import * as TextWithIOSLinkWorkaroundModule from '../../../a11y/native/TextWithIOSLinkWorkaround.tsx'; /* Metro dependency 6766 */
import * as UseReferralProgramBannerDetailsModule from '../hooks/useReferralProgramBannerDetails.tsx'; /* Metro dependency 12175 */
function _fun93282(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#93282, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12360:6, offset: 0x020adde8, size: 677 bytes, params: 8, frame: 23
var object5;
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;
const referralTrialStore = importDefault(7065) /* metro dependency 7065: ReferralTrialStore */;
let value = require(661) /* metro dependency 661: Constants */;
let value = ConstantsModule;
const env0_6 = value.AnalyticEvents;
const env0_7 = value.HelpdeskArticles;
value = require(33) /* metro dependency 33 */;
@@ -15,224 +27,255 @@ function _fun93282(global, require, importDefault, importAll, module, exports, d
const env0_9 = value.jsxs;
value = require(4501) /* metro dependency 4501: createStyles */;
const createStyles = value.createStyles;
object5 = {};
const object6 = {width: 320};
object6.borderRadius = (importDefault(697) /* metro dependency 697: native */).radii.sm;
object = {};
const object2 = {width: 320};
object2.borderRadius = (importDefault(697) /* metro dependency 697: native */).radii.sm;
let BACKGROUND_SURFACE_HIGH = (importDefault(697) /* metro dependency 697: native */).colors.BACKGROUND_SURFACE_HIGH;
object6.backgroundColor = BACKGROUND_SURFACE_HIGH;
object6.alignItems = 'center';
object2.backgroundColor = BACKGROUND_SURFACE_HIGH;
object2.alignItems = 'center';
const SHADOW_LOW = (importDefault(697) /* metro dependency 697: native */).shadows.SHADOW_LOW;
copyDataProperties(object6, SHADOW_LOW, undefined);
object5.container = object6;
object5.progressIndicatorContainer = {'flexDirection': 'row', 'alignItems': 'center', 'alignSelf': 'flex-start',
copyDataProperties(object2, SHADOW_LOW, undefined);
object.container = object2;
object.progressIndicatorContainer = {'flexDirection': 'row', 'alignItems': 'center', 'alignSelf': 'flex-start',
'gap': 8, 'marginTop': 16, 'marginLeft': 24};
const object8 = {'width': 24, 'height': 24, 'borderRadius': null, 'backgroundColor': null,
const object3 = {'width': 24, 'height': 24, 'borderRadius': null, 'backgroundColor': null,
'justifyContent': 'center', 'alignItems': 'center'};
object8.borderRadius = (importDefault(697) /* metro dependency 697: native */).radii.xxl;
object3.borderRadius = (importDefault(697) /* metro dependency 697: native */).radii.xxl;
const BACKGROUND_MOD_STRONG = (importDefault(697) /* metro dependency 697: native */).colors.BACKGROUND_MOD_STRONG;
object8.backgroundColor = BACKGROUND_MOD_STRONG;
object5.availableReferralSlot = object8;
const object9 = {borderWidth: 2};
object3.backgroundColor = BACKGROUND_MOD_STRONG;
object.availableReferralSlot = object3;
const object4 = {borderWidth: 2};
BACKGROUND_SURFACE_HIGH = (importDefault(697) /* metro dependency 697: native */).colors.BACKGROUND_SURFACE_HIGH;
object9.borderColor = BACKGROUND_SURFACE_HIGH;
object9.borderRadius = (importDefault(697) /* metro dependency 697: native */).radii.round;
object5.referredFriendAvatar = object9;
object5.contentContainer = {'alignItems': 'flex-start', 'paddingHorizontal': 24, 'gap': 8, 'marginTop': 12};
object5.heading = {textAlign: 'left'};
object5.bodyText = {textAlign: 'left'};
const object10 = {};
object4.borderColor = BACKGROUND_SURFACE_HIGH;
object4.borderRadius = (importDefault(697) /* metro dependency 697: native */).radii.round;
object.referredFriendAvatar = object4;
object.contentContainer = {'alignItems': 'flex-start', 'paddingHorizontal': 24, 'gap': 8, 'marginTop': 12};
object.heading = {textAlign: 'left'};
object.bodyText = {textAlign: 'left'};
const object7 = {};
let PX_16 = (importDefault(697) /* metro dependency 697: native */).space.PX_16;
object10.paddingHorizontal = PX_16;
object10.width = '100%';
object7.paddingHorizontal = PX_16;
object7.width = '100%';
const PX_24 = (importDefault(697) /* metro dependency 697: native */).space.PX_24;
object10.marginTop = PX_24;
object7.marginTop = PX_24;
PX_16 = (importDefault(697) /* metro dependency 697: native */).space.PX_16;
object10.marginBottom = PX_16;
object5.buttonContainer = object10;
const env0_10 = Reflect.apply(createStyles, value, [object5]);
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/premium/referral_program/native/ReferralProgramPerkCard.tsx');
object7.marginBottom = PX_16;
object.buttonContainer = object7;
const env0_10 = Reflect.apply(createStyles, value, [object]);
(FileImportTrackerModule).fileFinishedImporting('modules/premium/referral_program/native/ReferralProgramPerkCard.tsx');
exports.ReferralProgramPerkCard = ReferralProgramPerkCard;
}
function ReferredFriendAvatar({user}) { // fn#93283, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12360:1090, offset: 0x020ae08d, size: 138 bytes, params: 2, frame: 24
const styles = useStyles();
const Avatar = (require(1305) /* metro dependency 1305: native */).Avatar;
const avatarProps = {source: user.getAvatarSource(undefined, false, 24)};
const AvatarSizes = (require(1305) /* metro dependency 1305: native */).AvatarSizes;
const XSMALL = AvatarSizes.XSMALL;
avatarProps.size = XSMALL;
return (
<View style={styles.referredFriendAvatar}>
<Avatar {...avatarProps} />
</View>
);
}
function AvailableReferralSlot({slotIndex}) { // fn#93284, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12360:1283, offset: 0x020ae117, size: 107 bytes, params: 2, frame: 18
const styles = useStyles();
const Text = (require(4573) /* metro dependency 4573: Text */).Text;
return (
<View style={styles.availableReferralSlot}>
<Text variant="text-xs/medium" color="text-strong">
{slotIndex}
</Text>
</View>
);
}
function ProgressIndicator({referralSentUsers}) { // fn#93285, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12360:1466, offset: 0x020ae182, size: 218 bytes, params: 2, frame: 24
var r7;
var push;
var jsxRuntimeEnv0_8Binding;
var id;
var value3;
const styles = useStyles();
const items2 = [];
const MAX_REFERRALS_SENT = (require(12175) /* metro dependency 12175: useReferralProgramBannerDetails */).MAX_REFERRALS_SENT;
if (0 < MAX_REFERRALS_SENT) {
r7 = 0;
while (true) {
if (referralSentUsers[r7] != null) {
push = items2.push;
jsxRuntimeEnv0_8Binding = jsxRuntimeEnv0_8;
id = referralSentUsers[r7].id;
Reflect.apply(push, items2, [<ReferredFriendAvatar user={referralSentUsers[r7]} key={id} />]);
} else {
push = items2.push;
jsxRuntimeEnv0_8Binding = jsxRuntimeEnv0_8;
Reflect.apply(push, items2, [<AvailableReferralSlot slotIndex={r7 + 1} key={r7} />]);
}
value3 = typeof r7 === 'bigint' ? r7 + 1n : +r7 + 1;
if (value3 < MAX_REFERRALS_SENT) {
r7 = value3;
continue;
}
break;
}
function ReferredFriendAvatar({user}) { // fn#93283, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12360:1090, offset: 0x020ae08d, size: 138 bytes, params: 2, frame: 24
const styles = useStyles();
const Avatar = (NativeModule).Avatar;
const avatarProps = {source: user.getAvatarSource(undefined, false, 24)};
const AvatarSizes = (NativeModule).AvatarSizes;
const XSMALL = AvatarSizes.XSMALL;
avatarProps.size = XSMALL;
return (
<View style={styles.referredFriendAvatar}>
<Avatar {...avatarProps} />
</View>
);
}
return (
<View style={styles.progressIndicatorContainer}>
{items2}
</View>
);
}
function getBodyText_93286(a0, a1, a2) { // fn#93286, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12360:1746, offset: 0x020ae25c, size: 428 bytes, params: 4, frame: 22
var r2;
var r1;
var r0;
const intl = (require(1244) /* metro dependency 1244: indexNative */).intl;
var format;
const t = (require(1244) /* metro dependency 1244: indexNative */).t;
var property;
var defaultImport;
var defaultImport2;
var defaultImport3;
var defaultImport4;
if (a0) {
if (a1 === (require(12175) /* metro dependency 12175: useReferralProgramBannerDetails */).MAX_REFERRALS_SENT) {
format = intl.format;
if (a2) {
property = t['1aEjsH'];
defaultImport4 = importDefault(1948) /* metro dependency 1948: HelpdeskUtils */;
r2 = Reflect.apply(format, intl, [property,
{helpdeskArticle: defaultImport4.getArticleURL(HelpdeskArticles.REFERRAL_PROGRAM)}]);
} else {
property = t['+u3AOO'];
defaultImport3 = importDefault(1948) /* metro dependency 1948: HelpdeskUtils */;
r2 = Reflect.apply(format, intl, [property,
{helpdeskArticle: defaultImport3.getArticleURL(HelpdeskArticles.REFERRAL_PROGRAM)}]);
function AvailableReferralSlot({slotIndex}) { // fn#93284, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12360:1283, offset: 0x020ae117, size: 107 bytes, params: 2, frame: 18
const styles = useStyles();
const Text = (TextModule).Text;
return (
<View style={styles.availableReferralSlot}>
<Text variant="text-xs/medium" color="text-strong">
{slotIndex}
</Text>
</View>
);
}
function ProgressIndicator({referralSentUsers}) { // fn#93285, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12360:1466, offset: 0x020ae182, size: 218 bytes, params: 2, frame: 24
var r7;
var push;
var jsxRuntimeEnv0_8Binding;
var id;
var value3;
const styles = useStyles();
const items2 = [];
const MAX_REFERRALS_SENT = (UseReferralProgramBannerDetailsModule).MAX_REFERRALS_SENT;
if (0 < MAX_REFERRALS_SENT) {
r7 = 0;
while (true) {
if (referralSentUsers[r7] != null) {
push = items2.push;
jsxRuntimeEnv0_8Binding = jsxRuntimeEnv0_8;
id = referralSentUsers[r7].id;
Reflect.apply(push, items2, [<ReferredFriendAvatar user={referralSentUsers[r7]} key={id} />]);
} else {
push = items2.push;
jsxRuntimeEnv0_8Binding = jsxRuntimeEnv0_8;
Reflect.apply(push, items2, [<AvailableReferralSlot slotIndex={r7 + 1} key={r7} />]);
}
value3 = typeof r7 === 'bigint' ? r7 + 1n : +r7 + 1;
if (value3 < MAX_REFERRALS_SENT) {
r7 = value3;
continue;
}
break;
}
r1 = r2;
}
return (
<View style={styles.progressIndicatorContainer}>
{items2}
</View>
);
}
function getBodyText_93286(a0, a1, a2) { // fn#93286, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12360:1746, offset: 0x020ae25c, size: 428 bytes, params: 4, frame: 22
var r2;
var r1;
var r0;
const intl = (IndexNativeModule).intl;
var format;
const t = (IndexNativeModule).t;
var property;
var defaultImport;
var defaultImport2;
var defaultImport3;
var defaultImport4;
if (a0) {
if (a1 === (require(12175) /* metro dependency 12175: useReferralProgramBannerDetails */).MAX_REFERRALS_SENT) {
format = intl.format;
if (a2) {
property = t['1aEjsH'];
defaultImport4 = importDefault(1948) /* metro dependency 1948: HelpdeskUtils */;
r2 = Reflect.apply(format, intl, [property,
{helpdeskArticle: defaultImport4.getArticleURL(HelpdeskArticles.REFERRAL_PROGRAM)}]);
} else {
property = t['+u3AOO'];
defaultImport3 = importDefault(1948) /* metro dependency 1948: HelpdeskUtils */;
r2 = Reflect.apply(format, intl, [property,
{helpdeskArticle: defaultImport3.getArticleURL(HelpdeskArticles.REFERRAL_PROGRAM)}]);
}
r1 = r2;
} else {
format = intl.format;
property = t['omMr+V'];
defaultImport2 = importDefault(1948) /* metro dependency 1948: HelpdeskUtils */;
r1 = Reflect.apply(format, intl, [property,
{helpdeskArticle: defaultImport2.getArticleURL(HelpdeskArticles.REFERRAL_PROGRAM)}]);
}
r0 = r1;
} else {
format = intl.format;
property = t['omMr+V'];
defaultImport2 = importDefault(1948) /* metro dependency 1948: HelpdeskUtils */;
r1 = Reflect.apply(format, intl, [property,
{helpdeskArticle: defaultImport2.getArticleURL(HelpdeskArticles.REFERRAL_PROGRAM)}]);
property = t['zWhX/Q'];
defaultImport = importDefault(1948) /* metro dependency 1948: HelpdeskUtils */;
r0 = Reflect.apply(format, intl, [property,
{helpdeskArticle: defaultImport.getArticleURL(HelpdeskArticles.REFERRAL_PROGRAM)}]);
}
r0 = r1;
} else {
format = intl.format;
property = t['zWhX/Q'];
defaultImport = importDefault(1948) /* metro dependency 1948: HelpdeskUtils */;
r0 = Reflect.apply(format, intl, [property,
{helpdeskArticle: defaultImport.getArticleURL(HelpdeskArticles.REFERRAL_PROGRAM)}]);
return r0;
}
return r0;
}
function ReferralProgramPerkCard() { // fn#93287, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12360:2364, offset: 0x020ae408, size: 781 bytes, params: 1, frame: 34
var r23;
var value3;
const styles = useStyles();
const useReferralProgramBannerDetailsModule = require(12175) /* metro dependency 12175: useReferralProgramBannerDetails */;
const useReferralProgramBannerDetails = useReferralProgramBannerDetailsModule.useReferralProgramBannerDetails;
const referralSentUsers = Reflect.apply(useReferralProgramBannerDetails, useReferralProgramBannerDetailsModule,
[]).referralSentUsers;
const fluxModule = require(566) /* metro dependency 566: flux */;
const useStateFromStores = fluxModule.useStateFromStores;
let items2 = [ReferralTrialStore];
const recipientStatus = Reflect.apply(useStateFromStores, fluxModule, [items2, function() {
return ReferralTrialStore.getRecipientStatus();
}]);
const hasEligibleFriends = fluxModule.useStateFromStores([ReferralTrialStore], function() {
return ReferralTrialStore.getHasEligibleFriends();
});
const defaultImport = importDefault(6771) /* metro dependency 6771: useAnalyticsLocations */;
const PREMIUM_MARKETING_REFERALL_PROGRAM_PROGRESS_BAR = (importDefault(6789) /* metro dependency 6789: AnalyticsLocation */).PREMIUM_MARKETING_REFERALL_PROGRAM_PROGRESS_BAR;
const analyticsLocations = defaultImport(PREMIUM_MARKETING_REFERALL_PROGRAM_PROGRESS_BAR).analyticsLocations;
const size = recipientStatus.size;
const MAX_REFERRALS_SENT = useReferralProgramBannerDetailsModule.MAX_REFERRALS_SENT;
const value2 = size === MAX_REFERRALS_SENT;
if (value2) {
value3 = recipientStatus.values();
items2 = [];
arraySpread(items2, value3, 0, value2);
r23 = items2.every(function(a0) {
var REDEEMED = require(dependencyMap[15]).ReferralOfferStatus.REDEEMED;
return a0 === REDEEMED;
function ReferralProgramPerkCard() { // fn#93287, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12360:2364, offset: 0x020ae408, size: 781 bytes, params: 1, frame: 34
var r23;
var value3;
const styles = useStyles();
const useReferralProgramBannerDetails = UseReferralProgramBannerDetailsModule.useReferralProgramBannerDetails;
const referralSentUsers = Reflect.apply(useReferralProgramBannerDetails, UseReferralProgramBannerDetailsModule,
[]).referralSentUsers;
const useStateFromStores = FluxModule.useStateFromStores;
const referralTrialStoreBinding = ReferralTrialStore;
let items2 = [referralTrialStoreBinding];
const recipientStatus = Reflect.apply(useStateFromStores, FluxModule, [items2, function() {
return ReferralTrialStore.getRecipientStatus();
}]);
const hasEligibleFriends = FluxModule.useStateFromStores([referralTrialStoreBinding], function() {
return ReferralTrialStore.getHasEligibleFriends();
});
} else {
r23 = value2;
const defaultImport = UseAnalyticsLocations;
const PREMIUM_MARKETING_REFERALL_PROGRAM_PROGRESS_BAR = (AnalyticsLocation).PREMIUM_MARKETING_REFERALL_PROGRAM_PROGRESS_BAR;
const analyticsLocations = defaultImport(PREMIUM_MARKETING_REFERALL_PROGRAM_PROGRESS_BAR).analyticsLocations;
const size = recipientStatus.size;
const MAX_REFERRALS_SENT = UseReferralProgramBannerDetailsModule.MAX_REFERRALS_SENT;
const value2 = size === MAX_REFERRALS_SENT;
if (value2) {
value3 = recipientStatus.values();
items2 = [];
arraySpread(items2, value3, 0, value2);
r23 = items2.every(function(a0) {
var REDEEMED = require(dependencyMap[15]).ReferralOfferStatus.REDEEMED;
return a0 === REDEEMED;
});
} else {
r23 = value2;
}
const value5 = recipientStatus.size === MAX_REFERRALS_SENT;
const value6 = ReactModule.useCallback(_fun93291, [analyticsLocations]);
const items3 = [
((Component) => <Component nReferralsSent={recipientStatus.size} />)(ProgressWheel),
];
items3[1] = <ProgressIndicator referralSentUsers={referralSentUsers} />;
const Text = (TextModule).Text;
const intl = (IndexNativeModule).intl;
let string = intl.string;
const USo4s7 = (IndexNativeModule).t.USo4s7;
const text = (
<Text
variant="heading-lg/semibold"
color="text-strong"
style={styles.heading}
>
{Reflect.apply(string, intl, [USo4s7])}
</Text>
);
const TextWithIOSLinkWorkaround = (TextWithIOSLinkWorkaroundModule).TextWithIOSLinkWorkaround;
items3[2] = (
<View style={styles.contentContainer}>
{text}
<TextWithIOSLinkWorkaround
variant="text-md/medium"
color="text-subtle"
style={styles.bodyText}
>
{getBodyText_93286(hasEligibleFriends !== false, referralSentUsers.length, r23)}
</TextWithIOSLinkWorkaround>
</View>
);
const Button = (ButtonNativeModule).Button;
const r13 = hasEligibleFriends === false || value5;
string = intl.string;
const Lm2nFc = (IndexNativeModule).t.Lm2nFc;
items3[3] = (
<View style={styles.buttonContainer}>
<Button
variant="primary"
size="sm"
disabled={r13}
text={Reflect.apply(string, intl, [Lm2nFc])}
onPress={value6}
/>
</View>
);
return (
<View style={styles.container}>
{items3}
</View>
);
function _fun93291() { // fn#93291, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12360:2856, offset: 0x020ae76b, size: 126 bytes, params: 1, frame: 18
let value = environment.__proto__;
const defaultImport = importDefault(dependencyMap[16]);
const track = defaultImport.track;
const REFERRAL_PROGRAM_SHARE_MODAL_CTA_CLICKED = AnalyticEvents.REFERRAL_PROGRAM_SHARE_MODAL_CTA_CLICKED;
Reflect.apply(track, defaultImport, [REFERRAL_PROGRAM_SHARE_MODAL_CTA_CLICKED,
{location_stack: analyticsLocations}]);
const defaultImport2 = importDefault(dependencyMap[17]);
const openLazy = defaultImport2.openLazy;
value = require(dependencyMap[19]);
value = value(dependencyMap[18], dependencyMap.paths);
Reflect.apply(openLazy, defaultImport2, [value, 'referral-program-share-action-sheet']);
}
}
const value5 = recipientStatus.size === MAX_REFERRALS_SENT;
const value6 = env0_3.useCallback(_fun93291, [analyticsLocations]);
const items3 = [((Component) => <Component nReferralsSent={recipientStatus.size} />)(importDefault(12183) /* metro dependency 12183: ProgressWheel */)];
items3[1] = <ProgressIndicator referralSentUsers={referralSentUsers} />;
const Text = (require(4573) /* metro dependency 4573: Text */).Text;
const intl = (require(1244) /* metro dependency 1244: indexNative */).intl;
let string = intl.string;
const USo4s7 = (require(1244) /* metro dependency 1244: indexNative */).t.USo4s7;
const text = <Text variant="heading-lg/semibold" color="text-strong" style={styles.heading}>{Reflect.apply(string,
intl, [USo4s7])}</Text>;
const TextWithIOSLinkWorkaround = (require(6766) /* metro dependency 6766: TextWithIOSLinkWorkaround */).TextWithIOSLinkWorkaround;
items3[2] = <View style={styles.contentContainer}>{text}<TextWithIOSLinkWorkaround variant="text-md/medium" color="text-subtle" style={styles.bodyText}>{getBodyText_93286(hasEligibleFriends !== false,
referralSentUsers.length, r23)}</TextWithIOSLinkWorkaround></View>;
const Button = (require(4578) /* metro dependency 4578: ButtonNative */).Button;
const r13 = hasEligibleFriends === false || value5;
string = intl.string;
const Lm2nFc = (require(1244) /* metro dependency 1244: indexNative */).t.Lm2nFc;
items3[3] = <View style={styles.buttonContainer}><Button variant="primary" size="sm" disabled={r13} text={Reflect.apply(string,
intl, [Lm2nFc])} onPress={value6} /></View>;
return (
<View style={styles.container}>
{items3}
</View>
);
}
function _fun93291() { // fn#93291, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12360:2856, offset: 0x020ae76b, size: 126 bytes, params: 1, frame: 18
let value = environment.__proto__;
const defaultImport = importDefault(dependencyMap[16]);
const track = defaultImport.track;
const REFERRAL_PROGRAM_SHARE_MODAL_CTA_CLICKED = AnalyticEvents.REFERRAL_PROGRAM_SHARE_MODAL_CTA_CLICKED;
Reflect.apply(track, defaultImport, [REFERRAL_PROGRAM_SHARE_MODAL_CTA_CLICKED,
{location_stack: analyticsLocations}]);
const defaultImport2 = importDefault(dependencyMap[17]);
const openLazy = defaultImport2.openLazy;
value = require(dependencyMap[19]);
value = value(dependencyMap[18], dependencyMap.paths);
Reflect.apply(openLazy, defaultImport2, [value, 'referral-program-share-action-sheet']);
}
global.__d(_fun93282, 12174, [31, 27, 7065, 661, 33, 4501, 697, 1305, 4573, 12175, 1244, 1948, 566, 6771, 6789,
7066, 683, 4080, 12176, 1962, 12183, 6766, 4578,
2]) /* metro module 12174, dependencies: [31, 27, 7065, 661, 33, 4501, 697, 1305, 4573, 12175, 1244, 1948, 566, 6771, 6789, 7066, 683, 4080, 12176, 1962, 12183, 6766, 4578, 2] */;
File diff suppressed because it is too large. Load diff
@@ -1,41 +1,46 @@
/* Metro module 12179; source: modules/premium/referral_program/native/ReferralProgramShareActionSheetUtils.tsx; dependencies: [3793, 7690, 2] */
import RelationshipStore from '../../../../stores/RelationshipStore.tsx'; /* Metro dependency 3793 */
import * as FileImportTrackerModule from '../../../../by-id/module-00002-FileImportTracker.js'; /* Metro dependency 2 */
import * as UserRowConstantsModule from '../../../main_tabs_v2/native/shared_components/user_list/UserRowConstants.tsx'; /* Metro dependency 7690 */
function _fun93353(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#93353, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12365:6, offset: 0x020b0559, size: 128 bytes, params: 8, frame: 18
const Object = global.Object;
Object.defineProperty(exports, '__esModule', {value: true});
const relationshipStore = importDefault(3793) /* metro dependency 3793: RelationshipStore */;
const env0_1 = (require(7690) /* metro dependency 7690: UserRowConstants */).UserRowModes;
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/premium/referral_program/native/ReferralProgramShareActionSheetUtils.tsx');
(FileImportTrackerModule).fileFinishedImporting('modules/premium/referral_program/native/ReferralProgramShareActionSheetUtils.tsx');
exports.buildReferralUserRow = buildReferralUserRow;
}
function buildReferralUserRow({eligibleUsers, row, selectedUserIds, resendUsers, referralsRemaining, selectedNotResendUsers, onSelectUser}) { // fn#93354, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12365:266, offset: 0x020b05d9, size: 216 bytes, params: 2, frame: 21
var r5;
var length;
var value;
var includes;
var id;
var value2;
var has;
var value3;
var getRelationshipType;
const property = eligibleUsers[row];
if (property != null) {
length = selectedNotResendUsers.length;
value = length >= referralsRemaining;
includes = selectedUserIds.includes;
id = property.id;
value2 = Reflect.apply(includes, selectedUserIds, [id]);
has = resendUsers.has;
id = property.id;
value3 = Reflect.apply(has, resendUsers, [id]);
getRelationshipType = RelationshipStore.getRelationshipType;
id = property.id;
r5 = value && !value2;
r5 = r5 && !value3;
length = eligibleUsers.length;
return {type: 'user', props: {type: Reflect.apply(getRelationshipType, RelationshipStore, [id]), user: property,
onPress: onSelectUser, selected: value2, disabled: r5, mode: UserRowModes.TOGGLE, start: row === 0,
end: row === length - 1}};
function buildReferralUserRow({eligibleUsers, row, selectedUserIds, resendUsers, referralsRemaining, selectedNotResendUsers, onSelectUser}) { // fn#93354, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12365:266, offset: 0x020b05d9, size: 216 bytes, params: 2, frame: 21
var r5;
var length;
var value;
var includes;
var id;
var value2;
var has;
var value3;
var relationshipStoreBinding;
var getRelationshipType;
const property = eligibleUsers[row];
if (property != null) {
length = selectedNotResendUsers.length;
value = length >= referralsRemaining;
includes = selectedUserIds.includes;
id = property.id;
value2 = Reflect.apply(includes, selectedUserIds, [id]);
has = resendUsers.has;
id = property.id;
value3 = Reflect.apply(has, resendUsers, [id]);
relationshipStoreBinding = RelationshipStore;
getRelationshipType = relationshipStoreBinding.getRelationshipType;
id = property.id;
r5 = value && !value2;
r5 = r5 && !value3;
length = eligibleUsers.length;
return {type: 'user', props: {type: Reflect.apply(getRelationshipType, relationshipStoreBinding, [id]),
user: property, onPress: onSelectUser, selected: value2, disabled: r5, mode: UserRowModes.TOGGLE,
start: row === 0, end: row === length - 1}};
}
}
}
global.__d(_fun93353, 12179, [3793, 7690, 2]) /* metro module 12179, dependencies: [3793, 7690, 2] */;
@@ -1,154 +1,227 @@
/* Metro module 12180; source: modules/premium/referral_program/native/ReferralProgramShareConfirmationActionSheet.tsx; dependencies: [27, 661, 33, 4501, 697, 3995, 7066, 1305, 4573, 1244, 4578, 6682, 4080, 4603, 1948, 6275, 6758, 4572, 5473, 6766, 2] */
import Native from '../../../../external/discord_common/js/packages/tokens/native.tsx'; /* Metro dependency 697 */
import HelpdeskUtils from '../../../../utils/HelpdeskUtils.tsx'; /* Metro dependency 1948 */
import UserUtils from '../../../../utils/UserUtils.tsx'; /* Metro dependency 3995 */
import ActionSheetActionCreators from '../../../action_sheet/native/ActionSheetActionCreators.tsx'; /* Metro dependency 4080 */
import ChannelActionCreators from '../../../../actions/ChannelActionCreators.tsx'; /* Metro dependency 4603 */
import * as FileImportTrackerModule from '../../../../by-id/module-00002-FileImportTracker.js'; /* Metro dependency 2 */
import * as ReactNativeModule from '../../../../by-id/module-00027-ReactNative.js'; /* Metro dependency 27 */
import * as JsxRuntimeModule from '../../../../by-id/module-00033-JsxRuntime.js'; /* Metro dependency 33 */
import * as ConstantsModule from '../../../../Constants.tsx'; /* Metro dependency 661 */
import * as NativeModule from '../../../../design/void/native.tsx'; /* Metro dependency 1305 */
import * as StackNativeModule from '../../../../design/components/Stack/native/Stack.native.tsx'; /* Metro dependency 4572 */
import * as TextModule from '../../../../design/components/Text/native/Text.tsx'; /* Metro dependency 4573 */
import * as ButtonNativeModule from '../../../../design/components/Button/native/Button.native.tsx'; /* Metro dependency 4578 */
import * as NativeModule2 from '../../../../design/assets/native.tsx'; /* Metro dependency 5473 */
import * as BottomSheetNativeModule from '../../../../design/components/Sheet/native/BottomSheet.native.tsx'; /* Metro dependency 6275 */
import * as ChatIconModule from '../../../../design/components/Icon/native/redesign/generated/ChatIcon.tsx'; /* Metro dependency 6682 */
import * as BottomSheetTitleHeaderNativeModule from '../../../../design/components/Sheet/native/BottomSheetTitleHeader.native.tsx'; /* Metro dependency 6758 */
import * as TextWithIOSLinkWorkaroundModule from '../../../a11y/native/TextWithIOSLinkWorkaround.tsx'; /* Metro dependency 6766 */
import * as ReferralTrialActionCreatorsModule from '../../ReferralTrialActionCreators.tsx'; /* Metro dependency 7066 */
function _fun93355(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#93355, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12366:6, offset: 0x020b06b1, size: 623 bytes, params: 8, frame: 24
var object2;
const env0_0 = require;
const Object = global.Object;
Object.defineProperty(exports, '__esModule', {value: true});
const env0_3 = (require(27) /* metro dependency 27 */).View;
const env0_4 = (require(661) /* metro dependency 661: Constants */).HelpdeskArticles;
let value = require(33) /* metro dependency 33 */;
let value = JsxRuntimeModule;
const env0_5 = value.jsx;
const env0_6 = value.Fragment;
const env0_7 = value.jsxs;
value = require(4501) /* metro dependency 4501: createStyles */;
const createStyles = value.createStyles;
object2 = {};
object = {};
let PX_16 = (importDefault(697) /* metro dependency 697: native */).space.PX_16;
object2.content = {paddingHorizontal: PX_16};
object2.headerAsset = {alignSelf: 'center'};
const object3 = {};
object.content = {paddingHorizontal: PX_16};
object.headerAsset = {alignSelf: 'center'};
const object4 = {};
PX_16 = (importDefault(697) /* metro dependency 697: native */).space.PX_16;
object3.marginTop = PX_16;
object3.alignSelf = 'center';
object4.marginTop = PX_16;
object4.alignSelf = 'center';
let PX_8 = (importDefault(697) /* metro dependency 697: native */).space.PX_8;
object3.paddingHorizontal = PX_8;
object3.textAlign = 'center';
object2.header = object3;
const object8 = {textAlign: 'center'};
object4.paddingHorizontal = PX_8;
object4.textAlign = 'center';
object.header = object4;
const object5 = {textAlign: 'center'};
PX_8 = (importDefault(697) /* metro dependency 697: native */).space.PX_8;
object8.paddingHorizontal = PX_8;
object5.paddingHorizontal = PX_8;
PX_8 = (importDefault(697) /* metro dependency 697: native */).space.PX_8;
object8.marginTop = PX_8;
object2.subheader = object8;
const object9 = {};
object5.marginTop = PX_8;
object.subheader = object5;
const object6 = {};
PX_16 = (importDefault(697) /* metro dependency 697: native */).space.PX_16;
object9.gap = PX_16;
object6.gap = PX_16;
PX_16 = (importDefault(697) /* metro dependency 697: native */).space.PX_16;
object9.marginTop = PX_16;
object9.paddingBottom = 21;
object2.recipientContainer = object9;
const object10 = {'flexDirection': 'row', 'alignItems': 'center'};
object6.marginTop = PX_16;
object6.paddingBottom = 21;
object.recipientContainer = object6;
const object7 = {'flexDirection': 'row', 'alignItems': 'center'};
let PX_12 = (importDefault(697) /* metro dependency 697: native */).space.PX_12;
object10.padding = PX_12;
object7.padding = PX_12;
PX_12 = (importDefault(697) /* metro dependency 697: native */).space.PX_12;
object10.gap = PX_12;
object10.borderRadius = (importDefault(697) /* metro dependency 697: native */).radii.md;
object10.borderWidth = 1;
object7.gap = PX_12;
object7.borderRadius = (importDefault(697) /* metro dependency 697: native */).radii.md;
object7.borderWidth = 1;
const BORDER_MUTED = (importDefault(697) /* metro dependency 697: native */).colors.BORDER_MUTED;
object10.borderColor = BORDER_MUTED;
object2.recipientRow = object10;
object2.recipientDisplayName = {flex: 1};
object2.erroredAvatar = {opacity: 0.5};
object2.avatarContainer = {'alignSelf': 'center', 'justifyContent': 'center'};
const env0_8 = Reflect.apply(createStyles, value, [object2]);
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/premium/referral_program/native/ReferralProgramShareConfirmationActionSheet.tsx');
object7.borderColor = BORDER_MUTED;
object.recipientRow = object7;
object.recipientDisplayName = {flex: 1};
object.erroredAvatar = {opacity: 0.5};
object.avatarContainer = {'alignSelf': 'center', 'justifyContent': 'center'};
const env0_8 = Reflect.apply(createStyles, value, [object]);
(FileImportTrackerModule).fileFinishedImporting('modules/premium/referral_program/native/ReferralProgramShareConfirmationActionSheet.tsx');
exports.default = ReferralProgramShareConfirmationActionSheet;
}
function SharedUser({user, trialCreationResult}) { // fn#93356, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12366:897, offset: 0x020b0920, size: 698 bytes, params: 2, frame: 30
var r5;
const Text = (TextModule).Text;
var jsxRuntimeEnv0_6Binding;
var items3;
const intl = (require(1244) /* metro dependency 1244: indexNative */).intl;
const styles = useStyles();
const name = (UserUtils).getName(user);
const CreateReferralStatus = (ReferralTrialActionCreatorsModule).CreateReferralStatus;
const FAIL = CreateReferralStatus.FAIL;
const value3 = trialCreationResult === FAIL;
const Avatar = (NativeModule).Avatar;
const items2 = [styles.avatarContainer];
items2[1] = value3 && styles.erroredAvatar;
const AvatarSizes = (NativeModule).AvatarSizes;
const REFRESH_MEDIUM_32 = AvatarSizes.REFRESH_MEDIUM_32;
const avatar = (
<Avatar
style={items2}
size={REFRESH_MEDIUM_32}
user={user}
guildId={undefined}
/>
);
if (value3) {
jsxRuntimeEnv0_6Binding = jsxRuntimeEnv0_6;
items3 = [
<Text
variant="text-md/medium"
color="text-muted"
style={styles.recipientDisplayName}
>
{name}
</Text>,
];
items3[1] = (
<Text variant="text-md/medium" color="text-muted">
{intl.format((require(1244) /* metro dependency 1244: indexNative */).t.RO3T4B, {userName: name})}
</Text>
);
r5 = (
<>
{items3}
</>
);
} else {
r5 = (
<Text
variant="text-md/medium"
color="text-strong"
style={styles.recipientDisplayName}
>
{name}
</Text>
);
}
const Button = (ButtonNativeModule).Button;
const buttonProps = {'variant': 'secondary', 'size': 'sm',
text: intl.string((require(1244) /* metro dependency 1244: indexNative */).t['g33r/P'])};
const ChatIcon = (ChatIconModule).ChatIcon;
const CONTROL_SECONDARY_TEXT_DEFAULT = (Native).colors.CONTROL_SECONDARY_TEXT_DEFAULT;
buttonProps.icon = <ChatIcon size="xs" color={CONTROL_SECONDARY_TEXT_DEFAULT} />;
buttonProps.onPress = onPress_93357;
return (
<View style={styles.recipientRow}>
{avatar}
{r5}
<Button {...buttonProps} />
</View>
);
function SharedUserOnPress() { // fn#93357, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12366:1733, owner: SharedUser.onPress, offset: 0x020b0bda, size: 79 bytes, params: 1, frame: 13
const value = environment.__proto__;
(ActionSheetActionCreators).hideActionSheet();
(ChannelActionCreators).openPrivateChannel({recipientIds: user.id});
}
function SharedUser({user, trialCreationResult}) { // fn#93356, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12366:897, offset: 0x020b0920, size: 698 bytes, params: 2, frame: 30
var r5;
const Text = (require(4573) /* metro dependency 4573: Text */).Text;
var jsxRuntimeEnv0_6Binding;
var items3;
const intl = (require(1244) /* metro dependency 1244: indexNative */).intl;
const styles = useStyles();
const name = (importDefault(3995) /* metro dependency 3995: UserUtils */).getName(user);
const CreateReferralStatus = (require(7066) /* metro dependency 7066: ReferralTrialActionCreators */).CreateReferralStatus;
const FAIL = CreateReferralStatus.FAIL;
const value3 = trialCreationResult === FAIL;
const Avatar = (require(1305) /* metro dependency 1305: native */).Avatar;
const items2 = [styles.avatarContainer];
items2[1] = value3 && styles.erroredAvatar;
const AvatarSizes = (require(1305) /* metro dependency 1305: native */).AvatarSizes;
const REFRESH_MEDIUM_32 = AvatarSizes.REFRESH_MEDIUM_32;
const avatar = <Avatar style={items2} size={REFRESH_MEDIUM_32} user={user} guildId={undefined} />;
if (value3) {
jsxRuntimeEnv0_6Binding = jsxRuntimeEnv0_6;
items3 = [<Text variant="text-md/medium" color="text-muted" style={styles.recipientDisplayName}>{name}</Text>];
items3[1] = <Text variant="text-md/medium" color="text-muted">{intl.format((require(1244) /* metro dependency 1244: indexNative */).t.RO3T4B,
{userName: name})}</Text>;
r5 = <>{items3}</>;
} else {
r5 = <Text variant="text-md/medium" color="text-strong" style={styles.recipientDisplayName}>{name}</Text>;
}
const Button = (require(4578) /* metro dependency 4578: ButtonNative */).Button;
const buttonProps = {'variant': 'secondary', 'size': 'sm',
text: intl.string((require(1244) /* metro dependency 1244: indexNative */).t['g33r/P'])};
const ChatIcon = (require(6682) /* metro dependency 6682: ChatIcon */).ChatIcon;
const CONTROL_SECONDARY_TEXT_DEFAULT = (importDefault(697) /* metro dependency 697: native */).colors.CONTROL_SECONDARY_TEXT_DEFAULT;
buttonProps.icon = <ChatIcon size="xs" color={CONTROL_SECONDARY_TEXT_DEFAULT} />;
buttonProps.onPress = onPress_93357;
return (
<View style={styles.recipientRow}>
{avatar}
{r5}
<Button {...buttonProps} />
</View>
);
}
function ReferralProgramShareConfirmationActionSheet({selectedUsers, trialCreationResult}) { // fn#93358, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12366:1952, offset: 0x020b0c29, size: 687 bytes, params: 2, frame: 31
const intl = (require(1244) /* metro dependency 1244: indexNative */).intl;
const styles = useStyles();
let Array = global.Array;
const value2 = Array.from(trialCreationResult.values());
const r19 = value2.filter(function(a0) {
var SUCCESS = require(dependencyMap[6]).CreateReferralStatus.SUCCESS;
return a0 === SUCCESS;
}).length === 0 ? intl.string((require(1244) /* metro dependency 1244: indexNative */).t['7VBEue']) : intl.string((require(1244) /* metro dependency 1244: indexNative */).t.tKCltd);
const format = intl.format;
const AwGSWl = (require(1244) /* metro dependency 1244: indexNative */).t.AwGSWl;
const defaultImport = importDefault(1948) /* metro dependency 1948: HelpdeskUtils */;
const getArticleURL = defaultImport.getArticleURL;
const REFERRAL_PROGRAM = HelpdeskArticles.REFERRAL_PROGRAM;
const value5 = Reflect.apply(format, intl, [AwGSWl, {helpdeskArticle: Reflect.apply(getArticleURL, defaultImport,
[REFERRAL_PROGRAM])}]);
const BottomSheet = (require(6275) /* metro dependency 6275: BottomSheetNative */).BottomSheet;
const bottomSheetProps = {startExpanded: true, contentStyles: styles.content};
const BottomSheetTitleHeader = (require(6758) /* metro dependency 6758: BottomSheetTitleHeaderNative */).BottomSheetTitleHeader;
bottomSheetProps.header = <BottomSheetTitleHeader title={null} />;
const Stack = (require(4572) /* metro dependency 4572: StackNative */).Stack;
const FistBumpSpotIllustration = (require(5473) /* metro dependency 5473: native */).FistBumpSpotIllustration;
const items2 = [<View style={styles.headerAsset}><FistBumpSpotIllustration /></View>];
const Text = (require(4573) /* metro dependency 4573: Text */).Text;
items2[1] = <Text variant="heading-lg/bold" color="mobile-text-heading-primary" style={styles.header}>{r19}</Text>;
const TextWithIOSLinkWorkaround = (require(6766) /* metro dependency 6766: TextWithIOSLinkWorkaround */).TextWithIOSLinkWorkaround;
items2[2] = <TextWithIOSLinkWorkaround variant="text-md/medium" color="text-default" style={styles.subheader}>{value5}</TextWithIOSLinkWorkaround>;
Array = global.Array;
items2[3] = <View style={styles.recipientContainer}>{Array.from(selectedUsers).map(_fun93360)}</View>;
return (
<BottomSheet {...bottomSheetProps}>
<Stack>
{items2}
</Stack>
</BottomSheet>
);
}
function ReferralProgramShareConfirmationActionSheet({selectedUsers, trialCreationResult}) { // fn#93358, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12366:1952, offset: 0x020b0c29, size: 687 bytes, params: 2, frame: 31
const intl = (require(1244) /* metro dependency 1244: indexNative */).intl;
const styles = useStyles();
let Array = global.Array;
const value2 = Array.from(trialCreationResult.values());
const r19 = value2.filter(function(a0) {
var SUCCESS = require(dependencyMap[6]).CreateReferralStatus.SUCCESS;
return a0 === SUCCESS;
}).length === 0 ? intl.string((require(1244) /* metro dependency 1244: indexNative */).t['7VBEue']) : intl.string((require(1244) /* metro dependency 1244: indexNative */).t.tKCltd);
const format = intl.format;
const AwGSWl = (require(1244) /* metro dependency 1244: indexNative */).t.AwGSWl;
const defaultImport = HelpdeskUtils;
const getArticleURL = defaultImport.getArticleURL;
const REFERRAL_PROGRAM = HelpdeskArticles.REFERRAL_PROGRAM;
const value5 = Reflect.apply(format, intl, [AwGSWl, {helpdeskArticle: Reflect.apply(getArticleURL, defaultImport,
[REFERRAL_PROGRAM])}]);
const BottomSheet = (BottomSheetNativeModule).BottomSheet;
const bottomSheetProps = {startExpanded: true, contentStyles: styles.content};
const BottomSheetTitleHeader = (BottomSheetTitleHeaderNativeModule).BottomSheetTitleHeader;
bottomSheetProps.header = <BottomSheetTitleHeader title={null} />;
const Stack = (StackNativeModule).Stack;
const FistBumpSpotIllustration = (NativeModule2).FistBumpSpotIllustration;
const items2 = [
<View style={styles.headerAsset}>
<FistBumpSpotIllustration />
</View>,
];
const Text = (TextModule).Text;
items2[1] = (
<Text
variant="heading-lg/bold"
color="mobile-text-heading-primary"
style={styles.header}
>
{r19}
</Text>
);
const TextWithIOSLinkWorkaround = (TextWithIOSLinkWorkaroundModule).TextWithIOSLinkWorkaround;
items2[2] = (
<TextWithIOSLinkWorkaround
variant="text-md/medium"
color="text-default"
style={styles.subheader}
>
{value5}
</TextWithIOSLinkWorkaround>
);
Array = global.Array;
items2[3] = (
<View style={styles.recipientContainer}>
{Array.from(selectedUsers).map(_fun93360)}
</View>
);
return (
<BottomSheet {...bottomSheetProps}>
<Stack>
{items2}
</Stack>
</BottomSheet>
);
function _fun93360(a0) { // fn#93360, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12366:2853, offset: 0x020b0f06, size: 63 bytes, params: 2, frame: 17
return (
<SharedUser
user={a0}
trialCreationResult={trialCreationResult.get(a0.id)}
key={a0.id}
/>
);
}
function SharedUserOnPress() { // fn#93357, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12366:1733, owner: SharedUser.onPress, offset: 0x020b0bda, size: 79 bytes, params: 1, frame: 13
const value = environment.__proto__;
(importDefault(4080) /* metro dependency 4080: ActionSheetActionCreators */).hideActionSheet();
(importDefault(4603) /* metro dependency 4603: ChannelActionCreators */).openPrivateChannel({recipientIds: user.id});
}
}
function _fun93360(a0) { // fn#93360, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12366:2853, offset: 0x020b0f06, size: 63 bytes, params: 2, frame: 17
return (
<SharedUser
user={a0}
trialCreationResult={trialCreationResult.get(a0.id)}
key={a0.id}
/>
);
}
global.__d(_fun93355, 12180, [27, 661, 33, 4501, 697, 3995, 7066, 1305, 4573, 1244, 4578, 6682, 4080, 4603, 1948,
6275, 6758, 4572, 5473, 6766,
2]) /* metro module 12180, dependencies: [27, 661, 33, 4501, 697, 3995, 7066, 1305, 4573, 1244, 4578, 6682, 4080, 4603, 1948, 6275, 6758, 4572, 5473, 6766, 2] */;