-
Notifications
You must be signed in to change notification settings - Fork 0
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat: New care group screen #76
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Amazing job Haley just some small things!
client/screens/Profile/CareGroup.tsx
Outdated
</View> | ||
</View> | ||
|
||
<View className="mx-2 mt-2 flex h-[180vh] w-[96vw] flex-col items-center rounded-xl"> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Any reason for 180vh here? Scroll view should handle height on its own
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
removed
go.mod
Outdated
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This can be removed.
client/screens/Profile/CareGroup.tsx
Outdated
<ScrollView> | ||
<View className="bg-carewallet-lightergray"> | ||
<View className="flex h-[10vh] items-center"> | ||
<View className="h-[10vh] scroll-pb-96"> | ||
<View className="flex w-full flex-row justify-end text-carewallet-black"> | ||
<Button | ||
className="mx-auto mt-2 h-[50px] w-[96vw] items-start justify-center rounded-xl border-carewallet-lightgray bg-carewallet-white" | ||
textColor="#000000" | ||
mode="outlined" | ||
icon={() => <Settings />} // Example using FontAwesome icon | ||
> | ||
<Text className="font-carewallet-manrope-semibold"> | ||
{' '} | ||
Manage Caregiver Capabiities{' '} | ||
</Text> | ||
</Button> | ||
</View> | ||
</View> | ||
</View> | ||
|
||
<View className="mx-2 mt-2 flex h-[180vh] w-[96vw] flex-col items-center rounded-xl"> | ||
{users | ||
.filter((user) => user.user_id !== activeUser) | ||
.map((user) => ( | ||
<View | ||
key={user.user_id} // <-- Add key prop here | ||
onTouchEnd={() => { | ||
navigation.navigate('Profile'); | ||
}} | ||
> | ||
<CareTaker |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Noticed a scroll bug when I am scrolling and had pressed on a card it will visit the card after i lift up my finger. Look at other scroll views on how we handled this!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
this part should be fixed, although it still will navigate to 'Profile' and not the profile of the person it touches. since the profile component doesn't take in a userId or anything not sure how to navigate to the profile of an actual user without refactoring the profile component. any ideas or is it okay as is? @MattCMcCoy
client/screens/Profile/CareGroup.tsx
Outdated
/> | ||
</View> | ||
))} | ||
<View className="h-[70vh] pt-10"></View> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
<View className="h-[70vh] pt-10"></View> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
removed
client/screens/Profile/Profile.tsx
Outdated
<CircleCard | ||
Icon={<Settings />} | ||
ButtonText="Settings" | ||
onTouchEnd={() => navigation.navigate('CareGroup')} | ||
/> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This button is nested in settings on main. So when fixing merge conflicts, let caplan or I know if you have any problems.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
in my latest commit i will have allowed it to navigate from the settings page by pressing the 'manage caregiver capabilities' button
client/screens/Profile/CareGroup.tsx
Outdated
); | ||
} | ||
return ( | ||
<GestureHandlerRootView className="bg-carewallet-white pt-5"> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
What this for?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
i have no idea but i removed it
client/screens/Profile/CareGroup.tsx
Outdated
<Text className="font-carewallet-manrope-semibold"> | ||
{' '} | ||
Manage Caregiver Capabiities{' '} | ||
</Text> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
<Text className="font-carewallet-manrope-semibold"> | |
{' '} | |
Manage Caregiver Capabiities{' '} | |
</Text> | |
<Text className="font-carewallet-manrope-semibold"> | |
Manage Caregiver Capabiities | |
</Text> |
client/screens/Profile/CareGroup.tsx
Outdated
|
||
<View className="mx-2 mt-2 flex h-[180vh] w-[96vw] flex-col items-center rounded-xl"> | ||
{users | ||
.filter((user) => user.user_id !== activeUser) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
we should prob filter out patient as well
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
added
client/screens/Profile/CareGroup.tsx
Outdated
onTouchEnd={() => { | ||
navigation.navigate('Profile'); | ||
}} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
is this able to set the active profile on profile page depending on who you click on?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ah I see ignore my comment from before. I'm trying to do it like this but I'm assuming that the navigate function doesn't take into account the new state even if it was set differently again?:
onPress={() => { setActiveUser(user.user_id) navigation.navigate('Profile'); }}
// const { user: signedInUser, group } = useCareWalletContext(); | ||
// const [activeUser, setActiveUser] = useState(signedInUser.userID); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
// const { user: signedInUser, group } = useCareWalletContext(); | |
// const [activeUser, setActiveUser] = useState(signedInUser.userID); |
Once data branch is merged this is good to go 🚀 @narayansharma-21 |
Description
[Link to Ticket](insert the link to your ticket inside the parenthesis here)
Please include a summary of the changes and the related issue. Please also
include relevant motivation, context, and images!
How Has This Been Tested?
Please describe the tests that you ran to verify your changes. If they are unit
tests, provide the file name the tests are in. If they are not unit tests,
describe how you tested the change.
Checklist