715 lines
37 KiB
TypeScript
715 lines
37 KiB
TypeScript
/* Metro module 11784; source: modules/messages/native/DMMessageStickerGreeting.tsx; dependencies: [5, 57, 31, 27, 6583, 4814, 1878, 33, 4501, 697, 3963, 3860, 4000, 3857, 11785, 11786, 7067, 1244, 566, 671, 3995, 11787, 11050, 4017, 4504, 1305, 11049, 4589, 5278, 10970, 4573, 4578, 2] */
|
|
import Module00005 from '../../../by-id/module-00005.js'; /* Metro dependency 5 */
|
|
import Module00057 from '../../../by-id/module-00057.js'; /* Metro dependency 57 */
|
|
import UserStore from '../../../stores/UserStore.tsx'; /* Metro dependency 1878 */
|
|
import MessageStore from '../../../stores/MessageStore.tsx'; /* Metro dependency 4814 */
|
|
import StickersStore from '../../stickers/StickersStore.tsx'; /* Metro dependency 6583 */
|
|
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 JsxRuntimeModule from '../../../by-id/module-00033-JsxRuntime.js'; /* Metro dependency 33 */
|
|
import * as NativeModule from '../../../design/void/native.tsx'; /* Metro dependency 1305 */
|
|
import * as ClientThemesUtilsModule from '../../client_themes/native/ClientThemesUtils.tsx'; /* Metro dependency 3963 */
|
|
import * as ReanimatedRexportModule from '../../reanimated/ReanimatedRexport.tsx'; /* Metro dependency 4017 */
|
|
import * as CreateStylesModule from '../../../design/components/Styles/native/createStyles.tsx'; /* Metro dependency 4501 */
|
|
import * as TimingModule from '../../../design/animation/reanimated/timing/timing.tsx'; /* Metro dependency 4504 */
|
|
import * as StickersHooksModule from '../../stickers/StickersHooks.tsx'; /* Metro dependency 11049 */
|
|
import * as UseShowConvoStarterInDMModule from '../useShowConvoStarterInDM.tsx'; /* Metro dependency 11787 */
|
|
|
|
function _fun90262(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#90262, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:11970:6, offset: 0x020320b3, size: 339 bytes, params: 8, frame: 19
|
|
const env0_0 = require;
|
|
const Object = global.Object;
|
|
Object.defineProperty(exports, '__esModule', {value: true});
|
|
const env0_13 = (CreateStylesModule).createStyles(_fun90263);
|
|
const GradientPercentage = (ClientThemesUtilsModule).GradientPercentage;
|
|
const env0_14 = GradientPercentage.END;
|
|
object = {code: "function DMMessageStickerGreetingTsx1(){const{styles,isRendered,hasInputText,hasMessages,HEIGHT_COMPACT,HEIGHT_FULL,withDelay,withTiming,STANDARD_EASING}=this.__closure;const gradientOverlayOffset=styles.gradient.height;const hasHeight=isRendered&&!hasInputText;const heightExpanded=(hasMessages?HEIGHT_COMPACT:HEIGHT_FULL)-1;const targetHeight=hasHeight?heightExpanded+gradientOverlayOffset:0;const targetMargin=hasHeight?-gradientOverlayOffset:0;const generateAnimationConfig=function(value){return withDelay(300,withTiming(value,{easing:STANDARD_EASING,duration:250}));};return{justifyContent:'flex-end',overflow:'hidden',marginTop:generateAnimationConfig(targetMargin),height:generateAnimationConfig(targetHeight)};}"};
|
|
(FileImportTrackerModule).fileFinishedImporting('modules/messages/native/DMMessageStickerGreeting.tsx');
|
|
exports.default = DMMessageStickerGreeting;
|
|
function _fun90263(a0) { // fn#90263, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:11970:235, offset: 0x02032206, size: 207 bytes, params: 2, frame: 15
|
|
const value = a0;
|
|
const object = {};
|
|
object.container = {'backgroundColor': null, 'alignItems': 'center', 'paddingHorizontal': 16, 'paddingBottom': 16,
|
|
'paddingTop': 8,
|
|
backgroundColor: value ?? (importDefault(697) /* metro dependency 697: native */).colors.BACKGROUND_BASE_LOWER};
|
|
object.stickerContainer = {paddingBottom: 16};
|
|
const object4 = {'flexDirection': 'row', 'backgroundColor': null, 'justifyContent': 'center',
|
|
'alignItems': 'center', 'gap': 8, 'height': 48, 'paddingHorizontal': 16};
|
|
const BACKGROUND_BASE_LOWEST = (importDefault(697) /* metro dependency 697: native */).colors.BACKGROUND_BASE_LOWEST;
|
|
object4.backgroundColor = BACKGROUND_BASE_LOWEST;
|
|
object4.borderRadius = (importDefault(697) /* metro dependency 697: native */).radii.xxl;
|
|
object.toastContainer = object4;
|
|
object.toastContent = {lineHeight: 20};
|
|
object.gradient = {'position': 'absolute', 'right': 0, 'left': 0, 'top': 0, 'height': 30};
|
|
return object;
|
|
}
|
|
|
|
function DMMessageStickerGreeting({channel, hasInputText}) { // fn#90264, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:11970:1610, offset: 0x020322d5, size: 1339 bytes, params: 2, frame: 38
|
|
var r0;
|
|
var r9;
|
|
const intl = (require(1244) /* metro dependency 1244: indexNative */).intl;
|
|
var View2;
|
|
var object2;
|
|
var PressableOpacity;
|
|
var items3;
|
|
const useGradientValue = ClientThemesUtilsModule.useGradientValue;
|
|
const styles = useStyles(Reflect.apply(useGradientValue, ClientThemesUtilsModule, [END]));
|
|
const value3 = (require(566) /* metro dependency 566: flux */).useStateFromStores([MessageStore], _fun90265);
|
|
const user = (require(566) /* metro dependency 566: flux */).useStateFromStores([UserStore], function() {
|
|
return UserStore.getUser(channel.getRecipientId());
|
|
});
|
|
const value7 = intl.formatToPlainString((require(1244) /* metro dependency 1244: indexNative */).t.m0zYbV,
|
|
{username: (importDefault(3995) /* metro dependency 3995: UserUtils */).useName(user) ?? intl.string((require(1244) /* metro dependency 1244: indexNative */).t.y1Wu2f)});
|
|
const value8 = (UseShowConvoStarterInDMModule).useShowConvoStarterInDM(channel);
|
|
const value9 = (require(566) /* metro dependency 566: flux */).useStateFromStores([StickersStore], _fun90268,
|
|
[value8]);
|
|
undefined.useEffect(_fun90269, [value8]);
|
|
const value10 = useHandleWavePress(channel);
|
|
const {isRendered, setIsRendered} = useIsRendered();
|
|
const useAnimatedStyle = ReanimatedRexportModule.useAnimatedStyle;
|
|
const DMMessageStickerGreetingX2 = DMMessageStickerGreetingX;
|
|
object = {styles: styles, isRendered: isRendered, hasInputText: hasInputText, hasMessages: value3,
|
|
HEIGHT_COMPACT: 72, HEIGHT_FULL: 180};
|
|
object.withDelay = ReanimatedRexportModule.withDelay;
|
|
object.withTiming = (require(4504) /* metro dependency 4504: timing */).withTiming;
|
|
const STANDARD_EASING = (NativeModule).STANDARD_EASING;
|
|
object.STANDARD_EASING = STANDARD_EASING;
|
|
DMMessageStickerGreetingX2.__closure = object;
|
|
DMMessageStickerGreetingX2.__workletHash = 14002474476449;
|
|
DMMessageStickerGreetingX2.__initData = env0_15;
|
|
const value12 = Reflect.apply(useAnimatedStyle, ReanimatedRexportModule, [DMMessageStickerGreetingX2]);
|
|
const value14 = (require(3860) /* metro dependency 3860: useToken */).useToken(ClientThemesUtilsModule.useGradientValue(END) ?? (importDefault(697) /* metro dependency 697: native */).colors.BACKGROUND_BASE_LOWER);
|
|
object = [(require(4000) /* metro dependency 4000: ColorUtils */).hexWithOpacity(value14, 0), value14];
|
|
const value16 = (StickersHooksModule).useShouldAnimateSticker(false);
|
|
if (value8) {
|
|
View2 = (importDefault(4017) /* metro dependency 4017: ReanimatedRexport */).View;
|
|
object2 = {style: value12, onLayout: setIsRendered};
|
|
object = [
|
|
((Component) => <Component style={styles.gradient} colors={object} />)(importDefault(4589) /* metro dependency 4589 */),
|
|
|
|
|
|
];
|
|
var viewBindingProps = {style: styles.container};
|
|
if (value3) {
|
|
PressableOpacity = (require(5278) /* metro dependency 5278: Pressables */).PressableOpacity;
|
|
var pressableOpacityProps2 = {style: styles.toastContainer, accessibilityRole: 'button',
|
|
accessibilityLabel: intl.string((require(1244) /* metro dependency 1244: indexNative */).t.pJObYI),
|
|
onPress: value10};
|
|
items3 = [
|
|
value9 != null
|
|
? ((Component) => <Component sticker={value9} size={24} animated={value16} />)(importDefault(10970) /* metro dependency 10970: Sticker */)
|
|
: null,
|
|
];
|
|
items3[1] = ((Text) => <Text style={styles.toastContent} variant="text-md/bold">{value7}</Text>)((require(4573) /* metro dependency 4573: Text */).Text);
|
|
r9 = (
|
|
<PressableOpacity {...pressableOpacityProps2}>
|
|
{items3}
|
|
</PressableOpacity>
|
|
);
|
|
} else {
|
|
r9 = (
|
|
<>
|
|
{
|
|
value9 != null
|
|
? (
|
|
<View style={styles.stickerContainer}>
|
|
{((Component) => <Component sticker={value9} size={100} animated={value16} />)(importDefault(10970) /* metro dependency 10970: Sticker */)}
|
|
</View>
|
|
)
|
|
: null
|
|
}
|
|
{((Button) => <Button text={value7} onPress={value10} shrink />)((require(4578) /* metro dependency 4578: ButtonNative */).Button)}
|
|
</>
|
|
);
|
|
}
|
|
object[1] = (
|
|
<View {...viewBindingProps}>
|
|
{r9}
|
|
</View>
|
|
);
|
|
r0 = (
|
|
<View2 {...object2}>
|
|
{object}
|
|
</View2>
|
|
);
|
|
} else {
|
|
r0 = null;
|
|
}
|
|
return r0;
|
|
function _fun90265() { // fn#90265, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:11970:1751, offset: 0x02032810, size: 62 bytes, params: 1, frame: 11
|
|
var environment;
|
|
let value = environment.__proto__;
|
|
value = MessageStore.getMessages(channel.id);
|
|
return value.filter(function({type}) {
|
|
return type !== require(dependencyMap[19]).MessageTypes.FRIEND_REQUEST_ACCEPTED;
|
|
}).length > 0;
|
|
}
|
|
|
|
function _fun90268() { // fn#90268, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:11970:2140, offset: 0x020328a6, size: 38 bytes, params: 1, frame: 12
|
|
var r0;
|
|
let value = null;
|
|
if (Module00057) {
|
|
value = environment.__proto__;
|
|
value = StickersStore.getStickerById('749054660769218631');
|
|
r0 = value;
|
|
} else {
|
|
r0 = value;
|
|
}
|
|
return r0;
|
|
}
|
|
|
|
function _fun90269() { // fn#90269, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:11970:2190, offset: 0x020328cc, size: 59 bytes, params: 1, frame: 13
|
|
var value;
|
|
if (Module00057) {
|
|
value = environment.__proto__;
|
|
value = require(11050) /* metro dependency 11050: StickersActionCreators */;
|
|
value.fetchStickerPack('847199849233514549', true);
|
|
}
|
|
}
|
|
|
|
function useHandleWavePress(a0) { // fn#90270, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:11970:2264, owner: DMMessageStickerGreeting.useHandleWavePress, offset: 0x02032907, size: 179 bytes, params: 2, frame: 21
|
|
var environment;
|
|
const env0_0 = a0;
|
|
const value = environment.__proto__;
|
|
const binding = env1_5;
|
|
let useState = binding.useState;
|
|
const value2 = Reflect.apply(useState, binding, [null]);
|
|
const binding2 = env1_4;
|
|
const value3 = binding2(value2, 2);
|
|
const property = value3[0];
|
|
const env0_2 = value3[1];
|
|
useState = binding.useState;
|
|
const value4 = binding2(Reflect.apply(useState, binding, [false]), 2);
|
|
const property2 = value4[0];
|
|
const env0_4 = value4[1];
|
|
binding.useEffect(_fun90271, [a0.id]);
|
|
return binding.useCallback(env1_3(_fun90273), [property2, property, a0.id]);
|
|
function _fun90271() { // fn#90271, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:11970:2401, offset: 0x0100fa88, size: 18 bytes, params: 1, frame: 11
|
|
env0_2(null);
|
|
}
|
|
|
|
function* _fun90273() { // fn#90273, original name: ?anon_0_, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:11970:2441, offset: 0x020329c5, size: 316 bytes, params: 1, frame: 21
|
|
var environment;
|
|
var r4;
|
|
var binding;
|
|
var binding2;
|
|
var property;
|
|
var value4;
|
|
var trackWaveCtaClicked;
|
|
var object;
|
|
var channelBinding;
|
|
var id;
|
|
var value5;
|
|
var sendGreetMessage;
|
|
var value6;
|
|
var value7;
|
|
var value8;
|
|
var error;
|
|
var ok;
|
|
var status;
|
|
var value9;
|
|
var binding3;
|
|
var intl;
|
|
var string;
|
|
var t;
|
|
var Whhv4w;
|
|
if (true) {
|
|
value = environment.__proto__;
|
|
if (!env1_3) {
|
|
env1_4(true);
|
|
var showErrorToast2 = showErrorToast;
|
|
if (hasInputText !== null) {
|
|
env1_4(false);
|
|
return showErrorToast2(hasInputText);
|
|
}
|
|
try {
|
|
binding = env3_0;
|
|
} catch (error) {
|
|
ok = error.ok;
|
|
if (ok) {
|
|
r4 = ok;
|
|
} else {
|
|
status = error.status;
|
|
value9 = status !== 429;
|
|
r4 = value9;
|
|
}
|
|
if (!r4) {
|
|
binding = env3_0;
|
|
binding3 = env3_2;
|
|
intl = binding(binding3[17]).intl;
|
|
string = intl.string;
|
|
t = binding(binding3[17]).t;
|
|
Whhv4w = t.Whhv4w;
|
|
showErrorToast2(Reflect.apply(string, intl, [Whhv4w]));
|
|
}
|
|
env1_4(false);
|
|
return undefined;
|
|
}
|
|
try {
|
|
binding2 = env3_2;
|
|
} catch (error) {
|
|
ok = error.ok;
|
|
if (ok) {
|
|
r4 = ok;
|
|
} else {
|
|
status = error.status;
|
|
value9 = status !== 429;
|
|
r4 = value9;
|
|
}
|
|
if (!r4) {
|
|
binding = env3_0;
|
|
binding3 = env3_2;
|
|
intl = binding(binding3[17]).intl;
|
|
string = intl.string;
|
|
t = binding(binding3[17]).t;
|
|
Whhv4w = t.Whhv4w;
|
|
showErrorToast2(Reflect.apply(string, intl, [Whhv4w]));
|
|
}
|
|
env1_4(false);
|
|
return undefined;
|
|
}
|
|
try {
|
|
property = binding2[15];
|
|
} catch (error) {
|
|
ok = error.ok;
|
|
if (ok) {
|
|
r4 = ok;
|
|
} else {
|
|
status = error.status;
|
|
value9 = status !== 429;
|
|
r4 = value9;
|
|
}
|
|
if (!r4) {
|
|
binding = env3_0;
|
|
binding3 = env3_2;
|
|
intl = binding(binding3[17]).intl;
|
|
string = intl.string;
|
|
t = binding(binding3[17]).t;
|
|
Whhv4w = t.Whhv4w;
|
|
showErrorToast2(Reflect.apply(string, intl, [Whhv4w]));
|
|
}
|
|
env1_4(false);
|
|
return undefined;
|
|
}
|
|
try {
|
|
value4 = binding(property);
|
|
} catch (error) {
|
|
ok = error.ok;
|
|
if (ok) {
|
|
r4 = ok;
|
|
} else {
|
|
status = error.status;
|
|
value9 = status !== 429;
|
|
r4 = value9;
|
|
}
|
|
if (!r4) {
|
|
binding = env3_0;
|
|
binding3 = env3_2;
|
|
intl = binding(binding3[17]).intl;
|
|
string = intl.string;
|
|
t = binding(binding3[17]).t;
|
|
Whhv4w = t.Whhv4w;
|
|
showErrorToast2(Reflect.apply(string, intl, [Whhv4w]));
|
|
}
|
|
env1_4(false);
|
|
return undefined;
|
|
}
|
|
try {
|
|
trackWaveCtaClicked = value4.trackWaveCtaClicked;
|
|
} catch (error) {
|
|
ok = error.ok;
|
|
if (ok) {
|
|
r4 = ok;
|
|
} else {
|
|
status = error.status;
|
|
value9 = status !== 429;
|
|
r4 = value9;
|
|
}
|
|
if (!r4) {
|
|
binding = env3_0;
|
|
binding3 = env3_2;
|
|
intl = binding(binding3[17]).intl;
|
|
string = intl.string;
|
|
t = binding(binding3[17]).t;
|
|
Whhv4w = t.Whhv4w;
|
|
showErrorToast2(Reflect.apply(string, intl, [Whhv4w]));
|
|
}
|
|
env1_4(false);
|
|
return undefined;
|
|
}
|
|
try {
|
|
object = {};
|
|
} catch (error) {
|
|
ok = error.ok;
|
|
if (ok) {
|
|
r4 = ok;
|
|
} else {
|
|
status = error.status;
|
|
value9 = status !== 429;
|
|
r4 = value9;
|
|
}
|
|
if (!r4) {
|
|
binding = env3_0;
|
|
binding3 = env3_2;
|
|
intl = binding(binding3[17]).intl;
|
|
string = intl.string;
|
|
t = binding(binding3[17]).t;
|
|
Whhv4w = t.Whhv4w;
|
|
showErrorToast2(Reflect.apply(string, intl, [Whhv4w]));
|
|
}
|
|
env1_4(false);
|
|
return undefined;
|
|
}
|
|
try {
|
|
channelBinding = channel;
|
|
} catch (error) {
|
|
ok = error.ok;
|
|
if (ok) {
|
|
r4 = ok;
|
|
} else {
|
|
status = error.status;
|
|
value9 = status !== 429;
|
|
r4 = value9;
|
|
}
|
|
if (!r4) {
|
|
binding = env3_0;
|
|
binding3 = env3_2;
|
|
intl = binding(binding3[17]).intl;
|
|
string = intl.string;
|
|
t = binding(binding3[17]).t;
|
|
Whhv4w = t.Whhv4w;
|
|
showErrorToast2(Reflect.apply(string, intl, [Whhv4w]));
|
|
}
|
|
env1_4(false);
|
|
return undefined;
|
|
}
|
|
try {
|
|
id = channelBinding.id;
|
|
} catch (error) {
|
|
ok = error.ok;
|
|
if (ok) {
|
|
r4 = ok;
|
|
} else {
|
|
status = error.status;
|
|
value9 = status !== 429;
|
|
r4 = value9;
|
|
}
|
|
if (!r4) {
|
|
binding = env3_0;
|
|
binding3 = env3_2;
|
|
intl = binding(binding3[17]).intl;
|
|
string = intl.string;
|
|
t = binding(binding3[17]).t;
|
|
Whhv4w = t.Whhv4w;
|
|
showErrorToast2(Reflect.apply(string, intl, [Whhv4w]));
|
|
}
|
|
env1_4(false);
|
|
return undefined;
|
|
}
|
|
try {
|
|
object.channelId = id;
|
|
} catch (error) {
|
|
ok = error.ok;
|
|
if (ok) {
|
|
r4 = ok;
|
|
} else {
|
|
status = error.status;
|
|
value9 = status !== 429;
|
|
r4 = value9;
|
|
}
|
|
if (!r4) {
|
|
binding = env3_0;
|
|
binding3 = env3_2;
|
|
intl = binding(binding3[17]).intl;
|
|
string = intl.string;
|
|
t = binding(binding3[17]).t;
|
|
Whhv4w = t.Whhv4w;
|
|
showErrorToast2(Reflect.apply(string, intl, [Whhv4w]));
|
|
}
|
|
env1_4(false);
|
|
return undefined;
|
|
}
|
|
try {
|
|
object.source = 'In-channel greet';
|
|
} catch (error) {
|
|
ok = error.ok;
|
|
if (ok) {
|
|
r4 = ok;
|
|
} else {
|
|
status = error.status;
|
|
value9 = status !== 429;
|
|
r4 = value9;
|
|
}
|
|
if (!r4) {
|
|
binding = env3_0;
|
|
binding3 = env3_2;
|
|
intl = binding(binding3[17]).intl;
|
|
string = intl.string;
|
|
t = binding(binding3[17]).t;
|
|
Whhv4w = t.Whhv4w;
|
|
showErrorToast2(Reflect.apply(string, intl, [Whhv4w]));
|
|
}
|
|
env1_4(false);
|
|
return undefined;
|
|
}
|
|
try {
|
|
Reflect.apply(trackWaveCtaClicked, value4, [object]);
|
|
} catch (error) {
|
|
ok = error.ok;
|
|
if (ok) {
|
|
r4 = ok;
|
|
} else {
|
|
status = error.status;
|
|
value9 = status !== 429;
|
|
r4 = value9;
|
|
}
|
|
if (!r4) {
|
|
binding = env3_0;
|
|
binding3 = env3_2;
|
|
intl = binding(binding3[17]).intl;
|
|
string = intl.string;
|
|
t = binding(binding3[17]).t;
|
|
Whhv4w = t.Whhv4w;
|
|
showErrorToast2(Reflect.apply(string, intl, [Whhv4w]));
|
|
}
|
|
env1_4(false);
|
|
return undefined;
|
|
}
|
|
try {
|
|
binding = env3_1;
|
|
} catch (error) {
|
|
ok = error.ok;
|
|
if (ok) {
|
|
r4 = ok;
|
|
} else {
|
|
status = error.status;
|
|
value9 = status !== 429;
|
|
r4 = value9;
|
|
}
|
|
if (!r4) {
|
|
binding = env3_0;
|
|
binding3 = env3_2;
|
|
intl = binding(binding3[17]).intl;
|
|
string = intl.string;
|
|
t = binding(binding3[17]).t;
|
|
Whhv4w = t.Whhv4w;
|
|
showErrorToast2(Reflect.apply(string, intl, [Whhv4w]));
|
|
}
|
|
env1_4(false);
|
|
return undefined;
|
|
}
|
|
try {
|
|
property = binding2[16];
|
|
} catch (error) {
|
|
ok = error.ok;
|
|
if (ok) {
|
|
r4 = ok;
|
|
} else {
|
|
status = error.status;
|
|
value9 = status !== 429;
|
|
r4 = value9;
|
|
}
|
|
if (!r4) {
|
|
binding = env3_0;
|
|
binding3 = env3_2;
|
|
intl = binding(binding3[17]).intl;
|
|
string = intl.string;
|
|
t = binding(binding3[17]).t;
|
|
Whhv4w = t.Whhv4w;
|
|
showErrorToast2(Reflect.apply(string, intl, [Whhv4w]));
|
|
}
|
|
env1_4(false);
|
|
return undefined;
|
|
}
|
|
try {
|
|
value5 = binding(property);
|
|
} catch (error) {
|
|
ok = error.ok;
|
|
if (ok) {
|
|
r4 = ok;
|
|
} else {
|
|
status = error.status;
|
|
value9 = status !== 429;
|
|
r4 = value9;
|
|
}
|
|
if (!r4) {
|
|
binding = env3_0;
|
|
binding3 = env3_2;
|
|
intl = binding(binding3[17]).intl;
|
|
string = intl.string;
|
|
t = binding(binding3[17]).t;
|
|
Whhv4w = t.Whhv4w;
|
|
showErrorToast2(Reflect.apply(string, intl, [Whhv4w]));
|
|
}
|
|
env1_4(false);
|
|
return undefined;
|
|
}
|
|
try {
|
|
sendGreetMessage = value5.sendGreetMessage;
|
|
} catch (error) {
|
|
ok = error.ok;
|
|
if (ok) {
|
|
r4 = ok;
|
|
} else {
|
|
status = error.status;
|
|
value9 = status !== 429;
|
|
r4 = value9;
|
|
}
|
|
if (!r4) {
|
|
binding = env3_0;
|
|
binding3 = env3_2;
|
|
intl = binding(binding3[17]).intl;
|
|
string = intl.string;
|
|
t = binding(binding3[17]).t;
|
|
Whhv4w = t.Whhv4w;
|
|
showErrorToast2(Reflect.apply(string, intl, [Whhv4w]));
|
|
}
|
|
env1_4(false);
|
|
return undefined;
|
|
}
|
|
try {
|
|
id = channelBinding.id;
|
|
} catch (error) {
|
|
ok = error.ok;
|
|
if (ok) {
|
|
r4 = ok;
|
|
} else {
|
|
status = error.status;
|
|
value9 = status !== 429;
|
|
r4 = value9;
|
|
}
|
|
if (!r4) {
|
|
binding = env3_0;
|
|
binding3 = env3_2;
|
|
intl = binding(binding3[17]).intl;
|
|
string = intl.string;
|
|
t = binding(binding3[17]).t;
|
|
Whhv4w = t.Whhv4w;
|
|
showErrorToast2(Reflect.apply(string, intl, [Whhv4w]));
|
|
}
|
|
env1_4(false);
|
|
return undefined;
|
|
}
|
|
try {
|
|
value6 = Reflect.apply(sendGreetMessage, value5, [id, '749054660769218631']);
|
|
} catch (error) {
|
|
ok = error.ok;
|
|
if (ok) {
|
|
r4 = ok;
|
|
} else {
|
|
status = error.status;
|
|
value9 = status !== 429;
|
|
r4 = value9;
|
|
}
|
|
if (!r4) {
|
|
binding = env3_0;
|
|
binding3 = env3_2;
|
|
intl = binding(binding3[17]).intl;
|
|
string = intl.string;
|
|
t = binding(binding3[17]).t;
|
|
Whhv4w = t.Whhv4w;
|
|
showErrorToast2(Reflect.apply(string, intl, [Whhv4w]));
|
|
}
|
|
env1_4(false);
|
|
return undefined;
|
|
}
|
|
yield value6;
|
|
try {
|
|
value7 = undefined;
|
|
value8 = false;
|
|
} catch (error) {
|
|
ok = error.ok;
|
|
if (ok) {
|
|
r4 = ok;
|
|
} else {
|
|
status = error.status;
|
|
value9 = status !== 429;
|
|
r4 = value9;
|
|
}
|
|
if (!r4) {
|
|
binding = env3_0;
|
|
binding3 = env3_2;
|
|
intl = binding(binding3[17]).intl;
|
|
string = intl.string;
|
|
t = binding(binding3[17]).t;
|
|
Whhv4w = t.Whhv4w;
|
|
showErrorToast2(Reflect.apply(string, intl, [Whhv4w]));
|
|
}
|
|
env1_4(false);
|
|
return undefined;
|
|
}
|
|
if (value8) {
|
|
return value7;
|
|
}
|
|
env1_4(false);
|
|
}
|
|
}
|
|
function showErrorToast(a0) { // fn#90274, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:11970:2485, offset: 0x02032b01, size: 95 bytes, params: 2, frame: 16
|
|
let value = environment.__proto__.__proto__;
|
|
if (hasInputText !== a0) {
|
|
styles(a0);
|
|
}
|
|
value = environment.__proto__.__proto__.__proto__.__proto__;
|
|
const binding = env4_1;
|
|
const binding2 = env4_2;
|
|
value = binding(binding2[13]);
|
|
value.open({key: 'HANDLE_WAVE_PRESS_TOAST', content: a0, icon: binding(binding2[14])});
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
function useIsRendered() { // fn#90275, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:11970:2848, owner: DMMessageStickerGreeting.useIsRendered, offset: 0x02032b60, size: 93 bytes, params: 1, frame: 15
|
|
var environment;
|
|
let value = environment.__proto__;
|
|
const binding = env1_5;
|
|
value = env1_4(binding.useState(false), 2);
|
|
const property = value[0];
|
|
const property2 = value[1];
|
|
const useCallback = binding.useCallback;
|
|
return {isRendered: property, setIsRendered: Reflect.apply(useCallback, binding, [_fun90276, [property2]])};
|
|
function _fun90276() { // fn#90276, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:11970:2966, offset: 0x010be317, size: 18 bytes, params: 1, frame: 11
|
|
env0_0(true);
|
|
}
|
|
|
|
}
|
|
|
|
function DMMessageStickerGreetingX() { // fn#90277, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:11970:3053, owner: DMMessageStickerGreeting.x, offset: 0x02032bbd, size: 114 bytes, params: 1, frame: 14
|
|
var r3;
|
|
var value;
|
|
const height = styles.gradient.height;
|
|
const r5 = isRendered && !hasInputText;
|
|
const value3 = 0;
|
|
if (r5) {
|
|
value = 180;
|
|
value = (Module00005 ? 72 : value) - 1 + height;
|
|
r3 = value;
|
|
} else {
|
|
r3 = value3;
|
|
}
|
|
const generateAnimationConfig2 = generateAnimationConfig;
|
|
const object = {'justifyContent': 'flex-end', 'overflow': 'hidden'};
|
|
object.marginTop = generateAnimationConfig2(r5 ? -height : value3);
|
|
object.height = generateAnimationConfig2(r3);
|
|
return object;
|
|
function generateAnimationConfig(a0) { // fn#90278, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:11970:3141, owner: DMMessageStickerGreeting.x.generateAnimationConfig, offset: 0x02032c2f, size: 103 bytes, params: 2, frame: 18
|
|
let value = environment.__proto__.__proto__;
|
|
value = require(4017) /* metro dependency 4017: ReanimatedRexport */;
|
|
const withDelay = value.withDelay;
|
|
const withTiming = TimingModule.withTiming;
|
|
const STANDARD_EASING = (NativeModule).STANDARD_EASING;
|
|
return Reflect.apply(withDelay, value, [300, Reflect.apply(withTiming, TimingModule, [a0, {easing: STANDARD_EASING,
|
|
duration: 250}])]);
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
global.__d(_fun90262, 11784, [5, 57, 31, 27, 6583, 4814, 1878, 33, 4501, 697, 3963, 3860, 4000, 3857, 11785, 11786,
|
|
7067, 1244, 566, 671, 3995, 11787, 11050, 4017, 4504, 1305, 11049, 4589, 5278, 10970, 4573, 4578,
|
|
2]) /* metro module 11784, dependencies: [5, 57, 31, 27, 6583, 4814, 1878, 33, 4501, 697, 3963, 3860, 4000, 3857, 11785, 11786, 7067, 1244, 566, 671, 3995, 11787, 11050, 4017, 4504, 1305, 11049, 4589, 5278, 10970, 4573, 4578, 2] */;
|