From 5697a136c23c3ae03d31fa40cf9dda1e98d1c95c Mon Sep 17 00:00:00 2001 From: Reinaldo Neto <47038980+reinaldonetof@users.noreply.github.com> Date: Thu, 27 May 2021 17:41:33 -0300 Subject: [PATCH] [FIX] Add channels to team's flow using different navigators (#3157) * [FIX] the navigation to AddChannelTeamView and next screens * Fix the order inside the NewMessageStackNavigator * Delete spaces after arrow function in onPress * Adjusted InsideStackNavigator to a conditional animation * Fixed route for iPad * Small change Co-authored-by: Diego Mello --- app/stacks/InsideStack.js | 5 +++++ app/views/AddChannelTeamView.js | 5 ++++- 2 files changed, 9 insertions(+), 1 deletion(-) diff --git a/app/stacks/InsideStack.js b/app/stacks/InsideStack.js index 18517368c..83fc22240 100644 --- a/app/stacks/InsideStack.js +++ b/app/stacks/InsideStack.js @@ -182,6 +182,11 @@ const ChatsStackNavigator = () => { component={TeamChannelsView} options={TeamChannelsView.navigationOptions} /> + navigation.navigate('NewMessageStackNavigator', { screen: 'SelectedUsersViewCreateChannel', params: { nextAction: () => navigation.navigate('CreateChannelView', { teamId }) } })} + onPress={() => (isMasterDetail + ? navigation.navigate('SelectedUsersViewCreateChannel', { nextAction: () => navigation.navigate('CreateChannelView', { teamId }) }) + : navigation.navigate('SelectedUsersView', { nextAction: () => navigation.navigate('ChatsStackNavigator', { screen: 'CreateChannelView', params: { teamId } }) })) + } testID='add-channel-team-view-create-channel' left={() => } right={() => }