Files
2026-07-28 01:06:53 +03:00

111 lines
7.7 KiB
TypeScript

/* Metro module 14443; source: modules/guilds_bar/native/GuildsBarItemEmptyNUX.tsx; dependencies: [31, 27, 3969, 661, 7607, 33, 4501, 697, 3860, 566, 6947, 4017, 4577, 1244, 14444, 14395, 2] */
import Native from '../../../external/discord_common/js/packages/tokens/native.tsx'; /* Metro dependency 697 */
import SelectedGuildStore from '../../../stores/SelectedGuildStore.tsx'; /* Metro dependency 3969 */
import ReanimatedRexport from '../../reanimated/ReanimatedRexport.tsx'; /* Metro dependency 4017 */
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 ConstantsModule from '../../../Constants.tsx'; /* Metro dependency 661 */
import * as UseTokenModule from '../../../design/tokens/native/useToken.tsx'; /* Metro dependency 3860 */
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 SpringModule from '../../../design/animation/reanimated/spring/spring.tsx'; /* Metro dependency 4577 */
import * as MainTabsConstantsModule from '../../main_tabs_v2/native/MainTabsConstants.tsx'; /* Metro dependency 7607 */
import * as GuildsBarAnimatedItemWrapperModule from './GuildsBarAnimatedItemWrapper.tsx'; /* Metro dependency 14395 */
function _fun109291(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#109291, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14640:6, offset: 0x02344cd2, size: 339 bytes, params: 8, frame: 19
const env0_0 = require;
const Object = global.Object;
Object.defineProperty(exports, '__esModule', {value: true});
let value = ReactModule;
const env0_13 = {'top': 4, 'left': 12, 'bottom': 4, 'right': 12};
const env0_14 = (CreateStylesModule).createStyles(_fun109292);
object = {code: "function GuildsBarItemEmptyNUXTsx1(){const{withSpring,selected,activeColor,inactiveColor,MODE_CHANGE_PHYSICS}=this.__closure;return{backgroundColor:withSpring(selected?activeColor:inactiveColor,MODE_CHANGE_PHYSICS,'animate-always')};}"};
value = value.memo(GuildsBarEmptyNUX);
(FileImportTrackerModule).fileFinishedImporting('modules/guilds_bar/native/GuildsBarItemEmptyNUX.tsx');
exports.default = value;
function _fun109292(a0) { // fn#109292, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14640:320, offset: 0x02344e25, size: 184 bytes, params: 2, frame: 15
const GUILD_BAR_ITEM_PADDING = (Native).modules.mobile.GUILD_BAR_ITEM_PADDING;
return {container: {'position': 'relative', 'flexDirection': 'row', 'alignItems': 'center', 'marginTop': null,
'height': 55, marginTop: GUILD_BAR_ITEM_PADDING, width: a0}, guildIndicator: {'position': 'absolute',
'left': null, 'top': 4,
left: -(DM_WIDTH - a0) / 2}, icon: {'width': 59, 'height': 55, 'marginLeft': -3, 'marginRight': -6}, backdrop: {'position': 'absolute', 'top': 16, width: a0, height: a0 - 10, borderRadius: a0 / 3}};
}
function GuildsBarEmptyNUX() { // fn#109293, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14640:922, offset: 0x02344edd, size: 729 bytes, params: 1, frame: 27
let useToken = UseTokenModule.useToken;
const GUILD_BAR_ITEM_SIZE = (Native).modules.mobile.GUILD_BAR_ITEM_SIZE;
const styles = useStyles(Reflect.apply(useToken, UseTokenModule, [GUILD_BAR_ITEM_SIZE]));
const value3 = (require(566) /* metro dependency 566: flux */).useStateFromStores([SelectedGuildStore], function() {
return SelectedGuildStore.getGuildId() === EMPTY_NUX_SERVER;
});
const binding = env0_3;
let closure = function() {
require(dependencyMap[10]).transitionToGuild(EMPTY_NUX_SERVER);
};
const value4 = binding.useCallback(closure, []);
const value5 = (ReanimatedRexportModule).useSharedValue(false);
const value6 = binding.useCallback(_fun109296, [value5]);
const value7 = binding.useCallback(_fun109297, [value5]);
useToken = UseTokenModule.useToken;
const BACKGROUND_SURFACE_HIGH = (Native).colors.BACKGROUND_SURFACE_HIGH;
const value8 = Reflect.apply(useToken, UseTokenModule, [BACKGROUND_SURFACE_HIGH]);
useToken = UseTokenModule.useToken;
const BACKGROUND_BRAND = (Native).colors.BACKGROUND_BRAND;
const value9 = Reflect.apply(useToken, UseTokenModule, [BACKGROUND_BRAND]);
const useAnimatedStyle = ReanimatedRexportModule.useAnimatedStyle;
closure = GuildsBarEmptyNUXO;
closure.__closure = {withSpring: (require(4577) /* metro dependency 4577: spring */).withSpring, selected: value3,
activeColor: value9, inactiveColor: value8, MODE_CHANGE_PHYSICS: MODE_CHANGE_PHYSICS};
closure.__workletHash = 15012639840543;
closure.__initData = env0_15;
const value10 = Reflect.apply(useAnimatedStyle, ReanimatedRexportModule, [closure]);
object = {style: styles.container, onPressIn: value6, onPressOut: value7, onPress: value4, accessible: true,
accessibilityRole: 'button'};
const intl = (require(1244) /* metro dependency 1244: indexNative */).intl;
object.accessibilityLabel = intl.string((require(1244) /* metro dependency 1244: indexNative */).t['3S2xmm']);
object.accessibilityState = {selected: value3};
object.hitSlop = env0_13;
const View2 = (ReanimatedRexport).View;
const items2 = [
<View2 style={[styles.backdrop, value10]} />,
];
items2[1] = (
<Image
style={styles.icon}
source={importDefault(14444) /* metro dependency 14444 */}
resizeMode="contain"
/>
);
const UnreadIndicator = (GuildsBarAnimatedItemWrapperModule).UnreadIndicator;
items2[2] = (
<View style={styles.guildIndicator}>
<UnreadIndicator selected={value3 === true} />
</View>
);
return (
<Pressable {...object}>
{items2}
</Pressable>
);
function _fun109296() { // fn#109296, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14640:1191, offset: 0x023451fb, size: 23 bytes, params: 1, frame: 11
env0_1.set(true);
}
function _fun109297() { // fn#109297, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14640:1230, offset: 0x02345212, size: 23 bytes, params: 1, frame: 11
env0_1.set(false);
}
function GuildsBarEmptyNUXO() { // fn#109298, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:14640:1395, owner: GuildsBarEmptyNUX.o, offset: 0x02345229, size: 75 bytes, params: 1, frame: 17
return {backgroundColor: SpringModule.withSpring(env0_0 ? env0_3 : env0_2, MODE_CHANGE_PHYSICS, 'animate-always')};
}
}
}
global.__d(_fun109291, 14443, [31, 27, 3969, 661, 7607, 33, 4501, 697, 3860, 566, 6947, 4017, 4577, 1244, 14444,
14395,
2]) /* metro module 14443, dependencies: [31, 27, 3969, 661, 7607, 33, 4501, 697, 3860, 566, 6947, 4017, 4577, 1244, 14444, 14395, 2] */;