Skip to content

Commit

Permalink
fix(styling): Improve the styling of user list
Browse files Browse the repository at this point in the history
  • Loading branch information
David Code Howard committed Oct 12, 2023
1 parent ff27075 commit 4dd0951
Show file tree
Hide file tree
Showing 2 changed files with 16 additions and 9 deletions.
15 changes: 8 additions & 7 deletions dev-client/src/components/common/UserList.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@ import {
Box,
Button,
Center,
Divider,
FlatList,
HStack,
Image,
Expand Down Expand Up @@ -60,13 +61,12 @@ function UserItem({membership, user, currentUserId, onPress}: ItemProps) {
<Text flex={3}>{userName}</Text>
<Box>
<Badge
variant="chip"
bg="primary.lightest"
_text={{color: 'text.primary'}}
borderRadius={14}
flex={0}
ml={6}>
{membership.userRole.charAt(0) +
membership.userRole.slice(1).toLowerCase()}
py="5px"
px="10px"
_text={{color: 'text.primary'}}>
{t('general.role.' + membership.userRole)}
</Badge>
</Box>
</HStack>
Expand All @@ -79,7 +79,7 @@ function UserItem({membership, user, currentUserId, onPress}: ItemProps) {
_text={{color: 'error.main'}}
bgColor="grey.200"
onPress={onPress}>
LEAVE PROJECT
{t('projects.team.leave_project')}
</Button>
</Center>
)}
Expand All @@ -105,6 +105,7 @@ export default function UserList({
/>
)}
keyExtractor={([id, _]) => id}
ItemSeparatorComponent={Divider}
/>
);
}
10 changes: 8 additions & 2 deletions dev-client/src/translations/en.json
Original file line number Diff line number Diff line change
Expand Up @@ -119,7 +119,8 @@
}
},
"team": {
"add": "Add team members"
"add": "Add team members",
"leave_project": "LEAVE PROJECT"
},
"edit": {
"inputHeader": "General Project Settings"
Expand Down Expand Up @@ -192,7 +193,12 @@
"details": "Details",
"apply": "Apply",
"example_email": "[email protected]",
"profile_image_alt": "Profile image"
"profile_image_alt": "Profile image",
"role": {
"viewer": "Viewer",
"contributor": "Contributor",
"manager": "Manager"
}
},
"screens": {
"HOME": "LandPKS",
Expand Down

0 comments on commit 4dd0951

Please sign in to comment.