2026-08-25 06:04:03 +00:00
// Module ID: 15706
// Function ID: 15707
// Dependencies: [19, 4203, 1434, 4202, 5262, 21, 4380, 712, 15655, 4101, 589, 5885, 15688, 15657, 4205, 8576, 15669, 15698, 15646, 4120, 15677, 5374, 2]
2026-07-20 16:05:17 +00:00
2026-08-25 06:04:03 +00:00
// Module 15706
2026-08-24 06:08:38 +00:00
import ThemesDefault from "Themes" /* 712 */ ;
import importAllResult from "noop" /* 19 */ ;
2026-08-25 06:04:03 +00:00
import closure_4 from "handleGatewayJoinRequestUpdate" /* 4203 */ ;
2026-08-24 06:08:38 +00:00
import GuildNSFWContentLevel from "GuildNSFWContentLevel" /* 1434 */ ;
2026-08-25 06:04:03 +00:00
import closure_7 from "handleConnectionOpen" /* 4202 */ ;
import closure_8 from "insertUnsortedGuilds" /* 5262 */ ;
2026-08-24 06:08:38 +00:00
import { jsx } from "jsxProd" /* 21 */ ;
2026-08-25 06:04:03 +00:00
import createCacheKey from "createCacheKey" /* 4380 */ ;
2026-07-23 10:11:24 +00:00
const require = arg1 ;
2026-07-29 08:29:29 +00:00
let c3 = importAllResult ;
( { getGuildIconSource : c5 , getGuildIconURL : closure_6 } = GuildNSFWContentLevel ) ;
let obj = { guildIcon : null } ;
2026-08-24 06:08:38 +00:00
obj = { width : ThemesDefault.modules.mobile.GUILD_BAR_ITEM_SIZE , height : ThemesDefault.modules.mobile.GUILD_BAR_ITEM_SIZE } ;
2026-07-29 08:29:29 +00:00
obj [ 0 ] = obj ;
let closure_10 = createCacheKey . createStyles ( obj ) ;
2026-07-20 16:05:17 +00:00
const memoResult = importAllResult . memo ( function GuildsBarPendingGuild ( guildId ) {
guildId = guildId . guildId ;
2026-07-29 08:29:29 +00:00
let token ;
let stateFromStores ;
let stateFromStores1 ;
2026-07-23 10:11:24 +00:00
let stateFromStores3 ;
let obj = guildId ( stateFromStores [ 8 ] ) ;
2026-07-20 16:05:17 +00:00
const tmp = callback ( ) ;
2026-08-24 06:08:38 +00:00
obj1 = guildId ( stateFromStores [ 9 ] ) ;
2026-07-23 10:11:24 +00:00
token = obj1 . useToken ( token ( stateFromStores [ 7 ] ) . modules . mobile . GUILD_BAR_ITEM_SIZE ) ;
const guildsBarAnimatedWrapperStyles = obj . useGuildsBarAnimatedWrapperStyles ( { disableSelectedColor : true , disableBGColor : true } ) ;
2026-08-24 06:08:38 +00:00
const items = [ closure_7 ] ;
2026-07-29 08:29:29 +00:00
const items1 = [ guildId ] ;
2026-08-24 06:08:38 +00:00
stateFromStores = guildId ( stateFromStores [ 10 ] ) . useStateFromStores ( items , ( ) = > closure_1_7 . getGuildId ( ) === guildId , items1 ) ;
2026-07-29 08:29:29 +00:00
const obj3 = guildId ( stateFromStores [ 10 ] ) ;
2026-07-23 10:11:24 +00:00
const items2 = [ stateFromStores3 ] ;
2026-07-20 16:05:17 +00:00
const items3 = [ guildId ] ;
2026-07-29 08:29:29 +00:00
stateFromStores1 = guildId ( stateFromStores [ 10 ] ) . useStateFromStores ( items2 , ( ) = > stateFromStores3 . getRequest ( guildId ) , items3 ) ;
2026-07-23 10:11:24 +00:00
const obj4 = guildId ( stateFromStores [ 10 ] ) ;
const items4 = [ stateFromStores3 ] ;
2026-07-20 16:05:17 +00:00
const items5 = [ guildId , token , stateFromStores ] ;
2026-07-23 10:11:24 +00:00
const stateFromStores2 = guildId ( stateFromStores [ 10 ] ) . useStateFromStores ( items4 , ( ) = > {
2026-07-20 16:05:17 +00:00
const joinRequestGuild = stateFromStores3 . getJoinRequestGuild ( guildId ) ;
let tmp2 ;
if ( null != joinRequestGuild ) {
2026-08-24 06:08:38 +00:00
tmp2 = closure_1_6 ( joinRequestGuild , token , stateFromStores ) ;
2026-07-20 16:05:17 +00:00
}
let name ;
2026-07-29 08:29:29 +00:00
if ( joinRequestGuild != null ) {
2026-07-20 16:05:17 +00:00
name = joinRequestGuild . name ;
}
2026-07-29 08:29:29 +00:00
const obj = { guildName : name , icon : tmp2 , asset : null } ;
2026-07-20 16:05:17 +00:00
let tmp7 ;
if ( null != tmp2 ) {
if ( null != joinRequestGuild ) {
2026-08-24 06:08:38 +00:00
tmp7 = closure_1_5 ( joinRequestGuild , guildId ( stateFromStores [ 11 ] ) . ImageSizes [ guildId ( undefined , stateFromStores [ 11 ] ) . GuildIconSizes . LARGE ] , stateFromStores ) ;
2026-07-20 16:05:17 +00:00
}
}
2026-07-29 08:29:29 +00:00
obj [ 2 ] = tmp7 ;
2026-07-20 16:05:17 +00:00
return obj ;
2026-07-23 10:11:24 +00:00
} , items5 , token ( stateFromStores [ 12 ] ) ) ;
2026-07-29 08:29:29 +00:00
( { guildName , asset , icon } = stateFromStores2 ) ;
2026-07-20 16:05:17 +00:00
let applicationStatus ;
2026-07-23 10:11:24 +00:00
const obj5 = guildId ( stateFromStores [ 10 ] ) ;
2026-07-29 08:29:29 +00:00
if ( stateFromStores1 != null ) {
2026-07-20 16:05:17 +00:00
applicationStatus = stateFromStores1 . applicationStatus ;
}
2026-07-29 08:29:29 +00:00
const tmp10 = token ( stateFromStores [ 13 ] ) ;
2026-07-20 16:05:17 +00:00
const items6 = [ guildId , ] ;
let applicationStatus1 ;
2026-07-29 08:29:29 +00:00
( { badge , cutouts } = token ( stateFromStores [ 13 ] ) ( { mentionCount : 0 , joinRequestState : applicationStatus } ) ) ;
if ( stateFromStores1 != null ) {
2026-07-20 16:05:17 +00:00
applicationStatus1 = stateFromStores1 . applicationStatus ;
}
items6 [ 1 ] = applicationStatus1 ;
2026-07-23 10:11:24 +00:00
const memo = stateFromStores1 . useMemo ( ( ) = > ( {
2026-07-20 16:05:17 +00:00
onPress() {
let applicationStatus ;
2026-07-29 08:29:29 +00:00
if ( applicationStatus != null ) {
applicationStatus = applicationStatus . applicationStatus ;
2026-07-20 16:05:17 +00:00
}
2026-08-24 06:08:38 +00:00
if ( closure_1_0 ( closure_1_2 [ 14 ] ) . GuildJoinRequestApplicationStatuses . STARTED === applicationStatus ) {
2026-07-29 08:29:29 +00:00
let tmp2Result = tmp2 ( tmp3 [ 15 ] ) ;
const result = tmp2Result . openMemberVerificationIncompleteAlert ( closure_0 ) ;
} else if ( tmp2 ( tmp3 [ 14 ] ) . GuildJoinRequestApplicationStatuses . SUBMITTED === applicationStatus ) {
tmp2Result = tmp2 ( tmp3 [ 15 ] ) ;
const result1 = tmp2Result . openMemberVerificationPendingAlert ( closure_0 ) ;
} else if ( tmp2 ( tmp3 [ 14 ] ) . GuildJoinRequestApplicationStatuses . APPROVED === applicationStatus ) {
2026-08-24 06:08:38 +00:00
closure_1_1 ( tmp3 [ 16 ] ) ( closure_0 ) ;
2026-07-29 08:29:29 +00:00
} else if ( tmp2 ( tmp3 [ 14 ] ) . GuildJoinRequestApplicationStatuses . REJECTED === applicationStatus ) {
const obj = { guildId : null , canWithdraw : true } ;
obj [ 0 ] = closure_0 ;
const result2 = tmp2 ( tmp3 [ 15 ] ) . openMemberVerificationRejectedAlert ( obj ) ;
const tmp2Result1 = tmp2 ( tmp3 [ 15 ] ) ;
2026-07-20 16:05:17 +00:00
}
}
} ) , items6 ) ;
2026-07-29 08:29:29 +00:00
const tmp15 = token ( stateFromStores [ 17 ] ) ( guildId , icon , asset ) ;
let tmp2Result = tmp2 ( tmp3 [ 10 ] ) ;
2026-08-24 06:08:38 +00:00
const items7 = [ closure_8 ] ;
2026-07-29 08:29:29 +00:00
stateFromStores3 = tmp2Result . useStateFromStores ( items7 , ( ) = > guildsTree . getGuildsTree ( ) . version ) ;
2026-07-20 16:05:17 +00:00
const items8 = [ guildId , stateFromStores3 ] ;
2026-07-23 10:11:24 +00:00
const memo1 = stateFromStores1 . useMemo ( ( ) = > {
arr = token ( stateFromStores [ 18 ] ) ( arr , stateFromStores3 ) ;
2026-07-20 16:05:17 +00:00
return {
accessibilityActions : arr.map ( ( label ) = > ( { name : label.label , label : label.label } ) ) ,
onAccessibilityAction ( arg0 ) {
2026-07-23 10:11:24 +00:00
const found = arg0 . find ( ( label ) = > label . label === nativeEvent . nativeEvent . actionName ) ;
2026-07-29 08:29:29 +00:00
if ( found != null ) {
const action = found . action ;
if ( action != null ) {
action ( ) ;
}
2026-07-20 16:05:17 +00:00
}
}
} ;
} , items8 ) ;
( { accessibilityActions , onAccessibilityAction } = memo1 ) ;
2026-07-29 08:29:29 +00:00
tmp2Result = tmp2 ( tmp3 [ 19 ] ) ;
const sharedValue = tmp2Result . useSharedValue ( guildId ) ;
2026-08-08 06:10:11 +00:00
obj = { id : guildId , accessibilityActions , onAccessibilityAction , cutouts , selected : stateFromStores , sharedId : sharedValue , circle : ! stateFromStores , overState : "ct" , unread : null , label : null , config : null , styles : null , externalChildren : null , expandedChildren : null , children : "function runOnUI_Pnpm_threadsTs3(worklet){const{__DEV__,SHOULD_BE_USE_WEB,isWorkletFunction,IS_JEST,ReanimatedModule,makeShareableCloneRecursive,callMicrotasks}=this.__closure;if(__DEV__&&!SHOULD_BE_USE_WEB&&_WORKLET){throw new ReanimatedError('`runOnUI` cannot be called on the UI runtime. Please call the function synchronously or use `queueMicrotask` or `requestAnimationFrame` instead.');}if(__DEV__&&!SHOULD_BE_USE_WEB&&!isWorkletFunction(worklet)){throw new ReanimatedError('`runOnUI` can only be used with worklets.');}return function(...args){if(IS_JEST){ReanimatedModule.scheduleOnUI(makeShareableCloneRecursive(function(){'worklet';worklet(...args);}));return;}if(__DEV__){makeShareableCloneRecursive(worklet);makeShareableCloneRecursive(args);}_runOnUIQueue.push([worklet,args]);if(_runOnUIQueue.length===1){queueMicrotask(function(){const queue=_runOnUIQueue;_runOnUIQueue=[];ReanimatedModule.scheduleOnUI(makeShareableCloneRecursive(function(){'worklet';queue.forEach(function([worklet,args]){worklet(...args);});callMicrotasks();}));});}};}" } ;
2026-07-29 08:29:29 +00:00
let str = guildName ;
let tmp5Result = tmp5 ( tmp3 [ 8 ] ) ;
if ( guildName == null ) {
str = "" ;
2026-07-20 16:05:17 +00:00
}
2026-07-29 08:29:29 +00:00
obj [ 9 ] = str ;
obj [ 10 ] = memo ;
obj [ 11 ] = guildsBarAnimatedWrapperStyles ;
obj [ 12 ] = badge ;
obj [ 13 ] = jsx ( token ( stateFromStores [ 20 ] ) , { guildId , disableSubtitle : true } ) ;
if ( null != tmp15 ) {
obj = { source : null , style : null } ;
obj [ 0 ] = tmp15 ;
obj [ 1 ] = tmp . guildIcon ;
let tmp19Result = tmp19 ( tmp5 ( tmp3 [ 21 ] ) , obj ) ;
2026-07-20 16:05:17 +00:00
} else {
2026-07-29 08:29:29 +00:00
obj1 = { value : null , selected : null , animate : null , size : null } ;
obj1 [ 0 ] = guildName ;
obj1 [ 1 ] = stateFromStores ;
obj1 [ 2 ] = stateFromStores ;
tmp5Result = tmp5 ( tmp3 [ 11 ] ) ;
obj1 [ 3 ] = tmp2 ( tmp3 [ 11 ] ) . GuildIconSizes . LARGE ;
tmp19Result = tmp19 ( tmp5Result , obj1 ) ;
2026-07-20 16:05:17 +00:00
}
2026-07-29 08:29:29 +00:00
obj [ 14 ] = tmp19Result ;
2026-08-08 06:10:11 +00:00
return < tmp5Result id = { guildId } accessibilityActions = { accessibilityActions } onAccessibilityAction = { onAccessibilityAction } cutouts = { cutouts } selected = { stateFromStores } sharedId = { sharedValue } circle = { ! stateFromStores } overState = "ct" unread = { null } label = { null } config = { null } styles = { null } externalChildren = { null } expandedChildren = { null } > { "function runOnUI_Pnpm_threadsTs3(worklet){const{__DEV__,SHOULD_BE_USE_WEB,isWorkletFunction,IS_JEST,ReanimatedModule,makeShareableCloneRecursive,callMicrotasks}=this.__closure;if(__DEV__&&!SHOULD_BE_USE_WEB&&_WORKLET){throw new ReanimatedError('`runOnUI` cannot be called on the UI runtime. Please call the function synchronously or use `queueMicrotask` or `requestAnimationFrame` instead.');}if(__DEV__&&!SHOULD_BE_USE_WEB&&!isWorkletFunction(worklet)){throw new ReanimatedError('`runOnUI` can only be used with worklets.');}return function(...args){if(IS_JEST){ReanimatedModule.scheduleOnUI(makeShareableCloneRecursive(function(){'worklet';worklet(...args);}));return;}if(__DEV__){makeShareableCloneRecursive(worklet);makeShareableCloneRecursive(args);}_runOnUIQueue.push([worklet,args]);if(_runOnUIQueue.length===1){queueMicrotask(function(){const queue=_runOnUIQueue;_runOnUIQueue=[];ReanimatedModule.scheduleOnUI(makeShareableCloneRecursive(function(){'worklet';queue.forEach(function([worklet,args]){worklet(...args);});callMicrotasks();}));});}};}" } < / tmp5Result > ;
2026-07-20 16:05:17 +00:00
} ) ;
2026-08-24 06:08:38 +00:00
let result = require ( "set" ) . fileFinishedImporting ( "modules/guilds_bar/native/GuildsBarPendingGuild.tsx" ) ;
2026-07-20 16:05:17 +00:00
export default memoResult ;