Skip to content

Commit

Permalink
Merge pull request #1743 from ever-co/bug/team-screen-navigation-when…
Browse files Browse the repository at this point in the history
…-scrolling

allowing users to navigate only when scrolling is stopped
  • Loading branch information
evereq authored Nov 8, 2023
2 parents 868bcfa + 94a2f93 commit 1301110
Show file tree
Hide file tree
Showing 2 changed files with 294 additions and 227 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -57,6 +57,7 @@ export interface Props extends ListItemProps {
openMenuIndex: number | null
setOpenMenuIndex: React.Dispatch<React.SetStateAction<number | null>>
currentTeam: IOrganizationTeamWithMStatus | null
canNavigate: boolean
}

export const ListItemContent: React.FC<IcontentProps> = observer(

Check warning on line 63 in apps/mobile/app/screens/Authenticated/TeamScreen/components/ListCardItem.tsx

View workflow job for this annotation

GitHub Actions / Cspell

Unknown word (Icontent)
Expand Down Expand Up @@ -152,12 +153,15 @@ const ListCardItem: React.FC<Props> = observer((props) => {
taskEdition.setEditMode(false)
taskEdition.setEstimateEditMode(false)
props.setOpenMenuIndex(null)
isTaskScreen
? navigation.navigate("TaskScreen", { taskId: memberInfo?.memberTask?.id })
: navigation.navigate("Profile", {
userId: memberInfo.memberUser.id,
activeTab: "worked",
})

if (memberInfo.memberTask && props.canNavigate) {
isTaskScreen
? navigation.navigate("TaskScreen", { taskId: memberInfo.memberTask?.id })
: navigation.navigate("Profile", {
userId: memberInfo.memberUser.id,
activeTab: "worked",
})
}
}
const currentMember = props.currentTeam?.members.find(
(currentMember) => currentMember.id === props.member.id,
Expand Down
Loading

0 comments on commit 1301110

Please sign in to comment.